@arcadeai/design-system 5.0.2 → 5.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{clamp-DV0oJUnl.js → CSPContext-_3HefTUC.js} +1 -6
- package/dist/{DialogRoot-xodRxCJ6.js → DialogRoot-DuiSPdsZ.js} +1 -1
- package/dist/{DialogTrigger-BRWKaMYv.js → DialogTrigger-DGGP-2Oc.js} +109 -108
- package/dist/{FloatingPortalLite-e0IaokaG.js → FloatingPortalLite-D5nFwFgJ.js} +1 -1
- package/dist/ReactStore-C3H8e2ha.js +600 -0
- package/dist/{Toggle-waFXW8db.js → Toggle-BdxyK_Ln.js} +1 -1
- package/dist/{accordion-DimUia61.js → accordion-BP9Lgkg8.js} +18 -18
- package/dist/{alert-dialog-BiDZwtP2.js → alert-dialog-1bUE2clB.js} +1 -1
- package/dist/assets/index.css +1 -1
- package/dist/assets/tokens.css +1 -1
- package/dist/assets/variables.css +1 -1
- package/dist/{avatar-B-lhJ-Gz.js → avatar-DbL6b01k.js} +4 -3
- package/dist/{checkbox-CZViOGvt.js → checkbox-DB9O_Iw9.js} +96 -85
- package/dist/clamp-BT4ayAnN.js +6 -0
- package/dist/{collapsible-DlF1q_cg.js → collapsible-DP7Fb-Lu.js} +17 -17
- package/dist/components/index.js +257 -251
- package/dist/components/ui/atoms/accordion.js +1 -1
- package/dist/components/ui/atoms/alert-dialog.js +1 -1
- package/dist/components/ui/atoms/avatar.js +1 -1
- package/dist/components/ui/atoms/checkbox.d.ts +16 -2
- package/dist/components/ui/atoms/checkbox.d.ts.map +1 -1
- package/dist/components/ui/atoms/checkbox.js +2 -2
- package/dist/components/ui/atoms/clear-button.d.ts +13 -0
- package/dist/components/ui/atoms/clear-button.d.ts.map +1 -0
- package/dist/components/ui/atoms/clear-button.js +23 -0
- package/dist/components/ui/atoms/collapsible.js +1 -1
- package/dist/components/ui/atoms/dialog.js +2 -2
- package/dist/components/ui/atoms/dropdown-menu.js +1 -1
- package/dist/components/ui/atoms/hover-card.js +1 -1
- package/dist/components/ui/atoms/icon-tile.d.ts +10 -0
- package/dist/components/ui/atoms/icon-tile.d.ts.map +1 -0
- package/dist/components/ui/atoms/icon-tile.js +25 -0
- package/dist/components/ui/atoms/index.d.ts +3 -1
- package/dist/components/ui/atoms/index.d.ts.map +1 -1
- package/dist/components/ui/atoms/index.js +210 -208
- package/dist/components/ui/atoms/input-group.js +1 -1
- package/dist/components/ui/atoms/input.js +1 -1
- package/dist/components/ui/atoms/mobile-tooltip.js +2 -2
- package/dist/components/ui/atoms/popover.js +1 -1
- package/dist/components/ui/atoms/progress.js +1 -1
- package/dist/components/ui/atoms/radio-group.js +1 -1
- package/dist/components/ui/atoms/scroll-area.js +1 -1
- package/dist/components/ui/atoms/scroll-button.js +1 -1
- package/dist/components/ui/atoms/scroll-to-bottom-button.d.ts +24 -0
- package/dist/components/ui/atoms/scroll-to-bottom-button.d.ts.map +1 -0
- package/dist/components/ui/atoms/scroll-to-bottom-button.js +31 -0
- package/dist/components/ui/atoms/select.js +1 -1
- package/dist/components/ui/atoms/sheet.js +2 -2
- package/dist/components/ui/atoms/sidebar.js +2 -2
- package/dist/components/ui/atoms/slider.js +1 -1
- package/dist/components/ui/atoms/switch.js +1 -1
- package/dist/components/ui/atoms/tabs.js +1 -1
- package/dist/components/ui/atoms/toggle-group.js +1 -1
- package/dist/components/ui/atoms/toggle.js +1 -1
- package/dist/components/ui/atoms/tooltip.js +1 -1
- package/dist/components/ui/blocks/demo.js +4 -4
- package/dist/components/ui/index.js +257 -251
- package/dist/components/ui/molecules/avatar-stack.d.ts +32 -0
- package/dist/components/ui/molecules/avatar-stack.d.ts.map +1 -0
- package/dist/components/ui/molecules/avatar-stack.js +91 -0
- package/dist/components/ui/molecules/callout.d.ts +20 -0
- package/dist/components/ui/molecules/callout.d.ts.map +1 -0
- package/dist/components/ui/molecules/callout.js +39 -0
- package/dist/components/ui/molecules/chat-history-item.js +1 -1
- package/dist/components/ui/molecules/chip-body.d.ts +21 -0
- package/dist/components/ui/molecules/chip-body.d.ts.map +1 -0
- package/dist/components/ui/molecules/chip-body.js +21 -0
- package/dist/components/ui/molecules/client-secret-field.js +1 -1
- package/dist/components/ui/molecules/confirm-popover.js +1 -1
- package/dist/components/ui/molecules/date-time-picker.js +2 -2
- package/dist/components/ui/molecules/filter-chip-group.d.ts +26 -0
- package/dist/components/ui/molecules/filter-chip-group.d.ts.map +1 -0
- package/dist/components/ui/molecules/{mcp-server-picker/category-filter.js → filter-chip-group.js} +8 -7
- package/dist/components/ui/molecules/index.d.ts +14 -6
- package/dist/components/ui/molecules/index.d.ts.map +1 -1
- package/dist/components/ui/molecules/index.js +39 -35
- package/dist/components/ui/molecules/mcp-server-picker/recommended-toolkits-chip.d.ts.map +1 -1
- package/dist/components/ui/molecules/mcp-server-picker/recommended-toolkits-chip.js +18 -15
- package/dist/components/ui/molecules/mcp-server-picker/recommended-tools.js +2 -2
- package/dist/components/ui/molecules/mcp-server-picker/search-scope-tabs.js +1 -1
- package/dist/components/ui/molecules/mcp-server-picker/server-avatar-stack.d.ts +1 -1
- package/dist/components/ui/molecules/mcp-server-picker/server-avatar-stack.d.ts.map +1 -1
- package/dist/components/ui/molecules/mcp-server-picker/server-avatar-stack.js +29 -81
- package/dist/components/ui/molecules/mcp-server-picker/server-card.js +1 -1
- package/dist/components/ui/molecules/mcp-server-picker/tool-card.js +1 -1
- package/dist/components/ui/molecules/mcp-server-picker/tool-recommendations.d.ts +12 -0
- package/dist/components/ui/molecules/mcp-server-picker/tool-recommendations.d.ts.map +1 -0
- package/dist/components/ui/molecules/mcp-server-picker/{tool-search-band.js → tool-recommendations.js} +6 -6
- package/dist/components/ui/molecules/mcp-server-picker/toolkit-avatar.d.ts +6 -6
- package/dist/components/ui/molecules/mcp-server-picker/toolkit-avatar.d.ts.map +1 -1
- package/dist/components/ui/molecules/mcp-server-picker/toolkit-avatar.js +21 -33
- package/dist/components/ui/molecules/mcp-server-picker/toolkit-chip.d.ts.map +1 -1
- package/dist/components/ui/molecules/mcp-server-picker/toolkit-chip.js +19 -22
- package/dist/components/ui/molecules/mcp-server-picker/unoptimized-match-card.js +1 -1
- package/dist/components/ui/molecules/message.js +2 -2
- package/dist/components/ui/molecules/prompt-input.js +1 -1
- package/dist/components/ui/molecules/removable-chip.d.ts.map +1 -0
- package/dist/components/ui/{atoms → molecules}/removable-chip.js +1 -1
- package/dist/components/ui/molecules/requirement-badges.js +1 -1
- package/dist/components/ui/molecules/tool-call-accordion.js +2 -2
- package/dist/components/ui/molecules/tool-card.js +2 -2
- package/dist/components/ui/molecules/toolkit-card.js +1 -1
- package/dist/components/ui/molecules/undo-toast.d.ts +47 -0
- package/dist/components/ui/molecules/undo-toast.d.ts.map +1 -0
- package/dist/components/ui/molecules/undo-toast.js +3 -0
- package/dist/components/ui/molecules/user-nav.js +2 -2
- package/dist/components/ui/organisms/mcp-selection-summary-bar.d.ts.map +1 -1
- package/dist/components/ui/organisms/mcp-selection-summary-bar.js +27 -30
- package/dist/{dropdown-menu-CWWN1cXs.js → dropdown-menu-ecggVuhu.js} +202 -199
- package/dist/{getPseudoElementBounds-D_dlkPnQ.js → getPseudoElementBounds-BOe22aYl.js} +3 -3
- package/dist/{hover-card-GELKDadU.js → hover-card-CGLPPPPP.js} +71 -70
- package/dist/{input-DZfZK6b1.js → input-DZTqcpe-.js} +1 -1
- package/dist/main.js +263 -257
- package/dist/metadata/oauth-providers.d.ts +2 -0
- package/dist/metadata/oauth-providers.d.ts.map +1 -1
- package/dist/metadata/oauth-providers.js +153 -141
- package/dist/{popover-Cne_hQUh.js → popover-CpLkQtT5.js} +129 -128
- package/dist/popupStateMapping-XiLS0Jku.js +643 -0
- package/dist/{progress-D71iUjvg.js → progress-BqG0PtAD.js} +1 -1
- package/dist/{radio-group-CTqA-p0w.js → radio-group-BpMluqfv.js} +8 -7
- package/dist/{safePolygon-os2F06tc.js → safePolygon-DmV1hDsw.js} +35 -34
- package/dist/{scroll-area-C0KbhRES.js → scroll-area-D7iOy7xj.js} +4 -3
- package/dist/{scrollEdges-CHZpP0us.js → scrollEdges-Dck9qFyQ.js} +1 -1
- package/dist/{select-RvAj5g6e.js → select-DFWNXxvZ.js} +179 -176
- package/dist/{slider-Bhn1ogwZ.js → slider-ClXWRpwI.js} +4 -3
- package/dist/{store-C-KXBzZ0.js → store-D7k1qIkZ.js} +23 -22
- package/dist/{switch-D8M0xvzp.js → switch-DlxZDt6o.js} +3 -3
- package/dist/{tabs-ttkDuwww.js → tabs-Cj3LY-7F.js} +9 -8
- package/dist/{toggle-group-CL_MBwuU.js → toggle-group-CmP4iHEJ.js} +1 -1
- package/dist/{tooltip-ZIywOFGf.js → tooltip-BUR7V5Aa.js} +197 -196
- package/dist/{ui-CttBuHXi.js → ui-46pgiw5T.js} +2 -2
- package/dist/undo-toast-Cf4T6ToX.js +898 -0
- package/dist/{useAnchoredPopupScrollLock-a2b_Frjv.js → useAnchoredPopupScrollLock-CnoPUwXv.js} +1 -1
- package/dist/{useAriaLabelledBy-WyUZP7Yf.js → useAriaLabelledBy-DJZioWd6.js} +1 -1
- package/dist/useBaseUiId-CXSJgVcI.js +8 -0
- package/dist/{useCollapsiblePanel-B6XZh6zH.js → useCollapsiblePanel-BPbcE70S.js} +15 -14
- package/dist/{useFocus-DwJfNYN6.js → useFocus-B_SrhX9q.js} +10 -10
- package/dist/{useBaseUiId-voePHgyX.js → useId-Bzr7_bed.js} +1 -6
- package/dist/{useLabelableId-CC2YaILf.js → useLabelableId-9jrDGk5d.js} +1 -1
- package/dist/useOpenChangeComplete-CVIwfcpl.js +80 -0
- package/dist/{useOpenInteractionType-DQhvPqO3.js → useOpenInteractionType-INvHftZi.js} +29 -28
- package/dist/{usePositioner-DkeyI5Le.js → usePositioner-CaLGGc-z.js} +98 -97
- package/dist/useTransitionStatus-CCIoL5RH.js +51 -0
- package/dist/{useTriggerFocusGuards-Qi8iK-AK.js → useTriggerFocusGuards-Dlv8KvSm.js} +7 -7
- package/package.json +1 -1
- package/dist/components/ui/atoms/removable-chip.d.ts.map +0 -1
- package/dist/components/ui/molecules/mcp-server-picker/category-filter-menu.d.ts +0 -31
- package/dist/components/ui/molecules/mcp-server-picker/category-filter-menu.d.ts.map +0 -1
- package/dist/components/ui/molecules/mcp-server-picker/category-filter-menu.js +0 -106
- package/dist/components/ui/molecules/mcp-server-picker/category-filter.d.ts +0 -18
- package/dist/components/ui/molecules/mcp-server-picker/category-filter.d.ts.map +0 -1
- package/dist/components/ui/molecules/mcp-server-picker/tool-search-band.d.ts +0 -12
- package/dist/components/ui/molecules/mcp-server-picker/tool-search-band.d.ts.map +0 -1
- package/dist/popupStateMapping-C8W76brO.js +0 -1221
- package/dist/useOpenChangeComplete-Bs6gnxd9.js +0 -127
- /package/dist/components/ui/{atoms → molecules}/removable-chip.d.ts +0 -0
|
@@ -3,18 +3,19 @@ import { t as e } from "./useIsoLayoutEffect-4LGv3HzC.js";
|
|
|
3
3
|
import { f as t, o as n, t as r } from "./useRenderElement-BToElZ97.js";
|
|
4
4
|
import { t as i } from "./useStableCallback-CrM0Nb2q.js";
|
|
5
5
|
import { t as a } from "./DirectionContext-OzWG1tsQ.js";
|
|
6
|
-
import {
|
|
6
|
+
import { t as o } from "./useId-Bzr7_bed.js";
|
|
7
7
|
import { _ as s, a as c, c as l, d as u, f as d, h as f, i as p, l as m, n as h, o as g, p as _, r as v, s as y, t as b, u as x, v as S, y as C } from "./floating-ui.utils.dom-5U5b4xPf.js";
|
|
8
8
|
import { t as w } from "./useValueAsRef-CfO5zn2c.js";
|
|
9
9
|
import { t as T } from "./owner-CyZnQOKt.js";
|
|
10
|
-
import {
|
|
11
|
-
import { C as
|
|
10
|
+
import { D as E, E as D, o as O, r as k, x as A } from "./popupStateMapping-XiLS0Jku.js";
|
|
11
|
+
import { C as j, E as M, S as N, T as P, _ as ee, b as F, c as I, d as te, f as ne, g as L, h as re, l as R, m as z, p as ie, s as ae, u as B, v as oe, w as V, x as H, y as U } from "./composite-B-tEa-Zg.js";
|
|
12
|
+
import { f as se } from "./ReactStore-C3H8e2ha.js";
|
|
12
13
|
import * as W from "react";
|
|
13
14
|
import { useLayoutEffect as ce } from "react";
|
|
14
15
|
import * as le from "react-dom";
|
|
15
16
|
//#region ../../node_modules/.bun/@floating-ui+core@1.7.5/node_modules/@floating-ui/core/dist/floating-ui.core.mjs
|
|
16
17
|
function ue(e, t, n) {
|
|
17
|
-
let { reference: r, floating: i } = e, a =
|
|
18
|
+
let { reference: r, floating: i } = e, a = H(t), o = ne(t), s = z(o), c = F(t), l = a === "y", u = r.x + r.width / 2 - i.width / 2, d = r.y + r.height / 2 - i.height / 2, f = r[s] / 2 - i[s] / 2, p;
|
|
18
19
|
switch (c) {
|
|
19
20
|
case "top":
|
|
20
21
|
p = {
|
|
@@ -45,7 +46,7 @@ function ue(e, t, n) {
|
|
|
45
46
|
y: r.y
|
|
46
47
|
};
|
|
47
48
|
}
|
|
48
|
-
switch (
|
|
49
|
+
switch (te(t)) {
|
|
49
50
|
case "start":
|
|
50
51
|
p[o] -= f * (n && l ? -1 : 1);
|
|
51
52
|
break;
|
|
@@ -57,7 +58,7 @@ function ue(e, t, n) {
|
|
|
57
58
|
}
|
|
58
59
|
async function G(e, t) {
|
|
59
60
|
t === void 0 && (t = {});
|
|
60
|
-
let { x: n, y: r, platform: i, rects: a, elements: o, strategy: s } = e, { boundary: c = "clippingAncestors", rootBoundary: l = "viewport", elementContext: u = "floating", altBoundary: d = !1, padding: f = 0 } =
|
|
61
|
+
let { x: n, y: r, platform: i, rects: a, elements: o, strategy: s } = e, { boundary: c = "clippingAncestors", rootBoundary: l = "viewport", elementContext: u = "floating", altBoundary: d = !1, padding: f = 0 } = R(t, e), p = U(f), m = o[d ? u === "floating" ? "reference" : "floating" : u], h = V(await i.getClippingRect({
|
|
61
62
|
element: await (i.isElement == null ? void 0 : i.isElement(m)) ?? !0 ? m : m.contextElement || await (i.getDocumentElement == null ? void 0 : i.getDocumentElement(o.floating)),
|
|
62
63
|
boundary: c,
|
|
63
64
|
rootBoundary: l,
|
|
@@ -70,7 +71,7 @@ async function G(e, t) {
|
|
|
70
71
|
} : a.reference, _ = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(o.floating)), v = await (i.isElement == null ? void 0 : i.isElement(_)) && await (i.getScale == null ? void 0 : i.getScale(_)) || {
|
|
71
72
|
x: 1,
|
|
72
73
|
y: 1
|
|
73
|
-
}, y =
|
|
74
|
+
}, y = V(i.convertOffsetParentRelativeRectToViewportRelativeRect ? await i.convertOffsetParentRelativeRectToViewportRelativeRect({
|
|
74
75
|
elements: o,
|
|
75
76
|
rect: g,
|
|
76
77
|
offsetParent: _,
|
|
@@ -131,9 +132,9 @@ var de = 50, fe = async (e, t, n) => {
|
|
|
131
132
|
options: e,
|
|
132
133
|
async fn(t) {
|
|
133
134
|
var n;
|
|
134
|
-
let { placement: r, middlewareData: i, rects: a, initialPlacement: o, platform: s, elements: c } = t, { mainAxis: l = !0, crossAxis: u = !0, fallbackPlacements: d, fallbackStrategy: f = "bestFit", fallbackAxisSideDirection: p = "none", flipAlignment: m = !0, ...h } =
|
|
135
|
+
let { placement: r, middlewareData: i, rects: a, initialPlacement: o, platform: s, elements: c } = t, { mainAxis: l = !0, crossAxis: u = !0, fallbackPlacements: d, fallbackStrategy: f = "bestFit", fallbackAxisSideDirection: p = "none", flipAlignment: m = !0, ...h } = R(e, t);
|
|
135
136
|
if ((n = i.arrow) != null && n.alignmentOffset) return {};
|
|
136
|
-
let g =
|
|
137
|
+
let g = F(r), _ = H(o), v = F(o) === o, y = await (s.isRTL == null ? void 0 : s.isRTL(c.floating)), b = d || (v || !m ? [oe(o)] : re(o)), x = p !== "none";
|
|
137
138
|
!d && x && b.push(...ee(o, m, p, y));
|
|
138
139
|
let S = [o, ...b], C = await s.detectOverflow(t, h), w = [], T = i.flip?.overflows || [];
|
|
139
140
|
if (l && w.push(C[g]), u) {
|
|
@@ -145,7 +146,7 @@ var de = 50, fe = async (e, t, n) => {
|
|
|
145
146
|
overflows: w
|
|
146
147
|
}], !w.every((e) => e <= 0)) {
|
|
147
148
|
let e = (i.flip?.index || 0) + 1, t = S[e];
|
|
148
|
-
if (t && (!(u === "alignment" && _ !==
|
|
149
|
+
if (t && (!(u === "alignment" && _ !== H(t)) || T.every((e) => H(e.placement) === _ ? e.overflows[0] > 0 : !0))) return {
|
|
149
150
|
data: {
|
|
150
151
|
index: e,
|
|
151
152
|
overflows: T
|
|
@@ -157,7 +158,7 @@ var de = 50, fe = async (e, t, n) => {
|
|
|
157
158
|
case "bestFit": {
|
|
158
159
|
let e = T.filter((e) => {
|
|
159
160
|
if (x) {
|
|
160
|
-
let t =
|
|
161
|
+
let t = H(e.placement);
|
|
161
162
|
return t === _ || t === "y";
|
|
162
163
|
}
|
|
163
164
|
return !0;
|
|
@@ -184,14 +185,14 @@ function me(e, t) {
|
|
|
184
185
|
};
|
|
185
186
|
}
|
|
186
187
|
function he(e) {
|
|
187
|
-
return
|
|
188
|
+
return M.some((t) => e[t] >= 0);
|
|
188
189
|
}
|
|
189
190
|
var K = function(e) {
|
|
190
191
|
return e === void 0 && (e = {}), {
|
|
191
192
|
name: "hide",
|
|
192
193
|
options: e,
|
|
193
194
|
async fn(t) {
|
|
194
|
-
let { rects: n, platform: r } = t, { strategy: i = "referenceHidden", ...a } =
|
|
195
|
+
let { rects: n, platform: r } = t, { strategy: i = "referenceHidden", ...a } = R(e, t);
|
|
195
196
|
switch (i) {
|
|
196
197
|
case "referenceHidden": {
|
|
197
198
|
let e = me(await r.detectOverflow(t, {
|
|
@@ -219,7 +220,7 @@ var K = function(e) {
|
|
|
219
220
|
};
|
|
220
221
|
}, q = /*#__PURE__*/ new Set(["left", "top"]);
|
|
221
222
|
async function ge(e, t) {
|
|
222
|
-
let { placement: n, platform: r, elements: i } = e, a = await (r.isRTL == null ? void 0 : r.isRTL(i.floating)), o =
|
|
223
|
+
let { placement: n, platform: r, elements: i } = e, a = await (r.isRTL == null ? void 0 : r.isRTL(i.floating)), o = F(n), s = te(n), c = H(n) === "y", l = q.has(o) ? -1 : 1, u = a && c ? -1 : 1, d = R(t, e), { mainAxis: f, crossAxis: p, alignmentAxis: m } = typeof d == "number" ? {
|
|
223
224
|
mainAxis: d,
|
|
224
225
|
crossAxis: 0,
|
|
225
226
|
alignmentAxis: null
|
|
@@ -264,10 +265,10 @@ var _e = function(e) {
|
|
|
264
265
|
x: t,
|
|
265
266
|
y: n
|
|
266
267
|
};
|
|
267
|
-
} }, ...l } =
|
|
268
|
+
} }, ...l } = R(e, t), u = {
|
|
268
269
|
x: n,
|
|
269
270
|
y: r
|
|
270
|
-
}, d = await a.detectOverflow(t, l), f =
|
|
271
|
+
}, d = await a.detectOverflow(t, l), f = H(F(i)), p = L(f), m = u[p], h = u[f];
|
|
271
272
|
if (o) {
|
|
272
273
|
let e = p === "y" ? "top" : "left", t = p === "y" ? "bottom" : "right", n = m + d[e], r = m - d[t];
|
|
273
274
|
m = ae(n, m, r);
|
|
@@ -298,10 +299,10 @@ var _e = function(e) {
|
|
|
298
299
|
return e === void 0 && (e = {}), {
|
|
299
300
|
options: e,
|
|
300
301
|
fn(t) {
|
|
301
|
-
let { x: n, y: r, placement: i, rects: a, middlewareData: o } = t, { offset: s = 0, mainAxis: c = !0, crossAxis: l = !0 } =
|
|
302
|
+
let { x: n, y: r, placement: i, rects: a, middlewareData: o } = t, { offset: s = 0, mainAxis: c = !0, crossAxis: l = !0 } = R(e, t), u = {
|
|
302
303
|
x: n,
|
|
303
304
|
y: r
|
|
304
|
-
}, d =
|
|
305
|
+
}, d = H(i), f = L(d), p = u[f], m = u[d], h = R(s, t), g = typeof h == "number" ? {
|
|
305
306
|
mainAxis: h,
|
|
306
307
|
crossAxis: 0
|
|
307
308
|
} : {
|
|
@@ -314,7 +315,7 @@ var _e = function(e) {
|
|
|
314
315
|
p < t ? p = t : p > n && (p = n);
|
|
315
316
|
}
|
|
316
317
|
if (l) {
|
|
317
|
-
let e = f === "y" ? "width" : "height", t = q.has(
|
|
318
|
+
let e = f === "y" ? "width" : "height", t = q.has(F(i)), n = a.reference[d] - a.floating[e] + (t && o.offset?.[d] || 0) + (t ? 0 : g.crossAxis), r = a.reference[d] + a.reference[e] + (t ? 0 : o.offset?.[d] || 0) - (t ? g.crossAxis : 0);
|
|
318
319
|
m < n ? m = n : m > r && (m = r);
|
|
319
320
|
}
|
|
320
321
|
return {
|
|
@@ -329,12 +330,12 @@ var _e = function(e) {
|
|
|
329
330
|
options: e,
|
|
330
331
|
async fn(t) {
|
|
331
332
|
var n, r;
|
|
332
|
-
let { placement: i, rects: a, platform: o, elements: s } = t, { apply: c = () => {}, ...l } =
|
|
333
|
+
let { placement: i, rects: a, platform: o, elements: s } = t, { apply: c = () => {}, ...l } = R(e, t), u = await o.detectOverflow(t, l), d = F(i), f = te(i), p = H(i) === "y", { width: m, height: h } = a.floating, g, _;
|
|
333
334
|
d === "top" || d === "bottom" ? (g = d, _ = f === (await (o.isRTL == null ? void 0 : o.isRTL(s.floating)) ? "start" : "end") ? "left" : "right") : (_ = d, g = f === "end" ? "top" : "bottom");
|
|
334
|
-
let v = h - u.top - u.bottom, y = m - u.left - u.right, b =
|
|
335
|
+
let v = h - u.top - u.bottom, y = m - u.left - u.right, b = j(h - u[g], v), x = j(m - u[_], y), S = !t.middlewareData.shift, C = b, w = x;
|
|
335
336
|
if ((n = t.middlewareData.shift) != null && n.enabled.x && (w = y), (r = t.middlewareData.shift) != null && r.enabled.y && (C = v), S && !f) {
|
|
336
|
-
let e =
|
|
337
|
-
p ? w = m - 2 * (e !== 0 || t !== 0 ? e + t :
|
|
337
|
+
let e = N(u.left, 0), t = N(u.right, 0), n = N(u.top, 0), r = N(u.bottom, 0);
|
|
338
|
+
p ? w = m - 2 * (e !== 0 || t !== 0 ? e + t : N(u.left, u.right)) : C = h - 2 * (n !== 0 || r !== 0 ? n + r : N(u.top, u.bottom));
|
|
338
339
|
}
|
|
339
340
|
await c({
|
|
340
341
|
...t,
|
|
@@ -349,7 +350,7 @@ var _e = function(e) {
|
|
|
349
350
|
//#endregion
|
|
350
351
|
//#region ../../node_modules/.bun/@floating-ui+dom@1.7.6/node_modules/@floating-ui/dom/dist/floating-ui.dom.mjs
|
|
351
352
|
function be(e) {
|
|
352
|
-
let t = b(e), n = parseFloat(t.width) || 0, r = parseFloat(t.height) || 0, i = d(e), a = i ? e.offsetWidth : n, o = i ? e.offsetHeight : r, s =
|
|
353
|
+
let t = b(e), n = parseFloat(t.width) || 0, r = parseFloat(t.height) || 0, i = d(e), a = i ? e.offsetWidth : n, o = i ? e.offsetHeight : r, s = P(n) !== a || P(r) !== o;
|
|
353
354
|
return s && (n = a, r = o), {
|
|
354
355
|
width: n,
|
|
355
356
|
height: r,
|
|
@@ -361,14 +362,14 @@ function Y(e) {
|
|
|
361
362
|
}
|
|
362
363
|
function X(e) {
|
|
363
364
|
let t = Y(e);
|
|
364
|
-
if (!d(t)) return
|
|
365
|
-
let n = t.getBoundingClientRect(), { width: r, height: i, $: a } = be(t), o = (a ?
|
|
365
|
+
if (!d(t)) return I(1);
|
|
366
|
+
let n = t.getBoundingClientRect(), { width: r, height: i, $: a } = be(t), o = (a ? P(n.width) : n.width) / r, s = (a ? P(n.height) : n.height) / i;
|
|
366
367
|
return (!o || !Number.isFinite(o)) && (o = 1), (!s || !Number.isFinite(s)) && (s = 1), {
|
|
367
368
|
x: o,
|
|
368
369
|
y: s
|
|
369
370
|
};
|
|
370
371
|
}
|
|
371
|
-
var xe = /*#__PURE__*/
|
|
372
|
+
var xe = /*#__PURE__*/ I(0);
|
|
372
373
|
function Se(e) {
|
|
373
374
|
let t = m(e);
|
|
374
375
|
return !C() || !t.visualViewport ? xe : {
|
|
@@ -381,9 +382,9 @@ function Ce(e, t, n) {
|
|
|
381
382
|
}
|
|
382
383
|
function Z(e, t, n, r) {
|
|
383
384
|
t === void 0 && (t = !1), n === void 0 && (n = !1);
|
|
384
|
-
let i = e.getBoundingClientRect(), a = Y(e), o =
|
|
385
|
+
let i = e.getBoundingClientRect(), a = Y(e), o = I(1);
|
|
385
386
|
t && (r ? u(r) && (o = X(r)) : o = X(e));
|
|
386
|
-
let s = Ce(a, n, r) ? Se(a) :
|
|
387
|
+
let s = Ce(a, n, r) ? Se(a) : I(0), c = (i.left + s.x) / o.x, l = (i.top + s.y) / o.y, d = i.width / o.x, f = i.height / o.y;
|
|
387
388
|
if (a) {
|
|
388
389
|
let e = m(a), t = r && u(r) ? m(r) : r, n = e, i = p(n);
|
|
389
390
|
for (; i && r && t !== n;) {
|
|
@@ -391,7 +392,7 @@ function Z(e, t, n, r) {
|
|
|
391
392
|
c *= e.x, l *= e.y, d *= e.x, f *= e.y, c += a, l += o, n = m(i), i = p(n);
|
|
392
393
|
}
|
|
393
394
|
}
|
|
394
|
-
return
|
|
395
|
+
return V({
|
|
395
396
|
width: d,
|
|
396
397
|
height: f,
|
|
397
398
|
x: c,
|
|
@@ -415,12 +416,12 @@ function we(e) {
|
|
|
415
416
|
let l = {
|
|
416
417
|
scrollLeft: 0,
|
|
417
418
|
scrollTop: 0
|
|
418
|
-
}, u =
|
|
419
|
+
}, u = I(1), p = I(0), m = d(r);
|
|
419
420
|
if ((m || !m && !a) && ((c(r) !== "body" || f(o)) && (l = g(r)), m)) {
|
|
420
421
|
let e = Z(r);
|
|
421
422
|
u = X(r), p.x = e.x + r.clientLeft, p.y = e.y + r.clientTop;
|
|
422
423
|
}
|
|
423
|
-
let h = o && !m && !a ? $(o, l) :
|
|
424
|
+
let h = o && !m && !a ? $(o, l) : I(0);
|
|
424
425
|
return {
|
|
425
426
|
width: n.width * u.x,
|
|
426
427
|
height: n.height * u.y,
|
|
@@ -432,8 +433,8 @@ function Te(e) {
|
|
|
432
433
|
return Array.from(e.getClientRects());
|
|
433
434
|
}
|
|
434
435
|
function Ee(e) {
|
|
435
|
-
let t = v(e), n = g(e), r = e.ownerDocument.body, i =
|
|
436
|
-
return b(r).direction === "rtl" && (o +=
|
|
436
|
+
let t = v(e), n = g(e), r = e.ownerDocument.body, i = N(t.scrollWidth, t.clientWidth, r.scrollWidth, r.clientWidth), a = N(t.scrollHeight, t.clientHeight, r.scrollHeight, r.clientHeight), o = -n.scrollLeft + Q(e), s = -n.scrollTop;
|
|
437
|
+
return b(r).direction === "rtl" && (o += N(t.clientWidth, r.clientWidth) - i), {
|
|
437
438
|
width: i,
|
|
438
439
|
height: a,
|
|
439
440
|
x: o,
|
|
@@ -461,7 +462,7 @@ function Oe(e, t) {
|
|
|
461
462
|
};
|
|
462
463
|
}
|
|
463
464
|
function ke(e, t) {
|
|
464
|
-
let n = Z(e, !0, t === "fixed"), r = n.top + e.clientTop, i = n.left + e.clientLeft, a = d(e) ? X(e) :
|
|
465
|
+
let n = Z(e, !0, t === "fixed"), r = n.top + e.clientTop, i = n.left + e.clientLeft, a = d(e) ? X(e) : I(1);
|
|
465
466
|
return {
|
|
466
467
|
width: e.clientWidth * a.x,
|
|
467
468
|
height: e.clientHeight * a.y,
|
|
@@ -483,7 +484,7 @@ function Ae(e, t, n) {
|
|
|
483
484
|
height: t.height
|
|
484
485
|
};
|
|
485
486
|
}
|
|
486
|
-
return
|
|
487
|
+
return V(r);
|
|
487
488
|
}
|
|
488
489
|
function je(e, t) {
|
|
489
490
|
let n = l(e);
|
|
@@ -503,7 +504,7 @@ function Ne(e) {
|
|
|
503
504
|
let { element: t, boundary: n, rootBoundary: r, strategy: i } = e, a = [...n === "clippingAncestors" ? S(t) ? [] : Me(t, this._c) : [].concat(n), r], o = Ae(t, a[0], i), s = o.top, c = o.right, l = o.bottom, u = o.left;
|
|
504
505
|
for (let e = 1; e < a.length; e++) {
|
|
505
506
|
let n = Ae(t, a[e], i);
|
|
506
|
-
s =
|
|
507
|
+
s = N(n.top, s), c = j(n.right, c), l = j(n.bottom, l), u = N(n.left, u);
|
|
507
508
|
}
|
|
508
509
|
return {
|
|
509
510
|
width: c - u,
|
|
@@ -523,7 +524,7 @@ function Fe(e, t, n) {
|
|
|
523
524
|
let r = d(t), i = v(t), a = n === "fixed", o = Z(e, !0, a, t), s = {
|
|
524
525
|
scrollLeft: 0,
|
|
525
526
|
scrollTop: 0
|
|
526
|
-
}, l =
|
|
527
|
+
}, l = I(0);
|
|
527
528
|
function u() {
|
|
528
529
|
l.x = Q(i);
|
|
529
530
|
}
|
|
@@ -532,7 +533,7 @@ function Fe(e, t, n) {
|
|
|
532
533
|
l.x = e.x + t.clientLeft, l.y = e.y + t.clientTop;
|
|
533
534
|
} else i && u();
|
|
534
535
|
a && !r && i && u();
|
|
535
|
-
let p = i && !r && !a ? $(i, s) :
|
|
536
|
+
let p = i && !r && !a ? $(i, s) : I(0);
|
|
536
537
|
return {
|
|
537
538
|
x: o.left + s.scrollLeft - l.x - p.x,
|
|
538
539
|
y: o.top + s.scrollTop - l.y - p.y,
|
|
@@ -604,9 +605,9 @@ function Ue(e, t) {
|
|
|
604
605
|
s === void 0 && (s = !1), c === void 0 && (c = 1), a();
|
|
605
606
|
let l = e.getBoundingClientRect(), { left: u, top: d, width: f, height: p } = l;
|
|
606
607
|
if (s || t(), !f || !p) return;
|
|
607
|
-
let m =
|
|
608
|
+
let m = B(d), h = B(i.clientWidth - (u + f)), g = B(i.clientHeight - (d + p)), _ = B(u), v = {
|
|
608
609
|
rootMargin: -m + "px " + -h + "px " + -g + "px " + -_ + "px",
|
|
609
|
-
threshold:
|
|
610
|
+
threshold: N(0, j(1, c)) || 1
|
|
610
611
|
}, y = !0;
|
|
611
612
|
function b(t) {
|
|
612
613
|
let n = t[0].intersectionRatio;
|
|
@@ -851,7 +852,7 @@ var it = (e, t) => {
|
|
|
851
852
|
//#endregion
|
|
852
853
|
//#region ../../node_modules/.bun/@base-ui+react@1.6.0+df7f6a806acd27ca/node_modules/@base-ui/react/floating-ui-react/hooks/useFloatingRootContext.mjs
|
|
853
854
|
function ut(n) {
|
|
854
|
-
let { open: r = !1, onOpenChange: i, elements: a = {} } = n, s = o(), c =
|
|
855
|
+
let { open: r = !1, onOpenChange: i, elements: a = {} } = n, s = o(), c = D() != null;
|
|
855
856
|
if (process.env.NODE_ENV !== "production") {
|
|
856
857
|
let e = a.reference;
|
|
857
858
|
e && !u(e) && console.error("Cannot pass a virtual element to the `elements.reference` option,", "as it must be a real DOM element. Use `context.setPositionReference()`", "instead.");
|
|
@@ -884,7 +885,7 @@ function ut(n) {
|
|
|
884
885
|
//#endregion
|
|
885
886
|
//#region ../../node_modules/.bun/@base-ui+react@1.6.0+df7f6a806acd27ca/node_modules/@base-ui/react/floating-ui-react/hooks/useFloating.mjs
|
|
886
887
|
function dt(t = {}) {
|
|
887
|
-
let { nodeId: n, externalTree: r } = t, i = ut(t), a = t.rootContext || i, o = a.useState("referenceElement"), s = a.useState("floatingElement"), c = a.useState("domReferenceElement"), l = a.useState("open"), d = a.useState("floatingId"), [f, p] = W.useState(null), [m, h] = W.useState(void 0), [g, _] = W.useState(void 0), v = W.useRef(null), y =
|
|
888
|
+
let { nodeId: n, externalTree: r } = t, i = ut(t), a = t.rootContext || i, o = a.useState("referenceElement"), s = a.useState("floatingElement"), c = a.useState("domReferenceElement"), l = a.useState("open"), d = a.useState("floatingId"), [f, p] = W.useState(null), [m, h] = W.useState(void 0), [g, _] = W.useState(void 0), v = W.useRef(null), y = E(r), b = W.useMemo(() => ({
|
|
888
889
|
reference: o,
|
|
889
890
|
floating: s,
|
|
890
891
|
domReference: c
|
|
@@ -909,18 +910,18 @@ function dt(t = {}) {
|
|
|
909
910
|
p(t), x.refs.setReference(t);
|
|
910
911
|
}, [x.refs]), T = W.useCallback((e) => {
|
|
911
912
|
(u(e) || e === null) && (v.current = e, h(e)), (u(x.refs.reference.current) || x.refs.reference.current === null || e !== null && !u(e)) && x.refs.setReference(e);
|
|
912
|
-
}, [x.refs, h]),
|
|
913
|
+
}, [x.refs, h]), D = W.useCallback((e) => {
|
|
913
914
|
_(e), x.refs.setFloating(e);
|
|
914
915
|
}, [x.refs]), O = W.useMemo(() => ({
|
|
915
916
|
...x.refs,
|
|
916
917
|
setReference: T,
|
|
917
|
-
setFloating:
|
|
918
|
+
setFloating: D,
|
|
918
919
|
setPositionReference: w,
|
|
919
920
|
domReference: v
|
|
920
921
|
}), [
|
|
921
922
|
x.refs,
|
|
922
923
|
T,
|
|
923
|
-
|
|
924
|
+
D,
|
|
924
925
|
w
|
|
925
926
|
]), k = W.useMemo(() => ({
|
|
926
927
|
...x.elements,
|
|
@@ -971,14 +972,14 @@ var ft = (e) => ({
|
|
|
971
972
|
name: "arrow",
|
|
972
973
|
options: e,
|
|
973
974
|
async fn(t) {
|
|
974
|
-
let { x: n, y: r, placement: i, rects: a, platform: o, elements: s, middlewareData: c } = t, { element: l, padding: u = 0, offsetParent: d = "real" } =
|
|
975
|
+
let { x: n, y: r, placement: i, rects: a, platform: o, elements: s, middlewareData: c } = t, { element: l, padding: u = 0, offsetParent: d = "real" } = R(e, t) || {};
|
|
975
976
|
if (l == null) return {};
|
|
976
|
-
let f =
|
|
977
|
+
let f = U(u), p = {
|
|
977
978
|
x: n,
|
|
978
979
|
y: r
|
|
979
|
-
}, m =
|
|
980
|
+
}, m = ne(i), h = z(m), g = await o.getDimensions(l), _ = m === "y", v = _ ? "top" : "left", y = _ ? "bottom" : "right", b = _ ? "clientHeight" : "clientWidth", x = a.reference[h] + a.reference[m] - p[m] - a.floating[h], S = p[m] - a.reference[m], C = d === "real" ? await o.getOffsetParent?.(l) : s.floating, w = s.floating[b] || a.floating[h];
|
|
980
981
|
(!w || !await o.isElement?.(C)) && (w = s.floating[b] || a.floating[h]);
|
|
981
|
-
let T = x / 2 - S / 2, E = w / 2 - g[h] / 2 - 1, D = Math.min(f[v], E), O = Math.min(f[y], E), k = D, A = w - g[h] - O, j = w / 2 - g[h] / 2 + T, M = ae(k, j, A), N = !c.arrow &&
|
|
982
|
+
let T = x / 2 - S / 2, E = w / 2 - g[h] / 2 - 1, D = Math.min(f[v], E), O = Math.min(f[y], E), k = D, A = w - g[h] - O, j = w / 2 - g[h] / 2 + T, M = ae(k, j, A), N = !c.arrow && te(i) != null && j !== M && a.reference[h] / 2 - (j < k ? D : O) - g[h] / 2 < 0, P = N ? j < k ? j - k : j - A : 0;
|
|
982
983
|
return {
|
|
983
984
|
[m]: p[m] + P,
|
|
984
985
|
data: {
|
|
@@ -1025,7 +1026,7 @@ var ft = (e) => ({
|
|
|
1025
1026
|
height: e.documentElement.clientHeight
|
|
1026
1027
|
};
|
|
1027
1028
|
} else await a.isElement?.(u) && (d = await a.getDimensions(u));
|
|
1028
|
-
let f =
|
|
1029
|
+
let f = F(s), p = t, h = n;
|
|
1029
1030
|
f === "left" && (p = d.width - (t + r.width)), f === "top" && (h = d.height - (n + r.height));
|
|
1030
1031
|
let g = f === "left" ? "right" : gt.sideX, _ = f === "top" ? "bottom" : gt.sideY;
|
|
1031
1032
|
return {
|
|
@@ -1052,8 +1053,8 @@ function vt(e, t, n) {
|
|
|
1052
1053
|
function yt(e, t, n) {
|
|
1053
1054
|
let { rects: r, placement: i } = e;
|
|
1054
1055
|
return {
|
|
1055
|
-
side: vt(t,
|
|
1056
|
-
align:
|
|
1056
|
+
side: vt(t, F(i), n),
|
|
1057
|
+
align: te(i) || "center",
|
|
1057
1058
|
anchor: {
|
|
1058
1059
|
width: r.reference.width,
|
|
1059
1060
|
height: r.reference.height
|
|
@@ -1067,31 +1068,31 @@ function yt(e, t, n) {
|
|
|
1067
1068
|
function bt(t) {
|
|
1068
1069
|
let { anchor: n, positionMethod: r = "absolute", side: o = "bottom", sideOffset: s = 0, align: c = "center", alignOffset: l = 0, collisionBoundary: u, collisionPadding: d = 5, sticky: f = !1, arrowPadding: p = 5, disableAnchorTracking: h = !1, inline: g, keepMounted: _ = !1, floatingRootContext: v, mounted: y, collisionAvoidance: b, shiftCrossAxis: x = !1, nodeId: S, adaptiveOrigin: C, lazyFlip: E = !1, externalTree: D } = t, [O, k] = W.useState(null);
|
|
1069
1070
|
!y && O !== null && k(null);
|
|
1070
|
-
let A = b.side || "flip", j = b.align || "flip", M = b.fallbackAxisSide || "end", N = typeof n == "function" ? n : void 0, P = i(N),
|
|
1071
|
+
let A = b.side || "flip", j = b.align || "flip", M = b.fallbackAxisSide || "end", N = typeof n == "function" ? n : void 0, P = i(N), ee = N ? P : n, I = w(n), ne = w(y), L = a() === "rtl", re = O || {
|
|
1071
1072
|
top: "top",
|
|
1072
1073
|
right: "right",
|
|
1073
1074
|
bottom: "bottom",
|
|
1074
1075
|
left: "left",
|
|
1075
|
-
"inline-end":
|
|
1076
|
-
"inline-start":
|
|
1077
|
-
}[o],
|
|
1078
|
-
typeof
|
|
1079
|
-
top:
|
|
1080
|
-
right:
|
|
1081
|
-
bottom:
|
|
1082
|
-
left:
|
|
1083
|
-
} :
|
|
1084
|
-
top: (
|
|
1085
|
-
right: (
|
|
1086
|
-
bottom: (
|
|
1087
|
-
left: (
|
|
1076
|
+
"inline-end": L ? "left" : "right",
|
|
1077
|
+
"inline-start": L ? "right" : "left"
|
|
1078
|
+
}[o], R = c === "center" ? re : `${re}-${c}`, z = d, ie = +(o === "bottom"), ae = +(o === "top"), B = +(o === "right"), oe = +(o === "left");
|
|
1079
|
+
typeof z == "number" ? z = {
|
|
1080
|
+
top: z + ie,
|
|
1081
|
+
right: z + oe,
|
|
1082
|
+
bottom: z + ae,
|
|
1083
|
+
left: z + B
|
|
1084
|
+
} : z &&= {
|
|
1085
|
+
top: (z.top || 0) + ie,
|
|
1086
|
+
right: (z.right || 0) + oe,
|
|
1087
|
+
bottom: (z.bottom || 0) + ae,
|
|
1088
|
+
left: (z.left || 0) + B
|
|
1088
1089
|
};
|
|
1089
|
-
let
|
|
1090
|
+
let V = {
|
|
1090
1091
|
boundary: u === "clipping-ancestors" ? "clippingAncestors" : u,
|
|
1091
|
-
padding:
|
|
1092
|
-
},
|
|
1092
|
+
padding: z
|
|
1093
|
+
}, U = W.useRef(null), se = w(s), ce = w(l), le = typeof s == "function" ? 0 : s, ue = typeof l == "function" ? 0 : l, G = [];
|
|
1093
1094
|
g && G.push(g), G.push(it((e) => {
|
|
1094
|
-
let t = yt(e, o,
|
|
1095
|
+
let t = yt(e, o, L), n = typeof se.current == "function" ? se.current(t) : se.current, r = typeof ce.current == "function" ? ce.current(t) : ce.current;
|
|
1095
1096
|
return {
|
|
1096
1097
|
mainAxis: n,
|
|
1097
1098
|
crossAxis: r,
|
|
@@ -1100,16 +1101,16 @@ function bt(t) {
|
|
|
1100
1101
|
}, [
|
|
1101
1102
|
le,
|
|
1102
1103
|
ue,
|
|
1103
|
-
|
|
1104
|
+
L,
|
|
1104
1105
|
o
|
|
1105
1106
|
]));
|
|
1106
1107
|
let de = j === "none" && A !== "shift", fe = !de && (f || x || A === "shift"), pe = A === "none" ? null : st({
|
|
1107
|
-
...
|
|
1108
|
+
...V,
|
|
1108
1109
|
padding: {
|
|
1109
|
-
top:
|
|
1110
|
-
right:
|
|
1111
|
-
bottom:
|
|
1112
|
-
left:
|
|
1110
|
+
top: z.top + 1,
|
|
1111
|
+
right: z.right + 1,
|
|
1112
|
+
bottom: z.bottom + 1,
|
|
1113
|
+
left: z.left + 1
|
|
1113
1114
|
},
|
|
1114
1115
|
mainAxis: !x && A === "flip",
|
|
1115
1116
|
crossAxis: j === "flip" ? "alignment" : !1,
|
|
@@ -1117,7 +1118,7 @@ function bt(t) {
|
|
|
1117
1118
|
}), me = de ? null : at((e) => {
|
|
1118
1119
|
let t = T(e.elements.floating).documentElement;
|
|
1119
1120
|
return {
|
|
1120
|
-
...
|
|
1121
|
+
...V,
|
|
1121
1122
|
rootBoundary: x ? {
|
|
1122
1123
|
x: 0,
|
|
1123
1124
|
y: 0,
|
|
@@ -1127,35 +1128,35 @@ function bt(t) {
|
|
|
1127
1128
|
mainAxis: j !== "none",
|
|
1128
1129
|
crossAxis: fe,
|
|
1129
1130
|
limiter: f || x ? void 0 : ot((e) => {
|
|
1130
|
-
if (!
|
|
1131
|
-
let { width: t, height: n } =
|
|
1131
|
+
if (!U.current) return {};
|
|
1132
|
+
let { width: t, height: n } = U.current.getBoundingClientRect(), r = H(F(e.placement)), i = r === "y" ? t : n, a = r === "y" ? z.left + z.right : z.top + z.bottom;
|
|
1132
1133
|
return { offset: i / 2 + a / 2 };
|
|
1133
1134
|
})
|
|
1134
1135
|
};
|
|
1135
1136
|
}, [
|
|
1136
|
-
|
|
1137
|
+
V,
|
|
1137
1138
|
f,
|
|
1138
1139
|
x,
|
|
1139
|
-
|
|
1140
|
+
z,
|
|
1140
1141
|
j
|
|
1141
1142
|
]);
|
|
1142
1143
|
A === "shift" || j === "shift" || c === "center" ? G.push(me, pe) : G.push(pe, me), G.push(ct({
|
|
1143
|
-
...
|
|
1144
|
+
...V,
|
|
1144
1145
|
apply({ elements: { floating: e }, availableWidth: t, availableHeight: n, rects: r }) {
|
|
1145
|
-
if (!
|
|
1146
|
+
if (!ne.current) return;
|
|
1146
1147
|
let i = e.style;
|
|
1147
1148
|
i.setProperty("--available-width", `${t}px`), i.setProperty("--available-height", `${n}px`);
|
|
1148
1149
|
let a = m(e).devicePixelRatio || 1, { x: o, y: s, width: c, height: l } = r.reference, u = (Math.round((o + c) * a) - Math.round(o * a)) / a, d = (Math.round((s + l) * a) - Math.round(s * a)) / a;
|
|
1149
1150
|
i.setProperty("--anchor-width", `${u}px`), i.setProperty("--anchor-height", `${d}px`);
|
|
1150
1151
|
}
|
|
1151
1152
|
}), pt((e) => ({
|
|
1152
|
-
element:
|
|
1153
|
+
element: U.current || T(e.elements.floating).createElement("div"),
|
|
1153
1154
|
padding: p,
|
|
1154
1155
|
offsetParent: "floating"
|
|
1155
1156
|
}), [p]), {
|
|
1156
1157
|
name: "transformOrigin",
|
|
1157
1158
|
fn(e) {
|
|
1158
|
-
let { elements: t, middlewareData: n, placement: r, rects: i, y: a } = e, c =
|
|
1159
|
+
let { elements: t, middlewareData: n, placement: r, rects: i, y: a } = e, c = F(r), l = H(c), u = U.current, d = n.arrow?.x || 0, f = n.arrow?.y || 0, p = u?.clientWidth || 0, m = u?.clientHeight || 0, h = d + p / 2, g = f + m / 2, _ = Math.abs(n.shift?.y || 0), v = i.reference.height / 2, y = typeof s == "function" ? s(yt(e, o, L)) : s, b = _ > y, x = {
|
|
1159
1160
|
top: `${h}px calc(100% + ${y}px)`,
|
|
1160
1161
|
bottom: `${h}px ${-y}px`,
|
|
1161
1162
|
left: `calc(100% + ${y}px) ${g}px`,
|
|
@@ -1177,7 +1178,7 @@ function bt(t) {
|
|
|
1177
1178
|
}), [h]), { refs: K, elements: q, x: ge, y: _e, middlewareData: J, update: ve, placement: ye, context: be, isPositioned: Y, floatingStyles: X } = dt({
|
|
1178
1179
|
rootContext: v,
|
|
1179
1180
|
open: _ ? y : void 0,
|
|
1180
|
-
placement:
|
|
1181
|
+
placement: R,
|
|
1181
1182
|
middleware: G,
|
|
1182
1183
|
strategy: r,
|
|
1183
1184
|
whileElementsMounted: _ ? void 0 : (...e) => We(...e, he),
|
|
@@ -1205,22 +1206,22 @@ function bt(t) {
|
|
|
1205
1206
|
]), Q = W.useRef(null);
|
|
1206
1207
|
e(() => {
|
|
1207
1208
|
if (!y) return;
|
|
1208
|
-
let e =
|
|
1209
|
+
let e = I.current, t = typeof e == "function" ? e() : e, n = (xt(t) ? t.current : t) || null;
|
|
1209
1210
|
n !== Q.current && (K.setPositionReference(n), Q.current = n);
|
|
1210
1211
|
}, [
|
|
1211
1212
|
y,
|
|
1212
1213
|
K,
|
|
1213
|
-
|
|
1214
|
-
|
|
1214
|
+
ee,
|
|
1215
|
+
I
|
|
1215
1216
|
]), W.useEffect(() => {
|
|
1216
1217
|
if (!y) return;
|
|
1217
|
-
let e =
|
|
1218
|
+
let e = I.current;
|
|
1218
1219
|
typeof e != "function" && xt(e) && e.current !== Q.current && (K.setPositionReference(e.current), Q.current = e.current);
|
|
1219
1220
|
}, [
|
|
1220
1221
|
y,
|
|
1221
1222
|
K,
|
|
1222
|
-
|
|
1223
|
-
|
|
1223
|
+
ee,
|
|
1224
|
+
I
|
|
1224
1225
|
]), W.useEffect(() => {
|
|
1225
1226
|
if (_ && y && q.reference && q.floating) return We(q.reference, q.floating, ve, he);
|
|
1226
1227
|
}, [
|
|
@@ -1230,7 +1231,7 @@ function bt(t) {
|
|
|
1230
1231
|
ve,
|
|
1231
1232
|
he
|
|
1232
1233
|
]);
|
|
1233
|
-
let $ =
|
|
1234
|
+
let $ = F(ye), we = vt(o, $, L), Te = te(ye) || "center", Ee = !!J.hide?.referenceHidden;
|
|
1234
1235
|
e(() => {
|
|
1235
1236
|
E && y && Y && k($);
|
|
1236
1237
|
}, [
|
|
@@ -1247,7 +1248,7 @@ function bt(t) {
|
|
|
1247
1248
|
return W.useMemo(() => ({
|
|
1248
1249
|
positionerStyles: Z,
|
|
1249
1250
|
arrowStyles: De,
|
|
1250
|
-
arrowRef:
|
|
1251
|
+
arrowRef: U,
|
|
1251
1252
|
arrowUncentered: Oe,
|
|
1252
1253
|
side: we,
|
|
1253
1254
|
align: Te,
|
|
@@ -1260,7 +1261,7 @@ function bt(t) {
|
|
|
1260
1261
|
}), [
|
|
1261
1262
|
Z,
|
|
1262
1263
|
De,
|
|
1263
|
-
|
|
1264
|
+
U,
|
|
1264
1265
|
Oe,
|
|
1265
1266
|
we,
|
|
1266
1267
|
Te,
|
|
@@ -1278,7 +1279,7 @@ function xt(e) {
|
|
|
1278
1279
|
//#endregion
|
|
1279
1280
|
//#region ../../node_modules/.bun/@base-ui+react@1.6.0+df7f6a806acd27ca/node_modules/@base-ui/react/utils/getDisabledMountTransitionStyles.mjs
|
|
1280
1281
|
function St(e) {
|
|
1281
|
-
return e === "starting" ?
|
|
1282
|
+
return e === "starting" ? se : n;
|
|
1282
1283
|
}
|
|
1283
1284
|
//#endregion
|
|
1284
1285
|
//#region ../../node_modules/.bun/@base-ui+react@1.6.0+df7f6a806acd27ca/node_modules/@base-ui/react/utils/usePositioner.mjs
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { t as e } from "./useIsoLayoutEffect-4LGv3HzC.js";
|
|
3
|
+
import { t } from "./useAnimationFrame-jkCXMP_8.js";
|
|
4
|
+
import * as n from "react";
|
|
5
|
+
//#region ../../node_modules/.bun/@base-ui+react@1.6.0+df7f6a806acd27ca/node_modules/@base-ui/react/internals/useTransitionStatus.mjs
|
|
6
|
+
function r(r, i = !1, a = !1) {
|
|
7
|
+
let [o, s] = n.useState(r && i ? "idle" : void 0), [c, l] = n.useState(r);
|
|
8
|
+
return r && !c && (l(!0), s("starting")), !r && c && o !== "ending" && !a && s("ending"), !r && !c && o === "ending" && s(void 0), e(() => {
|
|
9
|
+
if (!r && c && o !== "ending" && a) {
|
|
10
|
+
let e = t.request(() => {
|
|
11
|
+
s("ending");
|
|
12
|
+
});
|
|
13
|
+
return () => {
|
|
14
|
+
t.cancel(e);
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
}, [
|
|
18
|
+
r,
|
|
19
|
+
c,
|
|
20
|
+
o,
|
|
21
|
+
a
|
|
22
|
+
]), e(() => {
|
|
23
|
+
if (!r || i) return;
|
|
24
|
+
let e = t.request(() => {
|
|
25
|
+
s(void 0);
|
|
26
|
+
});
|
|
27
|
+
return () => {
|
|
28
|
+
t.cancel(e);
|
|
29
|
+
};
|
|
30
|
+
}, [i, r]), e(() => {
|
|
31
|
+
if (!r || !i) return;
|
|
32
|
+
r && c && o !== "idle" && s("starting");
|
|
33
|
+
let e = t.request(() => {
|
|
34
|
+
s("idle");
|
|
35
|
+
});
|
|
36
|
+
return () => {
|
|
37
|
+
t.cancel(e);
|
|
38
|
+
};
|
|
39
|
+
}, [
|
|
40
|
+
i,
|
|
41
|
+
r,
|
|
42
|
+
c,
|
|
43
|
+
o
|
|
44
|
+
]), {
|
|
45
|
+
mounted: c,
|
|
46
|
+
setMounted: l,
|
|
47
|
+
transitionStatus: o
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
//#endregion
|
|
51
|
+
export { r as t };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { c as e, t } from "./createBaseUIEventDetails-C_dwdqj4.js";
|
|
3
|
-
import {
|
|
3
|
+
import { S as n, b as r, v as i, x as a } from "./ReactStore-C3H8e2ha.js";
|
|
4
4
|
import { n as o } from "./shadowDom-BACsbimN.js";
|
|
5
5
|
import * as s from "react";
|
|
6
6
|
import * as c from "react-dom";
|
|
@@ -14,17 +14,17 @@ function l(l, u) {
|
|
|
14
14
|
}
|
|
15
15
|
function p(a) {
|
|
16
16
|
let s = l.select("positionerElement");
|
|
17
|
-
if (s &&
|
|
17
|
+
if (s && n(a, s)) l.context.beforeContentFocusGuardRef.current?.focus();
|
|
18
18
|
else {
|
|
19
19
|
c.flushSync(() => {
|
|
20
20
|
l.setOpen(!1, t(e, a.nativeEvent, a.currentTarget));
|
|
21
21
|
});
|
|
22
|
-
let
|
|
23
|
-
for (;
|
|
24
|
-
let e =
|
|
25
|
-
if (
|
|
22
|
+
let n = r(l.context.triggerFocusTargetRef.current || u.current);
|
|
23
|
+
for (; n !== null && o(s, n);) {
|
|
24
|
+
let e = n;
|
|
25
|
+
if (n = i(n), n === e) break;
|
|
26
26
|
}
|
|
27
|
-
|
|
27
|
+
n?.focus();
|
|
28
28
|
}
|
|
29
29
|
}
|
|
30
30
|
return {
|