@simpleapps-com/augur-hooks 1.0.7 → 1.0.9

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.cjs CHANGED
@@ -41,7 +41,9 @@
41
41
 
42
42
 
43
43
 
44
- var _chunkC7JC34SMcjs = require('./chunk-C7JC34SM.cjs');
44
+
45
+
46
+ var _chunkDYM6U3QOcjs = require('./chunk-DYM6U3QO.cjs');
45
47
 
46
48
 
47
49
  var _chunkAXCNTEABcjs = require('./chunk-AXCNTEAB.cjs');
@@ -59,11 +61,13 @@ var AugurAuthReactContext = _react.createContext.call(void 0,
59
61
  );
60
62
  var AugurCacheContext = _react.createContext.call(void 0, void 0);
61
63
  var AugurOptionsContext = _react.createContext.call(void 0, null);
64
+ var AugurSiteContext = _react.createContext.call(void 0, void 0);
62
65
  function AugurHooksProvider({
63
66
  api,
64
67
  callbacks,
65
68
  auth,
66
69
  cache,
70
+ site,
67
71
  children
68
72
  }) {
69
73
  if (process.env.NODE_ENV === "development" && !api && !callbacks) {
@@ -77,7 +81,7 @@ function AugurHooksProvider({
77
81
  // eslint-disable-next-line react-hooks/exhaustive-deps
78
82
  [api]
79
83
  );
80
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AugurApiContext.Provider, { value: _nullishCoalesce(api, () => ( null)), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AugurCallbacksContext.Provider, { value: callbacks, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AugurAuthReactContext.Provider, { value: auth, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AugurCacheContext.Provider, { value: cache, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AugurOptionsContext.Provider, { value: options, children }) }) }) }) });
84
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AugurApiContext.Provider, { value: _nullishCoalesce(api, () => ( null)), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AugurCallbacksContext.Provider, { value: callbacks, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AugurAuthReactContext.Provider, { value: auth, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AugurCacheContext.Provider, { value: cache, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AugurSiteContext.Provider, { value: site, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AugurOptionsContext.Provider, { value: options, children }) }) }) }) }) });
81
85
  }
82
86
  function useAugurOptions() {
83
87
  const options = _react.useContext.call(void 0, AugurOptionsContext);
@@ -109,6 +113,9 @@ function useAugurAuth() {
109
113
  function useAugurCache() {
110
114
  return _react.useContext.call(void 0, AugurCacheContext);
111
115
  }
116
+ function useAugurSite() {
117
+ return _react.useContext.call(void 0, AugurSiteContext);
118
+ }
112
119
 
113
120
  // src/stores/cart-store.ts
114
121
  var _zustand = require('zustand');
@@ -187,13 +194,36 @@ function useDebounce(value, delay = 500) {
187
194
  }
188
195
 
189
196
  // src/hooks/use-format-price.ts
190
- function useFormatPrice(locale = "en-US", currency = "USD") {
191
- const formatPrice = (price) => {
197
+ function normaliseOptions(optionsOrLocale, legacyCurrency) {
198
+ if (typeof optionsOrLocale === "string") {
199
+ return { locale: optionsOrLocale, currency: legacyCurrency };
200
+ }
201
+ return _nullishCoalesce(optionsOrLocale, () => ( {}));
202
+ }
203
+ function resolveFormatting(opts, siteFormatting) {
204
+ return {
205
+ locale: _nullishCoalesce(_nullishCoalesce(opts.locale, () => ( _optionalChain([siteFormatting, 'optionalAccess', _ => _.locale]))), () => ( "en-US")),
206
+ currency: _nullishCoalesce(_nullishCoalesce(opts.currency, () => ( _optionalChain([siteFormatting, 'optionalAccess', _2 => _2.currency]))), () => ( "USD")),
207
+ precision: _nullishCoalesce(_nullishCoalesce(opts.precision, () => ( _optionalChain([siteFormatting, 'optionalAccess', _3 => _3.precision]))), () => ( 2)),
208
+ zeroLabel: _nullishCoalesce(opts.zeroLabel, () => ( _optionalChain([siteFormatting, 'optionalAccess', _4 => _4.zeroLabel])))
209
+ };
210
+ }
211
+ function useFormatPrice(optionsOrLocale, legacyCurrency) {
212
+ const site = useAugurSite();
213
+ const opts = normaliseOptions(optionsOrLocale, legacyCurrency);
214
+ const { locale, currency, precision: basePrecision, zeroLabel } = resolveFormatting(opts, _optionalChain([site, 'optionalAccess', _5 => _5.formatting]));
215
+ const formatPrice = (price, callOptions) => {
216
+ const effectiveValue = price * (_nullishCoalesce(_optionalChain([callOptions, 'optionalAccess', _6 => _6.quantity]), () => ( 1)));
217
+ if (effectiveValue === 0 && zeroLabel !== void 0) {
218
+ return zeroLabel;
219
+ }
220
+ const precision = _nullishCoalesce(_optionalChain([callOptions, 'optionalAccess', _7 => _7.precision]), () => ( basePrecision));
192
221
  return new Intl.NumberFormat(locale, {
193
222
  style: "currency",
194
223
  currency,
195
- minimumFractionDigits: 2
196
- }).format(price);
224
+ minimumFractionDigits: precision,
225
+ maximumFractionDigits: precision
226
+ }).format(effectiveValue);
197
227
  };
198
228
  return { formatPrice };
199
229
  }
@@ -207,9 +237,10 @@ function useItemPrice(itemId, customerId, quantity = 1, options = {}) {
207
237
  const callbacks = useAugurCallbacks();
208
238
  const auth = useAugurAuth();
209
239
  const cache = useAugurCache();
210
- const effectiveCustomerId = _nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _ => _.customerId])));
211
- const defaultOptions = _chunkC7JC34SMcjs.getItemPriceOptions.call(void 0, api, itemId, effectiveCustomerId, quantity, cache);
212
- const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (_optionalChain([callbacks, 'optionalAccess', _2 => _2.getItemPrice]) ? () => callbacks.getItemPrice(itemId, effectiveCustomerId, quantity) : void 0)));
240
+ const site = useAugurSite();
241
+ const effectiveCustomerId = _nullishCoalesce(_nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _8 => _8.customerId]))), () => ( _optionalChain([site, 'optionalAccess', _9 => _9.defaults, 'optionalAccess', _10 => _10.customerId])));
242
+ const defaultOptions = _chunkDYM6U3QOcjs.getItemPriceOptions.call(void 0, api, itemId, effectiveCustomerId, quantity, cache);
243
+ const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (_optionalChain([callbacks, 'optionalAccess', _11 => _11.getItemPrice]) ? () => callbacks.getItemPrice(itemId, effectiveCustomerId, quantity) : void 0)));
213
244
  const query = _reactquery.useQuery.call(void 0, {
214
245
  ...defaultOptions,
215
246
  ...resolvedQueryFn ? { queryFn: resolvedQueryFn } : {},
@@ -229,7 +260,7 @@ function useInvMastDoc(invMastUid, itemId, options = {}) {
229
260
  const api = useAugurApiOptional();
230
261
  const callbacks = useAugurCallbacks();
231
262
  const cache = useAugurCache();
232
- const queryOpts = _chunkC7JC34SMcjs.getInvMastDocOptions.call(void 0,
263
+ const queryOpts = _chunkDYM6U3QOcjs.getInvMastDocOptions.call(void 0,
233
264
  api,
234
265
  invMastUid,
235
266
  itemId,
@@ -238,7 +269,7 @@ function useInvMastDoc(invMastUid, itemId, options = {}) {
238
269
  );
239
270
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
240
271
  ...queryOpts,
241
- ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _3 => _3.getInvMastDoc]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getInvMastDoc(invMastUid, itemId, _nullishCoalesce(options.includePricing, () => ( "N")))))) } : {},
272
+ ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _12 => _12.getInvMastDoc]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getInvMastDoc(invMastUid, itemId, _nullishCoalesce(options.includePricing, () => ( "N")))))) } : {},
242
273
  enabled: _nullishCoalesce(options.enabled, () => ( true)),
243
274
  initialData: options.initialData
244
275
  });
@@ -251,7 +282,7 @@ function useItemCategory(itemCategoryUid, options = {}) {
251
282
  const api = useAugurApiOptional();
252
283
  const callbacks = useAugurCallbacks();
253
284
  const cache = useAugurCache();
254
- const queryOpts = _chunkC7JC34SMcjs.getItemCategoryOptions.call(void 0,
285
+ const queryOpts = _chunkDYM6U3QOcjs.getItemCategoryOptions.call(void 0,
255
286
  api,
256
287
  itemCategoryUid,
257
288
  options.apiOptions,
@@ -259,7 +290,7 @@ function useItemCategory(itemCategoryUid, options = {}) {
259
290
  );
260
291
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
261
292
  ...queryOpts,
262
- ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _4 => _4.getItemCategory]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getItemCategory(itemCategoryUid, options.apiOptions)))) } : {},
293
+ ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _13 => _13.getItemCategory]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getItemCategory(itemCategoryUid, options.apiOptions)))) } : {},
263
294
  enabled: _nullishCoalesce(options.enabled, () => ( true))
264
295
  });
265
296
  return { category: data, isLoading, error };
@@ -271,10 +302,10 @@ function useInvMast(invMastUid, itemId, options = {}) {
271
302
  const api = useAugurApiOptional();
272
303
  const callbacks = useAugurCallbacks();
273
304
  const cache = useAugurCache();
274
- const queryOpts = _chunkC7JC34SMcjs.getInvMastOptions.call(void 0, api, invMastUid, itemId, cache);
305
+ const queryOpts = _chunkDYM6U3QOcjs.getInvMastOptions.call(void 0, api, invMastUid, itemId, cache);
275
306
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
276
307
  ...queryOpts,
277
- ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _5 => _5.getInvMast]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getInvMast(invMastUid, itemId)))) } : {},
308
+ ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _14 => _14.getInvMast]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getInvMast(invMastUid, itemId)))) } : {},
278
309
  enabled: _nullishCoalesce(options.enabled, () => ( true))
279
310
  });
280
311
  return { item: data, isLoading, error };
@@ -286,10 +317,10 @@ function useInvMastStock(invMastUid, options = {}) {
286
317
  const api = useAugurApiOptional();
287
318
  const callbacks = useAugurCallbacks();
288
319
  const cache = useAugurCache();
289
- const queryOpts = _chunkC7JC34SMcjs.getInvMastStockOptions.call(void 0, api, invMastUid, cache);
320
+ const queryOpts = _chunkDYM6U3QOcjs.getInvMastStockOptions.call(void 0, api, invMastUid, cache);
290
321
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
291
322
  ...queryOpts,
292
- ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _6 => _6.getInvMastStock]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getInvMastStock(invMastUid)))) } : {},
323
+ ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _15 => _15.getInvMastStock]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getInvMastStock(invMastUid)))) } : {},
293
324
  enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!invMastUid,
294
325
  retry: 3,
295
326
  /* v8 ignore start */
@@ -303,6 +334,43 @@ function useInvMastStock(invMastUid, options = {}) {
303
334
  };
304
335
  }
305
336
 
337
+ // src/hooks/use-stock.ts
338
+
339
+
340
+
341
+ function useStock(invMastUid, options = {}) {
342
+ const api = useAugurApiOptional();
343
+ const callbacks = useAugurCallbacks();
344
+ const cache = useAugurCache();
345
+ const queryOpts = _chunkDYM6U3QOcjs.getStockOptions.call(void 0, api, invMastUid, cache);
346
+ const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (_optionalChain([callbacks, 'optionalAccess', _16 => _16.getStock]) ? () => callbacks.getStock(invMastUid) : void 0)));
347
+ const query = _reactquery.useQuery.call(void 0, {
348
+ ...queryOpts,
349
+ ...resolvedQueryFn ? { queryFn: resolvedQueryFn } : {},
350
+ enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!invMastUid,
351
+ retry: 3,
352
+ /* v8 ignore start */
353
+ retryDelay: (attemptIndex) => Math.min(1e3 * 2 ** attemptIndex, 1e4)
354
+ /* v8 ignore stop */
355
+ });
356
+ const resolved = _react.useMemo.call(void 0,
357
+ () => _augurutils.resolveStock.call(void 0, {
358
+ stock: _nullishCoalesce(query.data, () => ( null)),
359
+ companyKey: options.companyKey,
360
+ round: options.round,
361
+ lowStockThreshold: options.lowStockThreshold,
362
+ showQuantity: options.showQuantity
363
+ }),
364
+ [query.data, options.companyKey, options.round, options.lowStockThreshold, options.showQuantity]
365
+ );
366
+ return {
367
+ stock: _nullishCoalesce(query.data, () => ( null)),
368
+ resolved,
369
+ loading: query.isLoading,
370
+ error: query.error
371
+ };
372
+ }
373
+
306
374
  // src/hooks/use-batch-inv-mast-doc.ts
307
375
 
308
376
  function useBatchInvMastDoc(params, options = {}) {
@@ -311,26 +379,26 @@ function useBatchInvMastDoc(params, options = {}) {
311
379
  const cache = useAugurCache();
312
380
  const queryClient = _reactquery.useQueryClient.call(void 0, );
313
381
  const includePricing = _nullishCoalesce(options.includePricing, () => ( "N"));
314
- const batchOpts = _chunkC7JC34SMcjs.getBatchInvMastDocOptions.call(void 0, api, params, includePricing, cache);
382
+ const batchOpts = _chunkDYM6U3QOcjs.getBatchInvMastDocOptions.call(void 0, api, params, includePricing, cache);
315
383
  const resolveFetchItems = (uncached) => {
316
384
  if (options.queryFn) {
317
385
  return options.queryFn(uncached, includePricing);
318
386
  }
319
- if (_optionalChain([callbacks, 'optionalAccess', _7 => _7.batchGetInvMastDocs])) {
387
+ if (_optionalChain([callbacks, 'optionalAccess', _17 => _17.batchGetInvMastDocs])) {
320
388
  return callbacks.batchGetInvMastDocs(uncached, includePricing);
321
389
  }
322
- const fallbackOpts = _chunkC7JC34SMcjs.getBatchInvMastDocOptions.call(void 0, api, uncached, includePricing, cache);
390
+ const fallbackOpts = _chunkDYM6U3QOcjs.getBatchInvMastDocOptions.call(void 0, api, uncached, includePricing, cache);
323
391
  return fallbackOpts.queryFn();
324
392
  };
325
393
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
326
394
  queryKey: batchOpts.queryKey,
327
- queryFn: () => _chunkC7JC34SMcjs.executeBatchQuery.call(void 0, {
395
+ queryFn: () => _chunkDYM6U3QOcjs.executeBatchQuery.call(void 0, {
328
396
  params,
329
397
  queryClient,
330
- getItemKey: (p) => _chunkC7JC34SMcjs.getInvMastDocKey.call(void 0, p.invMastUid, p.itemId, includePricing),
398
+ getItemKey: (p) => _chunkDYM6U3QOcjs.getInvMastDocKey.call(void 0, p.invMastUid, p.itemId, includePricing),
331
399
  getResultKey: (p) => p.itemId.toUpperCase(),
332
400
  fetchItems: resolveFetchItems,
333
- getSeedKey: (_key, doc) => _chunkC7JC34SMcjs.getInvMastDocKey.call(void 0, doc.invMastUid, doc.itemId, includePricing)
401
+ getSeedKey: (_key, doc) => _chunkDYM6U3QOcjs.getInvMastDocKey.call(void 0, doc.invMastUid, doc.itemId, includePricing)
334
402
  }),
335
403
  staleTime: batchOpts.staleTime,
336
404
  gcTime: batchOpts.gcTime,
@@ -343,22 +411,22 @@ function useBatchInvMastDoc(params, options = {}) {
343
411
 
344
412
  function resolveData(data) {
345
413
  return {
346
- childrenTotal: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _8 => _8.childrenTotal]), () => ( 0)),
347
- itemCategoryDesc: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _9 => _9.itemCategoryDesc]), () => ( "")),
348
- productCategories: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _10 => _10.children]), () => ( null)),
349
- productCategoryImage: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _11 => _11.categoryImage]), () => ( null))
414
+ childrenTotal: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _18 => _18.childrenTotal]), () => ( 0)),
415
+ itemCategoryDesc: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _19 => _19.itemCategoryDesc]), () => ( "")),
416
+ productCategories: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _20 => _20.children]), () => ( null)),
417
+ productCategoryImage: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _21 => _21.categoryImage]), () => ( null))
350
418
  };
351
419
  }
352
420
  function useProductCategory(itemCategoryUid, options = {}) {
353
421
  const api = useAugurApiOptional();
354
422
  const callbacks = useAugurCallbacks();
355
423
  const cache = useAugurCache();
356
- const baseOptions = itemCategoryUid ? _chunkC7JC34SMcjs.getProductCategoryOptions.call(void 0, api, itemCategoryUid, cache) : {
357
- queryKey: _chunkC7JC34SMcjs.getProductCategoryKey.call(void 0, null),
424
+ const baseOptions = itemCategoryUid ? _chunkDYM6U3QOcjs.getProductCategoryOptions.call(void 0, api, itemCategoryUid, cache) : {
425
+ queryKey: _chunkDYM6U3QOcjs.getProductCategoryKey.call(void 0, null),
358
426
  /* v8 ignore next */
359
427
  queryFn: () => Promise.reject()
360
428
  };
361
- const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (_optionalChain([callbacks, 'optionalAccess', _12 => _12.getProductCategory]) ? () => callbacks.getProductCategory(itemCategoryUid) : void 0)));
429
+ const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (_optionalChain([callbacks, 'optionalAccess', _22 => _22.getProductCategory]) ? () => callbacks.getProductCategory(itemCategoryUid) : void 0)));
362
430
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
363
431
  ...baseOptions,
364
432
  ...resolvedQueryFn ? { queryFn: resolvedQueryFn } : {},
@@ -382,19 +450,19 @@ function useItemDetails(itemId, options = {}) {
382
450
  const callbacks = useAugurCallbacks();
383
451
  const cache = useAugurCache();
384
452
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
385
- ...itemId ? _chunkC7JC34SMcjs.getItemDetailsOptions.call(void 0, api, itemId, cache) : {
386
- queryKey: _chunkC7JC34SMcjs.getItemDetailsKey.call(void 0, ""),
453
+ ...itemId ? _chunkDYM6U3QOcjs.getItemDetailsOptions.call(void 0, api, itemId, cache) : {
454
+ queryKey: _chunkDYM6U3QOcjs.getItemDetailsKey.call(void 0, ""),
387
455
  /* v8 ignore next */
388
456
  queryFn: () => Promise.reject()
389
457
  },
390
- ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _13 => _13.getItemDetails]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getItemDetails(itemId)))) } : {},
458
+ ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _23 => _23.getItemDetails]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getItemDetails(itemId)))) } : {},
391
459
  enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!itemId,
392
460
  retry: 3,
393
461
  /* v8 ignore start */
394
462
  retryDelay: (attemptIndex) => Math.min(1e3 * 2 ** attemptIndex, 1e4)
395
463
  /* v8 ignore stop */
396
464
  });
397
- const categoryList = _nullishCoalesce(_optionalChain([data, 'optionalAccess', _14 => _14.categoryList]), () => ( []));
465
+ const categoryList = _nullishCoalesce(_optionalChain([data, 'optionalAccess', _24 => _24.categoryList]), () => ( []));
398
466
  return {
399
467
  itemCategoryUid: categoryList.length > 0 ? categoryList[categoryList.length - 1] : null,
400
468
  itemDetails: _nullishCoalesce(data, () => ( null)),
@@ -410,12 +478,12 @@ function useItemAttributes(itemCategoryUid, options = {}) {
410
478
  const callbacks = useAugurCallbacks();
411
479
  const cache = useAugurCache();
412
480
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
413
- ...itemCategoryUid ? _chunkC7JC34SMcjs.getItemAttributesOptions.call(void 0, api, itemCategoryUid, cache) : {
414
- queryKey: _chunkC7JC34SMcjs.getItemAttributesKey.call(void 0, null),
481
+ ...itemCategoryUid ? _chunkDYM6U3QOcjs.getItemAttributesOptions.call(void 0, api, itemCategoryUid, cache) : {
482
+ queryKey: _chunkDYM6U3QOcjs.getItemAttributesKey.call(void 0, null),
415
483
  /* v8 ignore next */
416
484
  queryFn: () => Promise.reject()
417
485
  },
418
- ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _15 => _15.getItemAttributes]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getItemAttributes(itemCategoryUid)))) } : {},
486
+ ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _25 => _25.getItemAttributes]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getItemAttributes(itemCategoryUid)))) } : {},
419
487
  enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!itemCategoryUid,
420
488
  retry: 3,
421
489
  /* v8 ignore start */
@@ -423,7 +491,7 @@ function useItemAttributes(itemCategoryUid, options = {}) {
423
491
  /* v8 ignore stop */
424
492
  });
425
493
  return {
426
- attributes: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _16 => _16.attributes]), () => ( null)),
494
+ attributes: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _26 => _26.attributes]), () => ( null)),
427
495
  loading: isLoading,
428
496
  error
429
497
  };
@@ -435,18 +503,18 @@ function useProductSearch(pageData, options = {}) {
435
503
  const api = useAugurApiOptional();
436
504
  const callbacks = useAugurCallbacks();
437
505
  const cache = useAugurCache();
438
- const defaultOptions = _chunkC7JC34SMcjs.getProductSearchOptions.call(void 0, api, pageData, cache);
506
+ const defaultOptions = _chunkDYM6U3QOcjs.getProductSearchOptions.call(void 0, api, pageData, cache);
439
507
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
440
508
  ...defaultOptions,
441
- ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _17 => _17.getProductSearch]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getProductSearch(pageData)))) } : {},
509
+ ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _27 => _27.getProductSearch]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getProductSearch(pageData)))) } : {},
442
510
  retry: 3,
443
511
  /* v8 ignore start */
444
512
  retryDelay: (attemptIndex) => Math.min(1e3 * 2 ** attemptIndex, 1e4)
445
513
  /* v8 ignore stop */
446
514
  });
447
515
  return {
448
- productItems: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _18 => _18.items]), () => ( null)),
449
- total: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _19 => _19.totalResults]), () => ( 0)),
516
+ productItems: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _28 => _28.items]), () => ( null)),
517
+ total: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _29 => _29.totalResults]), () => ( 0)),
450
518
  loading: isLoading,
451
519
  error
452
520
  };
@@ -461,15 +529,15 @@ function useSearchSuggestions(query, options = {}) {
461
529
  const limit = _nullishCoalesce(options.limit, () => ( 10));
462
530
  const offset = _nullishCoalesce(options.offset, () => ( 0));
463
531
  const enabled = (_nullishCoalesce(options.enabled, () => ( true))) && query.trim().length > 0;
464
- const defaultOptions = _chunkC7JC34SMcjs.getSearchSuggestionsOptions.call(void 0, api, query, limit, offset, cache);
532
+ const defaultOptions = _chunkDYM6U3QOcjs.getSearchSuggestionsOptions.call(void 0, api, query, limit, offset, cache);
465
533
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
466
534
  ...defaultOptions,
467
- ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _20 => _20.getSearchSuggestions]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getSearchSuggestions(query, limit, offset)))) } : {},
535
+ ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _30 => _30.getSearchSuggestions]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getSearchSuggestions(query, limit, offset)))) } : {},
468
536
  enabled
469
537
  });
470
538
  return {
471
- suggestions: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _21 => _21.data]), () => ( [])),
472
- total: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _22 => _22.total]), () => ( 0)),
539
+ suggestions: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _31 => _31.data]), () => ( [])),
540
+ total: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _32 => _32.total]), () => ( 0)),
473
541
  isLoading,
474
542
  error
475
543
  };
@@ -536,17 +604,17 @@ function useCartActions(callbacks) {
536
604
  ]);
537
605
  if (!success) throw new Error("Failed to add item to cart");
538
606
  invalidateCartCache();
539
- if (showToast && _optionalChain([notify, 'optionalAccess', _23 => _23.info])) {
607
+ if (showToast && _optionalChain([notify, 'optionalAccess', _33 => _33.info])) {
540
608
  notify.info(`${item.quantity} x ${itemId || "Item"} added to cart`);
541
609
  }
542
- _optionalChain([onSuccess, 'optionalCall', _24 => _24()]);
610
+ _optionalChain([onSuccess, 'optionalCall', _34 => _34()]);
543
611
  return true;
544
612
  } catch (error) {
545
613
  setCartLines(previousCartLines);
546
- if (showToast && _optionalChain([notify, 'optionalAccess', _25 => _25.error])) {
614
+ if (showToast && _optionalChain([notify, 'optionalAccess', _35 => _35.error])) {
547
615
  notify.error("Failed to add item to cart. Please try again.");
548
616
  }
549
- _optionalChain([onError, 'optionalCall', _26 => _26(error)]);
617
+ _optionalChain([onError, 'optionalCall', _36 => _36(error)]);
550
618
  return false;
551
619
  }
552
620
  },
@@ -565,14 +633,14 @@ function useCartActions(callbacks) {
565
633
  const success = await callbacks.updateCartLines(uid, updatedLines);
566
634
  if (!success) throw new Error("Failed to update quantity");
567
635
  invalidateCartCache();
568
- _optionalChain([onSuccess, 'optionalCall', _27 => _27()]);
636
+ _optionalChain([onSuccess, 'optionalCall', _37 => _37()]);
569
637
  return true;
570
638
  } catch (error) {
571
639
  setCartLines(previousCartLines);
572
- if (showToast && _optionalChain([notify, 'optionalAccess', _28 => _28.error])) {
640
+ if (showToast && _optionalChain([notify, 'optionalAccess', _38 => _38.error])) {
573
641
  notify.error("Failed to update quantity. Please try again.");
574
642
  }
575
- _optionalChain([onError, 'optionalCall', _29 => _29(error)]);
643
+ _optionalChain([onError, 'optionalCall', _39 => _39(error)]);
576
644
  return false;
577
645
  }
578
646
  },
@@ -591,17 +659,17 @@ function useCartActions(callbacks) {
591
659
  const success = await callbacks.updateCartLines(uid, zeroedLines);
592
660
  if (!success) throw new Error("Failed to remove item");
593
661
  invalidateCartCache();
594
- if (showToast && _optionalChain([notify, 'optionalAccess', _30 => _30.info])) {
662
+ if (showToast && _optionalChain([notify, 'optionalAccess', _40 => _40.info])) {
595
663
  notify.info(`${itemId || "Item"} removed from cart`);
596
664
  }
597
- _optionalChain([onSuccess, 'optionalCall', _31 => _31()]);
665
+ _optionalChain([onSuccess, 'optionalCall', _41 => _41()]);
598
666
  return true;
599
667
  } catch (error) {
600
668
  setCartLines(previousCartLines);
601
- if (showToast && _optionalChain([notify, 'optionalAccess', _32 => _32.error])) {
669
+ if (showToast && _optionalChain([notify, 'optionalAccess', _42 => _42.error])) {
602
670
  notify.error("Failed to remove item. Please try again.");
603
671
  }
604
- _optionalChain([onError, 'optionalCall', _33 => _33(error)]);
672
+ _optionalChain([onError, 'optionalCall', _43 => _43(error)]);
605
673
  return false;
606
674
  }
607
675
  },
@@ -617,17 +685,17 @@ function useCartActions(callbacks) {
617
685
  const success = await callbacks.deleteItemsFromCart(uid);
618
686
  if (!success) throw new Error("Failed to clear cart");
619
687
  invalidateCartCache();
620
- if (showToast && _optionalChain([notify, 'optionalAccess', _34 => _34.info])) {
688
+ if (showToast && _optionalChain([notify, 'optionalAccess', _44 => _44.info])) {
621
689
  notify.info("Cart cleared");
622
690
  }
623
- _optionalChain([onSuccess, 'optionalCall', _35 => _35()]);
691
+ _optionalChain([onSuccess, 'optionalCall', _45 => _45()]);
624
692
  return true;
625
693
  } catch (error) {
626
694
  setCartLines(previousCartLines);
627
- if (showToast && _optionalChain([notify, 'optionalAccess', _36 => _36.error])) {
695
+ if (showToast && _optionalChain([notify, 'optionalAccess', _46 => _46.error])) {
628
696
  notify.error("Failed to clear cart. Please try again.");
629
697
  }
630
- _optionalChain([onError, 'optionalCall', _37 => _37(error)]);
698
+ _optionalChain([onError, 'optionalCall', _47 => _47(error)]);
631
699
  return false;
632
700
  }
633
701
  },
@@ -641,7 +709,7 @@ function useCartActions(callbacks) {
641
709
  );
642
710
  const getItemQuantity = _react.useCallback.call(void 0,
643
711
  (invMastUid) => {
644
- return _nullishCoalesce(_optionalChain([cartLines, 'access', _38 => _38.find, 'call', _39 => _39((line) => line.invMastUid === invMastUid), 'optionalAccess', _40 => _40.quantity]), () => ( 0));
712
+ return _nullishCoalesce(_optionalChain([cartLines, 'access', _48 => _48.find, 'call', _49 => _49((line) => line.invMastUid === invMastUid), 'optionalAccess', _50 => _50.quantity]), () => ( 0));
645
713
  },
646
714
  [cartLines]
647
715
  );
@@ -671,8 +739,8 @@ function useCartInitialization(session, callbacks) {
671
739
  const clearCart = useClearCart();
672
740
  const queryClient = _reactquery.useQueryClient.call(void 0, );
673
741
  const effectiveStatus = session.status;
674
- const effectiveUserId = _nullishCoalesce(session.userId, () => ( _optionalChain([auth, 'optionalAccess', _41 => _41.userId])));
675
- const effectiveCartHdrUid = _nullishCoalesce(session.cartHdrUid, () => ( _optionalChain([auth, 'optionalAccess', _42 => _42.cartHdrUid])));
742
+ const effectiveUserId = _nullishCoalesce(session.userId, () => ( _optionalChain([auth, 'optionalAccess', _51 => _51.userId])));
743
+ const effectiveCartHdrUid = _nullishCoalesce(session.cartHdrUid, () => ( _optionalChain([auth, 'optionalAccess', _52 => _52.cartHdrUid])));
676
744
  const effectiveSession = _react.useMemo.call(void 0,
677
745
  () => ({ status: effectiveStatus, userId: effectiveUserId, cartHdrUid: effectiveCartHdrUid }),
678
746
  [effectiveStatus, effectiveUserId, effectiveCartHdrUid]
@@ -767,18 +835,19 @@ function useCartPricing(options = {}) {
767
835
  const callbacks = useAugurCallbacks();
768
836
  const auth = useAugurAuth();
769
837
  const cache = useAugurCache();
838
+ const site = useAugurSite();
770
839
  const cartLines = useCartLines();
771
- const customerId = _nullishCoalesce(options.customerId, () => ( _optionalChain([auth, 'optionalAccess', _43 => _43.customerId])));
772
- const priceFn = _nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _44 => _44.getItemPrice])));
840
+ const customerId = _nullishCoalesce(_nullishCoalesce(options.customerId, () => ( _optionalChain([auth, 'optionalAccess', _53 => _53.customerId]))), () => ( _optionalChain([site, 'optionalAccess', _54 => _54.defaults, 'optionalAccess', _55 => _55.customerId])));
841
+ const priceFn = _nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _56 => _56.getItemPrice])));
773
842
  const priceQueries = _reactquery.useQueries.call(void 0, {
774
843
  queries: cartLines.map((line) => {
775
844
  const base = priceFn ? {
776
- queryKey: _chunkC7JC34SMcjs.getItemPriceKey.call(void 0, line.itemId, customerId, line.quantity),
845
+ queryKey: _chunkDYM6U3QOcjs.getItemPriceKey.call(void 0, line.itemId, customerId, line.quantity),
777
846
  queryFn: () => priceFn(line.itemId, customerId, line.quantity),
778
847
  refetchOnReconnect: true,
779
848
  refetchOnWindowFocus: false,
780
849
  meta: { persist: true }
781
- } : _chunkC7JC34SMcjs.getItemPriceOptions.call(void 0, api, line.itemId, customerId, line.quantity, cache);
850
+ } : _chunkDYM6U3QOcjs.getItemPriceOptions.call(void 0, api, line.itemId, customerId, line.quantity, cache);
782
851
  return {
783
852
  ...base,
784
853
  enabled: !!customerId && !!line.itemId
@@ -789,7 +858,7 @@ function useCartPricing(options = {}) {
789
858
  const map = {};
790
859
  cartLines.forEach((line, index) => {
791
860
  const queryResult = priceQueries[index];
792
- if (_optionalChain([queryResult, 'optionalAccess', _45 => _45.data])) {
861
+ if (_optionalChain([queryResult, 'optionalAccess', _57 => _57.data])) {
793
862
  const derived = _augurutils.derivePrice.call(void 0, { priceData: queryResult.data, quantity: line.quantity });
794
863
  map[line.itemId.toUpperCase()] = {
795
864
  unitPrice: derived.unitPrice,
@@ -801,7 +870,7 @@ function useCartPricing(options = {}) {
801
870
  }, [cartLines, priceQueries]);
802
871
  const getUnitPrice = _react.useMemo.call(void 0, () => {
803
872
  return (itemId) => {
804
- return _nullishCoalesce(_optionalChain([prices, 'access', _46 => _46[_optionalChain([itemId, 'optionalAccess', _47 => _47.toUpperCase, 'call', _48 => _48()])], 'optionalAccess', _49 => _49.unitPrice]), () => ( 0));
873
+ return _nullishCoalesce(_optionalChain([prices, 'access', _58 => _58[_optionalChain([itemId, 'optionalAccess', _59 => _59.toUpperCase, 'call', _60 => _60()])], 'optionalAccess', _61 => _61.unitPrice]), () => ( 0));
805
874
  };
806
875
  }, [prices]);
807
876
  const getItemTotal = _react.useMemo.call(void 0, () => {
@@ -811,7 +880,7 @@ function useCartPricing(options = {}) {
811
880
  }, [getUnitPrice]);
812
881
  const subtotal = _react.useMemo.call(void 0, () => {
813
882
  return cartLines.reduce((sum, line) => {
814
- const unitPrice = _nullishCoalesce(_optionalChain([prices, 'access', _50 => _50[line.itemId.toUpperCase()], 'optionalAccess', _51 => _51.unitPrice]), () => ( 0));
883
+ const unitPrice = _nullishCoalesce(_optionalChain([prices, 'access', _62 => _62[line.itemId.toUpperCase()], 'optionalAccess', _63 => _63.unitPrice]), () => ( 0));
815
884
  return sum + unitPrice * line.quantity;
816
885
  }, 0);
817
886
  }, [cartLines, prices]);
@@ -879,13 +948,13 @@ function useCategoryItemsInfinite(itemCategoryUid, itemsFilters, options = {}) {
879
948
  const callbacks = useAugurCallbacks();
880
949
  const cache = useAugurCache();
881
950
  const { enabled = true } = options;
882
- const defaultOptions = _chunkC7JC34SMcjs.getCategoryItemsInfiniteOptions.call(void 0,
951
+ const defaultOptions = _chunkDYM6U3QOcjs.getCategoryItemsInfiniteOptions.call(void 0,
883
952
  api,
884
953
  itemCategoryUid,
885
954
  itemsFilters,
886
955
  cache
887
956
  );
888
- const cb = _optionalChain([callbacks, 'optionalAccess', _52 => _52.getCategoryItemsInfinite]);
957
+ const cb = _optionalChain([callbacks, 'optionalAccess', _64 => _64.getCategoryItemsInfinite]);
889
958
  const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (cb ? ({ pageParam }) => cb({
890
959
  itemCategoryUid,
891
960
  itemsFilters,
@@ -906,13 +975,13 @@ function useItemSearchInfinite(itemsFilters, itemCategoryUid, options = {}) {
906
975
  const callbacks = useAugurCallbacks();
907
976
  const cache = useAugurCache();
908
977
  const { enabled = true } = options;
909
- const defaultOptions = _chunkC7JC34SMcjs.getItemSearchInfiniteOptions.call(void 0,
978
+ const defaultOptions = _chunkDYM6U3QOcjs.getItemSearchInfiniteOptions.call(void 0,
910
979
  api,
911
980
  itemsFilters,
912
981
  itemCategoryUid,
913
982
  cache
914
983
  );
915
- const cb = _optionalChain([callbacks, 'optionalAccess', _53 => _53.getItemSearchInfinite]);
984
+ const cb = _optionalChain([callbacks, 'optionalAccess', _65 => _65.getItemSearchInfinite]);
916
985
  const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (cb ? ({ pageParam }) => cb({
917
986
  itemsFilters,
918
987
  itemCategoryUid,
@@ -933,12 +1002,12 @@ function useJoomlaContent(articleId, options = {}) {
933
1002
  const callbacks = useAugurCallbacks();
934
1003
  const cache = useAugurCache();
935
1004
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
936
- ...articleId ? _chunkC7JC34SMcjs.getJoomlaContentOptions.call(void 0, api, articleId, cache) : {
937
- queryKey: _chunkC7JC34SMcjs.getJoomlaContentKey.call(void 0, ""),
1005
+ ...articleId ? _chunkDYM6U3QOcjs.getJoomlaContentOptions.call(void 0, api, articleId, cache) : {
1006
+ queryKey: _chunkDYM6U3QOcjs.getJoomlaContentKey.call(void 0, ""),
938
1007
  /* v8 ignore next */
939
1008
  queryFn: () => Promise.reject()
940
1009
  },
941
- ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _54 => _54.getJoomlaContent]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getJoomlaContent(articleId)))) } : {},
1010
+ ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _66 => _66.getJoomlaContent]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getJoomlaContent(articleId)))) } : {},
942
1011
  enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!articleId
943
1012
  });
944
1013
  return {
@@ -955,12 +1024,12 @@ function useJoomlaContentList(categoryId, options = {}) {
955
1024
  const callbacks = useAugurCallbacks();
956
1025
  const cache = useAugurCache();
957
1026
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
958
- ...categoryId ? _chunkC7JC34SMcjs.getJoomlaContentListOptions.call(void 0, api, categoryId, options.filters, cache) : {
959
- queryKey: _chunkC7JC34SMcjs.getJoomlaContentListKey.call(void 0, ""),
1027
+ ...categoryId ? _chunkDYM6U3QOcjs.getJoomlaContentListOptions.call(void 0, api, categoryId, options.filters, cache) : {
1028
+ queryKey: _chunkDYM6U3QOcjs.getJoomlaContentListKey.call(void 0, ""),
960
1029
  /* v8 ignore next */
961
1030
  queryFn: () => Promise.reject()
962
1031
  },
963
- ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _55 => _55.getJoomlaContentList]))) ? {
1032
+ ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _67 => _67.getJoomlaContentList]))) ? {
964
1033
  queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getJoomlaContentList(categoryId, options.filters))))
965
1034
  } : {},
966
1035
  enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!categoryId
@@ -979,8 +1048,8 @@ function useJoomlaMenu(options = {}) {
979
1048
  const callbacks = useAugurCallbacks();
980
1049
  const cache = useAugurCache();
981
1050
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
982
- ..._chunkC7JC34SMcjs.getJoomlaMenuOptions.call(void 0, api, options.filters, cache),
983
- ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _56 => _56.getJoomlaMenu]))) ? {
1051
+ ..._chunkDYM6U3QOcjs.getJoomlaMenuOptions.call(void 0, api, options.filters, cache),
1052
+ ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _68 => _68.getJoomlaMenu]))) ? {
984
1053
  queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getJoomlaMenu(options.filters))))
985
1054
  } : {},
986
1055
  enabled: _nullishCoalesce(options.enabled, () => ( true))
@@ -999,12 +1068,12 @@ function useJoomlaMenuDoc(menuId, options = {}) {
999
1068
  const callbacks = useAugurCallbacks();
1000
1069
  const cache = useAugurCache();
1001
1070
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
1002
- ...menuId ? _chunkC7JC34SMcjs.getJoomlaMenuDocOptions.call(void 0, api, menuId, cache) : {
1003
- queryKey: _chunkC7JC34SMcjs.getJoomlaMenuDocKey.call(void 0, ""),
1071
+ ...menuId ? _chunkDYM6U3QOcjs.getJoomlaMenuDocOptions.call(void 0, api, menuId, cache) : {
1072
+ queryKey: _chunkDYM6U3QOcjs.getJoomlaMenuDocKey.call(void 0, ""),
1004
1073
  /* v8 ignore next */
1005
1074
  queryFn: () => Promise.reject()
1006
1075
  },
1007
- ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _57 => _57.getJoomlaMenuDoc]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getJoomlaMenuDoc(menuId)))) } : {},
1076
+ ..._nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _69 => _69.getJoomlaMenuDoc]))) ? { queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getJoomlaMenuDoc(menuId)))) } : {},
1008
1077
  enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!menuId
1009
1078
  });
1010
1079
  return {
@@ -1016,18 +1085,23 @@ function useJoomlaMenuDoc(menuId, options = {}) {
1016
1085
 
1017
1086
  // src/hooks/use-customer-orders.ts
1018
1087
 
1088
+ var EMPTY_LIST = { data: [], total: 0 };
1019
1089
  function useCustomerOrders(customerId, params, options = {}) {
1020
1090
  const callbacks = useAugurCallbacks();
1021
1091
  const auth = useAugurAuth();
1022
- const effectiveCustomerId = _nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _58 => _58.customerId])));
1092
+ const site = useAugurSite();
1093
+ const effectiveCustomerId = _nullishCoalesce(_nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _70 => _70.customerId]))), () => ( _optionalChain([site, 'optionalAccess', _71 => _71.defaults, 'optionalAccess', _72 => _72.customerId])));
1094
+ const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (_optionalChain([callbacks, 'optionalAccess', _73 => _73.getCustomerOrders]) ? () => callbacks.getCustomerOrders(effectiveCustomerId, params) : void 0)));
1095
+ const enabled = (_nullishCoalesce(options.enabled, () => ( true))) && !!effectiveCustomerId && !!resolvedQueryFn;
1023
1096
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
1024
- queryKey: _chunkC7JC34SMcjs.getCustomerOrdersKey.call(void 0, effectiveCustomerId, params),
1025
- queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getCustomerOrders(effectiveCustomerId, params)))),
1026
- enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!effectiveCustomerId && !!(_nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _59 => _59.getCustomerOrders]))))
1097
+ queryKey: _chunkDYM6U3QOcjs.getCustomerOrdersKey.call(void 0, effectiveCustomerId, params),
1098
+ queryFn: resolvedQueryFn,
1099
+ enabled
1027
1100
  });
1101
+ const result = data || EMPTY_LIST;
1028
1102
  return {
1029
- orders: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _60 => _60.data]), () => ( [])),
1030
- total: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _61 => _61.total]), () => ( 0)),
1103
+ orders: result.data,
1104
+ total: result.total,
1031
1105
  isLoading,
1032
1106
  error
1033
1107
  };
@@ -1035,14 +1109,17 @@ function useCustomerOrders(customerId, params, options = {}) {
1035
1109
  function useOrderDetail(customerId, orderId, options = {}) {
1036
1110
  const callbacks = useAugurCallbacks();
1037
1111
  const auth = useAugurAuth();
1038
- const effectiveCustomerId = _nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _62 => _62.customerId])));
1112
+ const site = useAugurSite();
1113
+ const effectiveCustomerId = _nullishCoalesce(_nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _74 => _74.customerId]))), () => ( _optionalChain([site, 'optionalAccess', _75 => _75.defaults, 'optionalAccess', _76 => _76.customerId])));
1114
+ const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (_optionalChain([callbacks, 'optionalAccess', _77 => _77.getCustomerOrderDetail]) ? () => callbacks.getCustomerOrderDetail(effectiveCustomerId, orderId) : void 0)));
1115
+ const enabled = (_nullishCoalesce(options.enabled, () => ( true))) && !!effectiveCustomerId && !!orderId && !!resolvedQueryFn;
1039
1116
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
1040
- queryKey: _chunkC7JC34SMcjs.getCustomerOrderDetailKey.call(void 0, effectiveCustomerId, orderId),
1041
- queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getCustomerOrderDetail(effectiveCustomerId, orderId)))),
1042
- enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!effectiveCustomerId && !!orderId && !!(_nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _63 => _63.getCustomerOrderDetail]))))
1117
+ queryKey: _chunkDYM6U3QOcjs.getCustomerOrderDetailKey.call(void 0, effectiveCustomerId, orderId),
1118
+ queryFn: resolvedQueryFn,
1119
+ enabled
1043
1120
  });
1044
1121
  return {
1045
- order: _nullishCoalesce(data, () => ( null)),
1122
+ order: data || null,
1046
1123
  isLoading,
1047
1124
  error
1048
1125
  };
@@ -1050,18 +1127,23 @@ function useOrderDetail(customerId, orderId, options = {}) {
1050
1127
 
1051
1128
  // src/hooks/use-customer-invoices.ts
1052
1129
 
1130
+ var EMPTY_LIST2 = { data: [], total: 0 };
1053
1131
  function useCustomerInvoices(customerId, params, options = {}) {
1054
1132
  const callbacks = useAugurCallbacks();
1055
1133
  const auth = useAugurAuth();
1056
- const effectiveCustomerId = _nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _64 => _64.customerId])));
1134
+ const site = useAugurSite();
1135
+ const effectiveCustomerId = _nullishCoalesce(_nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _78 => _78.customerId]))), () => ( _optionalChain([site, 'optionalAccess', _79 => _79.defaults, 'optionalAccess', _80 => _80.customerId])));
1136
+ const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (_optionalChain([callbacks, 'optionalAccess', _81 => _81.getCustomerInvoices]) ? () => callbacks.getCustomerInvoices(effectiveCustomerId, params) : void 0)));
1137
+ const enabled = (_nullishCoalesce(options.enabled, () => ( true))) && !!effectiveCustomerId && !!resolvedQueryFn;
1057
1138
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
1058
- queryKey: _chunkC7JC34SMcjs.getCustomerInvoicesKey.call(void 0, effectiveCustomerId, params),
1059
- queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getCustomerInvoices(effectiveCustomerId, params)))),
1060
- enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!effectiveCustomerId && !!(_nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _65 => _65.getCustomerInvoices]))))
1139
+ queryKey: _chunkDYM6U3QOcjs.getCustomerInvoicesKey.call(void 0, effectiveCustomerId, params),
1140
+ queryFn: resolvedQueryFn,
1141
+ enabled
1061
1142
  });
1143
+ const result = data || EMPTY_LIST2;
1062
1144
  return {
1063
- invoices: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _66 => _66.data]), () => ( [])),
1064
- total: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _67 => _67.total]), () => ( 0)),
1145
+ invoices: result.data,
1146
+ total: result.total,
1065
1147
  isLoading,
1066
1148
  error
1067
1149
  };
@@ -1069,17 +1151,17 @@ function useCustomerInvoices(customerId, params, options = {}) {
1069
1151
  function useInvoiceDetail(customerId, invoiceNo, options = {}) {
1070
1152
  const callbacks = useAugurCallbacks();
1071
1153
  const auth = useAugurAuth();
1072
- const effectiveCustomerId = _nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _68 => _68.customerId])));
1154
+ const site = useAugurSite();
1155
+ const effectiveCustomerId = _nullishCoalesce(_nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _82 => _82.customerId]))), () => ( _optionalChain([site, 'optionalAccess', _83 => _83.defaults, 'optionalAccess', _84 => _84.customerId])));
1156
+ const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (_optionalChain([callbacks, 'optionalAccess', _85 => _85.getCustomerInvoiceDetail]) ? () => callbacks.getCustomerInvoiceDetail(effectiveCustomerId, invoiceNo) : void 0)));
1157
+ const enabled = (_nullishCoalesce(options.enabled, () => ( true))) && !!effectiveCustomerId && !!invoiceNo && !!resolvedQueryFn;
1073
1158
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
1074
- queryKey: _chunkC7JC34SMcjs.getCustomerInvoiceDetailKey.call(void 0, effectiveCustomerId, invoiceNo),
1075
- queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getCustomerInvoiceDetail(
1076
- effectiveCustomerId,
1077
- invoiceNo
1078
- )))),
1079
- enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!effectiveCustomerId && !!invoiceNo && !!(_nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _69 => _69.getCustomerInvoiceDetail]))))
1159
+ queryKey: _chunkDYM6U3QOcjs.getCustomerInvoiceDetailKey.call(void 0, effectiveCustomerId, invoiceNo),
1160
+ queryFn: resolvedQueryFn,
1161
+ enabled
1080
1162
  });
1081
1163
  return {
1082
- invoice: _nullishCoalesce(data, () => ( null)),
1164
+ invoice: data || null,
1083
1165
  isLoading,
1084
1166
  error
1085
1167
  };
@@ -1087,18 +1169,23 @@ function useInvoiceDetail(customerId, invoiceNo, options = {}) {
1087
1169
 
1088
1170
  // src/hooks/use-customer-quotes.ts
1089
1171
 
1172
+ var EMPTY_LIST3 = { data: [], total: 0 };
1090
1173
  function useCustomerQuotes(customerId, params, options = {}) {
1091
1174
  const callbacks = useAugurCallbacks();
1092
1175
  const auth = useAugurAuth();
1093
- const effectiveCustomerId = _nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _70 => _70.customerId])));
1176
+ const site = useAugurSite();
1177
+ const effectiveCustomerId = _nullishCoalesce(_nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _86 => _86.customerId]))), () => ( _optionalChain([site, 'optionalAccess', _87 => _87.defaults, 'optionalAccess', _88 => _88.customerId])));
1178
+ const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (_optionalChain([callbacks, 'optionalAccess', _89 => _89.getCustomerQuotes]) ? () => callbacks.getCustomerQuotes(effectiveCustomerId, params) : void 0)));
1179
+ const enabled = (_nullishCoalesce(options.enabled, () => ( true))) && !!effectiveCustomerId && !!resolvedQueryFn;
1094
1180
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
1095
- queryKey: _chunkC7JC34SMcjs.getCustomerQuotesKey.call(void 0, effectiveCustomerId, params),
1096
- queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getCustomerQuotes(effectiveCustomerId, params)))),
1097
- enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!effectiveCustomerId && !!(_nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _71 => _71.getCustomerQuotes]))))
1181
+ queryKey: _chunkDYM6U3QOcjs.getCustomerQuotesKey.call(void 0, effectiveCustomerId, params),
1182
+ queryFn: resolvedQueryFn,
1183
+ enabled
1098
1184
  });
1185
+ const result = data || EMPTY_LIST3;
1099
1186
  return {
1100
- quotes: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _72 => _72.data]), () => ( [])),
1101
- total: _nullishCoalesce(_optionalChain([data, 'optionalAccess', _73 => _73.total]), () => ( 0)),
1187
+ quotes: result.data,
1188
+ total: result.total,
1102
1189
  isLoading,
1103
1190
  error
1104
1191
  };
@@ -1106,14 +1193,17 @@ function useCustomerQuotes(customerId, params, options = {}) {
1106
1193
  function useQuoteDetail(customerId, quoteNo, options = {}) {
1107
1194
  const callbacks = useAugurCallbacks();
1108
1195
  const auth = useAugurAuth();
1109
- const effectiveCustomerId = _nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _74 => _74.customerId])));
1196
+ const site = useAugurSite();
1197
+ const effectiveCustomerId = _nullishCoalesce(_nullishCoalesce(customerId, () => ( _optionalChain([auth, 'optionalAccess', _90 => _90.customerId]))), () => ( _optionalChain([site, 'optionalAccess', _91 => _91.defaults, 'optionalAccess', _92 => _92.customerId])));
1198
+ const resolvedQueryFn = _nullishCoalesce(options.queryFn, () => ( (_optionalChain([callbacks, 'optionalAccess', _93 => _93.getCustomerQuoteDetail]) ? () => callbacks.getCustomerQuoteDetail(effectiveCustomerId, quoteNo) : void 0)));
1199
+ const enabled = (_nullishCoalesce(options.enabled, () => ( true))) && !!effectiveCustomerId && !!quoteNo && !!resolvedQueryFn;
1110
1200
  const { data, isLoading, error } = _reactquery.useQuery.call(void 0, {
1111
- queryKey: _chunkC7JC34SMcjs.getCustomerQuoteDetailKey.call(void 0, effectiveCustomerId, quoteNo),
1112
- queryFn: _nullishCoalesce(options.queryFn, () => ( (() => callbacks.getCustomerQuoteDetail(effectiveCustomerId, quoteNo)))),
1113
- enabled: (_nullishCoalesce(options.enabled, () => ( true))) && !!effectiveCustomerId && !!quoteNo && !!(_nullishCoalesce(options.queryFn, () => ( _optionalChain([callbacks, 'optionalAccess', _75 => _75.getCustomerQuoteDetail]))))
1201
+ queryKey: _chunkDYM6U3QOcjs.getCustomerQuoteDetailKey.call(void 0, effectiveCustomerId, quoteNo),
1202
+ queryFn: resolvedQueryFn,
1203
+ enabled
1114
1204
  });
1115
1205
  return {
1116
- quote: _nullishCoalesce(data, () => ( null)),
1206
+ quote: data || null,
1117
1207
  isLoading,
1118
1208
  error
1119
1209
  };
@@ -1125,16 +1215,17 @@ function createSiteHooks(config = {}) {
1125
1215
  const { callbacks, defaultCustomerId, cache, imageConfig } = config;
1126
1216
  function Provider({ api, auth, children }) {
1127
1217
  const mergedAuth = {
1128
- status: _nullishCoalesce(_optionalChain([auth, 'optionalAccess', _76 => _76.status]), () => ( "unauthenticated")),
1129
- customerId: _nullishCoalesce(_optionalChain([auth, 'optionalAccess', _77 => _77.customerId]), () => ( defaultCustomerId)),
1130
- userId: _optionalChain([auth, 'optionalAccess', _78 => _78.userId]),
1131
- cartHdrUid: _optionalChain([auth, 'optionalAccess', _79 => _79.cartHdrUid])
1218
+ status: _nullishCoalesce(_optionalChain([auth, 'optionalAccess', _94 => _94.status]), () => ( "unauthenticated")),
1219
+ customerId: _optionalChain([auth, 'optionalAccess', _95 => _95.customerId]),
1220
+ userId: _optionalChain([auth, 'optionalAccess', _96 => _96.userId]),
1221
+ cartHdrUid: _optionalChain([auth, 'optionalAccess', _97 => _97.cartHdrUid])
1132
1222
  };
1133
1223
  return _react.createElement.call(void 0, AugurHooksProvider, {
1134
1224
  api,
1135
1225
  callbacks,
1136
1226
  auth: mergedAuth,
1137
1227
  cache,
1228
+ site: defaultCustomerId ? { name: "", defaults: { customerId: defaultCustomerId } } : void 0,
1138
1229
  children
1139
1230
  });
1140
1231
  }
@@ -1207,7 +1298,7 @@ function deserialize(data) {
1207
1298
 
1208
1299
  // src/persistence/apply-limits.ts
1209
1300
  function applyLimits(data, limits) {
1210
- const queries = _optionalChain([data, 'access', _80 => _80.clientState, 'optionalAccess', _81 => _81.queries]);
1301
+ const queries = _optionalChain([data, 'access', _98 => _98.clientState, 'optionalAccess', _99 => _99.queries]);
1211
1302
  if (!queries || Object.keys(limits).length === 0) return data;
1212
1303
  const entries = queries;
1213
1304
  const unlimited = [];
@@ -1308,7 +1399,7 @@ function useStorageMonitor(config) {
1308
1399
  const raw = storage.getItem(key);
1309
1400
  if (!raw) return;
1310
1401
  const parsed = JSON.parse(raw);
1311
- if (!_optionalChain([parsed, 'access', _82 => _82.clientState, 'optionalAccess', _83 => _83.queries])) return;
1402
+ if (!_optionalChain([parsed, 'access', _100 => _100.clientState, 'optionalAccess', _101 => _101.queries])) return;
1312
1403
  parsed.clientState.queries = parsed.clientState.queries.filter(
1313
1404
  (q) => {
1314
1405
  if (!Array.isArray(q.queryKey)) return true;
@@ -1335,7 +1426,7 @@ function useAugurPersistence(config) {
1335
1426
  setIsMounted(true);
1336
1427
  }, []);
1337
1428
  useStorageMonitor(config);
1338
- const isDev = typeof process !== "undefined" && _optionalChain([process, 'access', _84 => _84.env, 'optionalAccess', _85 => _85.NODE_ENV]) === "development";
1429
+ const isDev = typeof process !== "undefined" && _optionalChain([process, 'access', _102 => _102.env, 'optionalAccess', _103 => _103.NODE_ENV]) === "development";
1339
1430
  const { persistableKeys } = config;
1340
1431
  const dehydrateOptions = _react.useMemo.call(void 0, () => ({
1341
1432
  shouldDehydrateQuery: (query) => {
@@ -1441,5 +1532,9 @@ function useAugurPersistence(config) {
1441
1532
 
1442
1533
 
1443
1534
 
1444
- exports.AugurHooksProvider = AugurHooksProvider; exports.createSiteHooks = createSiteHooks; exports.executeBatchQuery = _chunkC7JC34SMcjs.executeBatchQuery; exports.getBatchInvMastDocKey = _chunkC7JC34SMcjs.getBatchInvMastDocKey; exports.getBatchInvMastDocOptions = _chunkC7JC34SMcjs.getBatchInvMastDocOptions; exports.getCartPricingQueryOptions = _chunkC7JC34SMcjs.getCartPricingQueryOptions; exports.getCategoryItemsInfiniteKey = _chunkC7JC34SMcjs.getCategoryItemsInfiniteKey; exports.getCategoryItemsInfiniteOptions = _chunkC7JC34SMcjs.getCategoryItemsInfiniteOptions; exports.getCustomerInvoiceDetailKey = _chunkC7JC34SMcjs.getCustomerInvoiceDetailKey; exports.getCustomerInvoicesKey = _chunkC7JC34SMcjs.getCustomerInvoicesKey; exports.getCustomerOrderDetailKey = _chunkC7JC34SMcjs.getCustomerOrderDetailKey; exports.getCustomerOrdersKey = _chunkC7JC34SMcjs.getCustomerOrdersKey; exports.getCustomerQuoteDetailKey = _chunkC7JC34SMcjs.getCustomerQuoteDetailKey; exports.getCustomerQuotesKey = _chunkC7JC34SMcjs.getCustomerQuotesKey; exports.getInvMastDocKey = _chunkC7JC34SMcjs.getInvMastDocKey; exports.getInvMastDocOptions = _chunkC7JC34SMcjs.getInvMastDocOptions; exports.getInvMastKey = _chunkC7JC34SMcjs.getInvMastKey; exports.getInvMastOptions = _chunkC7JC34SMcjs.getInvMastOptions; exports.getInvMastStockKey = _chunkC7JC34SMcjs.getInvMastStockKey; exports.getInvMastStockOptions = _chunkC7JC34SMcjs.getInvMastStockOptions; exports.getItemAttributesKey = _chunkC7JC34SMcjs.getItemAttributesKey; exports.getItemAttributesOptions = _chunkC7JC34SMcjs.getItemAttributesOptions; exports.getItemCategoryKey = _chunkC7JC34SMcjs.getItemCategoryKey; exports.getItemCategoryOptions = _chunkC7JC34SMcjs.getItemCategoryOptions; exports.getItemDetailsKey = _chunkC7JC34SMcjs.getItemDetailsKey; exports.getItemDetailsOptions = _chunkC7JC34SMcjs.getItemDetailsOptions; exports.getItemPriceKey = _chunkC7JC34SMcjs.getItemPriceKey; exports.getItemPriceOptions = _chunkC7JC34SMcjs.getItemPriceOptions; exports.getItemSearchInfiniteKey = _chunkC7JC34SMcjs.getItemSearchInfiniteKey; exports.getItemSearchInfiniteOptions = _chunkC7JC34SMcjs.getItemSearchInfiniteOptions; exports.getJoomlaContentKey = _chunkC7JC34SMcjs.getJoomlaContentKey; exports.getJoomlaContentListKey = _chunkC7JC34SMcjs.getJoomlaContentListKey; exports.getJoomlaContentListOptions = _chunkC7JC34SMcjs.getJoomlaContentListOptions; exports.getJoomlaContentOptions = _chunkC7JC34SMcjs.getJoomlaContentOptions; exports.getJoomlaMenuDocKey = _chunkC7JC34SMcjs.getJoomlaMenuDocKey; exports.getJoomlaMenuDocOptions = _chunkC7JC34SMcjs.getJoomlaMenuDocOptions; exports.getJoomlaMenuKey = _chunkC7JC34SMcjs.getJoomlaMenuKey; exports.getJoomlaMenuOptions = _chunkC7JC34SMcjs.getJoomlaMenuOptions; exports.getProductCategoryKey = _chunkC7JC34SMcjs.getProductCategoryKey; exports.getProductCategoryOptions = _chunkC7JC34SMcjs.getProductCategoryOptions; exports.getProductSearchKey = _chunkC7JC34SMcjs.getProductSearchKey; exports.getProductSearchOptions = _chunkC7JC34SMcjs.getProductSearchOptions; exports.getSearchSuggestionsKey = _chunkC7JC34SMcjs.getSearchSuggestionsKey; exports.getSearchSuggestionsOptions = _chunkC7JC34SMcjs.getSearchSuggestionsOptions; exports.useAugurApi = useAugurApi; exports.useAugurApiOptional = useAugurApiOptional; exports.useAugurAuth = useAugurAuth; exports.useAugurCache = useAugurCache; exports.useAugurOptions = useAugurOptions; exports.useAugurPersistence = useAugurPersistence; exports.useBatchInvMastDoc = useBatchInvMastDoc; exports.useCartActions = useCartActions; exports.useCartHdrUid = useCartHdrUid; exports.useCartInitialization = useCartInitialization; exports.useCartLineCount = useCartLineCount; exports.useCartLines = useCartLines; exports.useCartPricing = useCartPricing; exports.useCartQuantityTotal = useCartQuantityTotal; exports.useCartStore = useCartStore; exports.useCategoryItemsInfinite = useCategoryItemsInfinite; exports.useClearCart = useClearCart; exports.useCustomerInvoices = useCustomerInvoices; exports.useCustomerOrders = useCustomerOrders; exports.useCustomerQuotes = useCustomerQuotes; exports.useDebounce = useDebounce; exports.useFormatPrice = useFormatPrice; exports.useInvMast = useInvMast; exports.useInvMastDoc = useInvMastDoc; exports.useInvMastStock = useInvMastStock; exports.useInvoiceDetail = useInvoiceDetail; exports.useItemAttributes = useItemAttributes; exports.useItemCategory = useItemCategory; exports.useItemDetails = useItemDetails; exports.useItemFiltersStore = useItemFiltersStore; exports.useItemPrice = useItemPrice; exports.useItemSearchInfinite = useItemSearchInfinite; exports.useJoomlaContent = useJoomlaContent; exports.useJoomlaContentList = useJoomlaContentList; exports.useJoomlaMenu = useJoomlaMenu; exports.useJoomlaMenuDoc = useJoomlaMenuDoc; exports.useOrderDetail = useOrderDetail; exports.usePaginationPrefetch = usePaginationPrefetch; exports.useProductCategory = useProductCategory; exports.useProductSearch = useProductSearch; exports.useQuoteDetail = useQuoteDetail; exports.useSearchSuggestions = useSearchSuggestions; exports.useSetCartHdrUid = useSetCartHdrUid; exports.useSetCartLines = useSetCartLines;
1535
+
1536
+
1537
+
1538
+
1539
+ exports.AugurHooksProvider = AugurHooksProvider; exports.createSiteHooks = createSiteHooks; exports.executeBatchQuery = _chunkDYM6U3QOcjs.executeBatchQuery; exports.getBatchInvMastDocKey = _chunkDYM6U3QOcjs.getBatchInvMastDocKey; exports.getBatchInvMastDocOptions = _chunkDYM6U3QOcjs.getBatchInvMastDocOptions; exports.getCartPricingQueryOptions = _chunkDYM6U3QOcjs.getCartPricingQueryOptions; exports.getCategoryItemsInfiniteKey = _chunkDYM6U3QOcjs.getCategoryItemsInfiniteKey; exports.getCategoryItemsInfiniteOptions = _chunkDYM6U3QOcjs.getCategoryItemsInfiniteOptions; exports.getCustomerInvoiceDetailKey = _chunkDYM6U3QOcjs.getCustomerInvoiceDetailKey; exports.getCustomerInvoicesKey = _chunkDYM6U3QOcjs.getCustomerInvoicesKey; exports.getCustomerOrderDetailKey = _chunkDYM6U3QOcjs.getCustomerOrderDetailKey; exports.getCustomerOrdersKey = _chunkDYM6U3QOcjs.getCustomerOrdersKey; exports.getCustomerQuoteDetailKey = _chunkDYM6U3QOcjs.getCustomerQuoteDetailKey; exports.getCustomerQuotesKey = _chunkDYM6U3QOcjs.getCustomerQuotesKey; exports.getInvMastDocKey = _chunkDYM6U3QOcjs.getInvMastDocKey; exports.getInvMastDocOptions = _chunkDYM6U3QOcjs.getInvMastDocOptions; exports.getInvMastKey = _chunkDYM6U3QOcjs.getInvMastKey; exports.getInvMastOptions = _chunkDYM6U3QOcjs.getInvMastOptions; exports.getInvMastStockKey = _chunkDYM6U3QOcjs.getInvMastStockKey; exports.getInvMastStockOptions = _chunkDYM6U3QOcjs.getInvMastStockOptions; exports.getItemAttributesKey = _chunkDYM6U3QOcjs.getItemAttributesKey; exports.getItemAttributesOptions = _chunkDYM6U3QOcjs.getItemAttributesOptions; exports.getItemCategoryKey = _chunkDYM6U3QOcjs.getItemCategoryKey; exports.getItemCategoryOptions = _chunkDYM6U3QOcjs.getItemCategoryOptions; exports.getItemDetailsKey = _chunkDYM6U3QOcjs.getItemDetailsKey; exports.getItemDetailsOptions = _chunkDYM6U3QOcjs.getItemDetailsOptions; exports.getItemPriceKey = _chunkDYM6U3QOcjs.getItemPriceKey; exports.getItemPriceOptions = _chunkDYM6U3QOcjs.getItemPriceOptions; exports.getItemSearchInfiniteKey = _chunkDYM6U3QOcjs.getItemSearchInfiniteKey; exports.getItemSearchInfiniteOptions = _chunkDYM6U3QOcjs.getItemSearchInfiniteOptions; exports.getJoomlaContentKey = _chunkDYM6U3QOcjs.getJoomlaContentKey; exports.getJoomlaContentListKey = _chunkDYM6U3QOcjs.getJoomlaContentListKey; exports.getJoomlaContentListOptions = _chunkDYM6U3QOcjs.getJoomlaContentListOptions; exports.getJoomlaContentOptions = _chunkDYM6U3QOcjs.getJoomlaContentOptions; exports.getJoomlaMenuDocKey = _chunkDYM6U3QOcjs.getJoomlaMenuDocKey; exports.getJoomlaMenuDocOptions = _chunkDYM6U3QOcjs.getJoomlaMenuDocOptions; exports.getJoomlaMenuKey = _chunkDYM6U3QOcjs.getJoomlaMenuKey; exports.getJoomlaMenuOptions = _chunkDYM6U3QOcjs.getJoomlaMenuOptions; exports.getProductCategoryKey = _chunkDYM6U3QOcjs.getProductCategoryKey; exports.getProductCategoryOptions = _chunkDYM6U3QOcjs.getProductCategoryOptions; exports.getProductSearchKey = _chunkDYM6U3QOcjs.getProductSearchKey; exports.getProductSearchOptions = _chunkDYM6U3QOcjs.getProductSearchOptions; exports.getSearchSuggestionsKey = _chunkDYM6U3QOcjs.getSearchSuggestionsKey; exports.getSearchSuggestionsOptions = _chunkDYM6U3QOcjs.getSearchSuggestionsOptions; exports.getStockKey = _chunkDYM6U3QOcjs.getStockKey; exports.getStockOptions = _chunkDYM6U3QOcjs.getStockOptions; exports.useAugurApi = useAugurApi; exports.useAugurApiOptional = useAugurApiOptional; exports.useAugurAuth = useAugurAuth; exports.useAugurCache = useAugurCache; exports.useAugurOptions = useAugurOptions; exports.useAugurPersistence = useAugurPersistence; exports.useAugurSite = useAugurSite; exports.useBatchInvMastDoc = useBatchInvMastDoc; exports.useCartActions = useCartActions; exports.useCartHdrUid = useCartHdrUid; exports.useCartInitialization = useCartInitialization; exports.useCartLineCount = useCartLineCount; exports.useCartLines = useCartLines; exports.useCartPricing = useCartPricing; exports.useCartQuantityTotal = useCartQuantityTotal; exports.useCartStore = useCartStore; exports.useCategoryItemsInfinite = useCategoryItemsInfinite; exports.useClearCart = useClearCart; exports.useCustomerInvoices = useCustomerInvoices; exports.useCustomerOrders = useCustomerOrders; exports.useCustomerQuotes = useCustomerQuotes; exports.useDebounce = useDebounce; exports.useFormatPrice = useFormatPrice; exports.useInvMast = useInvMast; exports.useInvMastDoc = useInvMastDoc; exports.useInvMastStock = useInvMastStock; exports.useInvoiceDetail = useInvoiceDetail; exports.useItemAttributes = useItemAttributes; exports.useItemCategory = useItemCategory; exports.useItemDetails = useItemDetails; exports.useItemFiltersStore = useItemFiltersStore; exports.useItemPrice = useItemPrice; exports.useItemSearchInfinite = useItemSearchInfinite; exports.useJoomlaContent = useJoomlaContent; exports.useJoomlaContentList = useJoomlaContentList; exports.useJoomlaMenu = useJoomlaMenu; exports.useJoomlaMenuDoc = useJoomlaMenuDoc; exports.useOrderDetail = useOrderDetail; exports.usePaginationPrefetch = usePaginationPrefetch; exports.useProductCategory = useProductCategory; exports.useProductSearch = useProductSearch; exports.useQuoteDetail = useQuoteDetail; exports.useSearchSuggestions = useSearchSuggestions; exports.useSetCartHdrUid = useSetCartHdrUid; exports.useSetCartLines = useSetCartLines; exports.useStock = useStock;
1445
1540
  //# sourceMappingURL=index.cjs.map