2025-05-20 23:49:15 +08:00

75 lines
1.6 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

export type LayoutType = 'vertical';
// 仿豆包折叠逻辑
export type CollapseType =
| 'alwaysCollapsed' // 始终折叠
| 'followSystem' // 跟随系统视口宽度
| 'alwaysExpanded' // 始终打开
| 'narrowExpandWideCollapse'; // 系统视口 宽小则张,宽大则收
export interface DesignConfigState {
// 系统主题
darkMode: 'light' | 'dark' | 'inverted';
// 系统主题色
themeColor: string;
// 系统内置风格
themeColorList: string[];
// 是否开启路由动画
isPageAnimate: boolean;
// 路由动画类型
pageAnimateType: string;
// 布局模式 (纵向vertical | ... | 自己定义)
layout: LayoutType;
// 折叠类型
collapseType: CollapseType;
// 是否折叠菜单
isCollapse: boolean;
// 头部折叠按钮是否被悬停
isCollapseHover: boolean;
}
export const themeColorList: string[] = [
'#5d9dfe',
'#2d8cf0',
'#0960bd',
'#0084f4',
'#009688',
'#536dfe',
'#ff5c93',
'#ee4f12',
'#0096c7',
'#9c27b0',
'#ff9800',
'#FF3D68',
'#00C1D4',
'#18a058',
'#78DEC7',
'#1768AC',
'#FB9300',
'#FC5404',
'#8675ff',
];
const design: DesignConfigState = {
// 深色主题
darkMode: 'light',
// 系统主题色
themeColor: '#F7B51C',
// 系统内置主题色列表
themeColorList,
// 是否开启路由动画
isPageAnimate: false,
// 路由动画类型
pageAnimateType: 'zoom-fade',
// 布局模式 (纵向vertical | ... | 自己定义)
layout: 'vertical',
// 折叠类型
collapseType: 'followSystem',
// 是否折叠菜单
isCollapse: false,
// 头部折叠按钮是否被悬停
isCollapseHover: false,
};
export default design;