@justifi/webcomponents 4.8.2 → 4.9.0

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 (329) hide show
  1. package/dist/cjs/{Business-42d0c522.js → Business-64dffab7.js} +6 -7
  2. package/dist/cjs/{BusinessFormEventTypes-863f48e9.js → BusinessFormEventTypes-62990815.js} +1 -1
  3. package/dist/cjs/{Payout-44b49b2d.js → Payment-89a8bc21.js} +0 -43
  4. package/dist/cjs/Payout-a2dd7b01.js +45 -0
  5. package/dist/cjs/{SubAccount-2a803b22.js → SubAccount-f8144025.js} +1 -1
  6. package/dist/cjs/additional-questions-details_5.cjs.entry.js +24 -10
  7. package/dist/{webcomponents/p-4ee44c76.entry.js → cjs/business-details-core.cjs.entry.js} +55 -1
  8. package/dist/cjs/form-control-datepart_3.cjs.entry.js +1 -1
  9. package/dist/cjs/form-control-monetary.cjs.entry.js +1 -1
  10. package/dist/cjs/form-control-select_2.cjs.entry.js +1 -1
  11. package/dist/cjs/gross-payment-chart-core.cjs.entry.js +11036 -0
  12. package/dist/cjs/{index-55950669.js → index-07ddbad2.js} +0 -3
  13. package/dist/cjs/justifi-additional-questions_5.cjs.entry.js +3 -3
  14. package/dist/cjs/justifi-bank-account-form.cjs.entry.js +1 -1
  15. package/dist/cjs/{select-input_2.cjs.entry.js → justifi-billing-form_4.cjs.entry.js} +1818 -1
  16. package/dist/cjs/justifi-business-details.cjs.entry.js +43 -57
  17. package/dist/cjs/justifi-business-form-stepped.cjs.entry.js +5 -4
  18. package/dist/cjs/justifi-business-form.cjs.entry.js +5 -4
  19. package/dist/cjs/justifi-business-list.cjs.entry.js +5 -4
  20. package/dist/cjs/justifi-business-owners.cjs.entry.js +1 -1
  21. package/dist/cjs/justifi-card-form.cjs.entry.js +1 -1
  22. package/dist/cjs/justifi-checkout-core.cjs.entry.js +95 -0
  23. package/dist/cjs/justifi-checkout.cjs.entry.js +99 -0
  24. package/dist/cjs/justifi-details.cjs.entry.js +2 -2
  25. package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +39 -11008
  26. package/dist/cjs/justifi-new-payment-method_3.cjs.entry.js +168 -0
  27. package/dist/cjs/justifi-payment-balance-transactions.cjs.entry.js +5 -4
  28. package/dist/cjs/justifi-payment-details.cjs.entry.js +6 -5
  29. package/dist/cjs/justifi-payment-form.cjs.entry.js +5 -4
  30. package/dist/cjs/{justifi-billing-form_2.cjs.entry.js → justifi-payment-method-selector.cjs.entry.js} +4 -79
  31. package/dist/cjs/justifi-payments-list.cjs.entry.js +6 -5
  32. package/dist/cjs/justifi-payout-details.cjs.entry.js +5 -4
  33. package/dist/cjs/justifi-payouts-list.cjs.entry.js +5 -4
  34. package/dist/cjs/justifi-proceeds-list.cjs.entry.js +4 -3
  35. package/dist/cjs/justifi-refund-form.cjs.entry.js +3 -2
  36. package/dist/cjs/justifi-subaccount-details.cjs.entry.js +6 -5
  37. package/dist/cjs/justifi-subaccounts-list.cjs.entry.js +5 -4
  38. package/dist/cjs/justifi-table_2.cjs.entry.js +1 -1
  39. package/dist/cjs/loader.cjs.js +2 -2
  40. package/dist/cjs/payment-details-core.cjs.entry.js +10 -4
  41. package/dist/cjs/{payment.service-605896dc.js → payment.service-0b0086dc.js} +2 -1
  42. package/dist/cjs/payments-list-core.cjs.entry.js +4 -3
  43. package/dist/cjs/payout-details-core.cjs.entry.js +4 -4
  44. package/dist/cjs/{payout.service-b39f2739.js → payout.service-5cc3b4e9.js} +2 -1
  45. package/dist/cjs/payouts-list-core.cjs.entry.js +4 -3
  46. package/dist/cjs/subaccount-account-details_4.cjs.entry.js +7 -7
  47. package/dist/cjs/subaccount-bank-details.cjs.entry.js +3 -3
  48. package/dist/cjs/subaccount-terms-details.cjs.entry.js +3 -3
  49. package/dist/cjs/{utils-d126d17c.js → utils-5c3e442d.js} +5 -5
  50. package/dist/cjs/{utils-29a8a91d.js → utils-84208d99.js} +11 -2
  51. package/dist/cjs/webcomponents.cjs.js +2 -2
  52. package/dist/collection/api/Business.js +6 -7
  53. package/dist/collection/api/Checkout.js +1 -0
  54. package/dist/collection/api/index.js +1 -0
  55. package/dist/collection/api/services/business.service.js +8 -0
  56. package/dist/collection/api/services/checkout.service.js +12 -0
  57. package/dist/collection/api/services/reports.service.js +9 -0
  58. package/dist/collection/collection-manifest.json +7 -0
  59. package/dist/collection/components/billing-form/billing-form.js +1 -2
  60. package/dist/collection/components/business-details/additional-questions-details/additional-questions-details.js +5 -2
  61. package/dist/collection/components/business-details/additional-questions-details/test/additional-questions.spec.js +16 -0
  62. package/dist/collection/components/business-details/business-details-core.js +86 -0
  63. package/dist/collection/components/business-details/business-details.js +20 -65
  64. package/dist/collection/components/business-details/generic-info-details/generic-info-details.js +4 -2
  65. package/dist/collection/components/business-details/generic-info-details/test/generic-info-details.spec.js +16 -0
  66. package/dist/collection/components/business-details/get-business.js +17 -0
  67. package/dist/collection/components/business-details/legal-address-details/legal-address-details.js +5 -2
  68. package/dist/collection/components/business-details/legal-address-details/test/legal-address-details.spec.js +16 -0
  69. package/dist/collection/components/business-details/owner-details/owner-details.js +10 -12
  70. package/dist/collection/components/business-details/owner-details/test/owner-details.spec.js +16 -0
  71. package/dist/collection/components/business-details/representative-details/representative-details.js +5 -3
  72. package/dist/collection/components/business-details/representative-details/test/representative-details.spec.js +16 -0
  73. package/dist/collection/components/business-details/test/busines-details-core.spec.js +53 -0
  74. package/dist/collection/components/business-details/test/business-details.spec.js +40 -0
  75. package/dist/collection/components/business-details/test/get-business.spec.js +60 -0
  76. package/dist/collection/components/business-form/business-representative/business-representative.js +1 -1
  77. package/dist/collection/components/checkout/checkout-actions.js +33 -0
  78. package/dist/collection/components/checkout/checkout-core.css +2604 -0
  79. package/dist/collection/components/checkout/checkout-core.js +248 -0
  80. package/dist/collection/components/checkout/checkout.js +112 -0
  81. package/dist/collection/components/checkout/new-payment-method.js +188 -0
  82. package/dist/collection/components/checkout/payment-method-option-utils.js +19 -0
  83. package/dist/collection/components/checkout/payment-method-options.css +7073 -0
  84. package/dist/collection/components/checkout/payment-method-options.js +248 -0
  85. package/dist/collection/components/checkout/saved-payment-method.js +123 -0
  86. package/dist/collection/components/checkout/test/checkout.js +22 -0
  87. package/dist/collection/components/checkout/test/checkout.spec.js +166 -0
  88. package/dist/collection/components/checkout/test/mockCheckout.js +19 -0
  89. package/dist/collection/components/details/utils.js +4 -1
  90. package/dist/collection/components/gross-payment-chart/get-gross-payment-chart-data.js +14 -0
  91. package/dist/collection/components/gross-payment-chart/gross-payment-chart-core.js +119 -0
  92. package/dist/collection/components/gross-payment-chart/gross-payment-chart.js +25 -73
  93. package/dist/collection/components/gross-payment-chart/test/get-gross-payment-chart-data.spec.js +69 -0
  94. package/dist/collection/components/gross-payment-chart/test/gross-payment-chart-core.spec.js +64 -0
  95. package/dist/collection/components/gross-payment-chart/test/gross-payment-chart.spec.js +23 -8
  96. package/dist/collection/components/payment-details/payment-details-core.js +8 -2
  97. package/dist/collection/components/payment-details/payment-details.js +0 -1
  98. package/dist/collection/components/payment-form/payment-form.js +1 -1
  99. package/dist/collection/components/payment-method-form/payment-method-form.js +1 -1
  100. package/dist/collection/components/payout-details/payout-details-core.js +2 -2
  101. package/dist/collection/components/subaccount-details/subaccount-account-details/subaccount-account-details.js +2 -2
  102. package/dist/collection/components/subaccount-details/subaccount-bank-details/subaccount-bank-details.js +2 -2
  103. package/dist/collection/components/subaccount-details/subaccount-merchant-details/subaccount-merchant-details.js +2 -2
  104. package/dist/collection/components/subaccount-details/subaccount-owners-details/subaccount-owners-details.js +2 -2
  105. package/dist/collection/components/subaccount-details/subaccount-representative-details/subaccount-representative-details.js +2 -2
  106. package/dist/collection/components/subaccount-details/subaccount-terms-details/subaccount-terms-details.js +2 -2
  107. package/dist/collection/utils/utils.js +9 -3
  108. package/dist/docs.json +1152 -187
  109. package/dist/esm/{Business-e9340f6b.js → Business-9921d35f.js} +6 -7
  110. package/dist/esm/{BusinessFormEventTypes-989960ba.js → BusinessFormEventTypes-182e20be.js} +1 -1
  111. package/dist/esm/{Payout-dc5f009c.js → Payment-55886c86.js} +1 -43
  112. package/dist/esm/Payout-dfe15b00.js +43 -0
  113. package/dist/esm/{SubAccount-46b4c2b1.js → SubAccount-76f6d565.js} +1 -1
  114. package/dist/esm/additional-questions-details_5.entry.js +24 -10
  115. package/dist/esm/business-details-core.entry.js +51 -0
  116. package/dist/esm/form-control-datepart_3.entry.js +1 -1
  117. package/dist/esm/form-control-monetary.entry.js +1 -1
  118. package/dist/esm/form-control-select_2.entry.js +1 -1
  119. package/dist/esm/gross-payment-chart-core.entry.js +11032 -0
  120. package/dist/esm/{index-62b8aa8a.js → index-fb5ca346.js} +0 -3
  121. package/dist/esm/justifi-additional-questions_5.entry.js +3 -3
  122. package/dist/esm/justifi-bank-account-form.entry.js +1 -1
  123. package/dist/esm/{select-input_2.entry.js → justifi-billing-form_4.entry.js} +1817 -2
  124. package/dist/esm/justifi-business-details.entry.js +42 -56
  125. package/dist/esm/justifi-business-form-stepped.entry.js +5 -4
  126. package/dist/esm/justifi-business-form.entry.js +5 -4
  127. package/dist/esm/justifi-business-list.entry.js +5 -4
  128. package/dist/esm/justifi-business-owners.entry.js +1 -1
  129. package/dist/esm/justifi-card-form.entry.js +1 -1
  130. package/dist/esm/justifi-checkout-core.entry.js +91 -0
  131. package/dist/esm/justifi-checkout.entry.js +95 -0
  132. package/dist/esm/justifi-details.entry.js +2 -2
  133. package/dist/esm/justifi-gross-payment-chart.entry.js +39 -11008
  134. package/dist/esm/justifi-new-payment-method_3.entry.js +162 -0
  135. package/dist/esm/justifi-payment-balance-transactions.entry.js +4 -3
  136. package/dist/esm/justifi-payment-details.entry.js +5 -4
  137. package/dist/esm/justifi-payment-form.entry.js +4 -3
  138. package/dist/esm/{justifi-billing-form_2.entry.js → justifi-payment-method-selector.entry.js} +4 -78
  139. package/dist/esm/justifi-payments-list.entry.js +5 -4
  140. package/dist/esm/justifi-payout-details.entry.js +5 -4
  141. package/dist/esm/justifi-payouts-list.entry.js +5 -4
  142. package/dist/esm/justifi-proceeds-list.entry.js +4 -3
  143. package/dist/esm/justifi-refund-form.entry.js +3 -2
  144. package/dist/esm/justifi-subaccount-details.entry.js +6 -5
  145. package/dist/esm/justifi-subaccounts-list.entry.js +5 -4
  146. package/dist/esm/justifi-table_2.entry.js +1 -1
  147. package/dist/esm/loader.js +3 -3
  148. package/dist/esm/payment-details-core.entry.js +10 -4
  149. package/dist/esm/{payment.service-bea02ccf.js → payment.service-f274ef98.js} +2 -1
  150. package/dist/esm/payments-list-core.entry.js +4 -3
  151. package/dist/esm/payout-details-core.entry.js +4 -4
  152. package/dist/esm/{payout.service-92e56814.js → payout.service-af293f61.js} +2 -1
  153. package/dist/esm/payouts-list-core.entry.js +4 -3
  154. package/dist/esm/subaccount-account-details_4.entry.js +7 -7
  155. package/dist/esm/subaccount-bank-details.entry.js +3 -3
  156. package/dist/esm/subaccount-terms-details.entry.js +3 -3
  157. package/dist/esm/{utils-76a93600.js → utils-5193fcd7.js} +10 -3
  158. package/dist/esm/{utils-576874df.js → utils-a3e96d9f.js} +5 -5
  159. package/dist/esm/webcomponents.js +3 -3
  160. package/dist/module/Business.js +6 -7
  161. package/dist/module/Payment.js +138 -0
  162. package/dist/module/Payout.js +1 -138
  163. package/dist/module/SubAccount.js +1 -1
  164. package/dist/module/additional-questions-details2.js +5 -2
  165. package/dist/module/billing-form.js +1 -2
  166. package/dist/module/business-details-core.d.ts +11 -0
  167. package/dist/module/business-details-core.js +6 -0
  168. package/dist/module/business-details-core2.js +101 -0
  169. package/dist/module/business-representative.js +1 -1
  170. package/dist/module/checkout-core.js +163 -0
  171. package/dist/module/generic-info-details2.js +4 -2
  172. package/dist/module/gross-payment-chart-core.d.ts +11 -0
  173. package/dist/module/gross-payment-chart-core.js +6 -0
  174. package/dist/module/gross-payment-chart-core2.js +11055 -0
  175. package/dist/module/justifi-business-details.js +51 -60
  176. package/dist/module/justifi-business-form-stepped.js +1 -0
  177. package/dist/module/justifi-business-form.js +1 -0
  178. package/dist/module/justifi-business-list.js +2 -1
  179. package/dist/module/justifi-checkout-core.d.ts +11 -0
  180. package/dist/module/justifi-checkout-core.js +6 -0
  181. package/dist/module/justifi-checkout.d.ts +11 -0
  182. package/dist/module/justifi-checkout.js +172 -0
  183. package/dist/module/justifi-gross-payment-chart.js +49 -11016
  184. package/dist/module/justifi-new-payment-method.d.ts +11 -0
  185. package/dist/module/justifi-new-payment-method.js +6 -0
  186. package/dist/module/justifi-payment-balance-transactions.js +3 -2
  187. package/dist/module/justifi-payment-details.js +2 -1
  188. package/dist/module/justifi-payment-form.js +2 -1
  189. package/dist/module/justifi-payment-method-options.d.ts +11 -0
  190. package/dist/module/justifi-payment-method-options.js +6 -0
  191. package/dist/module/justifi-payments-list.js +2 -1
  192. package/dist/module/justifi-payout-details.js +2 -1
  193. package/dist/module/justifi-payouts-list.js +2 -1
  194. package/dist/module/justifi-proceeds-list.js +2 -1
  195. package/dist/module/justifi-refund-form.js +1 -0
  196. package/dist/module/justifi-saved-payment-method.d.ts +11 -0
  197. package/dist/module/justifi-saved-payment-method.js +6 -0
  198. package/dist/module/justifi-subaccount-details.js +2 -1
  199. package/dist/module/justifi-subaccounts-list.js +2 -1
  200. package/dist/module/legal-address-details2.js +5 -2
  201. package/dist/module/new-payment-method.js +105 -0
  202. package/dist/module/owner-details2.js +10 -4
  203. package/dist/module/payment-details-core2.js +9 -3
  204. package/dist/module/payment-method-form.js +3 -2
  205. package/dist/module/payment-method-options.js +128 -0
  206. package/dist/module/payment-method-selector.js +2 -1
  207. package/dist/module/payment.service.js +1 -0
  208. package/dist/module/payments-list-core2.js +2 -1
  209. package/dist/module/payout-details-core2.js +3 -3
  210. package/dist/module/payout.service.js +1 -0
  211. package/dist/module/payouts-list-core2.js +3 -2
  212. package/dist/module/representative-details2.js +5 -3
  213. package/dist/module/saved-payment-method.js +66 -0
  214. package/dist/module/subaccount-account-details2.js +2 -2
  215. package/dist/module/subaccount-bank-details.js +2 -2
  216. package/dist/module/subaccount-merchant-details2.js +3 -3
  217. package/dist/module/subaccount-owners-details2.js +2 -2
  218. package/dist/module/subaccount-representative-details2.js +2 -2
  219. package/dist/module/subaccount-terms-details.js +2 -2
  220. package/dist/module/utils.js +4 -4
  221. package/dist/module/utils2.js +10 -3
  222. package/dist/types/api/Api.d.ts +1 -1
  223. package/dist/types/api/Checkout.d.ts +14 -0
  224. package/dist/types/api/index.d.ts +1 -0
  225. package/dist/types/api/services/business.service.d.ts +8 -0
  226. package/dist/types/api/services/checkout.service.d.ts +9 -0
  227. package/dist/types/api/services/reports.service.d.ts +5 -0
  228. package/dist/types/components/billing-form/billing-form.d.ts +0 -1
  229. package/dist/types/components/business-details/business-details-core.d.ts +16 -0
  230. package/dist/types/components/business-details/business-details.d.ts +3 -13
  231. package/dist/types/components/business-details/get-business.d.ts +8 -0
  232. package/dist/types/components/business-details/owner-details/owner-details.d.ts +0 -8
  233. package/dist/types/components/checkout/checkout-actions.d.ts +17 -0
  234. package/dist/types/components/checkout/checkout-core.d.ts +28 -0
  235. package/dist/types/components/checkout/checkout.d.ts +12 -0
  236. package/dist/types/components/checkout/new-payment-method.d.ts +17 -0
  237. package/dist/types/components/checkout/payment-method-option-utils.d.ts +16 -0
  238. package/dist/types/components/checkout/payment-method-options.d.ts +18 -0
  239. package/dist/types/components/checkout/saved-payment-method.d.ts +11 -0
  240. package/dist/types/components/checkout/test/checkout.d.ts +1 -0
  241. package/dist/types/components/checkout/test/mockCheckout.d.ts +19 -0
  242. package/dist/types/components/details/utils.d.ts +1 -1
  243. package/dist/types/components/gross-payment-chart/get-gross-payment-chart-data.d.ts +11 -0
  244. package/dist/types/components/gross-payment-chart/gross-payment-chart-core.d.ts +18 -0
  245. package/dist/types/components/gross-payment-chart/gross-payment-chart.d.ts +4 -14
  246. package/dist/types/components/payment-details/payment-details.d.ts +0 -1
  247. package/dist/types/components/payment-method-form/payment-method-responses.d.ts +3 -9
  248. package/dist/types/components.d.ts +217 -32
  249. package/dist/types/utils/utils.d.ts +1 -0
  250. package/dist/webcomponents/p-018b71f5.entry.js +1 -0
  251. package/dist/webcomponents/p-0923e39c.js +1 -0
  252. package/dist/webcomponents/{p-7a1a06c0.entry.js → p-09b94d22.entry.js} +1 -1
  253. package/dist/webcomponents/p-1b04d091.entry.js +1 -0
  254. package/dist/webcomponents/{p-0a0cf2e6.entry.js → p-1bac1674.entry.js} +1 -1
  255. package/dist/webcomponents/p-1cbdca15.entry.js +1 -0
  256. package/dist/webcomponents/p-3134ab82.entry.js +1 -0
  257. package/dist/webcomponents/{p-22c1acd6.js → p-34f9fe6b.js} +1 -1
  258. package/dist/webcomponents/p-3bae0ed3.entry.js +1 -0
  259. package/dist/webcomponents/p-41031759.entry.js +1 -0
  260. package/dist/webcomponents/p-41490d96.entry.js +1 -0
  261. package/dist/webcomponents/p-44b88365.entry.js +1 -0
  262. package/dist/webcomponents/{p-081cf5f6.entry.js → p-4ed3a9f5.entry.js} +1 -1
  263. package/dist/webcomponents/{p-6478f3ca.js → p-4edd9721.js} +1 -1
  264. package/dist/webcomponents/p-51b0bf2a.entry.js +1 -0
  265. package/dist/webcomponents/p-531844f6.entry.js +1 -0
  266. package/dist/webcomponents/{p-4fa27a28.entry.js → p-591e29bf.entry.js} +1 -1
  267. package/dist/webcomponents/p-5d5d7550.entry.js +1 -0
  268. package/dist/webcomponents/{p-810b72b5.js → p-5ea274b8.js} +1 -1
  269. package/dist/webcomponents/{p-4ba2c711.entry.js → p-5f785ede.entry.js} +1 -1
  270. package/dist/webcomponents/p-63296409.js +1 -0
  271. package/dist/webcomponents/{p-4f14df36.js → p-6d05174c.js} +1 -1
  272. package/dist/webcomponents/p-72d1ad98.entry.js +1 -0
  273. package/dist/webcomponents/{p-40349ffc.entry.js → p-796cf44f.entry.js} +1 -1
  274. package/dist/webcomponents/p-79f99d62.entry.js +1 -0
  275. package/dist/webcomponents/p-7b2cddc7.js +1 -0
  276. package/dist/webcomponents/{p-7c0f91fa.entry.js → p-7cd06ada.entry.js} +1 -1
  277. package/dist/webcomponents/p-8f895ec3.entry.js +1 -0
  278. package/dist/webcomponents/p-92a55427.entry.js +1 -0
  279. package/dist/webcomponents/p-97c42345.entry.js +1 -0
  280. package/dist/webcomponents/p-99a8b7d0.entry.js +1 -0
  281. package/dist/webcomponents/p-9a63eec9.entry.js +1 -0
  282. package/dist/webcomponents/p-9c310f5c.entry.js +1 -0
  283. package/dist/webcomponents/p-9e3771b7.entry.js +19 -0
  284. package/dist/webcomponents/{p-4e56ddad.entry.js → p-a81229a5.entry.js} +1 -1
  285. package/dist/webcomponents/{p-234bc840.entry.js → p-adc96df1.entry.js} +1 -1
  286. package/dist/webcomponents/p-baafa7f5.js +1 -0
  287. package/dist/webcomponents/p-babd292f.entry.js +1 -0
  288. package/dist/webcomponents/{p-5c0310ee.js → p-bb037696.js} +1 -1
  289. package/dist/webcomponents/p-bb7f6095.entry.js +1 -0
  290. package/dist/webcomponents/p-c032b216.entry.js +1 -0
  291. package/dist/webcomponents/{p-08833966.entry.js → p-c2c3d5d1.entry.js} +1 -1
  292. package/dist/webcomponents/p-c8d51336.entry.js +1 -0
  293. package/dist/webcomponents/{p-4c01df65.entry.js → p-dc05b5c5.entry.js} +1 -1
  294. package/dist/webcomponents/p-e3fab0e2.js +1 -0
  295. package/dist/webcomponents/p-e536a4c1.entry.js +1 -0
  296. package/dist/webcomponents/p-ec358d69.entry.js +1 -0
  297. package/dist/webcomponents/p-f55ac955.entry.js +1 -0
  298. package/dist/webcomponents/p-f64a85cf.entry.js +1 -0
  299. package/dist/webcomponents/webcomponents.esm.js +1 -1
  300. package/package.json +3 -2
  301. package/dist/cjs/justifi-payment-method-form.cjs.entry.js +0 -1747
  302. package/dist/esm/justifi-payment-method-form.entry.js +0 -1743
  303. package/dist/webcomponents/p-0bc8b02e.entry.js +0 -1
  304. package/dist/webcomponents/p-112acd3c.entry.js +0 -1
  305. package/dist/webcomponents/p-1555e6b1.js +0 -1
  306. package/dist/webcomponents/p-16f41fd0.entry.js +0 -1
  307. package/dist/webcomponents/p-17715325.js +0 -1
  308. package/dist/webcomponents/p-3a4d4869.entry.js +0 -1
  309. package/dist/webcomponents/p-3cb0b96d.js +0 -1
  310. package/dist/webcomponents/p-5422a24b.entry.js +0 -1
  311. package/dist/webcomponents/p-578e0a05.entry.js +0 -1
  312. package/dist/webcomponents/p-640d90dc.entry.js +0 -1
  313. package/dist/webcomponents/p-663bfe87.js +0 -1
  314. package/dist/webcomponents/p-696396c7.entry.js +0 -1
  315. package/dist/webcomponents/p-6ab67031.entry.js +0 -1
  316. package/dist/webcomponents/p-8516d602.entry.js +0 -1
  317. package/dist/webcomponents/p-894a7475.entry.js +0 -19
  318. package/dist/webcomponents/p-94ebfafb.entry.js +0 -1
  319. package/dist/webcomponents/p-9cb3ff78.entry.js +0 -1
  320. package/dist/webcomponents/p-9e81808f.entry.js +0 -1
  321. package/dist/webcomponents/p-a432110c.entry.js +0 -1
  322. package/dist/webcomponents/p-a9dc1e2e.entry.js +0 -1
  323. package/dist/webcomponents/p-b1881723.entry.js +0 -1
  324. package/dist/webcomponents/p-b5aba473.entry.js +0 -1
  325. package/dist/webcomponents/p-bd099662.entry.js +0 -1
  326. package/dist/webcomponents/p-bfd917b8.entry.js +0 -1
  327. package/dist/webcomponents/p-c90fa055.entry.js +0 -1
  328. package/dist/webcomponents/p-ebb91944.entry.js +0 -1
  329. package/dist/webcomponents/p-ec4f27e7.entry.js +0 -1
@@ -2,7 +2,1822 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const index = require('./index-55950669.js');
5
+ const index = require('./index-07ddbad2.js');
6
+ const index_esm = require('./index.esm-d25bd7bf.js');
7
+ const stateOptions = require('./state-options-96d05a98.js');
8
+ const utils = require('./utils-84208d99.js');
9
+
10
+ const RegExZip = /^\d{5}/;
11
+ const BillingFormSchema = index_esm.create$3({
12
+ name: index_esm.create$6().required('Enter name'),
13
+ address_line1: index_esm.create$6().required('Enter street address'),
14
+ address_line2: index_esm.create$6(),
15
+ address_city: index_esm.create$6().required('Enter city'),
16
+ address_state: index_esm.create$6().required('Choose state'),
17
+ address_postal_code: index_esm.create$6().required('Enter ZIP').matches(RegExZip, 'Enter a valid ZIP').min(5, 'Enter a valid ZIP'),
18
+ });
19
+
20
+ const billingFormCss = ":root,[data-bs-theme=light]{--bs-blue:#0d6efd;--bs-indigo:#6610f2;--bs-purple:#6f42c1;--bs-pink:#d63384;--bs-red:#dc3545;--bs-orange:#fd7e14;--bs-yellow:#ffc107;--bs-green:#198754;--bs-teal:#20c997;--bs-cyan:#0dcaf0;--bs-black:#000;--bs-white:#fff;--bs-gray:#6c757d;--bs-gray-dark:#343a40;--bs-gray-100:#f8f9fa;--bs-gray-200:#e9ecef;--bs-gray-300:#dee2e6;--bs-gray-400:#ced4da;--bs-gray-500:#adb5bd;--bs-gray-600:#6c757d;--bs-gray-700:#495057;--bs-gray-800:#343a40;--bs-gray-900:#212529;--bs-primary:#0d6efd;--bs-secondary:#6c757d;--bs-success:#198754;--bs-info:#0dcaf0;--bs-warning:#ffc107;--bs-danger:#dc3545;--bs-light:#f8f9fa;--bs-dark:#212529;--bs-primary-rgb:13, 110, 253;--bs-secondary-rgb:108, 117, 125;--bs-success-rgb:25, 135, 84;--bs-info-rgb:13, 202, 240;--bs-warning-rgb:255, 193, 7;--bs-danger-rgb:220, 53, 69;--bs-light-rgb:248, 249, 250;--bs-dark-rgb:33, 37, 41;--bs-primary-text-emphasis:#052c65;--bs-secondary-text-emphasis:#2b2f32;--bs-success-text-emphasis:#0a3622;--bs-info-text-emphasis:#055160;--bs-warning-text-emphasis:#664d03;--bs-danger-text-emphasis:#58151c;--bs-light-text-emphasis:#495057;--bs-dark-text-emphasis:#495057;--bs-primary-bg-subtle:#cfe2ff;--bs-secondary-bg-subtle:#e2e3e5;--bs-success-bg-subtle:#d1e7dd;--bs-info-bg-subtle:#cff4fc;--bs-warning-bg-subtle:#fff3cd;--bs-danger-bg-subtle:#f8d7da;--bs-light-bg-subtle:#fcfcfd;--bs-dark-bg-subtle:#ced4da;--bs-primary-border-subtle:#9ec5fe;--bs-secondary-border-subtle:#c4c8cb;--bs-success-border-subtle:#a3cfbb;--bs-info-border-subtle:#9eeaf9;--bs-warning-border-subtle:#ffe69c;--bs-danger-border-subtle:#f1aeb5;--bs-light-border-subtle:#e9ecef;--bs-dark-border-subtle:#adb5bd;--bs-white-rgb:255, 255, 255;--bs-black-rgb:0, 0, 0;--bs-font-sans-serif:system-ui, -apple-system, \"Segoe UI\", Roboto, \"Helvetica Neue\", \"Noto Sans\", \"Liberation Sans\", Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\", \"Noto Color Emoji\";--bs-font-monospace:SFMono-Regular, Menlo, Monaco, Consolas, \"Liberation Mono\", \"Courier New\", monospace;--bs-gradient:linear-gradient(180deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0));--bs-body-font-family:var(--bs-font-sans-serif);--bs-body-font-size:1rem;--bs-body-font-weight:400;--bs-body-line-height:1.5;--bs-body-color:#212529;--bs-body-color-rgb:33, 37, 41;--bs-body-bg:#fff;--bs-body-bg-rgb:255, 255, 255;--bs-emphasis-color:#000;--bs-emphasis-color-rgb:0, 0, 0;--bs-secondary-color:rgba(33, 37, 41, 0.75);--bs-secondary-color-rgb:33, 37, 41;--bs-secondary-bg:#e9ecef;--bs-secondary-bg-rgb:233, 236, 239;--bs-tertiary-color:rgba(33, 37, 41, 0.5);--bs-tertiary-color-rgb:33, 37, 41;--bs-tertiary-bg:#f8f9fa;--bs-tertiary-bg-rgb:248, 249, 250;--bs-heading-color:inherit;--bs-link-color:#0d6efd;--bs-link-color-rgb:13, 110, 253;--bs-link-decoration:underline;--bs-link-hover-color:#0a58ca;--bs-link-hover-color-rgb:10, 88, 202;--bs-code-color:#d63384;--bs-highlight-color:#212529;--bs-highlight-bg:#fff3cd;--bs-border-width:1px;--bs-border-style:solid;--bs-border-color:#dee2e6;--bs-border-color-translucent:rgba(0, 0, 0, 0.175);--bs-border-radius:0.375rem;--bs-border-radius-sm:0.25rem;--bs-border-radius-lg:0.5rem;--bs-border-radius-xl:1rem;--bs-border-radius-xxl:2rem;--bs-border-radius-2xl:var(--bs-border-radius-xxl);--bs-border-radius-pill:50rem;--bs-box-shadow:0 0.5rem 1rem rgba(0, 0, 0, 0.15);--bs-box-shadow-sm:0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);--bs-box-shadow-lg:0 1rem 3rem rgba(0, 0, 0, 0.175);--bs-box-shadow-inset:inset 0 1px 2px rgba(0, 0, 0, 0.075);--bs-focus-ring-width:0.25rem;--bs-focus-ring-opacity:0.25;--bs-focus-ring-color:rgba(13, 110, 253, 0.25);--bs-form-valid-color:#198754;--bs-form-valid-border-color:#198754;--bs-form-invalid-color:#dc3545;--bs-form-invalid-border-color:#dc3545}[data-bs-theme=dark]{color-scheme:dark;--bs-body-color:#dee2e6;--bs-body-color-rgb:222, 226, 230;--bs-body-bg:#212529;--bs-body-bg-rgb:33, 37, 41;--bs-emphasis-color:#fff;--bs-emphasis-color-rgb:255, 255, 255;--bs-secondary-color:rgba(222, 226, 230, 0.75);--bs-secondary-color-rgb:222, 226, 230;--bs-secondary-bg:#343a40;--bs-secondary-bg-rgb:52, 58, 64;--bs-tertiary-color:rgba(222, 226, 230, 0.5);--bs-tertiary-color-rgb:222, 226, 230;--bs-tertiary-bg:#2b3035;--bs-tertiary-bg-rgb:43, 48, 53;--bs-primary-text-emphasis:#6ea8fe;--bs-secondary-text-emphasis:#a7acb1;--bs-success-text-emphasis:#75b798;--bs-info-text-emphasis:#6edff6;--bs-warning-text-emphasis:#ffda6a;--bs-danger-text-emphasis:#ea868f;--bs-light-text-emphasis:#f8f9fa;--bs-dark-text-emphasis:#dee2e6;--bs-primary-bg-subtle:#031633;--bs-secondary-bg-subtle:#161719;--bs-success-bg-subtle:#051b11;--bs-info-bg-subtle:#032830;--bs-warning-bg-subtle:#332701;--bs-danger-bg-subtle:#2c0b0e;--bs-light-bg-subtle:#343a40;--bs-dark-bg-subtle:#1a1d20;--bs-primary-border-subtle:#084298;--bs-secondary-border-subtle:#41464b;--bs-success-border-subtle:#0f5132;--bs-info-border-subtle:#087990;--bs-warning-border-subtle:#997404;--bs-danger-border-subtle:#842029;--bs-light-border-subtle:#495057;--bs-dark-border-subtle:#343a40;--bs-heading-color:inherit;--bs-link-color:#6ea8fe;--bs-link-hover-color:#8bb9fe;--bs-link-color-rgb:110, 168, 254;--bs-link-hover-color-rgb:139, 185, 254;--bs-code-color:#e685b5;--bs-highlight-color:#dee2e6;--bs-highlight-bg:#664d03;--bs-border-color:#495057;--bs-border-color-translucent:rgba(255, 255, 255, 0.15);--bs-form-valid-color:#75b798;--bs-form-valid-border-color:#75b798;--bs-form-invalid-color:#ea868f;--bs-form-invalid-border-color:#ea868f}.spinner-grow,.spinner-border{display:inline-block;width:var(--bs-spinner-width);height:var(--bs-spinner-height);vertical-align:var(--bs-spinner-vertical-align);border-radius:50%;animation:var(--bs-spinner-animation-speed) linear infinite var(--bs-spinner-animation-name)}@keyframes spinner-border{to{transform:rotate(360deg) }}.spinner-border{--bs-spinner-width:2rem;--bs-spinner-height:2rem;--bs-spinner-vertical-align:-0.125em;--bs-spinner-border-width:0.25em;--bs-spinner-animation-speed:0.75s;--bs-spinner-animation-name:spinner-border;border:var(--bs-spinner-border-width) solid currentcolor;border-right-color:transparent}.spinner-border-sm{--bs-spinner-width:1rem;--bs-spinner-height:1rem;--bs-spinner-border-width:0.2em}@keyframes spinner-grow{0%{transform:scale(0)}50%{opacity:1;transform:none}}.spinner-grow{--bs-spinner-width:2rem;--bs-spinner-height:2rem;--bs-spinner-vertical-align:-0.125em;--bs-spinner-animation-speed:0.75s;--bs-spinner-animation-name:spinner-grow;background-color:currentcolor;opacity:0}.spinner-grow-sm{--bs-spinner-width:1rem;--bs-spinner-height:1rem}@media (prefers-reduced-motion: reduce){.spinner-border,.spinner-grow{--bs-spinner-animation-speed:1.5s}}.clearfix::after{display:block;clear:both;content:\"\"}.text-bg-primary{color:#fff !important;background-color:RGBA(var(--bs-primary-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-secondary{color:#fff !important;background-color:RGBA(var(--bs-secondary-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-success{color:#fff !important;background-color:RGBA(var(--bs-success-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-info{color:#000 !important;background-color:RGBA(var(--bs-info-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-warning{color:#000 !important;background-color:RGBA(var(--bs-warning-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-danger{color:#fff !important;background-color:RGBA(var(--bs-danger-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-light{color:#000 !important;background-color:RGBA(var(--bs-light-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-dark{color:#fff !important;background-color:RGBA(var(--bs-dark-rgb), var(--bs-bg-opacity, 1)) !important}.link-primary{color:RGBA(var(--bs-primary-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-primary-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-primary:hover,.link-primary:focus{color:RGBA(10, 88, 202, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(10, 88, 202, var(--bs-link-underline-opacity, 1)) !important}.link-secondary{color:RGBA(var(--bs-secondary-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-secondary-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-secondary:hover,.link-secondary:focus{color:RGBA(86, 94, 100, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(86, 94, 100, var(--bs-link-underline-opacity, 1)) !important}.link-success{color:RGBA(var(--bs-success-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-success-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-success:hover,.link-success:focus{color:RGBA(20, 108, 67, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(20, 108, 67, var(--bs-link-underline-opacity, 1)) !important}.link-info{color:RGBA(var(--bs-info-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-info-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-info:hover,.link-info:focus{color:RGBA(61, 213, 243, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(61, 213, 243, var(--bs-link-underline-opacity, 1)) !important}.link-warning{color:RGBA(var(--bs-warning-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-warning-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-warning:hover,.link-warning:focus{color:RGBA(255, 205, 57, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(255, 205, 57, var(--bs-link-underline-opacity, 1)) !important}.link-danger{color:RGBA(var(--bs-danger-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-danger-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-danger:hover,.link-danger:focus{color:RGBA(176, 42, 55, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(176, 42, 55, var(--bs-link-underline-opacity, 1)) !important}.link-light{color:RGBA(var(--bs-light-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-light-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-light:hover,.link-light:focus{color:RGBA(249, 250, 251, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(249, 250, 251, var(--bs-link-underline-opacity, 1)) !important}.link-dark{color:RGBA(var(--bs-dark-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-dark-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-dark:hover,.link-dark:focus{color:RGBA(26, 30, 33, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(26, 30, 33, var(--bs-link-underline-opacity, 1)) !important}.link-body-emphasis{color:RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-body-emphasis:hover,.link-body-emphasis:focus{color:RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-opacity, 0.75)) !important;text-decoration-color:RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-underline-opacity, 0.75)) !important}.focus-ring:focus{outline:0;box-shadow:var(--bs-focus-ring-x, 0) var(--bs-focus-ring-y, 0) var(--bs-focus-ring-blur, 0) var(--bs-focus-ring-width) var(--bs-focus-ring-color)}.icon-link{display:inline-flex;gap:0.375rem;align-items:center;text-decoration-color:rgba(var(--bs-link-color-rgb), var(--bs-link-opacity, 0.5));text-underline-offset:0.25em;backface-visibility:hidden}.icon-link>.bi{flex-shrink:0;width:1em;height:1em;fill:currentcolor;transition:0.2s ease-in-out transform}@media (prefers-reduced-motion: reduce){.icon-link>.bi{transition:none}}.icon-link-hover:hover>.bi,.icon-link-hover:focus-visible>.bi{transform:var(--bs-icon-link-transform, translate3d(0.25em, 0, 0))}.ratio{position:relative;width:100%}.ratio::before{display:block;padding-top:var(--bs-aspect-ratio);content:\"\"}.ratio>*{position:absolute;top:0;left:0;width:100%;height:100%}.ratio-1x1{--bs-aspect-ratio:100%}.ratio-4x3{--bs-aspect-ratio:75%}.ratio-16x9{--bs-aspect-ratio:56.25%}.ratio-21x9{--bs-aspect-ratio:42.8571428571%}.fixed-top{position:fixed;top:0;right:0;left:0;z-index:1030}.fixed-bottom{position:fixed;right:0;bottom:0;left:0;z-index:1030}.sticky-top{position:sticky;top:0;z-index:1020}.sticky-bottom{position:sticky;bottom:0;z-index:1020}@media (min-width: 576px){.sticky-sm-top{position:sticky;top:0;z-index:1020}.sticky-sm-bottom{position:sticky;bottom:0;z-index:1020}}@media (min-width: 768px){.sticky-md-top{position:sticky;top:0;z-index:1020}.sticky-md-bottom{position:sticky;bottom:0;z-index:1020}}@media (min-width: 992px){.sticky-lg-top{position:sticky;top:0;z-index:1020}.sticky-lg-bottom{position:sticky;bottom:0;z-index:1020}}@media (min-width: 1200px){.sticky-xl-top{position:sticky;top:0;z-index:1020}.sticky-xl-bottom{position:sticky;bottom:0;z-index:1020}}@media (min-width: 1400px){.sticky-xxl-top{position:sticky;top:0;z-index:1020}.sticky-xxl-bottom{position:sticky;bottom:0;z-index:1020}}.hstack{display:flex;flex-direction:row;align-items:center;align-self:stretch}.vstack{display:flex;flex:1 1 auto;flex-direction:column;align-self:stretch}.visually-hidden,.visually-hidden-focusable:not(:focus):not(:focus-within){width:1px !important;height:1px !important;padding:0 !important;margin:-1px !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;white-space:nowrap !important;border:0 !important}.visually-hidden:not(caption),.visually-hidden-focusable:not(:focus):not(:focus-within):not(caption){position:absolute !important}.stretched-link::after{position:absolute;top:0;right:0;bottom:0;left:0;z-index:1;content:\"\"}.text-truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.vr{display:inline-block;align-self:stretch;width:var(--bs-border-width);min-height:1em;background-color:currentcolor;opacity:0.25}*,*::before,*::after{box-sizing:border-box}@media (prefers-reduced-motion: no-preference){:root{scroll-behavior:smooth}}body{margin:0;font-family:var(--bs-body-font-family);font-size:var(--bs-body-font-size);font-weight:var(--bs-body-font-weight);line-height:var(--bs-body-line-height);color:var(--bs-body-color);text-align:var(--bs-body-text-align);background-color:var(--bs-body-bg);-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:rgba(0, 0, 0, 0)}hr{margin:1rem 0;color:inherit;border:0;border-top:var(--bs-border-width) solid;opacity:0.25}h6,h5,h4,h3,h2,h1{margin-top:0;margin-bottom:0.5rem;font-weight:500;line-height:1.2;color:var(--bs-heading-color)}h1{font-size:calc(1.375rem + 1.5vw)}@media (min-width: 1200px){h1{font-size:2.5rem}}h2{font-size:calc(1.325rem + 0.9vw)}@media (min-width: 1200px){h2{font-size:2rem}}h3{font-size:calc(1.3rem + 0.6vw)}@media (min-width: 1200px){h3{font-size:1.75rem}}h4{font-size:calc(1.275rem + 0.3vw)}@media (min-width: 1200px){h4{font-size:1.5rem}}h5{font-size:1.25rem}h6{font-size:1rem}p{margin-top:0;margin-bottom:1rem}abbr[title]{text-decoration:underline dotted;cursor:help;text-decoration-skip-ink:none}address{margin-bottom:1rem;font-style:normal;line-height:inherit}ol,ul{padding-left:2rem}ol,ul,dl{margin-top:0;margin-bottom:1rem}ol ol,ul ul,ol ul,ul ol{margin-bottom:0}dt{font-weight:700}dd{margin-bottom:0.5rem;margin-left:0}blockquote{margin:0 0 1rem}b,strong{font-weight:bolder}small{font-size:0.875em}mark{padding:0.1875em;color:var(--bs-highlight-color);background-color:var(--bs-highlight-bg)}sub,sup{position:relative;font-size:0.75em;line-height:0;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}a{color:rgba(var(--bs-link-color-rgb), var(--bs-link-opacity, 1));text-decoration:underline}a:hover{--bs-link-color-rgb:var(--bs-link-hover-color-rgb)}a:not([href]):not([class]),a:not([href]):not([class]):hover{color:inherit;text-decoration:none}pre,code,kbd,samp{font-family:var(--bs-font-monospace);font-size:1em}pre{display:block;margin-top:0;margin-bottom:1rem;overflow:auto;font-size:0.875em}pre code{font-size:inherit;color:inherit;word-break:normal}code{font-size:0.875em;color:var(--bs-code-color);word-wrap:break-word}a>code{color:inherit}kbd{padding:0.1875rem 0.375rem;font-size:0.875em;color:var(--bs-body-bg);background-color:var(--bs-body-color);border-radius:0.25rem}kbd kbd{padding:0;font-size:1em}figure{margin:0 0 1rem}img,svg{vertical-align:middle}table{caption-side:bottom;border-collapse:collapse}caption{padding-top:0.5rem;padding-bottom:0.5rem;color:var(--bs-secondary-color);text-align:left}th{text-align:inherit;text-align:-webkit-match-parent}thead,tbody,tfoot,tr,td,th{border-color:inherit;border-style:solid;border-width:0}label{display:inline-block}button{border-radius:0}button:focus:not(:focus-visible){outline:0}input,button,select,optgroup,textarea{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}button,select{text-transform:none}[role=button]{cursor:pointer}select{word-wrap:normal}select:disabled{opacity:1}[list]:not([type=date]):not([type=datetime-local]):not([type=month]):not([type=week]):not([type=time])::-webkit-calendar-picker-indicator{display:none !important}button,[type=button],[type=reset],[type=submit]{-webkit-appearance:button}button:not(:disabled),[type=button]:not(:disabled),[type=reset]:not(:disabled),[type=submit]:not(:disabled){cursor:pointer}::-moz-focus-inner{padding:0;border-style:none}textarea{resize:vertical}fieldset{min-width:0;padding:0;margin:0;border:0}legend{float:left;width:100%;padding:0;margin-bottom:0.5rem;font-size:calc(1.275rem + 0.3vw);line-height:inherit}@media (min-width: 1200px){legend{font-size:1.5rem}}legend+*{clear:left}::-webkit-datetime-edit-fields-wrapper,::-webkit-datetime-edit-text,::-webkit-datetime-edit-minute,::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-year-field{padding:0}::-webkit-inner-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-color-swatch-wrapper{padding:0}::file-selector-button{font:inherit;-webkit-appearance:button}output{display:inline-block}iframe{border:0}summary{display:list-item;cursor:pointer}progress{vertical-align:baseline}[hidden]{display:none !important}:root{--bs-breakpoint-xs:0;--bs-breakpoint-sm:576px;--bs-breakpoint-md:768px;--bs-breakpoint-lg:992px;--bs-breakpoint-xl:1200px;--bs-breakpoint-xxl:1400px}.row{--bs-gutter-x:1.5rem;--bs-gutter-y:0;display:flex;flex-wrap:wrap;margin-top:calc(-1 * var(--bs-gutter-y));margin-right:calc(-0.5 * var(--bs-gutter-x));margin-left:calc(-0.5 * var(--bs-gutter-x))}.row>*{flex-shrink:0;width:100%;max-width:100%;padding-right:calc(var(--bs-gutter-x) * 0.5);padding-left:calc(var(--bs-gutter-x) * 0.5);margin-top:var(--bs-gutter-y)}.col{flex:1 0 0%}.row-cols-auto>*{flex:0 0 auto;width:auto}.row-cols-1>*{flex:0 0 auto;width:100%}.row-cols-2>*{flex:0 0 auto;width:50%}.row-cols-3>*{flex:0 0 auto;width:33.33333333%}.row-cols-4>*{flex:0 0 auto;width:25%}.row-cols-5>*{flex:0 0 auto;width:20%}.row-cols-6>*{flex:0 0 auto;width:16.66666667%}.col-auto{flex:0 0 auto;width:auto}.col-1{flex:0 0 auto;width:8.33333333%}.col-2{flex:0 0 auto;width:16.66666667%}.col-3{flex:0 0 auto;width:25%}.col-4{flex:0 0 auto;width:33.33333333%}.col-5{flex:0 0 auto;width:41.66666667%}.col-6{flex:0 0 auto;width:50%}.col-7{flex:0 0 auto;width:58.33333333%}.col-8{flex:0 0 auto;width:66.66666667%}.col-9{flex:0 0 auto;width:75%}.col-10{flex:0 0 auto;width:83.33333333%}.col-11{flex:0 0 auto;width:91.66666667%}.col-12{flex:0 0 auto;width:100%}.offset-1{margin-left:8.33333333%}.offset-2{margin-left:16.66666667%}.offset-3{margin-left:25%}.offset-4{margin-left:33.33333333%}.offset-5{margin-left:41.66666667%}.offset-6{margin-left:50%}.offset-7{margin-left:58.33333333%}.offset-8{margin-left:66.66666667%}.offset-9{margin-left:75%}.offset-10{margin-left:83.33333333%}.offset-11{margin-left:91.66666667%}.g-0,.gx-0{--bs-gutter-x:0}.g-0,.gy-0{--bs-gutter-y:0}.g-1,.gx-1{--bs-gutter-x:0.25rem}.g-1,.gy-1{--bs-gutter-y:0.25rem}.g-2,.gx-2{--bs-gutter-x:0.5rem}.g-2,.gy-2{--bs-gutter-y:0.5rem}.g-3,.gx-3{--bs-gutter-x:1rem}.g-3,.gy-3{--bs-gutter-y:1rem}.g-4,.gx-4{--bs-gutter-x:1.5rem}.g-4,.gy-4{--bs-gutter-y:1.5rem}.g-5,.gx-5{--bs-gutter-x:3rem}.g-5,.gy-5{--bs-gutter-y:3rem}@media (min-width: 576px){.col-sm{flex:1 0 0%}.row-cols-sm-auto>*{flex:0 0 auto;width:auto}.row-cols-sm-1>*{flex:0 0 auto;width:100%}.row-cols-sm-2>*{flex:0 0 auto;width:50%}.row-cols-sm-3>*{flex:0 0 auto;width:33.33333333%}.row-cols-sm-4>*{flex:0 0 auto;width:25%}.row-cols-sm-5>*{flex:0 0 auto;width:20%}.row-cols-sm-6>*{flex:0 0 auto;width:16.66666667%}.col-sm-auto{flex:0 0 auto;width:auto}.col-sm-1{flex:0 0 auto;width:8.33333333%}.col-sm-2{flex:0 0 auto;width:16.66666667%}.col-sm-3{flex:0 0 auto;width:25%}.col-sm-4{flex:0 0 auto;width:33.33333333%}.col-sm-5{flex:0 0 auto;width:41.66666667%}.col-sm-6{flex:0 0 auto;width:50%}.col-sm-7{flex:0 0 auto;width:58.33333333%}.col-sm-8{flex:0 0 auto;width:66.66666667%}.col-sm-9{flex:0 0 auto;width:75%}.col-sm-10{flex:0 0 auto;width:83.33333333%}.col-sm-11{flex:0 0 auto;width:91.66666667%}.col-sm-12{flex:0 0 auto;width:100%}.offset-sm-0{margin-left:0}.offset-sm-1{margin-left:8.33333333%}.offset-sm-2{margin-left:16.66666667%}.offset-sm-3{margin-left:25%}.offset-sm-4{margin-left:33.33333333%}.offset-sm-5{margin-left:41.66666667%}.offset-sm-6{margin-left:50%}.offset-sm-7{margin-left:58.33333333%}.offset-sm-8{margin-left:66.66666667%}.offset-sm-9{margin-left:75%}.offset-sm-10{margin-left:83.33333333%}.offset-sm-11{margin-left:91.66666667%}.g-sm-0,.gx-sm-0{--bs-gutter-x:0}.g-sm-0,.gy-sm-0{--bs-gutter-y:0}.g-sm-1,.gx-sm-1{--bs-gutter-x:0.25rem}.g-sm-1,.gy-sm-1{--bs-gutter-y:0.25rem}.g-sm-2,.gx-sm-2{--bs-gutter-x:0.5rem}.g-sm-2,.gy-sm-2{--bs-gutter-y:0.5rem}.g-sm-3,.gx-sm-3{--bs-gutter-x:1rem}.g-sm-3,.gy-sm-3{--bs-gutter-y:1rem}.g-sm-4,.gx-sm-4{--bs-gutter-x:1.5rem}.g-sm-4,.gy-sm-4{--bs-gutter-y:1.5rem}.g-sm-5,.gx-sm-5{--bs-gutter-x:3rem}.g-sm-5,.gy-sm-5{--bs-gutter-y:3rem}}@media (min-width: 768px){.col-md{flex:1 0 0%}.row-cols-md-auto>*{flex:0 0 auto;width:auto}.row-cols-md-1>*{flex:0 0 auto;width:100%}.row-cols-md-2>*{flex:0 0 auto;width:50%}.row-cols-md-3>*{flex:0 0 auto;width:33.33333333%}.row-cols-md-4>*{flex:0 0 auto;width:25%}.row-cols-md-5>*{flex:0 0 auto;width:20%}.row-cols-md-6>*{flex:0 0 auto;width:16.66666667%}.col-md-auto{flex:0 0 auto;width:auto}.col-md-1{flex:0 0 auto;width:8.33333333%}.col-md-2{flex:0 0 auto;width:16.66666667%}.col-md-3{flex:0 0 auto;width:25%}.col-md-4{flex:0 0 auto;width:33.33333333%}.col-md-5{flex:0 0 auto;width:41.66666667%}.col-md-6{flex:0 0 auto;width:50%}.col-md-7{flex:0 0 auto;width:58.33333333%}.col-md-8{flex:0 0 auto;width:66.66666667%}.col-md-9{flex:0 0 auto;width:75%}.col-md-10{flex:0 0 auto;width:83.33333333%}.col-md-11{flex:0 0 auto;width:91.66666667%}.col-md-12{flex:0 0 auto;width:100%}.offset-md-0{margin-left:0}.offset-md-1{margin-left:8.33333333%}.offset-md-2{margin-left:16.66666667%}.offset-md-3{margin-left:25%}.offset-md-4{margin-left:33.33333333%}.offset-md-5{margin-left:41.66666667%}.offset-md-6{margin-left:50%}.offset-md-7{margin-left:58.33333333%}.offset-md-8{margin-left:66.66666667%}.offset-md-9{margin-left:75%}.offset-md-10{margin-left:83.33333333%}.offset-md-11{margin-left:91.66666667%}.g-md-0,.gx-md-0{--bs-gutter-x:0}.g-md-0,.gy-md-0{--bs-gutter-y:0}.g-md-1,.gx-md-1{--bs-gutter-x:0.25rem}.g-md-1,.gy-md-1{--bs-gutter-y:0.25rem}.g-md-2,.gx-md-2{--bs-gutter-x:0.5rem}.g-md-2,.gy-md-2{--bs-gutter-y:0.5rem}.g-md-3,.gx-md-3{--bs-gutter-x:1rem}.g-md-3,.gy-md-3{--bs-gutter-y:1rem}.g-md-4,.gx-md-4{--bs-gutter-x:1.5rem}.g-md-4,.gy-md-4{--bs-gutter-y:1.5rem}.g-md-5,.gx-md-5{--bs-gutter-x:3rem}.g-md-5,.gy-md-5{--bs-gutter-y:3rem}}@media (min-width: 992px){.col-lg{flex:1 0 0%}.row-cols-lg-auto>*{flex:0 0 auto;width:auto}.row-cols-lg-1>*{flex:0 0 auto;width:100%}.row-cols-lg-2>*{flex:0 0 auto;width:50%}.row-cols-lg-3>*{flex:0 0 auto;width:33.33333333%}.row-cols-lg-4>*{flex:0 0 auto;width:25%}.row-cols-lg-5>*{flex:0 0 auto;width:20%}.row-cols-lg-6>*{flex:0 0 auto;width:16.66666667%}.col-lg-auto{flex:0 0 auto;width:auto}.col-lg-1{flex:0 0 auto;width:8.33333333%}.col-lg-2{flex:0 0 auto;width:16.66666667%}.col-lg-3{flex:0 0 auto;width:25%}.col-lg-4{flex:0 0 auto;width:33.33333333%}.col-lg-5{flex:0 0 auto;width:41.66666667%}.col-lg-6{flex:0 0 auto;width:50%}.col-lg-7{flex:0 0 auto;width:58.33333333%}.col-lg-8{flex:0 0 auto;width:66.66666667%}.col-lg-9{flex:0 0 auto;width:75%}.col-lg-10{flex:0 0 auto;width:83.33333333%}.col-lg-11{flex:0 0 auto;width:91.66666667%}.col-lg-12{flex:0 0 auto;width:100%}.offset-lg-0{margin-left:0}.offset-lg-1{margin-left:8.33333333%}.offset-lg-2{margin-left:16.66666667%}.offset-lg-3{margin-left:25%}.offset-lg-4{margin-left:33.33333333%}.offset-lg-5{margin-left:41.66666667%}.offset-lg-6{margin-left:50%}.offset-lg-7{margin-left:58.33333333%}.offset-lg-8{margin-left:66.66666667%}.offset-lg-9{margin-left:75%}.offset-lg-10{margin-left:83.33333333%}.offset-lg-11{margin-left:91.66666667%}.g-lg-0,.gx-lg-0{--bs-gutter-x:0}.g-lg-0,.gy-lg-0{--bs-gutter-y:0}.g-lg-1,.gx-lg-1{--bs-gutter-x:0.25rem}.g-lg-1,.gy-lg-1{--bs-gutter-y:0.25rem}.g-lg-2,.gx-lg-2{--bs-gutter-x:0.5rem}.g-lg-2,.gy-lg-2{--bs-gutter-y:0.5rem}.g-lg-3,.gx-lg-3{--bs-gutter-x:1rem}.g-lg-3,.gy-lg-3{--bs-gutter-y:1rem}.g-lg-4,.gx-lg-4{--bs-gutter-x:1.5rem}.g-lg-4,.gy-lg-4{--bs-gutter-y:1.5rem}.g-lg-5,.gx-lg-5{--bs-gutter-x:3rem}.g-lg-5,.gy-lg-5{--bs-gutter-y:3rem}}@media (min-width: 1200px){.col-xl{flex:1 0 0%}.row-cols-xl-auto>*{flex:0 0 auto;width:auto}.row-cols-xl-1>*{flex:0 0 auto;width:100%}.row-cols-xl-2>*{flex:0 0 auto;width:50%}.row-cols-xl-3>*{flex:0 0 auto;width:33.33333333%}.row-cols-xl-4>*{flex:0 0 auto;width:25%}.row-cols-xl-5>*{flex:0 0 auto;width:20%}.row-cols-xl-6>*{flex:0 0 auto;width:16.66666667%}.col-xl-auto{flex:0 0 auto;width:auto}.col-xl-1{flex:0 0 auto;width:8.33333333%}.col-xl-2{flex:0 0 auto;width:16.66666667%}.col-xl-3{flex:0 0 auto;width:25%}.col-xl-4{flex:0 0 auto;width:33.33333333%}.col-xl-5{flex:0 0 auto;width:41.66666667%}.col-xl-6{flex:0 0 auto;width:50%}.col-xl-7{flex:0 0 auto;width:58.33333333%}.col-xl-8{flex:0 0 auto;width:66.66666667%}.col-xl-9{flex:0 0 auto;width:75%}.col-xl-10{flex:0 0 auto;width:83.33333333%}.col-xl-11{flex:0 0 auto;width:91.66666667%}.col-xl-12{flex:0 0 auto;width:100%}.offset-xl-0{margin-left:0}.offset-xl-1{margin-left:8.33333333%}.offset-xl-2{margin-left:16.66666667%}.offset-xl-3{margin-left:25%}.offset-xl-4{margin-left:33.33333333%}.offset-xl-5{margin-left:41.66666667%}.offset-xl-6{margin-left:50%}.offset-xl-7{margin-left:58.33333333%}.offset-xl-8{margin-left:66.66666667%}.offset-xl-9{margin-left:75%}.offset-xl-10{margin-left:83.33333333%}.offset-xl-11{margin-left:91.66666667%}.g-xl-0,.gx-xl-0{--bs-gutter-x:0}.g-xl-0,.gy-xl-0{--bs-gutter-y:0}.g-xl-1,.gx-xl-1{--bs-gutter-x:0.25rem}.g-xl-1,.gy-xl-1{--bs-gutter-y:0.25rem}.g-xl-2,.gx-xl-2{--bs-gutter-x:0.5rem}.g-xl-2,.gy-xl-2{--bs-gutter-y:0.5rem}.g-xl-3,.gx-xl-3{--bs-gutter-x:1rem}.g-xl-3,.gy-xl-3{--bs-gutter-y:1rem}.g-xl-4,.gx-xl-4{--bs-gutter-x:1.5rem}.g-xl-4,.gy-xl-4{--bs-gutter-y:1.5rem}.g-xl-5,.gx-xl-5{--bs-gutter-x:3rem}.g-xl-5,.gy-xl-5{--bs-gutter-y:3rem}}@media (min-width: 1400px){.col-xxl{flex:1 0 0%}.row-cols-xxl-auto>*{flex:0 0 auto;width:auto}.row-cols-xxl-1>*{flex:0 0 auto;width:100%}.row-cols-xxl-2>*{flex:0 0 auto;width:50%}.row-cols-xxl-3>*{flex:0 0 auto;width:33.33333333%}.row-cols-xxl-4>*{flex:0 0 auto;width:25%}.row-cols-xxl-5>*{flex:0 0 auto;width:20%}.row-cols-xxl-6>*{flex:0 0 auto;width:16.66666667%}.col-xxl-auto{flex:0 0 auto;width:auto}.col-xxl-1{flex:0 0 auto;width:8.33333333%}.col-xxl-2{flex:0 0 auto;width:16.66666667%}.col-xxl-3{flex:0 0 auto;width:25%}.col-xxl-4{flex:0 0 auto;width:33.33333333%}.col-xxl-5{flex:0 0 auto;width:41.66666667%}.col-xxl-6{flex:0 0 auto;width:50%}.col-xxl-7{flex:0 0 auto;width:58.33333333%}.col-xxl-8{flex:0 0 auto;width:66.66666667%}.col-xxl-9{flex:0 0 auto;width:75%}.col-xxl-10{flex:0 0 auto;width:83.33333333%}.col-xxl-11{flex:0 0 auto;width:91.66666667%}.col-xxl-12{flex:0 0 auto;width:100%}.offset-xxl-0{margin-left:0}.offset-xxl-1{margin-left:8.33333333%}.offset-xxl-2{margin-left:16.66666667%}.offset-xxl-3{margin-left:25%}.offset-xxl-4{margin-left:33.33333333%}.offset-xxl-5{margin-left:41.66666667%}.offset-xxl-6{margin-left:50%}.offset-xxl-7{margin-left:58.33333333%}.offset-xxl-8{margin-left:66.66666667%}.offset-xxl-9{margin-left:75%}.offset-xxl-10{margin-left:83.33333333%}.offset-xxl-11{margin-left:91.66666667%}.g-xxl-0,.gx-xxl-0{--bs-gutter-x:0}.g-xxl-0,.gy-xxl-0{--bs-gutter-y:0}.g-xxl-1,.gx-xxl-1{--bs-gutter-x:0.25rem}.g-xxl-1,.gy-xxl-1{--bs-gutter-y:0.25rem}.g-xxl-2,.gx-xxl-2{--bs-gutter-x:0.5rem}.g-xxl-2,.gy-xxl-2{--bs-gutter-y:0.5rem}.g-xxl-3,.gx-xxl-3{--bs-gutter-x:1rem}.g-xxl-3,.gy-xxl-3{--bs-gutter-y:1rem}.g-xxl-4,.gx-xxl-4{--bs-gutter-x:1.5rem}.g-xxl-4,.gy-xxl-4{--bs-gutter-y:1.5rem}.g-xxl-5,.gx-xxl-5{--bs-gutter-x:3rem}.g-xxl-5,.gy-xxl-5{--bs-gutter-y:3rem}}:host{font-family:system-ui, -apple-system, \"Segoe UI\", Roboto, \"Helvetica Neue\", \"Noto Sans\", \"Liberation Sans\", Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\", \"Noto Color Emoji\";font-size:1rem;font-weight:400;line-height:1.5;color:#212529;display:block}justifi-billing-form{margin-left:calc(var(--jfi-layout-padding) * -1);margin-right:calc(var(--jfi-layout-padding) * -1)}*::part(label){color:var(--jfi-form-label-color);font-family:var(--jfi-form-label-font-family);font-weight:var(--jfi-form-label-font-weight);font-size:var(--jfi-form-label-font-size);margin:var(--jfi-form-label-margin)}*::part(input){background-color:var(--jfi-form-control-background-color);border-color:var(--jfi-form-control-border-color);border-width:var(--jfi-form-control-border-width);border-bottom-width:var(--jfi-form-control-border-bottom-width);border-left-width:var(--jfi-form-control-border-left-width);border-right-width:var(--jfi-form-control-border-right-width);border-top-width:var(--jfi-form-control-border-top-width);border-radius:var(--jfi-form-control-border-radius);border-style:var(--jfi-form-control-border-style);box-shadow:var(--jfi-form-control-box-shadow);color:var(--jfi-form-control-color);font-size:var(--jfi-form-control-font-size);font-weight:var(--jfi-form-control-font-weight);line-height:var(--jfi-form-control-line-height);margin:var(--jfi-form-control-margin);padding:var(--jfi-form-control-padding)}*::part(input):focus{color:var(--jfi-form-control-color-focus);border-color:var(--jfi-form-control-border-color-focus);box-shadow:var(--jfi-form-control-box-shadow-focus)}*::part(input-invalid){border-color:var(--jfi-form-control-border-color-error);box-shadow:var(--jfi-form-control-box-shadow-error)}*::part(input-invalid):focus{border-color:var(--jfi-form-control-border-color-error);box-shadow:var(--jfi-form-control-box-shadow-error-focus)}";
21
+
22
+ const BillingForm = class {
23
+ constructor(hostRef) {
24
+ index.registerInstance(this, hostRef);
25
+ this.legend = undefined;
26
+ this.billingFields = {
27
+ name: '',
28
+ address_line1: '',
29
+ address_line2: '',
30
+ address_city: '',
31
+ address_state: '',
32
+ address_postal_code: '',
33
+ };
34
+ this.billingFieldsErrors = {};
35
+ }
36
+ setFormValue(event) {
37
+ const data = event.detail;
38
+ const billingFieldsClone = Object.assign({}, this.billingFields);
39
+ if (data.name) {
40
+ billingFieldsClone[data.name] = data.value;
41
+ this.billingFields = billingFieldsClone;
42
+ }
43
+ }
44
+ /**
45
+ * Method for filling the form with provided data
46
+ * @argument {BillingFormFields} fields - The fields to fill the form with
47
+ */
48
+ async fill(fields) {
49
+ this.billingFields = Object.assign({}, fields);
50
+ }
51
+ /**
52
+ * Run validation on the form
53
+ */
54
+ async validate() {
55
+ const newErrors = {};
56
+ let isValid = true;
57
+ try {
58
+ await BillingFormSchema.validate(this.billingFields, { abortEarly: false });
59
+ }
60
+ catch (err) {
61
+ isValid = false;
62
+ err.inner.map((item) => {
63
+ newErrors[item.path] = item.message;
64
+ });
65
+ }
66
+ this.billingFieldsErrors = newErrors;
67
+ return { isValid: isValid };
68
+ }
69
+ /**
70
+ * Returns the values of the form as an object
71
+ * @returns {Promise<BillingFormFields>} The values of the form
72
+ */
73
+ async getValues() {
74
+ return this.billingFields;
75
+ }
76
+ render() {
77
+ return (index.h(index.Host, { exportparts: "label,input,input-invalid" }, index.h("fieldset", null, this.legend && index.h("legend", null, this.legend), index.h("div", { class: "row gy-3" }, index.h("div", { class: "col-12" }, index.h("text-input", { name: "name", label: "Full Name", defaultValue: this.billingFields.name, error: this.billingFieldsErrors.name })), index.h("div", { class: "col-12" }, index.h("text-input", { name: "address_line1", label: "Street Address", defaultValue: this.billingFields.address_line1, error: this.billingFieldsErrors.address_line1 })), index.h("div", { class: "col-12" }, index.h("text-input", { name: "address_line2", label: "Apartment, Suite, etc. (optional)", defaultValue: this.billingFields.address_line2, error: this.billingFieldsErrors.address_line2 })), index.h("div", { class: "col-12" }, index.h("text-input", { name: "address_city", label: "City", defaultValue: this.billingFields.address_city, error: this.billingFieldsErrors.address_city })), index.h("div", { class: "col-12" }, index.h("select-input", { name: "address_state", label: "State", options: stateOptions.StateOptions, defaultValue: this.billingFields.address_state, error: this.billingFieldsErrors.address_state })), index.h("div", { class: "col-12" }, index.h("text-input", { name: "address_postal_code", label: "ZIP", defaultValue: this.billingFields.address_postal_code, error: this.billingFieldsErrors.address_postal_code }))))));
78
+ }
79
+ };
80
+ BillingForm.style = billingFormCss;
81
+
82
+ function createCommonjsModule(fn, basedir, module) {
83
+ return module = {
84
+ path: basedir,
85
+ exports: {},
86
+ require: function (path, base) {
87
+ return commonjsRequire();
88
+ }
89
+ }, fn(module, module.exports), module.exports;
90
+ }
91
+
92
+ function commonjsRequire () {
93
+ throw new Error('Dynamic requires are not currently supported by @rollup/plugin-commonjs');
94
+ }
95
+
96
+ var iframeResizer = createCommonjsModule(function (module) {
97
+ (function (undefined$1) {
98
+ if (typeof window === 'undefined') return // don't run for server side render
99
+
100
+ var count = 0,
101
+ logEnabled = false,
102
+ hiddenCheckEnabled = false,
103
+ msgHeader = 'message',
104
+ msgHeaderLen = msgHeader.length,
105
+ msgId = '[iFrameSizer]', // Must match iframe msg ID
106
+ msgIdLen = msgId.length,
107
+ pagePosition = null,
108
+ requestAnimationFrame = window.requestAnimationFrame,
109
+ resetRequiredMethods = Object.freeze({
110
+ max: 1,
111
+ scroll: 1,
112
+ bodyScroll: 1,
113
+ documentElementScroll: 1
114
+ }),
115
+ settings = {},
116
+ timer = null,
117
+ defaults = Object.freeze({
118
+ autoResize: true,
119
+ bodyBackground: null,
120
+ bodyMargin: null,
121
+ bodyMarginV1: 8,
122
+ bodyPadding: null,
123
+ checkOrigin: true,
124
+ inPageLinks: false,
125
+ enablePublicMethods: true,
126
+ heightCalculationMethod: 'bodyOffset',
127
+ id: 'iFrameResizer',
128
+ interval: 32,
129
+ log: false,
130
+ maxHeight: Infinity,
131
+ maxWidth: Infinity,
132
+ minHeight: 0,
133
+ minWidth: 0,
134
+ mouseEvents: true,
135
+ resizeFrom: 'parent',
136
+ scrolling: false,
137
+ sizeHeight: true,
138
+ sizeWidth: false,
139
+ warningTimeout: 5000,
140
+ tolerance: 0,
141
+ widthCalculationMethod: 'scroll',
142
+ onClose: function () {
143
+ return true
144
+ },
145
+ onClosed: function () {},
146
+ onInit: function () {},
147
+ onMessage: function () {
148
+ warn('onMessage function not defined');
149
+ },
150
+ onMouseEnter: function () {},
151
+ onMouseLeave: function () {},
152
+ onResized: function () {},
153
+ onScroll: function () {
154
+ return true
155
+ }
156
+ });
157
+
158
+ function getMutationObserver() {
159
+ return (
160
+ window.MutationObserver ||
161
+ window.WebKitMutationObserver ||
162
+ window.MozMutationObserver
163
+ )
164
+ }
165
+
166
+ function addEventListener(el, evt, func) {
167
+ el.addEventListener(evt, func, false);
168
+ }
169
+
170
+ function removeEventListener(el, evt, func) {
171
+ el.removeEventListener(evt, func, false);
172
+ }
173
+
174
+ function setupRequestAnimationFrame() {
175
+ var vendors = ['moz', 'webkit', 'o', 'ms'];
176
+ var x;
177
+
178
+ // Remove vendor prefixing if prefixed and break early if not
179
+ for (x = 0; x < vendors.length && !requestAnimationFrame; x += 1) {
180
+ requestAnimationFrame = window[vendors[x] + 'RequestAnimationFrame'];
181
+ }
182
+
183
+ if (requestAnimationFrame) {
184
+ // Firefox extension content-scripts have a globalThis object that is not the same as window.
185
+ // Binding `requestAnimationFrame` to window allows the function to work and prevents errors
186
+ // being thrown when run in that context, and should be a no-op in every other context.
187
+ requestAnimationFrame = requestAnimationFrame.bind(window);
188
+ } else {
189
+ log('setup', 'RequestAnimationFrame not supported');
190
+ }
191
+ }
192
+
193
+ function getMyID(iframeId) {
194
+ var retStr = 'Host page: ' + iframeId;
195
+
196
+ if (window.top !== window.self) {
197
+ retStr =
198
+ window.parentIFrame && window.parentIFrame.getId
199
+ ? window.parentIFrame.getId() + ': ' + iframeId
200
+ : 'Nested host page: ' + iframeId;
201
+ }
202
+
203
+ return retStr
204
+ }
205
+
206
+ function formatLogHeader(iframeId) {
207
+ return msgId + '[' + getMyID(iframeId) + ']'
208
+ }
209
+
210
+ function isLogEnabled(iframeId) {
211
+ return settings[iframeId] ? settings[iframeId].log : logEnabled
212
+ }
213
+
214
+ function log(iframeId, msg) {
215
+ output('log', iframeId, msg, isLogEnabled(iframeId));
216
+ }
217
+
218
+ function info(iframeId, msg) {
219
+ output('info', iframeId, msg, isLogEnabled(iframeId));
220
+ }
221
+
222
+ function warn(iframeId, msg) {
223
+ output('warn', iframeId, msg, true);
224
+ }
225
+
226
+ function output(type, iframeId, msg, enabled) {
227
+ if (true === enabled && 'object' === typeof window.console) {
228
+ // eslint-disable-next-line no-console
229
+ console[type](formatLogHeader(iframeId), msg);
230
+ }
231
+ }
232
+
233
+ function iFrameListener(event) {
234
+ function resizeIFrame() {
235
+ function resize() {
236
+ setSize(messageData);
237
+ setPagePosition(iframeId);
238
+ on('onResized', messageData);
239
+ }
240
+
241
+ ensureInRange('Height');
242
+ ensureInRange('Width');
243
+
244
+ syncResize(resize, messageData, 'init');
245
+ }
246
+
247
+ function processMsg() {
248
+ var data = msg.slice(msgIdLen).split(':');
249
+ var height = data[1] ? parseInt(data[1], 10) : 0;
250
+ var iframe = settings[data[0]] && settings[data[0]].iframe;
251
+ var compStyle = getComputedStyle(iframe);
252
+
253
+ return {
254
+ iframe: iframe,
255
+ id: data[0],
256
+ height: height + getPaddingEnds(compStyle) + getBorderEnds(compStyle),
257
+ width: data[2],
258
+ type: data[3]
259
+ }
260
+ }
261
+
262
+ function getPaddingEnds(compStyle) {
263
+ if (compStyle.boxSizing !== 'border-box') {
264
+ return 0
265
+ }
266
+ var top = compStyle.paddingTop ? parseInt(compStyle.paddingTop, 10) : 0;
267
+ var bot = compStyle.paddingBottom
268
+ ? parseInt(compStyle.paddingBottom, 10)
269
+ : 0;
270
+ return top + bot
271
+ }
272
+
273
+ function getBorderEnds(compStyle) {
274
+ if (compStyle.boxSizing !== 'border-box') {
275
+ return 0
276
+ }
277
+ var top = compStyle.borderTopWidth
278
+ ? parseInt(compStyle.borderTopWidth, 10)
279
+ : 0;
280
+ var bot = compStyle.borderBottomWidth
281
+ ? parseInt(compStyle.borderBottomWidth, 10)
282
+ : 0;
283
+ return top + bot
284
+ }
285
+
286
+ function ensureInRange(Dimension) {
287
+ var max = Number(settings[iframeId]['max' + Dimension]),
288
+ min = Number(settings[iframeId]['min' + Dimension]),
289
+ dimension = Dimension.toLowerCase(),
290
+ size = Number(messageData[dimension]);
291
+
292
+ log(iframeId, 'Checking ' + dimension + ' is in range ' + min + '-' + max);
293
+
294
+ if (size < min) {
295
+ size = min;
296
+ log(iframeId, 'Set ' + dimension + ' to min value');
297
+ }
298
+
299
+ if (size > max) {
300
+ size = max;
301
+ log(iframeId, 'Set ' + dimension + ' to max value');
302
+ }
303
+
304
+ messageData[dimension] = '' + size;
305
+ }
306
+
307
+ function isMessageFromIFrame() {
308
+ function checkAllowedOrigin() {
309
+ function checkList() {
310
+ var i = 0,
311
+ retCode = false;
312
+
313
+ log(
314
+ iframeId,
315
+ 'Checking connection is from allowed list of origins: ' +
316
+ checkOrigin
317
+ );
318
+
319
+ for (; i < checkOrigin.length; i++) {
320
+ if (checkOrigin[i] === origin) {
321
+ retCode = true;
322
+ break
323
+ }
324
+ }
325
+ return retCode
326
+ }
327
+
328
+ function checkSingle() {
329
+ var remoteHost = settings[iframeId] && settings[iframeId].remoteHost;
330
+ log(iframeId, 'Checking connection is from: ' + remoteHost);
331
+ return origin === remoteHost
332
+ }
333
+
334
+ return checkOrigin.constructor === Array ? checkList() : checkSingle()
335
+ }
336
+
337
+ var origin = event.origin,
338
+ checkOrigin = settings[iframeId] && settings[iframeId].checkOrigin;
339
+
340
+ if (checkOrigin && '' + origin !== 'null' && !checkAllowedOrigin()) {
341
+ throw new Error(
342
+ 'Unexpected message received from: ' +
343
+ origin +
344
+ ' for ' +
345
+ messageData.iframe.id +
346
+ '. Message was: ' +
347
+ event.data +
348
+ '. This error can be disabled by setting the checkOrigin: false option or by providing of array of trusted domains.'
349
+ )
350
+ }
351
+
352
+ return true
353
+ }
354
+
355
+ function isMessageForUs() {
356
+ return (
357
+ msgId === ('' + msg).slice(0, msgIdLen) &&
358
+ msg.slice(msgIdLen).split(':')[0] in settings
359
+ ) // ''+Protects against non-string msg
360
+ }
361
+
362
+ function isMessageFromMetaParent() {
363
+ // Test if this message is from a parent above us. This is an ugly test, however, updating
364
+ // the message format would break backwards compatibility.
365
+ var retCode = messageData.type in { true: 1, false: 1, undefined: 1 };
366
+
367
+ if (retCode) {
368
+ log(iframeId, 'Ignoring init message from meta parent page');
369
+ }
370
+
371
+ return retCode
372
+ }
373
+
374
+ function getMsgBody(offset) {
375
+ return msg.slice(msg.indexOf(':') + msgHeaderLen + offset)
376
+ }
377
+
378
+ function forwardMsgFromIFrame(msgBody) {
379
+ log(
380
+ iframeId,
381
+ 'onMessage passed: {iframe: ' +
382
+ messageData.iframe.id +
383
+ ', message: ' +
384
+ msgBody +
385
+ '}'
386
+ );
387
+
388
+ on('onMessage', {
389
+ iframe: messageData.iframe,
390
+ message: JSON.parse(msgBody)
391
+ });
392
+
393
+ log(iframeId, '--');
394
+ }
395
+
396
+ function getPageInfo() {
397
+ var bodyPosition = document.body.getBoundingClientRect(),
398
+ iFramePosition = messageData.iframe.getBoundingClientRect();
399
+
400
+ return JSON.stringify({
401
+ iframeHeight: iFramePosition.height,
402
+ iframeWidth: iFramePosition.width,
403
+ clientHeight: Math.max(
404
+ document.documentElement.clientHeight,
405
+ window.innerHeight || 0
406
+ ),
407
+ clientWidth: Math.max(
408
+ document.documentElement.clientWidth,
409
+ window.innerWidth || 0
410
+ ),
411
+ offsetTop: parseInt(iFramePosition.top - bodyPosition.top, 10),
412
+ offsetLeft: parseInt(iFramePosition.left - bodyPosition.left, 10),
413
+ scrollTop: window.pageYOffset,
414
+ scrollLeft: window.pageXOffset,
415
+ documentHeight: document.documentElement.clientHeight,
416
+ documentWidth: document.documentElement.clientWidth,
417
+ windowHeight: window.innerHeight,
418
+ windowWidth: window.innerWidth
419
+ })
420
+ }
421
+
422
+ function sendPageInfoToIframe(iframe, iframeId) {
423
+ function debouncedTrigger() {
424
+ trigger('Send Page Info', 'pageInfo:' + getPageInfo(), iframe, iframeId);
425
+ }
426
+ debounceFrameEvents(debouncedTrigger, 32, iframeId);
427
+ }
428
+
429
+ function startPageInfoMonitor() {
430
+ function setListener(type, func) {
431
+ function sendPageInfo() {
432
+ if (settings[id]) {
433
+ sendPageInfoToIframe(settings[id].iframe, id);
434
+ } else {
435
+ stop();
436
+ }
437
+ }
438
+ ['scroll', 'resize'].forEach(function (evt) {
439
+ log(id, type + evt + ' listener for sendPageInfo');
440
+ func(window, evt, sendPageInfo);
441
+ });
442
+ }
443
+
444
+ function stop() {
445
+ setListener('Remove ', removeEventListener);
446
+ }
447
+
448
+ function start() {
449
+ setListener('Add ', addEventListener);
450
+ }
451
+
452
+ var id = iframeId; // Create locally scoped copy of iFrame ID
453
+
454
+ start();
455
+
456
+ if (settings[id]) {
457
+ settings[id].stopPageInfo = stop;
458
+ }
459
+ }
460
+
461
+ function stopPageInfoMonitor() {
462
+ if (settings[iframeId] && settings[iframeId].stopPageInfo) {
463
+ settings[iframeId].stopPageInfo();
464
+ delete settings[iframeId].stopPageInfo;
465
+ }
466
+ }
467
+
468
+ function checkIFrameExists() {
469
+ var retBool = true;
470
+
471
+ if (null === messageData.iframe) {
472
+ warn(iframeId, 'IFrame (' + messageData.id + ') not found');
473
+ retBool = false;
474
+ }
475
+ return retBool
476
+ }
477
+
478
+ function getElementPosition(target) {
479
+ var iFramePosition = target.getBoundingClientRect();
480
+
481
+ getPagePosition(iframeId);
482
+
483
+ return {
484
+ x: Math.floor(Number(iFramePosition.left) + Number(pagePosition.x)),
485
+ y: Math.floor(Number(iFramePosition.top) + Number(pagePosition.y))
486
+ }
487
+ }
488
+
489
+ function scrollRequestFromChild(addOffset) {
490
+ /* istanbul ignore next */ // Not testable in Karma
491
+ function reposition() {
492
+ pagePosition = newPosition;
493
+ scrollTo();
494
+ log(iframeId, '--');
495
+ }
496
+
497
+ function calcOffset() {
498
+ return {
499
+ x: Number(messageData.width) + offset.x,
500
+ y: Number(messageData.height) + offset.y
501
+ }
502
+ }
503
+
504
+ function scrollParent() {
505
+ if (window.parentIFrame) {
506
+ window.parentIFrame['scrollTo' + (addOffset ? 'Offset' : '')](
507
+ newPosition.x,
508
+ newPosition.y
509
+ );
510
+ } else {
511
+ warn(
512
+ iframeId,
513
+ 'Unable to scroll to requested position, window.parentIFrame not found'
514
+ );
515
+ }
516
+ }
517
+
518
+ var offset = addOffset
519
+ ? getElementPosition(messageData.iframe)
520
+ : { x: 0, y: 0 },
521
+ newPosition = calcOffset();
522
+
523
+ log(
524
+ iframeId,
525
+ 'Reposition requested from iFrame (offset x:' +
526
+ offset.x +
527
+ ' y:' +
528
+ offset.y +
529
+ ')'
530
+ );
531
+
532
+ if (window.top === window.self) {
533
+ reposition();
534
+ } else {
535
+ scrollParent();
536
+ }
537
+ }
538
+
539
+ function scrollTo() {
540
+ if (false === on('onScroll', pagePosition)) {
541
+ unsetPagePosition();
542
+ } else {
543
+ setPagePosition(iframeId);
544
+ }
545
+ }
546
+
547
+ function findTarget(location) {
548
+ function jumpToTarget() {
549
+ var jumpPosition = getElementPosition(target);
550
+
551
+ log(
552
+ iframeId,
553
+ 'Moving to in page link (#' +
554
+ hash +
555
+ ') at x: ' +
556
+ jumpPosition.x +
557
+ ' y: ' +
558
+ jumpPosition.y
559
+ );
560
+ pagePosition = {
561
+ x: jumpPosition.x,
562
+ y: jumpPosition.y
563
+ };
564
+
565
+ scrollTo();
566
+ log(iframeId, '--');
567
+ }
568
+
569
+ function jumpToParent() {
570
+ if (window.parentIFrame) {
571
+ window.parentIFrame.moveToAnchor(hash);
572
+ } else {
573
+ log(
574
+ iframeId,
575
+ 'In page link #' +
576
+ hash +
577
+ ' not found and window.parentIFrame not found'
578
+ );
579
+ }
580
+ }
581
+
582
+ var hash = location.split('#')[1] || '',
583
+ hashData = decodeURIComponent(hash),
584
+ target =
585
+ document.getElementById(hashData) ||
586
+ document.getElementsByName(hashData)[0];
587
+
588
+ if (target) {
589
+ jumpToTarget();
590
+ } else if (window.top === window.self) {
591
+ log(iframeId, 'In page link #' + hash + ' not found');
592
+ } else {
593
+ jumpToParent();
594
+ }
595
+ }
596
+
597
+ function onMouse(event) {
598
+ var mousePos = {};
599
+
600
+ if (Number(messageData.width) === 0 && Number(messageData.height) === 0) {
601
+ var data = getMsgBody(9).split(':');
602
+ mousePos = {
603
+ x: data[1],
604
+ y: data[0]
605
+ };
606
+ } else {
607
+ mousePos = {
608
+ x: messageData.width,
609
+ y: messageData.height
610
+ };
611
+ }
612
+
613
+ on(event, {
614
+ iframe: messageData.iframe,
615
+ screenX: Number(mousePos.x),
616
+ screenY: Number(mousePos.y),
617
+ type: messageData.type
618
+ });
619
+ }
620
+
621
+ function on(funcName, val) {
622
+ return chkEvent(iframeId, funcName, val)
623
+ }
624
+
625
+ function actionMsg() {
626
+ if (settings[iframeId] && settings[iframeId].firstRun) firstRun();
627
+
628
+ switch (messageData.type) {
629
+ case 'close': {
630
+ closeIFrame(messageData.iframe);
631
+ break
632
+ }
633
+
634
+ case 'message': {
635
+ forwardMsgFromIFrame(getMsgBody(6));
636
+ break
637
+ }
638
+
639
+ case 'mouseenter': {
640
+ onMouse('onMouseEnter');
641
+ break
642
+ }
643
+
644
+ case 'mouseleave': {
645
+ onMouse('onMouseLeave');
646
+ break
647
+ }
648
+
649
+ case 'autoResize': {
650
+ settings[iframeId].autoResize = JSON.parse(getMsgBody(9));
651
+ break
652
+ }
653
+
654
+ case 'scrollTo': {
655
+ scrollRequestFromChild(false);
656
+ break
657
+ }
658
+
659
+ case 'scrollToOffset': {
660
+ scrollRequestFromChild(true);
661
+ break
662
+ }
663
+
664
+ case 'pageInfo': {
665
+ sendPageInfoToIframe(
666
+ settings[iframeId] && settings[iframeId].iframe,
667
+ iframeId
668
+ );
669
+ startPageInfoMonitor();
670
+ break
671
+ }
672
+
673
+ case 'pageInfoStop': {
674
+ stopPageInfoMonitor();
675
+ break
676
+ }
677
+
678
+ case 'inPageLink': {
679
+ findTarget(getMsgBody(9));
680
+ break
681
+ }
682
+
683
+ case 'reset': {
684
+ resetIFrame(messageData);
685
+ break
686
+ }
687
+
688
+ case 'init': {
689
+ resizeIFrame();
690
+ on('onInit', messageData.iframe);
691
+ break
692
+ }
693
+
694
+ default: {
695
+ if (
696
+ Number(messageData.width) === 0 &&
697
+ Number(messageData.height) === 0
698
+ ) {
699
+ warn(
700
+ 'Unsupported message received (' +
701
+ messageData.type +
702
+ '), this is likely due to the iframe containing a later ' +
703
+ 'version of iframe-resizer than the parent page'
704
+ );
705
+ } else {
706
+ resizeIFrame();
707
+ }
708
+ }
709
+ }
710
+ }
711
+
712
+ function hasSettings(iframeId) {
713
+ var retBool = true;
714
+
715
+ if (!settings[iframeId]) {
716
+ retBool = false;
717
+ warn(
718
+ messageData.type +
719
+ ' No settings for ' +
720
+ iframeId +
721
+ '. Message was: ' +
722
+ msg
723
+ );
724
+ }
725
+
726
+ return retBool
727
+ }
728
+
729
+ function iFrameReadyMsgReceived() {
730
+ // eslint-disable-next-line no-restricted-syntax, guard-for-in
731
+ for (var iframeId in settings) {
732
+ trigger(
733
+ 'iFrame requested init',
734
+ createOutgoingMsg(iframeId),
735
+ settings[iframeId].iframe,
736
+ iframeId
737
+ );
738
+ }
739
+ }
740
+
741
+ function firstRun() {
742
+ if (settings[iframeId]) {
743
+ settings[iframeId].firstRun = false;
744
+ }
745
+ }
746
+
747
+ var msg = event.data,
748
+ messageData = {},
749
+ iframeId = null;
750
+
751
+ if ('[iFrameResizerChild]Ready' === msg) {
752
+ iFrameReadyMsgReceived();
753
+ } else if (isMessageForUs()) {
754
+ messageData = processMsg();
755
+ iframeId = messageData.id;
756
+ if (settings[iframeId]) {
757
+ settings[iframeId].loaded = true;
758
+ }
759
+
760
+ if (!isMessageFromMetaParent() && hasSettings(iframeId)) {
761
+ log(iframeId, 'Received: ' + msg);
762
+
763
+ if (checkIFrameExists() && isMessageFromIFrame()) {
764
+ actionMsg();
765
+ }
766
+ }
767
+ } else {
768
+ info(iframeId, 'Ignored: ' + msg);
769
+ }
770
+ }
771
+
772
+ function chkEvent(iframeId, funcName, val) {
773
+ var func = null,
774
+ retVal = null;
775
+
776
+ if (settings[iframeId]) {
777
+ func = settings[iframeId][funcName];
778
+
779
+ if ('function' === typeof func) {
780
+ retVal = func(val);
781
+ } else {
782
+ throw new TypeError(
783
+ funcName + ' on iFrame[' + iframeId + '] is not a function'
784
+ )
785
+ }
786
+ }
787
+
788
+ return retVal
789
+ }
790
+
791
+ function removeIframeListeners(iframe) {
792
+ var iframeId = iframe.id;
793
+ delete settings[iframeId];
794
+ }
795
+
796
+ function closeIFrame(iframe) {
797
+ var iframeId = iframe.id;
798
+ if (chkEvent(iframeId, 'onClose', iframeId) === false) {
799
+ log(iframeId, 'Close iframe cancelled by onClose event');
800
+ return
801
+ }
802
+ log(iframeId, 'Removing iFrame: ' + iframeId);
803
+
804
+ try {
805
+ // Catch race condition error with React
806
+ if (iframe.parentNode) {
807
+ iframe.parentNode.removeChild(iframe);
808
+ }
809
+ } catch (error) {
810
+ warn(error);
811
+ }
812
+
813
+ chkEvent(iframeId, 'onClosed', iframeId);
814
+ log(iframeId, '--');
815
+ removeIframeListeners(iframe);
816
+ }
817
+
818
+ function getPagePosition(iframeId) {
819
+ if (null === pagePosition) {
820
+ pagePosition = {
821
+ x:
822
+ window.pageXOffset === undefined$1
823
+ ? document.documentElement.scrollLeft
824
+ : window.pageXOffset,
825
+ y:
826
+ window.pageYOffset === undefined$1
827
+ ? document.documentElement.scrollTop
828
+ : window.pageYOffset
829
+ };
830
+ log(
831
+ iframeId,
832
+ 'Get page position: ' + pagePosition.x + ',' + pagePosition.y
833
+ );
834
+ }
835
+ }
836
+
837
+ function setPagePosition(iframeId) {
838
+ if (null !== pagePosition) {
839
+ window.scrollTo(pagePosition.x, pagePosition.y);
840
+ log(
841
+ iframeId,
842
+ 'Set page position: ' + pagePosition.x + ',' + pagePosition.y
843
+ );
844
+ unsetPagePosition();
845
+ }
846
+ }
847
+
848
+ function unsetPagePosition() {
849
+ pagePosition = null;
850
+ }
851
+
852
+ function resetIFrame(messageData) {
853
+ function reset() {
854
+ setSize(messageData);
855
+ trigger('reset', 'reset', messageData.iframe, messageData.id);
856
+ }
857
+
858
+ log(
859
+ messageData.id,
860
+ 'Size reset requested by ' +
861
+ ('init' === messageData.type ? 'host page' : 'iFrame')
862
+ );
863
+ getPagePosition(messageData.id);
864
+ syncResize(reset, messageData, 'reset');
865
+ }
866
+
867
+ function setSize(messageData) {
868
+ function setDimension(dimension) {
869
+ if (!messageData.id) {
870
+ log('undefined', 'messageData id not set');
871
+ return
872
+ }
873
+ messageData.iframe.style[dimension] = messageData[dimension] + 'px';
874
+ log(
875
+ messageData.id,
876
+ 'IFrame (' +
877
+ iframeId +
878
+ ') ' +
879
+ dimension +
880
+ ' set to ' +
881
+ messageData[dimension] +
882
+ 'px'
883
+ );
884
+ }
885
+
886
+ function chkZero(dimension) {
887
+ // FireFox sets dimension of hidden iFrames to zero.
888
+ // So if we detect that set up an event to check for
889
+ // when iFrame becomes visible.
890
+
891
+ /* istanbul ignore next */ // Not testable in PhantomJS
892
+ if (!hiddenCheckEnabled && '0' === messageData[dimension]) {
893
+ hiddenCheckEnabled = true;
894
+ log(iframeId, 'Hidden iFrame detected, creating visibility listener');
895
+ fixHiddenIFrames();
896
+ }
897
+ }
898
+
899
+ function processDimension(dimension) {
900
+ setDimension(dimension);
901
+ chkZero(dimension);
902
+ }
903
+
904
+ var iframeId = messageData.iframe.id;
905
+
906
+ if (settings[iframeId]) {
907
+ if (settings[iframeId].sizeHeight) {
908
+ processDimension('height');
909
+ }
910
+ if (settings[iframeId].sizeWidth) {
911
+ processDimension('width');
912
+ }
913
+ }
914
+ }
915
+
916
+ function syncResize(func, messageData, doNotSync) {
917
+ /* istanbul ignore if */ // Not testable in PhantomJS
918
+ if (
919
+ doNotSync !== messageData.type &&
920
+ requestAnimationFrame &&
921
+ // including check for jasmine because had trouble getting spy to work in unit test using requestAnimationFrame
922
+ !window.jasmine
923
+ ) {
924
+ log(messageData.id, 'Requesting animation frame');
925
+ requestAnimationFrame(func);
926
+ } else {
927
+ func();
928
+ }
929
+ }
930
+
931
+ function trigger(calleeMsg, msg, iframe, id, noResponseWarning) {
932
+ function postMessageToIFrame() {
933
+ var target = settings[id] && settings[id].targetOrigin;
934
+ log(
935
+ id,
936
+ '[' +
937
+ calleeMsg +
938
+ '] Sending msg to iframe[' +
939
+ id +
940
+ '] (' +
941
+ msg +
942
+ ') targetOrigin: ' +
943
+ target
944
+ );
945
+ iframe.contentWindow.postMessage(msgId + msg, target);
946
+ }
947
+
948
+ function iFrameNotFound() {
949
+ warn(id, '[' + calleeMsg + '] IFrame(' + id + ') not found');
950
+ }
951
+
952
+ function chkAndSend() {
953
+ if (
954
+ iframe &&
955
+ 'contentWindow' in iframe &&
956
+ null !== iframe.contentWindow
957
+ ) {
958
+ // Null test for PhantomJS
959
+ postMessageToIFrame();
960
+ } else {
961
+ iFrameNotFound();
962
+ }
963
+ }
964
+
965
+ function warnOnNoResponse() {
966
+ function warning() {
967
+ if (settings[id] && !settings[id].loaded && !errorShown) {
968
+ errorShown = true;
969
+ warn(
970
+ id,
971
+ 'IFrame has not responded within ' +
972
+ settings[id].warningTimeout / 1000 +
973
+ ' seconds. Check iFrameResizer.contentWindow.js has been loaded in iFrame. This message can be ignored if everything is working, or you can set the warningTimeout option to a higher value or zero to suppress this warning.'
974
+ );
975
+ }
976
+ }
977
+
978
+ if (
979
+ !!noResponseWarning &&
980
+ settings[id] &&
981
+ !!settings[id].warningTimeout
982
+ ) {
983
+ settings[id].msgTimeout = setTimeout(
984
+ warning,
985
+ settings[id].warningTimeout
986
+ );
987
+ }
988
+ }
989
+
990
+ var errorShown = false;
991
+
992
+ id = id || iframe.id;
993
+
994
+ if (settings[id]) {
995
+ chkAndSend();
996
+ warnOnNoResponse();
997
+ }
998
+ }
999
+
1000
+ function createOutgoingMsg(iframeId) {
1001
+ return (
1002
+ iframeId +
1003
+ ':' +
1004
+ settings[iframeId].bodyMarginV1 +
1005
+ ':' +
1006
+ settings[iframeId].sizeWidth +
1007
+ ':' +
1008
+ settings[iframeId].log +
1009
+ ':' +
1010
+ settings[iframeId].interval +
1011
+ ':' +
1012
+ settings[iframeId].enablePublicMethods +
1013
+ ':' +
1014
+ settings[iframeId].autoResize +
1015
+ ':' +
1016
+ settings[iframeId].bodyMargin +
1017
+ ':' +
1018
+ settings[iframeId].heightCalculationMethod +
1019
+ ':' +
1020
+ settings[iframeId].bodyBackground +
1021
+ ':' +
1022
+ settings[iframeId].bodyPadding +
1023
+ ':' +
1024
+ settings[iframeId].tolerance +
1025
+ ':' +
1026
+ settings[iframeId].inPageLinks +
1027
+ ':' +
1028
+ settings[iframeId].resizeFrom +
1029
+ ':' +
1030
+ settings[iframeId].widthCalculationMethod +
1031
+ ':' +
1032
+ settings[iframeId].mouseEvents
1033
+ )
1034
+ }
1035
+
1036
+ function isNumber(value) {
1037
+ return typeof value === 'number'
1038
+ }
1039
+
1040
+ function setupIFrame(iframe, options) {
1041
+ function setLimits() {
1042
+ function addStyle(style) {
1043
+ var styleValue = settings[iframeId][style];
1044
+ if (Infinity !== styleValue && 0 !== styleValue) {
1045
+ iframe.style[style] = isNumber(styleValue)
1046
+ ? styleValue + 'px'
1047
+ : styleValue;
1048
+ log(iframeId, 'Set ' + style + ' = ' + iframe.style[style]);
1049
+ }
1050
+ }
1051
+
1052
+ function chkMinMax(dimension) {
1053
+ if (
1054
+ settings[iframeId]['min' + dimension] >
1055
+ settings[iframeId]['max' + dimension]
1056
+ ) {
1057
+ throw new Error(
1058
+ 'Value for min' +
1059
+ dimension +
1060
+ ' can not be greater than max' +
1061
+ dimension
1062
+ )
1063
+ }
1064
+ }
1065
+
1066
+ chkMinMax('Height');
1067
+ chkMinMax('Width');
1068
+
1069
+ addStyle('maxHeight');
1070
+ addStyle('minHeight');
1071
+ addStyle('maxWidth');
1072
+ addStyle('minWidth');
1073
+ }
1074
+
1075
+ function newId() {
1076
+ var id = (options && options.id) || defaults.id + count++;
1077
+ if (null !== document.getElementById(id)) {
1078
+ id += count++;
1079
+ }
1080
+ return id
1081
+ }
1082
+
1083
+ function ensureHasId(iframeId) {
1084
+ if (typeof iframeId !== 'string') {
1085
+ throw new TypeError('Invaild id for iFrame. Expected String')
1086
+ }
1087
+
1088
+ if ('' === iframeId) {
1089
+ // eslint-disable-next-line no-multi-assign
1090
+ iframe.id = iframeId = newId();
1091
+ logEnabled = (options || {}).log;
1092
+ log(
1093
+ iframeId,
1094
+ 'Added missing iframe ID: ' + iframeId + ' (' + iframe.src + ')'
1095
+ );
1096
+ }
1097
+
1098
+ return iframeId
1099
+ }
1100
+
1101
+ function setScrolling() {
1102
+ log(
1103
+ iframeId,
1104
+ 'IFrame scrolling ' +
1105
+ (settings[iframeId] && settings[iframeId].scrolling
1106
+ ? 'enabled'
1107
+ : 'disabled') +
1108
+ ' for ' +
1109
+ iframeId
1110
+ );
1111
+ iframe.style.overflow =
1112
+ false === (settings[iframeId] && settings[iframeId].scrolling)
1113
+ ? 'hidden'
1114
+ : 'auto';
1115
+ switch (settings[iframeId] && settings[iframeId].scrolling) {
1116
+ case 'omit': {
1117
+ break
1118
+ }
1119
+
1120
+ case true: {
1121
+ iframe.scrolling = 'yes';
1122
+ break
1123
+ }
1124
+
1125
+ case false: {
1126
+ iframe.scrolling = 'no';
1127
+ break
1128
+ }
1129
+
1130
+ default: {
1131
+ iframe.scrolling = settings[iframeId]
1132
+ ? settings[iframeId].scrolling
1133
+ : 'no';
1134
+ }
1135
+ }
1136
+ }
1137
+
1138
+ // The V1 iFrame script expects an int, where as in V2 expects a CSS
1139
+ // string value such as '1px 3em', so if we have an int for V2, set V1=V2
1140
+ // and then convert V2 to a string PX value.
1141
+ function setupBodyMarginValues() {
1142
+ if (
1143
+ 'number' ===
1144
+ typeof (settings[iframeId] && settings[iframeId].bodyMargin) ||
1145
+ '0' === (settings[iframeId] && settings[iframeId].bodyMargin)
1146
+ ) {
1147
+ settings[iframeId].bodyMarginV1 = settings[iframeId].bodyMargin;
1148
+ settings[iframeId].bodyMargin =
1149
+ '' + settings[iframeId].bodyMargin + 'px';
1150
+ }
1151
+ }
1152
+
1153
+ function checkReset() {
1154
+ // Reduce scope of firstRun to function, because IE8's JS execution
1155
+ // context stack is borked and this value gets externally
1156
+ // changed midway through running this function!!!
1157
+ var firstRun = settings[iframeId] && settings[iframeId].firstRun,
1158
+ resetRequertMethod =
1159
+ settings[iframeId] &&
1160
+ settings[iframeId].heightCalculationMethod in resetRequiredMethods;
1161
+
1162
+ if (!firstRun && resetRequertMethod) {
1163
+ resetIFrame({ iframe: iframe, height: 0, width: 0, type: 'init' });
1164
+ }
1165
+ }
1166
+
1167
+ function setupIFrameObject() {
1168
+ if (settings[iframeId]) {
1169
+ settings[iframeId].iframe.iFrameResizer = {
1170
+ close: closeIFrame.bind(null, settings[iframeId].iframe),
1171
+
1172
+ removeListeners: removeIframeListeners.bind(
1173
+ null,
1174
+ settings[iframeId].iframe
1175
+ ),
1176
+
1177
+ resize: trigger.bind(
1178
+ null,
1179
+ 'Window resize',
1180
+ 'resize',
1181
+ settings[iframeId].iframe
1182
+ ),
1183
+
1184
+ moveToAnchor: function (anchor) {
1185
+ trigger(
1186
+ 'Move to anchor',
1187
+ 'moveToAnchor:' + anchor,
1188
+ settings[iframeId].iframe,
1189
+ iframeId
1190
+ );
1191
+ },
1192
+
1193
+ sendMessage: function (message) {
1194
+ message = JSON.stringify(message);
1195
+ trigger(
1196
+ 'Send Message',
1197
+ 'message:' + message,
1198
+ settings[iframeId].iframe,
1199
+ iframeId
1200
+ );
1201
+ }
1202
+ };
1203
+ }
1204
+ }
1205
+
1206
+ // We have to call trigger twice, as we can not be sure if all
1207
+ // iframes have completed loading when this code runs. The
1208
+ // event listener also catches the page changing in the iFrame.
1209
+ function init(msg) {
1210
+ function iFrameLoaded() {
1211
+ trigger('iFrame.onload', msg, iframe, undefined$1, true);
1212
+ checkReset();
1213
+ }
1214
+
1215
+ function createDestroyObserver(MutationObserver) {
1216
+ if (!iframe.parentNode) {
1217
+ return
1218
+ }
1219
+
1220
+ var destroyObserver = new MutationObserver(function (mutations) {
1221
+ mutations.forEach(function (mutation) {
1222
+ var removedNodes = Array.prototype.slice.call(mutation.removedNodes); // Transform NodeList into an Array
1223
+ removedNodes.forEach(function (removedNode) {
1224
+ if (removedNode === iframe) {
1225
+ closeIFrame(iframe);
1226
+ }
1227
+ });
1228
+ });
1229
+ });
1230
+ destroyObserver.observe(iframe.parentNode, {
1231
+ childList: true
1232
+ });
1233
+ }
1234
+
1235
+ var MutationObserver = getMutationObserver();
1236
+ if (MutationObserver) {
1237
+ createDestroyObserver(MutationObserver);
1238
+ }
1239
+
1240
+ addEventListener(iframe, 'load', iFrameLoaded);
1241
+ trigger('init', msg, iframe, undefined$1, true);
1242
+ }
1243
+
1244
+ function checkOptions(options) {
1245
+ if ('object' !== typeof options) {
1246
+ throw new TypeError('Options is not an object')
1247
+ }
1248
+ }
1249
+
1250
+ function copyOptions(options) {
1251
+ // eslint-disable-next-line no-restricted-syntax
1252
+ for (var option in defaults) {
1253
+ if (Object.prototype.hasOwnProperty.call(defaults, option)) {
1254
+ settings[iframeId][option] = Object.prototype.hasOwnProperty.call(
1255
+ options,
1256
+ option
1257
+ )
1258
+ ? options[option]
1259
+ : defaults[option];
1260
+ }
1261
+ }
1262
+ }
1263
+
1264
+ function getTargetOrigin(remoteHost) {
1265
+ return '' === remoteHost ||
1266
+ null !== remoteHost.match(/^(about:blank|javascript:|file:\/\/)/)
1267
+ ? '*'
1268
+ : remoteHost
1269
+ }
1270
+
1271
+ function depricate(key) {
1272
+ var splitName = key.split('Callback');
1273
+
1274
+ if (splitName.length === 2) {
1275
+ var name =
1276
+ 'on' + splitName[0].charAt(0).toUpperCase() + splitName[0].slice(1);
1277
+ this[name] = this[key];
1278
+ delete this[key];
1279
+ warn(
1280
+ iframeId,
1281
+ "Deprecated: '" +
1282
+ key +
1283
+ "' has been renamed '" +
1284
+ name +
1285
+ "'. The old method will be removed in the next major version."
1286
+ );
1287
+ }
1288
+ }
1289
+
1290
+ function processOptions(options) {
1291
+ options = options || {};
1292
+
1293
+ settings[iframeId] = Object.create(null); // Protect against prototype attacks
1294
+ settings[iframeId].iframe = iframe;
1295
+ settings[iframeId].firstRun = true;
1296
+ settings[iframeId].remoteHost =
1297
+ iframe.src && iframe.src.split('/').slice(0, 3).join('/');
1298
+
1299
+ checkOptions(options);
1300
+ Object.keys(options).forEach(depricate, options);
1301
+ copyOptions(options);
1302
+
1303
+ if (settings[iframeId]) {
1304
+ settings[iframeId].targetOrigin =
1305
+ true === settings[iframeId].checkOrigin
1306
+ ? getTargetOrigin(settings[iframeId].remoteHost)
1307
+ : '*';
1308
+ }
1309
+ }
1310
+
1311
+ function beenHere() {
1312
+ return iframeId in settings && 'iFrameResizer' in iframe
1313
+ }
1314
+
1315
+ var iframeId = ensureHasId(iframe.id);
1316
+
1317
+ if (beenHere()) {
1318
+ warn(iframeId, 'Ignored iFrame, already setup.');
1319
+ } else {
1320
+ processOptions(options);
1321
+ setScrolling();
1322
+ setLimits();
1323
+ setupBodyMarginValues();
1324
+ init(createOutgoingMsg(iframeId));
1325
+ setupIFrameObject();
1326
+ }
1327
+ }
1328
+
1329
+ function debouce(fn, time) {
1330
+ if (null === timer) {
1331
+ timer = setTimeout(function () {
1332
+ timer = null;
1333
+ fn();
1334
+ }, time);
1335
+ }
1336
+ }
1337
+
1338
+ var frameTimer = {};
1339
+ function debounceFrameEvents(fn, time, frameId) {
1340
+ if (!frameTimer[frameId]) {
1341
+ frameTimer[frameId] = setTimeout(function () {
1342
+ frameTimer[frameId] = null;
1343
+ fn();
1344
+ }, time);
1345
+ }
1346
+ }
1347
+
1348
+ // Not testable in PhantomJS
1349
+ /* istanbul ignore next */
1350
+
1351
+ function fixHiddenIFrames() {
1352
+ function checkIFrames() {
1353
+ function checkIFrame(settingId) {
1354
+ function chkDimension(dimension) {
1355
+ return (
1356
+ '0px' ===
1357
+ (settings[settingId] && settings[settingId].iframe.style[dimension])
1358
+ )
1359
+ }
1360
+
1361
+ function isVisible(el) {
1362
+ return null !== el.offsetParent
1363
+ }
1364
+
1365
+ if (
1366
+ settings[settingId] &&
1367
+ isVisible(settings[settingId].iframe) &&
1368
+ (chkDimension('height') || chkDimension('width'))
1369
+ ) {
1370
+ trigger(
1371
+ 'Visibility change',
1372
+ 'resize',
1373
+ settings[settingId].iframe,
1374
+ settingId
1375
+ );
1376
+ }
1377
+ }
1378
+
1379
+ Object.keys(settings).forEach(function (key) {
1380
+ checkIFrame(key);
1381
+ });
1382
+ }
1383
+
1384
+ function mutationObserved(mutations) {
1385
+ log(
1386
+ 'window',
1387
+ 'Mutation observed: ' + mutations[0].target + ' ' + mutations[0].type
1388
+ );
1389
+ debouce(checkIFrames, 16);
1390
+ }
1391
+
1392
+ function createMutationObserver() {
1393
+ var target = document.querySelector('body'),
1394
+ config = {
1395
+ attributes: true,
1396
+ attributeOldValue: false,
1397
+ characterData: true,
1398
+ characterDataOldValue: false,
1399
+ childList: true,
1400
+ subtree: true
1401
+ },
1402
+ observer = new MutationObserver(mutationObserved);
1403
+
1404
+ observer.observe(target, config);
1405
+ }
1406
+
1407
+ var MutationObserver = getMutationObserver();
1408
+ if (MutationObserver) {
1409
+ createMutationObserver();
1410
+ }
1411
+ }
1412
+
1413
+ function resizeIFrames(event) {
1414
+ function resize() {
1415
+ sendTriggerMsg('Window ' + event, 'resize');
1416
+ }
1417
+
1418
+ log('window', 'Trigger event: ' + event);
1419
+ debouce(resize, 16);
1420
+ }
1421
+
1422
+ // Not testable in PhantomJS
1423
+ /* istanbul ignore next */
1424
+ function tabVisible() {
1425
+ function resize() {
1426
+ sendTriggerMsg('Tab Visible', 'resize');
1427
+ }
1428
+
1429
+ if ('hidden' !== document.visibilityState) {
1430
+ log('document', 'Trigger event: Visibility change');
1431
+ debouce(resize, 16);
1432
+ }
1433
+ }
1434
+
1435
+ function sendTriggerMsg(eventName, event) {
1436
+ function isIFrameResizeEnabled(iframeId) {
1437
+ return (
1438
+ settings[iframeId] &&
1439
+ 'parent' === settings[iframeId].resizeFrom &&
1440
+ settings[iframeId].autoResize &&
1441
+ !settings[iframeId].firstRun
1442
+ )
1443
+ }
1444
+
1445
+ Object.keys(settings).forEach(function (iframeId) {
1446
+ if (isIFrameResizeEnabled(iframeId)) {
1447
+ trigger(eventName, event, settings[iframeId].iframe, iframeId);
1448
+ }
1449
+ });
1450
+ }
1451
+
1452
+ function setupEventListeners() {
1453
+ addEventListener(window, 'message', iFrameListener);
1454
+
1455
+ addEventListener(window, 'resize', function () {
1456
+ resizeIFrames('resize');
1457
+ });
1458
+
1459
+ addEventListener(document, 'visibilitychange', tabVisible);
1460
+
1461
+ addEventListener(document, '-webkit-visibilitychange', tabVisible);
1462
+ }
1463
+
1464
+ function factory() {
1465
+ function init(options, element) {
1466
+ function chkType() {
1467
+ if (!element.tagName) {
1468
+ throw new TypeError('Object is not a valid DOM element')
1469
+ } else if ('IFRAME' !== element.tagName.toUpperCase()) {
1470
+ throw new TypeError(
1471
+ 'Expected <IFRAME> tag, found <' + element.tagName + '>'
1472
+ )
1473
+ }
1474
+ }
1475
+
1476
+ if (element) {
1477
+ chkType();
1478
+ setupIFrame(element, options);
1479
+ iFrames.push(element);
1480
+ }
1481
+ }
1482
+
1483
+ function warnDeprecatedOptions(options) {
1484
+ if (options && options.enablePublicMethods) {
1485
+ warn(
1486
+ 'enablePublicMethods option has been removed, public methods are now always available in the iFrame'
1487
+ );
1488
+ }
1489
+ }
1490
+
1491
+ var iFrames;
1492
+
1493
+ setupRequestAnimationFrame();
1494
+ setupEventListeners();
1495
+
1496
+ return function iFrameResizeF(options, target) {
1497
+ iFrames = []; // Only return iFrames past in on this call
1498
+
1499
+ warnDeprecatedOptions(options);
1500
+
1501
+ switch (typeof target) {
1502
+ case 'undefined':
1503
+ case 'string': {
1504
+ Array.prototype.forEach.call(
1505
+ document.querySelectorAll(target || 'iframe'),
1506
+ init.bind(undefined$1, options)
1507
+ );
1508
+ break
1509
+ }
1510
+
1511
+ case 'object': {
1512
+ init(options, target);
1513
+ break
1514
+ }
1515
+
1516
+ default: {
1517
+ throw new TypeError('Unexpected data type (' + typeof target + ')')
1518
+ }
1519
+ }
1520
+
1521
+ return iFrames
1522
+ }
1523
+ }
1524
+
1525
+ function createJQueryPublicMethod($) {
1526
+ if (!$.fn) {
1527
+ info('', 'Unable to bind to jQuery, it is not fully loaded.');
1528
+ } else if (!$.fn.iFrameResize) {
1529
+ $.fn.iFrameResize = function $iFrameResizeF(options) {
1530
+ function init(index, element) {
1531
+ setupIFrame(element, options);
1532
+ }
1533
+
1534
+ return this.filter('iframe').each(init).end()
1535
+ };
1536
+ }
1537
+ }
1538
+
1539
+ if (window.jQuery !== undefined$1) {
1540
+ createJQueryPublicMethod(window.jQuery);
1541
+ }
1542
+
1543
+ if (typeof undefined$1 === 'function' && undefined$1.amd) {
1544
+ undefined$1([], factory);
1545
+ } else {
1546
+ // Node for browserfy
1547
+ module.exports = factory();
1548
+ }
1549
+ window.iFrameResize = window.iFrameResize || factory();
1550
+ })();
1551
+ });
1552
+
1553
+ const MessageEventType = {
1554
+ card: {
1555
+ ready: 'justifi.card.ready',
1556
+ tokenize: 'justifi.card.tokenize',
1557
+ validate: 'justifi.card.validate',
1558
+ resize: 'justifi.card.resize',
1559
+ styleOverrides: 'justifi.card.styleOverrides',
1560
+ },
1561
+ bankAccount: {
1562
+ ready: 'justifi.bankAccount.ready',
1563
+ tokenize: 'justifi.bankAccount.tokenize',
1564
+ validate: 'justifi.bankAccount.validate',
1565
+ resize: 'justifi.bankAccount.resize',
1566
+ styleOverrides: 'justifi.bankAccount.styleOverrides',
1567
+ },
1568
+ };
1569
+
1570
+ const name = "@justifi/webcomponents";
1571
+ const version = "4.9.0";
1572
+ const description = "JustiFi Web Components";
1573
+ const main = "dist/module/index.js";
1574
+ const module$1 = "dist/module/index.js";
1575
+ const types = "./dist/types/index.d.ts";
1576
+ const repository = {
1577
+ type: "git",
1578
+ url: "git+https://github.com/justifi-tech/web-component-library.git"
1579
+ };
1580
+ const homepage = "https://storybook.justifi.ai/?path=/docs/introduction--docs";
1581
+ const publishConfig = {
1582
+ registry: "https://registry.npmjs.org"
1583
+ };
1584
+ const files = [
1585
+ "dist/"
1586
+ ];
1587
+ const scripts = {
1588
+ build: "stencil build --docs",
1589
+ dev: "stencil build --watch",
1590
+ lint: "eslint . --max-warnings 0",
1591
+ clean: "rm -rf .turbo && rm -rf node_modules && rm -rf dist",
1592
+ generate: "stencil generate",
1593
+ test: "TZ=utc stencil test --spec",
1594
+ "test:watch": "TZ=utc stencil test --spec --watchAll",
1595
+ "test:e2e": "stencil test --e2e",
1596
+ "test:file": "stencil test --spec --watch --"
1597
+ };
1598
+ const dependencies = {
1599
+ "@stencil/core": "^4.0.5",
1600
+ bootstrap: "^5.2.3",
1601
+ "chart.js": "^4.4.1",
1602
+ "date-fns": "^2.29.3",
1603
+ "dinero.js": "^1.9.1",
1604
+ "iframe-resizer": "^4.3.7",
1605
+ imask: "^7.1.3",
1606
+ rxjs: "^7.8.1",
1607
+ "ts-dedent": "^2.2.0",
1608
+ uuid: "^9.0.0",
1609
+ yup: "^1.0.0"
1610
+ };
1611
+ const devDependencies = {
1612
+ "@babel/preset-env": "^7.21.5",
1613
+ "@babel/preset-react": "^7.18.6",
1614
+ "@babel/preset-typescript": "^7.21.5",
1615
+ "@stencil/sass": "^3.0.1",
1616
+ "@stencil/store": "^2.0.8",
1617
+ "@types/jest": "27.0.3",
1618
+ "@types/node": "^20.1.4",
1619
+ "@types/react": "^18.0.37",
1620
+ "@types/react-dom": "^18.0.11",
1621
+ dotenv: "^16.3.1",
1622
+ jest: "^29.7.0",
1623
+ "jest-cli": "^29.7.0",
1624
+ "jest-environment-node": "^29.7.0",
1625
+ puppeteer: "^21.0.0",
1626
+ "ts-jest": "^29.1.2"
1627
+ };
1628
+ const license = "MIT";
1629
+ const gitHead = "507bac1d941eae6e1f56e185ecd9bc9d22637783";
1630
+ const pnpm = {
1631
+ overrides: {
1632
+ "ip@<1.1.9": ">=1.1.9",
1633
+ "ip@=2.0.0": ">=2.0.1"
1634
+ }
1635
+ };
1636
+ const packageJson = {
1637
+ name: name,
1638
+ version: version,
1639
+ description: description,
1640
+ main: main,
1641
+ module: module$1,
1642
+ types: types,
1643
+ repository: repository,
1644
+ homepage: homepage,
1645
+ publishConfig: publishConfig,
1646
+ files: files,
1647
+ scripts: scripts,
1648
+ dependencies: dependencies,
1649
+ devDependencies: devDependencies,
1650
+ license: license,
1651
+ gitHead: gitHead,
1652
+ pnpm: pnpm
1653
+ };
1654
+
1655
+ const getComputedTheme = () => {
1656
+ const computedStyles = getComputedStyle(document.body);
1657
+ const computedTheme = {
1658
+ loadGoogleFont: computedStyles.getPropertyValue('--jfi-load-google-font'),
1659
+ layout: {
1660
+ fontFamily: computedStyles.getPropertyValue('--jfi-layout-font-family'),
1661
+ padding: computedStyles.getPropertyValue('--jfi-layout-padding'),
1662
+ formControlSpacingHorizontal: computedStyles.getPropertyValue('--jfi-layout-form-control-spacing-x'),
1663
+ formControlSpacingVertical: computedStyles.getPropertyValue('--jfi-layout-form-control-spacing-y'),
1664
+ },
1665
+ formControl: {
1666
+ backgroundColor: computedStyles.getPropertyValue('--jfi-form-control-background-color'),
1667
+ borderColor: computedStyles.getPropertyValue('--jfi-form-control-border-color'),
1668
+ borderColorFocus: computedStyles.getPropertyValue('--jfi-form-control-border-color-focus'),
1669
+ borderColorError: computedStyles.getPropertyValue('--jfi-form-control-border-color-error'),
1670
+ borderWidth: computedStyles.getPropertyValue('--jfi-form-control-border-width'),
1671
+ borderBottomWidth: computedStyles.getPropertyValue('--jfi-form-control-border-bottom-width'),
1672
+ borderLeftWidth: computedStyles.getPropertyValue('--jfi-form-control-border-left-width'),
1673
+ borderRightWidth: computedStyles.getPropertyValue('--jfi-form-control-border-right-width'),
1674
+ borderTopWidth: computedStyles.getPropertyValue('--jfi-form-control-border-top-width'),
1675
+ borderRadius: computedStyles.getPropertyValue('--jfi-form-control-border-radius'),
1676
+ borderStyle: computedStyles.getPropertyValue('--jfi-form-control-border-style'),
1677
+ boxShadow: computedStyles.getPropertyValue('--jfi-form-control-box-shadow'),
1678
+ boxShadowError: computedStyles.getPropertyValue('--jfi-form-control-box-shadow-error'),
1679
+ boxShadowErrorFocus: computedStyles.getPropertyValue('--jfi-form-control-box-shadow-error-focus'),
1680
+ boxShadowFocus: computedStyles.getPropertyValue('--jfi-form-control-box-shadow-focus'),
1681
+ color: computedStyles.getPropertyValue('--jfi-form-control-color'),
1682
+ colorFocus: computedStyles.getPropertyValue('--jfi-form-control-color-focus'),
1683
+ fontSize: computedStyles.getPropertyValue('--jfi-form-control-font-size'),
1684
+ fontWeight: computedStyles.getPropertyValue('--jfi-form-control-font-weight'),
1685
+ lineHeight: computedStyles.getPropertyValue('--jfi-form-control-line-height'),
1686
+ margin: computedStyles.getPropertyValue('--jfi-form-control-margin'),
1687
+ padding: computedStyles.getPropertyValue('--jfi-form-control-padding'),
1688
+ },
1689
+ formLabel: {
1690
+ color: computedStyles.getPropertyValue('--jfi-form-label-color'),
1691
+ fontFamily: computedStyles.getPropertyValue('--jfi-form-label-font-family'),
1692
+ fontSize: computedStyles.getPropertyValue('--jfi-form-label-font-size'),
1693
+ fontWeight: computedStyles.getPropertyValue('--jfi-form-label-font-weight'),
1694
+ margin: computedStyles.getPropertyValue('--jfi-form-label-margin'),
1695
+ },
1696
+ errorMessage: {
1697
+ color: computedStyles.getPropertyValue('--jfi-error-message-color'),
1698
+ margin: computedStyles.getPropertyValue('--jfi-error-message-margin'),
1699
+ fontSize: computedStyles.getPropertyValue('--jfi-error-message-font-size'),
1700
+ },
1701
+ };
1702
+ return computedTheme;
1703
+ };
1704
+
1705
+ /**
1706
+ * This approach decouples the communication logic from PaymentMethodForm component,
1707
+ * making it cleaner, more maintainable, and easier to test
1708
+ */
1709
+ class FrameCommunicationService {
1710
+ constructor(iframe, iframeOrigin) {
1711
+ this.iframe = iframe;
1712
+ this.iframeOrigin = iframeOrigin;
1713
+ }
1714
+ postMessage(eventType, payload) {
1715
+ const message = Object.assign({ eventType }, payload);
1716
+ this.iframe.contentWindow.postMessage(message, this.iframeOrigin);
1717
+ }
1718
+ addMessageListener(callback) {
1719
+ window.addEventListener('message', callback);
1720
+ }
1721
+ removeMessageListener(callback) {
1722
+ window.removeEventListener('message', callback);
1723
+ }
1724
+ postMessageWithResponseListener(eventType, payload) {
1725
+ return new Promise((resolve) => {
1726
+ const responseListener = (event) => {
1727
+ if (event.data.eventType !== eventType)
1728
+ return;
1729
+ window.removeEventListener('message', responseListener);
1730
+ resolve(event.data.data);
1731
+ };
1732
+ window.addEventListener('message', responseListener);
1733
+ this.postMessage(eventType, payload);
1734
+ });
1735
+ }
1736
+ }
1737
+
1738
+ const paymentMethodFormCss = ":host{display:block}justifi-payment-method-form iframe{border:none;width:100%}iframe{width:1px;min-width:100%}";
1739
+
1740
+ const PaymentMethodForm = class {
1741
+ constructor(hostRef) {
1742
+ index.registerInstance(this, hostRef);
1743
+ this.paymentMethodFormReady = index.createEvent(this, "paymentMethodFormReady", 7);
1744
+ this.paymentMethodFormValidated = index.createEvent(this, "paymentMethodFormValidated", 7);
1745
+ this.paymentMethodFormTokenized = index.createEvent(this, "paymentMethodFormTokenized", 7);
1746
+ this.computedTheme = getComputedTheme();
1747
+ this.dispatchMessageEvent = (messageEvent) => {
1748
+ const { eventType, data } = messageEvent.data;
1749
+ const eventTypeMessage = MessageEventType[this.paymentMethodFormType];
1750
+ if (eventType === eventTypeMessage.ready) {
1751
+ this.paymentMethodFormReady.emit(data);
1752
+ }
1753
+ else if (eventType === eventTypeMessage.tokenize) {
1754
+ this.paymentMethodFormTokenized.emit(data);
1755
+ }
1756
+ else if (eventType === eventTypeMessage.validate) {
1757
+ this.paymentMethodFormValidated.emit(data);
1758
+ }
1759
+ };
1760
+ this.postMessage = (eventType, payload) => {
1761
+ this.frameService.postMessage(eventType, payload);
1762
+ };
1763
+ this.paymentMethodFormType = undefined;
1764
+ this.paymentMethodFormValidationMode = undefined;
1765
+ this.iframeOrigin = undefined;
1766
+ this.singleLine = undefined;
1767
+ }
1768
+ disconnectedCallback() {
1769
+ this.frameService.removeMessageListener(this.dispatchMessageEvent);
1770
+ }
1771
+ async resize() {
1772
+ this.postMessage(MessageEventType[this.paymentMethodFormType].resize);
1773
+ }
1774
+ async tokenize(clientId, paymentMethodMetadata, account) {
1775
+ const eventType = MessageEventType[this.paymentMethodFormType].tokenize;
1776
+ return this.frameService.postMessageWithResponseListener(eventType, {
1777
+ clientId,
1778
+ paymentMethodMetadata,
1779
+ account,
1780
+ componentVersion: packageJson.version,
1781
+ });
1782
+ }
1783
+ async validate() {
1784
+ const eventType = MessageEventType[this.paymentMethodFormType].validate;
1785
+ return this.frameService.postMessageWithResponseListener(eventType);
1786
+ }
1787
+ sendStyleOverrides() {
1788
+ if (this.computedTheme) {
1789
+ this.postMessage(MessageEventType[this.paymentMethodFormType].styleOverrides, { styleOverrides: this.computedTheme });
1790
+ }
1791
+ }
1792
+ getIframeSrc() {
1793
+ let paramsList = [];
1794
+ if (this.paymentMethodFormValidationMode) {
1795
+ paramsList.push(`validationMode=${this.paymentMethodFormValidationMode}`);
1796
+ }
1797
+ if (this.singleLine) {
1798
+ paramsList.push(`singleLine=${this.singleLine}`);
1799
+ }
1800
+ let iframeSrc = `${this.iframeOrigin}/${this.paymentMethodFormType}${utils.composeQueryParams(paramsList)}`;
1801
+ return iframeSrc;
1802
+ }
1803
+ initializeFrameCommunicationService() {
1804
+ var _a;
1805
+ this.frameService = new FrameCommunicationService(this.iframeElement, this.iframeOrigin);
1806
+ (_a = this.frameService) === null || _a === void 0 ? void 0 : _a.addMessageListener(this.dispatchMessageEvent);
1807
+ }
1808
+ render() {
1809
+ return (index.h(index.Host, null, index.h("iframe", { id: `justifi-payment-method-form-${this.paymentMethodFormType}`, src: this.getIframeSrc(), ref: el => {
1810
+ this.iframeElement = el;
1811
+ }, onLoad: () => {
1812
+ iframeResizer({
1813
+ scrollbars: false,
1814
+ }, this.iframeElement);
1815
+ this.initializeFrameCommunicationService();
1816
+ this.sendStyleOverrides();
1817
+ } })));
1818
+ }
1819
+ };
1820
+ PaymentMethodForm.style = paymentMethodFormCss;
6
1821
 
7
1822
  const selectInputCss = ":root,[data-bs-theme=light]{--bs-blue:#0d6efd;--bs-indigo:#6610f2;--bs-purple:#6f42c1;--bs-pink:#d63384;--bs-red:#dc3545;--bs-orange:#fd7e14;--bs-yellow:#ffc107;--bs-green:#198754;--bs-teal:#20c997;--bs-cyan:#0dcaf0;--bs-black:#000;--bs-white:#fff;--bs-gray:#6c757d;--bs-gray-dark:#343a40;--bs-gray-100:#f8f9fa;--bs-gray-200:#e9ecef;--bs-gray-300:#dee2e6;--bs-gray-400:#ced4da;--bs-gray-500:#adb5bd;--bs-gray-600:#6c757d;--bs-gray-700:#495057;--bs-gray-800:#343a40;--bs-gray-900:#212529;--bs-primary:#0d6efd;--bs-secondary:#6c757d;--bs-success:#198754;--bs-info:#0dcaf0;--bs-warning:#ffc107;--bs-danger:#dc3545;--bs-light:#f8f9fa;--bs-dark:#212529;--bs-primary-rgb:13, 110, 253;--bs-secondary-rgb:108, 117, 125;--bs-success-rgb:25, 135, 84;--bs-info-rgb:13, 202, 240;--bs-warning-rgb:255, 193, 7;--bs-danger-rgb:220, 53, 69;--bs-light-rgb:248, 249, 250;--bs-dark-rgb:33, 37, 41;--bs-primary-text-emphasis:#052c65;--bs-secondary-text-emphasis:#2b2f32;--bs-success-text-emphasis:#0a3622;--bs-info-text-emphasis:#055160;--bs-warning-text-emphasis:#664d03;--bs-danger-text-emphasis:#58151c;--bs-light-text-emphasis:#495057;--bs-dark-text-emphasis:#495057;--bs-primary-bg-subtle:#cfe2ff;--bs-secondary-bg-subtle:#e2e3e5;--bs-success-bg-subtle:#d1e7dd;--bs-info-bg-subtle:#cff4fc;--bs-warning-bg-subtle:#fff3cd;--bs-danger-bg-subtle:#f8d7da;--bs-light-bg-subtle:#fcfcfd;--bs-dark-bg-subtle:#ced4da;--bs-primary-border-subtle:#9ec5fe;--bs-secondary-border-subtle:#c4c8cb;--bs-success-border-subtle:#a3cfbb;--bs-info-border-subtle:#9eeaf9;--bs-warning-border-subtle:#ffe69c;--bs-danger-border-subtle:#f1aeb5;--bs-light-border-subtle:#e9ecef;--bs-dark-border-subtle:#adb5bd;--bs-white-rgb:255, 255, 255;--bs-black-rgb:0, 0, 0;--bs-font-sans-serif:system-ui, -apple-system, \"Segoe UI\", Roboto, \"Helvetica Neue\", \"Noto Sans\", \"Liberation Sans\", Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\", \"Noto Color Emoji\";--bs-font-monospace:SFMono-Regular, Menlo, Monaco, Consolas, \"Liberation Mono\", \"Courier New\", monospace;--bs-gradient:linear-gradient(180deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0));--bs-body-font-family:var(--bs-font-sans-serif);--bs-body-font-size:1rem;--bs-body-font-weight:400;--bs-body-line-height:1.5;--bs-body-color:#212529;--bs-body-color-rgb:33, 37, 41;--bs-body-bg:#fff;--bs-body-bg-rgb:255, 255, 255;--bs-emphasis-color:#000;--bs-emphasis-color-rgb:0, 0, 0;--bs-secondary-color:rgba(33, 37, 41, 0.75);--bs-secondary-color-rgb:33, 37, 41;--bs-secondary-bg:#e9ecef;--bs-secondary-bg-rgb:233, 236, 239;--bs-tertiary-color:rgba(33, 37, 41, 0.5);--bs-tertiary-color-rgb:33, 37, 41;--bs-tertiary-bg:#f8f9fa;--bs-tertiary-bg-rgb:248, 249, 250;--bs-heading-color:inherit;--bs-link-color:#0d6efd;--bs-link-color-rgb:13, 110, 253;--bs-link-decoration:underline;--bs-link-hover-color:#0a58ca;--bs-link-hover-color-rgb:10, 88, 202;--bs-code-color:#d63384;--bs-highlight-color:#212529;--bs-highlight-bg:#fff3cd;--bs-border-width:1px;--bs-border-style:solid;--bs-border-color:#dee2e6;--bs-border-color-translucent:rgba(0, 0, 0, 0.175);--bs-border-radius:0.375rem;--bs-border-radius-sm:0.25rem;--bs-border-radius-lg:0.5rem;--bs-border-radius-xl:1rem;--bs-border-radius-xxl:2rem;--bs-border-radius-2xl:var(--bs-border-radius-xxl);--bs-border-radius-pill:50rem;--bs-box-shadow:0 0.5rem 1rem rgba(0, 0, 0, 0.15);--bs-box-shadow-sm:0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);--bs-box-shadow-lg:0 1rem 3rem rgba(0, 0, 0, 0.175);--bs-box-shadow-inset:inset 0 1px 2px rgba(0, 0, 0, 0.075);--bs-focus-ring-width:0.25rem;--bs-focus-ring-opacity:0.25;--bs-focus-ring-color:rgba(13, 110, 253, 0.25);--bs-form-valid-color:#198754;--bs-form-valid-border-color:#198754;--bs-form-invalid-color:#dc3545;--bs-form-invalid-border-color:#dc3545}[data-bs-theme=dark]{color-scheme:dark;--bs-body-color:#dee2e6;--bs-body-color-rgb:222, 226, 230;--bs-body-bg:#212529;--bs-body-bg-rgb:33, 37, 41;--bs-emphasis-color:#fff;--bs-emphasis-color-rgb:255, 255, 255;--bs-secondary-color:rgba(222, 226, 230, 0.75);--bs-secondary-color-rgb:222, 226, 230;--bs-secondary-bg:#343a40;--bs-secondary-bg-rgb:52, 58, 64;--bs-tertiary-color:rgba(222, 226, 230, 0.5);--bs-tertiary-color-rgb:222, 226, 230;--bs-tertiary-bg:#2b3035;--bs-tertiary-bg-rgb:43, 48, 53;--bs-primary-text-emphasis:#6ea8fe;--bs-secondary-text-emphasis:#a7acb1;--bs-success-text-emphasis:#75b798;--bs-info-text-emphasis:#6edff6;--bs-warning-text-emphasis:#ffda6a;--bs-danger-text-emphasis:#ea868f;--bs-light-text-emphasis:#f8f9fa;--bs-dark-text-emphasis:#dee2e6;--bs-primary-bg-subtle:#031633;--bs-secondary-bg-subtle:#161719;--bs-success-bg-subtle:#051b11;--bs-info-bg-subtle:#032830;--bs-warning-bg-subtle:#332701;--bs-danger-bg-subtle:#2c0b0e;--bs-light-bg-subtle:#343a40;--bs-dark-bg-subtle:#1a1d20;--bs-primary-border-subtle:#084298;--bs-secondary-border-subtle:#41464b;--bs-success-border-subtle:#0f5132;--bs-info-border-subtle:#087990;--bs-warning-border-subtle:#997404;--bs-danger-border-subtle:#842029;--bs-light-border-subtle:#495057;--bs-dark-border-subtle:#343a40;--bs-heading-color:inherit;--bs-link-color:#6ea8fe;--bs-link-hover-color:#8bb9fe;--bs-link-color-rgb:110, 168, 254;--bs-link-hover-color-rgb:139, 185, 254;--bs-code-color:#e685b5;--bs-highlight-color:#dee2e6;--bs-highlight-bg:#664d03;--bs-border-color:#495057;--bs-border-color-translucent:rgba(255, 255, 255, 0.15);--bs-form-valid-color:#75b798;--bs-form-valid-border-color:#75b798;--bs-form-invalid-color:#ea868f;--bs-form-invalid-border-color:#ea868f}.spinner-grow,.spinner-border{display:inline-block;width:var(--bs-spinner-width);height:var(--bs-spinner-height);vertical-align:var(--bs-spinner-vertical-align);border-radius:50%;animation:var(--bs-spinner-animation-speed) linear infinite var(--bs-spinner-animation-name)}@keyframes spinner-border{to{transform:rotate(360deg) }}.spinner-border{--bs-spinner-width:2rem;--bs-spinner-height:2rem;--bs-spinner-vertical-align:-0.125em;--bs-spinner-border-width:0.25em;--bs-spinner-animation-speed:0.75s;--bs-spinner-animation-name:spinner-border;border:var(--bs-spinner-border-width) solid currentcolor;border-right-color:transparent}.spinner-border-sm{--bs-spinner-width:1rem;--bs-spinner-height:1rem;--bs-spinner-border-width:0.2em}@keyframes spinner-grow{0%{transform:scale(0)}50%{opacity:1;transform:none}}.spinner-grow{--bs-spinner-width:2rem;--bs-spinner-height:2rem;--bs-spinner-vertical-align:-0.125em;--bs-spinner-animation-speed:0.75s;--bs-spinner-animation-name:spinner-grow;background-color:currentcolor;opacity:0}.spinner-grow-sm{--bs-spinner-width:1rem;--bs-spinner-height:1rem}@media (prefers-reduced-motion: reduce){.spinner-border,.spinner-grow{--bs-spinner-animation-speed:1.5s}}.clearfix::after{display:block;clear:both;content:\"\"}.text-bg-primary{color:#fff !important;background-color:RGBA(var(--bs-primary-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-secondary{color:#fff !important;background-color:RGBA(var(--bs-secondary-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-success{color:#fff !important;background-color:RGBA(var(--bs-success-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-info{color:#000 !important;background-color:RGBA(var(--bs-info-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-warning{color:#000 !important;background-color:RGBA(var(--bs-warning-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-danger{color:#fff !important;background-color:RGBA(var(--bs-danger-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-light{color:#000 !important;background-color:RGBA(var(--bs-light-rgb), var(--bs-bg-opacity, 1)) !important}.text-bg-dark{color:#fff !important;background-color:RGBA(var(--bs-dark-rgb), var(--bs-bg-opacity, 1)) !important}.link-primary{color:RGBA(var(--bs-primary-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-primary-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-primary:hover,.link-primary:focus{color:RGBA(10, 88, 202, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(10, 88, 202, var(--bs-link-underline-opacity, 1)) !important}.link-secondary{color:RGBA(var(--bs-secondary-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-secondary-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-secondary:hover,.link-secondary:focus{color:RGBA(86, 94, 100, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(86, 94, 100, var(--bs-link-underline-opacity, 1)) !important}.link-success{color:RGBA(var(--bs-success-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-success-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-success:hover,.link-success:focus{color:RGBA(20, 108, 67, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(20, 108, 67, var(--bs-link-underline-opacity, 1)) !important}.link-info{color:RGBA(var(--bs-info-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-info-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-info:hover,.link-info:focus{color:RGBA(61, 213, 243, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(61, 213, 243, var(--bs-link-underline-opacity, 1)) !important}.link-warning{color:RGBA(var(--bs-warning-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-warning-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-warning:hover,.link-warning:focus{color:RGBA(255, 205, 57, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(255, 205, 57, var(--bs-link-underline-opacity, 1)) !important}.link-danger{color:RGBA(var(--bs-danger-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-danger-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-danger:hover,.link-danger:focus{color:RGBA(176, 42, 55, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(176, 42, 55, var(--bs-link-underline-opacity, 1)) !important}.link-light{color:RGBA(var(--bs-light-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-light-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-light:hover,.link-light:focus{color:RGBA(249, 250, 251, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(249, 250, 251, var(--bs-link-underline-opacity, 1)) !important}.link-dark{color:RGBA(var(--bs-dark-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-dark-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-dark:hover,.link-dark:focus{color:RGBA(26, 30, 33, var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(26, 30, 33, var(--bs-link-underline-opacity, 1)) !important}.link-body-emphasis{color:RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-opacity, 1)) !important;text-decoration-color:RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-underline-opacity, 1)) !important}.link-body-emphasis:hover,.link-body-emphasis:focus{color:RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-opacity, 0.75)) !important;text-decoration-color:RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-underline-opacity, 0.75)) !important}.focus-ring:focus{outline:0;box-shadow:var(--bs-focus-ring-x, 0) var(--bs-focus-ring-y, 0) var(--bs-focus-ring-blur, 0) var(--bs-focus-ring-width) var(--bs-focus-ring-color)}.icon-link{display:inline-flex;gap:0.375rem;align-items:center;text-decoration-color:rgba(var(--bs-link-color-rgb), var(--bs-link-opacity, 0.5));text-underline-offset:0.25em;backface-visibility:hidden}.icon-link>.bi{flex-shrink:0;width:1em;height:1em;fill:currentcolor;transition:0.2s ease-in-out transform}@media (prefers-reduced-motion: reduce){.icon-link>.bi{transition:none}}.icon-link-hover:hover>.bi,.icon-link-hover:focus-visible>.bi{transform:var(--bs-icon-link-transform, translate3d(0.25em, 0, 0))}.ratio{position:relative;width:100%}.ratio::before{display:block;padding-top:var(--bs-aspect-ratio);content:\"\"}.ratio>*{position:absolute;top:0;left:0;width:100%;height:100%}.ratio-1x1{--bs-aspect-ratio:100%}.ratio-4x3{--bs-aspect-ratio:75%}.ratio-16x9{--bs-aspect-ratio:56.25%}.ratio-21x9{--bs-aspect-ratio:42.8571428571%}.fixed-top{position:fixed;top:0;right:0;left:0;z-index:1030}.fixed-bottom{position:fixed;right:0;bottom:0;left:0;z-index:1030}.sticky-top{position:sticky;top:0;z-index:1020}.sticky-bottom{position:sticky;bottom:0;z-index:1020}@media (min-width: 576px){.sticky-sm-top{position:sticky;top:0;z-index:1020}.sticky-sm-bottom{position:sticky;bottom:0;z-index:1020}}@media (min-width: 768px){.sticky-md-top{position:sticky;top:0;z-index:1020}.sticky-md-bottom{position:sticky;bottom:0;z-index:1020}}@media (min-width: 992px){.sticky-lg-top{position:sticky;top:0;z-index:1020}.sticky-lg-bottom{position:sticky;bottom:0;z-index:1020}}@media (min-width: 1200px){.sticky-xl-top{position:sticky;top:0;z-index:1020}.sticky-xl-bottom{position:sticky;bottom:0;z-index:1020}}@media (min-width: 1400px){.sticky-xxl-top{position:sticky;top:0;z-index:1020}.sticky-xxl-bottom{position:sticky;bottom:0;z-index:1020}}.hstack{display:flex;flex-direction:row;align-items:center;align-self:stretch}.vstack{display:flex;flex:1 1 auto;flex-direction:column;align-self:stretch}.visually-hidden,.visually-hidden-focusable:not(:focus):not(:focus-within){width:1px !important;height:1px !important;padding:0 !important;margin:-1px !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;white-space:nowrap !important;border:0 !important}.visually-hidden:not(caption),.visually-hidden-focusable:not(:focus):not(:focus-within):not(caption){position:absolute !important}.stretched-link::after{position:absolute;top:0;right:0;bottom:0;left:0;z-index:1;content:\"\"}.text-truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.vr{display:inline-block;align-self:stretch;width:var(--bs-border-width);min-height:1em;background-color:currentcolor;opacity:0.25}*,*::before,*::after{box-sizing:border-box}@media (prefers-reduced-motion: no-preference){:root{scroll-behavior:smooth}}body{margin:0;font-family:var(--bs-body-font-family);font-size:var(--bs-body-font-size);font-weight:var(--bs-body-font-weight);line-height:var(--bs-body-line-height);color:var(--bs-body-color);text-align:var(--bs-body-text-align);background-color:var(--bs-body-bg);-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:rgba(0, 0, 0, 0)}hr{margin:1rem 0;color:inherit;border:0;border-top:var(--bs-border-width) solid;opacity:0.25}h6,h5,h4,h3,h2,h1{margin-top:0;margin-bottom:0.5rem;font-weight:500;line-height:1.2;color:var(--bs-heading-color)}h1{font-size:calc(1.375rem + 1.5vw)}@media (min-width: 1200px){h1{font-size:2.5rem}}h2{font-size:calc(1.325rem + 0.9vw)}@media (min-width: 1200px){h2{font-size:2rem}}h3{font-size:calc(1.3rem + 0.6vw)}@media (min-width: 1200px){h3{font-size:1.75rem}}h4{font-size:calc(1.275rem + 0.3vw)}@media (min-width: 1200px){h4{font-size:1.5rem}}h5{font-size:1.25rem}h6{font-size:1rem}p{margin-top:0;margin-bottom:1rem}abbr[title]{text-decoration:underline dotted;cursor:help;text-decoration-skip-ink:none}address{margin-bottom:1rem;font-style:normal;line-height:inherit}ol,ul{padding-left:2rem}ol,ul,dl{margin-top:0;margin-bottom:1rem}ol ol,ul ul,ol ul,ul ol{margin-bottom:0}dt{font-weight:700}dd{margin-bottom:0.5rem;margin-left:0}blockquote{margin:0 0 1rem}b,strong{font-weight:bolder}small{font-size:0.875em}mark{padding:0.1875em;color:var(--bs-highlight-color);background-color:var(--bs-highlight-bg)}sub,sup{position:relative;font-size:0.75em;line-height:0;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}a{color:rgba(var(--bs-link-color-rgb), var(--bs-link-opacity, 1));text-decoration:underline}a:hover{--bs-link-color-rgb:var(--bs-link-hover-color-rgb)}a:not([href]):not([class]),a:not([href]):not([class]):hover{color:inherit;text-decoration:none}pre,code,kbd,samp{font-family:var(--bs-font-monospace);font-size:1em}pre{display:block;margin-top:0;margin-bottom:1rem;overflow:auto;font-size:0.875em}pre code{font-size:inherit;color:inherit;word-break:normal}code{font-size:0.875em;color:var(--bs-code-color);word-wrap:break-word}a>code{color:inherit}kbd{padding:0.1875rem 0.375rem;font-size:0.875em;color:var(--bs-body-bg);background-color:var(--bs-body-color);border-radius:0.25rem}kbd kbd{padding:0;font-size:1em}figure{margin:0 0 1rem}img,svg{vertical-align:middle}table{caption-side:bottom;border-collapse:collapse}caption{padding-top:0.5rem;padding-bottom:0.5rem;color:var(--bs-secondary-color);text-align:left}th{text-align:inherit;text-align:-webkit-match-parent}thead,tbody,tfoot,tr,td,th{border-color:inherit;border-style:solid;border-width:0}label{display:inline-block}button{border-radius:0}button:focus:not(:focus-visible){outline:0}input,button,select,optgroup,textarea{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}button,select{text-transform:none}[role=button]{cursor:pointer}select{word-wrap:normal}select:disabled{opacity:1}[list]:not([type=date]):not([type=datetime-local]):not([type=month]):not([type=week]):not([type=time])::-webkit-calendar-picker-indicator{display:none !important}button,[type=button],[type=reset],[type=submit]{-webkit-appearance:button}button:not(:disabled),[type=button]:not(:disabled),[type=reset]:not(:disabled),[type=submit]:not(:disabled){cursor:pointer}::-moz-focus-inner{padding:0;border-style:none}textarea{resize:vertical}fieldset{min-width:0;padding:0;margin:0;border:0}legend{float:left;width:100%;padding:0;margin-bottom:0.5rem;font-size:calc(1.275rem + 0.3vw);line-height:inherit}@media (min-width: 1200px){legend{font-size:1.5rem}}legend+*{clear:left}::-webkit-datetime-edit-fields-wrapper,::-webkit-datetime-edit-text,::-webkit-datetime-edit-minute,::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-year-field{padding:0}::-webkit-inner-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-color-swatch-wrapper{padding:0}::file-selector-button{font:inherit;-webkit-appearance:button}output{display:inline-block}iframe{border:0}summary{display:list-item;cursor:pointer}progress{vertical-align:baseline}[hidden]{display:none !important}.form-label{margin-bottom:0.5rem}.col-form-label{padding-top:calc(0.375rem + var(--bs-border-width));padding-bottom:calc(0.375rem + var(--bs-border-width));margin-bottom:0;font-size:inherit;line-height:1.5}.col-form-label-lg{padding-top:calc(0.5rem + var(--bs-border-width));padding-bottom:calc(0.5rem + var(--bs-border-width));font-size:1.25rem}.col-form-label-sm{padding-top:calc(0.25rem + var(--bs-border-width));padding-bottom:calc(0.25rem + var(--bs-border-width));font-size:0.875rem}.form-text{margin-top:0.25rem;font-size:0.875em;color:var(--bs-secondary-color)}.form-control{display:block;width:100%;padding:0.375rem 0.75rem;font-size:1rem;font-weight:400;line-height:1.5;color:var(--bs-body-color);appearance:none;background-color:var(--bs-body-bg);background-clip:padding-box;border:var(--bs-border-width) solid var(--bs-border-color);border-radius:var(--bs-border-radius);transition:border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out}@media (prefers-reduced-motion: reduce){.form-control{transition:none}}.form-control[type=file]{overflow:hidden}.form-control[type=file]:not(:disabled):not([readonly]){cursor:pointer}.form-control:focus{color:var(--bs-body-color);background-color:var(--bs-body-bg);border-color:#86b7fe;outline:0;box-shadow:0 0 0 0.25rem rgba(13, 110, 253, 0.25)}.form-control::-webkit-date-and-time-value{min-width:85px;height:1.5em;margin:0}.form-control::-webkit-datetime-edit{display:block;padding:0}.form-control::placeholder{color:var(--bs-secondary-color);opacity:1}.form-control:disabled{background-color:var(--bs-secondary-bg);opacity:1}.form-control::file-selector-button{padding:0.375rem 0.75rem;margin:-0.375rem -0.75rem;margin-inline-end:0.75rem;color:var(--bs-body-color);background-color:var(--bs-tertiary-bg);pointer-events:none;border-color:inherit;border-style:solid;border-width:0;border-inline-end-width:var(--bs-border-width);border-radius:0;transition:color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out}@media (prefers-reduced-motion: reduce){.form-control::file-selector-button{transition:none}}.form-control:hover:not(:disabled):not([readonly])::file-selector-button{background-color:var(--bs-secondary-bg)}.form-control-plaintext{display:block;width:100%;padding:0.375rem 0;margin-bottom:0;line-height:1.5;color:var(--bs-body-color);background-color:transparent;border:solid transparent;border-width:var(--bs-border-width) 0}.form-control-plaintext:focus{outline:0}.form-control-plaintext.form-control-sm,.form-control-plaintext.form-control-lg{padding-right:0;padding-left:0}.form-control-sm{min-height:calc(1.5em + 0.5rem + calc(var(--bs-border-width) * 2));padding:0.25rem 0.5rem;font-size:0.875rem;border-radius:var(--bs-border-radius-sm)}.form-control-sm::file-selector-button{padding:0.25rem 0.5rem;margin:-0.25rem -0.5rem;margin-inline-end:0.5rem}.form-control-lg{min-height:calc(1.5em + 1rem + calc(var(--bs-border-width) * 2));padding:0.5rem 1rem;font-size:1.25rem;border-radius:var(--bs-border-radius-lg)}.form-control-lg::file-selector-button{padding:0.5rem 1rem;margin:-0.5rem -1rem;margin-inline-end:1rem}textarea.form-control{min-height:calc(1.5em + 0.75rem + calc(var(--bs-border-width) * 2))}textarea.form-control-sm{min-height:calc(1.5em + 0.5rem + calc(var(--bs-border-width) * 2))}textarea.form-control-lg{min-height:calc(1.5em + 1rem + calc(var(--bs-border-width) * 2))}.form-control-color{width:3rem;height:calc(1.5em + 0.75rem + calc(var(--bs-border-width) * 2));padding:0.375rem}.form-control-color:not(:disabled):not([readonly]){cursor:pointer}.form-control-color::-moz-color-swatch{border:0 !important;border-radius:var(--bs-border-radius)}.form-control-color::-webkit-color-swatch{border:0 !important;border-radius:var(--bs-border-radius)}.form-control-color.form-control-sm{height:calc(1.5em + 0.5rem + calc(var(--bs-border-width) * 2))}.form-control-color.form-control-lg{height:calc(1.5em + 1rem + calc(var(--bs-border-width) * 2))}.form-select{--bs-form-select-bg-img:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e\");display:block;width:100%;padding:0.375rem 2.25rem 0.375rem 0.75rem;font-size:1rem;font-weight:400;line-height:1.5;color:var(--bs-body-color);appearance:none;background-color:var(--bs-body-bg);background-image:var(--bs-form-select-bg-img), var(--bs-form-select-bg-icon, none);background-repeat:no-repeat;background-position:right 0.75rem center;background-size:16px 12px;border:var(--bs-border-width) solid var(--bs-border-color);border-radius:var(--bs-border-radius);transition:border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out}@media (prefers-reduced-motion: reduce){.form-select{transition:none}}.form-select:focus{border-color:#86b7fe;outline:0;box-shadow:0 0 0 0.25rem rgba(13, 110, 253, 0.25)}.form-select[multiple],.form-select[size]:not([size=\"1\"]){padding-right:0.75rem;background-image:none}.form-select:disabled{background-color:var(--bs-secondary-bg)}.form-select:-moz-focusring{color:transparent;text-shadow:0 0 0 var(--bs-body-color)}.form-select-sm{padding-top:0.25rem;padding-bottom:0.25rem;padding-left:0.5rem;font-size:0.875rem;border-radius:var(--bs-border-radius-sm)}.form-select-lg{padding-top:0.5rem;padding-bottom:0.5rem;padding-left:1rem;font-size:1.25rem;border-radius:var(--bs-border-radius-lg)}[data-bs-theme=dark] .form-select{--bs-form-select-bg-img:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23dee2e6' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e\")}.form-check{display:block;min-height:1.5rem;padding-left:1.5em;margin-bottom:0.125rem}.form-check .form-check-input{float:left;margin-left:-1.5em}.form-check-reverse{padding-right:1.5em;padding-left:0;text-align:right}.form-check-reverse .form-check-input{float:right;margin-right:-1.5em;margin-left:0}.form-check-input{--bs-form-check-bg:var(--bs-body-bg);flex-shrink:0;width:1em;height:1em;margin-top:0.25em;vertical-align:top;appearance:none;background-color:var(--bs-form-check-bg);background-image:var(--bs-form-check-bg-image);background-repeat:no-repeat;background-position:center;background-size:contain;border:var(--bs-border-width) solid var(--bs-border-color);print-color-adjust:exact}.form-check-input[type=checkbox]{border-radius:0.25em}.form-check-input[type=radio]{border-radius:50%}.form-check-input:active{filter:brightness(90%)}.form-check-input:focus{border-color:#86b7fe;outline:0;box-shadow:0 0 0 0.25rem rgba(13, 110, 253, 0.25)}.form-check-input:checked{background-color:#0d6efd;border-color:#0d6efd}.form-check-input:checked[type=checkbox]{--bs-form-check-bg-image:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='m6 10 3 3 6-6'/%3e%3c/svg%3e\")}.form-check-input:checked[type=radio]{--bs-form-check-bg-image:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='2' fill='%23fff'/%3e%3c/svg%3e\")}.form-check-input[type=checkbox]:indeterminate{background-color:#0d6efd;border-color:#0d6efd;--bs-form-check-bg-image:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='M6 10h8'/%3e%3c/svg%3e\")}.form-check-input:disabled{pointer-events:none;filter:none;opacity:0.5}.form-check-input[disabled]~.form-check-label,.form-check-input:disabled~.form-check-label{cursor:default;opacity:0.5}.form-switch{padding-left:2.5em}.form-switch .form-check-input{--bs-form-switch-bg:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='rgba%280, 0, 0, 0.25%29'/%3e%3c/svg%3e\");width:2em;margin-left:-2.5em;background-image:var(--bs-form-switch-bg);background-position:left center;border-radius:2em;transition:background-position 0.15s ease-in-out}@media (prefers-reduced-motion: reduce){.form-switch .form-check-input{transition:none}}.form-switch .form-check-input:focus{--bs-form-switch-bg:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%2386b7fe'/%3e%3c/svg%3e\")}.form-switch .form-check-input:checked{background-position:right center;--bs-form-switch-bg:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23fff'/%3e%3c/svg%3e\")}.form-switch.form-check-reverse{padding-right:2.5em;padding-left:0}.form-switch.form-check-reverse .form-check-input{margin-right:-2.5em;margin-left:0}.form-check-inline{display:inline-block;margin-right:1rem}.btn-check{position:absolute;clip:rect(0, 0, 0, 0);pointer-events:none}.btn-check[disabled]+.btn,.btn-check:disabled+.btn{pointer-events:none;filter:none;opacity:0.65}[data-bs-theme=dark] .form-switch .form-check-input:not(:checked):not(:focus){--bs-form-switch-bg:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='rgba%28255, 255, 255, 0.25%29'/%3e%3c/svg%3e\")}.form-range{width:100%;height:1.5rem;padding:0;appearance:none;background-color:transparent}.form-range:focus{outline:0}.form-range:focus::-webkit-slider-thumb{box-shadow:0 0 0 1px #fff, 0 0 0 0.25rem rgba(13, 110, 253, 0.25)}.form-range:focus::-moz-range-thumb{box-shadow:0 0 0 1px #fff, 0 0 0 0.25rem rgba(13, 110, 253, 0.25)}.form-range::-moz-focus-outer{border:0}.form-range::-webkit-slider-thumb{width:1rem;height:1rem;margin-top:-0.25rem;appearance:none;background-color:#0d6efd;border:0;border-radius:1rem;transition:background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out}@media (prefers-reduced-motion: reduce){.form-range::-webkit-slider-thumb{transition:none}}.form-range::-webkit-slider-thumb:active{background-color:#b6d4fe}.form-range::-webkit-slider-runnable-track{width:100%;height:0.5rem;color:transparent;cursor:pointer;background-color:var(--bs-secondary-bg);border-color:transparent;border-radius:1rem}.form-range::-moz-range-thumb{width:1rem;height:1rem;appearance:none;background-color:#0d6efd;border:0;border-radius:1rem;transition:background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out}@media (prefers-reduced-motion: reduce){.form-range::-moz-range-thumb{transition:none}}.form-range::-moz-range-thumb:active{background-color:#b6d4fe}.form-range::-moz-range-track{width:100%;height:0.5rem;color:transparent;cursor:pointer;background-color:var(--bs-secondary-bg);border-color:transparent;border-radius:1rem}.form-range:disabled{pointer-events:none}.form-range:disabled::-webkit-slider-thumb{background-color:var(--bs-secondary-color)}.form-range:disabled::-moz-range-thumb{background-color:var(--bs-secondary-color)}.form-floating{position:relative}.form-floating>.form-control,.form-floating>.form-control-plaintext,.form-floating>.form-select{height:calc(3.5rem + calc(var(--bs-border-width) * 2));min-height:calc(3.5rem + calc(var(--bs-border-width) * 2));line-height:1.25}.form-floating>label{position:absolute;top:0;left:0;z-index:2;height:100%;padding:1rem 0.75rem;overflow:hidden;text-align:start;text-overflow:ellipsis;white-space:nowrap;pointer-events:none;border:var(--bs-border-width) solid transparent;transform-origin:0 0;transition:opacity 0.1s ease-in-out, transform 0.1s ease-in-out}@media (prefers-reduced-motion: reduce){.form-floating>label{transition:none}}.form-floating>.form-control,.form-floating>.form-control-plaintext{padding:1rem 0.75rem}.form-floating>.form-control::placeholder,.form-floating>.form-control-plaintext::placeholder{color:transparent}.form-floating>.form-control:focus,.form-floating>.form-control:not(:placeholder-shown),.form-floating>.form-control-plaintext:focus,.form-floating>.form-control-plaintext:not(:placeholder-shown){padding-top:1.625rem;padding-bottom:0.625rem}.form-floating>.form-control:-webkit-autofill,.form-floating>.form-control-plaintext:-webkit-autofill{padding-top:1.625rem;padding-bottom:0.625rem}.form-floating>.form-select{padding-top:1.625rem;padding-bottom:0.625rem}.form-floating>.form-control:focus~label,.form-floating>.form-control:not(:placeholder-shown)~label,.form-floating>.form-control-plaintext~label,.form-floating>.form-select~label{color:rgba(var(--bs-body-color-rgb), 0.65);transform:scale(0.85) translateY(-0.5rem) translateX(0.15rem)}.form-floating>.form-control:focus~label::after,.form-floating>.form-control:not(:placeholder-shown)~label::after,.form-floating>.form-control-plaintext~label::after,.form-floating>.form-select~label::after{position:absolute;inset:1rem 0.375rem;z-index:-1;height:1.5em;content:\"\";background-color:var(--bs-body-bg);border-radius:var(--bs-border-radius)}.form-floating>.form-control:-webkit-autofill~label{color:rgba(var(--bs-body-color-rgb), 0.65);transform:scale(0.85) translateY(-0.5rem) translateX(0.15rem)}.form-floating>.form-control-plaintext~label{border-width:var(--bs-border-width) 0}.form-floating>:disabled~label,.form-floating>.form-control:disabled~label{color:#6c757d}.form-floating>:disabled~label::after,.form-floating>.form-control:disabled~label::after{background-color:var(--bs-secondary-bg)}.input-group{position:relative;display:flex;flex-wrap:wrap;align-items:stretch;width:100%}.input-group>.form-control,.input-group>.form-select,.input-group>.form-floating{position:relative;flex:1 1 auto;width:1%;min-width:0}.input-group>.form-control:focus,.input-group>.form-select:focus,.input-group>.form-floating:focus-within{z-index:5}.input-group .btn{position:relative;z-index:2}.input-group .btn:focus{z-index:5}.input-group-text{display:flex;align-items:center;padding:0.375rem 0.75rem;font-size:1rem;font-weight:400;line-height:1.5;color:var(--bs-body-color);text-align:center;white-space:nowrap;background-color:var(--bs-tertiary-bg);border:var(--bs-border-width) solid var(--bs-border-color);border-radius:var(--bs-border-radius)}.input-group-lg>.form-control,.input-group-lg>.form-select,.input-group-lg>.input-group-text,.input-group-lg>.btn{padding:0.5rem 1rem;font-size:1.25rem;border-radius:var(--bs-border-radius-lg)}.input-group-sm>.form-control,.input-group-sm>.form-select,.input-group-sm>.input-group-text,.input-group-sm>.btn{padding:0.25rem 0.5rem;font-size:0.875rem;border-radius:var(--bs-border-radius-sm)}.input-group-lg>.form-select,.input-group-sm>.form-select{padding-right:3rem}.input-group:not(.has-validation)>:not(:last-child):not(.dropdown-toggle):not(.dropdown-menu):not(.form-floating),.input-group:not(.has-validation)>.dropdown-toggle:nth-last-child(n+3),.input-group:not(.has-validation)>.form-floating:not(:last-child)>.form-control,.input-group:not(.has-validation)>.form-floating:not(:last-child)>.form-select{border-top-right-radius:0;border-bottom-right-radius:0}.input-group.has-validation>:nth-last-child(n+3):not(.dropdown-toggle):not(.dropdown-menu):not(.form-floating),.input-group.has-validation>.dropdown-toggle:nth-last-child(n+4),.input-group.has-validation>.form-floating:nth-last-child(n+3)>.form-control,.input-group.has-validation>.form-floating:nth-last-child(n+3)>.form-select{border-top-right-radius:0;border-bottom-right-radius:0}.input-group>:not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback){margin-left:calc(var(--bs-border-width) * -1);border-top-left-radius:0;border-bottom-left-radius:0}.input-group>.form-floating:not(:first-child)>.form-control,.input-group>.form-floating:not(:first-child)>.form-select{border-top-left-radius:0;border-bottom-left-radius:0}.valid-feedback{display:none;width:100%;margin-top:0.25rem;font-size:0.875em;color:var(--bs-form-valid-color)}.valid-tooltip{position:absolute;top:100%;z-index:5;display:none;max-width:100%;padding:0.25rem 0.5rem;margin-top:0.1rem;font-size:0.875rem;color:#fff;background-color:var(--bs-success);border-radius:var(--bs-border-radius)}.was-validated :valid~.valid-feedback,.was-validated :valid~.valid-tooltip,.is-valid~.valid-feedback,.is-valid~.valid-tooltip{display:block}.was-validated .form-control:valid,.form-control.is-valid{border-color:var(--bs-form-valid-border-color);padding-right:calc(1.5em + 0.75rem);background-image:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%23198754' d='M2.3 6.73.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e\");background-repeat:no-repeat;background-position:right calc(0.375em + 0.1875rem) center;background-size:calc(0.75em + 0.375rem) calc(0.75em + 0.375rem)}.was-validated .form-control:valid:focus,.form-control.is-valid:focus{border-color:var(--bs-form-valid-border-color);box-shadow:0 0 0 0.25rem rgba(var(--bs-success-rgb), 0.25)}.was-validated textarea.form-control:valid,textarea.form-control.is-valid{padding-right:calc(1.5em + 0.75rem);background-position:top calc(0.375em + 0.1875rem) right calc(0.375em + 0.1875rem)}.was-validated .form-select:valid,.form-select.is-valid{border-color:var(--bs-form-valid-border-color)}.was-validated .form-select:valid:not([multiple]):not([size]),.was-validated .form-select:valid:not([multiple])[size=\"1\"],.form-select.is-valid:not([multiple]):not([size]),.form-select.is-valid:not([multiple])[size=\"1\"]{--bs-form-select-bg-icon:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%23198754' d='M2.3 6.73.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e\");padding-right:4.125rem;background-position:right 0.75rem center, center right 2.25rem;background-size:16px 12px, calc(0.75em + 0.375rem) calc(0.75em + 0.375rem)}.was-validated .form-select:valid:focus,.form-select.is-valid:focus{border-color:var(--bs-form-valid-border-color);box-shadow:0 0 0 0.25rem rgba(var(--bs-success-rgb), 0.25)}.was-validated .form-control-color:valid,.form-control-color.is-valid{width:calc(3rem + calc(1.5em + 0.75rem))}.was-validated .form-check-input:valid,.form-check-input.is-valid{border-color:var(--bs-form-valid-border-color)}.was-validated .form-check-input:valid:checked,.form-check-input.is-valid:checked{background-color:var(--bs-form-valid-color)}.was-validated .form-check-input:valid:focus,.form-check-input.is-valid:focus{box-shadow:0 0 0 0.25rem rgba(var(--bs-success-rgb), 0.25)}.was-validated .form-check-input:valid~.form-check-label,.form-check-input.is-valid~.form-check-label{color:var(--bs-form-valid-color)}.form-check-inline .form-check-input~.valid-feedback{margin-left:0.5em}.was-validated .input-group>.form-control:not(:focus):valid,.input-group>.form-control:not(:focus).is-valid,.was-validated .input-group>.form-select:not(:focus):valid,.input-group>.form-select:not(:focus).is-valid,.was-validated .input-group>.form-floating:not(:focus-within):valid,.input-group>.form-floating:not(:focus-within).is-valid{z-index:3}.invalid-feedback{display:none;width:100%;margin-top:0.25rem;font-size:0.875em;color:var(--bs-form-invalid-color)}.invalid-tooltip{position:absolute;top:100%;z-index:5;display:none;max-width:100%;padding:0.25rem 0.5rem;margin-top:0.1rem;font-size:0.875rem;color:#fff;background-color:var(--bs-danger);border-radius:var(--bs-border-radius)}.was-validated :invalid~.invalid-feedback,.was-validated :invalid~.invalid-tooltip,.is-invalid~.invalid-feedback,.is-invalid~.invalid-tooltip{display:block}.was-validated .form-control:invalid,.form-control.is-invalid{border-color:var(--bs-form-invalid-border-color);padding-right:calc(1.5em + 0.75rem);background-image:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e\");background-repeat:no-repeat;background-position:right calc(0.375em + 0.1875rem) center;background-size:calc(0.75em + 0.375rem) calc(0.75em + 0.375rem)}.was-validated .form-control:invalid:focus,.form-control.is-invalid:focus{border-color:var(--bs-form-invalid-border-color);box-shadow:0 0 0 0.25rem rgba(var(--bs-danger-rgb), 0.25)}.was-validated textarea.form-control:invalid,textarea.form-control.is-invalid{padding-right:calc(1.5em + 0.75rem);background-position:top calc(0.375em + 0.1875rem) right calc(0.375em + 0.1875rem)}.was-validated .form-select:invalid,.form-select.is-invalid{border-color:var(--bs-form-invalid-border-color)}.was-validated .form-select:invalid:not([multiple]):not([size]),.was-validated .form-select:invalid:not([multiple])[size=\"1\"],.form-select.is-invalid:not([multiple]):not([size]),.form-select.is-invalid:not([multiple])[size=\"1\"]{--bs-form-select-bg-icon:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e\");padding-right:4.125rem;background-position:right 0.75rem center, center right 2.25rem;background-size:16px 12px, calc(0.75em + 0.375rem) calc(0.75em + 0.375rem)}.was-validated .form-select:invalid:focus,.form-select.is-invalid:focus{border-color:var(--bs-form-invalid-border-color);box-shadow:0 0 0 0.25rem rgba(var(--bs-danger-rgb), 0.25)}.was-validated .form-control-color:invalid,.form-control-color.is-invalid{width:calc(3rem + calc(1.5em + 0.75rem))}.was-validated .form-check-input:invalid,.form-check-input.is-invalid{border-color:var(--bs-form-invalid-border-color)}.was-validated .form-check-input:invalid:checked,.form-check-input.is-invalid:checked{background-color:var(--bs-form-invalid-color)}.was-validated .form-check-input:invalid:focus,.form-check-input.is-invalid:focus{box-shadow:0 0 0 0.25rem rgba(var(--bs-danger-rgb), 0.25)}.was-validated .form-check-input:invalid~.form-check-label,.form-check-input.is-invalid~.form-check-label{color:var(--bs-form-invalid-color)}.form-check-inline .form-check-input~.invalid-feedback{margin-left:0.5em}.was-validated .input-group>.form-control:not(:focus):invalid,.input-group>.form-control:not(:focus).is-invalid,.was-validated .input-group>.form-select:not(:focus):invalid,.input-group>.form-select:not(:focus).is-invalid,.was-validated .input-group>.form-floating:not(:focus-within):invalid,.input-group>.form-floating:not(:focus-within).is-invalid{z-index:4}:host{font-family:system-ui, -apple-system, \"Segoe UI\", Roboto, \"Helvetica Neue\", \"Noto Sans\", \"Liberation Sans\", Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\", \"Noto Color Emoji\";font-size:1rem;font-weight:400;line-height:1.5;color:#212529;display:block}";
8
1823
 
@@ -51,5 +1866,7 @@ const TextInput = class {
51
1866
  };
52
1867
  TextInput.style = textInputCss;
53
1868
 
1869
+ exports.justifi_billing_form = BillingForm;
1870
+ exports.justifi_payment_method_form = PaymentMethodForm;
54
1871
  exports.select_input = SelectInput;
55
1872
  exports.text_input = TextInput;