@saasquatch/mint-components 1.12.1-14 → 1.12.1-16

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 (267) hide show
  1. package/dist/cjs/{ShadowViewAddon-63b78308.js → ShadowViewAddon-9aee7df5.js} +195 -90
  2. package/dist/cjs/{global-02e50f09.js → global-41c0a650.js} +1 -1
  3. package/dist/cjs/{index.module-df530553.js → index.module-d8342710.js} +12 -10
  4. package/dist/cjs/loader.cjs.js +3 -3
  5. package/dist/cjs/mint-components.cjs.js +3 -3
  6. package/dist/cjs/{re-render-1976e05e.js → re-render-dd8d65bf.js} +2 -2
  7. package/dist/cjs/sqm-asset-card.cjs.entry.js +1 -1
  8. package/dist/cjs/sqm-banking-info-form_16.cjs.entry.js +51 -51
  9. package/dist/cjs/{sqm-big-stat_39.cjs.entry.js → sqm-big-stat_40.cjs.entry.js} +220 -43
  10. package/dist/cjs/sqm-close-button.cjs.entry.js +1 -1
  11. package/dist/cjs/sqm-context-router.cjs.entry.js +1 -1
  12. package/dist/cjs/sqm-empty_4.cjs.entry.js +2 -2
  13. package/dist/cjs/sqm-graphql-client-provider.cjs.entry.js +3 -3
  14. package/dist/cjs/sqm-instant-access-registration.cjs.entry.js +3 -3
  15. package/dist/cjs/{sqm-invoice-table-view-e3b03a00.js → sqm-invoice-table-view-41a0b707.js} +1 -1
  16. package/dist/cjs/sqm-leaderboard-rank.cjs.entry.js +4 -4
  17. package/dist/cjs/sqm-logout-current-user.cjs.entry.js +3 -3
  18. package/dist/cjs/{sqm-navigation-sidebar-item-view-a125ec5f.js → sqm-navigation-sidebar-item-view-5f7886d6.js} +2 -2
  19. package/dist/cjs/sqm-navigation-sidebar-item.cjs.entry.js +3 -3
  20. package/dist/cjs/sqm-navigation-sidebar.cjs.entry.js +2 -2
  21. package/dist/cjs/sqm-password-field.cjs.entry.js +2 -2
  22. package/dist/cjs/sqm-popup-container.cjs.entry.js +1 -1
  23. package/dist/cjs/{sqm-portal-email-verification-view-292b5bf4.js → sqm-portal-email-verification-view-56fabc90.js} +1 -1
  24. package/dist/cjs/sqm-portal-email-verification.cjs.entry.js +6 -6
  25. package/dist/cjs/sqm-portal-forgot-password.cjs.entry.js +3 -3
  26. package/dist/cjs/sqm-portal-logout.cjs.entry.js +2 -2
  27. package/dist/cjs/{sqm-portal-profile-view-fde54e35.js → sqm-portal-profile-view-7c9c60a6.js} +1 -1
  28. package/dist/cjs/sqm-portal-profile.cjs.entry.js +6 -6
  29. package/dist/cjs/sqm-portal-protected-route.cjs.entry.js +5 -5
  30. package/dist/cjs/sqm-portal-registration-form.cjs.entry.js +6 -6
  31. package/dist/cjs/sqm-portal-reset-password.cjs.entry.js +5 -5
  32. package/dist/cjs/sqm-portal-verify-email.cjs.entry.js +5 -5
  33. package/dist/cjs/sqm-referral-table_11.cjs.entry.js +5 -5
  34. package/dist/cjs/sqm-referred-registration.cjs.entry.js +3 -3
  35. package/dist/cjs/sqm-rewards-table-customer-note-column.cjs.entry.js +2 -2
  36. package/dist/cjs/sqm-rewards-table_9.cjs.entry.js +8 -8
  37. package/dist/cjs/sqm-stencilbook.cjs.entry.js +235 -172
  38. package/dist/cjs/sqm-tab.cjs.entry.js +2 -2
  39. package/dist/cjs/sqm-tabs.cjs.entry.js +3 -3
  40. package/dist/cjs/{useChildElements-e0d44916.js → useChildElements-57e11069.js} +1 -1
  41. package/dist/cjs/{useInstantAccessRegistration-bbe746d1.js → useInstantAccessRegistration-14ccf9d4.js} +3 -3
  42. package/dist/cjs/{useReferralTable-a76adb0d.js → useReferralTable-ef36b29e.js} +7 -7
  43. package/dist/cjs/{useRegistrationFormState-876ed65d.js → useRegistrationFormState-7d608337.js} +1 -1
  44. package/dist/cjs/{utilities-cec9dd36.js → utilities-7df0fdad.js} +1 -1
  45. package/dist/collection/components/sqm-portal-change-marketing/ChangeMarketing.stories.js +55 -0
  46. package/dist/collection/components/sqm-portal-change-marketing/sqm-portal-change-marketing-view.js +5 -4
  47. package/dist/collection/components/sqm-portal-change-marketing/sqm-portal-change-marketing.js +5 -5
  48. package/dist/collection/components/sqm-stencilbook/sqm-stencilbook.js +2 -0
  49. package/dist/esm/{ShadowViewAddon-272f75a5.js → ShadowViewAddon-cadd38e4.js} +194 -91
  50. package/dist/esm/{global-62554cef.js → global-c1e70cb2.js} +1 -1
  51. package/dist/esm/{index.module-48f73e70.js → index.module-3344e7dc.js} +4 -2
  52. package/dist/esm/loader.js +3 -3
  53. package/dist/esm/mint-components.js +3 -3
  54. package/dist/esm/{re-render-cb4d43dc.js → re-render-29151677.js} +2 -2
  55. package/dist/esm/sqm-asset-card.entry.js +1 -1
  56. package/dist/esm/sqm-banking-info-form_16.entry.js +51 -51
  57. package/dist/esm/{sqm-big-stat_39.entry.js → sqm-big-stat_40.entry.js} +218 -42
  58. package/dist/esm/sqm-close-button.entry.js +1 -1
  59. package/dist/esm/sqm-context-router.entry.js +1 -1
  60. package/dist/esm/sqm-empty_4.entry.js +2 -2
  61. package/dist/esm/sqm-graphql-client-provider.entry.js +3 -3
  62. package/dist/esm/sqm-instant-access-registration.entry.js +3 -3
  63. package/dist/esm/{sqm-invoice-table-view-41a14ca6.js → sqm-invoice-table-view-eb4b3f63.js} +1 -1
  64. package/dist/esm/sqm-leaderboard-rank.entry.js +4 -4
  65. package/dist/esm/sqm-logout-current-user.entry.js +3 -3
  66. package/dist/esm/{sqm-navigation-sidebar-item-view-af40eedb.js → sqm-navigation-sidebar-item-view-08e47843.js} +2 -2
  67. package/dist/esm/sqm-navigation-sidebar-item.entry.js +3 -3
  68. package/dist/esm/sqm-navigation-sidebar.entry.js +2 -2
  69. package/dist/esm/sqm-password-field.entry.js +2 -2
  70. package/dist/esm/sqm-popup-container.entry.js +1 -1
  71. package/dist/esm/{sqm-portal-email-verification-view-460bac1b.js → sqm-portal-email-verification-view-52a45f66.js} +1 -1
  72. package/dist/esm/sqm-portal-email-verification.entry.js +6 -6
  73. package/dist/esm/sqm-portal-forgot-password.entry.js +3 -3
  74. package/dist/esm/sqm-portal-logout.entry.js +2 -2
  75. package/dist/esm/{sqm-portal-profile-view-4caa9f28.js → sqm-portal-profile-view-4810da8a.js} +1 -1
  76. package/dist/esm/sqm-portal-profile.entry.js +6 -6
  77. package/dist/esm/sqm-portal-protected-route.entry.js +5 -5
  78. package/dist/esm/sqm-portal-registration-form.entry.js +6 -6
  79. package/dist/esm/sqm-portal-reset-password.entry.js +5 -5
  80. package/dist/esm/sqm-portal-verify-email.entry.js +5 -5
  81. package/dist/esm/sqm-referral-table_11.entry.js +5 -5
  82. package/dist/esm/sqm-referred-registration.entry.js +3 -3
  83. package/dist/esm/sqm-rewards-table-customer-note-column.entry.js +2 -2
  84. package/dist/esm/sqm-rewards-table_9.entry.js +8 -8
  85. package/dist/esm/sqm-stencilbook.entry.js +235 -172
  86. package/dist/esm/sqm-tab.entry.js +2 -2
  87. package/dist/esm/sqm-tabs.entry.js +3 -3
  88. package/dist/esm/{useChildElements-a6b895dd.js → useChildElements-cc98d6c4.js} +1 -1
  89. package/dist/esm/{useInstantAccessRegistration-46a98499.js → useInstantAccessRegistration-e95685e5.js} +3 -3
  90. package/dist/esm/{useReferralTable-6e8350db.js → useReferralTable-f1ffc72e.js} +7 -7
  91. package/dist/esm/{useRegistrationFormState-de6b208e.js → useRegistrationFormState-4151cec4.js} +1 -1
  92. package/dist/esm/{utilities-e8022681.js → utilities-4d60af2c.js} +1 -1
  93. package/dist/esm-es5/ShadowViewAddon-cadd38e4.js +1 -0
  94. package/dist/esm-es5/{global-62554cef.js → global-c1e70cb2.js} +1 -1
  95. package/dist/esm-es5/index.module-3344e7dc.js +1 -0
  96. package/dist/esm-es5/loader.js +1 -1
  97. package/dist/esm-es5/mint-components.js +1 -1
  98. package/dist/esm-es5/{re-render-cb4d43dc.js → re-render-29151677.js} +1 -1
  99. package/dist/esm-es5/sqm-asset-card.entry.js +1 -1
  100. package/dist/esm-es5/sqm-banking-info-form_16.entry.js +1 -1
  101. package/dist/esm-es5/sqm-big-stat_40.entry.js +1 -0
  102. package/dist/esm-es5/sqm-close-button.entry.js +1 -1
  103. package/dist/esm-es5/sqm-context-router.entry.js +1 -1
  104. package/dist/esm-es5/sqm-empty_4.entry.js +1 -1
  105. package/dist/esm-es5/sqm-graphql-client-provider.entry.js +1 -1
  106. package/dist/esm-es5/sqm-instant-access-registration.entry.js +1 -1
  107. package/dist/esm-es5/{sqm-invoice-table-view-41a14ca6.js → sqm-invoice-table-view-eb4b3f63.js} +1 -1
  108. package/dist/esm-es5/sqm-leaderboard-rank.entry.js +1 -1
  109. package/dist/esm-es5/sqm-logout-current-user.entry.js +1 -1
  110. package/dist/esm-es5/{sqm-navigation-sidebar-item-view-af40eedb.js → sqm-navigation-sidebar-item-view-08e47843.js} +1 -1
  111. package/dist/esm-es5/sqm-navigation-sidebar-item.entry.js +1 -1
  112. package/dist/esm-es5/sqm-navigation-sidebar.entry.js +1 -1
  113. package/dist/esm-es5/sqm-password-field.entry.js +1 -1
  114. package/dist/esm-es5/sqm-popup-container.entry.js +1 -1
  115. package/dist/esm-es5/{sqm-portal-email-verification-view-460bac1b.js → sqm-portal-email-verification-view-52a45f66.js} +1 -1
  116. package/dist/esm-es5/sqm-portal-email-verification.entry.js +1 -1
  117. package/dist/esm-es5/sqm-portal-forgot-password.entry.js +1 -1
  118. package/dist/esm-es5/sqm-portal-logout.entry.js +1 -1
  119. package/dist/esm-es5/{sqm-portal-profile-view-4caa9f28.js → sqm-portal-profile-view-4810da8a.js} +1 -1
  120. package/dist/esm-es5/sqm-portal-profile.entry.js +1 -1
  121. package/dist/esm-es5/sqm-portal-protected-route.entry.js +1 -1
  122. package/dist/esm-es5/sqm-portal-registration-form.entry.js +1 -1
  123. package/dist/esm-es5/sqm-portal-reset-password.entry.js +1 -1
  124. package/dist/esm-es5/sqm-portal-verify-email.entry.js +1 -1
  125. package/dist/esm-es5/sqm-referral-table_11.entry.js +1 -1
  126. package/dist/esm-es5/sqm-referred-registration.entry.js +1 -1
  127. package/dist/esm-es5/sqm-rewards-table-customer-note-column.entry.js +1 -1
  128. package/dist/esm-es5/sqm-rewards-table_9.entry.js +1 -1
  129. package/dist/esm-es5/sqm-stencilbook.entry.js +1 -1
  130. package/dist/esm-es5/sqm-tab.entry.js +1 -1
  131. package/dist/esm-es5/sqm-tabs.entry.js +1 -1
  132. package/dist/esm-es5/{useChildElements-a6b895dd.js → useChildElements-cc98d6c4.js} +1 -1
  133. package/dist/esm-es5/{useInstantAccessRegistration-46a98499.js → useInstantAccessRegistration-e95685e5.js} +1 -1
  134. package/dist/esm-es5/{useReferralTable-6e8350db.js → useReferralTable-f1ffc72e.js} +1 -1
  135. package/dist/esm-es5/{useRegistrationFormState-de6b208e.js → useRegistrationFormState-4151cec4.js} +1 -1
  136. package/dist/esm-es5/{utilities-e8022681.js → utilities-4d60af2c.js} +1 -1
  137. package/dist/mint-components/mint-components.esm.js +1 -1
  138. package/dist/mint-components/mint-components.js +1 -1
  139. package/dist/mint-components/{p-bd6d9d54.system.entry.js → p-00aa314d.system.entry.js} +1 -1
  140. package/dist/mint-components/{p-bda832b2.js → p-051dd2a0.js} +2 -2
  141. package/dist/mint-components/{p-3fefb1f4.entry.js → p-063f4458.entry.js} +32 -15
  142. package/dist/mint-components/p-06ab1968.js +1 -0
  143. package/dist/mint-components/p-0afb7d5d.system.js +1 -0
  144. package/dist/mint-components/{p-f99765fe.system.entry.js → p-0c06a6f5.system.entry.js} +1 -1
  145. package/dist/mint-components/{p-9bb9a767.system.js → p-0f65c86c.system.js} +1 -1
  146. package/dist/mint-components/{p-9982db11.entry.js → p-1064099e.entry.js} +1 -1
  147. package/dist/mint-components/{p-83df7db2.system.entry.js → p-17c59360.system.entry.js} +1 -1
  148. package/dist/mint-components/p-186542b8.system.js +1 -0
  149. package/dist/mint-components/{p-0f30148d.system.entry.js → p-19c94256.system.entry.js} +1 -1
  150. package/dist/mint-components/p-1ba5157e.js +1 -0
  151. package/dist/mint-components/{p-68160d49.system.entry.js → p-1ca1ca86.system.entry.js} +1 -1
  152. package/dist/mint-components/p-2037fbd3.js +1 -0
  153. package/dist/mint-components/{p-94324315.system.entry.js → p-284cc389.system.entry.js} +1 -1
  154. package/dist/mint-components/{p-23112de2.entry.js → p-29a80f6e.entry.js} +1 -1
  155. package/dist/mint-components/p-2b85b9d2.entry.js +1 -0
  156. package/dist/mint-components/p-30909368.entry.js +1 -0
  157. package/dist/mint-components/{p-5f20200a.entry.js → p-36332fc7.entry.js} +1 -1
  158. package/dist/mint-components/p-3d6eac77.js +1 -0
  159. package/dist/mint-components/p-3e87d803.entry.js +1 -0
  160. package/dist/mint-components/{p-30797093.system.entry.js → p-3edd4ea8.system.entry.js} +1 -1
  161. package/dist/mint-components/{p-13976be9.system.entry.js → p-40ad6540.system.entry.js} +1 -1
  162. package/dist/mint-components/{p-5de3473d.entry.js → p-42baa318.entry.js} +1 -1
  163. package/dist/mint-components/{p-2a2d4343.system.js → p-45b1b2be.system.js} +1 -1
  164. package/dist/mint-components/p-46af0bf6.system.js +1 -0
  165. package/dist/mint-components/{p-902770d7.entry.js → p-4893f186.entry.js} +1 -1
  166. package/dist/mint-components/{p-b169229a.entry.js → p-4c6c314b.entry.js} +1 -1
  167. package/dist/mint-components/{p-0068067d.entry.js → p-4e582dd8.entry.js} +1 -1
  168. package/dist/mint-components/p-50135af6.entry.js +1 -0
  169. package/dist/mint-components/{p-7726e4ea.system.entry.js → p-5bdf586c.system.entry.js} +1 -1
  170. package/dist/mint-components/p-5d86d0b4.entry.js +1 -0
  171. package/dist/mint-components/{p-92b08cb2.system.entry.js → p-63b5126d.system.entry.js} +1 -1
  172. package/dist/mint-components/p-658d5964.system.entry.js +1 -0
  173. package/dist/mint-components/p-67a8b7ae.system.js +1 -0
  174. package/dist/mint-components/{p-9a520e94.entry.js → p-69a0a791.entry.js} +2 -2
  175. package/dist/mint-components/{p-498c4ffd.system.entry.js → p-6a4b1ec0.system.entry.js} +1 -1
  176. package/dist/mint-components/{p-59111d6c.entry.js → p-6c9eb87a.entry.js} +1 -1
  177. package/dist/mint-components/{p-44c3791a.system.entry.js → p-6e50122b.system.entry.js} +1 -1
  178. package/dist/mint-components/p-6fdf020e.entry.js +1 -0
  179. package/dist/mint-components/{p-64b25dd9.entry.js → p-7a33cd80.entry.js} +1 -1
  180. package/dist/mint-components/p-7c49ebfa.entry.js +1 -0
  181. package/dist/mint-components/{p-c89c890e.entry.js → p-85f3c5d5.entry.js} +2 -2
  182. package/dist/mint-components/{p-0f010c01.system.js → p-8833552d.system.js} +1 -1
  183. package/dist/mint-components/{p-74d012fc.entry.js → p-91c1a54d.entry.js} +1 -1
  184. package/dist/mint-components/{p-b348d95c.js → p-920641bf.js} +1 -1
  185. package/dist/mint-components/{p-018088cc.entry.js → p-924384b2.entry.js} +2 -2
  186. package/dist/mint-components/{p-1d803c85.js → p-9276151f.js} +1 -1
  187. package/dist/mint-components/{p-115edc43.system.entry.js → p-98072a24.system.entry.js} +1 -1
  188. package/dist/mint-components/{p-5da7c982.system.js → p-99b2ff9c.system.js} +1 -1
  189. package/dist/mint-components/p-9e62ac1f.system.entry.js +1 -0
  190. package/dist/mint-components/{p-66d09e59.system.js → p-a1b5a82c.system.js} +1 -1
  191. package/dist/mint-components/{p-57ea9c0b.system.js → p-a2bce8d7.system.js} +1 -1
  192. package/dist/mint-components/{p-98602fa9.js → p-a7161d9f.js} +1 -1
  193. package/dist/mint-components/{p-74609159.system.js → p-a8ebb87a.system.js} +1 -1
  194. package/dist/mint-components/{p-baca1c93.system.entry.js → p-a8ec5664.system.entry.js} +1 -1
  195. package/dist/mint-components/{p-52acd113.entry.js → p-ac1fb0c4.entry.js} +1 -1
  196. package/dist/mint-components/{p-2364eb2d.system.entry.js → p-ad8dbab8.system.entry.js} +1 -1
  197. package/dist/mint-components/p-ae72631b.entry.js +9 -0
  198. package/dist/mint-components/{p-1bb2fd65.system.entry.js → p-b6557eff.system.entry.js} +1 -1
  199. package/dist/mint-components/{p-804de0cf.system.entry.js → p-b758d962.system.entry.js} +1 -1
  200. package/dist/mint-components/{p-ce5057f7.system.js → p-b8fff589.system.js} +1 -1
  201. package/dist/mint-components/{p-d71ec46e.system.entry.js → p-b9cab58d.system.entry.js} +1 -1
  202. package/dist/mint-components/{p-1bdacfcb.entry.js → p-bb873ddd.entry.js} +1 -1
  203. package/dist/mint-components/{p-6f980faf.system.js → p-c588e9c1.system.js} +1 -1
  204. package/dist/mint-components/{p-512089bb.js → p-c810bcfc.js} +1 -1
  205. package/dist/mint-components/{p-778b55a5.entry.js → p-cb029418.entry.js} +1 -1
  206. package/dist/mint-components/{p-6aed684b.js → p-cbfc4b47.js} +1 -1
  207. package/dist/mint-components/{p-cefffd56.system.entry.js → p-cd326a35.system.entry.js} +1 -1
  208. package/dist/mint-components/{p-c98cd85a.system.entry.js → p-d1ebd4c9.system.entry.js} +1 -1
  209. package/dist/mint-components/{p-df2ada74.entry.js → p-d2389ef4.entry.js} +1 -1
  210. package/dist/mint-components/{p-215d9dce.system.entry.js → p-d5b327ec.system.entry.js} +1 -1
  211. package/dist/mint-components/{p-fc58dc2f.system.entry.js → p-db0d4d3a.system.entry.js} +1 -1
  212. package/dist/mint-components/{p-da1e21f2.js → p-e10b0628.js} +1 -1
  213. package/dist/mint-components/{p-275b2841.system.entry.js → p-e4d14213.system.entry.js} +1 -1
  214. package/dist/mint-components/{p-7ab32670.entry.js → p-ea2075fd.entry.js} +2 -2
  215. package/dist/mint-components/p-ea46d642.js +391 -0
  216. package/dist/mint-components/{p-c4719154.js → p-eb64a65f.js} +1 -1
  217. package/dist/mint-components/{p-099c59cc.system.entry.js → p-ebab1714.system.entry.js} +1 -1
  218. package/dist/mint-components/{p-b7324c0e.system.entry.js → p-f093ed85.system.entry.js} +1 -1
  219. package/dist/mint-components/{p-9aa177d6.system.entry.js → p-f58c7201.system.entry.js} +1 -1
  220. package/dist/mint-components/{p-1eb21821.system.js → p-f8d2c679.system.js} +1 -1
  221. package/dist/mint-components/{p-513f79fb.entry.js → p-fa160846.entry.js} +2 -2
  222. package/dist/mint-components/{p-3b08cc52.entry.js → p-fcf7f4c1.entry.js} +1 -1
  223. package/dist/mint-components/{p-670d441e.system.entry.js → p-fe163a23.system.entry.js} +1 -1
  224. package/dist/types/components/sqm-portal-change-marketing/ChangeMarketing.stories.d.ts +8 -0
  225. package/dist/types/components/sqm-portal-change-marketing/sqm-portal-change-marketing-view.d.ts +2 -2
  226. package/dist/types/components/sqm-portal-change-marketing/sqm-portal-change-marketing.d.ts +3 -3
  227. package/dist/types/components/sqm-portal-change-marketing/usePortalChangeMarketing.d.ts +2 -2
  228. package/dist/types/components.d.ts +4 -4
  229. package/docs/docs.docx +0 -0
  230. package/docs/raisins.json +1 -1
  231. package/package.json +1 -1
  232. package/dist/cjs/sqm-checkbox-field-view-e0a31f2a.js +0 -66
  233. package/dist/cjs/sqm-portal-change-marketing.cjs.entry.js +0 -236
  234. package/dist/esm/sqm-checkbox-field-view-0ef58cb3.js +0 -64
  235. package/dist/esm/sqm-portal-change-marketing.entry.js +0 -232
  236. package/dist/esm-es5/ShadowViewAddon-272f75a5.js +0 -1
  237. package/dist/esm-es5/index.module-48f73e70.js +0 -1
  238. package/dist/esm-es5/sqm-big-stat_39.entry.js +0 -1
  239. package/dist/esm-es5/sqm-checkbox-field-view-0ef58cb3.js +0 -1
  240. package/dist/esm-es5/sqm-portal-change-marketing.entry.js +0 -1
  241. package/dist/mint-components/p-1514e0af.system.entry.js +0 -1
  242. package/dist/mint-components/p-175075e7.system.js +0 -1
  243. package/dist/mint-components/p-1e0f4667.entry.js +0 -9
  244. package/dist/mint-components/p-29023a9c.entry.js +0 -1
  245. package/dist/mint-components/p-30f84f8b.system.js +0 -1
  246. package/dist/mint-components/p-32642d34.js +0 -1
  247. package/dist/mint-components/p-481dedf2.system.js +0 -1
  248. package/dist/mint-components/p-48b07ec7.system.entry.js +0 -1
  249. package/dist/mint-components/p-4dcdf9b6.js +0 -1
  250. package/dist/mint-components/p-52553737.system.entry.js +0 -1
  251. package/dist/mint-components/p-5ab5131c.entry.js +0 -1
  252. package/dist/mint-components/p-711bb8da.entry.js +0 -1
  253. package/dist/mint-components/p-7eabcffc.js +0 -1
  254. package/dist/mint-components/p-8e3390b6.entry.js +0 -1
  255. package/dist/mint-components/p-9b4a99c4.js +0 -1
  256. package/dist/mint-components/p-a178a449.system.js +0 -1
  257. package/dist/mint-components/p-a6b36268.system.js +0 -1
  258. package/dist/mint-components/p-b07a88fd.js +0 -1
  259. package/dist/mint-components/p-b5b9f737.entry.js +0 -1
  260. package/dist/mint-components/p-b86003f6.entry.js +0 -1
  261. package/dist/mint-components/p-de0a29b2.js +0 -391
  262. package/dist/mint-components/p-e169497d.entry.js +0 -1
  263. package/dist/mint-components/p-f9067e53.entry.js +0 -18
  264. package/dist/types/global/android.d.ts +0 -7
  265. package/dist/types/global/demo.d.ts +0 -2
  266. package/dist/types/stories/features.d.ts +0 -4
  267. package/dist/types/stories/templates.d.ts +0 -4
@@ -0,0 +1 @@
1
+ var __spreadArrays=this&&this.__spreadArrays||function(){for(var r=0,n=0,t=arguments.length;n<t;n++)r+=arguments[n].length;for(var e=Array(r),s=0,n=0;n<t;n++)for(var a=arguments[n],i=0,u=a.length;i<u;i++,s++)e[s]=a[i];return e};System.register(["./p-2a414b2e.system.js","./p-46af0bf6.system.js"],(function(r){"use strict";var n,t,e;return{setters:[function(r){n=r.k;t=r.u},function(r){e=r._}],execute:function(){r("u",s);function s(){var r=e();var s=r.children.length?Array.from(r.children):[];var a=n(s),i=a[0],u=a[1];var c;t((function(){c=new MutationObserver((function(){var n=Array.from(r.children);u(__spreadArrays(n))}))}),[]);t((function(){if(!c)return;c.observe(r,{childList:true});return function(){c.disconnect()}}),[r]);return i}}}}));
@@ -1,4 +1,4 @@
1
- import{h as e,r as t,c as a}from"./p-64c3217a.js";import{b as s,j as r,f as l,n as i,u as n}from"./p-fd2c5407.js";import{i as o}from"./p-c4719154.js";import{d,Q as c,H as u,L as h,y as p,k as m,i as v}from"./p-9b4a99c4.js";import{c as E}from"./p-c1086930.js";import"./p-02be1a88.js";import{c as y}from"./p-cef45012.js";import{G as f}from"./p-c5d2e4ba.js";import{u as g,a as w}from"./p-b348d95c.js";import{u as b}from"./p-4dcdf9b6.js";import{l as x}from"./p-251e7567.js";import{m as A}from"./p-f3053c61.js";import{g as D}from"./p-bda832b2.js";import{l as N}from"./p-9ec99ced.js";const R=s("sq:useRewardsTable"),T=d.gql`
1
+ import{h as e,r as t,c as a}from"./p-64c3217a.js";import{b as s,j as r,f as l,n as i,u as n}from"./p-fd2c5407.js";import{i as o}from"./p-eb64a65f.js";import{d,J as c,H as u,L as h,w as p,R as m,i as v}from"./p-2037fbd3.js";import{c as E}from"./p-c1086930.js";import"./p-02be1a88.js";import{c as f}from"./p-cef45012.js";import{G as y}from"./p-c5d2e4ba.js";import{u as g,a as w}from"./p-920641bf.js";import{u as b}from"./p-06ab1968.js";import{l as x}from"./p-251e7567.js";import{m as A}from"./p-f3053c61.js";import{g as D}from"./p-051dd2a0.js";import{l as R}from"./p-9ec99ced.js";const N=s("sq:useRewardsTable"),T=d.gql`
2
2
  query getRewards(
3
3
  $limit: Int!
4
4
  $offset: Int!
@@ -141,4 +141,4 @@ import{h as e,r as t,c as a}from"./p-64c3217a.js";import{b as s,j as r,f as l,n
141
141
  }
142
142
  }
143
143
  }
144
- `;async function I(t,a){const s=t.tagName.toLowerCase();let r;await customElements.whenDefined(s);try{r=a()}catch(t){return R("label promise failed",t),e("span",null)}try{return await r}catch(t){R("Error rendering label",t);const a=D(t);return e("details",null,e("summary",null,"Error"),a)}}const P=class{constructor(e){t(this,e),this.perPage=4,this.hideLabels=!1,this.prevLabel="Prev",this.moreLabel="Next",this.hiddenColumns="0",this.smBreakpoint=599,this.mdBreakpoint=799,i(this)}disconnectedCallback(){}render(){const t=e(C,null),a=e(S,null),{states:s,data:i,callbacks:o,elements:d}=v()?function(e,t,a){const[s,i]=r(((e,t)=>({...e,...t})),{columns:[],rows:[],loading:!1,page:0}),o=g(),{data:d}=n((()=>{var t;return(null===(t=e.demoData)||void 0===t?void 0:t.mockData)||A(e.perPage)}),[e.perPage]),c=b();return l((()=>{i({loading:!0}),d&&async function(t){let a=d;a=d.slice(0,e.perPage);const s=t.filter((e=>{var t,a;return"loading"!==e.slot&&"empty"!==e.slot&&"loading"!==(null===(t=null==e?void 0:e.firstElementChild)||void 0===t?void 0:t.getAttribute("slot"))&&"empty"!==(null===(a=null==e?void 0:e.firstElementChild)||void 0===a?void 0:a.getAttribute("slot"))})),r=null==s?void 0:s.map((async(e,t)=>{var a;const s=null===(a=null==e?void 0:e.firstElementChild)||void 0===a?void 0:a.getAttribute("slot");if("RAISINS-PLOP-TARGET"===e.tagName&&"loading"!==s&&"empty"!==s){e.style.position="absolute",e.setAttribute("slot","column-"+t);const a=e.firstElementChild.childNodes[1];return a.innerHTML="+",a.style.lineHeight="20px",I(e,(()=>e.renderLabel(t)))}return I(e,(()=>e.renderLabel()))})),l=null==a?void 0:a.map((async e=>{const t=null==s?void 0:s.map((async t=>I(t,(()=>t.renderCell(e,void 0,{})))));return await Promise.all(t)})),n=l&&(await Promise.all(l)).filter((e=>e));i({rows:n});const o=r&&await Promise.all(r);i({columns:o,loading:!1,page:0})}(c)}),[d,c,o]),E({states:{hasPrev:!1,hasNext:!1,loading:!1,show:"rows"},callbacks:{prevPage:()=>console.log("Prev"),nextPage:()=>console.log("Next")},data:{textOverrides:{showLabels:!e.hideLabels,prevLabel:e.prevLabel,moreLabel:e.moreLabel},referralData:[],mdBreakpoint:799,smBreakpoint:599},elements:{columns:s.columns,rows:s.rows,emptyElement:t,loadingElement:a}},e.demoData||{},{arrayMerge:(e,t)=>t})}(this,t,a):function(t,a,s){var i,n,o;const d=c(),v=u(),E=h(),y=null!==(i=t.programId)&&void 0!==i?i:v,f={userId_eq:null==d?void 0:d.id,accountId_eq:null==d?void 0:d.accountId,...y?"classic"===y?{programId_exists:!1}:{programId_eq:y}:{}},[w,x]=r(((e,t)=>({...e,...t})),{columns:[],rows:[],loading:!1,page:0}),{data:A,loading:D}=p(_,{},!(null==d?void 0:d.jwt)),{envelope:N,states:R,callbacks:P}=m(T,(e=>{var t;return null===(t=null==e?void 0:e.viewer)||void 0===t?void 0:t.rewards}),{limit:t.perPage,offset:0},{rewardFilter:f,locale:E},!(null==d?void 0:d.jwt)),C=g(),S=b(),L=null==N?void 0:N.data,U=null===(n=null==A?void 0:A.viewer)||void 0===n?void 0:n.impactConnection;l((()=>{x({loading:!0}),N&&async function(t){const a=t.filter((e=>"loading"!==e.slot&&"empty"!==e.slot)),s=null==a?void 0:a.map((async e=>I(e,(()=>e.renderLabel())))),r=null==L?void 0:L.map((async t=>{const s=null==a?void 0:a.map((async a=>I(a,(()=>a.renderCell(t,{locale:E,taxConnection:U},e)))));return await Promise.all(s)})),l=r&&(await Promise.all(r)).filter((e=>e));x({rows:l});const i=s&&await Promise.all(s);x({columns:i,loading:!1,page:R.currentPage})}(S)}),[N,S,C]);const k=!(null===(o=null==w?void 0:w.rows)||void 0===o?void 0:o.length)&&!(null==L?void 0:L.length);return{states:{hasNext:R.currentPage<R.pageCount-1,hasPrev:R.currentPage>0,show:R.loading||w.loading||D?"loading":k?"empty":"rows",namespace:"sqm-rewards-table"},data:{textOverrides:{showLabels:!t.hideLabels,prevLabel:t.prevLabel,moreLabel:t.moreLabel},hiddenColumns:t.hiddenColumns,smBreakpoint:t.smBreakpoint,mdBreakpoint:t.mdBreakpoint},elements:{columns:w.columns,rows:w.rows,emptyElement:a,loadingElement:s},callbacks:{nextPage:()=>{P.setCurrentPage(R.currentPage+1)},prevPage:()=>{P.setCurrentPage(R.currentPage-1)}}}}(this,t,a);return w([this.perPage]),e(f,{states:s,data:i,callbacks:o,elements:d})}};function C(){return e("slot",{name:"empty"},e("sqm-empty",{"empty-state-image":"https://res.cloudinary.com/saasquatch/image/upload/v1644360953/squatch-assets/empty_reward2.png","empty-state-header":"View your rewards","empty-state-text":"Refer friends and complete tasks to view the details of your rewards"}))}function S(){return e("slot",{name:"loading"},e(L,null),e(L,null),e(L,null),e(L,null))}function L(){return e("sqm-table-row",null,e("sqm-table-cell",{colspan:5},e("sl-skeleton",null)))}const U=class{constructor(e){t(this,e),this.ignored=!0,this.locale="en",i(this)}disconnectedCallback(){}render(){var e,t;return this.date?null===(t=null===(e=x.DateTime.fromMillis(this.date))||void 0===e?void 0:e.setLocale(N(this.locale)))||void 0===t?void 0:t.toLocaleString(x.DateTime.DATE_MED):"-"}},k=class{constructor(e){t(this,e),this.columnTitle="Date received",this.dateShown="dateGiven",i(this)}disconnectedCallback(){}async renderCell(t,a){return e("sqm-rewards-table-date-cell",{date:t[this.dateShown],locale:null==a?void 0:a.locale})}async renderLabel(){return this.columnTitle}render(){return w([this.dateShown,this.columnTitle]),e(a,{style:{display:"none"}})}},O=y({DetailsContainer:{width:"100%",display:"flex","align-items":"center","justify-content":"space-between","margin-right":"var(--sl-spacing-small)","flex-wrap":"wrap"},Details:{"padding-bottom":"var(--sl-spacing-small)","max-width":"500px","padding-right":"var(--sl-spacing-x-small)","&::part(header)":{padding:"var(--sl-spacing-x-small)",cursor:"default"},"&::part(content)":{padding:"var(--sl-spacing-x-small) var(--sl-spacing-medium)"},"&::part(base)":{opacity:"1"},"&::part(summary-icon)":{display:"flex"}},BadgeContainer:{"& > :not(:last-child)":{"margin-right":"var(--sl-spacing-x-small)"}},BoldText:{"font-weight":"var(--sl-font-weight-semibold)"},StatusBadge:{paddingLeft:"var(--sl-spacing-xxx-small)","&::part(base)":{textAlign:"center",maxWidth:"170px",whiteSpace:"pre-line"}},Fueltank:{"& .code":{display:"flex",cursor:"pointer",userSelect:"none",color:"var(--sl-color-neutral-500)","&:hover":{color:"var(--sl-color-sky-500)"}},"& .text":{maxWidth:"90%",overflow:"hidden",textOverflow:"ellipsis",color:"inherit",fontSize:"var(--sl-font-size-small)",fontWeight:"var(--sl-font-weight-bold)"},"& .icon":{position:"relative",top:"1px",marginLeft:"var(--sl-spacing-x-small)",color:"inherit"}}}),q=O.toString(),F=class{constructor(e){t(this,e)}render(){return o.locale=this.locale,e("div",{style:{display:"contents"}},e("style",{type:"text/css"},q),e((({reward:t})=>{var a;const s="CENTS"===t.unit?t.prettyValue.replace(/USD/gi,"$"):null!==(a=t.prettyValue)&&void 0!==a?a:"-",r="1"===t.prettyValueNumber||t.dateRedeemed&&"0"===t.prettyAvailableNumber;if("FUELTANK"===t.type)return e("div",{class:O.classes.Fueltank},t.prettyValue,t.fuelTankCode&&e("div",{class:"code",onClick:()=>navigator.clipboard.writeText(t.fuelTankCode)},e("sl-tooltip",{trigger:"click",placement:"top",distance:5,skidding:11,content:this.copyText,"onSl-show":e=>setTimeout((()=>e.path[0].hide()),1e3)},e("span",{class:"text"},t.fuelTankCode),e("span",{class:"icon"},e("sl-icon",{name:"files"})))));if("CREDIT"===t.type&&!r){const a=parseFloat(t.prettyValueNumber)-parseFloat(t.prettyRedeemedNumber),r=Math.round(a/parseFloat(t.prettyValueNumber)*100),l=t.statuses.includes("EXPIRED")||t.statuses.includes("CANCELLED")?e("div",null,o.formatMessage({id:"redeemedText",defaultMessage:this.redeemedText},{redeemedAmount:t.prettyRedeemedCredit})):e("div",null,o.formatMessage({id:"availableText",defaultMessage:this.availableText},{availableAmount:t.statuses.includes("PENDING")?t.prettyAssignedCredit:t.prettyAvailableValue})),i=y({Progress:{height:"3px",width:"100%",margin:"var(--sl-spacing-xx-small) 0",background:"var(--sl-color-neutral-200)","&:after":{content:'""',display:"block",background:"var(--sl-color-primary-300)",borderRadius:"100px",width:`${r}%`,height:"100%"}},Container:{display:"inline-block",verticalAlign:"top",width:"150px",whiteSpace:"break",overflow:"hidden",textOverflow:"ellipsis"},Text:{fontSize:"var(--sl-font-size-medium)",color:"var(--sl-color-gray-800)"},Subtext:{fontSize:"var(--sl-font-size-small)",color:"var(--sl-color-neutral-500)"}}),n=i.toString();return e("div",null,e("style",{type:"text/css"},n),e("div",{class:i.classes.Container},e("span",{part:"sqm-reward-cell-value"},s+" "),e("br",null)," ",e("div",{part:"sqm-reward-cell-progress",class:i.classes.Progress}),e("span",{part:"sqm-reward-cell-subtext",class:i.classes.Subtext},l)))}return e("div",null,s)}),{reward:this.reward}))}},M=class{constructor(e){t(this,e),this.columnTitle="Reward",this.redeemedText="{redeemedAmount} redeemed",this.availableText="{availableAmount} remaining",this.copyText="Copied!",i(this)}disconnectedCallback(){}async renderCell(t,a){return e("sqm-rewards-table-reward-cell",{reward:t,redeemedText:this.redeemedText,availableText:this.availableText,copyText:this.copyText,locale:null==a?void 0:a.locale,exportparts:"sqm-rewards-cell-value, sqm-rewards-cell-progress-bar, sqm-rewards-cell-subtext"})}async renderLabel(){return this.columnTitle}render(){return w([this.columnTitle,this.redeemedText,this.availableText,this.copyText]),e(a,{style:{display:"none"}})}},V=class{constructor(e){t(this,e),this.locale="en"}render(){o.locale=this.locale;const t=({reward:t})=>{var a;return e("span",null,o.formatMessage({id:"rewardSourceText",defaultMessage:this.rewardSourceText},{rewardSource:t.rewardSource,programName:null===(a=null==t?void 0:t.program)||void 0===a?void 0:a.name}))},a=({reward:t})=>{var a;const s=e("div",null,e("span",{style:{fontSize:"var(--sl-font-size-small)",color:"var(--sl-color-neutral-500)"}},this.rewardExchangeText),e("br",null),null===(a=t.exchangedRewardRedemptionTransaction)||void 0===a?void 0:a.prettyRedeemedCredit," → ",t.prettyValue);return t.exchangedRewardRedemptionTransaction.prettyRedeemedCredit.length+t.prettyValue.length<21?s:e("div",{style:{display:"inline-block",verticalAlign:"top"}},s)},s=e=>e?e.firstName||e.lastName?e.firstName?e.lastName?`${e.firstName} ${e.lastName}`:`${e.firstName}`:`${e.lastName}`:this.anonymousUserText:this.deletedUserText;return e((()=>"FRIEND_SIGNUP"===this.reward.rewardSource||"REFERRED"===this.reward.rewardSource?null===this.reward.referral?e("p",{style:{color:"var(--sl-color-gray-400)"}},this.deletedReferralText):e("div",null,e("div",{style:{fontSize:"var(--sl-font-size-small)",color:"var(--sl-color-neutral-500)"}},o.formatMessage({id:"referralText",defaultMessage:this.referralText},{rewardSource:this.reward.rewardSource})),e("div",null,s("FRIEND_SIGNUP"==this.reward.rewardSource?this.reward.referral.referredUser:this.reward.referral.referrerUser))):e(this.reward.exchangedRewardRedemptionTransaction?a:t,{reward:this.reward})),null)}},G=class{constructor(e){t(this,e),this.columnTitle="Source",this.anonymousUser="Anonymous User",this.deletedUser="Deleted User",this.rewardExchangeText="Reward Exchange",this.referralText="{rewardSource, select, FRIEND_SIGNUP {Referral to} REFERRED {Referred by} other {}}",this.rewardSourceText="{rewardSource, select, MANUAL {Manual} AUTOMATED {{programName}} other {}}",i(this)}disconnectedCallback(){}async renderCell(t,a){return e("sqm-rewards-table-source-cell",{reward:t,anonymousUserText:this.anonymousUser,deletedUserText:this.deletedUser,rewardExchangeText:this.rewardExchangeText,referralText:this.referralText,rewardSourceText:this.rewardSourceText,locale:null==a?void 0:a.locale})}async renderLabel(){return this.columnTitle}render(){return w([this.deletedUser,this.anonymousUser,this.columnTitle,this.rewardExchangeText,this.referralText,this.rewardSourceText]),e(a,{style:{display:"none"}})}},$=y({Badge:{"&::part(base)":{fontSize:"var(--sl-font-size-small)",padding:"4px 8px",paddingLeft:"10px",whiteSpace:"pre-line"}},RedeemBadge:{"&::part(base)":{fontSize:"var(--sl-font-size-small)",padding:"4px 8px",background:"var(--sl-color-blue-600)"}},Date:{fontSize:"var(--sl-font-size-small)",color:"var(--sl-color-neutral-500)",margin:"0"}}),B=$.toString(),j=class{constructor(e){t(this,e),this.expiryText="Expires",this.locale="en",this.pendingUsTax="W-9 required",this.pendingTaxReview="Awaiting tax form review.",this.pendingNewTaxForm="Invalid tax form. Submit a new form to receive your rewards.",this.pendingTaxSubmission="Submit your tax documents to receive your rewards.",this.pendingPartnerCreation="Complete your tax and cash payout setup to receive your rewards.",this.pendingScheduled="Until",this.pendingUnhandled="Fulfillment error",this.pendingReviewText="Awaiting review",this.deniedText="Detected self-referral",this.payoutFailed="Payout failed due to a fulfillment issue and is current being retried.",this.payoutApproved="Reward approved for payout and was scheduled for payment based on your settings.",this.payoutCancelled="If you think this is a mistake, contact our Support team."}rewardStatus(e){var t,a,s,r,l,i,n,o,d;const c=null===(t=e.statuses)||void 0===t?void 0:t.includes("EXPIRED"),u=null===(a=e.statuses)||void 0===a?void 0:a.includes("PENDING"),h="INTEGRATION"===e.type||"FUELTANK"===e.type,p=null===(r=null===(s=e.referral)||void 0===s?void 0:s.fraudData)||void 0===r?void 0:r.moderationStatus;if("DENIED"===p)return"DENIED";if("PENDING"===p)return"PENDING_REVIEW";const m=null===(l=e.partnerFundsTransfer)||void 0===l?void 0:l.status;return"TRANSFERRED"===m||"NOT_YET_DUE"===m?"PAYOUT_APPROVED":"OVERDUE"===m?"PAYOUT_FAILED":"REVERSED"===m?"PAYOUT_CANCELLED":e.dateCancelled?"CANCELLED":c?"EXPIRED":u?"PENDING":"CREDIT"===e.type?(null===(i=e.statuses)||void 0===i?void 0:i.includes("REDEEMED"))?"REDEEMED":"AVAILABLE":"PCT_DISCOUNT"===e.type&&(null===(n=e.statuses)||void 0===n?void 0:n.includes("AVAILABLE"))?"AVAILABLE":h&&u?"PENDING":h&&(null===(o=e.statuses)||void 0===o?void 0:o.includes("CANCELLED"))?"CANCELLED":h&&(null===(d=e.statuses)||void 0===d?void 0:d.includes("AVAILABLE"))?"AVAILABLE":""}getTaxPendingReasons(e,t){var a,s,r,l,i;if(null===(a=null==e?void 0:e.pendingReasons)||void 0===a?void 0:a.includes("US_TAX")){if(!(null==t?void 0:t.taxHandlingEnabled))return this.pendingUsTax;if(!(null==t?void 0:t.connected))return this.pendingPartnerCreation;if(null===(s=null==t?void 0:t.publisher)||void 0===s?void 0:s.requiredTaxDocumentType){if(!(null===(r=null==t?void 0:t.publisher)||void 0===r?void 0:r.currentTaxDocument))return this.pendingTaxSubmission;const e=t.publisher.currentTaxDocument.status;if("INACTIVE"===e)return this.pendingNewTaxForm;if("NOT_VERIFIED"===e)return this.pendingTaxReview}if(!(null===(l=null==t?void 0:t.publisher)||void 0===l?void 0:l.withdrawalSettings))return this.pendingPartnerCreation}return(null===(i=null==e?void 0:e.pendingReasons)||void 0===i?void 0:i.includes("PAYOUT_CONFIGURATION_MISSING"))?this.pendingPartnerCreation:""}getBadgeType(e){switch(e){case"AVAILABLE":return"success";case"REDEEMED":case"PAYOUT_APPROVED":return"primary";case"PENDING":case"PENDING_REVIEW":return"warning";default:return"danger"}}getPayoutStatusText(e){switch(e){case"US_TAX":return this.pendingUsTax;case"PAYOUT_APPROVED":return this.payoutApproved;case"PAYOUT_FAILED":return this.payoutFailed;case"PAYOUT_CANCELLED":return this.payoutCancelled;case"PENDING_TAX_REVIEW":return this.pendingTaxReview;case"PENDING_NEW_TAX_FORM":return this.pendingNewTaxForm;case"PENDING_TAX_SUBMISSION":return this.pendingTaxSubmission;case"PENDING_PARTNER_CREATION":return this.pendingPartnerCreation}}render(){var t;o.locale=this.locale;const a=this.rewardStatus(this.reward),s=o.formatMessage({id:"statusMessage",defaultMessage:this.statusText},{status:a}),r=this.getBadgeType(a),l=this.reward.dateCancelled||this.reward.dateExpires||this.reward.dateRedeemed||"",i=l&&`${"AVAILABLE"===a&&this.reward.dateExpires?this.expiryText+" ":""}${null===(t=x.DateTime.fromMillis(l))||void 0===t?void 0:t.setLocale(N(N(this.locale))).toLocaleString(x.DateTime.DATE_MED)}`,n="PENDING"===a?this.getTaxPendingReasons(this.reward,this.taxConnection)||function(e){var t;const a={SCHEDULED:e.reward.dateScheduledFor&&e.pendingScheduled+" "+(null===(t=x.DateTime.fromMillis(e.reward.dateScheduledFor))||void 0===t?void 0:t.setLocale(N(N(e.locale||"en"))).toLocaleString(x.DateTime.DATE_MED)),UNHANDLED_ERROR:e.pendingUnhandled,SUSPECTED_FRAUD:e.pendingReview},s=e.getTaxPendingReasons(e.reward,e.taxConnection);return[...s?[s]:[],...e.reward.pendingReasons.map((e=>{var t;return null!==(t=a[e])&&void 0!==t?t:e}))].join(", ")}(this):null,d="PENDING_REVIEW"===a?this.pendingReviewText:"DENIED"===a?this.deniedText:null;return e("div",{style:{display:"contents"}},e("style",{type:"text/css"},B),e("sl-badge",{type:r,pill:!0,class:"REDEEMED"===a||"PAYOUT_APPROVED"===a?$.classes.RedeemBadge:$.classes.Badge},s),e("p",{class:$.classes.Date},d||n||this.getPayoutStatusText(a)||i))}},z=class{constructor(e){t(this,e),this.columnTitle="Status",this.statusText="{status, select, AVAILABLE {Available} CANCELLED {Cancelled} PENDING {Pending} PENDING_REVIEW {Pending} PAYOUT_APPROVED {Payout Approved} PAYOUT_CANCELLED {Payout Cancelled} PAYOUT_FAILED {Payout Failed} EXPIRED {Expired} REDEEMED {Redeemed} DENIED {Denied} other {Not available} }",this.expiryText="Expires on ",this.pendingUsTax="W-9 required",this.pendingScheduled="Until",this.pendingUnhandled="Fulfillment error",this.pendingReviewText="Awaiting review",this.deniedText="Detected self-referral",this.pendingTaxReview="Awaiting tax form review.",this.pendingNewTaxForm="Invalid tax form. Submit a new form to receive your rewards.",this.pendingTaxSubmission="Submit your tax documents to receive your rewards.",this.pendingPartnerCreation="Complete your tax and cash payout setup to receive your rewards.",this.payoutFailed="Payout failed due to a fulfillment issue and is current being retried.",this.payoutCancelled="If you think this is a mistake, contact our Support team.",this.payoutApproved="Reward approved for payout and was scheduled for payment based on your settings.",i(this)}disconnectedCallback(){}async renderCell(t,a){return e("sqm-rewards-table-status-cell",{statusText:this.statusText,reward:t,taxConnection:null==a?void 0:a.taxConnection,expiryText:this.expiryText,pendingScheduled:this.pendingScheduled,pendingUsTax:this.pendingUsTax,pendingUnhandled:this.pendingUnhandled,pendingReviewText:this.pendingReviewText,payoutFailed:this.payoutFailed,payoutApproved:this.payoutApproved,payoutCancelled:this.payoutCancelled,deniedText:this.deniedText,locale:null==a?void 0:a.locale})}async renderLabel(){return this.columnTitle}render(){return w([this.columnTitle,this.statusText,this.expiryText,this.pendingReviewText,this.pendingScheduled,this.pendingUsTax,this.pendingUnhandled]),e(a,{style:{display:"none"}})}};export{P as sqm_rewards_table,U as sqm_rewards_table_date_cell,k as sqm_rewards_table_date_column,F as sqm_rewards_table_reward_cell,M as sqm_rewards_table_reward_column,V as sqm_rewards_table_source_cell,G as sqm_rewards_table_source_column,j as sqm_rewards_table_status_cell,z as sqm_rewards_table_status_column}
144
+ `;async function I(t,a){const s=t.tagName.toLowerCase();let r;await customElements.whenDefined(s);try{r=a()}catch(t){return N("label promise failed",t),e("span",null)}try{return await r}catch(t){N("Error rendering label",t);const a=D(t);return e("details",null,e("summary",null,"Error"),a)}}const P=class{constructor(e){t(this,e),this.perPage=4,this.hideLabels=!1,this.prevLabel="Prev",this.moreLabel="Next",this.hiddenColumns="0",this.smBreakpoint=599,this.mdBreakpoint=799,i(this)}disconnectedCallback(){}render(){const t=e(C,null),a=e(S,null),{states:s,data:i,callbacks:o,elements:d}=v()?function(e,t,a){const[s,i]=r(((e,t)=>({...e,...t})),{columns:[],rows:[],loading:!1,page:0}),o=g(),{data:d}=n((()=>{var t;return(null===(t=e.demoData)||void 0===t?void 0:t.mockData)||A(e.perPage)}),[e.perPage]),c=b();return l((()=>{i({loading:!0}),d&&async function(t){let a=d;a=d.slice(0,e.perPage);const s=t.filter((e=>{var t,a;return"loading"!==e.slot&&"empty"!==e.slot&&"loading"!==(null===(t=null==e?void 0:e.firstElementChild)||void 0===t?void 0:t.getAttribute("slot"))&&"empty"!==(null===(a=null==e?void 0:e.firstElementChild)||void 0===a?void 0:a.getAttribute("slot"))})),r=null==s?void 0:s.map((async(e,t)=>{var a;const s=null===(a=null==e?void 0:e.firstElementChild)||void 0===a?void 0:a.getAttribute("slot");if("RAISINS-PLOP-TARGET"===e.tagName&&"loading"!==s&&"empty"!==s){e.style.position="absolute",e.setAttribute("slot","column-"+t);const a=e.firstElementChild.childNodes[1];return a.innerHTML="+",a.style.lineHeight="20px",I(e,(()=>e.renderLabel(t)))}return I(e,(()=>e.renderLabel()))})),l=null==a?void 0:a.map((async e=>{const t=null==s?void 0:s.map((async t=>I(t,(()=>t.renderCell(e,void 0,{})))));return await Promise.all(t)})),n=l&&(await Promise.all(l)).filter((e=>e));i({rows:n});const o=r&&await Promise.all(r);i({columns:o,loading:!1,page:0})}(c)}),[d,c,o]),E({states:{hasPrev:!1,hasNext:!1,loading:!1,show:"rows"},callbacks:{prevPage:()=>console.log("Prev"),nextPage:()=>console.log("Next")},data:{textOverrides:{showLabels:!e.hideLabels,prevLabel:e.prevLabel,moreLabel:e.moreLabel},referralData:[],mdBreakpoint:799,smBreakpoint:599},elements:{columns:s.columns,rows:s.rows,emptyElement:t,loadingElement:a}},e.demoData||{},{arrayMerge:(e,t)=>t})}(this,t,a):function(t,a,s){var i,n,o;const d=c(),v=u(),E=h(),f=null!==(i=t.programId)&&void 0!==i?i:v,y={userId_eq:null==d?void 0:d.id,accountId_eq:null==d?void 0:d.accountId,...f?"classic"===f?{programId_exists:!1}:{programId_eq:f}:{}},[w,x]=r(((e,t)=>({...e,...t})),{columns:[],rows:[],loading:!1,page:0}),{data:A,loading:D}=p(_,{},!(null==d?void 0:d.jwt)),{envelope:R,states:N,callbacks:P}=m(T,(e=>{var t;return null===(t=null==e?void 0:e.viewer)||void 0===t?void 0:t.rewards}),{limit:t.perPage,offset:0},{rewardFilter:y,locale:E},!(null==d?void 0:d.jwt)),C=g(),S=b(),L=null==R?void 0:R.data,U=null===(n=null==A?void 0:A.viewer)||void 0===n?void 0:n.impactConnection;l((()=>{x({loading:!0}),R&&async function(t){const a=t.filter((e=>"loading"!==e.slot&&"empty"!==e.slot)),s=null==a?void 0:a.map((async e=>I(e,(()=>e.renderLabel())))),r=null==L?void 0:L.map((async t=>{const s=null==a?void 0:a.map((async a=>I(a,(()=>a.renderCell(t,{locale:E,taxConnection:U},e)))));return await Promise.all(s)})),l=r&&(await Promise.all(r)).filter((e=>e));x({rows:l});const i=s&&await Promise.all(s);x({columns:i,loading:!1,page:N.currentPage})}(S)}),[R,S,C]);const O=!(null===(o=null==w?void 0:w.rows)||void 0===o?void 0:o.length)&&!(null==L?void 0:L.length);return{states:{hasNext:N.currentPage<N.pageCount-1,hasPrev:N.currentPage>0,show:N.loading||w.loading||D?"loading":O?"empty":"rows",namespace:"sqm-rewards-table"},data:{textOverrides:{showLabels:!t.hideLabels,prevLabel:t.prevLabel,moreLabel:t.moreLabel},hiddenColumns:t.hiddenColumns,smBreakpoint:t.smBreakpoint,mdBreakpoint:t.mdBreakpoint},elements:{columns:w.columns,rows:w.rows,emptyElement:a,loadingElement:s},callbacks:{nextPage:()=>{P.setCurrentPage(N.currentPage+1)},prevPage:()=>{P.setCurrentPage(N.currentPage-1)}}}}(this,t,a);return w([this.perPage]),e(y,{states:s,data:i,callbacks:o,elements:d})}};function C(){return e("slot",{name:"empty"},e("sqm-empty",{"empty-state-image":"https://res.cloudinary.com/saasquatch/image/upload/v1644360953/squatch-assets/empty_reward2.png","empty-state-header":"View your rewards","empty-state-text":"Refer friends and complete tasks to view the details of your rewards"}))}function S(){return e("slot",{name:"loading"},e(L,null),e(L,null),e(L,null),e(L,null))}function L(){return e("sqm-table-row",null,e("sqm-table-cell",{colspan:5},e("sl-skeleton",null)))}const U=class{constructor(e){t(this,e),this.ignored=!0,this.locale="en",i(this)}disconnectedCallback(){}render(){var e,t;return this.date?null===(t=null===(e=x.DateTime.fromMillis(this.date))||void 0===e?void 0:e.setLocale(R(this.locale)))||void 0===t?void 0:t.toLocaleString(x.DateTime.DATE_MED):"-"}},O=class{constructor(e){t(this,e),this.columnTitle="Date received",this.dateShown="dateGiven",i(this)}disconnectedCallback(){}async renderCell(t,a){return e("sqm-rewards-table-date-cell",{date:t[this.dateShown],locale:null==a?void 0:a.locale})}async renderLabel(){return this.columnTitle}render(){return w([this.dateShown,this.columnTitle]),e(a,{style:{display:"none"}})}},k=f({DetailsContainer:{width:"100%",display:"flex","align-items":"center","justify-content":"space-between","margin-right":"var(--sl-spacing-small)","flex-wrap":"wrap"},Details:{"padding-bottom":"var(--sl-spacing-small)","max-width":"500px","padding-right":"var(--sl-spacing-x-small)","&::part(header)":{padding:"var(--sl-spacing-x-small)",cursor:"default"},"&::part(content)":{padding:"var(--sl-spacing-x-small) var(--sl-spacing-medium)"},"&::part(base)":{opacity:"1"},"&::part(summary-icon)":{display:"flex"}},BadgeContainer:{"& > :not(:last-child)":{"margin-right":"var(--sl-spacing-x-small)"}},BoldText:{"font-weight":"var(--sl-font-weight-semibold)"},StatusBadge:{paddingLeft:"var(--sl-spacing-xxx-small)","&::part(base)":{textAlign:"center",maxWidth:"170px",whiteSpace:"pre-line"}},Fueltank:{"& .code":{display:"flex",cursor:"pointer",userSelect:"none",color:"var(--sl-color-neutral-500)","&:hover":{color:"var(--sl-color-sky-500)"}},"& .text":{maxWidth:"90%",overflow:"hidden",textOverflow:"ellipsis",color:"inherit",fontSize:"var(--sl-font-size-small)",fontWeight:"var(--sl-font-weight-bold)"},"& .icon":{position:"relative",top:"1px",marginLeft:"var(--sl-spacing-x-small)",color:"inherit"}}}),q=k.toString(),F=class{constructor(e){t(this,e)}render(){return o.locale=this.locale,e("div",{style:{display:"contents"}},e("style",{type:"text/css"},q),e((({reward:t})=>{var a;const s="CENTS"===t.unit?t.prettyValue.replace(/USD/gi,"$"):null!==(a=t.prettyValue)&&void 0!==a?a:"-",r="1"===t.prettyValueNumber||t.dateRedeemed&&"0"===t.prettyAvailableNumber;if("FUELTANK"===t.type)return e("div",{class:k.classes.Fueltank},t.prettyValue,t.fuelTankCode&&e("div",{class:"code",onClick:()=>navigator.clipboard.writeText(t.fuelTankCode)},e("sl-tooltip",{trigger:"click",placement:"top",distance:5,skidding:11,content:this.copyText,"onSl-show":e=>setTimeout((()=>e.path[0].hide()),1e3)},e("span",{class:"text"},t.fuelTankCode),e("span",{class:"icon"},e("sl-icon",{name:"files"})))));if("CREDIT"===t.type&&!r){const a=parseFloat(t.prettyValueNumber)-parseFloat(t.prettyRedeemedNumber),r=Math.round(a/parseFloat(t.prettyValueNumber)*100),l=t.statuses.includes("EXPIRED")||t.statuses.includes("CANCELLED")?e("div",null,o.formatMessage({id:"redeemedText",defaultMessage:this.redeemedText},{redeemedAmount:t.prettyRedeemedCredit})):e("div",null,o.formatMessage({id:"availableText",defaultMessage:this.availableText},{availableAmount:t.statuses.includes("PENDING")?t.prettyAssignedCredit:t.prettyAvailableValue})),i=f({Progress:{height:"3px",width:"100%",margin:"var(--sl-spacing-xx-small) 0",background:"var(--sl-color-neutral-200)","&:after":{content:'""',display:"block",background:"var(--sl-color-primary-300)",borderRadius:"100px",width:`${r}%`,height:"100%"}},Container:{display:"inline-block",verticalAlign:"top",width:"150px",whiteSpace:"break",overflow:"hidden",textOverflow:"ellipsis"},Text:{fontSize:"var(--sl-font-size-medium)",color:"var(--sl-color-gray-800)"},Subtext:{fontSize:"var(--sl-font-size-small)",color:"var(--sl-color-neutral-500)"}}),n=i.toString();return e("div",null,e("style",{type:"text/css"},n),e("div",{class:i.classes.Container},e("span",{part:"sqm-reward-cell-value"},s+" "),e("br",null)," ",e("div",{part:"sqm-reward-cell-progress",class:i.classes.Progress}),e("span",{part:"sqm-reward-cell-subtext",class:i.classes.Subtext},l)))}return e("div",null,s)}),{reward:this.reward}))}},M=class{constructor(e){t(this,e),this.columnTitle="Reward",this.redeemedText="{redeemedAmount} redeemed",this.availableText="{availableAmount} remaining",this.copyText="Copied!",i(this)}disconnectedCallback(){}async renderCell(t,a){return e("sqm-rewards-table-reward-cell",{reward:t,redeemedText:this.redeemedText,availableText:this.availableText,copyText:this.copyText,locale:null==a?void 0:a.locale,exportparts:"sqm-rewards-cell-value, sqm-rewards-cell-progress-bar, sqm-rewards-cell-subtext"})}async renderLabel(){return this.columnTitle}render(){return w([this.columnTitle,this.redeemedText,this.availableText,this.copyText]),e(a,{style:{display:"none"}})}},V=class{constructor(e){t(this,e),this.locale="en"}render(){o.locale=this.locale;const t=({reward:t})=>{var a;return e("span",null,o.formatMessage({id:"rewardSourceText",defaultMessage:this.rewardSourceText},{rewardSource:t.rewardSource,programName:null===(a=null==t?void 0:t.program)||void 0===a?void 0:a.name}))},a=({reward:t})=>{var a;const s=e("div",null,e("span",{style:{fontSize:"var(--sl-font-size-small)",color:"var(--sl-color-neutral-500)"}},this.rewardExchangeText),e("br",null),null===(a=t.exchangedRewardRedemptionTransaction)||void 0===a?void 0:a.prettyRedeemedCredit," → ",t.prettyValue);return t.exchangedRewardRedemptionTransaction.prettyRedeemedCredit.length+t.prettyValue.length<21?s:e("div",{style:{display:"inline-block",verticalAlign:"top"}},s)},s=e=>e?e.firstName||e.lastName?e.firstName?e.lastName?`${e.firstName} ${e.lastName}`:`${e.firstName}`:`${e.lastName}`:this.anonymousUserText:this.deletedUserText;return e((()=>"FRIEND_SIGNUP"===this.reward.rewardSource||"REFERRED"===this.reward.rewardSource?null===this.reward.referral?e("p",{style:{color:"var(--sl-color-gray-400)"}},this.deletedReferralText):e("div",null,e("div",{style:{fontSize:"var(--sl-font-size-small)",color:"var(--sl-color-neutral-500)"}},o.formatMessage({id:"referralText",defaultMessage:this.referralText},{rewardSource:this.reward.rewardSource})),e("div",null,s("FRIEND_SIGNUP"==this.reward.rewardSource?this.reward.referral.referredUser:this.reward.referral.referrerUser))):e(this.reward.exchangedRewardRedemptionTransaction?a:t,{reward:this.reward})),null)}},G=class{constructor(e){t(this,e),this.columnTitle="Source",this.anonymousUser="Anonymous User",this.deletedUser="Deleted User",this.rewardExchangeText="Reward Exchange",this.referralText="{rewardSource, select, FRIEND_SIGNUP {Referral to} REFERRED {Referred by} other {}}",this.rewardSourceText="{rewardSource, select, MANUAL {Manual} AUTOMATED {{programName}} other {}}",i(this)}disconnectedCallback(){}async renderCell(t,a){return e("sqm-rewards-table-source-cell",{reward:t,anonymousUserText:this.anonymousUser,deletedUserText:this.deletedUser,rewardExchangeText:this.rewardExchangeText,referralText:this.referralText,rewardSourceText:this.rewardSourceText,locale:null==a?void 0:a.locale})}async renderLabel(){return this.columnTitle}render(){return w([this.deletedUser,this.anonymousUser,this.columnTitle,this.rewardExchangeText,this.referralText,this.rewardSourceText]),e(a,{style:{display:"none"}})}},$=f({Badge:{"&::part(base)":{fontSize:"var(--sl-font-size-small)",padding:"4px 8px",paddingLeft:"10px",whiteSpace:"pre-line"}},RedeemBadge:{"&::part(base)":{fontSize:"var(--sl-font-size-small)",padding:"4px 8px",background:"var(--sl-color-blue-600)"}},Date:{fontSize:"var(--sl-font-size-small)",color:"var(--sl-color-neutral-500)",margin:"0"}}),B=$.toString(),j=class{constructor(e){t(this,e),this.expiryText="Expires",this.locale="en",this.pendingUsTax="W-9 required",this.pendingTaxReview="Awaiting tax form review.",this.pendingNewTaxForm="Invalid tax form. Submit a new form to receive your rewards.",this.pendingTaxSubmission="Submit your tax documents to receive your rewards.",this.pendingPartnerCreation="Complete your tax and cash payout setup to receive your rewards.",this.pendingScheduled="Until",this.pendingUnhandled="Fulfillment error",this.pendingReviewText="Awaiting review",this.deniedText="Detected self-referral",this.payoutFailed="Payout failed due to a fulfillment issue and is current being retried.",this.payoutApproved="Reward approved for payout and was scheduled for payment based on your settings.",this.payoutCancelled="If you think this is a mistake, contact our Support team."}rewardStatus(e){var t,a,s,r,l,i,n,o,d;const c=null===(t=e.statuses)||void 0===t?void 0:t.includes("EXPIRED"),u=null===(a=e.statuses)||void 0===a?void 0:a.includes("PENDING"),h="INTEGRATION"===e.type||"FUELTANK"===e.type,p=null===(r=null===(s=e.referral)||void 0===s?void 0:s.fraudData)||void 0===r?void 0:r.moderationStatus;if("DENIED"===p)return"DENIED";if("PENDING"===p)return"PENDING_REVIEW";const m=null===(l=e.partnerFundsTransfer)||void 0===l?void 0:l.status;return"TRANSFERRED"===m||"NOT_YET_DUE"===m?"PAYOUT_APPROVED":"OVERDUE"===m?"PAYOUT_FAILED":"REVERSED"===m?"PAYOUT_CANCELLED":e.dateCancelled?"CANCELLED":c?"EXPIRED":u?"PENDING":"CREDIT"===e.type?(null===(i=e.statuses)||void 0===i?void 0:i.includes("REDEEMED"))?"REDEEMED":"AVAILABLE":"PCT_DISCOUNT"===e.type&&(null===(n=e.statuses)||void 0===n?void 0:n.includes("AVAILABLE"))?"AVAILABLE":h&&u?"PENDING":h&&(null===(o=e.statuses)||void 0===o?void 0:o.includes("CANCELLED"))?"CANCELLED":h&&(null===(d=e.statuses)||void 0===d?void 0:d.includes("AVAILABLE"))?"AVAILABLE":""}getTaxPendingReasons(e,t){var a,s,r,l,i;if(null===(a=null==e?void 0:e.pendingReasons)||void 0===a?void 0:a.includes("US_TAX")){if(!(null==t?void 0:t.taxHandlingEnabled))return this.pendingUsTax;if(!(null==t?void 0:t.connected))return this.pendingPartnerCreation;if(null===(s=null==t?void 0:t.publisher)||void 0===s?void 0:s.requiredTaxDocumentType){if(!(null===(r=null==t?void 0:t.publisher)||void 0===r?void 0:r.currentTaxDocument))return this.pendingTaxSubmission;const e=t.publisher.currentTaxDocument.status;if("INACTIVE"===e)return this.pendingNewTaxForm;if("NOT_VERIFIED"===e)return this.pendingTaxReview}if(!(null===(l=null==t?void 0:t.publisher)||void 0===l?void 0:l.withdrawalSettings))return this.pendingPartnerCreation}return(null===(i=null==e?void 0:e.pendingReasons)||void 0===i?void 0:i.includes("PAYOUT_CONFIGURATION_MISSING"))?this.pendingPartnerCreation:""}getBadgeType(e){switch(e){case"AVAILABLE":return"success";case"REDEEMED":case"PAYOUT_APPROVED":return"primary";case"PENDING":case"PENDING_REVIEW":return"warning";default:return"danger"}}getPayoutStatusText(e){switch(e){case"US_TAX":return this.pendingUsTax;case"PAYOUT_APPROVED":return this.payoutApproved;case"PAYOUT_FAILED":return this.payoutFailed;case"PAYOUT_CANCELLED":return this.payoutCancelled;case"PENDING_TAX_REVIEW":return this.pendingTaxReview;case"PENDING_NEW_TAX_FORM":return this.pendingNewTaxForm;case"PENDING_TAX_SUBMISSION":return this.pendingTaxSubmission;case"PENDING_PARTNER_CREATION":return this.pendingPartnerCreation}}render(){var t;o.locale=this.locale;const a=this.rewardStatus(this.reward),s=o.formatMessage({id:"statusMessage",defaultMessage:this.statusText},{status:a}),r=this.getBadgeType(a),l=this.reward.dateCancelled||this.reward.dateExpires||this.reward.dateRedeemed||"",i=l&&`${"AVAILABLE"===a&&this.reward.dateExpires?this.expiryText+" ":""}${null===(t=x.DateTime.fromMillis(l))||void 0===t?void 0:t.setLocale(R(R(this.locale))).toLocaleString(x.DateTime.DATE_MED)}`,n="PENDING"===a?this.getTaxPendingReasons(this.reward,this.taxConnection)||function(e){var t;const a={SCHEDULED:e.reward.dateScheduledFor&&e.pendingScheduled+" "+(null===(t=x.DateTime.fromMillis(e.reward.dateScheduledFor))||void 0===t?void 0:t.setLocale(R(R(e.locale||"en"))).toLocaleString(x.DateTime.DATE_MED)),UNHANDLED_ERROR:e.pendingUnhandled,SUSPECTED_FRAUD:e.pendingReview},s=e.getTaxPendingReasons(e.reward,e.taxConnection);return[...s?[s]:[],...e.reward.pendingReasons.map((e=>{var t;return null!==(t=a[e])&&void 0!==t?t:e}))].join(", ")}(this):null,d="PENDING_REVIEW"===a?this.pendingReviewText:"DENIED"===a?this.deniedText:null;return e("div",{style:{display:"contents"}},e("style",{type:"text/css"},B),e("sl-badge",{type:r,pill:!0,class:"REDEEMED"===a||"PAYOUT_APPROVED"===a?$.classes.RedeemBadge:$.classes.Badge},s),e("p",{class:$.classes.Date},d||n||this.getPayoutStatusText(a)||i))}},z=class{constructor(e){t(this,e),this.columnTitle="Status",this.statusText="{status, select, AVAILABLE {Available} CANCELLED {Cancelled} PENDING {Pending} PENDING_REVIEW {Pending} PAYOUT_APPROVED {Payout Approved} PAYOUT_CANCELLED {Payout Cancelled} PAYOUT_FAILED {Payout Failed} EXPIRED {Expired} REDEEMED {Redeemed} DENIED {Denied} other {Not available} }",this.expiryText="Expires on ",this.pendingUsTax="W-9 required",this.pendingScheduled="Until",this.pendingUnhandled="Fulfillment error",this.pendingReviewText="Awaiting review",this.deniedText="Detected self-referral",this.pendingTaxReview="Awaiting tax form review.",this.pendingNewTaxForm="Invalid tax form. Submit a new form to receive your rewards.",this.pendingTaxSubmission="Submit your tax documents to receive your rewards.",this.pendingPartnerCreation="Complete your tax and cash payout setup to receive your rewards.",this.payoutFailed="Payout failed due to a fulfillment issue and is current being retried.",this.payoutCancelled="If you think this is a mistake, contact our Support team.",this.payoutApproved="Reward approved for payout and was scheduled for payment based on your settings.",i(this)}disconnectedCallback(){}async renderCell(t,a){return e("sqm-rewards-table-status-cell",{statusText:this.statusText,reward:t,taxConnection:null==a?void 0:a.taxConnection,expiryText:this.expiryText,pendingScheduled:this.pendingScheduled,pendingUsTax:this.pendingUsTax,pendingUnhandled:this.pendingUnhandled,pendingReviewText:this.pendingReviewText,payoutFailed:this.payoutFailed,payoutApproved:this.payoutApproved,payoutCancelled:this.payoutCancelled,deniedText:this.deniedText,locale:null==a?void 0:a.locale})}async renderLabel(){return this.columnTitle}render(){return w([this.columnTitle,this.statusText,this.expiryText,this.pendingReviewText,this.pendingScheduled,this.pendingUsTax,this.pendingUnhandled]),e(a,{style:{display:"none"}})}};export{P as sqm_rewards_table,U as sqm_rewards_table_date_cell,O as sqm_rewards_table_date_column,F as sqm_rewards_table_reward_cell,M as sqm_rewards_table_reward_column,V as sqm_rewards_table_source_cell,G as sqm_rewards_table_source_column,j as sqm_rewards_table_status_cell,z as sqm_rewards_table_status_column}
@@ -1 +1 @@
1
- var __makeTemplateObject=this&&this.__makeTemplateObject||function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var __assign=this&&this.__assign||function(){__assign=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++){t=arguments[n];for(var r in t)if(Object.prototype.hasOwnProperty.call(t,r))e[r]=t[r]}return e};return __assign.apply(this,arguments)};System.register(["./p-ff17b3a4.system.js","./p-2a414b2e.system.js","./p-6f980faf.system.js","./p-481dedf2.system.js","./p-4bd679a7.system.js","./p-1a673057.system.js","./p-6333265f.system.js","./p-4f775e84.system.js","./p-57ea9c0b.system.js","./p-0f010c01.system.js"],(function(e){"use strict";var t,n,i,r,s,a,o,u,l,d,f,m,c,v;return{setters:[function(e){t=e.r;n=e.h},function(e){i=e.k;r=e.f;s=e.n},function(){},function(e){a=e.d;o=e.Q;u=e.y;l=e.e;d=e.i},function(e){f=e.c},function(){},function(e){m=e.g},function(){},function(e){c=e.P},function(e){v=e.i}],execute:function(){var g=a.gql(__makeTemplateObject(["\n query {\n viewer {\n ... on User {\n id\n accountId\n firstName\n lastName\n email\n countryCode\n }\n }\n }\n"],["\n query {\n viewer {\n ... on User {\n id\n accountId\n firstName\n lastName\n email\n countryCode\n }\n }\n }\n"]));var _=a.gql(__makeTemplateObject(["\n mutation (\n $id: String!\n $accountId: String!\n $firstName: String!\n $lastName: String!\n ) {\n upsertUser(\n userInput: {\n id: $id\n accountId: $accountId\n firstName: $firstName\n lastName: $lastName\n }\n ) {\n firstName\n lastName\n }\n }\n"],["\n mutation (\n $id: String!\n $accountId: String!\n $firstName: String!\n $lastName: String!\n ) {\n upsertUser(\n userInput: {\n id: $id\n accountId: $accountId\n firstName: $firstName\n lastName: $lastName\n }\n ) {\n firstName\n lastName\n }\n }\n"]));var h={country:"",email:"",firstName:"",lastName:"",errors:{},error:""};function p(e){var t=o();var n=i(false),s=n[0],a=n[1];var d=i(undefined),f=d[0],m=d[1];var c=i(h),p=c[0],y=c[1];var b=u(g,{},!(t===null||t===void 0?void 0:t.jwt));var x=l(_),N=x[0],S=x[1];r((function(){if(S===null||S===void 0?void 0:S.loading)return;if(S===null||S===void 0?void 0:S.errors){y((function(e){var t,n,i;return __assign(__assign({},e),{error:(i=(n=(t=S===null||S===void 0?void 0:S.errors)===null||t===void 0?void 0:t.response)===null||n===void 0?void 0:n.errors)===null||i===void 0?void 0:i[0].message})}))}else{m((function(e){var t;return __assign(__assign({},e),(t=S===null||S===void 0?void 0:S.data)===null||t===void 0?void 0:t.upsertUser)}));if(S===null||S===void 0?void 0:S.data)a(true)}}),[S===null||S===void 0?void 0:S.loading]);r((function(){var e,t;m((function(e){var t;return __assign(__assign({},e),(t=b===null||b===void 0?void 0:b.data)===null||t===void 0?void 0:t.viewer)}));y(__assign(__assign(__assign({},h),(e=b.data)===null||e===void 0?void 0:e.viewer),(t=S.data)===null||t===void 0?void 0:t.upsertUser))}),[b===null||b===void 0?void 0:b.data]);r((function(){var t,n;if((t=S===null||S===void 0?void 0:S.errors)===null||t===void 0?void 0:t.message){y(__assign(__assign({},(n=b.data)===null||n===void 0?void 0:n.viewer),{error:e.networkRequestMessage}))}}),[S===null||S===void 0?void 0:S.errors]);var j=function(){a(false);if(p.firstName&&p.lastName){N({id:t===null||t===void 0?void 0:t.id,accountId:t===null||t===void 0?void 0:t.accountId,firstName:p.firstName,lastName:p.lastName});y((function(e){return __assign(__assign({},e),{errors:{},error:""})}));return}var n={};if(!p.firstName){n["firstName"]={message:e.fieldEmptyText}}if(!p.lastName){n["lastName"]={message:e.fieldEmptyText}}if(!v(n)){y((function(t){return __assign(__assign({},t),{error:e.formErrorText})}))}y((function(e){return __assign(__assign({},e),{errors:n})}))};return{states:{success:s,loading:(b===null||b===void 0?void 0:b.loading)||S.loading,submitDisabled:false,showCountry:!e.hideCountry,formState:p,user:f,text:{firstnametext:e.firstnametext,lastnametext:e.lastnametext,countrytext:e.countrytext,emailtext:e.emailtext,editProfileHeader:e.editProfileHeader,editProfileSubHeader:e.editProfileSubHeader,submitChangeButtonText:e.submitChangeButtonText}},callbacks:{onSubmit:j,onChange:function(e){var t=e.target,n=t.name,i=t.value;y((function(e){var t;return __assign(__assign({},e),(t={},t[n]=i,t))}))}}}}var y=e("sqm_portal_profile",function(){function e(e){t(this,e);this.ignored=true;this.firstnametext="First Name";this.lastnametext="Last Name";this.emailtext="Email";this.countrytext="Country";this.editProfileHeader="Edit your profile";this.editProfileSubHeader="Personal Information";this.submitChangeButtonText="Submit Changes";this.hideCountry=false;this.networkRequestMessage="An error occurred while loading this page. Please refresh the page.";this.fieldEmptyText="Field is required";this.formErrorText="Please correct the errors below to update your profile.";this.submissionSuccessText="Your profile has been successfully updated.";s(this)}e.prototype.disconnectedCallback=function(){};e.prototype.render=function(){var e=d()?b(m(this)):p(m(this));return n(c,Object.assign({},e))};return e}());function b(e){return f({states:{success:false,loading:false,submitDisabled:false,showCountry:!e.hideCountry,user:{id:"01",accountId:"111100000",firstName:"Joe",lastName:"Smith",email:"jsmith@gmail.com",countryCode:"CA"},text:{firstnametext:e.firstnametext,lastnametext:e.lastnametext,emailtext:e.emailtext,countrytext:e.countrytext,editProfileHeader:e.editProfileHeader,editProfileSubHeader:e.editProfileSubHeader,submitChangeButtonText:e.submitChangeButtonText,submissionSuccessText:e.submissionSuccessText,fieldEmptyText:e.fieldEmptyText},formState:{country:"Canada",firstName:"Joe",lastName:"Smith",errors:null,error:""}},callbacks:{onSubmit:function(e){return console.log(e)},onChange:function(e){return console.log(e)}}},e.demoData||{},{arrayMerge:function(e,t){return t}})}}}}));
1
+ var __makeTemplateObject=this&&this.__makeTemplateObject||function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var __assign=this&&this.__assign||function(){__assign=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++){t=arguments[n];for(var r in t)if(Object.prototype.hasOwnProperty.call(t,r))e[r]=t[r]}return e};return __assign.apply(this,arguments)};System.register(["./p-ff17b3a4.system.js","./p-2a414b2e.system.js","./p-c588e9c1.system.js","./p-46af0bf6.system.js","./p-4bd679a7.system.js","./p-1a673057.system.js","./p-6333265f.system.js","./p-4f775e84.system.js","./p-a2bce8d7.system.js","./p-8833552d.system.js"],(function(e){"use strict";var t,n,i,r,s,a,o,u,l,d,f,m,c,v;return{setters:[function(e){t=e.r;n=e.h},function(e){i=e.k;r=e.f;s=e.n},function(){},function(e){a=e.d;o=e.J;u=e.w;l=e.$;d=e.i},function(e){f=e.c},function(){},function(e){m=e.g},function(){},function(e){c=e.P},function(e){v=e.i}],execute:function(){var g=a.gql(__makeTemplateObject(["\n query {\n viewer {\n ... on User {\n id\n accountId\n firstName\n lastName\n email\n countryCode\n }\n }\n }\n"],["\n query {\n viewer {\n ... on User {\n id\n accountId\n firstName\n lastName\n email\n countryCode\n }\n }\n }\n"]));var _=a.gql(__makeTemplateObject(["\n mutation (\n $id: String!\n $accountId: String!\n $firstName: String!\n $lastName: String!\n ) {\n upsertUser(\n userInput: {\n id: $id\n accountId: $accountId\n firstName: $firstName\n lastName: $lastName\n }\n ) {\n firstName\n lastName\n }\n }\n"],["\n mutation (\n $id: String!\n $accountId: String!\n $firstName: String!\n $lastName: String!\n ) {\n upsertUser(\n userInput: {\n id: $id\n accountId: $accountId\n firstName: $firstName\n lastName: $lastName\n }\n ) {\n firstName\n lastName\n }\n }\n"]));var h={country:"",email:"",firstName:"",lastName:"",errors:{},error:""};function p(e){var t=o();var n=i(false),s=n[0],a=n[1];var d=i(undefined),f=d[0],m=d[1];var c=i(h),p=c[0],y=c[1];var b=u(g,{},!(t===null||t===void 0?void 0:t.jwt));var x=l(_),N=x[0],S=x[1];r((function(){if(S===null||S===void 0?void 0:S.loading)return;if(S===null||S===void 0?void 0:S.errors){y((function(e){var t,n,i;return __assign(__assign({},e),{error:(i=(n=(t=S===null||S===void 0?void 0:S.errors)===null||t===void 0?void 0:t.response)===null||n===void 0?void 0:n.errors)===null||i===void 0?void 0:i[0].message})}))}else{m((function(e){var t;return __assign(__assign({},e),(t=S===null||S===void 0?void 0:S.data)===null||t===void 0?void 0:t.upsertUser)}));if(S===null||S===void 0?void 0:S.data)a(true)}}),[S===null||S===void 0?void 0:S.loading]);r((function(){var e,t;m((function(e){var t;return __assign(__assign({},e),(t=b===null||b===void 0?void 0:b.data)===null||t===void 0?void 0:t.viewer)}));y(__assign(__assign(__assign({},h),(e=b.data)===null||e===void 0?void 0:e.viewer),(t=S.data)===null||t===void 0?void 0:t.upsertUser))}),[b===null||b===void 0?void 0:b.data]);r((function(){var t,n;if((t=S===null||S===void 0?void 0:S.errors)===null||t===void 0?void 0:t.message){y(__assign(__assign({},(n=b.data)===null||n===void 0?void 0:n.viewer),{error:e.networkRequestMessage}))}}),[S===null||S===void 0?void 0:S.errors]);var j=function(){a(false);if(p.firstName&&p.lastName){N({id:t===null||t===void 0?void 0:t.id,accountId:t===null||t===void 0?void 0:t.accountId,firstName:p.firstName,lastName:p.lastName});y((function(e){return __assign(__assign({},e),{errors:{},error:""})}));return}var n={};if(!p.firstName){n["firstName"]={message:e.fieldEmptyText}}if(!p.lastName){n["lastName"]={message:e.fieldEmptyText}}if(!v(n)){y((function(t){return __assign(__assign({},t),{error:e.formErrorText})}))}y((function(e){return __assign(__assign({},e),{errors:n})}))};return{states:{success:s,loading:(b===null||b===void 0?void 0:b.loading)||S.loading,submitDisabled:false,showCountry:!e.hideCountry,formState:p,user:f,text:{firstnametext:e.firstnametext,lastnametext:e.lastnametext,countrytext:e.countrytext,emailtext:e.emailtext,editProfileHeader:e.editProfileHeader,editProfileSubHeader:e.editProfileSubHeader,submitChangeButtonText:e.submitChangeButtonText}},callbacks:{onSubmit:j,onChange:function(e){var t=e.target,n=t.name,i=t.value;y((function(e){var t;return __assign(__assign({},e),(t={},t[n]=i,t))}))}}}}var y=e("sqm_portal_profile",function(){function e(e){t(this,e);this.ignored=true;this.firstnametext="First Name";this.lastnametext="Last Name";this.emailtext="Email";this.countrytext="Country";this.editProfileHeader="Edit your profile";this.editProfileSubHeader="Personal Information";this.submitChangeButtonText="Submit Changes";this.hideCountry=false;this.networkRequestMessage="An error occurred while loading this page. Please refresh the page.";this.fieldEmptyText="Field is required";this.formErrorText="Please correct the errors below to update your profile.";this.submissionSuccessText="Your profile has been successfully updated.";s(this)}e.prototype.disconnectedCallback=function(){};e.prototype.render=function(){var e=d()?b(m(this)):p(m(this));return n(c,Object.assign({},e))};return e}());function b(e){return f({states:{success:false,loading:false,submitDisabled:false,showCountry:!e.hideCountry,user:{id:"01",accountId:"111100000",firstName:"Joe",lastName:"Smith",email:"jsmith@gmail.com",countryCode:"CA"},text:{firstnametext:e.firstnametext,lastnametext:e.lastnametext,emailtext:e.emailtext,countrytext:e.countrytext,editProfileHeader:e.editProfileHeader,editProfileSubHeader:e.editProfileSubHeader,submitChangeButtonText:e.submitChangeButtonText,submissionSuccessText:e.submissionSuccessText,fieldEmptyText:e.fieldEmptyText},formState:{country:"Canada",firstName:"Joe",lastName:"Smith",errors:null,error:""}},callbacks:{onSubmit:function(e){return console.log(e)},onChange:function(e){return console.log(e)}}},e.demoData||{},{arrayMerge:function(e,t){return t}})}}}}));
@@ -1 +1 @@
1
- import{h as s,c as t,r as a}from"./p-64c3217a.js";import{n as o}from"./p-fd2c5407.js";import{B as c}from"./p-9b4a99c4.js";import{g as e}from"./p-9ec99ced.js";const n=a=>{const{states:o,callbacks:c}=a,{styles:e}=o;return s(t,{class:"squatch-container"},s("div",{style:{padding:a.states.styles.padding},part:"sqm-base"},e.closeButton&&s("span",{part:"sqm-close-button",class:"close squatch-header-close","data-close-panel":"#squatch-panel",onClick:()=>c.closePopup()},e.closeButtonText),s("slot",null),e.poweredBy?s("a",{class:"sqh-attribution",href:"https://impact.com/advocate/",target:"_blank"},e.poweredByText):""))},r=class{constructor(s){a(this,s),this.poweredByText="Powered By",o(this)}disconnectedCallback(){}render(){const t=e(this);return s(n,Object.assign({},function(s){const t=c(),a=s.popupPadding?"none"===s.popupPadding?"0":`var(--sl-spacing-${s.popupPadding})`:"var(--sl-spacing-medium)",o=s.embedPadding?"none"===s.embedPadding?"0":`var(--sl-spacing-${s.embedPadding})`:"0",e="POPUP"===c()?a:o;return{states:{showCloseButton:s.closeButton&&"POPUP"===t,styles:{...s,padding:e,closeButtonText:s.closeButtonText?s.closeButtonText:"X",poweredByText:s.poweredByText}},data:{},callbacks:{closePopup:function(){var s;"POPUP"===c()&&(null===(s=window.frameElement.squatchJsApi)||void 0===s||s.close())}}}}(t)))}};r.style=".squatch-header-close{position:absolute;right:20px;top:10px;cursor:pointer}.squatch-container{background-color:var(--widget-background-color);display:block}";export{r as sqm_popup_container}
1
+ import{h as s,c as t,r as a}from"./p-64c3217a.js";import{n as o}from"./p-fd2c5407.js";import{B as c}from"./p-2037fbd3.js";import{g as e}from"./p-9ec99ced.js";const n=a=>{const{states:o,callbacks:c}=a,{styles:e}=o;return s(t,{class:"squatch-container"},s("div",{style:{padding:a.states.styles.padding},part:"sqm-base"},e.closeButton&&s("span",{part:"sqm-close-button",class:"close squatch-header-close","data-close-panel":"#squatch-panel",onClick:()=>c.closePopup()},e.closeButtonText),s("slot",null),e.poweredBy?s("a",{class:"sqh-attribution",href:"https://impact.com/advocate/",target:"_blank"},e.poweredByText):""))},r=class{constructor(s){a(this,s),this.poweredByText="Powered By",o(this)}disconnectedCallback(){}render(){const t=e(this);return s(n,Object.assign({},function(s){const t=c(),a=s.popupPadding?"none"===s.popupPadding?"0":`var(--sl-spacing-${s.popupPadding})`:"var(--sl-spacing-medium)",o=s.embedPadding?"none"===s.embedPadding?"0":`var(--sl-spacing-${s.embedPadding})`:"0",e="POPUP"===c()?a:o;return{states:{showCloseButton:s.closeButton&&"POPUP"===t,styles:{...s,padding:e,closeButtonText:s.closeButtonText?s.closeButtonText:"X",poweredByText:s.poweredByText}},data:{},callbacks:{closePopup:function(){var s;"POPUP"===c()&&(null===(s=window.frameElement.squatchJsApi)||void 0===s||s.close())}}}}(t)))}};r.style=".squatch-header-close{position:absolute;right:20px;top:10px;cursor:pointer}.squatch-container{background-color:var(--widget-background-color);display:block}";export{r as sqm_popup_container}
@@ -1 +1 @@
1
- System.register(["./p-ff17b3a4.system.js","./p-2a414b2e.system.js","./p-481dedf2.system.js","./p-f6934a55.system.js","./p-1a673057.system.js","./p-c5577dd7.system.js"],(function(t){"use strict";var n,e,s,o,i;return{setters:[function(t){n=t.r;e=t.h},function(t){s=t.n},function(t){o=t.a},function(){},function(){},function(t){i=t.C}],execute:function(){var c=t("sqm_close_button",function(){function t(t){n(this,t);this.color="#000000";s(this)}t.prototype.disconnectedCallback=function(){};t.prototype.render=function(){var t;var n=o();var s=n.type==="SquatchJS2"&&((t=n.widgetIdent)===null||t===void 0?void 0:t.engagementMedium)==="POPUP";if(!s)return e("div",{style:{display:"none"}});var c=function(){var t,e;if(n.type==="SquatchJS2"){(e=(t=n.api).close)===null||e===void 0?void 0:e.call(t)}};return e(i,{onClick:c,color:this.color})};return t}())}}}));
1
+ System.register(["./p-ff17b3a4.system.js","./p-2a414b2e.system.js","./p-46af0bf6.system.js","./p-f6934a55.system.js","./p-1a673057.system.js","./p-c5577dd7.system.js"],(function(t){"use strict";var n,e,s,o,i;return{setters:[function(t){n=t.r;e=t.h},function(t){s=t.n},function(t){o=t.g},function(){},function(){},function(t){i=t.C}],execute:function(){var c=t("sqm_close_button",function(){function t(t){n(this,t);this.color="#000000";s(this)}t.prototype.disconnectedCallback=function(){};t.prototype.render=function(){var t;var n=o();var s=n.type==="SquatchJS2"&&((t=n.widgetIdent)===null||t===void 0?void 0:t.engagementMedium)==="POPUP";if(!s)return e("div",{style:{display:"none"}});var c=function(){var t,e;if(n.type==="SquatchJS2"){(e=(t=n.api).close)===null||e===void 0?void 0:e.call(t)}};return e(i,{onClick:c,color:this.color})};return t}())}}}));
@@ -0,0 +1 @@
1
+ import{h as s,c as r,r as t}from"./p-64c3217a.js";import{n as o}from"./p-fd2c5407.js";import"./p-2037fbd3.js";import{a}from"./p-920641bf.js";const c=({},t)=>s(r,null,t),l=class{constructor(s){t(this,s),o(this)}disconnectedCallback(){}render(){return a([this.header]),s(c,null,s("slot",null))}};export{l as sqm_tab}
@@ -1 +1 @@
1
- import{r as e,h as i}from"./p-64c3217a.js";import{k as a,m as t,f as s,n}from"./p-fd2c5407.js";import"./p-c4719154.js";import{l as r,n as o,Q as l,$ as c,u as d,i as v}from"./p-9b4a99c4.js";import{c as u}from"./p-c1086930.js";import"./p-02be1a88.js";import"./p-cef45012.js";import"./p-5d0c9424.js";import{P as m}from"./p-da1e21f2.js";const f=class{constructor(i){e(this,i),this.ignored=!0,this.redirectPath="/verifyEmail",this.emailVerificationHeader="Verify your email",this.resendEmailButtonText="Re-send Email",this.verifyMessage="A verification email was sent to {email}. Please verify your email to continue to the portal. Resending an email will invalidate the previous email.",this.verificationStatusMessage="Checking verification status in {countdown}",this.verificationLoadingMessage="Checking verification status",this.verificationResentMessage="Your verification email has been resent successfully",this.networkErrorMessage="An error occurred while verifying your password. Please refresh the page.",n(this)}disconnectedCallback(){}render(){const{states:e,callbacks:n,content:f}=v()?u({states:{error:"",loading:!1,success:!1,countdown:10},callbacks:{submit:async()=>{}},content:{email:"test@example.com",verifyMessage:(h=this).verifyMessage,emailVerificationHeader:h.emailVerificationHeader,resendEmailButtonText:h.resendEmailButtonText,verificationLoadingMessage:h.verificationLoadingMessage,verificationStatusMessage:h.verificationStatusMessage,verificationResentMessage:h.verificationResentMessage,networkErrorMessage:h.networkErrorMessage}},h.demoData||{},{arrayMerge:(e,i)=>i}):function(e){var i,n,v,u,m,f,h,g,p;const[y,{loading:b,errors:w}]=r(),[M,{data:k,loading:j}]=o(),I=l(),P=null===(i=null==I?void 0:I.managedIdentity)||void 0===i?void 0:i.email,E=new URLSearchParams(c.location.search),x=E.get("nextPage"),[R,V]=a(!1),[C,L]=a(""),[S,_]=a(10),A=t(void 0),B=t(void 0);async function H(){var i;const a=await M();if(null===(i=null==a?void 0:a.managedIdentitySession)||void 0===i?void 0:i.emailVerified)return clearInterval(A.current),c.push({pathname:e.redirectPath,search:E.toString()&&"?"+E.toString()});U(10)}const T=(e=1e4)=>setInterval(H,e),q=e=>setInterval((()=>_(e)),1e3);function U(e){if(clearInterval(B.current),clearInterval(A.current),"hidden"===document.visibilityState)return;e&&_(e);let i=S||10;B.current=q(e-1||i-1),A.current=T(1e3*e||1e3*i)}const Y=d((()=>U()),[S]);return s((()=>(A.current||(H(),A.current=T()),()=>{clearInterval(A.current)})),[]),s((()=>(S>0&&(clearInterval(B.current),B.current=q(S-1)),document.addEventListener("visibilitychange",Y),()=>{clearInterval(B.current),document.removeEventListener("visibilitychange",Y)})),[S]),{states:{loading:b,error:(null===(m=null===(u=null===(v=null===(n=null==w?void 0:w.response)||void 0===n?void 0:n.errors)||void 0===v?void 0:v[0])||void 0===u?void 0:u.extensions)||void 0===m?void 0:m.message)||(null===(g=null===(h=null===(f=null==w?void 0:w.response)||void 0===f?void 0:f.errors)||void 0===h?void 0:h[0])||void 0===g?void 0:g.message)||C,success:R,loadingVerification:j,isVerified:!!(null===(p=null==k?void 0:k.managedIdentitySession)||void 0===p?void 0:p.emailVerified),countdown:S},callbacks:{submit:async()=>{var i;if(!P)return;L(""),V(!1);const a={email:P,urlParams:x?{nextPage:x}:null,redirectPath:e.redirectPath},t=await y(a);t instanceof Error?t.message&&L(e.networkErrorMessage):(null===(i=t.requestManagedIdentityVerificationEmail)||void 0===i?void 0:i.success)&&V(!0)}},content:{email:P,verifyMessage:e.verifyMessage,emailVerificationHeader:e.emailVerificationHeader,resendEmailButtonText:e.resendEmailButtonText,verificationLoadingMessage:e.verificationLoadingMessage,verificationStatusMessage:e.verificationStatusMessage,verificationResentMessage:e.verificationResentMessage,networkErrorMessage:e.networkErrorMessage}}}(this);var h;return i(m,{states:e,callbacks:n,content:f})}};export{f as sqm_portal_email_verification}
1
+ import{r as e,h as i}from"./p-64c3217a.js";import{k as a,m as t,f as s,n}from"./p-fd2c5407.js";import"./p-eb64a65f.js";import{l as r,n as o,J as l,j as c,u as d,i as v}from"./p-2037fbd3.js";import{c as u}from"./p-c1086930.js";import"./p-02be1a88.js";import"./p-cef45012.js";import"./p-5d0c9424.js";import{P as m}from"./p-e10b0628.js";const f=class{constructor(i){e(this,i),this.ignored=!0,this.redirectPath="/verifyEmail",this.emailVerificationHeader="Verify your email",this.resendEmailButtonText="Re-send Email",this.verifyMessage="A verification email was sent to {email}. Please verify your email to continue to the portal. Resending an email will invalidate the previous email.",this.verificationStatusMessage="Checking verification status in {countdown}",this.verificationLoadingMessage="Checking verification status",this.verificationResentMessage="Your verification email has been resent successfully",this.networkErrorMessage="An error occurred while verifying your password. Please refresh the page.",n(this)}disconnectedCallback(){}render(){const{states:e,callbacks:n,content:f}=v()?u({states:{error:"",loading:!1,success:!1,countdown:10},callbacks:{submit:async()=>{}},content:{email:"test@example.com",verifyMessage:(h=this).verifyMessage,emailVerificationHeader:h.emailVerificationHeader,resendEmailButtonText:h.resendEmailButtonText,verificationLoadingMessage:h.verificationLoadingMessage,verificationStatusMessage:h.verificationStatusMessage,verificationResentMessage:h.verificationResentMessage,networkErrorMessage:h.networkErrorMessage}},h.demoData||{},{arrayMerge:(e,i)=>i}):function(e){var i,n,v,u,m,f,h,g,p;const[y,{loading:b,errors:w}]=r(),[M,{data:j,loading:k}]=o(),I=l(),P=null===(i=null==I?void 0:I.managedIdentity)||void 0===i?void 0:i.email,E=new URLSearchParams(c.location.search),x=E.get("nextPage"),[R,V]=a(!1),[C,L]=a(""),[S,_]=a(10),A=t(void 0),B=t(void 0);async function H(){var i;const a=await M();if(null===(i=null==a?void 0:a.managedIdentitySession)||void 0===i?void 0:i.emailVerified)return clearInterval(A.current),c.push({pathname:e.redirectPath,search:E.toString()&&"?"+E.toString()});U(10)}const T=(e=1e4)=>setInterval(H,e),q=e=>setInterval((()=>_(e)),1e3);function U(e){if(clearInterval(B.current),clearInterval(A.current),"hidden"===document.visibilityState)return;e&&_(e);let i=S||10;B.current=q(e-1||i-1),A.current=T(1e3*e||1e3*i)}const Y=d((()=>U()),[S]);return s((()=>(A.current||(H(),A.current=T()),()=>{clearInterval(A.current)})),[]),s((()=>(S>0&&(clearInterval(B.current),B.current=q(S-1)),document.addEventListener("visibilitychange",Y),()=>{clearInterval(B.current),document.removeEventListener("visibilitychange",Y)})),[S]),{states:{loading:b,error:(null===(m=null===(u=null===(v=null===(n=null==w?void 0:w.response)||void 0===n?void 0:n.errors)||void 0===v?void 0:v[0])||void 0===u?void 0:u.extensions)||void 0===m?void 0:m.message)||(null===(g=null===(h=null===(f=null==w?void 0:w.response)||void 0===f?void 0:f.errors)||void 0===h?void 0:h[0])||void 0===g?void 0:g.message)||C,success:R,loadingVerification:k,isVerified:!!(null===(p=null==j?void 0:j.managedIdentitySession)||void 0===p?void 0:p.emailVerified),countdown:S},callbacks:{submit:async()=>{var i;if(!P)return;L(""),V(!1);const a={email:P,urlParams:x?{nextPage:x}:null,redirectPath:e.redirectPath},t=await y(a);t instanceof Error?t.message&&L(e.networkErrorMessage):(null===(i=t.requestManagedIdentityVerificationEmail)||void 0===i?void 0:i.success)&&V(!0)}},content:{email:P,verifyMessage:e.verifyMessage,emailVerificationHeader:e.emailVerificationHeader,resendEmailButtonText:e.resendEmailButtonText,verificationLoadingMessage:e.verificationLoadingMessage,verificationStatusMessage:e.verificationStatusMessage,verificationResentMessage:e.verificationResentMessage,networkErrorMessage:e.networkErrorMessage}}}(this);var h;return i(m,{states:e,callbacks:n,content:f})}};export{f as sqm_portal_email_verification}
@@ -0,0 +1 @@
1
+ import{r as s,h as t,c as o}from"./p-64c3217a.js";import{o as a,f as r,n}from"./p-fd2c5407.js";import{G as c,E as i,Q as e,P as l}from"./p-2037fbd3.js";const p=class{constructor(t){s(this,t),this.ignored=!0,n(this)}disconnectedCallback(){}render(){return async function({domain:s}){const t=c(),o=s,n=e(),p=i(o,n,t),[,d]=a(l,p);r((()=>{d(p)}),[p])}(this),t(o,{style:{display:"contents"}},t("slot",null))}};export{p as sqm_graphql_client_provider}
@@ -1,4 +1,4 @@
1
- import{r as i,h as t}from"./p-64c3217a.js";import{n as r}from"./p-fd2c5407.js";import{d as e,Q as o,y as s,b as a,i as c}from"./p-9b4a99c4.js";import{c as n}from"./p-c1086930.js";import"./p-cef45012.js";import{g as l}from"./p-9ec99ced.js";import{L as m}from"./p-e3e16c36.js";const d=e.gql`
1
+ import{r as i,h as t}from"./p-64c3217a.js";import{n as r}from"./p-fd2c5407.js";import{d as e,J as o,w as s,a,i as n}from"./p-2037fbd3.js";import{c}from"./p-c1086930.js";import"./p-cef45012.js";import{g as l}from"./p-9ec99ced.js";import{L as m}from"./p-e3e16c36.js";const d=e.gql`
2
2
  query getUserDetails {
3
3
  viewer {
4
4
  ... on User {
@@ -8,4 +8,4 @@ import{r as i,h as t}from"./p-64c3217a.js";import{n as r}from"./p-fd2c5407.js";i
8
8
  }
9
9
  }
10
10
  }
11
- `,h=class{constructor(t){i(this,t),this.userIdentificationText="{email}",this.switchUserText="not you?",this.emailErrorText="Error fetching email",r(this)}disconnectedCallback(){}render(){const i=c()?function(i){return n({onSwitchClick:()=>a(void 0),filledInEmailText:"john@example.com",switchUserText:i.switchUserText,emailErrorText:i.emailErrorText,loading:!1},i.demoData||{},{arrayMerge:(i,t)=>t})}(this):function(i){var t,r;const e=o(),{loading:c,data:n}=s(d,{},!e);return{loading:c,onSwitchClick:()=>{a(void 0)},filledInEmailText:null===(t=i.userIdentificationText)||void 0===t?void 0:t.replace("{email}",null===(r=null==n?void 0:n.viewer)||void 0===r?void 0:r.email),...i}}(l(this));return t(m,Object.assign({},i,{userIdentificationText:this.userIdentificationText,switchUserText:this.switchUserText,emailErrorText:this.emailErrorText}))}};export{h as sqm_logout_current_user}
11
+ `,h=class{constructor(t){i(this,t),this.userIdentificationText="{email}",this.switchUserText="not you?",this.emailErrorText="Error fetching email",r(this)}disconnectedCallback(){}render(){const i=n()?function(i){return c({onSwitchClick:()=>a(void 0),filledInEmailText:"john@example.com",switchUserText:i.switchUserText,emailErrorText:i.emailErrorText,loading:!1},i.demoData||{},{arrayMerge:(i,t)=>t})}(this):function(i){var t,r;const e=o(),{loading:n,data:c}=s(d,{},!e);return{loading:n,onSwitchClick:()=>{a(void 0)},filledInEmailText:null===(t=i.userIdentificationText)||void 0===t?void 0:t.replace("{email}",null===(r=null==c?void 0:c.viewer)||void 0===r?void 0:r.email),...i}}(l(this));return t(m,Object.assign({},i,{userIdentificationText:this.userIdentificationText,switchUserText:this.switchUserText,emailErrorText:this.emailErrorText}))}};export{h as sqm_logout_current_user}
@@ -1 +1 @@
1
- System.register(["./p-2a414b2e.system.js","./p-481dedf2.system.js"],(function(n){"use strict";var e,t,r;return{setters:[function(n){e=n.k;t=n.f},function(n){r=n.u}],execute:function(){n({a:u,b:i,i:s});function i(n){var i=e(window.innerWidth),u=i[0],s=i[1];var o=r((function(){return s(window.innerWidth)}),[]);t((function(){window.addEventListener("resize",o);return function(){return window.removeEventListener("resize",o)}}),[]);return u>n?false:true}function u(n){return CSS.supports("(color: "+n+")")}function s(n){return!n||Object.keys(n).length===0&&n.constructor===Object}}}}));
1
+ System.register(["./p-2a414b2e.system.js","./p-46af0bf6.system.js"],(function(n){"use strict";var e,t,r;return{setters:[function(n){e=n.k;t=n.f},function(n){r=n.u}],execute:function(){n({a:u,b:i,i:s});function i(n){var i=e(window.innerWidth),u=i[0],s=i[1];var o=r((function(){return s(window.innerWidth)}),[]);t((function(){window.addEventListener("resize",o);return function(){return window.removeEventListener("resize",o)}}),[]);return u>n?false:true}function u(n){return CSS.supports("(color: "+n+")")}function s(n){return!n||Object.keys(n).length===0&&n.constructor===Object}}}}));
@@ -1 +1 @@
1
- import{h as t,r as e,c as n}from"./p-64c3217a.js";import{n as s}from"./p-fd2c5407.js";import{i as a}from"./p-c4719154.js";import"./p-9b4a99c4.js";import"./p-cef45012.js";import{g as r}from"./p-9ec99ced.js";import{P as o,a as l}from"./p-c7fd9e16.js";function i(e){const{emptyStateHeader:n,emptyStateImage:s,emptyStateText:r,supportText:o,missingFeature:l=""}=e;return t("sqm-portal-container",{padding:"large",gap:"medium",part:"sqm-base"},t("img",{style:{height:"100px",margin:"auto"},src:s}),t("sqm-titled-section",{style:{maxHeight:"400px"},"label-margin":"xxx-small","text-align":"center"},t("sqm-text",{slot:"label"},t("p",{part:"header-text"},n)),t("sqm-text",{slot:"content"},t("p",{part:"description-text",innerHTML:"",style:{color:"var(--sl-color-gray-500)"}},a.formatMessage({id:"emptyStateText",defaultMessage:r},{supportText:t("a",{target:"_blank",href:`mailto:saasquatch-support@impact.com?subject=Next steps for ${l} feature&body=Hi Support Team, %0D%0A\n %0D%0A \n I am interested to learn more about the ${l} feature. Please let me know the next steps to access this feature, including any necessary plan upgrades.%0D%0A\n %0D%0A \n - Feature Interested In: ${l}%0D%0A\n - Company Name: [Please fill out your company name here]%0D%0A\n %0D%0A\n Thank you`},o)})))))}const m=class{constructor(t){e(this,t)}render(){return t(n,{slot:"empty"},t(i,{emptyStateImage:this.emptyStateImage,emptyStateHeader:this.emptyStateHeader,emptyStateText:this.emptyStateText,supportText:this.supportText}))}},c=class{constructor(t){e(this,t),this.ignored=!0,this.direction="column",this.gap="xxx-large",this.display="grid",this.maxWidth="100%",this.flexWrap="wrap",this.backgroundColor="#ffffff00",s(this)}disconnectedCallback(){}render(){return t(o,Object.assign({},r(this)),t("slot",null))}},p=class{constructor(t){e(this,t),this.ignored=!0,s(this)}disconnectedCallback(){}componentWillLoad(){}render(){return t("div",null,t("style",null,"\n sqm-text {\n display: block;\n }\n\n sqm-text h1 {\n font-size: var(--sl-font-size-xxx-large);\n font-weight: var(--sl-font-weight-semibold);\n color: var(--sl-color-neutral-800);\n margin: 0;\n }\n\n sqm-text h2 {\n font-size: var(--sl-font-size-xx-large);\n font-weight: var(--sl-font-weight-semibold);\n color: var(--sl-color-neutral-800);\n margin: 0;\n }\n\n sqm-text h3 {\n font-size: var(--sl-font-size-x-large);\n font-weight: var(--sl-font-weight-semibold);\n color: var(--sl-color-neutral-800);\n margin: 0;\n }\n\n sqm-text h4 {\n font-size: var(--sl-font-size-large);\n font-weight: var(--sl-font-weight-semibold);\n color: var(--sl-color-neutral-800);\n margin: 0;\n }\n\n sqm-text p {\n font-size: var(--sl-font-size-medium);\n font-weight: var(--sl-font-weight-normal);\n color: var(--sl-color-neutral-800);\n margin: 0;\n }\n\n sqm-text sub {\n font-size: var(--sl-font-size-small);\n font-weight: var(--sl-font-weight-normal);\n color: var(--sl-color-neutral-400);\n margin: 0;\n }\n"),t("slot",null))}},h=class{constructor(t){e(this,t),this.textAlign="left",this.labelMargin="small",this.padding="none",s(this)}disconnectedCallback(){}render(){const e=t("slot",{name:"label"},this.label),n=t("slot",{name:"content"});return t(l,Object.assign({},{...r(this),label:e,content:n}))}};export{m as sqm_empty,c as sqm_portal_container,p as sqm_text,h as sqm_titled_section}
1
+ import{h as t,r as e,c as n}from"./p-64c3217a.js";import{n as s}from"./p-fd2c5407.js";import{i as a}from"./p-eb64a65f.js";import"./p-2037fbd3.js";import"./p-cef45012.js";import{g as r}from"./p-9ec99ced.js";import{P as o,a as l}from"./p-c7fd9e16.js";function i(e){const{emptyStateHeader:n,emptyStateImage:s,emptyStateText:r,supportText:o,missingFeature:l=""}=e;return t("sqm-portal-container",{padding:"large",gap:"medium",part:"sqm-base"},t("img",{style:{height:"100px",margin:"auto"},src:s}),t("sqm-titled-section",{style:{maxHeight:"400px"},"label-margin":"xxx-small","text-align":"center"},t("sqm-text",{slot:"label"},t("p",{part:"header-text"},n)),t("sqm-text",{slot:"content"},t("p",{part:"description-text",innerHTML:"",style:{color:"var(--sl-color-gray-500)"}},a.formatMessage({id:"emptyStateText",defaultMessage:r},{supportText:t("a",{target:"_blank",href:`mailto:saasquatch-support@impact.com?subject=Next steps for ${l} feature&body=Hi Support Team, %0D%0A\n %0D%0A \n I am interested to learn more about the ${l} feature. Please let me know the next steps to access this feature, including any necessary plan upgrades.%0D%0A\n %0D%0A \n - Feature Interested In: ${l}%0D%0A\n - Company Name: [Please fill out your company name here]%0D%0A\n %0D%0A\n Thank you`},o)})))))}const m=class{constructor(t){e(this,t)}render(){return t(n,{slot:"empty"},t(i,{emptyStateImage:this.emptyStateImage,emptyStateHeader:this.emptyStateHeader,emptyStateText:this.emptyStateText,supportText:this.supportText}))}},c=class{constructor(t){e(this,t),this.ignored=!0,this.direction="column",this.gap="xxx-large",this.display="grid",this.maxWidth="100%",this.flexWrap="wrap",this.backgroundColor="#ffffff00",s(this)}disconnectedCallback(){}render(){return t(o,Object.assign({},r(this)),t("slot",null))}},p=class{constructor(t){e(this,t),this.ignored=!0,s(this)}disconnectedCallback(){}componentWillLoad(){}render(){return t("div",null,t("style",null,"\n sqm-text {\n display: block;\n }\n\n sqm-text h1 {\n font-size: var(--sl-font-size-xxx-large);\n font-weight: var(--sl-font-weight-semibold);\n color: var(--sl-color-neutral-800);\n margin: 0;\n }\n\n sqm-text h2 {\n font-size: var(--sl-font-size-xx-large);\n font-weight: var(--sl-font-weight-semibold);\n color: var(--sl-color-neutral-800);\n margin: 0;\n }\n\n sqm-text h3 {\n font-size: var(--sl-font-size-x-large);\n font-weight: var(--sl-font-weight-semibold);\n color: var(--sl-color-neutral-800);\n margin: 0;\n }\n\n sqm-text h4 {\n font-size: var(--sl-font-size-large);\n font-weight: var(--sl-font-weight-semibold);\n color: var(--sl-color-neutral-800);\n margin: 0;\n }\n\n sqm-text p {\n font-size: var(--sl-font-size-medium);\n font-weight: var(--sl-font-weight-normal);\n color: var(--sl-color-neutral-800);\n margin: 0;\n }\n\n sqm-text sub {\n font-size: var(--sl-font-size-small);\n font-weight: var(--sl-font-weight-normal);\n color: var(--sl-color-neutral-400);\n margin: 0;\n }\n"),t("slot",null))}},h=class{constructor(t){e(this,t),this.textAlign="left",this.labelMargin="small",this.padding="none",s(this)}disconnectedCallback(){}render(){const e=t("slot",{name:"label"},this.label),n=t("slot",{name:"content"});return t(l,Object.assign({},{...r(this),label:e,content:n}))}};export{m as sqm_empty,c as sqm_portal_container,p as sqm_text,h as sqm_titled_section}
@@ -1 +1 @@
1
- import{f as e}from"./p-fd2c5407.js";import{_ as r,g as s}from"./p-9b4a99c4.js";function t(s){const t=r();e((()=>{t.dispatchEvent(new CustomEvent("sqm:request-rerender",{detail:!0,bubbles:!0,composed:!0}))}),s)}function n(){const t=r(),[n,o]=s();return e((()=>{const e=e=>{e.stopPropagation(),o()};return t.addEventListener("sqm:request-rerender",e),()=>{t.removeEventListener("sqm:request-rerender",e)}}),[]),n}export{t as a,n as u}
1
+ import{f as e}from"./p-fd2c5407.js";import{_ as r,y as s}from"./p-2037fbd3.js";function t(s){const t=r();e((()=>{t.dispatchEvent(new CustomEvent("sqm:request-rerender",{detail:!0,bubbles:!0,composed:!0}))}),s)}function n(){const t=r(),[n,o]=s();return e((()=>{const e=e=>{e.stopPropagation(),o()};return t.addEventListener("sqm:request-rerender",e),()=>{t.removeEventListener("sqm:request-rerender",e)}}),[]),n}export{t as a,n as u}
@@ -1,4 +1,4 @@
1
- import{r as i,h as o}from"./p-64c3217a.js";import{m as s,f as t,n as r}from"./p-fd2c5407.js";import{d as e,L as l,W as a,y as n,$ as d,u as v,i as u}from"./p-9b4a99c4.js";import{j as m}from"./p-e7e129ac.js";import{c}from"./p-c1086930.js";import"./p-02be1a88.js";import"./p-cef45012.js";import"./p-5d0c9424.js";import{u as h}from"./p-b07a88fd.js";import{P as f}from"./p-40b1de58.js";import{A as p}from"./p-121cdc60.js";const g=e.gql`
1
+ import{r as i,h as o}from"./p-64c3217a.js";import{m as s,f as t,n as r}from"./p-fd2c5407.js";import{d as e,L as l,O as a,w as n,j as d,u as v,i as u}from"./p-2037fbd3.js";import{j as m}from"./p-e7e129ac.js";import{c}from"./p-c1086930.js";import"./p-02be1a88.js";import"./p-cef45012.js";import"./p-5d0c9424.js";import{u as h}from"./p-1ba5157e.js";import{P as f}from"./p-40b1de58.js";import{A as p}from"./p-121cdc60.js";const g=e.gql`
2
2
  query RegistrationFormQuery($key: String!) {
3
3
  form(key: $key) {
4
4
  key
@@ -10,4 +10,4 @@ import{r as i,h as o}from"./p-64c3217a.js";import{m as s,f as t,n as r}from"./p-
10
10
  }
11
11
  }
12
12
  }
13
- `,b=class{constructor(o){i(this,o),this.ignored=!0,this.nextPage="/",this.redirectPath="/verifyEmail",this.emailLabel="Email",this.passwordLabel="Password",this.submitLabel="Register",this.loginLabel="Sign in",this.confirmPasswordLabel="Confirm Password",this.confirmPassword=!1,this.disablePasswordValidation=!1,this.hideInputs=!1,this.pageLabel="Register",this.loginPath="/login",this.requiredFieldErrorMessage="Cannot be empty",this.networkErrorMessage="Network request failed.",this.passwordMismatchErrorMessage="Passwords do not match.",this.invalidEmailErrorMessage="Must be a valid email address",this.formDisabledErrorMessage="The registration form is currently disabled.",this.meetsRequirementsText="Password has met all requirements",this.doesNotMeetRequirementsText="Password must meet the following requirements:",this.minErrorText="be a minimum of 8 characters",this.uppercaseErrorText="contain at least 1 uppercase character",this.lowercaseErrorText="contain at least 1 lowercase character",this.hasErrorText="contain at least 1 number or symbol",r(this)}disconnectedCallback(){}render(){const{states:i,callbacks:r,refs:e}=u()?c({states:{error:"",loading:!1,confirmPassword:this.confirmPassword,hideInputs:this.hideInputs||!1,customPasswordField:!1,loginPath:"/login"},callbacks:{submit:async()=>{console.log("submit")},inputFunction:()=>{}},refs:{formRef:{}}},this.demoData||{},{arrayMerge:(i,o)=>o}):function(i){var o,r,e,u,c,f,b,y,w;const E=s(null),k=l(),{registrationFormState:P,setRegistrationFormState:j}=h({}),[M,{loading:q,errors:x,formError:F}]=a(),R=n(g,{key:i.formKey}),T=q||R.loading;t((()=>{var o,s,t;const r=null===(o=null==R?void 0:R.data)||void 0===o?void 0:o.form.initialData.initialData,e=!1===(null===(s=null==R?void 0:R.data)||void 0===s?void 0:s.form.initialData.isEnabled),l=(null===(t=null==R?void 0:R.data)||void 0===t?void 0:t.form.initialData.isEnabledErrorMessage)||i.formDisabledErrorMessage;j({loading:T,disabled:e,disabledMessage:l,initialData:r})}),[null===(o=null==R?void 0:R.data)||void 0===o?void 0:o.form.initialData]),t((()=>{if(!E.current)return;const i=E.current;return i.addEventListener("sl-input",D),()=>{i.removeEventListener("sl-input",D)}}),[E.current]);const D=v((i=>{var o,s;if("tel"!==(null===(s=null===(o=i.target)||void 0===o?void 0:o.type)||void 0===s?void 0:s.toLowerCase()))return;const t=new p("US");i.target.value=t.input(i.target.value)}),[]);let S="";return S=!1===(null===(r=null==R?void 0:R.data)||void 0===r?void 0:r.form.initialData.isEnabled)?(null===(e=null==R?void 0:R.data)||void 0===e?void 0:e.form.initialData.isEnabledErrorMessage)||i.formDisabledErrorMessage:(null===(u=null==x?void 0:x.response)||void 0===u?void 0:u.error)||(null==x?void 0:x.message)&&!(null===(c=null==x?void 0:x.response)||void 0===c?void 0:c.errors.length)?i.networkErrorMessage:F||(null===(w=null===(y=null===(b=null===(f=null==R?void 0:R.errors)||void 0===f?void 0:f.response)||void 0===b?void 0:b.errors)||void 0===y?void 0:y[0])||void 0===w?void 0:w.message)||(null==P?void 0:P.error),{states:{loading:q||R.loading,error:S,registrationFormState:P,confirmPassword:i.confirmPassword,hideInputs:i.hideInputs,loginPath:i.loginPath,enablePasswordValidation:!i.disablePasswordValidation},callbacks:{submit:async o=>{var s,t,r,e,l,a,n,v,u,c,h,f,p,g,b,y,w,E;let q=o.target.getFormControls();console.log("Test 123");let x={},F={};if(null==q||q.forEach((o=>{if(!o.name)return;const s=o.name,t=o.value;if(m.set(x,s,t),o.required&&!t&&m.set(F,s,i.requiredFieldErrorMessage),"function"==typeof o.validationError){const i=(0,o.validationError)({control:o,key:s,value:t});i&&m.set(F,s,i)}})),(i.confirmPassword||x.confirmPassword)&&x.password!==x.confirmPassword&&(F={...F,confirmPassword:i.passwordMismatchErrorMessage}),Object.keys(F).length)return void j({...P,loading:!1,error:"",validationErrors:F});j({...P,loading:!0,error:"",validationErrors:{}});const{email:R,password:T}=x;console.log("form data is ",x),delete x.email,delete x.password,delete x.confirmPassword;const D={key:i.formKey,formData:{locale:k,email:R,password:T,redirectPath:i.redirectPath,...x}};try{const o=await M(D);if(o instanceof Error)throw o;j({...P,loading:!1,error:"",validationErrors:{}});const m=null===(s=o.submitForm)||void 0===s?void 0:s.results.find((i=>{var o;return"identity"===(null===(o=null==i?void 0:i.formHandler)||void 0===o?void 0:o.namespace)}));m&&m.result.results.length&&m.result.results[0].success&&m.result.results[0].data.token?d.push(i.nextPage):1===(null===(t=o.submitForm)||void 0===t?void 0:t.results.length)&&1===(null===(a=null===(l=null===(e=null===(r=o.submitForm)||void 0===r?void 0:r.results[0])||void 0===e?void 0:e.result)||void 0===l?void 0:l.results)||void 0===a?void 0:a.length)&&!1===(null===(h=null===(c=null===(u=null===(v=null===(n=o.submitForm)||void 0===n?void 0:n.results[0])||void 0===v?void 0:v.result)||void 0===u?void 0:u.results)||void 0===c?void 0:c[0])||void 0===h?void 0:h.success)&&(null===(w=null===(y=null===(b=null===(g=null===(p=null===(f=o.submitForm)||void 0===f?void 0:f.results[0])||void 0===p?void 0:p.result)||void 0===g?void 0:g.results)||void 0===b?void 0:b[0])||void 0===y?void 0:y.message)||void 0===w?void 0:w.startsWith("Blocked email"))&&j({...P,loading:!1,error:"",validationErrors:{email:i.invalidEmailErrorMessage}})}catch(o){(null===(E=null==o?void 0:o.message)||void 0===E?void 0:E.includes("is not a valid email address"))?j({...P,loading:!1,error:"",validationErrors:{email:i.invalidEmailErrorMessage}}):j({...P,loading:!1,error:i.networkErrorMessage,validationErrors:{}})}},inputFunction:D},refs:{formRef:E}}}(this);const b={formData:o("slot",{name:"formData"}),secondaryButton:o("slot",{name:"secondaryButton"},o("sl-button",{type:"text",disabled:i.loading,onClick:()=>d.push(i.loginPath)},this.loginLabel)),terms:o("slot",{name:"terms"}),emailOptIn:o("slot",{name:"emailOptIn"}),emailLabel:this.emailLabel,passwordLabel:this.passwordLabel,submitLabel:this.submitLabel,pageLabel:this.pageLabel,confirmPasswordLabel:this.confirmPasswordLabel,networkErrorMessage:this.networkErrorMessage,passwordMismatchErrorMessage:this.passwordMismatchErrorMessage,invalidEmailErrorMessage:this.invalidEmailErrorMessage,formDisabledErrorMessage:this.formDisabledErrorMessage,requiredFieldErrorMessage:this.requiredFieldErrorMessage,meetsRequirementsText:this.meetsRequirementsText,doesNotMeetRequirementsText:this.doesNotMeetRequirementsText,minErrorText:this.minErrorText,uppercaseErrorText:this.uppercaseErrorText,lowercaseErrorText:this.lowercaseErrorText,hasErrorText:this.hasErrorText};return o(f,{states:i,callbacks:r,content:b,refs:e})}};export{b as sqm_portal_registration_form}
13
+ `,b=class{constructor(o){i(this,o),this.ignored=!0,this.nextPage="/",this.redirectPath="/verifyEmail",this.emailLabel="Email",this.passwordLabel="Password",this.submitLabel="Register",this.loginLabel="Sign in",this.confirmPasswordLabel="Confirm Password",this.confirmPassword=!1,this.disablePasswordValidation=!1,this.hideInputs=!1,this.pageLabel="Register",this.loginPath="/login",this.requiredFieldErrorMessage="Cannot be empty",this.networkErrorMessage="Network request failed.",this.passwordMismatchErrorMessage="Passwords do not match.",this.invalidEmailErrorMessage="Must be a valid email address",this.formDisabledErrorMessage="The registration form is currently disabled.",this.meetsRequirementsText="Password has met all requirements",this.doesNotMeetRequirementsText="Password must meet the following requirements:",this.minErrorText="be a minimum of 8 characters",this.uppercaseErrorText="contain at least 1 uppercase character",this.lowercaseErrorText="contain at least 1 lowercase character",this.hasErrorText="contain at least 1 number or symbol",r(this)}disconnectedCallback(){}render(){const{states:i,callbacks:r,refs:e}=u()?c({states:{error:"",loading:!1,confirmPassword:this.confirmPassword,hideInputs:this.hideInputs||!1,customPasswordField:!1,loginPath:"/login"},callbacks:{submit:async()=>{console.log("submit")},inputFunction:()=>{}},refs:{formRef:{}}},this.demoData||{},{arrayMerge:(i,o)=>o}):function(i){var o,r,e,u,c,f,b,w,y;const E=s(null),k=l(),{registrationFormState:P,setRegistrationFormState:j}=h({}),[M,{loading:q,errors:x,formError:F}]=a(),R=n(g,{key:i.formKey}),T=q||R.loading;t((()=>{var o,s,t;const r=null===(o=null==R?void 0:R.data)||void 0===o?void 0:o.form.initialData.initialData,e=!1===(null===(s=null==R?void 0:R.data)||void 0===s?void 0:s.form.initialData.isEnabled),l=(null===(t=null==R?void 0:R.data)||void 0===t?void 0:t.form.initialData.isEnabledErrorMessage)||i.formDisabledErrorMessage;j({loading:T,disabled:e,disabledMessage:l,initialData:r})}),[null===(o=null==R?void 0:R.data)||void 0===o?void 0:o.form.initialData]),t((()=>{if(!E.current)return;const i=E.current;return i.addEventListener("sl-input",D),()=>{i.removeEventListener("sl-input",D)}}),[E.current]);const D=v((i=>{var o,s;if("tel"!==(null===(s=null===(o=i.target)||void 0===o?void 0:o.type)||void 0===s?void 0:s.toLowerCase()))return;const t=new p("US");i.target.value=t.input(i.target.value)}),[]);let S="";return S=!1===(null===(r=null==R?void 0:R.data)||void 0===r?void 0:r.form.initialData.isEnabled)?(null===(e=null==R?void 0:R.data)||void 0===e?void 0:e.form.initialData.isEnabledErrorMessage)||i.formDisabledErrorMessage:(null===(u=null==x?void 0:x.response)||void 0===u?void 0:u.error)||(null==x?void 0:x.message)&&!(null===(c=null==x?void 0:x.response)||void 0===c?void 0:c.errors.length)?i.networkErrorMessage:F||(null===(y=null===(w=null===(b=null===(f=null==R?void 0:R.errors)||void 0===f?void 0:f.response)||void 0===b?void 0:b.errors)||void 0===w?void 0:w[0])||void 0===y?void 0:y.message)||(null==P?void 0:P.error),{states:{loading:q||R.loading,error:S,registrationFormState:P,confirmPassword:i.confirmPassword,hideInputs:i.hideInputs,loginPath:i.loginPath,enablePasswordValidation:!i.disablePasswordValidation},callbacks:{submit:async o=>{var s,t,r,e,l,a,n,v,u,c,h,f,p,g,b,w,y,E;let q=o.target.getFormControls();console.log("Test 123");let x={},F={};if(null==q||q.forEach((o=>{if(!o.name)return;const s=o.name,t=o.value;if(m.set(x,s,t),o.required&&!t&&m.set(F,s,i.requiredFieldErrorMessage),"function"==typeof o.validationError){const i=(0,o.validationError)({control:o,key:s,value:t});i&&m.set(F,s,i)}})),(i.confirmPassword||x.confirmPassword)&&x.password!==x.confirmPassword&&(F={...F,confirmPassword:i.passwordMismatchErrorMessage}),Object.keys(F).length)return void j({...P,loading:!1,error:"",validationErrors:F});j({...P,loading:!0,error:"",validationErrors:{}});const{email:R,password:T}=x;console.log("form data is ",x),delete x.email,delete x.password,delete x.confirmPassword;const D={key:i.formKey,formData:{locale:k,email:R,password:T,redirectPath:i.redirectPath,...x}};try{const o=await M(D);if(o instanceof Error)throw o;j({...P,loading:!1,error:"",validationErrors:{}});const m=null===(s=o.submitForm)||void 0===s?void 0:s.results.find((i=>{var o;return"identity"===(null===(o=null==i?void 0:i.formHandler)||void 0===o?void 0:o.namespace)}));m&&m.result.results.length&&m.result.results[0].success&&m.result.results[0].data.token?d.push(i.nextPage):1===(null===(t=o.submitForm)||void 0===t?void 0:t.results.length)&&1===(null===(a=null===(l=null===(e=null===(r=o.submitForm)||void 0===r?void 0:r.results[0])||void 0===e?void 0:e.result)||void 0===l?void 0:l.results)||void 0===a?void 0:a.length)&&!1===(null===(h=null===(c=null===(u=null===(v=null===(n=o.submitForm)||void 0===n?void 0:n.results[0])||void 0===v?void 0:v.result)||void 0===u?void 0:u.results)||void 0===c?void 0:c[0])||void 0===h?void 0:h.success)&&(null===(y=null===(w=null===(b=null===(g=null===(p=null===(f=o.submitForm)||void 0===f?void 0:f.results[0])||void 0===p?void 0:p.result)||void 0===g?void 0:g.results)||void 0===b?void 0:b[0])||void 0===w?void 0:w.message)||void 0===y?void 0:y.startsWith("Blocked email"))&&j({...P,loading:!1,error:"",validationErrors:{email:i.invalidEmailErrorMessage}})}catch(o){(null===(E=null==o?void 0:o.message)||void 0===E?void 0:E.includes("is not a valid email address"))?j({...P,loading:!1,error:"",validationErrors:{email:i.invalidEmailErrorMessage}}):j({...P,loading:!1,error:i.networkErrorMessage,validationErrors:{}})}},inputFunction:D},refs:{formRef:E}}}(this);const b={formData:o("slot",{name:"formData"}),secondaryButton:o("slot",{name:"secondaryButton"},o("sl-button",{type:"text",disabled:i.loading,onClick:()=>d.push(i.loginPath)},this.loginLabel)),terms:o("slot",{name:"terms"}),emailOptIn:o("slot",{name:"emailOptIn"}),emailLabel:this.emailLabel,passwordLabel:this.passwordLabel,submitLabel:this.submitLabel,pageLabel:this.pageLabel,confirmPasswordLabel:this.confirmPasswordLabel,networkErrorMessage:this.networkErrorMessage,passwordMismatchErrorMessage:this.passwordMismatchErrorMessage,invalidEmailErrorMessage:this.invalidEmailErrorMessage,formDisabledErrorMessage:this.formDisabledErrorMessage,requiredFieldErrorMessage:this.requiredFieldErrorMessage,meetsRequirementsText:this.meetsRequirementsText,doesNotMeetRequirementsText:this.doesNotMeetRequirementsText,minErrorText:this.minErrorText,uppercaseErrorText:this.uppercaseErrorText,lowercaseErrorText:this.lowercaseErrorText,hasErrorText:this.hasErrorText};return o(f,{states:i,callbacks:r,content:b,refs:e})}};export{b as sqm_portal_registration_form}
@@ -1 +1 @@
1
- import{h as e}from"./p-64c3217a.js";import{i as l}from"./p-c4719154.js";import{c as a}from"./p-cef45012.js";import{T as t}from"./p-5d0c9424.js";function i(i){var s,r,o,n,p;const{states:d,callbacks:m}=i,{text:u,formState:c}=d,{errors:b,error:v}=c,x=a({Container:{display:"flex",flexDirection:"column",gap:"var(--sl-spacing-xxx-large)",padding:"var(--sl-spacing-xxx-large)"},FormStyle:{width:"100%",minWidth:"700px","& >*:not(:last-child)":{"margin-bottom":"32px"},"@media screen and (max-width: 1100px)":{minWidth:"100%"}},Error:{"&::part(erroralert-base)":{"margin-bottom":"32px"}},Success:{"&::part(successalert-base)":{"margin-bottom":"32px"}},NameInputStyle:{width:"50%","@media screen and (max-width: 860px)":{width:"100%","margin-right":"0"}},NameInputContainer:{display:"flex",gap:"32px",width:"100%","@media screen and (max-width: 860px)":{flexDirection:"column"}}}),f=x.toString(),g=(null===(s=d.user)||void 0===s?void 0:s.countryCode)?l.formatDisplayName(null===(r=d.user)||void 0===r?void 0:r.countryCode,{type:"region"}):"";return e("div",{class:x.classes.Container,part:"sqm-base"},e("style",{type:"text/css"},f),e(t,Object.assign({},{type:"h1"}),u.editProfileHeader),e(t,Object.assign({},{type:"h2"}),u.editProfileSubHeader),e("form",{class:x.classes.FormStyle,onSubmit:m.onSubmit},d.success&&e("sqm-form-message",{class:x.classes.Success,exportparts:"success-icon"},e("div",{part:"successalert-text"},u.submissionSuccessText)),v&&e("sqm-form-message",{class:x.classes.Error,type:"error",exportparts:"erroralert-icon"},e("div",{part:"erroralert-text"},v)),e("div",{class:x.classes.NameInputContainer},e("sl-input",Object.assign({class:x.classes.NameInputStyle,exportparts:"label: input-label, base: input-base",value:null===(o=d.user)||void 0===o?void 0:o.firstName,onInput:m.onChange,label:u.firstnametext,disabled:d.loading},(null==b?void 0:b.firstName)&&"valid"!==(null==b?void 0:b.firstName.status)?{class:"ErrorStyles",helpText:u.fieldEmptyText}:[],{id:"firstName",name:"firstName",error:(null==b?void 0:b.firstName)&&"valid"!==(null==b?void 0:b.firstName.status)?null==b?void 0:b.firstName.message:void 0})),e("sl-input",Object.assign({class:x.classes.NameInputStyle,exportparts:"label: input-label, base: input-base",value:null===(n=d.user)||void 0===n?void 0:n.lastName,onInput:m.onChange,label:u.lastnametext,disabled:d.loading,id:"lastName",name:"lastName"},(null==b?void 0:b.lastName)&&"valid"!==(null==b?void 0:b.lastName.status)?{class:"ErrorStyles",helpText:u.fieldEmptyText}:[],{error:(null==b?void 0:b.lastName)&&"valid"!==(null==b?void 0:b.lastName.status)?null==b?void 0:b.lastName.message:void 0}))),e("sl-input",{label:u.emailtext,value:null===(p=d.user)||void 0===p?void 0:p.email,exportparts:"label: input-label, base: input-base",disabled:!0}),d.showCountry&&e("sl-input",{label:u.countrytext,value:g,exportparts:"label: input-label, base: input-base",disabled:!0}),e("sl-button",{type:"primary",loading:d.loading,disabled:d.submitDisabled,onClick:e=>{m.onSubmit(e)},submit:!0},u.submitChangeButtonText)))}export{i as P}
1
+ import{h as e}from"./p-64c3217a.js";import{i as a}from"./p-eb64a65f.js";import{c as l}from"./p-cef45012.js";import{T as t}from"./p-5d0c9424.js";function i(i){var s,r,o,n,p;const{states:d,callbacks:m}=i,{text:u,formState:c}=d,{errors:b,error:v}=c,x=l({Container:{display:"flex",flexDirection:"column",gap:"var(--sl-spacing-xxx-large)",padding:"var(--sl-spacing-xxx-large)"},FormStyle:{width:"100%",minWidth:"700px","& >*:not(:last-child)":{"margin-bottom":"32px"},"@media screen and (max-width: 1100px)":{minWidth:"100%"}},Error:{"&::part(erroralert-base)":{"margin-bottom":"32px"}},Success:{"&::part(successalert-base)":{"margin-bottom":"32px"}},NameInputStyle:{width:"50%","@media screen and (max-width: 860px)":{width:"100%","margin-right":"0"}},NameInputContainer:{display:"flex",gap:"32px",width:"100%","@media screen and (max-width: 860px)":{flexDirection:"column"}}}),f=x.toString(),g=(null===(s=d.user)||void 0===s?void 0:s.countryCode)?a.formatDisplayName(null===(r=d.user)||void 0===r?void 0:r.countryCode,{type:"region"}):"";return e("div",{class:x.classes.Container,part:"sqm-base"},e("style",{type:"text/css"},f),e(t,Object.assign({},{type:"h1"}),u.editProfileHeader),e(t,Object.assign({},{type:"h2"}),u.editProfileSubHeader),e("form",{class:x.classes.FormStyle,onSubmit:m.onSubmit},d.success&&e("sqm-form-message",{class:x.classes.Success,exportparts:"success-icon"},e("div",{part:"successalert-text"},u.submissionSuccessText)),v&&e("sqm-form-message",{class:x.classes.Error,type:"error",exportparts:"erroralert-icon"},e("div",{part:"erroralert-text"},v)),e("div",{class:x.classes.NameInputContainer},e("sl-input",Object.assign({class:x.classes.NameInputStyle,exportparts:"label: input-label, base: input-base",value:null===(o=d.user)||void 0===o?void 0:o.firstName,onInput:m.onChange,label:u.firstnametext,disabled:d.loading},(null==b?void 0:b.firstName)&&"valid"!==(null==b?void 0:b.firstName.status)?{class:"ErrorStyles",helpText:u.fieldEmptyText}:[],{id:"firstName",name:"firstName",error:(null==b?void 0:b.firstName)&&"valid"!==(null==b?void 0:b.firstName.status)?null==b?void 0:b.firstName.message:void 0})),e("sl-input",Object.assign({class:x.classes.NameInputStyle,exportparts:"label: input-label, base: input-base",value:null===(n=d.user)||void 0===n?void 0:n.lastName,onInput:m.onChange,label:u.lastnametext,disabled:d.loading,id:"lastName",name:"lastName"},(null==b?void 0:b.lastName)&&"valid"!==(null==b?void 0:b.lastName.status)?{class:"ErrorStyles",helpText:u.fieldEmptyText}:[],{error:(null==b?void 0:b.lastName)&&"valid"!==(null==b?void 0:b.lastName.status)?null==b?void 0:b.lastName.message:void 0}))),e("sl-input",{label:u.emailtext,value:null===(p=d.user)||void 0===p?void 0:p.email,exportparts:"label: input-label, base: input-base",disabled:!0}),d.showCountry&&e("sl-input",{label:u.countrytext,value:g,exportparts:"label: input-label, base: input-base",disabled:!0}),e("sl-button",{type:"primary",loading:d.loading,disabled:d.submitDisabled,onClick:e=>{m.onSubmit(e)},submit:!0},u.submitChangeButtonText)))}export{i as P}
@@ -1 +1 @@
1
- System.register(["./p-ff17b3a4.system.js","./p-2a414b2e.system.js","./p-481dedf2.system.js"],(function(t){"use strict";var n,e,s,i,o;return{setters:[function(t){n=t.r},function(t){e=t.n},function(t){s=t.b;i=t.$;o=t.i}],execute:function(){function r(t){var n=t.nextPage;s(undefined);i.push({pathname:n,search:""})}var u=t("sqm_portal_logout",function(){function t(t){n(this,t);this.ignored=true;this.nextPage="/";e(this)}t.prototype.disconnectedCallback=function(){};t.prototype.render=function(){o()?c():r(this)};return t}());function c(t){}}}}));
1
+ System.register(["./p-ff17b3a4.system.js","./p-2a414b2e.system.js","./p-46af0bf6.system.js"],(function(t){"use strict";var n,e,s,i,o;return{setters:[function(t){n=t.r},function(t){e=t.n},function(t){s=t.a;i=t.j;o=t.i}],execute:function(){function r(t){var n=t.nextPage;s(undefined);i.push({pathname:n,search:""})}var u=t("sqm_portal_logout",function(){function t(t){n(this,t);this.ignored=true;this.nextPage="/";e(this)}t.prototype.disconnectedCallback=function(){};t.prototype.render=function(){o()?c():r(this)};return t}());function c(t){}}}}));
@@ -1 +1 @@
1
- System.register(["./p-2a414b2e.system.js","./p-481dedf2.system.js"],(function(e){"use strict";var t,n,r;return{setters:[function(e){t=e.f},function(e){n=e._;r=e.g}],execute:function(){e({a:s,u:i});var u="sqm:request-rerender";function s(e){var r=n();t((function(){r.dispatchEvent(new CustomEvent(u,{detail:true,bubbles:true,composed:true}))}),e)}function i(){var e=n();var s=r(),i=s[0],o=s[1];t((function(){var t=function(e){e.stopPropagation();o()};e.addEventListener(u,t);return function(){e.removeEventListener(u,t)}}),[]);return i}}}}));
1
+ System.register(["./p-2a414b2e.system.js","./p-46af0bf6.system.js"],(function(e){"use strict";var t,n,r;return{setters:[function(e){t=e.f},function(e){n=e._;r=e.y}],execute:function(){e({a:s,u:i});var u="sqm:request-rerender";function s(e){var r=n();t((function(){r.dispatchEvent(new CustomEvent(u,{detail:true,bubbles:true,composed:true}))}),e)}function i(){var e=n();var s=r(),i=s[0],o=s[1];t((function(){var t=function(e){e.stopPropagation();o()};e.addEventListener(u,t);return function(){e.removeEventListener(u,t)}}),[]);return i}}}}));