inclusive-elements 0.5.5 → 0.5.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -21,7 +21,10 @@ const n = class n extends HTMLElement {
21
21
  escapeDeactivates: !1,
22
22
  allowOutsideClick: !0,
23
23
  preventScroll: !0,
24
- initialFocus: () => this.querySelector("[autofocus]") || void 0
24
+ initialFocus: () => this.querySelector("[autofocus]") || void 0,
25
+ // Content that is still loading may have nothing tabbable yet. The
26
+ // content element is focusable itself, so trap focus there until it does.
27
+ fallbackFocus: () => this.content ?? this
25
28
  });
26
29
  }
27
30
  static get observedAttributes() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "inclusive-elements",
3
- "version": "0.5.5",
3
+ "version": "0.5.6",
4
4
  "description": "Accessible, lightweight, unstyled implementations of common UI controls.",
5
5
  "module": "dist/inclusive-elements.js",
6
6
  "type": "module",