@fde-desktop/fde-core 0.4.9 → 0.4.11

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.
Files changed (186) hide show
  1. package/dist/{AppEmptyState-Bxpit0JV.js → AppEmptyState-Boej96TB.js} +1 -1
  2. package/dist/AppEmptyState-CLc00OOG.cjs +1 -0
  3. package/dist/AppIcon-C8vHUVcb.cjs +1 -0
  4. package/dist/AppIcon-mtEoyzOb.js +22 -0
  5. package/dist/AppMenuBar-CAlkNHjj.cjs +1 -0
  6. package/dist/AppMenuBar-DmSfQRXU.js +197 -0
  7. package/dist/CalendarApp-DOmjWbpl.js +10 -0
  8. package/dist/CalendarApp-Z0bCCYsK.cjs +1 -0
  9. package/dist/ColorPicker-CQRRwY-y.cjs +1 -0
  10. package/dist/ColorPicker-WCeD3Wjf.js +35 -0
  11. package/dist/CreateItemApp-BkFFFdX1.cjs +1 -0
  12. package/dist/CreateItemApp-DR8Y4bwo.js +202 -0
  13. package/dist/DeviceInfoApp-BXQ9uOwF.cjs +1 -0
  14. package/dist/DeviceInfoApp-I63mJRWy.js +195 -0
  15. package/dist/DownloadProgress-CkTGTf0z.cjs +1 -0
  16. package/dist/DownloadProgress-DnVASsv5.js +39 -0
  17. package/dist/FilePickerApp-By6-vbag.cjs +1 -0
  18. package/dist/FilePickerApp-ClHuhm6Z.js +390 -0
  19. package/dist/FilesApp-BC4UPNuw.cjs +1 -0
  20. package/dist/FilesApp-D8MqvC5X.js +210 -0
  21. package/dist/ImageViewerApp-B1niWF75.cjs +1 -0
  22. package/dist/{ImageViewerApp-BaLP3gkO.js → ImageViewerApp-iojtyFEf.js} +5 -5
  23. package/dist/{ImageViewerMenuBar-CabGSi9r.js → ImageViewerMenuBar-BIsUokxV.js} +2 -2
  24. package/dist/ImageViewerMenuBar-BgzgSF3v.cjs +1 -0
  25. package/dist/MenuEditApp-BHptoJbz.cjs +1 -0
  26. package/dist/{MenuEditApp-BTRppYnD.js → MenuEditApp-CJUbJaqh.js} +138 -143
  27. package/dist/MenuEditMenuBar-CCOSPAUe.cjs +1 -0
  28. package/dist/{MenuEditMenuBar-x1IQrHP2.js → MenuEditMenuBar-DnCL-kaZ.js} +3 -3
  29. package/dist/NotesApp-BmQIBtJ2.cjs +1 -0
  30. package/dist/{NotesApp-CQe7UfBC.js → NotesApp-DJ2dGt4-.js} +5 -5
  31. package/dist/NotesMenuBar-BzojwMtH.cjs +1 -0
  32. package/dist/{NotesMenuBar-VhpIe68v.js → NotesMenuBar-DILZTjnT.js} +3 -3
  33. package/dist/{PdfApp-DL_R9-Nc.js → PdfApp-IjY_GtnW.js} +3 -3
  34. package/dist/PdfApp-krW8UI97.cjs +1 -0
  35. package/dist/{PdfMenuBar-DZCLSOpR.js → PdfMenuBar-Bd5MTZcZ.js} +1 -1
  36. package/dist/PdfMenuBar-DWD0Qa3F.cjs +1 -0
  37. package/dist/SettingsApp-BE22l5UP.cjs +1 -0
  38. package/dist/SettingsApp-BTFtTFY_.js +1228 -0
  39. package/dist/SettingsMenuBar-CZE2evG2.cjs +1 -0
  40. package/dist/{SettingsMenuBar-YWiJHaxq.js → SettingsMenuBar-ktC0viTd.js} +3 -3
  41. package/dist/UploaderApp-CbypD538.js +263 -0
  42. package/dist/UploaderApp-D_qD3O70.cjs +1 -0
  43. package/dist/{VscIcon-DBfVnArE.js → VscIcon-AEENjKOE.js} +1 -1
  44. package/dist/VscIcon-BYb_Soyy.cjs +1 -0
  45. package/dist/buildBreadcrumbs-Ccd8i11b.cjs +1 -0
  46. package/dist/buildBreadcrumbs-noWhu8os.js +45 -0
  47. package/dist/{desktopStore-F8bgLqFl.js → desktopStore-8cSZlj7s.js} +407 -477
  48. package/dist/desktopStore-C1jR6Fdb.cjs +1 -0
  49. package/dist/imageViewerStore-Dfylg59V.cjs +1 -0
  50. package/dist/index.cjs +1 -1
  51. package/dist/index.css +1 -1
  52. package/dist/index.d.ts +16 -6
  53. package/dist/index.js +1646 -1960
  54. package/dist/menuEditStore-CYwtfD6H.cjs +1 -0
  55. package/dist/notesStore-CrWTO6oB.cjs +1 -0
  56. package/dist/settingsAppStore-DuYZNeFf.cjs +1 -0
  57. package/dist/useAdaptiveDimensions-3Lz4X0Tc.cjs +1 -0
  58. package/dist/{useAdaptiveDimensions-AVDc_qPa.js → useAdaptiveDimensions-DxNLJ7R5.js} +1 -1
  59. package/dist/{useCloseInterceptor-BZd3VILp.js → useCloseInterceptor-CIxhOZx1.js} +1 -1
  60. package/dist/useCloseInterceptor-CdX-09Ib.cjs +1 -0
  61. package/dist/useDynamicIcon-CK6SjEv5.cjs +1 -0
  62. package/dist/useOpenApp-D-FOY88T.cjs +1 -0
  63. package/dist/{useOpenApp-CBIm7Gzl.js → useOpenApp-DkZLFFCH.js} +51 -67
  64. package/dist/{useResolvedUrl-DQpLqOoL.js → useResolvedUrl-B6x4xy0x.js} +1 -2
  65. package/dist/useResolvedUrl-Bb39DpVy.cjs +1 -0
  66. package/package.json +2 -1
  67. package/dist/AccordionChevron-DxpOyInK.js +0 -26
  68. package/dist/AccordionChevron-kn5kSrEc.cjs +0 -1
  69. package/dist/ActionIcon-Drh4p6Fv.js +0 -145
  70. package/dist/ActionIcon-alk2zZD6.cjs +0 -1
  71. package/dist/AppEmptyState-BWCUbf-B.cjs +0 -1
  72. package/dist/AppIcon-BU7a3ZNH.cjs +0 -1
  73. package/dist/AppIcon-XumS3bIG.js +0 -80
  74. package/dist/AppMenuBar-B9U0n1Vv.cjs +0 -1
  75. package/dist/AppMenuBar-CnIEVjr8.js +0 -2049
  76. package/dist/Box-DSKR_qaa.js +0 -1579
  77. package/dist/Box-zW6Twge8.cjs +0 -1
  78. package/dist/Button-DMlnrqyx.cjs +0 -1
  79. package/dist/Button-wTOTQKxF.js +0 -178
  80. package/dist/CalendarApp-B_e1B1Yn.cjs +0 -1
  81. package/dist/CalendarApp-C-l9D6nd.cjs +0 -1
  82. package/dist/CalendarApp-D0ftTCTG.js +0 -1399
  83. package/dist/Center-CmxXB9ql.js +0 -25
  84. package/dist/Center-DKUE2pER.cjs +0 -1
  85. package/dist/CheckIcon-CZhtJD1O.cjs +0 -1
  86. package/dist/CheckIcon-N5qBqXQJ.js +0 -25
  87. package/dist/CodeServerApp-BOoGwZ7r.cjs +0 -1
  88. package/dist/CodeServerApp-Be3I5EGg.cjs +0 -1
  89. package/dist/CodeServerApp-DW18EZxa.js +0 -150
  90. package/dist/ColorPicker-BCNqi02x.js +0 -997
  91. package/dist/ColorPicker-BrDE7tMO.cjs +0 -1
  92. package/dist/CreateItemApp-B12M1E_1.cjs +0 -1
  93. package/dist/CreateItemApp-TAAprby3.js +0 -400
  94. package/dist/CreateItemApp-ePB6ujNl.cjs +0 -1
  95. package/dist/DeviceInfoApp-BMF18BGo.cjs +0 -1
  96. package/dist/DeviceInfoApp-DRy0H3aT.cjs +0 -1
  97. package/dist/DeviceInfoApp-lgpwkeRR.js +0 -223
  98. package/dist/DownloadProgress-EoyCaD5O.js +0 -174
  99. package/dist/DownloadProgress-VNdj22U8.cjs +0 -1
  100. package/dist/FileIcon-7JaSR3Gn.js +0 -89
  101. package/dist/FileIcon-CIXopWLv.cjs +0 -1
  102. package/dist/FilePickerApp-DaMgEqKh.js +0 -409
  103. package/dist/FilePickerApp-DjmuSFqa.cjs +0 -1
  104. package/dist/FilesApp-Bp7wfrBZ.cjs +0 -1
  105. package/dist/FilesApp-BpJJRKhi.cjs +0 -1
  106. package/dist/FilesApp-Cj94QG5o.js +0 -225
  107. package/dist/Group-CtBJSfCo.js +0 -48
  108. package/dist/Group-Dsrf6lEK.cjs +0 -1
  109. package/dist/ImageViewerApp-DlHGeB3S.cjs +0 -1
  110. package/dist/ImageViewerApp-DoXd_Swu.cjs +0 -1
  111. package/dist/ImageViewerMenuBar-SAI7UNz7.cjs +0 -1
  112. package/dist/ImageViewerMenuBar-_Jr29gii.cjs +0 -1
  113. package/dist/MenuEditApp-BJjlPTOa.cjs +0 -1
  114. package/dist/MenuEditApp-JPsGT-S3.cjs +0 -1
  115. package/dist/MenuEditMenuBar-BydGkqMw.cjs +0 -1
  116. package/dist/MenuEditMenuBar-DptlwVPQ.cjs +0 -1
  117. package/dist/NotesApp-BOcRGO7w.cjs +0 -1
  118. package/dist/NotesApp-OL07JXRE.cjs +0 -1
  119. package/dist/NotesMenuBar-BSI_2Y7p.cjs +0 -1
  120. package/dist/NotesMenuBar-Df6aW85J.cjs +0 -1
  121. package/dist/Paper-BX_9odR6.js +0 -30
  122. package/dist/Paper-D8-BaBx2.cjs +0 -1
  123. package/dist/PdfApp-CNEbty5v.cjs +0 -1
  124. package/dist/PdfApp-CVv3ZCaM.cjs +0 -1
  125. package/dist/PdfMenuBar--E6kDyrT.cjs +0 -1
  126. package/dist/PdfMenuBar-Dj5cJUkg.cjs +0 -1
  127. package/dist/SettingsApp-BlmHuAjT.js +0 -1831
  128. package/dist/SettingsApp-CNvIgf5B.cjs +0 -1
  129. package/dist/SettingsApp-DWxanNE4.cjs +0 -1
  130. package/dist/SettingsMenuBar-CBoOBCfx.cjs +0 -1
  131. package/dist/SettingsMenuBar-DQooFkZN.cjs +0 -1
  132. package/dist/Slider-BUiHxjKO.cjs +0 -1
  133. package/dist/Slider-t-NcD60t.js +0 -1176
  134. package/dist/Stack-Bp1Ek2Gp.js +0 -34
  135. package/dist/Stack-D4jAiRfc.cjs +0 -1
  136. package/dist/StorybookApp-CDLV_kja.cjs +0 -1
  137. package/dist/StorybookApp-DKwlPCmo.js +0 -10
  138. package/dist/TerminalApp-BCB7i1lR.cjs +0 -1
  139. package/dist/TerminalApp-BYc_gHLe.js +0 -326
  140. package/dist/TerminalApp-Dviz6aP2.cjs +0 -1
  141. package/dist/TerminalMenuBar-D5tPmgR_.js +0 -113
  142. package/dist/TerminalMenuBar-DNshPmCa.cjs +0 -1
  143. package/dist/TerminalMenuBar-HzMSR7XP.cjs +0 -1
  144. package/dist/TextInput-C-JtGWn1.js +0 -981
  145. package/dist/TextInput-CrsmcOip.cjs +0 -1
  146. package/dist/Tooltip-D5Cd9wtz.cjs +0 -1
  147. package/dist/Tooltip-DOeIvhrO.js +0 -1142
  148. package/dist/UnstyledButton-DGaG-e_G.js +0 -25
  149. package/dist/UnstyledButton-DX2pTahr.cjs +0 -1
  150. package/dist/UploaderApp-C6xA5Rrf2.cjs +0 -1
  151. package/dist/UploaderApp-DnHIRxB_.cjs +0 -1
  152. package/dist/UploaderApp-qBfpukR_.js +0 -488
  153. package/dist/VscIcon-CcMdrFoJ.cjs +0 -1
  154. package/dist/create-safe-context-Bboj0GWC.cjs +0 -1
  155. package/dist/create-safe-context-XT2cxc14.js +0 -12
  156. package/dist/desktopStore-CZoA9VHO.cjs +0 -1
  157. package/dist/getRuntime-BFK0-8R1.cjs +0 -1
  158. package/dist/getRuntime-DAPqFH2W.js +0 -63
  159. package/dist/imageViewerStore-BB_tssZR.cjs +0 -1
  160. package/dist/is-element-Bu_JY8Qy.js +0 -7
  161. package/dist/is-element-CdV0xajp.cjs +0 -1
  162. package/dist/menuEditStore-CTeM_dns.cjs +0 -1
  163. package/dist/notesStore-BCEl1D_v.cjs +0 -1
  164. package/dist/settingsAppStore-CMBc13VU.cjs +0 -1
  165. package/dist/terminalStore-IWdf4Mm6.js +0 -30
  166. package/dist/terminalStore-iIuyodfK.cjs +0 -1
  167. package/dist/use-merged-ref-BT8_u6vW.js +0 -25
  168. package/dist/use-merged-ref-n9Gw9LNn.cjs +0 -1
  169. package/dist/use-resolved-styles-api-8OXE2oRq.cjs +0 -1
  170. package/dist/use-resolved-styles-api-DNUlJJZf.js +0 -21
  171. package/dist/use-uncontrolled-A4hm9ATM.js +0 -23
  172. package/dist/use-uncontrolled-DDJVQiM_.cjs +0 -1
  173. package/dist/useAdaptiveDimensions-CfITBJ_m.cjs +0 -1
  174. package/dist/useCloseInterceptor-yntBEzNc.cjs +0 -1
  175. package/dist/useDynamicIcon-DJ_il30E.cjs +0 -1
  176. package/dist/useOpenApp-DW4x79Zg.cjs +0 -1
  177. package/dist/useResolvedUrl-BkMPM1fM.cjs +0 -1
  178. /package/dist/{Colors-zP2AFgU3.cjs → Colors-CNJbU7oq.cjs} +0 -0
  179. /package/dist/{Colors-ClnDxnyA.js → Colors-CuABn2W4.js} +0 -0
  180. /package/dist/{imageViewerStore-C5kWz0o7.js → imageViewerStore-COrD02Zu.js} +0 -0
  181. /package/dist/{menuEditStore-Cj1zAwxQ.js → menuEditStore-CxsgLiQu.js} +0 -0
  182. /package/dist/{notesStore-BPyRTHEc.js → notesStore-Dgah46U5.js} +0 -0
  183. /package/dist/{settingsAppStore-BDQ3ts1y.js → settingsAppStore-DHZhi6Rl.js} +0 -0
  184. /package/dist/{useDynamicIcon-Bf0t2foA.js → useDynamicIcon-_wGeWu-b.js} +0 -0
  185. /package/dist/{useMenuBarUtils-nmu9yehT.js → useMenuBarUtils-ChAfI7OA.js} +0 -0
  186. /package/dist/{useMenuBarUtils-nJIPJGIQ.cjs → useMenuBarUtils-DAap0ukp.cjs} +0 -0
@@ -1,2049 +0,0 @@
1
- import { A as e, D as t, I as n, M as r, O as i, S as a, c as o, d as s, i as c, l, n as u, o as d, r as f, t as p, x as m } from "./Box-DSKR_qaa.js";
2
- import { t as h } from "./is-element-Bu_JY8Qy.js";
3
- import { t as g } from "./create-safe-context-XT2cxc14.js";
4
- import { c as _, l as v, n as y, o as b, p as x, t as ee } from "./Tooltip-DOeIvhrO.js";
5
- import { n as S, t as C } from "./use-uncontrolled-A4hm9ATM.js";
6
- import { i as w, n as T, t as E, u as te } from "./TextInput-C-JtGWn1.js";
7
- import { a as ne, i as D, n as re, r as O, t as ie } from "./Slider-t-NcD60t.js";
8
- import { r as k, t as ae } from "./use-merged-ref-BT8_u6vW.js";
9
- import { t as oe } from "./use-resolved-styles-api-DNUlJJZf.js";
10
- import { t as A } from "./UnstyledButton-DGaG-e_G.js";
11
- import { t as se } from "./AccordionChevron-DxpOyInK.js";
12
- import { t as ce } from "./CheckIcon-N5qBqXQJ.js";
13
- import { i as le } from "./useDynamicIcon-Bf0t2foA.js";
14
- import { cloneElement as j, createContext as ue, use as de, useCallback as M, useEffect as N, useId as fe, useMemo as pe, useRef as P, useState as me } from "react";
15
- import { Fragment as he, jsx as F, jsxs as I } from "react/jsx-runtime";
16
- import ge from "clsx";
17
- import { NumericFormat as _e } from "react-number-format";
18
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/core/utils/find-element-ancestor/find-element-ancestor.mjs
19
- function ve(e, t) {
20
- let n = e;
21
- for (; (n = n.parentElement) && !n.matches(t););
22
- return n;
23
- }
24
- //#endregion
25
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/core/utils/create-scoped-keydown-handler/create-scoped-keydown-handler.mjs
26
- function ye(e, t, n) {
27
- for (let n = e - 1; n >= 0; --n) if (!t[n].disabled) return n;
28
- if (n) {
29
- for (let e = t.length - 1; e > -1; --e) if (!t[e].disabled) return e;
30
- }
31
- return e;
32
- }
33
- function be(e, t, n) {
34
- for (let n = e + 1; n < t.length; n += 1) if (!t[n].disabled) return n;
35
- if (n) {
36
- for (let e = 0; e < t.length; e += 1) if (!t[e].disabled) return e;
37
- }
38
- return e;
39
- }
40
- function xe(e, t, n) {
41
- return ve(e, n) === ve(t, n);
42
- }
43
- function Se({ parentSelector: e, siblingSelector: t, onKeyDown: n, loop: r = !0, activateOnFocus: i = !1, dir: a = "rtl", orientation: o }) {
44
- return (s) => {
45
- n?.(s);
46
- let c = Array.from(ve(s.currentTarget, e)?.querySelectorAll(t) || []).filter((t) => xe(s.currentTarget, t, e)), l = c.findIndex((e) => s.currentTarget === e), u = be(l, c, r), d = ye(l, c, r), f = a === "rtl" ? d : u, p = a === "rtl" ? u : d;
47
- switch (s.key) {
48
- case "ArrowRight":
49
- o === "horizontal" && (s.stopPropagation(), s.preventDefault(), c[f].focus(), i && c[f].click());
50
- break;
51
- case "ArrowLeft":
52
- o === "horizontal" && (s.stopPropagation(), s.preventDefault(), c[p].focus(), i && c[p].click());
53
- break;
54
- case "ArrowUp":
55
- o === "vertical" && (s.stopPropagation(), s.preventDefault(), c[d].focus(), i && c[d].click());
56
- break;
57
- case "ArrowDown":
58
- o === "vertical" && (s.stopPropagation(), s.preventDefault(), c[u].focus(), i && c[u].click());
59
- break;
60
- case "Home":
61
- s.stopPropagation(), s.preventDefault(), !c[0].disabled && c[0].focus();
62
- break;
63
- case "End": {
64
- s.stopPropagation(), s.preventDefault();
65
- let e = c.length - 1;
66
- !c[e].disabled && c[e].focus();
67
- break;
68
- }
69
- }
70
- };
71
- }
72
- //#endregion
73
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/core/utils/create-event-handler/create-event-handler.mjs
74
- function L(e, t) {
75
- return (n) => {
76
- e?.(n), t?.(n);
77
- };
78
- }
79
- //#endregion
80
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/core/utils/get-context-item-index/get-context-item-index.mjs
81
- function Ce(e, t, n) {
82
- return n ? Array.from(ve(n, t)?.querySelectorAll(e) || []).findIndex((e) => e === n) : null;
83
- }
84
- //#endregion
85
- //#region ../../node_modules/.bun/@mantine+hooks@9.0.0+b1ab299f0a400331/node_modules/@mantine/hooks/esm/use-disclosure/use-disclosure.mjs
86
- function we(e = !1, t = {}) {
87
- let [n, r] = me(e), i = M(() => {
88
- r((e) => e || (t.onOpen?.(), !0));
89
- }, [t.onOpen]), a = M(() => {
90
- r((e) => e && (t.onClose?.(), !1));
91
- }, [t.onClose]);
92
- return [n, {
93
- open: i,
94
- close: a,
95
- toggle: M(() => {
96
- n ? a() : i();
97
- }, [
98
- a,
99
- i,
100
- n
101
- ]),
102
- set: r
103
- }];
104
- }
105
- //#endregion
106
- //#region ../../node_modules/.bun/@mantine+hooks@9.0.0+b1ab299f0a400331/node_modules/@mantine/hooks/esm/use-previous/use-previous.mjs
107
- function Te(e) {
108
- let t = P(void 0);
109
- return N(() => {
110
- t.current = e;
111
- }, [e]), t.current;
112
- }
113
- //#endregion
114
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/core/utils/find-element-in-shadow-dom/find-element-in-shadow-dom.mjs
115
- function Ee(e, t = document) {
116
- let n = t.querySelector(e);
117
- if (n) return n;
118
- let r = t.querySelectorAll("*");
119
- for (let t = 0; t < r.length; t += 1) {
120
- let n = r[t];
121
- if (n.shadowRoot) {
122
- let t = Ee(e, n.shadowRoot);
123
- if (t) return t;
124
- }
125
- }
126
- return null;
127
- }
128
- function R(e, t = document) {
129
- let n = [], r = t.querySelectorAll(e);
130
- n.push(...Array.from(r));
131
- let i = t.querySelectorAll("*");
132
- for (let t = 0; t < i.length; t += 1) {
133
- let r = i[t];
134
- if (r.shadowRoot) {
135
- let t = R(e, r.shadowRoot);
136
- n.push(...t);
137
- }
138
- }
139
- return n;
140
- }
141
- function z(e) {
142
- if (!e) return document;
143
- let t = e.getRootNode();
144
- return t instanceof ShadowRoot || t instanceof Document ? t : document;
145
- }
146
- //#endregion
147
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/utils/Floating/use-delayed-hover.mjs
148
- function De({ open: e, close: t, openDelay: n, closeDelay: r }) {
149
- let i = P(-1), a = P(-1), o = () => {
150
- window.clearTimeout(i.current), window.clearTimeout(a.current);
151
- };
152
- return N(() => o, []), {
153
- openDropdown: () => {
154
- o(), n === 0 || n === void 0 ? e() : i.current = window.setTimeout(e, n);
155
- },
156
- closeDropdown: () => {
157
- o(), r === 0 || r === void 0 ? t() : a.current = window.setTimeout(t, r);
158
- }
159
- };
160
- }
161
- //#endregion
162
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/get-parsed-combobox-data/get-parsed-combobox-data.mjs
163
- function Oe(e) {
164
- return typeof e == "string" ? {
165
- value: e,
166
- label: e
167
- } : typeof e == "object" && "value" in e && !("label" in e) ? {
168
- value: e.value,
169
- label: `${e.value}`,
170
- disabled: e.disabled
171
- } : typeof e == "object" && "group" in e ? {
172
- group: e.group,
173
- items: e.items.map((e) => Oe(e))
174
- } : typeof e == "number" || typeof e == "bigint" || typeof e == "boolean" ? {
175
- value: e,
176
- label: `${e}`
177
- } : e;
178
- }
179
- function B(e) {
180
- return e ? e.map((e) => Oe(e)) : [];
181
- }
182
- //#endregion
183
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/get-options-lockup/get-options-lockup.mjs
184
- function ke(e) {
185
- return e.reduce((e, t) => "group" in t ? {
186
- ...e,
187
- ...ke(t.items)
188
- } : (e[`${t.value}`] = t, e), {});
189
- }
190
- //#endregion
191
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/Combobox.module.mjs
192
- var V = {
193
- dropdown: "m_88b62a41",
194
- search: "m_985517d8",
195
- options: "m_b2821a6e",
196
- option: "m_92253aa5",
197
- empty: "m_2530cd1d",
198
- header: "m_858f94bd",
199
- footer: "m_82b967cb",
200
- group: "m_254f3e4f",
201
- groupLabel: "m_2bb2e9e5",
202
- chevron: "m_2943220b",
203
- optionsDropdownOption: "m_390b5f4",
204
- optionsDropdownCheckIcon: "m_8ee53fc2",
205
- optionsDropdownCheckPlaceholder: "m_a530ee0a"
206
- }, H = { error: null }, U = t((e, { size: t, color: n }) => ({ chevron: {
207
- "--combobox-chevron-size": r(t, "combobox-chevron-size"),
208
- "--combobox-chevron-color": n ? m(n, e) : void 0
209
- } })), W = f((e) => {
210
- let t = l("ComboboxChevron", H, e), { size: n, error: r, style: i, className: a, classNames: s, styles: c, unstyled: u, vars: d, attributes: f, mod: m, ...h } = t, g = o({
211
- name: "ComboboxChevron",
212
- classes: V,
213
- props: t,
214
- style: i,
215
- className: a,
216
- classNames: s,
217
- styles: c,
218
- unstyled: u,
219
- vars: d,
220
- varsResolver: U,
221
- attributes: f,
222
- rootSelector: "chevron"
223
- });
224
- return /* @__PURE__ */ F(p, {
225
- component: "svg",
226
- ...h,
227
- ...g("chevron"),
228
- size: n,
229
- viewBox: "0 0 15 15",
230
- fill: "none",
231
- xmlns: "http://www.w3.org/2000/svg",
232
- mod: [
233
- "combobox-chevron",
234
- { error: r },
235
- m
236
- ],
237
- children: /* @__PURE__ */ F("path", {
238
- d: "M4.93179 5.43179C4.75605 5.60753 4.75605 5.89245 4.93179 6.06819C5.10753 6.24392 5.39245 6.24392 5.56819 6.06819L7.49999 4.13638L9.43179 6.06819C9.60753 6.24392 9.89245 6.24392 10.0682 6.06819C10.2439 5.89245 10.2439 5.60753 10.0682 5.43179L7.81819 3.18179C7.73379 3.0974 7.61933 3.04999 7.49999 3.04999C7.38064 3.04999 7.26618 3.0974 7.18179 3.18179L4.93179 5.43179ZM10.0682 9.56819C10.2439 9.39245 10.2439 9.10753 10.0682 8.93179C9.89245 8.75606 9.60753 8.75606 9.43179 8.93179L7.49999 10.8636L5.56819 8.93179C5.39245 8.75606 5.10753 8.75606 4.93179 8.93179C4.75605 9.10753 4.75605 9.39245 4.93179 9.56819L7.18179 11.8182C7.35753 11.9939 7.64245 11.9939 7.81819 11.8182L10.0682 9.56819Z",
239
- fill: "currentColor",
240
- fillRule: "evenodd",
241
- clipRule: "evenodd"
242
- })
243
- });
244
- });
245
- W.classes = V, W.varsResolver = U, W.displayName = "@mantine/core/ComboboxChevron";
246
- //#endregion
247
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/Combobox.context.mjs
248
- var [G, K] = g("Combobox component was not found in tree");
249
- //#endregion
250
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxClearButton/ComboboxClearButton.mjs
251
- function q({ size: e, onMouseDown: t, onClick: n, onClear: r, ...i }) {
252
- return /* @__PURE__ */ F(w.ClearButton, {
253
- tabIndex: -1,
254
- "aria-hidden": !0,
255
- ...i,
256
- onMouseDown: (e) => {
257
- e.preventDefault(), t?.(e);
258
- },
259
- onClick: (e) => {
260
- r(), n?.(e);
261
- }
262
- });
263
- }
264
- q.displayName = "@mantine/core/ComboboxClearButton";
265
- //#endregion
266
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxDropdown/ComboboxDropdown.mjs
267
- var Ae = f((e) => {
268
- let { classNames: t, styles: n, className: r, style: i, hidden: a, ...o } = l("ComboboxDropdown", null, e), s = K();
269
- return /* @__PURE__ */ F(y.Dropdown, {
270
- ...o,
271
- role: "presentation",
272
- "data-hidden": a || void 0,
273
- ...s.getStyles("dropdown", {
274
- className: r,
275
- style: i,
276
- classNames: t,
277
- styles: n
278
- })
279
- });
280
- });
281
- Ae.classes = V, Ae.displayName = "@mantine/core/ComboboxDropdown";
282
- //#endregion
283
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxDropdownTarget/ComboboxDropdownTarget.mjs
284
- var je = { refProp: "ref" }, J = f((e) => {
285
- let { children: t, refProp: n, ref: r } = l("ComboboxDropdownTarget", je, e);
286
- if (K(), !h(t)) throw Error("Combobox.DropdownTarget component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");
287
- return /* @__PURE__ */ F(y.Target, {
288
- ref: r,
289
- refProp: n,
290
- children: t
291
- });
292
- });
293
- J.displayName = "@mantine/core/ComboboxDropdownTarget";
294
- //#endregion
295
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxEmpty/ComboboxEmpty.mjs
296
- var Me = f((e) => {
297
- let { classNames: t, className: n, style: r, styles: i, vars: a, ...o } = l("ComboboxEmpty", null, e);
298
- return /* @__PURE__ */ F(p, {
299
- ...K().getStyles("empty", {
300
- className: n,
301
- classNames: t,
302
- styles: i,
303
- style: r
304
- }),
305
- ...o
306
- });
307
- });
308
- Me.classes = V, Me.displayName = "@mantine/core/ComboboxEmpty";
309
- //#endregion
310
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/use-combobox-target-props/use-combobox-target-props.mjs
311
- function Ne({ onKeyDown: e, withKeyboardNavigation: t, withAriaAttributes: n, withExpandedAttribute: r, targetType: i, autoComplete: a }) {
312
- let o = K(), [s, c] = me(null), l = (n) => {
313
- if (e?.(n), !o.readOnly && t) {
314
- if (n.nativeEvent.isComposing) return;
315
- if (n.nativeEvent.code === "ArrowDown" && (n.preventDefault(), o.store.dropdownOpened ? c(o.store.selectNextOption()) : (o.store.openDropdown("keyboard"), c(o.store.selectActiveOption()), o.store.updateSelectedOptionIndex("selected", { scrollIntoView: !0 }))), n.nativeEvent.code === "ArrowUp" && (n.preventDefault(), o.store.dropdownOpened ? c(o.store.selectPreviousOption()) : (o.store.openDropdown("keyboard"), c(o.store.selectActiveOption()), o.store.updateSelectedOptionIndex("selected", { scrollIntoView: !0 }))), n.nativeEvent.code === "Enter" || n.nativeEvent.code === "NumpadEnter") {
316
- if (n.nativeEvent.keyCode === 229) return;
317
- let e = o.store.getSelectedOptionIndex();
318
- o.store.dropdownOpened && e !== -1 ? (n.preventDefault(), o.store.clickSelectedOption()) : i === "button" && (n.preventDefault(), o.store.openDropdown("keyboard"));
319
- }
320
- n.key === "Escape" && o.store.closeDropdown("keyboard"), n.nativeEvent.code === "Space" && i === "button" && (n.preventDefault(), o.store.toggleDropdown("keyboard"));
321
- }
322
- };
323
- return {
324
- ...n ? {
325
- ...r ? { role: "combobox" } : {},
326
- "aria-haspopup": "listbox",
327
- "aria-expanded": r ? !!(o.store.listId && o.store.dropdownOpened) : void 0,
328
- "aria-controls": o.store.dropdownOpened && o.store.listId ? o.store.listId : void 0,
329
- "aria-activedescendant": o.store.dropdownOpened && s || void 0,
330
- autoComplete: a,
331
- "data-expanded": o.store.dropdownOpened || void 0,
332
- "data-mantine-stop-propagation": o.store.dropdownOpened || void 0
333
- } : {},
334
- onKeyDown: l
335
- };
336
- }
337
- //#endregion
338
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxEventsTarget/ComboboxEventsTarget.mjs
339
- var Pe = {
340
- refProp: "ref",
341
- targetType: "input",
342
- withKeyboardNavigation: !0,
343
- withAriaAttributes: !0,
344
- withExpandedAttribute: !1,
345
- autoComplete: "off"
346
- }, Fe = f((e) => {
347
- let { children: t, refProp: n, withKeyboardNavigation: r, withAriaAttributes: i, withExpandedAttribute: a, targetType: o, autoComplete: s, ref: c, ...u } = l("ComboboxEventsTarget", Pe, e), d = _(t);
348
- if (!d) throw Error("Combobox.EventsTarget component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");
349
- let f = K();
350
- return j(d, {
351
- ...Ne({
352
- targetType: o,
353
- withAriaAttributes: i,
354
- withKeyboardNavigation: r,
355
- withExpandedAttribute: a,
356
- onKeyDown: d.props.onKeyDown,
357
- autoComplete: s
358
- }),
359
- ...u,
360
- [n]: k(c, f.store.targetRef, v(d))
361
- });
362
- });
363
- Fe.displayName = "@mantine/core/ComboboxEventsTarget";
364
- //#endregion
365
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxFooter/ComboboxFooter.mjs
366
- var Y = f((e) => {
367
- let { classNames: t, className: n, style: r, styles: i, vars: a, ...o } = l("ComboboxFooter", null, e);
368
- return /* @__PURE__ */ F(p, {
369
- ...K().getStyles("footer", {
370
- className: n,
371
- classNames: t,
372
- style: r,
373
- styles: i
374
- }),
375
- ...o,
376
- onMouseDown: (e) => {
377
- e.preventDefault();
378
- }
379
- });
380
- });
381
- Y.classes = V, Y.displayName = "@mantine/core/ComboboxFooter";
382
- //#endregion
383
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxGroup/ComboboxGroup.mjs
384
- var X = f((e) => {
385
- let { classNames: t, className: n, style: r, styles: i, vars: a, children: o, label: s, id: c, ...u } = l("ComboboxGroup", null, e), d = K(), f = te(c);
386
- return /* @__PURE__ */ I(p, {
387
- role: "group",
388
- "aria-labelledby": s ? f : void 0,
389
- ...d.getStyles("group", {
390
- className: n,
391
- classNames: t,
392
- style: r,
393
- styles: i
394
- }),
395
- ...u,
396
- children: [s && /* @__PURE__ */ F("div", {
397
- id: f,
398
- ...d.getStyles("groupLabel", {
399
- classNames: t,
400
- styles: i
401
- }),
402
- children: s
403
- }), o]
404
- });
405
- });
406
- X.classes = V, X.displayName = "@mantine/core/ComboboxGroup";
407
- //#endregion
408
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxHeader/ComboboxHeader.mjs
409
- var Ie = f((e) => {
410
- let { classNames: t, className: n, style: r, styles: i, vars: a, ...o } = l("ComboboxHeader", null, e);
411
- return /* @__PURE__ */ F(p, {
412
- ...K().getStyles("header", {
413
- className: n,
414
- classNames: t,
415
- style: r,
416
- styles: i
417
- }),
418
- ...o,
419
- onMouseDown: (e) => {
420
- e.preventDefault();
421
- }
422
- });
423
- });
424
- Ie.classes = V, Ie.displayName = "@mantine/core/ComboboxHeader";
425
- //#endregion
426
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxHiddenInput/ComboboxHiddenInput.mjs
427
- function Le({ value: e, valuesDivider: t = ",", ...n }) {
428
- return /* @__PURE__ */ F("input", {
429
- type: "hidden",
430
- value: Array.isArray(e) ? e.join(t) : e ? `${e}` : "",
431
- ...n
432
- });
433
- }
434
- Le.displayName = "@mantine/core/ComboboxHiddenInput";
435
- //#endregion
436
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxOption/ComboboxOption.mjs
437
- var Re = f((e) => {
438
- let t = l("ComboboxOption", null, e), { classNames: n, className: r, style: i, styles: a, vars: o, onClick: s, id: c, active: u, onMouseDown: d, onMouseOver: f, disabled: m, selected: h, mod: g, ..._ } = t, v = K(), y = fe(), b = c || y;
439
- return /* @__PURE__ */ F(p, {
440
- ...v.getStyles("option", {
441
- className: r,
442
- classNames: n,
443
- styles: a,
444
- style: i
445
- }),
446
- ..._,
447
- id: b,
448
- mod: [
449
- "combobox-option",
450
- {
451
- "combobox-active": u,
452
- "combobox-disabled": m,
453
- "combobox-selected": h
454
- },
455
- g
456
- ],
457
- role: "option",
458
- onClick: (e) => {
459
- m ? e.preventDefault() : (v.onOptionSubmit?.(t.value, t), s?.(e));
460
- },
461
- onMouseDown: (e) => {
462
- e.preventDefault(), d?.(e);
463
- },
464
- onMouseOver: (e) => {
465
- v.resetSelectionOnOptionHover && v.store.resetSelectedOption(), f?.(e);
466
- }
467
- });
468
- });
469
- Re.classes = V, Re.displayName = "@mantine/core/ComboboxOption";
470
- //#endregion
471
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxOptions/ComboboxOptions.mjs
472
- var ze = f((e) => {
473
- let { classNames: t, className: n, style: r, styles: i, id: a, onMouseDown: o, labelledBy: s, ...c } = l("ComboboxOptions", null, e), u = K(), d = te(a);
474
- return N(() => {
475
- u.store.setListId(d);
476
- }, [d]), /* @__PURE__ */ F(p, {
477
- ...u.getStyles("options", {
478
- className: n,
479
- style: r,
480
- classNames: t,
481
- styles: i
482
- }),
483
- ...c,
484
- id: d,
485
- role: "listbox",
486
- "aria-labelledby": s,
487
- onMouseDown: (e) => {
488
- e.preventDefault(), o?.(e);
489
- }
490
- });
491
- });
492
- ze.classes = V, ze.displayName = "@mantine/core/ComboboxOptions";
493
- //#endregion
494
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxSearch/ComboboxSearch.mjs
495
- var Be = {
496
- withAriaAttributes: !0,
497
- withKeyboardNavigation: !0
498
- }, Ve = f((e) => {
499
- let { classNames: t, styles: n, unstyled: r, vars: i, withAriaAttributes: a, onKeyDown: o, withKeyboardNavigation: s, size: c, ref: u, ...d } = l("ComboboxSearch", Be, e), f = K(), p = f.getStyles("search"), m = Ne({
500
- targetType: "input",
501
- withAriaAttributes: a,
502
- withKeyboardNavigation: s,
503
- withExpandedAttribute: !1,
504
- onKeyDown: o,
505
- autoComplete: "off"
506
- });
507
- return /* @__PURE__ */ F(w, {
508
- ref: k(u, f.store.searchRef),
509
- classNames: [{ input: p.className }, t],
510
- styles: [{ input: p.style }, n],
511
- size: c || f.size,
512
- ...m,
513
- ...d,
514
- __staticSelector: "Combobox"
515
- });
516
- });
517
- Ve.classes = V, Ve.displayName = "@mantine/core/ComboboxSearch";
518
- //#endregion
519
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/ComboboxTarget/ComboboxTarget.mjs
520
- var He = {
521
- refProp: "ref",
522
- targetType: "input",
523
- withKeyboardNavigation: !0,
524
- withAriaAttributes: !0,
525
- withExpandedAttribute: !1,
526
- autoComplete: "off"
527
- }, Ue = f((e) => {
528
- let { children: t, refProp: n, withKeyboardNavigation: r, withAriaAttributes: i, withExpandedAttribute: a, targetType: o, autoComplete: s, ref: c, ...u } = l("ComboboxTarget", He, e), d = _(t);
529
- if (!d) throw Error("Combobox.Target component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");
530
- let f = K(), p = j(d, {
531
- ...Ne({
532
- targetType: o,
533
- withAriaAttributes: i,
534
- withKeyboardNavigation: r,
535
- withExpandedAttribute: a,
536
- onKeyDown: d.props.onKeyDown,
537
- autoComplete: s
538
- }),
539
- ...u
540
- });
541
- return /* @__PURE__ */ F(y.Target, {
542
- ref: k(c, f.store.targetRef),
543
- children: p
544
- });
545
- });
546
- Ue.displayName = "@mantine/core/ComboboxTarget";
547
- //#endregion
548
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/use-combobox/get-index/get-index.mjs
549
- function We(e, t, n) {
550
- for (let n = e - 1; n >= 0; --n) if (!t[n].hasAttribute("data-combobox-disabled")) return n;
551
- if (n) {
552
- for (let e = t.length - 1; e > -1; --e) if (!t[e].hasAttribute("data-combobox-disabled")) return e;
553
- }
554
- return e;
555
- }
556
- function Ge(e, t, n) {
557
- for (let n = e + 1; n < t.length; n += 1) if (!t[n].hasAttribute("data-combobox-disabled")) return n;
558
- if (n) {
559
- for (let e = 0; e < t.length; e += 1) if (!t[e].hasAttribute("data-combobox-disabled")) return e;
560
- }
561
- return e;
562
- }
563
- function Ke(e) {
564
- for (let t = 0; t < e.length; t += 1) if (!e[t].hasAttribute("data-combobox-disabled")) return t;
565
- return -1;
566
- }
567
- //#endregion
568
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/use-combobox/use-combobox.mjs
569
- function qe({ defaultOpened: e, opened: t, onOpenedChange: n, onDropdownClose: r, onDropdownOpen: i, loop: a = !0, scrollBehavior: o = "instant" } = {}) {
570
- let [s, c] = C({
571
- value: t,
572
- defaultValue: e,
573
- finalValue: !1,
574
- onChange: n
575
- }), l = P(null), u = P(-1), d = P(null), f = P(null), p = P(-1), m = P(-1), h = P(-1), g = M((e = "unknown") => {
576
- s || (c(!0), i?.(e));
577
- }, [
578
- c,
579
- i,
580
- s
581
- ]), _ = M((e = "unknown") => {
582
- s && (c(!1), r?.(e));
583
- }, [
584
- c,
585
- r,
586
- s
587
- ]), v = M((e = "unknown") => {
588
- s ? _(e) : g(e);
589
- }, [
590
- _,
591
- g,
592
- s
593
- ]), y = M(() => {
594
- let e = z(f.current), t = Ee(`#${l.current} [data-combobox-selected]`, e);
595
- t?.removeAttribute("data-combobox-selected"), t?.removeAttribute("aria-selected");
596
- }, []), b = M((e) => {
597
- let t = z(f.current), n = Ee(`#${l.current}`, t), r = n ? R("[data-combobox-option]", n) : null;
598
- if (!r) return null;
599
- let i = e >= r.length ? 0 : e < 0 ? r.length - 1 : e;
600
- return u.current = i, r?.[i] && !r[i].hasAttribute("data-combobox-disabled") ? (y(), r[i].setAttribute("data-combobox-selected", "true"), r[i].setAttribute("aria-selected", "true"), r[i].scrollIntoView({
601
- block: "nearest",
602
- behavior: o
603
- }), r[i].id) : null;
604
- }, [o, y]), x = M(() => {
605
- let e = z(f.current), t = Ee(`#${l.current} [data-combobox-active]`, e);
606
- return b(t ? R(`#${l.current} [data-combobox-option]`, e).findIndex((e) => e === t) : 0);
607
- }, [b]), ee = M(() => {
608
- let e = z(f.current), t = R(`#${l.current} [data-combobox-option]`, e);
609
- return b(Ge(u.current, t, a));
610
- }, [b, a]), S = M(() => {
611
- let e = z(f.current), t = R(`#${l.current} [data-combobox-option]`, e);
612
- return b(We(u.current, t, a));
613
- }, [b, a]), w = M(() => {
614
- let e = z(f.current);
615
- return b(Ke(R(`#${l.current} [data-combobox-option]`, e)));
616
- }, [b]), T = M((e = "selected", t) => {
617
- if (typeof e == "number") {
618
- u.current = e;
619
- let n = z(f.current), r = R(`#${l.current} [data-combobox-option]`, n);
620
- t?.scrollIntoView && r[e]?.scrollIntoView({
621
- block: "nearest",
622
- behavior: o
623
- });
624
- return;
625
- }
626
- h.current = window.setTimeout(() => {
627
- let n = z(f.current), r = R(`#${l.current} [data-combobox-option]`, n), i = r.findIndex((t) => t.hasAttribute(`data-combobox-${e}`));
628
- u.current = i, t?.scrollIntoView && r[i]?.scrollIntoView({
629
- block: "nearest",
630
- behavior: o
631
- });
632
- }, 0);
633
- }, []), E = M(() => {
634
- u.current = -1, y();
635
- }, [y]), te = M(() => {
636
- let e = z(f.current);
637
- (R(`#${l.current} [data-combobox-option]`, e)?.[u.current])?.click();
638
- }, []), ne = M((e) => {
639
- l.current = e;
640
- }, []), D = M(() => {
641
- p.current = window.setTimeout(() => d.current?.focus(), 0);
642
- }, []), re = M(() => {
643
- m.current = window.setTimeout(() => f.current?.focus(), 0);
644
- }, []), O = M(() => u.current, []);
645
- return N(() => () => {
646
- window.clearTimeout(p.current), window.clearTimeout(m.current), window.clearTimeout(h.current);
647
- }, []), {
648
- dropdownOpened: s,
649
- openDropdown: g,
650
- closeDropdown: _,
651
- toggleDropdown: v,
652
- selectedOptionIndex: u.current,
653
- getSelectedOptionIndex: O,
654
- selectOption: b,
655
- selectFirstOption: w,
656
- selectActiveOption: x,
657
- selectNextOption: ee,
658
- selectPreviousOption: S,
659
- resetSelectedOption: E,
660
- updateSelectedOptionIndex: T,
661
- listId: l.current,
662
- setListId: ne,
663
- clickSelectedOption: te,
664
- searchRef: d,
665
- focusSearchInput: D,
666
- targetRef: f,
667
- focusTarget: re
668
- };
669
- }
670
- //#endregion
671
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/Combobox.mjs
672
- var Je = {
673
- keepMounted: !0,
674
- withinPortal: !0,
675
- resetSelectionOnOptionHover: !1,
676
- width: "target",
677
- transitionProps: {
678
- transition: "fade",
679
- duration: 0
680
- },
681
- size: "sm"
682
- }, Ye = t((e, { size: t, dropdownPadding: a }) => ({
683
- options: {
684
- "--combobox-option-fz": i(t),
685
- "--combobox-option-padding": r(t, "combobox-option-padding")
686
- },
687
- dropdown: {
688
- "--combobox-padding": a === void 0 ? void 0 : n(a),
689
- "--combobox-option-fz": i(t),
690
- "--combobox-option-padding": r(t, "combobox-option-padding")
691
- }
692
- })), Z = (e) => {
693
- let t = l("Combobox", Je, e), { classNames: n, styles: r, unstyled: i, children: a, store: s, vars: c, onOptionSubmit: u, onClose: d, size: f, dropdownPadding: p, resetSelectionOnOptionHover: m, __staticSelector: h, readOnly: g, attributes: _, ...v } = t, b = qe(), x = s || b, ee = o({
694
- name: h || "Combobox",
695
- classes: V,
696
- props: t,
697
- classNames: n,
698
- styles: r,
699
- unstyled: i,
700
- attributes: _,
701
- vars: c,
702
- varsResolver: Ye
703
- }), S = () => {
704
- d?.(), x.closeDropdown();
705
- };
706
- return /* @__PURE__ */ F(G, {
707
- value: {
708
- getStyles: ee,
709
- store: x,
710
- onOptionSubmit: u,
711
- size: f,
712
- resetSelectionOnOptionHover: m,
713
- readOnly: g
714
- },
715
- children: /* @__PURE__ */ F(y, {
716
- opened: x.dropdownOpened,
717
- preventPositionChangeWhenVisible: !1,
718
- ...v,
719
- onChange: (e) => !e && S(),
720
- withRoles: !1,
721
- unstyled: i,
722
- children: a
723
- })
724
- });
725
- };
726
- Z.extend = (e) => e, Z.classes = V, Z.varsResolver = Ye, Z.displayName = "@mantine/core/Combobox", Z.Target = Ue, Z.Dropdown = Ae, Z.Options = ze, Z.Option = Re, Z.Search = Ve, Z.Empty = Me, Z.Chevron = W, Z.Footer = Y, Z.Header = Ie, Z.EventsTarget = Fe, Z.DropdownTarget = J, Z.Group = X, Z.ClearButton = q, Z.HiddenInput = Le;
727
- //#endregion
728
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/OptionsDropdown/is-options-group.mjs
729
- function Xe(e) {
730
- return "group" in e;
731
- }
732
- //#endregion
733
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/OptionsDropdown/default-options-filter.mjs
734
- function Ze({ options: e, search: t, limit: n }) {
735
- let r = t.trim().toLowerCase(), i = [];
736
- for (let a = 0; a < e.length; a += 1) {
737
- let o = e[a];
738
- if (i.length === n) return i;
739
- Xe(o) && i.push({
740
- group: o.group,
741
- items: Ze({
742
- options: o.items,
743
- search: t,
744
- limit: n - i.length
745
- })
746
- }), Xe(o) || o.label.toLowerCase().includes(r) && i.push(o);
747
- }
748
- return i;
749
- }
750
- //#endregion
751
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/OptionsDropdown/is-empty-combobox-data.mjs
752
- function Qe(e) {
753
- if (e.length === 0) return !0;
754
- for (let t of e) if (!("group" in t) || t.items.length > 0) return !1;
755
- return !0;
756
- }
757
- //#endregion
758
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/OptionsDropdown/validate-options.mjs
759
- function $e(e, t = /* @__PURE__ */ new Set()) {
760
- if (Array.isArray(e)) for (let n of e) if (Xe(n)) $e(n.items, t);
761
- else {
762
- if (n.value === void 0) throw Error("[@mantine/core] Each option must have value property");
763
- if (t.has(n.value)) throw Error(`[@mantine/core] Duplicate options are not supported. Option with value "${n.value}" was provided more than once`);
764
- t.add(n.value);
765
- }
766
- }
767
- //#endregion
768
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Combobox/OptionsDropdown/OptionsDropdown.mjs
769
- function et(e, t) {
770
- return Array.isArray(e) ? e.includes(t) : e === t;
771
- }
772
- function tt({ data: e, withCheckIcon: t, withAlignedLabels: n, value: r, checkIconPosition: i, unstyled: a, renderOption: o }) {
773
- if (!Xe(e)) {
774
- let s = et(r, e.value), c = t && (s ? /* @__PURE__ */ F(ce, { className: V.optionsDropdownCheckIcon }) : n ? /* @__PURE__ */ F("div", { className: V.optionsDropdownCheckPlaceholder }) : null), l = /* @__PURE__ */ I(he, { children: [
775
- i === "left" && c,
776
- /* @__PURE__ */ F("span", { children: e.label }),
777
- i === "right" && c
778
- ] });
779
- return /* @__PURE__ */ F(Z.Option, {
780
- value: e.value,
781
- disabled: e.disabled,
782
- className: ge({ [V.optionsDropdownOption]: !a }),
783
- "data-reverse": i === "right" || void 0,
784
- "data-checked": s || void 0,
785
- "aria-selected": s,
786
- active: s,
787
- children: typeof o == "function" ? o({
788
- option: e,
789
- checked: s
790
- }) : l
791
- });
792
- }
793
- let s = e.items.map((e) => /* @__PURE__ */ F(tt, {
794
- data: e,
795
- value: r,
796
- unstyled: a,
797
- withCheckIcon: t,
798
- withAlignedLabels: n,
799
- checkIconPosition: i,
800
- renderOption: o
801
- }, `${e.value}`));
802
- return /* @__PURE__ */ F(Z.Group, {
803
- label: e.group,
804
- children: s
805
- });
806
- }
807
- function nt({ data: e, hidden: t, hiddenWhenEmpty: n, filter: r, search: i, limit: a, maxDropdownHeight: o, withScrollArea: s = !0, filterOptions: c = !0, withCheckIcon: l = !1, withAlignedLabels: u = !1, value: d, checkIconPosition: f, nothingFoundMessage: p, unstyled: m, labelId: h, renderOption: g, scrollAreaProps: _, "aria-label": v }) {
808
- $e(e);
809
- let y = typeof i == "string" ? (r || Ze)({
810
- options: e,
811
- search: c ? i : "",
812
- limit: a ?? Infinity
813
- }) : e, b = Qe(y), x = y.map((e) => /* @__PURE__ */ F(tt, {
814
- data: e,
815
- withCheckIcon: l,
816
- withAlignedLabels: u,
817
- value: d,
818
- checkIconPosition: f,
819
- unstyled: m,
820
- renderOption: g
821
- }, Xe(e) ? e.group : `${e.value}`));
822
- return /* @__PURE__ */ F(Z.Dropdown, {
823
- hidden: t || n && b,
824
- "data-composed": !0,
825
- children: /* @__PURE__ */ I(Z.Options, {
826
- labelledBy: h,
827
- "aria-label": v,
828
- children: [s ? /* @__PURE__ */ F(ne.Autosize, {
829
- mah: o ?? 220,
830
- type: "scroll",
831
- scrollbarSize: "var(--combobox-padding)",
832
- offsetScrollbars: "y",
833
- ..._,
834
- children: x
835
- }) : x, b && p && /* @__PURE__ */ F(Z.Empty, { children: p })]
836
- })
837
- });
838
- }
839
- //#endregion
840
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Menu/Menu.context.mjs
841
- var [rt, it] = g("Menu component was not found in the tree"), at = {
842
- dropdown: "m_dc9b7c9f",
843
- label: "m_9bfac126",
844
- divider: "m_efdf90cb",
845
- item: "m_99ac2aa1",
846
- itemLabel: "m_5476e0d3",
847
- itemSection: "m_8b75e504",
848
- chevron: "m_b85b0bed"
849
- }, ot = f((e) => {
850
- let { classNames: t, className: n, style: r, styles: i, vars: a, ...o } = l("MenuDivider", null, e);
851
- return /* @__PURE__ */ F(p, {
852
- ...it().getStyles("divider", {
853
- className: n,
854
- style: r,
855
- styles: i,
856
- classNames: t
857
- }),
858
- ...o
859
- });
860
- });
861
- ot.classes = at, ot.displayName = "@mantine/core/MenuDivider";
862
- //#endregion
863
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Menu/MenuDropdown/MenuDropdown.mjs
864
- var st = f((e) => {
865
- let { classNames: t, className: n, style: r, styles: i, vars: a, onMouseEnter: o, onMouseLeave: s, onKeyDown: c, children: u, ref: d, ...f } = l("MenuDropdown", null, e), p = P(null), m = it(), h = L(c, (e) => {
866
- (e.key === "ArrowUp" || e.key === "ArrowDown") && (e.preventDefault(), p.current?.querySelectorAll("[data-menu-item]:not(:disabled)")[0]?.focus());
867
- }), g = L(o, () => (m.trigger === "hover" || m.trigger === "click-hover") && m.openDropdown()), _ = L(s, () => (m.trigger === "hover" || m.trigger === "click-hover") && m.closeDropdown());
868
- return /* @__PURE__ */ I(y.Dropdown, {
869
- ...f,
870
- onMouseEnter: g,
871
- onMouseLeave: _,
872
- role: "menu",
873
- "aria-orientation": "vertical",
874
- ref: k(d, p),
875
- ...m.getStyles("dropdown", {
876
- className: n,
877
- style: r,
878
- styles: i,
879
- classNames: t,
880
- withStaticClass: !1
881
- }),
882
- tabIndex: -1,
883
- "data-menu-dropdown": !0,
884
- onKeyDown: h,
885
- children: [m.withInitialFocusPlaceholder && /* @__PURE__ */ F("div", {
886
- tabIndex: -1,
887
- "data-autofocus": !0,
888
- "data-mantine-stop-propagation": !0,
889
- style: { outline: 0 }
890
- }), u]
891
- });
892
- });
893
- st.classes = at, st.displayName = "@mantine/core/MenuDropdown";
894
- //#endregion
895
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Menu/MenuSub/MenuSub.context.mjs
896
- var ct = ue(null), lt = u((e) => {
897
- let { classNames: t, className: n, style: r, styles: i, vars: o, color: c, closeMenuOnClick: u, leftSection: d, rightSection: f, children: p, disabled: m, "data-disabled": h, ref: g, ..._ } = l("MenuItem", null, e), v = it(), y = de(ct), x = s(), { dir: ee } = b(), S = P(null), C = _, w = L(C.onClick, () => {
898
- h || (typeof u == "boolean" ? u && v.closeDropdownImmediately() : v.closeOnItemClick && v.closeDropdownImmediately());
899
- }), T = c ? x.variantColorResolver({
900
- color: c,
901
- theme: x,
902
- variant: "light"
903
- }) : void 0, E = c ? a({
904
- color: c,
905
- theme: x
906
- }) : null, te = L(C.onKeyDown, (e) => {
907
- e.key === "ArrowLeft" && y && (y.close(), y.focusParentItem());
908
- });
909
- return /* @__PURE__ */ I(A, {
910
- onMouseDown: (e) => e.preventDefault(),
911
- ..._,
912
- unstyled: v.unstyled,
913
- tabIndex: v.menuItemTabIndex,
914
- ...v.getStyles("item", {
915
- className: n,
916
- style: r,
917
- styles: i,
918
- classNames: t
919
- }),
920
- ref: k(S, g),
921
- role: "menuitem",
922
- disabled: m,
923
- "data-menu-item": !0,
924
- "data-disabled": m || h || void 0,
925
- "data-mantine-stop-propagation": !0,
926
- onClick: w,
927
- onKeyDown: Se({
928
- siblingSelector: "[data-menu-item]:not([data-disabled])",
929
- parentSelector: "[data-menu-dropdown]",
930
- activateOnFocus: !1,
931
- loop: v.loop,
932
- dir: ee,
933
- orientation: "vertical",
934
- onKeyDown: te
935
- }),
936
- __vars: {
937
- "--menu-item-color": E?.isThemeColor && E?.shade === void 0 ? `var(--mantine-color-${E.color}-6)` : T?.color,
938
- "--menu-item-hover": T?.hover
939
- },
940
- children: [
941
- d && /* @__PURE__ */ F("div", {
942
- ...v.getStyles("itemSection", {
943
- styles: i,
944
- classNames: t
945
- }),
946
- "data-position": "left",
947
- children: d
948
- }),
949
- p && /* @__PURE__ */ F("div", {
950
- ...v.getStyles("itemLabel", {
951
- styles: i,
952
- classNames: t
953
- }),
954
- children: p
955
- }),
956
- f && /* @__PURE__ */ F("div", {
957
- ...v.getStyles("itemSection", {
958
- styles: i,
959
- classNames: t
960
- }),
961
- "data-position": "right",
962
- children: f
963
- })
964
- ]
965
- });
966
- });
967
- lt.classes = at, lt.displayName = "@mantine/core/MenuItem";
968
- //#endregion
969
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Menu/MenuLabel/MenuLabel.mjs
970
- var ut = f((e) => {
971
- let { classNames: t, className: n, style: r, styles: i, vars: a, ...o } = l("MenuLabel", null, e);
972
- return /* @__PURE__ */ F(p, {
973
- ...it().getStyles("label", {
974
- className: n,
975
- style: r,
976
- styles: i,
977
- classNames: t
978
- }),
979
- ...o
980
- });
981
- });
982
- ut.classes = at, ut.displayName = "@mantine/core/MenuLabel";
983
- //#endregion
984
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Menu/MenuSubDropdown/MenuSubDropdown.mjs
985
- var dt = f((e) => {
986
- let { classNames: t, className: n, style: r, styles: i, vars: a, onMouseEnter: o, onMouseLeave: s, onKeyDown: c, children: u, ref: d, ...f } = l("MenuSubDropdown", null, e), p = P(null), m = it(), h = de(ct), g = L(o, h?.open), _ = L(s, h?.close);
987
- return /* @__PURE__ */ F(y.Dropdown, {
988
- ...f,
989
- onMouseEnter: g,
990
- onMouseLeave: _,
991
- role: "menu",
992
- "aria-orientation": "vertical",
993
- ref: k(d, p),
994
- ...m.getStyles("dropdown", {
995
- className: n,
996
- style: r,
997
- styles: i,
998
- classNames: t,
999
- withStaticClass: !1
1000
- }),
1001
- tabIndex: -1,
1002
- "data-menu-dropdown": !0,
1003
- children: u
1004
- });
1005
- });
1006
- dt.classes = at, dt.displayName = "@mantine/core/MenuSubDropdown";
1007
- //#endregion
1008
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Menu/MenuSubItem/MenuSubItem.mjs
1009
- var ft = u((e) => {
1010
- let { classNames: t, className: n, style: r, styles: i, vars: o, color: c, leftSection: u, rightSection: d, children: f, disabled: p, "data-disabled": m, closeMenuOnClick: h, ref: g, ..._ } = l("MenuSubItem", null, e), v = it(), y = de(ct), x = s(), { dir: ee } = b(), S = P(null), C = _, w = c ? x.variantColorResolver({
1011
- color: c,
1012
- theme: x,
1013
- variant: "light"
1014
- }) : void 0, T = c ? a({
1015
- color: c,
1016
- theme: x
1017
- }) : null, E = L(C.onKeyDown, (e) => {
1018
- e.key === "ArrowRight" && (y?.open(), y?.focusFirstItem()), e.key === "ArrowLeft" && y?.parentContext && (y.parentContext.close(), y.parentContext.focusParentItem());
1019
- }), te = L(C.onClick, () => {
1020
- !m && h && v.closeDropdownImmediately();
1021
- }), ne = L(C.onMouseEnter, y?.open), D = L(C.onMouseLeave, y?.close);
1022
- return /* @__PURE__ */ I(A, {
1023
- onMouseDown: (e) => e.preventDefault(),
1024
- ..._,
1025
- unstyled: v.unstyled,
1026
- tabIndex: v.menuItemTabIndex,
1027
- ...v.getStyles("item", {
1028
- className: n,
1029
- style: r,
1030
- styles: i,
1031
- classNames: t
1032
- }),
1033
- ref: k(S, g),
1034
- role: "menuitem",
1035
- disabled: p,
1036
- "data-menu-item": !0,
1037
- "data-sub-menu-item": !0,
1038
- "data-disabled": p || m || void 0,
1039
- "data-mantine-stop-propagation": !0,
1040
- onMouseEnter: ne,
1041
- onMouseLeave: D,
1042
- onClick: te,
1043
- onKeyDown: Se({
1044
- siblingSelector: "[data-menu-item]:not([data-disabled])",
1045
- parentSelector: "[data-menu-dropdown]",
1046
- activateOnFocus: !1,
1047
- loop: v.loop,
1048
- dir: ee,
1049
- orientation: "vertical",
1050
- onKeyDown: E
1051
- }),
1052
- __vars: {
1053
- "--menu-item-color": T?.isThemeColor && T?.shade === void 0 ? `var(--mantine-color-${T.color}-6)` : w?.color,
1054
- "--menu-item-hover": w?.hover
1055
- },
1056
- children: [
1057
- u && /* @__PURE__ */ F("div", {
1058
- ...v.getStyles("itemSection", {
1059
- styles: i,
1060
- classNames: t
1061
- }),
1062
- "data-position": "left",
1063
- children: u
1064
- }),
1065
- f && /* @__PURE__ */ F("div", {
1066
- ...v.getStyles("itemLabel", {
1067
- styles: i,
1068
- classNames: t
1069
- }),
1070
- children: f
1071
- }),
1072
- /* @__PURE__ */ F("div", {
1073
- ...v.getStyles("itemSection", {
1074
- styles: i,
1075
- classNames: t
1076
- }),
1077
- "data-position": "right",
1078
- children: d || /* @__PURE__ */ F(se, {
1079
- ...v.getStyles("chevron"),
1080
- size: 14
1081
- })
1082
- })
1083
- ]
1084
- });
1085
- });
1086
- ft.classes = at, ft.displayName = "@mantine/core/MenuSubItem";
1087
- //#endregion
1088
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Menu/MenuSubTarget/MenuSubTarget.mjs
1089
- function pt({ children: e, refProp: t }) {
1090
- if (!h(e)) throw Error("Menu.Sub.Target component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");
1091
- return it(), /* @__PURE__ */ F(y.Target, {
1092
- refProp: t,
1093
- popupType: "menu",
1094
- children: e
1095
- });
1096
- }
1097
- pt.displayName = "@mantine/core/MenuSubTarget";
1098
- //#endregion
1099
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Menu/MenuSub/MenuSub.mjs
1100
- var mt = {
1101
- offset: 0,
1102
- position: "right-start",
1103
- transitionProps: { duration: 0 },
1104
- openDelay: 0,
1105
- middlewares: { shift: { crossAxis: !0 } }
1106
- };
1107
- function ht(e) {
1108
- let { children: t, closeDelay: n, openDelay: r, ...i } = l("MenuSub", mt, e), a = te(), [o, { open: s, close: c }] = we(!1), u = de(ct), { openDropdown: d, closeDropdown: f } = De({
1109
- open: s,
1110
- close: c,
1111
- closeDelay: n,
1112
- openDelay: r
1113
- });
1114
- return /* @__PURE__ */ F(ct, {
1115
- value: {
1116
- opened: o,
1117
- close: f,
1118
- open: d,
1119
- focusFirstItem: () => window.setTimeout(() => {
1120
- document.getElementById(`${a}-dropdown`)?.querySelectorAll("[data-menu-item]:not([data-disabled])")[0]?.focus();
1121
- }, 16),
1122
- focusParentItem: () => window.setTimeout(() => {
1123
- document.getElementById(`${a}-target`)?.focus();
1124
- }, 16),
1125
- parentContext: u
1126
- },
1127
- children: /* @__PURE__ */ F(y, {
1128
- opened: o,
1129
- withinPortal: !1,
1130
- withArrow: !1,
1131
- id: a,
1132
- ...i,
1133
- children: t
1134
- })
1135
- });
1136
- }
1137
- ht.extend = (e) => e, ht.displayName = "@mantine/core/MenuSub", ht.Target = pt, ht.Dropdown = dt, ht.Item = ft;
1138
- //#endregion
1139
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Menu/MenuTarget/MenuTarget.mjs
1140
- var gt = { refProp: "ref" };
1141
- function _t(e) {
1142
- let { children: t, refProp: n, ...r } = l("MenuTarget", gt, e), i = _(t);
1143
- if (!i) throw Error("Menu.Target component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported");
1144
- let a = it(), o = i.props, s = L(o.onClick, () => {
1145
- a.trigger === "click" ? a.toggleDropdown() : a.trigger === "click-hover" && (a.setOpenedViaClick(!0), a.opened || a.openDropdown());
1146
- }), c = L(o.onMouseEnter, () => (a.trigger === "hover" || a.trigger === "click-hover") && a.openDropdown()), u = L(o.onMouseLeave, () => {
1147
- (a.trigger === "hover" || a.trigger === "click-hover" && !a.openedViaClick) && a.closeDropdown();
1148
- });
1149
- return /* @__PURE__ */ F(y.Target, {
1150
- refProp: n,
1151
- popupType: "menu",
1152
- ...r,
1153
- children: j(i, {
1154
- onClick: s,
1155
- onMouseEnter: c,
1156
- onMouseLeave: u,
1157
- "data-expanded": a.opened ? !0 : void 0
1158
- })
1159
- });
1160
- }
1161
- _t.displayName = "@mantine/core/MenuTarget";
1162
- //#endregion
1163
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Menu/Menu.mjs
1164
- var vt = {
1165
- trapFocus: !0,
1166
- closeOnItemClick: !0,
1167
- withInitialFocusPlaceholder: !0,
1168
- clickOutsideEvents: [
1169
- "mousedown",
1170
- "touchstart",
1171
- "keydown"
1172
- ],
1173
- loop: !0,
1174
- trigger: "click",
1175
- openDelay: 0,
1176
- closeDelay: 100,
1177
- menuItemTabIndex: -1
1178
- }, Q = f((e) => {
1179
- let t = l("Menu", vt, e), { children: n, onOpen: r, onClose: i, opened: a, defaultOpened: s, trapFocus: c, onChange: u, closeOnItemClick: d, loop: f, closeOnEscape: p, trigger: m, openDelay: h, closeDelay: g, classNames: _, styles: v, unstyled: b, variant: x, vars: ee, menuItemTabIndex: S, keepMounted: w, withInitialFocusPlaceholder: T, attributes: E, ...te } = t, ne = o({
1180
- name: "Menu",
1181
- classes: at,
1182
- props: t,
1183
- classNames: _,
1184
- styles: v,
1185
- unstyled: b,
1186
- attributes: E
1187
- }), [D, re] = C({
1188
- value: a,
1189
- defaultValue: s,
1190
- finalValue: !1,
1191
- onChange: u
1192
- }), [O, ie] = me(!1), k = () => {
1193
- re(!1), ie(!1), D && i?.();
1194
- }, ae = () => {
1195
- re(!0), !D && r?.();
1196
- }, A = () => {
1197
- D ? k() : ae();
1198
- }, { openDropdown: se, closeDropdown: ce } = De({
1199
- open: ae,
1200
- close: k,
1201
- closeDelay: g,
1202
- openDelay: h
1203
- }), le = (e) => Ce("[data-menu-item]", "[data-menu-dropdown]", e), { resolvedClassNames: j, resolvedStyles: ue } = oe({
1204
- classNames: _,
1205
- styles: v,
1206
- props: t
1207
- });
1208
- return /* @__PURE__ */ F(rt, {
1209
- value: {
1210
- getStyles: ne,
1211
- opened: D,
1212
- toggleDropdown: A,
1213
- getItemIndex: le,
1214
- openedViaClick: O,
1215
- setOpenedViaClick: ie,
1216
- closeOnItemClick: d,
1217
- closeDropdown: m === "click" ? k : ce,
1218
- openDropdown: m === "click" ? ae : se,
1219
- closeDropdownImmediately: k,
1220
- loop: f,
1221
- trigger: m,
1222
- unstyled: b,
1223
- menuItemTabIndex: S,
1224
- withInitialFocusPlaceholder: T
1225
- },
1226
- children: /* @__PURE__ */ F(y, {
1227
- returnFocus: !0,
1228
- ...te,
1229
- opened: D,
1230
- onChange: A,
1231
- defaultOpened: s,
1232
- trapFocus: w ? !1 : c,
1233
- closeOnEscape: p,
1234
- __staticSelector: "Menu",
1235
- classNames: j,
1236
- styles: ue,
1237
- unstyled: b,
1238
- variant: x,
1239
- keepMounted: w,
1240
- children: n
1241
- })
1242
- });
1243
- });
1244
- Q.displayName = "@mantine/core/Menu", Q.classes = at, Q.Item = lt, Q.Label = ut, Q.Dropdown = st, Q.Target = _t, Q.Divider = ot, Q.Sub = ht;
1245
- //#endregion
1246
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/NumberInput/NumberInputChevron.mjs
1247
- function yt({ direction: e, style: t, ...n }) {
1248
- return /* @__PURE__ */ F("svg", {
1249
- style: {
1250
- width: "var(--ni-chevron-size)",
1251
- height: "var(--ni-chevron-size)",
1252
- transform: e === "up" ? "rotate(180deg)" : void 0,
1253
- ...t
1254
- },
1255
- viewBox: "0 0 15 15",
1256
- fill: "none",
1257
- xmlns: "http://www.w3.org/2000/svg",
1258
- ...n,
1259
- children: /* @__PURE__ */ F("path", {
1260
- d: "M3.13523 6.15803C3.3241 5.95657 3.64052 5.94637 3.84197 6.13523L7.5 9.56464L11.158 6.13523C11.3595 5.94637 11.6759 5.95657 11.8648 6.15803C12.0536 6.35949 12.0434 6.67591 11.842 6.86477L7.84197 10.6148C7.64964 10.7951 7.35036 10.7951 7.15803 10.6148L3.15803 6.86477C2.95657 6.67591 2.94637 6.35949 3.13523 6.15803Z",
1261
- fill: "currentColor",
1262
- fillRule: "evenodd",
1263
- clipRule: "evenodd"
1264
- })
1265
- });
1266
- }
1267
- //#endregion
1268
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/NumberInput/NumberInput.module.mjs
1269
- var bt = {
1270
- root: "m_e2f5cd4e",
1271
- controls: "m_95e17d22",
1272
- control: "m_80b4b171"
1273
- }, xt = /^(0\.0*|-0(\.0*)?)$/, St = /^-?0\d+(\.\d+)?\.?$/, Ct = /\.\d*0$/, wt = /^-?\d+\.$/;
1274
- function Tt(e) {
1275
- return typeof e == "string" && e !== "" && !Number.isNaN(Number(e));
1276
- }
1277
- function Et(e) {
1278
- return typeof e == "bigint";
1279
- }
1280
- function Dt(e) {
1281
- return typeof e == "number" ? e < 2 ** 53 - 1 : e === "" || Tt(e) && Number(e) < 2 ** 53 - 1;
1282
- }
1283
- function Ot(e, t) {
1284
- return e === "" || e === "-" || !t && e.startsWith("-") ? !1 : /^-?\d+$/.test(e);
1285
- }
1286
- function kt(e, t) {
1287
- return typeof e == "bigint" ? !0 : e === "" || Ot(e, t);
1288
- }
1289
- function At(e) {
1290
- if (!/^-?\d+$/.test(e)) return null;
1291
- try {
1292
- return BigInt(e);
1293
- } catch {
1294
- return null;
1295
- }
1296
- }
1297
- function jt(e) {
1298
- if (typeof e == "bigint") return e;
1299
- if (typeof e == "number" && Number.isFinite(e) && Number.isInteger(e)) return BigInt(e);
1300
- }
1301
- function Mt(e, t, n) {
1302
- return t !== void 0 && e < t ? t : n !== void 0 && e > n ? n : e;
1303
- }
1304
- function Nt(e) {
1305
- return e.toString().replace(".", "").length;
1306
- }
1307
- function Pt(e, t) {
1308
- return (typeof e == "number" ? e < 2 ** 53 - 1 : !Number.isNaN(Number(e))) && !Number.isNaN(e) && Nt(t) < 14 && t !== "";
1309
- }
1310
- function Ft(e, t, n) {
1311
- return e === void 0 ? !0 : (t === void 0 || e >= t) && (n === void 0 || e <= n);
1312
- }
1313
- var It = {
1314
- step: 1,
1315
- clampBehavior: "blur",
1316
- allowDecimal: !0,
1317
- allowNegative: !0,
1318
- withKeyboardEvents: !0,
1319
- allowLeadingZeros: !0,
1320
- trimLeadingZeroesOnBlur: !0,
1321
- startValue: 0,
1322
- allowedDecimalSeparators: [".", ","]
1323
- }, Lt = t((e, { size: t }) => ({ controls: { "--ni-chevron-size": r(t, "ni-chevron-size") } }));
1324
- function Rt(e, t, n) {
1325
- let r = e.toString(), i = wt.test(r), a = r.replace(/^0+(?=\d)/, ""), o = parseFloat(a);
1326
- if (Number.isNaN(o)) return a;
1327
- if (o > 2 ** 53 - 1) return t === void 0 ? a : t;
1328
- let s = S(o, n, t);
1329
- return i ? `${s.toString().replace(/^0+(?=\d)/, "")}.` : s;
1330
- }
1331
- function zt(e, t) {
1332
- if (e === "" || e === "-") return e;
1333
- let n = At(e);
1334
- return n === null ? e : t.clampBehavior === "blur" ? Mt(n, t.min, t.max) : n;
1335
- }
1336
- var Bt = c((e) => {
1337
- let t = l("NumberInput", It, e), { className: n, classNames: r, styles: i, unstyled: a, vars: s, onChange: c, onValueChange: u, value: d, defaultValue: f, max: p, min: m, step: h, hideControls: g, rightSection: _, isAllowed: v, clampBehavior: y, onBlur: b, allowDecimal: ee, decimalScale: w, onKeyDown: E, onKeyDownCapture: te, handlersRef: ne, startValue: D, disabled: re, rightSectionPointerEvents: O, allowNegative: ie, readOnly: se, size: ce, rightSectionWidth: le, stepHoldInterval: j, stepHoldDelay: ue, allowLeadingZeros: de, withKeyboardEvents: M, trimLeadingZeroesOnBlur: N, allowedDecimalSeparators: fe, selectAllOnFocus: pe, onMinReached: me, onMaxReached: he, onFocus: ve, attributes: ye, ref: be, ...xe } = t, Se = ie ?? !0, L = de ?? !0, Ce = o({
1338
- name: "NumberInput",
1339
- classes: bt,
1340
- props: t,
1341
- classNames: r,
1342
- styles: i,
1343
- unstyled: a,
1344
- attributes: ye,
1345
- vars: s,
1346
- varsResolver: Lt
1347
- }), { resolvedClassNames: we, resolvedStyles: Te } = oe({
1348
- classNames: r,
1349
- styles: i,
1350
- props: t
1351
- }), Ee = P(Et(d) || Et(f) ? "bigint" : "number");
1352
- Et(d) ? Ee.current = "bigint" : typeof d == "number" && (Ee.current = "number");
1353
- let R = Ee.current === "bigint", [z, De] = C({
1354
- value: d,
1355
- defaultValue: f,
1356
- finalValue: "",
1357
- onChange: c
1358
- }), Oe = ue !== void 0 && j !== void 0, B = P(null), ke = P(null), V = P(0), H = typeof m == "number" ? m : void 0, U = typeof p == "number" ? p : void 0, W = typeof h == "number" ? h : It.step, G = typeof D == "number" ? D : It.startValue, K = jt(m), q = jt(p), Ae = jt(h) ?? BigInt(1), je = jt(D) ?? BigInt(0), J = (e) => !Ot(e, Se) || L && St.test(e) ? e : At(e) ?? e, Me = (e) => {
1359
- let t = Number(e);
1360
- return Number.isSafeInteger(t) ? t : void 0;
1361
- }, Ne = (e, t) => {
1362
- t.source === "event" && De(R ? J(e.value) : Pt(e.floatValue, e.value) && !xt.test(e.value) && !(L && St.test(e.value)) && !Ct.test(e.value) && !wt.test(e.value) ? e.floatValue : e.value), u?.(e, t);
1363
- }, Pe = (e) => {
1364
- let t = String(e).match(/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/);
1365
- return t ? Math.max(0, (t[1] ? t[1].length : 0) - (t[2] ? +t[2] : 0)) : 0;
1366
- }, Fe = (e) => {
1367
- B.current && e !== void 0 && B.current.setSelectionRange(e, e);
1368
- }, Y = P(x);
1369
- Y.current = () => {
1370
- if (R) {
1371
- if (!kt(z, Se)) return;
1372
- let e, t = z;
1373
- if (typeof t == "bigint") {
1374
- let n = t + Ae;
1375
- q !== void 0 && n > q && he?.(), e = q !== void 0 && n > q ? q : n;
1376
- } else if (typeof t == "string" && t !== "") {
1377
- let n = At(t);
1378
- if (n === null) return;
1379
- let r = n + Ae;
1380
- q !== void 0 && r > q && he?.(), e = q !== void 0 && r > q ? q : r;
1381
- } else e = Mt(je, K, q);
1382
- let n = e.toString();
1383
- De(e), u?.({
1384
- floatValue: Me(e),
1385
- formattedValue: n,
1386
- value: n
1387
- }, { source: "increment" }), setTimeout(() => Fe(B.current?.value.length), 0);
1388
- return;
1389
- }
1390
- if (!Dt(z)) return;
1391
- let e, t = Pe(z), n = Pe(W), r = Math.max(t, n), i = 10 ** r;
1392
- if (!Tt(z) && (typeof z != "number" || Number.isNaN(z))) e = S(G, H, U);
1393
- else if (U !== void 0) {
1394
- let t = (Math.round(Number(z) * i) + Math.round(W * i)) / i;
1395
- t > U && he?.(), e = t <= U ? t : U;
1396
- } else e = (Math.round(Number(z) * i) + Math.round(W * i)) / i;
1397
- let a = e.toFixed(r);
1398
- De(parseFloat(a)), u?.({
1399
- floatValue: parseFloat(a),
1400
- formattedValue: a,
1401
- value: a
1402
- }, { source: "increment" }), setTimeout(() => Fe(B.current?.value.length), 0);
1403
- };
1404
- let X = P(x);
1405
- X.current = () => {
1406
- if (R) {
1407
- if (!kt(z, Se)) return;
1408
- let e, t = K === void 0 ? Se ? void 0 : BigInt(0) : K, n = z;
1409
- if (typeof n == "bigint") {
1410
- let r = n - Ae;
1411
- t !== void 0 && r < t && me?.(), e = t !== void 0 && r < t ? t : r;
1412
- } else if (typeof n == "string" && n !== "") {
1413
- let r = At(n);
1414
- if (r === null) return;
1415
- let i = r - Ae;
1416
- t !== void 0 && i < t && me?.(), e = t !== void 0 && i < t ? t : i;
1417
- } else e = Mt(je, t, q);
1418
- let r = e.toString();
1419
- De(e), u?.({
1420
- floatValue: Me(e),
1421
- formattedValue: r,
1422
- value: r
1423
- }, { source: "decrement" }), setTimeout(() => Fe(B.current?.value.length), 0);
1424
- return;
1425
- }
1426
- if (!Dt(z)) return;
1427
- let e, t = H === void 0 ? Se ? -(2 ** 53 - 1) : 0 : H, n = Pe(z), r = Pe(W), i = Math.max(n, r), a = 10 ** i;
1428
- if (!Tt(z) && typeof z != "number" || Number.isNaN(z)) e = S(G, t, U);
1429
- else {
1430
- let n = (Math.round(Number(z) * a) - Math.round(W * a)) / a;
1431
- t !== void 0 && n < t && me?.(), e = t !== void 0 && n < t ? t : n;
1432
- }
1433
- let o = e.toFixed(i);
1434
- De(parseFloat(o)), u?.({
1435
- floatValue: parseFloat(o),
1436
- formattedValue: o,
1437
- value: o
1438
- }, { source: "decrement" }), setTimeout(() => Fe(B.current?.value.length), 0);
1439
- };
1440
- let Ie = (e) => {
1441
- let t = e.clipboardData.getData("text"), n = xe.decimalSeparator || ".", r = (fe || [".", ","]).filter((e) => e !== n);
1442
- if (r.some((e) => t.includes(e))) {
1443
- e.preventDefault();
1444
- let i = t;
1445
- r.forEach((e) => {
1446
- i = i.split(e).join(n);
1447
- });
1448
- let a = B.current;
1449
- if (a) {
1450
- let e = a.selectionStart ?? 0, t = a.selectionEnd ?? 0, n = a.value, r = n.substring(0, e) + i + n.substring(t);
1451
- (Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype, "value")?.set)?.call(a, r), a.dispatchEvent(new Event("change", { bubbles: !0 }));
1452
- let o = e + i.length;
1453
- setTimeout(() => Fe(o), 0);
1454
- }
1455
- }
1456
- xe.onPaste?.(e);
1457
- }, Le = (e) => {
1458
- E?.(e), !(se || !M) && (e.key === "ArrowUp" && (e.preventDefault(), Y.current?.()), e.key === "ArrowDown" && (e.preventDefault(), X.current?.()));
1459
- }, Re = (e) => {
1460
- if (te?.(e), e.key === "Backspace") {
1461
- let t = B.current;
1462
- t && t.selectionStart === 0 && t.selectionStart === t.selectionEnd && (e.preventDefault(), window.setTimeout(() => Fe(0), 0));
1463
- }
1464
- }, ze = (e) => {
1465
- pe && setTimeout(() => e.currentTarget.select(), 0), ve?.(e);
1466
- }, Be = (e) => {
1467
- let t = z;
1468
- R ? (y === "blur" && typeof t == "bigint" && (t = Mt(t, K, q)), N && typeof t == "string" && (t = zt(t, {
1469
- min: K,
1470
- max: q,
1471
- clampBehavior: y
1472
- }))) : (y === "blur" && typeof t == "number" && (t = S(t, H, U)), N && typeof t == "string" && Pe(t) < 15 && (t = Rt(t, U, H))), z !== t && De(t), b?.(e);
1473
- };
1474
- ae(ne, {
1475
- increment: Y.current,
1476
- decrement: X.current
1477
- });
1478
- let Ve = (e) => {
1479
- e ? Y.current?.() : X.current?.(), V.current += 1;
1480
- }, He = (e) => {
1481
- if (Ve(e), Oe) {
1482
- let t = typeof j == "number" ? j : j(V.current);
1483
- ke.current = window.setTimeout(() => He(e), t);
1484
- }
1485
- }, Ue = (e, t) => {
1486
- e.preventDefault(), B.current?.focus(), Ve(t), Oe && (ke.current = window.setTimeout(() => He(t), ue));
1487
- }, We = () => {
1488
- ke.current && window.clearTimeout(ke.current), ke.current = null, V.current = 0;
1489
- }, Ge = /* @__PURE__ */ I("div", {
1490
- ...Ce("controls"),
1491
- children: [/* @__PURE__ */ F(A, {
1492
- ...Ce("control"),
1493
- tabIndex: -1,
1494
- "aria-hidden": !0,
1495
- disabled: re || typeof z == "number" && U !== void 0 && z >= U || typeof z == "bigint" && q !== void 0 && z >= q,
1496
- mod: { direction: "up" },
1497
- onMouseDown: (e) => e.preventDefault(),
1498
- onPointerDown: (e) => {
1499
- Ue(e, !0);
1500
- },
1501
- onPointerUp: We,
1502
- onPointerLeave: We,
1503
- children: /* @__PURE__ */ F(yt, { direction: "up" })
1504
- }), /* @__PURE__ */ F(A, {
1505
- ...Ce("control"),
1506
- tabIndex: -1,
1507
- "aria-hidden": !0,
1508
- disabled: re || typeof z == "number" && H !== void 0 && z <= H || typeof z == "bigint" && K !== void 0 && z <= K,
1509
- mod: { direction: "down" },
1510
- onMouseDown: (e) => e.preventDefault(),
1511
- onPointerDown: (e) => {
1512
- Ue(e, !1);
1513
- },
1514
- onPointerUp: We,
1515
- onPointerLeave: We,
1516
- children: /* @__PURE__ */ F(yt, { direction: "down" })
1517
- })]
1518
- });
1519
- return /* @__PURE__ */ F(T, {
1520
- component: _e,
1521
- allowNegative: ie,
1522
- className: ge(bt.root, n),
1523
- size: ce,
1524
- ...xe,
1525
- inputMode: R ? "numeric" : "decimal",
1526
- readOnly: se,
1527
- disabled: re,
1528
- value: typeof z == "bigint" ? z.toString() : z,
1529
- getInputRef: k(be, B),
1530
- onValueChange: Ne,
1531
- rightSection: g || se || !(R ? kt(z, Se) : Dt(z)) ? _ : _ || Ge,
1532
- classNames: we,
1533
- styles: Te,
1534
- unstyled: a,
1535
- __staticSelector: "NumberInput",
1536
- decimalScale: R ? 0 : ee ? w : 0,
1537
- onPaste: Ie,
1538
- onFocus: ze,
1539
- onKeyDown: Le,
1540
- onKeyDownCapture: Re,
1541
- rightSectionPointerEvents: O ?? (re ? "none" : void 0),
1542
- rightSectionWidth: le ?? `var(--ni-right-section-width-${ce || "sm"})`,
1543
- allowLeadingZeros: de,
1544
- allowedDecimalSeparators: fe,
1545
- onBlur: Be,
1546
- attributes: ye,
1547
- isAllowed: (e) => {
1548
- if (!(!v || v(e))) return !1;
1549
- if (y !== "strict") return !0;
1550
- if (!R) return Ft(e.floatValue, H, U);
1551
- if (e.value === "" || e.value === "-") return !0;
1552
- let t = At(e.value);
1553
- return t === null ? !0 : (K === void 0 || t >= K) && (q === void 0 || t <= q);
1554
- }
1555
- });
1556
- });
1557
- Bt.classes = {
1558
- ...T.classes,
1559
- ...bt
1560
- }, Bt.varsResolver = Lt, Bt.displayName = "@mantine/core/NumberInput";
1561
- //#endregion
1562
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Select/Select.mjs
1563
- var Vt = {
1564
- withCheckIcon: !0,
1565
- allowDeselect: !0,
1566
- checkIconPosition: "left",
1567
- openOnFocus: !0
1568
- }, Ht = c((e) => {
1569
- let t = l("Select", Vt, e), { classNames: n, styles: r, unstyled: i, vars: a, dropdownOpened: o, defaultDropdownOpened: s, onDropdownClose: c, onDropdownOpen: u, onFocus: d, onBlur: f, onClick: p, onChange: m, data: h, value: g, defaultValue: _, selectFirstOptionOnChange: v, selectFirstOptionOnDropdownOpen: y, onOptionSubmit: b, comboboxProps: x, readOnly: ee, disabled: S, filter: w, limit: E, withScrollArea: ne, maxDropdownHeight: D, size: re, searchable: O, rightSection: ie, checkIconPosition: k, withCheckIcon: ae, withAlignedLabels: A, nothingFoundMessage: se, name: ce, form: le, searchValue: j, defaultSearchValue: ue, onSearchChange: de, allowDeselect: M, error: fe, rightSectionPointerEvents: me, id: ge, clearable: _e, clearSectionMode: ve, clearButtonProps: ye, hiddenInputProps: be, renderOption: xe, onClear: Se, autoComplete: L, scrollAreaProps: Ce, __defaultRightSection: we, __clearSection: Ee, __clearable: R, chevronColor: z, autoSelectOnBlur: De, openOnFocus: Oe, attributes: V, ...H } = t, U = pe(() => B(h), [h]), W = P({}), G = pe(() => ke(U), [U]), K = te(ge), [q, Ae, je] = C({
1570
- value: g,
1571
- defaultValue: _,
1572
- finalValue: null,
1573
- onChange: m
1574
- }), J = q == null ? void 0 : `${q}` in G ? G[`${q}`] : W.current[`${q}`], Me = Te(J), [Ne, Pe, Fe] = C({
1575
- value: j,
1576
- defaultValue: ue,
1577
- finalValue: J ? J.label : "",
1578
- onChange: de
1579
- }), Y = qe({
1580
- opened: o,
1581
- defaultOpened: s,
1582
- onDropdownOpen: () => {
1583
- u?.(), y ? Y.selectFirstOption() : Y.updateSelectedOptionIndex("active", { scrollIntoView: !0 });
1584
- },
1585
- onDropdownClose: () => {
1586
- c?.(), setTimeout(Y.resetSelectedOption, 0);
1587
- }
1588
- }), X = (e) => {
1589
- Pe(e), Y.resetSelectedOption();
1590
- }, { resolvedClassNames: Ie, resolvedStyles: Le } = oe({
1591
- props: t,
1592
- styles: r,
1593
- classNames: n
1594
- });
1595
- N(() => {
1596
- v && Y.selectFirstOption();
1597
- }, [v, Ne]), N(() => {
1598
- g === null && X(""), g != null && J && (Me?.value !== J.value || Me?.label !== J.label) && X(J.label);
1599
- }, [g, J]), N(() => {
1600
- !je && !Fe && X(q == null ? "" : `${q}` in G ? G[`${q}`]?.label : W.current[`${q}`]?.label || "");
1601
- }, [G, q]), N(() => {
1602
- q && `${q}` in G && (W.current[`${q}`] = G[`${q}`]);
1603
- }, [G, q]);
1604
- let Re = /* @__PURE__ */ F(Z.ClearButton, {
1605
- ...ye,
1606
- onClear: () => {
1607
- Ae(null, null), X(""), Se?.();
1608
- }
1609
- }), ze = _e && !!q && !S && !ee;
1610
- return /* @__PURE__ */ I(he, { children: [/* @__PURE__ */ I(Z, {
1611
- store: Y,
1612
- __staticSelector: "Select",
1613
- classNames: Ie,
1614
- styles: Le,
1615
- unstyled: i,
1616
- readOnly: ee,
1617
- size: re,
1618
- attributes: V,
1619
- keepMounted: De,
1620
- onOptionSubmit: (e) => {
1621
- b?.(e);
1622
- let t = M && `${G[e].value}` == `${q}` ? null : G[e], n = t ? t.value : null;
1623
- n !== q && Ae(n, t), !je && X(n == null ? "" : t?.label || ""), Y.closeDropdown();
1624
- },
1625
- ...x,
1626
- children: [/* @__PURE__ */ F(Z.Target, {
1627
- targetType: O ? "input" : "button",
1628
- autoComplete: L,
1629
- withExpandedAttribute: !0,
1630
- children: /* @__PURE__ */ F(T, {
1631
- id: K,
1632
- __defaultRightSection: /* @__PURE__ */ F(Z.Chevron, {
1633
- size: re,
1634
- error: fe,
1635
- unstyled: i,
1636
- color: z
1637
- }),
1638
- __clearSection: Re,
1639
- __clearable: ze,
1640
- __clearSectionMode: ve,
1641
- rightSection: ie,
1642
- rightSectionPointerEvents: me || "none",
1643
- ...H,
1644
- size: re,
1645
- __staticSelector: "Select",
1646
- disabled: S,
1647
- readOnly: ee || !O,
1648
- value: Ne,
1649
- onChange: (e) => {
1650
- X(e.currentTarget.value), Y.openDropdown(), v && Y.selectFirstOption();
1651
- },
1652
- onFocus: (e) => {
1653
- Oe && O && Y.openDropdown(), d?.(e);
1654
- },
1655
- onBlur: (e) => {
1656
- De && Y.clickSelectedOption(), O && Y.closeDropdown();
1657
- let t = q != null && (`${q}` in G ? G[`${q}`] : W.current[`${q}`]);
1658
- X(t && t.label || ""), f?.(e);
1659
- },
1660
- onClick: (e) => {
1661
- O ? Y.openDropdown() : Y.toggleDropdown(), p?.(e);
1662
- },
1663
- classNames: Ie,
1664
- styles: Le,
1665
- unstyled: i,
1666
- pointer: !O,
1667
- error: fe,
1668
- attributes: V
1669
- })
1670
- }), /* @__PURE__ */ F(nt, {
1671
- data: U,
1672
- hidden: ee || S,
1673
- filter: w,
1674
- search: Ne,
1675
- limit: E,
1676
- hiddenWhenEmpty: !se,
1677
- withScrollArea: ne,
1678
- maxDropdownHeight: D,
1679
- filterOptions: !!O && J?.label !== Ne,
1680
- value: q,
1681
- checkIconPosition: k,
1682
- withCheckIcon: ae,
1683
- withAlignedLabels: A,
1684
- nothingFoundMessage: se,
1685
- unstyled: i,
1686
- labelId: H.label ? `${K}-label` : void 0,
1687
- "aria-label": H.label ? void 0 : H["aria-label"],
1688
- renderOption: xe,
1689
- scrollAreaProps: Ce
1690
- })]
1691
- }), /* @__PURE__ */ F(Z.HiddenInput, {
1692
- value: q,
1693
- name: ce,
1694
- form: le,
1695
- disabled: S,
1696
- ...be
1697
- })] });
1698
- });
1699
- Ht.classes = {
1700
- ...T.classes,
1701
- ...Z.classes
1702
- }, Ht.displayName = "@mantine/core/Select";
1703
- //#endregion
1704
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Switch/SwitchGroup/SwitchGroup.mjs
1705
- var Ut = ue(null), Wt = { hiddenInputValuesSeparator: "," }, Gt = c(((e) => {
1706
- let { value: t, defaultValue: n, onChange: r, size: i, wrapperProps: a, children: o, readOnly: s, name: c, hiddenInputValuesSeparator: u, hiddenInputProps: d, maxSelectedValues: f, disabled: p, ...m } = l("SwitchGroup", Wt, e), [h, g] = C({
1707
- value: t,
1708
- defaultValue: n,
1709
- finalValue: [],
1710
- onChange: r
1711
- }), _ = (e) => {
1712
- let t = e.currentTarget.value;
1713
- if (s) return;
1714
- let n = h.includes(t);
1715
- !n && f && h.length >= f || g(n ? h.filter((e) => e !== t) : [...h, t]);
1716
- }, v = (e) => {
1717
- if (p) return !0;
1718
- if (!f) return !1;
1719
- let t = h.includes(e), n = h.length >= f;
1720
- return !t && n;
1721
- }, y = h.join(u);
1722
- return /* @__PURE__ */ F(Ut, {
1723
- value: {
1724
- value: h,
1725
- onChange: _,
1726
- size: i,
1727
- isDisabled: v
1728
- },
1729
- children: /* @__PURE__ */ I(w.Wrapper, {
1730
- size: i,
1731
- ...a,
1732
- ...m,
1733
- labelElement: "div",
1734
- __staticSelector: "SwitchGroup",
1735
- children: [/* @__PURE__ */ F(D, {
1736
- role: "group",
1737
- children: o
1738
- }), /* @__PURE__ */ F("input", {
1739
- type: "hidden",
1740
- name: c,
1741
- value: y,
1742
- ...d
1743
- })]
1744
- })
1745
- });
1746
- }));
1747
- Gt.classes = w.Wrapper.classes, Gt.displayName = "@mantine/core/SwitchGroup";
1748
- //#endregion
1749
- //#region ../../node_modules/.bun/@mantine+core@9.0.0+9dd69a0af178a974/node_modules/@mantine/core/esm/components/Switch/Switch.module.mjs
1750
- var Kt = {
1751
- root: "m_5f93f3bb",
1752
- input: "m_926b4011",
1753
- track: "m_9307d992",
1754
- thumb: "m_93039a1d",
1755
- trackLabel: "m_8277e082"
1756
- }, qt = {
1757
- labelPosition: "right",
1758
- withThumbIndicator: !0
1759
- }, Jt = t((t, { radius: n, color: i, size: a }) => ({ root: {
1760
- "--switch-radius": n === void 0 ? void 0 : e(n),
1761
- "--switch-height": r(a, "switch-height"),
1762
- "--switch-width": r(a, "switch-width"),
1763
- "--switch-thumb-size": r(a, "switch-thumb-size"),
1764
- "--switch-label-font-size": r(a, "switch-label-font-size"),
1765
- "--switch-track-label-padding": r(a, "switch-track-label-padding"),
1766
- "--switch-color": i ? m(i, t) : void 0
1767
- } })), Yt = f((e) => {
1768
- let t = l("Switch", qt, e), { classNames: n, className: r, style: i, styles: a, unstyled: s, vars: c, color: u, label: f, offLabel: m, onLabel: h, id: g, size: _, radius: v, wrapperProps: y, thumbIcon: b, checked: x, defaultChecked: ee, onChange: S, labelPosition: w, description: T, error: E, disabled: ne, variant: D, rootRef: O, mod: ie, withThumbIndicator: k, attributes: ae, ...oe } = t, A = de(Ut), se = _ || A?.size, ce = o({
1769
- name: "Switch",
1770
- props: t,
1771
- classes: Kt,
1772
- className: r,
1773
- style: i,
1774
- classNames: n,
1775
- styles: a,
1776
- unstyled: s,
1777
- attributes: ae,
1778
- vars: c,
1779
- varsResolver: Jt
1780
- }), { styleProps: le, rest: j } = d(oe), ue = te(g), M = {
1781
- checked: A?.value.includes(j.value) ?? x,
1782
- onChange: (e) => {
1783
- A?.onChange(e), S?.(e);
1784
- }
1785
- }, N = ne || A?.isDisabled?.(j.value), [fe, pe] = C({
1786
- value: M.checked ?? x,
1787
- defaultValue: ee,
1788
- finalValue: !1
1789
- });
1790
- return /* @__PURE__ */ I(re, {
1791
- ...ce("root"),
1792
- __staticSelector: "Switch",
1793
- __stylesApiProps: t,
1794
- id: ue,
1795
- size: se,
1796
- labelPosition: w,
1797
- label: f,
1798
- description: T,
1799
- error: E,
1800
- disabled: N,
1801
- bodyElement: "label",
1802
- labelElement: "span",
1803
- classNames: n,
1804
- styles: a,
1805
- unstyled: s,
1806
- "data-checked": M.checked,
1807
- variant: D,
1808
- ref: O,
1809
- mod: ie,
1810
- attributes: ae,
1811
- inert: j.inert,
1812
- ...le,
1813
- ...y,
1814
- children: [/* @__PURE__ */ F("input", {
1815
- ...j,
1816
- ...M,
1817
- disabled: N,
1818
- checked: fe,
1819
- "data-checked": M.checked,
1820
- onChange: (e) => {
1821
- M.onChange?.(e), pe(e.currentTarget.checked);
1822
- },
1823
- id: ue,
1824
- type: "checkbox",
1825
- role: "switch",
1826
- inert: j.inert,
1827
- ...ce("input")
1828
- }), /* @__PURE__ */ I(p, {
1829
- "aria-hidden": "true",
1830
- component: "span",
1831
- mod: {
1832
- error: E,
1833
- "label-position": w,
1834
- "without-labels": !h && !m
1835
- },
1836
- ...ce("track"),
1837
- children: [/* @__PURE__ */ F(p, {
1838
- component: "span",
1839
- mod: {
1840
- "reduce-motion": !0,
1841
- "with-thumb-indicator": k && !b
1842
- },
1843
- ...ce("thumb"),
1844
- children: b
1845
- }), /* @__PURE__ */ F("span", {
1846
- ...ce("trackLabel"),
1847
- children: fe ? h : m
1848
- })]
1849
- })]
1850
- });
1851
- });
1852
- Yt.classes = {
1853
- ...Kt,
1854
- ...O
1855
- }, Yt.varsResolver = Jt, Yt.displayName = "@mantine/core/Switch", Yt.Group = Gt;
1856
- //#endregion
1857
- //#region src/components/Shared/DirtyIndicator/DirtyIndicator.tsx
1858
- var Xt = ({ size: e = 16 }) => /* @__PURE__ */ F("span", {
1859
- style: {
1860
- color: "orange",
1861
- fontWeight: "bold",
1862
- marginLeft: "8px",
1863
- display: "flex",
1864
- alignItems: "center"
1865
- },
1866
- title: "Unsaved changes",
1867
- children: le("FcSynchronize", { size: e })
1868
- }), $ = {
1869
- root: "_root_1aqog_1",
1870
- menuTrigger: "_menuTrigger_1aqog_19",
1871
- element: "_element_1aqog_37",
1872
- sliderLabel: "_sliderLabel_1aqog_44",
1873
- select: "_select_1aqog_50",
1874
- textInput: "_textInput_1aqog_51",
1875
- numberInput: "_numberInput_1aqog_52",
1876
- slider: "_slider_1aqog_44"
1877
- }, Zt = {
1878
- size: 16,
1879
- style: { display: "block" }
1880
- }, Qt = ({ name: e }) => le(e, Zt), $t = ({ label: e, icon: t, items: n, rightSection: r }) => {
1881
- let [i, a] = me(!1);
1882
- return /* @__PURE__ */ I(Q, {
1883
- opened: i,
1884
- onClose: () => a(!1),
1885
- withinPortal: !0,
1886
- keepMounted: !0,
1887
- closeOnItemClick: !0,
1888
- closeOnEscape: !0,
1889
- closeOnClickOutside: !0,
1890
- position: "bottom-start",
1891
- children: [/* @__PURE__ */ F(Q.Target, { children: /* @__PURE__ */ I("button", {
1892
- className: $.menuTrigger,
1893
- onClick: () => a((e) => !e),
1894
- children: [
1895
- t && /* @__PURE__ */ F(() => le(t ?? "", Zt), {}),
1896
- /* @__PURE__ */ F("span", { children: e }),
1897
- r && /* @__PURE__ */ F("span", {
1898
- style: { marginLeft: "auto" },
1899
- children: r
1900
- })
1901
- ]
1902
- }) }), /* @__PURE__ */ F(Q.Dropdown, { children: n.map((e, t) => e.type === "divider" ? /* @__PURE__ */ F(Q.Divider, {}, t) : e.type === "slider" ? /* @__PURE__ */ F(Q.Item, {
1903
- closeMenuOnClick: !1,
1904
- children: /* @__PURE__ */ I("div", {
1905
- style: { minWidth: 120 },
1906
- children: [e.label && /* @__PURE__ */ F("div", {
1907
- style: { marginBottom: 4 },
1908
- children: e.label
1909
- }), /* @__PURE__ */ F(ie, {
1910
- min: e.min,
1911
- max: e.max,
1912
- value: e.value,
1913
- onChange: e.onChange,
1914
- size: "sm"
1915
- })]
1916
- })
1917
- }, t) : /* @__PURE__ */ F(Q.Item, {
1918
- disabled: e.disabled,
1919
- onClick: e.onClick,
1920
- leftSection: e.icon ? /* @__PURE__ */ F(Qt, { name: e.icon }) : void 0,
1921
- children: e.label
1922
- }, t)) })]
1923
- });
1924
- }, en = ({ elements: e }) => {
1925
- let [t, n] = me({}), r = (e, t) => {
1926
- n((n) => ({
1927
- ...n,
1928
- [e]: {
1929
- ...n[e] ?? {
1930
- isHovered: !1,
1931
- isDragging: !1
1932
- },
1933
- ...t
1934
- }
1935
- }));
1936
- };
1937
- return /* @__PURE__ */ F("div", {
1938
- className: $.root,
1939
- role: "menubar",
1940
- "aria-label": "Application menu",
1941
- children: e.map((e, n) => {
1942
- switch (e.type) {
1943
- case "menu": return /* @__PURE__ */ F($t, {
1944
- label: e.label,
1945
- icon: e.icon,
1946
- items: e.items,
1947
- rightSection: e.rightSection
1948
- }, n);
1949
- case "combobox": return /* @__PURE__ */ F("div", {
1950
- className: $.element,
1951
- children: /* @__PURE__ */ F(Ht, {
1952
- data: e.options,
1953
- value: e.value,
1954
- onChange: (t) => t && e.onChange(t),
1955
- placeholder: e.label,
1956
- size: "sm",
1957
- className: $.select,
1958
- comboboxProps: { withinPortal: !0 }
1959
- })
1960
- }, n);
1961
- case "switch": return /* @__PURE__ */ F("div", {
1962
- className: $.element,
1963
- children: /* @__PURE__ */ F(Yt, {
1964
- label: e.label,
1965
- checked: e.checked,
1966
- onChange: (t) => e.onChange(t.currentTarget.checked),
1967
- size: "sm"
1968
- })
1969
- }, n);
1970
- case "slider": {
1971
- let i = t[n] ?? {
1972
- isHovered: !1,
1973
- isDragging: !1
1974
- }, a = i.isHovered || i.isDragging;
1975
- return /* @__PURE__ */ F(ee, {
1976
- label: (e.labelFormat ?? ((e) => String(e)))(e.value),
1977
- position: "bottom",
1978
- withArrow: !0,
1979
- opened: a,
1980
- children: /* @__PURE__ */ I("div", {
1981
- className: $.element,
1982
- onMouseEnter: () => r(n, { isHovered: !0 }),
1983
- onMouseLeave: () => r(n, { isHovered: !1 }),
1984
- children: [e.label && /* @__PURE__ */ F("span", {
1985
- className: $.sliderLabel,
1986
- children: e.label
1987
- }), /* @__PURE__ */ F(ie, {
1988
- min: e.min,
1989
- max: e.max,
1990
- value: e.value,
1991
- onChange: (t) => {
1992
- e.onChange(t), r(n, { isDragging: !0 });
1993
- },
1994
- onChangeEnd: (t) => {
1995
- e.onChange(t), r(n, { isDragging: !1 });
1996
- },
1997
- size: "sm",
1998
- className: $.slider,
1999
- marks: e.marks
2000
- })]
2001
- })
2002
- }, n);
2003
- }
2004
- case "text-input": return /* @__PURE__ */ F("div", {
2005
- className: $.element,
2006
- children: /* @__PURE__ */ F(E, {
2007
- placeholder: e.placeholder,
2008
- value: e.value,
2009
- onChange: (t) => e.onChange(t.currentTarget.value),
2010
- size: "sm",
2011
- className: $.textInput
2012
- })
2013
- }, n);
2014
- case "number-input": return /* @__PURE__ */ F("div", {
2015
- className: $.element,
2016
- children: /* @__PURE__ */ F(Bt, {
2017
- label: e.label,
2018
- value: e.value,
2019
- onChange: (t) => e.onChange(typeof t == "number" ? t : 0),
2020
- min: e.min,
2021
- max: e.max,
2022
- step: e.step ?? 1,
2023
- placeholder: e.placeholder,
2024
- size: "sm",
2025
- className: $.numberInput
2026
- })
2027
- }, n);
2028
- case "select": return /* @__PURE__ */ F("div", {
2029
- className: $.element,
2030
- children: /* @__PURE__ */ F(Ht, {
2031
- label: e.label,
2032
- data: e.options,
2033
- value: e.value,
2034
- onChange: (t) => t && e.onChange(t),
2035
- size: "sm",
2036
- className: $.select,
2037
- comboboxProps: { withinPortal: !0 }
2038
- })
2039
- }, n);
2040
- case "dirty-indicator": return /* @__PURE__ */ F("span", {
2041
- style: { marginLeft: "auto" },
2042
- children: /* @__PURE__ */ F(Xt, {})
2043
- }, n);
2044
- }
2045
- })
2046
- });
2047
- };
2048
- //#endregion
2049
- export { Xt as n, Q as r, en as t };