strata-ui-react 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.
@@ -1,7 +1,16 @@
1
1
  import * as React from "react";
2
2
  import { createContext, createElement, useContext, useEffect, useLayoutEffect, useMemo, useRef, useState } from "react";
3
3
  import * as ReactDOM from "react-dom";
4
- var __commonJSMin = (t, n) => () => (n || t((n = { exports: {} }).exports, n), n.exports), __require = /* @__PURE__ */ ((t) => typeof require < "u" ? require : typeof Proxy < "u" ? new Proxy(t, { get: (t, n) => (typeof require < "u" ? require : t)[n] }) : t)(function(t) {
4
+ var __create = Object.create, __defProp = Object.defineProperty, __getOwnPropDesc = Object.getOwnPropertyDescriptor, __getOwnPropNames = Object.getOwnPropertyNames, __getProtoOf = Object.getPrototypeOf, __hasOwnProp = Object.prototype.hasOwnProperty, __commonJSMin = (t, n) => () => (n || t((n = { exports: {} }).exports, n), n.exports), __copyProps = (t, n, i, s) => {
5
+ if (n && typeof n == "object" || typeof n == "function") for (var c = __getOwnPropNames(n), l = 0, u = c.length, d; l < u; l++) d = c[l], !__hasOwnProp.call(t, d) && d !== i && __defProp(t, d, {
6
+ get: ((t) => n[t]).bind(null, d),
7
+ enumerable: !(s = __getOwnPropDesc(n, d)) || s.enumerable
8
+ });
9
+ return t;
10
+ }, __toESM = (t, n, i) => (i = t == null ? {} : __create(__getProtoOf(t)), __copyProps(n || !t || !t.__esModule ? __defProp(i, "default", {
11
+ value: t,
12
+ enumerable: !0
13
+ }) : i, t)), __require = /* @__PURE__ */ ((t) => typeof require < "u" ? require : typeof Proxy < "u" ? new Proxy(t, { get: (t, n) => (typeof require < "u" ? require : t)[n] }) : t)(function(t) {
5
14
  if (typeof require < "u") return require.apply(this, arguments);
6
15
  throw Error("Calling `require` for \"" + t + "\" in an environment that doesn't expose the `require` function.");
7
16
  }), require_react_compiler_runtime_production = /* @__PURE__ */ __commonJSMin(((t) => {
@@ -274,15 +283,15 @@ var require_react_jsx_runtime_production = /* @__PURE__ */ __commonJSMin(((t) =>
274
283
  if (typeof t == "function") return t.$$typeof === P ? null : t.displayName || t.name || null;
275
284
  if (typeof t == "string") return t;
276
285
  switch (t) {
277
- case C: return "Fragment";
286
+ case S: return "Fragment";
278
287
  case T: return "Profiler";
279
- case w: return "StrictMode";
288
+ case C: return "StrictMode";
280
289
  case k: return "Suspense";
281
290
  case A: return "SuspenseList";
282
291
  case N: return "Activity";
283
292
  }
284
293
  if (typeof t == "object") switch (typeof t.tag == "number" && console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), t.$$typeof) {
285
- case S: return "Portal";
294
+ case x: return "Portal";
286
295
  case D: return t.displayName || "Context";
287
296
  case E: return (t._context.displayName || "Context") + ".Consumer";
288
297
  case O:
@@ -314,7 +323,7 @@ var require_react_jsx_runtime_production = /* @__PURE__ */ __commonJSMin(((t) =>
314
323
  }
315
324
  }
316
325
  function c(t) {
317
- if (t === C) return "<>";
326
+ if (t === S) return "<>";
318
327
  if (typeof t == "object" && t && t.$$typeof === M) return "<...>";
319
328
  try {
320
329
  var i = n(t);
@@ -353,7 +362,7 @@ var require_react_jsx_runtime_production = /* @__PURE__ */ __commonJSMin(((t) =>
353
362
  function h(t, n, i, s, c, l) {
354
363
  var u = i.ref;
355
364
  return t = {
356
- $$typeof: x,
365
+ $$typeof: b,
357
366
  type: t,
358
367
  key: n,
359
368
  props: i,
@@ -386,48 +395,48 @@ var require_react_jsx_runtime_production = /* @__PURE__ */ __commonJSMin(((t) =>
386
395
  value: l
387
396
  }), Object.freeze && (Object.freeze(t.props), Object.freeze(t)), t;
388
397
  }
389
- function _(t, i, c, u, m, g) {
390
- var _ = i.children;
391
- if (_ !== void 0) if (u) if (L(_)) {
392
- for (u = 0; u < _.length; u++) v(_[u]);
393
- Object.freeze && Object.freeze(_);
398
+ function g(t, i, c, u, m, g) {
399
+ var v = i.children;
400
+ if (v !== void 0) if (u) if (L(v)) {
401
+ for (u = 0; u < v.length; u++) _(v[u]);
402
+ Object.freeze && Object.freeze(v);
394
403
  } else console.error("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
395
- else v(_);
404
+ else _(v);
396
405
  if (I.call(i, "key")) {
397
- _ = n(t);
406
+ v = n(t);
398
407
  var y = Object.keys(i).filter(function(t) {
399
408
  return t !== "key";
400
409
  });
401
- u = 0 < y.length ? "{key: someKey, " + y.join(": ..., ") + ": ...}" : "{key: someKey}", U[_ + u] || (y = 0 < y.length ? "{" + y.join(": ..., ") + ": ...}" : "{}", console.error("A props object containing a \"key\" prop is being spread into JSX:\n let props = %s;\n <%s {...props} />\nReact keys must be passed directly to JSX without using spread:\n let props = %s;\n <%s key={someKey} {...props} />", u, _, y, _), U[_ + u] = !0);
410
+ u = 0 < y.length ? "{key: someKey, " + y.join(": ..., ") + ": ...}" : "{key: someKey}", U[v + u] || (y = 0 < y.length ? "{" + y.join(": ..., ") + ": ...}" : "{}", console.error("A props object containing a \"key\" prop is being spread into JSX:\n let props = %s;\n <%s {...props} />\nReact keys must be passed directly to JSX without using spread:\n let props = %s;\n <%s key={someKey} {...props} />", u, v, y, v), U[v + u] = !0);
402
411
  }
403
- if (_ = null, c !== void 0 && (s(c), _ = "" + c), d(i) && (s(i.key), _ = "" + i.key), "key" in i) for (var b in c = {}, i) b !== "key" && (c[b] = i[b]);
412
+ if (v = null, c !== void 0 && (s(c), v = "" + c), d(i) && (s(i.key), v = "" + i.key), "key" in i) for (var b in c = {}, i) b !== "key" && (c[b] = i[b]);
404
413
  else c = i;
405
- return _ && f(c, typeof t == "function" ? t.displayName || t.name || "Unknown" : t), h(t, _, c, l(), m, g);
414
+ return v && f(c, typeof t == "function" ? t.displayName || t.name || "Unknown" : t), h(t, v, c, l(), m, g);
406
415
  }
407
- function v(t) {
408
- y(t) ? t._store && (t._store.validated = 1) : typeof t == "object" && t && t.$$typeof === M && (t._payload.status === "fulfilled" ? y(t._payload.value) && t._payload.value._store && (t._payload.value._store.validated = 1) : t._store && (t._store.validated = 1));
416
+ function _(t) {
417
+ v(t) ? t._store && (t._store.validated = 1) : typeof t == "object" && t && t.$$typeof === M && (t._payload.status === "fulfilled" ? v(t._payload.value) && t._payload.value._store && (t._payload.value._store.validated = 1) : t._store && (t._store.validated = 1));
409
418
  }
410
- function y(t) {
411
- return typeof t == "object" && !!t && t.$$typeof === x;
419
+ function v(t) {
420
+ return typeof t == "object" && !!t && t.$$typeof === b;
412
421
  }
413
- var b = __require("react"), x = Symbol.for("react.transitional.element"), S = Symbol.for("react.portal"), C = Symbol.for("react.fragment"), w = Symbol.for("react.strict_mode"), T = Symbol.for("react.profiler"), E = Symbol.for("react.consumer"), D = Symbol.for("react.context"), O = Symbol.for("react.forward_ref"), k = Symbol.for("react.suspense"), A = Symbol.for("react.suspense_list"), j = Symbol.for("react.memo"), M = Symbol.for("react.lazy"), N = Symbol.for("react.activity"), P = Symbol.for("react.client.reference"), F = b.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, I = Object.prototype.hasOwnProperty, L = Array.isArray, R = console.createTask ? console.createTask : function() {
422
+ var y = __require("react"), b = Symbol.for("react.transitional.element"), x = Symbol.for("react.portal"), S = Symbol.for("react.fragment"), C = Symbol.for("react.strict_mode"), T = Symbol.for("react.profiler"), E = Symbol.for("react.consumer"), D = Symbol.for("react.context"), O = Symbol.for("react.forward_ref"), k = Symbol.for("react.suspense"), A = Symbol.for("react.suspense_list"), j = Symbol.for("react.memo"), M = Symbol.for("react.lazy"), N = Symbol.for("react.activity"), P = Symbol.for("react.client.reference"), F = y.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, I = Object.prototype.hasOwnProperty, L = Array.isArray, R = console.createTask ? console.createTask : function() {
414
423
  return null;
415
424
  };
416
- b = { react_stack_bottom_frame: function(t) {
425
+ y = { react_stack_bottom_frame: function(t) {
417
426
  return t();
418
427
  } };
419
- var z, B = {}, V = b.react_stack_bottom_frame.bind(b, u)(), H = R(c(u)), U = {};
420
- t.Fragment = C, t.jsx = function(t, n, i) {
428
+ var z, B = {}, V = y.react_stack_bottom_frame.bind(y, u)(), H = R(c(u)), U = {};
429
+ t.Fragment = S, t.jsx = function(t, n, i) {
421
430
  var s = 1e4 > F.recentlyCreatedOwnerStacks++;
422
- return _(t, n, i, !1, s ? Error("react-stack-top-frame") : V, s ? R(c(t)) : H);
431
+ return g(t, n, i, !1, s ? Error("react-stack-top-frame") : V, s ? R(c(t)) : H);
423
432
  }, t.jsxs = function(t, n, i) {
424
433
  var s = 1e4 > F.recentlyCreatedOwnerStacks++;
425
- return _(t, n, i, !0, s ? Error("react-stack-top-frame") : V, s ? R(c(t)) : H);
434
+ return g(t, n, i, !0, s ? Error("react-stack-top-frame") : V, s ? R(c(t)) : H);
426
435
  };
427
436
  })();
428
- })), import_jsx_runtime = (/* @__PURE__ */ __commonJSMin(((t, n) => {
437
+ })), import_jsx_runtime = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMin(((t, n) => {
429
438
  process.env.NODE_ENV === "production" ? n.exports = require_react_jsx_runtime_production() : n.exports = require_react_jsx_runtime_development();
430
- })))();
439
+ })))());
431
440
  const AvatarRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
432
441
  let { className: s, render: c, ...l } = n, [u, d] = React.useState("idle"), f = React.useMemo(() => ({ imageLoadingStatus: u }), [u]), m = React.useMemo(() => ({
433
442
  imageLoadingStatus: u,
@@ -966,7 +975,7 @@ var concatArrays = (t, n) => {
966
975
  isNumber,
967
976
  isArbitraryVariable,
968
977
  isArbitraryValue
969
- ], fh = () => [
978
+ ], $ = () => [
970
979
  isFraction,
971
980
  "full",
972
981
  ...k()
@@ -1848,10 +1857,10 @@ var concatArrays = (t, n) => {
1848
1857
  ] }],
1849
1858
  "transform-origin": [{ origin: E() }],
1850
1859
  "transform-style": [{ transform: ["3d", "flat"] }],
1851
- translate: [{ translate: fh() }],
1852
- "translate-x": [{ "translate-x": fh() }],
1853
- "translate-y": [{ "translate-y": fh() }],
1854
- "translate-z": [{ "translate-z": fh() }],
1860
+ translate: [{ translate: $() }],
1861
+ "translate-x": [{ "translate-x": $() }],
1862
+ "translate-y": [{ "translate-y": $() }],
1863
+ "translate-z": [{ "translate-z": $() }],
1855
1864
  "translate-none": ["translate-none"],
1856
1865
  accent: [{ accent: z() }],
1857
1866
  appearance: [{ appearance: ["none", "auto"] }],
@@ -2161,40 +2170,40 @@ const Avatar = (t) => {
2161
2170
  let n = (0, import_compiler_runtime$31.c)(12), i, s, c, l;
2162
2171
  n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4]) : ({className: s, children: i, ref: l, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l);
2163
2172
  let u;
2164
- n[5] === s ? u = n[6] : (u = cn("inline-flex size-xl items-center justify-center overflow-hidden rounded-full bg-surface-container align-middle font-medium select-none raised-2", s), n[5] = s, n[6] = u);
2173
+ n[5] === s ? u = n[6] : (u = cn("raised-2 inline-flex size-xl select-none items-center justify-center overflow-hidden rounded-full bg-surface-container align-middle font-medium", s), n[5] = s, n[6] = u);
2165
2174
  let d;
2166
2175
  return n[7] !== i || n[8] !== c || n[9] !== l || n[10] !== u ? (d = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AvatarRoot, {
2167
- "data-slot": "avatar",
2168
2176
  className: u,
2177
+ "data-slot": "avatar",
2169
2178
  ref: l,
2170
2179
  ...c,
2171
2180
  children: i
2172
2181
  }), n[7] = i, n[8] = c, n[9] = l, n[10] = u, n[11] = d) : d = n[11], d;
2173
2182
  };
2174
2183
  var import_compiler_runtime$30 = require_compiler_runtime();
2175
- const AvatarImage = (t) => {
2184
+ const AvatarFallback = (t) => {
2176
2185
  let n = (0, import_compiler_runtime$30.c)(10), i, s, c;
2177
2186
  n[0] === t ? (i = n[1], s = n[2], c = n[3]) : ({className: i, ref: c, ...s} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c);
2178
2187
  let l;
2179
- n[4] === i ? l = n[5] : (l = cn("size-full object-cover", i), n[4] = i, n[5] = l);
2188
+ n[4] === i ? l = n[5] : (l = cn("flex size-full items-center justify-center", i), n[4] = i, n[5] = l);
2180
2189
  let u;
2181
- return n[6] !== s || n[7] !== c || n[8] !== l ? (u = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AvatarImage$1, {
2182
- "data-slot": "avatar-image",
2190
+ return n[6] !== s || n[7] !== c || n[8] !== l ? (u = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AvatarFallback$1, {
2183
2191
  className: l,
2192
+ "data-slot": "avatar-fallback",
2184
2193
  ref: c,
2185
2194
  ...s
2186
2195
  }), n[6] = s, n[7] = c, n[8] = l, n[9] = u) : u = n[9], u;
2187
2196
  };
2188
2197
  var import_compiler_runtime$29 = require_compiler_runtime();
2189
- const AvatarFallback = (t) => {
2198
+ const AvatarImage = (t) => {
2190
2199
  let n = (0, import_compiler_runtime$29.c)(10), i, s, c;
2191
2200
  n[0] === t ? (i = n[1], s = n[2], c = n[3]) : ({className: i, ref: c, ...s} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c);
2192
2201
  let l;
2193
- n[4] === i ? l = n[5] : (l = cn("flex size-full items-center justify-center", i), n[4] = i, n[5] = l);
2202
+ n[4] === i ? l = n[5] : (l = cn("size-full object-cover", i), n[4] = i, n[5] = l);
2194
2203
  let u;
2195
- return n[6] !== s || n[7] !== c || n[8] !== l ? (u = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AvatarFallback$1, {
2196
- "data-slot": "avatar-fallback",
2204
+ return n[6] !== s || n[7] !== c || n[8] !== l ? (u = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AvatarImage$1, {
2197
2205
  className: l,
2206
+ "data-slot": "avatar-image",
2198
2207
  ref: c,
2199
2208
  ...s
2200
2209
  }), n[6] = s, n[7] = c, n[8] = l, n[9] = u) : u = n[9], u;
@@ -3363,54 +3372,54 @@ function useValueChanged(n, i) {
3363
3372
  }, [n]);
3364
3373
  }
3365
3374
  const CheckboxRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
3366
- let { checked: s, className: c, defaultChecked: l = !1, disabled: u = !1, id: d, indeterminate: f = !1, inputRef: m, name: h, onCheckedChange: g, parent: _ = !1, readOnly: v = !1, render: y, required: b = !1, uncheckedValue: x, value: S, nativeButton: w = !1, ...T } = n, { clearErrors: E } = useFormContext(), { disabled: D, name: O, setDirty: k, setFilled: A, setFocused: j, setTouched: M, state: N, validationMode: P, validityData: F, shouldValidateOnChange: I, validation: R } = useFieldRootContext(), z = useFieldItemContext(), { labelId: B, controlId: V, setControlId: H, getDescriptionProps: U } = useLabelableContext(), W = useCheckboxGroupContext(), G = W?.parent, K = G && W.allValues, q = D || z.disabled || W?.disabled || u, Y = O ?? h, Z = S ?? Y, Q = useBaseUiId(), fh = useBaseUiId(), $ = V;
3367
- K ? $ = _ ? fh : `${G.id}-${Z}` : d && ($ = d);
3368
- let mh = {};
3369
- K && (_ ? mh = W.parent.getParentProps() : Z && (mh = W.parent.getChildProps(Z)));
3370
- let hh = useStableCallback(g), { checked: gh = s, indeterminate: _h = f, onCheckedChange: vh, ...yh } = mh, bh = W?.value, Sh = W?.setValue, Ch = W?.defaultValue, wh = React.useRef(null), { getButtonProps: Th, buttonRef: Eh } = useButton({
3375
+ let { checked: s, className: c, defaultChecked: l = !1, disabled: u = !1, id: d, indeterminate: f = !1, inputRef: m, name: h, onCheckedChange: g, parent: _ = !1, readOnly: v = !1, render: y, required: b = !1, uncheckedValue: x, value: S, nativeButton: C = !1, ...w } = n, { clearErrors: T } = useFormContext(), { disabled: E, name: D, setDirty: O, setFilled: k, setFocused: A, setTouched: M, state: N, validationMode: P, validityData: F, shouldValidateOnChange: I, validation: L } = useFieldRootContext(), R = useFieldItemContext(), { labelId: z, controlId: B, setControlId: V, getDescriptionProps: H } = useLabelableContext(), U = useCheckboxGroupContext(), W = U?.parent, K = W && U.allValues, q = E || R.disabled || U?.disabled || u, J = D ?? h, Y = S ?? J, X = useBaseUiId(), Z = useBaseUiId(), Q = B;
3376
+ K ? Q = _ ? Z : `${W.id}-${Y}` : d && (Q = d);
3377
+ let $ = {};
3378
+ K && (_ ? $ = U.parent.getParentProps() : Y && ($ = U.parent.getChildProps(Y)));
3379
+ let yh = useStableCallback(g), { checked: bh = s, indeterminate: Sh = f, onCheckedChange: wh, ...Th } = $, Eh = U?.value, Oh = U?.setValue, kh = U?.defaultValue, Ah = React.useRef(null), { getButtonProps: jh, buttonRef: Mh } = useButton({
3371
3380
  disabled: q,
3372
- native: w
3373
- }), Dh = W?.validation ?? R, [Oh, kh] = useControlled({
3374
- controlled: Z && bh && !_ ? bh.includes(Z) : gh,
3375
- default: Z && Ch && !_ ? Ch.includes(Z) : l,
3381
+ native: C
3382
+ }), Nh = U?.validation ?? L, [Ph, Fh] = useControlled({
3383
+ controlled: Y && Eh && !_ ? Eh.includes(Y) : bh,
3384
+ default: Y && kh && !_ ? kh.includes(Y) : l,
3376
3385
  name: "Checkbox",
3377
3386
  state: "checked"
3378
3387
  });
3379
3388
  useIsoLayoutEffect(() => {
3380
- if (H !== NOOP) return H($), () => {
3381
- H(void 0);
3389
+ if (V !== NOOP) return V(Q), () => {
3390
+ V(void 0);
3382
3391
  };
3383
3392
  }, [
3384
- $,
3385
- W,
3386
- H,
3393
+ Q,
3394
+ U,
3395
+ V,
3387
3396
  _
3388
3397
  ]), useField({
3389
- enabled: !W,
3390
- id: Q,
3391
- commit: Dh.commit,
3392
- value: Oh,
3393
- controlRef: wh,
3394
- name: Y,
3395
- getValue: () => Oh
3398
+ enabled: !U,
3399
+ id: X,
3400
+ commit: Nh.commit,
3401
+ value: Ph,
3402
+ controlRef: Ah,
3403
+ name: J,
3404
+ getValue: () => Ph
3396
3405
  });
3397
- let Ah = React.useRef(null), jh = useMergedRefs(m, Ah, Dh.inputRef);
3406
+ let Lh = React.useRef(null), Rh = useMergedRefs(m, Lh, Nh.inputRef);
3398
3407
  useIsoLayoutEffect(() => {
3399
- Ah.current && (Ah.current.indeterminate = _h, Oh && A(!0));
3408
+ Lh.current && (Lh.current.indeterminate = Sh, Ph && k(!0));
3400
3409
  }, [
3401
- Oh,
3402
- _h,
3403
- A
3404
- ]), useValueChanged(Oh, () => {
3405
- W && !_ || (E(Y), A(Oh), k(Oh !== F.initialValue), I() ? Dh.commit(Oh) : Dh.commit(Oh, !0));
3410
+ Ph,
3411
+ Sh,
3412
+ k
3413
+ ]), useValueChanged(Ph, () => {
3414
+ U && !_ || (T(J), k(Ph), O(Ph !== F.initialValue), I() ? Nh.commit(Ph) : Nh.commit(Ph, !0));
3406
3415
  });
3407
- let Mh = mergeProps({
3408
- checked: Oh,
3416
+ let zh = mergeProps({
3417
+ checked: Ph,
3409
3418
  disabled: q,
3410
- name: _ ? void 0 : Y,
3411
- id: $ ?? void 0,
3419
+ name: _ ? void 0 : J,
3420
+ id: Q ?? void 0,
3412
3421
  required: b,
3413
- ref: jh,
3422
+ ref: Rh,
3414
3423
  style: visuallyHidden,
3415
3424
  tabIndex: -1,
3416
3425
  type: "checkbox",
@@ -3418,79 +3427,79 @@ const CheckboxRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
3418
3427
  onChange(t) {
3419
3428
  if (t.nativeEvent.defaultPrevented) return;
3420
3429
  let n = t.target.checked, i = createChangeEventDetails(none, t.nativeEvent);
3421
- vh?.(n, i), hh(n, i), !i.isCanceled && (kh(n), Z && bh && Sh && !_ && Sh(n ? [...bh, Z] : bh.filter((t) => t !== Z), i));
3430
+ wh?.(n, i), yh(n, i), !i.isCanceled && (Fh(n), Y && Eh && Oh && !_ && Oh(n ? [...Eh, Y] : Eh.filter((t) => t !== Y), i));
3422
3431
  },
3423
3432
  onFocus() {
3424
- wh.current?.focus();
3433
+ Ah.current?.focus();
3425
3434
  }
3426
- }, S === void 0 ? EMPTY_OBJECT : { value: (W ? Oh && S : S) || "" }, U, W ? Dh.getValidationProps : Dh.getInputValidationProps), Nh = K ? !!gh : Oh, Ph = K && _h || f;
3435
+ }, S === void 0 ? EMPTY_OBJECT : { value: (U ? Ph && S : S) || "" }, H, U ? Nh.getValidationProps : Nh.getInputValidationProps), Bh = K ? !!bh : Ph, Vh = K && Sh || f;
3427
3436
  React.useEffect(() => {
3428
- G && Z && G.disabledStatesRef.current.set(Z, q);
3437
+ W && Y && W.disabledStatesRef.current.set(Y, q);
3429
3438
  }, [
3430
- G,
3439
+ W,
3431
3440
  q,
3432
- Z
3441
+ Y
3433
3442
  ]);
3434
- let Fh = React.useMemo(() => ({
3443
+ let Hh = React.useMemo(() => ({
3435
3444
  ...N,
3436
- checked: Nh,
3445
+ checked: Bh,
3437
3446
  disabled: q,
3438
3447
  readOnly: v,
3439
3448
  required: b,
3440
- indeterminate: Ph
3449
+ indeterminate: Vh
3441
3450
  }), [
3442
3451
  N,
3443
- Nh,
3452
+ Bh,
3444
3453
  q,
3445
3454
  v,
3446
3455
  b,
3447
- Ph
3448
- ]), Ih = useStateAttributesMapping(Fh), Lh = useRenderElement("span", n, {
3449
- state: Fh,
3456
+ Vh
3457
+ ]), Uh = useStateAttributesMapping(Hh), Wh = useRenderElement("span", n, {
3458
+ state: Hh,
3450
3459
  ref: [
3451
- Eh,
3452
- wh,
3460
+ Mh,
3461
+ Ah,
3453
3462
  i,
3454
- W?.registerControlRef
3463
+ U?.registerControlRef
3455
3464
  ],
3456
3465
  props: [
3457
3466
  {
3458
- id: Q,
3467
+ id: X,
3459
3468
  role: "checkbox",
3460
- "aria-checked": _h ? "mixed" : Oh,
3469
+ "aria-checked": Sh ? "mixed" : Ph,
3461
3470
  "aria-readonly": v || void 0,
3462
3471
  "aria-required": b || void 0,
3463
- "aria-labelledby": B,
3472
+ "aria-labelledby": z,
3464
3473
  "data-parent": _ ? "" : void 0,
3465
3474
  onFocus() {
3466
- j(!0);
3475
+ A(!0);
3467
3476
  },
3468
3477
  onBlur() {
3469
- let t = Ah.current;
3470
- t && (M(!0), j(!1), P === "onBlur" && Dh.commit(W ? bh : t.checked));
3478
+ let t = Lh.current;
3479
+ t && (M(!0), A(!1), P === "onBlur" && Nh.commit(U ? Eh : t.checked));
3471
3480
  },
3472
3481
  onClick(t) {
3473
- v || q || (t.preventDefault(), Ah.current?.click());
3482
+ v || q || (t.preventDefault(), Lh.current?.click());
3474
3483
  }
3475
3484
  },
3476
- U,
3477
- Dh.getValidationProps,
3478
- T,
3479
- yh,
3480
- Th
3485
+ H,
3486
+ Nh.getValidationProps,
3487
+ w,
3488
+ Th,
3489
+ jh
3481
3490
  ],
3482
- stateAttributesMapping: Ih
3491
+ stateAttributesMapping: Uh
3483
3492
  });
3484
3493
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(CheckboxRootContext.Provider, {
3485
- value: Fh,
3494
+ value: Hh,
3486
3495
  children: [
3487
- Lh,
3488
- !Oh && !W && Y && !_ && x !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("input", {
3496
+ Wh,
3497
+ !Ph && !U && J && !_ && x !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("input", {
3489
3498
  type: "hidden",
3490
- name: Y,
3499
+ name: J,
3491
3500
  value: x
3492
3501
  }),
3493
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("input", { ...Mh })
3502
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("input", { ...zh })
3494
3503
  ]
3495
3504
  });
3496
3505
  });
@@ -3669,18 +3678,6 @@ const transitionStatusMapping = { transitionStatus(t) {
3669
3678
  return b ? x : null;
3670
3679
  });
3671
3680
  process.env.NODE_ENV !== "production" && (CheckboxIndicator$1.displayName = "CheckboxIndicator");
3672
- var import_compiler_runtime$26 = require_compiler_runtime();
3673
- const CheckboxIndicator = (t) => {
3674
- let n = (0, import_compiler_runtime$26.c)(8), i, s;
3675
- n[0] === t ? (i = n[1], s = n[2]) : ({className: i, ...s} = t, n[0] = t, n[1] = i, n[2] = s);
3676
- let c;
3677
- n[3] === i ? c = n[4] : (c = cn("flex", i), n[3] = i, n[4] = c);
3678
- let l;
3679
- return n[5] !== s || n[6] !== c ? (l = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CheckboxIndicator$1, {
3680
- className: c,
3681
- ...s
3682
- }), n[5] = s, n[6] = c, n[7] = l) : l = n[7], l;
3683
- };
3684
3681
  var a$2 = /* @__PURE__ */ new Map([
3685
3682
  ["bold", /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement("path", { d: "M216.49,168.49a12,12,0,0,1-17,0L128,97,56.49,168.49a12,12,0,0,1-17-17l80-80a12,12,0,0,1,17,0l80,80A12,12,0,0,1,216.49,168.49Z" }))],
3686
3683
  ["duotone", /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement("path", {
@@ -3749,27 +3746,39 @@ var e = React.forwardRef((n, i) => /* @__PURE__ */ React.createElement(p, {
3749
3746
  weights: a
3750
3747
  }));
3751
3748
  e.displayName = "XIcon";
3749
+ var import_compiler_runtime$26 = require_compiler_runtime();
3750
+ const CheckboxIndicator = (t) => {
3751
+ let n = (0, import_compiler_runtime$26.c)(8), i, s;
3752
+ n[0] === t ? (i = n[1], s = n[2]) : ({className: i, ...s} = t, n[0] = t, n[1] = i, n[2] = s);
3753
+ let c;
3754
+ n[3] === i ? c = n[4] : (c = cn("flex", i), n[3] = i, n[4] = c);
3755
+ let l;
3756
+ return n[5] !== s || n[6] !== c ? (l = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CheckboxIndicator$1, {
3757
+ className: c,
3758
+ ...s
3759
+ }), n[5] = s, n[6] = c, n[7] = l) : l = n[7], l;
3760
+ };
3752
3761
  var import_compiler_runtime$25 = require_compiler_runtime();
3753
3762
  const Checkbox = (t) => {
3754
3763
  let n = (0, import_compiler_runtime$25.c)(23), i, s, c, l, u, d;
3755
3764
  n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4], u = n[5], d = n[6]) : ({className: i, ref: d, label: l, id: c, disabled: s, ...u} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l, n[5] = u, n[6] = d);
3756
3765
  let f;
3757
- n[7] === i ? f = n[8] : (f = cn("flex size-md items-center text-on-accent justify-center rounded-sm bg-surface-dim inset-shadow-1-shadow data-checked:bg-accent data-checked:raised-1 hover:cursor-pointer transition-colors hover:disabled:cursor-not-allowed", i), n[7] = i, n[8] = f);
3766
+ n[7] === i ? f = n[8] : (f = cn("data-checked:raised-1 inset-shadow-1-shadow flex size-md items-center justify-center rounded-sm bg-surface-dim text-on-accent transition-colors hover:cursor-pointer hover:disabled:cursor-not-allowed data-checked:bg-accent", i), n[7] = i, n[8] = f);
3758
3767
  let m;
3759
3768
  n[9] === Symbol.for("react.memo_cache_sentinel") ? (m = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CheckboxIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(o$1, { weight: "bold" }) }), n[9] = m) : m = n[9];
3760
3769
  let h;
3761
3770
  n[10] !== s || n[11] !== c || n[12] !== u || n[13] !== d || n[14] !== f ? (h = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CheckboxRoot, {
3762
- id: c,
3763
- disabled: s,
3764
3771
  className: f,
3772
+ disabled: s,
3773
+ id: c,
3765
3774
  ref: d,
3766
3775
  ...u,
3767
3776
  children: m
3768
3777
  }), n[10] = s, n[11] = c, n[12] = u, n[13] = d, n[14] = f, n[15] = h) : h = n[15];
3769
3778
  let g;
3770
3779
  n[16] !== s || n[17] !== c || n[18] !== l ? (g = l && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", {
3780
+ className: cn("body-base cursor-pointer", s && "cursor-not-allowed text-text-neutral-primary-disabled"),
3771
3781
  htmlFor: c,
3772
- className: cn("body-base cursor-pointer", s && "text-text-neutral-primary-disabled cursor-not-allowed"),
3773
3782
  children: l
3774
3783
  }), n[16] = s, n[17] = c, n[18] = l, n[19] = g) : g = n[19];
3775
3784
  let _;
@@ -4738,7 +4747,7 @@ function handleTabIndex(t, n) {
4738
4747
  n.current.includes("floating") || s.length === 0 ? c !== "0" && t.setAttribute("tabindex", "0") : (c !== "-1" || t.hasAttribute("data-tabindex") && t.getAttribute("data-tabindex") !== "-1") && (t.setAttribute("tabindex", "-1"), t.setAttribute("data-tabindex", "-1"));
4739
4748
  }
4740
4749
  function FloatingFocusManager(n) {
4741
- let { context: i, children: s, disabled: c = !1, order: l = ["content"], initialFocus: u = !0, returnFocus: d = !0, restoreFocus: f = !1, modal: m = !0, closeOnFocusOut: h = !0, openInteractionType: g = "", getInsideElements: _ = () => [], nextFocusableElement: v, previousFocusableElement: y, beforeContentFocusGuardRef: b, externalTree: x } = n, S = "rootStore" in i ? i.rootStore : i, w = S.useState("open"), T = S.useState("domReferenceElement"), E = S.useState("floatingElement"), { events: D, dataRef: O } = S.context, k = useStableCallback(() => O.current.floatingContext?.nodeId), A = useStableCallback(_), j = u === !1, M = isTypeableCombobox(T) && j, N = useValueAsRef(l), P = useValueAsRef(u), F = useValueAsRef(d), I = useValueAsRef(g), L = useFloatingTree(x), R = usePortalContext(), z = React.useRef(null), B = React.useRef(null), V = React.useRef(!1), H = React.useRef(!1), U = React.useRef(!1), W = React.useRef(-1), G = React.useRef(""), K = React.useRef(""), q = useTimeout(), J = useTimeout(), Y = useAnimationFrame(), X = R != null, Z = getFloatingFocusElement(E), Q = useStableCallback((t = Z) => t ? tabbable(t, getTabbableOptions()) : []), fh = useStableCallback((t) => {
4750
+ let { context: i, children: s, disabled: c = !1, order: l = ["content"], initialFocus: u = !0, returnFocus: d = !0, restoreFocus: f = !1, modal: m = !0, closeOnFocusOut: h = !0, openInteractionType: g = "", getInsideElements: _ = () => [], nextFocusableElement: v, previousFocusableElement: y, beforeContentFocusGuardRef: b, externalTree: x } = n, S = "rootStore" in i ? i.rootStore : i, C = S.useState("open"), w = S.useState("domReferenceElement"), T = S.useState("floatingElement"), { events: E, dataRef: D } = S.context, O = useStableCallback(() => D.current.floatingContext?.nodeId), k = useStableCallback(_), A = u === !1, M = isTypeableCombobox(w) && A, N = useValueAsRef(l), P = useValueAsRef(u), F = useValueAsRef(d), I = useValueAsRef(g), L = useFloatingTree(x), R = usePortalContext(), z = React.useRef(null), B = React.useRef(null), V = React.useRef(!1), H = React.useRef(!1), U = React.useRef(!1), W = React.useRef(-1), G = React.useRef(""), K = React.useRef(""), q = useTimeout(), J = useTimeout(), Y = useAnimationFrame(), X = R != null, Z = getFloatingFocusElement(T), Q = useStableCallback((t = Z) => t ? tabbable(t, getTabbableOptions()) : []), $ = useStableCallback((t) => {
4742
4751
  let n = Q(t);
4743
4752
  return N.current.map(() => n).filter(Boolean).flat();
4744
4753
  });
@@ -4753,35 +4762,35 @@ function FloatingFocusManager(n) {
4753
4762
  };
4754
4763
  }, [
4755
4764
  c,
4756
- T,
4765
+ w,
4757
4766
  Z,
4758
4767
  m,
4759
4768
  N,
4760
4769
  M,
4761
4770
  Q,
4762
- fh
4771
+ $
4763
4772
  ]), React.useEffect(() => {
4764
- if (c || !E) return;
4773
+ if (c || !T) return;
4765
4774
  function t(t) {
4766
4775
  let n = getTarget(t), i = Q().indexOf(n);
4767
4776
  i !== -1 && (W.current = i);
4768
4777
  }
4769
- return E.addEventListener("focusin", t), () => {
4770
- E.removeEventListener("focusin", t);
4778
+ return T.addEventListener("focusin", t), () => {
4779
+ T.removeEventListener("focusin", t);
4771
4780
  };
4772
4781
  }, [
4773
4782
  c,
4774
- E,
4783
+ T,
4775
4784
  Q
4776
4785
  ]), React.useEffect(() => {
4777
- if (c || !w) return;
4786
+ if (c || !C) return;
4778
4787
  let t = getDocument(Z);
4779
4788
  function n() {
4780
4789
  U.current = !1;
4781
4790
  }
4782
4791
  function i(t) {
4783
4792
  let n = getTarget(t);
4784
- U.current = !(contains(E, n) || contains(T, n) || contains(R?.portalNode, n)), K.current = t.pointerType || "keyboard";
4793
+ U.current = !(contains(T, n) || contains(w, n) || contains(R?.portalNode, n)), K.current = t.pointerType || "keyboard";
4785
4794
  }
4786
4795
  function s() {
4787
4796
  K.current = "keyboard";
@@ -4791,10 +4800,10 @@ function FloatingFocusManager(n) {
4791
4800
  };
4792
4801
  }, [
4793
4802
  c,
4794
- E,
4795
4803
  T,
4796
- Z,
4797
4804
  w,
4805
+ Z,
4806
+ C,
4798
4807
  R
4799
4808
  ]), React.useEffect(() => {
4800
4809
  if (c || !h) return;
@@ -4806,8 +4815,8 @@ function FloatingFocusManager(n) {
4806
4815
  function n(t) {
4807
4816
  let n = t.relatedTarget, i = t.currentTarget, s = getTarget(t);
4808
4817
  queueMicrotask(() => {
4809
- let c = k(), l = S.context.triggerElements, u = !(contains(T, n) || contains(E, n) || contains(n, E) || contains(R?.portalNode, n) || n != null && l.hasElement(n) || l.hasMatchingElement((t) => contains(t, n)) || n?.hasAttribute(createAttribute("focus-guard")) || L && (getNodeChildren(L.nodesRef.current, c).find((t) => contains(t.context?.elements.floating, n) || contains(t.context?.elements.domReference, n)) || getNodeAncestors(L.nodesRef.current, c).find((t) => [t.context?.elements.floating, getFloatingFocusElement(t.context?.elements.floating)].includes(n) || t.context?.elements.domReference === n)));
4810
- if (i === T && Z && handleTabIndex(Z, N), f && i !== T && !isFocusable(s) && activeElement(getDocument(Z)) === getDocument(Z).body) {
4818
+ let c = O(), l = S.context.triggerElements, u = !(contains(w, n) || contains(T, n) || contains(n, T) || contains(R?.portalNode, n) || n != null && l.hasElement(n) || l.hasMatchingElement((t) => contains(t, n)) || n?.hasAttribute(createAttribute("focus-guard")) || L && (getNodeChildren(L.nodesRef.current, c).find((t) => contains(t.context?.elements.floating, n) || contains(t.context?.elements.domReference, n)) || getNodeAncestors(L.nodesRef.current, c).find((t) => [t.context?.elements.floating, getFloatingFocusElement(t.context?.elements.floating)].includes(n) || t.context?.elements.domReference === n)));
4819
+ if (i === w && Z && handleTabIndex(Z, N), f && i !== w && !isFocusable(s) && activeElement(getDocument(Z)) === getDocument(Z).body) {
4811
4820
  if (isHTMLElement(Z) && (Z.focus(), f === "popup")) {
4812
4821
  Y.request(() => {
4813
4822
  Z.focus();
@@ -4817,25 +4826,25 @@ function FloatingFocusManager(n) {
4817
4826
  let t = W.current, n = Q(), i = n[t] || n[n.length - 1] || Z;
4818
4827
  isHTMLElement(i) && i.focus();
4819
4828
  }
4820
- if (O.current.insideReactTree) {
4821
- O.current.insideReactTree = !1;
4829
+ if (D.current.insideReactTree) {
4830
+ D.current.insideReactTree = !1;
4822
4831
  return;
4823
4832
  }
4824
4833
  (M || !m) && n && u && !H.current && (M || n !== getPreviouslyFocusedElement()) && (V.current = !0, S.setOpen(!1, createChangeEventDetails("focus-out", t)));
4825
4834
  });
4826
4835
  }
4827
4836
  function i() {
4828
- U.current || (O.current.insideReactTree = !0, q.start(0, () => {
4829
- O.current.insideReactTree = !1;
4837
+ U.current || (D.current.insideReactTree = !0, q.start(0, () => {
4838
+ D.current.insideReactTree = !1;
4830
4839
  }));
4831
4840
  }
4832
- let s = isHTMLElement(T) ? T : null, l = [];
4833
- if (!(!E && !s)) return s && (s.addEventListener("focusout", n), s.addEventListener("pointerdown", t), l.push(() => {
4841
+ let s = isHTMLElement(w) ? w : null, l = [];
4842
+ if (!(!T && !s)) return s && (s.addEventListener("focusout", n), s.addEventListener("pointerdown", t), l.push(() => {
4834
4843
  s.removeEventListener("focusout", n), s.removeEventListener("pointerdown", t);
4835
- })), E && (E.addEventListener("focusout", n), R && (E.addEventListener("focusout", i, !0), l.push(() => {
4836
- E.removeEventListener("focusout", i, !0);
4844
+ })), T && (T.addEventListener("focusout", n), R && (T.addEventListener("focusout", i, !0), l.push(() => {
4845
+ T.removeEventListener("focusout", i, !0);
4837
4846
  })), l.push(() => {
4838
- E.removeEventListener("focusout", n);
4847
+ T.removeEventListener("focusout", n);
4839
4848
  })), () => {
4840
4849
  l.forEach((t) => {
4841
4850
  t();
@@ -4843,8 +4852,8 @@ function FloatingFocusManager(n) {
4843
4852
  };
4844
4853
  }, [
4845
4854
  c,
4855
+ w,
4846
4856
  T,
4847
- E,
4848
4857
  Z,
4849
4858
  m,
4850
4859
  L,
@@ -4854,63 +4863,63 @@ function FloatingFocusManager(n) {
4854
4863
  f,
4855
4864
  Q,
4856
4865
  M,
4857
- k,
4858
- N,
4859
4866
  O,
4867
+ N,
4868
+ D,
4860
4869
  q,
4861
4870
  J,
4862
4871
  Y
4863
4872
  ]);
4864
- let ph = React.useRef(null), $ = React.useRef(null), mh = useMergedRefs(ph, b, R?.beforeInsideRef), hh = useMergedRefs($, R?.afterInsideRef);
4873
+ let yh = React.useRef(null), bh = React.useRef(null), xh = useMergedRefs(yh, b, R?.beforeInsideRef), Sh = useMergedRefs(bh, R?.afterInsideRef);
4865
4874
  React.useEffect(() => {
4866
- if (c || !E || !w) return;
4875
+ if (c || !T || !C) return;
4867
4876
  let t = Array.from(R?.portalNode?.querySelectorAll(`[${createAttribute("portal")}]`) || []), n = markOthers([
4868
- E,
4869
- (L ? getNodeAncestors(L.nodesRef.current, k()) : []).find((t) => isTypeableCombobox(t.context?.elements.domReference || null))?.context?.elements.domReference,
4877
+ T,
4878
+ (L ? getNodeAncestors(L.nodesRef.current, O()) : []).find((t) => isTypeableCombobox(t.context?.elements.domReference || null))?.context?.elements.domReference,
4870
4879
  ...t,
4871
- ...A(),
4880
+ ...k(),
4872
4881
  z.current,
4873
4882
  B.current,
4874
- ph.current,
4875
- $.current,
4883
+ yh.current,
4884
+ bh.current,
4876
4885
  R?.beforeOutsideRef.current,
4877
4886
  R?.afterOutsideRef.current,
4878
4887
  resolveRef(y),
4879
4888
  resolveRef(v),
4880
- M ? T : null
4889
+ M ? w : null
4881
4890
  ].filter((t) => t != null), m || M);
4882
4891
  return () => {
4883
4892
  n();
4884
4893
  };
4885
4894
  }, [
4886
- w,
4895
+ C,
4887
4896
  c,
4897
+ w,
4888
4898
  T,
4889
- E,
4890
4899
  m,
4891
4900
  N,
4892
4901
  R,
4893
4902
  M,
4894
4903
  L,
4904
+ O,
4895
4905
  k,
4896
- A,
4897
4906
  v,
4898
4907
  y
4899
4908
  ]), useIsoLayoutEffect(() => {
4900
- if (!w || c || !isHTMLElement(Z)) return;
4909
+ if (!C || c || !isHTMLElement(Z)) return;
4901
4910
  let t = activeElement(getDocument(Z));
4902
4911
  queueMicrotask(() => {
4903
- let n = fh(Z), i = P.current, s = typeof i == "function" ? i(I.current || "") : i;
4912
+ let n = $(Z), i = P.current, s = typeof i == "function" ? i(I.current || "") : i;
4904
4913
  if (s === void 0 || s === !1) return;
4905
4914
  let c;
4906
4915
  c = s === !0 || s === null ? n[0] || Z : resolveRef(s), c = c || n[0] || Z, !contains(Z, t) && enqueueFocus(c, { preventScroll: c === Z });
4907
4916
  });
4908
4917
  }, [
4909
4918
  c,
4910
- w,
4919
+ C,
4911
4920
  Z,
4912
- j,
4913
- fh,
4921
+ A,
4922
+ $,
4914
4923
  P,
4915
4924
  I
4916
4925
  ]), useIsoLayoutEffect(() => {
@@ -4927,22 +4936,22 @@ function FloatingFocusManager(n) {
4927
4936
  } }), t ? V.current = !1 : V.current = !0;
4928
4937
  }
4929
4938
  }
4930
- D.on("openchange", n);
4939
+ E.on("openchange", n);
4931
4940
  let i = t.createElement("span");
4932
- i.setAttribute("tabindex", "-1"), i.setAttribute("aria-hidden", "true"), Object.assign(i.style, visuallyHidden), X && T && T.insertAdjacentElement("afterend", i);
4941
+ i.setAttribute("tabindex", "-1"), i.setAttribute("aria-hidden", "true"), Object.assign(i.style, visuallyHidden), X && w && w.insertAdjacentElement("afterend", i);
4933
4942
  function s() {
4934
4943
  let t = F.current, n = typeof t == "function" ? t(G.current) : t;
4935
4944
  if (n === void 0 || n === !1) return null;
4936
4945
  if (n === null && (n = !0), typeof n == "boolean") {
4937
- let t = T || getPreviouslyFocusedElement();
4946
+ let t = w || getPreviouslyFocusedElement();
4938
4947
  return t && t.isConnected ? t : i;
4939
4948
  }
4940
- let s = T || getPreviouslyFocusedElement() || i;
4949
+ let s = w || getPreviouslyFocusedElement() || i;
4941
4950
  return resolveRef(n) || s;
4942
4951
  }
4943
4952
  return () => {
4944
- D.off("openchange", n);
4945
- let c = activeElement(t), l = contains(E, c) || L && getNodeChildren(L.nodesRef.current, k(), !1).some((t) => contains(t.context?.elements.floating, c)), u = s();
4953
+ E.off("openchange", n);
4954
+ let c = activeElement(t), l = contains(T, c) || L && getNodeChildren(L.nodesRef.current, O(), !1).some((t) => contains(t.context?.elements.floating, c)), u = s();
4946
4955
  queueMicrotask(() => {
4947
4956
  let n = getFirstTabbableElement(u), s = typeof F.current != "boolean";
4948
4957
  F.current && !V.current && isHTMLElement(n) && (!(!s && n !== c && c !== t.body) || l) && n.focus({ preventScroll: !0 }), i.remove();
@@ -4950,21 +4959,21 @@ function FloatingFocusManager(n) {
4950
4959
  };
4951
4960
  }, [
4952
4961
  c,
4953
- E,
4962
+ T,
4954
4963
  Z,
4955
4964
  F,
4956
- O,
4957
4965
  D,
4966
+ E,
4958
4967
  L,
4959
4968
  X,
4960
- T,
4961
- k
4969
+ w,
4970
+ O
4962
4971
  ]), React.useEffect(() => {
4963
4972
  queueMicrotask(() => {
4964
4973
  V.current = !1;
4965
4974
  });
4966
4975
  }, [c]), React.useEffect(() => {
4967
- if (c || !w) return;
4976
+ if (c || !C) return;
4968
4977
  function t(t) {
4969
4978
  getTarget(t)?.closest("[data-base-ui-click-trigger]") && (H.current = !0);
4970
4979
  }
@@ -4974,15 +4983,15 @@ function FloatingFocusManager(n) {
4974
4983
  };
4975
4984
  }, [
4976
4985
  c,
4977
- w,
4986
+ C,
4978
4987
  Z
4979
4988
  ]), useIsoLayoutEffect(() => {
4980
4989
  if (!c && R) return R.setFocusManagerState({
4981
4990
  modal: m,
4982
4991
  closeOnFocusOut: h,
4983
- open: w,
4992
+ open: C,
4984
4993
  onOpenChange: S.setOpen,
4985
- domReference: T
4994
+ domReference: w
4986
4995
  }), () => {
4987
4996
  R.setFocusManagerState(null);
4988
4997
  };
@@ -4990,10 +4999,10 @@ function FloatingFocusManager(n) {
4990
4999
  c,
4991
5000
  R,
4992
5001
  m,
4993
- w,
5002
+ C,
4994
5003
  S,
4995
5004
  h,
4996
- T
5005
+ w
4997
5006
  ]), useIsoLayoutEffect(() => {
4998
5007
  if (!(c || !Z)) return handleTabIndex(Z, N), () => {
4999
5008
  queueMicrotask(clearDisconnectedPreviouslyFocusedElements);
@@ -5003,24 +5012,24 @@ function FloatingFocusManager(n) {
5003
5012
  Z,
5004
5013
  N
5005
5014
  ]);
5006
- let gh = !c && (m ? !M : !0) && (X || m);
5015
+ let Ch = !c && (m ? !M : !0) && (X || m);
5007
5016
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(React.Fragment, { children: [
5008
- gh && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(FocusGuard, {
5017
+ Ch && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(FocusGuard, {
5009
5018
  "data-type": "inside",
5010
- ref: mh,
5019
+ ref: xh,
5011
5020
  onFocus: (t) => {
5012
5021
  if (m) {
5013
- let t = fh();
5022
+ let t = $();
5014
5023
  enqueueFocus(t[t.length - 1]);
5015
- } else R?.portalNode && (V.current = !1, isOutsideEvent(t, R.portalNode) ? getNextTabbable(T)?.focus() : resolveRef(y ?? R.beforeOutsideRef)?.focus());
5024
+ } else R?.portalNode && (V.current = !1, isOutsideEvent(t, R.portalNode) ? getNextTabbable(w)?.focus() : resolveRef(y ?? R.beforeOutsideRef)?.focus());
5016
5025
  }
5017
5026
  }),
5018
5027
  s,
5019
- gh && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(FocusGuard, {
5028
+ Ch && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(FocusGuard, {
5020
5029
  "data-type": "inside",
5021
- ref: hh,
5030
+ ref: Sh,
5022
5031
  onFocus: (t) => {
5023
- m ? enqueueFocus(fh()[0]) : R?.portalNode && (h && (V.current = !0), isOutsideEvent(t, R.portalNode) ? getPreviousTabbable(T)?.focus() : resolveRef(v ?? R.afterOutsideRef)?.focus());
5032
+ m ? enqueueFocus($()[0]) : R?.portalNode && (h && (V.current = !0), isOutsideEvent(t, R.portalNode) ? getPreviousTabbable(w)?.focus() : resolveRef(v ?? R.afterOutsideRef)?.focus());
5024
5033
  }
5025
5034
  })
5026
5035
  ] });
@@ -6504,34 +6513,34 @@ var require_use_sync_external_store_shim_production = /* @__PURE__ */ __commonJS
6504
6513
  function h(t, n) {
6505
6514
  return n();
6506
6515
  }
6507
- var _ = typeof window > "u" || window.document === void 0 || window.document.createElement === void 0 ? h : f;
6508
- t.useSyncExternalStore = n.useSyncExternalStore === void 0 ? _ : n.useSyncExternalStore;
6516
+ var g = typeof window > "u" || window.document === void 0 || window.document.createElement === void 0 ? h : f;
6517
+ t.useSyncExternalStore = n.useSyncExternalStore === void 0 ? g : n.useSyncExternalStore;
6509
6518
  })), require_use_sync_external_store_shim_development = /* @__PURE__ */ __commonJSMin(((t) => {
6510
6519
  process.env.NODE_ENV !== "production" && (function() {
6511
6520
  function n(t, n) {
6512
6521
  return t === n && (t !== 0 || 1 / t == 1 / n) || t !== t && n !== n;
6513
6522
  }
6514
6523
  function i(t, n) {
6515
- _ || l.startTransition === void 0 || (_ = !0, console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));
6524
+ g || l.startTransition === void 0 || (g = !0, console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));
6516
6525
  var i = n();
6517
- if (!v) {
6526
+ if (!_) {
6518
6527
  var c = n();
6519
- u(i, c) || (console.error("The result of getSnapshot should be cached to avoid an infinite loop"), v = !0);
6528
+ u(i, c) || (console.error("The result of getSnapshot should be cached to avoid an infinite loop"), _ = !0);
6520
6529
  }
6521
6530
  c = d({ inst: {
6522
6531
  value: i,
6523
6532
  getSnapshot: n
6524
6533
  } });
6525
- var g = c[0].inst, y = c[1];
6534
+ var v = c[0].inst, y = c[1];
6526
6535
  return m(function() {
6527
- g.value = i, g.getSnapshot = n, s(g) && y({ inst: g });
6536
+ v.value = i, v.getSnapshot = n, s(v) && y({ inst: v });
6528
6537
  }, [
6529
6538
  t,
6530
6539
  i,
6531
6540
  n
6532
6541
  ]), f(function() {
6533
- return s(g) && y({ inst: g }), t(function() {
6534
- s(g) && y({ inst: g });
6542
+ return s(v) && y({ inst: v }), t(function() {
6543
+ s(v) && y({ inst: v });
6535
6544
  });
6536
6545
  }, [t]), h(i), i;
6537
6546
  }
@@ -6549,8 +6558,8 @@ var require_use_sync_external_store_shim_production = /* @__PURE__ */ __commonJS
6549
6558
  return n();
6550
6559
  }
6551
6560
  typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
6552
- var l = __require("react"), u = typeof Object.is == "function" ? Object.is : n, d = l.useState, f = l.useEffect, m = l.useLayoutEffect, h = l.useDebugValue, _ = !1, v = !1, y = typeof window > "u" || window.document === void 0 || window.document.createElement === void 0 ? c : i;
6553
- t.useSyncExternalStore = l.useSyncExternalStore === void 0 ? y : l.useSyncExternalStore, typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
6561
+ var l = __require("react"), u = typeof Object.is == "function" ? Object.is : n, d = l.useState, f = l.useEffect, m = l.useLayoutEffect, h = l.useDebugValue, g = !1, _ = !1, v = typeof window > "u" || window.document === void 0 || window.document.createElement === void 0 ? c : i;
6562
+ t.useSyncExternalStore = l.useSyncExternalStore === void 0 ? v : l.useSyncExternalStore, typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
6554
6563
  })();
6555
6564
  })), require_shim = /* @__PURE__ */ __commonJSMin(((t, n) => {
6556
6565
  process.env.NODE_ENV === "production" ? n.exports = require_use_sync_external_store_shim_production() : n.exports = require_use_sync_external_store_shim_development();
@@ -8121,9 +8130,9 @@ function DialogRoot(n) {
8121
8130
  onOpenChange: l,
8122
8131
  triggerIdProp: g
8123
8132
  });
8124
- let C = React.useMemo(() => ({ store: b }), [b]);
8133
+ let S = React.useMemo(() => ({ store: b }), [b]);
8125
8134
  return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DialogRootContext.Provider, {
8126
- value: C,
8135
+ value: S,
8127
8136
  children: typeof i == "function" ? i({ payload: x }) : i
8128
8137
  });
8129
8138
  }
@@ -8138,38 +8147,45 @@ process.env.NODE_ENV !== "production" && (DialogTitle$1.displayName = "DialogTit
8138
8147
  const DialogTrigger$1 = /* @__PURE__ */ React.forwardRef(function(n, i) {
8139
8148
  let { render: s, className: c, disabled: l = !1, nativeButton: u = !0, id: d, payload: f, handle: m, ...h } = n, g = useDialogRootContext(!0), _ = m?.store ?? g?.store;
8140
8149
  if (!_) throw Error(process.env.NODE_ENV === "production" ? formatErrorMessage(79) : "Base UI: <Dialog.Trigger> must be used within <Dialog.Root> or provided with a handle.");
8141
- let v = useBaseUiId(d), y = _.useState("floatingRootContext"), x = _.useState("isOpenedByTrigger", v), S = React.useRef(null), { registerTrigger: C, isMountedByThisTrigger: w } = useTriggerDataForwarding(v, S, _, { payload: f }), { getButtonProps: T, buttonRef: E } = useButton({
8150
+ let v = useBaseUiId(d), y = _.useState("floatingRootContext"), b = _.useState("isOpenedByTrigger", v), x = React.useRef(null), { registerTrigger: S, isMountedByThisTrigger: C } = useTriggerDataForwarding(v, x, _, { payload: f }), { getButtonProps: w, buttonRef: T } = useButton({
8142
8151
  disabled: l,
8143
8152
  native: u
8144
- }), D = useInteractions([useClick(y, { enabled: y != null })]), O = React.useMemo(() => ({
8153
+ }), E = useInteractions([useClick(y, { enabled: y != null })]), D = React.useMemo(() => ({
8145
8154
  disabled: l,
8146
- open: x
8147
- }), [l, x]), k = _.useState("triggerProps", w);
8155
+ open: b
8156
+ }), [l, b]), k = _.useState("triggerProps", C);
8148
8157
  return useRenderElement("button", n, {
8149
- state: O,
8158
+ state: D,
8150
8159
  ref: [
8151
- E,
8160
+ T,
8152
8161
  i,
8153
- C,
8154
- S
8162
+ S,
8163
+ x
8155
8164
  ],
8156
8165
  props: [
8157
- D.getReferenceProps(),
8166
+ E.getReferenceProps(),
8158
8167
  k,
8159
8168
  {
8160
8169
  "data-base-ui-click-trigger": "",
8161
8170
  id: v
8162
8171
  },
8163
8172
  h,
8164
- T
8173
+ w
8165
8174
  ],
8166
8175
  stateAttributesMapping: triggerOpenStateMapping
8167
8176
  });
8168
8177
  });
8169
8178
  process.env.NODE_ENV !== "production" && (DialogTrigger$1.displayName = "DialogTrigger");
8170
8179
  var import_compiler_runtime$24 = require_compiler_runtime();
8180
+ const Dialog = (t) => {
8181
+ let n = (0, import_compiler_runtime$24.c)(4), i;
8182
+ n[0] === t ? i = n[1] : ({...i} = t, n[0] = t, n[1] = i);
8183
+ let s;
8184
+ return n[2] === i ? s = n[3] : (s = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DialogRoot, { ...i }), n[2] = i, n[3] = s), s;
8185
+ };
8186
+ var import_compiler_runtime$23 = require_compiler_runtime();
8171
8187
  const DialogClose = (t) => {
8172
- let n = (0, import_compiler_runtime$24.c)(13), i, s, c, l;
8188
+ let n = (0, import_compiler_runtime$23.c)(13), i, s, c, l;
8173
8189
  n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4]) : ({className: s, children: i, ref: l, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l);
8174
8190
  let u;
8175
8191
  n[5] === s ? u = n[6] : (u = cn("", s), n[5] = s, n[6] = u);
@@ -8188,12 +8204,12 @@ const DialogClose = (t) => {
8188
8204
  children: i
8189
8205
  }), n[8] = i, n[9] = c, n[10] = l, n[11] = u, n[12] = f) : f = n[12], f;
8190
8206
  };
8191
- var import_compiler_runtime$23 = require_compiler_runtime();
8207
+ var import_compiler_runtime$22 = require_compiler_runtime();
8192
8208
  const DialogDescription = (t) => {
8193
- let n = (0, import_compiler_runtime$23.c)(12), i, s, c, l;
8209
+ let n = (0, import_compiler_runtime$22.c)(12), i, s, c, l;
8194
8210
  n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4]) : ({className: s, children: i, ref: l, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l);
8195
8211
  let u;
8196
- n[5] === s ? u = n[6] : (u = cn("text-prose-0 mb-0", s), n[5] = s, n[6] = u);
8212
+ n[5] === s ? u = n[6] : (u = cn("mb-0 text-prose-0", s), n[5] = s, n[6] = u);
8197
8213
  let d;
8198
8214
  return n[7] !== i || n[8] !== c || n[9] !== l || n[10] !== u ? (d = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DialogDescription$1, {
8199
8215
  className: u,
@@ -8202,14 +8218,14 @@ const DialogDescription = (t) => {
8202
8218
  children: i
8203
8219
  }), n[7] = i, n[8] = c, n[9] = l, n[10] = u, n[11] = d) : d = n[11], d;
8204
8220
  };
8205
- var import_compiler_runtime$22 = require_compiler_runtime();
8221
+ var import_compiler_runtime$21 = require_compiler_runtime();
8206
8222
  const DialogPopup = (t) => {
8207
- let n = (0, import_compiler_runtime$22.c)(19), i, s, c, l, u;
8223
+ let n = (0, import_compiler_runtime$21.c)(19), i, s, c, l, u;
8208
8224
  n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4], u = n[5]) : ({className: s, children: i, showCloseButton: u, ref: l, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l, n[5] = u);
8209
8225
  let d = u === void 0 ? !0 : u, f;
8210
8226
  n[6] === Symbol.for("react.memo_cache_sentinel") ? (f = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DialogBackdrop, { className: "fixed inset-[0px] min-h-dvh bg-scrim opacity-50 transition-all duration-150 data-ending-style:opacity-0 data-starting-style:opacity-0 supports-[-webkit-touch-callout:none]:absolute" }), n[6] = f) : f = n[6];
8211
8227
  let m;
8212
- n[7] === s ? m = n[8] : (m = cn("fixed top-1/2 left-1/2 min-w-1/3 max-w-[calc(100vw-3rem)] px-md py-sm space-y-2xs -translate-x-1/2 -translate-y-1/2 rounded-lg bg-surface-container outline-1 outline-outline transition-all duration-150 data-ending-style:scale-90 data-ending-style:opacity-0 data-starting-style:scale-90 data-starting-style:opacity-0", s), n[7] = s, n[8] = m);
8228
+ n[7] === s ? m = n[8] : (m = cn("fixed top-1/2 left-1/2 min-w-1/3 max-w-[calc(100vw-3rem)] -translate-x-1/2 -translate-y-1/2 space-y-2xs rounded-lg bg-surface-container px-md py-sm outline-1 outline-outline transition-all duration-150 data-ending-style:scale-90 data-starting-style:scale-90 data-ending-style:opacity-0 data-starting-style:opacity-0", s), n[7] = s, n[8] = m);
8213
8229
  let h;
8214
8230
  n[9] === d ? h = n[10] : (h = d && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DialogClose, {}), n[9] = d, n[10] = h);
8215
8231
  let g;
@@ -8225,9 +8241,9 @@ const DialogPopup = (t) => {
8225
8241
  children: [i, g]
8226
8242
  })] }), n[13] = i, n[14] = c, n[15] = l, n[16] = m, n[17] = g, n[18] = _) : _ = n[18], _;
8227
8243
  };
8228
- var import_compiler_runtime$21 = require_compiler_runtime();
8244
+ var import_compiler_runtime$20 = require_compiler_runtime();
8229
8245
  const DialogTitle = (t) => {
8230
- let n = (0, import_compiler_runtime$21.c)(12), i, s, c, l;
8246
+ let n = (0, import_compiler_runtime$20.c)(12), i, s, c, l;
8231
8247
  n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4]) : ({className: s, children: i, ref: l, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l);
8232
8248
  let u;
8233
8249
  n[5] === s ? u = n[6] : (u = cn("text-strong-2", s), n[5] = s, n[6] = u);
@@ -8239,9 +8255,9 @@ const DialogTitle = (t) => {
8239
8255
  children: i
8240
8256
  }), n[7] = i, n[8] = c, n[9] = l, n[10] = u, n[11] = d) : d = n[11], d;
8241
8257
  };
8242
- var import_compiler_runtime$20 = require_compiler_runtime();
8258
+ var import_compiler_runtime$19 = require_compiler_runtime();
8243
8259
  const DialogTrigger = (t) => {
8244
- let n = (0, import_compiler_runtime$20.c)(12), i, s, c, l;
8260
+ let n = (0, import_compiler_runtime$19.c)(12), i, s, c, l;
8245
8261
  n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4]) : ({className: s, children: i, ref: l, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l);
8246
8262
  let u;
8247
8263
  n[5] === s ? u = n[6] : (u = cn("", s), n[5] = s, n[6] = u);
@@ -8253,13 +8269,6 @@ const DialogTrigger = (t) => {
8253
8269
  children: i
8254
8270
  }), n[7] = i, n[8] = c, n[9] = l, n[10] = u, n[11] = d) : d = n[11], d;
8255
8271
  };
8256
- var import_compiler_runtime$19 = require_compiler_runtime();
8257
- const Dialog = (t) => {
8258
- let n = (0, import_compiler_runtime$19.c)(4), i;
8259
- n[0] === t ? i = n[1] : ({...i} = t, n[0] = t, n[1] = i);
8260
- let s;
8261
- return n[2] === i ? s = n[3] : (s = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DialogRoot, { ...i }), n[2] = i, n[3] = s), s;
8262
- };
8263
8272
  var __storeToDerived = /* @__PURE__ */ new WeakMap(), __derivedToStore = /* @__PURE__ */ new WeakMap(), __depsThatHaveWrittenThisTick = { current: [] }, __isFlushing = !1, __batchDepth = 0, __pendingUpdates = /* @__PURE__ */ new Set(), __initialBatchValues = /* @__PURE__ */ new Map();
8264
8273
  function __flush_internals(t) {
8265
8274
  let n = Array.from(t).sort((t, n) => t instanceof Derived && t.options.deps.includes(n) ? 1 : n instanceof Derived && n.options.deps.includes(t) ? -1 : 0);
@@ -10078,7 +10087,7 @@ const FieldErrors = (t) => {
10078
10087
  let f;
10079
10088
  n[7] === u.state.meta.errors ? f = n[8] : (f = u.state.meta.errors.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
10080
10089
  className: "mt-2",
10081
- children: u.state.meta.errors.map(_temp$2)
10090
+ children: u.state.meta.errors.map(_temp$1)
10082
10091
  }), n[7] = u.state.meta.errors, n[8] = f);
10083
10092
  let m;
10084
10093
  return n[9] !== i || n[10] !== c || n[11] !== l || n[12] !== d || n[13] !== f ? (m = /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
@@ -10088,11 +10097,11 @@ const FieldErrors = (t) => {
10088
10097
  children: [i, f]
10089
10098
  }), n[9] = i, n[10] = c, n[11] = l, n[12] = d, n[13] = f, n[14] = m) : m = n[14], m;
10090
10099
  };
10091
- function _temp$2(t, n) {
10100
+ function _temp$1(t) {
10092
10101
  return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
10093
10102
  className: "text-error text-sm",
10094
10103
  children: t.message
10095
- }, n);
10104
+ }, t.message);
10096
10105
  }
10097
10106
  function useLabelableId(t = {}) {
10098
10107
  let { id: n, implicit: i = !1, controlRef: s } = t, { controlId: c, setControlId: l } = useLabelableContext(), u = useBaseUiId(n);
@@ -10200,18 +10209,18 @@ var import_compiler_runtime$16 = require_compiler_runtime();
10200
10209
  const Input = (t) => {
10201
10210
  let n = (0, import_compiler_runtime$16.c)(20), s, c, l, u, d;
10202
10211
  n[0] === t ? (s = n[1], c = n[2], l = n[3], u = n[4], d = n[5]) : ({leadingIcon: c, showSeparator: d, className: s, ref: u, ...l} = t, n[0] = t, n[1] = s, n[2] = c, n[3] = l, n[4] = u, n[5] = d);
10203
- let f = d === void 0 ? !0 : d, m = l.disabled, h = l.disabled, g;
10204
- n[6] === s ? g = n[7] : (g = cn("flex items-center gap-xs px-md w-full py-sm group h-xl inset-shadow-2-shadow inset-shadow-sm bg-surface-dim rounded-xl data-[disabled=true]:opacity-50 data-[disabled=true]:cursor-not-allowed data-[disabled=true]:hover:outline-transparent outline-2 outline-transparent hover:not-focus-within:outline-outline focus-within:outline-primary focus-within:caret-primary transition-all", s), n[6] = s, n[7] = g);
10205
- let _;
10212
+ let f = d === void 0 ? !0 : d, m = l.disabled, h;
10213
+ n[6] === s ? h = n[7] : (h = cn("group inset-shadow-2-shadow inset-shadow-sm flex h-xl w-full items-center gap-xs rounded-xl bg-surface-dim px-md py-sm outline-2 outline-transparent transition-all focus-within:caret-primary focus-within:outline-primary hover:not-focus-within:outline-outline data-[disabled=true]:cursor-not-allowed data-[disabled=true]:opacity-50 data-[disabled=true]:hover:outline-transparent", s), n[6] = s, n[7] = h);
10214
+ let g = l.disabled, _;
10206
10215
  n[8] !== c || n[9] !== f ? (_ = c && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
10207
- className: cn("flex items-center text-on-surface-variant justify-center [&>svg]:size-s group-focus-within:text-primary transition-all"),
10216
+ className: cn("flex items-center justify-center text-on-surface-variant transition-all group-focus-within:text-primary [&>svg]:size-s"),
10208
10217
  children: createElement(c, { weight: "bold" })
10209
10218
  }), f && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Separator, {
10210
- orientation: "vertical",
10211
- className: "group-focus-within:bg-primary"
10219
+ className: "group-focus-within:bg-primary",
10220
+ orientation: "vertical"
10212
10221
  })] }), n[8] = c, n[9] = f, n[10] = _) : _ = n[10];
10213
10222
  let v;
10214
- n[11] === Symbol.for("react.memo_cache_sentinel") ? (v = cn("outline-none w-full", "placeholder:opacity-60", "disabled:text-text-neutral-primary-disabled disabled:cursor-not-allowed", "overflow-ellipsis"), n[11] = v) : v = n[11];
10223
+ n[11] === Symbol.for("react.memo_cache_sentinel") ? (v = cn("w-full outline-none", "placeholder:opacity-60", "disabled:cursor-not-allowed disabled:text-text-neutral-primary-disabled", "overflow-ellipsis"), n[11] = v) : v = n[11];
10215
10224
  let y;
10216
10225
  n[12] !== l || n[13] !== u ? (y = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Input$1, {
10217
10226
  className: v,
@@ -10219,67 +10228,42 @@ const Input = (t) => {
10219
10228
  ...l
10220
10229
  }), n[12] = l, n[13] = u, n[14] = y) : y = n[14];
10221
10230
  let b;
10222
- return n[15] !== l.disabled || n[16] !== g || n[17] !== _ || n[18] !== y ? (b = /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
10231
+ return n[15] !== l.disabled || n[16] !== h || n[17] !== _ || n[18] !== y ? (b = /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
10223
10232
  "aria-disabled": m,
10224
- "data-disabled": h,
10225
- className: g,
10233
+ className: h,
10234
+ "data-disabled": g,
10226
10235
  children: [_, y]
10227
- }), n[15] = l.disabled, n[16] = g, n[17] = _, n[18] = y, n[19] = b) : b = n[19], b;
10236
+ }), n[15] = l.disabled, n[16] = h, n[17] = _, n[18] = y, n[19] = b) : b = n[19], b;
10228
10237
  };
10229
10238
  var import_compiler_runtime$15 = require_compiler_runtime();
10230
10239
  const FieldInput = (t) => {
10231
10240
  let n = (0, import_compiler_runtime$15.c)(23), i, s, c, l;
10232
10241
  n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4]) : ({className: s, children: i, ref: l, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l);
10233
- let u = useFieldContext(), d = u.name, f = u.name, m = u.state.value, h;
10234
- n[5] === u ? h = n[6] : (h = (t) => u.handleChange(t.target.value), n[5] = u, n[6] = h);
10242
+ let u = useFieldContext(), d;
10243
+ n[5] === u ? d = n[6] : (d = u.state.value && u.getMeta().errors.length > 0 && "outline-error", n[5] = u, n[6] = d);
10244
+ let f;
10245
+ n[7] === u ? f = n[8] : (f = u.state.value && u.getMeta().isValid && "outline-success", n[7] = u, n[8] = f);
10246
+ let m;
10247
+ n[9] !== s || n[10] !== d || n[11] !== f ? (m = cn(d, f, s), n[9] = s, n[10] = d, n[11] = f, n[12] = m) : m = n[12];
10248
+ let h;
10249
+ n[13] === u ? h = n[14] : (h = (t) => u.handleChange(t.target.value), n[13] = u, n[14] = h);
10235
10250
  let g;
10236
- n[7] === u ? g = n[8] : (g = u.state.value && u.getMeta().errors.length > 0 && "outline-error", n[7] = u, n[8] = g);
10237
- let _;
10238
- n[9] === u ? _ = n[10] : (_ = u.state.value && u.getMeta().isValid && "outline-success", n[9] = u, n[10] = _);
10239
- let v;
10240
- n[11] !== s || n[12] !== g || n[13] !== _ ? (v = cn(g, _, s), n[11] = s, n[12] = g, n[13] = _, n[14] = v) : v = n[14];
10241
- let y;
10242
- return n[15] !== i || n[16] !== u.name || n[17] !== u.state.value || n[18] !== c || n[19] !== l || n[20] !== h || n[21] !== v ? (y = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Input, {
10243
- required: !0,
10244
- type: "text",
10245
- id: d,
10246
- name: f,
10247
- value: m,
10251
+ return n[15] !== i || n[16] !== u.name || n[17] !== u.state.value || n[18] !== c || n[19] !== l || n[20] !== m || n[21] !== h ? (g = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Input, {
10252
+ className: m,
10253
+ id: u.name,
10254
+ name: u.name,
10248
10255
  onChange: h,
10249
- className: v,
10250
10256
  ref: l,
10257
+ required: !0,
10258
+ type: "text",
10259
+ value: u.state.value,
10251
10260
  ...c,
10252
10261
  children: i
10253
- }), n[15] = i, n[16] = u.name, n[17] = u.state.value, n[18] = c, n[19] = l, n[20] = h, n[21] = v, n[22] = y) : y = n[22], y;
10262
+ }), n[15] = i, n[16] = u.name, n[17] = u.state.value, n[18] = c, n[19] = l, n[20] = m, n[21] = h, n[22] = g) : g = n[22], g;
10254
10263
  };
10255
10264
  var import_compiler_runtime$14 = require_compiler_runtime();
10256
- const FormSubmit = (t) => {
10257
- let n = (0, import_compiler_runtime$14.c)(15), i, s, c, l, u;
10258
- n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4], u = n[5]) : ({submittingText: u, className: s, children: i, ref: l, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l, n[5] = u);
10259
- let d = u === void 0 ? "Submitting..." : u, f = useFormContext$1(), m;
10260
- n[6] !== i || n[7] !== s || n[8] !== c || n[9] !== l || n[10] !== d ? (m = (t) => {
10261
- let [n, u] = t;
10262
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Button, {
10263
- type: "submit",
10264
- disabled: !n || u,
10265
- className: cn("w-full", s),
10266
- ref: l,
10267
- ...c,
10268
- children: u ? d : i
10269
- });
10270
- }, n[6] = i, n[7] = s, n[8] = c, n[9] = l, n[10] = d, n[11] = m) : m = n[11];
10271
- let h;
10272
- return n[12] !== f.Subscribe || n[13] !== m ? (h = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(f.Subscribe, {
10273
- selector: _temp$1,
10274
- children: m
10275
- }), n[12] = f.Subscribe, n[13] = m, n[14] = h) : h = n[14], h;
10276
- };
10277
- function _temp$1(t) {
10278
- return [t.canSubmit, t.isSubmitting];
10279
- }
10280
- var import_compiler_runtime$13 = require_compiler_runtime();
10281
10265
  const FormErrors = (t) => {
10282
- let n = (0, import_compiler_runtime$13.c)(17), i, s, c, l;
10266
+ let n = (0, import_compiler_runtime$14.c)(17), i, s, c, l;
10283
10267
  n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4]) : ({className: s, children: i, ref: l, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l);
10284
10268
  let u = useStore(useFormContext$1().store, _temp), d;
10285
10269
  n[5] === s ? d = n[6] : (d = cn("", s), n[5] = s, n[6] = d);
@@ -10301,13 +10285,28 @@ const FormErrors = (t) => {
10301
10285
  function _temp(t) {
10302
10286
  return t.errors;
10303
10287
  }
10304
- function _temp2(t, n) {
10288
+ function _temp2(t) {
10305
10289
  return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
10306
10290
  className: "text-error text-sm",
10307
10291
  children: t.message
10308
- }, n);
10292
+ }, t.message);
10309
10293
  }
10310
- const Form = createFormHook({
10294
+ var import_compiler_runtime$13 = require_compiler_runtime();
10295
+ const FormSubmit = (t) => {
10296
+ let n = (0, import_compiler_runtime$13.c)(15), i, s, c, l, u;
10297
+ n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4], u = n[5]) : ({submittingText: u, className: s, children: i, ref: l, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l, n[5] = u);
10298
+ let d = u === void 0 ? "Submitting..." : u, f = useFormContext$1(), m;
10299
+ n[6] !== i || n[7] !== s || n[8] !== c || n[9] !== l || n[10] !== d ? (m = (t) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Button, {
10300
+ className: cn("w-full", s),
10301
+ disabled: !t.canSubmit || t.isSubmitting,
10302
+ ref: l,
10303
+ type: "submit",
10304
+ ...c,
10305
+ children: t.isSubmitting ? d : i
10306
+ }), n[6] = i, n[7] = s, n[8] = c, n[9] = l, n[10] = d, n[11] = m) : m = n[11];
10307
+ let h;
10308
+ return n[12] !== f.Subscribe || n[13] !== m ? (h = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(f.Subscribe, { children: m }), n[12] = f.Subscribe, n[13] = m, n[14] = h) : h = n[14], h;
10309
+ }, Form = createFormHook({
10311
10310
  fieldComponents: {
10312
10311
  FieldErrors,
10313
10312
  FieldInput
@@ -10327,8 +10326,8 @@ const Label = (t) => {
10327
10326
  n[5] === s ? u = n[6] : (u = cn("hover:cursor-pointer", s), n[5] = s, n[6] = u);
10328
10327
  let d;
10329
10328
  return n[7] !== i || n[8] !== c || n[9] !== l || n[10] !== u ? (d = /* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", {
10330
- "data-slot": "label",
10331
10329
  className: u,
10330
+ "data-slot": "label",
10332
10331
  ref: l,
10333
10332
  ...c,
10334
10333
  children: i
@@ -10351,7 +10350,7 @@ const Profile = (t) => {
10351
10350
  i
10352
10351
  ] }), n[16] = i, n[17] = b, n[18] = x, n[19] = S) : S = n[19];
10353
10352
  let C = v && "hidden", w;
10354
- n[20] === C ? w = n[21] : (w = cn("flex flex-col justify-start items-start", C), n[20] = C, n[21] = w);
10353
+ n[20] === C ? w = n[21] : (w = cn("flex flex-col items-start justify-start", C), n[20] = C, n[21] = w);
10355
10354
  let T;
10356
10355
  n[22] === g ? T = n[23] : (T = /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
10357
10356
  className: "text-prose-0",
@@ -10492,12 +10491,12 @@ const ScrollAreaRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
10492
10491
  [ScrollAreaRootCssVars.scrollAreaCornerHeight]: `${v.height}px`,
10493
10492
  [ScrollAreaRootCssVars.scrollAreaCornerWidth]: `${v.width}px`
10494
10493
  }
10495
- }, fh = useRenderElement("div", n, {
10494
+ }, $ = useRenderElement("div", n, {
10496
10495
  state: Z,
10497
10496
  ref: [i, D],
10498
10497
  props: [Q, u],
10499
10498
  stateAttributesMapping: scrollAreaStateAttributesMapping
10500
- }), $ = React.useMemo(() => ({
10499
+ }), yh = React.useMemo(() => ({
10501
10500
  handlePointerDown: q,
10502
10501
  handlePointerMove: J,
10503
10502
  handlePointerUp: Y,
@@ -10555,8 +10554,8 @@ const ScrollAreaRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
10555
10554
  G
10556
10555
  ]);
10557
10556
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(ScrollAreaRootContext.Provider, {
10558
- value: $,
10559
- children: [styleDisableScrollbar.element, fh]
10557
+ value: yh,
10558
+ children: [styleDisableScrollbar.element, $]
10560
10559
  });
10561
10560
  });
10562
10561
  process.env.NODE_ENV !== "production" && (ScrollAreaRoot.displayName = "ScrollAreaRoot");
@@ -10640,13 +10639,13 @@ const ScrollAreaViewport = /* @__PURE__ */ React.forwardRef(function(n, i) {
10640
10639
  let t = i.offsetWidth - Y - V - U, n = b - C, s = n === 0 ? 0 : E / n, l = O === "rtl" ? clamp$1(s * t, -t, 0) : clamp$1(s * t, 0, t);
10641
10640
  c.style.transform = `translate3d(${l}px,0,0)`;
10642
10641
  }
10643
- let Z = clamp$1(F, 0, N), Q = clamp$1(I, 0, N), fh = clamp$1(L, 0, P), ph = clamp$1(R, 0, P), $ = [
10642
+ let Z = clamp$1(F, 0, N), Q = clamp$1(I, 0, N), $ = clamp$1(L, 0, P), yh = clamp$1(R, 0, P), bh = [
10644
10643
  [ScrollAreaViewportCssVars.scrollAreaOverflowXStart, Z],
10645
10644
  [ScrollAreaViewportCssVars.scrollAreaOverflowXEnd, Q],
10646
- [ScrollAreaViewportCssVars.scrollAreaOverflowYStart, fh],
10647
- [ScrollAreaViewportCssVars.scrollAreaOverflowYEnd, ph]
10645
+ [ScrollAreaViewportCssVars.scrollAreaOverflowYStart, $],
10646
+ [ScrollAreaViewportCssVars.scrollAreaOverflowYEnd, yh]
10648
10647
  ];
10649
- for (let [n, i] of $) t.style.setProperty(n, `${i}px`);
10648
+ for (let [n, i] of bh) t.style.setProperty(n, `${i}px`);
10650
10649
  l && (A || k ? v({
10651
10650
  width: 0,
10652
10651
  height: 0
@@ -10661,13 +10660,13 @@ const ScrollAreaViewport = /* @__PURE__ */ React.forwardRef(function(n, i) {
10661
10660
  cornerHidden: n
10662
10661
  };
10663
10662
  });
10664
- let mh = {
10663
+ let xh = {
10665
10664
  xStart: !A && Z > D.xStart,
10666
10665
  xEnd: !A && Q > D.xEnd,
10667
- yStart: !k && fh > D.yStart,
10668
- yEnd: !k && ph > D.yEnd
10666
+ yStart: !k && $ > D.yStart,
10667
+ yEnd: !k && yh > D.yEnd
10669
10668
  };
10670
- T((t) => t.xStart === mh.xStart && t.xEnd === mh.xEnd && t.yStart === mh.yStart && t.yEnd === mh.yEnd ? t : mh);
10669
+ T((t) => t.xStart === xh.xStart && t.xEnd === xh.xEnd && t.yStart === xh.yStart && t.yEnd === xh.yEnd ? t : xh);
10671
10670
  }
10672
10671
  let N = useStableCallback(() => {
10673
10672
  ReactDOM.flushSync(M);
@@ -10886,17 +10885,17 @@ const ScrollArea = (t) => {
10886
10885
  n[6] !== s || n[7] !== f ? (m = cn("h-[200px] rounded-lg bg-surface-container", f, s), n[6] = s, n[7] = f, n[8] = m) : m = n[8];
10887
10886
  let h;
10888
10887
  n[9] === i ? h = n[10] : (h = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ScrollAreaViewport, {
10889
- className: "h-full overscroll-contain flex flex-col gap-xs py-2xs pr-sm pl-sm prose-step-0",
10888
+ className: "prose-step-0 flex h-full flex-col gap-xs overscroll-contain py-2xs pr-sm pl-sm",
10890
10889
  children: i
10891
10890
  }), n[9] = i, n[10] = h);
10892
- let g = d === "vertical" && "w-2xs mr-2xs my-2xs", _ = d === "horizontal" && "h-2xs flex-col mb-2xs mx-xs", v;
10893
- n[11] !== s || n[12] !== g || n[13] !== _ ? (v = cn("inset-shadow-1-shadow flex justify-center rounded p-[2px] bg-surface-dim opacity-0 transition-opacity delay-300 data-hovering:opacity-100 data-hovering:delay-0 data-hovering:duration-75 data-scrolling:opacity-100 data-scrolling:delay-0 data-scrolling:duration-75 hover:cursor-pointer", g, _, s), n[11] = s, n[12] = g, n[13] = _, n[14] = v) : v = n[14];
10891
+ let g = d === "vertical" && "my-2xs mr-2xs w-2xs", _ = d === "horizontal" && "mx-xs mb-2xs h-2xs flex-col", v;
10892
+ n[11] !== s || n[12] !== g || n[13] !== _ ? (v = cn("inset-shadow-1-shadow flex justify-center rounded bg-surface-dim p-[2px] opacity-0 transition-opacity delay-300 hover:cursor-pointer data-hovering:opacity-100 data-scrolling:opacity-100 data-hovering:delay-0 data-scrolling:delay-0 data-hovering:duration-75 data-scrolling:duration-75", g, _, s), n[11] = s, n[12] = g, n[13] = _, n[14] = v) : v = n[14];
10894
10893
  let y;
10895
- n[15] === Symbol.for("react.memo_cache_sentinel") ? (y = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ScrollAreaThumb, { className: "w-full h-full rounded-full bg-accent rounded-1" }), n[15] = y) : y = n[15];
10894
+ n[15] === Symbol.for("react.memo_cache_sentinel") ? (y = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ScrollAreaThumb, { className: "h-full w-full rounded-1 rounded-full bg-accent" }), n[15] = y) : y = n[15];
10896
10895
  let b;
10897
10896
  n[16] !== d || n[17] !== v ? (b = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ScrollAreaScrollbar, {
10898
- orientation: d,
10899
10897
  className: v,
10898
+ orientation: d,
10900
10899
  children: y
10901
10900
  }), n[16] = d, n[17] = v, n[18] = b) : b = n[18];
10902
10901
  let x;
@@ -10912,86 +10911,211 @@ const ScrollArea = (t) => {
10912
10911
  x
10913
10912
  ]
10914
10913
  }), n[20] = c, n[21] = l, n[22] = m, n[23] = h, n[24] = b, n[25] = S) : S = n[25], S;
10915
- }, TooltipRootContext = /* @__PURE__ */ React.createContext(void 0);
10916
- process.env.NODE_ENV !== "production" && (TooltipRootContext.displayName = "TooltipRootContext");
10917
- function useTooltipRootContext(n) {
10918
- let i = React.useContext(TooltipRootContext);
10919
- if (i === void 0 && !n) throw Error(process.env.NODE_ENV === "production" ? formatErrorMessage(72) : "Base UI: TooltipRootContext is missing. Tooltip parts must be placed within <Tooltip.Root>.");
10920
- return i;
10921
- }
10922
- var selectors = {
10923
- ...popupStoreSelectors,
10924
- disabled: createSelector((t) => t.disabled),
10925
- instantType: createSelector((t) => t.instantType),
10926
- isInstantPhase: createSelector((t) => t.isInstantPhase),
10927
- trackCursorAxis: createSelector((t) => t.trackCursorAxis),
10928
- disableHoverablePopup: createSelector((t) => t.disableHoverablePopup),
10929
- lastOpenChangeReason: createSelector((t) => t.openChangeReason),
10930
- closeDelay: createSelector((t) => t.closeDelay)
10931
- }, TooltipStore = class n extends ReactStore {
10932
- constructor(n) {
10933
- super({
10934
- ...createInitialState(),
10935
- ...n
10936
- }, {
10937
- popupRef: /* @__PURE__ */ React.createRef(),
10938
- onOpenChange: void 0,
10939
- onOpenChangeComplete: void 0,
10940
- triggerElements: new PopupTriggerMap()
10941
- }, selectors);
10942
- }
10943
- setOpen = (t, n) => {
10944
- let i = n.reason, s = i === triggerHover, c = t && i === "trigger-focus", l = !t && (i === "trigger-press" || i === "escape-key");
10945
- if (n.preventUnmountOnClose = () => {
10946
- this.set("preventUnmountingOnClose", !0);
10947
- }, this.context.onOpenChange?.(t, n), n.isCanceled) return;
10948
- let u = () => {
10949
- let s = {
10950
- open: t,
10951
- openChangeReason: i
10952
- };
10953
- c ? s.instantType = "focus" : l ? s.instantType = "dismiss" : i === "trigger-hover" && (s.instantType = void 0);
10954
- let u = n.trigger?.id ?? null;
10955
- (u || t) && (s.activeTriggerId = u, s.activeTriggerElement = n.trigger ?? null), this.update(s);
10956
- };
10957
- s ? ReactDOM.flushSync(u) : u();
10958
- };
10959
- static useStore(t, i) {
10960
- let s = useRefWithInit(() => t ?? new n(i)).current, c = useSyncedFloatingRootContext({
10961
- popupStore: s,
10962
- onOpenChange: s.setOpen
10963
- });
10964
- return s.state.floatingRootContext = c, s;
10965
- }
10966
10914
  };
10967
- function createInitialState() {
10915
+ var getBoundingClientRect = (t) => {
10916
+ let n = t.getBoundingClientRect();
10968
10917
  return {
10969
- ...createInitialPopupStoreState(),
10970
- disabled: !1,
10971
- instantType: void 0,
10972
- isInstantPhase: !1,
10973
- trackCursorAxis: "none",
10974
- disableHoverablePopup: !1,
10975
- openChangeReason: null,
10976
- closeDelay: 0
10918
+ left: Math.ceil(n.left),
10919
+ width: Math.ceil(n.width)
10977
10920
  };
10978
- }
10979
- function TooltipRoot(n) {
10980
- let { disabled: i = !1, defaultOpen: s = !1, open: c, disableHoverablePopup: l = !1, trackCursorAxis: u = "none", actionsRef: d, onOpenChange: f, onOpenChangeComplete: m, handle: h, triggerId: g, defaultTriggerId: _ = null, children: v } = n, y = TooltipStore.useStore(h?.store, {
10981
- open: c ?? s,
10982
- activeTriggerId: g === void 0 ? _ : g
10983
- });
10984
- y.useControlledProp("open", c, s), y.useControlledProp("activeTriggerId", g, _), y.useContextCallback("onOpenChange", f), y.useContextCallback("onOpenChangeComplete", m);
10985
- let b = y.useState("open"), x = y.useState("activeTriggerId"), S = y.useState("payload");
10986
- y.useSyncedValues({
10987
- trackCursorAxis: u,
10988
- disableHoverablePopup: l
10989
- });
10990
- let C = !i && b;
10991
- useIsoLayoutEffect(() => {
10992
- b && i && y.setOpen(!1, createChangeEventDetails("disabled"));
10993
- }, [
10994
- b,
10921
+ }, sortNumList = (t) => [...t].map(Number).sort((t, n) => t - n), linearInterpolator = {
10922
+ getPercentageForValue: (t, n, i) => Math.max(0, Math.min(100, (t - n) / (i - n) * 100)),
10923
+ getValueForClientX: (t, n, i, s) => {
10924
+ let { left: c, width: l } = n, u = (t - c) / l;
10925
+ return (s - i) * u + i;
10926
+ }
10927
+ }, Ranger = class {
10928
+ constructor(t) {
10929
+ this.sortedValues = [], this.rangerElement = null, this._willUpdate = () => {
10930
+ let t = this.options.getRangerElement();
10931
+ this.rangerElement !== t && (this.rangerElement = t);
10932
+ }, this.getValueForClientX = (t) => {
10933
+ let n = getBoundingClientRect(this.rangerElement);
10934
+ return this.options.interpolator.getValueForClientX(t, n, this.options.min, this.options.max);
10935
+ }, this.getNextStep = (t, n) => {
10936
+ let { min: i, max: s } = this.options;
10937
+ if ("steps" in this.options) {
10938
+ let { steps: i } = this.options, s = i.indexOf(t) + n;
10939
+ return s >= 0 && s < i.length ? i[s] : t;
10940
+ } else {
10941
+ let c = t + this.options.stepSize * n;
10942
+ return c >= i && c <= s ? c : t;
10943
+ }
10944
+ }, this.roundToStep = (t) => {
10945
+ let { min: n, max: i } = this.options, s = n, c = i;
10946
+ if ("steps" in this.options) this.options.steps.forEach((n) => {
10947
+ n <= t && n > s && (s = n), n >= t && n < c && (c = n);
10948
+ });
10949
+ else {
10950
+ let { stepSize: n } = this.options;
10951
+ for (; s < t && s + n < t;) s += n;
10952
+ c = Math.min(s + n, i);
10953
+ }
10954
+ return t - s < c - t ? s : c;
10955
+ }, this.handleDrag = (t) => {
10956
+ if (this.activeHandleIndex === void 0) return;
10957
+ let n = t.type === "touchmove" ? t.changedTouches[0].clientX : t.clientX, i = this.getValueForClientX(n), s = this.roundToStep(i);
10958
+ this.sortedValues = [
10959
+ ...this.options.values.slice(0, this.activeHandleIndex),
10960
+ s,
10961
+ ...this.options.values.slice(this.activeHandleIndex + 1)
10962
+ ], this.options.onDrag ? this.options.onDrag(this) : (this.tempValues = this.sortedValues, this.options.rerender());
10963
+ }, this.handleKeyDown = (t, n) => {
10964
+ let { values: i } = this.options;
10965
+ if (t.keyCode === 37 || t.keyCode === 39) {
10966
+ this.activeHandleIndex = n;
10967
+ let s = t.keyCode === 37 ? -1 : 1, c = this.getNextStep(i[n], s);
10968
+ this.sortedValues = sortNumList([
10969
+ ...i.slice(0, n),
10970
+ c,
10971
+ ...i.slice(n + 1)
10972
+ ]), this.options.onChange && this.options.onChange(this);
10973
+ }
10974
+ }, this.handlePress = (t, n) => {
10975
+ this.activeHandleIndex = n, this.options.rerender();
10976
+ let i = () => {
10977
+ let { tempValues: t, handleDrag: n } = this;
10978
+ document.removeEventListener("mousemove", n), document.removeEventListener("touchmove", n), document.removeEventListener("mouseup", i), document.removeEventListener("touchend", i), this.sortedValues = sortNumList(t || this.options.values), this.options.onChange && this.options.onChange(this), this.options.onDrag && this.options.onDrag(this), this.activeHandleIndex = void 0, this.tempValues = void 0, this.options.rerender();
10979
+ }, { handleDrag: s } = this;
10980
+ document.addEventListener("mousemove", s), document.addEventListener("touchmove", s), document.addEventListener("mouseup", i), document.addEventListener("touchend", i);
10981
+ }, this.getPercentageForValue = (t) => this.options.interpolator.getPercentageForValue(t, this.options.min, this.options.max), this.getTicks = () => {
10982
+ let t = [];
10983
+ if (this.options.ticks) t = [...this.options.ticks];
10984
+ else if ("steps" in this.options) t = [...this.options.steps];
10985
+ else {
10986
+ for (t = [this.options.min]; t[t.length - 1] < this.options.max - this.options.tickSize;) t.push(t[t.length - 1] + this.options.tickSize);
10987
+ t.push(this.options.max);
10988
+ }
10989
+ return t.map((t, n) => ({
10990
+ value: t,
10991
+ key: n,
10992
+ percentage: this.getPercentageForValue(t)
10993
+ }));
10994
+ }, this.getSteps = () => {
10995
+ let t = sortNumList(this.tempValues || this.options.values);
10996
+ return [...t, this.options.max].map((n, i) => {
10997
+ let s = t[i - 1], c = s === void 0 ? this.options.min : s, l = this.getPercentageForValue(c);
10998
+ return {
10999
+ left: l,
11000
+ width: this.getPercentageForValue(n) - l
11001
+ };
11002
+ });
11003
+ }, this.handles = () => (this.tempValues || this.options.values).map((t, n) => ({
11004
+ value: t,
11005
+ isActive: n === this.activeHandleIndex,
11006
+ onKeyDownHandler: (t) => {
11007
+ this.handleKeyDown(t, n);
11008
+ },
11009
+ onMouseDownHandler: (t) => {
11010
+ this.handlePress(t, n);
11011
+ },
11012
+ onTouchStart: (t) => {
11013
+ this.handlePress(t, n);
11014
+ }
11015
+ })), this.setOptions(t);
11016
+ }
11017
+ setOptions(t) {
11018
+ Object.entries(t).forEach(([n, i]) => {
11019
+ i === void 0 && delete t[n];
11020
+ }), this.options = {
11021
+ debug: !1,
11022
+ tickSize: 10,
11023
+ interpolator: linearInterpolator,
11024
+ onChange: () => {},
11025
+ ...t
11026
+ };
11027
+ }
11028
+ }, useIsomorphicLayoutEffect = typeof window < "u" ? React.useLayoutEffect : React.useEffect;
11029
+ function useRanger(n) {
11030
+ let i = React.useReducer(() => ({}), {})[1], s = {
11031
+ ...n,
11032
+ rerender: i,
11033
+ onChange: (t) => {
11034
+ i(), n.onChange?.(t);
11035
+ }
11036
+ }, [c] = React.useState(() => new Ranger(s));
11037
+ return c.setOptions(s), useIsomorphicLayoutEffect(() => c._willUpdate()), c;
11038
+ }
11039
+ const TooltipRootContext = /* @__PURE__ */ React.createContext(void 0);
11040
+ process.env.NODE_ENV !== "production" && (TooltipRootContext.displayName = "TooltipRootContext");
11041
+ function useTooltipRootContext(n) {
11042
+ let i = React.useContext(TooltipRootContext);
11043
+ if (i === void 0 && !n) throw Error(process.env.NODE_ENV === "production" ? formatErrorMessage(72) : "Base UI: TooltipRootContext is missing. Tooltip parts must be placed within <Tooltip.Root>.");
11044
+ return i;
11045
+ }
11046
+ var selectors = {
11047
+ ...popupStoreSelectors,
11048
+ disabled: createSelector((t) => t.disabled),
11049
+ instantType: createSelector((t) => t.instantType),
11050
+ isInstantPhase: createSelector((t) => t.isInstantPhase),
11051
+ trackCursorAxis: createSelector((t) => t.trackCursorAxis),
11052
+ disableHoverablePopup: createSelector((t) => t.disableHoverablePopup),
11053
+ lastOpenChangeReason: createSelector((t) => t.openChangeReason),
11054
+ closeDelay: createSelector((t) => t.closeDelay)
11055
+ }, TooltipStore = class n extends ReactStore {
11056
+ constructor(n) {
11057
+ super({
11058
+ ...createInitialState(),
11059
+ ...n
11060
+ }, {
11061
+ popupRef: /* @__PURE__ */ React.createRef(),
11062
+ onOpenChange: void 0,
11063
+ onOpenChangeComplete: void 0,
11064
+ triggerElements: new PopupTriggerMap()
11065
+ }, selectors);
11066
+ }
11067
+ setOpen = (t, n) => {
11068
+ let i = n.reason, s = i === triggerHover, c = t && i === "trigger-focus", l = !t && (i === "trigger-press" || i === "escape-key");
11069
+ if (n.preventUnmountOnClose = () => {
11070
+ this.set("preventUnmountingOnClose", !0);
11071
+ }, this.context.onOpenChange?.(t, n), n.isCanceled) return;
11072
+ let u = () => {
11073
+ let s = {
11074
+ open: t,
11075
+ openChangeReason: i
11076
+ };
11077
+ c ? s.instantType = "focus" : l ? s.instantType = "dismiss" : i === "trigger-hover" && (s.instantType = void 0);
11078
+ let u = n.trigger?.id ?? null;
11079
+ (u || t) && (s.activeTriggerId = u, s.activeTriggerElement = n.trigger ?? null), this.update(s);
11080
+ };
11081
+ s ? ReactDOM.flushSync(u) : u();
11082
+ };
11083
+ static useStore(t, i) {
11084
+ let s = useRefWithInit(() => t ?? new n(i)).current, c = useSyncedFloatingRootContext({
11085
+ popupStore: s,
11086
+ onOpenChange: s.setOpen
11087
+ });
11088
+ return s.state.floatingRootContext = c, s;
11089
+ }
11090
+ };
11091
+ function createInitialState() {
11092
+ return {
11093
+ ...createInitialPopupStoreState(),
11094
+ disabled: !1,
11095
+ instantType: void 0,
11096
+ isInstantPhase: !1,
11097
+ trackCursorAxis: "none",
11098
+ disableHoverablePopup: !1,
11099
+ openChangeReason: null,
11100
+ closeDelay: 0
11101
+ };
11102
+ }
11103
+ function TooltipRoot(n) {
11104
+ let { disabled: i = !1, defaultOpen: s = !1, open: c, disableHoverablePopup: l = !1, trackCursorAxis: u = "none", actionsRef: d, onOpenChange: f, onOpenChangeComplete: m, handle: h, triggerId: g, defaultTriggerId: _ = null, children: v } = n, y = TooltipStore.useStore(h?.store, {
11105
+ open: c ?? s,
11106
+ activeTriggerId: g === void 0 ? _ : g
11107
+ });
11108
+ y.useControlledProp("open", c, s), y.useControlledProp("activeTriggerId", g, _), y.useContextCallback("onOpenChange", f), y.useContextCallback("onOpenChangeComplete", m);
11109
+ let b = y.useState("open"), x = y.useState("activeTriggerId"), S = y.useState("payload");
11110
+ y.useSyncedValues({
11111
+ trackCursorAxis: u,
11112
+ disableHoverablePopup: l
11113
+ });
11114
+ let C = !i && b;
11115
+ useIsoLayoutEffect(() => {
11116
+ b && i && y.setOpen(!1, createChangeEventDetails("disabled"));
11117
+ }, [
11118
+ b,
10995
11119
  i,
10996
11120
  y
10997
11121
  ]), y.useSyncedValue("disabled", i), useImplicitActiveTrigger(y);
@@ -11053,33 +11177,33 @@ function useTooltipProviderContext() {
11053
11177
  const TooltipTrigger$1 = /* @__PURE__ */ React.forwardRef(function(n, i) {
11054
11178
  let { className: s, render: c, handle: l, payload: u, disabled: d, delay: f, closeDelay: m, id: h, ...g } = n, _ = useTooltipRootContext(!0), v = l?.store ?? _;
11055
11179
  if (!v) throw Error(process.env.NODE_ENV === "production" ? formatErrorMessage(82) : "Base UI: <Tooltip.Trigger> must be either used within a <Tooltip.Root> component or provided with a handle.");
11056
- let y = useBaseUiId(h), x = v.useState("isTriggerActive", y), S = v.useState("floatingRootContext"), C = v.useState("isOpenedByTrigger", y), w = React.useRef(null), T = f ?? 600, E = m ?? 0, { registerTrigger: D, isMountedByThisTrigger: O } = useTriggerDataForwarding(y, w, v, {
11180
+ let y = useBaseUiId(h), b = v.useState("isTriggerActive", y), x = v.useState("floatingRootContext"), S = v.useState("isOpenedByTrigger", y), C = React.useRef(null), w = f ?? 600, T = m ?? 0, { registerTrigger: E, isMountedByThisTrigger: D } = useTriggerDataForwarding(y, C, v, {
11057
11181
  payload: u,
11058
- closeDelay: E
11059
- }), k = useTooltipProviderContext(), { delayRef: A, isInstantPhase: j, hasProvider: M } = useDelayGroup(S, { open: C });
11182
+ closeDelay: T
11183
+ }), k = useTooltipProviderContext(), { delayRef: A, isInstantPhase: j, hasProvider: M } = useDelayGroup(x, { open: S });
11060
11184
  v.useSyncedValue("isInstantPhase", j);
11061
- let N = v.useState("disabled"), P = d ?? N, F = v.useState("trackCursorAxis"), I = v.useState("disableHoverablePopup"), L = useHoverReferenceInteraction(S, {
11185
+ let N = v.useState("disabled"), P = d ?? N, F = v.useState("trackCursorAxis"), I = v.useState("disableHoverablePopup"), L = useHoverReferenceInteraction(x, {
11062
11186
  enabled: !P,
11063
11187
  mouseOnly: !0,
11064
11188
  move: !1,
11065
11189
  handleClose: !I && F !== "both" ? safePolygon() : null,
11066
11190
  restMs() {
11067
- let t = k?.delay, n = typeof A.current == "object" ? A.current.open : void 0, i = T;
11068
- return M && (i = n === 0 ? 0 : f ?? t ?? T), i;
11191
+ let t = k?.delay, n = typeof A.current == "object" ? A.current.open : void 0, i = w;
11192
+ return M && (i = n === 0 ? 0 : f ?? t ?? w), i;
11069
11193
  },
11070
11194
  delay() {
11071
- let t = typeof A.current == "object" ? A.current.close : void 0, n = E;
11195
+ let t = typeof A.current == "object" ? A.current.close : void 0, n = T;
11072
11196
  return m == null && M && (n = t), { close: n };
11073
11197
  },
11074
- triggerElementRef: w,
11075
- isActiveTrigger: x
11076
- }), R = React.useMemo(() => ({ open: C }), [C]), z = v.useState("triggerProps", O);
11198
+ triggerElementRef: C,
11199
+ isActiveTrigger: b
11200
+ }), R = React.useMemo(() => ({ open: S }), [S]), z = v.useState("triggerProps", D);
11077
11201
  return useRenderElement("button", n, {
11078
11202
  state: R,
11079
11203
  ref: [
11080
11204
  i,
11081
- D,
11082
- w
11205
+ E,
11206
+ C
11083
11207
  ],
11084
11208
  props: [
11085
11209
  L,
@@ -11328,100 +11452,100 @@ function useAnchorPositioning(n) {
11328
11452
  domReferenceElement: null
11329
11453
  });
11330
11454
  }, [b, y]);
11331
- let fh = React.useMemo(() => ({
11455
+ let $ = React.useMemo(() => ({
11332
11456
  elementResize: !_ && typeof ResizeObserver < "u",
11333
11457
  layoutShift: !_ && typeof IntersectionObserver < "u"
11334
- }), [_]), { refs: ph, elements: $, x: mh, y: hh, middlewareData: gh, update: _h, placement: vh, context: yh, isPositioned: bh, floatingStyles: xh } = useFloating({
11458
+ }), [_]), { refs: yh, elements: bh, x: xh, y: Sh, middlewareData: Ch, update: wh, placement: Th, context: Eh, isPositioned: Dh, floatingStyles: Oh } = useFloating({
11335
11459
  rootContext: y,
11336
11460
  placement: R,
11337
11461
  middleware: J,
11338
11462
  strategy: s,
11339
- whileElementsMounted: v ? void 0 : (...t) => autoUpdate(...t, fh),
11463
+ whileElementsMounted: v ? void 0 : (...t) => autoUpdate(...t, $),
11340
11464
  nodeId: C,
11341
11465
  externalTree: E
11342
- }), { sideX: Sh, sideY: Ch } = gh.adaptiveOrigin || DEFAULT_SIDES, wh = bh ? s : "fixed", Th = React.useMemo(() => w ? {
11343
- position: wh,
11344
- [Sh]: mh,
11345
- [Ch]: hh
11466
+ }), { sideX: kh, sideY: Ah } = Ch.adaptiveOrigin || DEFAULT_SIDES, jh = Dh ? s : "fixed", Mh = React.useMemo(() => w ? {
11467
+ position: jh,
11468
+ [kh]: xh,
11469
+ [Ah]: Sh
11346
11470
  } : {
11347
- position: wh,
11348
- ...xh
11471
+ position: jh,
11472
+ ...Oh
11349
11473
  }, [
11350
11474
  w,
11351
- wh,
11475
+ jh,
11476
+ kh,
11477
+ xh,
11478
+ Ah,
11352
11479
  Sh,
11353
- mh,
11354
- Ch,
11355
- hh,
11356
- xh
11357
- ]), Eh = React.useRef(null);
11480
+ Oh
11481
+ ]), Nh = React.useRef(null);
11358
11482
  useIsoLayoutEffect(() => {
11359
11483
  if (!b) return;
11360
11484
  let t = F.current, n = typeof t == "function" ? t() : t, i = (isRef(n) ? n.current : n) || null;
11361
- i !== Eh.current && (ph.setPositionReference(i), Eh.current = i);
11485
+ i !== Nh.current && (yh.setPositionReference(i), Nh.current = i);
11362
11486
  }, [
11363
11487
  b,
11364
- ph,
11488
+ yh,
11365
11489
  P,
11366
11490
  F
11367
11491
  ]), React.useEffect(() => {
11368
11492
  if (!b) return;
11369
11493
  let t = F.current;
11370
- typeof t != "function" && isRef(t) && t.current !== Eh.current && (ph.setPositionReference(t.current), Eh.current = t.current);
11494
+ typeof t != "function" && isRef(t) && t.current !== Nh.current && (yh.setPositionReference(t.current), Nh.current = t.current);
11371
11495
  }, [
11372
11496
  b,
11373
- ph,
11497
+ yh,
11374
11498
  P,
11375
11499
  F
11376
11500
  ]), React.useEffect(() => {
11377
- if (v && b && $.domReference && $.floating) return autoUpdate($.domReference, $.floating, _h, fh);
11501
+ if (v && b && bh.domReference && bh.floating) return autoUpdate(bh.domReference, bh.floating, wh, $);
11378
11502
  }, [
11379
11503
  v,
11380
11504
  b,
11381
- $,
11382
- _h,
11383
- fh
11505
+ bh,
11506
+ wh,
11507
+ $
11384
11508
  ]);
11385
- let Dh = getSide(vh), Oh = getLogicalSide(c, Dh, I), kh = getAlignment(vh) || "center", Ah = !!gh.hide?.referenceHidden;
11509
+ let Ph = getSide(Th), Fh = getLogicalSide(c, Ph, I), Ih = getAlignment(Th) || "center", Lh = !!Ch.hide?.referenceHidden;
11386
11510
  useIsoLayoutEffect(() => {
11387
- T && b && bh && O(Dh);
11511
+ T && b && Dh && O(Ph);
11388
11512
  }, [
11389
11513
  T,
11390
11514
  b,
11391
- bh,
11392
- Dh
11515
+ Dh,
11516
+ Ph
11393
11517
  ]);
11394
- let jh = React.useMemo(() => ({
11518
+ let Rh = React.useMemo(() => ({
11395
11519
  position: "absolute",
11396
- top: gh.arrow?.y,
11397
- left: gh.arrow?.x
11398
- }), [gh.arrow]), Mh = gh.arrow?.centerOffset !== 0;
11520
+ top: Ch.arrow?.y,
11521
+ left: Ch.arrow?.x
11522
+ }), [Ch.arrow]), zh = Ch.arrow?.centerOffset !== 0;
11399
11523
  return React.useMemo(() => ({
11400
- positionerStyles: Th,
11401
- arrowStyles: jh,
11524
+ positionerStyles: Mh,
11525
+ arrowStyles: Rh,
11402
11526
  arrowRef: G,
11403
- arrowUncentered: Mh,
11404
- side: Oh,
11405
- align: kh,
11406
- physicalSide: Dh,
11407
- anchorHidden: Ah,
11408
- refs: ph,
11409
- context: yh,
11410
- isPositioned: bh,
11411
- update: _h
11527
+ arrowUncentered: zh,
11528
+ side: Fh,
11529
+ align: Ih,
11530
+ physicalSide: Ph,
11531
+ anchorHidden: Lh,
11532
+ refs: yh,
11533
+ context: Eh,
11534
+ isPositioned: Dh,
11535
+ update: wh
11412
11536
  }), [
11413
- Th,
11414
- jh,
11415
- G,
11416
11537
  Mh,
11417
- Oh,
11418
- kh,
11419
- Dh,
11420
- Ah,
11421
- ph,
11538
+ Rh,
11539
+ G,
11540
+ zh,
11541
+ Fh,
11542
+ Ih,
11543
+ Ph,
11544
+ Lh,
11422
11545
  yh,
11423
- bh,
11424
- _h
11546
+ Eh,
11547
+ Dh,
11548
+ wh
11425
11549
  ]);
11426
11550
  }
11427
11551
  function isRef(t) {
@@ -11694,27 +11818,17 @@ const Tooltip = (t) => {
11694
11818
  }) }), n[3] = i, n[4] = s, n[5] = c) : c = n[5], c;
11695
11819
  };
11696
11820
  var import_compiler_runtime$8 = require_compiler_runtime();
11697
- const TooltipTrigger = (t) => {
11698
- let n = (0, import_compiler_runtime$8.c)(6), i, s;
11699
- n[0] === t ? (i = n[1], s = n[2]) : ({children: i, ...s} = t, n[0] = t, n[1] = i, n[2] = s);
11700
- let c;
11701
- return n[3] !== i || n[4] !== s ? (c = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TooltipTrigger$1, {
11702
- ...s,
11703
- children: i
11704
- }), n[3] = i, n[4] = s, n[5] = c) : c = n[5], c;
11705
- };
11706
- var import_compiler_runtime$7 = require_compiler_runtime();
11707
11821
  const TooltipContent = (t) => {
11708
- let n = (0, import_compiler_runtime$7.c)(11), i, s, c;
11822
+ let n = (0, import_compiler_runtime$8.c)(11), i, s, c;
11709
11823
  n[0] === t ? (i = n[1], s = n[2], c = n[3]) : ({className: s, children: i, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c);
11710
11824
  let l;
11711
- n[4] === s ? l = n[5] : (l = cn("bg-surface-container-high origin-(--transform-origin) px-xs py-3xs animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-fit rounded-md text-sm text-balance", s), n[4] = s, n[5] = l);
11825
+ n[4] === s ? l = n[5] : (l = cn("fade-in-0 zoom-in-95 data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-fit origin-(--transform-origin) animate-in text-balance rounded-md bg-surface-container-high px-xs py-3xs text-sm data-[state=closed]:animate-out", s), n[4] = s, n[5] = l);
11712
11826
  let u;
11713
11827
  n[6] === Symbol.for("react.memo_cache_sentinel") ? (u = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TooltipArrow, {
11714
- className: "data-[side=bottom]:top-[-8px] data-[side=left]:right-[-13px] data-[side=left]:rotate-90 data-[side=right]:left-[-13px] data-[side=right]:-rotate-90 data-[side=top]:bottom-[-8px] data-[side=top]:rotate-180",
11828
+ className: "data-[side=bottom]:top-[-8px] data-[side=left]:right-[-13px] data-[side=top]:bottom-[-8px] data-[side=right]:left-[-13px] data-[side=left]:rotate-90 data-[side=right]:-rotate-90 data-[side=top]:rotate-180",
11715
11829
  children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(o, {
11716
- weight: "fill",
11717
- className: "fill-surface-container-high "
11830
+ className: "fill-surface-container-high",
11831
+ weight: "fill"
11718
11832
  })
11719
11833
  }), n[6] = u) : u = n[6];
11720
11834
  let d;
@@ -11726,183 +11840,68 @@ const TooltipContent = (t) => {
11726
11840
  children: [u, i]
11727
11841
  })
11728
11842
  }) }), n[7] = i, n[8] = c, n[9] = l, n[10] = d) : d = n[10], d;
11843
+ };
11844
+ var import_compiler_runtime$7 = require_compiler_runtime();
11845
+ const TooltipTrigger = (t) => {
11846
+ let n = (0, import_compiler_runtime$7.c)(6), i, s;
11847
+ n[0] === t ? (i = n[1], s = n[2]) : ({children: i, ...s} = t, n[0] = t, n[1] = i, n[2] = s);
11848
+ let c;
11849
+ return n[3] !== i || n[4] !== s ? (c = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TooltipTrigger$1, {
11850
+ ...s,
11851
+ children: i
11852
+ }), n[3] = i, n[4] = s, n[5] = c) : c = n[5], c;
11729
11853
  }, SliderHandle = ({ sliderInstance: t, isActive: n, onKeyDownHandler: i, onMouseDownHandler: s, onTouchStart: c, value: l, className: u, children: d, ref: m, ...h }) => {
11730
11854
  let [g, _] = useState(!1);
11731
11855
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Tooltip, {
11732
11856
  open: n || g,
11733
11857
  trackCursorAxis: "x",
11734
11858
  children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(TooltipTrigger, { render: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", {
11859
+ "aria-valuemax": t.options.max,
11860
+ "aria-valuemin": t.options.min,
11861
+ "aria-valuenow": l,
11862
+ className: cn("absolute top-1/2 aspect-square -translate-x-1/2 -translate-y-1/2 rounded-full border-2 border-primary bg-surface-container outline-none transition-[width,height,border] hover:cursor-pointer hover:border-secondary active:border-secondary", n ? "size-md shadow-4-shadow" : "size-sm shadow-1-shadow", u),
11735
11863
  onKeyDown: i,
11736
11864
  onMouseDown: s,
11737
- onTouchStart: c,
11738
11865
  onMouseEnter: () => _(!0),
11739
11866
  onMouseLeave: () => _(!1),
11867
+ onTouchStart: c,
11868
+ ref: m,
11740
11869
  role: "slider",
11741
- "aria-valuemin": t.options.min,
11742
- "aria-valuemax": t.options.max,
11743
- "aria-valuenow": l,
11744
11870
  style: {
11745
11871
  left: `${t.getPercentageForValue(l)}%`,
11746
11872
  zIndex: n ? "1" : "0"
11747
11873
  },
11748
- className: cn("absolute top-1/2 -translate-x-1/2 -translate-y-1/2 rounded-full outline-none border-2 border-primary bg-surface-container hover:cursor-pointer active:border-secondary hover:border-secondary transition-[width,height,border] aspect-square", n ? "size-md shadow-4-shadow" : "size-sm shadow-1-shadow", u),
11749
- ref: m,
11750
11874
  ...h,
11751
11875
  children: d
11752
11876
  }) }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TooltipContent, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: l }) })]
11753
11877
  });
11754
11878
  }, SliderSegment = ({ index: t, steps: n, left: i, width: s, className: c, children: l, ref: u, ...d }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
11755
- className: cn("absolute bg-primary h-full rounded-full inset-shadow-1-shadow", c),
11879
+ className: cn("absolute inset-shadow-1-shadow h-full rounded-full bg-primary", c),
11880
+ ref: u,
11756
11881
  style: {
11757
11882
  background: `${t === n - 1 ? "transparent" : "var(--color-primary)"}`,
11758
11883
  left: `${i}%`,
11759
11884
  width: `${s}%`
11760
11885
  },
11761
- ref: u,
11762
11886
  ...d,
11763
11887
  children: l
11764
- }), SliderTickLabel = ({ className: t, children: n, ref: i, ...s }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
11765
- className: cn("absolute text-[0.6rem] top-full -translate-x-1/2 translate-y-[1.2rem] whitespace-nowrap style-text-default--1 text-on-surface-variant", t),
11766
- ref: i,
11767
- ...s,
11768
- children: n
11769
11888
  }), SliderTick = ({ percentage: t, className: n, children: i, ref: s, ...c }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
11770
11889
  className: cn("absolute top-2xs -translate-x-1/2", n),
11771
11890
  ref: s,
11772
11891
  ...c,
11773
11892
  style: { left: `${t}%` },
11774
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "absolute bg-on-surface-variant rounded-full left-0 h-2xs w-[2px] -translate-x-1/2 translate-y-[0.7rem]" }), i]
11893
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "absolute left-0 h-2xs w-[2px] -translate-x-1/2 translate-y-[0.7rem] rounded-full bg-on-surface-variant" }), i]
11894
+ }), SliderTickLabel = ({ className: t, children: n, ref: i, ...s }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
11895
+ className: cn("style-text-default--1 absolute top-full -translate-x-1/2 translate-y-[1.2rem] whitespace-nowrap text-[0.6rem] text-on-surface-variant", t),
11896
+ ref: i,
11897
+ ...s,
11898
+ children: n
11775
11899
  }), SliderTrack = ({ className: t, children: n, sliderRef: i, ...s }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
11776
- className: cn("relative h-2xs inset-shadow-1-shadow rounded-full bg-surface-dim grow", t),
11900
+ className: cn("relative inset-shadow-1-shadow h-2xs grow rounded-full bg-surface-dim", t),
11777
11901
  ref: i,
11778
11902
  ...s,
11779
11903
  children: n
11780
- });
11781
- var getBoundingClientRect = (t) => {
11782
- let n = t.getBoundingClientRect();
11783
- return {
11784
- left: Math.ceil(n.left),
11785
- width: Math.ceil(n.width)
11786
- };
11787
- }, sortNumList = (t) => [...t].map(Number).sort((t, n) => t - n), linearInterpolator = {
11788
- getPercentageForValue: (t, n, i) => Math.max(0, Math.min(100, (t - n) / (i - n) * 100)),
11789
- getValueForClientX: (t, n, i, s) => {
11790
- let { left: c, width: l } = n, u = (t - c) / l;
11791
- return (s - i) * u + i;
11792
- }
11793
- }, Ranger = class {
11794
- constructor(t) {
11795
- this.sortedValues = [], this.rangerElement = null, this._willUpdate = () => {
11796
- let t = this.options.getRangerElement();
11797
- this.rangerElement !== t && (this.rangerElement = t);
11798
- }, this.getValueForClientX = (t) => {
11799
- let n = getBoundingClientRect(this.rangerElement);
11800
- return this.options.interpolator.getValueForClientX(t, n, this.options.min, this.options.max);
11801
- }, this.getNextStep = (t, n) => {
11802
- let { min: i, max: s } = this.options;
11803
- if ("steps" in this.options) {
11804
- let { steps: i } = this.options, s = i.indexOf(t) + n;
11805
- return s >= 0 && s < i.length ? i[s] : t;
11806
- } else {
11807
- let c = t + this.options.stepSize * n;
11808
- return c >= i && c <= s ? c : t;
11809
- }
11810
- }, this.roundToStep = (t) => {
11811
- let { min: n, max: i } = this.options, s = n, c = i;
11812
- if ("steps" in this.options) this.options.steps.forEach((n) => {
11813
- n <= t && n > s && (s = n), n >= t && n < c && (c = n);
11814
- });
11815
- else {
11816
- let { stepSize: n } = this.options;
11817
- for (; s < t && s + n < t;) s += n;
11818
- c = Math.min(s + n, i);
11819
- }
11820
- return t - s < c - t ? s : c;
11821
- }, this.handleDrag = (t) => {
11822
- if (this.activeHandleIndex === void 0) return;
11823
- let n = t.type === "touchmove" ? t.changedTouches[0].clientX : t.clientX, i = this.getValueForClientX(n), s = this.roundToStep(i);
11824
- this.sortedValues = [
11825
- ...this.options.values.slice(0, this.activeHandleIndex),
11826
- s,
11827
- ...this.options.values.slice(this.activeHandleIndex + 1)
11828
- ], this.options.onDrag ? this.options.onDrag(this) : (this.tempValues = this.sortedValues, this.options.rerender());
11829
- }, this.handleKeyDown = (t, n) => {
11830
- let { values: i } = this.options;
11831
- if (t.keyCode === 37 || t.keyCode === 39) {
11832
- this.activeHandleIndex = n;
11833
- let s = t.keyCode === 37 ? -1 : 1, c = this.getNextStep(i[n], s);
11834
- this.sortedValues = sortNumList([
11835
- ...i.slice(0, n),
11836
- c,
11837
- ...i.slice(n + 1)
11838
- ]), this.options.onChange && this.options.onChange(this);
11839
- }
11840
- }, this.handlePress = (t, n) => {
11841
- this.activeHandleIndex = n, this.options.rerender();
11842
- let i = () => {
11843
- let { tempValues: t, handleDrag: n } = this;
11844
- document.removeEventListener("mousemove", n), document.removeEventListener("touchmove", n), document.removeEventListener("mouseup", i), document.removeEventListener("touchend", i), this.sortedValues = sortNumList(t || this.options.values), this.options.onChange && this.options.onChange(this), this.options.onDrag && this.options.onDrag(this), this.activeHandleIndex = void 0, this.tempValues = void 0, this.options.rerender();
11845
- }, { handleDrag: s } = this;
11846
- document.addEventListener("mousemove", s), document.addEventListener("touchmove", s), document.addEventListener("mouseup", i), document.addEventListener("touchend", i);
11847
- }, this.getPercentageForValue = (t) => this.options.interpolator.getPercentageForValue(t, this.options.min, this.options.max), this.getTicks = () => {
11848
- let t = [];
11849
- if (this.options.ticks) t = [...this.options.ticks];
11850
- else if ("steps" in this.options) t = [...this.options.steps];
11851
- else {
11852
- for (t = [this.options.min]; t[t.length - 1] < this.options.max - this.options.tickSize;) t.push(t[t.length - 1] + this.options.tickSize);
11853
- t.push(this.options.max);
11854
- }
11855
- return t.map((t, n) => ({
11856
- value: t,
11857
- key: n,
11858
- percentage: this.getPercentageForValue(t)
11859
- }));
11860
- }, this.getSteps = () => {
11861
- let t = sortNumList(this.tempValues || this.options.values);
11862
- return [...t, this.options.max].map((n, i) => {
11863
- let s = t[i - 1], c = s === void 0 ? this.options.min : s, l = this.getPercentageForValue(c);
11864
- return {
11865
- left: l,
11866
- width: this.getPercentageForValue(n) - l
11867
- };
11868
- });
11869
- }, this.handles = () => (this.tempValues || this.options.values).map((t, n) => ({
11870
- value: t,
11871
- isActive: n === this.activeHandleIndex,
11872
- onKeyDownHandler: (t) => {
11873
- this.handleKeyDown(t, n);
11874
- },
11875
- onMouseDownHandler: (t) => {
11876
- this.handlePress(t, n);
11877
- },
11878
- onTouchStart: (t) => {
11879
- this.handlePress(t, n);
11880
- }
11881
- })), this.setOptions(t);
11882
- }
11883
- setOptions(t) {
11884
- Object.entries(t).forEach(([n, i]) => {
11885
- i === void 0 && delete t[n];
11886
- }), this.options = {
11887
- debug: !1,
11888
- tickSize: 10,
11889
- interpolator: linearInterpolator,
11890
- onChange: () => {},
11891
- ...t
11892
- };
11893
- }
11894
- }, useIsomorphicLayoutEffect = typeof window < "u" ? React.useLayoutEffect : React.useEffect;
11895
- function useRanger(n) {
11896
- let i = React.useReducer(() => ({}), {})[1], s = {
11897
- ...n,
11898
- rerender: i,
11899
- onChange: (t) => {
11900
- i(), n.onChange?.(t);
11901
- }
11902
- }, [c] = React.useState(() => new Ranger(s));
11903
- return c.setOptions(s), useIsomorphicLayoutEffect(() => c._willUpdate()), c;
11904
- }
11905
- const Slider = ({ leadingIcon: t, trailingIcon: n, min: i, max: s, stepSize: c, defaultValues: l, showTickLabels: u, label: m, className: h, ref: g, ..._ }) => {
11904
+ }), Slider = ({ leadingIcon: t, trailingIcon: n, min: i, max: s, stepSize: c, defaultValues: l, showTickLabels: u, label: m, className: h, ref: g, ..._ }) => {
11906
11905
  let v = useRef(null), [y, b] = useState(l || [50]), x = useRanger({
11907
11906
  getRangerElement: () => v.current,
11908
11907
  values: y,
@@ -11914,14 +11913,14 @@ const Slider = ({ leadingIcon: t, trailingIcon: n, min: i, max: s, stepSize: c,
11914
11913
  }
11915
11914
  });
11916
11915
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
11917
- ref: g,
11918
11916
  className: cn("space-y-2xs", h),
11917
+ ref: g,
11919
11918
  ..._,
11920
11919
  children: [m && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
11921
11920
  className: "style-text-default--1 text-on-surface-variant",
11922
11921
  children: m
11923
11922
  }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
11924
- className: "flex items-center w-full gap-sm",
11923
+ className: "flex w-full items-center gap-sm",
11925
11924
  children: [
11926
11925
  t && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(t, {
11927
11926
  className: "size-sm",
@@ -11936,16 +11935,16 @@ const Slider = ({ leadingIcon: t, trailingIcon: n, min: i, max: s, stepSize: c,
11936
11935
  }, n)),
11937
11936
  x.getSteps().map(({ left: t, width: n }, i) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SliderSegment, {
11938
11937
  index: i,
11939
- steps: x.getSteps().length,
11940
11938
  left: t,
11939
+ steps: x.getSteps().length,
11941
11940
  width: n
11942
11941
  }, i)),
11943
11942
  x.handles().map(({ isActive: t, onKeyDownHandler: n, onMouseDownHandler: i, onTouchStart: s, value: c }, l) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SliderHandle, {
11944
- sliderInstance: x,
11945
11943
  isActive: t,
11946
11944
  onKeyDownHandler: n,
11947
11945
  onMouseDownHandler: i,
11948
11946
  onTouchStart: s,
11947
+ sliderInstance: x,
11949
11948
  value: c
11950
11949
  }, l))
11951
11950
  ]
@@ -11973,85 +11972,85 @@ const stateAttributesMapping$2 = {
11973
11972
  return t ? { [SwitchRootDataAttributes.checked]: "" } : { [SwitchRootDataAttributes.unchecked]: "" };
11974
11973
  }
11975
11974
  }, SwitchRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
11976
- let { checked: s, className: c, defaultChecked: l, id: u, inputRef: d, name: f, nativeButton: m = !1, onCheckedChange: h, readOnly: g = !1, required: _ = !1, disabled: v = !1, render: y, uncheckedValue: b, ...x } = n, { clearErrors: S } = useFormContext(), { state: w, setTouched: T, setDirty: E, validityData: D, setFilled: O, setFocused: k, shouldValidateOnChange: A, validationMode: j, disabled: M, name: N, validation: P } = useFieldRootContext(), { labelId: F } = useLabelableContext(), I = M || v, R = N ?? f, z = useStableCallback(h), B = React.useRef(null), V = useMergedRefs(B, d, P.inputRef), H = React.useRef(null), U = useBaseUiId(), W = useLabelableId({
11975
+ let { checked: s, className: c, defaultChecked: l, id: u, inputRef: d, name: f, nativeButton: m = !1, onCheckedChange: h, readOnly: g = !1, required: _ = !1, disabled: v = !1, render: y, uncheckedValue: b, ...x } = n, { clearErrors: S } = useFormContext(), { state: C, setTouched: w, setDirty: T, validityData: E, setFilled: D, setFocused: O, shouldValidateOnChange: k, validationMode: A, disabled: M, name: N, validation: P } = useFieldRootContext(), { labelId: F } = useLabelableContext(), I = M || v, L = N ?? f, R = useStableCallback(h), z = React.useRef(null), B = useMergedRefs(z, d, P.inputRef), V = React.useRef(null), H = useBaseUiId(), U = useLabelableId({
11977
11976
  id: u,
11978
11977
  implicit: !1,
11979
- controlRef: H
11980
- }), [G, K] = useControlled({
11978
+ controlRef: V
11979
+ }), [W, K] = useControlled({
11981
11980
  controlled: s,
11982
11981
  default: !!l,
11983
11982
  name: "Switch",
11984
11983
  state: "checked"
11985
11984
  });
11986
11985
  useField({
11987
- id: U,
11986
+ id: H,
11988
11987
  commit: P.commit,
11989
- value: G,
11990
- controlRef: H,
11991
- name: R,
11992
- getValue: () => G
11988
+ value: W,
11989
+ controlRef: V,
11990
+ name: L,
11991
+ getValue: () => W
11993
11992
  }), useIsoLayoutEffect(() => {
11994
- B.current && O(B.current.checked);
11995
- }, [B, O]), useValueChanged(G, () => {
11996
- S(R), E(G !== D.initialValue), O(G), A() ? P.commit(G) : P.commit(G, !0);
11993
+ z.current && D(z.current.checked);
11994
+ }, [z, D]), useValueChanged(W, () => {
11995
+ S(L), T(W !== E.initialValue), D(W), k() ? P.commit(W) : P.commit(W, !0);
11997
11996
  });
11998
11997
  let { getButtonProps: q, buttonRef: J } = useButton({
11999
11998
  disabled: I,
12000
11999
  native: m
12001
12000
  }), Y = {
12002
- id: U,
12001
+ id: H,
12003
12002
  role: "switch",
12004
- "aria-checked": G,
12003
+ "aria-checked": W,
12005
12004
  "aria-readonly": g || void 0,
12006
12005
  "aria-labelledby": F,
12007
12006
  onFocus() {
12008
- I || k(!0);
12007
+ I || O(!0);
12009
12008
  },
12010
12009
  onBlur() {
12011
- let t = B.current;
12012
- !t || I || (T(!0), k(!1), j === "onBlur" && P.commit(t.checked));
12010
+ let t = z.current;
12011
+ !t || I || (w(!0), O(!1), A === "onBlur" && P.commit(t.checked));
12013
12012
  },
12014
12013
  onClick(t) {
12015
- g || I || (t.preventDefault(), B?.current?.click());
12014
+ g || I || (t.preventDefault(), z?.current?.click());
12016
12015
  }
12017
12016
  }, X = React.useMemo(() => mergeProps({
12018
- checked: G,
12017
+ checked: W,
12019
12018
  disabled: I,
12020
- id: W,
12021
- name: R,
12019
+ id: U,
12020
+ name: L,
12022
12021
  required: _,
12023
12022
  style: visuallyHidden,
12024
12023
  tabIndex: -1,
12025
12024
  type: "checkbox",
12026
12025
  "aria-hidden": !0,
12027
- ref: V,
12026
+ ref: B,
12028
12027
  onChange(t) {
12029
12028
  if (t.nativeEvent.defaultPrevented) return;
12030
12029
  let n = t.target.checked, i = createChangeEventDetails(none, t.nativeEvent);
12031
- z?.(n, i), !i.isCanceled && K(n);
12030
+ R?.(n, i), !i.isCanceled && K(n);
12032
12031
  },
12033
12032
  onFocus() {
12034
- H.current?.focus();
12033
+ V.current?.focus();
12035
12034
  }
12036
12035
  }, P.getInputValidationProps), [
12037
- G,
12038
- I,
12039
- V,
12040
12036
  W,
12037
+ I,
12038
+ B,
12039
+ U,
12040
+ L,
12041
12041
  R,
12042
- z,
12043
12042
  _,
12044
12043
  K,
12045
12044
  P
12046
12045
  ]), Z = React.useMemo(() => ({
12047
- ...w,
12048
- checked: G,
12046
+ ...C,
12047
+ checked: W,
12049
12048
  disabled: I,
12050
12049
  readOnly: g,
12051
12050
  required: _
12052
12051
  }), [
12053
- w,
12054
- G,
12052
+ C,
12053
+ W,
12055
12054
  I,
12056
12055
  g,
12057
12056
  _
@@ -12059,7 +12058,7 @@ const stateAttributesMapping$2 = {
12059
12058
  state: Z,
12060
12059
  ref: [
12061
12060
  i,
12062
- H,
12061
+ V,
12063
12062
  J
12064
12063
  ],
12065
12064
  props: [
@@ -12074,9 +12073,9 @@ const stateAttributesMapping$2 = {
12074
12073
  value: Z,
12075
12074
  children: [
12076
12075
  Q,
12077
- !G && R && b !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("input", {
12076
+ !W && L && b !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("input", {
12078
12077
  type: "hidden",
12079
- name: R,
12078
+ name: L,
12080
12079
  value: b
12081
12080
  }),
12082
12081
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)("input", { ...X })
@@ -12102,9 +12101,9 @@ const Switch = (t) => {
12102
12101
  let n = (0, import_compiler_runtime$6.c)(18), i, s, c, l;
12103
12102
  n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4]) : ({label: s, className: i, ref: l, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l);
12104
12103
  let u;
12105
- n[5] === i ? u = n[6] : (u = cn("relative group transition-colors flex items-center h-[26px] w-[50px] rounded-full bg-surface-dim bg-size-[6.5rem_100%] inset-shadow-1-shadow p-0.5 ease-[cubic-bezier(0.26,0.75,0.38,0.45)] before:absolute before:rounded-full data-checked:bg-accent data-checked:active:bg-gray-500 outline-2 outline-transparent not-disabled:hover:outline-accent hover:cursor-pointer disabled:opacity-50 disabled:pointer-events-none", i), n[5] = i, n[6] = u);
12104
+ n[5] === i ? u = n[6] : (u = cn("group relative inset-shadow-1-shadow flex h-[26px] w-[50px] items-center rounded-full bg-size-[6.5rem_100%] bg-surface-dim p-0.5 outline-2 outline-transparent transition-colors ease-[cubic-bezier(0.26,0.75,0.38,0.45)] before:absolute before:rounded-full hover:cursor-pointer not-disabled:hover:outline-accent disabled:pointer-events-none disabled:opacity-50 data-checked:bg-accent data-checked:active:bg-gray-500", i), n[5] = i, n[6] = u);
12106
12105
  let d;
12107
- n[7] === Symbol.for("react.memo_cache_sentinel") ? (d = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SwitchThumb, { className: "size-[14px] data-checked:size-[18px] rounded-full bg-accent transition-transform duration-500 ease-[cubic-bezier(0.68,-0.55,0.27,1.55)] translate-x-[6px] shadow-xs data-checked:translate-x-[26px] data-checked:scale-[1.1] data-unchecked:bg-accent data-checked:bg-on-accent" }), n[7] = d) : d = n[7];
12106
+ n[7] === Symbol.for("react.memo_cache_sentinel") ? (d = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SwitchThumb, { className: "size-[14px] translate-x-[6px] rounded-full bg-accent shadow-xs transition-transform duration-500 ease-[cubic-bezier(0.68,-0.55,0.27,1.55)] data-checked:size-[18px] data-checked:translate-x-[26px] data-checked:scale-[1.1] data-checked:bg-on-accent data-unchecked:bg-accent" }), n[7] = d) : d = n[7];
12108
12107
  let f;
12109
12108
  n[8] !== c || n[9] !== l || n[10] !== u ? (f = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SwitchRoot, {
12110
12109
  className: u,
@@ -12180,7 +12179,7 @@ function CompositeList(n) {
12180
12179
  useIsoLayoutEffect(() => {
12181
12180
  f.forEach((t) => t(b));
12182
12181
  }, [f, b]);
12183
- let C = React.useMemo(() => ({
12182
+ let S = React.useMemo(() => ({
12184
12183
  register: v,
12185
12184
  unregister: y,
12186
12185
  subscribeMapChange: x,
@@ -12196,7 +12195,7 @@ function CompositeList(n) {
12196
12195
  d
12197
12196
  ]);
12198
12197
  return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(CompositeListContext.Provider, {
12199
- value: C,
12198
+ value: S,
12200
12199
  children: i
12201
12200
  });
12202
12201
  }
@@ -12621,25 +12620,25 @@ function isElementDisabled(t) {
12621
12620
  }
12622
12621
  var EMPTY_ARRAY$1 = [];
12623
12622
  function useCompositeRoot(n) {
12624
- let { itemSizes: i, cols: s = 1, loopFocus: c = !0, dense: l = !1, orientation: u = "both", direction: d, highlightedIndex: f, onHighlightedIndexChange: m, rootRef: h, enableHomeAndEndKeys: g = !1, stopEventPropagation: _ = !1, disabledIndices: v, modifierKeys: y = EMPTY_ARRAY$1 } = n, [b, x] = React.useState(0), S = s > 1, w = React.useRef(null), T = useMergedRefs(w, h), E = React.useRef([]), D = React.useRef(!1), O = f ?? b, k = useStableCallback((t, n = !1) => {
12623
+ let { itemSizes: i, cols: s = 1, loopFocus: c = !0, dense: l = !1, orientation: u = "both", direction: d, highlightedIndex: f, onHighlightedIndexChange: m, rootRef: h, enableHomeAndEndKeys: g = !1, stopEventPropagation: _ = !1, disabledIndices: v, modifierKeys: y = EMPTY_ARRAY$1 } = n, [b, x] = React.useState(0), S = s > 1, C = React.useRef(null), w = useMergedRefs(C, h), T = React.useRef([]), E = React.useRef(!1), D = f ?? b, O = useStableCallback((t, n = !1) => {
12625
12624
  if ((m ?? x)(t), n) {
12626
- let n = E.current[t];
12627
- scrollIntoViewIfNeeded(w.current, n, d, u);
12625
+ let n = T.current[t];
12626
+ scrollIntoViewIfNeeded(C.current, n, d, u);
12628
12627
  }
12629
- }), A = useStableCallback((t) => {
12630
- if (t.size === 0 || D.current) return;
12631
- D.current = !0;
12628
+ }), k = useStableCallback((t) => {
12629
+ if (t.size === 0 || E.current) return;
12630
+ E.current = !0;
12632
12631
  let n = Array.from(t.keys()), i = n.find((t) => t?.hasAttribute("data-composite-item-active")) ?? null, s = i ? n.indexOf(i) : -1;
12633
- s !== -1 && k(s), scrollIntoViewIfNeeded(w.current, i, d, u);
12634
- }), j = React.useMemo(() => ({
12632
+ s !== -1 && O(s), scrollIntoViewIfNeeded(C.current, i, d, u);
12633
+ }), A = React.useMemo(() => ({
12635
12634
  "aria-orientation": u === "both" ? void 0 : u,
12636
- ref: T,
12635
+ ref: w,
12637
12636
  onFocus(t) {
12638
- !w.current || !isNativeInput(t.target) || t.target.setSelectionRange(0, t.target.value.length ?? 0);
12637
+ !C.current || !isNativeInput(t.target) || t.target.setSelectionRange(0, t.target.value.length ?? 0);
12639
12638
  },
12640
12639
  onKeyDown(t) {
12641
12640
  let n = g ? ALL_KEYS : ARROW_KEYS;
12642
- if (!n.has(t.key) || isModifierKeySet(t, y) || !w.current) return;
12641
+ if (!n.has(t.key) || isModifierKeySet(t, y) || !C.current) return;
12643
12642
  let f = d === "rtl", m = f ? ARROW_LEFT : ARROW_RIGHT, h = {
12644
12643
  horizontal: m,
12645
12644
  vertical: ARROW_DOWN,
@@ -12653,21 +12652,21 @@ function useCompositeRoot(n) {
12653
12652
  let n = t.target.selectionStart, i = t.target.selectionEnd, s = t.target.value ?? "";
12654
12653
  if (n == null || t.shiftKey || n !== i || t.key !== x && n < s.length || t.key !== h && n > 0) return;
12655
12654
  }
12656
- let C = O, T = getMinListIndex(E, v), D = getMaxListIndex(E, v);
12655
+ let w = D, E = getMinListIndex(T, v), k = getMaxListIndex(T, v);
12657
12656
  if (S) {
12658
- let n = i || Array.from({ length: E.current.length }, () => ({
12657
+ let n = i || Array.from({ length: T.current.length }, () => ({
12659
12658
  width: 1,
12660
12659
  height: 1
12661
- })), d = createGridCellMap(n, s, l), m = d.findIndex((t) => t != null && !isListIndexDisabled(E, t, v)), h = d.reduce((t, n, i) => n != null && !isListIndexDisabled(E, n, v) ? i : t, -1);
12662
- C = d[getGridNavigatedIndex({ current: d.map((t) => t ? E.current[t] : null) }, {
12660
+ })), d = createGridCellMap(n, s, l), m = d.findIndex((t) => t != null && !isListIndexDisabled(T, t, v)), h = d.reduce((t, n, i) => n != null && !isListIndexDisabled(T, n, v) ? i : t, -1);
12661
+ w = d[getGridNavigatedIndex({ current: d.map((t) => t ? T.current[t] : null) }, {
12663
12662
  event: t,
12664
12663
  orientation: u,
12665
12664
  loopFocus: c,
12666
12665
  cols: s,
12667
- disabledIndices: getGridCellIndices([...v || E.current.map((t, n) => isListIndexDisabled(E, n) ? n : void 0), void 0], d),
12666
+ disabledIndices: getGridCellIndices([...v || T.current.map((t, n) => isListIndexDisabled(T, n) ? n : void 0), void 0], d),
12668
12667
  minIndex: m,
12669
12668
  maxIndex: h,
12670
- prevIndex: getGridCellIndexOfCorner(O > D ? T : O, n, d, s, t.key === "ArrowDown" ? "bl" : t.key === "ArrowRight" ? "tr" : "tl"),
12669
+ prevIndex: getGridCellIndexOfCorner(D > k ? E : D, n, d, s, t.key === "ArrowDown" ? "bl" : t.key === "ArrowRight" ? "tr" : "tl"),
12671
12670
  rtl: f
12672
12671
  })];
12673
12672
  }
@@ -12684,12 +12683,12 @@ function useCompositeRoot(n) {
12684
12683
  vertical: g ? VERTICAL_KEYS_WITH_EXTRA_KEYS : VERTICAL_KEYS,
12685
12684
  both: n
12686
12685
  }[u];
12687
- g && (t.key === "Home" ? C = T : t.key === "End" && (C = D)), C === O && (A.includes(t.key) || j.includes(t.key)) && (C = c && C === D && A.includes(t.key) ? T : c && C === T && j.includes(t.key) ? D : findNonDisabledListIndex(E, {
12688
- startingIndex: C,
12686
+ g && (t.key === "Home" ? w = E : t.key === "End" && (w = k)), w === D && (A.includes(t.key) || j.includes(t.key)) && (w = c && w === k && A.includes(t.key) ? E : c && w === E && j.includes(t.key) ? k : findNonDisabledListIndex(T, {
12687
+ startingIndex: w,
12689
12688
  decrement: j.includes(t.key),
12690
12689
  disabledIndices: v
12691
- })), C !== O && !isIndexOutOfListBounds(E, C) && (_ && t.stopPropagation(), M.has(t.key) && t.preventDefault(), k(C, !0), queueMicrotask(() => {
12692
- E.current[C]?.focus();
12690
+ })), w !== D && !isIndexOutOfListBounds(T, w) && (_ && t.stopPropagation(), M.has(t.key) && t.preventDefault(), O(w, !0), queueMicrotask(() => {
12691
+ T.current[w]?.focus();
12693
12692
  }));
12694
12693
  }
12695
12694
  }), [
@@ -12697,33 +12696,33 @@ function useCompositeRoot(n) {
12697
12696
  l,
12698
12697
  d,
12699
12698
  v,
12700
- E,
12699
+ T,
12701
12700
  g,
12702
- O,
12701
+ D,
12703
12702
  S,
12704
12703
  i,
12705
12704
  c,
12706
- T,
12705
+ w,
12707
12706
  y,
12708
- k,
12707
+ O,
12709
12708
  u,
12710
12709
  _
12711
12710
  ]);
12712
12711
  return React.useMemo(() => ({
12713
- props: j,
12714
- highlightedIndex: O,
12715
- onHighlightedIndexChange: k,
12716
- elementsRef: E,
12712
+ props: A,
12713
+ highlightedIndex: D,
12714
+ onHighlightedIndexChange: O,
12715
+ elementsRef: T,
12717
12716
  disabledIndices: v,
12718
- onMapChange: A,
12719
- relayKeyboardEvent: j.onKeyDown
12717
+ onMapChange: k,
12718
+ relayKeyboardEvent: A.onKeyDown
12720
12719
  }), [
12721
- j,
12720
+ A,
12721
+ D,
12722
12722
  O,
12723
- k,
12724
- E,
12723
+ T,
12725
12724
  v,
12726
- A
12725
+ k
12727
12726
  ]);
12728
12727
  }
12729
12728
  function isModifierKeySet(t, n) {
@@ -12872,11 +12871,43 @@ function useActivationDirectionDetector(n, i, s, c) {
12872
12871
  }
12873
12872
  const TabsOrientationContext = createContext("vertical");
12874
12873
  var import_compiler_runtime$5 = require_compiler_runtime();
12874
+ const Tabs = (t) => {
12875
+ let n = (0, import_compiler_runtime$5.c)(15), { className: i, ref: s, ...l } = t, [u, d] = useState(l.orientation ?? "vertical");
12876
+ if (useEffect(() => {
12877
+ let t = () => {
12878
+ window.innerWidth < 768 ? d("horizontal") : d(l.orientation ?? "vertical");
12879
+ };
12880
+ return t(), window.addEventListener("resize", t), () => window.removeEventListener("resize", t);
12881
+ }, [l.orientation]), l.orientation = u, l.orientation === "horizontal") {
12882
+ let t = l.orientation, c;
12883
+ n[0] === i ? c = n[1] : (c = cn("flex flex-wrap gap-4 overflow-auto", i), n[0] = i, n[1] = c);
12884
+ let u;
12885
+ n[2] !== l || n[3] !== s || n[4] !== c ? (u = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsRoot, {
12886
+ className: c,
12887
+ ref: s,
12888
+ ...l
12889
+ }), n[2] = l, n[3] = s, n[4] = c, n[5] = u) : u = n[5];
12890
+ let d;
12891
+ return n[6] !== l.orientation || n[7] !== u ? (d = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsOrientationContext.Provider, {
12892
+ value: t,
12893
+ children: u
12894
+ }), n[6] = l.orientation, n[7] = u, n[8] = d) : d = n[8], d;
12895
+ }
12896
+ let m;
12897
+ n[9] === i ? m = n[10] : (m = cn("flex flex-col gap-2 overflow-clip", i), n[9] = i, n[10] = m);
12898
+ let h;
12899
+ return n[11] !== l || n[12] !== s || n[13] !== m ? (h = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsRoot, {
12900
+ className: m,
12901
+ ref: s,
12902
+ ...l
12903
+ }), n[11] = l, n[12] = s, n[13] = m, n[14] = h) : h = n[14], h;
12904
+ };
12905
+ var import_compiler_runtime$4 = require_compiler_runtime();
12875
12906
  const TabsIndicator = (t) => {
12876
- let n = (0, import_compiler_runtime$5.c)(13), i, c;
12907
+ let n = (0, import_compiler_runtime$4.c)(13), i, c;
12877
12908
  if (n[0] === t ? (i = n[1], c = n[2]) : ({className: i, ...c} = t, n[0] = t, n[1] = i, n[2] = c), useContext(TabsOrientationContext) === "horizontal") {
12878
12909
  let t;
12879
- n[3] === i ? t = n[4] : (t = cn("absolute left-1/2 h-11 md:h-12 top-0 z-[-1] w-(--active-tab-width) translate-y-(--active-tab-top) -translate-x-1/2 rounded-2xl md:rounded-full bg-surface-brand-primary-default transition-all duration-300 ease-[cubic-bezier(0.68,-0.55,0.27,1.55)]", i), n[3] = i, n[4] = t);
12910
+ n[3] === i ? t = n[4] : (t = cn("absolute top-0 left-1/2 z-[-1] h-11 w-(--active-tab-width) -translate-x-1/2 translate-y-(--active-tab-top) rounded-2xl bg-surface-brand-primary-default transition-all duration-300 ease-[cubic-bezier(0.68,-0.55,0.27,1.55)] md:h-12 md:rounded-full", i), n[3] = i, n[4] = t);
12880
12911
  let s;
12881
12912
  return n[5] !== c || n[6] !== t ? (s = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsIndicator$1, {
12882
12913
  className: t,
@@ -12884,19 +12915,19 @@ const TabsIndicator = (t) => {
12884
12915
  }), n[5] = c, n[6] = t, n[7] = s) : s = n[7], s;
12885
12916
  }
12886
12917
  let l;
12887
- n[8] === i ? l = n[9] : (l = cn("absolute top-1/2 h-11 md:h-12 left-0 z-[-1] w-(--active-tab-width) translate-x-(--active-tab-left) -translate-y-1/2 rounded-full bg-surface-brand-primary-default transition-all duration-300 ease-[cubic-bezier(0.68,-0.55,0.27,1.55)]", i), n[8] = i, n[9] = l);
12918
+ n[8] === i ? l = n[9] : (l = cn("absolute top-1/2 left-0 z-[-1] h-11 w-(--active-tab-width) translate-x-(--active-tab-left) -translate-y-1/2 rounded-full bg-surface-brand-primary-default transition-all duration-300 ease-[cubic-bezier(0.68,-0.55,0.27,1.55)] md:h-12", i), n[8] = i, n[9] = l);
12888
12919
  let u;
12889
12920
  return n[10] !== c || n[11] !== l ? (u = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsIndicator$1, {
12890
12921
  className: l,
12891
12922
  ...c
12892
12923
  }), n[10] = c, n[11] = l, n[12] = u) : u = n[12], u;
12893
12924
  };
12894
- var import_compiler_runtime$4 = require_compiler_runtime();
12925
+ var import_compiler_runtime$3 = require_compiler_runtime();
12895
12926
  const TabsList = (t) => {
12896
- let n = (0, import_compiler_runtime$4.c)(13), i, c;
12927
+ let n = (0, import_compiler_runtime$3.c)(13), i, c;
12897
12928
  if (n[0] === t ? (i = n[1], c = n[2]) : ({className: i, ...c} = t, n[0] = t, n[1] = i, n[2] = c), useContext(TabsOrientationContext) === "horizontal") {
12898
12929
  let t;
12899
- n[3] === i ? t = n[4] : (t = cn("relative z-0 flex flex-col h-fit grow gap-2 p-2 bg-surface-neutral-primary-default rounded-3xl", i), n[3] = i, n[4] = t);
12930
+ n[3] === i ? t = n[4] : (t = cn("relative z-0 flex h-fit grow flex-col gap-2 rounded-3xl bg-surface-neutral-primary-default p-2", i), n[3] = i, n[4] = t);
12900
12931
  let s;
12901
12932
  return n[5] !== c || n[6] !== t ? (s = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsList$1, {
12902
12933
  className: t,
@@ -12904,69 +12935,37 @@ const TabsList = (t) => {
12904
12935
  }), n[5] = c, n[6] = t, n[7] = s) : s = n[7], s;
12905
12936
  }
12906
12937
  let l;
12907
- n[8] === i ? l = n[9] : (l = cn("relative z-0 flex gap-1 p-2 bg-surface-neutral-primary-default rounded-full", i), n[8] = i, n[9] = l);
12938
+ n[8] === i ? l = n[9] : (l = cn("relative z-0 flex gap-1 rounded-full bg-surface-neutral-primary-default p-2", i), n[8] = i, n[9] = l);
12908
12939
  let u;
12909
12940
  return n[10] !== c || n[11] !== l ? (u = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsList$1, {
12910
12941
  className: l,
12911
12942
  ...c
12912
12943
  }), n[10] = c, n[11] = l, n[12] = u) : u = n[12], u;
12913
12944
  };
12914
- var import_compiler_runtime$3 = require_compiler_runtime();
12945
+ var import_compiler_runtime$2 = require_compiler_runtime();
12915
12946
  const TabsPanel = (t) => {
12916
- let n = (0, import_compiler_runtime$3.c)(9), i, c;
12947
+ let n = (0, import_compiler_runtime$2.c)(9), i, c;
12917
12948
  n[0] === t ? (i = n[1], c = n[2]) : ({className: i, ...c} = t, n[0] = t, n[1] = i, n[2] = c);
12918
- let l = useContext(TabsOrientationContext) === "horizontal" ? "flex-1 min-h-0 h-full" : "grow", u;
12919
- n[3] !== i || n[4] !== l ? (u = cn("relative rounded-xl bg-surface-neutral-primary-default", l, "flex items-center justify-center p-4 overflow-auto", i), n[3] = i, n[4] = l, n[5] = u) : u = n[5];
12949
+ let l = useContext(TabsOrientationContext) === "horizontal" ? "h-full min-h-0 flex-1" : "grow", u;
12950
+ n[3] !== i || n[4] !== l ? (u = cn("relative rounded-xl bg-surface-neutral-primary-default", l, "flex items-center justify-center overflow-auto p-4", i), n[3] = i, n[4] = l, n[5] = u) : u = n[5];
12920
12951
  let d;
12921
12952
  return n[6] !== c || n[7] !== u ? (d = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsPanel$1, {
12922
12953
  className: u,
12923
12954
  ...c
12924
12955
  }), n[6] = c, n[7] = u, n[8] = d) : d = n[8], d;
12925
12956
  };
12926
- var import_compiler_runtime$2 = require_compiler_runtime();
12957
+ var import_compiler_runtime$1 = require_compiler_runtime();
12927
12958
  const TabsTab = (t) => {
12928
- let n = (0, import_compiler_runtime$2.c)(8), i, s;
12959
+ let n = (0, import_compiler_runtime$1.c)(8), i, s;
12929
12960
  n[0] === t ? (i = n[1], s = n[2]) : ({className: i, ...s} = t, n[0] = t, n[1] = i, n[2] = s);
12930
12961
  let c;
12931
- n[3] === i ? c = n[4] : (c = cn("inline-flex rounded-2xl md:rounded-full h-11 md:h-12 px-6 body-base-semibold w-full text-text-brand-primary-default text-center items-center justify-center border-0 break-keep whitespace-nowrap outline-none select-none focus-visible:relative focus-visible:before:absolute focus-visible:before:outline data-selected:text-text-inverse-primary-default transition-colors duration-300 hover:cursor-pointer aria-[selected=false]:hover:bg-surface-neutral-primary-hover", i), n[3] = i, n[4] = c);
12962
+ n[3] === i ? c = n[4] : (c = cn("body-base-semibold inline-flex h-11 w-full select-none items-center justify-center whitespace-nowrap break-keep rounded-2xl border-0 px-6 text-center text-text-brand-primary-default outline-none transition-colors duration-300 hover:cursor-pointer focus-visible:relative focus-visible:before:absolute focus-visible:before:outline aria-[selected=false]:hover:bg-surface-neutral-primary-hover data-selected:text-text-inverse-primary-default md:h-12 md:rounded-full", i), n[3] = i, n[4] = c);
12932
12963
  let l;
12933
12964
  return n[5] !== s || n[6] !== c ? (l = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsTab$1, {
12934
12965
  className: c,
12935
12966
  ...s
12936
12967
  }), n[5] = s, n[6] = c, n[7] = l) : l = n[7], l;
12937
12968
  };
12938
- var import_compiler_runtime$1 = require_compiler_runtime();
12939
- const Tabs = (t) => {
12940
- let n = (0, import_compiler_runtime$1.c)(15), { className: i, ref: s, ...l } = t, [u, d] = useState(l.orientation ?? "vertical");
12941
- if (useEffect(() => {
12942
- let t = () => {
12943
- window.innerWidth < 768 ? d("horizontal") : d(l.orientation ?? "vertical");
12944
- };
12945
- return t(), window.addEventListener("resize", t), () => window.removeEventListener("resize", t);
12946
- }, [l.orientation]), l.orientation = u, l.orientation === "horizontal") {
12947
- let t = l.orientation, c;
12948
- n[0] === i ? c = n[1] : (c = cn("flex flex-wrap gap-4 overflow-auto", i), n[0] = i, n[1] = c);
12949
- let u;
12950
- n[2] !== l || n[3] !== s || n[4] !== c ? (u = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsRoot, {
12951
- className: c,
12952
- ref: s,
12953
- ...l
12954
- }), n[2] = l, n[3] = s, n[4] = c, n[5] = u) : u = n[5];
12955
- let d;
12956
- return n[6] !== l.orientation || n[7] !== u ? (d = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsOrientationContext.Provider, {
12957
- value: t,
12958
- children: u
12959
- }), n[6] = l.orientation, n[7] = u, n[8] = d) : d = n[8], d;
12960
- }
12961
- let m;
12962
- n[9] === i ? m = n[10] : (m = cn("flex flex-col gap-2 overflow-clip", i), n[9] = i, n[10] = m);
12963
- let h;
12964
- return n[11] !== l || n[12] !== s || n[13] !== m ? (h = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TabsRoot, {
12965
- className: m,
12966
- ref: s,
12967
- ...l
12968
- }), n[11] = l, n[12] = s, n[13] = m, n[14] = h) : h = n[14], h;
12969
- };
12970
12969
  var counter = 0;
12971
12970
  function generateId(t) {
12972
12971
  return counter += 1, `${t}-${Math.random().toString(36).slice(2, 6)}-${counter}`;
@@ -13360,7 +13359,7 @@ const ToastRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
13360
13359
  }), K = React.useRef(void 0), q = React.useRef(0), J = React.useRef(!1), Y = React.useRef({
13361
13360
  x: 0,
13362
13361
  y: 0
13363
- }), X = React.useRef(!1), Z = React.useMemo(() => _.indexOf(s), [s, _]), Q = React.useMemo(() => _.filter((t) => t.transitionStatus !== "ending").indexOf(s), [s, _]), fh = React.useMemo(() => _.slice(0, _.indexOf(s)).reduce((t, n) => t + (n.height || 0), 0), [_, s]);
13362
+ }), X = React.useRef(!1), Z = React.useMemo(() => _.indexOf(s), [s, _]), Q = React.useMemo(() => _.filter((t) => t.transitionStatus !== "ending").indexOf(s), [s, _]), $ = React.useMemo(() => _.slice(0, _.indexOf(s)).reduce((t, n) => t + (n.height || 0), 0), [_, s]);
13364
13363
  useOpenChangeComplete({
13365
13364
  open: s.transitionStatus !== "ending",
13366
13365
  ref: U,
@@ -13368,7 +13367,7 @@ const ToastRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
13368
13367
  s.transitionStatus === "ending" && b(s.id);
13369
13368
  }
13370
13369
  });
13371
- let $ = useStableCallback((t = !1) => {
13370
+ let yh = useStableCallback((t = !1) => {
13372
13371
  let n = U.current;
13373
13372
  if (!n) return;
13374
13373
  let i = n.style.height;
@@ -13385,15 +13384,15 @@ const ToastRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
13385
13384
  }
13386
13385
  t ? ReactDOM.flushSync(l) : l();
13387
13386
  });
13388
- useIsoLayoutEffect($, [$]);
13389
- function mh(t, n) {
13387
+ useIsoLayoutEffect(yh, [yh]);
13388
+ function bh(t, n) {
13390
13389
  let i = t, s = n;
13391
13390
  return !h.includes("left") && !h.includes("right") ? i = t > 0 ? t ** OPPOSITE_DIRECTION_DAMPING_FACTOR : -(Math.abs(t) ** OPPOSITE_DIRECTION_DAMPING_FACTOR) : (!h.includes("right") && t > 0 && (i = t ** OPPOSITE_DIRECTION_DAMPING_FACTOR), !h.includes("left") && t < 0 && (i = -(Math.abs(t) ** OPPOSITE_DIRECTION_DAMPING_FACTOR))), !h.includes("up") && !h.includes("down") ? s = n > 0 ? n ** OPPOSITE_DIRECTION_DAMPING_FACTOR : -(Math.abs(n) ** OPPOSITE_DIRECTION_DAMPING_FACTOR) : (!h.includes("down") && n > 0 && (s = n ** OPPOSITE_DIRECTION_DAMPING_FACTOR), !h.includes("up") && n < 0 && (s = -(Math.abs(n) ** OPPOSITE_DIRECTION_DAMPING_FACTOR))), {
13392
13391
  x: i,
13393
13392
  y: s
13394
13393
  };
13395
13394
  }
13396
- function hh(t) {
13395
+ function xh(t) {
13397
13396
  if (t.button !== 0) return;
13398
13397
  t.pointerType === "touch" && S();
13399
13398
  let n = getTarget(t.nativeEvent);
@@ -13411,7 +13410,7 @@ const ToastRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
13411
13410
  w(!0), O(!0), A(!1), H(null), X.current = !0, U.current?.setPointerCapture(t.pointerId);
13412
13411
  }
13413
13412
  }
13414
- function gh(t) {
13413
+ function Sh(t) {
13415
13414
  if (!D) return;
13416
13415
  t.preventDefault(), X.current &&= (W.current = {
13417
13416
  x: t.clientX,
@@ -13436,13 +13435,13 @@ const ToastRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
13436
13435
  let t = K.current, n = getDisplacement(t, f, d);
13437
13436
  n > SWIPE_THRESHOLD ? (J.current = !1, E(t)) : !(h.includes("left") && h.includes("right")) && !(h.includes("up") && h.includes("down")) && q.current - n >= REVERSE_CANCEL_THRESHOLD && (J.current = !0);
13438
13437
  }
13439
- let g = mh(l, u), _ = G.current.x, v = G.current.y;
13438
+ let g = bh(l, u), _ = G.current.x, v = G.current.y;
13440
13439
  V === "horizontal" ? (h.includes("left") || h.includes("right")) && (_ += g.x) : (V === "vertical" || (h.includes("left") || h.includes("right")) && (_ += g.x), (h.includes("up") || h.includes("down")) && (v += g.y)), P({
13441
13440
  x: _,
13442
13441
  y: v
13443
13442
  });
13444
13443
  }
13445
- function _h(t) {
13444
+ function Ch(t) {
13446
13445
  if (!D) return;
13447
13446
  if (O(!1), A(!1), H(null), U.current?.releasePointerCapture(t.pointerId), J.current) {
13448
13447
  P({
@@ -13475,7 +13474,7 @@ const ToastRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
13475
13474
  y: F.y
13476
13475
  }), E(void 0));
13477
13476
  }
13478
- function vh(t) {
13477
+ function wh(t) {
13479
13478
  if (t.key === "Escape") {
13480
13479
  if (!U.current || !contains(U.current, activeElement(ownerDocument(U.current)))) return;
13481
13480
  y(s.id);
@@ -13492,7 +13491,7 @@ const ToastRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
13492
13491
  t.removeEventListener("touchmove", n);
13493
13492
  };
13494
13493
  }, [g]);
13495
- function yh() {
13494
+ function Th() {
13496
13495
  if (!D && N.x === F.x && N.y === F.y && !j) return {
13497
13496
  [ToastRootCssVars.swipeMovementX]: "0px",
13498
13497
  [ToastRootCssVars.swipeMovementY]: "0px"
@@ -13505,25 +13504,25 @@ const ToastRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
13505
13504
  [ToastRootCssVars.swipeMovementY]: `${n}px`
13506
13505
  };
13507
13506
  }
13508
- let bh = s.priority === "high", Sh = {
13509
- role: bh ? "alertdialog" : "dialog",
13507
+ let Eh = s.priority === "high", Oh = {
13508
+ role: Eh ? "alertdialog" : "dialog",
13510
13509
  tabIndex: 0,
13511
13510
  "aria-modal": !1,
13512
13511
  "aria-labelledby": L,
13513
13512
  "aria-describedby": z,
13514
- "aria-hidden": bh && !v ? !0 : void 0,
13515
- onPointerDown: g ? hh : void 0,
13516
- onPointerMove: g ? gh : void 0,
13517
- onPointerUp: g ? _h : void 0,
13518
- onKeyDown: vh,
13513
+ "aria-hidden": Eh && !v ? !0 : void 0,
13514
+ onPointerDown: g ? xh : void 0,
13515
+ onPointerMove: g ? Sh : void 0,
13516
+ onPointerUp: g ? Ch : void 0,
13517
+ onKeyDown: wh,
13519
13518
  inert: inertValue(s.limited),
13520
13519
  style: {
13521
- ...yh(),
13520
+ ...Th(),
13522
13521
  [ToastRootCssVars.index]: s.transitionStatus === "ending" ? Z : Q,
13523
- [ToastRootCssVars.offsetY]: `${fh}px`,
13522
+ [ToastRootCssVars.offsetY]: `${$}px`,
13524
13523
  [ToastRootCssVars.height]: s.height ? `${s.height}px` : void 0
13525
13524
  }
13526
- }, Ch = React.useMemo(() => ({
13525
+ }, kh = React.useMemo(() => ({
13527
13526
  rootRef: U,
13528
13527
  toast: s,
13529
13528
  titleId: L,
@@ -13532,7 +13531,7 @@ const ToastRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
13532
13531
  setDescriptionId: B,
13533
13532
  swiping: D,
13534
13533
  swipeDirection: T,
13535
- recalculateHeight: $,
13534
+ recalculateHeight: yh,
13536
13535
  index: Z,
13537
13536
  visibleIndex: Q,
13538
13537
  expanded: C
@@ -13542,33 +13541,33 @@ const ToastRoot = /* @__PURE__ */ React.forwardRef(function(n, i) {
13542
13541
  z,
13543
13542
  D,
13544
13543
  T,
13545
- $,
13544
+ yh,
13546
13545
  Z,
13547
13546
  Q,
13548
13547
  C
13549
- ]), wh = React.useMemo(() => ({
13548
+ ]), Ah = React.useMemo(() => ({
13550
13549
  transitionStatus: s.transitionStatus,
13551
13550
  expanded: C,
13552
13551
  limited: s.limited || !1,
13553
13552
  type: s.type,
13554
- swiping: Ch.swiping,
13555
- swipeDirection: Ch.swipeDirection
13553
+ swiping: kh.swiping,
13554
+ swipeDirection: kh.swipeDirection
13556
13555
  }), [
13557
13556
  C,
13558
13557
  s.transitionStatus,
13559
13558
  s.limited,
13560
13559
  s.type,
13561
- Ch.swiping,
13562
- Ch.swipeDirection
13563
- ]), Th = useRenderElement("div", n, {
13564
- ref: [i, Ch.rootRef],
13565
- state: wh,
13560
+ kh.swiping,
13561
+ kh.swipeDirection
13562
+ ]), jh = useRenderElement("div", n, {
13563
+ ref: [i, kh.rootRef],
13564
+ state: Ah,
13566
13565
  stateAttributesMapping,
13567
- props: [Sh, d]
13566
+ props: [Oh, d]
13568
13567
  });
13569
13568
  return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToastRootContext.Provider, {
13570
- value: Ch,
13571
- children: Th
13569
+ value: kh,
13570
+ children: jh
13572
13571
  });
13573
13572
  });
13574
13573
  process.env.NODE_ENV !== "production" && (ToastRoot.displayName = "ToastRoot");
@@ -13677,22 +13676,22 @@ const Toast = ({ className: t, children: n, position: i = "top-right", ref: s, .
13677
13676
  }
13678
13677
  };
13679
13678
  return l.map((l) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(ToastRoot, {
13680
- toast: l,
13681
- swipeDirection: u(i),
13682
- className: cn(i === "bottom-right" || i === "bottom-center" || i === "bottom-left" ? "absolute right-0 bottom-0 left-auto z-[calc(1000-var(--toast-index))] mr-0 w-full transform-[translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--toast-swipe-movement-y)+calc(min(var(--toast-index),10)*-15px)))_scale(calc(max(0,1-(var(--toast-index)*0.1))))] rounded-lg border border-outline bg-surface-container bg-clip-padding p-sm shadow-lg transition-all [transition-property:opacity,transform] duration-500 ease-[cubic-bezier(0.22,1,0.36,1)] select-none after:absolute after:bottom-full after:left-0 after:h-[calc(var(--gap)+1px)] after:w-full after:content-[\"\"] data-ending-style:opacity-0 data-expanded:transform-[translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--toast-offset-y)*-1+calc(var(--toast-index)*var(--gap)*-1)+var(--toast-swipe-movement-y)))] data-limited:opacity-0 data-starting-style:transform-[translateY(150%)] [&[data-ending-style]:not([data-limited]):not([data-swipe-direction])]:transform-[translateY(150%)] data-ending-style:data-[swipe-direction=down]:transform-[translateY(calc(var(--toast-swipe-movement-y)+150%))] data-expanded:data-ending-style:data-[swipe-direction=down]:transform-[translateY(calc(var(--toast-swipe-movement-y)+150%))] data-ending-style:data-[swipe-direction=left]:transform-[translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))] data-expanded:data-ending-style:data-[swipe-direction=left]:transform-[translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))] data-ending-style:data-[swipe-direction=right]:transform-[translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))] data-expanded:data-ending-style:data-[swipe-direction=right]:transform-[translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))] data-ending-style:data-[swipe-direction=up]:transform-[translateY(calc(var(--toast-swipe-movement-y)-150%))] data-expanded:data-ending-style:data-[swipe-direction=up]:transform-[translateY(calc(var(--toast-swipe-movement-y)-150%))] flex flex-col gap-3xs" : "absolute top-0 right-0 left-0 z-[calc(1000-var(--toast-index))] mx-auto w-full transform-[translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--toast-swipe-movement-y)+calc(min(var(--toast-index),10)*15px)))_scale(calc(max(0,1-(var(--toast-index)*0.1))))] rounded-lg border border-gray-200 bg-gray-50 bg-clip-padding p-sm shadow-lg transition-all [transition-property:opacity,transform] duration-500 ease-[cubic-bezier(0.22,1,0.36,1)] select-none after:absolute after:top-full after:left-0 after:h-[calc(var(--gap)+1px)] after:w-full after:content-[''] data-ending-style:opacity-0 data-expanded:transform-[translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--toast-offset-y)+calc(var(--toast-index)*var(--gap))+var(--toast-swipe-movement-y)))] data-limited:opacity-0 data-starting-style:transform-[translateY(-150%)] [&[data-ending-style]:not([data-limited]):not([data-swipe-direction])]:transform-[translateY(-150%)] data-ending-style:data-[swipe-direction=down]:transform-[translateY(calc(var(--toast-swipe-movement-y)+150%))] data-expanded:data-ending-style:data-[swipe-direction=down]:transform-[translateY(calc(var(--toast-swipe-movement-y)+150%))] data-ending-style:data-[swipe-direction=left]:transform-[translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))] data-expanded:data-ending-style:data-[swipe-direction=left]:transform-[translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))] data-ending-style:data-[swipe-direction=right]:transform-[translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))] data-expanded:data-ending-style:data-[swipe-direction=right]:transform-[translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))] data-ending-style:data-[swipe-direction=up]:transform-[translateY(calc(var(--toast-swipe-movement-y)-150%))] data-expanded:data-ending-style:data-[swipe-direction=up]:transform-[translateY(calc(var(--toast-swipe-movement-y)-150%))]", t, l.data.variant === "success" && "border-success bg-success-container", l.data.variant === "error" && "border-error bg-error-container", l.data.variant === "warning" && "border-warning bg-warning-container"),
13679
+ className: cn(i === "bottom-right" || i === "bottom-center" || i === "bottom-left" ? "transform-[translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--toast-swipe-movement-y)+calc(min(var(--toast-index),10)*-15px)))_scale(calc(max(0,1-(var(--toast-index)*0.1))))] data-expanded:transform-[translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--toast-offset-y)*-1+calc(var(--toast-index)*var(--gap)*-1)+var(--toast-swipe-movement-y)))] data-starting-style:transform-[translateY(150%)] [&[data-ending-style]:not([data-limited]):not([data-swipe-direction])]:transform-[translateY(150%)] data-ending-style:data-[swipe-direction=down]:transform-[translateY(calc(var(--toast-swipe-movement-y)+150%))] data-expanded:data-ending-style:data-[swipe-direction=down]:transform-[translateY(calc(var(--toast-swipe-movement-y)+150%))] data-ending-style:data-[swipe-direction=left]:transform-[translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))] data-expanded:data-ending-style:data-[swipe-direction=left]:transform-[translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))] data-ending-style:data-[swipe-direction=right]:transform-[translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))] data-expanded:data-ending-style:data-[swipe-direction=right]:transform-[translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))] data-ending-style:data-[swipe-direction=up]:transform-[translateY(calc(var(--toast-swipe-movement-y)-150%))] data-expanded:data-ending-style:data-[swipe-direction=up]:transform-[translateY(calc(var(--toast-swipe-movement-y)-150%))] absolute right-0 bottom-0 left-auto z-[calc(1000-var(--toast-index))] mr-0 flex w-full select-none flex-col gap-3xs rounded-lg border border-outline bg-surface-container bg-clip-padding p-sm shadow-lg transition-all duration-500 ease-[cubic-bezier(0.22,1,0.36,1)] [transition-property:opacity,transform] after:absolute after:bottom-full after:left-0 after:h-[calc(var(--gap)+1px)] after:w-full after:content-[\"\"] data-ending-style:opacity-0 data-limited:opacity-0" : "transform-[translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--toast-swipe-movement-y)+calc(min(var(--toast-index),10)*15px)))_scale(calc(max(0,1-(var(--toast-index)*0.1))))] data-expanded:transform-[translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--toast-offset-y)+calc(var(--toast-index)*var(--gap))+var(--toast-swipe-movement-y)))] data-starting-style:transform-[translateY(-150%)] [&[data-ending-style]:not([data-limited]):not([data-swipe-direction])]:transform-[translateY(-150%)] data-ending-style:data-[swipe-direction=down]:transform-[translateY(calc(var(--toast-swipe-movement-y)+150%))] data-expanded:data-ending-style:data-[swipe-direction=down]:transform-[translateY(calc(var(--toast-swipe-movement-y)+150%))] data-ending-style:data-[swipe-direction=left]:transform-[translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))] data-expanded:data-ending-style:data-[swipe-direction=left]:transform-[translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))] data-ending-style:data-[swipe-direction=right]:transform-[translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))] data-expanded:data-ending-style:data-[swipe-direction=right]:transform-[translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))] data-ending-style:data-[swipe-direction=up]:transform-[translateY(calc(var(--toast-swipe-movement-y)-150%))] data-expanded:data-ending-style:data-[swipe-direction=up]:transform-[translateY(calc(var(--toast-swipe-movement-y)-150%))] absolute top-0 right-0 left-0 z-[calc(1000-var(--toast-index))] mx-auto w-full select-none rounded-lg border border-gray-200 bg-gray-50 bg-clip-padding p-sm shadow-lg transition-all duration-500 ease-[cubic-bezier(0.22,1,0.36,1)] [transition-property:opacity,transform] after:absolute after:top-full after:left-0 after:h-[calc(var(--gap)+1px)] after:w-full after:content-[''] data-ending-style:opacity-0 data-limited:opacity-0", t, l.data.variant === "success" && "border-success bg-success-container", l.data.variant === "error" && "border-error bg-error-container", l.data.variant === "warning" && "border-warning bg-warning-container"),
13680
+ ref: s,
13683
13681
  style: {
13684
13682
  "--gap": "1rem",
13685
13683
  "--offset-y": "calc(var(--toast-offset-y) * -1 + (var(--toast-index) * var(--gap) * -1) + var(--toast-swipe-movement-y))"
13686
13684
  },
13687
- ref: s,
13685
+ swipeDirection: u(i),
13686
+ toast: l,
13688
13687
  ...c,
13689
13688
  children: [
13690
13689
  n,
13691
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToastTitle, { className: cn("text-sm font-semibold text-on-surface", l.data.variant === "success" && "text-on-success-container", l.data.variant === "error" && "text-on-error-container", l.data.variant === "warning" && "text-on-warning-container") }),
13692
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToastDescription, { className: cn("text-sm text-on-surface", l.data.variant === "success" && "text-on-success-container", l.data.variant === "error" && "text-on-error-container", l.data.variant === "warning" && "text-on-warning-container") }),
13690
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToastTitle, { className: cn("font-semibold text-on-surface text-sm", l.data.variant === "success" && "text-on-success-container", l.data.variant === "error" && "text-on-error-container", l.data.variant === "warning" && "text-on-warning-container") }),
13691
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToastDescription, { className: cn("text-on-surface text-sm", l.data.variant === "success" && "text-on-success-container", l.data.variant === "error" && "text-on-error-container", l.data.variant === "warning" && "text-on-warning-container") }),
13693
13692
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToastClose, {
13694
- className: "absolute top-xs right-2xs flex size-xs items-center justify-center rounded border-none bg-transparent text-on-surface hover:cursor-pointer",
13695
13693
  "aria-label": "Close",
13694
+ className: "absolute top-xs right-2xs flex size-xs items-center justify-center rounded border-none bg-transparent text-on-surface hover:cursor-pointer",
13696
13695
  children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(e, { weight: "bold" })
13697
13696
  })
13698
13697
  ]
@@ -13704,12 +13703,12 @@ const ToastProvider = (t) => {
13704
13703
  n[0] === t ? (i = n[1], s = n[2], c = n[3], l = n[4], u = n[5]) : ({position: u, className: s, children: i, ref: l, ...c} = t, n[0] = t, n[1] = i, n[2] = s, n[3] = c, n[4] = l, n[5] = u);
13705
13704
  let d = u === void 0 ? "bottom-center" : u, f = d === "top-left", m = d === "top-center", h = d === "top-right", g = d === "bottom-left", _ = d === "bottom-center", v = d === "bottom-right", y;
13706
13705
  n[6] !== s || n[7] !== f || n[8] !== m || n[9] !== h || n[10] !== g || n[11] !== _ || n[12] !== v ? (y = cn({
13707
- "fixed z-10 top-[1rem] left-[1rem] right-auto bottom-auto mx-0 flex w-1/4": f,
13708
- "fixed z-10 top-[1rem] left-1/2 right-auto bottom-auto mx-auto flex w-1/4 -translate-x-1/2": m,
13709
- "fixed z-10 top-[1rem] right-[1rem] left-auto bottom-auto mx-0 flex w-1/4": h,
13710
- "fixed z-10 bottom-[6rem] left-[1rem] right-auto top-auto mx-0 flex w-1/4": g,
13711
- "fixed z-10 bottom-[6rem] left-1/2 right-auto top-auto mx-auto flex w-1/4 -translate-x-1/2": _,
13712
- "fixed z-10 bottom-[6rem] right-[1rem] left-auto top-auto mx-0 flex w-1/4": v
13706
+ "fixed top-[1rem] right-auto bottom-auto left-[1rem] z-10 mx-0 flex w-1/4": f,
13707
+ "fixed top-[1rem] right-auto bottom-auto left-1/2 z-10 mx-auto flex w-1/4 -translate-x-1/2": m,
13708
+ "fixed top-[1rem] right-[1rem] bottom-auto left-auto z-10 mx-0 flex w-1/4": h,
13709
+ "fixed top-auto right-auto bottom-[6rem] left-[1rem] z-10 mx-0 flex w-1/4": g,
13710
+ "fixed top-auto right-auto bottom-[6rem] left-1/2 z-10 mx-auto flex w-1/4 -translate-x-1/2": _,
13711
+ "fixed top-auto right-[1rem] bottom-[6rem] left-auto z-10 mx-0 flex w-1/4": v
13713
13712
  }, s), n[6] = s, n[7] = f, n[8] = m, n[9] = h, n[10] = g, n[11] = _, n[12] = v, n[13] = y) : y = n[13];
13714
13713
  let b;
13715
13714
  n[14] === d ? b = n[15] : (b = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Toast, { position: d }), n[14] = d, n[15] = b);