/** * Switch 类名定义 - 对应 MUI switchClasses.js * 100% 一比一复刻 */ export interface SwitchClasses { root: string edgeStart: string edgeEnd: string switchBase: string colorPrimary: string colorSecondary: string colorError: string colorInfo: string colorSuccess: string colorWarning: string sizeSmall: string sizeMedium: string checked: string disabled: string input: string thumb: string track: string } export function getSwitchUtilityClass(slot: string): string { return `MuiSwitch-${slot}` } const switchClasses: SwitchClasses = { root: 'MuiSwitch-root', edgeStart: 'MuiSwitch-edgeStart', edgeEnd: 'MuiSwitch-edgeEnd', switchBase: 'MuiSwitch-switchBase', colorPrimary: 'MuiSwitch-colorPrimary', colorSecondary: 'MuiSwitch-colorSecondary', colorError: 'MuiSwitch-colorError', colorInfo: 'MuiSwitch-colorInfo', colorSuccess: 'MuiSwitch-colorSuccess', colorWarning: 'MuiSwitch-colorWarning', sizeSmall: 'MuiSwitch-sizeSmall', sizeMedium: 'MuiSwitch-sizeMedium', checked: 'Mui-checked', disabled: 'Mui-disabled', input: 'MuiSwitch-input', thumb: 'MuiSwitch-thumb', track: 'MuiSwitch-track', } export default switchClasses