Browse Source

fix: checkbox a11y focus error (#897)

YyumeiZhang 3 years ago
parent
commit
015d593716

+ 1 - 0
packages/semi-foundation/checkbox/checkboxFoundation.ts

@@ -144,6 +144,7 @@ class CheckboxFoundation<P = Record<string, any>, S = Record<string, any>> exten
     }
 
     handleBlur = () => {
+        this.clickState = false;
         this._adapter.setFocusVisible(false);
     }
 

+ 0 - 2
packages/semi-ui/checkbox/checkbox.tsx

@@ -111,8 +111,6 @@ class Checkbox extends BaseComponent<CheckboxProps, CheckboxState> {
     }
 
     foundation: CheckboxFoundation;
-    addonId: string;
-    extraId: string;
     constructor(props: CheckboxProps) {
         super(props);