@shopify/hydrogen-react 0.0.0-next-72f8a5c → 0.0.0-next-ea37299
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/dev/CartProvider.js +35 -35
- package/dist/dev/CartProvider.js.map +1 -1
- package/dist/dev/{CartProvider.cjs → CartProvider.mjs} +36 -36
- package/dist/dev/{CartProvider.cjs.map → CartProvider.mjs.map} +1 -1
- package/dist/dev/ExternalVideo.js +5 -5
- package/dist/dev/ExternalVideo.js.map +1 -1
- package/dist/dev/{ExternalVideo.cjs → ExternalVideo.mjs} +6 -6
- package/dist/{prod/ExternalVideo.cjs.map → dev/ExternalVideo.mjs.map} +1 -1
- package/dist/dev/Image.js +12 -12
- package/dist/dev/Image.js.map +1 -1
- package/dist/dev/{Image.cjs → Image.mjs} +13 -13
- package/dist/dev/{Image.cjs.map → Image.mjs.map} +1 -1
- package/dist/dev/MediaFile.js +12 -12
- package/dist/dev/MediaFile.js.map +1 -1
- package/dist/dev/{MediaFile.cjs → MediaFile.mjs} +13 -13
- package/dist/dev/{MediaFile.cjs.map → MediaFile.mjs.map} +1 -1
- package/dist/dev/Metafield.js +32 -32
- package/dist/dev/Metafield.js.map +1 -1
- package/dist/dev/{Metafield.cjs → Metafield.mjs} +33 -33
- package/dist/dev/{Metafield.cjs.map → Metafield.mjs.map} +1 -1
- package/dist/dev/ModelViewer.js +11 -11
- package/dist/dev/ModelViewer.js.map +1 -1
- package/dist/dev/{ModelViewer.cjs → ModelViewer.mjs} +12 -12
- package/dist/dev/{ModelViewer.cjs.map → ModelViewer.mjs.map} +1 -1
- package/dist/dev/Money.js +8 -8
- package/dist/dev/Money.js.map +1 -1
- package/dist/{prod/Money.cjs → dev/Money.mjs} +9 -9
- package/dist/dev/{Money.cjs.map → Money.mjs.map} +1 -1
- package/dist/dev/ProductPrice.js +9 -9
- package/dist/dev/ProductPrice.js.map +1 -1
- package/dist/{prod/ProductPrice.cjs → dev/ProductPrice.mjs} +10 -10
- package/dist/dev/{ProductPrice.cjs.map → ProductPrice.mjs.map} +1 -1
- package/dist/dev/ProductProvider.js +25 -25
- package/dist/dev/ProductProvider.js.map +1 -1
- package/dist/{prod/ProductProvider.cjs → dev/ProductProvider.mjs} +26 -26
- package/dist/dev/{ProductProvider.cjs.map → ProductProvider.mjs.map} +1 -1
- package/dist/dev/ShopPayButton.js +13 -13
- package/dist/dev/ShopPayButton.js.map +1 -1
- package/dist/{prod/ShopPayButton.cjs → dev/ShopPayButton.mjs} +14 -14
- package/dist/{prod/ShopPayButton.cjs.map → dev/ShopPayButton.mjs.map} +1 -1
- package/dist/dev/ShopifyProvider.js +14 -14
- package/dist/dev/ShopifyProvider.js.map +1 -1
- package/dist/dev/ShopifyProvider.mjs +46 -0
- package/dist/dev/{ShopifyProvider.cjs.map → ShopifyProvider.mjs.map} +1 -1
- package/dist/dev/Video.js +9 -9
- package/dist/dev/Video.js.map +1 -1
- package/dist/dev/{Video.cjs → Video.mjs} +10 -10
- package/dist/dev/{Video.cjs.map → Video.mjs.map} +1 -1
- package/dist/dev/_virtual/index.js +5 -0
- package/dist/dev/_virtual/index.js.map +1 -0
- package/dist/dev/_virtual/index.mjs +5 -0
- package/dist/dev/_virtual/index.mjs.map +1 -0
- package/dist/dev/_virtual/use-sync-external-store-shim.development.js +5 -0
- package/dist/dev/_virtual/use-sync-external-store-shim.development.js.map +1 -0
- package/dist/dev/_virtual/use-sync-external-store-shim.development.mjs +5 -0
- package/dist/dev/_virtual/use-sync-external-store-shim.development.mjs.map +1 -0
- package/dist/dev/_virtual/use-sync-external-store-shim.production.min.js +5 -0
- package/dist/dev/_virtual/use-sync-external-store-shim.production.min.js.map +1 -0
- package/dist/dev/_virtual/use-sync-external-store-shim.production.min.mjs +5 -0
- package/dist/dev/_virtual/use-sync-external-store-shim.production.min.mjs.map +1 -0
- package/dist/dev/_virtual/with-selector.development.js +5 -0
- package/dist/dev/_virtual/with-selector.development.js.map +1 -0
- package/dist/dev/_virtual/with-selector.development.mjs +5 -0
- package/dist/dev/_virtual/with-selector.development.mjs.map +1 -0
- package/dist/dev/_virtual/with-selector.js +5 -0
- package/dist/dev/_virtual/with-selector.js.map +1 -0
- package/dist/dev/_virtual/with-selector.mjs +5 -0
- package/dist/dev/_virtual/with-selector.mjs.map +1 -0
- package/dist/dev/_virtual/with-selector.production.min.js +5 -0
- package/dist/dev/_virtual/with-selector.production.min.js.map +1 -0
- package/dist/dev/_virtual/with-selector.production.min.mjs +5 -0
- package/dist/dev/_virtual/with-selector.production.min.mjs.map +1 -0
- package/dist/dev/cart-constants.js +9 -9
- package/dist/dev/cart-constants.js.map +1 -1
- package/dist/dev/cart-constants.mjs +17 -0
- package/dist/dev/{cart-constants.cjs.map → cart-constants.mjs.map} +1 -1
- package/dist/dev/cart-hooks.js +15 -15
- package/dist/dev/cart-hooks.js.map +1 -1
- package/dist/dev/cart-hooks.mjs +48 -0
- package/dist/dev/{cart-hooks.cjs.map → cart-hooks.mjs.map} +1 -1
- package/dist/dev/cart-queries.js +11 -11
- package/dist/dev/cart-queries.js.map +1 -1
- package/dist/{prod/cart-queries.cjs → dev/cart-queries.mjs} +12 -12
- package/dist/dev/{cart-queries.cjs.map → cart-queries.mjs.map} +1 -1
- package/dist/dev/flatten-connection.js +3 -3
- package/dist/dev/flatten-connection.js.map +1 -1
- package/dist/dev/{flatten-connection.cjs → flatten-connection.mjs} +4 -4
- package/dist/dev/{flatten-connection.cjs.map → flatten-connection.mjs.map} +1 -1
- package/dist/dev/image-size.js +6 -6
- package/dist/dev/image-size.js.map +1 -1
- package/dist/dev/{image-size.cjs → image-size.mjs} +7 -7
- package/dist/dev/{image-size.cjs.map → image-size.mjs.map} +1 -1
- package/dist/dev/index.js +37 -37
- package/dist/dev/index.js.map +1 -1
- package/dist/dev/index.mjs +38 -0
- package/dist/dev/index.mjs.map +1 -0
- package/dist/dev/load-script.js +7 -7
- package/dist/dev/load-script.js.map +1 -1
- package/dist/{prod/load-script.cjs → dev/load-script.mjs} +8 -8
- package/dist/dev/{load-script.cjs.map → load-script.mjs.map} +1 -1
- package/dist/dev/node_modules/@xstate/fsm/es/index.js +158 -0
- package/dist/dev/node_modules/@xstate/fsm/es/index.js.map +1 -0
- package/dist/dev/node_modules/@xstate/fsm/es/index.mjs +159 -0
- package/dist/dev/node_modules/@xstate/fsm/es/index.mjs.map +1 -0
- package/dist/dev/node_modules/@xstate/react/es/fsm.js +94 -0
- package/dist/dev/node_modules/@xstate/react/es/fsm.js.map +1 -0
- package/dist/dev/node_modules/@xstate/react/es/fsm.mjs +94 -0
- package/dist/dev/node_modules/@xstate/react/es/fsm.mjs.map +1 -0
- package/dist/dev/node_modules/@xstate/react/es/useConstant.js +30 -0
- package/dist/dev/node_modules/@xstate/react/es/useConstant.js.map +1 -0
- package/dist/dev/node_modules/@xstate/react/es/useConstant.mjs +12 -0
- package/dist/dev/node_modules/@xstate/react/es/useConstant.mjs.map +1 -0
- package/dist/dev/node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.browser.esm.js +5 -0
- package/dist/dev/node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.browser.esm.js.map +1 -0
- package/dist/dev/node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.browser.esm.mjs +6 -0
- package/dist/dev/node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.browser.esm.mjs.map +1 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js +107 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js.map +1 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.mjs +105 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.mjs.map +1 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.min.js +74 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.min.js.map +1 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.min.mjs +72 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.min.mjs.map +1 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js +138 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js.map +1 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.mjs +136 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.mjs.map +1 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.min.js +60 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.min.js.map +1 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.min.mjs +58 -0
- package/dist/dev/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.min.mjs.map +1 -0
- package/dist/dev/node_modules/use-sync-external-store/shim/index.js +21 -0
- package/dist/dev/node_modules/use-sync-external-store/shim/index.js.map +1 -0
- package/dist/dev/node_modules/use-sync-external-store/shim/index.mjs +21 -0
- package/dist/dev/node_modules/use-sync-external-store/shim/index.mjs.map +1 -0
- package/dist/dev/node_modules/use-sync-external-store/shim/with-selector.js +12 -0
- package/dist/dev/node_modules/use-sync-external-store/shim/with-selector.js.map +1 -0
- package/dist/dev/node_modules/use-sync-external-store/shim/with-selector.mjs +11 -0
- package/dist/dev/node_modules/use-sync-external-store/shim/with-selector.mjs.map +1 -0
- package/dist/dev/node_modules/worktop/cookie/index.js +27 -0
- package/dist/dev/node_modules/worktop/cookie/index.js.map +1 -0
- package/dist/dev/node_modules/worktop/cookie/index.mjs +27 -0
- package/dist/dev/node_modules/worktop/cookie/index.mjs.map +1 -0
- package/dist/dev/storefront-api-constants.js +3 -3
- package/dist/dev/storefront-api-constants.js.map +1 -1
- package/dist/dev/storefront-api-constants.mjs +5 -0
- package/dist/dev/storefront-api-constants.mjs.map +1 -0
- package/dist/dev/storefront-client.js +6 -6
- package/dist/dev/storefront-client.js.map +1 -1
- package/dist/dev/{storefront-client.cjs → storefront-client.mjs} +7 -7
- package/dist/dev/storefront-client.mjs.map +1 -0
- package/dist/dev/useCartAPIStateMachine.js +20 -20
- package/dist/dev/useCartAPIStateMachine.js.map +1 -1
- package/dist/{prod/useCartAPIStateMachine.cjs → dev/useCartAPIStateMachine.mjs} +21 -21
- package/dist/{prod/useCartAPIStateMachine.cjs.map → dev/useCartAPIStateMachine.mjs.map} +1 -1
- package/dist/dev/useCartActions.js +26 -26
- package/dist/dev/useCartActions.js.map +1 -1
- package/dist/dev/{useCartActions.cjs → useCartActions.mjs} +27 -27
- package/dist/dev/{useCartActions.cjs.map → useCartActions.mjs.map} +1 -1
- package/dist/dev/useMoney.js +10 -10
- package/dist/dev/useMoney.js.map +1 -1
- package/dist/{prod/useMoney.cjs → dev/useMoney.mjs} +11 -11
- package/dist/{prod/useMoney.cjs.map → dev/useMoney.mjs.map} +1 -1
- package/dist/prod/CartProvider.js +35 -35
- package/dist/prod/CartProvider.js.map +1 -1
- package/dist/prod/{CartProvider.cjs → CartProvider.mjs} +36 -36
- package/dist/prod/{CartProvider.cjs.map → CartProvider.mjs.map} +1 -1
- package/dist/prod/ExternalVideo.js +5 -5
- package/dist/prod/ExternalVideo.js.map +1 -1
- package/dist/prod/{ExternalVideo.cjs → ExternalVideo.mjs} +6 -6
- package/dist/{dev/ExternalVideo.cjs.map → prod/ExternalVideo.mjs.map} +1 -1
- package/dist/prod/Image.js +12 -12
- package/dist/prod/Image.js.map +1 -1
- package/dist/prod/{Image.cjs → Image.mjs} +13 -13
- package/dist/prod/{Image.cjs.map → Image.mjs.map} +1 -1
- package/dist/prod/MediaFile.js +12 -12
- package/dist/prod/MediaFile.js.map +1 -1
- package/dist/prod/{MediaFile.cjs → MediaFile.mjs} +13 -13
- package/dist/prod/{MediaFile.cjs.map → MediaFile.mjs.map} +1 -1
- package/dist/prod/Metafield.js +32 -32
- package/dist/prod/Metafield.js.map +1 -1
- package/dist/prod/{Metafield.cjs → Metafield.mjs} +33 -33
- package/dist/prod/{Metafield.cjs.map → Metafield.mjs.map} +1 -1
- package/dist/prod/ModelViewer.js +11 -11
- package/dist/prod/ModelViewer.js.map +1 -1
- package/dist/prod/{ModelViewer.cjs → ModelViewer.mjs} +12 -12
- package/dist/prod/{ModelViewer.cjs.map → ModelViewer.mjs.map} +1 -1
- package/dist/prod/Money.js +8 -8
- package/dist/prod/Money.js.map +1 -1
- package/dist/{dev/Money.cjs → prod/Money.mjs} +9 -9
- package/dist/prod/{Money.cjs.map → Money.mjs.map} +1 -1
- package/dist/prod/ProductPrice.js +9 -9
- package/dist/prod/ProductPrice.js.map +1 -1
- package/dist/{dev/ProductPrice.cjs → prod/ProductPrice.mjs} +10 -10
- package/dist/prod/{ProductPrice.cjs.map → ProductPrice.mjs.map} +1 -1
- package/dist/prod/ProductProvider.js +25 -25
- package/dist/prod/ProductProvider.js.map +1 -1
- package/dist/{dev/ProductProvider.cjs → prod/ProductProvider.mjs} +26 -26
- package/dist/prod/{ProductProvider.cjs.map → ProductProvider.mjs.map} +1 -1
- package/dist/prod/ShopPayButton.js +13 -13
- package/dist/prod/ShopPayButton.js.map +1 -1
- package/dist/{dev/ShopPayButton.cjs → prod/ShopPayButton.mjs} +14 -14
- package/dist/{dev/ShopPayButton.cjs.map → prod/ShopPayButton.mjs.map} +1 -1
- package/dist/prod/ShopifyProvider.js +14 -14
- package/dist/prod/ShopifyProvider.js.map +1 -1
- package/dist/prod/ShopifyProvider.mjs +46 -0
- package/dist/prod/{ShopifyProvider.cjs.map → ShopifyProvider.mjs.map} +1 -1
- package/dist/prod/Video.js +9 -9
- package/dist/prod/Video.js.map +1 -1
- package/dist/prod/{Video.cjs → Video.mjs} +10 -10
- package/dist/prod/{Video.cjs.map → Video.mjs.map} +1 -1
- package/dist/prod/_virtual/index.js +5 -0
- package/dist/prod/_virtual/index.js.map +1 -0
- package/dist/prod/_virtual/index.mjs +5 -0
- package/dist/prod/_virtual/index.mjs.map +1 -0
- package/dist/prod/_virtual/use-sync-external-store-shim.development.js +5 -0
- package/dist/prod/_virtual/use-sync-external-store-shim.development.js.map +1 -0
- package/dist/prod/_virtual/use-sync-external-store-shim.development.mjs +5 -0
- package/dist/prod/_virtual/use-sync-external-store-shim.development.mjs.map +1 -0
- package/dist/prod/_virtual/use-sync-external-store-shim.production.min.js +5 -0
- package/dist/prod/_virtual/use-sync-external-store-shim.production.min.js.map +1 -0
- package/dist/prod/_virtual/use-sync-external-store-shim.production.min.mjs +5 -0
- package/dist/prod/_virtual/use-sync-external-store-shim.production.min.mjs.map +1 -0
- package/dist/prod/_virtual/with-selector.development.js +5 -0
- package/dist/prod/_virtual/with-selector.development.js.map +1 -0
- package/dist/prod/_virtual/with-selector.development.mjs +5 -0
- package/dist/prod/_virtual/with-selector.development.mjs.map +1 -0
- package/dist/prod/_virtual/with-selector.js +5 -0
- package/dist/prod/_virtual/with-selector.js.map +1 -0
- package/dist/prod/_virtual/with-selector.mjs +5 -0
- package/dist/prod/_virtual/with-selector.mjs.map +1 -0
- package/dist/prod/_virtual/with-selector.production.min.js +5 -0
- package/dist/prod/_virtual/with-selector.production.min.js.map +1 -0
- package/dist/prod/_virtual/with-selector.production.min.mjs +5 -0
- package/dist/prod/_virtual/with-selector.production.min.mjs.map +1 -0
- package/dist/prod/cart-constants.js +9 -9
- package/dist/prod/cart-constants.js.map +1 -1
- package/dist/prod/cart-constants.mjs +17 -0
- package/dist/prod/{cart-constants.cjs.map → cart-constants.mjs.map} +1 -1
- package/dist/prod/cart-hooks.js +15 -15
- package/dist/prod/cart-hooks.js.map +1 -1
- package/dist/prod/cart-hooks.mjs +48 -0
- package/dist/prod/{cart-hooks.cjs.map → cart-hooks.mjs.map} +1 -1
- package/dist/prod/cart-queries.js +11 -11
- package/dist/prod/cart-queries.js.map +1 -1
- package/dist/{dev/cart-queries.cjs → prod/cart-queries.mjs} +12 -12
- package/dist/prod/{cart-queries.cjs.map → cart-queries.mjs.map} +1 -1
- package/dist/prod/flatten-connection.js +3 -3
- package/dist/prod/flatten-connection.js.map +1 -1
- package/dist/prod/{flatten-connection.cjs → flatten-connection.mjs} +4 -4
- package/dist/prod/{flatten-connection.cjs.map → flatten-connection.mjs.map} +1 -1
- package/dist/prod/image-size.js +6 -6
- package/dist/prod/image-size.js.map +1 -1
- package/dist/prod/{image-size.cjs → image-size.mjs} +7 -7
- package/dist/prod/{image-size.cjs.map → image-size.mjs.map} +1 -1
- package/dist/prod/index.js +37 -37
- package/dist/prod/index.js.map +1 -1
- package/dist/prod/index.mjs +38 -0
- package/dist/prod/index.mjs.map +1 -0
- package/dist/prod/load-script.js +7 -7
- package/dist/prod/load-script.js.map +1 -1
- package/dist/{dev/load-script.cjs → prod/load-script.mjs} +8 -8
- package/dist/prod/{load-script.cjs.map → load-script.mjs.map} +1 -1
- package/dist/prod/node_modules/@xstate/fsm/es/index.js +158 -0
- package/dist/prod/node_modules/@xstate/fsm/es/index.js.map +1 -0
- package/dist/prod/node_modules/@xstate/fsm/es/index.mjs +159 -0
- package/dist/prod/node_modules/@xstate/fsm/es/index.mjs.map +1 -0
- package/dist/prod/node_modules/@xstate/react/es/fsm.js +94 -0
- package/dist/prod/node_modules/@xstate/react/es/fsm.js.map +1 -0
- package/dist/prod/node_modules/@xstate/react/es/fsm.mjs +94 -0
- package/dist/prod/node_modules/@xstate/react/es/fsm.mjs.map +1 -0
- package/dist/prod/node_modules/@xstate/react/es/useConstant.js +30 -0
- package/dist/prod/node_modules/@xstate/react/es/useConstant.js.map +1 -0
- package/dist/prod/node_modules/@xstate/react/es/useConstant.mjs +12 -0
- package/dist/prod/node_modules/@xstate/react/es/useConstant.mjs.map +1 -0
- package/dist/prod/node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.browser.esm.js +5 -0
- package/dist/prod/node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.browser.esm.js.map +1 -0
- package/dist/prod/node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.browser.esm.mjs +6 -0
- package/dist/prod/node_modules/use-isomorphic-layout-effect/dist/use-isomorphic-layout-effect.browser.esm.mjs.map +1 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js +107 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js.map +1 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.mjs +105 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.mjs.map +1 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.min.js +74 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.min.js.map +1 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.min.mjs +72 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.min.mjs.map +1 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js +138 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js.map +1 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.mjs +136 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.mjs.map +1 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.min.js +60 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.min.js.map +1 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.min.mjs +58 -0
- package/dist/prod/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.min.mjs.map +1 -0
- package/dist/prod/node_modules/use-sync-external-store/shim/index.js +21 -0
- package/dist/prod/node_modules/use-sync-external-store/shim/index.js.map +1 -0
- package/dist/prod/node_modules/use-sync-external-store/shim/index.mjs +21 -0
- package/dist/prod/node_modules/use-sync-external-store/shim/index.mjs.map +1 -0
- package/dist/prod/node_modules/use-sync-external-store/shim/with-selector.js +12 -0
- package/dist/prod/node_modules/use-sync-external-store/shim/with-selector.js.map +1 -0
- package/dist/prod/node_modules/use-sync-external-store/shim/with-selector.mjs +11 -0
- package/dist/prod/node_modules/use-sync-external-store/shim/with-selector.mjs.map +1 -0
- package/dist/prod/node_modules/worktop/cookie/index.js +27 -0
- package/dist/prod/node_modules/worktop/cookie/index.js.map +1 -0
- package/dist/prod/node_modules/worktop/cookie/index.mjs +27 -0
- package/dist/prod/node_modules/worktop/cookie/index.mjs.map +1 -0
- package/dist/prod/storefront-api-constants.js +3 -3
- package/dist/prod/storefront-api-constants.js.map +1 -1
- package/dist/prod/storefront-api-constants.mjs +5 -0
- package/dist/prod/storefront-api-constants.mjs.map +1 -0
- package/dist/prod/storefront-client.js +6 -6
- package/dist/prod/storefront-client.js.map +1 -1
- package/dist/prod/{storefront-client.cjs → storefront-client.mjs} +7 -7
- package/dist/prod/storefront-client.mjs.map +1 -0
- package/dist/prod/useCartAPIStateMachine.js +20 -20
- package/dist/prod/useCartAPIStateMachine.js.map +1 -1
- package/dist/{dev/useCartAPIStateMachine.cjs → prod/useCartAPIStateMachine.mjs} +21 -21
- package/dist/{dev/useCartAPIStateMachine.cjs.map → prod/useCartAPIStateMachine.mjs.map} +1 -1
- package/dist/prod/useCartActions.js +26 -26
- package/dist/prod/useCartActions.js.map +1 -1
- package/dist/prod/{useCartActions.cjs → useCartActions.mjs} +27 -27
- package/dist/prod/{useCartActions.cjs.map → useCartActions.mjs.map} +1 -1
- package/dist/prod/useMoney.js +10 -10
- package/dist/prod/useMoney.js.map +1 -1
- package/dist/{dev/useMoney.cjs → prod/useMoney.mjs} +11 -11
- package/dist/{dev/useMoney.cjs.map → prod/useMoney.mjs.map} +1 -1
- package/dist/umd/hydrogen-react.dev.js +1 -1
- package/dist/umd/hydrogen-react.dev.js.map +1 -1
- package/dist/umd/hydrogen-react.prod.js +1 -1
- package/dist/umd/hydrogen-react.prod.js.map +1 -1
- package/package.json +14 -14
- package/dist/dev/ShopifyProvider.cjs +0 -46
- package/dist/dev/cart-constants.cjs +0 -17
- package/dist/dev/cart-hooks.cjs +0 -48
- package/dist/dev/index.cjs +0 -38
- package/dist/dev/index.cjs.map +0 -1
- package/dist/dev/storefront-api-constants.cjs +0 -5
- package/dist/dev/storefront-api-constants.cjs.map +0 -1
- package/dist/dev/storefront-client.cjs.map +0 -1
- package/dist/prod/ShopifyProvider.cjs +0 -46
- package/dist/prod/cart-constants.cjs +0 -17
- package/dist/prod/cart-hooks.cjs +0 -48
- package/dist/prod/index.cjs +0 -38
- package/dist/prod/index.cjs.map +0 -1
- package/dist/prod/storefront-api-constants.cjs +0 -5
- package/dist/prod/storefront-api-constants.cjs.map +0 -1
- package/dist/prod/storefront-client.cjs.map +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shopify/hydrogen-react",
|
|
3
|
-
"version": "0.0.0-next-
|
|
3
|
+
"version": "0.0.0-next-ea37299",
|
|
4
4
|
"description": "React components, hooks, and utilities for creating custom Shopify storefronts",
|
|
5
5
|
"homepage": "https://github.com/Shopify/hydrogen-ui/tree/main/packages/react",
|
|
6
6
|
"license": "MIT",
|
|
@@ -15,28 +15,28 @@
|
|
|
15
15
|
"dist",
|
|
16
16
|
"storefront.schema.json"
|
|
17
17
|
],
|
|
18
|
-
"type": "
|
|
18
|
+
"type": "commonjs",
|
|
19
19
|
"exports": {
|
|
20
20
|
".": {
|
|
21
21
|
"module": {
|
|
22
22
|
"types": "./dist/types/index.d.ts",
|
|
23
|
-
"development": "./dist/dev/index.
|
|
24
|
-
"production": "./dist/prod/index.
|
|
25
|
-
"default": "./dist/prod/index.
|
|
23
|
+
"development": "./dist/dev/index.mjs",
|
|
24
|
+
"production": "./dist/prod/index.mjs",
|
|
25
|
+
"default": "./dist/prod/index.mjs"
|
|
26
26
|
},
|
|
27
27
|
"import": {
|
|
28
28
|
"types": "./dist/types/index.d.ts",
|
|
29
|
-
"development": "./dist/dev/index.
|
|
30
|
-
"production": "./dist/prod/index.
|
|
31
|
-
"default": "./dist/prod/index.
|
|
29
|
+
"development": "./dist/dev/index.mjs",
|
|
30
|
+
"production": "./dist/prod/index.mjs",
|
|
31
|
+
"default": "./dist/prod/index.mjs"
|
|
32
32
|
},
|
|
33
33
|
"require": {
|
|
34
34
|
"types": "./dist/types/index.d.cts",
|
|
35
|
-
"development": "./dist/dev/index.
|
|
36
|
-
"production": "./dist/prod/index.
|
|
37
|
-
"default": "./dist/prod/index.
|
|
35
|
+
"development": "./dist/dev/index.js",
|
|
36
|
+
"production": "./dist/prod/index.js",
|
|
37
|
+
"default": "./dist/prod/index.js"
|
|
38
38
|
},
|
|
39
|
-
"default": "./dist/prod/index.
|
|
39
|
+
"default": "./dist/prod/index.mjs"
|
|
40
40
|
},
|
|
41
41
|
"./storefront-api-types": "./dist/types/storefront-api-types.d.ts",
|
|
42
42
|
"./storefront.schema.json": "./storefront.schema.json",
|
|
@@ -49,8 +49,8 @@
|
|
|
49
49
|
]
|
|
50
50
|
}
|
|
51
51
|
},
|
|
52
|
-
"main": "./dist/prod/index.
|
|
53
|
-
"module": "./dist/prod/index.
|
|
52
|
+
"main": "./dist/prod/index.js",
|
|
53
|
+
"module": "./dist/prod/index.mjs",
|
|
54
54
|
"types": "./dist/types/index.d.ts",
|
|
55
55
|
"unpkg": "./dist/umd/hydrogen-react.prod.js",
|
|
56
56
|
"jsdelivr": "./dist/umd/hydrogen-react.prod.js",
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const react = require("react");
|
|
4
|
-
const storefrontApiConstants = require("./storefront-api-constants.cjs");
|
|
5
|
-
const jsxRuntime = require("react/jsx-runtime");
|
|
6
|
-
const ShopifyContext = react.createContext({
|
|
7
|
-
storeDomain: "test.myshopify.com",
|
|
8
|
-
storefrontToken: "abc123",
|
|
9
|
-
storefrontApiVersion: storefrontApiConstants.SFAPI_VERSION,
|
|
10
|
-
country: {
|
|
11
|
-
isoCode: "US"
|
|
12
|
-
},
|
|
13
|
-
language: {
|
|
14
|
-
isoCode: "EN"
|
|
15
|
-
},
|
|
16
|
-
locale: "EN-US"
|
|
17
|
-
});
|
|
18
|
-
function ShopifyProvider({
|
|
19
|
-
children,
|
|
20
|
-
shopifyConfig
|
|
21
|
-
}) {
|
|
22
|
-
if (!shopifyConfig) {
|
|
23
|
-
throw new Error(`The 'shopifyConfig' prop must be passed to '<ShopifyProvider/>'`);
|
|
24
|
-
}
|
|
25
|
-
if (shopifyConfig.storefrontApiVersion !== storefrontApiConstants.SFAPI_VERSION) {
|
|
26
|
-
console.warn(`This version of Hydrogen-UI is built for Shopify's Storefront API version ${storefrontApiConstants.SFAPI_VERSION}, but it looks like you're using version ${shopifyConfig.storefrontApiVersion}. There may be issues or bugs if you use a mismatched version of Hydrogen-UI and the Storefront API.`);
|
|
27
|
-
}
|
|
28
|
-
const finalConfig = react.useMemo(() => ({
|
|
29
|
-
...shopifyConfig,
|
|
30
|
-
storeDomain: shopifyConfig.storeDomain.replace(/^https?:\/\//, "")
|
|
31
|
-
}), [shopifyConfig]);
|
|
32
|
-
return /* @__PURE__ */ jsxRuntime.jsx(ShopifyContext.Provider, {
|
|
33
|
-
value: finalConfig,
|
|
34
|
-
children
|
|
35
|
-
});
|
|
36
|
-
}
|
|
37
|
-
function useShop() {
|
|
38
|
-
const shopContext = react.useContext(ShopifyContext);
|
|
39
|
-
if (!shopContext) {
|
|
40
|
-
throw new Error(`'useShop()' must be a descendent of <ShopifyProvider/>`);
|
|
41
|
-
}
|
|
42
|
-
return shopContext;
|
|
43
|
-
}
|
|
44
|
-
exports.ShopifyProvider = ShopifyProvider;
|
|
45
|
-
exports.useShop = useShop;
|
|
46
|
-
//# sourceMappingURL=ShopifyProvider.cjs.map
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const CART_ID_STORAGE_KEY = "shopifyCartId";
|
|
4
|
-
const STOREFRONT_API_PUBLIC_TOKEN_HEADER = "X-Shopify-Storefront-Access-Token";
|
|
5
|
-
const SHOPIFY_STOREFRONT_ID_HEADER = "Shopify-Storefront-Id";
|
|
6
|
-
const SHOPIFY_STOREFRONT_Y_HEADER = "Shopify-Storefront-Y";
|
|
7
|
-
const SHOPIFY_STOREFRONT_S_HEADER = "Shopify-Storefront-S";
|
|
8
|
-
const SHOPIFY_Y = "_shopify_y";
|
|
9
|
-
const SHOPIFY_S = "_shopify_s";
|
|
10
|
-
exports.CART_ID_STORAGE_KEY = CART_ID_STORAGE_KEY;
|
|
11
|
-
exports.SHOPIFY_S = SHOPIFY_S;
|
|
12
|
-
exports.SHOPIFY_STOREFRONT_ID_HEADER = SHOPIFY_STOREFRONT_ID_HEADER;
|
|
13
|
-
exports.SHOPIFY_STOREFRONT_S_HEADER = SHOPIFY_STOREFRONT_S_HEADER;
|
|
14
|
-
exports.SHOPIFY_STOREFRONT_Y_HEADER = SHOPIFY_STOREFRONT_Y_HEADER;
|
|
15
|
-
exports.SHOPIFY_Y = SHOPIFY_Y;
|
|
16
|
-
exports.STOREFRONT_API_PUBLIC_TOKEN_HEADER = STOREFRONT_API_PUBLIC_TOKEN_HEADER;
|
|
17
|
-
//# sourceMappingURL=cart-constants.cjs.map
|
package/dist/dev/cart-hooks.cjs
DELETED
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const react = require("react");
|
|
4
|
-
const ShopifyProvider = require("./ShopifyProvider.cjs");
|
|
5
|
-
const cartConstants = require("./cart-constants.cjs");
|
|
6
|
-
const cookie = require("worktop/cookie");
|
|
7
|
-
function useCartFetch() {
|
|
8
|
-
const {
|
|
9
|
-
storeDomain,
|
|
10
|
-
storefrontApiVersion,
|
|
11
|
-
storefrontToken,
|
|
12
|
-
storefrontId
|
|
13
|
-
} = ShopifyProvider.useShop();
|
|
14
|
-
return react.useCallback(({
|
|
15
|
-
query,
|
|
16
|
-
variables
|
|
17
|
-
}) => {
|
|
18
|
-
const headers = {
|
|
19
|
-
"Content-Type": "application/json",
|
|
20
|
-
"X-SDK-Variant": "hydrogen",
|
|
21
|
-
"X-SDK-Version": storefrontApiVersion,
|
|
22
|
-
[cartConstants.STOREFRONT_API_PUBLIC_TOKEN_HEADER]: storefrontToken
|
|
23
|
-
};
|
|
24
|
-
if (storefrontId) {
|
|
25
|
-
headers[cartConstants.SHOPIFY_STOREFRONT_ID_HEADER] = storefrontId;
|
|
26
|
-
}
|
|
27
|
-
const cookieData = cookie.parse(document.cookie);
|
|
28
|
-
if (cookieData[cartConstants.SHOPIFY_Y] && cookieData[cartConstants.SHOPIFY_S]) {
|
|
29
|
-
headers[cartConstants.SHOPIFY_STOREFRONT_Y_HEADER] = cookieData[cartConstants.SHOPIFY_Y];
|
|
30
|
-
headers[cartConstants.SHOPIFY_STOREFRONT_S_HEADER] = cookieData[cartConstants.SHOPIFY_S];
|
|
31
|
-
}
|
|
32
|
-
return fetch(`https://${storeDomain}/api/${storefrontApiVersion}/graphql.json`, {
|
|
33
|
-
method: "POST",
|
|
34
|
-
headers,
|
|
35
|
-
body: JSON.stringify({
|
|
36
|
-
query: query.toString(),
|
|
37
|
-
variables
|
|
38
|
-
})
|
|
39
|
-
}).then((res) => res.json()).catch((error) => {
|
|
40
|
-
return {
|
|
41
|
-
data: void 0,
|
|
42
|
-
errors: error.toString()
|
|
43
|
-
};
|
|
44
|
-
});
|
|
45
|
-
}, [storeDomain, storefrontApiVersion, storefrontToken, storefrontId]);
|
|
46
|
-
}
|
|
47
|
-
exports.useCartFetch = useCartFetch;
|
|
48
|
-
//# sourceMappingURL=cart-hooks.cjs.map
|
package/dist/dev/index.cjs
DELETED
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const CartProvider = require("./CartProvider.cjs");
|
|
4
|
-
const ExternalVideo = require("./ExternalVideo.cjs");
|
|
5
|
-
const flattenConnection = require("./flatten-connection.cjs");
|
|
6
|
-
const Image = require("./Image.cjs");
|
|
7
|
-
const MediaFile = require("./MediaFile.cjs");
|
|
8
|
-
const Metafield = require("./Metafield.cjs");
|
|
9
|
-
const ModelViewer = require("./ModelViewer.cjs");
|
|
10
|
-
const Money = require("./Money.cjs");
|
|
11
|
-
const ProductPrice = require("./ProductPrice.cjs");
|
|
12
|
-
const ProductProvider = require("./ProductProvider.cjs");
|
|
13
|
-
const ShopifyProvider = require("./ShopifyProvider.cjs");
|
|
14
|
-
const ShopPayButton = require("./ShopPayButton.cjs");
|
|
15
|
-
const storefrontClient = require("./storefront-client.cjs");
|
|
16
|
-
const useMoney = require("./useMoney.cjs");
|
|
17
|
-
const Video = require("./Video.cjs");
|
|
18
|
-
exports.CartProvider = CartProvider.CartProvider;
|
|
19
|
-
exports.useCart = CartProvider.useCart;
|
|
20
|
-
exports.ExternalVideo = ExternalVideo.ExternalVideo;
|
|
21
|
-
exports.flattenConnection = flattenConnection.flattenConnection;
|
|
22
|
-
exports.Image = Image.Image;
|
|
23
|
-
exports.MediaFile = MediaFile.MediaFile;
|
|
24
|
-
exports.Metafield = Metafield.Metafield;
|
|
25
|
-
exports.parseMetafield = Metafield.parseMetafield;
|
|
26
|
-
exports.parseMetafieldValue = Metafield.parseMetafieldValue;
|
|
27
|
-
exports.ModelViewer = ModelViewer.ModelViewer;
|
|
28
|
-
exports.Money = Money.Money;
|
|
29
|
-
exports.ProductPrice = ProductPrice.ProductPrice;
|
|
30
|
-
exports.ProductProvider = ProductProvider.ProductProvider;
|
|
31
|
-
exports.useProduct = ProductProvider.useProduct;
|
|
32
|
-
exports.ShopifyProvider = ShopifyProvider.ShopifyProvider;
|
|
33
|
-
exports.useShop = ShopifyProvider.useShop;
|
|
34
|
-
exports.ShopPayButton = ShopPayButton.ShopPayButton;
|
|
35
|
-
exports.createStorefrontClient = storefrontClient.createStorefrontClient;
|
|
36
|
-
exports.useMoney = useMoney.useMoney;
|
|
37
|
-
exports.Video = Video.Video;
|
|
38
|
-
//# sourceMappingURL=index.cjs.map
|
package/dist/dev/index.cjs.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"storefront-api-constants.cjs","sources":["../../src/storefront-api-constants.ts"],"sourcesContent":["export const SFAPI_VERSION = '2022-10';\n"],"names":[],"mappings":";;AAAO,MAAM,gBAAgB;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"storefront-client.cjs","sources":["../../src/storefront-client.ts"],"sourcesContent":["import {SFAPI_VERSION} from './storefront-api-constants.js';\n\n/**\n * The `createStorefrontClient()` function creates helpers that enable you to quickly query the Shopify Storefront API.\n *\n * When used on the server, it is recommended to use the `privateStorefrontToken` prop. When used on the client, it is recommended to use the `publicStorefrontToken` prop.\n */\nexport function createStorefrontClient({\n storeDomain,\n privateStorefrontToken,\n publicStorefrontToken,\n storefrontApiVersion,\n contentType,\n}: StorefrontClientProps): StorefrontClientReturn {\n if (storefrontApiVersion !== SFAPI_VERSION) {\n console.warn(\n `StorefrontClient: The Storefront API version that you're using is different than the version this build of Hydrogen-UI is targeting. You may run into unexpected errors if these versions don't match. Received verion: \"${storefrontApiVersion}\"; expected version ${SFAPI_VERSION}`\n );\n }\n\n // only warn if not in a browser environment\n if (__HYDROGEN_DEV__ && !privateStorefrontToken && !globalThis.document) {\n console.warn(\n `StorefrontClient: Using a private storefront token is recommended for server environments. Refer to the authentication https://shopify.dev/api/storefront#authentication documentation for more details. `\n );\n }\n\n // only warn if in a browser environment and you're using the privateStorefrontToken\n if (__HYDROGEN_DEV__ && privateStorefrontToken && globalThis) {\n console.warn(\n `StorefrontClient: You are attempting to use a private token in an environment where it can be easily accessed by anyone. This is a security risk; please use the public token and the 'publicStorefrontToken' prop`\n );\n }\n\n return {\n getStorefrontApiUrl(overrideProps) {\n return `https://${\n overrideProps?.storeDomain ?? storeDomain\n }.myshopify.com/api/${\n overrideProps?.storefrontApiVersion ?? storefrontApiVersion\n }/graphql.json`;\n },\n getPrivateTokenHeaders(overrideProps) {\n if (!privateStorefrontToken && !overrideProps?.privateStorefrontToken) {\n throw new Error(\n `StorefrontClient: You did not pass in a 'privateStorefrontToken' while using 'getPrivateTokenHeaders()'`\n );\n }\n\n if (__HYDROGEN_DEV__ && !overrideProps?.buyerIp) {\n console.warn(\n `StorefrontClient: it is recommended to pass in the 'buyerIp' property which improves analytics and data in the admin.`\n );\n }\n\n const finalContentType = overrideProps?.contentType ?? contentType;\n\n return {\n // default to json\n 'content-type':\n finalContentType === 'graphql'\n ? 'application/graphql'\n : 'application/json',\n 'X-SDK-Variant': 'hydrogen-ui',\n 'X-SDK-Variant-Source': 'react',\n 'X-SDK-Version': storefrontApiVersion,\n 'Shopify-Storefront-Private-Token':\n overrideProps?.privateStorefrontToken ?? privateStorefrontToken ?? '',\n ...(overrideProps?.buyerIp\n ? {'Shopify-Storefront-Buyer-IP': overrideProps.buyerIp}\n : {}),\n };\n },\n getPublicTokenHeaders(overrideProps) {\n if (!publicStorefrontToken && !overrideProps?.publicStorefrontToken) {\n throw new Error(\n `StorefrontClient: You did not pass in a 'publicStorefrontToken' while using 'getPublicTokenHeaders()'`\n );\n }\n\n const finalContentType = overrideProps?.contentType ?? contentType;\n\n return {\n // default to json\n 'content-type':\n finalContentType === 'graphql'\n ? 'application/graphql'\n : 'application/json',\n 'X-SDK-Variant': 'hydrogen-ui',\n 'X-SDK-Variant-Source': 'react',\n 'X-SDK-Version': storefrontApiVersion,\n 'X-Shopify-Storefront-Access-Token':\n overrideProps?.publicStorefrontToken ?? publicStorefrontToken ?? '',\n };\n },\n };\n}\n\ntype StorefrontClientProps = {\n /** The host name of the domain (eg: `{shop}.myshopify.com`). */\n storeDomain: string;\n /** The Storefront API delegate access token. Refer to the [authentication](https://shopify.dev/api/storefront#authentication) and [delegate access token](https://shopify.dev/apps/auth/oauth/delegate-access-tokens) documentation for more details. */\n privateStorefrontToken?: string;\n /** The Storefront API access token. Refer to the [authentication](https://shopify.dev/api/storefront#authentication) documentation for more details. */\n publicStorefrontToken?: string;\n /** The Storefront API version. This should almost always be the same as the version Hydrogen-UI was built for. Learn more about Shopify [API versioning](https://shopify.dev/api/usage/versioning) for more details. */\n storefrontApiVersion: string;\n /**\n * Customizes which `\"content-type\"` header is added when using `getPrivateTokenHeaders()` and `getPublicTokenHeaders()`. When fetching with a `JSON.stringify()`-ed `body`, use `\"json\"`. When fetching with a `body` that is a plain string, use `\"graphql\"`. Defaults to `\"json\"`\n *\n * Can also be customized on a call-by-call basis by passing in `'contentType'` to both `getPrivateTokenHeaders({...})` and `getPublicTokenHeaders({...})`, for example: `getPublicTokenHeaders({contentType: 'graphql'})`\n */\n contentType?: 'json' | 'graphql';\n};\n\ntype OverrideTokenHeaderProps = Partial<\n Pick<StorefrontClientProps, 'contentType'>\n>;\n\ntype StorefrontClientReturn = {\n /**\n * Creates the fully-qualified URL to your store's GraphQL endpoint.\n *\n * By default, it will use the config you passed in when calling `createStorefrontClient()`. However, you can override the following settings on each invocation of `getStorefrontApiUrl({...})`:\n *\n * - `storeDomain`\n * - `storefrontApiVersion`\n */\n getStorefrontApiUrl: (\n props?: Partial<\n Pick<StorefrontClientProps, 'storeDomain' | 'storefrontApiVersion'>\n >\n ) => string;\n /**\n * Returns an object that contains headers that are needed for each query to Storefront API GraphQL endpoint. This method uses the private Server-to-Server token which reduces the chance of throttling but must not be exposed to clients. Server-side calls should prefer using this over `getPublicTokenHeaders()`.\n *\n * By default, it will use the config you passed in when calling `createStorefrontClient()`. However, you can override the following settings on each invocation of `getPrivateTokenHeaders({...})`:\n *\n * - `contentType`\n * - `privateStorefrontToken`\n * - `buyerIp`\n *\n * Note that `contentType` defaults to what you configured in `createStorefrontClient({...})` and defaults to `'json'`, but a specific call may require using `graphql`. When using `JSON.stringify()` on the `body`, use `'json'`; otherwise, use `'graphql'`.\n */\n getPrivateTokenHeaders: (\n props?: OverrideTokenHeaderProps &\n Pick<StorefrontClientProps, 'privateStorefrontToken'> & {\n /**\n * The client's IP address. Passing this to the Storefront API when using a server-to-server token will help improve your store's analytics data.\n */\n buyerIp?: string;\n }\n ) => Record<string, string>;\n /**\n * Returns an object that contains headers that are needed for each query to Storefront API GraphQL endpoint. This method uses the private Server-to-Server token which reduces the chance of throttling but must not be exposed to clients. Server-side calls should prefer using this over `getPublicTokenHeaders()`.\n *\n * By default, it will use the config you passed in when calling `createStorefrontClient()`. However, you can override the following settings on each invocation of `getPrivateTokenHeaders({...})`:\n *\n * - `contentType`\n * - `publicStorefrontToken`\n *\n * Note that `contentType` defaults to what you configured in `createStorefrontClient({...})` and defaults to `'json'`, but a specific call may require using `graphql`. When using `JSON.stringify()` on the `body`, use `'json'`; otherwise, use `'graphql'`.\n */\n getPublicTokenHeaders: (\n props?: OverrideTokenHeaderProps &\n Pick<StorefrontClientProps, 'publicStorefrontToken'>\n ) => Record<string, string>;\n};\n"],"names":["SFAPI_VERSION"],"mappings":";;;AAOO,SAAS,uBAAuB;AAAA,EACrC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAkD;AAChD,MAAI,yBAAyBA,uBAAAA,eAAe;AAClC,YAAA;AAAA,MACN,4NAA4N,2CAA2CA,uBAAA;AAAA,IAAA;AAAA,EAE3Q;AAGA,MAAwB,CAAC,0BAA0B,CAAC,WAAW,UAAU;AAC/D,YAAA;AAAA,MACN;AAAA,IAAA;AAAA,EAEJ;AAGI,MAAoB,0BAA0B,YAAY;AACpD,YAAA;AAAA,MACN;AAAA,IAAA;AAAA,EAEJ;AAEO,SAAA;AAAA,IACL,oBAAoB,eAAe;;AACjC,aAAO,YACL,oDAAe,gBAAf,YAA8B,kCAE9B,oDAAe,yBAAf,YAAuC;AAAA,IAE3C;AAAA,IACA,uBAAuB,eAAe;;AACpC,UAAI,CAAC,0BAA0B,EAAC,+CAAe,yBAAwB;AACrE,cAAM,IAAI;AAAA,UACR;AAAA,QAAA;AAAA,MAEJ;AAEI,UAAoB,EAAC,+CAAe,UAAS;AACvC,gBAAA;AAAA,UACN;AAAA,QAAA;AAAA,MAEJ;AAEM,YAAA,oBAAmB,oDAAe,gBAAf,YAA8B;AAEhD,aAAA;AAAA,QAEL,gBACE,qBAAqB,YACjB,wBACA;AAAA,QACN,iBAAiB;AAAA,QACjB,wBAAwB;AAAA,QACxB,iBAAiB;AAAA,QACjB,qCACE,0DAAe,2BAAf,YAAyC,2BAAzC,YAAmE;AAAA,QACrE,IAAI,+CAAe,WACf,EAAC,+BAA+B,cAAc,QAAA,IAC9C,CAAC;AAAA,MAAA;AAAA,IAET;AAAA,IACA,sBAAsB,eAAe;;AACnC,UAAI,CAAC,yBAAyB,EAAC,+CAAe,wBAAuB;AACnE,cAAM,IAAI;AAAA,UACR;AAAA,QAAA;AAAA,MAEJ;AAEM,YAAA,oBAAmB,oDAAe,gBAAf,YAA8B;AAEhD,aAAA;AAAA,QAEL,gBACE,qBAAqB,YACjB,wBACA;AAAA,QACN,iBAAiB;AAAA,QACjB,wBAAwB;AAAA,QACxB,iBAAiB;AAAA,QACjB,sCACE,0DAAe,0BAAf,YAAwC,0BAAxC,YAAiE;AAAA,MAAA;AAAA,IAEvE;AAAA,EAAA;AAEJ;;"}
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const react = require("react");
|
|
4
|
-
const storefrontApiConstants = require("./storefront-api-constants.cjs");
|
|
5
|
-
const jsxRuntime = require("react/jsx-runtime");
|
|
6
|
-
const ShopifyContext = react.createContext({
|
|
7
|
-
storeDomain: "test.myshopify.com",
|
|
8
|
-
storefrontToken: "abc123",
|
|
9
|
-
storefrontApiVersion: storefrontApiConstants.SFAPI_VERSION,
|
|
10
|
-
country: {
|
|
11
|
-
isoCode: "US"
|
|
12
|
-
},
|
|
13
|
-
language: {
|
|
14
|
-
isoCode: "EN"
|
|
15
|
-
},
|
|
16
|
-
locale: "EN-US"
|
|
17
|
-
});
|
|
18
|
-
function ShopifyProvider({
|
|
19
|
-
children,
|
|
20
|
-
shopifyConfig
|
|
21
|
-
}) {
|
|
22
|
-
if (!shopifyConfig) {
|
|
23
|
-
throw new Error(`The 'shopifyConfig' prop must be passed to '<ShopifyProvider/>'`);
|
|
24
|
-
}
|
|
25
|
-
if (shopifyConfig.storefrontApiVersion !== storefrontApiConstants.SFAPI_VERSION) {
|
|
26
|
-
console.warn(`This version of Hydrogen-UI is built for Shopify's Storefront API version ${storefrontApiConstants.SFAPI_VERSION}, but it looks like you're using version ${shopifyConfig.storefrontApiVersion}. There may be issues or bugs if you use a mismatched version of Hydrogen-UI and the Storefront API.`);
|
|
27
|
-
}
|
|
28
|
-
const finalConfig = react.useMemo(() => ({
|
|
29
|
-
...shopifyConfig,
|
|
30
|
-
storeDomain: shopifyConfig.storeDomain.replace(/^https?:\/\//, "")
|
|
31
|
-
}), [shopifyConfig]);
|
|
32
|
-
return /* @__PURE__ */ jsxRuntime.jsx(ShopifyContext.Provider, {
|
|
33
|
-
value: finalConfig,
|
|
34
|
-
children
|
|
35
|
-
});
|
|
36
|
-
}
|
|
37
|
-
function useShop() {
|
|
38
|
-
const shopContext = react.useContext(ShopifyContext);
|
|
39
|
-
if (!shopContext) {
|
|
40
|
-
throw new Error(`'useShop()' must be a descendent of <ShopifyProvider/>`);
|
|
41
|
-
}
|
|
42
|
-
return shopContext;
|
|
43
|
-
}
|
|
44
|
-
exports.ShopifyProvider = ShopifyProvider;
|
|
45
|
-
exports.useShop = useShop;
|
|
46
|
-
//# sourceMappingURL=ShopifyProvider.cjs.map
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const CART_ID_STORAGE_KEY = "shopifyCartId";
|
|
4
|
-
const STOREFRONT_API_PUBLIC_TOKEN_HEADER = "X-Shopify-Storefront-Access-Token";
|
|
5
|
-
const SHOPIFY_STOREFRONT_ID_HEADER = "Shopify-Storefront-Id";
|
|
6
|
-
const SHOPIFY_STOREFRONT_Y_HEADER = "Shopify-Storefront-Y";
|
|
7
|
-
const SHOPIFY_STOREFRONT_S_HEADER = "Shopify-Storefront-S";
|
|
8
|
-
const SHOPIFY_Y = "_shopify_y";
|
|
9
|
-
const SHOPIFY_S = "_shopify_s";
|
|
10
|
-
exports.CART_ID_STORAGE_KEY = CART_ID_STORAGE_KEY;
|
|
11
|
-
exports.SHOPIFY_S = SHOPIFY_S;
|
|
12
|
-
exports.SHOPIFY_STOREFRONT_ID_HEADER = SHOPIFY_STOREFRONT_ID_HEADER;
|
|
13
|
-
exports.SHOPIFY_STOREFRONT_S_HEADER = SHOPIFY_STOREFRONT_S_HEADER;
|
|
14
|
-
exports.SHOPIFY_STOREFRONT_Y_HEADER = SHOPIFY_STOREFRONT_Y_HEADER;
|
|
15
|
-
exports.SHOPIFY_Y = SHOPIFY_Y;
|
|
16
|
-
exports.STOREFRONT_API_PUBLIC_TOKEN_HEADER = STOREFRONT_API_PUBLIC_TOKEN_HEADER;
|
|
17
|
-
//# sourceMappingURL=cart-constants.cjs.map
|
package/dist/prod/cart-hooks.cjs
DELETED
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const react = require("react");
|
|
4
|
-
const ShopifyProvider = require("./ShopifyProvider.cjs");
|
|
5
|
-
const cartConstants = require("./cart-constants.cjs");
|
|
6
|
-
const cookie = require("worktop/cookie");
|
|
7
|
-
function useCartFetch() {
|
|
8
|
-
const {
|
|
9
|
-
storeDomain,
|
|
10
|
-
storefrontApiVersion,
|
|
11
|
-
storefrontToken,
|
|
12
|
-
storefrontId
|
|
13
|
-
} = ShopifyProvider.useShop();
|
|
14
|
-
return react.useCallback(({
|
|
15
|
-
query,
|
|
16
|
-
variables
|
|
17
|
-
}) => {
|
|
18
|
-
const headers = {
|
|
19
|
-
"Content-Type": "application/json",
|
|
20
|
-
"X-SDK-Variant": "hydrogen",
|
|
21
|
-
"X-SDK-Version": storefrontApiVersion,
|
|
22
|
-
[cartConstants.STOREFRONT_API_PUBLIC_TOKEN_HEADER]: storefrontToken
|
|
23
|
-
};
|
|
24
|
-
if (storefrontId) {
|
|
25
|
-
headers[cartConstants.SHOPIFY_STOREFRONT_ID_HEADER] = storefrontId;
|
|
26
|
-
}
|
|
27
|
-
const cookieData = cookie.parse(document.cookie);
|
|
28
|
-
if (cookieData[cartConstants.SHOPIFY_Y] && cookieData[cartConstants.SHOPIFY_S]) {
|
|
29
|
-
headers[cartConstants.SHOPIFY_STOREFRONT_Y_HEADER] = cookieData[cartConstants.SHOPIFY_Y];
|
|
30
|
-
headers[cartConstants.SHOPIFY_STOREFRONT_S_HEADER] = cookieData[cartConstants.SHOPIFY_S];
|
|
31
|
-
}
|
|
32
|
-
return fetch(`https://${storeDomain}/api/${storefrontApiVersion}/graphql.json`, {
|
|
33
|
-
method: "POST",
|
|
34
|
-
headers,
|
|
35
|
-
body: JSON.stringify({
|
|
36
|
-
query: query.toString(),
|
|
37
|
-
variables
|
|
38
|
-
})
|
|
39
|
-
}).then((res) => res.json()).catch((error) => {
|
|
40
|
-
return {
|
|
41
|
-
data: void 0,
|
|
42
|
-
errors: error.toString()
|
|
43
|
-
};
|
|
44
|
-
});
|
|
45
|
-
}, [storeDomain, storefrontApiVersion, storefrontToken, storefrontId]);
|
|
46
|
-
}
|
|
47
|
-
exports.useCartFetch = useCartFetch;
|
|
48
|
-
//# sourceMappingURL=cart-hooks.cjs.map
|
package/dist/prod/index.cjs
DELETED
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const CartProvider = require("./CartProvider.cjs");
|
|
4
|
-
const ExternalVideo = require("./ExternalVideo.cjs");
|
|
5
|
-
const flattenConnection = require("./flatten-connection.cjs");
|
|
6
|
-
const Image = require("./Image.cjs");
|
|
7
|
-
const MediaFile = require("./MediaFile.cjs");
|
|
8
|
-
const Metafield = require("./Metafield.cjs");
|
|
9
|
-
const ModelViewer = require("./ModelViewer.cjs");
|
|
10
|
-
const Money = require("./Money.cjs");
|
|
11
|
-
const ProductPrice = require("./ProductPrice.cjs");
|
|
12
|
-
const ProductProvider = require("./ProductProvider.cjs");
|
|
13
|
-
const ShopifyProvider = require("./ShopifyProvider.cjs");
|
|
14
|
-
const ShopPayButton = require("./ShopPayButton.cjs");
|
|
15
|
-
const storefrontClient = require("./storefront-client.cjs");
|
|
16
|
-
const useMoney = require("./useMoney.cjs");
|
|
17
|
-
const Video = require("./Video.cjs");
|
|
18
|
-
exports.CartProvider = CartProvider.CartProvider;
|
|
19
|
-
exports.useCart = CartProvider.useCart;
|
|
20
|
-
exports.ExternalVideo = ExternalVideo.ExternalVideo;
|
|
21
|
-
exports.flattenConnection = flattenConnection.flattenConnection;
|
|
22
|
-
exports.Image = Image.Image;
|
|
23
|
-
exports.MediaFile = MediaFile.MediaFile;
|
|
24
|
-
exports.Metafield = Metafield.Metafield;
|
|
25
|
-
exports.parseMetafield = Metafield.parseMetafield;
|
|
26
|
-
exports.parseMetafieldValue = Metafield.parseMetafieldValue;
|
|
27
|
-
exports.ModelViewer = ModelViewer.ModelViewer;
|
|
28
|
-
exports.Money = Money.Money;
|
|
29
|
-
exports.ProductPrice = ProductPrice.ProductPrice;
|
|
30
|
-
exports.ProductProvider = ProductProvider.ProductProvider;
|
|
31
|
-
exports.useProduct = ProductProvider.useProduct;
|
|
32
|
-
exports.ShopifyProvider = ShopifyProvider.ShopifyProvider;
|
|
33
|
-
exports.useShop = ShopifyProvider.useShop;
|
|
34
|
-
exports.ShopPayButton = ShopPayButton.ShopPayButton;
|
|
35
|
-
exports.createStorefrontClient = storefrontClient.createStorefrontClient;
|
|
36
|
-
exports.useMoney = useMoney.useMoney;
|
|
37
|
-
exports.Video = Video.Video;
|
|
38
|
-
//# sourceMappingURL=index.cjs.map
|
package/dist/prod/index.cjs.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"storefront-api-constants.cjs","sources":["../../src/storefront-api-constants.ts"],"sourcesContent":["export const SFAPI_VERSION = '2022-10';\n"],"names":[],"mappings":";;AAAO,MAAM,gBAAgB;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"storefront-client.cjs","sources":["../../src/storefront-client.ts"],"sourcesContent":["import {SFAPI_VERSION} from './storefront-api-constants.js';\n\n/**\n * The `createStorefrontClient()` function creates helpers that enable you to quickly query the Shopify Storefront API.\n *\n * When used on the server, it is recommended to use the `privateStorefrontToken` prop. When used on the client, it is recommended to use the `publicStorefrontToken` prop.\n */\nexport function createStorefrontClient({\n storeDomain,\n privateStorefrontToken,\n publicStorefrontToken,\n storefrontApiVersion,\n contentType,\n}: StorefrontClientProps): StorefrontClientReturn {\n if (storefrontApiVersion !== SFAPI_VERSION) {\n console.warn(\n `StorefrontClient: The Storefront API version that you're using is different than the version this build of Hydrogen-UI is targeting. You may run into unexpected errors if these versions don't match. Received verion: \"${storefrontApiVersion}\"; expected version ${SFAPI_VERSION}`\n );\n }\n\n // only warn if not in a browser environment\n if (__HYDROGEN_DEV__ && !privateStorefrontToken && !globalThis.document) {\n console.warn(\n `StorefrontClient: Using a private storefront token is recommended for server environments. Refer to the authentication https://shopify.dev/api/storefront#authentication documentation for more details. `\n );\n }\n\n // only warn if in a browser environment and you're using the privateStorefrontToken\n if (__HYDROGEN_DEV__ && privateStorefrontToken && globalThis) {\n console.warn(\n `StorefrontClient: You are attempting to use a private token in an environment where it can be easily accessed by anyone. This is a security risk; please use the public token and the 'publicStorefrontToken' prop`\n );\n }\n\n return {\n getStorefrontApiUrl(overrideProps) {\n return `https://${\n overrideProps?.storeDomain ?? storeDomain\n }.myshopify.com/api/${\n overrideProps?.storefrontApiVersion ?? storefrontApiVersion\n }/graphql.json`;\n },\n getPrivateTokenHeaders(overrideProps) {\n if (!privateStorefrontToken && !overrideProps?.privateStorefrontToken) {\n throw new Error(\n `StorefrontClient: You did not pass in a 'privateStorefrontToken' while using 'getPrivateTokenHeaders()'`\n );\n }\n\n if (__HYDROGEN_DEV__ && !overrideProps?.buyerIp) {\n console.warn(\n `StorefrontClient: it is recommended to pass in the 'buyerIp' property which improves analytics and data in the admin.`\n );\n }\n\n const finalContentType = overrideProps?.contentType ?? contentType;\n\n return {\n // default to json\n 'content-type':\n finalContentType === 'graphql'\n ? 'application/graphql'\n : 'application/json',\n 'X-SDK-Variant': 'hydrogen-ui',\n 'X-SDK-Variant-Source': 'react',\n 'X-SDK-Version': storefrontApiVersion,\n 'Shopify-Storefront-Private-Token':\n overrideProps?.privateStorefrontToken ?? privateStorefrontToken ?? '',\n ...(overrideProps?.buyerIp\n ? {'Shopify-Storefront-Buyer-IP': overrideProps.buyerIp}\n : {}),\n };\n },\n getPublicTokenHeaders(overrideProps) {\n if (!publicStorefrontToken && !overrideProps?.publicStorefrontToken) {\n throw new Error(\n `StorefrontClient: You did not pass in a 'publicStorefrontToken' while using 'getPublicTokenHeaders()'`\n );\n }\n\n const finalContentType = overrideProps?.contentType ?? contentType;\n\n return {\n // default to json\n 'content-type':\n finalContentType === 'graphql'\n ? 'application/graphql'\n : 'application/json',\n 'X-SDK-Variant': 'hydrogen-ui',\n 'X-SDK-Variant-Source': 'react',\n 'X-SDK-Version': storefrontApiVersion,\n 'X-Shopify-Storefront-Access-Token':\n overrideProps?.publicStorefrontToken ?? publicStorefrontToken ?? '',\n };\n },\n };\n}\n\ntype StorefrontClientProps = {\n /** The host name of the domain (eg: `{shop}.myshopify.com`). */\n storeDomain: string;\n /** The Storefront API delegate access token. Refer to the [authentication](https://shopify.dev/api/storefront#authentication) and [delegate access token](https://shopify.dev/apps/auth/oauth/delegate-access-tokens) documentation for more details. */\n privateStorefrontToken?: string;\n /** The Storefront API access token. Refer to the [authentication](https://shopify.dev/api/storefront#authentication) documentation for more details. */\n publicStorefrontToken?: string;\n /** The Storefront API version. This should almost always be the same as the version Hydrogen-UI was built for. Learn more about Shopify [API versioning](https://shopify.dev/api/usage/versioning) for more details. */\n storefrontApiVersion: string;\n /**\n * Customizes which `\"content-type\"` header is added when using `getPrivateTokenHeaders()` and `getPublicTokenHeaders()`. When fetching with a `JSON.stringify()`-ed `body`, use `\"json\"`. When fetching with a `body` that is a plain string, use `\"graphql\"`. Defaults to `\"json\"`\n *\n * Can also be customized on a call-by-call basis by passing in `'contentType'` to both `getPrivateTokenHeaders({...})` and `getPublicTokenHeaders({...})`, for example: `getPublicTokenHeaders({contentType: 'graphql'})`\n */\n contentType?: 'json' | 'graphql';\n};\n\ntype OverrideTokenHeaderProps = Partial<\n Pick<StorefrontClientProps, 'contentType'>\n>;\n\ntype StorefrontClientReturn = {\n /**\n * Creates the fully-qualified URL to your store's GraphQL endpoint.\n *\n * By default, it will use the config you passed in when calling `createStorefrontClient()`. However, you can override the following settings on each invocation of `getStorefrontApiUrl({...})`:\n *\n * - `storeDomain`\n * - `storefrontApiVersion`\n */\n getStorefrontApiUrl: (\n props?: Partial<\n Pick<StorefrontClientProps, 'storeDomain' | 'storefrontApiVersion'>\n >\n ) => string;\n /**\n * Returns an object that contains headers that are needed for each query to Storefront API GraphQL endpoint. This method uses the private Server-to-Server token which reduces the chance of throttling but must not be exposed to clients. Server-side calls should prefer using this over `getPublicTokenHeaders()`.\n *\n * By default, it will use the config you passed in when calling `createStorefrontClient()`. However, you can override the following settings on each invocation of `getPrivateTokenHeaders({...})`:\n *\n * - `contentType`\n * - `privateStorefrontToken`\n * - `buyerIp`\n *\n * Note that `contentType` defaults to what you configured in `createStorefrontClient({...})` and defaults to `'json'`, but a specific call may require using `graphql`. When using `JSON.stringify()` on the `body`, use `'json'`; otherwise, use `'graphql'`.\n */\n getPrivateTokenHeaders: (\n props?: OverrideTokenHeaderProps &\n Pick<StorefrontClientProps, 'privateStorefrontToken'> & {\n /**\n * The client's IP address. Passing this to the Storefront API when using a server-to-server token will help improve your store's analytics data.\n */\n buyerIp?: string;\n }\n ) => Record<string, string>;\n /**\n * Returns an object that contains headers that are needed for each query to Storefront API GraphQL endpoint. This method uses the private Server-to-Server token which reduces the chance of throttling but must not be exposed to clients. Server-side calls should prefer using this over `getPublicTokenHeaders()`.\n *\n * By default, it will use the config you passed in when calling `createStorefrontClient()`. However, you can override the following settings on each invocation of `getPrivateTokenHeaders({...})`:\n *\n * - `contentType`\n * - `publicStorefrontToken`\n *\n * Note that `contentType` defaults to what you configured in `createStorefrontClient({...})` and defaults to `'json'`, but a specific call may require using `graphql`. When using `JSON.stringify()` on the `body`, use `'json'`; otherwise, use `'graphql'`.\n */\n getPublicTokenHeaders: (\n props?: OverrideTokenHeaderProps &\n Pick<StorefrontClientProps, 'publicStorefrontToken'>\n ) => Record<string, string>;\n};\n"],"names":["SFAPI_VERSION"],"mappings":";;;AAOO,SAAS,uBAAuB;AAAA,EACrC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAkD;AAChD,MAAI,yBAAyBA,uBAAAA,eAAe;AAClC,YAAA;AAAA,MACN,4NAA4N,2CAA2CA,uBAAA;AAAA,IAAA;AAAA,EAE3Q;AAgBO,SAAA;AAAA,IACL,oBAAoB,eAAe;;AACjC,aAAO,YACL,oDAAe,gBAAf,YAA8B,kCAE9B,oDAAe,yBAAf,YAAuC;AAAA,IAE3C;AAAA,IACA,uBAAuB,eAAe;;AACpC,UAAI,CAAC,0BAA0B,EAAC,+CAAe,yBAAwB;AACrE,cAAM,IAAI;AAAA,UACR;AAAA,QAAA;AAAA,MAEJ;AAQM,YAAA,oBAAmB,oDAAe,gBAAf,YAA8B;AAEhD,aAAA;AAAA,QAEL,gBACE,qBAAqB,YACjB,wBACA;AAAA,QACN,iBAAiB;AAAA,QACjB,wBAAwB;AAAA,QACxB,iBAAiB;AAAA,QACjB,qCACE,0DAAe,2BAAf,YAAyC,2BAAzC,YAAmE;AAAA,QACrE,IAAI,+CAAe,WACf,EAAC,+BAA+B,cAAc,QAAA,IAC9C,CAAC;AAAA,MAAA;AAAA,IAET;AAAA,IACA,sBAAsB,eAAe;;AACnC,UAAI,CAAC,yBAAyB,EAAC,+CAAe,wBAAuB;AACnE,cAAM,IAAI;AAAA,UACR;AAAA,QAAA;AAAA,MAEJ;AAEM,YAAA,oBAAmB,oDAAe,gBAAf,YAA8B;AAEhD,aAAA;AAAA,QAEL,gBACE,qBAAqB,YACjB,wBACA;AAAA,QACN,iBAAiB;AAAA,QACjB,wBAAwB;AAAA,QACxB,iBAAiB;AAAA,QACjB,sCACE,0DAAe,0BAAf,YAAwC,0BAAxC,YAAiE;AAAA,MAAA;AAAA,IAEvE;AAAA,EAAA;AAEJ;;"}
|