@billgangcom/theme-lib 1.32.0 → 1.33.0

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,20 +1,20 @@
1
- import { j as t, I as f, a as W, c as H, S as K, T as wt, C as ht, b as tt, D as vt, H as jt, B as it, v as ct, u as yt, d as kt, e as gt, f as $t, M as Ct, g as St, h as At } from "./index-CC_0JpL1.js";
2
- import { i as Wo, L as Xo } from "./index-CC_0JpL1.js";
3
- import _ from "react";
1
+ import { j as t, I as f, a as W, c as V, S as K, T as Ct, C as ht, b as tt, D as jt, H as yt, B as ot, v as lt, u as kt, d as $t, e as qt, f as gt, g as wt, h as St, M as Tt, i as Pt, k as Dt } from "./index-DSREXVyt.js";
2
+ import { l as Zo, L as ta } from "./index-DSREXVyt.js";
3
+ import h from "react";
4
4
  import "@phosphor-icons/react";
5
- const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5j_15", Et = "_subtitle_9rr5j_22", Lt = "_alignmentContent_9rr5j_29", Rt = "_alignments_9rr5j_37", Mt = "_alignment_9rr5j_8", Ht = "_circle_9rr5j_58", Ft = "_paddings_9rr5j_65", Vt = "_padding_9rr5j_65", Ut = "_input_9rr5j_84", J = {
6
- wrapper: Ot,
7
- alignmentBlock: qt,
8
- title: Dt,
9
- subtitle: Et,
10
- alignmentContent: Lt,
11
- alignments: Rt,
12
- alignment: Mt,
13
- circle: Ht,
14
- paddings: Ft,
15
- padding: Vt,
16
- input: Ut
17
- }, zt = [
5
+ const Et = "_wrapper_9rr5j_2", Lt = "_alignmentBlock_9rr5j_8", Rt = "_title_9rr5j_15", Mt = "_subtitle_9rr5j_22", Ht = "_alignmentContent_9rr5j_29", Ft = "_alignments_9rr5j_37", Vt = "_alignment_9rr5j_8", Ut = "_circle_9rr5j_58", zt = "_paddings_9rr5j_65", Yt = "_padding_9rr5j_65", Gt = "_input_9rr5j_84", J = {
6
+ wrapper: Et,
7
+ alignmentBlock: Lt,
8
+ title: Rt,
9
+ subtitle: Mt,
10
+ alignmentContent: Ht,
11
+ alignments: Ft,
12
+ alignment: Vt,
13
+ circle: Ut,
14
+ paddings: zt,
15
+ padding: Yt,
16
+ input: Gt
17
+ }, Wt = [
18
18
  "topLeft",
19
19
  "top",
20
20
  "topRight",
@@ -24,7 +24,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
24
24
  "bottomLeft",
25
25
  "bottom",
26
26
  "bottomRight"
27
- ], Yt = ["left", "top", "right", "bottom"], qo = (u) => {
27
+ ], Xt = ["left", "top", "right", "bottom"], Mo = (u) => {
28
28
  const { alignment: o, padding: e, setPadding: n, setAlignment: i } = u;
29
29
  function a() {
30
30
  switch (o) {
@@ -61,7 +61,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
61
61
  /* @__PURE__ */ t.jsxs("div", { className: J.alignmentBlock, children: [
62
62
  /* @__PURE__ */ t.jsx("h5", { className: J.subtitle, children: "Alignment" }),
63
63
  /* @__PURE__ */ t.jsxs("div", { className: J.alignmentContent, children: [
64
- /* @__PURE__ */ t.jsx("div", { className: J.alignments, children: zt.map((s) => /* @__PURE__ */ t.jsxs(
64
+ /* @__PURE__ */ t.jsx("div", { className: J.alignments, children: Wt.map((s) => /* @__PURE__ */ t.jsxs(
65
65
  "div",
66
66
  {
67
67
  onClick: () => {
@@ -83,7 +83,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
83
83
  },
84
84
  s
85
85
  )) }),
86
- /* @__PURE__ */ t.jsx("div", { className: J.paddings, children: Yt.map((s) => /* @__PURE__ */ t.jsxs(
86
+ /* @__PURE__ */ t.jsx("div", { className: J.paddings, children: Xt.map((s) => /* @__PURE__ */ t.jsxs(
87
87
  "label",
88
88
  {
89
89
  className: J.padding,
@@ -116,18 +116,18 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
116
116
  ] })
117
117
  ] })
118
118
  ] });
119
- }, Gt = "_title_18dz7_1", Wt = "_subtitle_18dz7_5", Xt = "_header_18dz7_12", Jt = "_text_18dz7_13", Qt = "_top_18dz7_21", Kt = "_itemsBlock_18dz7_30", rt = {
120
- title: Gt,
121
- subtitle: Wt,
122
- header: Xt,
123
- text: Jt,
124
- top: Qt,
125
- itemsBlock: Kt
126
- }, Zt = "_typeTexts_rcw8p_1", te = "_block_rcw8p_8", ee = "_active_rcw8p_21", ft = {
127
- typeTexts: Zt,
128
- block: te,
129
- active: ee
130
- }, se = ["bold", "italic", "underline", "strike-through", "code"], Tt = (u) => {
119
+ }, Jt = "_title_18dz7_1", Qt = "_subtitle_18dz7_5", Kt = "_header_18dz7_12", Zt = "_text_18dz7_13", te = "_top_18dz7_21", ee = "_itemsBlock_18dz7_30", dt = {
120
+ title: Jt,
121
+ subtitle: Qt,
122
+ header: Kt,
123
+ text: Zt,
124
+ top: te,
125
+ itemsBlock: ee
126
+ }, se = "_typeTexts_rcw8p_1", ne = "_block_rcw8p_8", ie = "_active_rcw8p_21", xt = {
127
+ typeTexts: se,
128
+ block: ne,
129
+ active: ie
130
+ }, oe = ["bold", "italic", "underline", "strike-through", "code"], Bt = (u) => {
131
131
  const { typesText: o, setTypesText: e } = u;
132
132
  function n(i) {
133
133
  switch (i) {
@@ -143,11 +143,11 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
143
143
  return "TextUnderline";
144
144
  }
145
145
  }
146
- return /* @__PURE__ */ t.jsx("div", { className: ft.typeTexts, children: se.map((i) => /* @__PURE__ */ t.jsx(
146
+ return /* @__PURE__ */ t.jsx("div", { className: xt.typeTexts, children: oe.map((i) => /* @__PURE__ */ t.jsx(
147
147
  "div",
148
148
  {
149
- className: H(ft.block, {
150
- [ft.active]: o.includes(i)
149
+ className: V(xt.block, {
150
+ [xt.active]: o.includes(i)
151
151
  }),
152
152
  onClick: () => {
153
153
  const a = [...o];
@@ -169,7 +169,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
169
169
  },
170
170
  String(i)
171
171
  )) });
172
- }, Bt = (u) => {
172
+ }, At = (u) => {
173
173
  const {
174
174
  typesText: o,
175
175
  isActiveText: e,
@@ -180,9 +180,9 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
180
180
  title: s,
181
181
  subtitle: l = "Items"
182
182
  } = u;
183
- return /* @__PURE__ */ t.jsxs("div", { className: rt.text, children: [
184
- (s || e !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: rt.top, children: [
185
- s && /* @__PURE__ */ t.jsx("h3", { className: rt.title, children: s }),
183
+ return /* @__PURE__ */ t.jsxs("div", { className: dt.text, children: [
184
+ (s || e !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: dt.top, children: [
185
+ s && /* @__PURE__ */ t.jsx("h3", { className: dt.title, children: s }),
186
186
  e !== void 0 && n && /* @__PURE__ */ t.jsx(
187
187
  K,
188
188
  {
@@ -191,10 +191,10 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
191
191
  }
192
192
  )
193
193
  ] }),
194
- /* @__PURE__ */ t.jsxs("div", { className: rt.itemsBlock, children: [
195
- /* @__PURE__ */ t.jsx("h5", { className: rt.subtitle, children: l }),
194
+ /* @__PURE__ */ t.jsxs("div", { className: dt.itemsBlock, children: [
195
+ /* @__PURE__ */ t.jsx("h5", { className: dt.subtitle, children: l }),
196
196
  /* @__PURE__ */ t.jsx(
197
- wt,
197
+ Ct,
198
198
  {
199
199
  onChange: (d) => a(d),
200
200
  value: i,
@@ -202,7 +202,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
202
202
  }
203
203
  ),
204
204
  /* @__PURE__ */ t.jsx(
205
- Tt,
205
+ Bt,
206
206
  {
207
207
  typesText: o,
208
208
  setTypesText: c
@@ -210,36 +210,36 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
210
210
  )
211
211
  ] })
212
212
  ] });
213
- }, ne = "_title_fyopx_1", ie = "_subtitle_fyopx_5", oe = "_header_fyopx_12", ae = "_text_fyopx_13", ce = "_productsBlock_fyopx_14", le = "_top_fyopx_26", re = "_itemsBlock_fyopx_35", de = "_typeTexts_fyopx_41", ue = "_block_fyopx_48", pe = "_active_fyopx_61", me = "_products_fyopx_14", he = "_product_fyopx_14", _e = "_button_fyopx_80", ge = "_disabled_fyopx_91", xe = "_image_fyopx_95", fe = "_info_fyopx_102", be = "_name_fyopx_114", ve = "_buttons_fyopx_118", je = "_modal_fyopx_125", ye = "_link_fyopx_145", ke = "_modalOptions_fyopx_151", V = {
214
- title: ne,
215
- subtitle: ie,
216
- header: oe,
217
- text: ae,
218
- productsBlock: ce,
219
- top: le,
220
- itemsBlock: re,
221
- typeTexts: de,
222
- block: ue,
223
- active: pe,
224
- products: me,
225
- product: he,
226
- button: _e,
227
- disabled: ge,
228
- image: xe,
229
- info: fe,
230
- name: be,
231
- buttons: ve,
232
- modal: je,
233
- link: ye,
234
- modalOptions: ke
235
- }, $e = _.forwardRef(
213
+ }, ae = "_title_fyopx_1", ce = "_subtitle_fyopx_5", le = "_header_fyopx_12", re = "_text_fyopx_13", de = "_productsBlock_fyopx_14", ue = "_top_fyopx_26", pe = "_itemsBlock_fyopx_35", me = "_typeTexts_fyopx_41", he = "_block_fyopx_48", _e = "_active_fyopx_61", ge = "_products_fyopx_14", fe = "_product_fyopx_14", xe = "_button_fyopx_80", be = "_disabled_fyopx_91", ve = "_image_fyopx_95", je = "_info_fyopx_102", ye = "_name_fyopx_114", ke = "_buttons_fyopx_118", $e = "_modal_fyopx_125", we = "_link_fyopx_145", Ne = "_modalOptions_fyopx_151", F = {
214
+ title: ae,
215
+ subtitle: ce,
216
+ header: le,
217
+ text: re,
218
+ productsBlock: de,
219
+ top: ue,
220
+ itemsBlock: pe,
221
+ typeTexts: me,
222
+ block: he,
223
+ active: _e,
224
+ products: ge,
225
+ product: fe,
226
+ button: xe,
227
+ disabled: be,
228
+ image: ve,
229
+ info: je,
230
+ name: ye,
231
+ buttons: ke,
232
+ modal: $e,
233
+ link: we,
234
+ modalOptions: Ne
235
+ }, Ie = h.forwardRef(
236
236
  (u, o) => {
237
237
  const { activeItem: e, setActiveItem: n, popupPosition: i, modalOptions: a, setIsOpenModal: c } = u;
238
238
  return /* @__PURE__ */ t.jsxs(
239
239
  "div",
240
240
  {
241
241
  ref: o,
242
- className: V.modal,
242
+ className: F.modal,
243
243
  onClick: (s) => {
244
244
  s.stopPropagation();
245
245
  },
@@ -248,8 +248,8 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
248
248
  left: `${i.left}px`
249
249
  },
250
250
  children: [
251
- /* @__PURE__ */ t.jsxs("div", { className: V.top, children: [
252
- /* @__PURE__ */ t.jsx("h3", { className: V.title, children: e.name }),
251
+ /* @__PURE__ */ t.jsxs("div", { className: F.top, children: [
252
+ /* @__PURE__ */ t.jsx("h3", { className: F.title, children: e.name }),
253
253
  /* @__PURE__ */ t.jsx(
254
254
  f,
255
255
  {
@@ -263,7 +263,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
263
263
  }
264
264
  )
265
265
  ] }),
266
- /* @__PURE__ */ t.jsx("div", { className: V.modalOptions, children: a.map((s) => {
266
+ /* @__PURE__ */ t.jsx("div", { className: F.modalOptions, children: a.map((s) => {
267
267
  if (s.type === "image")
268
268
  return /* @__PURE__ */ t.jsx(
269
269
  ht,
@@ -282,7 +282,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
282
282
  );
283
283
  if (s.type === "text")
284
284
  return /* @__PURE__ */ t.jsx(
285
- Bt,
285
+ At,
286
286
  {
287
287
  typesText: e[s.field.type],
288
288
  setTypesText: (l) => {
@@ -320,7 +320,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
320
320
  }
321
321
  );
322
322
  if (s.type === "inputSwitch")
323
- return /* @__PURE__ */ t.jsxs("div", { className: V.link, children: [
323
+ return /* @__PURE__ */ t.jsxs("div", { className: F.link, children: [
324
324
  /* @__PURE__ */ t.jsx(
325
325
  W,
326
326
  {
@@ -353,7 +353,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
353
353
  ] });
354
354
  if (s.type === "list")
355
355
  return /* @__PURE__ */ t.jsx(
356
- Se,
356
+ Be,
357
357
  {
358
358
  items: e[s.field] || [],
359
359
  setItems: (l) => {
@@ -393,11 +393,11 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
393
393
  }
394
394
  );
395
395
  }
396
- ), Ne = "_other_g74jx_1", Ie = "_subtitle_g74jx_7", we = "_items_g74jx_14", bt = {
397
- other: Ne,
398
- subtitle: Ie,
399
- items: we
400
- }, xt = (u) => {
396
+ ), Ce = "_other_g74jx_1", Se = "_subtitle_g74jx_7", Te = "_items_g74jx_14", bt = {
397
+ other: Ce,
398
+ subtitle: Se,
399
+ items: Te
400
+ }, ft = (u) => {
401
401
  const { items: o, title: e = "Other" } = u;
402
402
  return /* @__PURE__ */ t.jsxs("div", { className: bt.other, children: [
403
403
  /* @__PURE__ */ t.jsx("h5", { className: bt.subtitle, children: e }),
@@ -413,13 +413,13 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
413
413
  i
414
414
  )) })
415
415
  ] });
416
- }, Ce = (u) => {
417
- const { index: o, moveProduct: e, children: n } = u, [, i] = yt({
416
+ }, Pe = (u) => {
417
+ const { index: o, moveProduct: e, children: n } = u, [, i] = kt({
418
418
  accept: "product",
419
419
  hover(s) {
420
420
  s.index !== o && (e(s.index, o), s.index = o);
421
421
  }
422
- }), [{ isDragging: a }, c] = kt({
422
+ }), [{ isDragging: a }, c] = $t({
423
423
  type: "product",
424
424
  item: { index: o },
425
425
  collect: (s) => ({
@@ -430,11 +430,11 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
430
430
  "div",
431
431
  {
432
432
  ref: (s) => c(i(s)),
433
- className: `${V.product} ${a ? V.dragging : ""}`,
433
+ className: `${F.product} ${a ? F.dragging : ""}`,
434
434
  children: n
435
435
  }
436
436
  );
437
- }, Se = (u) => {
437
+ }, Be = (u) => {
438
438
  const {
439
439
  isActiveItems: o,
440
440
  setIsActiveItems: e,
@@ -445,57 +445,57 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
445
445
  subtitle: s,
446
446
  editable: l = !0,
447
447
  draggable: d = !1,
448
- withImage: k = !1,
448
+ withImage: $ = !1,
449
449
  deletable: r = !0,
450
450
  addable: B = !0,
451
- itemsType: h,
452
- itemsPlaceholder: g = "",
451
+ itemsType: x,
452
+ itemsPlaceholder: _ = "",
453
453
  itemsOptions: m,
454
454
  hasRangeSelector: O = !1,
455
- rangeSelectorOptions: R,
456
- modalOptions: P,
457
- addableOptions: q = {},
455
+ rangeSelectorOptions: q,
456
+ modalOptions: b,
457
+ addableOptions: D = {},
458
458
  limit: C,
459
459
  autoScrollInterval: S
460
- } = u, [x, v] = _.useState(null), [M, y] = _.useState({
460
+ } = u, [g, j] = h.useState(null), [M, k] = h.useState({
461
461
  top: 0,
462
462
  left: 0
463
- }), [j, I] = _.useState(null), D = _.useRef(null), [E, U] = _.useState(!1), et = (p, T) => {
464
- const $ = [...n], [X] = $.splice(p, 1);
465
- $.splice(T, 0, X), i($);
463
+ }), [y, N] = h.useState(null), E = h.useRef(null), [L, U] = h.useState(!1), et = (p, T) => {
464
+ const w = [...n], [X] = w.splice(p, 1);
465
+ w.splice(T, 0, X), i(w);
466
466
  };
467
- _.useEffect(() => {
467
+ h.useEffect(() => {
468
468
  const p = () => {
469
- v(null), U(!1);
469
+ j(null), U(!1);
470
470
  };
471
- return document.body.addEventListener("click", p), v(null), U(!1), () => {
472
- v(null), U(!1), document.body.removeEventListener("click", p);
471
+ return document.body.addEventListener("click", p), j(null), U(!1), () => {
472
+ j(null), U(!1), document.body.removeEventListener("click", p);
473
473
  };
474
- }, []), _.useEffect(() => {
475
- if (x) {
476
- const p = [...n].map((T) => T.id === x.id ? x : T);
474
+ }, []), h.useEffect(() => {
475
+ if (g) {
476
+ const p = [...n].map((T) => T.id === g.id ? g : T);
477
477
  i(p);
478
478
  }
479
- }, [x]), _.useEffect(() => {
480
- if (D.current && j) {
481
- const p = D.current.getBoundingClientRect().height, T = window.innerHeight;
482
- let $ = j.top;
483
- $ + p > T + window.scrollY && ($ = T + window.scrollY - p - 200), $ < 0 && ($ = 10), y({
484
- top: $,
485
- left: j.left
479
+ }, [g]), h.useEffect(() => {
480
+ if (E.current && y) {
481
+ const p = E.current.getBoundingClientRect().height, T = window.innerHeight;
482
+ let w = y.top;
483
+ w + p > T + window.scrollY && (w = T + window.scrollY - p - 200), w < 0 && (w = 10), k({
484
+ top: w,
485
+ left: y.left
486
486
  });
487
487
  }
488
- }, [D.current, j]);
489
- const ot = (p, T) => {
488
+ }, [E.current, y]);
489
+ const at = (p, T) => {
490
490
  p.stopPropagation();
491
- const $ = p.target.getBoundingClientRect();
492
- I({
493
- top: $.top + window.scrollY,
494
- left: $.left - 30
495
- }), v(T), U(!0);
491
+ const w = p.target.getBoundingClientRect();
492
+ N({
493
+ top: w.top + window.scrollY,
494
+ left: w.left - 30
495
+ }), j(T), U(!0);
496
496
  };
497
- function b(p) {
498
- if (k)
497
+ function v(p) {
498
+ if ($)
499
499
  return p ? /* @__PURE__ */ t.jsx(
500
500
  "img",
501
501
  {
@@ -516,7 +516,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
516
516
  }
517
517
  const A = (p, T) => {
518
518
  var X;
519
- const $ = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
519
+ const w = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
520
520
  d && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
521
521
  f,
522
522
  {
@@ -526,52 +526,52 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
526
526
  height: 20
527
527
  }
528
528
  ) }),
529
- h === "select" && /* @__PURE__ */ t.jsx(
529
+ x === "select" && /* @__PURE__ */ t.jsx(
530
530
  tt,
531
531
  {
532
- onChange: (L) => {
533
- const lt = [...n].map((st) => st.id === p.id ? {
532
+ onChange: (R) => {
533
+ const rt = [...n].map((st) => st.id === p.id ? {
534
534
  ...p,
535
- name: L
535
+ name: R
536
536
  } : st);
537
- v({
537
+ j({
538
538
  ...p,
539
- name: L
540
- }), i([...lt]);
539
+ name: R
540
+ }), i([...rt]);
541
541
  },
542
542
  value: p.name,
543
- options: m.filter((L) => !n.find((Y) => Y.name === L.name)).map((L) => L.name),
544
- leftAddon: b(p.images)
543
+ options: m.filter((R) => !n.find((Y) => Y.name === R.name)).map((R) => R.name),
544
+ leftAddon: v(p.images)
545
545
  }
546
546
  ),
547
- h === "input" && /* @__PURE__ */ t.jsx(
547
+ x === "input" && /* @__PURE__ */ t.jsx(
548
548
  W,
549
549
  {
550
- onChange: (L) => {
551
- const lt = [...n].map((st) => st.id === p.id ? {
550
+ onChange: (R) => {
551
+ const rt = [...n].map((st) => st.id === p.id ? {
552
552
  ...p,
553
- name: L
553
+ name: R
554
554
  } : st);
555
- i([...lt]);
555
+ i([...rt]);
556
556
  },
557
557
  value: p.name,
558
- placeholder: g
558
+ placeholder: _
559
559
  }
560
560
  ),
561
- h === "image" && /* @__PURE__ */ t.jsx(
561
+ x === "image" && /* @__PURE__ */ t.jsx(
562
562
  ht,
563
563
  {
564
- onChange: (L) => {
565
- const lt = [...n].map((st) => st.id === p.id ? {
564
+ onChange: (R) => {
565
+ const rt = [...n].map((st) => st.id === p.id ? {
566
566
  ...p,
567
- images: L
567
+ images: R
568
568
  } : st);
569
- i([...lt]);
569
+ i([...rt]);
570
570
  },
571
- activeImage: (X = n.find((L) => L.id === p.id)) == null ? void 0 : X.images[0]
571
+ activeImage: (X = n.find((R) => R.id === p.id)) == null ? void 0 : X.images[0]
572
572
  }
573
573
  ),
574
- /* @__PURE__ */ t.jsxs("div", { className: V.buttons, children: [
574
+ /* @__PURE__ */ t.jsxs("div", { className: F.buttons, children: [
575
575
  l && /* @__PURE__ */ t.jsx(
576
576
  f,
577
577
  {
@@ -579,7 +579,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
579
579
  hoverable: !0,
580
580
  width: 20,
581
581
  height: 20,
582
- onClick: (L) => ot(L, p)
582
+ onClick: (R) => at(R, p)
583
583
  }
584
584
  ),
585
585
  r && /* @__PURE__ */ t.jsx(
@@ -590,32 +590,32 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
590
590
  width: 20,
591
591
  height: 20,
592
592
  fill: "#C12A2A",
593
- onClick: () => i(n.filter((L) => L.id !== p.id))
593
+ onClick: () => i(n.filter((R) => R.id !== p.id))
594
594
  }
595
595
  )
596
596
  ] })
597
597
  ] });
598
598
  return d ? /* @__PURE__ */ t.jsx(
599
- Ce,
599
+ Pe,
600
600
  {
601
601
  product: p,
602
602
  index: T,
603
603
  moveProduct: et,
604
- children: $
604
+ children: w
605
605
  },
606
606
  p.id
607
607
  ) : /* @__PURE__ */ t.jsx(
608
608
  "div",
609
609
  {
610
- className: V.product,
611
- children: $
610
+ className: F.product,
611
+ children: w
612
612
  },
613
613
  p.id
614
614
  );
615
615
  };
616
- return /* @__PURE__ */ t.jsxs("div", { className: V.productsBlock, children: [
617
- (c || o !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: V.top, children: [
618
- c && /* @__PURE__ */ t.jsx("h3", { className: V.title, children: c }),
616
+ return /* @__PURE__ */ t.jsxs("div", { className: F.productsBlock, children: [
617
+ (c || o !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: F.top, children: [
618
+ c && /* @__PURE__ */ t.jsx("h3", { className: F.title, children: c }),
619
619
  o !== void 0 && /* @__PURE__ */ t.jsx(
620
620
  K,
621
621
  {
@@ -624,27 +624,27 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
624
624
  }
625
625
  )
626
626
  ] }),
627
- x && l && P && E && /* @__PURE__ */ t.jsx(
628
- $e,
627
+ g && l && b && L && /* @__PURE__ */ t.jsx(
628
+ Ie,
629
629
  {
630
- ref: D,
631
- activeItem: x,
632
- setActiveItem: v,
630
+ ref: E,
631
+ activeItem: g,
632
+ setActiveItem: j,
633
633
  popupPosition: M,
634
- modalOptions: P,
634
+ modalOptions: b,
635
635
  setIsOpenModal: U
636
636
  }
637
637
  ),
638
- O && R && /* @__PURE__ */ t.jsx(Nt, { ...R }),
639
- /* @__PURE__ */ t.jsxs("div", { className: V.products, children: [
640
- s && /* @__PURE__ */ t.jsx("h5", { className: V.subtitle, children: s }),
641
- d ? /* @__PURE__ */ t.jsx(vt, { backend: jt, children: n.map((p, T) => A(p, T)) }) : n.map((p, T) => A(p, T)),
638
+ O && q && /* @__PURE__ */ t.jsx(Nt, { ...q }),
639
+ /* @__PURE__ */ t.jsxs("div", { className: F.products, children: [
640
+ s && /* @__PURE__ */ t.jsx("h5", { className: F.subtitle, children: s }),
641
+ d ? /* @__PURE__ */ t.jsx(jt, { backend: yt, children: n.map((p, T) => A(p, T)) }) : n.map((p, T) => A(p, T)),
642
642
  B && /* @__PURE__ */ t.jsxs(
643
- it,
643
+ ot,
644
644
  {
645
645
  withoutHover: !0,
646
- className: H(V.button, {
647
- [V.disabled]: !!(C && C <= n.length || n.length === (m == null ? void 0 : m.length))
646
+ className: V(F.button, {
647
+ [F.disabled]: !!(C && C <= n.length || n.length === (m == null ? void 0 : m.length))
648
648
  }),
649
649
  size: "s",
650
650
  disabled: !!(C && C <= n.length || n.length === (m == null ? void 0 : m.length)),
@@ -652,24 +652,24 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
652
652
  const p = [...n];
653
653
  let T = null;
654
654
  if (m) {
655
- for (let $ = 0; $ < m.length; $++)
656
- if (!n.find((X) => X.id === m[$].id)) {
657
- T = m[$];
655
+ for (let w = 0; w < m.length; w++)
656
+ if (!n.find((X) => X.id === m[w].id)) {
657
+ T = m[w];
658
658
  break;
659
659
  }
660
660
  }
661
- h === "select" ? p.push({
661
+ x === "select" ? p.push({
662
662
  name: T ? T.name : m[0].name,
663
663
  id: (T == null ? void 0 : T.id) || m[0].id,
664
- ...q
665
- }) : h === "input" ? p.push({
664
+ ...D
665
+ }) : x === "input" ? p.push({
666
666
  name: "",
667
- id: ct(),
668
- ...q
667
+ id: lt(),
668
+ ...D
669
669
  }) : p.push({
670
670
  name: `Image ${n.length + 1}`,
671
- id: ct(),
672
- ...q
671
+ id: lt(),
672
+ ...D
673
673
  }), i(p);
674
674
  },
675
675
  children: [
@@ -686,7 +686,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
686
686
  }
687
687
  )
688
688
  ] }),
689
- a !== void 0 && /* @__PURE__ */ t.jsx(xt, { items: a }),
689
+ a !== void 0 && /* @__PURE__ */ t.jsx(ft, { items: a }),
690
690
  S !== void 0 && /* @__PURE__ */ t.jsx(
691
691
  W,
692
692
  {
@@ -703,29 +703,29 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
703
703
  }
704
704
  )
705
705
  ] });
706
- }, Te = "_title_fyopx_1", Be = "_subtitle_fyopx_5", Pe = "_header_fyopx_12", Ae = "_text_fyopx_13", Oe = "_productsBlock_fyopx_14", qe = "_top_fyopx_26", De = "_itemsBlock_fyopx_35", Ee = "_typeTexts_fyopx_41", Le = "_block_fyopx_48", Re = "_active_fyopx_61", Me = "_products_fyopx_14", He = "_product_fyopx_14", Fe = "_button_fyopx_80", Ve = "_disabled_fyopx_91", Ue = "_image_fyopx_95", ze = "_info_fyopx_102", Ye = "_name_fyopx_114", Ge = "_buttons_fyopx_118", We = "_modal_fyopx_125", Xe = "_link_fyopx_145", Je = "_modalOptions_fyopx_151", Z = {
707
- title: Te,
708
- subtitle: Be,
709
- header: Pe,
710
- text: Ae,
711
- productsBlock: Oe,
712
- top: qe,
713
- itemsBlock: De,
714
- typeTexts: Ee,
715
- block: Le,
716
- active: Re,
717
- products: Me,
718
- product: He,
719
- button: Fe,
720
- disabled: Ve,
721
- image: Ue,
722
- info: ze,
723
- name: Ye,
724
- buttons: Ge,
725
- modal: We,
726
- link: Xe,
727
- modalOptions: Je
728
- }, Do = (u) => {
706
+ }, Ae = "_title_fyopx_1", Oe = "_subtitle_fyopx_5", qe = "_header_fyopx_12", De = "_text_fyopx_13", Ee = "_productsBlock_fyopx_14", Le = "_top_fyopx_26", Re = "_itemsBlock_fyopx_35", Me = "_typeTexts_fyopx_41", He = "_block_fyopx_48", Fe = "_active_fyopx_61", Ve = "_products_fyopx_14", Ue = "_product_fyopx_14", ze = "_button_fyopx_80", Ye = "_disabled_fyopx_91", Ge = "_image_fyopx_95", We = "_info_fyopx_102", Xe = "_name_fyopx_114", Je = "_buttons_fyopx_118", Qe = "_modal_fyopx_125", Ke = "_link_fyopx_145", Ze = "_modalOptions_fyopx_151", Z = {
707
+ title: Ae,
708
+ subtitle: Oe,
709
+ header: qe,
710
+ text: De,
711
+ productsBlock: Ee,
712
+ top: Le,
713
+ itemsBlock: Re,
714
+ typeTexts: Me,
715
+ block: He,
716
+ active: Fe,
717
+ products: Ve,
718
+ product: Ue,
719
+ button: ze,
720
+ disabled: Ye,
721
+ image: Ge,
722
+ info: We,
723
+ name: Xe,
724
+ buttons: Je,
725
+ modal: Qe,
726
+ link: Ke,
727
+ modalOptions: Ze
728
+ }, Ho = (u) => {
729
729
  const {
730
730
  isActiveItems: o,
731
731
  setIsActiveItems: e,
@@ -736,19 +736,19 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
736
736
  subtitle: s,
737
737
  draggable: l = !1,
738
738
  withImage: d = !1,
739
- addable: k = !0,
739
+ addable: $ = !0,
740
740
  itemsOptions: r,
741
741
  hasRangeSelector: B = !1,
742
- rangeSelectorOptions: h,
743
- limit: g,
742
+ rangeSelectorOptions: x,
743
+ limit: _,
744
744
  autoScrollInterval: m
745
745
  } = u;
746
- function O(P) {
746
+ function O(b) {
747
747
  if (d)
748
- return P ? /* @__PURE__ */ t.jsx(
748
+ return b ? /* @__PURE__ */ t.jsx(
749
749
  "img",
750
750
  {
751
- src: `https://imagedelivery.net/${P[0]}/w=1000`,
751
+ src: `https://imagedelivery.net/${b[0]}/w=1000`,
752
752
  alt: "image",
753
753
  width: 16,
754
754
  height: 16
@@ -763,9 +763,9 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
763
763
  }
764
764
  );
765
765
  }
766
- const R = (P) => {
767
- const q = r.find((S) => S.id === P);
768
- if (!q) return;
766
+ const q = (b) => {
767
+ const D = r.find((S) => S.id === b);
768
+ if (!D) return;
769
769
  const C = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
770
770
  l && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
771
771
  f,
@@ -780,14 +780,14 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
780
780
  tt,
781
781
  {
782
782
  onChange: (S) => {
783
- const x = [...n], v = r.find((j) => j.name === S);
784
- if (!v) return;
785
- const M = v.id, y = x.map((j) => j === P ? M : j);
786
- i([...y]);
783
+ const g = [...n], j = r.find((y) => y.name === S);
784
+ if (!j) return;
785
+ const M = j.id, k = g.map((y) => y === b ? M : y);
786
+ i([...k]);
787
787
  },
788
- value: q.name,
789
- options: r.filter((S) => !n.find((x) => x === S.id)).map((S) => S.name),
790
- leftAddon: O(q.images)
788
+ value: D.name,
789
+ options: r.filter((S) => !n.find((g) => g === S.id)).map((S) => S.name),
790
+ leftAddon: O(D.images)
791
791
  }
792
792
  ),
793
793
  /* @__PURE__ */ t.jsx("div", { className: Z.buttons, children: /* @__PURE__ */ t.jsx(
@@ -798,7 +798,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
798
798
  width: 20,
799
799
  height: 20,
800
800
  fill: "#C12A2A",
801
- onClick: () => i(n.filter((S) => S !== P))
801
+ onClick: () => i(n.filter((S) => S !== b))
802
802
  }
803
803
  ) })
804
804
  ] });
@@ -808,7 +808,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
808
808
  className: Z.product,
809
809
  children: C
810
810
  },
811
- P
811
+ b
812
812
  );
813
813
  };
814
814
  return /* @__PURE__ */ t.jsxs("div", { className: Z.productsBlock, children: [
@@ -818,34 +818,34 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
818
818
  K,
819
819
  {
820
820
  current: o,
821
- onChange: (P) => e == null ? void 0 : e(P)
821
+ onChange: (b) => e == null ? void 0 : e(b)
822
822
  }
823
823
  )
824
824
  ] }),
825
- B && h && /* @__PURE__ */ t.jsx(Nt, { ...h }),
825
+ B && x && /* @__PURE__ */ t.jsx(Nt, { ...x }),
826
826
  /* @__PURE__ */ t.jsxs("div", { className: Z.products, children: [
827
827
  s && /* @__PURE__ */ t.jsx("h5", { className: Z.subtitle, children: s }),
828
- n.map((P) => R(P)),
829
- k && /* @__PURE__ */ t.jsxs(
830
- it,
828
+ n.map((b) => q(b)),
829
+ $ && /* @__PURE__ */ t.jsxs(
830
+ ot,
831
831
  {
832
832
  withoutHover: !0,
833
- className: H(Z.button, {
834
- [Z.disabled]: !!(g && g <= n.length || n.length === r.length)
833
+ className: V(Z.button, {
834
+ [Z.disabled]: !!(_ && _ <= n.length || n.length === r.length)
835
835
  }),
836
836
  size: "s",
837
- disabled: !!(g && g <= n.length || n.length === r.length),
837
+ disabled: !!(_ && _ <= n.length || n.length === r.length),
838
838
  onClick: () => {
839
- const P = [...n];
840
- let q = null;
839
+ const b = [...n];
840
+ let D = null;
841
841
  if (r) {
842
842
  for (let C = 0; C < r.length; C++)
843
843
  if (!n.find((S) => S === r[C].id)) {
844
- q = r[C];
844
+ D = r[C];
845
845
  break;
846
846
  }
847
847
  }
848
- P.push((q == null ? void 0 : q.id) || r[0].id), i(P);
848
+ b.push((D == null ? void 0 : D.id) || r[0].id), i(b);
849
849
  },
850
850
  children: [
851
851
  /* @__PURE__ */ t.jsx("span", { children: "Add Option" }),
@@ -861,14 +861,14 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
861
861
  }
862
862
  )
863
863
  ] }),
864
- a !== void 0 && /* @__PURE__ */ t.jsx(xt, { items: a }),
864
+ a !== void 0 && /* @__PURE__ */ t.jsx(ft, { items: a }),
865
865
  m !== void 0 && /* @__PURE__ */ t.jsx(
866
866
  W,
867
867
  {
868
868
  label: "Auto scroll interval",
869
869
  type: "number",
870
870
  value: String(m.scrollInterval),
871
- onChange: (P) => m.setScrollInterval(Number(P)),
871
+ onChange: (b) => m.setScrollInterval(Number(b)),
872
872
  min: 0.1,
873
873
  max: 100,
874
874
  style: {
@@ -878,29 +878,29 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
878
878
  }
879
879
  )
880
880
  ] });
881
- }, Qe = "_title_fyopx_1", Ke = "_subtitle_fyopx_5", Ze = "_header_fyopx_12", ts = "_text_fyopx_13", es = "_productsBlock_fyopx_14", ss = "_top_fyopx_26", ns = "_itemsBlock_fyopx_35", is = "_typeTexts_fyopx_41", os = "_block_fyopx_48", as = "_active_fyopx_61", cs = "_products_fyopx_14", ls = "_product_fyopx_14", rs = "_button_fyopx_80", ds = "_disabled_fyopx_91", us = "_image_fyopx_95", ps = "_info_fyopx_102", ms = "_name_fyopx_114", hs = "_buttons_fyopx_118", _s = "_modal_fyopx_125", gs = "_link_fyopx_145", xs = "_modalOptions_fyopx_151", z = {
882
- title: Qe,
883
- subtitle: Ke,
884
- header: Ze,
885
- text: ts,
886
- productsBlock: es,
887
- top: ss,
888
- itemsBlock: ns,
889
- typeTexts: is,
890
- block: os,
891
- active: as,
892
- products: cs,
893
- product: ls,
894
- button: rs,
895
- disabled: ds,
896
- image: us,
897
- info: ps,
898
- name: ms,
899
- buttons: hs,
900
- modal: _s,
901
- link: gs,
902
- modalOptions: xs
903
- }, fs = _.forwardRef(
881
+ }, ts = "_title_fyopx_1", es = "_subtitle_fyopx_5", ss = "_header_fyopx_12", ns = "_text_fyopx_13", is = "_productsBlock_fyopx_14", os = "_top_fyopx_26", as = "_itemsBlock_fyopx_35", cs = "_typeTexts_fyopx_41", ls = "_block_fyopx_48", rs = "_active_fyopx_61", ds = "_products_fyopx_14", us = "_product_fyopx_14", ps = "_button_fyopx_80", ms = "_disabled_fyopx_91", hs = "_image_fyopx_95", _s = "_info_fyopx_102", gs = "_name_fyopx_114", fs = "_buttons_fyopx_118", xs = "_modal_fyopx_125", bs = "_link_fyopx_145", vs = "_modalOptions_fyopx_151", z = {
882
+ title: ts,
883
+ subtitle: es,
884
+ header: ss,
885
+ text: ns,
886
+ productsBlock: is,
887
+ top: os,
888
+ itemsBlock: as,
889
+ typeTexts: cs,
890
+ block: ls,
891
+ active: rs,
892
+ products: ds,
893
+ product: us,
894
+ button: ps,
895
+ disabled: ms,
896
+ image: hs,
897
+ info: _s,
898
+ name: gs,
899
+ buttons: fs,
900
+ modal: xs,
901
+ link: bs,
902
+ modalOptions: vs
903
+ }, js = h.forwardRef(
904
904
  (u, o) => {
905
905
  const { activeItem: e, setActiveItem: n, popupPosition: i, modalOptions: a, setIsOpenModal: c } = u;
906
906
  return /* @__PURE__ */ t.jsxs(
@@ -950,7 +950,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
950
950
  );
951
951
  if (s.type === "text")
952
952
  return /* @__PURE__ */ t.jsx(
953
- Bt,
953
+ At,
954
954
  {
955
955
  typesText: e[s.field.type],
956
956
  setTypesText: (l) => {
@@ -1041,13 +1041,13 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1041
1041
  }
1042
1042
  );
1043
1043
  }
1044
- ), bs = (u) => {
1045
- const { index: o, moveProduct: e, children: n } = u, [, i] = yt({
1044
+ ), ys = (u) => {
1045
+ const { index: o, moveProduct: e, children: n } = u, [, i] = kt({
1046
1046
  accept: "product",
1047
1047
  hover(s) {
1048
1048
  s.index !== o && (e(s.index, o), s.index = o);
1049
1049
  }
1050
- }), [{ isDragging: a }, c] = kt({
1050
+ }), [{ isDragging: a }, c] = $t({
1051
1051
  type: "product",
1052
1052
  item: { index: o },
1053
1053
  collect: (s) => ({
@@ -1062,7 +1062,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1062
1062
  children: n
1063
1063
  }
1064
1064
  );
1065
- }, Eo = (u) => {
1065
+ }, Fo = (u) => {
1066
1066
  const {
1067
1067
  isActiveItems: o,
1068
1068
  setIsActiveItems: e,
@@ -1073,59 +1073,59 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1073
1073
  subtitle: s,
1074
1074
  editable: l = !0,
1075
1075
  draggable: d = !1,
1076
- withImage: k = !1,
1076
+ withImage: $ = !1,
1077
1077
  deletable: r = !0,
1078
1078
  addable: B = !0,
1079
- itemsType: h,
1080
- itemsPlaceholder: g = "",
1079
+ itemsType: x,
1080
+ itemsPlaceholder: _ = "",
1081
1081
  itemsOptions: m,
1082
1082
  hasRangeSelector: O = !1,
1083
- rangeSelectorOptions: R,
1084
- modalOptions: P,
1085
- addableOptions: q = {}
1086
- } = u, [C, S] = _.useState(null), [x, v] = _.useState({
1083
+ rangeSelectorOptions: q,
1084
+ modalOptions: b,
1085
+ addableOptions: D = {}
1086
+ } = u, [C, S] = h.useState(null), [g, j] = h.useState({
1087
1087
  top: 0,
1088
1088
  left: 0
1089
- }), [M, y] = _.useState(null), j = _.useRef(null), [I, D] = _.useState(!1), E = (b, A) => {
1090
- const p = [...n], [T] = p.splice(b, 1);
1089
+ }), [M, k] = h.useState(null), y = h.useRef(null), [N, E] = h.useState(!1), L = (v, A) => {
1090
+ const p = [...n], [T] = p.splice(v, 1);
1091
1091
  p.splice(A, 0, T), i(p);
1092
1092
  };
1093
- _.useEffect(() => {
1094
- const b = () => {
1095
- S(null), D(!1);
1093
+ h.useEffect(() => {
1094
+ const v = () => {
1095
+ S(null), E(!1);
1096
1096
  };
1097
- return document.body.addEventListener("click", b), S(null), D(!1), () => {
1098
- S(null), D(!1), document.body.removeEventListener("click", b);
1097
+ return document.body.addEventListener("click", v), S(null), E(!1), () => {
1098
+ S(null), E(!1), document.body.removeEventListener("click", v);
1099
1099
  };
1100
- }, []), _.useEffect(() => {
1100
+ }, []), h.useEffect(() => {
1101
1101
  if (C) {
1102
- const b = [...n].map((A) => A.id === C.id ? C : A);
1103
- i(b);
1102
+ const v = [...n].map((A) => A.id === C.id ? C : A);
1103
+ i(v);
1104
1104
  }
1105
- }, [C]), _.useEffect(() => {
1106
- if (j.current && M) {
1107
- const b = j.current.getBoundingClientRect().height, A = window.innerHeight;
1105
+ }, [C]), h.useEffect(() => {
1106
+ if (y.current && M) {
1107
+ const v = y.current.getBoundingClientRect().height, A = window.innerHeight;
1108
1108
  let p = M.top;
1109
- p + b > A + window.scrollY && (p = A + window.scrollY - b - 200), p < 0 && (p = 10), v({
1109
+ p + v > A + window.scrollY && (p = A + window.scrollY - v - 200), p < 0 && (p = 10), j({
1110
1110
  top: p,
1111
1111
  left: M.left
1112
1112
  });
1113
1113
  }
1114
- }, [j.current, M]);
1115
- const U = (b, A) => {
1116
- b.stopPropagation();
1117
- const p = b.target.getBoundingClientRect();
1118
- y({
1114
+ }, [y.current, M]);
1115
+ const U = (v, A) => {
1116
+ v.stopPropagation();
1117
+ const p = v.target.getBoundingClientRect();
1118
+ k({
1119
1119
  top: p.top + window.scrollY,
1120
1120
  left: p.left - 30
1121
- }), S(A), D(!0);
1121
+ }), S(A), E(!0);
1122
1122
  };
1123
- function et(b) {
1124
- if (k)
1125
- return b ? /* @__PURE__ */ t.jsx(
1123
+ function et(v) {
1124
+ if ($)
1125
+ return v ? /* @__PURE__ */ t.jsx(
1126
1126
  "img",
1127
1127
  {
1128
- src: `https://imagedelivery.net/${b[0]}/w=1000`,
1128
+ src: `https://imagedelivery.net/${v[0]}/w=1000`,
1129
1129
  alt: "image",
1130
1130
  width: 16,
1131
1131
  height: 16
@@ -1140,7 +1140,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1140
1140
  }
1141
1141
  );
1142
1142
  }
1143
- const ot = (b, A) => {
1143
+ const at = (v, A) => {
1144
1144
  var T;
1145
1145
  const p = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
1146
1146
  d && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
@@ -1152,49 +1152,49 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1152
1152
  height: 20
1153
1153
  }
1154
1154
  ) }),
1155
- h === "select" && /* @__PURE__ */ t.jsx(
1155
+ x === "select" && /* @__PURE__ */ t.jsx(
1156
1156
  tt,
1157
1157
  {
1158
- onChange: ($) => {
1159
- const L = [...n].map((Y) => Y.id === b.id ? {
1160
- ...b,
1161
- name: $
1158
+ onChange: (w) => {
1159
+ const R = [...n].map((Y) => Y.id === v.id ? {
1160
+ ...v,
1161
+ name: w
1162
1162
  } : Y);
1163
1163
  S({
1164
- ...b,
1165
- name: $
1166
- }), i([...L]);
1164
+ ...v,
1165
+ name: w
1166
+ }), i([...R]);
1167
1167
  },
1168
- value: b.name,
1169
- options: m.filter(($) => !n.find((X) => X.name === $)),
1170
- leftAddon: et(b.images)
1168
+ value: v.name,
1169
+ options: m.filter((w) => !n.find((X) => X.name === w)),
1170
+ leftAddon: et(v.images)
1171
1171
  }
1172
1172
  ),
1173
- h === "input" && /* @__PURE__ */ t.jsx(
1173
+ x === "input" && /* @__PURE__ */ t.jsx(
1174
1174
  W,
1175
1175
  {
1176
- onChange: ($) => {
1177
- const L = [...n].map((Y) => Y.id === b.id ? {
1178
- ...b,
1179
- name: $
1176
+ onChange: (w) => {
1177
+ const R = [...n].map((Y) => Y.id === v.id ? {
1178
+ ...v,
1179
+ name: w
1180
1180
  } : Y);
1181
- i([...L]);
1181
+ i([...R]);
1182
1182
  },
1183
- value: b.name,
1184
- placeholder: g
1183
+ value: v.name,
1184
+ placeholder: _
1185
1185
  }
1186
1186
  ),
1187
- h === "image" && /* @__PURE__ */ t.jsx(
1187
+ x === "image" && /* @__PURE__ */ t.jsx(
1188
1188
  ht,
1189
1189
  {
1190
- onChange: ($) => {
1191
- const L = [...n].map((Y) => Y.id === b.id ? {
1192
- ...b,
1193
- images: $
1190
+ onChange: (w) => {
1191
+ const R = [...n].map((Y) => Y.id === v.id ? {
1192
+ ...v,
1193
+ images: w
1194
1194
  } : Y);
1195
- i([...L]);
1195
+ i([...R]);
1196
1196
  },
1197
- activeImage: (T = n.find(($) => $.id === b.id)) == null ? void 0 : T.images[0]
1197
+ activeImage: (T = n.find((w) => w.id === v.id)) == null ? void 0 : T.images[0]
1198
1198
  }
1199
1199
  ),
1200
1200
  /* @__PURE__ */ t.jsxs("div", { className: z.buttons, children: [
@@ -1205,7 +1205,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1205
1205
  hoverable: !0,
1206
1206
  width: 20,
1207
1207
  height: 20,
1208
- onClick: ($) => U($, b)
1208
+ onClick: (w) => U(w, v)
1209
1209
  }
1210
1210
  ),
1211
1211
  r && /* @__PURE__ */ t.jsx(
@@ -1216,27 +1216,27 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1216
1216
  width: 20,
1217
1217
  height: 20,
1218
1218
  fill: "#C12A2A",
1219
- onClick: () => i(n.filter(($) => $.id !== b.id))
1219
+ onClick: () => i(n.filter((w) => w.id !== v.id))
1220
1220
  }
1221
1221
  )
1222
1222
  ] })
1223
1223
  ] });
1224
1224
  return d ? /* @__PURE__ */ t.jsx(
1225
- bs,
1225
+ ys,
1226
1226
  {
1227
- product: b,
1227
+ product: v,
1228
1228
  index: A,
1229
- moveProduct: E,
1229
+ moveProduct: L,
1230
1230
  children: p
1231
1231
  },
1232
- b.id
1232
+ v.id
1233
1233
  ) : /* @__PURE__ */ t.jsx(
1234
1234
  "div",
1235
1235
  {
1236
1236
  className: z.product,
1237
1237
  children: p
1238
1238
  },
1239
- b.id
1239
+ v.id
1240
1240
  );
1241
1241
  };
1242
1242
  return /* @__PURE__ */ t.jsxs("div", { className: z.productsBlock, children: [
@@ -1246,33 +1246,33 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1246
1246
  K,
1247
1247
  {
1248
1248
  current: o,
1249
- onChange: (b) => e == null ? void 0 : e(b)
1249
+ onChange: (v) => e == null ? void 0 : e(v)
1250
1250
  }
1251
1251
  )
1252
1252
  ] }),
1253
- C && l && P && I && /* @__PURE__ */ t.jsx(
1254
- fs,
1253
+ C && l && b && N && /* @__PURE__ */ t.jsx(
1254
+ js,
1255
1255
  {
1256
- ref: j,
1256
+ ref: y,
1257
1257
  activeItem: C,
1258
1258
  setActiveItem: S,
1259
- popupPosition: x,
1260
- modalOptions: P,
1261
- setIsOpenModal: D
1259
+ popupPosition: g,
1260
+ modalOptions: b,
1261
+ setIsOpenModal: E
1262
1262
  }
1263
1263
  ),
1264
- O && R && /* @__PURE__ */ t.jsx(Nt, { ...R }),
1264
+ O && q && /* @__PURE__ */ t.jsx(Nt, { ...q }),
1265
1265
  /* @__PURE__ */ t.jsxs("div", { className: z.products, children: [
1266
1266
  s && /* @__PURE__ */ t.jsx("h5", { className: z.subtitle, children: s }),
1267
- d ? /* @__PURE__ */ t.jsx(vt, { backend: jt, children: n.map((b, A) => ot(b, A)) }) : n.map((b, A) => ot(b, A)),
1267
+ d ? /* @__PURE__ */ t.jsx(jt, { backend: yt, children: n.map((v, A) => at(v, A)) }) : n.map((v, A) => at(v, A)),
1268
1268
  B && /* @__PURE__ */ t.jsxs(
1269
- it,
1269
+ ot,
1270
1270
  {
1271
1271
  withoutHover: !0,
1272
1272
  className: z.button,
1273
1273
  size: "s",
1274
1274
  onClick: () => {
1275
- const b = [...n];
1275
+ const v = [...n];
1276
1276
  let A = null;
1277
1277
  if (m) {
1278
1278
  for (let p = 0; p < m.length; p++)
@@ -1281,19 +1281,19 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1281
1281
  break;
1282
1282
  }
1283
1283
  }
1284
- h === "select" ? b.push({
1284
+ x === "select" ? v.push({
1285
1285
  name: A || m[0],
1286
- id: ct(),
1287
- ...q
1288
- }) : h === "input" ? b.push({
1286
+ id: lt(),
1287
+ ...D
1288
+ }) : x === "input" ? v.push({
1289
1289
  name: "",
1290
- id: ct(),
1291
- ...q
1292
- }) : b.push({
1290
+ id: lt(),
1291
+ ...D
1292
+ }) : v.push({
1293
1293
  name: `Image ${n.length + 1}`,
1294
- id: ct(),
1295
- ...q
1296
- }), i(b);
1294
+ id: lt(),
1295
+ ...D
1296
+ }), i(v);
1297
1297
  },
1298
1298
  children: [
1299
1299
  /* @__PURE__ */ t.jsx("span", { children: "Add Option" }),
@@ -1309,48 +1309,50 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1309
1309
  }
1310
1310
  )
1311
1311
  ] }),
1312
- a !== void 0 && /* @__PURE__ */ t.jsx(xt, { items: a })
1312
+ a !== void 0 && /* @__PURE__ */ t.jsx(ft, { items: a })
1313
1313
  ] });
1314
- }, vs = "_title_dkxs6_1", js = "_subtitle_dkxs6_5", ys = "_header_dkxs6_12", ks = "_text_dkxs6_13", $s = "_productsBlock_dkxs6_14", Ns = "_buttonsBlock_dkxs6_15", Is = "_top_dkxs6_26", ws = "_itemsBlock_dkxs6_35", Cs = "_typeTexts_dkxs6_41", Ss = "_block_dkxs6_48", Ts = "_active_dkxs6_60", Bs = "_products_dkxs6_14", Ps = "_product_dkxs6_14", As = "_button_dkxs6_15", Os = "_image_dkxs6_90", qs = "_info_dkxs6_97", Ds = "_name_dkxs6_109", Es = "_buttons_dkxs6_15", Ls = "_modal_dkxs6_120", Rs = "_other_dkxs6_140", Ms = "_options_dkxs6_146", at = {
1315
- title: vs,
1316
- subtitle: js,
1317
- header: ys,
1318
- text: ks,
1319
- productsBlock: $s,
1320
- buttonsBlock: Ns,
1321
- top: Is,
1322
- itemsBlock: ws,
1323
- typeTexts: Cs,
1324
- block: Ss,
1325
- active: Ts,
1326
- products: Bs,
1327
- product: Ps,
1328
- button: As,
1329
- image: Os,
1330
- info: qs,
1331
- name: Ds,
1332
- buttons: Es,
1333
- modal: Ls,
1334
- other: Rs,
1335
- options: Ms
1336
- }, Hs = _.forwardRef((u, o) => {
1337
- const { activeButton: e, setActiveButton: n, popupPosition: i } = u, [a, c] = _.useState(e.typesText), [s, l] = _.useState(e.destination), [d, k] = _.useState(e.link || ""), [r, B] = _.useState(e.text || "");
1338
- return _.useEffect(() => {
1314
+ }, ks = "_title_dkxs6_1", $s = "_subtitle_dkxs6_5", ws = "_header_dkxs6_12", Ns = "_text_dkxs6_13", Is = "_productsBlock_dkxs6_14", Cs = "_buttonsBlock_dkxs6_15", Ss = "_top_dkxs6_26", Ts = "_itemsBlock_dkxs6_35", Ps = "_typeTexts_dkxs6_41", Bs = "_block_dkxs6_48", As = "_active_dkxs6_60", Os = "_products_dkxs6_14", qs = "_product_dkxs6_14", Ds = "_button_dkxs6_15", Es = "_image_dkxs6_90", Ls = "_info_dkxs6_97", Rs = "_name_dkxs6_109", Ms = "_buttons_dkxs6_15", Hs = "_modal_dkxs6_120", Fs = "_other_dkxs6_140", Vs = "_options_dkxs6_146", ct = {
1315
+ title: ks,
1316
+ subtitle: $s,
1317
+ header: ws,
1318
+ text: Ns,
1319
+ productsBlock: Is,
1320
+ buttonsBlock: Cs,
1321
+ top: Ss,
1322
+ itemsBlock: Ts,
1323
+ typeTexts: Ps,
1324
+ block: Bs,
1325
+ active: As,
1326
+ products: Os,
1327
+ product: qs,
1328
+ button: Ds,
1329
+ image: Es,
1330
+ info: Ls,
1331
+ name: Rs,
1332
+ buttons: Ms,
1333
+ modal: Hs,
1334
+ other: Fs,
1335
+ options: Vs
1336
+ }, Us = h.forwardRef((u, o) => {
1337
+ const { activeButton: e, setActiveButton: n, popupPosition: i } = u, [a, c] = h.useState(e.typesText), [s, l] = h.useState(e.destination), [d, $] = h.useState(e.page), [r, B] = h.useState(e.link || ""), [x, _] = h.useState(e.text || ""), [m, O] = h.useState(e.openInNewTab), { pages: q } = qt();
1338
+ return h.useEffect(() => {
1339
1339
  n({
1340
1340
  ...e,
1341
1341
  ...{
1342
- text: r,
1343
- link: d,
1342
+ text: x,
1343
+ link: r,
1344
1344
  destination: s,
1345
- typesText: a
1345
+ typesText: a,
1346
+ page: d,
1347
+ openInNewTab: m
1346
1348
  }
1347
1349
  });
1348
- }, [a, s, d, r]), /* @__PURE__ */ t.jsxs(
1350
+ }, [a, s, r, x, d, m]), /* @__PURE__ */ t.jsxs(
1349
1351
  "div",
1350
1352
  {
1351
- className: at.modal,
1352
- onClick: (h) => {
1353
- h.stopPropagation();
1353
+ className: ct.modal,
1354
+ onClick: (b) => {
1355
+ b.stopPropagation();
1354
1356
  },
1355
1357
  style: {
1356
1358
  top: `${i.top}px`,
@@ -1358,8 +1360,8 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1358
1360
  },
1359
1361
  ref: o,
1360
1362
  children: [
1361
- /* @__PURE__ */ t.jsxs("div", { className: at.top, children: [
1362
- /* @__PURE__ */ t.jsx("h3", { className: at.title, children: e.type }),
1363
+ /* @__PURE__ */ t.jsxs("div", { className: ct.top, children: [
1364
+ /* @__PURE__ */ t.jsx("h3", { className: ct.title, children: e.type }),
1363
1365
  /* @__PURE__ */ t.jsx(
1364
1366
  f,
1365
1367
  {
@@ -1371,13 +1373,13 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1371
1373
  }
1372
1374
  )
1373
1375
  ] }),
1374
- /* @__PURE__ */ t.jsxs("div", { className: at.options, children: [
1376
+ /* @__PURE__ */ t.jsxs("div", { className: ct.options, children: [
1375
1377
  /* @__PURE__ */ t.jsx(
1376
1378
  tt,
1377
1379
  {
1378
1380
  label: "Destination",
1379
- onChange: (h) => l(h),
1380
- options: ["Go to Page", "Open Link"],
1381
+ onChange: (b) => l(b),
1382
+ options: ["Go to Page", "Open Link"].filter((b) => b !== s),
1381
1383
  value: s
1382
1384
  }
1383
1385
  ),
@@ -1385,16 +1387,15 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1385
1387
  tt,
1386
1388
  {
1387
1389
  label: "Go to",
1388
- onChange: () => {
1389
- },
1390
- options: [],
1391
- value: "Homepage"
1390
+ onChange: (b) => $(b),
1391
+ options: q ? Object.values(q).filter((b) => b.name !== d).map((b) => b.name) : [],
1392
+ value: d
1392
1393
  }
1393
1394
  ) : /* @__PURE__ */ t.jsx(
1394
1395
  W,
1395
1396
  {
1396
- onChange: (h) => k(h),
1397
- value: d,
1397
+ onChange: (b) => B(b),
1398
+ value: r,
1398
1399
  placeholder: "https://",
1399
1400
  label: "Link"
1400
1401
  }
@@ -1402,21 +1403,22 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1402
1403
  /* @__PURE__ */ t.jsx(
1403
1404
  K,
1404
1405
  {
1405
- current: !1,
1406
- label: "Open in new tab"
1406
+ current: e.openInNewTab,
1407
+ label: "Open in new tab",
1408
+ onChange: (b) => O(b)
1407
1409
  }
1408
1410
  ),
1409
1411
  /* @__PURE__ */ t.jsx(
1410
- wt,
1412
+ Ct,
1411
1413
  {
1412
- onChange: (h) => B(h),
1413
- value: r,
1414
+ onChange: (b) => _(b),
1415
+ value: x,
1414
1416
  label: "Text",
1415
1417
  maxLength: 150
1416
1418
  }
1417
1419
  ),
1418
1420
  /* @__PURE__ */ t.jsx(
1419
- Tt,
1421
+ Bt,
1420
1422
  {
1421
1423
  typesText: a,
1422
1424
  setTypesText: c
@@ -1426,84 +1428,84 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1426
1428
  ]
1427
1429
  }
1428
1430
  );
1429
- }), Fs = "_subtitle_m8qel_1", Vs = "_header_m8qel_8", Us = "_text_m8qel_9", zs = "_productsBlock_m8qel_10", Ys = "_buttonsBlock_m8qel_11", Gs = "_top_m8qel_23", Ws = "_itemsBlock_m8qel_32", Xs = "_typeTexts_m8qel_38", Js = "_block_m8qel_45", Qs = "_active_m8qel_58", Ks = "_products_m8qel_10", Zs = "_product_m8qel_10", tn = "_button_m8qel_11", en = "_image_m8qel_88", sn = "_info_m8qel_95", nn = "_name_m8qel_107", on = "_buttons_m8qel_11", an = "_modal_m8qel_118", cn = "_other_m8qel_137", ln = "_options_m8qel_143", dt = {
1430
- subtitle: Fs,
1431
- header: Vs,
1432
- text: Us,
1433
- productsBlock: zs,
1434
- buttonsBlock: Ys,
1435
- top: Gs,
1436
- itemsBlock: Ws,
1437
- typeTexts: Xs,
1438
- block: Js,
1439
- active: Qs,
1440
- products: Ks,
1441
- product: Zs,
1442
- button: tn,
1443
- image: en,
1444
- info: sn,
1445
- name: nn,
1446
- buttons: on,
1447
- modal: an,
1448
- other: cn,
1449
- options: ln
1450
- }, rn = (u) => {
1451
- const { buttons: o, setButtons: e, deletable: n = !0, addable: i = !0 } = u, [a, c] = _.useState(null), [s, l] = _.useState({
1431
+ }), zs = "_subtitle_m8qel_1", Ys = "_header_m8qel_8", Gs = "_text_m8qel_9", Ws = "_productsBlock_m8qel_10", Xs = "_buttonsBlock_m8qel_11", Js = "_top_m8qel_23", Qs = "_itemsBlock_m8qel_32", Ks = "_typeTexts_m8qel_38", Zs = "_block_m8qel_45", tn = "_active_m8qel_58", en = "_products_m8qel_10", sn = "_product_m8qel_10", nn = "_button_m8qel_11", on = "_image_m8qel_88", an = "_info_m8qel_95", cn = "_name_m8qel_107", ln = "_buttons_m8qel_11", rn = "_modal_m8qel_118", dn = "_other_m8qel_137", un = "_options_m8qel_143", ut = {
1432
+ subtitle: zs,
1433
+ header: Ys,
1434
+ text: Gs,
1435
+ productsBlock: Ws,
1436
+ buttonsBlock: Xs,
1437
+ top: Js,
1438
+ itemsBlock: Qs,
1439
+ typeTexts: Ks,
1440
+ block: Zs,
1441
+ active: tn,
1442
+ products: en,
1443
+ product: sn,
1444
+ button: nn,
1445
+ image: on,
1446
+ info: an,
1447
+ name: cn,
1448
+ buttons: ln,
1449
+ modal: rn,
1450
+ other: dn,
1451
+ options: un
1452
+ }, pn = (u) => {
1453
+ const { buttons: o, setButtons: e, deletable: n = !0, addable: i = !0 } = u, [a, c] = h.useState(null), [s, l] = h.useState({
1452
1454
  top: 0,
1453
1455
  left: 0
1454
- }), [d, k] = _.useState(null), r = _.useRef(null);
1455
- _.useEffect(() => {
1456
- const h = () => {
1456
+ }), [d, $] = h.useState(null), r = h.useRef(null);
1457
+ h.useEffect(() => {
1458
+ const x = () => {
1457
1459
  c(null);
1458
1460
  };
1459
- return document.body.addEventListener("click", h), c(null), () => {
1460
- c(null), document.body.removeEventListener("click", h);
1461
+ return document.body.addEventListener("click", x), c(null), () => {
1462
+ c(null), document.body.removeEventListener("click", x);
1461
1463
  };
1462
- }, []), _.useEffect(() => {
1464
+ }, []), h.useEffect(() => {
1463
1465
  if (a) {
1464
- const h = [...o].map((g) => g.id === a.id ? a : g);
1465
- e(h);
1466
+ const x = [...o].map((_) => _.id === a.id ? a : _);
1467
+ e(x);
1466
1468
  }
1467
- }, [a]), _.useEffect(() => {
1469
+ }, [a]), h.useEffect(() => {
1468
1470
  if (r.current && d) {
1469
- const h = r.current.getBoundingClientRect().height, g = window.innerHeight;
1471
+ const x = r.current.getBoundingClientRect().height, _ = window.innerHeight;
1470
1472
  let m = d.top;
1471
- m + h > g + window.scrollY && (m = g + window.scrollY - h - 200), m < 0 && (m = 10), l({
1473
+ m + x > _ + window.scrollY && (m = _ + window.scrollY - x - 200), m < 0 && (m = 10), l({
1472
1474
  top: m,
1473
1475
  left: d.left
1474
1476
  });
1475
1477
  }
1476
1478
  }, [r.current, d]);
1477
- const B = (h, g) => {
1478
- h.stopPropagation();
1479
- const m = h.target.getBoundingClientRect();
1480
- k({
1479
+ const B = (x, _) => {
1480
+ x.stopPropagation();
1481
+ const m = x.target.getBoundingClientRect();
1482
+ $({
1481
1483
  top: m.top + window.scrollY,
1482
1484
  left: m.left - 30
1483
- }), c(g);
1485
+ }), c(_);
1484
1486
  };
1485
- return /* @__PURE__ */ t.jsxs("div", { className: dt.products, children: [
1486
- /* @__PURE__ */ t.jsx("h5", { className: dt.subtitle, children: "Button Type" }),
1487
- o.map((h) => /* @__PURE__ */ t.jsxs(
1487
+ return /* @__PURE__ */ t.jsxs("div", { className: ut.products, children: [
1488
+ /* @__PURE__ */ t.jsx("h5", { className: ut.subtitle, children: "Button Type" }),
1489
+ o.map((x) => /* @__PURE__ */ t.jsxs(
1488
1490
  "div",
1489
1491
  {
1490
- className: dt.product,
1492
+ className: ut.product,
1491
1493
  children: [
1492
1494
  /* @__PURE__ */ t.jsx(
1493
1495
  tt,
1494
1496
  {
1495
- onChange: (g) => {
1496
- const O = [...o].map((R) => R.id === h.id ? {
1497
- ...h,
1498
- type: g
1499
- } : R);
1497
+ onChange: (_) => {
1498
+ const O = [...o].map((q) => q.id === x.id ? {
1499
+ ...x,
1500
+ type: _
1501
+ } : q);
1500
1502
  e(O);
1501
1503
  },
1502
- value: h.type,
1504
+ value: x.type,
1503
1505
  options: ["Primary", "Secondary", "Tertiary"]
1504
1506
  }
1505
1507
  ),
1506
- /* @__PURE__ */ t.jsxs("div", { className: dt.buttons, children: [
1508
+ /* @__PURE__ */ t.jsxs("div", { className: ut.buttons, children: [
1507
1509
  /* @__PURE__ */ t.jsx(
1508
1510
  f,
1509
1511
  {
@@ -1511,8 +1513,8 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1511
1513
  hoverable: !0,
1512
1514
  width: 20,
1513
1515
  height: 20,
1514
- onClick: (g) => {
1515
- B(g, h);
1516
+ onClick: (_) => {
1517
+ B(_, x);
1516
1518
  }
1517
1519
  }
1518
1520
  ),
@@ -1522,8 +1524,8 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1522
1524
  name: "Trash",
1523
1525
  hoverable: !0,
1524
1526
  onClick: () => {
1525
- const g = o.filter((m) => m.id !== h.id);
1526
- e(g);
1527
+ const _ = o.filter((m) => m.id !== x.id);
1528
+ e(_);
1527
1529
  },
1528
1530
  width: 20,
1529
1531
  height: 20,
@@ -1533,10 +1535,10 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1533
1535
  ] })
1534
1536
  ]
1535
1537
  },
1536
- h.id
1538
+ x.id
1537
1539
  )),
1538
1540
  a && /* @__PURE__ */ t.jsx(
1539
- Hs,
1541
+ Us,
1540
1542
  {
1541
1543
  ref: r,
1542
1544
  activeButton: a,
@@ -1545,20 +1547,22 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1545
1547
  }
1546
1548
  ),
1547
1549
  i && /* @__PURE__ */ t.jsxs(
1548
- it,
1550
+ ot,
1549
1551
  {
1550
1552
  withoutHover: !0,
1551
- className: dt.button,
1553
+ className: ut.button,
1552
1554
  size: "s",
1553
1555
  onClick: () => {
1554
- const h = [...o];
1555
- h.push({
1556
+ const x = [...o];
1557
+ x.push({
1556
1558
  type: "Primary",
1557
- id: ct(),
1559
+ id: lt(),
1558
1560
  typesText: [],
1559
1561
  destination: "Go to Page",
1560
- text: "Button Name"
1561
- }), e(h);
1562
+ text: "Button Name",
1563
+ page: "home",
1564
+ openInNewTab: !0
1565
+ }), e(x);
1562
1566
  },
1563
1567
  children: [
1564
1568
  /* @__PURE__ */ t.jsx("span", { children: "Add Option" }),
@@ -1574,11 +1578,11 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1574
1578
  }
1575
1579
  )
1576
1580
  ] });
1577
- }, Lo = (u) => {
1581
+ }, Vo = (u) => {
1578
1582
  const { isActiveButtons: o, setIsActiveButtons: e, buttons: n, setButtons: i } = u;
1579
- return /* @__PURE__ */ t.jsx(t.Fragment, { children: /* @__PURE__ */ t.jsxs("div", { className: at.buttonsBlock, children: [
1580
- /* @__PURE__ */ t.jsxs("div", { className: at.top, children: [
1581
- /* @__PURE__ */ t.jsx("h3", { className: at.title, children: "Buttons" }),
1583
+ return /* @__PURE__ */ t.jsx(t.Fragment, { children: /* @__PURE__ */ t.jsxs("div", { className: ct.buttonsBlock, children: [
1584
+ /* @__PURE__ */ t.jsxs("div", { className: ct.top, children: [
1585
+ /* @__PURE__ */ t.jsx("h3", { className: ct.title, children: "Buttons" }),
1582
1586
  /* @__PURE__ */ t.jsx(
1583
1587
  K,
1584
1588
  {
@@ -1588,59 +1592,59 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1588
1592
  )
1589
1593
  ] }),
1590
1594
  /* @__PURE__ */ t.jsx(
1591
- rn,
1595
+ pn,
1592
1596
  {
1593
1597
  buttons: n,
1594
1598
  setButtons: i
1595
1599
  }
1596
1600
  )
1597
1601
  ] }) });
1598
- }, dn = "_wrapper_m18qi_1", un = "_subtitle_m18qi_7", pn = "_content_m18qi_14", mn = "_range_m18qi_22", hn = "_track_m18qi_27", _n = "_progress_m18qi_36", gn = "_dots_m18qi_46", xn = "_dot_m18qi_46", fn = "_active_m18qi_65", bn = "_input_m18qi_77", vn = "_countBlock_m18qi_91", jn = "_count_m18qi_91", yn = "_controls_m18qi_107", kn = "_button_m18qi_113", F = {
1599
- wrapper: dn,
1600
- subtitle: un,
1601
- content: pn,
1602
- range: mn,
1603
- track: hn,
1604
- progress: _n,
1605
- dots: gn,
1606
- dot: xn,
1607
- active: fn,
1608
- input: bn,
1609
- countBlock: vn,
1610
- count: jn,
1611
- controls: yn,
1612
- button: kn
1602
+ }, mn = "_wrapper_m18qi_1", hn = "_subtitle_m18qi_7", _n = "_content_m18qi_14", gn = "_range_m18qi_22", fn = "_track_m18qi_27", xn = "_progress_m18qi_36", bn = "_dots_m18qi_46", vn = "_dot_m18qi_46", jn = "_active_m18qi_65", yn = "_input_m18qi_77", kn = "_countBlock_m18qi_91", $n = "_count_m18qi_91", wn = "_controls_m18qi_107", Nn = "_button_m18qi_113", H = {
1603
+ wrapper: mn,
1604
+ subtitle: hn,
1605
+ content: _n,
1606
+ range: gn,
1607
+ track: fn,
1608
+ progress: xn,
1609
+ dots: bn,
1610
+ dot: vn,
1611
+ active: jn,
1612
+ input: yn,
1613
+ countBlock: kn,
1614
+ count: $n,
1615
+ controls: wn,
1616
+ button: Nn
1613
1617
  }, Nt = (u) => {
1614
- const { label: o, min: e = 1, max: n = 4, step: i = 1, count: a, setCount: c } = u, [s, l] = _.useState(!1), d = Array.from({ length: (n - e) / i + 1 }), k = (a - e) / (n - e) * 100, r = () => {
1618
+ const { label: o, min: e = 1, max: n = 4, step: i = 1, count: a, setCount: c } = u, [s, l] = h.useState(!1), d = Array.from({ length: (n - e) / i + 1 }), $ = (a - e) / (n - e) * 100, r = () => {
1615
1619
  a < n && c(a + i);
1616
1620
  }, B = () => {
1617
1621
  a > e && c(a - i);
1618
- }, h = (g) => {
1619
- const m = e + g * i;
1622
+ }, x = (_) => {
1623
+ const m = e + _ * i;
1620
1624
  c(m);
1621
1625
  };
1622
- return /* @__PURE__ */ t.jsxs("div", { className: F.wrapper, children: [
1623
- o && /* @__PURE__ */ t.jsx("h5", { className: F.subtitle, children: o }),
1624
- /* @__PURE__ */ t.jsxs("div", { className: F.content, children: [
1625
- /* @__PURE__ */ t.jsxs("div", { className: F.range, children: [
1626
- /* @__PURE__ */ t.jsx("div", { className: F.track }),
1626
+ return /* @__PURE__ */ t.jsxs("div", { className: H.wrapper, children: [
1627
+ o && /* @__PURE__ */ t.jsx("h5", { className: H.subtitle, children: o }),
1628
+ /* @__PURE__ */ t.jsxs("div", { className: H.content, children: [
1629
+ /* @__PURE__ */ t.jsxs("div", { className: H.range, children: [
1630
+ /* @__PURE__ */ t.jsx("div", { className: H.track }),
1627
1631
  /* @__PURE__ */ t.jsx(
1628
1632
  "div",
1629
1633
  {
1630
- className: F.progress,
1631
- style: { width: `${k}%` }
1634
+ className: H.progress,
1635
+ style: { width: `${$}%` }
1632
1636
  }
1633
1637
  ),
1634
- /* @__PURE__ */ t.jsx("div", { className: F.dots, children: d.map((g, m) => {
1638
+ /* @__PURE__ */ t.jsx("div", { className: H.dots, children: d.map((_, m) => {
1635
1639
  const O = m <= (a - e) / i;
1636
1640
  return /* @__PURE__ */ t.jsx(
1637
1641
  "button",
1638
1642
  {
1639
- onClick: () => h(m),
1640
- className: H(F.dot, {
1641
- [F.active]: O,
1642
- [F.inactive]: !O,
1643
- [F.dragging]: s
1643
+ onClick: () => x(m),
1644
+ className: V(H.dot, {
1645
+ [H.active]: O,
1646
+ [H.inactive]: !O,
1647
+ [H.dragging]: s
1644
1648
  }),
1645
1649
  "aria-label": `Set value to ${e + m * i}`
1646
1650
  },
@@ -1655,16 +1659,16 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1655
1659
  max: n,
1656
1660
  step: i,
1657
1661
  value: a,
1658
- onChange: (g) => c(Number(g.target.value)),
1662
+ onChange: (_) => c(Number(_.target.value)),
1659
1663
  onMouseDown: () => l(!0),
1660
1664
  onMouseUp: () => l(!1),
1661
1665
  onTouchStart: () => l(!0),
1662
1666
  onTouchEnd: () => l(!1),
1663
- className: F.input
1667
+ className: H.input
1664
1668
  }
1665
1669
  )
1666
1670
  ] }),
1667
- /* @__PURE__ */ t.jsxs("div", { className: F.countBlock, children: [
1671
+ /* @__PURE__ */ t.jsxs("div", { className: H.countBlock, children: [
1668
1672
  /* @__PURE__ */ t.jsx(
1669
1673
  W,
1670
1674
  {
@@ -1672,20 +1676,20 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1672
1676
  min: e,
1673
1677
  max: n,
1674
1678
  paddingless: !0,
1675
- onChange: (g) => {
1676
- const m = Number(g);
1679
+ onChange: (_) => {
1680
+ const m = Number(_);
1677
1681
  m > n ? c(n) : m < e ? c(e) : c(m);
1678
1682
  },
1679
1683
  value: String(a)
1680
1684
  }
1681
1685
  ),
1682
- /* @__PURE__ */ t.jsxs("div", { className: F.controls, children: [
1686
+ /* @__PURE__ */ t.jsxs("div", { className: H.controls, children: [
1683
1687
  /* @__PURE__ */ t.jsx(
1684
1688
  "button",
1685
1689
  {
1686
1690
  onClick: r,
1687
1691
  disabled: a >= n,
1688
- className: F.button,
1692
+ className: H.button,
1689
1693
  "aria-label": "Increment count",
1690
1694
  children: /* @__PURE__ */ t.jsx(
1691
1695
  f,
@@ -1702,7 +1706,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1702
1706
  {
1703
1707
  onClick: B,
1704
1708
  disabled: a <= e,
1705
- className: F.button,
1709
+ className: H.button,
1706
1710
  "aria-label": "Decrement count",
1707
1711
  children: /* @__PURE__ */ t.jsx(
1708
1712
  f,
@@ -1718,28 +1722,28 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1718
1722
  ] })
1719
1723
  ] })
1720
1724
  ] });
1721
- }, $n = "_title_1hw31_1", Nn = "_subtitle_1hw31_5", In = "_header_1hw31_12", wn = "_text_1hw31_13", Cn = "_productsBlock_1hw31_14", Sn = "_top_1hw31_26", Tn = "_itemsBlock_1hw31_35", Bn = "_typeTexts_1hw31_41", Pn = "_block_1hw31_48", An = "_active_1hw31_61", On = "_products_1hw31_14", qn = "_product_1hw31_14", Dn = "_button_1hw31_80", En = "_image_1hw31_91", Ln = "_info_1hw31_98", Rn = "_name_1hw31_110", Mn = "_buttons_1hw31_114", Hn = "_modal_1hw31_121", Fn = "_link_1hw31_141", Vn = "_modalOptions_1hw31_147", G = {
1722
- title: $n,
1723
- subtitle: Nn,
1724
- header: In,
1725
- text: wn,
1726
- productsBlock: Cn,
1727
- top: Sn,
1728
- itemsBlock: Tn,
1729
- typeTexts: Bn,
1730
- block: Pn,
1731
- active: An,
1732
- products: On,
1733
- product: qn,
1734
- button: Dn,
1735
- image: En,
1736
- info: Ln,
1737
- name: Rn,
1738
- buttons: Mn,
1739
- modal: Hn,
1740
- link: Fn,
1741
- modalOptions: Vn
1742
- }, Un = (u) => {
1725
+ }, In = "_title_1hw31_1", Cn = "_subtitle_1hw31_5", Sn = "_header_1hw31_12", Tn = "_text_1hw31_13", Pn = "_productsBlock_1hw31_14", Bn = "_top_1hw31_26", An = "_itemsBlock_1hw31_35", On = "_typeTexts_1hw31_41", qn = "_block_1hw31_48", Dn = "_active_1hw31_61", En = "_products_1hw31_14", Ln = "_product_1hw31_14", Rn = "_button_1hw31_80", Mn = "_image_1hw31_91", Hn = "_info_1hw31_98", Fn = "_name_1hw31_110", Vn = "_buttons_1hw31_114", Un = "_modal_1hw31_121", zn = "_link_1hw31_141", Yn = "_modalOptions_1hw31_147", G = {
1726
+ title: In,
1727
+ subtitle: Cn,
1728
+ header: Sn,
1729
+ text: Tn,
1730
+ productsBlock: Pn,
1731
+ top: Bn,
1732
+ itemsBlock: An,
1733
+ typeTexts: On,
1734
+ block: qn,
1735
+ active: Dn,
1736
+ products: En,
1737
+ product: Ln,
1738
+ button: Rn,
1739
+ image: Mn,
1740
+ info: Hn,
1741
+ name: Fn,
1742
+ buttons: Vn,
1743
+ modal: Un,
1744
+ link: zn,
1745
+ modalOptions: Yn
1746
+ }, Gn = (u) => {
1743
1747
  const { activeItem: o, setActiveItem: e, popupPosition: n, setIsOpenModal: i, itemsOptions: a } = u, c = a.find((l) => l.id === o.listingId);
1744
1748
  if (!c) return null;
1745
1749
  function s(l, d) {
@@ -1789,13 +1793,13 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1789
1793
  ]
1790
1794
  }
1791
1795
  );
1792
- }, zn = (u) => {
1793
- const { index: o, moveProduct: e, children: n } = u, [, i] = yt({
1796
+ }, Wn = (u) => {
1797
+ const { index: o, moveProduct: e, children: n } = u, [, i] = kt({
1794
1798
  accept: "product",
1795
1799
  hover(s) {
1796
1800
  s.index !== o && (e(s.index, o), s.index = o);
1797
1801
  }
1798
- }), [{ isDragging: a }, c] = kt({
1802
+ }), [{ isDragging: a }, c] = $t({
1799
1803
  type: "product",
1800
1804
  item: { index: o },
1801
1805
  collect: (s) => ({
@@ -1810,7 +1814,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1810
1814
  children: n
1811
1815
  }
1812
1816
  );
1813
- }, Ro = (u) => {
1817
+ }, Uo = (u) => {
1814
1818
  const {
1815
1819
  isActiveItems: o,
1816
1820
  setIsActiveItems: e,
@@ -1821,46 +1825,46 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1821
1825
  subtitle: s,
1822
1826
  editable: l = !0,
1823
1827
  draggable: d = !1,
1824
- withImage: k = !1,
1828
+ withImage: $ = !1,
1825
1829
  deletable: r = !0,
1826
1830
  addable: B = !0,
1827
- itemsType: h,
1828
- itemsOptions: g
1829
- } = u, [m, O] = _.useState(null), [R, P] = _.useState({
1831
+ itemsType: x,
1832
+ itemsOptions: _
1833
+ } = u, [m, O] = h.useState(null), [q, b] = h.useState({
1830
1834
  top: 0,
1831
1835
  left: 0
1832
- }), [q, C] = _.useState(!1), S = (y, j) => {
1833
- const I = [...n], [D] = I.splice(y, 1);
1834
- I.splice(j, 0, D), i(I);
1836
+ }), [D, C] = h.useState(!1), S = (k, y) => {
1837
+ const N = [...n], [E] = N.splice(k, 1);
1838
+ N.splice(y, 0, E), i(N);
1835
1839
  };
1836
- _.useEffect(() => {
1837
- const y = () => {
1840
+ h.useEffect(() => {
1841
+ const k = () => {
1838
1842
  O(null), C(!1);
1839
1843
  };
1840
- return document.body.addEventListener("click", y), O(null), C(!1), () => {
1841
- O(null), C(!1), document.body.removeEventListener("click", y);
1844
+ return document.body.addEventListener("click", k), O(null), C(!1), () => {
1845
+ O(null), C(!1), document.body.removeEventListener("click", k);
1842
1846
  };
1843
- }, []), _.useEffect(() => {
1847
+ }, []), h.useEffect(() => {
1844
1848
  if (m) {
1845
- const y = [...n].map((j) => j.listingId === m.listingId ? m : j);
1846
- i(y);
1849
+ const k = [...n].map((y) => y.listingId === m.listingId ? m : y);
1850
+ i(k);
1847
1851
  }
1848
1852
  }, [m]);
1849
- const x = (y, j) => {
1850
- y.stopPropagation();
1851
- const I = y.target.getBoundingClientRect(), D = 100, E = window.innerHeight;
1852
- let U = I.top + window.scrollY;
1853
- U + D > E && (U = E - D - 20), C(!0), P({
1853
+ const g = (k, y) => {
1854
+ k.stopPropagation();
1855
+ const N = k.target.getBoundingClientRect(), E = 100, L = window.innerHeight;
1856
+ let U = N.top + window.scrollY;
1857
+ U + E > L && (U = L - E - 20), C(!0), b({
1854
1858
  top: U - 80,
1855
- left: I.left - 30
1856
- }), O(j);
1859
+ left: N.left - 30
1860
+ }), O(y);
1857
1861
  };
1858
- function v(y) {
1859
- if (k)
1860
- return y ? /* @__PURE__ */ t.jsx(
1862
+ function j(k) {
1863
+ if ($)
1864
+ return k ? /* @__PURE__ */ t.jsx(
1861
1865
  "img",
1862
1866
  {
1863
- src: `https://imagedelivery.net/${y}/w=1000`,
1867
+ src: `https://imagedelivery.net/${k}/w=1000`,
1864
1868
  alt: "image",
1865
1869
  width: 16,
1866
1870
  height: 16
@@ -1875,10 +1879,10 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1875
1879
  }
1876
1880
  );
1877
1881
  }
1878
- const M = (y, j) => {
1879
- const I = g.find((E) => y.listingId === E.id);
1880
- if (!I) return null;
1881
- const D = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
1882
+ const M = (k, y) => {
1883
+ const N = _.find((L) => k.listingId === L.id);
1884
+ if (!N) return null;
1885
+ const E = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
1882
1886
  d && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
1883
1887
  f,
1884
1888
  {
@@ -1887,28 +1891,28 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1887
1891
  width: 20,
1888
1892
  height: 20
1889
1893
  }
1890
- ) }, j),
1891
- h === "select" && /* @__PURE__ */ t.jsx(
1894
+ ) }, y),
1895
+ x === "select" && /* @__PURE__ */ t.jsx(
1892
1896
  tt,
1893
1897
  {
1894
- onChange: (E) => {
1895
- const U = [...n], et = g.find((A) => A.productData.name === E);
1898
+ onChange: (L) => {
1899
+ const U = [...n], et = _.find((A) => A.productData.name === L);
1896
1900
  if (!et) return;
1897
- const ot = {
1901
+ const at = {
1898
1902
  listingId: et.id,
1899
1903
  image: et.productData.images.length > 0 ? et.productData.images[0].cfId : ""
1900
- }, b = U.map((A) => A.listingId === y.listingId ? ot : A);
1901
- O(ot), i([...b]);
1904
+ }, v = U.map((A) => A.listingId === k.listingId ? at : A);
1905
+ O(at), i([...v]);
1902
1906
  },
1903
- value: I.productData.name,
1907
+ value: N.productData.name,
1904
1908
  options: [
1905
- ...g.filter((E) => !n.find((U) => U.listingId === E.id)).map((E) => E.productData.name)
1909
+ ..._.filter((L) => !n.find((U) => U.listingId === L.id)).map((L) => L.productData.name)
1906
1910
  ],
1907
- leftAddon: v(
1908
- y.image || I.productData.images.length > 0 && I.productData.images[0].cfId || ""
1911
+ leftAddon: j(
1912
+ k.image || N.productData.images.length > 0 && N.productData.images[0].cfId || ""
1909
1913
  )
1910
1914
  },
1911
- j
1915
+ y
1912
1916
  ),
1913
1917
  /* @__PURE__ */ t.jsxs("div", { className: G.buttons, children: [
1914
1918
  l && /* @__PURE__ */ t.jsx(
@@ -1918,7 +1922,7 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1918
1922
  hoverable: !0,
1919
1923
  width: 20,
1920
1924
  height: 20,
1921
- onClick: (E) => x(E, y)
1925
+ onClick: (L) => g(L, k)
1922
1926
  }
1923
1927
  ),
1924
1928
  r && /* @__PURE__ */ t.jsx(
@@ -1929,27 +1933,27 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1929
1933
  width: 20,
1930
1934
  height: 20,
1931
1935
  fill: "#C12A2A",
1932
- onClick: () => i(n.filter((E) => E !== y))
1936
+ onClick: () => i(n.filter((L) => L !== k))
1933
1937
  }
1934
1938
  )
1935
1939
  ] })
1936
1940
  ] });
1937
1941
  return d ? /* @__PURE__ */ t.jsx(
1938
- zn,
1942
+ Wn,
1939
1943
  {
1940
- product: y,
1941
- index: j,
1944
+ product: k,
1945
+ index: y,
1942
1946
  moveProduct: S,
1943
- children: D
1947
+ children: E
1944
1948
  },
1945
- y.listingId
1949
+ k.listingId
1946
1950
  ) : /* @__PURE__ */ t.jsx(
1947
1951
  "div",
1948
1952
  {
1949
1953
  className: G.product,
1950
- children: D
1954
+ children: E
1951
1955
  },
1952
- y.listingId
1956
+ k.listingId
1953
1957
  );
1954
1958
  };
1955
1959
  return /* @__PURE__ */ t.jsxs("div", { className: G.productsBlock, children: [
@@ -1959,42 +1963,42 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
1959
1963
  K,
1960
1964
  {
1961
1965
  current: o,
1962
- onChange: (y) => e == null ? void 0 : e(y)
1966
+ onChange: (k) => e == null ? void 0 : e(k)
1963
1967
  }
1964
1968
  )
1965
1969
  ] }),
1966
- q && m && /* @__PURE__ */ t.jsx(
1967
- Un,
1970
+ D && m && /* @__PURE__ */ t.jsx(
1971
+ Gn,
1968
1972
  {
1969
1973
  activeItem: m,
1970
1974
  setActiveItem: O,
1971
1975
  setIsOpenModal: C,
1972
- popupPosition: R,
1973
- itemsOptions: g
1976
+ popupPosition: q,
1977
+ itemsOptions: _
1974
1978
  }
1975
1979
  ),
1976
1980
  /* @__PURE__ */ t.jsxs("div", { className: G.products, children: [
1977
1981
  s && /* @__PURE__ */ t.jsx("h5", { className: G.subtitle, children: s }),
1978
- d ? /* @__PURE__ */ t.jsx(vt, { backend: jt, children: n.map((y, j) => M(y, j)) }) : n.map((y, j) => M(y, j)),
1982
+ d ? /* @__PURE__ */ t.jsx(jt, { backend: yt, children: n.map((k, y) => M(k, y)) }) : n.map((k, y) => M(k, y)),
1979
1983
  B && /* @__PURE__ */ t.jsxs(
1980
- it,
1984
+ ot,
1981
1985
  {
1982
1986
  withoutHover: !0,
1983
1987
  className: G.button,
1984
1988
  size: "s",
1985
1989
  onClick: () => {
1986
- const y = [...n];
1987
- for (let j = 0; j < g.length; j++)
1988
- if (!n.find((I) => I.listingId === g[j].id)) {
1989
- y.push({
1990
- listingId: g[j].id,
1991
- image: g[j].productData.images.length > 0 ? g[j].productData.images[0].cfId : ""
1990
+ const k = [...n];
1991
+ for (let y = 0; y < _.length; y++)
1992
+ if (!n.find((N) => N.listingId === _[y].id)) {
1993
+ k.push({
1994
+ listingId: _[y].id,
1995
+ image: _[y].productData.images.length > 0 ? _[y].productData.images[0].cfId : ""
1992
1996
  });
1993
1997
  break;
1994
1998
  }
1995
- i(y);
1999
+ i(k);
1996
2000
  },
1997
- disabled: n.length === g.length,
2001
+ disabled: n.length === _.length,
1998
2002
  children: [
1999
2003
  /* @__PURE__ */ t.jsx("span", { children: "Add Option" }),
2000
2004
  /* @__PURE__ */ t.jsx(
@@ -2009,116 +2013,116 @@ const Ot = "_wrapper_9rr5j_2", qt = "_alignmentBlock_9rr5j_8", Dt = "_title_9rr5
2009
2013
  }
2010
2014
  )
2011
2015
  ] }),
2012
- a !== void 0 && /* @__PURE__ */ t.jsx(xt, { items: a })
2016
+ a !== void 0 && /* @__PURE__ */ t.jsx(ft, { items: a })
2013
2017
  ] });
2014
- }, Yn = "_options_1w11v_1", Gn = "_price_1w11v_12", Wn = "_oldPrice_1w11v_19", Xn = "_newPrice_1w11v_27", Jn = "_animate_1w11v_34", Qn = "_appearAndBounce_1w11v_1", Kn = "_meta_1w11v_52", Zn = "_info_1w11v_58", ti = "_infoRight_1w11v_66", ei = "_buttons_1w11v_73", si = "_variants_1w11v_80", ni = "_variant_1w11v_80", ii = "_stock_1w11v_97", oi = "_variantInfo_1w11v_104", ai = "_quantity_1w11v_110", ci = "_count_1w11v_117", li = "_focused_1w11v_134", ri = "_button_1w11v_73", di = "_activeVariant_1w11v_160", ui = "_chargeTypes_1w11v_164", pi = "_charge_1w11v_164", mi = "_chargeActive_1w11v_185", hi = "_title_1w11v_190", w = {
2015
- options: Yn,
2016
- price: Gn,
2017
- oldPrice: Wn,
2018
- newPrice: Xn,
2019
- animate: Jn,
2020
- appearAndBounce: Qn,
2021
- meta: Kn,
2022
- info: Zn,
2023
- infoRight: ti,
2024
- buttons: ei,
2025
- variants: si,
2026
- variant: ni,
2027
- stock: ii,
2028
- variantInfo: oi,
2029
- quantity: ai,
2030
- count: ci,
2031
- focused: li,
2032
- button: ri,
2033
- activeVariant: di,
2034
- chargeTypes: ui,
2035
- charge: pi,
2036
- chargeActive: mi,
2037
- title: hi
2018
+ }, Xn = "_options_1w11v_1", Jn = "_price_1w11v_12", Qn = "_oldPrice_1w11v_19", Kn = "_newPrice_1w11v_27", Zn = "_animate_1w11v_34", ti = "_appearAndBounce_1w11v_1", ei = "_meta_1w11v_52", si = "_info_1w11v_58", ni = "_infoRight_1w11v_66", ii = "_buttons_1w11v_73", oi = "_variants_1w11v_80", ai = "_variant_1w11v_80", ci = "_stock_1w11v_97", li = "_variantInfo_1w11v_104", ri = "_quantity_1w11v_110", di = "_count_1w11v_117", ui = "_focused_1w11v_134", pi = "_button_1w11v_73", mi = "_activeVariant_1w11v_160", hi = "_chargeTypes_1w11v_164", _i = "_charge_1w11v_164", gi = "_chargeActive_1w11v_185", fi = "_title_1w11v_190", I = {
2019
+ options: Xn,
2020
+ price: Jn,
2021
+ oldPrice: Qn,
2022
+ newPrice: Kn,
2023
+ animate: Zn,
2024
+ appearAndBounce: ti,
2025
+ meta: ei,
2026
+ info: si,
2027
+ infoRight: ni,
2028
+ buttons: ii,
2029
+ variants: oi,
2030
+ variant: ai,
2031
+ stock: ci,
2032
+ variantInfo: li,
2033
+ quantity: ri,
2034
+ count: di,
2035
+ focused: ui,
2036
+ button: pi,
2037
+ activeVariant: mi,
2038
+ chargeTypes: hi,
2039
+ charge: _i,
2040
+ chargeActive: gi,
2041
+ title: fi
2038
2042
  };
2039
- var Pt = /* @__PURE__ */ ((u) => (u.ONE_TIME = "One-Time", u.RECURRING = "Subscribe & Save", u))(Pt || {});
2040
- const Mo = (u) => {
2043
+ var Ot = /* @__PURE__ */ ((u) => (u.ONE_TIME = "One-Time", u.RECURRING = "Subscribe & Save", u))(Ot || {});
2044
+ const zo = (u) => {
2041
2045
  var C, S;
2042
- const { variants: o } = u, [e, n] = _.useState(o[0]), [i, a] = _.useState(e.chargeTypes[0]), c = gt(), [s, l] = _.useState(1), [d, k] = _.useState(!1), { reset: r, addProductToCart: B, getProducts: h } = $t(), [g, m] = _.useState(!1);
2043
- _.useEffect(() => {
2046
+ const { variants: o } = u, [e, n] = h.useState(o[0]), [i, a] = h.useState(e.chargeTypes[0]), c = gt(), [s, l] = h.useState(1), [d, $] = h.useState(!1), { reset: r, addProductToCart: B, getProducts: x } = wt(), [_, m] = h.useState(!1);
2047
+ h.useEffect(() => {
2044
2048
  m(!0);
2045
- const x = setTimeout(() => m(!1), 600);
2046
- return () => clearTimeout(x);
2049
+ const g = setTimeout(() => m(!1), 600);
2050
+ return () => clearTimeout(g);
2047
2051
  }, [s]);
2048
2052
  async function O() {
2049
- await h(), await B({
2053
+ await x(), await B({
2050
2054
  productId: u.id,
2051
2055
  productVariantId: e.id,
2052
2056
  quantity: s
2053
2057
  });
2054
2058
  }
2055
- function R() {
2059
+ function q() {
2056
2060
  r(), O(), c("/checkout");
2057
2061
  }
2058
- function P(x) {
2059
- if (x >= 864e5) {
2060
- const I = Math.floor(x / 864e5);
2061
- return `${I} ${I === 1 ? "day" : "days"}`;
2062
- } else if (x >= 36e5) {
2063
- const I = Math.floor(x / 36e5);
2064
- return `${I} ${I === 1 ? "hour" : "hours"}`;
2065
- } else if (x >= 6e4) {
2066
- const I = Math.floor(x / 6e4);
2067
- return `${I} ${I === 1 ? "minute" : "minutes"}`;
2062
+ function b(g) {
2063
+ if (g >= 864e5) {
2064
+ const N = Math.floor(g / 864e5);
2065
+ return `${N} ${N === 1 ? "day" : "days"}`;
2066
+ } else if (g >= 36e5) {
2067
+ const N = Math.floor(g / 36e5);
2068
+ return `${N} ${N === 1 ? "hour" : "hours"}`;
2069
+ } else if (g >= 6e4) {
2070
+ const N = Math.floor(g / 6e4);
2071
+ return `${N} ${N === 1 ? "minute" : "minutes"}`;
2068
2072
  } else {
2069
- const I = Math.floor(x / 1e3);
2070
- return `${I} ${I === 1 ? "second" : "seconds"}`;
2073
+ const N = Math.floor(g / 1e3);
2074
+ return `${N} ${N === 1 ? "second" : "seconds"}`;
2071
2075
  }
2072
2076
  }
2073
- function q(x, v) {
2074
- return x.length > v ? x.slice(0, v) + "..." : x;
2077
+ function D(g, j) {
2078
+ return g.length > j ? g.slice(0, j) + "..." : g;
2075
2079
  }
2076
- return /* @__PURE__ */ t.jsxs("div", { className: w.options, children: [
2077
- e.chargeTypes.length > 1 && /* @__PURE__ */ t.jsx("div", { className: w.chargeTypes, children: e.chargeTypes.map((x) => /* @__PURE__ */ t.jsx(
2080
+ return /* @__PURE__ */ t.jsxs("div", { className: I.options, children: [
2081
+ e.chargeTypes.length > 1 && /* @__PURE__ */ t.jsx("div", { className: I.chargeTypes, children: e.chargeTypes.map((g) => /* @__PURE__ */ t.jsx(
2078
2082
  "div",
2079
2083
  {
2080
- className: H(w.charge, {
2081
- [w.chargeActive]: i === x
2084
+ className: V(I.charge, {
2085
+ [I.chargeActive]: i === g
2082
2086
  }),
2083
- onClick: () => a(x),
2084
- children: Pt[x]
2087
+ onClick: () => a(g),
2088
+ children: Ot[g]
2085
2089
  },
2086
- x
2090
+ g
2087
2091
  )) }),
2088
- /* @__PURE__ */ t.jsx("div", { className: w.variants, children: o.map((x) => {
2089
- var v;
2092
+ /* @__PURE__ */ t.jsx("div", { className: I.variants, children: o.map((g) => {
2093
+ var j;
2090
2094
  return /* @__PURE__ */ t.jsxs(
2091
2095
  "div",
2092
2096
  {
2093
- className: H(w.variant, {
2094
- [w.activeVariant]: e.id === x.id
2097
+ className: V(I.variant, {
2098
+ [I.activeVariant]: e.id === g.id
2095
2099
  }),
2096
- onClick: () => n(x),
2100
+ onClick: () => n(g),
2097
2101
  children: [
2098
- /* @__PURE__ */ t.jsxs("div", { className: w.variantInfo, children: [
2099
- /* @__PURE__ */ t.jsx("span", { className: w.title, children: q(x.name, 15) }),
2102
+ /* @__PURE__ */ t.jsxs("div", { className: I.variantInfo, children: [
2103
+ /* @__PURE__ */ t.jsx("span", { className: I.title, children: D(g.name, 15) }),
2100
2104
  /* @__PURE__ */ t.jsxs("span", { children: [
2101
2105
  "$",
2102
- i === "ONE_TIME" ? x.price.amount : x.subscriptionSettings ? x.subscriptionSettings.price.amount : "Price Not Found"
2106
+ i === "ONE_TIME" ? g.price.amount : g.subscriptionSettings ? g.subscriptionSettings.price.amount : "Price Not Found"
2103
2107
  ] })
2104
2108
  ] }),
2105
- /* @__PURE__ */ t.jsx("div", { children: i === "ONE_TIME" && /* @__PURE__ */ t.jsxs("span", { className: w.stock, children: [
2106
- ((v = x.quantity.restrictions) == null ? void 0 : v.max) || x.quantity.available || 0,
2109
+ /* @__PURE__ */ t.jsx("div", { children: i === "ONE_TIME" && /* @__PURE__ */ t.jsxs("span", { className: I.stock, children: [
2110
+ ((j = g.quantity.restrictions) == null ? void 0 : j.max) || g.quantity.available || 0,
2107
2111
  " in stock"
2108
2112
  ] }) })
2109
2113
  ]
2110
2114
  },
2111
- x.id
2115
+ g.id
2112
2116
  );
2113
2117
  }) }),
2114
- i === "ONE_TIME" && /* @__PURE__ */ t.jsxs("div", { className: w.quantity, children: [
2118
+ i === "ONE_TIME" && /* @__PURE__ */ t.jsxs("div", { className: I.quantity, children: [
2115
2119
  /* @__PURE__ */ t.jsx(
2116
2120
  "button",
2117
2121
  {
2118
2122
  onClick: () => {
2119
- s > 1 ? l((x) => x - 1) : l(1);
2123
+ s > 1 ? l((g) => g - 1) : l(1);
2120
2124
  },
2121
- className: w.button,
2125
+ className: I.button,
2122
2126
  disabled: e.quantity.restrictions && s <= e.quantity.restrictions.min,
2123
2127
  children: /* @__PURE__ */ t.jsx(f, { name: "Minus" })
2124
2128
  }
@@ -2126,17 +2130,17 @@ const Mo = (u) => {
2126
2130
  /* @__PURE__ */ t.jsx(
2127
2131
  "label",
2128
2132
  {
2129
- className: H(w.count, {
2130
- [w.focused]: d
2133
+ className: V(I.count, {
2134
+ [I.focused]: d
2131
2135
  }),
2132
- onFocus: () => k(!0),
2133
- onBlur: () => k(!1),
2136
+ onFocus: () => $(!0),
2137
+ onBlur: () => $(!1),
2134
2138
  children: /* @__PURE__ */ t.jsx(
2135
2139
  W,
2136
2140
  {
2137
2141
  type: "number",
2138
2142
  value: String(s),
2139
- onChange: (x) => l(Number(x)),
2143
+ onChange: (g) => l(Number(g)),
2140
2144
  max: ((C = e.quantity.restrictions) == null ? void 0 : C.max) || e.quantity.available || 1 / 0,
2141
2145
  min: ((S = e.quantity.restrictions) == null ? void 0 : S.min) || 0,
2142
2146
  style: {
@@ -2152,18 +2156,18 @@ const Mo = (u) => {
2152
2156
  "button",
2153
2157
  {
2154
2158
  onClick: () => {
2155
- l((x) => x + 1);
2159
+ l((g) => g + 1);
2156
2160
  },
2157
- className: w.button,
2161
+ className: I.button,
2158
2162
  disabled: !!(e.quantity.restrictions && s >= e.quantity.restrictions.max || e.quantity.available && s >= e.quantity.available),
2159
2163
  children: /* @__PURE__ */ t.jsx(f, { name: "Plus" })
2160
2164
  }
2161
2165
  )
2162
2166
  ] }),
2163
- /* @__PURE__ */ t.jsxs("div", { className: w.meta, children: [
2164
- /* @__PURE__ */ t.jsxs("div", { className: w.info, children: [
2167
+ /* @__PURE__ */ t.jsxs("div", { className: I.meta, children: [
2168
+ /* @__PURE__ */ t.jsxs("div", { className: I.info, children: [
2165
2169
  /* @__PURE__ */ t.jsx("span", { children: "Delivery" }),
2166
- /* @__PURE__ */ t.jsxs("div", { className: w.infoRight, children: [
2170
+ /* @__PURE__ */ t.jsxs("div", { className: I.infoRight, children: [
2167
2171
  /* @__PURE__ */ t.jsx(
2168
2172
  f,
2169
2173
  {
@@ -2173,49 +2177,49 @@ const Mo = (u) => {
2173
2177
  height: 20
2174
2178
  }
2175
2179
  ),
2176
- /* @__PURE__ */ t.jsx("span", { children: !e.deliveryTime || e.deliveryTime === 0 ? "Instant" : P(e.deliveryTime) })
2180
+ /* @__PURE__ */ t.jsx("span", { children: !e.deliveryTime || e.deliveryTime === 0 ? "Instant" : b(e.deliveryTime) })
2177
2181
  ] })
2178
2182
  ] }),
2179
- /* @__PURE__ */ t.jsxs("div", { className: w.info, children: [
2183
+ /* @__PURE__ */ t.jsxs("div", { className: I.info, children: [
2180
2184
  /* @__PURE__ */ t.jsx("span", { children: "Price" }),
2181
- /* @__PURE__ */ t.jsx("div", { className: w.infoRight, children: i === "ONE_TIME" ? e.compareAtPrice && (e.compareAtPrice.amount || 0) - (e.price.amount || 0) > 0 ? /* @__PURE__ */ t.jsxs("div", { className: w.price, children: [
2182
- /* @__PURE__ */ t.jsxs("span", { className: H(w.newPrice, { [w.animate]: g }), children: [
2185
+ /* @__PURE__ */ t.jsx("div", { className: I.infoRight, children: i === "ONE_TIME" ? e.compareAtPrice && (e.compareAtPrice.amount || 0) - (e.price.amount || 0) > 0 ? /* @__PURE__ */ t.jsxs("div", { className: I.price, children: [
2186
+ /* @__PURE__ */ t.jsxs("span", { className: V(I.newPrice, { [I.animate]: _ }), children: [
2183
2187
  "$ ",
2184
2188
  (e.price.amount || 0) * s
2185
2189
  ] }),
2186
- /* @__PURE__ */ t.jsxs("span", { className: w.oldPrice, children: [
2190
+ /* @__PURE__ */ t.jsxs("span", { className: I.oldPrice, children: [
2187
2191
  "$ ",
2188
2192
  (e.compareAtPrice.amount || 0) * s
2189
2193
  ] })
2190
- ] }) : /* @__PURE__ */ t.jsxs("span", { className: H(w.newPrice, { [w.animate]: g }), children: [
2194
+ ] }) : /* @__PURE__ */ t.jsxs("span", { className: V(I.newPrice, { [I.animate]: _ }), children: [
2191
2195
  "$ ",
2192
2196
  (e.price.amount || 0) * s
2193
- ] }) : e.subscriptionSettings && e.subscriptionSettings.compareAtPrice && (e.subscriptionSettings.compareAtPrice.amount || 0) - (e.subscriptionSettings.price.amount || 0) > 0 ? /* @__PURE__ */ t.jsxs("div", { className: w.price, children: [
2194
- /* @__PURE__ */ t.jsxs("span", { className: H(w.newPrice, { [w.animate]: g }), children: [
2197
+ ] }) : e.subscriptionSettings && e.subscriptionSettings.compareAtPrice && (e.subscriptionSettings.compareAtPrice.amount || 0) - (e.subscriptionSettings.price.amount || 0) > 0 ? /* @__PURE__ */ t.jsxs("div", { className: I.price, children: [
2198
+ /* @__PURE__ */ t.jsxs("span", { className: V(I.newPrice, { [I.animate]: _ }), children: [
2195
2199
  "$ ",
2196
2200
  e.subscriptionSettings.price.amount || 0
2197
2201
  ] }),
2198
- /* @__PURE__ */ t.jsxs("span", { className: w.oldPrice, children: [
2202
+ /* @__PURE__ */ t.jsxs("span", { className: I.oldPrice, children: [
2199
2203
  "$ ",
2200
2204
  e.subscriptionSettings.compareAtPrice.amount || 0
2201
2205
  ] })
2202
- ] }) : e.subscriptionSettings && /* @__PURE__ */ t.jsxs("span", { className: H(w.newPrice, { [w.animate]: g }), children: [
2206
+ ] }) : e.subscriptionSettings && /* @__PURE__ */ t.jsxs("span", { className: V(I.newPrice, { [I.animate]: _ }), children: [
2203
2207
  "$ ",
2204
2208
  e.subscriptionSettings.price.amount || 0
2205
2209
  ] }) })
2206
2210
  ] })
2207
2211
  ] }),
2208
- /* @__PURE__ */ t.jsxs("div", { className: w.buttons, children: [
2212
+ /* @__PURE__ */ t.jsxs("div", { className: I.buttons, children: [
2209
2213
  /* @__PURE__ */ t.jsx(
2210
- it,
2214
+ ot,
2211
2215
  {
2212
2216
  type: "Primary",
2213
- onClick: () => R(),
2217
+ onClick: () => q(),
2214
2218
  children: /* @__PURE__ */ t.jsx("span", { children: i === "ONE_TIME" ? "Buy Now" : "Subscribe Now" })
2215
2219
  }
2216
2220
  ),
2217
2221
  i === "ONE_TIME" && /* @__PURE__ */ t.jsx(
2218
- it,
2222
+ ot,
2219
2223
  {
2220
2224
  type: "Secondary",
2221
2225
  onClick: () => O(),
@@ -2224,59 +2228,65 @@ const Mo = (u) => {
2224
2228
  )
2225
2229
  ] })
2226
2230
  ] });
2227
- }, _i = "_button_1x9be_1", gi = "_login_1x9be_14", xi = "_signUp_1x9be_18", fi = "_buttons_1x9be_23", bi = "_modal_1x9be_32", vi = "_info_1x9be_48", ji = "_top_1x9be_55", yi = "_title_1x9be_66", ki = "_clear_1x9be_72", $i = "_activeClear_1x9be_79", Ni = "_count_1x9be_83", Ii = "_cart_1x9be_98", wi = "_empty_1x9be_106", Ci = "_product_1x9be_132", Si = "_products_1x9be_141", Ti = "_image_1x9be_149", Bi = "_productInfo_1x9be_155", Pi = "_content_1x9be_162", Ai = "_name_1x9be_168", Oi = "_price_1x9be_174", qi = "_productButtons_1x9be_180", Di = "_productButton_1x9be_180", Ei = "_productCount_1x9be_200", Li = "_bottom_1x9be_216", Ri = "_subtotal_1x9be_224", Mi = "_block_1x9be_232", Hi = "_shoppingCount_1x9be_239", Fi = "_total_1x9be_259", Vi = "_link_1x9be_265", Ui = "_userInfo_1x9be_272", N = {
2228
- button: _i,
2229
- login: gi,
2230
- signUp: xi,
2231
- buttons: fi,
2232
- modal: bi,
2233
- info: vi,
2234
- top: ji,
2235
- title: yi,
2236
- clear: ki,
2237
- activeClear: $i,
2238
- count: Ni,
2239
- cart: Ii,
2240
- empty: wi,
2241
- product: Ci,
2242
- products: Si,
2243
- image: Ti,
2244
- productInfo: Bi,
2245
- content: Pi,
2246
- name: Ai,
2247
- price: Oi,
2248
- productButtons: qi,
2249
- productButton: Di,
2250
- productCount: Ei,
2251
- bottom: Li,
2252
- subtotal: Ri,
2253
- block: Mi,
2254
- shoppingCount: Hi,
2255
- total: Fi,
2256
- link: Vi,
2257
- userInfo: Ui
2258
- }, zi = "_button_15mga_1", Yi = "_primary_15mga_19", Gi = "_secondary_15mga_24", Wi = "_tertiary_15mga_29", Xi = "_content_15mga_34", ut = {
2259
- button: zi,
2260
- primary: Yi,
2261
- secondary: Gi,
2262
- tertiary: Wi,
2263
- content: Xi
2264
- }, Ji = (u) => {
2265
- const { children: o, onClick: e, style: n, className: i, disabled: a = !1, type: c = "Primary" } = u;
2231
+ }, xi = "_button_1861a_1", bi = "_login_1861a_14", vi = "_signUp_1861a_18", ji = "_buttons_1861a_23", yi = "_modal_1861a_32", ki = "_info_1861a_60", $i = "_top_1861a_67", wi = "_title_1861a_78", Ni = "_clear_1861a_84", Ii = "_activeClear_1861a_91", Ci = "_count_1861a_95", Si = "_cart_1861a_110", Ti = "_empty_1861a_118", Pi = "_product_1861a_144", Bi = "_products_1861a_153", Ai = "_image_1861a_161", Oi = "_productInfo_1861a_167", qi = "_content_1861a_174", Di = "_name_1861a_180", Ei = "_price_1861a_186", Li = "_productButtons_1861a_192", Ri = "_productButton_1861a_192", Mi = "_productCount_1861a_212", Hi = "_bottom_1861a_228", Fi = "_subtotal_1861a_236", Vi = "_block_1861a_244", Ui = "_shoppingCount_1861a_251", zi = "_total_1861a_271", Yi = "_link_1861a_277", Gi = "_userInfo_1861a_284", P = {
2232
+ button: xi,
2233
+ login: bi,
2234
+ signUp: vi,
2235
+ buttons: ji,
2236
+ modal: yi,
2237
+ info: ki,
2238
+ top: $i,
2239
+ title: wi,
2240
+ clear: Ni,
2241
+ activeClear: Ii,
2242
+ count: Ci,
2243
+ cart: Si,
2244
+ empty: Ti,
2245
+ product: Pi,
2246
+ products: Bi,
2247
+ image: Ai,
2248
+ productInfo: Oi,
2249
+ content: qi,
2250
+ name: Di,
2251
+ price: Ei,
2252
+ productButtons: Li,
2253
+ productButton: Ri,
2254
+ productCount: Mi,
2255
+ bottom: Hi,
2256
+ subtotal: Fi,
2257
+ block: Vi,
2258
+ shoppingCount: Ui,
2259
+ total: zi,
2260
+ link: Yi,
2261
+ userInfo: Gi
2262
+ }, Wi = "_button_bymeg_1", Xi = "_primary_bymeg_19", Ji = "_primaryHovered_bymeg_30", Qi = "_secondary_bymeg_34", Ki = "_secondaryHovered_bymeg_44", Zi = "_tertiary_bymeg_48", to = "_tertiaryHovered_bymeg_58", eo = "_content_bymeg_62", nt = {
2263
+ button: Wi,
2264
+ primary: Xi,
2265
+ primaryHovered: Ji,
2266
+ secondary: Qi,
2267
+ secondaryHovered: Ki,
2268
+ tertiary: Zi,
2269
+ tertiaryHovered: to,
2270
+ content: eo
2271
+ }, vt = (u) => {
2272
+ const { children: o, onClick: e, style: n, className: i, disabled: a = !1, type: c = "Primary" } = u, { themeSettings: s } = St();
2266
2273
  return /* @__PURE__ */ t.jsx(
2267
2274
  "button",
2268
2275
  {
2269
- className: H(ut.button, i, {
2270
- [ut.primary]: c === "Primary",
2271
- [ut.secondary]: c === "Secondary",
2272
- [ut.tertiary]: c === "Tertiary"
2276
+ className: V(nt.button, i, {
2277
+ [nt.primary]: c === "Primary",
2278
+ [nt.secondary]: c === "Secondary",
2279
+ [nt.tertiary]: c === "Tertiary",
2280
+ [nt.primaryHovered]: c === "Primary" && !a && s.buttons.primary.hover,
2281
+ [nt.secondaryHovered]: c === "Secondary" && !a && s.buttons.secondary.hover,
2282
+ [nt.tertiaryHovered]: c === "Tertiary" && !a && s.buttons.tertiary.hover
2273
2283
  }),
2274
2284
  onClick: e,
2275
2285
  style: {
2276
2286
  ...n
2277
2287
  },
2278
2288
  disabled: a,
2279
- children: c === "Tertiary" ? /* @__PURE__ */ t.jsxs("div", { className: ut.content, children: [
2289
+ children: c === "Tertiary" ? /* @__PURE__ */ t.jsxs("div", { className: nt.content, children: [
2280
2290
  /* @__PURE__ */ t.jsx(
2281
2291
  f,
2282
2292
  {
@@ -2294,13 +2304,13 @@ const Mo = (u) => {
2294
2304
  class mt extends Error {
2295
2305
  }
2296
2306
  mt.prototype.name = "InvalidTokenError";
2297
- function Qi(u) {
2307
+ function so(u) {
2298
2308
  return decodeURIComponent(atob(u).replace(/(.)/g, (o, e) => {
2299
2309
  let n = e.charCodeAt(0).toString(16).toUpperCase();
2300
2310
  return n.length < 2 && (n = "0" + n), "%" + n;
2301
2311
  }));
2302
2312
  }
2303
- function Ki(u) {
2313
+ function no(u) {
2304
2314
  let o = u.replace(/-/g, "+").replace(/_/g, "/");
2305
2315
  switch (o.length % 4) {
2306
2316
  case 0:
@@ -2315,12 +2325,12 @@ function Ki(u) {
2315
2325
  throw new Error("base64 string is not of the correct length");
2316
2326
  }
2317
2327
  try {
2318
- return Qi(o);
2328
+ return so(o);
2319
2329
  } catch {
2320
2330
  return atob(o);
2321
2331
  }
2322
2332
  }
2323
- function Zi(u, o) {
2333
+ function io(u, o) {
2324
2334
  if (typeof u != "string")
2325
2335
  throw new mt("Invalid token specified: must be a string");
2326
2336
  o || (o = {});
@@ -2329,7 +2339,7 @@ function Zi(u, o) {
2329
2339
  throw new mt(`Invalid token specified: missing part #${e + 1}`);
2330
2340
  let i;
2331
2341
  try {
2332
- i = Ki(n);
2342
+ i = no(n);
2333
2343
  } catch (a) {
2334
2344
  throw new mt(`Invalid token specified: invalid base64 for part #${e + 1} (${a.message})`);
2335
2345
  }
@@ -2339,68 +2349,74 @@ function Zi(u, o) {
2339
2349
  throw new mt(`Invalid token specified: invalid json for part #${e + 1} (${a.message})`);
2340
2350
  }
2341
2351
  }
2342
- const Ho = (u) => {
2352
+ const Yo = (u) => {
2343
2353
  const { shopping: o, signUp: e } = u, n = gt();
2344
2354
  function i(c) {
2345
2355
  n(c);
2346
2356
  }
2347
2357
  const a = JSON.parse(localStorage.getItem("token") || "{}");
2348
- return /* @__PURE__ */ t.jsxs("div", { className: N.buttons, children: [
2349
- o && /* @__PURE__ */ t.jsx(to, {}),
2358
+ return /* @__PURE__ */ t.jsxs("div", { className: P.buttons, children: [
2359
+ o && /* @__PURE__ */ t.jsx(oo, {}),
2350
2360
  !a.data && /* @__PURE__ */ t.jsx(
2351
- "div",
2361
+ vt,
2352
2362
  {
2353
- className: H(N.button, N.login),
2354
2363
  onClick: () => i("/customer-dash"),
2364
+ type: "Secondary",
2365
+ style: {
2366
+ padding: 10
2367
+ },
2355
2368
  children: "Login"
2356
2369
  }
2357
2370
  ),
2358
2371
  !a.data && e && /* @__PURE__ */ t.jsx(
2359
- "div",
2372
+ vt,
2360
2373
  {
2361
- className: H(N.button, N.login, N.signUp),
2362
2374
  onClick: () => i("/customer-dash"),
2375
+ type: "Primary",
2376
+ style: {
2377
+ padding: 10
2378
+ },
2363
2379
  children: "Sign Up"
2364
2380
  }
2365
2381
  ),
2366
- a.data && /* @__PURE__ */ t.jsx(no, { token: a.data })
2382
+ a.data && /* @__PURE__ */ t.jsx(lo, { token: a.data })
2367
2383
  ] });
2368
- }, to = () => {
2369
- const [u, o] = _.useState(!1), [e, n] = _.useState([]), { cart: i, getProducts: a } = $t();
2370
- function c(k) {
2384
+ }, oo = () => {
2385
+ const [u, o] = h.useState(!1), [e, n] = h.useState([]), { cart: i, getProducts: a } = wt();
2386
+ function c($) {
2371
2387
  for (let r = 0; r < i.parts.length; r++)
2372
- for (let B = 0; B < k.variants.length; B++)
2373
- if (i.parts[r].productVariantId === k.variants[r].id)
2388
+ for (let B = 0; B < $.variants.length; B++)
2389
+ if (i.parts[r].productVariantId === $.variants[r].id)
2374
2390
  return i.parts[r].productVariantId;
2375
2391
  }
2376
- function s(k) {
2392
+ function s($) {
2377
2393
  for (let r = 0; r < i.parts.length; r++)
2378
- for (let B = 0; B < k.variants.length; B++)
2379
- if (i.parts[r].productVariantId === k.variants[r].id)
2394
+ for (let B = 0; B < $.variants.length; B++)
2395
+ if (i.parts[r].productVariantId === $.variants[r].id)
2380
2396
  return i.parts[r].quantity;
2381
2397
  }
2382
- _.useEffect(() => {
2398
+ h.useEffect(() => {
2383
2399
  (async () => {
2384
- const r = i.parts.map((g) => String(g.productId)), h = (await a([...r])).map((g) => ({
2385
- ...g,
2386
- activeVariantId: c(g),
2387
- quantity: s(g)
2400
+ const r = i.parts.map((_) => String(_.productId)), x = (await a([...r])).map((_) => ({
2401
+ ..._,
2402
+ activeVariantId: c(_),
2403
+ quantity: s(_)
2388
2404
  }));
2389
- n(h);
2405
+ n(x);
2390
2406
  })();
2391
2407
  }, [i]);
2392
- function l(k) {
2408
+ function l($) {
2393
2409
  var r;
2394
- return !k || !(k != null && k.variants) ? !1 : (r = k.variants.find((B) => B.id === k.activeVariantId)) == null ? void 0 : r.subscriptionSettings;
2410
+ return !$ || !($ != null && $.variants) ? !1 : (r = $.variants.find((B) => B.id === $.activeVariantId)) == null ? void 0 : r.subscriptionSettings;
2395
2411
  }
2396
2412
  const d = i.parts.length > 0 && e.length > 0 && !l(e[0]);
2397
2413
  return /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
2398
2414
  /* @__PURE__ */ t.jsxs(
2399
2415
  "div",
2400
2416
  {
2401
- className: N.button,
2402
- onClick: (k) => {
2403
- k.stopPropagation(), o(!0);
2417
+ className: P.button,
2418
+ onClick: ($) => {
2419
+ $.stopPropagation(), window.location.pathname !== "/admin/builder" && o(!0);
2404
2420
  },
2405
2421
  children: [
2406
2422
  /* @__PURE__ */ t.jsx(
@@ -2410,20 +2426,20 @@ const Ho = (u) => {
2410
2426
  fill: "var(--icon-primary)"
2411
2427
  }
2412
2428
  ),
2413
- d && /* @__PURE__ */ t.jsx("div", { className: N.shoppingCount, children: i.parts.length })
2429
+ d && /* @__PURE__ */ t.jsx("div", { className: P.shoppingCount, children: i.parts.length })
2414
2430
  ]
2415
2431
  }
2416
2432
  ),
2417
- u && /* @__PURE__ */ t.jsx(Ct, { close: o, children: /* @__PURE__ */ t.jsx(
2418
- eo,
2433
+ u && /* @__PURE__ */ t.jsx(Tt, { close: o, children: /* @__PURE__ */ t.jsx(
2434
+ ao,
2419
2435
  {
2420
2436
  activeProducts: e,
2421
2437
  isCartNotEmpty: d
2422
2438
  }
2423
2439
  ) })
2424
2440
  ] });
2425
- }, eo = (u) => {
2426
- const { activeProducts: o, isCartNotEmpty: e } = u, { cart: n, reset: i, getTotalAndDiscount: a, updateQuantityOfProduct: c } = $t(), s = gt();
2441
+ }, ao = (u) => {
2442
+ const { activeProducts: o, isCartNotEmpty: e } = u, { cart: n, reset: i, getTotalAndDiscount: a, updateQuantityOfProduct: c } = wt(), s = gt();
2427
2443
  function l(r) {
2428
2444
  s(r);
2429
2445
  }
@@ -2434,7 +2450,7 @@ const Ho = (u) => {
2434
2450
  quantity: r.quantity + 1
2435
2451
  });
2436
2452
  }
2437
- function k(r) {
2453
+ function $(r) {
2438
2454
  c({
2439
2455
  productId: r.id,
2440
2456
  productVariantId: r.activeVariantId,
@@ -2444,19 +2460,19 @@ const Ho = (u) => {
2444
2460
  return /* @__PURE__ */ t.jsxs(
2445
2461
  "div",
2446
2462
  {
2447
- className: N.modal,
2463
+ className: P.modal,
2448
2464
  onClick: (r) => r.stopPropagation(),
2449
2465
  children: [
2450
- /* @__PURE__ */ t.jsxs("div", { className: N.top, children: [
2451
- /* @__PURE__ */ t.jsxs("div", { className: N.info, children: [
2452
- /* @__PURE__ */ t.jsx("span", { className: N.title, children: "Cart" }),
2453
- e && /* @__PURE__ */ t.jsx("div", { className: N.count, children: n.parts.length })
2466
+ /* @__PURE__ */ t.jsxs("div", { className: P.top, children: [
2467
+ /* @__PURE__ */ t.jsxs("div", { className: P.info, children: [
2468
+ /* @__PURE__ */ t.jsx("span", { className: P.title, children: "Cart" }),
2469
+ e && /* @__PURE__ */ t.jsx("div", { className: P.count, children: n.parts.length })
2454
2470
  ] }),
2455
2471
  /* @__PURE__ */ t.jsx(
2456
2472
  "button",
2457
2473
  {
2458
- className: H(N.clear, {
2459
- [N.activeClear]: e
2474
+ className: V(P.clear, {
2475
+ [P.activeClear]: e
2460
2476
  }),
2461
2477
  disabled: !e,
2462
2478
  onClick: () => i(),
@@ -2464,13 +2480,13 @@ const Ho = (u) => {
2464
2480
  }
2465
2481
  )
2466
2482
  ] }),
2467
- e ? /* @__PURE__ */ t.jsxs("div", { className: N.cart, children: [
2468
- /* @__PURE__ */ t.jsx("div", { className: N.products, children: o.map((r) => /* @__PURE__ */ t.jsxs(
2483
+ e ? /* @__PURE__ */ t.jsxs("div", { className: P.cart, children: [
2484
+ /* @__PURE__ */ t.jsx("div", { className: P.products, children: o.map((r) => /* @__PURE__ */ t.jsxs(
2469
2485
  "div",
2470
2486
  {
2471
- className: N.product,
2487
+ className: P.product,
2472
2488
  children: [
2473
- /* @__PURE__ */ t.jsxs("div", { className: N.productInfo, children: [
2489
+ /* @__PURE__ */ t.jsxs("div", { className: P.productInfo, children: [
2474
2490
  /* @__PURE__ */ t.jsx(
2475
2491
  "img",
2476
2492
  {
@@ -2478,25 +2494,25 @@ const Ho = (u) => {
2478
2494
  alt: "image",
2479
2495
  width: "100%",
2480
2496
  height: "100%",
2481
- className: N.image
2497
+ className: P.image
2482
2498
  }
2483
2499
  ),
2484
- /* @__PURE__ */ t.jsxs("div", { className: N.content, children: [
2485
- /* @__PURE__ */ t.jsx("div", { className: N.name, children: r.name }),
2486
- /* @__PURE__ */ t.jsxs("div", { className: N.price, children: [
2500
+ /* @__PURE__ */ t.jsxs("div", { className: P.content, children: [
2501
+ /* @__PURE__ */ t.jsx("div", { className: P.name, children: r.name }),
2502
+ /* @__PURE__ */ t.jsxs("div", { className: P.price, children: [
2487
2503
  "$",
2488
2504
  r.variants.find((B) => B.id === r.activeVariantId).price.amount * ((r == null ? void 0 : r.quantity) || 1)
2489
2505
  ] })
2490
2506
  ] })
2491
2507
  ] }),
2492
- /* @__PURE__ */ t.jsxs("div", { className: N.productButtons, children: [
2508
+ /* @__PURE__ */ t.jsxs("div", { className: P.productButtons, children: [
2493
2509
  /* @__PURE__ */ t.jsx(
2494
2510
  "div",
2495
2511
  {
2496
2512
  onClick: () => {
2497
- r.quantity !== 1 && k(r);
2513
+ r.quantity !== 1 && $(r);
2498
2514
  },
2499
- className: N.productButton,
2515
+ className: P.productButton,
2500
2516
  children: /* @__PURE__ */ t.jsx(
2501
2517
  f,
2502
2518
  {
@@ -2508,12 +2524,12 @@ const Ho = (u) => {
2508
2524
  )
2509
2525
  }
2510
2526
  ),
2511
- /* @__PURE__ */ t.jsx("div", { className: N.productCount, children: r.quantity }),
2527
+ /* @__PURE__ */ t.jsx("div", { className: P.productCount, children: r.quantity }),
2512
2528
  /* @__PURE__ */ t.jsx(
2513
2529
  "div",
2514
2530
  {
2515
2531
  onClick: () => d(r),
2516
- className: N.productButton,
2532
+ className: P.productButton,
2517
2533
  children: /* @__PURE__ */ t.jsx(
2518
2534
  f,
2519
2535
  {
@@ -2530,9 +2546,9 @@ const Ho = (u) => {
2530
2546
  },
2531
2547
  r.id
2532
2548
  )) }),
2533
- /* @__PURE__ */ t.jsxs("div", { className: N.bottom, children: [
2534
- /* @__PURE__ */ t.jsxs("div", { className: N.subtotal, children: [
2535
- /* @__PURE__ */ t.jsxs("div", { className: N.block, children: [
2549
+ /* @__PURE__ */ t.jsxs("div", { className: P.bottom, children: [
2550
+ /* @__PURE__ */ t.jsxs("div", { className: P.subtotal, children: [
2551
+ /* @__PURE__ */ t.jsxs("div", { className: P.block, children: [
2536
2552
  /* @__PURE__ */ t.jsx("span", { children: "Subtotal" }),
2537
2553
  /* @__PURE__ */ t.jsx(
2538
2554
  f,
@@ -2544,18 +2560,18 @@ const Ho = (u) => {
2544
2560
  }
2545
2561
  )
2546
2562
  ] }),
2547
- /* @__PURE__ */ t.jsxs("div", { className: N.total, children: [
2563
+ /* @__PURE__ */ t.jsxs("div", { className: P.total, children: [
2548
2564
  "$",
2549
2565
  a().total
2550
2566
  ] })
2551
2567
  ] }),
2552
- /* @__PURE__ */ t.jsx(Ji, { onClick: () => l("/checkout"), children: "Checkout" })
2568
+ /* @__PURE__ */ t.jsx(vt, { onClick: () => l("/checkout"), children: "Checkout" })
2553
2569
  ] })
2554
- ] }) : /* @__PURE__ */ t.jsx(so, {})
2570
+ ] }) : /* @__PURE__ */ t.jsx(co, {})
2555
2571
  ]
2556
2572
  }
2557
2573
  );
2558
- }, so = () => /* @__PURE__ */ t.jsxs("div", { className: N.empty, children: [
2574
+ }, co = () => /* @__PURE__ */ t.jsxs("div", { className: P.empty, children: [
2559
2575
  /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(f, { name: "Handbag" }) }),
2560
2576
  /* @__PURE__ */ t.jsx("span", { children: "Your cart is empty" }),
2561
2577
  /* @__PURE__ */ t.jsxs("span", { children: [
@@ -2565,16 +2581,16 @@ const Ho = (u) => {
2565
2581
  "a",
2566
2582
  {
2567
2583
  href: "/products",
2568
- className: N.link,
2584
+ className: P.link,
2569
2585
  children: "here"
2570
2586
  }
2571
2587
  )
2572
2588
  ] })
2573
- ] }), no = ({ token: u }) => {
2574
- const [o, e] = _.useState("test-email@gmail.com"), n = gt();
2575
- _.useEffect(() => {
2589
+ ] }), lo = ({ token: u }) => {
2590
+ const [o, e] = h.useState("test-email@gmail.com"), n = gt();
2591
+ h.useEffect(() => {
2576
2592
  (async () => {
2577
- const c = Zi(u);
2593
+ const c = io(u);
2578
2594
  e(c.email);
2579
2595
  })();
2580
2596
  }, [u]);
@@ -2584,29 +2600,29 @@ const Ho = (u) => {
2584
2600
  return /* @__PURE__ */ t.jsx(
2585
2601
  "div",
2586
2602
  {
2587
- className: N.userInfo,
2603
+ className: P.userInfo,
2588
2604
  onClick: () => i("/customer-dash"),
2589
2605
  children: /* @__PURE__ */ t.jsx("div", { children: o || "test-email@gmail.com" })
2590
2606
  }
2591
2607
  );
2592
- }, io = "_share_9g414_1", oo = "_modal_9g414_8", ao = "_header_9g414_14", co = "_socials_9g414_24", lo = "_social_9g414_24", ro = "_copy_9g414_34", uo = "_title_9g414_41", po = "_copyWrapper_9g414_47", mo = "_copyText_9g414_56", Q = {
2593
- share: io,
2594
- modal: oo,
2595
- header: ao,
2596
- socials: co,
2597
- social: lo,
2598
- copy: ro,
2599
- title: uo,
2600
- copyWrapper: po,
2601
- copyText: mo
2602
- }, Fo = () => {
2603
- const { isOpenModal: u, setIsOpenModal: o } = St();
2608
+ }, ro = "_share_9g414_1", uo = "_modal_9g414_8", po = "_header_9g414_14", mo = "_socials_9g414_24", ho = "_social_9g414_24", _o = "_copy_9g414_34", go = "_title_9g414_41", fo = "_copyWrapper_9g414_47", xo = "_copyText_9g414_56", Q = {
2609
+ share: ro,
2610
+ modal: uo,
2611
+ header: po,
2612
+ socials: mo,
2613
+ social: ho,
2614
+ copy: _o,
2615
+ title: go,
2616
+ copyWrapper: fo,
2617
+ copyText: xo
2618
+ }, Go = () => {
2619
+ const { isOpenModal: u, setIsOpenModal: o } = Pt();
2604
2620
  function e() {
2605
2621
  o(!0);
2606
2622
  }
2607
2623
  return /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
2608
2624
  /* @__PURE__ */ t.jsx(
2609
- it,
2625
+ ot,
2610
2626
  {
2611
2627
  className: Q.share,
2612
2628
  onClick: (n) => {
@@ -2617,12 +2633,13 @@ const Ho = (u) => {
2617
2633
  f,
2618
2634
  {
2619
2635
  name: "Share",
2620
- fill: "#757575"
2636
+ fill: "#757575",
2637
+ hoverable: !0
2621
2638
  }
2622
2639
  )
2623
2640
  }
2624
2641
  ),
2625
- u && /* @__PURE__ */ t.jsx(Ct, { close: o, children: /* @__PURE__ */ t.jsx(ho, {}) })
2642
+ u && /* @__PURE__ */ t.jsx(Tt, { close: o, children: /* @__PURE__ */ t.jsx(bo, {}) })
2626
2643
  ] });
2627
2644
  }, It = {
2628
2645
  facebook: "FacebookLogo",
@@ -2631,16 +2648,19 @@ const Ho = (u) => {
2631
2648
  instagram: "InstagramLogo",
2632
2649
  discord: "MessengerLogo",
2633
2650
  tiktok: "TiktokLogo"
2634
- }, ho = () => {
2635
- const { setIsOpenModal: u } = St(), o = window.location.href;
2636
- function e() {
2637
- navigator.clipboard.writeText(o);
2651
+ }, bo = () => {
2652
+ const { setIsOpenModal: u } = Pt(), { notification: o, setNotification: e } = Dt(), n = window.location.href;
2653
+ function i() {
2654
+ navigator.clipboard.writeText(n), e({
2655
+ message: "Link copied to clipboard",
2656
+ status: "success"
2657
+ });
2638
2658
  }
2639
2659
  return /* @__PURE__ */ t.jsxs(
2640
2660
  "div",
2641
2661
  {
2642
2662
  className: Q.modal,
2643
- onClick: (n) => n.stopPropagation(),
2663
+ onClick: (a) => a.stopPropagation(),
2644
2664
  children: [
2645
2665
  /* @__PURE__ */ t.jsxs("div", { className: Q.header, children: [
2646
2666
  /* @__PURE__ */ t.jsx("div", { className: Q.title, children: "Share this Post" }),
@@ -2649,43 +2669,44 @@ const Ho = (u) => {
2649
2669
  {
2650
2670
  name: "X",
2651
2671
  fill: "#757575",
2652
- onClick: () => u(!1)
2672
+ onClick: () => u(!1),
2673
+ hoverable: !0
2653
2674
  }
2654
2675
  )
2655
2676
  ] }),
2656
- /* @__PURE__ */ t.jsx("div", { className: Q.socials, children: Object.keys(It).map((n) => /* @__PURE__ */ t.jsx("div", { className: Q.social, children: /* @__PURE__ */ t.jsx(f, { name: It[n] }) })) }),
2677
+ /* @__PURE__ */ t.jsx("div", { className: Q.socials, children: Object.keys(It).map((a) => /* @__PURE__ */ t.jsx("div", { className: Q.social, children: /* @__PURE__ */ t.jsx(f, { name: It[a] }) })) }),
2657
2678
  /* @__PURE__ */ t.jsxs("div", { className: Q.copyWrapper, children: [
2658
2679
  /* @__PURE__ */ t.jsx(
2659
2680
  "div",
2660
2681
  {
2661
- className: H(Q.copy, Q.copyText),
2662
- onClick: e,
2663
- children: o
2682
+ className: V(Q.copy, Q.copyText),
2683
+ onClick: i,
2684
+ children: n
2664
2685
  }
2665
2686
  ),
2666
2687
  /* @__PURE__ */ t.jsx(
2667
2688
  "div",
2668
2689
  {
2669
- onClick: e,
2690
+ onClick: i,
2670
2691
  className: Q.copy,
2671
- children: /* @__PURE__ */ t.jsx(f, { name: "Copy" })
2692
+ children: o ? /* @__PURE__ */ t.jsx(f, { name: "Check" }) : /* @__PURE__ */ t.jsx(f, { name: "Copy" })
2672
2693
  }
2673
2694
  )
2674
2695
  ] })
2675
2696
  ]
2676
2697
  }
2677
2698
  );
2678
- }, _o = "_accordion_9e4oa_1", go = "_header_9e4oa_9", xo = "_icon_9e4oa_18", fo = "_open_9e4oa_21", bo = "_content_9e4oa_25", pt = {
2679
- accordion: _o,
2680
- header: go,
2681
- icon: xo,
2682
- open: fo,
2683
- content: bo
2684
- }, Vo = ({ title: u, content: o }) => {
2685
- const [e, n] = _.useState(!1), [i, a] = _.useState(0), c = _.useRef(null), s = () => {
2699
+ }, vo = "_accordion_1s1lq_1", jo = "_header_1s1lq_9", yo = "_icon_1s1lq_18", ko = "_open_1s1lq_21", $o = "_content_1s1lq_25", pt = {
2700
+ accordion: vo,
2701
+ header: jo,
2702
+ icon: yo,
2703
+ open: ko,
2704
+ content: $o
2705
+ }, Wo = ({ title: u, content: o }) => {
2706
+ const [e, n] = h.useState(!1), [i, a] = h.useState(0), c = h.useRef(null), s = () => {
2686
2707
  n(!e);
2687
2708
  };
2688
- return _.useEffect(() => {
2709
+ return h.useEffect(() => {
2689
2710
  c.current && a(e ? c.current.scrollHeight : 0);
2690
2711
  }, [e]), /* @__PURE__ */ t.jsxs("div", { className: pt.accordion, children: [
2691
2712
  /* @__PURE__ */ t.jsxs(
@@ -2695,7 +2716,7 @@ const Ho = (u) => {
2695
2716
  onClick: s,
2696
2717
  children: [
2697
2718
  /* @__PURE__ */ t.jsx("h5", { id: "h5", children: u }),
2698
- /* @__PURE__ */ t.jsx("div", { className: H(pt.icon, { [pt.open]: e }), children: /* @__PURE__ */ t.jsx(f, { name: "CaretDown" }) })
2719
+ /* @__PURE__ */ t.jsx("div", { className: V(pt.icon, { [pt.open]: e }), children: /* @__PURE__ */ t.jsx(f, { name: "CaretDown" }) })
2699
2720
  ]
2700
2721
  }
2701
2722
  ),
@@ -2709,16 +2730,16 @@ const Ho = (u) => {
2709
2730
  }
2710
2731
  )
2711
2732
  ] });
2712
- }, vo = "_wrapper_1r14x_1", jo = "_label_1r14x_9", yo = "_input_1r14x_18", ko = "_required_1r14x_35", $o = "_paddingless_1r14x_39", No = "_content_1r14x_43", Io = "_borderless_1r14x_58", wo = "_rightIcon_1r14x_63", nt = {
2713
- wrapper: vo,
2714
- label: jo,
2715
- input: yo,
2716
- required: ko,
2717
- paddingless: $o,
2718
- content: No,
2719
- borderless: Io,
2720
- rightIcon: wo
2721
- }, Uo = (u) => {
2733
+ }, wo = "_wrapper_1r14x_1", No = "_label_1r14x_9", Io = "_input_1r14x_18", Co = "_required_1r14x_35", So = "_paddingless_1r14x_39", To = "_content_1r14x_43", Po = "_borderless_1r14x_58", Bo = "_rightIcon_1r14x_63", it = {
2734
+ wrapper: wo,
2735
+ label: No,
2736
+ input: Io,
2737
+ required: Co,
2738
+ paddingless: So,
2739
+ content: To,
2740
+ borderless: Po,
2741
+ rightIcon: Bo
2742
+ }, Xo = (u) => {
2722
2743
  const {
2723
2744
  onChange: o,
2724
2745
  style: e,
@@ -2729,39 +2750,39 @@ const Ho = (u) => {
2729
2750
  max: s,
2730
2751
  placeholder: l,
2731
2752
  disabled: d = !1,
2732
- required: k = !1,
2753
+ required: $ = !1,
2733
2754
  regex: r,
2734
2755
  paddingless: B = !1,
2735
- borderless: h = !1,
2736
- editable: g = !1,
2756
+ borderless: x = !1,
2757
+ editable: _ = !1,
2737
2758
  isSearch: m = !1
2738
- } = u, { themeSettings: O } = At(), { inputs: R } = O, [P, q] = _.useState(!1);
2739
- function C(v, M) {
2740
- if (v.startsWith("#")) {
2741
- let I, D, E;
2742
- return v.length === 7 ? (I = parseInt(v.slice(1, 3), 16), D = parseInt(v.slice(3, 5), 16), E = parseInt(v.slice(5, 7), 16)) : v.length === 4 && (I = parseInt(v[1] + v[1], 16), D = parseInt(v[2] + v[2], 16), E = parseInt(v[3] + v[3], 16)), `rgba(${I}, ${D}, ${E}, ${M})`;
2759
+ } = u, { themeSettings: O } = St(), { inputs: q } = O, [b, D] = h.useState(!1);
2760
+ function C(j, M) {
2761
+ if (j.startsWith("#")) {
2762
+ let N, E, L;
2763
+ return j.length === 7 ? (N = parseInt(j.slice(1, 3), 16), E = parseInt(j.slice(3, 5), 16), L = parseInt(j.slice(5, 7), 16)) : j.length === 4 && (N = parseInt(j[1] + j[1], 16), E = parseInt(j[2] + j[2], 16), L = parseInt(j[3] + j[3], 16)), `rgba(${N}, ${E}, ${L}, ${M})`;
2743
2764
  }
2744
- const j = {
2765
+ const y = {
2745
2766
  black: "#000000",
2746
2767
  white: "#ffffff",
2747
2768
  red: "#ff0000",
2748
2769
  green: "#00ff00",
2749
2770
  blue: "#0000ff"
2750
2771
  // Можно добавить больше цветов
2751
- }[v.toLowerCase()];
2752
- return j ? C(j, M) : v;
2772
+ }[j.toLowerCase()];
2773
+ return y ? C(y, M) : j;
2753
2774
  }
2754
- function S(v) {
2755
- return Number(v) < 0 ? String(c) : v;
2775
+ function S(j) {
2776
+ return Number(j) < 0 ? String(c) : j;
2756
2777
  }
2757
- function x(v) {
2758
- return !k || !r ? !0 : new RegExp(r).test(v);
2778
+ function g(j) {
2779
+ return !$ || !r ? !0 : new RegExp(r).test(j);
2759
2780
  }
2760
- return /* @__PURE__ */ t.jsxs("div", { className: nt.wrapper, children: [
2781
+ return /* @__PURE__ */ t.jsxs("div", { className: it.wrapper, children: [
2761
2782
  n && /* @__PURE__ */ t.jsx(
2762
2783
  "label",
2763
2784
  {
2764
- className: nt.label,
2785
+ className: it.label,
2765
2786
  htmlFor: n,
2766
2787
  children: n
2767
2788
  }
@@ -2769,11 +2790,11 @@ const Ho = (u) => {
2769
2790
  /* @__PURE__ */ t.jsxs(
2770
2791
  "div",
2771
2792
  {
2772
- className: nt.content,
2793
+ className: it.content,
2773
2794
  style: {
2774
- paddingRight: R.general.height + 15,
2795
+ paddingRight: q.general.height + 15,
2775
2796
  ...e,
2776
- backgroundColor: C(R.field.color, R.field.opacity / 100)
2797
+ backgroundColor: C(q.field.color, q.field.opacity / 100)
2777
2798
  },
2778
2799
  children: [
2779
2800
  /* @__PURE__ */ t.jsx(
@@ -2781,37 +2802,37 @@ const Ho = (u) => {
2781
2802
  {
2782
2803
  id: n,
2783
2804
  type: a || "text",
2784
- onChange: (v) => {
2785
- if (a === "text") o(v.target.value);
2805
+ onChange: (j) => {
2806
+ if (a === "text") o(j.target.value);
2786
2807
  else {
2787
- const M = S(v.target.value);
2808
+ const M = S(j.target.value);
2788
2809
  o(M);
2789
2810
  }
2790
2811
  },
2791
2812
  value: i,
2792
2813
  autoComplete: "off",
2793
2814
  placeholder: l || "Type something...",
2794
- className: H(nt.input, {
2795
- [nt.required]: P && k && !x(i),
2796
- [nt.paddingless]: B,
2797
- [nt.borderless]: h
2815
+ className: V(it.input, {
2816
+ [it.required]: b && $ && !g(i),
2817
+ [it.paddingless]: B,
2818
+ [it.borderless]: x
2798
2819
  }),
2799
2820
  min: a === "number" ? c : void 0,
2800
2821
  max: a === "number" ? s : void 0,
2801
2822
  disabled: d,
2802
- onFocus: () => q(!0)
2823
+ onFocus: () => D(!0)
2803
2824
  }
2804
2825
  ),
2805
- m && /* @__PURE__ */ t.jsx("div", { className: nt.rightIcon, children: /* @__PURE__ */ t.jsx(
2826
+ m && /* @__PURE__ */ t.jsx("div", { className: it.rightIcon, children: /* @__PURE__ */ t.jsx(
2806
2827
  f,
2807
2828
  {
2808
2829
  name: "MagnifyingGlass",
2809
2830
  fill: "var(--icon-secondary)",
2810
- width: R.general.height,
2811
- height: R.general.height
2831
+ width: q.general.height,
2832
+ height: q.general.height
2812
2833
  }
2813
2834
  ) }),
2814
- g && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
2835
+ _ && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
2815
2836
  f,
2816
2837
  {
2817
2838
  name: "Sliders",
@@ -2824,13 +2845,13 @@ const Ho = (u) => {
2824
2845
  }
2825
2846
  )
2826
2847
  ] });
2827
- }, Co = "_wrapper_st58d_1", So = "_label_st58d_10", To = "_textarea_st58d_18", Bo = "_length_st58d_33", _t = {
2828
- wrapper: Co,
2829
- label: So,
2830
- textarea: To,
2831
- length: Bo
2832
- }, zo = (u) => {
2833
- const { onChange: o, label: e, value: n, maxLength: i, placeholder: a = "Type something..." } = u, [c, s] = _.useState(n.length);
2848
+ }, Ao = "_wrapper_st58d_1", Oo = "_label_st58d_10", qo = "_textarea_st58d_18", Do = "_length_st58d_33", _t = {
2849
+ wrapper: Ao,
2850
+ label: Oo,
2851
+ textarea: qo,
2852
+ length: Do
2853
+ }, Jo = (u) => {
2854
+ const { onChange: o, label: e, value: n, maxLength: i, placeholder: a = "Type something..." } = u, [c, s] = h.useState(n.length);
2834
2855
  return /* @__PURE__ */ t.jsxs("div", { className: _t.wrapper, children: [
2835
2856
  e && /* @__PURE__ */ t.jsx(
2836
2857
  "label",
@@ -2861,34 +2882,34 @@ const Ho = (u) => {
2861
2882
  ] });
2862
2883
  };
2863
2884
  export {
2864
- Vo as Accordion,
2865
- Ji as Button,
2866
- rn as ButtonTypeSettings,
2867
- Lo as ButtonsSettings,
2868
- Do as CategorySettings,
2885
+ Wo as Accordion,
2886
+ vt as Button,
2887
+ pn as ButtonTypeSettings,
2888
+ Vo as ButtonsSettings,
2889
+ Ho as CategorySettings,
2869
2890
  ht as ChooseImage,
2870
- Wo as ChooseImageModal,
2871
- so as EmptyCart,
2872
- Eo as FormSettings,
2873
- Ho as HeaderButtons,
2891
+ Zo as ChooseImageModal,
2892
+ co as EmptyCart,
2893
+ Fo as FormSettings,
2894
+ Yo as HeaderButtons,
2874
2895
  f as Icon,
2875
2896
  W as InputSettings,
2876
- Uo as InputUI,
2877
- Se as ItemsSettings,
2878
- qo as LayoutSettings,
2879
- Ro as ListingSelector,
2880
- Xo as Loader,
2881
- Ct as Modal,
2882
- Mo as ProductOptions,
2897
+ Xo as InputUI,
2898
+ Be as ItemsSettings,
2899
+ Mo as LayoutSettings,
2900
+ Uo as ListingSelector,
2901
+ ta as Loader,
2902
+ Tt as Modal,
2903
+ zo as ProductOptions,
2883
2904
  Nt as RangeSelector,
2884
2905
  tt as Select,
2885
- Fo as ShareLink,
2886
- to as ShoppingButton,
2887
- eo as ShoppingModalCart,
2906
+ Go as ShareLink,
2907
+ oo as ShoppingButton,
2908
+ ao as ShoppingModalCart,
2888
2909
  K as Switch,
2889
- Bt as TextSettings,
2890
- wt as TextareaSettings,
2891
- zo as TextareaUI,
2892
- Tt as TypesText,
2893
- no as UserInfo
2910
+ At as TextSettings,
2911
+ Ct as TextareaSettings,
2912
+ Jo as TextareaUI,
2913
+ Bt as TypesText,
2914
+ lo as UserInfo
2894
2915
  };