@cimplify/sdk 0.71.0 → 0.73.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/dist/react.d.mts +64 -17
  2. package/dist/react.d.ts +64 -17
  3. package/dist/react.js +209 -87
  4. package/dist/react.mjs +210 -88
  5. package/dist/styles.css +1 -1
  6. package/dist/testing.d.mts +15 -15
  7. package/dist/testing.d.ts +15 -15
  8. package/package.json +1 -1
  9. package/registry/accommodation-card.json +1 -1
  10. package/registry/add-on-selector.json +1 -1
  11. package/registry/billing-plan-selector.json +1 -1
  12. package/registry/booking-page.json +1 -1
  13. package/registry/bundle-selector.json +1 -1
  14. package/registry/compact-service-card.json +1 -1
  15. package/registry/composite-selector.json +1 -1
  16. package/registry/customer-input-fields.json +1 -1
  17. package/registry/date-slot-picker.json +1 -1
  18. package/registry/default-product-layout.json +1 -1
  19. package/registry/digital-product-card.json +1 -1
  20. package/registry/digital-product-layout.json +1 -1
  21. package/registry/food-product-card.json +1 -1
  22. package/registry/food-product-layout.json +1 -1
  23. package/registry/lease-service-card.json +1 -1
  24. package/registry/price-range.json +1 -1
  25. package/registry/price.json +1 -1
  26. package/registry/product-card.json +1 -1
  27. package/registry/product-customizer.json +1 -1
  28. package/registry/product-image-gallery.json +1 -1
  29. package/registry/product-sheet.json +1 -1
  30. package/registry/rental-service-card.json +1 -1
  31. package/registry/retail-product-card.json +1 -1
  32. package/registry/sale-badge.json +1 -1
  33. package/registry/schedule-service-card.json +1 -1
  34. package/registry/service-product-layout.json +1 -1
  35. package/registry/slot-picker.json +1 -1
  36. package/registry/standard-service-card.json +1 -1
  37. package/registry/subscription-card.json +1 -1
  38. package/registry/variant-selector.json +1 -1
  39. package/registry/volume-pricing.json +1 -1
  40. package/registry/wholesale-product-card.json +1 -1
  41. package/registry/wholesale-product-layout.json +1 -1
package/dist/react.js CHANGED
@@ -1149,14 +1149,20 @@ function CimplifyProvider({
1149
1149
  client,
1150
1150
  children,
1151
1151
  onLocationChange,
1152
+ initialBusiness,
1153
+ initialLocations,
1152
1154
  optimistic = true
1153
1155
  }) {
1154
1156
  const resolvedClient = React14.useMemo(() => client ?? createDefaultClient(), [client]);
1155
1157
  const onLocationChangeRef = React14.useRef(onLocationChange);
1156
- const [business, setBusiness] = React14.useState(null);
1157
- const [locations, setLocations] = React14.useState([]);
1158
- const [currentLocation, setCurrentLocationState] = React14.useState(null);
1159
- const [isReady, setIsReady] = React14.useState(false);
1158
+ const seeded = initialBusiness !== void 0;
1159
+ const initialBootstrapDone = React14.useRef(seeded);
1160
+ const [business, setBusiness] = React14.useState(initialBusiness ?? null);
1161
+ const [locations, setLocations] = React14.useState(initialLocations ?? []);
1162
+ const [currentLocation, setCurrentLocationState] = React14.useState(
1163
+ initialLocations && initialLocations.length > 0 ? initialLocations[0] : null
1164
+ );
1165
+ const [isReady, setIsReady] = React14.useState(seeded);
1160
1166
  React14.useEffect(() => {
1161
1167
  onLocationChangeRef.current = onLocationChange;
1162
1168
  }, [onLocationChange]);
@@ -1230,7 +1236,9 @@ function CimplifyProvider({
1230
1236
  React14.useEffect(() => {
1231
1237
  let cancelled = false;
1232
1238
  async function bootstrap() {
1233
- setIsReady(false);
1239
+ if (!initialBootstrapDone.current) {
1240
+ setIsReady(false);
1241
+ }
1234
1242
  const [businessResult, locationsResult] = await Promise.all([
1235
1243
  resolvedClient.business.getInfo(),
1236
1244
  resolvedClient.business.getLocations()
@@ -1255,23 +1263,27 @@ function CimplifyProvider({
1255
1263
  resolvedClient.setLocationId(null);
1256
1264
  setStoredLocationId(null);
1257
1265
  }
1266
+ initialBootstrapDone.current = true;
1258
1267
  setIsReady(true);
1259
1268
  }
1260
1269
  bootstrap().catch(() => {
1261
1270
  if (cancelled) {
1262
1271
  return;
1263
1272
  }
1264
- setBusiness(null);
1265
- setLocations([]);
1266
- setCurrentLocationState(null);
1267
- resolvedClient.setLocationId(null);
1268
- setStoredLocationId(null);
1273
+ if (!seeded) {
1274
+ setBusiness(null);
1275
+ setLocations([]);
1276
+ setCurrentLocationState(null);
1277
+ resolvedClient.setLocationId(null);
1278
+ setStoredLocationId(null);
1279
+ }
1280
+ initialBootstrapDone.current = true;
1269
1281
  setIsReady(true);
1270
1282
  });
1271
1283
  return () => {
1272
1284
  cancelled = true;
1273
1285
  };
1274
- }, [resolvedClient]);
1286
+ }, [resolvedClient, seeded]);
1275
1287
  const clientContextValue = React14.useMemo(
1276
1288
  () => ({
1277
1289
  client: resolvedClient,
@@ -4203,11 +4215,18 @@ function CimplifyUserButton({
4203
4215
  )
4204
4216
  ] });
4205
4217
  }
4206
- function Price({ amount, currency, className, prefix }) {
4218
+ function Price({
4219
+ amount,
4220
+ currency,
4221
+ className,
4222
+ prefix,
4223
+ convert = true
4224
+ }) {
4207
4225
  const context = useOptionalCimplify();
4208
- const resolvedCurrency = currency ?? context?.displayCurrency ?? "USD";
4209
- const convertedAmount = !currency && context?.convertPrice ? context.convertPrice(amount) : amount;
4210
- const resolvedAmount = typeof convertedAmount === "string" ? parseFloat(convertedAmount) || 0 : convertedAmount;
4226
+ const sourceCurrency = currency ?? context?.baseCurrency ?? "USD";
4227
+ const fxActive = convert && context?.fxRate != null && context.displayCurrency !== sourceCurrency && sourceCurrency === context.baseCurrency;
4228
+ const resolvedCurrency = fxActive ? context.displayCurrency : sourceCurrency;
4229
+ const resolvedAmount = fxActive ? context.convertPrice(amount) : typeof amount === "string" ? parseFloat(amount) || 0 : amount;
4211
4230
  return /* @__PURE__ */ jsxRuntime.jsxs("span", { className, children: [
4212
4231
  prefix,
4213
4232
  chunk7Y2O3E4D_js.formatPrice(resolvedAmount, resolvedCurrency)
@@ -6163,6 +6182,7 @@ function VariantSelector({
6163
6182
  variants,
6164
6183
  variantAxes,
6165
6184
  basePrice,
6185
+ currency,
6166
6186
  selectedVariantId,
6167
6187
  onVariantChange,
6168
6188
  productName,
@@ -6235,6 +6255,36 @@ function VariantSelector({
6235
6255
  className: cn("flex flex-wrap gap-2", classNames?.axisOptions),
6236
6256
  children: axis.values.map((value) => {
6237
6257
  const isSelected = axisSelections[axis.id] === value.id;
6258
+ if (value.image_url || value.color_hex) {
6259
+ const isImage = Boolean(value.image_url);
6260
+ return /* @__PURE__ */ jsxRuntime.jsx(
6261
+ radio.Radio.Root,
6262
+ {
6263
+ value: value.id,
6264
+ "data-cimplify-variant-option": true,
6265
+ "data-cimplify-variant-swatch": true,
6266
+ "data-selected": isSelected || void 0,
6267
+ "aria-label": value.name,
6268
+ title: value.name,
6269
+ style: isImage ? void 0 : { backgroundColor: value.color_hex },
6270
+ className: cn(
6271
+ "relative overflow-hidden border border-border transition-shadow",
6272
+ isImage ? "h-12 w-12 rounded-md" : "h-9 w-9 rounded-full",
6273
+ isSelected && "ring-2 ring-foreground ring-offset-2 ring-offset-background border-transparent",
6274
+ isSelected ? classNames?.swatchSelected : classNames?.swatch
6275
+ ),
6276
+ children: isImage && /* @__PURE__ */ jsxRuntime.jsx(
6277
+ "img",
6278
+ {
6279
+ src: value.image_url,
6280
+ alt: "",
6281
+ className: "h-full w-full object-cover"
6282
+ }
6283
+ )
6284
+ },
6285
+ value.id
6286
+ );
6287
+ }
6238
6288
  return /* @__PURE__ */ jsxRuntime.jsx(
6239
6289
  radio.Radio.Root,
6240
6290
  {
@@ -6315,7 +6365,7 @@ function VariantSelector({
6315
6365
  ),
6316
6366
  /* @__PURE__ */ jsxRuntime.jsxs("span", { "data-cimplify-variant-pricing": true, className: cn("text-sm text-muted-foreground", classNames?.pricing), children: [
6317
6367
  adjustment > 0 ? "+" : adjustment < 0 ? "" : "+",
6318
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: variant.price_adjustment })
6368
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: variant.price_adjustment, currency })
6319
6369
  ] })
6320
6370
  ]
6321
6371
  },
@@ -6330,6 +6380,7 @@ function AddOnSelector({
6330
6380
  addOns,
6331
6381
  selectedOptions,
6332
6382
  onOptionsChange,
6383
+ currency,
6333
6384
  className,
6334
6385
  classNames
6335
6386
  }) {
@@ -6488,7 +6539,7 @@ function AddOnSelector({
6488
6539
  ),
6489
6540
  option.default_price != null && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-sm text-muted-foreground", children: [
6490
6541
  "+",
6491
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: option.default_price })
6542
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: option.default_price, currency })
6492
6543
  ] })
6493
6544
  ]
6494
6545
  },
@@ -6508,6 +6559,7 @@ function BundleSelector({
6508
6559
  bundlePrice,
6509
6560
  discountValue,
6510
6561
  pricingType,
6562
+ currency,
6511
6563
  onSelectionsChange,
6512
6564
  onPriceChange,
6513
6565
  onReady,
@@ -6588,6 +6640,7 @@ function BundleSelector({
6588
6640
  component: comp,
6589
6641
  selectedVariantId: variantChoices[comp.id],
6590
6642
  onVariantChange: (variantId) => handleVariantChange(comp.id, variantId),
6643
+ currency,
6591
6644
  classNames
6592
6645
  },
6593
6646
  comp.id
@@ -6599,7 +6652,7 @@ function BundleSelector({
6599
6652
  className: cn("border-t border-border pt-4 flex justify-between text-sm", classNames?.summary),
6600
6653
  children: [
6601
6654
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: "Bundle price" }),
6602
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: bundlePrice, className: "font-medium text-primary" })
6655
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: bundlePrice, currency, className: "font-medium text-primary" })
6603
6656
  ]
6604
6657
  }
6605
6658
  ),
@@ -6610,7 +6663,7 @@ function BundleSelector({
6610
6663
  className: cn("flex justify-between text-sm", classNames?.savings),
6611
6664
  children: [
6612
6665
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: "You save" }),
6613
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: discountValue, className: "text-green-600 font-medium" })
6666
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: discountValue, currency, className: "text-green-600 font-medium" })
6614
6667
  ]
6615
6668
  }
6616
6669
  )
@@ -6643,6 +6696,7 @@ function BundleComponentCard({
6643
6696
  component,
6644
6697
  selectedVariantId,
6645
6698
  onVariantChange,
6699
+ currency,
6646
6700
  classNames
6647
6701
  }) {
6648
6702
  const idPrefix = React14.useId();
@@ -6723,7 +6777,7 @@ function BundleComponentCard({
6723
6777
  }
6724
6778
  )
6725
6779
  ] }),
6726
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-muted-foreground", children: /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: displayPrice }) })
6780
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-muted-foreground", children: /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: displayPrice, currency }) })
6727
6781
  ]
6728
6782
  }
6729
6783
  ),
@@ -6769,7 +6823,7 @@ function BundleComponentCard({
6769
6823
  className: cn("text-sm text-muted-foreground", classNames?.variantAdjustment),
6770
6824
  children: [
6771
6825
  adjustment > 0 ? "+" : "",
6772
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: variant.price_adjustment })
6826
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: variant.price_adjustment, currency })
6773
6827
  ]
6774
6828
  }
6775
6829
  )
@@ -6787,6 +6841,7 @@ function BundleComponentCard({
6787
6841
  function CompositeSelector({
6788
6842
  compositeId,
6789
6843
  groups,
6844
+ currency,
6790
6845
  onSelectionsChange,
6791
6846
  onPriceChange,
6792
6847
  onReady,
@@ -7165,7 +7220,7 @@ function CompositeSelector({
7165
7220
  ),
7166
7221
  component.price != null && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-sm text-muted-foreground shrink-0", children: [
7167
7222
  "+",
7168
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: component.price })
7223
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: component.price, currency })
7169
7224
  ] })
7170
7225
  ]
7171
7226
  },
@@ -7192,7 +7247,7 @@ function CompositeSelector({
7192
7247
  className: cn("flex justify-between text-muted-foreground", classNames?.summaryLine),
7193
7248
  children: [
7194
7249
  /* @__PURE__ */ jsxRuntime.jsx("span", { children: "Base" }),
7195
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: priceResult.base_price })
7250
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: priceResult.base_price, currency })
7196
7251
  ]
7197
7252
  }
7198
7253
  ),
@@ -7203,7 +7258,7 @@ function CompositeSelector({
7203
7258
  className: cn("flex justify-between text-muted-foreground", classNames?.summaryLine),
7204
7259
  children: [
7205
7260
  /* @__PURE__ */ jsxRuntime.jsx("span", { children: "Selections" }),
7206
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: priceResult.components_total })
7261
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: priceResult.components_total, currency })
7207
7262
  ]
7208
7263
  }
7209
7264
  ),
@@ -7214,7 +7269,7 @@ function CompositeSelector({
7214
7269
  className: cn("flex justify-between font-medium pt-1 border-t border-border", classNames?.summaryTotal),
7215
7270
  children: [
7216
7271
  /* @__PURE__ */ jsxRuntime.jsx("span", { children: "Total" }),
7217
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: priceResult.final_price, className: "text-primary" })
7272
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: priceResult.final_price, currency, className: "text-primary" })
7218
7273
  ]
7219
7274
  }
7220
7275
  )
@@ -7271,6 +7326,7 @@ function formatMarkup(plan) {
7271
7326
  function BillingPlanSelector({
7272
7327
  productId,
7273
7328
  plans: plansProp,
7329
+ currency,
7274
7330
  onPlanSelect,
7275
7331
  selectedPlanId,
7276
7332
  showOneTimePurchase = false,
@@ -7332,7 +7388,7 @@ function BillingPlanSelector({
7332
7388
  markup && /* @__PURE__ */ jsxRuntime.jsx("span", { "data-cimplify-billing-markup": true, className: classNames?.price, children: markup }),
7333
7389
  plan.markup_type === "fixed" && plan.markup_amount != null && /* @__PURE__ */ jsxRuntime.jsxs("span", { "data-cimplify-billing-markup": true, className: classNames?.price, children: [
7334
7390
  "+",
7335
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: plan.markup_amount })
7391
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: plan.markup_amount, currency })
7336
7392
  ] }),
7337
7393
  plan.trial_days > 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { "data-cimplify-billing-trial": true, className: classNames?.trialBadge, children: [
7338
7394
  plan.trial_days,
@@ -7340,7 +7396,7 @@ function BillingPlanSelector({
7340
7396
  ] }),
7341
7397
  plan.setup_fee > 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { "data-cimplify-billing-setup-fee": true, className: classNames?.setupFee, children: [
7342
7398
  "Setup fee: ",
7343
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: plan.setup_fee })
7399
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: plan.setup_fee, currency })
7344
7400
  ] }),
7345
7401
  plan.plan_type === "installment" && plan.installment_periods != null && /* @__PURE__ */ jsxRuntime.jsxs("span", { "data-cimplify-billing-periods": true, children: [
7346
7402
  plan.installment_periods,
@@ -7368,6 +7424,7 @@ function VolumePricing({
7368
7424
  tiers,
7369
7425
  currentQuantity,
7370
7426
  defaultOpen = false,
7427
+ currency,
7371
7428
  className,
7372
7429
  classNames
7373
7430
  }) {
@@ -7432,7 +7489,7 @@ function VolumePricing({
7432
7489
  }
7433
7490
  ),
7434
7491
  /* @__PURE__ */ jsxRuntime.jsxs("span", { "data-cimplify-volume-pricing-price": true, className: classNames?.tierPrice, children: [
7435
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: tier.unit_price, prefix: "" }),
7492
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: tier.unit_price, currency, prefix: "" }),
7436
7493
  " /ea"
7437
7494
  ] })
7438
7495
  ]
@@ -7707,6 +7764,7 @@ function CustomerInputFields({
7707
7764
  values,
7708
7765
  onChange,
7709
7766
  onFileUpload,
7767
+ currency,
7710
7768
  className,
7711
7769
  classNames
7712
7770
  }) {
@@ -7736,6 +7794,7 @@ function CustomerInputFields({
7736
7794
  value: values[field.id],
7737
7795
  onValueChange: (value) => setValue(field.id, value),
7738
7796
  onFileUpload: onFileUpload ?? (clientContext?.client ? (_file, _field) => defaultFileUpload(_file) : void 0),
7797
+ currency,
7739
7798
  classNames
7740
7799
  },
7741
7800
  field.id
@@ -7746,6 +7805,7 @@ function InputField({
7746
7805
  value,
7747
7806
  onValueChange,
7748
7807
  onFileUpload,
7808
+ currency,
7749
7809
  classNames
7750
7810
  }) {
7751
7811
  const hasPriceAdjustment = field.price_adjustment != null && chunk7Y2O3E4D_js.parsePrice(field.price_adjustment) > 0;
@@ -7755,7 +7815,7 @@ function InputField({
7755
7815
  field.is_required && /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("text-xs text-destructive", classNames?.required), children: "Required" }),
7756
7816
  hasPriceAdjustment && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: cn("text-xs text-muted-foreground", classNames?.priceAdjustment), children: [
7757
7817
  "+",
7758
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: field.price_adjustment })
7818
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: field.price_adjustment, currency })
7759
7819
  ] })
7760
7820
  ] }),
7761
7821
  field.help_text && /* @__PURE__ */ jsxRuntime.jsx("p", { className: cn("text-xs text-muted-foreground mb-1.5", classNames?.helpText), children: field.help_text }),
@@ -8678,6 +8738,8 @@ function SlotPicker({
8678
8738
  onSlotSelect,
8679
8739
  groupByTimeOfDay = true,
8680
8740
  showPrice = true,
8741
+ lowCapacityThreshold = 3,
8742
+ currency,
8681
8743
  schedulingMode = "intraday",
8682
8744
  durationUnit,
8683
8745
  durationValue,
@@ -8770,14 +8832,18 @@ function SlotPicker({
8770
8832
  children: group.slots.map((slot) => {
8771
8833
  const value = slotToValue(slot);
8772
8834
  const isSelected = selectedSlot?.start_time === slot.start_time && selectedSlot?.end_time === slot.end_time;
8835
+ const capacity = slot.capacity_available ?? slot.remaining_capacity;
8836
+ const soldOut = capacity === 0;
8837
+ const unavailable = slot.is_available === false || soldOut;
8838
+ const lowCapacity = lowCapacityThreshold > 0 && capacity != null && capacity > 0 && capacity <= lowCapacityThreshold;
8773
8839
  return /* @__PURE__ */ jsxRuntime.jsxs(
8774
8840
  radio.Radio.Root,
8775
8841
  {
8776
8842
  value,
8777
- disabled: slot.is_available === false,
8843
+ disabled: unavailable,
8778
8844
  "data-cimplify-slot": true,
8779
8845
  "data-selected": isSelected || void 0,
8780
- "data-unavailable": slot.is_available === false || void 0,
8846
+ "data-unavailable": unavailable || void 0,
8781
8847
  className: cn(
8782
8848
  "inline-flex items-center justify-center gap-2 rounded-md border border-border bg-background px-3 py-2 text-sm font-medium text-foreground transition-colors hover:border-foreground/40 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring data-[selected]:border-foreground data-[selected]:bg-foreground data-[selected]:text-background data-[unavailable]:cursor-not-allowed data-[unavailable]:opacity-40 data-[unavailable]:line-through",
8783
8849
  isMultiDay && "justify-between text-left",
@@ -8790,7 +8856,18 @@ function SlotPicker({
8790
8856
  {
8791
8857
  "data-cimplify-slot-price": true,
8792
8858
  className: cn("text-xs opacity-70", classNames?.slotPrice),
8793
- children: /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: slot.price })
8859
+ children: /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: slot.price, currency })
8860
+ }
8861
+ ),
8862
+ lowCapacity && /* @__PURE__ */ jsxRuntime.jsxs(
8863
+ "span",
8864
+ {
8865
+ "data-cimplify-slot-scarcity": true,
8866
+ className: cn("text-xs font-medium text-amber-600", classNames?.slotScarcity),
8867
+ children: [
8868
+ capacity,
8869
+ " left"
8870
+ ]
8794
8871
  }
8795
8872
  )
8796
8873
  ]
@@ -8827,6 +8904,7 @@ function DateSlotPicker({
8827
8904
  onSlotSelect,
8828
8905
  availability: availabilityProp,
8829
8906
  showPrice = true,
8907
+ currency,
8830
8908
  schedulingMode,
8831
8909
  durationUnit,
8832
8910
  durationValue,
@@ -8975,6 +9053,7 @@ function DateSlotPicker({
8975
9053
  selectedSlot,
8976
9054
  onSlotSelect: handleSlotSelect,
8977
9055
  showPrice,
9056
+ currency,
8978
9057
  schedulingMode,
8979
9058
  durationUnit,
8980
9059
  durationValue,
@@ -9011,6 +9090,7 @@ function ProductCustomizer({
9011
9090
  const [specialInstructions, setSpecialInstructions] = React14.useState("");
9012
9091
  const [selectedSlot, setSelectedSlot] = React14.useState(null);
9013
9092
  const cart = useCart();
9093
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
9014
9094
  const productType = product.type || "product";
9015
9095
  const isComposite = productType === "composite";
9016
9096
  const isBundle = productType === "bundle";
@@ -9177,6 +9257,7 @@ function ProductCustomizer({
9177
9257
  {
9178
9258
  compositeId: product.composite_id,
9179
9259
  groups: product.groups,
9260
+ currency,
9180
9261
  onSelectionsChange: setCompositeSelections,
9181
9262
  onPriceChange: setCompositePrice,
9182
9263
  onReady: setCompositeReady,
@@ -9190,6 +9271,7 @@ function ProductCustomizer({
9190
9271
  bundlePrice: product.bundle_price,
9191
9272
  discountValue: product.discount_value,
9192
9273
  pricingType: product.pricing_type,
9274
+ currency,
9193
9275
  onSelectionsChange: setBundleSelections,
9194
9276
  onPriceChange: setBundleTotalPrice,
9195
9277
  onReady: setBundleReady
@@ -9201,7 +9283,8 @@ function ProductCustomizer({
9201
9283
  serviceId: product.id,
9202
9284
  selectedSlot,
9203
9285
  onSlotSelect: (slot) => setSelectedSlot(slot),
9204
- participantCount: quantity
9286
+ participantCount: quantity,
9287
+ currency
9205
9288
  }
9206
9289
  ),
9207
9290
  hasVariants && /* @__PURE__ */ jsxRuntime.jsx(
@@ -9210,6 +9293,7 @@ function ProductCustomizer({
9210
9293
  variants: product.variants,
9211
9294
  variantAxes: product.variant_axes,
9212
9295
  basePrice: product.default_price,
9296
+ currency,
9213
9297
  selectedVariantId,
9214
9298
  onVariantChange: handleVariantChange,
9215
9299
  productName: product.name
@@ -9220,7 +9304,8 @@ function ProductCustomizer({
9220
9304
  {
9221
9305
  addOns: product.add_ons,
9222
9306
  selectedOptions: selectedAddOnOptionIds,
9223
- onOptionsChange: setSelectedAddOnOptionIds
9307
+ onOptionsChange: setSelectedAddOnOptionIds,
9308
+ currency
9224
9309
  }
9225
9310
  ),
9226
9311
  product.billing_plans && product.billing_plans.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
@@ -9228,6 +9313,7 @@ function ProductCustomizer({
9228
9313
  {
9229
9314
  productId: product.id,
9230
9315
  plans: product.billing_plans,
9316
+ currency,
9231
9317
  onPlanSelect: setSelectedBillingPlan,
9232
9318
  selectedPlanId: selectedBillingPlan?.id ?? null,
9233
9319
  showOneTimePurchase: true
@@ -9237,7 +9323,8 @@ function ProductCustomizer({
9237
9323
  VolumePricing,
9238
9324
  {
9239
9325
  tiers: product.quantity_pricing,
9240
- currentQuantity: quantity
9326
+ currentQuantity: quantity,
9327
+ currency
9241
9328
  }
9242
9329
  ),
9243
9330
  product.input_fields && product.input_fields.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
@@ -9245,12 +9332,13 @@ function ProductCustomizer({
9245
9332
  {
9246
9333
  fields: product.input_fields,
9247
9334
  values: customerInputValues,
9248
- onChange: setCustomerInputValues
9335
+ onChange: setCustomerInputValues,
9336
+ currency
9249
9337
  }
9250
9338
  ),
9251
9339
  product.deposit_type && product.deposit_type !== "none" && product.deposit_amount && /* @__PURE__ */ jsxRuntime.jsx("div", { "data-cimplify-customizer-deposit": true, className: cn("text-sm text-muted-foreground", classNames?.depositInfo), children: product.deposit_type === "fixed" ? /* @__PURE__ */ jsxRuntime.jsxs("span", { children: [
9252
9340
  "Deposit required: ",
9253
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.deposit_amount })
9341
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.deposit_amount, currency })
9254
9342
  ] }) : /* @__PURE__ */ jsxRuntime.jsxs("span", { children: [
9255
9343
  "Deposit required: ",
9256
9344
  chunk7Y2O3E4D_js.parsePrice(product.deposit_amount),
@@ -9314,7 +9402,7 @@ function ProductCustomizer({
9314
9402
  ] })
9315
9403
  ] }),
9316
9404
  product.quantity_pricing && product.quantity_pricing.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-customizer-unit-price": true, className: "text-sm text-muted-foreground text-right shrink-0", children: [
9317
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: chunk7Y2O3E4D_js.getUnitPriceAtQuantity(product.quantity_pricing, quantity, chunk7Y2O3E4D_js.parsePrice(product.default_price)), className: "font-medium text-foreground" }),
9405
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: chunk7Y2O3E4D_js.getUnitPriceAtQuantity(product.quantity_pricing, quantity, chunk7Y2O3E4D_js.parsePrice(product.default_price)), currency, className: "font-medium text-foreground" }),
9318
9406
  " ea."
9319
9407
  ] }),
9320
9408
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -9331,7 +9419,7 @@ function ProductCustomizer({
9331
9419
  ),
9332
9420
  children: isAdded ? "Added to Cart" : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
9333
9421
  "Add to Cart \xB7 ",
9334
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: displayTotalPrice })
9422
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: displayTotalPrice, currency })
9335
9423
  ] })
9336
9424
  }
9337
9425
  )
@@ -9360,9 +9448,15 @@ function ProductImageGallery({
9360
9448
  [images]
9361
9449
  );
9362
9450
  const [selectedImage, setSelectedImage] = React14.useState(0);
9451
+ const [fadeIn, setFadeIn] = React14.useState(true);
9363
9452
  React14.useEffect(() => {
9364
9453
  setSelectedImage(0);
9365
9454
  }, [normalizedImages.length, productName]);
9455
+ React14.useEffect(() => {
9456
+ setFadeIn(false);
9457
+ const id = requestAnimationFrame(() => setFadeIn(true));
9458
+ return () => cancelAnimationFrame(id);
9459
+ }, [selectedImage]);
9366
9460
  if (normalizedImages.length === 0) {
9367
9461
  return null;
9368
9462
  }
@@ -9378,7 +9472,13 @@ function ProductImageGallery({
9378
9472
  {
9379
9473
  src: activeImage,
9380
9474
  alt: productName,
9381
- style: { width: "100%", height: "100%", objectFit: "cover" },
9475
+ style: {
9476
+ width: "100%",
9477
+ height: "100%",
9478
+ objectFit: "cover",
9479
+ opacity: fadeIn ? 1 : 0,
9480
+ transition: "opacity 300ms ease"
9481
+ },
9382
9482
  "data-cimplify-image-gallery-active": true
9383
9483
  }
9384
9484
  )
@@ -10080,7 +10180,7 @@ function SaleBadge({
10080
10180
  "%"
10081
10181
  ] }),
10082
10182
  /* @__PURE__ */ jsxRuntime.jsx("span", { "data-cimplify-sale-label": true, className: classNames?.label, children: badgeText }),
10083
- showOriginalPrice && onSale && /* @__PURE__ */ jsxRuntime.jsx("span", { "data-cimplify-sale-original-price": true, className: classNames?.originalPrice, children: /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: chunk7Y2O3E4D_js.getBasePrice(product) }) })
10183
+ showOriginalPrice && onSale && /* @__PURE__ */ jsxRuntime.jsx("span", { "data-cimplify-sale-original-price": true, className: classNames?.originalPrice, children: /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: chunk7Y2O3E4D_js.getBasePrice(product), currency: chunk7Y2O3E4D_js.getProductCurrency(product) }) })
10084
10184
  ]
10085
10185
  }
10086
10186
  );
@@ -10375,6 +10475,7 @@ function ProductSheet({
10375
10475
  Price,
10376
10476
  {
10377
10477
  amount: fullProduct.default_price,
10478
+ currency: chunk7Y2O3E4D_js.getProductCurrency(fullProduct),
10378
10479
  className: classNames?.price
10379
10480
  }
10380
10481
  )
@@ -10541,6 +10642,7 @@ function FoodProductCard({
10541
10642
  className
10542
10643
  }) {
10543
10644
  const image = product.image_url || product.images?.[0] || "";
10645
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
10544
10646
  const tags = product.tags || [];
10545
10647
  const isSignature = product.metadata?.is_signature === true;
10546
10648
  const isNew = product.metadata?.is_new === true;
@@ -10567,8 +10669,8 @@ function FoodProductCard({
10567
10669
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between mt-3", children: [
10568
10670
  isComposite ? /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-sm font-bold", children: [
10569
10671
  "From ",
10570
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price })
10571
- ] }) : /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-sm font-bold" }),
10672
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency })
10673
+ ] }) : /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-sm font-bold" }),
10572
10674
  tags.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex gap-1", children: tags.slice(0, 2).map((tag) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] font-medium text-muted-foreground px-1.5 py-0.5 bg-muted rounded", children: tag }, tag)) })
10573
10675
  ] })
10574
10676
  ] })
@@ -10596,6 +10698,7 @@ function RetailProductCard({
10596
10698
  className
10597
10699
  }) {
10598
10700
  const image = product.image_url || product.images?.[0] || "";
10701
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
10599
10702
  const outOfStock = product.inventory_status?.in_stock === false;
10600
10703
  const onSale = chunk7Y2O3E4D_js.isOnSale(product);
10601
10704
  const swatches = getColorSwatches(product);
@@ -10614,8 +10717,8 @@ function RetailProductCard({
10614
10717
  product.vendor && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[10px] font-semibold text-muted-foreground uppercase tracking-widest", children: product.vendor }),
10615
10718
  /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "text-[14.5px] font-semibold text-foreground leading-snug tracking-tight mt-1 truncate", children: product.name }),
10616
10719
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 mt-2", children: [
10617
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-sm font-bold" }),
10618
- onSale && /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: chunk7Y2O3E4D_js.getBasePrice(product), className: "text-xs text-muted-foreground line-through" })
10720
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-sm font-bold" }),
10721
+ onSale && /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: chunk7Y2O3E4D_js.getBasePrice(product), currency, className: "text-xs text-muted-foreground line-through" })
10619
10722
  ] }),
10620
10723
  swatches.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex gap-1.5 mt-2.5", children: swatches.map((name) => /* @__PURE__ */ jsxRuntime.jsx(
10621
10724
  "span",
@@ -10630,8 +10733,7 @@ function RetailProductCard({
10630
10733
  ] });
10631
10734
  }
10632
10735
  function PriceRange({ product, currency, className }) {
10633
- const context = useOptionalCimplify();
10634
- const resolvedCurrency = currency ?? context?.displayCurrency ?? "USD";
10736
+ const resolvedCurrency = currency ?? chunk7Y2O3E4D_js.getProductCurrency(product);
10635
10737
  const range = chunk7Y2O3E4D_js.getPriceRange(product);
10636
10738
  if (!range) return null;
10637
10739
  return /* @__PURE__ */ jsxRuntime.jsx("span", { "data-cimplify-price-range": true, className, children: chunk7Y2O3E4D_js.formatPriceRange(range.min, range.max, resolvedCurrency) });
@@ -10644,6 +10746,7 @@ function WholesaleProductCard({
10644
10746
  className
10645
10747
  }) {
10646
10748
  const image = product.image_url || product.images?.[0] || "";
10749
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
10647
10750
  const hasTiers = product.quantity_pricing && product.quantity_pricing.length > 1;
10648
10751
  const status = product.inventory_status;
10649
10752
  return /* @__PURE__ */ jsxRuntime.jsxs(CardShell, { product, renderLink, className, children: [
@@ -10663,7 +10766,7 @@ function WholesaleProductCard({
10663
10766
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "p-3.5", children: [
10664
10767
  product.sku && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[10px] text-muted-foreground font-mono", children: product.sku }),
10665
10768
  /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "text-[14.5px] font-semibold text-foreground leading-snug tracking-tight mt-1 truncate", children: product.name }),
10666
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-2", children: hasTiers ? /* @__PURE__ */ jsxRuntime.jsx(PriceRange, { product, className: "text-sm font-bold" }) : /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-sm font-bold" }) }),
10769
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-2", children: hasTiers ? /* @__PURE__ */ jsxRuntime.jsx(PriceRange, { product, className: "text-sm font-bold" }) : /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-sm font-bold" }) }),
10667
10770
  status && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-1.5 mt-2", children: [
10668
10771
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn(
10669
10772
  "w-[7px] h-[7px] rounded-full shrink-0",
@@ -10691,6 +10794,7 @@ function DigitalProductCard({
10691
10794
  className
10692
10795
  }) {
10693
10796
  const image = product.image_url || product.images?.[0] || "";
10797
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
10694
10798
  const typeBadge = product.digital_type ? TYPE_BADGES[product.digital_type] : null;
10695
10799
  const isTicket = product.digital_type === "event_ticket";
10696
10800
  return /* @__PURE__ */ jsxRuntime.jsxs(CardShell, { product, renderLink, className, children: [
@@ -10704,7 +10808,7 @@ function DigitalProductCard({
10704
10808
  ] }),
10705
10809
  !isTicket && product.description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-[12px] text-muted-foreground mt-1 line-clamp-1", children: stripHtmlToText(product.description) }),
10706
10810
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between mt-2.5", children: [
10707
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-sm font-bold" }),
10811
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-sm font-bold" }),
10708
10812
  product.file_type && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-[10px] text-muted-foreground bg-muted px-1.5 py-0.5 rounded", children: [
10709
10813
  product.file_type.toUpperCase(),
10710
10814
  product.file_size_mb != null && ` \xB7 ${product.file_size_mb >= 1024 ? `${(product.file_size_mb / 1024).toFixed(1)}GB` : `${product.file_size_mb}MB`}`
@@ -10721,6 +10825,7 @@ function BundleProductCard({
10721
10825
  className
10722
10826
  }) {
10723
10827
  const image = product.image_url || product.images?.[0] || "";
10828
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
10724
10829
  const components = product.components || [];
10725
10830
  const componentCount = components.length;
10726
10831
  const onSale = chunk7Y2O3E4D_js.isOnSale(product);
@@ -10749,9 +10854,9 @@ function BundleProductCard({
10749
10854
  components.map((c) => c.product_name || c.product_id).join(", ")
10750
10855
  ] }),
10751
10856
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 mt-2.5", children: [
10752
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-sm font-bold" }),
10857
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-sm font-bold" }),
10753
10858
  onSale && product.bundle_price && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
10754
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: chunk7Y2O3E4D_js.getBasePrice(product), className: "text-xs text-muted-foreground line-through" }),
10859
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: chunk7Y2O3E4D_js.getBasePrice(product), currency, className: "text-xs text-muted-foreground line-through" }),
10755
10860
  discount != null && discount > 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-[10px] font-semibold text-emerald-600", children: [
10756
10861
  "Save ",
10757
10862
  discount,
@@ -10771,6 +10876,7 @@ function CompositeProductCard({
10771
10876
  className
10772
10877
  }) {
10773
10878
  const image = product.image_url || product.images?.[0] || "";
10879
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
10774
10880
  const groups = product.groups || [];
10775
10881
  const groupCount = groups.length;
10776
10882
  groups.reduce((sum, g) => sum + g.components.length, 0);
@@ -10798,7 +10904,7 @@ function CompositeProductCard({
10798
10904
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between mt-2.5", children: [
10799
10905
  /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-sm font-bold", children: [
10800
10906
  "From ",
10801
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price })
10907
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency })
10802
10908
  ] }),
10803
10909
  tags.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] font-medium text-muted-foreground px-1.5 py-0.5 bg-muted rounded", children: tags[0] })
10804
10910
  ] })
@@ -10822,12 +10928,13 @@ function StandardServiceCard({
10822
10928
  className
10823
10929
  }) {
10824
10930
  const image = product.image_url || product.images?.[0] || "";
10931
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
10825
10932
  const hasDeposit = product.deposit_type && product.deposit_type !== "none" && product.deposit_amount;
10826
10933
  return /* @__PURE__ */ jsxRuntime.jsxs(CardShell, { product, renderLink, className, children: [
10827
10934
  /* @__PURE__ */ jsxRuntime.jsxs(CardImage, { src: image, alt: product.name, aspectRatio: "16/9", renderImage, children: [
10828
10935
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 bg-gradient-to-t from-black/50 to-transparent pointer-events-none" }),
10829
10936
  product.duration_minutes != null && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute bottom-3 left-3 inline-flex items-center gap-1 text-[12px] font-semibold px-2.5 py-1 rounded-lg bg-background/92 backdrop-blur-xl text-foreground shadow-sm", children: formatDuration3(product.duration_minutes, product.duration_unit) }),
10830
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute bottom-3 right-3 text-white font-bold text-lg drop-shadow-sm", children: /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price }) })
10937
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute bottom-3 right-3 text-white font-bold text-lg drop-shadow-sm", children: /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency }) })
10831
10938
  ] }),
10832
10939
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "p-4", children: [
10833
10940
  /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "text-[14.5px] font-bold text-foreground leading-snug tracking-tight", children: product.name }),
@@ -10839,7 +10946,7 @@ function StandardServiceCard({
10839
10946
  hasDeposit && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
10840
10947
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-border", children: "\xB7" }),
10841
10948
  /* @__PURE__ */ jsxRuntime.jsxs("span", { children: [
10842
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.deposit_amount }),
10949
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.deposit_amount, currency }),
10843
10950
  " deposit"
10844
10951
  ] })
10845
10952
  ] })
@@ -10876,6 +10983,7 @@ function CompactServiceCard({
10876
10983
  className
10877
10984
  }) {
10878
10985
  const image = product.image_url || product.images?.[0] || "";
10986
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
10879
10987
  const hasDeposit = product.deposit_type && product.deposit_type !== "none" && product.deposit_amount;
10880
10988
  const hasBillingPlans = product.billing_plans && product.billing_plans.length > 0;
10881
10989
  const href = `/products/${product.slug}`;
@@ -10891,14 +10999,14 @@ function CompactServiceCard({
10891
10999
  "Available"
10892
11000
  ] }),
10893
11001
  hasDeposit && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-[10.5px] font-medium text-amber-600", children: [
10894
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.deposit_amount }),
11002
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.deposit_amount, currency }),
10895
11003
  " deposit"
10896
11004
  ] }),
10897
11005
  hasBillingPlans && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "inline-flex items-center gap-0.5 text-[10.5px] font-semibold text-primary px-1.5 py-0.5 bg-primary/10 rounded", children: "Subscription" })
10898
11006
  ] })
10899
11007
  ] }),
10900
11008
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 shrink-0", children: [
10901
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-sm font-bold" }),
11009
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-sm font-bold" }),
10902
11010
  /* @__PURE__ */ jsxRuntime.jsx("svg", { className: "w-4 h-4 text-muted-foreground group-hover:text-primary transition-colors", fill: "none", stroke: "currentColor", strokeWidth: "2", viewBox: "0 0 24 24", children: /* @__PURE__ */ jsxRuntime.jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M9 5l7 7-7 7" }) })
10903
11011
  ] })
10904
11012
  ] });
@@ -10924,6 +11032,7 @@ function ScheduleServiceCard({
10924
11032
  className
10925
11033
  }) {
10926
11034
  const image = product.image_url || product.images?.[0] || "";
11035
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
10927
11036
  const href = `/products/${product.slug}`;
10928
11037
  const durationLabel = product.duration_minutes != null ? formatDuration2(product.duration_minutes, product.duration_unit) : null;
10929
11038
  const displaySlots = (slots || []).slice(0, 3);
@@ -10943,7 +11052,7 @@ function ScheduleServiceCard({
10943
11052
  durationLabel,
10944
11053
  " \xB7 "
10945
11054
  ] }),
10946
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price })
11055
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency })
10947
11056
  ] })
10948
11057
  ] }),
10949
11058
  image && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-14 h-14 rounded-xl overflow-hidden bg-muted shrink-0", children: renderImage ? renderImage({ src: image, alt: product.name, className: "w-full h-full object-cover" }) : /* @__PURE__ */ jsxRuntime.jsx("img", { src: image, alt: product.name, className: "w-full h-full object-cover" }) })
@@ -10995,6 +11104,7 @@ function RentalServiceCard({
10995
11104
  className
10996
11105
  }) {
10997
11106
  const image = product.image_url || product.images?.[0] || "";
11107
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
10998
11108
  const hasDeposit = product.deposit_type && product.deposit_type !== "none" && product.deposit_amount;
10999
11109
  const unit = product.duration_unit ? UNIT_LABELS2[product.duration_unit] || product.duration_unit : "day";
11000
11110
  const status = product.inventory_status;
@@ -11006,7 +11116,7 @@ function RentalServiceCard({
11006
11116
  unit
11007
11117
  ] }),
11008
11118
  /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "absolute bottom-3 right-3 text-white font-bold text-lg drop-shadow-sm", children: [
11009
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price }),
11119
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency }),
11010
11120
  "/",
11011
11121
  unit
11012
11122
  ] }),
@@ -11028,7 +11138,7 @@ function RentalServiceCard({
11028
11138
  product.min_order_quantity > 1 ? "s" : ""
11029
11139
  ] }),
11030
11140
  hasDeposit && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-[10.5px] font-medium text-amber-600", children: [
11031
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.deposit_amount }),
11141
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.deposit_amount, currency }),
11032
11142
  " deposit"
11033
11143
  ] })
11034
11144
  ] }),
@@ -11064,6 +11174,7 @@ function AccommodationCard({
11064
11174
  className
11065
11175
  }) {
11066
11176
  const image = product.image_url || product.images?.[0] || "";
11177
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
11067
11178
  const hasTiers = product.quantity_pricing && product.quantity_pricing.length > 1;
11068
11179
  const cancellationHours = product.cancellation_window_minutes ? Math.floor(product.cancellation_window_minutes / 60) : null;
11069
11180
  const tags = product.tags || [];
@@ -11072,7 +11183,7 @@ function AccommodationCard({
11072
11183
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 bg-gradient-to-t from-black/50 to-transparent pointer-events-none" }),
11073
11184
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute bottom-3 left-3 inline-flex items-center text-[12px] font-semibold px-2.5 py-1 rounded-lg bg-background/92 backdrop-blur-xl text-foreground shadow-sm", children: "Per night" }),
11074
11185
  /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "absolute bottom-3 right-3 text-white font-bold text-lg drop-shadow-sm", children: [
11075
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price }),
11186
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency }),
11076
11187
  "/night"
11077
11188
  ] })
11078
11189
  ] }),
@@ -11129,6 +11240,7 @@ function LeaseServiceCard({
11129
11240
  className
11130
11241
  }) {
11131
11242
  const image = product.image_url || product.images?.[0] || "";
11243
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
11132
11244
  const hasDeposit = product.deposit_type && product.deposit_type !== "none" && product.deposit_amount;
11133
11245
  const hasTiers = product.quantity_pricing && product.quantity_pricing.length > 1;
11134
11246
  const unit = product.duration_unit ? UNIT_LABELS3[product.duration_unit] || product.duration_unit : "mo";
@@ -11142,7 +11254,7 @@ function LeaseServiceCard({
11142
11254
  unit
11143
11255
  ] }),
11144
11256
  /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "absolute bottom-3 right-3 text-white font-bold text-lg drop-shadow-sm", children: [
11145
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price }),
11257
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency }),
11146
11258
  "/",
11147
11259
  unit
11148
11260
  ] })
@@ -11161,7 +11273,7 @@ function LeaseServiceCard({
11161
11273
  product.min_order_quantity > 1 ? "s" : ""
11162
11274
  ] }),
11163
11275
  hasDeposit && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-[10.5px] font-medium text-amber-600", children: [
11164
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.deposit_amount }),
11276
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.deposit_amount, currency }),
11165
11277
  " deposit"
11166
11278
  ] }),
11167
11279
  cancellationHours != null && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10.5px] font-medium text-muted-foreground", children: cancellationHours >= 720 ? `${Math.floor(cancellationHours / 720)} month notice` : `${cancellationHours}h notice` })
@@ -11202,6 +11314,7 @@ function SubscriptionCard({
11202
11314
  className
11203
11315
  }) {
11204
11316
  const image = product.image_url || product.images?.[0] || "";
11317
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
11205
11318
  const plans = product.billing_plans || [];
11206
11319
  const primaryPlan = plans[0];
11207
11320
  const frequency = primaryPlan?.frequency ? FREQUENCY_LABELS2[primaryPlan.frequency] || `/${primaryPlan.frequency}` : "/mo";
@@ -11211,7 +11324,7 @@ function SubscriptionCard({
11211
11324
  /* @__PURE__ */ jsxRuntime.jsxs(CardImage, { src: image, alt: product.name, aspectRatio: "16/9", renderImage, children: [
11212
11325
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 bg-gradient-to-t from-black/50 to-transparent pointer-events-none" }),
11213
11326
  /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "absolute bottom-3 right-3 text-white font-bold text-lg drop-shadow-sm", children: [
11214
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price }),
11327
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency }),
11215
11328
  frequency
11216
11329
  ] }),
11217
11330
  hasTrial && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "absolute top-3 left-3 text-[11px] font-semibold tracking-wide bg-emerald-50/90 text-emerald-700 border border-emerald-200/50 backdrop-blur px-2 py-0.5 rounded-md", children: [
@@ -11240,7 +11353,7 @@ function SubscriptionCard({
11240
11353
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 text-[11px] text-muted-foreground", children: [
11241
11354
  hasTrial && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-emerald-600 font-medium", children: "Free trial" }),
11242
11355
  primaryPlan?.setup_fee != null && primaryPlan.setup_fee > 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { children: [
11243
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: primaryPlan.setup_fee }),
11356
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: primaryPlan.setup_fee, currency }),
11244
11357
  " setup"
11245
11358
  ] })
11246
11359
  ] }),
@@ -11403,7 +11516,7 @@ function ProductCard({
11403
11516
  /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-product-card-body": true, className: cn("p-4 flex flex-col gap-1", classNames?.body), children: [
11404
11517
  /* @__PURE__ */ jsxRuntime.jsx("span", { "data-cimplify-product-card-name": true, className: cn("font-semibold text-foreground leading-tight", classNames?.name), children: product.name }),
11405
11518
  descriptionPreview && /* @__PURE__ */ jsxRuntime.jsx("span", { "data-cimplify-product-card-description": true, className: cn("text-sm text-muted-foreground line-clamp-2", classNames?.description), children: descriptionPreview }),
11406
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: cn("text-sm font-medium text-foreground mt-1", classNames?.price) })
11519
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency: chunk7Y2O3E4D_js.getProductCurrency(product), className: cn("text-sm font-medium text-foreground mt-1", classNames?.price) })
11407
11520
  ] })
11408
11521
  ] });
11409
11522
  })();
@@ -12746,6 +12859,7 @@ function BookingPage({
12746
12859
  }) {
12747
12860
  const { addItem } = useCart();
12748
12861
  const { client } = useCimplifyClient();
12862
+ const currency = service.currency;
12749
12863
  const isReschedule = existingBooking !== void 0;
12750
12864
  const [step, setStep] = React14.useState(STEP.SELECT_SLOT);
12751
12865
  const [selectedSlot, setSelectedSlot] = React14.useState(null);
@@ -12887,10 +13001,10 @@ function BookingPage({
12887
13001
  /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-booking-service-info": true, className: classNames?.serviceInfo, children: [
12888
13002
  /* @__PURE__ */ jsxRuntime.jsx("span", { "data-cimplify-booking-service-name": true, children: service.name }),
12889
13003
  /* @__PURE__ */ jsxRuntime.jsx("span", { "data-cimplify-booking-service-duration": true, children: formatDuration2(service.duration_minutes, service.duration_unit) }),
12890
- service.price && /* @__PURE__ */ jsxRuntime.jsx("span", { "data-cimplify-booking-service-price": true, children: /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: service.price }) }),
13004
+ service.price && /* @__PURE__ */ jsxRuntime.jsx("span", { "data-cimplify-booking-service-price": true, children: /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: service.price, currency }) }),
12891
13005
  hasDeposit && /* @__PURE__ */ jsxRuntime.jsxs("span", { "data-cimplify-booking-deposit-info": true, className: classNames?.depositInfo, children: [
12892
13006
  "Deposit: ",
12893
- depositType === "percentage" ? `${chunk7Y2O3E4D_js.parsePrice(depositAmount)}%` : /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: depositAmount })
13007
+ depositType === "percentage" ? `${chunk7Y2O3E4D_js.parsePrice(depositAmount)}%` : /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: depositAmount, currency })
12894
13008
  ] }),
12895
13009
  cancellationMinutes !== void 0 && cancellationMinutes > 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { "data-cimplify-booking-cancellation-policy": true, className: classNames?.cancellationPolicy, children: [
12896
13010
  "Free cancellation up to ",
@@ -12899,7 +13013,7 @@ function BookingPage({
12899
13013
  ] }),
12900
13014
  noShowFee !== void 0 && chunk7Y2O3E4D_js.parsePrice(noShowFee) !== 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { "data-cimplify-booking-no-show-fee": true, className: classNames?.cancellationPolicy, children: [
12901
13015
  "No-show fee: ",
12902
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: noShowFee })
13016
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: noShowFee, currency })
12903
13017
  ] })
12904
13018
  ] }),
12905
13019
  error && /* @__PURE__ */ jsxRuntime.jsx("div", { "data-cimplify-booking-error": true, className: classNames?.error, children: error }),
@@ -12912,7 +13026,8 @@ function BookingPage({
12912
13026
  participantCount,
12913
13027
  selectedSlot,
12914
13028
  onSlotSelect: handleSlotSelect,
12915
- showPrice
13029
+ showPrice,
13030
+ currency
12916
13031
  }
12917
13032
  )
12918
13033
  ] }),
@@ -12970,11 +13085,11 @@ function BookingPage({
12970
13085
  ] }),
12971
13086
  (selectedSlot.price || service.price) && /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-booking-summary-row": true, className: classNames?.summaryRow, children: [
12972
13087
  /* @__PURE__ */ jsxRuntime.jsx("span", { children: "Price" }),
12973
- /* @__PURE__ */ jsxRuntime.jsx("span", { children: /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: selectedSlot.price || service.price }) })
13088
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: selectedSlot.price || service.price, currency }) })
12974
13089
  ] }),
12975
13090
  hasDeposit && /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-booking-summary-row": true, className: cn(classNames?.summaryRow, classNames?.depositInfo), children: [
12976
13091
  /* @__PURE__ */ jsxRuntime.jsx("span", { children: "Deposit" }),
12977
- /* @__PURE__ */ jsxRuntime.jsx("span", { children: depositType === "percentage" ? `${chunk7Y2O3E4D_js.parsePrice(depositAmount)}%` : /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: depositAmount }) })
13092
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: depositType === "percentage" ? `${chunk7Y2O3E4D_js.parsePrice(depositAmount)}%` : /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: depositAmount, currency }) })
12978
13093
  ] })
12979
13094
  ] }),
12980
13095
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -13638,6 +13753,7 @@ function DefaultProductLayout({
13638
13753
  }) {
13639
13754
  const [selectedVariantId, setSelectedVariantId] = React14__default.default.useState();
13640
13755
  const images = chunkIQLJJW2H_js.resolveGallery(product, selectedVariantId);
13756
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
13641
13757
  const hasRange = product.quantity_pricing && product.quantity_pricing.length > 1 || product.variants && product.variants.length > 1;
13642
13758
  const onSale = chunk7Y2O3E4D_js.isOnSale(product);
13643
13759
  const hasPhysicalDetails = product.sku || product.vendor || product.material;
@@ -13659,15 +13775,15 @@ function DefaultProductLayout({
13659
13775
  /* @__PURE__ */ jsxRuntime.jsx(TagPills, { tags: product.tags || [] })
13660
13776
  ] }),
13661
13777
  /* @__PURE__ */ jsxRuntime.jsx("h1", { "data-cimplify-product-layout-name": true, className: "text-3xl lg:text-4xl font-extrabold tracking-tight", children: product.name }),
13662
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-baseline gap-3", children: hasRange ? /* @__PURE__ */ jsxRuntime.jsx(PriceRange, { product, className: "text-2xl font-extrabold" }) : onSale ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
13663
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-2xl font-extrabold" }),
13664
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: chunk7Y2O3E4D_js.getBasePrice(product), className: "text-lg text-muted-foreground line-through" }),
13778
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-baseline gap-3", children: hasRange ? /* @__PURE__ */ jsxRuntime.jsx(PriceRange, { product, currency, className: "text-2xl font-extrabold" }) : onSale ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
13779
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-2xl font-extrabold" }),
13780
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: chunk7Y2O3E4D_js.getBasePrice(product), currency, className: "text-lg text-muted-foreground line-through" }),
13665
13781
  /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-sm font-bold text-destructive bg-destructive/10 px-2 py-0.5", children: [
13666
13782
  "Save ",
13667
13783
  chunk7Y2O3E4D_js.getDiscountPercentage(product),
13668
13784
  "%"
13669
13785
  ] })
13670
- ] }) : /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-2xl font-semibold" }) }),
13786
+ ] }) : /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-2xl font-semibold" }) }),
13671
13787
  /* @__PURE__ */ jsxRuntime.jsx(InventoryBadge, { product }),
13672
13788
  /* @__PURE__ */ jsxRuntime.jsx(RichText, { html: product.description, "data-cimplify-product-layout-description": true }),
13673
13789
  hasPhysicalDetails && /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-product-layout-details": true, className: "space-y-1 text-sm text-muted-foreground", children: [
@@ -13726,6 +13842,7 @@ function FoodProductLayout({
13726
13842
  className
13727
13843
  }) {
13728
13844
  const images = product.images || (product.image_url ? [product.image_url] : []);
13845
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
13729
13846
  const tags = product.tags || [];
13730
13847
  const ingredients = getMetadataStringList(product.metadata, "ingredients");
13731
13848
  const pairings = getMetadataStringList(product.metadata, "pairings");
@@ -13751,7 +13868,7 @@ function FoodProductLayout({
13751
13868
  ] }),
13752
13869
  /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
13753
13870
  /* @__PURE__ */ jsxRuntime.jsx("h1", { "data-cimplify-product-layout-name": true, className: "text-3xl lg:text-4xl font-bold tracking-tight", children: product.name }),
13754
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-2xl font-semibold mt-2 block" })
13871
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-2xl font-semibold mt-2 block" })
13755
13872
  ] }),
13756
13873
  (product.calories != null || product.preparation_time_minutes != null) && /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-product-layout-stats": true, className: "flex flex-wrap gap-4 py-3 border-y border-border", children: [
13757
13874
  product.preparation_time_minutes != null && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "flex items-center gap-1.5 text-sm text-muted-foreground", children: [
@@ -13800,6 +13917,7 @@ function WholesaleProductLayout({
13800
13917
  className
13801
13918
  }) {
13802
13919
  const images = product.images || (product.image_url ? [product.image_url] : []);
13920
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
13803
13921
  const hasTiers = product.quantity_pricing && product.quantity_pricing.length > 1;
13804
13922
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-product-layout": "wholesale", className: cn("space-y-8", className), children: [
13805
13923
  renderBreadcrumb?.(product),
@@ -13822,7 +13940,7 @@ function WholesaleProductLayout({
13822
13940
  ] }),
13823
13941
  /* @__PURE__ */ jsxRuntime.jsx("h1", { "data-cimplify-product-layout-name": true, className: "text-3xl lg:text-4xl font-extrabold tracking-tight", children: product.name })
13824
13942
  ] }),
13825
- /* @__PURE__ */ jsxRuntime.jsx("div", { children: hasTiers ? /* @__PURE__ */ jsxRuntime.jsx(PriceRange, { product, className: "text-2xl font-extrabold" }) : /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-2xl font-semibold" }) }),
13943
+ /* @__PURE__ */ jsxRuntime.jsx("div", { children: hasTiers ? /* @__PURE__ */ jsxRuntime.jsx(PriceRange, { product, currency, className: "text-2xl font-extrabold" }) : /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-2xl font-semibold" }) }),
13826
13944
  /* @__PURE__ */ jsxRuntime.jsx(InventoryBadge, { product }),
13827
13945
  product.min_order_quantity != null && product.min_order_quantity > 1 && /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-product-layout-moq": true, className: "flex items-center gap-3 p-3 bg-amber-50 border border-amber-200 text-sm text-amber-800", children: [
13828
13946
  "Minimum order quantity: ",
@@ -13883,6 +14001,7 @@ function ServiceProductLayout({
13883
14001
  className
13884
14002
  }) {
13885
14003
  const images = product.images || (product.image_url ? [product.image_url] : []);
14004
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
13886
14005
  const hasDeposit = product.deposit_type && product.deposit_type !== "none" && product.deposit_amount;
13887
14006
  const depositAmount = hasDeposit ? chunk7Y2O3E4D_js.parsePrice(product.deposit_amount) : 0;
13888
14007
  const cancellationHours = product.cancellation_window_minutes ? Math.floor(product.cancellation_window_minutes / 60) : null;
@@ -13902,12 +14021,12 @@ function ServiceProductLayout({
13902
14021
  /* @__PURE__ */ jsxRuntime.jsx(TagPills, { tags: product.tags || [] }),
13903
14022
  /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
13904
14023
  /* @__PURE__ */ jsxRuntime.jsx("h1", { "data-cimplify-product-layout-name": true, className: "text-3xl lg:text-4xl font-extrabold tracking-tight", children: product.name }),
13905
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-2xl font-bold text-primary mt-2 block" })
14024
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-2xl font-bold text-primary mt-2 block" })
13906
14025
  ] }),
13907
14026
  /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-product-layout-service-info": true, className: "flex flex-wrap gap-2", children: [
13908
14027
  product.duration_minutes != null && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "inline-flex items-center gap-1.5 px-3 py-1.5 bg-muted text-sm text-muted-foreground rounded-full", children: formatDuration2(product.duration_minutes, product.duration_unit) }),
13909
14028
  hasDeposit && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "inline-flex items-center gap-1.5 px-3 py-1.5 bg-muted text-sm text-muted-foreground rounded-full", children: [
13910
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: depositAmount }),
14029
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: depositAmount, currency }),
13911
14030
  " deposit"
13912
14031
  ] }),
13913
14032
  product.general_service_capacity != null && product.general_service_capacity > 1 && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "inline-flex items-center gap-1.5 px-3 py-1.5 bg-muted text-sm text-muted-foreground rounded-full", children: [
@@ -13946,10 +14065,10 @@ function ServiceProductLayout({
13946
14065
  ] }),
13947
14066
  product.no_show_fee && /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-muted-foreground", children: [
13948
14067
  "No-show fee: ",
13949
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.no_show_fee, className: "font-medium text-foreground" })
14068
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.no_show_fee, currency, className: "font-medium text-foreground" })
13950
14069
  ] }),
13951
14070
  hasDeposit && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: product.deposit_type === "fixed" ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
13952
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: depositAmount, className: "font-medium text-foreground" }),
14071
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: depositAmount, currency, className: "font-medium text-foreground" }),
13953
14072
  " deposit charged at booking"
13954
14073
  ] }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
13955
14074
  chunk7Y2O3E4D_js.parsePrice(product.deposit_amount),
@@ -13984,6 +14103,7 @@ function DigitalProductLayout({
13984
14103
  className
13985
14104
  }) {
13986
14105
  const images = product.images || (product.image_url ? [product.image_url] : []);
14106
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
13987
14107
  const typeLabel = product.digital_type ? DIGITAL_TYPE_LABELS[product.digital_type] || product.digital_type : "Digital product";
13988
14108
  const isTicket = product.digital_type === "event_ticket";
13989
14109
  const isAccessPass = product.digital_type === "access_pass";
@@ -14007,7 +14127,7 @@ function DigitalProductLayout({
14007
14127
  ] }),
14008
14128
  /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
14009
14129
  /* @__PURE__ */ jsxRuntime.jsx("h1", { "data-cimplify-product-layout-name": true, className: "text-3xl lg:text-4xl font-extrabold tracking-tight", children: product.name }),
14010
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-2xl font-bold mt-2 block" })
14130
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-2xl font-bold mt-2 block" })
14011
14131
  ] }),
14012
14132
  /* @__PURE__ */ jsxRuntime.jsx(RichText, { html: product.description, "data-cimplify-product-layout-description": true }),
14013
14133
  isDownload && /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-product-layout-delivery": true, className: "flex items-center gap-3 px-4 py-3 bg-muted rounded-lg", children: [
@@ -14110,6 +14230,7 @@ function BundleProductLayout({
14110
14230
  className
14111
14231
  }) {
14112
14232
  const images = product.images || (product.image_url ? [product.image_url] : []);
14233
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
14113
14234
  const components = product.components || [];
14114
14235
  const onSale = chunk7Y2O3E4D_js.isOnSale(product);
14115
14236
  const discount = chunk7Y2O3E4D_js.getDiscountPercentage(product);
@@ -14144,8 +14265,8 @@ function BundleProductLayout({
14144
14265
  /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
14145
14266
  /* @__PURE__ */ jsxRuntime.jsx("h1", { "data-cimplify-product-layout-name": true, className: "text-3xl lg:text-4xl font-bold tracking-tight", children: product.name }),
14146
14267
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-baseline gap-3 mt-2", children: [
14147
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "text-2xl font-bold" }),
14148
- onSale && baseTotal > 0 && /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: baseTotal, className: "text-lg text-muted-foreground line-through" })
14268
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "text-2xl font-bold" }),
14269
+ onSale && baseTotal > 0 && /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: baseTotal, currency, className: "text-lg text-muted-foreground line-through" })
14149
14270
  ] })
14150
14271
  ] }),
14151
14272
  /* @__PURE__ */ jsxRuntime.jsx(RichText, { html: product.description, "data-cimplify-product-layout-description": true }),
@@ -14161,13 +14282,13 @@ function BundleProductLayout({
14161
14282
  ] }),
14162
14283
  component.allow_variant_choice && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-violet-600 font-medium", children: "Choose variant" })
14163
14284
  ] }),
14164
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: component.effective_price ?? 0, className: "text-sm text-muted-foreground shrink-0" })
14285
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: component.effective_price ?? 0, currency, className: "text-sm text-muted-foreground shrink-0" })
14165
14286
  ] }, component.id)) })
14166
14287
  ] }),
14167
14288
  savings > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-bundle-savings": true, className: "flex items-center gap-2 p-3 bg-emerald-50 border border-emerald-200/60 text-sm text-emerald-800", children: [
14168
14289
  /* @__PURE__ */ jsxRuntime.jsx("svg", { className: "w-4 h-4 shrink-0", fill: "none", stroke: "currentColor", strokeWidth: "2", viewBox: "0 0 24 24", children: /* @__PURE__ */ jsxRuntime.jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M5 13l4 4L19 7" }) }),
14169
14290
  "You save ",
14170
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: savings, className: "font-semibold" }),
14291
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: savings, currency, className: "font-semibold" }),
14171
14292
  " with this bundle"
14172
14293
  ] }),
14173
14294
  /* @__PURE__ */ jsxRuntime.jsx(CustomAttributesTable, { attributes: product.custom_attributes || [] }),
@@ -14193,6 +14314,7 @@ function CompositeProductLayout({
14193
14314
  className
14194
14315
  }) {
14195
14316
  const images = product.images || (product.image_url ? [product.image_url] : []);
14317
+ const currency = chunk7Y2O3E4D_js.getProductCurrency(product);
14196
14318
  const groups = product.groups || [];
14197
14319
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-cimplify-product-layout": "composite", className: cn("space-y-8", className), children: [
14198
14320
  renderBreadcrumb?.(product),
@@ -14220,7 +14342,7 @@ function CompositeProductLayout({
14220
14342
  /* @__PURE__ */ jsxRuntime.jsx("h1", { "data-cimplify-product-layout-name": true, className: "text-3xl lg:text-4xl font-bold tracking-tight", children: product.name }),
14221
14343
  /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-lg text-muted-foreground mt-2", children: [
14222
14344
  "From ",
14223
- /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, className: "font-semibold text-foreground" })
14345
+ /* @__PURE__ */ jsxRuntime.jsx(Price, { amount: product.default_price, currency, className: "font-semibold text-foreground" })
14224
14346
  ] })
14225
14347
  ] }),
14226
14348
  /* @__PURE__ */ jsxRuntime.jsx(RichText, { html: product.description, "data-cimplify-product-layout-description": true }),