import { ForwardedRef, forwardRef } from 'react'; import { colors } from '@/libs/themes'; //type type Type = { onClick?: () => void; active: boolean; width?: number; height?: number; children: never[]; }; // const Switch = forwardRef((props: Type, ref: ForwardedRef) => { return (
props.onClick && props.onClick()} css={{ position: 'relative', minWidth: props?.width ?? 48, minHeight: props?.height ?? 30, borderRadius: 1000, backgroundColor: '#eee', }} >
{''}
); }); export default Switch; const absoluteT = { position: 'absolute', transition: '0.3s ease-in-out', borderRadius: 100, };