@liquidcommerce/elements-sdk 2.7.7 → 2.7.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/README.md +1 -1
  2. package/dist/index.checkout.esm.js +6989 -6973
  3. package/dist/index.esm.js +11337 -11224
  4. package/dist/types/auto-initialize/shared-utils.d.ts +3 -2
  5. package/dist/types/core/store/interfaces/product-list.interface.d.ts +2 -1
  6. package/dist/types/index.checkout.d.ts +1 -1
  7. package/dist/types/index.checkout.umd.d.ts +1 -1
  8. package/dist/types/interfaces/api/product-list.interface.d.ts +1 -1
  9. package/dist/types/modules/product/components/product-retailers-popup-list.component.d.ts +1 -1
  10. package/dist/types/modules/product-list/components/card-components/product-quantity-selector.d.ts +1 -1
  11. package/dist/types/modules/product-list/components/card-components/product-sizes-list.d.ts +1 -1
  12. package/dist/types/modules/product-list/components/filter-components/product-list-filters-chips.d.ts +1 -1
  13. package/dist/types/modules/product-list/components/filter-components/product-list-fulfillment-filter.d.ts +2 -2
  14. package/dist/types/modules/product-list/components/filter-components/product-list-toggle-filters.d.ts +1 -1
  15. package/dist/types/modules/product-list/components/index.d.ts +1 -1
  16. package/dist/types/modules/product-list/components/product-list-card-loading.component.d.ts +1 -1
  17. package/dist/types/modules/product-list/{product-list-card.component.d.ts → components/product-list-card.component.d.ts} +1 -1
  18. package/dist/types/modules/product-list/components/product-list-engraving.component.d.ts +3 -3
  19. package/dist/types/modules/product-list/components/product-list-filters.component.d.ts +4 -5
  20. package/dist/types/modules/product-list/components/product-list-product-engraving-lines.component.d.ts +2 -2
  21. package/dist/types/modules/product-list/components/product-list-product-pre-cart.component.d.ts +5 -2
  22. package/dist/types/modules/product-list/product-list.commands.d.ts +3 -2
  23. package/dist/types/modules/product-list/product-list.component.d.ts +2 -2
  24. package/dist/types/modules/product-list/product-list.interface.d.ts +9 -0
  25. package/docs/v1/README.md +1 -1
  26. package/docs/v1/examples/checkout-flow.md +2 -2
  27. package/docs/v1/examples/multi-product-page.md +2 -2
  28. package/docs/v1/examples/simple-product-page.md +1 -1
  29. package/docs/v1/getting-started/concepts.md +3 -3
  30. package/docs/v1/getting-started/installation.md +3 -3
  31. package/docs/v1/getting-started/quick-start.md +6 -6
  32. package/docs/v1/guides/address-component.md +1 -1
  33. package/docs/v1/guides/cart-component.md +7 -7
  34. package/docs/v1/guides/checkout-component.md +2 -2
  35. package/docs/v1/guides/product-component.md +5 -5
  36. package/docs/v1/guides/product-list-component.md +2 -2
  37. package/docs/v1/integration/laravel.md +1 -1
  38. package/docs/v1/integration/vanilla-js.md +2 -2
  39. package/package.json +11 -14
@@ -1,7 +1,7 @@
1
1
  import type { IAddProductParams } from '@/core/client/actions/client-cart-action.service';
2
2
  import type { IAnonymousCheckoutAddProductItem } from '@/interfaces/api/checkout.interface';
3
3
  import type { IInjectedComponent } from '@/interfaces/component.interface';
4
- import type { ILiquidCommerceElementsDevelopmentConfig } from '@/interfaces/config.interface';
4
+ import type { IClientCustomThemeConfig, ILiquidCommerceElementsDevelopmentConfig } from '@/interfaces/config.interface';
5
5
  import type { IInjectCheckoutParams } from '@/interfaces/injection.interface';
6
6
  export interface IQueryParamActions {
7
7
  addProduct: (params: IAddProductParams[], open?: boolean) => Promise<void>;
@@ -27,13 +27,14 @@ export declare const SHARED_ATTR: {
27
27
  };
28
28
  readonly JSON_SCRIPT: {
29
29
  readonly DEVELOPMENT: "data-liquid-commerce-elements-development";
30
+ readonly CUSTOM_THEME: "data-liquid-commerce-elements-custom-theme";
30
31
  };
31
32
  };
32
33
  export declare function startsWithLcePrefix(value: string | null): boolean;
33
34
  export declare function getDevelopmentConfigs(): ILiquidCommerceElementsDevelopmentConfig | undefined;
35
+ export declare function getCustomThemeConfig(): IClientCustomThemeConfig | undefined;
34
36
  export declare function triggerAutoInit(initFunction: () => Promise<void>, errorPrefix: string): void;
35
37
  export declare function setupCheckout(script: HTMLScriptElement, injectFn: (params: IInjectCheckoutParams) => Promise<IInjectedComponent | null>, exitCheckoutFn: () => void, options: {
36
- requireCheckoutId?: boolean;
37
38
  errorPrefix: string;
38
39
  }): Promise<void>;
39
40
  export declare function setupExitCheckoutHandlers(exitCheckoutFn: () => void): void;
@@ -1,7 +1,7 @@
1
- import type { IPagination } from 'modules/product-list/product-list.interface';
2
1
  import type { FulfillmentType } from '@/enums';
3
2
  import type { IProduct } from '@/interfaces/api/product.interface';
4
3
  import type { IFilterSchema } from '@/interfaces/api/product-list.interface';
4
+ import type { IPagination } from '@/modules/product-list/product-list.interface';
5
5
  import type { IProductFulfillmentStore, IProductSizeStore } from './product.interface';
6
6
  export interface IPLProductStore extends Omit<IProduct, 'sizes'> {
7
7
  id: string;
@@ -26,4 +26,5 @@ export interface IProductListStore {
26
26
  rows: number;
27
27
  columns: number;
28
28
  loading: boolean;
29
+ rerender: boolean;
29
30
  }
@@ -4,5 +4,5 @@ import { DEBUG_MODE, ELEMENTS_ENV } from '@/enums';
4
4
  import type { IElementsCheckoutActions, IElementsCheckoutClient } from '@/interfaces/client.interface';
5
5
  import type { IInjectedComponent } from '@/interfaces/component.interface';
6
6
  import type { ILiquidCommerceElementsCheckoutClientConfig } from '@/interfaces/config.interface';
7
- export { DEBUG_MODE, ELEMENTS_ENV, ElementsCheckout };
8
7
  export type { DebugMode, ElementsEnv, IElementsCheckoutActions, IElementsCheckoutClient, IInjectedComponent, ILiquidCommerceElementsCheckoutClientConfig, };
8
+ export { DEBUG_MODE, ELEMENTS_ENV, ElementsCheckout };
@@ -1,4 +1,4 @@
1
1
  import type { IElementsCheckoutActions, IElementsCheckoutClient } from '@/interfaces/client.interface';
2
2
  import { ElementsCheckout } from './clients/checkout';
3
- export { ElementsCheckout };
4
3
  export type { IElementsCheckoutActions, IElementsCheckoutClient };
4
+ export { ElementsCheckout };
@@ -1,6 +1,6 @@
1
- import type { FILTER_KEYS } from 'modules/product-list/product-list.constants';
2
1
  import type { ILocation } from '@/interfaces/api/address.interface';
3
2
  import type { IProductAvailabilityResponse } from '@/interfaces/api/product.interface';
3
+ import type { FILTER_KEYS } from '@/modules/product-list/product-list.constants';
4
4
  export interface IProductSearchParams {
5
5
  slug: string;
6
6
  location?: ILocation;
@@ -8,7 +8,7 @@ export interface IProductRetailersPopupListComponentParams {
8
8
  }
9
9
  export declare class ProductRetailersPopupListComponent extends BaseComponent<IProductRetailersPopupListComponentParams, IProductComponent> {
10
10
  get hostClasses(): string[];
11
- private get isProductListContext();
11
+ private get isProductContext();
12
12
  beforeSetupStoreWatchers(): void;
13
13
  private onFulfillmentTabClick;
14
14
  private onRetailerCardClick;
@@ -1,4 +1,4 @@
1
- import type { PLCCardStyle } from 'interfaces/configs/product-list.interface';
1
+ import type { PLCCardStyle } from '@/interfaces/configs/product-list.interface';
2
2
  export interface IQuantitySelectorParams {
3
3
  initialQuantity: number;
4
4
  minQuantity: number;
@@ -1,5 +1,5 @@
1
- import type { IProductSizeStore } from 'core/store/interfaces/product.interface';
2
1
  import { BaseComponent } from '@/core/base-component.service';
2
+ import type { IProductSizeStore } from '@/core/store/interfaces/product.interface';
3
3
  export interface IProductListSizeSelectorParams {
4
4
  sizes: Record<string, IProductSizeStore>;
5
5
  selectedSizeId: string | null;
@@ -1,4 +1,4 @@
1
- import type { IExtendedFilterSchema, IProductListFilters } from 'modules/product-list/product-list.interface';
1
+ import type { IExtendedFilterSchema, IProductListFilters } from '@/modules/product-list/product-list.interface';
2
2
  export interface ICreateChipsContainerParams {
3
3
  currentFilters?: IProductListFilters;
4
4
  sanitizedFilters?: IExtendedFilterSchema[];
@@ -1,5 +1,5 @@
1
- import { FULFILLMENT_OPTIONS } from 'modules/product-list/product-list.constants';
2
- import type { IProductListFilters } from 'modules/product-list/product-list.interface';
1
+ import { FULFILLMENT_OPTIONS } from '@/modules/product-list/product-list.constants';
2
+ import type { IProductListFilters } from '@/modules/product-list/product-list.interface';
3
3
  export interface ICreateFulfillmentFilterParams {
4
4
  currentFilters?: IProductListFilters;
5
5
  deliveryCollapsed: boolean;
@@ -1,4 +1,4 @@
1
- import type { IProductListFilters } from 'modules/product-list/product-list.interface';
1
+ import type { IProductListFilters } from '@/modules/product-list/product-list.interface';
2
2
  export interface ICreateEngravingFilterParams {
3
3
  currentFilters?: IProductListFilters;
4
4
  isPersonalizationDisabled: boolean;
@@ -1,6 +1,6 @@
1
- export * from '../product-list-card.component';
2
1
  export * from './filter-components';
3
2
  export * from './filter-components/product-list-apply-filter-button';
3
+ export * from './product-list-card.component';
4
4
  export * from './product-list-card-loading.component';
5
5
  export * from './product-list-engraving.component';
6
6
  export * from './product-list-filters.component';
@@ -1,5 +1,5 @@
1
- import type { IProductListComponent } from 'interfaces/configs';
2
1
  import { BaseComponent } from '@/core/base-component.service';
2
+ import type { IProductListComponent } from '@/interfaces/configs';
3
3
  import type { IProductListComponentParams } from '@/modules/product-list/product-list.component';
4
4
  export declare class ProductListCardLoadingComponent extends BaseComponent<IProductListComponentParams, IProductListComponent> {
5
5
  get hostClasses(): string[];
@@ -1,5 +1,5 @@
1
- import type { IProductListComponent } from 'interfaces/configs';
2
1
  import { BaseComponent, type IOnStoreChanged } from '@/core/base-component.service';
2
+ import type { IProductListComponent } from '@/interfaces/configs';
3
3
  export interface IProductListCardParams {
4
4
  slug: string;
5
5
  productId: string;
@@ -1,6 +1,6 @@
1
- import { BaseComponent } from 'core/base-component.service';
2
- import type { IProductListComponent } from 'interfaces/configs';
3
- import type { IEngravingFormComponentParams } from 'modules/ui-components/engraving';
1
+ import { BaseComponent } from '@/core/base-component.service';
2
+ import type { IProductListComponent } from '@/interfaces/configs';
3
+ import type { IEngravingFormComponentParams } from '@/modules/ui-components/engraving';
4
4
  interface IProductListEngravingParams extends IEngravingFormComponentParams {
5
5
  slug: string;
6
6
  }
@@ -1,12 +1,10 @@
1
- import { BaseComponent } from 'core/base-component.service';
2
- import type { ProductListFilterType } from 'interfaces/injection.interface';
1
+ import { BaseComponent } from '@/core/base-component.service';
2
+ import type { ProductListFilterType } from '@/interfaces/injection.interface';
3
3
  export interface IProductListFiltersParams {
4
4
  slug: string;
5
5
  filters: ProductListFilterType[];
6
6
  }
7
7
  export declare class ProductListFiltersComponent extends BaseComponent<IProductListFiltersParams> {
8
- private readonly DEFAULT_MIN_PRICE;
9
- private readonly DEFAULT_MAX_PRICE;
10
8
  private readonly FILTER_DEBOUNCE_DELAY_MS;
11
9
  private isRenderedInDrawerMode;
12
10
  private permanentFilters;
@@ -34,6 +32,8 @@ export declare class ProductListFiltersComponent extends BaseComponent<IProductL
34
32
  private detectIfRenderedInDrawer;
35
33
  onStoreWatch(): void;
36
34
  private syncFiltersFromStore;
35
+ private createFilterSection;
36
+ private rebuildContainer;
37
37
  private refreshUIStates;
38
38
  private transformFilterValue;
39
39
  private fetchFilters;
@@ -55,7 +55,6 @@ export declare class ProductListFiltersComponent extends BaseComponent<IProductL
55
55
  private togglePriceFilterCollapse;
56
56
  private buildPriceFilterElements;
57
57
  private buildDynamicFiltersElements;
58
- private getFilterElements;
59
58
  private buildCheckboxFilterElements;
60
59
  private toggleCheckboxFilterExpansion;
61
60
  private renderCheckboxItemsForFilter;
@@ -1,5 +1,5 @@
1
- import { BaseComponent } from 'core/base-component.service';
2
- import type { IProductListComponent } from 'interfaces/configs';
1
+ import { BaseComponent } from '@/core/base-component.service';
2
+ import type { IProductListComponent } from '@/interfaces/configs';
3
3
  export interface IProductListProductEngravingLinesComponentParams {
4
4
  slug: string;
5
5
  identifier: string;
@@ -1,5 +1,5 @@
1
- import { BaseComponent, type IOnStoreChanged } from 'core/base-component.service';
2
- import type { IProductListComponent } from 'interfaces/configs';
1
+ import { BaseComponent, type IOnStoreChanged } from '@/core/base-component.service';
2
+ import type { IProductListComponent } from '@/interfaces/configs';
3
3
  export interface IProductListProductPreCartComponentParams {
4
4
  slug: string;
5
5
  productId: string;
@@ -31,10 +31,13 @@ export declare class ProductListProductPreCartComponent extends BaseComponent<IP
31
31
  private updateAddToCartButton;
32
32
  private getEngravingFee;
33
33
  protected template(): HTMLElement[];
34
+ private createAnimatedContentElement;
35
+ private buildLayout;
34
36
  private createEngravingFormContent;
35
37
  private renderPreCartContent;
36
38
  private createDeliversToSectionWrapper;
37
39
  private createShippingFromSectionWrapper;
40
+ private createDescriptionSection;
38
41
  private createCartHeader;
39
42
  private createImageSection;
40
43
  private createPricePersonalizationSection;
@@ -3,7 +3,7 @@ import { type FulfillmentType } from '@/enums';
3
3
  import type { IFilterSchema, INavigationResponse, IProductSearchParams, IProductSearchResponse } from '@/interfaces/api/product-list.interface';
4
4
  import type { ProductListFilterType } from '@/interfaces/injection.interface';
5
5
  import { type AddItemParams } from '@/modules/cart/cart.commands';
6
- import type { IExtendedFilterSchema, IPagination, IProductListFilters } from './product-list.interface';
6
+ import type { IExtendedFilterSchema, ILoadInitialProductsParams, IPagination, IProductListFilters } from './product-list.interface';
7
7
  export declare class ProductListCommands extends BaseCommand {
8
8
  private readonly uiCommands;
9
9
  private readonly cartCommands;
@@ -12,7 +12,8 @@ export declare class ProductListCommands extends BaseCommand {
12
12
  initializeListStore(slug: string): void;
13
13
  updateSearchTerm(slug: string, searchTerm: string): void;
14
14
  setLoading(slug: string, isLoading: boolean): void;
15
- loadInitialProducts(slug: string, page: number, perPage: number, searchTerm: string, currentFilters: IProductListFilters, configuredFilters: ProductListFilterType[]): Promise<void>;
15
+ rerenderProductLists(): void;
16
+ loadInitialProducts({ slug, page, perPage, searchTerm, currentFilters, configuredFilters, }: ILoadInitialProductsParams): Promise<void>;
16
17
  loadMoreProducts(slug: string, perPage: number, searchTerm: string, currentFilters: IProductListFilters, configuredFilters: ProductListFilterType[]): Promise<void>;
17
18
  getProductList(params: IProductSearchParams): Promise<IProductSearchResponse>;
18
19
  syncFiltersFromComponent(slug: string, filters: IProductListFilters): void;
@@ -1,5 +1,5 @@
1
- import type { IProductListComponent } from 'interfaces/configs';
2
1
  import { BaseComponent, type IOnStoreChanged } from '@/core/base-component.service';
2
+ import type { IProductListComponent } from '@/interfaces/configs';
3
3
  import type { ProductListFilterType } from '@/interfaces/injection.interface';
4
4
  export interface IProductListComponentParams {
5
5
  slug: string;
@@ -31,7 +31,6 @@ export declare class ProductListComponent extends BaseComponent<IProductListComp
31
31
  private renderLoadingState;
32
32
  private renderProducts;
33
33
  private appendNewProducts;
34
- private getResponsiveColumns;
35
34
  private setupInfiniteScroll;
36
35
  private createScrollSentinel;
37
36
  private updateSentinel;
@@ -45,5 +44,6 @@ export declare class ProductListComponent extends BaseComponent<IProductListComp
45
44
  private cleanupScrollObserver;
46
45
  private doCleanup;
47
46
  onStoreWatch(changes: IOnStoreChanged[]): Promise<void>;
47
+ onStoreChanged(): boolean;
48
48
  protected template(): HTMLElement[];
49
49
  }
@@ -1,4 +1,5 @@
1
1
  import type { IFilterValue } from '@/interfaces/api/product-list.interface';
2
+ import type { ProductListFilterType } from '@/interfaces/injection.interface';
2
3
  export interface IPriceConfig {
3
4
  min?: string;
4
5
  max?: string;
@@ -54,3 +55,11 @@ export interface IRenderCheckboxItemsParams {
54
55
  state: ICheckboxLabelStates;
55
56
  onCheckboxChange: (value: string, checked: boolean) => void;
56
57
  }
58
+ export interface ILoadInitialProductsParams {
59
+ slug: string;
60
+ page: number;
61
+ perPage: number;
62
+ searchTerm: string;
63
+ currentFilters: IProductListFilters;
64
+ configuredFilters: ProductListFilterType[];
65
+ }
package/docs/v1/README.md CHANGED
@@ -108,7 +108,7 @@ Practical examples with working code:
108
108
  data-container-1="product"
109
109
  data-product-1="00619947000020"
110
110
  type="text/javascript"
111
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
111
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
112
112
  ></script>
113
113
 
114
114
  <div id="product"></div>
@@ -27,7 +27,7 @@ A two-page setup: a product page that adds to cart and redirects to a dedicated
27
27
  data-cart-badge-button="header-cart"
28
28
  data-checkout-url="https://yoursite.com/checkout?lce_checkout={token}"
29
29
  type="text/javascript"
30
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
30
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
31
31
  ></script>
32
32
  </head>
33
33
  <body>
@@ -63,7 +63,7 @@ When users click checkout, the cart redirects to your hosted checkout page with
63
63
  data-checkout-container="checkout"
64
64
  data-checkout-param="lce_checkout"
65
65
  type="text/javascript"
66
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
66
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
67
67
  ></script>
68
68
  </head>
69
69
  <body>
@@ -24,7 +24,7 @@ Show multiple products on a single page using declarative attributes or programm
24
24
  data-container-3="product-3"
25
25
  data-product-3="08068660001"
26
26
  type="text/javascript"
27
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
27
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
28
28
  ></script>
29
29
 
30
30
  <style>
@@ -53,7 +53,7 @@ Show multiple products on a single page using declarative attributes or programm
53
53
  data-token="YOUR_API_KEY"
54
54
  data-env="production"
55
55
  type="text/javascript"
56
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
56
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
57
57
  ></script>
58
58
 
59
59
  <script data-liquid-commerce-elements-products type="application/json">
@@ -32,7 +32,7 @@ A minimal, production-ready product page using the CDN build with a single Produ
32
32
  data-product-1="00619947000020"
33
33
  data-cart-badge-button="header-cart"
34
34
  type="text/javascript"
35
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
35
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
36
36
  ></script>
37
37
 
38
38
  <style>
@@ -68,7 +68,7 @@ When using the CDN, the SDK auto-initializes on page load:
68
68
  data-token="YOUR_API_KEY"
69
69
  data-env="production"
70
70
  type="text/javascript"
71
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
71
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
72
72
  ></script>
73
73
  ```
74
74
 
@@ -135,7 +135,7 @@ Configure components using HTML data attributes:
135
135
  data-container-1="product"
136
136
  data-product-1="00619947000020"
137
137
  type="text/javascript"
138
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
138
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
139
139
  ></script>
140
140
 
141
141
  <div id="product"></div>
@@ -187,7 +187,7 @@ You can use declarative initialization and programmatic control:
187
187
  data-token="YOUR_API_KEY"
188
188
  data-env="production"
189
189
  type="text/javascript"
190
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
190
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
191
191
  ></script>
192
192
 
193
193
  <script>
@@ -26,7 +26,7 @@ Add the following script tag to your page's `<head>` section:
26
26
  data-token="YOUR_API_KEY"
27
27
  data-env="production"
28
28
  type="text/javascript"
29
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
29
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
30
30
  ></script>
31
31
  ```
32
32
 
@@ -55,7 +55,7 @@ While the `<head>` section is recommended, the script can be placed anywhere on
55
55
  data-token="YOUR_API_KEY"
56
56
  data-env="production"
57
57
  type="text/javascript"
58
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
58
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
59
59
  ></script>
60
60
  </head>
61
61
  <body>
@@ -77,7 +77,7 @@ If you only need checkout functionality (without product displays or cart), use
77
77
  data-token="YOUR_API_KEY"
78
78
  data-env="production"
79
79
  type="text/javascript"
80
- src="https://assets-elements.liquidcommerce.us/checkout/elements.js"
80
+ src="https://elements.reservebar-worker.workers.dev/checkout/elements.js"
81
81
  ></script>
82
82
  ```
83
83
 
@@ -33,7 +33,7 @@ Add the Elements SDK script tag to your HTML `<head>`:
33
33
  data-token="YOUR_API_KEY"
34
34
  data-env="production"
35
35
  type="text/javascript"
36
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
36
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
37
37
  ></script>
38
38
  </head>
39
39
  <body>
@@ -70,7 +70,7 @@ Add product configuration using HTML data attributes on the script tag:
70
70
  data-container-1="product-display"
71
71
  data-product-1="00619947000020"
72
72
  type="text/javascript"
73
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
73
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
74
74
  ></script>
75
75
  ```
76
76
 
@@ -103,7 +103,7 @@ Here's the complete HTML for a working product page:
103
103
  data-container-1="product-display"
104
104
  data-product-1="00619947000020"
105
105
  type="text/javascript"
106
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
106
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
107
107
  ></script>
108
108
 
109
109
  <style>
@@ -150,7 +150,7 @@ If you prefer JavaScript over HTML attributes:
150
150
  data-token="YOUR_API_KEY"
151
151
  data-env="production"
152
152
  type="text/javascript"
153
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
153
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
154
154
  ></script>
155
155
 
156
156
  <script defer>
@@ -216,7 +216,7 @@ To display multiple products on one page:
216
216
  data-product-3="08068660001"
217
217
 
218
218
  type="text/javascript"
219
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
219
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
220
220
  ></script>
221
221
 
222
222
  <div id="product-1"></div>
@@ -347,7 +347,7 @@ Try this complete example with your API key:
347
347
  data-container-1="product"
348
348
  data-product-1="00619947000020"
349
349
  type="text/javascript"
350
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
350
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
351
351
  ></script>
352
352
 
353
353
  <style>
@@ -200,7 +200,7 @@ Create a dedicated page for address selection:
200
200
  data-token="YOUR_API_KEY"
201
201
  data-env="production"
202
202
  type="text/javascript"
203
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
203
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
204
204
  ></script>
205
205
  </head>
206
206
  <body>
@@ -31,7 +31,7 @@ Add a cart button using data attributes on the SDK script:
31
31
  data-env="production"
32
32
  data-cart-button="header-cart"
33
33
  type="text/javascript"
34
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
34
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
35
35
  ></script>
36
36
 
37
37
  <div id="header-cart"></div>
@@ -49,7 +49,7 @@ Show the number of items in the cart:
49
49
  data-env="production"
50
50
  data-cart-badge-button="header-cart"
51
51
  type="text/javascript"
52
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
52
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
53
53
  ></script>
54
54
 
55
55
  <div id="header-cart"></div>
@@ -67,7 +67,7 @@ Create a floating button (bottom-right corner):
67
67
  data-env="production"
68
68
  data-cart-button
69
69
  type="text/javascript"
70
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
70
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
71
71
  ></script>
72
72
  ```
73
73
 
@@ -103,7 +103,7 @@ If you want to control cart opening manually:
103
103
  data-env="production"
104
104
  data-cart-button-hidden
105
105
  type="text/javascript"
106
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
106
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
107
107
  ></script>
108
108
  ```
109
109
 
@@ -514,7 +514,7 @@ Or with data attributes:
514
514
  data-promo-active-from="2024-06-01T00:00:00Z"
515
515
  data-promo-active-until="2024-08-31T23:59:59Z"
516
516
  type="text/javascript"
517
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
517
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
518
518
  ></script>
519
519
  ```
520
520
 
@@ -530,7 +530,7 @@ Apply promo codes automatically via URL parameters:
530
530
  data-env="production"
531
531
  data-promo-code-param="lce_promo"
532
532
  type="text/javascript"
533
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
533
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
534
534
  ></script>
535
535
  ```
536
536
 
@@ -593,7 +593,7 @@ Or with data attributes:
593
593
  data-env="production"
594
594
  data-checkout-url="https://yoursite.com/checkout/{token}"
595
595
  type="text/javascript"
596
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
596
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
597
597
  ></script>
598
598
  ```
599
599
 
@@ -48,7 +48,7 @@ Configure checkout to load from URL parameter:
48
48
  data-checkout-container="checkout"
49
49
  data-checkout-param="lce_checkout"
50
50
  type="text/javascript"
51
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
51
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
52
52
  ></script>
53
53
 
54
54
  <div id="checkout"></div>
@@ -79,7 +79,7 @@ Or with data attributes:
79
79
  data-env="production"
80
80
  data-checkout-url="https://yoursite.com/checkout?lce_checkout={token}"
81
81
  type="text/javascript"
82
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
82
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
83
83
  ></script>
84
84
  ```
85
85
 
@@ -29,7 +29,7 @@ The simplest way to add a product is using HTML data attributes:
29
29
  data-container-1="product-display"
30
30
  data-product-1="00619947000020"
31
31
  type="text/javascript"
32
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
32
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
33
33
  ></script>
34
34
 
35
35
  <div id="product-display"></div>
@@ -48,7 +48,7 @@ The simplest way to add a product is using HTML data attributes:
48
48
  data-container-2="product-2"
49
49
  data-product-2="08504405135"
50
50
  type="text/javascript"
51
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
51
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
52
52
  ></script>
53
53
 
54
54
  <div id="product-1"></div>
@@ -66,7 +66,7 @@ Use `data-lce-product` on any div:
66
66
  data-token="YOUR_API_KEY"
67
67
  data-env="production"
68
68
  type="text/javascript"
69
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
69
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
70
70
  ></script>
71
71
 
72
72
  <div data-lce-product="00619947000020"></div>
@@ -86,7 +86,7 @@ For many products, use a JSON script tag:
86
86
  data-token="YOUR_API_KEY"
87
87
  data-env="production"
88
88
  type="text/javascript"
89
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
89
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
90
90
  ></script>
91
91
 
92
92
  <script data-liquid-commerce-elements-products type="application/json">
@@ -496,7 +496,7 @@ If product data fails to load:
496
496
  data-container-1="product"
497
497
  data-product-1="00619947000020"
498
498
  type="text/javascript"
499
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
499
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
500
500
  ></script>
501
501
  </head>
502
502
  <body>
@@ -25,7 +25,7 @@ Use data attributes to configure the product list:
25
25
  data-liquid-commerce-elements
26
26
  data-token="YOUR_API_KEY"
27
27
  data-env="production"
28
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
28
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
29
29
  ></script>
30
30
 
31
31
  <div
@@ -336,7 +336,7 @@ const client = await Elements('YOUR_API_KEY', {
336
336
  data-liquid-commerce-elements
337
337
  data-token="YOUR_API_KEY"
338
338
  data-env="production"
339
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
339
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
340
340
  ></script>
341
341
  </head>
342
342
  <body>
@@ -21,7 +21,7 @@ Use the CDN build in a Blade view for a quick server-rendered setup.
21
21
  data-container-1="product"
22
22
  data-product-1="00619947000020"
23
23
  type="text/javascript"
24
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
24
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
25
25
  ></script>
26
26
  </head>
27
27
  <body>
@@ -21,7 +21,7 @@ Use the CDN build for the fastest setup, or use NPM if you have a build step.
21
21
  data-product-1="00619947000020"
22
22
  data-cart-badge-button="header-cart"
23
23
  type="text/javascript"
24
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
24
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
25
25
  ></script>
26
26
  </head>
27
27
  <body>
@@ -46,7 +46,7 @@ Use the CDN build for the fastest setup, or use NPM if you have a build step.
46
46
  data-token="YOUR_API_KEY"
47
47
  data-env="production"
48
48
  type="text/javascript"
49
- src="https://assets-elements.liquidcommerce.us/all/elements.js"
49
+ src="https://elements.reservebar-worker.workers.dev/all/elements.js"
50
50
  ></script>
51
51
 
52
52
  <script>