File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -114,6 +114,8 @@ export interface CheckboxProps extends ChoiceBleedProps {
114114 error? : Error | boolean ;
115115 /** Indicates the tone of the checkbox */
116116 tone? : ' magic' ;
117+ /** Disable auto focus to input when click to checkbox*/
118+ disableFocus? : boolean ;
117119}
118120
119121type CheckboxSlots = {
@@ -233,7 +235,12 @@ const handleOnClick = () => {
233235 }
234236
235237 model .value = inputNode .value .checked ;
236- inputNode .value .focus ();
238+
239+ // Props use for fix case Checkbox use as slot of Combobox Component -> auto close popover when change focus
240+ if (! props .disableFocus ) {
241+ inputNode .value .focus ();
242+ }
243+
237244 emits (' change' , inputNode .value .checked , props .value || id .value );
238245};
239246 </script >
You can’t perform that action at this time.
0 commit comments