@drjoshcsimmons/scl 0.1.14 → 0.2.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/LICENSE +1 -1
- package/dist/components/ui/accordion/accordion.d.ts +1 -1
- package/dist/components/ui/accordion/accordion.d.ts.map +1 -1
- package/dist/components/ui/accordion/index.d.ts +1 -1
- package/dist/components/ui/accordion/index.d.ts.map +1 -1
- package/dist/components/ui/alert/alert.d.ts.map +1 -1
- package/dist/components/ui/alert/index.d.ts +1 -1
- package/dist/components/ui/alert/index.d.ts.map +1 -1
- package/dist/components/ui/alert-dialog/alert-dialog.d.ts +2 -2
- package/dist/components/ui/alert-dialog/alert-dialog.d.ts.map +1 -1
- package/dist/components/ui/alert-dialog/index.d.ts +1 -1
- package/dist/components/ui/alert-dialog/index.d.ts.map +1 -1
- package/dist/components/ui/avatar/avatar.d.ts +1 -1
- package/dist/components/ui/avatar/avatar.d.ts.map +1 -1
- package/dist/components/ui/avatar/index.d.ts +1 -1
- package/dist/components/ui/avatar/index.d.ts.map +1 -1
- package/dist/components/ui/badge/badge.d.ts +1 -1
- package/dist/components/ui/badge/badge.d.ts.map +1 -1
- package/dist/components/ui/badge/index.d.ts +1 -1
- package/dist/components/ui/badge/index.d.ts.map +1 -1
- package/dist/components/ui/button/button.d.ts.map +1 -1
- package/dist/components/ui/button/index.d.ts +1 -1
- package/dist/components/ui/button/index.d.ts.map +1 -1
- package/dist/components/ui/card/card.d.ts.map +1 -1
- package/dist/components/ui/card/index.d.ts +1 -1
- package/dist/components/ui/card/index.d.ts.map +1 -1
- package/dist/components/ui/checkbox/checkbox.d.ts +1 -1
- package/dist/components/ui/checkbox/checkbox.d.ts.map +1 -1
- package/dist/components/ui/checkbox/index.d.ts.map +1 -1
- package/dist/components/ui/collapsible/collapsible.d.ts.map +1 -1
- package/dist/components/ui/collapsible/index.d.ts +1 -1
- package/dist/components/ui/collapsible/index.d.ts.map +1 -1
- package/dist/components/ui/combobox/combobox.d.ts.map +1 -1
- package/dist/components/ui/combobox/index.d.ts +1 -1
- package/dist/components/ui/combobox/index.d.ts.map +1 -1
- package/dist/components/ui/command/command.d.ts.map +1 -1
- package/dist/components/ui/command/index.d.ts +1 -1
- package/dist/components/ui/command/index.d.ts.map +1 -1
- package/dist/components/ui/dialog/dialog.d.ts +1 -1
- package/dist/components/ui/dialog/dialog.d.ts.map +1 -1
- package/dist/components/ui/dialog/index.d.ts +1 -1
- package/dist/components/ui/dialog/index.d.ts.map +1 -1
- package/dist/components/ui/dithered-image/dithered-image.d.ts.map +1 -1
- package/dist/components/ui/dithered-image/index.d.ts +1 -1
- package/dist/components/ui/dithered-image/index.d.ts.map +1 -1
- package/dist/components/ui/dropdown-menu/dropdown-menu.d.ts +1 -1
- package/dist/components/ui/dropdown-menu/dropdown-menu.d.ts.map +1 -1
- package/dist/components/ui/dropdown-menu/index.d.ts +1 -1
- package/dist/components/ui/dropdown-menu/index.d.ts.map +1 -1
- package/dist/components/ui/form/form.d.ts +1 -1
- package/dist/components/ui/form/form.d.ts.map +1 -1
- package/dist/components/ui/form/index.d.ts +1 -1
- package/dist/components/ui/form/index.d.ts.map +1 -1
- package/dist/components/ui/input/index.d.ts.map +1 -1
- package/dist/components/ui/input/input.d.ts.map +1 -1
- package/dist/components/ui/label/index.d.ts.map +1 -1
- package/dist/components/ui/label/label.d.ts +1 -1
- package/dist/components/ui/label/label.d.ts.map +1 -1
- package/dist/components/ui/popover/index.d.ts +1 -1
- package/dist/components/ui/popover/index.d.ts.map +1 -1
- package/dist/components/ui/popover/popover.d.ts +1 -1
- package/dist/components/ui/popover/popover.d.ts.map +1 -1
- package/dist/components/ui/progress/index.d.ts.map +1 -1
- package/dist/components/ui/progress/progress.d.ts +1 -1
- package/dist/components/ui/progress/progress.d.ts.map +1 -1
- package/dist/components/ui/radio-group/index.d.ts.map +1 -1
- package/dist/components/ui/radio-group/radio-group.d.ts +1 -1
- package/dist/components/ui/radio-group/radio-group.d.ts.map +1 -1
- package/dist/components/ui/scroll-area/index.d.ts.map +1 -1
- package/dist/components/ui/scroll-area/scroll-area.d.ts +1 -1
- package/dist/components/ui/scroll-area/scroll-area.d.ts.map +1 -1
- package/dist/components/ui/select/index.d.ts +1 -1
- package/dist/components/ui/select/index.d.ts.map +1 -1
- package/dist/components/ui/select/select.d.ts +1 -1
- package/dist/components/ui/select/select.d.ts.map +1 -1
- package/dist/components/ui/separator/index.d.ts.map +1 -1
- package/dist/components/ui/separator/separator.d.ts +1 -1
- package/dist/components/ui/separator/separator.d.ts.map +1 -1
- package/dist/components/ui/sheet/index.d.ts +1 -1
- package/dist/components/ui/sheet/index.d.ts.map +1 -1
- package/dist/components/ui/sheet/sheet.d.ts +2 -2
- package/dist/components/ui/sheet/sheet.d.ts.map +1 -1
- package/dist/components/ui/skeleton/index.d.ts.map +1 -1
- package/dist/components/ui/skeleton/skeleton.d.ts.map +1 -1
- package/dist/components/ui/slider/index.d.ts.map +1 -1
- package/dist/components/ui/slider/slider.d.ts +1 -1
- package/dist/components/ui/slider/slider.d.ts.map +1 -1
- package/dist/components/ui/statusline/index.d.ts.map +1 -1
- package/dist/components/ui/statusline/statusline.d.ts.map +1 -1
- package/dist/components/ui/switch/index.d.ts.map +1 -1
- package/dist/components/ui/switch/switch.d.ts +1 -1
- package/dist/components/ui/switch/switch.d.ts.map +1 -1
- package/dist/components/ui/table/index.d.ts +1 -1
- package/dist/components/ui/table/index.d.ts.map +1 -1
- package/dist/components/ui/table/table.d.ts +1 -1
- package/dist/components/ui/table/table.d.ts.map +1 -1
- package/dist/components/ui/tabs/index.d.ts +1 -1
- package/dist/components/ui/tabs/index.d.ts.map +1 -1
- package/dist/components/ui/tabs/tabs.d.ts +1 -1
- package/dist/components/ui/tabs/tabs.d.ts.map +1 -1
- package/dist/components/ui/terminal-textarea/index.d.ts.map +1 -1
- package/dist/components/ui/terminal-textarea/terminal-textarea.d.ts.map +1 -1
- package/dist/components/ui/textarea/index.d.ts.map +1 -1
- package/dist/components/ui/textarea/textarea.d.ts.map +1 -1
- package/dist/components/ui/toggle/index.d.ts.map +1 -1
- package/dist/components/ui/toggle/toggle.d.ts +1 -1
- package/dist/components/ui/toggle/toggle.d.ts.map +1 -1
- package/dist/components/ui/tooltip/index.d.ts +1 -1
- package/dist/components/ui/tooltip/index.d.ts.map +1 -1
- package/dist/components/ui/tooltip/tooltip.d.ts +1 -1
- package/dist/components/ui/tooltip/tooltip.d.ts.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +12 -12
- package/dist/index10.js +42 -44
- package/dist/index100.js +4 -13
- package/dist/index101.js +30 -9
- package/dist/index102.js +13 -30
- package/dist/index103.js +649 -3
- package/dist/index104.js +30 -25
- package/dist/index105.js +3 -5
- package/dist/index106.js +44 -51
- package/dist/index107.js +30 -30
- package/dist/index108.js +55 -30
- package/dist/index109.js +29 -47
- package/dist/index11.js +5 -11
- package/dist/index110.js +44 -646
- package/dist/index113.js +47 -11
- package/dist/index114.js +42 -200
- package/dist/index115.js +12 -22
- package/dist/index116.js +194 -388
- package/dist/index117.js +21 -47
- package/dist/index118.js +392 -40
- package/dist/index119.js +6 -21
- package/dist/index12.js +2 -2
- package/dist/index120.js +48 -9
- package/dist/index121.js +15 -32
- package/dist/index122.js +3 -12
- package/dist/index123.js +38 -6
- package/dist/index124.js +18 -48
- package/dist/index126.js +3 -3
- package/dist/index127.js +3 -3
- package/dist/index129.js +1 -1
- package/dist/index13.js +2 -2
- package/dist/index130.js +1 -1
- package/dist/index131.js +2 -5
- package/dist/index132.js +2 -3
- package/dist/index133.js +5 -24
- package/dist/index134.js +3 -113
- package/dist/index135.js +23 -15
- package/dist/index136.js +107 -519
- package/dist/index137.js +14 -126
- package/dist/index138.js +516 -125
- package/dist/index139.js +128 -2
- package/dist/index14.js +4 -13
- package/dist/index140.js +134 -2
- package/dist/index141.js +65 -69
- package/dist/index142.js +68 -8
- package/dist/index143.js +9 -14
- package/dist/index144.js +14 -66
- package/dist/index145.js +65 -64
- package/dist/index15.js +43 -67
- package/dist/index16.js +3 -30
- package/dist/index17.js +75 -80
- package/dist/index18.js +11 -13
- package/dist/index19.js +4 -4
- package/dist/index20.js +5 -12
- package/dist/index21.js +15 -15
- package/dist/index22.js +21 -24
- package/dist/index23.js +7 -14
- package/dist/index24.js +11 -11
- package/dist/index25.js +66 -72
- package/dist/index26.js +15 -17
- package/dist/index27.js +57 -51
- package/dist/index28.js +2 -10
- package/dist/index29.js +9 -12
- package/dist/index3.js +18 -18
- package/dist/index30.js +27 -60
- package/dist/index31.js +15 -15
- package/dist/index32.js +24 -47
- package/dist/index33.js +16 -16
- package/dist/index34.js +1 -4
- package/dist/index36.js +11 -11
- package/dist/index37.js +21 -18
- package/dist/index38.js +99 -38
- package/dist/index39.js +37 -64
- package/dist/index4.js +24 -31
- package/dist/index40.js +10 -48
- package/dist/index41.js +48 -99
- package/dist/index42.js +65 -10
- package/dist/index45.js +237 -33
- package/dist/index46.js +11 -241
- package/dist/index47.js +33 -237
- package/dist/index48.js +241 -11
- package/dist/index49.js +16 -258
- package/dist/index5.js +13 -26
- package/dist/index50.js +125 -12
- package/dist/index51.js +25 -524
- package/dist/index52.js +71 -20
- package/dist/index53.js +206 -131
- package/dist/index54.js +11 -73
- package/dist/index55.js +54 -330
- package/dist/index56.js +249 -231
- package/dist/index57.js +225 -11
- package/dist/index58.js +9 -82
- package/dist/index59.js +11 -249
- package/dist/index6.js +66 -36
- package/dist/index60.js +130 -9
- package/dist/index61.js +21 -129
- package/dist/index62.js +860 -18
- package/dist/index63.js +9 -860
- package/dist/index64.js +82 -9
- package/dist/index65.js +256 -27
- package/dist/index66.js +12 -435
- package/dist/index67.js +244 -55
- package/dist/index68.js +7 -7
- package/dist/index69.js +511 -206
- package/dist/index7.js +5 -5
- package/dist/index70.js +5 -4
- package/dist/index71.js +435 -12
- package/dist/index72.js +318 -107
- package/dist/index73.js +3 -3
- package/dist/index74.js +1 -1
- package/dist/index75.js +156 -249
- package/dist/index76.js +66 -5
- package/dist/index77.js +44 -25
- package/dist/index78.js +23 -64
- package/dist/index79.js +5 -123
- package/dist/index8.js +5 -5
- package/dist/index80.js +50 -13
- package/dist/index81.js +32 -133
- package/dist/index82.js +1 -1
- package/dist/index83.js +7 -218
- package/dist/index84.js +124 -13
- package/dist/index85.js +13 -67
- package/dist/index86.js +133 -32
- package/dist/index87.js +216 -45
- package/dist/index88.js +14 -52
- package/dist/index89.js +66 -47
- package/dist/index9.js +19 -26
- package/dist/index90.js +48 -9
- package/dist/index91.js +49 -45
- package/dist/index92.js +9 -8
- package/dist/index93.js +29 -47
- package/dist/index94.js +9 -30
- package/dist/index95.js +8 -8
- package/dist/index96.js +24 -54
- package/dist/index97.js +5 -10
- package/dist/index98.js +55 -4
- package/dist/index99.js +11 -30
- package/dist/lib/utils.d.ts.map +1 -1
- package/dist/tokens/animations.d.ts.map +1 -1
- package/dist/tokens/colors.d.ts.map +1 -1
- package/dist/tokens/index.d.ts +3 -3
- package/dist/tokens/index.d.ts.map +1 -1
- package/dist/tokens/shadows.d.ts.map +1 -1
- package/dist/tokens/spacing.d.ts.map +1 -1
- package/dist/tokens/typography.d.ts.map +1 -1
- package/package.json +19 -9
package/dist/index88.js
CHANGED
|
@@ -1,54 +1,16 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
},
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
}), c = t !== void 0, a = c ? t : l;
|
|
15
|
-
{
|
|
16
|
-
const s = n.useRef(t !== void 0);
|
|
17
|
-
n.useEffect(() => {
|
|
18
|
-
const f = s.current;
|
|
19
|
-
f !== c && console.warn(
|
|
20
|
-
`${i} is changing from ${f ? "controlled" : "uncontrolled"} to ${c ? "controlled" : "uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`
|
|
21
|
-
), s.current = c;
|
|
22
|
-
}, [c, i]);
|
|
23
|
-
}
|
|
24
|
-
const m = n.useCallback(
|
|
25
|
-
(s) => {
|
|
26
|
-
var f;
|
|
27
|
-
if (c) {
|
|
28
|
-
const d = R(s) ? s(t) : s;
|
|
29
|
-
d !== t && ((f = r.current) == null || f.call(r, d));
|
|
30
|
-
} else
|
|
31
|
-
e(s);
|
|
32
|
-
},
|
|
33
|
-
[c, t, e, r]
|
|
34
|
-
);
|
|
35
|
-
return [a, m];
|
|
36
|
-
}
|
|
37
|
-
function w({
|
|
38
|
-
defaultProp: t,
|
|
39
|
-
onChange: u
|
|
40
|
-
}) {
|
|
41
|
-
const [o, i] = n.useState(t), l = n.useRef(o), e = n.useRef(u);
|
|
42
|
-
return E(() => {
|
|
43
|
-
e.current = u;
|
|
44
|
-
}, [u]), n.useEffect(() => {
|
|
45
|
-
var r;
|
|
46
|
-
l.current !== o && ((r = e.current) == null || r.call(e, o), l.current = o);
|
|
47
|
-
}, [o, l]), [o, i, e];
|
|
48
|
-
}
|
|
49
|
-
function R(t) {
|
|
50
|
-
return typeof t == "function";
|
|
51
|
-
}
|
|
1
|
+
import * as r from "react";
|
|
2
|
+
import s from "react-dom";
|
|
3
|
+
import { Primitive as c } from "./index81.js";
|
|
4
|
+
import { useLayoutEffect as u } from "./index100.js";
|
|
5
|
+
import { jsx as l } from "react/jsx-runtime";
|
|
6
|
+
var p = "Portal", d = r.forwardRef((e, a) => {
|
|
7
|
+
var o;
|
|
8
|
+
const { container: f, ...i } = e, [m, n] = r.useState(!1);
|
|
9
|
+
u(() => n(!0), []);
|
|
10
|
+
const t = f || m && ((o = globalThis == null ? void 0 : globalThis.document) == null ? void 0 : o.body);
|
|
11
|
+
return t ? s.createPortal(/* @__PURE__ */ l(c.div, { ...i, ref: a }), t) : null;
|
|
12
|
+
});
|
|
13
|
+
d.displayName = p;
|
|
52
14
|
export {
|
|
53
|
-
|
|
15
|
+
d as Portal
|
|
54
16
|
};
|
package/dist/index89.js
CHANGED
|
@@ -1,52 +1,71 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
return
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
},
|
|
9
|
-
return
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
1
|
+
import * as a from "react";
|
|
2
|
+
import { useComposedRefs as E } from "./index78.js";
|
|
3
|
+
import { useLayoutEffect as A } from "./index100.js";
|
|
4
|
+
function T(n, e) {
|
|
5
|
+
return a.useReducer((r, t) => e[r][t] ?? r, n);
|
|
6
|
+
}
|
|
7
|
+
var R = (n) => {
|
|
8
|
+
const { present: e, children: r } = n, t = v(e), i = typeof r == "function" ? r({ present: t.isPresent }) : a.Children.only(r), c = E(t.ref, P(i));
|
|
9
|
+
return typeof r == "function" || t.isPresent ? a.cloneElement(i, { ref: c }) : null;
|
|
10
|
+
};
|
|
11
|
+
R.displayName = "Presence";
|
|
12
|
+
function v(n) {
|
|
13
|
+
const [e, r] = a.useState(), t = a.useRef(null), i = a.useRef(n), c = a.useRef("none"), p = n ? "mounted" : "unmounted", [N, s] = T(p, {
|
|
14
|
+
mounted: {
|
|
15
|
+
UNMOUNT: "unmounted",
|
|
16
|
+
ANIMATION_OUT: "unmountSuspended"
|
|
17
|
+
},
|
|
18
|
+
unmountSuspended: {
|
|
19
|
+
MOUNT: "mounted",
|
|
20
|
+
ANIMATION_END: "unmounted"
|
|
21
|
+
},
|
|
22
|
+
unmounted: {
|
|
23
|
+
MOUNT: "mounted"
|
|
24
|
+
}
|
|
16
25
|
});
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
26
|
+
return a.useEffect(() => {
|
|
27
|
+
const o = l(t.current);
|
|
28
|
+
c.current = N === "mounted" ? o : "none";
|
|
29
|
+
}, [N]), A(() => {
|
|
30
|
+
const o = t.current, m = i.current;
|
|
31
|
+
if (m !== n) {
|
|
32
|
+
const f = c.current, u = l(o);
|
|
33
|
+
n ? s("MOUNT") : u === "none" || (o == null ? void 0 : o.display) === "none" ? s("UNMOUNT") : s(m && f !== u ? "ANIMATION_OUT" : "UNMOUNT"), i.current = n;
|
|
34
|
+
}
|
|
35
|
+
}, [n, s]), A(() => {
|
|
36
|
+
if (e) {
|
|
37
|
+
let o;
|
|
38
|
+
const m = e.ownerDocument.defaultView ?? window, d = (u) => {
|
|
39
|
+
const g = l(t.current).includes(CSS.escape(u.animationName));
|
|
40
|
+
if (u.target === e && g && (s("ANIMATION_END"), !i.current)) {
|
|
41
|
+
const O = e.style.animationFillMode;
|
|
42
|
+
e.style.animationFillMode = "forwards", o = m.setTimeout(() => {
|
|
43
|
+
e.style.animationFillMode === "forwards" && (e.style.animationFillMode = O);
|
|
44
|
+
});
|
|
34
45
|
}
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
}
|
|
46
|
+
}, f = (u) => {
|
|
47
|
+
u.target === e && (c.current = l(t.current));
|
|
48
|
+
};
|
|
49
|
+
return e.addEventListener("animationstart", f), e.addEventListener("animationcancel", d), e.addEventListener("animationend", d), () => {
|
|
50
|
+
m.clearTimeout(o), e.removeEventListener("animationstart", f), e.removeEventListener("animationcancel", d), e.removeEventListener("animationend", d);
|
|
51
|
+
};
|
|
52
|
+
} else
|
|
53
|
+
s("ANIMATION_END");
|
|
54
|
+
}, [e, s]), {
|
|
55
|
+
isPresent: ["mounted", "unmountSuspended"].includes(N),
|
|
56
|
+
ref: a.useCallback((o) => {
|
|
57
|
+
t.current = o ? getComputedStyle(o) : null, r(o);
|
|
58
|
+
}, [])
|
|
42
59
|
};
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
60
|
+
}
|
|
61
|
+
function l(n) {
|
|
62
|
+
return (n == null ? void 0 : n.animationName) || "none";
|
|
63
|
+
}
|
|
64
|
+
function P(n) {
|
|
65
|
+
var t, i;
|
|
66
|
+
let e = (t = Object.getOwnPropertyDescriptor(n.props, "ref")) == null ? void 0 : t.get, r = e && "isReactWarning" in e && e.isReactWarning;
|
|
67
|
+
return r ? n.ref : (e = (i = Object.getOwnPropertyDescriptor(n, "ref")) == null ? void 0 : i.get, r = e && "isReactWarning" in e && e.isReactWarning, r ? n.props.ref : n.props.ref || n.ref);
|
|
68
|
+
}
|
|
50
69
|
export {
|
|
51
|
-
|
|
70
|
+
R as Presence
|
|
52
71
|
};
|
package/dist/index9.js
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import { cn as
|
|
6
|
-
const p =
|
|
7
|
-
"inline-flex items-center justify-center gap-2 whitespace-nowrap font-mono font-bold uppercase tracking-wider
|
|
1
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import { Root as s } from "./index55.js";
|
|
3
|
+
import { cva as d } from "./index47.js";
|
|
4
|
+
import * as c from "react";
|
|
5
|
+
import { cn as v } from "./index2.js";
|
|
6
|
+
const p = d(
|
|
7
|
+
"inline-flex items-center justify-center gap-2 whitespace-nowrap font-mono font-bold uppercase tracking-wider cursor-pointer focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:pointer-events-none disabled:opacity-30 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
|
|
8
8
|
{
|
|
9
9
|
variants: {
|
|
10
10
|
variant: {
|
|
11
|
-
default: "bg-primary text-primary-foreground border-2 border-primary hover:bg-primary
|
|
12
|
-
secondary: "bg-secondary text-secondary-foreground border-2 border-secondary hover:bg-secondary
|
|
13
|
-
outline: "bg-transparent text-primary border-2 border-primary hover:bg-primary
|
|
14
|
-
"secondary-outline": "bg-transparent text-secondary border-2 border-secondary hover:bg-secondary
|
|
15
|
-
ghost: "bg-transparent text-primary border-2 border-transparent hover:border-primary
|
|
16
|
-
link: "bg-transparent text-primary underline-offset-4 hover:underline border-none",
|
|
17
|
-
destructive: "bg-destructive text-destructive-foreground border-2 border-destructive hover:bg-destructive
|
|
18
|
-
"destructive-outline": "bg-transparent text-destructive border-2 border-destructive hover:bg-destructive
|
|
11
|
+
default: "bg-primary text-primary-foreground border-2 border-primary hover:bg-transparent hover:text-primary active:bg-primary active:text-primary-foreground active:border-primary-foreground",
|
|
12
|
+
secondary: "bg-secondary text-secondary-foreground border-2 border-secondary hover:bg-transparent hover:text-secondary active:bg-secondary active:text-secondary-foreground active:border-secondary-foreground",
|
|
13
|
+
outline: "bg-transparent text-primary border-2 border-primary hover:bg-primary hover:text-primary-foreground active:bg-transparent active:text-primary active:border-primary-foreground",
|
|
14
|
+
"secondary-outline": "bg-transparent text-secondary border-2 border-secondary hover:bg-secondary hover:text-secondary-foreground active:bg-transparent active:text-secondary active:border-secondary-foreground",
|
|
15
|
+
ghost: "bg-transparent text-primary border-2 border-transparent hover:border-primary hover:bg-primary hover:text-primary-foreground active:bg-transparent active:border-primary-foreground active:text-primary",
|
|
16
|
+
link: "bg-transparent text-primary underline-offset-4 hover:underline border-none active:no-underline",
|
|
17
|
+
destructive: "bg-destructive text-destructive-foreground border-2 border-destructive hover:bg-transparent hover:text-destructive active:bg-destructive active:text-destructive-foreground active:border-destructive-foreground",
|
|
18
|
+
"destructive-outline": "bg-transparent text-destructive border-2 border-destructive hover:bg-destructive hover:text-destructive-foreground active:bg-transparent active:text-destructive active:border-destructive-foreground"
|
|
19
19
|
},
|
|
20
20
|
size: {
|
|
21
21
|
default: "h-11 px-6 py-3 text-sm",
|
|
@@ -29,18 +29,11 @@ const p = b(
|
|
|
29
29
|
size: "default"
|
|
30
30
|
}
|
|
31
31
|
}
|
|
32
|
-
),
|
|
33
|
-
({ className: r, variant: e, size: t, asChild: o = !1, ...
|
|
34
|
-
o ? d : "button",
|
|
35
|
-
{
|
|
36
|
-
className: c(p({ variant: e, size: t, className: r })),
|
|
37
|
-
ref: a,
|
|
38
|
-
...i
|
|
39
|
-
}
|
|
40
|
-
)
|
|
32
|
+
), u = c.forwardRef(
|
|
33
|
+
({ className: r, variant: e, size: t, asChild: o = !1, ...a }, n) => /* @__PURE__ */ i(o ? s : "button", { className: v(p({ variant: e, size: t, className: r })), ref: n, ...a })
|
|
41
34
|
);
|
|
42
|
-
|
|
35
|
+
u.displayName = "Button";
|
|
43
36
|
export {
|
|
44
|
-
|
|
37
|
+
u as Button,
|
|
45
38
|
p as buttonVariants
|
|
46
39
|
};
|
package/dist/index90.js
CHANGED
|
@@ -1,11 +1,50 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
});
|
|
8
|
-
|
|
1
|
+
import * as l from "react";
|
|
2
|
+
import { composeRefs as m } from "./index78.js";
|
|
3
|
+
import { jsx as u } from "react/jsx-runtime";
|
|
4
|
+
// @__NO_SIDE_EFFECTS__
|
|
5
|
+
function b(e) {
|
|
6
|
+
const n = /* @__PURE__ */ y(e), o = l.forwardRef((t, r) => {
|
|
7
|
+
const { children: i, ...c } = t, s = l.Children.toArray(i), a = s.find(E);
|
|
8
|
+
if (a) {
|
|
9
|
+
const f = a.props.children, d = s.map((p) => p === a ? l.Children.count(f) > 1 ? l.Children.only(null) : l.isValidElement(f) ? f.props.children : null : p);
|
|
10
|
+
return /* @__PURE__ */ u(n, { ...c, ref: r, children: l.isValidElement(f) ? l.cloneElement(f, void 0, d) : null });
|
|
11
|
+
}
|
|
12
|
+
return /* @__PURE__ */ u(n, { ...c, ref: r, children: i });
|
|
13
|
+
});
|
|
14
|
+
return o.displayName = `${e}.Slot`, o;
|
|
15
|
+
}
|
|
16
|
+
// @__NO_SIDE_EFFECTS__
|
|
17
|
+
function y(e) {
|
|
18
|
+
const n = l.forwardRef((o, t) => {
|
|
19
|
+
const { children: r, ...i } = o;
|
|
20
|
+
if (l.isValidElement(r)) {
|
|
21
|
+
const c = S(r), s = C(i, r.props);
|
|
22
|
+
return r.type !== l.Fragment && (s.ref = t ? m(t, c) : c), l.cloneElement(r, s);
|
|
23
|
+
}
|
|
24
|
+
return l.Children.count(r) > 1 ? l.Children.only(null) : null;
|
|
25
|
+
});
|
|
26
|
+
return n.displayName = `${e}.SlotClone`, n;
|
|
27
|
+
}
|
|
28
|
+
var g = Symbol("radix.slottable");
|
|
29
|
+
function E(e) {
|
|
30
|
+
return l.isValidElement(e) && typeof e.type == "function" && "__radixId" in e.type && e.type.__radixId === g;
|
|
31
|
+
}
|
|
32
|
+
function C(e, n) {
|
|
33
|
+
const o = { ...n };
|
|
34
|
+
for (const t in n) {
|
|
35
|
+
const r = e[t], i = n[t];
|
|
36
|
+
/^on[A-Z]/.test(t) ? r && i ? o[t] = (...s) => {
|
|
37
|
+
const a = i(...s);
|
|
38
|
+
return r(...s), a;
|
|
39
|
+
} : r && (o[t] = r) : t === "style" ? o[t] = { ...r, ...i } : t === "className" && (o[t] = [r, i].filter(Boolean).join(" "));
|
|
40
|
+
}
|
|
41
|
+
return { ...e, ...o };
|
|
42
|
+
}
|
|
43
|
+
function S(e) {
|
|
44
|
+
var t, r;
|
|
45
|
+
let n = (t = Object.getOwnPropertyDescriptor(e.props, "ref")) == null ? void 0 : t.get, o = n && "isReactWarning" in n && n.isReactWarning;
|
|
46
|
+
return o ? e.ref : (n = (r = Object.getOwnPropertyDescriptor(e, "ref")) == null ? void 0 : r.get, o = n && "isReactWarning" in n && n.isReactWarning, o ? e.props.ref : e.props.ref || e.ref);
|
|
47
|
+
}
|
|
9
48
|
export {
|
|
10
|
-
|
|
49
|
+
b as createSlot
|
|
11
50
|
};
|
package/dist/index91.js
CHANGED
|
@@ -1,48 +1,52 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
1
|
+
var S = function(r) {
|
|
2
|
+
if (typeof document > "u")
|
|
3
|
+
return null;
|
|
4
|
+
var u = Array.isArray(r) ? r[0] : r;
|
|
5
|
+
return u.ownerDocument.body;
|
|
6
|
+
}, f = /* @__PURE__ */ new WeakMap(), v = /* @__PURE__ */ new WeakMap(), p = {}, h = 0, W = function(r) {
|
|
7
|
+
return r && (r.host || W(r.parentNode));
|
|
8
|
+
}, D = function(r, u) {
|
|
9
|
+
return u.map(function(e) {
|
|
10
|
+
if (r.contains(e))
|
|
11
|
+
return e;
|
|
12
|
+
var n = W(e);
|
|
13
|
+
return n && r.contains(n) ? n : (console.error("aria-hidden", e, "in not contained inside", r, ". Doing nothing"), null);
|
|
14
|
+
}).filter(function(e) {
|
|
15
|
+
return !!e;
|
|
16
|
+
});
|
|
17
|
+
}, E = function(r, u, e, n) {
|
|
18
|
+
var i = D(u, Array.isArray(r) ? r : [r]);
|
|
19
|
+
p[e] || (p[e] = /* @__PURE__ */ new WeakMap());
|
|
20
|
+
var s = p[e], l = [], o = /* @__PURE__ */ new Set(), b = new Set(i), y = function(t) {
|
|
21
|
+
!t || o.has(t) || (o.add(t), y(t.parentNode));
|
|
13
22
|
};
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
(
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
{ Provider: p, Slot: C, ItemSlot: I },
|
|
42
|
-
O,
|
|
43
|
-
N
|
|
44
|
-
];
|
|
45
|
-
}
|
|
23
|
+
i.forEach(y);
|
|
24
|
+
var A = function(t) {
|
|
25
|
+
!t || b.has(t) || Array.prototype.forEach.call(t.children, function(a) {
|
|
26
|
+
if (o.has(a))
|
|
27
|
+
A(a);
|
|
28
|
+
else
|
|
29
|
+
try {
|
|
30
|
+
var c = a.getAttribute(n), w = c !== null && c !== "false", d = (f.get(a) || 0) + 1, M = (s.get(a) || 0) + 1;
|
|
31
|
+
f.set(a, d), s.set(a, M), l.push(a), d === 1 && w && v.set(a, !0), M === 1 && a.setAttribute(e, "true"), w || a.setAttribute(n, "true");
|
|
32
|
+
} catch (k) {
|
|
33
|
+
console.error("aria-hidden: cannot operate on ", a, k);
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
};
|
|
37
|
+
return A(u), o.clear(), h++, function() {
|
|
38
|
+
l.forEach(function(t) {
|
|
39
|
+
var a = f.get(t) - 1, c = s.get(t) - 1;
|
|
40
|
+
f.set(t, a), s.set(t, c), a || (v.has(t) || t.removeAttribute(n), v.delete(t)), c || t.removeAttribute(e);
|
|
41
|
+
}), h--, h || (f = /* @__PURE__ */ new WeakMap(), f = /* @__PURE__ */ new WeakMap(), v = /* @__PURE__ */ new WeakMap(), p = {});
|
|
42
|
+
};
|
|
43
|
+
}, C = function(r, u, e) {
|
|
44
|
+
e === void 0 && (e = "data-aria-hidden");
|
|
45
|
+
var n = Array.from(Array.isArray(r) ? r : [r]), i = S(r);
|
|
46
|
+
return i ? (n.push.apply(n, Array.from(i.querySelectorAll("[aria-live], script"))), E(n, i, e, "aria-hidden")) : function() {
|
|
47
|
+
return null;
|
|
48
|
+
};
|
|
49
|
+
};
|
|
46
50
|
export {
|
|
47
|
-
|
|
51
|
+
C as hideOthers
|
|
48
52
|
};
|
package/dist/index92.js
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "react
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
return o
|
|
7
|
-
}
|
|
1
|
+
import { __assign as m } from "./index125.js";
|
|
2
|
+
import * as r from "react";
|
|
3
|
+
import { RemoveScroll as e } from "./index126.js";
|
|
4
|
+
import t from "./index127.js";
|
|
5
|
+
var s = r.forwardRef(function(a, o) {
|
|
6
|
+
return r.createElement(e, m({}, a, { ref: o, sideCar: t }));
|
|
7
|
+
});
|
|
8
|
+
s.classNames = e.classNames;
|
|
8
9
|
export {
|
|
9
|
-
|
|
10
|
+
s as default
|
|
10
11
|
};
|
package/dist/index93.js
CHANGED
|
@@ -1,50 +1,32 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
1
|
+
import * as f from "react";
|
|
2
|
+
import "react-dom";
|
|
3
|
+
import { createSlot as l } from "./index55.js";
|
|
4
|
+
import { jsx as n } from "react/jsx-runtime";
|
|
5
|
+
var u = [
|
|
6
|
+
"a",
|
|
7
|
+
"button",
|
|
8
|
+
"div",
|
|
9
|
+
"form",
|
|
10
|
+
"h2",
|
|
11
|
+
"h3",
|
|
12
|
+
"img",
|
|
13
|
+
"input",
|
|
14
|
+
"label",
|
|
15
|
+
"li",
|
|
16
|
+
"nav",
|
|
17
|
+
"ol",
|
|
18
|
+
"p",
|
|
19
|
+
"select",
|
|
20
|
+
"span",
|
|
21
|
+
"svg",
|
|
22
|
+
"ul"
|
|
23
|
+
], w = u.reduce((t, i) => {
|
|
24
|
+
const o = l(`Primitive.${i}`), r = f.forwardRef((e, m) => {
|
|
25
|
+
const { asChild: a, ...p } = e, s = a ? o : i;
|
|
26
|
+
return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ n(s, { ...p, ref: m });
|
|
13
27
|
});
|
|
14
|
-
return
|
|
15
|
-
}
|
|
16
|
-
// @__NO_SIDE_EFFECTS__
|
|
17
|
-
function y(e) {
|
|
18
|
-
const n = l.forwardRef((o, t) => {
|
|
19
|
-
const { children: r, ...i } = o;
|
|
20
|
-
if (l.isValidElement(r)) {
|
|
21
|
-
const c = S(r), s = C(i, r.props);
|
|
22
|
-
return r.type !== l.Fragment && (s.ref = t ? m(t, c) : c), l.cloneElement(r, s);
|
|
23
|
-
}
|
|
24
|
-
return l.Children.count(r) > 1 ? l.Children.only(null) : null;
|
|
25
|
-
});
|
|
26
|
-
return n.displayName = `${e}.SlotClone`, n;
|
|
27
|
-
}
|
|
28
|
-
var g = Symbol("radix.slottable");
|
|
29
|
-
function E(e) {
|
|
30
|
-
return l.isValidElement(e) && typeof e.type == "function" && "__radixId" in e.type && e.type.__radixId === g;
|
|
31
|
-
}
|
|
32
|
-
function C(e, n) {
|
|
33
|
-
const o = { ...n };
|
|
34
|
-
for (const t in n) {
|
|
35
|
-
const r = e[t], i = n[t];
|
|
36
|
-
/^on[A-Z]/.test(t) ? r && i ? o[t] = (...s) => {
|
|
37
|
-
const a = i(...s);
|
|
38
|
-
return r(...s), a;
|
|
39
|
-
} : r && (o[t] = r) : t === "style" ? o[t] = { ...r, ...i } : t === "className" && (o[t] = [r, i].filter(Boolean).join(" "));
|
|
40
|
-
}
|
|
41
|
-
return { ...e, ...o };
|
|
42
|
-
}
|
|
43
|
-
function S(e) {
|
|
44
|
-
var t, r;
|
|
45
|
-
let n = (t = Object.getOwnPropertyDescriptor(e.props, "ref")) == null ? void 0 : t.get, o = n && "isReactWarning" in n && n.isReactWarning;
|
|
46
|
-
return o ? e.ref : (n = (r = Object.getOwnPropertyDescriptor(e, "ref")) == null ? void 0 : r.get, o = n && "isReactWarning" in n && n.isReactWarning, o ? e.props.ref : e.props.ref || e.ref);
|
|
47
|
-
}
|
|
28
|
+
return r.displayName = `Primitive.${i}`, { ...t, [i]: r };
|
|
29
|
+
}, {});
|
|
48
30
|
export {
|
|
49
|
-
|
|
31
|
+
w as Primitive
|
|
50
32
|
};
|
package/dist/index94.js
CHANGED
|
@@ -1,32 +1,11 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "react-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
"form",
|
|
10
|
-
"h2",
|
|
11
|
-
"h3",
|
|
12
|
-
"img",
|
|
13
|
-
"input",
|
|
14
|
-
"label",
|
|
15
|
-
"li",
|
|
16
|
-
"nav",
|
|
17
|
-
"ol",
|
|
18
|
-
"p",
|
|
19
|
-
"select",
|
|
20
|
-
"span",
|
|
21
|
-
"svg",
|
|
22
|
-
"ul"
|
|
23
|
-
], w = u.reduce((t, i) => {
|
|
24
|
-
const o = l(`Primitive.${i}`), r = f.forwardRef((e, m) => {
|
|
25
|
-
const { asChild: a, ...p } = e, s = a ? o : i;
|
|
26
|
-
return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ n(s, { ...p, ref: m });
|
|
27
|
-
});
|
|
28
|
-
return r.displayName = `Primitive.${i}`, { ...t, [i]: r };
|
|
29
|
-
}, {});
|
|
1
|
+
import "react";
|
|
2
|
+
import { jsx as e, Fragment as o } from "react/jsx-runtime";
|
|
3
|
+
var l = Symbol("radix.slottable");
|
|
4
|
+
// @__NO_SIDE_EFFECTS__
|
|
5
|
+
function n(r) {
|
|
6
|
+
const t = ({ children: a }) => /* @__PURE__ */ e(o, { children: a });
|
|
7
|
+
return t.displayName = `${r}.Slottable`, t.__radixId = l, t;
|
|
8
|
+
}
|
|
30
9
|
export {
|
|
31
|
-
|
|
10
|
+
n as createSlottable
|
|
32
11
|
};
|
package/dist/index95.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import * as c from "react";
|
|
2
|
-
import { composeEventHandlers as p } from "./
|
|
3
|
-
import { createCollection as V } from "./
|
|
4
|
-
import { useComposedRefs as j } from "./
|
|
5
|
-
import { createContextScope as z } from "./
|
|
2
|
+
import { composeEventHandlers as p } from "./index79.js";
|
|
3
|
+
import { createCollection as V } from "./index77.js";
|
|
4
|
+
import { useComposedRefs as j } from "./index78.js";
|
|
5
|
+
import { createContextScope as z } from "./index76.js";
|
|
6
6
|
import { useId as q } from "./index82.js";
|
|
7
|
-
import { Primitive as G } from "./
|
|
8
|
-
import { useCallbackRef as J } from "./
|
|
9
|
-
import { useControllableState as Q } from "./
|
|
10
|
-
import { useDirection as W } from "./
|
|
7
|
+
import { Primitive as G } from "./index81.js";
|
|
8
|
+
import { useCallbackRef as J } from "./index99.js";
|
|
9
|
+
import { useControllableState as Q } from "./index80.js";
|
|
10
|
+
import { useDirection as W } from "./index83.js";
|
|
11
11
|
import { jsx as d } from "react/jsx-runtime";
|
|
12
12
|
var y = "rovingFocusGroup.onEntryFocus", X = { bubbles: !1, cancelable: !0 }, I = "RovingFocusGroup", [D, N, Z] = V(I), [$, Fe] = z(
|
|
13
13
|
I,
|