@konstructio/ui 0.0.12-alpha.9 → 0.0.13-alpha.1
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/{Modal-B-E9uaA6.js → Modal-i7eolhYH.js} +311 -307
- package/dist/components/Alert/Alert.js +24 -29
- package/dist/components/Alert/Alert.variants.js +9 -15
- package/dist/components/AlertDialog/AlertDialog.js +59 -46
- package/dist/components/AlertDialog/components/AlertDialogTrigger.js +2 -2
- package/dist/components/AlertDialog/components/index.js +1 -1
- package/dist/components/Autocomplete/Autocomplete.js +76 -72
- package/dist/components/Autocomplete/Autocomplete.variants.js +11 -20
- package/dist/components/Autocomplete/components/List/List.js +28 -30
- package/dist/components/Autocomplete/components/List/List.variants.js +34 -40
- package/dist/components/Breadcrumb/Breadcrumb.js +47 -56
- package/dist/components/Breadcrumb/Breadcrumb.variants.js +6 -26
- package/dist/components/Breadcrumb/components/Item/Item.js +29 -41
- package/dist/components/Breadcrumb/components/Item/Item.variants.js +2 -20
- package/dist/components/Button/Button.js +33 -37
- package/dist/components/Button/Button.variants.js +138 -195
- package/dist/components/Card/Card.js +32 -37
- package/dist/components/Card/Card.variants.js +18 -53
- package/dist/components/Checkbox/Checkbox.js +65 -68
- package/dist/components/Checkbox/Checkbox.variants.js +11 -35
- package/dist/components/Command/Command.js +33 -25
- package/dist/components/Command/Command.variants.js +47 -94
- package/dist/components/Command/components/Command.js +1 -1
- package/dist/components/Command/components/CommandEmpty.js +1 -1
- package/dist/components/Command/components/CommandGroup.js +1 -1
- package/dist/components/Command/components/CommandInput.js +1 -1
- package/dist/components/Command/components/CommandItem.js +1 -1
- package/dist/components/Command/components/CommandList.js +1 -1
- package/dist/components/Command/components/CommandSeparator.js +1 -1
- package/dist/components/Command/components/DialogContent.js +1 -1
- package/dist/components/Command/components/DialogOverlay.js +8 -8
- package/dist/components/Divider/Divider.js +3 -2
- package/dist/components/Divider/Divider.variants.js +12 -9
- package/dist/components/Dropdown/Dropdown.js +6 -6
- package/dist/components/Dropdown/Dropdown.variants.js +31 -38
- package/dist/components/Dropdown/components/List/List.js +17 -15
- package/dist/components/Dropdown/components/List/List.variants.js +22 -32
- package/dist/components/Dropdown/components/ListItem/ListItem.js +20 -19
- package/dist/components/Dropdown/components/ListItem/ListItem.variants.js +18 -30
- package/dist/components/Dropdown/components/Wrapper.js +127 -90
- package/dist/components/Dropdown/contexts/dropdown.context.js +1 -1
- package/dist/components/Dropdown/contexts/dropdown.provider.js +9 -9
- package/dist/components/Input/Input.js +37 -37
- package/dist/components/Input/Input.variants.js +8 -13
- package/dist/components/Loading/Loading.js +60 -58
- package/dist/components/Loading/Loading.variants.js +9 -15
- package/dist/components/Modal/Modal.js +2 -2
- package/dist/components/Modal/components/Body/Body.js +1 -1
- package/dist/components/Modal/components/Footer/Footer.js +2 -2
- package/dist/components/Modal/components/Header/Header.js +3 -3
- package/dist/components/Modal/components/Wrapper/Wrapper.js +3 -4
- package/dist/components/Modal/components/Wrapper/Wrapper.variants.js +32 -46
- package/dist/components/Modal/components/index.js +1 -1
- package/dist/components/NumberInput/NumberInput.js +93 -111
- package/dist/components/NumberInput/NumberInput.variants.js +30 -51
- package/dist/components/ProgressBar/ProgressBar.js +25 -29
- package/dist/components/ProgressBar/ProgressBar.variants.js +10 -31
- package/dist/components/Radio/Radio.js +45 -46
- package/dist/components/Radio/Radio.variants.js +4 -13
- package/dist/components/RadioCard/RadioCard.js +31 -37
- package/dist/components/RadioCard/RadioCard.variants.js +8 -17
- package/dist/components/RadioCardGroup/RadioCardGroup.js +22 -23
- package/dist/components/RadioCardGroup/RadioCardGroup.variants.js +3 -9
- package/dist/components/RadioGroup/RadioGroup.js +30 -31
- package/dist/components/RadioGroup/RadioGroup.variants.js +2 -8
- package/dist/components/Range/Range.js +28 -34
- package/dist/components/Range/Range.variants.js +21 -53
- package/dist/components/Sidebar/Sidebar.js +12 -13
- package/dist/components/Sidebar/Sidebar.variants.js +30 -56
- package/dist/components/Sidebar/components/Footer/Footer.js +5 -17
- package/dist/components/Sidebar/components/Footer/Footer.variants.js +9 -16
- package/dist/components/Sidebar/components/Logo/Logo.js +5 -15
- package/dist/components/Sidebar/components/Logo/Logo.variants.js +20 -36
- package/dist/components/Sidebar/components/Navigation/Navigation.js +15 -28
- package/dist/components/Sidebar/components/Navigation/Navigation.variants.js +3 -17
- package/dist/components/Sidebar/components/NavigationGroup/NavigationGroup.js +21 -34
- package/dist/components/Sidebar/components/NavigationGroup/NavigationGroup.variants.js +2 -13
- package/dist/components/Sidebar/components/NavigationOption/NavigationOption.js +21 -27
- package/dist/components/Sidebar/components/NavigationOption/NavigationOption.variants.js +7 -17
- package/dist/components/Sidebar/components/NavigationSeparator/NavigationSeparator.js +7 -19
- package/dist/components/Sidebar/components/NavigationSeparator/NavigationSeparator.variants.js +6 -16
- package/dist/components/Sidebar/components/NavigationTitle/NavigationTitle.js +8 -21
- package/dist/components/Sidebar/components/NavigationTitle/NavigationTitle.variants.js +11 -20
- package/dist/components/Sidebar/components/Wrapper/Wrapper.js +41 -44
- package/dist/components/Slider/Slider.js +26 -27
- package/dist/components/Slider/Slider.variants.js +22 -34
- package/dist/components/Switch/Switch.js +103 -106
- package/dist/components/Switch/Switch.variants.js +28 -53
- package/dist/components/Table/Table.js +27 -0
- package/dist/components/Table/Table.variants.js +40 -0
- package/dist/components/Table/components/Body.js +18 -0
- package/dist/components/Table/components/Filter.js +9 -0
- package/dist/components/Table/components/Head.js +18 -0
- package/dist/components/Table/components/Row.js +28 -0
- package/dist/components/Table/components/index.js +10 -0
- package/dist/components/Tag/Tag.js +1 -1
- package/dist/components/TagSelect/TagSelect.variants.js +23 -55
- package/dist/components/TagSelect/components/Item/Item.js +12 -14
- package/dist/components/TagSelect/components/Item/Item.variants.js +11 -10
- package/dist/components/TagSelect/components/List/List.js +9 -10
- package/dist/components/TagSelect/components/List/List.variants.js +21 -35
- package/dist/components/TagSelect/components/Wrapper/Wrapper.js +46 -48
- package/dist/components/TextArea/TextArea.js +20 -23
- package/dist/components/TextArea/TextArea.variants.js +19 -31
- package/dist/components/Toast/Toast.js +110 -116
- package/dist/components/Toast/Toast.variants.js +42 -70
- package/dist/components/Tooltip/Tooltip.js +21 -27
- package/dist/components/Tooltip/Tooltip.variants.js +61 -62
- package/dist/components/Typography/Typography.js +23 -19
- package/dist/components/Typography/Typography.variants.js +1 -7
- package/dist/components/index.js +22 -20
- package/dist/contexts/theme.provider.js +37 -39
- package/dist/domain/theme.js +0 -0
- package/dist/index-AM3avohj.js +133 -0
- package/dist/{index-BzaHYXkt.js → index-BOx5P4tS.js} +5 -5
- package/dist/index-Bk324h27.js +82 -0
- package/dist/{index-4ecjw_Aj.js → index-Bry5AFQ2.js} +1 -1
- package/dist/{index-CbTU3cnP.js → index-CWKdynYu.js} +1 -1
- package/dist/index-D9BbbgUq.js +47 -0
- package/dist/{index-DyKo5ZJT.js → index-DvFiic6N.js} +45 -45
- package/dist/{index-Dj1pom3_.js → index-G_6jG4Qc.js} +2 -2
- package/dist/{index-D_76wh4w.js → index-YaQrdkGE.js} +3 -3
- package/dist/{index-Cva-e5M4.js → index-bYyfdsls.js} +9 -9
- package/dist/index-dRxIWVBr.js +313 -0
- package/dist/{index-D7QNmo_D.js → index-g-TFwd6Y.js} +41 -41
- package/dist/index.d.ts +115 -98
- package/dist/index.js +30 -30
- package/dist/package.json +37 -36
- package/dist/styles.css +1 -1
- package/dist/ui/kubefirst-theme.css +296 -0
- package/dist/ui/theme.css +6 -0
- package/dist/ui/utilities.css +165 -0
- package/dist/utils/index.js +675 -424
- package/package.json +37 -36
- package/dist/components/AlertDialog/AlertDialog.variants.js +0 -15
- package/dist/index-B_6_jmOO.js +0 -68
- package/dist/index-BbsJ0VIJ.js +0 -47
- package/dist/index-CzSBQN5S.js +0 -432
- package/dist/index-DUA6Y_AE.js +0 -126
- package/dist/plugins/index.js +0 -4
- package/dist/plugins/konstruct.js +0 -118
- package/dist/plugins/utils/animation.styles.js +0 -162
- package/dist/plugins/utils/colors.js +0 -331
- package/dist/plugins/utils/index.js +0 -7
package/dist/index-CzSBQN5S.js
DELETED
|
@@ -1,432 +0,0 @@
|
|
|
1
|
-
import { u as T, R as Ce, P as Ae, O as Ie, C as Le } from "./index-DyKo5ZJT.js";
|
|
2
|
-
import * as l from "react";
|
|
3
|
-
import be from "react";
|
|
4
|
-
import { P as C } from "./index-D7QNmo_D.js";
|
|
5
|
-
var pe = 1, De = 0.9, $e = 0.8, Me = 0.17, X = 0.1, Q = 0.999, Ve = 0.9999, Te = 0.99, Ke = /[\\\/_+.#"@\[\(\{&]/, qe = /[\\\/_+.#"@\[\(\{&]/g, Pe = /[\s-]/, ye = /[\s-]/g;
|
|
6
|
-
function re(e, n, r, v, u, i, d) {
|
|
7
|
-
if (i === n.length) return u === e.length ? pe : Te;
|
|
8
|
-
var m = `${u},${i}`;
|
|
9
|
-
if (d[m] !== void 0) return d[m];
|
|
10
|
-
for (var g = v.charAt(i), p = r.indexOf(g, u), c = 0, o, S, f, E; p >= 0; ) o = re(e, n, r, v, p + 1, i + 1, d), o > c && (p === u ? o *= pe : Ke.test(e.charAt(p - 1)) ? (o *= $e, f = e.slice(u, p - 1).match(qe), f && u > 0 && (o *= Math.pow(Q, f.length))) : Pe.test(e.charAt(p - 1)) ? (o *= De, E = e.slice(u, p - 1).match(ye), E && u > 0 && (o *= Math.pow(Q, E.length))) : (o *= Me, u > 0 && (o *= Math.pow(Q, p - u))), e.charAt(p) !== n.charAt(i) && (o *= Ve)), (o < X && r.charAt(p - 1) === v.charAt(i + 1) || v.charAt(i + 1) === v.charAt(i) && r.charAt(p - 1) !== v.charAt(i)) && (S = re(e, n, r, v, p + 1, i + 2, d), S * X > o && (o = S * X)), o > c && (c = o), p = r.indexOf(g, p + 1);
|
|
11
|
-
return d[m] = c, c;
|
|
12
|
-
}
|
|
13
|
-
function me(e) {
|
|
14
|
-
return e.toLowerCase().replace(ye, " ");
|
|
15
|
-
}
|
|
16
|
-
function Ue(e, n, r) {
|
|
17
|
-
return e = r && r.length > 0 ? `${e + " " + r.join(" ")}` : e, re(e, n, me(e), me(n), 0, 0, {});
|
|
18
|
-
}
|
|
19
|
-
var H = { exports: {} }, Z = {};
|
|
20
|
-
/**
|
|
21
|
-
* @license React
|
|
22
|
-
* use-sync-external-store-shim.production.js
|
|
23
|
-
*
|
|
24
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
25
|
-
*
|
|
26
|
-
* This source code is licensed under the MIT license found in the
|
|
27
|
-
* LICENSE file in the root directory of this source tree.
|
|
28
|
-
*/
|
|
29
|
-
var he;
|
|
30
|
-
function je() {
|
|
31
|
-
if (he) return Z;
|
|
32
|
-
he = 1;
|
|
33
|
-
var e = be;
|
|
34
|
-
function n(o, S) {
|
|
35
|
-
return o === S && (o !== 0 || 1 / o === 1 / S) || o !== o && S !== S;
|
|
36
|
-
}
|
|
37
|
-
var r = typeof Object.is == "function" ? Object.is : n, v = e.useState, u = e.useEffect, i = e.useLayoutEffect, d = e.useDebugValue;
|
|
38
|
-
function m(o, S) {
|
|
39
|
-
var f = S(), E = v({ inst: { value: f, getSnapshot: S } }), w = E[0].inst, _ = E[1];
|
|
40
|
-
return i(
|
|
41
|
-
function() {
|
|
42
|
-
w.value = f, w.getSnapshot = S, g(w) && _({ inst: w });
|
|
43
|
-
},
|
|
44
|
-
[o, f, S]
|
|
45
|
-
), u(
|
|
46
|
-
function() {
|
|
47
|
-
return g(w) && _({ inst: w }), o(function() {
|
|
48
|
-
g(w) && _({ inst: w });
|
|
49
|
-
});
|
|
50
|
-
},
|
|
51
|
-
[o]
|
|
52
|
-
), d(f), f;
|
|
53
|
-
}
|
|
54
|
-
function g(o) {
|
|
55
|
-
var S = o.getSnapshot;
|
|
56
|
-
o = o.value;
|
|
57
|
-
try {
|
|
58
|
-
var f = S();
|
|
59
|
-
return !r(o, f);
|
|
60
|
-
} catch {
|
|
61
|
-
return !0;
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
function p(o, S) {
|
|
65
|
-
return S();
|
|
66
|
-
}
|
|
67
|
-
var c = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? p : m;
|
|
68
|
-
return Z.useSyncExternalStore = e.useSyncExternalStore !== void 0 ? e.useSyncExternalStore : c, Z;
|
|
69
|
-
}
|
|
70
|
-
var ee = {};
|
|
71
|
-
/**
|
|
72
|
-
* @license React
|
|
73
|
-
* use-sync-external-store-shim.development.js
|
|
74
|
-
*
|
|
75
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
76
|
-
*
|
|
77
|
-
* This source code is licensed under the MIT license found in the
|
|
78
|
-
* LICENSE file in the root directory of this source tree.
|
|
79
|
-
*/
|
|
80
|
-
var ge;
|
|
81
|
-
function Ge() {
|
|
82
|
-
return ge || (ge = 1, process.env.NODE_ENV !== "production" && function() {
|
|
83
|
-
function e(f, E) {
|
|
84
|
-
return f === E && (f !== 0 || 1 / f === 1 / E) || f !== f && E !== E;
|
|
85
|
-
}
|
|
86
|
-
function n(f, E) {
|
|
87
|
-
c || u.startTransition === void 0 || (c = !0, console.error(
|
|
88
|
-
"You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."
|
|
89
|
-
));
|
|
90
|
-
var w = E();
|
|
91
|
-
if (!o) {
|
|
92
|
-
var _ = E();
|
|
93
|
-
i(w, _) || (console.error(
|
|
94
|
-
"The result of getSnapshot should be cached to avoid an infinite loop"
|
|
95
|
-
), o = !0);
|
|
96
|
-
}
|
|
97
|
-
_ = d({
|
|
98
|
-
inst: { value: w, getSnapshot: E }
|
|
99
|
-
});
|
|
100
|
-
var k = _[0].inst, M = _[1];
|
|
101
|
-
return g(
|
|
102
|
-
function() {
|
|
103
|
-
k.value = w, k.getSnapshot = E, r(k) && M({ inst: k });
|
|
104
|
-
},
|
|
105
|
-
[f, w, E]
|
|
106
|
-
), m(
|
|
107
|
-
function() {
|
|
108
|
-
return r(k) && M({ inst: k }), f(function() {
|
|
109
|
-
r(k) && M({ inst: k });
|
|
110
|
-
});
|
|
111
|
-
},
|
|
112
|
-
[f]
|
|
113
|
-
), p(w), w;
|
|
114
|
-
}
|
|
115
|
-
function r(f) {
|
|
116
|
-
var E = f.getSnapshot;
|
|
117
|
-
f = f.value;
|
|
118
|
-
try {
|
|
119
|
-
var w = E();
|
|
120
|
-
return !i(f, w);
|
|
121
|
-
} catch {
|
|
122
|
-
return !0;
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
function v(f, E) {
|
|
126
|
-
return E();
|
|
127
|
-
}
|
|
128
|
-
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
|
|
129
|
-
var u = be, i = typeof Object.is == "function" ? Object.is : e, d = u.useState, m = u.useEffect, g = u.useLayoutEffect, p = u.useDebugValue, c = !1, o = !1, S = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? v : n;
|
|
130
|
-
ee.useSyncExternalStore = u.useSyncExternalStore !== void 0 ? u.useSyncExternalStore : S, typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
|
|
131
|
-
}()), ee;
|
|
132
|
-
}
|
|
133
|
-
var Se;
|
|
134
|
-
function He() {
|
|
135
|
-
return Se || (Se = 1, process.env.NODE_ENV === "production" ? H.exports = /* @__PURE__ */ je() : H.exports = /* @__PURE__ */ Ge()), H.exports;
|
|
136
|
-
}
|
|
137
|
-
var Be = /* @__PURE__ */ He(), P = '[cmdk-group=""]', te = '[cmdk-group-items=""]', Fe = '[cmdk-group-heading=""]', le = '[cmdk-item=""]', Ee = `${le}:not([aria-disabled="true"])`, ne = "cmdk-item-select", L = "data-value", Ne = (e, n, r) => Ue(e, n, r), we = l.createContext(void 0), j = () => l.useContext(we), xe = l.createContext(void 0), ue = () => l.useContext(xe), _e = l.createContext(void 0), ke = l.forwardRef((e, n) => {
|
|
138
|
-
let r = V(() => {
|
|
139
|
-
var t, s;
|
|
140
|
-
return { search: "", value: (s = (t = e.value) != null ? t : e.defaultValue) != null ? s : "", filtered: { count: 0, items: /* @__PURE__ */ new Map(), groups: /* @__PURE__ */ new Set() } };
|
|
141
|
-
}), v = V(() => /* @__PURE__ */ new Set()), u = V(() => /* @__PURE__ */ new Map()), i = V(() => /* @__PURE__ */ new Map()), d = V(() => /* @__PURE__ */ new Set()), m = Oe(e), { label: g, children: p, value: c, onValueChange: o, filter: S, shouldFilter: f, loop: E, disablePointerSelection: w = !1, vimBindings: _ = !0, ...k } = e, M = T(), ae = T(), oe = T(), A = l.useRef(null), x = nt();
|
|
142
|
-
D(() => {
|
|
143
|
-
if (c !== void 0) {
|
|
144
|
-
let t = c.trim();
|
|
145
|
-
r.current.value = t, O.emit();
|
|
146
|
-
}
|
|
147
|
-
}, [c]), D(() => {
|
|
148
|
-
x(6, ce);
|
|
149
|
-
}, []);
|
|
150
|
-
let O = l.useMemo(() => ({ subscribe: (t) => (d.current.add(t), () => d.current.delete(t)), snapshot: () => r.current, setState: (t, s, h) => {
|
|
151
|
-
var a, b, y;
|
|
152
|
-
if (!Object.is(r.current[t], s)) {
|
|
153
|
-
if (r.current[t] = s, t === "search") z(), N(), x(1, W);
|
|
154
|
-
else if (t === "value" && (h || x(5, ce), ((a = m.current) == null ? void 0 : a.value) !== void 0)) {
|
|
155
|
-
let R = s ?? "";
|
|
156
|
-
(y = (b = m.current).onValueChange) == null || y.call(b, R);
|
|
157
|
-
return;
|
|
158
|
-
}
|
|
159
|
-
O.emit();
|
|
160
|
-
}
|
|
161
|
-
}, emit: () => {
|
|
162
|
-
d.current.forEach((t) => t());
|
|
163
|
-
} }), []), F = l.useMemo(() => ({ value: (t, s, h) => {
|
|
164
|
-
var a;
|
|
165
|
-
s !== ((a = i.current.get(t)) == null ? void 0 : a.value) && (i.current.set(t, { value: s, keywords: h }), r.current.filtered.items.set(t, ie(s, h)), x(2, () => {
|
|
166
|
-
N(), O.emit();
|
|
167
|
-
}));
|
|
168
|
-
}, item: (t, s) => (v.current.add(t), s && (u.current.has(s) ? u.current.get(s).add(t) : u.current.set(s, /* @__PURE__ */ new Set([t]))), x(3, () => {
|
|
169
|
-
z(), N(), r.current.value || W(), O.emit();
|
|
170
|
-
}), () => {
|
|
171
|
-
i.current.delete(t), v.current.delete(t), r.current.filtered.items.delete(t);
|
|
172
|
-
let h = K();
|
|
173
|
-
x(4, () => {
|
|
174
|
-
z(), (h == null ? void 0 : h.getAttribute("id")) === t && W(), O.emit();
|
|
175
|
-
});
|
|
176
|
-
}), group: (t) => (u.current.has(t) || u.current.set(t, /* @__PURE__ */ new Set()), () => {
|
|
177
|
-
i.current.delete(t), u.current.delete(t);
|
|
178
|
-
}), filter: () => m.current.shouldFilter, label: g || e["aria-label"], getDisablePointerSelection: () => m.current.disablePointerSelection, listId: M, inputId: oe, labelId: ae, listInnerRef: A }), []);
|
|
179
|
-
function ie(t, s) {
|
|
180
|
-
var h, a;
|
|
181
|
-
let b = (a = (h = m.current) == null ? void 0 : h.filter) != null ? a : Ne;
|
|
182
|
-
return t ? b(t, r.current.search, s) : 0;
|
|
183
|
-
}
|
|
184
|
-
function N() {
|
|
185
|
-
if (!r.current.search || m.current.shouldFilter === !1) return;
|
|
186
|
-
let t = r.current.filtered.items, s = [];
|
|
187
|
-
r.current.filtered.groups.forEach((a) => {
|
|
188
|
-
let b = u.current.get(a), y = 0;
|
|
189
|
-
b.forEach((R) => {
|
|
190
|
-
let I = t.get(R);
|
|
191
|
-
y = Math.max(I, y);
|
|
192
|
-
}), s.push([a, y]);
|
|
193
|
-
});
|
|
194
|
-
let h = A.current;
|
|
195
|
-
q().sort((a, b) => {
|
|
196
|
-
var y, R;
|
|
197
|
-
let I = a.getAttribute("id"), G = b.getAttribute("id");
|
|
198
|
-
return ((y = t.get(G)) != null ? y : 0) - ((R = t.get(I)) != null ? R : 0);
|
|
199
|
-
}).forEach((a) => {
|
|
200
|
-
let b = a.closest(te);
|
|
201
|
-
b ? b.appendChild(a.parentElement === b ? a : a.closest(`${te} > *`)) : h.appendChild(a.parentElement === h ? a : a.closest(`${te} > *`));
|
|
202
|
-
}), s.sort((a, b) => b[1] - a[1]).forEach((a) => {
|
|
203
|
-
var b;
|
|
204
|
-
let y = (b = A.current) == null ? void 0 : b.querySelector(`${P}[${L}="${encodeURIComponent(a[0])}"]`);
|
|
205
|
-
y == null || y.parentElement.appendChild(y);
|
|
206
|
-
});
|
|
207
|
-
}
|
|
208
|
-
function W() {
|
|
209
|
-
let t = q().find((h) => h.getAttribute("aria-disabled") !== "true"), s = t == null ? void 0 : t.getAttribute(L);
|
|
210
|
-
O.setState("value", s || void 0);
|
|
211
|
-
}
|
|
212
|
-
function z() {
|
|
213
|
-
var t, s, h, a;
|
|
214
|
-
if (!r.current.search || m.current.shouldFilter === !1) {
|
|
215
|
-
r.current.filtered.count = v.current.size;
|
|
216
|
-
return;
|
|
217
|
-
}
|
|
218
|
-
r.current.filtered.groups = /* @__PURE__ */ new Set();
|
|
219
|
-
let b = 0;
|
|
220
|
-
for (let y of v.current) {
|
|
221
|
-
let R = (s = (t = i.current.get(y)) == null ? void 0 : t.value) != null ? s : "", I = (a = (h = i.current.get(y)) == null ? void 0 : h.keywords) != null ? a : [], G = ie(R, I);
|
|
222
|
-
r.current.filtered.items.set(y, G), G > 0 && b++;
|
|
223
|
-
}
|
|
224
|
-
for (let [y, R] of u.current) for (let I of R) if (r.current.filtered.items.get(I) > 0) {
|
|
225
|
-
r.current.filtered.groups.add(y);
|
|
226
|
-
break;
|
|
227
|
-
}
|
|
228
|
-
r.current.filtered.count = b;
|
|
229
|
-
}
|
|
230
|
-
function ce() {
|
|
231
|
-
var t, s, h;
|
|
232
|
-
let a = K();
|
|
233
|
-
a && (((t = a.parentElement) == null ? void 0 : t.firstChild) === a && ((h = (s = a.closest(P)) == null ? void 0 : s.querySelector(Fe)) == null || h.scrollIntoView({ block: "nearest" })), a.scrollIntoView({ block: "nearest" }));
|
|
234
|
-
}
|
|
235
|
-
function K() {
|
|
236
|
-
var t;
|
|
237
|
-
return (t = A.current) == null ? void 0 : t.querySelector(`${le}[aria-selected="true"]`);
|
|
238
|
-
}
|
|
239
|
-
function q() {
|
|
240
|
-
var t;
|
|
241
|
-
return Array.from(((t = A.current) == null ? void 0 : t.querySelectorAll(Ee)) || []);
|
|
242
|
-
}
|
|
243
|
-
function Y(t) {
|
|
244
|
-
let s = q()[t];
|
|
245
|
-
s && O.setState("value", s.getAttribute(L));
|
|
246
|
-
}
|
|
247
|
-
function J(t) {
|
|
248
|
-
var s;
|
|
249
|
-
let h = K(), a = q(), b = a.findIndex((R) => R === h), y = a[b + t];
|
|
250
|
-
(s = m.current) != null && s.loop && (y = b + t < 0 ? a[a.length - 1] : b + t === a.length ? a[0] : a[b + t]), y && O.setState("value", y.getAttribute(L));
|
|
251
|
-
}
|
|
252
|
-
function se(t) {
|
|
253
|
-
let s = K(), h = s == null ? void 0 : s.closest(P), a;
|
|
254
|
-
for (; h && !a; ) h = t > 0 ? tt(h, P) : rt(h, P), a = h == null ? void 0 : h.querySelector(Ee);
|
|
255
|
-
a ? O.setState("value", a.getAttribute(L)) : J(t);
|
|
256
|
-
}
|
|
257
|
-
let de = () => Y(q().length - 1), fe = (t) => {
|
|
258
|
-
t.preventDefault(), t.metaKey ? de() : t.altKey ? se(1) : J(1);
|
|
259
|
-
}, ve = (t) => {
|
|
260
|
-
t.preventDefault(), t.metaKey ? Y(0) : t.altKey ? se(-1) : J(-1);
|
|
261
|
-
};
|
|
262
|
-
return l.createElement(C.div, { ref: n, tabIndex: -1, ...k, "cmdk-root": "", onKeyDown: (t) => {
|
|
263
|
-
var s;
|
|
264
|
-
if ((s = k.onKeyDown) == null || s.call(k, t), !t.defaultPrevented) switch (t.key) {
|
|
265
|
-
case "n":
|
|
266
|
-
case "j": {
|
|
267
|
-
_ && t.ctrlKey && fe(t);
|
|
268
|
-
break;
|
|
269
|
-
}
|
|
270
|
-
case "ArrowDown": {
|
|
271
|
-
fe(t);
|
|
272
|
-
break;
|
|
273
|
-
}
|
|
274
|
-
case "p":
|
|
275
|
-
case "k": {
|
|
276
|
-
_ && t.ctrlKey && ve(t);
|
|
277
|
-
break;
|
|
278
|
-
}
|
|
279
|
-
case "ArrowUp": {
|
|
280
|
-
ve(t);
|
|
281
|
-
break;
|
|
282
|
-
}
|
|
283
|
-
case "Home": {
|
|
284
|
-
t.preventDefault(), Y(0);
|
|
285
|
-
break;
|
|
286
|
-
}
|
|
287
|
-
case "End": {
|
|
288
|
-
t.preventDefault(), de();
|
|
289
|
-
break;
|
|
290
|
-
}
|
|
291
|
-
case "Enter":
|
|
292
|
-
if (!t.nativeEvent.isComposing && t.keyCode !== 229) {
|
|
293
|
-
t.preventDefault();
|
|
294
|
-
let h = K();
|
|
295
|
-
if (h) {
|
|
296
|
-
let a = new Event(ne);
|
|
297
|
-
h.dispatchEvent(a);
|
|
298
|
-
}
|
|
299
|
-
}
|
|
300
|
-
}
|
|
301
|
-
} }, l.createElement("label", { "cmdk-label": "", htmlFor: F.inputId, id: F.labelId, style: ut }, g), B(e, (t) => l.createElement(xe.Provider, { value: O }, l.createElement(we.Provider, { value: F }, t))));
|
|
302
|
-
}), We = l.forwardRef((e, n) => {
|
|
303
|
-
var r, v;
|
|
304
|
-
let u = T(), i = l.useRef(null), d = l.useContext(_e), m = j(), g = Oe(e), p = (v = (r = g.current) == null ? void 0 : r.forceMount) != null ? v : d == null ? void 0 : d.forceMount;
|
|
305
|
-
D(() => {
|
|
306
|
-
if (!p) return m.item(u, d == null ? void 0 : d.id);
|
|
307
|
-
}, [p]);
|
|
308
|
-
let c = Re(u, i, [e.value, e.children, i], e.keywords), o = ue(), S = $((x) => x.value && x.value === c.current), f = $((x) => p || m.filter() === !1 ? !0 : x.search ? x.filtered.items.get(u) > 0 : !0);
|
|
309
|
-
l.useEffect(() => {
|
|
310
|
-
let x = i.current;
|
|
311
|
-
if (!(!x || e.disabled)) return x.addEventListener(ne, E), () => x.removeEventListener(ne, E);
|
|
312
|
-
}, [f, e.onSelect, e.disabled]);
|
|
313
|
-
function E() {
|
|
314
|
-
var x, O;
|
|
315
|
-
w(), (O = (x = g.current).onSelect) == null || O.call(x, c.current);
|
|
316
|
-
}
|
|
317
|
-
function w() {
|
|
318
|
-
o.setState("value", c.current, !0);
|
|
319
|
-
}
|
|
320
|
-
if (!f) return null;
|
|
321
|
-
let { disabled: _, value: k, onSelect: M, forceMount: ae, keywords: oe, ...A } = e;
|
|
322
|
-
return l.createElement(C.div, { ref: U([i, n]), ...A, id: u, "cmdk-item": "", role: "option", "aria-disabled": !!_, "aria-selected": !!S, "data-disabled": !!_, "data-selected": !!S, onPointerMove: _ || m.getDisablePointerSelection() ? void 0 : w, onClick: _ ? void 0 : E }, e.children);
|
|
323
|
-
}), ze = l.forwardRef((e, n) => {
|
|
324
|
-
let { heading: r, children: v, forceMount: u, ...i } = e, d = T(), m = l.useRef(null), g = l.useRef(null), p = T(), c = j(), o = $((f) => u || c.filter() === !1 ? !0 : f.search ? f.filtered.groups.has(d) : !0);
|
|
325
|
-
D(() => c.group(d), []), Re(d, m, [e.value, e.heading, g]);
|
|
326
|
-
let S = l.useMemo(() => ({ id: d, forceMount: u }), [u]);
|
|
327
|
-
return l.createElement(C.div, { ref: U([m, n]), ...i, "cmdk-group": "", role: "presentation", hidden: o ? void 0 : !0 }, r && l.createElement("div", { ref: g, "cmdk-group-heading": "", "aria-hidden": !0, id: p }, r), B(e, (f) => l.createElement("div", { "cmdk-group-items": "", role: "group", "aria-labelledby": r ? p : void 0 }, l.createElement(_e.Provider, { value: S }, f))));
|
|
328
|
-
}), Ye = l.forwardRef((e, n) => {
|
|
329
|
-
let { alwaysRender: r, ...v } = e, u = l.useRef(null), i = $((d) => !d.search);
|
|
330
|
-
return !r && !i ? null : l.createElement(C.div, { ref: U([u, n]), ...v, "cmdk-separator": "", role: "separator" });
|
|
331
|
-
}), Je = l.forwardRef((e, n) => {
|
|
332
|
-
let { onValueChange: r, ...v } = e, u = e.value != null, i = ue(), d = $((c) => c.search), m = $((c) => c.value), g = j(), p = l.useMemo(() => {
|
|
333
|
-
var c;
|
|
334
|
-
let o = (c = g.listInnerRef.current) == null ? void 0 : c.querySelector(`${le}[${L}="${encodeURIComponent(m)}"]`);
|
|
335
|
-
return o == null ? void 0 : o.getAttribute("id");
|
|
336
|
-
}, []);
|
|
337
|
-
return l.useEffect(() => {
|
|
338
|
-
e.value != null && i.setState("search", e.value);
|
|
339
|
-
}, [e.value]), l.createElement(C.input, { ref: n, ...v, "cmdk-input": "", autoComplete: "off", autoCorrect: "off", spellCheck: !1, "aria-autocomplete": "list", role: "combobox", "aria-expanded": !0, "aria-controls": g.listId, "aria-labelledby": g.labelId, "aria-activedescendant": p, id: g.inputId, type: "text", value: u ? e.value : d, onChange: (c) => {
|
|
340
|
-
u || i.setState("search", c.target.value), r == null || r(c.target.value);
|
|
341
|
-
} });
|
|
342
|
-
}), Xe = l.forwardRef((e, n) => {
|
|
343
|
-
let { children: r, label: v = "Suggestions", ...u } = e, i = l.useRef(null), d = l.useRef(null), m = j();
|
|
344
|
-
return l.useEffect(() => {
|
|
345
|
-
if (d.current && i.current) {
|
|
346
|
-
let g = d.current, p = i.current, c, o = new ResizeObserver(() => {
|
|
347
|
-
c = requestAnimationFrame(() => {
|
|
348
|
-
let S = g.offsetHeight;
|
|
349
|
-
p.style.setProperty("--cmdk-list-height", S.toFixed(1) + "px");
|
|
350
|
-
});
|
|
351
|
-
});
|
|
352
|
-
return o.observe(g), () => {
|
|
353
|
-
cancelAnimationFrame(c), o.unobserve(g);
|
|
354
|
-
};
|
|
355
|
-
}
|
|
356
|
-
}, []), l.createElement(C.div, { ref: U([i, n]), ...u, "cmdk-list": "", role: "listbox", "aria-label": v, id: m.listId }, B(e, (g) => l.createElement("div", { ref: U([d, m.listInnerRef]), "cmdk-list-sizer": "" }, g)));
|
|
357
|
-
}), Qe = l.forwardRef((e, n) => {
|
|
358
|
-
let { open: r, onOpenChange: v, overlayClassName: u, contentClassName: i, container: d, ...m } = e;
|
|
359
|
-
return l.createElement(Ce, { open: r, onOpenChange: v }, l.createElement(Ae, { container: d }, l.createElement(Ie, { "cmdk-overlay": "", className: u }), l.createElement(Le, { "aria-label": e.label, "cmdk-dialog": "", className: i }, l.createElement(ke, { ref: n, ...m }))));
|
|
360
|
-
}), Ze = l.forwardRef((e, n) => $((r) => r.filtered.count === 0) ? l.createElement(C.div, { ref: n, ...e, "cmdk-empty": "", role: "presentation" }) : null), et = l.forwardRef((e, n) => {
|
|
361
|
-
let { progress: r, children: v, label: u = "Loading...", ...i } = e;
|
|
362
|
-
return l.createElement(C.div, { ref: n, ...i, "cmdk-loading": "", role: "progressbar", "aria-valuenow": r, "aria-valuemin": 0, "aria-valuemax": 100, "aria-label": u }, B(e, (d) => l.createElement("div", { "aria-hidden": !0 }, d)));
|
|
363
|
-
}), ct = Object.assign(ke, { List: Xe, Item: We, Input: Je, Group: ze, Separator: Ye, Dialog: Qe, Empty: Ze, Loading: et });
|
|
364
|
-
function tt(e, n) {
|
|
365
|
-
let r = e.nextElementSibling;
|
|
366
|
-
for (; r; ) {
|
|
367
|
-
if (r.matches(n)) return r;
|
|
368
|
-
r = r.nextElementSibling;
|
|
369
|
-
}
|
|
370
|
-
}
|
|
371
|
-
function rt(e, n) {
|
|
372
|
-
let r = e.previousElementSibling;
|
|
373
|
-
for (; r; ) {
|
|
374
|
-
if (r.matches(n)) return r;
|
|
375
|
-
r = r.previousElementSibling;
|
|
376
|
-
}
|
|
377
|
-
}
|
|
378
|
-
function Oe(e) {
|
|
379
|
-
let n = l.useRef(e);
|
|
380
|
-
return D(() => {
|
|
381
|
-
n.current = e;
|
|
382
|
-
}), n;
|
|
383
|
-
}
|
|
384
|
-
var D = typeof window > "u" ? l.useEffect : l.useLayoutEffect;
|
|
385
|
-
function V(e) {
|
|
386
|
-
let n = l.useRef();
|
|
387
|
-
return n.current === void 0 && (n.current = e()), n;
|
|
388
|
-
}
|
|
389
|
-
function U(e) {
|
|
390
|
-
return (n) => {
|
|
391
|
-
e.forEach((r) => {
|
|
392
|
-
typeof r == "function" ? r(n) : r != null && (r.current = n);
|
|
393
|
-
});
|
|
394
|
-
};
|
|
395
|
-
}
|
|
396
|
-
function $(e) {
|
|
397
|
-
let n = ue(), r = () => e(n.snapshot());
|
|
398
|
-
return Be.useSyncExternalStore(n.subscribe, r, r);
|
|
399
|
-
}
|
|
400
|
-
function Re(e, n, r, v = []) {
|
|
401
|
-
let u = l.useRef(), i = j();
|
|
402
|
-
return D(() => {
|
|
403
|
-
var d;
|
|
404
|
-
let m = (() => {
|
|
405
|
-
var p;
|
|
406
|
-
for (let c of r) {
|
|
407
|
-
if (typeof c == "string") return c.trim();
|
|
408
|
-
if (typeof c == "object" && "current" in c) return c.current ? (p = c.current.textContent) == null ? void 0 : p.trim() : u.current;
|
|
409
|
-
}
|
|
410
|
-
})(), g = v.map((p) => p.trim());
|
|
411
|
-
i.value(e, m, g), (d = n.current) == null || d.setAttribute(L, m), u.current = m;
|
|
412
|
-
}), u;
|
|
413
|
-
}
|
|
414
|
-
var nt = () => {
|
|
415
|
-
let [e, n] = l.useState(), r = V(() => /* @__PURE__ */ new Map());
|
|
416
|
-
return D(() => {
|
|
417
|
-
r.current.forEach((v) => v()), r.current = /* @__PURE__ */ new Map();
|
|
418
|
-
}, [e]), (v, u) => {
|
|
419
|
-
r.current.set(v, u), n({});
|
|
420
|
-
};
|
|
421
|
-
};
|
|
422
|
-
function lt(e) {
|
|
423
|
-
let n = e.type;
|
|
424
|
-
return typeof n == "function" ? n(e.props) : "render" in n ? n.render(e.props) : e;
|
|
425
|
-
}
|
|
426
|
-
function B({ asChild: e, children: n }, r) {
|
|
427
|
-
return e && l.isValidElement(n) ? l.cloneElement(lt(n), { ref: n.ref }, r(n.props.children)) : r(n);
|
|
428
|
-
}
|
|
429
|
-
var ut = { position: "absolute", width: "1px", height: "1px", padding: "0", margin: "-1px", overflow: "hidden", clip: "rect(0, 0, 0, 0)", whiteSpace: "nowrap", borderWidth: "0" };
|
|
430
|
-
export {
|
|
431
|
-
ct as V
|
|
432
|
-
};
|
package/dist/index-DUA6Y_AE.js
DELETED
|
@@ -1,126 +0,0 @@
|
|
|
1
|
-
import { jsx as i, jsxs as w } from "react/jsx-runtime";
|
|
2
|
-
import * as s from "react";
|
|
3
|
-
import { c as x, b as M } from "./index-Cva-e5M4.js";
|
|
4
|
-
import { u as A, a as I } from "./index-B_6_jmOO.js";
|
|
5
|
-
import { c as v, R as $, P as L, O as F, W as G, C as W, T as j, d as B, b as f, e as Y } from "./index-DyKo5ZJT.js";
|
|
6
|
-
import { Button as k } from "./components/Button/Button.js";
|
|
7
|
-
import { useTheme as q } from "./contexts/theme.hook.js";
|
|
8
|
-
var D = "AlertDialog", [H, se] = x(D, [
|
|
9
|
-
v
|
|
10
|
-
]), l = v(), m = (e) => {
|
|
11
|
-
const { __scopeAlertDialog: o, ...r } = e, t = l(o);
|
|
12
|
-
return /* @__PURE__ */ i($, { ...t, ...r, modal: !0 });
|
|
13
|
-
};
|
|
14
|
-
m.displayName = D;
|
|
15
|
-
var V = "AlertDialogTrigger", h = s.forwardRef(
|
|
16
|
-
(e, o) => {
|
|
17
|
-
const { __scopeAlertDialog: r, ...t } = e, a = l(r);
|
|
18
|
-
return /* @__PURE__ */ i(Y, { ...a, ...t, ref: o });
|
|
19
|
-
}
|
|
20
|
-
);
|
|
21
|
-
h.displayName = V;
|
|
22
|
-
var z = "AlertDialogPortal", y = (e) => {
|
|
23
|
-
const { __scopeAlertDialog: o, ...r } = e, t = l(o);
|
|
24
|
-
return /* @__PURE__ */ i(L, { ...t, ...r });
|
|
25
|
-
};
|
|
26
|
-
y.displayName = z;
|
|
27
|
-
var J = "AlertDialogOverlay", _ = s.forwardRef(
|
|
28
|
-
(e, o) => {
|
|
29
|
-
const { __scopeAlertDialog: r, ...t } = e, a = l(r);
|
|
30
|
-
return /* @__PURE__ */ i(F, { ...a, ...t, ref: o });
|
|
31
|
-
}
|
|
32
|
-
);
|
|
33
|
-
_.displayName = J;
|
|
34
|
-
var n = "AlertDialogContent", [K, Q] = H(n), N = s.forwardRef(
|
|
35
|
-
(e, o) => {
|
|
36
|
-
const { __scopeAlertDialog: r, children: t, ...a } = e, d = l(r), p = s.useRef(null), O = A(o, p), g = s.useRef(null);
|
|
37
|
-
return /* @__PURE__ */ i(
|
|
38
|
-
G,
|
|
39
|
-
{
|
|
40
|
-
contentName: n,
|
|
41
|
-
titleName: R,
|
|
42
|
-
docsSlug: "alert-dialog",
|
|
43
|
-
children: /* @__PURE__ */ i(K, { scope: r, cancelRef: g, children: /* @__PURE__ */ w(
|
|
44
|
-
W,
|
|
45
|
-
{
|
|
46
|
-
role: "alertdialog",
|
|
47
|
-
...d,
|
|
48
|
-
...a,
|
|
49
|
-
ref: O,
|
|
50
|
-
onOpenAutoFocus: M(a.onOpenAutoFocus, (c) => {
|
|
51
|
-
var u;
|
|
52
|
-
c.preventDefault(), (u = g.current) == null || u.focus({ preventScroll: !0 });
|
|
53
|
-
}),
|
|
54
|
-
onPointerDownOutside: (c) => c.preventDefault(),
|
|
55
|
-
onInteractOutside: (c) => c.preventDefault(),
|
|
56
|
-
children: [
|
|
57
|
-
/* @__PURE__ */ i(I, { children: t }),
|
|
58
|
-
/* @__PURE__ */ i(X, { contentRef: p })
|
|
59
|
-
]
|
|
60
|
-
}
|
|
61
|
-
) })
|
|
62
|
-
}
|
|
63
|
-
);
|
|
64
|
-
}
|
|
65
|
-
);
|
|
66
|
-
N.displayName = n;
|
|
67
|
-
var R = "AlertDialogTitle", C = s.forwardRef(
|
|
68
|
-
(e, o) => {
|
|
69
|
-
const { __scopeAlertDialog: r, ...t } = e, a = l(r);
|
|
70
|
-
return /* @__PURE__ */ i(j, { ...a, ...t, ref: o });
|
|
71
|
-
}
|
|
72
|
-
);
|
|
73
|
-
C.displayName = R;
|
|
74
|
-
var T = "AlertDialogDescription", E = s.forwardRef((e, o) => {
|
|
75
|
-
const { __scopeAlertDialog: r, ...t } = e, a = l(r);
|
|
76
|
-
return /* @__PURE__ */ i(B, { ...a, ...t, ref: o });
|
|
77
|
-
});
|
|
78
|
-
E.displayName = T;
|
|
79
|
-
var U = "AlertDialogAction", P = s.forwardRef(
|
|
80
|
-
(e, o) => {
|
|
81
|
-
const { __scopeAlertDialog: r, ...t } = e, a = l(r);
|
|
82
|
-
return /* @__PURE__ */ i(f, { ...a, ...t, ref: o });
|
|
83
|
-
}
|
|
84
|
-
);
|
|
85
|
-
P.displayName = U;
|
|
86
|
-
var S = "AlertDialogCancel", b = s.forwardRef(
|
|
87
|
-
(e, o) => {
|
|
88
|
-
const { __scopeAlertDialog: r, ...t } = e, { cancelRef: a } = Q(S, r), d = l(r), p = A(o, a);
|
|
89
|
-
return /* @__PURE__ */ i(f, { ...d, ...t, ref: p });
|
|
90
|
-
}
|
|
91
|
-
);
|
|
92
|
-
b.displayName = S;
|
|
93
|
-
var X = ({ contentRef: e }) => {
|
|
94
|
-
const o = `\`${n}\` requires a description for the component to be accessible for screen reader users.
|
|
95
|
-
|
|
96
|
-
You can add a description to the \`${n}\` by passing a \`${T}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
|
|
97
|
-
|
|
98
|
-
Alternatively, you can use your own component as a description by assigning it an \`id\` and passing the same value to the \`aria-describedby\` prop in \`${n}\`. If the description is confusing or duplicative for sighted users, you can use the \`@radix-ui/react-visually-hidden\` primitive as a wrapper around your description component.
|
|
99
|
-
|
|
100
|
-
For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;
|
|
101
|
-
return s.useEffect(() => {
|
|
102
|
-
var t;
|
|
103
|
-
document.getElementById(
|
|
104
|
-
(t = e.current) == null ? void 0 : t.getAttribute("aria-describedby")
|
|
105
|
-
) || console.warn(o);
|
|
106
|
-
}, [o, e]), null;
|
|
107
|
-
}, le = m, Z = h, ne = y, ce = _, pe = N, de = P, ge = b, ue = C, Ae = E;
|
|
108
|
-
const ve = ({
|
|
109
|
-
text: e,
|
|
110
|
-
theme: o,
|
|
111
|
-
onOpen: r
|
|
112
|
-
}) => {
|
|
113
|
-
const { theme: t } = q();
|
|
114
|
-
return /* @__PURE__ */ i(Z, { asChild: !0, children: /* @__PURE__ */ i(k, { type: "button", theme: o ?? t, onClick: r, children: e }) });
|
|
115
|
-
};
|
|
116
|
-
export {
|
|
117
|
-
ve as A,
|
|
118
|
-
pe as C,
|
|
119
|
-
Ae as D,
|
|
120
|
-
ce as O,
|
|
121
|
-
ne as P,
|
|
122
|
-
le as R,
|
|
123
|
-
ue as T,
|
|
124
|
-
ge as a,
|
|
125
|
-
de as b
|
|
126
|
-
};
|
package/dist/plugins/index.js
DELETED
|
@@ -1,118 +0,0 @@
|
|
|
1
|
-
import { g as m } from "../_commonjsHelpers-C6fGbg64.js";
|
|
2
|
-
import { addAnimationStyles as p, defaultAnimationThemeValues as c } from "./utils/animation.styles.js";
|
|
3
|
-
import { konstructColors as _ } from "./utils/colors.js";
|
|
4
|
-
var o = {}, l = {}, s;
|
|
5
|
-
function P() {
|
|
6
|
-
return s || (s = 1, function(e) {
|
|
7
|
-
Object.defineProperty(e, "__esModule", {
|
|
8
|
-
value: !0
|
|
9
|
-
}), Object.defineProperty(e, "default", {
|
|
10
|
-
enumerable: !0,
|
|
11
|
-
get: function() {
|
|
12
|
-
return i;
|
|
13
|
-
}
|
|
14
|
-
});
|
|
15
|
-
function n(r, t) {
|
|
16
|
-
return {
|
|
17
|
-
handler: r,
|
|
18
|
-
config: t
|
|
19
|
-
};
|
|
20
|
-
}
|
|
21
|
-
n.withOptions = function(r, t = () => ({})) {
|
|
22
|
-
const u = function(a) {
|
|
23
|
-
return {
|
|
24
|
-
__options: a,
|
|
25
|
-
handler: r(a),
|
|
26
|
-
config: t(a)
|
|
27
|
-
};
|
|
28
|
-
};
|
|
29
|
-
return u.__isOptionsFunction = !0, u.__pluginFunction = r, u.__configFunction = t, u;
|
|
30
|
-
};
|
|
31
|
-
const i = n;
|
|
32
|
-
}(l)), l;
|
|
33
|
-
}
|
|
34
|
-
var f;
|
|
35
|
-
function v() {
|
|
36
|
-
return f || (f = 1, function(e) {
|
|
37
|
-
Object.defineProperty(e, "__esModule", {
|
|
38
|
-
value: !0
|
|
39
|
-
}), Object.defineProperty(e, "default", {
|
|
40
|
-
enumerable: !0,
|
|
41
|
-
get: function() {
|
|
42
|
-
return r;
|
|
43
|
-
}
|
|
44
|
-
});
|
|
45
|
-
const n = /* @__PURE__ */ i(/* @__PURE__ */ P());
|
|
46
|
-
function i(t) {
|
|
47
|
-
return t && t.__esModule ? t : {
|
|
48
|
-
default: t
|
|
49
|
-
};
|
|
50
|
-
}
|
|
51
|
-
const r = n.default;
|
|
52
|
-
}(o)), o;
|
|
53
|
-
}
|
|
54
|
-
var d, g;
|
|
55
|
-
function b() {
|
|
56
|
-
if (g) return d;
|
|
57
|
-
g = 1;
|
|
58
|
-
let e = /* @__PURE__ */ v();
|
|
59
|
-
return d = (e.__esModule ? e : { default: e }).default, d;
|
|
60
|
-
}
|
|
61
|
-
var h = /* @__PURE__ */ b();
|
|
62
|
-
const k = /* @__PURE__ */ m(h), q = k(
|
|
63
|
-
function({ addBase: e, addUtilities: n, matchUtilities: i, theme: r }) {
|
|
64
|
-
e({
|
|
65
|
-
":root": {
|
|
66
|
-
"--viewport-padding": "25px"
|
|
67
|
-
}
|
|
68
|
-
}), p({ addUtilities: n, matchUtilities: i, theme: r });
|
|
69
|
-
},
|
|
70
|
-
{
|
|
71
|
-
theme: {
|
|
72
|
-
extend: {
|
|
73
|
-
colors: { ..._ },
|
|
74
|
-
viewportPadding: "",
|
|
75
|
-
...c,
|
|
76
|
-
backgroundImage: {
|
|
77
|
-
"kubefirst-gradient": "linear-gradient(90deg, #81E2B4, #8851C8)"
|
|
78
|
-
},
|
|
79
|
-
animation: {
|
|
80
|
-
"gradient-move": "moveGradient 6s linear infinite",
|
|
81
|
-
"slide-in": "slideIn 150ms cubic-bezier(0.16, 1, 0.3, 1)",
|
|
82
|
-
"swipe-out": "swipeOut 150ms cubic-bezier(0.16, 1, 0.3, 1)"
|
|
83
|
-
},
|
|
84
|
-
keyframes: {
|
|
85
|
-
moveGradient: {
|
|
86
|
-
"0%": { backgroundPosition: "0% 50%" },
|
|
87
|
-
"50%": { backgroundPosition: "100% 50%" },
|
|
88
|
-
"100%": { backgroundPosition: "0% 50%" }
|
|
89
|
-
},
|
|
90
|
-
hide: {
|
|
91
|
-
from: { opacity: "1" },
|
|
92
|
-
to: { opacity: "0" }
|
|
93
|
-
},
|
|
94
|
-
slideIn: {
|
|
95
|
-
from: {
|
|
96
|
-
transform: "translateX(calc(100% + var(--viewport-padding)))"
|
|
97
|
-
},
|
|
98
|
-
to: {
|
|
99
|
-
transform: "translateX(0)"
|
|
100
|
-
}
|
|
101
|
-
},
|
|
102
|
-
swipeOut: {
|
|
103
|
-
from: {
|
|
104
|
-
transform: "translateX(0)"
|
|
105
|
-
},
|
|
106
|
-
to: {
|
|
107
|
-
transform: "translateX(calc(100% + var(--viewport-padding)))"
|
|
108
|
-
}
|
|
109
|
-
},
|
|
110
|
-
...c.keyframes
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
}
|
|
115
|
-
);
|
|
116
|
-
export {
|
|
117
|
-
q as konstructPlugin
|
|
118
|
-
};
|