@kachingappz/bundles-js 0.3.7 → 1.0.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.
@@ -0,0 +1,1082 @@
1
+ import { JSX as JSX_2 } from 'react';
2
+
3
+ declare type AddPersonalisationModal = {
4
+ size: number;
5
+ roundness: number;
6
+ heading: string;
7
+ placeholderText: string;
8
+ lettersAllowed?: boolean;
9
+ numbersAllowed?: boolean;
10
+ characterLimitEnabled: boolean;
11
+ characterLimit: number;
12
+ imageSize: number;
13
+ textSize: number;
14
+ overlayColor: Color;
15
+ primaryTextColor: Color;
16
+ secondaryTextColor: Color;
17
+ buttonColor: Color;
18
+ buttonTextColor: Color;
19
+ errorColor: Color;
20
+ };
21
+
22
+ declare type Badge = SimpleBadge | MostPopularBadge | CustomBadge | BorderBadge;
23
+
24
+ declare type BadgeAttachedTo = {
25
+ type: "block";
26
+ } | {
27
+ type: "dealBar";
28
+ dealBarId: string;
29
+ } | {
30
+ type: "checkboxUpsell";
31
+ upsellId: string;
32
+ } | {
33
+ type: "barUpsell";
34
+ dealBarId: string;
35
+ upsellId: string;
36
+ };
37
+
38
+ declare type BadgeColors = {
39
+ text: Color;
40
+ background: Color;
41
+ };
42
+
43
+ declare type BadgeStyle = "simple" | "most-popular" | "custom";
44
+
45
+ declare type BaseBadge = {
46
+ id: string;
47
+ attachedTo: BadgeAttachedTo;
48
+ text: string;
49
+ colors: BadgeColors | null;
50
+ };
51
+
52
+ declare interface BaseDealBar {
53
+ id: string;
54
+ dealBarType?: DealBarType;
55
+ title: string;
56
+ subtitle: string;
57
+ label: string;
58
+ badgeStyle: BadgeStyle;
59
+ badgeText: string;
60
+ badgeImageGID: string | null;
61
+ mediaImageGID: string | null;
62
+ featuredMediaGID?: string | null;
63
+ featuredProductGID?: string | null;
64
+ featuredImages?: DealBarFeaturedImage[];
65
+ freeGifts: FreeGift[];
66
+ freeGiftsSummary?: FreeGiftsSummary | null;
67
+ multipleGiftsSelectors?: MultipleGiftsSelector[];
68
+ upsells: Upsell[];
69
+ productPersonalisation: ProductPersonalisation | null;
70
+ highlights?: Highlights | null;
71
+ sellingPlanEnabled?: boolean;
72
+ sellingPlanGid?: string | null;
73
+ hideBehindScratchOff?: boolean;
74
+ }
75
+
76
+ declare type BlockLayout = "vertical" | "horizontal" | "grid" | "plain";
77
+
78
+ declare type BlockVisibility = "all-products" | "excluded-products" | "selected-products" | "selected-collections";
79
+
80
+ declare type BorderBadge = BaseBadge & {
81
+ badgeType: "border";
82
+ position: "all" | "top" | "bottom" | "left" | "right";
83
+ thickness: number;
84
+ gap?: number;
85
+ textSize: number;
86
+ spacing: number;
87
+ repeatText: boolean;
88
+ delimiter?: string;
89
+ animated: boolean;
90
+ spinSpeed: number;
91
+ spinDirection: "clockwise" | "counterclockwise";
92
+ };
93
+
94
+ declare const BRAND_COLOR_KEYS: readonly ["primaryBackground", "secondaryBackground", "primaryText", "secondaryText", "border", "overlay", "primaryAccent", "primaryAccentText", "badgeBackground", "badgeText", "error"];
95
+
96
+ declare type BrandColorKey = (typeof BRAND_COLOR_KEYS)[number];
97
+
98
+ declare type BrandColors = Record<BrandColorKey, string>;
99
+
100
+ declare interface BundleDealBar extends BaseDealBar, ShowAsSoldOutFeature, RequireVariantSelectionFeature {
101
+ dealBarType: DealBarType.Bundle;
102
+ layout?: "horizontal" | "vertical";
103
+ quantitySelector: boolean;
104
+ showProductsOnlyWhenSelected?: boolean;
105
+ bundleProducts: BundleProduct[];
106
+ }
107
+
108
+ declare interface BundleProduct {
109
+ id: string;
110
+ productGID: string | null;
111
+ variantGIDs: string[] | null;
112
+ defaultVariantGID: string | null;
113
+ quantity: number;
114
+ discountType: DiscountType;
115
+ discountValue: string | number;
116
+ mediaImageGID: string | null;
117
+ title?: string;
118
+ hidePrice?: boolean;
119
+ }
120
+
121
+ declare interface BxgyDealBar extends BaseDealBar, ShowAsSoldOutFeature, RequireVariantSelectionFeature {
122
+ dealBarType: DealBarType.Bxgy;
123
+ buyQuantity: number;
124
+ buyDiscountType?: DiscountType;
125
+ buyDiscountValue?: string | number;
126
+ getQuantity: number;
127
+ getDiscountType?: DiscountType;
128
+ getDiscountValue?: string | number;
129
+ }
130
+
131
+ declare type CheckboxUpsell = {
132
+ id: string;
133
+ productGID: string | null;
134
+ variantGIDs: string[] | null;
135
+ defaultVariantGID?: string | null;
136
+ mediaImageGID: string | null;
137
+ discountType: DiscountType;
138
+ discountValue: string | number;
139
+ title: string;
140
+ subtitle: string;
141
+ productSource?: "selected" | "complementary";
142
+ preselected: boolean;
143
+ showProductOptionsOnlyWhenSelected?: boolean;
144
+ matchQuantityWithDealBar: boolean;
145
+ quantitySelector?: boolean;
146
+ subscriptionEnabled?: boolean;
147
+ subscriptionType?: "deal" | "always";
148
+ badgeStyle?: BadgeStyle;
149
+ badgeText?: string;
150
+ badgeImageGID?: string | null;
151
+ };
152
+
153
+ declare type CheckboxUpsells = {
154
+ title?: string;
155
+ upsells: CheckboxUpsell[];
156
+ };
157
+
158
+ declare type ChooseMultipleGiftsModal = {
159
+ buttonSize: number;
160
+ textSize: number;
161
+ overlayColor: Color;
162
+ priceColor: Color;
163
+ compareAtPriceColor: Color;
164
+ textColor: Color;
165
+ buttonColor: Color;
166
+ buttonTextColor: Color;
167
+ productPhotoSize: number;
168
+ heading: string;
169
+ subtitle: string;
170
+ buttonTextBeforeSelection: string;
171
+ buttonTextAfterSelection: string;
172
+ footerText: string;
173
+ };
174
+
175
+ declare type ChooseProductModal = {
176
+ buttonSize: number;
177
+ textSize: number;
178
+ overlayColor: Color;
179
+ priceColor: Color;
180
+ compareAtPriceColor: Color;
181
+ textColor: Color;
182
+ buttonColor: Color;
183
+ buttonTextColor: Color;
184
+ productPhotoSize: number;
185
+ heading?: string;
186
+ subtitle?: string;
187
+ buttonText?: string;
188
+ showSearchField: boolean;
189
+ showVariantImageByDefault?: boolean;
190
+ defaultSortOption?: DefaultSortOption;
191
+ };
192
+
193
+ declare type CollectionBreaks = {
194
+ visibility: CollectionBreaksVisibility;
195
+ excludedProducts?: {
196
+ id: string;
197
+ }[];
198
+ selectedProducts?: {
199
+ id: string;
200
+ }[];
201
+ selectedCollections?: {
202
+ id: string;
203
+ }[];
204
+ mediaImageGID: string | null;
205
+ buttonText: string;
206
+ buttonColor: Color;
207
+ productPhotoSize: number;
208
+ showProductName: boolean;
209
+ showChosenProductsPriceOnly?: boolean;
210
+ autoFillNotChosenItems: boolean;
211
+ requireItemSelectionEnabled: boolean;
212
+ requireItemSelectionAlert: RequireItemSelectionAlert | null;
213
+ };
214
+
215
+ declare type CollectionBreaksVisibility = "excluded-products" | "selected-products" | "selected-collections" | "deal-products";
216
+
217
+ declare type Color = {
218
+ red: number;
219
+ green: number;
220
+ blue: number;
221
+ alpha: number;
222
+ };
223
+
224
+ declare type Currency = {
225
+ currencyCode: string;
226
+ currencyRate: number;
227
+ };
228
+
229
+ declare type CustomBadge = BaseBadge & {
230
+ badgeType: "custom";
231
+ imageGID: string | null;
232
+ size: number;
233
+ };
234
+
235
+ declare type DealBar = QuantityBreakDealBar | BxgyDealBar | BundleDealBar | MixAndMatchDealBar | SkuDealBar;
236
+
237
+ declare interface DealBarFeaturedImage {
238
+ productGID: string;
239
+ mediaGID: string;
240
+ }
241
+
242
+ declare type DealBarProgressiveGiftStyle = {
243
+ imageSize: number;
244
+ cornerRadius: number;
245
+ labelBackgroundColor: Color;
246
+ labelTextColor: Color;
247
+ labelTextSize: number;
248
+ textColor: Color;
249
+ selectedTextColor: Color;
250
+ textSize: number;
251
+ lockedLabelBackgroundColor: Color;
252
+ lockedLabelTextColor: Color;
253
+ lockedLabelTextSize: number;
254
+ lockedTextColor: Color;
255
+ lockedTextSize: number;
256
+ lockedIconColor: Color;
257
+ lockedMediaImageGID: string | null;
258
+ };
259
+
260
+ declare enum DealBarType {
261
+ QuantityBreak = "quantity-break",
262
+ Bxgy = "bxgy",
263
+ Bundle = "bundle",
264
+ MixAndMatch = "mix-and-match",
265
+ Sku = "sku"
266
+ }
267
+
268
+ declare type DealBlock = {
269
+ id: string;
270
+ nanoId: string;
271
+ versionId?: string;
272
+ abTestVariantId?: string;
273
+ /** Durable variant letter (A-D). Display only -- never match on it. */
274
+ abTestVariantLetter?: string;
275
+ /** Half-open [lower, upper) share of the 0-99 session percentage space. */
276
+ abTestVariantRange?: [number, number];
277
+ /** @deprecated Superseded by abTestVariantRange. */
278
+ abTestVariantNumber?: number;
279
+ /** @deprecated Superseded by abTestVariantRange. */
280
+ abTestVariantsCount?: number;
281
+ /** @deprecated Superseded by abTestVariantRange. */
282
+ abTestTrafficAllocation?: number | null;
283
+ blockName: string;
284
+ discountName?: string;
285
+ blockTitle: string;
286
+ blockLayout: BlockLayout;
287
+ bundleBarsPerRow?: "2" | "3";
288
+ blockVisibility: BlockVisibility;
289
+ marketId?: number | null;
290
+ excludedMarketIds?: number[];
291
+ currency?: Currency | null;
292
+ excludeB2bCustomers: boolean;
293
+ excludePos?: boolean;
294
+ startTimestamp: number;
295
+ endTimestamp: number | null;
296
+ differentVariantsEnabled: boolean;
297
+ hideVariantPicker: boolean;
298
+ disableVariantOptionSync?: boolean;
299
+ hideUnavailableOptions?: boolean;
300
+ showPricesPerItem: boolean;
301
+ showBothPrices: boolean;
302
+ unitLabel?: string;
303
+ useProductCompareAtPrice: boolean;
304
+ showPricesWithoutDecimals?: boolean;
305
+ priceRounding: boolean;
306
+ priceRoundingPrecision: PriceRoundingPrecision;
307
+ updateNativePrice?: boolean;
308
+ updateNativePriceType?: "item" | "bundle";
309
+ showTotalPriceInAddToCartButton?: boolean;
310
+ skipCart: boolean;
311
+ showVariantsForSingleQuantity: boolean;
312
+ preselectedDealBarId: string | null;
313
+ cornerRadius: number;
314
+ spacing?: number;
315
+ selectedProductIds: number[];
316
+ selectedCollectionIds: number[];
317
+ excludedProductIds: number[];
318
+ excludedCollectionIds?: number[];
319
+ colors: {
320
+ background: Color;
321
+ selectedBackground: Color;
322
+ border: Color;
323
+ blockTitle: Color;
324
+ title: Color;
325
+ subtitle: Color;
326
+ price: Color;
327
+ fullPrice: Color;
328
+ labelBackground: Color;
329
+ label: Color;
330
+ badgeBackground: Color;
331
+ badgeText: Color;
332
+ freeGiftBackground: Color;
333
+ freeGiftText: Color;
334
+ freeGiftSelectedBackground: Color;
335
+ freeGiftSelectedText: Color;
336
+ upsellBackground: Color;
337
+ upsellText: Color;
338
+ upsellSelectedBackground: Color;
339
+ upsellSelectedText: Color;
340
+ progressiveGiftsLabelBackground?: Color;
341
+ primary?: Color;
342
+ pillBackground?: Color;
343
+ pillText?: Color;
344
+ pillBorder?: Color;
345
+ pillSelectedBackground?: Color;
346
+ pillSelectedText?: Color;
347
+ pillSelectedBorder?: Color;
348
+ };
349
+ fonts: {
350
+ fontFamily?: string | null;
351
+ blockTitle: Font;
352
+ title: Font;
353
+ subtitle: Font;
354
+ label: Font;
355
+ freeGift: Font;
356
+ upsell: Font;
357
+ unitLabel: Font;
358
+ pill?: Font;
359
+ };
360
+ dealBars: DealBar[];
361
+ badgesEnabled?: boolean;
362
+ badges?: Badge[];
363
+ swatchOptions?: SwatchOption[];
364
+ swatchSize?: number;
365
+ swatchShape?: SwatchShape;
366
+ showSelectedSwatchName?: boolean;
367
+ pillCornerRadius?: number | null;
368
+ imageSize?: number;
369
+ imageCornerRadius?: number;
370
+ defaultVariantsV2?: {
371
+ productGID: string | number;
372
+ dealBarId: string;
373
+ variantGIDs: (string | number | null)[];
374
+ }[];
375
+ collectionBreaksEnabled?: boolean;
376
+ collectionBreaks?: CollectionBreaks | null;
377
+ chooseProductModal?: ChooseProductModal | null;
378
+ mixAndMatchChooseProductModal?: MixAndMatchChooseProductModal | null;
379
+ chooseMultipleGiftsModal?: ChooseMultipleGiftsModal | null;
380
+ addPersonalisationModal?: AddPersonalisationModal | null;
381
+ timerEnabled: boolean;
382
+ timer: Timer | null;
383
+ scratchOffEnabled?: boolean;
384
+ scratchOff?: ScratchOff | null;
385
+ subscriptionsEnabled: boolean;
386
+ subscriptions: Subscriptions | null;
387
+ stickyAtcEnabled: boolean;
388
+ stickyAtc: StickyAtc | null;
389
+ progressiveGiftsEnabled: boolean;
390
+ progressiveGifts: ProgressiveGifts | null;
391
+ checkboxUpsellsEnabled: boolean | null;
392
+ checkboxUpsells: CheckboxUpsells | null;
393
+ savingsSummaryEnabled?: boolean;
394
+ savingsSummary?: SavingsSummary | null;
395
+ customStylesEnabled?: boolean;
396
+ shopCustomStyles?: string;
397
+ customStyles?: string;
398
+ lowStockAlertEnabled: boolean;
399
+ lowStockAlert: LowStockAlert | null;
400
+ };
401
+
402
+ declare type DefaultSortOption = "relevance" | "newest-first" | "price-low-to-high" | "price-high-to-low";
403
+
404
+ declare type DiscountType = "default" | "percentage" | "amount" | "specific";
405
+
406
+ export declare const fetchKachingBundlesData: (...args: Parameters<typeof fetchKachingBundlesData_2>) => Promise<KachingBundlesData | null>;
407
+
408
+ declare const fetchKachingBundlesData_2: (storefront: HydrogenV2Storefront | ReactHydrogenStorefront | ShopifyStorefrontApiClient | StorefrontCredentials, { productId, dealBlockId, country, language, }: {
409
+ productId: string;
410
+ dealBlockId?: string;
411
+ country?: string;
412
+ language?: string;
413
+ }) => Promise<KachingBundlesData_2 | null>;
414
+
415
+ declare type Font = {
416
+ size: string | number;
417
+ style: FontStyle;
418
+ };
419
+
420
+ declare type FontStyle = "light" | "light-italic" | "regular" | "regular-italic" | "medium" | "medium-italic" | "bold" | "bold-italic";
421
+
422
+ declare type FreeGift = {
423
+ id: string;
424
+ giftType?: "product" | "shipping";
425
+ productGID: string | null;
426
+ variantGIDs: string[] | null;
427
+ mediaImageGID: string | null;
428
+ text: string;
429
+ imageSize: number;
430
+ quantity: number;
431
+ showPrice: boolean;
432
+ includeInCompareAt?: boolean;
433
+ applyOnlyForSubscriptions: boolean;
434
+ excludeRatesAboveThreshold?: boolean;
435
+ excludeRatesAboveThresholdAmount?: number;
436
+ };
437
+
438
+ declare type FreeGiftsSummary = {
439
+ enabled: boolean;
440
+ showImages: boolean;
441
+ title: string;
442
+ };
443
+
444
+ declare interface GlobalConfig {
445
+ shopifyDomain: string;
446
+ moneyFormat: string;
447
+ locale: string;
448
+ liquidLocale?: string;
449
+ country: string;
450
+ currencyRate: number;
451
+ marketCurrencyCode?: string;
452
+ marketId: number;
453
+ productId: number | null;
454
+ storefrontAccessToken: string | null;
455
+ includeSellingPlans: boolean;
456
+ includeAvailableQuantity: boolean;
457
+ customApiHost: string | null;
458
+ keepQuantityInput: boolean;
459
+ ignoreDeselect: boolean;
460
+ ignoreUnitPrice: boolean;
461
+ requireCustomerLogin: boolean;
462
+ abTestsRunning: boolean;
463
+ webPixel: boolean;
464
+ b2bCustomer: boolean;
465
+ isLoggedIn: boolean;
466
+ isDeprecatedAppEmbed?: boolean;
467
+ preview: boolean;
468
+ previewAlerts: boolean;
469
+ previewScratchOff: boolean;
470
+ defaultTranslations: {
471
+ "system.out_of_stock": string;
472
+ "system.invalid_variant": string;
473
+ "system.unavailable_option_value": string;
474
+ "system.confirm": string;
475
+ "system.cancel": string;
476
+ "system.free": string;
477
+ "system.search": string;
478
+ "system.quantity": string;
479
+ "system.subscription_plan": string;
480
+ "system.remove": string;
481
+ "system.sort_by": string;
482
+ "system.sort_relevance": string;
483
+ "system.sort_newest_first": string;
484
+ "system.sort_price_low_to_high": string;
485
+ "system.sort_price_high_to_low": string;
486
+ "system.no_results_found": string;
487
+ "system.no_results_description": string;
488
+ "system.clear_search": string;
489
+ "system.no_products_available": string;
490
+ "system.original_price": string;
491
+ "system.price": string;
492
+ "system.letters_only": string;
493
+ "system.numbers_only": string;
494
+ "system.select_variant_alert"?: string;
495
+ "system.select_variant_placeholder"?: string;
496
+ "system.personalisation_required_alert"?: string;
497
+ "system.deal_page_adding_to_cart"?: string;
498
+ "system.deal_page_add_to_cart_failed"?: string;
499
+ "system.deal_page_total"?: string;
500
+ "system.deal_page_tier_items"?: string;
501
+ "system.deal_page_sign_in_prompt"?: string;
502
+ "system.deal_page_sign_in"?: string;
503
+ "system.deal_page_unavailable"?: string;
504
+ "system.deal_page_full_price"?: string;
505
+ "system.deal_page_items_one"?: string;
506
+ "system.deal_page_items_other"?: string;
507
+ "system.deal_page_items_few"?: string;
508
+ "system.deal_page_items_many"?: string;
509
+ "system.deal_page_percentage_off"?: string;
510
+ "system.deal_page_price_each"?: string;
511
+ "system.deal_page_quantity_for_price"?: string;
512
+ "system.deal_page_save_up_to"?: string;
513
+ "system.deal_page_in_your_box"?: string;
514
+ "system.deal_page_in_your_box_count"?: string;
515
+ "system.deal_page_in_box_count"?: string;
516
+ "system.deal_page_remove_from_box"?: string;
517
+ "system.deal_page_remove_one"?: string;
518
+ "system.deal_page_box_full"?: string;
519
+ "system.deal_page_sold_out"?: string;
520
+ "system.deal_page_start_your_box"?: string;
521
+ "system.deal_page_not_a_full_box"?: string;
522
+ "system.deal_page_full_price_for_now"?: string;
523
+ "system.deal_page_percentage_unlocked"?: string;
524
+ "system.deal_page_box_of"?: string;
525
+ "system.deal_page_no_box_price"?: string;
526
+ "system.deal_page_track_box_full"?: string;
527
+ "system.deal_page_nudge_start_percentage_one"?: string;
528
+ "system.deal_page_nudge_start_percentage_other"?: string;
529
+ "system.deal_page_nudge_start_percentage_few"?: string;
530
+ "system.deal_page_nudge_start_percentage_many"?: string;
531
+ "system.deal_page_nudge_start_fixed_one"?: string;
532
+ "system.deal_page_nudge_start_fixed_other"?: string;
533
+ "system.deal_page_nudge_start_fixed_few"?: string;
534
+ "system.deal_page_nudge_start_fixed_many"?: string;
535
+ "system.deal_page_nudge_more_percentage_one"?: string;
536
+ "system.deal_page_nudge_more_percentage_other"?: string;
537
+ "system.deal_page_nudge_more_percentage_few"?: string;
538
+ "system.deal_page_nudge_more_percentage_many"?: string;
539
+ "system.deal_page_nudge_more_fixed_one"?: string;
540
+ "system.deal_page_nudge_more_fixed_other"?: string;
541
+ "system.deal_page_nudge_more_fixed_few"?: string;
542
+ "system.deal_page_nudge_more_fixed_many"?: string;
543
+ "system.deal_page_nudge_best_price"?: string;
544
+ "system.deal_page_nudge_box_full"?: string;
545
+ "system.deal_page_nudge_below_minimum_one"?: string;
546
+ "system.deal_page_nudge_below_minimum_other"?: string;
547
+ "system.deal_page_nudge_below_minimum_few"?: string;
548
+ "system.deal_page_nudge_below_minimum_many"?: string;
549
+ "system.deal_page_subtotal"?: string;
550
+ "system.deal_page_box_discount"?: string;
551
+ "system.deal_page_box_price_saving"?: string;
552
+ "system.deal_page_items_separately"?: string;
553
+ "system.deal_page_cheaper_separately"?: string;
554
+ "system.deal_page_add_item_to_start"?: string;
555
+ "system.deal_page_add_more_to_continue_one"?: string;
556
+ "system.deal_page_add_more_to_continue_other"?: string;
557
+ "system.deal_page_add_more_to_continue_few"?: string;
558
+ "system.deal_page_add_more_to_continue_many"?: string;
559
+ "system.deal_page_line_quantity"?: string;
560
+ "system.deal_page_view_box"?: string;
561
+ "system.deal_page_close"?: string;
562
+ "system.deal_page_back_to_products"?: string;
563
+ "system.deal_page_items_still_to_add_one"?: string;
564
+ "system.deal_page_items_still_to_add_other"?: string;
565
+ "system.deal_page_items_still_to_add_few"?: string;
566
+ "system.deal_page_items_still_to_add_many"?: string;
567
+ "system.deal_page_default_pricing_title"?: string;
568
+ "system.deal_page_default_pricing_note_percentage"?: string;
569
+ "system.deal_page_default_pricing_note_fixed"?: string;
570
+ "system.deal_page_default_box_title"?: string;
571
+ "system.deal_page_default_empty_title"?: string;
572
+ "system.deal_page_default_empty_note"?: string;
573
+ "system.deal_page_default_add_to_box"?: string;
574
+ "system.deal_page_default_add_box_to_cart"?: string;
575
+ "system.deal_page_items_range"?: string;
576
+ "system.deal_page_minimum"?: string;
577
+ "system.deal_page_tip_box_size"?: string;
578
+ "system.deal_page_tip_on_its_own"?: string;
579
+ "system.deal_page_about_this_price"?: string;
580
+ };
581
+ customSelectors: {
582
+ quantity: string | null;
583
+ addToCartButton: string | null;
584
+ variantPicker: string | null;
585
+ price?: string | null;
586
+ priceCompare?: string | null;
587
+ label?: string | null;
588
+ };
589
+ featureFlags: {
590
+ atc_total_price?: boolean;
591
+ cart_change_response_rewrite?: boolean;
592
+ cart_interceptor_dedupe_disabled?: boolean;
593
+ cart_interceptor_json_encoding?: boolean;
594
+ debug_cart_add?: boolean;
595
+ disable_nested_cart_lines?: boolean;
596
+ early_fetch_override?: boolean;
597
+ hide_missing_variants?: boolean;
598
+ initialize_with_form_variant?: boolean;
599
+ intercept_cart_request?: boolean;
600
+ legacy_saved_percentage?: boolean;
601
+ low_priority_scripts?: boolean;
602
+ native_swatches_disabled?: boolean;
603
+ observe_external_selling_plan?: boolean;
604
+ observe_form_selling_plan?: boolean;
605
+ percentage_cents_rounding_workaround?: boolean;
606
+ preserve_variant_selections?: boolean;
607
+ price_rounding_v2?: boolean;
608
+ propagate_line_properties?: boolean;
609
+ propagate_picker_option_changes?: boolean;
610
+ reinitialize_morphed_placeholders?: boolean;
611
+ remove_variant_change_delay?: boolean;
612
+ rever_non_returnable?: boolean;
613
+ show_single_variant_name?: boolean;
614
+ split_bxgy_items?: boolean;
615
+ split_quantity_break_items?: boolean;
616
+ storefront_metaobjects?: boolean;
617
+ pos_extension?: boolean;
618
+ variant_images?: boolean;
619
+ };
620
+ shopCustomStyles: string;
621
+ brandColors?: BrandColors | null;
622
+ }
623
+
624
+ declare type Highlights = {
625
+ layout?: "vertical" | "horizontal";
626
+ items: string[];
627
+ showOnlyWhenSelected: boolean;
628
+ size: number;
629
+ iconColor: Color;
630
+ textColor: Color;
631
+ iconType?: "none" | "checkmark" | "dot" | "arrow" | "star" | "heart" | "thumbs-up" | "custom";
632
+ customIconGID?: string | null;
633
+ };
634
+
635
+ declare interface HydrogenV2Storefront {
636
+ query: (query: string, options?: {
637
+ variables?: Record<string, unknown>;
638
+ }) => Promise<unknown>;
639
+ i18n: {
640
+ country: string;
641
+ language: string;
642
+ };
643
+ }
644
+
645
+ export declare const KachingBundle: ({ data, selectedVariantId, preview, onLinesChange, targetWindow, }: {
646
+ data?: KachingBundlesData;
647
+ selectedVariantId?: string;
648
+ preview?: {
649
+ price?: number;
650
+ color?: string;
651
+ cornerRadius?: number;
652
+ };
653
+ onLinesChange?: (lines: {
654
+ merchandiseId: string;
655
+ quantity: number;
656
+ attributes: {
657
+ key: string;
658
+ value: string;
659
+ }[];
660
+ sellingPlanId?: string;
661
+ }[]) => void;
662
+ targetWindow?: Window;
663
+ }) => JSX_2.Element | null;
664
+
665
+ export declare interface KachingBundlesData {
666
+ }
667
+
668
+ declare interface KachingBundlesData_2 {
669
+ config: GlobalConfig;
670
+ dealBlock: DealBlock;
671
+ product: Product;
672
+ otherProducts: Product[];
673
+ mediaImages: {
674
+ gid: string;
675
+ url: string;
676
+ }[];
677
+ collectionBreaksProducts: Product[];
678
+ translations: {
679
+ [key: string]: string;
680
+ };
681
+ }
682
+
683
+ declare type LowStockAlert = {
684
+ threshold: number;
685
+ message: string;
686
+ textColor: Color;
687
+ };
688
+
689
+ declare interface MixAndMatchChooseProductModal {
690
+ buttonSize: number;
691
+ textSize: number;
692
+ overlayColor: Color;
693
+ priceColor: Color;
694
+ compareAtPriceColor: Color;
695
+ textColor: Color;
696
+ buttonColor: Color;
697
+ buttonTextColor: Color;
698
+ productPhotoSize: number;
699
+ heading: string;
700
+ subtitle?: string;
701
+ buttonText: string;
702
+ }
703
+
704
+ declare interface MixAndMatchDealBar extends BaseDealBar, ShowAsSoldOutFeature, RequireVariantSelectionFeature {
705
+ dealBarType: DealBarType.MixAndMatch;
706
+ discountType: DiscountType;
707
+ discountValue: string | number;
708
+ showProductsOnlyWhenSelected?: boolean;
709
+ showProductPrices?: boolean;
710
+ bundleProducts: MixAndMatchProduct[];
711
+ buttonText?: string;
712
+ }
713
+
714
+ declare interface MixAndMatchProduct {
715
+ id: string;
716
+ productGID: string | null;
717
+ variantGIDs: string[] | null;
718
+ title?: string;
719
+ selectedProducts?: {
720
+ id: string;
721
+ variantGIDs: string[] | null;
722
+ }[];
723
+ }
724
+
725
+ declare type MostPopularBadge = BaseBadge & {
726
+ badgeType: "most-popular";
727
+ size: number;
728
+ };
729
+
730
+ declare type MultipleGiftsSelector = {
731
+ id: string;
732
+ products: {
733
+ id: string;
734
+ variantGIDs: string[] | null;
735
+ }[];
736
+ mediaImageGID: string | null;
737
+ imageSize: number;
738
+ textBeforeSelection: string;
739
+ textAfterSelection: string;
740
+ maxQuantity: number;
741
+ showPrice: boolean;
742
+ showProductPhotos?: boolean;
743
+ includeInCompareAt?: boolean;
744
+ applyOnlyForSubscriptions: boolean;
745
+ };
746
+
747
+ declare type PriceRoundingPrecision = ".99" | ".95" | ".90" | ".x9" | ".x0" | ".00";
748
+
749
+ declare interface Product {
750
+ id: number;
751
+ handle: string;
752
+ url: string | null;
753
+ availableForSale: boolean;
754
+ createdAt?: string;
755
+ title: string;
756
+ image: string | null;
757
+ selectedVariantId: number;
758
+ collectionIds: number[];
759
+ options: ProductOption[];
760
+ variants: Variant[];
761
+ requiresSellingPlan: boolean;
762
+ sellingPlans: SellingPlan[];
763
+ isNativeBundle: boolean | null;
764
+ metafields: {
765
+ text: string | null;
766
+ text2: string | null;
767
+ text3: string | null;
768
+ text4: string | null;
769
+ };
770
+ }
771
+
772
+ declare interface ProductOption {
773
+ defaultName: string;
774
+ name: string;
775
+ position: number;
776
+ optionValues: {
777
+ id: number;
778
+ defaultName: string;
779
+ name: string;
780
+ swatch: {
781
+ color: string | null;
782
+ image: string | null;
783
+ };
784
+ }[];
785
+ }
786
+
787
+ declare type ProductPersonalisation = {
788
+ id: string;
789
+ productGID: string | null;
790
+ variantGID: string | null;
791
+ pricePerItem: string;
792
+ pricePerItemUnitLabel: string;
793
+ compareAtPrice: string;
794
+ valueLabel?: string;
795
+ title: string;
796
+ subtitle: string;
797
+ mediaImageGID: string | null;
798
+ imageSize: number;
799
+ required: boolean;
800
+ };
801
+
802
+ declare type ProgressiveGift = {
803
+ id: string;
804
+ giftType: "product" | "shipping";
805
+ productGID: string | null;
806
+ variantGIDs: string[] | null;
807
+ mediaImageGID: string | null;
808
+ unlockAtBar: number;
809
+ unlockAtBarOnly?: boolean;
810
+ label: string;
811
+ labelCrossedOut: string;
812
+ title: string;
813
+ lockedTitle: string;
814
+ quantity: number;
815
+ differentVariantsEnabled: boolean;
816
+ applyOnlyForSubscriptions?: boolean;
817
+ excludeRatesAboveThreshold?: boolean;
818
+ excludeRatesAboveThresholdAmount?: number;
819
+ };
820
+
821
+ declare type ProgressiveGifts = {
822
+ layout: "horizontal" | "vertical" | "deal-bar";
823
+ title: string;
824
+ subtitle: string;
825
+ hideLockedGifts: boolean;
826
+ showLockedGiftLabels: boolean;
827
+ showLockedGiftProducts: boolean;
828
+ gifts: ProgressiveGift[];
829
+ titleColor: Color;
830
+ titleAlignment: "start" | "center" | "end";
831
+ titleStyle: FontStyle;
832
+ titleSize: number;
833
+ subtitleColor: Color;
834
+ subtitleAlignment: "start" | "center" | "end";
835
+ subtitleStyle: FontStyle;
836
+ subtitleSize: number;
837
+ inheritStyle: boolean;
838
+ style: ProgressiveGiftsStyle | null;
839
+ dealBarStyle?: DealBarProgressiveGiftStyle | null;
840
+ };
841
+
842
+ declare type ProgressiveGiftsStyle = {
843
+ imageSize: number;
844
+ cornerRadius: number;
845
+ labelBackgroundColor: Color;
846
+ labelTextColor: Color;
847
+ labelTextSize: number;
848
+ backgroundColor: Color;
849
+ borderColor: Color;
850
+ textColor: Color;
851
+ textSize: number;
852
+ lockedBackgroundColor: Color;
853
+ lockedBorderColor: Color;
854
+ lockedTextColor: Color;
855
+ lockedTextSize: number;
856
+ lockedIconColor: Color;
857
+ lockedMediaImageGID: string | null;
858
+ };
859
+
860
+ declare interface QuantityBreakDealBar extends BaseDealBar, ShowAsSoldOutFeature, RequireVariantSelectionFeature {
861
+ dealBarType?: DealBarType.QuantityBreak;
862
+ quantity: number | string;
863
+ discountType: DiscountType;
864
+ discountValue: string | number;
865
+ quantitySelector?: boolean;
866
+ }
867
+
868
+ declare interface ReactHydrogenStorefront {
869
+ getStorefrontApiUrl: () => string;
870
+ getPublicTokenHeaders: () => Record<string, string>;
871
+ }
872
+
873
+ declare type RequireItemSelectionAlert = {
874
+ text: string;
875
+ textColor: Color;
876
+ backgroundColor: Color;
877
+ };
878
+
879
+ declare interface RequireVariantSelectionFeature {
880
+ requireVariantSelectionEnabled?: boolean;
881
+ }
882
+
883
+ declare type SavingsSummary = {
884
+ title: string;
885
+ backgroundColor: Color;
886
+ textColor: Color;
887
+ valueColor: Color;
888
+ borderColor: Color;
889
+ borderWidth: number;
890
+ borderRadius: number;
891
+ iconType: "none" | "checkmark" | "dot" | "arrow" | "star" | "heart" | "thumbs-up" | "custom";
892
+ customIconGID: string | null;
893
+ iconColor: Color;
894
+ titleAlignment: "start" | "center" | "end";
895
+ titleFont: Font;
896
+ includeGiftValue: boolean;
897
+ hideWhenZeroSavings: boolean;
898
+ };
899
+
900
+ declare type ScratchOff = {
901
+ title: string;
902
+ backgroundColor: Color;
903
+ titleColor: Color;
904
+ titleSize: number;
905
+ };
906
+
907
+ declare interface SellingPlan {
908
+ id: number;
909
+ name: string;
910
+ priceAdjustment: {
911
+ type: "percentage" | "fixed_amount" | "price";
912
+ value: number;
913
+ } | null;
914
+ }
915
+
916
+ declare interface ShopifyStorefrontApiClient {
917
+ request: (query: string, options?: {
918
+ variables?: Record<string, unknown>;
919
+ }) => Promise<{
920
+ data: unknown;
921
+ }>;
922
+ }
923
+
924
+ declare type ShowAsSoldOut = {
925
+ label: string;
926
+ opacity: number;
927
+ backgroundColor: Color;
928
+ textColor: Color;
929
+ textSize: number;
930
+ };
931
+
932
+ declare interface ShowAsSoldOutFeature {
933
+ showAsSoldOutEnabled: boolean;
934
+ showAsSoldOut: ShowAsSoldOut | null;
935
+ }
936
+
937
+ declare type SimpleBadge = BaseBadge & {
938
+ badgeType: "simple";
939
+ textSize: number;
940
+ };
941
+
942
+ declare interface SkuDealBar extends BaseDealBar, ShowAsSoldOutFeature {
943
+ dealBarType: DealBarType.Sku;
944
+ productGID: string | null;
945
+ variantGIDs?: string[] | null;
946
+ }
947
+
948
+ declare type StickyAtc = {
949
+ title: string;
950
+ buttonText: string;
951
+ backgroundColor: Color;
952
+ titleColor: Color;
953
+ buttonColor: Color;
954
+ buttonTextColor: Color;
955
+ titleFont: Font;
956
+ buttonFont: Font;
957
+ productPhotoSize: number;
958
+ buttonPadding: number;
959
+ productPhotoCornerRadius: number;
960
+ buttonCornerRadius: number;
961
+ sameSizeOnMobile?: boolean;
962
+ mobile?: StickyAtcMobileOverrides | null;
963
+ };
964
+
965
+ declare type StickyAtcMobileOverrides = {
966
+ titleFontSize: number;
967
+ buttonFontSize: number;
968
+ productPhotoSize: number;
969
+ buttonPadding: number;
970
+ productPhotoCornerRadius: number;
971
+ buttonCornerRadius: number;
972
+ };
973
+
974
+ export declare interface StorefrontApiClientInterface {
975
+ shopifyDomain: string;
976
+ query<T = unknown>(query: string, options?: {
977
+ variables?: Record<string, unknown>;
978
+ }): Promise<T>;
979
+ }
980
+
981
+ export declare interface StorefrontCredentials {
982
+ shopifyDomain: string;
983
+ storefrontAccessToken: string;
984
+ }
985
+
986
+ declare type Subscriptions = {
987
+ layout: SubscriptionsLayout;
988
+ position: "above" | "below";
989
+ title?: string;
990
+ subscribeTitle: string;
991
+ subscribeSubtitle: string;
992
+ oneTimeTitle: string;
993
+ oneTimeSubtitle: string;
994
+ subscribeByDefault: boolean;
995
+ showPrices?: boolean;
996
+ hideDealBarPrices?: boolean;
997
+ titleColor: Color;
998
+ subtitleColor: Color;
999
+ titleSize: number;
1000
+ subtitleSize: number;
1001
+ highlights?: Highlights | null;
1002
+ };
1003
+
1004
+ declare type SubscriptionsLayout = "horizontal" | "vertical" | "checkbox" | "link";
1005
+
1006
+ declare type SwatchOption = {
1007
+ localization?: {
1008
+ language: string;
1009
+ country: string;
1010
+ };
1011
+ name: string;
1012
+ swatchType: SwatchType;
1013
+ colors: {
1014
+ name: string;
1015
+ color: Color;
1016
+ }[];
1017
+ images: {
1018
+ name: string;
1019
+ mediaImageGID: string;
1020
+ }[];
1021
+ };
1022
+
1023
+ declare type SwatchShape = "square" | "rounded" | "circle";
1024
+
1025
+ declare type SwatchType = "default" | "colorDropdown" | "imageDropdown" | "productImageDropdown" | "mixedDropdown" | "colorButtons" | "imageButtons" | "productImageButtons" | "pillButtons";
1026
+
1027
+ declare type Timer = {
1028
+ type: "duration" | "midnight" | "custom";
1029
+ minutes: number;
1030
+ endTimestamp: number | null;
1031
+ title: string;
1032
+ textColor: Color;
1033
+ backgroundColor: Color;
1034
+ titleAlignment: "start" | "center" | "end";
1035
+ titleStyle: FontStyle;
1036
+ titleSize: number;
1037
+ };
1038
+
1039
+ declare type Upsell = {
1040
+ id: string;
1041
+ productSource: "selected" | "complementary";
1042
+ productGID: string | null;
1043
+ variantGIDs: string[] | null;
1044
+ defaultVariantGID?: string | null;
1045
+ mediaImageGID: string | null;
1046
+ discountType: DiscountType;
1047
+ discountValue: string | number;
1048
+ text: string;
1049
+ imageSize: number;
1050
+ quantity: number;
1051
+ preselected: boolean;
1052
+ visibleOnlyWhenDealBarSelected: boolean;
1053
+ subscriptionEnabled?: boolean;
1054
+ subscriptionType?: "deal" | "always";
1055
+ };
1056
+
1057
+ declare interface Variant {
1058
+ id: number;
1059
+ availableForSale: boolean;
1060
+ price: number;
1061
+ compareAtPrice: number | null;
1062
+ options: string[];
1063
+ imageId: number | null;
1064
+ image: string | null;
1065
+ sellingPlans: {
1066
+ id: number;
1067
+ price: number;
1068
+ compareAtPrice?: number;
1069
+ perDeliveryPrice?: number;
1070
+ }[];
1071
+ inventoryManagement: string | null;
1072
+ inventoryPolicy: string | null;
1073
+ inventoryQuantity: number | null;
1074
+ unitPriceMeasurement: {
1075
+ quantityValue: number;
1076
+ quantityUnit: string;
1077
+ referenceValue: number;
1078
+ referenceUnit: string;
1079
+ } | null;
1080
+ }
1081
+
1082
+ export { }