@beamimpact/web-sdk 1.50.1 → 1.52.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (352) hide show
  1. package/dist/chunks/_share-dialog-dependencies-BwdvNwrJ.esm.js +2 -0
  2. package/dist/chunks/_share-dialog-dependencies-BwdvNwrJ.esm.js.map +1 -0
  3. package/dist/chunks/_share-dialog-dependencies-QaTONkKb.esm.js +2 -0
  4. package/dist/chunks/_share-dialog-dependencies-QaTONkKb.esm.js.map +1 -0
  5. package/dist/chunks/{beam-errors-AMvTvR1C.esm.js → beam-errors-Ci0d3926.esm.js} +1 -1
  6. package/dist/chunks/{beam-errors-AMvTvR1C.esm.js.map → beam-errors-Ci0d3926.esm.js.map} +1 -1
  7. package/dist/chunks/{cart-contents-6_ztOjrx.esm.d.ts → cart-contents-CUgc4y1N.esm.d.ts} +1 -1
  8. package/dist/chunks/cart-contents-DkoytiZh.esm.js +2 -0
  9. package/dist/chunks/{cart-contents-h60geKWa.esm.js.map → cart-contents-DkoytiZh.esm.js.map} +1 -1
  10. package/dist/chunks/{css-card-grid-nEc--M5M.esm.js → css-card-grid-CvoGpsJH.esm.js} +2 -2
  11. package/dist/chunks/{css-card-grid-nEc--M5M.esm.js.map → css-card-grid-CvoGpsJH.esm.js.map} +1 -1
  12. package/dist/chunks/enforce-config-Ba1JkOHs.esm.js +3 -0
  13. package/dist/chunks/{enforce-config-S8EGgEnO.esm.js.map → enforce-config-Ba1JkOHs.esm.js.map} +1 -1
  14. package/dist/chunks/enforce-config-CZ3ToOgr.esm.js +3 -0
  15. package/dist/chunks/{enforce-config-l-tNb_z7.esm.js.map → enforce-config-CZ3ToOgr.esm.js.map} +1 -1
  16. package/dist/chunks/{events-u_8n2LIU.esm.d.ts → events-BKkf9u9l.esm.d.ts} +3 -3
  17. package/dist/chunks/{events-T3hYV1LF.esm.js → events-BohmT6Lp.esm.js} +2 -2
  18. package/dist/chunks/{events-T3hYV1LF.esm.js.map → events-BohmT6Lp.esm.js.map} +1 -1
  19. package/dist/chunks/index-B5vRxWI3.esm.js +2 -0
  20. package/dist/chunks/index-B5vRxWI3.esm.js.map +1 -0
  21. package/dist/chunks/{index-JDZQClkA.esm.js → index-BNjsFEGn.esm.js} +2 -2
  22. package/dist/chunks/{index-JDZQClkA.esm.js.map → index-BNjsFEGn.esm.js.map} +1 -1
  23. package/dist/chunks/{index-bhqIqVQJ.esm.d.ts → index-BqBEii8E.esm.d.ts} +1 -1
  24. package/dist/chunks/index-BsuCVFh-.esm.js +2 -0
  25. package/dist/chunks/index-BsuCVFh-.esm.js.map +1 -0
  26. package/dist/chunks/{index-dLnZQZlT.esm.js → index-C-beNpP0.esm.js} +2 -2
  27. package/dist/chunks/index-C-beNpP0.esm.js.map +1 -0
  28. package/dist/chunks/{index-E8H5A7Qq.esm.js → index-C3hpHWh1.esm.js} +1 -1
  29. package/dist/chunks/index-C3hpHWh1.esm.js.map +1 -0
  30. package/dist/chunks/index-C9SnlT_2.esm.js +2 -0
  31. package/dist/chunks/index-C9SnlT_2.esm.js.map +1 -0
  32. package/dist/chunks/index-CFZqe2Wn.esm.js +2 -0
  33. package/dist/chunks/index-CFZqe2Wn.esm.js.map +1 -0
  34. package/dist/chunks/{index-FQExZDX9.esm.js → index-CFtmDAHb.esm.js} +1 -1
  35. package/dist/chunks/index-CFtmDAHb.esm.js.map +1 -0
  36. package/dist/chunks/index-CTt5RnKY.esm.js +2 -0
  37. package/dist/chunks/index-CTt5RnKY.esm.js.map +1 -0
  38. package/dist/chunks/{index-0X3JKFYs.esm.d.ts → index-CbKkAM6h.esm.d.ts} +1 -1
  39. package/dist/chunks/{index-f7fp9odj.esm.js → index-CbWdmBet.esm.js} +2 -2
  40. package/dist/chunks/index-CbWdmBet.esm.js.map +1 -0
  41. package/dist/chunks/{index-XCMf22lv.esm.js → index-D6qJfs7_.esm.js} +1 -1
  42. package/dist/chunks/index-D6qJfs7_.esm.js.map +1 -0
  43. package/dist/chunks/{index-XPlAZw7t.esm.js → index-DElVAjg2.esm.js} +2 -2
  44. package/dist/chunks/{index-XPlAZw7t.esm.js.map → index-DElVAjg2.esm.js.map} +1 -1
  45. package/dist/chunks/{index-HVGMpZIV.esm.js → index-DTGB86pM.esm.js} +2 -2
  46. package/dist/chunks/{index-HVGMpZIV.esm.js.map → index-DTGB86pM.esm.js.map} +1 -1
  47. package/dist/chunks/index-DZt3Lbb4.esm.js +2 -0
  48. package/dist/chunks/index-DZt3Lbb4.esm.js.map +1 -0
  49. package/dist/chunks/{index-kFulvjM4.esm.js → index-DhtZDPvk.esm.js} +2 -2
  50. package/dist/chunks/index-DhtZDPvk.esm.js.map +1 -0
  51. package/dist/chunks/{index-q2vZ79t1.esm.d.ts → index-Dnm34FcO.esm.d.ts} +2 -2
  52. package/dist/chunks/{index-puZGYsUA.esm.d.ts → index-DvbUE31b.esm.d.ts} +2 -2
  53. package/dist/chunks/{index-m1LRybiJ.esm.js → index-GcpuX_TZ.esm.js} +2 -2
  54. package/dist/chunks/index-GcpuX_TZ.esm.js.map +1 -0
  55. package/dist/chunks/{index-eXilYHHK.esm.js → index-IKiJwo5v.esm.js} +2 -2
  56. package/dist/chunks/{index-eXilYHHK.esm.js.map → index-IKiJwo5v.esm.js.map} +1 -1
  57. package/dist/chunks/{index-cznI-EZa.esm.d.ts → index-TAxKoTC1.esm.d.ts} +4 -2
  58. package/dist/chunks/index-ki8pLX6n.esm.d.ts +15 -0
  59. package/dist/chunks/{index-PiMq5a49.esm.js → index-oGObXjk6.esm.js} +1 -1
  60. package/dist/chunks/index-oGObXjk6.esm.js.map +1 -0
  61. package/dist/chunks/{is-all-html-elements-SdSkxirh.esm.js → is-all-html-elements-fcB7UUA1.esm.js} +1 -1
  62. package/dist/chunks/{is-all-html-elements-SdSkxirh.esm.js.map → is-all-html-elements-fcB7UUA1.esm.js.map} +1 -1
  63. package/dist/chunks/lit-WqMxC_PA.esm.js +34 -0
  64. package/dist/chunks/lit-WqMxC_PA.esm.js.map +1 -0
  65. package/dist/chunks/loading-template-DG4lkIIc.esm.js +2 -0
  66. package/dist/chunks/{loading-template-t4fFsYtr.esm.js.map → loading-template-DG4lkIIc.esm.js.map} +1 -1
  67. package/dist/chunks/{localize-7sMSg1W9.esm.js → localize-Btu9xYcE.esm.js} +6 -6
  68. package/dist/chunks/{localize-7sMSg1W9.esm.js.map → localize-Btu9xYcE.esm.js.map} +1 -1
  69. package/dist/chunks/{localize-OiRewTgu.esm.js → localize-C25pEGnx.esm.js} +6 -6
  70. package/dist/chunks/{localize-OiRewTgu.esm.js.map → localize-C25pEGnx.esm.js.map} +1 -1
  71. package/dist/chunks/lodash-7H4x2457.esm.js +2 -0
  72. package/dist/chunks/lodash-7H4x2457.esm.js.map +1 -0
  73. package/dist/chunks/order-page-BbrDKYmJ.esm.js +2 -0
  74. package/dist/chunks/order-page-BbrDKYmJ.esm.js.map +1 -0
  75. package/dist/chunks/{order-page-dlXIs0gJ.esm.d.ts → order-page-Cerye00Q.esm.d.ts} +19 -7
  76. package/dist/chunks/order-page-stMlaqKK.esm.js +2 -0
  77. package/dist/chunks/order-page-stMlaqKK.esm.js.map +1 -0
  78. package/dist/chunks/{progress-bar-PMU_xI3L.esm.js → progress-bar-DF7UuuHb.esm.js} +4 -4
  79. package/dist/chunks/{progress-bar-PMU_xI3L.esm.js.map → progress-bar-DF7UuuHb.esm.js.map} +1 -1
  80. package/dist/chunks/promo-pill-label-CbW_Vcru.esm.js +16 -0
  81. package/dist/chunks/{promo-pill-label-P1X4xeAx.esm.js.map → promo-pill-label-CbW_Vcru.esm.js.map} +1 -1
  82. package/dist/chunks/{promo-types-aQ_hre6t.esm.d.ts → promo-types-C1unMpo2.esm.d.ts} +1 -1
  83. package/dist/chunks/{promoManager--3WXq4at.esm.js → promoManager-B9cTR1R3.esm.js} +2 -2
  84. package/dist/chunks/{promoManager--3WXq4at.esm.js.map → promoManager-B9cTR1R3.esm.js.map} +1 -1
  85. package/dist/chunks/{promoManager-YUzbMtwY.esm.js → promoManager-fl54hq13.esm.js} +2 -2
  86. package/dist/chunks/{promoManager-YUzbMtwY.esm.js.map → promoManager-fl54hq13.esm.js.map} +1 -1
  87. package/dist/chunks/{responsive-2lC2Wrtg.esm.js → responsive-BR8qUfBa.esm.js} +2 -2
  88. package/dist/chunks/{responsive-2lC2Wrtg.esm.js.map → responsive-BR8qUfBa.esm.js.map} +1 -1
  89. package/dist/chunks/routes-CAhDCFDX.esm.js +2 -0
  90. package/dist/chunks/{routes-o-phF_L1.esm.js.map → routes-CAhDCFDX.esm.js.map} +1 -1
  91. package/dist/chunks/routes-pcL-CUiQ.esm.js +2 -0
  92. package/dist/chunks/{routes-YPOoVIR2.esm.js.map → routes-pcL-CUiQ.esm.js.map} +1 -1
  93. package/dist/chunks/{share-button-hDn8fnBI.esm.d.ts → share-button-B9hpxBVr.esm.d.ts} +6 -1
  94. package/dist/chunks/share-button-BYVId0-U.esm.js +2 -0
  95. package/dist/chunks/share-button-BYVId0-U.esm.js.map +1 -0
  96. package/dist/chunks/share-button-BvUcpOcx.esm.js +167 -0
  97. package/dist/chunks/share-button-BvUcpOcx.esm.js.map +1 -0
  98. package/dist/chunks/share-button-C-DXj68Z.esm.js +2 -0
  99. package/dist/chunks/share-button-C-DXj68Z.esm.js.map +1 -0
  100. package/dist/chunks/share-button-CtklpZOO.esm.js +167 -0
  101. package/dist/chunks/share-button-CtklpZOO.esm.js.map +1 -0
  102. package/dist/chunks/{update-cart-UuMHYehB.esm.js → update-cart-BLsw_Faz.esm.js} +2 -2
  103. package/dist/chunks/{update-cart-UuMHYehB.esm.js.map → update-cart-BLsw_Faz.esm.js.map} +1 -1
  104. package/dist/chunks/{update-cart-JO4fuiim.esm.d.ts → update-cart-NiToHHJH.esm.d.ts} +2 -2
  105. package/dist/chunks/{update-cart-mNsQ9K-k.esm.js → update-cart-ciJaz8li.esm.js} +2 -2
  106. package/dist/chunks/{update-cart-mNsQ9K-k.esm.js.map → update-cart-ciJaz8li.esm.js.map} +1 -1
  107. package/dist/chunks/{vendor-GKiOHg2N.esm.js → vendor-KKSARHWL.esm.js} +2 -2
  108. package/dist/chunks/{vendor-GKiOHg2N.esm.js.map → vendor-KKSARHWL.esm.js.map} +1 -1
  109. package/dist/components/beam-partner-logos.d.ts +1 -1
  110. package/dist/components/beam-partner-logos.esm.js +4 -4
  111. package/dist/components/beam-partner-logos.esm.js.map +1 -1
  112. package/dist/components/beam-partner-logos.js +4 -4
  113. package/dist/components/beam-partner-logos.js.map +1 -1
  114. package/dist/components/community-impact.d.ts +3 -3
  115. package/dist/components/community-impact.esm.js +15 -15
  116. package/dist/components/community-impact.esm.js.map +1 -1
  117. package/dist/components/community-impact.js +15 -15
  118. package/dist/components/community-impact.js.map +1 -1
  119. package/dist/components/cumulative-impact.d.ts +2 -2
  120. package/dist/components/cumulative-impact.esm.js +8 -8
  121. package/dist/components/cumulative-impact.esm.js.map +1 -1
  122. package/dist/components/cumulative-impact.js +8 -8
  123. package/dist/components/cumulative-impact.js.map +1 -1
  124. package/dist/components/impact-overview.d.ts +4 -4
  125. package/dist/components/impact-overview.esm.js +26 -21
  126. package/dist/components/impact-overview.esm.js.map +1 -1
  127. package/dist/components/impact-overview.js +26 -21
  128. package/dist/components/impact-overview.js.map +1 -1
  129. package/dist/components/index.d.ts +8 -8
  130. package/dist/components/index.esm.js +1 -1
  131. package/dist/components/index.js +1 -1
  132. package/dist/components/post-purchase.d.ts +7 -7
  133. package/dist/components/post-purchase.esm.js +2 -2
  134. package/dist/components/post-purchase.esm.js.map +1 -1
  135. package/dist/components/post-purchase.js +2 -2
  136. package/dist/components/post-purchase.js.map +1 -1
  137. package/dist/components/product-details-page.d.ts +3 -4
  138. package/dist/components/product-details-page.esm.js +22 -11
  139. package/dist/components/product-details-page.esm.js.map +1 -1
  140. package/dist/components/product-details-page.js +22 -11
  141. package/dist/components/product-details-page.js.map +1 -1
  142. package/dist/components/redeem-transaction.d.ts +6 -6
  143. package/dist/components/redeem-transaction.esm.js +3 -3
  144. package/dist/components/redeem-transaction.esm.js.map +1 -1
  145. package/dist/components/redeem-transaction.js +3 -3
  146. package/dist/components/redeem-transaction.js.map +1 -1
  147. package/dist/components/select-nonprofit.d.ts +6 -6
  148. package/dist/components/select-nonprofit.esm.js +89 -89
  149. package/dist/components/select-nonprofit.esm.js.map +1 -1
  150. package/dist/components/select-nonprofit.js +89 -89
  151. package/dist/components/select-nonprofit.js.map +1 -1
  152. package/dist/components/select-subscription-nonprofit.d.ts +3 -3
  153. package/dist/components/select-subscription-nonprofit.esm.js +13 -13
  154. package/dist/components/select-subscription-nonprofit.esm.js.map +1 -1
  155. package/dist/components/select-subscription-nonprofit.js +13 -13
  156. package/dist/components/select-subscription-nonprofit.js.map +1 -1
  157. package/dist/components/shopify.d.ts +12 -12
  158. package/dist/components/shopify.esm.js +1 -1
  159. package/dist/components/shopify.esm.js.map +1 -1
  160. package/dist/components/shopify.js +1 -1
  161. package/dist/components/shopify.js.map +1 -1
  162. package/dist/components/social-share.d.ts +3 -3
  163. package/dist/components/social-share.esm.js +3 -3
  164. package/dist/components/social-share.esm.js.map +1 -1
  165. package/dist/components/social-share.js +3 -3
  166. package/dist/components/social-share.js.map +1 -1
  167. package/dist/components/subscription-impact.d.ts +4 -4
  168. package/dist/components/subscription-impact.esm.js +27 -25
  169. package/dist/components/subscription-impact.esm.js.map +1 -1
  170. package/dist/components/subscription-impact.js +27 -25
  171. package/dist/components/subscription-impact.js.map +1 -1
  172. package/dist/components/subscription-management.d.ts +7 -7
  173. package/dist/components/subscription-management.esm.js +9 -9
  174. package/dist/components/subscription-management.esm.js.map +1 -1
  175. package/dist/components/subscription-management.js +9 -9
  176. package/dist/components/subscription-management.js.map +1 -1
  177. package/dist/index.d.ts +22 -22
  178. package/dist/index.esm.js +1 -1
  179. package/dist/index.js +1 -1
  180. package/dist/integrations/beam.d.ts +1 -1
  181. package/dist/integrations/beam.esm.js +1 -1
  182. package/dist/integrations/beam.esm.js.map +1 -1
  183. package/dist/integrations/beam.js +1 -1
  184. package/dist/integrations/beam.js.map +1 -1
  185. package/dist/integrations/cart.d.ts +4 -4
  186. package/dist/integrations/cart.esm.js +1 -1
  187. package/dist/integrations/cart.js +1 -1
  188. package/dist/integrations/index.d.ts +18 -18
  189. package/dist/integrations/index.esm.js +1 -1
  190. package/dist/integrations/index.js +1 -1
  191. package/dist/integrations/logs.d.ts +2 -2
  192. package/dist/integrations/logs.esm.js +1 -1
  193. package/dist/integrations/logs.js +1 -1
  194. package/dist/integrations/promoManager.d.ts +1 -1
  195. package/dist/integrations/promoManager.esm.js +1 -1
  196. package/dist/integrations/promoManager.js +1 -1
  197. package/dist/integrations/session.d.ts +1 -1
  198. package/dist/integrations/session.esm.js +1 -1
  199. package/dist/integrations/session.js +1 -1
  200. package/dist/integrations/shopify.d.ts +10 -10
  201. package/dist/integrations/shopify.esm.js +1 -1
  202. package/dist/integrations/shopify.js +1 -1
  203. package/dist/integrations/statsig.d.ts +1 -1
  204. package/dist/integrations/statsig.esm.js +2 -2
  205. package/dist/integrations/statsig.esm.js.map +1 -1
  206. package/dist/integrations/statsig.js +2 -2
  207. package/dist/integrations/statsig.js.map +1 -1
  208. package/dist/integrations/utils.d.ts +6 -6
  209. package/dist/integrations/utils.esm.js +1 -1
  210. package/dist/integrations/utils.js +1 -1
  211. package/dist/react/beam-partner-logos.d.ts +1 -1
  212. package/dist/react/beam-partner-logos.esm.js +1 -1
  213. package/dist/react/beam-partner-logos.js +1 -1
  214. package/dist/react/community-impact.d.ts +3 -3
  215. package/dist/react/community-impact.esm.js +1 -1
  216. package/dist/react/community-impact.js +1 -1
  217. package/dist/react/cumulative-impact.d.ts +2 -2
  218. package/dist/react/cumulative-impact.esm.js +1 -1
  219. package/dist/react/cumulative-impact.js +1 -1
  220. package/dist/react/impact-overview.d.ts +4 -4
  221. package/dist/react/impact-overview.esm.js +1 -1
  222. package/dist/react/impact-overview.esm.js.map +1 -1
  223. package/dist/react/impact-overview.js +1 -1
  224. package/dist/react/impact-overview.js.map +1 -1
  225. package/dist/react/index.d.ts +10 -10
  226. package/dist/react/index.esm.js +1 -1
  227. package/dist/react/index.js +1 -1
  228. package/dist/react/post-purchase.d.ts +7 -7
  229. package/dist/react/post-purchase.esm.js +1 -1
  230. package/dist/react/post-purchase.esm.js.map +1 -1
  231. package/dist/react/post-purchase.js +1 -1
  232. package/dist/react/post-purchase.js.map +1 -1
  233. package/dist/react/product-details-page.d.ts +3 -3
  234. package/dist/react/product-details-page.esm.js +1 -1
  235. package/dist/react/product-details-page.js +1 -1
  236. package/dist/react/redeem-transaction.d.ts +8 -8
  237. package/dist/react/redeem-transaction.esm.js +1 -1
  238. package/dist/react/redeem-transaction.js +1 -1
  239. package/dist/react/select-nonprofit.d.ts +8 -8
  240. package/dist/react/select-nonprofit.esm.js +1 -1
  241. package/dist/react/select-nonprofit.js +1 -1
  242. package/dist/react/select-subscription-nonprofit.d.ts +7 -7
  243. package/dist/react/select-subscription-nonprofit.esm.js +1 -1
  244. package/dist/react/select-subscription-nonprofit.js +1 -1
  245. package/dist/react/social-share.d.ts +3 -3
  246. package/dist/react/social-share.esm.js +1 -1
  247. package/dist/react/social-share.esm.js.map +1 -1
  248. package/dist/react/social-share.js +1 -1
  249. package/dist/react/social-share.js.map +1 -1
  250. package/dist/react/subscription-impact.d.ts +4 -4
  251. package/dist/react/subscription-impact.esm.js +1 -1
  252. package/dist/react/subscription-impact.js +1 -1
  253. package/dist/react/subscription-management.d.ts +7 -7
  254. package/dist/react/subscription-management.esm.js +1 -1
  255. package/dist/react/subscription-management.js +1 -1
  256. package/dist/utils/beam-errors.d.ts +1 -1
  257. package/dist/utils/beam-errors.esm.js +1 -1
  258. package/dist/utils/beam-errors.js +1 -1
  259. package/dist/utils/cart.esm.js +1 -1
  260. package/dist/utils/cart.js +1 -1
  261. package/dist/utils/cookies.esm.js +1 -1
  262. package/dist/utils/cookies.esm.js.map +1 -1
  263. package/dist/utils/cookies.js +1 -1
  264. package/dist/utils/cookies.js.map +1 -1
  265. package/dist/utils/debounce.esm.js +1 -1
  266. package/dist/utils/debounce.js +1 -1
  267. package/dist/utils/events.d.ts +5 -5
  268. package/dist/utils/events.esm.js +1 -1
  269. package/dist/utils/events.js +1 -1
  270. package/dist/utils/index.d.ts +6 -6
  271. package/dist/utils/index.esm.js +1 -1
  272. package/dist/utils/index.js +1 -1
  273. package/dist/utils/is-equal.esm.js +1 -1
  274. package/dist/utils/is-equal.js +1 -1
  275. package/dist/utils/local-storage.esm.js +1 -1
  276. package/dist/utils/local-storage.js +1 -1
  277. package/dist/utils/memoize-last.esm.js +1 -1
  278. package/dist/utils/memoize-last.esm.js.map +1 -1
  279. package/dist/utils/memoize-last.js +1 -1
  280. package/dist/utils/memoize-last.js.map +1 -1
  281. package/dist/utils/network-listeners.esm.js +1 -1
  282. package/dist/utils/network-listeners.esm.js.map +1 -1
  283. package/dist/utils/network-listeners.js +1 -1
  284. package/dist/utils/network-listeners.js.map +1 -1
  285. package/dist/utils/promoManager.d.ts +3 -3
  286. package/dist/utils/promoManager.esm.js +1 -1
  287. package/dist/utils/promoManager.js +1 -1
  288. package/dist/utils/remote-session.esm.js +1 -1
  289. package/dist/utils/remote-session.js +1 -1
  290. package/dist/utils/wait-for-element.esm.js +1 -1
  291. package/dist/utils/wait-for-element.js +1 -1
  292. package/package.json +4 -4
  293. package/dist/chunks/_share-dialog-dependencies-RmYWlyJ0.esm.js +0 -2
  294. package/dist/chunks/_share-dialog-dependencies-RmYWlyJ0.esm.js.map +0 -1
  295. package/dist/chunks/_share-dialog-dependencies-yCBFjXxQ.esm.js +0 -2
  296. package/dist/chunks/_share-dialog-dependencies-yCBFjXxQ.esm.js.map +0 -1
  297. package/dist/chunks/cart-contents-h60geKWa.esm.js +0 -2
  298. package/dist/chunks/enforce-config-S8EGgEnO.esm.js +0 -3
  299. package/dist/chunks/enforce-config-l-tNb_z7.esm.js +0 -3
  300. package/dist/chunks/index-2qmtuEV_.esm.d.ts +0 -15
  301. package/dist/chunks/index-44clOvXJ.esm.js +0 -2
  302. package/dist/chunks/index-44clOvXJ.esm.js.map +0 -1
  303. package/dist/chunks/index-B-9JPaCH.esm.js +0 -2
  304. package/dist/chunks/index-B-9JPaCH.esm.js.map +0 -1
  305. package/dist/chunks/index-CNVMNDM4.esm.js +0 -2
  306. package/dist/chunks/index-CNVMNDM4.esm.js.map +0 -1
  307. package/dist/chunks/index-E8H5A7Qq.esm.js.map +0 -1
  308. package/dist/chunks/index-FQExZDX9.esm.js.map +0 -1
  309. package/dist/chunks/index-PiMq5a49.esm.js.map +0 -1
  310. package/dist/chunks/index-UHchr4H_.esm.js +0 -2
  311. package/dist/chunks/index-UHchr4H_.esm.js.map +0 -1
  312. package/dist/chunks/index-XCMf22lv.esm.js.map +0 -1
  313. package/dist/chunks/index-dLnZQZlT.esm.js.map +0 -1
  314. package/dist/chunks/index-f7fp9odj.esm.js.map +0 -1
  315. package/dist/chunks/index-kFulvjM4.esm.js.map +0 -1
  316. package/dist/chunks/index-m1LRybiJ.esm.js.map +0 -1
  317. package/dist/chunks/index-smGc5rsi.esm.js +0 -2
  318. package/dist/chunks/index-smGc5rsi.esm.js.map +0 -1
  319. package/dist/chunks/index-wz6Yfo37.esm.js +0 -2
  320. package/dist/chunks/index-wz6Yfo37.esm.js.map +0 -1
  321. package/dist/chunks/lit-iNN5L_Qk.esm.js +0 -34
  322. package/dist/chunks/lit-iNN5L_Qk.esm.js.map +0 -1
  323. package/dist/chunks/loading-template-t4fFsYtr.esm.js +0 -2
  324. package/dist/chunks/lodash-P8OIs-at.esm.js +0 -2
  325. package/dist/chunks/lodash-P8OIs-at.esm.js.map +0 -1
  326. package/dist/chunks/order-page-WPxvCNLM.esm.js +0 -2
  327. package/dist/chunks/order-page-WPxvCNLM.esm.js.map +0 -1
  328. package/dist/chunks/order-page-ZpOf35sP.esm.js +0 -2
  329. package/dist/chunks/order-page-ZpOf35sP.esm.js.map +0 -1
  330. package/dist/chunks/promo-pill-label-P1X4xeAx.esm.js +0 -16
  331. package/dist/chunks/routes-YPOoVIR2.esm.js +0 -2
  332. package/dist/chunks/routes-o-phF_L1.esm.js +0 -2
  333. package/dist/chunks/share-button-EsUPw38-.esm.js +0 -163
  334. package/dist/chunks/share-button-EsUPw38-.esm.js.map +0 -1
  335. package/dist/chunks/share-button-SNvuFDC9.esm.js +0 -2
  336. package/dist/chunks/share-button-SNvuFDC9.esm.js.map +0 -1
  337. package/dist/chunks/share-button-r0y-bbwR.esm.js +0 -163
  338. package/dist/chunks/share-button-r0y-bbwR.esm.js.map +0 -1
  339. package/dist/chunks/shoelace-components-PB22pjfM.esm.js +0 -2
  340. package/dist/chunks/shoelace-components-PB22pjfM.esm.js.map +0 -1
  341. package/dist/chunks/shoelace-components-lr4iB8kL.esm.js +0 -2
  342. package/dist/chunks/shoelace-components-lr4iB8kL.esm.js.map +0 -1
  343. /package/dist/chunks/{beam-errors-bKCZlkvr.esm.d.ts → beam-errors-CCe004HS.esm.d.ts} +0 -0
  344. /package/dist/chunks/{index-EGiUuWe-.esm.d.ts → index-C-hPf29c.esm.d.ts} +0 -0
  345. /package/dist/chunks/{index-hn6JhG_w.esm.d.ts → index-DXj15KHe.esm.d.ts} +0 -0
  346. /package/dist/chunks/{index-mTXm0DPh.esm.d.ts → index-DbaDUPup.esm.d.ts} +0 -0
  347. /package/dist/chunks/{openapi-spec-bxGNhNMa.esm.d.ts → openapi-spec-VAt3phhg.esm.d.ts} +0 -0
  348. /package/dist/chunks/{progress-bar-0VS_AmEf.esm.d.ts → progress-bar-CveZ8E6Q.esm.d.ts} +0 -0
  349. /package/dist/chunks/{promo-pill-label-3bA1z-la.esm.d.ts → promo-pill-label-BXRqZHET.esm.d.ts} +0 -0
  350. /package/dist/chunks/{routes-lGXt7ttd.esm.d.ts → routes-DDRd747e.esm.d.ts} +0 -0
  351. /package/dist/chunks/{types-aju0qrRe.esm.d.ts → types-C7gqAyyH.esm.d.ts} +0 -0
  352. /package/dist/chunks/{types-IbMT3Nwn.esm.d.ts → types-CPxMwnoR.esm.d.ts} +0 -0
@@ -1 +0,0 @@
1
- {"version":3,"file":"lodash-P8OIs-at.esm.js","sources":["../../node_modules/lodash-es/isObject.js","../../node_modules/lodash-es/_freeGlobal.js","../../node_modules/lodash-es/_root.js","../../node_modules/lodash-es/now.js","../../node_modules/lodash-es/_trimmedEndIndex.js","../../node_modules/lodash-es/_baseTrim.js","../../node_modules/lodash-es/_Symbol.js","../../node_modules/lodash-es/_getRawTag.js","../../node_modules/lodash-es/_objectToString.js","../../node_modules/lodash-es/_baseGetTag.js","../../node_modules/lodash-es/isObjectLike.js","../../node_modules/lodash-es/isSymbol.js","../../node_modules/lodash-es/toNumber.js","../../node_modules/lodash-es/debounce.js","../../node_modules/lodash-es/_listCacheClear.js","../../node_modules/lodash-es/eq.js","../../node_modules/lodash-es/_assocIndexOf.js","../../node_modules/lodash-es/_listCacheDelete.js","../../node_modules/lodash-es/_listCacheGet.js","../../node_modules/lodash-es/_listCacheHas.js","../../node_modules/lodash-es/_listCacheSet.js","../../node_modules/lodash-es/_ListCache.js","../../node_modules/lodash-es/_stackClear.js","../../node_modules/lodash-es/_stackDelete.js","../../node_modules/lodash-es/_stackGet.js","../../node_modules/lodash-es/_stackHas.js","../../node_modules/lodash-es/isFunction.js","../../node_modules/lodash-es/_coreJsData.js","../../node_modules/lodash-es/_isMasked.js","../../node_modules/lodash-es/_toSource.js","../../node_modules/lodash-es/_baseIsNative.js","../../node_modules/lodash-es/_getValue.js","../../node_modules/lodash-es/_getNative.js","../../node_modules/lodash-es/_Map.js","../../node_modules/lodash-es/_nativeCreate.js","../../node_modules/lodash-es/_hashClear.js","../../node_modules/lodash-es/_hashDelete.js","../../node_modules/lodash-es/_hashGet.js","../../node_modules/lodash-es/_hashHas.js","../../node_modules/lodash-es/_hashSet.js","../../node_modules/lodash-es/_Hash.js","../../node_modules/lodash-es/_mapCacheClear.js","../../node_modules/lodash-es/_isKeyable.js","../../node_modules/lodash-es/_getMapData.js","../../node_modules/lodash-es/_mapCacheDelete.js","../../node_modules/lodash-es/_mapCacheGet.js","../../node_modules/lodash-es/_mapCacheHas.js","../../node_modules/lodash-es/_mapCacheSet.js","../../node_modules/lodash-es/_MapCache.js","../../node_modules/lodash-es/_stackSet.js","../../node_modules/lodash-es/_Stack.js","../../node_modules/lodash-es/_setCacheAdd.js","../../node_modules/lodash-es/_setCacheHas.js","../../node_modules/lodash-es/_SetCache.js","../../node_modules/lodash-es/_arraySome.js","../../node_modules/lodash-es/_cacheHas.js","../../node_modules/lodash-es/_equalArrays.js","../../node_modules/lodash-es/_Uint8Array.js","../../node_modules/lodash-es/_mapToArray.js","../../node_modules/lodash-es/_setToArray.js","../../node_modules/lodash-es/_equalByTag.js","../../node_modules/lodash-es/_arrayPush.js","../../node_modules/lodash-es/isArray.js","../../node_modules/lodash-es/_baseGetAllKeys.js","../../node_modules/lodash-es/_arrayFilter.js","../../node_modules/lodash-es/stubArray.js","../../node_modules/lodash-es/_getSymbols.js","../../node_modules/lodash-es/_baseTimes.js","../../node_modules/lodash-es/_baseIsArguments.js","../../node_modules/lodash-es/isArguments.js","../../node_modules/lodash-es/stubFalse.js","../../node_modules/lodash-es/isBuffer.js","../../node_modules/lodash-es/_isIndex.js","../../node_modules/lodash-es/isLength.js","../../node_modules/lodash-es/_baseIsTypedArray.js","../../node_modules/lodash-es/_baseUnary.js","../../node_modules/lodash-es/_nodeUtil.js","../../node_modules/lodash-es/isTypedArray.js","../../node_modules/lodash-es/_arrayLikeKeys.js","../../node_modules/lodash-es/_isPrototype.js","../../node_modules/lodash-es/_overArg.js","../../node_modules/lodash-es/_nativeKeys.js","../../node_modules/lodash-es/_baseKeys.js","../../node_modules/lodash-es/isArrayLike.js","../../node_modules/lodash-es/keys.js","../../node_modules/lodash-es/_getAllKeys.js","../../node_modules/lodash-es/_equalObjects.js","../../node_modules/lodash-es/_DataView.js","../../node_modules/lodash-es/_Promise.js","../../node_modules/lodash-es/_Set.js","../../node_modules/lodash-es/_WeakMap.js","../../node_modules/lodash-es/_getTag.js","../../node_modules/lodash-es/_baseIsEqualDeep.js","../../node_modules/lodash-es/_baseIsEqual.js","../../node_modules/lodash-es/isEqual.js"],"sourcesContent":["/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\nexport default isObject;\n","/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\nexport default freeGlobal;\n","import freeGlobal from './_freeGlobal.js';\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\nexport default root;\n","import root from './_root.js';\n\n/**\n * Gets the timestamp of the number of milliseconds that have elapsed since\n * the Unix epoch (1 January 1970 00:00:00 UTC).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Date\n * @returns {number} Returns the timestamp.\n * @example\n *\n * _.defer(function(stamp) {\n * console.log(_.now() - stamp);\n * }, _.now());\n * // => Logs the number of milliseconds it took for the deferred invocation.\n */\nvar now = function() {\n return root.Date.now();\n};\n\nexport default now;\n","/** Used to match a single whitespace character. */\nvar reWhitespace = /\\s/;\n\n/**\n * Used by `_.trim` and `_.trimEnd` to get the index of the last non-whitespace\n * character of `string`.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {number} Returns the index of the last non-whitespace character.\n */\nfunction trimmedEndIndex(string) {\n var index = string.length;\n\n while (index-- && reWhitespace.test(string.charAt(index))) {}\n return index;\n}\n\nexport default trimmedEndIndex;\n","import trimmedEndIndex from './_trimmedEndIndex.js';\n\n/** Used to match leading whitespace. */\nvar reTrimStart = /^\\s+/;\n\n/**\n * The base implementation of `_.trim`.\n *\n * @private\n * @param {string} string The string to trim.\n * @returns {string} Returns the trimmed string.\n */\nfunction baseTrim(string) {\n return string\n ? string.slice(0, trimmedEndIndex(string) + 1).replace(reTrimStart, '')\n : string;\n}\n\nexport default baseTrim;\n","import root from './_root.js';\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\nexport default Symbol;\n","import Symbol from './_Symbol.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n}\n\nexport default getRawTag;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\nexport default objectToString;\n","import Symbol from './_Symbol.js';\nimport getRawTag from './_getRawTag.js';\nimport objectToString from './_objectToString.js';\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\nexport default baseGetTag;\n","/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\nexport default isObjectLike;\n","import baseGetTag from './_baseGetTag.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\n}\n\nexport default isSymbol;\n","import baseTrim from './_baseTrim.js';\nimport isObject from './isObject.js';\nimport isSymbol from './isSymbol.js';\n\n/** Used as references for various `Number` constants. */\nvar NAN = 0 / 0;\n\n/** Used to detect bad signed hexadecimal string values. */\nvar reIsBadHex = /^[-+]0x[0-9a-f]+$/i;\n\n/** Used to detect binary string values. */\nvar reIsBinary = /^0b[01]+$/i;\n\n/** Used to detect octal string values. */\nvar reIsOctal = /^0o[0-7]+$/i;\n\n/** Built-in method references without a dependency on `root`. */\nvar freeParseInt = parseInt;\n\n/**\n * Converts `value` to a number.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to process.\n * @returns {number} Returns the number.\n * @example\n *\n * _.toNumber(3.2);\n * // => 3.2\n *\n * _.toNumber(Number.MIN_VALUE);\n * // => 5e-324\n *\n * _.toNumber(Infinity);\n * // => Infinity\n *\n * _.toNumber('3.2');\n * // => 3.2\n */\nfunction toNumber(value) {\n if (typeof value == 'number') {\n return value;\n }\n if (isSymbol(value)) {\n return NAN;\n }\n if (isObject(value)) {\n var other = typeof value.valueOf == 'function' ? value.valueOf() : value;\n value = isObject(other) ? (other + '') : other;\n }\n if (typeof value != 'string') {\n return value === 0 ? value : +value;\n }\n value = baseTrim(value);\n var isBinary = reIsBinary.test(value);\n return (isBinary || reIsOctal.test(value))\n ? freeParseInt(value.slice(2), isBinary ? 2 : 8)\n : (reIsBadHex.test(value) ? NAN : +value);\n}\n\nexport default toNumber;\n","import isObject from './isObject.js';\nimport now from './now.js';\nimport toNumber from './toNumber.js';\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeMax = Math.max,\n nativeMin = Math.min;\n\n/**\n * Creates a debounced function that delays invoking `func` until after `wait`\n * milliseconds have elapsed since the last time the debounced function was\n * invoked. The debounced function comes with a `cancel` method to cancel\n * delayed `func` invocations and a `flush` method to immediately invoke them.\n * Provide `options` to indicate whether `func` should be invoked on the\n * leading and/or trailing edge of the `wait` timeout. The `func` is invoked\n * with the last arguments provided to the debounced function. Subsequent\n * calls to the debounced function return the result of the last `func`\n * invocation.\n *\n * **Note:** If `leading` and `trailing` options are `true`, `func` is\n * invoked on the trailing edge of the timeout only if the debounced function\n * is invoked more than once during the `wait` timeout.\n *\n * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred\n * until to the next tick, similar to `setTimeout` with a timeout of `0`.\n *\n * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)\n * for details over the differences between `_.debounce` and `_.throttle`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to debounce.\n * @param {number} [wait=0] The number of milliseconds to delay.\n * @param {Object} [options={}] The options object.\n * @param {boolean} [options.leading=false]\n * Specify invoking on the leading edge of the timeout.\n * @param {number} [options.maxWait]\n * The maximum time `func` is allowed to be delayed before it's invoked.\n * @param {boolean} [options.trailing=true]\n * Specify invoking on the trailing edge of the timeout.\n * @returns {Function} Returns the new debounced function.\n * @example\n *\n * // Avoid costly calculations while the window size is in flux.\n * jQuery(window).on('resize', _.debounce(calculateLayout, 150));\n *\n * // Invoke `sendMail` when clicked, debouncing subsequent calls.\n * jQuery(element).on('click', _.debounce(sendMail, 300, {\n * 'leading': true,\n * 'trailing': false\n * }));\n *\n * // Ensure `batchLog` is invoked once after 1 second of debounced calls.\n * var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 });\n * var source = new EventSource('/stream');\n * jQuery(source).on('message', debounced);\n *\n * // Cancel the trailing debounced invocation.\n * jQuery(window).on('popstate', debounced.cancel);\n */\nfunction debounce(func, wait, options) {\n var lastArgs,\n lastThis,\n maxWait,\n result,\n timerId,\n lastCallTime,\n lastInvokeTime = 0,\n leading = false,\n maxing = false,\n trailing = true;\n\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n wait = toNumber(wait) || 0;\n if (isObject(options)) {\n leading = !!options.leading;\n maxing = 'maxWait' in options;\n maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;\n trailing = 'trailing' in options ? !!options.trailing : trailing;\n }\n\n function invokeFunc(time) {\n var args = lastArgs,\n thisArg = lastThis;\n\n lastArgs = lastThis = undefined;\n lastInvokeTime = time;\n result = func.apply(thisArg, args);\n return result;\n }\n\n function leadingEdge(time) {\n // Reset any `maxWait` timer.\n lastInvokeTime = time;\n // Start the timer for the trailing edge.\n timerId = setTimeout(timerExpired, wait);\n // Invoke the leading edge.\n return leading ? invokeFunc(time) : result;\n }\n\n function remainingWait(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime,\n timeWaiting = wait - timeSinceLastCall;\n\n return maxing\n ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke)\n : timeWaiting;\n }\n\n function shouldInvoke(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime;\n\n // Either this is the first call, activity has stopped and we're at the\n // trailing edge, the system time has gone backwards and we're treating\n // it as the trailing edge, or we've hit the `maxWait` limit.\n return (lastCallTime === undefined || (timeSinceLastCall >= wait) ||\n (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait));\n }\n\n function timerExpired() {\n var time = now();\n if (shouldInvoke(time)) {\n return trailingEdge(time);\n }\n // Restart the timer.\n timerId = setTimeout(timerExpired, remainingWait(time));\n }\n\n function trailingEdge(time) {\n timerId = undefined;\n\n // Only invoke if we have `lastArgs` which means `func` has been\n // debounced at least once.\n if (trailing && lastArgs) {\n return invokeFunc(time);\n }\n lastArgs = lastThis = undefined;\n return result;\n }\n\n function cancel() {\n if (timerId !== undefined) {\n clearTimeout(timerId);\n }\n lastInvokeTime = 0;\n lastArgs = lastCallTime = lastThis = timerId = undefined;\n }\n\n function flush() {\n return timerId === undefined ? result : trailingEdge(now());\n }\n\n function debounced() {\n var time = now(),\n isInvoking = shouldInvoke(time);\n\n lastArgs = arguments;\n lastThis = this;\n lastCallTime = time;\n\n if (isInvoking) {\n if (timerId === undefined) {\n return leadingEdge(lastCallTime);\n }\n if (maxing) {\n // Handle invocations in a tight loop.\n clearTimeout(timerId);\n timerId = setTimeout(timerExpired, wait);\n return invokeFunc(lastCallTime);\n }\n }\n if (timerId === undefined) {\n timerId = setTimeout(timerExpired, wait);\n }\n return result;\n }\n debounced.cancel = cancel;\n debounced.flush = flush;\n return debounced;\n}\n\nexport default debounce;\n","/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n}\n\nexport default listCacheClear;\n","/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\nexport default eq;\n","import eq from './eq.js';\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\nexport default assocIndexOf;\n","import assocIndexOf from './_assocIndexOf.js';\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype;\n\n/** Built-in value references. */\nvar splice = arrayProto.splice;\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n}\n\nexport default listCacheDelete;\n","import assocIndexOf from './_assocIndexOf.js';\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\nexport default listCacheGet;\n","import assocIndexOf from './_assocIndexOf.js';\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\nexport default listCacheHas;\n","import assocIndexOf from './_assocIndexOf.js';\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\nexport default listCacheSet;\n","import listCacheClear from './_listCacheClear.js';\nimport listCacheDelete from './_listCacheDelete.js';\nimport listCacheGet from './_listCacheGet.js';\nimport listCacheHas from './_listCacheHas.js';\nimport listCacheSet from './_listCacheSet.js';\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\nexport default ListCache;\n","import ListCache from './_ListCache.js';\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\nexport default stackClear;\n","/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\nexport default stackDelete;\n","/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\nexport default stackGet;\n","/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\nexport default stackHas;\n","import baseGetTag from './_baseGetTag.js';\nimport isObject from './isObject.js';\n\n/** `Object#toString` result references. */\nvar asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n proxyTag = '[object Proxy]';\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nexport default isFunction;\n","import root from './_root.js';\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\nexport default coreJsData;\n","import coreJsData from './_coreJsData.js';\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\nexport default isMasked;\n","/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\nexport default toSource;\n","import isFunction from './isFunction.js';\nimport isMasked from './_isMasked.js';\nimport isObject from './isObject.js';\nimport toSource from './_toSource.js';\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\nexport default baseIsNative;\n","/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\nexport default getValue;\n","import baseIsNative from './_baseIsNative.js';\nimport getValue from './_getValue.js';\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\nexport default getNative;\n","import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map');\n\nexport default Map;\n","import getNative from './_getNative.js';\n\n/* Built-in method references that are verified to be native. */\nvar nativeCreate = getNative(Object, 'create');\n\nexport default nativeCreate;\n","import nativeCreate from './_nativeCreate.js';\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n}\n\nexport default hashClear;\n","/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n}\n\nexport default hashDelete;\n","import nativeCreate from './_nativeCreate.js';\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\nexport default hashGet;\n","import nativeCreate from './_nativeCreate.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\nexport default hashHas;\n","import nativeCreate from './_nativeCreate.js';\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\nexport default hashSet;\n","import hashClear from './_hashClear.js';\nimport hashDelete from './_hashDelete.js';\nimport hashGet from './_hashGet.js';\nimport hashHas from './_hashHas.js';\nimport hashSet from './_hashSet.js';\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\nexport default Hash;\n","import Hash from './_Hash.js';\nimport ListCache from './_ListCache.js';\nimport Map from './_Map.js';\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\nexport default mapCacheClear;\n","/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\nexport default isKeyable;\n","import isKeyable from './_isKeyable.js';\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\nexport default getMapData;\n","import getMapData from './_getMapData.js';\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n}\n\nexport default mapCacheDelete;\n","import getMapData from './_getMapData.js';\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\nexport default mapCacheGet;\n","import getMapData from './_getMapData.js';\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\nexport default mapCacheHas;\n","import getMapData from './_getMapData.js';\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n}\n\nexport default mapCacheSet;\n","import mapCacheClear from './_mapCacheClear.js';\nimport mapCacheDelete from './_mapCacheDelete.js';\nimport mapCacheGet from './_mapCacheGet.js';\nimport mapCacheHas from './_mapCacheHas.js';\nimport mapCacheSet from './_mapCacheSet.js';\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\nexport default MapCache;\n","import ListCache from './_ListCache.js';\nimport Map from './_Map.js';\nimport MapCache from './_MapCache.js';\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\nexport default stackSet;\n","import ListCache from './_ListCache.js';\nimport stackClear from './_stackClear.js';\nimport stackDelete from './_stackDelete.js';\nimport stackGet from './_stackGet.js';\nimport stackHas from './_stackHas.js';\nimport stackSet from './_stackSet.js';\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nexport default Stack;\n","/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\nfunction setCacheAdd(value) {\n this.__data__.set(value, HASH_UNDEFINED);\n return this;\n}\n\nexport default setCacheAdd;\n","/**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\nfunction setCacheHas(value) {\n return this.__data__.has(value);\n}\n\nexport default setCacheHas;\n","import MapCache from './_MapCache.js';\nimport setCacheAdd from './_setCacheAdd.js';\nimport setCacheHas from './_setCacheHas.js';\n\n/**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\nfunction SetCache(values) {\n var index = -1,\n length = values == null ? 0 : values.length;\n\n this.__data__ = new MapCache;\n while (++index < length) {\n this.add(values[index]);\n }\n}\n\n// Add methods to `SetCache`.\nSetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\nSetCache.prototype.has = setCacheHas;\n\nexport default SetCache;\n","/**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\nfunction arraySome(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (predicate(array[index], index, array)) {\n return true;\n }\n }\n return false;\n}\n\nexport default arraySome;\n","/**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction cacheHas(cache, key) {\n return cache.has(key);\n}\n\nexport default cacheHas;\n","import SetCache from './_SetCache.js';\nimport arraySome from './_arraySome.js';\nimport cacheHas from './_cacheHas.js';\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\nfunction equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n arrLength = array.length,\n othLength = other.length;\n\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n return false;\n }\n // Check that cyclic values are equal.\n var arrStacked = stack.get(array);\n var othStacked = stack.get(other);\n if (arrStacked && othStacked) {\n return arrStacked == other && othStacked == array;\n }\n var index = -1,\n result = true,\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n stack.set(array, other);\n stack.set(other, array);\n\n // Ignore non-index properties.\n while (++index < arrLength) {\n var arrValue = array[index],\n othValue = other[index];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, arrValue, index, other, array, stack)\n : customizer(arrValue, othValue, index, array, other, stack);\n }\n if (compared !== undefined) {\n if (compared) {\n continue;\n }\n result = false;\n break;\n }\n // Recursively compare arrays (susceptible to call stack limits).\n if (seen) {\n if (!arraySome(other, function(othValue, othIndex) {\n if (!cacheHas(seen, othIndex) &&\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n return seen.push(othIndex);\n }\n })) {\n result = false;\n break;\n }\n } else if (!(\n arrValue === othValue ||\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\n )) {\n result = false;\n break;\n }\n }\n stack['delete'](array);\n stack['delete'](other);\n return result;\n}\n\nexport default equalArrays;\n","import root from './_root.js';\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nexport default Uint8Array;\n","/**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\nfunction mapToArray(map) {\n var index = -1,\n result = Array(map.size);\n\n map.forEach(function(value, key) {\n result[++index] = [key, value];\n });\n return result;\n}\n\nexport default mapToArray;\n","/**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\nfunction setToArray(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = value;\n });\n return result;\n}\n\nexport default setToArray;\n","import Symbol from './_Symbol.js';\nimport Uint8Array from './_Uint8Array.js';\nimport eq from './eq.js';\nimport equalArrays from './_equalArrays.js';\nimport mapToArray from './_mapToArray.js';\nimport setToArray from './_setToArray.js';\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/** `Object#toString` result references. */\nvar boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]';\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n switch (tag) {\n case dataViewTag:\n if ((object.byteLength != other.byteLength) ||\n (object.byteOffset != other.byteOffset)) {\n return false;\n }\n object = object.buffer;\n other = other.buffer;\n\n case arrayBufferTag:\n if ((object.byteLength != other.byteLength) ||\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n return false;\n }\n return true;\n\n case boolTag:\n case dateTag:\n case numberTag:\n // Coerce booleans to `1` or `0` and dates to milliseconds.\n // Invalid dates are coerced to `NaN`.\n return eq(+object, +other);\n\n case errorTag:\n return object.name == other.name && object.message == other.message;\n\n case regexpTag:\n case stringTag:\n // Coerce regexes to strings and treat strings, primitives and objects,\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n // for more details.\n return object == (other + '');\n\n case mapTag:\n var convert = mapToArray;\n\n case setTag:\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n convert || (convert = setToArray);\n\n if (object.size != other.size && !isPartial) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked) {\n return stacked == other;\n }\n bitmask |= COMPARE_UNORDERED_FLAG;\n\n // Recursively compare objects (susceptible to call stack limits).\n stack.set(object, other);\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n stack['delete'](object);\n return result;\n\n case symbolTag:\n if (symbolValueOf) {\n return symbolValueOf.call(object) == symbolValueOf.call(other);\n }\n }\n return false;\n}\n\nexport default equalByTag;\n","/**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\nfunction arrayPush(array, values) {\n var index = -1,\n length = values.length,\n offset = array.length;\n\n while (++index < length) {\n array[offset + index] = values[index];\n }\n return array;\n}\n\nexport default arrayPush;\n","/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\nexport default isArray;\n","import arrayPush from './_arrayPush.js';\nimport isArray from './isArray.js';\n\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\nexport default baseGetAllKeys;\n","/**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\nfunction arrayFilter(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result[resIndex++] = value;\n }\n }\n return result;\n}\n\nexport default arrayFilter;\n","/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n return [];\n}\n\nexport default stubArray;\n","import arrayFilter from './_arrayFilter.js';\nimport stubArray from './stubArray.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n\n/**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n if (object == null) {\n return [];\n }\n object = Object(object);\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\n return propertyIsEnumerable.call(object, symbol);\n });\n};\n\nexport default getSymbols;\n","/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\nexport default baseTimes;\n","import baseGetTag from './_baseGetTag.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]';\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\nexport default baseIsArguments;\n","import baseIsArguments from './_baseIsArguments.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n};\n\nexport default isArguments;\n","/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nexport default stubFalse;\n","import root from './_root.js';\nimport stubFalse from './stubFalse.js';\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nexport default isBuffer;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/** Used to detect unsigned integer values. */\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\nfunction isIndex(value, length) {\n var type = typeof value;\n length = length == null ? MAX_SAFE_INTEGER : length;\n\n return !!length &&\n (type == 'number' ||\n (type != 'symbol' && reIsUint.test(value))) &&\n (value > -1 && value % 1 == 0 && value < length);\n}\n\nexport default isIndex;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nexport default isLength;\n","import baseGetTag from './_baseGetTag.js';\nimport isLength from './isLength.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nexport default baseIsTypedArray;\n","/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\nexport default baseUnary;\n","import freeGlobal from './_freeGlobal.js';\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\nexport default nodeUtil;\n","import baseIsTypedArray from './_baseIsTypedArray.js';\nimport baseUnary from './_baseUnary.js';\nimport nodeUtil from './_nodeUtil.js';\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nexport default isTypedArray;\n","import baseTimes from './_baseTimes.js';\nimport isArguments from './isArguments.js';\nimport isArray from './isArray.js';\nimport isBuffer from './isBuffer.js';\nimport isIndex from './_isIndex.js';\nimport isTypedArray from './isTypedArray.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default arrayLikeKeys;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\nexport default isPrototype;\n","/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\nexport default overArg;\n","import overArg from './_overArg.js';\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nexport default nativeKeys;\n","import isPrototype from './_isPrototype.js';\nimport nativeKeys from './_nativeKeys.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default baseKeys;\n","import isFunction from './isFunction.js';\nimport isLength from './isLength.js';\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\nexport default isArrayLike;\n","import arrayLikeKeys from './_arrayLikeKeys.js';\nimport baseKeys from './_baseKeys.js';\nimport isArrayLike from './isArrayLike.js';\n\n/**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\nfunction keys(object) {\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n}\n\nexport default keys;\n","import baseGetAllKeys from './_baseGetAllKeys.js';\nimport getSymbols from './_getSymbols.js';\nimport keys from './keys.js';\n\n/**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeys(object) {\n return baseGetAllKeys(object, keys, getSymbols);\n}\n\nexport default getAllKeys;\n","import getAllKeys from './_getAllKeys.js';\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n objProps = getAllKeys(object),\n objLength = objProps.length,\n othProps = getAllKeys(other),\n othLength = othProps.length;\n\n if (objLength != othLength && !isPartial) {\n return false;\n }\n var index = objLength;\n while (index--) {\n var key = objProps[index];\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n return false;\n }\n }\n // Check that cyclic values are equal.\n var objStacked = stack.get(object);\n var othStacked = stack.get(other);\n if (objStacked && othStacked) {\n return objStacked == other && othStacked == object;\n }\n var result = true;\n stack.set(object, other);\n stack.set(other, object);\n\n var skipCtor = isPartial;\n while (++index < objLength) {\n key = objProps[index];\n var objValue = object[key],\n othValue = other[key];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, objValue, key, other, object, stack)\n : customizer(objValue, othValue, key, object, other, stack);\n }\n // Recursively compare objects (susceptible to call stack limits).\n if (!(compared === undefined\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n : compared\n )) {\n result = false;\n break;\n }\n skipCtor || (skipCtor = key == 'constructor');\n }\n if (result && !skipCtor) {\n var objCtor = object.constructor,\n othCtor = other.constructor;\n\n // Non `Object` object instances with different constructors are not equal.\n if (objCtor != othCtor &&\n ('constructor' in object && 'constructor' in other) &&\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n result = false;\n }\n }\n stack['delete'](object);\n stack['delete'](other);\n return result;\n}\n\nexport default equalObjects;\n","import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nexport default DataView;\n","import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nexport default Promise;\n","import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nexport default Set;\n","import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nexport default WeakMap;\n","import DataView from './_DataView.js';\nimport Map from './_Map.js';\nimport Promise from './_Promise.js';\nimport Set from './_Set.js';\nimport WeakMap from './_WeakMap.js';\nimport baseGetTag from './_baseGetTag.js';\nimport toSource from './_toSource.js';\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n setTag = '[object Set]',\n weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\nexport default getTag;\n","import Stack from './_Stack.js';\nimport equalArrays from './_equalArrays.js';\nimport equalByTag from './_equalByTag.js';\nimport equalObjects from './_equalObjects.js';\nimport getTag from './_getTag.js';\nimport isArray from './isArray.js';\nimport isBuffer from './isBuffer.js';\nimport isTypedArray from './isTypedArray.js';\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n var objIsArr = isArray(object),\n othIsArr = isArray(other),\n objTag = objIsArr ? arrayTag : getTag(object),\n othTag = othIsArr ? arrayTag : getTag(other);\n\n objTag = objTag == argsTag ? objectTag : objTag;\n othTag = othTag == argsTag ? objectTag : othTag;\n\n var objIsObj = objTag == objectTag,\n othIsObj = othTag == objectTag,\n isSameTag = objTag == othTag;\n\n if (isSameTag && isBuffer(object)) {\n if (!isBuffer(other)) {\n return false;\n }\n objIsArr = true;\n objIsObj = false;\n }\n if (isSameTag && !objIsObj) {\n stack || (stack = new Stack);\n return (objIsArr || isTypedArray(object))\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n }\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n if (objIsWrapped || othIsWrapped) {\n var objUnwrapped = objIsWrapped ? object.value() : object,\n othUnwrapped = othIsWrapped ? other.value() : other;\n\n stack || (stack = new Stack);\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n }\n }\n if (!isSameTag) {\n return false;\n }\n stack || (stack = new Stack);\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n}\n\nexport default baseIsEqualDeep;\n","import baseIsEqualDeep from './_baseIsEqualDeep.js';\nimport isObjectLike from './isObjectLike.js';\n\n/**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Unordered comparison\n * 2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\nfunction baseIsEqual(value, other, bitmask, customizer, stack) {\n if (value === other) {\n return true;\n }\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n return value !== value && other !== other;\n }\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n}\n\nexport default baseIsEqual;\n","import baseIsEqual from './_baseIsEqual.js';\n\n/**\n * Performs a deep comparison between two values to determine if they are\n * equivalent.\n *\n * **Note:** This method supports comparing arrays, array buffers, booleans,\n * date objects, error objects, maps, numbers, `Object` objects, regexes,\n * sets, strings, symbols, and typed arrays. `Object` objects are compared\n * by their own, not inherited, enumerable properties. Functions and DOM\n * nodes are compared by strict equality, i.e. `===`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.isEqual(object, other);\n * // => true\n *\n * object === other;\n * // => false\n */\nfunction isEqual(value, other) {\n return baseIsEqual(value, other);\n}\n\nexport default isEqual;\n"],"names":["isObject","value","type","freeGlobal","freeSelf","root","now","reWhitespace","trimmedEndIndex","string","index","reTrimStart","baseTrim","Symbol","objectProto","hasOwnProperty","nativeObjectToString","symToStringTag","getRawTag","isOwn","tag","unmasked","result","objectToString","nullTag","undefinedTag","baseGetTag","isObjectLike","symbolTag","isSymbol","NAN","reIsBadHex","reIsBinary","reIsOctal","freeParseInt","toNumber","other","isBinary","FUNC_ERROR_TEXT","nativeMax","nativeMin","debounce","func","wait","options","lastArgs","lastThis","maxWait","timerId","lastCallTime","lastInvokeTime","leading","maxing","trailing","invokeFunc","time","args","thisArg","leadingEdge","timerExpired","remainingWait","timeSinceLastCall","timeSinceLastInvoke","timeWaiting","shouldInvoke","trailingEdge","cancel","flush","debounced","isInvoking","listCacheClear","eq","assocIndexOf","array","key","length","arrayProto","splice","listCacheDelete","data","lastIndex","listCacheGet","listCacheHas","listCacheSet","ListCache","entries","entry","stackClear","stackDelete","stackGet","stackHas","asyncTag","funcTag","genTag","proxyTag","isFunction","coreJsData","maskSrcKey","uid","isMasked","funcProto","funcToString","toSource","reRegExpChar","reIsHostCtor","reIsNative","baseIsNative","pattern","getValue","object","getNative","Map","nativeCreate","hashClear","hashDelete","HASH_UNDEFINED","hashGet","hashHas","hashSet","Hash","mapCacheClear","isKeyable","getMapData","map","mapCacheDelete","mapCacheGet","mapCacheHas","mapCacheSet","size","MapCache","LARGE_ARRAY_SIZE","stackSet","pairs","Stack","setCacheAdd","setCacheHas","SetCache","values","arraySome","predicate","cacheHas","cache","COMPARE_PARTIAL_FLAG","COMPARE_UNORDERED_FLAG","equalArrays","bitmask","customizer","equalFunc","stack","isPartial","arrLength","othLength","arrStacked","othStacked","seen","arrValue","othValue","compared","othIndex","Uint8Array","mapToArray","setToArray","set","boolTag","dateTag","errorTag","mapTag","numberTag","regexpTag","setTag","stringTag","arrayBufferTag","dataViewTag","symbolProto","symbolValueOf","equalByTag","convert","stacked","arrayPush","offset","isArray","baseGetAllKeys","keysFunc","symbolsFunc","arrayFilter","resIndex","stubArray","propertyIsEnumerable","nativeGetSymbols","getSymbols","symbol","baseTimes","n","iteratee","argsTag","baseIsArguments","isArguments","stubFalse","freeExports","freeModule","moduleExports","Buffer","nativeIsBuffer","isBuffer","MAX_SAFE_INTEGER","reIsUint","isIndex","isLength","arrayTag","objectTag","weakMapTag","float32Tag","float64Tag","int8Tag","int16Tag","int32Tag","uint8Tag","uint8ClampedTag","uint16Tag","uint32Tag","typedArrayTags","baseIsTypedArray","baseUnary","freeProcess","nodeUtil","types","nodeIsTypedArray","isTypedArray","arrayLikeKeys","inherited","isArr","isArg","isBuff","isType","skipIndexes","isPrototype","Ctor","proto","overArg","transform","arg","nativeKeys","baseKeys","isArrayLike","keys","getAllKeys","equalObjects","objProps","objLength","othProps","objStacked","skipCtor","objValue","objCtor","othCtor","DataView","Promise","Set","WeakMap","promiseTag","dataViewCtorString","mapCtorString","promiseCtorString","setCtorString","weakMapCtorString","getTag","ctorString","getTag$1","baseIsEqualDeep","objIsArr","othIsArr","objTag","othTag","objIsObj","othIsObj","isSameTag","objIsWrapped","othIsWrapped","objUnwrapped","othUnwrapped","baseIsEqual","isEqual"],"mappings":"AAyBA,SAASA,EAASC,EAAO,CACvB,IAAIC,EAAO,OAAOD,EAClB,OAAOA,GAAS,OAASC,GAAQ,UAAYA,GAAQ,WACvD,CC3BA,IAAIC,GAAa,OAAO,QAAU,UAAY,QAAU,OAAO,SAAW,QAAU,OCEhFC,GAAW,OAAO,MAAQ,UAAY,MAAQ,KAAK,SAAW,QAAU,KAGxE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GAAgBC,EAAc,CAChC,IAAIC,EAAeF,EAAevK,EAAO,MAAO,EAAGA,EAC/C0K,EAAeF,EAAejP,EAAM,MAAK,EAAKA,EAElD,OAAAgH,IAAUA,EAAQ,IAAIf,GACfc,EAAUmI,EAAcC,EAActI,EAASC,EAAYE,CAAK,CACxE,CACF,CACD,OAAK+H,GAGL/H,IAAUA,EAAQ,IAAIf,GACfiH,GAAazI,EAAQzE,EAAO6G,EAASC,EAAYC,EAAWC,CAAK,GAH/D,EAIX,CC/DA,SAASoI,GAAYvR,EAAOmC,EAAO6G,EAASC,EAAYE,EAAO,CAC7D,OAAInJ,IAAUmC,EACL,GAELnC,GAAS,MAAQmC,GAAS,MAAS,CAACT,EAAa1B,CAAK,GAAK,CAAC0B,EAAaS,CAAK,EACzEnC,IAAUA,GAASmC,IAAUA,EAE/BwO,GAAgB3Q,EAAOmC,EAAO6G,EAASC,EAAYsI,GAAapI,CAAK,CAC9E,CCKA,SAASqI,GAAQxR,EAAOmC,EAAO,CAC7B,OAAOoP,GAAYvR,EAAOmC,CAAK,CACjC","x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94]}
@@ -1,2 +0,0 @@
1
- import{i as U}from"./lodash-P8OIs-at.esm.js";import{d as R,c as k,i as x,h as K,g as F}from"./events-T3hYV1LF.esm.js";import{logger as I}from"../utils/logger.esm.js";import{initNetworkListeners as G}from"../utils/network-listeners.esm.js";import{createScopedLocalStorage as j}from"../utils/local-storage.esm.js";import{memoizeLast as A}from"../utils/memoize-last.esm.js";import"./promoManager-YUzbMtwY.esm.js";import{B as h}from"./cart-contents-h60geKWa.esm.js";import{O as E}from"./update-cart-UuMHYehB.esm.js";import{W as M,D as W}from"./routes-o-phF_L1.esm.js";import{getExternalCartId as S,getBeamCartId as _}from"../utils/cart.esm.js";import"../components/post-purchase.esm.js";import{waitForElement as q}from"../utils/wait-for-element.esm.js";import{B as z}from"./beam-errors-AMvTvR1C.esm.js";import{getCookieValue as H}from"../utils/cookies.esm.js";const N=window.Shopify?.routes?.root||"/";let P=!1;const B="cart";async function V(e){if(P)return!1;G(),window.addEventListener(R.eventName,async r=>{const t=r,n=/cart\/(add|change|update|clear)/,a=t.detail.type==="xhr"?t.detail.xhr.responseURL:t.detail.response.url,d=new URL(a);if(!n.test(d.pathname))return;const o=await O(e);o.changed&&E(e,o.cart)});let s,c;window.addEventListener(k.eventName,async r=>{const t=r;I.debug("[cart-page][BeamNonprofitSelectEvent]",t.detail);const{source:n,selectedNonprofitId:a,selectionId:d}=t.detail;if(n===M.select_nonprofit){const o=S(B,e),l=_(h,e),{chainId:p,storeId:u}=e;if(s===a&&c===d)return;await g({selectedNonprofitId:a,selectionId:d,beamCartId:l||void 0,cartId:o||void 0,chainId:p,storeId:u}),c=d,s=a}}),window.addEventListener(x.eventName,async r=>{const t=r;I.debug("[cart-page][BeamNonprofitSelectionRemovedEvent]",t.detail);const{newNonprofitId:n,selectionId:a}=t.detail,d=S(B,e),o=_(h,e),{chainId:l,storeId:p}=e;s===n&&c===a||(await g({selectedNonprofitId:n,beamCartId:o||void 0,selectionId:a,cartId:d||void 0,chainId:l,storeId:p}),c=a,s=n)}),window.addEventListener(K.eventName,r=>{const t=r;I.debug("[cart-page][BeamCartCreatedEvent]",t.detail),L(e)}),window.addEventListener(F.eventName,async r=>{const t=r;I.debug("[cart-page][BeamCartChangeEvent]",t.detail),L(e)});const m=await O(e);return await E(e,m.cart,!0),P=!0,!0}async function L(e){let s,c;try{if(window.statsig){const m=window.statsig;s=m.getLayer("beam_trial_layer").get("show_beam",!1),c=m.getStableID();const r=S(B,e),t=_(h,e),{chainId:n,storeId:a}=e;g({showBeam:s,remoteSessionId:c,beamCartId:t||void 0,cartId:r||void 0,chainId:n,storeId:a})}}catch(m){I.error(m)}}async function O(e){const{token:s,total_price:c,item_count:m,currency:r,items:t,cart_level_discount_applications:n}=await T();let a=!1;const d=j(e).getItemJson("cart"),o=_(h,e),l={cartId:s,beamCartId:o,subtotal:c/100,itemCount:m,currencyCode:r,schema:{source:"generic"},content:{items:t.map(({sku:p,final_line_price:u,product_id:y,line_level_discount_allocations:C})=>{const b=p||String(y),v=u/100,f=C?.map(({discount_application:w})=>({code:w?.title,applicable:!0}));return{remoteProductIdentifier:b,localAmount:v,discounts:f}}),discounts:n.map(({title:p})=>({code:p,applicable:!0}))}};return U(l,{...d,beamCartId:d?.beamCartId})||(a=!0),{changed:a,cart:l}}const $=E,T=async function(){return await window.fetch(N+"cart.js",{method:"GET",headers:{"Content-Type":"application/json"}}).then(e=>e.json())},g=A(async function({selectedNonprofitId:e,selectionId:s,beamCartId:c,cartId:m,chainId:r,storeId:t,showBeam:n,remoteSessionId:a}){const{attributes:d}=await T(),o=d?.beam;let l={};try{o&&(l=JSON.parse(o))}catch(u){I.error(u)}const p={beam:JSON.stringify({...l,nonprofit_id:e,selection_id:s,beam_cart_id:c,shopify_cart_id:m,chain_id:r,store_id:t,show_beam:n,remote_session_id:a})};if(!U(p.beam,l))try{await window.fetch(N+"cart/update.js",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({attributes:p})})}catch(u){I.error(u)}}),Q=A(async function({selectedNonprofitId:e,selectionId:s,beamCartId:c,cartId:m,chainId:r,storeId:t}){let n,a;try{if(window.statsig){const o=window.statsig;n=o.getLayer("beam_trial_layer").get("show_beam",!1),a=o.getStableID()}}catch(o){I.error(o)}const d={beam:JSON.stringify({nonprofit_id:e,selection_id:s,beam_cart_id:c,shopify_cart_id:m,chain_id:r,store_id:t,show_beam:n,remote_session_id:a})};try{await window.fetch(N+"cart/update.js",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({attributes:d})})}catch(o){I.error(o)}});async function X({parentSelector:e=".step__sections",apiKey:s,baseUrl:c=W,storeId:m,postalCode:r,discountCodes:t,countryCode:n,orderId:a,email:d,cartTotal:o,cart:l,promoCodes:p,htmlPromoCodes:u,currencyCode:y="USD",domain:C,lang:b="en",debug:v=!1}){const f=document.querySelector(e)||await q(e);if(!f)throw new z(`Timed out waiting for selector '${e}'. Could not render Beam post-purchase widget.`);const w=await H("cart");if(w){const J=j({apiKey:s}),D=J.getItemJson("cart")||{};J.setItemJson("cart",{...D,cartId:w})}const i=document.createElement("beam-post-purchase");i.apiKey=s,i.baseUrl=c,i.storeId=m,i.postalCode=r,i.countryCode=n,i.orderId=String(a),i.email=d,i.cartTotal=o,i.cart=l,i.promoCodes=p,i.htmlPromoCodes=u,i.discountCodes=t,i.currencyCode=y,i.domain=C,i.lang=b,i.debug=v,f.appendChild(i)}export{V as F,$ as G,Q as H,L as S,O as _,g,X as s,T as v};
2
- //# sourceMappingURL=order-page-WPxvCNLM.esm.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"order-page-WPxvCNLM.esm.js","sources":["../../src/integrations/shopify/cart-page.ts","../../src/integrations/shopify/order-page.ts"],"sourcesContent":["/* eslint-disable camelcase */\nimport isEqual from \"lodash-es/isEqual\";\nimport { logger, memoizeLast } from \"../../utils\";\nimport { initNetworkListeners } from \"../../utils/network-listeners\";\nimport {\n BeamCartChangeEvent,\n BeamCartCreatedEvent,\n BeamNetworkCallEvent,\n BeamNonprofitSelectEvent,\n BeamNonprofitSelectionRemovedEvent,\n} from \"../../utils/events\";\nimport { createScopedLocalStorage } from \"../../utils/local-storage\";\nimport { BEAM_CART_COOKIE_NAME, TBeamCartLocalStorage, TCart, TCartItems } from \"../../shared/cart-contents\";\nimport { BeamCartAPIConfig, updateCart } from \"../cart\";\nimport { WIDGET_NAMES } from \"../../api-sdk/constants\";\nimport { getBeamCartId, getExternalCartId } from \"../../utils/cart\";\n\nexport type BeamShopifyCartIntegrationConfig = BeamCartAPIConfig & {\n storeId: number; // will be added to cart custom_attributes, and used in cart API call\n chainId?: number; // will be added to cart custom_attributes\n};\n\ntype ShopifyDiscountApplication = {\n title: string;\n value: string;\n};\n\ntype ShopifyLineLevelDiscountAllocations = {\n amount?: string;\n discount_application: ShopifyDiscountApplication;\n};\n\nconst SHOPIFY_BASE_URL = window.Shopify?.routes?.root || \"/\"; // see window.d.ts\n\nlet isBeamCartIntegrationRegistered = false; // Skip registering event listeners if already set up\n\nconst SHOPIFY_CART_COOKIE_NAME = \"cart\";\n\n/**\n * @main registerCartIntegration - set up event listeners to integrate Beam with Shopify cart\n * @return {boolean} returns true if NEW listeners were created, false if setup was already done\n */\nasync function registerCartIntegration(config: BeamShopifyCartIntegrationConfig) {\n if (isBeamCartIntegrationRegistered) {\n return false; // Do nothing if listeners are already attached\n }\n\n // logger.debug(\"[cart-page][registerCartIntegration] initializing network listeners\");\n // Set up event listeners for AJAX events\n initNetworkListeners();\n\n window.addEventListener(BeamNetworkCallEvent.eventName, async (_event: Event) => {\n const event = _event as BeamNetworkCallEvent;\n const cartChangePaths = /cart\\/(add|change|update|clear)/;\n // note: response urls below follow redirects\n const requestUrlStr = event.detail.type === \"xhr\" ? event.detail.xhr.responseURL : event.detail.response.url;\n const url = new URL(requestUrlStr);\n if (!cartChangePaths.test(url.pathname)) {\n return;\n }\n // logger.debug(\"[cart-page][BeamNetworkCallEvent] getting current cart\");\n const currentCart = await getCurrentCart(config);\n if (!currentCart.changed) {\n // logger.debug(`[cart-page][BeamNetworkCallEvent] cart has not changed from URL ${requestUrlStr}`, currentCart.cart);\n return;\n }\n // Send cart to Beam to update timestamp, which is used for cart abandonment / ROI calc\n // logger.debug(`[cart-page][BeamNetworkCallEvent] cart has changed from URL ${requestUrlStr}`, currentCart.cart);\n updateCart(config, currentCart.cart);\n });\n\n // Listen to Beam's own events to integrate Beam data into Shopify order\n let lastNonprofitId: number | null | undefined;\n let lastSelectionId: string | null | undefined;\n window.addEventListener(BeamNonprofitSelectEvent.eventName, async (_event) => {\n const event = _event as BeamNonprofitSelectEvent;\n logger.debug(\"[cart-page][BeamNonprofitSelectEvent]\", event.detail);\n const { source, selectedNonprofitId, selectionId } = event.detail;\n\n if (source === WIDGET_NAMES.select_nonprofit) {\n const cartId = getExternalCartId(SHOPIFY_CART_COOKIE_NAME, config); // Shopify cart ID\n const beamCartId = getBeamCartId(BEAM_CART_COOKIE_NAME, config); // Beam cart ID\n const { chainId, storeId } = config;\n // Skip update if nothing changed (can happen if widget is re-initialized and\n // emits event after cache restoration, i.e., on cart re-render).\n if (lastNonprofitId === selectedNonprofitId && lastSelectionId === selectionId) {\n return;\n }\n await appendBeamAttributesToCart({\n selectedNonprofitId,\n selectionId,\n beamCartId: beamCartId ? beamCartId : undefined,\n cartId: cartId ? cartId : undefined,\n chainId,\n storeId,\n });\n lastSelectionId = selectionId;\n lastNonprofitId = selectedNonprofitId;\n }\n });\n\n /**\n * Upon removal of the selected nonprofit from the widget and local storage,\n * an event is emitted and that event is then used to update the cart attributes accordingly\n * This event listener updates the cart attributes based on the emitted event\n */\n window.addEventListener(BeamNonprofitSelectionRemovedEvent.eventName, async (_event) => {\n const event = _event as BeamNonprofitSelectionRemovedEvent;\n logger.debug(\"[cart-page][BeamNonprofitSelectionRemovedEvent]\", event.detail);\n const { newNonprofitId, selectionId } = event.detail;\n\n const cartId = getExternalCartId(SHOPIFY_CART_COOKIE_NAME, config);\n const beamCartId = getBeamCartId(BEAM_CART_COOKIE_NAME, config);\n const { chainId, storeId } = config;\n if (lastNonprofitId === newNonprofitId && lastSelectionId === selectionId) {\n return;\n }\n await appendBeamAttributesToCart({\n selectedNonprofitId: newNonprofitId,\n beamCartId: beamCartId ? beamCartId : undefined,\n selectionId,\n cartId: cartId ? cartId : undefined,\n chainId,\n storeId,\n });\n lastSelectionId = selectionId;\n lastNonprofitId = newNonprofitId;\n });\n\n /**\n * When a BeamCart is created, write beam metadata to the Shopify cart if\n * we need to capture it for Statsig\n */\n window.addEventListener(BeamCartCreatedEvent.eventName, (_event: Event) => {\n const event = _event as BeamCartCreatedEvent;\n logger.debug(\"[cart-page][BeamCartCreatedEvent]\", event.detail);\n appendStatsigToShopifyCartAttributes(config);\n });\n\n /**\n * On any cart changes, write beam metadata to the Shopify cart if\n * we need to capture it for Statsig\n */\n window.addEventListener(BeamCartChangeEvent.eventName, async (_event: Event) => {\n const event = _event as BeamCartChangeEvent;\n logger.debug(\"[cart-page][BeamCartChangeEvent]\", event.detail);\n appendStatsigToShopifyCartAttributes(config);\n });\n\n // Handle full-page load, ie, first-time page load and reloads from form submit events\n // This creates a GET to /cart.js\n // logger.debug(\"[cart-page][registerCartIntegration] getting current cart\");\n const currentCart = await getCurrentCart(config);\n // logger.debug(\"[cart-page][registerCartIntegration] initial cart fetch result\", currentCart);\n await updateCart(config, currentCart.cart, true);\n\n isBeamCartIntegrationRegistered = true;\n\n return true;\n}\n\n/* ***************************************** HELPER FUNCTIONS *****************************************\n These may be used individually to integrate with carts if the registerCartIntegration\n script doesn't work for some reason.\n ****************************************************************************************************/\n\n/**\n * Adds Statsig data to a Shopify cart\n */\nasync function appendStatsigToShopifyCartAttributes(config: BeamShopifyCartIntegrationConfig) {\n let showBeam;\n let remoteSessionId;\n try {\n if (window.statsig) {\n const statsig = window.statsig as any;\n showBeam = statsig.getLayer(\"beam_trial_layer\").get(\"show_beam\", false /* default to hide */) as boolean;\n remoteSessionId = statsig.getStableID();\n\n const cartId = getExternalCartId(SHOPIFY_CART_COOKIE_NAME, config);\n const beamCartId = getBeamCartId(BEAM_CART_COOKIE_NAME, config);\n const { chainId, storeId } = config;\n\n /**\n * When a Beam cart is created, we need to ensure that the\n * Statsig properties get added to the \"beam\" cart property\n */\n appendBeamAttributesToCart({\n showBeam: showBeam,\n remoteSessionId: remoteSessionId,\n beamCartId: beamCartId ? beamCartId : undefined,\n cartId: cartId ? cartId : undefined,\n chainId,\n storeId,\n });\n }\n } catch (e) {\n logger.error(e);\n }\n}\n\n/**\n * Detects change in cart since last page load,\n * by calling GET /cart.js, and returns cart values.\n * Used for:\n * - Form-based carts where the page refreshes to modify cart instead of using AJAX calls\n * - Hydrogen/GraphQL based carts (needs to be integrated manually)\n */\nasync function getCurrentCart(config: BeamShopifyCartIntegrationConfig): Promise<{\n changed: boolean;\n cart: {\n cartId: string;\n subtotal: number;\n itemCount: number;\n currencyCode: string;\n } & TCart;\n}> {\n const {\n token, // equal to \"cart\" cookie\n total_price, // this is the pretax value, after discounts, and multiplied by 100 (integer from decimal)\n item_count,\n currency,\n items,\n cart_level_discount_applications,\n } = await getShopifyCart();\n\n let changed = false;\n\n const localStorage = createScopedLocalStorage(config);\n\n // The cart cache is used to detect changes after page refreshes / across tabs\n const cachedCart: TBeamCartLocalStorage | null = localStorage.getItemJson(\"cart\");\n // The Beam cart cookie is used to identify the cart across subdomains\n // Use explicit null if empty because API requires it\n const beamCartId: string | null = getBeamCartId(BEAM_CART_COOKIE_NAME, config);\n\n const cart = {\n cartId: token,\n beamCartId,\n subtotal: total_price / 100,\n itemCount: item_count,\n currencyCode: currency,\n schema: { source: \"generic\" } as const,\n content: {\n // pull out minimal fields from full line items\n items: (items as TCartItems).map(({ sku, final_line_price, product_id, line_level_discount_allocations }) => {\n const remoteProductIdentifier = sku || String(product_id);\n const localAmount = final_line_price / 100;\n const discounts = (line_level_discount_allocations as ShopifyLineLevelDiscountAllocations[])?.map(\n ({ discount_application }) => {\n return { code: discount_application?.title, applicable: true };\n }\n );\n return { remoteProductIdentifier, localAmount, discounts };\n }),\n discounts: (cart_level_discount_applications as ShopifyDiscountApplication[]).map(({ title }) => {\n return { code: title, applicable: true };\n }),\n },\n };\n\n if (\n !isEqual(cart, {\n ...cachedCart,\n beamCartId: cachedCart?.beamCartId,\n })\n ) {\n changed = true;\n }\n\n // logger.debug(\"[cart-page][getCurrentCart] has cart changed?\", changed, cart);\n\n return { changed, cart };\n}\n\n/**\n * trackCart - Backwards-compatible alias for updateCart\n */\nconst trackCart = updateCart;\n\n/**\n * Helper function to get the Shopify cart attributes\n */\nconst getShopifyCart = async function () {\n const cart = await window\n .fetch(SHOPIFY_BASE_URL + \"cart.js\", {\n method: \"GET\",\n headers: { \"Content-Type\": \"application/json\" },\n })\n .then((res) => res.json());\n return cart;\n};\n\n/**\n * Sends Beam data to Shopify to integrate with order as custom attributes.\n * Memoized so that calls with the same data as the previous don't create additional API calls to Shopify.\n * This will do an append, not a full overwrite of the attributes in the beam property\n */\nconst appendBeamAttributesToCart = memoizeLast(async function appendBeamAttributesToCart({\n selectedNonprofitId,\n selectionId,\n beamCartId,\n cartId,\n chainId,\n storeId,\n showBeam,\n remoteSessionId,\n}: {\n selectedNonprofitId?: number | null;\n selectionId?: string;\n beamCartId?: string;\n cartId?: string;\n chainId?: number;\n storeId?: number;\n showBeam?: boolean;\n remoteSessionId?: string;\n}) {\n const { attributes } = await getShopifyCart();\n\n // Get only the Beam attribute, if it exists\n const existingBeamCartAttrString = attributes?.beam;\n let existingBeamCartAttr = {};\n try {\n if (existingBeamCartAttrString) {\n existingBeamCartAttr = JSON.parse(existingBeamCartAttrString);\n }\n } catch (err) {\n logger.error(err);\n }\n\n const beamCartAttrs = {\n beam: JSON.stringify({\n ...existingBeamCartAttr,\n nonprofit_id: selectedNonprofitId,\n selection_id: selectionId,\n beam_cart_id: beamCartId,\n shopify_cart_id: cartId,\n chain_id: chainId,\n store_id: storeId,\n show_beam: showBeam,\n remote_session_id: remoteSessionId,\n }),\n };\n\n // If the attributes match, no reason to update the cart\n if (isEqual(beamCartAttrs.beam, existingBeamCartAttr)) {\n // logger.debug(\"[cart-page][appendBeamAttributesToCart] cart attributes match, skipping update\");\n return;\n }\n\n try {\n await window.fetch(SHOPIFY_BASE_URL + \"cart/update.js\", {\n method: \"POST\",\n headers: { \"Content-Type\": \"application/json\" },\n body: JSON.stringify({ attributes: beamCartAttrs }),\n });\n } catch (err) {\n logger.error(err); // don't throw, allow later calls to continue\n }\n});\n\n/**\n * Sends Beam data to Shopify to integrate with order as custom attributes.\n * Memoized so that calls with the same data as the previous don't create additional API calls to Shopify.\n * This method force-updates the \"beam\" attribute with the values passed in\n */\nconst addBeamAttributesToCart = memoizeLast(async function addBeamAttributesToCart({\n selectedNonprofitId,\n selectionId,\n beamCartId,\n cartId,\n chainId,\n storeId,\n}: {\n selectedNonprofitId?: number | null;\n selectionId?: string;\n beamCartId?: string;\n cartId?: string;\n chainId?: number;\n storeId?: number;\n}) {\n let showBeam;\n let remoteSessionId;\n try {\n if (window.statsig) {\n const statsig = window.statsig as any;\n showBeam = statsig.getLayer(\"beam_trial_layer\").get(\"show_beam\", false /* default to hide */) as boolean;\n remoteSessionId = statsig.getStableID();\n }\n } catch (e) {\n logger.error(e);\n }\n const beamCartAttrs = {\n beam: JSON.stringify({\n nonprofit_id: selectedNonprofitId,\n selection_id: selectionId,\n beam_cart_id: beamCartId,\n shopify_cart_id: cartId,\n chain_id: chainId,\n store_id: storeId,\n show_beam: showBeam,\n remote_session_id: remoteSessionId,\n }),\n };\n\n try {\n await window.fetch(SHOPIFY_BASE_URL + \"cart/update.js\", {\n method: \"POST\",\n headers: { \"Content-Type\": \"application/json\" },\n body: JSON.stringify({ attributes: beamCartAttrs }),\n });\n } catch (err) {\n logger.error(err); // don't throw, allow later calls to continue\n }\n});\n\ndeclare global {\n interface Window {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n statsig?: any; // attached by Statsig CDN script\n }\n}\nexport {\n trackCart,\n getCurrentCart,\n addBeamAttributesToCart,\n appendStatsigToShopifyCartAttributes,\n registerCartIntegration,\n appendBeamAttributesToCart,\n getShopifyCart,\n};\n","import \"../../components/post-purchase\";\nimport { postTransaction } from \"../../api-sdk/v3/routes\";\nimport { DEFAULT_BASE_URL } from \"../../api-sdk/constants\";\nimport { LANGUAGES, TUrl } from \"../../api-sdk/types\";\nimport { waitForElement } from \"../../utils/wait-for-element\";\nimport { BeamError } from \"../../utils/beam-errors\";\nimport { getCookieValue } from \"../../utils/cookies\";\nimport { createScopedLocalStorage } from \"../../utils/local-storage\";\nimport { TCart } from \"../../shared/cart-contents\";\n\n// Shopify admin page: admin/settings/checkout\n\nexport type TBeamOrderPageParams = Parameters<typeof postTransaction>[0][\"requestBody\"] & {\n // Either storeId or postalCode + countryCode must be provided\n storeId?: number;\n postalCode?: string;\n countryCode?: string;\n orderId: string;\n email: string;\n cartTotal: number;\n cart: TCart;\n discountCodes: string[];\n promoCodes: string[];\n htmlPromoCodes: string;\n currencyCode: string;\n parentSelector: string; // CSS Selector for parent of widget to be inserted into DOM\n apiKey: string;\n baseUrl: TUrl;\n domain?: string; // Base domain for setting cookies\n lang: LANGUAGES;\n debug: boolean;\n};\n\nexport async function showBeamOrderPageWidgets({\n parentSelector = \".step__sections\",\n apiKey,\n baseUrl = DEFAULT_BASE_URL,\n storeId,\n postalCode,\n discountCodes,\n countryCode,\n orderId,\n email,\n cartTotal,\n cart,\n promoCodes,\n htmlPromoCodes,\n currencyCode = \"USD\",\n domain,\n lang = \"en\",\n debug = false,\n}: TBeamOrderPageParams) {\n const parentElement = document.querySelector(parentSelector) || (await waitForElement(parentSelector));\n if (!parentElement) {\n throw new BeamError(\n `Timed out waiting for selector '${parentSelector}'. Could not render Beam post-purchase widget.`\n );\n }\n\n // If checkout and order page are on different subdomains, we can't access localStorage\n // We can make postTransaction work by copying the cart cookie to the expected localStorage key on the current domain\n const cartId = await getCookieValue(\"cart\"); // Shopify-only cart identifier\n if (cartId) {\n const beamLocalStorage = createScopedLocalStorage({ apiKey });\n const existingValue = beamLocalStorage.getItemJson(\"cart\") || {};\n beamLocalStorage.setItemJson(\"cart\", { ...existingValue, cartId });\n }\n\n // Note: assign properties one by one instead of bulk Object.assign to type check assignments\n const widget = document.createElement(\"beam-post-purchase\");\n widget.apiKey = apiKey;\n widget.baseUrl = baseUrl;\n widget.storeId = storeId;\n widget.postalCode = postalCode;\n widget.countryCode = countryCode;\n widget.orderId = String(orderId);\n widget.email = email;\n widget.cartTotal = cartTotal;\n widget.cart = cart;\n widget.promoCodes = promoCodes;\n widget.htmlPromoCodes = htmlPromoCodes;\n widget.discountCodes = discountCodes;\n widget.currencyCode = currencyCode;\n widget.domain = domain;\n widget.lang = lang;\n widget.debug = debug;\n\n // Insert widget into DOM\n parentElement.appendChild(widget);\n}\n"],"names":["SHOPIFY_BASE_URL","isBeamCartIntegrationRegistered","SHOPIFY_CART_COOKIE_NAME","registerCartIntegration","config","initNetworkListeners","BeamNetworkCallEvent","_event","event","cartChangePaths","requestUrlStr","url","currentCart","getCurrentCart","updateCart","lastNonprofitId","lastSelectionId","BeamNonprofitSelectEvent","logger","source","selectedNonprofitId","selectionId","WIDGET_NAMES","cartId","getExternalCartId","beamCartId","getBeamCartId","BEAM_CART_COOKIE_NAME","chainId","storeId","appendBeamAttributesToCart","BeamNonprofitSelectionRemovedEvent","newNonprofitId","BeamCartCreatedEvent","appendStatsigToShopifyCartAttributes","BeamCartChangeEvent","showBeam","remoteSessionId","statsig","e","token","total_price","item_count","currency","items","cart_level_discount_applications","getShopifyCart","changed","cachedCart","createScopedLocalStorage","cart","sku","final_line_price","product_id","line_level_discount_allocations","remoteProductIdentifier","localAmount","discounts","discount_application","title","isEqual","trackCart","res","memoizeLast","attributes","existingBeamCartAttrString","existingBeamCartAttr","err","beamCartAttrs","addBeamAttributesToCart","showBeamOrderPageWidgets","parentSelector","apiKey","baseUrl","DEFAULT_BASE_URL","postalCode","discountCodes","countryCode","orderId","email","cartTotal","promoCodes","htmlPromoCodes","currencyCode","domain","lang","debug","parentElement","waitForElement","BeamError","getCookieValue","beamLocalStorage","existingValue","widget"],"mappings":"w1BAgCA,MAAMA,EAAmB,OAAO,SAAS,QAAQ,MAAQ,IAEzD,IAAIC,EAAkC,GAEtC,MAAMC,EAA2B,OAMjC,eAAeC,EAAwBC,EAA0C,CAC/E,GAAIH,EACF,MAAO,GAKTI,EAAqB,EAErB,OAAO,iBAAiBC,EAAqB,UAAW,MAAOC,GAAkB,CAC/E,MAAMC,EAAQD,EACRE,EAAkB,kCAElBC,EAAgBF,EAAM,OAAO,OA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AAMiD,CAAG,CAClB,CACF,CAAC,EC5XD,eAAsBG,EAAyB,CAC7C,eAAAC,EAAiB,kBACjB,OAAAC,EACA,QAAAC,EAAUC,EACV,QAAA7C,EACA,WAAA8C,EACA,cAAAC,EACA,YAAAC,EACA,QAAAC,EACA,MAAAC,EACA,UAAAC,EACA,KAAA9B,EACA,WAAA+B,EACA,eAAAC,EACA,aAAAC,EAAe,MACf,OAAAC,EACA,KAAAC,EAAO,KACP,MAAAC,EAAQ,EACV,EAAyB,CACvB,MAAMC,EAAgB,SAAS,cAAchB,CAAc,GAAM,MAAMiB,EAAejB,CAAc,EACpG,GAAI,CAACgB,EACH,MAAM,IAAIE,EACR,mCAAmClB,CAAc,gDACnD,EAKF,MAAMhD,EAAS,MAAMmE,EAAe,MAAM,EAC1C,GAAInE,EAAQ,CACV,MAAMoE,EAAmB1C,EAAyB,CAAE,OAAAuB,CAAO,CAAC,EACtDoB,EAAgBD,EAAiB,YAAY,MAAM,GAAK,CAAA,EAC9DA,EAAiB,YAAY,OAAQ,CAAE,GAAGC,EAAe,OAAArE,CAAO,CAAC,CACnE,CAGA,MAAMsE,EAAS,SAAS,cAAc,oBAAoB,EAC1DA,EAAO,OAASrB,EAChBqB,EAAO,QAAUpB,EACjBoB,EAAO,QAAUhE,EACjBgE,EAAO,WAAalB,EACpBkB,EAAO,YAAchB,EACrBgB,EAAO,QAAU,OAAOf,CAAO,EAC/Be,EAAO,MAAQd,EACfc,EAAO,UAAYb,EACnBa,EAAO,KAAO3C,EACd2C,EAAO,WAAaZ,EACpBY,EAAO,eAAiBX,EACxBW,EAAO,cAAgBjB,EACvBiB,EAAO,aAAeV,EACtBU,EAAO,OAAST,EAChBS,EAAO,KAAOR,EACdQ,EAAO,MAAQP,EAGfC,EAAc,YAAYM,CAAM,CAClC"}
@@ -1,2 +0,0 @@
1
- import{i as U}from"./lodash-P8OIs-at.esm.js";import{d as R,c as k,i as x,h as K,g as F}from"./events-T3hYV1LF.esm.js";import{logger as I}from"../utils/logger.js";import{initNetworkListeners as G}from"../utils/network-listeners.js";import{createScopedLocalStorage as j}from"../utils/local-storage.js";import{memoizeLast as A}from"../utils/memoize-last.js";import"./promoManager--3WXq4at.esm.js";import{B as h}from"./cart-contents-h60geKWa.esm.js";import{O as E}from"./update-cart-mNsQ9K-k.esm.js";import{W as M,D as W}from"./routes-YPOoVIR2.esm.js";import{getExternalCartId as S,getBeamCartId as _}from"../utils/cart.js";import"../components/post-purchase.js";import{waitForElement as q}from"../utils/wait-for-element.js";import{B as z}from"./beam-errors-AMvTvR1C.esm.js";import{getCookieValue as H}from"../utils/cookies.js";const N=window.Shopify?.routes?.root||"/";let P=!1;const B="cart";async function V(e){if(P)return!1;G(),window.addEventListener(R.eventName,async r=>{const t=r,n=/cart\/(add|change|update|clear)/,a=t.detail.type==="xhr"?t.detail.xhr.responseURL:t.detail.response.url,d=new URL(a);if(!n.test(d.pathname))return;const o=await O(e);o.changed&&E(e,o.cart)});let s,c;window.addEventListener(k.eventName,async r=>{const t=r;I.debug("[cart-page][BeamNonprofitSelectEvent]",t.detail);const{source:n,selectedNonprofitId:a,selectionId:d}=t.detail;if(n===M.select_nonprofit){const o=S(B,e),l=_(h,e),{chainId:p,storeId:u}=e;if(s===a&&c===d)return;await g({selectedNonprofitId:a,selectionId:d,beamCartId:l||void 0,cartId:o||void 0,chainId:p,storeId:u}),c=d,s=a}}),window.addEventListener(x.eventName,async r=>{const t=r;I.debug("[cart-page][BeamNonprofitSelectionRemovedEvent]",t.detail);const{newNonprofitId:n,selectionId:a}=t.detail,d=S(B,e),o=_(h,e),{chainId:l,storeId:p}=e;s===n&&c===a||(await g({selectedNonprofitId:n,beamCartId:o||void 0,selectionId:a,cartId:d||void 0,chainId:l,storeId:p}),c=a,s=n)}),window.addEventListener(K.eventName,r=>{const t=r;I.debug("[cart-page][BeamCartCreatedEvent]",t.detail),L(e)}),window.addEventListener(F.eventName,async r=>{const t=r;I.debug("[cart-page][BeamCartChangeEvent]",t.detail),L(e)});const m=await O(e);return await E(e,m.cart,!0),P=!0,!0}async function L(e){let s,c;try{if(window.statsig){const m=window.statsig;s=m.getLayer("beam_trial_layer").get("show_beam",!1),c=m.getStableID();const r=S(B,e),t=_(h,e),{chainId:n,storeId:a}=e;g({showBeam:s,remoteSessionId:c,beamCartId:t||void 0,cartId:r||void 0,chainId:n,storeId:a})}}catch(m){I.error(m)}}async function O(e){const{token:s,total_price:c,item_count:m,currency:r,items:t,cart_level_discount_applications:n}=await T();let a=!1;const d=j(e).getItemJson("cart"),o=_(h,e),l={cartId:s,beamCartId:o,subtotal:c/100,itemCount:m,currencyCode:r,schema:{source:"generic"},content:{items:t.map(({sku:p,final_line_price:u,product_id:y,line_level_discount_allocations:C})=>{const b=p||String(y),v=u/100,f=C?.map(({discount_application:w})=>({code:w?.title,applicable:!0}));return{remoteProductIdentifier:b,localAmount:v,discounts:f}}),discounts:n.map(({title:p})=>({code:p,applicable:!0}))}};return U(l,{...d,beamCartId:d?.beamCartId})||(a=!0),{changed:a,cart:l}}const $=E,T=async function(){return await window.fetch(N+"cart.js",{method:"GET",headers:{"Content-Type":"application/json"}}).then(e=>e.json())},g=A(async function({selectedNonprofitId:e,selectionId:s,beamCartId:c,cartId:m,chainId:r,storeId:t,showBeam:n,remoteSessionId:a}){const{attributes:d}=await T(),o=d?.beam;let l={};try{o&&(l=JSON.parse(o))}catch(u){I.error(u)}const p={beam:JSON.stringify({...l,nonprofit_id:e,selection_id:s,beam_cart_id:c,shopify_cart_id:m,chain_id:r,store_id:t,show_beam:n,remote_session_id:a})};if(!U(p.beam,l))try{await window.fetch(N+"cart/update.js",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({attributes:p})})}catch(u){I.error(u)}}),Q=A(async function({selectedNonprofitId:e,selectionId:s,beamCartId:c,cartId:m,chainId:r,storeId:t}){let n,a;try{if(window.statsig){const o=window.statsig;n=o.getLayer("beam_trial_layer").get("show_beam",!1),a=o.getStableID()}}catch(o){I.error(o)}const d={beam:JSON.stringify({nonprofit_id:e,selection_id:s,beam_cart_id:c,shopify_cart_id:m,chain_id:r,store_id:t,show_beam:n,remote_session_id:a})};try{await window.fetch(N+"cart/update.js",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({attributes:d})})}catch(o){I.error(o)}});async function X({parentSelector:e=".step__sections",apiKey:s,baseUrl:c=W,storeId:m,postalCode:r,discountCodes:t,countryCode:n,orderId:a,email:d,cartTotal:o,cart:l,promoCodes:p,htmlPromoCodes:u,currencyCode:y="USD",domain:C,lang:b="en",debug:v=!1}){const f=document.querySelector(e)||await q(e);if(!f)throw new z(`Timed out waiting for selector '${e}'. Could not render Beam post-purchase widget.`);const w=await H("cart");if(w){const J=j({apiKey:s}),D=J.getItemJson("cart")||{};J.setItemJson("cart",{...D,cartId:w})}const i=document.createElement("beam-post-purchase");i.apiKey=s,i.baseUrl=c,i.storeId=m,i.postalCode=r,i.countryCode=n,i.orderId=String(a),i.email=d,i.cartTotal=o,i.cart=l,i.promoCodes=p,i.htmlPromoCodes=u,i.discountCodes=t,i.currencyCode=y,i.domain=C,i.lang=b,i.debug=v,f.appendChild(i)}export{V as F,$ as G,Q as H,L as S,O as _,g,X as s,T as v};
2
- //# sourceMappingURL=order-page-ZpOf35sP.esm.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"order-page-ZpOf35sP.esm.js","sources":["../../src/integrations/shopify/cart-page.ts","../../src/integrations/shopify/order-page.ts"],"sourcesContent":["/* eslint-disable camelcase */\nimport isEqual from \"lodash-es/isEqual\";\nimport { logger, memoizeLast } from \"../../utils\";\nimport { initNetworkListeners } from \"../../utils/network-listeners\";\nimport {\n BeamCartChangeEvent,\n BeamCartCreatedEvent,\n BeamNetworkCallEvent,\n BeamNonprofitSelectEvent,\n BeamNonprofitSelectionRemovedEvent,\n} from \"../../utils/events\";\nimport { createScopedLocalStorage } from \"../../utils/local-storage\";\nimport { BEAM_CART_COOKIE_NAME, TBeamCartLocalStorage, TCart, TCartItems } from \"../../shared/cart-contents\";\nimport { BeamCartAPIConfig, updateCart } from \"../cart\";\nimport { WIDGET_NAMES } from \"../../api-sdk/constants\";\nimport { getBeamCartId, getExternalCartId } from \"../../utils/cart\";\n\nexport type BeamShopifyCartIntegrationConfig = BeamCartAPIConfig & {\n storeId: number; // will be added to cart custom_attributes, and used in cart API call\n chainId?: number; // will be added to cart custom_attributes\n};\n\ntype ShopifyDiscountApplication = {\n title: string;\n value: string;\n};\n\ntype ShopifyLineLevelDiscountAllocations = {\n amount?: string;\n discount_application: ShopifyDiscountApplication;\n};\n\nconst SHOPIFY_BASE_URL = window.Shopify?.routes?.root || \"/\"; // see window.d.ts\n\nlet isBeamCartIntegrationRegistered = false; // Skip registering event listeners if already set up\n\nconst SHOPIFY_CART_COOKIE_NAME = \"cart\";\n\n/**\n * @main registerCartIntegration - set up event listeners to integrate Beam with Shopify cart\n * @return {boolean} returns true if NEW listeners were created, false if setup was already done\n */\nasync function registerCartIntegration(config: BeamShopifyCartIntegrationConfig) {\n if (isBeamCartIntegrationRegistered) {\n return false; // Do nothing if listeners are already attached\n }\n\n // logger.debug(\"[cart-page][registerCartIntegration] initializing network listeners\");\n // Set up event listeners for AJAX events\n initNetworkListeners();\n\n window.addEventListener(BeamNetworkCallEvent.eventName, async (_event: Event) => {\n const event = _event as BeamNetworkCallEvent;\n const cartChangePaths = /cart\\/(add|change|update|clear)/;\n // note: response urls below follow redirects\n const requestUrlStr = event.detail.type === \"xhr\" ? event.detail.xhr.responseURL : event.detail.response.url;\n const url = new URL(requestUrlStr);\n if (!cartChangePaths.test(url.pathname)) {\n return;\n }\n // logger.debug(\"[cart-page][BeamNetworkCallEvent] getting current cart\");\n const currentCart = await getCurrentCart(config);\n if (!currentCart.changed) {\n // logger.debug(`[cart-page][BeamNetworkCallEvent] cart has not changed from URL ${requestUrlStr}`, currentCart.cart);\n return;\n }\n // Send cart to Beam to update timestamp, which is used for cart abandonment / ROI calc\n // logger.debug(`[cart-page][BeamNetworkCallEvent] cart has changed from URL ${requestUrlStr}`, currentCart.cart);\n updateCart(config, currentCart.cart);\n });\n\n // Listen to Beam's own events to integrate Beam data into Shopify order\n let lastNonprofitId: number | null | undefined;\n let lastSelectionId: string | null | undefined;\n window.addEventListener(BeamNonprofitSelectEvent.eventName, async (_event) => {\n const event = _event as BeamNonprofitSelectEvent;\n logger.debug(\"[cart-page][BeamNonprofitSelectEvent]\", event.detail);\n const { source, selectedNonprofitId, selectionId } = event.detail;\n\n if (source === WIDGET_NAMES.select_nonprofit) {\n const cartId = getExternalCartId(SHOPIFY_CART_COOKIE_NAME, config); // Shopify cart ID\n const beamCartId = getBeamCartId(BEAM_CART_COOKIE_NAME, config); // Beam cart ID\n const { chainId, storeId } = config;\n // Skip update if nothing changed (can happen if widget is re-initialized and\n // emits event after cache restoration, i.e., on cart re-render).\n if (lastNonprofitId === selectedNonprofitId && lastSelectionId === selectionId) {\n return;\n }\n await appendBeamAttributesToCart({\n selectedNonprofitId,\n selectionId,\n beamCartId: beamCartId ? beamCartId : undefined,\n cartId: cartId ? cartId : undefined,\n chainId,\n storeId,\n });\n lastSelectionId = selectionId;\n lastNonprofitId = selectedNonprofitId;\n }\n });\n\n /**\n * Upon removal of the selected nonprofit from the widget and local storage,\n * an event is emitted and that event is then used to update the cart attributes accordingly\n * This event listener updates the cart attributes based on the emitted event\n */\n window.addEventListener(BeamNonprofitSelectionRemovedEvent.eventName, async (_event) => {\n const event = _event as BeamNonprofitSelectionRemovedEvent;\n logger.debug(\"[cart-page][BeamNonprofitSelectionRemovedEvent]\", event.detail);\n const { newNonprofitId, selectionId } = event.detail;\n\n const cartId = getExternalCartId(SHOPIFY_CART_COOKIE_NAME, config);\n const beamCartId = getBeamCartId(BEAM_CART_COOKIE_NAME, config);\n const { chainId, storeId } = config;\n if (lastNonprofitId === newNonprofitId && lastSelectionId === selectionId) {\n return;\n }\n await appendBeamAttributesToCart({\n selectedNonprofitId: newNonprofitId,\n beamCartId: beamCartId ? beamCartId : undefined,\n selectionId,\n cartId: cartId ? cartId : undefined,\n chainId,\n storeId,\n });\n lastSelectionId = selectionId;\n lastNonprofitId = newNonprofitId;\n });\n\n /**\n * When a BeamCart is created, write beam metadata to the Shopify cart if\n * we need to capture it for Statsig\n */\n window.addEventListener(BeamCartCreatedEvent.eventName, (_event: Event) => {\n const event = _event as BeamCartCreatedEvent;\n logger.debug(\"[cart-page][BeamCartCreatedEvent]\", event.detail);\n appendStatsigToShopifyCartAttributes(config);\n });\n\n /**\n * On any cart changes, write beam metadata to the Shopify cart if\n * we need to capture it for Statsig\n */\n window.addEventListener(BeamCartChangeEvent.eventName, async (_event: Event) => {\n const event = _event as BeamCartChangeEvent;\n logger.debug(\"[cart-page][BeamCartChangeEvent]\", event.detail);\n appendStatsigToShopifyCartAttributes(config);\n });\n\n // Handle full-page load, ie, first-time page load and reloads from form submit events\n // This creates a GET to /cart.js\n // logger.debug(\"[cart-page][registerCartIntegration] getting current cart\");\n const currentCart = await getCurrentCart(config);\n // logger.debug(\"[cart-page][registerCartIntegration] initial cart fetch result\", currentCart);\n await updateCart(config, currentCart.cart, true);\n\n isBeamCartIntegrationRegistered = true;\n\n return true;\n}\n\n/* ***************************************** HELPER FUNCTIONS *****************************************\n These may be used individually to integrate with carts if the registerCartIntegration\n script doesn't work for some reason.\n ****************************************************************************************************/\n\n/**\n * Adds Statsig data to a Shopify cart\n */\nasync function appendStatsigToShopifyCartAttributes(config: BeamShopifyCartIntegrationConfig) {\n let showBeam;\n let remoteSessionId;\n try {\n if (window.statsig) {\n const statsig = window.statsig as any;\n showBeam = statsig.getLayer(\"beam_trial_layer\").get(\"show_beam\", false /* default to hide */) as boolean;\n remoteSessionId = statsig.getStableID();\n\n const cartId = getExternalCartId(SHOPIFY_CART_COOKIE_NAME, config);\n const beamCartId = getBeamCartId(BEAM_CART_COOKIE_NAME, config);\n const { chainId, storeId } = config;\n\n /**\n * When a Beam cart is created, we need to ensure that the\n * Statsig properties get added to the \"beam\" cart property\n */\n appendBeamAttributesToCart({\n showBeam: showBeam,\n remoteSessionId: remoteSessionId,\n beamCartId: beamCartId ? beamCartId : undefined,\n cartId: cartId ? cartId : undefined,\n chainId,\n storeId,\n });\n }\n } catch (e) {\n logger.error(e);\n }\n}\n\n/**\n * Detects change in cart since last page load,\n * by calling GET /cart.js, and returns cart values.\n * Used for:\n * - Form-based carts where the page refreshes to modify cart instead of using AJAX calls\n * - Hydrogen/GraphQL based carts (needs to be integrated manually)\n */\nasync function getCurrentCart(config: BeamShopifyCartIntegrationConfig): Promise<{\n changed: boolean;\n cart: {\n cartId: string;\n subtotal: number;\n itemCount: number;\n currencyCode: string;\n } & TCart;\n}> {\n const {\n token, // equal to \"cart\" cookie\n total_price, // this is the pretax value, after discounts, and multiplied by 100 (integer from decimal)\n item_count,\n currency,\n items,\n cart_level_discount_applications,\n } = await getShopifyCart();\n\n let changed = false;\n\n const localStorage = createScopedLocalStorage(config);\n\n // The cart cache is used to detect changes after page refreshes / across tabs\n const cachedCart: TBeamCartLocalStorage | null = localStorage.getItemJson(\"cart\");\n // The Beam cart cookie is used to identify the cart across subdomains\n // Use explicit null if empty because API requires it\n const beamCartId: string | null = getBeamCartId(BEAM_CART_COOKIE_NAME, config);\n\n const cart = {\n cartId: token,\n beamCartId,\n subtotal: total_price / 100,\n itemCount: item_count,\n currencyCode: currency,\n schema: { source: \"generic\" } as const,\n content: {\n // pull out minimal fields from full line items\n items: (items as TCartItems).map(({ sku, final_line_price, product_id, line_level_discount_allocations }) => {\n const remoteProductIdentifier = sku || String(product_id);\n const localAmount = final_line_price / 100;\n const discounts = (line_level_discount_allocations as ShopifyLineLevelDiscountAllocations[])?.map(\n ({ discount_application }) => {\n return { code: discount_application?.title, applicable: true };\n }\n );\n return { remoteProductIdentifier, localAmount, discounts };\n }),\n discounts: (cart_level_discount_applications as ShopifyDiscountApplication[]).map(({ title }) => {\n return { code: title, applicable: true };\n }),\n },\n };\n\n if (\n !isEqual(cart, {\n ...cachedCart,\n beamCartId: cachedCart?.beamCartId,\n })\n ) {\n changed = true;\n }\n\n // logger.debug(\"[cart-page][getCurrentCart] has cart changed?\", changed, cart);\n\n return { changed, cart };\n}\n\n/**\n * trackCart - Backwards-compatible alias for updateCart\n */\nconst trackCart = updateCart;\n\n/**\n * Helper function to get the Shopify cart attributes\n */\nconst getShopifyCart = async function () {\n const cart = await window\n .fetch(SHOPIFY_BASE_URL + \"cart.js\", {\n method: \"GET\",\n headers: { \"Content-Type\": \"application/json\" },\n })\n .then((res) => res.json());\n return cart;\n};\n\n/**\n * Sends Beam data to Shopify to integrate with order as custom attributes.\n * Memoized so that calls with the same data as the previous don't create additional API calls to Shopify.\n * This will do an append, not a full overwrite of the attributes in the beam property\n */\nconst appendBeamAttributesToCart = memoizeLast(async function appendBeamAttributesToCart({\n selectedNonprofitId,\n selectionId,\n beamCartId,\n cartId,\n chainId,\n storeId,\n showBeam,\n remoteSessionId,\n}: {\n selectedNonprofitId?: number | null;\n selectionId?: string;\n beamCartId?: string;\n cartId?: string;\n chainId?: number;\n storeId?: number;\n showBeam?: boolean;\n remoteSessionId?: string;\n}) {\n const { attributes } = await getShopifyCart();\n\n // Get only the Beam attribute, if it exists\n const existingBeamCartAttrString = attributes?.beam;\n let existingBeamCartAttr = {};\n try {\n if (existingBeamCartAttrString) {\n existingBeamCartAttr = JSON.parse(existingBeamCartAttrString);\n }\n } catch (err) {\n logger.error(err);\n }\n\n const beamCartAttrs = {\n beam: JSON.stringify({\n ...existingBeamCartAttr,\n nonprofit_id: selectedNonprofitId,\n selection_id: selectionId,\n beam_cart_id: beamCartId,\n shopify_cart_id: cartId,\n chain_id: chainId,\n store_id: storeId,\n show_beam: showBeam,\n remote_session_id: remoteSessionId,\n }),\n };\n\n // If the attributes match, no reason to update the cart\n if (isEqual(beamCartAttrs.beam, existingBeamCartAttr)) {\n // logger.debug(\"[cart-page][appendBeamAttributesToCart] cart attributes match, skipping update\");\n return;\n }\n\n try {\n await window.fetch(SHOPIFY_BASE_URL + \"cart/update.js\", {\n method: \"POST\",\n headers: { \"Content-Type\": \"application/json\" },\n body: JSON.stringify({ attributes: beamCartAttrs }),\n });\n } catch (err) {\n logger.error(err); // don't throw, allow later calls to continue\n }\n});\n\n/**\n * Sends Beam data to Shopify to integrate with order as custom attributes.\n * Memoized so that calls with the same data as the previous don't create additional API calls to Shopify.\n * This method force-updates the \"beam\" attribute with the values passed in\n */\nconst addBeamAttributesToCart = memoizeLast(async function addBeamAttributesToCart({\n selectedNonprofitId,\n selectionId,\n beamCartId,\n cartId,\n chainId,\n storeId,\n}: {\n selectedNonprofitId?: number | null;\n selectionId?: string;\n beamCartId?: string;\n cartId?: string;\n chainId?: number;\n storeId?: number;\n}) {\n let showBeam;\n let remoteSessionId;\n try {\n if (window.statsig) {\n const statsig = window.statsig as any;\n showBeam = statsig.getLayer(\"beam_trial_layer\").get(\"show_beam\", false /* default to hide */) as boolean;\n remoteSessionId = statsig.getStableID();\n }\n } catch (e) {\n logger.error(e);\n }\n const beamCartAttrs = {\n beam: JSON.stringify({\n nonprofit_id: selectedNonprofitId,\n selection_id: selectionId,\n beam_cart_id: beamCartId,\n shopify_cart_id: cartId,\n chain_id: chainId,\n store_id: storeId,\n show_beam: showBeam,\n remote_session_id: remoteSessionId,\n }),\n };\n\n try {\n await window.fetch(SHOPIFY_BASE_URL + \"cart/update.js\", {\n method: \"POST\",\n headers: { \"Content-Type\": \"application/json\" },\n body: JSON.stringify({ attributes: beamCartAttrs }),\n });\n } catch (err) {\n logger.error(err); // don't throw, allow later calls to continue\n }\n});\n\ndeclare global {\n interface Window {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n statsig?: any; // attached by Statsig CDN script\n }\n}\nexport {\n trackCart,\n getCurrentCart,\n addBeamAttributesToCart,\n appendStatsigToShopifyCartAttributes,\n registerCartIntegration,\n appendBeamAttributesToCart,\n getShopifyCart,\n};\n","import \"../../components/post-purchase\";\nimport { postTransaction } from \"../../api-sdk/v3/routes\";\nimport { DEFAULT_BASE_URL } from \"../../api-sdk/constants\";\nimport { LANGUAGES, TUrl } from \"../../api-sdk/types\";\nimport { waitForElement } from \"../../utils/wait-for-element\";\nimport { BeamError } from \"../../utils/beam-errors\";\nimport { getCookieValue } from \"../../utils/cookies\";\nimport { createScopedLocalStorage } from \"../../utils/local-storage\";\nimport { TCart } from \"../../shared/cart-contents\";\n\n// Shopify admin page: admin/settings/checkout\n\nexport type TBeamOrderPageParams = Parameters<typeof postTransaction>[0][\"requestBody\"] & {\n // Either storeId or postalCode + countryCode must be provided\n storeId?: number;\n postalCode?: string;\n countryCode?: string;\n orderId: string;\n email: string;\n cartTotal: number;\n cart: TCart;\n discountCodes: string[];\n promoCodes: string[];\n htmlPromoCodes: string;\n currencyCode: string;\n parentSelector: string; // CSS Selector for parent of widget to be inserted into DOM\n apiKey: string;\n baseUrl: TUrl;\n domain?: string; // Base domain for setting cookies\n lang: LANGUAGES;\n debug: boolean;\n};\n\nexport async function showBeamOrderPageWidgets({\n parentSelector = \".step__sections\",\n apiKey,\n baseUrl = DEFAULT_BASE_URL,\n storeId,\n postalCode,\n discountCodes,\n countryCode,\n orderId,\n email,\n cartTotal,\n cart,\n promoCodes,\n htmlPromoCodes,\n currencyCode = \"USD\",\n domain,\n lang = \"en\",\n debug = false,\n}: TBeamOrderPageParams) {\n const parentElement = document.querySelector(parentSelector) || (await waitForElement(parentSelector));\n if (!parentElement) {\n throw new BeamError(\n `Timed out waiting for selector '${parentSelector}'. Could not render Beam post-purchase widget.`\n );\n }\n\n // If checkout and order page are on different subdomains, we can't access localStorage\n // We can make postTransaction work by copying the cart cookie to the expected localStorage key on the current domain\n const cartId = await getCookieValue(\"cart\"); // Shopify-only cart identifier\n if (cartId) {\n const beamLocalStorage = createScopedLocalStorage({ apiKey });\n const existingValue = beamLocalStorage.getItemJson(\"cart\") || {};\n beamLocalStorage.setItemJson(\"cart\", { ...existingValue, cartId });\n }\n\n // Note: assign properties one by one instead of bulk Object.assign to type check assignments\n const widget = document.createElement(\"beam-post-purchase\");\n widget.apiKey = apiKey;\n widget.baseUrl = baseUrl;\n widget.storeId = storeId;\n widget.postalCode = postalCode;\n widget.countryCode = countryCode;\n widget.orderId = String(orderId);\n widget.email = email;\n widget.cartTotal = cartTotal;\n widget.cart = cart;\n widget.promoCodes = promoCodes;\n widget.htmlPromoCodes = htmlPromoCodes;\n widget.discountCodes = discountCodes;\n widget.currencyCode = currencyCode;\n widget.domain = domain;\n widget.lang = lang;\n widget.debug = debug;\n\n // Insert widget into DOM\n parentElement.appendChild(widget);\n}\n"],"names":["SHOPIFY_BASE_URL","isBeamCartIntegrationRegistered","SHOPIFY_CART_COOKIE_NAME","registerCartIntegration","config","initNetworkListeners","BeamNetworkCallEvent","_event","event","cartChangePaths","requestUrlStr","url","currentCart","getCurrentCart","updateCart","lastNonprofitId","lastSelectionId","BeamNonprofitSelectEvent","logger","source","selectedNonprofitId","selectionId","WIDGET_NAMES","cartId","getExternalCartId","beamCartId","getBeamCartId","BEAM_CART_COOKIE_NAME","chainId","storeId","appendBeamAttributesToCart","BeamNonprofitSelectionRemovedEvent","newNonprofitId","BeamCartCreatedEvent","appendStatsigToShopifyCartAttributes","BeamCartChangeEvent","showBeam","remoteSessionId","statsig","e","token","total_price","item_count","currency","items","cart_level_discount_applications","getShopifyCart","changed","cachedCart","createScopedLocalStorage","cart","sku","final_line_price","product_id","line_level_discount_allocations","remoteProductIdentifier","localAmount","discounts","discount_application","title","isEqual","trackCart","res","memoizeLast","attributes","existingBeamCartAttrString","existingBeamCartAttr","err","beamCartAttrs","addBeamAttributesToCart","showBeamOrderPageWidgets","parentSelector","apiKey","baseUrl","DEFAULT_BASE_URL","postalCode","discountCodes","countryCode","orderId","email","cartTotal","promoCodes","htmlPromoCodes","currencyCode","domain","lang","debug","parentElement","waitForElement","BeamError","getCookieValue","beamLocalStorage","existingValue","widget"],"mappings":"wzBAgCA,MAAMA,EAAmB,OAAO,SAAS,QAAQ,MAAQ,IAEzD,IAAIC,EAAkC,GAEtC,MAAMC,EAA2B,OAMjC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,KAAOR,EACdQ,EAAO,MAAQP,EAGfC,EAAc,YAAYM,CAAM,CAClC"}
@@ -1,16 +0,0 @@
1
- import{h as s,f as d,y as b,g as p}from"./lit-iNN5L_Qk.esm.js";import"./vendor-GKiOHg2N.esm.js";var f=Object.defineProperty,P=Object.getOwnPropertyDescriptor,n=(l,o,a,e)=>{for(var r=e>1?void 0:e?P(o,a):o,t=l.length-1,i;t>=0;t--)(i=l[t])&&(r=(e?i(o,a,r):i(r))||r);return e&&r&&f(o,a,r),r};class m extends s{constructor(){super(...arguments),this.promo=null,this.shortVersion=!1}static get styles(){return d`
2
- sl-badge::part(base) {
3
- background-color: var(--beam-promoPillLabel-color-background, #000);
4
- color: var(--beam-promoPillLabel-color, #fff);
5
- border: var(--beam-promoPillLabel-border-width, 0px) solid var(--beam-promoPillLabel-border, #000);
6
- border-radius: 18.37px;
7
- font-family: var(--beam-promoPillLabel-font, inherit);
8
- font-size: var(--beam-promoPillLabel-font-size, 12px);
9
- font-weight: var(--beam-promoPillLabel-font-weight, bold);
10
- text-transform: var(--beam-promoPillLabel-text-transform, none);
11
- text-wrap: var(--beam-promoPillLabel-text-wrap, wrap);
12
- padding: var(--beam-promoPillLabel-text-padding);
13
- margin: var(--beam-promoPillLabel-border-margin);
14
- }
15
- `}render(){if(this.promo){const o=this.shortVersion?this.promo["promo-text-short"]:this.promo["promo-text-long"];return b`<sl-badge pill aria-label="${o}">${o}</sl-badge>`}else return b``}}n([p({type:Object})],m.prototype,"promo",2),n([p({type:Boolean})],m.prototype,"shortVersion",2),customElements.get("beam-promo-info-pill")||customElements.define("beam-promo-info-pill",m);const g={"--beam-promoPillLabel-color-background":"#000","--beam-promoPillLabel-color":"#fff","--beam-promoPillLabel-border":"#000","--beam-promoPillLabel-border-width":"0px","--beam-promoPillLabel-font-size":"11px","--beam-promoPillLabel-font":"inherit","--beam-promoPillLabel-font-weight":"bold","--beam-promoPillLabel-text-transform":"none","--beam-promoPillLabel-text-wrap":"wrap","--beam-promoPillLabel-text-padding":"4px 15px","--beam-promoPillLabel-border-margin":"0px"};export{g as p};
16
- //# sourceMappingURL=promo-pill-label-P1X4xeAx.esm.js.map
@@ -1,2 +0,0 @@
1
- import{B as E,N as m}from"./beam-errors-AMvTvR1C.esm.js";import{logger as p}from"../utils/logger.js";var N="1.50.1",v={"@lit/react":"1.0.0","@lukeed/uuid":"2.0.0","@shoelace-style/shoelace":"2.15.0",lit:"2.6.1","lodash-es":"4.17.21","lucide-static":"0.292.0"};async function w(s,o){const c={method:"GET",...o,headers:{"Content-Type":"application/json",Accept:"application/json","X-Beam-Client":"WebSDK","X-Beam-Client-Version":N,...o?.headers},preflightContinue:!0,mode:o?.mode||"cors",body:o?.body!=null?o.body:void 0};let i;try{i=await fetch(s,c)}catch(e){const a=new E(`Network call failed (${c?.method.toUpperCase()} ${s})`);throw a.cause=e,p.error(a,s),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 m(i,r,`Response invalid. Expected JSON. Received: "${n}"`),a.cause=e),p.error(a),a}if(!i.ok){const e=new m(i,r,"Response was not OK");throw p.error(e),e}return r}const u="https://api.beamimpact.com",C="https://production.beamimpactlogs.com",O={en:"en",fr:"fr",de:"de",es:"es",it:"it",pl:"pl"},A={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"},L={cart_update:"cart_update"},t=(s,o,c)=>({[s]:async function({headers:i={},baseUrl:r=u,apiRoot:n="/api/v3",pathParams:e={},queryParams:a={},requestBody:d}){const h=Object.entries(e).reduce((S,[_,y])=>S.replace(`{${_}}`,y),s),f=JSON.parse(JSON.stringify(a)),l=new URLSearchParams(f).toString(),b=r+n+h+(l&&`?${l}`),g={headers:i,method:o,body:JSON.stringify(d)};return w(b,g)}})[s],P=t("/impact","get"),R=t("/chain/{chainId}/cumulativeImpact","get"),T=t("/selectNonprofit","post"),U=t("/transaction","post"),D=t("/transaction/{transactionId}","put"),k=t("/cart","post"),x=t("/chain/findEligibleNonprofitsForCart","post"),B=t("/logs","post"),I=t("/experimentSession","post"),J=t("/subscriptions/updateSubscriptionNonprofit","post"),F=t("/subscriptions/findOrCreateSubscription","post"),G=t("/productDetailsPage","post");export{u as D,L as H,O as S,A as W,C as a,k as b,B as c,v as d,I as e,x as f,P as g,F as h,T as i,D as j,R as k,G as l,U as p,J as u};
2
- //# sourceMappingURL=routes-YPOoVIR2.esm.js.map
@@ -1,2 +0,0 @@
1
- import{B as E,N as m}from"./beam-errors-AMvTvR1C.esm.js";import{logger as p}from"../utils/logger.esm.js";var N="1.50.1",v={"@lit/react":"1.0.0","@lukeed/uuid":"2.0.0","@shoelace-style/shoelace":"2.15.0",lit:"2.6.1","lodash-es":"4.17.21","lucide-static":"0.292.0"};async function w(s,o){const c={method:"GET",...o,headers:{"Content-Type":"application/json",Accept:"application/json","X-Beam-Client":"WebSDK","X-Beam-Client-Version":N,...o?.headers},preflightContinue:!0,mode:o?.mode||"cors",body:o?.body!=null?o.body:void 0};let i;try{i=await fetch(s,c)}catch(e){const a=new E(`Network call failed (${c?.method.toUpperCase()} ${s})`);throw a.cause=e,p.error(a,s),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 m(i,r,`Response invalid. Expected JSON. Received: "${n}"`),a.cause=e),p.error(a),a}if(!i.ok){const e=new m(i,r,"Response was not OK");throw p.error(e),e}return r}const u="https://api.beamimpact.com",C="https://production.beamimpactlogs.com",O={en:"en",fr:"fr",de:"de",es:"es",it:"it",pl:"pl"},A={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"},L={cart_update:"cart_update"},t=(s,o,c)=>({[s]:async function({headers:i={},baseUrl:r=u,apiRoot:n="/api/v3",pathParams:e={},queryParams:a={},requestBody:d}){const h=Object.entries(e).reduce((S,[_,y])=>S.replace(`{${_}}`,y),s),f=JSON.parse(JSON.stringify(a)),l=new URLSearchParams(f).toString(),b=r+n+h+(l&&`?${l}`),g={headers:i,method:o,body:JSON.stringify(d)};return w(b,g)}})[s],P=t("/impact","get"),R=t("/chain/{chainId}/cumulativeImpact","get"),T=t("/selectNonprofit","post"),U=t("/transaction","post"),D=t("/transaction/{transactionId}","put"),k=t("/cart","post"),x=t("/chain/findEligibleNonprofitsForCart","post"),B=t("/logs","post"),I=t("/experimentSession","post"),J=t("/subscriptions/updateSubscriptionNonprofit","post"),F=t("/subscriptions/findOrCreateSubscription","post"),G=t("/productDetailsPage","post");export{u as D,L as H,O as S,A as W,C as a,k as b,B as c,v as d,I as e,x as f,P as g,F as h,T as i,D as j,R as k,G as l,U as p,J as u};
2
- //# sourceMappingURL=routes-o-phF_L1.esm.js.map