Skip to content

Commit

Permalink
fix: defaultChecked prop in checkbox and switch
Browse files Browse the repository at this point in the history
  • Loading branch information
Cr0zy07 committed Jan 4, 2024
1 parent e616e8d commit 31ca72d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/components/checkbox/src/bubble-input.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ const bubbleInput = defineComponent({
return () => h('input', {
'type': 'checkbox',
'aria-hidden': true,
'defaultChecked': isIndeterminate(checked.value) ? false : checked.value,
'defaultChecked': isIndeterminate(checked.value),
...mergeProps(attrs, otherProps, emits),
'tabIndex': -1,
'ref': inputRef,
Expand Down
2 changes: 1 addition & 1 deletion packages/components/switch/src/bubble-input.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ const bubbleInput = defineComponent({
return () => h('input', {
'type': 'checkbox',
'aria-hidden': true,
'defaultChecked': checked.value ? false : checked.value,
'defaultChecked': checked.value,
...mergeProps(attrs, otherProps, emits),
'tabIndex': -1,
'ref': inputRef,
Expand Down

0 comments on commit 31ca72d

Please sign in to comment.