@liquidcommerce/elements-sdk 2.6.0-beta.12 → 2.6.0-beta.120
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +100 -2518
- package/dist/index.checkout.esm.js +19988 -0
- package/dist/index.esm.js +27974 -20438
- package/dist/ssr-stub.checkout.esm.js +17 -0
- package/dist/ssr-stub.esm.js +275 -0
- package/dist/types/auto-initialize/checkout.d.ts +2 -0
- package/dist/types/auto-initialize/shared-utils.d.ts +51 -0
- package/dist/types/{elements-base-client.d.ts → clients/base.d.ts} +16 -2
- package/dist/types/clients/builder.d.ts +3 -0
- package/dist/types/clients/checkout.d.ts +6 -0
- package/dist/types/clients/helpers.d.ts +8 -0
- package/dist/types/clients/main.d.ts +3 -0
- package/dist/types/constants/core.constant.d.ts +13 -18
- package/dist/types/constants/index.d.ts +1 -0
- package/dist/types/constants/prop65.constant.d.ts +8 -0
- package/dist/types/core/a11y/announcer.service.d.ts +16 -0
- package/dist/types/core/a11y/focus-manager.service.d.ts +21 -0
- package/dist/types/core/a11y/focusable.d.ts +5 -0
- package/dist/types/core/a11y/glyph-button.d.ts +8 -0
- package/dist/types/core/a11y/index.d.ts +6 -0
- package/dist/types/core/a11y/required.d.ts +1 -0
- package/dist/types/core/a11y/single-select.d.ts +20 -0
- package/dist/types/core/api/api-client.service.d.ts +22 -18
- package/dist/types/core/api/api-result.d.ts +19 -0
- package/dist/types/core/api/auth-client.service.d.ts +37 -13
- package/dist/types/core/api/http-client.service.d.ts +0 -8
- package/dist/types/core/base-component.service.d.ts +4 -1
- package/dist/types/core/client/actions/base-action.service.d.ts +22 -0
- package/dist/types/core/client/actions/client-address-action.service.d.ts +18 -0
- package/dist/types/core/client/actions/client-cart-action.service.d.ts +38 -0
- package/dist/types/core/client/actions/client-checkout-action.service.d.ts +75 -0
- package/dist/types/core/client/actions/client-product-action.service.d.ts +15 -0
- package/dist/types/core/client/client-action.service.d.ts +6 -74
- package/dist/types/core/client/client-config.service.d.ts +10 -5
- package/dist/types/core/debug-panel/debug-panel.styles.d.ts +1 -1
- package/dist/types/core/google-tag-manager.service.d.ts +10 -1
- package/dist/types/core/logger/logger.service.d.ts +1 -1
- package/dist/types/core/pubsub/interfaces/address.interface.d.ts +3 -0
- package/dist/types/core/pubsub/interfaces/cart.interface.d.ts +6 -1
- package/dist/types/core/pubsub/interfaces/checkout.interface.d.ts +39 -49
- package/dist/types/core/pubsub/interfaces/core.interface.d.ts +14 -7
- package/dist/types/core/pubsub/pubsub.service.d.ts +1 -2
- package/dist/types/core/singleton-manager.service.d.ts +12 -8
- package/dist/types/core/store/interfaces/cart.interface.d.ts +2 -3
- package/dist/types/core/store/interfaces/checkout.interface.d.ts +28 -107
- package/dist/types/core/store/interfaces/core.interface.d.ts +12 -2
- package/dist/types/core/store/interfaces/metadata.interface.d.ts +11 -0
- package/dist/types/core/store/interfaces/product-list.interface.d.ts +30 -0
- package/dist/types/core/store/interfaces/product.interface.d.ts +1 -0
- package/dist/types/core/store/store.constant.d.ts +5 -0
- package/dist/types/core/store/store.service.d.ts +1 -0
- package/dist/types/core/telemetry/telemetry.service.d.ts +1 -0
- package/dist/types/enums/core.enum.d.ts +45 -2
- package/dist/types/enums/index.d.ts +0 -1
- package/dist/types/index.checkout.d.ts +9 -0
- package/dist/types/index.checkout.umd.d.ts +4 -0
- package/dist/types/index.d.ts +8 -3
- package/dist/types/interfaces/api/cart.interface.d.ts +12 -7
- package/dist/types/interfaces/api/checkout.interface.d.ts +246 -0
- package/dist/types/interfaces/api/index.d.ts +5 -0
- package/dist/types/interfaces/api/product-list.interface.d.ts +15 -6
- package/dist/types/interfaces/api/product.interface.d.ts +10 -4
- package/dist/types/interfaces/client.interface.d.ts +74 -0
- package/dist/types/interfaces/component.interface.d.ts +7 -0
- package/dist/types/interfaces/config.interface.d.ts +44 -0
- package/dist/types/interfaces/configs/address.interface.d.ts +1 -1
- package/dist/types/interfaces/configs/cart.interface.d.ts +2 -1
- package/dist/types/interfaces/configs/checkout.interface.d.ts +3 -1
- package/dist/types/interfaces/configs/global.interface.d.ts +9 -3
- package/dist/types/interfaces/configs/index.d.ts +1 -0
- package/dist/types/interfaces/configs/product-list.interface.d.ts +49 -0
- package/dist/types/interfaces/configs/product.interface.d.ts +7 -1
- package/dist/types/interfaces/injection.interface.d.ts +56 -0
- package/dist/types/modules/address/address-display.component.d.ts +3 -1
- package/dist/types/modules/address/address-input.component.d.ts +10 -1
- package/dist/types/modules/address/address.command.d.ts +2 -1
- package/dist/types/modules/address/styles/register-styles.d.ts +1 -0
- package/dist/types/modules/cart/cart.commands.d.ts +9 -5
- package/dist/types/modules/cart/components/cart-body.component.d.ts +1 -0
- package/dist/types/modules/cart/components/cart-fulfillment.component.d.ts +1 -1
- package/dist/types/modules/cart/components/cart-item-quantity-price.component.d.ts +5 -0
- package/dist/types/modules/cart/components/cart-item.component.d.ts +6 -0
- package/dist/types/modules/cart/styles/register-styles.d.ts +1 -0
- package/dist/types/modules/checkout/checkout.commands.d.ts +84 -12
- package/dist/types/modules/checkout/checkout.component.d.ts +6 -1
- package/dist/types/modules/checkout/components/checkout-billing.component.d.ts +5 -2
- package/dist/types/modules/checkout/components/checkout-buyer.component.d.ts +1 -0
- package/dist/types/modules/checkout/components/checkout-completed.component.d.ts +5 -0
- package/dist/types/modules/checkout/components/checkout-deliver-to.component.d.ts +1 -0
- package/dist/types/modules/checkout/components/checkout-express-checkout.component.d.ts +61 -0
- package/dist/types/modules/checkout/components/checkout-express-completion.component.d.ts +21 -0
- package/dist/types/modules/checkout/components/checkout-header.component.d.ts +1 -0
- package/dist/types/modules/checkout/components/checkout-item-quantity.component.d.ts +4 -0
- package/dist/types/modules/checkout/components/checkout-items.component.d.ts +4 -3
- package/dist/types/modules/checkout/components/checkout-order-summary.component.d.ts +3 -0
- package/dist/types/modules/checkout/components/checkout-payment.component.d.ts +6 -1
- package/dist/types/modules/checkout/components/checkout-place-order-button.component.d.ts +2 -0
- package/dist/types/modules/checkout/components/checkout-presale-countdown.component.d.ts +15 -1
- package/dist/types/modules/checkout/components/checkout-presale-expired.component.d.ts +7 -1
- package/dist/types/modules/checkout/components/checkout-prop65-warning.component.d.ts +8 -0
- package/dist/types/modules/checkout/components/checkout-send-as-gift.component.d.ts +3 -0
- package/dist/types/modules/checkout/components/checkout-stripe-form.component.d.ts +7 -2
- package/dist/types/modules/checkout/components/checkout-tips.component.d.ts +4 -2
- package/dist/types/modules/checkout/components/index.d.ts +3 -0
- package/dist/types/modules/checkout/components/promo-pc-gc.component.d.ts +0 -2
- package/dist/types/modules/checkout/components/required-fields-legend.d.ts +1 -0
- package/dist/types/modules/checkout/constant.d.ts +5 -0
- package/dist/types/modules/checkout/customer-prefill.d.ts +5 -0
- package/dist/types/modules/checkout/express-wallet.d.ts +12 -0
- package/dist/types/modules/checkout/payment-session-error.d.ts +4 -0
- package/dist/types/modules/checkout/styles/express-checkout.style.d.ts +1 -0
- package/dist/types/modules/checkout/styles/express-completion.style.d.ts +1 -0
- package/dist/types/modules/checkout/styles/register-styles.d.ts +1 -0
- package/dist/types/modules/product/components/components.d.ts +26 -2
- package/dist/types/modules/product/components/index.d.ts +1 -0
- package/dist/types/modules/product/components/product-add-to-cart-section.component.d.ts +8 -1
- package/dist/types/modules/product/components/product-delivery-estimate.component.d.ts +11 -0
- package/dist/types/modules/product/components/product-description.component.d.ts +1 -0
- package/dist/types/modules/product/components/product-drawer.component.d.ts +6 -0
- package/dist/types/modules/product/components/product-image-carousel.component.d.ts +5 -0
- package/dist/types/modules/product/components/product-options.component.d.ts +2 -1
- package/dist/types/modules/product/components/product-prop65-warning.d.ts +1 -0
- package/dist/types/modules/product/components/product-retailers-carousel.component.d.ts +6 -0
- package/dist/types/modules/product/components/product-retailers-popup-list.component.d.ts +12 -2
- package/dist/types/modules/product/components/product-retailers-popup.component.d.ts +1 -0
- package/dist/types/modules/product/components/product-retailers.component.d.ts +1 -0
- package/dist/types/modules/product/product.commands.d.ts +5 -5
- package/dist/types/modules/product/product.component.d.ts +3 -0
- package/dist/types/modules/product/styles/prop65-warning.style.d.ts +1 -0
- package/dist/types/modules/product/styles/register-styles.d.ts +1 -0
- package/dist/types/modules/product-list/components/card-components/index.d.ts +6 -0
- package/dist/types/modules/product-list/components/card-components/product-badge.d.ts +9 -0
- package/dist/types/modules/product-list/components/card-components/product-button.d.ts +11 -0
- package/dist/types/modules/product-list/components/card-components/product-fulfillment-text.d.ts +2 -0
- package/dist/types/modules/product-list/components/card-components/product-price-and-personalization.d.ts +14 -0
- package/dist/types/modules/product-list/components/card-components/product-quantity-selector.d.ts +11 -0
- package/dist/types/modules/product-list/components/card-components/product-sizes-list.d.ts +14 -0
- package/dist/types/modules/product-list/components/filter-components/index.d.ts +7 -0
- package/dist/types/modules/product-list/components/filter-components/product-list-apply-filter-button.d.ts +1 -0
- package/dist/types/modules/product-list/components/{product-list-filters-subcomponents/product-list-checkbox-filter.components.d.ts → filter-components/product-list-checkbox-filter.d.ts} +1 -0
- package/dist/types/modules/product-list/components/filter-components/product-list-chip.d.ts +5 -0
- package/dist/types/modules/product-list/components/filter-components/product-list-filters-chips.d.ts +13 -0
- package/dist/types/modules/product-list/components/filter-components/product-list-fulfillment-filter.d.ts +15 -0
- package/dist/types/modules/product-list/components/{product-list-filters-subcomponents/product-list-price-filter.components.d.ts → filter-components/product-list-price-filter.d.ts} +2 -1
- package/dist/types/modules/product-list/components/filter-components/product-list-toggle-filters.d.ts +7 -0
- package/dist/types/modules/product-list/components/index.d.ts +6 -2
- package/dist/types/modules/product-list/components/product-list-card-loading.component.d.ts +3 -1
- package/dist/types/modules/product-list/components/product-list-card.component.d.ts +39 -31
- package/dist/types/modules/product-list/components/product-list-engraving.component.d.ts +12 -0
- package/dist/types/modules/product-list/components/product-list-filters.component.d.ts +58 -36
- package/dist/types/modules/product-list/components/product-list-product-engraving-lines.component.d.ts +22 -0
- package/dist/types/modules/product-list/components/product-list-product-pre-cart.component.d.ts +54 -0
- package/dist/types/modules/product-list/components/product-list-search.component.d.ts +25 -0
- package/dist/types/modules/product-list/product-list-filter.registry.d.ts +42 -0
- package/dist/types/modules/product-list/product-list-filter.utils.d.ts +7 -0
- package/dist/types/modules/product-list/product-list-order.utils.d.ts +3 -0
- package/dist/types/modules/product-list/product-list-query-params.utils.d.ts +3 -0
- package/dist/types/modules/product-list/product-list.commands.d.ts +22 -7
- package/dist/types/modules/product-list/product-list.component.d.ts +23 -47
- package/dist/types/modules/product-list/product-list.constants.d.ts +38 -0
- package/dist/types/modules/product-list/product-list.interface.d.ts +17 -28
- package/dist/types/modules/product-list/styles/product-list-card.style.d.ts +1 -0
- package/dist/types/modules/product-list/styles/product-list-filters.style.d.ts +1 -0
- package/dist/types/modules/product-list/styles/register-styles.d.ts +1 -0
- package/dist/types/modules/theme-provider/constants/component-groupings.d.ts +1 -0
- package/dist/types/modules/theme-provider/constants/css-variable-mappings.d.ts +1 -1
- package/dist/types/modules/theme-provider/services/style-registry.service.d.ts +16 -0
- package/dist/types/modules/theme-provider/services/stylesheet-generator.service.d.ts +0 -1
- package/dist/types/modules/theme-provider/styles/register-styles.d.ts +1 -0
- package/dist/types/modules/theme-provider/theme-provider.service.d.ts +2 -2
- package/dist/types/modules/ui-components/alert/alert.component.d.ts +1 -1
- package/dist/types/modules/ui-components/buttons/buttons-open-cart.component.d.ts +5 -0
- package/dist/types/modules/ui-components/drawer/drawer.component.d.ts +15 -0
- package/dist/types/modules/ui-components/engraving/engraving-form.component.d.ts +9 -1
- package/dist/types/modules/ui-components/engraving/engraving-view.component.d.ts +7 -1
- package/dist/types/modules/ui-components/input/index.d.ts +0 -1
- package/dist/types/modules/ui-components/input/input.component.d.ts +15 -2
- package/dist/types/modules/ui-components/lce-element/lce-element.component.d.ts +2 -1
- package/dist/types/modules/ui-components/promo-code-ticker/promo-code-ticker.component.d.ts +1 -1
- package/dist/types/modules/ui-components/ui.commands.d.ts +7 -1
- package/dist/types/ssr/stub.checkout.d.ts +6 -0
- package/dist/types/ssr/stub.d.ts +10 -0
- package/dist/types/static/icon/arrow-right.icon.d.ts +1 -1
- package/dist/types/static/icon/bag.icon.d.ts +1 -1
- package/dist/types/static/icon/check.icon.d.ts +2 -0
- package/dist/types/static/icon/checkbox.icon.d.ts +1 -1
- package/dist/types/static/icon/chevron-down.icon.d.ts +1 -1
- package/dist/types/static/icon/chevron-left.icon.d.ts +1 -1
- package/dist/types/static/icon/chevron-up.icon.d.ts +1 -1
- package/dist/types/static/icon/close.icon.d.ts +1 -1
- package/dist/types/static/icon/error-info.icon.d.ts +1 -1
- package/dist/types/static/icon/filter.icon.d.ts +1 -1
- package/dist/types/static/icon/icon.a11y.d.ts +1 -0
- package/dist/types/static/icon/icon.types.d.ts +1 -0
- package/dist/types/static/icon/index.d.ts +2 -0
- package/dist/types/static/icon/info.icon.d.ts +1 -1
- package/dist/types/static/icon/loading-spinner.icon.d.ts +1 -1
- package/dist/types/static/icon/search.icon.d.ts +1 -1
- package/dist/types/static/icon/success.icon.d.ts +1 -1
- package/dist/types/static/icon/trash.icon.d.ts +1 -1
- package/dist/types/static/icon/warning.icon.d.ts +1 -1
- package/dist/types/utils/dom-compat.d.ts +2 -0
- package/dist/types/utils/format.d.ts +9 -14
- package/dist/types/utils/image-bg-removal.d.ts +3 -0
- package/dist/types/utils/product-selection.d.ts +16 -0
- package/dist/types/utils/product.d.ts +21 -0
- package/dist/types/utils/timezone.d.ts +6 -0
- package/docs/v1/README.md +213 -0
- package/docs/v1/api/actions/address-actions.md +286 -0
- package/docs/v1/api/actions/cart-actions.md +364 -0
- package/docs/v1/api/actions/checkout-actions.md +586 -0
- package/docs/v1/api/actions/product-actions.md +204 -0
- package/docs/v1/api/client.md +664 -0
- package/docs/v1/api/configuration.md +583 -0
- package/docs/v1/api/injection-methods.md +331 -0
- package/docs/v1/api/typescript-types.md +501 -0
- package/docs/v1/api/ui-helpers.md +200 -0
- package/docs/v1/examples/advanced-patterns.md +199 -0
- package/docs/v1/examples/checkout-flow.md +90 -0
- package/docs/v1/examples/custom-theming.md +76 -0
- package/docs/v1/examples/multi-product-page.md +90 -0
- package/docs/v1/examples/simple-product-page.md +89 -0
- package/docs/v1/getting-started/concepts.md +521 -0
- package/docs/v1/getting-started/installation.md +351 -0
- package/docs/v1/getting-started/quick-start.md +410 -0
- package/docs/v1/guides/accessibility.md +280 -0
- package/docs/v1/guides/address-component.md +435 -0
- package/docs/v1/guides/best-practices.md +365 -0
- package/docs/v1/guides/cart-component.md +800 -0
- package/docs/v1/guides/checkout-component.md +806 -0
- package/docs/v1/guides/events.md +988 -0
- package/docs/v1/guides/product-component.md +761 -0
- package/docs/v1/guides/product-list-component.md +730 -0
- package/docs/v1/guides/theming.md +243 -0
- package/docs/v1/integration/angular.md +39 -0
- package/docs/v1/integration/laravel.md +41 -0
- package/docs/v1/integration/nextjs.md +69 -0
- package/docs/v1/integration/proxy-setup.md +106 -0
- package/docs/v1/integration/react.md +64 -0
- package/docs/v1/integration/vanilla-js.md +84 -0
- package/docs/v1/integration/vue.md +58 -0
- package/docs/v1/reference/analytics.md +133 -0
- package/docs/v1/reference/browser-support.md +47 -0
- package/docs/v1/reference/error-handling.md +83 -0
- package/docs/v1/reference/performance.md +52 -0
- package/docs/v1/reference/telemetry.md +85 -0
- package/docs/v1/reference/troubleshooting.md +135 -0
- package/package.json +75 -45
- package/dist/types/elements-builder-client.d.ts +0 -2
- package/dist/types/elements-client-helper.d.ts +0 -4
- package/dist/types/elements-client.d.ts +0 -2
- package/dist/types/enums/cloud.enum.d.ts +0 -97
- package/dist/types/interfaces/cloud/checkout.interface.d.ts +0 -218
- package/dist/types/interfaces/cloud/core.interface.d.ts +0 -22
- package/dist/types/interfaces/cloud/index.d.ts +0 -3
- package/dist/types/interfaces/cloud/retailer.interface.d.ts +0 -67
- package/dist/types/interfaces/cloud/user.interface.d.ts +0 -100
- package/dist/types/interfaces/core.interface.d.ts +0 -111
- package/dist/types/modules/checkout/components/checkout.type.d.ts +0 -4
- package/dist/types/modules/product-list/components/product-list-filters-subcomponents/index.d.ts +0 -6
- package/dist/types/modules/product-list/components/product-list-filters-subcomponents/product-list-apply-filter-button.component.d.ts +0 -1
- package/dist/types/modules/product-list/components/product-list-filters-subcomponents/product-list-delivery-options-filter.components.d.ts +0 -16
- package/dist/types/modules/product-list/components/product-list-filters-subcomponents/product-list-search.component.d.ts +0 -16
- package/dist/types/modules/product-list/components/product-list-filters-subcomponents/product-list-toggle-filters.components.d.ts +0 -18
- package/dist/types/modules/theme-provider/styles/address/index.d.ts +0 -1
- package/dist/types/modules/theme-provider/styles/cart/index.d.ts +0 -1
- package/dist/types/modules/theme-provider/styles/checkout/index.d.ts +0 -1
- package/dist/types/modules/theme-provider/styles/product/index.d.ts +0 -3
- package/dist/types/modules/theme-provider/styles/product-list/index.d.ts +0 -1
- package/dist/types/modules/theme-provider/styles/ui/index.d.ts +0 -3
- package/dist/types/modules/ui-components/input/birthdate-input.component.d.ts +0 -53
- package/dist/types/utils/helper.d.ts +0 -28
- package/docs/ACTIONS.md +0 -1300
- package/docs/BROWSER_SUPPORT.md +0 -279
- package/docs/CONFIGURATION.md +0 -853
- package/docs/DOCUMENTATION_INDEX.md +0 -311
- package/docs/EVENTS.md +0 -798
- package/docs/PROXY.md +0 -228
- package/docs/THEMING.md +0 -592
- package/docs/TROUBLESHOOTING.md +0 -793
- package/umd/elements.js +0 -1
- /package/dist/types/{auto-initialize.d.ts → auto-initialize/main.d.ts} +0 -0
- /package/dist/types/modules/{theme-provider/styles/address → address/styles}/address.style.d.ts +0 -0
- /package/dist/types/modules/{theme-provider/styles/cart → cart/styles}/cart.style.d.ts +0 -0
- /package/dist/types/modules/{theme-provider/styles/checkout → checkout/styles}/checkout.style.d.ts +0 -0
- /package/dist/types/modules/{theme-provider/styles/product → product/styles}/image-carousel.style.d.ts +0 -0
- /package/dist/types/modules/{theme-provider/styles/product → product/styles}/product.style.d.ts +0 -0
- /package/dist/types/modules/{theme-provider/styles/product → product/styles}/retailers.style.d.ts +0 -0
- /package/dist/types/modules/{theme-provider/styles/product-list → product-list/styles}/product-list.style.d.ts +0 -0
- /package/dist/types/modules/{theme-provider/styles/ui → ui-components/styles}/drawer.style.d.ts +0 -0
- /package/dist/types/modules/{theme-provider/styles/ui → ui-components/styles}/loading.style.d.ts +0 -0
- /package/dist/types/modules/{theme-provider/styles/ui → ui-components/styles}/promo-code-ticker.style.d.ts +0 -0
|
@@ -0,0 +1,583 @@
|
|
|
1
|
+
# Configuration Reference
|
|
2
|
+
|
|
3
|
+
Complete reference for all configuration options available in the Elements SDK.
|
|
4
|
+
|
|
5
|
+
## Client Configuration
|
|
6
|
+
|
|
7
|
+
### ILiquidCommerceElementsConfig
|
|
8
|
+
|
|
9
|
+
Top-level configuration passed to `Elements()` or `ElementsBuilder()`.
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
interface ILiquidCommerceElementsConfig {
|
|
13
|
+
env?: ElementsEnv;
|
|
14
|
+
promoTicker?: IPromoTicker[];
|
|
15
|
+
customTheme?: IClientCustomThemeConfig;
|
|
16
|
+
debugMode?: DebugMode;
|
|
17
|
+
checkout?: ILiquidCommerceElementsCheckoutConfig;
|
|
18
|
+
proxy?: IElementsProxyConfig;
|
|
19
|
+
gtm?: IElementsGTMConfig;
|
|
20
|
+
development?: ILiquidCommerceElementsDevelopmentConfig;
|
|
21
|
+
}
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
| Property | Type | Required | Description |
|
|
25
|
+
|----------|------|----------|-------------|
|
|
26
|
+
| `env` | `'staging' \| 'production'` | No | API environment |
|
|
27
|
+
| `promoTicker` | `IPromoTicker[]` | No | Promotional ticker configurations |
|
|
28
|
+
| `customTheme` | `IClientCustomThemeConfig` | No | Theme overrides for all components |
|
|
29
|
+
| `debugMode` | `'none' \| 'console' \| 'panel'` | No | Debug output mode |
|
|
30
|
+
| `checkout` | `ILiquidCommerceElementsCheckoutConfig` | No | Checkout behavior settings |
|
|
31
|
+
| `proxy` | `IElementsProxyConfig` | No | Proxy configuration for API requests |
|
|
32
|
+
| `gtm` | `IElementsGTMConfig` | No | Google tag gateway URL of your own GTM container |
|
|
33
|
+
| `development` | `ILiquidCommerceElementsDevelopmentConfig` | No | Development/testing options |
|
|
34
|
+
|
|
35
|
+
> **Note:** `debugMode` (`'console'` or `'panel'`) is **ignored in production** -- it is forced off when `env` is `'production'`. It only takes effect outside production (`'staging'`).
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
|
|
39
|
+
## Theme Configuration
|
|
40
|
+
|
|
41
|
+
### IClientCustomThemeConfig
|
|
42
|
+
|
|
43
|
+
Override default theme settings for any component.
|
|
44
|
+
|
|
45
|
+
```typescript
|
|
46
|
+
interface IClientCustomThemeConfig {
|
|
47
|
+
global?: UpdateComponentGlobalConfigs;
|
|
48
|
+
product?: UpdateProductComponent;
|
|
49
|
+
address?: UpdateAddressComponent;
|
|
50
|
+
cart?: UpdateCartComponent;
|
|
51
|
+
checkout?: UpdateCheckoutComponent;
|
|
52
|
+
productList?: UpdateProductListComponent;
|
|
53
|
+
}
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
All theme properties are deeply partial -- you only need to specify the values you want to override.
|
|
57
|
+
|
|
58
|
+
---
|
|
59
|
+
|
|
60
|
+
### Global Theme
|
|
61
|
+
|
|
62
|
+
#### IGlobalTheme
|
|
63
|
+
|
|
64
|
+
```typescript
|
|
65
|
+
interface IGlobalTheme {
|
|
66
|
+
buttonCornerRadius: string;
|
|
67
|
+
cardCornerRadius: string;
|
|
68
|
+
headingFont: IFontFamily;
|
|
69
|
+
paragraphFont: IFontFamily;
|
|
70
|
+
primaryColor: string;
|
|
71
|
+
accentColor: string;
|
|
72
|
+
defaultTextColor: string;
|
|
73
|
+
selectedTextColor: string;
|
|
74
|
+
linkTextColor: string;
|
|
75
|
+
errorColor: string;
|
|
76
|
+
warningColor: string;
|
|
77
|
+
successColor: string;
|
|
78
|
+
drawerBackgroundColor: string;
|
|
79
|
+
|
|
80
|
+
/**
|
|
81
|
+
* Boundary color for form fields. Optional; defaults to a neutral that clears the 3:1
|
|
82
|
+
* contrast required by WCAG 1.4.11.
|
|
83
|
+
*/
|
|
84
|
+
inputBorderColor?: string;
|
|
85
|
+
|
|
86
|
+
/** Keyboard focus ring color. Must reach 3:1 against the surface behind the control. */
|
|
87
|
+
focusRingColor?: string;
|
|
88
|
+
}
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
> `inputBorderColor` and `focusRingColor` are optional. Omit them to keep the WCAG-compliant
|
|
92
|
+
> defaults, or set them explicitly to keep those two details on-brand — any value you supply is used
|
|
93
|
+
> as given, so check its contrast. See [Accessibility](../guides/accessibility.md).
|
|
94
|
+
|
|
95
|
+
| Property | Type | Description |
|
|
96
|
+
|----------|------|-------------|
|
|
97
|
+
| `buttonCornerRadius` | `string` | CSS border-radius for buttons (e.g., `'8px'`) |
|
|
98
|
+
| `cardCornerRadius` | `string` | CSS border-radius for cards |
|
|
99
|
+
| `headingFont` | `IFontFamily` | Font family and weights for headings |
|
|
100
|
+
| `paragraphFont` | `IFontFamily` | Font family and weights for body text |
|
|
101
|
+
| `primaryColor` | `string` | Primary brand color (buttons, links, highlights) |
|
|
102
|
+
| `accentColor` | `string` | Secondary accent color |
|
|
103
|
+
| `defaultTextColor` | `string` | Default text color |
|
|
104
|
+
| `selectedTextColor` | `string` | Text color for selected/active elements |
|
|
105
|
+
| `linkTextColor` | `string` | Color for links |
|
|
106
|
+
| `errorColor` | `string` | Color for error states |
|
|
107
|
+
| `warningColor` | `string` | Color for warning states |
|
|
108
|
+
| `successColor` | `string` | Color for success states |
|
|
109
|
+
| `drawerBackgroundColor` | `string` | Background color for drawer components |
|
|
110
|
+
|
|
111
|
+
#### IFontFamily
|
|
112
|
+
|
|
113
|
+
```typescript
|
|
114
|
+
interface IFontFamily {
|
|
115
|
+
name: string; // Google Font name (e.g., 'Inter')
|
|
116
|
+
weights: number[]; // Font weights to load (e.g., [400, 500, 700])
|
|
117
|
+
}
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
> **Note:** Only Google Fonts are supported -- `name` must be a valid Google Fonts family. `Poppins` is always injected as the default font family in addition to any fonts you specify. Font loading requires network access to `fonts.googleapis.com` and `fonts.gstatic.com`; if you run behind a CSP or proxy, allow these hosts.
|
|
121
|
+
|
|
122
|
+
#### IGlobalLayout
|
|
123
|
+
|
|
124
|
+
```typescript
|
|
125
|
+
interface IGlobalLayout {
|
|
126
|
+
enablePersonalization: boolean;
|
|
127
|
+
personalizationText: string;
|
|
128
|
+
personalizationCardStyle: 'outlined' | 'filled';
|
|
129
|
+
allowPromoCodes: boolean;
|
|
130
|
+
inputFieldStyle: 'outlined' | 'filled';
|
|
131
|
+
enableOrderedProductSizes: boolean;
|
|
132
|
+
orderedProductSizes: string[];
|
|
133
|
+
showPoweredBy: boolean;
|
|
134
|
+
poweredByMode: 'light' | 'dark';
|
|
135
|
+
}
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
| Property | Type | Description |
|
|
139
|
+
|----------|------|-------------|
|
|
140
|
+
| `enablePersonalization` | `boolean` | Enable engraving/personalization features |
|
|
141
|
+
| `personalizationText` | `string` | Label text for personalization option |
|
|
142
|
+
| `personalizationCardStyle` | `'outlined' \| 'filled'` | Visual style for personalization cards |
|
|
143
|
+
| `allowPromoCodes` | `boolean` | Show promo code inputs in cart/checkout |
|
|
144
|
+
| `inputFieldStyle` | `'outlined' \| 'filled'` | Visual style for input fields |
|
|
145
|
+
| `enableOrderedProductSizes` | `boolean` | Enable a fixed display order for product/PLC size selectors (defined by `orderedProductSizes`) instead of the default ordering |
|
|
146
|
+
| `orderedProductSizes` | `string[]` | Ordered list of size values controlling the sequence in which size selectors are rendered; changes trigger targeted rerenders of the affected size selectors |
|
|
147
|
+
| `showPoweredBy` | `boolean` | Show "Powered by LiquidCommerce" badge |
|
|
148
|
+
| `poweredByMode` | `'light' \| 'dark'` | Colour mode for the checkout: the powered-by badge, the Stripe payment form, and the California Proposition 65 warning panel |
|
|
149
|
+
|
|
150
|
+
> **Note:** `showPoweredBy` is a server/plan-controlled setting and **cannot** be overridden by hosts. Any value supplied via `customTheme` (or a later config update) is stripped and the server value is restored. Only `poweredByMode` (`'light' \| 'dark'`) is host-overridable.
|
|
151
|
+
|
|
152
|
+
**Example:**
|
|
153
|
+
|
|
154
|
+
```javascript
|
|
155
|
+
customTheme: {
|
|
156
|
+
global: {
|
|
157
|
+
theme: {
|
|
158
|
+
primaryColor: '#007bff',
|
|
159
|
+
buttonCornerRadius: '8px',
|
|
160
|
+
headingFont: { name: 'Inter', weights: [400, 600, 700] }
|
|
161
|
+
},
|
|
162
|
+
layout: {
|
|
163
|
+
allowPromoCodes: true,
|
|
164
|
+
inputFieldStyle: 'outlined'
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
---
|
|
171
|
+
|
|
172
|
+
### Product Theme
|
|
173
|
+
|
|
174
|
+
#### IProductComponent
|
|
175
|
+
|
|
176
|
+
```typescript
|
|
177
|
+
interface IProductComponent {
|
|
178
|
+
theme: IProductTheme;
|
|
179
|
+
layout: IProductLayout;
|
|
180
|
+
}
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
#### IProductTheme
|
|
184
|
+
|
|
185
|
+
```typescript
|
|
186
|
+
interface IProductTheme {
|
|
187
|
+
backgroundColor: string;
|
|
188
|
+
}
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
#### IProductLayout
|
|
192
|
+
|
|
193
|
+
```typescript
|
|
194
|
+
interface IProductLayout {
|
|
195
|
+
showImages: boolean;
|
|
196
|
+
showOnlyMainImage: boolean;
|
|
197
|
+
showTitle: boolean;
|
|
198
|
+
showDescription: boolean;
|
|
199
|
+
descriptionPosition: 'above' | 'below';
|
|
200
|
+
showQuantityCounter: boolean;
|
|
201
|
+
showOffHours: boolean;
|
|
202
|
+
quantityCounterStyle: 'outlined' | 'ghost';
|
|
203
|
+
fulfillmentDisplay: 'carousel' | 'popup';
|
|
204
|
+
enableShippingFulfillment: boolean;
|
|
205
|
+
enableOnDemandFulfillment: boolean;
|
|
206
|
+
primaryFulfillmentMethod: 'shipping' | 'onDemand';
|
|
207
|
+
showOnlyOneRetailer: boolean;
|
|
208
|
+
hideRetailerName: boolean;
|
|
209
|
+
addToCartButtonText: string;
|
|
210
|
+
addToCartButtonShowTotalPrice: boolean;
|
|
211
|
+
buyNowButtonText: string;
|
|
212
|
+
preSaleButtonText: string;
|
|
213
|
+
prioritizeEngraving: boolean;
|
|
214
|
+
noAvailabilityText: string;
|
|
215
|
+
}
|
|
216
|
+
```
|
|
217
|
+
|
|
218
|
+
| Property | Type | Description |
|
|
219
|
+
|----------|------|-------------|
|
|
220
|
+
| `showImages` | `boolean` | Show product image carousel |
|
|
221
|
+
| `showOnlyMainImage` | `boolean` | Show only the main product image (no carousel) |
|
|
222
|
+
| `showTitle` | `boolean` | Show product title |
|
|
223
|
+
| `showDescription` | `boolean` | Show product description |
|
|
224
|
+
| `descriptionPosition` | `'above' \| 'below'` | Placement of the product description relative to other content |
|
|
225
|
+
| `showQuantityCounter` | `boolean` | Show quantity selector |
|
|
226
|
+
| `showOffHours` | `boolean` | Show off-hours messaging |
|
|
227
|
+
| `quantityCounterStyle` | `'outlined' \| 'ghost'` | Visual style for quantity counter |
|
|
228
|
+
| `fulfillmentDisplay` | `'carousel' \| 'popup'` | How to display fulfillment/retailer options |
|
|
229
|
+
| `enableShippingFulfillment` | `boolean` | Enable shipping fulfillment option |
|
|
230
|
+
| `enableOnDemandFulfillment` | `boolean` | Enable on-demand delivery option |
|
|
231
|
+
| `primaryFulfillmentMethod` | `'shipping' \| 'onDemand'` | Fulfillment method shown first and selected by default; falls back to the other enabled method when it has no availability |
|
|
232
|
+
| `showOnlyOneRetailer` | `boolean` | Admin setting. Availability is narrowed server-side to one shipping and one on-demand retailer per product |
|
|
233
|
+
| `hideRetailerName` | `boolean` | Admin setting, honoured only with `showOnlyOneRetailer`. Availability is narrowed to one retailer and one delivery method per size, and the product component and product list show only its delivery estimate (e.g. "Ships in 2-3 days") instead of the retailer choice. Cart and checkout still show the retailer |
|
|
234
|
+
| `addToCartButtonText` | `string` | Custom text for add-to-cart button |
|
|
235
|
+
| `addToCartButtonShowTotalPrice` | `boolean` | Show total price on add-to-cart button |
|
|
236
|
+
| `buyNowButtonText` | `string` | Custom text for buy-now button |
|
|
237
|
+
| `preSaleButtonText` | `string` | Custom text for pre-sale button |
|
|
238
|
+
| `prioritizeEngraving` | `boolean` | Show engraving option before add-to-cart |
|
|
239
|
+
| `noAvailabilityText` | `string` | Text shown when product is unavailable |
|
|
240
|
+
|
|
241
|
+
**Example:**
|
|
242
|
+
|
|
243
|
+
```javascript
|
|
244
|
+
customTheme: {
|
|
245
|
+
product: {
|
|
246
|
+
layout: {
|
|
247
|
+
fulfillmentDisplay: 'popup',
|
|
248
|
+
addToCartButtonText: 'Add to Bag',
|
|
249
|
+
showQuantityCounter: true
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
}
|
|
253
|
+
```
|
|
254
|
+
|
|
255
|
+
---
|
|
256
|
+
|
|
257
|
+
### Cart Theme
|
|
258
|
+
|
|
259
|
+
#### ICartComponent
|
|
260
|
+
|
|
261
|
+
```typescript
|
|
262
|
+
interface ICartComponent {
|
|
263
|
+
theme: ICartTheme;
|
|
264
|
+
layout: ICartLayout;
|
|
265
|
+
}
|
|
266
|
+
```
|
|
267
|
+
|
|
268
|
+
#### ICartTheme
|
|
269
|
+
|
|
270
|
+
```typescript
|
|
271
|
+
interface ICartTheme {
|
|
272
|
+
backgroundColor: string;
|
|
273
|
+
}
|
|
274
|
+
```
|
|
275
|
+
|
|
276
|
+
#### ICartLayout
|
|
277
|
+
|
|
278
|
+
```typescript
|
|
279
|
+
interface ICartLayout {
|
|
280
|
+
showShopRetailerButton?: boolean;
|
|
281
|
+
showQuantityCounter: boolean;
|
|
282
|
+
quantityCounterStyle: 'outlined' | 'ghost';
|
|
283
|
+
drawerHeaderText: string;
|
|
284
|
+
goToCheckoutButtonText: string;
|
|
285
|
+
}
|
|
286
|
+
```
|
|
287
|
+
|
|
288
|
+
| Property | Type | Description |
|
|
289
|
+
|----------|------|-------------|
|
|
290
|
+
| `showShopRetailerButton` | `boolean` | Default `false`, including older server themes. Shows the retailer shopping button for eligible unmet minimums; requires a `cart_shop_retailer` event handler. |
|
|
291
|
+
| `showQuantityCounter` | `boolean` | Show quantity counter in cart items |
|
|
292
|
+
| `quantityCounterStyle` | `'outlined' \| 'ghost'` | Visual style for quantity counter |
|
|
293
|
+
| `drawerHeaderText` | `string` | Header text for the cart drawer |
|
|
294
|
+
| `goToCheckoutButtonText` | `string` | Custom text for checkout button |
|
|
295
|
+
|
|
296
|
+
**Example:**
|
|
297
|
+
|
|
298
|
+
```javascript
|
|
299
|
+
customTheme: {
|
|
300
|
+
cart: {
|
|
301
|
+
theme: { backgroundColor: '#f8f9fa' },
|
|
302
|
+
layout: {
|
|
303
|
+
drawerHeaderText: 'Your Bag',
|
|
304
|
+
goToCheckoutButtonText: 'Proceed to Checkout'
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
```
|
|
309
|
+
|
|
310
|
+
---
|
|
311
|
+
|
|
312
|
+
### Checkout Theme
|
|
313
|
+
|
|
314
|
+
#### ICheckoutComponent
|
|
315
|
+
|
|
316
|
+
```typescript
|
|
317
|
+
interface ICheckoutComponent {
|
|
318
|
+
theme: ICheckoutTheme;
|
|
319
|
+
layout: ICheckoutLayout;
|
|
320
|
+
}
|
|
321
|
+
```
|
|
322
|
+
|
|
323
|
+
#### ICheckoutTheme
|
|
324
|
+
|
|
325
|
+
```typescript
|
|
326
|
+
interface ICheckoutTheme {
|
|
327
|
+
backgroundColor: string;
|
|
328
|
+
}
|
|
329
|
+
```
|
|
330
|
+
|
|
331
|
+
#### ICheckoutLayout
|
|
332
|
+
|
|
333
|
+
```typescript
|
|
334
|
+
interface ICheckoutLayout {
|
|
335
|
+
emailOptIn: ICheckoutMarketingOptIn;
|
|
336
|
+
smsOptIn: ICheckoutMarketingOptIn;
|
|
337
|
+
allowGiftCards: boolean;
|
|
338
|
+
requireBirthDate?: boolean;
|
|
339
|
+
legalMessage: ICheckoutLegalMessage;
|
|
340
|
+
continueShoppingUrl: string;
|
|
341
|
+
exitUrl: string;
|
|
342
|
+
thankYouButtonText: string;
|
|
343
|
+
drawerHeaderText: string;
|
|
344
|
+
placeOrderButtonText: string;
|
|
345
|
+
checkoutCompleted: ICheckoutCompleted;
|
|
346
|
+
}
|
|
347
|
+
```
|
|
348
|
+
|
|
349
|
+
| Property | Type | Description |
|
|
350
|
+
|----------|------|-------------|
|
|
351
|
+
| `emailOptIn` | `ICheckoutMarketingOptIn` | Email marketing opt-in configuration |
|
|
352
|
+
| `smsOptIn` | `ICheckoutMarketingOptIn` | SMS marketing opt-in configuration |
|
|
353
|
+
| `allowGiftCards` | `boolean` | Enable gift card payment option |
|
|
354
|
+
| `requireBirthDate` | `boolean` | Whether the shopper must enter a date of birth to place an order. Defaults to `true`. When `false` the form's field is optional and express checkout does not ask for it |
|
|
355
|
+
| `legalMessage` | `ICheckoutLegalMessage` | Legal/terms message configuration |
|
|
356
|
+
| `continueShoppingUrl` | `string` | URL for "Continue Shopping" link |
|
|
357
|
+
| `exitUrl` | `string` | URL for exit/back navigation |
|
|
358
|
+
| `thankYouButtonText` | `string` | Button text on order confirmation page |
|
|
359
|
+
| `drawerHeaderText` | `string` | Header text for checkout drawer |
|
|
360
|
+
| `placeOrderButtonText` | `string` | Custom text for place order button |
|
|
361
|
+
| `checkoutCompleted` | `ICheckoutCompleted` | Order confirmation page customization |
|
|
362
|
+
|
|
363
|
+
#### ICheckoutMarketingOptIn
|
|
364
|
+
|
|
365
|
+
```typescript
|
|
366
|
+
interface ICheckoutMarketingOptIn {
|
|
367
|
+
show: boolean; // Show the opt-in checkbox
|
|
368
|
+
checked: boolean; // Default checked state
|
|
369
|
+
text: string; // Label text (supports rich HTML)
|
|
370
|
+
}
|
|
371
|
+
```
|
|
372
|
+
|
|
373
|
+
#### ICheckoutLegalMessage
|
|
374
|
+
|
|
375
|
+
```typescript
|
|
376
|
+
interface ICheckoutLegalMessage {
|
|
377
|
+
show: boolean; // Show the legal message
|
|
378
|
+
text: string; // Message content (supports rich HTML)
|
|
379
|
+
}
|
|
380
|
+
```
|
|
381
|
+
|
|
382
|
+
#### ICheckoutCompleted
|
|
383
|
+
|
|
384
|
+
```typescript
|
|
385
|
+
interface ICheckoutCompleted {
|
|
386
|
+
customLogo: string; // URL to custom logo image
|
|
387
|
+
customText: string | null; // Custom confirmation text
|
|
388
|
+
}
|
|
389
|
+
```
|
|
390
|
+
|
|
391
|
+
**Example:**
|
|
392
|
+
|
|
393
|
+
```javascript
|
|
394
|
+
customTheme: {
|
|
395
|
+
checkout: {
|
|
396
|
+
layout: {
|
|
397
|
+
placeOrderButtonText: 'Complete Purchase',
|
|
398
|
+
emailOptIn: { show: true, checked: false, text: 'Subscribe to our newsletter' },
|
|
399
|
+
legalMessage: { show: true, text: 'By placing this order, you agree to our <a href="/terms">Terms</a>.' }
|
|
400
|
+
}
|
|
401
|
+
}
|
|
402
|
+
}
|
|
403
|
+
```
|
|
404
|
+
|
|
405
|
+
---
|
|
406
|
+
|
|
407
|
+
### Address Theme
|
|
408
|
+
|
|
409
|
+
#### IAddressComponent
|
|
410
|
+
|
|
411
|
+
```typescript
|
|
412
|
+
interface IAddressComponent {
|
|
413
|
+
theme: IAddressTheme;
|
|
414
|
+
}
|
|
415
|
+
```
|
|
416
|
+
|
|
417
|
+
#### IAddressTheme
|
|
418
|
+
|
|
419
|
+
```typescript
|
|
420
|
+
interface IAddressTheme {
|
|
421
|
+
backgroundColor: string;
|
|
422
|
+
}
|
|
423
|
+
```
|
|
424
|
+
|
|
425
|
+
---
|
|
426
|
+
|
|
427
|
+
### Product List Theme
|
|
428
|
+
|
|
429
|
+
#### IProductListComponent
|
|
430
|
+
|
|
431
|
+
```typescript
|
|
432
|
+
interface IProductListComponent {
|
|
433
|
+
theme: IProductListTheme;
|
|
434
|
+
layout: IProductListLayout;
|
|
435
|
+
}
|
|
436
|
+
```
|
|
437
|
+
|
|
438
|
+
Product list theme updates use a special structure where lists are keyed by slug:
|
|
439
|
+
|
|
440
|
+
```typescript
|
|
441
|
+
interface UpdateProductListComponent {
|
|
442
|
+
theme?: { backgroundColor?: string };
|
|
443
|
+
layout?: {
|
|
444
|
+
lists?: Record<string, DeepPartial<IPLCList>>;
|
|
445
|
+
};
|
|
446
|
+
}
|
|
447
|
+
```
|
|
448
|
+
|
|
449
|
+
**Example:**
|
|
450
|
+
|
|
451
|
+
```javascript
|
|
452
|
+
customTheme: {
|
|
453
|
+
productList: {
|
|
454
|
+
theme: { backgroundColor: '#ffffff' },
|
|
455
|
+
layout: {
|
|
456
|
+
lists: {
|
|
457
|
+
'best-sellers': {
|
|
458
|
+
productCard: {
|
|
459
|
+
style: 'card',
|
|
460
|
+
showPrice: true,
|
|
461
|
+
enablePreCart: true
|
|
462
|
+
}
|
|
463
|
+
}
|
|
464
|
+
}
|
|
465
|
+
}
|
|
466
|
+
}
|
|
467
|
+
}
|
|
468
|
+
```
|
|
469
|
+
|
|
470
|
+
---
|
|
471
|
+
|
|
472
|
+
## Promo Ticker Configuration
|
|
473
|
+
|
|
474
|
+
### IPromoTicker
|
|
475
|
+
|
|
476
|
+
```typescript
|
|
477
|
+
interface IPromoTicker {
|
|
478
|
+
promoCode: string; // Promo code to auto-apply
|
|
479
|
+
text: string[]; // Array of messages to rotate
|
|
480
|
+
separator: string; // Separator between messages (e.g., '|')
|
|
481
|
+
activeFrom: string; // Start date in ISO 8601 UTC format
|
|
482
|
+
activeUntil: string; // End date in ISO 8601 UTC format
|
|
483
|
+
}
|
|
484
|
+
```
|
|
485
|
+
|
|
486
|
+
**Example:**
|
|
487
|
+
|
|
488
|
+
```javascript
|
|
489
|
+
promoTicker: [
|
|
490
|
+
{
|
|
491
|
+
promoCode: 'SUMMER20',
|
|
492
|
+
text: ['20% Off Summer Sale', 'Free Shipping on $50+'],
|
|
493
|
+
separator: '|',
|
|
494
|
+
activeFrom: '2026-06-01T00:00:00Z',
|
|
495
|
+
activeUntil: '2026-08-31T23:59:59Z'
|
|
496
|
+
}
|
|
497
|
+
]
|
|
498
|
+
```
|
|
499
|
+
|
|
500
|
+
---
|
|
501
|
+
|
|
502
|
+
## Checkout Configuration
|
|
503
|
+
|
|
504
|
+
### ILiquidCommerceElementsCheckoutConfig
|
|
505
|
+
|
|
506
|
+
```typescript
|
|
507
|
+
interface ILiquidCommerceElementsCheckoutConfig {
|
|
508
|
+
pageUrl?: string; // URL with {token} placeholder
|
|
509
|
+
}
|
|
510
|
+
```
|
|
511
|
+
|
|
512
|
+
When `pageUrl` is set, the cart's checkout button redirects to this URL instead of opening the checkout drawer. Use `{token}` as a placeholder for the checkout session token.
|
|
513
|
+
|
|
514
|
+
**Example:**
|
|
515
|
+
|
|
516
|
+
```javascript
|
|
517
|
+
checkout: {
|
|
518
|
+
pageUrl: 'https://yoursite.com/checkout?lce_checkout={token}'
|
|
519
|
+
}
|
|
520
|
+
```
|
|
521
|
+
|
|
522
|
+
---
|
|
523
|
+
|
|
524
|
+
## Proxy Configuration
|
|
525
|
+
|
|
526
|
+
### IElementsProxyConfig
|
|
527
|
+
|
|
528
|
+
```typescript
|
|
529
|
+
interface IElementsProxyConfig {
|
|
530
|
+
baseUrl: string;
|
|
531
|
+
headers?: Record<string, string>;
|
|
532
|
+
}
|
|
533
|
+
```
|
|
534
|
+
|
|
535
|
+
Route SDK API requests through your own server to avoid ad blockers.
|
|
536
|
+
|
|
537
|
+
See [Proxy Setup Guide](../integration/proxy-setup.md) for implementation details.
|
|
538
|
+
|
|
539
|
+
---
|
|
540
|
+
|
|
541
|
+
## GTM Configuration
|
|
542
|
+
|
|
543
|
+
### IElementsGTMConfig
|
|
544
|
+
|
|
545
|
+
```typescript
|
|
546
|
+
interface IElementsGTMConfig {
|
|
547
|
+
gatewayUrl?: string;
|
|
548
|
+
}
|
|
549
|
+
```
|
|
550
|
+
|
|
551
|
+
If your site loads its own GTM container through Google tag gateway for advertisers, set `gatewayUrl` to that first-party path (e.g. `'https://www.yoursite.com/metrics/'` or `'/metrics/'`) so the SDK recognizes the container before GTM has booted it. It affects detection only: your container receives SDK events through `dataLayer` with or without it. Declarative equivalent: `data-gtm-gateway-url`. An empty or non-string value drops the whole `gtm` config with a console warning.
|
|
552
|
+
|
|
553
|
+
See [Analytics → Google tag gateway](../reference/analytics.md#google-tag-gateway).
|
|
554
|
+
|
|
555
|
+
---
|
|
556
|
+
|
|
557
|
+
## Development Configuration
|
|
558
|
+
|
|
559
|
+
### ILiquidCommerceElementsDevelopmentConfig
|
|
560
|
+
|
|
561
|
+
```typescript
|
|
562
|
+
interface ILiquidCommerceElementsDevelopmentConfig {
|
|
563
|
+
customApiUrl?: string;
|
|
564
|
+
openShadowDom?: boolean;
|
|
565
|
+
mockMode?: boolean;
|
|
566
|
+
}
|
|
567
|
+
```
|
|
568
|
+
|
|
569
|
+
| Property | Type | Description |
|
|
570
|
+
|----------|------|-------------|
|
|
571
|
+
| `customApiUrl` | `string` | Custom API URL for local or custom backend testing |
|
|
572
|
+
| `openShadowDom` | `boolean` | Use an OPEN (inspectable) Shadow DOM instead of the default closed mode, for debugging. Shadow DOM is always attached; forced off in production (default: `false`) |
|
|
573
|
+
| `mockMode` | `boolean` | Enable mock mode to receive mock data from the API; sends an `X-Liquid-Api-Mock-Mode` header with all requests (default: `false`) |
|
|
574
|
+
|
|
575
|
+
> To pre-select a payment method and skip the card form (in any environment), use [`actions.checkout.setSavedPaymentMethod`](./actions/checkout-actions.md#actionscheckoutsetsavedpaymentmethod) instead.
|
|
576
|
+
|
|
577
|
+
---
|
|
578
|
+
|
|
579
|
+
## See Also
|
|
580
|
+
|
|
581
|
+
- [Client API](./client.md) - Client initialization and usage
|
|
582
|
+
- [TypeScript Types](./typescript-types.md) - Complete type reference
|
|
583
|
+
- [Theming Guide](../guides/theming.md) - Theming best practices
|