defaultSettings.ts 1.78 KB
Newer Older
何乐's avatar
何乐 committed
1 2 3
import { MenuTheme } from 'antd/es/menu';

export type ContentWidth = 'Fluid' | 'Fixed';
陈小聪's avatar
陈小聪 committed
4

duanledexianxianxian's avatar
duanledexianxianxian committed
5 6 7 8 9 10
export interface localeProps {
  key: string;
  icon: string;
  label: string;
}

陈小聪's avatar
陈小聪 committed
11
export interface DefaultSettings {
何乐's avatar
何乐 committed
12 13 14 15 16
  /**
   * theme for nav menu
   */
  navTheme: MenuTheme;
  /**
duanledexianxianxian's avatar
duanledexianxianxian committed
17
   * primary color of ant design 默认#1890FF
何乐's avatar
何乐 committed
18
   */
陈小聪's avatar
陈小聪 committed
19
  primaryColor: string;
何乐's avatar
何乐 committed
20 21 22 23 24 25 26 27 28 29 30
  /**
   * nav menu position: `sidemenu` or `topmenu`
   */
  layout: 'sidemenu' | 'topmenu';
  /**
   * layout of content: `Fluid` or `Fixed`, only works when layout is topmenu
   */
  contentWidth: ContentWidth;
  /**
   * sticky header
   */
陈小聪's avatar
陈小聪 committed
31
  fixedHeader: boolean;
何乐's avatar
何乐 committed
32 33 34
  /**
   * auto hide header
   */
陈小聪's avatar
陈小聪 committed
35
  autoHideHeader: boolean;
何乐's avatar
何乐 committed
36 37 38
  /**
   * sticky siderbar
   */
陈小聪's avatar
陈小聪 committed
39
  fixSiderbar: boolean;
陈帅's avatar
陈帅 committed
40
  menu: { locale: boolean };
陈小聪's avatar
陈小聪 committed
41 42
  title: string;
  pwa: boolean;
陈帅's avatar
陈帅 committed
43 44 45 46
  // Your custom iconfont Symbol script Url
  // eg://at.alicdn.com/t/font_1039637_btcrd5co4w.js
  // 注意:如果需要图标多色,Iconfont 图标项目里要进行批量去色处理
  // Usage: https://github.com/ant-design/ant-design-pro/pull/3517
陈小聪's avatar
陈小聪 committed
47 48
  iconfontUrl: string;
  colorWeak: boolean;
duanledexianxianxian's avatar
duanledexianxianxian committed
49 50 51 52
  /**
   * 只有一种语言的时候,系统固话成一个语言,无导航栏选择框
   */
  locales: localeProps[];
陈小聪's avatar
陈小聪 committed
53 54 55
}

export default {
何乐's avatar
何乐 committed
56
  navTheme: 'dark',
duanledexianxianxian's avatar
duanledexianxianxian committed
57
  primaryColor: '#13C2C2',
何乐's avatar
何乐 committed
58 59
  layout: 'sidemenu',
  contentWidth: 'Fluid',
duanledexianxianxian's avatar
duanledexianxianxian committed
60
  fixedHeader: true,
何乐's avatar
何乐 committed
61
  autoHideHeader: false,
duanledexianxianxian's avatar
duanledexianxianxian committed
62
  fixSiderbar: true,
陈小聪's avatar
陈小聪 committed
63
  colorWeak: false,
Yu's avatar
Yu committed
64
  menu: {
陈帅's avatar
陈帅 committed
65
    locale: true,
Yu's avatar
Yu committed
66
  },
duanledexianxianxian's avatar
duanledexianxianxian committed
67
  title: 'KIM3.0平台业务架构',
期贤's avatar
期贤 committed
68
  pwa: false,
Yu's avatar
Yu committed
69
  iconfontUrl: '',
duanledexianxianxian's avatar
duanledexianxianxian committed
70 71 72 73 74 75
  locales: [
    { key: 'zh-CN', label: '简体中文', icon: '🇨🇳' },
    // { key: 'zh-TW', label: '繁体中文', icon: '🇭🇰' },
    { key: 'en-US', label: 'English', icon: '🇬🇧' },
    // { key: 'pt-BR', label: 'Português', icon: '🇧🇷' },
  ],
陈小聪's avatar
陈小聪 committed
76
} as DefaultSettings;