@billgangcom/theme-lib 1.52.1 → 1.52.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/ui.es.js CHANGED
@@ -1,8 +1,8 @@
1
- import { j as t, I as b, c as V, a as rt, S as it, R as vt, B as tt, O as dt, b as ot, u as ut, d as mt, P as ht, D as pt, e as _t, v as gt, f as ft, C as xt, g as U, h as Ct, i as nt, k as St, l as wt, m as $t, n as lt, o as F, L as Bt, p as ct, q as bt, r as Y, t as Pt, M as jt, w as yt, x as Mt, y as Nt, z as Tt } from "./index-B2Rk8_zm.js";
2
- import { H as mi, E as hi, G as pi, A as _i, T as gi, F as fi } from "./index-B2Rk8_zm.js";
1
+ import { j as t, I as b, c as V, a as rt, S as it, R as vt, B as tt, O as dt, b as ot, u as ut, d as mt, P as ht, D as pt, e as _t, v as gt, f as ft, C as xt, g as U, h as Ct, i as nt, k as St, l as wt, m as $t, n as lt, o as F, L as Bt, p as ct, q as bt, r as Y, t as Pt, M as jt, w as yt, x as Mt, y as Nt, z as Tt } from "./index-hseNJ-Jo.js";
2
+ import { H as mi, E as hi, G as pi, A as _i, T as gi, F as fi } from "./index-hseNJ-Jo.js";
3
3
  import f from "react";
4
4
  import "@phosphor-icons/react";
5
- const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1ibay_15", Et = "_subtitle_1ibay_22", zt = "_alignmentContent_1ibay_29", Rt = "_alignments_1ibay_37", Dt = "_alignment_1ibay_8", Lt = "_circle_1ibay_60", Ht = "_paddings_1ibay_67", Ut = "_padding_1ibay_67", Ft = "_active_1ibay_91", Vt = "_input_1ibay_98", W = {
5
+ const qt = "_wrapper_1vmyb_2", At = "_alignmentBlock_1vmyb_8", Ot = "_title_1vmyb_15", Et = "_subtitle_1vmyb_22", zt = "_alignmentContent_1vmyb_29", Rt = "_alignments_1vmyb_37", Dt = "_alignment_1vmyb_8", Lt = "_circle_1vmyb_60", Ht = "_paddings_1vmyb_67", Ut = "_padding_1vmyb_67", Ft = "_active_1vmyb_91", Vt = "_input_1vmyb_98", W = {
6
6
  wrapper: qt,
7
7
  alignmentBlock: At,
8
8
  title: Ot,
@@ -25,10 +25,10 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
25
25
  "bottomLeft",
26
26
  "bottom",
27
27
  "bottomRight"
28
- ], Wt = ["left", "top", "right", "bottom"], Xn = (r) => {
29
- const { alignment: o, padding: e, setPadding: s, setAlignment: n } = r;
30
- function g(d) {
31
- switch (d) {
28
+ ], Wt = ["left", "top", "right", "bottom"], Xn = (d) => {
29
+ const { alignment: o, padding: e, setPadding: s, setAlignment: n } = d;
30
+ function g(l) {
31
+ switch (l) {
32
32
  case "left":
33
33
  case "topLeft":
34
34
  case "bottomLeft":
@@ -45,8 +45,8 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
45
45
  return "TextAlignCenter";
46
46
  }
47
47
  }
48
- function h(d) {
49
- switch (d) {
48
+ function h(l) {
49
+ switch (l) {
50
50
  case "left":
51
51
  return "AlignLeft";
52
52
  case "right":
@@ -57,28 +57,28 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
57
57
  return "AlignBottom";
58
58
  }
59
59
  }
60
- const [c, p] = f.useState(null), [I, O] = f.useState(null);
60
+ const [c, _] = f.useState(null), [k, M] = f.useState(null);
61
61
  return /* @__PURE__ */ t.jsxs("div", { className: W.layout, children: [
62
62
  /* @__PURE__ */ t.jsx("h3", { className: W.title, children: "Layout" }),
63
63
  /* @__PURE__ */ t.jsxs("div", { className: W.alignmentBlock, children: [
64
64
  /* @__PURE__ */ t.jsx("h5", { className: W.subtitle, children: "Alignment" }),
65
65
  /* @__PURE__ */ t.jsxs("div", { className: W.alignmentContent, children: [
66
- /* @__PURE__ */ t.jsx("div", { className: W.alignments, children: Yt.map((d) => /* @__PURE__ */ t.jsxs(
66
+ /* @__PURE__ */ t.jsx("div", { className: W.alignments, children: Yt.map((l) => /* @__PURE__ */ t.jsxs(
67
67
  "div",
68
68
  {
69
69
  onClick: () => {
70
- n(d);
70
+ n(l);
71
71
  },
72
72
  className: W.alignment,
73
73
  onMouseEnter: () => {
74
- p(d);
74
+ _(l);
75
75
  },
76
76
  onMouseLeave: () => {
77
- p(null);
77
+ _(null);
78
78
  },
79
79
  children: [
80
- d !== o && c !== d && /* @__PURE__ */ t.jsx("div", { className: W.circle }),
81
- d !== o && c === d && /* @__PURE__ */ t.jsx(
80
+ l !== o && c !== l && /* @__PURE__ */ t.jsx("div", { className: W.circle }),
81
+ l !== o && c === l && /* @__PURE__ */ t.jsx(
82
82
  b,
83
83
  {
84
84
  name: g(c),
@@ -87,7 +87,7 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
87
87
  height: 22
88
88
  }
89
89
  ),
90
- d === o && /* @__PURE__ */ t.jsx(
90
+ l === o && /* @__PURE__ */ t.jsx(
91
91
  b,
92
92
  {
93
93
  name: g(o),
@@ -98,25 +98,25 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
98
98
  )
99
99
  ]
100
100
  },
101
- d
101
+ l
102
102
  )) }),
103
- /* @__PURE__ */ t.jsx("div", { className: W.paddings, children: Wt.map((d) => /* @__PURE__ */ t.jsxs(
103
+ /* @__PURE__ */ t.jsx("div", { className: W.paddings, children: Wt.map((l) => /* @__PURE__ */ t.jsxs(
104
104
  "label",
105
105
  {
106
106
  className: V(W.padding, {
107
- [W.active]: I === d
107
+ [W.active]: k === l
108
108
  }),
109
109
  onFocus: () => {
110
- O(d);
110
+ M(l);
111
111
  },
112
112
  onBlur: () => {
113
- O(null);
113
+ M(null);
114
114
  },
115
115
  children: [
116
116
  /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
117
117
  b,
118
118
  {
119
- name: h(d),
119
+ name: h(l),
120
120
  width: 20,
121
121
  height: 20
122
122
  }
@@ -125,18 +125,19 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
125
125
  rt,
126
126
  {
127
127
  type: "number",
128
- value: String(e[d]),
128
+ value: String(e[l]),
129
129
  onChange: (i) => s({
130
130
  ...e,
131
- [d]: Number(i)
131
+ [l]: Math.min(Number(i), 999)
132
132
  }),
133
+ max: 999,
133
134
  paddingless: !0,
134
135
  borderless: !0
135
136
  }
136
137
  )
137
138
  ]
138
139
  },
139
- d
140
+ l
140
141
  )) })
141
142
  ] })
142
143
  ] })
@@ -165,7 +166,7 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
165
166
  modalOptions: pe,
166
167
  addButton: _e,
167
168
  deleteButton: ge
168
- }, Jn = (r) => {
169
+ }, Jn = (d) => {
169
170
  const {
170
171
  isActiveItems: o,
171
172
  setIsActiveItems: e,
@@ -174,18 +175,18 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
174
175
  other: g,
175
176
  title: h,
176
177
  subtitle: c,
177
- draggable: p = !1,
178
- withImage: I = !1,
179
- addable: O = !0,
180
- itemsOptions: d,
178
+ draggable: _ = !1,
179
+ withImage: k = !1,
180
+ addable: M = !0,
181
+ itemsOptions: l,
181
182
  hasRangeSelector: i = !1,
182
183
  rangeSelectorOptions: x,
183
184
  limit: v,
184
- autoScrollInterval: _,
185
+ autoScrollInterval: p,
185
186
  deletable: y
186
- } = r;
187
+ } = d;
187
188
  function w(a) {
188
- if (I)
189
+ if (k)
189
190
  return a ? /* @__PURE__ */ t.jsx(
190
191
  "img",
191
192
  {
@@ -205,10 +206,10 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
205
206
  );
206
207
  }
207
208
  const L = (a, $ = !1) => {
208
- const T = d.find((E) => E.id === a);
209
- if (!T) return;
209
+ const q = l.find((E) => E.id === a);
210
+ if (!q) return;
210
211
  const Q = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
211
- p && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
212
+ _ && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
212
213
  b,
213
214
  {
214
215
  name: "DotsSixVertical",
@@ -221,14 +222,14 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
221
222
  ot,
222
223
  {
223
224
  onChange: (E) => {
224
- const u = [...s], C = d.find((j) => j.name === E);
225
+ const u = [...s], C = l.find((j) => j.name === E);
225
226
  if (!C) return;
226
- const M = C.id, l = u.map((j) => j === a ? M : j);
227
- n([...l]);
227
+ const T = C.id, r = u.map((j) => j === a ? T : j);
228
+ n([...r]);
228
229
  },
229
- value: T.name,
230
- options: d.filter((E) => !s.find((u) => u === E.id)).map((E) => E.name),
231
- leftAddon: w(T.images)
230
+ value: q.name,
231
+ options: l.filter((E) => !s.find((u) => u === E.id)).map((E) => E.name),
232
+ leftAddon: w(q.images)
232
233
  }
233
234
  ),
234
235
  $ && /* @__PURE__ */ t.jsx("div", { className: G.buttons, children: /* @__PURE__ */ t.jsx("div", { className: G.deleteButton, children: /* @__PURE__ */ t.jsx(
@@ -267,7 +268,7 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
267
268
  /* @__PURE__ */ t.jsxs("div", { className: G.products, children: [
268
269
  c && /* @__PURE__ */ t.jsx("h5", { className: G.subtitle, children: c }),
269
270
  s.map((a) => L(a, y)),
270
- O && /* @__PURE__ */ t.jsx(
271
+ M && /* @__PURE__ */ t.jsx(
271
272
  "div",
272
273
  {
273
274
  style: {
@@ -281,21 +282,21 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
281
282
  {
282
283
  withoutHover: !0,
283
284
  className: V(G.button, {
284
- [G.disabled]: !!(v && v <= s.length || s.length === d.length)
285
+ [G.disabled]: !!(v && v <= s.length || s.length === l.length)
285
286
  }),
286
287
  size: "s",
287
- disabled: !!(v && v <= s.length || s.length === d.length),
288
+ disabled: !!(v && v <= s.length || s.length === l.length),
288
289
  onClick: () => {
289
290
  const a = [...s];
290
291
  let $ = null;
291
- if (d) {
292
- for (let T = 0; T < d.length; T++)
293
- if (!s.find((Q) => Q === d[T].id)) {
294
- $ = d[T];
292
+ if (l) {
293
+ for (let q = 0; q < l.length; q++)
294
+ if (!s.find((Q) => Q === l[q].id)) {
295
+ $ = l[q];
295
296
  break;
296
297
  }
297
298
  }
298
- a.push(($ == null ? void 0 : $.id) || d[0].id), n(a);
299
+ a.push(($ == null ? void 0 : $.id) || l[0].id), n(a);
299
300
  },
300
301
  style: {
301
302
  width: "fit-content"
@@ -317,13 +318,13 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
317
318
  )
318
319
  ] }),
319
320
  g !== void 0 && /* @__PURE__ */ t.jsx(dt, { items: g }),
320
- _ !== void 0 && /* @__PURE__ */ t.jsx(
321
+ p !== void 0 && /* @__PURE__ */ t.jsx(
321
322
  rt,
322
323
  {
323
324
  label: "Auto scroll interval",
324
325
  type: "number",
325
- value: String(_.scrollInterval),
326
- onChange: (a) => _.setScrollInterval(Number(a)),
326
+ value: String(p.scrollInterval),
327
+ onChange: (a) => p.setScrollInterval(Number(a)),
327
328
  min: 0.1,
328
329
  max: 100,
329
330
  style: {
@@ -359,7 +360,7 @@ const qt = "_wrapper_1ibay_2", At = "_alignmentBlock_1ibay_8", Ot = "_title_1iba
359
360
  deleteButton: Re,
360
361
  closeIcon: De
361
362
  };
362
- function Le({ product: r, children: o }) {
363
+ function Le({ product: d, children: o }) {
363
364
  const {
364
365
  attributes: e,
365
366
  listeners: s,
@@ -368,8 +369,8 @@ function Le({ product: r, children: o }) {
368
369
  transition: h,
369
370
  isDragging: c
370
371
  } = ft({
371
- id: r.id
372
- }), p = {
372
+ id: d.id
373
+ }), _ = {
373
374
  transform: xt.Transform.toString(g),
374
375
  transition: h
375
376
  };
@@ -377,7 +378,7 @@ function Le({ product: r, children: o }) {
377
378
  "div",
378
379
  {
379
380
  ref: n,
380
- style: p,
381
+ style: _,
381
382
  className: `${D.product} ${c ? D.dragging : ""}`,
382
383
  ...e,
383
384
  ...s,
@@ -385,7 +386,7 @@ function Le({ product: r, children: o }) {
385
386
  }
386
387
  );
387
388
  }
388
- const Kn = (r) => {
389
+ const Kn = (d) => {
389
390
  const {
390
391
  isActiveItems: o,
391
392
  setIsActiveItems: e,
@@ -394,14 +395,14 @@ const Kn = (r) => {
394
395
  title: g,
395
396
  subtitle: h,
396
397
  editable: c = !0,
397
- draggable: p = !1,
398
- deletable: I = !0,
399
- addable: O = !0,
400
- itemsType: d,
398
+ draggable: _ = !1,
399
+ deletable: k = !0,
400
+ addable: M = !0,
401
+ itemsType: l,
401
402
  itemsOptions: i,
402
403
  addableOptions: x = {},
403
404
  limit: v
404
- } = r, [_, y] = f.useState(null), [w, L] = f.useState(null), a = f.useRef(null), $ = ut(
405
+ } = d, [p, y] = f.useState(null), [w, L] = f.useState(null), a = f.useRef(null), $ = ut(
405
406
  mt(ht, {
406
407
  activationConstraint: {
407
408
  distance: 5
@@ -409,32 +410,32 @@ const Kn = (r) => {
409
410
  })
410
411
  );
411
412
  f.useEffect(() => {
412
- if (_) {
413
- const u = [...s].map((C) => C.id === _.id ? _ : C);
413
+ if (p) {
414
+ const u = [...s].map((C) => C.id === p.id ? p : C);
414
415
  n(u);
415
416
  }
416
- }, [_]), f.useEffect(() => {
417
+ }, [p]), f.useEffect(() => {
417
418
  a.current && w && (a.current.getBoundingClientRect().height, w.top);
418
419
  }, [a.current, w]);
419
- const T = (u, C) => {
420
+ const q = (u, C) => {
420
421
  u.stopPropagation();
421
- const M = u.target.getBoundingClientRect();
422
+ const T = u.target.getBoundingClientRect();
422
423
  L({
423
- top: M.top + window.scrollY,
424
- left: M.left - 30
424
+ top: T.top + window.scrollY,
425
+ left: T.left - 30
425
426
  }), y(C);
426
427
  }, Q = (u) => {
427
- const { active: C, over: M } = u;
428
- if (M && C.id !== M.id) {
429
- const l = s.findIndex((S) => S.id === C.id), j = s.findIndex((S) => S.id === M.id);
430
- if (l !== -1 && j !== -1) {
431
- const S = [...s], [R] = S.splice(l, 1);
428
+ const { active: C, over: T } = u;
429
+ if (T && C.id !== T.id) {
430
+ const r = s.findIndex((S) => S.id === C.id), j = s.findIndex((S) => S.id === T.id);
431
+ if (r !== -1 && j !== -1) {
432
+ const S = [...s], [R] = S.splice(r, 1);
432
433
  S.splice(j, 0, R), n(S);
433
434
  }
434
435
  }
435
436
  }, E = (u, C) => {
436
- const M = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
437
- p && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
437
+ const T = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
438
+ _ && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
438
439
  b,
439
440
  {
440
441
  name: "DotsSixVertical",
@@ -443,27 +444,27 @@ const Kn = (r) => {
443
444
  height: 20
444
445
  }
445
446
  ) }),
446
- d === "select" && i && /* @__PURE__ */ t.jsx(
447
+ l === "select" && i && /* @__PURE__ */ t.jsx(
447
448
  ot,
448
449
  {
449
- onChange: (l) => {
450
- const j = [...s], S = i.find((P) => P.name === l);
450
+ onChange: (r) => {
451
+ const j = [...s], S = i.find((P) => P.name === r);
451
452
  if (!S) return;
452
453
  const R = j.map((P) => P.id === u.id ? {
453
454
  ...S,
454
455
  name: {
455
- "en-US": l
456
+ "en-US": r
456
457
  }
457
458
  } : P);
458
459
  y({
459
460
  ...u,
460
461
  name: {
461
- "en-US": l
462
+ "en-US": r
462
463
  }
463
464
  }), n([...R]);
464
465
  },
465
466
  value: u.name,
466
- options: i.filter((l) => !s.find((j) => j.name === l.name)).map((l) => l.name)
467
+ options: i.filter((r) => !s.find((j) => j.name === r.name)).map((r) => r.name)
467
468
  }
468
469
  ),
469
470
  /* @__PURE__ */ t.jsxs("div", { className: D.buttons, children: [
@@ -474,10 +475,10 @@ const Kn = (r) => {
474
475
  hoverable: !0,
475
476
  width: 20,
476
477
  height: 20,
477
- onClick: (l) => T(l, u)
478
+ onClick: (r) => q(r, u)
478
479
  }
479
480
  ) }),
480
- I && /* @__PURE__ */ t.jsx("div", { className: D.deleteButton, children: /* @__PURE__ */ t.jsx(
481
+ k && /* @__PURE__ */ t.jsx("div", { className: D.deleteButton, children: /* @__PURE__ */ t.jsx(
481
482
  b,
482
483
  {
483
484
  name: "Trash",
@@ -485,24 +486,24 @@ const Kn = (r) => {
485
486
  width: 20,
486
487
  height: 20,
487
488
  fill: "#C12A2A",
488
- onClick: () => n(s.filter((l) => l.id !== u.id))
489
+ onClick: () => n(s.filter((r) => r.id !== u.id))
489
490
  }
490
491
  ) })
491
492
  ] })
492
493
  ] });
493
- return p ? /* @__PURE__ */ t.jsx(
494
+ return _ ? /* @__PURE__ */ t.jsx(
494
495
  Le,
495
496
  {
496
497
  product: u,
497
498
  index: C,
498
- children: M
499
+ children: T
499
500
  },
500
501
  u.id
501
502
  ) : /* @__PURE__ */ t.jsx(
502
503
  "div",
503
504
  {
504
505
  className: D.product,
505
- children: M
506
+ children: T
506
507
  },
507
508
  u.id
508
509
  );
@@ -520,7 +521,7 @@ const Kn = (r) => {
520
521
  ] }),
521
522
  /* @__PURE__ */ t.jsxs("div", { className: D.products, children: [
522
523
  h && /* @__PURE__ */ t.jsx("h5", { className: D.subtitle, children: h }),
523
- p ? /* @__PURE__ */ t.jsx(
524
+ _ ? /* @__PURE__ */ t.jsx(
524
525
  pt,
525
526
  {
526
527
  sensors: $,
@@ -535,7 +536,7 @@ const Kn = (r) => {
535
536
  )
536
537
  }
537
538
  ) : s.map((u, C) => E(u, C)),
538
- O && /* @__PURE__ */ t.jsx(
539
+ M && /* @__PURE__ */ t.jsx(
539
540
  "div",
540
541
  {
541
542
  style: {
@@ -556,13 +557,13 @@ const Kn = (r) => {
556
557
  const u = [...s];
557
558
  let C = null;
558
559
  if (i) {
559
- for (let M = 0; M < i.length; M++)
560
- if (!s.find((l) => l.id === i[M].id)) {
561
- C = i[M];
560
+ for (let T = 0; T < i.length; T++)
561
+ if (!s.find((r) => r.id === i[T].id)) {
562
+ C = i[T];
562
563
  break;
563
564
  }
564
565
  }
565
- d === "select" && i && u.push({
566
+ l === "select" && i && u.push({
566
567
  name: C ? C.name : i[0].name,
567
568
  id: (C == null ? void 0 : C.id) || i[0].id,
568
569
  ...x
@@ -589,10 +590,10 @@ const Kn = (r) => {
589
590
  ] })
590
591
  ] });
591
592
  };
592
- function He(r) {
593
- const { product: o, children: e } = r, { attributes: s, listeners: n, setNodeRef: g, transform: h, transition: c, isDragging: p } = ft({
593
+ function He(d) {
594
+ const { product: o, children: e } = d, { attributes: s, listeners: n, setNodeRef: g, transform: h, transition: c, isDragging: _ } = ft({
594
595
  id: o.id
595
- }), I = {
596
+ }), k = {
596
597
  transform: xt.Transform.toString(h),
597
598
  transition: c
598
599
  };
@@ -600,15 +601,15 @@ function He(r) {
600
601
  "div",
601
602
  {
602
603
  ref: g,
603
- style: I,
604
- className: `${U.product} ${p ? U.dragging : ""}`,
604
+ style: k,
605
+ className: `${U.product} ${_ ? U.dragging : ""}`,
605
606
  ...s,
606
607
  ...n,
607
608
  children: e
608
609
  }
609
610
  );
610
611
  }
611
- const Zn = (r) => {
612
+ const Zn = (d) => {
612
613
  const {
613
614
  isActiveItems: o,
614
615
  setIsActiveItems: e,
@@ -617,22 +618,22 @@ const Zn = (r) => {
617
618
  other: g,
618
619
  title: h,
619
620
  subtitle: c,
620
- editable: p = !0,
621
- draggable: I = !1,
622
- withImage: O = !1,
623
- deletable: d = !0,
621
+ editable: _ = !0,
622
+ draggable: k = !1,
623
+ withImage: M = !1,
624
+ deletable: l = !0,
624
625
  addable: i = !0,
625
626
  itemsType: x,
626
627
  itemsPlaceholder: v = "",
627
- itemsOptions: _,
628
+ itemsOptions: p,
628
629
  hasRangeSelector: y = !1,
629
630
  rangeSelectorOptions: w,
630
631
  modalOptions: L,
631
632
  addableOptions: a = {}
632
- } = r, [$, T] = f.useState(null), [Q, E] = f.useState({
633
+ } = d, [$, q] = f.useState(null), [Q, E] = f.useState({
633
634
  top: 0,
634
635
  left: 0
635
- }), [u, C] = f.useState(null), M = f.useRef(null), [l, j] = f.useState(!1), S = ut(
636
+ }), [u, C] = f.useState(null), T = f.useRef(null), [r, j] = f.useState(!1), S = ut(
636
637
  mt(ht, {
637
638
  activationConstraint: {
638
639
  distance: 5
@@ -641,36 +642,36 @@ const Zn = (r) => {
641
642
  );
642
643
  f.useEffect(() => {
643
644
  const m = () => {
644
- T(null), j(!1);
645
+ q(null), j(!1);
645
646
  };
646
- return document.body.addEventListener("click", m), T(null), j(!1), () => {
647
- T(null), j(!1), document.body.removeEventListener("click", m);
647
+ return document.body.addEventListener("click", m), q(null), j(!1), () => {
648
+ q(null), j(!1), document.body.removeEventListener("click", m);
648
649
  };
649
650
  }, []), f.useEffect(() => {
650
651
  if ($) {
651
- const m = [...s].map((q) => q.id === $.id ? $ : q);
652
+ const m = [...s].map((A) => A.id === $.id ? $ : A);
652
653
  n(m);
653
654
  }
654
655
  }, [$]), f.useEffect(() => {
655
- if (M.current && u) {
656
- const m = M.current.getBoundingClientRect().height, q = window.innerHeight;
656
+ if (T.current && u) {
657
+ const m = T.current.getBoundingClientRect().height, A = window.innerHeight;
657
658
  let B = u.top;
658
- B + m > q + window.scrollY - 200 && (B = q + window.scrollY - m - 200), B < 0 && (B = 10), E({
659
+ B + m > A + window.scrollY - 200 && (B = A + window.scrollY - m - 200), B < 0 && (B = 10), E({
659
660
  top: B,
660
661
  left: u.left
661
662
  });
662
663
  }
663
- }, [M.current, u]);
664
- const R = (m, q) => {
664
+ }, [T.current, u]);
665
+ const R = (m, A) => {
665
666
  m.stopPropagation();
666
667
  const B = m.target.getBoundingClientRect();
667
668
  C({
668
669
  top: B.top + window.scrollY,
669
670
  left: B.left - 30
670
- }), T(q), j(!0);
671
+ }), q(A), j(!0);
671
672
  };
672
673
  function P(m) {
673
- if (O)
674
+ if (M)
674
675
  return m ? /* @__PURE__ */ t.jsx(
675
676
  "img",
676
677
  {
@@ -690,18 +691,18 @@ const Zn = (r) => {
690
691
  );
691
692
  }
692
693
  const z = (m) => {
693
- const { active: q, over: B } = m;
694
- if (B && q.id !== B.id) {
695
- const A = s.findIndex((H) => H.id === q.id), et = s.findIndex((H) => H.id === B.id);
696
- if (A !== -1 && et !== -1) {
697
- const H = [...s], [X] = H.splice(A, 1);
694
+ const { active: A, over: B } = m;
695
+ if (B && A.id !== B.id) {
696
+ const O = s.findIndex((H) => H.id === A.id), et = s.findIndex((H) => H.id === B.id);
697
+ if (O !== -1 && et !== -1) {
698
+ const H = [...s], [X] = H.splice(O, 1);
698
699
  H.splice(et, 0, X), n(H);
699
700
  }
700
701
  }
701
702
  }, J = (m) => {
702
703
  var B;
703
- const q = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
704
- I && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
704
+ const A = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
705
+ k && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
705
706
  b,
706
707
  {
707
708
  name: "DotsSixVertical",
@@ -710,26 +711,26 @@ const Zn = (r) => {
710
711
  height: 20
711
712
  }
712
713
  ) }),
713
- x === "select" && _ && /* @__PURE__ */ t.jsx(
714
+ x === "select" && p && /* @__PURE__ */ t.jsx(
714
715
  ot,
715
716
  {
716
- onChange: (A) => {
717
+ onChange: (O) => {
717
718
  const H = [...s].map((X) => X.id === m.id ? {
718
719
  ...m,
719
720
  name: {
720
- "en-US": A
721
+ "en-US": O
721
722
  }
722
723
  } : X);
723
- T({
724
+ q({
724
725
  ...m,
725
726
  name: {
726
- "en-US": A
727
+ "en-US": O
727
728
  }
728
729
  }), n([...H]);
729
730
  },
730
731
  value: m.name["en-US"],
731
- options: _.filter(
732
- (A) => !s.find((et) => et.name["en-US"] === A)
732
+ options: p.filter(
733
+ (O) => !s.find((et) => et.name["en-US"] === O)
733
734
  ),
734
735
  leftAddon: P(m.images)
735
736
  }
@@ -737,11 +738,11 @@ const Zn = (r) => {
737
738
  x === "input" && /* @__PURE__ */ t.jsx(
738
739
  rt,
739
740
  {
740
- onChange: (A) => {
741
+ onChange: (O) => {
741
742
  const H = [...s].map((X) => X.id === m.id ? {
742
743
  ...m,
743
744
  name: {
744
- "en-US": A
745
+ "en-US": O
745
746
  }
746
747
  } : X);
747
748
  n([...H]);
@@ -753,28 +754,28 @@ const Zn = (r) => {
753
754
  x === "image" && /* @__PURE__ */ t.jsx(
754
755
  St,
755
756
  {
756
- onChange: (A) => {
757
+ onChange: (O) => {
757
758
  const H = [...s].map((X) => X.id === m.id ? {
758
759
  ...m,
759
- images: A
760
+ images: O
760
761
  } : X);
761
762
  n([...H]);
762
763
  },
763
- activeImage: (B = s.find((A) => A.id === m.id)) == null ? void 0 : B.images[0]
764
+ activeImage: (B = s.find((O) => O.id === m.id)) == null ? void 0 : B.images[0]
764
765
  }
765
766
  ),
766
767
  /* @__PURE__ */ t.jsxs("div", { className: U.buttons, children: [
767
- p && /* @__PURE__ */ t.jsx("div", { className: U.deleteButton, children: /* @__PURE__ */ t.jsx(
768
+ _ && /* @__PURE__ */ t.jsx("div", { className: U.deleteButton, children: /* @__PURE__ */ t.jsx(
768
769
  b,
769
770
  {
770
771
  name: "Sliders",
771
772
  hoverable: !0,
772
773
  width: 20,
773
774
  height: 20,
774
- onClick: (A) => R(A, m)
775
+ onClick: (O) => R(O, m)
775
776
  }
776
777
  ) }),
777
- d && /* @__PURE__ */ t.jsx("div", { className: U.deleteButton, children: /* @__PURE__ */ t.jsx(
778
+ l && /* @__PURE__ */ t.jsx("div", { className: U.deleteButton, children: /* @__PURE__ */ t.jsx(
778
779
  b,
779
780
  {
780
781
  name: "Trash",
@@ -782,23 +783,23 @@ const Zn = (r) => {
782
783
  width: 20,
783
784
  height: 20,
784
785
  fill: "#C12A2A",
785
- onClick: () => n(s.filter((A) => A.id !== m.id))
786
+ onClick: () => n(s.filter((O) => O.id !== m.id))
786
787
  }
787
788
  ) })
788
789
  ] })
789
790
  ] });
790
- return I ? /* @__PURE__ */ t.jsx(
791
+ return k ? /* @__PURE__ */ t.jsx(
791
792
  He,
792
793
  {
793
794
  product: m,
794
- children: q
795
+ children: A
795
796
  },
796
797
  m.id
797
798
  ) : /* @__PURE__ */ t.jsx(
798
799
  "div",
799
800
  {
800
801
  className: U.product,
801
- children: q
802
+ children: A
802
803
  },
803
804
  m.id
804
805
  );
@@ -814,12 +815,12 @@ const Zn = (r) => {
814
815
  }
815
816
  )
816
817
  ] }),
817
- $ && p && L && l && /* @__PURE__ */ t.jsx(
818
+ $ && _ && L && r && /* @__PURE__ */ t.jsx(
818
819
  Ct,
819
820
  {
820
- ref: M,
821
+ ref: T,
821
822
  activeItem: $,
822
- setActiveItem: T,
823
+ setActiveItem: q,
823
824
  popupPosition: Q,
824
825
  modalOptions: L,
825
826
  setIsOpenModal: j
@@ -828,7 +829,7 @@ const Zn = (r) => {
828
829
  y && w && /* @__PURE__ */ t.jsx(vt, { ...w }),
829
830
  /* @__PURE__ */ t.jsxs("div", { className: U.products, children: [
830
831
  c && /* @__PURE__ */ t.jsx("h5", { className: U.subtitle, children: c }),
831
- I ? /* @__PURE__ */ t.jsx(
832
+ k ? /* @__PURE__ */ t.jsx(
832
833
  pt,
833
834
  {
834
835
  sensors: S,
@@ -859,17 +860,17 @@ const Zn = (r) => {
859
860
  size: "s",
860
861
  onClick: () => {
861
862
  const m = [...s];
862
- let q = null;
863
- if (_) {
864
- for (let B = 0; B < _.length; B++)
865
- if (!s.find((A) => A.name["en-US"] === _[B])) {
866
- q = _[B];
863
+ let A = null;
864
+ if (p) {
865
+ for (let B = 0; B < p.length; B++)
866
+ if (!s.find((O) => O.name["en-US"] === p[B])) {
867
+ A = p[B];
867
868
  break;
868
869
  }
869
870
  }
870
- x === "select" && _ ? m.push({
871
+ x === "select" && p ? m.push({
871
872
  name: {
872
- "en-US": q || _[0]
873
+ "en-US": A || p[0]
873
874
  },
874
875
  id: nt(),
875
876
  ...a,
@@ -935,37 +936,37 @@ const Zn = (r) => {
935
936
  options: ls,
936
937
  addButton: rs,
937
938
  deleteButton: ds
938
- }, us = (r) => {
939
- const { buttons: o, setButtons: e, deletable: s = !0, addable: n = !0, editableLink: g = !0 } = r, { pages: h } = wt(), [c, p] = f.useState(null), [I, O] = f.useState({
939
+ }, us = (d) => {
940
+ const { buttons: o, setButtons: e, deletable: s = !0, addable: n = !0, editableLink: g = !0 } = d, { pages: h } = wt(), [c, _] = f.useState(null), [k, M] = f.useState({
940
941
  top: 0,
941
942
  left: 0
942
- }), [d, i] = f.useState(null), x = f.useRef(null);
943
+ }), [l, i] = f.useState(null), x = f.useRef(null);
943
944
  f.useEffect(() => {
944
945
  if (c) {
945
- const _ = [...o].map((y) => y.id === c.id ? c : y);
946
- e(_);
946
+ const p = [...o].map((y) => y.id === c.id ? c : y);
947
+ e(p);
947
948
  }
948
949
  }, [c]), f.useEffect(() => {
949
- if (x.current && d) {
950
- const _ = x.current.getBoundingClientRect().height, y = window.innerHeight;
951
- let w = d.top;
952
- w + _ > y + window.scrollY - 200 && (w = y + window.scrollY - _ - 200), w < 0 && (w = 10), O({
950
+ if (x.current && l) {
951
+ const p = x.current.getBoundingClientRect().height, y = window.innerHeight;
952
+ let w = l.top;
953
+ w + p > y + window.scrollY - 200 && (w = y + window.scrollY - p - 200), w < 0 && (w = 10), M({
953
954
  top: w,
954
- left: d.left
955
+ left: l.left
955
956
  });
956
957
  }
957
- }, [x.current, d]);
958
- const v = (_, y) => {
959
- _.stopPropagation();
960
- const w = _.target.getBoundingClientRect();
958
+ }, [x.current, l]);
959
+ const v = (p, y) => {
960
+ p.stopPropagation();
961
+ const w = p.target.getBoundingClientRect();
961
962
  i({
962
963
  top: w.top + window.scrollY - 70,
963
964
  left: w.left - (n ? 30 : 65)
964
- }), p(y);
965
+ }), _(y);
965
966
  };
966
967
  return /* @__PURE__ */ t.jsxs("div", { className: K.products, children: [
967
968
  /* @__PURE__ */ t.jsx("h5", { className: K.subtitle, children: "Button Type" }),
968
- o.map((_) => /* @__PURE__ */ t.jsxs(
969
+ o.map((p) => /* @__PURE__ */ t.jsxs(
969
970
  "div",
970
971
  {
971
972
  className: K.product,
@@ -974,13 +975,13 @@ const Zn = (r) => {
974
975
  ot,
975
976
  {
976
977
  onChange: (y) => {
977
- const L = [...o].map((a) => a.id === _.id ? {
978
- ..._,
978
+ const L = [...o].map((a) => a.id === p.id ? {
979
+ ...p,
979
980
  type: y
980
981
  } : a);
981
982
  e(L);
982
983
  },
983
- value: _.type,
984
+ value: p.type,
984
985
  options: ["Primary", "Secondary", "Tertiary"]
985
986
  }
986
987
  ),
@@ -993,7 +994,7 @@ const Zn = (r) => {
993
994
  width: 20,
994
995
  height: 20,
995
996
  onClick: (y) => {
996
- v(y, _);
997
+ v(y, p);
997
998
  }
998
999
  }
999
1000
  ) }),
@@ -1003,7 +1004,7 @@ const Zn = (r) => {
1003
1004
  name: "Trash",
1004
1005
  hoverable: !0,
1005
1006
  onClick: () => {
1006
- const y = o.filter((w) => w.id !== _.id);
1007
+ const y = o.filter((w) => w.id !== p.id);
1007
1008
  e(y);
1008
1009
  },
1009
1010
  width: 20,
@@ -1014,15 +1015,15 @@ const Zn = (r) => {
1014
1015
  ] })
1015
1016
  ]
1016
1017
  },
1017
- _.id
1018
+ p.id
1018
1019
  )),
1019
1020
  c && /* @__PURE__ */ t.jsx(
1020
1021
  $t,
1021
1022
  {
1022
1023
  ref: x,
1023
1024
  activeButton: c,
1024
- setActiveButton: p,
1025
- popupPosition: I,
1025
+ setActiveButton: _,
1026
+ popupPosition: k,
1026
1027
  editableLink: g
1027
1028
  }
1028
1029
  ),
@@ -1041,8 +1042,8 @@ const Zn = (r) => {
1041
1042
  className: K.button,
1042
1043
  size: "s",
1043
1044
  onClick: () => {
1044
- const _ = [...o];
1045
- g ? _.push({
1045
+ const p = [...o];
1046
+ g ? p.push({
1046
1047
  type: "Primary",
1047
1048
  id: nt(),
1048
1049
  typesText: [],
@@ -1052,7 +1053,7 @@ const Zn = (r) => {
1052
1053
  destination: "Go to Page",
1053
1054
  page: h ? Object.values(h)[0].name : "Home",
1054
1055
  openInNewTab: !1
1055
- }) : _.push({
1056
+ }) : p.push({
1056
1057
  type: "Primary",
1057
1058
  id: nt(),
1058
1059
  typesText: [],
@@ -1062,7 +1063,7 @@ const Zn = (r) => {
1062
1063
  destination: "Go to Page",
1063
1064
  page: h ? Object.values(h)[0].name : "Home",
1064
1065
  openInNewTab: !1
1065
- }), e(_);
1066
+ }), e(p);
1066
1067
  },
1067
1068
  style: {
1068
1069
  width: "fit-content"
@@ -1083,8 +1084,8 @@ const Zn = (r) => {
1083
1084
  }
1084
1085
  )
1085
1086
  ] });
1086
- }, ti = (r) => {
1087
- const { isActiveButtons: o, setIsActiveButtons: e, buttons: s, setButtons: n, editableLink: g = !0 } = r;
1087
+ }, ti = (d) => {
1088
+ const { isActiveButtons: o, setIsActiveButtons: e, buttons: s, setButtons: n, editableLink: g = !0 } = d;
1088
1089
  return /* @__PURE__ */ t.jsx(t.Fragment, { children: /* @__PURE__ */ t.jsxs("div", { className: lt.buttonsBlock, children: [
1089
1090
  /* @__PURE__ */ t.jsxs("div", { className: lt.top, children: [
1090
1091
  /* @__PURE__ */ t.jsx("h3", { className: lt.title, children: "Buttons" }),
@@ -1106,10 +1107,10 @@ const Zn = (r) => {
1106
1107
  )
1107
1108
  ] }) });
1108
1109
  };
1109
- function ms(r) {
1110
- const { product: o, children: e } = r, { attributes: s, listeners: n, setNodeRef: g, transform: h, transition: c, isDragging: p } = ft({
1110
+ function ms(d) {
1111
+ const { product: o, children: e } = d, { attributes: s, listeners: n, setNodeRef: g, transform: h, transition: c, isDragging: _ } = ft({
1111
1112
  id: String(o.listingId)
1112
- }), I = {
1113
+ }), k = {
1113
1114
  transform: xt.Transform.toString(h),
1114
1115
  transition: c
1115
1116
  };
@@ -1117,15 +1118,15 @@ function ms(r) {
1117
1118
  "div",
1118
1119
  {
1119
1120
  ref: g,
1120
- style: I,
1121
- className: `${F.product} ${p ? F.dragging : ""}`,
1121
+ style: k,
1122
+ className: `${F.product} ${_ ? F.dragging : ""}`,
1122
1123
  ...s,
1123
1124
  ...n,
1124
1125
  children: e
1125
1126
  }
1126
1127
  );
1127
1128
  }
1128
- const ei = (r) => {
1129
+ const ei = (d) => {
1129
1130
  const {
1130
1131
  isActiveItems: o,
1131
1132
  setIsActiveItems: e,
@@ -1134,19 +1135,19 @@ const ei = (r) => {
1134
1135
  other: g,
1135
1136
  title: h,
1136
1137
  subtitle: c,
1137
- editable: p = !0,
1138
- draggable: I = !1,
1139
- withImage: O = !1,
1140
- deletable: d = !0,
1138
+ editable: _ = !0,
1139
+ draggable: k = !1,
1140
+ withImage: M = !1,
1141
+ deletable: l = !0,
1141
1142
  addable: i = !0,
1142
1143
  itemsType: x,
1143
1144
  itemsOptions: v
1144
- } = r, [_, y] = f.useState(
1145
+ } = d, [p, y] = f.useState(
1145
1146
  null
1146
1147
  ), [w, L] = f.useState({
1147
1148
  top: 0,
1148
1149
  left: 0
1149
- }), [a, $] = f.useState(!1), T = ut(
1150
+ }), [a, $] = f.useState(!1), q = ut(
1150
1151
  mt(ht, {
1151
1152
  activationConstraint: {
1152
1153
  distance: 5
@@ -1154,33 +1155,33 @@ const ei = (r) => {
1154
1155
  })
1155
1156
  );
1156
1157
  f.useEffect(() => {
1157
- const l = () => {
1158
+ const r = () => {
1158
1159
  y(null), $(!1);
1159
1160
  };
1160
- return document.body.addEventListener("click", l), y(null), $(!1), () => {
1161
- y(null), $(!1), document.body.removeEventListener("click", l);
1161
+ return document.body.addEventListener("click", r), y(null), $(!1), () => {
1162
+ y(null), $(!1), document.body.removeEventListener("click", r);
1162
1163
  };
1163
1164
  }, []), f.useEffect(() => {
1164
- if (_) {
1165
- const l = [...s].map((j) => j.listingId === _.listingId ? _ : j);
1166
- n(l);
1165
+ if (p) {
1166
+ const r = [...s].map((j) => j.listingId === p.listingId ? p : j);
1167
+ n(r);
1167
1168
  }
1168
- }, [_]);
1169
- const Q = (l, j) => {
1170
- l.stopPropagation();
1171
- const S = l.target.getBoundingClientRect(), R = 100, P = window.innerHeight;
1169
+ }, [p]);
1170
+ const Q = (r, j) => {
1171
+ r.stopPropagation();
1172
+ const S = r.target.getBoundingClientRect(), R = 100, P = window.innerHeight;
1172
1173
  let z = S.top + window.scrollY;
1173
1174
  z + R > P && (z = P - R - 20), $(!0), L({
1174
1175
  top: z - 80,
1175
1176
  left: S.left - 30
1176
1177
  }), y(j);
1177
1178
  };
1178
- function E(l) {
1179
- if (O)
1180
- return l ? /* @__PURE__ */ t.jsx(
1179
+ function E(r) {
1180
+ if (M)
1181
+ return r ? /* @__PURE__ */ t.jsx(
1181
1182
  "img",
1182
1183
  {
1183
- src: `https://imagedelivery.net/${l}/w=1000`,
1184
+ src: `https://imagedelivery.net/${r}/w=1000`,
1184
1185
  alt: "image",
1185
1186
  width: 16,
1186
1187
  height: 16
@@ -1195,8 +1196,8 @@ const ei = (r) => {
1195
1196
  }
1196
1197
  );
1197
1198
  }
1198
- const u = (l) => {
1199
- const { active: j, over: S } = l;
1199
+ const u = (r) => {
1200
+ const { active: j, over: S } = r;
1200
1201
  if (S && j.id !== S.id) {
1201
1202
  const R = s.findIndex((z) => String(z.listingId) === j.id), P = s.findIndex((z) => String(z.listingId) === S.id);
1202
1203
  if (R !== -1 && P !== -1) {
@@ -1204,11 +1205,11 @@ const ei = (r) => {
1204
1205
  z.splice(P, 0, J), n(z);
1205
1206
  }
1206
1207
  }
1207
- }, C = (l, j) => {
1208
- const S = v.find((P) => l.listingId === P.id);
1208
+ }, C = (r, j) => {
1209
+ const S = v.find((P) => r.listingId === P.id);
1209
1210
  if (!S) return null;
1210
1211
  const R = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
1211
- I && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
1212
+ k && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
1212
1213
  b,
1213
1214
  {
1214
1215
  name: "DotsSixVertical",
@@ -1226,31 +1227,31 @@ const ei = (r) => {
1226
1227
  const m = {
1227
1228
  listingId: J.id,
1228
1229
  image: J.productData.images.length > 0 ? J.productData.images[0].cfId : ""
1229
- }, q = z.map((B) => B.listingId === l.listingId ? m : B);
1230
- y(m), n([...q]);
1230
+ }, A = z.map((B) => B.listingId === r.listingId ? m : B);
1231
+ y(m), n([...A]);
1231
1232
  },
1232
1233
  value: S.productData.name,
1233
1234
  options: [
1234
1235
  ...v.filter((P) => !s.find((z) => z.listingId === P.id)).map((P) => P.productData.name)
1235
1236
  ],
1236
1237
  leftAddon: E(
1237
- l.image || S.productData.images.length > 0 && S.productData.images[0].cfId || ""
1238
+ r.image || S.productData.images.length > 0 && S.productData.images[0].cfId || ""
1238
1239
  )
1239
1240
  },
1240
1241
  j
1241
1242
  ),
1242
1243
  /* @__PURE__ */ t.jsxs("div", { className: F.buttons, children: [
1243
- p && /* @__PURE__ */ t.jsx("div", { className: F.deleteButton, children: /* @__PURE__ */ t.jsx(
1244
+ _ && /* @__PURE__ */ t.jsx("div", { className: F.deleteButton, children: /* @__PURE__ */ t.jsx(
1244
1245
  b,
1245
1246
  {
1246
1247
  name: "Sliders",
1247
1248
  hoverable: !0,
1248
1249
  width: 20,
1249
1250
  height: 20,
1250
- onClick: (P) => Q(P, l)
1251
+ onClick: (P) => Q(P, r)
1251
1252
  }
1252
1253
  ) }),
1253
- d && /* @__PURE__ */ t.jsx("div", { className: F.deleteButton, children: /* @__PURE__ */ t.jsx(
1254
+ l && /* @__PURE__ */ t.jsx("div", { className: F.deleteButton, children: /* @__PURE__ */ t.jsx(
1254
1255
  b,
1255
1256
  {
1256
1257
  name: "Trash",
@@ -1258,27 +1259,27 @@ const ei = (r) => {
1258
1259
  width: 20,
1259
1260
  height: 20,
1260
1261
  fill: "#C12A2A",
1261
- onClick: () => n(s.filter((P) => P !== l))
1262
+ onClick: () => n(s.filter((P) => P !== r))
1262
1263
  }
1263
1264
  ) })
1264
1265
  ] })
1265
1266
  ] });
1266
- return I ? /* @__PURE__ */ t.jsx(
1267
+ return k ? /* @__PURE__ */ t.jsx(
1267
1268
  ms,
1268
1269
  {
1269
- product: l,
1270
+ product: r,
1270
1271
  children: R
1271
1272
  },
1272
- l.listingId
1273
+ r.listingId
1273
1274
  ) : /* @__PURE__ */ t.jsx(
1274
1275
  "div",
1275
1276
  {
1276
1277
  className: F.product,
1277
1278
  children: R
1278
1279
  },
1279
- l.listingId
1280
+ r.listingId
1280
1281
  );
1281
- }, M = f.useRef(null);
1282
+ }, T = f.useRef(null);
1282
1283
  return /* @__PURE__ */ t.jsxs("div", { className: F.productsBlock, children: [
1283
1284
  (h || o !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: F.top, children: [
1284
1285
  h && /* @__PURE__ */ t.jsx("h3", { className: F.title, children: h }),
@@ -1286,15 +1287,15 @@ const ei = (r) => {
1286
1287
  it,
1287
1288
  {
1288
1289
  current: o,
1289
- onChange: (l) => e == null ? void 0 : e(l)
1290
+ onChange: (r) => e == null ? void 0 : e(r)
1290
1291
  }
1291
1292
  )
1292
1293
  ] }),
1293
- a && _ && /* @__PURE__ */ t.jsx(
1294
+ a && p && /* @__PURE__ */ t.jsx(
1294
1295
  Bt,
1295
1296
  {
1296
- ref: M,
1297
- activeItem: _,
1297
+ ref: T,
1298
+ activeItem: p,
1298
1299
  setActiveItem: y,
1299
1300
  setIsOpenModal: $,
1300
1301
  popupPosition: w,
@@ -1303,21 +1304,21 @@ const ei = (r) => {
1303
1304
  ),
1304
1305
  o && /* @__PURE__ */ t.jsxs("div", { className: F.products, children: [
1305
1306
  c && /* @__PURE__ */ t.jsx("h5", { className: F.subtitle, children: c }),
1306
- I ? /* @__PURE__ */ t.jsx(
1307
+ k ? /* @__PURE__ */ t.jsx(
1307
1308
  pt,
1308
1309
  {
1309
- sensors: T,
1310
+ sensors: q,
1310
1311
  onDragEnd: u,
1311
1312
  children: /* @__PURE__ */ t.jsx(
1312
1313
  _t,
1313
1314
  {
1314
- items: s.map((l) => String(l.listingId)),
1315
+ items: s.map((r) => String(r.listingId)),
1315
1316
  strategy: gt,
1316
- children: s.map((l, j) => C(l, j))
1317
+ children: s.map((r, j) => C(r, j))
1317
1318
  }
1318
1319
  )
1319
1320
  }
1320
- ) : s.map((l, j) => C(l, j)),
1321
+ ) : s.map((r, j) => C(r, j)),
1321
1322
  i && /* @__PURE__ */ t.jsx(
1322
1323
  "div",
1323
1324
  {
@@ -1333,16 +1334,16 @@ const ei = (r) => {
1333
1334
  className: F.button,
1334
1335
  size: "s",
1335
1336
  onClick: () => {
1336
- const l = [...s];
1337
+ const r = [...s];
1337
1338
  for (let j = 0; j < v.length; j++)
1338
1339
  if (!s.find((S) => S.listingId === v[j].id)) {
1339
- l.push({
1340
+ r.push({
1340
1341
  listingId: v[j].id,
1341
1342
  image: v[j].productData.images.length > 0 ? v[j].productData.images[0].cfId : ""
1342
1343
  });
1343
1344
  break;
1344
1345
  }
1345
- n(l);
1346
+ n(r);
1346
1347
  },
1347
1348
  disabled: s.length === v.length,
1348
1349
  style: {
@@ -1366,7 +1367,7 @@ const ei = (r) => {
1366
1367
  ] }),
1367
1368
  o && g !== void 0 && /* @__PURE__ */ t.jsx(dt, { items: g })
1368
1369
  ] });
1369
- }, hs = "_options_6cemk_1", ps = "_price_6cemk_12", _s = "_oldPrice_6cemk_19", gs = "_newPrice_6cemk_27", fs = "_animate_6cemk_34", xs = "_appearAndBounce_6cemk_1", bs = "_meta_6cemk_52", js = "_info_6cemk_58", vs = "_infoRight_6cemk_66", ys = "_buttons_6cemk_73", Ns = "_variants_6cemk_80", ks = "_variant_6cemk_80", Is = "_stock_6cemk_98", Cs = "_variantInfo_6cemk_105", Ss = "_quantity_6cemk_111", ws = "_count_6cemk_118", $s = "_focused_6cemk_135", Bs = "_button_6cemk_73", Ps = "_activeVariant_6cemk_161", Ms = "_chargeTypes_6cemk_165", Ts = "_charge_6cemk_165", qs = "_chargeActive_6cemk_190", As = "_title_6cemk_198", k = {
1370
+ }, hs = "_options_6cemk_1", ps = "_price_6cemk_12", _s = "_oldPrice_6cemk_19", gs = "_newPrice_6cemk_27", fs = "_animate_6cemk_34", xs = "_appearAndBounce_6cemk_1", bs = "_meta_6cemk_52", js = "_info_6cemk_58", vs = "_infoRight_6cemk_66", ys = "_buttons_6cemk_73", Ns = "_variants_6cemk_80", ks = "_variant_6cemk_80", Is = "_stock_6cemk_98", Cs = "_variantInfo_6cemk_105", Ss = "_quantity_6cemk_111", ws = "_count_6cemk_118", $s = "_focused_6cemk_135", Bs = "_button_6cemk_73", Ps = "_activeVariant_6cemk_161", Ms = "_chargeTypes_6cemk_165", Ts = "_charge_6cemk_165", qs = "_chargeActive_6cemk_190", As = "_title_6cemk_198", I = {
1370
1371
  options: hs,
1371
1372
  price: ps,
1372
1373
  oldPrice: _s,
@@ -1391,24 +1392,24 @@ const ei = (r) => {
1391
1392
  chargeActive: qs,
1392
1393
  title: As
1393
1394
  };
1394
- var kt = /* @__PURE__ */ ((r) => (r.ONE_TIME = "One-Time", r.RECURRING = "Subscribe & Save", r))(kt || {});
1395
- const si = (r) => {
1395
+ var kt = /* @__PURE__ */ ((d) => (d.ONE_TIME = "One-Time", d.RECURRING = "Subscribe & Save", d))(kt || {});
1396
+ const si = (d) => {
1396
1397
  var w, L;
1397
- const { variants: o } = r, [e, s] = f.useState(o[0]), [n, g] = f.useState(e.chargeTypes[0]), h = ct(), [c, p] = f.useState(1), { reset: I, addProductToCart: O, getProducts: d } = bt(), [i, x] = f.useState(!1);
1398
+ const { variants: o } = d, [e, s] = f.useState(o[0]), [n, g] = f.useState(e.chargeTypes[0]), h = ct(), [c, _] = f.useState(1), { reset: k, addProductToCart: M, getProducts: l } = bt(), [i, x] = f.useState(!1);
1398
1399
  f.useEffect(() => {
1399
1400
  x(!0);
1400
1401
  const a = setTimeout(() => x(!1), 600);
1401
1402
  return () => clearTimeout(a);
1402
1403
  }, [c]);
1403
1404
  async function v() {
1404
- await d(), await O({
1405
- productId: r.id,
1405
+ await l(), await M({
1406
+ productId: d.id,
1406
1407
  productVariantId: e.id,
1407
1408
  quantity: c
1408
1409
  });
1409
1410
  }
1410
- function _() {
1411
- I(), v(), h("/checkout");
1411
+ function p() {
1412
+ k(), v(), h("/checkout");
1412
1413
  }
1413
1414
  function y(a) {
1414
1415
  if (a >= 864e5) {
@@ -1426,37 +1427,37 @@ const si = (r) => {
1426
1427
  }
1427
1428
  }
1428
1429
  return f.useEffect(() => {
1429
- (e.quantity.available === 0 || !e.quantity.available) && p(0);
1430
- }, [e.quantity.available]), /* @__PURE__ */ t.jsxs("div", { className: k.options, children: [
1431
- e.chargeTypes.length > 1 && /* @__PURE__ */ t.jsx("div", { className: k.chargeTypes, children: e.chargeTypes.map((a) => /* @__PURE__ */ t.jsx(
1430
+ (e.quantity.available === 0 || !e.quantity.available) && _(0);
1431
+ }, [e.quantity.available]), /* @__PURE__ */ t.jsxs("div", { className: I.options, children: [
1432
+ e.chargeTypes.length > 1 && /* @__PURE__ */ t.jsx("div", { className: I.chargeTypes, children: e.chargeTypes.map((a) => /* @__PURE__ */ t.jsx(
1432
1433
  "div",
1433
1434
  {
1434
- className: V(k.charge, {
1435
- [k.chargeActive]: n === a
1435
+ className: V(I.charge, {
1436
+ [I.chargeActive]: n === a
1436
1437
  }),
1437
1438
  onClick: () => g(a),
1438
1439
  children: kt[a]
1439
1440
  },
1440
1441
  a
1441
1442
  )) }),
1442
- /* @__PURE__ */ t.jsx("div", { className: k.variants, children: o.map((a) => {
1443
+ /* @__PURE__ */ t.jsx("div", { className: I.variants, children: o.map((a) => {
1443
1444
  var $;
1444
1445
  return /* @__PURE__ */ t.jsxs(
1445
1446
  "div",
1446
1447
  {
1447
- className: V(k.variant, {
1448
- [k.activeVariant]: e.id === a.id
1448
+ className: V(I.variant, {
1449
+ [I.activeVariant]: e.id === a.id
1449
1450
  }),
1450
1451
  onClick: () => s(a),
1451
1452
  children: [
1452
- /* @__PURE__ */ t.jsxs("div", { className: k.variantInfo, children: [
1453
- /* @__PURE__ */ t.jsx("span", { className: k.title, children: a.name }),
1453
+ /* @__PURE__ */ t.jsxs("div", { className: I.variantInfo, children: [
1454
+ /* @__PURE__ */ t.jsx("span", { className: I.title, children: a.name }),
1454
1455
  /* @__PURE__ */ t.jsxs("span", { children: [
1455
1456
  "$",
1456
1457
  n === "ONE_TIME" ? a.price.amount : a.subscriptionSettings ? a.subscriptionSettings.price.amount : "Price Not Found"
1457
1458
  ] })
1458
1459
  ] }),
1459
- /* @__PURE__ */ t.jsx("div", { children: n === "ONE_TIME" && /* @__PURE__ */ t.jsxs("span", { className: k.stock, children: [
1460
+ /* @__PURE__ */ t.jsx("div", { children: n === "ONE_TIME" && /* @__PURE__ */ t.jsxs("span", { className: I.stock, children: [
1460
1461
  (($ = a.quantity.restrictions) == null ? void 0 : $.max) || a.quantity.available || 0,
1461
1462
  " in stock"
1462
1463
  ] }) })
@@ -1465,15 +1466,15 @@ const si = (r) => {
1465
1466
  a.id
1466
1467
  );
1467
1468
  }) }),
1468
- n === "ONE_TIME" && /* @__PURE__ */ t.jsxs("div", { className: k.quantity, children: [
1469
+ n === "ONE_TIME" && /* @__PURE__ */ t.jsxs("div", { className: I.quantity, children: [
1469
1470
  /* @__PURE__ */ t.jsx(
1470
1471
  Y,
1471
1472
  {
1472
1473
  type: "Secondary",
1473
1474
  onClick: () => {
1474
- c > 1 ? p((a) => a - 1) : p(1);
1475
+ c > 1 ? _((a) => a - 1) : _(1);
1475
1476
  },
1476
- className: k.button,
1477
+ className: I.button,
1477
1478
  disabled: e.quantity.available === 0 || e.quantity.restrictions && c <= e.quantity.restrictions.min || Object.keys(e.quantity.restrictions || {}).length === 0 && !e.quantity.available,
1478
1479
  children: /* @__PURE__ */ t.jsx(b, { name: "Minus" })
1479
1480
  }
@@ -1483,7 +1484,7 @@ const si = (r) => {
1483
1484
  {
1484
1485
  type: "number",
1485
1486
  value: String(c),
1486
- onChange: (a) => p(Number(a)),
1487
+ onChange: (a) => _(Number(a)),
1487
1488
  max: ((w = e.quantity.restrictions) == null ? void 0 : w.max) || e.quantity.available || 1 / 0,
1488
1489
  min: ((L = e.quantity.restrictions) == null ? void 0 : L.min) || 0,
1489
1490
  centered: !0,
@@ -1495,18 +1496,18 @@ const si = (r) => {
1495
1496
  {
1496
1497
  type: "Secondary",
1497
1498
  onClick: () => {
1498
- p((a) => a + 1);
1499
+ _((a) => a + 1);
1499
1500
  },
1500
- className: k.button,
1501
+ className: I.button,
1501
1502
  disabled: !!(e.quantity.restrictions && c >= e.quantity.restrictions.max || e.quantity.available !== void 0 && c >= e.quantity.available || Object.keys(e.quantity.restrictions || {}).length === 0 && !e.quantity.available),
1502
1503
  children: /* @__PURE__ */ t.jsx(b, { name: "Plus" })
1503
1504
  }
1504
1505
  )
1505
1506
  ] }),
1506
- /* @__PURE__ */ t.jsxs("div", { className: k.meta, children: [
1507
- /* @__PURE__ */ t.jsxs("div", { className: k.info, children: [
1507
+ /* @__PURE__ */ t.jsxs("div", { className: I.meta, children: [
1508
+ /* @__PURE__ */ t.jsxs("div", { className: I.info, children: [
1508
1509
  /* @__PURE__ */ t.jsx("span", { children: "Delivery" }),
1509
- /* @__PURE__ */ t.jsxs("div", { className: k.infoRight, children: [
1510
+ /* @__PURE__ */ t.jsxs("div", { className: I.infoRight, children: [
1510
1511
  /* @__PURE__ */ t.jsx(
1511
1512
  b,
1512
1513
  {
@@ -1519,41 +1520,41 @@ const si = (r) => {
1519
1520
  /* @__PURE__ */ t.jsx("span", { children: !e.deliveryTime || e.deliveryTime === 0 ? "Instant" : y(e.deliveryTime) })
1520
1521
  ] })
1521
1522
  ] }),
1522
- /* @__PURE__ */ t.jsxs("div", { className: k.info, children: [
1523
+ /* @__PURE__ */ t.jsxs("div", { className: I.info, children: [
1523
1524
  /* @__PURE__ */ t.jsx("span", { children: "Price" }),
1524
- /* @__PURE__ */ t.jsx("div", { className: k.infoRight, children: n === "ONE_TIME" ? e.compareAtPrice && (e.compareAtPrice.amount || 0) - (e.price.amount || 0) > 0 ? /* @__PURE__ */ t.jsxs("div", { className: k.price, children: [
1525
- /* @__PURE__ */ t.jsxs("span", { className: V(k.newPrice, { [k.animate]: i }), children: [
1525
+ /* @__PURE__ */ t.jsx("div", { className: I.infoRight, children: n === "ONE_TIME" ? e.compareAtPrice && (e.compareAtPrice.amount || 0) - (e.price.amount || 0) > 0 ? /* @__PURE__ */ t.jsxs("div", { className: I.price, children: [
1526
+ /* @__PURE__ */ t.jsxs("span", { className: V(I.newPrice, { [I.animate]: i }), children: [
1526
1527
  "$ ",
1527
1528
  (e.price.amount || 0) * c
1528
1529
  ] }),
1529
- /* @__PURE__ */ t.jsxs("span", { className: k.oldPrice, children: [
1530
+ /* @__PURE__ */ t.jsxs("span", { className: I.oldPrice, children: [
1530
1531
  "$ ",
1531
1532
  (e.compareAtPrice.amount || 0) * c
1532
1533
  ] })
1533
- ] }) : /* @__PURE__ */ t.jsxs("span", { className: V(k.newPrice, { [k.animate]: i }), children: [
1534
+ ] }) : /* @__PURE__ */ t.jsxs("span", { className: V(I.newPrice, { [I.animate]: i }), children: [
1534
1535
  "$ ",
1535
1536
  (e.price.amount || 0) * c
1536
- ] }) : e.subscriptionSettings && e.subscriptionSettings.compareAtPrice && (e.subscriptionSettings.compareAtPrice.amount || 0) - (e.subscriptionSettings.price.amount || 0) > 0 ? /* @__PURE__ */ t.jsxs("div", { className: k.price, children: [
1537
- /* @__PURE__ */ t.jsxs("span", { className: V(k.newPrice, { [k.animate]: i }), children: [
1537
+ ] }) : e.subscriptionSettings && e.subscriptionSettings.compareAtPrice && (e.subscriptionSettings.compareAtPrice.amount || 0) - (e.subscriptionSettings.price.amount || 0) > 0 ? /* @__PURE__ */ t.jsxs("div", { className: I.price, children: [
1538
+ /* @__PURE__ */ t.jsxs("span", { className: V(I.newPrice, { [I.animate]: i }), children: [
1538
1539
  "$ ",
1539
1540
  e.subscriptionSettings.price.amount || 0
1540
1541
  ] }),
1541
- /* @__PURE__ */ t.jsxs("span", { className: k.oldPrice, children: [
1542
+ /* @__PURE__ */ t.jsxs("span", { className: I.oldPrice, children: [
1542
1543
  "$ ",
1543
1544
  e.subscriptionSettings.compareAtPrice.amount || 0
1544
1545
  ] })
1545
- ] }) : e.subscriptionSettings && /* @__PURE__ */ t.jsxs("span", { className: V(k.newPrice, { [k.animate]: i }), children: [
1546
+ ] }) : e.subscriptionSettings && /* @__PURE__ */ t.jsxs("span", { className: V(I.newPrice, { [I.animate]: i }), children: [
1546
1547
  "$ ",
1547
1548
  e.subscriptionSettings.price.amount || 0
1548
1549
  ] }) })
1549
1550
  ] })
1550
1551
  ] }),
1551
- /* @__PURE__ */ t.jsxs("div", { className: k.buttons, children: [
1552
+ /* @__PURE__ */ t.jsxs("div", { className: I.buttons, children: [
1552
1553
  /* @__PURE__ */ t.jsx(
1553
1554
  Y,
1554
1555
  {
1555
1556
  type: "Primary",
1556
- onClick: () => _(),
1557
+ onClick: () => p(),
1557
1558
  disabled: e.quantity.available === 0 || !e.quantity.available || Object.keys(e.quantity.restrictions || {}).length === 0 && !e.quantity.available,
1558
1559
  children: n === "ONE_TIME" ? "Buy Now" : "Subscribe Now"
1559
1560
  }
@@ -1609,14 +1610,14 @@ const si = (r) => {
1609
1610
  pagesMobileModalContent: _n,
1610
1611
  pagesMobileModalHeader: gn,
1611
1612
  pagesMobileModalFooter: fn
1612
- }, ni = (r) => {
1613
- const { shopping: o, signUp: e, isShowUserInfo: s = !0 } = r;
1613
+ }, ni = (d) => {
1614
+ const { shopping: o, signUp: e, isShowUserInfo: s = !0 } = d;
1614
1615
  return /* @__PURE__ */ t.jsxs("div", { className: N.buttons, children: [
1615
1616
  o && /* @__PURE__ */ t.jsx(xn, {}),
1616
1617
  s && /* @__PURE__ */ t.jsx(It, { signUp: e })
1617
1618
  ] });
1618
1619
  }, xn = () => {
1619
- const [r, o] = f.useState(!1), [e, s] = f.useState([]), { cart: n, getProducts: g } = bt();
1620
+ const [d, o] = f.useState(!1), [e, s] = f.useState([]), { cart: n, getProducts: g } = bt();
1620
1621
  function h(i) {
1621
1622
  for (let x = 0; x < n.parts.length; x++)
1622
1623
  for (let v = 0; v < i.variants.length; v++)
@@ -1631,19 +1632,19 @@ const si = (r) => {
1631
1632
  }
1632
1633
  f.useEffect(() => {
1633
1634
  (async () => {
1634
- const x = n.parts.map((y) => String(y.productId)), _ = (await g([...x])).map((y) => ({
1635
+ const x = n.parts.map((y) => String(y.productId)), p = (await g([...x])).map((y) => ({
1635
1636
  ...y,
1636
1637
  activeVariantId: h(y),
1637
1638
  quantity: c(y)
1638
1639
  }));
1639
- s(_);
1640
+ s(p);
1640
1641
  })();
1641
1642
  }, [n.parts.length]);
1642
- function p(i) {
1643
+ function _(i) {
1643
1644
  var x;
1644
1645
  return !i || !(i != null && i.variants) ? !1 : (x = i.variants.find((v) => v.id === i.activeVariantId)) == null ? void 0 : x.subscriptionSettings;
1645
1646
  }
1646
- const I = n.parts.length > 0 && e.length > 0 && !p(e[0]), [O, d] = f.useState(!1);
1647
+ const k = n.parts.length > 0 && e.length > 0 && !_(e[0]), [M, l] = f.useState(!1);
1647
1648
  return /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
1648
1649
  /* @__PURE__ */ t.jsxs(
1649
1650
  Y,
@@ -1653,7 +1654,7 @@ const si = (r) => {
1653
1654
  padding: 10
1654
1655
  },
1655
1656
  onClick: (i) => {
1656
- i.stopPropagation(), window.location.pathname.includes("/admin/builder") || (o(!0), d(!0));
1657
+ i.stopPropagation(), window.location.pathname.includes("/admin/builder") || (o(!0), l(!0));
1657
1658
  },
1658
1659
  children: [
1659
1660
  /* @__PURE__ */ t.jsx(
@@ -1663,15 +1664,15 @@ const si = (r) => {
1663
1664
  fill: "var(--icon-primary)"
1664
1665
  }
1665
1666
  ),
1666
- I && /* @__PURE__ */ t.jsx("div", { className: N.shoppingCount, children: n.parts.length })
1667
+ k && /* @__PURE__ */ t.jsx("div", { className: N.shoppingCount, children: n.parts.length })
1667
1668
  ]
1668
1669
  }
1669
1670
  ),
1670
- r && /* @__PURE__ */ t.jsx(
1671
+ d && /* @__PURE__ */ t.jsx(
1671
1672
  jt,
1672
1673
  {
1673
1674
  close: () => {
1674
- d(!1), setTimeout(() => {
1675
+ l(!1), setTimeout(() => {
1675
1676
  o(!1);
1676
1677
  }, 300);
1677
1678
  },
@@ -1680,26 +1681,26 @@ const si = (r) => {
1680
1681
  bn,
1681
1682
  {
1682
1683
  activeProducts: e,
1683
- isCartNotEmpty: I,
1684
- isOpen: O
1684
+ isCartNotEmpty: k,
1685
+ isOpen: M
1685
1686
  }
1686
1687
  )
1687
1688
  }
1688
1689
  )
1689
1690
  ] });
1690
- }, bn = (r) => {
1691
- const { activeProducts: o, isCartNotEmpty: e, isOpen: s } = r, { cart: n, reset: g, getTotalAndDiscount: h, updateQuantityOfProduct: c } = bt(), p = ct();
1692
- function I(i) {
1693
- p(i);
1691
+ }, bn = (d) => {
1692
+ const { activeProducts: o, isCartNotEmpty: e, isOpen: s } = d, { cart: n, reset: g, getTotalAndDiscount: h, updateQuantityOfProduct: c } = bt(), _ = ct();
1693
+ function k(i) {
1694
+ _(i);
1694
1695
  }
1695
- function O(i) {
1696
+ function M(i) {
1696
1697
  c({
1697
1698
  productId: i.id,
1698
1699
  productVariantId: i.activeVariantId,
1699
1700
  quantity: i.quantity + 1
1700
1701
  });
1701
1702
  }
1702
- function d(i) {
1703
+ function l(i) {
1703
1704
  c({
1704
1705
  productId: i.id,
1705
1706
  productVariantId: i.activeVariantId,
@@ -1761,7 +1762,7 @@ const si = (r) => {
1761
1762
  "div",
1762
1763
  {
1763
1764
  onClick: () => {
1764
- i.quantity !== 1 && d(i);
1765
+ i.quantity !== 1 && l(i);
1765
1766
  },
1766
1767
  className: N.productButton,
1767
1768
  children: /* @__PURE__ */ t.jsx(
@@ -1779,7 +1780,7 @@ const si = (r) => {
1779
1780
  /* @__PURE__ */ t.jsx(
1780
1781
  "div",
1781
1782
  {
1782
- onClick: () => O(i),
1783
+ onClick: () => M(i),
1783
1784
  className: N.productButton,
1784
1785
  children: /* @__PURE__ */ t.jsx(
1785
1786
  b,
@@ -1816,7 +1817,7 @@ const si = (r) => {
1816
1817
  h().total
1817
1818
  ] })
1818
1819
  ] }),
1819
- /* @__PURE__ */ t.jsx(Y, { onClick: () => I("/checkout"), children: "Checkout" })
1820
+ /* @__PURE__ */ t.jsx(Y, { onClick: () => k("/checkout"), children: "Checkout" })
1820
1821
  ] })
1821
1822
  ] }) : /* @__PURE__ */ t.jsx(jn, {})
1822
1823
  ]
@@ -1843,7 +1844,7 @@ const si = (r) => {
1843
1844
  }
1844
1845
  )
1845
1846
  ] })
1846
- ] }), It = ({ signUp: r }) => {
1847
+ ] }), It = ({ signUp: d }) => {
1847
1848
  const o = JSON.parse(localStorage.getItem("token") || "{}"), { data: e } = o, s = ct();
1848
1849
  function n(c) {
1849
1850
  window.location.pathname.includes("/admin/builder") || s(c);
@@ -1861,7 +1862,7 @@ const si = (r) => {
1861
1862
  children: "Login"
1862
1863
  }
1863
1864
  ),
1864
- r && /* @__PURE__ */ t.jsx(
1865
+ d && /* @__PURE__ */ t.jsx(
1865
1866
  Y,
1866
1867
  {
1867
1868
  onClick: () => n("/customer-dash"),
@@ -1877,8 +1878,8 @@ const si = (r) => {
1877
1878
  const [g, h] = f.useState("test-email@gmail.com");
1878
1879
  return f.useEffect(() => {
1879
1880
  (async () => {
1880
- const p = Mt(e);
1881
- h(p.email);
1881
+ const _ = Mt(e);
1882
+ h(_.email);
1882
1883
  })();
1883
1884
  }, [e]), /* @__PURE__ */ t.jsx(
1884
1885
  "div",
@@ -1889,7 +1890,7 @@ const si = (r) => {
1889
1890
  }
1890
1891
  );
1891
1892
  }, vn = ({
1892
- children: r,
1893
+ children: d,
1893
1894
  logo: o,
1894
1895
  setIsOpen: e,
1895
1896
  signUp: s
@@ -1922,13 +1923,13 @@ const si = (r) => {
1922
1923
  }
1923
1924
  )
1924
1925
  ] }),
1925
- /* @__PURE__ */ t.jsx("div", { className: N.pagesMobileModalContent, children: r }),
1926
+ /* @__PURE__ */ t.jsx("div", { className: N.pagesMobileModalContent, children: d }),
1926
1927
  /* @__PURE__ */ t.jsx("div", { className: N.pagesMobileModalFooter, children: /* @__PURE__ */ t.jsx(It, { signUp: s }) })
1927
1928
  ]
1928
1929
  }
1929
1930
  );
1930
1931
  }, ii = ({
1931
- children: r,
1932
+ children: d,
1932
1933
  logo: o,
1933
1934
  signUp: e
1934
1935
  }) => {
@@ -1941,12 +1942,12 @@ const si = (r) => {
1941
1942
  logo: o,
1942
1943
  setIsOpen: n,
1943
1944
  signUp: e,
1944
- children: r
1945
+ children: d
1945
1946
  }
1946
1947
  ) })
1947
1948
  ] });
1948
- }, yn = (r) => {
1949
- const { setIsOpenModal: o } = r;
1949
+ }, yn = (d) => {
1950
+ const { setIsOpenModal: o } = d;
1950
1951
  return /* @__PURE__ */ t.jsx(
1951
1952
  Y,
1952
1953
  {
@@ -1979,7 +1980,7 @@ const si = (r) => {
1979
1980
  copyTextMobile: Mn,
1980
1981
  copyTextMiniMobile: Tn
1981
1982
  }, oi = () => {
1982
- const { isOpenModal: r, setIsOpenModal: o } = Nt();
1983
+ const { isOpenModal: d, setIsOpenModal: o } = Nt();
1983
1984
  function e() {
1984
1985
  o(!0);
1985
1986
  }
@@ -2002,10 +2003,10 @@ const si = (r) => {
2002
2003
  )
2003
2004
  }
2004
2005
  ),
2005
- r && /* @__PURE__ */ t.jsx(jt, { close: o, children: /* @__PURE__ */ t.jsx(qn, {}) })
2006
+ d && /* @__PURE__ */ t.jsx(jt, { close: o, children: /* @__PURE__ */ t.jsx(qn, {}) })
2006
2007
  ] });
2007
2008
  }, qn = () => {
2008
- const { setIsOpenModal: r } = Nt(), { notification: o, setNotification: e } = Tt(), { setIsOpen: s } = yt(), n = window.location.href;
2009
+ const { setIsOpenModal: d } = Nt(), { notification: o, setNotification: e } = Tt(), { setIsOpen: s } = yt(), n = window.location.href;
2009
2010
  function g() {
2010
2011
  navigator.clipboard.writeText(n), e({
2011
2012
  message: "Link copied to clipboard",
@@ -2014,17 +2015,17 @@ const si = (r) => {
2014
2015
  }
2015
2016
  function h() {
2016
2017
  s(!1), setTimeout(() => {
2017
- r(!1), s(!0);
2018
+ d(!1), s(!0);
2018
2019
  }, 300);
2019
2020
  }
2020
- function c(p, I) {
2021
- return p.length > I ? p.slice(0, I) + "..." : p;
2021
+ function c(_, k) {
2022
+ return _.length > k ? _.slice(0, k) + "..." : _;
2022
2023
  }
2023
2024
  return /* @__PURE__ */ t.jsxs(
2024
2025
  "div",
2025
2026
  {
2026
2027
  className: Z.modal,
2027
- onClick: (p) => p.stopPropagation(),
2028
+ onClick: (_) => _.stopPropagation(),
2028
2029
  children: [
2029
2030
  /* @__PURE__ */ t.jsxs("div", { className: Z.header, children: [
2030
2031
  /* @__PURE__ */ t.jsx("div", { className: Z.title, children: "Copy Product Link" }),
@@ -2072,8 +2073,8 @@ const si = (r) => {
2072
2073
  icon: En,
2073
2074
  open: zn,
2074
2075
  content: Rn
2075
- }, ai = ({ title: r, content: o, defaultOpen: e = !1 }) => {
2076
- const [s, n] = f.useState(e), [g, h] = f.useState(0), c = f.useRef(null), p = () => {
2076
+ }, ai = ({ title: d, content: o, defaultOpen: e = !1 }) => {
2077
+ const [s, n] = f.useState(e), [g, h] = f.useState(0), c = f.useRef(null), _ = () => {
2077
2078
  n(!s);
2078
2079
  };
2079
2080
  return f.useEffect(() => {
@@ -2083,9 +2084,9 @@ const si = (r) => {
2083
2084
  "div",
2084
2085
  {
2085
2086
  className: st.header,
2086
- onClick: p,
2087
+ onClick: _,
2087
2088
  children: [
2088
- /* @__PURE__ */ t.jsx("h5", { id: "h5", children: r }),
2089
+ /* @__PURE__ */ t.jsx("h5", { id: "h5", children: d }),
2089
2090
  /* @__PURE__ */ t.jsx("div", { className: V(st.icon, { [st.open]: s }), children: /* @__PURE__ */ t.jsx(b, { name: "CaretDown" }) })
2090
2091
  ]
2091
2092
  }
@@ -2100,7 +2101,7 @@ const si = (r) => {
2100
2101
  }
2101
2102
  )
2102
2103
  ] });
2103
- }, ci = ({ children: r, path: o, className: e, target: s = "_self", id: n }) => {
2104
+ }, ci = ({ children: d, path: o, className: e, target: s = "_self", id: n }) => {
2104
2105
  if (window.location.pathname.includes("/admin/builder"))
2105
2106
  return /* @__PURE__ */ t.jsx(
2106
2107
  "div",
@@ -2109,11 +2110,11 @@ const si = (r) => {
2109
2110
  role: "link",
2110
2111
  style: { cursor: "pointer" },
2111
2112
  id: n,
2112
- children: r
2113
+ children: d
2113
2114
  }
2114
2115
  );
2115
- const g = ct(), h = /^https?:\/\//.test(o), c = (p) => {
2116
- h || s === "_blank" ? s === "_blank" ? window.open(o, "_blank") : window.location.href = o : (p.preventDefault(), g(o, { replace: !0 }));
2116
+ const g = ct(), h = /^https?:\/\//.test(o), c = (_) => {
2117
+ h || s === "_blank" ? s === "_blank" ? window.open(o, "_blank") : window.location.href = o : (_.preventDefault(), g(o, { replace: !0 }));
2117
2118
  };
2118
2119
  return /* @__PURE__ */ t.jsx(
2119
2120
  "div",
@@ -2123,7 +2124,7 @@ const si = (r) => {
2123
2124
  role: "link",
2124
2125
  style: { cursor: "pointer" },
2125
2126
  id: n,
2126
- children: r
2127
+ children: d
2127
2128
  }
2128
2129
  );
2129
2130
  }, Dn = "_buttonsBlock_1b2rb_1", Ln = "_slideUp_1b2rb_1", Hn = {
@@ -2146,8 +2147,18 @@ const si = (r) => {
2146
2147
  label: Fn,
2147
2148
  textarea: Vn,
2148
2149
  length: Yn
2149
- }, ri = (r) => {
2150
- const { onChange: o, label: e, value: s, maxLength: n, placeholder: g = "Type something..." } = r, [h, c] = f.useState(s.length);
2150
+ }, ri = (d) => {
2151
+ const {
2152
+ onChange: o,
2153
+ label: e,
2154
+ value: s,
2155
+ maxLength: n,
2156
+ placeholder: g = "Type something...",
2157
+ type: h = "text"
2158
+ } = d, [c, _] = f.useState(s.length);
2159
+ function k(M) {
2160
+ return h === "number" ? M.replace(/[^\d\n]+/g, "") : M;
2161
+ }
2151
2162
  return /* @__PURE__ */ t.jsxs("div", { className: at.wrapper, children: [
2152
2163
  e && /* @__PURE__ */ t.jsx(
2153
2164
  "label",
@@ -2161,9 +2172,10 @@ const si = (r) => {
2161
2172
  "textarea",
2162
2173
  {
2163
2174
  id: e,
2164
- defaultValue: s,
2165
- onChange: (p) => {
2166
- c(p.target.value.length), o(p.target.value);
2175
+ value: s,
2176
+ onChange: (M) => {
2177
+ const l = k(M.target.value);
2178
+ _(l.length), o(l);
2167
2179
  },
2168
2180
  placeholder: g,
2169
2181
  className: at.textarea,
@@ -2171,7 +2183,7 @@ const si = (r) => {
2171
2183
  }
2172
2184
  ),
2173
2185
  n && /* @__PURE__ */ t.jsxs("div", { className: at.length, children: [
2174
- h,
2186
+ c,
2175
2187
  "/",
2176
2188
  n
2177
2189
  ] })