@drjoshcsimmons/scl 0.1.13 → 0.1.15
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/components/ui/dropdown-menu/dropdown-menu.d.ts.map +1 -1
- package/dist/index100.js +25 -30
- package/dist/index101.js +8 -12
- package/dist/index102.js +177 -51
- package/dist/index103.js +47 -29
- package/dist/index104.js +30 -4
- package/dist/index105.js +52 -216
- package/dist/index106.js +29 -47
- package/dist/index107.js +30 -30
- package/dist/index108.js +650 -30
- package/dist/index110.js +30 -9
- package/dist/index111.js +8 -180
- package/dist/index112.js +15 -30
- package/dist/index113.js +6 -48
- package/dist/index115.js +47 -11
- package/dist/index116.js +11 -47
- package/dist/index117.js +206 -6
- package/dist/index118.js +20 -204
- package/dist/index119.js +399 -21
- package/dist/index12.js +1 -1
- package/dist/index120.js +20 -399
- package/dist/index121.js +3 -15
- package/dist/index122.js +32 -3
- package/dist/index123.js +12 -32
- package/dist/index124.js +48 -18
- package/dist/index125.js +2 -25
- package/dist/index126.js +53 -29
- package/dist/index127.js +65 -5
- package/dist/index128.js +25 -2
- package/dist/index129.js +29 -53
- package/dist/index13.js +1 -1
- package/dist/index130.js +5 -65
- package/dist/index136.js +1 -1
- package/dist/index137.js +1 -1
- package/dist/index14.js +2 -2
- package/dist/index141.js +1 -1
- package/dist/index142.js +1 -1
- package/dist/index143.js +1 -1
- package/dist/index148.js +11 -21
- package/dist/index149.js +26 -11
- package/dist/index15.js +54 -54
- package/dist/index150.js +4 -27
- package/dist/index151.js +22 -4
- package/dist/index17.js +71 -72
- package/dist/index18.js +2 -2
- package/dist/index19.js +4 -4
- package/dist/index21.js +15 -15
- package/dist/index22.js +20 -20
- package/dist/index23.js +2 -2
- package/dist/index24.js +12 -12
- package/dist/index25.js +57 -57
- package/dist/index26.js +1 -1
- package/dist/index27.js +31 -31
- package/dist/index29.js +7 -7
- package/dist/index31.js +14 -14
- package/dist/index32.js +17 -17
- package/dist/index33.js +10 -10
- package/dist/index36.js +8 -8
- package/dist/index37.js +18 -18
- package/dist/index4.js +25 -25
- package/dist/index45.js +1 -1
- package/dist/index46.js +1 -1
- package/dist/index48.js +62 -249
- package/dist/index49.js +241 -12
- package/dist/index50.js +410 -285
- package/dist/index51.js +125 -12
- package/dist/index52.js +3 -3
- package/dist/index53.js +1 -1
- package/dist/index54.js +102 -209
- package/dist/index55.js +130 -11
- package/dist/index56.js +236 -11
- package/dist/index57.js +11 -125
- package/dist/index58.js +57 -70
- package/dist/index59.js +248 -76
- package/dist/index6.js +36 -36
- package/dist/index60.js +222 -822
- package/dist/index61.js +6 -3
- package/dist/index62.js +506 -94
- package/dist/index63.js +1 -1
- package/dist/index64.js +158 -57
- package/dist/index65.js +71 -230
- package/dist/index66.js +20 -433
- package/dist/index67.js +823 -299
- package/dist/index68.js +9 -161
- package/dist/index69.js +218 -24
- package/dist/index7.js +1 -1
- package/dist/index70.js +11 -236
- package/dist/index71.js +325 -119
- package/dist/index72.js +310 -12
- package/dist/index73.js +12 -254
- package/dist/index74.js +25 -524
- package/dist/index75.js +12 -22
- package/dist/index77.js +1 -1
- package/dist/index8.js +5 -5
- package/dist/index80.js +1 -1
- package/dist/index81.js +1 -1
- package/dist/index82.js +1 -1
- package/dist/index84.js +48 -118
- package/dist/index85.js +10 -134
- package/dist/index86.js +4 -14
- package/dist/index87.js +29 -68
- package/dist/index88.js +11 -13
- package/dist/index89.js +124 -8
- package/dist/index9.js +21 -21
- package/dist/index90.js +15 -50
- package/dist/index91.js +127 -40
- package/dist/index92.js +218 -5
- package/dist/index93.js +14 -25
- package/dist/index94.js +66 -12
- package/dist/index95.js +44 -646
- package/dist/index96.js +50 -9
- package/dist/index97.js +9 -55
- package/dist/index98.js +3 -10
- package/dist/index99.js +6 -4
- package/package.json +1 -1
package/dist/index94.js
CHANGED
|
@@ -1,17 +1,71 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
for (var d = i.charAt(h), a = e.indexOf(d, n), l = 0, r, g, c, p; a >= 0; ) r = $(t, o, e, i, a + 1, h + 1, u), r > l && (a === n ? r *= m : H.test(t.charAt(a - 1)) ? (r *= k, c = t.slice(n, a - 1).match(J), c && n > 0 && (r *= Math.pow(w, c.length))) : K.test(t.charAt(a - 1)) ? (r *= j, p = t.slice(n, a - 1).match(A), p && n > 0 && (r *= Math.pow(w, p.length))) : (r *= B, n > 0 && (r *= Math.pow(w, a - n))), t.charAt(a) !== o.charAt(h) && (r *= D)), (r < v && e.charAt(a - 1) === i.charAt(h + 1) || i.charAt(h + 1) === i.charAt(h) && e.charAt(a - 1) !== i.charAt(h)) && (g = $(t, o, e, i, a + 1, h + 2, u), g * v > r && (r = g * v)), r > l && (l = r), a = e.indexOf(d, a + 1);
|
|
7
|
-
return u[s] = l, l;
|
|
1
|
+
import * as a from "react";
|
|
2
|
+
import { useComposedRefs as E } from "./index78.js";
|
|
3
|
+
import { useLayoutEffect as A } from "./index86.js";
|
|
4
|
+
function T(n, e) {
|
|
5
|
+
return a.useReducer((r, t) => e[r][t] ?? r, n);
|
|
8
6
|
}
|
|
9
|
-
|
|
10
|
-
|
|
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
|
+
}
|
|
25
|
+
});
|
|
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
|
+
});
|
|
45
|
+
}
|
|
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
|
+
}, [])
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
function l(n) {
|
|
62
|
+
return (n == null ? void 0 : n.animationName) || "none";
|
|
11
63
|
}
|
|
12
|
-
function
|
|
13
|
-
|
|
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);
|
|
14
68
|
}
|
|
15
69
|
export {
|
|
16
|
-
|
|
70
|
+
R as Presence
|
|
17
71
|
};
|