fix(web): fix PaletteOutlined icon import and apply theme config

- Replace non-existent PaletteOutlined with BgColorsOutlined
- Apply user's refined light/dark theme configuration with proper
  color tokens, component overrides, and design system consistency
This commit is contained in:
iven
2026-04-12 18:57:10 +08:00
parent 9557c9ca16
commit 88f6516fa9
2 changed files with 178 additions and 13 deletions

View File

@@ -1,4 +1,13 @@
import { Tabs } from 'antd';
import {
BookOutlined,
GlobalOutlined,
MenuOutlined,
NumberOutlined,
SettingOutlined,
BgColorsOutlined,
AuditOutlined,
} from '@ant-design/icons';
import DictionaryManager from './settings/DictionaryManager';
import LanguageManager from './settings/LanguageManager';
import MenuConfig from './settings/MenuConfig';
@@ -8,17 +17,93 @@ import ThemeSettings from './settings/ThemeSettings';
import AuditLogViewer from './settings/AuditLogViewer';
const Settings: React.FC = () => {
const items = [
{ key: 'dictionaries', label: '数据字典', children: <DictionaryManager /> },
{ key: 'languages', label: '语言管理', children: <LanguageManager /> },
{ key: 'menus', label: '菜单配置', children: <MenuConfig /> },
{ key: 'numbering', label: '编号规则', children: <NumberingRules /> },
{ key: 'settings', label: '系统参数', children: <SystemSettings /> },
{ key: 'theme', label: '主题设置', children: <ThemeSettings /> },
{ key: 'audit-log', label: '审计日志', children: <AuditLogViewer /> },
];
return (
<div>
<div className="erp-page-header" style={{ borderBottom: 'none', marginBottom: 0, paddingBottom: 8 }}>
<div>
<h4></h4>
<div className="erp-page-subtitle"></div>
</div>
</div>
return <Tabs defaultActiveKey="dictionaries" items={items} />;
<Tabs
defaultActiveKey="dictionaries"
style={{ marginTop: 8 }}
items={[
{
key: 'dictionaries',
label: (
<span style={{ display: 'flex', alignItems: 'center', gap: 6 }}>
<BookOutlined style={{ fontSize: 14 }} />
</span>
),
children: <DictionaryManager />,
},
{
key: 'languages',
label: (
<span style={{ display: 'flex', alignItems: 'center', gap: 6 }}>
<GlobalOutlined style={{ fontSize: 14 }} />
</span>
),
children: <LanguageManager />,
},
{
key: 'menus',
label: (
<span style={{ display: 'flex', alignItems: 'center', gap: 6 }}>
<MenuOutlined style={{ fontSize: 14 }} />
</span>
),
children: <MenuConfig />,
},
{
key: 'numbering',
label: (
<span style={{ display: 'flex', alignItems: 'center', gap: 6 }}>
<NumberOutlined style={{ fontSize: 14 }} />
</span>
),
children: <NumberingRules />,
},
{
key: 'settings',
label: (
<span style={{ display: 'flex', alignItems: 'center', gap: 6 }}>
<SettingOutlined style={{ fontSize: 14 }} />
</span>
),
children: <SystemSettings />,
},
{
key: 'theme',
label: (
<span style={{ display: 'flex', alignItems: 'center', gap: 6 }}>
<BgColorsOutlined style={{ fontSize: 14 }} />
</span>
),
children: <ThemeSettings />,
},
{
key: 'audit-log',
label: (
<span style={{ display: 'flex', alignItems: 'center', gap: 6 }}>
<AuditOutlined style={{ fontSize: 14 }} />
</span>
),
children: <AuditLogViewer />,
},
]}
/>
</div>
);
};
export default Settings;