@beamimpact/web-sdk 1.55.8 → 1.56.3
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 +5 -0
- package/dist/chunks/_share-dialog-dependencies-Bk60ibnw.esm.js +2 -0
- package/dist/chunks/{_share-dialog-dependencies-BG0p8uUr.esm.js.map → _share-dialog-dependencies-Bk60ibnw.esm.js.map} +1 -1
- package/dist/chunks/_share-dialog-dependencies-D6vA_2f6.esm.js +2 -0
- package/dist/chunks/{_share-dialog-dependencies-dHlBUqo0.esm.js.map → _share-dialog-dependencies-D6vA_2f6.esm.js.map} +1 -1
- package/dist/chunks/{beam-errors-CCe004HS.esm.d.ts → beam-errors-DUQ9pK2V.esm.d.ts} +7 -1
- package/dist/chunks/{cart-contents-CLT7p7Gd.esm.d.ts → cart-contents-CEoSx3y4.esm.d.ts} +1 -1
- package/dist/chunks/{css-card-grid-CvoGpsJH.esm.js → css-card-grid-DixMt6ek.esm.js} +2 -2
- package/dist/chunks/{css-card-grid-CvoGpsJH.esm.js.map → css-card-grid-DixMt6ek.esm.js.map} +1 -1
- package/dist/chunks/enforce-config-DHnpgqSK.esm.js +3 -0
- package/dist/chunks/enforce-config-DHnpgqSK.esm.js.map +1 -0
- package/dist/chunks/enforce-config-DUbQnaLO.esm.js +3 -0
- package/dist/chunks/enforce-config-DUbQnaLO.esm.js.map +1 -0
- package/dist/chunks/events-COWOQoLW.esm.js +2 -0
- package/dist/chunks/{events-Dki0ka4F.esm.js.map → events-COWOQoLW.esm.js.map} +1 -1
- package/dist/chunks/{events-CSyogxoH.esm.d.ts → events-Dwqfqbij.esm.d.ts} +33 -5
- package/dist/chunks/index-8rOpG9kf.esm.js +2 -0
- package/dist/chunks/index-8rOpG9kf.esm.js.map +1 -0
- package/dist/chunks/{index-DnTE6QlY.esm.js → index-B1GmdVT3.esm.js} +2 -2
- package/dist/chunks/index-B1GmdVT3.esm.js.map +1 -0
- package/dist/chunks/{index-DEaZqGi7.esm.js → index-B2dxbh1d.esm.js} +2 -2
- package/dist/chunks/{index-DEaZqGi7.esm.js.map → index-B2dxbh1d.esm.js.map} +1 -1
- package/dist/chunks/{index-2OQzw7UI.esm.js → index-BEEmYYxP.esm.js} +28 -18
- package/dist/chunks/index-BEEmYYxP.esm.js.map +1 -0
- package/dist/chunks/{index-RhV6PBPH.esm.js → index-BIEV1MH0.esm.js} +2 -2
- package/dist/chunks/{index-RhV6PBPH.esm.js.map → index-BIEV1MH0.esm.js.map} +1 -1
- package/dist/chunks/{index-CBS5Fqry.esm.d.ts → index-BLlSL37B.esm.d.ts} +4 -2
- package/dist/chunks/{index-C-hPf29c.esm.d.ts → index-BY5lSRmw.esm.d.ts} +4 -1
- package/dist/chunks/index-BaWMWAyt.esm.js +2 -0
- package/dist/chunks/index-BaWMWAyt.esm.js.map +1 -0
- package/dist/chunks/index-BeX4QeUu.esm.js +2 -0
- package/dist/chunks/index-BeX4QeUu.esm.js.map +1 -0
- package/dist/chunks/{index-CGKJagBi.esm.js → index-C3v-y56g.esm.js} +2 -2
- package/dist/chunks/index-C3v-y56g.esm.js.map +1 -0
- package/dist/chunks/{index-CJ1y1kTs.esm.d.ts → index-C_u1FXtO.esm.d.ts} +33 -5
- package/dist/chunks/{index-DrxhkT6Y.esm.js → index-CqqF1sQo.esm.js} +2 -2
- package/dist/chunks/index-CqqF1sQo.esm.js.map +1 -0
- package/dist/chunks/index-Cs4Kp9X4.esm.js +2 -0
- package/dist/chunks/index-Cs4Kp9X4.esm.js.map +1 -0
- package/dist/chunks/index-D20ifskY.esm.d.ts +21 -0
- package/dist/chunks/{index-BTDB5Gk-.esm.js → index-D3hxLDQF.esm.js} +2 -2
- package/dist/chunks/index-D3hxLDQF.esm.js.map +1 -0
- package/dist/chunks/{index-DBb5HSkR.esm.js → index-D5TZB-zM.esm.js} +2 -2
- package/dist/chunks/index-D5TZB-zM.esm.js.map +1 -0
- package/dist/chunks/{index-iqYDqEil.esm.d.ts → index-DDCtGN21.esm.d.ts} +15 -2
- package/dist/chunks/index-DSJACB_p.esm.js +2 -0
- package/dist/chunks/{index-BNjsFEGn.esm.js.map → index-DSJACB_p.esm.js.map} +1 -1
- package/dist/chunks/{index-Ct1m4IjM.esm.js → index-DmjZnpod.esm.js} +2 -2
- package/dist/chunks/index-DmjZnpod.esm.js.map +1 -0
- package/dist/chunks/{index-rxgS4BLp.esm.d.ts → index-DyUuvdr3.esm.d.ts} +6 -2
- package/dist/chunks/{index-B1lGZARl.esm.d.ts → index-EJRmgmQu.esm.d.ts} +33 -5
- package/dist/chunks/{index-C5gnsl34.esm.js → index-UMeAzKTG.esm.js} +28 -18
- package/dist/chunks/index-UMeAzKTG.esm.js.map +1 -0
- package/dist/chunks/{index-BjGPkgs-.esm.d.ts → index-hghrT7Z_.esm.d.ts} +13 -1
- package/dist/chunks/index-mppXVWCH.esm.js +2 -0
- package/dist/chunks/{index-IKiJwo5v.esm.js.map → index-mppXVWCH.esm.js.map} +1 -1
- package/dist/chunks/{index-Cg65EbvX.esm.js → index-n62IxH5D.esm.js} +2 -2
- package/dist/chunks/index-n62IxH5D.esm.js.map +1 -0
- package/dist/chunks/{index-tbwbkOdj.esm.js → index-nAPzvUWE.esm.js} +2 -2
- package/dist/chunks/index-nAPzvUWE.esm.js.map +1 -0
- package/dist/chunks/{index-DXj15KHe.esm.d.ts → index-xcGPhpiO.esm.d.ts} +13 -1
- package/dist/chunks/lit-JRlupCB5.esm.js +25 -0
- package/dist/chunks/lit-JRlupCB5.esm.js.map +1 -0
- package/dist/chunks/loading-template-BFvXaTlD.esm.js +2 -0
- package/dist/chunks/{loading-template-DG4lkIIc.esm.js.map → loading-template-BFvXaTlD.esm.js.map} +1 -1
- package/dist/chunks/{localize-Btu9xYcE.esm.js → localize-Dg7NgKIP.esm.js} +4 -4
- package/dist/chunks/localize-Dg7NgKIP.esm.js.map +1 -0
- package/dist/chunks/{localize-C25pEGnx.esm.js → localize-DkAbsh05.esm.js} +4 -4
- package/dist/chunks/localize-DkAbsh05.esm.js.map +1 -0
- package/dist/chunks/lodash-BSs6Il-c.esm.js +2 -0
- package/dist/chunks/lodash-BSs6Il-c.esm.js.map +1 -0
- package/dist/chunks/{openapi-spec-Bk7E2QQP.esm.d.ts → openapi-spec-B4z4_CMq.esm.d.ts} +18 -0
- package/dist/chunks/{order-page-BRG7MXZ2.esm.js → order-page-B0WbVrvh.esm.js} +2 -2
- package/dist/chunks/order-page-B0WbVrvh.esm.js.map +1 -0
- package/dist/chunks/{order-page-Qn1yyNbN.esm.d.ts → order-page-CSEjG6ma.esm.d.ts} +19 -18
- package/dist/chunks/{order-page-BbHDQfmy.esm.js → order-page-CT3hnhzf.esm.js} +2 -2
- package/dist/chunks/order-page-CT3hnhzf.esm.js.map +1 -0
- package/dist/chunks/{progress-bar-DF7UuuHb.esm.js → progress-bar-B82FOT8n.esm.js} +2 -2
- package/dist/chunks/{progress-bar-DF7UuuHb.esm.js.map → progress-bar-B82FOT8n.esm.js.map} +1 -1
- package/dist/chunks/{promo-pill-label-ByFGhdxh.esm.js → promo-pill-label-D_4zJ7uy.esm.js} +3 -3
- package/dist/chunks/{promo-pill-label-ByFGhdxh.esm.js.map → promo-pill-label-D_4zJ7uy.esm.js.map} +1 -1
- package/dist/chunks/{promo-pill-label-WGLW3bql.esm.js → promo-pill-label-DcsiJS_N.esm.js} +3 -3
- package/dist/chunks/{promo-pill-label-WGLW3bql.esm.js.map → promo-pill-label-DcsiJS_N.esm.js.map} +1 -1
- package/dist/chunks/{promo-types-7r9-UuiP.esm.d.ts → promo-types-CmZzhkpN.esm.d.ts} +3 -2
- package/dist/chunks/{responsive-BR8qUfBa.esm.js → responsive-CIV4sFdH.esm.js} +2 -2
- package/dist/chunks/{responsive-BR8qUfBa.esm.js.map → responsive-CIV4sFdH.esm.js.map} +1 -1
- package/dist/chunks/routes-BIMwJ8u9.esm.js +2 -0
- package/dist/chunks/routes-BIMwJ8u9.esm.js.map +1 -0
- package/dist/chunks/routes-DSu5s3K7.esm.js +2 -0
- package/dist/chunks/routes-DSu5s3K7.esm.js.map +1 -0
- package/dist/chunks/routes-OxC3Ah30.esm.d.ts +638 -0
- package/dist/chunks/{share-button-DPNNnXeM.esm.js → share-button-CLMw49f5.esm.js} +2 -2
- package/dist/chunks/{share-button-DPNNnXeM.esm.js.map → share-button-CLMw49f5.esm.js.map} +1 -1
- package/dist/chunks/{share-button-M8cMa6ol.esm.js → share-button-DXS3zbJz.esm.js} +2 -2
- package/dist/chunks/{share-button-M8cMa6ol.esm.js.map → share-button-DXS3zbJz.esm.js.map} +1 -1
- package/dist/chunks/{share-button-BRjKJc5L.esm.js → share-button-DkTpGZk1.esm.js} +8 -3
- package/dist/chunks/share-button-DkTpGZk1.esm.js.map +1 -0
- package/dist/chunks/{share-button-DmjRJmXh.esm.js → share-button-Dzc7loia.esm.js} +8 -3
- package/dist/chunks/share-button-Dzc7loia.esm.js.map +1 -0
- package/dist/chunks/{types-CPxMwnoR.esm.d.ts → types-D_PLq1pj.esm.d.ts} +1 -1
- package/dist/chunks/{update-cart-gwNcGXkd.esm.js → update-cart-ByUvNLyZ.esm.js} +2 -2
- package/dist/chunks/update-cart-ByUvNLyZ.esm.js.map +1 -0
- package/dist/chunks/{update-cart-CauFT0AF.esm.d.ts → update-cart-DWgFuC7U.esm.d.ts} +3 -2
- package/dist/chunks/{update-cart-CJywJNax.esm.js → update-cart-yj_9VGHp.esm.js} +2 -2
- package/dist/chunks/update-cart-yj_9VGHp.esm.js.map +1 -0
- package/dist/chunks/vendor-ckSdd6aH.esm.js +1286 -0
- package/dist/chunks/vendor-ckSdd6aH.esm.js.map +1 -0
- package/dist/components/beam-partner-logos.esm.js +5 -5
- package/dist/components/beam-partner-logos.esm.js.map +1 -1
- package/dist/components/beam-partner-logos.js +5 -5
- package/dist/components/beam-partner-logos.js.map +1 -1
- package/dist/components/community-impact.d.ts +1 -3
- package/dist/components/community-impact.esm.js +11 -6
- package/dist/components/community-impact.esm.js.map +1 -1
- package/dist/components/community-impact.js +11 -6
- package/dist/components/community-impact.js.map +1 -1
- package/dist/components/cumulative-impact.d.ts +1 -1
- package/dist/components/cumulative-impact.esm.js +10 -10
- package/dist/components/cumulative-impact.esm.js.map +1 -1
- package/dist/components/cumulative-impact.js +10 -10
- package/dist/components/cumulative-impact.js.map +1 -1
- package/dist/components/impact-overview.d.ts +36 -39
- package/dist/components/impact-overview.esm.js +11 -6
- package/dist/components/impact-overview.esm.js.map +1 -1
- package/dist/components/impact-overview.js +11 -6
- package/dist/components/impact-overview.js.map +1 -1
- package/dist/components/index.d.ts +5 -8
- package/dist/components/index.esm.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/post-purchase.d.ts +9 -11
- package/dist/components/post-purchase.esm.js +4 -4
- package/dist/components/post-purchase.esm.js.map +1 -1
- package/dist/components/post-purchase.js +4 -4
- package/dist/components/post-purchase.js.map +1 -1
- package/dist/components/product-details-page.d.ts +26 -27
- package/dist/components/product-details-page.esm.js +18 -18
- package/dist/components/product-details-page.esm.js.map +1 -1
- package/dist/components/product-details-page.js +18 -18
- package/dist/components/product-details-page.js.map +1 -1
- package/dist/components/redeem-transaction.d.ts +3 -6
- package/dist/components/redeem-transaction.esm.js +1 -1
- package/dist/components/redeem-transaction.js +1 -1
- package/dist/components/select-nonprofit.d.ts +3 -15
- package/dist/components/select-nonprofit.esm.js +6 -5
- package/dist/components/select-nonprofit.esm.js.map +1 -1
- package/dist/components/select-nonprofit.js +6 -5
- package/dist/components/select-nonprofit.js.map +1 -1
- package/dist/components/select-subscription-nonprofit.d.ts +1 -2
- package/dist/components/select-subscription-nonprofit.esm.js +42 -21
- package/dist/components/select-subscription-nonprofit.esm.js.map +1 -1
- package/dist/components/select-subscription-nonprofit.js +42 -21
- package/dist/components/select-subscription-nonprofit.js.map +1 -1
- package/dist/components/shopify.d.ts +8 -12
- package/dist/components/shopify.esm.js +1 -1
- package/dist/components/shopify.js +1 -1
- package/dist/components/social-share.d.ts +13 -2
- package/dist/components/social-share.esm.js +11 -4
- package/dist/components/social-share.esm.js.map +1 -1
- package/dist/components/social-share.js +11 -4
- package/dist/components/social-share.js.map +1 -1
- package/dist/components/subscription-impact.d.ts +36 -49
- package/dist/components/subscription-impact.esm.js +15 -3
- package/dist/components/subscription-impact.esm.js.map +1 -1
- package/dist/components/subscription-impact.js +15 -3
- package/dist/components/subscription-impact.js.map +1 -1
- package/dist/components/subscription-management.d.ts +91 -92
- package/dist/components/subscription-management.esm.js +4 -3
- package/dist/components/subscription-management.esm.js.map +1 -1
- package/dist/components/subscription-management.js +4 -3
- package/dist/components/subscription-management.js.map +1 -1
- package/dist/index.d.ts +19 -22
- package/dist/index.esm.js +1 -1
- package/dist/index.js +1 -1
- package/dist/integrations/beam.d.ts +3 -2
- package/dist/integrations/beam.esm.js +1 -1
- package/dist/integrations/beam.esm.js.map +1 -1
- package/dist/integrations/beam.js +1 -1
- package/dist/integrations/beam.js.map +1 -1
- package/dist/integrations/cart.d.ts +3 -3
- package/dist/integrations/cart.esm.js +1 -1
- package/dist/integrations/cart.js +1 -1
- package/dist/integrations/index.d.ts +14 -18
- package/dist/integrations/index.esm.js +1 -1
- package/dist/integrations/index.js +1 -1
- package/dist/integrations/logs.d.ts +2 -2
- package/dist/integrations/logs.esm.js +1 -1
- package/dist/integrations/logs.js +1 -1
- package/dist/integrations/promoManager.d.ts +1 -1
- package/dist/integrations/promoManager.esm.js +1 -1
- package/dist/integrations/promoManager.esm.js.map +1 -1
- package/dist/integrations/promoManager.js +1 -1
- package/dist/integrations/promoManager.js.map +1 -1
- package/dist/integrations/session.d.ts +1 -1
- package/dist/integrations/session.esm.js +1 -1
- package/dist/integrations/session.js +1 -1
- package/dist/integrations/shopify.d.ts +6 -10
- package/dist/integrations/shopify.esm.js +1 -1
- package/dist/integrations/shopify.js +1 -1
- package/dist/integrations/statsig.d.ts +9 -5
- package/dist/integrations/statsig.esm.js +14 -14
- package/dist/integrations/statsig.esm.js.map +1 -1
- package/dist/integrations/statsig.js +14 -14
- package/dist/integrations/statsig.js.map +1 -1
- package/dist/integrations/utils.d.ts +7 -7
- package/dist/integrations/utils.esm.js +1 -1
- package/dist/integrations/utils.js +1 -1
- package/dist/react/beam-partner-logos.esm.js +1 -1
- package/dist/react/beam-partner-logos.js +1 -1
- package/dist/react/community-impact.d.ts +1 -3
- package/dist/react/community-impact.esm.js +1 -1
- package/dist/react/community-impact.esm.js.map +1 -1
- package/dist/react/community-impact.js +1 -1
- package/dist/react/community-impact.js.map +1 -1
- package/dist/react/cumulative-impact.d.ts +1 -1
- package/dist/react/cumulative-impact.esm.js +1 -1
- package/dist/react/cumulative-impact.esm.js.map +1 -1
- package/dist/react/cumulative-impact.js +1 -1
- package/dist/react/cumulative-impact.js.map +1 -1
- package/dist/react/impact-overview.d.ts +1 -4
- package/dist/react/impact-overview.esm.js +1 -1
- package/dist/react/impact-overview.esm.js.map +1 -1
- package/dist/react/impact-overview.js +1 -1
- package/dist/react/impact-overview.js.map +1 -1
- package/dist/react/index.d.ts +7 -10
- package/dist/react/index.esm.js +1 -1
- package/dist/react/index.js +1 -1
- package/dist/react/post-purchase.d.ts +3 -7
- package/dist/react/post-purchase.esm.js +1 -1
- package/dist/react/post-purchase.esm.js.map +1 -1
- package/dist/react/post-purchase.js +1 -1
- package/dist/react/post-purchase.js.map +1 -1
- package/dist/react/product-details-page.d.ts +1 -2
- package/dist/react/product-details-page.esm.js +1 -1
- package/dist/react/product-details-page.esm.js.map +1 -1
- package/dist/react/product-details-page.js +1 -1
- package/dist/react/product-details-page.js.map +1 -1
- package/dist/react/redeem-transaction.d.ts +5 -8
- package/dist/react/redeem-transaction.esm.js +1 -1
- package/dist/react/redeem-transaction.esm.js.map +1 -1
- package/dist/react/redeem-transaction.js +1 -1
- package/dist/react/redeem-transaction.js.map +1 -1
- package/dist/react/select-nonprofit.d.ts +5 -7
- package/dist/react/select-nonprofit.esm.js +1 -1
- package/dist/react/select-nonprofit.esm.js.map +1 -1
- package/dist/react/select-nonprofit.js +1 -1
- package/dist/react/select-nonprofit.js.map +1 -1
- package/dist/react/select-subscription-nonprofit.d.ts +5 -6
- package/dist/react/select-subscription-nonprofit.esm.js +1 -1
- package/dist/react/select-subscription-nonprofit.esm.js.map +1 -1
- package/dist/react/select-subscription-nonprofit.js +1 -1
- package/dist/react/select-subscription-nonprofit.js.map +1 -1
- package/dist/react/social-share.d.ts +1 -2
- package/dist/react/social-share.esm.js +1 -1
- package/dist/react/social-share.esm.js.map +1 -1
- package/dist/react/social-share.js +1 -1
- package/dist/react/social-share.js.map +1 -1
- package/dist/react/subscription-impact.d.ts +1 -3
- package/dist/react/subscription-impact.esm.js +1 -1
- package/dist/react/subscription-impact.esm.js.map +1 -1
- package/dist/react/subscription-impact.js +1 -1
- package/dist/react/subscription-impact.js.map +1 -1
- package/dist/react/subscription-management.d.ts +4 -6
- package/dist/react/subscription-management.esm.js +1 -1
- package/dist/react/subscription-management.esm.js.map +1 -1
- package/dist/react/subscription-management.js +1 -1
- package/dist/react/subscription-management.js.map +1 -1
- package/dist/utils/beam-errors.d.ts +1 -1
- package/dist/utils/cookies.d.ts +1 -41
- package/dist/utils/cookies.esm.js +1 -1
- package/dist/utils/cookies.esm.js.map +1 -1
- package/dist/utils/cookies.js +1 -1
- package/dist/utils/cookies.js.map +1 -1
- package/dist/utils/debounce.esm.js +1 -1
- package/dist/utils/debounce.js +1 -1
- package/dist/utils/events.d.ts +5 -5
- package/dist/utils/events.esm.js +1 -1
- package/dist/utils/events.js +1 -1
- package/dist/utils/index.d.ts +7 -7
- package/dist/utils/index.esm.js +1 -1
- package/dist/utils/index.js +1 -1
- package/dist/utils/is-equal.esm.js +1 -1
- package/dist/utils/is-equal.js +1 -1
- package/dist/utils/memoize-last.esm.js +1 -1
- package/dist/utils/memoize-last.js +1 -1
- package/dist/utils/network-listeners.esm.js +1 -1
- package/dist/utils/network-listeners.esm.js.map +1 -1
- package/dist/utils/network-listeners.js +1 -1
- package/dist/utils/network-listeners.js.map +1 -1
- package/dist/utils/promoManager.d.ts +6 -18
- package/dist/utils/promoManager.esm.js.map +1 -1
- package/dist/utils/promoManager.js.map +1 -1
- package/package.json +42 -39
- package/dist/chunks/_share-dialog-dependencies-BG0p8uUr.esm.js +0 -2
- package/dist/chunks/_share-dialog-dependencies-dHlBUqo0.esm.js +0 -2
- package/dist/chunks/enforce-config-Ba1JkOHs.esm.js +0 -3
- package/dist/chunks/enforce-config-Ba1JkOHs.esm.js.map +0 -1
- package/dist/chunks/enforce-config-CZ3ToOgr.esm.js +0 -3
- package/dist/chunks/enforce-config-CZ3ToOgr.esm.js.map +0 -1
- package/dist/chunks/events-Dki0ka4F.esm.js +0 -2
- package/dist/chunks/index-2OQzw7UI.esm.js.map +0 -1
- package/dist/chunks/index-B1Y88trP.esm.js +0 -2
- package/dist/chunks/index-B1Y88trP.esm.js.map +0 -1
- package/dist/chunks/index-B7hOLixE.esm.d.ts +0 -15
- package/dist/chunks/index-BNjsFEGn.esm.js +0 -2
- package/dist/chunks/index-BTDB5Gk-.esm.js.map +0 -1
- package/dist/chunks/index-BX6GnRsb.esm.js +0 -2
- package/dist/chunks/index-BX6GnRsb.esm.js.map +0 -1
- package/dist/chunks/index-C5gnsl34.esm.js.map +0 -1
- package/dist/chunks/index-CGKJagBi.esm.js.map +0 -1
- package/dist/chunks/index-CWKcDbs6.esm.js +0 -2
- package/dist/chunks/index-CWKcDbs6.esm.js.map +0 -1
- package/dist/chunks/index-Cg65EbvX.esm.js.map +0 -1
- package/dist/chunks/index-Ct1m4IjM.esm.js.map +0 -1
- package/dist/chunks/index-DBb5HSkR.esm.js.map +0 -1
- package/dist/chunks/index-DnTE6QlY.esm.js.map +0 -1
- package/dist/chunks/index-DrxhkT6Y.esm.js.map +0 -1
- package/dist/chunks/index-IKiJwo5v.esm.js +0 -2
- package/dist/chunks/index-eCVyk0rc.esm.js +0 -2
- package/dist/chunks/index-eCVyk0rc.esm.js.map +0 -1
- package/dist/chunks/index-tbwbkOdj.esm.js.map +0 -1
- package/dist/chunks/lit-WqMxC_PA.esm.js +0 -34
- package/dist/chunks/lit-WqMxC_PA.esm.js.map +0 -1
- package/dist/chunks/loading-template-DG4lkIIc.esm.js +0 -2
- package/dist/chunks/localize-Btu9xYcE.esm.js.map +0 -1
- package/dist/chunks/localize-C25pEGnx.esm.js.map +0 -1
- package/dist/chunks/lodash-D3TLHRR_.esm.js +0 -2
- package/dist/chunks/lodash-D3TLHRR_.esm.js.map +0 -1
- package/dist/chunks/order-page-BRG7MXZ2.esm.js.map +0 -1
- package/dist/chunks/order-page-BbHDQfmy.esm.js.map +0 -1
- package/dist/chunks/progress-bar-CveZ8E6Q.esm.d.ts +0 -15
- package/dist/chunks/promo-pill-label-BXRqZHET.esm.d.ts +0 -19
- package/dist/chunks/routes-BvX92EDq.esm.js +0 -2
- package/dist/chunks/routes-BvX92EDq.esm.js.map +0 -1
- package/dist/chunks/routes-DahRzf8t.esm.d.ts +0 -638
- package/dist/chunks/routes-DguZveS3.esm.js +0 -2
- package/dist/chunks/routes-DguZveS3.esm.js.map +0 -1
- package/dist/chunks/share-button-BRjKJc5L.esm.js.map +0 -1
- package/dist/chunks/share-button-CDVVaxEc.esm.d.ts +0 -27
- package/dist/chunks/share-button-DmjRJmXh.esm.js.map +0 -1
- package/dist/chunks/update-cart-CJywJNax.esm.js.map +0 -1
- package/dist/chunks/update-cart-gwNcGXkd.esm.js.map +0 -1
- package/dist/chunks/vendor-KKSARHWL.esm.js +0 -1284
- package/dist/chunks/vendor-KKSARHWL.esm.js.map +0 -1
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import"./promo-types-DKAOFHJr.esm.js";import{B as y,N as d}from"./beam-errors-Ci0d3926.esm.js";import{logger as p}from"../utils/logger.js";const l="https://api.beamimpact.com",O="https://production.beamimpactlogs.com",v={en:"en",fr:"fr",de:"de",es:"es",it:"it",pl:"pl",ja:"ja"},w={select_nonprofit:"select-nonprofit",redeem_transaction:"redeem-transaction",impact_overview:"impact-overview",community_impact:"community-impact",cumulative_impact:"cumulative-impact",product_details_page:"product-details-page",subscription_management:"subscription-management",subscription_impact:"subscription-impact",select_subscription_nonprofit:"select-subscription-nonprofit",social_share:"social-share"},C={cart_update:"cart_update"},L={NONPROFIT:"nonprofit",NONPROFIT_SELECTED_AT:"nonprofit_selected_at"};var A="1.55.8",R={"@shoelace-style/shoelace":"2.15.0","lucide-static":"0.292.0"};async function u(o,s){const c={method:"GET",...s,headers:{"Content-Type":"application/json",Accept:"application/json","X-Beam-Client":"WebSDK","X-Beam-Client-Version":A,...s?.headers},preflightContinue:!0,mode:s?.mode||"cors",body:s?.body!=null?s.body:void 0};let i;try{i=await fetch(o,c)}catch(e){const a=new y(`Network call failed (${c?.method.toUpperCase()} ${o})`);throw a.cause=e,p.error(a,o),a}let r,n;try{n=await i.text(),n&&(r=JSON.parse(n))}catch(e){let a=e;throw e instanceof SyntaxError&&(a=new d(i,r,`Response invalid. Expected JSON. Received: "${n}"`),a.cause=e),p.error(a),a}if(!i.ok){const e=new d(i,r,"Response was not OK");throw p.error(e),e}return r}const t=(o,s,c)=>({[o]:async function({headers:i={},baseUrl:r=l,apiRoot:n="/api/v3",pathParams:e={},queryParams:a={},requestBody:h}){const f=Object.entries(e).reduce((g,[E,N])=>g.replace(`{${E}}`,N),o),_=JSON.parse(JSON.stringify(a)),m=new URLSearchParams(_).toString(),S=r+n+f+(m&&`?${m}`),b={headers:i,method:s,body:JSON.stringify(h)};return u(S,b)}})[o];t("/chain/{chainId}/nonprofits","get");const T=t("/impact","get"),P=t("/chain/{chainId}/cumulativeImpact","get"),D=t("/selectNonprofit","post");t("/transaction","post"),t("/transaction/{transactionId}","put");const I=t("/cart","post"),U=t("/chain/findEligibleNonprofitsForCart","post"),F=t("/logs","post"),j=t("/experimentSession","post"),x=t("/subscriptions/updateSubscriptionNonprofit","post"),B=t("/subscriptions/findOrCreateSubscription","post"),G=t("/productDetailsPage","post");export{l as D,C as H,L,v as S,w as W,O as a,F as b,j as c,U as d,B as e,u as f,T as g,D as h,P as i,G as j,R as k,t as m,I as p,x as u};
|
|
2
|
-
//# sourceMappingURL=routes-BvX92EDq.esm.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"routes-BvX92EDq.esm.js","sources":["../../src/api-sdk/constants.ts","../../src/api-sdk/fetch-json.ts","../../src/api-sdk/make-openapi-method.ts","../../src/api-sdk/v3/routes.ts"],"sourcesContent":["import { PROMO_LOCAL_STORAGE_KEY } from \"../shared/promo-types\";\nimport { LANGUAGES, TUrl } from \"./types\";\n\nexport const DEFAULT_BASE_URL: TUrl = \"https://api.beamimpact.com\";\n\nexport const DEFAULT_LOG_URL = \"https://production.beamimpactlogs.com\";\n\nexport const SUPPORTED_LANGUAGES: Record<string, LANGUAGES> = {\n en: \"en\",\n fr: \"fr\",\n de: \"de\",\n es: \"es\",\n it: \"it\",\n pl: \"pl\",\n ja: \"ja\",\n};\n\nexport const WIDGET_NAMES = {\n select_nonprofit: \"select-nonprofit\",\n redeem_transaction: \"redeem-transaction\",\n impact_overview: \"impact-overview\",\n community_impact: \"community-impact\",\n cumulative_impact: \"cumulative-impact\",\n product_details_page: \"product-details-page\",\n subscription_management: \"subscription-management\",\n subscription_impact: \"subscription-impact\",\n select_subscription_nonprofit: \"select-subscription-nonprofit\",\n social_share: \"social-share\",\n} as const;\n\nexport const HELPER_NAMES = {\n cart_update: \"cart_update\",\n};\n\n// TODO: https://beamimpact.atlassian.net/browse/ENG-721\nexport const LOCAL_STORAGE_KEYS = {\n TRANSACTION: \"transaction\",\n CART: \"cart\",\n PROMO: PROMO_LOCAL_STORAGE_KEY,\n NONPROFIT: \"nonprofit\",\n NONPROFIT_SELECTED_AT: \"nonprofit_selected_at\",\n} as const;\n","/**\n * Wrapper over window.fetch that expects/returns JSON\n */\nimport { BeamError, NetworkError } from \"../utils/beam-errors\";\nimport { logger } from \"../utils/logger\";\nimport { version as pkgVersion } from \"../../package.json\";\n\nexport async function fetchJson<T = unknown>(url: RequestInfo, options?: RequestInit): Promise<T> {\n const fetchOptions = {\n method: \"GET\",\n ...options,\n headers: {\n \"Content-Type\": \"application/json\",\n Accept: \"application/json\",\n \"X-Beam-Client\": \"WebSDK\",\n \"X-Beam-Client-Version\": pkgVersion,\n ...options?.headers,\n },\n preflightContinue: true,\n mode: options?.mode || \"cors\",\n body: options?.body != null ? options.body : undefined,\n };\n\n let response;\n try {\n response = await fetch(url, fetchOptions);\n // fetch can throw a TypeError if the server can't be reached, catch and log below\n } catch (err) {\n const error = new BeamError(`Network call failed (${fetchOptions?.method.toUpperCase()} ${url})`);\n error.cause = err;\n logger.error(error, url);\n throw error;\n }\n let body;\n let text;\n // This can throw a SyntaxError if response payload is malformed JSON\n try {\n text = await response.text();\n if (text) {\n // (response can be empty)\n body = JSON.parse(text);\n }\n } catch (err) {\n let error = err as Error;\n if (err instanceof SyntaxError) {\n error = new NetworkError(response, body, `Response invalid. Expected JSON. Received: \"${text}\"`);\n error.cause = err;\n }\n logger.error(error);\n throw error;\n }\n // Translate 4xx, 5xx status to runtime error\n if (!response.ok) {\n const error = new NetworkError(response, body, \"Response was not OK\");\n logger.error(error);\n throw error;\n }\n\n return body;\n}\n","/* eslint-disable @typescript-eslint/no-explicit-any */\n\nimport { DEFAULT_BASE_URL } from \"./constants\";\nimport { fetchJson } from \"./fetch-json\";\nimport { paths } from \"./openapi-spec\";\nimport { THttpMethod } from \"./types\";\n\nexport const makeOpenApiMethod = <\n TPathName extends keyof paths,\n TMethod extends keyof paths[TPathName],\n TStatusCode extends paths[TPathName][TMethod] extends { responses: any }\n ? keyof paths[TPathName][TMethod][\"responses\"]\n : never\n>(\n pathName: TPathName,\n method: TMethod,\n okHttpStatus: TStatusCode\n) => {\n type TRouteSpec = paths[typeof pathName];\n type TRouteMethod = TRouteSpec[typeof method];\n type TParams = \"parameters\" extends keyof TRouteMethod ? TRouteMethod[\"parameters\"] : never;\n type TPathParams = TParams extends { path: any } ? TParams[\"path\"] : Record<string, never>;\n type TQueryParams = TParams extends { query: any } ? TParams[\"query\"] : Record<string, never>;\n type TRequestBody = TRouteMethod extends { requestBody: { content: { \"application/json\": any } } }\n ? TRouteMethod[\"requestBody\"][\"content\"][\"application/json\"]\n : never;\n type TAllResponses = TRouteMethod extends { responses: any } ? TRouteMethod[\"responses\"] : never;\n type TOkResponse = TAllResponses[typeof okHttpStatus] extends { content: { \"application/json\": any } }\n ? TAllResponses[typeof okHttpStatus][\"content\"][\"application/json\"]\n : never;\n const openApi = {\n [pathName]: async function ({\n headers = {},\n baseUrl = DEFAULT_BASE_URL,\n apiRoot = \"/api/v3\",\n pathParams = {},\n queryParams = {},\n requestBody,\n }: {\n baseUrl?: string;\n apiRoot?: string;\n pathParams?: TPathParams;\n queryParams?: TQueryParams;\n requestBody?: TRequestBody;\n headers?: Record<string, string>;\n }) {\n const pathWithParams: string = Object.entries(pathParams).reduce((newPath: string, [k, v]) => {\n return newPath.replace(`{${k}}`, v as string);\n }, pathName as string);\n const cleanQueryParams = JSON.parse(JSON.stringify(queryParams));\n const search = new URLSearchParams(cleanQueryParams as unknown as Record<string, string>).toString();\n const url = baseUrl + apiRoot + pathWithParams + (search && `?${search}`);\n const options = { headers, method: method as THttpMethod, body: JSON.stringify(requestBody) };\n\n return fetchJson<TOkResponse>(url, options);\n },\n };\n\n // Use object to create function with dynamic name, for better stacktraces\n return openApi[pathName];\n};\n","import { makeOpenApiMethod } from \"../make-openapi-method\";\n\nexport const getChainNonprofits = makeOpenApiMethod(\"/chain/{chainId}/nonprofits\", \"get\", 200);\n\nexport const getImpact = makeOpenApiMethod(\"/impact\", \"get\", 200);\n\nexport const getCumulativeImpact = makeOpenApiMethod(\"/chain/{chainId}/cumulativeImpact\", \"get\", 200);\n\nexport const postSelectNonprofit = makeOpenApiMethod(\"/selectNonprofit\", \"post\", 201);\n\nexport const postTransaction = makeOpenApiMethod(\"/transaction\", \"post\", 201);\n\nexport const putTransaction = makeOpenApiMethod(\"/transaction/{transactionId}\", \"put\", 204);\n\nexport const postCart = makeOpenApiMethod(\"/cart\", \"post\", 200);\n\nexport const postChainEligibleNonprofitsForCart = makeOpenApiMethod(\n \"/chain/findEligibleNonprofitsForCart\",\n \"post\",\n 200\n);\n\nexport const postLogs = makeOpenApiMethod(\"/logs\", \"post\", 200);\n\nexport const postExperimentSession = makeOpenApiMethod(\"/experimentSession\", \"post\", 200);\n\nexport const updateSubscription = makeOpenApiMethod(\"/subscriptions/updateSubscriptionNonprofit\", \"post\", 200);\n\nexport const postFindOrCreateSubscription = makeOpenApiMethod(\"/subscriptions/findOrCreateSubscription\", \"post\", 200);\n\nexport const postProductDetailsPage = makeOpenApiMethod(\"/productDetailsPage\", \"post\", 200);\n"],"names":["DEFAULT_BASE_URL","DEFAULT_LOG_URL","SUPPORTED_LANGUAGES","WIDGET_NAMES","HELPER_NAMES","LOCAL_STORAGE_KEYS","fetchJson","url","options","fetchOptions","pkgVersion","response","err","error","BeamError","logger","body","text","NetworkError","makeOpenApiMethod","pathName","method","okHttpStatus","headers","baseUrl","apiRoot","pathParams","queryParams","requestBody","pathWithParams","newPath","k","v","cleanQueryParams","search","getImpact","getCumulativeImpact","postSelectNonprofit","postCart","postChainEligibleNonprofitsForCart","postLogs","postExperimentSession","updateSubscription","postFindOrCreateSubscription","postProductDetailsPage"],"mappings":"2IAGO,MAAMA,EAAyB,6BAEzBC,EAAkB,wCAElBC,EAAiD,CAC5D,GAAI,KACJ,GAAI,KACJ,GAAI,KACJ,GAAI,KACJ,GAAI,KACJ,GAAI,KACJ,GAAI,IACN,EAEaC,EAAe,CAC1B,iBAAkB,mBAClB,mBAAoB,qBACpB,gBAAiB,kBACjB,iBAAkB,mBAClB,kBAAmB,oBACnB,qBAAsB,uBACtB,wBAAyB,0BACzB,oBAAqB,sBACrB,8BAA+B,gCAC/B,aAAc,cAChB,EAEaC,EAAe,CAC1B,YAAa,aACf,EAGaC,EAAqB,CAIhC,UAAW,YACX,sBAAuB,uBACzB,mFClCA,eAAsBC,EAAuBC,EAAkBC,EAAmC,CAChG,MAAMC,EAAe,CACnB,OAAQ,MACR,GAAGD,EACH,QAAS,CACP,eAAgB,mBAChB,OAAQ,mBACR,gBAAiB,SACjB,wBAAyBE,EACzB,GAAGF,GAAS,OACd,EACA,kBAAmB,GACnB,KAAMA,GAAS,MAAQ,OACvB,KAAMA,GAAS,MAAQ,KAAOA,EAAQ,KAAO,MAC/C,EAEA,IAAIG,EACJ,GAAI,CACFA,EAAW,MAAM,MAAMJ,EAAKE,CAAY,CAE1C,OAASG,EAAK,CACZ,MAAMC,EAAQ,IAAIC,EAAU,wBAAwBL,GAAc,OAAO,aAAa,IAAIF,CAAG,GAAG,EAChG,MAAAM,EAAM,MAAQD,EACdG,EAAO,MAAMF,EAAON,CAAG,EACjBM,CACR,CACA,IAAIG,EACAC,EAEJ,GAAI,CACFA,EAAO,MAAMN,EAAS,OAClBM,IAEFD,EAAO,KAAK,MAAMC,CAAI,EAE1B,OAASL,EAAK,CACZ,IAAIC,EAAQD,EACZ,MAAIA,aAAe,cACjBC,EAAQ,IAAIK,EAAaP,EAAUK,EAAM,+CAA+CC,CAAI,GAAG,EAC/FJ,EAAM,MAAQD,GAEhBG,EAAO,MAAMF,CAAK,EACZA,CACR,CAEA,GAAI,CAACF,EAAS,GAAI,CAChB,MAAME,EAAQ,IAAIK,EAAaP,EAAUK,EAAM,qBAAqB,EACpE,MAAAD,EAAO,MAAMF,CAAK,EACZA,CACR,CAEA,OAAOG,CACT,CCpDO,MAAMG,EAAoB,CAO/BC,EACAC,EACAC,KAcgB,CACd,CAACF,CAAQ,EAAG,eAAgB,CAC1B,QAAAG,EAAU,CAAA,EACV,QAAAC,EAAUxB,EACV,QAAAyB,EAAU,UACV,WAAAC,EAAa,CAAA,EACb,YAAAC,EAAc,CAAA,EACd,YAAAC,CACF,EAOG,CACD,MAAMC,EAAyB,OAAO,QAAQH,CAAU,EAAE,OAAO,CAACI,EAAiB,CAACC,EAAGC,CAAC,IAC/EF,EAAQ,QAAQ,IAAIC,CAAC,IAAKC,CAAW,EAC3CZ,CAAkB,EACfa,EAAmB,KAAK,MAAM,KAAK,UAAUN,CAAW,CAAC,EACzDO,EAAS,IAAI,gBAAgBD,CAAqD,EAAE,SAAA,EACpF1B,EAAMiB,EAAUC,EAAUI,GAAkBK,GAAU,IAAIA,CAAM,IAChE1B,EAAU,CAAE,QAAAe,EAAS,OAAQF,EAAuB,KAAM,KAAK,UAAUO,CAAW,CAAE,EAE5F,OAAOtB,EAAuBC,EAAKC,CAAO,CAC5C,CACF,GAGeY,CAAQ,ECzDSD,EAAkB,8BAA+B,KAAU,EAAA,MAEhFgB,EAAYhB,EAAkB,UAAW,KAAU,EAEnDiB,EAAsBjB,EAAkB,oCAAqC,KAAU,EAEvFkB,EAAsBlB,EAAkB,mBAAoB,MAAW,EAErDA,EAAkB,eAAgB,MAAW,EAE9CA,EAAkB,+BAAgC,KAAU,QAE7EmB,EAAWnB,EAAkB,QAAS,MAAW,EAEjDoB,EAAqCpB,EAChD,uCACA,MAEF,EAEaqB,EAAWrB,EAAkB,QAAS,MAAW,EAEjDsB,EAAwBtB,EAAkB,qBAAsB,MAAW,EAE3EuB,EAAqBvB,EAAkB,6CAA8C,MAAW,EAEhGwB,EAA+BxB,EAAkB,0CAA2C,MAAW,EAEvGyB,EAAyBzB,EAAkB,sBAAuB,MAAW"}
|
|
@@ -1,638 +0,0 @@
|
|
|
1
|
-
declare const getChainNonprofits: ({ headers, baseUrl, apiRoot, pathParams, queryParams, requestBody, }: {
|
|
2
|
-
baseUrl?: string | undefined;
|
|
3
|
-
apiRoot?: string | undefined;
|
|
4
|
-
pathParams?: {
|
|
5
|
-
chainId: number;
|
|
6
|
-
} | undefined;
|
|
7
|
-
queryParams?: {
|
|
8
|
-
postalCode?: string | undefined;
|
|
9
|
-
countryCode?: string | undefined;
|
|
10
|
-
storeId?: number | undefined;
|
|
11
|
-
lang?: "en" | "fr" | "de" | "es" | "it" | "pl" | "ja" | undefined;
|
|
12
|
-
widgetName: "select-nonprofit" | "redeem-transaction";
|
|
13
|
-
version: string;
|
|
14
|
-
} | undefined;
|
|
15
|
-
requestBody?: undefined;
|
|
16
|
-
headers?: Record<string, string> | undefined;
|
|
17
|
-
}) => Promise<{
|
|
18
|
-
chain: {
|
|
19
|
-
name: string;
|
|
20
|
-
logoUrl: string | null;
|
|
21
|
-
logoLockupUrl?: string | null | undefined;
|
|
22
|
-
communityImpactUrl: string | null;
|
|
23
|
-
donationTypeName: string | null;
|
|
24
|
-
matchDonationTypeName: string | null;
|
|
25
|
-
};
|
|
26
|
-
config: {
|
|
27
|
-
web: {
|
|
28
|
-
title: string;
|
|
29
|
-
description: string;
|
|
30
|
-
promoDescriptionPrefix?: string | undefined;
|
|
31
|
-
promoDescription?: string | undefined;
|
|
32
|
-
confirmButton?: string | undefined;
|
|
33
|
-
confirmedButton?: string | undefined;
|
|
34
|
-
collapsedButton?: string | undefined;
|
|
35
|
-
theme?: {
|
|
36
|
-
[key: string]: unknown;
|
|
37
|
-
} | null | undefined;
|
|
38
|
-
nonprofitSelectedHeader?: string | undefined;
|
|
39
|
-
nonprofitUnselectedHeader?: string | undefined;
|
|
40
|
-
dynamicStrings?: {
|
|
41
|
-
[key: string]: string;
|
|
42
|
-
} | null | undefined;
|
|
43
|
-
additionalStrings?: {
|
|
44
|
-
[key: string]: string;
|
|
45
|
-
} | null | undefined;
|
|
46
|
-
disableAnimation?: boolean | undefined;
|
|
47
|
-
promo?: {
|
|
48
|
-
"promo-text-long": string;
|
|
49
|
-
"promo-text-short": string;
|
|
50
|
-
"promo-cause-alt-text": string;
|
|
51
|
-
} | undefined;
|
|
52
|
-
};
|
|
53
|
-
mobileWeb?: {
|
|
54
|
-
title: string;
|
|
55
|
-
description: string;
|
|
56
|
-
nonprofitSelectedHeader?: string | undefined;
|
|
57
|
-
nonprofitUnselectedHeader?: string | undefined;
|
|
58
|
-
} | undefined;
|
|
59
|
-
mobile: {
|
|
60
|
-
title: string;
|
|
61
|
-
description: string;
|
|
62
|
-
nonprofitSelectedHeader?: string | undefined;
|
|
63
|
-
nonprofitUnselectedHeader?: string | undefined;
|
|
64
|
-
};
|
|
65
|
-
enableNonprofitDeselection?: boolean | undefined;
|
|
66
|
-
} & {
|
|
67
|
-
web?: {
|
|
68
|
-
redeemButtonText?: string | undefined;
|
|
69
|
-
} | undefined;
|
|
70
|
-
mobileWeb?: {
|
|
71
|
-
redeemButtonText?: string | undefined;
|
|
72
|
-
} | undefined;
|
|
73
|
-
mobile?: {
|
|
74
|
-
redeemButtonText?: string | undefined;
|
|
75
|
-
} | undefined;
|
|
76
|
-
};
|
|
77
|
-
nonprofits: {
|
|
78
|
-
imageUrl: Partial<string | null>;
|
|
79
|
-
nonprofit: {
|
|
80
|
-
id: number;
|
|
81
|
-
name: string;
|
|
82
|
-
cause: string | null;
|
|
83
|
-
causeIconUrl: string | null;
|
|
84
|
-
causeIconSelectedUrl: string | null;
|
|
85
|
-
causeColor: string | null;
|
|
86
|
-
extensibility?: {
|
|
87
|
-
causeIconUrl?: string | null | undefined;
|
|
88
|
-
causeIconSelectedUrl?: string | null | undefined;
|
|
89
|
-
causeIconAndBackgroundUrl?: string | null | undefined;
|
|
90
|
-
} | undefined;
|
|
91
|
-
website: string | null;
|
|
92
|
-
websiteLinkText: string;
|
|
93
|
-
badge?: string | undefined;
|
|
94
|
-
includeInPersonalImpact?: boolean | undefined;
|
|
95
|
-
};
|
|
96
|
-
impact: {
|
|
97
|
-
description: string | null;
|
|
98
|
-
goalCompletionText: string;
|
|
99
|
-
goalProgressText: string;
|
|
100
|
-
goalProgressPercentage: number;
|
|
101
|
-
};
|
|
102
|
-
promo?: {
|
|
103
|
-
type?: string | undefined;
|
|
104
|
-
isActive: boolean;
|
|
105
|
-
multiplier: number | null;
|
|
106
|
-
} | null | undefined;
|
|
107
|
-
}[];
|
|
108
|
-
store: {
|
|
109
|
-
id: number;
|
|
110
|
-
};
|
|
111
|
-
region: {
|
|
112
|
-
id: string | null;
|
|
113
|
-
};
|
|
114
|
-
promos?: {
|
|
115
|
-
validatedPromoCodes: {
|
|
116
|
-
promoCodeId: string | null;
|
|
117
|
-
promoCodeGroupId?: string | null | undefined;
|
|
118
|
-
promoId?: number | undefined;
|
|
119
|
-
validatedAt: string;
|
|
120
|
-
apply: boolean;
|
|
121
|
-
}[];
|
|
122
|
-
} | undefined;
|
|
123
|
-
extensibility?: {
|
|
124
|
-
excludeB2BOrders?: boolean | undefined;
|
|
125
|
-
} | undefined;
|
|
126
|
-
settings?: {
|
|
127
|
-
excludeDonationsForRecurringTransactions: boolean;
|
|
128
|
-
} | undefined;
|
|
129
|
-
}>;
|
|
130
|
-
declare const getImpact: ({ headers, baseUrl, apiRoot, pathParams, queryParams, requestBody, }: {
|
|
131
|
-
baseUrl?: string | undefined;
|
|
132
|
-
apiRoot?: string | undefined;
|
|
133
|
-
pathParams?: Record<string, never> | undefined;
|
|
134
|
-
queryParams?: {
|
|
135
|
-
chainId?: number | undefined;
|
|
136
|
-
storeId?: number | undefined;
|
|
137
|
-
beamUserId?: string | undefined;
|
|
138
|
-
nonprofitId?: number | undefined;
|
|
139
|
-
communityImpactLimit?: number | undefined;
|
|
140
|
-
personalImpactLimit?: number | undefined;
|
|
141
|
-
widgetName: "impact-overview" | "community-impact" | "subscription-impact" | "subscription-management";
|
|
142
|
-
version: string;
|
|
143
|
-
lang?: "en" | "fr" | "de" | "es" | "it" | "pl" | "ja" | undefined;
|
|
144
|
-
omitThemes?: boolean | undefined;
|
|
145
|
-
draftConfig?: boolean | undefined;
|
|
146
|
-
discountCodes?: string[] | undefined;
|
|
147
|
-
transactionId?: string | undefined;
|
|
148
|
-
partnerUserId?: string | undefined;
|
|
149
|
-
} | undefined;
|
|
150
|
-
requestBody?: undefined;
|
|
151
|
-
headers?: Record<string, string> | undefined;
|
|
152
|
-
}) => Promise<{
|
|
153
|
-
chain: {
|
|
154
|
-
name: string;
|
|
155
|
-
logoUrl: string | null;
|
|
156
|
-
logoLockupUrl?: string | null | undefined;
|
|
157
|
-
communityImpactUrl: string | null;
|
|
158
|
-
donationTypeName: string | null;
|
|
159
|
-
matchDonationTypeName: string | null;
|
|
160
|
-
};
|
|
161
|
-
store: {
|
|
162
|
-
name: string | null;
|
|
163
|
-
displayName: string | null;
|
|
164
|
-
communityPageURL: string | null;
|
|
165
|
-
};
|
|
166
|
-
config: {
|
|
167
|
-
web: {
|
|
168
|
-
title: string;
|
|
169
|
-
description: string;
|
|
170
|
-
promoDescriptionPrefix?: string | undefined;
|
|
171
|
-
promoDescription?: string | undefined;
|
|
172
|
-
confirmButton?: string | undefined;
|
|
173
|
-
confirmedButton?: string | undefined;
|
|
174
|
-
collapsedButton?: string | undefined;
|
|
175
|
-
theme?: {
|
|
176
|
-
[key: string]: unknown;
|
|
177
|
-
} | null | undefined;
|
|
178
|
-
nonprofitSelectedHeader?: string | undefined;
|
|
179
|
-
nonprofitUnselectedHeader?: string | undefined;
|
|
180
|
-
dynamicStrings?: {
|
|
181
|
-
[key: string]: string;
|
|
182
|
-
} | null | undefined;
|
|
183
|
-
additionalStrings?: {
|
|
184
|
-
[key: string]: string;
|
|
185
|
-
} | null | undefined;
|
|
186
|
-
disableAnimation?: boolean | undefined;
|
|
187
|
-
promo?: {
|
|
188
|
-
"promo-text-long": string;
|
|
189
|
-
"promo-text-short": string;
|
|
190
|
-
"promo-cause-alt-text": string;
|
|
191
|
-
} | undefined;
|
|
192
|
-
};
|
|
193
|
-
mobileWeb?: {
|
|
194
|
-
title: string;
|
|
195
|
-
description: string;
|
|
196
|
-
nonprofitSelectedHeader?: string | undefined;
|
|
197
|
-
nonprofitUnselectedHeader?: string | undefined;
|
|
198
|
-
} | undefined;
|
|
199
|
-
mobile: {
|
|
200
|
-
title: string;
|
|
201
|
-
description: string;
|
|
202
|
-
nonprofitSelectedHeader?: string | undefined;
|
|
203
|
-
nonprofitUnselectedHeader?: string | undefined;
|
|
204
|
-
};
|
|
205
|
-
enableNonprofitDeselection?: boolean | undefined;
|
|
206
|
-
};
|
|
207
|
-
personal: {
|
|
208
|
-
imageUrl: string | null;
|
|
209
|
-
nonprofit: {
|
|
210
|
-
id: number;
|
|
211
|
-
name: string;
|
|
212
|
-
cause: string | null;
|
|
213
|
-
causeIconUrl: string | null;
|
|
214
|
-
causeIconSelectedUrl: string | null;
|
|
215
|
-
causeColor: string | null;
|
|
216
|
-
extensibility?: {
|
|
217
|
-
causeIconUrl?: string | null | undefined;
|
|
218
|
-
causeIconSelectedUrl?: string | null | undefined;
|
|
219
|
-
causeIconAndBackgroundUrl?: string | null | undefined;
|
|
220
|
-
} | undefined;
|
|
221
|
-
website: string | null;
|
|
222
|
-
websiteLinkText: string;
|
|
223
|
-
badge?: string | undefined;
|
|
224
|
-
includeInPersonalImpact?: boolean | undefined;
|
|
225
|
-
};
|
|
226
|
-
impact: {
|
|
227
|
-
description: string | null;
|
|
228
|
-
goalCompletionText: string;
|
|
229
|
-
goalProgressText: string;
|
|
230
|
-
goalProgressPercentage: number;
|
|
231
|
-
};
|
|
232
|
-
share: {
|
|
233
|
-
imageUrl: string | null;
|
|
234
|
-
};
|
|
235
|
-
filters?: string[] | undefined;
|
|
236
|
-
}[];
|
|
237
|
-
community: {
|
|
238
|
-
imageUrl: string | null;
|
|
239
|
-
nonprofit: {
|
|
240
|
-
id: number;
|
|
241
|
-
name: string;
|
|
242
|
-
cause: string | null;
|
|
243
|
-
causeIconUrl: string | null;
|
|
244
|
-
causeIconSelectedUrl: string | null;
|
|
245
|
-
causeColor: string | null;
|
|
246
|
-
extensibility?: {
|
|
247
|
-
causeIconUrl?: string | null | undefined;
|
|
248
|
-
causeIconSelectedUrl?: string | null | undefined;
|
|
249
|
-
causeIconAndBackgroundUrl?: string | null | undefined;
|
|
250
|
-
} | undefined;
|
|
251
|
-
website: string | null;
|
|
252
|
-
websiteLinkText: string;
|
|
253
|
-
badge?: string | undefined;
|
|
254
|
-
includeInPersonalImpact?: boolean | undefined;
|
|
255
|
-
};
|
|
256
|
-
impact: {
|
|
257
|
-
description: string | null;
|
|
258
|
-
goalCompletionText: string;
|
|
259
|
-
goalProgressText: string;
|
|
260
|
-
goalProgressPercentage: number;
|
|
261
|
-
};
|
|
262
|
-
share: {
|
|
263
|
-
imageUrl: string | null;
|
|
264
|
-
};
|
|
265
|
-
filters?: string[] | undefined;
|
|
266
|
-
}[];
|
|
267
|
-
promo: {
|
|
268
|
-
type?: string | undefined;
|
|
269
|
-
isActive: boolean;
|
|
270
|
-
multiplier: number | null;
|
|
271
|
-
} | null;
|
|
272
|
-
promoAssetUrl: string | null;
|
|
273
|
-
personalImpactAssetUrl: string | null;
|
|
274
|
-
settings?: {
|
|
275
|
-
excludeDonationsForRecurringTransactions: boolean;
|
|
276
|
-
} | undefined;
|
|
277
|
-
}>;
|
|
278
|
-
declare const postTransaction: ({ headers, baseUrl, apiRoot, pathParams, queryParams, requestBody, }: {
|
|
279
|
-
baseUrl?: string | undefined;
|
|
280
|
-
apiRoot?: string | undefined;
|
|
281
|
-
pathParams?: undefined;
|
|
282
|
-
queryParams?: undefined;
|
|
283
|
-
requestBody?: {
|
|
284
|
-
orderId: string | number;
|
|
285
|
-
storeId?: number | undefined;
|
|
286
|
-
selectionId?: string | undefined;
|
|
287
|
-
beamCartId?: string | undefined;
|
|
288
|
-
cartId?: string | undefined;
|
|
289
|
-
nonprofitId?: number | null | undefined;
|
|
290
|
-
beamUserId?: string | undefined;
|
|
291
|
-
email?: string | undefined;
|
|
292
|
-
partnerUserId?: string | undefined;
|
|
293
|
-
currencyCode: string;
|
|
294
|
-
defaultToLastNonprofit?: boolean | undefined;
|
|
295
|
-
postalCode?: string | undefined;
|
|
296
|
-
countryCode?: string | undefined;
|
|
297
|
-
cart?: {
|
|
298
|
-
schema: {
|
|
299
|
-
source: "shopify";
|
|
300
|
-
variant: "ajax";
|
|
301
|
-
version?: string | undefined;
|
|
302
|
-
};
|
|
303
|
-
content: {
|
|
304
|
-
localAmount?: number | undefined;
|
|
305
|
-
discounts?: {
|
|
306
|
-
code: string;
|
|
307
|
-
applicable: boolean;
|
|
308
|
-
}[] | null | undefined;
|
|
309
|
-
items: {
|
|
310
|
-
id?: number | null | undefined;
|
|
311
|
-
gift_card?: boolean | null | undefined;
|
|
312
|
-
final_line_price: number | null;
|
|
313
|
-
final_price?: number | null | undefined;
|
|
314
|
-
line_level_discount_applications?: ({
|
|
315
|
-
title: string;
|
|
316
|
-
} & {
|
|
317
|
-
[key: string]: unknown;
|
|
318
|
-
})[] | null | undefined;
|
|
319
|
-
quantity?: number | null | undefined;
|
|
320
|
-
sku: string | null;
|
|
321
|
-
product_id?: number | null | undefined;
|
|
322
|
-
product_title?: string | null | undefined;
|
|
323
|
-
product_type?: string | null | undefined;
|
|
324
|
-
variant_id?: number | null | undefined;
|
|
325
|
-
}[];
|
|
326
|
-
subscriptions?: {
|
|
327
|
-
remoteSubscriptionId: string;
|
|
328
|
-
isNew?: boolean | undefined;
|
|
329
|
-
}[] | undefined;
|
|
330
|
-
};
|
|
331
|
-
} | {
|
|
332
|
-
schema: {
|
|
333
|
-
source: "shopify";
|
|
334
|
-
variant: "liquid";
|
|
335
|
-
version?: string | undefined;
|
|
336
|
-
};
|
|
337
|
-
content: {
|
|
338
|
-
localAmount?: number | undefined;
|
|
339
|
-
discounts?: {
|
|
340
|
-
code: string;
|
|
341
|
-
applicable: boolean;
|
|
342
|
-
}[] | null | undefined;
|
|
343
|
-
items: {
|
|
344
|
-
id?: number | null | undefined;
|
|
345
|
-
gift_card?: boolean | null | undefined;
|
|
346
|
-
final_line_price: number | null;
|
|
347
|
-
final_price?: number | null | undefined;
|
|
348
|
-
line_level_discount_applications?: ({
|
|
349
|
-
title: string;
|
|
350
|
-
} & {
|
|
351
|
-
[key: string]: unknown;
|
|
352
|
-
})[] | null | undefined;
|
|
353
|
-
quantity?: number | null | undefined;
|
|
354
|
-
sku: string | null;
|
|
355
|
-
product_id?: number | null | undefined;
|
|
356
|
-
variant_id?: number | null | undefined;
|
|
357
|
-
}[];
|
|
358
|
-
subscriptions?: {
|
|
359
|
-
remoteSubscriptionId: string;
|
|
360
|
-
isNew?: boolean | undefined;
|
|
361
|
-
}[] | undefined;
|
|
362
|
-
};
|
|
363
|
-
} | {
|
|
364
|
-
schema: {
|
|
365
|
-
source: "generic";
|
|
366
|
-
variant?: "default" | undefined;
|
|
367
|
-
version?: string | undefined;
|
|
368
|
-
};
|
|
369
|
-
content: {
|
|
370
|
-
localAmount?: number | undefined;
|
|
371
|
-
discounts?: {
|
|
372
|
-
code: string;
|
|
373
|
-
applicable: boolean;
|
|
374
|
-
}[] | null | undefined;
|
|
375
|
-
items: {
|
|
376
|
-
remoteProductIdentifier?: string | null | undefined;
|
|
377
|
-
localAmount: number;
|
|
378
|
-
remoteSubscriptionId?: string | undefined;
|
|
379
|
-
discounts?: {
|
|
380
|
-
code: string;
|
|
381
|
-
applicable: boolean;
|
|
382
|
-
}[] | null | undefined;
|
|
383
|
-
}[];
|
|
384
|
-
subscriptions?: {
|
|
385
|
-
remoteSubscriptionId: string;
|
|
386
|
-
isNew?: boolean | undefined;
|
|
387
|
-
}[] | undefined;
|
|
388
|
-
};
|
|
389
|
-
} | undefined;
|
|
390
|
-
remoteSessionId?: string | undefined;
|
|
391
|
-
options?: {
|
|
392
|
-
config?: {
|
|
393
|
-
omitThemes?: boolean | undefined;
|
|
394
|
-
draftConfig?: boolean | undefined;
|
|
395
|
-
} | undefined;
|
|
396
|
-
response?: {
|
|
397
|
-
personalImpact?: boolean | undefined;
|
|
398
|
-
communityImpact?: boolean | undefined;
|
|
399
|
-
} | undefined;
|
|
400
|
-
} | undefined;
|
|
401
|
-
widgetName?: "select-nonprofit" | "redeem-transaction" | "select-nonprofit-cta" | undefined;
|
|
402
|
-
version?: string | undefined;
|
|
403
|
-
donation?: {
|
|
404
|
-
currencyCode: string;
|
|
405
|
-
amount: number;
|
|
406
|
-
} | undefined;
|
|
407
|
-
cartTotal?: number | undefined;
|
|
408
|
-
discountCodes?: string[] | undefined;
|
|
409
|
-
creationMethod?: "recurring" | null | undefined;
|
|
410
|
-
promos?: {
|
|
411
|
-
unvalidatedPromoCodes: (Partial<{
|
|
412
|
-
type?: "manual" | "url" | undefined;
|
|
413
|
-
} & {
|
|
414
|
-
attributes?: {
|
|
415
|
-
value?: string | undefined;
|
|
416
|
-
} | undefined;
|
|
417
|
-
}> & Partial<{
|
|
418
|
-
type?: "manual" | "url" | undefined;
|
|
419
|
-
} & {
|
|
420
|
-
attributes?: {
|
|
421
|
-
url?: string | undefined;
|
|
422
|
-
} | undefined;
|
|
423
|
-
}>)[];
|
|
424
|
-
validatedPromoCodes: {
|
|
425
|
-
promoCodeId: string | null;
|
|
426
|
-
promoCodeGroupId?: string | null | undefined;
|
|
427
|
-
promoId?: number | undefined;
|
|
428
|
-
validatedAt: string;
|
|
429
|
-
apply: boolean;
|
|
430
|
-
}[];
|
|
431
|
-
} | undefined;
|
|
432
|
-
} | undefined;
|
|
433
|
-
headers?: Record<string, string> | undefined;
|
|
434
|
-
}) => Promise<{
|
|
435
|
-
transactionId: string;
|
|
436
|
-
transactionCreated?: boolean | undefined;
|
|
437
|
-
beamUserId: string;
|
|
438
|
-
beamCartId?: string | null | undefined;
|
|
439
|
-
chainId: number;
|
|
440
|
-
nonprofitId: number | null;
|
|
441
|
-
creationMethod?: string | undefined;
|
|
442
|
-
impact?: {
|
|
443
|
-
personal?: {
|
|
444
|
-
imageUrl: string | null;
|
|
445
|
-
nonprofit: {
|
|
446
|
-
id: number;
|
|
447
|
-
name: string;
|
|
448
|
-
cause: string | null;
|
|
449
|
-
causeIconUrl: string | null;
|
|
450
|
-
causeIconSelectedUrl: string | null;
|
|
451
|
-
causeColor: string | null;
|
|
452
|
-
extensibility?: {
|
|
453
|
-
causeIconUrl?: string | null | undefined;
|
|
454
|
-
causeIconSelectedUrl?: string | null | undefined;
|
|
455
|
-
causeIconAndBackgroundUrl?: string | null | undefined;
|
|
456
|
-
} | undefined;
|
|
457
|
-
website: string | null;
|
|
458
|
-
websiteLinkText: string;
|
|
459
|
-
badge?: string | undefined;
|
|
460
|
-
includeInPersonalImpact?: boolean | undefined;
|
|
461
|
-
};
|
|
462
|
-
impact: {
|
|
463
|
-
description: string | null;
|
|
464
|
-
goalCompletionText: string;
|
|
465
|
-
goalProgressText: string;
|
|
466
|
-
goalProgressPercentage: number;
|
|
467
|
-
};
|
|
468
|
-
share: {
|
|
469
|
-
imageUrl: string | null;
|
|
470
|
-
};
|
|
471
|
-
filters?: string[] | undefined;
|
|
472
|
-
}[] | undefined;
|
|
473
|
-
community?: {
|
|
474
|
-
imageUrl: string | null;
|
|
475
|
-
nonprofit: {
|
|
476
|
-
id: number;
|
|
477
|
-
name: string;
|
|
478
|
-
cause: string | null;
|
|
479
|
-
causeIconUrl: string | null;
|
|
480
|
-
causeIconSelectedUrl: string | null;
|
|
481
|
-
causeColor: string | null;
|
|
482
|
-
extensibility?: {
|
|
483
|
-
causeIconUrl?: string | null | undefined;
|
|
484
|
-
causeIconSelectedUrl?: string | null | undefined;
|
|
485
|
-
causeIconAndBackgroundUrl?: string | null | undefined;
|
|
486
|
-
} | undefined;
|
|
487
|
-
website: string | null;
|
|
488
|
-
websiteLinkText: string;
|
|
489
|
-
badge?: string | undefined;
|
|
490
|
-
includeInPersonalImpact?: boolean | undefined;
|
|
491
|
-
};
|
|
492
|
-
impact: {
|
|
493
|
-
description: string | null;
|
|
494
|
-
goalCompletionText: string;
|
|
495
|
-
goalProgressText: string;
|
|
496
|
-
goalProgressPercentage: number;
|
|
497
|
-
};
|
|
498
|
-
share: {
|
|
499
|
-
imageUrl: string | null;
|
|
500
|
-
};
|
|
501
|
-
filters?: string[] | undefined;
|
|
502
|
-
}[] | undefined;
|
|
503
|
-
} | undefined;
|
|
504
|
-
config?: {
|
|
505
|
-
mobile?: {
|
|
506
|
-
title?: unknown;
|
|
507
|
-
description?: string | undefined;
|
|
508
|
-
theme?: {
|
|
509
|
-
[key: string]: unknown;
|
|
510
|
-
} | null | undefined;
|
|
511
|
-
} | undefined;
|
|
512
|
-
mobileWeb?: {
|
|
513
|
-
title?: unknown;
|
|
514
|
-
description?: string | undefined;
|
|
515
|
-
theme?: {
|
|
516
|
-
[key: string]: unknown;
|
|
517
|
-
} | null | undefined;
|
|
518
|
-
} | undefined;
|
|
519
|
-
web?: {
|
|
520
|
-
title?: string | undefined;
|
|
521
|
-
description?: string | undefined;
|
|
522
|
-
theme?: {
|
|
523
|
-
[key: string]: unknown;
|
|
524
|
-
} | null | undefined;
|
|
525
|
-
} | undefined;
|
|
526
|
-
} | undefined;
|
|
527
|
-
extensibility?: {
|
|
528
|
-
excludeB2BOrders?: boolean | undefined;
|
|
529
|
-
} | undefined;
|
|
530
|
-
reportSettings?: {
|
|
531
|
-
excludeRecurringDonations?: boolean | undefined;
|
|
532
|
-
} | undefined;
|
|
533
|
-
}>;
|
|
534
|
-
declare const postProductDetailsPage: ({ headers, baseUrl, apiRoot, pathParams, queryParams, requestBody, }: {
|
|
535
|
-
baseUrl?: string | undefined;
|
|
536
|
-
apiRoot?: string | undefined;
|
|
537
|
-
pathParams?: Record<string, never> | undefined;
|
|
538
|
-
queryParams?: {
|
|
539
|
-
lang?: "en" | "fr" | "de" | "es" | "it" | "pl" | "ja" | undefined;
|
|
540
|
-
version: string;
|
|
541
|
-
storeId: number;
|
|
542
|
-
draftConfig?: boolean | undefined;
|
|
543
|
-
widgetName?: "impact-overview" | "community-impact" | "subscription-impact" | "subscription-management" | "select-nonprofit" | "redeem-transaction" | "cumulative-impact" | "product-details-page" | "select-subscription-nonprofit" | "select-nonprofit-cta" | "mobile-full-screen-nonprofit-selection" | "mobile-impact-list" | "mobile-minimal-nonprofit-selection" | "mobile-personal-impact" | "mobile-selected-nonprofit" | "mobile-progress-bar" | "mobile-share-button" | undefined;
|
|
544
|
-
remoteProductIdentifier?: string | undefined;
|
|
545
|
-
} | undefined;
|
|
546
|
-
requestBody?: {
|
|
547
|
-
lang?: string | undefined;
|
|
548
|
-
version?: string | undefined;
|
|
549
|
-
storeId?: number | undefined;
|
|
550
|
-
widgetName?: string | undefined;
|
|
551
|
-
remoteProductIdentifier?: string | undefined;
|
|
552
|
-
beamCartId?: string | undefined;
|
|
553
|
-
draftConfig?: boolean | undefined;
|
|
554
|
-
promos?: {
|
|
555
|
-
unvalidatedPromoCodes: (Partial<{
|
|
556
|
-
type?: "manual" | "url" | undefined;
|
|
557
|
-
} & {
|
|
558
|
-
attributes?: {
|
|
559
|
-
value?: string | undefined;
|
|
560
|
-
} | undefined;
|
|
561
|
-
}> & Partial<{
|
|
562
|
-
type?: "manual" | "url" | undefined;
|
|
563
|
-
} & {
|
|
564
|
-
attributes?: {
|
|
565
|
-
url?: string | undefined;
|
|
566
|
-
} | undefined;
|
|
567
|
-
}>)[];
|
|
568
|
-
validatedPromoCodes: {
|
|
569
|
-
promoCodeId: string | null;
|
|
570
|
-
promoCodeGroupId?: string | null | undefined;
|
|
571
|
-
promoId?: number | undefined;
|
|
572
|
-
validatedAt: string;
|
|
573
|
-
apply: boolean;
|
|
574
|
-
}[];
|
|
575
|
-
} | undefined;
|
|
576
|
-
} | undefined;
|
|
577
|
-
headers?: Record<string, string> | undefined;
|
|
578
|
-
}) => Promise<{
|
|
579
|
-
config: {
|
|
580
|
-
web: {
|
|
581
|
-
title: string;
|
|
582
|
-
description: string;
|
|
583
|
-
promoDescriptionPrefix?: string | undefined;
|
|
584
|
-
promoDescription?: string | undefined;
|
|
585
|
-
confirmButton?: string | undefined;
|
|
586
|
-
confirmedButton?: string | undefined;
|
|
587
|
-
collapsedButton?: string | undefined;
|
|
588
|
-
theme?: {
|
|
589
|
-
[key: string]: unknown;
|
|
590
|
-
} | null | undefined;
|
|
591
|
-
nonprofitSelectedHeader?: string | undefined;
|
|
592
|
-
nonprofitUnselectedHeader?: string | undefined;
|
|
593
|
-
dynamicStrings?: {
|
|
594
|
-
[key: string]: string;
|
|
595
|
-
} | null | undefined;
|
|
596
|
-
additionalStrings?: {
|
|
597
|
-
[key: string]: string;
|
|
598
|
-
} | null | undefined;
|
|
599
|
-
disableAnimation?: boolean | undefined;
|
|
600
|
-
promo?: {
|
|
601
|
-
"promo-text-long": string;
|
|
602
|
-
"promo-text-short": string;
|
|
603
|
-
"promo-cause-alt-text": string;
|
|
604
|
-
} | undefined;
|
|
605
|
-
};
|
|
606
|
-
mobileWeb?: {
|
|
607
|
-
title: string;
|
|
608
|
-
description: string;
|
|
609
|
-
nonprofitSelectedHeader?: string | undefined;
|
|
610
|
-
nonprofitUnselectedHeader?: string | undefined;
|
|
611
|
-
} | undefined;
|
|
612
|
-
mobile: {
|
|
613
|
-
title: string;
|
|
614
|
-
description: string;
|
|
615
|
-
nonprofitSelectedHeader?: string | undefined;
|
|
616
|
-
nonprofitUnselectedHeader?: string | undefined;
|
|
617
|
-
};
|
|
618
|
-
enableNonprofitDeselection?: boolean | undefined;
|
|
619
|
-
};
|
|
620
|
-
ppgfDisclosure?: {
|
|
621
|
-
copy: string;
|
|
622
|
-
} | undefined;
|
|
623
|
-
ppgfDisclosureHyperlink?: {
|
|
624
|
-
url: string;
|
|
625
|
-
copy: string;
|
|
626
|
-
} | undefined;
|
|
627
|
-
promos?: {
|
|
628
|
-
validatedPromoCodes?: {
|
|
629
|
-
promoCodeId: string | null;
|
|
630
|
-
promoCodeGroupId?: string | null | undefined;
|
|
631
|
-
promoId?: number | undefined;
|
|
632
|
-
validatedAt: string;
|
|
633
|
-
apply: boolean;
|
|
634
|
-
}[] | undefined;
|
|
635
|
-
} | undefined;
|
|
636
|
-
}>;
|
|
637
|
-
|
|
638
|
-
export { getImpact as a, postTransaction as b, getChainNonprofits as g, postProductDetailsPage as p };
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import"./promo-types-DKAOFHJr.esm.js";import{B as y,N as d}from"./beam-errors-Ci0d3926.esm.js";import{logger as p}from"../utils/logger.esm.js";const l="https://api.beamimpact.com",O="https://production.beamimpactlogs.com",v={en:"en",fr:"fr",de:"de",es:"es",it:"it",pl:"pl",ja:"ja"},w={select_nonprofit:"select-nonprofit",redeem_transaction:"redeem-transaction",impact_overview:"impact-overview",community_impact:"community-impact",cumulative_impact:"cumulative-impact",product_details_page:"product-details-page",subscription_management:"subscription-management",subscription_impact:"subscription-impact",select_subscription_nonprofit:"select-subscription-nonprofit",social_share:"social-share"},C={cart_update:"cart_update"},L={NONPROFIT:"nonprofit",NONPROFIT_SELECTED_AT:"nonprofit_selected_at"};var A="1.55.8",R={"@shoelace-style/shoelace":"2.15.0","lucide-static":"0.292.0"};async function u(o,s){const c={method:"GET",...s,headers:{"Content-Type":"application/json",Accept:"application/json","X-Beam-Client":"WebSDK","X-Beam-Client-Version":A,...s?.headers},preflightContinue:!0,mode:s?.mode||"cors",body:s?.body!=null?s.body:void 0};let i;try{i=await fetch(o,c)}catch(e){const a=new y(`Network call failed (${c?.method.toUpperCase()} ${o})`);throw a.cause=e,p.error(a,o),a}let r,n;try{n=await i.text(),n&&(r=JSON.parse(n))}catch(e){let a=e;throw e instanceof SyntaxError&&(a=new d(i,r,`Response invalid. Expected JSON. Received: "${n}"`),a.cause=e),p.error(a),a}if(!i.ok){const e=new d(i,r,"Response was not OK");throw p.error(e),e}return r}const t=(o,s,c)=>({[o]:async function({headers:i={},baseUrl:r=l,apiRoot:n="/api/v3",pathParams:e={},queryParams:a={},requestBody:h}){const f=Object.entries(e).reduce((g,[E,N])=>g.replace(`{${E}}`,N),o),_=JSON.parse(JSON.stringify(a)),m=new URLSearchParams(_).toString(),S=r+n+f+(m&&`?${m}`),b={headers:i,method:s,body:JSON.stringify(h)};return u(S,b)}})[o];t("/chain/{chainId}/nonprofits","get");const T=t("/impact","get"),P=t("/chain/{chainId}/cumulativeImpact","get"),D=t("/selectNonprofit","post");t("/transaction","post"),t("/transaction/{transactionId}","put");const I=t("/cart","post"),U=t("/chain/findEligibleNonprofitsForCart","post"),F=t("/logs","post"),j=t("/experimentSession","post"),x=t("/subscriptions/updateSubscriptionNonprofit","post"),B=t("/subscriptions/findOrCreateSubscription","post"),G=t("/productDetailsPage","post");export{l as D,C as H,L,v as S,w as W,O as a,F as b,j as c,U as d,B as e,u as f,T as g,D as h,P as i,G as j,R as k,t as m,I as p,x as u};
|
|
2
|
-
//# sourceMappingURL=routes-DguZveS3.esm.js.map
|