@billgangcom/theme-lib 1.36.1 → 1.38.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,21 +1,21 @@
1
- import { j as t, I as b, c as z, a as W, S as Z, T as Ot, C as gt, b as st, u as $t, d as Nt, D as It, e as wt, v as Ct, B as at, f as mt, P as Bt, g as St, h as Tt, i as Ht, k as jt, l as Pt, m as qt, M as Et, n as Dt, o as zt } from "./index-CAh3qv6L.js";
2
- import { p as fa, L as xa } from "./index-CAh3qv6L.js";
3
- import g from "react";
1
+ import { j as t, I as v, c as F, a as W, S as Z, T as Ot, C as gt, b as st, u as It, d as $t, D as Nt, e as wt, v as Ct, B as ct, f as mt, P as Bt, g as St, h as Tt, i as Ht, k as bt, l as Pt, m as qt, M as Et, n as Dt, o as zt, p as Ft } from "./index-BRelv8dA.js";
2
+ import { q as ya, L as ka } from "./index-BRelv8dA.js";
3
+ import p from "react";
4
4
  import "@phosphor-icons/react";
5
- const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibiw_15", Yt = "_subtitle_3ibiw_22", Gt = "_alignmentContent_3ibiw_29", Wt = "_alignments_3ibiw_37", Xt = "_alignment_3ibiw_8", Jt = "_circle_3ibiw_63", Qt = "_paddings_3ibiw_70", Kt = "_padding_3ibiw_70", Zt = "_active_3ibiw_94", te = "_input_3ibiw_101", J = {
6
- wrapper: Ft,
7
- alignmentBlock: Vt,
8
- title: Ut,
9
- subtitle: Yt,
10
- alignmentContent: Gt,
11
- alignments: Wt,
12
- alignment: Xt,
13
- circle: Jt,
14
- paddings: Qt,
15
- padding: Kt,
16
- active: Zt,
17
- input: te
18
- }, ee = [
5
+ const Vt = "_wrapper_1ibay_2", Ut = "_alignmentBlock_1ibay_8", Yt = "_title_1ibay_15", Gt = "_subtitle_1ibay_22", Wt = "_alignmentContent_1ibay_29", Xt = "_alignments_1ibay_37", Jt = "_alignment_1ibay_8", Qt = "_circle_1ibay_60", Kt = "_paddings_1ibay_67", Zt = "_padding_1ibay_67", te = "_active_1ibay_91", ee = "_input_1ibay_98", J = {
6
+ wrapper: Vt,
7
+ alignmentBlock: Ut,
8
+ title: Yt,
9
+ subtitle: Gt,
10
+ alignmentContent: Wt,
11
+ alignments: Xt,
12
+ alignment: Jt,
13
+ circle: Qt,
14
+ paddings: Kt,
15
+ padding: Zt,
16
+ active: te,
17
+ input: ee
18
+ }, se = [
19
19
  "topLeft",
20
20
  "top",
21
21
  "topRight",
@@ -25,10 +25,10 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
25
25
  "bottomLeft",
26
26
  "bottom",
27
27
  "bottomRight"
28
- ], se = ["left", "top", "right", "bottom"], ia = (r) => {
29
- const { alignment: c, padding: e, setPadding: s, setAlignment: i } = r;
30
- function a() {
31
- switch (c) {
28
+ ], ne = ["left", "top", "right", "bottom"], ra = (r) => {
29
+ const { alignment: a, padding: e, setPadding: s, setAlignment: i } = r;
30
+ function o(x) {
31
+ switch (x) {
32
32
  case "left":
33
33
  case "topLeft":
34
34
  case "bottomLeft":
@@ -45,8 +45,8 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
45
45
  return "TextAlignCenter";
46
46
  }
47
47
  }
48
- function l(o) {
49
- switch (o) {
48
+ function l(x) {
49
+ switch (x) {
50
50
  case "left":
51
51
  return "AlignLeft";
52
52
  case "right":
@@ -57,25 +57,40 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
57
57
  return "AlignBottom";
58
58
  }
59
59
  }
60
- const [m, n] = g.useState(null);
60
+ const [d, n] = p.useState(null), [c, b] = p.useState(null);
61
61
  return /* @__PURE__ */ t.jsxs("div", { className: J.layout, children: [
62
62
  /* @__PURE__ */ t.jsx("h3", { className: J.title, children: "Layout" }),
63
63
  /* @__PURE__ */ t.jsxs("div", { className: J.alignmentBlock, children: [
64
64
  /* @__PURE__ */ t.jsx("h5", { className: J.subtitle, children: "Alignment" }),
65
65
  /* @__PURE__ */ t.jsxs("div", { className: J.alignmentContent, children: [
66
- /* @__PURE__ */ t.jsx("div", { className: J.alignments, children: ee.map((o) => /* @__PURE__ */ t.jsxs(
66
+ /* @__PURE__ */ t.jsx("div", { className: J.alignments, children: se.map((x) => /* @__PURE__ */ t.jsxs(
67
67
  "div",
68
68
  {
69
69
  onClick: () => {
70
- i(o);
70
+ i(x);
71
71
  },
72
72
  className: J.alignment,
73
+ onMouseEnter: () => {
74
+ n(x);
75
+ },
76
+ onMouseLeave: () => {
77
+ n(null);
78
+ },
73
79
  children: [
74
- o !== c && /* @__PURE__ */ t.jsx("div", { className: J.circle }),
75
- o === c && /* @__PURE__ */ t.jsx(
76
- b,
80
+ x !== a && d !== x && /* @__PURE__ */ t.jsx("div", { className: J.circle }),
81
+ x !== a && d === x && /* @__PURE__ */ t.jsx(
82
+ v,
77
83
  {
78
- name: a(),
84
+ name: o(d),
85
+ fill: "#c2c2c2",
86
+ width: 22,
87
+ height: 22
88
+ }
89
+ ),
90
+ x === a && /* @__PURE__ */ t.jsx(
91
+ v,
92
+ {
93
+ name: o(a),
79
94
  fill: "#FF3F19",
80
95
  width: 22,
81
96
  height: 22
@@ -83,25 +98,25 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
83
98
  )
84
99
  ]
85
100
  },
86
- o
101
+ x
87
102
  )) }),
88
- /* @__PURE__ */ t.jsx("div", { className: J.paddings, children: se.map((o) => /* @__PURE__ */ t.jsxs(
103
+ /* @__PURE__ */ t.jsx("div", { className: J.paddings, children: ne.map((x) => /* @__PURE__ */ t.jsxs(
89
104
  "label",
90
105
  {
91
- className: z(J.padding, {
92
- [J.active]: m === o
106
+ className: F(J.padding, {
107
+ [J.active]: c === x
93
108
  }),
94
109
  onFocus: () => {
95
- n(o);
110
+ b(x);
96
111
  },
97
112
  onBlur: () => {
98
- n(null);
113
+ b(null);
99
114
  },
100
115
  children: [
101
116
  /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
102
- b,
117
+ v,
103
118
  {
104
- name: l(o),
119
+ name: l(x),
105
120
  width: 20,
106
121
  height: 20
107
122
  }
@@ -110,10 +125,10 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
110
125
  W,
111
126
  {
112
127
  type: "number",
113
- value: String(e[o]),
114
- onChange: (x) => s({
128
+ value: String(e[x]),
129
+ onChange: (h) => s({
115
130
  ...e,
116
- [o]: Number(x)
131
+ [x]: Number(h)
117
132
  }),
118
133
  paddingless: !0,
119
134
  borderless: !0
@@ -121,24 +136,24 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
121
136
  )
122
137
  ]
123
138
  },
124
- o
139
+ x
125
140
  )) })
126
141
  ] })
127
142
  ] })
128
143
  ] });
129
- }, ne = "_title_1jkiw_1", ie = "_subtitle_1jkiw_5", oe = "_header_1jkiw_12", ae = "_text_1jkiw_13", ce = "_top_1jkiw_20", le = "_itemsBlock_1jkiw_29", ht = {
130
- title: ne,
131
- subtitle: ie,
132
- header: oe,
133
- text: ae,
134
- top: ce,
135
- itemsBlock: le
136
- }, re = "_typeTexts_167ez_1", de = "_block_167ez_8", ue = "_active_167ez_25", vt = {
137
- typeTexts: re,
138
- block: de,
139
- active: ue
140
- }, me = ["bold", "italic", "underline", "strike-through", "code"], Lt = (r) => {
141
- const { typesText: c, setTypesText: e } = r;
144
+ }, ie = "_title_1jkiw_1", oe = "_subtitle_1jkiw_5", ae = "_header_1jkiw_12", ce = "_text_1jkiw_13", le = "_top_1jkiw_20", re = "_itemsBlock_1jkiw_29", _t = {
145
+ title: ie,
146
+ subtitle: oe,
147
+ header: ae,
148
+ text: ce,
149
+ top: le,
150
+ itemsBlock: re
151
+ }, de = "_typeTexts_167ez_1", ue = "_block_167ez_8", me = "_active_167ez_25", jt = {
152
+ typeTexts: de,
153
+ block: ue,
154
+ active: me
155
+ }, _e = ["bold", "italic", "underline", "strike-through", "code"], Lt = (r) => {
156
+ const { typesText: a, setTypesText: e } = r;
142
157
  function s(i) {
143
158
  switch (i) {
144
159
  case "bold":
@@ -153,25 +168,25 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
153
168
  return "TextUnderline";
154
169
  }
155
170
  }
156
- return /* @__PURE__ */ t.jsx("div", { className: vt.typeTexts, children: me.map((i) => /* @__PURE__ */ t.jsx(
171
+ return /* @__PURE__ */ t.jsx("div", { className: jt.typeTexts, children: _e.map((i) => /* @__PURE__ */ t.jsx(
157
172
  "div",
158
173
  {
159
- className: z(vt.block, {
160
- [vt.active]: c.includes(i)
174
+ className: F(jt.block, {
175
+ [jt.active]: a.includes(i)
161
176
  }),
162
177
  onClick: () => {
163
- const a = [...c];
164
- if (a.includes(i)) {
165
- const l = a.filter((m) => m !== i);
178
+ const o = [...a];
179
+ if (o.includes(i)) {
180
+ const l = o.filter((d) => d !== i);
166
181
  e(l);
167
182
  } else
168
- a.push(i), e(a);
183
+ o.push(i), e(o);
169
184
  },
170
185
  children: /* @__PURE__ */ t.jsx(
171
- b,
186
+ v,
172
187
  {
173
188
  name: s(i),
174
- fill: c.includes(i) ? "#252525" : "#757575",
189
+ fill: a.includes(i) ? "#252525" : "#757575",
175
190
  width: 20,
176
191
  height: 20
177
192
  }
@@ -181,32 +196,32 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
181
196
  )) });
182
197
  }, Rt = (r) => {
183
198
  const {
184
- typesText: c,
199
+ typesText: a,
185
200
  isActiveText: e,
186
201
  setIsActiveText: s,
187
202
  text: i,
188
- setText: a,
203
+ setText: o,
189
204
  setTypesText: l,
190
- title: m,
205
+ title: d,
191
206
  subtitle: n = "Items"
192
207
  } = r;
193
- return /* @__PURE__ */ t.jsxs("div", { className: ht.text, children: [
194
- (m || e !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: ht.top, children: [
195
- m && /* @__PURE__ */ t.jsx("h3", { className: ht.title, children: m }),
208
+ return /* @__PURE__ */ t.jsxs("div", { className: _t.text, children: [
209
+ (d || e !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: _t.top, children: [
210
+ d && /* @__PURE__ */ t.jsx("h3", { className: _t.title, children: d }),
196
211
  e !== void 0 && s && /* @__PURE__ */ t.jsx(
197
212
  Z,
198
213
  {
199
214
  current: e,
200
- onChange: (o) => s(o)
215
+ onChange: (c) => s(c)
201
216
  }
202
217
  )
203
218
  ] }),
204
- /* @__PURE__ */ t.jsxs("div", { className: ht.itemsBlock, children: [
205
- /* @__PURE__ */ t.jsx("h5", { className: ht.subtitle, children: n }),
219
+ /* @__PURE__ */ t.jsxs("div", { className: _t.itemsBlock, children: [
220
+ /* @__PURE__ */ t.jsx("h5", { className: _t.subtitle, children: n }),
206
221
  /* @__PURE__ */ t.jsx(
207
222
  Ot,
208
223
  {
209
- onChange: (o) => a(o),
224
+ onChange: (c) => o(c),
210
225
  value: i,
211
226
  maxLength: 150
212
227
  }
@@ -214,47 +229,48 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
214
229
  /* @__PURE__ */ t.jsx(
215
230
  Lt,
216
231
  {
217
- typesText: c,
232
+ typesText: a,
218
233
  setTypesText: l
219
234
  }
220
235
  )
221
236
  ] })
222
237
  ] });
223
- }, he = "_title_157lh_1", _e = "_subtitle_157lh_5", pe = "_header_157lh_12", ge = "_text_157lh_13", fe = "_productsBlock_157lh_14", xe = "_top_157lh_26", je = "_itemsBlock_157lh_35", be = "_typeTexts_157lh_41", ve = "_block_157lh_48", ye = "_active_157lh_61", ke = "_products_157lh_14", $e = "_product_157lh_14", Ne = "_button_157lh_80", Ie = "_disabled_157lh_91", we = "_image_157lh_95", Ce = "_info_157lh_102", Be = "_name_157lh_114", Se = "_buttons_157lh_118", Te = "_modal_157lh_125", Pe = "_link_157lh_145", Ae = "_modalOptions_157lh_151", Oe = "_addButton_157lh_163", qe = "_deleteButton_157lh_178", H = {
238
+ }, he = "_title_xma5o_1", pe = "_subtitle_xma5o_5", ge = "_header_xma5o_12", xe = "_text_xma5o_13", fe = "_productsBlock_xma5o_14", be = "_top_xma5o_26", ve = "_itemsBlock_xma5o_35", je = "_typeTexts_xma5o_41", ye = "_block_xma5o_48", ke = "_active_xma5o_61", Ie = "_products_xma5o_14", $e = "_product_xma5o_14", Ne = "_button_xma5o_80", we = "_disabled_xma5o_91", Ce = "_image_xma5o_95", Be = "_info_xma5o_102", Se = "_name_xma5o_114", Te = "_buttons_xma5o_118", Pe = "_modal_xma5o_125", Ae = "_link_xma5o_145", Oe = "_modalOptions_xma5o_151", qe = "_addButton_xma5o_165", Ee = "_deleteButton_xma5o_180", De = "_closeIcon_xma5o_192", M = {
224
239
  title: he,
225
- subtitle: _e,
226
- header: pe,
227
- text: ge,
240
+ subtitle: pe,
241
+ header: ge,
242
+ text: xe,
228
243
  productsBlock: fe,
229
- top: xe,
230
- itemsBlock: je,
231
- typeTexts: be,
232
- block: ve,
233
- active: ye,
234
- products: ke,
244
+ top: be,
245
+ itemsBlock: ve,
246
+ typeTexts: je,
247
+ block: ye,
248
+ active: ke,
249
+ products: Ie,
235
250
  product: $e,
236
251
  button: Ne,
237
- disabled: Ie,
238
- image: we,
239
- info: Ce,
240
- name: Be,
241
- buttons: Se,
242
- modal: Te,
243
- link: Pe,
244
- modalOptions: Ae,
245
- addButton: Oe,
246
- deleteButton: qe
247
- }, Ee = g.forwardRef(
248
- (r, c) => {
249
- const { activeItem: e, setActiveItem: s, popupPosition: i, modalOptions: a, setIsOpenModal: l } = r;
250
- function m(n, o) {
251
- return n.length > o ? `${n.slice(0, o)}...` : n;
252
+ disabled: we,
253
+ image: Ce,
254
+ info: Be,
255
+ name: Se,
256
+ buttons: Te,
257
+ modal: Pe,
258
+ link: Ae,
259
+ modalOptions: Oe,
260
+ addButton: qe,
261
+ deleteButton: Ee,
262
+ closeIcon: De
263
+ }, Le = p.forwardRef(
264
+ (r, a) => {
265
+ const { activeItem: e, setActiveItem: s, popupPosition: i, modalOptions: o, setIsOpenModal: l } = r;
266
+ function d(n, c) {
267
+ return n.length > c ? `${n.slice(0, c)}...` : n;
252
268
  }
253
269
  return /* @__PURE__ */ t.jsxs(
254
270
  "div",
255
271
  {
256
- ref: c,
257
- className: H.modal,
272
+ ref: a,
273
+ className: M.modal,
258
274
  onClick: (n) => {
259
275
  n.stopPropagation();
260
276
  },
@@ -263,34 +279,33 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
263
279
  left: `${i.left}px`
264
280
  },
265
281
  children: [
266
- /* @__PURE__ */ t.jsxs("div", { className: H.top, children: [
267
- /* @__PURE__ */ t.jsx("h3", { className: H.title, children: m(e.name, 20) }),
268
- /* @__PURE__ */ t.jsx(
269
- b,
282
+ /* @__PURE__ */ t.jsxs("div", { className: M.top, children: [
283
+ /* @__PURE__ */ t.jsx("h3", { className: M.title, children: d(e.name, 20) }),
284
+ /* @__PURE__ */ t.jsx("div", { className: M.closeIcon, children: /* @__PURE__ */ t.jsx(
285
+ v,
270
286
  {
271
287
  name: "X",
272
288
  height: 20,
273
289
  width: 20,
274
- hoverable: !0,
275
290
  onClick: () => {
276
291
  s(null), l(!1);
277
292
  }
278
293
  }
279
- )
294
+ ) })
280
295
  ] }),
281
- /* @__PURE__ */ t.jsx("div", { className: H.modalOptions, children: a.map((n) => {
296
+ /* @__PURE__ */ t.jsx("div", { className: M.modalOptions, children: o.map((n) => {
282
297
  if (n.type === "image")
283
298
  return /* @__PURE__ */ t.jsx(
284
299
  gt,
285
300
  {
286
301
  label: "Put up an attractive image",
287
302
  activeImage: e[n.field],
288
- onChange: (o) => {
289
- const x = {
303
+ onChange: (c) => {
304
+ const b = {
290
305
  ...e,
291
- [n.field]: o
306
+ [n.field]: c
292
307
  };
293
- s(x);
308
+ s(b);
294
309
  }
295
310
  },
296
311
  String(n.field)
@@ -300,20 +315,20 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
300
315
  Rt,
301
316
  {
302
317
  typesText: e[n.field.type],
303
- setTypesText: (o) => {
304
- const x = {
318
+ setTypesText: (c) => {
319
+ const b = {
305
320
  ...e,
306
- [n.field.type]: o
321
+ [n.field.type]: c
307
322
  };
308
- s(x);
323
+ s(b);
309
324
  },
310
325
  text: e[n.field.text] || "",
311
- setText: (o) => {
312
- const x = {
326
+ setText: (c) => {
327
+ const b = {
313
328
  ...e,
314
- [n.field.text]: o
329
+ [n.field.text]: c
315
330
  };
316
- s(x);
331
+ s(b);
317
332
  },
318
333
  subtitle: n.label
319
334
  }
@@ -322,12 +337,12 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
322
337
  return /* @__PURE__ */ t.jsx(
323
338
  W,
324
339
  {
325
- onChange: (o) => {
326
- const x = {
340
+ onChange: (c) => {
341
+ const b = {
327
342
  ...e,
328
- [n.field]: o
343
+ [n.field]: c
329
344
  };
330
- s(x);
345
+ s(b);
331
346
  },
332
347
  value: e[n.field] || "",
333
348
  label: n.label,
@@ -335,16 +350,16 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
335
350
  }
336
351
  );
337
352
  if (n.type === "inputSwitch")
338
- return /* @__PURE__ */ t.jsxs("div", { className: H.link, children: [
353
+ return /* @__PURE__ */ t.jsxs("div", { className: M.link, children: [
339
354
  /* @__PURE__ */ t.jsx(
340
355
  W,
341
356
  {
342
- onChange: (o) => {
343
- const x = {
357
+ onChange: (c) => {
358
+ const b = {
344
359
  ...e,
345
- [n.field.text]: o
360
+ [n.field.text]: c
346
361
  };
347
- s(x);
362
+ s(b);
348
363
  },
349
364
  value: e[n.field.text] || "",
350
365
  label: n.inputLabel,
@@ -356,27 +371,27 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
356
371
  {
357
372
  current: !!e[n.field.switch] || !1,
358
373
  label: n.switchLabel,
359
- onChange: (o) => {
360
- const x = {
374
+ onChange: (c) => {
375
+ const b = {
361
376
  ...e,
362
- [n.field.switch]: o
377
+ [n.field.switch]: c
363
378
  };
364
- s(x);
379
+ s(b);
365
380
  }
366
381
  }
367
382
  )
368
383
  ] });
369
384
  if (n.type === "list")
370
385
  return /* @__PURE__ */ t.jsx(
371
- He,
386
+ Fe,
372
387
  {
373
388
  items: e[n.field] || [],
374
- setItems: (o) => {
375
- const x = {
389
+ setItems: (c) => {
390
+ const b = {
376
391
  ...e,
377
- [n.field]: o
392
+ [n.field]: c
378
393
  };
379
- s(x);
394
+ s(b);
380
395
  },
381
396
  itemsType: "select",
382
397
  draggable: n.draggable || !1,
@@ -392,16 +407,16 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
392
407
  st,
393
408
  {
394
409
  options: n.itemsOptions,
395
- onChange: (o) => {
396
- const x = {
410
+ onChange: (c) => {
411
+ const b = {
397
412
  ...e,
398
- [n.field]: o
413
+ [n.field]: c
399
414
  };
400
- s(x);
415
+ s(b);
401
416
  },
402
417
  label: n.label,
403
418
  value: e[n.field] || "String",
404
- leftAddon: n.leftAddon && n.leftAddon === "icon" && /* @__PURE__ */ t.jsx(b, { name: e[n.field] })
419
+ leftAddon: n.leftAddon && n.leftAddon === "icon" && /* @__PURE__ */ t.jsx(v, { name: e[n.field] })
405
420
  }
406
421
  );
407
422
  }) })
@@ -409,19 +424,19 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
409
424
  }
410
425
  );
411
426
  }
412
- ), De = "_other_g74jx_1", Le = "_subtitle_g74jx_7", Re = "_items_g74jx_14", yt = {
413
- other: De,
414
- subtitle: Le,
415
- items: Re
416
- }, bt = (r) => {
417
- const { items: c, title: e = "Other" } = r;
427
+ ), Re = "_other_g74jx_1", Me = "_subtitle_g74jx_7", He = "_items_g74jx_14", yt = {
428
+ other: Re,
429
+ subtitle: Me,
430
+ items: He
431
+ }, vt = (r) => {
432
+ const { items: a, title: e = "Other" } = r;
418
433
  return /* @__PURE__ */ t.jsxs("div", { className: yt.other, children: [
419
434
  /* @__PURE__ */ t.jsx("h5", { className: yt.subtitle, children: e }),
420
- /* @__PURE__ */ t.jsx("div", { className: yt.items, children: c.map((s, i) => /* @__PURE__ */ t.jsx(
435
+ /* @__PURE__ */ t.jsx("div", { className: yt.items, children: a.map((s, i) => /* @__PURE__ */ t.jsx(
421
436
  Z,
422
437
  {
423
438
  current: s.isItem,
424
- onChange: (a) => s.setIsItem(a),
439
+ onChange: (o) => s.setIsItem(o),
425
440
  label: s.label,
426
441
  hasBackground: !0,
427
442
  paddingless: !1
@@ -430,18 +445,18 @@ const Ft = "_wrapper_3ibiw_2", Vt = "_alignmentBlock_3ibiw_8", Ut = "_title_3ibi
430
445
  )) })
431
446
  ] });
432
447
  };
433
- function Me({ product: r, children: c }) {
448
+ function ze({ product: r, children: a }) {
434
449
  const {
435
450
  attributes: e,
436
451
  listeners: s,
437
452
  setNodeRef: i,
438
- transform: a,
453
+ transform: o,
439
454
  transition: l,
440
- isDragging: m
455
+ isDragging: d
441
456
  } = St({
442
457
  id: r.id
443
458
  }), n = {
444
- transform: Tt.Transform.toString(a),
459
+ transform: Tt.Transform.toString(o),
445
460
  transition: l
446
461
  };
447
462
  return /* @__PURE__ */ t.jsx(
@@ -449,88 +464,88 @@ function Me({ product: r, children: c }) {
449
464
  {
450
465
  ref: i,
451
466
  style: n,
452
- className: `${H.product} ${m ? H.dragging : ""}`,
467
+ className: `${M.product} ${d ? M.dragging : ""}`,
453
468
  ...e,
454
469
  ...s,
455
- children: c
470
+ children: a
456
471
  }
457
472
  );
458
473
  }
459
- const He = (r) => {
474
+ const Fe = (r) => {
460
475
  const {
461
- isActiveItems: c,
476
+ isActiveItems: a,
462
477
  setIsActiveItems: e,
463
478
  items: s,
464
479
  setItems: i,
465
- other: a,
480
+ other: o,
466
481
  title: l,
467
- subtitle: m,
482
+ subtitle: d,
468
483
  editable: n = !0,
469
- draggable: o = !1,
470
- withImage: x = !1,
471
- deletable: $ = !0,
472
- addable: _ = !0,
473
- itemsType: h,
474
- itemsPlaceholder: p = "",
475
- itemsOptions: d,
484
+ draggable: c = !1,
485
+ withImage: b = !1,
486
+ deletable: x = !0,
487
+ addable: h = !0,
488
+ itemsType: _,
489
+ itemsPlaceholder: g = "",
490
+ itemsOptions: u,
476
491
  hasRangeSelector: w = !1,
477
492
  rangeSelectorOptions: q,
478
- modalOptions: y,
493
+ modalOptions: k,
479
494
  addableOptions: L = {},
480
495
  limit: B,
481
496
  autoScrollInterval: S
482
- } = r, [f, D] = g.useState(null), [X, tt] = g.useState({
497
+ } = r, [f, D] = p.useState(null), [X, tt] = p.useState({
483
498
  top: 0,
484
499
  left: 0
485
- }), [v, N] = g.useState(null), E = g.useRef(null), [G, A] = g.useState(!1), M = $t(
486
- Nt(Bt, {
500
+ }), [y, $] = p.useState(null), E = p.useRef(null), [G, A] = p.useState(!1), H = It(
501
+ $t(Bt, {
487
502
  activationConstraint: {
488
503
  distance: 5
489
504
  }
490
505
  })
491
506
  );
492
- g.useEffect(() => {
493
- const u = () => {
507
+ p.useEffect(() => {
508
+ const m = () => {
494
509
  D(null), A(!1);
495
510
  };
496
- return document.body.addEventListener("click", u), D(null), A(!1), () => {
497
- D(null), A(!1), document.body.removeEventListener("click", u);
511
+ return document.body.addEventListener("click", m), D(null), A(!1), () => {
512
+ D(null), A(!1), document.body.removeEventListener("click", m);
498
513
  };
499
- }, []), g.useEffect(() => {
514
+ }, []), p.useEffect(() => {
500
515
  if (f) {
501
- const u = [...s].map((k) => k.id === f.id ? f : k);
502
- i(u);
516
+ const m = [...s].map((I) => I.id === f.id ? f : I);
517
+ i(m);
503
518
  }
504
- }, [f]), g.useEffect(() => {
505
- if (E.current && v) {
506
- const u = E.current.getBoundingClientRect().height, k = window.innerHeight;
507
- let T = v.top;
508
- T + u > k + window.scrollY - 200 && (T = k + window.scrollY - u - 200), T < 0 && (T = 10), tt({
519
+ }, [f]), p.useEffect(() => {
520
+ if (E.current && y) {
521
+ const m = E.current.getBoundingClientRect().height, I = window.innerHeight;
522
+ let T = y.top;
523
+ T + m > I + window.scrollY - 200 && (T = I + window.scrollY - m - 200), T < 0 && (T = 10), tt({
509
524
  top: T,
510
- left: v.left
525
+ left: y.left
511
526
  });
512
527
  }
513
- }, [E.current, v]);
514
- const K = (u, k) => {
515
- u.stopPropagation();
516
- const T = u.target.getBoundingClientRect();
517
- N({
528
+ }, [E.current, y]);
529
+ const K = (m, I) => {
530
+ m.stopPropagation();
531
+ const T = m.target.getBoundingClientRect();
532
+ $({
518
533
  top: T.top + window.scrollY,
519
534
  left: T.left - 30
520
- }), D(k), A(!0);
535
+ }), D(I), A(!0);
521
536
  };
522
- function ct(u) {
523
- if (x)
524
- return u ? /* @__PURE__ */ t.jsx(
537
+ function lt(m) {
538
+ if (b)
539
+ return m ? /* @__PURE__ */ t.jsx(
525
540
  "img",
526
541
  {
527
- src: `https://imagedelivery.net/${u[0]}/w=1000`,
542
+ src: `https://imagedelivery.net/${m[0]}/w=1000`,
528
543
  alt: "image",
529
544
  width: 16,
530
545
  height: 16
531
546
  }
532
547
  ) : /* @__PURE__ */ t.jsx(
533
- b,
548
+ v,
534
549
  {
535
550
  name: "Image",
536
551
  width: 16,
@@ -539,20 +554,20 @@ const He = (r) => {
539
554
  }
540
555
  );
541
556
  }
542
- const j = (u) => {
543
- const { active: k, over: T } = u;
544
- if (T && k.id !== T.id) {
545
- const R = s.findIndex((P) => P.id === k.id), V = s.findIndex((P) => P.id === T.id);
546
- if (R !== -1 && V !== -1) {
547
- const P = [...s], [lt] = P.splice(R, 1);
548
- P.splice(V, 0, lt), i(P);
557
+ const j = (m) => {
558
+ const { active: I, over: T } = m;
559
+ if (T && I.id !== T.id) {
560
+ const R = s.findIndex((P) => P.id === I.id), U = s.findIndex((P) => P.id === T.id);
561
+ if (R !== -1 && U !== -1) {
562
+ const P = [...s], [rt] = P.splice(R, 1);
563
+ P.splice(U, 0, rt), i(P);
549
564
  }
550
565
  }
551
- }, O = (u, k) => {
552
- var R, V;
566
+ }, O = (m, I) => {
567
+ var R, U;
553
568
  const T = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
554
- o && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
555
- b,
569
+ c && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
570
+ v,
556
571
  {
557
572
  name: "DotsSixVertical",
558
573
  hoverable: !0,
@@ -560,135 +575,135 @@ const He = (r) => {
560
575
  height: 20
561
576
  }
562
577
  ) }),
563
- h === "select" && d && /* @__PURE__ */ t.jsx(
578
+ _ === "select" && u && /* @__PURE__ */ t.jsx(
564
579
  st,
565
580
  {
566
581
  onChange: (P) => {
567
- const lt = [...s], ut = d.find((ft) => ft.name === P);
582
+ const rt = [...s], ut = u.find((xt) => xt.name === P);
568
583
  if (!ut) return;
569
- const rt = lt.map((ft) => ft.id === u.id ? {
584
+ const dt = rt.map((xt) => xt.id === m.id ? {
570
585
  ...ut,
571
586
  name: P
572
- } : ft);
587
+ } : xt);
573
588
  D({
574
- ...u,
589
+ ...m,
575
590
  name: P
576
- }), i([...rt]);
591
+ }), i([...dt]);
577
592
  },
578
- value: u.name,
579
- options: d.filter((P) => !s.find((lt) => lt.name === P.name)).map((P) => P.name),
580
- leftAddon: ct(u.images)
593
+ value: m.name,
594
+ options: u.filter((P) => !s.find((rt) => rt.name === P.name)).map((P) => P.name),
595
+ leftAddon: lt(m.images)
581
596
  }
582
597
  ),
583
- h === "input" && /* @__PURE__ */ t.jsx(
598
+ _ === "input" && /* @__PURE__ */ t.jsx(
584
599
  W,
585
600
  {
586
601
  onChange: (P) => {
587
- const ut = [...s].map((rt) => rt.id === u.id ? {
588
- ...u,
602
+ const ut = [...s].map((dt) => dt.id === m.id ? {
603
+ ...m,
589
604
  name: P
590
- } : rt);
605
+ } : dt);
591
606
  i([...ut]);
592
607
  },
593
- value: u.name,
594
- placeholder: p
608
+ value: m.name,
609
+ placeholder: g
595
610
  }
596
611
  ),
597
- h === "image" && /* @__PURE__ */ t.jsx(
612
+ _ === "image" && /* @__PURE__ */ t.jsx(
598
613
  gt,
599
614
  {
600
615
  onChange: (P) => {
601
- const ut = [...s].map((rt) => rt.id === u.id ? {
602
- ...u,
616
+ const ut = [...s].map((dt) => dt.id === m.id ? {
617
+ ...m,
603
618
  images: P
604
- } : rt);
619
+ } : dt);
605
620
  i([...ut]);
606
621
  },
607
- activeImage: (R = s.find((P) => P.id === u.id)) != null && R.images ? (V = s.find((P) => P.id === u.id)) == null ? void 0 : V.images[0] : void 0
622
+ activeImage: (R = s.find((P) => P.id === m.id)) != null && R.images ? (U = s.find((P) => P.id === m.id)) == null ? void 0 : U.images[0] : void 0
608
623
  }
609
624
  ),
610
- /* @__PURE__ */ t.jsxs("div", { className: H.buttons, children: [
611
- n && /* @__PURE__ */ t.jsx("div", { className: H.deleteButton, children: /* @__PURE__ */ t.jsx(
612
- b,
625
+ /* @__PURE__ */ t.jsxs("div", { className: M.buttons, children: [
626
+ n && /* @__PURE__ */ t.jsx("div", { className: M.deleteButton, children: /* @__PURE__ */ t.jsx(
627
+ v,
613
628
  {
614
629
  name: "Sliders",
615
630
  hoverable: !0,
616
631
  width: 20,
617
632
  height: 20,
618
- onClick: (P) => K(P, u)
633
+ onClick: (P) => K(P, m)
619
634
  }
620
635
  ) }),
621
- $ && /* @__PURE__ */ t.jsx("div", { className: H.deleteButton, children: /* @__PURE__ */ t.jsx(
622
- b,
636
+ x && /* @__PURE__ */ t.jsx("div", { className: M.deleteButton, children: /* @__PURE__ */ t.jsx(
637
+ v,
623
638
  {
624
639
  name: "Trash",
625
640
  hoverable: !0,
626
641
  width: 20,
627
642
  height: 20,
628
643
  fill: "#C12A2A",
629
- onClick: () => i(s.filter((P) => P.id !== u.id))
644
+ onClick: () => i(s.filter((P) => P.id !== m.id))
630
645
  }
631
646
  ) })
632
647
  ] })
633
648
  ] });
634
- return o ? /* @__PURE__ */ t.jsx(
635
- Me,
649
+ return c ? /* @__PURE__ */ t.jsx(
650
+ ze,
636
651
  {
637
- product: u,
638
- index: k,
652
+ product: m,
653
+ index: I,
639
654
  children: T
640
655
  },
641
- u.id
656
+ m.id
642
657
  ) : /* @__PURE__ */ t.jsx(
643
658
  "div",
644
659
  {
645
- className: H.product,
660
+ className: M.product,
646
661
  children: T
647
662
  },
648
- u.id
663
+ m.id
649
664
  );
650
665
  };
651
- return /* @__PURE__ */ t.jsxs("div", { className: H.productsBlock, children: [
652
- (l || c !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: H.top, children: [
653
- l && /* @__PURE__ */ t.jsx("h3", { className: H.title, children: l }),
654
- c !== void 0 && /* @__PURE__ */ t.jsx(
666
+ return /* @__PURE__ */ t.jsxs("div", { className: M.productsBlock, children: [
667
+ (l || a !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: M.top, children: [
668
+ l && /* @__PURE__ */ t.jsx("h3", { className: M.title, children: l }),
669
+ a !== void 0 && /* @__PURE__ */ t.jsx(
655
670
  Z,
656
671
  {
657
- current: c,
658
- onChange: (u) => e == null ? void 0 : e(u)
672
+ current: a,
673
+ onChange: (m) => e == null ? void 0 : e(m)
659
674
  }
660
675
  )
661
676
  ] }),
662
- f && n && y && G && /* @__PURE__ */ t.jsx(
663
- Ee,
677
+ f && n && k && G && /* @__PURE__ */ t.jsx(
678
+ Le,
664
679
  {
665
680
  ref: E,
666
681
  activeItem: f,
667
682
  setActiveItem: D,
668
683
  popupPosition: X,
669
- modalOptions: y,
684
+ modalOptions: k,
670
685
  setIsOpenModal: A
671
686
  }
672
687
  ),
673
688
  w && q && /* @__PURE__ */ t.jsx(At, { ...q }),
674
- /* @__PURE__ */ t.jsxs("div", { className: H.products, children: [
675
- m && /* @__PURE__ */ t.jsx("h5", { className: H.subtitle, children: m }),
676
- o ? /* @__PURE__ */ t.jsx(
677
- It,
689
+ /* @__PURE__ */ t.jsxs("div", { className: M.products, children: [
690
+ d && /* @__PURE__ */ t.jsx("h5", { className: M.subtitle, children: d }),
691
+ c ? /* @__PURE__ */ t.jsx(
692
+ Nt,
678
693
  {
679
- sensors: M,
694
+ sensors: H,
680
695
  onDragEnd: j,
681
696
  children: /* @__PURE__ */ t.jsx(
682
697
  wt,
683
698
  {
684
- items: s.map((u) => u.id),
699
+ items: s.map((m) => m.id),
685
700
  strategy: Ct,
686
- children: s.map((u, k) => O(u, k))
701
+ children: s.map((m, I) => O(m, I))
687
702
  }
688
703
  )
689
704
  }
690
- ) : s.map((u, k) => O(u, k)),
691
- _ && /* @__PURE__ */ t.jsx(
705
+ ) : s.map((m, I) => O(m, I)),
706
+ h && /* @__PURE__ */ t.jsx(
692
707
  "div",
693
708
  {
694
709
  style: {
@@ -697,45 +712,45 @@ const He = (r) => {
697
712
  justifyContent: "center"
698
713
  },
699
714
  children: /* @__PURE__ */ t.jsx(
700
- at,
715
+ ct,
701
716
  {
702
717
  withoutHover: !0,
703
- className: z(H.button, {
704
- [H.disabled]: !!(B && B <= s.length || s.length === (d == null ? void 0 : d.length))
718
+ className: F(M.button, {
719
+ [M.disabled]: !!(B && B <= s.length || s.length === (u == null ? void 0 : u.length))
705
720
  }),
706
721
  size: "s",
707
- disabled: !!(B && B <= s.length || s.length === (d == null ? void 0 : d.length)),
722
+ disabled: !!(B && B <= s.length || s.length === (u == null ? void 0 : u.length)),
708
723
  onClick: () => {
709
- const u = [...s];
710
- let k = null;
711
- if (d) {
712
- for (let T = 0; T < d.length; T++)
713
- if (!s.find((R) => R.id === d[T].id)) {
714
- k = d[T];
724
+ const m = [...s];
725
+ let I = null;
726
+ if (u) {
727
+ for (let T = 0; T < u.length; T++)
728
+ if (!s.find((R) => R.id === u[T].id)) {
729
+ I = u[T];
715
730
  break;
716
731
  }
717
732
  }
718
- h === "select" && d ? u.push({
719
- name: k ? k.name : d[0].name,
720
- id: (k == null ? void 0 : k.id) || d[0].id,
733
+ _ === "select" && u ? m.push({
734
+ name: I ? I.name : u[0].name,
735
+ id: (I == null ? void 0 : I.id) || u[0].id,
721
736
  ...L
722
- }) : h === "input" ? u.push({
737
+ }) : _ === "input" ? m.push({
723
738
  name: "",
724
739
  id: mt(),
725
740
  ...L
726
- }) : u.push({
741
+ }) : m.push({
727
742
  name: `Image ${s.length + 1}`,
728
743
  id: mt(),
729
744
  ...L
730
- }), i(u);
745
+ }), i(m);
731
746
  },
732
747
  style: {
733
748
  width: "fit-content"
734
749
  },
735
- children: /* @__PURE__ */ t.jsxs("div", { className: H.addButton, children: [
750
+ children: /* @__PURE__ */ t.jsxs("div", { className: M.addButton, children: [
736
751
  /* @__PURE__ */ t.jsx("span", { children: "Add Option" }),
737
752
  /* @__PURE__ */ t.jsx(
738
- b,
753
+ v,
739
754
  {
740
755
  name: "Plus",
741
756
  width: 16,
@@ -748,14 +763,14 @@ const He = (r) => {
748
763
  }
749
764
  )
750
765
  ] }),
751
- a !== void 0 && /* @__PURE__ */ t.jsx(bt, { items: a }),
766
+ o !== void 0 && /* @__PURE__ */ t.jsx(vt, { items: o }),
752
767
  S !== void 0 && /* @__PURE__ */ t.jsx(
753
768
  W,
754
769
  {
755
770
  label: "Auto scroll interval",
756
771
  type: "number",
757
772
  value: String(S.scrollInterval),
758
- onChange: (u) => S.setScrollInterval(Number(u)),
773
+ onChange: (m) => S.setScrollInterval(Number(m)),
759
774
  min: 0.1,
760
775
  max: 100,
761
776
  style: {
@@ -765,60 +780,60 @@ const He = (r) => {
765
780
  }
766
781
  )
767
782
  ] });
768
- }, ze = "_title_82zux_1", Fe = "_subtitle_82zux_5", Ve = "_header_82zux_12", Ue = "_text_82zux_13", Ye = "_productsBlock_82zux_14", Ge = "_top_82zux_26", We = "_itemsBlock_82zux_35", Xe = "_typeTexts_82zux_41", Je = "_block_82zux_48", Qe = "_active_82zux_61", Ke = "_products_82zux_14", Ze = "_product_82zux_14", ts = "_button_82zux_80", es = "_disabled_82zux_91", ss = "_image_82zux_95", ns = "_info_82zux_102", is = "_name_82zux_114", os = "_buttons_82zux_118", as = "_modal_82zux_125", cs = "_link_82zux_145", ls = "_modalOptions_82zux_151", rs = "_addButton_82zux_157", ds = "_deleteButton_82zux_179", Q = {
769
- title: ze,
770
- subtitle: Fe,
771
- header: Ve,
772
- text: Ue,
773
- productsBlock: Ye,
774
- top: Ge,
775
- itemsBlock: We,
776
- typeTexts: Xe,
777
- block: Je,
778
- active: Qe,
779
- products: Ke,
780
- product: Ze,
781
- button: ts,
782
- disabled: es,
783
- image: ss,
784
- info: ns,
785
- name: is,
786
- buttons: os,
787
- modal: as,
788
- link: cs,
789
- modalOptions: ls,
790
- addButton: rs,
791
- deleteButton: ds
792
- }, oa = (r) => {
783
+ }, Ve = "_title_82zux_1", Ue = "_subtitle_82zux_5", Ye = "_header_82zux_12", Ge = "_text_82zux_13", We = "_productsBlock_82zux_14", Xe = "_top_82zux_26", Je = "_itemsBlock_82zux_35", Qe = "_typeTexts_82zux_41", Ke = "_block_82zux_48", Ze = "_active_82zux_61", ts = "_products_82zux_14", es = "_product_82zux_14", ss = "_button_82zux_80", ns = "_disabled_82zux_91", is = "_image_82zux_95", os = "_info_82zux_102", as = "_name_82zux_114", cs = "_buttons_82zux_118", ls = "_modal_82zux_125", rs = "_link_82zux_145", ds = "_modalOptions_82zux_151", us = "_addButton_82zux_157", ms = "_deleteButton_82zux_179", Q = {
784
+ title: Ve,
785
+ subtitle: Ue,
786
+ header: Ye,
787
+ text: Ge,
788
+ productsBlock: We,
789
+ top: Xe,
790
+ itemsBlock: Je,
791
+ typeTexts: Qe,
792
+ block: Ke,
793
+ active: Ze,
794
+ products: ts,
795
+ product: es,
796
+ button: ss,
797
+ disabled: ns,
798
+ image: is,
799
+ info: os,
800
+ name: as,
801
+ buttons: cs,
802
+ modal: ls,
803
+ link: rs,
804
+ modalOptions: ds,
805
+ addButton: us,
806
+ deleteButton: ms
807
+ }, da = (r) => {
793
808
  const {
794
- isActiveItems: c,
809
+ isActiveItems: a,
795
810
  setIsActiveItems: e,
796
811
  items: s,
797
812
  setItems: i,
798
- other: a,
813
+ other: o,
799
814
  title: l,
800
- subtitle: m,
815
+ subtitle: d,
801
816
  draggable: n = !1,
802
- withImage: o = !1,
803
- addable: x = !0,
804
- itemsOptions: $,
805
- hasRangeSelector: _ = !1,
806
- rangeSelectorOptions: h,
807
- limit: p,
808
- autoScrollInterval: d
817
+ withImage: c = !1,
818
+ addable: b = !0,
819
+ itemsOptions: x,
820
+ hasRangeSelector: h = !1,
821
+ rangeSelectorOptions: _,
822
+ limit: g,
823
+ autoScrollInterval: u
809
824
  } = r;
810
- function w(y) {
811
- if (o)
812
- return y ? /* @__PURE__ */ t.jsx(
825
+ function w(k) {
826
+ if (c)
827
+ return k ? /* @__PURE__ */ t.jsx(
813
828
  "img",
814
829
  {
815
- src: `https://imagedelivery.net/${y[0]}/w=1000`,
830
+ src: `https://imagedelivery.net/${k[0]}/w=1000`,
816
831
  alt: "image",
817
832
  width: 16,
818
833
  height: 16
819
834
  }
820
835
  ) : /* @__PURE__ */ t.jsx(
821
- b,
836
+ v,
822
837
  {
823
838
  name: "Image",
824
839
  width: 16,
@@ -827,12 +842,12 @@ const He = (r) => {
827
842
  }
828
843
  );
829
844
  }
830
- const q = (y) => {
831
- const L = $.find((S) => S.id === y);
845
+ const q = (k) => {
846
+ const L = x.find((S) => S.id === k);
832
847
  if (!L) return;
833
848
  const B = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
834
849
  n && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
835
- b,
850
+ v,
836
851
  {
837
852
  name: "DotsSixVertical",
838
853
  hoverable: !0,
@@ -844,25 +859,25 @@ const He = (r) => {
844
859
  st,
845
860
  {
846
861
  onChange: (S) => {
847
- const f = [...s], D = $.find((v) => v.name === S);
862
+ const f = [...s], D = x.find((y) => y.name === S);
848
863
  if (!D) return;
849
- const X = D.id, tt = f.map((v) => v === y ? X : v);
864
+ const X = D.id, tt = f.map((y) => y === k ? X : y);
850
865
  i([...tt]);
851
866
  },
852
867
  value: L.name,
853
- options: $.filter((S) => !s.find((f) => f === S.id)).map((S) => S.name),
868
+ options: x.filter((S) => !s.find((f) => f === S.id)).map((S) => S.name),
854
869
  leftAddon: w(L.images)
855
870
  }
856
871
  ),
857
872
  /* @__PURE__ */ t.jsx("div", { className: Q.buttons, children: /* @__PURE__ */ t.jsx("div", { className: Q.deleteButton, children: /* @__PURE__ */ t.jsx(
858
- b,
873
+ v,
859
874
  {
860
875
  name: "Trash",
861
876
  hoverable: !0,
862
877
  width: 20,
863
878
  height: 20,
864
879
  fill: "#C12A2A",
865
- onClick: () => i(s.filter((S) => S !== y))
880
+ onClick: () => i(s.filter((S) => S !== k))
866
881
  }
867
882
  ) }) })
868
883
  ] });
@@ -872,25 +887,25 @@ const He = (r) => {
872
887
  className: Q.product,
873
888
  children: B
874
889
  },
875
- y
890
+ k
876
891
  );
877
892
  };
878
893
  return /* @__PURE__ */ t.jsxs("div", { className: Q.productsBlock, children: [
879
- (l || c !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: Q.top, children: [
894
+ (l || a !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: Q.top, children: [
880
895
  l && /* @__PURE__ */ t.jsx("h3", { className: Q.title, children: l }),
881
- c !== void 0 && /* @__PURE__ */ t.jsx(
896
+ a !== void 0 && /* @__PURE__ */ t.jsx(
882
897
  Z,
883
898
  {
884
- current: c,
885
- onChange: (y) => e == null ? void 0 : e(y)
899
+ current: a,
900
+ onChange: (k) => e == null ? void 0 : e(k)
886
901
  }
887
902
  )
888
903
  ] }),
889
- _ && h && /* @__PURE__ */ t.jsx(At, { ...h }),
904
+ h && _ && /* @__PURE__ */ t.jsx(At, { ..._ }),
890
905
  /* @__PURE__ */ t.jsxs("div", { className: Q.products, children: [
891
- m && /* @__PURE__ */ t.jsx("h5", { className: Q.subtitle, children: m }),
892
- s.map((y) => q(y)),
893
- x && /* @__PURE__ */ t.jsx(
906
+ d && /* @__PURE__ */ t.jsx("h5", { className: Q.subtitle, children: d }),
907
+ s.map((k) => q(k)),
908
+ b && /* @__PURE__ */ t.jsx(
894
909
  "div",
895
910
  {
896
911
  style: {
@@ -900,25 +915,25 @@ const He = (r) => {
900
915
  gap: 5
901
916
  },
902
917
  children: /* @__PURE__ */ t.jsx(
903
- at,
918
+ ct,
904
919
  {
905
920
  withoutHover: !0,
906
- className: z(Q.button, {
907
- [Q.disabled]: !!(p && p <= s.length || s.length === $.length)
921
+ className: F(Q.button, {
922
+ [Q.disabled]: !!(g && g <= s.length || s.length === x.length)
908
923
  }),
909
924
  size: "s",
910
- disabled: !!(p && p <= s.length || s.length === $.length),
925
+ disabled: !!(g && g <= s.length || s.length === x.length),
911
926
  onClick: () => {
912
- const y = [...s];
927
+ const k = [...s];
913
928
  let L = null;
914
- if ($) {
915
- for (let B = 0; B < $.length; B++)
916
- if (!s.find((S) => S === $[B].id)) {
917
- L = $[B];
929
+ if (x) {
930
+ for (let B = 0; B < x.length; B++)
931
+ if (!s.find((S) => S === x[B].id)) {
932
+ L = x[B];
918
933
  break;
919
934
  }
920
935
  }
921
- y.push((L == null ? void 0 : L.id) || $[0].id), i(y);
936
+ k.push((L == null ? void 0 : L.id) || x[0].id), i(k);
922
937
  },
923
938
  style: {
924
939
  width: "fit-content"
@@ -926,7 +941,7 @@ const He = (r) => {
926
941
  children: /* @__PURE__ */ t.jsxs("div", { className: Q.addButton, children: [
927
942
  /* @__PURE__ */ t.jsx("span", { children: "Add Option" }),
928
943
  /* @__PURE__ */ t.jsx(
929
- b,
944
+ v,
930
945
  {
931
946
  name: "Plus",
932
947
  width: 16,
@@ -939,14 +954,14 @@ const He = (r) => {
939
954
  }
940
955
  )
941
956
  ] }),
942
- a !== void 0 && /* @__PURE__ */ t.jsx(bt, { items: a }),
943
- d !== void 0 && /* @__PURE__ */ t.jsx(
957
+ o !== void 0 && /* @__PURE__ */ t.jsx(vt, { items: o }),
958
+ u !== void 0 && /* @__PURE__ */ t.jsx(
944
959
  W,
945
960
  {
946
961
  label: "Auto scroll interval",
947
962
  type: "number",
948
- value: String(d.scrollInterval),
949
- onChange: (y) => d.setScrollInterval(Number(y)),
963
+ value: String(u.scrollInterval),
964
+ onChange: (k) => u.setScrollInterval(Number(k)),
950
965
  min: 0.1,
951
966
  max: 100,
952
967
  style: {
@@ -956,41 +971,42 @@ const He = (r) => {
956
971
  }
957
972
  )
958
973
  ] });
959
- }, us = "_title_fymju_1", ms = "_subtitle_fymju_5", hs = "_header_fymju_12", _s = "_text_fymju_13", ps = "_productsBlock_fymju_14", gs = "_top_fymju_26", fs = "_itemsBlock_fymju_35", xs = "_typeTexts_fymju_41", js = "_block_fymju_48", bs = "_active_fymju_61", vs = "_products_fymju_14", ys = "_product_fymju_14", ks = "_button_fymju_80", $s = "_disabled_fymju_91", Ns = "_image_fymju_95", Is = "_info_fymju_102", ws = "_name_fymju_114", Cs = "_buttons_fymju_118", Bs = "_modal_fymju_125", Ss = "_link_fymju_146", Ts = "_modalOptions_fymju_152", Ps = "_addButton_fymju_164", As = "_deleteButton_fymju_179", F = {
960
- title: us,
961
- subtitle: ms,
962
- header: hs,
963
- text: _s,
964
- productsBlock: ps,
965
- top: gs,
966
- itemsBlock: fs,
967
- typeTexts: xs,
974
+ }, _s = "_title_wjbkg_1", hs = "_subtitle_wjbkg_5", ps = "_header_wjbkg_12", gs = "_text_wjbkg_13", xs = "_productsBlock_wjbkg_14", fs = "_top_wjbkg_26", bs = "_itemsBlock_wjbkg_35", vs = "_typeTexts_wjbkg_41", js = "_block_wjbkg_48", ys = "_active_wjbkg_61", ks = "_products_wjbkg_14", Is = "_product_wjbkg_14", $s = "_button_wjbkg_80", Ns = "_disabled_wjbkg_91", ws = "_image_wjbkg_95", Cs = "_info_wjbkg_102", Bs = "_name_wjbkg_114", Ss = "_buttons_wjbkg_118", Ts = "_modal_wjbkg_125", Ps = "_link_wjbkg_146", As = "_modalOptions_wjbkg_152", Os = "_addButton_wjbkg_165", qs = "_deleteButton_wjbkg_180", Es = "_closeIcon_wjbkg_192", z = {
975
+ title: _s,
976
+ subtitle: hs,
977
+ header: ps,
978
+ text: gs,
979
+ productsBlock: xs,
980
+ top: fs,
981
+ itemsBlock: bs,
982
+ typeTexts: vs,
968
983
  block: js,
969
- active: bs,
970
- products: vs,
971
- product: ys,
972
- button: ks,
973
- disabled: $s,
974
- image: Ns,
975
- info: Is,
976
- name: ws,
977
- buttons: Cs,
978
- modal: Bs,
979
- link: Ss,
980
- modalOptions: Ts,
981
- addButton: Ps,
982
- deleteButton: As
983
- }, Os = g.forwardRef(
984
- (r, c) => {
985
- const { activeItem: e, setActiveItem: s, popupPosition: i, modalOptions: a, setIsOpenModal: l } = r;
986
- function m(n, o) {
987
- return n.length > o ? `${n.slice(0, o)}...` : n;
984
+ active: ys,
985
+ products: ks,
986
+ product: Is,
987
+ button: $s,
988
+ disabled: Ns,
989
+ image: ws,
990
+ info: Cs,
991
+ name: Bs,
992
+ buttons: Ss,
993
+ modal: Ts,
994
+ link: Ps,
995
+ modalOptions: As,
996
+ addButton: Os,
997
+ deleteButton: qs,
998
+ closeIcon: Es
999
+ }, Ds = p.forwardRef(
1000
+ (r, a) => {
1001
+ const { activeItem: e, setActiveItem: s, popupPosition: i, modalOptions: o, setIsOpenModal: l } = r;
1002
+ function d(n, c) {
1003
+ return n.length > c ? `${n.slice(0, c)}...` : n;
988
1004
  }
989
1005
  return /* @__PURE__ */ t.jsxs(
990
1006
  "div",
991
1007
  {
992
- ref: c,
993
- className: F.modal,
1008
+ ref: a,
1009
+ className: z.modal,
994
1010
  onClick: (n) => {
995
1011
  n.stopPropagation();
996
1012
  },
@@ -999,10 +1015,10 @@ const He = (r) => {
999
1015
  left: `${i.left}px`
1000
1016
  },
1001
1017
  children: [
1002
- /* @__PURE__ */ t.jsxs("div", { className: F.top, children: [
1003
- /* @__PURE__ */ t.jsx("h3", { className: F.title, children: m(e.name, 20) }),
1004
- /* @__PURE__ */ t.jsx(
1005
- b,
1018
+ /* @__PURE__ */ t.jsxs("div", { className: z.top, children: [
1019
+ /* @__PURE__ */ t.jsx("h3", { className: z.title, children: d(e.name, 20) }),
1020
+ /* @__PURE__ */ t.jsx("div", { className: z.closeIcon, children: /* @__PURE__ */ t.jsx(
1021
+ v,
1006
1022
  {
1007
1023
  name: "X",
1008
1024
  height: 20,
@@ -1012,21 +1028,21 @@ const He = (r) => {
1012
1028
  s(null), l(!1);
1013
1029
  }
1014
1030
  }
1015
- )
1031
+ ) })
1016
1032
  ] }),
1017
- /* @__PURE__ */ t.jsx("div", { className: F.modalOptions, children: a.map((n) => {
1033
+ /* @__PURE__ */ t.jsx("div", { className: z.modalOptions, children: o.map((n) => {
1018
1034
  if (n.type === "image")
1019
1035
  return /* @__PURE__ */ t.jsx(
1020
1036
  gt,
1021
1037
  {
1022
1038
  label: "Put up an attractive image",
1023
1039
  activeImage: e[n.field],
1024
- onChange: (o) => {
1025
- const x = {
1040
+ onChange: (c) => {
1041
+ const b = {
1026
1042
  ...e,
1027
- [n.field]: o
1043
+ [n.field]: c
1028
1044
  };
1029
- s(x);
1045
+ s(b);
1030
1046
  }
1031
1047
  },
1032
1048
  String(n.field)
@@ -1036,20 +1052,20 @@ const He = (r) => {
1036
1052
  Rt,
1037
1053
  {
1038
1054
  typesText: e[n.field.type],
1039
- setTypesText: (o) => {
1040
- const x = {
1055
+ setTypesText: (c) => {
1056
+ const b = {
1041
1057
  ...e,
1042
- [n.field.type]: o
1058
+ [n.field.type]: c
1043
1059
  };
1044
- s(x);
1060
+ s(b);
1045
1061
  },
1046
1062
  text: e[n.field.text] || "",
1047
- setText: (o) => {
1048
- const x = {
1063
+ setText: (c) => {
1064
+ const b = {
1049
1065
  ...e,
1050
- [n.field.text]: o
1066
+ [n.field.text]: c
1051
1067
  };
1052
- s(x);
1068
+ s(b);
1053
1069
  },
1054
1070
  subtitle: n.label
1055
1071
  }
@@ -1058,12 +1074,12 @@ const He = (r) => {
1058
1074
  return /* @__PURE__ */ t.jsx(
1059
1075
  W,
1060
1076
  {
1061
- onChange: (o) => {
1062
- const x = {
1077
+ onChange: (c) => {
1078
+ const b = {
1063
1079
  ...e,
1064
- [n.field]: o
1080
+ [n.field]: c
1065
1081
  };
1066
- s(x);
1082
+ s(b);
1067
1083
  },
1068
1084
  value: e[n.field] || "",
1069
1085
  label: n.label,
@@ -1071,16 +1087,16 @@ const He = (r) => {
1071
1087
  }
1072
1088
  );
1073
1089
  if (n.type === "inputSwitch")
1074
- return /* @__PURE__ */ t.jsxs("div", { className: F.link, children: [
1090
+ return /* @__PURE__ */ t.jsxs("div", { className: z.link, children: [
1075
1091
  /* @__PURE__ */ t.jsx(
1076
1092
  W,
1077
1093
  {
1078
- onChange: (o) => {
1079
- const x = {
1094
+ onChange: (c) => {
1095
+ const b = {
1080
1096
  ...e,
1081
- [n.field.text]: o
1097
+ [n.field.text]: c
1082
1098
  };
1083
- s(x);
1099
+ s(b);
1084
1100
  },
1085
1101
  value: e[n.field.text] || "",
1086
1102
  label: n.inputLabel,
@@ -1092,12 +1108,12 @@ const He = (r) => {
1092
1108
  {
1093
1109
  current: !!e[n.field.switch] || !1,
1094
1110
  label: n.switchLabel,
1095
- onChange: (o) => {
1096
- const x = {
1111
+ onChange: (c) => {
1112
+ const b = {
1097
1113
  ...e,
1098
- [n.field.switch]: o
1114
+ [n.field.switch]: c
1099
1115
  };
1100
- s(x);
1116
+ s(b);
1101
1117
  }
1102
1118
  }
1103
1119
  )
@@ -1107,16 +1123,16 @@ const He = (r) => {
1107
1123
  st,
1108
1124
  {
1109
1125
  options: n.itemsOptions,
1110
- onChange: (o) => {
1111
- const x = {
1126
+ onChange: (c) => {
1127
+ const b = {
1112
1128
  ...e,
1113
- [n.field]: o
1129
+ [n.field]: c
1114
1130
  };
1115
- s(x);
1131
+ s(b);
1116
1132
  },
1117
1133
  label: n.label,
1118
1134
  value: e[n.field] || "String",
1119
- leftAddon: n.leftAddon && n.leftAddon === "icon" && /* @__PURE__ */ t.jsx(b, { name: e[n.field] })
1135
+ leftAddon: n.leftAddon && n.leftAddon === "icon" && /* @__PURE__ */ t.jsx(v, { name: e[n.field] })
1120
1136
  }
1121
1137
  );
1122
1138
  }) })
@@ -1125,88 +1141,88 @@ const He = (r) => {
1125
1141
  );
1126
1142
  }
1127
1143
  );
1128
- function qs(r) {
1129
- const { product: c, children: e } = r, { attributes: s, listeners: i, setNodeRef: a, transform: l, transition: m, isDragging: n } = St({
1130
- id: c.id
1131
- }), o = {
1144
+ function Ls(r) {
1145
+ const { product: a, children: e } = r, { attributes: s, listeners: i, setNodeRef: o, transform: l, transition: d, isDragging: n } = St({
1146
+ id: a.id
1147
+ }), c = {
1132
1148
  transform: Tt.Transform.toString(l),
1133
- transition: m
1149
+ transition: d
1134
1150
  };
1135
1151
  return /* @__PURE__ */ t.jsx(
1136
1152
  "div",
1137
1153
  {
1138
- ref: a,
1139
- style: o,
1140
- className: `${F.product} ${n ? F.dragging : ""}`,
1154
+ ref: o,
1155
+ style: c,
1156
+ className: `${z.product} ${n ? z.dragging : ""}`,
1141
1157
  ...s,
1142
1158
  ...i,
1143
1159
  children: e
1144
1160
  }
1145
1161
  );
1146
1162
  }
1147
- const aa = (r) => {
1163
+ const ua = (r) => {
1148
1164
  const {
1149
- isActiveItems: c,
1165
+ isActiveItems: a,
1150
1166
  setIsActiveItems: e,
1151
1167
  items: s,
1152
1168
  setItems: i,
1153
- other: a,
1169
+ other: o,
1154
1170
  title: l,
1155
- subtitle: m,
1171
+ subtitle: d,
1156
1172
  editable: n = !0,
1157
- draggable: o = !1,
1158
- withImage: x = !1,
1159
- deletable: $ = !0,
1160
- addable: _ = !0,
1161
- itemsType: h,
1162
- itemsPlaceholder: p = "",
1163
- itemsOptions: d,
1173
+ draggable: c = !1,
1174
+ withImage: b = !1,
1175
+ deletable: x = !0,
1176
+ addable: h = !0,
1177
+ itemsType: _,
1178
+ itemsPlaceholder: g = "",
1179
+ itemsOptions: u,
1164
1180
  hasRangeSelector: w = !1,
1165
1181
  rangeSelectorOptions: q,
1166
- modalOptions: y,
1182
+ modalOptions: k,
1167
1183
  addableOptions: L = {}
1168
- } = r, [B, S] = g.useState(null), [f, D] = g.useState({
1184
+ } = r, [B, S] = p.useState(null), [f, D] = p.useState({
1169
1185
  top: 0,
1170
1186
  left: 0
1171
- }), [X, tt] = g.useState(null), v = g.useRef(null), [N, E] = g.useState(!1), G = $t(
1172
- Nt(Bt, {
1187
+ }), [X, tt] = p.useState(null), y = p.useRef(null), [$, E] = p.useState(!1), G = It(
1188
+ $t(Bt, {
1173
1189
  activationConstraint: {
1174
1190
  distance: 5
1175
1191
  }
1176
1192
  })
1177
1193
  );
1178
- g.useEffect(() => {
1194
+ p.useEffect(() => {
1179
1195
  const j = () => {
1180
1196
  S(null), E(!1);
1181
1197
  };
1182
1198
  return document.body.addEventListener("click", j), S(null), E(!1), () => {
1183
1199
  S(null), E(!1), document.body.removeEventListener("click", j);
1184
1200
  };
1185
- }, []), g.useEffect(() => {
1201
+ }, []), p.useEffect(() => {
1186
1202
  if (B) {
1187
1203
  const j = [...s].map((O) => O.id === B.id ? B : O);
1188
1204
  i(j);
1189
1205
  }
1190
- }, [B]), g.useEffect(() => {
1191
- if (v.current && X) {
1192
- const j = v.current.getBoundingClientRect().height, O = window.innerHeight;
1193
- let u = X.top;
1194
- u + j > O + window.scrollY - 200 && (u = O + window.scrollY - j - 200), u < 0 && (u = 10), D({
1195
- top: u,
1206
+ }, [B]), p.useEffect(() => {
1207
+ if (y.current && X) {
1208
+ const j = y.current.getBoundingClientRect().height, O = window.innerHeight;
1209
+ let m = X.top;
1210
+ m + j > O + window.scrollY - 200 && (m = O + window.scrollY - j - 200), m < 0 && (m = 10), D({
1211
+ top: m,
1196
1212
  left: X.left
1197
1213
  });
1198
1214
  }
1199
- }, [v.current, X]);
1215
+ }, [y.current, X]);
1200
1216
  const A = (j, O) => {
1201
1217
  j.stopPropagation();
1202
- const u = j.target.getBoundingClientRect();
1218
+ const m = j.target.getBoundingClientRect();
1203
1219
  tt({
1204
- top: u.top + window.scrollY,
1205
- left: u.left - 30
1220
+ top: m.top + window.scrollY,
1221
+ left: m.left - 30
1206
1222
  }), S(O), E(!0);
1207
1223
  };
1208
- function M(j) {
1209
- if (x)
1224
+ function H(j) {
1225
+ if (b)
1210
1226
  return j ? /* @__PURE__ */ t.jsx(
1211
1227
  "img",
1212
1228
  {
@@ -1216,7 +1232,7 @@ const aa = (r) => {
1216
1232
  height: 16
1217
1233
  }
1218
1234
  ) : /* @__PURE__ */ t.jsx(
1219
- b,
1235
+ v,
1220
1236
  {
1221
1237
  name: "Image",
1222
1238
  width: 16,
@@ -1226,19 +1242,19 @@ const aa = (r) => {
1226
1242
  );
1227
1243
  }
1228
1244
  const K = (j) => {
1229
- const { active: O, over: u } = j;
1230
- if (u && O.id !== u.id) {
1231
- const k = s.findIndex((R) => R.id === O.id), T = s.findIndex((R) => R.id === u.id);
1232
- if (k !== -1 && T !== -1) {
1233
- const R = [...s], [V] = R.splice(k, 1);
1234
- R.splice(T, 0, V), i(R);
1245
+ const { active: O, over: m } = j;
1246
+ if (m && O.id !== m.id) {
1247
+ const I = s.findIndex((R) => R.id === O.id), T = s.findIndex((R) => R.id === m.id);
1248
+ if (I !== -1 && T !== -1) {
1249
+ const R = [...s], [U] = R.splice(I, 1);
1250
+ R.splice(T, 0, U), i(R);
1235
1251
  }
1236
1252
  }
1237
- }, ct = (j) => {
1238
- var u;
1253
+ }, lt = (j) => {
1254
+ var m;
1239
1255
  const O = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
1240
- o && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
1241
- b,
1256
+ c && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
1257
+ v,
1242
1258
  {
1243
1259
  name: "DotsSixVertical",
1244
1260
  hoverable: !0,
@@ -1246,77 +1262,77 @@ const aa = (r) => {
1246
1262
  height: 20
1247
1263
  }
1248
1264
  ) }),
1249
- h === "select" && d && /* @__PURE__ */ t.jsx(
1265
+ _ === "select" && u && /* @__PURE__ */ t.jsx(
1250
1266
  st,
1251
1267
  {
1252
- onChange: (k) => {
1253
- const R = [...s].map((V) => V.id === j.id ? {
1268
+ onChange: (I) => {
1269
+ const R = [...s].map((U) => U.id === j.id ? {
1254
1270
  ...j,
1255
- name: k
1256
- } : V);
1271
+ name: I
1272
+ } : U);
1257
1273
  S({
1258
1274
  ...j,
1259
- name: k
1275
+ name: I
1260
1276
  }), i([...R]);
1261
1277
  },
1262
1278
  value: j.name,
1263
- options: d.filter((k) => !s.find((T) => T.name === k)),
1264
- leftAddon: M(j.images)
1279
+ options: u.filter((I) => !s.find((T) => T.name === I)),
1280
+ leftAddon: H(j.images)
1265
1281
  }
1266
1282
  ),
1267
- h === "input" && /* @__PURE__ */ t.jsx(
1283
+ _ === "input" && /* @__PURE__ */ t.jsx(
1268
1284
  W,
1269
1285
  {
1270
- onChange: (k) => {
1271
- const R = [...s].map((V) => V.id === j.id ? {
1286
+ onChange: (I) => {
1287
+ const R = [...s].map((U) => U.id === j.id ? {
1272
1288
  ...j,
1273
- name: k
1274
- } : V);
1289
+ name: I
1290
+ } : U);
1275
1291
  i([...R]);
1276
1292
  },
1277
1293
  value: j.name,
1278
- placeholder: p
1294
+ placeholder: g
1279
1295
  }
1280
1296
  ),
1281
- h === "image" && /* @__PURE__ */ t.jsx(
1297
+ _ === "image" && /* @__PURE__ */ t.jsx(
1282
1298
  gt,
1283
1299
  {
1284
- onChange: (k) => {
1285
- const R = [...s].map((V) => V.id === j.id ? {
1300
+ onChange: (I) => {
1301
+ const R = [...s].map((U) => U.id === j.id ? {
1286
1302
  ...j,
1287
- images: k
1288
- } : V);
1303
+ images: I
1304
+ } : U);
1289
1305
  i([...R]);
1290
1306
  },
1291
- activeImage: (u = s.find((k) => k.id === j.id)) == null ? void 0 : u.images[0]
1307
+ activeImage: (m = s.find((I) => I.id === j.id)) == null ? void 0 : m.images[0]
1292
1308
  }
1293
1309
  ),
1294
- /* @__PURE__ */ t.jsxs("div", { className: F.buttons, children: [
1295
- n && /* @__PURE__ */ t.jsx("div", { className: F.deleteButton, children: /* @__PURE__ */ t.jsx(
1296
- b,
1310
+ /* @__PURE__ */ t.jsxs("div", { className: z.buttons, children: [
1311
+ n && /* @__PURE__ */ t.jsx("div", { className: z.deleteButton, children: /* @__PURE__ */ t.jsx(
1312
+ v,
1297
1313
  {
1298
1314
  name: "Sliders",
1299
1315
  hoverable: !0,
1300
1316
  width: 20,
1301
1317
  height: 20,
1302
- onClick: (k) => A(k, j)
1318
+ onClick: (I) => A(I, j)
1303
1319
  }
1304
1320
  ) }),
1305
- $ && /* @__PURE__ */ t.jsx("div", { className: F.deleteButton, children: /* @__PURE__ */ t.jsx(
1306
- b,
1321
+ x && /* @__PURE__ */ t.jsx("div", { className: z.deleteButton, children: /* @__PURE__ */ t.jsx(
1322
+ v,
1307
1323
  {
1308
1324
  name: "Trash",
1309
1325
  hoverable: !0,
1310
1326
  width: 20,
1311
1327
  height: 20,
1312
1328
  fill: "#C12A2A",
1313
- onClick: () => i(s.filter((k) => k.id !== j.id))
1329
+ onClick: () => i(s.filter((I) => I.id !== j.id))
1314
1330
  }
1315
1331
  ) })
1316
1332
  ] })
1317
1333
  ] });
1318
- return o ? /* @__PURE__ */ t.jsx(
1319
- qs,
1334
+ return c ? /* @__PURE__ */ t.jsx(
1335
+ Ls,
1320
1336
  {
1321
1337
  product: j,
1322
1338
  children: O
@@ -1325,39 +1341,39 @@ const aa = (r) => {
1325
1341
  ) : /* @__PURE__ */ t.jsx(
1326
1342
  "div",
1327
1343
  {
1328
- className: F.product,
1344
+ className: z.product,
1329
1345
  children: O
1330
1346
  },
1331
1347
  j.id
1332
1348
  );
1333
1349
  };
1334
- return /* @__PURE__ */ t.jsxs("div", { className: F.productsBlock, children: [
1335
- (l || c !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: F.top, children: [
1336
- l && /* @__PURE__ */ t.jsx("h3", { className: F.title, children: l }),
1337
- c !== void 0 && /* @__PURE__ */ t.jsx(
1350
+ return /* @__PURE__ */ t.jsxs("div", { className: z.productsBlock, children: [
1351
+ (l || a !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: z.top, children: [
1352
+ l && /* @__PURE__ */ t.jsx("h3", { className: z.title, children: l }),
1353
+ a !== void 0 && /* @__PURE__ */ t.jsx(
1338
1354
  Z,
1339
1355
  {
1340
- current: c,
1356
+ current: a,
1341
1357
  onChange: (j) => e == null ? void 0 : e(j)
1342
1358
  }
1343
1359
  )
1344
1360
  ] }),
1345
- B && n && y && N && /* @__PURE__ */ t.jsx(
1346
- Os,
1361
+ B && n && k && $ && /* @__PURE__ */ t.jsx(
1362
+ Ds,
1347
1363
  {
1348
- ref: v,
1364
+ ref: y,
1349
1365
  activeItem: B,
1350
1366
  setActiveItem: S,
1351
1367
  popupPosition: f,
1352
- modalOptions: y,
1368
+ modalOptions: k,
1353
1369
  setIsOpenModal: E
1354
1370
  }
1355
1371
  ),
1356
1372
  w && q && /* @__PURE__ */ t.jsx(At, { ...q }),
1357
- /* @__PURE__ */ t.jsxs("div", { className: F.products, children: [
1358
- m && /* @__PURE__ */ t.jsx("h5", { className: F.subtitle, children: m }),
1359
- o ? /* @__PURE__ */ t.jsx(
1360
- It,
1373
+ /* @__PURE__ */ t.jsxs("div", { className: z.products, children: [
1374
+ d && /* @__PURE__ */ t.jsx("h5", { className: z.subtitle, children: d }),
1375
+ c ? /* @__PURE__ */ t.jsx(
1376
+ Nt,
1361
1377
  {
1362
1378
  sensors: G,
1363
1379
  onDragEnd: K,
@@ -1366,12 +1382,12 @@ const aa = (r) => {
1366
1382
  {
1367
1383
  items: s.map((j) => j.id),
1368
1384
  strategy: Ct,
1369
- children: s.map((j) => ct(j))
1385
+ children: s.map((j) => lt(j))
1370
1386
  }
1371
1387
  )
1372
1388
  }
1373
- ) : s.map((j) => ct(j)),
1374
- _ && /* @__PURE__ */ t.jsx(
1389
+ ) : s.map((j) => lt(j)),
1390
+ h && /* @__PURE__ */ t.jsx(
1375
1391
  "div",
1376
1392
  {
1377
1393
  style: {
@@ -1380,28 +1396,28 @@ const aa = (r) => {
1380
1396
  justifyContent: "center"
1381
1397
  },
1382
1398
  children: /* @__PURE__ */ t.jsx(
1383
- at,
1399
+ ct,
1384
1400
  {
1385
1401
  withoutHover: !0,
1386
- className: F.button,
1402
+ className: z.button,
1387
1403
  size: "s",
1388
1404
  onClick: () => {
1389
1405
  const j = [...s];
1390
1406
  let O = null;
1391
- if (d) {
1392
- for (let u = 0; u < d.length; u++)
1393
- if (!s.find((k) => k.name === d[u])) {
1394
- O = d[u];
1407
+ if (u) {
1408
+ for (let m = 0; m < u.length; m++)
1409
+ if (!s.find((I) => I.name === u[m])) {
1410
+ O = u[m];
1395
1411
  break;
1396
1412
  }
1397
1413
  }
1398
- h === "select" && d ? j.push({
1399
- name: O || d[0],
1414
+ _ === "select" && u ? j.push({
1415
+ name: O || u[0],
1400
1416
  id: mt(),
1401
1417
  ...L,
1402
1418
  maxSymbols: 100
1403
1419
  // пример значения
1404
- }) : h === "input" ? j.push({
1420
+ }) : _ === "input" ? j.push({
1405
1421
  name: "",
1406
1422
  id: mt(),
1407
1423
  ...L,
@@ -1416,10 +1432,10 @@ const aa = (r) => {
1416
1432
  style: {
1417
1433
  width: "fit-content"
1418
1434
  },
1419
- children: /* @__PURE__ */ t.jsxs("div", { className: F.addButton, children: [
1435
+ children: /* @__PURE__ */ t.jsxs("div", { className: z.addButton, children: [
1420
1436
  /* @__PURE__ */ t.jsx("span", { children: "Add Option" }),
1421
1437
  /* @__PURE__ */ t.jsx(
1422
- b,
1438
+ v,
1423
1439
  {
1424
1440
  name: "Plus",
1425
1441
  width: 16,
@@ -1432,61 +1448,62 @@ const aa = (r) => {
1432
1448
  }
1433
1449
  )
1434
1450
  ] }),
1435
- a !== void 0 && /* @__PURE__ */ t.jsx(bt, { items: a })
1451
+ o !== void 0 && /* @__PURE__ */ t.jsx(vt, { items: o })
1436
1452
  ] });
1437
- }, Es = "_title_174ru_1", Ds = "_subtitle_174ru_5", Ls = "_header_174ru_12", Rs = "_text_174ru_13", Ms = "_productsBlock_174ru_14", Hs = "_buttonsBlock_174ru_15", zs = "_top_174ru_26", Fs = "_itemsBlock_174ru_35", Vs = "_typeTexts_174ru_41", Us = "_block_174ru_48", Ys = "_active_174ru_60", Gs = "_products_174ru_14", Ws = "_product_174ru_14", Xs = "_button_174ru_15", Js = "_image_174ru_90", Qs = "_info_174ru_97", Ks = "_name_174ru_109", Zs = "_buttons_174ru_15", tn = "_modal_174ru_120", en = "_other_174ru_139", sn = "_options_174ru_145", dt = {
1438
- title: Es,
1439
- subtitle: Ds,
1440
- header: Ls,
1441
- text: Rs,
1442
- productsBlock: Ms,
1443
- buttonsBlock: Hs,
1444
- top: zs,
1445
- itemsBlock: Fs,
1446
- typeTexts: Vs,
1447
- block: Us,
1448
- active: Ys,
1449
- products: Gs,
1450
- product: Ws,
1451
- button: Xs,
1452
- image: Js,
1453
- info: Qs,
1454
- name: Ks,
1455
- buttons: Zs,
1456
- modal: tn,
1457
- other: en,
1458
- options: sn
1459
- }, nn = g.forwardRef((r, c) => {
1460
- const { activeButton: e, setActiveButton: s, popupPosition: i } = r, [a, l] = g.useState(e.typesText), [m, n] = g.useState(e.destination), [o, x] = g.useState(e.page), [$, _] = g.useState(e.link || ""), [h, p] = g.useState(e.text || ""), [d, w] = g.useState(e.openInNewTab), { pages: q } = Ht();
1461
- return g.useEffect(() => {
1453
+ }, Rs = "_title_bn7sv_1", Ms = "_subtitle_bn7sv_5", Hs = "_header_bn7sv_12", zs = "_text_bn7sv_13", Fs = "_productsBlock_bn7sv_14", Vs = "_buttonsBlock_bn7sv_15", Us = "_top_bn7sv_26", Ys = "_itemsBlock_bn7sv_35", Gs = "_typeTexts_bn7sv_41", Ws = "_block_bn7sv_48", Xs = "_active_bn7sv_60", Js = "_products_bn7sv_14", Qs = "_product_bn7sv_14", Ks = "_button_bn7sv_15", Zs = "_image_bn7sv_90", tn = "_info_bn7sv_97", en = "_name_bn7sv_109", sn = "_buttons_bn7sv_15", nn = "_modal_bn7sv_120", on = "_other_bn7sv_139", an = "_options_bn7sv_145", cn = "_closeIcon_bn7sv_153", at = {
1454
+ title: Rs,
1455
+ subtitle: Ms,
1456
+ header: Hs,
1457
+ text: zs,
1458
+ productsBlock: Fs,
1459
+ buttonsBlock: Vs,
1460
+ top: Us,
1461
+ itemsBlock: Ys,
1462
+ typeTexts: Gs,
1463
+ block: Ws,
1464
+ active: Xs,
1465
+ products: Js,
1466
+ product: Qs,
1467
+ button: Ks,
1468
+ image: Zs,
1469
+ info: tn,
1470
+ name: en,
1471
+ buttons: sn,
1472
+ modal: nn,
1473
+ other: on,
1474
+ options: an,
1475
+ closeIcon: cn
1476
+ }, ln = p.forwardRef((r, a) => {
1477
+ const { activeButton: e, setActiveButton: s, popupPosition: i } = r, [o, l] = p.useState(e.typesText), [d, n] = p.useState(e.destination), [c, b] = p.useState(e.page), [x, h] = p.useState(e.link || ""), [_, g] = p.useState(e.text || ""), [u, w] = p.useState(e.openInNewTab), { pages: q } = Ht();
1478
+ return p.useEffect(() => {
1462
1479
  s({
1463
1480
  ...e,
1464
1481
  ...{
1465
- text: h,
1466
- link: $,
1467
- destination: m,
1468
- typesText: a,
1469
- page: o,
1470
- openInNewTab: d
1482
+ text: _,
1483
+ link: x,
1484
+ destination: d,
1485
+ typesText: o,
1486
+ page: c,
1487
+ openInNewTab: u
1471
1488
  }
1472
1489
  });
1473
- }, [a, m, $, h, o, d]), /* @__PURE__ */ t.jsxs(
1490
+ }, [o, d, x, _, c, u]), /* @__PURE__ */ t.jsxs(
1474
1491
  "div",
1475
1492
  {
1476
- className: dt.modal,
1477
- onClick: (y) => {
1478
- y.stopPropagation();
1493
+ className: at.modal,
1494
+ onClick: (k) => {
1495
+ k.stopPropagation();
1479
1496
  },
1480
1497
  style: {
1481
1498
  top: `${i.top}px`,
1482
1499
  left: `${i.left}px`
1483
1500
  },
1484
- ref: c,
1501
+ ref: a,
1485
1502
  children: [
1486
- /* @__PURE__ */ t.jsxs("div", { className: dt.top, children: [
1487
- /* @__PURE__ */ t.jsx("h3", { className: dt.title, children: e.type }),
1488
- /* @__PURE__ */ t.jsx(
1489
- b,
1503
+ /* @__PURE__ */ t.jsxs("div", { className: at.top, children: [
1504
+ /* @__PURE__ */ t.jsx("h3", { className: at.title, children: e.type }),
1505
+ /* @__PURE__ */ t.jsx("div", { className: at.closeIcon, children: /* @__PURE__ */ t.jsx(
1506
+ v,
1490
1507
  {
1491
1508
  name: "X",
1492
1509
  height: 20,
@@ -1494,31 +1511,31 @@ const aa = (r) => {
1494
1511
  hoverable: !0,
1495
1512
  onClick: () => s(null)
1496
1513
  }
1497
- )
1514
+ ) })
1498
1515
  ] }),
1499
- /* @__PURE__ */ t.jsxs("div", { className: dt.options, children: [
1516
+ /* @__PURE__ */ t.jsxs("div", { className: at.options, children: [
1500
1517
  /* @__PURE__ */ t.jsx(
1501
1518
  st,
1502
1519
  {
1503
1520
  label: "Destination",
1504
- onChange: (y) => n(y),
1505
- options: ["Go to Page", "Open Link"].filter((y) => y !== m),
1506
- value: m
1521
+ onChange: (k) => n(k),
1522
+ options: ["Go to Page", "Open Link"].filter((k) => k !== d),
1523
+ value: d
1507
1524
  }
1508
1525
  ),
1509
- m === "Go to Page" ? /* @__PURE__ */ t.jsx(
1526
+ d === "Go to Page" ? /* @__PURE__ */ t.jsx(
1510
1527
  st,
1511
1528
  {
1512
1529
  label: "Go to",
1513
- onChange: (y) => x(y),
1514
- options: q ? Object.values(q).filter((y) => y.name !== o).map((y) => y.name) : [],
1515
- value: o
1530
+ onChange: (k) => b(k),
1531
+ options: q ? Object.values(q).filter((k) => k.name !== c).map((k) => k.name) : [],
1532
+ value: c
1516
1533
  }
1517
1534
  ) : /* @__PURE__ */ t.jsx(
1518
1535
  W,
1519
1536
  {
1520
- onChange: (y) => _(y),
1521
- value: $,
1537
+ onChange: (k) => h(k),
1538
+ value: x,
1522
1539
  placeholder: "https://",
1523
1540
  label: "Link"
1524
1541
  }
@@ -1528,14 +1545,14 @@ const aa = (r) => {
1528
1545
  {
1529
1546
  current: e.openInNewTab,
1530
1547
  label: "Open in new tab",
1531
- onChange: (y) => w(y)
1548
+ onChange: (k) => w(k)
1532
1549
  }
1533
1550
  ),
1534
1551
  /* @__PURE__ */ t.jsx(
1535
1552
  Ot,
1536
1553
  {
1537
- onChange: (y) => p(y),
1538
- value: h,
1554
+ onChange: (k) => g(k),
1555
+ value: _,
1539
1556
  label: "Text",
1540
1557
  maxLength: 150
1541
1558
  }
@@ -1543,7 +1560,7 @@ const aa = (r) => {
1543
1560
  /* @__PURE__ */ t.jsx(
1544
1561
  Lt,
1545
1562
  {
1546
- typesText: a,
1563
+ typesText: o,
1547
1564
  setTypesText: l
1548
1565
  }
1549
1566
  )
@@ -1551,67 +1568,67 @@ const aa = (r) => {
1551
1568
  ]
1552
1569
  }
1553
1570
  );
1554
- }), on = "_subtitle_jql1y_1", an = "_header_jql1y_8", cn = "_text_jql1y_9", ln = "_productsBlock_jql1y_10", rn = "_buttonsBlock_jql1y_11", dn = "_top_jql1y_23", un = "_itemsBlock_jql1y_32", mn = "_typeTexts_jql1y_38", hn = "_block_jql1y_45", _n = "_active_jql1y_58", pn = "_products_jql1y_10", gn = "_product_jql1y_10", fn = "_button_jql1y_11", xn = "_image_jql1y_88", jn = "_info_jql1y_95", bn = "_name_jql1y_107", vn = "_buttons_jql1y_11", yn = "_modal_jql1y_118", kn = "_other_jql1y_138", $n = "_options_jql1y_144", Nn = "_addButton_jql1y_150", In = "_deleteButton_jql1y_165", nt = {
1555
- subtitle: on,
1556
- header: an,
1557
- text: cn,
1558
- productsBlock: ln,
1559
- buttonsBlock: rn,
1560
- top: dn,
1561
- itemsBlock: un,
1562
- typeTexts: mn,
1563
- block: hn,
1564
- active: _n,
1565
- products: pn,
1566
- product: gn,
1567
- button: fn,
1568
- image: xn,
1569
- info: jn,
1570
- name: bn,
1571
- buttons: vn,
1572
- modal: yn,
1573
- other: kn,
1574
- options: $n,
1575
- addButton: Nn,
1576
- deleteButton: In
1577
- }, wn = (r) => {
1578
- const { buttons: c, setButtons: e, deletable: s = !0, addable: i = !0 } = r, [a, l] = g.useState(null), [m, n] = g.useState({
1571
+ }), rn = "_subtitle_jql1y_1", dn = "_header_jql1y_8", un = "_text_jql1y_9", mn = "_productsBlock_jql1y_10", _n = "_buttonsBlock_jql1y_11", hn = "_top_jql1y_23", pn = "_itemsBlock_jql1y_32", gn = "_typeTexts_jql1y_38", xn = "_block_jql1y_45", fn = "_active_jql1y_58", bn = "_products_jql1y_10", vn = "_product_jql1y_10", jn = "_button_jql1y_11", yn = "_image_jql1y_88", kn = "_info_jql1y_95", In = "_name_jql1y_107", $n = "_buttons_jql1y_11", Nn = "_modal_jql1y_118", wn = "_other_jql1y_138", Cn = "_options_jql1y_144", Bn = "_addButton_jql1y_150", Sn = "_deleteButton_jql1y_165", nt = {
1572
+ subtitle: rn,
1573
+ header: dn,
1574
+ text: un,
1575
+ productsBlock: mn,
1576
+ buttonsBlock: _n,
1577
+ top: hn,
1578
+ itemsBlock: pn,
1579
+ typeTexts: gn,
1580
+ block: xn,
1581
+ active: fn,
1582
+ products: bn,
1583
+ product: vn,
1584
+ button: jn,
1585
+ image: yn,
1586
+ info: kn,
1587
+ name: In,
1588
+ buttons: $n,
1589
+ modal: Nn,
1590
+ other: wn,
1591
+ options: Cn,
1592
+ addButton: Bn,
1593
+ deleteButton: Sn
1594
+ }, Tn = (r) => {
1595
+ const { buttons: a, setButtons: e, deletable: s = !0, addable: i = !0 } = r, [o, l] = p.useState(null), [d, n] = p.useState({
1579
1596
  top: 0,
1580
1597
  left: 0
1581
- }), [o, x] = g.useState(null), $ = g.useRef(null);
1582
- g.useEffect(() => {
1583
- const h = () => {
1598
+ }), [c, b] = p.useState(null), x = p.useRef(null);
1599
+ p.useEffect(() => {
1600
+ const _ = () => {
1584
1601
  l(null);
1585
1602
  };
1586
- return document.body.addEventListener("click", h), l(null), () => {
1587
- l(null), document.body.removeEventListener("click", h);
1603
+ return document.body.addEventListener("click", _), l(null), () => {
1604
+ l(null), document.body.removeEventListener("click", _);
1588
1605
  };
1589
- }, []), g.useEffect(() => {
1590
- if (a) {
1591
- const h = [...c].map((p) => p.id === a.id ? a : p);
1592
- e(h);
1606
+ }, []), p.useEffect(() => {
1607
+ if (o) {
1608
+ const _ = [...a].map((g) => g.id === o.id ? o : g);
1609
+ e(_);
1593
1610
  }
1594
- }, [a]), g.useEffect(() => {
1595
- if ($.current && o) {
1596
- const h = $.current.getBoundingClientRect().height, p = window.innerHeight;
1597
- let d = o.top;
1598
- d + h > p + window.scrollY - 200 && (d = p + window.scrollY - h - 200), d < 0 && (d = 10), n({
1599
- top: d,
1600
- left: o.left
1611
+ }, [o]), p.useEffect(() => {
1612
+ if (x.current && c) {
1613
+ const _ = x.current.getBoundingClientRect().height, g = window.innerHeight;
1614
+ let u = c.top;
1615
+ u + _ > g + window.scrollY - 200 && (u = g + window.scrollY - _ - 200), u < 0 && (u = 10), n({
1616
+ top: u,
1617
+ left: c.left
1601
1618
  });
1602
1619
  }
1603
- }, [$.current, o]);
1604
- const _ = (h, p) => {
1605
- h.stopPropagation();
1606
- const d = h.target.getBoundingClientRect();
1607
- x({
1608
- top: d.top + window.scrollY,
1609
- left: d.left - 30
1610
- }), l(p);
1620
+ }, [x.current, c]);
1621
+ const h = (_, g) => {
1622
+ _.stopPropagation();
1623
+ const u = _.target.getBoundingClientRect();
1624
+ b({
1625
+ top: u.top + window.scrollY,
1626
+ left: u.left - 30
1627
+ }), l(g);
1611
1628
  };
1612
1629
  return /* @__PURE__ */ t.jsxs("div", { className: nt.products, children: [
1613
1630
  /* @__PURE__ */ t.jsx("h5", { className: nt.subtitle, children: "Button Type" }),
1614
- c.map((h) => /* @__PURE__ */ t.jsxs(
1631
+ a.map((_) => /* @__PURE__ */ t.jsxs(
1615
1632
  "div",
1616
1633
  {
1617
1634
  className: nt.product,
@@ -1619,38 +1636,38 @@ const aa = (r) => {
1619
1636
  /* @__PURE__ */ t.jsx(
1620
1637
  st,
1621
1638
  {
1622
- onChange: (p) => {
1623
- const w = [...c].map((q) => q.id === h.id ? {
1624
- ...h,
1625
- type: p
1639
+ onChange: (g) => {
1640
+ const w = [...a].map((q) => q.id === _.id ? {
1641
+ ..._,
1642
+ type: g
1626
1643
  } : q);
1627
1644
  e(w);
1628
1645
  },
1629
- value: h.type,
1646
+ value: _.type,
1630
1647
  options: ["Primary", "Secondary", "Tertiary"]
1631
1648
  }
1632
1649
  ),
1633
1650
  /* @__PURE__ */ t.jsxs("div", { className: nt.buttons, children: [
1634
1651
  /* @__PURE__ */ t.jsx("div", { className: nt.deleteButton, children: /* @__PURE__ */ t.jsx(
1635
- b,
1652
+ v,
1636
1653
  {
1637
1654
  name: "Sliders",
1638
1655
  hoverable: !0,
1639
1656
  width: 20,
1640
1657
  height: 20,
1641
- onClick: (p) => {
1642
- _(p, h);
1658
+ onClick: (g) => {
1659
+ h(g, _);
1643
1660
  }
1644
1661
  }
1645
1662
  ) }),
1646
1663
  s && /* @__PURE__ */ t.jsx("div", { className: nt.deleteButton, children: /* @__PURE__ */ t.jsx(
1647
- b,
1664
+ v,
1648
1665
  {
1649
1666
  name: "Trash",
1650
1667
  hoverable: !0,
1651
1668
  onClick: () => {
1652
- const p = c.filter((d) => d.id !== h.id);
1653
- e(p);
1669
+ const g = a.filter((u) => u.id !== _.id);
1670
+ e(g);
1654
1671
  },
1655
1672
  width: 20,
1656
1673
  height: 20,
@@ -1660,15 +1677,15 @@ const aa = (r) => {
1660
1677
  ] })
1661
1678
  ]
1662
1679
  },
1663
- h.id
1680
+ _.id
1664
1681
  )),
1665
- a && /* @__PURE__ */ t.jsx(
1666
- nn,
1682
+ o && /* @__PURE__ */ t.jsx(
1683
+ ln,
1667
1684
  {
1668
- ref: $,
1669
- activeButton: a,
1685
+ ref: x,
1686
+ activeButton: o,
1670
1687
  setActiveButton: l,
1671
- popupPosition: m
1688
+ popupPosition: d
1672
1689
  }
1673
1690
  ),
1674
1691
  i && /* @__PURE__ */ t.jsx(
@@ -1680,14 +1697,14 @@ const aa = (r) => {
1680
1697
  justifyContent: "center"
1681
1698
  },
1682
1699
  children: /* @__PURE__ */ t.jsx(
1683
- at,
1700
+ ct,
1684
1701
  {
1685
1702
  withoutHover: !0,
1686
1703
  className: nt.button,
1687
1704
  size: "s",
1688
1705
  onClick: () => {
1689
- const h = [...c];
1690
- h.push({
1706
+ const _ = [...a];
1707
+ _.push({
1691
1708
  type: "Primary",
1692
1709
  id: mt(),
1693
1710
  typesText: [],
@@ -1695,7 +1712,7 @@ const aa = (r) => {
1695
1712
  text: "Button Name",
1696
1713
  page: "home",
1697
1714
  openInNewTab: !0
1698
- }), e(h);
1715
+ }), e(_);
1699
1716
  },
1700
1717
  style: {
1701
1718
  width: "fit-content"
@@ -1703,7 +1720,7 @@ const aa = (r) => {
1703
1720
  children: /* @__PURE__ */ t.jsxs("div", { className: nt.addButton, children: [
1704
1721
  /* @__PURE__ */ t.jsx("span", { children: "Add Option" }),
1705
1722
  /* @__PURE__ */ t.jsx(
1706
- b,
1723
+ v,
1707
1724
  {
1708
1725
  name: "Plus",
1709
1726
  width: 16,
@@ -1716,77 +1733,77 @@ const aa = (r) => {
1716
1733
  }
1717
1734
  )
1718
1735
  ] });
1719
- }, ca = (r) => {
1720
- const { isActiveButtons: c, setIsActiveButtons: e, buttons: s, setButtons: i } = r;
1721
- return /* @__PURE__ */ t.jsx(t.Fragment, { children: /* @__PURE__ */ t.jsxs("div", { className: dt.buttonsBlock, children: [
1722
- /* @__PURE__ */ t.jsxs("div", { className: dt.top, children: [
1723
- /* @__PURE__ */ t.jsx("h3", { className: dt.title, children: "Buttons" }),
1736
+ }, ma = (r) => {
1737
+ const { isActiveButtons: a, setIsActiveButtons: e, buttons: s, setButtons: i } = r;
1738
+ return /* @__PURE__ */ t.jsx(t.Fragment, { children: /* @__PURE__ */ t.jsxs("div", { className: at.buttonsBlock, children: [
1739
+ /* @__PURE__ */ t.jsxs("div", { className: at.top, children: [
1740
+ /* @__PURE__ */ t.jsx("h3", { className: at.title, children: "Buttons" }),
1724
1741
  /* @__PURE__ */ t.jsx(
1725
1742
  Z,
1726
1743
  {
1727
- current: c,
1728
- onChange: (a) => e(a)
1744
+ current: a,
1745
+ onChange: (o) => e(o)
1729
1746
  }
1730
1747
  )
1731
1748
  ] }),
1732
1749
  /* @__PURE__ */ t.jsx(
1733
- wn,
1750
+ Tn,
1734
1751
  {
1735
1752
  buttons: s,
1736
1753
  setButtons: i
1737
1754
  }
1738
1755
  )
1739
1756
  ] }) });
1740
- }, Cn = "_wrapper_m18qi_1", Bn = "_subtitle_m18qi_7", Sn = "_content_m18qi_14", Tn = "_range_m18qi_22", Pn = "_track_m18qi_27", An = "_progress_m18qi_36", On = "_dots_m18qi_46", qn = "_dot_m18qi_46", En = "_active_m18qi_65", Dn = "_input_m18qi_77", Ln = "_countBlock_m18qi_91", Rn = "_count_m18qi_91", Mn = "_controls_m18qi_107", Hn = "_button_m18qi_113", U = {
1741
- wrapper: Cn,
1742
- subtitle: Bn,
1743
- content: Sn,
1744
- range: Tn,
1745
- track: Pn,
1746
- progress: An,
1747
- dots: On,
1748
- dot: qn,
1749
- active: En,
1750
- input: Dn,
1751
- countBlock: Ln,
1752
- count: Rn,
1753
- controls: Mn,
1754
- button: Hn
1757
+ }, Pn = "_wrapper_m18qi_1", An = "_subtitle_m18qi_7", On = "_content_m18qi_14", qn = "_range_m18qi_22", En = "_track_m18qi_27", Dn = "_progress_m18qi_36", Ln = "_dots_m18qi_46", Rn = "_dot_m18qi_46", Mn = "_active_m18qi_65", Hn = "_input_m18qi_77", zn = "_countBlock_m18qi_91", Fn = "_count_m18qi_91", Vn = "_controls_m18qi_107", Un = "_button_m18qi_113", Y = {
1758
+ wrapper: Pn,
1759
+ subtitle: An,
1760
+ content: On,
1761
+ range: qn,
1762
+ track: En,
1763
+ progress: Dn,
1764
+ dots: Ln,
1765
+ dot: Rn,
1766
+ active: Mn,
1767
+ input: Hn,
1768
+ countBlock: zn,
1769
+ count: Fn,
1770
+ controls: Vn,
1771
+ button: Un
1755
1772
  }, At = (r) => {
1756
- const { label: c, min: e = 1, max: s = 4, step: i = 1, count: a, setCount: l } = r, [m, n] = g.useState(!1), o = Array.from({ length: (s - e) / i + 1 }), x = (a - e) / (s - e) * 100, $ = () => {
1757
- a < s && l(a + i);
1758
- }, _ = () => {
1759
- a > e && l(a - i);
1760
- }, h = (p) => {
1761
- const d = e + p * i;
1762
- l(d);
1773
+ const { label: a, min: e = 1, max: s = 4, step: i = 1, count: o, setCount: l } = r, [d, n] = p.useState(!1), c = Array.from({ length: (s - e) / i + 1 }), b = (o - e) / (s - e) * 100, x = () => {
1774
+ o < s && l(o + i);
1775
+ }, h = () => {
1776
+ o > e && l(o - i);
1777
+ }, _ = (g) => {
1778
+ const u = e + g * i;
1779
+ l(u);
1763
1780
  };
1764
- return /* @__PURE__ */ t.jsxs("div", { className: U.wrapper, children: [
1765
- c && /* @__PURE__ */ t.jsx("h5", { className: U.subtitle, children: c }),
1766
- /* @__PURE__ */ t.jsxs("div", { className: U.content, children: [
1767
- /* @__PURE__ */ t.jsxs("div", { className: U.range, children: [
1768
- /* @__PURE__ */ t.jsx("div", { className: U.track }),
1781
+ return /* @__PURE__ */ t.jsxs("div", { className: Y.wrapper, children: [
1782
+ a && /* @__PURE__ */ t.jsx("h5", { className: Y.subtitle, children: a }),
1783
+ /* @__PURE__ */ t.jsxs("div", { className: Y.content, children: [
1784
+ /* @__PURE__ */ t.jsxs("div", { className: Y.range, children: [
1785
+ /* @__PURE__ */ t.jsx("div", { className: Y.track }),
1769
1786
  /* @__PURE__ */ t.jsx(
1770
1787
  "div",
1771
1788
  {
1772
- className: U.progress,
1773
- style: { width: `${x}%` }
1789
+ className: Y.progress,
1790
+ style: { width: `${b}%` }
1774
1791
  }
1775
1792
  ),
1776
- /* @__PURE__ */ t.jsx("div", { className: U.dots, children: o.map((p, d) => {
1777
- const w = d <= (a - e) / i;
1793
+ /* @__PURE__ */ t.jsx("div", { className: Y.dots, children: c.map((g, u) => {
1794
+ const w = u <= (o - e) / i;
1778
1795
  return /* @__PURE__ */ t.jsx(
1779
1796
  "button",
1780
1797
  {
1781
- onClick: () => h(d),
1782
- className: z(U.dot, {
1783
- [U.active]: w,
1784
- [U.inactive]: !w,
1785
- [U.dragging]: m
1798
+ onClick: () => _(u),
1799
+ className: F(Y.dot, {
1800
+ [Y.active]: w,
1801
+ [Y.inactive]: !w,
1802
+ [Y.dragging]: d
1786
1803
  }),
1787
- "aria-label": `Set value to ${e + d * i}`
1804
+ "aria-label": `Set value to ${e + u * i}`
1788
1805
  },
1789
- d
1806
+ u
1790
1807
  );
1791
1808
  }) }),
1792
1809
  /* @__PURE__ */ t.jsx(
@@ -1796,17 +1813,17 @@ const aa = (r) => {
1796
1813
  min: e,
1797
1814
  max: s,
1798
1815
  step: i,
1799
- value: a,
1800
- onChange: (p) => l(Number(p.target.value)),
1816
+ value: o,
1817
+ onChange: (g) => l(Number(g.target.value)),
1801
1818
  onMouseDown: () => n(!0),
1802
1819
  onMouseUp: () => n(!1),
1803
1820
  onTouchStart: () => n(!0),
1804
1821
  onTouchEnd: () => n(!1),
1805
- className: U.input
1822
+ className: Y.input
1806
1823
  }
1807
1824
  )
1808
1825
  ] }),
1809
- /* @__PURE__ */ t.jsxs("div", { className: U.countBlock, children: [
1826
+ /* @__PURE__ */ t.jsxs("div", { className: Y.countBlock, children: [
1810
1827
  /* @__PURE__ */ t.jsx(
1811
1828
  W,
1812
1829
  {
@@ -1814,23 +1831,23 @@ const aa = (r) => {
1814
1831
  min: e,
1815
1832
  max: s,
1816
1833
  paddingless: !0,
1817
- onChange: (p) => {
1818
- const d = Number(p);
1819
- d > s ? l(s) : d < e ? l(e) : l(d);
1834
+ onChange: (g) => {
1835
+ const u = Number(g);
1836
+ u > s ? l(s) : u < e ? l(e) : l(u);
1820
1837
  },
1821
- value: String(a)
1838
+ value: String(o)
1822
1839
  }
1823
1840
  ),
1824
- /* @__PURE__ */ t.jsxs("div", { className: U.controls, children: [
1841
+ /* @__PURE__ */ t.jsxs("div", { className: Y.controls, children: [
1825
1842
  /* @__PURE__ */ t.jsx(
1826
1843
  "button",
1827
1844
  {
1828
- onClick: $,
1829
- disabled: a >= s,
1830
- className: U.button,
1845
+ onClick: x,
1846
+ disabled: o >= s,
1847
+ className: Y.button,
1831
1848
  "aria-label": "Increment count",
1832
1849
  children: /* @__PURE__ */ t.jsx(
1833
- b,
1850
+ v,
1834
1851
  {
1835
1852
  name: "CaretUp",
1836
1853
  width: 15,
@@ -1842,12 +1859,12 @@ const aa = (r) => {
1842
1859
  /* @__PURE__ */ t.jsx(
1843
1860
  "button",
1844
1861
  {
1845
- onClick: _,
1846
- disabled: a <= e,
1847
- className: U.button,
1862
+ onClick: h,
1863
+ disabled: o <= e,
1864
+ className: Y.button,
1848
1865
  "aria-label": "Decrement count",
1849
1866
  children: /* @__PURE__ */ t.jsx(
1850
- b,
1867
+ v,
1851
1868
  {
1852
1869
  name: "CaretDown",
1853
1870
  width: 15,
@@ -1860,39 +1877,40 @@ const aa = (r) => {
1860
1877
  ] })
1861
1878
  ] })
1862
1879
  ] });
1863
- }, zn = "_title_1lejm_1", Fn = "_subtitle_1lejm_5", Vn = "_header_1lejm_12", Un = "_text_1lejm_13", Yn = "_productsBlock_1lejm_14", Gn = "_top_1lejm_26", Wn = "_itemsBlock_1lejm_35", Xn = "_typeTexts_1lejm_41", Jn = "_block_1lejm_48", Qn = "_active_1lejm_61", Kn = "_products_1lejm_14", Zn = "_product_1lejm_14", ti = "_button_1lejm_80", ei = "_image_1lejm_91", si = "_info_1lejm_98", ni = "_name_1lejm_110", ii = "_buttons_1lejm_114", oi = "_modal_1lejm_121", ai = "_link_1lejm_141", ci = "_modalOptions_1lejm_147", li = "_addButton_1lejm_159", ri = "_deleteButton_1lejm_174", Y = {
1864
- title: zn,
1865
- subtitle: Fn,
1866
- header: Vn,
1867
- text: Un,
1868
- productsBlock: Yn,
1869
- top: Gn,
1870
- itemsBlock: Wn,
1871
- typeTexts: Xn,
1872
- block: Jn,
1873
- active: Qn,
1874
- products: Kn,
1875
- product: Zn,
1876
- button: ti,
1877
- image: ei,
1878
- info: si,
1879
- name: ni,
1880
- buttons: ii,
1881
- modal: oi,
1882
- link: ai,
1883
- modalOptions: ci,
1884
- addButton: li,
1885
- deleteButton: ri
1886
- }, di = (r) => {
1887
- const { activeItem: c, setActiveItem: e, popupPosition: s, setIsOpenModal: i, itemsOptions: a } = r, l = a.find((n) => n.id === c.listingId);
1880
+ }, Yn = "_title_ix5ax_1", Gn = "_subtitle_ix5ax_5", Wn = "_header_ix5ax_12", Xn = "_text_ix5ax_13", Jn = "_productsBlock_ix5ax_14", Qn = "_top_ix5ax_26", Kn = "_itemsBlock_ix5ax_35", Zn = "_typeTexts_ix5ax_41", ti = "_block_ix5ax_48", ei = "_active_ix5ax_61", si = "_products_ix5ax_14", ni = "_product_ix5ax_14", ii = "_button_ix5ax_80", oi = "_image_ix5ax_91", ai = "_info_ix5ax_98", ci = "_name_ix5ax_110", li = "_buttons_ix5ax_114", ri = "_modal_ix5ax_121", di = "_link_ix5ax_141", ui = "_modalOptions_ix5ax_147", mi = "_addButton_ix5ax_160", _i = "_deleteButton_ix5ax_175", hi = "_closeIcon_ix5ax_187", V = {
1881
+ title: Yn,
1882
+ subtitle: Gn,
1883
+ header: Wn,
1884
+ text: Xn,
1885
+ productsBlock: Jn,
1886
+ top: Qn,
1887
+ itemsBlock: Kn,
1888
+ typeTexts: Zn,
1889
+ block: ti,
1890
+ active: ei,
1891
+ products: si,
1892
+ product: ni,
1893
+ button: ii,
1894
+ image: oi,
1895
+ info: ai,
1896
+ name: ci,
1897
+ buttons: li,
1898
+ modal: ri,
1899
+ link: di,
1900
+ modalOptions: ui,
1901
+ addButton: mi,
1902
+ deleteButton: _i,
1903
+ closeIcon: hi
1904
+ }, pi = (r) => {
1905
+ const { activeItem: a, setActiveItem: e, popupPosition: s, setIsOpenModal: i, itemsOptions: o } = r, l = o.find((n) => n.id === a.listingId);
1888
1906
  if (!l) return null;
1889
- function m(n, o) {
1890
- return n.length > o ? `${n.slice(0, o)}...` : n;
1907
+ function d(n, c) {
1908
+ return n.length > c ? `${n.slice(0, c)}...` : n;
1891
1909
  }
1892
1910
  return /* @__PURE__ */ t.jsxs(
1893
1911
  "div",
1894
1912
  {
1895
- className: Y.modal,
1913
+ className: V.modal,
1896
1914
  onClick: (n) => {
1897
1915
  n.stopPropagation();
1898
1916
  },
@@ -1901,32 +1919,31 @@ const aa = (r) => {
1901
1919
  left: `${s.left}px`
1902
1920
  },
1903
1921
  children: [
1904
- /* @__PURE__ */ t.jsxs("div", { className: Y.top, children: [
1905
- /* @__PURE__ */ t.jsx("h3", { children: m(l.productData.name, 20) }),
1906
- /* @__PURE__ */ t.jsx(
1907
- b,
1922
+ /* @__PURE__ */ t.jsxs("div", { className: V.top, children: [
1923
+ /* @__PURE__ */ t.jsx("h3", { children: d(l.productData.name, 20) }),
1924
+ /* @__PURE__ */ t.jsx("div", { className: V.closeIcon, children: /* @__PURE__ */ t.jsx(
1925
+ v,
1908
1926
  {
1909
1927
  name: "X",
1910
1928
  height: 20,
1911
1929
  width: 20,
1912
- hoverable: !0,
1913
1930
  onClick: () => {
1914
1931
  i(!1), e(null);
1915
1932
  }
1916
1933
  }
1917
- )
1934
+ ) })
1918
1935
  ] }),
1919
- /* @__PURE__ */ t.jsx("div", { className: Y.modalOptions, children: /* @__PURE__ */ t.jsx(
1936
+ /* @__PURE__ */ t.jsx("div", { className: V.modalOptions, children: /* @__PURE__ */ t.jsx(
1920
1937
  gt,
1921
1938
  {
1922
1939
  label: "Put up an attractive image",
1923
1940
  activeImage: l.productData.images.length > 0 ? l.productData.images[0].cfId : void 0,
1924
1941
  onChange: (n) => {
1925
- const o = {
1926
- ...c,
1942
+ const c = {
1943
+ ...a,
1927
1944
  image: n[0]
1928
1945
  };
1929
- e(o);
1946
+ e(c);
1930
1947
  }
1931
1948
  }
1932
1949
  ) })
@@ -1934,87 +1951,87 @@ const aa = (r) => {
1934
1951
  }
1935
1952
  );
1936
1953
  };
1937
- function ui(r) {
1938
- const { product: c, children: e } = r, { attributes: s, listeners: i, setNodeRef: a, transform: l, transition: m, isDragging: n } = St({
1939
- id: String(c.listingId)
1940
- }), o = {
1954
+ function gi(r) {
1955
+ const { product: a, children: e } = r, { attributes: s, listeners: i, setNodeRef: o, transform: l, transition: d, isDragging: n } = St({
1956
+ id: String(a.listingId)
1957
+ }), c = {
1941
1958
  transform: Tt.Transform.toString(l),
1942
- transition: m
1959
+ transition: d
1943
1960
  };
1944
1961
  return /* @__PURE__ */ t.jsx(
1945
1962
  "div",
1946
1963
  {
1947
- ref: a,
1948
- style: o,
1949
- className: `${Y.product} ${n ? Y.dragging : ""}`,
1964
+ ref: o,
1965
+ style: c,
1966
+ className: `${V.product} ${n ? V.dragging : ""}`,
1950
1967
  ...s,
1951
1968
  ...i,
1952
1969
  children: e
1953
1970
  }
1954
1971
  );
1955
1972
  }
1956
- const la = (r) => {
1973
+ const _a = (r) => {
1957
1974
  const {
1958
- isActiveItems: c,
1975
+ isActiveItems: a,
1959
1976
  setIsActiveItems: e,
1960
1977
  items: s,
1961
1978
  setItems: i,
1962
- other: a,
1979
+ other: o,
1963
1980
  title: l,
1964
- subtitle: m,
1981
+ subtitle: d,
1965
1982
  editable: n = !0,
1966
- draggable: o = !1,
1967
- withImage: x = !1,
1968
- deletable: $ = !0,
1969
- addable: _ = !0,
1970
- itemsType: h,
1971
- itemsOptions: p
1972
- } = r, [d, w] = g.useState(
1983
+ draggable: c = !1,
1984
+ withImage: b = !1,
1985
+ deletable: x = !0,
1986
+ addable: h = !0,
1987
+ itemsType: _,
1988
+ itemsOptions: g
1989
+ } = r, [u, w] = p.useState(
1973
1990
  null
1974
- ), [q, y] = g.useState({
1991
+ ), [q, k] = p.useState({
1975
1992
  top: 0,
1976
1993
  left: 0
1977
- }), [L, B] = g.useState(!1), S = $t(
1978
- Nt(Bt, {
1994
+ }), [L, B] = p.useState(!1), S = It(
1995
+ $t(Bt, {
1979
1996
  activationConstraint: {
1980
1997
  distance: 5
1981
1998
  }
1982
1999
  })
1983
2000
  );
1984
- g.useEffect(() => {
1985
- const v = () => {
2001
+ p.useEffect(() => {
2002
+ const y = () => {
1986
2003
  w(null), B(!1);
1987
2004
  };
1988
- return document.body.addEventListener("click", v), w(null), B(!1), () => {
1989
- w(null), B(!1), document.body.removeEventListener("click", v);
2005
+ return document.body.addEventListener("click", y), w(null), B(!1), () => {
2006
+ w(null), B(!1), document.body.removeEventListener("click", y);
1990
2007
  };
1991
- }, []), g.useEffect(() => {
1992
- if (d) {
1993
- const v = [...s].map((N) => N.listingId === d.listingId ? d : N);
1994
- i(v);
2008
+ }, []), p.useEffect(() => {
2009
+ if (u) {
2010
+ const y = [...s].map(($) => $.listingId === u.listingId ? u : $);
2011
+ i(y);
1995
2012
  }
1996
- }, [d]);
1997
- const f = (v, N) => {
1998
- v.stopPropagation();
1999
- const E = v.target.getBoundingClientRect(), G = 100, A = window.innerHeight;
2000
- let M = E.top + window.scrollY;
2001
- M + G > A && (M = A - G - 20), B(!0), y({
2002
- top: M - 80,
2013
+ }, [u]);
2014
+ const f = (y, $) => {
2015
+ y.stopPropagation();
2016
+ const E = y.target.getBoundingClientRect(), G = 100, A = window.innerHeight;
2017
+ let H = E.top + window.scrollY;
2018
+ H + G > A && (H = A - G - 20), B(!0), k({
2019
+ top: H - 80,
2003
2020
  left: E.left - 30
2004
- }), w(N);
2021
+ }), w($);
2005
2022
  };
2006
- function D(v) {
2007
- if (x)
2008
- return v ? /* @__PURE__ */ t.jsx(
2023
+ function D(y) {
2024
+ if (b)
2025
+ return y ? /* @__PURE__ */ t.jsx(
2009
2026
  "img",
2010
2027
  {
2011
- src: `https://imagedelivery.net/${v}/w=1000`,
2028
+ src: `https://imagedelivery.net/${y}/w=1000`,
2012
2029
  alt: "image",
2013
2030
  width: 16,
2014
2031
  height: 16
2015
2032
  }
2016
2033
  ) : /* @__PURE__ */ t.jsx(
2017
- b,
2034
+ v,
2018
2035
  {
2019
2036
  name: "Image",
2020
2037
  width: 16,
@@ -2023,21 +2040,21 @@ const la = (r) => {
2023
2040
  }
2024
2041
  );
2025
2042
  }
2026
- const X = (v) => {
2027
- const { active: N, over: E } = v;
2028
- if (E && N.id !== E.id) {
2029
- const G = s.findIndex((M) => String(M.listingId) === N.id), A = s.findIndex((M) => String(M.listingId) === E.id);
2043
+ const X = (y) => {
2044
+ const { active: $, over: E } = y;
2045
+ if (E && $.id !== E.id) {
2046
+ const G = s.findIndex((H) => String(H.listingId) === $.id), A = s.findIndex((H) => String(H.listingId) === E.id);
2030
2047
  if (G !== -1 && A !== -1) {
2031
- const M = [...s], [K] = M.splice(G, 1);
2032
- M.splice(A, 0, K), i(M);
2048
+ const H = [...s], [K] = H.splice(G, 1);
2049
+ H.splice(A, 0, K), i(H);
2033
2050
  }
2034
2051
  }
2035
- }, tt = (v, N) => {
2036
- const E = p.find((A) => v.listingId === A.id);
2052
+ }, tt = (y, $) => {
2053
+ const E = g.find((A) => y.listingId === A.id);
2037
2054
  if (!E) return null;
2038
2055
  const G = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
2039
- o && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
2040
- b,
2056
+ c && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
2057
+ v,
2041
2058
  {
2042
2059
  name: "DotsSixVertical",
2043
2060
  hoverable: !0,
@@ -2045,107 +2062,107 @@ const la = (r) => {
2045
2062
  height: 20
2046
2063
  }
2047
2064
  ) }),
2048
- h === "select" && /* @__PURE__ */ t.jsx(
2065
+ _ === "select" && /* @__PURE__ */ t.jsx(
2049
2066
  st,
2050
2067
  {
2051
2068
  onChange: (A) => {
2052
- const M = [...s], K = p.find((O) => O.productData.name === A);
2069
+ const H = [...s], K = g.find((O) => O.productData.name === A);
2053
2070
  if (!K) return;
2054
- const ct = {
2071
+ const lt = {
2055
2072
  listingId: K.id,
2056
2073
  image: K.productData.images.length > 0 ? K.productData.images[0].cfId : ""
2057
- }, j = M.map((O) => O.listingId === v.listingId ? ct : O);
2058
- w(ct), i([...j]);
2074
+ }, j = H.map((O) => O.listingId === y.listingId ? lt : O);
2075
+ w(lt), i([...j]);
2059
2076
  },
2060
2077
  value: E.productData.name,
2061
2078
  options: [
2062
- ...p.filter((A) => !s.find((M) => M.listingId === A.id)).map((A) => A.productData.name)
2079
+ ...g.filter((A) => !s.find((H) => H.listingId === A.id)).map((A) => A.productData.name)
2063
2080
  ],
2064
2081
  leftAddon: D(
2065
- v.image || E.productData.images.length > 0 && E.productData.images[0].cfId || ""
2082
+ y.image || E.productData.images.length > 0 && E.productData.images[0].cfId || ""
2066
2083
  )
2067
2084
  },
2068
- N
2085
+ $
2069
2086
  ),
2070
- /* @__PURE__ */ t.jsxs("div", { className: Y.buttons, children: [
2071
- n && /* @__PURE__ */ t.jsx("div", { className: Y.deleteButton, children: /* @__PURE__ */ t.jsx(
2072
- b,
2087
+ /* @__PURE__ */ t.jsxs("div", { className: V.buttons, children: [
2088
+ n && /* @__PURE__ */ t.jsx("div", { className: V.deleteButton, children: /* @__PURE__ */ t.jsx(
2089
+ v,
2073
2090
  {
2074
2091
  name: "Sliders",
2075
2092
  hoverable: !0,
2076
2093
  width: 20,
2077
2094
  height: 20,
2078
- onClick: (A) => f(A, v)
2095
+ onClick: (A) => f(A, y)
2079
2096
  }
2080
2097
  ) }),
2081
- $ && /* @__PURE__ */ t.jsx("div", { className: Y.deleteButton, children: /* @__PURE__ */ t.jsx(
2082
- b,
2098
+ x && /* @__PURE__ */ t.jsx("div", { className: V.deleteButton, children: /* @__PURE__ */ t.jsx(
2099
+ v,
2083
2100
  {
2084
2101
  name: "Trash",
2085
2102
  hoverable: !0,
2086
2103
  width: 20,
2087
2104
  height: 20,
2088
2105
  fill: "#C12A2A",
2089
- onClick: () => i(s.filter((A) => A !== v))
2106
+ onClick: () => i(s.filter((A) => A !== y))
2090
2107
  }
2091
2108
  ) })
2092
2109
  ] })
2093
2110
  ] });
2094
- return o ? /* @__PURE__ */ t.jsx(
2095
- ui,
2111
+ return c ? /* @__PURE__ */ t.jsx(
2112
+ gi,
2096
2113
  {
2097
- product: v,
2114
+ product: y,
2098
2115
  children: G
2099
2116
  },
2100
- v.listingId
2117
+ y.listingId
2101
2118
  ) : /* @__PURE__ */ t.jsx(
2102
2119
  "div",
2103
2120
  {
2104
- className: Y.product,
2121
+ className: V.product,
2105
2122
  children: G
2106
2123
  },
2107
- v.listingId
2124
+ y.listingId
2108
2125
  );
2109
2126
  };
2110
- return /* @__PURE__ */ t.jsxs("div", { className: Y.productsBlock, children: [
2111
- (l || c !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: Y.top, children: [
2112
- l && /* @__PURE__ */ t.jsx("h3", { className: Y.title, children: l }),
2113
- c !== void 0 && /* @__PURE__ */ t.jsx(
2127
+ return /* @__PURE__ */ t.jsxs("div", { className: V.productsBlock, children: [
2128
+ (l || a !== void 0) && /* @__PURE__ */ t.jsxs("div", { className: V.top, children: [
2129
+ l && /* @__PURE__ */ t.jsx("h3", { className: V.title, children: l }),
2130
+ a !== void 0 && /* @__PURE__ */ t.jsx(
2114
2131
  Z,
2115
2132
  {
2116
- current: c,
2117
- onChange: (v) => e == null ? void 0 : e(v)
2133
+ current: a,
2134
+ onChange: (y) => e == null ? void 0 : e(y)
2118
2135
  }
2119
2136
  )
2120
2137
  ] }),
2121
- L && d && /* @__PURE__ */ t.jsx(
2122
- di,
2138
+ L && u && /* @__PURE__ */ t.jsx(
2139
+ pi,
2123
2140
  {
2124
- activeItem: d,
2141
+ activeItem: u,
2125
2142
  setActiveItem: w,
2126
2143
  setIsOpenModal: B,
2127
2144
  popupPosition: q,
2128
- itemsOptions: p
2145
+ itemsOptions: g
2129
2146
  }
2130
2147
  ),
2131
- /* @__PURE__ */ t.jsxs("div", { className: Y.products, children: [
2132
- m && /* @__PURE__ */ t.jsx("h5", { className: Y.subtitle, children: m }),
2133
- o ? /* @__PURE__ */ t.jsx(
2134
- It,
2148
+ /* @__PURE__ */ t.jsxs("div", { className: V.products, children: [
2149
+ d && /* @__PURE__ */ t.jsx("h5", { className: V.subtitle, children: d }),
2150
+ c ? /* @__PURE__ */ t.jsx(
2151
+ Nt,
2135
2152
  {
2136
2153
  sensors: S,
2137
2154
  onDragEnd: X,
2138
2155
  children: /* @__PURE__ */ t.jsx(
2139
2156
  wt,
2140
2157
  {
2141
- items: s.map((v) => String(v.listingId)),
2158
+ items: s.map((y) => String(y.listingId)),
2142
2159
  strategy: Ct,
2143
- children: s.map((v, N) => tt(v, N))
2160
+ children: s.map((y, $) => tt(y, $))
2144
2161
  }
2145
2162
  )
2146
2163
  }
2147
- ) : s.map((v, N) => tt(v, N)),
2148
- _ && /* @__PURE__ */ t.jsx(
2164
+ ) : s.map((y, $) => tt(y, $)),
2165
+ h && /* @__PURE__ */ t.jsx(
2149
2166
  "div",
2150
2167
  {
2151
2168
  style: {
@@ -2154,31 +2171,31 @@ const la = (r) => {
2154
2171
  justifyContent: "center"
2155
2172
  },
2156
2173
  children: /* @__PURE__ */ t.jsx(
2157
- at,
2174
+ ct,
2158
2175
  {
2159
2176
  withoutHover: !0,
2160
- className: Y.button,
2177
+ className: V.button,
2161
2178
  size: "s",
2162
2179
  onClick: () => {
2163
- const v = [...s];
2164
- for (let N = 0; N < p.length; N++)
2165
- if (!s.find((E) => E.listingId === p[N].id)) {
2166
- v.push({
2167
- listingId: p[N].id,
2168
- image: p[N].productData.images.length > 0 ? p[N].productData.images[0].cfId : ""
2180
+ const y = [...s];
2181
+ for (let $ = 0; $ < g.length; $++)
2182
+ if (!s.find((E) => E.listingId === g[$].id)) {
2183
+ y.push({
2184
+ listingId: g[$].id,
2185
+ image: g[$].productData.images.length > 0 ? g[$].productData.images[0].cfId : ""
2169
2186
  });
2170
2187
  break;
2171
2188
  }
2172
- i(v);
2189
+ i(y);
2173
2190
  },
2174
- disabled: s.length === p.length,
2191
+ disabled: s.length === g.length,
2175
2192
  style: {
2176
2193
  width: "fit-content"
2177
2194
  },
2178
- children: /* @__PURE__ */ t.jsxs("div", { className: Y.addButton, children: [
2195
+ children: /* @__PURE__ */ t.jsxs("div", { className: V.addButton, children: [
2179
2196
  /* @__PURE__ */ t.jsx("span", { children: "Add Option" }),
2180
2197
  /* @__PURE__ */ t.jsx(
2181
- b,
2198
+ v,
2182
2199
  {
2183
2200
  name: "Plus",
2184
2201
  width: 16,
@@ -2191,100 +2208,100 @@ const la = (r) => {
2191
2208
  }
2192
2209
  )
2193
2210
  ] }),
2194
- a !== void 0 && /* @__PURE__ */ t.jsx(bt, { items: a })
2211
+ o !== void 0 && /* @__PURE__ */ t.jsx(vt, { items: o })
2195
2212
  ] });
2196
- }, mi = "_options_d1lk6_1", hi = "_price_d1lk6_12", _i = "_oldPrice_d1lk6_19", pi = "_newPrice_d1lk6_27", gi = "_animate_d1lk6_34", fi = "_appearAndBounce_d1lk6_1", xi = "_meta_d1lk6_52", ji = "_info_d1lk6_58", bi = "_infoRight_d1lk6_66", vi = "_buttons_d1lk6_73", yi = "_variants_d1lk6_80", ki = "_variant_d1lk6_80", $i = "_stock_d1lk6_98", Ni = "_variantInfo_d1lk6_105", Ii = "_quantity_d1lk6_111", wi = "_count_d1lk6_118", Ci = "_focused_d1lk6_135", Bi = "_button_d1lk6_73", Si = "_activeVariant_d1lk6_161", Ti = "_chargeTypes_d1lk6_165", Pi = "_charge_d1lk6_165", Ai = "_chargeActive_d1lk6_190", Oi = "_title_d1lk6_198", I = {
2197
- options: mi,
2198
- price: hi,
2199
- oldPrice: _i,
2200
- newPrice: pi,
2201
- animate: gi,
2202
- appearAndBounce: fi,
2203
- meta: xi,
2204
- info: ji,
2205
- infoRight: bi,
2206
- buttons: vi,
2207
- variants: yi,
2208
- variant: ki,
2209
- stock: $i,
2210
- variantInfo: Ni,
2211
- quantity: Ii,
2212
- count: wi,
2213
- focused: Ci,
2214
- button: Bi,
2215
- activeVariant: Si,
2216
- chargeTypes: Ti,
2217
- charge: Pi,
2218
- chargeActive: Ai,
2219
- title: Oi
2213
+ }, xi = "_options_d1lk6_1", fi = "_price_d1lk6_12", bi = "_oldPrice_d1lk6_19", vi = "_newPrice_d1lk6_27", ji = "_animate_d1lk6_34", yi = "_appearAndBounce_d1lk6_1", ki = "_meta_d1lk6_52", Ii = "_info_d1lk6_58", $i = "_infoRight_d1lk6_66", Ni = "_buttons_d1lk6_73", wi = "_variants_d1lk6_80", Ci = "_variant_d1lk6_80", Bi = "_stock_d1lk6_98", Si = "_variantInfo_d1lk6_105", Ti = "_quantity_d1lk6_111", Pi = "_count_d1lk6_118", Ai = "_focused_d1lk6_135", Oi = "_button_d1lk6_73", qi = "_activeVariant_d1lk6_161", Ei = "_chargeTypes_d1lk6_165", Di = "_charge_d1lk6_165", Li = "_chargeActive_d1lk6_190", Ri = "_title_d1lk6_198", N = {
2214
+ options: xi,
2215
+ price: fi,
2216
+ oldPrice: bi,
2217
+ newPrice: vi,
2218
+ animate: ji,
2219
+ appearAndBounce: yi,
2220
+ meta: ki,
2221
+ info: Ii,
2222
+ infoRight: $i,
2223
+ buttons: Ni,
2224
+ variants: wi,
2225
+ variant: Ci,
2226
+ stock: Bi,
2227
+ variantInfo: Si,
2228
+ quantity: Ti,
2229
+ count: Pi,
2230
+ focused: Ai,
2231
+ button: Oi,
2232
+ activeVariant: qi,
2233
+ chargeTypes: Ei,
2234
+ charge: Di,
2235
+ chargeActive: Li,
2236
+ title: Ri
2220
2237
  };
2221
2238
  var Mt = /* @__PURE__ */ ((r) => (r.ONE_TIME = "One-Time", r.RECURRING = "Subscribe & Save", r))(Mt || {});
2222
- const ra = (r) => {
2239
+ const ha = (r) => {
2223
2240
  var B, S;
2224
- const { variants: c } = r, [e, s] = g.useState(c[0]), [i, a] = g.useState(e.chargeTypes[0]), l = jt(), [m, n] = g.useState(1), [o, x] = g.useState(!1), { reset: $, addProductToCart: _, getProducts: h } = Pt(), [p, d] = g.useState(!1);
2225
- g.useEffect(() => {
2226
- d(!0);
2227
- const f = setTimeout(() => d(!1), 600);
2241
+ const { variants: a } = r, [e, s] = p.useState(a[0]), [i, o] = p.useState(e.chargeTypes[0]), l = bt(), [d, n] = p.useState(1), [c, b] = p.useState(!1), { reset: x, addProductToCart: h, getProducts: _ } = Pt(), [g, u] = p.useState(!1);
2242
+ p.useEffect(() => {
2243
+ u(!0);
2244
+ const f = setTimeout(() => u(!1), 600);
2228
2245
  return () => clearTimeout(f);
2229
- }, [m]);
2246
+ }, [d]);
2230
2247
  async function w() {
2231
- await h(), await _({
2248
+ await _(), await h({
2232
2249
  productId: r.id,
2233
2250
  productVariantId: e.id,
2234
- quantity: m
2251
+ quantity: d
2235
2252
  });
2236
2253
  }
2237
2254
  function q() {
2238
- $(), w(), l("/checkout");
2255
+ x(), w(), l("/checkout");
2239
2256
  }
2240
- function y(f) {
2257
+ function k(f) {
2241
2258
  if (f >= 864e5) {
2242
- const N = Math.floor(f / 864e5);
2243
- return `${N} ${N === 1 ? "day" : "days"}`;
2259
+ const $ = Math.floor(f / 864e5);
2260
+ return `${$} ${$ === 1 ? "day" : "days"}`;
2244
2261
  } else if (f >= 36e5) {
2245
- const N = Math.floor(f / 36e5);
2246
- return `${N} ${N === 1 ? "hour" : "hours"}`;
2262
+ const $ = Math.floor(f / 36e5);
2263
+ return `${$} ${$ === 1 ? "hour" : "hours"}`;
2247
2264
  } else if (f >= 6e4) {
2248
- const N = Math.floor(f / 6e4);
2249
- return `${N} ${N === 1 ? "minute" : "minutes"}`;
2265
+ const $ = Math.floor(f / 6e4);
2266
+ return `${$} ${$ === 1 ? "minute" : "minutes"}`;
2250
2267
  } else {
2251
- const N = Math.floor(f / 1e3);
2252
- return `${N} ${N === 1 ? "second" : "seconds"}`;
2268
+ const $ = Math.floor(f / 1e3);
2269
+ return `${$} ${$ === 1 ? "second" : "seconds"}`;
2253
2270
  }
2254
2271
  }
2255
2272
  function L(f, D) {
2256
2273
  return f.length > D ? f.slice(0, D) + "..." : f;
2257
2274
  }
2258
- return /* @__PURE__ */ t.jsxs("div", { className: I.options, children: [
2259
- e.chargeTypes.length > 1 && /* @__PURE__ */ t.jsx("div", { className: I.chargeTypes, children: e.chargeTypes.map((f) => /* @__PURE__ */ t.jsx(
2275
+ return /* @__PURE__ */ t.jsxs("div", { className: N.options, children: [
2276
+ e.chargeTypes.length > 1 && /* @__PURE__ */ t.jsx("div", { className: N.chargeTypes, children: e.chargeTypes.map((f) => /* @__PURE__ */ t.jsx(
2260
2277
  "div",
2261
2278
  {
2262
- className: z(I.charge, {
2263
- [I.chargeActive]: i === f
2279
+ className: F(N.charge, {
2280
+ [N.chargeActive]: i === f
2264
2281
  }),
2265
- onClick: () => a(f),
2282
+ onClick: () => o(f),
2266
2283
  children: Mt[f]
2267
2284
  },
2268
2285
  f
2269
2286
  )) }),
2270
- /* @__PURE__ */ t.jsx("div", { className: I.variants, children: c.map((f) => {
2287
+ /* @__PURE__ */ t.jsx("div", { className: N.variants, children: a.map((f) => {
2271
2288
  var D;
2272
2289
  return /* @__PURE__ */ t.jsxs(
2273
2290
  "div",
2274
2291
  {
2275
- className: z(I.variant, {
2276
- [I.activeVariant]: e.id === f.id
2292
+ className: F(N.variant, {
2293
+ [N.activeVariant]: e.id === f.id
2277
2294
  }),
2278
2295
  onClick: () => s(f),
2279
2296
  children: [
2280
- /* @__PURE__ */ t.jsxs("div", { className: I.variantInfo, children: [
2281
- /* @__PURE__ */ t.jsx("span", { className: I.title, children: L(f.name, 15) }),
2297
+ /* @__PURE__ */ t.jsxs("div", { className: N.variantInfo, children: [
2298
+ /* @__PURE__ */ t.jsx("span", { className: N.title, children: L(f.name, 15) }),
2282
2299
  /* @__PURE__ */ t.jsxs("span", { children: [
2283
2300
  "$",
2284
2301
  i === "ONE_TIME" ? f.price.amount : f.subscriptionSettings ? f.subscriptionSettings.price.amount : "Price Not Found"
2285
2302
  ] })
2286
2303
  ] }),
2287
- /* @__PURE__ */ t.jsx("div", { children: i === "ONE_TIME" && /* @__PURE__ */ t.jsxs("span", { className: I.stock, children: [
2304
+ /* @__PURE__ */ t.jsx("div", { children: i === "ONE_TIME" && /* @__PURE__ */ t.jsxs("span", { className: N.stock, children: [
2288
2305
  ((D = f.quantity.restrictions) == null ? void 0 : D.max) || f.quantity.available || 0,
2289
2306
  " in stock"
2290
2307
  ] }) })
@@ -2293,31 +2310,31 @@ const ra = (r) => {
2293
2310
  f.id
2294
2311
  );
2295
2312
  }) }),
2296
- i === "ONE_TIME" && /* @__PURE__ */ t.jsxs("div", { className: I.quantity, children: [
2313
+ i === "ONE_TIME" && /* @__PURE__ */ t.jsxs("div", { className: N.quantity, children: [
2297
2314
  /* @__PURE__ */ t.jsx(
2298
2315
  "button",
2299
2316
  {
2300
2317
  onClick: () => {
2301
- m > 1 ? n((f) => f - 1) : n(1);
2318
+ d > 1 ? n((f) => f - 1) : n(1);
2302
2319
  },
2303
- className: I.button,
2304
- disabled: e.quantity.restrictions && m <= e.quantity.restrictions.min,
2305
- children: /* @__PURE__ */ t.jsx(b, { name: "Minus" })
2320
+ className: N.button,
2321
+ disabled: e.quantity.restrictions && d <= e.quantity.restrictions.min,
2322
+ children: /* @__PURE__ */ t.jsx(v, { name: "Minus" })
2306
2323
  }
2307
2324
  ),
2308
2325
  /* @__PURE__ */ t.jsx(
2309
2326
  "label",
2310
2327
  {
2311
- className: z(I.count, {
2312
- [I.focused]: o
2328
+ className: F(N.count, {
2329
+ [N.focused]: c
2313
2330
  }),
2314
- onFocus: () => x(!0),
2315
- onBlur: () => x(!1),
2331
+ onFocus: () => b(!0),
2332
+ onBlur: () => b(!1),
2316
2333
  children: /* @__PURE__ */ t.jsx(
2317
2334
  W,
2318
2335
  {
2319
2336
  type: "number",
2320
- value: String(m),
2337
+ value: String(d),
2321
2338
  onChange: (f) => n(Number(f)),
2322
2339
  max: ((B = e.quantity.restrictions) == null ? void 0 : B.max) || e.quantity.available || 1 / 0,
2323
2340
  min: ((S = e.quantity.restrictions) == null ? void 0 : S.min) || 0,
@@ -2336,18 +2353,18 @@ const ra = (r) => {
2336
2353
  onClick: () => {
2337
2354
  n((f) => f + 1);
2338
2355
  },
2339
- className: I.button,
2340
- disabled: !!(e.quantity.restrictions && m >= e.quantity.restrictions.max || e.quantity.available && m >= e.quantity.available),
2341
- children: /* @__PURE__ */ t.jsx(b, { name: "Plus" })
2356
+ className: N.button,
2357
+ disabled: !!(e.quantity.restrictions && d >= e.quantity.restrictions.max || e.quantity.available && d >= e.quantity.available),
2358
+ children: /* @__PURE__ */ t.jsx(v, { name: "Plus" })
2342
2359
  }
2343
2360
  )
2344
2361
  ] }),
2345
- /* @__PURE__ */ t.jsxs("div", { className: I.meta, children: [
2346
- /* @__PURE__ */ t.jsxs("div", { className: I.info, children: [
2362
+ /* @__PURE__ */ t.jsxs("div", { className: N.meta, children: [
2363
+ /* @__PURE__ */ t.jsxs("div", { className: N.info, children: [
2347
2364
  /* @__PURE__ */ t.jsx("span", { children: "Delivery" }),
2348
- /* @__PURE__ */ t.jsxs("div", { className: I.infoRight, children: [
2365
+ /* @__PURE__ */ t.jsxs("div", { className: N.infoRight, children: [
2349
2366
  /* @__PURE__ */ t.jsx(
2350
- b,
2367
+ v,
2351
2368
  {
2352
2369
  name: "Lightning",
2353
2370
  fill: "#FF3F19",
@@ -2355,41 +2372,41 @@ const ra = (r) => {
2355
2372
  height: 20
2356
2373
  }
2357
2374
  ),
2358
- /* @__PURE__ */ t.jsx("span", { children: !e.deliveryTime || e.deliveryTime === 0 ? "Instant" : y(e.deliveryTime) })
2375
+ /* @__PURE__ */ t.jsx("span", { children: !e.deliveryTime || e.deliveryTime === 0 ? "Instant" : k(e.deliveryTime) })
2359
2376
  ] })
2360
2377
  ] }),
2361
- /* @__PURE__ */ t.jsxs("div", { className: I.info, children: [
2378
+ /* @__PURE__ */ t.jsxs("div", { className: N.info, children: [
2362
2379
  /* @__PURE__ */ t.jsx("span", { children: "Price" }),
2363
- /* @__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: [
2364
- /* @__PURE__ */ t.jsxs("span", { className: z(I.newPrice, { [I.animate]: p }), children: [
2380
+ /* @__PURE__ */ t.jsx("div", { className: N.infoRight, children: i === "ONE_TIME" ? e.compareAtPrice && (e.compareAtPrice.amount || 0) - (e.price.amount || 0) > 0 ? /* @__PURE__ */ t.jsxs("div", { className: N.price, children: [
2381
+ /* @__PURE__ */ t.jsxs("span", { className: F(N.newPrice, { [N.animate]: g }), children: [
2365
2382
  "$ ",
2366
- (e.price.amount || 0) * m
2383
+ (e.price.amount || 0) * d
2367
2384
  ] }),
2368
- /* @__PURE__ */ t.jsxs("span", { className: I.oldPrice, children: [
2385
+ /* @__PURE__ */ t.jsxs("span", { className: N.oldPrice, children: [
2369
2386
  "$ ",
2370
- (e.compareAtPrice.amount || 0) * m
2387
+ (e.compareAtPrice.amount || 0) * d
2371
2388
  ] })
2372
- ] }) : /* @__PURE__ */ t.jsxs("span", { className: z(I.newPrice, { [I.animate]: p }), children: [
2389
+ ] }) : /* @__PURE__ */ t.jsxs("span", { className: F(N.newPrice, { [N.animate]: g }), children: [
2373
2390
  "$ ",
2374
- (e.price.amount || 0) * m
2375
- ] }) : e.subscriptionSettings && e.subscriptionSettings.compareAtPrice && (e.subscriptionSettings.compareAtPrice.amount || 0) - (e.subscriptionSettings.price.amount || 0) > 0 ? /* @__PURE__ */ t.jsxs("div", { className: I.price, children: [
2376
- /* @__PURE__ */ t.jsxs("span", { className: z(I.newPrice, { [I.animate]: p }), children: [
2391
+ (e.price.amount || 0) * d
2392
+ ] }) : e.subscriptionSettings && e.subscriptionSettings.compareAtPrice && (e.subscriptionSettings.compareAtPrice.amount || 0) - (e.subscriptionSettings.price.amount || 0) > 0 ? /* @__PURE__ */ t.jsxs("div", { className: N.price, children: [
2393
+ /* @__PURE__ */ t.jsxs("span", { className: F(N.newPrice, { [N.animate]: g }), children: [
2377
2394
  "$ ",
2378
2395
  e.subscriptionSettings.price.amount || 0
2379
2396
  ] }),
2380
- /* @__PURE__ */ t.jsxs("span", { className: I.oldPrice, children: [
2397
+ /* @__PURE__ */ t.jsxs("span", { className: N.oldPrice, children: [
2381
2398
  "$ ",
2382
2399
  e.subscriptionSettings.compareAtPrice.amount || 0
2383
2400
  ] })
2384
- ] }) : e.subscriptionSettings && /* @__PURE__ */ t.jsxs("span", { className: z(I.newPrice, { [I.animate]: p }), children: [
2401
+ ] }) : e.subscriptionSettings && /* @__PURE__ */ t.jsxs("span", { className: F(N.newPrice, { [N.animate]: g }), children: [
2385
2402
  "$ ",
2386
2403
  e.subscriptionSettings.price.amount || 0
2387
2404
  ] }) })
2388
2405
  ] })
2389
2406
  ] }),
2390
- /* @__PURE__ */ t.jsxs("div", { className: I.buttons, children: [
2407
+ /* @__PURE__ */ t.jsxs("div", { className: N.buttons, children: [
2391
2408
  /* @__PURE__ */ t.jsx(
2392
- at,
2409
+ ct,
2393
2410
  {
2394
2411
  type: "Primary",
2395
2412
  onClick: () => q(),
@@ -2397,7 +2414,7 @@ const ra = (r) => {
2397
2414
  }
2398
2415
  ),
2399
2416
  i === "ONE_TIME" && /* @__PURE__ */ t.jsx(
2400
- at,
2417
+ ct,
2401
2418
  {
2402
2419
  type: "Secondary",
2403
2420
  onClick: () => w(),
@@ -2406,139 +2423,139 @@ const ra = (r) => {
2406
2423
  )
2407
2424
  ] })
2408
2425
  ] });
2409
- }, qi = "_button_oyh2y_1", Ei = "_login_oyh2y_14", Di = "_signUp_oyh2y_18", Li = "_buttons_oyh2y_23", Ri = "_modal_oyh2y_32", Mi = "_closing_oyh2y_61", Hi = "_info_oyh2y_85", zi = "_top_oyh2y_92", Fi = "_title_oyh2y_103", Vi = "_clear_oyh2y_110", Ui = "_activeClear_oyh2y_117", Yi = "_count_oyh2y_121", Gi = "_cart_oyh2y_136", Wi = "_empty_oyh2y_144", Xi = "_product_oyh2y_170", Ji = "_products_oyh2y_179", Qi = "_image_oyh2y_187", Ki = "_productInfo_oyh2y_193", Zi = "_content_oyh2y_200", to = "_name_oyh2y_206", eo = "_price_oyh2y_212", so = "_productButtons_oyh2y_218", no = "_productButton_oyh2y_218", io = "_productCount_oyh2y_238", oo = "_bottom_oyh2y_254", ao = "_subtotal_oyh2y_262", co = "_block_oyh2y_270", lo = "_shoppingCount_oyh2y_277", ro = "_total_oyh2y_297", uo = "_link_oyh2y_303", mo = "_userInfo_oyh2y_310", C = {
2410
- button: qi,
2411
- login: Ei,
2412
- signUp: Di,
2413
- buttons: Li,
2414
- modal: Ri,
2426
+ }, Mi = "_button_oyh2y_1", Hi = "_login_oyh2y_14", zi = "_signUp_oyh2y_18", Fi = "_buttons_oyh2y_23", Vi = "_modal_oyh2y_32", Ui = "_closing_oyh2y_61", Yi = "_info_oyh2y_85", Gi = "_top_oyh2y_92", Wi = "_title_oyh2y_103", Xi = "_clear_oyh2y_110", Ji = "_activeClear_oyh2y_117", Qi = "_count_oyh2y_121", Ki = "_cart_oyh2y_136", Zi = "_empty_oyh2y_144", to = "_product_oyh2y_170", eo = "_products_oyh2y_179", so = "_image_oyh2y_187", no = "_productInfo_oyh2y_193", io = "_content_oyh2y_200", oo = "_name_oyh2y_206", ao = "_price_oyh2y_212", co = "_productButtons_oyh2y_218", lo = "_productButton_oyh2y_218", ro = "_productCount_oyh2y_238", uo = "_bottom_oyh2y_254", mo = "_subtotal_oyh2y_262", _o = "_block_oyh2y_270", ho = "_shoppingCount_oyh2y_277", po = "_total_oyh2y_297", go = "_link_oyh2y_303", xo = "_userInfo_oyh2y_310", C = {
2427
+ button: Mi,
2428
+ login: Hi,
2429
+ signUp: zi,
2430
+ buttons: Fi,
2431
+ modal: Vi,
2415
2432
  "slide-in-fade": "_slide-in-fade_oyh2y_1",
2416
- closing: Mi,
2433
+ closing: Ui,
2417
2434
  "slide-out-fade": "_slide-out-fade_oyh2y_1",
2418
- info: Hi,
2419
- top: zi,
2420
- title: Fi,
2421
- clear: Vi,
2422
- activeClear: Ui,
2423
- count: Yi,
2424
- cart: Gi,
2425
- empty: Wi,
2426
- product: Xi,
2427
- products: Ji,
2428
- image: Qi,
2429
- productInfo: Ki,
2430
- content: Zi,
2431
- name: to,
2432
- price: eo,
2433
- productButtons: so,
2434
- productButton: no,
2435
- productCount: io,
2436
- bottom: oo,
2437
- subtotal: ao,
2438
- block: co,
2439
- shoppingCount: lo,
2440
- total: ro,
2441
- link: uo,
2442
- userInfo: mo
2443
- }, ho = "_button_85085_1", _o = "_primary_85085_20", po = "_primaryHovered_85085_30", go = "_secondary_85085_34", fo = "_secondaryHovered_85085_44", xo = "_tertiary_85085_48", jo = "_tertiaryHovered_85085_58", bo = "_content_85085_62", it = {
2444
- button: ho,
2445
- primary: _o,
2446
- primaryHovered: po,
2447
- secondary: go,
2448
- secondaryHovered: fo,
2449
- tertiary: xo,
2450
- tertiaryHovered: jo,
2451
- content: bo
2435
+ info: Yi,
2436
+ top: Gi,
2437
+ title: Wi,
2438
+ clear: Xi,
2439
+ activeClear: Ji,
2440
+ count: Qi,
2441
+ cart: Ki,
2442
+ empty: Zi,
2443
+ product: to,
2444
+ products: eo,
2445
+ image: so,
2446
+ productInfo: no,
2447
+ content: io,
2448
+ name: oo,
2449
+ price: ao,
2450
+ productButtons: co,
2451
+ productButton: lo,
2452
+ productCount: ro,
2453
+ bottom: uo,
2454
+ subtotal: mo,
2455
+ block: _o,
2456
+ shoppingCount: ho,
2457
+ total: po,
2458
+ link: go,
2459
+ userInfo: xo
2460
+ }, fo = "_button_85085_1", bo = "_primary_85085_20", vo = "_primaryHovered_85085_30", jo = "_secondary_85085_34", yo = "_secondaryHovered_85085_44", ko = "_tertiary_85085_48", Io = "_tertiaryHovered_85085_58", $o = "_content_85085_62", it = {
2461
+ button: fo,
2462
+ primary: bo,
2463
+ primaryHovered: vo,
2464
+ secondary: jo,
2465
+ secondaryHovered: yo,
2466
+ tertiary: ko,
2467
+ tertiaryHovered: Io,
2468
+ content: $o
2452
2469
  }, kt = (r) => {
2453
- const { children: c, onClick: e, style: s, className: i, disabled: a = !1, type: l = "Primary" } = r, { themeSettings: m } = qt();
2470
+ const { children: a, onClick: e, style: s, className: i, disabled: o = !1, type: l = "Primary" } = r, { themeSettings: d } = qt();
2454
2471
  return /* @__PURE__ */ t.jsx(
2455
2472
  "button",
2456
2473
  {
2457
- className: z(it.button, i, {
2474
+ className: F(it.button, i, {
2458
2475
  [it.primary]: l === "Primary",
2459
2476
  [it.secondary]: l === "Secondary",
2460
2477
  [it.tertiary]: l === "Tertiary",
2461
- [it.primaryHovered]: l === "Primary" && !a && m.buttons.primary.hover,
2462
- [it.secondaryHovered]: l === "Secondary" && !a && m.buttons.secondary.hover,
2463
- [it.tertiaryHovered]: l === "Tertiary" && !a && m.buttons.tertiary.hover
2478
+ [it.primaryHovered]: l === "Primary" && !o && d.buttons.primary.hover,
2479
+ [it.secondaryHovered]: l === "Secondary" && !o && d.buttons.secondary.hover,
2480
+ [it.tertiaryHovered]: l === "Tertiary" && !o && d.buttons.tertiary.hover
2464
2481
  }),
2465
2482
  onClick: e,
2466
2483
  style: {
2467
2484
  ...s
2468
2485
  },
2469
- disabled: a,
2486
+ disabled: o,
2470
2487
  children: l === "Tertiary" ? /* @__PURE__ */ t.jsxs("div", { className: it.content, children: [
2488
+ a,
2471
2489
  /* @__PURE__ */ t.jsx(
2472
- b,
2490
+ v,
2473
2491
  {
2474
2492
  name: "ArrowRight",
2475
2493
  fill: "#757575",
2476
2494
  width: 20,
2477
2495
  height: 20
2478
2496
  }
2479
- ),
2480
- c
2481
- ] }) : /* @__PURE__ */ t.jsx(t.Fragment, { children: c })
2497
+ )
2498
+ ] }) : /* @__PURE__ */ t.jsx(t.Fragment, { children: a })
2482
2499
  }
2483
2500
  );
2484
2501
  };
2485
2502
  class pt extends Error {
2486
2503
  }
2487
2504
  pt.prototype.name = "InvalidTokenError";
2488
- function vo(r) {
2489
- return decodeURIComponent(atob(r).replace(/(.)/g, (c, e) => {
2505
+ function No(r) {
2506
+ return decodeURIComponent(atob(r).replace(/(.)/g, (a, e) => {
2490
2507
  let s = e.charCodeAt(0).toString(16).toUpperCase();
2491
2508
  return s.length < 2 && (s = "0" + s), "%" + s;
2492
2509
  }));
2493
2510
  }
2494
- function yo(r) {
2495
- let c = r.replace(/-/g, "+").replace(/_/g, "/");
2496
- switch (c.length % 4) {
2511
+ function wo(r) {
2512
+ let a = r.replace(/-/g, "+").replace(/_/g, "/");
2513
+ switch (a.length % 4) {
2497
2514
  case 0:
2498
2515
  break;
2499
2516
  case 2:
2500
- c += "==";
2517
+ a += "==";
2501
2518
  break;
2502
2519
  case 3:
2503
- c += "=";
2520
+ a += "=";
2504
2521
  break;
2505
2522
  default:
2506
2523
  throw new Error("base64 string is not of the correct length");
2507
2524
  }
2508
2525
  try {
2509
- return vo(c);
2526
+ return No(a);
2510
2527
  } catch {
2511
- return atob(c);
2528
+ return atob(a);
2512
2529
  }
2513
2530
  }
2514
- function ko(r, c) {
2531
+ function Co(r, a) {
2515
2532
  if (typeof r != "string")
2516
2533
  throw new pt("Invalid token specified: must be a string");
2517
- c || (c = {});
2518
- const e = c.header === !0 ? 0 : 1, s = r.split(".")[e];
2534
+ a || (a = {});
2535
+ const e = a.header === !0 ? 0 : 1, s = r.split(".")[e];
2519
2536
  if (typeof s != "string")
2520
2537
  throw new pt(`Invalid token specified: missing part #${e + 1}`);
2521
2538
  let i;
2522
2539
  try {
2523
- i = yo(s);
2524
- } catch (a) {
2525
- throw new pt(`Invalid token specified: invalid base64 for part #${e + 1} (${a.message})`);
2540
+ i = wo(s);
2541
+ } catch (o) {
2542
+ throw new pt(`Invalid token specified: invalid base64 for part #${e + 1} (${o.message})`);
2526
2543
  }
2527
2544
  try {
2528
2545
  return JSON.parse(i);
2529
- } catch (a) {
2530
- throw new pt(`Invalid token specified: invalid json for part #${e + 1} (${a.message})`);
2546
+ } catch (o) {
2547
+ throw new pt(`Invalid token specified: invalid json for part #${e + 1} (${o.message})`);
2531
2548
  }
2532
2549
  }
2533
- const da = (r) => {
2534
- const { shopping: c, signUp: e } = r, s = jt();
2550
+ const pa = (r) => {
2551
+ const { shopping: a, signUp: e } = r, s = bt();
2535
2552
  function i(l) {
2536
2553
  s(l);
2537
2554
  }
2538
- const a = JSON.parse(localStorage.getItem("token") || "{}");
2555
+ const o = JSON.parse(localStorage.getItem("token") || "{}");
2539
2556
  return /* @__PURE__ */ t.jsxs("div", { className: C.buttons, children: [
2540
- c && /* @__PURE__ */ t.jsx($o, {}),
2541
- !a.data && /* @__PURE__ */ t.jsx(
2557
+ a && /* @__PURE__ */ t.jsx(Bo, {}),
2558
+ !o.data && /* @__PURE__ */ t.jsx(
2542
2559
  kt,
2543
2560
  {
2544
2561
  onClick: () => i("/customer-dash"),
@@ -2549,7 +2566,7 @@ const da = (r) => {
2549
2566
  children: "Login"
2550
2567
  }
2551
2568
  ),
2552
- !a.data && e && /* @__PURE__ */ t.jsx(
2569
+ !o.data && e && /* @__PURE__ */ t.jsx(
2553
2570
  kt,
2554
2571
  {
2555
2572
  onClick: () => i("/customer-dash"),
@@ -2560,54 +2577,54 @@ const da = (r) => {
2560
2577
  children: "Sign Up"
2561
2578
  }
2562
2579
  ),
2563
- a.data && /* @__PURE__ */ t.jsx(wo, { token: a.data })
2580
+ o.data && /* @__PURE__ */ t.jsx(Po, { token: o.data })
2564
2581
  ] });
2565
- }, $o = () => {
2566
- const [r, c] = g.useState(!1), [e, s] = g.useState([]), { cart: i, getProducts: a } = Pt();
2567
- function l(_) {
2568
- for (let h = 0; h < i.parts.length; h++)
2569
- for (let p = 0; p < _.variants.length; p++)
2570
- if (i.parts[h].productVariantId === _.variants[h].id)
2571
- return i.parts[h].productVariantId;
2582
+ }, Bo = () => {
2583
+ const [r, a] = p.useState(!1), [e, s] = p.useState([]), { cart: i, getProducts: o } = Pt();
2584
+ function l(h) {
2585
+ for (let _ = 0; _ < i.parts.length; _++)
2586
+ for (let g = 0; g < h.variants.length; g++)
2587
+ if (i.parts[_].productVariantId === h.variants[_].id)
2588
+ return i.parts[_].productVariantId;
2572
2589
  }
2573
- function m(_) {
2574
- for (let h = 0; h < i.parts.length; h++)
2575
- for (let p = 0; p < _.variants.length; p++)
2576
- if (i.parts[h].productVariantId === _.variants[h].id)
2577
- return i.parts[h].quantity;
2590
+ function d(h) {
2591
+ for (let _ = 0; _ < i.parts.length; _++)
2592
+ for (let g = 0; g < h.variants.length; g++)
2593
+ if (i.parts[_].productVariantId === h.variants[_].id)
2594
+ return i.parts[_].quantity;
2578
2595
  }
2579
- g.useEffect(() => {
2596
+ p.useEffect(() => {
2580
2597
  (async () => {
2581
- const h = i.parts.map((w) => String(w.productId)), d = (await a([...h])).map((w) => ({
2598
+ const _ = i.parts.map((w) => String(w.productId)), u = (await o([..._])).map((w) => ({
2582
2599
  ...w,
2583
2600
  activeVariantId: l(w),
2584
- quantity: m(w)
2601
+ quantity: d(w)
2585
2602
  }));
2586
- s(d);
2603
+ s(u);
2587
2604
  })();
2588
2605
  }, [i.parts.length]);
2589
- function n(_) {
2590
- var h;
2591
- return !_ || !(_ != null && _.variants) ? !1 : (h = _.variants.find((p) => p.id === _.activeVariantId)) == null ? void 0 : h.subscriptionSettings;
2606
+ function n(h) {
2607
+ var _;
2608
+ return !h || !(h != null && h.variants) ? !1 : (_ = h.variants.find((g) => g.id === h.activeVariantId)) == null ? void 0 : _.subscriptionSettings;
2592
2609
  }
2593
- const o = i.parts.length > 0 && e.length > 0 && !n(e[0]), [x, $] = g.useState(!1);
2610
+ const c = i.parts.length > 0 && e.length > 0 && !n(e[0]), [b, x] = p.useState(!1);
2594
2611
  return /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
2595
2612
  /* @__PURE__ */ t.jsxs(
2596
2613
  "div",
2597
2614
  {
2598
2615
  className: C.button,
2599
- onClick: (_) => {
2600
- _.stopPropagation(), c(!0), $(!0);
2616
+ onClick: (h) => {
2617
+ h.stopPropagation(), a(!0), x(!0);
2601
2618
  },
2602
2619
  children: [
2603
2620
  /* @__PURE__ */ t.jsx(
2604
- b,
2621
+ v,
2605
2622
  {
2606
2623
  name: "Handbag",
2607
2624
  fill: "var(--icon-primary)"
2608
2625
  }
2609
2626
  ),
2610
- o && /* @__PURE__ */ t.jsx("div", { className: C.shoppingCount, children: i.parts.length })
2627
+ c && /* @__PURE__ */ t.jsx("div", { className: C.shoppingCount, children: i.parts.length })
2611
2628
  ]
2612
2629
  }
2613
2630
  ),
@@ -2615,47 +2632,48 @@ const da = (r) => {
2615
2632
  Et,
2616
2633
  {
2617
2634
  close: () => {
2618
- $(!1), setTimeout(() => {
2619
- c(!1);
2635
+ x(!1), setTimeout(() => {
2636
+ a(!1);
2620
2637
  }, 300);
2621
2638
  },
2639
+ withAnimation: !1,
2622
2640
  children: /* @__PURE__ */ t.jsx(
2623
- No,
2641
+ So,
2624
2642
  {
2625
2643
  activeProducts: e,
2626
- isCartNotEmpty: o,
2627
- isOpen: x
2644
+ isCartNotEmpty: c,
2645
+ isOpen: b
2628
2646
  }
2629
2647
  )
2630
2648
  }
2631
2649
  )
2632
2650
  ] });
2633
- }, No = (r) => {
2634
- const { activeProducts: c, isCartNotEmpty: e, isOpen: s } = r, { cart: i, reset: a, getTotalAndDiscount: l, updateQuantityOfProduct: m } = Pt(), n = jt();
2635
- function o(_) {
2636
- n(_);
2651
+ }, So = (r) => {
2652
+ const { activeProducts: a, isCartNotEmpty: e, isOpen: s } = r, { cart: i, reset: o, getTotalAndDiscount: l, updateQuantityOfProduct: d } = Pt(), n = bt();
2653
+ function c(h) {
2654
+ n(h);
2637
2655
  }
2638
- function x(_) {
2639
- m({
2640
- productId: _.id,
2641
- productVariantId: _.activeVariantId,
2642
- quantity: _.quantity + 1
2656
+ function b(h) {
2657
+ d({
2658
+ productId: h.id,
2659
+ productVariantId: h.activeVariantId,
2660
+ quantity: h.quantity + 1
2643
2661
  });
2644
2662
  }
2645
- function $(_) {
2646
- m({
2647
- productId: _.id,
2648
- productVariantId: _.activeVariantId,
2649
- quantity: _.quantity - 1
2663
+ function x(h) {
2664
+ d({
2665
+ productId: h.id,
2666
+ productVariantId: h.activeVariantId,
2667
+ quantity: h.quantity - 1
2650
2668
  });
2651
2669
  }
2652
2670
  return /* @__PURE__ */ t.jsxs(
2653
2671
  "div",
2654
2672
  {
2655
- className: z(C.modal, {
2673
+ className: F(C.modal, {
2656
2674
  [C.closing]: !s
2657
2675
  }),
2658
- onClick: (_) => _.stopPropagation(),
2676
+ onClick: (h) => h.stopPropagation(),
2659
2677
  children: [
2660
2678
  /* @__PURE__ */ t.jsxs("div", { className: C.top, children: [
2661
2679
  /* @__PURE__ */ t.jsxs("div", { className: C.info, children: [
@@ -2665,17 +2683,17 @@ const da = (r) => {
2665
2683
  /* @__PURE__ */ t.jsx(
2666
2684
  "button",
2667
2685
  {
2668
- className: z(C.clear, {
2686
+ className: F(C.clear, {
2669
2687
  [C.activeClear]: e
2670
2688
  }),
2671
2689
  disabled: !e,
2672
- onClick: a,
2690
+ onClick: o,
2673
2691
  children: "Clear all"
2674
2692
  }
2675
2693
  )
2676
2694
  ] }),
2677
2695
  e ? /* @__PURE__ */ t.jsxs("div", { className: C.cart, children: [
2678
- /* @__PURE__ */ t.jsx("div", { className: C.products, children: c.map((_) => /* @__PURE__ */ t.jsxs(
2696
+ /* @__PURE__ */ t.jsx("div", { className: C.products, children: a.map((h) => /* @__PURE__ */ t.jsxs(
2679
2697
  "div",
2680
2698
  {
2681
2699
  className: C.product,
@@ -2684,7 +2702,7 @@ const da = (r) => {
2684
2702
  /* @__PURE__ */ t.jsx(
2685
2703
  "img",
2686
2704
  {
2687
- src: `https://imagedelivery.net/${_.images[0].cfId}/w=500`,
2705
+ src: `https://imagedelivery.net/${h.images[0].cfId}/w=500`,
2688
2706
  alt: "image",
2689
2707
  width: "100%",
2690
2708
  height: "100%",
@@ -2692,10 +2710,10 @@ const da = (r) => {
2692
2710
  }
2693
2711
  ),
2694
2712
  /* @__PURE__ */ t.jsxs("div", { className: C.content, children: [
2695
- /* @__PURE__ */ t.jsx("div", { className: C.name, children: _.name }),
2713
+ /* @__PURE__ */ t.jsx("div", { className: C.name, children: h.name }),
2696
2714
  /* @__PURE__ */ t.jsxs("div", { className: C.price, children: [
2697
2715
  "$",
2698
- _.variants.find((h) => h.id === _.activeVariantId).price.amount * ((_ == null ? void 0 : _.quantity) || 1)
2716
+ h.variants.find((_) => _.id === h.activeVariantId).price.amount * ((h == null ? void 0 : h.quantity) || 1)
2699
2717
  ] })
2700
2718
  ] })
2701
2719
  ] }),
@@ -2704,11 +2722,11 @@ const da = (r) => {
2704
2722
  "div",
2705
2723
  {
2706
2724
  onClick: () => {
2707
- _.quantity !== 1 && $(_);
2725
+ h.quantity !== 1 && x(h);
2708
2726
  },
2709
2727
  className: C.productButton,
2710
2728
  children: /* @__PURE__ */ t.jsx(
2711
- b,
2729
+ v,
2712
2730
  {
2713
2731
  name: "Minus",
2714
2732
  fill: "#757575",
@@ -2718,14 +2736,14 @@ const da = (r) => {
2718
2736
  )
2719
2737
  }
2720
2738
  ),
2721
- /* @__PURE__ */ t.jsx("div", { className: C.productCount, children: _.quantity }),
2739
+ /* @__PURE__ */ t.jsx("div", { className: C.productCount, children: h.quantity }),
2722
2740
  /* @__PURE__ */ t.jsx(
2723
2741
  "div",
2724
2742
  {
2725
- onClick: () => x(_),
2743
+ onClick: () => b(h),
2726
2744
  className: C.productButton,
2727
2745
  children: /* @__PURE__ */ t.jsx(
2728
- b,
2746
+ v,
2729
2747
  {
2730
2748
  name: "Plus",
2731
2749
  fill: "#757575",
@@ -2738,14 +2756,14 @@ const da = (r) => {
2738
2756
  ] })
2739
2757
  ]
2740
2758
  },
2741
- _.id
2759
+ h.id
2742
2760
  )) }),
2743
2761
  /* @__PURE__ */ t.jsxs("div", { className: C.bottom, children: [
2744
2762
  /* @__PURE__ */ t.jsxs("div", { className: C.subtotal, children: [
2745
2763
  /* @__PURE__ */ t.jsxs("div", { className: C.block, children: [
2746
2764
  /* @__PURE__ */ t.jsx("span", { children: "Subtotal" }),
2747
2765
  /* @__PURE__ */ t.jsx(
2748
- b,
2766
+ v,
2749
2767
  {
2750
2768
  name: "Info",
2751
2769
  width: 20,
@@ -2759,15 +2777,15 @@ const da = (r) => {
2759
2777
  l().total
2760
2778
  ] })
2761
2779
  ] }),
2762
- /* @__PURE__ */ t.jsx(kt, { onClick: () => o("/checkout"), children: "Checkout" })
2780
+ /* @__PURE__ */ t.jsx(kt, { onClick: () => c("/checkout"), children: "Checkout" })
2763
2781
  ] })
2764
- ] }) : /* @__PURE__ */ t.jsx(Io, {})
2782
+ ] }) : /* @__PURE__ */ t.jsx(To, {})
2765
2783
  ]
2766
2784
  }
2767
2785
  );
2768
- }, Io = () => /* @__PURE__ */ t.jsxs("div", { className: C.empty, children: [
2786
+ }, To = () => /* @__PURE__ */ t.jsxs("div", { className: C.empty, children: [
2769
2787
  /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
2770
- b,
2788
+ v,
2771
2789
  {
2772
2790
  name: "Handbag",
2773
2791
  fill: "var(--icon-secondary)"
@@ -2786,43 +2804,43 @@ const da = (r) => {
2786
2804
  }
2787
2805
  )
2788
2806
  ] })
2789
- ] }), wo = ({ token: r }) => {
2790
- const [c, e] = g.useState("test-email@gmail.com"), s = jt();
2791
- g.useEffect(() => {
2807
+ ] }), Po = ({ token: r }) => {
2808
+ const [a, e] = p.useState("test-email@gmail.com"), s = bt();
2809
+ p.useEffect(() => {
2792
2810
  (async () => {
2793
- const l = ko(r);
2811
+ const l = Co(r);
2794
2812
  e(l.email);
2795
2813
  })();
2796
2814
  }, [r]);
2797
- function i(a) {
2798
- s(a);
2815
+ function i(o) {
2816
+ s(o);
2799
2817
  }
2800
2818
  return /* @__PURE__ */ t.jsx(
2801
2819
  "div",
2802
2820
  {
2803
2821
  className: C.userInfo,
2804
2822
  onClick: () => i("/customer-dash"),
2805
- children: /* @__PURE__ */ t.jsx("div", { children: c || "test-email@gmail.com" })
2823
+ children: /* @__PURE__ */ t.jsx("div", { children: a || "test-email@gmail.com" })
2806
2824
  }
2807
2825
  );
2808
- }, Co = "_share_11u0d_1", Bo = "_modal_11u0d_8", So = "_header_11u0d_14", To = "_socials_11u0d_24", Po = "_social_11u0d_24", Ao = "_copy_11u0d_34", Oo = "_title_11u0d_41", qo = "_copyWrapper_11u0d_47", Eo = "_copyText_11u0d_56", ot = {
2809
- share: Co,
2810
- modal: Bo,
2811
- header: So,
2812
- socials: To,
2813
- social: Po,
2814
- copy: Ao,
2815
- title: Oo,
2816
- copyWrapper: qo,
2817
- copyText: Eo
2818
- }, ua = () => {
2819
- const { isOpenModal: r, setIsOpenModal: c } = Dt();
2826
+ }, Ao = "_share_11u0d_1", Oo = "_modal_11u0d_8", qo = "_header_11u0d_14", Eo = "_socials_11u0d_24", Do = "_social_11u0d_24", Lo = "_copy_11u0d_34", Ro = "_title_11u0d_41", Mo = "_copyWrapper_11u0d_47", Ho = "_copyText_11u0d_56", ot = {
2827
+ share: Ao,
2828
+ modal: Oo,
2829
+ header: qo,
2830
+ socials: Eo,
2831
+ social: Do,
2832
+ copy: Lo,
2833
+ title: Ro,
2834
+ copyWrapper: Mo,
2835
+ copyText: Ho
2836
+ }, ga = () => {
2837
+ const { isOpenModal: r, setIsOpenModal: a } = Dt();
2820
2838
  function e() {
2821
- c(!0);
2839
+ a(!0);
2822
2840
  }
2823
2841
  return /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
2824
2842
  /* @__PURE__ */ t.jsx(
2825
- at,
2843
+ ct,
2826
2844
  {
2827
2845
  className: ot.share,
2828
2846
  onClick: (s) => {
@@ -2830,7 +2848,7 @@ const da = (r) => {
2830
2848
  },
2831
2849
  type: "Secondary",
2832
2850
  children: /* @__PURE__ */ t.jsx(
2833
- b,
2851
+ v,
2834
2852
  {
2835
2853
  name: "Share",
2836
2854
  fill: "#757575",
@@ -2839,30 +2857,35 @@ const da = (r) => {
2839
2857
  )
2840
2858
  }
2841
2859
  ),
2842
- r && /* @__PURE__ */ t.jsx(Et, { close: c, children: /* @__PURE__ */ t.jsx(Do, {}) })
2860
+ r && /* @__PURE__ */ t.jsx(Et, { close: a, children: /* @__PURE__ */ t.jsx(zo, {}) })
2843
2861
  ] });
2844
- }, Do = () => {
2845
- const { setIsOpenModal: r } = Dt(), { notification: c, setNotification: e } = zt(), s = window.location.href;
2846
- function i() {
2847
- navigator.clipboard.writeText(s), e({
2862
+ }, zo = () => {
2863
+ const { setIsOpenModal: r } = Dt(), { notification: a, setNotification: e } = zt(), { setIsOpen: s } = Ft(), i = window.location.href;
2864
+ function o() {
2865
+ navigator.clipboard.writeText(i), e({
2848
2866
  message: "Link copied to clipboard",
2849
2867
  status: "success"
2850
2868
  });
2851
2869
  }
2870
+ function l() {
2871
+ s(!1), setTimeout(() => {
2872
+ r(!1), s(!0);
2873
+ }, 300);
2874
+ }
2852
2875
  return /* @__PURE__ */ t.jsxs(
2853
2876
  "div",
2854
2877
  {
2855
2878
  className: ot.modal,
2856
- onClick: (a) => a.stopPropagation(),
2879
+ onClick: (d) => d.stopPropagation(),
2857
2880
  children: [
2858
2881
  /* @__PURE__ */ t.jsxs("div", { className: ot.header, children: [
2859
2882
  /* @__PURE__ */ t.jsx("div", { className: ot.title, children: "Copy Product Link" }),
2860
2883
  /* @__PURE__ */ t.jsx(
2861
- b,
2884
+ v,
2862
2885
  {
2863
2886
  name: "X",
2864
2887
  fill: "#757575",
2865
- onClick: () => r(!1),
2888
+ onClick: l,
2866
2889
  hoverable: !0
2867
2890
  }
2868
2891
  )
@@ -2871,44 +2894,44 @@ const da = (r) => {
2871
2894
  /* @__PURE__ */ t.jsx(
2872
2895
  "div",
2873
2896
  {
2874
- className: z(ot.copy, ot.copyText),
2875
- onClick: i,
2876
- children: s
2897
+ className: F(ot.copy, ot.copyText),
2898
+ onClick: o,
2899
+ children: i
2877
2900
  }
2878
2901
  ),
2879
2902
  /* @__PURE__ */ t.jsx(
2880
2903
  "div",
2881
2904
  {
2882
- onClick: i,
2905
+ onClick: o,
2883
2906
  className: ot.copy,
2884
- children: c ? /* @__PURE__ */ t.jsx(b, { name: "Check" }) : /* @__PURE__ */ t.jsx(b, { name: "Copy" })
2907
+ children: a ? /* @__PURE__ */ t.jsx(v, { name: "Check" }) : /* @__PURE__ */ t.jsx(v, { name: "Copy" })
2885
2908
  }
2886
2909
  )
2887
2910
  ] })
2888
2911
  ]
2889
2912
  }
2890
2913
  );
2891
- }, Lo = "_accordion_1s1lq_1", Ro = "_header_1s1lq_9", Mo = "_icon_1s1lq_18", Ho = "_open_1s1lq_21", zo = "_content_1s1lq_25", _t = {
2892
- accordion: Lo,
2893
- header: Ro,
2894
- icon: Mo,
2895
- open: Ho,
2896
- content: zo
2897
- }, ma = ({ title: r, content: c }) => {
2898
- const [e, s] = g.useState(!1), [i, a] = g.useState(0), l = g.useRef(null), m = () => {
2914
+ }, Fo = "_accordion_1s1lq_1", Vo = "_header_1s1lq_9", Uo = "_icon_1s1lq_18", Yo = "_open_1s1lq_21", Go = "_content_1s1lq_25", ht = {
2915
+ accordion: Fo,
2916
+ header: Vo,
2917
+ icon: Uo,
2918
+ open: Yo,
2919
+ content: Go
2920
+ }, xa = ({ title: r, content: a }) => {
2921
+ const [e, s] = p.useState(!1), [i, o] = p.useState(0), l = p.useRef(null), d = () => {
2899
2922
  s(!e);
2900
2923
  };
2901
- return g.useEffect(() => {
2902
- l.current && a(e ? l.current.scrollHeight : 0);
2903
- }, [e]), /* @__PURE__ */ t.jsxs("div", { className: _t.accordion, children: [
2924
+ return p.useEffect(() => {
2925
+ l.current && o(e ? l.current.scrollHeight : 0);
2926
+ }, [e]), /* @__PURE__ */ t.jsxs("div", { className: ht.accordion, children: [
2904
2927
  /* @__PURE__ */ t.jsxs(
2905
2928
  "div",
2906
2929
  {
2907
- className: _t.header,
2908
- onClick: m,
2930
+ className: ht.header,
2931
+ onClick: d,
2909
2932
  children: [
2910
2933
  /* @__PURE__ */ t.jsx("h5", { id: "h5", children: r }),
2911
- /* @__PURE__ */ t.jsx("div", { className: z(_t.icon, { [_t.open]: e }), children: /* @__PURE__ */ t.jsx(b, { name: "CaretDown" }) })
2934
+ /* @__PURE__ */ t.jsx("div", { className: F(ht.icon, { [ht.open]: e }), children: /* @__PURE__ */ t.jsx(v, { name: "CaretDown" }) })
2912
2935
  ]
2913
2936
  }
2914
2937
  ),
@@ -2916,44 +2939,44 @@ const da = (r) => {
2916
2939
  "div",
2917
2940
  {
2918
2941
  ref: l,
2919
- className: _t.content,
2942
+ className: ht.content,
2920
2943
  style: { height: `${i}px` },
2921
- children: /* @__PURE__ */ t.jsx("p", { id: "p", children: c })
2944
+ children: /* @__PURE__ */ t.jsx("p", { id: "p", children: a })
2922
2945
  }
2923
2946
  )
2924
2947
  ] });
2925
- }, Fo = "_wrapper_p74l6_1", Vo = "_label_p74l6_9", Uo = "_input_p74l6_18", Yo = "_paddingless_p74l6_31", Go = "_content_p74l6_35", Wo = "_contentBorder_p74l6_48", Xo = "_borderless_p74l6_53", Jo = "_rightIcon_p74l6_58", et = {
2926
- wrapper: Fo,
2927
- label: Vo,
2928
- input: Uo,
2929
- paddingless: Yo,
2930
- content: Go,
2931
- contentBorder: Wo,
2932
- borderless: Xo,
2933
- rightIcon: Jo
2934
- }, ha = (r) => {
2948
+ }, Wo = "_wrapper_p74l6_1", Xo = "_label_p74l6_9", Jo = "_input_p74l6_18", Qo = "_paddingless_p74l6_31", Ko = "_content_p74l6_35", Zo = "_contentBorder_p74l6_48", ta = "_borderless_p74l6_53", ea = "_rightIcon_p74l6_58", et = {
2949
+ wrapper: Wo,
2950
+ label: Xo,
2951
+ input: Jo,
2952
+ paddingless: Qo,
2953
+ content: Ko,
2954
+ contentBorder: Zo,
2955
+ borderless: ta,
2956
+ rightIcon: ea
2957
+ }, fa = (r) => {
2935
2958
  const {
2936
- onChange: c,
2959
+ onChange: a,
2937
2960
  style: e,
2938
2961
  label: s,
2939
2962
  value: i,
2940
- type: a,
2963
+ type: o,
2941
2964
  min: l,
2942
- max: m,
2965
+ max: d,
2943
2966
  placeholder: n,
2944
- disabled: o = !1,
2945
- required: x = !1,
2946
- regex: $,
2947
- paddingless: _ = !1,
2948
- borderless: h = !1,
2949
- editable: p = !1,
2950
- isSearch: d = !1
2951
- } = r, { themeSettings: w } = qt(), { inputs: q } = w, [y, L] = g.useState(!1);
2967
+ disabled: c = !1,
2968
+ required: b = !1,
2969
+ regex: x,
2970
+ paddingless: h = !1,
2971
+ borderless: _ = !1,
2972
+ editable: g = !1,
2973
+ isSearch: u = !1
2974
+ } = r, { themeSettings: w } = qt(), { inputs: q } = w, [k, L] = p.useState(!1);
2952
2975
  function B(f) {
2953
2976
  return Number(f) < 0 ? String(l) : f;
2954
2977
  }
2955
2978
  function S(f) {
2956
- return !x || !$ ? !0 : new RegExp($).test(f);
2979
+ return !b || !x ? !0 : new RegExp(x).test(f);
2957
2980
  }
2958
2981
  return /* @__PURE__ */ t.jsxs("div", { className: et.wrapper, children: [
2959
2982
  s && /* @__PURE__ */ t.jsx(
@@ -2967,7 +2990,7 @@ const da = (r) => {
2967
2990
  /* @__PURE__ */ t.jsxs(
2968
2991
  "div",
2969
2992
  {
2970
- className: z(et.content, {
2993
+ className: F(et.content, {
2971
2994
  [et.contentBorder]: q.border.active
2972
2995
  }),
2973
2996
  style: {
@@ -2980,30 +3003,30 @@ const da = (r) => {
2980
3003
  "input",
2981
3004
  {
2982
3005
  id: s,
2983
- type: a || "text",
3006
+ type: o || "text",
2984
3007
  onChange: (f) => {
2985
- if (a === "text") c(f.target.value);
3008
+ if (o === "text") a(f.target.value);
2986
3009
  else {
2987
3010
  const D = B(f.target.value);
2988
- c(D);
3011
+ a(D);
2989
3012
  }
2990
3013
  },
2991
3014
  value: i,
2992
3015
  autoComplete: "off",
2993
3016
  placeholder: n || "Type something...",
2994
- className: z(et.input, {
2995
- [et.required]: y && x && !S(i),
2996
- [et.paddingless]: _,
2997
- [et.borderless]: h
3017
+ className: F(et.input, {
3018
+ [et.required]: k && b && !S(i),
3019
+ [et.paddingless]: h,
3020
+ [et.borderless]: _
2998
3021
  }),
2999
- min: a === "number" ? l : void 0,
3000
- max: a === "number" ? m : void 0,
3001
- disabled: o,
3022
+ min: o === "number" ? l : void 0,
3023
+ max: o === "number" ? d : void 0,
3024
+ disabled: c,
3002
3025
  onFocus: () => L(!0)
3003
3026
  }
3004
3027
  ),
3005
- d && /* @__PURE__ */ t.jsx("div", { className: et.rightIcon, children: /* @__PURE__ */ t.jsx(
3006
- b,
3028
+ u && /* @__PURE__ */ t.jsx("div", { className: et.rightIcon, children: /* @__PURE__ */ t.jsx(
3029
+ v,
3007
3030
  {
3008
3031
  name: "MagnifyingGlass",
3009
3032
  fill: "var(--icon-secondary)",
@@ -3011,8 +3034,8 @@ const da = (r) => {
3011
3034
  height: q.general.height
3012
3035
  }
3013
3036
  ) }),
3014
- p && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
3015
- b,
3037
+ g && /* @__PURE__ */ t.jsx("div", { children: /* @__PURE__ */ t.jsx(
3038
+ v,
3016
3039
  {
3017
3040
  name: "Sliders",
3018
3041
  width: 20,
@@ -3024,18 +3047,18 @@ const da = (r) => {
3024
3047
  }
3025
3048
  )
3026
3049
  ] });
3027
- }, Qo = "_wrapper_st58d_1", Ko = "_label_st58d_10", Zo = "_textarea_st58d_18", ta = "_length_st58d_33", xt = {
3028
- wrapper: Qo,
3029
- label: Ko,
3030
- textarea: Zo,
3031
- length: ta
3032
- }, _a = (r) => {
3033
- const { onChange: c, label: e, value: s, maxLength: i, placeholder: a = "Type something..." } = r, [l, m] = g.useState(s.length);
3034
- return /* @__PURE__ */ t.jsxs("div", { className: xt.wrapper, children: [
3050
+ }, sa = "_wrapper_st58d_1", na = "_label_st58d_10", ia = "_textarea_st58d_18", oa = "_length_st58d_33", ft = {
3051
+ wrapper: sa,
3052
+ label: na,
3053
+ textarea: ia,
3054
+ length: oa
3055
+ }, ba = (r) => {
3056
+ const { onChange: a, label: e, value: s, maxLength: i, placeholder: o = "Type something..." } = r, [l, d] = p.useState(s.length);
3057
+ return /* @__PURE__ */ t.jsxs("div", { className: ft.wrapper, children: [
3035
3058
  e && /* @__PURE__ */ t.jsx(
3036
3059
  "label",
3037
3060
  {
3038
- className: xt.label,
3061
+ className: ft.label,
3039
3062
  htmlFor: e,
3040
3063
  children: e
3041
3064
  }
@@ -3046,14 +3069,14 @@ const da = (r) => {
3046
3069
  id: e,
3047
3070
  defaultValue: s,
3048
3071
  onChange: (n) => {
3049
- m(n.target.value.length), c(n.target.value);
3072
+ d(n.target.value.length), a(n.target.value);
3050
3073
  },
3051
- placeholder: a,
3052
- className: xt.textarea,
3074
+ placeholder: o,
3075
+ className: ft.textarea,
3053
3076
  maxLength: i
3054
3077
  }
3055
3078
  ),
3056
- i && /* @__PURE__ */ t.jsxs("div", { className: xt.length, children: [
3079
+ i && /* @__PURE__ */ t.jsxs("div", { className: ft.length, children: [
3057
3080
  l,
3058
3081
  "/",
3059
3082
  i
@@ -3061,34 +3084,34 @@ const da = (r) => {
3061
3084
  ] });
3062
3085
  };
3063
3086
  export {
3064
- ma as Accordion,
3087
+ xa as Accordion,
3065
3088
  kt as Button,
3066
- wn as ButtonTypeSettings,
3067
- ca as ButtonsSettings,
3068
- oa as CategorySettings,
3089
+ Tn as ButtonTypeSettings,
3090
+ ma as ButtonsSettings,
3091
+ da as CategorySettings,
3069
3092
  gt as ChooseImage,
3070
- fa as ChooseImageModal,
3071
- Io as EmptyCart,
3072
- aa as FormSettings,
3073
- da as HeaderButtons,
3074
- b as Icon,
3093
+ ya as ChooseImageModal,
3094
+ To as EmptyCart,
3095
+ ua as FormSettings,
3096
+ pa as HeaderButtons,
3097
+ v as Icon,
3075
3098
  W as InputSettings,
3076
- ha as InputUI,
3077
- He as ItemsSettings,
3078
- ia as LayoutSettings,
3079
- la as ListingSelector,
3080
- xa as Loader,
3099
+ fa as InputUI,
3100
+ Fe as ItemsSettings,
3101
+ ra as LayoutSettings,
3102
+ _a as ListingSelector,
3103
+ ka as Loader,
3081
3104
  Et as Modal,
3082
- ra as ProductOptions,
3105
+ ha as ProductOptions,
3083
3106
  At as RangeSelector,
3084
3107
  st as Select,
3085
- ua as ShareLink,
3086
- $o as ShoppingButton,
3087
- No as ShoppingModalCart,
3108
+ ga as ShareLink,
3109
+ Bo as ShoppingButton,
3110
+ So as ShoppingModalCart,
3088
3111
  Z as Switch,
3089
3112
  Rt as TextSettings,
3090
3113
  Ot as TextareaSettings,
3091
- _a as TextareaUI,
3114
+ ba as TextareaUI,
3092
3115
  Lt as TypesText,
3093
- wo as UserInfo
3116
+ Po as UserInfo
3094
3117
  };