@teamnovu/kit-shopware-composables 0.0.22 → 0.0.23

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/index.mjs CHANGED
@@ -1,6 +1,6 @@
1
- import { inject as Y, unref as o, computed as c, reactive as Z, watch as H, toRef as W } from "vue";
1
+ import { inject as Y, unref as i, computed as c, reactive as Z, watch as H, toRef as W } from "vue";
2
2
  import { until as J } from "@vueuse/core";
3
- import { queryOptions as P, useQuery as Q, useQueryClient as C, useMutation as v } from "@tanstack/vue-query";
3
+ import { queryOptions as C, useQuery as P, useQueryClient as S, useMutation as h } from "@tanstack/vue-query";
4
4
  import "@teamnovu/kit-shopware-api-client";
5
5
  const _ = Symbol("shopwareClient");
6
6
  function g() {
@@ -13,29 +13,29 @@ const F = {
13
13
  all: () => ["context"]
14
14
  }, ee = {
15
15
  all: () => ["language"]
16
- }, B = {
16
+ }, k = {
17
17
  all: () => ["category"],
18
- lists: () => [...B.all(), "list"],
18
+ lists: () => [...k.all(), "list"],
19
19
  list: (e) => [
20
- ...B.all(),
20
+ ...k.all(),
21
21
  "list",
22
22
  {
23
23
  body: e
24
24
  }
25
25
  ]
26
- }, b = {
26
+ }, D = {
27
27
  all: () => ["navigation"],
28
- lists: () => [...b.all(), "list"],
28
+ lists: () => [...D.all(), "list"],
29
29
  list: (e) => [
30
- ...b.all(),
30
+ ...D.all(),
31
31
  "list",
32
32
  {
33
33
  body: e
34
34
  }
35
35
  ],
36
- details: () => [...b.all(), "detail"],
36
+ details: () => [...D.all(), "detail"],
37
37
  detail: (e, s, t) => [
38
- ...b.all(),
38
+ ...D.all(),
39
39
  "detail",
40
40
  {
41
41
  activeId: e,
@@ -43,34 +43,40 @@ const F = {
43
43
  body: t
44
44
  }
45
45
  ]
46
- }, w = {
46
+ }, A = {
47
47
  all: () => ["product"],
48
- lists: () => [...w.all(), "list"],
48
+ lists: () => [...A.all(), "list"],
49
49
  list: (e, s) => [
50
- ...w.all(),
50
+ ...A.all(),
51
51
  "list",
52
52
  {
53
53
  url: e,
54
54
  body: s
55
55
  }
56
56
  ],
57
- details: () => [...w.all(), "detail"],
57
+ details: () => [...A.all(), "detail"],
58
58
  customDetail: (e, s) => [
59
- ...w.details(),
59
+ ...A.details(),
60
60
  "custom",
61
61
  {
62
62
  url: e,
63
63
  body: s
64
64
  }
65
65
  ],
66
+ headlessDetail: (e) => [
67
+ ...A.details(),
68
+ {
69
+ body: e
70
+ }
71
+ ],
66
72
  detail: (e) => [
67
- ...w.details(),
73
+ ...A.details(),
68
74
  {
69
75
  body: e
70
76
  }
71
77
  ],
72
78
  search: (e) => [
73
- ...w.all(),
79
+ ...A.all(),
74
80
  "search",
75
81
  {
76
82
  body: e
@@ -94,11 +100,11 @@ const F = {
94
100
  ],
95
101
  details: () => [...R.all(), "detail"],
96
102
  detail: (e, s) => [...R.details(), e, ...s ? [{ body: s }] : []]
97
- }, D = {
103
+ }, B = {
98
104
  all: () => ["shippingMethod"],
99
- lists: () => [...D.all(), "list"],
105
+ lists: () => [...B.all(), "list"],
100
106
  list: (e) => [
101
- ...D.all(),
107
+ ...B.all(),
102
108
  "list",
103
109
  {
104
110
  body: e
@@ -157,10 +163,10 @@ const F = {
157
163
  ]
158
164
  };
159
165
  function p(e) {
160
- const s = o(e);
166
+ const s = i(e);
161
167
  return Object.fromEntries(
162
168
  Object.entries(s ?? {}).map(
163
- ([t, n]) => [t, o(n)]
169
+ ([t, n]) => [t, i(n)]
164
170
  )
165
171
  );
166
172
  }
@@ -170,7 +176,7 @@ function ne(e) {
170
176
  var n;
171
177
  return (n = p(e)) == null ? void 0 : n.body;
172
178
  }));
173
- return P({
179
+ return C({
174
180
  queryKey: t,
175
181
  queryFn: ({ signal: n }) => s.query(te, {
176
182
  ...p(e),
@@ -179,33 +185,33 @@ function ne(e) {
179
185
  });
180
186
  }
181
187
  function se(e) {
182
- return Q(ne(e));
188
+ return P(ne(e));
183
189
  }
184
190
  const V = (e) => {
185
191
  const s = e.replace(/\/?$/, "");
186
192
  return s.startsWith("/") ? s.slice(1) : s;
187
- }, ft = (e) => `/${V(e)}`;
188
- function vt(e, s, t) {
189
- const n = C();
193
+ }, vt = (e) => `/${V(e)}`;
194
+ function qt(e, s, t) {
195
+ const n = S();
190
196
  return {
191
197
  onMutate: async (r) => {
192
198
  await n.cancelQueries({ queryKey: e });
193
199
  const a = n.getQueryData(e);
194
200
  if (n.setQueryData(e, (u) => s(r, u)), t) {
195
- const u = o(t), i = o(u.onMutate);
196
- i == null || i(r);
201
+ const u = i(t), o = i(u.onMutate);
202
+ o == null || o(r);
197
203
  }
198
204
  return { previousValue: a };
199
205
  },
200
206
  onError: (r, a, u) => {
201
207
  if (u && n.setQueryData(e, u.previousValue), t) {
202
- const i = o(t), f = o(i.onError);
208
+ const o = i(t), f = i(o.onError);
203
209
  f == null || f(r, a, u);
204
210
  }
205
211
  },
206
212
  onSettled: (...r) => {
207
213
  if (n.invalidateQueries({ queryKey: e }), t) {
208
- const a = o(t), u = o(a.onSettled);
214
+ const a = i(t), u = i(a.onSettled);
209
215
  u == null || u(...r);
210
216
  }
211
217
  }
@@ -214,7 +220,7 @@ function vt(e, s, t) {
214
220
  const re = "readContext get /context";
215
221
  function ae(e) {
216
222
  const s = g();
217
- return P({
223
+ return C({
218
224
  queryKey: F.all(),
219
225
  queryFn: ({ signal: t }) => s.query(re, {
220
226
  ...p(e),
@@ -222,28 +228,28 @@ function ae(e) {
222
228
  })
223
229
  });
224
230
  }
225
- function k(e) {
226
- return Q(ae(e));
231
+ function b(e) {
232
+ return P(ae(e));
227
233
  }
228
234
  const ue = "updateContext patch /context";
229
235
  function $(e) {
230
- const s = g(), t = C();
231
- return v({
236
+ const s = g(), t = S();
237
+ return h({
232
238
  ...e,
233
239
  mutationFn: async (n) => (t.cancelQueries({ queryKey: F.all() }), s.query(ue, {
234
240
  body: n
235
241
  })),
236
242
  onSuccess: async (n, r, a) => {
237
- var u, i;
243
+ var u, o;
238
244
  await Promise.all([
239
245
  t.invalidateQueries({ queryKey: F.all() }),
240
246
  t.invalidateQueries({ queryKey: L.get() })
241
- ]), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
247
+ ]), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
242
248
  }
243
249
  });
244
250
  }
245
- function ht() {
246
- const e = $(), s = k(), t = se(), n = c(() => s.isFetching.value || e.isPending.value), r = async (d) => {
251
+ function Ct() {
252
+ const e = $(), s = b(), t = se(), n = c(() => s.isFetching.value || e.isPending.value), r = async (d) => {
247
253
  await e.mutateAsync({
248
254
  billingAddressId: d.id
249
255
  }), await J(n).toBe(!1);
@@ -254,7 +260,7 @@ function ht() {
254
260
  }, u = c(() => {
255
261
  var d, M;
256
262
  return (M = (d = s.data.value) == null ? void 0 : d.customer) == null ? void 0 : M.activeBillingAddress;
257
- }), i = c(() => {
263
+ }), o = c(() => {
258
264
  var d, M;
259
265
  return (M = (d = s.data.value) == null ? void 0 : d.customer) == null ? void 0 : M.activeShippingAddress;
260
266
  }), f = c(() => {
@@ -265,12 +271,12 @@ function ht() {
265
271
  return M.id !== ((O = u.value) == null ? void 0 : O.id);
266
272
  }
267
273
  )) ?? [];
268
- }), S = c(() => {
274
+ }), Q = c(() => {
269
275
  var d;
270
276
  return ((d = t.data.value) == null ? void 0 : d.elements.filter(
271
277
  (M) => {
272
278
  var O;
273
- return M.id !== ((O = i.value) == null ? void 0 : O.id);
279
+ return M.id !== ((O = o.value) == null ? void 0 : O.id);
274
280
  }
275
281
  )) ?? [];
276
282
  });
@@ -282,19 +288,19 @@ function ht() {
282
288
  setShippingAddress: a,
283
289
  isSaving: n,
284
290
  activeBillingAddress: u,
285
- activeShippingAddress: i,
291
+ activeShippingAddress: o,
286
292
  inactiveBillingAddresses: f,
287
- inactiveShippingAddresses: S
293
+ inactiveShippingAddresses: Q
288
294
  };
289
295
  }
290
- const ie = "readOrder post /order";
291
- function oe(e) {
296
+ const oe = "readOrder post /order";
297
+ function ie(e) {
292
298
  const s = g(), t = U.detail(e);
293
- return P({
299
+ return C({
294
300
  queryKey: t,
295
301
  queryFn: async ({ signal: n }) => {
296
302
  const r = p(e);
297
- return s.query(ie, {
303
+ return s.query(oe, {
298
304
  ...r,
299
305
  signal: n
300
306
  });
@@ -302,11 +308,11 @@ function oe(e) {
302
308
  });
303
309
  }
304
310
  function ce(e) {
305
- return Q(oe(e));
311
+ return P(ie(e));
306
312
  }
307
- function qt(e, s) {
313
+ function Pt(e, s) {
308
314
  const t = c(() => {
309
- const l = o(e);
315
+ const l = i(e);
310
316
  if (l)
311
317
  return {
312
318
  body: {
@@ -330,13 +336,13 @@ function qt(e, s) {
330
336
  }), u = c(() => {
331
337
  var l, m, q;
332
338
  return (q = (m = (l = r.value) == null ? void 0 : l.stateMachineState) == null ? void 0 : m.translated) == null ? void 0 : q.name;
333
- }), i = c(() => {
339
+ }), o = c(() => {
334
340
  var l, m;
335
341
  return (m = (l = r.value) == null ? void 0 : l.stateMachineState) == null ? void 0 : m.technicalName;
336
342
  }), f = c(() => {
337
343
  var l, m;
338
344
  return (m = (l = r.value) == null ? void 0 : l.price) == null ? void 0 : m.totalPrice;
339
- }), S = c(() => {
345
+ }), Q = c(() => {
340
346
  var l, m;
341
347
  return (m = (l = r.value) == null ? void 0 : l.price) == null ? void 0 : m.positionPrice;
342
348
  }), d = c(() => {
@@ -362,7 +368,7 @@ function qt(e, s) {
362
368
  var l, m, q;
363
369
  return (q = (m = (l = r.value) == null ? void 0 : l.deliveries) == null ? void 0 : m[0]) == null ? void 0 : q.shippingOrderAddress;
364
370
  }
365
- ), h = c(() => {
371
+ ), v = c(() => {
366
372
  var m, q;
367
373
  const l = (m = r.value) == null ? void 0 : m.transactions;
368
374
  if (l != null && l.length)
@@ -372,33 +378,33 @@ function qt(e, s) {
372
378
  const l = (m = r.value) == null ? void 0 : m.deliveries;
373
379
  if (l != null && l.length)
374
380
  return (q = l.at(-1)) == null ? void 0 : q.shippingMethod;
375
- }), A = c(() => {
381
+ }), w = c(() => {
376
382
  var m;
377
- const l = o(e);
383
+ const l = i(e);
378
384
  return ((m = a.value) == null ? void 0 : m[l]) ?? !1;
379
385
  });
380
386
  return {
381
387
  order: r,
382
388
  status: u,
383
- statusTechnicalName: i,
389
+ statusTechnicalName: o,
384
390
  total: f,
385
- subtotal: S,
391
+ subtotal: Q,
386
392
  shippingCosts: d,
387
393
  shippingAddress: y,
388
394
  billingAddress: O,
389
395
  personalDetails: M,
390
396
  shippingMethod: K,
391
- paymentMethod: h,
392
- paymentChangeable: A,
397
+ paymentMethod: v,
398
+ paymentChangeable: w,
393
399
  orderQuery: n
394
400
  };
395
401
  }
396
- function Ct(e) {
402
+ function St(e) {
397
403
  const s = c(() => {
398
404
  var r, a;
399
- return (a = (r = o(e)) == null ? void 0 : r.transactions) == null ? void 0 : a.find((u) => {
400
- var i;
401
- return ((i = u.paymentMethod) == null ? void 0 : i.active) === !0;
405
+ return (a = (r = i(e)) == null ? void 0 : r.transactions) == null ? void 0 : a.find((u) => {
406
+ var o;
407
+ return ((o = u.paymentMethod) == null ? void 0 : o.active) === !0;
402
408
  });
403
409
  }), t = c(() => {
404
410
  var r;
@@ -414,66 +420,66 @@ function Ct(e) {
414
420
  };
415
421
  }
416
422
  const le = "createCustomerAddress post /account/address";
417
- function St(e) {
418
- const s = g(), t = C();
419
- return v({
423
+ function Qt(e) {
424
+ const s = g(), t = S();
425
+ return h({
420
426
  ...e,
421
427
  mutationFn: async (n) => s.query(le, p(n)),
422
428
  onSuccess: async (n, r, a) => {
423
- var u, i;
424
- await t.invalidateQueries({ queryKey: R.lists() }), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
429
+ var u, o;
430
+ await t.invalidateQueries({ queryKey: R.lists() }), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
425
431
  }
426
432
  });
427
433
  }
428
434
  const de = "deleteCustomerAddress delete /account/address/{addressId}";
429
- function Pt(e) {
430
- const s = g(), t = C();
431
- return v({
435
+ function Mt(e) {
436
+ const s = g(), t = S();
437
+ return h({
432
438
  ...e,
433
439
  mutationFn: async (n) => s.query(de, p(n)),
434
440
  onSuccess: async (n, r, a) => {
435
- var u, i;
436
- await t.invalidateQueries({ queryKey: R.lists() }), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
441
+ var u, o;
442
+ await t.invalidateQueries({ queryKey: R.lists() }), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
437
443
  }
438
444
  });
439
445
  }
440
446
  const ye = "updateCustomerAddress patch /account/address/{addressId}";
441
- function Qt(e) {
442
- const s = g(), t = C();
443
- return v({
447
+ function Ot(e) {
448
+ const s = g(), t = S();
449
+ return h({
444
450
  ...e,
445
451
  mutationFn: async (n) => s.query(ye, p(n)),
446
452
  onSuccess: async (n, r, a) => {
447
- var i, f;
453
+ var o, f;
448
454
  const { addressId: u } = p(r).params;
449
455
  t.setQueryData(R.detail(u), n), await Promise.all([
450
456
  t.invalidateQueries({ queryKey: R.lists() }),
451
457
  t.invalidateQueries({
452
458
  queryKey: R.detail(p(r).params.addressId),
453
- predicate: (S) => S.queryKey.at(-1) !== u
459
+ predicate: (Q) => Q.queryKey.at(-1) !== u
454
460
  })
455
- ]), await ((f = o((i = o(e)) == null ? void 0 : i.onSuccess)) == null ? void 0 : f(n, r, a));
461
+ ]), await ((f = i((o = i(e)) == null ? void 0 : o.onSuccess)) == null ? void 0 : f(n, r, a));
456
462
  }
457
463
  });
458
464
  }
459
465
  const pe = "addLineItem post /checkout/cart/line-item";
460
- function Mt(e) {
461
- const s = g(), t = C();
462
- return v({
466
+ function Kt(e) {
467
+ const s = g(), t = S();
468
+ return h({
463
469
  ...e,
464
470
  mutationFn: async (n) => s.query(pe, {
465
471
  body: n
466
472
  }),
467
473
  onSuccess: async (n, r, a) => {
468
- var u, i;
469
- t.setQueryData(L.get(), n), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
474
+ var u, o;
475
+ t.setQueryData(L.get(), n), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
470
476
  }
471
477
  });
472
478
  }
473
479
  const ge = "readCart get /checkout/cart";
474
480
  function me(e) {
475
481
  const s = g(), t = L.get();
476
- return P({
482
+ return C({
477
483
  queryKey: t,
478
484
  queryFn: async ({ signal: n }) => s.query(ge, {
479
485
  ...p(e),
@@ -481,58 +487,58 @@ function me(e) {
481
487
  })
482
488
  });
483
489
  }
484
- function Ot() {
485
- return Q(me());
490
+ function At() {
491
+ return P(me());
486
492
  }
487
493
  const fe = "removeLineItem post /checkout/cart/line-item/delete";
488
- function Kt(e) {
489
- const s = g(), t = C();
490
- return v({
494
+ function wt(e) {
495
+ const s = g(), t = S();
496
+ return h({
491
497
  ...e,
492
498
  mutationFn: async (n) => s.query(fe, {
493
499
  body: n
494
500
  }),
495
501
  onSuccess: async (n, r, a) => {
496
- var u, i;
497
- t.setQueryData(L.get(), n), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
502
+ var u, o;
503
+ t.setQueryData(L.get(), n), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
498
504
  }
499
505
  });
500
506
  }
501
- const ve = "updateLineItem patch /checkout/cart/line-item";
502
- function At(e) {
503
- const s = g(), t = C();
504
- return v({
507
+ const he = "updateLineItem patch /checkout/cart/line-item";
508
+ function Rt(e) {
509
+ const s = g(), t = S();
510
+ return h({
505
511
  ...e,
506
- mutationFn: async (n) => s.query(ve, {
512
+ mutationFn: async (n) => s.query(he, {
507
513
  body: n
508
514
  }),
509
515
  onSuccess: async (n, r, a) => {
510
- var u, i;
511
- t.setQueryData(L.get(), n), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
516
+ var u, o;
517
+ t.setQueryData(L.get(), n), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
512
518
  }
513
519
  });
514
520
  }
515
- const he = "createOrder post /checkout/order";
516
- function wt(e) {
517
- const s = g(), t = C();
518
- return v({
521
+ const ve = "createOrder post /checkout/order";
522
+ function Ft(e) {
523
+ const s = g(), t = S();
524
+ return h({
519
525
  ...e,
520
- mutationFn: async (n) => s.query(he, p(n)),
526
+ mutationFn: async (n) => s.query(ve, p(n)),
521
527
  onSuccess: async (n, r, a) => {
522
- var u, i;
528
+ var u, o;
523
529
  await Promise.all([
524
530
  // Clear cart after successful order creation
525
531
  t.invalidateQueries({ queryKey: L.get() }),
526
532
  // Invalidate order list to refetch data
527
533
  t.invalidateQueries({ queryKey: U.lists() })
528
- ]), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
534
+ ]), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
529
535
  }
530
536
  });
531
537
  }
532
538
  const qe = "readLanguages post /language";
533
539
  function Ce(e) {
534
540
  const s = g();
535
- return P({
541
+ return C({
536
542
  queryKey: ee.all(),
537
543
  queryFn: ({ signal: t }) => s.query(qe, {
538
544
  ...p(e),
@@ -540,56 +546,56 @@ function Ce(e) {
540
546
  })
541
547
  });
542
548
  }
543
- function Rt(e) {
544
- return Q(Ce(e));
549
+ function Lt(e) {
550
+ return P(Ce(e));
545
551
  }
546
- const Se = "readCountry post /country", Pe = function(s) {
552
+ const Pe = "readCountry post /country", Se = function(s) {
547
553
  const t = g(), n = j.list(s);
548
- return P({
554
+ return C({
549
555
  queryKey: n,
550
556
  queryFn: async ({ signal: r }) => {
551
557
  const a = p(s);
552
- return t.query(Se, {
558
+ return t.query(Pe, {
553
559
  ...a,
554
560
  signal: r
555
561
  });
556
562
  }
557
563
  });
558
564
  };
559
- function Ft(e) {
560
- return Q(Pe(e));
565
+ function It(e) {
566
+ return P(Se(e));
561
567
  }
562
568
  const Qe = "changeEmail post /account/change-email";
563
- function Lt(e) {
564
- const s = g(), t = C();
565
- return v({
569
+ function xt(e) {
570
+ const s = g(), t = S();
571
+ return h({
566
572
  ...e,
567
573
  mutationFn: async (n) => s.query(Qe, p(n)),
568
574
  onSuccess: async (n, r, a) => {
569
- var u, i;
570
- await t.invalidateQueries({ queryKey: I.all() }), await t.invalidateQueries({ queryKey: F.all() }), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
575
+ var u, o;
576
+ await t.invalidateQueries({ queryKey: I.all() }), await t.invalidateQueries({ queryKey: F.all() }), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
571
577
  }
572
578
  });
573
579
  }
574
580
  const Me = "changeProfile post /account/change-profile";
575
- function It(e) {
576
- const s = g(), t = C();
577
- return v({
581
+ function Ut(e) {
582
+ const s = g(), t = S();
583
+ return h({
578
584
  ...e,
579
585
  mutationFn: async (n) => s.query(Me, p(n)),
580
586
  onSuccess: async (n, r, a) => {
581
- var u, i;
587
+ var u, o;
582
588
  await Promise.all([
583
589
  t.invalidateQueries({ queryKey: I.all() }),
584
590
  t.invalidateQueries({ queryKey: F.all() })
585
- ]), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
591
+ ]), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
586
592
  }
587
593
  });
588
594
  }
589
595
  const Oe = "loginCustomer post /account/login";
590
- function xt(e) {
591
- const s = g(), t = C();
592
- return v({
596
+ function Dt(e) {
597
+ const s = g(), t = S();
598
+ return h({
593
599
  ...e,
594
600
  mutationFn: async (n) => {
595
601
  const r = await s.queryRaw(Oe, {
@@ -598,104 +604,104 @@ function xt(e) {
598
604
  return a && (s.contextToken = a), r.json();
599
605
  },
600
606
  onSuccess: async (n, r, a) => {
601
- var u, i;
607
+ var u, o;
602
608
  await Promise.all([
603
609
  t.resetQueries({ queryKey: F.all() }),
604
610
  t.invalidateQueries({ queryKey: L.get() }),
605
611
  t.invalidateQueries({ queryKey: I.all() })
606
- ]), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
612
+ ]), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
607
613
  }
608
614
  });
609
615
  }
610
616
  const Ke = "logoutCustomer post /account/logout";
611
- function Ut(e) {
612
- const s = g(), t = C();
613
- return v({
617
+ function bt(e) {
618
+ const s = g(), t = S();
619
+ return h({
614
620
  ...e,
615
621
  mutationFn: async (n) => s.query(Ke, p(n)),
616
622
  onSuccess: async (n, r, a) => {
617
- var u, i;
623
+ var u, o;
618
624
  await Promise.all([
619
625
  t.resetQueries({ queryKey: F.all() }),
620
626
  t.invalidateQueries({ queryKey: L.get() }),
621
627
  t.invalidateQueries({ queryKey: I.all() })
622
- ]), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
628
+ ]), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
623
629
  }
624
630
  });
625
631
  }
626
632
  const Ae = "readCustomer post /account/customer";
627
633
  function we(e) {
628
634
  const s = g(), t = I.detail(c(() => p(e).body ?? {}));
629
- return P({
635
+ return C({
630
636
  queryKey: t,
631
637
  queryFn: async () => s.query(Ae, p(e))
632
638
  });
633
639
  }
634
640
  function Re(e) {
635
- return Q(we(e));
641
+ return P(we(e));
636
642
  }
637
643
  const Fe = "register post /account/register";
638
- function bt(e) {
639
- const s = g(), t = C();
640
- return v({
644
+ function kt(e) {
645
+ const s = g(), t = S();
646
+ return h({
641
647
  ...e,
642
648
  mutationFn: async (n) => s.query(Fe, p(n)),
643
649
  onSuccess: async (n, r, a) => {
644
- var u, i;
645
- await t.invalidateQueries({ queryKey: I.all() }), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
650
+ var u, o;
651
+ await t.invalidateQueries({ queryKey: I.all() }), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
646
652
  }
647
653
  });
648
654
  }
649
655
  const Le = "defaultBillingAddress patch /account/address/default-billing/{addressId}";
650
- function kt(e) {
651
- const s = g(), t = C();
652
- return v({
656
+ function Bt(e) {
657
+ const s = g(), t = S();
658
+ return h({
653
659
  ...e,
654
660
  mutationFn: async (n) => s.query(Le, p(n)),
655
661
  onSuccess: async (n, r, a) => {
656
- var u, i;
662
+ var u, o;
657
663
  await Promise.all([
658
664
  t.invalidateQueries({ queryKey: I.all() }),
659
665
  t.invalidateQueries({ queryKey: F.all() })
660
- ]), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
666
+ ]), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
661
667
  }
662
668
  });
663
669
  }
664
670
  const Ie = "defaultShippingAddress patch /account/address/default-shipping/{addressId}";
665
- function Bt(e) {
666
- const s = g(), t = C();
667
- return v({
671
+ function Nt(e) {
672
+ const s = g(), t = S();
673
+ return h({
668
674
  ...e,
669
675
  mutationFn: async (n) => s.query(Ie, p(n)),
670
676
  onSuccess: async (n, r, a) => {
671
- var u, i;
677
+ var u, o;
672
678
  await Promise.all([
673
679
  t.invalidateQueries({ queryKey: I.all() }),
674
680
  t.invalidateQueries({ queryKey: F.all() })
675
- ]), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
681
+ ]), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
676
682
  }
677
683
  });
678
684
  }
679
685
  const xe = "deleteCustomer delete /account/customer";
680
- function Dt(e) {
681
- const s = g(), t = C();
682
- return v({
686
+ function Tt(e) {
687
+ const s = g(), t = S();
688
+ return h({
683
689
  ...e,
684
690
  mutationFn: async (n) => s.query(xe, p(n)),
685
691
  onSuccess: async (n, r, a) => {
686
- var u, i;
692
+ var u, o;
687
693
  await Promise.all([
688
694
  t.resetQueries({ queryKey: I.all() }),
689
695
  t.resetQueries({ queryKey: F.all() }),
690
696
  t.resetQueries({ queryKey: L.get() })
691
- ]), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
697
+ ]), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
692
698
  }
693
699
  });
694
700
  }
695
701
  const Ue = "registerConfirm post /account/register-confirm";
696
- function Nt(e) {
702
+ function Et(e) {
697
703
  const s = g();
698
- return v({
704
+ return h({
699
705
  ...e,
700
706
  mutationFn: async (t) => {
701
707
  const n = await s.queryRaw(Ue, {
@@ -705,67 +711,67 @@ function Nt(e) {
705
711
  },
706
712
  onSuccess: async (t, n, r) => {
707
713
  var a, u;
708
- await ((u = o((a = o(e)) == null ? void 0 : a.onSuccess)) == null ? void 0 : u(t, n, r));
714
+ await ((u = i((a = i(e)) == null ? void 0 : a.onSuccess)) == null ? void 0 : u(t, n, r));
709
715
  }
710
716
  });
711
717
  }
712
- const be = "sendRecoveryMail post /account/recovery-password";
713
- function Tt(e) {
718
+ const De = "sendRecoveryMail post /account/recovery-password";
719
+ function jt(e) {
714
720
  const s = g();
715
- return v({
721
+ return h({
716
722
  ...e,
717
- mutationFn: async (t) => s.query(be, p(t)),
723
+ mutationFn: async (t) => s.query(De, p(t)),
718
724
  onSuccess: async (t, n, r) => {
719
725
  var a, u;
720
- await ((u = o((a = o(e)) == null ? void 0 : a.onSuccess)) == null ? void 0 : u(t, n, r));
726
+ await ((u = i((a = i(e)) == null ? void 0 : a.onSuccess)) == null ? void 0 : u(t, n, r));
721
727
  }
722
728
  });
723
729
  }
724
- const ke = "changePassword post /account/change-password";
725
- function Et(e) {
730
+ const be = "changePassword post /account/change-password";
731
+ function Vt(e) {
726
732
  const s = g();
727
- return v({
733
+ return h({
728
734
  ...e,
729
- mutationFn: async (t) => s.query(ke, p(t)),
735
+ mutationFn: async (t) => s.query(be, p(t)),
730
736
  onSuccess: async (t, n, r) => {
731
737
  var a, u;
732
- await ((u = o((a = o(e)) == null ? void 0 : a.onSuccess)) == null ? void 0 : u(t, n, r));
738
+ await ((u = i((a = i(e)) == null ? void 0 : a.onSuccess)) == null ? void 0 : u(t, n, r));
733
739
  }
734
740
  });
735
741
  }
736
- const Be = "imitateCustomerLogin post /account/login/imitate-customer";
737
- function De(e) {
742
+ const ke = "imitateCustomerLogin post /account/login/imitate-customer";
743
+ function Be(e) {
738
744
  const s = g(), t = I.imitateLogin(c(() => p(e).body ?? {}));
739
- return P({
745
+ return C({
740
746
  queryKey: t,
741
- queryFn: async () => s.query(Be, p(e))
747
+ queryFn: async () => s.query(ke, p(e))
742
748
  });
743
749
  }
744
- function jt(e) {
745
- return Q(De(e));
750
+ function $t(e) {
751
+ return P(Be(e));
746
752
  }
747
753
  const Ne = "recoveryPassword post /account/recovery-password-confirm";
748
- function Vt(e) {
754
+ function zt(e) {
749
755
  const s = g();
750
- return v({
756
+ return h({
751
757
  ...e,
752
758
  mutationFn: async (t) => s.query(Ne, p(t)),
753
759
  onSuccess: async (t, n, r) => {
754
760
  var a, u;
755
- await ((u = o((a = o(e)) == null ? void 0 : a.onSuccess)) == null ? void 0 : u(t, n, r));
761
+ await ((u = i((a = i(e)) == null ? void 0 : a.onSuccess)) == null ? void 0 : u(t, n, r));
756
762
  }
757
763
  });
758
764
  }
759
765
  const Te = "readNavigation post /navigation/{activeId}/{rootId}", Ee = function(s, t, n) {
760
- const r = g(), a = b.detail(s, t, n);
761
- return P({
766
+ const r = g(), a = D.detail(s, t, n);
767
+ return C({
762
768
  queryKey: a,
763
769
  queryFn: async ({ signal: u }) => {
764
- const i = o(s), f = o(t), S = p(n);
770
+ const o = i(s), f = i(t), Q = p(n);
765
771
  return r.query(Te, {
766
- ...S,
772
+ ...Q,
767
773
  params: {
768
- activeId: i,
774
+ activeId: o,
769
775
  rootId: f
770
776
  },
771
777
  signal: u
@@ -773,8 +779,8 @@ const Te = "readNavigation post /navigation/{activeId}/{rootId}", Ee = function(
773
779
  }
774
780
  });
775
781
  };
776
- function $t(e, s, t) {
777
- return Q(Ee(e, s, t));
782
+ function Gt(e, s, t) {
783
+ return P(Ee(e, s, t));
778
784
  }
779
785
  const je = "readPaymentMethod post /payment-method";
780
786
  function Ve(e) {
@@ -782,7 +788,7 @@ function Ve(e) {
782
788
  var n;
783
789
  return (n = p(e)) == null ? void 0 : n.body;
784
790
  }));
785
- return P({
791
+ return C({
786
792
  queryKey: t,
787
793
  queryFn: ({ signal: n }) => s.query(je, {
788
794
  ...p(e),
@@ -791,35 +797,35 @@ function Ve(e) {
791
797
  });
792
798
  }
793
799
  function $e(e) {
794
- return Q(Ve(e));
800
+ return P(Ve(e));
795
801
  }
796
802
  const ze = "handlePaymentMethod post /handle-payment";
797
- function zt(e) {
798
- const s = g(), t = C();
799
- return v({
803
+ function Ht(e) {
804
+ const s = g(), t = S();
805
+ return h({
800
806
  ...e,
801
807
  mutationFn: async (n) => s.query(ze, p(n)),
802
808
  onSuccess: async (n, r, a) => {
803
- var u, i;
804
- await t.invalidateQueries({ queryKey: L.get() }), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
809
+ var u, o;
810
+ await t.invalidateQueries({ queryKey: L.get() }), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
805
811
  }
806
812
  });
807
813
  }
808
814
  const Ge = "orderSetPayment post /order/payment";
809
- function Gt(e) {
810
- const s = g(), t = C();
811
- return v({
815
+ function Wt(e) {
816
+ const s = g(), t = S();
817
+ return h({
812
818
  ...e,
813
819
  mutationFn: async (n) => s.query(Ge, p(n)),
814
820
  onSuccess: async (n, r, a) => {
815
- var u, i;
816
- await t.invalidateQueries({ queryKey: U.all() }), await ((i = o((u = o(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : i(n, r, a));
821
+ var u, o;
822
+ await t.invalidateQueries({ queryKey: U.all() }), await ((o = i((u = i(e)) == null ? void 0 : u.onSuccess)) == null ? void 0 : o(n, r, a));
817
823
  }
818
824
  });
819
825
  }
820
826
  const He = "readCategoryList post /category", We = function(s) {
821
- const t = g(), n = B.list(s);
822
- return P({
827
+ const t = g(), n = k.list(s);
828
+ return C({
823
829
  queryKey: n,
824
830
  queryFn: async ({ signal: r }) => t.query(He, {
825
831
  ...p(s),
@@ -827,13 +833,13 @@ const He = "readCategoryList post /category", We = function(s) {
827
833
  })
828
834
  });
829
835
  };
830
- function Ht(e) {
831
- return Q(We(e));
836
+ function Jt(e) {
837
+ return P(We(e));
832
838
  }
833
839
  const Je = "readCompactProductListing post /novu/headless/product-listing/{seoUrl}";
834
840
  function Xe(e, s) {
835
- const t = g(), n = w.list(e, s);
836
- return P({
841
+ const t = g(), n = A.list(e, s);
842
+ return C({
837
843
  queryKey: n,
838
844
  queryFn: async ({ signal: r }) => {
839
845
  const a = p(s);
@@ -841,20 +847,20 @@ function Xe(e, s) {
841
847
  ...a,
842
848
  params: {
843
849
  ...a.params,
844
- seoUrl: V(o(e))
850
+ seoUrl: V(i(e))
845
851
  },
846
852
  signal: r
847
853
  });
848
854
  }
849
855
  });
850
856
  }
851
- function Wt(e, s) {
852
- return Q(Xe(e, s));
857
+ function Xt(e, s) {
858
+ return P(Xe(e, s));
853
859
  }
854
860
  const Ye = "readCustomProductDetail post /novu/headless/product/{seoUrl}";
855
861
  function Ze(e, s) {
856
- const t = g(), n = w.customDetail(e, s);
857
- return P({
862
+ const t = g(), n = A.customDetail(e, s);
863
+ return C({
858
864
  queryKey: n,
859
865
  queryFn: async ({ signal: r }) => {
860
866
  const a = p(s);
@@ -862,20 +868,20 @@ function Ze(e, s) {
862
868
  ...a,
863
869
  params: {
864
870
  ...a.params,
865
- seoUrl: V(o(e))
871
+ seoUrl: V(i(e))
866
872
  },
867
873
  signal: r
868
874
  });
869
875
  }
870
876
  });
871
877
  }
872
- function Jt(e, s) {
873
- return Q(Ze(e, s));
878
+ function Yt(e, s) {
879
+ return P(Ze(e, s));
874
880
  }
875
881
  const _e = "searchPage post /search";
876
882
  function et(e) {
877
- const s = g(), t = w.search(e);
878
- return P({
883
+ const s = g(), t = A.search(e);
884
+ return C({
879
885
  queryKey: t,
880
886
  queryFn: async ({ signal: n }) => {
881
887
  const r = p(e);
@@ -886,13 +892,13 @@ function et(e) {
886
892
  }
887
893
  });
888
894
  }
889
- function Xt(e) {
890
- return Q(et(e));
895
+ function Zt(e) {
896
+ return P(et(e));
891
897
  }
892
898
  const tt = "readProduct post /product";
893
899
  function nt(e) {
894
- const s = g(), t = w.detail(e);
895
- return P({
900
+ const s = g(), t = A.headlessDetail(e);
901
+ return C({
896
902
  queryKey: t,
897
903
  queryFn: async ({ signal: n }) => {
898
904
  const r = p(e);
@@ -903,71 +909,92 @@ function nt(e) {
903
909
  }
904
910
  });
905
911
  }
906
- function Yt(e) {
907
- return Q(nt(e));
912
+ function _t(e) {
913
+ return P(nt(e));
908
914
  }
909
- const st = "readSalutation post /salutation", rt = function(s) {
910
- const t = g(), n = E.list(s);
911
- return P({
915
+ const st = "readProductDetail post /product/{productId}";
916
+ function rt(e, s) {
917
+ const t = g(), n = A.detail(s);
918
+ return C({
912
919
  queryKey: n,
913
920
  queryFn: async ({ signal: r }) => {
914
921
  const a = p(s);
915
922
  return t.query(st, {
923
+ ...a,
924
+ params: {
925
+ ...a.params,
926
+ productId: i(e)
927
+ },
928
+ signal: r
929
+ });
930
+ }
931
+ });
932
+ }
933
+ function en(e, s) {
934
+ return P(rt(e, s));
935
+ }
936
+ const at = "readSalutation post /salutation", ut = function(s) {
937
+ const t = g(), n = E.list(s);
938
+ return C({
939
+ queryKey: n,
940
+ queryFn: async ({ signal: r }) => {
941
+ const a = p(s);
942
+ return t.query(at, {
916
943
  ...a,
917
944
  signal: r
918
945
  });
919
946
  }
920
947
  });
921
948
  };
922
- function Zt(e) {
923
- return Q(rt(e));
949
+ function tn(e) {
950
+ return P(ut(e));
924
951
  }
925
- const at = "readSeoUrl post /seo-url", ut = function(s) {
952
+ const ot = "readSeoUrl post /seo-url", it = function(s) {
926
953
  const t = g(), n = T.list(s);
927
- return P({
954
+ return C({
928
955
  queryKey: n,
929
956
  queryFn: async ({ signal: r }) => {
930
957
  const a = p(s);
931
- return t.query(at, {
958
+ return t.query(ot, {
932
959
  ...a,
933
960
  signal: r
934
961
  });
935
962
  }
936
963
  });
937
964
  };
938
- function _t(e) {
939
- return Q(ut(e));
965
+ function nn(e) {
966
+ return P(it(e));
940
967
  }
941
- const it = "readShippingMethod post /shipping-method";
942
- function ot(e) {
943
- const s = g(), t = D.list(c(() => {
968
+ const ct = "readShippingMethod post /shipping-method";
969
+ function lt(e) {
970
+ const s = g(), t = B.list(c(() => {
944
971
  var n;
945
972
  return (n = p(e)) == null ? void 0 : n.body;
946
973
  }));
947
- return P({
974
+ return C({
948
975
  queryKey: t,
949
- queryFn: ({ signal: n }) => s.query(it, {
976
+ queryFn: ({ signal: n }) => s.query(ct, {
950
977
  ...p(e),
951
978
  signal: n
952
979
  })
953
980
  });
954
981
  }
955
- function ct(e) {
956
- return Q(ot(e));
982
+ function dt(e) {
983
+ return P(lt(e));
957
984
  }
958
- function en() {
959
- const e = k(), s = $(), t = $e({
985
+ function sn() {
986
+ const e = b(), s = $(), t = $e({
960
987
  query: {
961
988
  onlyAvailable: !0
962
989
  }
963
- }), n = c(() => s.isPending.value), r = async (i) => s.mutateAsync({
964
- paymentMethodId: i
990
+ }), n = c(() => s.isPending.value), r = async (o) => s.mutateAsync({
991
+ paymentMethodId: o
965
992
  }), a = c(() => {
966
- var i, f;
967
- return (f = (i = e.data) == null ? void 0 : i.value) == null ? void 0 : f.paymentMethod;
993
+ var o, f;
994
+ return (f = (o = e.data) == null ? void 0 : o.value) == null ? void 0 : f.paymentMethod;
968
995
  }), u = c(() => {
969
- var i, f, S;
970
- return ((S = (f = (i = t.data) == null ? void 0 : i.value) == null ? void 0 : f.elements) == null ? void 0 : S.sort((d, M) => (d.position ?? 0) - (M.position ?? 0))) ?? [];
996
+ var o, f, Q;
997
+ return ((Q = (f = (o = t.data) == null ? void 0 : o.value) == null ? void 0 : f.elements) == null ? void 0 : Q.sort((d, M) => (d.position ?? 0) - (M.position ?? 0))) ?? [];
971
998
  });
972
999
  return {
973
1000
  contextUpdateMutation: s,
@@ -979,19 +1006,19 @@ function en() {
979
1006
  paymentMethods: u
980
1007
  };
981
1008
  }
982
- function tn() {
983
- const e = k(), s = $(), t = ct({
1009
+ function rn() {
1010
+ const e = b(), s = $(), t = dt({
984
1011
  query: {
985
1012
  onlyAvailable: !0
986
1013
  }
987
- }), n = c(() => s.isPending.value), r = async (i) => s.mutateAsync({
988
- shippingMethodId: i
1014
+ }), n = c(() => s.isPending.value), r = async (o) => s.mutateAsync({
1015
+ shippingMethodId: o
989
1016
  }), a = c(() => {
990
- var i, f;
991
- return (f = (i = e.data) == null ? void 0 : i.value) == null ? void 0 : f.shippingMethod;
1017
+ var o, f;
1018
+ return (f = (o = e.data) == null ? void 0 : o.value) == null ? void 0 : f.shippingMethod;
992
1019
  }), u = c(() => {
993
- var i, f;
994
- return ((f = (i = t.data) == null ? void 0 : i.value) == null ? void 0 : f.elements.sort((S, d) => (S.position ?? 0) - (d.position ?? 0))) ?? [];
1020
+ var o, f;
1021
+ return ((f = (o = t.data) == null ? void 0 : o.value) == null ? void 0 : f.elements.sort((Q, d) => (Q.position ?? 0) - (d.position ?? 0))) ?? [];
995
1022
  });
996
1023
  return {
997
1024
  contextUpdateMutation: s,
@@ -1003,7 +1030,7 @@ function tn() {
1003
1030
  shippingMethods: u
1004
1031
  };
1005
1032
  }
1006
- const lt = (e, s) => {
1033
+ const yt = (e, s) => {
1007
1034
  var n;
1008
1035
  const t = (n = e == null ? void 0 : e.extensions) == null ? void 0 : n.novuSeoUrls;
1009
1036
  if (Array.isArray(s)) {
@@ -1011,52 +1038,52 @@ const lt = (e, s) => {
1011
1038
  return r ? (t == null ? void 0 : t[r]) ?? "" : "";
1012
1039
  }
1013
1040
  return (t == null ? void 0 : t[s]) ?? "";
1014
- }, nn = () => {
1015
- const e = k(), s = c(() => {
1041
+ }, an = () => {
1042
+ const e = b(), s = c(() => {
1016
1043
  var t, n, r;
1017
1044
  return ((r = (n = (t = e.data) == null ? void 0 : t.value) == null ? void 0 : n.context) == null ? void 0 : r.languageIdChain) ?? [];
1018
1045
  });
1019
1046
  return (t, n) => {
1020
1047
  const r = [n, ...s.value];
1021
- return lt(o(t), o(r));
1048
+ return yt(i(t), i(r));
1022
1049
  };
1023
1050
  };
1024
- function sn(e) {
1051
+ function un(e) {
1025
1052
  const { total: s, limit: t, page: n, totalCountMode: r } = e ?? {}, a = Z({
1026
1053
  page: n ?? 1,
1027
1054
  total: s ?? 0,
1028
1055
  limit: t,
1029
1056
  totalCountMode: r
1030
- }), u = c(() => a.limit === void 0 ? 1 : Math.max(1, Math.ceil(a.total / a.limit))), i = c({
1057
+ }), u = c(() => a.limit === void 0 ? 1 : Math.max(1, Math.ceil(a.total / a.limit))), o = c({
1031
1058
  get() {
1032
1059
  return a.page;
1033
1060
  },
1034
1061
  set(O) {
1035
- a.page = Math.max(1, Math.min(o(u), O));
1062
+ a.page = Math.max(1, Math.min(i(u), O));
1036
1063
  }
1037
1064
  });
1038
1065
  H(
1039
- [() => o(u), () => a],
1066
+ [() => i(u), () => a],
1040
1067
  ([O, y]) => {
1041
1068
  a.page = Math.min(O, a.page), a.total = y.total ?? 0, a.limit = y.limit;
1042
1069
  }
1043
1070
  );
1044
- const f = c(() => a.page === o(u)), S = c(() => a.page === 1), d = c(() => ({
1071
+ const f = c(() => a.page === i(u)), Q = c(() => a.page === 1), d = c(() => ({
1045
1072
  p: a.page,
1046
1073
  limit: a.limit,
1047
1074
  "total-count-mode": a.totalCountMode ?? "none"
1048
1075
  })), M = (O) => {
1049
- H(() => o(O), (y) => {
1076
+ H(() => i(O), (y) => {
1050
1077
  y && (a.total = (y == null ? void 0 : y.total) ?? 0, a.limit = (y == null ? void 0 : y.limit) ?? 0);
1051
1078
  });
1052
1079
  };
1053
1080
  return {
1054
- page: o(i),
1081
+ page: i(o),
1055
1082
  total: W(a, "total"),
1056
1083
  limit: W(a, "limit"),
1057
1084
  pageCount: u,
1058
1085
  isLastPage: f,
1059
- isFirstPage: S,
1086
+ isFirstPage: Q,
1060
1087
  usePaginationSync: M,
1061
1088
  // This can be used to pass the pagination options directly to the query options
1062
1089
  queryOptions: d
@@ -1073,32 +1100,32 @@ function X(e) {
1073
1100
  unitPrice: n
1074
1101
  }));
1075
1102
  }
1076
- function rn(e) {
1103
+ function on(e) {
1077
1104
  const s = c(() => {
1078
1105
  var y;
1079
1106
  return (y = e.value) == null ? void 0 : y.calculatedCheapestPrice;
1080
1107
  }), t = c(
1081
1108
  () => {
1082
- var y, h, K, A, l;
1083
- return (((h = (y = e.value) == null ? void 0 : y.calculatedPrices) == null ? void 0 : h.length) ?? 0) > 0 ? (A = (K = e.value) == null ? void 0 : K.calculatedPrices) == null ? void 0 : A[0] : (l = e.value) == null ? void 0 : l.calculatedPrice;
1109
+ var y, v, K, w, l;
1110
+ return (((v = (y = e.value) == null ? void 0 : y.calculatedPrices) == null ? void 0 : v.length) ?? 0) > 0 ? (w = (K = e.value) == null ? void 0 : K.calculatedPrices) == null ? void 0 : w[0] : (l = e.value) == null ? void 0 : l.calculatedPrice;
1084
1111
  }
1085
1112
  ), n = c(() => {
1086
1113
  var y;
1087
1114
  return (y = t == null ? void 0 : t.value) == null ? void 0 : y.referencePrice;
1088
1115
  }), r = c(() => {
1089
- var y, h;
1090
- return (((h = (y = e.value) == null ? void 0 : y.calculatedPrices) == null ? void 0 : h.length) ?? 0) > 1;
1116
+ var y, v;
1117
+ return (((v = (y = e.value) == null ? void 0 : y.calculatedPrices) == null ? void 0 : v.length) ?? 0) > 1;
1091
1118
  }), a = c(
1092
1119
  () => {
1093
- var y, h, K, A, l, m;
1094
- return !!((y = e.value) != null && y.parentId) && ((K = (h = e.value) == null ? void 0 : h.calculatedCheapestPrice) == null ? void 0 : K.hasRange) && ((A = t == null ? void 0 : t.value) == null ? void 0 : A.unitPrice) !== ((l = s == null ? void 0 : s.value) == null ? void 0 : l.unitPrice) && ((m = s == null ? void 0 : s.value) == null ? void 0 : m.unitPrice);
1120
+ var y, v, K, w, l, m;
1121
+ return !!((y = e.value) != null && y.parentId) && ((K = (v = e.value) == null ? void 0 : v.calculatedCheapestPrice) == null ? void 0 : K.hasRange) && ((w = t == null ? void 0 : t.value) == null ? void 0 : w.unitPrice) !== ((l = s == null ? void 0 : s.value) == null ? void 0 : l.unitPrice) && ((m = s == null ? void 0 : s.value) == null ? void 0 : m.unitPrice);
1095
1122
  }
1096
1123
  ), u = c(
1097
1124
  () => {
1098
- var y, h;
1099
- return r.value && X(e.value).length > 1 ? (h = (y = e.value) == null ? void 0 : y.calculatedPrices) == null ? void 0 : h.reduce((K, A) => A.unitPrice < K.unitPrice ? A : K) : t.value;
1125
+ var y, v;
1126
+ return r.value && X(e.value).length > 1 ? (v = (y = e.value) == null ? void 0 : y.calculatedPrices) == null ? void 0 : v.reduce((K, w) => w.unitPrice < K.unitPrice ? w : K) : t.value;
1100
1127
  }
1101
- ), i = c(
1128
+ ), o = c(
1102
1129
  () => {
1103
1130
  var y;
1104
1131
  return (y = u.value) == null ? void 0 : y.unitPrice;
@@ -1108,21 +1135,21 @@ function rn(e) {
1108
1135
  var y;
1109
1136
  return (y = u.value) == null ? void 0 : y.totalPrice;
1110
1137
  }
1111
- ), S = c(
1138
+ ), Q = c(
1112
1139
  () => u.value
1113
1140
  ), d = c(() => {
1114
- var y, h;
1115
- return !!((h = (y = u.value) == null ? void 0 : y.listPrice) != null && h.percentage);
1141
+ var y, v;
1142
+ return !!((v = (y = u.value) == null ? void 0 : y.listPrice) != null && v.percentage);
1116
1143
  }), M = c(
1117
1144
  () => {
1118
- var y, h, K;
1119
- return (K = (h = (y = e.value) == null ? void 0 : y.calculatedPrice) == null ? void 0 : h.regulationPrice) == null ? void 0 : K.price;
1145
+ var y, v, K;
1146
+ return (K = (v = (y = e.value) == null ? void 0 : y.calculatedPrice) == null ? void 0 : v.regulationPrice) == null ? void 0 : K.price;
1120
1147
  }
1121
1148
  ), O = c(() => X(e.value));
1122
1149
  return {
1123
- price: S,
1150
+ price: Q,
1124
1151
  totalPrice: f,
1125
- unitPrice: i,
1152
+ unitPrice: o,
1126
1153
  displayFromVariants: a,
1127
1154
  displayFrom: r,
1128
1155
  tierPrices: O,
@@ -1131,7 +1158,7 @@ function rn(e) {
1131
1158
  regulationPrice: M
1132
1159
  };
1133
1160
  }
1134
- function dt(e, s) {
1161
+ function pt(e, s) {
1135
1162
  var n;
1136
1163
  const t = (n = e.extensions) == null ? void 0 : n.variants;
1137
1164
  return s.length === 0 ? (t == null ? void 0 : t.find((r) => {
@@ -1142,16 +1169,16 @@ function dt(e, s) {
1142
1169
  return (a = r.optionIds) == null ? void 0 : a.every((u) => s.includes(u));
1143
1170
  });
1144
1171
  }
1145
- function an(e, s) {
1146
- return c(() => dt(o(e), o(s)));
1172
+ function cn(e, s) {
1173
+ return c(() => pt(i(e), i(s)));
1147
1174
  }
1148
- function un(e) {
1175
+ function ln(e) {
1149
1176
  return c(() => {
1150
1177
  var s, t, n, r, a, u;
1151
- return !!((t = (s = o(e)) == null ? void 0 : s.customer) != null && t.id) && !!((r = (n = o(e)) == null ? void 0 : n.customer) != null && r.active) && !((u = (a = o(e)) == null ? void 0 : a.customer) != null && u.guest);
1178
+ return !!((t = (s = i(e)) == null ? void 0 : s.customer) != null && t.id) && !!((r = (n = i(e)) == null ? void 0 : n.customer) != null && r.active) && !((u = (a = i(e)) == null ? void 0 : a.customer) != null && u.guest);
1152
1179
  });
1153
1180
  }
1154
- function on(e) {
1181
+ function dn(e) {
1155
1182
  const s = Re(e ? { body: e } : void 0), t = c(() => {
1156
1183
  var d;
1157
1184
  return (d = s.data) == null ? void 0 : d.value;
@@ -1173,7 +1200,7 @@ function on(e) {
1173
1200
  var d;
1174
1201
  return ((d = t.value) == null ? void 0 : d.defaultBillingAddressId) || null;
1175
1202
  }
1176
- ), i = c(
1203
+ ), o = c(
1177
1204
  () => {
1178
1205
  var d;
1179
1206
  return ((d = t.value) == null ? void 0 : d.defaultShippingAddressId) || null;
@@ -1183,7 +1210,7 @@ function on(e) {
1183
1210
  var d;
1184
1211
  return ((d = t.value) == null ? void 0 : d.defaultBillingAddress) || null;
1185
1212
  }
1186
- ), S = c(
1213
+ ), Q = c(
1187
1214
  () => {
1188
1215
  var d;
1189
1216
  return ((d = t.value) == null ? void 0 : d.defaultShippingAddress) || null;
@@ -1196,104 +1223,106 @@ function on(e) {
1196
1223
  isCustomerSession: r,
1197
1224
  isGuestSession: a,
1198
1225
  defaultBillingAddressId: u,
1199
- defaultShippingAddressId: i,
1226
+ defaultShippingAddressId: o,
1200
1227
  userDefaultBillingAddress: f,
1201
- userDefaultShippingAddress: S,
1228
+ userDefaultShippingAddress: Q,
1202
1229
  // Expose queries and mutations directly
1203
1230
  customerQuery: s
1204
1231
  };
1205
1232
  }
1206
1233
  export {
1207
- ft as absolutizeSeoUrl,
1234
+ vt as absolutizeSeoUrl,
1208
1235
  R as addressKeys,
1209
1236
  L as cartKeys,
1210
- B as categoryKeys,
1237
+ k as categoryKeys,
1211
1238
  F as contextKeys,
1212
1239
  j as countryKeys,
1213
1240
  I as customerKeys,
1214
- dt as getProductVariantForOptions,
1241
+ pt as getProductVariantForOptions,
1215
1242
  ee as languageKey,
1216
- b as navigationKeys,
1243
+ D as navigationKeys,
1217
1244
  U as orderKeys,
1218
1245
  N as paymentKeys,
1219
- w as productKeys,
1246
+ A as productKeys,
1220
1247
  je as readPaymentMethodOperation,
1221
- it as readShippingMethodOperation,
1248
+ ct as readShippingMethodOperation,
1222
1249
  V as relativizeSeoUrl,
1223
1250
  E as salutationKeys,
1224
1251
  T as seoUrlKeys,
1225
- D as shippingKeys,
1252
+ B as shippingKeys,
1226
1253
  _ as shopwareClientKey,
1227
1254
  p as unrefOptions,
1228
- Mt as useAddLineItemMutation,
1229
- Lt as useChangeEmailMutation,
1230
- Et as useChangePasswordMutation,
1231
- It as useChangeProfileMutation,
1232
- ht as useCheckoutAddresses,
1233
- St as useCreateCustomerAddressMutation,
1234
- wt as useCreateOrderMutation,
1235
- kt as useDefaultBillingAddressMutation,
1236
- Bt as useDefaultShippingAddressMutation,
1237
- Pt as useDeleteCustomerAddressMutation,
1238
- Dt as useDeleteCustomerMutation,
1239
- zt as useHandlePaymentMutation,
1240
- jt as useImitateCustomerLoginQuery,
1241
- De as useImitateCustomerLoginQueryOptions,
1242
- un as useIsLoggedIn,
1255
+ Kt as useAddLineItemMutation,
1256
+ xt as useChangeEmailMutation,
1257
+ Vt as useChangePasswordMutation,
1258
+ Ut as useChangeProfileMutation,
1259
+ Ct as useCheckoutAddresses,
1260
+ Qt as useCreateCustomerAddressMutation,
1261
+ Ft as useCreateOrderMutation,
1262
+ Bt as useDefaultBillingAddressMutation,
1263
+ Nt as useDefaultShippingAddressMutation,
1264
+ Mt as useDeleteCustomerAddressMutation,
1265
+ Tt as useDeleteCustomerMutation,
1266
+ Ht as useHandlePaymentMutation,
1267
+ $t as useImitateCustomerLoginQuery,
1268
+ Be as useImitateCustomerLoginQueryOptions,
1269
+ ln as useIsLoggedIn,
1243
1270
  se as useListAddressQuery,
1244
1271
  ne as useListAddressQueryOptions,
1245
- xt as useLoginCustomerMutation,
1246
- Ut as useLogoutCustomerMutation,
1247
- vt as useOptimistic,
1248
- qt as useOrderDetails,
1249
- Ct as useOrderPayment,
1250
- Gt as useOrderSetPaymentMutation,
1251
- sn as usePagination,
1252
- en as usePaymentMethods,
1253
- rn as useProductPrice,
1254
- an as useProductVariantForOptions,
1255
- Ot as useReadCartQuery,
1272
+ Dt as useLoginCustomerMutation,
1273
+ bt as useLogoutCustomerMutation,
1274
+ qt as useOptimistic,
1275
+ Pt as useOrderDetails,
1276
+ St as useOrderPayment,
1277
+ Wt as useOrderSetPaymentMutation,
1278
+ un as usePagination,
1279
+ sn as usePaymentMethods,
1280
+ on as useProductPrice,
1281
+ cn as useProductVariantForOptions,
1282
+ At as useReadCartQuery,
1256
1283
  me as useReadCartQueryOptions,
1257
- Ht as useReadCategoryListQuery,
1284
+ Jt as useReadCategoryListQuery,
1258
1285
  We as useReadCategoryListQueryOptions,
1259
- Wt as useReadCompactProductListingQuery,
1286
+ Xt as useReadCompactProductListingQuery,
1260
1287
  Xe as useReadCompactProductListingQueryOptions,
1261
- k as useReadContextQuery,
1288
+ b as useReadContextQuery,
1262
1289
  ae as useReadContextQueryOptions,
1263
- Ft as useReadCountryQuery,
1264
- Pe as useReadCountryQueryOptions,
1290
+ It as useReadCountryQuery,
1291
+ Se as useReadCountryQueryOptions,
1265
1292
  Ze as useReadCustomProductDetailOptions,
1266
- Jt as useReadCustomProductDetailQuery,
1293
+ Yt as useReadCustomProductDetailQuery,
1267
1294
  Re as useReadCustomerQuery,
1268
1295
  we as useReadCustomerQueryOptions,
1269
- Rt as useReadLanguageQuery,
1296
+ Lt as useReadLanguageQuery,
1270
1297
  Ce as useReadLanguageQueryOptions,
1271
- $t as useReadNavigationQuery,
1298
+ Gt as useReadNavigationQuery,
1272
1299
  Ee as useReadNavigationQueryOptions,
1273
1300
  ce as useReadOrderQuery,
1274
- oe as useReadOrderQueryOptions,
1301
+ ie as useReadOrderQueryOptions,
1275
1302
  $e as useReadPaymentMethodQuery,
1276
1303
  Ve as useReadPaymentMethodQueryOptions,
1277
- Yt as useReadProductQuery,
1304
+ en as useReadProductDetailQuery,
1305
+ rt as useReadProductDetailQueryOptions,
1306
+ _t as useReadProductQuery,
1278
1307
  nt as useReadProductQueryOptions,
1279
- Zt as useReadSalutationQuery,
1280
- rt as useReadSalutationQueryOptions,
1281
- _t as useReadSeoUrlQuery,
1282
- ut as useReadSeoUrlQueryOptions,
1283
- ct as useReadShippingMethodQuery,
1284
- ot as useReadShippingMethodQueryOptions,
1285
- Vt as useRecoveryPasswordMutation,
1286
- Nt as useRegisterConfirmMutation,
1287
- bt as useRegisterCustomerMutation,
1288
- Kt as useRemoveLineItemMutation,
1289
- Xt as useSearchPageQuery,
1308
+ tn as useReadSalutationQuery,
1309
+ ut as useReadSalutationQueryOptions,
1310
+ nn as useReadSeoUrlQuery,
1311
+ it as useReadSeoUrlQueryOptions,
1312
+ dt as useReadShippingMethodQuery,
1313
+ lt as useReadShippingMethodQueryOptions,
1314
+ zt as useRecoveryPasswordMutation,
1315
+ Et as useRegisterConfirmMutation,
1316
+ kt as useRegisterCustomerMutation,
1317
+ wt as useRemoveLineItemMutation,
1318
+ Zt as useSearchPageQuery,
1290
1319
  et as useSearchPageQueryOptions,
1291
- Tt as useSendRecoveryMailMutation,
1292
- nn as useSeoUrl,
1293
- tn as useShippingMethods,
1320
+ jt as useSendRecoveryMailMutation,
1321
+ an as useSeoUrl,
1322
+ rn as useShippingMethods,
1294
1323
  g as useShopwareQueryClient,
1295
1324
  $ as useUpdateContextMutation,
1296
- Qt as useUpdateCustomerAddressMutation,
1297
- At as useUpdateLineItemMutation,
1298
- on as useUser
1325
+ Ot as useUpdateCustomerAddressMutation,
1326
+ Rt as useUpdateLineItemMutation,
1327
+ dn as useUser
1299
1328
  };