randmarcomps 1.66.0 → 1.68.0
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/randmarcomps.js +234 -234
- package/dist/randmarcomps.umd.cjs +9 -9
- package/package.json +1 -1
package/dist/randmarcomps.js
CHANGED
|
@@ -57,13 +57,13 @@ function Ws({ containerRef: e, inputRef: t, pushPasswordManagerStrategy: n, isFo
|
|
|
57
57
|
}
|
|
58
58
|
var ro = l.createContext({}), oo = l.forwardRef((e, t) => {
|
|
59
59
|
var n = e, { value: r, onChange: o, maxLength: a, textAlign: s = "left", pattern: c, placeholder: u, inputMode: d = "numeric", onComplete: p, pushPasswordManagerStrategy: m = "increase-width", pasteTransformer: v, containerClassName: g, noScriptCSSFallback: y = Bs, render: f, children: h } = n, b = _s(n, ["value", "onChange", "maxLength", "textAlign", "pattern", "placeholder", "inputMode", "onComplete", "pushPasswordManagerStrategy", "pasteTransformer", "containerClassName", "noScriptCSSFallback", "render", "children"]), w, N, C, S, E;
|
|
60
|
-
let [T,
|
|
61
|
-
o == null || o(I),
|
|
62
|
-
}, [o]),
|
|
60
|
+
let [T, z] = l.useState(typeof b.defaultValue == "string" ? b.defaultValue : ""), _ = r ?? T, W = Ls(_), H = l.useCallback((I) => {
|
|
61
|
+
o == null || o(I), z(I);
|
|
62
|
+
}, [o]), B = l.useMemo(() => c ? typeof c == "string" ? new RegExp(c) : c : null, [c]), D = l.useRef(null), R = l.useRef(null), j = l.useRef({ value: _, onChange: H, isIOS: typeof window < "u" && ((N = (w = window == null ? void 0 : window.CSS) == null ? void 0 : w.supports) == null ? void 0 : N.call(w, "-webkit-touch-callout", "none")) }), P = l.useRef({ prev: [(C = D.current) == null ? void 0 : C.selectionStart, (S = D.current) == null ? void 0 : S.selectionEnd, (E = D.current) == null ? void 0 : E.selectionDirection] });
|
|
63
63
|
l.useImperativeHandle(t, () => D.current, []), l.useEffect(() => {
|
|
64
|
-
let I = D.current,
|
|
65
|
-
if (!I || !
|
|
66
|
-
|
|
64
|
+
let I = D.current, F = R.current;
|
|
65
|
+
if (!I || !F) return;
|
|
66
|
+
j.current.value !== I.value && j.current.onChange(I.value), P.current.prev = [I.selectionStart, I.selectionEnd, I.selectionDirection];
|
|
67
67
|
function oe() {
|
|
68
68
|
if (document.activeElement !== I) {
|
|
69
69
|
re(null), G(null);
|
|
@@ -99,7 +99,7 @@ var ro = l.createContext({}), oo = l.forwardRef((e, t) => {
|
|
|
99
99
|
}
|
|
100
100
|
}
|
|
101
101
|
let ie = () => {
|
|
102
|
-
|
|
102
|
+
F && F.style.setProperty("--root-height", `${I.clientHeight}px`);
|
|
103
103
|
};
|
|
104
104
|
ie();
|
|
105
105
|
let le = new ResizeObserver(ie);
|
|
@@ -107,62 +107,62 @@ var ro = l.createContext({}), oo = l.forwardRef((e, t) => {
|
|
|
107
107
|
document.removeEventListener("selectionchange", oe, { capture: !0 }), le.disconnect();
|
|
108
108
|
};
|
|
109
109
|
}, []);
|
|
110
|
-
let [U, O] = l.useState(!1), [
|
|
110
|
+
let [U, O] = l.useState(!1), [L, q] = l.useState(!1), [Z, re] = l.useState(null), [$, G] = l.useState(null);
|
|
111
111
|
l.useEffect(() => {
|
|
112
112
|
Is(() => {
|
|
113
|
-
var I,
|
|
113
|
+
var I, F, oe, ie;
|
|
114
114
|
(I = D.current) == null || I.dispatchEvent(new Event("input"));
|
|
115
|
-
let le = (
|
|
115
|
+
let le = (F = D.current) == null ? void 0 : F.selectionStart, K = (oe = D.current) == null ? void 0 : oe.selectionEnd, ce = (ie = D.current) == null ? void 0 : ie.selectionDirection;
|
|
116
116
|
le !== null && K !== null && (re(le), G(K), P.current.prev = [le, K, ce]);
|
|
117
117
|
});
|
|
118
|
-
}, [_,
|
|
119
|
-
|
|
120
|
-
}, [a, p,
|
|
121
|
-
let J = Ws({ containerRef: R, inputRef: D, pushPasswordManagerStrategy: m, isFocused:
|
|
122
|
-
let
|
|
123
|
-
if (
|
|
118
|
+
}, [_, L]), l.useEffect(() => {
|
|
119
|
+
W !== void 0 && _ !== W && W.length < a && _.length === a && (p == null || p(_));
|
|
120
|
+
}, [a, p, W, _]);
|
|
121
|
+
let J = Ws({ containerRef: R, inputRef: D, pushPasswordManagerStrategy: m, isFocused: L }), Pe = l.useCallback((I) => {
|
|
122
|
+
let F = I.currentTarget.value.slice(0, a);
|
|
123
|
+
if (F.length > 0 && B && !B.test(F)) {
|
|
124
124
|
I.preventDefault();
|
|
125
125
|
return;
|
|
126
126
|
}
|
|
127
|
-
typeof
|
|
128
|
-
}, [a,
|
|
127
|
+
typeof W == "string" && F.length < W.length && document.dispatchEvent(new Event("selectionchange")), H(F);
|
|
128
|
+
}, [a, H, W, B]), be = l.useCallback(() => {
|
|
129
129
|
var I;
|
|
130
130
|
if (D.current) {
|
|
131
|
-
let
|
|
132
|
-
(I = D.current) == null || I.setSelectionRange(
|
|
131
|
+
let F = Math.min(D.current.value.length, a - 1), oe = D.current.value.length;
|
|
132
|
+
(I = D.current) == null || I.setSelectionRange(F, oe), re(F), G(oe);
|
|
133
133
|
}
|
|
134
134
|
q(!0);
|
|
135
135
|
}, [a]), lt = l.useCallback((I) => {
|
|
136
|
-
var
|
|
136
|
+
var F, oe;
|
|
137
137
|
let ie = D.current;
|
|
138
|
-
if (!v && (!
|
|
138
|
+
if (!v && (!j.current.isIOS || !I.clipboardData || !ie)) return;
|
|
139
139
|
let le = I.clipboardData.getData("text/plain"), K = v ? v(le) : le;
|
|
140
140
|
I.preventDefault();
|
|
141
|
-
let ce = (
|
|
142
|
-
if (pe.length > 0 &&
|
|
143
|
-
ie.value = pe,
|
|
141
|
+
let ce = (F = D.current) == null ? void 0 : F.selectionStart, Ct = (oe = D.current) == null ? void 0 : oe.selectionEnd, pe = (ce !== Ct ? _.slice(0, ce) + K + _.slice(Ct) : _.slice(0, ce) + K + _.slice(ce)).slice(0, a);
|
|
142
|
+
if (pe.length > 0 && B && !B.test(pe)) return;
|
|
143
|
+
ie.value = pe, H(pe);
|
|
144
144
|
let Fe = Math.min(pe.length, a - 1), Ce = pe.length;
|
|
145
145
|
ie.setSelectionRange(Fe, Ce), re(Fe), G(Ce);
|
|
146
|
-
}, [a,
|
|
147
|
-
var
|
|
148
|
-
lt(I), (
|
|
146
|
+
}, [a, H, B, _]), xt = l.useMemo(() => ({ position: "relative", cursor: b.disabled ? "default" : "text", userSelect: "none", WebkitUserSelect: "none", pointerEvents: "none" }), [b.disabled]), ct = l.useMemo(() => ({ position: "absolute", inset: 0, width: J.willPushPWMBadge ? `calc(100% + ${J.PWM_BADGE_SPACE_WIDTH})` : "100%", clipPath: J.willPushPWMBadge ? `inset(0 ${J.PWM_BADGE_SPACE_WIDTH} 0 0)` : void 0, height: "100%", display: "flex", textAlign: s, opacity: "1", color: "transparent", pointerEvents: "all", background: "transparent", caretColor: "transparent", border: "0 solid transparent", outline: "0 solid transparent", boxShadow: "none", lineHeight: "1", letterSpacing: "-.5em", fontSize: "var(--root-height)", fontFamily: "monospace", fontVariantNumeric: "tabular-nums" }), [J.PWM_BADGE_SPACE_WIDTH, J.willPushPWMBadge, s]), Nt = l.useMemo(() => l.createElement("input", Ds(Os({ autoComplete: b.autoComplete || "one-time-code" }, b), { "data-input-otp": !0, "data-input-otp-placeholder-shown": _.length === 0 || void 0, "data-input-otp-mss": Z, "data-input-otp-mse": $, inputMode: d, pattern: B == null ? void 0 : B.source, "aria-placeholder": u, style: ct, maxLength: a, value: _, ref: D, onPaste: (I) => {
|
|
147
|
+
var F;
|
|
148
|
+
lt(I), (F = b.onPaste) == null || F.call(b, I);
|
|
149
149
|
}, onChange: Pe, onMouseOver: (I) => {
|
|
150
|
-
var
|
|
151
|
-
O(!0), (
|
|
150
|
+
var F;
|
|
151
|
+
O(!0), (F = b.onMouseOver) == null || F.call(b, I);
|
|
152
152
|
}, onMouseLeave: (I) => {
|
|
153
|
-
var
|
|
154
|
-
O(!1), (
|
|
153
|
+
var F;
|
|
154
|
+
O(!1), (F = b.onMouseLeave) == null || F.call(b, I);
|
|
155
155
|
}, onFocus: (I) => {
|
|
156
|
-
var
|
|
157
|
-
be(), (
|
|
156
|
+
var F;
|
|
157
|
+
be(), (F = b.onFocus) == null || F.call(b, I);
|
|
158
158
|
}, onBlur: (I) => {
|
|
159
|
-
var
|
|
160
|
-
q(!1), (
|
|
161
|
-
} })), [Pe, be, lt, d, ct, a,
|
|
159
|
+
var F;
|
|
160
|
+
q(!1), (F = b.onBlur) == null || F.call(b, I);
|
|
161
|
+
} })), [Pe, be, lt, d, ct, a, $, Z, b, B == null ? void 0 : B.source, _]), Ke = l.useMemo(() => ({ slots: Array.from({ length: a }).map((I, F) => {
|
|
162
162
|
var oe;
|
|
163
|
-
let ie =
|
|
163
|
+
let ie = L && Z !== null && $ !== null && (Z === $ && F === Z || F >= Z && F < $), le = _[F] !== void 0 ? _[F] : null, K = _[0] !== void 0 ? null : (oe = u == null ? void 0 : u[F]) != null ? oe : null;
|
|
164
164
|
return { char: le, placeholderChar: K, isActive: ie, hasFakeCaret: ie && le === null };
|
|
165
|
-
}), isFocused:
|
|
165
|
+
}), isFocused: L, isHovering: !b.disabled && U }), [L, U, a, $, Z, b.disabled, _]), $e = l.useMemo(() => f ? f(Ke) : l.createElement(ro.Provider, { value: Ke }, h), [h, Ke, f]);
|
|
166
166
|
return l.createElement(l.Fragment, null, y !== null && l.createElement("noscript", null, l.createElement("style", null, y)), l.createElement("div", { ref: R, "data-input-otp-container": !0, style: xt, className: g }, $e, l.createElement("div", { style: { position: "absolute", inset: 0, pointerEvents: "none" } }, Nt)));
|
|
167
167
|
});
|
|
168
168
|
oo.displayName = "Input";
|
|
@@ -775,21 +775,21 @@ function zi(e, ...t) {
|
|
|
775
775
|
const ne = (e) => {
|
|
776
776
|
const t = (n) => n[e] || [];
|
|
777
777
|
return t.isThemeGetter = !0, t;
|
|
778
|
-
}, fo = /^\[(?:(\w[\w-]*):)?(.+)\]$/i, po = /^\((?:(\w[\w-]*):)?(.+)\)$/i, Wi = /^\d+\/\d+$/, Bi = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, ji = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, Vi = /^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/, Hi = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, Ui = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, Ye = (e) => Wi.test(e),
|
|
778
|
+
}, fo = /^\[(?:(\w[\w-]*):)?(.+)\]$/i, po = /^\((?:(\w[\w-]*):)?(.+)\)$/i, Wi = /^\d+\/\d+$/, Bi = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, ji = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, Vi = /^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/, Hi = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, Ui = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, Ye = (e) => Wi.test(e), V = (e) => !!e && !Number.isNaN(Number(e)), je = (e) => !!e && Number.isInteger(Number(e)), Er = (e) => e.endsWith("%") && V(e.slice(0, -1)), Me = (e) => Bi.test(e), Gi = () => !0, Ki = (e) => (
|
|
779
779
|
// `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.
|
|
780
780
|
// For example, `hsl(0 0% 0%)` would be classified as a length without this check.
|
|
781
781
|
// I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
|
|
782
782
|
ji.test(e) && !Vi.test(e)
|
|
783
|
-
), Gn = () => !1, Yi = (e) => Hi.test(e), qi = (e) => Ui.test(e), Xi = (e) => !A(e) && !k(e), Qi = (e) => ot(e, go, Gn), A = (e) => fo.test(e), Ve = (e) => ot(e, vo, Ki), fn = (e) => ot(e, ll,
|
|
783
|
+
), Gn = () => !1, Yi = (e) => Hi.test(e), qi = (e) => Ui.test(e), Xi = (e) => !A(e) && !k(e), Qi = (e) => ot(e, go, Gn), A = (e) => fo.test(e), Ve = (e) => ot(e, vo, Ki), fn = (e) => ot(e, ll, V), Zi = (e) => ot(e, mo, Gn), Ji = (e) => ot(e, ho, qi), el = (e) => ot(e, Gn, Yi), k = (e) => po.test(e), Et = (e) => at(e, vo), tl = (e) => at(e, cl), nl = (e) => at(e, mo), rl = (e) => at(e, go), ol = (e) => at(e, ho), al = (e) => at(e, dl, !0), ot = (e, t, n) => {
|
|
784
784
|
const r = fo.exec(e);
|
|
785
785
|
return r ? r[1] ? t(r[1]) : n(r[2]) : !1;
|
|
786
786
|
}, at = (e, t, n = !1) => {
|
|
787
787
|
const r = po.exec(e);
|
|
788
788
|
return r ? r[1] ? t(r[1]) : n : !1;
|
|
789
789
|
}, mo = (e) => e === "position", sl = /* @__PURE__ */ new Set(["image", "url"]), ho = (e) => sl.has(e), il = /* @__PURE__ */ new Set(["length", "size", "percentage"]), go = (e) => il.has(e), vo = (e) => e === "length", ll = (e) => e === "number", cl = (e) => e === "family-name", dl = (e) => e === "shadow", ul = () => {
|
|
790
|
-
const e = ne("color"), t = ne("font"), n = ne("text"), r = ne("font-weight"), o = ne("tracking"), a = ne("leading"), s = ne("breakpoint"), c = ne("container"), u = ne("spacing"), d = ne("radius"), p = ne("shadow"), m = ne("inset-shadow"), v = ne("drop-shadow"), g = ne("blur"), y = ne("perspective"), f = ne("aspect"), h = ne("ease"), b = ne("animate"), w = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], N = () => ["bottom", "center", "left", "left-bottom", "left-top", "right", "right-bottom", "right-top", "top"], C = () => ["auto", "hidden", "clip", "visible", "scroll"], S = () => ["auto", "contain", "none"], E = () => [k, A, u], T = () => [Ye, "full", "auto", ...E()],
|
|
790
|
+
const e = ne("color"), t = ne("font"), n = ne("text"), r = ne("font-weight"), o = ne("tracking"), a = ne("leading"), s = ne("breakpoint"), c = ne("container"), u = ne("spacing"), d = ne("radius"), p = ne("shadow"), m = ne("inset-shadow"), v = ne("drop-shadow"), g = ne("blur"), y = ne("perspective"), f = ne("aspect"), h = ne("ease"), b = ne("animate"), w = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], N = () => ["bottom", "center", "left", "left-bottom", "left-top", "right", "right-bottom", "right-top", "top"], C = () => ["auto", "hidden", "clip", "visible", "scroll"], S = () => ["auto", "contain", "none"], E = () => [k, A, u], T = () => [Ye, "full", "auto", ...E()], z = () => [je, "none", "subgrid", k, A], _ = () => ["auto", {
|
|
791
791
|
span: ["full", je, k, A]
|
|
792
|
-
}, k, A],
|
|
792
|
+
}, k, A], W = () => [je, "auto", k, A], H = () => ["auto", "min", "max", "fr", k, A], B = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline"], D = () => ["start", "end", "center", "stretch"], R = () => ["auto", ...E()], j = () => [Ye, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...E()], P = () => [e, k, A], U = () => [Er, Ve], O = () => [
|
|
793
793
|
// Deprecated since Tailwind CSS v4.0.0
|
|
794
794
|
"",
|
|
795
795
|
"none",
|
|
@@ -797,14 +797,14 @@ const ne = (e) => {
|
|
|
797
797
|
d,
|
|
798
798
|
k,
|
|
799
799
|
A
|
|
800
|
-
],
|
|
800
|
+
], L = () => ["", V, Et, Ve], q = () => ["solid", "dashed", "dotted", "double"], Z = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], re = () => [
|
|
801
801
|
// Deprecated since Tailwind CSS v4.0.0
|
|
802
802
|
"",
|
|
803
803
|
"none",
|
|
804
804
|
g,
|
|
805
805
|
k,
|
|
806
806
|
A
|
|
807
|
-
],
|
|
807
|
+
], $ = () => ["center", "top", "top-right", "right", "bottom-right", "bottom", "bottom-left", "left", "top-left", k, A], G = () => ["none", V, k, A], J = () => ["none", V, k, A], Pe = () => [V, k, A], be = () => [Ye, "full", ...E()];
|
|
808
808
|
return {
|
|
809
809
|
cacheSize: 500,
|
|
810
810
|
theme: {
|
|
@@ -823,7 +823,7 @@ const ne = (e) => {
|
|
|
823
823
|
perspective: ["dramatic", "near", "normal", "midrange", "distant", "none"],
|
|
824
824
|
radius: [Me],
|
|
825
825
|
shadow: [Me],
|
|
826
|
-
spacing: ["px",
|
|
826
|
+
spacing: ["px", V],
|
|
827
827
|
text: [Me],
|
|
828
828
|
tracking: ["tighter", "tight", "normal", "wide", "wider", "widest"]
|
|
829
829
|
},
|
|
@@ -849,7 +849,7 @@ const ne = (e) => {
|
|
|
849
849
|
* @see https://tailwindcss.com/docs/columns
|
|
850
850
|
*/
|
|
851
851
|
columns: [{
|
|
852
|
-
columns: [
|
|
852
|
+
columns: [V, A, k, c]
|
|
853
853
|
}],
|
|
854
854
|
/**
|
|
855
855
|
* Break After
|
|
@@ -1080,21 +1080,21 @@ const ne = (e) => {
|
|
|
1080
1080
|
* @see https://tailwindcss.com/docs/flex
|
|
1081
1081
|
*/
|
|
1082
1082
|
flex: [{
|
|
1083
|
-
flex: [
|
|
1083
|
+
flex: [V, Ye, "auto", "initial", "none", A]
|
|
1084
1084
|
}],
|
|
1085
1085
|
/**
|
|
1086
1086
|
* Flex Grow
|
|
1087
1087
|
* @see https://tailwindcss.com/docs/flex-grow
|
|
1088
1088
|
*/
|
|
1089
1089
|
grow: [{
|
|
1090
|
-
grow: ["",
|
|
1090
|
+
grow: ["", V, k, A]
|
|
1091
1091
|
}],
|
|
1092
1092
|
/**
|
|
1093
1093
|
* Flex Shrink
|
|
1094
1094
|
* @see https://tailwindcss.com/docs/flex-shrink
|
|
1095
1095
|
*/
|
|
1096
1096
|
shrink: [{
|
|
1097
|
-
shrink: ["",
|
|
1097
|
+
shrink: ["", V, k, A]
|
|
1098
1098
|
}],
|
|
1099
1099
|
/**
|
|
1100
1100
|
* Order
|
|
@@ -1108,7 +1108,7 @@ const ne = (e) => {
|
|
|
1108
1108
|
* @see https://tailwindcss.com/docs/grid-template-columns
|
|
1109
1109
|
*/
|
|
1110
1110
|
"grid-cols": [{
|
|
1111
|
-
"grid-cols":
|
|
1111
|
+
"grid-cols": z()
|
|
1112
1112
|
}],
|
|
1113
1113
|
/**
|
|
1114
1114
|
* Grid Column Start / End
|
|
@@ -1122,21 +1122,21 @@ const ne = (e) => {
|
|
|
1122
1122
|
* @see https://tailwindcss.com/docs/grid-column
|
|
1123
1123
|
*/
|
|
1124
1124
|
"col-start": [{
|
|
1125
|
-
"col-start":
|
|
1125
|
+
"col-start": W()
|
|
1126
1126
|
}],
|
|
1127
1127
|
/**
|
|
1128
1128
|
* Grid Column End
|
|
1129
1129
|
* @see https://tailwindcss.com/docs/grid-column
|
|
1130
1130
|
*/
|
|
1131
1131
|
"col-end": [{
|
|
1132
|
-
"col-end":
|
|
1132
|
+
"col-end": W()
|
|
1133
1133
|
}],
|
|
1134
1134
|
/**
|
|
1135
1135
|
* Grid Template Rows
|
|
1136
1136
|
* @see https://tailwindcss.com/docs/grid-template-rows
|
|
1137
1137
|
*/
|
|
1138
1138
|
"grid-rows": [{
|
|
1139
|
-
"grid-rows":
|
|
1139
|
+
"grid-rows": z()
|
|
1140
1140
|
}],
|
|
1141
1141
|
/**
|
|
1142
1142
|
* Grid Row Start / End
|
|
@@ -1150,14 +1150,14 @@ const ne = (e) => {
|
|
|
1150
1150
|
* @see https://tailwindcss.com/docs/grid-row
|
|
1151
1151
|
*/
|
|
1152
1152
|
"row-start": [{
|
|
1153
|
-
"row-start":
|
|
1153
|
+
"row-start": W()
|
|
1154
1154
|
}],
|
|
1155
1155
|
/**
|
|
1156
1156
|
* Grid Row End
|
|
1157
1157
|
* @see https://tailwindcss.com/docs/grid-row
|
|
1158
1158
|
*/
|
|
1159
1159
|
"row-end": [{
|
|
1160
|
-
"row-end":
|
|
1160
|
+
"row-end": W()
|
|
1161
1161
|
}],
|
|
1162
1162
|
/**
|
|
1163
1163
|
* Grid Auto Flow
|
|
@@ -1171,14 +1171,14 @@ const ne = (e) => {
|
|
|
1171
1171
|
* @see https://tailwindcss.com/docs/grid-auto-columns
|
|
1172
1172
|
*/
|
|
1173
1173
|
"auto-cols": [{
|
|
1174
|
-
"auto-cols":
|
|
1174
|
+
"auto-cols": H()
|
|
1175
1175
|
}],
|
|
1176
1176
|
/**
|
|
1177
1177
|
* Grid Auto Rows
|
|
1178
1178
|
* @see https://tailwindcss.com/docs/grid-auto-rows
|
|
1179
1179
|
*/
|
|
1180
1180
|
"auto-rows": [{
|
|
1181
|
-
"auto-rows":
|
|
1181
|
+
"auto-rows": H()
|
|
1182
1182
|
}],
|
|
1183
1183
|
/**
|
|
1184
1184
|
* Gap
|
|
@@ -1206,7 +1206,7 @@ const ne = (e) => {
|
|
|
1206
1206
|
* @see https://tailwindcss.com/docs/justify-content
|
|
1207
1207
|
*/
|
|
1208
1208
|
"justify-content": [{
|
|
1209
|
-
justify: [...
|
|
1209
|
+
justify: [...B(), "normal"]
|
|
1210
1210
|
}],
|
|
1211
1211
|
/**
|
|
1212
1212
|
* Justify Items
|
|
@@ -1227,7 +1227,7 @@ const ne = (e) => {
|
|
|
1227
1227
|
* @see https://tailwindcss.com/docs/align-content
|
|
1228
1228
|
*/
|
|
1229
1229
|
"align-content": [{
|
|
1230
|
-
content: ["normal", ...
|
|
1230
|
+
content: ["normal", ...B()]
|
|
1231
1231
|
}],
|
|
1232
1232
|
/**
|
|
1233
1233
|
* Align Items
|
|
@@ -1248,7 +1248,7 @@ const ne = (e) => {
|
|
|
1248
1248
|
* @see https://tailwindcss.com/docs/place-content
|
|
1249
1249
|
*/
|
|
1250
1250
|
"place-content": [{
|
|
1251
|
-
"place-content":
|
|
1251
|
+
"place-content": B()
|
|
1252
1252
|
}],
|
|
1253
1253
|
/**
|
|
1254
1254
|
* Place Items
|
|
@@ -1423,14 +1423,14 @@ const ne = (e) => {
|
|
|
1423
1423
|
* @see https://tailwindcss.com/docs/width#setting-both-width-and-height
|
|
1424
1424
|
*/
|
|
1425
1425
|
size: [{
|
|
1426
|
-
size:
|
|
1426
|
+
size: j()
|
|
1427
1427
|
}],
|
|
1428
1428
|
/**
|
|
1429
1429
|
* Width
|
|
1430
1430
|
* @see https://tailwindcss.com/docs/width
|
|
1431
1431
|
*/
|
|
1432
1432
|
w: [{
|
|
1433
|
-
w: [c, "screen", ...
|
|
1433
|
+
w: [c, "screen", ...j()]
|
|
1434
1434
|
}],
|
|
1435
1435
|
/**
|
|
1436
1436
|
* Min-Width
|
|
@@ -1442,7 +1442,7 @@ const ne = (e) => {
|
|
|
1442
1442
|
"screen",
|
|
1443
1443
|
/** Deprecated. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
|
|
1444
1444
|
"none",
|
|
1445
|
-
...
|
|
1445
|
+
...j()
|
|
1446
1446
|
]
|
|
1447
1447
|
}],
|
|
1448
1448
|
/**
|
|
@@ -1460,7 +1460,7 @@ const ne = (e) => {
|
|
|
1460
1460
|
{
|
|
1461
1461
|
screen: [s]
|
|
1462
1462
|
},
|
|
1463
|
-
...
|
|
1463
|
+
...j()
|
|
1464
1464
|
]
|
|
1465
1465
|
}],
|
|
1466
1466
|
/**
|
|
@@ -1468,21 +1468,21 @@ const ne = (e) => {
|
|
|
1468
1468
|
* @see https://tailwindcss.com/docs/height
|
|
1469
1469
|
*/
|
|
1470
1470
|
h: [{
|
|
1471
|
-
h: ["screen", ...
|
|
1471
|
+
h: ["screen", ...j()]
|
|
1472
1472
|
}],
|
|
1473
1473
|
/**
|
|
1474
1474
|
* Min-Height
|
|
1475
1475
|
* @see https://tailwindcss.com/docs/min-height
|
|
1476
1476
|
*/
|
|
1477
1477
|
"min-h": [{
|
|
1478
|
-
"min-h": ["screen", "none", ...
|
|
1478
|
+
"min-h": ["screen", "none", ...j()]
|
|
1479
1479
|
}],
|
|
1480
1480
|
/**
|
|
1481
1481
|
* Max-Height
|
|
1482
1482
|
* @see https://tailwindcss.com/docs/max-height
|
|
1483
1483
|
*/
|
|
1484
1484
|
"max-h": [{
|
|
1485
|
-
"max-h": ["screen", ...
|
|
1485
|
+
"max-h": ["screen", ...j()]
|
|
1486
1486
|
}],
|
|
1487
1487
|
// ------------------
|
|
1488
1488
|
// --- Typography ---
|
|
@@ -1567,7 +1567,7 @@ const ne = (e) => {
|
|
|
1567
1567
|
* @see https://tailwindcss.com/docs/line-clamp
|
|
1568
1568
|
*/
|
|
1569
1569
|
"line-clamp": [{
|
|
1570
|
-
"line-clamp": [
|
|
1570
|
+
"line-clamp": [V, "none", k, fn]
|
|
1571
1571
|
}],
|
|
1572
1572
|
/**
|
|
1573
1573
|
* Line Height
|
|
@@ -1640,7 +1640,7 @@ const ne = (e) => {
|
|
|
1640
1640
|
* @see https://tailwindcss.com/docs/text-decoration-thickness
|
|
1641
1641
|
*/
|
|
1642
1642
|
"text-decoration-thickness": [{
|
|
1643
|
-
decoration: [
|
|
1643
|
+
decoration: [V, "from-font", "auto", k, Ve]
|
|
1644
1644
|
}],
|
|
1645
1645
|
/**
|
|
1646
1646
|
* Text Decoration Color
|
|
@@ -1654,7 +1654,7 @@ const ne = (e) => {
|
|
|
1654
1654
|
* @see https://tailwindcss.com/docs/text-underline-offset
|
|
1655
1655
|
*/
|
|
1656
1656
|
"underline-offset": [{
|
|
1657
|
-
"underline-offset": [
|
|
1657
|
+
"underline-offset": [V, "auto", k, A]
|
|
1658
1658
|
}],
|
|
1659
1659
|
/**
|
|
1660
1660
|
* Text Transform
|
|
@@ -1937,70 +1937,70 @@ const ne = (e) => {
|
|
|
1937
1937
|
* @see https://tailwindcss.com/docs/border-width
|
|
1938
1938
|
*/
|
|
1939
1939
|
"border-w": [{
|
|
1940
|
-
border:
|
|
1940
|
+
border: L()
|
|
1941
1941
|
}],
|
|
1942
1942
|
/**
|
|
1943
1943
|
* Border Width X
|
|
1944
1944
|
* @see https://tailwindcss.com/docs/border-width
|
|
1945
1945
|
*/
|
|
1946
1946
|
"border-w-x": [{
|
|
1947
|
-
"border-x":
|
|
1947
|
+
"border-x": L()
|
|
1948
1948
|
}],
|
|
1949
1949
|
/**
|
|
1950
1950
|
* Border Width Y
|
|
1951
1951
|
* @see https://tailwindcss.com/docs/border-width
|
|
1952
1952
|
*/
|
|
1953
1953
|
"border-w-y": [{
|
|
1954
|
-
"border-y":
|
|
1954
|
+
"border-y": L()
|
|
1955
1955
|
}],
|
|
1956
1956
|
/**
|
|
1957
1957
|
* Border Width Start
|
|
1958
1958
|
* @see https://tailwindcss.com/docs/border-width
|
|
1959
1959
|
*/
|
|
1960
1960
|
"border-w-s": [{
|
|
1961
|
-
"border-s":
|
|
1961
|
+
"border-s": L()
|
|
1962
1962
|
}],
|
|
1963
1963
|
/**
|
|
1964
1964
|
* Border Width End
|
|
1965
1965
|
* @see https://tailwindcss.com/docs/border-width
|
|
1966
1966
|
*/
|
|
1967
1967
|
"border-w-e": [{
|
|
1968
|
-
"border-e":
|
|
1968
|
+
"border-e": L()
|
|
1969
1969
|
}],
|
|
1970
1970
|
/**
|
|
1971
1971
|
* Border Width Top
|
|
1972
1972
|
* @see https://tailwindcss.com/docs/border-width
|
|
1973
1973
|
*/
|
|
1974
1974
|
"border-w-t": [{
|
|
1975
|
-
"border-t":
|
|
1975
|
+
"border-t": L()
|
|
1976
1976
|
}],
|
|
1977
1977
|
/**
|
|
1978
1978
|
* Border Width Right
|
|
1979
1979
|
* @see https://tailwindcss.com/docs/border-width
|
|
1980
1980
|
*/
|
|
1981
1981
|
"border-w-r": [{
|
|
1982
|
-
"border-r":
|
|
1982
|
+
"border-r": L()
|
|
1983
1983
|
}],
|
|
1984
1984
|
/**
|
|
1985
1985
|
* Border Width Bottom
|
|
1986
1986
|
* @see https://tailwindcss.com/docs/border-width
|
|
1987
1987
|
*/
|
|
1988
1988
|
"border-w-b": [{
|
|
1989
|
-
"border-b":
|
|
1989
|
+
"border-b": L()
|
|
1990
1990
|
}],
|
|
1991
1991
|
/**
|
|
1992
1992
|
* Border Width Left
|
|
1993
1993
|
* @see https://tailwindcss.com/docs/border-width
|
|
1994
1994
|
*/
|
|
1995
1995
|
"border-w-l": [{
|
|
1996
|
-
"border-l":
|
|
1996
|
+
"border-l": L()
|
|
1997
1997
|
}],
|
|
1998
1998
|
/**
|
|
1999
1999
|
* Divide Width X
|
|
2000
2000
|
* @see https://tailwindcss.com/docs/border-width#between-children
|
|
2001
2001
|
*/
|
|
2002
2002
|
"divide-x": [{
|
|
2003
|
-
"divide-x":
|
|
2003
|
+
"divide-x": L()
|
|
2004
2004
|
}],
|
|
2005
2005
|
/**
|
|
2006
2006
|
* Divide Width X Reverse
|
|
@@ -2012,7 +2012,7 @@ const ne = (e) => {
|
|
|
2012
2012
|
* @see https://tailwindcss.com/docs/border-width#between-children
|
|
2013
2013
|
*/
|
|
2014
2014
|
"divide-y": [{
|
|
2015
|
-
"divide-y":
|
|
2015
|
+
"divide-y": L()
|
|
2016
2016
|
}],
|
|
2017
2017
|
/**
|
|
2018
2018
|
* Divide Width Y Reverse
|
|
@@ -2115,14 +2115,14 @@ const ne = (e) => {
|
|
|
2115
2115
|
* @see https://tailwindcss.com/docs/outline-offset
|
|
2116
2116
|
*/
|
|
2117
2117
|
"outline-offset": [{
|
|
2118
|
-
"outline-offset": [
|
|
2118
|
+
"outline-offset": [V, k, A]
|
|
2119
2119
|
}],
|
|
2120
2120
|
/**
|
|
2121
2121
|
* Outline Width
|
|
2122
2122
|
* @see https://tailwindcss.com/docs/outline-width
|
|
2123
2123
|
*/
|
|
2124
2124
|
"outline-w": [{
|
|
2125
|
-
outline: ["",
|
|
2125
|
+
outline: ["", V, Et, Ve]
|
|
2126
2126
|
}],
|
|
2127
2127
|
/**
|
|
2128
2128
|
* Outline Color
|
|
@@ -2174,7 +2174,7 @@ const ne = (e) => {
|
|
|
2174
2174
|
* @see https://tailwindcss.com/docs/box-shadow#adding-a-ring
|
|
2175
2175
|
*/
|
|
2176
2176
|
"ring-w": [{
|
|
2177
|
-
ring:
|
|
2177
|
+
ring: L()
|
|
2178
2178
|
}],
|
|
2179
2179
|
/**
|
|
2180
2180
|
* Ring Width Inset
|
|
@@ -2197,7 +2197,7 @@ const ne = (e) => {
|
|
|
2197
2197
|
* @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158
|
|
2198
2198
|
*/
|
|
2199
2199
|
"ring-offset-w": [{
|
|
2200
|
-
"ring-offset": [
|
|
2200
|
+
"ring-offset": [V, Ve]
|
|
2201
2201
|
}],
|
|
2202
2202
|
/**
|
|
2203
2203
|
* Ring Offset Color
|
|
@@ -2213,7 +2213,7 @@ const ne = (e) => {
|
|
|
2213
2213
|
* @see https://tailwindcss.com/docs/box-shadow#adding-an-inset-ring
|
|
2214
2214
|
*/
|
|
2215
2215
|
"inset-ring-w": [{
|
|
2216
|
-
"inset-ring":
|
|
2216
|
+
"inset-ring": L()
|
|
2217
2217
|
}],
|
|
2218
2218
|
/**
|
|
2219
2219
|
* Inset Ring Color
|
|
@@ -2227,7 +2227,7 @@ const ne = (e) => {
|
|
|
2227
2227
|
* @see https://tailwindcss.com/docs/opacity
|
|
2228
2228
|
*/
|
|
2229
2229
|
opacity: [{
|
|
2230
|
-
opacity: [
|
|
2230
|
+
opacity: [V, k, A]
|
|
2231
2231
|
}],
|
|
2232
2232
|
/**
|
|
2233
2233
|
* Mix Blend Mode
|
|
@@ -2271,14 +2271,14 @@ const ne = (e) => {
|
|
|
2271
2271
|
* @see https://tailwindcss.com/docs/brightness
|
|
2272
2272
|
*/
|
|
2273
2273
|
brightness: [{
|
|
2274
|
-
brightness: [
|
|
2274
|
+
brightness: [V, k, A]
|
|
2275
2275
|
}],
|
|
2276
2276
|
/**
|
|
2277
2277
|
* Contrast
|
|
2278
2278
|
* @see https://tailwindcss.com/docs/contrast
|
|
2279
2279
|
*/
|
|
2280
2280
|
contrast: [{
|
|
2281
|
-
contrast: [
|
|
2281
|
+
contrast: [V, k, A]
|
|
2282
2282
|
}],
|
|
2283
2283
|
/**
|
|
2284
2284
|
* Drop Shadow
|
|
@@ -2299,35 +2299,35 @@ const ne = (e) => {
|
|
|
2299
2299
|
* @see https://tailwindcss.com/docs/grayscale
|
|
2300
2300
|
*/
|
|
2301
2301
|
grayscale: [{
|
|
2302
|
-
grayscale: ["",
|
|
2302
|
+
grayscale: ["", V, k, A]
|
|
2303
2303
|
}],
|
|
2304
2304
|
/**
|
|
2305
2305
|
* Hue Rotate
|
|
2306
2306
|
* @see https://tailwindcss.com/docs/hue-rotate
|
|
2307
2307
|
*/
|
|
2308
2308
|
"hue-rotate": [{
|
|
2309
|
-
"hue-rotate": [
|
|
2309
|
+
"hue-rotate": [V, k, A]
|
|
2310
2310
|
}],
|
|
2311
2311
|
/**
|
|
2312
2312
|
* Invert
|
|
2313
2313
|
* @see https://tailwindcss.com/docs/invert
|
|
2314
2314
|
*/
|
|
2315
2315
|
invert: [{
|
|
2316
|
-
invert: ["",
|
|
2316
|
+
invert: ["", V, k, A]
|
|
2317
2317
|
}],
|
|
2318
2318
|
/**
|
|
2319
2319
|
* Saturate
|
|
2320
2320
|
* @see https://tailwindcss.com/docs/saturate
|
|
2321
2321
|
*/
|
|
2322
2322
|
saturate: [{
|
|
2323
|
-
saturate: [
|
|
2323
|
+
saturate: [V, k, A]
|
|
2324
2324
|
}],
|
|
2325
2325
|
/**
|
|
2326
2326
|
* Sepia
|
|
2327
2327
|
* @see https://tailwindcss.com/docs/sepia
|
|
2328
2328
|
*/
|
|
2329
2329
|
sepia: [{
|
|
2330
|
-
sepia: ["",
|
|
2330
|
+
sepia: ["", V, k, A]
|
|
2331
2331
|
}],
|
|
2332
2332
|
/**
|
|
2333
2333
|
* Backdrop Filter
|
|
@@ -2354,56 +2354,56 @@ const ne = (e) => {
|
|
|
2354
2354
|
* @see https://tailwindcss.com/docs/backdrop-brightness
|
|
2355
2355
|
*/
|
|
2356
2356
|
"backdrop-brightness": [{
|
|
2357
|
-
"backdrop-brightness": [
|
|
2357
|
+
"backdrop-brightness": [V, k, A]
|
|
2358
2358
|
}],
|
|
2359
2359
|
/**
|
|
2360
2360
|
* Backdrop Contrast
|
|
2361
2361
|
* @see https://tailwindcss.com/docs/backdrop-contrast
|
|
2362
2362
|
*/
|
|
2363
2363
|
"backdrop-contrast": [{
|
|
2364
|
-
"backdrop-contrast": [
|
|
2364
|
+
"backdrop-contrast": [V, k, A]
|
|
2365
2365
|
}],
|
|
2366
2366
|
/**
|
|
2367
2367
|
* Backdrop Grayscale
|
|
2368
2368
|
* @see https://tailwindcss.com/docs/backdrop-grayscale
|
|
2369
2369
|
*/
|
|
2370
2370
|
"backdrop-grayscale": [{
|
|
2371
|
-
"backdrop-grayscale": ["",
|
|
2371
|
+
"backdrop-grayscale": ["", V, k, A]
|
|
2372
2372
|
}],
|
|
2373
2373
|
/**
|
|
2374
2374
|
* Backdrop Hue Rotate
|
|
2375
2375
|
* @see https://tailwindcss.com/docs/backdrop-hue-rotate
|
|
2376
2376
|
*/
|
|
2377
2377
|
"backdrop-hue-rotate": [{
|
|
2378
|
-
"backdrop-hue-rotate": [
|
|
2378
|
+
"backdrop-hue-rotate": [V, k, A]
|
|
2379
2379
|
}],
|
|
2380
2380
|
/**
|
|
2381
2381
|
* Backdrop Invert
|
|
2382
2382
|
* @see https://tailwindcss.com/docs/backdrop-invert
|
|
2383
2383
|
*/
|
|
2384
2384
|
"backdrop-invert": [{
|
|
2385
|
-
"backdrop-invert": ["",
|
|
2385
|
+
"backdrop-invert": ["", V, k, A]
|
|
2386
2386
|
}],
|
|
2387
2387
|
/**
|
|
2388
2388
|
* Backdrop Opacity
|
|
2389
2389
|
* @see https://tailwindcss.com/docs/backdrop-opacity
|
|
2390
2390
|
*/
|
|
2391
2391
|
"backdrop-opacity": [{
|
|
2392
|
-
"backdrop-opacity": [
|
|
2392
|
+
"backdrop-opacity": [V, k, A]
|
|
2393
2393
|
}],
|
|
2394
2394
|
/**
|
|
2395
2395
|
* Backdrop Saturate
|
|
2396
2396
|
* @see https://tailwindcss.com/docs/backdrop-saturate
|
|
2397
2397
|
*/
|
|
2398
2398
|
"backdrop-saturate": [{
|
|
2399
|
-
"backdrop-saturate": [
|
|
2399
|
+
"backdrop-saturate": [V, k, A]
|
|
2400
2400
|
}],
|
|
2401
2401
|
/**
|
|
2402
2402
|
* Backdrop Sepia
|
|
2403
2403
|
* @see https://tailwindcss.com/docs/backdrop-sepia
|
|
2404
2404
|
*/
|
|
2405
2405
|
"backdrop-sepia": [{
|
|
2406
|
-
"backdrop-sepia": ["",
|
|
2406
|
+
"backdrop-sepia": ["", V, k, A]
|
|
2407
2407
|
}],
|
|
2408
2408
|
// --------------
|
|
2409
2409
|
// --- Tables ---
|
|
@@ -2472,7 +2472,7 @@ const ne = (e) => {
|
|
|
2472
2472
|
* @see https://tailwindcss.com/docs/transition-duration
|
|
2473
2473
|
*/
|
|
2474
2474
|
duration: [{
|
|
2475
|
-
duration: [
|
|
2475
|
+
duration: [V, "initial", k, A]
|
|
2476
2476
|
}],
|
|
2477
2477
|
/**
|
|
2478
2478
|
* Transition Timing Function
|
|
@@ -2486,7 +2486,7 @@ const ne = (e) => {
|
|
|
2486
2486
|
* @see https://tailwindcss.com/docs/transition-delay
|
|
2487
2487
|
*/
|
|
2488
2488
|
delay: [{
|
|
2489
|
-
delay: [
|
|
2489
|
+
delay: [V, k, A]
|
|
2490
2490
|
}],
|
|
2491
2491
|
/**
|
|
2492
2492
|
* Animation
|
|
@@ -2517,7 +2517,7 @@ const ne = (e) => {
|
|
|
2517
2517
|
* @see https://tailwindcss.com/docs/perspective-origin
|
|
2518
2518
|
*/
|
|
2519
2519
|
"perspective-origin": [{
|
|
2520
|
-
"perspective-origin":
|
|
2520
|
+
"perspective-origin": $()
|
|
2521
2521
|
}],
|
|
2522
2522
|
/**
|
|
2523
2523
|
* Rotate
|
|
@@ -2613,7 +2613,7 @@ const ne = (e) => {
|
|
|
2613
2613
|
* @see https://tailwindcss.com/docs/transform-origin
|
|
2614
2614
|
*/
|
|
2615
2615
|
"transform-origin": [{
|
|
2616
|
-
origin:
|
|
2616
|
+
origin: $()
|
|
2617
2617
|
}],
|
|
2618
2618
|
/**
|
|
2619
2619
|
* Transform Style
|
|
@@ -2930,7 +2930,7 @@ const ne = (e) => {
|
|
|
2930
2930
|
* @see https://tailwindcss.com/docs/stroke-width
|
|
2931
2931
|
*/
|
|
2932
2932
|
"stroke-w": [{
|
|
2933
|
-
stroke: [
|
|
2933
|
+
stroke: [V, Et, Ve, fn]
|
|
2934
2934
|
}],
|
|
2935
2935
|
/**
|
|
2936
2936
|
* Stroke
|
|
@@ -3290,11 +3290,11 @@ var Cl = "DismissableLayer", Mn = "dismissableLayer.update", El = "dismissableLa
|
|
|
3290
3290
|
onDismiss: c,
|
|
3291
3291
|
...u
|
|
3292
3292
|
} = e, d = l.useContext(xo), [p, m] = l.useState(null), v = (p == null ? void 0 : p.ownerDocument) ?? (globalThis == null ? void 0 : globalThis.document), [, g] = l.useState({}), y = se(t, (T) => m(T)), f = Array.from(d.layers), [h] = [...d.layersWithOutsidePointerEventsDisabled].slice(-1), b = f.indexOf(h), w = p ? f.indexOf(p) : -1, N = d.layersWithOutsidePointerEventsDisabled.size > 0, C = w >= b, S = Rl((T) => {
|
|
3293
|
-
const
|
|
3293
|
+
const z = T.target, _ = [...d.branches].some((W) => W.contains(z));
|
|
3294
3294
|
!C || _ || (o == null || o(T), s == null || s(T), T.defaultPrevented || c == null || c());
|
|
3295
3295
|
}, v), E = Pl((T) => {
|
|
3296
|
-
const
|
|
3297
|
-
[...d.branches].some((
|
|
3296
|
+
const z = T.target;
|
|
3297
|
+
[...d.branches].some((W) => W.contains(z)) || (a == null || a(T), s == null || s(T), T.defaultPrevented || c == null || c());
|
|
3298
3298
|
}, v);
|
|
3299
3299
|
return Nl((T) => {
|
|
3300
3300
|
w === d.layers.size - 1 && (r == null || r(T), !T.defaultPrevented && c && (T.preventDefault(), c()));
|
|
@@ -4005,10 +4005,10 @@ function Nc(e) {
|
|
|
4005
4005
|
var b = Rt(f), w = n.current, N = "deltaX" in f ? f.deltaX : w[0] - b[0], C = "deltaY" in f ? f.deltaY : w[1] - b[1], S, E = f.target, T = Math.abs(N) > Math.abs(C) ? "h" : "v";
|
|
4006
4006
|
if ("touches" in f && T === "h" && E.type === "range")
|
|
4007
4007
|
return !1;
|
|
4008
|
-
var
|
|
4009
|
-
if (!
|
|
4008
|
+
var z = Ir(T, E);
|
|
4009
|
+
if (!z)
|
|
4010
4010
|
return !0;
|
|
4011
|
-
if (
|
|
4011
|
+
if (z ? S = T : (S = T === "v" ? "h" : "v", z = Ir(T, E)), !z)
|
|
4012
4012
|
return !1;
|
|
4013
4013
|
if (!r.current && "changedTouches" in f && (N || C) && (r.current = S), !S)
|
|
4014
4014
|
return !0;
|
|
@@ -4814,12 +4814,12 @@ const Kc = (e) => ({
|
|
|
4814
4814
|
}, g = rr(o), y = nr(g), f = await s.getDimensions(d), h = g === "y", b = h ? "top" : "left", w = h ? "bottom" : "right", N = h ? "clientHeight" : "clientWidth", C = a.reference[y] + a.reference[g] - v[g] - a.floating[y], S = v[g] - a.reference[g], E = await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(d));
|
|
4815
4815
|
let T = E ? E[N] : 0;
|
|
4816
4816
|
(!T || !await (s.isElement == null ? void 0 : s.isElement(E))) && (T = c.floating[N] || a.floating[y]);
|
|
4817
|
-
const
|
|
4817
|
+
const z = C / 2 - S / 2, _ = T / 2 - f[y] / 2 - 1, W = _e(m[b], _), H = _e(m[w], _), B = W, D = T - f[y] - H, R = T / 2 - f[y] / 2 + z, j = Dn(B, R, D), P = !u.arrow && st(o) != null && R !== j && a.reference[y] / 2 - (R < B ? W : H) - f[y] / 2 < 0, U = P ? R < B ? R - B : R - D : 0;
|
|
4818
4818
|
return {
|
|
4819
4819
|
[g]: v[g] + U,
|
|
4820
4820
|
data: {
|
|
4821
|
-
[g]:
|
|
4822
|
-
centerOffset: R -
|
|
4821
|
+
[g]: j,
|
|
4822
|
+
centerOffset: R - j - U,
|
|
4823
4823
|
...P && {
|
|
4824
4824
|
alignmentOffset: U
|
|
4825
4825
|
}
|
|
@@ -4853,42 +4853,42 @@ const Kc = (e) => ({
|
|
|
4853
4853
|
return {};
|
|
4854
4854
|
const b = Re(o), w = Ie(c), N = Re(c) === c, C = await (u.isRTL == null ? void 0 : u.isRTL(d.floating)), S = v || (N || !f ? [Bt(c)] : jc(c)), E = y !== "none";
|
|
4855
4855
|
!v && E && S.push(...Hc(c, f, y, C));
|
|
4856
|
-
const T = [c, ...S],
|
|
4857
|
-
let
|
|
4858
|
-
if (p && _.push(
|
|
4856
|
+
const T = [c, ...S], z = await ht(t, h), _ = [];
|
|
4857
|
+
let W = ((r = a.flip) == null ? void 0 : r.overflows) || [];
|
|
4858
|
+
if (p && _.push(z[b]), m) {
|
|
4859
4859
|
const R = Bc(o, s, C);
|
|
4860
|
-
_.push(
|
|
4860
|
+
_.push(z[R[0]], z[R[1]]);
|
|
4861
4861
|
}
|
|
4862
|
-
if (
|
|
4862
|
+
if (W = [...W, {
|
|
4863
4863
|
placement: o,
|
|
4864
4864
|
overflows: _
|
|
4865
4865
|
}], !_.every((R) => R <= 0)) {
|
|
4866
|
-
var
|
|
4867
|
-
const R = (((
|
|
4868
|
-
if (
|
|
4866
|
+
var H, B;
|
|
4867
|
+
const R = (((H = a.flip) == null ? void 0 : H.index) || 0) + 1, j = T[R];
|
|
4868
|
+
if (j)
|
|
4869
4869
|
return {
|
|
4870
4870
|
data: {
|
|
4871
4871
|
index: R,
|
|
4872
|
-
overflows:
|
|
4872
|
+
overflows: W
|
|
4873
4873
|
},
|
|
4874
4874
|
reset: {
|
|
4875
|
-
placement:
|
|
4875
|
+
placement: j
|
|
4876
4876
|
}
|
|
4877
4877
|
};
|
|
4878
|
-
let P = (
|
|
4878
|
+
let P = (B = W.filter((U) => U.overflows[0] <= 0).sort((U, O) => U.overflows[1] - O.overflows[1])[0]) == null ? void 0 : B.placement;
|
|
4879
4879
|
if (!P)
|
|
4880
4880
|
switch (g) {
|
|
4881
4881
|
case "bestFit": {
|
|
4882
4882
|
var D;
|
|
4883
|
-
const U = (D =
|
|
4883
|
+
const U = (D = W.filter((O) => {
|
|
4884
4884
|
if (E) {
|
|
4885
|
-
const
|
|
4886
|
-
return
|
|
4885
|
+
const L = Ie(O.placement);
|
|
4886
|
+
return L === w || // Create a bias to the `y` side axis due to horizontal
|
|
4887
4887
|
// reading directions favoring greater width.
|
|
4888
|
-
|
|
4888
|
+
L === "y";
|
|
4889
4889
|
}
|
|
4890
4890
|
return !0;
|
|
4891
|
-
}).map((O) => [O.placement, O.overflows.filter((
|
|
4891
|
+
}).map((O) => [O.placement, O.overflows.filter((L) => L > 0).reduce((L, q) => L + q, 0)]).sort((O, L) => O[1] - L[1])[0]) == null ? void 0 : D[0];
|
|
4892
4892
|
U && (P = U);
|
|
4893
4893
|
break;
|
|
4894
4894
|
}
|
|
@@ -5129,14 +5129,14 @@ const Qc = function(e) {
|
|
|
5129
5129
|
let h, b;
|
|
5130
5130
|
m === "top" || m === "bottom" ? (h = m, b = v === (await (s.isRTL == null ? void 0 : s.isRTL(c.floating)) ? "start" : "end") ? "left" : "right") : (b = m, h = v === "end" ? "top" : "bottom");
|
|
5131
5131
|
const w = f - p.top - p.bottom, N = y - p.left - p.right, C = _e(f - p[h], w), S = _e(y - p[b], N), E = !t.middlewareData.shift;
|
|
5132
|
-
let T = C,
|
|
5133
|
-
if ((n = t.middlewareData.shift) != null && n.enabled.x && (
|
|
5134
|
-
const
|
|
5135
|
-
g ?
|
|
5132
|
+
let T = C, z = S;
|
|
5133
|
+
if ((n = t.middlewareData.shift) != null && n.enabled.x && (z = N), (r = t.middlewareData.shift) != null && r.enabled.y && (T = w), E && !v) {
|
|
5134
|
+
const W = de(p.left, 0), H = de(p.right, 0), B = de(p.top, 0), D = de(p.bottom, 0);
|
|
5135
|
+
g ? z = y - 2 * (W !== 0 || H !== 0 ? W + H : de(p.left, p.right)) : T = f - 2 * (B !== 0 || D !== 0 ? B + D : de(p.top, p.bottom));
|
|
5136
5136
|
}
|
|
5137
5137
|
await u({
|
|
5138
5138
|
...t,
|
|
5139
|
-
availableWidth:
|
|
5139
|
+
availableWidth: z,
|
|
5140
5140
|
availableHeight: T
|
|
5141
5141
|
});
|
|
5142
5142
|
const _ = await s.getDimensions(c.floating);
|
|
@@ -5707,7 +5707,7 @@ function Td(e) {
|
|
|
5707
5707
|
O !== E.current && (E.current = O, f(O));
|
|
5708
5708
|
}, []), N = l.useCallback((O) => {
|
|
5709
5709
|
O !== T.current && (T.current = O, b(O));
|
|
5710
|
-
}, []), C = a || y, S = s || h, E = l.useRef(null), T = l.useRef(null),
|
|
5710
|
+
}, []), C = a || y, S = s || h, E = l.useRef(null), T = l.useRef(null), z = l.useRef(p), _ = u != null, W = xn(u), H = xn(o), B = xn(d), D = l.useCallback(() => {
|
|
5711
5711
|
if (!E.current || !T.current)
|
|
5712
5712
|
return;
|
|
5713
5713
|
const O = {
|
|
@@ -5715,22 +5715,22 @@ function Td(e) {
|
|
|
5715
5715
|
strategy: n,
|
|
5716
5716
|
middleware: v
|
|
5717
5717
|
};
|
|
5718
|
-
|
|
5718
|
+
H.current && (O.platform = H.current), Sd(E.current, T.current, O).then((L) => {
|
|
5719
5719
|
const q = {
|
|
5720
|
-
|
|
5720
|
+
...L,
|
|
5721
5721
|
// The floating element's position may be recomputed while it's closed
|
|
5722
5722
|
// but still mounted (such as when transitioning out). To ensure
|
|
5723
5723
|
// `isPositioned` will be `false` initially on the next open, avoid
|
|
5724
5724
|
// setting it to `true` when `open === false` (must be specified).
|
|
5725
|
-
isPositioned:
|
|
5725
|
+
isPositioned: B.current !== !1
|
|
5726
5726
|
};
|
|
5727
|
-
R.current && !Vt(
|
|
5727
|
+
R.current && !Vt(z.current, q) && (z.current = q, Vn.flushSync(() => {
|
|
5728
5728
|
m(q);
|
|
5729
5729
|
}));
|
|
5730
5730
|
});
|
|
5731
|
-
}, [v, t, n,
|
|
5731
|
+
}, [v, t, n, H, B]);
|
|
5732
5732
|
It(() => {
|
|
5733
|
-
d === !1 &&
|
|
5733
|
+
d === !1 && z.current.isPositioned && (z.current.isPositioned = !1, m((O) => ({
|
|
5734
5734
|
...O,
|
|
5735
5735
|
isPositioned: !1
|
|
5736
5736
|
})));
|
|
@@ -5740,12 +5740,12 @@ function Td(e) {
|
|
|
5740
5740
|
R.current = !1;
|
|
5741
5741
|
}), []), It(() => {
|
|
5742
5742
|
if (C && (E.current = C), S && (T.current = S), C && S) {
|
|
5743
|
-
if (
|
|
5744
|
-
return
|
|
5743
|
+
if (W.current)
|
|
5744
|
+
return W.current(C, S, D);
|
|
5745
5745
|
D();
|
|
5746
5746
|
}
|
|
5747
|
-
}, [C, S, D,
|
|
5748
|
-
const
|
|
5747
|
+
}, [C, S, D, W, _]);
|
|
5748
|
+
const j = l.useMemo(() => ({
|
|
5749
5749
|
reference: E,
|
|
5750
5750
|
floating: T,
|
|
5751
5751
|
setReference: w,
|
|
@@ -5761,26 +5761,26 @@ function Td(e) {
|
|
|
5761
5761
|
};
|
|
5762
5762
|
if (!P.floating)
|
|
5763
5763
|
return O;
|
|
5764
|
-
const
|
|
5764
|
+
const L = qr(P.floating, p.x), q = qr(P.floating, p.y);
|
|
5765
5765
|
return c ? {
|
|
5766
5766
|
...O,
|
|
5767
|
-
transform: "translate(" +
|
|
5767
|
+
transform: "translate(" + L + "px, " + q + "px)",
|
|
5768
5768
|
...fa(P.floating) >= 1.5 && {
|
|
5769
5769
|
willChange: "transform"
|
|
5770
5770
|
}
|
|
5771
5771
|
} : {
|
|
5772
5772
|
position: n,
|
|
5773
|
-
left:
|
|
5773
|
+
left: L,
|
|
5774
5774
|
top: q
|
|
5775
5775
|
};
|
|
5776
5776
|
}, [n, c, P.floating, p.x, p.y]);
|
|
5777
5777
|
return l.useMemo(() => ({
|
|
5778
5778
|
...p,
|
|
5779
5779
|
update: D,
|
|
5780
|
-
refs:
|
|
5780
|
+
refs: j,
|
|
5781
5781
|
elements: P,
|
|
5782
5782
|
floatingStyles: U
|
|
5783
|
-
}), [p, D,
|
|
5783
|
+
}), [p, D, j, P, U]);
|
|
5784
5784
|
}
|
|
5785
5785
|
const Rd = (e) => {
|
|
5786
5786
|
function t(n) {
|
|
@@ -5896,12 +5896,12 @@ var cr = "PopperContent", [zd, Wd] = ma(cr), wa = l.forwardRef(
|
|
|
5896
5896
|
updatePositionStrategy: g = "optimized",
|
|
5897
5897
|
onPlaced: y,
|
|
5898
5898
|
...f
|
|
5899
|
-
} = e, h = ga(cr, n), [b, w] = l.useState(null), N = se(t, ($e) => w($e)), [C, S] = l.useState(null), E = $d(C), T = (E == null ? void 0 : E.width) ?? 0,
|
|
5900
|
-
padding:
|
|
5901
|
-
boundary:
|
|
5899
|
+
} = e, h = ga(cr, n), [b, w] = l.useState(null), N = se(t, ($e) => w($e)), [C, S] = l.useState(null), E = $d(C), T = (E == null ? void 0 : E.width) ?? 0, z = (E == null ? void 0 : E.height) ?? 0, _ = r + (a !== "center" ? "-" + a : ""), W = typeof p == "number" ? p : { top: 0, right: 0, bottom: 0, left: 0, ...p }, H = Array.isArray(d) ? d : [d], B = H.length > 0, D = {
|
|
5900
|
+
padding: W,
|
|
5901
|
+
boundary: H.filter(jd),
|
|
5902
5902
|
// with `strategy: 'fixed'`, this is the only way to get it to respect boundaries
|
|
5903
|
-
altBoundary:
|
|
5904
|
-
}, { refs: R, floatingStyles:
|
|
5903
|
+
altBoundary: B
|
|
5904
|
+
}, { refs: R, floatingStyles: j, placement: P, isPositioned: U, middlewareData: O } = Td({
|
|
5905
5905
|
// default to `fixed` strategy so users don't have to pick and we also avoid focus scroll issues
|
|
5906
5906
|
strategy: "fixed",
|
|
5907
5907
|
placement: _,
|
|
@@ -5912,7 +5912,7 @@ var cr = "PopperContent", [zd, Wd] = ma(cr), wa = l.forwardRef(
|
|
|
5912
5912
|
reference: h.anchor
|
|
5913
5913
|
},
|
|
5914
5914
|
middleware: [
|
|
5915
|
-
Pd({ mainAxis: o +
|
|
5915
|
+
Pd({ mainAxis: o + z, alignmentAxis: s }),
|
|
5916
5916
|
u && Ad({
|
|
5917
5917
|
mainAxis: !0,
|
|
5918
5918
|
crossAxis: !1,
|
|
@@ -5922,20 +5922,20 @@ var cr = "PopperContent", [zd, Wd] = ma(cr), wa = l.forwardRef(
|
|
|
5922
5922
|
u && Md({ ...D }),
|
|
5923
5923
|
Od({
|
|
5924
5924
|
...D,
|
|
5925
|
-
apply: ({ elements: $e, rects: I, availableWidth:
|
|
5925
|
+
apply: ({ elements: $e, rects: I, availableWidth: F, availableHeight: oe }) => {
|
|
5926
5926
|
const { width: ie, height: le } = I.reference, K = $e.floating.style;
|
|
5927
|
-
K.setProperty("--radix-popper-available-width", `${
|
|
5927
|
+
K.setProperty("--radix-popper-available-width", `${F}px`), K.setProperty("--radix-popper-available-height", `${oe}px`), K.setProperty("--radix-popper-anchor-width", `${ie}px`), K.setProperty("--radix-popper-anchor-height", `${le}px`);
|
|
5928
5928
|
}
|
|
5929
5929
|
}),
|
|
5930
5930
|
C && _d({ element: C, padding: c }),
|
|
5931
|
-
Vd({ arrowWidth: T, arrowHeight:
|
|
5931
|
+
Vd({ arrowWidth: T, arrowHeight: z }),
|
|
5932
5932
|
v && Dd({ strategy: "referenceHidden", ...D })
|
|
5933
5933
|
]
|
|
5934
|
-
}), [
|
|
5934
|
+
}), [L, q] = Ca(P), Z = fe(y);
|
|
5935
5935
|
De(() => {
|
|
5936
5936
|
U && (Z == null || Z());
|
|
5937
5937
|
}, [U, Z]);
|
|
5938
|
-
const re = (be = O.arrow) == null ? void 0 : be.x,
|
|
5938
|
+
const re = (be = O.arrow) == null ? void 0 : be.x, $ = (lt = O.arrow) == null ? void 0 : lt.y, G = ((xt = O.arrow) == null ? void 0 : xt.centerOffset) !== 0, [J, Pe] = l.useState();
|
|
5939
5939
|
return De(() => {
|
|
5940
5940
|
b && Pe(window.getComputedStyle(b).zIndex);
|
|
5941
5941
|
}, [b]), /* @__PURE__ */ i(
|
|
@@ -5944,8 +5944,8 @@ var cr = "PopperContent", [zd, Wd] = ma(cr), wa = l.forwardRef(
|
|
|
5944
5944
|
ref: R.setFloating,
|
|
5945
5945
|
"data-radix-popper-content-wrapper": "",
|
|
5946
5946
|
style: {
|
|
5947
|
-
...
|
|
5948
|
-
transform: U ?
|
|
5947
|
+
...j,
|
|
5948
|
+
transform: U ? j.transform : "translate(0, -200%)",
|
|
5949
5949
|
// keep off the page when measuring
|
|
5950
5950
|
minWidth: "max-content",
|
|
5951
5951
|
zIndex: J,
|
|
@@ -5966,15 +5966,15 @@ var cr = "PopperContent", [zd, Wd] = ma(cr), wa = l.forwardRef(
|
|
|
5966
5966
|
zd,
|
|
5967
5967
|
{
|
|
5968
5968
|
scope: n,
|
|
5969
|
-
placedSide:
|
|
5969
|
+
placedSide: L,
|
|
5970
5970
|
onArrowChange: S,
|
|
5971
5971
|
arrowX: re,
|
|
5972
|
-
arrowY:
|
|
5972
|
+
arrowY: $,
|
|
5973
5973
|
shouldHideArrow: G,
|
|
5974
5974
|
children: /* @__PURE__ */ i(
|
|
5975
5975
|
Q.div,
|
|
5976
5976
|
{
|
|
5977
|
-
"data-side":
|
|
5977
|
+
"data-side": L,
|
|
5978
5978
|
"data-align": q,
|
|
5979
5979
|
...f,
|
|
5980
5980
|
ref: N,
|
|
@@ -7278,13 +7278,13 @@ var Qa = "ToastViewport", Ju = ["F8"], Fn = "toast.viewportPause", zn = "toast.v
|
|
|
7278
7278
|
var S, E, T;
|
|
7279
7279
|
const N = w.altKey || w.ctrlKey || w.metaKey;
|
|
7280
7280
|
if (w.key === "Tab" && !N) {
|
|
7281
|
-
const
|
|
7281
|
+
const z = document.activeElement, _ = w.shiftKey;
|
|
7282
7282
|
if (w.target === h && _) {
|
|
7283
7283
|
(S = d.current) == null || S.focus();
|
|
7284
7284
|
return;
|
|
7285
7285
|
}
|
|
7286
|
-
const
|
|
7287
|
-
Cn(
|
|
7286
|
+
const B = f({ tabbingDirection: _ ? "backwards" : "forwards" }), D = B.findIndex((R) => R === z);
|
|
7287
|
+
Cn(B.slice(D + 1)) ? w.preventDefault() : _ ? (E = d.current) == null || E.focus() : (T = p.current) == null || T.focus();
|
|
7288
7288
|
}
|
|
7289
7289
|
};
|
|
7290
7290
|
return h.addEventListener("keydown", b), () => h.removeEventListener("keydown", b);
|
|
@@ -7404,31 +7404,31 @@ var [of, af] = qa(dn, {
|
|
|
7404
7404
|
onSwipeCancel: v,
|
|
7405
7405
|
onSwipeEnd: g,
|
|
7406
7406
|
...y
|
|
7407
|
-
} = e, f = cn(dn, n), [h, b] = l.useState(null), w = se(t, (R) => b(R)), N = l.useRef(null), C = l.useRef(null), S = o || f.duration, E = l.useRef(0), T = l.useRef(S),
|
|
7408
|
-
var
|
|
7409
|
-
(h == null ? void 0 : h.contains(document.activeElement)) && ((
|
|
7410
|
-
}),
|
|
7407
|
+
} = e, f = cn(dn, n), [h, b] = l.useState(null), w = se(t, (R) => b(R)), N = l.useRef(null), C = l.useRef(null), S = o || f.duration, E = l.useRef(0), T = l.useRef(S), z = l.useRef(0), { onToastAdd: _, onToastRemove: W } = f, H = fe(() => {
|
|
7408
|
+
var j;
|
|
7409
|
+
(h == null ? void 0 : h.contains(document.activeElement)) && ((j = f.viewport) == null || j.focus()), s();
|
|
7410
|
+
}), B = l.useCallback(
|
|
7411
7411
|
(R) => {
|
|
7412
|
-
!R || R === 1 / 0 || (window.clearTimeout(
|
|
7412
|
+
!R || R === 1 / 0 || (window.clearTimeout(z.current), E.current = (/* @__PURE__ */ new Date()).getTime(), z.current = window.setTimeout(H, R));
|
|
7413
7413
|
},
|
|
7414
|
-
[
|
|
7414
|
+
[H]
|
|
7415
7415
|
);
|
|
7416
7416
|
l.useEffect(() => {
|
|
7417
7417
|
const R = f.viewport;
|
|
7418
7418
|
if (R) {
|
|
7419
|
-
const
|
|
7420
|
-
|
|
7419
|
+
const j = () => {
|
|
7420
|
+
B(T.current), d == null || d();
|
|
7421
7421
|
}, P = () => {
|
|
7422
7422
|
const U = (/* @__PURE__ */ new Date()).getTime() - E.current;
|
|
7423
|
-
T.current = T.current - U, window.clearTimeout(
|
|
7423
|
+
T.current = T.current - U, window.clearTimeout(z.current), u == null || u();
|
|
7424
7424
|
};
|
|
7425
|
-
return R.addEventListener(Fn, P), R.addEventListener(zn,
|
|
7426
|
-
R.removeEventListener(Fn, P), R.removeEventListener(zn,
|
|
7425
|
+
return R.addEventListener(Fn, P), R.addEventListener(zn, j), () => {
|
|
7426
|
+
R.removeEventListener(Fn, P), R.removeEventListener(zn, j);
|
|
7427
7427
|
};
|
|
7428
7428
|
}
|
|
7429
|
-
}, [f.viewport, S, u, d,
|
|
7430
|
-
a && !f.isClosePausedRef.current &&
|
|
7431
|
-
}, [a, S, f.isClosePausedRef,
|
|
7429
|
+
}, [f.viewport, S, u, d, B]), l.useEffect(() => {
|
|
7430
|
+
a && !f.isClosePausedRef.current && B(S);
|
|
7431
|
+
}, [a, S, f.isClosePausedRef, B]), l.useEffect(() => (_(), () => W()), [_, W]);
|
|
7432
7432
|
const D = l.useMemo(() => h ? is(h) : null, [h]);
|
|
7433
7433
|
return f.viewport ? /* @__PURE__ */ x(te, { children: [
|
|
7434
7434
|
D && /* @__PURE__ */ i(
|
|
@@ -7441,13 +7441,13 @@ var [of, af] = qa(dn, {
|
|
|
7441
7441
|
children: D
|
|
7442
7442
|
}
|
|
7443
7443
|
),
|
|
7444
|
-
/* @__PURE__ */ i(of, { scope: n, onClose:
|
|
7444
|
+
/* @__PURE__ */ i(of, { scope: n, onClose: H, children: Vn.createPortal(
|
|
7445
7445
|
/* @__PURE__ */ i(mr.ItemSlot, { scope: n, children: /* @__PURE__ */ i(
|
|
7446
7446
|
Al,
|
|
7447
7447
|
{
|
|
7448
7448
|
asChild: !0,
|
|
7449
7449
|
onEscapeKeyDown: X(c, () => {
|
|
7450
|
-
f.isFocusedToastEscapeKeyDownRef.current ||
|
|
7450
|
+
f.isFocusedToastEscapeKeyDownRef.current || H(), f.isFocusedToastEscapeKeyDownRef.current = !1;
|
|
7451
7451
|
}),
|
|
7452
7452
|
children: /* @__PURE__ */ i(
|
|
7453
7453
|
Q.li,
|
|
@@ -7462,25 +7462,25 @@ var [of, af] = qa(dn, {
|
|
|
7462
7462
|
ref: w,
|
|
7463
7463
|
style: { userSelect: "none", touchAction: "none", ...e.style },
|
|
7464
7464
|
onKeyDown: X(e.onKeyDown, (R) => {
|
|
7465
|
-
R.key === "Escape" && (c == null || c(R.nativeEvent), R.nativeEvent.defaultPrevented || (f.isFocusedToastEscapeKeyDownRef.current = !0,
|
|
7465
|
+
R.key === "Escape" && (c == null || c(R.nativeEvent), R.nativeEvent.defaultPrevented || (f.isFocusedToastEscapeKeyDownRef.current = !0, H()));
|
|
7466
7466
|
}),
|
|
7467
7467
|
onPointerDown: X(e.onPointerDown, (R) => {
|
|
7468
7468
|
R.button === 0 && (N.current = { x: R.clientX, y: R.clientY });
|
|
7469
7469
|
}),
|
|
7470
7470
|
onPointerMove: X(e.onPointerMove, (R) => {
|
|
7471
7471
|
if (!N.current) return;
|
|
7472
|
-
const
|
|
7473
|
-
U ? (C.current =
|
|
7472
|
+
const j = R.clientX - N.current.x, P = R.clientY - N.current.y, U = !!C.current, O = ["left", "right"].includes(f.swipeDirection), L = ["left", "up"].includes(f.swipeDirection) ? Math.min : Math.max, q = O ? L(0, j) : 0, Z = O ? 0 : L(0, P), re = R.pointerType === "touch" ? 10 : 2, $ = { x: q, y: Z }, G = { originalEvent: R, delta: $ };
|
|
7473
|
+
U ? (C.current = $, Mt(tf, m, G, {
|
|
7474
7474
|
discrete: !1
|
|
7475
|
-
})) : Qr(
|
|
7475
|
+
})) : Qr($, f.swipeDirection, re) ? (C.current = $, Mt(ef, p, G, {
|
|
7476
7476
|
discrete: !1
|
|
7477
|
-
}), R.target.setPointerCapture(R.pointerId)) : (Math.abs(
|
|
7477
|
+
}), R.target.setPointerCapture(R.pointerId)) : (Math.abs(j) > re || Math.abs(P) > re) && (N.current = null);
|
|
7478
7478
|
}),
|
|
7479
7479
|
onPointerUp: X(e.onPointerUp, (R) => {
|
|
7480
|
-
const
|
|
7481
|
-
if (P.hasPointerCapture(R.pointerId) && P.releasePointerCapture(R.pointerId), C.current = null, N.current = null,
|
|
7482
|
-
const U = R.currentTarget, O = { originalEvent: R, delta:
|
|
7483
|
-
Qr(
|
|
7480
|
+
const j = C.current, P = R.target;
|
|
7481
|
+
if (P.hasPointerCapture(R.pointerId) && P.releasePointerCapture(R.pointerId), C.current = null, N.current = null, j) {
|
|
7482
|
+
const U = R.currentTarget, O = { originalEvent: R, delta: j };
|
|
7483
|
+
Qr(j, f.swipeDirection, f.swipeThreshold) ? Mt(rf, g, O, {
|
|
7484
7484
|
discrete: !0
|
|
7485
7485
|
}) : Mt(
|
|
7486
7486
|
nf,
|
|
@@ -7489,7 +7489,7 @@ var [of, af] = qa(dn, {
|
|
|
7489
7489
|
{
|
|
7490
7490
|
discrete: !0
|
|
7491
7491
|
}
|
|
7492
|
-
), U.addEventListener("click", (
|
|
7492
|
+
), U.addEventListener("click", (L) => L.preventDefault(), {
|
|
7493
7493
|
once: !0
|
|
7494
7494
|
});
|
|
7495
7495
|
}
|
|
@@ -8182,10 +8182,10 @@ function Qf({
|
|
|
8182
8182
|
syncToShopifyAction: c,
|
|
8183
8183
|
isSyncToShopifyActionLoading: u = !1
|
|
8184
8184
|
}) {
|
|
8185
|
-
var R,
|
|
8186
|
-
const [d, p] = Se(1), [m, v] = Se(null), [g, y] = Se(0), [f, h] = Se(!1), b = ((R = e == null ? void 0 : e.Distribution) == null ? void 0 : R.RegularPrice) || 0, w = ((
|
|
8185
|
+
var R, j, P, U, O, L, q, Z, re;
|
|
8186
|
+
const [d, p] = Se(1), [m, v] = Se(null), [g, y] = Se(0), [f, h] = Se(!1), b = ((R = e == null ? void 0 : e.Distribution) == null ? void 0 : R.RegularPrice) || 0, w = ((j = e == null ? void 0 : e.Distribution) == null ? void 0 : j.Price) || 0, [N, C] = Se(null), [S, E] = Se(!1);
|
|
8187
8187
|
if (Ze(() => {
|
|
8188
|
-
const
|
|
8188
|
+
const $ = async () => {
|
|
8189
8189
|
if (e != null && e.ManufacturerId) {
|
|
8190
8190
|
E(!0);
|
|
8191
8191
|
try {
|
|
@@ -8203,17 +8203,17 @@ function Qf({
|
|
|
8203
8203
|
}
|
|
8204
8204
|
}
|
|
8205
8205
|
};
|
|
8206
|
-
e != null && e.ManufacturerId &&
|
|
8206
|
+
e != null && e.ManufacturerId && $();
|
|
8207
8207
|
}, [e == null ? void 0 : e.ManufacturerId]), Ze(() => {
|
|
8208
|
-
var
|
|
8208
|
+
var $;
|
|
8209
8209
|
if (e && r) {
|
|
8210
|
-
const G = (
|
|
8210
|
+
const G = ($ = e.Opportunities) == null ? void 0 : $.find((J) => J.BidNumber == r);
|
|
8211
8211
|
G && v(G);
|
|
8212
8212
|
}
|
|
8213
8213
|
}, [e, r]), Ze(() => {
|
|
8214
8214
|
if (!e) return;
|
|
8215
|
-
const
|
|
8216
|
-
y(b > 0 ? Math.round((b -
|
|
8215
|
+
const $ = m != null && m.Price ? m.Price : w;
|
|
8216
|
+
y(b > 0 ? Math.round((b - $) / b * 100) : 0);
|
|
8217
8217
|
}, [e, m, w, b]), Ze(() => {
|
|
8218
8218
|
s || p(1);
|
|
8219
8219
|
}, [s]), !e)
|
|
@@ -8269,15 +8269,15 @@ function Qf({
|
|
|
8269
8269
|
] })
|
|
8270
8270
|
] })
|
|
8271
8271
|
] }) });
|
|
8272
|
-
const T = (e == null ? void 0 : e.Opportunities) || [],
|
|
8272
|
+
const T = (e == null ? void 0 : e.Opportunities) || [], z = T.length > 0, _ = () => {
|
|
8273
8273
|
d > 1 && p(d - 1);
|
|
8274
|
-
},
|
|
8274
|
+
}, W = () => {
|
|
8275
8275
|
p(d + 1);
|
|
8276
|
-
},
|
|
8276
|
+
}, H = ((U = (P = e.Distribution) == null ? void 0 : P.Inventory) == null ? void 0 : U.reduce(($, G) => $ + (G.AvailableQuantity || 0), 0)) || 0, B = ($) => {
|
|
8277
8277
|
try {
|
|
8278
|
-
return new Date(
|
|
8278
|
+
return new Date($).toLocaleDateString("en-US", { year: "numeric", month: "short", day: "numeric" });
|
|
8279
8279
|
} catch (G) {
|
|
8280
|
-
return console.error(G),
|
|
8280
|
+
return console.error(G), $.split("T")[0] || "N/A";
|
|
8281
8281
|
}
|
|
8282
8282
|
}, D = () => {
|
|
8283
8283
|
a && a({ quantity: d, bidNumber: (m == null ? void 0 : m.BidNumber) ?? null });
|
|
@@ -8386,36 +8386,36 @@ function Qf({
|
|
|
8386
8386
|
/* @__PURE__ */ x("div", { className: "flex gap-6 mt-4", children: [
|
|
8387
8387
|
/* @__PURE__ */ i("div", { className: "flex flex-1", children: e.Distribution && /* @__PURE__ */ x("div", { className: "w-full", children: [
|
|
8388
8388
|
/* @__PURE__ */ i("div", { className: "text-sm text-muted-foreground flex items-center", children: "Opportunities" }),
|
|
8389
|
-
|
|
8389
|
+
z ? /* @__PURE__ */ i("div", { className: "space-y-2 max-h-[200px] overflow-y-auto pr-1 mt-1", children: T.map(($, G) => {
|
|
8390
8390
|
var J;
|
|
8391
8391
|
return /* @__PURE__ */ x(
|
|
8392
8392
|
"div",
|
|
8393
8393
|
{
|
|
8394
8394
|
className: `flex justify-between items-center border border-gray-100 rounded transition-colors py-2 px-4
|
|
8395
|
-
${
|
|
8395
|
+
${$.BidNumber == (m == null ? void 0 : m.BidNumber) ? "bg-primary/10 cursor-pointer" : $.Active ? "hover:bg-primary/5 cursor-pointer" : ""}
|
|
8396
8396
|
`,
|
|
8397
8397
|
onClick: () => v(
|
|
8398
|
-
|
|
8398
|
+
$.BidNumber != (m == null ? void 0 : m.BidNumber) ? $ : null
|
|
8399
8399
|
),
|
|
8400
8400
|
children: [
|
|
8401
8401
|
/* @__PURE__ */ i("div", { className: "flex items-center", children: /* @__PURE__ */ x("div", { className: "flex flex-col", children: [
|
|
8402
|
-
/* @__PURE__ */ i("span", { className: "font-medium text-sm", children:
|
|
8403
|
-
/* @__PURE__ */ i("span", { className: "text-xs text-gray-500", children:
|
|
8402
|
+
/* @__PURE__ */ i("span", { className: "font-medium text-sm", children: $.Opportunity }),
|
|
8403
|
+
/* @__PURE__ */ i("span", { className: "text-xs text-gray-500", children: $.BidNumber })
|
|
8404
8404
|
] }) }),
|
|
8405
8405
|
/* @__PURE__ */ x("div", { className: "flex flex-col items-end", children: [
|
|
8406
8406
|
/* @__PURE__ */ x("span", { className: "font-semibold", children: [
|
|
8407
8407
|
"$",
|
|
8408
|
-
(J =
|
|
8408
|
+
(J = $.Price) == null ? void 0 : J.toFixed(2)
|
|
8409
8409
|
] }),
|
|
8410
|
-
|
|
8410
|
+
$.Rebate && $.Rebate > 0 && /* @__PURE__ */ x("span", { className: "text-xs text-green-600", children: [
|
|
8411
8411
|
"Rebate: $",
|
|
8412
|
-
|
|
8412
|
+
$.Rebate.toFixed(2)
|
|
8413
8413
|
] }),
|
|
8414
|
-
|
|
8414
|
+
$.EndDate && /* @__PURE__ */ x("span", { className: "text-xs text-gray-500", children: [
|
|
8415
8415
|
"Ends: ",
|
|
8416
|
-
|
|
8416
|
+
B($.EndDate)
|
|
8417
8417
|
] }),
|
|
8418
|
-
|
|
8418
|
+
!$.Active && /* @__PURE__ */ i(Ee, { variant: "outline", className: "text-xs px-2 py-0 h-5 mt-1 bg-gray-100", children: "Inactive" })
|
|
8419
8419
|
] })
|
|
8420
8420
|
]
|
|
8421
8421
|
},
|
|
@@ -8428,16 +8428,16 @@ function Qf({
|
|
|
8428
8428
|
/* @__PURE__ */ i(Js, { className: "mr-2" }),
|
|
8429
8429
|
"View Product"
|
|
8430
8430
|
] }),
|
|
8431
|
-
((
|
|
8431
|
+
((L = e.Distribution) == null ? void 0 : L.Inventory) && /* @__PURE__ */ i("div", { className: "mt-4", children: /* @__PURE__ */ x(Zt, { open: f, onOpenChange: h, children: [
|
|
8432
8432
|
/* @__PURE__ */ i(Jo, { asChild: !0, children: /* @__PURE__ */ x(
|
|
8433
8433
|
ae,
|
|
8434
8434
|
{
|
|
8435
8435
|
variant: "ghost",
|
|
8436
|
-
className: `flex items-center text-sm ${
|
|
8436
|
+
className: `flex items-center text-sm ${H > 0 ? "text-green-700" : "text-red-700"}`,
|
|
8437
8437
|
children: [
|
|
8438
8438
|
/* @__PURE__ */ i(xr, { size: "16", className: "mr-2" }),
|
|
8439
|
-
|
|
8440
|
-
|
|
8439
|
+
H > 0 ? /* @__PURE__ */ x(te, { children: [
|
|
8440
|
+
H,
|
|
8441
8441
|
" in stock"
|
|
8442
8442
|
] }) : /* @__PURE__ */ i(te, { children: "Out of stock" })
|
|
8443
8443
|
]
|
|
@@ -8458,7 +8458,7 @@ function Qf({
|
|
|
8458
8458
|
/* @__PURE__ */ x("div", { className: "flex items-center flex-wrap", children: [
|
|
8459
8459
|
/* @__PURE__ */ x("span", { className: "text-2xl font-bold whitespace-nowrap", children: [
|
|
8460
8460
|
/* @__PURE__ */ i("span", { children: "$" }),
|
|
8461
|
-
m ? (Z = (q = e.Opportunities) == null ? void 0 : q.find((
|
|
8461
|
+
m ? (Z = (q = e.Opportunities) == null ? void 0 : q.find(($) => $.BidNumber == m.BidNumber)) == null ? void 0 : Z.Price : w.toFixed(2),
|
|
8462
8462
|
/* @__PURE__ */ i("span", { children: " CAD" })
|
|
8463
8463
|
] }),
|
|
8464
8464
|
g > 0 && /* @__PURE__ */ x("span", { className: "text-muted-foreground line-through ml-2 whitespace-nowrap", children: [
|
|
@@ -8492,14 +8492,14 @@ function Qf({
|
|
|
8492
8492
|
size: "icon",
|
|
8493
8493
|
className: "rounded-r-none",
|
|
8494
8494
|
onClick: _,
|
|
8495
|
-
disabled: typeof
|
|
8495
|
+
disabled: typeof d < "u" && (d <= 1 || !e.AvailableToBuy || s || !a),
|
|
8496
8496
|
children: "-"
|
|
8497
8497
|
}
|
|
8498
8498
|
),
|
|
8499
8499
|
/* @__PURE__ */ i(
|
|
8500
8500
|
"div",
|
|
8501
8501
|
{
|
|
8502
|
-
className: `px-4 ${
|
|
8502
|
+
className: `px-4 ${!e.AvailableToBuy || s || !a ? "text-gray-400" : ""}`,
|
|
8503
8503
|
children: d
|
|
8504
8504
|
}
|
|
8505
8505
|
),
|
|
@@ -8509,8 +8509,8 @@ function Qf({
|
|
|
8509
8509
|
variant: "ghost",
|
|
8510
8510
|
size: "icon",
|
|
8511
8511
|
className: "rounded-l-none",
|
|
8512
|
-
onClick:
|
|
8513
|
-
disabled:
|
|
8512
|
+
onClick: W,
|
|
8513
|
+
disabled: !e.AvailableToBuy || s || !a,
|
|
8514
8514
|
children: "+"
|
|
8515
8515
|
}
|
|
8516
8516
|
)
|
|
@@ -8520,7 +8520,7 @@ function Qf({
|
|
|
8520
8520
|
{
|
|
8521
8521
|
className: "gap-2 whitespace-nowrap",
|
|
8522
8522
|
onClick: D,
|
|
8523
|
-
disabled:
|
|
8523
|
+
disabled: !e.AvailableToBuy || s || !a,
|
|
8524
8524
|
children: s ? /* @__PURE__ */ x(te, { children: [
|
|
8525
8525
|
/* @__PURE__ */ i(yr, { className: "h-4 w-4 animate-spin" }),
|
|
8526
8526
|
"Adding..."
|
|
@@ -8535,7 +8535,7 @@ function Qf({
|
|
|
8535
8535
|
{
|
|
8536
8536
|
className: "gap-2 whitespace-nowrap bg-green-600 hover:bg-green-700",
|
|
8537
8537
|
onClick: c,
|
|
8538
|
-
disabled:
|
|
8538
|
+
disabled: u || !c,
|
|
8539
8539
|
children: u ? /* @__PURE__ */ x(te, { children: [
|
|
8540
8540
|
/* @__PURE__ */ i(yr, { className: "h-4 w-4 animate-spin" }),
|
|
8541
8541
|
"Syncing..."
|