Skip to content

Commit 8a19e62

Browse files
committed
Blur checkbox on disabled. Fixes issues with shadow roots
1 parent fab151b commit 8a19e62

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

elements/howto-checkbox/howto-checkbox.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -182,8 +182,7 @@
182182
this.removeAttribute('tabindex');
183183
// If the focus is currently on this element, unfocus it by
184184
// calling the `HTMLElement.blur()` method.
185-
if (document.activeElement === this)
186-
this.blur();
185+
this.blur();
187186
} else {
188187
this.setAttribute('tabindex', '0');
189188
}

0 commit comments

Comments
 (0)