Toggle: fix toggle acting as a submit button in forms

This commit is contained in:
Alex Gleason 2023-04-10 15:25:42 -05:00
parent 2315dbdae5
commit 0e1da7512c
No known key found for this signature in database
GPG key ID: 7211D1F99744FBB7

View file

@ -26,6 +26,7 @@ const Toggle: React.FC<IToggle> = ({ id, size = 'md', name, checked, onChange, r
'cursor-default': disabled,
})}
onClick={handleClick}
type='button'
>
<div className={clsx('rounded-full bg-white transition-transform', {
'h-4.5 w-4.5': size === 'sm',