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