mirror of
https://github.com/CherryHQ/cherry-studio.git
synced 2026-01-07 05:39:05 +08:00
refactor(Sidebar, McpSettingsNavbar): update icons and improve layout for better UI consistency
This commit is contained in:
parent
60a10bd6af
commit
a488489092
@ -19,10 +19,10 @@ import {
|
|||||||
MessageSquareQuote,
|
MessageSquareQuote,
|
||||||
Moon,
|
Moon,
|
||||||
Palette,
|
Palette,
|
||||||
RefreshCcw,
|
|
||||||
Settings,
|
Settings,
|
||||||
Sparkle,
|
Sparkle,
|
||||||
Sun
|
Sun,
|
||||||
|
SunMoon
|
||||||
} from 'lucide-react'
|
} from 'lucide-react'
|
||||||
import { FC, useEffect } from 'react'
|
import { FC, useEffect } from 'react'
|
||||||
import { useTranslation } from 'react-i18next'
|
import { useTranslation } from 'react-i18next'
|
||||||
@ -104,7 +104,7 @@ const Sidebar: FC = () => {
|
|||||||
) : settingTheme === 'light' ? (
|
) : settingTheme === 'light' ? (
|
||||||
<Sun size={20} className="icon" />
|
<Sun size={20} className="icon" />
|
||||||
) : (
|
) : (
|
||||||
<RefreshCcw size={20} className="icon" />
|
<SunMoon size={20} className="icon" />
|
||||||
)}
|
)}
|
||||||
</Icon>
|
</Icon>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
|
|||||||
@ -64,10 +64,9 @@ export const McpSettingsNavbar = () => {
|
|||||||
key: name,
|
key: name,
|
||||||
label: (
|
label: (
|
||||||
<Menu.Item
|
<Menu.Item
|
||||||
key={name}
|
|
||||||
onClick={() => window.open(url, '_blank', 'noopener,noreferrer')}
|
onClick={() => window.open(url, '_blank', 'noopener,noreferrer')}
|
||||||
style={{ display: 'flex', alignItems: 'center', cursor: 'pointer' }}>
|
style={{ backgroundColor: 'transparent' }}
|
||||||
<img src={logo} alt={name} style={{ width: 16, height: 16, borderRadius: 3, marginRight: 8 }} />
|
icon={<img src={logo} alt={name} style={{ width: 20, height: 20, borderRadius: 5, marginRight: 10 }} />}>
|
||||||
{name}
|
{name}
|
||||||
</Menu.Item>
|
</Menu.Item>
|
||||||
)
|
)
|
||||||
@ -85,17 +84,14 @@ export const McpSettingsNavbar = () => {
|
|||||||
style={{ fontSize: 13, height: 28, borderRadius: 20 }}>
|
style={{ fontSize: 13, height: 28, borderRadius: 20 }}>
|
||||||
{t('settings.mcp.searchNpx')}
|
{t('settings.mcp.searchNpx')}
|
||||||
</Button>
|
</Button>
|
||||||
<Dropdown
|
<Dropdown menu={{ items: resourceMenuItems }} trigger={['click']}>
|
||||||
menu={{ items: resourceMenuItems }}
|
|
||||||
trigger={['click']}
|
|
||||||
overlayStyle={{ maxHeight: '400px', overflow: 'auto' }}>
|
|
||||||
<Button
|
<Button
|
||||||
size="small"
|
size="small"
|
||||||
type="text"
|
type="text"
|
||||||
className="nodrag"
|
className="nodrag"
|
||||||
style={{ fontSize: 13, height: 28, borderRadius: 20, display: 'flex', alignItems: 'center' }}>
|
style={{ fontSize: 13, height: 28, borderRadius: 20, display: 'flex', alignItems: 'center' }}>
|
||||||
{t('settings.mcp.findMore')}
|
{t('settings.mcp.findMore')}
|
||||||
<ChevronDown size={14} style={{ marginLeft: 5 }} />
|
<ChevronDown size={16} />
|
||||||
</Button>
|
</Button>
|
||||||
</Dropdown>
|
</Dropdown>
|
||||||
<InstallNpxUv mini />
|
<InstallNpxUv mini />
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user