@mcp-use/inspector 20.0.0-beta.6 → 20.0.0-beta.7
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/cdn/{AnimatePresence-Dcw-FOy8.js → AnimatePresence-D1bZ5_-l.js} +79 -78
- package/dist/cdn/{ChatTab-D6J3Gyp7.js → ChatTab-DtUGK07C.js} +1951 -1932
- package/dist/cdn/CheckboxIndicator-BjF73mGX.js +252 -0
- package/dist/cdn/{ConnectionSettingsForm-CWQueI8J.js → ConnectionSettingsForm-CNuMa6jp.js} +202 -202
- package/dist/cdn/{ConnectionSettingsTab-FGyt3QaI.js → ConnectionSettingsTab-qSVQ1aIF.js} +36 -35
- package/dist/cdn/{ElicitationTab-CL1KJ0bz.js → ElicitationTab-PEmEDvC5.js} +47 -46
- package/dist/cdn/{FormContext-tmgN_Vdr.js → FormContext-NtUiZclE.js} +26 -26
- package/dist/cdn/{InspectorContext-UjtEbNod.js → InspectorContext-BBKCdfmK.js} +1 -1
- package/dist/cdn/{JSONDisplay-BFxf5oEu.js → JSONDisplay-BJqMz7Ny.js} +22 -22
- package/dist/cdn/{ListTabHeader-Cv-GmtGF.js → ListTabHeader-DzmTtN1e.js} +20 -19
- package/dist/cdn/{WidgetWrapper-CruwjBOd.js → MCPAppsDebugControls-BpP-Ifap.js} +514 -550
- package/dist/cdn/{ManufactOAuthCallback-B98kSYCj.js → ManufactOAuthCallback-ChbbjFIT.js} +2 -2
- package/dist/cdn/{MarkdownRenderer-gLqUICEd.js → MarkdownRenderer-bX1BrKgI.js} +23 -23
- package/dist/cdn/McpAppsViewPanel-jlsYQ7uS.js +56 -0
- package/dist/cdn/{NotificationsTab-CeImSrhx.js → NotificationsTab-B7uebqMV.js} +21 -21
- package/dist/cdn/{OAuthCallback-Bg2bP-o9.js → OAuthCallback--NZdLoWx.js} +3 -3
- package/dist/cdn/PromptsTab-BlXDcau3.js +902 -0
- package/dist/cdn/{ResourcesTab-CQkKni-P.js → ResourcesTab-D45_JojP.js} +116 -114
- package/dist/cdn/{SamplingTab-D8q-iCMc.js → SamplingTab-r7tImM6L.js} +34 -33
- package/dist/cdn/{ServerMetadataTab-CvrKX8fz.js → ServerMetadataTab-BM3VhSLf.js} +9 -9
- package/dist/cdn/{StatusIcon-D0-ARyOh.js → StatusIcon-Q3n3YRtE.js} +10 -11
- package/dist/cdn/{ToolsTab-6xaVH43x.js → ToolsTab-DOAO8HnS.js} +664 -652
- package/dist/cdn/{ViewPreview-Ohh6JwOn.js → ViewPreview-CBhrVdwx.js} +3 -3
- package/dist/cdn/{WidgetDebugContext-D4usL_MA.js → WidgetDebugContext-B6yoOVVV.js} +1 -11
- package/dist/cdn/WidgetWrapper-BlbQAh_X.js +12 -0
- package/dist/cdn/{bell-CGjAO_0s.js → bell-GrTZcnD2.js} +1 -1
- package/dist/cdn/{browser-CbQIH4w2.js → browser-DG2Z8392.js} +1 -1
- package/dist/cdn/{brush-B_mKhyxG.js → brush-CelVvMGp.js} +1 -1
- package/dist/cdn/button-CB4uOoUV.js +2509 -0
- package/dist/cdn/card-BA-DQk-G.js +41 -0
- package/dist/cdn/{checkbox-By0FklhG.js → checkbox-kwVa4gRX.js} +7 -7
- package/dist/cdn/{clock-CmUbSx_B.js → clock-YMF8Gtw5.js} +1 -1
- package/dist/cdn/{code-V_0nf5rg.js → code-C8sN2OGR.js} +1 -1
- package/dist/cdn/{jsx-runtime-CIxvMpEo.js → createLucideIcon-BONxC1L5.js} +57 -24
- package/dist/cdn/{dialog-BsDpuJd3.js → dialog-CJGnC5Ag.js} +171 -171
- package/dist/cdn/{dist-DaMB0Su9.js → dist-CTJnCYmk.js} +1 -1
- package/dist/cdn/{dist-CXHFvGre.js → dist-SxRsB1iS.js} +3 -3
- package/dist/cdn/{external-link-CjmfT6rW.js → external-link-Bo4lQxr1.js} +1 -1
- package/dist/cdn/{eye-B7H96av8.js → eye-pSGG7nvf.js} +1 -1
- package/dist/cdn/{folder-open-B3lu2rG_.js → folder-open-aM8CPtBO.js} +1 -1
- package/dist/cdn/{hash-BVQnWi7q.js → hash-DDs2vE1k.js} +1 -1
- package/dist/cdn/{history-Csw4rb44.js → history-BfUFpL1d.js} +1 -1
- package/dist/cdn/{index-browser-DkQOzkvX.js → index-browser-Dm3R1Mfe.js} +1 -1
- package/dist/cdn/{info-CNiOwqkf.js → info-BMkB68mB.js} +1 -1
- package/dist/cdn/{input-C2OBd4PJ.js → input-BCpgLXU1.js} +2993 -5499
- package/dist/cdn/inspector.css +1 -1
- package/dist/cdn/inspector.js +7106 -7140
- package/dist/cdn/{label-B9Jmm9be.js → label-A0UGV8FE.js} +9 -9
- package/dist/cdn/{loader-circle-BLy9A_pp.js → loader-circle-BKRHJEB7.js} +1 -1
- package/dist/cdn/{maximize-2-CH5Lq90B.js → maximize-2-DdrB_spi.js} +1 -1
- package/dist/cdn/{maximize-BALCV_ep.js → maximize-hSOCz133.js} +1 -1
- package/dist/cdn/{message-square-BnxdpJxZ.js → message-square-D3tKB3uJ.js} +1 -1
- package/dist/cdn/{not-found-DEtSM_Wd.js → not-found-BajFyZpp.js} +9 -11
- package/dist/cdn/{play-vuZ5PLnI.js → play-B1leulYf.js} +1 -1
- package/dist/cdn/providerMeta-CjGU4rID.js +436 -0
- package/dist/cdn/{react-BLtCruam.js → react-Bl-hSkvn.js} +562 -512
- package/dist/cdn/{refresh-cw-BXY-Pa0U.js → refresh-cw-CyvXrS91.js} +1 -1
- package/dist/cdn/{save-Tgil_AJZ.js → save-CmdEPUAm.js} +1 -1
- package/dist/cdn/{select-DDdiIPR2.js → select-CCFHjOGk.js} +808 -807
- package/dist/cdn/{servers-Dm72iTpY.js → servers-Dd0Vcp81.js} +5 -1
- package/dist/cdn/{shared-DaILIQPP.js → shared-CJVHJhag.js} +36 -36
- package/dist/cdn/{sheet-Br_l2kry.js → sheet-oyq1mIyg.js} +620 -619
- package/dist/cdn/{sparkles-BntO2rDR.js → sparkles-CxeZpVtX.js} +1 -1
- package/dist/cdn/spinner-Be1GlSGX.js +15 -0
- package/dist/cdn/{square-check-big-BvwQ17Bl.js → square-check-big-C_4wbfwF.js} +1 -1
- package/dist/cdn/{switch-C3IyQuid.js → switch-DHXEA_N5.js} +190 -189
- package/dist/cdn/{tabs-subtle-CkdI6Mac.js → tabs-subtle-Dubd6Kj8.js} +269 -268
- package/dist/cdn/{telemetry-C7Ytz2BG.js → telemetry-TwPKZlFf.js} +2 -2
- package/dist/cdn/{textarea-DSbwcFVt.js → textarea-CwmI8_uI.js} +6 -6
- package/dist/cdn/{trash-2-RwpJY5SL.js → trash-2-BhumJAFE.js} +1 -1
- package/dist/cdn/{useAriaLabelledBy-DqAdnppm.js → useAriaLabelledBy-Cra6w3YY.js} +2 -1
- package/dist/cdn/{useCompositeItem-BRqEzYh-.js → useCompositeItem-Dhnm-7el.js} +3 -3
- package/dist/cdn/{useConfig-BW6uQf2m.js → useConfig-leHVjdjl.js} +2 -2
- package/dist/cdn/{useSavedRequests-Ci2I919u.js → useSavedRequests-mSIsDd4c.js} +1 -1
- package/dist/cdn/{useViewHostProps-CINeSkth.js → useViewHostProps-CDOm2w6u.js} +124 -109
- package/dist/cdn/{wrench-DzGmCfnb.js → wrench-DvK20LUT.js} +1 -1
- package/dist/cdn/{x-C3vRQIYu.js → x-EilKPiCX.js} +1 -1
- package/dist/cdn/{zap-Mb-pbw2X.js → zap-0Wr9QO7N.js} +1 -1
- package/dist/cli.js +1 -1
- package/dist/client/components/ChatTab.d.ts.map +1 -1
- package/dist/client/components/MCPAppsDebugControls.d.ts.map +1 -1
- package/dist/client/components/ToolsTab.d.ts.map +1 -1
- package/dist/client/components/chat/ConfigurationDialog.d.ts.map +1 -1
- package/dist/client/components/chat/ToolResultRenderer.d.ts.map +1 -1
- package/dist/client/components/mcp-apps/McpAppsViewPanel.d.ts +29 -0
- package/dist/client/components/mcp-apps/McpAppsViewPanel.d.ts.map +1 -0
- package/dist/client/components/tools/ToolExecutionPanel.d.ts.map +1 -1
- package/dist/client/components/tools/ToolResultDisplay.d.ts +2 -1
- package/dist/client/components/tools/ToolResultDisplay.d.ts.map +1 -1
- package/dist/client/components/tools/useToolsTabNavigation.d.ts.map +1 -1
- package/dist/client/components/ui/MeshGradientCanvas.d.ts.map +1 -1
- package/dist/client/components/ui/mesh-animation-pause.d.ts +14 -0
- package/dist/client/components/ui/mesh-animation-pause.d.ts.map +1 -0
- package/dist/client/components/ui/mesh-gradient-colors.d.ts +6 -0
- package/dist/client/components/ui/mesh-gradient-colors.d.ts.map +1 -0
- package/dist/client/components/ui/mesh-tab-background.d.ts +1 -1
- package/dist/client/components/ui/mesh-tab-background.d.ts.map +1 -1
- package/dist/client/components/ui/not-found.d.ts.map +1 -1
- package/dist/client/context/WidgetDebugContext.d.ts +1 -11
- package/dist/client/context/WidgetDebugContext.d.ts.map +1 -1
- package/dist/client/hooks/useDeviceViewport.d.ts +1 -5
- package/dist/client/hooks/useDeviceViewport.d.ts.map +1 -1
- package/dist/client/hooks/useViewHostProps.d.ts +1 -1
- package/dist/client/hooks/useViewHostProps.d.ts.map +1 -1
- package/dist/client/index.js +2086 -1860
- package/dist/client/utils/servers.d.ts +5 -0
- package/dist/client/utils/servers.d.ts.map +1 -1
- package/dist/server/cdn-shell.js +2 -2
- package/dist/server/{chunk-GBY4WAVP.js → chunk-5GVQGIAX.js} +1 -1
- package/dist/server/{chunk-IFF5T5J4.js → chunk-UZZDBVKF.js} +1 -1
- package/dist/server/{chunk-NUHI6MJ6.js → chunk-VFVFLXKP.js} +1 -1
- package/dist/server/cli.js +2 -2
- package/dist/server/index.js +3 -3
- package/dist/server/middleware.js +3 -3
- package/dist/server/version.js +1 -1
- package/dist/web/assets/AnimatePresence-FfDQQNFJ.js +9 -0
- package/dist/web/assets/ChatTab-B6ubLbeA.js +18 -0
- package/dist/web/assets/ConnectionSettingsTab-Cb2eDgEu.js +1 -0
- package/dist/web/assets/ElicitationTab-CbnCrmu9.js +1 -0
- package/dist/web/assets/FormContext-sV-yByKz.js +1 -0
- package/dist/web/assets/ListTabHeader-CrGae306.js +1 -0
- package/dist/web/assets/MCPAppsDebugControls-sRglMhat.js +34 -0
- package/dist/web/assets/{ManufactOAuthCallback-BRO6TPkZ.js → ManufactOAuthCallback-D4uYGigW.js} +1 -1
- package/dist/web/assets/{MarkdownRenderer-gaJFjbtr.js → MarkdownRenderer-Cwxp9fLj.js} +2 -2
- package/dist/web/assets/McpAppsViewPanel-jQYFoZNX.js +1 -0
- package/dist/web/assets/{NotificationsTab-LYcfRjyd.js → NotificationsTab-DuSm762_.js} +1 -1
- package/dist/web/assets/{OAuthCallback-D8UItgTB.js → OAuthCallback-VLHlUe2c.js} +1 -1
- package/dist/web/assets/PromptsTab-DK6XZxR8.js +15 -0
- package/dist/web/assets/ResourcesTab-CUE4MAtJ.js +2 -0
- package/dist/web/assets/SamplingTab-BYNkVCTu.js +1 -0
- package/dist/web/assets/ServerMetadataTab-DWjNFMbq.js +1 -0
- package/dist/web/assets/ToolsTab-BisWWY2p.js +8 -0
- package/dist/web/assets/{ViewPreview--z6jL0Zg.js → ViewPreview-COrmPpRr.js} +1 -1
- package/dist/web/assets/WidgetWrapper-cv_BM1bY.js +1 -0
- package/dist/web/assets/{brush--0LobUi4.js → brush-DX0UZ_pI.js} +1 -1
- package/dist/web/assets/button-C8Xa2k4x.js +1 -0
- package/dist/web/assets/checkbox-B6dtF73d.js +1 -0
- package/dist/web/assets/code-B14rVdNt.js +1 -0
- package/dist/web/assets/createLucideIcon-BEHeJH0M.js +1 -0
- package/dist/web/assets/{dist-B8sA8Zml.js → dist-9Oy7e0v8.js} +4 -4
- package/dist/web/assets/index-BMaSsizY.js +499 -0
- package/dist/web/assets/index-D7TVTIt9.css +1 -0
- package/dist/web/assets/input-C0OQCUZy.js +1 -0
- package/dist/web/assets/{label-Cdim77Jw.js → label-CI7JWQOo.js} +1 -1
- package/dist/web/assets/{maximize-2-BTT9QQU9.js → maximize-2-Br1WQzT2.js} +1 -1
- package/dist/web/assets/{maximize-_O55kFcr.js → maximize-CJNgRe6S.js} +1 -1
- package/dist/web/assets/{refresh-cw-C9wQl8_d.js → refresh-cw-B5iaAZKn.js} +1 -1
- package/dist/web/assets/{save-B-MsgxX9.js → save-TM6fvNrt.js} +1 -1
- package/dist/web/assets/select-D6jzbLJn.js +1 -0
- package/dist/web/assets/shared-CFs9CZfB.js +1 -0
- package/dist/web/assets/{sparkles-2OAsc1aP.js → sparkles-BGYTDThM.js} +1 -1
- package/dist/web/assets/tabs-subtle-D2XkWhLL.js +1 -0
- package/dist/web/assets/textarea-CRTXuRmE.js +1 -0
- package/dist/web/assets/{useConfig-BAsKhUxf.js → useConfig-B6tXvJOb.js} +1 -1
- package/dist/web/assets/useViewHostProps-DZqOwiAm.js +1 -0
- package/dist/web/assets/{zap-Du2Uc5pa.js → zap-BDWHCVHU.js} +1 -1
- package/dist/web/index.html +10 -10
- package/package.json +4 -4
- package/dist/cdn/CheckboxIndicator-Bt4IICtv.js +0 -251
- package/dist/cdn/PromptsTab-C4LuwyWN.js +0 -901
- package/dist/cdn/card-DgiYnSg-.js +0 -41
- package/dist/cdn/createLucideIcon-C5fZZ6oB.js +0 -38
- package/dist/cdn/providerMeta-BQIfHuNL.js +0 -379
- package/dist/cdn/spinner-jQtC7EBj.js +0 -15
- package/dist/web/assets/AnimatePresence-C5p0yiY1.js +0 -9
- package/dist/web/assets/ChatTab-CsBPVCSc.js +0 -18
- package/dist/web/assets/ConnectionSettingsTab-DQTXfnl1.js +0 -1
- package/dist/web/assets/ElicitationTab-_FKB7nNG.js +0 -1
- package/dist/web/assets/FormContext-DH2caWKO.js +0 -1
- package/dist/web/assets/ListTabHeader-R17w_JsB.js +0 -1
- package/dist/web/assets/PromptsTab-B2uVMRR2.js +0 -15
- package/dist/web/assets/ResourcesTab-DhOZYPjE.js +0 -2
- package/dist/web/assets/SamplingTab-C-oY2hoi.js +0 -1
- package/dist/web/assets/ServerMetadataTab-BkTxO5KS.js +0 -1
- package/dist/web/assets/ToolsTab-DupHgo7A.js +0 -8
- package/dist/web/assets/WidgetWrapper-CZaEVEw4.js +0 -34
- package/dist/web/assets/checkbox-BQ9mI_6k.js +0 -1
- package/dist/web/assets/code-tME-5H6D.js +0 -1
- package/dist/web/assets/createLucideIcon-B3b8EU0b.js +0 -1
- package/dist/web/assets/index-C_fCIJ4C.js +0 -492
- package/dist/web/assets/index-fBX3akc8.css +0 -1
- package/dist/web/assets/input-CLYhA7PK.js +0 -1
- package/dist/web/assets/jsx-runtime-Cjj9sGSy.js +0 -1
- package/dist/web/assets/select-CJ57-Bor.js +0 -1
- package/dist/web/assets/shared-CCC9rTz4.js +0 -1
- package/dist/web/assets/tabs-subtle-246ABJqx.js +0 -1
- package/dist/web/assets/textarea-DLAmNVf_.js +0 -1
- package/dist/web/assets/useViewHostProps-CV5zBxUb.js +0 -1
|
@@ -1,24 +1,25 @@
|
|
|
1
1
|
import { s as e, t } from "./react-BIs9pQ3H.js";
|
|
2
|
-
import { A as n, B as r, D as i, E as a, F as o, I as s, L as c, M as l, Mn as u, N as d, Nn as f, O as p,
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { c as
|
|
7
|
-
import { t as he } from "./
|
|
2
|
+
import { A as n, B as r, D as i, E as a, F as o, I as s, L as c, M as l, Mn as u, N as d, Nn as f, O as p, P as m, R as h, S as g, T as _, U as v, Yn as y, _ as b, an as x, b as S, f as C, g as w, h as T, in as E, j as D, k as O, m as k, s as A, v as j, w as M, x as ee, y as N, z as P } from "./input-BCpgLXU1.js";
|
|
3
|
+
import { n as te } from "./createLucideIcon-BONxC1L5.js";
|
|
4
|
+
import { U as F, a as ne, d as re, g as ie, h as ae, k as oe, m as I, s as se, u as ce } from "./button-CB4uOoUV.js";
|
|
5
|
+
import { n as le } from "./label-A0UGV8FE.js";
|
|
6
|
+
import { c as ue } from "./select-CCFHjOGk.js";
|
|
7
|
+
import { c as L, i as de, l as fe, o as pe, r as me, t as he } from "./FormContext-NtUiZclE.js";
|
|
8
|
+
import { t as ge } from "./useAriaLabelledBy-Cra6w3YY.js";
|
|
8
9
|
//#region ../../node_modules/.pnpm/motion-utils@12.39.0/node_modules/motion-utils/dist/es/wrap.mjs
|
|
9
|
-
var
|
|
10
|
+
var _e = (e, t, n) => {
|
|
10
11
|
let r = t - e;
|
|
11
12
|
return ((n - e) % r + r) % r + e;
|
|
12
13
|
};
|
|
13
14
|
//#endregion
|
|
14
15
|
//#region ../../node_modules/.pnpm/motion-utils@12.39.0/node_modules/motion-utils/dist/es/easing/utils/get-easing-for-segment.mjs
|
|
15
16
|
/*#__NO_SIDE_EFFECTS__*/
|
|
16
|
-
function
|
|
17
|
-
return
|
|
17
|
+
function R(e, t) {
|
|
18
|
+
return m(e) ? e[_e(0, e.length, t)] : e;
|
|
18
19
|
}
|
|
19
20
|
//#endregion
|
|
20
21
|
//#region ../../node_modules/.pnpm/motion-dom@12.42.2/node_modules/motion-dom/dist/es/animation/GroupAnimation.mjs
|
|
21
|
-
var
|
|
22
|
+
var z = class {
|
|
22
23
|
constructor(e) {
|
|
23
24
|
this.stop = () => this.runAll("stop"), this.animations = e.filter(Boolean);
|
|
24
25
|
}
|
|
@@ -58,10 +59,10 @@ var B = class {
|
|
|
58
59
|
return this.getAll("startTime");
|
|
59
60
|
}
|
|
60
61
|
get duration() {
|
|
61
|
-
return
|
|
62
|
+
return B(this.animations, "duration");
|
|
62
63
|
}
|
|
63
64
|
get iterationDuration() {
|
|
64
|
-
return
|
|
65
|
+
return B(this.animations, "iterationDuration");
|
|
65
66
|
}
|
|
66
67
|
runAll(e) {
|
|
67
68
|
this.animations.forEach((t) => t[e]());
|
|
@@ -79,7 +80,7 @@ var B = class {
|
|
|
79
80
|
this.runAll("complete");
|
|
80
81
|
}
|
|
81
82
|
};
|
|
82
|
-
function
|
|
83
|
+
function B(e, t) {
|
|
83
84
|
let n = 0;
|
|
84
85
|
for (let r = 0; r < e.length; r++) {
|
|
85
86
|
let i = e[r][t];
|
|
@@ -89,22 +90,22 @@ function V(e, t) {
|
|
|
89
90
|
}
|
|
90
91
|
//#endregion
|
|
91
92
|
//#region ../../node_modules/.pnpm/motion-dom@12.42.2/node_modules/motion-dom/dist/es/animation/GroupAnimationWithThen.mjs
|
|
92
|
-
var
|
|
93
|
+
var V = class extends z {
|
|
93
94
|
then(e, t) {
|
|
94
95
|
return this.finished.finally(e).then(() => {});
|
|
95
96
|
}
|
|
96
97
|
};
|
|
97
98
|
//#endregion
|
|
98
99
|
//#region ../../node_modules/.pnpm/motion-dom@12.42.2/node_modules/motion-dom/dist/es/render/object/ObjectVisualElement.mjs
|
|
99
|
-
function
|
|
100
|
+
function H(e, t) {
|
|
100
101
|
return e in t;
|
|
101
102
|
}
|
|
102
|
-
var
|
|
103
|
+
var ve = class extends j {
|
|
103
104
|
constructor() {
|
|
104
105
|
super(...arguments), this.type = "object";
|
|
105
106
|
}
|
|
106
107
|
readValueFromInstance(e, t) {
|
|
107
|
-
if (
|
|
108
|
+
if (H(t, e)) {
|
|
108
109
|
let n = e[t];
|
|
109
110
|
if (typeof n == "string" || typeof n == "number") return n;
|
|
110
111
|
}
|
|
@@ -114,7 +115,7 @@ var _e = class extends ae {
|
|
|
114
115
|
delete t.output[e];
|
|
115
116
|
}
|
|
116
117
|
measureInstanceViewportBox() {
|
|
117
|
-
return
|
|
118
|
+
return S();
|
|
118
119
|
}
|
|
119
120
|
build(e, t) {
|
|
120
121
|
Object.assign(e.output, t);
|
|
@@ -125,66 +126,66 @@ var _e = class extends ae {
|
|
|
125
126
|
sortInstanceNodePosition() {
|
|
126
127
|
return 0;
|
|
127
128
|
}
|
|
128
|
-
},
|
|
129
|
-
function
|
|
130
|
-
let t =
|
|
129
|
+
}, U = /* @__PURE__ */ e(t(), 1);
|
|
130
|
+
function ye(e) {
|
|
131
|
+
let t = v(() => i(e)), { isStatic: n } = (0, U.useContext)(k);
|
|
131
132
|
if (n) {
|
|
132
|
-
let [, n] = (0,
|
|
133
|
-
(0,
|
|
133
|
+
let [, n] = (0, U.useState)(e);
|
|
134
|
+
(0, U.useEffect)(() => t.on("change", n), []);
|
|
134
135
|
}
|
|
135
136
|
return t;
|
|
136
137
|
}
|
|
137
138
|
//#endregion
|
|
138
139
|
//#region ../../node_modules/.pnpm/framer-motion@12.42.2_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/framer-motion/dist/es/animation/utils/is-dom-keyframes.mjs
|
|
139
|
-
function
|
|
140
|
+
function W(e) {
|
|
140
141
|
return typeof e == "object" && !Array.isArray(e);
|
|
141
142
|
}
|
|
142
143
|
//#endregion
|
|
143
144
|
//#region ../../node_modules/.pnpm/framer-motion@12.42.2_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/framer-motion/dist/es/animation/animate/resolve-subjects.mjs
|
|
144
|
-
function
|
|
145
|
-
return e == null ? [] : typeof e == "string" &&
|
|
145
|
+
function G(e, t, n, r) {
|
|
146
|
+
return e == null ? [] : typeof e == "string" && W(t) ? M(e, n, r) : e instanceof NodeList ? Array.from(e) : Array.isArray(e) ? e.filter((e) => e != null) : [e];
|
|
146
147
|
}
|
|
147
148
|
//#endregion
|
|
148
149
|
//#region ../../node_modules/.pnpm/framer-motion@12.42.2_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/framer-motion/dist/es/animation/sequence/utils/calc-repeat-duration.mjs
|
|
149
|
-
function
|
|
150
|
+
function be(e, t, n) {
|
|
150
151
|
return e * (t + 1) + n * t;
|
|
151
152
|
}
|
|
152
153
|
//#endregion
|
|
153
154
|
//#region ../../node_modules/.pnpm/framer-motion@12.42.2_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/framer-motion/dist/es/animation/sequence/utils/calc-time.mjs
|
|
154
|
-
function
|
|
155
|
+
function K(e, t, n, r) {
|
|
155
156
|
return typeof t == "number" ? t : t.startsWith("-") || t.startsWith("+") ? Math.max(0, e + parseFloat(t)) : t === "<" ? n : t.startsWith("<") ? Math.max(0, n + parseFloat(t.slice(1))) : r.get(t) ?? e;
|
|
156
157
|
}
|
|
157
158
|
//#endregion
|
|
158
159
|
//#region ../../node_modules/.pnpm/framer-motion@12.42.2_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/framer-motion/dist/es/animation/sequence/utils/edit.mjs
|
|
159
|
-
function
|
|
160
|
+
function q(e, t, n) {
|
|
160
161
|
for (let i = 0; i < e.length; i++) {
|
|
161
162
|
let a = e[i];
|
|
162
163
|
a.at > t && a.at < n && (r(e, a), i--);
|
|
163
164
|
}
|
|
164
165
|
}
|
|
165
|
-
function
|
|
166
|
-
|
|
166
|
+
function xe(e, t, n, r, i, a) {
|
|
167
|
+
q(e, i, a);
|
|
167
168
|
for (let o = 0; o < t.length; o++) e.push({
|
|
168
169
|
value: t[o],
|
|
169
170
|
at: d(i, a, r[o]),
|
|
170
|
-
easing: /* @__PURE__ */
|
|
171
|
+
easing: /* @__PURE__ */ R(n, o)
|
|
171
172
|
});
|
|
172
173
|
}
|
|
173
174
|
//#endregion
|
|
174
175
|
//#region ../../node_modules/.pnpm/framer-motion@12.42.2_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/framer-motion/dist/es/animation/sequence/utils/normalize-times.mjs
|
|
175
|
-
function
|
|
176
|
+
function Se(e, t, n = 0) {
|
|
176
177
|
let r = t + 1 + t * n;
|
|
177
178
|
for (let t = 0; t < e.length; t++) e[t] = e[t] / r;
|
|
178
179
|
}
|
|
179
180
|
//#endregion
|
|
180
181
|
//#region ../../node_modules/.pnpm/framer-motion@12.42.2_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/framer-motion/dist/es/animation/sequence/utils/sort.mjs
|
|
181
|
-
function
|
|
182
|
+
function Ce(e, t) {
|
|
182
183
|
return e.at === t.at ? e.value === null ? 1 : t.value === null ? -1 : 0 : e.at - t.at;
|
|
183
184
|
}
|
|
184
185
|
//#endregion
|
|
185
186
|
//#region ../../node_modules/.pnpm/framer-motion@12.42.2_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/framer-motion/dist/es/animation/sequence/create.mjs
|
|
186
|
-
var
|
|
187
|
-
function
|
|
187
|
+
var we = "easeInOut", J = 20;
|
|
188
|
+
function Te(e, { defaultTransition: t = {}, ...r } = {}, i, u) {
|
|
188
189
|
let d = t.duration || .3, f = /* @__PURE__ */ new Map(), m = /* @__PURE__ */ new Map(), h = {}, g = /* @__PURE__ */ new Map(), _ = 0, v = 0, y = 0;
|
|
189
190
|
for (let r = 0; r < e.length; r++) {
|
|
190
191
|
let c = e[r];
|
|
@@ -192,16 +193,16 @@ function we(e, { defaultTransition: t = {}, ...r } = {}, i, u) {
|
|
|
192
193
|
g.set(c, v);
|
|
193
194
|
continue;
|
|
194
195
|
} else if (!Array.isArray(c)) {
|
|
195
|
-
g.set(c.name,
|
|
196
|
+
g.set(c.name, K(v, c.at, _, g));
|
|
196
197
|
continue;
|
|
197
198
|
}
|
|
198
199
|
let [f, b, x = {}] = c;
|
|
199
|
-
x.at !== void 0 && (v =
|
|
200
|
+
x.at !== void 0 && (v = K(v, x.at, _, g));
|
|
200
201
|
let S = 0, C = (e, r, i, a = 0, c = 0) => {
|
|
201
|
-
let f =
|
|
202
|
-
if (D <= 2 &&
|
|
202
|
+
let f = Oe(e), { delay: m = 0, times: h = O(f), type: g = t.type || "keyframes", repeat: _, repeatType: b, repeatDelay: x = 0, ...C } = r, { ease: w = t.ease || "easeOut", duration: T } = r, E = typeof m == "function" ? m(a, c) : m, D = f.length, k = p(g) ? g : u?.[g || "keyframes"];
|
|
203
|
+
if (D <= 2 && k) {
|
|
203
204
|
let e = 100;
|
|
204
|
-
if (D === 2 &&
|
|
205
|
+
if (D === 2 && je(f)) {
|
|
205
206
|
let t = f[1] - f[0];
|
|
206
207
|
e = Math.abs(t);
|
|
207
208
|
}
|
|
@@ -210,16 +211,16 @@ function we(e, { defaultTransition: t = {}, ...r } = {}, i, u) {
|
|
|
210
211
|
...C
|
|
211
212
|
};
|
|
212
213
|
T !== void 0 && (n.duration = s(T));
|
|
213
|
-
let r = l(n, e,
|
|
214
|
+
let r = l(n, e, k);
|
|
214
215
|
w = r.ease, T = r.duration;
|
|
215
216
|
}
|
|
216
217
|
T ??= d;
|
|
217
|
-
let
|
|
218
|
+
let A = v + E;
|
|
218
219
|
h.length === 1 && h[0] === 0 && (h[1] = 1);
|
|
219
|
-
let
|
|
220
|
-
if (
|
|
220
|
+
let j = h.length - f.length;
|
|
221
|
+
if (j > 0 && n(h, j), f.length === 1 && f.unshift(null), _ && P(_ < J, `Sequence segments can't repeat ${_} times — ignoring repeat option. Use a value below ${J} or apply repeat at the sequence level instead.`), _ && _ < J) {
|
|
221
222
|
let e = T > 0 ? x / T : 0;
|
|
222
|
-
T =
|
|
223
|
+
T = be(T, _, x);
|
|
223
224
|
let t = [...f], n = [...h];
|
|
224
225
|
w = Array.isArray(w) ? [...w] : [w];
|
|
225
226
|
let r = [...w], i = b === "reverse" || b === "mirror", a = t, s = r;
|
|
@@ -227,22 +228,22 @@ function we(e, { defaultTransition: t = {}, ...r } = {}, i, u) {
|
|
|
227
228
|
for (let o = 0; o < _; o++) {
|
|
228
229
|
let c = i && o % 2 == 0, l = c ? a : t, u = c ? s : r, d = (o + 1) * (1 + e);
|
|
229
230
|
e > 0 && (f.push(f[f.length - 1]), h.push(d), w.push("linear")), f.push(...l);
|
|
230
|
-
for (let e = 0; e < l.length; e++) h.push(n[e] + d), w.push(e === 0 ? "linear" : /* @__PURE__ */
|
|
231
|
+
for (let e = 0; e < l.length; e++) h.push(n[e] + d), w.push(e === 0 ? "linear" : /* @__PURE__ */ R(u, e - 1));
|
|
231
232
|
}
|
|
232
|
-
|
|
233
|
+
Se(h, _, e);
|
|
233
234
|
}
|
|
234
|
-
let
|
|
235
|
-
|
|
235
|
+
let M = A + T;
|
|
236
|
+
xe(i, f, w, h, A, M), S = Math.max(E + T, S), y = Math.max(M, y);
|
|
236
237
|
};
|
|
237
238
|
if (a(f)) {
|
|
238
|
-
let e =
|
|
239
|
-
C(b, x,
|
|
239
|
+
let e = Ee(f, m);
|
|
240
|
+
C(b, x, De("default", e));
|
|
240
241
|
} else {
|
|
241
|
-
let e =
|
|
242
|
+
let e = G(f, b, i, h), t = e.length;
|
|
242
243
|
for (let n = 0; n < t; n++) {
|
|
243
244
|
b = b, x = x;
|
|
244
|
-
let r = e[n], i =
|
|
245
|
-
for (let e in b) C(b[e],
|
|
245
|
+
let r = e[n], i = Ee(r, m);
|
|
246
|
+
for (let e in b) C(b[e], ke(x, e), De(e, i), n, t);
|
|
246
247
|
}
|
|
247
248
|
}
|
|
248
249
|
_ = v, v += S;
|
|
@@ -250,13 +251,13 @@ function we(e, { defaultTransition: t = {}, ...r } = {}, i, u) {
|
|
|
250
251
|
return m.forEach((e, n) => {
|
|
251
252
|
for (let i in e) {
|
|
252
253
|
let a = e[i];
|
|
253
|
-
a.sort(
|
|
254
|
+
a.sort(Ce);
|
|
254
255
|
let o = [], s = [], l = [];
|
|
255
256
|
for (let e = 0; e < a.length; e++) {
|
|
256
257
|
let { at: t, value: n, easing: r } = a[e];
|
|
257
258
|
o.push(n), s.push(c(0, y, t)), l.push(r || "easeOut");
|
|
258
259
|
}
|
|
259
|
-
s[0] !== 0 && (s.unshift(0), o.unshift(o[0]), l.unshift(
|
|
260
|
+
s[0] !== 0 && (s.unshift(0), o.unshift(o[0]), l.unshift(we)), s[s.length - 1] !== 1 && (s.push(1), o.push(null)), f.has(n) || f.set(n, {
|
|
260
261
|
keyframes: {},
|
|
261
262
|
transition: {}
|
|
262
263
|
});
|
|
@@ -273,25 +274,25 @@ function we(e, { defaultTransition: t = {}, ...r } = {}, i, u) {
|
|
|
273
274
|
}
|
|
274
275
|
}), f;
|
|
275
276
|
}
|
|
276
|
-
function
|
|
277
|
+
function Ee(e, t) {
|
|
277
278
|
return !t.has(e) && t.set(e, {}), t.get(e);
|
|
278
279
|
}
|
|
279
|
-
function
|
|
280
|
+
function De(e, t) {
|
|
280
281
|
return t[e] || (t[e] = []), t[e];
|
|
281
282
|
}
|
|
282
|
-
function
|
|
283
|
+
function Oe(e) {
|
|
283
284
|
return Array.isArray(e) ? e : [e];
|
|
284
285
|
}
|
|
285
|
-
function
|
|
286
|
+
function ke(e, t) {
|
|
286
287
|
return e && e[t] ? {
|
|
287
288
|
...e,
|
|
288
289
|
...e[t]
|
|
289
290
|
} : { ...e };
|
|
290
291
|
}
|
|
291
|
-
var
|
|
292
|
+
var Ae = (e) => typeof e == "number", je = (e) => e.every(Ae);
|
|
292
293
|
//#endregion
|
|
293
294
|
//#region ../../node_modules/.pnpm/framer-motion@12.42.2_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/framer-motion/dist/es/animation/utils/create-visual-element.mjs
|
|
294
|
-
function
|
|
295
|
+
function Me(e) {
|
|
295
296
|
let t = {
|
|
296
297
|
presenceContext: null,
|
|
297
298
|
props: {},
|
|
@@ -305,11 +306,11 @@ function je(e) {
|
|
|
305
306
|
},
|
|
306
307
|
latestValues: {}
|
|
307
308
|
}
|
|
308
|
-
}, n =
|
|
309
|
-
n.mount(e),
|
|
309
|
+
}, n = g(e) && !ee(e) ? new w(t) : new b(t);
|
|
310
|
+
n.mount(e), N.set(e, n);
|
|
310
311
|
}
|
|
311
|
-
function
|
|
312
|
-
let t = new
|
|
312
|
+
function Ne(e) {
|
|
313
|
+
let t = new ve({
|
|
313
314
|
presenceContext: null,
|
|
314
315
|
props: {},
|
|
315
316
|
visualState: {
|
|
@@ -317,25 +318,25 @@ function Me(e) {
|
|
|
317
318
|
latestValues: {}
|
|
318
319
|
}
|
|
319
320
|
});
|
|
320
|
-
t.mount(e),
|
|
321
|
+
t.mount(e), N.set(e, t);
|
|
321
322
|
}
|
|
322
323
|
//#endregion
|
|
323
324
|
//#region ../../node_modules/.pnpm/framer-motion@12.42.2_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/framer-motion/dist/es/animation/animate/subject.mjs
|
|
324
|
-
function
|
|
325
|
-
return a(e) || typeof e == "number" || typeof e == "string" && !
|
|
325
|
+
function Pe(e, t) {
|
|
326
|
+
return a(e) || typeof e == "number" || typeof e == "string" && !W(t);
|
|
326
327
|
}
|
|
327
|
-
function
|
|
328
|
+
function Fe(e, t, n, r) {
|
|
328
329
|
let i = [];
|
|
329
|
-
if (
|
|
330
|
+
if (Pe(e, t)) i.push(T(e, W(t) && t.default || t, n && (n.default || n)));
|
|
330
331
|
else {
|
|
331
332
|
if (e == null) return i;
|
|
332
|
-
let a =
|
|
333
|
-
|
|
333
|
+
let a = G(e, t, r), o = a.length;
|
|
334
|
+
h(!!o, "No valid elements provided.", "no-valid-elements");
|
|
334
335
|
for (let e = 0; e < o; e++) {
|
|
335
|
-
let r = a[e], s = r instanceof Element ?
|
|
336
|
-
|
|
337
|
-
let c =
|
|
338
|
-
"delay" in l && typeof l.delay == "function" && (l.delay = l.delay(e, o)), i.push(...
|
|
336
|
+
let r = a[e], s = r instanceof Element ? Me : Ne;
|
|
337
|
+
N.has(r) || s(r);
|
|
338
|
+
let c = N.get(r), l = { ...n };
|
|
339
|
+
"delay" in l && typeof l.delay == "function" && (l.delay = l.delay(e, o)), i.push(..._(c, {
|
|
339
340
|
...t,
|
|
340
341
|
transition: l
|
|
341
342
|
}, {}));
|
|
@@ -345,9 +346,9 @@ function Pe(e, t, n, r) {
|
|
|
345
346
|
}
|
|
346
347
|
//#endregion
|
|
347
348
|
//#region ../../node_modules/.pnpm/framer-motion@12.42.2_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/framer-motion/dist/es/animation/animate/sequence.mjs
|
|
348
|
-
function
|
|
349
|
+
function Ie(e, t, n) {
|
|
349
350
|
let r = [];
|
|
350
|
-
return
|
|
351
|
+
return Te(e.map((e) => {
|
|
351
352
|
if (Array.isArray(e) && typeof e[0] == "function") {
|
|
352
353
|
let t = e[0], n = i(0);
|
|
353
354
|
return n.on("change", t), e.length === 1 ? [n, [0, 1]] : e.length === 2 ? [
|
|
@@ -361,44 +362,44 @@ function Fe(e, t, n) {
|
|
|
361
362
|
];
|
|
362
363
|
}
|
|
363
364
|
return e;
|
|
364
|
-
}), t, n, { spring:
|
|
365
|
-
r.push(...
|
|
365
|
+
}), t, n, { spring: D }).forEach(({ keyframes: e, transition: t }, n) => {
|
|
366
|
+
r.push(...Fe(n, e, t));
|
|
366
367
|
}), r;
|
|
367
368
|
}
|
|
368
369
|
//#endregion
|
|
369
370
|
//#region ../../node_modules/.pnpm/framer-motion@12.42.2_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/framer-motion/dist/es/animation/animate/index.mjs
|
|
370
|
-
function
|
|
371
|
+
function Le(e) {
|
|
371
372
|
return Array.isArray(e) && e.some(Array.isArray);
|
|
372
373
|
}
|
|
373
|
-
function
|
|
374
|
+
function Re(e = {}) {
|
|
374
375
|
let { scope: t, reduceMotion: n, skipAnimations: i } = e;
|
|
375
376
|
function a(e, a, o) {
|
|
376
377
|
let s = [], c, l = {};
|
|
377
|
-
if (n !== void 0 && (l.reduceMotion = n), i !== void 0 && (l.skipAnimations = i),
|
|
378
|
+
if (n !== void 0 && (l.reduceMotion = n), i !== void 0 && (l.skipAnimations = i), Le(e)) {
|
|
378
379
|
let { onComplete: n, ...r } = a || {};
|
|
379
|
-
typeof n == "function" && (c = n), s =
|
|
380
|
+
typeof n == "function" && (c = n), s = Ie(e, {
|
|
380
381
|
...l,
|
|
381
382
|
...r
|
|
382
383
|
}, t);
|
|
383
384
|
} else {
|
|
384
385
|
let { onComplete: n, ...r } = o || {};
|
|
385
|
-
typeof n == "function" && (c = n), s =
|
|
386
|
+
typeof n == "function" && (c = n), s = Fe(e, a, {
|
|
386
387
|
...l,
|
|
387
388
|
...r
|
|
388
389
|
}, t);
|
|
389
390
|
}
|
|
390
|
-
let u = new
|
|
391
|
+
let u = new V(s);
|
|
391
392
|
return c && u.finished.then(c), t && (t.animations.push(u), u.finished.then(() => {
|
|
392
393
|
r(t.animations, u);
|
|
393
394
|
})), u;
|
|
394
395
|
}
|
|
395
396
|
return a;
|
|
396
397
|
}
|
|
397
|
-
var
|
|
398
|
+
var Y = Re(), ze = /*#__PURE__*/ U.createContext(void 0);
|
|
398
399
|
process.env.NODE_ENV !== "production" && (ze.displayName = "SwitchRootContext");
|
|
399
400
|
function Be() {
|
|
400
|
-
let e =
|
|
401
|
-
if (e === void 0) throw Error(process.env.NODE_ENV === "production" ?
|
|
401
|
+
let e = U.useContext(ze);
|
|
402
|
+
if (e === void 0) throw Error(process.env.NODE_ENV === "production" ? I(63) : "Base UI: SwitchRootContext is missing. Switch parts must be placed within <Switch.Root>.");
|
|
402
403
|
return e;
|
|
403
404
|
}
|
|
404
405
|
//#endregion
|
|
@@ -406,48 +407,48 @@ function Be() {
|
|
|
406
407
|
var Ve = /*#__PURE__*/ function(e) {
|
|
407
408
|
return e.checked = "data-checked", e.unchecked = "data-unchecked", e.disabled = "data-disabled", e.readonly = "data-readonly", e.required = "data-required", e.valid = "data-valid", e.invalid = "data-invalid", e.touched = "data-touched", e.dirty = "data-dirty", e.filled = "data-filled", e.focused = "data-focused", e;
|
|
408
409
|
}({}), He = {
|
|
409
|
-
...
|
|
410
|
+
...L,
|
|
410
411
|
checked(e) {
|
|
411
412
|
return e ? { [Ve.checked]: "" } : { [Ve.unchecked]: "" };
|
|
412
413
|
}
|
|
413
|
-
}, X =
|
|
414
|
-
let { checked: n, className: r, defaultChecked: i, "aria-labelledby": a, form: o, id: s, inputRef: c, name: l, nativeButton: d = !1, onCheckedChange: p, readOnly:
|
|
414
|
+
}, X = te(), Ue = /*#__PURE__*/ U.forwardRef(function(e, t) {
|
|
415
|
+
let { checked: n, className: r, defaultChecked: i, "aria-labelledby": a, form: o, id: s, inputRef: c, name: l, nativeButton: d = !1, onCheckedChange: p, readOnly: m = !1, required: h = !1, disabled: g = !1, render: _, uncheckedValue: v, value: b, style: S, ...C } = e, { clearErrors: w } = he(), { state: T, setTouched: D, setDirty: O, validityData: k, setFilled: A, setFocused: j, validationMode: M, disabled: ee, name: N, validation: P } = pe(), { labelId: te } = me(), F = ee || g, I = N ?? l, L = U.useRef(null), _e = ce(L, c, P.inputRef), R = U.useRef(null), z = f(), B = ue({
|
|
415
416
|
id: s,
|
|
416
417
|
implicit: !1,
|
|
417
|
-
controlRef:
|
|
418
|
-
}),
|
|
418
|
+
controlRef: R
|
|
419
|
+
}), V = d ? void 0 : B, [H, ve] = le({
|
|
419
420
|
controlled: n,
|
|
420
421
|
default: !!i,
|
|
421
422
|
name: "Switch",
|
|
422
423
|
state: "checked"
|
|
423
424
|
});
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
}, [
|
|
427
|
-
|
|
425
|
+
de(R, z, H, void 0, !F, l), ie(() => {
|
|
426
|
+
L.current && A(L.current.checked);
|
|
427
|
+
}, [L, A]), fe(H, () => {
|
|
428
|
+
w(I), O(H !== k.initialValue), A(H), P.change(H);
|
|
428
429
|
});
|
|
429
|
-
let { getButtonProps:
|
|
430
|
-
disabled:
|
|
430
|
+
let { getButtonProps: ye, buttonRef: W } = re({
|
|
431
|
+
disabled: F,
|
|
431
432
|
native: d
|
|
432
|
-
}),
|
|
433
|
-
id: d ?
|
|
433
|
+
}), G = ge(a, te, L, !d, V), be = {
|
|
434
|
+
id: d ? B : z,
|
|
434
435
|
role: "switch",
|
|
435
|
-
"aria-checked":
|
|
436
|
-
"aria-readonly":
|
|
437
|
-
"aria-required":
|
|
438
|
-
"aria-labelledby":
|
|
436
|
+
"aria-checked": H,
|
|
437
|
+
"aria-readonly": m || void 0,
|
|
438
|
+
"aria-required": h || void 0,
|
|
439
|
+
"aria-labelledby": G,
|
|
439
440
|
onFocus() {
|
|
440
|
-
|
|
441
|
+
F || j(!0);
|
|
441
442
|
},
|
|
442
443
|
onBlur() {
|
|
443
|
-
let e =
|
|
444
|
-
!e ||
|
|
444
|
+
let e = L.current;
|
|
445
|
+
!e || F || (D(!0), j(!1), M === "onBlur" && P.commit(e.checked));
|
|
445
446
|
},
|
|
446
447
|
onClick(e) {
|
|
447
|
-
if (
|
|
448
|
+
if (m || F) return;
|
|
448
449
|
e.preventDefault();
|
|
449
|
-
let t =
|
|
450
|
-
t && t.dispatchEvent(new (
|
|
450
|
+
let t = L.current;
|
|
451
|
+
t && t.dispatchEvent(new (oe(t)).PointerEvent("click", {
|
|
451
452
|
bubbles: !0,
|
|
452
453
|
shiftKey: e.shiftKey,
|
|
453
454
|
ctrlKey: e.ctrlKey,
|
|
@@ -455,70 +456,70 @@ var Ve = /*#__PURE__*/ function(e) {
|
|
|
455
456
|
metaKey: e.metaKey
|
|
456
457
|
}));
|
|
457
458
|
}
|
|
458
|
-
},
|
|
459
|
-
checked:
|
|
460
|
-
disabled:
|
|
459
|
+
}, K = ae({
|
|
460
|
+
checked: H,
|
|
461
|
+
disabled: F,
|
|
461
462
|
form: o,
|
|
462
|
-
id:
|
|
463
|
-
name:
|
|
464
|
-
required:
|
|
465
|
-
style:
|
|
463
|
+
id: V,
|
|
464
|
+
name: I,
|
|
465
|
+
required: h,
|
|
466
|
+
style: I ? x : E,
|
|
466
467
|
tabIndex: -1,
|
|
467
468
|
type: "checkbox",
|
|
468
469
|
"aria-hidden": !0,
|
|
469
|
-
ref:
|
|
470
|
+
ref: _e,
|
|
470
471
|
onChange(e) {
|
|
471
472
|
if (e.nativeEvent.defaultPrevented) return;
|
|
472
|
-
if (
|
|
473
|
+
if (m) {
|
|
473
474
|
e.preventDefault();
|
|
474
475
|
return;
|
|
475
476
|
}
|
|
476
|
-
let t = e.currentTarget.checked, n = u(
|
|
477
|
-
p?.(t, n), !n.isCanceled &&
|
|
477
|
+
let t = e.currentTarget.checked, n = u(y, e.nativeEvent);
|
|
478
|
+
p?.(t, n), !n.isCanceled && ve(t);
|
|
478
479
|
},
|
|
479
480
|
onFocus() {
|
|
480
|
-
|
|
481
|
+
R.current?.focus();
|
|
481
482
|
}
|
|
482
|
-
}, (e) => P.getValidationProps(
|
|
483
|
-
...
|
|
484
|
-
checked:
|
|
485
|
-
disabled:
|
|
486
|
-
readOnly:
|
|
487
|
-
required:
|
|
483
|
+
}, (e) => P.getValidationProps(F, e), b === void 0 ? se : { value: b }), q = U.useMemo(() => ({
|
|
484
|
+
...T,
|
|
485
|
+
checked: H,
|
|
486
|
+
disabled: F,
|
|
487
|
+
readOnly: m,
|
|
488
|
+
required: h
|
|
488
489
|
}), [
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
]),
|
|
495
|
-
state:
|
|
490
|
+
T,
|
|
491
|
+
H,
|
|
492
|
+
F,
|
|
493
|
+
m,
|
|
494
|
+
h
|
|
495
|
+
]), xe = ne("span", e, {
|
|
496
|
+
state: q,
|
|
496
497
|
ref: [
|
|
497
498
|
t,
|
|
498
|
-
|
|
499
|
-
|
|
499
|
+
R,
|
|
500
|
+
W
|
|
500
501
|
],
|
|
501
502
|
props: [
|
|
503
|
+
be,
|
|
504
|
+
C,
|
|
502
505
|
ye,
|
|
503
|
-
|
|
504
|
-
ve,
|
|
505
|
-
(e) => P.getValidationProps(I, e)
|
|
506
|
+
(e) => P.getValidationProps(F, e)
|
|
506
507
|
],
|
|
507
508
|
stateAttributesMapping: He
|
|
508
509
|
});
|
|
509
510
|
return /*#__PURE__*/ (0, X.jsxs)(ze.Provider, {
|
|
510
|
-
value:
|
|
511
|
+
value: q,
|
|
511
512
|
children: [
|
|
512
|
-
|
|
513
|
-
!
|
|
513
|
+
xe,
|
|
514
|
+
!H && I && v !== void 0 && /*#__PURE__*/ (0, X.jsx)("input", {
|
|
514
515
|
type: "hidden",
|
|
515
516
|
form: o,
|
|
516
|
-
name:
|
|
517
|
-
value:
|
|
518
|
-
disabled:
|
|
517
|
+
name: I,
|
|
518
|
+
value: v,
|
|
519
|
+
disabled: F
|
|
519
520
|
}),
|
|
520
521
|
/*#__PURE__*/ (0, X.jsx)("input", {
|
|
521
|
-
...
|
|
522
|
+
...K,
|
|
522
523
|
suppressHydrationWarning: !0
|
|
523
524
|
})
|
|
524
525
|
]
|
|
@@ -527,9 +528,9 @@ var Ve = /*#__PURE__*/ function(e) {
|
|
|
527
528
|
process.env.NODE_ENV !== "production" && (Ue.displayName = "SwitchRoot");
|
|
528
529
|
//#endregion
|
|
529
530
|
//#region ../../node_modules/.pnpm/@base-ui+react@1.6.0_@types+react@19.2.17_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/@base-ui/react/switch/thumb/SwitchThumb.mjs
|
|
530
|
-
var Z = /*#__PURE__*/
|
|
531
|
+
var Z = /*#__PURE__*/ U.forwardRef(function(e, t) {
|
|
531
532
|
let { render: n, className: r, style: i, ...a } = e;
|
|
532
|
-
return
|
|
533
|
+
return ne("span", e, {
|
|
533
534
|
state: Be(),
|
|
534
535
|
ref: t,
|
|
535
536
|
stateAttributesMapping: He,
|
|
@@ -543,46 +544,46 @@ var We = 34, Ge = 20, Q = 16, $ = 2, Ke = 4, qe = 2;
|
|
|
543
544
|
function Je(e) {
|
|
544
545
|
return "label" in e && typeof e.label == "string";
|
|
545
546
|
}
|
|
546
|
-
var Ye = (0,
|
|
547
|
-
let u = (0,
|
|
548
|
-
(0,
|
|
547
|
+
var Ye = (0, U.forwardRef)(({ label: e, checked: t, onToggle: n, disabled: r = !1, thumbTransition: i, uncheckedTrackColor: a, uncheckedTrackColorHovered: o, className: s, ...c }, l) => {
|
|
548
|
+
let u = (0, U.useId)(), d = (0, U.useRef)(!1), [f, p] = (0, U.useState)(!1), [m, h] = (0, U.useState)(!1), g = (0, U.useRef)(!1), _ = (0, U.useRef)(!1), v = (0, U.useRef)(null), y = ye(t ? 16 : $);
|
|
549
|
+
(0, U.useEffect)(() => {
|
|
549
550
|
d.current = !0;
|
|
550
551
|
}, []);
|
|
551
|
-
let
|
|
552
|
-
(0,
|
|
553
|
-
g.current || (d.current ?
|
|
552
|
+
let b = m ? 20 : f ? 18 : Q, x = m ? Q - Ke : Q, S = m ? 4 : $, w = b - Q, T = t ? 16 - w : $;
|
|
553
|
+
(0, U.useEffect)(() => {
|
|
554
|
+
g.current || (d.current ? Y(y, T, i ?? A.moderate) : y.set(T));
|
|
554
555
|
}, [
|
|
555
556
|
T,
|
|
556
|
-
|
|
557
|
+
y,
|
|
557
558
|
i
|
|
558
559
|
]);
|
|
559
|
-
let E = (0,
|
|
560
|
-
r || e.pointerType === "mouse" && e.button !== 0 || (h(!0), g.current = !1,
|
|
560
|
+
let E = (0, U.useCallback)((e) => {
|
|
561
|
+
r || e.pointerType === "mouse" && e.button !== 0 || (h(!0), g.current = !1, _.current = !1, v.current = {
|
|
561
562
|
clientX: e.clientX,
|
|
562
|
-
originX:
|
|
563
|
+
originX: y.get()
|
|
563
564
|
}, e.currentTarget.setPointerCapture(e.pointerId));
|
|
564
|
-
}, [r,
|
|
565
|
-
if (!
|
|
566
|
-
let t = e.clientX -
|
|
565
|
+
}, [r, y]), D = (0, U.useCallback)((e) => {
|
|
566
|
+
if (!v.current) return;
|
|
567
|
+
let t = e.clientX - v.current.clientX;
|
|
567
568
|
if (!g.current) {
|
|
568
569
|
if (Math.abs(t) < qe) return;
|
|
569
570
|
g.current = !0;
|
|
570
571
|
}
|
|
571
|
-
let n = $, r = We - $ - 20, i =
|
|
572
|
-
|
|
573
|
-
}, [
|
|
574
|
-
|
|
575
|
-
|
|
572
|
+
let n = $, r = We - $ - 20, i = v.current.originX + t;
|
|
573
|
+
y.set(Math.max(n, Math.min(r, i)));
|
|
574
|
+
}, [y]), O = (0, U.useCallback)((e) => {
|
|
575
|
+
v.current &&= (h(!1), g.current && (_.current = !0, g.current = !1, e && (y.get() > 14 / 2 === t ? Y(y, t ? 16 : $, i ?? A.moderate) : n()), requestAnimationFrame(() => {
|
|
576
|
+
_.current = !1;
|
|
576
577
|
})), null);
|
|
577
578
|
}, [
|
|
578
579
|
t,
|
|
579
580
|
n,
|
|
580
|
-
|
|
581
|
+
y,
|
|
581
582
|
i
|
|
582
583
|
]);
|
|
583
584
|
return /* @__PURE__ */ (0, X.jsxs)("div", {
|
|
584
585
|
ref: l,
|
|
585
|
-
className:
|
|
586
|
+
className: F("relative z-10 flex items-center gap-2.5 px-3 py-2 cursor-pointer select-none touch-none", r && "opacity-50 pointer-events-none", s),
|
|
586
587
|
onPointerEnter: (e) => {
|
|
587
588
|
e.pointerType === "mouse" && p(!0);
|
|
588
589
|
},
|
|
@@ -591,21 +592,21 @@ var Ye = (0, W.forwardRef)(({ label: e, checked: t, onToggle: n, disabled: r = !
|
|
|
591
592
|
onPointerMove: D,
|
|
592
593
|
onPointerUp: () => O(!0),
|
|
593
594
|
onPointerCancel: () => {
|
|
594
|
-
|
|
595
|
+
v.current &&= (h(!1), g.current && (g.current = !1, Y(y, t ? 16 : $, i ?? A.moderate)), null);
|
|
595
596
|
},
|
|
596
597
|
onClick: () => {
|
|
597
|
-
r ||
|
|
598
|
+
r || _.current || n();
|
|
598
599
|
},
|
|
599
600
|
...c,
|
|
600
601
|
children: [/* @__PURE__ */ (0, X.jsx)(Ue, {
|
|
601
602
|
checked: t,
|
|
602
603
|
"aria-labelledby": u,
|
|
603
604
|
onCheckedChange: () => {
|
|
604
|
-
|
|
605
|
+
_.current || n();
|
|
605
606
|
},
|
|
606
607
|
disabled: r,
|
|
607
608
|
tabIndex: 0,
|
|
608
|
-
className:
|
|
609
|
+
className: F("relative shrink-0 rounded-full outline-none cursor-pointer", "transition-colors duration-80", "focus-visible:ring-1 focus-visible:ring-[color:var(--focus-ring,#6B97FF)] focus-visible:ring-offset-2 focus-visible:ring-offset-background"),
|
|
609
610
|
style: {
|
|
610
611
|
width: We,
|
|
611
612
|
height: Ge,
|
|
@@ -614,32 +615,32 @@ var Ye = (0, W.forwardRef)(({ label: e, checked: t, onToggle: n, disabled: r = !
|
|
|
614
615
|
onClick: (e) => e.stopPropagation(),
|
|
615
616
|
children: /* @__PURE__ */ (0, X.jsx)(Z, { render: (e) => {
|
|
616
617
|
let { style: t, onDrag: n, onDragStart: r, onDragEnd: a, onAnimationStart: o, onAnimationEnd: s, onAnimationIteration: c, ...l } = e;
|
|
617
|
-
return /* @__PURE__ */ (0, X.jsx)(
|
|
618
|
+
return /* @__PURE__ */ (0, X.jsx)(C.span, {
|
|
618
619
|
...l,
|
|
619
620
|
className: "absolute top-0 left-0 block rounded-full bg-white shadow-sm",
|
|
620
621
|
initial: !1,
|
|
621
622
|
style: {
|
|
622
623
|
...t,
|
|
623
|
-
x:
|
|
624
|
+
x: y
|
|
624
625
|
},
|
|
625
626
|
animate: {
|
|
626
|
-
y:
|
|
627
|
-
width:
|
|
628
|
-
height:
|
|
627
|
+
y: S,
|
|
628
|
+
width: b,
|
|
629
|
+
height: x
|
|
629
630
|
},
|
|
630
|
-
transition: d.current ? i ??
|
|
631
|
+
transition: d.current ? i ?? A.moderate : { duration: 0 }
|
|
631
632
|
});
|
|
632
633
|
} })
|
|
633
634
|
}), /* @__PURE__ */ (0, X.jsx)("span", {
|
|
634
635
|
id: u,
|
|
635
|
-
className:
|
|
636
|
+
className: F("text-[13px] [text-box:trim-both_cap_alphabetic] transition-[color] duration-80", t ? "text-foreground" : "text-muted-foreground"),
|
|
636
637
|
children: e
|
|
637
638
|
})]
|
|
638
639
|
});
|
|
639
640
|
});
|
|
640
641
|
Ye.displayName = "FluidSwitch";
|
|
641
|
-
var Xe = (0,
|
|
642
|
-
let [o, s] = (0,
|
|
642
|
+
var Xe = (0, U.forwardRef)(({ checked: e, defaultChecked: t = !1, onCheckedChange: n, disabled: r = !1, className: i }, a) => {
|
|
643
|
+
let [o, s] = (0, U.useState)(t), c = e ?? o;
|
|
643
644
|
return /* @__PURE__ */ (0, X.jsx)(Ue, {
|
|
644
645
|
ref: a,
|
|
645
646
|
checked: c,
|
|
@@ -647,12 +648,12 @@ var Xe = (0, W.forwardRef)(({ checked: e, defaultChecked: t = !1, onCheckedChang
|
|
|
647
648
|
onCheckedChange: (t) => {
|
|
648
649
|
e === void 0 && s(t), n?.(t);
|
|
649
650
|
},
|
|
650
|
-
className:
|
|
651
|
-
children: /* @__PURE__ */ (0, X.jsx)(Z, { className:
|
|
651
|
+
className: F("peer inline-flex h-5 w-9 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent shadow-xs transition-colors duration-80", "focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-[color:var(--focus-ring,#6B97FF)]", "disabled:cursor-not-allowed disabled:opacity-50", "data-checked:bg-primary data-unchecked:bg-input", i),
|
|
652
|
+
children: /* @__PURE__ */ (0, X.jsx)(Z, { className: F("pointer-events-none block size-4 rounded-full bg-background shadow-sm ring-0 transition-transform duration-80", "data-checked:translate-x-4 data-unchecked:translate-x-0") })
|
|
652
653
|
});
|
|
653
654
|
});
|
|
654
655
|
Xe.displayName = "ShadcnSwitch";
|
|
655
|
-
var Ze = (0,
|
|
656
|
+
var Ze = (0, U.forwardRef)((e, t) => Je(e) ? /* @__PURE__ */ (0, X.jsx)(Ye, {
|
|
656
657
|
ref: t,
|
|
657
658
|
...e
|
|
658
659
|
}) : /* @__PURE__ */ (0, X.jsx)(Xe, {
|