@tenorlab/react-dashboard 1.2.5 → 1.2.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (25) hide show
  1. package/dist/components/DynamicWidgetLoader.d.ts +2 -1
  2. package/dist/components/WidgetContainer.d.ts +1 -1
  3. package/dist/components/WidgetsCatalogFlyout.d.ts +3 -2
  4. package/dist/components/dashboard-primitives/index.d.ts +0 -4
  5. package/dist/components/index.d.ts +0 -2
  6. package/dist/components/interfaces/core-react.interfaces.d.ts +1 -1
  7. package/dist/components/interfaces/index.d.ts +0 -4
  8. package/dist/components/use-dashboard-store.d.ts +1 -1
  9. package/dist/components/use-dashboard-undo-service.d.ts +1 -1
  10. package/dist/index.d.ts +0 -1
  11. package/dist/react-dashboard.es.js +1449 -1682
  12. package/package.json +2 -1
  13. package/dist/components/dashboard-primitives/color-utils.d.ts +0 -12
  14. package/dist/components/dashboard-primitives/css-vars-utils.d.ts +0 -6
  15. package/dist/components/dashboard-primitives/parse-container-title.d.ts +0 -2
  16. package/dist/components/dashboard-primitives/use-distinct-css-classes.d.ts +0 -1
  17. package/dist/components/dashboard-settings/dashboard-settings-utils.d.ts +0 -4
  18. package/dist/components/dashboard-settings/dashboard-settings.d.ts +0 -2
  19. package/dist/components/dashboard-settings/index.d.ts +0 -2
  20. package/dist/components/interfaces/core.base.d.ts +0 -73
  21. package/dist/components/interfaces/core.interfaces.d.ts +0 -39
  22. package/dist/components/interfaces/core.utils.d.ts +0 -66
  23. package/dist/components/interfaces/storage-service.interfaces.d.ts +0 -8
  24. package/dist/components/use-dashboard-storage-service.d.ts +0 -2
  25. package/dist/react-dashboard.css +0 -1
@@ -1,7 +1,29 @@
1
- import ae, { useState as ce, useCallback as ue, useMemo as st, forwardRef as le, useRef as Ct, Suspense as St, useEffect as Dt } from "react";
2
- import { jsxs as W, jsx as s } from "react/jsx-runtime";
3
- import ct from "react-dom";
4
- const Tt = [
1
+ import oe, { useState as se, useCallback as ce, useMemo as ot, forwardRef as le, useRef as yt, Suspense as bt, useEffect as vt } from "react";
2
+ import { jsxs as $, jsx as o } from "react/jsx-runtime";
3
+ import at from "react-dom";
4
+ const ke = (e) => {
5
+ let n;
6
+ const t = /* @__PURE__ */ new Set(), r = (x, b) => {
7
+ const c = typeof x == "function" ? x(n) : x;
8
+ if (!Object.is(c, n)) {
9
+ const p = n;
10
+ n = b ?? (typeof c != "object" || c === null) ? c : Object.assign({}, n, c), t.forEach((m) => m(n, p));
11
+ }
12
+ }, a = () => n, f = { setState: r, getState: a, getInitialState: () => D, subscribe: (x) => (t.add(x), () => t.delete(x)) }, D = n = e(r, a, f);
13
+ return f;
14
+ }, xt = ((e) => e ? ke(e) : ke), wt = (e) => e;
15
+ function Ct(e, n = wt) {
16
+ const t = oe.useSyncExternalStore(
17
+ e.subscribe,
18
+ oe.useCallback(() => n(e.getState()), [e, n]),
19
+ oe.useCallback(() => n(e.getInitialState()), [e, n])
20
+ );
21
+ return oe.useDebugValue(t), t;
22
+ }
23
+ const St = (e) => {
24
+ const n = xt(e), t = (r) => Ct(n, r);
25
+ return Object.assign(t, n), t;
26
+ }, Dt = ((e) => St), Tt = [
5
27
  {
6
28
  key: "grid-gap",
7
29
  name: "Gap",
@@ -79,15 +101,15 @@ const Tt = [
79
101
  defaultValue: "1.0rem",
80
102
  value: "1.0rem"
81
103
  }
82
- ], Et = ["rem", "pc", "cm", "in", "em", "vh", "vw", "%"], Nt = (e, n) => Et.includes(e) ? n : 1, _t = {
104
+ ], Nt = ["rem", "pc", "cm", "in", "em", "vh", "vw", "%"], Et = (e, n) => Nt.includes(e) ? n : 1, _t = {
83
105
  incrementOrDecrementValue: (e, n) => {
84
- const t = e.value.match(/([\d.]+)/), r = t ? parseFloat(t[1]) : 0, i = e.value.match(/([^\d.]+)/), o = i ? i[1] : e.defaultUnit, a = Nt(o, e.step) * n, b = `${Math.max(r + a, e.minValue).toFixed(1)}${o}`;
106
+ const t = e.value.match(/([\d.]+)/), r = t ? parseFloat(t[1]) : 0, a = e.value.match(/([^\d.]+)/), i = a ? a[1] : e.defaultUnit, d = Et(i, e.step) * n, f = `${Math.max(r + d, e.minValue).toFixed(1)}${i}`;
85
107
  return {
86
108
  ...e,
87
- value: b
109
+ value: f
88
110
  };
89
111
  }
90
- }, Ce = {
112
+ }, xe = {
91
113
  userID: 0,
92
114
  clientAppKey: "",
93
115
  dashboardId: "default",
@@ -97,191 +119,59 @@ const Tt = [
97
119
  widgets: [],
98
120
  childWidgetsConfig: [],
99
121
  cssSettings: [...Tt]
100
- }, Ae = 0.7, Fe = 1, Mt = 0.05, lt = (e) => {
122
+ }, st = (e) => {
123
+ const n = `${e}`.split("_");
124
+ return n.length > 1 ? n[1].replace(/(\D)(\d+)/, "$1 $2") : "Container";
125
+ }, je = 0.7, Ae = 1, Mt = (e) => {
101
126
  let n = Number(e || 0);
102
- return n < Ae && (n = Ae), n > Fe && (n = Fe), n;
103
- }, Pn = (e, n) => {
104
- let t = Number(Number((Mt * n).toFixed(2)).toFixed(2)), r = Number((Number(e) + t).toFixed(2));
105
- return lt(r);
106
- }, $n = (e) => {
107
- let n = {
108
- ...e
109
- };
110
- return n.widgets = n.widgets.filter((t) => {
111
- if (`${t}`.includes("WidgetContainer")) {
112
- const r = n.childWidgetsConfig.filter(
113
- (i) => i.parentWidgetKey === t
114
- );
115
- if (!r || r.length === 0)
116
- return n.widgets = n.widgets.filter(
117
- (i) => i !== t
118
- ), !1;
119
- }
120
- return !0;
121
- }), n;
127
+ return n < je && (n = je), n > Ae && (n = Ae), n;
122
128
  }, Pt = (e) => {
123
129
  const n = e.widgets.filter(
124
130
  (r) => r.includes("WidgetContainer")
125
131
  ), t = {};
126
- return n.forEach((r, i) => {
127
- const d = `${r.split("_container")[0]}_container${i + 1}`;
128
- t[r] = d;
132
+ return n.forEach((r, a) => {
133
+ const i = `${r.split("_container")[0]}_container${a + 1}`;
134
+ t[r] = i;
129
135
  }), e.widgets = e.widgets.map((r) => t[r] || r), e.childWidgetsConfig = e.childWidgetsConfig.map((r) => {
130
- const i = r.parentWidgetKey, o = t[i];
136
+ const a = r.parentWidgetKey, i = t[a];
131
137
  return {
132
138
  ...r,
133
139
  // If a new key exists, use it. If not, keep the original key.
134
- parentWidgetKey: o || i
140
+ parentWidgetKey: i || a
135
141
  };
136
142
  }), e;
137
- }, ge = (e, n) => {
138
- const t = `${e}`.includes("Container"), r = t ? ["Container"] : ["Widget"], i = n?.name || e, o = n?.description || (t ? "Container" : "Unknown");
143
+ }, $t = (e, n) => {
144
+ const t = `${e}`.includes("Container"), r = t ? ["Container"] : ["Widget"], a = n?.name || e, i = n?.description || (t ? "Container" : "Unknown");
139
145
  return {
140
- name: i,
141
- description: o,
146
+ name: a,
147
+ description: i,
142
148
  categories: r,
143
149
  noDuplicatedWidgets: !0,
144
150
  icon: void 0,
145
151
  externalDependencies: []
146
152
  };
147
- }, Wn = (e, n, t) => {
148
- const r = n[e];
149
- return r || ge(e, t);
150
- }, $t = (e, n) => {
151
- const r = n.get(e)?.meta;
152
- return r || ge(e);
153
- }, Wt = (e, n, t) => {
154
- const r = t || ge(e);
155
- return [
156
- e,
157
- {
158
- key: e,
159
- title: r.name,
160
- isContainer: `${e}`.includes("Container"),
161
- meta: r,
162
- component: n
163
- }
164
- ];
165
- }, dt = (e, n, t) => {
166
- const r = t || ge(e);
167
- return [
168
- e,
169
- {
170
- key: e,
171
- title: r.name,
172
- isContainer: !1,
173
- meta: r,
174
- loader: n
175
- }
176
- ];
177
- }, It = (e) => {
178
- const n = e.match(/\/widget-([a-zA-Z0-9-]+)\/index\.ts$/);
179
- if (n && n[1]) {
180
- const t = n[1], r = t.split("-"), i = `Widget${r.map((a) => a.charAt(0).toUpperCase() + a.slice(1)).join("")}`, o = r.map((a) => a.charAt(0).toUpperCase() + a.slice(1)).join(" ");
181
- return {
182
- key: i,
183
- title: o,
184
- folder: t
185
- };
186
- }
187
- return null;
188
- }, Ot = (e, n, t, r) => {
189
- const i = `${n}/widget-${t}/meta.ts`, o = e[i];
190
- if (!o)
191
- return;
192
- const a = `${r}Meta`;
193
- return o[a] || void 0;
194
- }, In = async (e) => new Promise(async (n, t) => {
195
- const r = [];
196
- try {
197
- const o = await (await fetch(`${e}?${Math.random()}`)).json();
198
- for (const a in o) {
199
- const d = o[a], b = () => import(
200
- /* @vite-ignore */
201
- d.url
202
- ), m = {
203
- name: d.meta?.name || "Unknown",
204
- description: d.meta?.description || "Remote Plugin",
205
- categories: d.meta?.categories || ["Widget"],
206
- noDuplicatedWidgets: d.meta?.noDuplicatedWidgets ?? !0,
207
- icon: void 0,
208
- // Or a logic to map a string name to a Lucide component
209
- externalDependencies: d.meta?.externalDependencies || []
210
- };
211
- r.push(dt(a, b, m));
212
- }
213
- n({
214
- entries: r,
215
- message: "",
216
- details: ""
217
- });
218
- } catch (i) {
219
- console.error("Remote plugin discovery failed:", i), t({
220
- entries: [],
221
- message: "Remote plugin discovery failed:",
222
- details: typeof i == "object" ? JSON.stringify(i) : i
223
- });
224
- }
225
- }), On = (e, n, t, r = !0) => {
226
- const i = [];
227
- for (const o in n) {
228
- const a = n[o], d = It(o);
229
- if (d && a) {
230
- const { key: b, title: m, folder: h } = d;
231
- let u = Ot(t, e, h, b);
232
- if (u || (u = ge(b, {
233
- description: `Local ${r ? "dynamic" : "static"} widget`
234
- })), r)
235
- i.push(
236
- dt(b, a, u)
237
- );
238
- else {
239
- const p = a.default || a;
240
- i.push(Wt(b, p, u));
241
- }
242
- }
243
- }
244
- return i;
245
- }, Le = (e) => {
246
- let n;
247
- const t = /* @__PURE__ */ new Set(), r = (m, h) => {
248
- const u = typeof m == "function" ? m(n) : m;
249
- if (!Object.is(u, n)) {
250
- const p = n;
251
- n = h ?? (typeof u != "object" || u === null) ? u : Object.assign({}, n, u), t.forEach((y) => y(n, p));
252
- }
253
- }, i = () => n, d = { setState: r, getState: i, getInitialState: () => b, subscribe: (m) => (t.add(m), () => t.delete(m)) }, b = n = e(r, i, d);
254
- return d;
255
- }, Rt = ((e) => e ? Le(e) : Le), kt = (e) => e;
256
- function jt(e, n = kt) {
257
- const t = ae.useSyncExternalStore(
258
- e.subscribe,
259
- ae.useCallback(() => n(e.getState()), [e, n]),
260
- ae.useCallback(() => n(e.getInitialState()), [e, n])
261
- );
262
- return ae.useDebugValue(t), t;
263
- }
264
- const At = (e) => {
265
- const n = Rt(e), t = (r) => jt(n, r);
266
- return Object.assign(t, n), t;
267
- }, Ft = ((e) => At), Lt = (e) => {
153
+ }, It = (e, n) => n.get(e)?.meta || $t(e), G = (e, ...n) => [
154
+ ...new Set(
155
+ [e || "", ...n].join(" ").trim().replace(/\n+/gi, " ").replace(/\s+/gi, " ").split(" ")
156
+ )
157
+ ].join(" ").trim(), Rt = (e) => {
268
158
  const n = e.widgets.filter((r) => r.includes("WidgetContainer")).map((r) => Number(r.split("_")[1].replace("container", "")));
269
159
  return `container${n.length > 0 ? Math.max(...n) + 1 : 1}`;
270
- }, Vt = (e, n) => {
271
- const t = Lt(e);
160
+ }, Ot = (e, n) => {
161
+ const t = Rt(e);
272
162
  return `${n}_${t}`;
273
- }, Ut = (e) => {
274
- const { dashboardConfig: n, widgetKey: t, parentWidgetKey: r, noDuplicatedWidgets: i } = e;
163
+ }, Wt = (e) => {
164
+ const { dashboardConfig: n, widgetKey: t, parentWidgetKey: r, noDuplicatedWidgets: a } = e;
275
165
  if (r) {
276
- if (i && n.childWidgetsConfig.find(
277
- (a) => a.parentWidgetKey === r && a.widgetKey === t
166
+ if (a && n.childWidgetsConfig.find(
167
+ (d) => d.parentWidgetKey === r && d.widgetKey === t
278
168
  ))
279
169
  return {
280
170
  success: !1,
281
171
  message: `DashboardStore: addWidget: Widget already added (${t})`,
282
172
  updatedDashboardConfig: n
283
173
  };
284
- const o = [
174
+ const i = [
285
175
  ...n.childWidgetsConfig,
286
176
  { parentWidgetKey: r, widgetKey: t }
287
177
  // new entry
@@ -290,102 +180,102 @@ const At = (e) => {
290
180
  success: !0,
291
181
  updatedDashboardConfig: {
292
182
  ...n,
293
- childWidgetsConfig: o
183
+ childWidgetsConfig: i
294
184
  }
295
185
  };
296
186
  } else {
297
- if (i && n.widgets.includes(t))
187
+ if (a && n.widgets.includes(t))
298
188
  return {
299
189
  success: !1,
300
190
  message: `DashboardStore: addWidget: Widget already added (${t})`,
301
191
  updatedDashboardConfig: n
302
192
  };
303
- const o = [...n.widgets, t];
193
+ const i = [...n.widgets, t];
304
194
  return {
305
195
  success: !0,
306
196
  updatedDashboardConfig: {
307
197
  ...n,
308
- widgets: o
198
+ widgets: i
309
199
  }
310
200
  };
311
201
  }
312
- }, qt = (e, n, t) => {
202
+ }, kt = (e, n, t) => {
313
203
  if ((t || "").trim().length > 0) {
314
204
  const r = e.childWidgetsConfig.filter(
315
- (b) => b.parentWidgetKey !== t
316
- ), i = e.childWidgetsConfig.filter(
317
- (b) => b.parentWidgetKey === t && b.widgetKey !== n
318
- ), o = [...r, ...i];
319
- let a = {
205
+ (D) => D.parentWidgetKey !== t
206
+ ), a = e.childWidgetsConfig.filter(
207
+ (D) => D.parentWidgetKey === t && D.widgetKey !== n
208
+ ), i = [...r, ...a];
209
+ let d = {
320
210
  ...e,
321
- childWidgetsConfig: o
211
+ childWidgetsConfig: i
322
212
  };
323
- return `${n}`.includes("Container") && (a = Pt(a)), {
213
+ return `${n}`.includes("Container") && (d = Pt(d)), {
324
214
  success: !0,
325
- updatedDashboardConfig: a
215
+ updatedDashboardConfig: d
326
216
  };
327
217
  } else {
328
- const r = e.widgets.filter((o) => o !== n), i = e.childWidgetsConfig.filter(
329
- (o) => o.parentWidgetKey !== n
218
+ const r = e.widgets.filter((i) => i !== n), a = e.childWidgetsConfig.filter(
219
+ (i) => i.parentWidgetKey !== n
330
220
  );
331
221
  return {
332
222
  success: !0,
333
223
  updatedDashboardConfig: {
334
224
  ...e,
335
225
  widgets: r,
336
- childWidgetsConfig: i
226
+ childWidgetsConfig: a
337
227
  }
338
228
  };
339
229
  }
340
- }, Yt = (e, n, t, r) => {
230
+ }, jt = (e, n, t, r) => {
341
231
  if ((r || "").trim().length > 0) {
342
- const i = e.childWidgetsConfig.filter(
343
- (h) => h.parentWidgetKey !== r
232
+ const a = e.childWidgetsConfig.filter(
233
+ (b) => b.parentWidgetKey !== r
344
234
  );
345
- let o = e.childWidgetsConfig.filter(
346
- (h) => h.parentWidgetKey === r
235
+ let i = e.childWidgetsConfig.filter(
236
+ (b) => b.parentWidgetKey === r
347
237
  );
348
- const a = o.indexOf(t);
349
- let d = a + n;
350
- if (d = Math.max(0, d), d = Math.min(o.length - 1, d), d === a)
238
+ const d = i.indexOf(t);
239
+ let f = d + n;
240
+ if (f = Math.max(0, f), f = Math.min(i.length - 1, f), f === d)
351
241
  return {
352
242
  success: !1,
353
243
  message: `DashboardStore: moveWidget: Widget already at min/max position (${t})`,
354
244
  updatedDashboardConfig: e
355
245
  };
356
- const b = [...o], [m] = b.splice(a, 1);
357
- return b.splice(d, 0, m), {
246
+ const D = [...i], [x] = D.splice(d, 1);
247
+ return D.splice(f, 0, x), {
358
248
  success: !0,
359
249
  updatedDashboardConfig: {
360
250
  ...e,
361
- childWidgetsConfig: [...i, ...b]
251
+ childWidgetsConfig: [...a, ...D]
362
252
  }
363
253
  };
364
254
  } else {
365
- const i = e.widgets || [], o = i.indexOf(t);
366
- let a = o + n;
367
- if (a = Math.max(0, a), a = Math.min(i.length - 1, a), a === o)
255
+ const a = e.widgets || [], i = a.indexOf(t);
256
+ let d = i + n;
257
+ if (d = Math.max(0, d), d = Math.min(a.length - 1, d), d === i)
368
258
  return {
369
259
  success: !1,
370
260
  message: `DashboardStore: moveWidget: Widget already at min/max position (${t})`,
371
261
  updatedDashboardConfig: e
372
262
  };
373
- const d = [...i], [b] = d.splice(o, 1);
374
- return d.splice(a, 0, b), {
263
+ const f = [...a], [D] = f.splice(i, 1);
264
+ return f.splice(d, 0, D), {
375
265
  success: !0,
376
266
  updatedDashboardConfig: {
377
267
  ...e,
378
- widgets: d
268
+ widgets: f
379
269
  }
380
270
  };
381
271
  }
382
- }, zt = (e, n) => ({
272
+ }, At = (e, n) => ({
383
273
  isLoading: !1,
384
274
  isEditing: !1,
385
- allDashboardConfigs: [Ce],
386
- currentDashboardConfig: Ce,
275
+ allDashboardConfigs: [xe],
276
+ currentDashboardConfig: xe,
387
277
  targetContainerKey: void 0,
388
- getNextContainerKey: (t) => Vt(n().currentDashboardConfig, t),
278
+ getNextContainerKey: (t) => Ot(n().currentDashboardConfig, t),
389
279
  setIsLoading: (t) => (e(() => ({ isLoading: t })), t),
390
280
  setIsEditing: (t) => {
391
281
  let r = n().targetContainerKey;
@@ -394,206 +284,154 @@ const At = (e) => {
394
284
  setTargetContainerKey: (t) => (e(() => ({ targetContainerKey: t })), t),
395
285
  setAllDashboardConfigs: (t) => (e(() => ({ allDashboardConfigs: t })), n().allDashboardConfigs),
396
286
  setCurrentDashboardConfig: (t) => {
397
- const r = n(), i = [
398
- ...r.allDashboardConfigs.filter((o) => o.dashboardId !== t.dashboardId),
287
+ const r = n(), a = [
288
+ ...r.allDashboardConfigs.filter((i) => i.dashboardId !== t.dashboardId),
399
289
  t
400
290
  ];
401
291
  return e(() => ({
402
292
  ...r,
403
- allDashboardConfigs: i,
293
+ allDashboardConfigs: a,
404
294
  currentDashboardConfig: t
405
- })), i;
295
+ })), a;
406
296
  },
407
297
  addDashboardConfig: (t) => {
408
- const r = n(), i = [
409
- ...r.allDashboardConfigs.filter((o) => o.dashboardId !== t.dashboardId),
298
+ const r = n(), a = [
299
+ ...r.allDashboardConfigs.filter((i) => i.dashboardId !== t.dashboardId),
410
300
  t
411
301
  ];
412
302
  return e(() => ({
413
303
  ...r,
414
- allDashboardConfigs: i,
304
+ allDashboardConfigs: a,
415
305
  currentDashboardConfig: t
416
- })), i;
306
+ })), a;
417
307
  },
418
308
  deleteDashboardConfigById: (t) => {
419
- const r = n(), i = [...r.allDashboardConfigs.filter((o) => o.dashboardId !== t)];
309
+ const r = n(), a = [...r.allDashboardConfigs.filter((i) => i.dashboardId !== t)];
420
310
  return e(() => ({
421
311
  ...r,
422
- allDashboardConfigs: i,
423
- currentDashboardConfig: i[0] || Ce
424
- })), i;
312
+ allDashboardConfigs: a,
313
+ currentDashboardConfig: a[0] || xe
314
+ })), a;
425
315
  },
426
316
  selectDashboardById: (t) => (e(() => {
427
- const r = n(), i = r.allDashboardConfigs.find((o) => o.dashboardId === t);
428
- return i ? {
429
- currentDashboardConfig: i
317
+ const r = n(), a = r.allDashboardConfigs.find((i) => i.dashboardId === t);
318
+ return a ? {
319
+ currentDashboardConfig: a
430
320
  } : {
431
321
  ...r
432
322
  };
433
323
  }), n().currentDashboardConfig),
434
324
  addWidget: (t) => {
435
- const r = n(), i = Ut({
325
+ const r = n(), a = Wt({
436
326
  dashboardConfig: r.currentDashboardConfig,
437
327
  ...t
438
- }), o = [
328
+ }), i = [
439
329
  ...r.allDashboardConfigs.filter(
440
- (a) => a.dashboardId !== i.updatedDashboardConfig.dashboardId
330
+ (d) => d.dashboardId !== a.updatedDashboardConfig.dashboardId
441
331
  ),
442
- i.updatedDashboardConfig
332
+ a.updatedDashboardConfig
443
333
  ];
444
- return i.success && e(() => ({
445
- allDashboardConfigs: o,
446
- currentDashboardConfig: i.updatedDashboardConfig
334
+ return a.success && e(() => ({
335
+ allDashboardConfigs: i,
336
+ currentDashboardConfig: a.updatedDashboardConfig
447
337
  })), {
448
- ...i,
449
- allUpdatedDashboardConfigs: o
338
+ ...a,
339
+ allUpdatedDashboardConfigs: i
450
340
  };
451
341
  },
452
342
  removeWidget: (t, r) => {
453
- const i = n(), o = qt(i.currentDashboardConfig, t, r), a = [
454
- ...i.allDashboardConfigs.filter(
455
- (d) => d.dashboardId !== o.updatedDashboardConfig.dashboardId
343
+ const a = n(), i = kt(a.currentDashboardConfig, t, r), d = [
344
+ ...a.allDashboardConfigs.filter(
345
+ (f) => f.dashboardId !== i.updatedDashboardConfig.dashboardId
456
346
  ),
457
- o.updatedDashboardConfig
347
+ i.updatedDashboardConfig
458
348
  ];
459
- return o.success && e(() => ({
460
- allDashboardConfigs: a,
461
- currentDashboardConfig: o.updatedDashboardConfig
349
+ return i.success && e(() => ({
350
+ allDashboardConfigs: d,
351
+ currentDashboardConfig: i.updatedDashboardConfig
462
352
  })), {
463
- ...o,
464
- allUpdatedDashboardConfigs: a
353
+ ...i,
354
+ allUpdatedDashboardConfigs: d
465
355
  };
466
356
  },
467
- moveWidget: (t, r, i) => {
468
- const o = n(), a = Yt(o.currentDashboardConfig, t, r, i), d = [
469
- ...o.allDashboardConfigs.filter(
470
- (b) => b.dashboardId !== a.updatedDashboardConfig.dashboardId
357
+ moveWidget: (t, r, a) => {
358
+ const i = n(), d = jt(i.currentDashboardConfig, t, r, a), f = [
359
+ ...i.allDashboardConfigs.filter(
360
+ (D) => D.dashboardId !== d.updatedDashboardConfig.dashboardId
471
361
  ),
472
- a.updatedDashboardConfig
362
+ d.updatedDashboardConfig
473
363
  ];
474
- return a.success && e(() => ({
475
- allDashboardConfigs: d,
476
- currentDashboardConfig: a.updatedDashboardConfig
364
+ return d.success && e(() => ({
365
+ allDashboardConfigs: f,
366
+ currentDashboardConfig: d.updatedDashboardConfig
477
367
  })), {
478
- ...a,
479
- allUpdatedDashboardConfigs: d
368
+ ...d,
369
+ allUpdatedDashboardConfigs: f
480
370
  };
481
371
  }
482
- }), Rn = Ft()((...e) => ({
483
- ...zt(...e)
484
- })), ut = (e, n) => `dashboards_${n}_${e}`, Bt = async (e, n, t, r) => {
485
- const i = localStorage.getItem(ut(e, n));
486
- if (i)
487
- try {
488
- const o = JSON.parse(i);
489
- return o.length < 1 ? [r] : (o.forEach((a) => {
490
- a.dashboardId || (a.dashboardId = "default"), a.dashboardName || (a.dashboardName = `Dashboard ${a.dashboardId}`), a.responsiveGrid = a.responsiveGrid ?? !1, (a.widgets || []).length < 1 && (a.widgets = r.widgets);
491
- const d = (a.cssSettings || []).filter(
492
- (b) => r.cssSettings.some((m) => m.key === b.key)
493
- );
494
- if (d.length < 1)
495
- a.cssSettings = [...r.cssSettings];
496
- else {
497
- d.forEach((m) => {
498
- m.value = (m.value || "").replace(/NaN/g, "");
499
- const h = r.cssSettings.find(
500
- (u) => u.key === m.key
501
- );
502
- h && (Object.keys(h).forEach((u) => {
503
- u in m || (m[u] = h[u]);
504
- }), m.step = h.step, m.minValue = h.minValue, m.defaultValue = h.defaultValue, m.defaultUnit = h.defaultUnit, /\d+/g.test(m.value) === !1 && (m.value = h ? h.value : "1.0rem"));
505
- });
506
- const b = r.cssSettings.filter((m) => !d.some(
507
- (h) => h.key === m.key
508
- ));
509
- a.cssSettings = [...d, ...b];
510
- }
511
- a.widgets = a.widgets.filter(
512
- (b) => b.includes("WidgetContainer") || t.has(b)
513
- ), a.childWidgetsConfig = a.childWidgetsConfig.filter(
514
- (b) => t.has(b.widgetKey)
515
- ), a.zoomScale ? a.zoomScale < 0.7 && (a.zoomScale = 0.7) : a.zoomScale = 1;
516
- }), o);
517
- } catch (o) {
518
- console.warn("Error parsing saved dashboard config:", o);
519
- }
520
- return [r];
521
- }, Ht = async (e, n, t, r) => {
522
- t.forEach((o) => {
523
- if (o.userID = e, o.clientAppKey = n, o.responsiveGrid = o.responsiveGrid ?? !1, typeof o != "object")
524
- throw new Error("Invalid dashboard configuration");
525
- o.widgets = o.widgets.filter(
526
- (a) => a.includes("WidgetContainer") || r.has(a)
527
- ), o.childWidgetsConfig = o.childWidgetsConfig.filter(
528
- (a) => r.has(a.widgetKey)
529
- ), o.zoomScale ? o.zoomScale < 0.7 && (o.zoomScale = 0.7) : o.zoomScale = 1;
530
- });
531
- const i = JSON.stringify(t);
532
- return localStorage.setItem(ut(e, n), i), !0;
533
- }, Kt = {
534
- getSavedDashboards: Bt,
535
- saveDashboards: Ht
536
- }, kn = () => Kt, jn = () => {
537
- const [e, n] = ce({}), [t, r] = ce({}), i = ue((h) => {
538
- const u = h.dashboardId;
372
+ }), xn = Dt()((...e) => ({
373
+ ...At(...e)
374
+ })), wn = () => {
375
+ const [e, n] = se({}), [t, r] = se({}), a = ce((b) => {
376
+ const c = b.dashboardId;
539
377
  n((p) => {
540
- const y = {
378
+ const m = {
541
379
  undoIndex: 0,
542
- config: h
380
+ config: b
543
381
  };
544
- return r((D) => ({
545
- ...D,
546
- [u]: 0
382
+ return r((T) => ({
383
+ ...T,
384
+ [c]: 0
547
385
  })), {
548
386
  ...p,
549
- [u]: [y]
387
+ [c]: [m]
550
388
  // Forces a reset to just this one entry
551
389
  };
552
390
  });
553
- }, []), o = ue(
554
- (h) => {
555
- n((u) => {
556
- const p = h.dashboardId, y = u[p] || [], D = t[p] ?? -1, g = y.slice(0, D + 1), v = {
391
+ }, []), i = ce(
392
+ (b) => {
393
+ n((c) => {
394
+ const p = b.dashboardId, m = c[p] || [], T = t[p] ?? -1, g = m.slice(0, T + 1), y = {
557
395
  undoIndex: g.length,
558
396
  // New index based on trimmed length
559
- config: h
560
- }, w = [...g, v];
561
- return r((T) => ({
562
- ...T,
397
+ config: b
398
+ }, w = [...g, y];
399
+ return r((N) => ({
400
+ ...N,
563
401
  [p]: w.length - 1
564
402
  // Index is now the last element's index
565
403
  })), {
566
- ...u,
404
+ ...c,
567
405
  [p]: w
568
406
  };
569
407
  });
570
408
  },
571
409
  [t]
572
- ), a = ue((h) => {
573
- n((u) => {
574
- if (!u[h])
575
- return u;
576
- const { [h]: p, ...y } = u;
577
- return y;
578
- }), r((u) => {
579
- const { [h]: p, ...y } = u;
580
- return y;
410
+ ), d = ce((b) => {
411
+ n((c) => {
412
+ if (!c[b])
413
+ return c;
414
+ const { [b]: p, ...m } = c;
415
+ return m;
416
+ }), r((c) => {
417
+ const { [b]: p, ...m } = c;
418
+ return m;
581
419
  });
582
- }, []), d = ue(
583
- (h) => {
584
- r((u) => {
585
- const p = u[h] ?? -1, y = Math.max(0, p - 1);
586
- return y !== p ? { ...u, [h]: y } : u;
420
+ }, []), f = ce(
421
+ (b) => {
422
+ r((c) => {
423
+ const p = c[b] ?? -1, m = Math.max(0, p - 1);
424
+ return m !== p ? { ...c, [b]: m } : c;
587
425
  });
588
426
  },
589
427
  [
590
428
  //loadConfigFromHistory
591
429
  ]
592
- ), b = ue(
593
- (h) => {
594
- r((u) => {
595
- const p = e[h]?.length || 0, y = u[h] ?? -1, D = Math.min(p - 1, y + 1);
596
- return D !== y ? { ...u, [h]: D } : u;
430
+ ), D = ce(
431
+ (b) => {
432
+ r((c) => {
433
+ const p = e[b]?.length || 0, m = c[b] ?? -1, T = Math.min(p - 1, m + 1);
434
+ return T !== m ? { ...c, [b]: T } : c;
597
435
  });
598
436
  },
599
437
  [
@@ -602,26 +440,26 @@ const At = (e) => {
602
440
  ]
603
441
  );
604
442
  return {
605
- initializeHistoryForDashboard: i,
443
+ initializeHistoryForDashboard: a,
606
444
  resetAllHistory: () => n({}),
607
- addUndoEntry: o,
608
- removeUndoHistoryForDashboard: a,
609
- undo: d,
610
- redo: b,
611
- getUndoStatus: (h) => {
612
- const u = t[h] ?? -1, p = e[h]?.length || 0, y = u <= 0, D = u >= p - 1;
613
- return { isUndoDisabled: y, isRedoDisabled: D };
445
+ addUndoEntry: i,
446
+ removeUndoHistoryForDashboard: d,
447
+ undo: f,
448
+ redo: D,
449
+ getUndoStatus: (b) => {
450
+ const c = t[b] ?? -1, p = e[b]?.length || 0, m = c <= 0, T = c >= p - 1;
451
+ return { isUndoDisabled: m, isRedoDisabled: T };
614
452
  },
615
453
  undoHistory: e,
616
454
  historyIndex: t
617
455
  // (Optional: You might expose undoHistory and historyIndex if needed for debugging)
618
456
  };
619
457
  };
620
- function H({
458
+ function K({
621
459
  children: e,
622
460
  className: n
623
461
  }) {
624
- return /* @__PURE__ */ s(
462
+ return /* @__PURE__ */ o(
625
463
  "svg",
626
464
  {
627
465
  xmlns: "http://www.w3.org/2000/svg",
@@ -638,260 +476,223 @@ function H({
638
476
  }
639
477
  );
640
478
  }
641
- function An({ className: e }) {
642
- return /* @__PURE__ */ W(H, { className: `lucide lucide-circle-plus-icon lucide-circle-plus ${e}`, children: [
643
- /* @__PURE__ */ s("circle", { cx: "12", cy: "12", r: "10" }),
644
- /* @__PURE__ */ s("path", { d: "M8 12h8" }),
645
- /* @__PURE__ */ s("path", { d: "M12 8v8" })
479
+ function Cn({ className: e }) {
480
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-circle-plus-icon lucide-circle-plus ${e}`, children: [
481
+ /* @__PURE__ */ o("circle", { cx: "12", cy: "12", r: "10" }),
482
+ /* @__PURE__ */ o("path", { d: "M8 12h8" }),
483
+ /* @__PURE__ */ o("path", { d: "M12 8v8" })
646
484
  ] });
647
485
  }
648
- function Fn({ className: e }) {
649
- return /* @__PURE__ */ W(H, { className: `lucide lucide-trash2-icon lucide-trash-2 ${e}`, children: [
650
- /* @__PURE__ */ s("path", { d: "M10 11v6" }),
651
- /* @__PURE__ */ s("path", { d: "M14 11v6" }),
652
- /* @__PURE__ */ s("path", { d: "M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6" }),
653
- /* @__PURE__ */ s("path", { d: "M3 6h18" }),
654
- /* @__PURE__ */ s("path", { d: "M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2" })
486
+ function Sn({ className: e }) {
487
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-trash2-icon lucide-trash-2 ${e}`, children: [
488
+ /* @__PURE__ */ o("path", { d: "M10 11v6" }),
489
+ /* @__PURE__ */ o("path", { d: "M14 11v6" }),
490
+ /* @__PURE__ */ o("path", { d: "M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6" }),
491
+ /* @__PURE__ */ o("path", { d: "M3 6h18" }),
492
+ /* @__PURE__ */ o("path", { d: "M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2" })
655
493
  ] });
656
494
  }
657
- function Ln({ className: e }) {
658
- return /* @__PURE__ */ W(H, { className: `lucide lucide-square-pen-icon lucide-square-pen ${e}`, children: [
659
- /* @__PURE__ */ s("path", { d: "M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7" }),
660
- /* @__PURE__ */ s("path", { d: "M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z" })
495
+ function Dn({ className: e }) {
496
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-square-pen-icon lucide-square-pen ${e}`, children: [
497
+ /* @__PURE__ */ o("path", { d: "M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7" }),
498
+ /* @__PURE__ */ o("path", { d: "M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z" })
661
499
  ] });
662
500
  }
663
- function Vn({ className: e }) {
664
- return /* @__PURE__ */ W(H, { className: `lucide lucide-grid3x3-icon lucide-grid-3x3 ${e}`, children: [
665
- /* @__PURE__ */ s("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }),
666
- /* @__PURE__ */ s("path", { d: "M3 9h18" }),
667
- /* @__PURE__ */ s("path", { d: "M3 15h18" }),
668
- /* @__PURE__ */ s("path", { d: "M9 3v18" }),
669
- /* @__PURE__ */ s("path", { d: "M15 3v18" })
501
+ function Tn({ className: e }) {
502
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-grid3x3-icon lucide-grid-3x3 ${e}`, children: [
503
+ /* @__PURE__ */ o("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }),
504
+ /* @__PURE__ */ o("path", { d: "M3 9h18" }),
505
+ /* @__PURE__ */ o("path", { d: "M3 15h18" }),
506
+ /* @__PURE__ */ o("path", { d: "M9 3v18" }),
507
+ /* @__PURE__ */ o("path", { d: "M15 3v18" })
670
508
  ] });
671
509
  }
672
- function Un({ className: e }) {
673
- return /* @__PURE__ */ W(H, { className: `lucide lucide-monitor-icon lucide-monitor ${e}`, children: [
674
- /* @__PURE__ */ s("rect", { width: "20", height: "14", x: "2", y: "3", rx: "2" }),
675
- /* @__PURE__ */ s("line", { x1: "8", x2: "16", y1: "21", y2: "21" }),
676
- /* @__PURE__ */ s("line", { x1: "12", x2: "12", y1: "17", y2: "21" })
510
+ function Nn({ className: e }) {
511
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-monitor-icon lucide-monitor ${e}`, children: [
512
+ /* @__PURE__ */ o("rect", { width: "20", height: "14", x: "2", y: "3", rx: "2" }),
513
+ /* @__PURE__ */ o("line", { x1: "8", x2: "16", y1: "21", y2: "21" }),
514
+ /* @__PURE__ */ o("line", { x1: "12", x2: "12", y1: "17", y2: "21" })
677
515
  ] });
678
516
  }
679
- function qn({ className: e }) {
680
- return /* @__PURE__ */ W(
681
- H,
517
+ function En({ className: e }) {
518
+ return /* @__PURE__ */ $(
519
+ K,
682
520
  {
683
521
  className: `lucide lucide-monitor-smartphone-icon lucide-monitor-smartphone ${e}`,
684
522
  children: [
685
- /* @__PURE__ */ s("path", { d: "M18 8V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h8" }),
686
- /* @__PURE__ */ s("path", { d: "M10 19v-3.96 3.15" }),
687
- /* @__PURE__ */ s("path", { d: "M7 19h5" }),
688
- /* @__PURE__ */ s("rect", { width: "6", height: "10", x: "16", y: "12", rx: "2" })
523
+ /* @__PURE__ */ o("path", { d: "M18 8V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h8" }),
524
+ /* @__PURE__ */ o("path", { d: "M10 19v-3.96 3.15" }),
525
+ /* @__PURE__ */ o("path", { d: "M7 19h5" }),
526
+ /* @__PURE__ */ o("rect", { width: "6", height: "10", x: "16", y: "12", rx: "2" })
689
527
  ]
690
528
  }
691
529
  );
692
530
  }
693
- function ft({ className: e }) {
694
- return /* @__PURE__ */ W(
695
- H,
531
+ function lt({ className: e }) {
532
+ return /* @__PURE__ */ $(
533
+ K,
696
534
  {
697
535
  className: `lucide lucide-circle-arrow-left-icon lucide-circle-arrow-left ${e}`,
698
536
  children: [
699
- /* @__PURE__ */ s("circle", { cx: "12", cy: "12", r: "10" }),
700
- /* @__PURE__ */ s("path", { d: "m12 8-4 4 4 4" }),
701
- /* @__PURE__ */ s("path", { d: "M16 12H8" })
537
+ /* @__PURE__ */ o("circle", { cx: "12", cy: "12", r: "10" }),
538
+ /* @__PURE__ */ o("path", { d: "m12 8-4 4 4 4" }),
539
+ /* @__PURE__ */ o("path", { d: "M16 12H8" })
702
540
  ]
703
541
  }
704
542
  );
705
543
  }
706
- function ht({ className: e }) {
707
- return /* @__PURE__ */ W(
708
- H,
544
+ function dt({ className: e }) {
545
+ return /* @__PURE__ */ $(
546
+ K,
709
547
  {
710
548
  className: `lucide lucide-circle-arrow-right-icon lucide-circle-arrow-right ${e}`,
711
549
  children: [
712
- /* @__PURE__ */ s("circle", { cx: "12", cy: "12", r: "10" }),
713
- /* @__PURE__ */ s("path", { d: "m12 16 4-4-4-4" }),
714
- /* @__PURE__ */ s("path", { d: "M8 12h8" })
550
+ /* @__PURE__ */ o("circle", { cx: "12", cy: "12", r: "10" }),
551
+ /* @__PURE__ */ o("path", { d: "m12 16 4-4-4-4" }),
552
+ /* @__PURE__ */ o("path", { d: "M8 12h8" })
715
553
  ]
716
554
  }
717
555
  );
718
556
  }
719
- function Xt({ className: e }) {
720
- return /* @__PURE__ */ W(H, { className: `lucide lucide-settings-icon lucide-settings ${e}`, children: [
721
- /* @__PURE__ */ s("path", { d: "M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915" }),
722
- /* @__PURE__ */ s("circle", { cx: "12", cy: "12", r: "3" })
557
+ function Lt({ className: e }) {
558
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-settings-icon lucide-settings ${e}`, children: [
559
+ /* @__PURE__ */ o("path", { d: "M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915" }),
560
+ /* @__PURE__ */ o("circle", { cx: "12", cy: "12", r: "3" })
723
561
  ] });
724
562
  }
725
- function Yn({ className: e }) {
726
- return /* @__PURE__ */ W(
727
- H,
563
+ function _n({ className: e }) {
564
+ return /* @__PURE__ */ $(
565
+ K,
728
566
  {
729
567
  className: `lucide lucide-tablet-smartphone-icon lucide-tablet-smartphone ${e}`,
730
568
  children: [
731
- /* @__PURE__ */ s("rect", { width: "10", height: "14", x: "3", y: "8", rx: "2" }),
732
- /* @__PURE__ */ s("path", { d: "M5 4a2 2 0 0 1 2-2h12a2 2 0 0 1 2 2v16a2 2 0 0 1-2 2h-2.4" }),
733
- /* @__PURE__ */ s("path", { d: "M8 18h.01" })
569
+ /* @__PURE__ */ o("rect", { width: "10", height: "14", x: "3", y: "8", rx: "2" }),
570
+ /* @__PURE__ */ o("path", { d: "M5 4a2 2 0 0 1 2-2h12a2 2 0 0 1 2 2v16a2 2 0 0 1-2 2h-2.4" }),
571
+ /* @__PURE__ */ o("path", { d: "M8 18h.01" })
734
572
  ]
735
573
  }
736
574
  );
737
575
  }
738
- function gt({ className: e }) {
739
- return /* @__PURE__ */ W(H, { className: `lucide lucide-circle-x-icon lucide-circle-x ${e}`, children: [
740
- /* @__PURE__ */ s("circle", { cx: "12", cy: "12", r: "10" }),
741
- /* @__PURE__ */ s("path", { d: "m15 9-6 6" }),
742
- /* @__PURE__ */ s("path", { d: "m9 9 6 6" })
576
+ function ct({ className: e }) {
577
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-circle-x-icon lucide-circle-x ${e}`, children: [
578
+ /* @__PURE__ */ o("circle", { cx: "12", cy: "12", r: "10" }),
579
+ /* @__PURE__ */ o("path", { d: "m15 9-6 6" }),
580
+ /* @__PURE__ */ o("path", { d: "m9 9 6 6" })
743
581
  ] });
744
582
  }
745
- function zn({ className: e }) {
746
- return /* @__PURE__ */ W(H, { className: `lucide lucide-zoom-in-icon lucide-zoom-in ${e}`, children: [
747
- /* @__PURE__ */ s("circle", { cx: "11", cy: "11", r: "8" }),
748
- /* @__PURE__ */ s("line", { x1: "21", x2: "16.65", y1: "21", y2: "16.65" }),
749
- /* @__PURE__ */ s("line", { x1: "11", x2: "11", y1: "8", y2: "14" }),
750
- /* @__PURE__ */ s("line", { x1: "8", x2: "14", y1: "11", y2: "11" })
583
+ function Mn({ className: e }) {
584
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-zoom-in-icon lucide-zoom-in ${e}`, children: [
585
+ /* @__PURE__ */ o("circle", { cx: "11", cy: "11", r: "8" }),
586
+ /* @__PURE__ */ o("line", { x1: "21", x2: "16.65", y1: "21", y2: "16.65" }),
587
+ /* @__PURE__ */ o("line", { x1: "11", x2: "11", y1: "8", y2: "14" }),
588
+ /* @__PURE__ */ o("line", { x1: "8", x2: "14", y1: "11", y2: "11" })
751
589
  ] });
752
590
  }
753
- function Bn({ className: e }) {
754
- return /* @__PURE__ */ W(H, { className: `lucide lucide-zoom-out-icon lucide-zoom-out ${e}`, children: [
755
- /* @__PURE__ */ s("circle", { cx: "11", cy: "11", r: "8" }),
756
- /* @__PURE__ */ s("line", { x1: "21", x2: "16.65", y1: "21", y2: "16.65" }),
757
- /* @__PURE__ */ s("line", { x1: "8", x2: "14", y1: "11", y2: "11" })
591
+ function Pn({ className: e }) {
592
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-zoom-out-icon lucide-zoom-out ${e}`, children: [
593
+ /* @__PURE__ */ o("circle", { cx: "11", cy: "11", r: "8" }),
594
+ /* @__PURE__ */ o("line", { x1: "21", x2: "16.65", y1: "21", y2: "16.65" }),
595
+ /* @__PURE__ */ o("line", { x1: "8", x2: "14", y1: "11", y2: "11" })
758
596
  ] });
759
597
  }
760
- function Gt({ className: e }) {
761
- return /* @__PURE__ */ W(H, { className: `lucide lucide-timer-reset-icon lucide-timer-reset ${e}`, children: [
762
- /* @__PURE__ */ s("path", { d: "M10 2h4" }),
763
- /* @__PURE__ */ s("path", { d: "M12 14v-4" }),
764
- /* @__PURE__ */ s("path", { d: "M4 13a8 8 0 0 1 8-7 8 8 0 1 1-5.3 14L4 17.6" }),
765
- /* @__PURE__ */ s("path", { d: "M9 17H4v5" })
598
+ function Ut({ className: e }) {
599
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-timer-reset-icon lucide-timer-reset ${e}`, children: [
600
+ /* @__PURE__ */ o("path", { d: "M10 2h4" }),
601
+ /* @__PURE__ */ o("path", { d: "M12 14v-4" }),
602
+ /* @__PURE__ */ o("path", { d: "M4 13a8 8 0 0 1 8-7 8 8 0 1 1-5.3 14L4 17.6" }),
603
+ /* @__PURE__ */ o("path", { d: "M9 17H4v5" })
766
604
  ] });
767
605
  }
768
- function Zt({ className: e }) {
769
- return /* @__PURE__ */ W(H, { className: `lucide lucide-undo-icon lucide-undo ${e}`, children: [
770
- /* @__PURE__ */ s("path", { d: "M3 7v6h6" }),
771
- /* @__PURE__ */ s("path", { d: "M21 17a9 9 0 0 0-9-9 9 9 0 0 0-6 2.3L3 13" })
606
+ function qt({ className: e }) {
607
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-undo-icon lucide-undo ${e}`, children: [
608
+ /* @__PURE__ */ o("path", { d: "M3 7v6h6" }),
609
+ /* @__PURE__ */ o("path", { d: "M21 17a9 9 0 0 0-9-9 9 9 0 0 0-6 2.3L3 13" })
772
610
  ] });
773
611
  }
774
- function Jt({ className: e }) {
775
- return /* @__PURE__ */ W(H, { className: `lucide lucide-redo-icon lucide-redo ${e}`, children: [
776
- /* @__PURE__ */ s("path", { d: "M21 7v6h-6" }),
777
- /* @__PURE__ */ s("path", { d: "M3 17a9 9 0 0 1 9-9 9 9 0 0 1 6 2.3l3 2.7" })
612
+ function Yt({ className: e }) {
613
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-redo-icon lucide-redo ${e}`, children: [
614
+ /* @__PURE__ */ o("path", { d: "M21 7v6h-6" }),
615
+ /* @__PURE__ */ o("path", { d: "M3 17a9 9 0 0 1 9-9 9 9 0 0 1 6 2.3l3 2.7" })
778
616
  ] });
779
617
  }
780
- function Qt({ className: e }) {
781
- return /* @__PURE__ */ W(H, { className: `lucide lucide-hand-icon lucide-hand ${e}`, children: [
782
- /* @__PURE__ */ s("path", { d: "M18 11V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2" }),
783
- /* @__PURE__ */ s("path", { d: "M14 10V4a2 2 0 0 0-2-2a2 2 0 0 0-2 2v2" }),
784
- /* @__PURE__ */ s("path", { d: "M10 10.5V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2v8" }),
785
- /* @__PURE__ */ s("path", { d: "M18 8a2 2 0 1 1 4 0v6a8 8 0 0 1-8 8h-2c-2.8 0-4.5-.86-5.99-2.34l-3.6-3.6a2 2 0 0 1 2.83-2.82L7 15" })
618
+ function Ft({ className: e }) {
619
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-hand-icon lucide-hand ${e}`, children: [
620
+ /* @__PURE__ */ o("path", { d: "M18 11V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2" }),
621
+ /* @__PURE__ */ o("path", { d: "M14 10V4a2 2 0 0 0-2-2a2 2 0 0 0-2 2v2" }),
622
+ /* @__PURE__ */ o("path", { d: "M10 10.5V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2v8" }),
623
+ /* @__PURE__ */ o("path", { d: "M18 8a2 2 0 1 1 4 0v6a8 8 0 0 1-8 8h-2c-2.8 0-4.5-.86-5.99-2.34l-3.6-3.6a2 2 0 0 1 2.83-2.82L7 15" })
786
624
  ] });
787
625
  }
788
- function en({ className: e }) {
789
- return /* @__PURE__ */ W(H, { className: `lucide lucide-hand-grab-icon lucide-hand-grab ${e}`, children: [
790
- /* @__PURE__ */ s("path", { d: "M18 11.5V9a2 2 0 0 0-2-2a2 2 0 0 0-2 2v1.4" }),
791
- /* @__PURE__ */ s("path", { d: "M14 10V8a2 2 0 0 0-2-2a2 2 0 0 0-2 2v2" }),
792
- /* @__PURE__ */ s("path", { d: "M10 9.9V9a2 2 0 0 0-2-2a2 2 0 0 0-2 2v5" }),
793
- /* @__PURE__ */ s("path", { d: "M6 14a2 2 0 0 0-2-2a2 2 0 0 0-2 2" }),
794
- /* @__PURE__ */ s("path", { d: "M18 11a2 2 0 1 1 4 0v3a8 8 0 0 1-8 8h-4a8 8 0 0 1-8-8 2 2 0 1 1 4 0" })
626
+ function Vt({ className: e }) {
627
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-hand-grab-icon lucide-hand-grab ${e}`, children: [
628
+ /* @__PURE__ */ o("path", { d: "M18 11.5V9a2 2 0 0 0-2-2a2 2 0 0 0-2 2v1.4" }),
629
+ /* @__PURE__ */ o("path", { d: "M14 10V8a2 2 0 0 0-2-2a2 2 0 0 0-2 2v2" }),
630
+ /* @__PURE__ */ o("path", { d: "M10 9.9V9a2 2 0 0 0-2-2a2 2 0 0 0-2 2v5" }),
631
+ /* @__PURE__ */ o("path", { d: "M6 14a2 2 0 0 0-2-2a2 2 0 0 0-2 2" }),
632
+ /* @__PURE__ */ o("path", { d: "M18 11a2 2 0 1 1 4 0v3a8 8 0 0 1-8 8h-4a8 8 0 0 1-8-8 2 2 0 1 1 4 0" })
795
633
  ] });
796
634
  }
797
- function tn({ className: e }) {
798
- return /* @__PURE__ */ W(H, { className: `lucide lucide-crosshair-icon lucide-crosshair ${e}`, children: [
799
- /* @__PURE__ */ s("line", { x1: "22", x2: "18", y1: "12", y2: "12" }),
800
- /* @__PURE__ */ s("line", { x1: "6", x2: "2", y1: "12", y2: "12" }),
801
- /* @__PURE__ */ s("line", { x1: "12", x2: "12", y1: "6", y2: "2" }),
802
- /* @__PURE__ */ s("line", { x1: "12", x2: "12", y1: "22", y2: "18" })
635
+ function Kt({ className: e }) {
636
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-crosshair-icon lucide-crosshair ${e}`, children: [
637
+ /* @__PURE__ */ o("line", { x1: "22", x2: "18", y1: "12", y2: "12" }),
638
+ /* @__PURE__ */ o("line", { x1: "6", x2: "2", y1: "12", y2: "12" }),
639
+ /* @__PURE__ */ o("line", { x1: "12", x2: "12", y1: "6", y2: "2" }),
640
+ /* @__PURE__ */ o("line", { x1: "12", x2: "12", y1: "22", y2: "18" })
803
641
  ] });
804
642
  }
805
- function Hn({ className: e }) {
806
- return /* @__PURE__ */ W(H, { className: `lucide lucide-target-icon lucide-target ${e}`, children: [
807
- /* @__PURE__ */ s("circle", { cx: "12", cy: "12", r: "10" }),
808
- /* @__PURE__ */ s("circle", { cx: "12", cy: "12", r: "6" }),
809
- /* @__PURE__ */ s("circle", { cx: "12", cy: "12", r: "2" })
643
+ function $n({ className: e }) {
644
+ return /* @__PURE__ */ $(K, { className: `lucide lucide-target-icon lucide-target ${e}`, children: [
645
+ /* @__PURE__ */ o("circle", { cx: "12", cy: "12", r: "10" }),
646
+ /* @__PURE__ */ o("circle", { cx: "12", cy: "12", r: "6" }),
647
+ /* @__PURE__ */ o("circle", { cx: "12", cy: "12", r: "2" })
810
648
  ] });
811
649
  }
812
- function nn({ className: e }) {
813
- return /* @__PURE__ */ W(
814
- H,
650
+ function zt({ className: e }) {
651
+ return /* @__PURE__ */ $(
652
+ K,
815
653
  {
816
654
  className: `lucide lucide-file-question-mark-icon lucide-file-question-mark ${e}`,
817
655
  children: [
818
- /* @__PURE__ */ s("circle", { cx: "12", cy: "12", r: "10" }),
819
- /* @__PURE__ */ s("path", { d: "M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3" }),
820
- /* @__PURE__ */ s("path", { d: "M12 17h.01" })
656
+ /* @__PURE__ */ o("circle", { cx: "12", cy: "12", r: "10" }),
657
+ /* @__PURE__ */ o("path", { d: "M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3" }),
658
+ /* @__PURE__ */ o("path", { d: "M12 17h.01" })
821
659
  ]
822
660
  }
823
661
  );
824
662
  }
825
- const G = (e, ...n) => [
826
- ...new Set(
827
- [e || "", ...n].join(" ").trim().replace(/\n+/gi, " ").replace(/\s+/gi, " ").split(" ")
828
- )
829
- ].join(" ").trim(), re = (e, n = "color") => {
830
- if (typeof window > "u") return "#FFFFFF";
831
- const t = document.createElement("div");
832
- Array.isArray(e) ? e.forEach((i) => t.classList.add(i)) : e.split(" ").forEach((i) => t.classList.add(i)), t.style.display = "none", document.body.appendChild(t);
833
- const r = window.getComputedStyle(t)[n];
834
- return document.body.removeChild(t), r;
835
- }, Kn = {
836
- primary: re("text-primary", "color"),
837
- secondary: re("text-secondary", "color"),
838
- success: re("text-success", "color"),
839
- danger: re("text-danger", "color"),
840
- warning: re("text-warning", "color"),
841
- info: re("text-info", "color"),
842
- disabled: re("text-disabled", "color"),
843
- neutral: re("text-neutral", "color"),
844
- body: re("text-body", "color")
845
- }, Xn = {
846
- getCssVariableValue: (e) => {
847
- const n = document.documentElement;
848
- return getComputedStyle(n).getPropertyValue(e).trim() || null;
849
- },
850
- setCssVariableValue: (e, n) => {
851
- document.documentElement.style.setProperty(e, n);
852
- },
853
- restoreCssVarsFromSettings: (e) => {
854
- const n = document.documentElement;
855
- e.forEach((t) => {
856
- n.style.setProperty(t.cssProperty, t.value);
857
- });
858
- }
859
- }, mt = (e) => {
860
- const n = `${e}`.split("_");
861
- return n.length > 1 ? n[1].replace(/(\D)(\d+)/, "$1 $2") : "Container";
862
- }, pt = ({
663
+ const ut = ({
863
664
  label: e,
864
665
  className: n,
865
666
  size: t = "medium",
866
667
  value: r,
867
- onChange: i,
868
- onKeyDown: o,
869
- placeholder: a = ""
668
+ onChange: a,
669
+ onKeyDown: i,
670
+ placeholder: d = ""
870
671
  }) => {
871
- const d = st(() => t === "small" ? "py-1.5 px-3 text-sm" : "py-2.5 px-4 text-base", [t]), b = G("flex flex-col mb-4", n || ""), h = `${G(`
672
+ const f = ot(() => t === "small" ? "py-1.5 px-3 text-sm" : "py-2.5 px-4 text-base", [t]), D = G("flex flex-col mb-4", n || ""), b = `${G(`
872
673
  block w-full rounded-md px-3 py-1.5 text-base
873
674
  bg-formfield content-formfield
874
675
  outline-1 -outline-offset-1 outline-primary
875
676
  placeholder:text-disabled
876
677
  focus:outline-2 focus:-outline-offset-2 focus:outline-indigo-200 sm:text-sm/6
877
- `)} ${d}`;
878
- return /* @__PURE__ */ W("div", { className: b, children: [
879
- /* @__PURE__ */ s("label", { htmlFor: e, className: "block text-sm/6 font-medium mb-1.5", children: e }),
880
- /* @__PURE__ */ s(
678
+ `)} ${f}`;
679
+ return /* @__PURE__ */ $("div", { className: D, children: [
680
+ /* @__PURE__ */ o("label", { htmlFor: e, className: "block text-sm/6 font-medium mb-1.5", children: e }),
681
+ /* @__PURE__ */ o(
881
682
  "input",
882
683
  {
883
684
  id: e,
884
685
  type: "text",
885
686
  value: r,
886
- onChange: i,
887
- onKeyDown: (u) => o && o(u),
888
- placeholder: a,
889
- className: h,
687
+ onChange: a,
688
+ onKeyDown: (c) => i && i(c),
689
+ placeholder: d,
690
+ className: b,
890
691
  "aria-label": e
891
692
  }
892
693
  )
893
694
  ] });
894
- }, Se = /* @__PURE__ */ new Map([
695
+ }, we = /* @__PURE__ */ new Map([
895
696
  [
896
697
  "normal",
897
698
  "group bg-[category] content-[category] hover:bg-[category] group-hover:bg-[category] focus:outline-[category] focus:outline-offset-[category]"
@@ -901,69 +702,69 @@ const G = (e, ...n) => [
901
702
  "group bg-transparent border-[category] text-[category] hover:text-[category] group-hover:text-[category] focus:outline-[category] focus:outline-offset-[category]"
902
703
  ]
903
704
  ]);
904
- function J(e) {
705
+ function Z(e) {
905
706
  const {
906
707
  tooltip: n,
907
708
  disabled: t,
908
709
  isIconButton: r,
909
- className: i,
910
- buttonType: o,
911
- category: a,
912
- px: d,
913
- py: b,
914
- children: m,
915
- ...h
916
- } = e, u = () => {
917
- const y = e.isIconButton || !1, D = e.category || "primary", g = e.buttonType || "normal", v = e.disabled || !1, w = e.className || "", T = e.font || "semibold", C = Number((e.border || 0) > 0 ? e.border : 0);
710
+ className: a,
711
+ buttonType: i,
712
+ category: d,
713
+ px: f,
714
+ py: D,
715
+ children: x,
716
+ ...b
717
+ } = e, c = () => {
718
+ const m = e.isIconButton || !1, T = e.category || "primary", g = e.buttonType || "normal", y = e.disabled || !1, w = e.className || "", N = e.font || "semibold", C = Number((e.border || 0) > 0 ? e.border : 0);
918
719
  let S = (e.borderColor || "").trim();
919
720
  S = S.length > 0 ? S : "";
920
- const l = Number((e.borderHover || 0) > 0 ? e.borderHover : 0), N = e.shadow || "sm", c = e.shadowHover || "md", f = (e.addCss || "").trim(), M = e.justifyCss || "justify-center";
921
- if (y)
721
+ const l = Number((e.borderHover || 0) > 0 ? e.borderHover : 0), M = e.shadow || "sm", s = e.shadowHover || "md", h = (e.addCss || "").trim(), u = e.justifyCss || "justify-center";
722
+ if (m)
922
723
  return G(
923
724
  "flex flex-row items-center",
924
- v ? "text-disabled" : `text-${D} hover:brightness-110 cursor-pointer`,
725
+ y ? "text-disabled" : `text-${T} hover:brightness-110 cursor-pointer`,
925
726
  w || ""
926
727
  );
927
- const $ = [
728
+ const _ = [
928
729
  "relative cursor-pointer",
929
730
  "rounded-sm focus:outline-none focus:ring focus:ring-offset",
930
731
  "transition-all duration-150",
931
732
  "text-sm",
932
- `font-${T}`
733
+ `font-${N}`
933
734
  ];
934
- if (v)
935
- g === "ghost" ? $.push("text-disabled border-disabled cursor-not-allowed") : $.push("bg-disabled content-disabled border-disabled cursor-not-allowed");
735
+ if (y)
736
+ g === "ghost" ? _.push("text-disabled border-disabled cursor-not-allowed") : _.push("bg-disabled content-disabled border-disabled cursor-not-allowed");
936
737
  else {
937
- $.push("cursor-pointer");
738
+ _.push("cursor-pointer");
938
739
  let I = "";
939
- Se.has(g) ? I = `${Se.get(g)}` : I = `${Se.get("normal")}`, C < 1 && (I = I.replace("border-[category]", ""));
940
- const E = I.replace(/\[category\]/g, D).trim();
941
- $.push(E);
740
+ we.has(g) ? I = `${we.get(g)}` : I = `${we.get("normal")}`, C < 1 && (I = I.replace("border-[category]", ""));
741
+ const B = I.replace(/\[category\]/g, T).trim();
742
+ _.push(B);
942
743
  }
943
- return C > 0 ? ($.push(`border-[${C}px]`), $.push(`border-${S}`)) : ($.push("border-[1px]"), $.push("border-transparent")), l > 0 ? ($.push(`hover:border-[${l}px] group-hover:border-[${l}px]`), $.push(`hover:border-${S} group-hover:border-${S}`)) : $.push("hover:border-[1px] group-hover:border-[1px]"), $.push(`shadow-${N}`), $.push(`hover:shadow-${c} group-hover:shadow-${c}`), f.length > 0 && $.push(f), f.indexOf("hidden") === -1 && $.push("inline-flex"), $.push(M), $.join(" ").trim();
744
+ return C > 0 ? (_.push(`border-[${C}px]`), _.push(`border-${S}`)) : (_.push("border-[1px]"), _.push("border-transparent")), l > 0 ? (_.push(`hover:border-[${l}px] group-hover:border-[${l}px]`), _.push(`hover:border-${S} group-hover:border-${S}`)) : _.push("hover:border-[1px] group-hover:border-[1px]"), _.push(`shadow-${M}`), _.push(`hover:shadow-${s} group-hover:shadow-${s}`), h.length > 0 && _.push(h), h.indexOf("hidden") === -1 && _.push("inline-flex"), _.push(u), _.join(" ").trim();
944
745
  }, p = () => {
945
- const y = e.px || 0.7, D = e.py || 0.25;
746
+ const m = e.px || 0.7, T = e.py || 0.25;
946
747
  return {
947
- padding: r ? 0 : `${D}rem ${y}rem `
748
+ padding: r ? 0 : `${T}rem ${m}rem `
948
749
  };
949
750
  };
950
- return /* @__PURE__ */ s("button", { type: "button", disabled: t, className: u(), style: p(), ...h, children: m });
751
+ return /* @__PURE__ */ o("button", { type: "button", disabled: t, className: c(), style: p(), ...b, children: x });
951
752
  }
952
- const rn = (e) => e.direction === "row" ? G("flex flex-row items-center gap-2", e.classNames || "") : G("flex flex-col gap-2 w-full", e.classNames || "");
953
- function on(e) {
954
- const { children: n, testId: t, classNames: r, direction: i, ...o } = e, a = rn(e);
955
- return /* @__PURE__ */ s("div", { "data-testid": t || "not-set", className: a, ...o, children: n });
753
+ const Bt = (e) => e.direction === "row" ? G("flex flex-row items-center gap-2", e.classNames || "") : G("flex flex-col gap-2 w-full", e.classNames || "");
754
+ function Ht(e) {
755
+ const { children: n, testId: t, classNames: r, direction: a, ...i } = e, d = Bt(e);
756
+ return /* @__PURE__ */ o("div", { "data-testid": t || "not-set", className: d, ...i, children: n });
956
757
  }
957
- const Gn = le(
758
+ const In = le(
958
759
  (e, n) => {
959
- const { classNames: t, innerClass: r, ...i } = e, o = G(t || "", "w-full"), a = G(
760
+ const { classNames: t, innerClass: r, ...a } = e, i = G(t || "", "w-full"), d = G(
960
761
  `w-full flex overflow-hidden justify-between items-center gap-0
961
762
  rounded-md border`,
962
763
  r || ""
963
764
  );
964
- return /* @__PURE__ */ s(on, { direction: "row", classNames: o, ...i, children: /* @__PURE__ */ s("div", { className: a, children: e.children }) });
765
+ return /* @__PURE__ */ o(Ht, { direction: "row", classNames: i, ...a, children: /* @__PURE__ */ o("div", { className: d, children: e.children }) });
965
766
  }
966
- ), Zn = le((e, n) => /* @__PURE__ */ s(
767
+ ), Rn = le((e, n) => /* @__PURE__ */ o(
967
768
  "div",
968
769
  {
969
770
  "data-testid": e.testId || "not-set",
@@ -974,8 +775,8 @@ const Gn = le(
974
775
  },
975
776
  children: e.children
976
777
  }
977
- )), Jn = le(
978
- (e, n) => /* @__PURE__ */ s(
778
+ )), On = le(
779
+ (e, n) => /* @__PURE__ */ o(
979
780
  "div",
980
781
  {
981
782
  "data-testid": e.testId || "not-set",
@@ -983,7 +784,7 @@ const Gn = le(
983
784
  children: e.children
984
785
  }
985
786
  )
986
- ), Qn = le((e, n) => /* @__PURE__ */ s(
787
+ ), Wn = le((e, n) => /* @__PURE__ */ o(
987
788
  "div",
988
789
  {
989
790
  "data-testid": e.testId || "not-set",
@@ -995,108 +796,108 @@ const Gn = le(
995
796
  children: e.children
996
797
  }
997
798
  ));
998
- function an(e) {
799
+ function Xt(e) {
999
800
  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
1000
801
  }
1001
- var fe = { exports: {} }, De = {}, pe = { exports: {} }, ye = { exports: {} }, U = {};
1002
- var Ve;
1003
- function sn() {
1004
- if (Ve) return U;
1005
- Ve = 1;
1006
- var e = typeof Symbol == "function" && Symbol.for, n = e ? /* @__PURE__ */ Symbol.for("react.element") : 60103, t = e ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, r = e ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, i = e ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, o = e ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, a = e ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, d = e ? /* @__PURE__ */ Symbol.for("react.context") : 60110, b = e ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, m = e ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, h = e ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, u = e ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, p = e ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, y = e ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, D = e ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, g = e ? /* @__PURE__ */ Symbol.for("react.block") : 60121, v = e ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, w = e ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, T = e ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
802
+ var ue = { exports: {} }, Ce = {}, ge = { exports: {} }, me = { exports: {} }, q = {};
803
+ var Le;
804
+ function Gt() {
805
+ if (Le) return q;
806
+ Le = 1;
807
+ var e = typeof Symbol == "function" && Symbol.for, n = e ? /* @__PURE__ */ Symbol.for("react.element") : 60103, t = e ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, r = e ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, a = e ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, i = e ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, d = e ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, f = e ? /* @__PURE__ */ Symbol.for("react.context") : 60110, D = e ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, x = e ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, b = e ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, c = e ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, p = e ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, m = e ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, T = e ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, g = e ? /* @__PURE__ */ Symbol.for("react.block") : 60121, y = e ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, w = e ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, N = e ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
1007
808
  function C(l) {
1008
809
  if (typeof l == "object" && l !== null) {
1009
- var N = l.$$typeof;
1010
- switch (N) {
810
+ var M = l.$$typeof;
811
+ switch (M) {
1011
812
  case n:
1012
813
  switch (l = l.type, l) {
1013
- case b:
1014
- case m:
814
+ case D:
815
+ case x:
1015
816
  case r:
1016
- case o:
1017
817
  case i:
1018
- case u:
818
+ case a:
819
+ case c:
1019
820
  return l;
1020
821
  default:
1021
822
  switch (l = l && l.$$typeof, l) {
823
+ case f:
824
+ case b:
825
+ case T:
826
+ case m:
1022
827
  case d:
1023
- case h:
1024
- case D:
1025
- case y:
1026
- case a:
1027
828
  return l;
1028
829
  default:
1029
- return N;
830
+ return M;
1030
831
  }
1031
832
  }
1032
833
  case t:
1033
- return N;
834
+ return M;
1034
835
  }
1035
836
  }
1036
837
  }
1037
838
  function S(l) {
1038
- return C(l) === m;
839
+ return C(l) === x;
1039
840
  }
1040
- return U.AsyncMode = b, U.ConcurrentMode = m, U.ContextConsumer = d, U.ContextProvider = a, U.Element = n, U.ForwardRef = h, U.Fragment = r, U.Lazy = D, U.Memo = y, U.Portal = t, U.Profiler = o, U.StrictMode = i, U.Suspense = u, U.isAsyncMode = function(l) {
1041
- return S(l) || C(l) === b;
1042
- }, U.isConcurrentMode = S, U.isContextConsumer = function(l) {
841
+ return q.AsyncMode = D, q.ConcurrentMode = x, q.ContextConsumer = f, q.ContextProvider = d, q.Element = n, q.ForwardRef = b, q.Fragment = r, q.Lazy = T, q.Memo = m, q.Portal = t, q.Profiler = i, q.StrictMode = a, q.Suspense = c, q.isAsyncMode = function(l) {
842
+ return S(l) || C(l) === D;
843
+ }, q.isConcurrentMode = S, q.isContextConsumer = function(l) {
844
+ return C(l) === f;
845
+ }, q.isContextProvider = function(l) {
1043
846
  return C(l) === d;
1044
- }, U.isContextProvider = function(l) {
1045
- return C(l) === a;
1046
- }, U.isElement = function(l) {
847
+ }, q.isElement = function(l) {
1047
848
  return typeof l == "object" && l !== null && l.$$typeof === n;
1048
- }, U.isForwardRef = function(l) {
1049
- return C(l) === h;
1050
- }, U.isFragment = function(l) {
849
+ }, q.isForwardRef = function(l) {
850
+ return C(l) === b;
851
+ }, q.isFragment = function(l) {
1051
852
  return C(l) === r;
1052
- }, U.isLazy = function(l) {
1053
- return C(l) === D;
1054
- }, U.isMemo = function(l) {
1055
- return C(l) === y;
1056
- }, U.isPortal = function(l) {
853
+ }, q.isLazy = function(l) {
854
+ return C(l) === T;
855
+ }, q.isMemo = function(l) {
856
+ return C(l) === m;
857
+ }, q.isPortal = function(l) {
1057
858
  return C(l) === t;
1058
- }, U.isProfiler = function(l) {
1059
- return C(l) === o;
1060
- }, U.isStrictMode = function(l) {
859
+ }, q.isProfiler = function(l) {
1061
860
  return C(l) === i;
1062
- }, U.isSuspense = function(l) {
1063
- return C(l) === u;
1064
- }, U.isValidElementType = function(l) {
1065
- return typeof l == "string" || typeof l == "function" || l === r || l === m || l === o || l === i || l === u || l === p || typeof l == "object" && l !== null && (l.$$typeof === D || l.$$typeof === y || l.$$typeof === a || l.$$typeof === d || l.$$typeof === h || l.$$typeof === v || l.$$typeof === w || l.$$typeof === T || l.$$typeof === g);
1066
- }, U.typeOf = C, U;
861
+ }, q.isStrictMode = function(l) {
862
+ return C(l) === a;
863
+ }, q.isSuspense = function(l) {
864
+ return C(l) === c;
865
+ }, q.isValidElementType = function(l) {
866
+ return typeof l == "string" || typeof l == "function" || l === r || l === x || l === i || l === a || l === c || l === p || typeof l == "object" && l !== null && (l.$$typeof === T || l.$$typeof === m || l.$$typeof === d || l.$$typeof === f || l.$$typeof === b || l.$$typeof === y || l.$$typeof === w || l.$$typeof === N || l.$$typeof === g);
867
+ }, q.typeOf = C, q;
1067
868
  }
1068
- var q = {};
869
+ var Y = {};
1069
870
  var Ue;
1070
- function cn() {
871
+ function Jt() {
1071
872
  return Ue || (Ue = 1, process.env.NODE_ENV !== "production" && (function() {
1072
- var e = typeof Symbol == "function" && Symbol.for, n = e ? /* @__PURE__ */ Symbol.for("react.element") : 60103, t = e ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, r = e ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, i = e ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, o = e ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, a = e ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, d = e ? /* @__PURE__ */ Symbol.for("react.context") : 60110, b = e ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, m = e ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, h = e ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, u = e ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, p = e ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, y = e ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, D = e ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, g = e ? /* @__PURE__ */ Symbol.for("react.block") : 60121, v = e ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, w = e ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, T = e ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
1073
- function C(_) {
1074
- return typeof _ == "string" || typeof _ == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
1075
- _ === r || _ === m || _ === o || _ === i || _ === u || _ === p || typeof _ == "object" && _ !== null && (_.$$typeof === D || _.$$typeof === y || _.$$typeof === a || _.$$typeof === d || _.$$typeof === h || _.$$typeof === v || _.$$typeof === w || _.$$typeof === T || _.$$typeof === g);
1076
- }
1077
- function S(_) {
1078
- if (typeof _ == "object" && _ !== null) {
1079
- var te = _.$$typeof;
873
+ var e = typeof Symbol == "function" && Symbol.for, n = e ? /* @__PURE__ */ Symbol.for("react.element") : 60103, t = e ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, r = e ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, a = e ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, i = e ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, d = e ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, f = e ? /* @__PURE__ */ Symbol.for("react.context") : 60110, D = e ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, x = e ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, b = e ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, c = e ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, p = e ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, m = e ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, T = e ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, g = e ? /* @__PURE__ */ Symbol.for("react.block") : 60121, y = e ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, w = e ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, N = e ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
874
+ function C(E) {
875
+ return typeof E == "string" || typeof E == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
876
+ E === r || E === x || E === i || E === a || E === c || E === p || typeof E == "object" && E !== null && (E.$$typeof === T || E.$$typeof === m || E.$$typeof === d || E.$$typeof === f || E.$$typeof === b || E.$$typeof === y || E.$$typeof === w || E.$$typeof === N || E.$$typeof === g);
877
+ }
878
+ function S(E) {
879
+ if (typeof E == "object" && E !== null) {
880
+ var te = E.$$typeof;
1080
881
  switch (te) {
1081
882
  case n:
1082
- var me = _.type;
1083
- switch (me) {
1084
- case b:
1085
- case m:
883
+ var he = E.type;
884
+ switch (he) {
885
+ case D:
886
+ case x:
1086
887
  case r:
1087
- case o:
1088
888
  case i:
1089
- case u:
1090
- return me;
889
+ case a:
890
+ case c:
891
+ return he;
1091
892
  default:
1092
- var je = me && me.$$typeof;
1093
- switch (je) {
893
+ var We = he && he.$$typeof;
894
+ switch (We) {
895
+ case f:
896
+ case b:
897
+ case T:
898
+ case m:
1094
899
  case d:
1095
- case h:
1096
- case D:
1097
- case y:
1098
- case a:
1099
- return je;
900
+ return We;
1100
901
  default:
1101
902
  return te;
1102
903
  }
@@ -1106,184 +907,184 @@ function cn() {
1106
907
  }
1107
908
  }
1108
909
  }
1109
- var l = b, N = m, c = d, f = a, M = n, $ = h, I = r, E = D, z = y, X = t, Q = o, K = i, ee = u, se = !1;
1110
- function de(_) {
1111
- return se || (se = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), x(_) || S(_) === b;
910
+ var l = D, M = x, s = f, h = d, u = n, _ = b, I = r, B = T, H = m, X = t, Q = i, z = a, ee = c, ae = !1;
911
+ function de(E) {
912
+ return ae || (ae = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), v(E) || S(E) === D;
1112
913
  }
1113
- function x(_) {
1114
- return S(_) === m;
914
+ function v(E) {
915
+ return S(E) === x;
1115
916
  }
1116
- function P(_) {
1117
- return S(_) === d;
917
+ function P(E) {
918
+ return S(E) === f;
1118
919
  }
1119
- function A(_) {
1120
- return S(_) === a;
920
+ function j(E) {
921
+ return S(E) === d;
1121
922
  }
1122
- function k(_) {
1123
- return typeof _ == "object" && _ !== null && _.$$typeof === n;
923
+ function W(E) {
924
+ return typeof E == "object" && E !== null && E.$$typeof === n;
1124
925
  }
1125
- function O(_) {
1126
- return S(_) === h;
926
+ function R(E) {
927
+ return S(E) === b;
1127
928
  }
1128
- function F(_) {
1129
- return S(_) === r;
929
+ function A(E) {
930
+ return S(E) === r;
1130
931
  }
1131
- function R(_) {
1132
- return S(_) === D;
932
+ function O(E) {
933
+ return S(E) === T;
1133
934
  }
1134
- function j(_) {
1135
- return S(_) === y;
935
+ function k(E) {
936
+ return S(E) === m;
1136
937
  }
1137
- function L(_) {
1138
- return S(_) === t;
938
+ function L(E) {
939
+ return S(E) === t;
1139
940
  }
1140
- function Y(_) {
1141
- return S(_) === o;
941
+ function F(E) {
942
+ return S(E) === i;
1142
943
  }
1143
- function V(_) {
1144
- return S(_) === i;
944
+ function U(E) {
945
+ return S(E) === a;
1145
946
  }
1146
- function Z(_) {
1147
- return S(_) === u;
947
+ function J(E) {
948
+ return S(E) === c;
1148
949
  }
1149
- q.AsyncMode = l, q.ConcurrentMode = N, q.ContextConsumer = c, q.ContextProvider = f, q.Element = M, q.ForwardRef = $, q.Fragment = I, q.Lazy = E, q.Memo = z, q.Portal = X, q.Profiler = Q, q.StrictMode = K, q.Suspense = ee, q.isAsyncMode = de, q.isConcurrentMode = x, q.isContextConsumer = P, q.isContextProvider = A, q.isElement = k, q.isForwardRef = O, q.isFragment = F, q.isLazy = R, q.isMemo = j, q.isPortal = L, q.isProfiler = Y, q.isStrictMode = V, q.isSuspense = Z, q.isValidElementType = C, q.typeOf = S;
1150
- })()), q;
950
+ Y.AsyncMode = l, Y.ConcurrentMode = M, Y.ContextConsumer = s, Y.ContextProvider = h, Y.Element = u, Y.ForwardRef = _, Y.Fragment = I, Y.Lazy = B, Y.Memo = H, Y.Portal = X, Y.Profiler = Q, Y.StrictMode = z, Y.Suspense = ee, Y.isAsyncMode = de, Y.isConcurrentMode = v, Y.isContextConsumer = P, Y.isContextProvider = j, Y.isElement = W, Y.isForwardRef = R, Y.isFragment = A, Y.isLazy = O, Y.isMemo = k, Y.isPortal = L, Y.isProfiler = F, Y.isStrictMode = U, Y.isSuspense = J, Y.isValidElementType = C, Y.typeOf = S;
951
+ })()), Y;
1151
952
  }
1152
953
  var qe;
1153
- function yt() {
1154
- return qe || (qe = 1, process.env.NODE_ENV === "production" ? ye.exports = sn() : ye.exports = cn()), ye.exports;
954
+ function ft() {
955
+ return qe || (qe = 1, process.env.NODE_ENV === "production" ? me.exports = Gt() : me.exports = Jt()), me.exports;
1155
956
  }
1156
- var Te, Ye;
1157
- function ln() {
1158
- if (Ye) return Te;
957
+ var Se, Ye;
958
+ function Zt() {
959
+ if (Ye) return Se;
1159
960
  Ye = 1;
1160
961
  var e = Object.getOwnPropertySymbols, n = Object.prototype.hasOwnProperty, t = Object.prototype.propertyIsEnumerable;
1161
- function r(o) {
1162
- if (o == null)
962
+ function r(i) {
963
+ if (i == null)
1163
964
  throw new TypeError("Object.assign cannot be called with null or undefined");
1164
- return Object(o);
965
+ return Object(i);
1165
966
  }
1166
- function i() {
967
+ function a() {
1167
968
  try {
1168
969
  if (!Object.assign)
1169
970
  return !1;
1170
- var o = new String("abc");
1171
- if (o[5] = "de", Object.getOwnPropertyNames(o)[0] === "5")
971
+ var i = new String("abc");
972
+ if (i[5] = "de", Object.getOwnPropertyNames(i)[0] === "5")
1172
973
  return !1;
1173
- for (var a = {}, d = 0; d < 10; d++)
1174
- a["_" + String.fromCharCode(d)] = d;
1175
- var b = Object.getOwnPropertyNames(a).map(function(h) {
1176
- return a[h];
974
+ for (var d = {}, f = 0; f < 10; f++)
975
+ d["_" + String.fromCharCode(f)] = f;
976
+ var D = Object.getOwnPropertyNames(d).map(function(b) {
977
+ return d[b];
1177
978
  });
1178
- if (b.join("") !== "0123456789")
979
+ if (D.join("") !== "0123456789")
1179
980
  return !1;
1180
- var m = {};
1181
- return "abcdefghijklmnopqrst".split("").forEach(function(h) {
1182
- m[h] = h;
1183
- }), Object.keys(Object.assign({}, m)).join("") === "abcdefghijklmnopqrst";
981
+ var x = {};
982
+ return "abcdefghijklmnopqrst".split("").forEach(function(b) {
983
+ x[b] = b;
984
+ }), Object.keys(Object.assign({}, x)).join("") === "abcdefghijklmnopqrst";
1184
985
  } catch {
1185
986
  return !1;
1186
987
  }
1187
988
  }
1188
- return Te = i() ? Object.assign : function(o, a) {
1189
- for (var d, b = r(o), m, h = 1; h < arguments.length; h++) {
1190
- d = Object(arguments[h]);
1191
- for (var u in d)
1192
- n.call(d, u) && (b[u] = d[u]);
989
+ return Se = a() ? Object.assign : function(i, d) {
990
+ for (var f, D = r(i), x, b = 1; b < arguments.length; b++) {
991
+ f = Object(arguments[b]);
992
+ for (var c in f)
993
+ n.call(f, c) && (D[c] = f[c]);
1193
994
  if (e) {
1194
- m = e(d);
1195
- for (var p = 0; p < m.length; p++)
1196
- t.call(d, m[p]) && (b[m[p]] = d[m[p]]);
995
+ x = e(f);
996
+ for (var p = 0; p < x.length; p++)
997
+ t.call(f, x[p]) && (D[x[p]] = f[x[p]]);
1197
998
  }
1198
999
  }
1199
- return b;
1200
- }, Te;
1000
+ return D;
1001
+ }, Se;
1201
1002
  }
1202
- var Ee, ze;
1203
- function Oe() {
1204
- if (ze) return Ee;
1205
- ze = 1;
1003
+ var De, Fe;
1004
+ function Ie() {
1005
+ if (Fe) return De;
1006
+ Fe = 1;
1206
1007
  var e = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";
1207
- return Ee = e, Ee;
1008
+ return De = e, De;
1208
1009
  }
1209
- var Ne, Be;
1210
- function bt() {
1211
- return Be || (Be = 1, Ne = Function.call.bind(Object.prototype.hasOwnProperty)), Ne;
1010
+ var Te, Ve;
1011
+ function ht() {
1012
+ return Ve || (Ve = 1, Te = Function.call.bind(Object.prototype.hasOwnProperty)), Te;
1212
1013
  }
1213
- var _e, He;
1214
- function dn() {
1215
- if (He) return _e;
1216
- He = 1;
1014
+ var Ne, Ke;
1015
+ function Qt() {
1016
+ if (Ke) return Ne;
1017
+ Ke = 1;
1217
1018
  var e = function() {
1218
1019
  };
1219
1020
  if (process.env.NODE_ENV !== "production") {
1220
- var n = /* @__PURE__ */ Oe(), t = {}, r = /* @__PURE__ */ bt();
1221
- e = function(o) {
1222
- var a = "Warning: " + o;
1223
- typeof console < "u" && console.error(a);
1021
+ var n = /* @__PURE__ */ Ie(), t = {}, r = /* @__PURE__ */ ht();
1022
+ e = function(i) {
1023
+ var d = "Warning: " + i;
1024
+ typeof console < "u" && console.error(d);
1224
1025
  try {
1225
- throw new Error(a);
1026
+ throw new Error(d);
1226
1027
  } catch {
1227
1028
  }
1228
1029
  };
1229
1030
  }
1230
- function i(o, a, d, b, m) {
1031
+ function a(i, d, f, D, x) {
1231
1032
  if (process.env.NODE_ENV !== "production") {
1232
- for (var h in o)
1233
- if (r(o, h)) {
1234
- var u;
1033
+ for (var b in i)
1034
+ if (r(i, b)) {
1035
+ var c;
1235
1036
  try {
1236
- if (typeof o[h] != "function") {
1037
+ if (typeof i[b] != "function") {
1237
1038
  var p = Error(
1238
- (b || "React class") + ": " + d + " type `" + h + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof o[h] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
1039
+ (D || "React class") + ": " + f + " type `" + b + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof i[b] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
1239
1040
  );
1240
1041
  throw p.name = "Invariant Violation", p;
1241
1042
  }
1242
- u = o[h](a, h, b, d, null, n);
1243
- } catch (D) {
1244
- u = D;
1043
+ c = i[b](d, b, D, f, null, n);
1044
+ } catch (T) {
1045
+ c = T;
1245
1046
  }
1246
- if (u && !(u instanceof Error) && e(
1247
- (b || "React class") + ": type specification of " + d + " `" + h + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof u + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
1248
- ), u instanceof Error && !(u.message in t)) {
1249
- t[u.message] = !0;
1250
- var y = m ? m() : "";
1047
+ if (c && !(c instanceof Error) && e(
1048
+ (D || "React class") + ": type specification of " + f + " `" + b + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof c + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
1049
+ ), c instanceof Error && !(c.message in t)) {
1050
+ t[c.message] = !0;
1051
+ var m = x ? x() : "";
1251
1052
  e(
1252
- "Failed " + d + " type: " + u.message + (y ?? "")
1053
+ "Failed " + f + " type: " + c.message + (m ?? "")
1253
1054
  );
1254
1055
  }
1255
1056
  }
1256
1057
  }
1257
1058
  }
1258
- return i.resetWarningCache = function() {
1059
+ return a.resetWarningCache = function() {
1259
1060
  process.env.NODE_ENV !== "production" && (t = {});
1260
- }, _e = i, _e;
1061
+ }, Ne = a, Ne;
1261
1062
  }
1262
- var Me, Ke;
1263
- function un() {
1264
- if (Ke) return Me;
1265
- Ke = 1;
1266
- var e = yt(), n = ln(), t = /* @__PURE__ */ Oe(), r = /* @__PURE__ */ bt(), i = /* @__PURE__ */ dn(), o = function() {
1063
+ var Ee, ze;
1064
+ function en() {
1065
+ if (ze) return Ee;
1066
+ ze = 1;
1067
+ var e = ft(), n = Zt(), t = /* @__PURE__ */ Ie(), r = /* @__PURE__ */ ht(), a = /* @__PURE__ */ Qt(), i = function() {
1267
1068
  };
1268
- process.env.NODE_ENV !== "production" && (o = function(d) {
1269
- var b = "Warning: " + d;
1270
- typeof console < "u" && console.error(b);
1069
+ process.env.NODE_ENV !== "production" && (i = function(f) {
1070
+ var D = "Warning: " + f;
1071
+ typeof console < "u" && console.error(D);
1271
1072
  try {
1272
- throw new Error(b);
1073
+ throw new Error(D);
1273
1074
  } catch {
1274
1075
  }
1275
1076
  });
1276
- function a() {
1077
+ function d() {
1277
1078
  return null;
1278
1079
  }
1279
- return Me = function(d, b) {
1280
- var m = typeof Symbol == "function" && Symbol.iterator, h = "@@iterator";
1281
- function u(x) {
1282
- var P = x && (m && x[m] || x[h]);
1080
+ return Ee = function(f, D) {
1081
+ var x = typeof Symbol == "function" && Symbol.iterator, b = "@@iterator";
1082
+ function c(v) {
1083
+ var P = v && (x && v[x] || v[b]);
1283
1084
  if (typeof P == "function")
1284
1085
  return P;
1285
1086
  }
1286
- var p = "<<anonymous>>", y = {
1087
+ var p = "<<anonymous>>", m = {
1287
1088
  array: w("array"),
1288
1089
  bigint: w("bigint"),
1289
1090
  bool: w("boolean"),
@@ -1292,246 +1093,246 @@ function un() {
1292
1093
  object: w("object"),
1293
1094
  string: w("string"),
1294
1095
  symbol: w("symbol"),
1295
- any: T(),
1096
+ any: N(),
1296
1097
  arrayOf: C,
1297
1098
  element: S(),
1298
1099
  elementType: l(),
1299
- instanceOf: N,
1300
- node: $(),
1301
- objectOf: f,
1302
- oneOf: c,
1303
- oneOfType: M,
1304
- shape: E,
1305
- exact: z
1100
+ instanceOf: M,
1101
+ node: _(),
1102
+ objectOf: h,
1103
+ oneOf: s,
1104
+ oneOfType: u,
1105
+ shape: B,
1106
+ exact: H
1306
1107
  };
1307
- function D(x, P) {
1308
- return x === P ? x !== 0 || 1 / x === 1 / P : x !== x && P !== P;
1108
+ function T(v, P) {
1109
+ return v === P ? v !== 0 || 1 / v === 1 / P : v !== v && P !== P;
1309
1110
  }
1310
- function g(x, P) {
1311
- this.message = x, this.data = P && typeof P == "object" ? P : {}, this.stack = "";
1111
+ function g(v, P) {
1112
+ this.message = v, this.data = P && typeof P == "object" ? P : {}, this.stack = "";
1312
1113
  }
1313
1114
  g.prototype = Error.prototype;
1314
- function v(x) {
1115
+ function y(v) {
1315
1116
  if (process.env.NODE_ENV !== "production")
1316
- var P = {}, A = 0;
1317
- function k(F, R, j, L, Y, V, Z) {
1318
- if (L = L || p, V = V || j, Z !== t) {
1319
- if (b) {
1320
- var _ = new Error(
1117
+ var P = {}, j = 0;
1118
+ function W(A, O, k, L, F, U, J) {
1119
+ if (L = L || p, U = U || k, J !== t) {
1120
+ if (D) {
1121
+ var E = new Error(
1321
1122
  "Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types"
1322
1123
  );
1323
- throw _.name = "Invariant Violation", _;
1124
+ throw E.name = "Invariant Violation", E;
1324
1125
  } else if (process.env.NODE_ENV !== "production" && typeof console < "u") {
1325
- var te = L + ":" + j;
1126
+ var te = L + ":" + k;
1326
1127
  !P[te] && // Avoid spamming the console because they are often not actionable except for lib authors
1327
- A < 3 && (o(
1328
- "You are manually calling a React.PropTypes validation function for the `" + V + "` prop on `" + L + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."
1329
- ), P[te] = !0, A++);
1128
+ j < 3 && (i(
1129
+ "You are manually calling a React.PropTypes validation function for the `" + U + "` prop on `" + L + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."
1130
+ ), P[te] = !0, j++);
1330
1131
  }
1331
1132
  }
1332
- return R[j] == null ? F ? R[j] === null ? new g("The " + Y + " `" + V + "` is marked as required " + ("in `" + L + "`, but its value is `null`.")) : new g("The " + Y + " `" + V + "` is marked as required in " + ("`" + L + "`, but its value is `undefined`.")) : null : x(R, j, L, Y, V);
1133
+ return O[k] == null ? A ? O[k] === null ? new g("The " + F + " `" + U + "` is marked as required " + ("in `" + L + "`, but its value is `null`.")) : new g("The " + F + " `" + U + "` is marked as required in " + ("`" + L + "`, but its value is `undefined`.")) : null : v(O, k, L, F, U);
1333
1134
  }
1334
- var O = k.bind(null, !1);
1335
- return O.isRequired = k.bind(null, !0), O;
1336
- }
1337
- function w(x) {
1338
- function P(A, k, O, F, R, j) {
1339
- var L = A[k], Y = K(L);
1340
- if (Y !== x) {
1341
- var V = ee(L);
1135
+ var R = W.bind(null, !1);
1136
+ return R.isRequired = W.bind(null, !0), R;
1137
+ }
1138
+ function w(v) {
1139
+ function P(j, W, R, A, O, k) {
1140
+ var L = j[W], F = z(L);
1141
+ if (F !== v) {
1142
+ var U = ee(L);
1342
1143
  return new g(
1343
- "Invalid " + F + " `" + R + "` of type " + ("`" + V + "` supplied to `" + O + "`, expected ") + ("`" + x + "`."),
1344
- { expectedType: x }
1144
+ "Invalid " + A + " `" + O + "` of type " + ("`" + U + "` supplied to `" + R + "`, expected ") + ("`" + v + "`."),
1145
+ { expectedType: v }
1345
1146
  );
1346
1147
  }
1347
1148
  return null;
1348
1149
  }
1349
- return v(P);
1350
- }
1351
- function T() {
1352
- return v(a);
1353
- }
1354
- function C(x) {
1355
- function P(A, k, O, F, R) {
1356
- if (typeof x != "function")
1357
- return new g("Property `" + R + "` of component `" + O + "` has invalid PropType notation inside arrayOf.");
1358
- var j = A[k];
1359
- if (!Array.isArray(j)) {
1360
- var L = K(j);
1361
- return new g("Invalid " + F + " `" + R + "` of type " + ("`" + L + "` supplied to `" + O + "`, expected an array."));
1150
+ return y(P);
1151
+ }
1152
+ function N() {
1153
+ return y(d);
1154
+ }
1155
+ function C(v) {
1156
+ function P(j, W, R, A, O) {
1157
+ if (typeof v != "function")
1158
+ return new g("Property `" + O + "` of component `" + R + "` has invalid PropType notation inside arrayOf.");
1159
+ var k = j[W];
1160
+ if (!Array.isArray(k)) {
1161
+ var L = z(k);
1162
+ return new g("Invalid " + A + " `" + O + "` of type " + ("`" + L + "` supplied to `" + R + "`, expected an array."));
1362
1163
  }
1363
- for (var Y = 0; Y < j.length; Y++) {
1364
- var V = x(j, Y, O, F, R + "[" + Y + "]", t);
1365
- if (V instanceof Error)
1366
- return V;
1164
+ for (var F = 0; F < k.length; F++) {
1165
+ var U = v(k, F, R, A, O + "[" + F + "]", t);
1166
+ if (U instanceof Error)
1167
+ return U;
1367
1168
  }
1368
1169
  return null;
1369
1170
  }
1370
- return v(P);
1171
+ return y(P);
1371
1172
  }
1372
1173
  function S() {
1373
- function x(P, A, k, O, F) {
1374
- var R = P[A];
1375
- if (!d(R)) {
1376
- var j = K(R);
1377
- return new g("Invalid " + O + " `" + F + "` of type " + ("`" + j + "` supplied to `" + k + "`, expected a single ReactElement."));
1174
+ function v(P, j, W, R, A) {
1175
+ var O = P[j];
1176
+ if (!f(O)) {
1177
+ var k = z(O);
1178
+ return new g("Invalid " + R + " `" + A + "` of type " + ("`" + k + "` supplied to `" + W + "`, expected a single ReactElement."));
1378
1179
  }
1379
1180
  return null;
1380
1181
  }
1381
- return v(x);
1182
+ return y(v);
1382
1183
  }
1383
1184
  function l() {
1384
- function x(P, A, k, O, F) {
1385
- var R = P[A];
1386
- if (!e.isValidElementType(R)) {
1387
- var j = K(R);
1388
- return new g("Invalid " + O + " `" + F + "` of type " + ("`" + j + "` supplied to `" + k + "`, expected a single ReactElement type."));
1185
+ function v(P, j, W, R, A) {
1186
+ var O = P[j];
1187
+ if (!e.isValidElementType(O)) {
1188
+ var k = z(O);
1189
+ return new g("Invalid " + R + " `" + A + "` of type " + ("`" + k + "` supplied to `" + W + "`, expected a single ReactElement type."));
1389
1190
  }
1390
1191
  return null;
1391
1192
  }
1392
- return v(x);
1193
+ return y(v);
1393
1194
  }
1394
- function N(x) {
1395
- function P(A, k, O, F, R) {
1396
- if (!(A[k] instanceof x)) {
1397
- var j = x.name || p, L = de(A[k]);
1398
- return new g("Invalid " + F + " `" + R + "` of type " + ("`" + L + "` supplied to `" + O + "`, expected ") + ("instance of `" + j + "`."));
1195
+ function M(v) {
1196
+ function P(j, W, R, A, O) {
1197
+ if (!(j[W] instanceof v)) {
1198
+ var k = v.name || p, L = de(j[W]);
1199
+ return new g("Invalid " + A + " `" + O + "` of type " + ("`" + L + "` supplied to `" + R + "`, expected ") + ("instance of `" + k + "`."));
1399
1200
  }
1400
1201
  return null;
1401
1202
  }
1402
- return v(P);
1203
+ return y(P);
1403
1204
  }
1404
- function c(x) {
1405
- if (!Array.isArray(x))
1406
- return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? o(
1205
+ function s(v) {
1206
+ if (!Array.isArray(v))
1207
+ return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? i(
1407
1208
  "Invalid arguments supplied to oneOf, expected an array, got " + arguments.length + " arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."
1408
- ) : o("Invalid argument supplied to oneOf, expected an array.")), a;
1409
- function P(A, k, O, F, R) {
1410
- for (var j = A[k], L = 0; L < x.length; L++)
1411
- if (D(j, x[L]))
1209
+ ) : i("Invalid argument supplied to oneOf, expected an array.")), d;
1210
+ function P(j, W, R, A, O) {
1211
+ for (var k = j[W], L = 0; L < v.length; L++)
1212
+ if (T(k, v[L]))
1412
1213
  return null;
1413
- var Y = JSON.stringify(x, function(Z, _) {
1414
- var te = ee(_);
1415
- return te === "symbol" ? String(_) : _;
1214
+ var F = JSON.stringify(v, function(J, E) {
1215
+ var te = ee(E);
1216
+ return te === "symbol" ? String(E) : E;
1416
1217
  });
1417
- return new g("Invalid " + F + " `" + R + "` of value `" + String(j) + "` " + ("supplied to `" + O + "`, expected one of " + Y + "."));
1218
+ return new g("Invalid " + A + " `" + O + "` of value `" + String(k) + "` " + ("supplied to `" + R + "`, expected one of " + F + "."));
1418
1219
  }
1419
- return v(P);
1220
+ return y(P);
1420
1221
  }
1421
- function f(x) {
1422
- function P(A, k, O, F, R) {
1423
- if (typeof x != "function")
1424
- return new g("Property `" + R + "` of component `" + O + "` has invalid PropType notation inside objectOf.");
1425
- var j = A[k], L = K(j);
1222
+ function h(v) {
1223
+ function P(j, W, R, A, O) {
1224
+ if (typeof v != "function")
1225
+ return new g("Property `" + O + "` of component `" + R + "` has invalid PropType notation inside objectOf.");
1226
+ var k = j[W], L = z(k);
1426
1227
  if (L !== "object")
1427
- return new g("Invalid " + F + " `" + R + "` of type " + ("`" + L + "` supplied to `" + O + "`, expected an object."));
1428
- for (var Y in j)
1429
- if (r(j, Y)) {
1430
- var V = x(j, Y, O, F, R + "." + Y, t);
1431
- if (V instanceof Error)
1432
- return V;
1228
+ return new g("Invalid " + A + " `" + O + "` of type " + ("`" + L + "` supplied to `" + R + "`, expected an object."));
1229
+ for (var F in k)
1230
+ if (r(k, F)) {
1231
+ var U = v(k, F, R, A, O + "." + F, t);
1232
+ if (U instanceof Error)
1233
+ return U;
1433
1234
  }
1434
1235
  return null;
1435
1236
  }
1436
- return v(P);
1437
- }
1438
- function M(x) {
1439
- if (!Array.isArray(x))
1440
- return process.env.NODE_ENV !== "production" && o("Invalid argument supplied to oneOfType, expected an instance of array."), a;
1441
- for (var P = 0; P < x.length; P++) {
1442
- var A = x[P];
1443
- if (typeof A != "function")
1444
- return o(
1445
- "Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + se(A) + " at index " + P + "."
1446
- ), a;
1237
+ return y(P);
1238
+ }
1239
+ function u(v) {
1240
+ if (!Array.isArray(v))
1241
+ return process.env.NODE_ENV !== "production" && i("Invalid argument supplied to oneOfType, expected an instance of array."), d;
1242
+ for (var P = 0; P < v.length; P++) {
1243
+ var j = v[P];
1244
+ if (typeof j != "function")
1245
+ return i(
1246
+ "Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + ae(j) + " at index " + P + "."
1247
+ ), d;
1447
1248
  }
1448
- function k(O, F, R, j, L) {
1449
- for (var Y = [], V = 0; V < x.length; V++) {
1450
- var Z = x[V], _ = Z(O, F, R, j, L, t);
1451
- if (_ == null)
1249
+ function W(R, A, O, k, L) {
1250
+ for (var F = [], U = 0; U < v.length; U++) {
1251
+ var J = v[U], E = J(R, A, O, k, L, t);
1252
+ if (E == null)
1452
1253
  return null;
1453
- _.data && r(_.data, "expectedType") && Y.push(_.data.expectedType);
1254
+ E.data && r(E.data, "expectedType") && F.push(E.data.expectedType);
1454
1255
  }
1455
- var te = Y.length > 0 ? ", expected one of type [" + Y.join(", ") + "]" : "";
1456
- return new g("Invalid " + j + " `" + L + "` supplied to " + ("`" + R + "`" + te + "."));
1256
+ var te = F.length > 0 ? ", expected one of type [" + F.join(", ") + "]" : "";
1257
+ return new g("Invalid " + k + " `" + L + "` supplied to " + ("`" + O + "`" + te + "."));
1457
1258
  }
1458
- return v(k);
1259
+ return y(W);
1459
1260
  }
1460
- function $() {
1461
- function x(P, A, k, O, F) {
1462
- return X(P[A]) ? null : new g("Invalid " + O + " `" + F + "` supplied to " + ("`" + k + "`, expected a ReactNode."));
1261
+ function _() {
1262
+ function v(P, j, W, R, A) {
1263
+ return X(P[j]) ? null : new g("Invalid " + R + " `" + A + "` supplied to " + ("`" + W + "`, expected a ReactNode."));
1463
1264
  }
1464
- return v(x);
1265
+ return y(v);
1465
1266
  }
1466
- function I(x, P, A, k, O) {
1267
+ function I(v, P, j, W, R) {
1467
1268
  return new g(
1468
- (x || "React class") + ": " + P + " type `" + A + "." + k + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + O + "`."
1269
+ (v || "React class") + ": " + P + " type `" + j + "." + W + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + R + "`."
1469
1270
  );
1470
1271
  }
1471
- function E(x) {
1472
- function P(A, k, O, F, R) {
1473
- var j = A[k], L = K(j);
1272
+ function B(v) {
1273
+ function P(j, W, R, A, O) {
1274
+ var k = j[W], L = z(k);
1474
1275
  if (L !== "object")
1475
- return new g("Invalid " + F + " `" + R + "` of type `" + L + "` " + ("supplied to `" + O + "`, expected `object`."));
1476
- for (var Y in x) {
1477
- var V = x[Y];
1478
- if (typeof V != "function")
1479
- return I(O, F, R, Y, ee(V));
1480
- var Z = V(j, Y, O, F, R + "." + Y, t);
1481
- if (Z)
1482
- return Z;
1276
+ return new g("Invalid " + A + " `" + O + "` of type `" + L + "` " + ("supplied to `" + R + "`, expected `object`."));
1277
+ for (var F in v) {
1278
+ var U = v[F];
1279
+ if (typeof U != "function")
1280
+ return I(R, A, O, F, ee(U));
1281
+ var J = U(k, F, R, A, O + "." + F, t);
1282
+ if (J)
1283
+ return J;
1483
1284
  }
1484
1285
  return null;
1485
1286
  }
1486
- return v(P);
1287
+ return y(P);
1487
1288
  }
1488
- function z(x) {
1489
- function P(A, k, O, F, R) {
1490
- var j = A[k], L = K(j);
1289
+ function H(v) {
1290
+ function P(j, W, R, A, O) {
1291
+ var k = j[W], L = z(k);
1491
1292
  if (L !== "object")
1492
- return new g("Invalid " + F + " `" + R + "` of type `" + L + "` " + ("supplied to `" + O + "`, expected `object`."));
1493
- var Y = n({}, A[k], x);
1494
- for (var V in Y) {
1495
- var Z = x[V];
1496
- if (r(x, V) && typeof Z != "function")
1497
- return I(O, F, R, V, ee(Z));
1498
- if (!Z)
1293
+ return new g("Invalid " + A + " `" + O + "` of type `" + L + "` " + ("supplied to `" + R + "`, expected `object`."));
1294
+ var F = n({}, j[W], v);
1295
+ for (var U in F) {
1296
+ var J = v[U];
1297
+ if (r(v, U) && typeof J != "function")
1298
+ return I(R, A, O, U, ee(J));
1299
+ if (!J)
1499
1300
  return new g(
1500
- "Invalid " + F + " `" + R + "` key `" + V + "` supplied to `" + O + "`.\nBad object: " + JSON.stringify(A[k], null, " ") + `
1501
- Valid keys: ` + JSON.stringify(Object.keys(x), null, " ")
1301
+ "Invalid " + A + " `" + O + "` key `" + U + "` supplied to `" + R + "`.\nBad object: " + JSON.stringify(j[W], null, " ") + `
1302
+ Valid keys: ` + JSON.stringify(Object.keys(v), null, " ")
1502
1303
  );
1503
- var _ = Z(j, V, O, F, R + "." + V, t);
1504
- if (_)
1505
- return _;
1304
+ var E = J(k, U, R, A, O + "." + U, t);
1305
+ if (E)
1306
+ return E;
1506
1307
  }
1507
1308
  return null;
1508
1309
  }
1509
- return v(P);
1310
+ return y(P);
1510
1311
  }
1511
- function X(x) {
1512
- switch (typeof x) {
1312
+ function X(v) {
1313
+ switch (typeof v) {
1513
1314
  case "number":
1514
1315
  case "string":
1515
1316
  case "undefined":
1516
1317
  return !0;
1517
1318
  case "boolean":
1518
- return !x;
1319
+ return !v;
1519
1320
  case "object":
1520
- if (Array.isArray(x))
1521
- return x.every(X);
1522
- if (x === null || d(x))
1321
+ if (Array.isArray(v))
1322
+ return v.every(X);
1323
+ if (v === null || f(v))
1523
1324
  return !0;
1524
- var P = u(x);
1325
+ var P = c(v);
1525
1326
  if (P) {
1526
- var A = P.call(x), k;
1527
- if (P !== x.entries) {
1528
- for (; !(k = A.next()).done; )
1529
- if (!X(k.value))
1327
+ var j = P.call(v), W;
1328
+ if (P !== v.entries) {
1329
+ for (; !(W = j.next()).done; )
1330
+ if (!X(W.value))
1530
1331
  return !1;
1531
1332
  } else
1532
- for (; !(k = A.next()).done; ) {
1533
- var O = k.value;
1534
- if (O && !X(O[1]))
1333
+ for (; !(W = j.next()).done; ) {
1334
+ var R = W.value;
1335
+ if (R && !X(R[1]))
1535
1336
  return !1;
1536
1337
  }
1537
1338
  } else
@@ -1541,27 +1342,27 @@ Valid keys: ` + JSON.stringify(Object.keys(x), null, " ")
1541
1342
  return !1;
1542
1343
  }
1543
1344
  }
1544
- function Q(x, P) {
1545
- return x === "symbol" ? !0 : P ? P["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && P instanceof Symbol : !1;
1345
+ function Q(v, P) {
1346
+ return v === "symbol" ? !0 : P ? P["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && P instanceof Symbol : !1;
1546
1347
  }
1547
- function K(x) {
1548
- var P = typeof x;
1549
- return Array.isArray(x) ? "array" : x instanceof RegExp ? "object" : Q(P, x) ? "symbol" : P;
1348
+ function z(v) {
1349
+ var P = typeof v;
1350
+ return Array.isArray(v) ? "array" : v instanceof RegExp ? "object" : Q(P, v) ? "symbol" : P;
1550
1351
  }
1551
- function ee(x) {
1552
- if (typeof x > "u" || x === null)
1553
- return "" + x;
1554
- var P = K(x);
1352
+ function ee(v) {
1353
+ if (typeof v > "u" || v === null)
1354
+ return "" + v;
1355
+ var P = z(v);
1555
1356
  if (P === "object") {
1556
- if (x instanceof Date)
1357
+ if (v instanceof Date)
1557
1358
  return "date";
1558
- if (x instanceof RegExp)
1359
+ if (v instanceof RegExp)
1559
1360
  return "regexp";
1560
1361
  }
1561
1362
  return P;
1562
1363
  }
1563
- function se(x) {
1564
- var P = ee(x);
1364
+ function ae(v) {
1365
+ var P = ee(v);
1565
1366
  switch (P) {
1566
1367
  case "array":
1567
1368
  case "object":
@@ -1574,24 +1375,24 @@ Valid keys: ` + JSON.stringify(Object.keys(x), null, " ")
1574
1375
  return P;
1575
1376
  }
1576
1377
  }
1577
- function de(x) {
1578
- return !x.constructor || !x.constructor.name ? p : x.constructor.name;
1378
+ function de(v) {
1379
+ return !v.constructor || !v.constructor.name ? p : v.constructor.name;
1579
1380
  }
1580
- return y.checkPropTypes = i, y.resetWarningCache = i.resetWarningCache, y.PropTypes = y, y;
1581
- }, Me;
1381
+ return m.checkPropTypes = a, m.resetWarningCache = a.resetWarningCache, m.PropTypes = m, m;
1382
+ }, Ee;
1582
1383
  }
1583
- var Pe, Xe;
1584
- function fn() {
1585
- if (Xe) return Pe;
1586
- Xe = 1;
1587
- var e = /* @__PURE__ */ Oe();
1384
+ var _e, Be;
1385
+ function tn() {
1386
+ if (Be) return _e;
1387
+ Be = 1;
1388
+ var e = /* @__PURE__ */ Ie();
1588
1389
  function n() {
1589
1390
  }
1590
1391
  function t() {
1591
1392
  }
1592
- return t.resetWarningCache = n, Pe = function() {
1593
- function r(a, d, b, m, h, u) {
1594
- if (u !== e) {
1393
+ return t.resetWarningCache = n, _e = function() {
1394
+ function r(d, f, D, x, b, c) {
1395
+ if (c !== e) {
1595
1396
  var p = new Error(
1596
1397
  "Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types"
1597
1398
  );
@@ -1599,10 +1400,10 @@ function fn() {
1599
1400
  }
1600
1401
  }
1601
1402
  r.isRequired = r;
1602
- function i() {
1403
+ function a() {
1603
1404
  return r;
1604
1405
  }
1605
- var o = {
1406
+ var i = {
1606
1407
  array: r,
1607
1408
  bigint: r,
1608
1409
  bool: r,
@@ -1612,392 +1413,392 @@ function fn() {
1612
1413
  string: r,
1613
1414
  symbol: r,
1614
1415
  any: r,
1615
- arrayOf: i,
1416
+ arrayOf: a,
1616
1417
  element: r,
1617
1418
  elementType: r,
1618
- instanceOf: i,
1419
+ instanceOf: a,
1619
1420
  node: r,
1620
- objectOf: i,
1621
- oneOf: i,
1622
- oneOfType: i,
1623
- shape: i,
1624
- exact: i,
1421
+ objectOf: a,
1422
+ oneOf: a,
1423
+ oneOfType: a,
1424
+ shape: a,
1425
+ exact: a,
1625
1426
  checkPropTypes: t,
1626
1427
  resetWarningCache: n
1627
1428
  };
1628
- return o.PropTypes = o, o;
1629
- }, Pe;
1429
+ return i.PropTypes = i, i;
1430
+ }, _e;
1630
1431
  }
1631
- var Ge;
1632
- function vt() {
1633
- if (Ge) return pe.exports;
1634
- if (Ge = 1, process.env.NODE_ENV !== "production") {
1635
- var e = yt(), n = !0;
1636
- pe.exports = /* @__PURE__ */ un()(e.isElement, n);
1432
+ var He;
1433
+ function gt() {
1434
+ if (He) return ge.exports;
1435
+ if (He = 1, process.env.NODE_ENV !== "production") {
1436
+ var e = ft(), n = !0;
1437
+ ge.exports = /* @__PURE__ */ en()(e.isElement, n);
1637
1438
  } else
1638
- pe.exports = /* @__PURE__ */ fn()();
1639
- return pe.exports;
1439
+ ge.exports = /* @__PURE__ */ tn()();
1440
+ return ge.exports;
1640
1441
  }
1641
- var be = { exports: {} }, Ze;
1642
- function hn() {
1643
- if (Ze) return be.exports;
1644
- Ze = 1;
1442
+ var pe = { exports: {} }, Xe;
1443
+ function nn() {
1444
+ if (Xe) return pe.exports;
1445
+ Xe = 1;
1645
1446
  function e(t) {
1646
- var r, i, o = "";
1647
- if (typeof t == "string" || typeof t == "number") o += t;
1447
+ var r, a, i = "";
1448
+ if (typeof t == "string" || typeof t == "number") i += t;
1648
1449
  else if (typeof t == "object") if (Array.isArray(t)) {
1649
- var a = t.length;
1650
- for (r = 0; r < a; r++) t[r] && (i = e(t[r])) && (o && (o += " "), o += i);
1651
- } else for (i in t) t[i] && (o && (o += " "), o += i);
1652
- return o;
1450
+ var d = t.length;
1451
+ for (r = 0; r < d; r++) t[r] && (a = e(t[r])) && (i && (i += " "), i += a);
1452
+ } else for (a in t) t[a] && (i && (i += " "), i += a);
1453
+ return i;
1653
1454
  }
1654
1455
  function n() {
1655
- for (var t, r, i = 0, o = "", a = arguments.length; i < a; i++) (t = arguments[i]) && (r = e(t)) && (o && (o += " "), o += r);
1656
- return o;
1456
+ for (var t, r, a = 0, i = "", d = arguments.length; a < d; a++) (t = arguments[a]) && (r = e(t)) && (i && (i += " "), i += r);
1457
+ return i;
1657
1458
  }
1658
- return be.exports = n, be.exports.clsx = n, be.exports;
1459
+ return pe.exports = n, pe.exports.clsx = n, pe.exports;
1659
1460
  }
1660
- var B = {}, oe = {}, Je;
1661
- function we() {
1662
- if (Je) return oe;
1663
- Je = 1, Object.defineProperty(oe, "__esModule", {
1461
+ var V = {}, re = {}, Ge;
1462
+ function ve() {
1463
+ if (Ge) return re;
1464
+ Ge = 1, Object.defineProperty(re, "__esModule", {
1664
1465
  value: !0
1665
- }), oe.dontSetMe = i, oe.findInArray = e, oe.int = r, oe.isFunction = n, oe.isNum = t;
1666
- function e(o, a) {
1667
- for (let d = 0, b = o.length; d < b; d++)
1668
- if (a.apply(a, [o[d], d, o])) return o[d];
1466
+ }), re.dontSetMe = a, re.findInArray = e, re.int = r, re.isFunction = n, re.isNum = t;
1467
+ function e(i, d) {
1468
+ for (let f = 0, D = i.length; f < D; f++)
1469
+ if (d.apply(d, [i[f], f, i])) return i[f];
1669
1470
  }
1670
- function n(o) {
1671
- return typeof o == "function" || Object.prototype.toString.call(o) === "[object Function]";
1471
+ function n(i) {
1472
+ return typeof i == "function" || Object.prototype.toString.call(i) === "[object Function]";
1672
1473
  }
1673
- function t(o) {
1674
- return typeof o == "number" && !isNaN(o);
1474
+ function t(i) {
1475
+ return typeof i == "number" && !isNaN(i);
1675
1476
  }
1676
- function r(o) {
1677
- return parseInt(o, 10);
1477
+ function r(i) {
1478
+ return parseInt(i, 10);
1678
1479
  }
1679
- function i(o, a, d) {
1680
- if (o[a])
1681
- return new Error(`Invalid prop ${a} passed to ${d} - do not set this, set it on the child.`);
1480
+ function a(i, d, f) {
1481
+ if (i[d])
1482
+ return new Error(`Invalid prop ${d} passed to ${f} - do not set this, set it on the child.`);
1682
1483
  }
1683
- return oe;
1484
+ return re;
1684
1485
  }
1685
- var ie = {}, Qe;
1686
- function gn() {
1687
- if (Qe) return ie;
1688
- Qe = 1, Object.defineProperty(ie, "__esModule", {
1486
+ var ie = {}, Je;
1487
+ function rn() {
1488
+ if (Je) return ie;
1489
+ Je = 1, Object.defineProperty(ie, "__esModule", {
1689
1490
  value: !0
1690
1491
  }), ie.browserPrefixToKey = t, ie.browserPrefixToStyle = r, ie.default = void 0, ie.getPrefix = n;
1691
1492
  const e = ["Moz", "Webkit", "O", "ms"];
1692
1493
  function n() {
1693
- let o = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "transform";
1494
+ let i = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "transform";
1694
1495
  if (typeof window > "u") return "";
1695
- const a = window.document?.documentElement?.style;
1696
- if (!a || o in a) return "";
1697
- for (let d = 0; d < e.length; d++)
1698
- if (t(o, e[d]) in a) return e[d];
1496
+ const d = window.document?.documentElement?.style;
1497
+ if (!d || i in d) return "";
1498
+ for (let f = 0; f < e.length; f++)
1499
+ if (t(i, e[f]) in d) return e[f];
1699
1500
  return "";
1700
1501
  }
1701
- function t(o, a) {
1702
- return a ? `${a}${i(o)}` : o;
1502
+ function t(i, d) {
1503
+ return d ? `${d}${a(i)}` : i;
1703
1504
  }
1704
- function r(o, a) {
1705
- return a ? `-${a.toLowerCase()}-${o}` : o;
1505
+ function r(i, d) {
1506
+ return d ? `-${d.toLowerCase()}-${i}` : i;
1706
1507
  }
1707
- function i(o) {
1708
- let a = "", d = !0;
1709
- for (let b = 0; b < o.length; b++)
1710
- d ? (a += o[b].toUpperCase(), d = !1) : o[b] === "-" ? d = !0 : a += o[b];
1711
- return a;
1508
+ function a(i) {
1509
+ let d = "", f = !0;
1510
+ for (let D = 0; D < i.length; D++)
1511
+ f ? (d += i[D].toUpperCase(), f = !1) : i[D] === "-" ? f = !0 : d += i[D];
1512
+ return d;
1712
1513
  }
1713
1514
  return ie.default = n(), ie;
1714
1515
  }
1715
- var et;
1516
+ var Ze;
1716
1517
  function Re() {
1717
- if (et) return B;
1718
- et = 1, Object.defineProperty(B, "__esModule", {
1518
+ if (Ze) return V;
1519
+ Ze = 1, Object.defineProperty(V, "__esModule", {
1719
1520
  value: !0
1720
- }), B.addClassName = l, B.addEvent = a, B.addUserSelectStyles = T, B.createCSSTransform = y, B.createSVGTransform = D, B.getTouch = v, B.getTouchIdentifier = w, B.getTranslation = g, B.innerHeight = h, B.innerWidth = u, B.matchesSelector = i, B.matchesSelectorAndParentsTo = o, B.offsetXYFromParent = p, B.outerHeight = b, B.outerWidth = m, B.removeClassName = N, B.removeEvent = d, B.scheduleRemoveUserSelectStyles = C;
1721
- var e = we(), n = t(gn());
1722
- function t(c, f) {
1723
- if (typeof WeakMap == "function") var M = /* @__PURE__ */ new WeakMap(), $ = /* @__PURE__ */ new WeakMap();
1724
- return (t = function(I, E) {
1725
- if (!E && I && I.__esModule) return I;
1726
- var z, X, Q = { __proto__: null, default: I };
1521
+ }), V.addClassName = l, V.addEvent = d, V.addUserSelectStyles = N, V.createCSSTransform = m, V.createSVGTransform = T, V.getTouch = y, V.getTouchIdentifier = w, V.getTranslation = g, V.innerHeight = b, V.innerWidth = c, V.matchesSelector = a, V.matchesSelectorAndParentsTo = i, V.offsetXYFromParent = p, V.outerHeight = D, V.outerWidth = x, V.removeClassName = M, V.removeEvent = f, V.scheduleRemoveUserSelectStyles = C;
1522
+ var e = ve(), n = t(rn());
1523
+ function t(s, h) {
1524
+ if (typeof WeakMap == "function") var u = /* @__PURE__ */ new WeakMap(), _ = /* @__PURE__ */ new WeakMap();
1525
+ return (t = function(I, B) {
1526
+ if (!B && I && I.__esModule) return I;
1527
+ var H, X, Q = { __proto__: null, default: I };
1727
1528
  if (I === null || typeof I != "object" && typeof I != "function") return Q;
1728
- if (z = E ? $ : M) {
1729
- if (z.has(I)) return z.get(I);
1730
- z.set(I, Q);
1529
+ if (H = B ? _ : u) {
1530
+ if (H.has(I)) return H.get(I);
1531
+ H.set(I, Q);
1731
1532
  }
1732
- for (const K in I) K !== "default" && {}.hasOwnProperty.call(I, K) && ((X = (z = Object.defineProperty) && Object.getOwnPropertyDescriptor(I, K)) && (X.get || X.set) ? z(Q, K, X) : Q[K] = I[K]);
1533
+ for (const z in I) z !== "default" && {}.hasOwnProperty.call(I, z) && ((X = (H = Object.defineProperty) && Object.getOwnPropertyDescriptor(I, z)) && (X.get || X.set) ? H(Q, z, X) : Q[z] = I[z]);
1733
1534
  return Q;
1734
- })(c, f);
1535
+ })(s, h);
1735
1536
  }
1736
1537
  let r = "";
1737
- function i(c, f) {
1738
- return r || (r = (0, e.findInArray)(["matches", "webkitMatchesSelector", "mozMatchesSelector", "msMatchesSelector", "oMatchesSelector"], function(M) {
1739
- return (0, e.isFunction)(c[M]);
1740
- })), (0, e.isFunction)(c[r]) ? c[r](f) : !1;
1538
+ function a(s, h) {
1539
+ return r || (r = (0, e.findInArray)(["matches", "webkitMatchesSelector", "mozMatchesSelector", "msMatchesSelector", "oMatchesSelector"], function(u) {
1540
+ return (0, e.isFunction)(s[u]);
1541
+ })), (0, e.isFunction)(s[r]) ? s[r](h) : !1;
1741
1542
  }
1742
- function o(c, f, M) {
1743
- let $ = c;
1543
+ function i(s, h, u) {
1544
+ let _ = s;
1744
1545
  do {
1745
- if (i($, f)) return !0;
1746
- if ($ === M) return !1;
1747
- $ = $.parentNode;
1748
- } while ($);
1546
+ if (a(_, h)) return !0;
1547
+ if (_ === u) return !1;
1548
+ _ = _.parentNode;
1549
+ } while (_);
1749
1550
  return !1;
1750
1551
  }
1751
- function a(c, f, M, $) {
1752
- if (!c) return;
1552
+ function d(s, h, u, _) {
1553
+ if (!s) return;
1753
1554
  const I = {
1754
1555
  capture: !0,
1755
- ...$
1556
+ ..._
1756
1557
  };
1757
- c.addEventListener ? c.addEventListener(f, M, I) : c.attachEvent ? c.attachEvent("on" + f, M) : c["on" + f] = M;
1558
+ s.addEventListener ? s.addEventListener(h, u, I) : s.attachEvent ? s.attachEvent("on" + h, u) : s["on" + h] = u;
1758
1559
  }
1759
- function d(c, f, M, $) {
1760
- if (!c) return;
1560
+ function f(s, h, u, _) {
1561
+ if (!s) return;
1761
1562
  const I = {
1762
1563
  capture: !0,
1763
- ...$
1564
+ ..._
1764
1565
  };
1765
- c.removeEventListener ? c.removeEventListener(f, M, I) : c.detachEvent ? c.detachEvent("on" + f, M) : c["on" + f] = null;
1766
- }
1767
- function b(c) {
1768
- let f = c.clientHeight;
1769
- const M = c.ownerDocument.defaultView.getComputedStyle(c);
1770
- return f += (0, e.int)(M.borderTopWidth), f += (0, e.int)(M.borderBottomWidth), f;
1771
- }
1772
- function m(c) {
1773
- let f = c.clientWidth;
1774
- const M = c.ownerDocument.defaultView.getComputedStyle(c);
1775
- return f += (0, e.int)(M.borderLeftWidth), f += (0, e.int)(M.borderRightWidth), f;
1776
- }
1777
- function h(c) {
1778
- let f = c.clientHeight;
1779
- const M = c.ownerDocument.defaultView.getComputedStyle(c);
1780
- return f -= (0, e.int)(M.paddingTop), f -= (0, e.int)(M.paddingBottom), f;
1781
- }
1782
- function u(c) {
1783
- let f = c.clientWidth;
1784
- const M = c.ownerDocument.defaultView.getComputedStyle(c);
1785
- return f -= (0, e.int)(M.paddingLeft), f -= (0, e.int)(M.paddingRight), f;
1786
- }
1787
- function p(c, f, M) {
1788
- const I = f === f.ownerDocument.body ? {
1566
+ s.removeEventListener ? s.removeEventListener(h, u, I) : s.detachEvent ? s.detachEvent("on" + h, u) : s["on" + h] = null;
1567
+ }
1568
+ function D(s) {
1569
+ let h = s.clientHeight;
1570
+ const u = s.ownerDocument.defaultView.getComputedStyle(s);
1571
+ return h += (0, e.int)(u.borderTopWidth), h += (0, e.int)(u.borderBottomWidth), h;
1572
+ }
1573
+ function x(s) {
1574
+ let h = s.clientWidth;
1575
+ const u = s.ownerDocument.defaultView.getComputedStyle(s);
1576
+ return h += (0, e.int)(u.borderLeftWidth), h += (0, e.int)(u.borderRightWidth), h;
1577
+ }
1578
+ function b(s) {
1579
+ let h = s.clientHeight;
1580
+ const u = s.ownerDocument.defaultView.getComputedStyle(s);
1581
+ return h -= (0, e.int)(u.paddingTop), h -= (0, e.int)(u.paddingBottom), h;
1582
+ }
1583
+ function c(s) {
1584
+ let h = s.clientWidth;
1585
+ const u = s.ownerDocument.defaultView.getComputedStyle(s);
1586
+ return h -= (0, e.int)(u.paddingLeft), h -= (0, e.int)(u.paddingRight), h;
1587
+ }
1588
+ function p(s, h, u) {
1589
+ const I = h === h.ownerDocument.body ? {
1789
1590
  left: 0,
1790
1591
  top: 0
1791
- } : f.getBoundingClientRect(), E = (c.clientX + f.scrollLeft - I.left) / M, z = (c.clientY + f.scrollTop - I.top) / M;
1592
+ } : h.getBoundingClientRect(), B = (s.clientX + h.scrollLeft - I.left) / u, H = (s.clientY + h.scrollTop - I.top) / u;
1792
1593
  return {
1793
- x: E,
1794
- y: z
1594
+ x: B,
1595
+ y: H
1795
1596
  };
1796
1597
  }
1797
- function y(c, f) {
1798
- const M = g(c, f, "px");
1598
+ function m(s, h) {
1599
+ const u = g(s, h, "px");
1799
1600
  return {
1800
- [(0, n.browserPrefixToKey)("transform", n.default)]: M
1601
+ [(0, n.browserPrefixToKey)("transform", n.default)]: u
1801
1602
  };
1802
1603
  }
1803
- function D(c, f) {
1804
- return g(c, f, "");
1604
+ function T(s, h) {
1605
+ return g(s, h, "");
1805
1606
  }
1806
- function g(c, f, M) {
1607
+ function g(s, h, u) {
1807
1608
  let {
1808
- x: $,
1609
+ x: _,
1809
1610
  y: I
1810
- } = c, E = `translate(${$}${M},${I}${M})`;
1811
- if (f) {
1812
- const z = `${typeof f.x == "string" ? f.x : f.x + M}`, X = `${typeof f.y == "string" ? f.y : f.y + M}`;
1813
- E = `translate(${z}, ${X})` + E;
1611
+ } = s, B = `translate(${_}${u},${I}${u})`;
1612
+ if (h) {
1613
+ const H = `${typeof h.x == "string" ? h.x : h.x + u}`, X = `${typeof h.y == "string" ? h.y : h.y + u}`;
1614
+ B = `translate(${H}, ${X})` + B;
1814
1615
  }
1815
- return E;
1616
+ return B;
1816
1617
  }
1817
- function v(c, f) {
1818
- return c.targetTouches && (0, e.findInArray)(c.targetTouches, (M) => f === M.identifier) || c.changedTouches && (0, e.findInArray)(c.changedTouches, (M) => f === M.identifier);
1618
+ function y(s, h) {
1619
+ return s.targetTouches && (0, e.findInArray)(s.targetTouches, (u) => h === u.identifier) || s.changedTouches && (0, e.findInArray)(s.changedTouches, (u) => h === u.identifier);
1819
1620
  }
1820
- function w(c) {
1821
- if (c.targetTouches && c.targetTouches[0]) return c.targetTouches[0].identifier;
1822
- if (c.changedTouches && c.changedTouches[0]) return c.changedTouches[0].identifier;
1621
+ function w(s) {
1622
+ if (s.targetTouches && s.targetTouches[0]) return s.targetTouches[0].identifier;
1623
+ if (s.changedTouches && s.changedTouches[0]) return s.changedTouches[0].identifier;
1823
1624
  }
1824
- function T(c) {
1825
- if (!c) return;
1826
- let f = c.getElementById("react-draggable-style-el");
1827
- f || (f = c.createElement("style"), f.type = "text/css", f.id = "react-draggable-style-el", f.innerHTML = `.react-draggable-transparent-selection *::-moz-selection {all: inherit;}
1828
- `, f.innerHTML += `.react-draggable-transparent-selection *::selection {all: inherit;}
1829
- `, c.getElementsByTagName("head")[0].appendChild(f)), c.body && l(c.body, "react-draggable-transparent-selection");
1625
+ function N(s) {
1626
+ if (!s) return;
1627
+ let h = s.getElementById("react-draggable-style-el");
1628
+ h || (h = s.createElement("style"), h.type = "text/css", h.id = "react-draggable-style-el", h.innerHTML = `.react-draggable-transparent-selection *::-moz-selection {all: inherit;}
1629
+ `, h.innerHTML += `.react-draggable-transparent-selection *::selection {all: inherit;}
1630
+ `, s.getElementsByTagName("head")[0].appendChild(h)), s.body && l(s.body, "react-draggable-transparent-selection");
1830
1631
  }
1831
- function C(c) {
1632
+ function C(s) {
1832
1633
  window.requestAnimationFrame ? window.requestAnimationFrame(() => {
1833
- S(c);
1834
- }) : S(c);
1634
+ S(s);
1635
+ }) : S(s);
1835
1636
  }
1836
- function S(c) {
1837
- if (c)
1637
+ function S(s) {
1638
+ if (s)
1838
1639
  try {
1839
- if (c.body && N(c.body, "react-draggable-transparent-selection"), c.selection)
1840
- c.selection.empty();
1640
+ if (s.body && M(s.body, "react-draggable-transparent-selection"), s.selection)
1641
+ s.selection.empty();
1841
1642
  else {
1842
- const f = (c.defaultView || window).getSelection();
1843
- f && f.type !== "Caret" && f.removeAllRanges();
1643
+ const h = (s.defaultView || window).getSelection();
1644
+ h && h.type !== "Caret" && h.removeAllRanges();
1844
1645
  }
1845
1646
  } catch {
1846
1647
  }
1847
1648
  }
1848
- function l(c, f) {
1849
- c.classList ? c.classList.add(f) : c.className.match(new RegExp(`(?:^|\\s)${f}(?!\\S)`)) || (c.className += ` ${f}`);
1649
+ function l(s, h) {
1650
+ s.classList ? s.classList.add(h) : s.className.match(new RegExp(`(?:^|\\s)${h}(?!\\S)`)) || (s.className += ` ${h}`);
1850
1651
  }
1851
- function N(c, f) {
1852
- c.classList ? c.classList.remove(f) : c.className = c.className.replace(new RegExp(`(?:^|\\s)${f}(?!\\S)`, "g"), "");
1652
+ function M(s, h) {
1653
+ s.classList ? s.classList.remove(h) : s.className = s.className.replace(new RegExp(`(?:^|\\s)${h}(?!\\S)`, "g"), "");
1853
1654
  }
1854
- return B;
1655
+ return V;
1855
1656
  }
1856
- var ne = {}, tt;
1857
- function xt() {
1858
- if (tt) return ne;
1859
- tt = 1, Object.defineProperty(ne, "__esModule", {
1657
+ var ne = {}, Qe;
1658
+ function mt() {
1659
+ if (Qe) return ne;
1660
+ Qe = 1, Object.defineProperty(ne, "__esModule", {
1860
1661
  value: !0
1861
- }), ne.canDragX = i, ne.canDragY = o, ne.createCoreData = d, ne.createDraggableData = b, ne.getBoundPosition = t, ne.getControlPosition = a, ne.snapToGrid = r;
1862
- var e = we(), n = Re();
1863
- function t(u, p, y) {
1864
- if (!u.props.bounds) return [p, y];
1662
+ }), ne.canDragX = a, ne.canDragY = i, ne.createCoreData = f, ne.createDraggableData = D, ne.getBoundPosition = t, ne.getControlPosition = d, ne.snapToGrid = r;
1663
+ var e = ve(), n = Re();
1664
+ function t(c, p, m) {
1665
+ if (!c.props.bounds) return [p, m];
1865
1666
  let {
1866
- bounds: D
1867
- } = u.props;
1868
- D = typeof D == "string" ? D : m(D);
1869
- const g = h(u);
1870
- if (typeof D == "string") {
1667
+ bounds: T
1668
+ } = c.props;
1669
+ T = typeof T == "string" ? T : x(T);
1670
+ const g = b(c);
1671
+ if (typeof T == "string") {
1871
1672
  const {
1872
- ownerDocument: v
1873
- } = g, w = v.defaultView;
1874
- let T;
1875
- if (D === "parent" ? T = g.parentNode : T = g.getRootNode().querySelector(D), !(T instanceof w.HTMLElement))
1876
- throw new Error('Bounds selector "' + D + '" could not find an element.');
1877
- const C = T, S = w.getComputedStyle(g), l = w.getComputedStyle(C);
1878
- D = {
1673
+ ownerDocument: y
1674
+ } = g, w = y.defaultView;
1675
+ let N;
1676
+ if (T === "parent" ? N = g.parentNode : N = g.getRootNode().querySelector(T), !(N instanceof w.HTMLElement))
1677
+ throw new Error('Bounds selector "' + T + '" could not find an element.');
1678
+ const C = N, S = w.getComputedStyle(g), l = w.getComputedStyle(C);
1679
+ T = {
1879
1680
  left: -g.offsetLeft + (0, e.int)(l.paddingLeft) + (0, e.int)(S.marginLeft),
1880
1681
  top: -g.offsetTop + (0, e.int)(l.paddingTop) + (0, e.int)(S.marginTop),
1881
1682
  right: (0, n.innerWidth)(C) - (0, n.outerWidth)(g) - g.offsetLeft + (0, e.int)(l.paddingRight) - (0, e.int)(S.marginRight),
1882
1683
  bottom: (0, n.innerHeight)(C) - (0, n.outerHeight)(g) - g.offsetTop + (0, e.int)(l.paddingBottom) - (0, e.int)(S.marginBottom)
1883
1684
  };
1884
1685
  }
1885
- return (0, e.isNum)(D.right) && (p = Math.min(p, D.right)), (0, e.isNum)(D.bottom) && (y = Math.min(y, D.bottom)), (0, e.isNum)(D.left) && (p = Math.max(p, D.left)), (0, e.isNum)(D.top) && (y = Math.max(y, D.top)), [p, y];
1686
+ return (0, e.isNum)(T.right) && (p = Math.min(p, T.right)), (0, e.isNum)(T.bottom) && (m = Math.min(m, T.bottom)), (0, e.isNum)(T.left) && (p = Math.max(p, T.left)), (0, e.isNum)(T.top) && (m = Math.max(m, T.top)), [p, m];
1886
1687
  }
1887
- function r(u, p, y) {
1888
- const D = Math.round(p / u[0]) * u[0], g = Math.round(y / u[1]) * u[1];
1889
- return [D, g];
1688
+ function r(c, p, m) {
1689
+ const T = Math.round(p / c[0]) * c[0], g = Math.round(m / c[1]) * c[1];
1690
+ return [T, g];
1890
1691
  }
1891
- function i(u) {
1892
- return u.props.axis === "both" || u.props.axis === "x";
1692
+ function a(c) {
1693
+ return c.props.axis === "both" || c.props.axis === "x";
1893
1694
  }
1894
- function o(u) {
1895
- return u.props.axis === "both" || u.props.axis === "y";
1695
+ function i(c) {
1696
+ return c.props.axis === "both" || c.props.axis === "y";
1896
1697
  }
1897
- function a(u, p, y) {
1898
- const D = typeof p == "number" ? (0, n.getTouch)(u, p) : null;
1899
- if (typeof p == "number" && !D) return null;
1900
- const g = h(y), v = y.props.offsetParent || g.offsetParent || g.ownerDocument.body;
1901
- return (0, n.offsetXYFromParent)(D || u, v, y.props.scale);
1698
+ function d(c, p, m) {
1699
+ const T = typeof p == "number" ? (0, n.getTouch)(c, p) : null;
1700
+ if (typeof p == "number" && !T) return null;
1701
+ const g = b(m), y = m.props.offsetParent || g.offsetParent || g.ownerDocument.body;
1702
+ return (0, n.offsetXYFromParent)(T || c, y, m.props.scale);
1902
1703
  }
1903
- function d(u, p, y) {
1904
- const D = !(0, e.isNum)(u.lastX), g = h(u);
1905
- return D ? {
1704
+ function f(c, p, m) {
1705
+ const T = !(0, e.isNum)(c.lastX), g = b(c);
1706
+ return T ? {
1906
1707
  node: g,
1907
1708
  deltaX: 0,
1908
1709
  deltaY: 0,
1909
1710
  lastX: p,
1910
- lastY: y,
1711
+ lastY: m,
1911
1712
  x: p,
1912
- y
1713
+ y: m
1913
1714
  } : {
1914
1715
  node: g,
1915
- deltaX: p - u.lastX,
1916
- deltaY: y - u.lastY,
1917
- lastX: u.lastX,
1918
- lastY: u.lastY,
1716
+ deltaX: p - c.lastX,
1717
+ deltaY: m - c.lastY,
1718
+ lastX: c.lastX,
1719
+ lastY: c.lastY,
1919
1720
  x: p,
1920
- y
1721
+ y: m
1921
1722
  };
1922
1723
  }
1923
- function b(u, p) {
1924
- const y = u.props.scale;
1724
+ function D(c, p) {
1725
+ const m = c.props.scale;
1925
1726
  return {
1926
1727
  node: p.node,
1927
- x: u.state.x + p.deltaX / y,
1928
- y: u.state.y + p.deltaY / y,
1929
- deltaX: p.deltaX / y,
1930
- deltaY: p.deltaY / y,
1931
- lastX: u.state.x,
1932
- lastY: u.state.y
1728
+ x: c.state.x + p.deltaX / m,
1729
+ y: c.state.y + p.deltaY / m,
1730
+ deltaX: p.deltaX / m,
1731
+ deltaY: p.deltaY / m,
1732
+ lastX: c.state.x,
1733
+ lastY: c.state.y
1933
1734
  };
1934
1735
  }
1935
- function m(u) {
1736
+ function x(c) {
1936
1737
  return {
1937
- left: u.left,
1938
- top: u.top,
1939
- right: u.right,
1940
- bottom: u.bottom
1738
+ left: c.left,
1739
+ top: c.top,
1740
+ right: c.right,
1741
+ bottom: c.bottom
1941
1742
  };
1942
1743
  }
1943
- function h(u) {
1944
- const p = u.findDOMNode();
1744
+ function b(c) {
1745
+ const p = c.findDOMNode();
1945
1746
  if (!p)
1946
1747
  throw new Error("<DraggableCore>: Unmounted during event!");
1947
1748
  return p;
1948
1749
  }
1949
1750
  return ne;
1950
1751
  }
1951
- var he = {}, ve = {}, nt;
1952
- function wt() {
1953
- if (nt) return ve;
1954
- nt = 1, Object.defineProperty(ve, "__esModule", {
1752
+ var fe = {}, ye = {}, et;
1753
+ function pt() {
1754
+ if (et) return ye;
1755
+ et = 1, Object.defineProperty(ye, "__esModule", {
1955
1756
  value: !0
1956
- }), ve.default = e;
1757
+ }), ye.default = e;
1957
1758
  function e() {
1958
1759
  }
1959
- return ve;
1760
+ return ye;
1960
1761
  }
1961
- var rt;
1962
- function mn() {
1963
- if (rt) return he;
1964
- rt = 1, Object.defineProperty(he, "__esModule", {
1762
+ var tt;
1763
+ function on() {
1764
+ if (tt) return fe;
1765
+ tt = 1, Object.defineProperty(fe, "__esModule", {
1965
1766
  value: !0
1966
- }), he.default = void 0;
1967
- var e = b(ae), n = d(/* @__PURE__ */ vt()), t = d(ct), r = Re(), i = xt(), o = we(), a = d(wt());
1968
- function d(g) {
1767
+ }), fe.default = void 0;
1768
+ var e = D(oe), n = f(/* @__PURE__ */ gt()), t = f(at), r = Re(), a = mt(), i = ve(), d = f(pt());
1769
+ function f(g) {
1969
1770
  return g && g.__esModule ? g : { default: g };
1970
1771
  }
1971
- function b(g, v) {
1972
- if (typeof WeakMap == "function") var w = /* @__PURE__ */ new WeakMap(), T = /* @__PURE__ */ new WeakMap();
1973
- return (b = function(C, S) {
1772
+ function D(g, y) {
1773
+ if (typeof WeakMap == "function") var w = /* @__PURE__ */ new WeakMap(), N = /* @__PURE__ */ new WeakMap();
1774
+ return (D = function(C, S) {
1974
1775
  if (!S && C && C.__esModule) return C;
1975
- var l, N, c = { __proto__: null, default: C };
1976
- if (C === null || typeof C != "object" && typeof C != "function") return c;
1977
- if (l = S ? T : w) {
1776
+ var l, M, s = { __proto__: null, default: C };
1777
+ if (C === null || typeof C != "object" && typeof C != "function") return s;
1778
+ if (l = S ? N : w) {
1978
1779
  if (l.has(C)) return l.get(C);
1979
- l.set(C, c);
1780
+ l.set(C, s);
1980
1781
  }
1981
- for (const f in C) f !== "default" && {}.hasOwnProperty.call(C, f) && ((N = (l = Object.defineProperty) && Object.getOwnPropertyDescriptor(C, f)) && (N.get || N.set) ? l(c, f, N) : c[f] = C[f]);
1982
- return c;
1983
- })(g, v);
1782
+ for (const h in C) h !== "default" && {}.hasOwnProperty.call(C, h) && ((M = (l = Object.defineProperty) && Object.getOwnPropertyDescriptor(C, h)) && (M.get || M.set) ? l(s, h, M) : s[h] = C[h]);
1783
+ return s;
1784
+ })(g, y);
1984
1785
  }
1985
- function m(g, v, w) {
1986
- return (v = h(v)) in g ? Object.defineProperty(g, v, { value: w, enumerable: !0, configurable: !0, writable: !0 }) : g[v] = w, g;
1786
+ function x(g, y, w) {
1787
+ return (y = b(y)) in g ? Object.defineProperty(g, y, { value: w, enumerable: !0, configurable: !0, writable: !0 }) : g[y] = w, g;
1987
1788
  }
1988
- function h(g) {
1989
- var v = u(g, "string");
1990
- return typeof v == "symbol" ? v : v + "";
1789
+ function b(g) {
1790
+ var y = c(g, "string");
1791
+ return typeof y == "symbol" ? y : y + "";
1991
1792
  }
1992
- function u(g, v) {
1793
+ function c(g, y) {
1993
1794
  if (typeof g != "object" || !g) return g;
1994
1795
  var w = g[Symbol.toPrimitive];
1995
1796
  if (w !== void 0) {
1996
- var T = w.call(g, v);
1997
- if (typeof T != "object") return T;
1797
+ var N = w.call(g, y);
1798
+ if (typeof N != "object") return N;
1998
1799
  throw new TypeError("@@toPrimitive must return a primitive value.");
1999
1800
  }
2000
- return (v === "string" ? String : Number)(g);
1801
+ return (y === "string" ? String : Number)(g);
2001
1802
  }
2002
1803
  const p = {
2003
1804
  touch: {
@@ -2011,84 +1812,84 @@ function mn() {
2011
1812
  stop: "mouseup"
2012
1813
  }
2013
1814
  };
2014
- let y = p.mouse, D = class extends e.Component {
1815
+ let m = p.mouse, T = class extends e.Component {
2015
1816
  constructor() {
2016
- super(...arguments), m(this, "dragging", !1), m(this, "lastX", NaN), m(this, "lastY", NaN), m(this, "touchIdentifier", null), m(this, "mounted", !1), m(this, "handleDragStart", (v) => {
2017
- if (this.props.onMouseDown(v), !this.props.allowAnyClick && typeof v.button == "number" && v.button !== 0) return !1;
1817
+ super(...arguments), x(this, "dragging", !1), x(this, "lastX", NaN), x(this, "lastY", NaN), x(this, "touchIdentifier", null), x(this, "mounted", !1), x(this, "handleDragStart", (y) => {
1818
+ if (this.props.onMouseDown(y), !this.props.allowAnyClick && typeof y.button == "number" && y.button !== 0) return !1;
2018
1819
  const w = this.findDOMNode();
2019
1820
  if (!w || !w.ownerDocument || !w.ownerDocument.body)
2020
1821
  throw new Error("<DraggableCore> not mounted on DragStart!");
2021
1822
  const {
2022
- ownerDocument: T
1823
+ ownerDocument: N
2023
1824
  } = w;
2024
- if (this.props.disabled || !(v.target instanceof T.defaultView.Node) || this.props.handle && !(0, r.matchesSelectorAndParentsTo)(v.target, this.props.handle, w) || this.props.cancel && (0, r.matchesSelectorAndParentsTo)(v.target, this.props.cancel, w))
1825
+ if (this.props.disabled || !(y.target instanceof N.defaultView.Node) || this.props.handle && !(0, r.matchesSelectorAndParentsTo)(y.target, this.props.handle, w) || this.props.cancel && (0, r.matchesSelectorAndParentsTo)(y.target, this.props.cancel, w))
2025
1826
  return;
2026
- v.type === "touchstart" && !this.props.allowMobileScroll && v.preventDefault();
2027
- const C = (0, r.getTouchIdentifier)(v);
1827
+ y.type === "touchstart" && !this.props.allowMobileScroll && y.preventDefault();
1828
+ const C = (0, r.getTouchIdentifier)(y);
2028
1829
  this.touchIdentifier = C;
2029
- const S = (0, i.getControlPosition)(v, C, this);
1830
+ const S = (0, a.getControlPosition)(y, C, this);
2030
1831
  if (S == null) return;
2031
1832
  const {
2032
1833
  x: l,
2033
- y: N
2034
- } = S, c = (0, i.createCoreData)(this, l, N);
2035
- (0, a.default)("DraggableCore: handleDragStart: %j", c), (0, a.default)("calling", this.props.onStart), !(this.props.onStart(v, c) === !1 || this.mounted === !1) && (this.props.enableUserSelectHack && (0, r.addUserSelectStyles)(T), this.dragging = !0, this.lastX = l, this.lastY = N, (0, r.addEvent)(T, y.move, this.handleDrag), (0, r.addEvent)(T, y.stop, this.handleDragStop));
2036
- }), m(this, "handleDrag", (v) => {
2037
- const w = (0, i.getControlPosition)(v, this.touchIdentifier, this);
1834
+ y: M
1835
+ } = S, s = (0, a.createCoreData)(this, l, M);
1836
+ (0, d.default)("DraggableCore: handleDragStart: %j", s), (0, d.default)("calling", this.props.onStart), !(this.props.onStart(y, s) === !1 || this.mounted === !1) && (this.props.enableUserSelectHack && (0, r.addUserSelectStyles)(N), this.dragging = !0, this.lastX = l, this.lastY = M, (0, r.addEvent)(N, m.move, this.handleDrag), (0, r.addEvent)(N, m.stop, this.handleDragStop));
1837
+ }), x(this, "handleDrag", (y) => {
1838
+ const w = (0, a.getControlPosition)(y, this.touchIdentifier, this);
2038
1839
  if (w == null) return;
2039
1840
  let {
2040
- x: T,
1841
+ x: N,
2041
1842
  y: C
2042
1843
  } = w;
2043
1844
  if (Array.isArray(this.props.grid)) {
2044
- let N = T - this.lastX, c = C - this.lastY;
2045
- if ([N, c] = (0, i.snapToGrid)(this.props.grid, N, c), !N && !c) return;
2046
- T = this.lastX + N, C = this.lastY + c;
1845
+ let M = N - this.lastX, s = C - this.lastY;
1846
+ if ([M, s] = (0, a.snapToGrid)(this.props.grid, M, s), !M && !s) return;
1847
+ N = this.lastX + M, C = this.lastY + s;
2047
1848
  }
2048
- const S = (0, i.createCoreData)(this, T, C);
2049
- if ((0, a.default)("DraggableCore: handleDrag: %j", S), this.props.onDrag(v, S) === !1 || this.mounted === !1) {
1849
+ const S = (0, a.createCoreData)(this, N, C);
1850
+ if ((0, d.default)("DraggableCore: handleDrag: %j", S), this.props.onDrag(y, S) === !1 || this.mounted === !1) {
2050
1851
  try {
2051
1852
  this.handleDragStop(new MouseEvent("mouseup"));
2052
1853
  } catch {
2053
- const c = document.createEvent("MouseEvents");
2054
- c.initMouseEvent("mouseup", !0, !0, window, 0, 0, 0, 0, 0, !1, !1, !1, !1, 0, null), this.handleDragStop(c);
1854
+ const s = document.createEvent("MouseEvents");
1855
+ s.initMouseEvent("mouseup", !0, !0, window, 0, 0, 0, 0, 0, !1, !1, !1, !1, 0, null), this.handleDragStop(s);
2055
1856
  }
2056
1857
  return;
2057
1858
  }
2058
- this.lastX = T, this.lastY = C;
2059
- }), m(this, "handleDragStop", (v) => {
1859
+ this.lastX = N, this.lastY = C;
1860
+ }), x(this, "handleDragStop", (y) => {
2060
1861
  if (!this.dragging) return;
2061
- const w = (0, i.getControlPosition)(v, this.touchIdentifier, this);
1862
+ const w = (0, a.getControlPosition)(y, this.touchIdentifier, this);
2062
1863
  if (w == null) return;
2063
1864
  let {
2064
- x: T,
1865
+ x: N,
2065
1866
  y: C
2066
1867
  } = w;
2067
1868
  if (Array.isArray(this.props.grid)) {
2068
- let c = T - this.lastX || 0, f = C - this.lastY || 0;
2069
- [c, f] = (0, i.snapToGrid)(this.props.grid, c, f), T = this.lastX + c, C = this.lastY + f;
1869
+ let s = N - this.lastX || 0, h = C - this.lastY || 0;
1870
+ [s, h] = (0, a.snapToGrid)(this.props.grid, s, h), N = this.lastX + s, C = this.lastY + h;
2070
1871
  }
2071
- const S = (0, i.createCoreData)(this, T, C);
2072
- if (this.props.onStop(v, S) === !1 || this.mounted === !1) return !1;
2073
- const N = this.findDOMNode();
2074
- N && this.props.enableUserSelectHack && (0, r.scheduleRemoveUserSelectStyles)(N.ownerDocument), (0, a.default)("DraggableCore: handleDragStop: %j", S), this.dragging = !1, this.lastX = NaN, this.lastY = NaN, N && ((0, a.default)("DraggableCore: Removing handlers"), (0, r.removeEvent)(N.ownerDocument, y.move, this.handleDrag), (0, r.removeEvent)(N.ownerDocument, y.stop, this.handleDragStop));
2075
- }), m(this, "onMouseDown", (v) => (y = p.mouse, this.handleDragStart(v))), m(this, "onMouseUp", (v) => (y = p.mouse, this.handleDragStop(v))), m(this, "onTouchStart", (v) => (y = p.touch, this.handleDragStart(v))), m(this, "onTouchEnd", (v) => (y = p.touch, this.handleDragStop(v)));
1872
+ const S = (0, a.createCoreData)(this, N, C);
1873
+ if (this.props.onStop(y, S) === !1 || this.mounted === !1) return !1;
1874
+ const M = this.findDOMNode();
1875
+ M && this.props.enableUserSelectHack && (0, r.scheduleRemoveUserSelectStyles)(M.ownerDocument), (0, d.default)("DraggableCore: handleDragStop: %j", S), this.dragging = !1, this.lastX = NaN, this.lastY = NaN, M && ((0, d.default)("DraggableCore: Removing handlers"), (0, r.removeEvent)(M.ownerDocument, m.move, this.handleDrag), (0, r.removeEvent)(M.ownerDocument, m.stop, this.handleDragStop));
1876
+ }), x(this, "onMouseDown", (y) => (m = p.mouse, this.handleDragStart(y))), x(this, "onMouseUp", (y) => (m = p.mouse, this.handleDragStop(y))), x(this, "onTouchStart", (y) => (m = p.touch, this.handleDragStart(y))), x(this, "onTouchEnd", (y) => (m = p.touch, this.handleDragStop(y)));
2076
1877
  }
2077
1878
  componentDidMount() {
2078
1879
  this.mounted = !0;
2079
- const v = this.findDOMNode();
2080
- v && (0, r.addEvent)(v, p.touch.start, this.onTouchStart, {
1880
+ const y = this.findDOMNode();
1881
+ y && (0, r.addEvent)(y, p.touch.start, this.onTouchStart, {
2081
1882
  passive: !1
2082
1883
  });
2083
1884
  }
2084
1885
  componentWillUnmount() {
2085
1886
  this.mounted = !1;
2086
- const v = this.findDOMNode();
2087
- if (v) {
1887
+ const y = this.findDOMNode();
1888
+ if (y) {
2088
1889
  const {
2089
1890
  ownerDocument: w
2090
- } = v;
2091
- (0, r.removeEvent)(w, p.mouse.move, this.handleDrag), (0, r.removeEvent)(w, p.touch.move, this.handleDrag), (0, r.removeEvent)(w, p.mouse.stop, this.handleDragStop), (0, r.removeEvent)(w, p.touch.stop, this.handleDragStop), (0, r.removeEvent)(v, p.touch.start, this.onTouchStart, {
1891
+ } = y;
1892
+ (0, r.removeEvent)(w, p.mouse.move, this.handleDrag), (0, r.removeEvent)(w, p.touch.move, this.handleDrag), (0, r.removeEvent)(w, p.mouse.stop, this.handleDragStop), (0, r.removeEvent)(w, p.touch.stop, this.handleDragStop), (0, r.removeEvent)(y, p.touch.start, this.onTouchStart, {
2092
1893
  passive: !1
2093
1894
  }), this.props.enableUserSelectHack && (0, r.scheduleRemoveUserSelectStyles)(w);
2094
1895
  }
@@ -2111,7 +1912,7 @@ function mn() {
2111
1912
  });
2112
1913
  }
2113
1914
  };
2114
- return he.default = D, m(D, "displayName", "DraggableCore"), m(D, "propTypes", {
1915
+ return fe.default = T, x(T, "displayName", "DraggableCore"), x(T, "propTypes", {
2115
1916
  /**
2116
1917
  * `allowAnyClick` allows dragging using any mouse button.
2117
1918
  * By default, we only accept the left button.
@@ -2143,8 +1944,8 @@ function mn() {
2143
1944
  * `offsetParent`, if set, uses the passed DOM node to compute drag offsets
2144
1945
  * instead of using the parent node.
2145
1946
  */
2146
- offsetParent: function(g, v) {
2147
- if (g[v] && g[v].nodeType !== 1)
1947
+ offsetParent: function(g, y) {
1948
+ if (g[y] && g[y].nodeType !== 1)
2148
1949
  throw new Error("Draggable's offsetParent must be a DOM Node.");
2149
1950
  },
2150
1951
  /**
@@ -2238,10 +2039,10 @@ function mn() {
2238
2039
  /**
2239
2040
  * These properties should be defined on the child, not here.
2240
2041
  */
2241
- className: o.dontSetMe,
2242
- style: o.dontSetMe,
2243
- transform: o.dontSetMe
2244
- }), m(D, "defaultProps", {
2042
+ className: i.dontSetMe,
2043
+ style: i.dontSetMe,
2044
+ transform: i.dontSetMe
2045
+ }), x(T, "defaultProps", {
2245
2046
  allowAnyClick: !1,
2246
2047
  // by default only accept left click
2247
2048
  allowMobileScroll: !1,
@@ -2256,73 +2057,73 @@ function mn() {
2256
2057
  onMouseDown: function() {
2257
2058
  },
2258
2059
  scale: 1
2259
- }), he;
2060
+ }), fe;
2260
2061
  }
2261
- var ot;
2262
- function pn() {
2263
- return ot || (ot = 1, (function(e) {
2062
+ var nt;
2063
+ function an() {
2064
+ return nt || (nt = 1, (function(e) {
2264
2065
  Object.defineProperty(e, "__esModule", {
2265
2066
  value: !0
2266
2067
  }), Object.defineProperty(e, "DraggableCore", {
2267
2068
  enumerable: !0,
2268
2069
  get: function() {
2269
- return b.default;
2070
+ return D.default;
2270
2071
  }
2271
2072
  }), e.default = void 0;
2272
- var n = u(ae), t = h(/* @__PURE__ */ vt()), r = h(ct), i = hn(), o = Re(), a = xt(), d = we(), b = h(mn()), m = h(wt());
2273
- function h(w) {
2073
+ var n = c(oe), t = b(/* @__PURE__ */ gt()), r = b(at), a = nn(), i = Re(), d = mt(), f = ve(), D = b(on()), x = b(pt());
2074
+ function b(w) {
2274
2075
  return w && w.__esModule ? w : { default: w };
2275
2076
  }
2276
- function u(w, T) {
2077
+ function c(w, N) {
2277
2078
  if (typeof WeakMap == "function") var C = /* @__PURE__ */ new WeakMap(), S = /* @__PURE__ */ new WeakMap();
2278
- return (u = function(l, N) {
2279
- if (!N && l && l.__esModule) return l;
2280
- var c, f, M = { __proto__: null, default: l };
2281
- if (l === null || typeof l != "object" && typeof l != "function") return M;
2282
- if (c = N ? S : C) {
2283
- if (c.has(l)) return c.get(l);
2284
- c.set(l, M);
2079
+ return (c = function(l, M) {
2080
+ if (!M && l && l.__esModule) return l;
2081
+ var s, h, u = { __proto__: null, default: l };
2082
+ if (l === null || typeof l != "object" && typeof l != "function") return u;
2083
+ if (s = M ? S : C) {
2084
+ if (s.has(l)) return s.get(l);
2085
+ s.set(l, u);
2285
2086
  }
2286
- for (const $ in l) $ !== "default" && {}.hasOwnProperty.call(l, $) && ((f = (c = Object.defineProperty) && Object.getOwnPropertyDescriptor(l, $)) && (f.get || f.set) ? c(M, $, f) : M[$] = l[$]);
2287
- return M;
2288
- })(w, T);
2087
+ for (const _ in l) _ !== "default" && {}.hasOwnProperty.call(l, _) && ((h = (s = Object.defineProperty) && Object.getOwnPropertyDescriptor(l, _)) && (h.get || h.set) ? s(u, _, h) : u[_] = l[_]);
2088
+ return u;
2089
+ })(w, N);
2289
2090
  }
2290
2091
  function p() {
2291
2092
  return p = Object.assign ? Object.assign.bind() : function(w) {
2292
- for (var T = 1; T < arguments.length; T++) {
2293
- var C = arguments[T];
2093
+ for (var N = 1; N < arguments.length; N++) {
2094
+ var C = arguments[N];
2294
2095
  for (var S in C) ({}).hasOwnProperty.call(C, S) && (w[S] = C[S]);
2295
2096
  }
2296
2097
  return w;
2297
2098
  }, p.apply(null, arguments);
2298
2099
  }
2299
- function y(w, T, C) {
2300
- return (T = D(T)) in w ? Object.defineProperty(w, T, { value: C, enumerable: !0, configurable: !0, writable: !0 }) : w[T] = C, w;
2100
+ function m(w, N, C) {
2101
+ return (N = T(N)) in w ? Object.defineProperty(w, N, { value: C, enumerable: !0, configurable: !0, writable: !0 }) : w[N] = C, w;
2301
2102
  }
2302
- function D(w) {
2303
- var T = g(w, "string");
2304
- return typeof T == "symbol" ? T : T + "";
2103
+ function T(w) {
2104
+ var N = g(w, "string");
2105
+ return typeof N == "symbol" ? N : N + "";
2305
2106
  }
2306
- function g(w, T) {
2107
+ function g(w, N) {
2307
2108
  if (typeof w != "object" || !w) return w;
2308
2109
  var C = w[Symbol.toPrimitive];
2309
2110
  if (C !== void 0) {
2310
- var S = C.call(w, T);
2111
+ var S = C.call(w, N);
2311
2112
  if (typeof S != "object") return S;
2312
2113
  throw new TypeError("@@toPrimitive must return a primitive value.");
2313
2114
  }
2314
- return (T === "string" ? String : Number)(w);
2115
+ return (N === "string" ? String : Number)(w);
2315
2116
  }
2316
- class v extends n.Component {
2117
+ class y extends n.Component {
2317
2118
  // React 16.3+
2318
2119
  // Arity (props, state)
2319
- static getDerivedStateFromProps(T, C) {
2120
+ static getDerivedStateFromProps(N, C) {
2320
2121
  let {
2321
2122
  position: S
2322
- } = T, {
2123
+ } = N, {
2323
2124
  prevPropsPosition: l
2324
2125
  } = C;
2325
- return S && (!l || S.x !== l.x || S.y !== l.y) ? ((0, m.default)("Draggable: getDerivedStateFromProps %j", {
2126
+ return S && (!l || S.x !== l.x || S.y !== l.y) ? ((0, x.default)("Draggable: getDerivedStateFromProps %j", {
2326
2127
  position: S,
2327
2128
  prevPropsPosition: l
2328
2129
  }), {
@@ -2333,17 +2134,17 @@ function pn() {
2333
2134
  }
2334
2135
  }) : null;
2335
2136
  }
2336
- constructor(T) {
2337
- super(T), y(this, "onDragStart", (C, S) => {
2338
- if ((0, m.default)("Draggable: onDragStart: %j", S), this.props.onStart(C, (0, a.createDraggableData)(this, S)) === !1) return !1;
2137
+ constructor(N) {
2138
+ super(N), m(this, "onDragStart", (C, S) => {
2139
+ if ((0, x.default)("Draggable: onDragStart: %j", S), this.props.onStart(C, (0, d.createDraggableData)(this, S)) === !1) return !1;
2339
2140
  this.setState({
2340
2141
  dragging: !0,
2341
2142
  dragged: !0
2342
2143
  });
2343
- }), y(this, "onDrag", (C, S) => {
2144
+ }), m(this, "onDrag", (C, S) => {
2344
2145
  if (!this.state.dragging) return !1;
2345
- (0, m.default)("Draggable: onDrag: %j", S);
2346
- const l = (0, a.createDraggableData)(this, S), N = {
2146
+ (0, x.default)("Draggable: onDrag: %j", S);
2147
+ const l = (0, d.createDraggableData)(this, S), M = {
2347
2148
  x: l.x,
2348
2149
  y: l.y,
2349
2150
  slackX: 0,
@@ -2351,48 +2152,48 @@ function pn() {
2351
2152
  };
2352
2153
  if (this.props.bounds) {
2353
2154
  const {
2354
- x: f,
2355
- y: M
2356
- } = N;
2357
- N.x += this.state.slackX, N.y += this.state.slackY;
2358
- const [$, I] = (0, a.getBoundPosition)(this, N.x, N.y);
2359
- N.x = $, N.y = I, N.slackX = this.state.slackX + (f - N.x), N.slackY = this.state.slackY + (M - N.y), l.x = N.x, l.y = N.y, l.deltaX = N.x - this.state.x, l.deltaY = N.y - this.state.y;
2155
+ x: h,
2156
+ y: u
2157
+ } = M;
2158
+ M.x += this.state.slackX, M.y += this.state.slackY;
2159
+ const [_, I] = (0, d.getBoundPosition)(this, M.x, M.y);
2160
+ M.x = _, M.y = I, M.slackX = this.state.slackX + (h - M.x), M.slackY = this.state.slackY + (u - M.y), l.x = M.x, l.y = M.y, l.deltaX = M.x - this.state.x, l.deltaY = M.y - this.state.y;
2360
2161
  }
2361
2162
  if (this.props.onDrag(C, l) === !1) return !1;
2362
- this.setState(N);
2363
- }), y(this, "onDragStop", (C, S) => {
2364
- if (!this.state.dragging || this.props.onStop(C, (0, a.createDraggableData)(this, S)) === !1) return !1;
2365
- (0, m.default)("Draggable: onDragStop: %j", S);
2366
- const N = {
2163
+ this.setState(M);
2164
+ }), m(this, "onDragStop", (C, S) => {
2165
+ if (!this.state.dragging || this.props.onStop(C, (0, d.createDraggableData)(this, S)) === !1) return !1;
2166
+ (0, x.default)("Draggable: onDragStop: %j", S);
2167
+ const M = {
2367
2168
  dragging: !1,
2368
2169
  slackX: 0,
2369
2170
  slackY: 0
2370
2171
  };
2371
2172
  if (!!this.props.position) {
2372
2173
  const {
2373
- x: f,
2374
- y: M
2174
+ x: h,
2175
+ y: u
2375
2176
  } = this.props.position;
2376
- N.x = f, N.y = M;
2177
+ M.x = h, M.y = u;
2377
2178
  }
2378
- this.setState(N);
2179
+ this.setState(M);
2379
2180
  }), this.state = {
2380
2181
  // Whether or not we are currently dragging.
2381
2182
  dragging: !1,
2382
2183
  // Whether or not we have been dragged before.
2383
2184
  dragged: !1,
2384
2185
  // Current transform x and y.
2385
- x: T.position ? T.position.x : T.defaultPosition.x,
2386
- y: T.position ? T.position.y : T.defaultPosition.y,
2186
+ x: N.position ? N.position.x : N.defaultPosition.x,
2187
+ y: N.position ? N.position.y : N.defaultPosition.y,
2387
2188
  prevPropsPosition: {
2388
- ...T.position
2189
+ ...N.position
2389
2190
  },
2390
2191
  // Used for compensating for out-of-bounds drags
2391
2192
  slackX: 0,
2392
2193
  slackY: 0,
2393
2194
  // Can only determine if SVG after mounting
2394
2195
  isElementSVG: !1
2395
- }, T.position && !(T.onDrag || T.onStop) && console.warn("A `position` was applied to this <Draggable>, without drag handlers. This will make this component effectively undraggable. Please attach `onDrag` or `onStop` handlers so you can adjust the `position` of this element.");
2196
+ }, N.position && !(N.onDrag || N.onStop) && console.warn("A `position` was applied to this <Draggable>, without drag handlers. This will make this component effectively undraggable. Please attach `onDrag` or `onStop` handlers so you can adjust the `position` of this element.");
2396
2197
  }
2397
2198
  componentDidMount() {
2398
2199
  typeof window.SVGElement < "u" && this.findDOMNode() instanceof window.SVGElement && this.setState({
@@ -2411,31 +2212,31 @@ function pn() {
2411
2212
  }
2412
2213
  render() {
2413
2214
  const {
2414
- axis: T,
2215
+ axis: N,
2415
2216
  bounds: C,
2416
2217
  children: S,
2417
2218
  defaultPosition: l,
2418
- defaultClassName: N,
2419
- defaultClassNameDragging: c,
2420
- defaultClassNameDragged: f,
2421
- position: M,
2422
- positionOffset: $,
2219
+ defaultClassName: M,
2220
+ defaultClassNameDragging: s,
2221
+ defaultClassNameDragged: h,
2222
+ position: u,
2223
+ positionOffset: _,
2423
2224
  scale: I,
2424
- ...E
2225
+ ...B
2425
2226
  } = this.props;
2426
- let z = {}, X = null;
2427
- const K = !!!M || this.state.dragging, ee = M || l, se = {
2227
+ let H = {}, X = null;
2228
+ const z = !!!u || this.state.dragging, ee = u || l, ae = {
2428
2229
  // Set left if horizontal drag is enabled
2429
- x: (0, a.canDragX)(this) && K ? this.state.x : ee.x,
2230
+ x: (0, d.canDragX)(this) && z ? this.state.x : ee.x,
2430
2231
  // Set top if vertical drag is enabled
2431
- y: (0, a.canDragY)(this) && K ? this.state.y : ee.y
2232
+ y: (0, d.canDragY)(this) && z ? this.state.y : ee.y
2432
2233
  };
2433
- this.state.isElementSVG ? X = (0, o.createSVGTransform)(se, $) : z = (0, o.createCSSTransform)(se, $);
2434
- const de = (0, i.clsx)(S.props.className || "", N, {
2435
- [c]: this.state.dragging,
2436
- [f]: this.state.dragged
2234
+ this.state.isElementSVG ? X = (0, i.createSVGTransform)(ae, _) : H = (0, i.createCSSTransform)(ae, _);
2235
+ const de = (0, a.clsx)(S.props.className || "", M, {
2236
+ [s]: this.state.dragging,
2237
+ [h]: this.state.dragged
2437
2238
  });
2438
- return /* @__PURE__ */ n.createElement(b.default, p({}, E, {
2239
+ return /* @__PURE__ */ n.createElement(D.default, p({}, B, {
2439
2240
  onStart: this.onDragStart,
2440
2241
  onDrag: this.onDrag,
2441
2242
  onStop: this.onDragStop
@@ -2443,15 +2244,15 @@ function pn() {
2443
2244
  className: de,
2444
2245
  style: {
2445
2246
  ...S.props.style,
2446
- ...z
2247
+ ...H
2447
2248
  },
2448
2249
  transform: X
2449
2250
  }));
2450
2251
  }
2451
2252
  }
2452
- e.default = v, y(v, "displayName", "Draggable"), y(v, "propTypes", {
2253
+ e.default = y, m(y, "displayName", "Draggable"), m(y, "propTypes", {
2453
2254
  // Accepts all props <DraggableCore> accepts.
2454
- ...b.default.propTypes,
2255
+ ...D.default.propTypes,
2455
2256
  /**
2456
2257
  * `axis` determines which axis the draggable can move.
2457
2258
  *
@@ -2553,11 +2354,11 @@ function pn() {
2553
2354
  /**
2554
2355
  * These properties should be defined on the child, not here.
2555
2356
  */
2556
- className: d.dontSetMe,
2557
- style: d.dontSetMe,
2558
- transform: d.dontSetMe
2559
- }), y(v, "defaultProps", {
2560
- ...b.default.defaultProps,
2357
+ className: f.dontSetMe,
2358
+ style: f.dontSetMe,
2359
+ transform: f.dontSetMe
2360
+ }), m(y, "defaultProps", {
2361
+ ...D.default.defaultProps,
2561
2362
  axis: "both",
2562
2363
  bounds: !1,
2563
2364
  defaultClassName: "react-draggable",
@@ -2569,20 +2370,20 @@ function pn() {
2569
2370
  },
2570
2371
  scale: 1
2571
2372
  });
2572
- })(De)), De;
2373
+ })(Ce)), Ce;
2573
2374
  }
2574
- var it;
2575
- function yn() {
2576
- if (it) return fe.exports;
2577
- it = 1;
2375
+ var rt;
2376
+ function sn() {
2377
+ if (rt) return ue.exports;
2378
+ rt = 1;
2578
2379
  const {
2579
2380
  default: e,
2580
2381
  DraggableCore: n
2581
- } = pn();
2582
- return fe.exports = e, fe.exports.default = e, fe.exports.DraggableCore = n, fe.exports;
2382
+ } = an();
2383
+ return ue.exports = e, ue.exports.default = e, ue.exports.DraggableCore = n, ue.exports;
2583
2384
  }
2584
- var bn = yn();
2585
- const vn = /* @__PURE__ */ an(bn), xn = le((e, n) => {
2385
+ var ln = sn();
2386
+ const dn = /* @__PURE__ */ Xt(ln), cn = le((e, n) => {
2586
2387
  const r = {
2587
2388
  ...{
2588
2389
  // 1. Take it out of the document flow
@@ -2600,35 +2401,35 @@ const vn = /* @__PURE__ */ an(bn), xn = le((e, n) => {
2600
2401
  boxShadow: "rgba(0, 0, 0, 0.5) 7px 7px 10px 0px"
2601
2402
  },
2602
2403
  ...e.style || {}
2603
- }, i = e.testId || "not-set", o = e.className || "panel", a = Ct(null);
2404
+ }, a = e.testId || "not-set", i = e.className || "panel", d = yt(null);
2604
2405
  return (
2605
2406
  // 3. Pass the internal ref to the Draggable component via 'nodeRef'
2606
- /* @__PURE__ */ s(
2607
- vn,
2407
+ /* @__PURE__ */ o(
2408
+ dn,
2608
2409
  {
2609
- nodeRef: a,
2610
- "data-testid": i,
2410
+ nodeRef: d,
2411
+ "data-testid": a,
2611
2412
  axis: "both",
2612
2413
  handle: ".handle",
2613
- onStart: (m, h) => {
2414
+ onStart: (x, b) => {
2614
2415
  e.onDraggingChange?.(!0);
2615
2416
  },
2616
- onStop: (m, h) => {
2417
+ onStop: (x, b) => {
2617
2418
  setTimeout(() => {
2618
2419
  e.onDraggingChange?.(!1);
2619
2420
  }, 100);
2620
2421
  },
2621
- children: /* @__PURE__ */ s("div", { ref: a, className: o, style: r, children: e.children })
2422
+ children: /* @__PURE__ */ o("div", { ref: d, className: i, style: r, children: e.children })
2622
2423
  }
2623
2424
  )
2624
2425
  );
2625
2426
  });
2626
- function tr({ children: e, addCssClasses: n }) {
2427
+ function jn({ children: e, addCssClasses: n }) {
2627
2428
  const t = G(
2628
2429
  "w-full h-full flex-1 flex flex-col",
2629
2430
  (n || "gap-2 items-end justify-end content-end").trim()
2630
2431
  );
2631
- return /* @__PURE__ */ s(
2432
+ return /* @__PURE__ */ o(
2632
2433
  "div",
2633
2434
  {
2634
2435
  className: t,
@@ -2639,54 +2440,54 @@ function tr({ children: e, addCssClasses: n }) {
2639
2440
  }
2640
2441
  );
2641
2442
  }
2642
- function nr({ children: e, addCssClasses: n }) {
2443
+ function An({ children: e, addCssClasses: n }) {
2643
2444
  const t = G(
2644
2445
  "w-full flex flex-col",
2645
2446
  (n || "items-end").trim()
2646
2447
  );
2647
- return /* @__PURE__ */ s("div", { className: t, children: e });
2448
+ return /* @__PURE__ */ o("div", { className: t, children: e });
2648
2449
  }
2649
- const rr = (e) => {
2450
+ const Ln = (e) => {
2650
2451
  console.warn("showToast TODO", e);
2651
- }, wn = (e) => e < 0.8 ? 1 : e <= 1 ? 0 : e > 1 ? -1 : 0, or = le((e, n) => {
2652
- let t = lt(Number(e.zoomScale || 0));
2653
- const r = e.responsiveGrid || !1, i = e.isEditing || !1, o = {
2452
+ }, un = (e) => e < 0.8 ? 1 : e <= 1 ? 0 : e > 1 ? -1 : 0, Un = le((e, n) => {
2453
+ let t = Mt(Number(e.zoomScale || 0));
2454
+ const r = e.responsiveGrid || !1, a = e.isEditing || !1, i = {
2654
2455
  "--bwj-dashboard-transform-scale": t,
2655
- "--bwj-dashboard-add-cols": wn(t)
2656
- }, a = G(
2456
+ "--bwj-dashboard-add-cols": un(t)
2457
+ }, d = G(
2657
2458
  "dashboard-main-grid w-full",
2658
- i ? "editing" : "",
2459
+ a ? "editing" : "",
2659
2460
  r ? "responsive-grid" : "",
2660
- `border border-dashed ${i ? "border-primary border-opacity-50" : "border-transparent"}`
2461
+ `border border-dashed ${a ? "border-primary border-opacity-50" : "border-transparent"}`
2661
2462
  );
2662
- return /* @__PURE__ */ s("div", { className: a, style: o, children: e.children });
2663
- }), $e = "size-5", Cn = (e, n) => {
2463
+ return /* @__PURE__ */ o("div", { className: d, style: i, children: e.children });
2464
+ }), Me = "size-5", fn = (e, n) => {
2664
2465
  const t = e.hideTitle && !e.isEditing, r = e.noBorder;
2665
- let i = `dashboard-widget ${e.isEditing ? "editing" : ""} border border-solid`;
2666
- r ? i = `${i} border-transparent border-opacity-0` : (e.borderCssClasses || "").trim().length > 0 ? i = `${i} ${e.borderCssClasses}` : i = `${i} border-card-invert border-opacity-20`, e.noShadow && (i = `${i} no-shadow`), e.noPadding && (i = `${i} no-padding p-0`), (e.backgroundCssClasses || "").trim().length > 0 ? i = `${i} ${e.backgroundCssClasses}` : i = `${i} bg-card content-card`, ["large", "xlarge"].indexOf(e.size || "") > -1 && (i = `${i} ${e.size}-widget`);
2667
- const o = () => {
2466
+ let a = `dashboard-widget ${e.isEditing ? "editing" : ""} border border-solid`;
2467
+ r ? a = `${a} border-transparent border-opacity-0` : (e.borderCssClasses || "").trim().length > 0 ? a = `${a} ${e.borderCssClasses}` : a = `${a} border-card-invert border-opacity-20`, e.noShadow && (a = `${a} no-shadow`), e.noPadding && (a = `${a} no-padding p-0`), (e.backgroundCssClasses || "").trim().length > 0 ? a = `${a} ${e.backgroundCssClasses}` : a = `${a} bg-card content-card`, ["large", "xlarge"].indexOf(e.size || "") > -1 && (a = `${a} ${e.size}-widget`);
2468
+ const i = () => {
2668
2469
  e.onRemoveClick && e.widgetKey && e.onRemoveClick(e.widgetKey, e.parentWidgetKey);
2669
- }, a = (b) => {
2670
- e.onMoveClick && e.widgetKey && e.onMoveClick(b, e.widgetKey, e.parentWidgetKey);
2671
- }, d = G(
2470
+ }, d = (D) => {
2471
+ e.onMoveClick && e.widgetKey && e.onMoveClick(D, e.widgetKey, e.parentWidgetKey);
2472
+ }, f = G(
2672
2473
  "widget-header",
2673
2474
  t ? "hidden" : "flex items-center justify-between border-b border-solid border-card-invert",
2674
2475
  t ? "border-opacity-0" : "border-opacity-20"
2675
2476
  );
2676
- return /* @__PURE__ */ W("div", { className: i, children: [
2677
- /* @__PURE__ */ W("div", { className: d, children: [
2678
- /* @__PURE__ */ W("div", { className: "widget-title-wrapper w-full flex flex-row gap-2 items-center justify-between", children: [
2679
- /* @__PURE__ */ W("h2", { className: "widget-title", children: [
2477
+ return /* @__PURE__ */ $("div", { className: a, children: [
2478
+ /* @__PURE__ */ $("div", { className: f, children: [
2479
+ /* @__PURE__ */ $("div", { className: "widget-title-wrapper w-full flex flex-row gap-2 items-center justify-between", children: [
2480
+ /* @__PURE__ */ $("h2", { className: "widget-title", children: [
2680
2481
  e.title,
2681
2482
  " "
2682
2483
  ] }),
2683
- /* @__PURE__ */ s("div", {})
2484
+ /* @__PURE__ */ o("div", {})
2684
2485
  ] }),
2685
- /* @__PURE__ */ s("div", { "data-testid": "collapse-and-other-actions", children: /* @__PURE__ */ W("div", { className: "actions-inner", children: [
2686
- /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s("span", { className: "hidden", children: "Widget" }) }),
2687
- /* @__PURE__ */ W("div", { className: "actions-buttons-container", children: [
2688
- /* @__PURE__ */ s(
2689
- J,
2486
+ /* @__PURE__ */ o("div", { "data-testid": "collapse-and-other-actions", children: /* @__PURE__ */ $("div", { className: "actions-inner", children: [
2487
+ /* @__PURE__ */ o("div", { children: /* @__PURE__ */ o("span", { className: "hidden", children: "Widget" }) }),
2488
+ /* @__PURE__ */ $("div", { className: "actions-buttons-container", children: [
2489
+ /* @__PURE__ */ o(
2490
+ Z,
2690
2491
  {
2691
2492
  "data-testid": `move-widget-left_${e.title}`,
2692
2493
  isIconButton: !0,
@@ -2695,12 +2496,12 @@ const rr = (e) => {
2695
2496
  placement: "top",
2696
2497
  title: `${e.index < 1 ? "Already at min position" : "Move Widget to the left/up"}`
2697
2498
  },
2698
- onClick: () => a(-1),
2699
- children: /* @__PURE__ */ s(ft, { className: $e })
2499
+ onClick: () => d(-1),
2500
+ children: /* @__PURE__ */ o(lt, { className: Me })
2700
2501
  }
2701
2502
  ),
2702
- /* @__PURE__ */ s(
2703
- J,
2503
+ /* @__PURE__ */ o(
2504
+ Z,
2704
2505
  {
2705
2506
  "data-testid": `move-widget-right_${e.title}`,
2706
2507
  isIconButton: !0,
@@ -2709,12 +2510,12 @@ const rr = (e) => {
2709
2510
  placement: "top",
2710
2511
  title: `${e.index >= e.maxIndex ? "Already at max position" : "Move Widget to the right/down"}`
2711
2512
  },
2712
- onClick: () => a(1),
2713
- children: /* @__PURE__ */ s(ht, { className: $e })
2513
+ onClick: () => d(1),
2514
+ children: /* @__PURE__ */ o(dt, { className: Me })
2714
2515
  }
2715
2516
  ),
2716
- /* @__PURE__ */ s(
2717
- J,
2517
+ /* @__PURE__ */ o(
2518
+ Z,
2718
2519
  {
2719
2520
  "data-testid": `remove-container_${e.title}`,
2720
2521
  isIconButton: !0,
@@ -2722,95 +2523,95 @@ const rr = (e) => {
2722
2523
  placement: "top",
2723
2524
  title: "Remove Widget"
2724
2525
  },
2725
- onClick: () => o(),
2726
- children: /* @__PURE__ */ s(gt, { className: $e })
2526
+ onClick: () => i(),
2527
+ children: /* @__PURE__ */ o(ct, { className: Me })
2727
2528
  }
2728
2529
  )
2729
2530
  ] })
2730
2531
  ] }) })
2731
2532
  ] }),
2732
- /* @__PURE__ */ s("div", { className: "widget-inner", children: e.children })
2533
+ /* @__PURE__ */ o("div", { className: "widget-inner", children: e.children })
2733
2534
  ] });
2734
- }, at = le(Cn), Sn = (e, n) => {
2735
- const t = (o) => o.replace(/[^0-9.]/g, ""), r = t(e).split(".").map(Number), i = t(n).split(".").map(Number);
2736
- return !(r[0] !== i[0] || r[1] < i[1]);
2535
+ }, it = le(fn), hn = (e, n) => {
2536
+ const t = (i) => i.replace(/[^0-9.]/g, ""), r = t(e).split(".").map(Number), a = t(n).split(".").map(Number);
2537
+ return !(r[0] !== a[0] || r[1] < a[1]);
2737
2538
  };
2738
- function Dn(e) {
2739
- return /* @__PURE__ */ s("div", { className: "dashboard-widget", children: /* @__PURE__ */ W("div", { className: "absolute inset-0 bg-black flex flex-col items-center justify-center text-center", children: [
2740
- /* @__PURE__ */ s("div", { className: "w-full absolute opacity-100 text-primary", children: e.title }),
2741
- /* @__PURE__ */ s("div", { className: "animate-ping rounded-full h-32 w-32 border-8 border-white" })
2539
+ function gn(e) {
2540
+ return /* @__PURE__ */ o("div", { className: "dashboard-widget", children: /* @__PURE__ */ $("div", { className: "absolute inset-0 bg-black flex flex-col items-center justify-center text-center", children: [
2541
+ /* @__PURE__ */ o("div", { className: "w-full absolute opacity-100 text-primary", children: e.title }),
2542
+ /* @__PURE__ */ o("div", { className: "animate-ping rounded-full h-32 w-32 border-8 border-white" })
2742
2543
  ] }) });
2743
2544
  }
2744
- function Tn({
2545
+ function mn({
2745
2546
  index: e,
2746
2547
  maxIndex: n,
2747
2548
  widgetKey: t,
2748
2549
  parentWidgetKey: r,
2749
- targetContainerKey: i,
2750
- childWidgetsConfig: o,
2751
- widgetCatalog: a,
2752
- isEditing: d,
2550
+ targetContainerKey: a,
2551
+ childWidgetsConfig: i,
2552
+ widgetCatalog: d,
2553
+ isEditing: f,
2753
2554
  // for additional props passed to all widget from the dashboard through the DynamicWidgetLoader:
2754
- extraProps: b,
2755
- onRemoveClick: m,
2756
- onMoveClick: h,
2757
- selectContainer: u
2555
+ extraProps: D,
2556
+ onRemoveClick: x,
2557
+ onMoveClick: b,
2558
+ selectContainer: c
2758
2559
  }) {
2759
- const p = `${t}`.split("_"), y = p.length > 1, D = y ? p[0] : t, g = a.get(D);
2560
+ const p = `${t}`.split("_"), m = p.length > 1, T = m ? p[0] : t, g = d.get(T);
2760
2561
  if (!g)
2761
- return /* @__PURE__ */ s("div", { className: "flex", children: /* @__PURE__ */ W("p", { children: [
2562
+ return /* @__PURE__ */ o("div", { className: "flex", children: /* @__PURE__ */ $("p", { children: [
2762
2563
  "Widget not found in catalog: ",
2763
- D
2564
+ T
2764
2565
  ] }) });
2765
- let v = null, w = !1;
2766
- const T = !!g.isContainer, C = y ? mt(t) : "", S = T ? (o || []).filter((c) => c.parentWidgetKey === t) : [], l = {
2566
+ let y = null, w = !1;
2567
+ const N = !!g.isContainer, C = m ? st(t) : "", S = N ? (i || []).filter((s) => s.parentWidgetKey === t) : [], l = {
2767
2568
  index: e,
2768
2569
  maxIndex: n,
2769
2570
  widgetKey: t,
2770
2571
  parentWidgetKey: r,
2771
- isEditing: d,
2772
- extraProps: b,
2773
- title: y ? C : g.title,
2774
- onRemoveClick: m,
2775
- onMoveClick: h
2572
+ isEditing: f,
2573
+ extraProps: D,
2574
+ title: m ? C : g.title,
2575
+ onRemoveClick: x,
2576
+ onMoveClick: b
2776
2577
  };
2777
- if (g.component ? (v = g.component, w = !1) : g.loader && (w = !0, v = st(() => {
2578
+ if (g.component ? (y = g.component, w = !1) : g.loader && (w = !0, y = ot(() => {
2778
2579
  if (!g) return null;
2779
- const c = typeof __HOST_REACT_VERSION__ < "u" ? __HOST_REACT_VERSION__ : "19.2.3", f = g.meta?.externalDependencies || [], M = f.find(($) => $.startsWith("react@"));
2780
- if (M) {
2781
- const $ = M.split("@")[1];
2782
- if (!Sn(c, $))
2783
- return ae.lazy(async () => ({
2784
- default: () => /* @__PURE__ */ s(at, { ...l, children: /* @__PURE__ */ W("div", { className: "p-4 border border-dashed border-danger", children: [
2785
- /* @__PURE__ */ W("p", { className: "font-bold", children: [
2580
+ const s = typeof __HOST_REACT_VERSION__ < "u" ? __HOST_REACT_VERSION__ : "19.2.3", h = g.meta?.externalDependencies || [], u = h.find((_) => _.startsWith("react@"));
2581
+ if (u) {
2582
+ const _ = u.split("@")[1];
2583
+ if (!hn(s, _))
2584
+ return oe.lazy(async () => ({
2585
+ default: () => /* @__PURE__ */ o(it, { ...l, children: /* @__PURE__ */ $("div", { className: "p-4 border border-dashed border-danger", children: [
2586
+ /* @__PURE__ */ $("p", { className: "font-bold", children: [
2786
2587
  'Failed to load "',
2787
2588
  t,
2788
2589
  '"'
2789
2590
  ] }),
2790
- /* @__PURE__ */ W("p", { className: "text-xs italic", children: [
2591
+ /* @__PURE__ */ $("p", { className: "text-xs italic", children: [
2791
2592
  "The remote plugin is unavailable or incompatible.",
2792
- /* @__PURE__ */ W("p", { className: "font-bold text-sm", children: [
2593
+ /* @__PURE__ */ $("p", { className: "font-bold text-sm", children: [
2793
2594
  "Version Mismatch: ",
2794
2595
  t
2795
2596
  ] }),
2796
- /* @__PURE__ */ W("p", { className: "text-xs", children: [
2597
+ /* @__PURE__ */ $("p", { className: "text-xs", children: [
2797
2598
  "Widget requires ",
2798
- /* @__PURE__ */ W("strong", { children: [
2599
+ /* @__PURE__ */ $("strong", { children: [
2799
2600
  "React ",
2800
- $
2601
+ _
2801
2602
  ] }),
2802
2603
  ". Host is running",
2803
2604
  " ",
2804
- /* @__PURE__ */ s("strong", { children: c }),
2605
+ /* @__PURE__ */ o("strong", { children: s }),
2805
2606
  "."
2806
2607
  ] })
2807
2608
  ] }),
2808
- /* @__PURE__ */ W("div", { className: "flex flex-col mt-3", children: [
2809
- /* @__PURE__ */ s("h5", { children: "Externals:" }),
2810
- /* @__PURE__ */ s("dl", { className: "ml-2 flex flex-col text-xs", children: f.map((I, E) => /* @__PURE__ */ W("dd", { children: [
2609
+ /* @__PURE__ */ $("div", { className: "flex flex-col mt-3", children: [
2610
+ /* @__PURE__ */ o("h5", { children: "Externals:" }),
2611
+ /* @__PURE__ */ o("dl", { className: "ml-2 flex flex-col text-xs", children: h.map((I, B) => /* @__PURE__ */ $("dd", { children: [
2811
2612
  "- ",
2812
2613
  I
2813
- ] }, E)) })
2614
+ ] }, B)) })
2814
2615
  ] })
2815
2616
  ] }) })
2816
2617
  }));
@@ -2818,93 +2619,93 @@ function Tn({
2818
2619
  if (g.component)
2819
2620
  return g.component;
2820
2621
  if (g.loader) {
2821
- const $ = async () => {
2622
+ const _ = async () => {
2822
2623
  try {
2823
2624
  return await g.loader();
2824
2625
  } catch (I) {
2825
2626
  return console.error(`CDN Load Failure for ${t}:`, I), {
2826
- default: () => /* @__PURE__ */ s(at, { ...l, children: /* @__PURE__ */ W("div", { className: "p-4 border border-dashed border-danger", children: [
2827
- /* @__PURE__ */ W("p", { className: "font-bold", children: [
2627
+ default: () => /* @__PURE__ */ o(it, { ...l, children: /* @__PURE__ */ $("div", { className: "p-4 border border-dashed border-danger", children: [
2628
+ /* @__PURE__ */ $("p", { className: "font-bold", children: [
2828
2629
  'Failed to load "',
2829
2630
  t,
2830
2631
  '"'
2831
2632
  ] }),
2832
- /* @__PURE__ */ s("p", { className: "text-xs italic", children: "The remote plugin is unavailable or incompatible." }),
2833
- /* @__PURE__ */ s("pre", { className: "text-xs overflow-hidden", children: JSON.stringify(g.meta || {}, null, 2) })
2633
+ /* @__PURE__ */ o("p", { className: "text-xs italic", children: "The remote plugin is unavailable or incompatible." }),
2634
+ /* @__PURE__ */ o("pre", { className: "text-xs overflow-hidden", children: JSON.stringify(g.meta || {}, null, 2) })
2834
2635
  ] }) })
2835
2636
  };
2836
2637
  }
2837
2638
  };
2838
- return ae.lazy($);
2639
+ return oe.lazy(_);
2839
2640
  }
2840
2641
  return null;
2841
- }, [g, t])), !v)
2842
- return /* @__PURE__ */ s("div", { className: "flex", children: /* @__PURE__ */ W("p", { children: [
2642
+ }, [g, t])), !y)
2643
+ return /* @__PURE__ */ o("div", { className: "flex", children: /* @__PURE__ */ $("p", { children: [
2843
2644
  "Widget definition incomplete: ",
2844
- D
2645
+ T
2845
2646
  ] }) });
2846
- const N = T ? {
2847
- highlight: i === t,
2848
- selectContainer: u,
2647
+ const M = N ? {
2648
+ highlight: a === t,
2649
+ selectContainer: c,
2849
2650
  // The children prop is the recursive call back to DynamicWidgetLoader
2850
- children: S.map((c, f) => /* @__PURE__ */ s(
2851
- Tn,
2651
+ children: S.map((s, h) => /* @__PURE__ */ o(
2652
+ mn,
2852
2653
  {
2853
- index: f,
2654
+ index: h,
2854
2655
  maxIndex: S.length - 1,
2855
- widgetKey: c.widgetKey,
2856
- parentWidgetKey: c.parentWidgetKey,
2857
- widgetCatalog: a,
2858
- isEditing: d,
2859
- extraProps: b,
2860
- onRemoveClick: m,
2861
- onMoveClick: h
2656
+ widgetKey: s.widgetKey,
2657
+ parentWidgetKey: s.parentWidgetKey,
2658
+ widgetCatalog: d,
2659
+ isEditing: f,
2660
+ extraProps: D,
2661
+ onRemoveClick: x,
2662
+ onMoveClick: b
2862
2663
  },
2863
- `${c.widgetKey}_${f}`
2664
+ `${s.widgetKey}_${h}`
2864
2665
  ))
2865
2666
  } : {};
2866
- return w ? /* @__PURE__ */ s(St, { fallback: /* @__PURE__ */ s(Dn, { title: `Loading ${g.title}` }), children: /* @__PURE__ */ s(v, { ...l, ...N }) }) : /* @__PURE__ */ s(v, { ...l, ...N });
2667
+ return w ? /* @__PURE__ */ o(bt, { fallback: /* @__PURE__ */ o(gn, { title: `Loading ${g.title}` }), children: /* @__PURE__ */ o(y, { ...l, ...M }) }) : /* @__PURE__ */ o(y, { ...l, ...M });
2867
2668
  }
2868
- const xe = "size-5";
2869
- function ke(e) {
2870
- const n = e.highlight || !1, t = e.direction || "column", r = e.children.length > 0, i = e.isEditing || !1;
2871
- let d = n ? "border-transparent" : i && !r ? "border-card-invert" : "border-transparent";
2872
- const b = ["large", "xlarge"].includes(e.size || "");
2873
- let m = "";
2874
- ["large", "xlarge"].indexOf(e.size || "") > -1 && (m = `${e.size}-widget`);
2875
- let h = "";
2876
- t === "row" && !r ? h = "min-h-48" : t === "column" && !r && (h = "min-h-96");
2877
- let u = G(
2669
+ const be = "size-5";
2670
+ function Oe(e) {
2671
+ const n = e.highlight || !1, t = e.direction || "column", r = e.children.length > 0, a = e.isEditing || !1;
2672
+ let f = n ? "border-transparent" : a && !r ? "border-card-invert" : "border-transparent";
2673
+ const D = ["large", "xlarge"].includes(e.size || "");
2674
+ let x = "";
2675
+ ["large", "xlarge"].indexOf(e.size || "") > -1 && (x = `${e.size}-widget`);
2676
+ let b = "";
2677
+ t === "row" && !r ? b = "min-h-48" : t === "column" && !r && (b = "min-h-96");
2678
+ let c = G(
2878
2679
  "dashboard-widget-container relative ",
2879
2680
  r ? "" : "has-no-children",
2880
- i ? "editing" : "",
2881
- h,
2882
- m,
2883
- b ? "widget-container-grid" : "widget-container-flex",
2681
+ a ? "editing" : "",
2682
+ b,
2683
+ x,
2684
+ D ? "widget-container-grid" : "widget-container-flex",
2884
2685
  `direction-${t}`,
2885
- `border ${d}`,
2886
- `${n ? "highlight-container" : ""} ${d}`
2887
- ), p = `widget-container-header direction-${t} flex items-center border-1 ${d}`;
2888
- const y = () => {
2686
+ `border ${f}`,
2687
+ `${n ? "highlight-container" : ""} ${f}`
2688
+ ), p = `widget-container-header direction-${t} flex items-center border-1 ${f}`;
2689
+ const m = () => {
2889
2690
  e.onRemoveClick && e.widgetKey && e.onRemoveClick(e.widgetKey);
2890
- }, D = (v) => {
2891
- e.onMoveClick && e.widgetKey && e.onMoveClick(v, e.widgetKey, e.parentWidgetKey);
2691
+ }, T = (y) => {
2692
+ e.onMoveClick && e.widgetKey && e.onMoveClick(y, e.widgetKey, e.parentWidgetKey);
2892
2693
  }, g = () => {
2893
2694
  e.selectContainer && e.widgetKey && e.selectContainer(e.widgetKey);
2894
2695
  };
2895
- return /* @__PURE__ */ W("div", { "data-testid": `container_${e.widgetKey}`, className: u, children: [
2896
- /* @__PURE__ */ W("div", { className: p, children: [
2897
- /* @__PURE__ */ s(
2696
+ return /* @__PURE__ */ $("div", { "data-testid": `container_${e.widgetKey}`, className: c, children: [
2697
+ /* @__PURE__ */ $("div", { className: p, children: [
2698
+ /* @__PURE__ */ o(
2898
2699
  "div",
2899
2700
  {
2900
2701
  className: "widget-title-wrapper w-full flex whitespace-nowrap",
2901
2702
  onClick: g,
2902
- children: /* @__PURE__ */ s("span", { className: "text-sm font-semibold capitalize", children: e.title })
2703
+ children: /* @__PURE__ */ o("span", { className: "text-sm font-semibold capitalize", children: e.title })
2903
2704
  }
2904
2705
  ),
2905
- /* @__PURE__ */ s("div", { "data-testid": "collapse-and-other-actions", children: /* @__PURE__ */ s("div", { className: "actions-inner", children: /* @__PURE__ */ W("div", { className: "actions-buttons-container", children: [
2906
- /* @__PURE__ */ s(
2907
- J,
2706
+ /* @__PURE__ */ o("div", { "data-testid": "collapse-and-other-actions", children: /* @__PURE__ */ o("div", { className: "actions-inner", children: /* @__PURE__ */ $("div", { className: "actions-buttons-container", children: [
2707
+ /* @__PURE__ */ o(
2708
+ Z,
2908
2709
  {
2909
2710
  "data-testid": `open-widgets-catalog-from-container_${e.title}`,
2910
2711
  isIconButton: !0,
@@ -2914,16 +2715,16 @@ function ke(e) {
2914
2715
  title: "Target this Container"
2915
2716
  },
2916
2717
  onClick: g,
2917
- children: /* @__PURE__ */ s(
2918
- tn,
2718
+ children: /* @__PURE__ */ o(
2719
+ Kt,
2919
2720
  {
2920
- className: `${xe} ${n ? "text-success" : "text-disabled"}`
2721
+ className: `${be} ${n ? "text-success" : "text-disabled"}`
2921
2722
  }
2922
2723
  )
2923
2724
  }
2924
2725
  ),
2925
- /* @__PURE__ */ s(
2926
- J,
2726
+ /* @__PURE__ */ o(
2727
+ Z,
2927
2728
  {
2928
2729
  "data-testid": `move-container-left_${e.title}`,
2929
2730
  isIconButton: !0,
@@ -2932,12 +2733,12 @@ function ke(e) {
2932
2733
  placement: "top",
2933
2734
  title: `${e.index < 1 ? "Already at min position" : "Move Container to the left/up"}`
2934
2735
  },
2935
- onClick: () => D(-1),
2936
- children: /* @__PURE__ */ s(ft, { className: xe })
2736
+ onClick: () => T(-1),
2737
+ children: /* @__PURE__ */ o(lt, { className: be })
2937
2738
  }
2938
2739
  ),
2939
- /* @__PURE__ */ s(
2940
- J,
2740
+ /* @__PURE__ */ o(
2741
+ Z,
2941
2742
  {
2942
2743
  "data-testid": `move-container-right_${e.title}`,
2943
2744
  isIconButton: !0,
@@ -2946,12 +2747,12 @@ function ke(e) {
2946
2747
  placement: "top",
2947
2748
  title: `${e.index >= e.maxIndex ? "Already at max position" : "Move Container to the right/down"}`
2948
2749
  },
2949
- onClick: () => D(1),
2950
- children: /* @__PURE__ */ s(ht, { className: xe })
2750
+ onClick: () => T(1),
2751
+ children: /* @__PURE__ */ o(dt, { className: be })
2951
2752
  }
2952
2753
  ),
2953
- /* @__PURE__ */ s(
2954
- J,
2754
+ /* @__PURE__ */ o(
2755
+ Z,
2955
2756
  {
2956
2757
  "data-testid": `remove-container_${e.title}`,
2957
2758
  isIconButton: !0,
@@ -2959,147 +2760,140 @@ function ke(e) {
2959
2760
  placement: "top",
2960
2761
  title: "Remove Container"
2961
2762
  },
2962
- onClick: () => y(),
2963
- children: /* @__PURE__ */ s(gt, { className: xe })
2763
+ onClick: () => m(),
2764
+ children: /* @__PURE__ */ o(ct, { className: be })
2964
2765
  }
2965
2766
  )
2966
2767
  ] }) }) })
2967
2768
  ] }),
2968
- /* @__PURE__ */ s("div", { "data-testid": `childrenwrapper_${e.widgetKey}`, className: "widget-container-inner", children: e.children })
2769
+ /* @__PURE__ */ o("div", { "data-testid": `childrenwrapper_${e.widgetKey}`, className: "widget-container-inner", children: e.children })
2969
2770
  ] });
2970
2771
  }
2971
- function ir(e) {
2772
+ function qn(e) {
2972
2773
  const { direction: n, ...t } = e;
2973
- return /* @__PURE__ */ s(ke, { direction: "column", ...t });
2774
+ return /* @__PURE__ */ o(Oe, { direction: "column", ...t });
2974
2775
  }
2975
- function ar(e) {
2776
+ function Yn(e) {
2976
2777
  const { size: n, ...t } = e;
2977
- return /* @__PURE__ */ s(ke, { size: "large", ...t });
2778
+ return /* @__PURE__ */ o(Oe, { size: "large", ...t });
2978
2779
  }
2979
- function sr(e) {
2780
+ function Fn(e) {
2980
2781
  const { direction: n, ...t } = e;
2981
- return /* @__PURE__ */ s(ke, { direction: "row", ...t });
2782
+ return /* @__PURE__ */ o(Oe, { direction: "row", ...t });
2982
2783
  }
2983
- function We({
2784
+ function Pe({
2984
2785
  // widgetKey,
2985
2786
  metaData: e,
2986
2787
  alreadyAdded: n,
2987
2788
  addWidget: t
2988
2789
  }) {
2989
- const [r, i] = ce(!1), o = e.icon || nn, a = e.name || "Unknown", d = e.description || "---", m = (e.noDuplicatedWidgets || !1) && n, h = G(`
2790
+ const [r, a] = se(!1), i = e.icon || zt, d = e.name || "Unknown", f = e.description || "---", x = (e.noDuplicatedWidgets || !1) && n, b = G(`
2990
2791
  flex flex-row gap-2 p-2 rounded-md border text-sm bg-card content-card backdrop-opacity-100
2991
- ${m ? "border-disabled fill-disabled text-disabled" : "cursor-pointer border-primary fill-danger hover:fill-primary content-primary hover:brightness-110"}
2792
+ ${x ? "border-disabled fill-disabled text-disabled" : "cursor-pointer border-primary fill-danger hover:fill-primary content-primary hover:brightness-110"}
2992
2793
  `);
2993
- return /* @__PURE__ */ W("div", { className: h, style: { width: "calc(100% - 1rem)" }, onClick: () => {
2994
- m || t();
2794
+ return /* @__PURE__ */ $("div", { className: b, style: { width: "calc(100% - 1rem)" }, onClick: () => {
2795
+ x || t();
2995
2796
  }, children: [
2996
- /* @__PURE__ */ s(o, { className: "" }),
2997
- /* @__PURE__ */ W("div", { className: "w-full", children: [
2998
- /* @__PURE__ */ W("div", { className: "flex flex-row items-center gap-2 justify-between", children: [
2999
- /* @__PURE__ */ s("span", { className: "font-bold", children: a }),
3000
- /* @__PURE__ */ s("div", { className: "text-xs", children: m ? "(Added)" : "" })
2797
+ /* @__PURE__ */ o(i, { className: "" }),
2798
+ /* @__PURE__ */ $("div", { className: "w-full", children: [
2799
+ /* @__PURE__ */ $("div", { className: "flex flex-row items-center gap-2 justify-between", children: [
2800
+ /* @__PURE__ */ o("span", { className: "font-bold", children: d }),
2801
+ /* @__PURE__ */ o("div", { className: "text-xs", children: x ? "(Added)" : "" })
3001
2802
  ] }),
3002
- /* @__PURE__ */ W("div", { className: "flex flex-col text-xs", children: [
3003
- /* @__PURE__ */ s("div", { children: d }),
3004
- /* @__PURE__ */ s("div", { className: "mt-3 cursor-pointer", onClick: (y) => {
3005
- y.stopPropagation(), y.preventDefault(), i(!r);
2803
+ /* @__PURE__ */ $("div", { className: "flex flex-col text-xs", children: [
2804
+ /* @__PURE__ */ o("div", { children: f }),
2805
+ /* @__PURE__ */ o("div", { className: "mt-3 cursor-pointer", onClick: (m) => {
2806
+ m.stopPropagation(), m.preventDefault(), a(!r);
3006
2807
  }, children: "Externals:" }),
3007
- r && /* @__PURE__ */ s("dl", { className: "ml-2 flex flex-col text-xs", children: e.externalDependencies.map((y, D) => /* @__PURE__ */ W("dd", { children: [
2808
+ r && /* @__PURE__ */ o("dl", { className: "ml-2 flex flex-col text-xs", children: e.externalDependencies.map((m, T) => /* @__PURE__ */ $("dd", { children: [
3008
2809
  "- ",
3009
- y
3010
- ] }, D)) })
2810
+ m
2811
+ ] }, T)) })
3011
2812
  ] })
3012
2813
  ] })
3013
2814
  ] });
3014
2815
  }
3015
- function En({
3016
- item: e,
3017
- onSettingItemChanged: n
3018
- }) {
3019
- const t = e.name || "Unknown", r = e.description || "---", i = G(`
2816
+ function pn({ item: e, onSettingItemChanged: n }) {
2817
+ const t = e.name || "Unknown", r = e.description || "---", a = G(`
3020
2818
  flex flex-row gap-2 p-2 rounded-md border text-sm bg-card content-card backdrop-opacity-100
3021
- `), o = (d) => {
3022
- const b = d.key;
3023
- if (["ArrowUp", "ArrowDown"].includes(b)) {
3024
- d.preventDefault();
3025
- const m = _t.incrementOrDecrementValue(
2819
+ `), i = (f) => {
2820
+ const D = f.key;
2821
+ if (["ArrowUp", "ArrowDown"].includes(D)) {
2822
+ f.preventDefault();
2823
+ const x = _t.incrementOrDecrementValue(
3026
2824
  e,
3027
- b === "ArrowUp" ? 1 : -1
2825
+ D === "ArrowUp" ? 1 : -1
3028
2826
  );
3029
- n(m);
2827
+ n(x);
3030
2828
  }
3031
- }, a = (d) => {
2829
+ }, d = (f) => {
3032
2830
  n({
3033
2831
  ...e,
3034
- value: d.target.value || ""
2832
+ value: f.target.value || ""
3035
2833
  });
3036
2834
  };
3037
- return /* @__PURE__ */ s("div", { className: i, style: { width: "calc(100% - 1rem)" }, children: /* @__PURE__ */ W("div", { className: "w-full", children: [
3038
- /* @__PURE__ */ s("div", { className: "flex flex-row items-center gap-2 justify-between", children: /* @__PURE__ */ s("span", { className: "font-bold", children: t }) }),
3039
- /* @__PURE__ */ s("div", { className: "flex flex-col gap-2 text-xs", children: /* @__PURE__ */ s("div", { children: r }) }),
3040
- /* @__PURE__ */ W("div", { children: [
2835
+ return /* @__PURE__ */ o("div", { className: a, style: { width: "calc(100% - 1rem)" }, children: /* @__PURE__ */ $("div", { className: "w-full", children: [
2836
+ /* @__PURE__ */ o("div", { className: "flex flex-row items-center gap-2 justify-between", children: /* @__PURE__ */ o("span", { className: "font-bold", children: t }) }),
2837
+ /* @__PURE__ */ o("div", { className: "flex flex-col gap-2 text-xs", children: /* @__PURE__ */ o("div", { children: r }) }),
2838
+ /* @__PURE__ */ $("div", { children: [
3041
2839
  "Value:",
3042
- /* @__PURE__ */ s(
3043
- pt,
2840
+ /* @__PURE__ */ o(
2841
+ ut,
3044
2842
  {
3045
2843
  label: "Filter...",
3046
2844
  size: "small",
3047
2845
  className: "w-full",
3048
2846
  value: e.value,
3049
- onChange: a,
3050
- onKeyDown: o
2847
+ onChange: d,
2848
+ onKeyDown: i
3051
2849
  }
3052
2850
  )
3053
2851
  ] })
3054
2852
  ] }) });
3055
2853
  }
3056
- const Ie = (e, n) => [
2854
+ const $e = (e, n) => [
3057
2855
  ...n.widgets.filter((r) => r.indexOf("Container") === -1),
3058
2856
  ...n.childWidgetsConfig.map((r) => r.widgetKey)
3059
2857
  ].includes(e);
3060
- function cr({
3061
- targetContainerKey: e,
3062
- widgetsCatalog: n,
3063
- currentDashboardConfig: t,
3064
- undoStatus: r,
3065
- addWidget: i,
3066
- addContainer: o,
3067
- onSettingItemsUpdated: a,
3068
- onResetToDefaultDashboardClick: d,
3069
- onUndoOrRedo: b,
3070
- onDoneClick: m
3071
- }) {
3072
- const [h, u] = ce("Editing"), [p, y] = ce(0), [D, g] = ce(""), w = Array.from(n.keys()).map((E) => ({
3073
- widgetKey: E,
3074
- metaData: $t(E, n)
3075
- })), T = (E) => {
3076
- g(E.target.value);
3077
- }, C = (E) => {
3078
- const z = D.trim().toLowerCase();
3079
- return z.length < 1 ? !0 : E.name.trim().toLowerCase().includes(z) || E.description.toLowerCase().includes(z);
3080
- }, S = (E) => {
3081
- const z = D.trim().toLowerCase();
3082
- return z.length < 1 ? !0 : E.name.trim().toLowerCase().includes(z) || E.description.toLowerCase().includes(z);
3083
- }, l = (E) => G(
2858
+ function Vn(e) {
2859
+ const {
2860
+ currentDashboardConfig: n,
2861
+ undoStatus: t,
2862
+ addContainer: r,
2863
+ onResetToDefaultDashboardClick: a,
2864
+ onUndoOrRedo: i,
2865
+ onDoneClick: d
2866
+ } = e, [f, D] = se("Editing"), [x, b] = se(0), [c, p] = se(""), T = Array.from(e.widgetsCatalog.keys()).map((u) => ({
2867
+ widgetKey: u,
2868
+ metaData: It(u, e.widgetsCatalog)
2869
+ })), g = !!e.targetContainerKey, y = (u) => {
2870
+ p(u.target.value);
2871
+ }, w = (u) => {
2872
+ const _ = c.trim().toLowerCase();
2873
+ return _.length < 1 ? !0 : u.name.trim().toLowerCase().includes(_) || u.description.toLowerCase().includes(_);
2874
+ }, N = (u) => {
2875
+ const _ = c.trim().toLowerCase();
2876
+ return _.length < 1 ? !0 : u.name.trim().toLowerCase().includes(_) || u.description.toLowerCase().includes(_);
2877
+ }, C = (u) => G(
3084
2878
  "px-4 py-2 font-medium cursor-pointer border-b-2 border-transparent hover:border-primary focus:outline-none",
3085
- E === p ? "text-primary border-primary" : ""
3086
- ), N = !!e;
3087
- Dt(() => {
3088
- if (e) {
3089
- y(0);
3090
- const E = mt(e);
3091
- u(`Editing ${E}`);
2879
+ u === x ? "text-primary border-primary" : ""
2880
+ ), S = (u) => {
2881
+ g ? e.addWidget(u, e.targetContainerKey) : e.addWidget(u);
2882
+ }, l = (u) => {
2883
+ const _ = (e.currentDashboardConfig.cssSettings || []).map((I) => I.key === u.key ? u : I);
2884
+ e.onSettingItemsUpdated(_);
2885
+ }, [M, s] = se(!1), h = (u) => {
2886
+ s(u);
2887
+ };
2888
+ return vt(() => {
2889
+ if (e.targetContainerKey) {
2890
+ b(0);
2891
+ const u = st(e.targetContainerKey);
2892
+ D(`Editing ${u}`);
3092
2893
  } else
3093
- u("Editing Dashboard");
3094
- }, [e]);
3095
- const c = (E) => {
3096
- N ? i(E, e) : i(E);
3097
- }, f = (E) => {
3098
- const z = (t.cssSettings || []).map((X) => X.key === E.key ? E : X);
3099
- a(z);
3100
- }, [M, $] = ce(!1);
3101
- return /* @__PURE__ */ s(
3102
- xn,
2894
+ D("Editing Dashboard");
2895
+ }, [e.targetContainerKey]), /* @__PURE__ */ o(
2896
+ cn,
3103
2897
  {
3104
2898
  testId: "dashboard-catalog-flyout",
3105
2899
  className: "bg-body content-body bg-opacity-70 border-2 border-primary",
@@ -3110,25 +2904,23 @@ function cr({
3110
2904
  minHeight: "360px",
3111
2905
  backdropFilter: "blur(8px)"
3112
2906
  },
3113
- onDraggingChange: (E) => {
3114
- $(E);
3115
- },
3116
- children: /* @__PURE__ */ W("div", { className: "flex flex-col gap-2 p-2", children: [
3117
- /* @__PURE__ */ W("div", { className: "flex flex-row gap-2 justify-between", children: [
3118
- /* @__PURE__ */ W("div", { className: "handle flex-1 flex gap-2 w-full hover:text-primary cursor-grab", children: [
3119
- M ? /* @__PURE__ */ s(en, { className: "size-5" }) : /* @__PURE__ */ s(Qt, { className: "size-5" }),
3120
- /* @__PURE__ */ s(
2907
+ onDraggingChange: h,
2908
+ children: /* @__PURE__ */ $("div", { className: "flex flex-col gap-2 p-2", children: [
2909
+ /* @__PURE__ */ $("div", { className: "flex flex-row gap-2 justify-between", children: [
2910
+ /* @__PURE__ */ $("div", { className: "handle flex-1 flex gap-2 w-full hover:text-primary cursor-grab", children: [
2911
+ M ? /* @__PURE__ */ o(Vt, { className: "size-5" }) : /* @__PURE__ */ o(Ft, { className: "size-5" }),
2912
+ /* @__PURE__ */ o(
3121
2913
  "h2",
3122
2914
  {
3123
2915
  className: "flex-1 text-base margin-0 capitalize",
3124
- title: N ? h : `Editing dashboard: ${t.dashboardName}`,
3125
- children: h
2916
+ title: g ? f : `Editing dashboard: ${n.dashboardName}`,
2917
+ children: f
3126
2918
  }
3127
2919
  )
3128
2920
  ] }),
3129
- /* @__PURE__ */ W("div", { className: "flex flex-row gap-2 items-center", children: [
3130
- /* @__PURE__ */ s(
3131
- J,
2921
+ /* @__PURE__ */ $("div", { className: "flex flex-row gap-2 items-center", children: [
2922
+ /* @__PURE__ */ o(
2923
+ Z,
3132
2924
  {
3133
2925
  "data-testid": "undo-dashboard-config-change",
3134
2926
  isIconButton: !0,
@@ -3136,13 +2928,13 @@ function cr({
3136
2928
  placement: "bottom",
3137
2929
  title: "Undo"
3138
2930
  },
3139
- disabled: r.isUndoDisabled,
3140
- onClick: () => b("Undo"),
3141
- children: /* @__PURE__ */ s(Zt, { className: "size-5" })
2931
+ disabled: t.isUndoDisabled,
2932
+ onClick: () => i("Undo"),
2933
+ children: /* @__PURE__ */ o(qt, { className: "size-5" })
3142
2934
  }
3143
2935
  ),
3144
- /* @__PURE__ */ s(
3145
- J,
2936
+ /* @__PURE__ */ o(
2937
+ Z,
3146
2938
  {
3147
2939
  "data-testid": "redo-dashboard-config-change",
3148
2940
  isIconButton: !0,
@@ -3150,13 +2942,13 @@ function cr({
3150
2942
  placement: "bottom",
3151
2943
  title: "Redo"
3152
2944
  },
3153
- disabled: r.isRedoDisabled,
3154
- onClick: () => b("Redo"),
3155
- children: /* @__PURE__ */ s(Jt, { className: "size-5" })
2945
+ disabled: t.isRedoDisabled,
2946
+ onClick: () => i("Redo"),
2947
+ children: /* @__PURE__ */ o(Yt, { className: "size-5" })
3156
2948
  }
3157
2949
  ),
3158
- /* @__PURE__ */ s(
3159
- J,
2950
+ /* @__PURE__ */ o(
2951
+ Z,
3160
2952
  {
3161
2953
  "data-testid": "reset-dashboard-to-default",
3162
2954
  isIconButton: !0,
@@ -3164,29 +2956,29 @@ function cr({
3164
2956
  placement: "bottom",
3165
2957
  title: "Reset this dashboard to the default configuration"
3166
2958
  },
3167
- onClick: d,
3168
- children: /* @__PURE__ */ s(Gt, { className: "size-5" })
2959
+ onClick: a,
2960
+ children: /* @__PURE__ */ o(Ut, { className: "size-5" })
3169
2961
  }
3170
2962
  )
3171
2963
  ] })
3172
2964
  ] }),
3173
- /* @__PURE__ */ W("div", { className: "flex border-b border-gray-200", children: [
3174
- /* @__PURE__ */ s("button", { onClick: () => y(0), className: l(0), children: "Widgets" }),
3175
- /* @__PURE__ */ s("button", { onClick: () => y(1), className: l(1), children: "Charts" }),
3176
- !N && /* @__PURE__ */ s("button", { onClick: () => y(2), className: l(2), children: "Containers" }),
3177
- !N && /* @__PURE__ */ s("button", { onClick: () => y(3), className: l(3), children: /* @__PURE__ */ s(Xt, {}) })
2965
+ /* @__PURE__ */ $("div", { className: "flex border-b border-gray-200", children: [
2966
+ /* @__PURE__ */ o("button", { onClick: () => b(0), className: C(0), children: "Widgets" }),
2967
+ /* @__PURE__ */ o("button", { onClick: () => b(1), className: C(1), children: "Charts" }),
2968
+ !g && /* @__PURE__ */ o("button", { onClick: () => b(2), className: C(2), children: "Containers" }),
2969
+ !g && /* @__PURE__ */ o("button", { onClick: () => b(3), className: C(3), children: /* @__PURE__ */ o(Lt, {}) })
3178
2970
  ] }),
3179
- /* @__PURE__ */ s("div", { className: "flex items-center justify-between gap-1 w-full", children: /* @__PURE__ */ s(
3180
- pt,
2971
+ /* @__PURE__ */ o("div", { className: "flex items-center justify-between gap-1 w-full", children: /* @__PURE__ */ o(
2972
+ ut,
3181
2973
  {
3182
2974
  label: "Filter...",
3183
2975
  size: "small",
3184
2976
  className: "w-full",
3185
- value: D,
3186
- onChange: T
2977
+ value: c,
2978
+ onChange: y
3187
2979
  }
3188
2980
  ) }),
3189
- /* @__PURE__ */ W(
2981
+ /* @__PURE__ */ $(
3190
2982
  "div",
3191
2983
  {
3192
2984
  className: "flex flex-col gap-2 overflow-x-hidden overflow-y-auto",
@@ -3194,60 +2986,60 @@ function cr({
3194
2986
  maxHeight: "360px"
3195
2987
  },
3196
2988
  children: [
3197
- p === 0 && w.filter(
3198
- (E) => E.metaData.categories.includes("Widget") && C(E.metaData)
3199
- ).map((E) => /* @__PURE__ */ s(
3200
- We,
2989
+ x === 0 && T.filter(
2990
+ (u) => u.metaData.categories.includes("Widget") && w(u.metaData)
2991
+ ).map((u) => /* @__PURE__ */ o(
2992
+ Pe,
3201
2993
  {
3202
- widgetKey: E.widgetKey,
3203
- metaData: E.metaData,
3204
- alreadyAdded: Ie(E.widgetKey, t),
3205
- addWidget: () => c(E.widgetKey)
2994
+ widgetKey: u.widgetKey,
2995
+ metaData: u.metaData,
2996
+ alreadyAdded: $e(u.widgetKey, n),
2997
+ addWidget: () => S(u.widgetKey)
3206
2998
  },
3207
- E.widgetKey
2999
+ u.widgetKey
3208
3000
  )),
3209
- p === 1 && w.filter(
3210
- (E) => E.metaData.categories.includes("Chart") && C(E.metaData)
3211
- ).map((E) => /* @__PURE__ */ s(
3212
- We,
3001
+ x === 1 && T.filter(
3002
+ (u) => u.metaData.categories.includes("Chart") && w(u.metaData)
3003
+ ).map((u) => /* @__PURE__ */ o(
3004
+ Pe,
3213
3005
  {
3214
- widgetKey: E.widgetKey,
3215
- metaData: E.metaData,
3216
- alreadyAdded: Ie(E.widgetKey, t),
3217
- addWidget: () => c(E.widgetKey)
3006
+ widgetKey: u.widgetKey,
3007
+ metaData: u.metaData,
3008
+ alreadyAdded: $e(u.widgetKey, n),
3009
+ addWidget: () => S(u.widgetKey)
3218
3010
  },
3219
- E.widgetKey
3011
+ u.widgetKey
3220
3012
  )),
3221
- !N && p === 2 && w.filter((E) => E.metaData.categories.includes("Container")).map((E) => /* @__PURE__ */ s(
3222
- We,
3013
+ !g && x === 2 && T.filter((u) => u.metaData.categories.includes("Container")).map((u) => /* @__PURE__ */ o(
3014
+ Pe,
3223
3015
  {
3224
- widgetKey: E.widgetKey,
3225
- metaData: E.metaData,
3226
- alreadyAdded: Ie(E.widgetKey, t),
3227
- addWidget: () => o(E.widgetKey)
3016
+ widgetKey: u.widgetKey,
3017
+ metaData: u.metaData,
3018
+ alreadyAdded: $e(u.widgetKey, n),
3019
+ addWidget: () => r(u.widgetKey)
3228
3020
  },
3229
- E.widgetKey
3021
+ u.widgetKey
3230
3022
  )),
3231
- !N && p === 3 && (t.cssSettings || []).filter(S).map((E) => /* @__PURE__ */ s(
3232
- En,
3023
+ !g && x === 3 && (n.cssSettings || []).filter(N).map((u) => /* @__PURE__ */ o(
3024
+ pn,
3233
3025
  {
3234
- item: E,
3235
- onSettingItemChanged: f
3026
+ item: u,
3027
+ onSettingItemChanged: l
3236
3028
  },
3237
- E.key
3029
+ u.key
3238
3030
  ))
3239
3031
  ]
3240
3032
  }
3241
3033
  ),
3242
- /* @__PURE__ */ s("div", { className: "mt-4 w-full flex flex-row justify-end pt-1", children: /* @__PURE__ */ s(
3243
- J,
3034
+ /* @__PURE__ */ o("div", { className: "mt-4 w-full flex flex-row justify-end pt-1", children: /* @__PURE__ */ o(
3035
+ Z,
3244
3036
  {
3245
3037
  className: "bg-opacity-100",
3246
3038
  tooltip: {
3247
3039
  placement: "bottom",
3248
3040
  title: "Click to exit edit mode"
3249
3041
  },
3250
- onClick: m,
3042
+ onClick: d,
3251
3043
  children: "Done"
3252
3044
  }
3253
3045
  ) })
@@ -3256,72 +3048,47 @@ function cr({
3256
3048
  );
3257
3049
  }
3258
3050
  export {
3259
- An as AddIcon,
3260
- J as Button,
3261
- nn as CircleQuestionMark,
3262
- tn as CrosshairIcon,
3263
- or as DashboardGrid,
3264
- Fe as DashboardMaxZoomScale,
3265
- Ae as DashboardMinZoomScale,
3266
- at as DashboardWidgetBase,
3267
- Mt as DashboardZoomStep,
3268
- Fn as DeleteIcon,
3269
- xn as DraggablePanel,
3270
- Tn as DynamicWidgetLoader,
3271
- Ln as EditIcon,
3272
- Vn as GridIcon,
3273
- en as HandGrabIcon,
3274
- Qt as HandIcon,
3275
- Gn as ListItem,
3276
- Zn as ListItemLeftChild,
3277
- Jn as ListItemMiddleChild,
3278
- Qn as ListItemRightChild,
3279
- Un as MonitorIcon,
3280
- qn as MonitorSmartphoneIcon,
3281
- ft as MoveLeftIcon,
3282
- ht as MoveRightIcon,
3283
- Jt as RedoIcon,
3284
- Xt as SettingsIcon,
3285
- on as Stack,
3286
- H as SvgBaseWrapper,
3287
- Yn as TabletSmartphoneIcon,
3288
- Hn as TargetIcon,
3289
- pt as TextField,
3290
- Gt as TimerResetIcon,
3291
- Zt as UndoIcon,
3292
- ir as WidgetContainerColumn,
3293
- ar as WidgetContainerLarge,
3294
- sr as WidgetContainerRow,
3295
- cr as WidgetsCatalogFlyout,
3296
- tr as WrapperColumnContent,
3297
- nr as WrapperColumnContentListItem,
3298
- gt as XCircleIcon,
3299
- zn as ZoomInIcon,
3300
- Bn as ZoomOutIcon,
3301
- Sn as _isVersionCompatible,
3302
- Ce as blankDashboardConfig,
3303
- dt as createDynamicEntry,
3304
- Wt as createStaticEntry,
3305
- Tt as cssSettingsCatalog,
3306
- Xn as cssVarsUtils,
3307
- _t as dashboardSettingsUtils,
3308
- Pt as ensureContainersSequence,
3309
- lt as ensureZoomScaleIsWithinRange,
3310
- ge as getDefaultWidgetMetaFromKey,
3311
- Wn as getDefaultWidgetMetaFromMap,
3312
- G as getDistinctCssClasses,
3313
- Ot as getMetaInfoFromFile,
3314
- Pn as getNewZoomScaleWithinRange,
3315
- $t as getWidgetMetaFromCatalog,
3316
- On as localWidgetDiscovery,
3317
- mt as parseContainerTitle,
3318
- It as parseKeyAndTitleFromFilePath,
3319
- In as remoteWidgetDiscovery,
3320
- $n as removeEmptyContainers,
3321
- re as resolveColorFromClass,
3322
- Kn as resolvedColors,
3323
- rr as showToast,
3324
- kn as useDashboardStorageService,
3325
- Rn as useDashboardStore,
3326
- jn as useDashboardUndoService
3051
+ Cn as AddIcon,
3052
+ Z as Button,
3053
+ zt as CircleQuestionMark,
3054
+ Kt as CrosshairIcon,
3055
+ Un as DashboardGrid,
3056
+ it as DashboardWidgetBase,
3057
+ Sn as DeleteIcon,
3058
+ cn as DraggablePanel,
3059
+ mn as DynamicWidgetLoader,
3060
+ Dn as EditIcon,
3061
+ Tn as GridIcon,
3062
+ Vt as HandGrabIcon,
3063
+ Ft as HandIcon,
3064
+ In as ListItem,
3065
+ Rn as ListItemLeftChild,
3066
+ On as ListItemMiddleChild,
3067
+ Wn as ListItemRightChild,
3068
+ Nn as MonitorIcon,
3069
+ En as MonitorSmartphoneIcon,
3070
+ lt as MoveLeftIcon,
3071
+ dt as MoveRightIcon,
3072
+ Yt as RedoIcon,
3073
+ Lt as SettingsIcon,
3074
+ Ht as Stack,
3075
+ K as SvgBaseWrapper,
3076
+ _n as TabletSmartphoneIcon,
3077
+ $n as TargetIcon,
3078
+ ut as TextField,
3079
+ Ut as TimerResetIcon,
3080
+ qt as UndoIcon,
3081
+ qn as WidgetContainerColumn,
3082
+ Yn as WidgetContainerLarge,
3083
+ Fn as WidgetContainerRow,
3084
+ Vn as WidgetsCatalogFlyout,
3085
+ jn as WrapperColumnContent,
3086
+ An as WrapperColumnContentListItem,
3087
+ ct as XCircleIcon,
3088
+ Mn as ZoomInIcon,
3089
+ Pn as ZoomOutIcon,
3090
+ hn as _isVersionCompatible,
3091
+ Ln as showToast,
3092
+ xn as useDashboardStore,
3093
+ wn as useDashboardUndoService
3327
3094
  };