@zag-js/tabs 0.0.0-dev-20220712223104 → 0.0.0-dev-20220713183215
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/dist/index.js +7 -7
- package/dist/index.mjs +7 -7
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -86,21 +86,21 @@ function getDocument(el) {
|
|
|
86
86
|
return el;
|
|
87
87
|
return (_a = el == null ? void 0 : el.ownerDocument) != null ? _a : document;
|
|
88
88
|
}
|
|
89
|
-
function defineDomHelpers(
|
|
90
|
-
const
|
|
89
|
+
function defineDomHelpers(helpers) {
|
|
90
|
+
const dom2 = {
|
|
91
91
|
getRootNode: (ctx) => {
|
|
92
92
|
var _a, _b;
|
|
93
93
|
return (_b = (_a = ctx.getRootNode) == null ? void 0 : _a.call(ctx)) != null ? _b : document;
|
|
94
94
|
},
|
|
95
|
-
getDoc: (ctx) => getDocument(
|
|
95
|
+
getDoc: (ctx) => getDocument(dom2.getRootNode(ctx)),
|
|
96
96
|
getWin: (ctx) => {
|
|
97
97
|
var _a;
|
|
98
|
-
return (_a =
|
|
98
|
+
return (_a = dom2.getDoc(ctx).defaultView) != null ? _a : window;
|
|
99
99
|
},
|
|
100
|
-
getActiveElement: (ctx) =>
|
|
101
|
-
getById: (ctx, id) =>
|
|
100
|
+
getActiveElement: (ctx) => dom2.getDoc(ctx).activeElement,
|
|
101
|
+
getById: (ctx, id) => dom2.getRootNode(ctx).getElementById(id)
|
|
102
102
|
};
|
|
103
|
-
return __spreadValues2(__spreadValues2({},
|
|
103
|
+
return __spreadValues2(__spreadValues2({}, dom2), helpers);
|
|
104
104
|
}
|
|
105
105
|
function isHTMLElement(v) {
|
|
106
106
|
return typeof v === "object" && (v == null ? void 0 : v.nodeType) === Node.ELEMENT_NODE && typeof (v == null ? void 0 : v.nodeName) === "string";
|
package/dist/index.mjs
CHANGED
|
@@ -62,21 +62,21 @@ function getDocument(el) {
|
|
|
62
62
|
return el;
|
|
63
63
|
return (_a = el == null ? void 0 : el.ownerDocument) != null ? _a : document;
|
|
64
64
|
}
|
|
65
|
-
function defineDomHelpers(
|
|
66
|
-
const
|
|
65
|
+
function defineDomHelpers(helpers) {
|
|
66
|
+
const dom2 = {
|
|
67
67
|
getRootNode: (ctx) => {
|
|
68
68
|
var _a, _b;
|
|
69
69
|
return (_b = (_a = ctx.getRootNode) == null ? void 0 : _a.call(ctx)) != null ? _b : document;
|
|
70
70
|
},
|
|
71
|
-
getDoc: (ctx) => getDocument(
|
|
71
|
+
getDoc: (ctx) => getDocument(dom2.getRootNode(ctx)),
|
|
72
72
|
getWin: (ctx) => {
|
|
73
73
|
var _a;
|
|
74
|
-
return (_a =
|
|
74
|
+
return (_a = dom2.getDoc(ctx).defaultView) != null ? _a : window;
|
|
75
75
|
},
|
|
76
|
-
getActiveElement: (ctx) =>
|
|
77
|
-
getById: (ctx, id) =>
|
|
76
|
+
getActiveElement: (ctx) => dom2.getDoc(ctx).activeElement,
|
|
77
|
+
getById: (ctx, id) => dom2.getRootNode(ctx).getElementById(id)
|
|
78
78
|
};
|
|
79
|
-
return __spreadValues2(__spreadValues2({},
|
|
79
|
+
return __spreadValues2(__spreadValues2({}, dom2), helpers);
|
|
80
80
|
}
|
|
81
81
|
function isHTMLElement(v) {
|
|
82
82
|
return typeof v === "object" && (v == null ? void 0 : v.nodeType) === Node.ELEMENT_NODE && typeof (v == null ? void 0 : v.nodeName) === "string";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zag-js/tabs",
|
|
3
|
-
"version": "0.0.0-dev-
|
|
3
|
+
"version": "0.0.0-dev-20220713183215",
|
|
4
4
|
"description": "Core logic for the tabs widget implemented as a state machine",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"js",
|
|
@@ -29,11 +29,11 @@
|
|
|
29
29
|
"url": "https://github.com/chakra-ui/zag/issues"
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@zag-js/core": "0.0.0-dev-
|
|
33
|
-
"@zag-js/types": "0.0.0-dev-
|
|
32
|
+
"@zag-js/core": "0.0.0-dev-20220713183215",
|
|
33
|
+
"@zag-js/types": "0.0.0-dev-20220713183215"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
36
|
-
"@zag-js/dom-utils": "0.0.0-dev-
|
|
36
|
+
"@zag-js/dom-utils": "0.0.0-dev-20220713183215",
|
|
37
37
|
"@zag-js/utils": "0.1.2"
|
|
38
38
|
},
|
|
39
39
|
"scripts": {
|