@y14e/tabs 1.5.4 → 1.5.5

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/tabs
10
10
 
11
11
  ```ts
12
12
  // npm
13
- import Tabs from '@y14e/tabs@1.5.4';
13
+ import Tabs from '@y14e/tabs@1.5.5';
14
14
 
15
15
  // CDNs
16
- import Tabs from 'https://esm.sh/@y14e/tabs@1.5.4';
16
+ import Tabs from 'https://esm.sh/@y14e/tabs@1.5.5';
17
17
  // or
18
- import Tabs from 'https://cdn.jsdelivr.net/npm/@y14e/tabs@1.5.4/+esm';
18
+ import Tabs from 'https://cdn.jsdelivr.net/npm/@y14e/tabs@1.5.5/+esm';
19
19
  // or
20
- import Tabs from 'https://esm.unpkg.com/@y14e/tabs@1.5.4';
20
+ import Tabs from 'https://esm.unpkg.com/@y14e/tabs@1.5.5';
21
21
  ```
22
22
 
23
23
  ## Usage
package/dist/index.cjs CHANGED
@@ -1043,20 +1043,19 @@ var Tabs = class _Tabs {
1043
1043
  };
1044
1044
  }
1045
1045
  #onAnimationFinish() {
1046
- if (!this.#contentElement) {
1047
- return;
1048
- }
1049
- const { style } = this.#contentElement;
1050
- style.removeProperty("block-size");
1051
- style.removeProperty("overflow");
1052
- style.removeProperty("position");
1046
+ ["block-size", "overflow", "position"].forEach((name) => {
1047
+ this.#contentElement?.style.removeProperty(name);
1048
+ });
1053
1049
  this.#panelElements.forEach((panel) => {
1054
- const { style: style2 } = panel;
1055
- style2.removeProperty("content-visibility");
1056
- style2.removeProperty("display");
1057
- style2.removeProperty("inline-size");
1058
- style2.removeProperty("opacity");
1059
- style2.removeProperty("position");
1050
+ [
1051
+ "content-visibility",
1052
+ "display",
1053
+ "inline-size",
1054
+ "opacity",
1055
+ "position"
1056
+ ].forEach((name) => {
1057
+ panel.style.removeProperty(name);
1058
+ });
1060
1059
  });
1061
1060
  this.#rootElement.removeAttribute("data-tabs-animating");
1062
1061
  }
@@ -1146,7 +1145,7 @@ function isFocusable2(element) {
1146
1145
  * Tabs
1147
1146
  * WAI-ARIA compliant tabs pattern implementation in TypeScript.
1148
1147
  *
1149
- * @version 1.5.4
1148
+ * @version 1.5.5
1150
1149
  * @author Yusuke Kamiyamane
1151
1150
  * @license MIT
1152
1151
  * @copyright Copyright (c) Yusuke Kamiyamane
package/dist/index.d.cts CHANGED
@@ -2,7 +2,7 @@
2
2
  * Tabs
3
3
  * WAI-ARIA compliant tabs pattern implementation in TypeScript.
4
4
  *
5
- * @version 1.5.4
5
+ * @version 1.5.5
6
6
  * @author Yusuke Kamiyamane
7
7
  * @license MIT
8
8
  * @copyright Copyright (c) Yusuke Kamiyamane
package/dist/index.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  * Tabs
3
3
  * WAI-ARIA compliant tabs pattern implementation in TypeScript.
4
4
  *
5
- * @version 1.5.4
5
+ * @version 1.5.5
6
6
  * @author Yusuke Kamiyamane
7
7
  * @license MIT
8
8
  * @copyright Copyright (c) Yusuke Kamiyamane
package/dist/index.js CHANGED
@@ -1041,20 +1041,19 @@ var Tabs = class _Tabs {
1041
1041
  };
1042
1042
  }
1043
1043
  #onAnimationFinish() {
1044
- if (!this.#contentElement) {
1045
- return;
1046
- }
1047
- const { style } = this.#contentElement;
1048
- style.removeProperty("block-size");
1049
- style.removeProperty("overflow");
1050
- style.removeProperty("position");
1044
+ ["block-size", "overflow", "position"].forEach((name) => {
1045
+ this.#contentElement?.style.removeProperty(name);
1046
+ });
1051
1047
  this.#panelElements.forEach((panel) => {
1052
- const { style: style2 } = panel;
1053
- style2.removeProperty("content-visibility");
1054
- style2.removeProperty("display");
1055
- style2.removeProperty("inline-size");
1056
- style2.removeProperty("opacity");
1057
- style2.removeProperty("position");
1048
+ [
1049
+ "content-visibility",
1050
+ "display",
1051
+ "inline-size",
1052
+ "opacity",
1053
+ "position"
1054
+ ].forEach((name) => {
1055
+ panel.style.removeProperty(name);
1056
+ });
1058
1057
  });
1059
1058
  this.#rootElement.removeAttribute("data-tabs-animating");
1060
1059
  }
@@ -1144,7 +1143,7 @@ function isFocusable2(element) {
1144
1143
  * Tabs
1145
1144
  * WAI-ARIA compliant tabs pattern implementation in TypeScript.
1146
1145
  *
1147
- * @version 1.5.4
1146
+ * @version 1.5.5
1148
1147
  * @author Yusuke Kamiyamane
1149
1148
  * @license MIT
1150
1149
  * @copyright Copyright (c) Yusuke Kamiyamane
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@y14e/tabs",
3
- "version": "1.5.4",
3
+ "version": "1.5.5",
4
4
  "description": "WAI-ARIA compliant tabs pattern implementation in TypeScript",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",