@y14e/disclosure-css 2.0.10 → 2.0.11

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.
package/README.md CHANGED
@@ -10,14 +10,14 @@ npm i @y14e/disclosure-css
10
10
 
11
11
  ```ts
12
12
  // npm
13
- import { Disclosure } from "@y14e/disclosure-css";
13
+ import { Disclosure } from '@y14e/disclosure-css';
14
14
 
15
15
  // CDNs
16
- import { Disclosure } from "https://esm.sh/@y14e/disclosure-css@2.0.10";
16
+ import { Disclosure } from 'https://esm.sh/@y14e/disclosure-css@2.0.11';
17
17
  // or
18
- import { Disclosure } from "https://cdn.jsdelivr.net/npm/@y14e/disclosure-css@2.0.10/+esm";
18
+ import { Disclosure } from 'https://cdn.jsdelivr.net/npm/@y14e/disclosure-css@2.0.11/+esm';
19
19
  // or
20
- import { Disclosure } from "https://esm.unpkg.com/@y14e/disclosure-css@2.0.10";
20
+ import { Disclosure } from 'https://esm.unpkg.com/@y14e/disclosure-css@2.0.11';
21
21
  ```
22
22
 
23
23
  ## Usage
@@ -43,7 +43,7 @@ interface DisclosureOptions {
43
43
  Override the global default settings applied to all disclosure instances.
44
44
 
45
45
  ```ts
46
- import { Disclosure } from "@y14e/disclosure-css";
46
+ import { Disclosure } from '@y14e/disclosure-css';
47
47
 
48
48
  Disclosure.defaults = {
49
49
  collapsible: false,
@@ -37,16 +37,16 @@ function restoreAttributes(element_or_elements) {
37
37
  }
38
38
  function saveAttributes(element_or_elements, name_or_names) {
39
39
  const names = Array.isArray(name_or_names) ? name_or_names : [name_or_names];
40
- (Array.isArray(element_or_elements) ? element_or_elements : [element_or_elements]).forEach((element) => {
40
+ for (const element of Array.isArray(element_or_elements) ? element_or_elements : [element_or_elements]) {
41
41
  let snapshot = snapshots.get(element);
42
42
  if (!snapshot) {
43
43
  snapshot = /* @__PURE__ */ new Map();
44
44
  snapshots.set(element, snapshot);
45
45
  }
46
- names.forEach((name) => {
46
+ for (const name of names) {
47
47
  snapshot.set(name, element.getAttribute(name));
48
- });
49
- });
48
+ }
49
+ }
50
50
  }
51
51
  function isValid(element, name, token) {
52
52
  if (!(element instanceof Element)) {
@@ -91,7 +91,7 @@ function resolveOptions(options) {
91
91
  }
92
92
 
93
93
  // node_modules/power-focusable/dist/index.js
94
- var FOCUSABLE_SELECTOR = `:is(a[href], area[href], button, embed, iframe, input:not([type="hidden" i]), object, select, details > summary:first-of-type, textarea, [contenteditable]:not([contenteditable="false" i]), [controls], [tabindex]):not(:disabled, [hidden], [inert], [tabindex="-1"])`;
94
+ var FOCUSABLE_SELECTOR = ':is(a[href], area[href], button, embed, iframe, input:not([type="hidden" i]), object, select, details > summary:first-of-type, textarea, [contenteditable]:not([contenteditable="false" i]), [controls], [tabindex]):not(:disabled, [hidden], [inert], [tabindex="-1"])';
95
95
  var FOCUSABLE_SELECTOR_WITH_NEGATIVE_TABINDEX = FOCUSABLE_SELECTOR.replace(
96
96
  /(,\s*)?\[tabindex="-1"\]/g,
97
97
  ""
@@ -117,29 +117,19 @@ function getFocusables(container = document.body, options = {}) {
117
117
  }) || include?.(node)) {
118
118
  candidates[candidates.length] = node;
119
119
  }
120
- const children2 = composed ? getComposedChildren(node) : getChildren(node);
121
- for (let i = 0, l = children2.length; i < l; i++) {
122
- const child = children2[i];
123
- child && traverse2(child);
124
- }
120
+ (composed ? getComposedChildren(node) : getChildren(node)).map(traverse2);
125
121
  };
126
- const children = composed ? getComposedChildren(container) : getChildren(container);
127
- for (let i = 0, l = children.length; i < l; i++) {
128
- const child = children[i];
129
- child && traverse2(child);
130
- }
122
+ (composed ? getComposedChildren(container) : getChildren(container)).map(
123
+ traverse2
124
+ );
131
125
  } else {
132
- const matches = container.querySelectorAll(
126
+ for (const match of container.querySelectorAll(
133
127
  skipNegativeTabIndexCheck ? FOCUSABLE_SELECTOR_WITH_NEGATIVE_TABINDEX : FOCUSABLE_SELECTOR
134
- );
135
- for (let i = 0, l = matches.length; i < l; i++) {
136
- const matched = matches[i];
137
- if (matched && isFocusable(matched, {
128
+ )) {
129
+ match && isFocusable(match, {
138
130
  skipNegativeTabIndexCheck,
139
131
  skipVisibilityCheck
140
- })) {
141
- candidates[candidates.length] = matched;
142
- }
132
+ }) && candidates.push(match);
143
133
  }
144
134
  }
145
135
  return normalizeRadioGroup(
@@ -206,8 +196,7 @@ function isDisabledDeep(element) {
206
196
  }
207
197
  function normalizeRadioGroup(elements) {
208
198
  let map = null;
209
- for (let i = 0, l = elements.length; i < l; i++) {
210
- const element = elements[i];
199
+ for (const element of elements) {
211
200
  if (!(element instanceof HTMLInputElement)) {
212
201
  continue;
213
202
  }
@@ -257,23 +246,10 @@ function normalizeRadioGroup(elements) {
257
246
  function sortByTabIndex(elements) {
258
247
  const ordered = [];
259
248
  const natural = [];
260
- for (let i = 0, l = elements.length; i < l; i++) {
261
- const element = elements[i];
262
- if (element) {
263
- const target = getTabIndex(element) > 0 ? ordered : natural;
264
- target[target.length] = element;
265
- }
249
+ for (const element of elements) {
250
+ (getTabIndex(element) > 0 ? ordered : natural).push(element);
266
251
  }
267
- ordered.sort((a, b) => getTabIndex(a) - getTabIndex(b));
268
- let count = 0;
269
- const sorted = new Array(ordered.length + natural.length);
270
- for (let i = 0, l = ordered.length; i < l; i++) {
271
- sorted[count++] = ordered[i];
272
- }
273
- for (let i = 0, l = natural.length; i < l; i++) {
274
- sorted[count++] = natural[i];
275
- }
276
- return sorted;
252
+ return ordered.sort((a, b) => getTabIndex(a) - getTabIndex(b)).concat(natural);
277
253
  }
278
254
  function getComposedChildren(node) {
279
255
  if (node instanceof ShadowRoot) {
@@ -414,10 +390,10 @@ var RovingTabIndex = class _RovingTabIndex {
414
390
  this.#isDestroyed = true;
415
391
  this.#controller?.abort();
416
392
  this.#controller = null;
417
- this.#focusables.forEach((focusable) => {
393
+ for (const focusable of this.#focusables) {
418
394
  _RovingTabIndex.#initialized.delete(focusable);
419
395
  restoreAttributes(focusable);
420
- });
396
+ }
421
397
  this.#focusables.clear();
422
398
  this.#focusablesByFirstChar.clear();
423
399
  }
@@ -561,17 +537,17 @@ var RovingTabIndex = class _RovingTabIndex {
561
537
  caseInsensitive: true
562
538
  });
563
539
  }
564
- keys.forEach((key) => {
540
+ for (const key of keys) {
565
541
  const focusables = this.#focusablesByFirstChar.get(key) ?? [];
566
542
  focusables.push(focusable);
567
543
  this.#focusablesByFirstChar.set(key, focusables);
568
- });
544
+ }
569
545
  }
570
546
  if (!navigationOnly) {
571
547
  if (active && this.#focusables.has(active)) {
572
- this.#focusables.forEach((focusable) => {
548
+ for (const focusable of this.#focusables) {
573
549
  focusable.setAttribute("tabindex", focusable === active ? "0" : "-1");
574
- });
550
+ }
575
551
  } else {
576
552
  [...this.#focusables].forEach((focusable, i) => {
577
553
  focusable.setAttribute("tabindex", i || noStart ? "-1" : "0");
@@ -601,6 +577,7 @@ var RovingTabIndex = class _RovingTabIndex {
601
577
  typeahead = false,
602
578
  wrap = false
603
579
  } = options;
580
+ direction = direction.toLowerCase();
604
581
  if (!["both", "horizontal", "vertical"].includes(direction)) {
605
582
  console.warn("Invalid direction option. Fallback: 'both'.");
606
583
  direction = "both";
@@ -753,14 +730,14 @@ var Disclosure = class _Disclosure {
753
730
  ]);
754
731
  this.#controller = new AbortController();
755
732
  const { signal } = this.#controller;
756
- this.#summaryElements.forEach((summary) => {
733
+ for (const summary of this.#summaryElements) {
757
734
  if (!this.#isFocusable(summary)) {
758
735
  summary.setAttribute("aria-disabled", "true");
759
736
  summary.setAttribute("tabindex", "-1");
760
737
  summary.style.setProperty("pointer-events", "none");
761
738
  }
762
739
  summary.addEventListener("click", this.#onSummaryClick, { signal });
763
- });
740
+ }
764
741
  this.#cleanupRovingTabIndex = createRovingTabIndex(this.#rootElement, {
765
742
  direction: "vertical",
766
743
  navigationOnly: true,
@@ -812,7 +789,7 @@ var Disclosure = class _Disclosure {
812
789
  * WAI-ARIA compliant disclosure pattern implementation in TypeScript.
813
790
  * Using the <details> and <summary> element.
814
791
  *
815
- * @version 2.0.10
792
+ * @version 2.0.11
816
793
  * @author Yusuke Kamiyamane
817
794
  * @license MIT
818
795
  * @copyright Copyright (c) Yusuke Kamiyamane
@@ -824,7 +801,7 @@ var Disclosure = class _Disclosure {
824
801
  (**
825
802
  * Attribute Utils
826
803
  *
827
- * @version 2.0.8
804
+ * @version 2.0.10
828
805
  * @author Yusuke Kamiyamane
829
806
  * @license MIT
830
807
  * @copyright Copyright (c) Yusuke Kamiyamane
@@ -837,7 +814,7 @@ power-focusable/dist/index.js:
837
814
  * High-precision focus management utility with full composed tree support.
838
815
  * Handles complex focus rules including tabindex ordering, radio groups, inert.
839
816
  *
840
- * @version 4.3.29
817
+ * @version 4.3.30
841
818
  * @author Yusuke Kamiyamane
842
819
  * @license MIT
843
820
  * @copyright Copyright (c) Yusuke Kamiyamane
@@ -850,7 +827,7 @@ power-focusable/dist/index.js:
850
827
  * Lightweight roving tabindex utility with fully focus management.
851
828
  * Designed for accessible menus, tabs, toolbars, and composite widgets.
852
829
  *
853
- * @version 3.1.27
830
+ * @version 3.1.28
854
831
  * @author Yusuke Kamiyamane
855
832
  * @license MIT
856
833
  * @copyright Copyright (c) Yusuke Kamiyamane
@@ -35,16 +35,16 @@ function restoreAttributes(element_or_elements) {
35
35
  }
36
36
  function saveAttributes(element_or_elements, name_or_names) {
37
37
  const names = Array.isArray(name_or_names) ? name_or_names : [name_or_names];
38
- (Array.isArray(element_or_elements) ? element_or_elements : [element_or_elements]).forEach((element) => {
38
+ for (const element of Array.isArray(element_or_elements) ? element_or_elements : [element_or_elements]) {
39
39
  let snapshot = snapshots.get(element);
40
40
  if (!snapshot) {
41
41
  snapshot = /* @__PURE__ */ new Map();
42
42
  snapshots.set(element, snapshot);
43
43
  }
44
- names.forEach((name) => {
44
+ for (const name of names) {
45
45
  snapshot.set(name, element.getAttribute(name));
46
- });
47
- });
46
+ }
47
+ }
48
48
  }
49
49
  function isValid(element, name, token) {
50
50
  if (!(element instanceof Element)) {
@@ -89,7 +89,7 @@ function resolveOptions(options) {
89
89
  }
90
90
 
91
91
  // node_modules/power-focusable/dist/index.js
92
- var FOCUSABLE_SELECTOR = `:is(a[href], area[href], button, embed, iframe, input:not([type="hidden" i]), object, select, details > summary:first-of-type, textarea, [contenteditable]:not([contenteditable="false" i]), [controls], [tabindex]):not(:disabled, [hidden], [inert], [tabindex="-1"])`;
92
+ var FOCUSABLE_SELECTOR = ':is(a[href], area[href], button, embed, iframe, input:not([type="hidden" i]), object, select, details > summary:first-of-type, textarea, [contenteditable]:not([contenteditable="false" i]), [controls], [tabindex]):not(:disabled, [hidden], [inert], [tabindex="-1"])';
93
93
  var FOCUSABLE_SELECTOR_WITH_NEGATIVE_TABINDEX = FOCUSABLE_SELECTOR.replace(
94
94
  /(,\s*)?\[tabindex="-1"\]/g,
95
95
  ""
@@ -115,29 +115,19 @@ function getFocusables(container = document.body, options = {}) {
115
115
  }) || include?.(node)) {
116
116
  candidates[candidates.length] = node;
117
117
  }
118
- const children2 = composed ? getComposedChildren(node) : getChildren(node);
119
- for (let i = 0, l = children2.length; i < l; i++) {
120
- const child = children2[i];
121
- child && traverse2(child);
122
- }
118
+ (composed ? getComposedChildren(node) : getChildren(node)).map(traverse2);
123
119
  };
124
- const children = composed ? getComposedChildren(container) : getChildren(container);
125
- for (let i = 0, l = children.length; i < l; i++) {
126
- const child = children[i];
127
- child && traverse2(child);
128
- }
120
+ (composed ? getComposedChildren(container) : getChildren(container)).map(
121
+ traverse2
122
+ );
129
123
  } else {
130
- const matches = container.querySelectorAll(
124
+ for (const match of container.querySelectorAll(
131
125
  skipNegativeTabIndexCheck ? FOCUSABLE_SELECTOR_WITH_NEGATIVE_TABINDEX : FOCUSABLE_SELECTOR
132
- );
133
- for (let i = 0, l = matches.length; i < l; i++) {
134
- const matched = matches[i];
135
- if (matched && isFocusable(matched, {
126
+ )) {
127
+ match && isFocusable(match, {
136
128
  skipNegativeTabIndexCheck,
137
129
  skipVisibilityCheck
138
- })) {
139
- candidates[candidates.length] = matched;
140
- }
130
+ }) && candidates.push(match);
141
131
  }
142
132
  }
143
133
  return normalizeRadioGroup(
@@ -204,8 +194,7 @@ function isDisabledDeep(element) {
204
194
  }
205
195
  function normalizeRadioGroup(elements) {
206
196
  let map = null;
207
- for (let i = 0, l = elements.length; i < l; i++) {
208
- const element = elements[i];
197
+ for (const element of elements) {
209
198
  if (!(element instanceof HTMLInputElement)) {
210
199
  continue;
211
200
  }
@@ -255,23 +244,10 @@ function normalizeRadioGroup(elements) {
255
244
  function sortByTabIndex(elements) {
256
245
  const ordered = [];
257
246
  const natural = [];
258
- for (let i = 0, l = elements.length; i < l; i++) {
259
- const element = elements[i];
260
- if (element) {
261
- const target = getTabIndex(element) > 0 ? ordered : natural;
262
- target[target.length] = element;
263
- }
247
+ for (const element of elements) {
248
+ (getTabIndex(element) > 0 ? ordered : natural).push(element);
264
249
  }
265
- ordered.sort((a, b) => getTabIndex(a) - getTabIndex(b));
266
- let count = 0;
267
- const sorted = new Array(ordered.length + natural.length);
268
- for (let i = 0, l = ordered.length; i < l; i++) {
269
- sorted[count++] = ordered[i];
270
- }
271
- for (let i = 0, l = natural.length; i < l; i++) {
272
- sorted[count++] = natural[i];
273
- }
274
- return sorted;
250
+ return ordered.sort((a, b) => getTabIndex(a) - getTabIndex(b)).concat(natural);
275
251
  }
276
252
  function getComposedChildren(node) {
277
253
  if (node instanceof ShadowRoot) {
@@ -412,10 +388,10 @@ var RovingTabIndex = class _RovingTabIndex {
412
388
  this.#isDestroyed = true;
413
389
  this.#controller?.abort();
414
390
  this.#controller = null;
415
- this.#focusables.forEach((focusable) => {
391
+ for (const focusable of this.#focusables) {
416
392
  _RovingTabIndex.#initialized.delete(focusable);
417
393
  restoreAttributes(focusable);
418
- });
394
+ }
419
395
  this.#focusables.clear();
420
396
  this.#focusablesByFirstChar.clear();
421
397
  }
@@ -559,17 +535,17 @@ var RovingTabIndex = class _RovingTabIndex {
559
535
  caseInsensitive: true
560
536
  });
561
537
  }
562
- keys.forEach((key) => {
538
+ for (const key of keys) {
563
539
  const focusables = this.#focusablesByFirstChar.get(key) ?? [];
564
540
  focusables.push(focusable);
565
541
  this.#focusablesByFirstChar.set(key, focusables);
566
- });
542
+ }
567
543
  }
568
544
  if (!navigationOnly) {
569
545
  if (active && this.#focusables.has(active)) {
570
- this.#focusables.forEach((focusable) => {
546
+ for (const focusable of this.#focusables) {
571
547
  focusable.setAttribute("tabindex", focusable === active ? "0" : "-1");
572
- });
548
+ }
573
549
  } else {
574
550
  [...this.#focusables].forEach((focusable, i) => {
575
551
  focusable.setAttribute("tabindex", i || noStart ? "-1" : "0");
@@ -599,6 +575,7 @@ var RovingTabIndex = class _RovingTabIndex {
599
575
  typeahead = false,
600
576
  wrap = false
601
577
  } = options;
578
+ direction = direction.toLowerCase();
602
579
  if (!["both", "horizontal", "vertical"].includes(direction)) {
603
580
  console.warn("Invalid direction option. Fallback: 'both'.");
604
581
  direction = "both";
@@ -751,14 +728,14 @@ var Disclosure = class _Disclosure {
751
728
  ]);
752
729
  this.#controller = new AbortController();
753
730
  const { signal } = this.#controller;
754
- this.#summaryElements.forEach((summary) => {
731
+ for (const summary of this.#summaryElements) {
755
732
  if (!this.#isFocusable(summary)) {
756
733
  summary.setAttribute("aria-disabled", "true");
757
734
  summary.setAttribute("tabindex", "-1");
758
735
  summary.style.setProperty("pointer-events", "none");
759
736
  }
760
737
  summary.addEventListener("click", this.#onSummaryClick, { signal });
761
- });
738
+ }
762
739
  this.#cleanupRovingTabIndex = createRovingTabIndex(this.#rootElement, {
763
740
  direction: "vertical",
764
741
  navigationOnly: true,
@@ -810,7 +787,7 @@ var Disclosure = class _Disclosure {
810
787
  * WAI-ARIA compliant disclosure pattern implementation in TypeScript.
811
788
  * Using the <details> and <summary> element.
812
789
  *
813
- * @version 2.0.10
790
+ * @version 2.0.11
814
791
  * @author Yusuke Kamiyamane
815
792
  * @license MIT
816
793
  * @copyright Copyright (c) Yusuke Kamiyamane
@@ -822,7 +799,7 @@ var Disclosure = class _Disclosure {
822
799
  (**
823
800
  * Attribute Utils
824
801
  *
825
- * @version 2.0.8
802
+ * @version 2.0.10
826
803
  * @author Yusuke Kamiyamane
827
804
  * @license MIT
828
805
  * @copyright Copyright (c) Yusuke Kamiyamane
@@ -835,7 +812,7 @@ power-focusable/dist/index.js:
835
812
  * High-precision focus management utility with full composed tree support.
836
813
  * Handles complex focus rules including tabindex ordering, radio groups, inert.
837
814
  *
838
- * @version 4.3.29
815
+ * @version 4.3.30
839
816
  * @author Yusuke Kamiyamane
840
817
  * @license MIT
841
818
  * @copyright Copyright (c) Yusuke Kamiyamane
@@ -848,7 +825,7 @@ power-focusable/dist/index.js:
848
825
  * Lightweight roving tabindex utility with fully focus management.
849
826
  * Designed for accessible menus, tabs, toolbars, and composite widgets.
850
827
  *
851
- * @version 3.1.27
828
+ * @version 3.1.28
852
829
  * @author Yusuke Kamiyamane
853
830
  * @license MIT
854
831
  * @copyright Copyright (c) Yusuke Kamiyamane
package/dist/index.cjs CHANGED
@@ -131,14 +131,14 @@ var Disclosure = class _Disclosure {
131
131
  ]);
132
132
  this.#controller = new AbortController();
133
133
  const { signal } = this.#controller;
134
- this.#summaryElements.forEach((summary) => {
134
+ for (const summary of this.#summaryElements) {
135
135
  if (!this.#isFocusable(summary)) {
136
136
  summary.setAttribute("aria-disabled", "true");
137
137
  summary.setAttribute("tabindex", "-1");
138
138
  summary.style.setProperty("pointer-events", "none");
139
139
  }
140
140
  summary.addEventListener("click", this.#onSummaryClick, { signal });
141
- });
141
+ }
142
142
  this.#cleanupRovingTabIndex = rovingTabindex.createRovingTabIndex(this.#rootElement, {
143
143
  direction: "vertical",
144
144
  navigationOnly: true,
@@ -190,7 +190,7 @@ var Disclosure = class _Disclosure {
190
190
  * WAI-ARIA compliant disclosure pattern implementation in TypeScript.
191
191
  * Using the <details> and <summary> element.
192
192
  *
193
- * @version 2.0.10
193
+ * @version 2.0.11
194
194
  * @author Yusuke Kamiyamane
195
195
  * @license MIT
196
196
  * @copyright Copyright (c) Yusuke Kamiyamane
package/dist/index.d.cts CHANGED
@@ -3,7 +3,7 @@
3
3
  * WAI-ARIA compliant disclosure pattern implementation in TypeScript.
4
4
  * Using the <details> and <summary> element.
5
5
  *
6
- * @version 2.0.10
6
+ * @version 2.0.11
7
7
  * @author Yusuke Kamiyamane
8
8
  * @license MIT
9
9
  * @copyright Copyright (c) Yusuke Kamiyamane
package/dist/index.d.ts CHANGED
@@ -3,7 +3,7 @@
3
3
  * WAI-ARIA compliant disclosure pattern implementation in TypeScript.
4
4
  * Using the <details> and <summary> element.
5
5
  *
6
- * @version 2.0.10
6
+ * @version 2.0.11
7
7
  * @author Yusuke Kamiyamane
8
8
  * @license MIT
9
9
  * @copyright Copyright (c) Yusuke Kamiyamane
package/dist/index.js CHANGED
@@ -109,14 +109,14 @@ var Disclosure = class _Disclosure {
109
109
  ]);
110
110
  this.#controller = new AbortController();
111
111
  const { signal } = this.#controller;
112
- this.#summaryElements.forEach((summary) => {
112
+ for (const summary of this.#summaryElements) {
113
113
  if (!this.#isFocusable(summary)) {
114
114
  summary.setAttribute("aria-disabled", "true");
115
115
  summary.setAttribute("tabindex", "-1");
116
116
  summary.style.setProperty("pointer-events", "none");
117
117
  }
118
118
  summary.addEventListener("click", this.#onSummaryClick, { signal });
119
- });
119
+ }
120
120
  this.#cleanupRovingTabIndex = createRovingTabIndex(this.#rootElement, {
121
121
  direction: "vertical",
122
122
  navigationOnly: true,
@@ -168,7 +168,7 @@ var Disclosure = class _Disclosure {
168
168
  * WAI-ARIA compliant disclosure pattern implementation in TypeScript.
169
169
  * Using the <details> and <summary> element.
170
170
  *
171
- * @version 2.0.10
171
+ * @version 2.0.11
172
172
  * @author Yusuke Kamiyamane
173
173
  * @license MIT
174
174
  * @copyright Copyright (c) Yusuke Kamiyamane
package/package.json CHANGED
@@ -1,11 +1,27 @@
1
1
  {
2
2
  "name": "@y14e/disclosure-css",
3
- "version": "2.0.10",
3
+ "version": "2.0.11",
4
4
  "description": "WAI-ARIA compliant disclosure pattern implementation in TypeScript",
5
+ "keywords": [
6
+ "a11y",
7
+ "accessibility",
8
+ "disclosure",
9
+ "collapsible",
10
+ "component",
11
+ "typescript",
12
+ "utility"
13
+ ],
14
+ "homepage": "https://github.com/y14e/disclosure-css#readme",
15
+ "bugs": {
16
+ "url": "https://github.com/y14e/disclosure-css/issues"
17
+ },
18
+ "repository": {
19
+ "type": "git",
20
+ "url": "git+https://github.com/y14e/disclosure-css.git"
21
+ },
22
+ "license": "MIT",
23
+ "author": "Yusuke Kamiyamane",
5
24
  "type": "module",
6
- "main": "./dist/index.cjs",
7
- "module": "./dist/index.js",
8
- "types": "./dist/index.d.ts",
9
25
  "exports": {
10
26
  ".": {
11
27
  "types": "./dist/index.d.ts",
@@ -13,6 +29,9 @@
13
29
  "require": "./dist/index.cjs"
14
30
  }
15
31
  },
32
+ "main": "./dist/index.cjs",
33
+ "module": "./dist/index.js",
34
+ "types": "./dist/index.d.ts",
16
35
  "files": [
17
36
  "dist",
18
37
  "LICENSE",
@@ -20,28 +39,9 @@
20
39
  ],
21
40
  "scripts": {
22
41
  "build": "tsup",
23
- "prepublishOnly": "npm run build",
24
- "lint": "tsc --noEmit"
25
- },
26
- "keywords": [
27
- "a11y",
28
- "accessibility",
29
- "disclosure",
30
- "collapsible",
31
- "component",
32
- "typescript",
33
- "utility"
34
- ],
35
- "author": "Yusuke Kamiyamane",
36
- "license": "MIT",
37
- "repository": {
38
- "type": "git",
39
- "url": "git+https://github.com/y14e/disclosure-css.git"
42
+ "lint": "tsc --noEmit",
43
+ "prepublishOnly": "npm run build"
40
44
  },
41
- "bugs": {
42
- "url": "https://github.com/y14e/disclosure-css/issues"
43
- },
44
- "homepage": "https://github.com/y14e/disclosure-css#readme",
45
45
  "devDependencies": {
46
46
  "bun-types": "latest",
47
47
  "tsup": "^8.0.0",
@@ -54,7 +54,7 @@
54
54
  "esbuild": true
55
55
  },
56
56
  "dependencies": {
57
- "@y14e/attribute-utils": "^2.0.8",
58
- "@y14e/roving-tabindex": "^3.1.27"
57
+ "@y14e/attribute-utils": "^2.0.10",
58
+ "@y14e/roving-tabindex": "^3.1.28"
59
59
  }
60
60
  }