@webority/ui-react 0.6.2 → 0.6.4
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/types/components/ActionIcon.d.ts +5 -1
- package/dist/types/components/AppAccordion.d.ts +1 -1
- package/dist/types/components/AppAutocomplete.d.ts +1 -1
- package/dist/types/components/AppAvatar.d.ts +1 -1
- package/dist/types/components/AppCallout.d.ts +1 -1
- package/dist/types/components/AppChip.d.ts +1 -1
- package/dist/types/components/AppChoiceCard.d.ts +1 -1
- package/dist/types/components/AppChoiceChip.d.ts +10 -24
- package/dist/types/components/AppColorField.d.ts +1 -1
- package/dist/types/components/AppCompareTable.d.ts +1 -1
- package/dist/types/components/AppConfirmDialog.d.ts +1 -1
- package/dist/types/components/AppDataTable.d.ts +1 -1
- package/dist/types/components/AppDatePicker.d.ts +1 -1
- package/dist/types/components/AppDropdown.d.ts +2 -1
- package/dist/types/components/AppEmptyState.d.ts +1 -1
- package/dist/types/components/AppFileAttachment.d.ts +1 -1
- package/dist/types/components/AppFilePicker.d.ts +1 -1
- package/dist/types/components/AppInfoList.d.ts +1 -1
- package/dist/types/components/AppInfoTip.d.ts +2 -1
- package/dist/types/components/AppKpiTile.d.ts +1 -1
- package/dist/types/components/AppLogoPicker.d.ts +1 -1
- package/dist/types/components/AppModal.d.ts +1 -1
- package/dist/types/components/AppMultiSelect.d.ts +1 -1
- package/dist/types/components/AppPageHeader.d.ts +5 -20
- package/dist/types/components/AppPhoneNumberInput.d.ts +2 -1
- package/dist/types/components/AppPricingCard.d.ts +1 -1
- package/dist/types/components/AppRepeater.d.ts +1 -1
- package/dist/types/components/AppResourceCard.d.ts +1 -1
- package/dist/types/components/AppSegmented.d.ts +1 -1
- package/dist/types/components/AppSelect.d.ts +2 -1
- package/dist/types/components/AppSelectMini.d.ts +2 -1
- package/dist/types/components/AppShell.d.ts +1 -1
- package/dist/types/components/AppSidebarMenu.d.ts +2 -1
- package/dist/types/components/AppSkeleton.d.ts +1 -1
- package/dist/types/components/AppSpinner.d.ts +4 -15
- package/dist/types/components/AppSplash.d.ts +6 -23
- package/dist/types/components/AppStatusBadge.d.ts +4 -13
- package/dist/types/components/AppStepper.d.ts +1 -1
- package/dist/types/components/AppTableEmptyState.d.ts +1 -1
- package/dist/types/components/AppTablePagination.d.ts +1 -1
- package/dist/types/components/AppTabs.d.ts +1 -1
- package/dist/types/components/AppTimeline.d.ts +1 -1
- package/dist/types/components/Icon.d.ts +3 -1
- package/dist/types/components/warnUnknownProps.d.ts +13 -0
- package/dist/types/index.d.ts +1 -1
- package/dist/ui-react.js +557 -497
- package/package.json +3 -3
package/dist/ui-react.js
CHANGED
|
@@ -11,8 +11,24 @@ import g from "react-bootstrap/Dropdown";
|
|
|
11
11
|
import { toast as _ } from "react-toastify";
|
|
12
12
|
import v from "react-bootstrap/Offcanvas";
|
|
13
13
|
import y from "react-bootstrap/Nav";
|
|
14
|
+
//#region src/components/warnUnknownProps.js
|
|
15
|
+
var b = /* @__PURE__ */ new Set(/* @__PURE__ */ "id.title.role.style.className.class.tabIndex.lang.dir.hidden.slot.part.draggable.spellCheck.translate.inert.popover.name.type.value.defaultValue.checked.defaultChecked.placeholder.disabled.readOnly.required.autoFocus.autoComplete.form.formAction.formMethod.formNoValidate.formTarget.min.max.step.minLength.maxLength.pattern.multiple.accept.capture.rows.cols.wrap.list.htmlFor.inputMode.enterKeyHint.href.target.rel.download.ping.referrerPolicy.src.srcSet.alt.width.height.loading.decoding.sizes.crossOrigin.useMap.colSpan.rowSpan.headers.scope.span.key.ref.children.dangerouslySetInnerHTML.suppressHydrationWarning".split(".")), x = () => {
|
|
16
|
+
try {
|
|
17
|
+
return process.env.NODE_ENV !== "production";
|
|
18
|
+
} catch {
|
|
19
|
+
return !0;
|
|
20
|
+
}
|
|
21
|
+
}, S = (e) => e.startsWith("data-") || e.startsWith("aria-") || /^on[A-Z]/.test(e), C = /* @__PURE__ */ new Set();
|
|
22
|
+
function w(e, t) {
|
|
23
|
+
if (!(!x() || !t)) for (let n of Object.keys(t)) {
|
|
24
|
+
if (S(n) || b.has(n)) continue;
|
|
25
|
+
let t = `${e}.${n}`;
|
|
26
|
+
C.has(t) || (C.add(t), console.warn(`[@webority/ui-react] <${e}> received an unknown prop "${n}". It is not part of the component's API and is not a valid HTML attribute, so it will either be dropped or land on the DOM — check the prop name against the component catalogue at https://ui.webority.dev.`));
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
//#endregion
|
|
14
30
|
//#region src/components/Icon.jsx
|
|
15
|
-
var
|
|
31
|
+
var T = {
|
|
16
32
|
activity: "activity",
|
|
17
33
|
"alert-circle": "exclamation-circle",
|
|
18
34
|
"alert-triangle": "exclamation-triangle",
|
|
@@ -106,9 +122,9 @@ var b = {
|
|
|
106
122
|
"wand-sparkles": "magic",
|
|
107
123
|
x: "x-lg",
|
|
108
124
|
zap: "lightning-charge"
|
|
109
|
-
};
|
|
110
|
-
function
|
|
111
|
-
if (e === "hard-hat") return /* @__PURE__ */ t("svg", {
|
|
125
|
+
}, E = [...Object.keys(T), "hard-hat"].sort();
|
|
126
|
+
function D({ name: e, size: r = 16, className: i, color: a, style: o, ...s }) {
|
|
127
|
+
if (w("Icon", s), e === "hard-hat") return /* @__PURE__ */ t("svg", {
|
|
112
128
|
width: r,
|
|
113
129
|
height: r,
|
|
114
130
|
viewBox: "0 0 24 24",
|
|
@@ -130,9 +146,9 @@ function x({ name: e, size: r = 16, className: i, color: a, style: o }) {
|
|
|
130
146
|
}), /* @__PURE__ */ t("path", { d: "M3.2 22.5C3.2 17.4 7.5 14.9 11 14.7L12 17.4l1-2.7C16.5 14.9 20.8 17.4 20.8 22.5z" })]
|
|
131
147
|
})
|
|
132
148
|
});
|
|
133
|
-
let
|
|
134
|
-
return
|
|
135
|
-
className: `bi bi-${
|
|
149
|
+
let c = T[e] || e;
|
|
150
|
+
return c ? /* @__PURE__ */ t("i", {
|
|
151
|
+
className: `bi bi-${c}${i ? ` ${i}` : ""}`,
|
|
136
152
|
"data-icon": e,
|
|
137
153
|
"aria-hidden": "true",
|
|
138
154
|
style: {
|
|
@@ -145,20 +161,24 @@ function x({ name: e, size: r = 16, className: i, color: a, style: o }) {
|
|
|
145
161
|
}
|
|
146
162
|
//#endregion
|
|
147
163
|
//#region src/components/ActionIcon.jsx
|
|
148
|
-
function
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
164
|
+
function O({ icon: e, label: n, danger: r = !1, disabled: i = !1, size: a = 20, onClick: o, className: s = "", as: c, href: l, ...u }) {
|
|
165
|
+
w("ActionIcon", u);
|
|
166
|
+
let d = [
|
|
167
|
+
"u-action",
|
|
168
|
+
r ? "danger" : "",
|
|
169
|
+
s
|
|
170
|
+
].filter(Boolean).join(" "), f = c ?? (l ? "a" : "button"), p = f === "button";
|
|
171
|
+
return /* @__PURE__ */ t(f, {
|
|
172
|
+
type: p ? "button" : void 0,
|
|
173
|
+
href: p || i ? void 0 : l,
|
|
174
|
+
className: d,
|
|
156
175
|
"aria-label": n,
|
|
157
176
|
title: n,
|
|
158
|
-
disabled: i,
|
|
177
|
+
disabled: p ? i : void 0,
|
|
178
|
+
"aria-disabled": !p && i ? "true" : void 0,
|
|
159
179
|
onClick: o,
|
|
160
|
-
...
|
|
161
|
-
children: /* @__PURE__ */ t(
|
|
180
|
+
...u,
|
|
181
|
+
children: /* @__PURE__ */ t(D, {
|
|
162
182
|
name: e,
|
|
163
183
|
size: a
|
|
164
184
|
})
|
|
@@ -166,12 +186,13 @@ function S({ icon: e, label: n, danger: r = !1, disabled: i = !1, size: a = 20,
|
|
|
166
186
|
}
|
|
167
187
|
//#endregion
|
|
168
188
|
//#region src/components/AppAccordion.jsx
|
|
169
|
-
function
|
|
170
|
-
|
|
189
|
+
function k({ items: e = [], multiple: r = !1, id: i, className: o = "", ...s }) {
|
|
190
|
+
w("AppAccordion", s);
|
|
191
|
+
let l = a(), u = i || l, [d, f] = c(() => {
|
|
171
192
|
let t = e.filter((e) => e.open).map((e, t) => e.key ?? String(t));
|
|
172
193
|
return new Set(r ? t : t.slice(0, 1));
|
|
173
|
-
}),
|
|
174
|
-
|
|
194
|
+
}), p = (e, t) => e.key ?? String(t), m = (e) => {
|
|
195
|
+
f((t) => {
|
|
175
196
|
let n = new Set(r ? t : []);
|
|
176
197
|
return t.has(e) ? n.delete(e) : n.add(e), n;
|
|
177
198
|
});
|
|
@@ -179,7 +200,7 @@ function C({ items: e = [], multiple: r = !1, id: i, className: o = "" }) {
|
|
|
179
200
|
return /* @__PURE__ */ t("div", {
|
|
180
201
|
className: `faq-list${o ? ` ${o}` : ""}`,
|
|
181
202
|
children: e.map((e, r) => {
|
|
182
|
-
let i =
|
|
203
|
+
let i = p(e, r), a = d.has(i), o = `${u}-${r}`, s = `${o}-q`;
|
|
183
204
|
return /* @__PURE__ */ n("div", {
|
|
184
205
|
className: `faq-item${a ? " open" : ""}`,
|
|
185
206
|
children: [/* @__PURE__ */ n("button", {
|
|
@@ -188,10 +209,10 @@ function C({ items: e = [], multiple: r = !1, id: i, className: o = "" }) {
|
|
|
188
209
|
id: s,
|
|
189
210
|
"aria-expanded": a,
|
|
190
211
|
"aria-controls": o,
|
|
191
|
-
onClick: () =>
|
|
212
|
+
onClick: () => m(i),
|
|
192
213
|
children: [e.title, /* @__PURE__ */ t("span", {
|
|
193
214
|
className: "faq-q-icon",
|
|
194
|
-
children: /* @__PURE__ */ t(
|
|
215
|
+
children: /* @__PURE__ */ t(D, {
|
|
195
216
|
name: "chevron-down",
|
|
196
217
|
size: 18
|
|
197
218
|
})
|
|
@@ -211,8 +232,8 @@ function C({ items: e = [], multiple: r = !1, id: i, className: o = "" }) {
|
|
|
211
232
|
}
|
|
212
233
|
//#endregion
|
|
213
234
|
//#region src/components/AppAlert.jsx
|
|
214
|
-
function
|
|
215
|
-
return /* @__PURE__ */ t(l, {
|
|
235
|
+
function A({ variant: e = "info", children: n, className: r = "", onClose: i, dismissible: a, role: o = "alert", ...s }) {
|
|
236
|
+
return w("AppAlert", s), /* @__PURE__ */ t(l, {
|
|
216
237
|
variant: e,
|
|
217
238
|
className: r || void 0,
|
|
218
239
|
onClose: i,
|
|
@@ -225,15 +246,15 @@ function w({ variant: e = "info", children: n, className: r = "", onClose: i, di
|
|
|
225
246
|
}
|
|
226
247
|
//#endregion
|
|
227
248
|
//#region ../elements/dist/ui-elements.js
|
|
228
|
-
var
|
|
249
|
+
var j = {
|
|
229
250
|
success: "<rect width=\"174\" height=\"174\" rx=\"87\" fill=\"var(--wui-success-5)\"/>\n<rect x=\"24\" y=\"24\" width=\"126\" height=\"126\" rx=\"63\" stroke=\"var(--wui-success-20)\" stroke-width=\"16\"/>\n<g clip-path=\"url(#wui_success_clip)\">\n<rect x=\"32\" y=\"32\" width=\"110\" height=\"110\" rx=\"55\" fill=\"var(--wui-success-active)\"/>\n<rect x=\"108.758\" y=\"67.5986\" width=\"75.5044\" height=\"49.155\" transform=\"rotate(45 108.758 67.5986)\" fill=\"var(--wui-success)\"/>\n<path d=\"M87.895 96.1046C89.7154 97.9249 89.7154 101.046 87.895 102.866L84.1243 106.637C82.3039 108.457 79.1833 108.457 77.3629 106.637L60.8496 89.9934C59.0293 88.173 59.0293 85.0524 60.8496 83.232L64.6204 79.4613C66.4408 77.6409 69.5614 77.6409 71.3817 79.4613L87.895 96.1046Z\" fill=\"white\"/>\n<path d=\"M102.324 67.3672C104.144 65.5469 107.265 65.5469 109.085 67.3672L112.856 71.138C114.676 72.9583 114.676 76.079 112.856 77.8993L84.2499 106.375C82.4296 108.195 79.3089 108.195 77.4886 106.375L73.7178 102.604C71.8975 100.784 71.8975 97.6633 73.7178 95.8429L102.324 67.3672Z\" fill=\"white\"/>\n</g>\n<defs><clipPath id=\"wui_success_clip\"><rect x=\"32\" y=\"32\" width=\"110\" height=\"110\" rx=\"55\" fill=\"white\"/></clipPath></defs>",
|
|
230
251
|
error: "<rect width=\"174\" height=\"174\" rx=\"87\" fill=\"var(--wui-danger-5)\"/>\n<rect x=\"24\" y=\"24\" width=\"126\" height=\"126\" rx=\"63\" stroke=\"var(--wui-danger-20)\" stroke-width=\"16\"/>\n<g clip-path=\"url(#wui_error_clip0)\">\n<rect x=\"32\" y=\"32\" width=\"110\" height=\"110\" rx=\"55\" fill=\"var(--wui-danger)\"/>\n<rect x=\"110.758\" y=\"62\" width=\"75.5044\" height=\"69.9535\" transform=\"rotate(45 110.758 62)\" fill=\"var(--wui-danger-active)\"/>\n<g clip-path=\"url(#wui_error_clip1)\">\n<path d=\"M95.9285 87.0037L112.943 69.9887C114.823 68.1087 114.823 65.0608 112.943 63.1838L110.675 60.9155C108.795 59.0349 105.747 59.0349 103.87 60.9155L86.8552 77.9298L69.8403 60.9119C67.9603 59.032 64.9124 59.032 63.0353 60.9119L60.7635 63.1802C58.8835 65.0608 58.8835 68.1087 60.7635 69.9858L77.7814 87.0037L60.767 104.018C58.8865 105.899 58.8865 108.947 60.767 110.824L63.0353 113.092C64.9153 114.972 67.9632 114.972 69.8403 113.092L86.8552 96.0769L103.87 113.092C105.75 114.972 108.798 114.972 110.675 113.092L112.943 110.824C114.823 108.943 114.823 105.895 112.943 104.018L95.9285 87.0037Z\" fill=\"white\"/>\n</g>\n</g>\n<defs><clipPath id=\"wui_error_clip0\"><rect x=\"32\" y=\"32\" width=\"110\" height=\"110\" rx=\"55\" fill=\"white\"/></clipPath><clipPath id=\"wui_error_clip1\"><rect width=\"55\" height=\"55\" fill=\"white\" transform=\"translate(59.3535 59.502)\"/></clipPath></defs>",
|
|
231
252
|
warning: "<rect width=\"174\" height=\"174\" rx=\"87\" fill=\"var(--wui-warning-5)\"/>\n<rect x=\"24\" y=\"24\" width=\"126\" height=\"126\" rx=\"63\" stroke=\"var(--wui-warning-20)\" stroke-width=\"16\"/>\n<g clip-path=\"url(#wui_warning_clip)\">\n<rect x=\"32\" y=\"32\" width=\"110\" height=\"110\" rx=\"55\" fill=\"var(--wui-warning)\"/>\n<path d=\"M93.7812 60.9731L156.173 123.365L113.082 166.456L60 113.5L97 109L93.7812 60.9731Z\" fill=\"var(--wui-warning-active)\"/>\n<path d=\"M116.145 101.611L96.0431 62.7255C94.8912 60.6967 93.0607 59.1479 90.8656 58.3543C88.6768 57.5543 86.2768 57.5607 84.0945 58.3671C83.0001 58.7767 81.9953 59.3655 81.125 60.1079C80.2545 60.8567 79.5122 61.7527 78.9425 62.7703L57.8933 101.554C56.1525 104.594 56.1717 108.331 57.9317 111.358C59.6981 114.392 62.9427 116.248 66.4435 116.242H107.563C111.051 116.248 114.283 114.398 116.049 111.39C116.952 109.854 117.4 108.133 117.4 106.418C117.4 104.76 116.984 103.102 116.145 101.611ZM87.0064 105.714C85.0672 105.714 83.4929 104.146 83.4929 102.207C83.4929 100.267 85.0672 98.6993 87.0064 98.6993C88.9392 98.6993 90.5136 100.267 90.5136 102.207C90.5136 104.146 88.9392 105.714 87.0064 105.714ZM90.9104 78.098L88.0432 95.3266C88.0049 95.8706 87.5504 96.2994 87.0064 96.2994C86.4561 96.2994 86.0016 95.8706 85.9633 95.3266L83.0961 78.098C83.0385 77.8101 83.0065 77.522 83.0065 77.2405C83.0065 76.3125 83.3137 75.4037 83.8833 74.6485C84.6321 73.6629 85.7713 73.0549 87.0064 72.9717C88.2352 73.0549 89.3744 73.6629 90.1232 74.6485C90.872 75.6341 91.16 76.8885 90.9104 78.098Z\" fill=\"white\"/>\n</g>\n<defs><clipPath id=\"wui_warning_clip\"><rect x=\"32\" y=\"32\" width=\"110\" height=\"110\" rx=\"55\" fill=\"white\"/></clipPath></defs>",
|
|
232
253
|
info: "<rect width=\"174\" height=\"174\" rx=\"87\" fill=\"var(--wui-info-5)\"/>\n<rect x=\"24\" y=\"24\" width=\"126\" height=\"126\" rx=\"63\" stroke=\"var(--wui-info-20)\" stroke-width=\"16\"/>\n<g clip-path=\"url(#wui_info_clip)\">\n<rect x=\"32\" y=\"32\" width=\"110\" height=\"110\" rx=\"55\" fill=\"var(--wui-info)\"/>\n<path d=\"M104.999 67.5L111.454 64L163.495 116.041L115.739 163.797L62.999 111L101.897 104.102L104.999 67.5Z\" fill=\"var(--wui-info-active)\"/>\n<path d=\"M87 121C105.778 121 121 105.778 121 87C121 68.2223 105.778 53 87 53C68.2223 53 53 68.2223 53 87C53 105.778 68.2223 121 87 121Z\" fill=\"white\"/>\n<path d=\"M87 75.542C89.3472 75.542 91.25 73.6392 91.25 71.292C91.25 68.9448 89.3472 67.042 87 67.042C84.6528 67.042 82.75 68.9448 82.75 71.292C82.75 73.6392 84.6528 75.542 87 75.542Z\" fill=\"var(--wui-info-active)\"/>\n<path d=\"M86.9992 106.992C86.0975 106.992 85.2327 106.634 84.5951 105.996C83.9574 105.359 83.5992 104.494 83.5992 103.592V86.592C82.6975 86.592 81.8327 86.2338 81.1951 85.5962C80.5574 84.9585 80.1992 84.0937 80.1992 83.192C80.1992 82.2903 80.5574 81.4255 81.1951 80.7878C81.8327 80.1502 82.6975 79.792 83.5992 79.792H86.9992C87.901 79.792 88.7658 80.1502 89.4034 80.7878C90.041 81.4255 90.3992 82.2903 90.3992 83.192V103.592C90.3992 104.494 90.041 105.359 89.4034 105.996C88.7658 106.634 87.901 106.992 86.9992 106.992Z\" fill=\"var(--wui-info-active)\"/>\n<path d=\"M90.3992 106.992H83.5992C82.6975 106.992 81.8327 106.634 81.1951 105.996C80.5574 105.358 80.1992 104.494 80.1992 103.592C80.1992 102.69 80.5574 101.825 81.1951 101.188C81.8327 100.55 82.6975 100.192 83.5992 100.192H90.3992C91.301 100.192 92.1658 100.55 92.8034 101.188C93.441 101.825 93.7992 102.69 93.7992 103.592C93.7992 104.494 93.441 105.358 92.8034 105.996C92.1658 106.634 91.301 106.992 90.3992 106.992Z\" fill=\"var(--wui-info-active)\"/>\n</g>\n<defs><clipPath id=\"wui_info_clip\"><rect x=\"32\" y=\"32\" width=\"110\" height=\"110\" rx=\"55\" fill=\"white\"/></clipPath></defs>",
|
|
233
254
|
delete: "<rect width=\"174\" height=\"174\" rx=\"87\" fill=\"var(--wui-danger-5)\"/>\n<rect x=\"24\" y=\"24\" width=\"126\" height=\"126\" rx=\"63\" stroke=\"var(--wui-danger-20)\" stroke-width=\"16\"/>\n<g clip-path=\"url(#wui_delete_clip0)\">\n<rect x=\"32\" y=\"32\" width=\"110\" height=\"110\" rx=\"55\" fill=\"var(--wui-danger)\"/>\n<path d=\"M114.529 67.5672L163.249 116.287L116.354 163.183L67.6336 114.463L100.999 81.0975L64.999 77.5L58.999 69.5L114.529 67.5672Z\" fill=\"var(--wui-danger-active)\"/>\n<path d=\"M103.5 79L100.5 105.5L76 113L69.5 83.5L103.5 79Z\" fill=\"var(--wui-danger)\"/>\n<g clip-path=\"url(#wui_delete_clip1)\">\n<path d=\"M113.652 66.9993C108.895 66.5266 104.139 66.1721 99.3522 65.9061V65.8766L98.7022 62.0357C98.259 59.3175 97.609 55.2402 90.6954 55.2402H82.9545C76.0704 55.2402 75.4204 59.1402 74.9477 62.0061L74.3272 65.788C71.5795 65.9652 68.8318 66.1425 66.084 66.4084L60.0568 66.9993C58.8159 67.1175 57.9295 68.2107 58.0477 69.4221C58.1659 70.6334 59.2295 71.5198 60.4704 71.4016L66.4977 70.8107C81.9795 69.2743 97.5795 69.8652 113.239 71.4311C113.327 71.4311 113.386 71.4311 113.475 71.4311C114.598 71.4311 115.573 70.5743 115.691 69.4221C115.779 68.2107 114.893 67.1175 113.652 66.9993Z\" fill=\"white\"/>\n<path d=\"M108.216 75.5971C107.507 74.8585 106.532 74.4448 105.527 74.4448H68.1816C67.177 74.4448 66.1725 74.8585 65.4929 75.5971C64.8134 76.3357 64.4293 77.3403 64.4884 78.3744L66.3202 108.688C66.6452 113.179 67.0588 118.793 77.3702 118.793H96.3384C106.65 118.793 107.063 113.208 107.388 108.688L109.22 78.4039C109.279 77.3403 108.895 76.3357 108.216 75.5971ZM91.7588 103.99H81.9202C80.7088 103.99 79.7043 102.986 79.7043 101.774C79.7043 100.563 80.7088 99.5585 81.9202 99.5585H91.7588C92.9702 99.5585 93.9747 100.563 93.9747 101.774C93.9747 102.986 92.9702 103.99 91.7588 103.99ZM94.2406 92.1721H79.4679C78.2566 92.1721 77.252 91.1676 77.252 89.9562C77.252 88.7448 78.2566 87.7403 79.4679 87.7403H94.2406C95.452 87.7403 96.4566 88.7448 96.4566 89.9562C96.4566 91.1676 95.452 92.1721 94.2406 92.1721Z\" fill=\"white\"/>\n</g>\n</g>\n<defs><clipPath id=\"wui_delete_clip0\"><rect x=\"32\" y=\"32\" width=\"110\" height=\"110\" rx=\"55\" fill=\"white\"/></clipPath><clipPath id=\"wui_delete_clip1\"><rect width=\"65\" height=\"65\" fill=\"white\" transform=\"translate(54.3535 54.502)\"/></clipPath></defs>"
|
|
234
255
|
};
|
|
235
|
-
Object.keys(
|
|
236
|
-
var
|
|
256
|
+
Object.keys(j);
|
|
257
|
+
var ee = class extends HTMLElement {
|
|
237
258
|
static get observedAttributes() {
|
|
238
259
|
return ["tone", "size"];
|
|
239
260
|
}
|
|
@@ -244,19 +265,19 @@ var E = class extends HTMLElement {
|
|
|
244
265
|
this.isConnected && this.render();
|
|
245
266
|
}
|
|
246
267
|
render() {
|
|
247
|
-
let e = this.getAttribute("tone"), t = this.getAttribute("size") || "72", n =
|
|
268
|
+
let e = this.getAttribute("tone"), t = this.getAttribute("size") || "72", n = j[e] || j.info;
|
|
248
269
|
this.innerHTML = `<svg width="${t}" height="${t}" viewBox="0 0 174 174" fill="none" xmlns="http://www.w3.org/2000/svg" aria-hidden="true">${n}</svg>`;
|
|
249
270
|
}
|
|
250
|
-
},
|
|
251
|
-
function
|
|
252
|
-
let n = e.getAttribute("name"), r = e.querySelector(`:scope > input[${
|
|
271
|
+
}, te = "data-wui-mirror";
|
|
272
|
+
function M(e, t) {
|
|
273
|
+
let n = e.getAttribute("name"), r = e.querySelector(`:scope > input[${te}]`);
|
|
253
274
|
if (!n) {
|
|
254
275
|
r?.remove();
|
|
255
276
|
return;
|
|
256
277
|
}
|
|
257
|
-
r || (r = document.createElement("input"), r.type = "hidden", r.setAttribute(
|
|
278
|
+
r || (r = document.createElement("input"), r.type = "hidden", r.setAttribute(te, ""), e.appendChild(r)), r.name = n, r.value = t == null ? "" : String(t), r.disabled = e.hasAttribute("disabled");
|
|
258
279
|
}
|
|
259
|
-
var
|
|
280
|
+
var N = Symbol("wui.trustedHtml"), P = (e) => String(e ?? "").replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'"), F = (e) => e?.[N] ? String(e.label ?? "") : P(e == null ? "" : e.label), ne = class extends HTMLElement {
|
|
260
281
|
_accessibleName() {
|
|
261
282
|
return this.getAttribute("aria-label") || this.getAttribute("placeholder") || "Select";
|
|
262
283
|
}
|
|
@@ -284,9 +305,9 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
284
305
|
return this._value;
|
|
285
306
|
}
|
|
286
307
|
set value(e) {
|
|
287
|
-
this._value = e == null ? "" : String(e),
|
|
308
|
+
this._value = e == null ? "" : String(e), M(this, this._value);
|
|
288
309
|
let t = this._readOptions().find((e) => String(e.value) === this._value);
|
|
289
|
-
t && (this._label =
|
|
310
|
+
t && (this._label = L(t.label)), this._syncInput();
|
|
290
311
|
}
|
|
291
312
|
set options(e) {
|
|
292
313
|
this._optionsProp = Array.isArray(e) ? e : [], this._renderOptions();
|
|
@@ -316,7 +337,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
316
337
|
e.length && (this._declared = e.map((e) => ({
|
|
317
338
|
value: e.getAttribute("value") ?? e.textContent.trim(),
|
|
318
339
|
label: e.innerHTML,
|
|
319
|
-
[
|
|
340
|
+
[N]: !0,
|
|
320
341
|
selected: e.hasAttribute("selected")
|
|
321
342
|
})));
|
|
322
343
|
}
|
|
@@ -328,8 +349,8 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
328
349
|
let e = this.getAttribute("placeholder") || "Search…";
|
|
329
350
|
this.innerHTML = `
|
|
330
351
|
<div class="search-select">
|
|
331
|
-
<div class="input search-select-control search-select-ac" role="combobox" aria-haspopup="listbox" aria-expanded="false" aria-label="${
|
|
332
|
-
<input class="search-select-input search-select-ac-input" placeholder="${
|
|
352
|
+
<div class="input search-select-control search-select-ac" role="combobox" aria-haspopup="listbox" aria-expanded="false" aria-label="${I(this._accessibleName())}">
|
|
353
|
+
<input class="search-select-input search-select-ac-input" placeholder="${I(e)}" aria-autocomplete="list" autocomplete="off"${this.hasAttribute("disabled") ? " disabled" : ""} />
|
|
333
354
|
<span class="search-select-spinner spinner-border spinner-border-sm" role="status" aria-hidden="true" hidden></span>
|
|
334
355
|
<button type="button" class="search-select-clear" aria-label="Clear" hidden><i class="bi bi-x" aria-hidden="true"></i></button>
|
|
335
356
|
</div>
|
|
@@ -338,7 +359,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
338
359
|
<div class="search-select-empty" hidden>No matches</div>
|
|
339
360
|
<div class="search-select-hint" hidden>Type to search…</div>
|
|
340
361
|
</div>
|
|
341
|
-
</div>`, this._rendered = !0,
|
|
362
|
+
</div>`, this._rendered = !0, M(this, this._value), this._wire(), this._syncInput(), this._renderOptions();
|
|
342
363
|
}
|
|
343
364
|
_refs() {
|
|
344
365
|
return {
|
|
@@ -367,9 +388,9 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
367
388
|
let t = this._refs();
|
|
368
389
|
if (!t.optionsWrap) return;
|
|
369
390
|
let n = (e ?? (t.input ? t.input.value : "")).trim().toLowerCase(), r = this._readOptions();
|
|
370
|
-
!this._remote && n && (r = r.filter((e) =>
|
|
391
|
+
!this._remote && n && (r = r.filter((e) => L(e.label).toLowerCase().includes(n))), t.optionsWrap.innerHTML = r.map((e) => {
|
|
371
392
|
let t = String(e.value) === String(this._value);
|
|
372
|
-
return `<button type="button" role="option" class="search-select-option${t ? " selected" : ""}" data-value="${
|
|
393
|
+
return `<button type="button" role="option" class="search-select-option${t ? " selected" : ""}" data-value="${I(e.value)}" aria-selected="${t}">${F(e)}</button>`;
|
|
373
394
|
}).join(""), this._active = -1;
|
|
374
395
|
let i = n.length < this._minChars;
|
|
375
396
|
t.hint && (t.hint.hidden = !(this._remote && i && !r.length)), t.empty && (t.empty.hidden = this._loading || r.length > 0 || this._remote && i);
|
|
@@ -390,7 +411,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
390
411
|
}, o = () => {
|
|
391
412
|
e.menu.hidden = !0, e.control.setAttribute("aria-expanded", "false"), e.control.classList.remove("open"), r(-1), this._syncInput();
|
|
392
413
|
}, s = (t) => {
|
|
393
|
-
this._value = t.dataset.value, this._label =
|
|
414
|
+
this._value = t.dataset.value, this._label = L(t.innerHTML), M(this, this._value), e.input.value = this._label, this.dispatchEvent(new Event("change", { bubbles: !0 })), o(), e.input.focus();
|
|
394
415
|
};
|
|
395
416
|
e.input.addEventListener("focus", () => a()), e.input.addEventListener("input", () => {
|
|
396
417
|
let t = e.input.value;
|
|
@@ -413,7 +434,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
413
434
|
let t = e.target.closest(".search-select-option");
|
|
414
435
|
t && r(this._optionEls().indexOf(t));
|
|
415
436
|
}), e.clear?.addEventListener("click", () => {
|
|
416
|
-
this._value = "", this._label = "",
|
|
437
|
+
this._value = "", this._label = "", M(this, ""), e.input.value = "", e.clear.hidden = !0, this._renderOptions(""), this.dispatchEvent(new Event("change", { bubbles: !0 })), e.input.focus();
|
|
417
438
|
}), this._onDocClick = (e) => {
|
|
418
439
|
i() && !this.contains(e.target) && o();
|
|
419
440
|
}, document.addEventListener("click", this._onDocClick), window.addEventListener("resize", () => {
|
|
@@ -423,7 +444,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
423
444
|
disconnectedCallback() {
|
|
424
445
|
this._onDocClick && document.removeEventListener("click", this._onDocClick), clearTimeout(this._timer);
|
|
425
446
|
}
|
|
426
|
-
},
|
|
447
|
+
}, I = (e) => String(e ?? "").replace(/"/g, """).replace(/</g, "<"), L = (e) => String(e ?? "").replace(/<[^>]*>/g, ""), re = [
|
|
427
448
|
"January",
|
|
428
449
|
"February",
|
|
429
450
|
"March",
|
|
@@ -436,7 +457,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
436
457
|
"October",
|
|
437
458
|
"November",
|
|
438
459
|
"December"
|
|
439
|
-
],
|
|
460
|
+
], ie = [
|
|
440
461
|
"Su",
|
|
441
462
|
"Mo",
|
|
442
463
|
"Tu",
|
|
@@ -444,17 +465,17 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
444
465
|
"Th",
|
|
445
466
|
"Fr",
|
|
446
467
|
"Sa"
|
|
447
|
-
],
|
|
468
|
+
], R = (e) => String(e).padStart(2, "0"), ae = (e, t, n) => `${e}-${R(t + 1)}-${R(n)}`, z = (e) => {
|
|
448
469
|
let t = /^(\d{4})-(\d{2})-(\d{2})$/.exec(e || "");
|
|
449
470
|
return t ? {
|
|
450
471
|
y: +t[1],
|
|
451
472
|
m: t[2] - 1,
|
|
452
473
|
d: +t[3]
|
|
453
474
|
} : null;
|
|
454
|
-
},
|
|
455
|
-
let t =
|
|
456
|
-
return t ? `${
|
|
457
|
-
},
|
|
475
|
+
}, oe = (e) => {
|
|
476
|
+
let t = z(e);
|
|
477
|
+
return t ? `${R(t.d)} ${re[t.m].slice(0, 3)} ${t.y}` : "";
|
|
478
|
+
}, se = class extends HTMLElement {
|
|
458
479
|
static get observedAttributes() {
|
|
459
480
|
return [
|
|
460
481
|
"value",
|
|
@@ -479,46 +500,46 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
479
500
|
return this._value;
|
|
480
501
|
}
|
|
481
502
|
set value(e) {
|
|
482
|
-
this._value = e || "",
|
|
503
|
+
this._value = e || "", M(this, this._value), this._syncTrigger(), this.dispatchEvent(new Event("change", { bubbles: !0 }));
|
|
483
504
|
}
|
|
484
505
|
render() {
|
|
485
506
|
this._value = this.getAttribute("value") || this._value;
|
|
486
|
-
let e = this.getAttribute("placeholder") || "Enter Date", t =
|
|
507
|
+
let e = this.getAttribute("placeholder") || "Enter Date", t = z(this._value);
|
|
487
508
|
t && (this._viewY = t.y, this._viewM = t.m), this.innerHTML = `
|
|
488
509
|
<div class="datepicker">
|
|
489
510
|
<button type="button" class="input datepicker-trigger" aria-haspopup="dialog" aria-expanded="false"${this.hasAttribute("disabled") ? " disabled" : ""}>
|
|
490
|
-
<span data-trigger-label class="${t ? "" : "search-select-placeholder"}">${t ?
|
|
511
|
+
<span data-trigger-label class="${t ? "" : "search-select-placeholder"}">${t ? oe(this._value) : e}</span>
|
|
491
512
|
<i class="bi bi-calendar3" aria-hidden="true"></i>
|
|
492
513
|
</button>
|
|
493
514
|
<div class="datepicker-pop" role="dialog" hidden></div>
|
|
494
|
-
</div>`, this._rendered = !0,
|
|
515
|
+
</div>`, this._rendered = !0, M(this, this._value), this._wire();
|
|
495
516
|
}
|
|
496
517
|
_syncFormValue() {
|
|
497
|
-
|
|
518
|
+
M(this, this._value);
|
|
498
519
|
}
|
|
499
520
|
_syncTrigger() {
|
|
500
521
|
let e = this.querySelector("[data-trigger-label]");
|
|
501
522
|
if (!e) return;
|
|
502
|
-
let t =
|
|
503
|
-
e.textContent = t ?
|
|
523
|
+
let t = z(this._value);
|
|
524
|
+
e.textContent = t ? oe(this._value) : this.getAttribute("placeholder") || "Enter Date", e.classList.toggle("search-select-placeholder", !t);
|
|
504
525
|
}
|
|
505
526
|
_renderMonth() {
|
|
506
|
-
let e = this.querySelector(".datepicker-pop"), t = new Date(this._viewY, this._viewM, 1).getDay(), n = new Date(this._viewY, this._viewM + 1, 0).getDate(), r =
|
|
527
|
+
let e = this.querySelector(".datepicker-pop"), t = new Date(this._viewY, this._viewM, 1).getDay(), n = new Date(this._viewY, this._viewM + 1, 0).getDate(), r = z(this._value), i = z(this.getAttribute("min")), a = z(this.getAttribute("max")), o = (e, t, n) => {
|
|
507
528
|
let r = new Date(e, t, n).getTime();
|
|
508
529
|
return !!(i && r < new Date(i.y, i.m, i.d).getTime() || a && r > new Date(a.y, a.m, a.d).getTime());
|
|
509
530
|
}, s = "";
|
|
510
531
|
for (let e = 0; e < t; e++) s += "<span class=\"datepicker-day is-outside\"></span>";
|
|
511
532
|
for (let e = 1; e <= n; e++) {
|
|
512
|
-
let t =
|
|
533
|
+
let t = ae(this._viewY, this._viewM, e), n = r && r.y === this._viewY && r.m === this._viewM && r.d === e, i = o(this._viewY, this._viewM, e);
|
|
513
534
|
s += `<button type="button" class="datepicker-day${n ? " selected" : ""}" data-iso="${t}"${i ? " disabled" : ""}>${e}</button>`;
|
|
514
535
|
}
|
|
515
536
|
e.innerHTML = `
|
|
516
537
|
<div class="datepicker-head">
|
|
517
538
|
<button type="button" class="datepicker-nav-btn" data-nav="-1" aria-label="Previous month"><i class="bi bi-chevron-left" aria-hidden="true"></i></button>
|
|
518
|
-
<span class="datepicker-month">${
|
|
539
|
+
<span class="datepicker-month">${re[this._viewM]} ${this._viewY}</span>
|
|
519
540
|
<button type="button" class="datepicker-nav-btn" data-nav="1" aria-label="Next month"><i class="bi bi-chevron-right" aria-hidden="true"></i></button>
|
|
520
541
|
</div>
|
|
521
|
-
<div class="datepicker-weekdays">${
|
|
542
|
+
<div class="datepicker-weekdays">${ie.map((e) => `<span>${e}</span>`).join("")}</div>
|
|
522
543
|
<div class="datepicker-grid">${s}</div>
|
|
523
544
|
<div class="datepicker-foot"><button type="button" class="datepicker-link" data-clear>Clear</button></div>`;
|
|
524
545
|
}
|
|
@@ -551,7 +572,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
551
572
|
disconnectedCallback() {
|
|
552
573
|
this._onDocClick && document.removeEventListener("click", this._onDocClick), this._onDocKey && document.removeEventListener("keydown", this._onDocKey);
|
|
553
574
|
}
|
|
554
|
-
},
|
|
575
|
+
}, ce = class extends HTMLElement {
|
|
555
576
|
_accessibleName() {
|
|
556
577
|
return this.getAttribute("aria-label") || this.getAttribute("placeholder") || "Select";
|
|
557
578
|
}
|
|
@@ -583,7 +604,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
583
604
|
return this._values.slice();
|
|
584
605
|
}
|
|
585
606
|
set values(e) {
|
|
586
|
-
this._values = Array.isArray(e) ? e.map(String) : [],
|
|
607
|
+
this._values = Array.isArray(e) ? e.map(String) : [], M(this, this._values.join(",")), this._rendered && this._renderControl();
|
|
587
608
|
}
|
|
588
609
|
set options(e) {
|
|
589
610
|
this._optionsProp = Array.isArray(e) ? e : null, this.isConnected && this.render();
|
|
@@ -597,7 +618,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
597
618
|
e.length && (this._declared = e.map((e) => ({
|
|
598
619
|
value: e.getAttribute("value") ?? e.textContent.trim(),
|
|
599
620
|
label: e.innerHTML,
|
|
600
|
-
[
|
|
621
|
+
[N]: !0,
|
|
601
622
|
selected: e.hasAttribute("selected")
|
|
602
623
|
})));
|
|
603
624
|
}
|
|
@@ -610,41 +631,41 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
610
631
|
}
|
|
611
632
|
_labelHtmlFor(e) {
|
|
612
633
|
let t = this._readOptions().find((t) => String(t.value) === String(e));
|
|
613
|
-
return t ?
|
|
634
|
+
return t ? F(t) : P(e);
|
|
614
635
|
}
|
|
615
636
|
render() {
|
|
616
637
|
this._snapshotDeclared();
|
|
617
638
|
let e = this.hasAttribute("searchable"), t = this.getAttribute("search-placeholder") || "Search…";
|
|
618
|
-
|
|
639
|
+
M(this, this._values.join(",")), this.innerHTML = `
|
|
619
640
|
<div class="search-select">
|
|
620
|
-
<div class="input search-select-control search-select-multi" role="combobox" aria-haspopup="listbox" aria-expanded="false" aria-label="${
|
|
641
|
+
<div class="input search-select-control search-select-multi" role="combobox" aria-haspopup="listbox" aria-expanded="false" aria-label="${B(this._accessibleName())}"${this.hasAttribute("disabled") ? " aria-disabled=\"true\"" : ""}>
|
|
621
642
|
<div class="ms-chips" data-chips></div>
|
|
622
643
|
<i class="bi bi-chevron-down search-select-caret" aria-hidden="true"></i>
|
|
623
644
|
</div>
|
|
624
645
|
<div class="search-select-menu search-select-menu-fixed" role="listbox" aria-multiselectable="true" tabindex="-1" hidden>
|
|
625
|
-
${e ? `<div class="search-select-search"><i class="bi bi-search" aria-hidden="true"></i><input class="search-select-input" placeholder="${
|
|
646
|
+
${e ? `<div class="search-select-search"><i class="bi bi-search" aria-hidden="true"></i><input class="search-select-input" placeholder="${B(t)}" aria-autocomplete="list" /><button type="button" class="search-select-clear" aria-label="Clear search" hidden><i class="bi bi-x" aria-hidden="true"></i></button></div>` : ""}
|
|
626
647
|
<div class="search-select-options"></div>
|
|
627
648
|
<div class="search-select-empty" hidden>No matches</div>
|
|
628
649
|
</div>
|
|
629
|
-
</div>`, this._rendered = !0,
|
|
650
|
+
</div>`, this._rendered = !0, M(this, this._values.join(",")), this._renderControl(), this._renderOptions(), this._wire();
|
|
630
651
|
}
|
|
631
652
|
_renderControl() {
|
|
632
653
|
let e = this.querySelector("[data-chips]");
|
|
633
654
|
if (!e) return;
|
|
634
655
|
let t = this.getAttribute("placeholder") || "Select…";
|
|
635
656
|
if (!this._values.length) {
|
|
636
|
-
e.innerHTML = `<span class="search-select-placeholder">${
|
|
657
|
+
e.innerHTML = `<span class="search-select-placeholder">${P(t)}</span>`;
|
|
637
658
|
return;
|
|
638
659
|
}
|
|
639
|
-
e.innerHTML = this._values.map((e) => `<span class="chip chip-sm"><span class="chip-label">${this._labelHtmlFor(e)}</span><button type="button" class="chip-remove" data-remove="${
|
|
660
|
+
e.innerHTML = this._values.map((e) => `<span class="chip chip-sm"><span class="chip-label">${this._labelHtmlFor(e)}</span><button type="button" class="chip-remove" data-remove="${B(e)}" aria-label="Remove"><i class="bi bi-x" aria-hidden="true"></i></button></span>`).join("");
|
|
640
661
|
}
|
|
641
662
|
_renderOptions(e) {
|
|
642
663
|
let t = this.querySelector(".search-select-options"), n = this.querySelector(".search-select-empty");
|
|
643
664
|
if (!t) return;
|
|
644
665
|
let r = (e || "").trim().toLowerCase(), i = this._readOptions();
|
|
645
|
-
r && (i = i.filter((e) =>
|
|
666
|
+
r && (i = i.filter((e) => le(e.label).toLowerCase().includes(r))), t.innerHTML = i.map((e) => {
|
|
646
667
|
let t = this._values.includes(String(e.value));
|
|
647
|
-
return `<button type="button" role="option" class="search-select-option${t ? " selected" : ""}" data-value="${
|
|
668
|
+
return `<button type="button" role="option" class="search-select-option${t ? " selected" : ""}" data-value="${B(e.value)}" aria-selected="${t}"><span class="ms-check"><i class="bi bi-check" aria-hidden="true"></i></span><span class="ms-opt-label">${F(e)}</span></button>`;
|
|
648
669
|
}).join(""), n && (n.hidden = i.length > 0), this._active = -1;
|
|
649
670
|
}
|
|
650
671
|
_wire() {
|
|
@@ -663,7 +684,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
663
684
|
}, f = () => {
|
|
664
685
|
t.hidden = !0, e.setAttribute("aria-expanded", "false"), e.classList.remove("open"), l(-1);
|
|
665
686
|
}, p = () => {
|
|
666
|
-
|
|
687
|
+
M(this, this._values.join(",")), this.dispatchEvent(new Event("change", { bubbles: !0 }));
|
|
667
688
|
}, m = (e) => {
|
|
668
689
|
let t = String(e);
|
|
669
690
|
this._values.includes(t) ? this._values = this._values.filter((e) => e !== t) : this._values = [...this._values, t], this._renderControl(), this._renderOptions(n ? n.value : ""), p();
|
|
@@ -707,7 +728,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
707
728
|
disconnectedCallback() {
|
|
708
729
|
this._onDocClick && document.removeEventListener("click", this._onDocClick);
|
|
709
730
|
}
|
|
710
|
-
},
|
|
731
|
+
}, B = (e) => String(e ?? "").replace(/"/g, """).replace(/</g, "<"), le = (e) => String(e ?? "").replace(/<[^>]*>/g, ""), ue = [
|
|
711
732
|
[
|
|
712
733
|
"AF",
|
|
713
734
|
"Afghanistan",
|
|
@@ -1933,11 +1954,11 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
1933
1954
|
"Zimbabwe",
|
|
1934
1955
|
"263"
|
|
1935
1956
|
]
|
|
1936
|
-
],
|
|
1957
|
+
], V = (e) => (ue.find((t) => t[0] === e) || [
|
|
1937
1958
|
"",
|
|
1938
1959
|
"",
|
|
1939
1960
|
""
|
|
1940
|
-
])[2],
|
|
1961
|
+
])[2], H = (e) => `wui-flag wui-flag-${String(e).toLowerCase()}`, de = class extends HTMLElement {
|
|
1941
1962
|
static get observedAttributes() {
|
|
1942
1963
|
return [
|
|
1943
1964
|
"value",
|
|
@@ -1956,33 +1977,33 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
1956
1977
|
this._rendered && (e === "country" && (this._country = n || "IN"), this.render());
|
|
1957
1978
|
}
|
|
1958
1979
|
get value() {
|
|
1959
|
-
return `+${
|
|
1980
|
+
return `+${V(this._country)}${this._national}`;
|
|
1960
1981
|
}
|
|
1961
1982
|
set value(e) {
|
|
1962
1983
|
this._national = String(e ?? "").replace(/[^0-9]/g, ""), this._commit();
|
|
1963
1984
|
}
|
|
1964
1985
|
_commit() {
|
|
1965
|
-
|
|
1986
|
+
M(this, this.value), this.dispatchEvent(new Event("change", { bubbles: !0 }));
|
|
1966
1987
|
}
|
|
1967
1988
|
render() {
|
|
1968
1989
|
let e = this.getAttribute("placeholder") || "Enter phone number";
|
|
1969
1990
|
this._country = this.getAttribute("country") || this._country;
|
|
1970
|
-
let t =
|
|
1991
|
+
let t = ue.map(([e, t, n]) => `<button type="button" role="option" class="country-dropdown-item${e === this._country ? " selected" : ""}" data-iso="${e}"><span class="${H(e)}" aria-hidden="true"></span><span class="country-name-text">${t}<span class="country-code-text">+${n}</span></span></button>`).join("");
|
|
1971
1992
|
this.innerHTML = `
|
|
1972
1993
|
<div class="phone-input-wrap">
|
|
1973
1994
|
<div class="phone-country-adornment">
|
|
1974
1995
|
<button type="button" class="country-toggle" aria-haspopup="listbox" aria-expanded="false"${this.hasAttribute("disabled") ? " disabled" : ""}>
|
|
1975
|
-
<span class="${
|
|
1996
|
+
<span class="${H(this._country)}" data-flag aria-hidden="true"></span>
|
|
1976
1997
|
<i class="bi bi-chevron-down phone-chevron" aria-hidden="true"></i>
|
|
1977
|
-
<span class="phone-dial" data-dial>+${
|
|
1998
|
+
<span class="phone-dial" data-dial>+${V(this._country)}</span>
|
|
1978
1999
|
</button>
|
|
1979
2000
|
<div class="country-dropdown-menu" role="listbox" hidden>
|
|
1980
2001
|
<div class="dropdown-search-wrapper"><span class="dropdown-search-icon"><i class="bi bi-search" aria-hidden="true"></i></span><input type="text" class="dropdown-search-input" placeholder="Search country or code" aria-label="Search countries" /></div>
|
|
1981
2002
|
<div class="country-list-scroll">${t}<div class="country-empty" hidden>No countries found</div></div>
|
|
1982
2003
|
</div>
|
|
1983
2004
|
</div>
|
|
1984
|
-
<input type="tel" class="input" placeholder="${
|
|
1985
|
-
</div>`, this._rendered = !0,
|
|
2005
|
+
<input type="tel" class="input" placeholder="${U(e)}" value="${U(this._national)}"${this.hasAttribute("disabled") ? " disabled" : ""} />
|
|
2006
|
+
</div>`, this._rendered = !0, M(this, this.value), this._wire();
|
|
1986
2007
|
}
|
|
1987
2008
|
_wire() {
|
|
1988
2009
|
let e = this.querySelector(".country-toggle"), t = this.querySelector(".country-dropdown-menu"), n = this.querySelector(".dropdown-search-input"), r = this.querySelector(".country-list-scroll"), i = this.querySelector(".country-empty"), a = this.querySelector("input[type=tel]"), o = this.querySelector("[data-flag]"), s = this.querySelector("[data-dial]");
|
|
@@ -2006,7 +2027,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
2006
2027
|
}
|
|
2007
2028
|
i && (i.hidden = n > 0);
|
|
2008
2029
|
}, p = (e) => {
|
|
2009
|
-
this._country = e, this.setAttribute("country", e), o && (o.className =
|
|
2030
|
+
this._country = e, this.setAttribute("country", e), o && (o.className = H(e)), s && (s.textContent = `+${V(e)}`);
|
|
2010
2031
|
for (let t of r.querySelectorAll(".country-dropdown-item")) t.classList.toggle("selected", t.dataset.iso === e);
|
|
2011
2032
|
d(), this._commit();
|
|
2012
2033
|
};
|
|
@@ -2017,12 +2038,12 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
2017
2038
|
this._national = a.value.replace(/[^0-9]/g, ""), this._commit();
|
|
2018
2039
|
}), this._onDocClick = (e) => {
|
|
2019
2040
|
c() && !this.contains(e.target) && d();
|
|
2020
|
-
}, document.addEventListener("click", this._onDocClick),
|
|
2041
|
+
}, document.addEventListener("click", this._onDocClick), M(this, this.value);
|
|
2021
2042
|
}
|
|
2022
2043
|
disconnectedCallback() {
|
|
2023
2044
|
this._reposition && (window.removeEventListener("scroll", this._reposition, !0), window.removeEventListener("resize", this._reposition)), this._onDocClick && document.removeEventListener("click", this._onDocClick);
|
|
2024
2045
|
}
|
|
2025
|
-
},
|
|
2046
|
+
}, U = (e) => String(e ?? "").replace(/"/g, """).replace(/</g, "<"), fe = class extends HTMLElement {
|
|
2026
2047
|
static get observedAttributes() {
|
|
2027
2048
|
return [
|
|
2028
2049
|
"value",
|
|
@@ -2050,7 +2071,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
2050
2071
|
return this._value;
|
|
2051
2072
|
}
|
|
2052
2073
|
set value(e) {
|
|
2053
|
-
this._value = e == null ? "" : String(e),
|
|
2074
|
+
this._value = e == null ? "" : String(e), M(this, this._value), this._syncSelected();
|
|
2054
2075
|
}
|
|
2055
2076
|
set options(e) {
|
|
2056
2077
|
this._optionsProp = Array.isArray(e) ? e : null, this.isConnected && this.render();
|
|
@@ -2064,7 +2085,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
2064
2085
|
e.length && (this._declared = e.map((e) => ({
|
|
2065
2086
|
value: e.getAttribute("value") ?? e.textContent.trim(),
|
|
2066
2087
|
label: e.innerHTML,
|
|
2067
|
-
[
|
|
2088
|
+
[N]: !0,
|
|
2068
2089
|
selected: e.hasAttribute("selected")
|
|
2069
2090
|
})));
|
|
2070
2091
|
}
|
|
@@ -2074,22 +2095,22 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
2074
2095
|
render() {
|
|
2075
2096
|
this._snapshotDeclared();
|
|
2076
2097
|
let e = this._readOptions(), t = this.hasAttribute("searchable"), n = this.getAttribute("placeholder") || "Select...", r = this.getAttribute("search-placeholder") || "Search...", i = e.find((e) => String(e.value) === String(this._value)) || e.find((e) => e.selected);
|
|
2077
|
-
i && (this._value = String(i.value)),
|
|
2098
|
+
i && (this._value = String(i.value)), M(this, this._value);
|
|
2078
2099
|
let a = e.map((e) => {
|
|
2079
2100
|
let t = String(e.value) === String(this._value);
|
|
2080
|
-
return `<button type="button" role="option" class="search-select-option${t ? " selected" : ""}" data-value="${
|
|
2101
|
+
return `<button type="button" role="option" class="search-select-option${t ? " selected" : ""}" data-value="${W(e.value)}" aria-selected="${t}">${F(e)}</button>`;
|
|
2081
2102
|
}).join("");
|
|
2082
2103
|
this.innerHTML = `
|
|
2083
2104
|
<div class="search-select${this.hasAttribute("compact") ? " search-select-compact" : ""}">
|
|
2084
|
-
<button type="button" role="combobox" class="input search-select-control" aria-haspopup="listbox" aria-expanded="false" aria-label="${
|
|
2085
|
-
<span class="${i ? "" : "search-select-placeholder"}" data-label>${i ?
|
|
2105
|
+
<button type="button" role="combobox" class="input search-select-control" aria-haspopup="listbox" aria-expanded="false" aria-label="${W(this._accessibleName())}"${this.hasAttribute("disabled") ? " disabled" : ""}>
|
|
2106
|
+
<span class="${i ? "" : "search-select-placeholder"}" data-label>${i ? F(i) : P(n)}</span>
|
|
2086
2107
|
<i class="bi bi-chevron-down search-select-caret" aria-hidden="true"></i>
|
|
2087
2108
|
</button>
|
|
2088
2109
|
<div class="search-select-menu search-select-menu-fixed" role="listbox" tabindex="-1" hidden>
|
|
2089
|
-
${t ? `<div class="search-select-search"><i class="bi bi-search" aria-hidden="true"></i><input class="search-select-input" placeholder="${
|
|
2110
|
+
${t ? `<div class="search-select-search"><i class="bi bi-search" aria-hidden="true"></i><input class="search-select-input" placeholder="${W(r)}" aria-autocomplete="list" /><button type="button" class="search-select-clear" aria-label="Clear search" hidden><i class="bi bi-x" aria-hidden="true"></i></button></div>` : ""}
|
|
2090
2111
|
<div class="search-select-options">${a}<div class="search-select-empty" hidden>No matches</div></div>
|
|
2091
2112
|
</div>
|
|
2092
|
-
</div>`, this._rendered = !0,
|
|
2113
|
+
</div>`, this._rendered = !0, M(this, this._value), this._wire();
|
|
2093
2114
|
}
|
|
2094
2115
|
_refs() {
|
|
2095
2116
|
return {
|
|
@@ -2114,7 +2135,7 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
2114
2135
|
let t = e.dataset.value === String(this._value);
|
|
2115
2136
|
e.classList.toggle("selected", t), e.setAttribute("aria-selected", String(t));
|
|
2116
2137
|
}
|
|
2117
|
-
e && (e.innerHTML = t ?
|
|
2138
|
+
e && (e.innerHTML = t ? F(t) : e.innerHTML, e.classList.toggle("search-select-placeholder", !t));
|
|
2118
2139
|
}
|
|
2119
2140
|
_wire() {
|
|
2120
2141
|
let e = this._refs();
|
|
@@ -2169,14 +2190,14 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
2169
2190
|
disconnectedCallback() {
|
|
2170
2191
|
this._onDocClick && document.removeEventListener("click", this._onDocClick);
|
|
2171
2192
|
}
|
|
2172
|
-
},
|
|
2193
|
+
}, W = (e) => String(e ?? "").replace(/"/g, """).replace(/</g, "<"), G = "image/png,image/jpeg,image/webp", pe = {
|
|
2173
2194
|
"image/png": [".png"],
|
|
2174
2195
|
"image/jpeg": [".jpg", ".jpeg"],
|
|
2175
2196
|
"image/webp": [".webp"],
|
|
2176
2197
|
"image/gif": [".gif"],
|
|
2177
2198
|
"image/svg+xml": [".svg"],
|
|
2178
2199
|
"application/pdf": [".pdf"]
|
|
2179
|
-
},
|
|
2200
|
+
}, me = {
|
|
2180
2201
|
"image/png": "PNG",
|
|
2181
2202
|
"image/jpeg": "JPG",
|
|
2182
2203
|
"image/webp": "WEBP",
|
|
@@ -2190,36 +2211,36 @@ var k = Symbol("wui.trustedHtml"), A = (e) => String(e ?? "").replace(/&/g, "&am
|
|
|
2190
2211
|
".gif": "GIF",
|
|
2191
2212
|
".svg": "SVG",
|
|
2192
2213
|
".pdf": "PDF"
|
|
2193
|
-
},
|
|
2194
|
-
function
|
|
2214
|
+
}, K = (e) => String(e || "").split(",").map((e) => e.trim().toLowerCase()).filter(Boolean);
|
|
2215
|
+
function he(e) {
|
|
2195
2216
|
let t = [];
|
|
2196
|
-
for (let n of
|
|
2197
|
-
let e =
|
|
2217
|
+
for (let n of K(e)) {
|
|
2218
|
+
let e = me[n] || (n.startsWith(".") ? n.slice(1).toUpperCase() : n.toUpperCase());
|
|
2198
2219
|
t.includes(e) || t.push(e);
|
|
2199
2220
|
}
|
|
2200
2221
|
return t.length <= 1 ? t[0] || "supported" : `${t.slice(0, -1).join(", ")} or ${t[t.length - 1]}`;
|
|
2201
2222
|
}
|
|
2202
|
-
function
|
|
2203
|
-
let n =
|
|
2223
|
+
function ge(e, t) {
|
|
2224
|
+
let n = K(t);
|
|
2204
2225
|
if (!n.length) return !0;
|
|
2205
2226
|
let r = (e.type || "").toLowerCase(), i = (e.name || "").toLowerCase();
|
|
2206
|
-
return n.some((e) => e.startsWith(".") ? i.endsWith(e) : e.endsWith("/*") ? r.startsWith(e.slice(0, -1)) : r && r === e ? !0 : !r && (
|
|
2227
|
+
return n.some((e) => e.startsWith(".") ? i.endsWith(e) : e.endsWith("/*") ? r.startsWith(e.slice(0, -1)) : r && r === e ? !0 : !r && (pe[e] || []).some((e) => i.endsWith(e)));
|
|
2207
2228
|
}
|
|
2208
|
-
function
|
|
2229
|
+
function q(e, t = {}) {
|
|
2209
2230
|
if (!e) return null;
|
|
2210
|
-
let n = t.accept === void 0 ?
|
|
2211
|
-
return
|
|
2231
|
+
let n = t.accept === void 0 ? G : t.accept, r = t.maxSizeMb || 5;
|
|
2232
|
+
return ge(e, n) ? e.size > r * 1024 * 1024 ? `Keep the file under ${r} MB.` : null : `Choose a ${he(n)} file.`;
|
|
2212
2233
|
}
|
|
2213
|
-
var
|
|
2234
|
+
var J = (e, t) => {
|
|
2214
2235
|
typeof customElements < "u" && !customElements.get(e) && customElements.define(e, t);
|
|
2215
2236
|
};
|
|
2216
|
-
function
|
|
2217
|
-
|
|
2237
|
+
function _e() {
|
|
2238
|
+
J("wui-select", fe), J("wui-phone", de), J("wui-datepicker", se), J("wui-autocomplete", ne), J("wui-multiselect", ce), J("wui-status-icon", ee);
|
|
2218
2239
|
}
|
|
2219
|
-
|
|
2240
|
+
_e();
|
|
2220
2241
|
//#endregion
|
|
2221
2242
|
//#region src/components/RequiredMark.jsx
|
|
2222
|
-
function
|
|
2243
|
+
function Y() {
|
|
2223
2244
|
return /* @__PURE__ */ t("span", {
|
|
2224
2245
|
className: "required",
|
|
2225
2246
|
"aria-hidden": "true",
|
|
@@ -2228,22 +2249,23 @@ function G() {
|
|
|
2228
2249
|
}
|
|
2229
2250
|
//#endregion
|
|
2230
2251
|
//#region src/components/AppAutocomplete.jsx
|
|
2231
|
-
function
|
|
2232
|
-
|
|
2252
|
+
function ve({ value: e, onChange: r, options: a, loadOptions: o, placeholder: c = "Search…", minChars: l, debounce: u, disabled: d = !1, name: f, label: p, error: m, hint: h, required: g = !1, fieldClassName: _ = "", ...v }) {
|
|
2253
|
+
w("AppAutocomplete", v);
|
|
2254
|
+
let y = s(null), b = typeof o == "function";
|
|
2233
2255
|
return i(() => {
|
|
2234
|
-
let e =
|
|
2235
|
-
e && !
|
|
2236
|
-
}, [a,
|
|
2237
|
-
let t =
|
|
2256
|
+
let e = y.current;
|
|
2257
|
+
e && !b && (e.options = a || []);
|
|
2258
|
+
}, [a, b]), i(() => {
|
|
2259
|
+
let t = y.current;
|
|
2238
2260
|
t && t.value !== (e ?? "") && (t.value = e ?? "");
|
|
2239
2261
|
}, [e]), i(() => {
|
|
2240
|
-
let e =
|
|
2262
|
+
let e = y.current;
|
|
2241
2263
|
if (!e) return;
|
|
2242
2264
|
let t = () => r?.(e.value);
|
|
2243
2265
|
return e.addEventListener("change", t), () => e.removeEventListener("change", t);
|
|
2244
2266
|
}, [r]), i(() => {
|
|
2245
|
-
let e =
|
|
2246
|
-
if (!e || !
|
|
2267
|
+
let e = y.current;
|
|
2268
|
+
if (!e || !b) return;
|
|
2247
2269
|
let t = !1, n = async (n) => {
|
|
2248
2270
|
e.loading = !0;
|
|
2249
2271
|
try {
|
|
@@ -2256,24 +2278,25 @@ function ge({ value: e, onChange: r, options: a, loadOptions: o, placeholder: c
|
|
|
2256
2278
|
return e.addEventListener("search", n), () => {
|
|
2257
2279
|
t = !0, e.removeEventListener("search", n);
|
|
2258
2280
|
};
|
|
2259
|
-
}, [
|
|
2281
|
+
}, [b, o]), /* @__PURE__ */ n("div", {
|
|
2260
2282
|
className: `field${_ ? ` ${_}` : ""}`,
|
|
2261
2283
|
children: [
|
|
2262
2284
|
p && /* @__PURE__ */ n("label", {
|
|
2263
2285
|
className: "label",
|
|
2264
2286
|
htmlFor: f,
|
|
2265
|
-
children: [p, g && /* @__PURE__ */ t(
|
|
2287
|
+
children: [p, g && /* @__PURE__ */ t(Y, {})]
|
|
2266
2288
|
}),
|
|
2267
2289
|
/* @__PURE__ */ t("wui-autocomplete", {
|
|
2268
2290
|
"aria-label": typeof p == "string" ? p : void 0,
|
|
2269
2291
|
id: f,
|
|
2270
|
-
ref:
|
|
2292
|
+
ref: y,
|
|
2271
2293
|
name: f,
|
|
2272
2294
|
placeholder: c,
|
|
2273
|
-
remote:
|
|
2295
|
+
remote: b ? "" : void 0,
|
|
2274
2296
|
"min-chars": l == null ? void 0 : String(l),
|
|
2275
2297
|
debounce: u == null ? void 0 : String(u),
|
|
2276
|
-
disabled: d ? "" : void 0
|
|
2298
|
+
disabled: d ? "" : void 0,
|
|
2299
|
+
required: g ? "" : void 0
|
|
2277
2300
|
}),
|
|
2278
2301
|
m ? /* @__PURE__ */ t("div", {
|
|
2279
2302
|
className: "field-error",
|
|
@@ -2287,32 +2310,33 @@ function ge({ value: e, onChange: r, options: a, loadOptions: o, placeholder: c
|
|
|
2287
2310
|
}
|
|
2288
2311
|
//#endregion
|
|
2289
2312
|
//#region src/components/AppAvatar.jsx
|
|
2290
|
-
function
|
|
2313
|
+
function ye(e) {
|
|
2291
2314
|
let t = (e || "").trim();
|
|
2292
2315
|
if (!t) return "?";
|
|
2293
2316
|
let n = t.split(/\s+/).filter(Boolean);
|
|
2294
2317
|
return n.length === 1 ? n[0].slice(0, 2).toUpperCase() : (n[0][0] + n[n.length - 1][0]).toUpperCase();
|
|
2295
2318
|
}
|
|
2296
|
-
function
|
|
2297
|
-
|
|
2319
|
+
function be({ name: e, src: n, className: r = "", ...i }) {
|
|
2320
|
+
w("AppAvatar", i);
|
|
2321
|
+
let a = ["avatar", r].filter(Boolean).join(" ");
|
|
2298
2322
|
return n ? /* @__PURE__ */ t("span", {
|
|
2299
|
-
className:
|
|
2323
|
+
className: a,
|
|
2300
2324
|
children: /* @__PURE__ */ t("img", {
|
|
2301
2325
|
className: "avatar-img",
|
|
2302
2326
|
src: n,
|
|
2303
2327
|
alt: e || "Profile photo"
|
|
2304
2328
|
})
|
|
2305
2329
|
}) : /* @__PURE__ */ t("span", {
|
|
2306
|
-
className:
|
|
2330
|
+
className: a,
|
|
2307
2331
|
role: "img",
|
|
2308
2332
|
"aria-label": e,
|
|
2309
|
-
children:
|
|
2333
|
+
children: ye(e)
|
|
2310
2334
|
});
|
|
2311
2335
|
}
|
|
2312
2336
|
//#endregion
|
|
2313
2337
|
//#region src/components/AppBadge.jsx
|
|
2314
|
-
function
|
|
2315
|
-
return /* @__PURE__ */ t(u, {
|
|
2338
|
+
function xe({ children: e, tone: n, dot: r = !1, className: i = "", ...a }) {
|
|
2339
|
+
return w("AppBadge", a), /* @__PURE__ */ t(u, {
|
|
2316
2340
|
bg: !1,
|
|
2317
2341
|
className: [
|
|
2318
2342
|
n ? `badge-${n}` : "",
|
|
@@ -2325,25 +2349,31 @@ function ye({ children: e, tone: n, dot: r = !1, className: i = "", ...a }) {
|
|
|
2325
2349
|
}
|
|
2326
2350
|
//#endregion
|
|
2327
2351
|
//#region src/components/AppButton.jsx
|
|
2328
|
-
var
|
|
2352
|
+
var Se = {
|
|
2329
2353
|
primary: "primary",
|
|
2330
2354
|
secondary: "secondary",
|
|
2331
2355
|
outline: "outline-primary",
|
|
2332
2356
|
ghost: "link",
|
|
2333
2357
|
danger: "danger"
|
|
2334
2358
|
};
|
|
2335
|
-
function
|
|
2336
|
-
|
|
2359
|
+
function Ce(e, n) {
|
|
2360
|
+
if (!e) return null;
|
|
2361
|
+
let r = n === "left" ? "me-2" : "ms-2";
|
|
2362
|
+
return typeof e == "string" ? /* @__PURE__ */ t(D, {
|
|
2337
2363
|
name: e,
|
|
2338
2364
|
size: 16,
|
|
2339
|
-
className:
|
|
2340
|
-
}) :
|
|
2365
|
+
className: r
|
|
2366
|
+
}) : /* @__PURE__ */ t("span", {
|
|
2367
|
+
className: `d-inline-flex ${r}`,
|
|
2368
|
+
children: e
|
|
2369
|
+
});
|
|
2341
2370
|
}
|
|
2342
|
-
function
|
|
2371
|
+
function X({ children: e, variant: r = "primary", size: i = "md", type: a = "button", loading: o = !1, disabled: s = !1, block: c = !1, leftIcon: l = null, rightIcon: u = null, className: f = "", ...p }) {
|
|
2372
|
+
w("AppButton", p);
|
|
2343
2373
|
let m = [c ? "w-100" : "", f].filter(Boolean).join(" ");
|
|
2344
2374
|
return /* @__PURE__ */ n(d, {
|
|
2345
|
-
type: a,
|
|
2346
|
-
variant:
|
|
2375
|
+
type: (p.as === void 0 || p.as === "button") && p.href === void 0 ? a : void 0,
|
|
2376
|
+
variant: Se[r] ?? "primary",
|
|
2347
2377
|
size: i === "md" ? void 0 : i,
|
|
2348
2378
|
disabled: s || o,
|
|
2349
2379
|
className: m || void 0,
|
|
@@ -2353,20 +2383,20 @@ function q({ children: e, variant: r = "primary", size: i = "md", type: a = "but
|
|
|
2353
2383
|
className: "spinner-border spinner-border-sm me-2",
|
|
2354
2384
|
"aria-hidden": "true"
|
|
2355
2385
|
}),
|
|
2356
|
-
!o &&
|
|
2386
|
+
!o && Ce(l, "left"),
|
|
2357
2387
|
e,
|
|
2358
|
-
!o &&
|
|
2388
|
+
!o && Ce(u, "right")
|
|
2359
2389
|
]
|
|
2360
2390
|
});
|
|
2361
2391
|
}
|
|
2362
2392
|
//#endregion
|
|
2363
2393
|
//#region src/components/AppCallout.jsx
|
|
2364
|
-
function
|
|
2365
|
-
return /* @__PURE__ */ n("div", {
|
|
2394
|
+
function we({ children: e, icon: r = "info", className: i = "", ...a }) {
|
|
2395
|
+
return w("AppCallout", a), /* @__PURE__ */ n("div", {
|
|
2366
2396
|
className: `info-callout${i ? ` ${i}` : ""}`,
|
|
2367
2397
|
children: [r && /* @__PURE__ */ t("span", {
|
|
2368
2398
|
className: "info-callout-icon",
|
|
2369
|
-
children: /* @__PURE__ */ t(
|
|
2399
|
+
children: /* @__PURE__ */ t(D, {
|
|
2370
2400
|
name: r,
|
|
2371
2401
|
size: 18
|
|
2372
2402
|
})
|
|
@@ -2375,7 +2405,8 @@ function xe({ children: e, icon: r = "info", className: i = "" }) {
|
|
|
2375
2405
|
}
|
|
2376
2406
|
//#endregion
|
|
2377
2407
|
//#region src/components/AppCard.jsx
|
|
2378
|
-
function
|
|
2408
|
+
function Te({ title: r, titleClassName: i = "", header: a, headerExtra: o, headerActions: s, children: c, className: l = "", bodyClassName: u = "", headerClassName: d = "", body: p = !0, lifted: m = !1, ...h }) {
|
|
2409
|
+
w("AppCard", h);
|
|
2379
2410
|
let g = a != null || r != null || o != null || s != null;
|
|
2380
2411
|
return /* @__PURE__ */ n(f, {
|
|
2381
2412
|
className: [m ? "card-lifted" : "", l].filter(Boolean).join(" ") || void 0,
|
|
@@ -2399,7 +2430,8 @@ function Se({ title: r, titleClassName: i = "", header: a, headerExtra: o, heade
|
|
|
2399
2430
|
}
|
|
2400
2431
|
//#endregion
|
|
2401
2432
|
//#region src/components/AppCheckbox.jsx
|
|
2402
|
-
var
|
|
2433
|
+
var Ee = r(function({ label: e, id: r, name: i, className: o = "", ...s }, c) {
|
|
2434
|
+
w("AppCheckbox", s);
|
|
2403
2435
|
let l = a(), u = r || i || l;
|
|
2404
2436
|
return /* @__PURE__ */ n("div", {
|
|
2405
2437
|
className: `form-check${o ? ` ${o}` : ""}`,
|
|
@@ -2419,8 +2451,9 @@ var Ce = r(function({ label: e, id: r, name: i, className: o = "", ...s }, c) {
|
|
|
2419
2451
|
});
|
|
2420
2452
|
//#endregion
|
|
2421
2453
|
//#region src/components/AppChip.jsx
|
|
2422
|
-
function
|
|
2423
|
-
|
|
2454
|
+
function De({ label: r, children: i, tone: a = "neutral", size: o = "md", leadingIcon: s, avatar: c, onRemove: l, onClick: u, disabled: d = !1, removeLabel: f, className: p = "", ...m }) {
|
|
2455
|
+
w("AppChip", m);
|
|
2456
|
+
let h = r ?? i, g = [
|
|
2424
2457
|
"chip",
|
|
2425
2458
|
a && a !== "neutral" ? a : "",
|
|
2426
2459
|
o === "sm" ? "chip-sm" : "",
|
|
@@ -2428,7 +2461,7 @@ function we({ label: r, children: i, tone: a = "neutral", size: o = "md", leadin
|
|
|
2428
2461
|
l ? "chip-removable" : "",
|
|
2429
2462
|
d ? "is-disabled" : "",
|
|
2430
2463
|
p
|
|
2431
|
-
].filter(Boolean).join(" "),
|
|
2464
|
+
].filter(Boolean).join(" "), _ = c ? /* @__PURE__ */ t("span", {
|
|
2432
2465
|
className: "chip-avatar",
|
|
2433
2466
|
children: typeof c == "string" ? /* @__PURE__ */ t("img", {
|
|
2434
2467
|
src: c,
|
|
@@ -2436,32 +2469,32 @@ function we({ label: r, children: i, tone: a = "neutral", size: o = "md", leadin
|
|
|
2436
2469
|
}) : c
|
|
2437
2470
|
}) : s ? /* @__PURE__ */ t("span", {
|
|
2438
2471
|
className: "chip-ic",
|
|
2439
|
-
children: /* @__PURE__ */ t(
|
|
2472
|
+
children: /* @__PURE__ */ t(D, {
|
|
2440
2473
|
name: s,
|
|
2441
2474
|
size: o === "sm" ? 12 : 14
|
|
2442
2475
|
})
|
|
2443
2476
|
}) : null;
|
|
2444
2477
|
return /* @__PURE__ */ n("span", {
|
|
2445
|
-
className:
|
|
2478
|
+
className: g,
|
|
2446
2479
|
children: [u ? /* @__PURE__ */ n("button", {
|
|
2447
2480
|
type: "button",
|
|
2448
2481
|
className: "chip-body",
|
|
2449
2482
|
onClick: u,
|
|
2450
2483
|
disabled: d,
|
|
2451
|
-
children: [
|
|
2484
|
+
children: [_, /* @__PURE__ */ t("span", {
|
|
2452
2485
|
className: "chip-label",
|
|
2453
|
-
children:
|
|
2486
|
+
children: h
|
|
2454
2487
|
})]
|
|
2455
|
-
}) : /* @__PURE__ */ n(e, { children: [
|
|
2488
|
+
}) : /* @__PURE__ */ n(e, { children: [_, /* @__PURE__ */ t("span", {
|
|
2456
2489
|
className: "chip-label",
|
|
2457
|
-
children:
|
|
2490
|
+
children: h
|
|
2458
2491
|
})] }), l && /* @__PURE__ */ t("button", {
|
|
2459
2492
|
type: "button",
|
|
2460
2493
|
className: "chip-remove",
|
|
2461
2494
|
onClick: l,
|
|
2462
2495
|
disabled: d,
|
|
2463
|
-
"aria-label": f || (typeof
|
|
2464
|
-
children: /* @__PURE__ */ t(
|
|
2496
|
+
"aria-label": f || (typeof h == "string" ? `Remove ${h}` : "Remove"),
|
|
2497
|
+
children: /* @__PURE__ */ t(D, {
|
|
2465
2498
|
name: "x",
|
|
2466
2499
|
size: o === "sm" ? 12 : 14
|
|
2467
2500
|
})
|
|
@@ -2470,8 +2503,8 @@ function we({ label: r, children: i, tone: a = "neutral", size: o = "md", leadin
|
|
|
2470
2503
|
}
|
|
2471
2504
|
//#endregion
|
|
2472
2505
|
//#region src/components/AppChoiceCard.jsx
|
|
2473
|
-
function
|
|
2474
|
-
return /* @__PURE__ */ n("label", {
|
|
2506
|
+
function Oe({ name: r, multiple: i = !1, value: a, checked: o, onChange: s, icon: c, iconNode: l, iconSize: u = 18, image: d, imageAlt: f = "", children: p, title: m, description: h, checkIcon: g = "check", checkSize: _ = 12, className: v = "", ...y }) {
|
|
2507
|
+
return w("AppChoiceCard", y), /* @__PURE__ */ n("label", {
|
|
2475
2508
|
className: `struct-card${d ? " struct-card-img-card" : ""}${o ? " checked" : ""}${v ? ` ${v}` : ""}`,
|
|
2476
2509
|
children: [
|
|
2477
2510
|
/* @__PURE__ */ t("input", {
|
|
@@ -2491,14 +2524,14 @@ function Te({ name: r, multiple: i = !1, value: a, checked: o, onChange: s, icon
|
|
|
2491
2524
|
})
|
|
2492
2525
|
}) : l || c ? /* @__PURE__ */ t("span", {
|
|
2493
2526
|
className: "struct-card-ic",
|
|
2494
|
-
children: l || /* @__PURE__ */ t(
|
|
2527
|
+
children: l || /* @__PURE__ */ t(D, {
|
|
2495
2528
|
name: c,
|
|
2496
2529
|
size: u
|
|
2497
2530
|
})
|
|
2498
2531
|
}) : null,
|
|
2499
2532
|
/* @__PURE__ */ t("span", {
|
|
2500
2533
|
className: "struct-card-body",
|
|
2501
|
-
children: p || /* @__PURE__ */ n(e, { children: [/* @__PURE__ */ t("span", {
|
|
2534
|
+
children: p || /* @__PURE__ */ n(e, { children: [m && /* @__PURE__ */ t("span", {
|
|
2502
2535
|
className: "struct-card-title",
|
|
2503
2536
|
children: m
|
|
2504
2537
|
}), h && /* @__PURE__ */ t("span", {
|
|
@@ -2508,7 +2541,7 @@ function Te({ name: r, multiple: i = !1, value: a, checked: o, onChange: s, icon
|
|
|
2508
2541
|
}),
|
|
2509
2542
|
/* @__PURE__ */ t("span", {
|
|
2510
2543
|
className: "struct-card-check",
|
|
2511
|
-
children: /* @__PURE__ */ t(
|
|
2544
|
+
children: /* @__PURE__ */ t(D, {
|
|
2512
2545
|
name: g,
|
|
2513
2546
|
size: _
|
|
2514
2547
|
})
|
|
@@ -2518,8 +2551,8 @@ function Te({ name: r, multiple: i = !1, value: a, checked: o, onChange: s, icon
|
|
|
2518
2551
|
}
|
|
2519
2552
|
//#endregion
|
|
2520
2553
|
//#region src/components/AppChoiceChip.jsx
|
|
2521
|
-
function
|
|
2522
|
-
return /* @__PURE__ */ n("label", {
|
|
2554
|
+
function ke({ multiple: e = !0, label: r, name: i, value: a, checked: o, onChange: s, children: c, count: l, className: u = "", ...d }) {
|
|
2555
|
+
return w("AppChoiceChip", d), /* @__PURE__ */ n("label", {
|
|
2523
2556
|
className: `choice-chip${o ? " checked" : ""}${u ? ` ${u}` : ""}`,
|
|
2524
2557
|
children: [
|
|
2525
2558
|
/* @__PURE__ */ t("input", {
|
|
@@ -2539,15 +2572,16 @@ function Ee({ multiple: e = !0, label: r, name: i, value: a, checked: o, onChang
|
|
|
2539
2572
|
}
|
|
2540
2573
|
//#endregion
|
|
2541
2574
|
//#region src/components/AppColorField.jsx
|
|
2542
|
-
function
|
|
2543
|
-
|
|
2575
|
+
function Ae({ value: e = "#000000", onChange: r, label: i, required: a = !1, error: o, hint: s, name: c, id: l, disabled: u = !1, className: d = "", ...f }) {
|
|
2576
|
+
w("AppColorField", f);
|
|
2577
|
+
let p = l || c;
|
|
2544
2578
|
return /* @__PURE__ */ n("div", {
|
|
2545
2579
|
className: `field${d ? ` ${d}` : ""}`,
|
|
2546
2580
|
children: [
|
|
2547
2581
|
i && /* @__PURE__ */ n("label", {
|
|
2548
2582
|
className: "label",
|
|
2549
|
-
htmlFor:
|
|
2550
|
-
children: [i, a && /* @__PURE__ */ t(
|
|
2583
|
+
htmlFor: p,
|
|
2584
|
+
children: [i, a && /* @__PURE__ */ t(Y, {})]
|
|
2551
2585
|
}),
|
|
2552
2586
|
/* @__PURE__ */ n("div", {
|
|
2553
2587
|
className: "color-field",
|
|
@@ -2562,7 +2596,7 @@ function De({ value: e = "#000000", onChange: r, label: i, required: a = !1, err
|
|
|
2562
2596
|
}), /* @__PURE__ */ t("input", {
|
|
2563
2597
|
type: "text",
|
|
2564
2598
|
className: `input color-field-hex${o ? " error" : ""}`,
|
|
2565
|
-
id:
|
|
2599
|
+
id: p,
|
|
2566
2600
|
name: c,
|
|
2567
2601
|
value: e,
|
|
2568
2602
|
onChange: (e) => r?.(e.target.value),
|
|
@@ -2586,10 +2620,11 @@ function De({ value: e = "#000000", onChange: r, label: i, required: a = !1, err
|
|
|
2586
2620
|
}
|
|
2587
2621
|
//#endregion
|
|
2588
2622
|
//#region src/components/AppCompareTable.jsx
|
|
2589
|
-
function
|
|
2590
|
-
|
|
2623
|
+
function je({ columns: e = [], rows: r = [], caption: i, className: a = "", ...o }) {
|
|
2624
|
+
w("AppCompareTable", o);
|
|
2625
|
+
let s = (e) => e === !0 ? /* @__PURE__ */ t("span", {
|
|
2591
2626
|
className: "compare-yes",
|
|
2592
|
-
children: /* @__PURE__ */ t(
|
|
2627
|
+
children: /* @__PURE__ */ t(D, {
|
|
2593
2628
|
name: "check",
|
|
2594
2629
|
size: 16
|
|
2595
2630
|
})
|
|
@@ -2614,52 +2649,53 @@ function Oe({ columns: e = [], rows: r = [], caption: i, className: a = "" }) {
|
|
|
2614
2649
|
children: r.label
|
|
2615
2650
|
}), r.values.map((n, r) => /* @__PURE__ */ t("td", {
|
|
2616
2651
|
className: e[r + 1]?.highlight ? "is-highlight" : void 0,
|
|
2617
|
-
children:
|
|
2652
|
+
children: s(n)
|
|
2618
2653
|
}, e[r + 1]?.label ?? r))] }, r.key ?? `${r.label}-${i}`)) })
|
|
2619
2654
|
] })
|
|
2620
2655
|
});
|
|
2621
2656
|
}
|
|
2622
2657
|
//#endregion
|
|
2623
2658
|
//#region src/components/AppInfoTip.jsx
|
|
2624
|
-
function
|
|
2625
|
-
|
|
2659
|
+
function Z({ label: e, children: r, ...i }) {
|
|
2660
|
+
w("AppInfoTip", i);
|
|
2661
|
+
let [l, u] = c(!1), [d, f] = c(null), p = s(null), h = s(null), g = a();
|
|
2626
2662
|
return o(() => {
|
|
2627
|
-
if (!
|
|
2628
|
-
let e =
|
|
2663
|
+
if (!l || !p.current || !h.current) return;
|
|
2664
|
+
let e = p.current.getBoundingClientRect(), t = h.current.offsetWidth, n = h.current.offsetHeight, r = e.left + e.width / 2 - t / 2;
|
|
2629
2665
|
r = Math.max(8, Math.min(r, window.innerWidth - t - 8));
|
|
2630
|
-
let
|
|
2631
|
-
|
|
2632
|
-
top:
|
|
2666
|
+
let i = e.top - n - 8;
|
|
2667
|
+
i < 8 && (i = e.bottom + 8), f({
|
|
2668
|
+
top: i,
|
|
2633
2669
|
left: r
|
|
2634
2670
|
});
|
|
2635
|
-
}, [
|
|
2671
|
+
}, [l]), r ? /* @__PURE__ */ n("span", {
|
|
2636
2672
|
className: "infotip",
|
|
2637
|
-
onMouseLeave: () =>
|
|
2673
|
+
onMouseLeave: () => u(!1),
|
|
2638
2674
|
children: [/* @__PURE__ */ t("button", {
|
|
2639
2675
|
type: "button",
|
|
2640
|
-
ref:
|
|
2676
|
+
ref: p,
|
|
2641
2677
|
className: "infotip-btn",
|
|
2642
2678
|
"aria-label": e,
|
|
2643
|
-
"aria-expanded":
|
|
2644
|
-
"aria-describedby":
|
|
2645
|
-
onMouseEnter: () =>
|
|
2646
|
-
onClick: () =>
|
|
2647
|
-
onFocus: () =>
|
|
2648
|
-
onBlur: () =>
|
|
2649
|
-
children: /* @__PURE__ */ t(
|
|
2679
|
+
"aria-expanded": l,
|
|
2680
|
+
"aria-describedby": l ? g : void 0,
|
|
2681
|
+
onMouseEnter: () => u(!0),
|
|
2682
|
+
onClick: () => u((e) => !e),
|
|
2683
|
+
onFocus: () => u(!0),
|
|
2684
|
+
onBlur: () => u(!1),
|
|
2685
|
+
children: /* @__PURE__ */ t(D, {
|
|
2650
2686
|
name: "info",
|
|
2651
2687
|
size: 16
|
|
2652
2688
|
})
|
|
2653
|
-
}),
|
|
2654
|
-
ref:
|
|
2689
|
+
}), l && m(/* @__PURE__ */ t("span", {
|
|
2690
|
+
ref: h,
|
|
2655
2691
|
className: "infotip-pop is-portal",
|
|
2656
2692
|
role: "tooltip",
|
|
2657
|
-
id:
|
|
2693
|
+
id: g,
|
|
2658
2694
|
style: {
|
|
2659
2695
|
position: "fixed",
|
|
2660
|
-
top:
|
|
2661
|
-
left:
|
|
2662
|
-
visibility:
|
|
2696
|
+
top: d ? d.top : 0,
|
|
2697
|
+
left: d ? d.left : 0,
|
|
2698
|
+
visibility: d ? "visible" : "hidden"
|
|
2663
2699
|
},
|
|
2664
2700
|
children: r
|
|
2665
2701
|
}), document.body)]
|
|
@@ -2667,52 +2703,53 @@ function J({ label: e, children: r }) {
|
|
|
2667
2703
|
}
|
|
2668
2704
|
//#endregion
|
|
2669
2705
|
//#region src/components/AppInput.jsx
|
|
2670
|
-
var
|
|
2671
|
-
|
|
2706
|
+
var Me = r(function({ label: e, required: r = !1, error: i, hint: a, help: o, helpLabel: s = "More information", type: l = "text", leftIcon: u, rightIcon: d, onRightIconClick: f, unit: m, id: h, name: g, className: _ = "", fieldClassName: v = "", disabled: y = !1, ...b }, x) {
|
|
2707
|
+
w("AppInput", b);
|
|
2708
|
+
let [S, C] = c(!1), T = h || g, E = l === "password", O = E && S ? "text" : l, k = [
|
|
2672
2709
|
"input",
|
|
2673
2710
|
i ? "error" : "",
|
|
2674
2711
|
E ? "pw" : "",
|
|
2675
2712
|
m ? "num-input" : "",
|
|
2676
2713
|
_
|
|
2677
|
-
].filter(Boolean).join(" "),
|
|
2714
|
+
].filter(Boolean).join(" "), A = /* @__PURE__ */ t(p.Control, {
|
|
2678
2715
|
id: T,
|
|
2679
2716
|
name: g,
|
|
2680
|
-
type:
|
|
2681
|
-
className:
|
|
2717
|
+
type: O,
|
|
2718
|
+
className: k,
|
|
2682
2719
|
disabled: y,
|
|
2683
2720
|
required: r,
|
|
2684
2721
|
"aria-invalid": i ? "true" : "false",
|
|
2685
|
-
ref:
|
|
2722
|
+
ref: x,
|
|
2686
2723
|
...b
|
|
2687
|
-
}),
|
|
2688
|
-
return
|
|
2724
|
+
}), j;
|
|
2725
|
+
return j = m ? /* @__PURE__ */ n("div", {
|
|
2689
2726
|
className: "input-with-unit",
|
|
2690
|
-
children: [
|
|
2727
|
+
children: [A, /* @__PURE__ */ t("span", {
|
|
2691
2728
|
className: "unit",
|
|
2692
2729
|
children: m
|
|
2693
2730
|
})]
|
|
2694
2731
|
}) : E ? /* @__PURE__ */ n("div", {
|
|
2695
2732
|
className: "input-wrap",
|
|
2696
|
-
children: [
|
|
2733
|
+
children: [A, /* @__PURE__ */ t("button", {
|
|
2697
2734
|
type: "button",
|
|
2698
2735
|
className: "pw-toggle",
|
|
2699
|
-
onClick: () =>
|
|
2700
|
-
"aria-label":
|
|
2736
|
+
onClick: () => C((e) => !e),
|
|
2737
|
+
"aria-label": S ? "Hide password" : "Show password",
|
|
2701
2738
|
tabIndex: -1,
|
|
2702
|
-
children: /* @__PURE__ */ t(
|
|
2703
|
-
name:
|
|
2739
|
+
children: /* @__PURE__ */ t(D, {
|
|
2740
|
+
name: S ? "eye-off" : "eye",
|
|
2704
2741
|
size: 18
|
|
2705
2742
|
})
|
|
2706
2743
|
})]
|
|
2707
2744
|
}) : d ? /* @__PURE__ */ n("div", {
|
|
2708
2745
|
className: "input-wrap",
|
|
2709
|
-
children: [
|
|
2746
|
+
children: [A, /* @__PURE__ */ t("button", {
|
|
2710
2747
|
type: "button",
|
|
2711
2748
|
className: "pw-toggle",
|
|
2712
2749
|
onClick: f,
|
|
2713
2750
|
disabled: !f,
|
|
2714
2751
|
tabIndex: -1,
|
|
2715
|
-
children: /* @__PURE__ */ t(
|
|
2752
|
+
children: /* @__PURE__ */ t(D, {
|
|
2716
2753
|
name: d,
|
|
2717
2754
|
size: 18
|
|
2718
2755
|
})
|
|
@@ -2721,12 +2758,12 @@ var Y = r(function({ label: e, required: r = !1, error: i, hint: a, help: o, hel
|
|
|
2721
2758
|
className: "input-icon",
|
|
2722
2759
|
children: [/* @__PURE__ */ t("span", {
|
|
2723
2760
|
className: "ic",
|
|
2724
|
-
children: /* @__PURE__ */ t(
|
|
2761
|
+
children: /* @__PURE__ */ t(D, {
|
|
2725
2762
|
name: u,
|
|
2726
2763
|
size: 16
|
|
2727
2764
|
})
|
|
2728
|
-
}),
|
|
2729
|
-
}) :
|
|
2765
|
+
}), A]
|
|
2766
|
+
}) : A, /* @__PURE__ */ n(p.Group, {
|
|
2730
2767
|
className: `field${v ? ` ${v}` : ""}`,
|
|
2731
2768
|
children: [
|
|
2732
2769
|
e && /* @__PURE__ */ n(p.Label, {
|
|
@@ -2734,14 +2771,14 @@ var Y = r(function({ label: e, required: r = !1, error: i, hint: a, help: o, hel
|
|
|
2734
2771
|
htmlFor: T,
|
|
2735
2772
|
children: [
|
|
2736
2773
|
e,
|
|
2737
|
-
|
|
2774
|
+
r && /* @__PURE__ */ t(Y, {}),
|
|
2775
|
+
o && /* @__PURE__ */ t(Z, {
|
|
2738
2776
|
label: s,
|
|
2739
2777
|
children: o
|
|
2740
|
-
})
|
|
2741
|
-
r && /* @__PURE__ */ t(G, {})
|
|
2778
|
+
})
|
|
2742
2779
|
]
|
|
2743
2780
|
}),
|
|
2744
|
-
|
|
2781
|
+
j,
|
|
2745
2782
|
i ? /* @__PURE__ */ t("div", {
|
|
2746
2783
|
className: "field-error",
|
|
2747
2784
|
children: i
|
|
@@ -2751,17 +2788,18 @@ var Y = r(function({ label: e, required: r = !1, error: i, hint: a, help: o, hel
|
|
|
2751
2788
|
}) : null
|
|
2752
2789
|
]
|
|
2753
2790
|
});
|
|
2754
|
-
}),
|
|
2755
|
-
function
|
|
2756
|
-
|
|
2791
|
+
}), Ne = "a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]:not([tabindex=\"-1\"])";
|
|
2792
|
+
function Pe({ open: e, title: r, subtitle: a, headerIcon: o, onClose: c, footer: l, size: u, wide: d = !1, side: f = !1, maxWidth: p, hideHeader: m = !1, className: g = "", children: _, ...v }) {
|
|
2793
|
+
w("AppModal", v);
|
|
2794
|
+
let y = s(null);
|
|
2757
2795
|
i(() => {
|
|
2758
2796
|
if (!e) return;
|
|
2759
|
-
let t =
|
|
2797
|
+
let t = y.current?.closest(".modal-content");
|
|
2760
2798
|
if (!t) return;
|
|
2761
|
-
let n = () => Array.from(t.querySelectorAll(
|
|
2799
|
+
let n = () => Array.from(t.querySelectorAll(Ne));
|
|
2762
2800
|
(t.querySelector("[data-autofocus]") || n().find((e) => !e.classList.contains("lx-modal-close")) || n()[0] || t).focus?.();
|
|
2763
2801
|
}, [e]);
|
|
2764
|
-
let
|
|
2802
|
+
let b = ["lx-modal-shell", f ? "is-side" : ""].filter(Boolean).join(" "), x = [
|
|
2765
2803
|
"lx-modal",
|
|
2766
2804
|
d ? "lx-modal-wide" : "",
|
|
2767
2805
|
f ? "lx-modal-side" : "",
|
|
@@ -2778,10 +2816,10 @@ function X({ open: e, title: r, subtitle: a, headerIcon: o, onClose: c, footer:
|
|
|
2778
2816
|
restoreFocus: !0,
|
|
2779
2817
|
size: u,
|
|
2780
2818
|
centered: !f,
|
|
2781
|
-
className:
|
|
2819
|
+
className: b,
|
|
2782
2820
|
style: p == null ? void 0 : { "--lx-modal-max-width": typeof p == "number" ? `${p}px` : p },
|
|
2783
2821
|
dialogClassName: "lx-rb-dialog",
|
|
2784
|
-
contentClassName:
|
|
2822
|
+
contentClassName: x,
|
|
2785
2823
|
backdropClassName: "lx-modal-dim",
|
|
2786
2824
|
"aria-label": typeof r == "string" ? r : void 0,
|
|
2787
2825
|
children: [
|
|
@@ -2791,7 +2829,7 @@ function X({ open: e, title: r, subtitle: a, headerIcon: o, onClose: c, footer:
|
|
|
2791
2829
|
className: "lx-modal-heading",
|
|
2792
2830
|
children: [o && /* @__PURE__ */ t("span", {
|
|
2793
2831
|
className: "lx-modal-headicon",
|
|
2794
|
-
children: /* @__PURE__ */ t(
|
|
2832
|
+
children: /* @__PURE__ */ t(D, {
|
|
2795
2833
|
name: o,
|
|
2796
2834
|
size: 18
|
|
2797
2835
|
})
|
|
@@ -2826,7 +2864,7 @@ function X({ open: e, title: r, subtitle: a, headerIcon: o, onClose: c, footer:
|
|
|
2826
2864
|
}),
|
|
2827
2865
|
/* @__PURE__ */ t("div", {
|
|
2828
2866
|
className: "lx-modal-body",
|
|
2829
|
-
ref:
|
|
2867
|
+
ref: y,
|
|
2830
2868
|
children: _
|
|
2831
2869
|
}),
|
|
2832
2870
|
l && /* @__PURE__ */ t("div", {
|
|
@@ -2838,27 +2876,28 @@ function X({ open: e, title: r, subtitle: a, headerIcon: o, onClose: c, footer:
|
|
|
2838
2876
|
}
|
|
2839
2877
|
//#endregion
|
|
2840
2878
|
//#region src/components/ModalIcons.jsx
|
|
2841
|
-
var
|
|
2879
|
+
var Q = (e) => function({ size: n = 72 }) {
|
|
2842
2880
|
return /* @__PURE__ */ t("wui-status-icon", {
|
|
2843
2881
|
tone: e,
|
|
2844
2882
|
size: n
|
|
2845
2883
|
});
|
|
2846
|
-
},
|
|
2847
|
-
success:
|
|
2848
|
-
error:
|
|
2849
|
-
warning:
|
|
2850
|
-
info:
|
|
2851
|
-
delete:
|
|
2884
|
+
}, Fe = {
|
|
2885
|
+
success: Q("success"),
|
|
2886
|
+
error: Q("error"),
|
|
2887
|
+
warning: Q("warning"),
|
|
2888
|
+
info: Q("info"),
|
|
2889
|
+
delete: Q("delete")
|
|
2852
2890
|
};
|
|
2853
2891
|
//#endregion
|
|
2854
2892
|
//#region src/components/AppConfirmDialog.jsx
|
|
2855
|
-
function
|
|
2856
|
-
|
|
2893
|
+
function Ie({ open: r, title: a, message: o, confirmLabel: s = "Confirm", cancelLabel: l = "Cancel", danger: u = !1, tone: d, confirmPhrase: f, onConfirm: p, onClose: m, ...h }) {
|
|
2894
|
+
w("AppConfirmDialog", h);
|
|
2895
|
+
let [g, _] = c("");
|
|
2857
2896
|
if (i(() => {
|
|
2858
|
-
r ||
|
|
2897
|
+
r || _("");
|
|
2859
2898
|
}, [r]), !r) return null;
|
|
2860
|
-
let
|
|
2861
|
-
return /* @__PURE__ */ t(
|
|
2899
|
+
let v = !!f && g.trim() !== f, y = Fe[d || (u ? "delete" : "info")];
|
|
2900
|
+
return /* @__PURE__ */ t(Pe, {
|
|
2862
2901
|
open: r,
|
|
2863
2902
|
hideHeader: !0,
|
|
2864
2903
|
title: a,
|
|
@@ -2866,13 +2905,13 @@ function je({ open: r, title: a, message: o, confirmLabel: s = "Confirm", cancel
|
|
|
2866
2905
|
className: "lx-confirm",
|
|
2867
2906
|
footer: /* @__PURE__ */ n("div", {
|
|
2868
2907
|
className: "lx-confirm-actions",
|
|
2869
|
-
children: [/* @__PURE__ */ t(
|
|
2908
|
+
children: [/* @__PURE__ */ t(X, {
|
|
2870
2909
|
variant: "secondary",
|
|
2871
2910
|
onClick: m,
|
|
2872
2911
|
children: l
|
|
2873
|
-
}), /* @__PURE__ */ t(
|
|
2912
|
+
}), /* @__PURE__ */ t(X, {
|
|
2874
2913
|
variant: u ? "danger" : "primary",
|
|
2875
|
-
disabled:
|
|
2914
|
+
disabled: v,
|
|
2876
2915
|
onClick: p,
|
|
2877
2916
|
children: s
|
|
2878
2917
|
})]
|
|
@@ -2880,27 +2919,29 @@ function je({ open: r, title: a, message: o, confirmLabel: s = "Confirm", cancel
|
|
|
2880
2919
|
children: /* @__PURE__ */ n("div", {
|
|
2881
2920
|
className: "lx-confirm-content",
|
|
2882
2921
|
children: [
|
|
2883
|
-
|
|
2922
|
+
y && /* @__PURE__ */ t("span", {
|
|
2884
2923
|
className: "lx-confirm-icon",
|
|
2885
|
-
children: /* @__PURE__ */ t(
|
|
2924
|
+
children: /* @__PURE__ */ t(y, { size: 104 })
|
|
2886
2925
|
}),
|
|
2887
2926
|
/* @__PURE__ */ t("h3", {
|
|
2888
2927
|
className: "lx-confirm-title",
|
|
2928
|
+
tabIndex: -1,
|
|
2929
|
+
"data-autofocus": !0,
|
|
2889
2930
|
children: a
|
|
2890
2931
|
}),
|
|
2891
2932
|
o && /* @__PURE__ */ t("p", {
|
|
2892
2933
|
className: "lx-confirm-msg",
|
|
2893
2934
|
children: o
|
|
2894
2935
|
}),
|
|
2895
|
-
f && /* @__PURE__ */ t(
|
|
2936
|
+
f && /* @__PURE__ */ t(Me, {
|
|
2896
2937
|
fieldClassName: "mt-3 mb-0 w-100 text-start",
|
|
2897
2938
|
label: /* @__PURE__ */ n(e, { children: [
|
|
2898
2939
|
"Type ",
|
|
2899
2940
|
/* @__PURE__ */ t("strong", { children: f }),
|
|
2900
2941
|
" to confirm"
|
|
2901
2942
|
] }),
|
|
2902
|
-
value:
|
|
2903
|
-
onChange: (e) =>
|
|
2943
|
+
value: g,
|
|
2944
|
+
onChange: (e) => _(e.target.value),
|
|
2904
2945
|
"aria-label": `Type ${f} to confirm`
|
|
2905
2946
|
})
|
|
2906
2947
|
]
|
|
@@ -2909,8 +2950,8 @@ function je({ open: r, title: a, message: o, confirmLabel: s = "Confirm", cancel
|
|
|
2909
2950
|
}
|
|
2910
2951
|
//#endregion
|
|
2911
2952
|
//#region src/components/AppSkeleton.jsx
|
|
2912
|
-
function
|
|
2913
|
-
return /* @__PURE__ */ t("span", {
|
|
2953
|
+
function Le({ width: e = "100%", height: n = 14, radius: r = 6, className: i = "", style: a, ...o }) {
|
|
2954
|
+
return w("AppSkeleton", o), /* @__PURE__ */ t("span", {
|
|
2914
2955
|
className: `skeleton${i ? ` ${i}` : ""}`,
|
|
2915
2956
|
"aria-hidden": "true",
|
|
2916
2957
|
style: {
|
|
@@ -2921,7 +2962,7 @@ function Me({ width: e = "100%", height: n = 14, radius: r = 6, className: i = "
|
|
|
2921
2962
|
}
|
|
2922
2963
|
});
|
|
2923
2964
|
}
|
|
2924
|
-
var
|
|
2965
|
+
var Re = [
|
|
2925
2966
|
"r0",
|
|
2926
2967
|
"r1",
|
|
2927
2968
|
"r2",
|
|
@@ -2930,7 +2971,7 @@ var Ne = [
|
|
|
2930
2971
|
"r5",
|
|
2931
2972
|
"r6",
|
|
2932
2973
|
"r7"
|
|
2933
|
-
],
|
|
2974
|
+
], ze = [
|
|
2934
2975
|
"c0",
|
|
2935
2976
|
"c1",
|
|
2936
2977
|
"c2",
|
|
@@ -2940,31 +2981,32 @@ var Ne = [
|
|
|
2940
2981
|
"c6",
|
|
2941
2982
|
"c7"
|
|
2942
2983
|
];
|
|
2943
|
-
function
|
|
2944
|
-
return
|
|
2984
|
+
function Be({ rows: e = 4, cols: n = 5 }) {
|
|
2985
|
+
return Re.slice(0, e).map((e) => /* @__PURE__ */ t("tr", { children: ze.slice(0, n).map((e, n) => /* @__PURE__ */ t("td", { children: /* @__PURE__ */ t(Le, {
|
|
2945
2986
|
width: n === 0 ? "70%" : "50%",
|
|
2946
2987
|
height: 12
|
|
2947
2988
|
}) }, e)) }, e));
|
|
2948
2989
|
}
|
|
2949
2990
|
//#endregion
|
|
2950
2991
|
//#region src/components/AppSelectMini.jsx
|
|
2951
|
-
function
|
|
2952
|
-
|
|
2992
|
+
function Ve({ value: e, onChange: n, options: r = [], placeholder: a = "Select...", name: o, ariaLabel: c, id: l, disabled: u, className: d, ...f }) {
|
|
2993
|
+
w("AppSelectMini", f);
|
|
2994
|
+
let p = s(null);
|
|
2953
2995
|
return i(() => {
|
|
2954
|
-
|
|
2996
|
+
p.current && (p.current.options = r.map((e) => ({
|
|
2955
2997
|
value: e.value,
|
|
2956
2998
|
label: e.label ?? e.text ?? ""
|
|
2957
2999
|
})));
|
|
2958
3000
|
}, [r]), i(() => {
|
|
2959
|
-
let t =
|
|
3001
|
+
let t = p.current;
|
|
2960
3002
|
t && String(t.value ?? "") !== String(e ?? "") && (t.value = e ?? "");
|
|
2961
3003
|
}, [e]), i(() => {
|
|
2962
|
-
let e =
|
|
3004
|
+
let e = p.current;
|
|
2963
3005
|
if (!e) return;
|
|
2964
3006
|
let t = () => n?.(e.value);
|
|
2965
3007
|
return e.addEventListener("change", t), () => e.removeEventListener("change", t);
|
|
2966
3008
|
}, [n]), /* @__PURE__ */ t("wui-select", {
|
|
2967
|
-
ref:
|
|
3009
|
+
ref: p,
|
|
2968
3010
|
name: o,
|
|
2969
3011
|
compact: "",
|
|
2970
3012
|
id: l,
|
|
@@ -2976,20 +3018,19 @@ function Fe({ value: e, onChange: n, options: r = [], placeholder: a = "Select..
|
|
|
2976
3018
|
}
|
|
2977
3019
|
//#endregion
|
|
2978
3020
|
//#region src/components/AppTablePagination.jsx
|
|
2979
|
-
var
|
|
3021
|
+
var He = [
|
|
2980
3022
|
5,
|
|
2981
3023
|
10,
|
|
2982
3024
|
25,
|
|
2983
3025
|
50
|
|
2984
3026
|
];
|
|
2985
|
-
function
|
|
2986
|
-
return /* @__PURE__ */ n("div", {
|
|
3027
|
+
function Ue({ page: e, totalPages: r, pageSize: i, total: a, firstRow: o, lastRow: s, onPageChange: c, onPageSizeChange: l, pageSizes: u = He, ...d }) {
|
|
3028
|
+
return w("AppTablePagination", d), /* @__PURE__ */ n("div", {
|
|
2987
3029
|
className: "table-pagination",
|
|
2988
3030
|
children: [
|
|
2989
3031
|
/* @__PURE__ */ n("span", {
|
|
2990
3032
|
className: "tpg-rows",
|
|
2991
|
-
children: ["Rows per page:", /* @__PURE__ */ t(
|
|
2992
|
-
compact: !0,
|
|
3033
|
+
children: ["Rows per page:", /* @__PURE__ */ t(Ve, {
|
|
2993
3034
|
value: i,
|
|
2994
3035
|
onChange: (e) => l(Number(e)),
|
|
2995
3036
|
ariaLabel: "Rows per page",
|
|
@@ -3017,7 +3058,7 @@ function Le({ page: e, totalPages: r, pageSize: i, total: a, firstRow: o, lastRo
|
|
|
3017
3058
|
onClick: () => c(Math.max(1, e - 1)),
|
|
3018
3059
|
disabled: e <= 1,
|
|
3019
3060
|
"aria-label": "Previous page",
|
|
3020
|
-
children: /* @__PURE__ */ t(
|
|
3061
|
+
children: /* @__PURE__ */ t(D, {
|
|
3021
3062
|
name: "arrow-left",
|
|
3022
3063
|
size: 18
|
|
3023
3064
|
})
|
|
@@ -3027,7 +3068,7 @@ function Le({ page: e, totalPages: r, pageSize: i, total: a, firstRow: o, lastRo
|
|
|
3027
3068
|
onClick: () => c(Math.min(r, e + 1)),
|
|
3028
3069
|
disabled: e >= r,
|
|
3029
3070
|
"aria-label": "Next page",
|
|
3030
|
-
children: /* @__PURE__ */ t(
|
|
3071
|
+
children: /* @__PURE__ */ t(D, {
|
|
3031
3072
|
name: "arrow-right",
|
|
3032
3073
|
size: 18
|
|
3033
3074
|
})
|
|
@@ -3038,16 +3079,17 @@ function Le({ page: e, totalPages: r, pageSize: i, total: a, firstRow: o, lastRo
|
|
|
3038
3079
|
}
|
|
3039
3080
|
//#endregion
|
|
3040
3081
|
//#region src/components/AppDataTable.jsx
|
|
3041
|
-
function
|
|
3082
|
+
function We(e) {
|
|
3042
3083
|
return e === "end" ? "lx-cell-end" : e === "num" ? "num" : e === "center" ? "text-center" : "";
|
|
3043
3084
|
}
|
|
3044
|
-
function
|
|
3085
|
+
function Ge(e) {
|
|
3045
3086
|
return e == null || e === "" ? "—" : e;
|
|
3046
3087
|
}
|
|
3047
|
-
function
|
|
3048
|
-
|
|
3049
|
-
|
|
3050
|
-
|
|
3088
|
+
function Ke({ columns: r, rows: i, rowKey: a = (e) => e.id, sort: o, onSort: s, loading: c = !1, skeletonRows: l = 5, empty: u = "No records found.", emptyFiltered: d, sourceCount: f, rowActions: p, rowActionsLabel: m, pagination: h, ariaLabel: g, className: _ = "", selectable: v = !1, selectedIds: y, onToggleRow: b, onToggleAll: x, ...S }) {
|
|
3089
|
+
w("AppDataTable", S);
|
|
3090
|
+
let C = Math.max(1, r.length + +!!p + +!!v), T = v && i ? i.reduce((e, t) => e + +!!y?.has(a(t)), 0) : 0, E = v && i && i.length > 0 && T === i.length, O = T > 0 && !E, k = (e) => {
|
|
3091
|
+
e && (e.indeterminate = O);
|
|
3092
|
+
}, A = d !== void 0 && f > 0 ? d : u;
|
|
3051
3093
|
return /* @__PURE__ */ n(e, { children: [/* @__PURE__ */ t("div", {
|
|
3052
3094
|
className: "table-wrap",
|
|
3053
3095
|
children: /* @__PURE__ */ n("table", {
|
|
@@ -3057,18 +3099,18 @@ function Be({ columns: r, rows: i, rowKey: a = (e) => e.id, sort: o, onSort: s,
|
|
|
3057
3099
|
v && /* @__PURE__ */ t("th", {
|
|
3058
3100
|
className: "lx-select-cell",
|
|
3059
3101
|
children: /* @__PURE__ */ t("input", {
|
|
3060
|
-
ref:
|
|
3102
|
+
ref: k,
|
|
3061
3103
|
type: "checkbox",
|
|
3062
3104
|
className: "lx-check",
|
|
3063
|
-
checked:
|
|
3064
|
-
onChange: (e) =>
|
|
3105
|
+
checked: E,
|
|
3106
|
+
onChange: (e) => x?.(e.target.checked),
|
|
3065
3107
|
"aria-label": "Select all rows"
|
|
3066
3108
|
})
|
|
3067
3109
|
}),
|
|
3068
3110
|
r.map((e) => {
|
|
3069
3111
|
let r = !!(e.sortable && s), i = o && o.key === e.key;
|
|
3070
3112
|
return /* @__PURE__ */ n("th", {
|
|
3071
|
-
className: (r ? "sortable " : "") +
|
|
3113
|
+
className: (r ? "sortable " : "") + We(e.align),
|
|
3072
3114
|
style: e.width ? { width: e.width } : void 0,
|
|
3073
3115
|
tabIndex: r ? 0 : void 0,
|
|
3074
3116
|
"aria-sort": i ? o.dir === "asc" ? "ascending" : "descending" : r ? "none" : void 0,
|
|
@@ -3078,7 +3120,7 @@ function Be({ columns: r, rows: i, rowKey: a = (e) => e.id, sort: o, onSort: s,
|
|
|
3078
3120
|
} : void 0,
|
|
3079
3121
|
children: [e.label, r && /* @__PURE__ */ t("span", {
|
|
3080
3122
|
className: "sort-icon",
|
|
3081
|
-
children: /* @__PURE__ */ t(
|
|
3123
|
+
children: /* @__PURE__ */ t(D, {
|
|
3082
3124
|
name: "chevrons-up-down",
|
|
3083
3125
|
size: 14
|
|
3084
3126
|
})
|
|
@@ -3095,7 +3137,7 @@ function Be({ columns: r, rows: i, rowKey: a = (e) => e.id, sort: o, onSort: s,
|
|
|
3095
3137
|
children: "Actions"
|
|
3096
3138
|
})
|
|
3097
3139
|
}))
|
|
3098
|
-
] }) }), /* @__PURE__ */ t("tbody", { children: c ? /* @__PURE__ */ t(
|
|
3140
|
+
] }) }), /* @__PURE__ */ t("tbody", { children: c ? /* @__PURE__ */ t(Be, {
|
|
3099
3141
|
rows: l,
|
|
3100
3142
|
cols: C
|
|
3101
3143
|
}) : i?.length ? i.map((e) => {
|
|
@@ -3114,8 +3156,8 @@ function Be({ columns: r, rows: i, rowKey: a = (e) => e.id, sort: o, onSort: s,
|
|
|
3114
3156
|
})
|
|
3115
3157
|
}),
|
|
3116
3158
|
r.map((n) => /* @__PURE__ */ t("td", {
|
|
3117
|
-
className:
|
|
3118
|
-
children: n.render ? n.render(e) :
|
|
3159
|
+
className: We(n.align) + (n.cellClassName ? ` ${n.cellClassName}` : ""),
|
|
3160
|
+
children: n.render ? n.render(e) : Ge(e[n.key])
|
|
3119
3161
|
}, n.key)),
|
|
3120
3162
|
p && /* @__PURE__ */ t("td", { children: /* @__PURE__ */ t("div", {
|
|
3121
3163
|
className: "u-row-actions",
|
|
@@ -3126,10 +3168,10 @@ function Be({ columns: r, rows: i, rowKey: a = (e) => e.id, sort: o, onSort: s,
|
|
|
3126
3168
|
}) : /* @__PURE__ */ t("tr", { children: /* @__PURE__ */ t("td", {
|
|
3127
3169
|
colSpan: C,
|
|
3128
3170
|
className: "lx-table-empty",
|
|
3129
|
-
children:
|
|
3171
|
+
children: A
|
|
3130
3172
|
}) }) })]
|
|
3131
3173
|
})
|
|
3132
|
-
}), h && !c && h.total > 0 && /* @__PURE__ */ t(
|
|
3174
|
+
}), h && !c && h.total > 0 && /* @__PURE__ */ t(Ue, {
|
|
3133
3175
|
page: h.page,
|
|
3134
3176
|
totalPages: h.totalPages,
|
|
3135
3177
|
pageSize: h.pageSize,
|
|
@@ -3142,41 +3184,43 @@ function Be({ columns: r, rows: i, rowKey: a = (e) => e.id, sort: o, onSort: s,
|
|
|
3142
3184
|
}
|
|
3143
3185
|
//#endregion
|
|
3144
3186
|
//#region src/components/AppDatePicker.jsx
|
|
3145
|
-
function
|
|
3146
|
-
|
|
3187
|
+
function qe({ value: e, onChange: r, label: o, required: c = !1, hint: l, error: u, name: d, min: f, max: p, placeholder: m = "Enter Date", disabled: h, id: g, ariaLabel: _, className: v = "", ...y }) {
|
|
3188
|
+
w("AppDatePicker", y);
|
|
3189
|
+
let b = s(null), x = a(), S = g || d || x;
|
|
3147
3190
|
i(() => {
|
|
3148
|
-
let t =
|
|
3191
|
+
let t = b.current;
|
|
3149
3192
|
t && t.value !== (e ?? "") && (t.value = e ?? "");
|
|
3150
3193
|
}, [e]), i(() => {
|
|
3151
|
-
let e =
|
|
3194
|
+
let e = b.current;
|
|
3152
3195
|
if (!e) return;
|
|
3153
3196
|
let t = () => r?.(e.value);
|
|
3154
3197
|
return e.addEventListener("change", t), () => e.removeEventListener("change", t);
|
|
3155
3198
|
}, [r]);
|
|
3156
|
-
let
|
|
3157
|
-
ref:
|
|
3158
|
-
id:
|
|
3199
|
+
let C = /* @__PURE__ */ t("wui-datepicker", {
|
|
3200
|
+
ref: b,
|
|
3201
|
+
id: S,
|
|
3159
3202
|
name: d,
|
|
3160
3203
|
min: f,
|
|
3161
3204
|
max: p,
|
|
3162
3205
|
placeholder: m,
|
|
3163
3206
|
"aria-label": _,
|
|
3164
3207
|
"aria-invalid": u ? "true" : void 0,
|
|
3165
|
-
disabled: h ? "" : void 0
|
|
3208
|
+
disabled: h ? "" : void 0,
|
|
3209
|
+
required: c ? "" : void 0
|
|
3166
3210
|
});
|
|
3167
|
-
return !o && !u && !l ?
|
|
3211
|
+
return !o && !u && !l ? C : /* @__PURE__ */ n("div", {
|
|
3168
3212
|
className: `field${v ? ` ${v}` : ""}`,
|
|
3169
3213
|
children: [
|
|
3170
3214
|
o && /* @__PURE__ */ n("label", {
|
|
3171
3215
|
className: "label",
|
|
3172
|
-
htmlFor:
|
|
3216
|
+
htmlFor: S,
|
|
3173
3217
|
children: [o, c && /* @__PURE__ */ t("span", {
|
|
3174
3218
|
className: "required",
|
|
3175
3219
|
"aria-hidden": "true",
|
|
3176
3220
|
children: "*"
|
|
3177
3221
|
})]
|
|
3178
3222
|
}),
|
|
3179
|
-
|
|
3223
|
+
C,
|
|
3180
3224
|
u && /* @__PURE__ */ t("div", {
|
|
3181
3225
|
className: "field-error",
|
|
3182
3226
|
children: u
|
|
@@ -3190,7 +3234,7 @@ function Ve({ value: e, onChange: r, label: o, required: c = !1, hint: l, error:
|
|
|
3190
3234
|
}
|
|
3191
3235
|
//#endregion
|
|
3192
3236
|
//#region src/components/AppDropdown.jsx
|
|
3193
|
-
var
|
|
3237
|
+
var Je = r(function({ icon: e, iconSize: n = 20, btnClassName: r = "topbar-icon-btn", label: i, align: a = "end", "aria-label": o, className: s, ...c }, l) {
|
|
3194
3238
|
return /* @__PURE__ */ t("button", {
|
|
3195
3239
|
ref: l,
|
|
3196
3240
|
type: "button",
|
|
@@ -3198,17 +3242,17 @@ var He = r(function({ icon: e, iconSize: n = 20, btnClassName: r = "topbar-icon-
|
|
|
3198
3242
|
title: i,
|
|
3199
3243
|
"aria-label": o,
|
|
3200
3244
|
...c,
|
|
3201
|
-
children: /* @__PURE__ */ t(
|
|
3245
|
+
children: /* @__PURE__ */ t(D, {
|
|
3202
3246
|
name: e,
|
|
3203
3247
|
size: n
|
|
3204
3248
|
})
|
|
3205
3249
|
});
|
|
3206
3250
|
});
|
|
3207
|
-
function
|
|
3208
|
-
return /* @__PURE__ */ n(g, {
|
|
3251
|
+
function Ye({ icon: e, iconSize: r, toggleClassName: i = "topbar-icon-btn", label: a, ariaLabel: o, align: s = "end", items: c = [], menuClassName: l = "", linkComponent: u, ...d }) {
|
|
3252
|
+
return w("AppDropdown", d), /* @__PURE__ */ n(g, {
|
|
3209
3253
|
align: s,
|
|
3210
3254
|
children: [/* @__PURE__ */ t(g.Toggle, {
|
|
3211
|
-
as:
|
|
3255
|
+
as: Je,
|
|
3212
3256
|
icon: e,
|
|
3213
3257
|
iconSize: r,
|
|
3214
3258
|
btnClassName: i,
|
|
@@ -3232,10 +3276,12 @@ function Ue({ icon: e, iconSize: r, toggleClassName: i = "topbar-icon-btn", labe
|
|
|
3232
3276
|
...r,
|
|
3233
3277
|
onClick: e.onClick,
|
|
3234
3278
|
className: e.danger ? "danger" : void 0,
|
|
3235
|
-
children: [e.
|
|
3279
|
+
children: [e.image ? /* @__PURE__ */ t("img", {
|
|
3280
|
+
src: e.image,
|
|
3281
|
+
alt: ""
|
|
3282
|
+
}) : e.icon && /* @__PURE__ */ t(D, {
|
|
3236
3283
|
name: e.icon,
|
|
3237
|
-
size:
|
|
3238
|
-
color: e.danger ? "var(--wui-danger)" : "var(--wui-primary)"
|
|
3284
|
+
size: 16
|
|
3239
3285
|
}), e.label]
|
|
3240
3286
|
}, e.key);
|
|
3241
3287
|
})
|
|
@@ -3244,8 +3290,8 @@ function Ue({ icon: e, iconSize: r, toggleClassName: i = "topbar-icon-btn", labe
|
|
|
3244
3290
|
}
|
|
3245
3291
|
//#endregion
|
|
3246
3292
|
//#region src/components/AppEmptyState.jsx
|
|
3247
|
-
function
|
|
3248
|
-
return /* @__PURE__ */ n("div", {
|
|
3293
|
+
function Xe({ icon: e, iconSize: r = 24, size: i = "md", title: a, text: o, action: s, className: c = "", style: l, ...u }) {
|
|
3294
|
+
return w("AppEmptyState", u), /* @__PURE__ */ n("div", {
|
|
3249
3295
|
className: [
|
|
3250
3296
|
"empty-state",
|
|
3251
3297
|
i === "sm" ? "empty-state-sm" : "",
|
|
@@ -3255,7 +3301,7 @@ function We({ icon: e, iconSize: r = 24, size: i = "md", title: a, text: o, acti
|
|
|
3255
3301
|
children: [
|
|
3256
3302
|
e ? /* @__PURE__ */ t("div", {
|
|
3257
3303
|
className: "empty-state-icon",
|
|
3258
|
-
children: /* @__PURE__ */ t(
|
|
3304
|
+
children: /* @__PURE__ */ t(D, {
|
|
3259
3305
|
name: e,
|
|
3260
3306
|
size: r
|
|
3261
3307
|
})
|
|
@@ -3277,38 +3323,39 @@ function We({ icon: e, iconSize: r = 24, size: i = "md", title: a, text: o, acti
|
|
|
3277
3323
|
}
|
|
3278
3324
|
//#endregion
|
|
3279
3325
|
//#region src/components/AppFileAttachment.jsx
|
|
3280
|
-
function
|
|
3281
|
-
|
|
3326
|
+
function Ze({ label: r = "Attachment", value: o, name: s, onChange: l, accept: u = G, maxSizeMb: d = 5, optional: f = !1, error: p, id: m, ...h }) {
|
|
3327
|
+
w("AppFileAttachment", h);
|
|
3328
|
+
let g = a(), _ = m || s || g, [v, y] = c(null), [b, x] = c("");
|
|
3282
3329
|
i(() => {
|
|
3283
3330
|
if (o instanceof File) {
|
|
3284
3331
|
let e = URL.createObjectURL(o);
|
|
3285
|
-
return
|
|
3332
|
+
return y(e), () => URL.revokeObjectURL(e);
|
|
3286
3333
|
}
|
|
3287
|
-
|
|
3334
|
+
y(o?.url || null);
|
|
3288
3335
|
}, [o]);
|
|
3289
3336
|
function S(e) {
|
|
3290
3337
|
let t = e.target.files?.[0];
|
|
3291
3338
|
if (e.target.value = "", !t) return;
|
|
3292
|
-
let n =
|
|
3339
|
+
let n = q(t, {
|
|
3293
3340
|
accept: u,
|
|
3294
3341
|
maxSizeMb: d
|
|
3295
3342
|
});
|
|
3296
3343
|
if (n) {
|
|
3297
|
-
|
|
3344
|
+
x(n);
|
|
3298
3345
|
return;
|
|
3299
3346
|
}
|
|
3300
|
-
|
|
3347
|
+
x(""), l(t);
|
|
3301
3348
|
}
|
|
3302
3349
|
function C() {
|
|
3303
|
-
|
|
3350
|
+
x(""), l(null);
|
|
3304
3351
|
}
|
|
3305
|
-
let
|
|
3352
|
+
let T = o instanceof File ? o.name : o?.name, E = o instanceof File ? `${(o.size / 1024).toFixed(0)} KB` : null, O = p || b;
|
|
3306
3353
|
return /* @__PURE__ */ n("div", {
|
|
3307
3354
|
className: "field",
|
|
3308
3355
|
children: [
|
|
3309
3356
|
/* @__PURE__ */ n("label", {
|
|
3310
3357
|
className: "label",
|
|
3311
|
-
htmlFor:
|
|
3358
|
+
htmlFor: _,
|
|
3312
3359
|
children: [r, f && /* @__PURE__ */ t("span", {
|
|
3313
3360
|
className: "label-optional",
|
|
3314
3361
|
children: " (optional)"
|
|
@@ -3319,14 +3366,14 @@ function Ge({ label: r = "Attachment", value: o, name: s, onChange: l, accept: u
|
|
|
3319
3366
|
children: [/* @__PURE__ */ n("div", {
|
|
3320
3367
|
className: "attach-figure",
|
|
3321
3368
|
children: [/* @__PURE__ */ t("img", {
|
|
3322
|
-
src:
|
|
3323
|
-
alt:
|
|
3369
|
+
src: v,
|
|
3370
|
+
alt: T
|
|
3324
3371
|
}), /* @__PURE__ */ t("button", {
|
|
3325
3372
|
type: "button",
|
|
3326
3373
|
className: "attach-remove",
|
|
3327
3374
|
"aria-label": "Remove attachment",
|
|
3328
3375
|
onClick: C,
|
|
3329
|
-
children: /* @__PURE__ */ t(
|
|
3376
|
+
children: /* @__PURE__ */ t(D, {
|
|
3330
3377
|
name: "x",
|
|
3331
3378
|
size: 18
|
|
3332
3379
|
})
|
|
@@ -3335,19 +3382,19 @@ function Ge({ label: r = "Attachment", value: o, name: s, onChange: l, accept: u
|
|
|
3335
3382
|
className: "attach-meta",
|
|
3336
3383
|
children: [/* @__PURE__ */ t("div", {
|
|
3337
3384
|
className: "attach-name",
|
|
3338
|
-
children: w
|
|
3339
|
-
}), T && /* @__PURE__ */ t("div", {
|
|
3340
|
-
className: "attach-size",
|
|
3341
3385
|
children: T
|
|
3386
|
+
}), E && /* @__PURE__ */ t("div", {
|
|
3387
|
+
className: "attach-size",
|
|
3388
|
+
children: E
|
|
3342
3389
|
})]
|
|
3343
3390
|
})]
|
|
3344
3391
|
}) : /* @__PURE__ */ n(e, { children: [/* @__PURE__ */ n("label", {
|
|
3345
3392
|
className: "attach-drop",
|
|
3346
|
-
htmlFor:
|
|
3393
|
+
htmlFor: _,
|
|
3347
3394
|
children: [
|
|
3348
3395
|
/* @__PURE__ */ t("span", {
|
|
3349
3396
|
className: "attach-drop-icon",
|
|
3350
|
-
children: /* @__PURE__ */ t(
|
|
3397
|
+
children: /* @__PURE__ */ t(D, {
|
|
3351
3398
|
name: "image",
|
|
3352
3399
|
size: 18
|
|
3353
3400
|
})
|
|
@@ -3372,78 +3419,79 @@ function Ge({ label: r = "Attachment", value: o, name: s, onChange: l, accept: u
|
|
|
3372
3419
|
})
|
|
3373
3420
|
]
|
|
3374
3421
|
}), /* @__PURE__ */ t("input", {
|
|
3375
|
-
id:
|
|
3422
|
+
id: _,
|
|
3376
3423
|
type: "file",
|
|
3377
3424
|
className: "visually-hidden-input",
|
|
3378
3425
|
name: s,
|
|
3379
3426
|
accept: u,
|
|
3380
3427
|
onChange: S
|
|
3381
3428
|
})] }),
|
|
3382
|
-
|
|
3429
|
+
O && /* @__PURE__ */ t("div", {
|
|
3383
3430
|
className: "field-error",
|
|
3384
|
-
children:
|
|
3431
|
+
children: O
|
|
3385
3432
|
})
|
|
3386
3433
|
]
|
|
3387
3434
|
});
|
|
3388
3435
|
}
|
|
3389
3436
|
//#endregion
|
|
3390
3437
|
//#region src/components/toast.js
|
|
3391
|
-
var
|
|
3438
|
+
var Qe = /* @__PURE__ */ new Set([
|
|
3392
3439
|
"success",
|
|
3393
3440
|
"info",
|
|
3394
3441
|
"warning",
|
|
3395
3442
|
"error"
|
|
3396
3443
|
]);
|
|
3397
3444
|
function $(e, t = "success") {
|
|
3398
|
-
let n =
|
|
3445
|
+
let n = Qe.has(t) ? t : "success";
|
|
3399
3446
|
_[n](e, { toastId: `${n}:${e}` });
|
|
3400
3447
|
}
|
|
3401
|
-
function
|
|
3448
|
+
function $e(e) {
|
|
3402
3449
|
_.error(e, { toastId: `error:${e}` });
|
|
3403
3450
|
}
|
|
3404
3451
|
//#endregion
|
|
3405
3452
|
//#region src/components/AppFilePicker.jsx
|
|
3406
|
-
function
|
|
3407
|
-
|
|
3453
|
+
function et({ label: e, value: r, name: o, onPick: l, accept: u = ".jpg,.jpeg,.png", maxSizeMb: d = 5, required: f, error: p, ...m }) {
|
|
3454
|
+
w("AppFilePicker", m);
|
|
3455
|
+
let [h, g] = c(null), [_, v] = c(!1), y = s(null), b = a(), x = o || b;
|
|
3408
3456
|
i(() => {
|
|
3409
3457
|
if (r instanceof File) {
|
|
3410
3458
|
let e = URL.createObjectURL(r);
|
|
3411
|
-
return
|
|
3459
|
+
return g(e), () => URL.revokeObjectURL(e);
|
|
3412
3460
|
}
|
|
3413
|
-
|
|
3461
|
+
g(null);
|
|
3414
3462
|
}, [r]);
|
|
3415
|
-
let S = r?.url ||
|
|
3416
|
-
let t =
|
|
3463
|
+
let S = r?.url || h, C = (e) => {
|
|
3464
|
+
let t = q(e, {
|
|
3417
3465
|
accept: u,
|
|
3418
3466
|
maxSizeMb: d
|
|
3419
3467
|
});
|
|
3420
3468
|
return t ? ($(t, "error"), !1) : (l(e), !0);
|
|
3421
|
-
},
|
|
3469
|
+
}, T = (e) => {
|
|
3422
3470
|
let t = e.target.files?.[0] || null;
|
|
3423
3471
|
t && (C(t) || (e.target.value = ""));
|
|
3424
|
-
},
|
|
3425
|
-
e.preventDefault(),
|
|
3472
|
+
}, E = (e) => {
|
|
3473
|
+
e.preventDefault(), v(!1);
|
|
3426
3474
|
let t = e.dataTransfer.files?.[0];
|
|
3427
3475
|
t && C(t);
|
|
3428
|
-
},
|
|
3429
|
-
id:
|
|
3476
|
+
}, O = () => y.current?.click(), k = /* @__PURE__ */ t("input", {
|
|
3477
|
+
id: x,
|
|
3430
3478
|
name: o,
|
|
3431
|
-
ref:
|
|
3479
|
+
ref: y,
|
|
3432
3480
|
type: "file",
|
|
3433
3481
|
accept: u,
|
|
3434
3482
|
hidden: !0,
|
|
3435
3483
|
onClick: (e) => {
|
|
3436
3484
|
e.currentTarget.value = "";
|
|
3437
3485
|
},
|
|
3438
|
-
onChange:
|
|
3486
|
+
onChange: T
|
|
3439
3487
|
});
|
|
3440
3488
|
return /* @__PURE__ */ n("div", {
|
|
3441
3489
|
className: "field",
|
|
3442
3490
|
children: [
|
|
3443
3491
|
/* @__PURE__ */ n("label", {
|
|
3444
3492
|
className: "label",
|
|
3445
|
-
htmlFor:
|
|
3446
|
-
children: [e, f && /* @__PURE__ */ t(
|
|
3493
|
+
htmlFor: x,
|
|
3494
|
+
children: [e, f && /* @__PURE__ */ t(Y, {})]
|
|
3447
3495
|
}),
|
|
3448
3496
|
S ? /* @__PURE__ */ n("div", {
|
|
3449
3497
|
className: `file-preview${p ? " error" : ""}`,
|
|
@@ -3452,7 +3500,7 @@ function Je({ label: e, value: r, name: o, onPick: l, accept: u = ".jpg,.jpeg,.p
|
|
|
3452
3500
|
type: "button",
|
|
3453
3501
|
className: "file-preview-open",
|
|
3454
3502
|
"aria-label": `Change ${e}`,
|
|
3455
|
-
onClick:
|
|
3503
|
+
onClick: O,
|
|
3456
3504
|
children: [/* @__PURE__ */ t("img", {
|
|
3457
3505
|
src: S,
|
|
3458
3506
|
alt: `${e} preview`,
|
|
@@ -3461,7 +3509,7 @@ function Je({ label: e, value: r, name: o, onPick: l, accept: u = ".jpg,.jpeg,.p
|
|
|
3461
3509
|
className: "file-preview-overlay",
|
|
3462
3510
|
children: /* @__PURE__ */ n("span", {
|
|
3463
3511
|
className: "file-preview-cta",
|
|
3464
|
-
children: [/* @__PURE__ */ t(
|
|
3512
|
+
children: [/* @__PURE__ */ t(D, {
|
|
3465
3513
|
name: "image",
|
|
3466
3514
|
size: 16
|
|
3467
3515
|
}), " Change image"]
|
|
@@ -3474,29 +3522,29 @@ function Je({ label: e, value: r, name: o, onPick: l, accept: u = ".jpg,.jpeg,.p
|
|
|
3474
3522
|
"aria-label": `Remove ${e}`,
|
|
3475
3523
|
title: "Remove image",
|
|
3476
3524
|
onClick: () => l(null),
|
|
3477
|
-
children: /* @__PURE__ */ t(
|
|
3525
|
+
children: /* @__PURE__ */ t(D, {
|
|
3478
3526
|
name: "x",
|
|
3479
3527
|
size: 16
|
|
3480
3528
|
})
|
|
3481
3529
|
}),
|
|
3482
|
-
|
|
3530
|
+
k
|
|
3483
3531
|
]
|
|
3484
3532
|
}) : /* @__PURE__ */ n("div", {
|
|
3485
|
-
className: `file-input file-input-tall${
|
|
3533
|
+
className: `file-input file-input-tall${_ ? " dragging" : ""}${p ? " error" : ""}`,
|
|
3486
3534
|
onDragOver: (e) => {
|
|
3487
|
-
e.preventDefault(),
|
|
3535
|
+
e.preventDefault(), _ || v(!0);
|
|
3488
3536
|
},
|
|
3489
3537
|
onDragLeave: (e) => {
|
|
3490
|
-
e.preventDefault(),
|
|
3538
|
+
e.preventDefault(), v(!1);
|
|
3491
3539
|
},
|
|
3492
|
-
onDrop:
|
|
3540
|
+
onDrop: E,
|
|
3493
3541
|
children: [/* @__PURE__ */ n("label", {
|
|
3494
|
-
htmlFor:
|
|
3542
|
+
htmlFor: x,
|
|
3495
3543
|
className: "file-input-zone-label",
|
|
3496
3544
|
children: [
|
|
3497
3545
|
/* @__PURE__ */ t("span", {
|
|
3498
3546
|
className: "file-input-icon",
|
|
3499
|
-
children: /* @__PURE__ */ t(
|
|
3547
|
+
children: /* @__PURE__ */ t(D, {
|
|
3500
3548
|
name: "upload",
|
|
3501
3549
|
size: 24
|
|
3502
3550
|
})
|
|
@@ -3517,7 +3565,7 @@ function Je({ label: e, value: r, name: o, onPick: l, accept: u = ".jpg,.jpeg,.p
|
|
|
3517
3565
|
]
|
|
3518
3566
|
})
|
|
3519
3567
|
]
|
|
3520
|
-
}),
|
|
3568
|
+
}), k]
|
|
3521
3569
|
}),
|
|
3522
3570
|
p && /* @__PURE__ */ t("div", {
|
|
3523
3571
|
className: "field-error",
|
|
@@ -3528,13 +3576,13 @@ function Je({ label: e, value: r, name: o, onPick: l, accept: u = ".jpg,.jpeg,.p
|
|
|
3528
3576
|
}
|
|
3529
3577
|
//#endregion
|
|
3530
3578
|
//#region src/components/AppInfoList.jsx
|
|
3531
|
-
function
|
|
3532
|
-
return /* @__PURE__ */ t("div", {
|
|
3579
|
+
function tt({ items: r = [], className: i = "", ...a }) {
|
|
3580
|
+
return w("AppInfoList", a), /* @__PURE__ */ t("div", {
|
|
3533
3581
|
className: `info-list${i ? ` ${i}` : ""}`,
|
|
3534
3582
|
children: r.map((r, i) => {
|
|
3535
3583
|
let a = /* @__PURE__ */ n(e, { children: [/* @__PURE__ */ t("span", {
|
|
3536
3584
|
className: "info-icon",
|
|
3537
|
-
children: /* @__PURE__ */ t(
|
|
3585
|
+
children: /* @__PURE__ */ t(D, {
|
|
3538
3586
|
name: r.icon,
|
|
3539
3587
|
size: 16
|
|
3540
3588
|
})
|
|
@@ -3561,14 +3609,15 @@ function Ye({ items: r = [], className: i = "" }) {
|
|
|
3561
3609
|
}
|
|
3562
3610
|
//#endregion
|
|
3563
3611
|
//#region src/components/AppKpiTile.jsx
|
|
3564
|
-
function
|
|
3565
|
-
|
|
3612
|
+
function nt({ label: e, value: r, icon: i, delta: a, deltaDirection: o = "flat", inline: s = !1, className: c = "", ...l }) {
|
|
3613
|
+
w("AppKpiTile", l);
|
|
3614
|
+
let u = `kpi${s ? " kpi-inline" : ""}${c ? ` ${c}` : ""}`, d = o === "up" ? "arrow-up" : o === "down" ? "arrow-down" : null;
|
|
3566
3615
|
return /* @__PURE__ */ n("div", {
|
|
3567
|
-
className:
|
|
3616
|
+
className: u,
|
|
3568
3617
|
children: [
|
|
3569
3618
|
i && /* @__PURE__ */ t("span", {
|
|
3570
3619
|
className: "kpi-icon",
|
|
3571
|
-
children: /* @__PURE__ */ t(
|
|
3620
|
+
children: /* @__PURE__ */ t(D, {
|
|
3572
3621
|
name: i,
|
|
3573
3622
|
size: 20
|
|
3574
3623
|
})
|
|
@@ -3583,8 +3632,8 @@ function Xe({ label: e, value: r, icon: i, delta: a, deltaDirection: o = "flat",
|
|
|
3583
3632
|
}),
|
|
3584
3633
|
a && /* @__PURE__ */ n("div", {
|
|
3585
3634
|
className: `kpi-delta${o === "flat" ? "" : ` ${o}`}`,
|
|
3586
|
-
children: [
|
|
3587
|
-
name:
|
|
3635
|
+
children: [d && /* @__PURE__ */ t(D, {
|
|
3636
|
+
name: d,
|
|
3588
3637
|
size: 13
|
|
3589
3638
|
}), a]
|
|
3590
3639
|
})
|
|
@@ -3593,15 +3642,16 @@ function Xe({ label: e, value: r, icon: i, delta: a, deltaDirection: o = "flat",
|
|
|
3593
3642
|
}
|
|
3594
3643
|
//#endregion
|
|
3595
3644
|
//#region src/components/AppLogoPicker.jsx
|
|
3596
|
-
function
|
|
3597
|
-
|
|
3645
|
+
function rt({ value: r, fallback: i, name: a, onPick: o, loading: c = !1, accept: l = "image/png,image/jpeg", maxSizeMb: u = 5, overlayIcon: d = "image", overlayLabel: f = "Update photo", ariaLabel: p = "Upload photo", ...m }) {
|
|
3646
|
+
w("AppLogoPicker", m);
|
|
3647
|
+
let h = s(null);
|
|
3598
3648
|
return /* @__PURE__ */ n(e, { children: [/* @__PURE__ */ t("button", {
|
|
3599
3649
|
type: "button",
|
|
3600
3650
|
className: "set-uploader",
|
|
3601
3651
|
"aria-busy": c || void 0,
|
|
3602
3652
|
disabled: c,
|
|
3603
3653
|
onClick: () => {
|
|
3604
|
-
c ||
|
|
3654
|
+
c || h.current?.click();
|
|
3605
3655
|
},
|
|
3606
3656
|
"aria-label": p,
|
|
3607
3657
|
children: /* @__PURE__ */ n("span", {
|
|
@@ -3616,21 +3666,21 @@ function Ze({ value: r, fallback: i, name: a, onPick: o, loading: c = !1, accept
|
|
|
3616
3666
|
}), c ? /* @__PURE__ */ t("span", {
|
|
3617
3667
|
className: "set-uploader-overlay is-loading",
|
|
3618
3668
|
"aria-hidden": "true",
|
|
3619
|
-
children: /* @__PURE__ */ t(
|
|
3669
|
+
children: /* @__PURE__ */ t(D, {
|
|
3620
3670
|
name: "refresh-cw",
|
|
3621
3671
|
size: 22,
|
|
3622
3672
|
className: "lx-spin"
|
|
3623
3673
|
})
|
|
3624
3674
|
}) : /* @__PURE__ */ n("span", {
|
|
3625
3675
|
className: "set-uploader-overlay",
|
|
3626
|
-
children: [/* @__PURE__ */ t(
|
|
3676
|
+
children: [/* @__PURE__ */ t(D, {
|
|
3627
3677
|
name: d,
|
|
3628
3678
|
size: 22
|
|
3629
3679
|
}), /* @__PURE__ */ t("span", { children: f })]
|
|
3630
3680
|
})]
|
|
3631
3681
|
})
|
|
3632
3682
|
}), /* @__PURE__ */ t("input", {
|
|
3633
|
-
ref:
|
|
3683
|
+
ref: h,
|
|
3634
3684
|
type: "file",
|
|
3635
3685
|
name: a,
|
|
3636
3686
|
hidden: !0,
|
|
@@ -3638,7 +3688,7 @@ function Ze({ value: r, fallback: i, name: a, onPick: o, loading: c = !1, accept
|
|
|
3638
3688
|
onChange: (e) => {
|
|
3639
3689
|
let t = e.target.files?.[0];
|
|
3640
3690
|
if (e.target.value = "", !t) return;
|
|
3641
|
-
let n =
|
|
3691
|
+
let n = q(t, {
|
|
3642
3692
|
accept: l,
|
|
3643
3693
|
maxSizeMb: u
|
|
3644
3694
|
});
|
|
@@ -3653,18 +3703,19 @@ function Ze({ value: r, fallback: i, name: a, onPick: o, loading: c = !1, accept
|
|
|
3653
3703
|
}
|
|
3654
3704
|
//#endregion
|
|
3655
3705
|
//#region src/components/AppMultiSelect.jsx
|
|
3656
|
-
function
|
|
3657
|
-
|
|
3706
|
+
function it({ values: e, onChange: r, options: a, placeholder: o = "Select…", searchPlaceholder: c = "Search…", searchable: l = !0, disabled: u = !1, name: d, label: f, error: p, hint: m, required: h = !1, fieldClassName: g = "", ..._ }) {
|
|
3707
|
+
w("AppMultiSelect", _);
|
|
3708
|
+
let v = s(null);
|
|
3658
3709
|
return i(() => {
|
|
3659
|
-
let e =
|
|
3710
|
+
let e = v.current;
|
|
3660
3711
|
e && (e.options = a || []);
|
|
3661
3712
|
}, [a]), i(() => {
|
|
3662
|
-
let t =
|
|
3713
|
+
let t = v.current;
|
|
3663
3714
|
if (!t) return;
|
|
3664
3715
|
let n = e || [], r = t.values || [];
|
|
3665
3716
|
n.join(",") !== r.join(",") && (t.values = n);
|
|
3666
3717
|
}, [e]), i(() => {
|
|
3667
|
-
let e =
|
|
3718
|
+
let e = v.current;
|
|
3668
3719
|
if (!e) return;
|
|
3669
3720
|
let t = () => r?.(e.values);
|
|
3670
3721
|
return e.addEventListener("change", t), () => e.removeEventListener("change", t);
|
|
@@ -3674,17 +3725,18 @@ function Qe({ values: e, onChange: r, options: a, placeholder: o = "Select…",
|
|
|
3674
3725
|
f && /* @__PURE__ */ n("label", {
|
|
3675
3726
|
className: "label",
|
|
3676
3727
|
htmlFor: d,
|
|
3677
|
-
children: [f, h && /* @__PURE__ */ t(
|
|
3728
|
+
children: [f, h && /* @__PURE__ */ t(Y, {})]
|
|
3678
3729
|
}),
|
|
3679
3730
|
/* @__PURE__ */ t("wui-multiselect", {
|
|
3680
3731
|
"aria-label": typeof f == "string" ? f : void 0,
|
|
3681
3732
|
id: d,
|
|
3682
|
-
ref:
|
|
3733
|
+
ref: v,
|
|
3683
3734
|
name: d,
|
|
3684
3735
|
placeholder: o,
|
|
3685
3736
|
"search-placeholder": c,
|
|
3686
3737
|
searchable: l ? "" : void 0,
|
|
3687
|
-
disabled: u ? "" : void 0
|
|
3738
|
+
disabled: u ? "" : void 0,
|
|
3739
|
+
required: h ? "" : void 0
|
|
3688
3740
|
}),
|
|
3689
3741
|
p ? /* @__PURE__ */ t("div", {
|
|
3690
3742
|
className: "field-error",
|
|
@@ -3698,8 +3750,8 @@ function Qe({ values: e, onChange: r, options: a, placeholder: o = "Select…",
|
|
|
3698
3750
|
}
|
|
3699
3751
|
//#endregion
|
|
3700
3752
|
//#region src/components/AppPageHeader.jsx
|
|
3701
|
-
function
|
|
3702
|
-
return /* @__PURE__ */ n("div", {
|
|
3753
|
+
function at({ title: e, subtitle: r, actions: i, className: a = "", ...o }) {
|
|
3754
|
+
return w("AppPageHeader", o), /* @__PURE__ */ n("div", {
|
|
3703
3755
|
className: `page-header${i ? " d-flex align-items-end justify-content-between" : ""}${a ? ` ${a}` : ""}`,
|
|
3704
3756
|
children: [/* @__PURE__ */ n("div", { children: [/* @__PURE__ */ t("div", {
|
|
3705
3757
|
className: "page-title",
|
|
@@ -3715,13 +3767,14 @@ function $e({ title: e, subtitle: r, actions: i, className: a = "" }) {
|
|
|
3715
3767
|
}
|
|
3716
3768
|
//#endregion
|
|
3717
3769
|
//#region src/components/AppPhoneNumberInput.jsx
|
|
3718
|
-
function
|
|
3719
|
-
|
|
3770
|
+
function ot({ value: e, onChange: r, country: a, disabled: o = !1, name: c, label: l = "Phone number", placeholder: u = "Enter phone number", required: d = !1, error: f, fieldClassName: p = "", ...m }) {
|
|
3771
|
+
w("AppPhoneNumberInput", m);
|
|
3772
|
+
let h = s(null);
|
|
3720
3773
|
return i(() => {
|
|
3721
|
-
let t =
|
|
3774
|
+
let t = h.current;
|
|
3722
3775
|
t && t.value !== (e ?? "") && (t.value = e ?? "");
|
|
3723
3776
|
}, [e]), i(() => {
|
|
3724
|
-
let e =
|
|
3777
|
+
let e = h.current;
|
|
3725
3778
|
if (!e) return;
|
|
3726
3779
|
let t = () => r?.(e.value);
|
|
3727
3780
|
return e.addEventListener("change", t), () => e.removeEventListener("change", t);
|
|
@@ -3731,10 +3784,10 @@ function et({ value: e, onChange: r, country: a, disabled: o = !1, name: c, labe
|
|
|
3731
3784
|
l && /* @__PURE__ */ n("label", {
|
|
3732
3785
|
className: "label",
|
|
3733
3786
|
htmlFor: c,
|
|
3734
|
-
children: [l, d && /* @__PURE__ */ t(
|
|
3787
|
+
children: [l, d && /* @__PURE__ */ t(Y, {})]
|
|
3735
3788
|
}),
|
|
3736
3789
|
/* @__PURE__ */ t("wui-phone", {
|
|
3737
|
-
ref:
|
|
3790
|
+
ref: h,
|
|
3738
3791
|
name: c,
|
|
3739
3792
|
country: a,
|
|
3740
3793
|
placeholder: u,
|
|
@@ -3749,8 +3802,8 @@ function et({ value: e, onChange: r, country: a, disabled: o = !1, name: c, labe
|
|
|
3749
3802
|
}
|
|
3750
3803
|
//#endregion
|
|
3751
3804
|
//#region src/components/AppPricingCard.jsx
|
|
3752
|
-
function
|
|
3753
|
-
return /* @__PURE__ */ n("div", {
|
|
3805
|
+
function st({ name: e, price: r, unit: i, tagline: a, features: o = [], cta: s, featured: c = !1, current: l = !1, badge: u = "Most popular", className: d = "", ...f }) {
|
|
3806
|
+
return w("AppPricingCard", f), /* @__PURE__ */ n("div", {
|
|
3754
3807
|
className: [
|
|
3755
3808
|
"plan-card",
|
|
3756
3809
|
c ? "featured" : "",
|
|
@@ -3785,7 +3838,7 @@ function tt({ name: e, price: r, unit: i, tagline: a, features: o = [], cta: s,
|
|
|
3785
3838
|
className: r ? void 0 : "excluded",
|
|
3786
3839
|
children: [/* @__PURE__ */ t("span", {
|
|
3787
3840
|
className: "plan-feature-icon",
|
|
3788
|
-
children: /* @__PURE__ */ t(
|
|
3841
|
+
children: /* @__PURE__ */ t(D, {
|
|
3789
3842
|
name: r ? "check" : "x",
|
|
3790
3843
|
size: 16
|
|
3791
3844
|
})
|
|
@@ -3802,7 +3855,8 @@ function tt({ name: e, price: r, unit: i, tagline: a, features: o = [], cta: s,
|
|
|
3802
3855
|
}
|
|
3803
3856
|
//#endregion
|
|
3804
3857
|
//#region src/components/AppRadio.jsx
|
|
3805
|
-
var
|
|
3858
|
+
var ct = r(function({ label: e, id: r, name: i, className: o = "", ...s }, c) {
|
|
3859
|
+
w("AppRadio", s);
|
|
3806
3860
|
let l = a(), u = r || i || l;
|
|
3807
3861
|
return /* @__PURE__ */ n("div", {
|
|
3808
3862
|
className: `form-check${o ? ` ${o}` : ""}`,
|
|
@@ -3822,8 +3876,9 @@ var nt = r(function({ label: e, id: r, name: i, className: o = "", ...s }, c) {
|
|
|
3822
3876
|
});
|
|
3823
3877
|
//#endregion
|
|
3824
3878
|
//#region src/components/AppRepeater.jsx
|
|
3825
|
-
function
|
|
3826
|
-
|
|
3879
|
+
function lt({ rows: e = [], renderRow: r, onAdd: i, onRemove: a, addLabel: o = "Add another", removeLabel: s = "Remove row", emptyText: c, min: l = 0, max: u, numbered: d = !0, className: f = "", ...p }) {
|
|
3880
|
+
w("AppRepeater", p);
|
|
3881
|
+
let m = typeof u == "number" && e.length >= u, h = !!a && e.length > l;
|
|
3827
3882
|
return /* @__PURE__ */ n("div", {
|
|
3828
3883
|
className: `repeater${f ? ` ${f}` : ""}`,
|
|
3829
3884
|
children: [
|
|
@@ -3842,7 +3897,7 @@ function rt({ rows: e = [], renderRow: r, onAdd: i, onRemove: a, addLabel: o = "
|
|
|
3842
3897
|
className: "repeater-body",
|
|
3843
3898
|
children: r(e, i)
|
|
3844
3899
|
}),
|
|
3845
|
-
|
|
3900
|
+
h && /* @__PURE__ */ t(O, {
|
|
3846
3901
|
icon: "trash-2",
|
|
3847
3902
|
label: `${s} ${i + 1}`,
|
|
3848
3903
|
danger: !0,
|
|
@@ -3851,16 +3906,12 @@ function rt({ rows: e = [], renderRow: r, onAdd: i, onRemove: a, addLabel: o = "
|
|
|
3851
3906
|
})
|
|
3852
3907
|
]
|
|
3853
3908
|
}, e.id ?? i)),
|
|
3854
|
-
/* @__PURE__ */ t(
|
|
3909
|
+
/* @__PURE__ */ t(X, {
|
|
3855
3910
|
variant: "secondary",
|
|
3856
3911
|
size: "sm",
|
|
3857
|
-
leftIcon:
|
|
3858
|
-
name: "plus",
|
|
3859
|
-
size: 14,
|
|
3860
|
-
className: "me-1"
|
|
3861
|
-
}),
|
|
3912
|
+
leftIcon: "plus",
|
|
3862
3913
|
className: "repeater-add",
|
|
3863
|
-
disabled:
|
|
3914
|
+
disabled: m,
|
|
3864
3915
|
onClick: i,
|
|
3865
3916
|
children: o
|
|
3866
3917
|
})
|
|
@@ -3869,10 +3920,11 @@ function rt({ rows: e = [], renderRow: r, onAdd: i, onRemove: a, addLabel: o = "
|
|
|
3869
3920
|
}
|
|
3870
3921
|
//#endregion
|
|
3871
3922
|
//#region src/components/AppResourceCard.jsx
|
|
3872
|
-
function
|
|
3873
|
-
|
|
3923
|
+
function ut({ icon: r, title: i, text: a, href: o, external: s = !1, linkComponent: c, className: l = "", ...u }) {
|
|
3924
|
+
w("AppResourceCard", u);
|
|
3925
|
+
let d = /* @__PURE__ */ n(e, { children: [/* @__PURE__ */ t("span", {
|
|
3874
3926
|
className: "res-card-icon",
|
|
3875
|
-
children: /* @__PURE__ */ t(
|
|
3927
|
+
children: /* @__PURE__ */ t(D, {
|
|
3876
3928
|
name: r,
|
|
3877
3929
|
size: 18
|
|
3878
3930
|
})
|
|
@@ -3885,30 +3937,30 @@ function it({ icon: r, title: i, text: a, href: o, external: s = !1, linkCompone
|
|
|
3885
3937
|
className: "res-card-text",
|
|
3886
3938
|
children: a
|
|
3887
3939
|
})]
|
|
3888
|
-
})] }),
|
|
3940
|
+
})] }), f = `res-card${l ? ` ${l}` : ""}`;
|
|
3889
3941
|
return c && !s ? /* @__PURE__ */ t(c, {
|
|
3890
|
-
className:
|
|
3942
|
+
className: f,
|
|
3891
3943
|
to: o,
|
|
3892
|
-
children:
|
|
3944
|
+
children: d
|
|
3893
3945
|
}) : /* @__PURE__ */ t("a", {
|
|
3894
|
-
className:
|
|
3946
|
+
className: f,
|
|
3895
3947
|
href: o,
|
|
3896
3948
|
target: s ? "_blank" : void 0,
|
|
3897
3949
|
rel: s ? "noopener noreferrer" : void 0,
|
|
3898
|
-
children:
|
|
3950
|
+
children: d
|
|
3899
3951
|
});
|
|
3900
3952
|
}
|
|
3901
3953
|
//#endregion
|
|
3902
3954
|
//#region src/components/AppSearch.jsx
|
|
3903
|
-
function
|
|
3904
|
-
return /* @__PURE__ */ n("div", {
|
|
3955
|
+
function dt({ value: e, onValueChange: r, placeholder: i, ariaLabel: a, iconSize: o = 18, className: s = "", ...c }) {
|
|
3956
|
+
return w("AppSearch", c), /* @__PURE__ */ n("div", {
|
|
3905
3957
|
className: [
|
|
3906
3958
|
"search-wrap",
|
|
3907
3959
|
e ? "has-value" : "",
|
|
3908
3960
|
s
|
|
3909
3961
|
].filter(Boolean).join(" "),
|
|
3910
3962
|
children: [
|
|
3911
|
-
/* @__PURE__ */ t(
|
|
3963
|
+
/* @__PURE__ */ t(D, {
|
|
3912
3964
|
name: "search",
|
|
3913
3965
|
size: o,
|
|
3914
3966
|
className: "search-icon"
|
|
@@ -3927,7 +3979,7 @@ function at({ value: e, onValueChange: r, placeholder: i, ariaLabel: a, iconSize
|
|
|
3927
3979
|
className: "search-clear",
|
|
3928
3980
|
"aria-label": "Clear search",
|
|
3929
3981
|
onClick: () => r(""),
|
|
3930
|
-
children: /* @__PURE__ */ t(
|
|
3982
|
+
children: /* @__PURE__ */ t(D, {
|
|
3931
3983
|
name: "x",
|
|
3932
3984
|
size: 16
|
|
3933
3985
|
})
|
|
@@ -3937,8 +3989,9 @@ function at({ value: e, onValueChange: r, placeholder: i, ariaLabel: a, iconSize
|
|
|
3937
3989
|
}
|
|
3938
3990
|
//#endregion
|
|
3939
3991
|
//#region src/components/AppSegmented.jsx
|
|
3940
|
-
function
|
|
3941
|
-
|
|
3992
|
+
function ft({ options: e = [], value: r, onChange: i, label: o, name: s, size: c = "md", className: l = "", ...u }) {
|
|
3993
|
+
w("AppSegmented", u);
|
|
3994
|
+
let d = a(), f = s || d;
|
|
3942
3995
|
return /* @__PURE__ */ t("div", {
|
|
3943
3996
|
className: `segmented${c === "sm" ? " segmented-sm" : ""}${l ? ` ${l}` : ""}`,
|
|
3944
3997
|
role: "radiogroup",
|
|
@@ -3949,12 +4002,12 @@ function ot({ options: e = [], value: r, onChange: i, label: o, name: s, size: c
|
|
|
3949
4002
|
/* @__PURE__ */ t("input", {
|
|
3950
4003
|
type: "radio",
|
|
3951
4004
|
className: "segmented-input",
|
|
3952
|
-
name:
|
|
4005
|
+
name: f,
|
|
3953
4006
|
value: e.value,
|
|
3954
4007
|
checked: e.value === r,
|
|
3955
4008
|
onChange: () => i?.(e.value)
|
|
3956
4009
|
}),
|
|
3957
|
-
e.icon && /* @__PURE__ */ t(
|
|
4010
|
+
e.icon && /* @__PURE__ */ t(D, {
|
|
3958
4011
|
name: e.icon,
|
|
3959
4012
|
size: 13
|
|
3960
4013
|
}),
|
|
@@ -3965,51 +4018,53 @@ function ot({ options: e = [], value: r, onChange: i, label: o, name: s, size: c
|
|
|
3965
4018
|
}
|
|
3966
4019
|
//#endregion
|
|
3967
4020
|
//#region src/components/AppSelect.jsx
|
|
3968
|
-
var
|
|
3969
|
-
function
|
|
3970
|
-
|
|
4021
|
+
var pt = (e) => e == null ? "" : e.label ?? e.text ?? "";
|
|
4022
|
+
function mt({ value: e, onChange: r, options: a = [], placeholder: o = "Select...", searchPlaceholder: c = "Search...", searchable: l = !1, disabled: u, label: d, required: f = !1, error: p, hint: m, help: h, helpLabel: g = "More information", id: _, name: v, fieldClassName: y = "", ...b }) {
|
|
4023
|
+
w("AppSelect", b);
|
|
4024
|
+
let x = s(null);
|
|
3971
4025
|
i(() => {
|
|
3972
|
-
|
|
4026
|
+
x.current && (x.current.options = a.map((e) => ({
|
|
3973
4027
|
value: e.value,
|
|
3974
|
-
label:
|
|
4028
|
+
label: pt(e)
|
|
3975
4029
|
})));
|
|
3976
4030
|
}, [a]), i(() => {
|
|
3977
|
-
let t =
|
|
4031
|
+
let t = x.current;
|
|
3978
4032
|
t && String(t.value ?? "") !== String(e ?? "") && (t.value = e ?? "");
|
|
3979
4033
|
}, [e]), i(() => {
|
|
3980
|
-
let e =
|
|
4034
|
+
let e = x.current;
|
|
3981
4035
|
if (!e) return;
|
|
3982
4036
|
let t = () => r?.(e.value);
|
|
3983
4037
|
return e.addEventListener("change", t), () => e.removeEventListener("change", t);
|
|
3984
4038
|
}, [r]);
|
|
3985
|
-
let
|
|
4039
|
+
let S = /* @__PURE__ */ t("wui-select", {
|
|
3986
4040
|
"aria-label": typeof d == "string" ? d : void 0,
|
|
3987
|
-
ref:
|
|
4041
|
+
ref: x,
|
|
3988
4042
|
id: _ || v,
|
|
3989
4043
|
name: v,
|
|
3990
4044
|
placeholder: o,
|
|
3991
4045
|
"search-placeholder": c,
|
|
3992
4046
|
searchable: l ? "" : void 0,
|
|
3993
|
-
disabled: u ? "" : void 0
|
|
4047
|
+
disabled: u ? "" : void 0,
|
|
4048
|
+
required: f ? "" : void 0
|
|
3994
4049
|
});
|
|
3995
|
-
if (!d && !p && !m) return
|
|
3996
|
-
let
|
|
4050
|
+
if (!d && !p && !m) return S;
|
|
4051
|
+
let C = _ || v;
|
|
3997
4052
|
return /* @__PURE__ */ n("div", {
|
|
3998
4053
|
className: `field${y ? ` ${y}` : ""}`,
|
|
3999
4054
|
children: [
|
|
4000
4055
|
d && /* @__PURE__ */ n("label", {
|
|
4001
4056
|
className: "label",
|
|
4002
|
-
htmlFor:
|
|
4057
|
+
htmlFor: C,
|
|
4003
4058
|
children: [
|
|
4004
4059
|
d,
|
|
4005
|
-
|
|
4060
|
+
f && /* @__PURE__ */ t(Y, {}),
|
|
4061
|
+
h && /* @__PURE__ */ t(Z, {
|
|
4006
4062
|
label: g,
|
|
4007
4063
|
children: h
|
|
4008
|
-
})
|
|
4009
|
-
f && /* @__PURE__ */ t(G, {})
|
|
4064
|
+
})
|
|
4010
4065
|
]
|
|
4011
4066
|
}),
|
|
4012
|
-
|
|
4067
|
+
S,
|
|
4013
4068
|
p ? /* @__PURE__ */ t("div", {
|
|
4014
4069
|
className: "field-error",
|
|
4015
4070
|
children: p
|
|
@@ -4022,23 +4077,24 @@ function ct({ value: e, onChange: r, options: a = [], placeholder: o = "Select..
|
|
|
4022
4077
|
}
|
|
4023
4078
|
//#endregion
|
|
4024
4079
|
//#region src/components/AppShell.jsx
|
|
4025
|
-
function
|
|
4026
|
-
|
|
4080
|
+
function ht({ groups: e = [], brand: r, sidebarFooter: a, topbarStart: o, topbarEnd: s, footer: l, children: u, collapsed: d, onCollapsedChange: f, noSidebar: p = !1, navLabel: m = "Main navigation", linkComponent: h, className: g = "", ..._ }) {
|
|
4081
|
+
w("AppShell", _);
|
|
4082
|
+
let [v, y] = c(!1), [b, x] = c(!1), [S, C] = c(!1), T = d ?? v;
|
|
4027
4083
|
return i(() => {
|
|
4028
4084
|
let e = () => C(window.scrollY > 4);
|
|
4029
4085
|
return e(), window.addEventListener("scroll", e, { passive: !0 }), () => window.removeEventListener("scroll", e);
|
|
4030
4086
|
}, []), i(() => {
|
|
4031
|
-
if (!
|
|
4087
|
+
if (!b) return;
|
|
4032
4088
|
let e = (e) => {
|
|
4033
|
-
e.key === "Escape" &&
|
|
4089
|
+
e.key === "Escape" && x(!1);
|
|
4034
4090
|
};
|
|
4035
4091
|
return document.addEventListener("keydown", e), () => document.removeEventListener("keydown", e);
|
|
4036
|
-
}, [
|
|
4092
|
+
}, [b]), /* @__PURE__ */ n("div", {
|
|
4037
4093
|
className: [
|
|
4038
4094
|
"app-shell",
|
|
4039
|
-
|
|
4095
|
+
T ? "collapsed" : "",
|
|
4040
4096
|
p ? "no-sidebar" : "",
|
|
4041
|
-
|
|
4097
|
+
b ? "mobile-open" : "",
|
|
4042
4098
|
g
|
|
4043
4099
|
].filter(Boolean).join(" "),
|
|
4044
4100
|
children: [
|
|
@@ -4057,10 +4113,10 @@ function lt({ groups: e = [], brand: r, sidebarFooter: a, topbarStart: o, topbar
|
|
|
4057
4113
|
children: [e.label && /* @__PURE__ */ t("div", {
|
|
4058
4114
|
className: "app-nav-group-label",
|
|
4059
4115
|
children: e.label
|
|
4060
|
-
}), e.items.map((e) => /* @__PURE__ */ t(
|
|
4116
|
+
}), e.items.map((e) => /* @__PURE__ */ t(gt, {
|
|
4061
4117
|
item: e,
|
|
4062
4118
|
linkComponent: h,
|
|
4063
|
-
onNavigate: () =>
|
|
4119
|
+
onNavigate: () => x(!1)
|
|
4064
4120
|
}, e.key ?? e.href))]
|
|
4065
4121
|
}, e.label ?? `group-${r}`))
|
|
4066
4122
|
}),
|
|
@@ -4074,12 +4130,12 @@ function lt({ groups: e = [], brand: r, sidebarFooter: a, topbarStart: o, topbar
|
|
|
4074
4130
|
type: "button",
|
|
4075
4131
|
className: "app-sidebar-toggle",
|
|
4076
4132
|
onClick: () => {
|
|
4077
|
-
let e = !
|
|
4078
|
-
|
|
4133
|
+
let e = !T;
|
|
4134
|
+
y(e), f?.(e);
|
|
4079
4135
|
},
|
|
4080
|
-
"aria-label":
|
|
4081
|
-
"aria-expanded": !
|
|
4082
|
-
children: /* @__PURE__ */ t(
|
|
4136
|
+
"aria-label": T ? "Expand navigation" : "Collapse navigation",
|
|
4137
|
+
"aria-expanded": !T,
|
|
4138
|
+
children: /* @__PURE__ */ t(D, {
|
|
4083
4139
|
name: "chevron-left",
|
|
4084
4140
|
size: 14
|
|
4085
4141
|
})
|
|
@@ -4094,10 +4150,10 @@ function lt({ groups: e = [], brand: r, sidebarFooter: a, topbarStart: o, topbar
|
|
|
4094
4150
|
children: [/* @__PURE__ */ t("button", {
|
|
4095
4151
|
type: "button",
|
|
4096
4152
|
className: "app-topbar-menu",
|
|
4097
|
-
onClick: () =>
|
|
4153
|
+
onClick: () => x(!0),
|
|
4098
4154
|
"aria-label": "Open navigation",
|
|
4099
|
-
"aria-expanded":
|
|
4100
|
-
children: /* @__PURE__ */ t(
|
|
4155
|
+
"aria-expanded": b,
|
|
4156
|
+
children: /* @__PURE__ */ t(D, {
|
|
4101
4157
|
name: "menu",
|
|
4102
4158
|
size: 18
|
|
4103
4159
|
})
|
|
@@ -4120,18 +4176,18 @@ function lt({ groups: e = [], brand: r, sidebarFooter: a, topbarStart: o, topbar
|
|
|
4120
4176
|
/* @__PURE__ */ t("button", {
|
|
4121
4177
|
type: "button",
|
|
4122
4178
|
className: "app-scrim",
|
|
4123
|
-
onClick: () =>
|
|
4179
|
+
onClick: () => x(!1),
|
|
4124
4180
|
"aria-label": "Close navigation",
|
|
4125
|
-
tabIndex:
|
|
4181
|
+
tabIndex: b ? 0 : -1
|
|
4126
4182
|
})
|
|
4127
4183
|
]
|
|
4128
4184
|
});
|
|
4129
4185
|
}
|
|
4130
|
-
function
|
|
4186
|
+
function gt({ item: r, linkComponent: i, onNavigate: a }) {
|
|
4131
4187
|
let o = `app-nav-item${r.active ? " active" : ""}`, s = /* @__PURE__ */ n(e, { children: [
|
|
4132
4188
|
r.icon && /* @__PURE__ */ t("span", {
|
|
4133
4189
|
className: "app-nav-icon",
|
|
4134
|
-
children: /* @__PURE__ */ t(
|
|
4190
|
+
children: /* @__PURE__ */ t(D, {
|
|
4135
4191
|
name: r.icon,
|
|
4136
4192
|
size: 22
|
|
4137
4193
|
})
|
|
@@ -4161,7 +4217,7 @@ function ut({ item: r, linkComponent: i, onNavigate: a }) {
|
|
|
4161
4217
|
}
|
|
4162
4218
|
//#endregion
|
|
4163
4219
|
//#region src/components/AppSidebarMenu.jsx
|
|
4164
|
-
var
|
|
4220
|
+
var _t = {
|
|
4165
4221
|
left: "start",
|
|
4166
4222
|
right: "end",
|
|
4167
4223
|
start: "start",
|
|
@@ -4169,11 +4225,11 @@ var dt = {
|
|
|
4169
4225
|
top: "top",
|
|
4170
4226
|
bottom: "bottom"
|
|
4171
4227
|
};
|
|
4172
|
-
function
|
|
4173
|
-
return /* @__PURE__ */ n(v, {
|
|
4228
|
+
function vt({ show: e, onHide: r, side: i = "right", title: a, titleIcon: o, header: s, children: c, footer: l, width: u, backdrop: d = !0, scroll: f = !1, keyboard: p = !0, closeButton: m = !0, responsive: h, className: g = "", bodyClassName: _ = "", ariaLabel: y, ...b }) {
|
|
4229
|
+
return w("AppSidebarMenu", b), /* @__PURE__ */ n(v, {
|
|
4174
4230
|
show: e,
|
|
4175
4231
|
onHide: r,
|
|
4176
|
-
placement:
|
|
4232
|
+
placement: _t[i] || "end",
|
|
4177
4233
|
backdrop: d,
|
|
4178
4234
|
scroll: f,
|
|
4179
4235
|
keyboard: p,
|
|
@@ -4188,17 +4244,17 @@ function ft({ show: e, onHide: r, side: i = "right", title: a, titleIcon: o, hea
|
|
|
4188
4244
|
className: "drawer-title",
|
|
4189
4245
|
children: [o && /* @__PURE__ */ t("span", {
|
|
4190
4246
|
className: "drawer-title-ic",
|
|
4191
|
-
children: /* @__PURE__ */ t(
|
|
4247
|
+
children: /* @__PURE__ */ t(D, {
|
|
4192
4248
|
name: o,
|
|
4193
4249
|
size: 18
|
|
4194
4250
|
})
|
|
4195
4251
|
}), a]
|
|
4196
|
-
}), m && /* @__PURE__ */ t(
|
|
4252
|
+
}), m && /* @__PURE__ */ t(X, {
|
|
4197
4253
|
variant: "ghost",
|
|
4198
4254
|
className: "btn-icon",
|
|
4199
4255
|
onClick: r,
|
|
4200
4256
|
"aria-label": "Close",
|
|
4201
|
-
children: /* @__PURE__ */ t(
|
|
4257
|
+
children: /* @__PURE__ */ t(D, {
|
|
4202
4258
|
name: "x",
|
|
4203
4259
|
size: 16
|
|
4204
4260
|
})
|
|
@@ -4217,8 +4273,8 @@ function ft({ show: e, onHide: r, side: i = "right", title: a, titleIcon: o, hea
|
|
|
4217
4273
|
}
|
|
4218
4274
|
//#endregion
|
|
4219
4275
|
//#region src/components/AppSpinner.jsx
|
|
4220
|
-
function
|
|
4221
|
-
return /* @__PURE__ */ t("span", {
|
|
4276
|
+
function yt({ size: e = "md", label: n = "Loading", className: r = "", ...i }) {
|
|
4277
|
+
return w("AppSpinner", i), /* @__PURE__ */ t("span", {
|
|
4222
4278
|
className: `spinner-border${e === "sm" ? " spinner-border-sm" : ""}${r ? ` ${r}` : ""}`,
|
|
4223
4279
|
role: "status",
|
|
4224
4280
|
"aria-label": n
|
|
@@ -4226,8 +4282,8 @@ function pt({ size: e = "md", label: n = "Loading", className: r = "" }) {
|
|
|
4226
4282
|
}
|
|
4227
4283
|
//#endregion
|
|
4228
4284
|
//#region src/components/AppSplash.jsx
|
|
4229
|
-
function
|
|
4230
|
-
return /* @__PURE__ */ t("div", {
|
|
4285
|
+
function bt({ logo: e, initials: r, text: i, label: a = "Loading", className: o = "", ...s }) {
|
|
4286
|
+
return w("AppSplash", s), /* @__PURE__ */ t("div", {
|
|
4231
4287
|
className: `splash${o ? ` ${o}` : ""}`,
|
|
4232
4288
|
role: "status",
|
|
4233
4289
|
"aria-live": "polite",
|
|
@@ -4253,22 +4309,22 @@ function mt({ logo: e, initials: r, text: i, label: a = "Loading", className: o
|
|
|
4253
4309
|
}
|
|
4254
4310
|
//#endregion
|
|
4255
4311
|
//#region src/components/AppStatusBadge.jsx
|
|
4256
|
-
function
|
|
4257
|
-
return e == null || e === "" ? "—" : /* @__PURE__ */ t("span", {
|
|
4312
|
+
function xt({ label: e, tone: n = "neutral", className: r = "", ...i }) {
|
|
4313
|
+
return w("AppStatusBadge", i), e == null || e === "" ? "—" : /* @__PURE__ */ t("span", {
|
|
4258
4314
|
className: `status-label ${n}${r ? ` ${r}` : ""}`,
|
|
4259
4315
|
children: e
|
|
4260
4316
|
});
|
|
4261
4317
|
}
|
|
4262
4318
|
//#endregion
|
|
4263
4319
|
//#region src/components/AppStepper.jsx
|
|
4264
|
-
function
|
|
4265
|
-
return /* @__PURE__ */ t("nav", {
|
|
4320
|
+
function St({ steps: r = [], variant: i = "steps", label: a = "Progress", linkComponent: o, className: s = "", ...c }) {
|
|
4321
|
+
return w("AppStepper", c), /* @__PURE__ */ t("nav", {
|
|
4266
4322
|
className: [i === "journey" ? "stepper stepper-journey" : "stepper", s].filter(Boolean).join(" "),
|
|
4267
4323
|
"aria-label": a,
|
|
4268
4324
|
children: r.map((a, s) => {
|
|
4269
4325
|
let c = a.status || "pending", l = `step${c === "pending" ? "" : ` ${c}`}`, u = /* @__PURE__ */ n(e, { children: [/* @__PURE__ */ t("span", {
|
|
4270
4326
|
className: "step-circle",
|
|
4271
|
-
children: c === "done" ? /* @__PURE__ */ t(
|
|
4327
|
+
children: c === "done" ? /* @__PURE__ */ t(D, {
|
|
4272
4328
|
name: "check",
|
|
4273
4329
|
size: 14
|
|
4274
4330
|
}) : s + 1
|
|
@@ -4308,7 +4364,8 @@ function gt({ steps: r = [], variant: i = "steps", label: a = "Progress", linkCo
|
|
|
4308
4364
|
}
|
|
4309
4365
|
//#endregion
|
|
4310
4366
|
//#region src/components/AppSwitch.jsx
|
|
4311
|
-
var
|
|
4367
|
+
var Ct = r(function({ label: e, id: r, name: i, className: o = "", ...s }, c) {
|
|
4368
|
+
w("AppSwitch", s);
|
|
4312
4369
|
let l = a(), u = r || i || l;
|
|
4313
4370
|
return /* @__PURE__ */ n("div", {
|
|
4314
4371
|
className: `form-check form-switch${o ? ` ${o}` : ""}`,
|
|
@@ -4328,13 +4385,13 @@ var _t = r(function({ label: e, id: r, name: i, className: o = "", ...s }, c) {
|
|
|
4328
4385
|
});
|
|
4329
4386
|
//#endregion
|
|
4330
4387
|
//#region src/components/AppTableEmptyState.jsx
|
|
4331
|
-
function
|
|
4332
|
-
return /* @__PURE__ */ n("div", {
|
|
4388
|
+
function wt({ icon: e, title: r, text: i, action: a, ...o }) {
|
|
4389
|
+
return w("AppTableEmptyState", o), /* @__PURE__ */ n("div", {
|
|
4333
4390
|
className: "tbl-empty",
|
|
4334
4391
|
children: [
|
|
4335
4392
|
/* @__PURE__ */ t("span", {
|
|
4336
4393
|
className: "tbl-empty-icon",
|
|
4337
|
-
children: /* @__PURE__ */ t(
|
|
4394
|
+
children: /* @__PURE__ */ t(D, {
|
|
4338
4395
|
name: e,
|
|
4339
4396
|
size: 24
|
|
4340
4397
|
})
|
|
@@ -4356,26 +4413,27 @@ function vt({ icon: e, title: r, text: i, action: a }) {
|
|
|
4356
4413
|
}
|
|
4357
4414
|
//#endregion
|
|
4358
4415
|
//#region src/components/AppTabs.jsx
|
|
4359
|
-
function
|
|
4360
|
-
|
|
4361
|
-
|
|
4416
|
+
function Tt({ tabs: e, value: r, onChange: i, variant: a = "underline", ariaLabel: o, className: c = "", ...l }) {
|
|
4417
|
+
w("AppTabs", l);
|
|
4418
|
+
let u = s(null);
|
|
4419
|
+
function d(t) {
|
|
4362
4420
|
let n = e.findIndex((e) => e.key === r);
|
|
4363
4421
|
if (n < 0) return;
|
|
4364
4422
|
let a = null;
|
|
4365
4423
|
if (t.key === "ArrowRight" ? a = e[(n + 1) % e.length] : t.key === "ArrowLeft" ? a = e[(n - 1 + e.length) % e.length] : t.key === "Home" ? a = e[0] : t.key === "End" && (a = e[e.length - 1]), !a) return;
|
|
4366
4424
|
t.preventDefault(), i(a.key);
|
|
4367
4425
|
let o = CSS.escape(String(a.key));
|
|
4368
|
-
|
|
4426
|
+
u.current?.querySelector(`[data-rr-ui-event-key="${o}"]`)?.focus();
|
|
4369
4427
|
}
|
|
4370
4428
|
return /* @__PURE__ */ t(y, {
|
|
4371
4429
|
as: "div",
|
|
4372
4430
|
role: "tablist",
|
|
4373
|
-
ref:
|
|
4431
|
+
ref: u,
|
|
4374
4432
|
activeKey: r,
|
|
4375
4433
|
onSelect: (e) => {
|
|
4376
4434
|
e != null && i(e);
|
|
4377
4435
|
},
|
|
4378
|
-
onKeyDown:
|
|
4436
|
+
onKeyDown: d,
|
|
4379
4437
|
bsPrefix: "app-tabs",
|
|
4380
4438
|
className: [a === "pills" ? "app-tabs-pills" : "", c].filter(Boolean).join(" "),
|
|
4381
4439
|
"aria-label": o,
|
|
@@ -4399,7 +4457,8 @@ function yt({ tabs: e, value: r, onChange: i, variant: a = "underline", ariaLabe
|
|
|
4399
4457
|
}
|
|
4400
4458
|
//#endregion
|
|
4401
4459
|
//#region src/components/AppTextarea.jsx
|
|
4402
|
-
var
|
|
4460
|
+
var Et = r(function({ label: e, required: r = !1, error: i, hint: a, help: o, helpLabel: s = "More information", id: c, name: l, rows: u = 4, className: d = "", fieldClassName: f = "", ...m }, h) {
|
|
4461
|
+
w("AppTextarea", m);
|
|
4403
4462
|
let g = c || l, _ = [
|
|
4404
4463
|
"textarea",
|
|
4405
4464
|
i ? "error" : "",
|
|
@@ -4413,11 +4472,11 @@ var bt = r(function({ label: e, required: r = !1, error: i, hint: a, help: o, he
|
|
|
4413
4472
|
htmlFor: g,
|
|
4414
4473
|
children: [
|
|
4415
4474
|
e,
|
|
4416
|
-
|
|
4475
|
+
r && /* @__PURE__ */ t(Y, {}),
|
|
4476
|
+
o && /* @__PURE__ */ t(Z, {
|
|
4417
4477
|
label: s,
|
|
4418
4478
|
children: o
|
|
4419
|
-
})
|
|
4420
|
-
r && /* @__PURE__ */ t(G, {})
|
|
4479
|
+
})
|
|
4421
4480
|
]
|
|
4422
4481
|
}),
|
|
4423
4482
|
/* @__PURE__ */ t(p.Control, {
|
|
@@ -4427,6 +4486,7 @@ var bt = r(function({ label: e, required: r = !1, error: i, hint: a, help: o, he
|
|
|
4427
4486
|
rows: u,
|
|
4428
4487
|
className: _,
|
|
4429
4488
|
"aria-invalid": i ? "true" : "false",
|
|
4489
|
+
required: r,
|
|
4430
4490
|
ref: h,
|
|
4431
4491
|
...m
|
|
4432
4492
|
}),
|
|
@@ -4442,14 +4502,14 @@ var bt = r(function({ label: e, required: r = !1, error: i, hint: a, help: o, he
|
|
|
4442
4502
|
});
|
|
4443
4503
|
//#endregion
|
|
4444
4504
|
//#region src/components/AppTimeline.jsx
|
|
4445
|
-
function
|
|
4446
|
-
return /* @__PURE__ */ t("ol", {
|
|
4505
|
+
function Dt({ items: e = [], className: r = "", ...i }) {
|
|
4506
|
+
return w("AppTimeline", i), /* @__PURE__ */ t("ol", {
|
|
4447
4507
|
className: `timeline${r ? ` ${r}` : ""}`,
|
|
4448
4508
|
children: e.map((e, r) => /* @__PURE__ */ n("li", {
|
|
4449
4509
|
className: `timeline-item${e.tone && e.tone !== "neutral" ? ` ${e.tone}` : ""}`,
|
|
4450
4510
|
children: [/* @__PURE__ */ t("span", {
|
|
4451
4511
|
className: "timeline-dot",
|
|
4452
|
-
children: /* @__PURE__ */ t(
|
|
4512
|
+
children: /* @__PURE__ */ t(D, {
|
|
4453
4513
|
name: e.icon || "circle",
|
|
4454
4514
|
size: 12
|
|
4455
4515
|
})
|
|
@@ -4480,4 +4540,4 @@ function xt({ items: e = [], className: r = "" }) {
|
|
|
4480
4540
|
});
|
|
4481
4541
|
}
|
|
4482
4542
|
//#endregion
|
|
4483
|
-
export {
|
|
4543
|
+
export { O as ActionIcon, k as AppAccordion, A as AppAlert, ve as AppAutocomplete, be as AppAvatar, xe as AppBadge, X as AppButton, we as AppCallout, Te as AppCard, Ee as AppCheckbox, De as AppChip, Oe as AppChoiceCard, ke as AppChoiceChip, Ae as AppColorField, je as AppCompareTable, Ie as AppConfirmDialog, Ke as AppDataTable, qe as AppDatePicker, Ye as AppDropdown, Xe as AppEmptyState, Ze as AppFileAttachment, et as AppFilePicker, tt as AppInfoList, Z as AppInfoTip, Me as AppInput, nt as AppKpiTile, rt as AppLogoPicker, Pe as AppModal, it as AppMultiSelect, at as AppPageHeader, ot as AppPhoneNumberInput, st as AppPricingCard, ct as AppRadio, lt as AppRepeater, ut as AppResourceCard, dt as AppSearch, ft as AppSegmented, mt as AppSelect, Ve as AppSelectMini, ht as AppShell, vt as AppSidebarMenu, Le as AppSkeleton, Be as AppSkeletonRows, yt as AppSpinner, bt as AppSplash, xt as AppStatusBadge, St as AppStepper, Ct as AppSwitch, wt as AppTableEmptyState, Ue as AppTablePagination, Tt as AppTabs, Et as AppTextarea, Dt as AppTimeline, D as Icon, Fe as MODAL_ICONS, Y as RequiredMark, $e as errorToast, E as iconNames, $ as toast };
|