chop-logic-components 2.0.0 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (181) hide show
  1. package/README.md +24 -8
  2. package/dist/icons/index.d.ts +5 -5
  3. package/dist/icons/svg/ArrowDownIcon.d.ts +2 -2
  4. package/dist/icons/svg/ArrowUpIcon.d.ts +2 -2
  5. package/dist/icons/svg/BackIcon.d.ts +2 -2
  6. package/dist/icons/svg/CancelIcon.d.ts +2 -2
  7. package/dist/icons/svg/CheckMarkIcon.d.ts +2 -2
  8. package/dist/icons/svg/CheckboxCheckedIcon.d.ts +2 -2
  9. package/dist/icons/svg/CheckboxUncheckedIcon.d.ts +2 -2
  10. package/dist/icons/svg/ChevronDownIcon.d.ts +2 -2
  11. package/dist/icons/svg/ChevronLeftIcon.d.ts +2 -2
  12. package/dist/icons/svg/ChevronRightIcon.d.ts +2 -2
  13. package/dist/icons/svg/ChevronUpIcon.d.ts +2 -2
  14. package/dist/icons/svg/ClearIcon.d.ts +2 -2
  15. package/dist/icons/svg/CopyIcon.d.ts +2 -2
  16. package/dist/icons/svg/CutIcon.d.ts +2 -2
  17. package/dist/icons/svg/DeleteIcon.d.ts +2 -2
  18. package/dist/icons/svg/DownloadIcon.d.ts +2 -2
  19. package/dist/icons/svg/ErrorIcon.d.ts +2 -2
  20. package/dist/icons/svg/ForwardIcon.d.ts +2 -2
  21. package/dist/icons/svg/GraduateIcon.d.ts +2 -2
  22. package/dist/icons/svg/HelpIcon.d.ts +2 -2
  23. package/dist/icons/svg/HideIcon.d.ts +2 -2
  24. package/dist/icons/svg/HomeIcon.d.ts +2 -2
  25. package/dist/icons/svg/InfoIcon.d.ts +2 -2
  26. package/dist/icons/svg/LoginIcon.d.ts +2 -2
  27. package/dist/icons/svg/PasteIcon.d.ts +2 -2
  28. package/dist/icons/svg/QuestionIcon.d.ts +2 -2
  29. package/dist/icons/svg/RemoveIcon.d.ts +2 -2
  30. package/dist/icons/svg/SaveIcon.d.ts +2 -2
  31. package/dist/icons/svg/ShowIcon.d.ts +2 -2
  32. package/dist/icons/svg/UploadIcon.d.ts +2 -2
  33. package/dist/icons/svg/WarningIcon.d.ts +2 -2
  34. package/dist/index.cjs.js +985 -1
  35. package/dist/index.cjs.js.map +1 -1
  36. package/dist/index.es.js +4216 -38
  37. package/dist/index.es.js.map +1 -1
  38. package/dist/models/components/icon.d.ts +5 -0
  39. package/dist/models/index.d.ts +1 -1
  40. package/package.json +19 -19
  41. package/dist/BackIcon-6a-KPT4R.cjs +0 -2
  42. package/dist/BackIcon-6a-KPT4R.cjs.map +0 -1
  43. package/dist/BackIcon-Dol4HlEB.js +0 -11
  44. package/dist/BackIcon-Dol4HlEB.js.map +0 -1
  45. package/dist/CancelIcon-Bdj8BJBh.js +0 -11
  46. package/dist/CancelIcon-Bdj8BJBh.js.map +0 -1
  47. package/dist/CancelIcon-Io9DmIXB.cjs +0 -2
  48. package/dist/CancelIcon-Io9DmIXB.cjs.map +0 -1
  49. package/dist/ChevronDownIcon-Bc3VeNFb.js +0 -17
  50. package/dist/ChevronDownIcon-Bc3VeNFb.js.map +0 -1
  51. package/dist/ChevronDownIcon-u_QuMZ-m.cjs +0 -2
  52. package/dist/ChevronDownIcon-u_QuMZ-m.cjs.map +0 -1
  53. package/dist/ChevronLeftIcon-7IFnvAad.js +0 -17
  54. package/dist/ChevronLeftIcon-7IFnvAad.js.map +0 -1
  55. package/dist/ChevronLeftIcon-CBJFCd4g.cjs +0 -2
  56. package/dist/ChevronLeftIcon-CBJFCd4g.cjs.map +0 -1
  57. package/dist/ChevronRightIcon-CSlX-7NZ.js +0 -17
  58. package/dist/ChevronRightIcon-CSlX-7NZ.js.map +0 -1
  59. package/dist/ChevronRightIcon-C_13rpgA.cjs +0 -2
  60. package/dist/ChevronRightIcon-C_13rpgA.cjs.map +0 -1
  61. package/dist/ChevronUpIcon-CTEQHMLW.cjs +0 -2
  62. package/dist/ChevronUpIcon-CTEQHMLW.cjs.map +0 -1
  63. package/dist/ChevronUpIcon-DfSPGScz.js +0 -11
  64. package/dist/ChevronUpIcon-DfSPGScz.js.map +0 -1
  65. package/dist/ClearIcon-DR09y0XK.js +0 -12
  66. package/dist/ClearIcon-DR09y0XK.js.map +0 -1
  67. package/dist/ClearIcon-oiZQl1xy.cjs +0 -2
  68. package/dist/ClearIcon-oiZQl1xy.cjs.map +0 -1
  69. package/dist/CopyIcon-CfJxdJkE.cjs +0 -2
  70. package/dist/CopyIcon-CfJxdJkE.cjs.map +0 -1
  71. package/dist/CopyIcon-Cncb2wSQ.js +0 -27
  72. package/dist/CopyIcon-Cncb2wSQ.js.map +0 -1
  73. package/dist/CutIcon-C0ot7pv1.cjs +0 -2
  74. package/dist/CutIcon-C0ot7pv1.cjs.map +0 -1
  75. package/dist/CutIcon-DsxJcafW.js +0 -29
  76. package/dist/CutIcon-DsxJcafW.js.map +0 -1
  77. package/dist/DeleteIcon-C0T5ZleK.js +0 -11
  78. package/dist/DeleteIcon-C0T5ZleK.js.map +0 -1
  79. package/dist/DeleteIcon-CVPhcSfG.cjs +0 -2
  80. package/dist/DeleteIcon-CVPhcSfG.cjs.map +0 -1
  81. package/dist/DownloadIcon-BHhuRKBy.cjs +0 -2
  82. package/dist/DownloadIcon-BHhuRKBy.cjs.map +0 -1
  83. package/dist/DownloadIcon-C_1FJXS6.js +0 -11
  84. package/dist/DownloadIcon-C_1FJXS6.js.map +0 -1
  85. package/dist/ForwardIcon-CKnkecv-.cjs +0 -2
  86. package/dist/ForwardIcon-CKnkecv-.cjs.map +0 -1
  87. package/dist/ForwardIcon-DSxMxnjb.js +0 -11
  88. package/dist/ForwardIcon-DSxMxnjb.js.map +0 -1
  89. package/dist/GraduateIcon-DQLWdRj8.js +0 -9
  90. package/dist/GraduateIcon-DQLWdRj8.js.map +0 -1
  91. package/dist/GraduateIcon-Dsk-T3da.cjs +0 -2
  92. package/dist/GraduateIcon-Dsk-T3da.cjs.map +0 -1
  93. package/dist/HideIcon-Bp5glcyr.js +0 -11
  94. package/dist/HideIcon-Bp5glcyr.js.map +0 -1
  95. package/dist/HideIcon-CyItCp1h.cjs +0 -2
  96. package/dist/HideIcon-CyItCp1h.cjs.map +0 -1
  97. package/dist/HomeIcon-DX_PgT5n.cjs +0 -2
  98. package/dist/HomeIcon-DX_PgT5n.cjs.map +0 -1
  99. package/dist/HomeIcon-DyYP6u5L.js +0 -9
  100. package/dist/HomeIcon-DyYP6u5L.js.map +0 -1
  101. package/dist/LoginIcon-CXb93ZdU.js +0 -9
  102. package/dist/LoginIcon-CXb93ZdU.js.map +0 -1
  103. package/dist/LoginIcon-CYQ6pYwB.cjs +0 -2
  104. package/dist/LoginIcon-CYQ6pYwB.cjs.map +0 -1
  105. package/dist/PasteIcon-BIKTS0Dz.cjs +0 -2
  106. package/dist/PasteIcon-BIKTS0Dz.cjs.map +0 -1
  107. package/dist/PasteIcon-D5VKRUHc.js +0 -11
  108. package/dist/PasteIcon-D5VKRUHc.js.map +0 -1
  109. package/dist/QuestionIcon-CA5cYfsl.js +0 -23
  110. package/dist/QuestionIcon-CA5cYfsl.js.map +0 -1
  111. package/dist/QuestionIcon-DbZnERtn.cjs +0 -2
  112. package/dist/QuestionIcon-DbZnERtn.cjs.map +0 -1
  113. package/dist/RemoveIcon-CzYds-64.cjs +0 -2
  114. package/dist/RemoveIcon-CzYds-64.cjs.map +0 -1
  115. package/dist/RemoveIcon-DIvsqLi-.js +0 -31
  116. package/dist/RemoveIcon-DIvsqLi-.js.map +0 -1
  117. package/dist/SaveIcon-B84k1D5f.cjs +0 -2
  118. package/dist/SaveIcon-B84k1D5f.cjs.map +0 -1
  119. package/dist/SaveIcon-DhBj4tAF.js +0 -11
  120. package/dist/SaveIcon-DhBj4tAF.js.map +0 -1
  121. package/dist/ShowIcon-DkpGVHWR.js +0 -12
  122. package/dist/ShowIcon-DkpGVHWR.js.map +0 -1
  123. package/dist/ShowIcon-SGeEvbuz.cjs +0 -2
  124. package/dist/ShowIcon-SGeEvbuz.cjs.map +0 -1
  125. package/dist/UploadIcon-CvFnGI7Y.js +0 -12
  126. package/dist/UploadIcon-CvFnGI7Y.js.map +0 -1
  127. package/dist/UploadIcon-va72gwks.cjs +0 -2
  128. package/dist/UploadIcon-va72gwks.cjs.map +0 -1
  129. package/dist/__tests__/index.test.d.ts +0 -1
  130. package/dist/components/containers/form/__tests__/Form.test.d.ts +0 -1
  131. package/dist/components/containers/form/__tests__/helpers.test.d.ts +0 -1
  132. package/dist/components/containers/grid/__tests__/Body.test.d.ts +0 -1
  133. package/dist/components/containers/grid/__tests__/ColumnGroup.test.d.ts +0 -1
  134. package/dist/components/containers/grid/__tests__/Grid.test.d.ts +0 -1
  135. package/dist/components/containers/grid/__tests__/Head.test.d.ts +0 -1
  136. package/dist/components/containers/grid/__tests__/Row.test.d.ts +0 -1
  137. package/dist/components/containers/grid/__tests__/SelectAllRowsCell.test.d.ts +0 -1
  138. package/dist/components/containers/grid/__tests__/SelectRowCell.test.d.ts +0 -1
  139. package/dist/components/containers/grid/__tests__/helpers.test.d.ts +0 -1
  140. package/dist/components/containers/menu/__tests__/Menu.test.d.ts +0 -1
  141. package/dist/components/containers/menu/__tests__/MenuItem.test.d.ts +0 -1
  142. package/dist/components/containers/menu/__tests__/MenuLeaf.test.d.ts +0 -1
  143. package/dist/components/containers/menu/__tests__/SubMenu.test.d.ts +0 -1
  144. package/dist/components/containers/portal/__tests__/Portal.test.d.ts +0 -1
  145. package/dist/components/containers/tabs/__tests__/TabList.test.d.ts +0 -1
  146. package/dist/components/containers/tabs/__tests__/Tabs.test.d.ts +0 -1
  147. package/dist/components/inputs/button/__tests__/Button.test.d.ts +0 -1
  148. package/dist/components/inputs/checkbox/__tests__/Checkbox.test.d.ts +0 -1
  149. package/dist/components/inputs/multi-select/__tests__/MultiSelect.test.d.ts +0 -1
  150. package/dist/components/inputs/multi-select/__tests__/helpers.test.d.ts +0 -1
  151. package/dist/components/inputs/numeric/__tests__/NumericInput.test.d.ts +0 -1
  152. package/dist/components/inputs/numeric/__tests__/helpers.test.d.ts +0 -1
  153. package/dist/components/inputs/select/__tests__/Select.test.d.ts +0 -1
  154. package/dist/components/inputs/select/__tests__/helpers.test.d.ts +0 -1
  155. package/dist/components/inputs/text/__tests__/TextInput.test.d.ts +0 -1
  156. package/dist/components/inputs/text/__tests__/helpers.test.d.ts +0 -1
  157. package/dist/components/modals/alert/__tests__/Alert.test.d.ts +0 -1
  158. package/dist/components/modals/alert/__tests__/helpers.test.d.ts +0 -1
  159. package/dist/components/modals/dialog/__tests__/Dialog.test.d.ts +0 -1
  160. package/dist/components/modals/tooltip/__tests__/Tooltip.test.d.ts +0 -1
  161. package/dist/elements/error-message/__tests__/ErrorMessage.test.d.ts +0 -1
  162. package/dist/elements/icon/__tests__/Icon.test.d.ts +0 -1
  163. package/dist/elements/input-inner-button/__tests__/InputInnerButton.test.d.ts +0 -1
  164. package/dist/elements/label/__tests__/Label.test.d.ts +0 -1
  165. package/dist/elements/loader/__tests__/Loader.test.d.ts +0 -1
  166. package/dist/hocs/with-tooltip/__tests__/with-tooltip.test.d.ts +0 -1
  167. package/dist/hooks/use-click-outside/__tests__/use-click-outside.test.d.ts +0 -1
  168. package/dist/hooks/use-element-ids/__tests__/use-element-ids.test.d.ts +0 -1
  169. package/dist/hooks/use-key-press/__tests__/use-key-press.test.d.ts +0 -1
  170. package/dist/hooks/use-modal-focus-trap/__tests__/use-modal-focus-trap.test.d.ts +0 -1
  171. package/dist/hooks/use-mount/__tests__/use-mount.test.d.ts +0 -1
  172. package/dist/hooks/use-tooltip-position/__tests__/use-tooltip-position.test.d.ts +0 -1
  173. package/dist/hooks/use-window-dimensions/__tests__/use-window-dimensions.test.d.ts +0 -1
  174. package/dist/icons/__tests__/icons.test.d.ts +0 -1
  175. package/dist/index-Dg2AZXfT.js +0 -4203
  176. package/dist/index-Dg2AZXfT.js.map +0 -1
  177. package/dist/index-OUA1cKrc.cjs +0 -993
  178. package/dist/index-OUA1cKrc.cjs.map +0 -1
  179. package/dist/utils/__tests__/get-chop-logic-theme.test.d.ts +0 -1
  180. package/dist/utils/__tests__/handle-dropdown-list-key-press.test.d.ts +0 -1
  181. package/dist/utils/__tests__/move-focus-on-element-by-id.test.d.ts +0 -1
@@ -1,4203 +0,0 @@
1
- import ye, { useDebugValue as sn, createElement as vr, useRef as $e, useContext as xe, lazy as T, Suspense as wr, useEffect as fe, useState as B, useId as Sr, useCallback as tt } from "react";
2
- import kr from "react-dom";
3
- var st = { exports: {} }, Xe = {};
4
- /**
5
- * @license React
6
- * react-jsx-runtime.production.js
7
- *
8
- * Copyright (c) Meta Platforms, Inc. and affiliates.
9
- *
10
- * This source code is licensed under the MIT license found in the
11
- * LICENSE file in the root directory of this source tree.
12
- */
13
- var an;
14
- function Cr() {
15
- if (an) return Xe;
16
- an = 1;
17
- var e = Symbol.for("react.transitional.element"), t = Symbol.for("react.fragment");
18
- function n(r, o, s) {
19
- var i = null;
20
- if (s !== void 0 && (i = "" + s), o.key !== void 0 && (i = "" + o.key), "key" in o) {
21
- s = {};
22
- for (var d in o)
23
- d !== "key" && (s[d] = o[d]);
24
- } else s = o;
25
- return o = s.ref, {
26
- $$typeof: e,
27
- type: r,
28
- key: i,
29
- ref: o !== void 0 ? o : null,
30
- props: s
31
- };
32
- }
33
- return Xe.Fragment = t, Xe.jsx = n, Xe.jsxs = n, Xe;
34
- }
35
- var Je = {};
36
- /**
37
- * @license React
38
- * react-jsx-runtime.development.js
39
- *
40
- * Copyright (c) Meta Platforms, Inc. and affiliates.
41
- *
42
- * This source code is licensed under the MIT license found in the
43
- * LICENSE file in the root directory of this source tree.
44
- */
45
- var cn;
46
- function jr() {
47
- return cn || (cn = 1, process.env.NODE_ENV !== "production" && function() {
48
- function e(a) {
49
- if (a == null) return null;
50
- if (typeof a == "function")
51
- return a.$$typeof === rt ? null : a.displayName || a.name || null;
52
- if (typeof a == "string") return a;
53
- switch (a) {
54
- case C:
55
- return "Fragment";
56
- case z:
57
- return "Portal";
58
- case D:
59
- return "Profiler";
60
- case x:
61
- return "StrictMode";
62
- case se:
63
- return "Suspense";
64
- case X:
65
- return "SuspenseList";
66
- }
67
- if (typeof a == "object")
68
- switch (typeof a.tag == "number" && console.error(
69
- "Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
70
- ), a.$$typeof) {
71
- case oe:
72
- return (a.displayName || "Context") + ".Provider";
73
- case V:
74
- return (a._context.displayName || "Context") + ".Consumer";
75
- case te:
76
- var b = a.render;
77
- return a = a.displayName, a || (a = b.displayName || b.name || "", a = a !== "" ? "ForwardRef(" + a + ")" : "ForwardRef"), a;
78
- case Ve:
79
- return b = a.displayName || null, b !== null ? b : e(a.type) || "Memo";
80
- case Ke:
81
- b = a._payload, a = a._init;
82
- try {
83
- return e(a(b));
84
- } catch {
85
- }
86
- }
87
- return null;
88
- }
89
- function t(a) {
90
- return "" + a;
91
- }
92
- function n(a) {
93
- try {
94
- t(a);
95
- var b = !1;
96
- } catch {
97
- b = !0;
98
- }
99
- if (b) {
100
- b = console;
101
- var y = b.error, R = typeof Symbol == "function" && Symbol.toStringTag && a[Symbol.toStringTag] || a.constructor.name || "Object";
102
- return y.call(
103
- b,
104
- "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
105
- R
106
- ), t(a);
107
- }
108
- }
109
- function r() {
110
- }
111
- function o() {
112
- if (ie === 0) {
113
- Se = console.log, pe = console.info, ke = console.warn, ae = console.error, ne = console.group, Oe = console.groupCollapsed, Ce = console.groupEnd;
114
- var a = {
115
- configurable: !0,
116
- enumerable: !0,
117
- value: r,
118
- writable: !0
119
- };
120
- Object.defineProperties(console, {
121
- info: a,
122
- log: a,
123
- warn: a,
124
- error: a,
125
- group: a,
126
- groupCollapsed: a,
127
- groupEnd: a
128
- });
129
- }
130
- ie++;
131
- }
132
- function s() {
133
- if (ie--, ie === 0) {
134
- var a = { configurable: !0, enumerable: !0, writable: !0 };
135
- Object.defineProperties(console, {
136
- log: K({}, a, { value: Se }),
137
- info: K({}, a, { value: pe }),
138
- warn: K({}, a, { value: ke }),
139
- error: K({}, a, { value: ae }),
140
- group: K({}, a, { value: ne }),
141
- groupCollapsed: K({}, a, { value: Oe }),
142
- groupEnd: K({}, a, { value: Ce })
143
- });
144
- }
145
- 0 > ie && console.error(
146
- "disabledDepth fell below zero. This is a bug in React. Please file an issue."
147
- );
148
- }
149
- function i(a) {
150
- if (J === void 0)
151
- try {
152
- throw Error();
153
- } catch (y) {
154
- var b = y.stack.trim().match(/\n( *(at )?)/);
155
- J = b && b[1] || "", en = -1 < y.stack.indexOf(`
156
- at`) ? " (<anonymous>)" : -1 < y.stack.indexOf("@") ? "@unknown:0:0" : "";
157
- }
158
- return `
159
- ` + J + a + en;
160
- }
161
- function d(a, b) {
162
- if (!a || zt) return "";
163
- var y = Rt.get(a);
164
- if (y !== void 0) return y;
165
- zt = !0, y = Error.prepareStackTrace, Error.prepareStackTrace = void 0;
166
- var R = null;
167
- R = H.H, H.H = null, o();
168
- try {
169
- var F = {
170
- DetermineComponentFrameRoot: function() {
171
- try {
172
- if (b) {
173
- var me = function() {
174
- throw Error();
175
- };
176
- if (Object.defineProperty(me.prototype, "props", {
177
- set: function() {
178
- throw Error();
179
- }
180
- }), typeof Reflect == "object" && Reflect.construct) {
181
- try {
182
- Reflect.construct(me, []);
183
- } catch (le) {
184
- var ot = le;
185
- }
186
- Reflect.construct(a, [], me);
187
- } else {
188
- try {
189
- me.call();
190
- } catch (le) {
191
- ot = le;
192
- }
193
- a.call(me.prototype);
194
- }
195
- } else {
196
- try {
197
- throw Error();
198
- } catch (le) {
199
- ot = le;
200
- }
201
- (me = a()) && typeof me.catch == "function" && me.catch(function() {
202
- });
203
- }
204
- } catch (le) {
205
- if (le && ot && typeof le.stack == "string")
206
- return [le.stack, ot.stack];
207
- }
208
- return [null, null];
209
- }
210
- };
211
- F.DetermineComponentFrameRoot.displayName = "DetermineComponentFrameRoot";
212
- var M = Object.getOwnPropertyDescriptor(
213
- F.DetermineComponentFrameRoot,
214
- "name"
215
- );
216
- M && M.configurable && Object.defineProperty(
217
- F.DetermineComponentFrameRoot,
218
- "name",
219
- { value: "DetermineComponentFrameRoot" }
220
- );
221
- var I = F.DetermineComponentFrameRoot(), ce = I[0], Pe = I[1];
222
- if (ce && Pe) {
223
- var G = ce.split(`
224
- `), je = Pe.split(`
225
- `);
226
- for (I = M = 0; M < G.length && !G[M].includes(
227
- "DetermineComponentFrameRoot"
228
- ); )
229
- M++;
230
- for (; I < je.length && !je[I].includes(
231
- "DetermineComponentFrameRoot"
232
- ); )
233
- I++;
234
- if (M === G.length || I === je.length)
235
- for (M = G.length - 1, I = je.length - 1; 1 <= M && 0 <= I && G[M] !== je[I]; )
236
- I--;
237
- for (; 1 <= M && 0 <= I; M--, I--)
238
- if (G[M] !== je[I]) {
239
- if (M !== 1 || I !== 1)
240
- do
241
- if (M--, I--, 0 > I || G[M] !== je[I]) {
242
- var qe = `
243
- ` + G[M].replace(
244
- " at new ",
245
- " at "
246
- );
247
- return a.displayName && qe.includes("<anonymous>") && (qe = qe.replace("<anonymous>", a.displayName)), typeof a == "function" && Rt.set(a, qe), qe;
248
- }
249
- while (1 <= M && 0 <= I);
250
- break;
251
- }
252
- }
253
- } finally {
254
- zt = !1, H.H = R, s(), Error.prepareStackTrace = y;
255
- }
256
- return G = (G = a ? a.displayName || a.name : "") ? i(G) : "", typeof a == "function" && Rt.set(a, G), G;
257
- }
258
- function l(a) {
259
- if (a == null) return "";
260
- if (typeof a == "function") {
261
- var b = a.prototype;
262
- return d(
263
- a,
264
- !(!b || !b.isReactComponent)
265
- );
266
- }
267
- if (typeof a == "string") return i(a);
268
- switch (a) {
269
- case se:
270
- return i("Suspense");
271
- case X:
272
- return i("SuspenseList");
273
- }
274
- if (typeof a == "object")
275
- switch (a.$$typeof) {
276
- case te:
277
- return a = d(a.render, !1), a;
278
- case Ve:
279
- return l(a.type);
280
- case Ke:
281
- b = a._payload, a = a._init;
282
- try {
283
- return l(a(b));
284
- } catch {
285
- }
286
- }
287
- return "";
288
- }
289
- function u() {
290
- var a = H.A;
291
- return a === null ? null : a.getOwner();
292
- }
293
- function f(a) {
294
- if (he.call(a, "key")) {
295
- var b = Object.getOwnPropertyDescriptor(a, "key").get;
296
- if (b && b.isReactWarning) return !1;
297
- }
298
- return a.key !== void 0;
299
- }
300
- function h(a, b) {
301
- function y() {
302
- tn || (tn = !0, console.error(
303
- "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
304
- b
305
- ));
306
- }
307
- y.isReactWarning = !0, Object.defineProperty(a, "key", {
308
- get: y,
309
- configurable: !0
310
- });
311
- }
312
- function m() {
313
- var a = e(this.type);
314
- return nn[a] || (nn[a] = !0, console.error(
315
- "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
316
- )), a = this.props.ref, a !== void 0 ? a : null;
317
- }
318
- function p(a, b, y, R, F, M) {
319
- return y = M.ref, a = {
320
- $$typeof: _,
321
- type: a,
322
- key: b,
323
- props: M,
324
- _owner: F
325
- }, (y !== void 0 ? y : null) !== null ? Object.defineProperty(a, "ref", {
326
- enumerable: !1,
327
- get: m
328
- }) : Object.defineProperty(a, "ref", { enumerable: !1, value: null }), a._store = {}, Object.defineProperty(a._store, "validated", {
329
- configurable: !1,
330
- enumerable: !1,
331
- writable: !0,
332
- value: 0
333
- }), Object.defineProperty(a, "_debugInfo", {
334
- configurable: !1,
335
- enumerable: !1,
336
- writable: !0,
337
- value: null
338
- }), Object.freeze && (Object.freeze(a.props), Object.freeze(a)), a;
339
- }
340
- function g(a, b, y, R, F, M) {
341
- if (typeof a == "string" || typeof a == "function" || a === C || a === D || a === x || a === se || a === X || a === _t || typeof a == "object" && a !== null && (a.$$typeof === Ke || a.$$typeof === Ve || a.$$typeof === oe || a.$$typeof === V || a.$$typeof === te || a.$$typeof === W || a.getModuleId !== void 0)) {
342
- var I = b.children;
343
- if (I !== void 0)
344
- if (R)
345
- if (we(I)) {
346
- for (R = 0; R < I.length; R++)
347
- $(I[R], a);
348
- Object.freeze && Object.freeze(I);
349
- } else
350
- console.error(
351
- "React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
352
- );
353
- else $(I, a);
354
- } else
355
- I = "", (a === void 0 || typeof a == "object" && a !== null && Object.keys(a).length === 0) && (I += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports."), a === null ? R = "null" : we(a) ? R = "array" : a !== void 0 && a.$$typeof === _ ? (R = "<" + (e(a.type) || "Unknown") + " />", I = " Did you accidentally export a JSX literal instead of a component?") : R = typeof a, console.error(
356
- "React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",
357
- R,
358
- I
359
- );
360
- if (he.call(b, "key")) {
361
- I = e(a);
362
- var ce = Object.keys(b).filter(function(G) {
363
- return G !== "key";
364
- });
365
- R = 0 < ce.length ? "{key: someKey, " + ce.join(": ..., ") + ": ...}" : "{key: someKey}", rn[I + R] || (ce = 0 < ce.length ? "{" + ce.join(": ..., ") + ": ...}" : "{}", console.error(
366
- `A props object containing a "key" prop is being spread into JSX:
367
- let props = %s;
368
- <%s {...props} />
369
- React keys must be passed directly to JSX without using spread:
370
- let props = %s;
371
- <%s key={someKey} {...props} />`,
372
- R,
373
- I,
374
- ce,
375
- I
376
- ), rn[I + R] = !0);
377
- }
378
- if (I = null, y !== void 0 && (n(y), I = "" + y), f(b) && (n(b.key), I = "" + b.key), "key" in b) {
379
- y = {};
380
- for (var Pe in b)
381
- Pe !== "key" && (y[Pe] = b[Pe]);
382
- } else y = b;
383
- return I && h(
384
- y,
385
- typeof a == "function" ? a.displayName || a.name || "Unknown" : a
386
- ), p(a, I, M, F, u(), y);
387
- }
388
- function $(a, b) {
389
- if (typeof a == "object" && a && a.$$typeof !== xr) {
390
- if (we(a))
391
- for (var y = 0; y < a.length; y++) {
392
- var R = a[y];
393
- w(R) && v(R, b);
394
- }
395
- else if (w(a))
396
- a._store && (a._store.validated = 1);
397
- else if (a === null || typeof a != "object" ? y = null : (y = Te && a[Te] || a["@@iterator"], y = typeof y == "function" ? y : null), typeof y == "function" && y !== a.entries && (y = y.call(a), y !== a))
398
- for (; !(a = y.next()).done; )
399
- w(a.value) && v(a.value, b);
400
- }
401
- }
402
- function w(a) {
403
- return typeof a == "object" && a !== null && a.$$typeof === _;
404
- }
405
- function v(a, b) {
406
- if (a._store && !a._store.validated && a.key == null && (a._store.validated = 1, b = S(b), !on[b])) {
407
- on[b] = !0;
408
- var y = "";
409
- a && a._owner != null && a._owner !== u() && (y = null, typeof a._owner.tag == "number" ? y = e(a._owner.type) : typeof a._owner.name == "string" && (y = a._owner.name), y = " It was passed a child from " + y + ".");
410
- var R = H.getCurrentStack;
411
- H.getCurrentStack = function() {
412
- var F = l(a.type);
413
- return R && (F += R() || ""), F;
414
- }, console.error(
415
- 'Each child in a list should have a unique "key" prop.%s%s See https://react.dev/link/warning-keys for more information.',
416
- b,
417
- y
418
- ), H.getCurrentStack = R;
419
- }
420
- }
421
- function S(a) {
422
- var b = "", y = u();
423
- return y && (y = e(y.type)) && (b = `
424
-
425
- Check the render method of \`` + y + "`."), b || (a = e(a)) && (b = `
426
-
427
- Check the top-level render call using <` + a + ">."), b;
428
- }
429
- var E = ye, _ = Symbol.for("react.transitional.element"), z = Symbol.for("react.portal"), C = Symbol.for("react.fragment"), x = Symbol.for("react.strict_mode"), D = Symbol.for("react.profiler"), V = Symbol.for("react.consumer"), oe = Symbol.for("react.context"), te = Symbol.for("react.forward_ref"), se = Symbol.for("react.suspense"), X = Symbol.for("react.suspense_list"), Ve = Symbol.for("react.memo"), Ke = Symbol.for("react.lazy"), _t = Symbol.for("react.offscreen"), Te = Symbol.iterator, rt = Symbol.for("react.client.reference"), H = E.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, he = Object.prototype.hasOwnProperty, K = Object.assign, W = Symbol.for("react.client.reference"), we = Array.isArray, ie = 0, Se, pe, ke, ae, ne, Oe, Ce;
430
- r.__reactDisabledLog = !0;
431
- var J, en, zt = !1, Rt = new (typeof WeakMap == "function" ? WeakMap : Map)(), xr = Symbol.for("react.client.reference"), tn, nn = {}, rn = {}, on = {};
432
- Je.Fragment = C, Je.jsx = function(a, b, y, R, F) {
433
- return g(a, b, y, !1, R, F);
434
- }, Je.jsxs = function(a, b, y, R, F) {
435
- return g(a, b, y, !0, R, F);
436
- };
437
- }()), Je;
438
- }
439
- var ln;
440
- function Er() {
441
- return ln || (ln = 1, process.env.NODE_ENV === "production" ? st.exports = Cr() : st.exports = jr()), st.exports;
442
- }
443
- var c = Er(), U = function() {
444
- return U = Object.assign || function(t) {
445
- for (var n, r = 1, o = arguments.length; r < o; r++) {
446
- n = arguments[r];
447
- for (var s in n) Object.prototype.hasOwnProperty.call(n, s) && (t[s] = n[s]);
448
- }
449
- return t;
450
- }, U.apply(this, arguments);
451
- };
452
- function Be(e, t, n) {
453
- if (n || arguments.length === 2) for (var r = 0, o = t.length, s; r < o; r++)
454
- (s || !(r in t)) && (s || (s = Array.prototype.slice.call(t, 0, r)), s[r] = t[r]);
455
- return e.concat(s || Array.prototype.slice.call(t));
456
- }
457
- function Ir(e) {
458
- var t = /* @__PURE__ */ Object.create(null);
459
- return function(n) {
460
- return t[n] === void 0 && (t[n] = e(n)), t[n];
461
- };
462
- }
463
- var Ar = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/, _r = /* @__PURE__ */ Ir(
464
- function(e) {
465
- return Ar.test(e) || e.charCodeAt(0) === 111 && e.charCodeAt(1) === 110 && e.charCodeAt(2) < 91;
466
- }
467
- /* Z+1 */
468
- ), P = "-ms-", Qe = "-moz-", O = "-webkit-", zn = "comm", xt = "rule", Ut = "decl", zr = "@import", Rn = "@keyframes", Rr = "@layer", Tn = Math.abs, Yt = String.fromCharCode, Bt = Object.assign;
469
- function Tr(e, t) {
470
- return L(e, 0) ^ 45 ? (((t << 2 ^ L(e, 0)) << 2 ^ L(e, 1)) << 2 ^ L(e, 2)) << 2 ^ L(e, 3) : 0;
471
- }
472
- function On(e) {
473
- return e.trim();
474
- }
475
- function de(e, t) {
476
- return (e = t.exec(e)) ? e[0] : e;
477
- }
478
- function A(e, t, n) {
479
- return e.replace(t, n);
480
- }
481
- function dt(e, t, n) {
482
- return e.indexOf(t, n);
483
- }
484
- function L(e, t) {
485
- return e.charCodeAt(t) | 0;
486
- }
487
- function De(e, t, n) {
488
- return e.slice(t, n);
489
- }
490
- function re(e) {
491
- return e.length;
492
- }
493
- function Pn(e) {
494
- return e.length;
495
- }
496
- function Ze(e, t) {
497
- return t.push(e), e;
498
- }
499
- function Or(e, t) {
500
- return e.map(t).join("");
501
- }
502
- function dn(e, t) {
503
- return e.filter(function(n) {
504
- return !de(n, t);
505
- });
506
- }
507
- var vt = 1, Ne = 1, Mn = 0, Q = 0, N = 0, Ge = "";
508
- function wt(e, t, n, r, o, s, i, d) {
509
- return { value: e, root: t, parent: n, type: r, props: o, children: s, line: vt, column: Ne, length: i, return: "", siblings: d };
510
- }
511
- function ge(e, t) {
512
- return Bt(wt("", null, null, "", null, null, 0, e.siblings), e, { length: -e.length }, t);
513
- }
514
- function Me(e) {
515
- for (; e.root; )
516
- e = ge(e.root, { children: [e] });
517
- Ze(e, e.siblings);
518
- }
519
- function Pr() {
520
- return N;
521
- }
522
- function Mr() {
523
- return N = Q > 0 ? L(Ge, --Q) : 0, Ne--, N === 10 && (Ne = 1, vt--), N;
524
- }
525
- function ee() {
526
- return N = Q < Mn ? L(Ge, Q++) : 0, Ne++, N === 10 && (Ne = 1, vt++), N;
527
- }
528
- function Ae() {
529
- return L(Ge, Q);
530
- }
531
- function ut() {
532
- return Q;
533
- }
534
- function St(e, t) {
535
- return De(Ge, e, t);
536
- }
537
- function Dt(e) {
538
- switch (e) {
539
- // \0 \t \n \r \s whitespace token
540
- case 0:
541
- case 9:
542
- case 10:
543
- case 13:
544
- case 32:
545
- return 5;
546
- // ! + , / > @ ~ isolate token
547
- case 33:
548
- case 43:
549
- case 44:
550
- case 47:
551
- case 62:
552
- case 64:
553
- case 126:
554
- // ; { } breakpoint token
555
- case 59:
556
- case 123:
557
- case 125:
558
- return 4;
559
- // : accompanied token
560
- case 58:
561
- return 3;
562
- // " ' ( [ opening delimit token
563
- case 34:
564
- case 39:
565
- case 40:
566
- case 91:
567
- return 2;
568
- // ) ] closing delimit token
569
- case 41:
570
- case 93:
571
- return 1;
572
- }
573
- return 0;
574
- }
575
- function Br(e) {
576
- return vt = Ne = 1, Mn = re(Ge = e), Q = 0, [];
577
- }
578
- function Dr(e) {
579
- return Ge = "", e;
580
- }
581
- function Tt(e) {
582
- return On(St(Q - 1, Nt(e === 91 ? e + 2 : e === 40 ? e + 1 : e)));
583
- }
584
- function Nr(e) {
585
- for (; (N = Ae()) && N < 33; )
586
- ee();
587
- return Dt(e) > 2 || Dt(N) > 3 ? "" : " ";
588
- }
589
- function Lr(e, t) {
590
- for (; --t && ee() && !(N < 48 || N > 102 || N > 57 && N < 65 || N > 70 && N < 97); )
591
- ;
592
- return St(e, ut() + (t < 6 && Ae() == 32 && ee() == 32));
593
- }
594
- function Nt(e) {
595
- for (; ee(); )
596
- switch (N) {
597
- // ] ) " '
598
- case e:
599
- return Q;
600
- // " '
601
- case 34:
602
- case 39:
603
- e !== 34 && e !== 39 && Nt(N);
604
- break;
605
- // (
606
- case 40:
607
- e === 41 && Nt(e);
608
- break;
609
- // \
610
- case 92:
611
- ee();
612
- break;
613
- }
614
- return Q;
615
- }
616
- function Hr(e, t) {
617
- for (; ee() && e + N !== 57; )
618
- if (e + N === 84 && Ae() === 47)
619
- break;
620
- return "/*" + St(t, Q - 1) + "*" + Yt(e === 47 ? e : ee());
621
- }
622
- function Fr(e) {
623
- for (; !Dt(Ae()); )
624
- ee();
625
- return St(e, Q);
626
- }
627
- function Gr(e) {
628
- return Dr(ft("", null, null, null, [""], e = Br(e), 0, [0], e));
629
- }
630
- function ft(e, t, n, r, o, s, i, d, l) {
631
- for (var u = 0, f = 0, h = i, m = 0, p = 0, g = 0, $ = 1, w = 1, v = 1, S = 0, E = "", _ = o, z = s, C = r, x = E; w; )
632
- switch (g = S, S = ee()) {
633
- // (
634
- case 40:
635
- if (g != 108 && L(x, h - 1) == 58) {
636
- dt(x += A(Tt(S), "&", "&\f"), "&\f", Tn(u ? d[u - 1] : 0)) != -1 && (v = -1);
637
- break;
638
- }
639
- // " ' [
640
- case 34:
641
- case 39:
642
- case 91:
643
- x += Tt(S);
644
- break;
645
- // \t \n \r \s
646
- case 9:
647
- case 10:
648
- case 13:
649
- case 32:
650
- x += Nr(g);
651
- break;
652
- // \
653
- case 92:
654
- x += Lr(ut() - 1, 7);
655
- continue;
656
- // /
657
- case 47:
658
- switch (Ae()) {
659
- case 42:
660
- case 47:
661
- Ze(Wr(Hr(ee(), ut()), t, n, l), l);
662
- break;
663
- default:
664
- x += "/";
665
- }
666
- break;
667
- // {
668
- case 123 * $:
669
- d[u++] = re(x) * v;
670
- // } ; \0
671
- case 125 * $:
672
- case 59:
673
- case 0:
674
- switch (S) {
675
- // \0 }
676
- case 0:
677
- case 125:
678
- w = 0;
679
- // ;
680
- case 59 + f:
681
- v == -1 && (x = A(x, /\f/g, "")), p > 0 && re(x) - h && Ze(p > 32 ? fn(x + ";", r, n, h - 1, l) : fn(A(x, " ", "") + ";", r, n, h - 2, l), l);
682
- break;
683
- // @ ;
684
- case 59:
685
- x += ";";
686
- // { rule/at-rule
687
- default:
688
- if (Ze(C = un(x, t, n, u, f, o, d, E, _ = [], z = [], h, s), s), S === 123)
689
- if (f === 0)
690
- ft(x, t, C, C, _, s, h, d, z);
691
- else
692
- switch (m === 99 && L(x, 3) === 110 ? 100 : m) {
693
- // d l m s
694
- case 100:
695
- case 108:
696
- case 109:
697
- case 115:
698
- ft(e, C, C, r && Ze(un(e, C, C, 0, 0, o, d, E, o, _ = [], h, z), z), o, z, h, d, r ? _ : z);
699
- break;
700
- default:
701
- ft(x, C, C, C, [""], z, 0, d, z);
702
- }
703
- }
704
- u = f = p = 0, $ = v = 1, E = x = "", h = i;
705
- break;
706
- // :
707
- case 58:
708
- h = 1 + re(x), p = g;
709
- default:
710
- if ($ < 1) {
711
- if (S == 123)
712
- --$;
713
- else if (S == 125 && $++ == 0 && Mr() == 125)
714
- continue;
715
- }
716
- switch (x += Yt(S), S * $) {
717
- // &
718
- case 38:
719
- v = f > 0 ? 1 : (x += "\f", -1);
720
- break;
721
- // ,
722
- case 44:
723
- d[u++] = (re(x) - 1) * v, v = 1;
724
- break;
725
- // @
726
- case 64:
727
- Ae() === 45 && (x += Tt(ee())), m = Ae(), f = h = re(E = x += Fr(ut())), S++;
728
- break;
729
- // -
730
- case 45:
731
- g === 45 && re(x) == 2 && ($ = 0);
732
- }
733
- }
734
- return s;
735
- }
736
- function un(e, t, n, r, o, s, i, d, l, u, f, h) {
737
- for (var m = o - 1, p = o === 0 ? s : [""], g = Pn(p), $ = 0, w = 0, v = 0; $ < r; ++$)
738
- for (var S = 0, E = De(e, m + 1, m = Tn(w = i[$])), _ = e; S < g; ++S)
739
- (_ = On(w > 0 ? p[S] + " " + E : A(E, /&\f/g, p[S]))) && (l[v++] = _);
740
- return wt(e, t, n, o === 0 ? xt : d, l, u, f, h);
741
- }
742
- function Wr(e, t, n, r) {
743
- return wt(e, t, n, zn, Yt(Pr()), De(e, 2, -2), 0, r);
744
- }
745
- function fn(e, t, n, r, o) {
746
- return wt(e, t, n, Ut, De(e, 0, r), De(e, r + 1, -1), r, o);
747
- }
748
- function Bn(e, t, n) {
749
- switch (Tr(e, t)) {
750
- // color-adjust
751
- case 5103:
752
- return O + "print-" + e + e;
753
- // animation, animation-(delay|direction|duration|fill-mode|iteration-count|name|play-state|timing-function)
754
- case 5737:
755
- case 4201:
756
- case 3177:
757
- case 3433:
758
- case 1641:
759
- case 4457:
760
- case 2921:
761
- // text-decoration, filter, clip-path, backface-visibility, column, box-decoration-break
762
- case 5572:
763
- case 6356:
764
- case 5844:
765
- case 3191:
766
- case 6645:
767
- case 3005:
768
- // mask, mask-image, mask-(mode|clip|size), mask-(repeat|origin), mask-position, mask-composite,
769
- case 6391:
770
- case 5879:
771
- case 5623:
772
- case 6135:
773
- case 4599:
774
- case 4855:
775
- // background-clip, columns, column-(count|fill|gap|rule|rule-color|rule-style|rule-width|span|width)
776
- case 4215:
777
- case 6389:
778
- case 5109:
779
- case 5365:
780
- case 5621:
781
- case 3829:
782
- return O + e + e;
783
- // tab-size
784
- case 4789:
785
- return Qe + e + e;
786
- // appearance, user-select, transform, hyphens, text-size-adjust
787
- case 5349:
788
- case 4246:
789
- case 4810:
790
- case 6968:
791
- case 2756:
792
- return O + e + Qe + e + P + e + e;
793
- // writing-mode
794
- case 5936:
795
- switch (L(e, t + 11)) {
796
- // vertical-l(r)
797
- case 114:
798
- return O + e + P + A(e, /[svh]\w+-[tblr]{2}/, "tb") + e;
799
- // vertical-r(l)
800
- case 108:
801
- return O + e + P + A(e, /[svh]\w+-[tblr]{2}/, "tb-rl") + e;
802
- // horizontal(-)tb
803
- case 45:
804
- return O + e + P + A(e, /[svh]\w+-[tblr]{2}/, "lr") + e;
805
- }
806
- // flex, flex-direction, scroll-snap-type, writing-mode
807
- case 6828:
808
- case 4268:
809
- case 2903:
810
- return O + e + P + e + e;
811
- // order
812
- case 6165:
813
- return O + e + P + "flex-" + e + e;
814
- // align-items
815
- case 5187:
816
- return O + e + A(e, /(\w+).+(:[^]+)/, O + "box-$1$2" + P + "flex-$1$2") + e;
817
- // align-self
818
- case 5443:
819
- return O + e + P + "flex-item-" + A(e, /flex-|-self/g, "") + (de(e, /flex-|baseline/) ? "" : P + "grid-row-" + A(e, /flex-|-self/g, "")) + e;
820
- // align-content
821
- case 4675:
822
- return O + e + P + "flex-line-pack" + A(e, /align-content|flex-|-self/g, "") + e;
823
- // flex-shrink
824
- case 5548:
825
- return O + e + P + A(e, "shrink", "negative") + e;
826
- // flex-basis
827
- case 5292:
828
- return O + e + P + A(e, "basis", "preferred-size") + e;
829
- // flex-grow
830
- case 6060:
831
- return O + "box-" + A(e, "-grow", "") + O + e + P + A(e, "grow", "positive") + e;
832
- // transition
833
- case 4554:
834
- return O + A(e, /([^-])(transform)/g, "$1" + O + "$2") + e;
835
- // cursor
836
- case 6187:
837
- return A(A(A(e, /(zoom-|grab)/, O + "$1"), /(image-set)/, O + "$1"), e, "") + e;
838
- // background, background-image
839
- case 5495:
840
- case 3959:
841
- return A(e, /(image-set\([^]*)/, O + "$1$`$1");
842
- // justify-content
843
- case 4968:
844
- return A(A(e, /(.+:)(flex-)?(.*)/, O + "box-pack:$3" + P + "flex-pack:$3"), /s.+-b[^;]+/, "justify") + O + e + e;
845
- // justify-self
846
- case 4200:
847
- if (!de(e, /flex-|baseline/)) return P + "grid-column-align" + De(e, t) + e;
848
- break;
849
- // grid-template-(columns|rows)
850
- case 2592:
851
- case 3360:
852
- return P + A(e, "template-", "") + e;
853
- // grid-(row|column)-start
854
- case 4384:
855
- case 3616:
856
- return n && n.some(function(r, o) {
857
- return t = o, de(r.props, /grid-\w+-end/);
858
- }) ? ~dt(e + (n = n[t].value), "span", 0) ? e : P + A(e, "-start", "") + e + P + "grid-row-span:" + (~dt(n, "span", 0) ? de(n, /\d+/) : +de(n, /\d+/) - +de(e, /\d+/)) + ";" : P + A(e, "-start", "") + e;
859
- // grid-(row|column)-end
860
- case 4896:
861
- case 4128:
862
- return n && n.some(function(r) {
863
- return de(r.props, /grid-\w+-start/);
864
- }) ? e : P + A(A(e, "-end", "-span"), "span ", "") + e;
865
- // (margin|padding)-inline-(start|end)
866
- case 4095:
867
- case 3583:
868
- case 4068:
869
- case 2532:
870
- return A(e, /(.+)-inline(.+)/, O + "$1$2") + e;
871
- // (min|max)?(width|height|inline-size|block-size)
872
- case 8116:
873
- case 7059:
874
- case 5753:
875
- case 5535:
876
- case 5445:
877
- case 5701:
878
- case 4933:
879
- case 4677:
880
- case 5533:
881
- case 5789:
882
- case 5021:
883
- case 4765:
884
- if (re(e) - 1 - t > 6)
885
- switch (L(e, t + 1)) {
886
- // (m)ax-content, (m)in-content
887
- case 109:
888
- if (L(e, t + 4) !== 45)
889
- break;
890
- // (f)ill-available, (f)it-content
891
- case 102:
892
- return A(e, /(.+:)(.+)-([^]+)/, "$1" + O + "$2-$3$1" + Qe + (L(e, t + 3) == 108 ? "$3" : "$2-$3")) + e;
893
- // (s)tretch
894
- case 115:
895
- return ~dt(e, "stretch", 0) ? Bn(A(e, "stretch", "fill-available"), t, n) + e : e;
896
- }
897
- break;
898
- // grid-(column|row)
899
- case 5152:
900
- case 5920:
901
- return A(e, /(.+?):(\d+)(\s*\/\s*(span)?\s*(\d+))?(.*)/, function(r, o, s, i, d, l, u) {
902
- return P + o + ":" + s + u + (i ? P + o + "-span:" + (d ? l : +l - +s) + u : "") + e;
903
- });
904
- // position: sticky
905
- case 4949:
906
- if (L(e, t + 6) === 121)
907
- return A(e, ":", ":" + O) + e;
908
- break;
909
- // display: (flex|inline-flex|grid|inline-grid)
910
- case 6444:
911
- switch (L(e, L(e, 14) === 45 ? 18 : 11)) {
912
- // (inline-)?fle(x)
913
- case 120:
914
- return A(e, /(.+:)([^;\s!]+)(;|(\s+)?!.+)?/, "$1" + O + (L(e, 14) === 45 ? "inline-" : "") + "box$3$1" + O + "$2$3$1" + P + "$2box$3") + e;
915
- // (inline-)?gri(d)
916
- case 100:
917
- return A(e, ":", ":" + P) + e;
918
- }
919
- break;
920
- // scroll-margin, scroll-margin-(top|right|bottom|left)
921
- case 5719:
922
- case 2647:
923
- case 2135:
924
- case 3927:
925
- case 2391:
926
- return A(e, "scroll-", "scroll-snap-") + e;
927
- }
928
- return e;
929
- }
930
- function mt(e, t) {
931
- for (var n = "", r = 0; r < e.length; r++)
932
- n += t(e[r], r, e, t) || "";
933
- return n;
934
- }
935
- function Ur(e, t, n, r) {
936
- switch (e.type) {
937
- case Rr:
938
- if (e.children.length) break;
939
- case zr:
940
- case Ut:
941
- return e.return = e.return || e.value;
942
- case zn:
943
- return "";
944
- case Rn:
945
- return e.return = e.value + "{" + mt(e.children, r) + "}";
946
- case xt:
947
- if (!re(e.value = e.props.join(","))) return "";
948
- }
949
- return re(n = mt(e.children, r)) ? e.return = e.value + "{" + n + "}" : "";
950
- }
951
- function Yr(e) {
952
- var t = Pn(e);
953
- return function(n, r, o, s) {
954
- for (var i = "", d = 0; d < t; d++)
955
- i += e[d](n, r, o, s) || "";
956
- return i;
957
- };
958
- }
959
- function Vr(e) {
960
- return function(t) {
961
- t.root || (t = t.return) && e(t);
962
- };
963
- }
964
- function Kr(e, t, n, r) {
965
- if (e.length > -1 && !e.return)
966
- switch (e.type) {
967
- case Ut:
968
- e.return = Bn(e.value, e.length, n);
969
- return;
970
- case Rn:
971
- return mt([ge(e, { value: A(e.value, "@", "@" + O) })], r);
972
- case xt:
973
- if (e.length)
974
- return Or(n = e.props, function(o) {
975
- switch (de(o, r = /(::plac\w+|:read-\w+)/)) {
976
- // :read-(only|write)
977
- case ":read-only":
978
- case ":read-write":
979
- Me(ge(e, { props: [A(o, /:(read-\w+)/, ":" + Qe + "$1")] })), Me(ge(e, { props: [o] })), Bt(e, { props: dn(n, r) });
980
- break;
981
- // :placeholder
982
- case "::placeholder":
983
- Me(ge(e, { props: [A(o, /:(plac\w+)/, ":" + O + "input-$1")] })), Me(ge(e, { props: [A(o, /:(plac\w+)/, ":" + Qe + "$1")] })), Me(ge(e, { props: [A(o, /:(plac\w+)/, P + "input-$1")] })), Me(ge(e, { props: [o] })), Bt(e, { props: dn(n, r) });
984
- break;
985
- }
986
- return "";
987
- });
988
- }
989
- }
990
- var qr = {
991
- animationIterationCount: 1,
992
- aspectRatio: 1,
993
- borderImageOutset: 1,
994
- borderImageSlice: 1,
995
- borderImageWidth: 1,
996
- boxFlex: 1,
997
- boxFlexGroup: 1,
998
- boxOrdinalGroup: 1,
999
- columnCount: 1,
1000
- columns: 1,
1001
- flex: 1,
1002
- flexGrow: 1,
1003
- flexPositive: 1,
1004
- flexShrink: 1,
1005
- flexNegative: 1,
1006
- flexOrder: 1,
1007
- gridRow: 1,
1008
- gridRowEnd: 1,
1009
- gridRowSpan: 1,
1010
- gridRowStart: 1,
1011
- gridColumn: 1,
1012
- gridColumnEnd: 1,
1013
- gridColumnSpan: 1,
1014
- gridColumnStart: 1,
1015
- msGridRow: 1,
1016
- msGridRowSpan: 1,
1017
- msGridColumn: 1,
1018
- msGridColumnSpan: 1,
1019
- fontWeight: 1,
1020
- lineHeight: 1,
1021
- opacity: 1,
1022
- order: 1,
1023
- orphans: 1,
1024
- tabSize: 1,
1025
- widows: 1,
1026
- zIndex: 1,
1027
- zoom: 1,
1028
- WebkitLineClamp: 1,
1029
- // SVG-related properties
1030
- fillOpacity: 1,
1031
- floodOpacity: 1,
1032
- stopOpacity: 1,
1033
- strokeDasharray: 1,
1034
- strokeDashoffset: 1,
1035
- strokeMiterlimit: 1,
1036
- strokeOpacity: 1,
1037
- strokeWidth: 1
1038
- }, ze = typeof process < "u" && process.env !== void 0 && (process.env.REACT_APP_SC_ATTR || process.env.SC_ATTR) || "data-styled", Dn = "active", Nn = "data-styled-version", kt = "6.1.14", Vt = `/*!sc*/
1039
- `, gt = typeof window < "u" && "HTMLElement" in window, Xr = !!(typeof SC_DISABLE_SPEEDY == "boolean" ? SC_DISABLE_SPEEDY : typeof process < "u" && process.env !== void 0 && process.env.REACT_APP_SC_DISABLE_SPEEDY !== void 0 && process.env.REACT_APP_SC_DISABLE_SPEEDY !== "" ? process.env.REACT_APP_SC_DISABLE_SPEEDY !== "false" && process.env.REACT_APP_SC_DISABLE_SPEEDY : typeof process < "u" && process.env !== void 0 && process.env.SC_DISABLE_SPEEDY !== void 0 && process.env.SC_DISABLE_SPEEDY !== "" ? process.env.SC_DISABLE_SPEEDY !== "false" && process.env.SC_DISABLE_SPEEDY : process.env.NODE_ENV !== "production"), hn = /invalid hook call/i, it = /* @__PURE__ */ new Set(), Jr = function(e, t) {
1040
- if (process.env.NODE_ENV !== "production") {
1041
- var n = t ? ' with the id of "'.concat(t, '"') : "", r = "The component ".concat(e).concat(n, ` has been created dynamically.
1042
- `) + `You may see this warning because you've called styled inside another component.
1043
- To resolve this only create new StyledComponents outside of any render method and function component.`, o = console.error;
1044
- try {
1045
- var s = !0;
1046
- console.error = function(i) {
1047
- for (var d = [], l = 1; l < arguments.length; l++) d[l - 1] = arguments[l];
1048
- hn.test(i) ? (s = !1, it.delete(r)) : o.apply(void 0, Be([i], d, !1));
1049
- }, $e(), s && !it.has(r) && (console.warn(r), it.add(r));
1050
- } catch (i) {
1051
- hn.test(i.message) && it.delete(r);
1052
- } finally {
1053
- console.error = o;
1054
- }
1055
- }
1056
- }, Ct = Object.freeze([]), Le = Object.freeze({});
1057
- function Zr(e, t, n) {
1058
- return n === void 0 && (n = Le), e.theme !== n.theme && e.theme || t || n.theme;
1059
- }
1060
- var Lt = /* @__PURE__ */ new Set(["a", "abbr", "address", "area", "article", "aside", "audio", "b", "base", "bdi", "bdo", "big", "blockquote", "body", "br", "button", "canvas", "caption", "cite", "code", "col", "colgroup", "data", "datalist", "dd", "del", "details", "dfn", "dialog", "div", "dl", "dt", "em", "embed", "fieldset", "figcaption", "figure", "footer", "form", "h1", "h2", "h3", "h4", "h5", "h6", "header", "hgroup", "hr", "html", "i", "iframe", "img", "input", "ins", "kbd", "keygen", "label", "legend", "li", "link", "main", "map", "mark", "menu", "menuitem", "meta", "meter", "nav", "noscript", "object", "ol", "optgroup", "option", "output", "p", "param", "picture", "pre", "progress", "q", "rp", "rt", "ruby", "s", "samp", "script", "section", "select", "small", "source", "span", "strong", "style", "sub", "summary", "sup", "table", "tbody", "td", "textarea", "tfoot", "th", "thead", "time", "tr", "track", "u", "ul", "use", "var", "video", "wbr", "circle", "clipPath", "defs", "ellipse", "foreignObject", "g", "image", "line", "linearGradient", "marker", "mask", "path", "pattern", "polygon", "polyline", "radialGradient", "rect", "stop", "svg", "text", "tspan"]), Qr = /[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g, eo = /(^-|-$)/g;
1061
- function pn(e) {
1062
- return e.replace(Qr, "-").replace(eo, "");
1063
- }
1064
- var to = /(a)(d)/gi, at = 52, mn = function(e) {
1065
- return String.fromCharCode(e + (e > 25 ? 39 : 97));
1066
- };
1067
- function Ht(e) {
1068
- var t, n = "";
1069
- for (t = Math.abs(e); t > at; t = t / at | 0) n = mn(t % at) + n;
1070
- return (mn(t % at) + n).replace(to, "$1-$2");
1071
- }
1072
- var Ot, Ln = 5381, Ee = function(e, t) {
1073
- for (var n = t.length; n; ) e = 33 * e ^ t.charCodeAt(--n);
1074
- return e;
1075
- }, Hn = function(e) {
1076
- return Ee(Ln, e);
1077
- };
1078
- function no(e) {
1079
- return Ht(Hn(e) >>> 0);
1080
- }
1081
- function Fn(e) {
1082
- return process.env.NODE_ENV !== "production" && typeof e == "string" && e || e.displayName || e.name || "Component";
1083
- }
1084
- function Pt(e) {
1085
- return typeof e == "string" && (process.env.NODE_ENV === "production" || e.charAt(0) === e.charAt(0).toLowerCase());
1086
- }
1087
- var Gn = typeof Symbol == "function" && Symbol.for, Wn = Gn ? Symbol.for("react.memo") : 60115, ro = Gn ? Symbol.for("react.forward_ref") : 60112, oo = { childContextTypes: !0, contextType: !0, contextTypes: !0, defaultProps: !0, displayName: !0, getDefaultProps: !0, getDerivedStateFromError: !0, getDerivedStateFromProps: !0, mixins: !0, propTypes: !0, type: !0 }, so = { name: !0, length: !0, prototype: !0, caller: !0, callee: !0, arguments: !0, arity: !0 }, Un = { $$typeof: !0, compare: !0, defaultProps: !0, displayName: !0, propTypes: !0, type: !0 }, io = ((Ot = {})[ro] = { $$typeof: !0, render: !0, defaultProps: !0, displayName: !0, propTypes: !0 }, Ot[Wn] = Un, Ot);
1088
- function gn(e) {
1089
- return ("type" in (t = e) && t.type.$$typeof) === Wn ? Un : "$$typeof" in e ? io[e.$$typeof] : oo;
1090
- var t;
1091
- }
1092
- var ao = Object.defineProperty, co = Object.getOwnPropertyNames, bn = Object.getOwnPropertySymbols, lo = Object.getOwnPropertyDescriptor, uo = Object.getPrototypeOf, yn = Object.prototype;
1093
- function Yn(e, t, n) {
1094
- if (typeof t != "string") {
1095
- if (yn) {
1096
- var r = uo(t);
1097
- r && r !== yn && Yn(e, r, n);
1098
- }
1099
- var o = co(t);
1100
- bn && (o = o.concat(bn(t)));
1101
- for (var s = gn(e), i = gn(t), d = 0; d < o.length; ++d) {
1102
- var l = o[d];
1103
- if (!(l in so || n && n[l] || i && l in i || s && l in s)) {
1104
- var u = lo(t, l);
1105
- try {
1106
- ao(e, l, u);
1107
- } catch {
1108
- }
1109
- }
1110
- }
1111
- }
1112
- return e;
1113
- }
1114
- function He(e) {
1115
- return typeof e == "function";
1116
- }
1117
- function Kt(e) {
1118
- return typeof e == "object" && "styledComponentId" in e;
1119
- }
1120
- function Ie(e, t) {
1121
- return e && t ? "".concat(e, " ").concat(t) : e || t || "";
1122
- }
1123
- function $n(e, t) {
1124
- if (e.length === 0) return "";
1125
- for (var n = e[0], r = 1; r < e.length; r++) n += e[r];
1126
- return n;
1127
- }
1128
- function Fe(e) {
1129
- return e !== null && typeof e == "object" && e.constructor.name === Object.name && !("props" in e && e.$$typeof);
1130
- }
1131
- function Ft(e, t, n) {
1132
- if (n === void 0 && (n = !1), !n && !Fe(e) && !Array.isArray(e)) return t;
1133
- if (Array.isArray(t)) for (var r = 0; r < t.length; r++) e[r] = Ft(e[r], t[r]);
1134
- else if (Fe(t)) for (var r in t) e[r] = Ft(e[r], t[r]);
1135
- return e;
1136
- }
1137
- function qt(e, t) {
1138
- Object.defineProperty(e, "toString", { value: t });
1139
- }
1140
- var fo = process.env.NODE_ENV !== "production" ? { 1: `Cannot create styled-component for component: %s.
1141
-
1142
- `, 2: `Can't collect styles once you've consumed a \`ServerStyleSheet\`'s styles! \`ServerStyleSheet\` is a one off instance for each server-side render cycle.
1143
-
1144
- - Are you trying to reuse it across renders?
1145
- - Are you accidentally calling collectStyles twice?
1146
-
1147
- `, 3: `Streaming SSR is only supported in a Node.js environment; Please do not try to call this method in the browser.
1148
-
1149
- `, 4: `The \`StyleSheetManager\` expects a valid target or sheet prop!
1150
-
1151
- - Does this error occur on the client and is your target falsy?
1152
- - Does this error occur on the server and is the sheet falsy?
1153
-
1154
- `, 5: `The clone method cannot be used on the client!
1155
-
1156
- - Are you running in a client-like environment on the server?
1157
- - Are you trying to run SSR on the client?
1158
-
1159
- `, 6: `Trying to insert a new style tag, but the given Node is unmounted!
1160
-
1161
- - Are you using a custom target that isn't mounted?
1162
- - Does your document not have a valid head element?
1163
- - Have you accidentally removed a style tag manually?
1164
-
1165
- `, 7: 'ThemeProvider: Please return an object from your "theme" prop function, e.g.\n\n```js\ntheme={() => ({})}\n```\n\n', 8: `ThemeProvider: Please make your "theme" prop an object.
1166
-
1167
- `, 9: "Missing document `<head>`\n\n", 10: `Cannot find a StyleSheet instance. Usually this happens if there are multiple copies of styled-components loaded at once. Check out this issue for how to troubleshoot and fix the common cases where this situation can happen: https://github.com/styled-components/styled-components/issues/1941#issuecomment-417862021
1168
-
1169
- `, 11: `_This error was replaced with a dev-time warning, it will be deleted for v4 final._ [createGlobalStyle] received children which will not be rendered. Please use the component without passing children elements.
1170
-
1171
- `, 12: "It seems you are interpolating a keyframe declaration (%s) into an untagged string. This was supported in styled-components v3, but is not longer supported in v4 as keyframes are now injected on-demand. Please wrap your string in the css\\`\\` helper which ensures the styles are injected correctly. See https://www.styled-components.com/docs/api#css\n\n", 13: `%s is not a styled component and cannot be referred to via component selector. See https://www.styled-components.com/docs/advanced#referring-to-other-components for more details.
1172
-
1173
- `, 14: `ThemeProvider: "theme" prop is required.
1174
-
1175
- `, 15: "A stylis plugin has been supplied that is not named. We need a name for each plugin to be able to prevent styling collisions between different stylis configurations within the same app. Before you pass your plugin to `<StyleSheetManager stylisPlugins={[]}>`, please make sure each plugin is uniquely-named, e.g.\n\n```js\nObject.defineProperty(importedPlugin, 'name', { value: 'some-unique-name' });\n```\n\n", 16: `Reached the limit of how many styled components may be created at group %s.
1176
- You may only create up to 1,073,741,824 components. If you're creating components dynamically,
1177
- as for instance in your render method then you may be running into this limitation.
1178
-
1179
- `, 17: `CSSStyleSheet could not be found on HTMLStyleElement.
1180
- Has styled-components' style tag been unmounted or altered by another script?
1181
- `, 18: "ThemeProvider: Please make sure your useTheme hook is within a `<ThemeProvider>`" } : {};
1182
- function ho() {
1183
- for (var e = [], t = 0; t < arguments.length; t++) e[t] = arguments[t];
1184
- for (var n = e[0], r = [], o = 1, s = e.length; o < s; o += 1) r.push(e[o]);
1185
- return r.forEach(function(i) {
1186
- n = n.replace(/%[a-z]/, i);
1187
- }), n;
1188
- }
1189
- function We(e) {
1190
- for (var t = [], n = 1; n < arguments.length; n++) t[n - 1] = arguments[n];
1191
- return process.env.NODE_ENV === "production" ? new Error("An error occurred. See https://github.com/styled-components/styled-components/blob/main/packages/styled-components/src/utils/errors.md#".concat(e, " for more information.").concat(t.length > 0 ? " Args: ".concat(t.join(", ")) : "")) : new Error(ho.apply(void 0, Be([fo[e]], t, !1)).trim());
1192
- }
1193
- var po = function() {
1194
- function e(t) {
1195
- this.groupSizes = new Uint32Array(512), this.length = 512, this.tag = t;
1196
- }
1197
- return e.prototype.indexOfGroup = function(t) {
1198
- for (var n = 0, r = 0; r < t; r++) n += this.groupSizes[r];
1199
- return n;
1200
- }, e.prototype.insertRules = function(t, n) {
1201
- if (t >= this.groupSizes.length) {
1202
- for (var r = this.groupSizes, o = r.length, s = o; t >= s; ) if ((s <<= 1) < 0) throw We(16, "".concat(t));
1203
- this.groupSizes = new Uint32Array(s), this.groupSizes.set(r), this.length = s;
1204
- for (var i = o; i < s; i++) this.groupSizes[i] = 0;
1205
- }
1206
- for (var d = this.indexOfGroup(t + 1), l = (i = 0, n.length); i < l; i++) this.tag.insertRule(d, n[i]) && (this.groupSizes[t]++, d++);
1207
- }, e.prototype.clearGroup = function(t) {
1208
- if (t < this.length) {
1209
- var n = this.groupSizes[t], r = this.indexOfGroup(t), o = r + n;
1210
- this.groupSizes[t] = 0;
1211
- for (var s = r; s < o; s++) this.tag.deleteRule(r);
1212
- }
1213
- }, e.prototype.getGroup = function(t) {
1214
- var n = "";
1215
- if (t >= this.length || this.groupSizes[t] === 0) return n;
1216
- for (var r = this.groupSizes[t], o = this.indexOfGroup(t), s = o + r, i = o; i < s; i++) n += "".concat(this.tag.getRule(i)).concat(Vt);
1217
- return n;
1218
- }, e;
1219
- }(), mo = 1 << 30, ht = /* @__PURE__ */ new Map(), bt = /* @__PURE__ */ new Map(), pt = 1, ct = function(e) {
1220
- if (ht.has(e)) return ht.get(e);
1221
- for (; bt.has(pt); ) pt++;
1222
- var t = pt++;
1223
- if (process.env.NODE_ENV !== "production" && ((0 | t) < 0 || t > mo)) throw We(16, "".concat(t));
1224
- return ht.set(e, t), bt.set(t, e), t;
1225
- }, go = function(e, t) {
1226
- pt = t + 1, ht.set(e, t), bt.set(t, e);
1227
- }, bo = "style[".concat(ze, "][").concat(Nn, '="').concat(kt, '"]'), yo = new RegExp("^".concat(ze, '\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)')), $o = function(e, t, n) {
1228
- for (var r, o = n.split(","), s = 0, i = o.length; s < i; s++) (r = o[s]) && e.registerName(t, r);
1229
- }, xo = function(e, t) {
1230
- for (var n, r = ((n = t.textContent) !== null && n !== void 0 ? n : "").split(Vt), o = [], s = 0, i = r.length; s < i; s++) {
1231
- var d = r[s].trim();
1232
- if (d) {
1233
- var l = d.match(yo);
1234
- if (l) {
1235
- var u = 0 | parseInt(l[1], 10), f = l[2];
1236
- u !== 0 && (go(f, u), $o(e, f, l[3]), e.getTag().insertRules(u, o)), o.length = 0;
1237
- } else o.push(d);
1238
- }
1239
- }
1240
- }, xn = function(e) {
1241
- for (var t = document.querySelectorAll(bo), n = 0, r = t.length; n < r; n++) {
1242
- var o = t[n];
1243
- o && o.getAttribute(ze) !== Dn && (xo(e, o), o.parentNode && o.parentNode.removeChild(o));
1244
- }
1245
- };
1246
- function vo() {
1247
- return typeof __webpack_nonce__ < "u" ? __webpack_nonce__ : null;
1248
- }
1249
- var Vn = function(e) {
1250
- var t = document.head, n = e || t, r = document.createElement("style"), o = function(d) {
1251
- var l = Array.from(d.querySelectorAll("style[".concat(ze, "]")));
1252
- return l[l.length - 1];
1253
- }(n), s = o !== void 0 ? o.nextSibling : null;
1254
- r.setAttribute(ze, Dn), r.setAttribute(Nn, kt);
1255
- var i = vo();
1256
- return i && r.setAttribute("nonce", i), n.insertBefore(r, s), r;
1257
- }, wo = function() {
1258
- function e(t) {
1259
- this.element = Vn(t), this.element.appendChild(document.createTextNode("")), this.sheet = function(n) {
1260
- if (n.sheet) return n.sheet;
1261
- for (var r = document.styleSheets, o = 0, s = r.length; o < s; o++) {
1262
- var i = r[o];
1263
- if (i.ownerNode === n) return i;
1264
- }
1265
- throw We(17);
1266
- }(this.element), this.length = 0;
1267
- }
1268
- return e.prototype.insertRule = function(t, n) {
1269
- try {
1270
- return this.sheet.insertRule(n, t), this.length++, !0;
1271
- } catch {
1272
- return !1;
1273
- }
1274
- }, e.prototype.deleteRule = function(t) {
1275
- this.sheet.deleteRule(t), this.length--;
1276
- }, e.prototype.getRule = function(t) {
1277
- var n = this.sheet.cssRules[t];
1278
- return n && n.cssText ? n.cssText : "";
1279
- }, e;
1280
- }(), So = function() {
1281
- function e(t) {
1282
- this.element = Vn(t), this.nodes = this.element.childNodes, this.length = 0;
1283
- }
1284
- return e.prototype.insertRule = function(t, n) {
1285
- if (t <= this.length && t >= 0) {
1286
- var r = document.createTextNode(n);
1287
- return this.element.insertBefore(r, this.nodes[t] || null), this.length++, !0;
1288
- }
1289
- return !1;
1290
- }, e.prototype.deleteRule = function(t) {
1291
- this.element.removeChild(this.nodes[t]), this.length--;
1292
- }, e.prototype.getRule = function(t) {
1293
- return t < this.length ? this.nodes[t].textContent : "";
1294
- }, e;
1295
- }(), ko = function() {
1296
- function e(t) {
1297
- this.rules = [], this.length = 0;
1298
- }
1299
- return e.prototype.insertRule = function(t, n) {
1300
- return t <= this.length && (this.rules.splice(t, 0, n), this.length++, !0);
1301
- }, e.prototype.deleteRule = function(t) {
1302
- this.rules.splice(t, 1), this.length--;
1303
- }, e.prototype.getRule = function(t) {
1304
- return t < this.length ? this.rules[t] : "";
1305
- }, e;
1306
- }(), vn = gt, Co = { isServer: !gt, useCSSOMInjection: !Xr }, Kn = function() {
1307
- function e(t, n, r) {
1308
- t === void 0 && (t = Le), n === void 0 && (n = {});
1309
- var o = this;
1310
- this.options = U(U({}, Co), t), this.gs = n, this.names = new Map(r), this.server = !!t.isServer, !this.server && gt && vn && (vn = !1, xn(this)), qt(this, function() {
1311
- return function(s) {
1312
- for (var i = s.getTag(), d = i.length, l = "", u = function(h) {
1313
- var m = function(v) {
1314
- return bt.get(v);
1315
- }(h);
1316
- if (m === void 0) return "continue";
1317
- var p = s.names.get(m), g = i.getGroup(h);
1318
- if (p === void 0 || !p.size || g.length === 0) return "continue";
1319
- var $ = "".concat(ze, ".g").concat(h, '[id="').concat(m, '"]'), w = "";
1320
- p !== void 0 && p.forEach(function(v) {
1321
- v.length > 0 && (w += "".concat(v, ","));
1322
- }), l += "".concat(g).concat($, '{content:"').concat(w, '"}').concat(Vt);
1323
- }, f = 0; f < d; f++) u(f);
1324
- return l;
1325
- }(o);
1326
- });
1327
- }
1328
- return e.registerId = function(t) {
1329
- return ct(t);
1330
- }, e.prototype.rehydrate = function() {
1331
- !this.server && gt && xn(this);
1332
- }, e.prototype.reconstructWithOptions = function(t, n) {
1333
- return n === void 0 && (n = !0), new e(U(U({}, this.options), t), this.gs, n && this.names || void 0);
1334
- }, e.prototype.allocateGSInstance = function(t) {
1335
- return this.gs[t] = (this.gs[t] || 0) + 1;
1336
- }, e.prototype.getTag = function() {
1337
- return this.tag || (this.tag = (t = function(n) {
1338
- var r = n.useCSSOMInjection, o = n.target;
1339
- return n.isServer ? new ko(o) : r ? new wo(o) : new So(o);
1340
- }(this.options), new po(t)));
1341
- var t;
1342
- }, e.prototype.hasNameForId = function(t, n) {
1343
- return this.names.has(t) && this.names.get(t).has(n);
1344
- }, e.prototype.registerName = function(t, n) {
1345
- if (ct(t), this.names.has(t)) this.names.get(t).add(n);
1346
- else {
1347
- var r = /* @__PURE__ */ new Set();
1348
- r.add(n), this.names.set(t, r);
1349
- }
1350
- }, e.prototype.insertRules = function(t, n, r) {
1351
- this.registerName(t, n), this.getTag().insertRules(ct(t), r);
1352
- }, e.prototype.clearNames = function(t) {
1353
- this.names.has(t) && this.names.get(t).clear();
1354
- }, e.prototype.clearRules = function(t) {
1355
- this.getTag().clearGroup(ct(t)), this.clearNames(t);
1356
- }, e.prototype.clearTag = function() {
1357
- this.tag = void 0;
1358
- }, e;
1359
- }(), jo = /&/g, Eo = /^\s*\/\/.*$/gm;
1360
- function qn(e, t) {
1361
- return e.map(function(n) {
1362
- return n.type === "rule" && (n.value = "".concat(t, " ").concat(n.value), n.value = n.value.replaceAll(",", ",".concat(t, " ")), n.props = n.props.map(function(r) {
1363
- return "".concat(t, " ").concat(r);
1364
- })), Array.isArray(n.children) && n.type !== "@keyframes" && (n.children = qn(n.children, t)), n;
1365
- });
1366
- }
1367
- function Io(e) {
1368
- var t, n, r, o = Le, s = o.options, i = s === void 0 ? Le : s, d = o.plugins, l = d === void 0 ? Ct : d, u = function(m, p, g) {
1369
- return g.startsWith(n) && g.endsWith(n) && g.replaceAll(n, "").length > 0 ? ".".concat(t) : m;
1370
- }, f = l.slice();
1371
- f.push(function(m) {
1372
- m.type === xt && m.value.includes("&") && (m.props[0] = m.props[0].replace(jo, n).replace(r, u));
1373
- }), i.prefix && f.push(Kr), f.push(Ur);
1374
- var h = function(m, p, g, $) {
1375
- p === void 0 && (p = ""), g === void 0 && (g = ""), $ === void 0 && ($ = "&"), t = $, n = p, r = new RegExp("\\".concat(n, "\\b"), "g");
1376
- var w = m.replace(Eo, ""), v = Gr(g || p ? "".concat(g, " ").concat(p, " { ").concat(w, " }") : w);
1377
- i.namespace && (v = qn(v, i.namespace));
1378
- var S = [];
1379
- return mt(v, Yr(f.concat(Vr(function(E) {
1380
- return S.push(E);
1381
- })))), S;
1382
- };
1383
- return h.hash = l.length ? l.reduce(function(m, p) {
1384
- return p.name || We(15), Ee(m, p.name);
1385
- }, Ln).toString() : "", h;
1386
- }
1387
- var Ao = new Kn(), Gt = Io(), Xn = ye.createContext({ shouldForwardProp: void 0, styleSheet: Ao, stylis: Gt });
1388
- Xn.Consumer;
1389
- ye.createContext(void 0);
1390
- function wn() {
1391
- return xe(Xn);
1392
- }
1393
- var Sn = function() {
1394
- function e(t, n) {
1395
- var r = this;
1396
- this.inject = function(o, s) {
1397
- s === void 0 && (s = Gt);
1398
- var i = r.name + s.hash;
1399
- o.hasNameForId(r.id, i) || o.insertRules(r.id, i, s(r.rules, i, "@keyframes"));
1400
- }, this.name = t, this.id = "sc-keyframes-".concat(t), this.rules = n, qt(this, function() {
1401
- throw We(12, String(r.name));
1402
- });
1403
- }
1404
- return e.prototype.getName = function(t) {
1405
- return t === void 0 && (t = Gt), this.name + t.hash;
1406
- }, e;
1407
- }(), _o = function(e) {
1408
- return e >= "A" && e <= "Z";
1409
- };
1410
- function kn(e) {
1411
- for (var t = "", n = 0; n < e.length; n++) {
1412
- var r = e[n];
1413
- if (n === 1 && r === "-" && e[0] === "-") return e;
1414
- _o(r) ? t += "-" + r.toLowerCase() : t += r;
1415
- }
1416
- return t.startsWith("ms-") ? "-" + t : t;
1417
- }
1418
- var Jn = function(e) {
1419
- return e == null || e === !1 || e === "";
1420
- }, Zn = function(e) {
1421
- var t, n, r = [];
1422
- for (var o in e) {
1423
- var s = e[o];
1424
- e.hasOwnProperty(o) && !Jn(s) && (Array.isArray(s) && s.isCss || He(s) ? r.push("".concat(kn(o), ":"), s, ";") : Fe(s) ? r.push.apply(r, Be(Be(["".concat(o, " {")], Zn(s), !1), ["}"], !1)) : r.push("".concat(kn(o), ": ").concat((t = o, (n = s) == null || typeof n == "boolean" || n === "" ? "" : typeof n != "number" || n === 0 || t in qr || t.startsWith("--") ? String(n).trim() : "".concat(n, "px")), ";")));
1425
- }
1426
- return r;
1427
- };
1428
- function _e(e, t, n, r) {
1429
- if (Jn(e)) return [];
1430
- if (Kt(e)) return [".".concat(e.styledComponentId)];
1431
- if (He(e)) {
1432
- if (!He(s = e) || s.prototype && s.prototype.isReactComponent || !t) return [e];
1433
- var o = e(t);
1434
- return process.env.NODE_ENV === "production" || typeof o != "object" || Array.isArray(o) || o instanceof Sn || Fe(o) || o === null || console.error("".concat(Fn(e), " is not a styled component and cannot be referred to via component selector. See https://www.styled-components.com/docs/advanced#referring-to-other-components for more details.")), _e(o, t, n, r);
1435
- }
1436
- var s;
1437
- return e instanceof Sn ? n ? (e.inject(n, r), [e.getName(r)]) : [e] : Fe(e) ? Zn(e) : Array.isArray(e) ? Array.prototype.concat.apply(Ct, e.map(function(i) {
1438
- return _e(i, t, n, r);
1439
- })) : [e.toString()];
1440
- }
1441
- function zo(e) {
1442
- for (var t = 0; t < e.length; t += 1) {
1443
- var n = e[t];
1444
- if (He(n) && !Kt(n)) return !1;
1445
- }
1446
- return !0;
1447
- }
1448
- var Ro = Hn(kt), To = function() {
1449
- function e(t, n, r) {
1450
- this.rules = t, this.staticRulesId = "", this.isStatic = process.env.NODE_ENV === "production" && (r === void 0 || r.isStatic) && zo(t), this.componentId = n, this.baseHash = Ee(Ro, n), this.baseStyle = r, Kn.registerId(n);
1451
- }
1452
- return e.prototype.generateAndInjectStyles = function(t, n, r) {
1453
- var o = this.baseStyle ? this.baseStyle.generateAndInjectStyles(t, n, r) : "";
1454
- if (this.isStatic && !r.hash) if (this.staticRulesId && n.hasNameForId(this.componentId, this.staticRulesId)) o = Ie(o, this.staticRulesId);
1455
- else {
1456
- var s = $n(_e(this.rules, t, n, r)), i = Ht(Ee(this.baseHash, s) >>> 0);
1457
- if (!n.hasNameForId(this.componentId, i)) {
1458
- var d = r(s, ".".concat(i), void 0, this.componentId);
1459
- n.insertRules(this.componentId, i, d);
1460
- }
1461
- o = Ie(o, i), this.staticRulesId = i;
1462
- }
1463
- else {
1464
- for (var l = Ee(this.baseHash, r.hash), u = "", f = 0; f < this.rules.length; f++) {
1465
- var h = this.rules[f];
1466
- if (typeof h == "string") u += h, process.env.NODE_ENV !== "production" && (l = Ee(l, h));
1467
- else if (h) {
1468
- var m = $n(_e(h, t, n, r));
1469
- l = Ee(l, m + f), u += m;
1470
- }
1471
- }
1472
- if (u) {
1473
- var p = Ht(l >>> 0);
1474
- n.hasNameForId(this.componentId, p) || n.insertRules(this.componentId, p, r(u, ".".concat(p), void 0, this.componentId)), o = Ie(o, p);
1475
- }
1476
- }
1477
- return o;
1478
- }, e;
1479
- }(), Qn = ye.createContext(void 0);
1480
- Qn.Consumer;
1481
- var Mt = {}, Cn = /* @__PURE__ */ new Set();
1482
- function Oo(e, t, n) {
1483
- var r = Kt(e), o = e, s = !Pt(e), i = t.attrs, d = i === void 0 ? Ct : i, l = t.componentId, u = l === void 0 ? function(_, z) {
1484
- var C = typeof _ != "string" ? "sc" : pn(_);
1485
- Mt[C] = (Mt[C] || 0) + 1;
1486
- var x = "".concat(C, "-").concat(no(kt + C + Mt[C]));
1487
- return z ? "".concat(z, "-").concat(x) : x;
1488
- }(t.displayName, t.parentComponentId) : l, f = t.displayName, h = f === void 0 ? function(_) {
1489
- return Pt(_) ? "styled.".concat(_) : "Styled(".concat(Fn(_), ")");
1490
- }(e) : f, m = t.displayName && t.componentId ? "".concat(pn(t.displayName), "-").concat(t.componentId) : t.componentId || u, p = r && o.attrs ? o.attrs.concat(d).filter(Boolean) : d, g = t.shouldForwardProp;
1491
- if (r && o.shouldForwardProp) {
1492
- var $ = o.shouldForwardProp;
1493
- if (t.shouldForwardProp) {
1494
- var w = t.shouldForwardProp;
1495
- g = function(_, z) {
1496
- return $(_, z) && w(_, z);
1497
- };
1498
- } else g = $;
1499
- }
1500
- var v = new To(n, m, r ? o.componentStyle : void 0);
1501
- function S(_, z) {
1502
- return function(C, x, D) {
1503
- var V = C.attrs, oe = C.componentStyle, te = C.defaultProps, se = C.foldedComponentIds, X = C.styledComponentId, Ve = C.target, Ke = ye.useContext(Qn), _t = wn(), Te = C.shouldForwardProp || _t.shouldForwardProp;
1504
- process.env.NODE_ENV !== "production" && sn(X);
1505
- var rt = Zr(x, Ke, te) || Le, H = function(Se, pe, ke) {
1506
- for (var ae, ne = U(U({}, pe), { className: void 0, theme: ke }), Oe = 0; Oe < Se.length; Oe += 1) {
1507
- var Ce = He(ae = Se[Oe]) ? ae(ne) : ae;
1508
- for (var J in Ce) ne[J] = J === "className" ? Ie(ne[J], Ce[J]) : J === "style" ? U(U({}, ne[J]), Ce[J]) : Ce[J];
1509
- }
1510
- return pe.className && (ne.className = Ie(ne.className, pe.className)), ne;
1511
- }(V, x, rt), he = H.as || Ve, K = {};
1512
- for (var W in H) H[W] === void 0 || W[0] === "$" || W === "as" || W === "theme" && H.theme === rt || (W === "forwardedAs" ? K.as = H.forwardedAs : Te && !Te(W, he) || (K[W] = H[W], Te || process.env.NODE_ENV !== "development" || _r(W) || Cn.has(W) || !Lt.has(he) || (Cn.add(W), console.warn('styled-components: it looks like an unknown prop "'.concat(W, '" is being sent through to the DOM, which will likely trigger a React console error. If you would like automatic filtering of unknown props, you can opt-into that behavior via `<StyleSheetManager shouldForwardProp={...}>` (connect an API like `@emotion/is-prop-valid`) or consider using transient props (`$` prefix for automatic filtering.)')))));
1513
- var we = function(Se, pe) {
1514
- var ke = wn(), ae = Se.generateAndInjectStyles(pe, ke.styleSheet, ke.stylis);
1515
- return process.env.NODE_ENV !== "production" && sn(ae), ae;
1516
- }(oe, H);
1517
- process.env.NODE_ENV !== "production" && C.warnTooManyClasses && C.warnTooManyClasses(we);
1518
- var ie = Ie(se, X);
1519
- return we && (ie += " " + we), H.className && (ie += " " + H.className), K[Pt(he) && !Lt.has(he) ? "class" : "className"] = ie, D && (K.ref = D), vr(he, K);
1520
- }(E, _, z);
1521
- }
1522
- S.displayName = h;
1523
- var E = ye.forwardRef(S);
1524
- return E.attrs = p, E.componentStyle = v, E.displayName = h, E.shouldForwardProp = g, E.foldedComponentIds = r ? Ie(o.foldedComponentIds, o.styledComponentId) : "", E.styledComponentId = m, E.target = r ? o.target : e, Object.defineProperty(E, "defaultProps", { get: function() {
1525
- return this._foldedDefaultProps;
1526
- }, set: function(_) {
1527
- this._foldedDefaultProps = r ? function(z) {
1528
- for (var C = [], x = 1; x < arguments.length; x++) C[x - 1] = arguments[x];
1529
- for (var D = 0, V = C; D < V.length; D++) Ft(z, V[D], !0);
1530
- return z;
1531
- }({}, o.defaultProps, _) : _;
1532
- } }), process.env.NODE_ENV !== "production" && (Jr(h, m), E.warnTooManyClasses = /* @__PURE__ */ function(_, z) {
1533
- var C = {}, x = !1;
1534
- return function(D) {
1535
- if (!x && (C[D] = !0, Object.keys(C).length >= 200)) {
1536
- var V = z ? ' with the id of "'.concat(z, '"') : "";
1537
- console.warn("Over ".concat(200, " classes were generated for component ").concat(_).concat(V, `.
1538
- `) + `Consider using the attrs method, together with a style object for frequently changed styles.
1539
- Example:
1540
- const Component = styled.div.attrs(props => ({
1541
- style: {
1542
- background: props.background,
1543
- },
1544
- }))\`width: 100%;\`
1545
-
1546
- <Component />`), x = !0, C = {};
1547
- }
1548
- };
1549
- }(h, m)), qt(E, function() {
1550
- return ".".concat(E.styledComponentId);
1551
- }), s && Yn(E, e, { attrs: !0, componentStyle: !0, displayName: !0, foldedComponentIds: !0, shouldForwardProp: !0, styledComponentId: !0, target: !0 }), E;
1552
- }
1553
- function jn(e, t) {
1554
- for (var n = [e[0]], r = 0, o = t.length; r < o; r += 1) n.push(t[r], e[r + 1]);
1555
- return n;
1556
- }
1557
- var En = function(e) {
1558
- return Object.assign(e, { isCss: !0 });
1559
- };
1560
- function Po(e) {
1561
- for (var t = [], n = 1; n < arguments.length; n++) t[n - 1] = arguments[n];
1562
- if (He(e) || Fe(e)) return En(_e(jn(Ct, Be([e], t, !0))));
1563
- var r = e;
1564
- return t.length === 0 && r.length === 1 && typeof r[0] == "string" ? _e(r) : En(_e(jn(r, t)));
1565
- }
1566
- function Wt(e, t, n) {
1567
- if (n === void 0 && (n = Le), !t) throw We(1, t);
1568
- var r = function(o) {
1569
- for (var s = [], i = 1; i < arguments.length; i++) s[i - 1] = arguments[i];
1570
- return e(t, n, Po.apply(void 0, Be([o], s, !1)));
1571
- };
1572
- return r.attrs = function(o) {
1573
- return Wt(e, t, U(U({}, n), { attrs: Array.prototype.concat(n.attrs, o).filter(Boolean) }));
1574
- }, r.withConfig = function(o) {
1575
- return Wt(e, t, U(U({}, n), o));
1576
- }, r;
1577
- }
1578
- var er = function(e) {
1579
- return Wt(Oo, e);
1580
- }, k = er;
1581
- Lt.forEach(function(e) {
1582
- k[e] = er(e);
1583
- });
1584
- process.env.NODE_ENV !== "production" && typeof navigator < "u" && navigator.product === "ReactNative" && console.warn(`It looks like you've imported 'styled-components' on React Native.
1585
- Perhaps you're looking to import 'styled-components/native'?
1586
- Read more about this at https://www.styled-components.com/docs/basics#react-native`);
1587
- var lt = "__sc-".concat(ze, "__");
1588
- process.env.NODE_ENV !== "production" && process.env.NODE_ENV !== "test" && typeof window < "u" && (window[lt] || (window[lt] = 0), window[lt] === 1 && console.warn(`It looks like there are several instances of 'styled-components' initialized in this application. This may cause dynamic styles to not render properly, errors during the rehydration process, a missing theme prop, and makes your application bigger without good reason.
1589
-
1590
- See https://s-c.sh/2BAXzed for more info.`), window[lt] += 1);
1591
- const Ue = `
1592
- animation: fadeIn ease 400ms;
1593
- -webkit-animation: fadeIn ease 400ms;
1594
- -moz-animation: fadeIn ease 400ms;
1595
-
1596
- @keyframes fadeIn {
1597
- 0% {
1598
- opacity: 0;
1599
- }
1600
- 100% {
1601
- opacity: 1;
1602
- }
1603
- }
1604
-
1605
- @-moz-keyframes fadeIn {
1606
- 0% {
1607
- opacity: 0;
1608
- }
1609
- 100% {
1610
- opacity: 1;
1611
- }
1612
- }
1613
-
1614
- @-webkit-keyframes fadeIn {
1615
- 0% {
1616
- opacity: 0;
1617
- }
1618
- 100% {
1619
- opacity: 1;
1620
- }
1621
- }
1622
- `, tr = `
1623
- animation: fadeOut ease 400ms;
1624
- -webkit-animation: fadeOut ease 400ms;
1625
- -moz-animation: fadeOut ease 400ms;
1626
-
1627
- @keyframes fadeOut {
1628
- 0% {
1629
- opacity: 1;
1630
- }
1631
- 100% {
1632
- opacity: 0;
1633
- }
1634
- }
1635
-
1636
- @-moz-keyframes fadeOut {
1637
- 0% {
1638
- opacity: 1;
1639
- }
1640
- 100% {
1641
- opacity: 0;
1642
- }
1643
- }
1644
-
1645
- @-webkit-keyframes fadeOut {
1646
- 0% {
1647
- opacity: 1;
1648
- }
1649
- 100% {
1650
- opacity: 0;
1651
- }
1652
- }
1653
- `, Mo = Object.freeze({
1654
- /* Very small devices (phones, 600px and down) */
1655
- /* @media only screen and (max-width: 600px) {...} */
1656
- phones: "only screen and (max-width: 600px)",
1657
- /* Small devices (portrait tablets and large phones, 600px and up) */
1658
- /* @media only screen and (min-width: 600px) {...} */
1659
- portraitTablets: "only screen and (min-width: 600px)",
1660
- /* Medium devices (landscape tablets, 768px and up) */
1661
- /* @media only screen and (min-width: 768px) {...} */
1662
- landscapeTablets: "only screen and (min-width: 768px)",
1663
- /* Large devices (laptops/desktops, 992px and up) */
1664
- /* @media only screen and (min-width: 992px) {...} */
1665
- laptops: "only screen and (min-width: 992px)",
1666
- /* Extra large devices (large laptops and desktops, 1200px and up) */
1667
- /* @media only screen and (min-width: 1200px) {...} */
1668
- desktops: "only screen and (min-width: 1200px)"
1669
- }), Bo = {
1670
- // Colors
1671
- fontColorBase: "hsl(0, 0%, 24%)",
1672
- fontColorLight: "hsl(0, 0%, 62%)",
1673
- fontColorAccent: "hsl(345, 100%, 47%)",
1674
- backgroundColorBase: "hsl(0, 0%, 100%)",
1675
- backgroundColorLight: "hsl(0, 0%, 95%)",
1676
- backgroundColorTransparent: "hsla(0, 0%, 0%, 0.3)",
1677
- // Gradients
1678
- gradientShadow: "linear-gradient(to left, hsl(340deg 100% 16%) 0%, hsl(340deg 100% 32%) 8%, hsl(340deg 100% 32%) 92%, hsl(340deg 100% 16%) 100%)",
1679
- // Fonts
1680
- fontFamilyCore: "Arial, Helvetica, sans-serif",
1681
- fontFamilyMonospace: "'Courier New', Courier, monospace",
1682
- fontSizeBase: "1.2rem",
1683
- fontSizeSmall: "0.8rem",
1684
- fontSizeHeader: "2rem",
1685
- // Units
1686
- gapSmall: "0.25rem",
1687
- gapMedium: "0.6rem",
1688
- gapBig: "1rem",
1689
- iconSize: "1.2rem",
1690
- blockBorderRadius: "0.25rem",
1691
- // Shadows
1692
- boxShadow: "hsla(0, 0%, 0%, 0.15) 2.4px 2.4px 3.2px",
1693
- textShadow: "2.4px 2.4px 3.2px hsla(0, 0%, 0%, 0.3)",
1694
- // Borders
1695
- borderBase: "1px solid hsl(0, 0%, 84%)",
1696
- borderLight: "1px solid hsl(0, 0%, 89%)",
1697
- borderAccent: "1px solid hsl(345, 100%, 47%)",
1698
- borderOutline: "1px solid hsl(0, 0%, 24%)",
1699
- // Z-indexes
1700
- zIndexBase: "1",
1701
- zIndexPopup: "100",
1702
- zIndexModal: "200"
1703
- }, Do = {
1704
- // Colors
1705
- fontColorBase: "hsl(0, 0%, 100%)",
1706
- fontColorLight: "hsl(0, 0%, 92%)",
1707
- fontColorAccent: "hsl(16, 82%, 52%)",
1708
- backgroundColorBase: "hsl(0, 0%, 17%)",
1709
- backgroundColorLight: "hsl(0, 0%, 24%)",
1710
- backgroundColorTransparent: "hsla(0, 0%, 92%, 0.3)",
1711
- // Gradients
1712
- gradientShadow: "linear-gradient(to left, hsl(16, 86%, 26%) 0%, hsl(16, 86%, 30%) 8%, hsl(16, 86%, 30%) 92%, hsl(16, 86%, 26%) 100%)",
1713
- // Fonts
1714
- fontFamilyCore: "Arial, Helvetica, sans-serif",
1715
- fontFamilyMonospace: "'Courier New', Courier, monospace",
1716
- fontSizeBase: "1.2rem",
1717
- fontSizeSmall: "0.8rem",
1718
- fontSizeHeader: "2rem",
1719
- // Units
1720
- gapSmall: "0.25rem",
1721
- gapMedium: "0.6rem",
1722
- gapBig: "1rem",
1723
- iconSize: "1.2rem",
1724
- blockBorderRadius: "0.25rem",
1725
- // Shadows
1726
- boxShadow: "hsla(0, 0%, 92%, 0.15) 2.4px 2.4px 3.2px",
1727
- textShadow: "2.4px 2.4px 3.2px hsla(0, 0%, 92%, 0.3)",
1728
- // Borders
1729
- borderBase: "1px solid hsl(0, 0%, 11%)",
1730
- borderLight: "1px solid hsl(0, 0%, 29%)",
1731
- borderAccent: "1px solid hsl(16, 82%, 52%)",
1732
- borderOutline: "1px solid hsl(0, 0%, 100%)",
1733
- // Z-indexes
1734
- zIndexBase: "1",
1735
- zIndexPopup: "100",
1736
- zIndexModal: "200"
1737
- }, No = k.span`
1738
- display: ${({ $visible: e }) => e ? "block" : "none"};
1739
- position: absolute;
1740
- max-width: 100%;
1741
- right: 0;
1742
- top: 72px;
1743
- opacity: 0.8;
1744
- z-index: ${(e) => e.$theme.zIndexPopup};
1745
- background-color: ${(e) => e.$theme.backgroundColorBase};
1746
- border: ${(e) => e.$theme.borderAccent};
1747
- color: ${(e) => e.$theme.fontColorAccent};
1748
- padding: ${(e) => e.$theme.gapMedium};
1749
- font-size: ${(e) => e.$theme.fontSizeSmall};
1750
- font-family: ${(e) => e.$theme.fontFamilyCore};
1751
- border-radius: ${(e) => e.$theme.blockBorderRadius};
1752
- box-shadow: ${(e) => e.$theme.boxShadow};
1753
- pointer-events: none;
1754
-
1755
- ${Ue}
1756
- `, nr = ({
1757
- errorId: e,
1758
- testId: t,
1759
- message: n = "Invalid input",
1760
- visible: r = !1,
1761
- style: o,
1762
- theme: s
1763
- }) => /* @__PURE__ */ c.jsx(No, { id: e, $visible: r, "data-testid": t, style: o, $theme: s, "aria-hidden": !r, children: n });
1764
- var Z = /* @__PURE__ */ ((e) => (e.Success = "success", e.Error = "error", e.Warning = "warning", e.Info = "info", e.Help = "help", e))(Z || {}), be = /* @__PURE__ */ ((e) => (e.Primary = "primary", e.Flat = "flat", e.Icon = "icon", e))(be || {}), j = /* @__PURE__ */ ((e) => (e.ArrowDown = "arrow-down", e.ArrowUp = "arrow-up", e.Back = "back", e.Cancel = "cancel", e.CheckboxChecked = "checkbox-checked", e.CheckboxUnchecked = "checkbox-unchecked", e.CheckMark = "check-mark", e.ChevronDown = "chevron-down", e.ChevronLeft = "chevron-left", e.ChevronRight = "chevron-right", e.ChevronUp = "chevron-up", e.Clear = "clear", e.Copy = "copy", e.Cut = "cut", e.Delete = "delete", e.Download = "download", e.Error = "error", e.Forward = "forward", e.Graduate = "graduate", e.Help = "help", e.Hide = "hide", e.Home = "home", e.Info = "info", e.Login = "login", e.Paste = "paste", e.Question = "question", e.Save = "save", e.Show = "show", e.Upload = "upload", e.Warning = "warning", e.Remove = "remove", e))(j || {}), Lo = /* @__PURE__ */ ((e) => (e.Dots = "dots", e.Brackets = "brackets", e.Linear = "linear", e.Square = "square", e.Circle = "circle", e.Pulse = "pulse", e.Arrow = "arrow", e.Filler = "filler", e.Rotation = "rotation", e))(Lo || {}), Y = /* @__PURE__ */ ((e) => (e.Vertical = "vertical", e.Horizontal = "horizontal", e))(Y || {}), rr = /* @__PURE__ */ ((e) => (e.Light = "light", e.Dark = "dark", e))(rr || {}), or = /* @__PURE__ */ ((e) => (e.Span = "span", e.Div = "div", e.P = "p", e.Strong = "strong", e.Em = "em", e))(or || {});
1765
- const Ho = T(() => Promise.resolve().then(() => Ds)), Fo = T(() => Promise.resolve().then(() => Ns)), Go = T(() => import("./BackIcon-Dol4HlEB.js")), Wo = T(() => import("./CancelIcon-Bdj8BJBh.js")), Uo = T(() => Promise.resolve().then(() => Rs)), Yo = T(() => Promise.resolve().then(() => Ts)), Vo = T(() => Promise.resolve().then(() => Js)), Ko = T(() => import("./ChevronDownIcon-Bc3VeNFb.js")), qo = T(() => import("./ChevronLeftIcon-7IFnvAad.js")), Xo = T(() => import("./ChevronRightIcon-CSlX-7NZ.js")), Jo = T(() => import("./ChevronUpIcon-DfSPGScz.js")), Zo = T(() => import("./ClearIcon-DR09y0XK.js")), Qo = T(() => import("./CopyIcon-Cncb2wSQ.js")), es = T(() => import("./CutIcon-DsxJcafW.js")), ts = T(() => import("./DeleteIcon-C0T5ZleK.js")), ns = T(() => import("./DownloadIcon-C_1FJXS6.js")), rs = T(() => Promise.resolve().then(() => ta)), os = T(() => import("./ForwardIcon-DSxMxnjb.js")), ss = T(() => import("./GraduateIcon-DQLWdRj8.js")), is = T(() => Promise.resolve().then(() => na)), as = T(() => import("./HideIcon-Bp5glcyr.js")), cs = T(() => import("./HomeIcon-DyYP6u5L.js")), ls = T(() => Promise.resolve().then(() => ra)), ds = T(() => import("./LoginIcon-CXb93ZdU.js")), us = T(() => import("./PasteIcon-D5VKRUHc.js")), fs = T(() => import("./QuestionIcon-CA5cYfsl.js")), hs = T(() => import("./RemoveIcon-DIvsqLi-.js")), ps = T(() => import("./SaveIcon-DhBj4tAF.js")), ms = T(() => import("./ShowIcon-DkpGVHWR.js")), gs = T(() => import("./UploadIcon-CvFnGI7Y.js")), bs = T(() => Promise.resolve().then(() => oa)), ys = {
1766
- [j.ArrowDown]: Ho,
1767
- [j.ArrowUp]: Fo,
1768
- [j.Back]: Go,
1769
- [j.Cancel]: Wo,
1770
- [j.CheckboxChecked]: Uo,
1771
- [j.CheckboxUnchecked]: Yo,
1772
- [j.CheckMark]: Vo,
1773
- [j.ChevronDown]: Ko,
1774
- [j.ChevronUp]: Jo,
1775
- [j.ChevronLeft]: qo,
1776
- [j.ChevronRight]: Xo,
1777
- [j.Clear]: Zo,
1778
- [j.Copy]: Qo,
1779
- [j.Cut]: es,
1780
- [j.Delete]: ts,
1781
- [j.Download]: ns,
1782
- [j.Error]: rs,
1783
- [j.Forward]: os,
1784
- [j.Graduate]: ss,
1785
- [j.Help]: is,
1786
- [j.Hide]: as,
1787
- [j.Home]: cs,
1788
- [j.Info]: ls,
1789
- [j.Login]: ds,
1790
- [j.Paste]: us,
1791
- [j.Question]: fs,
1792
- [j.Save]: ps,
1793
- [j.Show]: ms,
1794
- [j.Upload]: gs,
1795
- [j.Warning]: bs,
1796
- [j.Remove]: hs
1797
- }, ue = ({ name: e, testId: t, ...n }) => {
1798
- if (!e) return null;
1799
- const r = /* @__PURE__ */ c.jsx("span", { style: { fontSize: "1rem" }, "aria-label": "SVG Icon Fallback", children: "⬜" }), o = ys[e];
1800
- return /* @__PURE__ */ c.jsx(wr, { fallback: r, children: /* @__PURE__ */ c.jsx(o, { "data-testid": t, ...n }) });
1801
- }, $s = k.button`
1802
- background: transparent;
1803
- border: none;
1804
- display: flex;
1805
- align-items: center;
1806
- font-size: ${(e) => e.$theme.fontSizeBase};
1807
- color: ${(e) => e.$theme.fontColorLight};
1808
- padding: 0;
1809
-
1810
- &:focus-visible {
1811
- outline: ${(e) => e.$theme.borderOutline};
1812
- outline-offset: -1px;
1813
- }
1814
-
1815
- &:hover {
1816
- color: ${(e) => e.$theme.fontColorAccent};
1817
- }
1818
-
1819
- svg {
1820
- cursor: pointer;
1821
- height: ${(e) => e.$theme.iconSize};
1822
- width: ${(e) => e.$theme.iconSize};
1823
- }
1824
-
1825
- &[disabled] {
1826
- pointer-events: none;
1827
- opacity: 0.5;
1828
- }
1829
- `, yt = ({ onClick: e, label: t, icon: n, disabled: r, theme: o }) => /* @__PURE__ */ c.jsx($s, { onClick: e, "aria-label": t, type: "button", disabled: r, $theme: o, children: /* @__PURE__ */ c.jsx(ue, { name: n }) }), xs = k.label`
1830
- display: flex;
1831
- align-items: center;
1832
- font-size: ${(e) => e.$theme.fontSizeSmall};
1833
- font-family: ${(e) => e.$theme.fontFamilyCore};
1834
- gap: ${(e) => e.$theme.gapSmall};
1835
- color: ${(e) => e.$theme.fontColorBase};
1836
-
1837
- &:hover {
1838
- text-shadow: ${(e) => e.$theme.textShadow};
1839
- }
1840
-
1841
- & + span {
1842
- text-wrap: nowrap;
1843
- overflow: hidden;
1844
- text-overflow: ellipsis;
1845
- }
1846
-
1847
- & abbr {
1848
- text-decoration: none;
1849
- cursor: pointer;
1850
- color: ${(e) => e.$theme.fontColorAccent};
1851
- margin-left: ${(e) => e.$theme.gapSmall};
1852
- }
1853
- `, Ye = ({
1854
- label: e,
1855
- required: t,
1856
- inputId: n,
1857
- theme: r,
1858
- icon: o,
1859
- iconPosition: s,
1860
- isTextHidden: i = !1,
1861
- style: d
1862
- }) => {
1863
- const l = !!o && s === "left", u = !!o && s === "right";
1864
- return /* @__PURE__ */ c.jsxs(xs, { htmlFor: n, style: d, $theme: r, children: [
1865
- l && o,
1866
- !i && /* @__PURE__ */ c.jsxs("span", { children: [
1867
- e,
1868
- t && /* @__PURE__ */ c.jsx("abbr", { title: "required", children: "*" })
1869
- ] }),
1870
- u && o
1871
- ] });
1872
- };
1873
- function vs(e) {
1874
- return ({ tooltip: t, visibleOn: n, ...r }) => t != null && t.length ? /* @__PURE__ */ c.jsx(pi, { tooltipContent: t, visibleOn: n, children: /* @__PURE__ */ c.jsx(e, { ...r }) }) : /* @__PURE__ */ c.jsx(e, { ...r });
1875
- }
1876
- const Re = ye.createContext({}), ws = ye.createContext({
1877
- mode: rr.Light
1878
- });
1879
- function Ss(e, t) {
1880
- const n = e === "dark" ? Do : Bo;
1881
- if (t)
1882
- for (const r in t) {
1883
- const o = r;
1884
- Object.prototype.hasOwnProperty.call(n, o) && (n[o] = t[o].toString());
1885
- }
1886
- return n;
1887
- }
1888
- function et(e) {
1889
- const t = document.getElementById(e);
1890
- t && t.focus();
1891
- }
1892
- function sr({
1893
- e,
1894
- options: t,
1895
- onClose: n
1896
- }) {
1897
- let r = "";
1898
- t.forEach((s) => {
1899
- document.getElementById(s.id) === document.activeElement && (r = s.id);
1900
- });
1901
- const o = t.findIndex((s) => s.id === r);
1902
- switch (e.key) {
1903
- case "Escape":
1904
- e.preventDefault(), n();
1905
- break;
1906
- case "ArrowUp": {
1907
- e.preventDefault();
1908
- const s = o - 1 >= 0 ? o - 1 : t.length - 1, i = t[s];
1909
- i && et(i.id);
1910
- break;
1911
- }
1912
- case "ArrowDown":
1913
- case "Tab": {
1914
- e.preventDefault();
1915
- const s = o === t.length - 1 ? 0 : o + 1, i = t[s];
1916
- i && et(i.id);
1917
- break;
1918
- }
1919
- }
1920
- }
1921
- const q = () => {
1922
- const { customTheme: e, mode: t } = xe(ws);
1923
- return Ss(t, e);
1924
- }, jt = ({ ref: e, onClickOutsideHandler: t, dependentRef: n }) => {
1925
- fe(() => {
1926
- const r = (o) => {
1927
- const s = (e == null ? void 0 : e.current) && !e.current.contains(o.target), i = n != null && n.current ? !n.current.contains(o.target) : !0;
1928
- s && i && t();
1929
- };
1930
- return document.addEventListener("mousedown", r), () => {
1931
- document.removeEventListener("mousedown", r);
1932
- };
1933
- }, [e, n, t]);
1934
- }, ks = ({ ref: e, isVisible: t }) => {
1935
- const [n, r] = B({ width: 0, height: 0 });
1936
- return fe(() => {
1937
- e != null && e.current && t && r({
1938
- width: e.current.offsetWidth,
1939
- height: e.current.offsetHeight
1940
- });
1941
- }, [e, t]), n;
1942
- };
1943
- function ve(e) {
1944
- const t = Sr(), n = e ?? t, r = `${n}_error`, o = `${n}_dropdown`;
1945
- return {
1946
- elementId: n,
1947
- errorId: r,
1948
- dropdownId: o
1949
- };
1950
- }
1951
- const Et = ({ ref: e, keyCode: t, onKeyPress: n }) => {
1952
- fe(() => {
1953
- const r = (o) => {
1954
- (o == null ? void 0 : o.code) === t && (e != null && e.current) && n();
1955
- };
1956
- return document.addEventListener("keydown", r, !1), () => {
1957
- document.removeEventListener("keydown", r, !1);
1958
- };
1959
- }, [e, t, n]);
1960
- }, Cs = ({ modalRef: e, isOpened: t }) => {
1961
- fe(() => {
1962
- const n = e.current;
1963
- if (!t || !n) return;
1964
- const r = n.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])'), o = r[0], s = r[r.length - 1], i = (d) => {
1965
- d.key === "Tab" && (d.shiftKey && document.activeElement === o ? (d.preventDefault(), s.focus()) : !d.shiftKey && document.activeElement === s && (d.preventDefault(), o.focus()));
1966
- };
1967
- return n.addEventListener("keydown", i), () => {
1968
- n.removeEventListener("keydown", i);
1969
- };
1970
- }, [e, t]);
1971
- }, ir = (e, t = 300) => {
1972
- const [n, r] = B(!1);
1973
- return fe(() => {
1974
- e && !n ? r(!0) : !e && n && setTimeout(() => {
1975
- r(!1);
1976
- }, t);
1977
- }, [e]), n;
1978
- }, nt = (e) => {
1979
- const { resetSignal: t } = xe(Re);
1980
- fe(() => {
1981
- t && e();
1982
- }, [t, e]);
1983
- };
1984
- function In() {
1985
- const { innerWidth: e, innerHeight: t } = window;
1986
- return { width: e, height: t };
1987
- }
1988
- function js() {
1989
- const [e, t] = B(In());
1990
- return fe(() => {
1991
- function n() {
1992
- t(In());
1993
- }
1994
- return window.addEventListener("resize", n), () => window.removeEventListener("resize", n);
1995
- }, []), e;
1996
- }
1997
- const Es = ({ wrapperRef: e, tooltipRef: t, isOpened: n, spacing: r = 4 }) => {
1998
- const [o, s] = B({ top: 0, left: 0 }), { width: i, height: d } = ks({
1999
- ref: t,
2000
- isVisible: n
2001
- }), { width: l, height: u } = js();
2002
- return fe(() => {
2003
- if (n && (e != null && e.current)) {
2004
- const f = e == null ? void 0 : e.current.getBoundingClientRect();
2005
- let h = Math.round(f.bottom + r), m = Math.round(f.left);
2006
- h + d > window.innerHeight && (h = Math.round(f.top - d - r)), m + i > window.innerWidth && (m = Math.round(window.innerWidth - i - r)), m < 0 && (m = r), s({ top: h, left: m });
2007
- }
2008
- }, [n, e, d, i, r, l, u]), o;
2009
- }, Is = k.button`
2010
- position: relative;
2011
- border: none;
2012
- background: transparent;
2013
- padding: 0;
2014
- cursor: pointer;
2015
- outline: none;
2016
- transition: filter 250ms;
2017
- width: ${(e) => e.$extended ? "100%" : "inherit"};
2018
-
2019
- &[disabled] {
2020
- pointer-events: none;
2021
- opacity: 0.5;
2022
- }
2023
-
2024
- .chop-logic-button_shadow {
2025
- position: absolute;
2026
- top: 0;
2027
- left: 0;
2028
- width: 100%;
2029
- height: 100%;
2030
- border-radius: ${(e) => e.$theme.blockBorderRadius};
2031
- background: hsl(0deg 0% 0% / 0.25);
2032
- will-change: transform;
2033
- transform: translateY(2px);
2034
- transition: transform 600ms cubic-bezier(0.3, 0.7, 0.4, 1);
2035
- }
2036
-
2037
- .chop-logic-button_edge {
2038
- position: absolute;
2039
- top: 0;
2040
- left: 0;
2041
- width: 100%;
2042
- height: 100%;
2043
- border-radius: ${(e) => e.$theme.blockBorderRadius};
2044
- background: ${(e) => e.$theme.gradientShadow};
2045
- }
2046
-
2047
- .chop-logic-button_front {
2048
- display: flex;
2049
- align-items: center;
2050
- justify-content: center;
2051
- gap: ${(e) => e.$theme.gapSmall};
2052
- position: relative;
2053
- padding: ${(e) => `${e.$theme.gapMedium} ${e.$theme.gapBig}`};
2054
- border-radius: ${(e) => e.$theme.blockBorderRadius};
2055
- font-size: ${(e) => e.$theme.fontSizeBase};
2056
- color: #ffffff;
2057
- background: ${(e) => e.$theme.fontColorAccent};
2058
- will-change: transform;
2059
- transform: translateY(-4px);
2060
- transition: transform 600ms cubic-bezier(0.3, 0.7, 0.4, 1);
2061
- }
2062
-
2063
- &:hover {
2064
- filter: brightness(110%);
2065
- }
2066
-
2067
- &:hover .chop-logic-button_front {
2068
- transform: translateY(-6px);
2069
- transition: transform 250ms cubic-bezier(0.3, 0.7, 0.4, 1.5);
2070
- }
2071
-
2072
- &:active .chop-logic-button_front {
2073
- transform: translateY(-2px);
2074
- transition: transform 34ms;
2075
- }
2076
-
2077
- &:hover .chop-logic-button_shadow {
2078
- transform: translateY(4px);
2079
- transition: transform 250ms cubic-bezier(0.3, 0.7, 0.4, 1.5);
2080
- }
2081
-
2082
- &:active .chop-logic-button_shadow {
2083
- transform: translateY(1px);
2084
- transition: transform 34ms;
2085
- }
2086
-
2087
- &:focus-visible {
2088
- outline: revert;
2089
- outline: ${(e) => e.$theme.borderOutline};
2090
- outline-offset: 4px;
2091
- }
2092
- `, As = k.button`
2093
- border: none;
2094
- cursor: pointer;
2095
- display: flex;
2096
- align-items: center;
2097
- justify-content: center;
2098
- gap: ${(e) => e.$theme.gapSmall};
2099
- padding: ${(e) => `${e.$theme.gapMedium} ${e.$theme.gapBig}`};
2100
- border-radius: ${(e) => e.$theme.blockBorderRadius};
2101
- font-size: ${(e) => e.$theme.fontSizeBase};
2102
- color: ${(e) => e.$theme.fontColorBase};
2103
- background: transparent;
2104
- width: ${(e) => e.$extended ? "100%" : "inherit"};
2105
-
2106
- &:hover,
2107
- &:active {
2108
- background: ${(e) => e.$theme.backgroundColorLight};
2109
- transition: all 0.3s ease 0s;
2110
- color: ${(e) => e.$theme.fontColorAccent};
2111
- }
2112
-
2113
- &:focus-visible {
2114
- outline: ${(e) => e.$theme.borderOutline};
2115
- }
2116
-
2117
- &[disabled] {
2118
- pointer-events: none;
2119
- opacity: 0.5;
2120
- }
2121
- `, _s = k.button`
2122
- border: none;
2123
- cursor: pointer;
2124
- display: flex;
2125
- align-items: center;
2126
- justify-content: center;
2127
- padding: ${(e) => e.$theme.gapMedium};
2128
- border-radius: ${(e) => e.$theme.blockBorderRadius};
2129
- font-size: ${(e) => e.$theme.fontSizeBase};
2130
- color: ${(e) => e.$theme.fontColorBase};
2131
- background: transparent;
2132
-
2133
- &:hover {
2134
- background-color: ${(e) => e.$theme.backgroundColorLight};
2135
- color: ${(e) => e.$theme.fontColorAccent};
2136
- transition: all 0.3s ease 0s;
2137
- }
2138
-
2139
- &:focus-visible {
2140
- outline: ${(e) => e.$theme.borderOutline};
2141
- }
2142
-
2143
- &[disabled] {
2144
- pointer-events: none;
2145
- opacity: 0.5;
2146
- }
2147
-
2148
- svg {
2149
- height: ${(e) => e.$theme.iconSize};
2150
- width: ${(e) => e.$theme.iconSize};
2151
- }
2152
- `, zs = ({
2153
- onClick: e,
2154
- text: t,
2155
- icon: n,
2156
- label: r,
2157
- disabled: o = !1,
2158
- extended: s = !1,
2159
- type: i = "button",
2160
- view: d = be.Primary,
2161
- ...l
2162
- }) => {
2163
- const u = q();
2164
- switch (d) {
2165
- case be.Primary:
2166
- return /* @__PURE__ */ c.jsxs(
2167
- Is,
2168
- {
2169
- $extended: s,
2170
- "aria-label": r,
2171
- type: i,
2172
- onClick: e,
2173
- disabled: o,
2174
- $theme: u,
2175
- ...l,
2176
- children: [
2177
- /* @__PURE__ */ c.jsx("span", { className: "chop-logic-button_shadow" }),
2178
- /* @__PURE__ */ c.jsx("span", { className: "chop-logic-button_edge" }),
2179
- /* @__PURE__ */ c.jsxs("span", { className: "chop-logic-button_front", children: [
2180
- /* @__PURE__ */ c.jsx(ue, { name: n }),
2181
- t
2182
- ] })
2183
- ]
2184
- }
2185
- );
2186
- case be.Flat:
2187
- return /* @__PURE__ */ c.jsxs(
2188
- As,
2189
- {
2190
- $extended: s,
2191
- "aria-label": r,
2192
- type: i,
2193
- onClick: e,
2194
- disabled: o,
2195
- $theme: u,
2196
- ...l,
2197
- children: [
2198
- /* @__PURE__ */ c.jsx(ue, { name: n }),
2199
- t
2200
- ]
2201
- }
2202
- );
2203
- case be.Icon:
2204
- return /* @__PURE__ */ c.jsx(_s, { "aria-label": r, type: i, onClick: e, disabled: o, $theme: u, ...l, children: /* @__PURE__ */ c.jsx(ue, { name: n }) });
2205
- default:
2206
- return null;
2207
- }
2208
- }, $t = vs(zs);
2209
- function It(e) {
2210
- return /* @__PURE__ */ c.jsxs("svg", { viewBox: "0 0 16 16", fill: "currentColor", height: "1em", width: "1em", role: "img", ...e, children: [
2211
- /* @__PURE__ */ c.jsx("title", { children: "Checkbox Checked" }),
2212
- /* @__PURE__ */ c.jsx(
2213
- "path",
2214
- {
2215
- fill: "currentColor",
2216
- d: "M14 0H2C.9 0 0 .9 0 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V2c0-1.1-.9-2-2-2zM7 12.414L3.293 8.707l1.414-1.414L7 9.586l4.793-4.793 1.414 1.414L7 12.414z"
2217
- }
2218
- )
2219
- ] });
2220
- }
2221
- const Rs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2222
- __proto__: null,
2223
- default: It
2224
- }, Symbol.toStringTag, { value: "Module" }));
2225
- function At(e) {
2226
- return /* @__PURE__ */ c.jsxs("svg", { viewBox: "0 0 16 16", fill: "currentColor", height: "1em", width: "1em", role: "img", ...e, children: [
2227
- /* @__PURE__ */ c.jsx("title", { children: "Checkbox Unchecked" }),
2228
- /* @__PURE__ */ c.jsx("path", { fill: "currentColor", d: "M14 0H2C.9 0 0 .9 0 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V2c0-1.1-.9-2-2-2zm0 14H2V2h12v12z" })
2229
- ] });
2230
- }
2231
- const Ts = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2232
- __proto__: null,
2233
- default: At
2234
- }, Symbol.toStringTag, { value: "Module" })), Os = k.div`
2235
- display: flex;
2236
- gap: ${(e) => e.$theme.gapMedium};
2237
- padding: ${(e) => e.$theme.gapMedium} 0;
2238
- position: relative;
2239
- overflow: hidden;
2240
-
2241
- & svg {
2242
- color: ${(e) => e.$checked ? e.$theme.fontColorAccent : e.$theme.fontColorLight};
2243
- }
2244
-
2245
- & label {
2246
- cursor: pointer;
2247
- gap: ${(e) => e.$theme.gapMedium};
2248
- font-size: ${(e) => e.$theme.fontSizeBase} !important;
2249
- &:hover,
2250
- &:active {
2251
- text-shadow: ${(e) => e.$theme.textShadow};
2252
- }
2253
- }
2254
-
2255
- ${(e) => e.$disabled && `
2256
- pointer-events: none;
2257
- opacity: 0.5;
2258
- `}
2259
-
2260
- & input {
2261
- position: absolute;
2262
- z-index: -1;
2263
- opacity: 0;
2264
- top: 4px;
2265
- left: 0;
2266
- margin: 0;
2267
-
2268
- &:focus-visible + label {
2269
- outline: ${(e) => e.$theme.borderOutline};
2270
- outline-offset: 2px;
2271
- }
2272
- }
2273
- `;
2274
- function Ps({
2275
- defaultChecked: e,
2276
- initialValues: t,
2277
- name: n
2278
- }) {
2279
- return t && (t == null ? void 0 : t[n]) !== void 0 ? !!(t != null && t[n]) : !!e;
2280
- }
2281
- function Ms({
2282
- name: e,
2283
- defaultChecked: t,
2284
- onChange: n
2285
- }) {
2286
- const { onChangeFormInput: r, initialValues: o } = xe(Re), s = Ps({ initialValues: o, name: e, defaultChecked: t }), [i, d] = B(s), l = (f) => {
2287
- const h = f.target.checked;
2288
- d(h), n == null || n(f), r == null || r({ name: e, value: h });
2289
- }, u = tt(() => {
2290
- d(s), r == null || r({ name: e, value: s });
2291
- }, [e]);
2292
- return nt(u), {
2293
- handleChange: l,
2294
- checked: i
2295
- };
2296
- }
2297
- const da = ({
2298
- name: e,
2299
- label: t,
2300
- disabled: n,
2301
- noLabel: r,
2302
- required: o = !1,
2303
- iconPosition: s = "left",
2304
- defaultChecked: i,
2305
- onChange: d,
2306
- id: l,
2307
- ...u
2308
- }) => {
2309
- const { handleChange: f, checked: h } = Ms({ name: e, defaultChecked: i, onChange: d }), { elementId: m } = ve(l), p = q();
2310
- return /* @__PURE__ */ c.jsxs(Os, { $disabled: !!n, $theme: p, $checked: h, ...u, children: [
2311
- /* @__PURE__ */ c.jsx(
2312
- "input",
2313
- {
2314
- id: m,
2315
- name: e,
2316
- type: "checkbox",
2317
- disabled: n,
2318
- required: o,
2319
- checked: h,
2320
- onChange: f,
2321
- "aria-label": r ? t : void 0
2322
- }
2323
- ),
2324
- /* @__PURE__ */ c.jsx(
2325
- Ye,
2326
- {
2327
- label: t,
2328
- required: o,
2329
- inputId: m,
2330
- isTextHidden: r,
2331
- icon: h ? /* @__PURE__ */ c.jsx(It, {}) : /* @__PURE__ */ c.jsx(At, {}),
2332
- iconPosition: s,
2333
- theme: p
2334
- }
2335
- )
2336
- ] });
2337
- }, ar = k.div`
2338
- position: relative;
2339
- display: flex;
2340
- justify-content: space-between;
2341
- flex-direction: column;
2342
- gap: ${(e) => e.$theme.gapMedium};
2343
- background: transparent;
2344
- `, cr = k.button`
2345
- text-align: left;
2346
- cursor: pointer;
2347
- display: flex;
2348
- justify-content: space-between;
2349
- align-items: center;
2350
- gap: ${(e) => e.$theme.gapMedium};
2351
- padding: ${(e) => e.$theme.gapMedium};
2352
- border: ${(e) => e.$theme.borderLight};
2353
- border-radius: ${(e) => e.$theme.blockBorderRadius};
2354
- background-color: ${(e) => e.$theme.backgroundColorBase};
2355
- white-space: nowrap;
2356
- text-overflow: ellipsis;
2357
- overflow: hidden;
2358
-
2359
- & > span:nth-child(1) {
2360
- font-size: ${(e) => e.$theme.fontSizeBase};
2361
- color: ${(e) => e.$theme.fontColorBase};
2362
- font-family: ${(e) => e.$theme.fontFamilyCore};
2363
- overflow: hidden;
2364
- text-overflow: ellipsis;
2365
- }
2366
-
2367
- svg {
2368
- cursor: pointer;
2369
- color: ${(e) => e.$theme.fontColorLight};
2370
- height: ${(e) => e.$theme.iconSize};
2371
- width: ${(e) => e.$theme.iconSize};
2372
-
2373
- &:hover {
2374
- color: ${(e) => e.$theme.fontColorAccent};
2375
- }
2376
- }
2377
-
2378
- &:focus-visible {
2379
- outline: ${(e) => e.$theme.borderOutline};
2380
- outline-offset: 2px;
2381
- }
2382
-
2383
- &[disabled] {
2384
- pointer-events: none;
2385
- opacity: 0.5;
2386
- }
2387
- `, lr = k.ul`
2388
- visibility: hidden;
2389
- opacity: 0;
2390
- transition:
2391
- visibility 0s,
2392
- opacity 0.3s linear;
2393
- position: absolute;
2394
- background: ${(e) => e.$theme.backgroundColorBase};
2395
- margin: 0;
2396
- padding: 0;
2397
- list-style: none;
2398
- z-index: ${(e) => e.$theme.zIndexPopup};
2399
- width: 100%;
2400
- top: 72px;
2401
- left: -1px;
2402
- border: ${(e) => e.$theme.borderLight};
2403
- border-radius: ${(e) => e.$theme.blockBorderRadius};
2404
- box-shadow: ${(e) => e.$theme.boxShadow};
2405
- overflow-y: auto;
2406
- max-height: 180px;
2407
-
2408
- ${(e) => e.$opened && "visibility: visible; opacity: 1;"}
2409
- `, dr = k.li`
2410
- padding: ${(e) => e.$theme.gapMedium};
2411
- cursor: pointer;
2412
- display: flex;
2413
- justify-content: space-between;
2414
- align-items: center;
2415
- gap: ${(e) => e.$theme.gapMedium};
2416
- font-size: ${(e) => e.$theme.fontSizeBase};
2417
- color: ${(e) => e.$theme.fontColorBase};
2418
- font-family: ${(e) => e.$theme.fontFamilyCore};
2419
-
2420
- &:hover,
2421
- &:active {
2422
- color: ${(e) => e.$theme.fontColorAccent};
2423
- }
2424
-
2425
- &:focus-visible {
2426
- outline: ${(e) => e.$theme.borderOutline};
2427
- outline-offset: -4px;
2428
- }
2429
-
2430
- svg {
2431
- color: ${(e) => e.$selected ? e.$theme.fontColorAccent : e.$theme.fontColorLight};
2432
- width: ${(e) => e.$theme.iconSize};
2433
- height: ${(e) => e.$theme.iconSize};
2434
- }
2435
- `, Bs = k(dr)`
2436
- justify-content: flex-start;
2437
- `;
2438
- function Xt(e) {
2439
- return /* @__PURE__ */ c.jsxs("svg", { viewBox: "0 0 24 24", fill: "currentColor", height: "1em", width: "1em", role: "img", ...e, children: [
2440
- /* @__PURE__ */ c.jsx("title", { children: "Arrow Down" }),
2441
- /* @__PURE__ */ c.jsx("path", { d: "M21.886 5.536A1.002 1.002 0 0021 5H3a1.002 1.002 0 00-.822 1.569l9 13a.998.998 0 001.644 0l9-13a.998.998 0 00.064-1.033zM12 17.243L4.908 7h14.184L12 17.243z" })
2442
- ] });
2443
- }
2444
- const Ds = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2445
- __proto__: null,
2446
- default: Xt
2447
- }, Symbol.toStringTag, { value: "Module" }));
2448
- function Jt(e) {
2449
- return /* @__PURE__ */ c.jsxs("svg", { viewBox: "0 0 24 24", fill: "currentColor", height: "1em", width: "1em", role: "img", ...e, children: [
2450
- /* @__PURE__ */ c.jsx("title", { children: "Arrow Up" }),
2451
- /* @__PURE__ */ c.jsx("path", { d: "M3 19h18a1.002 1.002 0 00.823-1.569l-9-13c-.373-.539-1.271-.539-1.645 0l-9 13A.999.999 0 003 19zm9-12.243L19.092 17H4.908L12 6.757z" })
2452
- ] });
2453
- }
2454
- const Ns = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2455
- __proto__: null,
2456
- default: Jt
2457
- }, Symbol.toStringTag, { value: "Module" })), Ls = ({
2458
- opened: e,
2459
- onClick: t,
2460
- comboboxId: n,
2461
- dropdownId: r,
2462
- name: o,
2463
- placeholder: s,
2464
- disabled: i,
2465
- required: d,
2466
- values: l,
2467
- theme: u
2468
- }) => {
2469
- const f = l == null ? void 0 : l.filter((p) => p.selected).map((p) => p.label), h = l == null ? void 0 : l.filter((p) => p.selected).map((p) => p.id);
2470
- let m = /* @__PURE__ */ c.jsx("span", { children: s });
2471
- return f && f.length > 1 ? m = /* @__PURE__ */ c.jsx("span", { children: `${f.length} items selected` }) : f && f.length === 1 && (m = /* @__PURE__ */ c.jsx("span", { children: f[0] })), /* @__PURE__ */ c.jsxs(
2472
- cr,
2473
- {
2474
- type: "button",
2475
- name: o,
2476
- value: h,
2477
- role: "combobox",
2478
- "aria-haspopup": "listbox",
2479
- "aria-expanded": e,
2480
- "aria-controls": r,
2481
- id: n,
2482
- onClick: t,
2483
- disabled: i,
2484
- "aria-required": d,
2485
- $theme: u,
2486
- children: [
2487
- m,
2488
- e ? /* @__PURE__ */ c.jsx(Jt, {}) : /* @__PURE__ */ c.jsx(Xt, {})
2489
- ]
2490
- }
2491
- );
2492
- }, Hs = ({ value: e, onSelect: t, theme: n }) => {
2493
- const { id: r, label: o, selected: s } = e, i = (d) => (l) => {
2494
- switch (l.key) {
2495
- case " ":
2496
- case "SpaceBar":
2497
- case "Enter":
2498
- l.preventDefault(), t(d);
2499
- break;
2500
- }
2501
- };
2502
- return /* @__PURE__ */ c.jsxs(
2503
- Bs,
2504
- {
2505
- id: r,
2506
- role: "option",
2507
- "aria-selected": s,
2508
- tabIndex: 0,
2509
- onKeyDown: i(r),
2510
- onClick: () => t(r),
2511
- $theme: n,
2512
- $selected: s,
2513
- children: [
2514
- s ? /* @__PURE__ */ c.jsx(It, {}) : /* @__PURE__ */ c.jsx(At, {}),
2515
- /* @__PURE__ */ c.jsx("span", { children: o })
2516
- ]
2517
- }
2518
- );
2519
- }, Fs = ({ options: e, opened: t, onClose: n, onSelect: r, dropdownId: o, theme: s }) => /* @__PURE__ */ c.jsx(
2520
- lr,
2521
- {
2522
- $opened: t,
2523
- role: "listbox",
2524
- id: o,
2525
- tabIndex: -1,
2526
- onKeyDown: (i) => sr({ e: i, options: e, onClose: n }),
2527
- $theme: s,
2528
- children: e.map((i) => /* @__PURE__ */ c.jsx(Hs, { value: i, onSelect: () => r(i.id), theme: s }, i.id))
2529
- }
2530
- );
2531
- function Gs({
2532
- name: e,
2533
- options: t,
2534
- initialValues: n,
2535
- defaultValue: r
2536
- }) {
2537
- return t.map((o) => {
2538
- let s = !1;
2539
- return n && (n != null && n[e]) && Array.isArray(n[e]) && n[e].find((d) => d === o.id || (d == null ? void 0 : d.id) === o.id) && (s = !0), !(n != null && n[e]) && Array.isArray(r) && r.find((d) => d === o.id) && (s = !0), { ...o, selected: s };
2540
- });
2541
- }
2542
- const An = (e) => e.filter((t) => t.selected).map((t) => t.id), Ws = (e, t) => {
2543
- const n = e.find((r) => r.id === t);
2544
- return e.map((r) => r.id === t ? { ...r, selected: !(n != null && n.selected) } : r);
2545
- };
2546
- function Us({
2547
- name: e,
2548
- defaultValue: t,
2549
- onChange: n,
2550
- options: r
2551
- }) {
2552
- const [o, s] = B(!1), { onChangeFormInput: i, initialValues: d } = xe(Re), l = Gs({ name: e, options: r, initialValues: d, defaultValue: t }), [u, f] = B(l), h = () => s(!1), m = () => s(!o), p = ($) => {
2553
- const w = Ws(u, $);
2554
- f(w), n == null || n(w), i == null || i({ name: e, value: An(w) });
2555
- }, g = tt(() => {
2556
- s(!1), f(l), i == null || i({ name: e, value: An(l) });
2557
- }, [e]);
2558
- return nt(g), {
2559
- handleClose: h,
2560
- handleToggle: m,
2561
- handleSelect: p,
2562
- opened: o,
2563
- values: u
2564
- };
2565
- }
2566
- const ua = ({
2567
- options: e,
2568
- name: t,
2569
- label: n,
2570
- required: r = !1,
2571
- placeholder: o = "Not selected",
2572
- disabled: s = !1,
2573
- onChange: i,
2574
- defaultValue: d,
2575
- id: l,
2576
- ...u
2577
- }) => {
2578
- const f = $e(null), { elementId: h, dropdownId: m } = ve(l), p = q(), { handleClose: g, handleSelect: $, handleToggle: w, opened: v, values: S } = Us({
2579
- name: t,
2580
- options: e,
2581
- defaultValue: d,
2582
- onChange: i
2583
- });
2584
- return jt({ ref: f, onClickOutsideHandler: g }), Et({ keyCode: "Escape", ref: f, onKeyPress: g }), /* @__PURE__ */ c.jsxs(ar, { ref: f, $theme: p, ...u, children: [
2585
- /* @__PURE__ */ c.jsx(Ye, { label: n, required: r, inputId: h, theme: p }),
2586
- /* @__PURE__ */ c.jsx(
2587
- Ls,
2588
- {
2589
- name: t,
2590
- opened: v,
2591
- comboboxId: h,
2592
- dropdownId: m,
2593
- onClick: w,
2594
- values: S,
2595
- placeholder: o,
2596
- disabled: s,
2597
- required: r,
2598
- theme: p
2599
- }
2600
- ),
2601
- /* @__PURE__ */ c.jsx(
2602
- Fs,
2603
- {
2604
- theme: p,
2605
- options: S,
2606
- opened: v,
2607
- onClose: g,
2608
- dropdownId: m,
2609
- onSelect: $
2610
- }
2611
- )
2612
- ] });
2613
- };
2614
- function Ys({
2615
- name: e,
2616
- initialValues: t,
2617
- defaultValue: n
2618
- }) {
2619
- return t && t[e] ? Number(t[e]) : n && typeof n == "number" ? n : 0;
2620
- }
2621
- function Vs({
2622
- value: e,
2623
- required: t,
2624
- validator: n,
2625
- maxValue: r,
2626
- minValue: o
2627
- }) {
2628
- return t && !n && e === void 0 ? !1 : n && typeof n == "function" ? n(e) : r && o && e && !n ? e <= r && e >= o : !0;
2629
- }
2630
- function Ks({
2631
- name: e,
2632
- defaultValue: t,
2633
- onChange: n,
2634
- onSpinButtonClick: r,
2635
- min: o,
2636
- max: s,
2637
- step: i,
2638
- required: d,
2639
- validator: l
2640
- }) {
2641
- const { onChangeFormInput: u, initialValues: f } = xe(Re), h = Ys({ initialValues: f, defaultValue: t, name: e }), m = s ? Number(s) : Number.MAX_SAFE_INTEGER, p = o ? Number(o) : Number.MIN_SAFE_INTEGER, [g, $] = B(h), [w, v] = B(!0), S = (x) => {
2642
- $(x);
2643
- const D = Vs({ value: x, required: d, validator: l, maxValue: m, minValue: p });
2644
- v(D), u == null || u({ name: e, value: x, valid: D });
2645
- }, E = (x) => {
2646
- const D = Number(x.target.value);
2647
- S(D), n == null || n(x);
2648
- }, _ = () => {
2649
- S(g + i), r == null || r(g + i);
2650
- }, z = () => {
2651
- S(g - i), r == null || r(g - i);
2652
- }, C = tt(() => {
2653
- $(h), v(!0), u == null || u({ name: e, value: h, valid: !0 });
2654
- }, [e]);
2655
- return nt(C), {
2656
- handleChange: E,
2657
- value: g,
2658
- valid: w,
2659
- minValue: p,
2660
- maxValue: m,
2661
- increment: _,
2662
- decrement: z
2663
- };
2664
- }
2665
- const qs = k.div`
2666
- display: flex;
2667
- flex-direction: column;
2668
- gap: ${(e) => e.$theme.gapMedium};
2669
- position: relative;
2670
-
2671
- & > div:nth-child(2) {
2672
- display: flex;
2673
- gap: ${(e) => e.$theme.gapMedium};
2674
- align-items: center;
2675
- border: ${(e) => e.$theme.borderLight};
2676
- border-radius: ${(e) => e.$theme.blockBorderRadius};
2677
- padding: ${(e) => e.$theme.gapMedium};
2678
- background-color: ${(e) => e.$theme.backgroundColorBase};
2679
-
2680
- &:has(input:focus) {
2681
- border: ${(e) => e.$theme.borderOutline};
2682
- }
2683
-
2684
- &:has(input[aria-invalid='true']) {
2685
- border: ${(e) => e.$theme.borderAccent};
2686
- }
2687
-
2688
- &:has(input[disabled]) {
2689
- pointer-events: none;
2690
- opacity: 0.5;
2691
- }
2692
-
2693
- & > span:nth-child(2) {
2694
- display: flex;
2695
- align-items: center;
2696
- }
2697
- }
2698
-
2699
- & input {
2700
- font-size: ${(e) => e.$theme.fontSizeBase};
2701
- padding: 0;
2702
- border: none;
2703
- font-family: ${(e) => e.$theme.fontFamilyCore};
2704
- color: ${(e) => e.$theme.fontColorBase};
2705
- display: inline-block;
2706
- background: transparent;
2707
- white-space: nowrap;
2708
- text-overflow: ellipsis;
2709
- overflow: hidden;
2710
- flex-grow: 1;
2711
- min-width: 0;
2712
-
2713
- &:focus-visible {
2714
- outline: none;
2715
- }
2716
-
2717
- &::-webkit-outer-spin-button,
2718
- &::-webkit-inner-spin-button {
2719
- -webkit-appearance: none;
2720
- margin: 0;
2721
- }
2722
-
2723
- &[type='number'] {
2724
- -moz-appearance: textfield;
2725
- }
2726
- }
2727
- `, fa = ({
2728
- name: e,
2729
- label: t,
2730
- errorMessage: n,
2731
- onChange: r,
2732
- onBlur: o,
2733
- onFocus: s,
2734
- onSpinButtonClick: i,
2735
- validator: d,
2736
- min: l,
2737
- max: u,
2738
- id: f,
2739
- tabIndex: h,
2740
- disabled: m = !1,
2741
- required: p = !1,
2742
- readOnly: g = !1,
2743
- hasSpinButtons: $ = !0,
2744
- defaultValue: w = 0,
2745
- step: v = 1,
2746
- ...S
2747
- }) => {
2748
- const { elementId: E, errorId: _ } = ve(f), z = q(), { value: C, valid: x, handleChange: D, increment: V, decrement: oe, minValue: te, maxValue: se } = Ks({
2749
- name: e,
2750
- defaultValue: w,
2751
- min: l,
2752
- max: u,
2753
- onChange: r,
2754
- required: p,
2755
- validator: d,
2756
- step: v,
2757
- onSpinButtonClick: i
2758
- });
2759
- return /* @__PURE__ */ c.jsxs(qs, { $theme: z, ...S, children: [
2760
- /* @__PURE__ */ c.jsx(Ye, { label: t, required: p, inputId: E, theme: z }),
2761
- /* @__PURE__ */ c.jsxs("div", { children: [
2762
- /* @__PURE__ */ c.jsx(
2763
- "input",
2764
- {
2765
- id: E,
2766
- name: e,
2767
- type: "number",
2768
- disabled: m,
2769
- required: p,
2770
- readOnly: g,
2771
- placeholder: "0",
2772
- "aria-invalid": !x,
2773
- "aria-errormessage": _,
2774
- value: C.toString(),
2775
- onChange: D,
2776
- min: te,
2777
- max: se,
2778
- step: v,
2779
- onBlur: o,
2780
- onFocus: s,
2781
- tabIndex: h
2782
- }
2783
- ),
2784
- $ && /* @__PURE__ */ c.jsxs("span", { children: [
2785
- /* @__PURE__ */ c.jsx(
2786
- yt,
2787
- {
2788
- onClick: oe,
2789
- label: `Decrement value for ${t}`,
2790
- icon: j.ChevronLeft,
2791
- disabled: m,
2792
- theme: z
2793
- }
2794
- ),
2795
- /* @__PURE__ */ c.jsx(
2796
- yt,
2797
- {
2798
- onClick: V,
2799
- label: `Increment value for ${t}`,
2800
- icon: j.ChevronRight,
2801
- disabled: m,
2802
- theme: z
2803
- }
2804
- )
2805
- ] })
2806
- ] }),
2807
- /* @__PURE__ */ c.jsx(nr, { errorId: _, message: n, visible: !x, theme: z })
2808
- ] });
2809
- }, Xs = ({
2810
- opened: e,
2811
- onClick: t,
2812
- comboboxId: n,
2813
- dropdownId: r,
2814
- selected: o,
2815
- name: s,
2816
- placeholder: i,
2817
- disabled: d,
2818
- required: l,
2819
- theme: u
2820
- }) => /* @__PURE__ */ c.jsxs(
2821
- cr,
2822
- {
2823
- type: "button",
2824
- name: s,
2825
- value: o == null ? void 0 : o.id,
2826
- role: "combobox",
2827
- "aria-haspopup": "listbox",
2828
- "aria-expanded": e,
2829
- "aria-controls": r,
2830
- id: n,
2831
- onClick: t,
2832
- disabled: d,
2833
- "aria-required": l,
2834
- $theme: u,
2835
- children: [
2836
- o != null && o.label ? /* @__PURE__ */ c.jsx("span", { children: o == null ? void 0 : o.label }) : /* @__PURE__ */ c.jsx("span", { children: i }),
2837
- e ? /* @__PURE__ */ c.jsx(Jt, {}) : /* @__PURE__ */ c.jsx(Xt, {})
2838
- ]
2839
- }
2840
- );
2841
- function Zt(e) {
2842
- return /* @__PURE__ */ c.jsxs("svg", { viewBox: "0 0 512 512", fill: "currentColor", height: "1em", width: "1em", role: "img", ...e, children: [
2843
- /* @__PURE__ */ c.jsx("title", { children: "Check Mark" }),
2844
- /* @__PURE__ */ c.jsx("path", { d: "M470.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L192 338.7l233.4-233.3c12.5-12.5 32.8-12.5 45.3 0z" })
2845
- ] });
2846
- }
2847
- const Js = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2848
- __proto__: null,
2849
- default: Zt
2850
- }, Symbol.toStringTag, { value: "Module" })), Zs = ({ value: e, selected: t, onSelect: n, onClear: r, theme: o }) => {
2851
- const { id: s, label: i } = e, d = (u) => {
2852
- t ? r() : n(u);
2853
- }, l = (u) => (f) => {
2854
- switch (f.key) {
2855
- case " ":
2856
- case "SpaceBar":
2857
- case "Enter":
2858
- f.preventDefault(), d(u);
2859
- break;
2860
- }
2861
- };
2862
- return /* @__PURE__ */ c.jsxs(
2863
- dr,
2864
- {
2865
- id: s,
2866
- role: "option",
2867
- "aria-selected": t,
2868
- tabIndex: 0,
2869
- onKeyDown: l(s),
2870
- onClick: () => d(s),
2871
- $theme: o,
2872
- $selected: t,
2873
- children: [
2874
- /* @__PURE__ */ c.jsx("span", { children: i }),
2875
- t && /* @__PURE__ */ c.jsx(Zt, {})
2876
- ]
2877
- }
2878
- );
2879
- }, Qs = ({
2880
- options: e,
2881
- opened: t,
2882
- onClose: n,
2883
- onSelect: r,
2884
- dropdownId: o,
2885
- comboboxId: s,
2886
- selected: i,
2887
- onClear: d,
2888
- theme: l
2889
- }) => {
2890
- const u = (f) => {
2891
- r(f), n(), et(s);
2892
- };
2893
- return /* @__PURE__ */ c.jsx(
2894
- lr,
2895
- {
2896
- role: "listbox",
2897
- id: o,
2898
- tabIndex: -1,
2899
- onKeyDown: (f) => sr({ e: f, options: e, onClose: n }),
2900
- $opened: t,
2901
- $theme: l,
2902
- children: e.map((f) => /* @__PURE__ */ c.jsx(
2903
- Zs,
2904
- {
2905
- value: f,
2906
- onSelect: () => u(f.id),
2907
- onClear: d,
2908
- selected: f.id === (i == null ? void 0 : i.id),
2909
- theme: l
2910
- },
2911
- f.id
2912
- ))
2913
- }
2914
- );
2915
- };
2916
- function ei({
2917
- name: e,
2918
- options: t,
2919
- initialValues: n,
2920
- defaultValue: r
2921
- }) {
2922
- var s;
2923
- let o;
2924
- return n && n[e] && (o = ((s = n[e]) == null ? void 0 : s.id) ?? n[e]), !(n != null && n[e]) && r && typeof r == "string" && (o = r), t.find((i) => i.id === o);
2925
- }
2926
- function ti({
2927
- name: e,
2928
- defaultValue: t,
2929
- onChange: n,
2930
- options: r
2931
- }) {
2932
- const { onChangeFormInput: o, initialValues: s } = xe(Re), i = ei({ name: e, options: r, defaultValue: t, initialValues: s }), [d, l] = B(!1), [u, f] = B(i), h = () => l(!1), m = () => l(!d), p = (w) => {
2933
- const v = r.find((S) => S.id === w);
2934
- f(v), n == null || n(v), o == null || o({ name: e, value: v == null ? void 0 : v.id });
2935
- }, g = () => {
2936
- f(void 0), n == null || n(void 0);
2937
- }, $ = tt(() => {
2938
- l(!1), f(i), o == null || o({ name: e, value: i == null ? void 0 : i.id });
2939
- }, [e]);
2940
- return nt($), {
2941
- selected: u,
2942
- opened: d,
2943
- handleClear: g,
2944
- handleClose: h,
2945
- handleToggle: m,
2946
- handleSelect: p
2947
- };
2948
- }
2949
- const ha = ({
2950
- options: e,
2951
- onChange: t,
2952
- name: n,
2953
- label: r,
2954
- defaultValue: o,
2955
- id: s,
2956
- placeholder: i = "Not selected",
2957
- required: d = !1,
2958
- disabled: l = !1,
2959
- ...u
2960
- }) => {
2961
- const f = $e(null), h = q(), { elementId: m, dropdownId: p } = ve(s), { handleClear: g, handleClose: $, handleSelect: w, handleToggle: v, selected: S, opened: E } = ti({
2962
- options: e,
2963
- onChange: t,
2964
- defaultValue: o,
2965
- name: n
2966
- });
2967
- return jt({ ref: f, onClickOutsideHandler: $ }), Et({ keyCode: "Escape", ref: f, onKeyPress: $ }), /* @__PURE__ */ c.jsxs(ar, { ref: f, $theme: h, ...u, children: [
2968
- /* @__PURE__ */ c.jsx(Ye, { label: r, required: d, inputId: m, theme: h }),
2969
- /* @__PURE__ */ c.jsx(
2970
- Xs,
2971
- {
2972
- name: n,
2973
- opened: E,
2974
- comboboxId: m,
2975
- dropdownId: p,
2976
- onClick: v,
2977
- selected: S,
2978
- placeholder: i,
2979
- disabled: l,
2980
- required: d,
2981
- theme: h
2982
- }
2983
- ),
2984
- /* @__PURE__ */ c.jsx(
2985
- Qs,
2986
- {
2987
- options: e,
2988
- selected: S,
2989
- opened: E,
2990
- onClose: $,
2991
- dropdownId: p,
2992
- comboboxId: m,
2993
- onSelect: w,
2994
- onClear: g,
2995
- theme: h
2996
- }
2997
- )
2998
- ] });
2999
- };
3000
- function ni({
3001
- value: e,
3002
- required: t,
3003
- validator: n
3004
- }) {
3005
- return t && !n && !e.length ? !1 : n && typeof n == "function" ? n(e) : n && typeof n == "object" ? new RegExp(n.regexp, n == null ? void 0 : n.flags).test(e) : !0;
3006
- }
3007
- function ri({
3008
- name: e,
3009
- initialValues: t,
3010
- defaultValue: n
3011
- }) {
3012
- return t && (t != null && t[e]) ? t[e].toString() : n && typeof n == "string" ? n : "";
3013
- }
3014
- function oi({
3015
- name: e,
3016
- defaultValue: t,
3017
- onChange: n,
3018
- onClear: r,
3019
- required: o,
3020
- validator: s
3021
- }) {
3022
- const { onChangeFormInput: i, initialValues: d } = xe(Re), l = ri({ initialValues: d, defaultValue: t, name: e }), [u, f] = B(l), [h, m] = B(!0), [p, g] = B(!1), $ = (E) => {
3023
- const _ = E.target.value, z = ni({ value: _, required: o, validator: s });
3024
- f(_), m(z), i == null || i({ name: e, value: _, valid: z }), n == null || n(E);
3025
- }, w = () => {
3026
- f(""), m(!0), i == null || i({ name: e, value: "", valid: !0 }), r == null || r();
3027
- }, v = tt(() => {
3028
- f(l), m(!0), i == null || i({ name: e, value: l, valid: !0 });
3029
- }, [e]), S = () => {
3030
- g(!p);
3031
- };
3032
- return nt(v), {
3033
- value: u,
3034
- valid: h,
3035
- passwordShown: p,
3036
- handleChange: $,
3037
- handleClear: w,
3038
- togglePassword: S
3039
- };
3040
- }
3041
- const si = k.div`
3042
- display: flex;
3043
- flex-direction: column;
3044
- gap: ${(e) => e.$theme.gapMedium};
3045
- position: relative;
3046
-
3047
- & > div:nth-child(2) {
3048
- display: flex;
3049
- gap: ${(e) => e.$theme.gapMedium};
3050
- align-items: center;
3051
- border: ${(e) => e.$theme.borderLight};
3052
- border-radius: ${(e) => e.$theme.blockBorderRadius};
3053
- padding: ${(e) => e.$theme.gapMedium};
3054
- background-color: ${(e) => e.$theme.backgroundColorBase};
3055
-
3056
- &:has(input:focus) {
3057
- border: ${(e) => e.$theme.borderOutline};
3058
- }
3059
-
3060
- &:has(input[aria-invalid='true']) {
3061
- border: ${(e) => e.$theme.borderAccent};
3062
- }
3063
-
3064
- &:has(input[disabled]) {
3065
- pointer-events: none;
3066
- opacity: 0.5;
3067
- }
3068
-
3069
- & > span:nth-child(2) {
3070
- display: flex;
3071
- gap: ${(e) => e.$theme.gapSmall};
3072
- align-items: center;
3073
- }
3074
- }
3075
-
3076
- & input {
3077
- font-size: ${(e) => e.$theme.fontSizeBase};
3078
- padding: 0;
3079
- border: none;
3080
- font-family: ${(e) => e.$theme.fontFamilyCore};
3081
- color: ${(e) => e.$theme.fontColorBase};
3082
- display: inline-block;
3083
- background: transparent;
3084
- white-space: nowrap;
3085
- text-overflow: ellipsis;
3086
- overflow: hidden;
3087
- flex-grow: 1;
3088
- min-width: 0;
3089
-
3090
- &:focus-visible {
3091
- outline: none;
3092
- }
3093
-
3094
- &:placeholder-shown + span {
3095
- display: none !important;
3096
- }
3097
- }
3098
- `, pa = ({
3099
- name: e,
3100
- label: t,
3101
- errorMessage: n,
3102
- defaultValue: r,
3103
- onChange: o,
3104
- onBlur: s,
3105
- onFocus: i,
3106
- onClear: d,
3107
- validator: l,
3108
- maxLength: u,
3109
- id: f,
3110
- tabIndex: h,
3111
- placeholder: m = "Type here...",
3112
- disabled: p = !1,
3113
- required: g = !1,
3114
- clearable: $ = !0,
3115
- readOnly: w = !1,
3116
- autoComplete: v = "off",
3117
- type: S = "text",
3118
- ...E
3119
- }) => {
3120
- const { value: _, valid: z, handleChange: C, handleClear: x, passwordShown: D, togglePassword: V } = oi({
3121
- defaultValue: r,
3122
- name: e,
3123
- onChange: o,
3124
- onClear: d,
3125
- required: g,
3126
- validator: l
3127
- }), { elementId: oe, errorId: te } = ve(f), se = S === "password", X = q();
3128
- return /* @__PURE__ */ c.jsxs(si, { $theme: X, ...E, children: [
3129
- /* @__PURE__ */ c.jsx(Ye, { label: t, required: g, inputId: oe, theme: X }),
3130
- /* @__PURE__ */ c.jsxs("div", { children: [
3131
- /* @__PURE__ */ c.jsx(
3132
- "input",
3133
- {
3134
- id: oe,
3135
- name: e,
3136
- type: D ? "text" : S,
3137
- disabled: p,
3138
- placeholder: m,
3139
- required: g,
3140
- readOnly: w,
3141
- autoComplete: v,
3142
- "aria-invalid": !z,
3143
- "aria-errormessage": te,
3144
- "aria-readonly": w,
3145
- value: _,
3146
- onChange: C,
3147
- maxLength: u,
3148
- onBlur: s,
3149
- onFocus: i,
3150
- tabIndex: h
3151
- }
3152
- ),
3153
- /* @__PURE__ */ c.jsxs("span", { children: [
3154
- $ && /* @__PURE__ */ c.jsx(
3155
- yt,
3156
- {
3157
- onClick: x,
3158
- label: `Clear input for ${t}`,
3159
- icon: j.Remove,
3160
- disabled: p,
3161
- theme: X
3162
- }
3163
- ),
3164
- se && /* @__PURE__ */ c.jsx(
3165
- yt,
3166
- {
3167
- onClick: V,
3168
- label: "Toggle password visibility",
3169
- icon: D ? j.Hide : j.Show,
3170
- disabled: p,
3171
- theme: X
3172
- }
3173
- )
3174
- ] })
3175
- ] }),
3176
- /* @__PURE__ */ c.jsx(nr, { errorId: te, message: n, visible: !z, theme: X })
3177
- ] });
3178
- }, ii = k.div`
3179
- z-index: ${(e) => e.$theme.zIndexModal};
3180
- background-color: ${(e) => e.$theme.backgroundColorBase};
3181
- box-shadow: ${(e) => e.$theme.boxShadow};
3182
- font-family: ${(e) => e.$theme.fontFamilyCore};
3183
- color: ${(e) => e.$theme.fontColorBase};
3184
- width: 100%;
3185
- height: 90%;
3186
- position: absolute;
3187
- bottom: 0;
3188
- left: 0;
3189
- border-top-left-radius: ${(e) => e.$theme.blockBorderRadius};
3190
- border-top-right-radius: ${(e) => e.$theme.blockBorderRadius};
3191
- ${Ue}
3192
-
3193
- @media ${Mo.landscapeTablets} {
3194
- width: fit-content;
3195
- height: fit-content;
3196
- position: relative;
3197
- min-width: 40%;
3198
- max-width: 90%;
3199
- max-height: 90%;
3200
- border-bottom-left-radius: ${(e) => e.$theme.blockBorderRadius};
3201
- border-bottom-right-radius: ${(e) => e.$theme.blockBorderRadius};
3202
-
3203
- header {
3204
- font-size: ${(e) => e.$theme.fontSizeHeader};
3205
- }
3206
- }
3207
- `, ai = k.div`
3208
- position: fixed;
3209
- top: 0;
3210
- left: 0;
3211
- width: 100%;
3212
- height: 100%;
3213
- z-index: inherit;
3214
- display: flex;
3215
- justify-content: center;
3216
- align-items: center;
3217
- background-color: ${(e) => e.$theme.backgroundColorTransparent};
3218
- ${Ue}
3219
-
3220
- ${(e) => e.$isClosing && tr}
3221
- `, ci = k.header`
3222
- font-size: 1.6rem;
3223
- font-weight: bold;
3224
- display: flex;
3225
- justify-content: space-between;
3226
- align-items: center;
3227
- gap: ${(e) => e.$theme.gapBig};
3228
- padding: ${(e) => e.$theme.gapBig};
3229
- border-bottom: ${(e) => e.$theme.borderBase};
3230
- color: ${(e) => e.$theme.fontColorBase};
3231
- `, li = k.div`
3232
- padding: ${(e) => e.$theme.gapBig};
3233
- font-size: ${(e) => e.$theme.fontSizeBase};
3234
- `, di = ({ title: e, onClose: t, theme: n }) => /* @__PURE__ */ c.jsxs(ci, { $theme: n, children: [
3235
- e,
3236
- /* @__PURE__ */ c.jsx($t, { icon: j.Cancel, view: be.Icon, label: "Close modal window", onClick: t })
3237
- ] }), ui = ({ title: e, onClose: t, isOpened: n, children: r, theme: o, ...s }) => {
3238
- const i = $e(null);
3239
- return Cs({ modalRef: i, isOpened: n }), Et({ keyCode: "Escape", ref: i, onKeyPress: t }), /* @__PURE__ */ c.jsxs(ii, { ref: i, role: "dialog", "aria-modal": "true", $theme: o, ...s, children: [
3240
- /* @__PURE__ */ c.jsx(di, { title: e, onClose: t, theme: o }),
3241
- /* @__PURE__ */ c.jsx(li, { $theme: o, children: r })
3242
- ] });
3243
- }, ma = ({ isOpened: e, onClose: t, title: n, children: r, ...o }) => {
3244
- const s = ir(e), i = s && !e, d = q();
3245
- return s ? /* @__PURE__ */ c.jsx(Qt, { children: /* @__PURE__ */ c.jsx(ai, { $isClosing: i, $theme: d, children: /* @__PURE__ */ c.jsx(ui, { title: n, onClose: t, isOpened: e, ...o, theme: d, children: r }) }) }) : null;
3246
- }, fi = ({ id: e }) => {
3247
- const [t, n] = B(!1), r = $e(null), o = $e(null), { top: s, left: i } = Es({ wrapperRef: r, tooltipRef: o, isOpened: t }), { elementId: d } = ve(e), l = () => n(!1), u = () => n(!0), f = () => n(!t), h = (m) => {
3248
- m.preventDefault(), f();
3249
- };
3250
- return Et({ keyCode: "Escape", ref: o, onKeyPress: l }), jt({ ref: o, onClickOutsideHandler: l, dependentRef: r }), {
3251
- elementId: d,
3252
- openTooltip: u,
3253
- closeTooltip: l,
3254
- toggleTooltip: f,
3255
- handleContextMenu: h,
3256
- top: s,
3257
- left: i,
3258
- isOpened: t,
3259
- wrapperRef: r,
3260
- tooltipRef: o
3261
- };
3262
- }, hi = k.div`
3263
- position: absolute;
3264
- left: 0;
3265
- top: 0;
3266
- z-index: ${(e) => e.$theme.zIndexPopup};
3267
- background-color: ${(e) => e.$theme.backgroundColorBase};
3268
- border: ${(e) => e.$theme.borderLight};
3269
- color: ${(e) => e.$theme.fontColorBase};
3270
- padding: ${(e) => e.$theme.gapMedium};
3271
- font-size: ${(e) => e.$theme.fontSizeSmall};
3272
- font-family: ${(e) => e.$theme.fontFamilyCore};
3273
- border-radius: ${(e) => e.$theme.blockBorderRadius};
3274
- box-shadow: ${(e) => e.$theme.boxShadow};
3275
- pointer-events: none;
3276
- white-space: nowrap;
3277
-
3278
- ${Ue}
3279
- `, pi = ({
3280
- children: e,
3281
- tooltipContent: t,
3282
- containerTag: n = or.Span,
3283
- visibleOn: r = "hover",
3284
- id: o,
3285
- style: s,
3286
- ...i
3287
- }) => {
3288
- const d = n, l = q(), { openTooltip: u, closeTooltip: f, toggleTooltip: h, handleContextMenu: m, elementId: p, top: g, left: $, isOpened: w, wrapperRef: v, tooltipRef: S } = fi({ id: o });
3289
- return /* @__PURE__ */ c.jsxs(
3290
- d,
3291
- {
3292
- style: { position: "relative", cursor: "pointer" },
3293
- onClick: r === "click" ? h : void 0,
3294
- onMouseOver: r === "hover" ? u : void 0,
3295
- onMouseLeave: r === "hover" ? f : void 0,
3296
- onFocus: r === "focus" ? u : void 0,
3297
- onBlur: r === "focus" ? f : void 0,
3298
- onContextMenu: r === "contextmenu" ? (E) => m(E) : void 0,
3299
- tabIndex: 0,
3300
- ref: v,
3301
- "aria-describedby": p,
3302
- children: [
3303
- e,
3304
- w && /* @__PURE__ */ c.jsx(Qt, { children: /* @__PURE__ */ c.jsx(hi, { style: { ...s, top: g, left: $ }, ref: S, role: "tooltip", id: p, $theme: l, ...i, children: t }) })
3305
- ]
3306
- }
3307
- );
3308
- };
3309
- function mi(e) {
3310
- return e ? Object.keys(e).map((t) => [t, !0]) : [];
3311
- }
3312
- function gi(e, t) {
3313
- return (t == null ? void 0 : t.valid) === void 0 ? e : e.map((n) => n[0] !== t.name ? n : [n[0], !!(t != null && t.valid)]);
3314
- }
3315
- function bi(e) {
3316
- return e.every((t) => t[1]);
3317
- }
3318
- function yi({
3319
- initialValues: e,
3320
- onReset: t,
3321
- onSubmit: n,
3322
- onClickSubmit: r
3323
- }) {
3324
- const [o, s] = B(e), [i, d] = B(mi(e)), [l, u] = B(0);
3325
- return {
3326
- handleInputChange: (p) => {
3327
- const g = { ...o, [p.name]: p.value };
3328
- s(g), d(gi(i, p));
3329
- },
3330
- handleSubmit: (p) => {
3331
- p.preventDefault();
3332
- const $ = { ...Object.fromEntries(new FormData(p.target)), ...o };
3333
- n == null || n(p), r == null || r($);
3334
- },
3335
- handleReset: (p) => {
3336
- t == null || t(p), s(e), u(l + 1);
3337
- },
3338
- resetSignal: l,
3339
- valid: bi(i)
3340
- };
3341
- }
3342
- const $i = k.form`
3343
- display: grid;
3344
- align-items: end;
3345
- gap: ${(e) => e.$theme.gapMedium};
3346
- font-size: ${(e) => e.$theme.fontSizeBase};
3347
- font-family: ${(e) => e.$theme.fontFamilyCore};
3348
-
3349
- ${({ $columns: e }) => `
3350
- grid-template-columns: repeat(${e}, 1fr);
3351
- grid-template-rows: auto;
3352
- `}
3353
- `, xi = k.div`
3354
- display: flex;
3355
- align-items: center;
3356
- justify-content: space-between;
3357
- padding-top: 1rem;
3358
-
3359
- ${({ $columns: e }) => `
3360
- grid-column: 1 / ${e + 1};
3361
- `}
3362
- `, ga = ({
3363
- children: e,
3364
- initialValues: t,
3365
- onReset: n,
3366
- onSubmit: r,
3367
- onClickSubmit: o,
3368
- columns: s = 1,
3369
- hasReset: i = !0,
3370
- ...d
3371
- }) => {
3372
- const { handleInputChange: l, handleSubmit: u, handleReset: f, resetSignal: h, valid: m } = yi({
3373
- initialValues: t,
3374
- onReset: n,
3375
- onSubmit: r,
3376
- onClickSubmit: o
3377
- }), p = q();
3378
- return /* @__PURE__ */ c.jsx($i, { onSubmit: u, onReset: f, $columns: s, $theme: p, ...d, children: /* @__PURE__ */ c.jsxs(Re.Provider, { value: { onChangeFormInput: l, initialValues: t, resetSignal: h }, children: [
3379
- e,
3380
- /* @__PURE__ */ c.jsxs(xi, { $columns: s, children: [
3381
- i && /* @__PURE__ */ c.jsx($t, { type: "reset", text: "Reset", icon: j.Clear, view: be.Flat }),
3382
- /* @__PURE__ */ c.jsx($t, { type: "submit", text: "Submit", icon: j.Forward, extended: !i, disabled: !m })
3383
- ] })
3384
- ] }) });
3385
- }, vi = k.table`
3386
- border-collapse: collapse;
3387
- `, wi = k.thead`
3388
- font-family: ${(e) => e.$theme.fontFamilyCore};
3389
- color: ${(e) => e.$theme.fontColorBase};
3390
- font-size: ${(e) => e.$theme.fontSizeBase};
3391
- `, Si = k.tbody`
3392
- font-family: ${(e) => e.$theme.fontFamilyCore};
3393
- color: ${(e) => e.$theme.fontColorBase};
3394
- `, ur = k.th`
3395
- padding: ${(e) => e.$theme.gapMedium};
3396
- text-align: left;
3397
- `, ki = k.tr`
3398
- font-weight: bold;
3399
- border-top: ${(e) => e.$theme.borderLight};
3400
- border-bottom: ${(e) => e.$theme.borderLight};
3401
- background-color: ${(e) => e.$theme.backgroundColorBase};
3402
- `, fr = k.td`
3403
- padding: ${(e) => e.$theme.gapMedium};
3404
- `, Ci = k.caption`
3405
- font-family: ${(e) => e.$theme.fontFamilyCore};
3406
- color: ${(e) => e.$theme.fontColorBase};
3407
- padding: ${(e) => e.$theme.gapMedium};
3408
- font-weight: bold;
3409
- `, ji = k.tr`
3410
- border-bottom: ${(e) => e.$theme.borderLight};
3411
-
3412
- ${(e) => e.$selected && `
3413
- background-color: ${e.$theme.backgroundColorLight};
3414
- `}
3415
- `, _n = k.col`
3416
- border-right: ${(e) => e.$theme.borderLight};
3417
-
3418
- ${(e) => e.$isFirst && `border-left: ${e.$theme.borderLight};`}
3419
- ${(e) => e.$highlighted && `background-color: ${e.$theme.backgroundColorLight};`}
3420
- `, Ei = k.div`
3421
- display: flex;
3422
- gap: ${(e) => e.$theme.gapSmall};
3423
- padding: ${(e) => e.$theme.gapSmall} 0;
3424
- position: relative;
3425
- overflow: hidden;
3426
-
3427
- svg {
3428
- color: ${(e) => e.$checked ? e.$theme.fontColorBase : e.$theme.fontColorLight};
3429
- }
3430
-
3431
- label {
3432
- cursor: pointer;
3433
- gap: ${(e) => e.$theme.gapSmall};
3434
- font-size: ${(e) => e.$theme.fontSizeBase} !important;
3435
- &:hover,
3436
- &:active {
3437
- text-shadow: ${(e) => e.$theme.textShadow};
3438
- }
3439
- }
3440
-
3441
- ${(e) => e.$disabled && `
3442
- pointer-events: none;
3443
- opacity: 0.5;
3444
- `}
3445
- `, Ii = k.input`
3446
- position: absolute;
3447
- z-index: -1;
3448
- opacity: 0;
3449
- top: 4px;
3450
- left: 0;
3451
- margin: 0;
3452
-
3453
- &:focus-visible + label {
3454
- outline: ${(e) => e.$theme.borderOutline};
3455
- outline-offset: 2px;
3456
- }
3457
- `;
3458
- function Ai({
3459
- item: e,
3460
- columns: t,
3461
- renderDataItem: n
3462
- }) {
3463
- const r = [];
3464
- for (const o of t) {
3465
- let s;
3466
- n && e[o.field] ? s = n(e, o.field) : e[o.field] ? s = e[o.field].toString() : s = "", r.push(s);
3467
- }
3468
- return r;
3469
- }
3470
- const _i = ({ value: e, theme: t }) => /* @__PURE__ */ c.jsx(fr, { $theme: t, children: e }), hr = ({
3471
- name: e,
3472
- label: t,
3473
- disabled: n,
3474
- required: r = !1,
3475
- onChange: o,
3476
- checked: s = !1,
3477
- theme: i,
3478
- ...d
3479
- }) => {
3480
- const { elementId: l } = ve(d == null ? void 0 : d.id);
3481
- return /* @__PURE__ */ c.jsxs(Ei, { $disabled: !!n, $checked: s, $theme: i, children: [
3482
- /* @__PURE__ */ c.jsx(
3483
- Ii,
3484
- {
3485
- id: l,
3486
- name: e,
3487
- type: "checkbox",
3488
- disabled: n,
3489
- required: r,
3490
- checked: s,
3491
- onChange: o,
3492
- $theme: i
3493
- }
3494
- ),
3495
- /* @__PURE__ */ c.jsx(
3496
- Ye,
3497
- {
3498
- label: t,
3499
- required: r,
3500
- inputId: l,
3501
- isTextHidden: !0,
3502
- iconPosition: "left",
3503
- theme: i,
3504
- icon: s ? /* @__PURE__ */ c.jsx(It, {}) : /* @__PURE__ */ c.jsx(At, {})
3505
- }
3506
- )
3507
- ] });
3508
- }, zi = ({
3509
- rowId: e,
3510
- isRowSelected: t,
3511
- selectRowById: n,
3512
- deselectRowById: r,
3513
- disabled: o,
3514
- theme: s
3515
- }) => {
3516
- const i = (d) => {
3517
- const { checked: l } = d.target;
3518
- l ? n(e) : r(e);
3519
- };
3520
- return /* @__PURE__ */ c.jsx(fr, { $theme: s, children: /* @__PURE__ */ c.jsx(
3521
- hr,
3522
- {
3523
- theme: s,
3524
- label: "Select row",
3525
- onChange: i,
3526
- id: `select_row_${e}`,
3527
- checked: t,
3528
- disabled: o
3529
- }
3530
- ) });
3531
- }, Ri = ({ rowId: e, selectRowById: t, deselectRowById: n, selectable: r, values: o, selectedIds: s, disabled: i, theme: d }) => {
3532
- const l = s.includes(e);
3533
- return /* @__PURE__ */ c.jsxs(ji, { $selected: l, $theme: d, children: [
3534
- r && /* @__PURE__ */ c.jsx(
3535
- zi,
3536
- {
3537
- rowId: e,
3538
- selectRowById: t,
3539
- deselectRowById: n,
3540
- isRowSelected: l,
3541
- disabled: i,
3542
- theme: d
3543
- }
3544
- ),
3545
- o.map((u, f) => /* @__PURE__ */ c.jsx(_i, { value: u, theme: d }, `row_${f}`))
3546
- ] });
3547
- }, Ti = ({
3548
- selectRowById: e,
3549
- deselectRowById: t,
3550
- renderDataItem: n,
3551
- selectedIds: r,
3552
- selectable: o,
3553
- data: s,
3554
- columns: i,
3555
- theme: d
3556
- }) => /* @__PURE__ */ c.jsx(Si, { $theme: d, children: s.map((l) => {
3557
- const u = Ai({ item: l, columns: i, renderDataItem: n });
3558
- return /* @__PURE__ */ c.jsx(
3559
- Ri,
3560
- {
3561
- rowId: l.id,
3562
- disabled: l == null ? void 0 : l.disabled,
3563
- selectRowById: e,
3564
- deselectRowById: t,
3565
- selectable: o,
3566
- values: u,
3567
- selectedIds: r,
3568
- theme: d
3569
- },
3570
- l.id
3571
- );
3572
- }) }), Oi = ({
3573
- columns: e,
3574
- selectable: t,
3575
- theme: n
3576
- }) => /* @__PURE__ */ c.jsxs("colgroup", { children: [
3577
- t && /* @__PURE__ */ c.jsx(_n, { $isFirst: !0, $highlighted: !1, $theme: n }),
3578
- e.map((r, o) => /* @__PURE__ */ c.jsx(
3579
- _n,
3580
- {
3581
- $isFirst: o === 0 && !t,
3582
- $highlighted: !!(r != null && r.highlighted),
3583
- className: r == null ? void 0 : r.className,
3584
- $theme: n
3585
- },
3586
- r == null ? void 0 : r.title
3587
- ))
3588
- ] }), Pi = ({
3589
- title: e,
3590
- component: t,
3591
- theme: n
3592
- }) => /* @__PURE__ */ c.jsx(ur, { $theme: n, children: t ?? e ?? "" }), Mi = ({ gridId: e, isAllSelected: t, selectAll: n, deselectAll: r, disabled: o, theme: s }) => {
3593
- const i = (d) => {
3594
- const { checked: l } = d.target;
3595
- l ? n() : r();
3596
- };
3597
- return /* @__PURE__ */ c.jsx(ur, { $theme: s, children: /* @__PURE__ */ c.jsx(
3598
- hr,
3599
- {
3600
- label: "Select all rows",
3601
- onChange: i,
3602
- id: `select_all_${e}`,
3603
- checked: t,
3604
- disabled: o,
3605
- theme: s
3606
- }
3607
- ) });
3608
- }, Bi = ({
3609
- columns: e,
3610
- gridId: t,
3611
- selectAll: n,
3612
- deselectAll: r,
3613
- selectable: o,
3614
- isAllSelected: s,
3615
- isAllCheckboxDisabled: i = !1,
3616
- theme: d
3617
- }) => /* @__PURE__ */ c.jsx(wi, { $theme: d, children: /* @__PURE__ */ c.jsxs(ki, { $theme: d, children: [
3618
- o && /* @__PURE__ */ c.jsx(
3619
- Mi,
3620
- {
3621
- isAllSelected: s,
3622
- disabled: i,
3623
- gridId: t,
3624
- selectAll: n,
3625
- deselectAll: r,
3626
- theme: d
3627
- }
3628
- ),
3629
- e.map((l) => /* @__PURE__ */ c.jsx(Pi, { title: l.title, component: l.component, theme: d }, `${l.title}_${t}`))
3630
- ] }) }), Di = ({
3631
- data: e,
3632
- id: t,
3633
- onSelect: n
3634
- }) => {
3635
- const { elementId: r } = ve(t), [o, s] = B([]), i = e.map((g) => g.id), d = i.length === o.length, l = e.some((g) => g == null ? void 0 : g.disabled), u = (g) => {
3636
- s(g), n == null || n(g);
3637
- };
3638
- return {
3639
- elementId: r,
3640
- isAllSelected: d,
3641
- isAllCheckboxDisabled: l,
3642
- selectedIds: o,
3643
- handleSelectAll: () => {
3644
- u(i);
3645
- },
3646
- handleDeselectAll: () => {
3647
- u([]);
3648
- },
3649
- handleSelectRowById: (g) => {
3650
- const $ = [...o, g];
3651
- u($);
3652
- },
3653
- handleDeselectRowById: (g) => {
3654
- const $ = o.filter((w) => w !== g);
3655
- u($);
3656
- }
3657
- };
3658
- }, ba = ({
3659
- columns: e,
3660
- data: t,
3661
- id: n,
3662
- onSelect: r,
3663
- renderDataItem: o,
3664
- caption: s,
3665
- selectable: i = !1,
3666
- ...d
3667
- }) => {
3668
- const {
3669
- elementId: l,
3670
- handleSelectAll: u,
3671
- handleDeselectAll: f,
3672
- isAllCheckboxDisabled: h,
3673
- isAllSelected: m,
3674
- handleDeselectRowById: p,
3675
- handleSelectRowById: g,
3676
- selectedIds: $
3677
- } = Di({ id: n, data: t, onSelect: r }), w = q();
3678
- return /* @__PURE__ */ c.jsxs(vi, { ...d, children: [
3679
- s && /* @__PURE__ */ c.jsx(Ci, { $theme: w, children: s }),
3680
- /* @__PURE__ */ c.jsx(Oi, { columns: e, selectable: i, theme: w }),
3681
- /* @__PURE__ */ c.jsx(
3682
- Bi,
3683
- {
3684
- gridId: l,
3685
- columns: e,
3686
- selectable: i,
3687
- selectAll: u,
3688
- deselectAll: f,
3689
- isAllSelected: m,
3690
- isAllCheckboxDisabled: h,
3691
- theme: w
3692
- }
3693
- ),
3694
- /* @__PURE__ */ c.jsx(
3695
- Ti,
3696
- {
3697
- columns: e,
3698
- data: t,
3699
- selectable: i,
3700
- selectRowById: g,
3701
- deselectRowById: p,
3702
- selectedIds: $,
3703
- renderDataItem: o,
3704
- theme: w
3705
- }
3706
- )
3707
- ] });
3708
- }, pr = k.ul`
3709
- list-style: none;
3710
- margin: 0;
3711
- padding: 0;
3712
- padding-inline-start: 0;
3713
- display: flex;
3714
- gap: ${(e) => e.$theme.gapSmall};
3715
- flex-direction: ${(e) => e.$mode === Y.Vertical ? "column" : "row"};
3716
- justify-content: flex-start;
3717
- width: 100%;
3718
- `, Ni = k(pr)`
3719
- flex-direction: column;
3720
- padding-left: ${(e) => e.$theme.gapBig};
3721
- margin-left: ${(e) => e.$theme.gapBig};
3722
- margin-top: ${(e) => e.$theme.gapSmall};
3723
- box-sizing: border-box;
3724
- border-left: ${(e) => e.$theme.borderLight};
3725
- ${Ue}
3726
-
3727
- ${({ $theme: e, $mode: t }) => t === Y.Horizontal && `
3728
- position: absolute;
3729
- top: 100%;
3730
- left: 40%;
3731
- width: max-content;
3732
- border-radius: ${e.blockBorderRadius};
3733
- border: ${e.borderLight};
3734
- box-shadow: ${e.boxShadow};
3735
- background-color: ${e.backgroundColorBase};
3736
- padding: ${e.gapMedium};
3737
- margin: 0;
3738
- z-index: ${e.zIndexPopup};
3739
- `}
3740
- `, Li = k.li`
3741
- display: flex;
3742
- justify-content: flex-start;
3743
- align-items: center;
3744
- gap: ${(e) => e.$theme.gapMedium};
3745
- font-family: ${(e) => e.$theme.fontFamilyCore};
3746
- color: ${(e) => e.$theme.fontColorBase};
3747
- font-size: ${(e) => e.$theme.fontSizeBase};
3748
- background-color: ${(e) => e.$theme.backgroundColorBase};
3749
- padding: ${(e) => e.$theme.gapMedium};
3750
- border-radius: ${(e) => e.$theme.blockBorderRadius};
3751
- cursor: pointer;
3752
-
3753
- &:hover {
3754
- color: ${(e) => e.$theme.fontColorAccent};
3755
- }
3756
-
3757
- &:focus-visible {
3758
- outline: ${(e) => e.$theme.borderOutline};
3759
- }
3760
- `, Hi = k.li`
3761
- display: flex;
3762
- justify-content: flex-start;
3763
- align-items: center;
3764
- flex-direction: column;
3765
- gap: 0;
3766
- padding: 0;
3767
- position: relative;
3768
- border-radius: ${(e) => e.$theme.blockBorderRadius};
3769
-
3770
- &:focus-visible {
3771
- outline: ${(e) => e.$theme.borderOutline};
3772
- }
3773
- `, Fi = k.span`
3774
- position: relative;
3775
- display: flex;
3776
- box-sizing: border-box;
3777
- gap: ${(e) => e.$theme.gapMedium};
3778
- align-items: center;
3779
- width: 100%;
3780
- justify-content: space-between;
3781
- font-family: ${(e) => e.$theme.fontFamilyCore};
3782
- color: ${(e) => e.$theme.fontColorBase};
3783
- font-size: ${(e) => e.$theme.fontSizeBase};
3784
- background-color: ${(e) => e.$theme.backgroundColorBase};
3785
- padding: ${(e) => e.$theme.gapMedium};
3786
- border-radius: ${(e) => e.$theme.blockBorderRadius};
3787
- cursor: pointer;
3788
-
3789
- span {
3790
- display: flex;
3791
- gap: ${(e) => e.$theme.gapMedium};
3792
- align-items: center;
3793
- }
3794
-
3795
- &:hover {
3796
- color: ${(e) => e.$theme.fontColorAccent};
3797
- }
3798
- `, Gi = ({ theme: e, item: t }) => {
3799
- const { icon: n, link: r, label: o, onFocus: s, onClick: i, onHover: d } = t, l = r ? /* @__PURE__ */ c.jsx("a", { href: r, target: "_blank", rel: "noreferrer", children: o }) : /* @__PURE__ */ c.jsx("span", { children: o });
3800
- return /* @__PURE__ */ c.jsxs(Li, { tabIndex: 0, role: "menuitem", $theme: e, onFocus: s, onClick: i, onMouseOver: d, children: [
3801
- /* @__PURE__ */ c.jsx(ue, { name: n }),
3802
- l
3803
- ] });
3804
- }, Wi = ({ item: e, theme: t, isSubMenuOpened: n, toggleSubMenu: r, closeSubMenu: o, mode: s, children: i }) => {
3805
- const { icon: d, link: l, label: u } = e, f = $e(null), h = $e(null), m = l ? /* @__PURE__ */ c.jsxs("a", { href: l, target: "_blank", rel: "noreferrer", children: [
3806
- /* @__PURE__ */ c.jsx(ue, { name: d }),
3807
- u
3808
- ] }) : /* @__PURE__ */ c.jsxs("span", { children: [
3809
- /* @__PURE__ */ c.jsx(ue, { name: d }),
3810
- u
3811
- ] }), p = ($) => {
3812
- $.stopPropagation(), $.key === " " && r();
3813
- };
3814
- return jt({ ref: f, dependentRef: h, onClickOutsideHandler: () => {
3815
- s !== Y.Vertical && o();
3816
- } }), /* @__PURE__ */ c.jsxs(
3817
- Hi,
3818
- {
3819
- tabIndex: 0,
3820
- role: "menuitem",
3821
- "aria-haspopup": "true",
3822
- "aria-expanded": n,
3823
- $theme: t,
3824
- onKeyDown: p,
3825
- ref: f,
3826
- children: [
3827
- /* @__PURE__ */ c.jsxs(Fi, { ref: h, $theme: t, onClick: r, $mode: s, children: [
3828
- m,
3829
- /* @__PURE__ */ c.jsx(ue, { name: n ? j.ArrowUp : j.ArrowDown })
3830
- ] }),
3831
- n && i
3832
- ]
3833
- }
3834
- );
3835
- }, mr = ({ item: e, theme: t, mode: n }) => {
3836
- var l, u;
3837
- const r = !((l = e == null ? void 0 : e.nestedItems) != null && l.length), [o, s] = B(!1);
3838
- if (r)
3839
- return /* @__PURE__ */ c.jsx(Gi, { item: e, theme: t });
3840
- const i = () => {
3841
- s(!o);
3842
- }, d = () => {
3843
- s(!1);
3844
- };
3845
- return /* @__PURE__ */ c.jsx(
3846
- Wi,
3847
- {
3848
- item: e,
3849
- theme: t,
3850
- isSubMenuOpened: o,
3851
- toggleSubMenu: i,
3852
- closeSubMenu: d,
3853
- mode: n,
3854
- children: /* @__PURE__ */ c.jsx(Ni, { role: "menu", "aria-label": e.label, $theme: t, $mode: n, children: (u = e == null ? void 0 : e.nestedItems) == null ? void 0 : u.map((f) => /* @__PURE__ */ c.jsx(mr, { item: f, theme: t, mode: n }, f.id)) })
3855
- }
3856
- );
3857
- }, ya = ({ items: e, mode: t = Y.Vertical, ...n }) => {
3858
- const r = q();
3859
- return /* @__PURE__ */ c.jsx(pr, { role: "menubar", $theme: r, $mode: t, ...n, children: e.map((o) => /* @__PURE__ */ c.jsx(mr, { item: o, theme: r, mode: t }, o.id)) });
3860
- }, Qt = ({ children: e }) => {
3861
- const [t] = B(() => document.createElement("div"));
3862
- return fe(() => (document.body.appendChild(t), () => {
3863
- document.body.removeChild(t);
3864
- }), [t]), kr.createPortal(e, t);
3865
- }, Ui = k.button`
3866
- background: transparent;
3867
- position: relative;
3868
- outline: none;
3869
- border: none;
3870
- padding: ${(e) => e.$theme.gapMedium};
3871
- cursor: pointer;
3872
- font-size: ${(e) => e.$theme.fontSizeBase};
3873
- font-family: ${(e) => e.$theme.fontFamilyCore};
3874
- color: ${(e) => e.$theme.fontColorBase};
3875
- overflow: hidden;
3876
- border-top-left-radius: ${(e) => e.$theme.blockBorderRadius};
3877
- border-top-right-radius: ${(e) => e.$theme.blockBorderRadius};
3878
-
3879
- &:focus-visible {
3880
- outline: ${(e) => e.$theme.borderOutline};
3881
- outline-offset: -4px;
3882
- }
3883
-
3884
- &:hover,
3885
- &:active {
3886
- color: ${(e) => e.$theme.fontColorAccent};
3887
- }
3888
-
3889
- ${(e) => e.$disabled && `
3890
- pointer-events: none;
3891
- filter: grayscale(80%);
3892
- opacity: 0.6;
3893
- `}
3894
-
3895
- ${(e) => e.$selected && `
3896
- border-top: ${e.$theme.borderLight};
3897
- border-right: ${e.$theme.borderLight};
3898
- border-left: ${e.$theme.borderLight};
3899
- background-color: ${e.$theme.backgroundColorBase};
3900
- top: 1px;
3901
- `}
3902
-
3903
- ${(e) => e.$mode === Y.Vertical && `
3904
- border-bottom-left-radius: ${e.$theme.blockBorderRadius};
3905
- border-top-right-radius: 0;
3906
- `}
3907
-
3908
- ${(e) => e.$mode === Y.Vertical && e.$selected && `
3909
- border-top: ${e.$theme.borderLight};
3910
- border-right: none;
3911
- border-left: ${e.$theme.borderLight};
3912
- border-bottom: ${e.$theme.borderLight};
3913
- top: 0px;
3914
- left: 1px;
3915
- `}
3916
- `, Yi = k.div`
3917
- background-color: ${(e) => e.$theme.backgroundColorBase};
3918
- color: ${(e) => e.$theme.fontColorBase};
3919
- font-size: ${(e) => e.$theme.fontSizeBase};
3920
- font-family: ${(e) => e.$theme.fontFamilyCore};
3921
- padding: ${(e) => e.$theme.gapBig};
3922
- flex-grow: 1;
3923
- `, Vi = k.div`
3924
- border-bottom: ${(e) => e.$theme.borderLight};
3925
- padding: 0 ${(e) => e.$theme.gapMedium};
3926
- display: flex;
3927
- gap: ${(e) => e.$theme.gapMedium};
3928
-
3929
- ${(e) => e.$mode === Y.Vertical && `
3930
- flex-direction: column;
3931
- border-bottom: none;
3932
- border-right: ${e.$theme.borderLight};
3933
- padding: ${e.$theme.gapMedium} 0;
3934
- `}
3935
- `, Ki = k.div`
3936
- display: flex;
3937
- flex-direction: column;
3938
- width: 100%;
3939
-
3940
- ${({ $mode: e }) => e === Y.Vertical && `
3941
- flex-direction: row;
3942
- `}
3943
- `, qi = ({ tabs: e, selectedTabId: t, theme: n }) => {
3944
- var s;
3945
- const r = (s = e.find((i) => i.id === t)) == null ? void 0 : s.content, o = `tabpanel_${t}`;
3946
- return /* @__PURE__ */ c.jsx(Yi, { role: "tabpanel", "aria-labelledby": t, id: o, $theme: n, children: r });
3947
- }, Xi = ({
3948
- title: e,
3949
- onTabSelect: t,
3950
- tabId: n,
3951
- isSelected: r,
3952
- isDisabled: o = !1,
3953
- tabPanelId: s,
3954
- mode: i,
3955
- theme: d
3956
- }) => /* @__PURE__ */ c.jsx(
3957
- Ui,
3958
- {
3959
- role: "tab",
3960
- id: n,
3961
- onClick: () => t(n),
3962
- "aria-selected": r,
3963
- "aria-controls": s,
3964
- $selected: r,
3965
- $disabled: o,
3966
- $mode: i,
3967
- $theme: d,
3968
- children: e
3969
- }
3970
- ), Ji = ({ tabs: e, onTabSelect: t, selectedTabId: n, tabPanelIds: r, mode: o, tabIds: s, theme: i }) => {
3971
- const d = (l) => {
3972
- const u = s.findIndex((f) => f === n);
3973
- switch (l.key) {
3974
- case "ArrowLeft":
3975
- case "ArrowUp": {
3976
- if (l.preventDefault(), l.key === "ArrowUp" && o === Y.Horizontal || l.key === "ArrowLeft" && o === Y.Vertical) break;
3977
- const f = u - 1 >= 0 ? u - 1 : s.length - 1, h = s[f];
3978
- h && (et(h), t(h));
3979
- break;
3980
- }
3981
- case "ArrowRight":
3982
- case "ArrowDown": {
3983
- if (l.preventDefault(), l.key === "ArrowDown" && o === Y.Horizontal || l.key === "ArrowRight" && o === Y.Vertical) break;
3984
- const f = u === s.length - 1 ? 0 : u + 1, h = s[f];
3985
- h && (et(h), t(h));
3986
- break;
3987
- }
3988
- }
3989
- };
3990
- return /* @__PURE__ */ c.jsx(Vi, { role: "tablist", $mode: o, onKeyDown: d, $theme: i, children: e.map(({ id: l, title: u, disabled: f }, h) => /* @__PURE__ */ c.jsx(
3991
- Xi,
3992
- {
3993
- title: u,
3994
- onTabSelect: t,
3995
- tabId: l,
3996
- isSelected: l === n,
3997
- isDisabled: f,
3998
- tabPanelId: r[h],
3999
- mode: o,
4000
- theme: i
4001
- },
4002
- l
4003
- )) });
4004
- }, $a = ({ tabs: e, defaultTabId: t, mode: n = Y.Horizontal, ...r }) => {
4005
- const o = e.map((h) => h.id), s = o.map((h) => `tabpanel_${h}`), i = t && o.includes(t) ? t : o[0], [d, l] = B(i), u = q(), f = (h) => {
4006
- l(h);
4007
- };
4008
- return /* @__PURE__ */ c.jsxs(Ki, { $mode: n, ...r, children: [
4009
- /* @__PURE__ */ c.jsx(
4010
- Ji,
4011
- {
4012
- tabs: e,
4013
- selectedTabId: d,
4014
- tabPanelIds: s,
4015
- onTabSelect: f,
4016
- mode: n,
4017
- tabIds: o,
4018
- theme: u
4019
- }
4020
- ),
4021
- /* @__PURE__ */ c.jsx(qi, { tabs: e, selectedTabId: d, theme: u })
4022
- ] });
4023
- }, Zi = k.header`
4024
- display: flex;
4025
- justify-content: space-between;
4026
- align-items: center;
4027
-
4028
- h3 {
4029
- display: flex;
4030
- gap: ${(e) => e.$theme.gapMedium};
4031
- align-items: center;
4032
- margin: 0;
4033
- color: ${(e) => e.$theme.fontColorBase};
4034
-
4035
- svg {
4036
- color: ${(e) => e.$theme.fontColorAccent};
4037
- }
4038
- }
4039
- `, Qi = k.div`
4040
- position: fixed;
4041
- bottom: ${(e) => e.$theme.gapBig};
4042
- left: 50%;
4043
- transform: translateX(-50%);
4044
- z-index: ${(e) => e.$theme.zIndexPopup};
4045
- ${Ue}
4046
-
4047
- ${(e) => e.$isClosing && tr}
4048
- `, ea = k.div`
4049
- display: flex;
4050
- flex-direction: column;
4051
- gap: ${(e) => e.$theme.gapMedium};
4052
- font-family: ${(e) => e.$theme.fontFamilyCore};
4053
- background: ${(e) => e.$theme.backgroundColorBase};
4054
- color: ${(e) => e.$theme.fontColorBase};
4055
- width: 90vw;
4056
- padding: ${(e) => e.$theme.gapMedium};
4057
- box-shadow: ${(e) => e.$theme.boxShadow};
4058
- border: ${(e) => e.$theme.borderLight};
4059
- border-radius: ${(e) => e.$theme.blockBorderRadius};
4060
- `;
4061
- function gr(e) {
4062
- return /* @__PURE__ */ c.jsxs("svg", { viewBox: "0 0 24 24", fill: "currentColor", height: "1em", width: "1em", role: "img", ...e, children: [
4063
- /* @__PURE__ */ c.jsx("title", { children: "Error" }),
4064
- /* @__PURE__ */ c.jsx("path", { d: "M11 7h2v7h-2zm0 8h2v2h-2z" }),
4065
- /* @__PURE__ */ c.jsx("path", { d: "M21.707 7.293l-5-5A.996.996 0 0016 2H8a.996.996 0 00-.707.293l-5 5A.996.996 0 002 8v8c0 .266.105.52.293.707l5 5A.996.996 0 008 22h8c.266 0 .52-.105.707-.293l5-5A.996.996 0 0022 16V8a.996.996 0 00-.293-.707zM20 15.586L15.586 20H8.414L4 15.586V8.414L8.414 4h7.172L20 8.414v7.172z" })
4066
- ] });
4067
- }
4068
- const ta = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4069
- __proto__: null,
4070
- default: gr
4071
- }, Symbol.toStringTag, { value: "Module" }));
4072
- function br(e) {
4073
- return /* @__PURE__ */ c.jsxs("svg", { viewBox: "0 0 512 512", fill: "currentColor", height: "1em", width: "1em", role: "img", ...e, children: [
4074
- /* @__PURE__ */ c.jsx("title", { children: "Help" }),
4075
- /* @__PURE__ */ c.jsx("path", { d: "M414.39 97.61A224 224 0 1097.61 414.39 224 224 0 10414.39 97.61zM192.13 260.18a64 64 0 1159.69 59.69 64.07 64.07 0 01-59.69-59.69zm240-66.64l-96.37 5.84a4.06 4.06 0 01-3.44-1.59 96 96 0 00-18.07-18.07 4.06 4.06 0 01-1.59-3.44l5.84-96.37a4 4 0 015.42-3.51A193 193 0 01435.6 188.12a4 4 0 01-3.51 5.42zM193.54 79.91l5.84 96.37a4.06 4.06 0 01-1.59 3.44 96 96 0 00-18.07 18.07 4.06 4.06 0 01-3.44 1.59l-96.37-5.84a4 4 0 01-3.51-5.42A193 193 0 01188.12 76.4a4 4 0 015.42 3.51zM79.91 318.46l96.37-5.84a4.06 4.06 0 013.44 1.59 96 96 0 0018.07 18.07 4.06 4.06 0 011.59 3.44l-5.84 96.37a4 4 0 01-5.42 3.51A193 193 0 0176.4 323.88a4 4 0 013.51-5.42zm238.55 113.63l-5.84-96.37a4.06 4.06 0 011.59-3.44 96 96 0 0018.07-18.07 4.06 4.06 0 013.44-1.59l96.37 5.84a4 4 0 013.51 5.42A193 193 0 01323.88 435.6a4 4 0 01-5.42-3.51z" })
4076
- ] });
4077
- }
4078
- const na = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4079
- __proto__: null,
4080
- default: br
4081
- }, Symbol.toStringTag, { value: "Module" }));
4082
- function yr(e) {
4083
- return /* @__PURE__ */ c.jsxs("svg", { viewBox: "0 0 1024 1024", fill: "currentColor", height: "1em", width: "1em", role: "img", ...e, children: [
4084
- /* @__PURE__ */ c.jsx("title", { children: "Info" }),
4085
- /* @__PURE__ */ c.jsx("path", { d: "M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z" }),
4086
- /* @__PURE__ */ c.jsx("path", { d: "M464 336a48 48 0 1096 0 48 48 0 10-96 0zm72 112h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V456c0-4.4-3.6-8-8-8z" })
4087
- ] });
4088
- }
4089
- const ra = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4090
- __proto__: null,
4091
- default: yr
4092
- }, Symbol.toStringTag, { value: "Module" }));
4093
- function $r(e) {
4094
- return /* @__PURE__ */ c.jsxs("svg", { viewBox: "0 0 24 24", fill: "currentColor", height: "1em", width: "1em", role: "img", ...e, children: [
4095
- /* @__PURE__ */ c.jsx("title", { children: "Warning" }),
4096
- /* @__PURE__ */ c.jsx("path", { fill: "none", d: "M0 0h24v24H0z" }),
4097
- /* @__PURE__ */ c.jsx("path", { d: "M4 20v-6a8 8 0 1116 0v6h1v2H3v-2h1zm2 0h12v-6a6 6 0 10-12 0v6zm5-18h2v3h-2V2zm8.778 2.808l1.414 1.414-2.12 2.121-1.415-1.414 2.121-2.121zM2.808 6.222l1.414-1.414 2.121 2.12L4.93 8.344 2.808 6.222zM7 14a5 5 0 015-5v2a3 3 0 00-3 3H7z" })
4098
- ] });
4099
- }
4100
- const oa = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4101
- __proto__: null,
4102
- default: $r
4103
- }, Symbol.toStringTag, { value: "Module" }));
4104
- function sa(e, t) {
4105
- if (t) return t;
4106
- switch (e) {
4107
- case Z.Info:
4108
- return "For your information";
4109
- case Z.Warning:
4110
- return "Please pay attention";
4111
- case Z.Error:
4112
- return "Something went wrong";
4113
- case Z.Success:
4114
- return "Everything is okay";
4115
- case Z.Help:
4116
- return "Useful tip";
4117
- default:
4118
- return "Alert";
4119
- }
4120
- }
4121
- function ia(e, t) {
4122
- if (t)
4123
- return /* @__PURE__ */ c.jsx(ue, { name: t });
4124
- switch (e) {
4125
- case Z.Info:
4126
- return /* @__PURE__ */ c.jsx(yr, {});
4127
- case Z.Warning:
4128
- return /* @__PURE__ */ c.jsx($r, {});
4129
- case Z.Error:
4130
- return /* @__PURE__ */ c.jsx(gr, {});
4131
- case Z.Success:
4132
- return /* @__PURE__ */ c.jsx(Zt, {});
4133
- case Z.Help:
4134
- return /* @__PURE__ */ c.jsx(br, {});
4135
- default:
4136
- return null;
4137
- }
4138
- }
4139
- const aa = ({ title: e, onClose: t, mode: n, icon: r, theme: o }) => {
4140
- const s = sa(n, e), i = ia(n, r);
4141
- return /* @__PURE__ */ c.jsxs(Zi, { $theme: o, children: [
4142
- /* @__PURE__ */ c.jsxs("h3", { children: [
4143
- i,
4144
- s
4145
- ] }),
4146
- /* @__PURE__ */ c.jsx($t, { icon: j.Cancel, view: be.Icon, label: "Close alert popup", onClick: t })
4147
- ] });
4148
- }, xa = ({
4149
- isOpened: e,
4150
- onClose: t,
4151
- title: n,
4152
- message: r,
4153
- mode: o = Z.Info,
4154
- icon: s,
4155
- ...i
4156
- }) => {
4157
- const d = ir(e), l = d && !e, u = q();
4158
- return d ? /* @__PURE__ */ c.jsx(Qt, { children: /* @__PURE__ */ c.jsx(Qi, { $isClosing: l, $theme: u, children: /* @__PURE__ */ c.jsxs(ea, { ...i, $theme: u, children: [
4159
- /* @__PURE__ */ c.jsx(aa, { title: n, onClose: t, mode: o, icon: s, theme: u }),
4160
- /* @__PURE__ */ c.jsx("p", { children: r })
4161
- ] }) }) }) : null;
4162
- };
4163
- export {
4164
- q as A,
4165
- jt as B,
4166
- $t as C,
4167
- ks as D,
4168
- ve as E,
4169
- Et as F,
4170
- Cs as G,
4171
- ir as H,
4172
- yt as I,
4173
- nt as J,
4174
- Es as K,
4175
- js as L,
4176
- da as a,
4177
- ua as b,
4178
- fa as c,
4179
- ha as d,
4180
- pa as e,
4181
- ma as f,
4182
- pi as g,
4183
- ga as h,
4184
- ba as i,
4185
- c as j,
4186
- ya as k,
4187
- Qt as l,
4188
- $a as m,
4189
- xa as n,
4190
- Re as o,
4191
- ws as p,
4192
- nr as q,
4193
- ue as r,
4194
- Ye as s,
4195
- Z as t,
4196
- be as u,
4197
- j as v,
4198
- Lo as w,
4199
- Y as x,
4200
- rr as y,
4201
- or as z
4202
- };
4203
- //# sourceMappingURL=index-Dg2AZXfT.js.map