mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-14 09:20:51 +08:00
2f38edd715
* fix(components): [select] inner input height is inconsistent with select * Update packages/constants/size.ts Co-authored-by: JeremyWuuuuu <15975785+JeremyWuuuuu@users.noreply.github.com> Co-authored-by: JeremyWuuuuu <15975785+JeremyWuuuuu@users.noreply.github.com>
14 lines
338 B
TypeScript
14 lines
338 B
TypeScript
export const componentSizes = ['', 'default', 'small', 'large'] as const
|
|
|
|
export type ComponentSize = typeof componentSizes[number]
|
|
|
|
export const componentSizeMap = {
|
|
large: 40,
|
|
default: 32,
|
|
small: 24,
|
|
} as const
|
|
|
|
export const getComponentSize = (size: ComponentSize = 'default') => {
|
|
return componentSizeMap[size || 'default']
|
|
}
|