mirror of
https://github.com/m-xlsea/ruoyi-plus-soybean.git
synced 2025-09-24 07:49:47 +08:00
refactor(projects): remove enum
This commit is contained in:
@ -1,4 +1,9 @@
|
||||
import { EnumThemeAnimateMode, EnumThemeHorizontalMenuPosition, EnumThemeLayoutMode, EnumThemeTabMode } from '@/enum';
|
||||
import {
|
||||
themeLayoutModeOptions,
|
||||
themeTabModeOptions,
|
||||
themeHorizontalMenuPositionOptions,
|
||||
themeAnimateModeOptions
|
||||
} from '@/constants';
|
||||
import jsonSetting from './theme.json';
|
||||
|
||||
const themeColorList = [
|
||||
@ -34,12 +39,7 @@ const defaultThemeSetting: Theme.Setting = {
|
||||
layout: {
|
||||
minWidth: 900,
|
||||
mode: 'vertical',
|
||||
modeList: [
|
||||
{ value: 'vertical', label: EnumThemeLayoutMode.vertical },
|
||||
{ value: 'vertical-mix', label: EnumThemeLayoutMode['vertical-mix'] },
|
||||
{ value: 'horizontal', label: EnumThemeLayoutMode.horizontal },
|
||||
{ value: 'horizontal-mix', label: EnumThemeLayoutMode['horizontal-mix'] }
|
||||
]
|
||||
modeList: themeLayoutModeOptions
|
||||
},
|
||||
themeColor: themeColorList[0],
|
||||
themeColorList,
|
||||
@ -64,10 +64,7 @@ const defaultThemeSetting: Theme.Setting = {
|
||||
visible: true,
|
||||
height: 44,
|
||||
mode: 'chrome',
|
||||
modeList: [
|
||||
{ value: 'chrome', label: EnumThemeTabMode.chrome },
|
||||
{ value: 'button', label: EnumThemeTabMode.button }
|
||||
],
|
||||
modeList: themeTabModeOptions,
|
||||
isCache: true
|
||||
},
|
||||
sider: {
|
||||
@ -80,11 +77,7 @@ const defaultThemeSetting: Theme.Setting = {
|
||||
},
|
||||
menu: {
|
||||
horizontalPosition: 'flex-start',
|
||||
horizontalPositionList: [
|
||||
{ value: 'flex-start', label: EnumThemeHorizontalMenuPosition['flex-start'] },
|
||||
{ value: 'center', label: EnumThemeHorizontalMenuPosition.center },
|
||||
{ value: 'flex-end', label: EnumThemeHorizontalMenuPosition['flex-end'] }
|
||||
]
|
||||
horizontalPositionList: themeHorizontalMenuPositionOptions
|
||||
},
|
||||
footer: {
|
||||
fixed: false,
|
||||
@ -94,14 +87,7 @@ const defaultThemeSetting: Theme.Setting = {
|
||||
page: {
|
||||
animate: true,
|
||||
animateMode: 'fade-slide',
|
||||
animateModeList: [
|
||||
{ value: 'fade-slide', label: EnumThemeAnimateMode['fade-slide'] },
|
||||
{ value: 'fade', label: EnumThemeAnimateMode.fade },
|
||||
{ value: 'fade-bottom', label: EnumThemeAnimateMode['fade-bottom'] },
|
||||
{ value: 'fade-scale', label: EnumThemeAnimateMode['fade-scale'] },
|
||||
{ value: 'zoom-fade', label: EnumThemeAnimateMode['zoom-fade'] },
|
||||
{ value: 'zoom-out', label: EnumThemeAnimateMode['zoom-out'] }
|
||||
]
|
||||
animateModeList: themeAnimateModeOptions
|
||||
}
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user