@ahrowe/ui 0.1.10 → 0.1.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +2 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +762 -762
- package/dist/index.mjs.map +1 -1
- package/dist/style.css +1 -1
- package/dist/types/package/common/dropdown/dropdown.d.ts +1 -1
- package/dist/types/package/common/dropdown/dropdown.types.d.ts +10 -6
- package/dist/types/package/common/input/input.d.ts +1 -1
- package/dist/types/package/common/input/input.types.d.ts +5 -2
- package/dist/types/package/common/themeProvider/theme.types.d.ts +2 -0
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -2,16 +2,16 @@ import e, { Component as t, PureComponent as n, forwardRef as r, useCallback as
|
|
|
2
2
|
import f from "classnames";
|
|
3
3
|
import { FontAwesomeIcon as p } from "@fortawesome/react-fontawesome";
|
|
4
4
|
import { faBell as m, faCheck as h, faChevronDown as g, faChevronLeft as _, faChevronRight as v, faCircleCheck as y, faCircleInfo as b, faCircleXmark as x, faDoorOpen as S, faDownload as C, faDrawPolygon as w, faEnvelope as T, faEye as E, faEyeSlash as ee, faGear as D, faHandPointer as O, faLayerGroup as k, faMagnifyingGlassMinus as te, faMagnifyingGlassPlus as ne, faPen as A, faPhone as j, faPlus as M, faSearch as N, faSquare as re, faTrash as ie, faTriangleExclamation as ae, faUpload as oe, faXmark as se, faXmarkCircle as P } from "@fortawesome/free-solid-svg-icons";
|
|
5
|
-
import { Fragment as
|
|
6
|
-
import { createPortal as
|
|
5
|
+
import { Fragment as ce, jsx as F, jsxs as I } from "react/jsx-runtime";
|
|
6
|
+
import { createPortal as L } from "react-dom";
|
|
7
7
|
import le from "downshift";
|
|
8
8
|
import ue from "@mona-health/react-input-mask";
|
|
9
9
|
import { DndContext as de, DragOverlay as fe, PointerSensor as pe, closestCorners as R, useDroppable as me, useSensor as he, useSensors as z } from "@dnd-kit/core";
|
|
10
10
|
import { SortableContext as B, arrayMove as V, useSortable as ge, verticalListSortingStrategy as _e } from "@dnd-kit/sortable";
|
|
11
|
-
import { CSS as
|
|
12
|
-
import { NumericFormat as
|
|
11
|
+
import { CSS as ve } from "@dnd-kit/utilities";
|
|
12
|
+
import { NumericFormat as ye } from "react-number-format";
|
|
13
13
|
//#region package/common/accordion/accordion.types.ts
|
|
14
|
-
var
|
|
14
|
+
var H = /* @__PURE__ */ function(e) {
|
|
15
15
|
return e.Default = "default", e.Primary = "primary", e.Plain = "plain", e;
|
|
16
16
|
}({}), be = {
|
|
17
17
|
accordion: "accordion_YZt8B",
|
|
@@ -72,11 +72,11 @@ var ye = /* @__PURE__ */ function(e) {
|
|
|
72
72
|
"accordion-icon-active": "accordion-icon-active_-L8BH",
|
|
73
73
|
accordionIconActive: "accordion-icon-active_-L8BH"
|
|
74
74
|
}, Ce = {
|
|
75
|
-
[
|
|
76
|
-
[
|
|
77
|
-
[
|
|
75
|
+
[H.Default]: be,
|
|
76
|
+
[H.Primary]: xe,
|
|
77
|
+
[H.Plain]: Se
|
|
78
78
|
};
|
|
79
|
-
function we({ id: e = "", title: t = "", children: n = null, expanded: r = null, onHeaderClicked: i = () => {}, styleType: o =
|
|
79
|
+
function we({ id: e = "", title: t = "", children: n = null, expanded: r = null, onHeaderClicked: i = () => {}, styleType: o = H.Default, startOpen: s = !1, hideHeader: c = !1, className: l, style: m, classNames: h, styles: _, ...v }) {
|
|
80
80
|
let y = Ce[o], b = u(null), [x, S] = d(r ?? s), [C, w] = d(null);
|
|
81
81
|
a(() => {
|
|
82
82
|
r !== null && S(r);
|
|
@@ -91,7 +91,7 @@ function we({ id: e = "", title: t = "", children: n = null, expanded: r = null,
|
|
|
91
91
|
i(e, t), r === null && S(t);
|
|
92
92
|
}
|
|
93
93
|
let E = { height: `${x ? 32 : 24}px` }, ee = { height: x ? C ?? "auto" : "0px" };
|
|
94
|
-
return /* @__PURE__ */
|
|
94
|
+
return /* @__PURE__ */ I("div", {
|
|
95
95
|
...v,
|
|
96
96
|
id: e || void 0,
|
|
97
97
|
className: f(y.accordion, x && y.accordionActive, l, h?.root),
|
|
@@ -99,7 +99,7 @@ function we({ id: e = "", title: t = "", children: n = null, expanded: r = null,
|
|
|
99
99
|
...m,
|
|
100
100
|
..._?.root
|
|
101
101
|
},
|
|
102
|
-
children: [!c && /* @__PURE__ */
|
|
102
|
+
children: [!c && /* @__PURE__ */ I("div", {
|
|
103
103
|
className: f(y.accordionHeader, x && y.accordionHeaderActive, h?.header),
|
|
104
104
|
style: {
|
|
105
105
|
...E,
|
|
@@ -111,22 +111,22 @@ function we({ id: e = "", title: t = "", children: n = null, expanded: r = null,
|
|
|
111
111
|
onKeyDown: ({ key: e }) => {
|
|
112
112
|
e === "Enter" && T();
|
|
113
113
|
},
|
|
114
|
-
children: [/* @__PURE__ */
|
|
114
|
+
children: [/* @__PURE__ */ F("div", {
|
|
115
115
|
className: f(y.accordionTitle, h?.title),
|
|
116
116
|
style: _?.title,
|
|
117
117
|
children: t
|
|
118
|
-
}), /* @__PURE__ */
|
|
118
|
+
}), /* @__PURE__ */ F(p, {
|
|
119
119
|
icon: g,
|
|
120
120
|
className: f(y.accordionIcon, x && y.accordionIconActive, h?.icon),
|
|
121
121
|
style: _?.icon
|
|
122
122
|
})]
|
|
123
|
-
}), /* @__PURE__ */
|
|
123
|
+
}), /* @__PURE__ */ F("div", {
|
|
124
124
|
className: f(y.accordionBody, x && y.accordionBodyActive, h?.body),
|
|
125
125
|
style: {
|
|
126
126
|
...ee,
|
|
127
127
|
..._?.body
|
|
128
128
|
},
|
|
129
|
-
children: /* @__PURE__ */
|
|
129
|
+
children: /* @__PURE__ */ F("div", {
|
|
130
130
|
className: f(y.accordionBodyInner, h?.bodyInner),
|
|
131
131
|
style: _?.bodyInner,
|
|
132
132
|
ref: b,
|
|
@@ -181,14 +181,14 @@ var Te = {
|
|
|
181
181
|
//#endregion
|
|
182
182
|
//#region package/common/loading/spinnerLoading/spinnerLoading.tsx
|
|
183
183
|
function De({ className: e }) {
|
|
184
|
-
return /* @__PURE__ */
|
|
184
|
+
return /* @__PURE__ */ F("svg", {
|
|
185
185
|
"data-testid": "spinner",
|
|
186
186
|
className: f(Ee.spinnerLoading, e),
|
|
187
187
|
xmlns: "http://www.w3.org/2000/svg",
|
|
188
188
|
viewBox: "0 0 100 100",
|
|
189
189
|
fill: "none",
|
|
190
190
|
stroke: "var(--primary-color)",
|
|
191
|
-
children: /* @__PURE__ */
|
|
191
|
+
children: /* @__PURE__ */ F("circle", {
|
|
192
192
|
cx: "50",
|
|
193
193
|
cy: "50",
|
|
194
194
|
r: "45",
|
|
@@ -236,14 +236,14 @@ var Oe = De, W = /* @__PURE__ */ function(e) {
|
|
|
236
236
|
return e.addEventListener("click", n), () => e.removeEventListener("click", n);
|
|
237
237
|
}, [t, l]);
|
|
238
238
|
let _ = { "--ripple-animation-length": `${s}s` };
|
|
239
|
-
return t === void 0 ? /* @__PURE__ */
|
|
239
|
+
return t === void 0 ? /* @__PURE__ */ F("div", {
|
|
240
240
|
className: je.rippleContainer,
|
|
241
241
|
ref: p,
|
|
242
242
|
style: {
|
|
243
243
|
overflow: i ? "hidden" : "visible",
|
|
244
244
|
..._
|
|
245
245
|
}
|
|
246
|
-
}) : /* @__PURE__ */
|
|
246
|
+
}) : /* @__PURE__ */ I("div", {
|
|
247
247
|
...d,
|
|
248
248
|
className: n,
|
|
249
249
|
onClick: l ? void 0 : (e) => g(e),
|
|
@@ -252,7 +252,7 @@ var Oe = De, W = /* @__PURE__ */ function(e) {
|
|
|
252
252
|
overflow: i ? "hidden" : "visible",
|
|
253
253
|
...r
|
|
254
254
|
},
|
|
255
|
-
children: [t, /* @__PURE__ */
|
|
255
|
+
children: [t, /* @__PURE__ */ F("div", {
|
|
256
256
|
className: je.rippleContainer,
|
|
257
257
|
ref: p,
|
|
258
258
|
style: _
|
|
@@ -269,7 +269,7 @@ var Oe = De, W = /* @__PURE__ */ function(e) {
|
|
|
269
269
|
large: U.buttonSizeLarge
|
|
270
270
|
};
|
|
271
271
|
function G({ className: e, style: t, type: n = Ae.Button, styleType: r = W.Default, size: i = ke.Default, onClick: a = () => {}, children: o, icon: s, isLoading: c = !1, disabled: l = !1, title: u = void 0, ref: d, classNames: m, styles: h, ...g }) {
|
|
272
|
-
return /* @__PURE__ */
|
|
272
|
+
return /* @__PURE__ */ F("button", {
|
|
273
273
|
...g,
|
|
274
274
|
className: f(U.button, Ne[r], Pe[i], { [U.buttonNotAllowed]: c || l }, e),
|
|
275
275
|
style: t,
|
|
@@ -278,25 +278,25 @@ function G({ className: e, style: t, type: n = Ae.Button, styleType: r = W.Defau
|
|
|
278
278
|
disabled: l || c,
|
|
279
279
|
title: u,
|
|
280
280
|
ref: d,
|
|
281
|
-
children: /* @__PURE__ */
|
|
281
|
+
children: /* @__PURE__ */ F(Me, {
|
|
282
282
|
disabled: c || l,
|
|
283
|
-
children: /* @__PURE__ */
|
|
283
|
+
children: /* @__PURE__ */ F("div", {
|
|
284
284
|
className: f(U.buttonBackground, m?.background),
|
|
285
285
|
style: h?.background,
|
|
286
|
-
children: /* @__PURE__ */
|
|
286
|
+
children: /* @__PURE__ */ I("div", {
|
|
287
287
|
className: f(U.buttonContent, m?.content),
|
|
288
288
|
style: h?.content,
|
|
289
|
-
children: [c ? /* @__PURE__ */
|
|
289
|
+
children: [c ? /* @__PURE__ */ F("div", {
|
|
290
290
|
className: f(U.buttonLoadingContainer, m?.loadingContainer),
|
|
291
291
|
style: h?.loadingContainer,
|
|
292
|
-
children: /* @__PURE__ */
|
|
293
|
-
}) : null, /* @__PURE__ */
|
|
292
|
+
children: /* @__PURE__ */ F(Oe, { className: U.buttonLoadingIcon })
|
|
293
|
+
}) : null, /* @__PURE__ */ I("div", {
|
|
294
294
|
className: f(m?.label, {
|
|
295
295
|
[U.buttonLoading]: c,
|
|
296
296
|
[U.buttonWithIcon]: !!s
|
|
297
297
|
}),
|
|
298
298
|
style: h?.label,
|
|
299
|
-
children: [s ? /* @__PURE__ */
|
|
299
|
+
children: [s ? /* @__PURE__ */ F(p, { icon: s }) : null, o]
|
|
300
300
|
})]
|
|
301
301
|
})
|
|
302
302
|
})
|
|
@@ -307,14 +307,14 @@ G.StyleType = W, G.Size = ke, G.Type = Ae;
|
|
|
307
307
|
//#endregion
|
|
308
308
|
//#region package/common/actionButtons/actionButtons.tsx
|
|
309
309
|
function Fe({ onSubmit: e = () => null, onClose: t = () => null, submitLabel: n = "Save", cancelLabel: r = "Cancel", submitButtonStyle: i = W.Primary, isSubmitButtonLoading: a = !1, isSubmitButtonDisabled: o = !1, isCancelButtonLoading: s = !1, isCancelButtonDisabled: c = !1, hidePrimaryButton: l = !1, hideSecondaryButton: u = !1, noMargin: d = !1, className: p, style: m, classNames: h, styles: g, ..._ }) {
|
|
310
|
-
return /* @__PURE__ */
|
|
310
|
+
return /* @__PURE__ */ I("div", {
|
|
311
311
|
..._,
|
|
312
312
|
className: f(Te.actionButtons, !d && Te.actionButtonsMargin, p, h?.root),
|
|
313
313
|
style: {
|
|
314
314
|
...m,
|
|
315
315
|
...g?.root
|
|
316
316
|
},
|
|
317
|
-
children: [!l && /* @__PURE__ */
|
|
317
|
+
children: [!l && /* @__PURE__ */ F(G, {
|
|
318
318
|
isLoading: a,
|
|
319
319
|
disabled: o,
|
|
320
320
|
styleType: i,
|
|
@@ -323,7 +323,7 @@ function Fe({ onSubmit: e = () => null, onClose: t = () => null, submitLabel: n
|
|
|
323
323
|
className: h?.submitButton,
|
|
324
324
|
style: g?.submitButton,
|
|
325
325
|
children: n
|
|
326
|
-
}), !u && /* @__PURE__ */
|
|
326
|
+
}), !u && /* @__PURE__ */ F(G, {
|
|
327
327
|
isLoading: s,
|
|
328
328
|
disabled: c,
|
|
329
329
|
onClick: t,
|
|
@@ -338,7 +338,7 @@ var Ie = { interactableDiv: "interactableDiv_Ej8Fi" }, Le = e.forwardRef(({ clas
|
|
|
338
338
|
let l = i((e) => {
|
|
339
339
|
e.key === "Enter" && n?.(e), r?.(e);
|
|
340
340
|
}, [n, r]);
|
|
341
|
-
return /* @__PURE__ */
|
|
341
|
+
return /* @__PURE__ */ F("div", {
|
|
342
342
|
className: f(Ie.interactableDiv, e),
|
|
343
343
|
onClick: n,
|
|
344
344
|
tabIndex: a ?? 0,
|
|
@@ -353,20 +353,20 @@ var Ie = { interactableDiv: "interactableDiv_Ej8Fi" }, Le = e.forwardRef(({ clas
|
|
|
353
353
|
Le.displayName = "InteractableDiv";
|
|
354
354
|
//#endregion
|
|
355
355
|
//#region package/common/interactableDiv/index.ts
|
|
356
|
-
var
|
|
356
|
+
var K = Le, Re = { actionIcon: "actionIcon_ganSq" };
|
|
357
357
|
//#endregion
|
|
358
358
|
//#region package/common/actionIcon/actionIcon.tsx
|
|
359
|
-
function
|
|
360
|
-
return /* @__PURE__ */
|
|
359
|
+
function ze({ icon: e, className: t = "", style: n, title: r = "", onClick: i = () => {}, classNames: a, styles: o, ...s }) {
|
|
360
|
+
return /* @__PURE__ */ F(K, {
|
|
361
361
|
...s,
|
|
362
|
-
className: f(
|
|
362
|
+
className: f(Re.actionIcon, t, a?.root),
|
|
363
363
|
style: {
|
|
364
364
|
...n,
|
|
365
365
|
...o?.root
|
|
366
366
|
},
|
|
367
367
|
title: r,
|
|
368
368
|
onClick: i,
|
|
369
|
-
children: /* @__PURE__ */
|
|
369
|
+
children: /* @__PURE__ */ F(p, {
|
|
370
370
|
icon: e,
|
|
371
371
|
className: a?.icon,
|
|
372
372
|
style: o?.icon
|
|
@@ -375,11 +375,11 @@ function Be({ icon: e, className: t = "", style: n, title: r = "", onClick: i =
|
|
|
375
375
|
}
|
|
376
376
|
//#endregion
|
|
377
377
|
//#region package/common/bodyEnd/bodyEnd.tsx
|
|
378
|
-
function
|
|
378
|
+
function Be({ children: e = null }) {
|
|
379
379
|
let t = document.getElementById("bodyEnd");
|
|
380
|
-
return t ?
|
|
380
|
+
return t ? L(e, t) : (typeof process < "u" && process.env.NODE_ENV !== "production" && console.error("[BodyEnd] No element with id=\"bodyEnd\" found. Add <div id=\"bodyEnd\"></div> to your app root."), null);
|
|
381
381
|
}
|
|
382
|
-
var
|
|
382
|
+
var q = {
|
|
383
383
|
card: "card_w-6Ki",
|
|
384
384
|
"card-padding": "card-padding_X2-q-",
|
|
385
385
|
cardPadding: "card-padding_X2-q-",
|
|
@@ -403,15 +403,15 @@ var K = {
|
|
|
403
403
|
};
|
|
404
404
|
//#endregion
|
|
405
405
|
//#region package/common/card/Card.tsx
|
|
406
|
-
function
|
|
406
|
+
function Ve({ className: e = void 0, children: t = null, onClick: n = void 0, tabIndex: r = null, hoverEffect: i = void 0, style: a = void 0, ...o }) {
|
|
407
407
|
let s = !!n;
|
|
408
|
-
return /* @__PURE__ */
|
|
408
|
+
return /* @__PURE__ */ F(K, {
|
|
409
409
|
...o,
|
|
410
|
-
className: f(
|
|
410
|
+
className: f(q.card, q.cardPadding, q.cardShadow, s && q.cardInteractable, (s && i !== !1 || i) && q.cardHover, e),
|
|
411
411
|
onClick: n,
|
|
412
412
|
tabIndex: r ?? (s ? 0 : null),
|
|
413
413
|
style: a,
|
|
414
|
-
children: /* @__PURE__ */
|
|
414
|
+
children: /* @__PURE__ */ F(Me, {
|
|
415
415
|
disabled: !s,
|
|
416
416
|
overflowHidden: !1,
|
|
417
417
|
children: t
|
|
@@ -420,21 +420,21 @@ function He({ className: e = void 0, children: t = null, onClick: n = void 0, ta
|
|
|
420
420
|
}
|
|
421
421
|
//#endregion
|
|
422
422
|
//#region package/common/card/CardHeader.tsx
|
|
423
|
-
function
|
|
423
|
+
function He({ className: e = "", title: t = "", subTitle: n = "", thumbnail: r = "" }) {
|
|
424
424
|
let i = typeof r == "string" && r.startsWith("http") ? r : void 0;
|
|
425
|
-
return /* @__PURE__ */
|
|
426
|
-
className: f(
|
|
427
|
-
children: [r && /* @__PURE__ */
|
|
428
|
-
className:
|
|
425
|
+
return /* @__PURE__ */ I("div", {
|
|
426
|
+
className: f(q.cardHeader, e),
|
|
427
|
+
children: [r && /* @__PURE__ */ F("div", {
|
|
428
|
+
className: q.cardHeaderThumbnail,
|
|
429
429
|
style: i ? { backgroundImage: `url(${i})` } : {},
|
|
430
430
|
children: !i && r
|
|
431
|
-
}), /* @__PURE__ */
|
|
432
|
-
className:
|
|
433
|
-
children: [/* @__PURE__ */
|
|
434
|
-
className:
|
|
431
|
+
}), /* @__PURE__ */ I("div", {
|
|
432
|
+
className: q.cardHeaderTitles,
|
|
433
|
+
children: [/* @__PURE__ */ F("div", {
|
|
434
|
+
className: q.cardHeaderTitlesMain,
|
|
435
435
|
children: t
|
|
436
|
-
}), /* @__PURE__ */
|
|
437
|
-
className:
|
|
436
|
+
}), /* @__PURE__ */ F("div", {
|
|
437
|
+
className: q.cardHeaderTitlesSub,
|
|
438
438
|
children: n
|
|
439
439
|
})]
|
|
440
440
|
})]
|
|
@@ -442,31 +442,31 @@ function Ue({ className: e = "", title: t = "", subTitle: n = "", thumbnail: r =
|
|
|
442
442
|
}
|
|
443
443
|
//#endregion
|
|
444
444
|
//#region package/common/card/CardMedia.tsx
|
|
445
|
-
function
|
|
446
|
-
return /* @__PURE__ */
|
|
447
|
-
className:
|
|
445
|
+
function Ue({ src: e = "", alt: t = "" }) {
|
|
446
|
+
return /* @__PURE__ */ F("img", {
|
|
447
|
+
className: q.cardMedia,
|
|
448
448
|
src: e,
|
|
449
449
|
alt: t
|
|
450
450
|
});
|
|
451
451
|
}
|
|
452
452
|
//#endregion
|
|
453
453
|
//#region package/common/card/CardContent.tsx
|
|
454
|
-
function
|
|
455
|
-
return /* @__PURE__ */
|
|
454
|
+
function We({ children: e = null }) {
|
|
455
|
+
return /* @__PURE__ */ F(ce, { children: e });
|
|
456
456
|
}
|
|
457
457
|
//#endregion
|
|
458
458
|
//#region package/common/card/CardActions.tsx
|
|
459
|
-
function
|
|
460
|
-
return /* @__PURE__ */
|
|
461
|
-
className: f(
|
|
462
|
-
children: [t.map(({ id: e, onClick: t, label: n, styleType: r = W.Default }) => /* @__PURE__ */
|
|
459
|
+
function Ge({ className: e = "", actions: t = [], children: n = null }) {
|
|
460
|
+
return /* @__PURE__ */ I("div", {
|
|
461
|
+
className: f(q.cardActions, e),
|
|
462
|
+
children: [t.map(({ id: e, onClick: t, label: n, styleType: r = W.Default }) => /* @__PURE__ */ F("div", { children: /* @__PURE__ */ F(G, {
|
|
463
463
|
onClick: t,
|
|
464
464
|
styleType: r,
|
|
465
465
|
children: n
|
|
466
466
|
}) }, e ?? n)), n]
|
|
467
467
|
});
|
|
468
468
|
}
|
|
469
|
-
var
|
|
469
|
+
var Ke = {
|
|
470
470
|
checkbox: "checkbox_VO3c2",
|
|
471
471
|
"checkbox-icon": "checkbox-icon_7O0Hm",
|
|
472
472
|
checkboxIcon: "checkbox-icon_7O0Hm",
|
|
@@ -485,7 +485,7 @@ var qe = {
|
|
|
485
485
|
};
|
|
486
486
|
//#endregion
|
|
487
487
|
//#region package/common/checkbox/checkbox.tsx
|
|
488
|
-
function
|
|
488
|
+
function qe({ label: e = "", selected: t = !1, onToggle: n = () => {}, className: r = "", style: i, disabled: o = !1, lineHeight: s = "", title: c = "", tabIndex: l = 0, cursorDefault: p = !1, width: m = "17px", height: h = "17px", formValidator: g = null, children: _ = null, background: v = null, isLoading: y = !1, classNames: b, styles: x, ...S }) {
|
|
489
489
|
let C = u(null), [, w] = d(0);
|
|
490
490
|
a(() => {
|
|
491
491
|
if (!g) return;
|
|
@@ -496,11 +496,11 @@ function Je({ label: e = "", selected: t = !1, onToggle: n = () => {}, className
|
|
|
496
496
|
o || y || (C.current?.addRipple(), g && g.set(!g.value), n(!t, e));
|
|
497
497
|
}
|
|
498
498
|
let E = g ? g.value : t;
|
|
499
|
-
return /* @__PURE__ */
|
|
499
|
+
return /* @__PURE__ */ I("div", {
|
|
500
500
|
...S,
|
|
501
|
-
className: f(
|
|
502
|
-
[
|
|
503
|
-
[
|
|
501
|
+
className: f(Ke.checkbox, {
|
|
502
|
+
[Ke.checkboxDisabled]: o,
|
|
503
|
+
[Ke.checkboxPointer]: !p
|
|
504
504
|
}, r),
|
|
505
505
|
style: i,
|
|
506
506
|
onClick: T,
|
|
@@ -510,30 +510,30 @@ function Je({ label: e = "", selected: t = !1, onToggle: n = () => {}, className
|
|
|
510
510
|
role: "checkbox",
|
|
511
511
|
"aria-checked": E,
|
|
512
512
|
tabIndex: l,
|
|
513
|
-
children: [/* @__PURE__ */
|
|
513
|
+
children: [/* @__PURE__ */ F("div", {
|
|
514
514
|
title: c,
|
|
515
|
-
className: f(
|
|
515
|
+
className: f(Ke.checkboxIcon, y ? Ke.checkboxLoading : null, b?.icon),
|
|
516
516
|
style: x?.icon,
|
|
517
|
-
children: y ? /* @__PURE__ */
|
|
517
|
+
children: y ? /* @__PURE__ */ F("div", {
|
|
518
518
|
style: {
|
|
519
519
|
width: m,
|
|
520
520
|
height: h
|
|
521
521
|
},
|
|
522
|
-
children: /* @__PURE__ */
|
|
523
|
-
}) : /* @__PURE__ */
|
|
522
|
+
children: /* @__PURE__ */ F(Oe, { className: Ke.checkboxLoadingSpinner })
|
|
523
|
+
}) : /* @__PURE__ */ I("div", {
|
|
524
524
|
style: {
|
|
525
525
|
width: m,
|
|
526
526
|
height: h,
|
|
527
527
|
...x?.checkmark
|
|
528
528
|
},
|
|
529
|
-
className: f(
|
|
530
|
-
children: [/* @__PURE__ */
|
|
529
|
+
className: f(Ke.checkboxCheckmark, E && Ke.checkboxCheckmarkChecked, b?.checkmark),
|
|
530
|
+
children: [/* @__PURE__ */ F(Me, {
|
|
531
531
|
ref: C,
|
|
532
532
|
manualOnly: !0,
|
|
533
533
|
overflowHidden: !1,
|
|
534
534
|
rippleAnimationLength: .3,
|
|
535
535
|
rippleBackground: "radial-gradient(transparent, var(--primary-color))"
|
|
536
|
-
}), /* @__PURE__ */
|
|
536
|
+
}), /* @__PURE__ */ F("svg", {
|
|
537
537
|
strokeLinejoin: "round",
|
|
538
538
|
strokeLinecap: "round",
|
|
539
539
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -541,14 +541,14 @@ function Je({ label: e = "", selected: t = !1, onToggle: n = () => {}, className
|
|
|
541
541
|
width: `calc(${m} + 1px)`,
|
|
542
542
|
height: `calc(${h} + 1px)`,
|
|
543
543
|
...v ? { style: { background: v } } : {},
|
|
544
|
-
children: /* @__PURE__ */
|
|
544
|
+
children: /* @__PURE__ */ F("path", {
|
|
545
545
|
d: "M 0 0 l 1 1 l 2 -2",
|
|
546
546
|
strokeWidth: "0.4",
|
|
547
547
|
fill: "none"
|
|
548
548
|
})
|
|
549
549
|
})]
|
|
550
550
|
})
|
|
551
|
-
}), /* @__PURE__ */
|
|
551
|
+
}), /* @__PURE__ */ F("div", {
|
|
552
552
|
className: b?.label,
|
|
553
553
|
style: {
|
|
554
554
|
lineHeight: s || "100%",
|
|
@@ -558,7 +558,7 @@ function Je({ label: e = "", selected: t = !1, onToggle: n = () => {}, className
|
|
|
558
558
|
})]
|
|
559
559
|
});
|
|
560
560
|
}
|
|
561
|
-
var
|
|
561
|
+
var Je = {
|
|
562
562
|
chip: "chip_rCTMl",
|
|
563
563
|
"chip-clickable": "chip-clickable_WTVjG",
|
|
564
564
|
chipClickable: "chip-clickable_WTVjG",
|
|
@@ -575,30 +575,30 @@ var Ye = {
|
|
|
575
575
|
};
|
|
576
576
|
//#endregion
|
|
577
577
|
//#region package/common/chip/chip.tsx
|
|
578
|
-
function
|
|
578
|
+
function Ye({ className: e = "", thumbnail: t = "", text: n = "", showRemoveIcon: r = !1, onClick: i, onRemove: a, ...o }) {
|
|
579
579
|
let s = c(() => {
|
|
580
580
|
if (typeof t == "string" && t.startsWith("http")) return t;
|
|
581
581
|
}, [t]);
|
|
582
|
-
return /* @__PURE__ */
|
|
582
|
+
return /* @__PURE__ */ F("div", {
|
|
583
583
|
...o,
|
|
584
|
-
className: f(
|
|
584
|
+
className: f(Je.chip, i && Je.chipClickable, e),
|
|
585
585
|
onClick: i,
|
|
586
|
-
children: /* @__PURE__ */
|
|
586
|
+
children: /* @__PURE__ */ F(Me, {
|
|
587
587
|
disabled: !i,
|
|
588
588
|
style: { borderRadius: "inherit" },
|
|
589
|
-
children: /* @__PURE__ */
|
|
590
|
-
className:
|
|
589
|
+
children: /* @__PURE__ */ I("div", {
|
|
590
|
+
className: Je.chipInner,
|
|
591
591
|
children: [
|
|
592
|
-
t && /* @__PURE__ */
|
|
593
|
-
className:
|
|
592
|
+
t && /* @__PURE__ */ F("div", {
|
|
593
|
+
className: Je.chipThumbnail,
|
|
594
594
|
style: s ? { backgroundImage: `url(${s})` } : {},
|
|
595
595
|
children: !s && t
|
|
596
596
|
}),
|
|
597
|
-
/* @__PURE__ */
|
|
598
|
-
className:
|
|
597
|
+
/* @__PURE__ */ F("div", {
|
|
598
|
+
className: Je.chipText,
|
|
599
599
|
children: n
|
|
600
600
|
}),
|
|
601
|
-
r && /* @__PURE__ */
|
|
601
|
+
r && /* @__PURE__ */ F(ze, {
|
|
602
602
|
icon: P,
|
|
603
603
|
onClick: (e) => {
|
|
604
604
|
e.stopPropagation(), a?.();
|
|
@@ -611,14 +611,14 @@ function Xe({ className: e = "", thumbnail: t = "", text: n = "", showRemoveIcon
|
|
|
611
611
|
}
|
|
612
612
|
//#endregion
|
|
613
613
|
//#region package/common/chip/chipContainer.tsx
|
|
614
|
-
function
|
|
615
|
-
return /* @__PURE__ */
|
|
614
|
+
function Xe({ className: e = void 0, children: t = null, inline: n = !1, ...r }) {
|
|
615
|
+
return /* @__PURE__ */ F("div", {
|
|
616
616
|
...r,
|
|
617
|
-
className: f(
|
|
617
|
+
className: f(Je.chipContainer, n && Je.chipContainerInline, e),
|
|
618
618
|
children: t
|
|
619
619
|
});
|
|
620
620
|
}
|
|
621
|
-
var
|
|
621
|
+
var Ze = {
|
|
622
622
|
floatingMenu: "floatingMenu_E1XCy",
|
|
623
623
|
"floatingMenu-content": "floatingMenu-content_AmxkA",
|
|
624
624
|
floatingMenuContent: "floatingMenu-content_AmxkA",
|
|
@@ -641,15 +641,15 @@ var Qe = {
|
|
|
641
641
|
"floatingMenu-anim": "floatingMenu-anim_5KB-f",
|
|
642
642
|
floatingMenuAnim: "floatingMenu-anim_5KB-f",
|
|
643
643
|
showMenu: "showMenu_AprCh"
|
|
644
|
-
},
|
|
644
|
+
}, Qe = /* @__PURE__ */ function(e) {
|
|
645
645
|
return e.Left = "left", e.Right = "right", e.Center = "center", e;
|
|
646
646
|
}({});
|
|
647
647
|
//#endregion
|
|
648
648
|
//#region package/common/floatingMenu/floatingMenu.tsx
|
|
649
|
-
function
|
|
649
|
+
function $e(e) {
|
|
650
650
|
return e.charAt(0).toUpperCase() + e.slice(1);
|
|
651
651
|
}
|
|
652
|
-
function
|
|
652
|
+
function et({ align: e = Qe.Left, children: t = null, content: n = null, isOpen: r = !1, onOpenChange: i = () => {}, dontCloseOnChildClick: o = !1, className: s, style: c, classNames: l, styles: p, ...m }) {
|
|
653
653
|
let h = u(null), g = u(null), _ = u(i), [v, y] = d(10), [b, x] = d(null);
|
|
654
654
|
a(() => {
|
|
655
655
|
_.current = i;
|
|
@@ -684,21 +684,21 @@ function tt({ align: e = $e.Left, children: t = null, content: n = null, isOpen:
|
|
|
684
684
|
!r && !i && setTimeout(() => _.current(!1), 1);
|
|
685
685
|
}
|
|
686
686
|
return window.addEventListener("mouseup", e), () => window.removeEventListener("mouseup", e);
|
|
687
|
-
}, [r, o]), /* @__PURE__ */
|
|
687
|
+
}, [r, o]), /* @__PURE__ */ I("div", {
|
|
688
688
|
...m,
|
|
689
|
-
className: f(
|
|
689
|
+
className: f(Ze.floatingMenu, s, l?.root),
|
|
690
690
|
style: {
|
|
691
691
|
...c,
|
|
692
692
|
...p?.root
|
|
693
693
|
},
|
|
694
|
-
children: [/* @__PURE__ */
|
|
695
|
-
className: f(
|
|
694
|
+
children: [/* @__PURE__ */ F("div", {
|
|
695
|
+
className: f(Ze.floatingMenuContent, l?.trigger),
|
|
696
696
|
style: p?.trigger,
|
|
697
697
|
ref: g,
|
|
698
698
|
onClick: S,
|
|
699
699
|
children: t
|
|
700
|
-
}), r && /* @__PURE__ */
|
|
701
|
-
className: f(
|
|
700
|
+
}), r && /* @__PURE__ */ I("div", {
|
|
701
|
+
className: f(Ze.floatingMenuAnim, l?.menu),
|
|
702
702
|
style: {
|
|
703
703
|
width: `${v}px`,
|
|
704
704
|
...b && {
|
|
@@ -707,16 +707,16 @@ function tt({ align: e = $e.Left, children: t = null, content: n = null, isOpen:
|
|
|
707
707
|
},
|
|
708
708
|
...p?.menu
|
|
709
709
|
},
|
|
710
|
-
children: [/* @__PURE__ */
|
|
710
|
+
children: [/* @__PURE__ */ F("div", { className: f(Ze.floatingMenuContainerFlag, Ze[`floatingMenuContainerFlagAlign${$e(e)}`]) }), /* @__PURE__ */ F("div", {
|
|
711
711
|
ref: h,
|
|
712
|
-
className: f(
|
|
712
|
+
className: f(Ze.floatingMenuContainer, Ze[`floatingMenuContainerAlign${$e(e)}`], l?.menuContainer),
|
|
713
713
|
style: p?.menuContainer,
|
|
714
714
|
children: n
|
|
715
715
|
})]
|
|
716
716
|
})]
|
|
717
717
|
});
|
|
718
718
|
}
|
|
719
|
-
var
|
|
719
|
+
var tt = {
|
|
720
720
|
tooltipBubble: "tooltipBubble_uyev0",
|
|
721
721
|
tooltipDetails: "tooltipDetails_R7N16",
|
|
722
722
|
"tooltipDetails-icon": "tooltipDetails-icon_rsjns",
|
|
@@ -725,30 +725,30 @@ var nt = {
|
|
|
725
725
|
};
|
|
726
726
|
//#endregion
|
|
727
727
|
//#region package/common/tooltip/tooltip.tsx
|
|
728
|
-
function
|
|
728
|
+
function nt({ variant: e, message: t = "", isVisible: n = !0, tooltipPosition: r, onClick: i }) {
|
|
729
729
|
let [a, o] = d(!1);
|
|
730
|
-
return e === "info" ? n ? /* @__PURE__ */
|
|
731
|
-
className: f(
|
|
730
|
+
return e === "info" ? n ? /* @__PURE__ */ F("div", {
|
|
731
|
+
className: f(tt.tooltipBubble, r),
|
|
732
732
|
onClick: i,
|
|
733
733
|
children: t
|
|
734
|
-
}) : null : e === "details" ? /* @__PURE__ */
|
|
735
|
-
className:
|
|
736
|
-
children: [/* @__PURE__ */
|
|
737
|
-
className:
|
|
734
|
+
}) : null : e === "details" ? /* @__PURE__ */ I("div", {
|
|
735
|
+
className: tt.tooltipDetails,
|
|
736
|
+
children: [/* @__PURE__ */ F("span", {
|
|
737
|
+
className: tt.tooltipDetailsIcon,
|
|
738
738
|
onMouseEnter: () => o(!0),
|
|
739
739
|
onMouseLeave: () => o(!1),
|
|
740
740
|
children: "?"
|
|
741
|
-
}), a && /* @__PURE__ */
|
|
742
|
-
className: f(
|
|
741
|
+
}), a && /* @__PURE__ */ F("div", {
|
|
742
|
+
className: f(tt.tooltipBubble, r),
|
|
743
743
|
children: t
|
|
744
744
|
})]
|
|
745
|
-
}) : e === "error" && n ? /* @__PURE__ */
|
|
746
|
-
className: f(
|
|
745
|
+
}) : e === "error" && n ? /* @__PURE__ */ F("div", {
|
|
746
|
+
className: f(tt.tooltipError, r),
|
|
747
747
|
onClick: i,
|
|
748
748
|
children: t
|
|
749
749
|
}) : null;
|
|
750
750
|
}
|
|
751
|
-
var
|
|
751
|
+
var J = {
|
|
752
752
|
"required-mark": "required-mark_xGJdX",
|
|
753
753
|
requiredMark: "required-mark_xGJdX",
|
|
754
754
|
isRequired: "isRequired_Jkn3h",
|
|
@@ -800,10 +800,6 @@ var q = {
|
|
|
800
800
|
inputFieldWithIcon: "input-field-withIcon_VpfmK",
|
|
801
801
|
"input-field-withIcon-left": "input-field-withIcon-left_Io7lU",
|
|
802
802
|
inputFieldWithIconLeft: "input-field-withIcon-left_Io7lU",
|
|
803
|
-
"input-field-field": "input-field-field_u6UjZ",
|
|
804
|
-
inputFieldField: "input-field-field_u6UjZ",
|
|
805
|
-
"input-field-field-default": "input-field-field-default_huHVO",
|
|
806
|
-
inputFieldFieldDefault: "input-field-field-default_huHVO",
|
|
807
803
|
"input-field-suffix": "input-field-suffix_NZpXp",
|
|
808
804
|
inputFieldSuffix: "input-field-suffix_NZpXp",
|
|
809
805
|
"input-field-date": "input-field-date_UHJEZ",
|
|
@@ -824,180 +820,182 @@ var q = {
|
|
|
824
820
|
inputFieldIconNotClickable: "input-field-icon-notClickable_7j24I",
|
|
825
821
|
"input-error": "input-error_LIG23",
|
|
826
822
|
inputError: "input-error_LIG23"
|
|
827
|
-
},
|
|
823
|
+
}, Y = /* @__PURE__ */ function(e) {
|
|
828
824
|
return e.Edit = "edit", e.Phone = "phone", e.Email = "email", e.Iban = "iban", e.Date = "date", e.HasNoIcon = "hasNoIcon", e.Search = "searchInput", e.Password = "password", e;
|
|
829
825
|
}({});
|
|
830
826
|
//#endregion
|
|
831
827
|
//#region package/common/input/input.tsx
|
|
832
|
-
function
|
|
833
|
-
let [
|
|
834
|
-
let e =
|
|
828
|
+
function rt({ name: t = "", label: n = "", errorMessage: r = "", isValid: o = !0, className: s = "", style: c, value: l = "", icon: m = null, onChange: h = () => {}, onFocus: g = null, onBlur: _ = null, onMouseEnter: v = null, onMouseLeave: y = null, isUppercase: b = !1, isRequired: x = !1, tabIndex: S = 0, type: C = void 0, isRow: w = !1, onIconClick: D = null, parse: O = null, formValidator: k = null, autoFocus: te = !1, suffix: ne = null, upperRightLabel: M = null, labelInBorder: re = !1, showCancel: ie = !1, onClearClicked: ae, min: oe = null, max: P = null, placeholder: ce = "", useMatLabelStyle: L = !0, autoComplete: le = null, onClick: ue = () => null, readOnly: de = !1, customInput: fe, alwaysShowCancel: pe = !1, multiline: R = !1, rows: me, autoResize: he = !1, classNames: z, styles: B, disabled: V = !1, ...ge }) {
|
|
829
|
+
let [_e, ve] = d(!1), [ye, H] = d(!1), [be, xe] = d(!1), [, Se] = d(0), Ce = u(null), we = u(k), Te = i(() => {
|
|
830
|
+
let e = Ce.current;
|
|
835
831
|
!e || !he || (e.style.height = "auto", e.style.height = `${e.scrollHeight}px`);
|
|
836
832
|
}, [he]);
|
|
837
833
|
a(() => {
|
|
838
834
|
setTimeout(() => {
|
|
839
|
-
|
|
840
|
-
}, 1),
|
|
835
|
+
ve(!1), H(!1);
|
|
836
|
+
}, 1), Te();
|
|
841
837
|
}, []), a(() => {
|
|
842
|
-
te &&
|
|
843
|
-
|
|
838
|
+
te && Ce.current && setTimeout(() => {
|
|
839
|
+
Ce.current?.focus();
|
|
844
840
|
}, 1);
|
|
845
841
|
}, [te]), a(() => {
|
|
846
|
-
|
|
847
|
-
let e =
|
|
842
|
+
we.current = k;
|
|
843
|
+
let e = we.current;
|
|
848
844
|
if (!e) return;
|
|
849
845
|
e.label = n ?? "", e.validate();
|
|
850
|
-
let t = () =>
|
|
846
|
+
let t = () => Se((e) => e + 1);
|
|
851
847
|
return e.registerOnUpdateListener(t), () => {
|
|
852
848
|
e.removeOnUpdateListener(t);
|
|
853
849
|
};
|
|
854
850
|
}, [k, n]);
|
|
855
|
-
let
|
|
851
|
+
let U = () => k ? k.touched && k.hasError() : !o || !!r, Ee = () => !!(x || k && k.validators.find((e) => e.validatorId === "required")), De = (e) => {
|
|
856
852
|
H(!0), v && v(e);
|
|
857
|
-
}, Ee = (e) => {
|
|
858
|
-
H(!1), y && y(e);
|
|
859
|
-
}, De = (e) => {
|
|
860
|
-
ge(!0), g && g(e);
|
|
861
853
|
}, Oe = (e) => {
|
|
862
|
-
|
|
854
|
+
H(!1), y && y(e);
|
|
863
855
|
}, W = (e) => {
|
|
856
|
+
ve(!0), g && g(e);
|
|
857
|
+
}, ke = (e) => {
|
|
858
|
+
we.current && (we.current.touched = !0), ve(!1), _ && _(e);
|
|
859
|
+
}, Ae = (e) => {
|
|
864
860
|
let t, n;
|
|
865
|
-
typeof e == "string" ? n = e : (t = e, n = e.target.value), O && (n = O(n)), k && k.set(n), h && h(n, t),
|
|
866
|
-
},
|
|
867
|
-
if (C !== "email") return C === "password" &&
|
|
868
|
-
},
|
|
869
|
-
className: f(
|
|
870
|
-
[
|
|
871
|
-
[
|
|
861
|
+
typeof e == "string" ? n = e : (t = e, n = e.target.value), O && (n = O(n)), k && k.set(n), h && h(n, t), Te();
|
|
862
|
+
}, je = () => {
|
|
863
|
+
if (C !== "email") return C === "password" && be ? "text" : C;
|
|
864
|
+
}, Me = C && C !== Y.Date && C !== Y.Iban && C !== Y.HasNoIcon, Ne = Me && !L && (C === Y.Email || C === Y.Phone || C === Y.Search), Pe = {
|
|
865
|
+
className: f(J.inputFieldIcon, {
|
|
866
|
+
[J.inputFieldIconNotClickable]: !D,
|
|
867
|
+
[J.inputFieldIconLeft]: Ne
|
|
872
868
|
}),
|
|
873
869
|
onClick: D ?? void 0
|
|
874
|
-
},
|
|
875
|
-
className: f(
|
|
876
|
-
onClick: () =>
|
|
877
|
-
},
|
|
878
|
-
|
|
879
|
-
let
|
|
880
|
-
return /* @__PURE__ */
|
|
881
|
-
className: f(
|
|
870
|
+
}, G = {
|
|
871
|
+
className: f(J.inputFieldIcon, J.inputFieldIconPassword),
|
|
872
|
+
onClick: () => xe(!be)
|
|
873
|
+
}, Fe = U(), Ie = n;
|
|
874
|
+
Ie && Ee() && (Ie = `${Ie} *`);
|
|
875
|
+
let Le = k ? k.value : l, K = L && (_e || Le || C === Y.Date);
|
|
876
|
+
return /* @__PURE__ */ I("div", {
|
|
877
|
+
className: f(J.input, s),
|
|
882
878
|
style: c,
|
|
883
879
|
children: [
|
|
884
|
-
/* @__PURE__ */
|
|
880
|
+
/* @__PURE__ */ I("label", {
|
|
885
881
|
htmlFor: t,
|
|
886
|
-
className: f(
|
|
887
|
-
[
|
|
888
|
-
[
|
|
882
|
+
className: f(J.inputLabel, z?.label, {
|
|
883
|
+
[J.inputLabelColumn]: !w,
|
|
884
|
+
[J.inputLabelInBorder]: re
|
|
889
885
|
}),
|
|
890
886
|
style: B?.label,
|
|
891
887
|
children: [
|
|
892
|
-
|
|
893
|
-
className:
|
|
894
|
-
children: [`${
|
|
895
|
-
className: f(
|
|
888
|
+
Ie && !L ? /* @__PURE__ */ I("span", {
|
|
889
|
+
className: J.inputLabelText,
|
|
890
|
+
children: [`${Ie} `, Ee() ? /* @__PURE__ */ F("span", {
|
|
891
|
+
className: f(J.isRequired),
|
|
896
892
|
children: "\xA0 *"
|
|
897
893
|
}) : null]
|
|
898
894
|
}) : null,
|
|
899
|
-
M && /* @__PURE__ */
|
|
900
|
-
className: f(
|
|
895
|
+
M && /* @__PURE__ */ F("div", {
|
|
896
|
+
className: f(J.inputUpperRightLabel, z?.upperRightLabel),
|
|
901
897
|
style: B?.upperRightLabel,
|
|
902
898
|
children: M
|
|
903
899
|
}),
|
|
904
|
-
/* @__PURE__ */
|
|
905
|
-
className: f(
|
|
900
|
+
/* @__PURE__ */ I("div", {
|
|
901
|
+
className: f(J.inputContainer, { [J.inputContainerMultiline]: R }, z?.container),
|
|
906
902
|
style: B?.container,
|
|
907
|
-
onMouseEnter:
|
|
908
|
-
onMouseLeave:
|
|
903
|
+
onMouseEnter: De,
|
|
904
|
+
onMouseLeave: Oe,
|
|
909
905
|
children: [
|
|
910
906
|
m,
|
|
911
|
-
e.cloneElement(fe ||
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
[
|
|
915
|
-
[
|
|
916
|
-
[
|
|
917
|
-
[
|
|
918
|
-
[
|
|
919
|
-
[
|
|
907
|
+
e.cloneElement(fe || F(R ? "textarea" : "input", {}), {
|
|
908
|
+
...ge,
|
|
909
|
+
className: f(J.inputField, {
|
|
910
|
+
[J.inputFieldUppercase]: b,
|
|
911
|
+
[J.inputFieldDate]: C === Y.Date,
|
|
912
|
+
[J.inputFieldDefault]: C !== Y.Date,
|
|
913
|
+
[J.inputFieldWithIcon]: Me,
|
|
914
|
+
[J.inputFieldWithIconLeft]: Ne,
|
|
915
|
+
[J.inputFieldMultiline]: R,
|
|
916
|
+
[J.inputFieldMultilineAutoResize]: R && he
|
|
920
917
|
}, z?.input),
|
|
921
918
|
name: t,
|
|
922
919
|
id: t,
|
|
923
920
|
value: k ? k.value : l,
|
|
924
921
|
tabIndex: S,
|
|
925
|
-
ref: fe ? void 0 :
|
|
926
|
-
onChange:
|
|
927
|
-
onFocus:
|
|
928
|
-
onBlur:
|
|
929
|
-
placeholder:
|
|
922
|
+
ref: fe ? void 0 : Ce,
|
|
923
|
+
onChange: Ae,
|
|
924
|
+
onFocus: W,
|
|
925
|
+
onBlur: ke,
|
|
926
|
+
placeholder: L ? "" : ce,
|
|
930
927
|
autoComplete: le,
|
|
931
928
|
onClick: ue,
|
|
932
929
|
readOnly: de,
|
|
930
|
+
disabled: V,
|
|
933
931
|
...!R && {
|
|
934
|
-
type:
|
|
932
|
+
type: je(),
|
|
935
933
|
min: oe,
|
|
936
934
|
max: P
|
|
937
935
|
},
|
|
938
936
|
...R && me !== void 0 && { rows: me }
|
|
939
937
|
}),
|
|
940
|
-
ne && /* @__PURE__ */
|
|
941
|
-
className: f(
|
|
938
|
+
ne && /* @__PURE__ */ F("div", {
|
|
939
|
+
className: f(J.inputFieldSuffix, z?.suffix),
|
|
942
940
|
style: B?.suffix,
|
|
943
941
|
children: ne
|
|
944
942
|
})
|
|
945
943
|
]
|
|
946
944
|
}),
|
|
947
|
-
/* @__PURE__ */
|
|
948
|
-
className: f(
|
|
949
|
-
[
|
|
950
|
-
[
|
|
951
|
-
[
|
|
952
|
-
[
|
|
945
|
+
/* @__PURE__ */ F("fieldset", {
|
|
946
|
+
className: f(J.inputFieldset, z?.fieldset, {
|
|
947
|
+
[J.inputContainerBorderFocused]: _e,
|
|
948
|
+
[J.inputContainerBorderSearchFocused]: C === Y.Search && (_e || l),
|
|
949
|
+
[J.inputContainerBorderInvalid]: Fe,
|
|
950
|
+
[J.inputContainerBorderError]: Fe
|
|
953
951
|
}),
|
|
954
952
|
style: B?.fieldset,
|
|
955
|
-
children: /* @__PURE__ */
|
|
956
|
-
className: f(
|
|
957
|
-
children: /* @__PURE__ */
|
|
953
|
+
children: /* @__PURE__ */ F("legend", {
|
|
954
|
+
className: f(J.inputFieldsetLegend, { [J.inputFieldsetLegendActive]: K }),
|
|
955
|
+
children: /* @__PURE__ */ F("span", { children: Ie })
|
|
958
956
|
})
|
|
959
957
|
}),
|
|
960
|
-
|
|
961
|
-
className: f(
|
|
962
|
-
[
|
|
963
|
-
[
|
|
958
|
+
L && n && /* @__PURE__ */ F("div", {
|
|
959
|
+
className: f(J.inputMatLabel, {
|
|
960
|
+
[J.inputMatLabelFloating]: K,
|
|
961
|
+
[J.inputMatLabelMultiline]: R && !K
|
|
964
962
|
}),
|
|
965
|
-
children:
|
|
963
|
+
children: Ie
|
|
966
964
|
}),
|
|
967
|
-
|
|
968
|
-
className: f(
|
|
969
|
-
children:
|
|
965
|
+
L && ce && /* @__PURE__ */ F("div", {
|
|
966
|
+
className: f(J.inputPlaceholder, _e && !Le && J.inputPlaceholderShown, R && J.inputPlaceholderMultiline),
|
|
967
|
+
children: ce
|
|
970
968
|
}),
|
|
971
|
-
/* @__PURE__ */
|
|
969
|
+
/* @__PURE__ */ F(nt, {
|
|
972
970
|
variant: "error",
|
|
973
971
|
message: k ? k.getCurrentErrorMessage() : r || "",
|
|
974
|
-
isVisible:
|
|
972
|
+
isVisible: Fe && (_e || ye)
|
|
975
973
|
})
|
|
976
974
|
]
|
|
977
975
|
}),
|
|
978
|
-
C ===
|
|
976
|
+
C === Y.Phone && /* @__PURE__ */ F(p, {
|
|
979
977
|
icon: j,
|
|
980
|
-
...
|
|
978
|
+
...Pe
|
|
981
979
|
}),
|
|
982
|
-
C ===
|
|
980
|
+
C === Y.Email && /* @__PURE__ */ F(p, {
|
|
983
981
|
icon: T,
|
|
984
|
-
...
|
|
982
|
+
...Pe
|
|
985
983
|
}),
|
|
986
|
-
C ===
|
|
984
|
+
C === Y.Edit && /* @__PURE__ */ F(p, {
|
|
987
985
|
icon: A,
|
|
988
|
-
...
|
|
986
|
+
...Pe
|
|
989
987
|
}),
|
|
990
|
-
C ===
|
|
988
|
+
C === Y.Search && /* @__PURE__ */ F(p, {
|
|
991
989
|
icon: N,
|
|
992
|
-
...
|
|
990
|
+
...Pe
|
|
993
991
|
}),
|
|
994
|
-
C ===
|
|
995
|
-
icon:
|
|
996
|
-
...
|
|
992
|
+
C === Y.Password && /* @__PURE__ */ F(p, {
|
|
993
|
+
icon: be ? ee : E,
|
|
994
|
+
...G
|
|
997
995
|
}),
|
|
998
|
-
(ie && l && (
|
|
996
|
+
(ie && l && (_e || ye) || pe) && /* @__PURE__ */ F(p, {
|
|
999
997
|
icon: se,
|
|
1000
|
-
className:
|
|
998
|
+
className: J.inputFieldIcon,
|
|
1001
999
|
onClick: ae ?? void 0,
|
|
1002
1000
|
onMouseEnter: () => H(!0),
|
|
1003
1001
|
onMouseLeave: () => H(!1)
|
|
@@ -1005,7 +1003,7 @@ function it({ name: t = "", label: n = "", errorMessage: r = "", isValid: o = !0
|
|
|
1005
1003
|
]
|
|
1006
1004
|
});
|
|
1007
1005
|
}
|
|
1008
|
-
var
|
|
1006
|
+
var X = {
|
|
1009
1007
|
colorPicker: "colorPicker_Ts3an",
|
|
1010
1008
|
swatch: "swatch_NW78g",
|
|
1011
1009
|
swatchHex: "swatchHex_j7-i5",
|
|
@@ -1020,10 +1018,10 @@ var Y = {
|
|
|
1020
1018
|
};
|
|
1021
1019
|
//#endregion
|
|
1022
1020
|
//#region package/common/colorPicker/colorPicker.tsx
|
|
1023
|
-
function
|
|
1021
|
+
function it(e) {
|
|
1024
1022
|
return /^#[0-9a-fA-F]{6}$/.test(e) || /^#[0-9a-fA-F]{8}$/.test(e);
|
|
1025
1023
|
}
|
|
1026
|
-
function
|
|
1024
|
+
function at(e) {
|
|
1027
1025
|
return /^#[0-9a-fA-F]{8}$/.test(e) ? {
|
|
1028
1026
|
hex6: e.slice(0, 7),
|
|
1029
1027
|
alpha: Math.round(parseInt(e.slice(7, 9), 16) / 255 * 100)
|
|
@@ -1032,13 +1030,13 @@ function ot(e) {
|
|
|
1032
1030
|
alpha: 100
|
|
1033
1031
|
};
|
|
1034
1032
|
}
|
|
1035
|
-
function
|
|
1033
|
+
function ot(e, t, n) {
|
|
1036
1034
|
return !n || t >= 100 ? e : `${e}${Math.round(t / 100 * 255).toString(16).padStart(2, "0")}`;
|
|
1037
1035
|
}
|
|
1038
|
-
function
|
|
1036
|
+
function st(e, t) {
|
|
1039
1037
|
return `rgba(${parseInt(e.slice(1, 3), 16)}, ${parseInt(e.slice(3, 5), 16)}, ${parseInt(e.slice(5, 7), 16)}, ${t / 100})`;
|
|
1040
1038
|
}
|
|
1041
|
-
function
|
|
1039
|
+
function ct(e) {
|
|
1042
1040
|
let t = parseInt(e.slice(1, 3), 16) / 255, n = parseInt(e.slice(3, 5), 16) / 255, r = parseInt(e.slice(5, 7), 16) / 255, i = Math.max(t, n, r), a = i - Math.min(t, n, r), o = 0;
|
|
1043
1041
|
a !== 0 && (o = i === t ? (n - r) / a % 6 : i === n ? (r - t) / a + 2 : (t - n) / a + 4, o = Math.round(o * 60), o < 0 && (o += 360));
|
|
1044
1042
|
let s = i === 0 ? 0 : Math.round(a / i * 100), c = Math.round(i * 100);
|
|
@@ -1048,13 +1046,13 @@ function lt(e) {
|
|
|
1048
1046
|
v: c
|
|
1049
1047
|
};
|
|
1050
1048
|
}
|
|
1051
|
-
function
|
|
1049
|
+
function lt(e, t, n) {
|
|
1052
1050
|
let r = t / 100, i = n / 100, a = i * r, o = a * (1 - Math.abs(e / 60 % 2 - 1)), s = i - a, c = 0, l = 0, u = 0;
|
|
1053
1051
|
e < 60 ? (c = a, l = o, u = 0) : e < 120 ? (c = o, l = a, u = 0) : e < 180 ? (c = 0, l = a, u = o) : e < 240 ? (c = 0, l = o, u = a) : e < 300 ? (c = o, l = 0, u = a) : (c = a, l = 0, u = o);
|
|
1054
1052
|
let d = (e) => Math.round((e + s) * 255).toString(16).padStart(2, "0");
|
|
1055
1053
|
return `#${d(c)}${d(l)}${d(u)}`;
|
|
1056
1054
|
}
|
|
1057
|
-
function
|
|
1055
|
+
function ut({ hex: e, onChange: t, useInputComponent: n = !1 }) {
|
|
1058
1056
|
let [r, i] = d(e);
|
|
1059
1057
|
a(() => {
|
|
1060
1058
|
i(e);
|
|
@@ -1062,25 +1060,25 @@ function dt({ hex: e, onChange: t, useInputComponent: n = !1 }) {
|
|
|
1062
1060
|
function o(e) {
|
|
1063
1061
|
i(e);
|
|
1064
1062
|
let n = e.startsWith("#") ? e : `#${e}`;
|
|
1065
|
-
|
|
1063
|
+
it(n) && t(n);
|
|
1066
1064
|
}
|
|
1067
1065
|
function s() {
|
|
1068
|
-
|
|
1066
|
+
it(r.startsWith("#") ? r : `#${r}`) || i(e);
|
|
1069
1067
|
}
|
|
1070
|
-
return n ? /* @__PURE__ */
|
|
1068
|
+
return n ? /* @__PURE__ */ F(rt, {
|
|
1071
1069
|
value: r,
|
|
1072
1070
|
onChange: (e) => o(e),
|
|
1073
1071
|
onBlur: s
|
|
1074
|
-
}) : /* @__PURE__ */
|
|
1072
|
+
}) : /* @__PURE__ */ F("input", {
|
|
1075
1073
|
type: "text",
|
|
1076
1074
|
value: r,
|
|
1077
1075
|
onChange: (e) => o(e.target.value),
|
|
1078
1076
|
onBlur: s,
|
|
1079
|
-
className:
|
|
1077
|
+
className: X.hexInput,
|
|
1080
1078
|
spellCheck: !1
|
|
1081
1079
|
});
|
|
1082
1080
|
}
|
|
1083
|
-
function
|
|
1081
|
+
function dt({ hue: e, sat: t, val: n, alpha: r, onHueChange: i, onSVChange: a, onAlphaChange: o, showInput: s = !0, showAlpha: c = !1 }) {
|
|
1084
1082
|
let l = u(null);
|
|
1085
1083
|
function d(e) {
|
|
1086
1084
|
let t = l.current.getBoundingClientRect(), n = Math.max(0, Math.min(1, (e.clientX - t.left) / t.width)), r = Math.max(0, Math.min(1, (e.clientY - t.top) / t.height));
|
|
@@ -1101,53 +1099,53 @@ function ft({ hue: e, sat: t, val: n, alpha: r, onHueChange: i, onSVChange: a, o
|
|
|
1101
1099
|
window.addEventListener("mousemove", r), window.addEventListener("mouseup", i);
|
|
1102
1100
|
}
|
|
1103
1101
|
function p(e) {
|
|
1104
|
-
let { hex6: t, alpha: n } =
|
|
1102
|
+
let { hex6: t, alpha: n } = at(e), { h: r, s, v: l } = ct(t);
|
|
1105
1103
|
i(r), a(s, l), c && o(n);
|
|
1106
1104
|
}
|
|
1107
|
-
let m =
|
|
1108
|
-
return /* @__PURE__ */
|
|
1109
|
-
className:
|
|
1105
|
+
let m = lt(e, t, n), h = c ? ot(m, r, !0) : m;
|
|
1106
|
+
return /* @__PURE__ */ I("div", {
|
|
1107
|
+
className: X.panel,
|
|
1110
1108
|
children: [
|
|
1111
|
-
/* @__PURE__ */
|
|
1109
|
+
/* @__PURE__ */ I("div", {
|
|
1112
1110
|
ref: l,
|
|
1113
|
-
className:
|
|
1111
|
+
className: X.gradientArea,
|
|
1114
1112
|
style: { "--hue": e },
|
|
1115
1113
|
onMouseDown: f,
|
|
1116
|
-
children: [/* @__PURE__ */
|
|
1117
|
-
className:
|
|
1114
|
+
children: [/* @__PURE__ */ F("div", { className: X.gradientOverlay }), /* @__PURE__ */ F("div", {
|
|
1115
|
+
className: X.cursor,
|
|
1118
1116
|
style: {
|
|
1119
1117
|
left: `${t}%`,
|
|
1120
1118
|
top: `${100 - n}%`
|
|
1121
1119
|
}
|
|
1122
1120
|
})]
|
|
1123
1121
|
}),
|
|
1124
|
-
/* @__PURE__ */
|
|
1122
|
+
/* @__PURE__ */ F("input", {
|
|
1125
1123
|
type: "range",
|
|
1126
1124
|
min: 0,
|
|
1127
1125
|
max: 359,
|
|
1128
1126
|
value: e,
|
|
1129
1127
|
onChange: (e) => i(Number(e.target.value)),
|
|
1130
|
-
className:
|
|
1128
|
+
className: X.hueSlider
|
|
1131
1129
|
}),
|
|
1132
|
-
c && /* @__PURE__ */
|
|
1130
|
+
c && /* @__PURE__ */ F("input", {
|
|
1133
1131
|
type: "range",
|
|
1134
1132
|
min: 0,
|
|
1135
1133
|
max: 100,
|
|
1136
1134
|
value: r,
|
|
1137
1135
|
onChange: (e) => o(Number(e.target.value)),
|
|
1138
|
-
className:
|
|
1136
|
+
className: X.alphaSlider,
|
|
1139
1137
|
style: { "--alpha-color": m }
|
|
1140
1138
|
}),
|
|
1141
|
-
s && /* @__PURE__ */
|
|
1139
|
+
s && /* @__PURE__ */ F(ut, {
|
|
1142
1140
|
hex: h,
|
|
1143
1141
|
onChange: p
|
|
1144
1142
|
})
|
|
1145
1143
|
]
|
|
1146
1144
|
});
|
|
1147
1145
|
}
|
|
1148
|
-
var
|
|
1149
|
-
function
|
|
1150
|
-
let [s, c] = d(!1), { hex6: l, alpha: p } =
|
|
1146
|
+
var ft = "#3b82f6";
|
|
1147
|
+
function pt({ className: e, value: t = ft, onChange: n, showInput: r = !1, showAlpha: i = !1, inline: a = !1, ...o }) {
|
|
1148
|
+
let [s, c] = d(!1), { hex6: l, alpha: p } = at(it(t) ? t : ft), m = ct(l), [h, g] = d({
|
|
1151
1149
|
h: m.h,
|
|
1152
1150
|
s: m.s,
|
|
1153
1151
|
v: m.v,
|
|
@@ -1155,9 +1153,9 @@ function mt({ className: e, value: t = pt, onChange: n, showInput: r = !1, showA
|
|
|
1155
1153
|
}), _ = u(h), [v, y] = d(t);
|
|
1156
1154
|
if (t !== v) {
|
|
1157
1155
|
y(t);
|
|
1158
|
-
let { hex6: e, alpha: n } =
|
|
1159
|
-
if (e !==
|
|
1160
|
-
let t =
|
|
1156
|
+
let { hex6: e, alpha: n } = at(it(t) ? t : ft);
|
|
1157
|
+
if (e !== lt(h.h, h.s, h.v) || n !== h.a) {
|
|
1158
|
+
let t = ct(e);
|
|
1161
1159
|
g({
|
|
1162
1160
|
h: t.h,
|
|
1163
1161
|
s: t.s,
|
|
@@ -1168,7 +1166,7 @@ function mt({ className: e, value: t = pt, onChange: n, showInput: r = !1, showA
|
|
|
1168
1166
|
}
|
|
1169
1167
|
let { h: b, s: x, v: S, a: C } = h;
|
|
1170
1168
|
function w(e, t, r, a) {
|
|
1171
|
-
n?.(
|
|
1169
|
+
n?.(ot(lt(e, t, r), a, i));
|
|
1172
1170
|
}
|
|
1173
1171
|
function T(e) {
|
|
1174
1172
|
_.current.h = e, g((t) => ({
|
|
@@ -1189,7 +1187,7 @@ function mt({ className: e, value: t = pt, onChange: n, showInput: r = !1, showA
|
|
|
1189
1187
|
a: e
|
|
1190
1188
|
})), w(_.current.h, _.current.s, _.current.v, e);
|
|
1191
1189
|
}
|
|
1192
|
-
let D =
|
|
1190
|
+
let D = lt(b, x, S), O = i ? st(D, C) : D, k = ot(D, C, i), te = {
|
|
1193
1191
|
hue: b,
|
|
1194
1192
|
sat: x,
|
|
1195
1193
|
val: S,
|
|
@@ -1199,40 +1197,40 @@ function mt({ className: e, value: t = pt, onChange: n, showInput: r = !1, showA
|
|
|
1199
1197
|
onAlphaChange: ee,
|
|
1200
1198
|
showAlpha: i
|
|
1201
1199
|
};
|
|
1202
|
-
return a ? /* @__PURE__ */
|
|
1200
|
+
return a ? /* @__PURE__ */ F("div", {
|
|
1203
1201
|
...o,
|
|
1204
|
-
className: f(
|
|
1205
|
-
children: /* @__PURE__ */
|
|
1202
|
+
className: f(X.colorPicker, e),
|
|
1203
|
+
children: /* @__PURE__ */ F(dt, {
|
|
1206
1204
|
...te,
|
|
1207
1205
|
showInput: r
|
|
1208
1206
|
})
|
|
1209
|
-
}) : /* @__PURE__ */
|
|
1207
|
+
}) : /* @__PURE__ */ I("div", {
|
|
1210
1208
|
...o,
|
|
1211
|
-
className: f(
|
|
1212
|
-
children: [/* @__PURE__ */
|
|
1209
|
+
className: f(X.colorPicker, e),
|
|
1210
|
+
children: [/* @__PURE__ */ F(et, {
|
|
1213
1211
|
isOpen: s,
|
|
1214
1212
|
onOpenChange: c,
|
|
1215
1213
|
dontCloseOnChildClick: !0,
|
|
1216
|
-
align:
|
|
1217
|
-
content: /* @__PURE__ */
|
|
1218
|
-
children: /* @__PURE__ */
|
|
1219
|
-
className:
|
|
1220
|
-
children: [/* @__PURE__ */
|
|
1221
|
-
className:
|
|
1214
|
+
align: Qe.Left,
|
|
1215
|
+
content: /* @__PURE__ */ F(dt, { ...te }),
|
|
1216
|
+
children: /* @__PURE__ */ I(K, {
|
|
1217
|
+
className: X.swatch,
|
|
1218
|
+
children: [/* @__PURE__ */ F("div", {
|
|
1219
|
+
className: X.swatchFill,
|
|
1222
1220
|
style: { background: O }
|
|
1223
|
-
}), /* @__PURE__ */
|
|
1224
|
-
className:
|
|
1221
|
+
}), /* @__PURE__ */ F("span", {
|
|
1222
|
+
className: X.swatchHex,
|
|
1225
1223
|
children: k
|
|
1226
1224
|
})]
|
|
1227
1225
|
})
|
|
1228
|
-
}), r && /* @__PURE__ */
|
|
1226
|
+
}), r && /* @__PURE__ */ F(ut, {
|
|
1229
1227
|
hex: k,
|
|
1230
1228
|
onChange: (e) => n?.(e),
|
|
1231
1229
|
useInputComponent: !0
|
|
1232
1230
|
})]
|
|
1233
1231
|
});
|
|
1234
1232
|
}
|
|
1235
|
-
var
|
|
1233
|
+
var mt = {
|
|
1236
1234
|
modal: "modal_L-Fkd",
|
|
1237
1235
|
slideIn: "slideIn_RVIHR",
|
|
1238
1236
|
fadeIn: "fadeIn_XSuIE",
|
|
@@ -1247,32 +1245,32 @@ var ht = {
|
|
|
1247
1245
|
};
|
|
1248
1246
|
//#endregion
|
|
1249
1247
|
//#region package/common/modal/modal.tsx
|
|
1250
|
-
function
|
|
1248
|
+
function ht({ children: e = null, title: t = "", isOpen: n = !1, onClose: r = () => null, className: i = "", style: o, hideHeader: s = !1, classNames: c, styles: l }) {
|
|
1251
1249
|
let [u, m] = d(n), [h, g] = d(n);
|
|
1252
1250
|
return a(() => {
|
|
1253
1251
|
n ? (m(n), setTimeout(() => g(!0), 1)) : (g(!1), setTimeout(() => m(n), 300));
|
|
1254
|
-
}, [n]), u ? /* @__PURE__ */
|
|
1255
|
-
className: f(
|
|
1252
|
+
}, [n]), u ? /* @__PURE__ */ F(Be, { children: /* @__PURE__ */ I("div", {
|
|
1253
|
+
className: f(mt.modalContainer, c?.container),
|
|
1256
1254
|
style: l?.container,
|
|
1257
|
-
children: [/* @__PURE__ */
|
|
1258
|
-
className: f(
|
|
1255
|
+
children: [/* @__PURE__ */ F("div", {
|
|
1256
|
+
className: f(mt.modalWrapper, h && mt.modalWrapperShown, c?.backdrop),
|
|
1259
1257
|
style: l?.backdrop,
|
|
1260
1258
|
onClick: r
|
|
1261
|
-
}), h && /* @__PURE__ */
|
|
1262
|
-
className: f(
|
|
1259
|
+
}), h && /* @__PURE__ */ I("div", {
|
|
1260
|
+
className: f(mt.modal, h && mt.modalShown, i, c?.modal),
|
|
1263
1261
|
style: {
|
|
1264
1262
|
...o,
|
|
1265
1263
|
...l?.modal
|
|
1266
1264
|
},
|
|
1267
1265
|
onClick: (e) => e.stopPropagation(),
|
|
1268
|
-
children: [!s && /* @__PURE__ */
|
|
1269
|
-
className: f(
|
|
1266
|
+
children: [!s && /* @__PURE__ */ I("div", {
|
|
1267
|
+
className: f(mt.modalHeader, c?.header),
|
|
1270
1268
|
style: l?.header,
|
|
1271
|
-
children: [/* @__PURE__ */
|
|
1269
|
+
children: [/* @__PURE__ */ F("div", {
|
|
1272
1270
|
className: c?.title,
|
|
1273
1271
|
style: l?.title,
|
|
1274
1272
|
children: t
|
|
1275
|
-
}), /* @__PURE__ */
|
|
1273
|
+
}), /* @__PURE__ */ F(p, {
|
|
1276
1274
|
onClick: r,
|
|
1277
1275
|
icon: se,
|
|
1278
1276
|
className: c?.closeButton,
|
|
@@ -1284,7 +1282,7 @@ function gt({ children: e = null, title: t = "", isOpen: n = !1, onClose: r = ()
|
|
|
1284
1282
|
}
|
|
1285
1283
|
//#endregion
|
|
1286
1284
|
//#region package/common/confirmModal/confirmModal.tsx
|
|
1287
|
-
function
|
|
1285
|
+
function gt({ children: e = null, className: t = "", onClose: n = () => {}, onConfirm: r = () => {}, title: i = "", content: a = null, isOpen: o = void 0 }) {
|
|
1288
1286
|
let [s, c] = d(!1), [l, u] = d(!1);
|
|
1289
1287
|
function f(e = !1) {
|
|
1290
1288
|
c(!1), n(e);
|
|
@@ -1297,16 +1295,16 @@ function _t({ children: e = null, className: t = "", onClose: n = () => {}, onCo
|
|
|
1297
1295
|
u(!1);
|
|
1298
1296
|
}
|
|
1299
1297
|
}
|
|
1300
|
-
return /* @__PURE__ */
|
|
1298
|
+
return /* @__PURE__ */ I("div", {
|
|
1301
1299
|
className: t,
|
|
1302
|
-
children: [/* @__PURE__ */
|
|
1300
|
+
children: [/* @__PURE__ */ F("span", {
|
|
1303
1301
|
onClick: () => c(!0),
|
|
1304
1302
|
children: e
|
|
1305
|
-
}), /* @__PURE__ */
|
|
1303
|
+
}), /* @__PURE__ */ I(ht, {
|
|
1306
1304
|
title: i,
|
|
1307
1305
|
isOpen: o === void 0 ? s : o,
|
|
1308
1306
|
onClose: () => f(),
|
|
1309
|
-
children: [a, /* @__PURE__ */
|
|
1307
|
+
children: [a, /* @__PURE__ */ F(Fe, {
|
|
1310
1308
|
onClose: () => f(),
|
|
1311
1309
|
onSubmit: p,
|
|
1312
1310
|
submitLabel: "Confirm",
|
|
@@ -1315,7 +1313,7 @@ function _t({ children: e = null, className: t = "", onClose: n = () => {}, onCo
|
|
|
1315
1313
|
})]
|
|
1316
1314
|
});
|
|
1317
1315
|
}
|
|
1318
|
-
var
|
|
1316
|
+
var _t = {
|
|
1319
1317
|
"datePickerMonth-item": "datePickerMonth-item_30WWy",
|
|
1320
1318
|
datePickerMonthItem: "datePickerMonth-item_30WWy",
|
|
1321
1319
|
"datePickerMonth-content": "datePickerMonth-content_9bbSs",
|
|
@@ -1334,7 +1332,7 @@ var vt = {
|
|
|
1334
1332
|
datePickerMonthDayDisabled: "datePickerMonth-day-disabled_4t0Ci",
|
|
1335
1333
|
"datePickerMonth-placeholder": "datePickerMonth-placeholder_gy1Yx",
|
|
1336
1334
|
datePickerMonthPlaceholder: "datePickerMonth-placeholder_gy1Yx"
|
|
1337
|
-
},
|
|
1335
|
+
}, vt = [
|
|
1338
1336
|
"de_AT",
|
|
1339
1337
|
"de_CH",
|
|
1340
1338
|
"de_DE",
|
|
@@ -1342,10 +1340,10 @@ var vt = {
|
|
|
1342
1340
|
"en_GB",
|
|
1343
1341
|
"de",
|
|
1344
1342
|
"en"
|
|
1345
|
-
],
|
|
1346
|
-
let e = navigator.languages[0]?.replace("-", "_") ||
|
|
1347
|
-
return
|
|
1348
|
-
},
|
|
1343
|
+
], yt = "en_US", bt = () => {
|
|
1344
|
+
let e = navigator.languages[0]?.replace("-", "_") || yt;
|
|
1345
|
+
return vt.includes(e) ? e === "en_GB" || e === "en" ? "en_US" : e === "de" ? "de_DE" : e : yt;
|
|
1346
|
+
}, xt = (e) => {
|
|
1349
1347
|
switch (e) {
|
|
1350
1348
|
case "en_US":
|
|
1351
1349
|
case "en_GB": return "en";
|
|
@@ -1354,47 +1352,47 @@ var vt = {
|
|
|
1354
1352
|
case "de_AT": return "de";
|
|
1355
1353
|
default: return "de";
|
|
1356
1354
|
}
|
|
1357
|
-
},
|
|
1358
|
-
async function
|
|
1359
|
-
|
|
1355
|
+
}, St = bt();
|
|
1356
|
+
async function Ct(e) {
|
|
1357
|
+
St = e;
|
|
1360
1358
|
}
|
|
1361
|
-
function
|
|
1362
|
-
return
|
|
1359
|
+
function wt(e = "_") {
|
|
1360
|
+
return St.replace("_", e);
|
|
1363
1361
|
}
|
|
1364
1362
|
//#endregion
|
|
1365
1363
|
//#region package/common/datePicker/dateFunctions.ts
|
|
1366
|
-
function
|
|
1364
|
+
function Tt(e, t) {
|
|
1367
1365
|
return new Date(t, e, 0).getDate();
|
|
1368
1366
|
}
|
|
1369
|
-
function
|
|
1367
|
+
function Et(e, t, n) {
|
|
1370
1368
|
return new Date(Date.UTC(n, t - 1, e));
|
|
1371
1369
|
}
|
|
1372
|
-
function
|
|
1370
|
+
function Dt(e, t, n, r, i = !1) {
|
|
1373
1371
|
return new Date(Date.UTC(t, n - 1, r)).toLocaleDateString(e, { month: i ? "short" : "long" });
|
|
1374
1372
|
}
|
|
1375
|
-
function
|
|
1376
|
-
return Array.from(Array(12).keys()).map((t) =>
|
|
1373
|
+
function Ot(e = wt("-")) {
|
|
1374
|
+
return Array.from(Array(12).keys()).map((t) => Dt(e, 2023, t + 1, 1));
|
|
1377
1375
|
}
|
|
1378
|
-
function
|
|
1376
|
+
function kt(e, t = !0) {
|
|
1379
1377
|
let n = new Date(Date.UTC(2023, 3, 10)), r = [];
|
|
1380
1378
|
for (let i = 0; i < 7; i++) r.push(n.toLocaleDateString(e, { weekday: t ? "short" : "long" })), n.setDate(n.getDate() + 1);
|
|
1381
1379
|
return r;
|
|
1382
1380
|
}
|
|
1383
|
-
function
|
|
1381
|
+
function At(e, t) {
|
|
1384
1382
|
return new Date(Date.UTC(t, e - 1, 1)).getDay() || 7;
|
|
1385
1383
|
}
|
|
1386
|
-
function
|
|
1384
|
+
function jt(e) {
|
|
1387
1385
|
return {
|
|
1388
1386
|
day: e.getDate(),
|
|
1389
1387
|
month: e.getMonth() + 1,
|
|
1390
1388
|
year: e.getFullYear()
|
|
1391
1389
|
};
|
|
1392
1390
|
}
|
|
1393
|
-
function
|
|
1391
|
+
function Mt(e) {
|
|
1394
1392
|
let t = e.getDate(), n = e.getMonth() + 1, r = e.getFullYear();
|
|
1395
1393
|
return `${t < 10 ? `0${t}` : t}.${n < 10 ? `0${n}` : n}.${r}`;
|
|
1396
1394
|
}
|
|
1397
|
-
function
|
|
1395
|
+
function Nt(e, t, n) {
|
|
1398
1396
|
let r = e, i = n;
|
|
1399
1397
|
return r[0] !== "_" && (r[0] > "3" ? (r = `0${r[0]}${t.substring(2)}`, i = {
|
|
1400
1398
|
start: 3,
|
|
@@ -1412,18 +1410,18 @@ function Pt(e, t, n) {
|
|
|
1412
1410
|
}
|
|
1413
1411
|
//#endregion
|
|
1414
1412
|
//#region package/common/datePicker/components/datePickerMonth/datePickerMonth.tsx
|
|
1415
|
-
function
|
|
1416
|
-
let { day: a, month: o, year: s } = r ?
|
|
1413
|
+
function Pt(e, t, n, r, i) {
|
|
1414
|
+
let { day: a, month: o, year: s } = r ? jt(r) : {
|
|
1417
1415
|
day: void 0,
|
|
1418
1416
|
month: void 0,
|
|
1419
1417
|
year: void 0
|
|
1420
|
-
}, { day: c, month: l, year: u } = i ?
|
|
1418
|
+
}, { day: c, month: l, year: u } = i ? jt(i) : {
|
|
1421
1419
|
day: void 0,
|
|
1422
1420
|
month: void 0,
|
|
1423
1421
|
year: void 0
|
|
1424
|
-
}, d =
|
|
1422
|
+
}, d = Et(e, t, n), f = e === a && t === o && n === s, p = e === c && t === l && n === u, m = !1;
|
|
1425
1423
|
if (a !== void 0 && o !== void 0 && s !== void 0 && c !== void 0 && l !== void 0 && u !== void 0) {
|
|
1426
|
-
let e =
|
|
1424
|
+
let e = Et(a, o, s), t = Et(c, l, u);
|
|
1427
1425
|
m = d.getTime() >= e.getTime() && d.getTime() <= t.getTime();
|
|
1428
1426
|
}
|
|
1429
1427
|
return {
|
|
@@ -1432,54 +1430,54 @@ function Ft(e, t, n, r, i) {
|
|
|
1432
1430
|
isEndDate: p
|
|
1433
1431
|
};
|
|
1434
1432
|
}
|
|
1435
|
-
function
|
|
1436
|
-
let a =
|
|
1433
|
+
function Ft(e, t, n, r, i) {
|
|
1434
|
+
let a = Et(e, t, n);
|
|
1437
1435
|
if (r) {
|
|
1438
|
-
let { day: e, month: t, year: n } =
|
|
1439
|
-
if (a <
|
|
1436
|
+
let { day: e, month: t, year: n } = jt(r);
|
|
1437
|
+
if (a < Et(e, t, n)) return !0;
|
|
1440
1438
|
}
|
|
1441
1439
|
if (i) {
|
|
1442
|
-
let { day: e, month: t, year: n } =
|
|
1443
|
-
if (a >
|
|
1440
|
+
let { day: e, month: t, year: n } = jt(i);
|
|
1441
|
+
if (a > Et(e, t, n)) return !0;
|
|
1444
1442
|
}
|
|
1445
1443
|
return !1;
|
|
1446
1444
|
}
|
|
1447
|
-
function
|
|
1448
|
-
let { day: r, month: i, year: a } =
|
|
1445
|
+
function It(e, t, n) {
|
|
1446
|
+
let { day: r, month: i, year: a } = jt(/* @__PURE__ */ new Date());
|
|
1449
1447
|
return e === r && t === i && n === a;
|
|
1450
1448
|
}
|
|
1451
|
-
function
|
|
1452
|
-
let c =
|
|
1453
|
-
return /* @__PURE__ */
|
|
1454
|
-
className: f(
|
|
1455
|
-
children: /* @__PURE__ */
|
|
1456
|
-
className: f(
|
|
1449
|
+
function Lt({ className: e = "", month: t = (/* @__PURE__ */ new Date()).getMonth() + 1, year: n = (/* @__PURE__ */ new Date()).getFullYear(), onSelect: r = () => null, selectionStart: i, selectionEnd: a, minDate: o = null, maxDate: s = null }) {
|
|
1450
|
+
let c = wt("-"), l = Tt(t, n), u = At(t, n);
|
|
1451
|
+
return /* @__PURE__ */ F("div", {
|
|
1452
|
+
className: f(_t.datePickerMonth, e),
|
|
1453
|
+
children: /* @__PURE__ */ I("div", {
|
|
1454
|
+
className: f(_t.datePickerMonthContent),
|
|
1457
1455
|
children: [
|
|
1458
|
-
|
|
1459
|
-
Array.from(Array(u - 1).keys()).map((e) => /* @__PURE__ */
|
|
1456
|
+
kt(c).map((e, t) => /* @__PURE__ */ F("div", { children: e }, t)),
|
|
1457
|
+
Array.from(Array(u - 1).keys()).map((e) => /* @__PURE__ */ F("div", { className: f(_t.datePickerMonthItem, _t.datePickerMonthPlaceholder) }, e)),
|
|
1460
1458
|
Array.from(Array(l).keys()).map((e) => {
|
|
1461
|
-
let c = e + 1, l =
|
|
1462
|
-
return /* @__PURE__ */
|
|
1463
|
-
onClick: () => u ? null : r(
|
|
1464
|
-
className: f(
|
|
1465
|
-
[
|
|
1466
|
-
[
|
|
1467
|
-
[
|
|
1468
|
-
[
|
|
1469
|
-
[
|
|
1459
|
+
let c = e + 1, l = Pt(c, t, n, i, a), u = Ft(c, t, n, o, s), d = It(c, t, n);
|
|
1460
|
+
return /* @__PURE__ */ F(K, {
|
|
1461
|
+
onClick: () => u ? null : r(Et(c, t, n)),
|
|
1462
|
+
className: f(_t.datePickerMonthDay, _t.datePickerMonthItem, {
|
|
1463
|
+
[_t.datePickerMonthDaySelected]: l.isInRange,
|
|
1464
|
+
[_t.datePickerMonthDaySelectedStart]: l.isStartDate,
|
|
1465
|
+
[_t.datePickerMonthDaySelectedEnd]: l.isEndDate,
|
|
1466
|
+
[_t.datePickerMonthDayDisabled]: u,
|
|
1467
|
+
[_t.datePickerMonthDayToday]: d
|
|
1470
1468
|
}),
|
|
1471
1469
|
children: c
|
|
1472
1470
|
}, c);
|
|
1473
1471
|
}),
|
|
1474
|
-
Array.from(Array(42 - (u + l - 1)).keys()).map((e) => /* @__PURE__ */
|
|
1475
|
-
className: f(
|
|
1472
|
+
Array.from(Array(42 - (u + l - 1)).keys()).map((e) => /* @__PURE__ */ F("div", {
|
|
1473
|
+
className: f(_t.datePickerMonthItem, _t.datePickerMonthPlaceholder),
|
|
1476
1474
|
children: "\xA0"
|
|
1477
1475
|
}, e))
|
|
1478
1476
|
]
|
|
1479
1477
|
})
|
|
1480
1478
|
});
|
|
1481
1479
|
}
|
|
1482
|
-
var
|
|
1480
|
+
var Rt = {
|
|
1483
1481
|
infiniteBlock: "infiniteBlock_dFv-h",
|
|
1484
1482
|
"spinner-wrapper": "spinner-wrapper_hsgWz",
|
|
1485
1483
|
spinnerWrapper: "spinner-wrapper_hsgWz",
|
|
@@ -1487,7 +1485,7 @@ var zt = {
|
|
|
1487
1485
|
};
|
|
1488
1486
|
//#endregion
|
|
1489
1487
|
//#region package/common/infiniteBlock/infiniteBlock.tsx
|
|
1490
|
-
function
|
|
1488
|
+
function zt(e, t) {
|
|
1491
1489
|
let n = e;
|
|
1492
1490
|
for (; n.props.children !== null && typeof n.props.children == "object" && !Array.isArray(n.props.children);) n = n.props.children;
|
|
1493
1491
|
let r = n.props.children;
|
|
@@ -1500,11 +1498,11 @@ function Bt(e, t) {
|
|
|
1500
1498
|
}
|
|
1501
1499
|
return String(r).toLowerCase().startsWith(t);
|
|
1502
1500
|
}
|
|
1503
|
-
function
|
|
1501
|
+
function Bt(e, t, n) {
|
|
1504
1502
|
let r = e + t;
|
|
1505
1503
|
return r === n ? 0 : r < -1 ? n - 1 : r;
|
|
1506
1504
|
}
|
|
1507
|
-
function
|
|
1505
|
+
function Vt({ children: t, onScroll: n, className: r = "", isDataLoading: a = !1, setHighlightedIndex: o = () => null }) {
|
|
1508
1506
|
let s = u(null), c = u(!1), [l, p] = d(!1), m = u(-1), h = u(null), g = i(() => {
|
|
1509
1507
|
let e = s.current;
|
|
1510
1508
|
if (!e) return;
|
|
@@ -1518,12 +1516,12 @@ function Ht({ children: t, onScroll: n, className: r = "", isDataLoading: a = !1
|
|
|
1518
1516
|
let i = e.Children.toArray(t), a = m.current;
|
|
1519
1517
|
switch (n.key) {
|
|
1520
1518
|
case "ArrowDown":
|
|
1521
|
-
a =
|
|
1519
|
+
a = Bt(a, 1, i.length);
|
|
1522
1520
|
break;
|
|
1523
1521
|
case "ArrowUp":
|
|
1524
|
-
a =
|
|
1522
|
+
a = Bt(a, -1, i.length);
|
|
1525
1523
|
break;
|
|
1526
|
-
default: for (let e = 0; e < i.length; e++) if (
|
|
1524
|
+
default: for (let e = 0; e < i.length; e++) if (zt(i[e], n.key)) {
|
|
1527
1525
|
if (a >= e && h.current === n.key) continue;
|
|
1528
1526
|
a = e;
|
|
1529
1527
|
break;
|
|
@@ -1538,22 +1536,22 @@ function Ht({ children: t, onScroll: n, className: r = "", isDataLoading: a = !1
|
|
|
1538
1536
|
o(a);
|
|
1539
1537
|
}
|
|
1540
1538
|
}, [t, o]);
|
|
1541
|
-
return /* @__PURE__ */
|
|
1542
|
-
className: f(
|
|
1539
|
+
return /* @__PURE__ */ I("div", {
|
|
1540
|
+
className: f(Rt.infiniteBlock, r),
|
|
1543
1541
|
onScroll: g,
|
|
1544
1542
|
onKeyDown: _,
|
|
1545
1543
|
tabIndex: 0,
|
|
1546
1544
|
ref: s,
|
|
1547
|
-
children: [a ? /* @__PURE__ */
|
|
1548
|
-
className:
|
|
1549
|
-
children: /* @__PURE__ */
|
|
1550
|
-
}) : t, l && /* @__PURE__ */
|
|
1551
|
-
className:
|
|
1552
|
-
children: /* @__PURE__ */
|
|
1545
|
+
children: [a ? /* @__PURE__ */ F("div", {
|
|
1546
|
+
className: Rt.spinnerWrapper,
|
|
1547
|
+
children: /* @__PURE__ */ F(Oe, { className: Rt.spinner })
|
|
1548
|
+
}) : t, l && /* @__PURE__ */ F("div", {
|
|
1549
|
+
className: Rt.spinnerWrapper,
|
|
1550
|
+
children: /* @__PURE__ */ F(Oe, { className: Rt.spinner })
|
|
1553
1551
|
})]
|
|
1554
1552
|
});
|
|
1555
1553
|
}
|
|
1556
|
-
var
|
|
1554
|
+
var Z = {
|
|
1557
1555
|
"required-mark": "required-mark_fy7Fm",
|
|
1558
1556
|
requiredMark: "required-mark_fy7Fm",
|
|
1559
1557
|
dropdown: "dropdown_XTshY",
|
|
@@ -1621,135 +1619,137 @@ var X = {
|
|
|
1621
1619
|
};
|
|
1622
1620
|
//#endregion
|
|
1623
1621
|
//#region package/common/dropdown/dropdown.tsx
|
|
1624
|
-
function
|
|
1625
|
-
let [
|
|
1622
|
+
function Ht({ errorMessage: e = "", className: t = "", label: n = "", value: r = "", isValid: i = !0, tabIndex: o = 0, isRequired: s = !1, customProps: c = {}, isRow: l = !1, disabled: m = !1, onScroll: h = () => Promise.resolve(), isListOnTop: _ = !1, onClick: v, onChange: y, onFocus: b = null, onBlur: x = null, onMouseEnter: S = null, onMouseLeave: C = null, dropdownLabel: w, isDropdownListWider: T = !1, inputClassName: E = "", dropDownIconClassName: ee = "", dropDownClassName: D = "", formValidator: O = null, labelClassName: k = "", dropDownInputClassName: te = "", items: ne = [], useMatLabelStyle: A = !0, placeholder: j = "", plainStyle: M = !1, scrollToSelected: N = !1, reactRef: re, ...ie }) {
|
|
1623
|
+
let [ae, oe] = d(!1), [se, P] = d(!1), [, ce] = d(0), L = u(O);
|
|
1626
1624
|
a(() => {
|
|
1627
|
-
if (
|
|
1628
|
-
|
|
1629
|
-
let e = () =>
|
|
1630
|
-
return
|
|
1625
|
+
if (L.current = O, !L.current) return;
|
|
1626
|
+
L.current.label = n ?? "", L.current.validate();
|
|
1627
|
+
let e = () => ce((e) => e + 1);
|
|
1628
|
+
return L.current.registerOnUpdateListener(e), () => L.current?.removeOnUpdateListener(e);
|
|
1631
1629
|
}, [O, n]);
|
|
1632
|
-
let
|
|
1633
|
-
|
|
1634
|
-
}, ue = (e) => {
|
|
1635
|
-
se(!1), C?.(e);
|
|
1630
|
+
let ue = (e) => {
|
|
1631
|
+
P(!0), S?.(e);
|
|
1636
1632
|
}, de = (e) => {
|
|
1637
|
-
|
|
1633
|
+
P(!1), C?.(e);
|
|
1638
1634
|
}, fe = (e) => {
|
|
1639
|
-
|
|
1640
|
-
}, pe = (
|
|
1635
|
+
oe(!0), b?.(e);
|
|
1636
|
+
}, pe = (e) => {
|
|
1637
|
+
L.current && (L.current.touched = !0), oe(!1), x?.(e);
|
|
1638
|
+
}, R = () => O ? O.touched && O.hasError() : !i || !!e, me = () => !!(s || O?.validators.find((e) => e.validatorId === "required")), he = (e) => {
|
|
1641
1639
|
O ? (O.set(e), y?.(O.value, c)) : y?.(e, c);
|
|
1642
|
-
},
|
|
1643
|
-
|
|
1644
|
-
e.key ===
|
|
1645
|
-
})
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1640
|
+
}, z = w, B = O ? O.value : r, V = R();
|
|
1641
|
+
ne.forEach((e) => {
|
|
1642
|
+
e.key === B && (z = e.label);
|
|
1643
|
+
});
|
|
1644
|
+
let ge = z || B, _e = ge == null || typeof ge == "string" && ge.trim() === "";
|
|
1645
|
+
return /* @__PURE__ */ I("div", {
|
|
1646
|
+
...ie,
|
|
1647
|
+
className: f(t, Z.dropdownLabel, Z.dropdown, { [Z.dropdownLabelColumn]: !l }),
|
|
1648
|
+
onMouseEnter: ue,
|
|
1649
|
+
onMouseLeave: de,
|
|
1649
1650
|
children: [
|
|
1650
|
-
/* @__PURE__ */
|
|
1651
|
-
onChange: (e) =>
|
|
1651
|
+
/* @__PURE__ */ F(le, {
|
|
1652
|
+
onChange: (e) => he((e || { key: "" }).key),
|
|
1652
1653
|
itemToString: (e) => e ? String(e.key) : "",
|
|
1653
|
-
selectedItem: ne.find((e) => e.key ===
|
|
1654
|
+
selectedItem: ne.find((e) => e.key === B) ?? null,
|
|
1654
1655
|
stateReducer: (e, t) => N && Object.prototype.hasOwnProperty.call(t, "isOpen") ? {
|
|
1655
1656
|
...t,
|
|
1656
1657
|
highlightedIndex: t.isOpen ? ne.indexOf(e.selectedItem) : null
|
|
1657
1658
|
} : t,
|
|
1658
|
-
children: ({ getItemProps: e, getToggleButtonProps: t, isOpen: r, selectedItem: i, highlightedIndex: a, setHighlightedIndex: s }) => /* @__PURE__ */
|
|
1659
|
-
onFocus:
|
|
1660
|
-
onBlur:
|
|
1661
|
-
className: f(
|
|
1662
|
-
[X.dropdownInputPlain]: M,
|
|
1663
|
-
[X.dropdownInputButtonDisabled]: m
|
|
1664
|
-
}, te),
|
|
1659
|
+
children: ({ getItemProps: e, getToggleButtonProps: t, isOpen: r, selectedItem: i, highlightedIndex: a, setHighlightedIndex: s }) => /* @__PURE__ */ F("div", { children: /* @__PURE__ */ I("div", {
|
|
1660
|
+
onFocus: fe,
|
|
1661
|
+
onBlur: pe,
|
|
1662
|
+
className: f(Z.dropdownInput, { [Z.dropdownInputPlain]: M }, te),
|
|
1665
1663
|
children: [
|
|
1666
|
-
/* @__PURE__ */
|
|
1664
|
+
/* @__PURE__ */ F("button", {
|
|
1667
1665
|
tabIndex: o,
|
|
1668
1666
|
type: "button",
|
|
1667
|
+
disabled: m,
|
|
1669
1668
|
style: T ? {
|
|
1670
1669
|
padding: "6px",
|
|
1671
1670
|
border: "none"
|
|
1672
1671
|
} : {},
|
|
1673
|
-
className: f(
|
|
1672
|
+
className: f(Z.dropdownInputButton, { [Z.dropdownInputButtonDisabled]: m }, E),
|
|
1674
1673
|
...t(),
|
|
1675
1674
|
onClick: (e) => {
|
|
1676
1675
|
t().onClick?.(e), v?.(e);
|
|
1677
1676
|
},
|
|
1678
1677
|
ref: re,
|
|
1679
|
-
children:
|
|
1678
|
+
children: _e ? "\xA0" : ge
|
|
1680
1679
|
}),
|
|
1681
|
-
/* @__PURE__ */
|
|
1680
|
+
/* @__PURE__ */ F("button", {
|
|
1682
1681
|
type: "button",
|
|
1683
1682
|
tabIndex: -1,
|
|
1684
|
-
|
|
1683
|
+
disabled: m,
|
|
1684
|
+
className: f(Z.dropdownInputButtonIcon, ee),
|
|
1685
1685
|
...t(),
|
|
1686
1686
|
onClick: (e) => {
|
|
1687
1687
|
t().onClick?.(e), v?.(e);
|
|
1688
1688
|
},
|
|
1689
|
-
children: !m && /* @__PURE__ */
|
|
1689
|
+
children: !m && /* @__PURE__ */ F(p, {
|
|
1690
1690
|
icon: g,
|
|
1691
|
-
className: f(
|
|
1691
|
+
className: f(Z.dropdownInputButtonIconArrow, { [Z.dropdownInputButtonIconArrowOpen]: r })
|
|
1692
1692
|
})
|
|
1693
1693
|
}),
|
|
1694
|
-
!m && r ? /* @__PURE__ */
|
|
1694
|
+
!m && r ? /* @__PURE__ */ F(Vt, {
|
|
1695
1695
|
onScroll: h,
|
|
1696
|
-
className: f(
|
|
1697
|
-
[
|
|
1698
|
-
[
|
|
1696
|
+
className: f(Z.dropdownInputList, {
|
|
1697
|
+
[Z.dropdownInputListOnTop]: _,
|
|
1698
|
+
[Z.dropdownInputListWider]: T
|
|
1699
1699
|
}),
|
|
1700
1700
|
setHighlightedIndex: s,
|
|
1701
|
-
children: ne.map((t, n) => /* @__PURE__ */
|
|
1701
|
+
children: ne.map((t, n) => /* @__PURE__ */ F("div", {
|
|
1702
1702
|
...e({
|
|
1703
1703
|
index: n,
|
|
1704
1704
|
item: t,
|
|
1705
1705
|
disabled: !!t.disabled
|
|
1706
1706
|
}),
|
|
1707
|
-
className: f(
|
|
1708
|
-
[
|
|
1709
|
-
[
|
|
1707
|
+
className: f(Z.dropdownInputListItem, D, {
|
|
1708
|
+
[Z.dropdownInputListItemActive]: a === n,
|
|
1709
|
+
[Z.dropdownInputListItemSelected]: i === t
|
|
1710
1710
|
}),
|
|
1711
1711
|
children: t.label
|
|
1712
1712
|
}, t.key))
|
|
1713
1713
|
}) : null,
|
|
1714
|
-
/* @__PURE__ */
|
|
1715
|
-
className: f(
|
|
1716
|
-
[
|
|
1717
|
-
[
|
|
1718
|
-
[
|
|
1719
|
-
[
|
|
1714
|
+
/* @__PURE__ */ F("fieldset", {
|
|
1715
|
+
className: f(Z.dropdownFieldset, {
|
|
1716
|
+
[Z.dropdownBorderPlain]: M,
|
|
1717
|
+
[Z.dropdownBorderFocused]: ae,
|
|
1718
|
+
[Z.dropdownBorderInvalid]: V,
|
|
1719
|
+
[Z.dropdownBorderError]: V
|
|
1720
1720
|
}),
|
|
1721
|
-
children: /* @__PURE__ */
|
|
1722
|
-
className: f(
|
|
1723
|
-
children: /* @__PURE__ */
|
|
1721
|
+
children: /* @__PURE__ */ F("legend", {
|
|
1722
|
+
className: f(Z.dropdownFieldsetLegend, { [Z.dropdownFieldsetLegendActive]: A && (ae || B) }),
|
|
1723
|
+
children: /* @__PURE__ */ F("span", { children: n })
|
|
1724
1724
|
})
|
|
1725
1725
|
}),
|
|
1726
|
-
A && n && /* @__PURE__ */
|
|
1727
|
-
className: f(
|
|
1726
|
+
A && n && /* @__PURE__ */ F("div", {
|
|
1727
|
+
className: f(Z.dropdownMatLabel, { [Z.dropdownMatLabelFloating]: ae || B }),
|
|
1728
1728
|
children: n
|
|
1729
1729
|
}),
|
|
1730
|
-
A && j && /* @__PURE__ */
|
|
1731
|
-
className: f(
|
|
1730
|
+
A && j && /* @__PURE__ */ F("div", {
|
|
1731
|
+
className: f(Z.dropdownPlaceholder, ae && !z && Z.dropdownPlaceholderShown),
|
|
1732
1732
|
children: j
|
|
1733
1733
|
})
|
|
1734
1734
|
]
|
|
1735
1735
|
}) })
|
|
1736
1736
|
}),
|
|
1737
|
-
n && !A && /* @__PURE__ */
|
|
1738
|
-
className: f(
|
|
1739
|
-
children: [n,
|
|
1740
|
-
className:
|
|
1737
|
+
n && !A && /* @__PURE__ */ I("div", {
|
|
1738
|
+
className: f(Z.dropdownLabelText, k),
|
|
1739
|
+
children: [n, me() ? /* @__PURE__ */ F("div", {
|
|
1740
|
+
className: Z.requiredMark,
|
|
1741
1741
|
children: "*"
|
|
1742
1742
|
}) : null]
|
|
1743
1743
|
}),
|
|
1744
|
-
/* @__PURE__ */
|
|
1744
|
+
/* @__PURE__ */ F(nt, {
|
|
1745
1745
|
variant: "error",
|
|
1746
1746
|
message: O ? O.getCurrentErrorMessage() : e || "",
|
|
1747
|
-
isVisible:
|
|
1747
|
+
isVisible: V && (ae || se)
|
|
1748
1748
|
})
|
|
1749
1749
|
]
|
|
1750
1750
|
});
|
|
1751
1751
|
}
|
|
1752
|
-
var
|
|
1752
|
+
var Ut = {
|
|
1753
1753
|
datePicker: "datePicker_ZohTp",
|
|
1754
1754
|
"datePicker-header": "datePicker-header_YmSWE",
|
|
1755
1755
|
datePickerHeader: "datePicker-header_YmSWE",
|
|
@@ -1766,23 +1766,23 @@ var Wt = {
|
|
|
1766
1766
|
};
|
|
1767
1767
|
//#endregion
|
|
1768
1768
|
//#region package/common/datePicker/datePicker.tsx
|
|
1769
|
-
function
|
|
1770
|
-
let T = () => r ? r.value : t, E = T() ?? /* @__PURE__ */ new Date(), [ee, D] = d(E.getMonth() + 1), [O, k] = d(E.getFullYear()), [te, ne] = d(!1), [A, j] = d(() => T() ?
|
|
1769
|
+
function Wt({ className: e = "", selected: t, onSelect: n = () => null, formValidator: r = null, noInput: i = !1, noHeader: o = !1, isModal: s = !1, isInline: c = !1, onChange: l = () => null, minDate: p = null, maxDate: m = null, children: h = null, showClearButton: g = !1, label: y = "", isValid: b = !0, errorMessage: x = "", isRequired: S = !1, startDate: C, endDate: w }) {
|
|
1770
|
+
let T = () => r ? r.value : t, E = T() ?? /* @__PURE__ */ new Date(), [ee, D] = d(E.getMonth() + 1), [O, k] = d(E.getFullYear()), [te, ne] = d(!1), [A, j] = d(() => T() ? Mt(E) : ""), [M, N] = d(!1), [re, ie] = d(!1), [, ae] = d(0), [oe, se] = d(t), P = u(r);
|
|
1771
1771
|
if (oe !== t) {
|
|
1772
1772
|
se(t);
|
|
1773
1773
|
let e = t ?? /* @__PURE__ */ new Date();
|
|
1774
|
-
D(e.getMonth() + 1), k(e.getFullYear()), j(t ?
|
|
1774
|
+
D(e.getMonth() + 1), k(e.getFullYear()), j(t ? Mt(t) : "");
|
|
1775
1775
|
}
|
|
1776
1776
|
a(() => {
|
|
1777
1777
|
if (P.current = r, !r) return;
|
|
1778
1778
|
let e = () => {
|
|
1779
1779
|
let e = r.value;
|
|
1780
|
-
e ? (D(e.getMonth() + 1), k(e.getFullYear()), j(
|
|
1780
|
+
e ? (D(e.getMonth() + 1), k(e.getFullYear()), j(Mt(e))) : j(""), ae((e) => e + 1);
|
|
1781
1781
|
};
|
|
1782
1782
|
return r.registerOnUpdateListener(e), () => r.removeOnUpdateListener(e);
|
|
1783
1783
|
}, [r]);
|
|
1784
|
-
let
|
|
1785
|
-
j(e ?
|
|
1784
|
+
let L = () => r ? r.touched && r.hasError() : !b || !!x, le = () => !!(S || r?.validators.find((e) => e.validatorId === "required")), de = (e) => {
|
|
1785
|
+
j(e ? Mt(e) : ""), r && r.set(e), l(e);
|
|
1786
1786
|
}, fe = (e) => {
|
|
1787
1787
|
de(e), n(e), ne(!1);
|
|
1788
1788
|
}, pe = (e) => {
|
|
@@ -1792,13 +1792,13 @@ function Gt({ className: e = "", selected: t, onSelect: n = () => null, formVali
|
|
|
1792
1792
|
});
|
|
1793
1793
|
}, R = (e) => {
|
|
1794
1794
|
if (e.match(/\d{2}\.\d{2}\.\d{4}/gi)) {
|
|
1795
|
-
let [t, n, r] = e.split("."), i =
|
|
1795
|
+
let [t, n, r] = e.split("."), i = Et(Number(t), Number(n), Number(r));
|
|
1796
1796
|
if (i && i.toString() !== "Invalid Date" && (!m || i <= m) && (!p || i >= p)) return i;
|
|
1797
1797
|
}
|
|
1798
1798
|
return null;
|
|
1799
1799
|
}, me = ({ previousState: e, nextState: t }) => {
|
|
1800
1800
|
if (!e || t.value === e.value) return t;
|
|
1801
|
-
let n =
|
|
1801
|
+
let n = Nt(t.value, e.value, t.selection ?? null), r = R(n.value);
|
|
1802
1802
|
return r && de(r), n;
|
|
1803
1803
|
}, he = () => {
|
|
1804
1804
|
let e = 400, t = (/* @__PURE__ */ new Date()).getFullYear() - 200;
|
|
@@ -1806,47 +1806,47 @@ function Gt({ className: e = "", selected: t, onSelect: n = () => null, formVali
|
|
|
1806
1806
|
key: e + t,
|
|
1807
1807
|
label: e + t
|
|
1808
1808
|
}));
|
|
1809
|
-
}, z = T(), B =
|
|
1810
|
-
o ? null : /* @__PURE__ */
|
|
1811
|
-
className:
|
|
1809
|
+
}, z = T(), B = L(), V = /* @__PURE__ */ I(ce, { children: [
|
|
1810
|
+
o ? null : /* @__PURE__ */ I("div", {
|
|
1811
|
+
className: Ut.datePickerHeader,
|
|
1812
1812
|
children: [
|
|
1813
|
-
/* @__PURE__ */
|
|
1813
|
+
/* @__PURE__ */ F(ze, {
|
|
1814
1814
|
icon: _,
|
|
1815
1815
|
onClick: () => pe(-1)
|
|
1816
1816
|
}),
|
|
1817
|
-
/* @__PURE__ */
|
|
1818
|
-
className:
|
|
1819
|
-
children: /* @__PURE__ */
|
|
1820
|
-
className:
|
|
1821
|
-
children: [/* @__PURE__ */
|
|
1817
|
+
/* @__PURE__ */ F("div", {
|
|
1818
|
+
className: Ut.datePickerHeaderMonthAndYearContainer,
|
|
1819
|
+
children: /* @__PURE__ */ I("div", {
|
|
1820
|
+
className: Ut.datePickerHeaderMonthAndYear,
|
|
1821
|
+
children: [/* @__PURE__ */ F(Ht, {
|
|
1822
1822
|
plainStyle: !0,
|
|
1823
1823
|
scrollToSelected: !0,
|
|
1824
1824
|
onChange: (e) => D(e),
|
|
1825
|
-
className:
|
|
1826
|
-
value:
|
|
1827
|
-
items:
|
|
1825
|
+
className: Ut.datePickerHeaderMonth,
|
|
1826
|
+
value: Dt(wt("-"), O, ee, 1),
|
|
1827
|
+
items: Ot().map((e, t) => ({
|
|
1828
1828
|
key: t + 1,
|
|
1829
1829
|
label: e
|
|
1830
1830
|
}))
|
|
1831
|
-
}), /* @__PURE__ */
|
|
1831
|
+
}), /* @__PURE__ */ F(Ht, {
|
|
1832
1832
|
plainStyle: !0,
|
|
1833
1833
|
scrollToSelected: !0,
|
|
1834
1834
|
useMatLabelStyle: !1,
|
|
1835
|
-
className:
|
|
1835
|
+
className: Ut.datePickerHeaderYear,
|
|
1836
1836
|
onChange: (e) => k(e),
|
|
1837
1837
|
value: O,
|
|
1838
1838
|
items: he()
|
|
1839
1839
|
})]
|
|
1840
1840
|
})
|
|
1841
1841
|
}),
|
|
1842
|
-
/* @__PURE__ */
|
|
1842
|
+
/* @__PURE__ */ F(ze, {
|
|
1843
1843
|
icon: v,
|
|
1844
1844
|
onClick: () => pe(1)
|
|
1845
1845
|
})
|
|
1846
1846
|
]
|
|
1847
1847
|
}),
|
|
1848
|
-
/* @__PURE__ */
|
|
1849
|
-
className:
|
|
1848
|
+
/* @__PURE__ */ F(Lt, {
|
|
1849
|
+
className: Ut.datePickerMonth,
|
|
1850
1850
|
month: ee,
|
|
1851
1851
|
year: O,
|
|
1852
1852
|
onSelect: fe,
|
|
@@ -1855,18 +1855,18 @@ function Gt({ className: e = "", selected: t, onSelect: n = () => null, formVali
|
|
|
1855
1855
|
minDate: p,
|
|
1856
1856
|
maxDate: m
|
|
1857
1857
|
}),
|
|
1858
|
-
g && /* @__PURE__ */
|
|
1858
|
+
g && /* @__PURE__ */ F(G, {
|
|
1859
1859
|
onClick: () => fe(null),
|
|
1860
1860
|
children: "Clear"
|
|
1861
1861
|
}),
|
|
1862
1862
|
h
|
|
1863
|
-
] }), ge = i ? null : /* @__PURE__ */
|
|
1863
|
+
] }), ge = i ? null : /* @__PURE__ */ F(rt, {
|
|
1864
1864
|
readOnly: s,
|
|
1865
1865
|
label: `${y}${le() ? " *" : ""}`,
|
|
1866
1866
|
value: A,
|
|
1867
1867
|
onChange: (e) => j(e),
|
|
1868
1868
|
onClick: () => ne(!0),
|
|
1869
|
-
customInput: /* @__PURE__ */
|
|
1869
|
+
customInput: /* @__PURE__ */ F(ue, {
|
|
1870
1870
|
mask: "99.99.9999",
|
|
1871
1871
|
maskPlaceholder: "_",
|
|
1872
1872
|
beforeMaskedStateChange: me
|
|
@@ -1878,25 +1878,25 @@ function Gt({ className: e = "", selected: t, onSelect: n = () => null, formVali
|
|
|
1878
1878
|
onMouseEnter: () => ie(!0),
|
|
1879
1879
|
onMouseLeave: () => ie(!1),
|
|
1880
1880
|
isValid: !B
|
|
1881
|
-
}), _e = c ? V : s ? /* @__PURE__ */
|
|
1881
|
+
}), _e = c ? V : s ? /* @__PURE__ */ F(ht, {
|
|
1882
1882
|
hideHeader: !0,
|
|
1883
1883
|
isOpen: te,
|
|
1884
1884
|
onClose: () => ne(!1),
|
|
1885
1885
|
children: V
|
|
1886
|
-
}) : /* @__PURE__ */
|
|
1886
|
+
}) : /* @__PURE__ */ F(et, {
|
|
1887
1887
|
isOpen: te,
|
|
1888
1888
|
onOpenChange: (e) => ne(e),
|
|
1889
1889
|
content: V,
|
|
1890
|
-
align:
|
|
1890
|
+
align: Qe.Left,
|
|
1891
1891
|
dontCloseOnChildClick: !0,
|
|
1892
1892
|
children: ge
|
|
1893
1893
|
});
|
|
1894
|
-
return /* @__PURE__ */
|
|
1895
|
-
className: f(
|
|
1894
|
+
return /* @__PURE__ */ I("div", {
|
|
1895
|
+
className: f(Ut.datePicker, e),
|
|
1896
1896
|
children: [
|
|
1897
1897
|
(s || c) && ge,
|
|
1898
1898
|
_e,
|
|
1899
|
-
/* @__PURE__ */
|
|
1899
|
+
/* @__PURE__ */ F(nt, {
|
|
1900
1900
|
variant: "error",
|
|
1901
1901
|
message: r ? r.getCurrentErrorMessage() : x || "",
|
|
1902
1902
|
isVisible: B && (M || re)
|
|
@@ -1904,17 +1904,17 @@ function Gt({ className: e = "", selected: t, onSelect: n = () => null, formVali
|
|
|
1904
1904
|
]
|
|
1905
1905
|
});
|
|
1906
1906
|
}
|
|
1907
|
-
var
|
|
1907
|
+
var Gt = { emptyState: "emptyState_KXOIx" };
|
|
1908
1908
|
//#endregion
|
|
1909
1909
|
//#region package/common/emptyState/emptyState.tsx
|
|
1910
|
-
function
|
|
1911
|
-
return /* @__PURE__ */
|
|
1910
|
+
function Kt({ className: e, icon: t, children: n, ...r }) {
|
|
1911
|
+
return /* @__PURE__ */ I("div", {
|
|
1912
1912
|
...r,
|
|
1913
|
-
className: f(
|
|
1914
|
-
children: [t && /* @__PURE__ */
|
|
1913
|
+
className: f(Gt.emptyState, e),
|
|
1914
|
+
children: [t && /* @__PURE__ */ F(p, { icon: t }), /* @__PURE__ */ F("div", { children: n ?? "No entries available" })]
|
|
1915
1915
|
});
|
|
1916
1916
|
}
|
|
1917
|
-
var
|
|
1917
|
+
var qt = {
|
|
1918
1918
|
fab: "fab_hyAAa",
|
|
1919
1919
|
"fab-content": "fab-content_IBiXm",
|
|
1920
1920
|
fabContent: "fab-content_IBiXm",
|
|
@@ -1922,25 +1922,25 @@ var Jt = {
|
|
|
1922
1922
|
fabContentContainer: "fab-content-container_FQD1x",
|
|
1923
1923
|
"fab-size-mini": "fab-size-mini_KP9BD",
|
|
1924
1924
|
fabSizeMini: "fab-size-mini_KP9BD"
|
|
1925
|
-
},
|
|
1925
|
+
}, Jt = {
|
|
1926
1926
|
default: null,
|
|
1927
|
-
mini:
|
|
1927
|
+
mini: qt.fabSizeMini
|
|
1928
1928
|
};
|
|
1929
|
-
function
|
|
1930
|
-
return /* @__PURE__ */
|
|
1929
|
+
function Yt({ children: e = null, size: t = "default", className: n = "", styleType: r = W.Primary, onClick: i = () => {} }) {
|
|
1930
|
+
return /* @__PURE__ */ F(G, {
|
|
1931
1931
|
styleType: r,
|
|
1932
|
-
className: f(
|
|
1932
|
+
className: f(qt.fab, Jt[t], n),
|
|
1933
1933
|
onClick: i,
|
|
1934
|
-
children: /* @__PURE__ */
|
|
1935
|
-
className:
|
|
1936
|
-
children: /* @__PURE__ */
|
|
1937
|
-
className:
|
|
1934
|
+
children: /* @__PURE__ */ F("div", {
|
|
1935
|
+
className: qt.fabContentContainer,
|
|
1936
|
+
children: /* @__PURE__ */ F("div", {
|
|
1937
|
+
className: qt.fabContent,
|
|
1938
1938
|
children: e
|
|
1939
1939
|
})
|
|
1940
1940
|
})
|
|
1941
1941
|
});
|
|
1942
1942
|
}
|
|
1943
|
-
var
|
|
1943
|
+
var Xt = {
|
|
1944
1944
|
fab: "fab_YI34X",
|
|
1945
1945
|
appear: "appear_DL0wm",
|
|
1946
1946
|
"fab-container": "fab-container_8uoYo",
|
|
@@ -1978,48 +1978,48 @@ function Zt({ children: e = null, size: t = "default", menuEntries: n = [], onMe
|
|
|
1978
1978
|
function u(e, t) {
|
|
1979
1979
|
e.stopPropagation(), a && c(!1), r(t);
|
|
1980
1980
|
}
|
|
1981
|
-
return /* @__PURE__ */
|
|
1981
|
+
return /* @__PURE__ */ I("div", {
|
|
1982
1982
|
...o,
|
|
1983
|
-
className:
|
|
1983
|
+
className: Xt.fabContainer,
|
|
1984
1984
|
children: [
|
|
1985
|
-
/* @__PURE__ */
|
|
1986
|
-
className: f(
|
|
1985
|
+
/* @__PURE__ */ F("div", {
|
|
1986
|
+
className: f(Xt.fabMenuBackdrop, s && Xt.fabMenuBackdropOpen),
|
|
1987
1987
|
onClick: (e) => {
|
|
1988
1988
|
e.stopPropagation(), c(!1);
|
|
1989
1989
|
}
|
|
1990
1990
|
}),
|
|
1991
|
-
/* @__PURE__ */
|
|
1991
|
+
/* @__PURE__ */ F("div", {
|
|
1992
1992
|
onClick: (e) => e.stopPropagation(),
|
|
1993
|
-
children: /* @__PURE__ */
|
|
1994
|
-
className:
|
|
1993
|
+
children: /* @__PURE__ */ F(Yt, {
|
|
1994
|
+
className: Xt.fab,
|
|
1995
1995
|
size: t,
|
|
1996
1996
|
onClick: l,
|
|
1997
|
-
children: /* @__PURE__ */
|
|
1998
|
-
className: f(
|
|
1999
|
-
children: [/* @__PURE__ */
|
|
2000
|
-
className: f(
|
|
1997
|
+
children: /* @__PURE__ */ I("div", {
|
|
1998
|
+
className: f(Xt.fabIcon, s && Xt.fabIconMenuOpen),
|
|
1999
|
+
children: [/* @__PURE__ */ F("div", {
|
|
2000
|
+
className: f(Xt.fabIconContent, !s && Xt.fabIconContentShown),
|
|
2001
2001
|
children: e
|
|
2002
|
-
}), /* @__PURE__ */
|
|
2003
|
-
className: f(
|
|
2004
|
-
children: /* @__PURE__ */
|
|
2002
|
+
}), /* @__PURE__ */ F("div", {
|
|
2003
|
+
className: f(Xt.fabIconContent, s && Xt.fabIconContentShown),
|
|
2004
|
+
children: /* @__PURE__ */ F(p, { icon: M })
|
|
2005
2005
|
})]
|
|
2006
2006
|
})
|
|
2007
2007
|
})
|
|
2008
2008
|
}),
|
|
2009
|
-
/* @__PURE__ */
|
|
2010
|
-
className:
|
|
2011
|
-
children: n.map(({ id: e, label: t, icon: n }) => /* @__PURE__ */
|
|
2012
|
-
className: f(
|
|
2009
|
+
/* @__PURE__ */ F("div", {
|
|
2010
|
+
className: Xt.fabMenu,
|
|
2011
|
+
children: n.map(({ id: e, label: t, icon: n }) => /* @__PURE__ */ I("div", {
|
|
2012
|
+
className: f(Xt.fabMenuEntry, s && Xt.fabMenuEntryShown),
|
|
2013
2013
|
onClick: (t) => u(t, e),
|
|
2014
|
-
children: [t && /* @__PURE__ */
|
|
2015
|
-
className:
|
|
2016
|
-
children: /* @__PURE__ */
|
|
2017
|
-
className:
|
|
2014
|
+
children: [t && /* @__PURE__ */ F("div", {
|
|
2015
|
+
className: Xt.fabMenuEntryLabelContainer,
|
|
2016
|
+
children: /* @__PURE__ */ F("div", {
|
|
2017
|
+
className: Xt.fabMenuEntryLabel,
|
|
2018
2018
|
children: t
|
|
2019
2019
|
})
|
|
2020
|
-
}), /* @__PURE__ */
|
|
2020
|
+
}), /* @__PURE__ */ F(Yt, {
|
|
2021
2021
|
size: "mini",
|
|
2022
|
-
children: /* @__PURE__ */
|
|
2022
|
+
children: /* @__PURE__ */ F(p, { icon: n })
|
|
2023
2023
|
})]
|
|
2024
2024
|
}, e))
|
|
2025
2025
|
})
|
|
@@ -2060,21 +2060,21 @@ function tn({ data: e = [], selectedId: t = null, label: n = "", onChange: r, fo
|
|
|
2060
2060
|
function g(e) {
|
|
2061
2061
|
i && i.set(e), r?.(e);
|
|
2062
2062
|
}
|
|
2063
|
-
return /* @__PURE__ */
|
|
2063
|
+
return /* @__PURE__ */ I("div", {
|
|
2064
2064
|
...u,
|
|
2065
2065
|
className: f(Qt.iconPicker, { [Qt.iconPickerError]: m }, c?.root, o),
|
|
2066
2066
|
style: {
|
|
2067
2067
|
...l?.root,
|
|
2068
2068
|
...s
|
|
2069
2069
|
},
|
|
2070
|
-
children: [n && /* @__PURE__ */
|
|
2070
|
+
children: [n && /* @__PURE__ */ I("div", {
|
|
2071
2071
|
className: f(Qt.iconPickerLabel, c?.label),
|
|
2072
2072
|
style: l?.label,
|
|
2073
2073
|
children: [n, h && " *"]
|
|
2074
|
-
}), /* @__PURE__ */
|
|
2074
|
+
}), /* @__PURE__ */ F("div", {
|
|
2075
2075
|
className: f(Qt.iconPickerItemContainer, c?.itemContainer),
|
|
2076
2076
|
style: l?.itemContainer,
|
|
2077
|
-
children: e.map(({ id: e, label: t, icon: n, customIcon: r }) => /* @__PURE__ */
|
|
2077
|
+
children: e.map(({ id: e, label: t, icon: n, customIcon: r }) => /* @__PURE__ */ I("div", {
|
|
2078
2078
|
className: f(Qt.iconPickerItem, { [Qt.iconPickerItemSelected]: d === e }, c?.item),
|
|
2079
2079
|
style: l?.item,
|
|
2080
2080
|
title: t,
|
|
@@ -2085,9 +2085,9 @@ function tn({ data: e = [], selectedId: t = null, label: n = "", onChange: r, fo
|
|
|
2085
2085
|
t === "Enter" && g(e);
|
|
2086
2086
|
},
|
|
2087
2087
|
children: [
|
|
2088
|
-
n && /* @__PURE__ */
|
|
2088
|
+
n && /* @__PURE__ */ F(p, { icon: n }),
|
|
2089
2089
|
r ?? null,
|
|
2090
|
-
/* @__PURE__ */
|
|
2090
|
+
/* @__PURE__ */ F(Me, {})
|
|
2091
2091
|
]
|
|
2092
2092
|
}, e))
|
|
2093
2093
|
})]
|
|
@@ -2116,7 +2116,7 @@ function rn({ children: e = null, idleAfterSeconds: t = 600, renderCondition: n
|
|
|
2116
2116
|
for (let e of nn) document.removeEventListener(e, c);
|
|
2117
2117
|
s.current !== null && clearTimeout(s.current);
|
|
2118
2118
|
};
|
|
2119
|
-
}, [c]), /* @__PURE__ */
|
|
2119
|
+
}, [c]), /* @__PURE__ */ F(ce, { children: n && r && e });
|
|
2120
2120
|
}
|
|
2121
2121
|
var an = {
|
|
2122
2122
|
inputDropdown: "inputDropdown_UdYMa",
|
|
@@ -2165,7 +2165,7 @@ function cn({ label: e = "", value: t = "", formValidator: n = null, items: r =
|
|
|
2165
2165
|
C,
|
|
2166
2166
|
O
|
|
2167
2167
|
]);
|
|
2168
|
-
return /* @__PURE__ */
|
|
2168
|
+
return /* @__PURE__ */ I("div", {
|
|
2169
2169
|
...h,
|
|
2170
2170
|
className: f(an.inputDropdown, s?.root, a),
|
|
2171
2171
|
style: {
|
|
@@ -2175,17 +2175,17 @@ function cn({ label: e = "", value: t = "", formValidator: n = null, items: r =
|
|
|
2175
2175
|
onFocus: ee,
|
|
2176
2176
|
onBlur: D,
|
|
2177
2177
|
onKeyDown: k,
|
|
2178
|
-
children: [/* @__PURE__ */
|
|
2178
|
+
children: [/* @__PURE__ */ F(rt, {
|
|
2179
2179
|
label: e,
|
|
2180
2180
|
value: _,
|
|
2181
2181
|
onChange: (e) => {
|
|
2182
2182
|
v(e), w(null);
|
|
2183
2183
|
},
|
|
2184
2184
|
placeholder: m
|
|
2185
|
-
}), /* @__PURE__ */
|
|
2185
|
+
}), /* @__PURE__ */ F("div", {
|
|
2186
2186
|
className: f(an.dropdown, { [an.dropdownShown]: x }, s?.dropdown),
|
|
2187
2187
|
style: c?.dropdown,
|
|
2188
|
-
children: x && E.map((e, t) => /* @__PURE__ */
|
|
2188
|
+
children: x && E.map((e, t) => /* @__PURE__ */ F("div", {
|
|
2189
2189
|
className: f(an.dropdownItem, C === t && an.dropdownItemHighlighted, s?.item),
|
|
2190
2190
|
style: c?.item,
|
|
2191
2191
|
onClick: () => O(e),
|
|
@@ -2214,10 +2214,10 @@ var ln = {
|
|
|
2214
2214
|
//#region package/common/kanbanBoard/KanbanItem.tsx
|
|
2215
2215
|
function un({ id: e, children: t }) {
|
|
2216
2216
|
let { attributes: n, listeners: r, setNodeRef: i, transform: a, transition: o, isDragging: s } = ge({ id: e });
|
|
2217
|
-
return /* @__PURE__ */
|
|
2217
|
+
return /* @__PURE__ */ F("div", {
|
|
2218
2218
|
ref: i,
|
|
2219
2219
|
style: {
|
|
2220
|
-
transform:
|
|
2220
|
+
transform: ve.Transform.toString(a),
|
|
2221
2221
|
transition: o
|
|
2222
2222
|
},
|
|
2223
2223
|
className: f(ln.item, s && ln.itemDragging),
|
|
@@ -2230,20 +2230,20 @@ function un({ id: e, children: t }) {
|
|
|
2230
2230
|
//#region package/common/kanbanBoard/KanbanColumn.tsx
|
|
2231
2231
|
function dn({ id: e, title: t, itemIds: n, items: r, renderItem: i, className: a, classNames: o, styles: s }) {
|
|
2232
2232
|
let { setNodeRef: c, isOver: l } = me({ id: `column-${e}` });
|
|
2233
|
-
return /* @__PURE__ */
|
|
2233
|
+
return /* @__PURE__ */ I("div", {
|
|
2234
2234
|
className: f(ln.column, l && ln.columnOver, n.length === 0 && ln.columnEmpty, a),
|
|
2235
|
-
children: [/* @__PURE__ */
|
|
2235
|
+
children: [/* @__PURE__ */ F("div", {
|
|
2236
2236
|
className: f(ln.columnHeader, o?.header),
|
|
2237
2237
|
style: s?.header,
|
|
2238
2238
|
children: t
|
|
2239
|
-
}), /* @__PURE__ */
|
|
2239
|
+
}), /* @__PURE__ */ F(B, {
|
|
2240
2240
|
items: n,
|
|
2241
2241
|
strategy: _e,
|
|
2242
|
-
children: /* @__PURE__ */
|
|
2242
|
+
children: /* @__PURE__ */ F("div", {
|
|
2243
2243
|
ref: c,
|
|
2244
2244
|
className: f(ln.columnItems, o?.items),
|
|
2245
2245
|
style: s?.items,
|
|
2246
|
-
children: n.map((e) => /* @__PURE__ */
|
|
2246
|
+
children: n.map((e) => /* @__PURE__ */ F(un, {
|
|
2247
2247
|
id: e,
|
|
2248
2248
|
children: r[e] === void 0 ? null : i(r[e], e)
|
|
2249
2249
|
}, e))
|
|
@@ -2303,23 +2303,23 @@ function fn({ columns: e, items: t, renderItem: n, onChange: r, className: i, st
|
|
|
2303
2303
|
}
|
|
2304
2304
|
r(u), p(null);
|
|
2305
2305
|
}
|
|
2306
|
-
return /* @__PURE__ */
|
|
2306
|
+
return /* @__PURE__ */ I(de, {
|
|
2307
2307
|
sensors: m,
|
|
2308
2308
|
collisionDetection: R,
|
|
2309
2309
|
onDragStart: _,
|
|
2310
2310
|
onDragOver: v,
|
|
2311
2311
|
onDragEnd: y,
|
|
2312
|
-
children: [/* @__PURE__ */
|
|
2312
|
+
children: [/* @__PURE__ */ F("div", {
|
|
2313
2313
|
className: f(ln.board, i),
|
|
2314
2314
|
style: a,
|
|
2315
|
-
children: h.map((e) => /* @__PURE__ */
|
|
2315
|
+
children: h.map((e) => /* @__PURE__ */ F(dn, {
|
|
2316
2316
|
id: e.id,
|
|
2317
2317
|
title: e.title,
|
|
2318
2318
|
itemIds: e.itemIds,
|
|
2319
2319
|
items: t,
|
|
2320
2320
|
renderItem: n
|
|
2321
2321
|
}, e.id))
|
|
2322
|
-
}), /* @__PURE__ */
|
|
2322
|
+
}), /* @__PURE__ */ F(fe, { children: c && t[c] !== void 0 ? /* @__PURE__ */ F("div", {
|
|
2323
2323
|
className: f(ln.dragOverlay, o?.dragOverlay),
|
|
2324
2324
|
style: s?.dragOverlay,
|
|
2325
2325
|
children: n(t[c], c)
|
|
@@ -2342,37 +2342,37 @@ var pn = {
|
|
|
2342
2342
|
//#endregion
|
|
2343
2343
|
//#region package/common/loading/iconLoading/iconLoading.tsx
|
|
2344
2344
|
function mn({ className: e = "" }) {
|
|
2345
|
-
return /* @__PURE__ */
|
|
2345
|
+
return /* @__PURE__ */ F("div", {
|
|
2346
2346
|
className: f(pn.iconLoading, e),
|
|
2347
|
-
children: /* @__PURE__ */
|
|
2347
|
+
children: /* @__PURE__ */ I("svg", {
|
|
2348
2348
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2349
2349
|
viewBox: "-8 -1 16 14",
|
|
2350
2350
|
children: [
|
|
2351
|
-
/* @__PURE__ */
|
|
2351
|
+
/* @__PURE__ */ F("path", {
|
|
2352
2352
|
className: pn.iconLoadingFirst,
|
|
2353
2353
|
d: "M 0 0 C 3 5 6 5 6 12",
|
|
2354
2354
|
strokeWidth: "1.7",
|
|
2355
2355
|
fill: "none"
|
|
2356
2356
|
}),
|
|
2357
|
-
/* @__PURE__ */
|
|
2357
|
+
/* @__PURE__ */ F("path", {
|
|
2358
2358
|
className: pn.iconLoadingFirst,
|
|
2359
2359
|
d: "M 0 0 C -3 5 -6 5 -6 12",
|
|
2360
2360
|
strokeWidth: "1.7",
|
|
2361
2361
|
fill: "none"
|
|
2362
2362
|
}),
|
|
2363
|
-
/* @__PURE__ */
|
|
2363
|
+
/* @__PURE__ */ F("path", {
|
|
2364
2364
|
className: pn.iconLoadingFirst,
|
|
2365
2365
|
d: "M 0 0 L 0 10",
|
|
2366
2366
|
strokeWidth: "1.7",
|
|
2367
2367
|
fill: "none"
|
|
2368
2368
|
}),
|
|
2369
|
-
/* @__PURE__ */
|
|
2369
|
+
/* @__PURE__ */ F("path", {
|
|
2370
2370
|
className: pn.iconLoadingSecond,
|
|
2371
2371
|
d: "M 0.1 10 C -3 10 -4 10 -6 12",
|
|
2372
2372
|
strokeWidth: "1.7",
|
|
2373
2373
|
fill: "none"
|
|
2374
2374
|
}),
|
|
2375
|
-
/* @__PURE__ */
|
|
2375
|
+
/* @__PURE__ */ F("path", {
|
|
2376
2376
|
className: pn.iconLoadingSecond,
|
|
2377
2377
|
d: "M -0.1 10 C 3 10 4 10 6 12",
|
|
2378
2378
|
strokeWidth: "1.7",
|
|
@@ -2394,7 +2394,7 @@ function _n({ value: e, onChange: t, formValidator: n, label: r, error: i, class
|
|
|
2394
2394
|
r !== void 0 && (m === "-" && (r = -Math.abs(r)), m === "+" && (r = Math.abs(r))), n?.set(r ?? null), t?.(r);
|
|
2395
2395
|
}
|
|
2396
2396
|
let b = m === "-" ? "-" : m === "+" ? "+" : l;
|
|
2397
|
-
return /* @__PURE__ */
|
|
2397
|
+
return /* @__PURE__ */ F(rt, {
|
|
2398
2398
|
label: r,
|
|
2399
2399
|
className: f(gn.numberInput, a),
|
|
2400
2400
|
value: v,
|
|
@@ -2403,7 +2403,7 @@ function _n({ value: e, onChange: t, formValidator: n, label: r, error: i, class
|
|
|
2403
2403
|
isValid: n ? n.touched ? !n.hasError() : !0 : !i,
|
|
2404
2404
|
errorMessage: n ? n.getCurrentErrorMessage() ?? "" : i ?? "",
|
|
2405
2405
|
placeholder: p,
|
|
2406
|
-
customInput: /* @__PURE__ */
|
|
2406
|
+
customInput: /* @__PURE__ */ F(ye, {
|
|
2407
2407
|
onValueChange: (e) => y(e.floatValue),
|
|
2408
2408
|
allowNegative: m == null ? o : !1,
|
|
2409
2409
|
decimalSeparator: s,
|
|
@@ -2431,16 +2431,16 @@ var vn = _n, yn = {
|
|
|
2431
2431
|
//#region package/common/optionPicker/optionPicker.tsx
|
|
2432
2432
|
function bn({ className: e = void 0, options: t, onChange: n, value: r, ...i }) {
|
|
2433
2433
|
let a = t.findIndex((e) => e.key === r) * 100 / t.length;
|
|
2434
|
-
return /* @__PURE__ */
|
|
2434
|
+
return /* @__PURE__ */ I("div", {
|
|
2435
2435
|
...i,
|
|
2436
2436
|
className: f(yn.optionPicker, e),
|
|
2437
|
-
children: [/* @__PURE__ */
|
|
2437
|
+
children: [/* @__PURE__ */ F("div", {
|
|
2438
2438
|
className: yn.optionPickerChip,
|
|
2439
2439
|
style: {
|
|
2440
2440
|
left: `${a}%`,
|
|
2441
2441
|
width: `${100 / t.length}%`
|
|
2442
2442
|
}
|
|
2443
|
-
}), t.map((e) => /* @__PURE__ */
|
|
2443
|
+
}), t.map((e) => /* @__PURE__ */ F(K, {
|
|
2444
2444
|
onClick: (t) => n(e.key, t),
|
|
2445
2445
|
className: f(yn.optionPickerOption, e.key === r && yn.optionPickerOptionActive),
|
|
2446
2446
|
tabIndex: e.key === r ? -1 : 0,
|
|
@@ -2535,22 +2535,22 @@ function wn({ children: e = null, overscrollContent: t = null, overscrollContent
|
|
|
2535
2535
|
x.current = null, b.current = !1, S.current(!1);
|
|
2536
2536
|
}, 500);
|
|
2537
2537
|
}
|
|
2538
|
-
if (d && !h) return n ? /* @__PURE__ */
|
|
2538
|
+
if (d && !h) return n ? /* @__PURE__ */ I("div", { children: [n, e] }) : /* @__PURE__ */ F(ce, { children: e });
|
|
2539
2539
|
let O = l === "%" ? `${100 - o}%` : `calc(100% - ${o}px)`;
|
|
2540
|
-
return /* @__PURE__ */
|
|
2540
|
+
return /* @__PURE__ */ I("div", {
|
|
2541
2541
|
className: Cn.overscroll,
|
|
2542
2542
|
ref: _,
|
|
2543
2543
|
onScroll: D,
|
|
2544
|
-
children: [/* @__PURE__ */
|
|
2544
|
+
children: [/* @__PURE__ */ F("div", {
|
|
2545
2545
|
className: Cn.overscrollHeaderContainer,
|
|
2546
2546
|
style: { height: `${s}${l}` },
|
|
2547
2547
|
ref: y,
|
|
2548
|
-
children: /* @__PURE__ */
|
|
2548
|
+
children: /* @__PURE__ */ F("div", {
|
|
2549
2549
|
className: f(Cn.overscrollHeader, r && Cn.overscrollHeaderCentered),
|
|
2550
2550
|
ref: v,
|
|
2551
2551
|
children: t
|
|
2552
2552
|
})
|
|
2553
|
-
}), /* @__PURE__ */
|
|
2553
|
+
}), /* @__PURE__ */ F("div", {
|
|
2554
2554
|
style: { minHeight: O },
|
|
2555
2555
|
children: e
|
|
2556
2556
|
})]
|
|
@@ -2578,7 +2578,7 @@ function Dn({ className: e = void 0, total: t = 100, progress: n = 0, style: r =
|
|
|
2578
2578
|
let e = [];
|
|
2579
2579
|
return Array.isArray(n) ? e.push(...n) : typeof n == "object" ? e.push(n) : e.push({ amount: n }), e.map((n, i) => {
|
|
2580
2580
|
let a = t ? n.amount / t * 100 : 0;
|
|
2581
|
-
return /* @__PURE__ */
|
|
2581
|
+
return /* @__PURE__ */ F("div", {
|
|
2582
2582
|
className: f(Tn.progressBarFill, i === e.length - 1 && Tn.progressBarFillEnd, n.class),
|
|
2583
2583
|
style: {
|
|
2584
2584
|
width: `${a}%`,
|
|
@@ -2586,7 +2586,7 @@ function Dn({ className: e = void 0, total: t = 100, progress: n = 0, style: r =
|
|
|
2586
2586
|
...r || {}
|
|
2587
2587
|
},
|
|
2588
2588
|
title: n.label ? `${n.label}: ${n.amount}` : void 0,
|
|
2589
|
-
children: n.label && /* @__PURE__ */
|
|
2589
|
+
children: n.label && /* @__PURE__ */ F("div", {
|
|
2590
2590
|
className: Tn.progressBarLabel,
|
|
2591
2591
|
style: n.color ? { color: En(n.color) } : {},
|
|
2592
2592
|
children: n.label
|
|
@@ -2594,7 +2594,7 @@ function Dn({ className: e = void 0, total: t = 100, progress: n = 0, style: r =
|
|
|
2594
2594
|
}, i);
|
|
2595
2595
|
});
|
|
2596
2596
|
}
|
|
2597
|
-
return /* @__PURE__ */
|
|
2597
|
+
return /* @__PURE__ */ F("div", {
|
|
2598
2598
|
...i,
|
|
2599
2599
|
className: f(Tn.progressBar, e),
|
|
2600
2600
|
style: r,
|
|
@@ -2892,7 +2892,7 @@ function er({ className: e }) {
|
|
|
2892
2892
|
let [t, n] = d([]), [r, i] = d([]), [o, c] = d("rect"), [l, m] = d(null), [g, _] = d(null), [v, y] = d(null), [b, x] = d(null), [T, E] = d([]), [ee, D] = d(null), [k, A] = d(1), [j, M] = d({
|
|
2893
2893
|
x: 0,
|
|
2894
2894
|
y: 0
|
|
2895
|
-
}), N = u(null), ae = u(null), se = u(null), P = u(null),
|
|
2895
|
+
}), N = u(null), ae = u(null), se = u(null), P = u(null), L = u(null), le = u({
|
|
2896
2896
|
rooms: t,
|
|
2897
2897
|
doors: r,
|
|
2898
2898
|
tool: o,
|
|
@@ -3231,17 +3231,17 @@ function er({ className: e }) {
|
|
|
3231
3231
|
name: e
|
|
3232
3232
|
} : t));
|
|
3233
3233
|
}
|
|
3234
|
-
function
|
|
3234
|
+
function ve(e, t) {
|
|
3235
3235
|
let n = parseFloat(t);
|
|
3236
3236
|
isNaN(n) || n <= 0 || i((t) => t.map((t) => t.id === e ? {
|
|
3237
3237
|
...t,
|
|
3238
3238
|
width: n
|
|
3239
3239
|
} : t));
|
|
3240
3240
|
}
|
|
3241
|
-
function
|
|
3241
|
+
function ye() {
|
|
3242
3242
|
l && (n((e) => e.filter((e) => e.id !== l)), i((e) => e.filter((e) => e.roomId !== l)), _(null), m(null));
|
|
3243
3243
|
}
|
|
3244
|
-
function
|
|
3244
|
+
function H(e) {
|
|
3245
3245
|
i((t) => t.filter((t) => t.id !== e));
|
|
3246
3246
|
}
|
|
3247
3247
|
function be(e) {
|
|
@@ -3287,27 +3287,27 @@ function er({ className: e }) {
|
|
|
3287
3287
|
label: "Polygon room"
|
|
3288
3288
|
}
|
|
3289
3289
|
], Ee = 400 / k, De = 300 / k, Oe = g ? Q.roomDrawerCanvasDoor : o === "select" ? Q.roomDrawerCanvasSelect : void 0;
|
|
3290
|
-
return /* @__PURE__ */
|
|
3290
|
+
return /* @__PURE__ */ I("div", {
|
|
3291
3291
|
className: f(Q.roomDrawer, e),
|
|
3292
3292
|
children: [
|
|
3293
|
-
/* @__PURE__ */
|
|
3293
|
+
/* @__PURE__ */ I("div", {
|
|
3294
3294
|
className: Q.roomDrawerToolbar,
|
|
3295
3295
|
children: [
|
|
3296
|
-
U.map(({ t: e, icon: t, label: n }) => /* @__PURE__ */
|
|
3296
|
+
U.map(({ t: e, icon: t, label: n }) => /* @__PURE__ */ F("button", {
|
|
3297
3297
|
title: n,
|
|
3298
3298
|
className: f(Q.roomDrawerToolbarBtn, e === o && !g && Q.roomDrawerToolbarBtnActive),
|
|
3299
3299
|
onClick: () => be(e),
|
|
3300
|
-
children: /* @__PURE__ */
|
|
3300
|
+
children: /* @__PURE__ */ F(p, { icon: t })
|
|
3301
3301
|
}, e)),
|
|
3302
|
-
/* @__PURE__ */
|
|
3303
|
-
/* @__PURE__ */
|
|
3302
|
+
/* @__PURE__ */ F("div", { className: Q.roomDrawerToolbarSep }),
|
|
3303
|
+
/* @__PURE__ */ F("button", {
|
|
3304
3304
|
title: "Zoom in (+)",
|
|
3305
3305
|
className: Q.roomDrawerToolbarBtn,
|
|
3306
3306
|
onClick: () => de(Jn),
|
|
3307
3307
|
disabled: k >= Xn,
|
|
3308
|
-
children: /* @__PURE__ */
|
|
3308
|
+
children: /* @__PURE__ */ F(p, { icon: ne })
|
|
3309
3309
|
}),
|
|
3310
|
-
/* @__PURE__ */
|
|
3310
|
+
/* @__PURE__ */ I("button", {
|
|
3311
3311
|
title: `Reset zoom (0) — ${Math.round(k * 100)}%`,
|
|
3312
3312
|
className: Q.roomDrawerToolbarZoomLabel,
|
|
3313
3313
|
onClick: () => {
|
|
@@ -3318,29 +3318,29 @@ function er({ className: e }) {
|
|
|
3318
3318
|
},
|
|
3319
3319
|
children: [Math.round(k * 100), "%"]
|
|
3320
3320
|
}),
|
|
3321
|
-
/* @__PURE__ */
|
|
3321
|
+
/* @__PURE__ */ F("button", {
|
|
3322
3322
|
title: "Zoom out (−)",
|
|
3323
3323
|
className: Q.roomDrawerToolbarBtn,
|
|
3324
3324
|
onClick: () => de(1 / Jn),
|
|
3325
3325
|
disabled: k <= Yn,
|
|
3326
|
-
children: /* @__PURE__ */
|
|
3326
|
+
children: /* @__PURE__ */ F(p, { icon: te })
|
|
3327
3327
|
}),
|
|
3328
|
-
/* @__PURE__ */
|
|
3329
|
-
/* @__PURE__ */
|
|
3328
|
+
/* @__PURE__ */ F("div", { className: Q.roomDrawerToolbarSep }),
|
|
3329
|
+
/* @__PURE__ */ F("button", {
|
|
3330
3330
|
title: "Upload SVG",
|
|
3331
3331
|
className: Q.roomDrawerToolbarBtn,
|
|
3332
|
-
onClick: () =>
|
|
3333
|
-
children: /* @__PURE__ */
|
|
3332
|
+
onClick: () => L.current?.click(),
|
|
3333
|
+
children: /* @__PURE__ */ F(p, { icon: oe })
|
|
3334
3334
|
}),
|
|
3335
|
-
/* @__PURE__ */
|
|
3335
|
+
/* @__PURE__ */ F("button", {
|
|
3336
3336
|
title: "Download SVG",
|
|
3337
3337
|
className: Q.roomDrawerToolbarBtn,
|
|
3338
3338
|
onClick: () => Gn(t, r),
|
|
3339
3339
|
disabled: t.length === 0,
|
|
3340
|
-
children: /* @__PURE__ */
|
|
3340
|
+
children: /* @__PURE__ */ F(p, { icon: C })
|
|
3341
3341
|
}),
|
|
3342
|
-
/* @__PURE__ */
|
|
3343
|
-
ref:
|
|
3342
|
+
/* @__PURE__ */ F("input", {
|
|
3343
|
+
ref: L,
|
|
3344
3344
|
type: "file",
|
|
3345
3345
|
accept: ".svg,image/svg+xml",
|
|
3346
3346
|
style: { display: "none" },
|
|
@@ -3348,7 +3348,7 @@ function er({ className: e }) {
|
|
|
3348
3348
|
})
|
|
3349
3349
|
]
|
|
3350
3350
|
}),
|
|
3351
|
-
/* @__PURE__ */
|
|
3351
|
+
/* @__PURE__ */ I("svg", {
|
|
3352
3352
|
ref: P,
|
|
3353
3353
|
className: f(Q.roomDrawerCanvas, Oe),
|
|
3354
3354
|
viewBox: `${j.x} ${j.y} ${Ee} ${De}`,
|
|
@@ -3357,18 +3357,18 @@ function er({ className: e }) {
|
|
|
3357
3357
|
onMouseUp: ge,
|
|
3358
3358
|
onDoubleClick: B,
|
|
3359
3359
|
children: [
|
|
3360
|
-
/* @__PURE__ */
|
|
3360
|
+
/* @__PURE__ */ F("defs", { children: /* @__PURE__ */ F("pattern", {
|
|
3361
3361
|
id: "rd-grid",
|
|
3362
3362
|
width: 5,
|
|
3363
3363
|
height: 5,
|
|
3364
3364
|
patternUnits: "userSpaceOnUse",
|
|
3365
|
-
children: /* @__PURE__ */
|
|
3365
|
+
children: /* @__PURE__ */ F("path", {
|
|
3366
3366
|
d: "M 5 0 L 0 0 0 5",
|
|
3367
3367
|
fill: "none",
|
|
3368
3368
|
className: Q.gridLine
|
|
3369
3369
|
})
|
|
3370
3370
|
}) }),
|
|
3371
|
-
/* @__PURE__ */
|
|
3371
|
+
/* @__PURE__ */ F("rect", {
|
|
3372
3372
|
x: j.x,
|
|
3373
3373
|
y: j.y,
|
|
3374
3374
|
width: Ee,
|
|
@@ -3377,16 +3377,16 @@ function er({ className: e }) {
|
|
|
3377
3377
|
}),
|
|
3378
3378
|
t.map((e) => {
|
|
3379
3379
|
let t = e.points, n = t.map((e, t) => `${t === 0 ? "M" : "L"} ${e.x},${e.y}`).join(" ") + " Z", i = Bn(t, r.filter((t) => t.roomId === e.id)), a = Fn(t), o = l === e.id, s = g === e.id;
|
|
3380
|
-
return /* @__PURE__ */
|
|
3381
|
-
/* @__PURE__ */
|
|
3380
|
+
return /* @__PURE__ */ I("g", { children: [
|
|
3381
|
+
/* @__PURE__ */ F("path", {
|
|
3382
3382
|
d: n,
|
|
3383
3383
|
className: f(Q.roomFill, (o || s) && Q.roomFillSelected)
|
|
3384
3384
|
}),
|
|
3385
|
-
i.map((e, t) => /* @__PURE__ */
|
|
3385
|
+
i.map((e, t) => /* @__PURE__ */ F("path", {
|
|
3386
3386
|
d: e,
|
|
3387
3387
|
className: f(Q.roomStroke, (o || s) && Q.roomStrokeSelected)
|
|
3388
3388
|
}, t)),
|
|
3389
|
-
e.name && /* @__PURE__ */
|
|
3389
|
+
e.name && /* @__PURE__ */ F("text", {
|
|
3390
3390
|
x: a.x,
|
|
3391
3391
|
y: a.y,
|
|
3392
3392
|
className: Q.roomText,
|
|
@@ -3400,7 +3400,7 @@ function er({ className: e }) {
|
|
|
3400
3400
|
let n = t.find((t) => t.id === e.roomId);
|
|
3401
3401
|
if (!n) return null;
|
|
3402
3402
|
let r = n.points[e.wallIndex], i = n.points[(e.wallIndex + 1) % n.points.length], a = Ln(r, i, e.t, e.width);
|
|
3403
|
-
return a ? /* @__PURE__ */
|
|
3403
|
+
return a ? /* @__PURE__ */ F("line", {
|
|
3404
3404
|
x1: a.p1.x,
|
|
3405
3405
|
y1: a.p1.y,
|
|
3406
3406
|
x2: a.p2.x,
|
|
@@ -3417,7 +3417,7 @@ function er({ className: e }) {
|
|
|
3417
3417
|
x: (a.p1.x + a.p2.x) / 2,
|
|
3418
3418
|
y: (a.p1.y + a.p2.y) / 2
|
|
3419
3419
|
};
|
|
3420
|
-
return /* @__PURE__ */
|
|
3420
|
+
return /* @__PURE__ */ F("circle", {
|
|
3421
3421
|
cx: o.x,
|
|
3422
3422
|
cy: o.y,
|
|
3423
3423
|
r: 2.5,
|
|
@@ -3427,31 +3427,31 @@ function er({ className: e }) {
|
|
|
3427
3427
|
}
|
|
3428
3428
|
}, e.id);
|
|
3429
3429
|
}),
|
|
3430
|
-
o === "select" && !g && Ce && Ce.points.map((e, t) => /* @__PURE__ */
|
|
3430
|
+
o === "select" && !g && Ce && Ce.points.map((e, t) => /* @__PURE__ */ F("circle", {
|
|
3431
3431
|
cx: e.x,
|
|
3432
3432
|
cy: e.y,
|
|
3433
3433
|
r: 3.5,
|
|
3434
3434
|
className: Q.vertexHandle
|
|
3435
3435
|
}, t)),
|
|
3436
|
-
Se && /* @__PURE__ */
|
|
3436
|
+
Se && /* @__PURE__ */ F("rect", {
|
|
3437
3437
|
x: Se.x,
|
|
3438
3438
|
y: Se.y,
|
|
3439
3439
|
width: Se.w,
|
|
3440
3440
|
height: Se.h,
|
|
3441
3441
|
className: Q.preview
|
|
3442
3442
|
}),
|
|
3443
|
-
o === "polygon" && T.length > 0 && /* @__PURE__ */
|
|
3444
|
-
/* @__PURE__ */
|
|
3443
|
+
o === "polygon" && T.length > 0 && /* @__PURE__ */ I(ce, { children: [
|
|
3444
|
+
/* @__PURE__ */ F("polyline", {
|
|
3445
3445
|
points: [...T, ee ?? T[T.length - 1]].map((e) => `${e.x},${e.y}`).join(" "),
|
|
3446
3446
|
className: Q.preview
|
|
3447
3447
|
}),
|
|
3448
|
-
T.length >= 3 && /* @__PURE__ */
|
|
3448
|
+
T.length >= 3 && /* @__PURE__ */ F("circle", {
|
|
3449
3449
|
cx: T[0].x,
|
|
3450
3450
|
cy: T[0].y,
|
|
3451
3451
|
r: 8 / 2,
|
|
3452
3452
|
className: Q.polyCloseTarget
|
|
3453
3453
|
}),
|
|
3454
|
-
T.map((e, t) => /* @__PURE__ */
|
|
3454
|
+
T.map((e, t) => /* @__PURE__ */ F("circle", {
|
|
3455
3455
|
cx: e.x,
|
|
3456
3456
|
cy: e.y,
|
|
3457
3457
|
r: 2,
|
|
@@ -3460,87 +3460,87 @@ function er({ className: e }) {
|
|
|
3460
3460
|
] })
|
|
3461
3461
|
]
|
|
3462
3462
|
}),
|
|
3463
|
-
Ce && !g && /* @__PURE__ */
|
|
3463
|
+
Ce && !g && /* @__PURE__ */ I("div", {
|
|
3464
3464
|
className: Q.roomDrawerInfo,
|
|
3465
3465
|
children: [
|
|
3466
|
-
/* @__PURE__ */
|
|
3466
|
+
/* @__PURE__ */ F("span", {
|
|
3467
3467
|
className: Q.roomDrawerInfoLabel,
|
|
3468
3468
|
children: "Name"
|
|
3469
3469
|
}),
|
|
3470
|
-
/* @__PURE__ */
|
|
3470
|
+
/* @__PURE__ */ F("input", {
|
|
3471
3471
|
className: Q.roomDrawerInfoInput,
|
|
3472
3472
|
value: Ce.name,
|
|
3473
3473
|
onChange: (e) => _e(e.target.value),
|
|
3474
3474
|
placeholder: "Room name"
|
|
3475
3475
|
}),
|
|
3476
|
-
/* @__PURE__ */
|
|
3476
|
+
/* @__PURE__ */ I("button", {
|
|
3477
3477
|
className: Q.roomDrawerInfoDoorsBtn,
|
|
3478
3478
|
onClick: () => _(Ce.id),
|
|
3479
3479
|
title: "Edit doors",
|
|
3480
|
-
children: [/* @__PURE__ */
|
|
3480
|
+
children: [/* @__PURE__ */ F(p, { icon: S }), /* @__PURE__ */ F("span", { children: r.filter((e) => e.roomId === Ce.id).length })]
|
|
3481
3481
|
}),
|
|
3482
|
-
/* @__PURE__ */
|
|
3482
|
+
/* @__PURE__ */ F("button", {
|
|
3483
3483
|
className: Q.roomDrawerInfoDelete,
|
|
3484
|
-
onClick:
|
|
3484
|
+
onClick: ye,
|
|
3485
3485
|
title: "Delete room",
|
|
3486
|
-
children: /* @__PURE__ */
|
|
3486
|
+
children: /* @__PURE__ */ F(p, { icon: ie })
|
|
3487
3487
|
})
|
|
3488
3488
|
]
|
|
3489
3489
|
}),
|
|
3490
|
-
g && we && /* @__PURE__ */
|
|
3490
|
+
g && we && /* @__PURE__ */ I("div", {
|
|
3491
3491
|
className: Q.roomDrawerDoorPanel,
|
|
3492
|
-
children: [/* @__PURE__ */
|
|
3492
|
+
children: [/* @__PURE__ */ I("div", {
|
|
3493
3493
|
className: Q.roomDrawerDoorPanelHeader,
|
|
3494
3494
|
children: [
|
|
3495
|
-
/* @__PURE__ */
|
|
3495
|
+
/* @__PURE__ */ F(p, {
|
|
3496
3496
|
icon: S,
|
|
3497
3497
|
className: Q.roomDrawerDoorPanelIcon
|
|
3498
3498
|
}),
|
|
3499
|
-
/* @__PURE__ */
|
|
3499
|
+
/* @__PURE__ */ F("span", {
|
|
3500
3500
|
className: Q.roomDrawerDoorPanelTitle,
|
|
3501
3501
|
children: we.name ? `Doors · ${we.name}` : "Doors"
|
|
3502
3502
|
}),
|
|
3503
|
-
/* @__PURE__ */
|
|
3503
|
+
/* @__PURE__ */ I("button", {
|
|
3504
3504
|
className: Q.roomDrawerDoorPanelDone,
|
|
3505
3505
|
onClick: () => _(null),
|
|
3506
3506
|
title: "Done (Esc)",
|
|
3507
|
-
children: [/* @__PURE__ */
|
|
3507
|
+
children: [/* @__PURE__ */ F(p, { icon: h }), "Done"]
|
|
3508
3508
|
})
|
|
3509
3509
|
]
|
|
3510
|
-
}), /* @__PURE__ */
|
|
3510
|
+
}), /* @__PURE__ */ I("div", {
|
|
3511
3511
|
className: Q.roomDrawerDoorPanelList,
|
|
3512
|
-
children: [Te.length === 0 && /* @__PURE__ */
|
|
3512
|
+
children: [Te.length === 0 && /* @__PURE__ */ F("span", {
|
|
3513
3513
|
className: Q.roomDrawerDoorPanelEmpty,
|
|
3514
3514
|
children: "Click on a wall to add a door"
|
|
3515
|
-
}), Te.map((e, t) => /* @__PURE__ */
|
|
3515
|
+
}), Te.map((e, t) => /* @__PURE__ */ I("div", {
|
|
3516
3516
|
className: Q.roomDrawerDoorPanelItem,
|
|
3517
3517
|
children: [
|
|
3518
|
-
/* @__PURE__ */
|
|
3518
|
+
/* @__PURE__ */ I("span", {
|
|
3519
3519
|
className: Q.roomDrawerDoorPanelLabel,
|
|
3520
3520
|
children: ["Door ", t + 1]
|
|
3521
3521
|
}),
|
|
3522
|
-
/* @__PURE__ */
|
|
3522
|
+
/* @__PURE__ */ F("span", {
|
|
3523
3523
|
className: Q.roomDrawerDoorPanelWidthLabel,
|
|
3524
3524
|
children: "Width"
|
|
3525
3525
|
}),
|
|
3526
|
-
/* @__PURE__ */
|
|
3526
|
+
/* @__PURE__ */ F("input", {
|
|
3527
3527
|
className: Q.roomDrawerInfoInput,
|
|
3528
3528
|
type: "number",
|
|
3529
3529
|
min: 1,
|
|
3530
3530
|
value: e.width,
|
|
3531
|
-
onChange: (t) =>
|
|
3531
|
+
onChange: (t) => ve(e.id, t.target.value)
|
|
3532
3532
|
}),
|
|
3533
|
-
/* @__PURE__ */
|
|
3533
|
+
/* @__PURE__ */ F("button", {
|
|
3534
3534
|
className: Q.roomDrawerInfoDelete,
|
|
3535
|
-
onClick: () =>
|
|
3535
|
+
onClick: () => H(e.id),
|
|
3536
3536
|
title: "Delete door",
|
|
3537
|
-
children: /* @__PURE__ */
|
|
3537
|
+
children: /* @__PURE__ */ F(p, { icon: ie })
|
|
3538
3538
|
})
|
|
3539
3539
|
]
|
|
3540
3540
|
}, e.id))]
|
|
3541
3541
|
})]
|
|
3542
3542
|
}),
|
|
3543
|
-
/* @__PURE__ */
|
|
3543
|
+
/* @__PURE__ */ F("div", {
|
|
3544
3544
|
className: Q.roomDrawerHint,
|
|
3545
3545
|
children: g ? "Click a wall to add a door · Adjust width or delete from the list · Done or Esc to finish" : `${$n[o]} · Scroll to zoom · Middle-drag to pan · 0 to reset`
|
|
3546
3546
|
})
|
|
@@ -3605,27 +3605,27 @@ function nr({ data: e = [] }) {
|
|
|
3605
3605
|
});
|
|
3606
3606
|
}
|
|
3607
3607
|
let m = e[r]?.data ?? null;
|
|
3608
|
-
return /* @__PURE__ */
|
|
3608
|
+
return /* @__PURE__ */ I("div", {
|
|
3609
3609
|
className: tr.roomViewer,
|
|
3610
3610
|
ref: t,
|
|
3611
3611
|
children: [
|
|
3612
|
-
/* @__PURE__ */
|
|
3612
|
+
/* @__PURE__ */ F("h3", {
|
|
3613
3613
|
className: tr.roomViewerHeader,
|
|
3614
3614
|
children: e[r]?.label ?? ""
|
|
3615
3615
|
}),
|
|
3616
|
-
/* @__PURE__ */
|
|
3616
|
+
/* @__PURE__ */ F("div", {
|
|
3617
3617
|
className: f(tr.roomViewerContainer, o && tr.roomViewerContainerLoading),
|
|
3618
3618
|
children: m
|
|
3619
3619
|
}, r),
|
|
3620
|
-
e.length > 1 && /* @__PURE__ */
|
|
3620
|
+
e.length > 1 && /* @__PURE__ */ I("div", {
|
|
3621
3621
|
className: tr.roomViewerActions,
|
|
3622
3622
|
children: [
|
|
3623
|
-
/* @__PURE__ */
|
|
3623
|
+
/* @__PURE__ */ F(p, {
|
|
3624
3624
|
icon: _,
|
|
3625
3625
|
onClick: () => l(-1)
|
|
3626
3626
|
}),
|
|
3627
|
-
/* @__PURE__ */
|
|
3628
|
-
/* @__PURE__ */
|
|
3627
|
+
/* @__PURE__ */ F(p, { icon: k }),
|
|
3628
|
+
/* @__PURE__ */ F(p, {
|
|
3629
3629
|
icon: v,
|
|
3630
3630
|
onClick: () => l(1)
|
|
3631
3631
|
})
|
|
@@ -3638,7 +3638,7 @@ var rr = { scrollbarProvider: "scrollbarProvider_IMBFu" };
|
|
|
3638
3638
|
//#endregion
|
|
3639
3639
|
//#region package/common/scrollbarProvider/scrollbarProvider.tsx
|
|
3640
3640
|
function ir({ className: e = void 0, children: t = void 0 }) {
|
|
3641
|
-
return /* @__PURE__ */
|
|
3641
|
+
return /* @__PURE__ */ F("div", {
|
|
3642
3642
|
className: f(rr.scrollbarProvider, e),
|
|
3643
3643
|
children: t
|
|
3644
3644
|
});
|
|
@@ -3660,17 +3660,17 @@ function sr({ value: e, onChange: t, onDebounce: n, placeholder: r, label: i, de
|
|
|
3660
3660
|
}, o);
|
|
3661
3661
|
}
|
|
3662
3662
|
let h = c && typeof s == "number" && !Number.isNaN(s);
|
|
3663
|
-
return /* @__PURE__ */
|
|
3663
|
+
return /* @__PURE__ */ I("div", {
|
|
3664
3664
|
...f,
|
|
3665
3665
|
className: l,
|
|
3666
3666
|
style: d == null ? void 0 : { width: d },
|
|
3667
|
-
children: [/* @__PURE__ */
|
|
3668
|
-
type:
|
|
3667
|
+
children: [/* @__PURE__ */ F(rt, {
|
|
3668
|
+
type: Y.Search,
|
|
3669
3669
|
label: i,
|
|
3670
3670
|
placeholder: r,
|
|
3671
3671
|
value: e,
|
|
3672
3672
|
onChange: m
|
|
3673
|
-
}), h && /* @__PURE__ */
|
|
3673
|
+
}), h && /* @__PURE__ */ I("p", {
|
|
3674
3674
|
className: or.resultCount,
|
|
3675
3675
|
children: [
|
|
3676
3676
|
s,
|
|
@@ -3711,14 +3711,14 @@ var cr = {
|
|
|
3711
3711
|
//#endregion
|
|
3712
3712
|
//#region package/common/stepper/stepper.tsx
|
|
3713
3713
|
function lr() {
|
|
3714
|
-
return /* @__PURE__ */
|
|
3714
|
+
return /* @__PURE__ */ F("svg", {
|
|
3715
3715
|
strokeLinejoin: "round",
|
|
3716
3716
|
strokeLinecap: "round",
|
|
3717
3717
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3718
3718
|
viewBox: "-0.2 -1.2 3.4 2",
|
|
3719
3719
|
height: "20px",
|
|
3720
3720
|
width: "20px",
|
|
3721
|
-
children: /* @__PURE__ */
|
|
3721
|
+
children: /* @__PURE__ */ F("path", {
|
|
3722
3722
|
d: "M 0 0 l 1 1 l 2 -2",
|
|
3723
3723
|
stroke: "white",
|
|
3724
3724
|
strokeWidth: "0.4",
|
|
@@ -3728,7 +3728,7 @@ function lr() {
|
|
|
3728
3728
|
}
|
|
3729
3729
|
function ur({ steps: t = [], currentStep: n = 0, alignment: r = "horizontal", onStepClicked: i = null, nonLinear: a = !1, hideLabels: o = !1, className: s, style: c, classNames: l, styles: u, ...d }) {
|
|
3730
3730
|
let p = r === "vertical";
|
|
3731
|
-
return /* @__PURE__ */
|
|
3731
|
+
return /* @__PURE__ */ F("div", {
|
|
3732
3732
|
...d,
|
|
3733
3733
|
className: f(cr.stepper, { [cr.stepperVertical]: p }, l?.root, s),
|
|
3734
3734
|
style: {
|
|
@@ -3736,27 +3736,27 @@ function ur({ steps: t = [], currentStep: n = 0, alignment: r = "horizontal", on
|
|
|
3736
3736
|
...c
|
|
3737
3737
|
},
|
|
3738
3738
|
children: t.map((r, s) => {
|
|
3739
|
-
let c = s < n, d = s <= n, m = !!i && (a ? s !== n : c), h = f(cr.stepperEntry, { [cr.stepperEntryActive]: d }, { [cr.stepperEntryDone]: c }, { [cr.stepperClickable]: m }, l?.entry), g = /* @__PURE__ */
|
|
3739
|
+
let c = s < n, d = s <= n, m = !!i && (a ? s !== n : c), h = f(cr.stepperEntry, { [cr.stepperEntryActive]: d }, { [cr.stepperEntryDone]: c }, { [cr.stepperClickable]: m }, l?.entry), g = /* @__PURE__ */ I(ce, { children: [/* @__PURE__ */ F("div", {
|
|
3740
3740
|
className: f(cr.stepperEntryNumber, { [cr.stepperEntryNumberDone]: c }, l?.entryNumber),
|
|
3741
3741
|
style: u?.entryNumber,
|
|
3742
|
-
children: c ? /* @__PURE__ */
|
|
3743
|
-
}), !o && /* @__PURE__ */
|
|
3742
|
+
children: c ? /* @__PURE__ */ F(lr, {}) : s + 1
|
|
3743
|
+
}), !o && /* @__PURE__ */ F("div", {
|
|
3744
3744
|
className: f(cr.stepperEntryLabel, { [cr.stepperEntryLabelVertical]: p }, l?.entryLabel),
|
|
3745
3745
|
style: u?.entryLabel,
|
|
3746
3746
|
children: r.label
|
|
3747
3747
|
})] });
|
|
3748
|
-
return /* @__PURE__ */
|
|
3748
|
+
return /* @__PURE__ */ I(e.Fragment, { children: [m ? /* @__PURE__ */ F(K, {
|
|
3749
3749
|
className: h,
|
|
3750
3750
|
style: u?.entry,
|
|
3751
3751
|
onClick: () => i(s),
|
|
3752
3752
|
"aria-current": s === n ? "step" : void 0,
|
|
3753
3753
|
children: g
|
|
3754
|
-
}) : /* @__PURE__ */
|
|
3754
|
+
}) : /* @__PURE__ */ F("div", {
|
|
3755
3755
|
className: h,
|
|
3756
3756
|
style: u?.entry,
|
|
3757
3757
|
"aria-current": s === n ? "step" : void 0,
|
|
3758
3758
|
children: g
|
|
3759
|
-
}), s < t.length - 1 && /* @__PURE__ */
|
|
3759
|
+
}), s < t.length - 1 && /* @__PURE__ */ F("div", {
|
|
3760
3760
|
className: f(cr.stepperConnector, { [cr.stepperConnectorFilled]: c }, { [cr.stepperConnectorVertical]: p }, l?.connector),
|
|
3761
3761
|
style: u?.connector
|
|
3762
3762
|
})] }, s);
|
|
@@ -3806,13 +3806,13 @@ function mr({ className: e, previewItems: t = [], onSelect: n, onLoadAdditional:
|
|
|
3806
3806
|
let t = e.currentTarget, n = t.scrollHeight - t.clientHeight * 1.5;
|
|
3807
3807
|
t.scrollTop >= n && r?.();
|
|
3808
3808
|
}
|
|
3809
|
-
return /* @__PURE__ */
|
|
3809
|
+
return /* @__PURE__ */ F(ce, { children: t.length > 0 && /* @__PURE__ */ F("div", {
|
|
3810
3810
|
className: f(pr.gifPreview, e),
|
|
3811
3811
|
onScroll: i,
|
|
3812
|
-
children: t.map((e, t) => /* @__PURE__ */
|
|
3812
|
+
children: t.map((e, t) => /* @__PURE__ */ F(K, {
|
|
3813
3813
|
className: pr.gifPreviewImageContainer,
|
|
3814
3814
|
onClick: () => n?.(e),
|
|
3815
|
-
children: /* @__PURE__ */
|
|
3815
|
+
children: /* @__PURE__ */ F("div", {
|
|
3816
3816
|
className: pr.gifPreviewImage,
|
|
3817
3817
|
style: { backgroundImage: `url(${e.media_formats.tinygif.url})` }
|
|
3818
3818
|
})
|
|
@@ -3831,13 +3831,13 @@ function gr({ className: e, src: t = "" }) {
|
|
|
3831
3831
|
let [n, r] = d(!0);
|
|
3832
3832
|
return a(() => {
|
|
3833
3833
|
r(!0);
|
|
3834
|
-
}, [t]), /* @__PURE__ */
|
|
3834
|
+
}, [t]), /* @__PURE__ */ I("div", {
|
|
3835
3835
|
className: f(hr.gifView, e),
|
|
3836
|
-
children: [/* @__PURE__ */
|
|
3836
|
+
children: [/* @__PURE__ */ F("img", {
|
|
3837
3837
|
className: hr.tenorPickerSelected,
|
|
3838
3838
|
src: t,
|
|
3839
3839
|
onLoad: () => r(!1)
|
|
3840
|
-
}), n && /* @__PURE__ */
|
|
3840
|
+
}), n && /* @__PURE__ */ F("div", { className: hr.gifViewLoading })]
|
|
3841
3841
|
});
|
|
3842
3842
|
}
|
|
3843
3843
|
var _r = {
|
|
@@ -3877,10 +3877,10 @@ function vr({ className: e, token: t = "", isModal: n = !1, onSelect: r = () =>
|
|
|
3877
3877
|
await r(e), v(!1), e && a.registerShare(o, e.id);
|
|
3878
3878
|
}
|
|
3879
3879
|
function S() {
|
|
3880
|
-
return /* @__PURE__ */
|
|
3880
|
+
return /* @__PURE__ */ F(Xe, {
|
|
3881
3881
|
inline: !0,
|
|
3882
3882
|
className: _r.tenorPickerSuggestionsContainer,
|
|
3883
|
-
children: p.map((e) => /* @__PURE__ */
|
|
3883
|
+
children: p.map((e) => /* @__PURE__ */ F(Ye, {
|
|
3884
3884
|
className: _r.tenorPickerSuggestionsItem,
|
|
3885
3885
|
text: e,
|
|
3886
3886
|
onClick: () => y(e)
|
|
@@ -3888,42 +3888,42 @@ function vr({ className: e, token: t = "", isModal: n = !1, onSelect: r = () =>
|
|
|
3888
3888
|
});
|
|
3889
3889
|
}
|
|
3890
3890
|
function C() {
|
|
3891
|
-
return /* @__PURE__ */
|
|
3891
|
+
return /* @__PURE__ */ F(mr, {
|
|
3892
3892
|
previewItems: l,
|
|
3893
3893
|
onSelect: x,
|
|
3894
3894
|
onLoadAdditional: b
|
|
3895
3895
|
});
|
|
3896
3896
|
}
|
|
3897
3897
|
function w() {
|
|
3898
|
-
return /* @__PURE__ */
|
|
3898
|
+
return /* @__PURE__ */ F(sr, {
|
|
3899
3899
|
label: "Pick gif",
|
|
3900
3900
|
value: o,
|
|
3901
3901
|
onDebounce: y,
|
|
3902
3902
|
onChange: s
|
|
3903
3903
|
});
|
|
3904
3904
|
}
|
|
3905
|
-
return n ? /* @__PURE__ */
|
|
3905
|
+
return n ? /* @__PURE__ */ I("div", {
|
|
3906
3906
|
className: f(_r.tenorPicker, e),
|
|
3907
3907
|
children: [
|
|
3908
|
-
/* @__PURE__ */
|
|
3908
|
+
/* @__PURE__ */ I("div", {
|
|
3909
3909
|
className: Te.actionButtons,
|
|
3910
|
-
children: [/* @__PURE__ */
|
|
3910
|
+
children: [/* @__PURE__ */ F(G, {
|
|
3911
3911
|
onClick: () => v(!0),
|
|
3912
3912
|
children: "Pick gif"
|
|
3913
|
-
}), i && /* @__PURE__ */
|
|
3913
|
+
}), i && /* @__PURE__ */ F(G, {
|
|
3914
3914
|
styleType: W.Delete,
|
|
3915
3915
|
onClick: () => x(null),
|
|
3916
3916
|
children: "Remove gif"
|
|
3917
3917
|
})]
|
|
3918
3918
|
}),
|
|
3919
|
-
i && /* @__PURE__ */
|
|
3919
|
+
i && /* @__PURE__ */ F(gr, {
|
|
3920
3920
|
className: _r.tenorPickerSelected,
|
|
3921
3921
|
src: i
|
|
3922
3922
|
}),
|
|
3923
|
-
/* @__PURE__ */
|
|
3923
|
+
/* @__PURE__ */ F(ht, {
|
|
3924
3924
|
isOpen: _,
|
|
3925
3925
|
onClose: () => v(!1),
|
|
3926
|
-
children: /* @__PURE__ */
|
|
3926
|
+
children: /* @__PURE__ */ I("div", {
|
|
3927
3927
|
className: _r.tenorPickerModalContent,
|
|
3928
3928
|
children: [
|
|
3929
3929
|
w(),
|
|
@@ -3933,22 +3933,22 @@ function vr({ className: e, token: t = "", isModal: n = !1, onSelect: r = () =>
|
|
|
3933
3933
|
})
|
|
3934
3934
|
})
|
|
3935
3935
|
]
|
|
3936
|
-
}) : /* @__PURE__ */
|
|
3936
|
+
}) : /* @__PURE__ */ I("div", {
|
|
3937
3937
|
className: f(_r.tenorPicker, e),
|
|
3938
3938
|
children: [
|
|
3939
|
-
/* @__PURE__ */
|
|
3940
|
-
align:
|
|
3939
|
+
/* @__PURE__ */ F(et, {
|
|
3940
|
+
align: Qe.Left,
|
|
3941
3941
|
isOpen: l.length > 0 && _,
|
|
3942
3942
|
onOpenChange: v,
|
|
3943
|
-
content: /* @__PURE__ */
|
|
3943
|
+
content: /* @__PURE__ */ I(ce, { children: [S(), C()] }),
|
|
3944
3944
|
children: w()
|
|
3945
3945
|
}),
|
|
3946
|
-
i && /* @__PURE__ */
|
|
3946
|
+
i && /* @__PURE__ */ F(G, {
|
|
3947
3947
|
styleType: W.Delete,
|
|
3948
3948
|
onClick: () => x(null),
|
|
3949
3949
|
children: "Remove gif"
|
|
3950
3950
|
}),
|
|
3951
|
-
i && /* @__PURE__ */
|
|
3951
|
+
i && /* @__PURE__ */ F(gr, {
|
|
3952
3952
|
className: _r.tenorPickerSelected,
|
|
3953
3953
|
src: i
|
|
3954
3954
|
})
|
|
@@ -3958,7 +3958,7 @@ function vr({ className: e, token: t = "", isModal: n = !1, onSelect: r = () =>
|
|
|
3958
3958
|
//#endregion
|
|
3959
3959
|
//#region package/common/textarea/textarea.tsx
|
|
3960
3960
|
function yr(e) {
|
|
3961
|
-
return /* @__PURE__ */
|
|
3961
|
+
return /* @__PURE__ */ F(rt, {
|
|
3962
3962
|
...e,
|
|
3963
3963
|
multiline: !0
|
|
3964
3964
|
});
|
|
@@ -4071,7 +4071,7 @@ var br = {
|
|
|
4071
4071
|
}
|
|
4072
4072
|
render() {
|
|
4073
4073
|
let { children: e } = this.props, { resolvedVariables: t, colorFadeActive: n } = this.state;
|
|
4074
|
-
return /* @__PURE__ */
|
|
4074
|
+
return /* @__PURE__ */ F("div", {
|
|
4075
4075
|
ref: this.wrapperRef,
|
|
4076
4076
|
id: "themeProvider",
|
|
4077
4077
|
className: n ? xr.colorFade : void 0,
|
|
@@ -4145,28 +4145,28 @@ function Er({ item: e, isBottom: t, onDismiss: n }) {
|
|
|
4145
4145
|
r,
|
|
4146
4146
|
c,
|
|
4147
4147
|
n
|
|
4148
|
-
]), /* @__PURE__ */
|
|
4148
|
+
]), /* @__PURE__ */ I("div", {
|
|
4149
4149
|
className: f(wr.toast, t ? wr.toastBottom : null, wr[`toast-${d}`], s && wr.toastDismissing, m?.root),
|
|
4150
4150
|
style: h?.root,
|
|
4151
4151
|
children: [
|
|
4152
|
-
/* @__PURE__ */
|
|
4152
|
+
/* @__PURE__ */ F(p, {
|
|
4153
4153
|
icon: Tr[d],
|
|
4154
4154
|
className: f(wr.toastIcon, m?.icon),
|
|
4155
4155
|
style: h?.icon
|
|
4156
4156
|
}),
|
|
4157
|
-
/* @__PURE__ */
|
|
4157
|
+
/* @__PURE__ */ F("div", {
|
|
4158
4158
|
className: f(wr.toastContent, m?.content),
|
|
4159
4159
|
style: h?.content,
|
|
4160
4160
|
children: i
|
|
4161
4161
|
}),
|
|
4162
|
-
u && /* @__PURE__ */
|
|
4162
|
+
u && /* @__PURE__ */ F(ze, {
|
|
4163
4163
|
icon: se,
|
|
4164
4164
|
onClick: () => n(r),
|
|
4165
4165
|
className: f(wr.toastCloseButton, m?.closeButton),
|
|
4166
4166
|
style: h?.closeButton,
|
|
4167
4167
|
"aria-label": "Close"
|
|
4168
4168
|
}),
|
|
4169
|
-
l && c > 0 && /* @__PURE__ */
|
|
4169
|
+
l && c > 0 && /* @__PURE__ */ F("div", {
|
|
4170
4170
|
className: f(wr.toastProgressBar, m?.progressBar),
|
|
4171
4171
|
style: {
|
|
4172
4172
|
"--toast-duration": `${c}ms`,
|
|
@@ -4247,9 +4247,9 @@ function Pr({ children: e, position: t = jr.position, duration: n = jr.duration,
|
|
|
4247
4247
|
let n = t.options.position;
|
|
4248
4248
|
return e[n] || (e[n] = []), e[n].push(t), e;
|
|
4249
4249
|
}, {});
|
|
4250
|
-
return /* @__PURE__ */
|
|
4250
|
+
return /* @__PURE__ */ I(ce, { children: [e, /* @__PURE__ */ F(Be, { children: Object.entries(g).map(([e, t]) => /* @__PURE__ */ F("div", {
|
|
4251
4251
|
className: f(wr.container, Nr(e)),
|
|
4252
|
-
children: t.map((t) => /* @__PURE__ */
|
|
4252
|
+
children: t.map((t) => /* @__PURE__ */ F(Er, {
|
|
4253
4253
|
item: t,
|
|
4254
4254
|
isBottom: e.startsWith("bottom"),
|
|
4255
4255
|
onDismiss: m
|
|
@@ -4351,7 +4351,7 @@ function Br({ index: e, top: t, columnTemplate: n, isSelected: r, showDivider: i
|
|
|
4351
4351
|
return s(() => {
|
|
4352
4352
|
let e = T.current;
|
|
4353
4353
|
if (!(!e || !o)) return o.observe(e), () => o.unobserve(e);
|
|
4354
|
-
}, [o]), /* @__PURE__ */
|
|
4354
|
+
}, [o]), /* @__PURE__ */ F("div", {
|
|
4355
4355
|
ref: T,
|
|
4356
4356
|
"data-index": e,
|
|
4357
4357
|
className: f($.virtualListRow, r && $.virtualListRowSelected, !i && $.virtualListRowNoDivider, m && $.virtualListRowDraggable, g && $.virtualListRowDragging, S),
|
|
@@ -4385,13 +4385,13 @@ function Br({ index: e, top: t, columnTemplate: n, isSelected: r, showDivider: i
|
|
|
4385
4385
|
});
|
|
4386
4386
|
}
|
|
4387
4387
|
function Vr({ items: e, renderRow: t, columns: n, height: r = "100%", estimatedRowHeight: l = 40, overscan: m = 3, rowGap: h = 0, selectedKey: g, getItemKey: _, onRowClick: v, visibleColumnKeys: y, onVisibleColumnsChange: b, showColumnToggle: x, onLoadMore: S, loadMoreThreshold: C = 100, isLoading: w = !1, multiSelect: T = !1, selectedKeys: E, onSelectionChange: ee, reorderable: O = !1, onReorder: k, longPressDelay: te = 400, showDivider: ne = !0, className: A, style: j, classNames: M, styles: N, ...re }, ie) {
|
|
4388
|
-
let [ae, oe] = d(0), [se, P] = d(0), [
|
|
4388
|
+
let [ae, oe] = d(0), [se, P] = d(0), [L, le] = d(/* @__PURE__ */ new Map()), [ue, de] = d(!1), [fe, pe] = d(!1), R = u(!1), me = u(null), [he, z] = d(null), B = u(null), V = u(!1), ge = u(null), _e = u(0), ve = u(0), ye = u(null), H = u(!1), be = u(k), xe = u(null), Se = u(0), Ce = u(0), we = u(0), [Te] = d(() => typeof window < "u" && typeof window.matchMedia == "function" ? window.matchMedia("(pointer: coarse)").matches : !1), U = E !== void 0, [Ee, De] = d(/* @__PURE__ */ new Set()), W = U ? E : Ee, ke = y !== void 0, [Ae, je] = d(() => new Set((n ?? []).filter((e) => !e.defaultHidden).map((e) => e.key))), Me = ke ? new Set(y) : Ae, Ne = u(null), Pe = u(null), G = u(null), Fe = u([]), Ie = u(null), Le = u(0), K = u([]), [Re] = d(() => typeof ResizeObserver > "u" ? null : new ResizeObserver((e) => {
|
|
4389
4389
|
le((t) => {
|
|
4390
4390
|
let n = null;
|
|
4391
4391
|
for (let r of e) {
|
|
4392
4392
|
let e = r.target, i = Number(e.dataset.index);
|
|
4393
4393
|
if (Number.isNaN(i)) continue;
|
|
4394
|
-
let a =
|
|
4394
|
+
let a = K.current[i];
|
|
4395
4395
|
if (a === void 0) continue;
|
|
4396
4396
|
let o = r.borderBoxSize?.[0], s = o ? Math.round(o.blockSize) : e.offsetHeight;
|
|
4397
4397
|
t.get(a) !== s && (n ||= new Map(t), n.set(a, s));
|
|
@@ -4399,7 +4399,7 @@ function Vr({ items: e, renderRow: t, columns: n, height: r = "100%", estimatedR
|
|
|
4399
4399
|
return n ?? t;
|
|
4400
4400
|
});
|
|
4401
4401
|
}));
|
|
4402
|
-
a(() => () =>
|
|
4402
|
+
a(() => () => Re?.disconnect(), [Re]), s(() => {
|
|
4403
4403
|
let e = Ne.current;
|
|
4404
4404
|
if (!e) return;
|
|
4405
4405
|
P(e.clientHeight);
|
|
@@ -4412,7 +4412,7 @@ function Vr({ items: e, renderRow: t, columns: n, height: r = "100%", estimatedR
|
|
|
4412
4412
|
}
|
|
4413
4413
|
return document.addEventListener("mousedown", e), () => document.removeEventListener("mousedown", e);
|
|
4414
4414
|
}, [ue]);
|
|
4415
|
-
let
|
|
4415
|
+
let ze = i((e) => {
|
|
4416
4416
|
let t = e.currentTarget;
|
|
4417
4417
|
Le.current = t.scrollTop, Ie.current ??= requestAnimationFrame(() => {
|
|
4418
4418
|
Ie.current = null, oe(Le.current);
|
|
@@ -4423,26 +4423,26 @@ function Vr({ items: e, renderRow: t, columns: n, height: r = "100%", estimatedR
|
|
|
4423
4423
|
a(() => () => {
|
|
4424
4424
|
Ie.current != null && cancelAnimationFrame(Ie.current);
|
|
4425
4425
|
}, []);
|
|
4426
|
-
let
|
|
4426
|
+
let Be = c(() => e.map((e, t) => _ ? _(e, t) : t), [e, _]);
|
|
4427
4427
|
s(() => {
|
|
4428
|
-
|
|
4428
|
+
K.current = Be, be.current = k;
|
|
4429
4429
|
});
|
|
4430
|
-
let { offsets:
|
|
4431
|
-
|
|
4432
|
-
|
|
4430
|
+
let { offsets: q, totalHeight: Ve } = c(() => Fr(Be, L, l, h), [
|
|
4431
|
+
Be,
|
|
4432
|
+
L,
|
|
4433
4433
|
l,
|
|
4434
4434
|
h
|
|
4435
4435
|
]);
|
|
4436
4436
|
s(() => {
|
|
4437
4437
|
let t = Ne.current, n = Fe.current;
|
|
4438
|
-
if (Fe.current =
|
|
4438
|
+
if (Fe.current = q, !t || n.length === 0) return;
|
|
4439
4439
|
let r = t.scrollTop;
|
|
4440
4440
|
if (r <= 0) return;
|
|
4441
4441
|
let i = Ir(n, r, n.length - 1);
|
|
4442
4442
|
if (i >= e.length) return;
|
|
4443
|
-
let a = r - n[i], o =
|
|
4443
|
+
let a = r - n[i], o = q[i] + a;
|
|
4444
4444
|
Math.abs(o - r) > .5 && (t.scrollTop = o, Le.current = o, oe(o));
|
|
4445
|
-
}, [
|
|
4445
|
+
}, [q, e.length]), o(ie, () => {
|
|
4446
4446
|
function t(e, t) {
|
|
4447
4447
|
let n = Ne.current;
|
|
4448
4448
|
if (!n) return;
|
|
@@ -4455,7 +4455,7 @@ function Vr({ items: e, renderRow: t, columns: n, height: r = "100%", estimatedR
|
|
|
4455
4455
|
function n(n, r) {
|
|
4456
4456
|
let i = Ne.current;
|
|
4457
4457
|
if (!i || e.length === 0) return;
|
|
4458
|
-
let a = Math.max(0, Math.min(n, e.length - 1)), o =
|
|
4458
|
+
let a = Math.max(0, Math.min(n, e.length - 1)), o = q[a] ?? 0, s = (q[a + 1] ?? o) - o, c = Pe.current?.offsetHeight ?? 0, l = Math.max(0, i.clientHeight - c), u = r?.align ?? "start", d = o - c;
|
|
4459
4459
|
u === "center" ? d -= (l - s) / 2 : u === "end" && (d -= l - s), t(d, r?.behavior);
|
|
4460
4460
|
}
|
|
4461
4461
|
return {
|
|
@@ -4471,17 +4471,17 @@ function Vr({ items: e, renderRow: t, columns: n, height: r = "100%", estimatedR
|
|
|
4471
4471
|
};
|
|
4472
4472
|
}, [
|
|
4473
4473
|
e,
|
|
4474
|
-
|
|
4474
|
+
q,
|
|
4475
4475
|
_
|
|
4476
4476
|
]);
|
|
4477
|
-
let { startIndex:
|
|
4478
|
-
|
|
4477
|
+
let { startIndex: He, endIndex: Ue } = c(() => Lr(q, ae, se, m, e.length), [
|
|
4478
|
+
q,
|
|
4479
4479
|
ae,
|
|
4480
4480
|
se,
|
|
4481
4481
|
m,
|
|
4482
4482
|
e.length
|
|
4483
|
-
]),
|
|
4484
|
-
function
|
|
4483
|
+
]), We = !!n?.length, Ge = We ? n.filter((e) => Me.has(e.key)) : [], Ke = We ? `${T && We ? "40px " : ""}${zr(Ge)}` : void 0, Je = x !== !1 && We;
|
|
4484
|
+
function Ye(e) {
|
|
4485
4485
|
let t = new Set(Me);
|
|
4486
4486
|
if (t.has(e)) {
|
|
4487
4487
|
if (t.size <= 1) return;
|
|
@@ -4490,82 +4490,82 @@ function Vr({ items: e, renderRow: t, columns: n, height: r = "100%", estimatedR
|
|
|
4490
4490
|
let n = [...t];
|
|
4491
4491
|
ke || je(t), b?.(n);
|
|
4492
4492
|
}
|
|
4493
|
-
function
|
|
4493
|
+
function Xe(e, t) {
|
|
4494
4494
|
return _ ? _(e, t) : t;
|
|
4495
4495
|
}
|
|
4496
|
-
function
|
|
4496
|
+
function Ze(e) {
|
|
4497
4497
|
U || De(e), ee?.(e);
|
|
4498
4498
|
}
|
|
4499
|
-
function
|
|
4499
|
+
function Qe(e) {
|
|
4500
4500
|
let t = new Set(W);
|
|
4501
|
-
t.has(e) ? t.delete(e) : t.add(e),
|
|
4501
|
+
t.has(e) ? t.delete(e) : t.add(e), Ze(t);
|
|
4502
4502
|
}
|
|
4503
|
-
function
|
|
4504
|
-
let t = e.map((e, t) =>
|
|
4505
|
-
|
|
4503
|
+
function $e() {
|
|
4504
|
+
let t = e.map((e, t) => Xe(e, t));
|
|
4505
|
+
Ze(t.every((e) => W.has(e)) ? /* @__PURE__ */ new Set() : new Set(t));
|
|
4506
4506
|
}
|
|
4507
|
-
function
|
|
4507
|
+
function et(e) {
|
|
4508
4508
|
me.current = e, z(e);
|
|
4509
4509
|
}
|
|
4510
|
-
function
|
|
4510
|
+
function tt(e, t) {
|
|
4511
4511
|
t.preventDefault();
|
|
4512
4512
|
let n = me.current;
|
|
4513
4513
|
if (n == null) return;
|
|
4514
|
-
let r =
|
|
4514
|
+
let r = Be.indexOf(n), i = t.currentTarget.getBoundingClientRect(), a = Rr(r, e, t.clientY, i.top, i.height);
|
|
4515
4515
|
a != null && k?.(r, a);
|
|
4516
4516
|
}
|
|
4517
|
-
function
|
|
4517
|
+
function nt() {
|
|
4518
4518
|
me.current = null, z(null);
|
|
4519
4519
|
}
|
|
4520
|
-
let
|
|
4520
|
+
let J = i((e) => {
|
|
4521
4521
|
let t = me.current, n = Ne.current;
|
|
4522
4522
|
if (t == null || !n) return;
|
|
4523
|
-
let r = xe.current ?
|
|
4523
|
+
let r = xe.current ? ve.current - Se.current + we.current / 2 : ve.current, i = document.elementFromPoint(e, r), a = i && n.contains(i) ? i.closest("[data-index]") : null;
|
|
4524
4524
|
if (!a) return;
|
|
4525
4525
|
let o = Number(a.dataset.index);
|
|
4526
4526
|
if (Number.isNaN(o)) return;
|
|
4527
|
-
let s =
|
|
4527
|
+
let s = K.current.indexOf(t), c = a.getBoundingClientRect(), l = Rr(s, o, r, c.top, c.height);
|
|
4528
4528
|
l != null && be.current?.(s, l);
|
|
4529
|
-
}, []),
|
|
4529
|
+
}, []), Y = i(() => {
|
|
4530
4530
|
let e = xe.current;
|
|
4531
|
-
e && (e.style.transform = `translate(${Ce.current}px, ${
|
|
4532
|
-
}, []),
|
|
4531
|
+
e && (e.style.transform = `translate(${Ce.current}px, ${ve.current - Se.current}px)`);
|
|
4532
|
+
}, []), rt = i(() => {
|
|
4533
4533
|
let e = Ne.current;
|
|
4534
4534
|
if (!e || !V.current) {
|
|
4535
|
-
|
|
4535
|
+
ye.current = null;
|
|
4536
4536
|
return;
|
|
4537
4537
|
}
|
|
4538
|
-
let t = e.getBoundingClientRect(), n = _e.current, r =
|
|
4539
|
-
n >= t.left && n <= t.right && r >= t.top && r <= t.bottom && (r < t.top + 48 ? i = -Math.min(18, Math.ceil((t.top + 48 - r) / 3)) : r > t.bottom - 48 && (i = Math.min(18, Math.ceil((r - (t.bottom - 48)) / 3)))), i !== 0 && (e.scrollTop += i,
|
|
4540
|
-
}, [
|
|
4541
|
-
B.current != null && (clearTimeout(B.current), B.current = null), window.removeEventListener("touchmove",
|
|
4542
|
-
|
|
4538
|
+
let t = e.getBoundingClientRect(), n = _e.current, r = ve.current, i = 0;
|
|
4539
|
+
n >= t.left && n <= t.right && r >= t.top && r <= t.bottom && (r < t.top + 48 ? i = -Math.min(18, Math.ceil((t.top + 48 - r) / 3)) : r > t.bottom - 48 && (i = Math.min(18, Math.ceil((r - (t.bottom - 48)) / 3)))), i !== 0 && (e.scrollTop += i, J(n)), ye.current = requestAnimationFrame(rt);
|
|
4540
|
+
}, [J]), X = i(() => {
|
|
4541
|
+
B.current != null && (clearTimeout(B.current), B.current = null), window.removeEventListener("touchmove", it), window.removeEventListener("touchend", X), window.removeEventListener("touchcancel", X), ye.current != null && (cancelAnimationFrame(ye.current), ye.current = null), xe.current &&= (xe.current.remove(), null), document.body.style.touchAction = "", document.body.style.overscrollBehavior = "", V.current && (H.current = !0, setTimeout(() => {
|
|
4542
|
+
H.current = !1;
|
|
4543
4543
|
}, 350)), V.current = !1, ge.current = null, me.current = null, z(null);
|
|
4544
|
-
}, []),
|
|
4544
|
+
}, []), it = i((e) => {
|
|
4545
4545
|
let t = e.touches[0];
|
|
4546
4546
|
if (t) {
|
|
4547
|
-
if (_e.current = t.clientX,
|
|
4547
|
+
if (_e.current = t.clientX, ve.current = t.clientY, !V.current) {
|
|
4548
4548
|
let e = ge.current;
|
|
4549
4549
|
e != null && Math.abs(t.clientY - e) > 10 && B.current != null && (clearTimeout(B.current), B.current = null);
|
|
4550
4550
|
return;
|
|
4551
4551
|
}
|
|
4552
|
-
e.cancelable && e.preventDefault(),
|
|
4552
|
+
e.cancelable && e.preventDefault(), Y(), J(t.clientX);
|
|
4553
4553
|
}
|
|
4554
|
-
}, [
|
|
4555
|
-
function
|
|
4554
|
+
}, [J, Y]);
|
|
4555
|
+
function at(e, t) {
|
|
4556
4556
|
if (!O || B.current != null || V.current) return;
|
|
4557
4557
|
let n = t.touches[0];
|
|
4558
|
-
n && (ge.current = n.clientY, _e.current = n.clientX,
|
|
4559
|
-
B.current = null, V.current = !0, me.current = e, z(e), navigator.vibrate?.(10), document.body.style.touchAction = "none", document.body.style.overscrollBehavior = "none",
|
|
4558
|
+
n && (ge.current = n.clientY, _e.current = n.clientX, ve.current = n.clientY, window.addEventListener("touchmove", it, { passive: !1 }), window.addEventListener("touchend", X), window.addEventListener("touchcancel", X), B.current = window.setTimeout(() => {
|
|
4559
|
+
B.current = null, V.current = !0, me.current = e, z(e), navigator.vibrate?.(10), document.body.style.touchAction = "none", document.body.style.overscrollBehavior = "none", ot(e), ye.current ??= requestAnimationFrame(rt);
|
|
4560
4560
|
}, te));
|
|
4561
4561
|
}
|
|
4562
|
-
function
|
|
4562
|
+
function ot(e) {
|
|
4563
4563
|
let t = Ne.current;
|
|
4564
4564
|
if (!t) return;
|
|
4565
|
-
let n =
|
|
4565
|
+
let n = K.current.indexOf(e), r = t.querySelector(`[data-index="${n}"]`);
|
|
4566
4566
|
if (!r) return;
|
|
4567
4567
|
let i = r.getBoundingClientRect();
|
|
4568
|
-
Se.current =
|
|
4568
|
+
Se.current = ve.current - i.top, Ce.current = i.left, we.current = i.height;
|
|
4569
4569
|
let a = r.cloneNode(!0);
|
|
4570
4570
|
a.removeAttribute("data-index"), a.setAttribute("data-drag-clone", "true"), a.setAttribute("aria-hidden", "true"), a.classList.add($.virtualListDragClone), Object.assign(a.style, {
|
|
4571
4571
|
position: "fixed",
|
|
@@ -4580,60 +4580,60 @@ function Vr({ items: e, renderRow: t, columns: n, height: r = "100%", estimatedR
|
|
|
4580
4580
|
background: "var(--background)",
|
|
4581
4581
|
boxShadow: "var(--card-shadow)",
|
|
4582
4582
|
borderRadius: "var(--default-border-radius)"
|
|
4583
|
-
}), t.appendChild(a), xe.current = a,
|
|
4583
|
+
}), t.appendChild(a), xe.current = a, Y();
|
|
4584
4584
|
}
|
|
4585
|
-
a(() =>
|
|
4586
|
-
let
|
|
4587
|
-
let r = e[n], i =
|
|
4588
|
-
return /* @__PURE__ */
|
|
4585
|
+
a(() => X, [X]);
|
|
4586
|
+
let st = T && e.length > 0 && e.every((e, t) => W.has(Xe(e, t))), ct = T && !st && e.some((e, t) => W.has(Xe(e, t))), lt = (n) => {
|
|
4587
|
+
let r = e[n], i = Xe(r, n), a = g != null && i === g || W.has(i);
|
|
4588
|
+
return /* @__PURE__ */ F(Br, {
|
|
4589
4589
|
index: n,
|
|
4590
|
-
top:
|
|
4591
|
-
columnTemplate:
|
|
4590
|
+
top: q[n],
|
|
4591
|
+
columnTemplate: Ke,
|
|
4592
4592
|
isSelected: a,
|
|
4593
4593
|
showDivider: ne,
|
|
4594
4594
|
onClick: () => {
|
|
4595
|
-
if (
|
|
4596
|
-
|
|
4595
|
+
if (H.current) {
|
|
4596
|
+
H.current = !1;
|
|
4597
4597
|
return;
|
|
4598
4598
|
}
|
|
4599
4599
|
v?.(r, n);
|
|
4600
4600
|
},
|
|
4601
|
-
observer:
|
|
4602
|
-
ariaRowIndex:
|
|
4603
|
-
ariaPosInSet:
|
|
4604
|
-
ariaSetSize:
|
|
4605
|
-
rowRole:
|
|
4601
|
+
observer: Re,
|
|
4602
|
+
ariaRowIndex: We ? n + 2 : void 0,
|
|
4603
|
+
ariaPosInSet: We ? void 0 : n + 1,
|
|
4604
|
+
ariaSetSize: We ? void 0 : e.length,
|
|
4605
|
+
rowRole: We ? "row" : "listitem",
|
|
4606
4606
|
reorderable: O,
|
|
4607
|
-
reserveToggleGutter:
|
|
4607
|
+
reserveToggleGutter: Je,
|
|
4608
4608
|
draggable: O && !Te || void 0,
|
|
4609
4609
|
isDragging: O && i === he,
|
|
4610
|
-
onDragStart: O ? () =>
|
|
4611
|
-
onDragOver: O ? (e) =>
|
|
4612
|
-
onDragEnd: O ?
|
|
4613
|
-
onTouchStart: O ? (e) =>
|
|
4610
|
+
onDragStart: O ? () => et(i) : void 0,
|
|
4611
|
+
onDragOver: O ? (e) => tt(n, e) : void 0,
|
|
4612
|
+
onDragEnd: O ? nt : void 0,
|
|
4613
|
+
onTouchStart: O ? (e) => at(i, e) : void 0,
|
|
4614
4614
|
rowClassName: M?.row,
|
|
4615
4615
|
rowStyle: N?.row,
|
|
4616
|
-
children:
|
|
4616
|
+
children: We ? /* @__PURE__ */ I(ce, { children: [T && /* @__PURE__ */ F("div", {
|
|
4617
4617
|
className: f($.virtualListSelectCell, M?.selectCell),
|
|
4618
4618
|
style: N?.selectCell,
|
|
4619
4619
|
role: "gridcell",
|
|
4620
4620
|
onClick: (e) => e.stopPropagation(),
|
|
4621
|
-
children: /* @__PURE__ */
|
|
4621
|
+
children: /* @__PURE__ */ F(qe, {
|
|
4622
4622
|
selected: W.has(i),
|
|
4623
|
-
onToggle: () =>
|
|
4623
|
+
onToggle: () => Qe(i),
|
|
4624
4624
|
"aria-label": "Select row"
|
|
4625
4625
|
})
|
|
4626
|
-
}),
|
|
4626
|
+
}), Ge.map((e) => /* @__PURE__ */ F("div", {
|
|
4627
4627
|
className: f($.virtualListCell, M?.cell),
|
|
4628
4628
|
style: N?.cell,
|
|
4629
4629
|
role: "gridcell",
|
|
4630
4630
|
children: e.renderCell(r, n)
|
|
4631
4631
|
}, e.key))] }) : t?.(r, n)
|
|
4632
4632
|
}, i);
|
|
4633
|
-
},
|
|
4634
|
-
for (let e =
|
|
4635
|
-
let
|
|
4636
|
-
return
|
|
4633
|
+
}, ut = [];
|
|
4634
|
+
for (let e = He; e <= Ue; e++) ut.push(lt(e));
|
|
4635
|
+
let dt = he == null ? -1 : Be.indexOf(he);
|
|
4636
|
+
return dt >= 0 && (dt < He || dt > Ue) && ut.push(lt(dt)), /* @__PURE__ */ I("div", {
|
|
4637
4637
|
...re,
|
|
4638
4638
|
ref: Ne,
|
|
4639
4639
|
className: f($.virtualList, he != null && $.virtualListReordering, A, M?.root),
|
|
@@ -4642,58 +4642,58 @@ function Vr({ items: e, renderRow: t, columns: n, height: r = "100%", estimatedR
|
|
|
4642
4642
|
...j,
|
|
4643
4643
|
...N?.root
|
|
4644
4644
|
},
|
|
4645
|
-
onScroll:
|
|
4646
|
-
role:
|
|
4647
|
-
"aria-rowcount":
|
|
4645
|
+
onScroll: ze,
|
|
4646
|
+
role: We ? "grid" : "list",
|
|
4647
|
+
"aria-rowcount": We ? e.length + 1 : void 0,
|
|
4648
4648
|
children: [
|
|
4649
|
-
|
|
4649
|
+
We && /* @__PURE__ */ I("div", {
|
|
4650
4650
|
ref: Pe,
|
|
4651
4651
|
className: f($.virtualListHeader, M?.header),
|
|
4652
4652
|
style: {
|
|
4653
|
-
gridTemplateColumns:
|
|
4654
|
-
...
|
|
4653
|
+
gridTemplateColumns: Ke,
|
|
4654
|
+
...Je ? { paddingRight: 32 } : {},
|
|
4655
4655
|
...N?.header
|
|
4656
4656
|
},
|
|
4657
4657
|
role: "row",
|
|
4658
4658
|
"aria-rowindex": 1,
|
|
4659
4659
|
children: [
|
|
4660
|
-
T && /* @__PURE__ */
|
|
4660
|
+
T && /* @__PURE__ */ F("div", {
|
|
4661
4661
|
className: f($.virtualListSelectCell, M?.selectCell),
|
|
4662
4662
|
style: N?.selectCell,
|
|
4663
4663
|
role: "columnheader",
|
|
4664
|
-
children: /* @__PURE__ */
|
|
4665
|
-
selected:
|
|
4666
|
-
onToggle:
|
|
4664
|
+
children: /* @__PURE__ */ F(qe, {
|
|
4665
|
+
selected: st || ct,
|
|
4666
|
+
onToggle: $e,
|
|
4667
4667
|
"aria-label": "Select all rows"
|
|
4668
4668
|
})
|
|
4669
4669
|
}),
|
|
4670
|
-
|
|
4670
|
+
Ge.map((e) => /* @__PURE__ */ F("div", {
|
|
4671
4671
|
className: f($.virtualListHeaderCell, M?.headerCell),
|
|
4672
4672
|
style: N?.headerCell,
|
|
4673
4673
|
role: "columnheader",
|
|
4674
4674
|
children: e.label
|
|
4675
4675
|
}, e.key)),
|
|
4676
|
-
|
|
4676
|
+
Je && /* @__PURE__ */ I("div", {
|
|
4677
4677
|
ref: G,
|
|
4678
4678
|
className: $.virtualListToggleWrapper,
|
|
4679
|
-
children: [/* @__PURE__ */
|
|
4679
|
+
children: [/* @__PURE__ */ F("button", {
|
|
4680
4680
|
type: "button",
|
|
4681
4681
|
className: f($.virtualListHeaderToggle, M?.headerToggle),
|
|
4682
4682
|
style: N?.headerToggle,
|
|
4683
4683
|
onClick: () => de((e) => !e),
|
|
4684
4684
|
"aria-label": "Toggle column visibility",
|
|
4685
|
-
children: /* @__PURE__ */
|
|
4685
|
+
children: /* @__PURE__ */ F(p, {
|
|
4686
4686
|
icon: D,
|
|
4687
4687
|
style: N?.headerToggle
|
|
4688
4688
|
})
|
|
4689
|
-
}), ue && /* @__PURE__ */
|
|
4689
|
+
}), ue && /* @__PURE__ */ F("div", {
|
|
4690
4690
|
className: f($.virtualListTogglePopover, M?.togglePopover),
|
|
4691
4691
|
style: N?.togglePopover,
|
|
4692
|
-
children: n.map((e) => /* @__PURE__ */
|
|
4692
|
+
children: n.map((e) => /* @__PURE__ */ F(qe, {
|
|
4693
4693
|
className: f($.virtualListToggleItem, M?.toggleItem),
|
|
4694
4694
|
style: N?.toggleItem,
|
|
4695
4695
|
selected: Me.has(e.key),
|
|
4696
|
-
onToggle: () =>
|
|
4696
|
+
onToggle: () => Ye(e.key),
|
|
4697
4697
|
cursorDefault: !1,
|
|
4698
4698
|
children: e.label
|
|
4699
4699
|
}, e.key))
|
|
@@ -4701,21 +4701,21 @@ function Vr({ items: e, renderRow: t, columns: n, height: r = "100%", estimatedR
|
|
|
4701
4701
|
})
|
|
4702
4702
|
]
|
|
4703
4703
|
}),
|
|
4704
|
-
w ? /* @__PURE__ */
|
|
4704
|
+
w ? /* @__PURE__ */ F("div", {
|
|
4705
4705
|
className: $.virtualListLoadingFull,
|
|
4706
|
-
children: /* @__PURE__ */
|
|
4707
|
-
}) : /* @__PURE__ */
|
|
4706
|
+
children: /* @__PURE__ */ F(Oe, { className: $.virtualListSpinner })
|
|
4707
|
+
}) : /* @__PURE__ */ F("div", {
|
|
4708
4708
|
className: f($.virtualListBody, M?.body),
|
|
4709
4709
|
style: {
|
|
4710
|
-
height:
|
|
4710
|
+
height: Ve,
|
|
4711
4711
|
...N?.body
|
|
4712
4712
|
},
|
|
4713
|
-
children:
|
|
4713
|
+
children: ut
|
|
4714
4714
|
}),
|
|
4715
|
-
fe && /* @__PURE__ */
|
|
4715
|
+
fe && /* @__PURE__ */ F("div", {
|
|
4716
4716
|
className: f($.virtualListLoadingIndicator, M?.loadingIndicator),
|
|
4717
4717
|
style: N?.loadingIndicator,
|
|
4718
|
-
children: /* @__PURE__ */
|
|
4718
|
+
children: /* @__PURE__ */ F(Oe, { className: $.virtualListSpinner })
|
|
4719
4719
|
})
|
|
4720
4720
|
]
|
|
4721
4721
|
});
|
|
@@ -4749,18 +4749,18 @@ function Wr({ currentStep: e = 0, stepCount: t = 0, renderStep: n = () => null,
|
|
|
4749
4749
|
...s?.root,
|
|
4750
4750
|
...i
|
|
4751
4751
|
};
|
|
4752
|
-
return /* @__PURE__ */
|
|
4752
|
+
return /* @__PURE__ */ F("div", {
|
|
4753
4753
|
...c,
|
|
4754
4754
|
className: f(Ur.wizard, o?.root, r),
|
|
4755
4755
|
style: b,
|
|
4756
|
-
children: /* @__PURE__ */
|
|
4756
|
+
children: /* @__PURE__ */ F("div", {
|
|
4757
4757
|
className: f(Ur.wizardContentContainer, o?.container),
|
|
4758
4758
|
style: {
|
|
4759
4759
|
width: `${t * 100}%`,
|
|
4760
4760
|
marginLeft: `-${e * 100}%`,
|
|
4761
4761
|
...s?.container
|
|
4762
4762
|
},
|
|
4763
|
-
children: Array.from({ length: t }, (r, i) => /* @__PURE__ */
|
|
4763
|
+
children: Array.from({ length: t }, (r, i) => /* @__PURE__ */ F("div", {
|
|
4764
4764
|
ref: (e) => {
|
|
4765
4765
|
v.current[i] = e;
|
|
4766
4766
|
},
|
|
@@ -4770,7 +4770,7 @@ function Wr({ currentStep: e = 0, stepCount: t = 0, renderStep: n = () => null,
|
|
|
4770
4770
|
marginLeft: `${100 / t * i}%`,
|
|
4771
4771
|
...s?.step
|
|
4772
4772
|
},
|
|
4773
|
-
children: /* @__PURE__ */
|
|
4773
|
+
children: /* @__PURE__ */ F("div", {
|
|
4774
4774
|
className: f({ [Ur.wizardContentOutOfFrame]: e !== i && !m }, o?.stepContent),
|
|
4775
4775
|
style: s?.stepContent,
|
|
4776
4776
|
inert: e === i ? void 0 : !0,
|
|
@@ -4887,7 +4887,7 @@ var Kr = class {
|
|
|
4887
4887
|
//#region package/services/formValidation/FormValidatorGroupForm.tsx
|
|
4888
4888
|
function qr(e) {
|
|
4889
4889
|
return function({ children: t, ...n }) {
|
|
4890
|
-
return /* @__PURE__ */
|
|
4890
|
+
return /* @__PURE__ */ F("form", {
|
|
4891
4891
|
onSubmit: e.submit,
|
|
4892
4892
|
noValidate: !0,
|
|
4893
4893
|
...n,
|
|
@@ -5185,7 +5185,7 @@ var si = { t: (e, t) => ({
|
|
|
5185
5185
|
}
|
|
5186
5186
|
renderTooltip() {
|
|
5187
5187
|
let { errorMessage: e, formValidator: t } = this.props, { isHovered: n, isFocused: r } = this.state;
|
|
5188
|
-
return /* @__PURE__ */
|
|
5188
|
+
return /* @__PURE__ */ F(nt, {
|
|
5189
5189
|
variant: "error",
|
|
5190
5190
|
message: t ? t.getCurrentErrorMessage() : e || "",
|
|
5191
5191
|
isVisible: this.hasError() && (r || n)
|
|
@@ -5221,6 +5221,6 @@ function di(e, { initialValues: t, onSubmit: n, onValidate: r, errorParser: i, o
|
|
|
5221
5221
|
return f.current = n, p.current = r, a(() => (n !== void 0 && (d.onSubmitCallback = (...e) => f.current?.(...e)), r !== void 0 && (d.onValidateCallback = (...e) => p.current?.(...e)), d.registerOnUpdateListener(s), () => d.removeOnUpdateListener(s)), []), d;
|
|
5222
5222
|
}
|
|
5223
5223
|
//#endregion
|
|
5224
|
-
export { we as Accordion,
|
|
5224
|
+
export { we as Accordion, H as AccordionStyleType, Fe as ActionButtons, ze as ActionIcon, Qe as Align, Be as BodyEnd, G as Button, ke as ButtonSize, W as ButtonStyleType, Ae as ButtonType, Ve as Card, Ge as CardActions, We as CardContent, He as CardHeader, Ue as CardMedia, qe as Checkbox, Ye as Chip, Xe as ChipContainer, pt as ColorPicker, gt as ConfirmModal, Wt as DatePicker, Ht as Dropdown, Kt as EmptyState, Zt as Fab, et as FloatingMenu, Xr as FormValidator, Yr as FormValidatorGroup, hn as IconLoading, tn as IconPicker, rn as IdleManager, Vt as InfiniteBlock, rt as Input, cn as InputDropdown, Y as InputType, K as InteractableDiv, fn as KanbanBoard, dn as KanbanColumn, ht as Modal, vn as NumberInput, bn as OptionPicker, wn as Overscroll, Dn as ProgressBar, Me as Ripple, er as RoomDrawer, nr as RoomViewer, ar as ScrollbarProvider, sr as SearchInput, Oe as SpinnerLoading, ur as Stepper, vr as TenorPicker, yr as Textarea, Sr as ThemeProvider, Pr as ToastProvider, nt as Tooltip, li as ValidatableComponent, ci as Validators, Hr as VirtualList, Wr as Wizard, br as defaultTheme, wt as getLocale, ri as hasEightPasswordChars, ai as hasOnePasswordDigit, ii as hasOnePasswordLetter, ti as isBic, Qr as isDate, ei as isEmail, $r as isISODate, Zr as isNumber, oi as isPassword, ni as isURL, xt as mapLocale, Ct as setLocale, Ar as showToast, ui as useFormValidator, di as useFormValidatorGroup, Cr as useTheme };
|
|
5225
5225
|
|
|
5226
5226
|
//# sourceMappingURL=index.mjs.map
|