@billgangcom/theme-lib 1.118.0 → 1.119.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/dist/{builder-CcLZHVq3.js → builder-DzFcDuDU.js} +5 -5
  2. package/dist/{builder-JKkaOMOl.cjs → builder-J5ldtrWV.cjs} +2 -2
  3. package/dist/{builder-components-B0SvEDG4.cjs → builder-components-BoDoFia9.cjs} +1 -1
  4. package/dist/{builder-components-Dl3dEzV6.js → builder-components-ucfPTdxb.js} +4 -4
  5. package/dist/builder.cjs.js +1 -1
  6. package/dist/builder.es.js +44 -44
  7. package/dist/charge-CIrLvwjQ.cjs +109 -0
  8. package/dist/{charge-DC4f3U8I.js → charge-CkFhM3y1.js} +6862 -7143
  9. package/dist/{checkout-B_qFvrUF.js → checkout-9Jay4luu.js} +5 -5
  10. package/dist/{checkout-BaZLmyfk.cjs → checkout-B6bZNOGK.cjs} +1 -1
  11. package/dist/exports.cjs.js +1 -1
  12. package/dist/exports.es.js +25 -24
  13. package/dist/{index-Bh3_Rczn.js → index-53U3IdCJ.js} +1 -1
  14. package/dist/{index-C-SrHRJh.js → index-BBjyo7G6.js} +12 -12
  15. package/dist/{index-BqtOxv5i.js → index-BEyHjESz.js} +5 -5
  16. package/dist/{index-D4Hp4-Qp.cjs → index-BVukctWW.cjs} +1 -1
  17. package/dist/{index-Ek3qYkbu.js → index-BaOPUHM8.js} +5 -5
  18. package/dist/{index-DtcojRuS.cjs → index-BvQuZZ3i.cjs} +1 -1
  19. package/dist/{index-BtQ89Hj3.cjs → index-C5VbWkjb.cjs} +1 -1
  20. package/dist/{index-CyiCR5lK.cjs → index-CvGiwrdP.cjs} +1 -1
  21. package/dist/{index-BFZm601D.js → index-DECUT1Xe.js} +5 -5
  22. package/dist/{index-CmO3iWeV.cjs → index-fGH2ZXNu.cjs} +1 -1
  23. package/dist/index.cjs.js +1 -1
  24. package/dist/index.es.js +9 -9
  25. package/dist/{order-t2QoTU6S.cjs → order-BL887gLb.cjs} +1 -1
  26. package/dist/{order-Bd24i-W3.js → order-CKVOrGVA.js} +5 -5
  27. package/dist/src/exports.d.ts +1 -0
  28. package/dist/src/lib/createTicket.d.ts +1 -1
  29. package/dist/src/pages/ticket/model.d.ts +6 -1
  30. package/dist/src/storefront/api/ticket.d.ts +4 -1
  31. package/dist/src/ui/ImagesLoader/example.d.ts +18 -0
  32. package/dist/src/ui/ImagesLoader/index.d.ts +30 -0
  33. package/dist/src/ui/index.d.ts +1 -0
  34. package/dist/style.css +1 -1
  35. package/dist/{subscription-CqhnWDq_.js → subscription-73bl_3mQ.js} +5 -5
  36. package/dist/{subscription-DHhmsQxH.cjs → subscription-DzDsbagC.cjs} +1 -1
  37. package/dist/ticket-DcS7ghEG.cjs +108 -0
  38. package/dist/{ticket-r3Kx22M9.js → ticket-DnMgS6P-.js} +480 -401
  39. package/dist/{top-up-Ba_v68et.cjs → top-up-BW2_KFwo.cjs} +1 -1
  40. package/dist/{top-up-9OWzVCVP.js → top-up-xA00mj-1.js} +5 -5
  41. package/dist/{ui-components-BGzv0KT2.js → ui-components-BVKhtpkS.js} +2905 -2666
  42. package/dist/ui-components-Dggjc69e.cjs +1 -0
  43. package/dist/ui.cjs.js +1 -1
  44. package/dist/ui.es.js +39 -38
  45. package/dist/{validation-BUpHL2xL.js → validation-BdRe9zY0.js} +5 -5
  46. package/dist/{validation-D3IO5HzB.cjs → validation-zwszvSxz.cjs} +1 -1
  47. package/package.json +1 -1
  48. package/dist/charge-LGilmNUv.cjs +0 -109
  49. package/dist/ticket-Cv2XbF6y.cjs +0 -108
  50. package/dist/ui-components-C4hKK4aN.cjs +0 -1
@@ -1,38 +1,38 @@
1
- var ee = Object.defineProperty;
2
- var oe = (n, r, e) => r in n ? ee(n, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[r] = e;
3
- var D = (n, r, e) => oe(n, typeof r != "symbol" ? r + "" : r, e);
4
- import { jsx as i, jsxs as m, Fragment as ne } from "react/jsx-runtime";
1
+ var se = Object.defineProperty;
2
+ var Ie = (n, r, e) => r in n ? se(n, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[r] = e;
3
+ var H = (n, r, e) => Ie(n, typeof r != "symbol" ? r + "" : r, e);
4
+ import { jsx as a, jsxs as h, Fragment as ue } from "react/jsx-runtime";
5
5
  import p from "react";
6
- import { j as q, M as z, r as j, aa as re, e as E, v as N, O as te, X as ce, p as U, K as x, c as X, a as V, b as O, f as B, ab as ae, u as ie, V as K } from "./builder-CcLZHVq3.js";
7
- import { y as le, z as se, N as Ie, P as ue, B as de, D as R, E as pe, F as ge, u as he, H as Se, Q as me, U as Ce } from "./charge-DC4f3U8I.js";
8
- import { e as F, g as _, E as G, I as we } from "./ui-components-BGzv0KT2.js";
9
- import { R as J, a as Y, b as Q, c as fe } from "./builder-components-Dl3dEzV6.js";
6
+ import { j as Q, M as Z, r as ee, aa as de, e as W, v as G, O as pe, X as ge, p as $, K as U, c as oe, a as ne, b as q, f as R, ab as he, u as Se, V as re, J as me } from "./builder-DzFcDuDU.js";
7
+ import { y as Ce, z as we, N as fe, P as ye, B as be, D as N, E as ke, F as Le, u as Te, H as Ae, Q as Pe, U as Be } from "./charge-CkFhM3y1.js";
8
+ import { e as v, g as V, E as j, k as Fe, I as K, M as De } from "./ui-components-BVKhtpkS.js";
9
+ import { R as te, a as ce, b as ae, c as Re } from "./builder-components-ucfPTdxb.js";
10
10
  import "react-dom";
11
- import "./checkout-B_qFvrUF.js";
12
- const ye = "_wrapper_1vt13_1", be = "_bg_1vt13_10", Le = "_main_1vt13_32", ke = "_noAnimation_1vt13_37", Te = "_loading_1vt13_51", Ae = "_loadingContent_1vt13_61", Pe = "_loader_1vt13_66", T = {
13
- wrapper: ye,
14
- bg: be,
15
- main: Le,
16
- noAnimation: ke,
17
- loading: Te,
18
- loadingContent: Ae,
19
- loader: Pe
20
- }, Be = async (n, r) => {
21
- const e = q.getState().apiUrls, o = z ? localStorage.getItem("fakeDomain") || "flagship-theme.pages.dev" : window.location.hostname, l = localStorage.getItem("shopPassword");
22
- if (r && !l)
11
+ import "./checkout-9Jay4luu.js";
12
+ const ve = "_wrapper_1vt13_1", Me = "_bg_1vt13_10", xe = "_main_1vt13_32", He = "_noAnimation_1vt13_37", Ne = "_loading_1vt13_51", Ee = "_loadingContent_1vt13_61", Ue = "_loader_1vt13_66", P = {
13
+ wrapper: ve,
14
+ bg: Me,
15
+ main: xe,
16
+ noAnimation: He,
17
+ loading: Ne,
18
+ loadingContent: Ee,
19
+ loader: Ue
20
+ }, Oe = async (n, r) => {
21
+ const e = Q.getState().apiUrls, o = Z ? localStorage.getItem("fakeDomain") || "flagship-theme.pages.dev" : window.location.hostname, i = localStorage.getItem("shopPassword");
22
+ if (r && !i)
23
23
  return null;
24
- const t = `${e.storeApi}/v2/shops/${o}/pages/${n}` + (r ? `?password=${l}` : "");
24
+ const t = `${e.storeApi}/v2/shops/${o}/pages/${n}` + (r ? `?password=${i}` : "");
25
25
  try {
26
- return await j({
26
+ return await ee({
27
27
  url: t,
28
28
  withToken: !0,
29
29
  method: "get"
30
30
  });
31
31
  } catch (c) {
32
- if (re.isAxiosError(c) && c.response && c.response.status === 404)
32
+ if (de.isAxiosError(c) && c.response && c.response.status === 404)
33
33
  return null;
34
34
  }
35
- }, Lo = [
35
+ }, Oo = [
36
36
  "Acorn",
37
37
  "AcornIcon",
38
38
  "ActivityIcon",
@@ -3078,11 +3078,11 @@ const ye = "_wrapper_1vt13_1", be = "_bg_1vt13_10", Le = "_main_1vt13_32", ke =
3078
3078
  "YoutubeLogo",
3079
3079
  "YoutubeLogoIcon"
3080
3080
  ];
3081
- var Fe = /* @__PURE__ */ ((n) => (n.ICON_LINK = "--icon-link", n.ICON_ERROR = "--icon-error", n.ICON_ACTION = "--icon-action", n.ICON_PRIMARY = "--icon-primary", n.ICON_SUCCESS = "--icon-success", n.ICON_WARNING = "--icon-warning", n.ICON_DISABLED = "--icon-disabled", n.ICON_INVERTED = "--icon-inverted", n.ICON_TERTIARY = "--icon-tertiary", n.ICON_SECONDARY = "--icon-secondary", n.ICON_ACTION_HOVER = "--icon-actionHover", n.ICON_INFORMATION = "--icon-information", n.TEXT_LINK = "--text-link", n.TEXT_ERROR = "--text-error", n.TEXT_ACTION = "--text-action", n.TEXT_PRIMARY = "--text-primary", n.TEXT_SUCCESS = "--text-success", n.TEXT_WARNING = "--text-warning", n.TEXT_DISABLED = "--text-disabled", n.TEXT_INVERTED = "--text-inverted", n.TEXT_TERTIARY = "--text-tertiary", n.TEXT_SECONDARY = "--text-secondary", n.TEXT_ACTION_HOVER = "--text-actionHover", n.TEXT_INFORMATION = "--text-information", n.BORDER_ERROR = "--border-error", n.BORDER_FOCUS = "--border-focus", n.BORDER_ACTION = "--border-action", n.BORDER_PRIMARY = "--border-primary", n.BORDER_SUCCESS = "--border-success", n.BORDER_WARNING = "--border-warning", n.BORDER_DISABLED = "--border-disabled", n.BORDER_SECONDARY = "--border-secondary", n.BORDER_ACTION_HOVER = "--border-actionHover", n.BORDER_INFORMATION = "--border-information", n.SURFACE_ERROR = "--surface-error", n.SURFACE_MODAL = "--surface-modal", n.SURFACE_ACTION1 = "--surface-action1", n.SURFACE_ACTION2 = "--surface-action2", n.SURFACE_PRIMARY = "--surface-primary", n.SURFACE_SUCCESS = "--surface-success", n.SURFACE_WARNING = "--surface-warning", n.SURFACE_DISABLED = "--surface-disabled", n.SURFACE_SECONDARY = "--surface-secondary", n.SURFACE_INFORMATION = "--surface-information", n.SURFACE_ACTION1_HOVER = "--surface-action1Hover", n.SURFACE_ACTION2_HOVER = "--surface-action2Hover", n))(Fe || {});
3082
- const ko = [
3081
+ var _e = /* @__PURE__ */ ((n) => (n.ICON_LINK = "--icon-link", n.ICON_ERROR = "--icon-error", n.ICON_ACTION = "--icon-action", n.ICON_PRIMARY = "--icon-primary", n.ICON_SUCCESS = "--icon-success", n.ICON_WARNING = "--icon-warning", n.ICON_DISABLED = "--icon-disabled", n.ICON_INVERTED = "--icon-inverted", n.ICON_TERTIARY = "--icon-tertiary", n.ICON_SECONDARY = "--icon-secondary", n.ICON_ACTION_HOVER = "--icon-actionHover", n.ICON_INFORMATION = "--icon-information", n.TEXT_LINK = "--text-link", n.TEXT_ERROR = "--text-error", n.TEXT_ACTION = "--text-action", n.TEXT_PRIMARY = "--text-primary", n.TEXT_SUCCESS = "--text-success", n.TEXT_WARNING = "--text-warning", n.TEXT_DISABLED = "--text-disabled", n.TEXT_INVERTED = "--text-inverted", n.TEXT_TERTIARY = "--text-tertiary", n.TEXT_SECONDARY = "--text-secondary", n.TEXT_ACTION_HOVER = "--text-actionHover", n.TEXT_INFORMATION = "--text-information", n.BORDER_ERROR = "--border-error", n.BORDER_FOCUS = "--border-focus", n.BORDER_ACTION = "--border-action", n.BORDER_PRIMARY = "--border-primary", n.BORDER_SUCCESS = "--border-success", n.BORDER_WARNING = "--border-warning", n.BORDER_DISABLED = "--border-disabled", n.BORDER_SECONDARY = "--border-secondary", n.BORDER_ACTION_HOVER = "--border-actionHover", n.BORDER_INFORMATION = "--border-information", n.SURFACE_ERROR = "--surface-error", n.SURFACE_MODAL = "--surface-modal", n.SURFACE_ACTION1 = "--surface-action1", n.SURFACE_ACTION2 = "--surface-action2", n.SURFACE_PRIMARY = "--surface-primary", n.SURFACE_SUCCESS = "--surface-success", n.SURFACE_WARNING = "--surface-warning", n.SURFACE_DISABLED = "--surface-disabled", n.SURFACE_SECONDARY = "--surface-secondary", n.SURFACE_INFORMATION = "--surface-information", n.SURFACE_ACTION1_HOVER = "--surface-action1Hover", n.SURFACE_ACTION2_HOVER = "--surface-action2Hover", n))(_e || {});
3082
+ const _o = [
3083
3083
  {
3084
3084
  value: "4:3",
3085
- addon: /* @__PURE__ */ i(
3085
+ addon: /* @__PURE__ */ a(
3086
3086
  "div",
3087
3087
  {
3088
3088
  style: {
@@ -3092,7 +3092,7 @@ const ko = [
3092
3092
  alignItems: "center",
3093
3093
  justifyContent: "center"
3094
3094
  },
3095
- children: /* @__PURE__ */ i(
3095
+ children: /* @__PURE__ */ a(
3096
3096
  "div",
3097
3097
  {
3098
3098
  style: {
@@ -3108,7 +3108,7 @@ const ko = [
3108
3108
  },
3109
3109
  {
3110
3110
  value: "16:9",
3111
- addon: /* @__PURE__ */ i(
3111
+ addon: /* @__PURE__ */ a(
3112
3112
  "div",
3113
3113
  {
3114
3114
  style: {
@@ -3118,7 +3118,7 @@ const ko = [
3118
3118
  alignItems: "center",
3119
3119
  justifyContent: "center"
3120
3120
  },
3121
- children: /* @__PURE__ */ i(
3121
+ children: /* @__PURE__ */ a(
3122
3122
  "div",
3123
3123
  {
3124
3124
  style: {
@@ -3134,7 +3134,7 @@ const ko = [
3134
3134
  },
3135
3135
  {
3136
3136
  value: "9:16",
3137
- addon: /* @__PURE__ */ i(
3137
+ addon: /* @__PURE__ */ a(
3138
3138
  "div",
3139
3139
  {
3140
3140
  style: {
@@ -3144,7 +3144,7 @@ const ko = [
3144
3144
  alignItems: "center",
3145
3145
  justifyContent: "center"
3146
3146
  },
3147
- children: /* @__PURE__ */ i(
3147
+ children: /* @__PURE__ */ a(
3148
3148
  "div",
3149
3149
  {
3150
3150
  style: {
@@ -3160,7 +3160,7 @@ const ko = [
3160
3160
  },
3161
3161
  {
3162
3162
  value: "1:1",
3163
- addon: /* @__PURE__ */ i(
3163
+ addon: /* @__PURE__ */ a(
3164
3164
  "div",
3165
3165
  {
3166
3166
  style: {
@@ -3170,7 +3170,7 @@ const ko = [
3170
3170
  alignItems: "center",
3171
3171
  justifyContent: "center"
3172
3172
  },
3173
- children: /* @__PURE__ */ i(
3173
+ children: /* @__PURE__ */ a(
3174
3174
  "div",
3175
3175
  {
3176
3176
  style: {
@@ -3184,11 +3184,11 @@ const ko = [
3184
3184
  }
3185
3185
  )
3186
3186
  }
3187
- ], To = (n) => {
3188
- const { notifications: r, setNotifications: e } = E.getState();
3187
+ ], Go = (n) => {
3188
+ const { notifications: r, setNotifications: e } = W.getState();
3189
3189
  e(r.filter((o) => o.id !== n));
3190
- }, Ao = (n) => {
3191
- const { notifications: r, setNotifications: e } = E.getState(), o = N();
3190
+ }, Wo = (n) => {
3191
+ const { notifications: r, setNotifications: e } = W.getState(), o = G();
3192
3192
  return e([
3193
3193
  ...r,
3194
3194
  {
@@ -3197,37 +3197,37 @@ const ko = [
3197
3197
  }
3198
3198
  ]), o;
3199
3199
  };
3200
- class De {
3200
+ class Ge {
3201
3201
  constructor() {
3202
- D(this, "observer", null);
3203
- D(this, "callbacks", /* @__PURE__ */ new Map());
3204
- D(this, "handleWindowResize", () => {
3202
+ H(this, "observer", null);
3203
+ H(this, "callbacks", /* @__PURE__ */ new Map());
3204
+ H(this, "handleWindowResize", () => {
3205
3205
  this.callbacks.forEach((r, e) => {
3206
3206
  const o = e.getBoundingClientRect().width;
3207
- r.forEach((l) => l(o));
3207
+ r.forEach((i) => i(o));
3208
3208
  });
3209
3209
  });
3210
3210
  this.observer = new ResizeObserver((r) => {
3211
3211
  var e;
3212
3212
  for (const o of r) {
3213
- const l = o.contentRect.width, t = o.target;
3214
- this.callbacks.has(t) && ((e = this.callbacks.get(t)) == null || e.forEach((c) => c(l)));
3213
+ const i = o.contentRect.width, t = o.target;
3214
+ this.callbacks.has(t) && ((e = this.callbacks.get(t)) == null || e.forEach((c) => c(i)));
3215
3215
  }
3216
3216
  }), window.addEventListener("resize", this.handleWindowResize);
3217
3217
  }
3218
3218
  observe(r, e) {
3219
- var l;
3219
+ var i;
3220
3220
  if (!this.observer) return;
3221
- this.callbacks.has(r) || (this.callbacks.set(r, []), this.observer.observe(r)), (this.callbacks.get(r) || []).includes(e) || (l = this.callbacks.get(r)) == null || l.push(e);
3221
+ this.callbacks.has(r) || (this.callbacks.set(r, []), this.observer.observe(r)), (this.callbacks.get(r) || []).includes(e) || (i = this.callbacks.get(r)) == null || i.push(e);
3222
3222
  }
3223
3223
  unobserve(r, e) {
3224
3224
  var o;
3225
3225
  if (!(!this.observer || !this.callbacks.has(r))) {
3226
3226
  if (e) {
3227
- const l = this.callbacks.get(r) || [];
3227
+ const i = this.callbacks.get(r) || [];
3228
3228
  this.callbacks.set(
3229
3229
  r,
3230
- l.filter((t) => t !== e)
3230
+ i.filter((t) => t !== e)
3231
3231
  );
3232
3232
  }
3233
3233
  (o = this.callbacks.get(r)) != null && o.length || (this.callbacks.delete(r), this.observer.unobserve(r));
@@ -3238,83 +3238,83 @@ class De {
3238
3238
  this.observer && (this.observer.disconnect(), this.observer = null), this.callbacks.clear(), window.removeEventListener("resize", this.handleWindowResize);
3239
3239
  }
3240
3240
  }
3241
- const W = new De();
3242
- function Po(n) {
3241
+ const J = new Ge();
3242
+ function $o(n) {
3243
3243
  const [r, e] = p.useState("desktop");
3244
3244
  return p.useEffect(() => {
3245
3245
  const o = n.current;
3246
3246
  if (!o) return;
3247
- const l = (s) => s >= 1081 ? "desktop" : s >= 720 ? "tablet" : "mobile", t = (s) => {
3248
- const I = l(s);
3249
- e(I);
3247
+ const i = (s) => s >= 1081 ? "desktop" : s >= 720 ? "tablet" : "mobile", t = (s) => {
3248
+ const u = i(s);
3249
+ e(u);
3250
3250
  };
3251
- W.observe(o, t);
3251
+ J.observe(o, t);
3252
3252
  const c = o.getBoundingClientRect().width;
3253
3253
  return t(c), () => {
3254
- W.unobserve(o, t);
3254
+ J.unobserve(o, t);
3255
3255
  };
3256
3256
  }, [n]), r;
3257
3257
  }
3258
- const Bo = () => {
3259
- const { balance: n, setBalance: r } = te();
3258
+ const qo = () => {
3259
+ const { balance: n, setBalance: r } = pe();
3260
3260
  return p.useEffect(() => {
3261
3261
  n || (async () => {
3262
3262
  if (!localStorage.getItem("token")) return;
3263
- const l = await le();
3264
- r(l);
3263
+ const i = await Ce();
3264
+ r(i);
3265
3265
  })();
3266
3266
  }, [n]), n;
3267
- }, Re = "_wrapper_ysrl4_1", ve = "_tableContainer_ysrl4_6", xe = "_ticketsTable_ysrl4_19", Me = "_tableItem_ysrl4_37", He = "_tableLoader_ysrl4_41", k = {
3268
- wrapper: Re,
3269
- tableContainer: ve,
3270
- ticketsTable: xe,
3271
- tableItem: Me,
3272
- tableLoader: He
3273
- }, Ne = async (n = 1) => {
3267
+ }, We = "_wrapper_ysrl4_1", $e = "_tableContainer_ysrl4_6", qe = "_ticketsTable_ysrl4_19", ze = "_tableItem_ysrl4_37", Xe = "_tableLoader_ysrl4_41", T = {
3268
+ wrapper: We,
3269
+ tableContainer: $e,
3270
+ ticketsTable: qe,
3271
+ tableItem: ze,
3272
+ tableLoader: Xe
3273
+ }, Ve = async (n = 1) => {
3274
3274
  try {
3275
- return await se({ PageNumber: n });
3275
+ return await we({ PageNumber: n });
3276
3276
  } catch (r) {
3277
3277
  return console.error("Failed to fetch tickets:", r), {
3278
3278
  list: [],
3279
3279
  totalCount: 0
3280
3280
  };
3281
3281
  }
3282
- }, Fo = () => {
3283
- const [n, r] = p.useState(null), { page: e, setPage: o } = ce(), [l, t] = p.useState(!0), [c, s] = p.useState(0);
3282
+ }, zo = () => {
3283
+ const [n, r] = p.useState(null), { page: e, setPage: o } = ge(), [i, t] = p.useState(!0), [c, s] = p.useState(0);
3284
3284
  p.useEffect(() => {
3285
3285
  (async () => {
3286
3286
  t(!0);
3287
- const { list: y, totalCount: C } = await Ne(e);
3288
- r(y), s(C), t(!1);
3287
+ const { list: k, totalCount: C } = await Ve(e);
3288
+ r(k), s(C), t(!1);
3289
3289
  })();
3290
3290
  }, [e]);
3291
- const I = !l && n;
3292
- return I && n.length === 0 ? /* @__PURE__ */ i(
3293
- Ie,
3291
+ const u = !i && n;
3292
+ return u && n.length === 0 ? /* @__PURE__ */ a(
3293
+ fe,
3294
3294
  {
3295
3295
  title: "Tickets",
3296
3296
  description: "You don't have any tickets yet. If you contact support, tickets will be displayed here.",
3297
3297
  centered: !0
3298
3298
  }
3299
- ) : /* @__PURE__ */ m("div", { className: k.wrapper, children: [
3300
- /* @__PURE__ */ i(ue, { title: "Tickets" }),
3301
- /* @__PURE__ */ m("div", { className: k.tableContainer, children: [
3302
- /* @__PURE__ */ m(de, { className: k.ticketsTable, children: [
3303
- /* @__PURE__ */ i(R, { className: k.tableItem, children: "TICKET ID" }),
3304
- /* @__PURE__ */ i(R, { className: k.tableItem, children: "LAST MESSAGE" }),
3305
- /* @__PURE__ */ i(R, { className: k.tableItem, children: "CREATED" }),
3306
- /* @__PURE__ */ i(R, { className: k.tableItem, children: "STATUS" }),
3307
- I && (n == null ? void 0 : n.map((S) => /* @__PURE__ */ i(
3308
- pe,
3299
+ ) : /* @__PURE__ */ h("div", { className: T.wrapper, children: [
3300
+ /* @__PURE__ */ a(ye, { title: "Tickets" }),
3301
+ /* @__PURE__ */ h("div", { className: T.tableContainer, children: [
3302
+ /* @__PURE__ */ h(be, { className: T.ticketsTable, children: [
3303
+ /* @__PURE__ */ a(N, { className: T.tableItem, children: "TICKET ID" }),
3304
+ /* @__PURE__ */ a(N, { className: T.tableItem, children: "LAST MESSAGE" }),
3305
+ /* @__PURE__ */ a(N, { className: T.tableItem, children: "CREATED" }),
3306
+ /* @__PURE__ */ a(N, { className: T.tableItem, children: "STATUS" }),
3307
+ u && (n == null ? void 0 : n.map((m) => /* @__PURE__ */ a(
3308
+ ke,
3309
3309
  {
3310
- item: S
3310
+ item: m
3311
3311
  },
3312
- S.id
3312
+ m.id
3313
3313
  )))
3314
3314
  ] }),
3315
- !I && /* @__PURE__ */ i("div", { className: k.tableLoader, children: /* @__PURE__ */ i(F, {}) }),
3316
- I && /* @__PURE__ */ i(
3317
- ge,
3315
+ !u && /* @__PURE__ */ a("div", { className: T.tableLoader, children: /* @__PURE__ */ a(v, {}) }),
3316
+ u && /* @__PURE__ */ a(
3317
+ Le,
3318
3318
  {
3319
3319
  currentPage: e,
3320
3320
  totalCount: c,
@@ -3323,13 +3323,13 @@ const Bo = () => {
3323
3323
  )
3324
3324
  ] })
3325
3325
  ] });
3326
- }, Ee = "_wrapper_rccv2_1", Ue = "_content_rccv2_11", Oe = "_title_rccv2_21", M = {
3327
- wrapper: Ee,
3328
- content: Ue,
3329
- title: Oe
3330
- }, _e = () => {
3331
- const n = U(), { isAntistock: r } = x();
3332
- return r ? /* @__PURE__ */ m(
3326
+ }, je = "_wrapper_rccv2_1", Ke = "_content_rccv2_11", Je = "_title_rccv2_21", O = {
3327
+ wrapper: je,
3328
+ content: Ke,
3329
+ title: Je
3330
+ }, Ye = () => {
3331
+ const n = $(), { isAntistock: r } = U();
3332
+ return r ? /* @__PURE__ */ h(
3333
3333
  "div",
3334
3334
  {
3335
3335
  style: {
@@ -3343,9 +3343,9 @@ const Bo = () => {
3343
3343
  color: "var(--text-primary)"
3344
3344
  },
3345
3345
  children: [
3346
- /* @__PURE__ */ i(J, {}),
3347
- /* @__PURE__ */ i(Y, {}),
3348
- /* @__PURE__ */ m(
3346
+ /* @__PURE__ */ a(te, {}),
3347
+ /* @__PURE__ */ a(ce, {}),
3348
+ /* @__PURE__ */ h(
3349
3349
  "div",
3350
3350
  {
3351
3351
  style: {
@@ -3357,7 +3357,7 @@ const Bo = () => {
3357
3357
  gap: "24px"
3358
3358
  },
3359
3359
  children: [
3360
- /* @__PURE__ */ i(
3360
+ /* @__PURE__ */ a(
3361
3361
  "h2",
3362
3362
  {
3363
3363
  style: {
@@ -3367,8 +3367,8 @@ const Bo = () => {
3367
3367
  children: "404 Not Found"
3368
3368
  }
3369
3369
  ),
3370
- /* @__PURE__ */ i(
3371
- _,
3370
+ /* @__PURE__ */ a(
3371
+ V,
3372
3372
  {
3373
3373
  type: "Primary",
3374
3374
  onClick: () => n("/"),
@@ -3378,13 +3378,13 @@ const Bo = () => {
3378
3378
  ]
3379
3379
  }
3380
3380
  ),
3381
- /* @__PURE__ */ i(Q, {})
3381
+ /* @__PURE__ */ a(ae, {})
3382
3382
  ]
3383
3383
  }
3384
- ) : /* @__PURE__ */ i("div", { className: M.wrapper, children: /* @__PURE__ */ m("div", { className: M.content, children: [
3385
- /* @__PURE__ */ i("h1", { className: M.title, children: "Page Not Found" }),
3386
- /* @__PURE__ */ i(
3387
- _,
3384
+ ) : /* @__PURE__ */ a("div", { className: O.wrapper, children: /* @__PURE__ */ h("div", { className: O.content, children: [
3385
+ /* @__PURE__ */ a("h1", { className: O.title, children: "Page Not Found" }),
3386
+ /* @__PURE__ */ a(
3387
+ V,
3388
3388
  {
3389
3389
  type: "Primary",
3390
3390
  onClick: () => n("/"),
@@ -3392,7 +3392,7 @@ const Bo = () => {
3392
3392
  }
3393
3393
  )
3394
3394
  ] }) });
3395
- }, $ = {
3395
+ }, Y = {
3396
3396
  "/": "Home",
3397
3397
  "/products": "Products",
3398
3398
  "/reviews": "Reviews",
@@ -3401,143 +3401,143 @@ const Bo = () => {
3401
3401
  "/faq": "FAQ",
3402
3402
  "/support": "Support",
3403
3403
  "/cart": "Cart"
3404
- }, Ge = ({ pagePath: n }) => {
3405
- const { sourceBlocks: r } = X(), e = U(), [o, l] = p.useState(null), [t, c] = p.useState(!0), [s, I] = p.useState(null), { settings: S } = V(), { addProducts: y } = he(), { pageContext: C } = O(), { isAntistock: d, general: h } = x();
3404
+ }, Qe = ({ pagePath: n }) => {
3405
+ const { sourceBlocks: r } = oe(), e = $(), [o, i] = p.useState(null), [t, c] = p.useState(!0), [s, u] = p.useState(null), { settings: m } = ne(), { addProducts: k } = Te(), { pageContext: C } = q(), { isAntistock: w, general: g } = U();
3406
3406
  p.useEffect(() => {
3407
- var g, b;
3408
- if (n === "/support" && ((g = h == null ? void 0 : h.info) != null && g.disableSupport)) {
3409
- const a = (b = h == null ? void 0 : h.info) == null ? void 0 : b.thirdPartySupportUrl;
3410
- a ? window.open(a, "_self") : e("/", { replace: !0 });
3407
+ var S, L;
3408
+ if (n === "/support" && ((S = g == null ? void 0 : g.info) != null && S.disableSupport)) {
3409
+ const l = (L = g == null ? void 0 : g.info) == null ? void 0 : L.thirdPartySupportUrl;
3410
+ l ? window.open(l, "_self") : e("/", { replace: !0 });
3411
3411
  }
3412
- }, [n, h]), p.useEffect(() => {
3412
+ }, [n, g]), p.useEffect(() => {
3413
3413
  c(!0);
3414
- const g = async () => {
3415
- const b = await Be(
3414
+ const S = async () => {
3415
+ const L = await Oe(
3416
3416
  encodeURIComponent(n),
3417
- h == null ? void 0 : h.info.passwordProtected
3417
+ g == null ? void 0 : g.info.passwordProtected
3418
3418
  );
3419
- if (b) {
3420
- const { data: a } = b;
3421
- if (a.seo && a.seo.pageTitle ? document.title = a.seo.pageTitle : $[n] ? document.title = $[n] : a.products.length > 0 ? document.title = `Product | ${a.products[0].name}` : a.fullPosts.length > 0 && (document.title = `Post | ${a.fullPosts[0].title}`), a.preserveContent) {
3422
- const w = {
3423
- order: [...(s == null ? void 0 : s.order) ?? [], ...a.layout.order],
3419
+ if (L) {
3420
+ const { data: l } = L;
3421
+ if (l.seo && l.seo.pageTitle ? document.title = l.seo.pageTitle : Y[n] ? document.title = Y[n] : l.products.length > 0 ? document.title = `Product | ${l.products[0].name}` : l.fullPosts.length > 0 && (document.title = `Post | ${l.fullPosts[0].title}`), l.preserveContent) {
3422
+ const y = {
3423
+ order: [...(s == null ? void 0 : s.order) ?? [], ...l.layout.order],
3424
3424
  data: {
3425
3425
  ...s == null ? void 0 : s.data,
3426
- ...a.layout.data
3426
+ ...l.layout.data
3427
3427
  }
3428
3428
  };
3429
- I(w);
3429
+ u(y);
3430
3430
  } else
3431
- I(a.layout);
3432
- const L = a.listings.filter(
3433
- (w) => w.type === "PRODUCT" || w.type === "GROUP"
3434
- ), f = L && L.length > 0 ? a.listings : [...C.listings ?? [], ...a.listings];
3435
- if (a.preserveContent) {
3436
- const w = {
3431
+ u(l.layout);
3432
+ const M = l.listings.filter(
3433
+ (y) => y.type === "PRODUCT" || y.type === "GROUP"
3434
+ ), F = M && M.length > 0 ? l.listings : [...C.listings ?? [], ...l.listings];
3435
+ if (l.preserveContent) {
3436
+ const y = {
3437
3437
  ...C,
3438
- products: [...(o == null ? void 0 : o.products) ?? [], ...a.products],
3439
- reviews: [...(o == null ? void 0 : o.reviews) ?? [], ...a.reviews],
3440
- categories: [...(o == null ? void 0 : o.categories) ?? [], ...a.categories],
3441
- faqs: [...(o == null ? void 0 : o.faqs) ?? [], ...a.faqs],
3442
- general: a.general,
3443
- fullPosts: [...(o == null ? void 0 : o.fullPosts) ?? [], ...a.fullPosts],
3444
- posts: [...(o == null ? void 0 : o.posts) ?? [], ...a.posts],
3445
- preserveContent: a.preserveContent,
3446
- listings: f,
3447
- vouches: [...(o == null ? void 0 : o.vouches) ?? [], ...a.vouches]
3438
+ products: [...(o == null ? void 0 : o.products) ?? [], ...l.products],
3439
+ reviews: [...(o == null ? void 0 : o.reviews) ?? [], ...l.reviews],
3440
+ categories: [...(o == null ? void 0 : o.categories) ?? [], ...l.categories],
3441
+ faqs: [...(o == null ? void 0 : o.faqs) ?? [], ...l.faqs],
3442
+ general: l.general,
3443
+ fullPosts: [...(o == null ? void 0 : o.fullPosts) ?? [], ...l.fullPosts],
3444
+ posts: [...(o == null ? void 0 : o.posts) ?? [], ...l.posts],
3445
+ preserveContent: l.preserveContent,
3446
+ listings: F,
3447
+ vouches: [...(o == null ? void 0 : o.vouches) ?? [], ...l.vouches]
3448
3448
  };
3449
- l(w);
3449
+ i(y);
3450
3450
  } else
3451
- l({
3451
+ i({
3452
3452
  ...C,
3453
- products: a.products,
3454
- reviews: a.reviews,
3455
- categories: a.categories,
3456
- faqs: a.faqs,
3457
- general: a.general,
3458
- fullPosts: a.fullPosts,
3459
- posts: a.posts,
3460
- preserveContent: a.preserveContent,
3461
- listings: f,
3462
- vouches: a.vouches
3453
+ products: l.products,
3454
+ reviews: l.reviews,
3455
+ categories: l.categories,
3456
+ faqs: l.faqs,
3457
+ general: l.general,
3458
+ fullPosts: l.fullPosts,
3459
+ posts: l.posts,
3460
+ preserveContent: l.preserveContent,
3461
+ listings: F,
3462
+ vouches: l.vouches
3463
3463
  });
3464
- y(a.products);
3464
+ k(l.products);
3465
3465
  }
3466
3466
  c(!1);
3467
3467
  };
3468
- C.listings && h && g();
3469
- }, [n, C.listings, h]);
3470
- const A = (g) => {
3471
- if (!g || !g.name)
3472
- return /* @__PURE__ */ i(G, { error: "Block or block.name is undefined." });
3473
- if (!r || !r[g.name])
3474
- return /* @__PURE__ */ i(G, { error: `Block "${g.name}" does not exist in blocks.` });
3475
- const b = new r[g.name]();
3476
- return g.value && Object.assign(b, g.value), b.renderBlock(S, o);
3468
+ C.listings && g && S();
3469
+ }, [n, C.listings, g]);
3470
+ const B = (S) => {
3471
+ if (!S || !S.name)
3472
+ return /* @__PURE__ */ a(j, { error: "Block or block.name is undefined." });
3473
+ if (!r || !r[S.name])
3474
+ return /* @__PURE__ */ a(j, { error: `Block "${S.name}" does not exist in blocks.` });
3475
+ const L = new r[S.name]();
3476
+ return S.value && Object.assign(L, S.value), L.renderBlock(m, o);
3477
3477
  };
3478
- return !t && s === null ? /* @__PURE__ */ i(_e, {}) : /* @__PURE__ */ m(
3478
+ return !t && s === null ? /* @__PURE__ */ a(Ye, {}) : /* @__PURE__ */ h(
3479
3479
  "div",
3480
3480
  {
3481
- className: B(T.wrapper, {
3482
- [T.bg]: !d,
3483
- [T.loadingContent]: t
3481
+ className: R(P.wrapper, {
3482
+ [P.bg]: !w,
3483
+ [P.loadingContent]: t
3484
3484
  }),
3485
3485
  children: [
3486
- /* @__PURE__ */ i(J, {}),
3487
- /* @__PURE__ */ i(
3488
- Y,
3486
+ /* @__PURE__ */ a(te, {}),
3487
+ /* @__PURE__ */ a(
3488
+ ce,
3489
3489
  {
3490
- settings: S,
3490
+ settings: m,
3491
3491
  pageContext: o
3492
3492
  }
3493
3493
  ),
3494
- s ? /* @__PURE__ */ m(ne, { children: [
3495
- /* @__PURE__ */ i(
3494
+ s ? /* @__PURE__ */ h(ue, { children: [
3495
+ /* @__PURE__ */ a(
3496
3496
  "div",
3497
3497
  {
3498
- className: B(T.main, {
3499
- [T.noAnimation]: d
3498
+ className: R(P.main, {
3499
+ [P.noAnimation]: w
3500
3500
  }),
3501
- children: s.order && s.order.map((g) => /* @__PURE__ */ i(
3502
- fe,
3501
+ children: s.order && s.order.map((S) => /* @__PURE__ */ a(
3502
+ Re,
3503
3503
  {
3504
- block: s.data[g],
3505
- render: A
3504
+ block: s.data[S],
3505
+ render: B
3506
3506
  },
3507
- g
3507
+ S
3508
3508
  ))
3509
3509
  }
3510
3510
  ),
3511
- /* @__PURE__ */ i(
3512
- Q,
3511
+ /* @__PURE__ */ a(
3512
+ ae,
3513
3513
  {
3514
- settings: S,
3514
+ settings: m,
3515
3515
  pageContext: o
3516
3516
  }
3517
3517
  )
3518
- ] }) : /* @__PURE__ */ i("div", { className: T.loading, children: /* @__PURE__ */ i(F, {}) }),
3519
- t && /* @__PURE__ */ i("div", { className: T.loader, children: /* @__PURE__ */ i(F, {}) })
3518
+ ] }) : /* @__PURE__ */ a("div", { className: P.loading, children: /* @__PURE__ */ a(v, {}) }),
3519
+ t && /* @__PURE__ */ a("div", { className: P.loader, children: /* @__PURE__ */ a(v, {}) })
3520
3520
  ]
3521
3521
  }
3522
3522
  );
3523
3523
  };
3524
- function Do() {
3525
- const n = ae();
3526
- return /* @__PURE__ */ i(Ge, { pagePath: n.pathname });
3524
+ function Xo() {
3525
+ const n = he();
3526
+ return /* @__PURE__ */ a(Qe, { pagePath: n.pathname });
3527
3527
  }
3528
- const Ro = (n, r) => {
3528
+ const Vo = (n, r) => {
3529
3529
  let e = `:root {
3530
3530
  `;
3531
3531
  if (r && (e += ` --max-width-store: ${r.maxStoreWidth};
3532
3532
  `, r.aspectRatio && (e += ` --aspect-ratio: ${r.aspectRatio.toString().replace(":", "/")};
3533
3533
  `), r.showParticles !== void 0 && (e += ` --showParticles: ${r.showParticles};
3534
- `)), n.colors && Object.entries(n.colors).forEach(([o, l]) => {
3535
- Object.entries(l).forEach(([t, c]) => {
3534
+ `)), n.colors && Object.entries(n.colors).forEach(([o, i]) => {
3535
+ Object.entries(i).forEach(([t, c]) => {
3536
3536
  e += ` --${o}-${t}: ${c};
3537
3537
  `;
3538
3538
  });
3539
- }), n.fonts && Object.entries(n.fonts.desktop).forEach(([o, l]) => {
3540
- typeof l == "object" && Object.entries(l).forEach(([t, c]) => {
3539
+ }), n.fonts && Object.entries(n.fonts.desktop).forEach(([o, i]) => {
3540
+ typeof i == "object" && Object.entries(i).forEach(([t, c]) => {
3541
3541
  c && (e += ` --font-${o}-${t}-family: ${c.font};
3542
3542
  `, e += ` --font-${o}-${t}-size: ${c.size}px;
3543
3543
  `, e += ` --font-${o}-${t}-weight: ${c.weight};
@@ -3548,14 +3548,14 @@ const Ro = (n, r) => {
3548
3548
  }), n.buttons) {
3549
3549
  const { buttons: o } = n;
3550
3550
  if (o.primary && o.secondary && o.tertiary) {
3551
- const l = `${o.primary.boxShadow.left}px ${o.primary.boxShadow.top}px ${o.primary.boxShadow.blur}px ${o.primary.boxShadow.spread}px ${o.primary.boxShadow.color}`, t = `${o.secondary.boxShadow.left}px ${o.secondary.boxShadow.top}px ${o.secondary.boxShadow.blur}px ${o.secondary.boxShadow.spread}px ${o.secondary.boxShadow.color}`, c = `${o.tertiary.boxShadow.left}px ${o.tertiary.boxShadow.top}px ${o.tertiary.boxShadow.blur}px ${o.tertiary.boxShadow.spread}px ${o.tertiary.boxShadow.color}`;
3551
+ const i = `${o.primary.boxShadow.left}px ${o.primary.boxShadow.top}px ${o.primary.boxShadow.blur}px ${o.primary.boxShadow.spread}px ${o.primary.boxShadow.color}`, t = `${o.secondary.boxShadow.left}px ${o.secondary.boxShadow.top}px ${o.secondary.boxShadow.blur}px ${o.secondary.boxShadow.spread}px ${o.secondary.boxShadow.color}`, c = `${o.tertiary.boxShadow.left}px ${o.tertiary.boxShadow.top}px ${o.tertiary.boxShadow.blur}px ${o.tertiary.boxShadow.spread}px ${o.tertiary.boxShadow.color}`;
3552
3552
  e += ` --button-primary-size: ${o.primary.size}px;
3553
3553
  `, e += ` --button-primary-height: ${o.primary.height}px;
3554
3554
  `, e += ` --button-primary-radius: ${o.primary.radius}px;
3555
3555
  `, e += ` --button-primary-alignment: ${o.primary.alignment};
3556
3556
  `, e += ` --button-primary-background: ${o.primary.background};
3557
3557
  `, e += ` --button-primary-hover: ${o.primary.hover};
3558
- `, e += ` --button-primary-box-shadow: ${l};
3558
+ `, e += ` --button-primary-box-shadow: ${i};
3559
3559
  `, e += ` --button-primary-font: ${o.primary.font};
3560
3560
  `, e += ` --button-primary-text-color: ${o.primary.color};
3561
3561
  `, e += ` --button-primary-text-color-hover: ${o.primary.colorHover};
@@ -3650,7 +3650,7 @@ const Ro = (n, r) => {
3650
3650
  `, e += ` --border-md: var(--scale-2);
3651
3651
  `, e += ` --border-lg: var(--scale-4);
3652
3652
  `, e += "}", e;
3653
- }, vo = (n) => {
3653
+ }, jo = (n) => {
3654
3654
  const r = document.getElementById("dynamic-styles");
3655
3655
  if (r)
3656
3656
  r.innerHTML = n;
@@ -3658,56 +3658,56 @@ const Ro = (n, r) => {
3658
3658
  const e = document.createElement("style");
3659
3659
  e.id = "dynamic-styles", e.innerHTML = n, document.head.appendChild(e);
3660
3660
  }
3661
- }, v = /* @__PURE__ */ new Set(), We = (n) => {
3661
+ }, E = /* @__PURE__ */ new Set(), Ze = (n) => {
3662
3662
  const r = /* @__PURE__ */ new Map();
3663
3663
  return Object.entries(n).forEach(([, e]) => {
3664
3664
  typeof e == "object" && Object.entries(e).forEach(([, o]) => {
3665
- var l, t;
3665
+ var i, t;
3666
3666
  if (o && o.font) {
3667
3667
  const c = o.font.replace(/\s+/g, "+");
3668
- r.has(c) || r.set(c, /* @__PURE__ */ new Set()), (l = r.get(c)) == null || l.add(o.weight), (t = r.get(c)) == null || t.add(o.boldWeight);
3668
+ r.has(c) || r.set(c, /* @__PURE__ */ new Set()), (i = r.get(c)) == null || i.add(o.weight), (t = r.get(c)) == null || t.add(o.boldWeight);
3669
3669
  }
3670
3670
  });
3671
3671
  }), r;
3672
- }, $e = (n) => {
3672
+ }, eo = (n) => {
3673
3673
  const r = /* @__PURE__ */ new Map();
3674
3674
  return Object.entries(n).forEach(([, e]) => {
3675
3675
  typeof e == "object" && Object.keys(e).forEach((o) => {
3676
- var l;
3676
+ var i;
3677
3677
  if (o === "font" && e[o]) {
3678
3678
  const t = e[o].replace(/\s+/g, "+");
3679
- r.has(t) || r.set(t, /* @__PURE__ */ new Set()), (l = r.get(t)) == null || l.add("400");
3679
+ r.has(t) || r.set(t, /* @__PURE__ */ new Set()), (i = r.get(t)) == null || i.add("400");
3680
3680
  }
3681
3681
  });
3682
3682
  }), r;
3683
- }, qe = (n) => {
3684
- v.forEach((r) => {
3683
+ }, oo = (n) => {
3684
+ E.forEach((r) => {
3685
3685
  if (!n.has(r)) {
3686
3686
  const e = document.querySelector(`link[data-font="${r}"]`);
3687
- e && e.remove(), v.delete(r);
3687
+ e && e.remove(), E.delete(r);
3688
3688
  }
3689
3689
  });
3690
- }, ze = (n) => {
3690
+ }, no = (n) => {
3691
3691
  const r = /* @__PURE__ */ new Set();
3692
3692
  n.forEach((e, o) => {
3693
- const l = Array.from(e).sort().join(";"), t = `${o}:wght@${l}`;
3694
- if (r.add(t), !v.has(t)) {
3693
+ const i = Array.from(e).sort().join(";"), t = `${o}:wght@${i}`;
3694
+ if (r.add(t), !E.has(t)) {
3695
3695
  const c = document.createElement("link");
3696
- c.rel = "stylesheet", c.href = `https://fonts.googleapis.com/css2?family=${t}&display=swap`, c.setAttribute("data-font", t), document.head.appendChild(c), v.add(t);
3696
+ c.rel = "stylesheet", c.href = `https://fonts.googleapis.com/css2?family=${t}&display=swap`, c.setAttribute("data-font", t), document.head.appendChild(c), E.add(t);
3697
3697
  }
3698
- }), qe(r);
3699
- }, xo = (n) => {
3698
+ }), oo(r);
3699
+ }, Ko = (n) => {
3700
3700
  if (n.fonts) {
3701
- const r = We(n.fonts.desktop), e = $e(n.buttons), o = new Map(r);
3702
- e.forEach((l, t) => {
3701
+ const r = Ze(n.fonts.desktop), e = eo(n.buttons), o = new Map(r);
3702
+ e.forEach((i, t) => {
3703
3703
  if (o.has(t)) {
3704
3704
  const c = o.get(t);
3705
- l.forEach((s) => c == null ? void 0 : c.add(s));
3705
+ i.forEach((s) => c == null ? void 0 : c.add(s));
3706
3706
  } else
3707
- o.set(t, new Set(l));
3708
- }), ze(o);
3707
+ o.set(t, new Set(i));
3708
+ }), no(o);
3709
3709
  }
3710
- }, H = [
3710
+ }, _ = [
3711
3711
  {
3712
3712
  family: "GT Eesti Pro Display",
3713
3713
  files: [
@@ -3750,7 +3750,7 @@ const Ro = (n, r) => {
3750
3750
  { filename: "Ubuntu-Bold.ttf", weight: "700", style: "normal" }
3751
3751
  ]
3752
3752
  }
3753
- ], je = (n) => {
3753
+ ], ro = (n) => {
3754
3754
  var e;
3755
3755
  switch ((e = n.split(".").pop()) == null ? void 0 : e.toLowerCase()) {
3756
3756
  case "woff2":
@@ -3764,32 +3764,32 @@ const Ro = (n, r) => {
3764
3764
  default:
3765
3765
  return "opentype";
3766
3766
  }
3767
- }, Xe = (n, r, e, o) => {
3768
- const l = je(r);
3767
+ }, to = (n, r, e, o) => {
3768
+ const i = ro(r);
3769
3769
  return `
3770
3770
  @font-face {
3771
3771
  font-family: '${n}';
3772
- src: url('./src/assets/fonts/${r}') format('${l}');
3772
+ src: url('./src/assets/fonts/${r}') format('${i}');
3773
3773
  font-weight: ${e};
3774
3774
  font-style: ${o};
3775
3775
  font-display: swap;
3776
3776
  }`;
3777
- }, Mo = () => {
3777
+ }, Jo = () => {
3778
3778
  if (document.getElementById("custom-fonts-styles"))
3779
3779
  return;
3780
3780
  let n = "";
3781
- H.forEach((e) => {
3781
+ _.forEach((e) => {
3782
3782
  e.files.forEach((o) => {
3783
- n += Xe(e.family, o.filename, o.weight, o.style) + `
3783
+ n += to(e.family, o.filename, o.weight, o.style) + `
3784
3784
  `;
3785
3785
  });
3786
3786
  });
3787
3787
  const r = document.createElement("style");
3788
- r.id = "custom-fonts-styles", r.type = "text/css", r.textContent = n, document.head.appendChild(r), console.log("Custom fonts loaded:", H.map((e) => e.family).join(", ")), H.forEach((e) => {
3788
+ r.id = "custom-fonts-styles", r.type = "text/css", r.textContent = n, document.head.appendChild(r), console.log("Custom fonts loaded:", _.map((e) => e.family).join(", ")), _.forEach((e) => {
3789
3789
  console.log(`Font "${e.family}":`, e.files.map((o) => `${o.filename} (${o.weight})`).join(", "));
3790
3790
  });
3791
3791
  };
3792
- function Ho() {
3792
+ function Yo() {
3793
3793
  if (window.location.pathname.includes("/admin/builder"))
3794
3794
  try {
3795
3795
  const {
@@ -3797,27 +3797,27 @@ function Ho() {
3797
3797
  currentBlock: r,
3798
3798
  blocks: e,
3799
3799
  setHeader: o,
3800
- setFooter: l,
3800
+ setFooter: i,
3801
3801
  setAnnouncement: t
3802
- } = ie.getState(), { currentPage: c, pages: s } = O.getState(), { currentInstance: I, settingsInstance: S } = X.getState(), { setSettings: y } = V.getState();
3803
- if (r || y(S.blockSettings), I && r) {
3802
+ } = Se.getState(), { currentPage: c, pages: s } = q.getState(), { currentInstance: u, settingsInstance: m } = oe.getState(), { setSettings: k } = ne.getState();
3803
+ if (r || k(m.blockSettings), u && r) {
3804
3804
  if (r === "header")
3805
- o(I);
3805
+ o(u);
3806
3806
  else if (r === "footer")
3807
- l(I);
3807
+ i(u);
3808
3808
  else if (r === "announcement")
3809
- t(I);
3809
+ t(u);
3810
3810
  else if (r === "header" || r === "footer" || r === "announcement")
3811
3811
  throw new Error(`Missing ${r} data.`);
3812
3812
  }
3813
- if (I && s && r && !["header", "footer", "announcement"].includes(r)) {
3813
+ if (u && s && r && !["header", "footer", "announcement"].includes(r)) {
3814
3814
  const C = {
3815
3815
  blockSettings: {}
3816
3816
  };
3817
- if (!I.blockSettings)
3817
+ if (!u.blockSettings)
3818
3818
  throw new Error("currentInstance.blockSettings is undefined.");
3819
- if (Object.keys(I.blockSettings).filter((d) => !["displayName", "isAddable"].includes(d)).forEach((d) => {
3820
- C.blockSettings[d] = I.blockSettings[d];
3819
+ if (Object.keys(u.blockSettings).filter((w) => !["displayName", "isAddable"].includes(w)).forEach((w) => {
3820
+ C.blockSettings[w] = u.blockSettings[w];
3821
3821
  }), !s[c])
3822
3822
  throw new Error(`Page "${c}" does not exist.`);
3823
3823
  if (!e[s[c].path].data || !e[s[c].path].data[r])
@@ -3833,23 +3833,23 @@ function Ho() {
3833
3833
  console.error("Error in hotReload function:", n);
3834
3834
  }
3835
3835
  }
3836
- function No(n, r = !0) {
3836
+ function Qo(n, r = !0) {
3837
3837
  if (!n || typeof n != "string")
3838
3838
  return "";
3839
3839
  if (/<[a-z][\s\S]*>/i.test(n))
3840
3840
  return n;
3841
- const o = n.split(" "), l = 20;
3841
+ const o = n.split(" "), i = 20;
3842
3842
  if (r) {
3843
3843
  let t = "", c = [];
3844
3844
  return o.forEach((s) => {
3845
- s.length > l ? (c.length > 0 && (t += `<span style="hyphens: manual">${c.join(" ")} </span>`, c = []), t += `<span style="hyphens: auto" lang="en">${s} </span>`) : c.push(s);
3845
+ s.length > i ? (c.length > 0 && (t += `<span style="hyphens: manual">${c.join(" ")} </span>`, c = []), t += `<span style="hyphens: auto" lang="en">${s} </span>`) : c.push(s);
3846
3846
  }), c.length > 0 && (t += `<span style="hyphens: manual">${c.join(" ")}</span>`), t;
3847
3847
  } else {
3848
3848
  const t = [];
3849
3849
  let c = [], s = 0;
3850
- return o.forEach((I) => {
3851
- I.length > l ? (c.length > 0 && (t.push(
3852
- /* @__PURE__ */ m(
3850
+ return o.forEach((u) => {
3851
+ u.length > i ? (c.length > 0 && (t.push(
3852
+ /* @__PURE__ */ h(
3853
3853
  "span",
3854
3854
  {
3855
3855
  style: { hyphens: "manual" },
@@ -3861,21 +3861,21 @@ function No(n, r = !0) {
3861
3861
  s++
3862
3862
  )
3863
3863
  ), c = []), t.push(
3864
- /* @__PURE__ */ m(
3864
+ /* @__PURE__ */ h(
3865
3865
  "span",
3866
3866
  {
3867
3867
  style: { hyphens: "auto" },
3868
3868
  lang: "en",
3869
3869
  children: [
3870
- I,
3870
+ u,
3871
3871
  " "
3872
3872
  ]
3873
3873
  },
3874
3874
  s++
3875
3875
  )
3876
- )) : c.push(I);
3876
+ )) : c.push(u);
3877
3877
  }), c.length > 0 && t.push(
3878
- /* @__PURE__ */ i(
3878
+ /* @__PURE__ */ a(
3879
3879
  "span",
3880
3880
  {
3881
3881
  style: { hyphens: "manual" },
@@ -3886,122 +3886,139 @@ function No(n, r = !0) {
3886
3886
  ), t;
3887
3887
  }
3888
3888
  }
3889
- const Eo = () => {
3890
- const n = q.getState().apiUrls, r = U(), { notifications: e, setNotifications: o } = E(), { isAntistock: l } = x();
3891
- return async (t, c, s, I, S) => {
3892
- const y = z ? localStorage.getItem("fakeDomain") : window.location.hostname, C = `${n.slApi}/v1/public/${y}/tickets`;
3889
+ const Zo = () => {
3890
+ const n = Q.getState().apiUrls, r = $(), { notifications: e, setNotifications: o } = W(), { isAntistock: i } = U();
3891
+ return async (t, c, s, u, m, k) => {
3892
+ const C = Z ? localStorage.getItem("fakeDomain") : window.location.hostname, w = `${n.slApi}/v1/public/${C}/tickets`;
3893
3893
  try {
3894
- const d = await j({
3894
+ const g = await ee({
3895
3895
  method: "post",
3896
- url: C,
3896
+ url: w,
3897
3897
  body: {
3898
3898
  title: t,
3899
3899
  firstMessage: c,
3900
- email: I,
3900
+ email: u,
3901
3901
  recaptcha: s,
3902
- tsId: K(),
3903
- orderId: S
3902
+ tsId: re(),
3903
+ orderId: m,
3904
+ imageIds: k
3904
3905
  },
3905
3906
  withToken: !1
3906
3907
  });
3907
3908
  return o([
3908
3909
  ...e,
3909
3910
  {
3910
- id: N(),
3911
- message: l ? "Support ticket successfully created. You can expect to hear from us soon." : "Ticket created successfully. We will contact you by mail",
3911
+ id: G(),
3912
+ message: i ? "Support ticket successfully created. You can expect to hear from us soon." : "Ticket created successfully. We will contact you by mail",
3912
3913
  status: "success"
3913
3914
  }
3914
- ]), r(`/ticket/${d.data.id}/${d.data.accessToken}`), d;
3915
- } catch (d) {
3915
+ ]), r(`/ticket/${g.data.id}/${g.data.accessToken}`), g;
3916
+ } catch (g) {
3916
3917
  o([
3917
3918
  ...e,
3918
3919
  {
3919
- id: N(),
3920
- message: `Error: ${d}. Please try again later.`,
3920
+ id: G(),
3921
+ message: `Error: ${g}. Please try again later.`,
3921
3922
  status: "error"
3922
3923
  }
3923
3924
  ]);
3924
3925
  }
3925
3926
  };
3926
- }, Uo = () => {
3927
- const { pages: n } = O(), [r, e] = p.useState(n);
3927
+ }, en = () => {
3928
+ const { pages: n } = q(), [r, e] = p.useState(n);
3928
3929
  return p.useEffect(() => {
3929
3930
  e(n);
3930
3931
  }, [n]), r;
3931
3932
  };
3932
- var Z = /* @__PURE__ */ ((n) => (n.NEW = "NEW", n.ANSWERED = "ANSWERED", n.NOT_ANSWERED = "NOT_ANSWERED", n.CLOSED = "CLOSED", n))(Z || {});
3933
- const Ve = "_wrapper_mlj8m_1", Ke = "_ticketContainer_mlj8m_23", Je = "_title_mlj8m_28", Ye = "_subtext_mlj8m_35", Qe = "_container_mlj8m_41", Ze = "_content_mlj8m_52", eo = "_messages_mlj8m_63", oo = "_input_mlj8m_81", no = "_textarea_mlj8m_94", ro = "_textareaAntistock_mlj8m_123", to = "_message_mlj8m_63", co = "_messageDate_mlj8m_153", ao = "_messageAntistock_mlj8m_159", io = "_myMessage_mlj8m_164", lo = "_otherMessage_mlj8m_171", so = "_button_mlj8m_178", Io = "_disabled_mlj8m_178", uo = "_loadingMessage_mlj8m_204", u = {
3934
- wrapper: Ve,
3935
- ticketContainer: Ke,
3936
- title: Je,
3937
- subtext: Ye,
3938
- container: Qe,
3939
- content: Ze,
3940
- messages: eo,
3941
- input: oo,
3942
- textarea: no,
3943
- textareaAntistock: ro,
3944
- message: to,
3945
- messageDate: co,
3946
- messageAntistock: ao,
3947
- myMessage: io,
3948
- otherMessage: lo,
3949
- button: so,
3950
- disabled: Io,
3951
- loadingMessage: uo
3952
- }, po = () => {
3953
- const n = window.location.pathname.split("/"), r = n[n.length - 1], e = n[n.length - 2], [o, l] = p.useState(!0), [t, c] = p.useState(null), [s, I] = p.useState(""), [S, y] = p.useState(null), { executeRecaptcha: C } = Se(), { isAntistock: d } = x(), h = (t == null ? void 0 : t.status) === Z.CLOSED, A = async () => {
3933
+ var ie = /* @__PURE__ */ ((n) => (n.NEW = "NEW", n.ANSWERED = "ANSWERED", n.NOT_ANSWERED = "NOT_ANSWERED", n.CLOSED = "CLOSED", n))(ie || {});
3934
+ const co = "_wrapper_ukunw_1", ao = "_ticketContainer_ukunw_23", io = "_title_ukunw_28", lo = "_subtext_ukunw_35", so = "_container_ukunw_41", Io = "_content_ukunw_52", uo = "_messages_ukunw_63", po = "_input_ukunw_81", go = "_textarea_ukunw_94", ho = "_textareaAntistock_ukunw_123", So = "_message_ukunw_63", mo = "_messageDate_ukunw_153", Co = "_messageAntistock_ukunw_159", wo = "_myMessage_ukunw_164", fo = "_otherMessage_ukunw_171", yo = "_button_ukunw_178", bo = "_disabled_ukunw_178", ko = "_loadingMessage_ukunw_204", Lo = "_messageImages_ukunw_208", To = "_messageImage_ukunw_208", Ao = "_imagesLoader_ukunw_236", Po = "_imageModal_ukunw_240", Bo = "_imageModalClose_ukunw_268", d = {
3935
+ wrapper: co,
3936
+ ticketContainer: ao,
3937
+ title: io,
3938
+ subtext: lo,
3939
+ container: so,
3940
+ content: Io,
3941
+ messages: uo,
3942
+ input: po,
3943
+ textarea: go,
3944
+ textareaAntistock: ho,
3945
+ message: So,
3946
+ messageDate: mo,
3947
+ messageAntistock: Co,
3948
+ myMessage: wo,
3949
+ otherMessage: fo,
3950
+ button: yo,
3951
+ disabled: bo,
3952
+ loadingMessage: ko,
3953
+ messageImages: Lo,
3954
+ messageImage: To,
3955
+ imagesLoader: Ao,
3956
+ imageModal: Po,
3957
+ imageModalClose: Bo
3958
+ }, Fo = () => {
3959
+ const n = window.location.pathname.split("/"), r = n[n.length - 1], e = n[n.length - 2], [o, i] = p.useState(!0), [t, c] = p.useState(null), [s, u] = p.useState(""), [m, k] = p.useState(null), [C, w] = p.useState(null), [g, B] = p.useState(null), S = p.useRef(null), { executeRecaptcha: L } = Ae(), { isAntistock: l } = U(), M = re(), { setIsOpen: F } = me(), y = (t == null ? void 0 : t.status) === ie.CLOSED, z = p.useCallback(() => {
3960
+ var I;
3961
+ (I = S.current) == null || I.scrollIntoView({ behavior: "smooth" });
3962
+ }, []), x = p.useCallback(async () => {
3954
3963
  if (e && r) {
3955
- const { data: a } = await me(e, r);
3956
- c(a), l(!1);
3964
+ const { data: I } = await Pe(e, r);
3965
+ c(I), i(!1);
3957
3966
  }
3958
- };
3967
+ }, [e, r]);
3959
3968
  p.useEffect(() => {
3960
- A();
3961
- const a = setInterval(() => {
3962
- A();
3969
+ x();
3970
+ const I = setInterval(() => {
3971
+ x();
3963
3972
  }, 5e3);
3964
- return () => clearInterval(a);
3965
- }, []);
3966
- const g = async () => {
3967
- const a = await C();
3968
- if (!e || !r || !a || !s.trim()) return;
3969
- const L = {
3973
+ return () => clearInterval(I);
3974
+ }, [x]);
3975
+ const X = async () => {
3976
+ const I = await L();
3977
+ if (!e || !r || !I || !s.trim()) return;
3978
+ const b = (m == null ? void 0 : m.map((f) => ({
3979
+ imageId: parseInt(f.id),
3980
+ path: f.url
3981
+ }))) || [], A = {
3970
3982
  content: s,
3971
3983
  createdAt: (/* @__PURE__ */ new Date()).toISOString(),
3972
3984
  id: Date.now(),
3973
3985
  // Уникальный временный ID
3974
- isSellerReply: !1
3986
+ isSellerReply: !1,
3987
+ images: b
3975
3988
  };
3976
3989
  c(
3977
3990
  (f) => f ? {
3978
3991
  ...f,
3979
- messages: [...f.messages, L]
3992
+ messages: [...f.messages, A]
3980
3993
  } : null
3981
- ), y(L.id), I("");
3994
+ ), w(A.id), u(""), k(null), setTimeout(() => {
3995
+ z();
3996
+ }, 100);
3982
3997
  try {
3983
- await Ce(e, r, s, a, K()), await A();
3998
+ await Be(e, r, s, I, M, b), await x(), setTimeout(() => {
3999
+ z();
4000
+ }, 100);
3984
4001
  } finally {
3985
4002
  setTimeout(() => {
3986
- y(null);
4003
+ w(null);
3987
4004
  }, 1e4);
3988
4005
  }
3989
- }, b = (a) => {
3990
- const L = /* @__PURE__ */ new Date(), f = new Date(a), w = Math.floor((L.getTime() - f.getTime()) / 1e3);
3991
- if (w < 60)
4006
+ }, le = (I) => {
4007
+ const b = /* @__PURE__ */ new Date(), A = new Date(I), f = Math.floor((b.getTime() - A.getTime()) / 1e3);
4008
+ if (f < 60)
3992
4009
  return "just now";
3993
- if (w < 3600) {
3994
- const P = Math.floor(w / 60);
3995
- return `${P} minute${P > 1 ? "s" : ""} ago`;
3996
- } else if (w < 10800) {
3997
- const P = Math.floor(w / 3600);
3998
- return `${P} hour${P > 1 ? "s" : ""} ago`;
3999
- } else return f.getFullYear() === L.getFullYear() ? f.toLocaleDateString("en-US", {
4010
+ if (f < 3600) {
4011
+ const D = Math.floor(f / 60);
4012
+ return `${D} minute${D > 1 ? "s" : ""} ago`;
4013
+ } else if (f < 10800) {
4014
+ const D = Math.floor(f / 3600);
4015
+ return `${D} hour${D > 1 ? "s" : ""} ago`;
4016
+ } else return A.getFullYear() === b.getFullYear() ? A.toLocaleDateString("en-US", {
4000
4017
  month: "short",
4001
4018
  day: "2-digit",
4002
4019
  hour: "2-digit",
4003
4020
  minute: "2-digit"
4004
- }) : f.toLocaleDateString("en-US", {
4021
+ }) : A.toLocaleDateString("en-US", {
4005
4022
  year: "numeric",
4006
4023
  month: "short",
4007
4024
  day: "2-digit",
@@ -4009,105 +4026,167 @@ const Ve = "_wrapper_mlj8m_1", Ke = "_ticketContainer_mlj8m_23", Je = "_title_ml
4009
4026
  minute: "2-digit"
4010
4027
  });
4011
4028
  };
4012
- return /* @__PURE__ */ i("div", { className: u.wrapper, children: o && !t ? /* @__PURE__ */ i(F, {}) : /* @__PURE__ */ m("div", { className: u.container, children: [
4013
- d ? /* @__PURE__ */ m("div", { className: u.ticketContainer, children: [
4014
- /* @__PURE__ */ i(
4015
- "div",
4016
- {
4017
- className: u.title,
4018
- style: { fontSize: "var(--font-heading-h3-size)" },
4019
- children: t == null ? void 0 : t.title
4020
- }
4021
- ),
4022
- /* @__PURE__ */ i(
4029
+ return /* @__PURE__ */ h("div", { className: d.wrapper, children: [
4030
+ o && !t ? /* @__PURE__ */ a(v, {}) : /* @__PURE__ */ h("div", { className: d.container, children: [
4031
+ l ? /* @__PURE__ */ h("div", { className: d.ticketContainer, children: [
4032
+ /* @__PURE__ */ a(
4033
+ "div",
4034
+ {
4035
+ className: d.title,
4036
+ style: { fontSize: "var(--font-heading-h3-size)" },
4037
+ children: t == null ? void 0 : t.title
4038
+ }
4039
+ ),
4040
+ /* @__PURE__ */ a(
4041
+ "div",
4042
+ {
4043
+ className: d.subtext,
4044
+ style: { fontSize: "var(--font-body-md-size)" },
4045
+ children: "We’re going to respond to your ticket shortly. You’ll receive updates in your email inbox. Feel free to close this page."
4046
+ }
4047
+ )
4048
+ ] }) : /* @__PURE__ */ a("div", { className: d.title, children: `#${e} (${t == null ? void 0 : t.title})` }),
4049
+ /* @__PURE__ */ h(
4023
4050
  "div",
4024
4051
  {
4025
- className: u.subtext,
4026
- style: { fontSize: "var(--font-body-md-size)" },
4027
- children: "We’re going to respond to your ticket shortly. You’ll receive updates in your email inbox. Feel free to close this page."
4052
+ className: d.content,
4053
+ style: {
4054
+ position: l ? "relative" : void 0,
4055
+ border: l ? "1px solid var(--border-secondary)" : void 0
4056
+ },
4057
+ children: [
4058
+ /* @__PURE__ */ h("div", { className: d.messages, children: [
4059
+ t == null ? void 0 : t.messages.sort((I, b) => new Date(I.createdAt).getTime() - new Date(b.createdAt).getTime()).map((I) => /* @__PURE__ */ h(
4060
+ "div",
4061
+ {
4062
+ className: R(d.message, {
4063
+ [d.messageAntistock]: l,
4064
+ [d.myMessage]: !I.isSellerReply,
4065
+ [d.otherMessage]: I.isSellerReply,
4066
+ [d.loadingMessage]: C === I.id
4067
+ // Добавляем класс загрузки
4068
+ }),
4069
+ children: [
4070
+ /* @__PURE__ */ a("div", { className: d.messageContent, children: I.content }),
4071
+ I.images && I.images.length > 0 && /* @__PURE__ */ a("div", { className: d.messageImages, children: I.images.map((b) => /* @__PURE__ */ a(
4072
+ "div",
4073
+ {
4074
+ className: d.messageImage,
4075
+ onClick: () => {
4076
+ B(b.path), F(!0);
4077
+ },
4078
+ children: /* @__PURE__ */ a(
4079
+ "img",
4080
+ {
4081
+ src: b.path,
4082
+ alt: "Attachment"
4083
+ }
4084
+ )
4085
+ },
4086
+ b.imageId
4087
+ )) }),
4088
+ C !== I.id && /* @__PURE__ */ a("div", { className: d.messageDate, children: le(I.createdAt) }),
4089
+ C === I.id && /* @__PURE__ */ a("div", { className: d.messageDate, children: /* @__PURE__ */ a(v, {}) })
4090
+ ]
4091
+ },
4092
+ I.id
4093
+ )),
4094
+ /* @__PURE__ */ a("div", { ref: S })
4095
+ ] }),
4096
+ /* @__PURE__ */ h("div", { className: d.input, children: [
4097
+ !y && /* @__PURE__ */ a(
4098
+ Fe,
4099
+ {
4100
+ images: m,
4101
+ onChange: (I) => k(I),
4102
+ multiple: !0,
4103
+ enablePaste: !0,
4104
+ uploadText: "Add images",
4105
+ uploadSubtext: "Click or drag images here",
4106
+ className: d.imagesLoader
4107
+ }
4108
+ ),
4109
+ /* @__PURE__ */ h("div", { style: { position: "relative" }, children: [
4110
+ /* @__PURE__ */ a(
4111
+ "textarea",
4112
+ {
4113
+ disabled: y,
4114
+ className: R(d.textarea, {
4115
+ [d.textareaAntistock]: l
4116
+ }),
4117
+ value: s,
4118
+ placeholder: y ? "The ticket has been closed. Need further assistance? Please submit a new request." : l ? "Type a message..." : "What worries you?",
4119
+ onChange: (I) => u(I.target.value),
4120
+ onKeyDown: (I) => {
4121
+ I.key === "Enter" && !I.shiftKey && (I.preventDefault(), X());
4122
+ }
4123
+ }
4124
+ ),
4125
+ /* @__PURE__ */ a(
4126
+ "div",
4127
+ {
4128
+ onClick: X,
4129
+ className: R(d.button, {
4130
+ [d.disabled]: y
4131
+ }),
4132
+ children: /* @__PURE__ */ a(K, { name: "PaperPlaneRight" })
4133
+ }
4134
+ )
4135
+ ] })
4136
+ ] })
4137
+ ]
4028
4138
  }
4029
4139
  )
4030
- ] }) : /* @__PURE__ */ i("div", { className: u.title, children: `#${e} (${t == null ? void 0 : t.title})` }),
4031
- /* @__PURE__ */ m(
4140
+ ] }),
4141
+ g && /* @__PURE__ */ a(De, { close: () => B(null), children: /* @__PURE__ */ h(
4032
4142
  "div",
4033
4143
  {
4034
- className: u.content,
4035
- style: {
4036
- position: d ? "relative" : void 0,
4037
- border: d ? "1px solid var(--border-secondary)" : void 0
4038
- },
4144
+ className: d.imageModal,
4145
+ onClick: (I) => I.stopPropagation(),
4039
4146
  children: [
4040
- /* @__PURE__ */ i("div", { className: u.messages, children: t == null ? void 0 : t.messages.sort((a, L) => new Date(a.createdAt).getTime() - new Date(L.createdAt).getTime()).map((a) => /* @__PURE__ */ m(
4147
+ /* @__PURE__ */ a(
4041
4148
  "div",
4042
4149
  {
4043
- className: B(u.message, {
4044
- [u.messageAntistock]: d,
4045
- [u.myMessage]: !a.isSellerReply,
4046
- [u.otherMessage]: a.isSellerReply,
4047
- [u.loadingMessage]: S === a.id
4048
- // Добавляем класс загрузки
4049
- }),
4050
- children: [
4051
- /* @__PURE__ */ i("div", { className: u.messageContent, children: a.content }),
4052
- S !== a.id && /* @__PURE__ */ i("div", { className: u.messageDate, children: b(a.createdAt) }),
4053
- S === a.id && /* @__PURE__ */ i("div", { className: u.messageDate, children: /* @__PURE__ */ i(F, {}) })
4054
- ]
4055
- },
4056
- a.id
4057
- )) }),
4058
- /* @__PURE__ */ m("div", { className: u.input, children: [
4059
- /* @__PURE__ */ i(
4060
- "textarea",
4061
- {
4062
- disabled: h,
4063
- className: B(u.textarea, {
4064
- [u.textareaAntistock]: d
4065
- }),
4066
- value: s,
4067
- placeholder: h ? "The ticket has been closed. Need further assistance? Please submit a new request." : d ? "Type a message..." : "What worries you?",
4068
- onChange: (a) => I(a.target.value),
4069
- onKeyDown: (a) => {
4070
- a.key === "Enter" && !a.shiftKey && (a.preventDefault(), g());
4071
- }
4072
- }
4073
- ),
4074
- /* @__PURE__ */ i(
4075
- "div",
4076
- {
4077
- onClick: g,
4078
- className: B(u.button, {
4079
- [u.disabled]: h
4080
- }),
4081
- children: /* @__PURE__ */ i(we, { name: "PaperPlaneRight" })
4082
- }
4083
- )
4084
- ] })
4150
+ className: d.imageModalClose,
4151
+ onClick: () => {
4152
+ B(null), F(!1);
4153
+ },
4154
+ children: /* @__PURE__ */ a(K, { name: "X" })
4155
+ }
4156
+ ),
4157
+ /* @__PURE__ */ a(
4158
+ "img",
4159
+ {
4160
+ src: g,
4161
+ alt: "Full size"
4162
+ }
4163
+ )
4085
4164
  ]
4086
4165
  }
4087
- )
4088
- ] }) });
4089
- }, Oo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4166
+ ) })
4167
+ ] });
4168
+ }, on = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4090
4169
  __proto__: null,
4091
- TicketItem: po
4170
+ TicketItem: Fo
4092
4171
  }, Symbol.toStringTag, { value: "Module" }));
4093
4172
  export {
4094
- Fe as C,
4095
- Do as D,
4096
- Fo as T,
4097
- Eo as a,
4098
- Uo as b,
4099
- ko as c,
4100
- Ao as d,
4101
- Bo as e,
4102
- Ro as f,
4103
- Be as g,
4104
- Ho as h,
4105
- Lo as i,
4106
- xo as j,
4107
- vo as k,
4108
- Mo as l,
4109
- Oo as m,
4110
- To as r,
4111
- No as s,
4112
- Po as u
4173
+ _e as C,
4174
+ Xo as D,
4175
+ zo as T,
4176
+ Zo as a,
4177
+ en as b,
4178
+ _o as c,
4179
+ Wo as d,
4180
+ qo as e,
4181
+ Vo as f,
4182
+ Oe as g,
4183
+ Yo as h,
4184
+ Oo as i,
4185
+ Ko as j,
4186
+ jo as k,
4187
+ Jo as l,
4188
+ on as m,
4189
+ Go as r,
4190
+ Qo as s,
4191
+ $o as u
4113
4192
  };