chore: 拆分input组件
This commit is contained in:
48
src/views/home/components/input/options.ts
Normal file
48
src/views/home/components/input/options.ts
Normal file
@@ -0,0 +1,48 @@
|
||||
import type { OptionItem, SettingOption } from './types'
|
||||
|
||||
export const styleKeys: string[] = [
|
||||
'Venetian Modern',
|
||||
'Coastal',
|
||||
'Maximalism',
|
||||
'Memphis',
|
||||
'Verdant',
|
||||
'Century Chrome',
|
||||
'Modern Revival',
|
||||
'Transitional',
|
||||
"Tuscan 2000's",
|
||||
'Kitsch-core',
|
||||
'Bauhaus',
|
||||
'Constructivism',
|
||||
'Nordic Noir',
|
||||
'Dopamine',
|
||||
'Squiggle'
|
||||
]
|
||||
|
||||
export const optionTagOrder = ['type', 'area', 'style'] as const
|
||||
|
||||
export const createTypeOptions = (): OptionItem[] => [
|
||||
{
|
||||
label: 'Input.types.sofa',
|
||||
value: 'Sofa'
|
||||
},
|
||||
{
|
||||
label: 'Input.types.desk',
|
||||
value: 'Desk'
|
||||
},
|
||||
{
|
||||
label: 'Input.types.chair',
|
||||
value: 'Chair'
|
||||
}
|
||||
]
|
||||
|
||||
export const createStyleOptions = (): OptionItem[] =>
|
||||
styleKeys.map((key) => ({
|
||||
label: key,
|
||||
value: key
|
||||
}))
|
||||
|
||||
export const createSettingOptions = (): SettingOption[] => [
|
||||
{ label: 'Input.settingOptions.first', value: 50 },
|
||||
{ label: 'Input.settingOptions.second', value: 50 },
|
||||
{ label: 'Input.settingOptions.third', value: 50 }
|
||||
]
|
||||
Reference in New Issue
Block a user