@zag-js/tooltip 0.2.6 → 0.2.8
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/{chunk-PFKIRGNP.mjs → chunk-3CVVHJEG.mjs} +1 -19
- package/dist/{chunk-JWVFZJC7.mjs → chunk-7JKEQJM5.mjs} +2 -2
- package/dist/{chunk-XZ6HXWV2.mjs → chunk-JUJSXBJJ.mjs} +3 -3
- package/dist/{chunk-GQYNO326.mjs → chunk-U6APNBZA.mjs} +0 -0
- package/dist/{chunk-RRQRIZBA.mjs → chunk-Z2SSSXHP.mjs} +0 -0
- package/dist/index.js +1 -19
- package/dist/index.mjs +5 -5
- package/dist/tooltip.anatomy.mjs +1 -1
- package/dist/tooltip.connect.js +1 -19
- package/dist/tooltip.connect.mjs +4 -4
- package/dist/tooltip.dom.d.ts +0 -4
- package/dist/tooltip.dom.js +1 -19
- package/dist/tooltip.dom.mjs +1 -1
- package/dist/tooltip.machine.js +1 -19
- package/dist/tooltip.machine.mjs +3 -3
- package/dist/tooltip.store.mjs +1 -1
- package/package.json +4 -4
|
@@ -59,25 +59,7 @@ function defineDomHelpers(helpers) {
|
|
|
59
59
|
return (_a = dom2.getDoc(ctx).defaultView) != null ? _a : window;
|
|
60
60
|
},
|
|
61
61
|
getActiveElement: (ctx) => dom2.getDoc(ctx).activeElement,
|
|
62
|
-
getById: (ctx, id) => dom2.getRootNode(ctx).getElementById(id)
|
|
63
|
-
createEmitter: (ctx, target) => {
|
|
64
|
-
const win = dom2.getWin(ctx);
|
|
65
|
-
return function emit(evt, detail, options) {
|
|
66
|
-
const { bubbles = true, cancelable, composed = true } = options != null ? options : {};
|
|
67
|
-
const eventName = `zag:${evt}`;
|
|
68
|
-
const init = { bubbles, cancelable, composed, detail };
|
|
69
|
-
const event = new win.CustomEvent(eventName, init);
|
|
70
|
-
target.dispatchEvent(event);
|
|
71
|
-
};
|
|
72
|
-
},
|
|
73
|
-
createListener: (target) => {
|
|
74
|
-
return function listen(evt, handler) {
|
|
75
|
-
const eventName = `zag:${evt}`;
|
|
76
|
-
const listener = (e) => handler(e);
|
|
77
|
-
target.addEventListener(eventName, listener);
|
|
78
|
-
return () => target.removeEventListener(eventName, listener);
|
|
79
|
-
};
|
|
80
|
-
}
|
|
62
|
+
getById: (ctx, id) => dom2.getRootNode(ctx).getElementById(id)
|
|
81
63
|
};
|
|
82
64
|
return {
|
|
83
65
|
...dom2,
|
|
@@ -2,10 +2,10 @@ import {
|
|
|
2
2
|
dom,
|
|
3
3
|
getScrollParents,
|
|
4
4
|
isHTMLElement
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-3CVVHJEG.mjs";
|
|
6
6
|
import {
|
|
7
7
|
store
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-U6APNBZA.mjs";
|
|
9
9
|
|
|
10
10
|
// src/tooltip.machine.ts
|
|
11
11
|
import { createMachine, subscribe } from "@zag-js/core";
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
parts
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-Z2SSSXHP.mjs";
|
|
4
4
|
import {
|
|
5
5
|
dom
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-3CVVHJEG.mjs";
|
|
7
7
|
import {
|
|
8
8
|
store
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-U6APNBZA.mjs";
|
|
10
10
|
|
|
11
11
|
// ../../utilities/dom/src/attrs.ts
|
|
12
12
|
var dataAttr = (guard) => {
|
|
File without changes
|
|
File without changes
|
package/dist/index.js
CHANGED
|
@@ -129,25 +129,7 @@ function defineDomHelpers(helpers) {
|
|
|
129
129
|
return (_a = dom2.getDoc(ctx).defaultView) != null ? _a : window;
|
|
130
130
|
},
|
|
131
131
|
getActiveElement: (ctx) => dom2.getDoc(ctx).activeElement,
|
|
132
|
-
getById: (ctx, id) => dom2.getRootNode(ctx).getElementById(id)
|
|
133
|
-
createEmitter: (ctx, target) => {
|
|
134
|
-
const win = dom2.getWin(ctx);
|
|
135
|
-
return function emit(evt, detail, options) {
|
|
136
|
-
const { bubbles = true, cancelable, composed = true } = options != null ? options : {};
|
|
137
|
-
const eventName = `zag:${evt}`;
|
|
138
|
-
const init = { bubbles, cancelable, composed, detail };
|
|
139
|
-
const event = new win.CustomEvent(eventName, init);
|
|
140
|
-
target.dispatchEvent(event);
|
|
141
|
-
};
|
|
142
|
-
},
|
|
143
|
-
createListener: (target) => {
|
|
144
|
-
return function listen(evt, handler) {
|
|
145
|
-
const eventName = `zag:${evt}`;
|
|
146
|
-
const listener = (e) => handler(e);
|
|
147
|
-
target.addEventListener(eventName, listener);
|
|
148
|
-
return () => target.removeEventListener(eventName, listener);
|
|
149
|
-
};
|
|
150
|
-
}
|
|
132
|
+
getById: (ctx, id) => dom2.getRootNode(ctx).getElementById(id)
|
|
151
133
|
};
|
|
152
134
|
return {
|
|
153
135
|
...dom2,
|
package/dist/index.mjs
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import {
|
|
2
2
|
connect
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-JUJSXBJJ.mjs";
|
|
4
4
|
import {
|
|
5
5
|
anatomy
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-Z2SSSXHP.mjs";
|
|
7
7
|
import {
|
|
8
8
|
machine
|
|
9
|
-
} from "./chunk-
|
|
10
|
-
import "./chunk-
|
|
11
|
-
import "./chunk-
|
|
9
|
+
} from "./chunk-7JKEQJM5.mjs";
|
|
10
|
+
import "./chunk-3CVVHJEG.mjs";
|
|
11
|
+
import "./chunk-U6APNBZA.mjs";
|
|
12
12
|
export {
|
|
13
13
|
anatomy,
|
|
14
14
|
connect,
|
package/dist/tooltip.anatomy.mjs
CHANGED
package/dist/tooltip.connect.js
CHANGED
|
@@ -86,25 +86,7 @@ function defineDomHelpers(helpers) {
|
|
|
86
86
|
return (_a = dom2.getDoc(ctx).defaultView) != null ? _a : window;
|
|
87
87
|
},
|
|
88
88
|
getActiveElement: (ctx) => dom2.getDoc(ctx).activeElement,
|
|
89
|
-
getById: (ctx, id) => dom2.getRootNode(ctx).getElementById(id)
|
|
90
|
-
createEmitter: (ctx, target) => {
|
|
91
|
-
const win = dom2.getWin(ctx);
|
|
92
|
-
return function emit(evt, detail, options) {
|
|
93
|
-
const { bubbles = true, cancelable, composed = true } = options != null ? options : {};
|
|
94
|
-
const eventName = `zag:${evt}`;
|
|
95
|
-
const init = { bubbles, cancelable, composed, detail };
|
|
96
|
-
const event = new win.CustomEvent(eventName, init);
|
|
97
|
-
target.dispatchEvent(event);
|
|
98
|
-
};
|
|
99
|
-
},
|
|
100
|
-
createListener: (target) => {
|
|
101
|
-
return function listen(evt, handler) {
|
|
102
|
-
const eventName = `zag:${evt}`;
|
|
103
|
-
const listener = (e) => handler(e);
|
|
104
|
-
target.addEventListener(eventName, listener);
|
|
105
|
-
return () => target.removeEventListener(eventName, listener);
|
|
106
|
-
};
|
|
107
|
-
}
|
|
89
|
+
getById: (ctx, id) => dom2.getRootNode(ctx).getElementById(id)
|
|
108
90
|
};
|
|
109
91
|
return {
|
|
110
92
|
...dom2,
|
package/dist/tooltip.connect.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
connect
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
5
|
-
import "./chunk-
|
|
6
|
-
import "./chunk-
|
|
3
|
+
} from "./chunk-JUJSXBJJ.mjs";
|
|
4
|
+
import "./chunk-Z2SSSXHP.mjs";
|
|
5
|
+
import "./chunk-3CVVHJEG.mjs";
|
|
6
|
+
import "./chunk-U6APNBZA.mjs";
|
|
7
7
|
export {
|
|
8
8
|
connect
|
|
9
9
|
};
|
package/dist/tooltip.dom.d.ts
CHANGED
|
@@ -19,10 +19,6 @@ declare const dom: {
|
|
|
19
19
|
getById: <T = HTMLElement>(ctx: {
|
|
20
20
|
getRootNode?: (() => Node | Document | ShadowRoot) | undefined;
|
|
21
21
|
}, id: string) => T | null;
|
|
22
|
-
createEmitter: (ctx: {
|
|
23
|
-
getRootNode?: (() => Node | Document | ShadowRoot) | undefined;
|
|
24
|
-
}, target: HTMLElement) => (evt: string, detail: Record<string, any>, options?: EventInit | undefined) => void;
|
|
25
|
-
createListener: (target: HTMLElement) => <T_1 = any>(evt: string, handler: (e: CustomEvent<T_1>) => void) => () => void;
|
|
26
22
|
} & {
|
|
27
23
|
getTriggerId: (ctx: MachineContext) => string;
|
|
28
24
|
getContentId: (ctx: MachineContext) => string;
|
package/dist/tooltip.dom.js
CHANGED
|
@@ -81,25 +81,7 @@ function defineDomHelpers(helpers) {
|
|
|
81
81
|
return (_a = dom2.getDoc(ctx).defaultView) != null ? _a : window;
|
|
82
82
|
},
|
|
83
83
|
getActiveElement: (ctx) => dom2.getDoc(ctx).activeElement,
|
|
84
|
-
getById: (ctx, id) => dom2.getRootNode(ctx).getElementById(id)
|
|
85
|
-
createEmitter: (ctx, target) => {
|
|
86
|
-
const win = dom2.getWin(ctx);
|
|
87
|
-
return function emit(evt, detail, options) {
|
|
88
|
-
const { bubbles = true, cancelable, composed = true } = options != null ? options : {};
|
|
89
|
-
const eventName = `zag:${evt}`;
|
|
90
|
-
const init = { bubbles, cancelable, composed, detail };
|
|
91
|
-
const event = new win.CustomEvent(eventName, init);
|
|
92
|
-
target.dispatchEvent(event);
|
|
93
|
-
};
|
|
94
|
-
},
|
|
95
|
-
createListener: (target) => {
|
|
96
|
-
return function listen(evt, handler) {
|
|
97
|
-
const eventName = `zag:${evt}`;
|
|
98
|
-
const listener = (e) => handler(e);
|
|
99
|
-
target.addEventListener(eventName, listener);
|
|
100
|
-
return () => target.removeEventListener(eventName, listener);
|
|
101
|
-
};
|
|
102
|
-
}
|
|
84
|
+
getById: (ctx, id) => dom2.getRootNode(ctx).getElementById(id)
|
|
103
85
|
};
|
|
104
86
|
return {
|
|
105
87
|
...dom2,
|
package/dist/tooltip.dom.mjs
CHANGED
package/dist/tooltip.machine.js
CHANGED
|
@@ -118,25 +118,7 @@ function defineDomHelpers(helpers) {
|
|
|
118
118
|
return (_a = dom2.getDoc(ctx).defaultView) != null ? _a : window;
|
|
119
119
|
},
|
|
120
120
|
getActiveElement: (ctx) => dom2.getDoc(ctx).activeElement,
|
|
121
|
-
getById: (ctx, id) => dom2.getRootNode(ctx).getElementById(id)
|
|
122
|
-
createEmitter: (ctx, target) => {
|
|
123
|
-
const win = dom2.getWin(ctx);
|
|
124
|
-
return function emit(evt, detail, options) {
|
|
125
|
-
const { bubbles = true, cancelable, composed = true } = options != null ? options : {};
|
|
126
|
-
const eventName = `zag:${evt}`;
|
|
127
|
-
const init = { bubbles, cancelable, composed, detail };
|
|
128
|
-
const event = new win.CustomEvent(eventName, init);
|
|
129
|
-
target.dispatchEvent(event);
|
|
130
|
-
};
|
|
131
|
-
},
|
|
132
|
-
createListener: (target) => {
|
|
133
|
-
return function listen(evt, handler) {
|
|
134
|
-
const eventName = `zag:${evt}`;
|
|
135
|
-
const listener = (e) => handler(e);
|
|
136
|
-
target.addEventListener(eventName, listener);
|
|
137
|
-
return () => target.removeEventListener(eventName, listener);
|
|
138
|
-
};
|
|
139
|
-
}
|
|
121
|
+
getById: (ctx, id) => dom2.getRootNode(ctx).getElementById(id)
|
|
140
122
|
};
|
|
141
123
|
return {
|
|
142
124
|
...dom2,
|
package/dist/tooltip.machine.mjs
CHANGED
package/dist/tooltip.store.mjs
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zag-js/tooltip",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.8",
|
|
4
4
|
"description": "Core logic for the tooltip widget implemented as a state machine",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"js",
|
|
@@ -27,13 +27,13 @@
|
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
29
|
"@zag-js/anatomy": "0.1.3",
|
|
30
|
-
"@zag-js/core": "0.2.
|
|
30
|
+
"@zag-js/core": "0.2.6",
|
|
31
31
|
"@zag-js/popper": "0.2.2",
|
|
32
|
-
"@zag-js/types": "0.3.
|
|
32
|
+
"@zag-js/types": "0.3.3"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
35
|
"clean-package": "2.2.0",
|
|
36
|
-
"@zag-js/dom-utils": "0.2.
|
|
36
|
+
"@zag-js/dom-utils": "0.2.3",
|
|
37
37
|
"@zag-js/utils": "0.3.2"
|
|
38
38
|
},
|
|
39
39
|
"clean-package": "../../../clean-package.config.json",
|