@justifi/webcomponents 6.1.0-rc.3 → 6.1.1-rc.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (793) hide show
  1. package/dist/cjs/{Api-DqzbA2qk.js → Api-CjtvTD2_.js} +2 -2
  2. package/dist/cjs/{Business-DWHy_-z9.js → Business-DCRzZf0w.js} +9 -299
  3. package/dist/cjs/{Refund-BPSBtjQC.js → Refund-BnhHNKLz.js} +4 -3
  4. package/dist/cjs/additional-questions-details_5.cjs.entry.js +14 -13
  5. package/dist/cjs/{badge-BJVdpSU-.js → badge-CE3ss_OU.js} +2 -2
  6. package/dist/cjs/bank-account-document-form-inputs_4.cjs.entry.js +112 -0
  7. package/dist/cjs/bank-account-form.cjs.entry.js +8 -8
  8. package/dist/cjs/{business-additional-questions-schema-CetDMUp7.js → business-additional-questions-schema-b8P-0T0O.js} +4 -26
  9. package/dist/cjs/business-details-core.cjs.entry.js +5 -5
  10. package/dist/cjs/{business-form-options-e9UFw4P-.js → business-form-options-CMII7nIK.js} +1 -1
  11. package/dist/cjs/business-identity-schema-aFUle0C9.js +51 -0
  12. package/dist/cjs/{business.service-Bv9o99Ll.js → business.service-Cj_NUZsr.js} +3 -3
  13. package/dist/cjs/{button-_YJuE8cy.js → button-gPNZ9XRn.js} +2 -2
  14. package/dist/cjs/card-form.cjs.entry.js +8 -8
  15. package/dist/cjs/{check-pkg-version-CadxBsjl.js → check-pkg-version-iW3HGQFY.js} +4 -4
  16. package/dist/cjs/{checkout.service-dLB93w3Z.js → checkout.service-Bc8L9ixO.js} +3 -3
  17. package/dist/cjs/{checkout.store-DC4yVxDj.js → checkout.store-Bswr7kNY.js} +5 -1
  18. package/dist/cjs/checkouts-list-core.cjs.entry.js +15 -13
  19. package/dist/cjs/{terminal-orders-list-params-state-ARjo40Y9.js → checkouts-list-params-state-BYpq-c6X.js} +1 -1
  20. package/dist/cjs/{checkouts-table-C102WCfy.js → checkouts-table-C5AHeIr0.js} +4 -4
  21. package/dist/cjs/{config-state-BeZM7X7J.js → config-state-C7babhLh.js} +1 -1
  22. package/dist/cjs/{custom-popper.cjs.entry.js → custom-popper_2.cjs.entry.js} +23 -3
  23. package/dist/cjs/{dispute.service-BmAAnNky.js → dispute.service-DhO_tuDc.js} +3 -3
  24. package/dist/cjs/form-alert_5.cjs.entry.js +16 -26
  25. package/dist/cjs/form-control-checkbox.cjs.entry.js +6 -6
  26. package/dist/cjs/form-control-date.cjs.entry.js +5 -5
  27. package/dist/cjs/{form-control-error-text-DJzNQrEz.js → form-control-error-text-BnMWn8U_.js} +2 -2
  28. package/dist/cjs/form-control-file-v2_2.cjs.entry.js +6 -6
  29. package/dist/cjs/{form-control-help-text-DII6UDeq.js → form-control-help-text-DEi5vSjN.js} +2 -2
  30. package/dist/cjs/form-control-help-text.cjs.entry.js +1 -1
  31. package/dist/cjs/form-control-monetary-provisioning.cjs.entry.js +7 -7
  32. package/dist/cjs/form-control-monetary.cjs.entry.js +7 -7
  33. package/dist/cjs/form-control-number-masked_2.cjs.entry.js +107 -0
  34. package/dist/cjs/form-control-number.cjs.entry.js +6 -6
  35. package/dist/cjs/form-control-radio.cjs.entry.js +4 -4
  36. package/dist/cjs/{form-control-select_3.cjs.entry.js → form-control-select_2.cjs.entry.js} +7 -26
  37. package/dist/cjs/{form-input-masks-BnNFJ3IJ.js → form-input-masks-DgXd0f4V.js} +4 -9
  38. package/dist/cjs/{get-business-D9ZHyPem.js → get-business-o5jPq_ME.js} +1 -1
  39. package/dist/cjs/{get-payment-details-BHPHzSkH.js → get-payment-details-BinT-ZEP.js} +3 -3
  40. package/dist/cjs/{get-subaccounts-Bw76aYu0.js → get-subaccounts-BoTVdl7v.js} +4 -4
  41. package/dist/cjs/gross-payment-chart-core.cjs.entry.js +26 -17
  42. package/dist/cjs/{header-1-Da7oKhXY.js → header-1-D3r87SC6.js} +2 -2
  43. package/dist/cjs/{header-3-uBM_CzcP.js → header-3-BFQJJgBb.js} +2 -2
  44. package/dist/cjs/helpers-B5OCqlIM.js +35 -0
  45. package/dist/cjs/hidden-input_2.cjs.entry.js +9 -9
  46. package/dist/cjs/{index-CaAefsWD.js → index-Bhtk1qkX.js} +5 -2
  47. package/dist/cjs/{index-D-CfIyoF.js → index-CWM5ions.js} +1 -1
  48. package/dist/cjs/{input-handlers-D6QMwPTB.js → input-handlers-DYl_0IwC.js} +2 -2
  49. package/dist/cjs/{insurance-state-KJzYGtVr.js → insurance-state-JbqYvJN3.js} +3 -3
  50. package/dist/cjs/justifi-additional-questions-form-step-core_6.cjs.entry.js +72 -129
  51. package/dist/cjs/justifi-additional-questions-form-step_9.cjs.entry.js +26 -25
  52. package/dist/cjs/justifi-additional-statement_8.cjs.entry.js +10 -10
  53. package/dist/cjs/{justifi-checkout-summary_7.cjs.entry.js → justifi-apple-pay_8.cjs.entry.js} +824 -25
  54. package/dist/cjs/justifi-bank-account-billing-form-simple_9.cjs.entry.js +31 -30
  55. package/dist/cjs/justifi-business-details.cjs.entry.js +15 -13
  56. package/dist/cjs/justifi-business-form.cjs.entry.js +23 -27
  57. package/dist/cjs/justifi-business-representative-form-inputs.cjs.entry.js +8 -16
  58. package/dist/cjs/justifi-checkout.cjs.entry.js +16 -14
  59. package/dist/cjs/justifi-checkouts-list-filters.cjs.entry.js +12 -10
  60. package/dist/cjs/justifi-checkouts-list.cjs.entry.js +18 -16
  61. package/dist/cjs/justifi-config-provider.cjs.entry.js +3 -3
  62. package/dist/cjs/justifi-details.cjs.entry.js +3 -3
  63. package/dist/cjs/justifi-dispute-management-core.cjs.entry.js +2 -2
  64. package/dist/cjs/justifi-dispute-management.cjs.entry.js +13 -11
  65. package/dist/cjs/justifi-dispute-notification_3.cjs.entry.js +19 -17
  66. package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +13 -11
  67. package/dist/cjs/justifi-order-terminals.cjs.entry.js +18 -16
  68. package/dist/cjs/justifi-owner-form_3.cjs.entry.js +21 -30
  69. package/dist/cjs/justifi-payment-details.cjs.entry.js +23 -14
  70. package/dist/cjs/justifi-payment-provisioning-core.cjs.entry.js +25 -40
  71. package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +13 -11
  72. package/dist/cjs/justifi-payment-transactions-list.cjs.entry.js +17 -15
  73. package/dist/cjs/justifi-payments-list-filters.cjs.entry.js +8 -8
  74. package/dist/cjs/justifi-payments-list.cjs.entry.js +18 -16
  75. package/dist/cjs/justifi-payout-details.cjs.entry.js +16 -13
  76. package/dist/cjs/justifi-payout-transactions-list.cjs.entry.js +17 -15
  77. package/dist/cjs/justifi-payouts-list-filters.cjs.entry.js +8 -8
  78. package/dist/cjs/justifi-payouts-list.cjs.entry.js +19 -17
  79. package/dist/cjs/justifi-refund-payment.cjs.entry.js +17 -15
  80. package/dist/cjs/justifi-saved-payment-method.cjs.entry.js +3 -3
  81. package/dist/cjs/justifi-season-interruption-insurance.cjs.entry.js +16 -14
  82. package/dist/cjs/justifi-skeleton.cjs.entry.js +5 -5
  83. package/dist/cjs/justifi-terminal-orders-list-filters.cjs.entry.js +13 -11
  84. package/dist/cjs/justifi-terminal-orders-list.cjs.entry.js +16 -14
  85. package/dist/cjs/justifi-terminals-list-filters.cjs.entry.js +14 -11
  86. package/dist/cjs/justifi-terminals-list.cjs.entry.js +18 -16
  87. package/dist/cjs/loader.cjs.js +2 -2
  88. package/dist/cjs/{package-CVxkAS_m.js → package-CwcyK2nz.js} +1 -1
  89. package/dist/cjs/pagination-menu.cjs.entry.js +5 -5
  90. package/dist/cjs/{parts-9jMf1erK.js → parts-Pb06tUMp.js} +2 -0
  91. package/dist/cjs/payment-details-core.cjs.entry.js +34 -16
  92. package/dist/cjs/payment-method-option.cjs.entry.js +4 -4
  93. package/dist/cjs/{payment.service-DODmonNs.js → payment.service-C9thkR4g.js} +3 -3
  94. package/dist/cjs/payments-list-core.cjs.entry.js +16 -14
  95. package/dist/cjs/{payments-list-params-state-ARjo40Y9.js → payments-list-params-state-BYpq-c6X.js} +1 -1
  96. package/dist/cjs/{payments-status-5IzqwLep.js → payments-status-CnNXcRLO.js} +21 -3
  97. package/dist/cjs/{payments-table-BcZ6U6p8.js → payments-table-BGuCOPTJ.js} +4 -4
  98. package/dist/cjs/payout-details-core.cjs.entry.js +25 -12
  99. package/dist/cjs/{payout.service-Do8DxBxe.js → payout.service-CGZxpQMq.js} +3 -3
  100. package/dist/cjs/payouts-list-core.cjs.entry.js +16 -14
  101. package/dist/cjs/{checkouts-list-params-state-ARjo40Y9.js → payouts-list-params-state-BYpq-c6X.js} +1 -1
  102. package/dist/cjs/{payouts-status-D38A6UrI.js → payouts-status-2na6MMgV.js} +2 -2
  103. package/dist/cjs/{payouts-table-Cn_cCCOY.js → payouts-table-DXekpbYc.js} +4 -4
  104. package/dist/cjs/{schema-validations-0mjPveQ0.js → schema-validations-Bj7eYNO8.js} +6 -45
  105. package/dist/cjs/{skeleton-DlPP4i_w.js → skeleton-BvdAh448.js} +2 -2
  106. package/dist/cjs/{spinner-BNWG01hP.js → spinner-Rt52JMa2.js} +2 -2
  107. package/dist/cjs/state-options-CIT9xdTz.js +246 -0
  108. package/dist/cjs/{styled-host-DSpt9LtB.js → styled-host-BSooSIhA.js} +1 -1
  109. package/dist/cjs/{table-CAWBqvW5.js → table-Ccg4k90C.js} +3 -3
  110. package/dist/cjs/table-filters-menu.cjs.entry.js +4 -4
  111. package/dist/cjs/terminal-orders-list-core.cjs.entry.js +15 -13
  112. package/dist/cjs/{payouts-list-params-state-ARjo40Y9.js → terminal-orders-list-params-state-BYpq-c6X.js} +1 -1
  113. package/dist/cjs/{terminal-orders-table-BUA4LcEc.js → terminal-orders-table-7ew1vCKk.js} +7 -7
  114. package/dist/cjs/terminal-quantity-selector.cjs.entry.js +3 -3
  115. package/dist/cjs/{terminal.service-bxQnc1JY.js → terminal.service-BkKxH-k4.js} +3 -3
  116. package/dist/cjs/terminals-list-core.cjs.entry.js +15 -13
  117. package/dist/cjs/terminals-list-params-state-BYpq-c6X.js +22 -0
  118. package/dist/cjs/{terminals-table-C2_M7SWl.js → terminals-table-ByYs-pH7.js} +9 -4
  119. package/dist/cjs/{utils-ChCUZgUy.js → utils-Bab-tddY.js} +4 -0
  120. package/dist/cjs/{utils-C6mfHWv-.js → utils-CUcA4G_O.js} +5 -5
  121. package/dist/cjs/webcomponents.cjs.js +3 -3
  122. package/dist/collection/api/BankAccount.js +0 -4
  123. package/dist/collection/api/Business.js +1 -16
  124. package/dist/collection/api/Terminal.js +1 -0
  125. package/dist/collection/api/services/apple-pay.service.js +5 -42
  126. package/dist/collection/collection-manifest.json +2 -5
  127. package/dist/collection/components/business-details/additional-questions-details/additional-questions-details.js +1 -1
  128. package/dist/collection/components/business-details/owner-details/owner-details.js +9 -8
  129. package/dist/collection/components/business-details/representative-details/representative-details.js +1 -1
  130. package/dist/collection/components/business-forms/business-form/business-core-info/business-core-info.js +4 -36
  131. package/dist/collection/components/business-forms/business-form/business-form.js +2 -6
  132. package/dist/collection/components/business-forms/business-form/business-representative/business-representative.js +5 -41
  133. package/dist/collection/components/business-forms/business-form/legal-address-form/legal-address-form.js +6 -27
  134. package/dist/collection/components/business-forms/owner-form/identity-address/identity-address-form.js +6 -26
  135. package/dist/collection/components/business-forms/owner-form/owner-form-core.js +3 -29
  136. package/dist/collection/components/business-forms/owner-form/owner-form-inputs.js +2 -43
  137. package/dist/collection/components/business-forms/owner-form/owner-form.js +1 -26
  138. package/dist/collection/components/business-forms/payment-provisioning/additional-questions/business-additional-questions-form-step.js +1 -1
  139. package/dist/collection/components/business-forms/payment-provisioning/bank-account/bank-account-document-inputs.js +1 -1
  140. package/dist/collection/components/business-forms/payment-provisioning/bank-account/bank-account-form-inputs.js +1 -2
  141. package/dist/collection/components/business-forms/payment-provisioning/bank-account/business-bank-account-form-step-core.js +5 -36
  142. package/dist/collection/components/business-forms/payment-provisioning/bank-account/business-bank-account-form-step.js +1 -26
  143. package/dist/collection/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step-core.js +7 -47
  144. package/dist/collection/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step.js +1 -26
  145. package/dist/collection/components/business-forms/payment-provisioning/business-owners/business-owners-form-step-core.js +1 -26
  146. package/dist/collection/components/business-forms/payment-provisioning/business-owners/business-owners-form-step.js +1 -26
  147. package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-inputs.js +4 -43
  148. package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-step-core.js +4 -33
  149. package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-step.js +1 -26
  150. package/dist/collection/components/business-forms/payment-provisioning/form-control-monetary-provisioning.js +2 -2
  151. package/dist/collection/components/business-forms/payment-provisioning/legal-address-form/legal-address-form-step-core.js +10 -35
  152. package/dist/collection/components/business-forms/payment-provisioning/legal-address-form/legal-address-form-step.js +1 -26
  153. package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning-core.js +20 -39
  154. package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning-form-buttons.js +1 -1
  155. package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning-form-steps.js +6 -34
  156. package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning.js +1 -1
  157. package/dist/collection/components/business-forms/payment-provisioning/terms-and-conditions/business-terms-conditions-form-step.js +1 -1
  158. package/dist/collection/components/business-forms/schemas/business-address-schema.js +19 -41
  159. package/dist/collection/components/business-forms/schemas/business-bank-account-schema.js +39 -74
  160. package/dist/collection/components/business-forms/schemas/business-core-info-schema.js +4 -27
  161. package/dist/collection/components/business-forms/schemas/business-form-schema.js +4 -7
  162. package/dist/collection/components/business-forms/schemas/business-identity-schema.js +24 -53
  163. package/dist/collection/components/business-forms/schemas/schema-validations.js +4 -41
  164. package/dist/collection/components/checkout/bank-account-form/bank-account-form.js +2 -2
  165. package/dist/collection/components/checkout/billing-form/billing-form.js +3 -2
  166. package/dist/collection/components/checkout/card-form/card-form.js +2 -2
  167. package/dist/collection/components/checkout/checkout.js +2 -2
  168. package/dist/collection/components/checkout/save-new-payment-method.js +1 -1
  169. package/dist/collection/components/checkout/saved-payment-method.js +1 -1
  170. package/dist/collection/components/checkouts-list/checkouts-list-core.js +1 -1
  171. package/dist/collection/components/checkouts-list/checkouts-list-filters.js +1 -1
  172. package/dist/collection/components/checkouts-list/checkouts-list.js +1 -1
  173. package/dist/collection/components/dispute-management/dispute-management-core.js +1 -1
  174. package/dist/collection/components/dispute-management/dispute-management.js +1 -1
  175. package/dist/collection/components/dispute-management/dispute-notification.js +1 -1
  176. package/dist/collection/components/dispute-management/dispute-response/additional-statement.js +1 -1
  177. package/dist/collection/components/dispute-management/dispute-response/cancellation-policy.js +1 -1
  178. package/dist/collection/components/dispute-management/dispute-response/customer-details.js +1 -1
  179. package/dist/collection/components/dispute-management/dispute-response/dispute-response-core.js +1 -1
  180. package/dist/collection/components/dispute-management/dispute-response/dispute-response.js +1 -1
  181. package/dist/collection/components/dispute-management/dispute-response/duplicate-charge.js +1 -1
  182. package/dist/collection/components/dispute-management/dispute-response/electronic-evidence.js +1 -1
  183. package/dist/collection/components/dispute-management/dispute-response/product-or-service.js +1 -1
  184. package/dist/collection/components/dispute-management/dispute-response/refund-policy.js +1 -1
  185. package/dist/collection/components/dispute-management/dispute-response/shipping-details.js +1 -1
  186. package/dist/collection/components/filters/table-filters-menu.js +1 -1
  187. package/dist/collection/components/gross-payment-chart/gross-payment-chart-core.js +1 -1
  188. package/dist/collection/components/modular-checkout/modular-checkout.js +7 -6
  189. package/dist/collection/components/modular-checkout/sub-components/apple-pay.js +48 -35
  190. package/dist/collection/components/modular-checkout/sub-components/bank-account-billing-form-simple.js +1 -1
  191. package/dist/collection/components/modular-checkout/sub-components/bank-account.js +2 -2
  192. package/dist/collection/components/modular-checkout/sub-components/card-billing-form-simple.js +1 -1
  193. package/dist/collection/components/modular-checkout/sub-components/card-form.js +2 -2
  194. package/dist/collection/components/modular-checkout/sub-components/payment-method-option.js +1 -1
  195. package/dist/collection/components/modular-checkout/sub-components/summary.js +1 -1
  196. package/dist/collection/components/order-terminals/order-terminals.js +1 -1
  197. package/dist/collection/components/order-terminals/terminal-quantity-selector/terminal-quantity-selector.js +1 -1
  198. package/dist/collection/components/payment-details/payment-details-core.js +19 -9
  199. package/dist/collection/components/payment-details/payment-details.js +28 -1
  200. package/dist/collection/components/payment-transactions-list/payment-transactions-list.js +1 -1
  201. package/dist/collection/components/payments-list/payments-list-core.js +1 -1
  202. package/dist/collection/components/payments-list/payments-list-filters.js +2 -2
  203. package/dist/collection/components/payments-list/payments-list.js +1 -1
  204. package/dist/collection/components/payments-list/payments-status.js +19 -1
  205. package/dist/collection/components/payout-details/payout-details-core.js +57 -4
  206. package/dist/collection/components/payout-details/payout-details.js +22 -1
  207. package/dist/collection/components/payout-transactions-list/payout-transactions-list.js +1 -1
  208. package/dist/collection/components/payouts-list/payouts-list-core.js +1 -1
  209. package/dist/collection/components/payouts-list/payouts-list-filters.js +2 -2
  210. package/dist/collection/components/payouts-list/payouts-list.js +1 -1
  211. package/dist/collection/components/terminal-orders-list/terminal-orders-list-core.js +1 -1
  212. package/dist/collection/components/terminal-orders-list/terminal-orders-list-filters.js +2 -2
  213. package/dist/collection/components/terminal-orders-list/terminal-orders-list.js +1 -1
  214. package/dist/collection/components/terminals-list/terminals-list-core.js +1 -1
  215. package/dist/collection/components/terminals-list/terminals-list-filters.js +4 -3
  216. package/dist/collection/components/terminals-list/terminals-list.js +1 -1
  217. package/dist/collection/components/terminals-list/terminals-status.js +5 -0
  218. package/dist/collection/components/tokenize-payment-method/tokenize-payment-method.js +1 -1
  219. package/dist/collection/store/checkout.store.js +4 -0
  220. package/dist/collection/styles/parts.js +1 -1
  221. package/dist/collection/ui-components/apple-pay-button.js +6 -8
  222. package/dist/collection/ui-components/custom-popper/custom-popper.js +2 -2
  223. package/dist/collection/ui-components/details/utils.js +4 -4
  224. package/dist/collection/ui-components/form/form-control-checkbox.js +2 -2
  225. package/dist/collection/ui-components/form/form-control-date.js +2 -2
  226. package/dist/collection/ui-components/form/form-control-file-v2.js +1 -1
  227. package/dist/collection/ui-components/form/form-control-file.js +2 -2
  228. package/dist/collection/ui-components/form/form-control-monetary.js +2 -2
  229. package/dist/collection/ui-components/form/form-control-number-masked.js +2 -2
  230. package/dist/collection/ui-components/form/form-control-number.js +2 -2
  231. package/dist/collection/ui-components/form/form-control-radio.js +2 -2
  232. package/dist/collection/ui-components/form/form-control-select.js +2 -2
  233. package/dist/collection/ui-components/form/form-control-text.js +2 -2
  234. package/dist/collection/ui-components/form/form-control-textarea.js +2 -2
  235. package/dist/collection/ui-components/form/hidden-input.js +1 -1
  236. package/dist/collection/ui-components/form/iframe-input.js +3 -3
  237. package/dist/collection/ui-components/pagination-menu/pagination-menu.js +3 -3
  238. package/dist/collection/ui-components/shadow-dom-components/justifi-button.js +1 -1
  239. package/dist/collection/ui-components/shadow-dom-components/justifi-header.js +1 -1
  240. package/dist/collection/ui-components/shadow-dom-components/justifi-skeleton.js +1 -1
  241. package/dist/collection/utils/form-input-masks.js +0 -8
  242. package/dist/collection/utils/utils.js +4 -0
  243. package/dist/docs.json +248 -1133
  244. package/dist/esm/{Api-DLf3ihCB.js → Api-DhiA2e_P.js} +2 -2
  245. package/dist/esm/{Business-B5rtFhtR.js → Business-BCoP0TAV.js} +3 -290
  246. package/dist/esm/{Refund-BeI1WGfx.js → Refund-B-iOTRxz.js} +3 -2
  247. package/dist/esm/additional-questions-details_5.entry.js +14 -13
  248. package/dist/esm/{badge-CkfrkCoy.js → badge-CtdO-tEY.js} +2 -2
  249. package/dist/esm/bank-account-document-form-inputs_4.entry.js +107 -0
  250. package/dist/esm/bank-account-form.entry.js +8 -8
  251. package/dist/esm/{business-additional-questions-schema-DSvdNuI1.js → business-additional-questions-schema-9FAJSx_D.js} +5 -26
  252. package/dist/esm/business-details-core.entry.js +5 -5
  253. package/dist/esm/{business-form-options-D6s5H4RI.js → business-form-options-CgssATyg.js} +2 -2
  254. package/dist/esm/business-identity-schema-CDJzknbg.js +48 -0
  255. package/dist/esm/{business.service-BIALik8Z.js → business.service-D55OVyco.js} +3 -3
  256. package/dist/esm/{button-CuZAKl_x.js → button-DtTaQHMK.js} +2 -2
  257. package/dist/esm/card-form.entry.js +8 -8
  258. package/dist/esm/{check-pkg-version-Bk5bgulF.js → check-pkg-version-XGo_oqEC.js} +4 -4
  259. package/dist/esm/{checkout.service-DZDZBIGQ.js → checkout.service-fwbqSq8g.js} +3 -3
  260. package/dist/esm/{checkout.store-DwJGKabu.js → checkout.store-4nUf2OuT.js} +5 -1
  261. package/dist/esm/checkouts-list-core.entry.js +15 -13
  262. package/dist/esm/{checkouts-list-params-state-BY5996_y.js → checkouts-list-params-state-C_fug9R3.js} +1 -1
  263. package/dist/esm/{checkouts-table-59DpP7zM.js → checkouts-table-B6gGDtOr.js} +4 -4
  264. package/dist/esm/{config-state-C83RkI9h.js → config-state-DiHV-4QK.js} +1 -1
  265. package/dist/esm/{custom-popper.entry.js → custom-popper_2.entry.js} +23 -4
  266. package/dist/esm/{dispute.service-ByJy64X7.js → dispute.service-Cdq3_yRo.js} +3 -3
  267. package/dist/esm/form-alert_5.entry.js +15 -25
  268. package/dist/esm/form-control-checkbox.entry.js +6 -6
  269. package/dist/esm/form-control-date.entry.js +5 -5
  270. package/dist/esm/{form-control-error-text-CjrxZorl.js → form-control-error-text-bprS-t9d.js} +2 -2
  271. package/dist/esm/form-control-file-v2_2.entry.js +6 -6
  272. package/dist/esm/{form-control-help-text-CMUgRhUf.js → form-control-help-text-Bvnp-IAG.js} +2 -2
  273. package/dist/esm/form-control-help-text.entry.js +1 -1
  274. package/dist/esm/form-control-monetary-provisioning.entry.js +7 -7
  275. package/dist/esm/form-control-monetary.entry.js +7 -7
  276. package/dist/esm/form-control-number-masked_2.entry.js +104 -0
  277. package/dist/esm/form-control-number.entry.js +6 -6
  278. package/dist/esm/form-control-radio.entry.js +4 -4
  279. package/dist/esm/{form-control-select_3.entry.js → form-control-select_2.entry.js} +8 -26
  280. package/dist/esm/{form-input-masks-CVaOFfrI.js → form-input-masks-B-iV5cYd.js} +3 -9
  281. package/dist/esm/{get-business-Xt7B5dSo.js → get-business-Crb6P-iI.js} +1 -1
  282. package/dist/esm/{get-payment-details-B00HoaFm.js → get-payment-details-sGoWyAat.js} +3 -3
  283. package/dist/esm/{get-subaccounts-C_yzcZq_.js → get-subaccounts-BsJSlShO.js} +4 -4
  284. package/dist/esm/gross-payment-chart-core.entry.js +26 -17
  285. package/dist/esm/{header-1-BukynbFR.js → header-1-C1Hnxki8.js} +2 -2
  286. package/dist/esm/{header-3-D87MAyMK.js → header-3-Bq8fpjm-.js} +2 -2
  287. package/dist/esm/helpers-Mu7LQT-w.js +29 -0
  288. package/dist/esm/hidden-input_2.entry.js +9 -9
  289. package/dist/esm/{index-NOsb-hYl.js → index-DJ9G-4S-.js} +1 -1
  290. package/dist/esm/{index-_b8l4IX7.js → index-DOjVAAtq.js} +5 -2
  291. package/dist/esm/{input-handlers-D3y0TzH9.js → input-handlers-CX6mSvOM.js} +1 -1
  292. package/dist/esm/{insurance-state-BjY1QRXI.js → insurance-state-CVme82j7.js} +3 -3
  293. package/dist/esm/justifi-additional-questions-form-step-core_6.entry.js +73 -130
  294. package/dist/esm/justifi-additional-questions-form-step_9.entry.js +26 -25
  295. package/dist/esm/justifi-additional-statement_8.entry.js +10 -10
  296. package/dist/esm/{justifi-checkout-summary_7.entry.js → justifi-apple-pay_8.entry.js} +824 -26
  297. package/dist/esm/justifi-bank-account-billing-form-simple_9.entry.js +30 -29
  298. package/dist/esm/justifi-business-details.entry.js +15 -13
  299. package/dist/esm/justifi-business-form.entry.js +23 -27
  300. package/dist/esm/justifi-business-representative-form-inputs.entry.js +8 -16
  301. package/dist/esm/justifi-checkout.entry.js +16 -14
  302. package/dist/esm/justifi-checkouts-list-filters.entry.js +12 -10
  303. package/dist/esm/justifi-checkouts-list.entry.js +18 -16
  304. package/dist/esm/justifi-config-provider.entry.js +3 -3
  305. package/dist/esm/justifi-details.entry.js +3 -3
  306. package/dist/esm/justifi-dispute-management-core.entry.js +2 -2
  307. package/dist/esm/justifi-dispute-management.entry.js +13 -11
  308. package/dist/esm/justifi-dispute-notification_3.entry.js +19 -17
  309. package/dist/esm/justifi-gross-payment-chart.entry.js +13 -11
  310. package/dist/esm/justifi-order-terminals.entry.js +18 -16
  311. package/dist/esm/justifi-owner-form_3.entry.js +21 -30
  312. package/dist/esm/justifi-payment-details.entry.js +23 -14
  313. package/dist/esm/justifi-payment-provisioning-core.entry.js +25 -40
  314. package/dist/esm/justifi-payment-provisioning.entry.js +13 -11
  315. package/dist/esm/justifi-payment-transactions-list.entry.js +17 -15
  316. package/dist/esm/justifi-payments-list-filters.entry.js +8 -8
  317. package/dist/esm/justifi-payments-list.entry.js +18 -16
  318. package/dist/esm/justifi-payout-details.entry.js +16 -13
  319. package/dist/esm/justifi-payout-transactions-list.entry.js +17 -15
  320. package/dist/esm/justifi-payouts-list-filters.entry.js +8 -8
  321. package/dist/esm/justifi-payouts-list.entry.js +19 -17
  322. package/dist/esm/justifi-refund-payment.entry.js +17 -15
  323. package/dist/esm/justifi-saved-payment-method.entry.js +3 -3
  324. package/dist/esm/justifi-season-interruption-insurance.entry.js +16 -14
  325. package/dist/esm/justifi-skeleton.entry.js +5 -5
  326. package/dist/esm/justifi-terminal-orders-list-filters.entry.js +13 -11
  327. package/dist/esm/justifi-terminal-orders-list.entry.js +16 -14
  328. package/dist/esm/justifi-terminals-list-filters.entry.js +14 -11
  329. package/dist/esm/justifi-terminals-list.entry.js +18 -16
  330. package/dist/esm/loader.js +3 -3
  331. package/dist/esm/{package-BRhnhmpB.js → package-YyotqiSL.js} +1 -1
  332. package/dist/esm/pagination-menu.entry.js +5 -5
  333. package/dist/esm/{parts-CA_TyBed.js → parts-xDbRW9xn.js} +2 -1
  334. package/dist/esm/payment-details-core.entry.js +34 -16
  335. package/dist/esm/payment-method-option.entry.js +4 -4
  336. package/dist/esm/{payment.service-B_NytmNz.js → payment.service-BoQ1MW1k.js} +3 -3
  337. package/dist/esm/payments-list-core.entry.js +16 -14
  338. package/dist/esm/{payments-list-params-state-BY5996_y.js → payments-list-params-state-C_fug9R3.js} +1 -1
  339. package/dist/esm/{payments-status-BWv1l1-e.js → payments-status-cvtVmtY5.js} +22 -4
  340. package/dist/esm/{payments-table-BSk36N1O.js → payments-table-D_BlyU1F.js} +4 -4
  341. package/dist/esm/payout-details-core.entry.js +25 -12
  342. package/dist/esm/{payout.service-BJQVlc_Z.js → payout.service-xcBdom3q.js} +3 -3
  343. package/dist/esm/payouts-list-core.entry.js +16 -14
  344. package/dist/esm/{payouts-list-params-state-BY5996_y.js → payouts-list-params-state-C_fug9R3.js} +1 -1
  345. package/dist/esm/{payouts-status-BujJlH_r.js → payouts-status-D-vjrqBb.js} +2 -2
  346. package/dist/esm/{payouts-table-5N7OylTW.js → payouts-table-Clj8YGLV.js} +4 -4
  347. package/dist/esm/{schema-validations-BFoU1cR8.js → schema-validations-B9dmY7ME.js} +6 -41
  348. package/dist/esm/{skeleton-C161KeYG.js → skeleton-B8EUwt4b.js} +2 -2
  349. package/dist/esm/{spinner-UiInIFXW.js → spinner-CYXkn1fh.js} +2 -2
  350. package/dist/esm/state-options-BX8GieXu.js +244 -0
  351. package/dist/esm/{styled-host-hSGxxyFZ.js → styled-host-OalOsPBp.js} +1 -1
  352. package/dist/esm/{table-9ewYPAZH.js → table-Bj20uWfu.js} +3 -3
  353. package/dist/esm/table-filters-menu.entry.js +4 -4
  354. package/dist/esm/terminal-orders-list-core.entry.js +15 -13
  355. package/dist/esm/{terminal-orders-list-params-state-BY5996_y.js → terminal-orders-list-params-state-C_fug9R3.js} +1 -1
  356. package/dist/esm/{terminal-orders-table-BcziGGSF.js → terminal-orders-table-DzBpIW8i.js} +7 -7
  357. package/dist/esm/terminal-quantity-selector.entry.js +3 -3
  358. package/dist/esm/{terminal.service-B9MOFa2c.js → terminal.service-l6zTIPZ3.js} +3 -3
  359. package/dist/esm/terminals-list-core.entry.js +15 -13
  360. package/dist/esm/terminals-list-params-state-C_fug9R3.js +16 -0
  361. package/dist/esm/{terminals-table-BoFlvdHS.js → terminals-table-BMS5tazC.js} +9 -4
  362. package/dist/esm/{utils-DeZftIgK.js → utils-BOijEGPV.js} +4 -1
  363. package/dist/esm/{utils-fntGABrK.js → utils-DRwofES0.js} +5 -5
  364. package/dist/esm/webcomponents.js +4 -4
  365. package/dist/module/Business.js +3 -290
  366. package/dist/module/Refund.js +2 -1
  367. package/dist/module/additional-questions-details2.js +1 -1
  368. package/dist/module/additional-statement.js +1 -1
  369. package/dist/{esm/justifi-apple-pay.entry.js → module/apple-pay.js} +74 -106
  370. package/dist/module/badge.js +1 -1
  371. package/dist/module/bank-account-billing-form-simple.js +2 -2
  372. package/dist/module/bank-account-document-inputs.js +1 -1
  373. package/dist/module/bank-account-form-inputs2.js +2 -9
  374. package/dist/module/bank-account-form.js +3 -3
  375. package/dist/module/bank-account.js +2 -2
  376. package/dist/module/billing-form-full.js +2 -2
  377. package/dist/module/billing-form.js +3 -2
  378. package/dist/module/business-additional-questions-form-step.js +1 -1
  379. package/dist/module/business-address-schema.js +20 -40
  380. package/dist/module/business-bank-account-form-step-core.js +49 -102
  381. package/dist/module/business-bank-account-form-step.js +5 -18
  382. package/dist/module/business-core-info-form-step-core.js +7 -22
  383. package/dist/module/business-core-info-form-step.js +1 -2
  384. package/dist/module/business-core-info-schema.js +5 -26
  385. package/dist/module/business-core-info.js +4 -12
  386. package/dist/module/business-documents-on-file2.js +1 -1
  387. package/dist/module/business-identity-schema.js +25 -52
  388. package/dist/module/business-owners-form-step-core.js +13 -20
  389. package/dist/module/business-owners-form-step.js +15 -22
  390. package/dist/module/business-representative-form-inputs.js +17 -34
  391. package/dist/module/business-representative-form-step-core.js +18 -29
  392. package/dist/module/business-representative-form-step.js +17 -24
  393. package/dist/module/business-representative.js +18 -36
  394. package/dist/module/business-terms-conditions-form-step.js +1 -1
  395. package/dist/module/button.js +1 -1
  396. package/dist/module/cancellation-policy.js +1 -1
  397. package/dist/module/card-billing-form-simple.js +2 -2
  398. package/dist/module/card-form.js +3 -3
  399. package/dist/module/card-form2.js +2 -2
  400. package/dist/module/checkout.store.js +4 -0
  401. package/dist/module/checkouts-list-core2.js +2 -2
  402. package/dist/module/custom-popper2.js +2 -2
  403. package/dist/module/customer-details.js +1 -1
  404. package/dist/module/dispute-management-core.js +1 -1
  405. package/dist/module/dispute-notification.js +1 -1
  406. package/dist/module/dispute-response-core.js +1 -1
  407. package/dist/module/dispute-response.js +1 -1
  408. package/dist/module/duplicate-charge.js +1 -1
  409. package/dist/module/electronic-evidence.js +1 -1
  410. package/dist/module/form-alert2.js +1 -1
  411. package/dist/module/form-control-checkbox2.js +3 -3
  412. package/dist/module/form-control-date2.js +3 -3
  413. package/dist/module/form-control-error-text.js +1 -1
  414. package/dist/module/form-control-file-v22.js +1 -1
  415. package/dist/module/form-control-file2.js +3 -3
  416. package/dist/module/form-control-monetary-provisioning2.js +3 -3
  417. package/dist/module/form-control-monetary2.js +3 -3
  418. package/dist/module/form-control-number-masked2.js +3 -3
  419. package/dist/module/form-control-number.js +3 -3
  420. package/dist/module/form-control-radio2.js +3 -3
  421. package/dist/module/form-control-select2.js +3 -3
  422. package/dist/module/form-control-text2.js +3 -3
  423. package/dist/module/form-control-textarea2.js +3 -3
  424. package/dist/module/form-control-tooltip2.js +1 -1
  425. package/dist/module/form-input-masks.js +3 -9
  426. package/dist/module/get-business.js +1 -1
  427. package/dist/module/gross-payment-chart-core2.js +22 -13
  428. package/dist/module/header-3.js +1 -1
  429. package/dist/module/helpers.js +29 -0
  430. package/dist/module/hidden-input2.js +2 -2
  431. package/dist/module/identity-address-form.js +14 -16
  432. package/dist/module/iframe-input2.js +4 -4
  433. package/dist/module/input-handlers.js +1 -1
  434. package/dist/module/justifi-apple-pay.js +1 -904
  435. package/dist/module/justifi-business-form.js +29 -41
  436. package/dist/module/justifi-button2.js +1 -1
  437. package/dist/module/justifi-checkout.js +27 -21
  438. package/dist/module/justifi-checkouts-list-filters.js +2 -2
  439. package/dist/module/justifi-checkouts-list.js +2 -2
  440. package/dist/module/justifi-dispute-management.js +1 -1
  441. package/dist/module/justifi-header2.js +1 -1
  442. package/dist/module/justifi-order-terminals.js +5 -5
  443. package/dist/module/justifi-payment-details.js +8 -1
  444. package/dist/module/justifi-payment-provisioning.js +49 -67
  445. package/dist/module/justifi-payment-transactions-list.js +3 -3
  446. package/dist/module/justifi-payments-list-filters.js +3 -3
  447. package/dist/module/justifi-payments-list.js +1 -1
  448. package/dist/module/justifi-payout-details.js +4 -2
  449. package/dist/module/justifi-payout-transactions-list.js +3 -3
  450. package/dist/module/justifi-payouts-list-filters.js +3 -3
  451. package/dist/module/justifi-payouts-list.js +2 -2
  452. package/dist/module/justifi-refund-payment.js +1 -1
  453. package/dist/module/justifi-saved-payment-method.js +1 -1
  454. package/dist/module/justifi-season-interruption-insurance.js +2 -2
  455. package/dist/module/justifi-skeleton.js +1 -1
  456. package/dist/module/justifi-terminal-orders-list-filters.js +4 -4
  457. package/dist/module/justifi-terminal-orders-list.js +2 -2
  458. package/dist/module/justifi-terminals-list-filters.js +5 -4
  459. package/dist/module/justifi-terminals-list.js +2 -2
  460. package/dist/module/legal-address-form-step-core.js +19 -26
  461. package/dist/module/legal-address-form-step.js +9 -16
  462. package/dist/module/legal-address-form.js +14 -17
  463. package/dist/module/modular-checkout.js +7 -6
  464. package/dist/module/owner-details2.js +8 -7
  465. package/dist/module/owner-form-core2.js +16 -24
  466. package/dist/module/owner-form-inputs2.js +15 -34
  467. package/dist/module/owner-form.js +13 -20
  468. package/dist/module/package.js +1 -1
  469. package/dist/module/pagination-menu2.js +4 -4
  470. package/dist/module/parts.js +2 -1
  471. package/dist/module/payment-details-core2.js +22 -9
  472. package/dist/module/payment-method-option.js +1 -1
  473. package/dist/module/payment-provisioning-core.js +69 -104
  474. package/dist/module/payment-provisioning-form-buttons.js +1 -1
  475. package/dist/module/payment-provisioning-form-steps.js +54 -75
  476. package/dist/module/payments-list-core2.js +2 -2
  477. package/dist/module/payments-status.js +20 -2
  478. package/dist/module/payout-details-core2.js +18 -4
  479. package/dist/module/payouts-list-core2.js +2 -2
  480. package/dist/module/product-or-service.js +1 -1
  481. package/dist/module/refund-policy.js +1 -1
  482. package/dist/module/representative-details2.js +1 -1
  483. package/dist/module/save-new-payment-method.js +1 -1
  484. package/dist/module/schema-validations.js +6 -41
  485. package/dist/module/shipping-details.js +1 -1
  486. package/dist/module/spinner.js +1 -1
  487. package/dist/module/state-options.js +244 -0
  488. package/dist/module/summary.js +1 -1
  489. package/dist/module/table-filters-menu2.js +2 -2
  490. package/dist/module/table.js +1 -1
  491. package/dist/module/terminal-orders-list-core2.js +3 -3
  492. package/dist/module/terminal-quantity-selector2.js +2 -2
  493. package/dist/module/terminals-list-core2.js +8 -3
  494. package/dist/module/tokenize-payment-method.js +1 -1
  495. package/dist/module/utils.js +4 -4
  496. package/dist/module/utils2.js +4 -1
  497. package/dist/types/api/BankAccount.d.ts +0 -6
  498. package/dist/types/api/Business.d.ts +0 -9
  499. package/dist/types/api/Checkout.d.ts +2 -0
  500. package/dist/types/api/ComponentEvents.d.ts +4 -0
  501. package/dist/types/api/Terminal.d.ts +2 -1
  502. package/dist/types/components/business-details/owner-details/owner-details.d.ts +1 -1
  503. package/dist/types/components/business-forms/business-form/business-core-info/business-core-info.d.ts +0 -3
  504. package/dist/types/components/business-forms/business-form/business-form.d.ts +0 -2
  505. package/dist/types/components/business-forms/business-form/business-representative/business-representative.d.ts +1 -4
  506. package/dist/types/components/business-forms/business-form/legal-address-form/legal-address-form.d.ts +0 -2
  507. package/dist/types/components/business-forms/owner-form/identity-address/identity-address-form.d.ts +0 -2
  508. package/dist/types/components/business-forms/owner-form/owner-form-core.d.ts +0 -2
  509. package/dist/types/components/business-forms/owner-form/owner-form-inputs.d.ts +0 -3
  510. package/dist/types/components/business-forms/owner-form/owner-form.d.ts +0 -2
  511. package/dist/types/components/business-forms/payment-provisioning/bank-account/business-bank-account-form-step-core.d.ts +0 -5
  512. package/dist/types/components/business-forms/payment-provisioning/bank-account/business-bank-account-form-step.d.ts +0 -2
  513. package/dist/types/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step-core.d.ts +0 -3
  514. package/dist/types/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step.d.ts +0 -2
  515. package/dist/types/components/business-forms/payment-provisioning/business-owners/business-owners-form-step-core.d.ts +0 -2
  516. package/dist/types/components/business-forms/payment-provisioning/business-owners/business-owners-form-step.d.ts +0 -2
  517. package/dist/types/components/business-forms/payment-provisioning/business-representative/business-representative-form-inputs.d.ts +0 -3
  518. package/dist/types/components/business-forms/payment-provisioning/business-representative/business-representative-form-step-core.d.ts +0 -2
  519. package/dist/types/components/business-forms/payment-provisioning/business-representative/business-representative-form-step.d.ts +0 -2
  520. package/dist/types/components/business-forms/payment-provisioning/legal-address-form/legal-address-form-step-core.d.ts +0 -2
  521. package/dist/types/components/business-forms/payment-provisioning/legal-address-form/legal-address-form-step.d.ts +0 -2
  522. package/dist/types/components/business-forms/payment-provisioning/payment-provisioning-core.d.ts +2 -4
  523. package/dist/types/components/business-forms/payment-provisioning/payment-provisioning-form-steps.d.ts +0 -2
  524. package/dist/types/components/business-forms/schemas/business-address-schema.d.ts +2 -54
  525. package/dist/types/components/business-forms/schemas/business-bank-account-schema.d.ts +16 -14
  526. package/dist/types/components/business-forms/schemas/business-core-info-schema.d.ts +3 -67
  527. package/dist/types/components/business-forms/schemas/business-form-schema.d.ts +6 -164
  528. package/dist/types/components/business-forms/schemas/business-identity-schema.d.ts +2 -122
  529. package/dist/types/components/business-forms/schemas/schema-validations.d.ts +0 -5
  530. package/dist/types/components/modular-checkout/sub-components/apple-pay.d.ts +2 -0
  531. package/dist/types/components/payment-details/payment-details-core.d.ts +3 -1
  532. package/dist/types/components/payment-details/payment-details.d.ts +3 -1
  533. package/dist/types/components/payments-list/payments-status.d.ts +12 -0
  534. package/dist/types/components/payout-details/payout-details-core.d.ts +5 -1
  535. package/dist/types/components/payout-details/payout-details.d.ts +1 -0
  536. package/dist/types/components.d.ts +38 -113
  537. package/dist/types/stencil-public-runtime.d.ts +20 -10
  538. package/dist/types/store/checkout.store.d.ts +1 -0
  539. package/dist/types/styles/parts.d.ts +1 -1
  540. package/dist/types/ui-components/details/utils.d.ts +3 -2
  541. package/dist/types/utils/form-input-masks.d.ts +0 -1
  542. package/dist/types/utils/utils.d.ts +1 -0
  543. package/dist/webcomponents/p-0217783c.entry.js +20 -0
  544. package/dist/webcomponents/p-02fdd7f5.entry.js +1 -0
  545. package/dist/webcomponents/p-0af5269e.entry.js +1 -0
  546. package/dist/webcomponents/p-0cac8468.entry.js +1 -0
  547. package/dist/webcomponents/{p-b59221a9.entry.js → p-0cf71cbd.entry.js} +1 -1
  548. package/dist/webcomponents/p-0eb69f41.entry.js +1 -0
  549. package/dist/webcomponents/p-0fgTPVV0.js +1 -0
  550. package/dist/webcomponents/{p-c1f10a84.entry.js → p-13df20c1.entry.js} +1 -1
  551. package/dist/webcomponents/{p-C77ElQ41.js → p-1ydcg9ti.js} +1 -1
  552. package/dist/webcomponents/p-28625e07.entry.js +1 -0
  553. package/dist/webcomponents/p-2d300faa.entry.js +1 -0
  554. package/dist/webcomponents/{p-6ea75d39.entry.js → p-2f40f708.entry.js} +1 -1
  555. package/dist/webcomponents/p-328117e4.entry.js +1 -0
  556. package/dist/webcomponents/p-32978110.entry.js +1 -0
  557. package/dist/webcomponents/{p-c7390115.entry.js → p-37a93597.entry.js} +1 -1
  558. package/dist/webcomponents/p-3dd950bf.entry.js +1 -0
  559. package/dist/webcomponents/p-447b55c0.entry.js +1 -0
  560. package/dist/webcomponents/p-47997bc2.entry.js +1 -0
  561. package/dist/webcomponents/p-4bf52215.entry.js +1 -0
  562. package/dist/webcomponents/p-50701f16.entry.js +1 -0
  563. package/dist/webcomponents/p-526b7442.entry.js +1 -0
  564. package/dist/webcomponents/p-5aae36f3.entry.js +1 -0
  565. package/dist/webcomponents/p-5bd3d86e.entry.js +1 -0
  566. package/dist/webcomponents/p-63ad8ebd.entry.js +1 -0
  567. package/dist/webcomponents/p-63fb5e82.entry.js +1 -0
  568. package/dist/webcomponents/p-6472b6db.entry.js +1 -0
  569. package/dist/webcomponents/p-6e9cd0dd.entry.js +1 -0
  570. package/dist/webcomponents/p-6f27030e.entry.js +1 -0
  571. package/dist/webcomponents/p-705dba52.entry.js +1 -0
  572. package/dist/webcomponents/p-7680c57b.entry.js +1 -0
  573. package/dist/webcomponents/p-7686ef15.entry.js +1 -0
  574. package/dist/webcomponents/p-773d6dd3.entry.js +1 -0
  575. package/dist/webcomponents/p-78cb62a8.entry.js +1 -0
  576. package/dist/webcomponents/p-7b55e1c1.entry.js +1 -0
  577. package/dist/webcomponents/p-7b5ad3a7.entry.js +1 -0
  578. package/dist/webcomponents/p-80b2cdec.entry.js +1 -0
  579. package/dist/webcomponents/p-8S_ROmnq.js +1 -0
  580. package/dist/webcomponents/p-8ca21fab.entry.js +1 -0
  581. package/dist/webcomponents/p-9ad7d724.entry.js +1 -0
  582. package/dist/webcomponents/p-9ed7b13f.entry.js +1 -0
  583. package/dist/webcomponents/p-B-iV5cYd.js +1 -0
  584. package/dist/webcomponents/p-B6IWa9Ph.js +1 -0
  585. package/dist/webcomponents/{p-BdREtifE.js → p-BBx_EQqR.js} +1 -1
  586. package/dist/webcomponents/p-BX8GieXu.js +1 -0
  587. package/dist/webcomponents/{p-xWrhxNNk.js → p-Bgnhf5c9.js} +1 -1
  588. package/dist/webcomponents/{p-DTwFW2k_.js → p-BhCH9S0e.js} +1 -1
  589. package/dist/webcomponents/p-BjNuRWXK.js +1 -0
  590. package/dist/webcomponents/p-BlJnA265.js +1 -0
  591. package/dist/webcomponents/p-BoQ6_4Ks.js +1 -0
  592. package/dist/webcomponents/{p-DWGKeoot.js → p-C0wTyoTh.js} +1 -1
  593. package/dist/webcomponents/p-C2JJBtMc.js +1 -0
  594. package/dist/webcomponents/{p-g2ubqhtv.js → p-C8k7a6D-.js} +1 -1
  595. package/dist/webcomponents/{p-BPDMo6us.js → p-C98BC5W5.js} +1 -1
  596. package/dist/webcomponents/p-C9EQ459H.js +1 -0
  597. package/dist/webcomponents/p-C9iide2W.js +1 -0
  598. package/dist/webcomponents/p-CCLgieAN.js +1 -0
  599. package/dist/webcomponents/p-CCmDcLao.js +1 -0
  600. package/dist/webcomponents/{p-qUCDGWNE.js → p-CEk3bv0x.js} +1 -1
  601. package/dist/webcomponents/p-CH8Y3GSr.js +1 -0
  602. package/dist/webcomponents/{p-BaM0JBLn.js → p-CdEseavG.js} +1 -1
  603. package/dist/webcomponents/{p-D2hzOOMf.js → p-ClvhB3WW.js} +1 -1
  604. package/dist/webcomponents/{p-JSXyHheQ.js → p-CmBCj61h.js} +1 -1
  605. package/dist/webcomponents/p-D0Peuz-m.js +1 -0
  606. package/dist/webcomponents/p-D6BImiVi.js +1 -0
  607. package/dist/webcomponents/p-DGsXKF67.js +1 -0
  608. package/dist/webcomponents/p-DH8F0bsw.js +1 -0
  609. package/dist/webcomponents/{p-_b8l4IX7.js → p-DOjVAAtq.js} +2 -2
  610. package/dist/webcomponents/p-DQZ5VHTZ.js +1 -0
  611. package/dist/webcomponents/p-DWn9BiNn.js +1 -0
  612. package/dist/webcomponents/{p-hj8k0lRi.js → p-DdMxswn1.js} +1 -1
  613. package/dist/webcomponents/{p-M5r2kSbf.js → p-DdZLLkQ5.js} +1 -1
  614. package/dist/webcomponents/p-DfV3dFDB.js +1 -0
  615. package/dist/webcomponents/p-Dieke6TH.js +1 -0
  616. package/dist/webcomponents/p-Dt-vy9Le.js +1 -0
  617. package/dist/webcomponents/p-NAjz1Xfo.js +1 -0
  618. package/dist/webcomponents/p-NwmOm8Pg.js +1 -0
  619. package/dist/webcomponents/p-PSJOKMWp.js +1 -0
  620. package/dist/webcomponents/p-RQzxYnz_.js +1 -0
  621. package/dist/webcomponents/p-T2yENPvU.js +1 -0
  622. package/dist/webcomponents/p-YyotqiSL.js +1 -0
  623. package/dist/webcomponents/{p-931003fc.entry.js → p-a09695c4.entry.js} +1 -1
  624. package/dist/webcomponents/{p-b46fe458.entry.js → p-a4846316.entry.js} +1 -1
  625. package/dist/webcomponents/p-a6tcNl_T.js +1 -0
  626. package/dist/webcomponents/p-adc1d0be.entry.js +1 -0
  627. package/dist/webcomponents/p-ae8ae5bb.entry.js +1 -0
  628. package/dist/webcomponents/p-aeb22aa2.entry.js +1 -0
  629. package/dist/webcomponents/{p-fVyCeQNq.js → p-au49QgoI.js} +1 -1
  630. package/dist/webcomponents/p-b149a2fc.entry.js +1 -0
  631. package/dist/webcomponents/p-b4aa9298.entry.js +1 -0
  632. package/dist/webcomponents/{p-b17cb15d.entry.js → p-b608add9.entry.js} +1 -1
  633. package/dist/webcomponents/p-bb53e2e9.entry.js +1 -0
  634. package/dist/webcomponents/p-bc099dd0.entry.js +1 -0
  635. package/dist/webcomponents/p-c12d0453.entry.js +1 -0
  636. package/dist/webcomponents/p-c2569b4c.entry.js +1 -0
  637. package/dist/webcomponents/p-c644a9f1.entry.js +1 -0
  638. package/dist/webcomponents/p-cb782215.entry.js +1 -0
  639. package/dist/webcomponents/p-d0a2035f.entry.js +1 -0
  640. package/dist/webcomponents/p-d1bceac6.entry.js +1 -0
  641. package/dist/webcomponents/p-d4476052.entry.js +1 -0
  642. package/dist/webcomponents/p-d5452069.entry.js +1 -0
  643. package/dist/webcomponents/p-d88d7418.entry.js +1 -0
  644. package/dist/webcomponents/p-de95bf57.entry.js +1 -0
  645. package/dist/webcomponents/p-e365b251.entry.js +1 -0
  646. package/dist/webcomponents/p-e6be4e19.entry.js +1 -0
  647. package/dist/webcomponents/p-e6fe9b7d.entry.js +1 -0
  648. package/dist/webcomponents/p-e9f6a621.entry.js +1 -0
  649. package/dist/webcomponents/p-ec9514f8.entry.js +1 -0
  650. package/dist/webcomponents/p-edfeb034.entry.js +1 -0
  651. package/dist/webcomponents/p-f378af59.entry.js +1 -0
  652. package/dist/webcomponents/p-f705fc49.entry.js +1 -0
  653. package/dist/webcomponents/p-fbc5fc6d.entry.js +1 -0
  654. package/dist/webcomponents/p-ffefa09c.entry.js +1 -0
  655. package/dist/webcomponents/p-h5pyZngT.js +1 -0
  656. package/dist/webcomponents/p-hbWSMN3O.js +1 -0
  657. package/dist/webcomponents/p-lKnUT24T.js +1 -0
  658. package/dist/webcomponents/p-tYuXMkCd.js +1 -0
  659. package/dist/webcomponents/p-wQgEEOq_.js +1 -0
  660. package/dist/webcomponents/p-xDbRW9xn.js +1 -0
  661. package/dist/webcomponents/{p-CPpUGsw5.js → p-yH3TC3ZQ.js} +1 -1
  662. package/dist/webcomponents/webcomponents.esm.js +1 -1
  663. package/package.json +1 -1
  664. package/dist/cjs/bank-account-document-form-inputs_6.cjs.entry.js +0 -132
  665. package/dist/cjs/business-identity-schema-Cd0tvfJr.js +0 -101
  666. package/dist/cjs/country-config-MCOhn8o3.js +0 -68
  667. package/dist/cjs/form-control-number-masked_3.cjs.entry.js +0 -119
  668. package/dist/cjs/justifi-apple-pay.cjs.entry.js +0 -876
  669. package/dist/cjs/terminals-list-params-state-ARjo40Y9.js +0 -22
  670. package/dist/collection/components/business-forms/payment-provisioning/bank-account/bank-account-form-inputs-canada.js +0 -88
  671. package/dist/collection/components/business-forms/payment-provisioning/bank-account/bank-account-read-only-value.js +0 -50
  672. package/dist/collection/components/business-forms/payment-provisioning/form-address-fields/form-address-fields.js +0 -101
  673. package/dist/collection/components/business-forms/payment-provisioning/test/mockBusiness.js +0 -52
  674. package/dist/collection/components/business-forms/utils/country-config.js +0 -47
  675. package/dist/collection/utils/country-codes.js +0 -5
  676. package/dist/collection/utils/province-options.js +0 -20
  677. package/dist/esm/bank-account-document-form-inputs_6.entry.js +0 -125
  678. package/dist/esm/business-identity-schema-mN4VhA1v.js +0 -94
  679. package/dist/esm/country-config-BQ4D46Lb.js +0 -64
  680. package/dist/esm/form-control-number-masked_3.entry.js +0 -115
  681. package/dist/esm/terminals-list-params-state-BY5996_y.js +0 -16
  682. package/dist/module/bank-account-form-inputs-canada.d.ts +0 -11
  683. package/dist/module/bank-account-form-inputs-canada.js +0 -6
  684. package/dist/module/bank-account-form-inputs-canada2.js +0 -68
  685. package/dist/module/bank-account-read-only-value.d.ts +0 -11
  686. package/dist/module/bank-account-read-only-value.js +0 -6
  687. package/dist/module/bank-account-read-only-value2.js +0 -33
  688. package/dist/module/country-config.js +0 -64
  689. package/dist/module/form-address-fields.js +0 -65
  690. package/dist/module/justifi-form-address-fields.d.ts +0 -11
  691. package/dist/module/justifi-form-address-fields.js +0 -6
  692. package/dist/types/components/business-forms/payment-provisioning/bank-account/bank-account-form-inputs-canada.d.ts +0 -7
  693. package/dist/types/components/business-forms/payment-provisioning/bank-account/bank-account-read-only-value.d.ts +0 -5
  694. package/dist/types/components/business-forms/payment-provisioning/form-address-fields/form-address-fields.d.ts +0 -8
  695. package/dist/types/components/business-forms/payment-provisioning/test/mockBusiness.d.ts +0 -12
  696. package/dist/types/utils/country-codes.d.ts +0 -4
  697. package/dist/types/utils/province-options.d.ts +0 -5
  698. package/dist/webcomponents/p-0254c06c.entry.js +0 -1
  699. package/dist/webcomponents/p-047fe97f.entry.js +0 -1
  700. package/dist/webcomponents/p-04ca6ff0.entry.js +0 -1
  701. package/dist/webcomponents/p-09d53b03.entry.js +0 -1
  702. package/dist/webcomponents/p-0c5e2fed.entry.js +0 -1
  703. package/dist/webcomponents/p-0ea48603.entry.js +0 -1
  704. package/dist/webcomponents/p-17e9d5c0.entry.js +0 -1
  705. package/dist/webcomponents/p-1ab4d6aa.entry.js +0 -1
  706. package/dist/webcomponents/p-1cf42bc9.entry.js +0 -1
  707. package/dist/webcomponents/p-1e7f4b4f.entry.js +0 -1
  708. package/dist/webcomponents/p-22defde6.entry.js +0 -20
  709. package/dist/webcomponents/p-242208d9.entry.js +0 -1
  710. package/dist/webcomponents/p-31ac0c3d.entry.js +0 -1
  711. package/dist/webcomponents/p-36e21b78.entry.js +0 -1
  712. package/dist/webcomponents/p-3a77a97c.entry.js +0 -1
  713. package/dist/webcomponents/p-40938820.entry.js +0 -1
  714. package/dist/webcomponents/p-40dc0c3c.entry.js +0 -1
  715. package/dist/webcomponents/p-42763479.entry.js +0 -1
  716. package/dist/webcomponents/p-430203b0.entry.js +0 -1
  717. package/dist/webcomponents/p-46d2d042.entry.js +0 -1
  718. package/dist/webcomponents/p-485516a1.entry.js +0 -1
  719. package/dist/webcomponents/p-4fb58ee6.entry.js +0 -1
  720. package/dist/webcomponents/p-54995a3d.entry.js +0 -1
  721. package/dist/webcomponents/p-56617fdd.entry.js +0 -1
  722. package/dist/webcomponents/p-592a45f6.entry.js +0 -1
  723. package/dist/webcomponents/p-5a044ca5.entry.js +0 -1
  724. package/dist/webcomponents/p-5ec18584.entry.js +0 -1
  725. package/dist/webcomponents/p-6122dc79.entry.js +0 -1
  726. package/dist/webcomponents/p-62858ba5.entry.js +0 -1
  727. package/dist/webcomponents/p-62b5e6cf.entry.js +0 -1
  728. package/dist/webcomponents/p-67dab4d9.entry.js +0 -1
  729. package/dist/webcomponents/p-6b791b1d.entry.js +0 -1
  730. package/dist/webcomponents/p-6ebf8f11.entry.js +0 -1
  731. package/dist/webcomponents/p-6fdac295.entry.js +0 -1
  732. package/dist/webcomponents/p-724cf90f.entry.js +0 -1
  733. package/dist/webcomponents/p-7ecca5fe.entry.js +0 -1
  734. package/dist/webcomponents/p-7ecf9bd0.entry.js +0 -1
  735. package/dist/webcomponents/p-850dd606.entry.js +0 -1
  736. package/dist/webcomponents/p-85af9d78.entry.js +0 -1
  737. package/dist/webcomponents/p-9367e7e6.entry.js +0 -1
  738. package/dist/webcomponents/p-9c114674.entry.js +0 -1
  739. package/dist/webcomponents/p-9c267692.entry.js +0 -1
  740. package/dist/webcomponents/p-B5rtFhtR.js +0 -1
  741. package/dist/webcomponents/p-BRhnhmpB.js +0 -1
  742. package/dist/webcomponents/p-BgFM_jvF.js +0 -1
  743. package/dist/webcomponents/p-BqbXuOZP.js +0 -1
  744. package/dist/webcomponents/p-BwpdCtUc.js +0 -1
  745. package/dist/webcomponents/p-C6g4MbnB.js +0 -1
  746. package/dist/webcomponents/p-CA_TyBed.js +0 -1
  747. package/dist/webcomponents/p-CE-MNrID.js +0 -1
  748. package/dist/webcomponents/p-CMpATPXy.js +0 -1
  749. package/dist/webcomponents/p-CQUZeo9r.js +0 -1
  750. package/dist/webcomponents/p-CSeo7WDO.js +0 -1
  751. package/dist/webcomponents/p-CTJ3moi4.js +0 -1
  752. package/dist/webcomponents/p-CVaOFfrI.js +0 -1
  753. package/dist/webcomponents/p-CYNcSTQA.js +0 -1
  754. package/dist/webcomponents/p-CevVA9qy.js +0 -1
  755. package/dist/webcomponents/p-CkiX8OGy.js +0 -1
  756. package/dist/webcomponents/p-CtWnJFtW.js +0 -1
  757. package/dist/webcomponents/p-CycBoHSW.js +0 -1
  758. package/dist/webcomponents/p-D-RVXHwG.js +0 -1
  759. package/dist/webcomponents/p-D1Na2I0C.js +0 -1
  760. package/dist/webcomponents/p-D5lmImiz.js +0 -1
  761. package/dist/webcomponents/p-DMf85Fkr.js +0 -1
  762. package/dist/webcomponents/p-DNPS-Ypi.js +0 -1
  763. package/dist/webcomponents/p-DQ5V5-Jy.js +0 -1
  764. package/dist/webcomponents/p-DapORSs4.js +0 -1
  765. package/dist/webcomponents/p-DcPNd9_D.js +0 -1
  766. package/dist/webcomponents/p-DfKxeSrC.js +0 -1
  767. package/dist/webcomponents/p-Dkujm7_O.js +0 -1
  768. package/dist/webcomponents/p-Dv1Fyrn3.js +0 -1
  769. package/dist/webcomponents/p-DxVCqvBt.js +0 -1
  770. package/dist/webcomponents/p-DzWLLt4t.js +0 -1
  771. package/dist/webcomponents/p-LO0pl3n2.js +0 -1
  772. package/dist/webcomponents/p-PdQT2QcR.js +0 -1
  773. package/dist/webcomponents/p-a2817869.entry.js +0 -1
  774. package/dist/webcomponents/p-a291a90c.entry.js +0 -1
  775. package/dist/webcomponents/p-b0bc03e6.entry.js +0 -1
  776. package/dist/webcomponents/p-c2cb70c8.entry.js +0 -1
  777. package/dist/webcomponents/p-c540fe9d.entry.js +0 -1
  778. package/dist/webcomponents/p-c6093716.entry.js +0 -1
  779. package/dist/webcomponents/p-c6e43493.entry.js +0 -1
  780. package/dist/webcomponents/p-c780cc91.entry.js +0 -1
  781. package/dist/webcomponents/p-c9598246.entry.js +0 -1
  782. package/dist/webcomponents/p-c972a599.entry.js +0 -1
  783. package/dist/webcomponents/p-cc1d8649.entry.js +0 -1
  784. package/dist/webcomponents/p-ce4895ca.entry.js +0 -1
  785. package/dist/webcomponents/p-ce67282b.entry.js +0 -1
  786. package/dist/webcomponents/p-cef5c6e9.entry.js +0 -1
  787. package/dist/webcomponents/p-d21fa0c9.entry.js +0 -1
  788. package/dist/webcomponents/p-d236f152.entry.js +0 -1
  789. package/dist/webcomponents/p-d6ac11fc.entry.js +0 -1
  790. package/dist/webcomponents/p-e55ce6ad.entry.js +0 -1
  791. package/dist/webcomponents/p-f02bd076.entry.js +0 -1
  792. package/dist/webcomponents/p-lPeK9y_X.js +0 -1
  793. package/dist/webcomponents/p-sCHf--Vc.js +0 -1
@@ -0,0 +1,20 @@
1
+ import{r as t,c as i,h as e,H as s}from"./p-DOjVAAtq.js";import{f as n,m as r}from"./p-Bgnhf5c9.js";import{E as o}from"./p-CH8Y3GSr.js";import{S as h}from"./p-h5pyZngT.js";import"./p-HXpYMWUU.js";import"./p-xDbRW9xn.js";
2
+ /*!
3
+ * @kurkle/color v0.3.4
4
+ * https://github.com/kurkle/color#readme
5
+ * (c) 2024 Jukka Kurkela
6
+ * Released under the MIT License
7
+ */function a(t){return t+.5|0}const c=(t,i,e)=>Math.max(Math.min(t,e),i);function l(t){return c(a(2.55*t),0,255)}function u(t){return c(a(255*t),0,255)}function f(t){return c(a(t/2.55)/100,0,1)}function d(t){return c(a(100*t),0,100)}const b={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},g=[..."0123456789ABCDEF"],p=t=>g[15&t],m=t=>g[(240&t)>>4]+g[15&t],x=t=>(240&t)>>4==(15&t);const v=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function y(t,i,e){const s=i*Math.min(e,1-e),n=(i,n=(i+t/30)%12)=>e-s*Math.max(Math.min(n-3,9-n,1),-1);return[n(0),n(8),n(4)]}function M(t,i,e){const s=(s,n=(s+t/60)%6)=>e-e*i*Math.max(Math.min(n,4-n,1),0);return[s(5),s(3),s(1)]}function w(t,i,e){const s=y(t,1,.5);let n;for(i+e>1&&(n=1/(i+e),i*=n,e*=n),n=0;n<3;n++)s[n]*=1-i-e,s[n]+=i;return s}function _(t){const i=t.r/255,e=t.g/255,s=t.b/255,n=Math.max(i,e,s),r=Math.min(i,e,s),o=(n+r)/2;let h,a,c;return n!==r&&(c=n-r,a=o>.5?c/(2-n-r):c/(n+r),h=function(t,i,e,s,n){return t===n?(i-e)/s+(i<e?6:0):i===n?(e-t)/s+2:(t-i)/s+4}(i,e,s,c,n),h=60*h+.5),[0|h,a||0,o]}function k(t,i,e,s){return(Array.isArray(i)?t(i[0],i[1],i[2]):t(i,e,s)).map(u)}function O(t,i,e){return k(y,t,i,e)}function S(t){return(t%360+360)%360}const A={x:"dark",Z:"light",Y:"re",X:"blu",W:"gr",V:"medium",U:"slate",A:"ee",T:"ol",S:"or",B:"ra",C:"lateg",D:"ights",R:"in",Q:"turquois",E:"hi",P:"ro",O:"al",N:"le",M:"de",L:"yello",F:"en",K:"ch",G:"arks",H:"ea",I:"ightg",J:"wh"},D={OiceXe:"f0f8ff",antiquewEte:"faebd7",aqua:"ffff",aquamarRe:"7fffd4",azuY:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"0",blanKedOmond:"ffebcd",Xe:"ff",XeviTet:"8a2be2",bPwn:"a52a2a",burlywood:"deb887",caMtXe:"5f9ea0",KartYuse:"7fff00",KocTate:"d2691e",cSO:"ff7f50",cSnflowerXe:"6495ed",cSnsilk:"fff8dc",crimson:"dc143c",cyan:"ffff",xXe:"8b",xcyan:"8b8b",xgTMnPd:"b8860b",xWay:"a9a9a9",xgYF:"6400",xgYy:"a9a9a9",xkhaki:"bdb76b",xmagFta:"8b008b",xTivegYF:"556b2f",xSange:"ff8c00",xScEd:"9932cc",xYd:"8b0000",xsOmon:"e9967a",xsHgYF:"8fbc8f",xUXe:"483d8b",xUWay:"2f4f4f",xUgYy:"2f4f4f",xQe:"ced1",xviTet:"9400d3",dAppRk:"ff1493",dApskyXe:"bfff",dimWay:"696969",dimgYy:"696969",dodgerXe:"1e90ff",fiYbrick:"b22222",flSOwEte:"fffaf0",foYstWAn:"228b22",fuKsia:"ff00ff",gaRsbSo:"dcdcdc",ghostwEte:"f8f8ff",gTd:"ffd700",gTMnPd:"daa520",Way:"808080",gYF:"8000",gYFLw:"adff2f",gYy:"808080",honeyMw:"f0fff0",hotpRk:"ff69b4",RdianYd:"cd5c5c",Rdigo:"4b0082",ivSy:"fffff0",khaki:"f0e68c",lavFMr:"e6e6fa",lavFMrXsh:"fff0f5",lawngYF:"7cfc00",NmoncEffon:"fffacd",ZXe:"add8e6",ZcSO:"f08080",Zcyan:"e0ffff",ZgTMnPdLw:"fafad2",ZWay:"d3d3d3",ZgYF:"90ee90",ZgYy:"d3d3d3",ZpRk:"ffb6c1",ZsOmon:"ffa07a",ZsHgYF:"20b2aa",ZskyXe:"87cefa",ZUWay:"778899",ZUgYy:"778899",ZstAlXe:"b0c4de",ZLw:"ffffe0",lime:"ff00",limegYF:"32cd32",lRF:"faf0e6",magFta:"ff00ff",maPon:"800000",VaquamarRe:"66cdaa",VXe:"cd",VScEd:"ba55d3",VpurpN:"9370db",VsHgYF:"3cb371",VUXe:"7b68ee",VsprRggYF:"fa9a",VQe:"48d1cc",VviTetYd:"c71585",midnightXe:"191970",mRtcYam:"f5fffa",mistyPse:"ffe4e1",moccasR:"ffe4b5",navajowEte:"ffdead",navy:"80",Tdlace:"fdf5e6",Tive:"808000",TivedBb:"6b8e23",Sange:"ffa500",SangeYd:"ff4500",ScEd:"da70d6",pOegTMnPd:"eee8aa",pOegYF:"98fb98",pOeQe:"afeeee",pOeviTetYd:"db7093",papayawEp:"ffefd5",pHKpuff:"ffdab9",peru:"cd853f",pRk:"ffc0cb",plum:"dda0dd",powMrXe:"b0e0e6",purpN:"800080",YbeccapurpN:"663399",Yd:"ff0000",Psybrown:"bc8f8f",PyOXe:"4169e1",saddNbPwn:"8b4513",sOmon:"fa8072",sandybPwn:"f4a460",sHgYF:"2e8b57",sHshell:"fff5ee",siFna:"a0522d",silver:"c0c0c0",skyXe:"87ceeb",UXe:"6a5acd",UWay:"708090",UgYy:"708090",snow:"fffafa",sprRggYF:"ff7f",stAlXe:"4682b4",tan:"d2b48c",teO:"8080",tEstN:"d8bfd8",tomato:"ff6347",Qe:"40e0d0",viTet:"ee82ee",JHt:"f5deb3",wEte:"ffffff",wEtesmoke:"f5f5f5",Lw:"ffff00",LwgYF:"9acd32"};let j;const R=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/,C=t=>t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055,E=t=>t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4);function L(t,i,e){if(t){let s=_(t);s[i]=Math.max(0,Math.min(s[i]+s[i]*e,0===i?360:1)),s=O(s),t.r=s[0],t.g=s[1],t.b=s[2]}}function P(t,i){return t?Object.assign(i||{},t):t}function T(t){var i={r:0,g:0,b:0,a:255};return Array.isArray(t)?t.length>=3&&(i={r:t[0],g:t[1],b:t[2],a:255},t.length>3&&(i.a=u(t[3]))):(i=P(t,{r:0,g:0,b:0,a:1})).a=u(i.a),i}function I(t){return"r"===t.charAt(0)?function(t){const i=R.exec(t);let e,s,n,r=255;if(i){if(i[7]!==e){const t=+i[7];r=i[8]?l(t):c(255*t,0,255)}return e=+i[1],s=+i[3],n=+i[5],e=255&(i[2]?l(e):c(e,0,255)),s=255&(i[4]?l(s):c(s,0,255)),n=255&(i[6]?l(n):c(n,0,255)),{r:e,g:s,b:n,a:r}}}(t):function(t){const i=v.exec(t);let e,s=255;if(!i)return;i[5]!==e&&(s=i[6]?l(+i[5]):u(+i[5]));const n=S(+i[2]),r=+i[3]/100,o=+i[4]/100;return e="hwb"===i[1]?function(t,i,e){return k(w,t,i,e)}(n,r,o):"hsv"===i[1]?function(t,i,e){return k(M,t,i,e)}(n,r,o):O(n,r,o),{r:e[0],g:e[1],b:e[2],a:s}}(t)}class F{constructor(t){if(t instanceof F)return t;const i=typeof t;let e;var s,n,r;"object"===i?e=T(t):"string"===i&&(r=(s=t).length,"#"===s[0]&&(4===r||5===r?n={r:255&17*b[s[1]],g:255&17*b[s[2]],b:255&17*b[s[3]],a:5===r?17*b[s[4]]:255}:7!==r&&9!==r||(n={r:b[s[1]]<<4|b[s[2]],g:b[s[3]]<<4|b[s[4]],b:b[s[5]]<<4|b[s[6]],a:9===r?b[s[7]]<<4|b[s[8]]:255})),e=n||function(t){j||(j=function(){const t={},i=Object.keys(D),e=Object.keys(A);let s,n,r,o,h;for(s=0;s<i.length;s++){for(o=h=i[s],n=0;n<e.length;n++)r=e[n],h=h.replace(r,A[r]);r=parseInt(D[o],16),t[h]=[r>>16&255,r>>8&255,255&r]}return t}(),j.transparent=[0,0,0,0]);const i=j[t.toLowerCase()];return i&&{r:i[0],g:i[1],b:i[2],a:4===i.length?i[3]:255}}(t)||I(t)),this._rgb=e,this._valid=!!e}get valid(){return this._valid}get rgb(){var t=P(this._rgb);return t&&(t.a=f(t.a)),t}set rgb(t){this._rgb=T(t)}rgbString(){return this._valid?(t=this._rgb)&&(t.a<255?`rgba(${t.r}, ${t.g}, ${t.b}, ${f(t.a)})`:`rgb(${t.r}, ${t.g}, ${t.b})`):void 0;var t}hexString(){return this._valid?(i=(t=>x(t.r)&&x(t.g)&&x(t.b)&&x(t.a))(t=this._rgb)?p:m,t?"#"+i(t.r)+i(t.g)+i(t.b)+((t,i)=>t<255?i(t):"")(t.a,i):void 0):void 0;var t,i}hslString(){return this._valid?function(t){if(!t)return;const i=_(t),e=i[0],s=d(i[1]),n=d(i[2]);return t.a<255?`hsla(${e}, ${s}%, ${n}%, ${f(t.a)})`:`hsl(${e}, ${s}%, ${n}%)`}(this._rgb):void 0}mix(t,i){if(t){const e=this.rgb,s=t.rgb;let n;const r=i===n?.5:i,o=2*r-1,h=e.a-s.a,a=((o*h==-1?o:(o+h)/(1+o*h))+1)/2;n=1-a,e.r=255&a*e.r+n*s.r+.5,e.g=255&a*e.g+n*s.g+.5,e.b=255&a*e.b+n*s.b+.5,e.a=r*e.a+(1-r)*s.a,this.rgb=e}return this}interpolate(t,i){return t&&(this._rgb=function(t,i,e){const s=E(f(t.r)),n=E(f(t.g)),r=E(f(t.b));return{r:u(C(s+e*(E(f(i.r))-s))),g:u(C(n+e*(E(f(i.g))-n))),b:u(C(r+e*(E(f(i.b))-r))),a:t.a+e*(i.a-t.a)}}(this._rgb,t._rgb,i)),this}clone(){return new F(this.rgb)}alpha(t){return this._rgb.a=u(t),this}clearer(t){return this._rgb.a*=1-t,this}greyscale(){const t=this._rgb,i=a(.3*t.r+.59*t.g+.11*t.b);return t.r=t.g=t.b=i,this}opaquer(t){return this._rgb.a*=1+t,this}negate(){const t=this._rgb;return t.r=255-t.r,t.g=255-t.g,t.b=255-t.b,this}lighten(t){return L(this._rgb,2,t),this}darken(t){return L(this._rgb,2,-t),this}saturate(t){return L(this._rgb,1,t),this}desaturate(t){return L(this._rgb,1,-t),this}rotate(t){return function(t,i){var e=_(t);e[0]=S(e[0]+i),e=O(e),t.r=e[0],t.g=e[1],t.b=e[2]}(this._rgb,t),this}}
8
+ /*!
9
+ * Chart.js v4.5.1
10
+ * https://www.chartjs.org
11
+ * (c) 2025 Chart.js Contributors
12
+ * Released under the MIT License
13
+ */function B(){}const W=(()=>{let t=0;return()=>t++})();function N(t){return null==t}function z(t){if(Array.isArray&&Array.isArray(t))return!0;const i=Object.prototype.toString.call(t);return"[object"===i.slice(0,7)&&"Array]"===i.slice(-6)}function H(t){return null!==t&&"[object Object]"===Object.prototype.toString.call(t)}function $(t){return("number"==typeof t||t instanceof Number)&&isFinite(+t)}function Y(t,i){return $(t)?t:i}function V(t,i){return void 0===t?i:t}const X=(t,i)=>"string"==typeof t&&t.endsWith("%")?parseFloat(t)/100*i:+t;function U(t,i,e){if(t&&"function"==typeof t.call)return t.apply(e,i)}function Z(t,i,e){let s,n,r;if(z(t))for(n=t.length,s=0;s<n;s++)i.call(e,t[s],s);else if(H(t))for(r=Object.keys(t),n=r.length,s=0;s<n;s++)i.call(e,t[r[s]],r[s])}function K(t,i){let e,s,n,r;if(!t||!i||t.length!==i.length)return!1;for(e=0,s=t.length;e<s;++e)if(n=t[e],r=i[e],n.datasetIndex!==r.datasetIndex||n.index!==r.index)return!1;return!0}function Q(t){if(z(t))return t.map(Q);if(H(t)){const i=Object.create(null),e=Object.keys(t),s=e.length;let n=0;for(;n<s;++n)i[e[n]]=Q(t[e[n]]);return i}return t}function q(t){return-1===["__proto__","prototype","constructor"].indexOf(t)}function G(t,i,e,s){if(!q(t))return;const n=i[t],r=e[t];H(n)&&H(r)?J(n,r,s):i[t]=Q(r)}function J(t,i,e){const s=z(i)?i:[i],n=s.length;if(!H(t))return t;const r=(e=e||{}).merger||G;let o;for(let i=0;i<n;++i){if(o=s[i],!H(o))continue;const n=Object.keys(o);for(let i=0,s=n.length;i<s;++i)r(n[i],t,o,e)}return t}function tt(t,i){return J(t,i,{merger:it})}function it(t,i,e){if(!q(t))return;const s=i[t],n=e[t];H(s)&&H(n)?tt(s,n):Object.prototype.hasOwnProperty.call(i,t)||(i[t]=Q(n))}const et={"":t=>t,x:t=>t.x,y:t=>t.y};function st(t,i){const e=et[i]||(et[i]=function(t){const i=function(t){const i=t.split("."),e=[];let s="";for(const t of i)s+=t,s.endsWith("\\")?s=s.slice(0,-1)+".":(e.push(s),s="");return e}(t);return t=>{for(const e of i){if(""===e)break;t=t&&t[e]}return t}}(i));return e(t)}function nt(t){return t.charAt(0).toUpperCase()+t.slice(1)}const rt=t=>void 0!==t,ot=t=>"function"==typeof t,ht=(t,i)=>{if(t.size!==i.size)return!1;for(const e of t)if(!i.has(e))return!1;return!0},at=Math.PI,ct=2*at,lt=Number.POSITIVE_INFINITY,ut=at/180,ft=at/2,dt=at/4,bt=2*at/3,gt=Math.log10,pt=Math.sign;function mt(t,i,e){return Math.abs(t-i)<e}function xt(t){const i=Math.round(t);t=mt(t,i,t/1e3)?i:t;const e=Math.pow(10,Math.floor(gt(t))),s=t/e;return(s<=1?1:s<=2?2:s<=5?5:10)*e}function vt(t){return!function(t){return"symbol"==typeof t||"object"==typeof t&&null!==t&&!(Symbol.toPrimitive in t||"toString"in t||"valueOf"in t)}(t)&&!isNaN(parseFloat(t))&&isFinite(t)}function yt(t){return t*(at/180)}function Mt(t){if(!$(t))return;let i=1,e=0;for(;Math.round(t*i)/i!==t;)i*=10,e++;return e}function wt(t){return(t%ct+ct)%ct}function _t(t,i,e,s){const n=wt(t),r=wt(i),o=wt(e),h=wt(r-n),a=wt(o-n),c=wt(n-r),l=wt(n-o);return n===r||n===o||s&&r===o||h>a&&c<l}function kt(t,i,e){return Math.max(i,Math.min(e,t))}function Ot(t,i,e,s=1e-6){return t>=Math.min(i,e)-s&&t<=Math.max(i,e)+s}function St(t,i,e){e=e||(e=>t[e]<i);let s,n=t.length-1,r=0;for(;n-r>1;)s=r+n>>1,e(s)?r=s:n=s;return{lo:r,hi:n}}const At=(t,i,e,s)=>St(t,e,s?s=>{const n=t[s][i];return n<e||n===e&&t[s+1][i]===e}:s=>t[s][i]<e),Dt=(t,i,e)=>St(t,e,(s=>t[s][i]>=e)),jt=["push","pop","shift","splice","unshift"];function Rt(t,i){const e=t._chartjs;if(!e)return;const s=e.listeners,n=s.indexOf(i);-1!==n&&s.splice(n,1),s.length>0||(jt.forEach((i=>{delete t[i]})),delete t._chartjs)}const Ct="undefined"==typeof window?function(t){return t()}:window.requestAnimationFrame;function Et(t,i){let e=[],s=!1;return function(...n){e=n,s||(s=!0,Ct.call(window,(()=>{s=!1,t.apply(i,e)})))}}const Lt=t=>"start"===t?"left":"end"===t?"right":"center",Pt=(t,i,e)=>"start"===t?i:"end"===t?e:(i+e)/2,Tt=t=>0===t||1===t,It=(t,i,e)=>-Math.pow(2,10*(t-=1))*Math.sin((t-i)*ct/e),Ft=(t,i,e)=>Math.pow(2,-10*t)*Math.sin((t-i)*ct/e)+1,Bt={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>-t*(t-2),easeInOutQuad:t=>(t/=.5)<1?.5*t*t:-.5*(--t*(t-2)-1),easeInCubic:t=>t*t*t,easeOutCubic:t=>(t-=1)*t*t+1,easeInOutCubic:t=>(t/=.5)<1?.5*t*t*t:.5*((t-=2)*t*t+2),easeInQuart:t=>t*t*t*t,easeOutQuart:t=>-((t-=1)*t*t*t-1),easeInOutQuart:t=>(t/=.5)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2),easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>(t-=1)*t*t*t*t+1,easeInOutQuint:t=>(t/=.5)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2),easeInSine:t=>1-Math.cos(t*ft),easeOutSine:t=>Math.sin(t*ft),easeInOutSine:t=>-.5*(Math.cos(at*t)-1),easeInExpo:t=>0===t?0:Math.pow(2,10*(t-1)),easeOutExpo:t=>1===t?1:1-Math.pow(2,-10*t),easeInOutExpo:t=>Tt(t)?t:t<.5?.5*Math.pow(2,10*(2*t-1)):.5*(2-Math.pow(2,-10*(2*t-1))),easeInCirc:t=>t>=1?t:-(Math.sqrt(1-t*t)-1),easeOutCirc:t=>Math.sqrt(1-(t-=1)*t),easeInOutCirc:t=>(t/=.5)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1),easeInElastic:t=>Tt(t)?t:It(t,.075,.3),easeOutElastic:t=>Tt(t)?t:Ft(t,.075,.3),easeInOutElastic(t){const i=.1125;return Tt(t)?t:t<.5?.5*It(2*t,i,.45):.5+.5*Ft(2*t-1,i,.45)},easeInBack(t){const i=1.70158;return t*t*((i+1)*t-i)},easeOutBack(t){const i=1.70158;return(t-=1)*t*((i+1)*t+i)+1},easeInOutBack(t){let i=1.70158;return(t/=.5)<1?t*t*((1+(i*=1.525))*t-i)*.5:.5*((t-=2)*t*((1+(i*=1.525))*t+i)+2)},easeInBounce:t=>1-Bt.easeOutBounce(1-t),easeOutBounce(t){const i=7.5625,e=2.75;return t<1/e?i*t*t:t<2/e?i*(t-=1.5/e)*t+.75:t<2.5/e?i*(t-=2.25/e)*t+.9375:i*(t-=2.625/e)*t+.984375},easeInOutBounce:t=>t<.5?.5*Bt.easeInBounce(2*t):.5*Bt.easeOutBounce(2*t-1)+.5};function Wt(t){if(t&&"object"==typeof t){const i=t.toString();return"[object CanvasPattern]"===i||"[object CanvasGradient]"===i}return!1}function Nt(t){return Wt(t)?t:new F(t)}function zt(t){return Wt(t)?t:new F(t).saturate(.5).darken(.1).hexString()}const Ht=["x","y","borderWidth","radius","tension"],$t=["color","borderColor","backgroundColor"],Yt=new Map;function Vt(t,i,e){return function(t,i){i=i||{};const e=t+JSON.stringify(i);let s=Yt.get(e);return s||(s=new Intl.NumberFormat(t,i),Yt.set(e,s)),s}(i,e).format(t)}var Xt={formatters:{values:t=>z(t)?t:""+t,numeric(t,i,e){if(0===t)return"0";const s=this.chart.options.locale;let n,r=t;if(e.length>1){const i=Math.max(Math.abs(e[0].value),Math.abs(e[e.length-1].value));(i<1e-4||i>1e15)&&(n="scientific"),r=function(t,i){let e=i.length>3?i[2].value-i[1].value:i[1].value-i[0].value;return Math.abs(e)>=1&&t!==Math.floor(t)&&(e=t-Math.floor(t)),e}(t,e)}const o=gt(Math.abs(r)),h=isNaN(o)?1:Math.max(Math.min(-1*Math.floor(o),20),0),a={notation:n,minimumFractionDigits:h,maximumFractionDigits:h};return Object.assign(a,this.options.ticks.format),Vt(t,s,a)}}};const Ut=Object.create(null),Zt=Object.create(null);function Kt(t,i){if(!i)return t;const e=i.split(".");for(let i=0,s=e.length;i<s;++i){const s=e[i];t=t[s]||(t[s]=Object.create(null))}return t}function Qt(t,i,e){return"string"==typeof i?J(Kt(t,i),e):J(Kt(t,""),i)}class qt{constructor(t,i){this.animation=void 0,this.backgroundColor="rgba(0,0,0,0.1)",this.borderColor="rgba(0,0,0,0.1)",this.color="#666",this.datasets={},this.devicePixelRatio=t=>t.chart.platform.getDevicePixelRatio(),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=(t,i)=>zt(i.backgroundColor),this.hoverBorderColor=(t,i)=>zt(i.borderColor),this.hoverColor=(t,i)=>zt(i.color),this.indexAxis="x",this.interaction={mode:"nearest",intersect:!0,includeInvisible:!1},this.maintainAspectRatio=!0,this.onHover=null,this.onClick=null,this.parsing=!0,this.plugins={},this.responsive=!0,this.scale=void 0,this.scales={},this.showLine=!0,this.drawActiveElementsOnTop=!0,this.describe(t),this.apply(i)}set(t,i){return Qt(this,t,i)}get(t){return Kt(this,t)}describe(t,i){return Qt(Zt,t,i)}override(t,i){return Qt(Ut,t,i)}route(t,i,e,s){const n=Kt(this,t),r=Kt(this,e),o="_"+i;Object.defineProperties(n,{[o]:{value:n[i],writable:!0},[i]:{enumerable:!0,get(){const t=this[o],i=r[s];return H(t)?Object.assign({},i,t):V(t,i)},set(t){this[o]=t}}})}apply(t){t.forEach((t=>t(this)))}}var Gt=new qt({_scriptable:t=>!t.startsWith("on"),_indexable:t=>"events"!==t,hover:{_fallback:"interaction"},interaction:{_scriptable:!1,_indexable:!1}},[function(t){t.set("animation",{delay:void 0,duration:1e3,easing:"easeOutQuart",fn:void 0,from:void 0,loop:void 0,to:void 0,type:void 0}),t.describe("animation",{_fallback:!1,_indexable:!1,_scriptable:t=>"onProgress"!==t&&"onComplete"!==t&&"fn"!==t}),t.set("animations",{colors:{type:"color",properties:$t},numbers:{type:"number",properties:Ht}}),t.describe("animations",{_fallback:"animation"}),t.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:t=>0|t}}}})},function(t){t.set("layout",{autoPadding:!0,padding:{top:0,right:0,bottom:0,left:0}})},function(t){t.set("scale",{display:!0,offset:!1,reverse:!1,beginAtZero:!1,bounds:"ticks",clip:!0,grace:0,grid:{display:!0,lineWidth:1,drawOnChartArea:!0,drawTicks:!0,tickLength:8,tickWidth:(t,i)=>i.lineWidth,tickColor:(t,i)=>i.color,offset:!1},border:{display:!0,dash:[],dashOffset:0,width:1},title:{display:!1,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:!1,textStrokeWidth:0,textStrokeColor:"",padding:3,display:!0,autoSkip:!0,autoSkipPadding:3,labelOffset:0,callback:Xt.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:!1,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}}),t.route("scale.ticks","color","","color"),t.route("scale.grid","color","","borderColor"),t.route("scale.border","color","","borderColor"),t.route("scale.title","color","","color"),t.describe("scale",{_fallback:!1,_scriptable:t=>!t.startsWith("before")&&!t.startsWith("after")&&"callback"!==t&&"parser"!==t,_indexable:t=>"borderDash"!==t&&"tickBorderDash"!==t&&"dash"!==t}),t.describe("scales",{_fallback:"scale"}),t.describe("scale.ticks",{_scriptable:t=>"backdropPadding"!==t&&"callback"!==t,_indexable:t=>"backdropPadding"!==t})}]);function Jt(t,i,e,s,n){let r=i[n];return r||(r=i[n]=t.measureText(n).width,e.push(n)),r>s&&(s=r),s}function ti(t,i,e){const s=t.currentDevicePixelRatio,n=0!==e?Math.max(e/2,.5):0;return Math.round((i-n)*s)/s+n}function ii(t,i){(i||t)&&((i=i||t.getContext("2d")).save(),i.resetTransform(),i.clearRect(0,0,t.width,t.height),i.restore())}function ei(t,i,e,s){si(t,i,e,s,null)}function si(t,i,e,s,n){let r,o,h,a,c,l,u,f;const d=i.pointStyle,b=i.rotation,g=i.radius;let p=(b||0)*ut;if(d&&"object"==typeof d&&(r=d.toString(),"[object HTMLImageElement]"===r||"[object HTMLCanvasElement]"===r))return t.save(),t.translate(e,s),t.rotate(p),t.drawImage(d,-d.width/2,-d.height/2,d.width,d.height),void t.restore();if(!(isNaN(g)||g<=0)){switch(t.beginPath(),d){default:n?t.ellipse(e,s,n/2,g,0,0,ct):t.arc(e,s,g,0,ct),t.closePath();break;case"triangle":l=n?n/2:g,t.moveTo(e+Math.sin(p)*l,s-Math.cos(p)*g),p+=bt,t.lineTo(e+Math.sin(p)*l,s-Math.cos(p)*g),p+=bt,t.lineTo(e+Math.sin(p)*l,s-Math.cos(p)*g),t.closePath();break;case"rectRounded":c=.516*g,a=g-c,o=Math.cos(p+dt)*a,u=Math.cos(p+dt)*(n?n/2-c:a),h=Math.sin(p+dt)*a,f=Math.sin(p+dt)*(n?n/2-c:a),t.arc(e-u,s-h,c,p-at,p-ft),t.arc(e+f,s-o,c,p-ft,p),t.arc(e+u,s+h,c,p,p+ft),t.arc(e-f,s+o,c,p+ft,p+at),t.closePath();break;case"rect":if(!b){a=Math.SQRT1_2*g,l=n?n/2:a,t.rect(e-l,s-a,2*l,2*a);break}p+=dt;case"rectRot":u=Math.cos(p)*(n?n/2:g),o=Math.cos(p)*g,h=Math.sin(p)*g,f=Math.sin(p)*(n?n/2:g),t.moveTo(e-u,s-h),t.lineTo(e+f,s-o),t.lineTo(e+u,s+h),t.lineTo(e-f,s+o),t.closePath();break;case"crossRot":p+=dt;case"cross":u=Math.cos(p)*(n?n/2:g),o=Math.cos(p)*g,h=Math.sin(p)*g,f=Math.sin(p)*(n?n/2:g),t.moveTo(e-u,s-h),t.lineTo(e+u,s+h),t.moveTo(e+f,s-o),t.lineTo(e-f,s+o);break;case"star":u=Math.cos(p)*(n?n/2:g),o=Math.cos(p)*g,h=Math.sin(p)*g,f=Math.sin(p)*(n?n/2:g),t.moveTo(e-u,s-h),t.lineTo(e+u,s+h),t.moveTo(e+f,s-o),t.lineTo(e-f,s+o),p+=dt,u=Math.cos(p)*(n?n/2:g),o=Math.cos(p)*g,h=Math.sin(p)*g,f=Math.sin(p)*(n?n/2:g),t.moveTo(e-u,s-h),t.lineTo(e+u,s+h),t.moveTo(e+f,s-o),t.lineTo(e-f,s+o);break;case"line":o=n?n/2:Math.cos(p)*g,h=Math.sin(p)*g,t.moveTo(e-o,s-h),t.lineTo(e+o,s+h);break;case"dash":t.moveTo(e,s),t.lineTo(e+Math.cos(p)*(n?n/2:g),s+Math.sin(p)*g);break;case!1:t.closePath()}t.fill(),i.borderWidth>0&&t.stroke()}}function ni(t,i,e){return e=e||.5,!i||t&&t.x>i.left-e&&t.x<i.right+e&&t.y>i.top-e&&t.y<i.bottom+e}function ri(t,i){t.save(),t.beginPath(),t.rect(i.left,i.top,i.right-i.left,i.bottom-i.top),t.clip()}function oi(t){t.restore()}function hi(t,i,e,s,n){if(n.strikethrough||n.underline){const r=t.measureText(s),o=i-r.actualBoundingBoxLeft,h=i+r.actualBoundingBoxRight,a=e+r.actualBoundingBoxDescent,c=n.strikethrough?(e-r.actualBoundingBoxAscent+a)/2:a;t.strokeStyle=t.fillStyle,t.beginPath(),t.lineWidth=n.decorationWidth||2,t.moveTo(o,c),t.lineTo(h,c),t.stroke()}}function ai(t,i){const e=t.fillStyle;t.fillStyle=i.color,t.fillRect(i.left,i.top,i.width,i.height),t.fillStyle=e}function ci(t,i,e,s,n,r={}){const o=z(i)?i:[i],h=r.strokeWidth>0&&""!==r.strokeColor;let a,c;for(t.save(),t.font=n.string,function(t,i){i.translation&&t.translate(i.translation[0],i.translation[1]),N(i.rotation)||t.rotate(i.rotation),i.color&&(t.fillStyle=i.color),i.textAlign&&(t.textAlign=i.textAlign),i.textBaseline&&(t.textBaseline=i.textBaseline)}(t,r),a=0;a<o.length;++a)c=o[a],r.backdrop&&ai(t,r.backdrop),h&&(r.strokeColor&&(t.strokeStyle=r.strokeColor),N(r.strokeWidth)||(t.lineWidth=r.strokeWidth),t.strokeText(c,e,s,r.maxWidth)),t.fillText(c,e,s,r.maxWidth),hi(t,e,s,c,r),s+=Number(n.lineHeight);t.restore()}function li(t,i){const{x:e,y:s,w:n,h:r,radius:o}=i;t.arc(e+o.topLeft,s+o.topLeft,o.topLeft,1.5*at,at,!0),t.lineTo(e,s+r-o.bottomLeft),t.arc(e+o.bottomLeft,s+r-o.bottomLeft,o.bottomLeft,at,ft,!0),t.lineTo(e+n-o.bottomRight,s+r),t.arc(e+n-o.bottomRight,s+r-o.bottomRight,o.bottomRight,ft,0,!0),t.lineTo(e+n,s+o.topRight),t.arc(e+n-o.topRight,s+o.topRight,o.topRight,0,-ft,!0),t.lineTo(e+o.topLeft,s)}const ui=/^(normal|(\d+(?:\.\d+)?)(px|em|%)?)$/,fi=/^(normal|italic|initial|inherit|unset|(oblique( -?[0-9]?[0-9]deg)?))$/;function di(t,i){const e=(""+t).match(ui);if(!e||"normal"===e[1])return 1.2*i;switch(t=+e[2],e[3]){case"px":return t;case"%":t/=100}return i*t}function bi(t,i){const e={},s=H(i),n=s?Object.keys(i):i,r=H(t)?s?e=>V(t[e],t[i[e]]):i=>t[i]:()=>t;for(const t of n)e[t]=+r(t)||0;return e}function gi(t){return bi(t,{top:"y",right:"x",bottom:"y",left:"x"})}function pi(t){return bi(t,["topLeft","topRight","bottomLeft","bottomRight"])}function mi(t){const i=gi(t);return i.width=i.left+i.right,i.height=i.top+i.bottom,i}function xi(t,i){let e=V((t=t||{}).size,(i=i||Gt.font).size);"string"==typeof e&&(e=parseInt(e,10));let s=V(t.style,i.style);s&&!(""+s).match(fi)&&(console.warn('Invalid font style specified: "'+s+'"'),s=void 0);const n={family:V(t.family,i.family),lineHeight:di(V(t.lineHeight,i.lineHeight),e),size:e,style:s,weight:V(t.weight,i.weight),string:""};return n.string=function(t){return!t||N(t.size)||N(t.family)?null:(t.style?t.style+" ":"")+(t.weight?t.weight+" ":"")+t.size+"px "+t.family}(n),n}function vi(t){let i,e,s;for(i=0,e=t.length;i<e;++i)if(s=t[i],void 0!==s&&void 0!==s)return s}function yi(t,i){return Object.assign(Object.create(t),i)}function Mi(t,i=[""],e,s,n=()=>t[0]){const r=e||t;void 0===s&&(s=Ei("_fallback",t));const o={[Symbol.toStringTag]:"Object",_cacheable:!0,_scopes:t,_rootScopes:r,_fallback:s,_getTarget:n,override:e=>Mi([e,...t],i,r,s)};return new Proxy(o,{deleteProperty:(i,e)=>(delete i[e],delete i._keys,delete t[0][e],!0),get:(e,s)=>Si(e,s,(()=>function(t,i,e,s){let n;for(const r of i)if(n=Ei(ki(r,t),e),void 0!==n)return Oi(t,n)?Ri(e,s,t,n):n}(s,i,t,e))),getOwnPropertyDescriptor:(t,i)=>Reflect.getOwnPropertyDescriptor(t._scopes[0],i),getPrototypeOf:()=>Reflect.getPrototypeOf(t[0]),has:(t,i)=>Li(t).includes(i),ownKeys:t=>Li(t),set(t,i,e){const s=t._storage||(t._storage=n());return t[i]=s[i]=e,delete t._keys,!0}})}function wi(t,i,e,s){const n={_cacheable:!1,_proxy:t,_context:i,_subProxy:e,_stack:new Set,_descriptors:_i(t,s),setContext:i=>wi(t,i,e,s),override:n=>wi(t.override(n),i,e,s)};return new Proxy(n,{deleteProperty:(i,e)=>(delete i[e],delete t[e],!0),get:(t,i,e)=>Si(t,i,(()=>function(t,i,e){const{_proxy:s,_context:n,_subProxy:r,_descriptors:o}=t;let h=s[i];return ot(h)&&o.isScriptable(i)&&(h=function(t,i,e,s){const{_proxy:n,_context:r,_subProxy:o,_stack:h}=e;if(h.has(t))throw new Error("Recursion detected: "+Array.from(h).join("->")+"->"+t);h.add(t);let a=i(r,o||s);return h.delete(t),Oi(t,a)&&(a=Ri(n._scopes,n,t,a)),a}(i,h,t,e)),z(h)&&h.length&&(h=function(t,i,e,s){const{_proxy:n,_context:r,_subProxy:o,_descriptors:h}=e;if(void 0!==r.index&&s(t))return i[r.index%i.length];if(H(i[0])){const e=i,s=n._scopes.filter((t=>t!==e));i=[];for(const a of e){const e=Ri(s,n,t,a);i.push(wi(e,r,o&&o[t],h))}}return i}(i,h,t,o.isIndexable)),Oi(i,h)&&(h=wi(h,n,r&&r[i],o)),h}(t,i,e))),getOwnPropertyDescriptor:(i,e)=>i._descriptors.allKeys?Reflect.has(t,e)?{enumerable:!0,configurable:!0}:void 0:Reflect.getOwnPropertyDescriptor(t,e),getPrototypeOf:()=>Reflect.getPrototypeOf(t),has:(i,e)=>Reflect.has(t,e),ownKeys:()=>Reflect.ownKeys(t),set:(i,e,s)=>(t[e]=s,delete i[e],!0)})}function _i(t,i={scriptable:!0,indexable:!0}){const{_scriptable:e=i.scriptable,_indexable:s=i.indexable,_allKeys:n=i.allKeys}=t;return{allKeys:n,scriptable:e,indexable:s,isScriptable:ot(e)?e:()=>e,isIndexable:ot(s)?s:()=>s}}const ki=(t,i)=>t?t+nt(i):i,Oi=(t,i)=>H(i)&&"adapters"!==t&&(null===Object.getPrototypeOf(i)||i.constructor===Object);function Si(t,i,e){if(Object.prototype.hasOwnProperty.call(t,i)||"constructor"===i)return t[i];const s=e();return t[i]=s,s}function Ai(t,i,e){return ot(t)?t(i,e):t}const Di=(t,i)=>!0===t?i:"string"==typeof t?st(i,t):void 0;function ji(t,i,e,s,n){for(const r of i){const i=Di(e,r);if(i){t.add(i);const r=Ai(i._fallback,e,n);if(void 0!==r&&r!==e&&r!==s)return r}else if(!1===i&&void 0!==s&&e!==s)return null}return!1}function Ri(t,i,e,s){const n=i._rootScopes,r=Ai(i._fallback,e,s),o=[...t,...n],h=new Set;h.add(s);let a=Ci(h,o,e,r||e,s);return null!==a&&(void 0===r||r===e||(a=Ci(h,o,r,a,s),null!==a))&&Mi(Array.from(h),[""],n,r,(()=>function(t,i,e){const s=t._getTarget();i in s||(s[i]={});const n=s[i];return z(n)&&H(e)?e:n||{}}(i,e,s)))}function Ci(t,i,e,s,n){for(;e;)e=ji(t,i,e,s,n);return e}function Ei(t,i){for(const e of i){if(!e)continue;const i=e[t];if(void 0!==i)return i}}function Li(t){let i=t._keys;return i||(i=t._keys=function(t){const i=new Set;for(const e of t)for(const t of Object.keys(e).filter((t=>!t.startsWith("_"))))i.add(t);return Array.from(i)}(t._scopes)),i}function Pi(t,i,e,s){const{iScale:n}=t,{key:r="r"}=this._parsing,o=new Array(s);let h,a,c,l;for(h=0,a=s;h<a;++h)c=h+e,l=i[c],o[h]={r:n.parse(st(l,r),c)};return o}function Ti(){return"undefined"!=typeof window&&"undefined"!=typeof document}function Ii(t){let i=t.parentNode;return i&&"[object ShadowRoot]"===i.toString()&&(i=i.host),i}function Fi(t,i,e){let s;return"string"==typeof t?(s=parseInt(t,10),-1!==t.indexOf("%")&&(s=s/100*i.parentNode[e])):s=t,s}const Bi=t=>t.ownerDocument.defaultView.getComputedStyle(t,null),Wi=["top","right","bottom","left"];function Ni(t,i,e){const s={};e=e?"-"+e:"";for(let n=0;n<4;n++){const r=Wi[n];s[r]=parseFloat(t[i+"-"+r+e])||0}return s.width=s.left+s.right,s.height=s.top+s.bottom,s}function zi(t,i){if("native"in t)return t;const{canvas:e,currentDevicePixelRatio:s}=i,n=Bi(e),r="border-box"===n.boxSizing,o=Ni(n,"padding"),h=Ni(n,"border","width"),{x:a,y:c,box:l}=function(t,i){const e=t.touches,s=e&&e.length?e[0]:t,{offsetX:n,offsetY:r}=s;let o,h,a=!1;if(((t,i,e)=>(t>0||i>0)&&(!e||!e.shadowRoot))(n,r,t.target))o=n,h=r;else{const t=i.getBoundingClientRect();o=s.clientX-t.left,h=s.clientY-t.top,a=!0}return{x:o,y:h,box:a}}(t,e),u=o.left+(l&&h.left),f=o.top+(l&&h.top);let{width:d,height:b}=i;return r&&(d-=o.width+h.width,b-=o.height+h.height),{x:Math.round((a-u)/d*e.width/s),y:Math.round((c-f)/b*e.height/s)}}const Hi=t=>Math.round(10*t)/10;function $i(t,i,e){const s=i||1,n=Hi(t.height*s),r=Hi(t.width*s);t.height=Hi(t.height),t.width=Hi(t.width);const o=t.canvas;return o.style&&(e||!o.style.height&&!o.style.width)&&(o.style.height=`${t.height}px`,o.style.width=`${t.width}px`),(t.currentDevicePixelRatio!==s||o.height!==n||o.width!==r)&&(t.currentDevicePixelRatio=s,o.height=n,o.width=r,t.ctx.setTransform(s,0,0,s,0,0),!0)}const Yi=function(){let t=!1;try{const i={get passive(){return t=!0,!1}};Ti()&&(window.addEventListener("test",null,i),window.removeEventListener("test",null,i))}catch(t){}return t}();function Vi(t,i){const e=function(t,i){return Bi(t).getPropertyValue(i)}(t,i),s=e&&e.match(/^(\d+)(\.\d+)?px$/);return s?+s[1]:void 0}function Xi(t,i,e){return t?function(t,i){return{x:e=>t+t+i-e,setWidth(t){i=t},textAlign:t=>"center"===t?t:"right"===t?"left":"right",xPlus:(t,i)=>t-i,leftForLtr:(t,i)=>t-i}}(i,e):{x:t=>t,setWidth(t){},textAlign:t=>t,xPlus:(t,i)=>t+i,leftForLtr:t=>t}}function Ui(t,i){let e,s;"ltr"!==i&&"rtl"!==i||(e=t.canvas.style,s=[e.getPropertyValue("direction"),e.getPropertyPriority("direction")],e.setProperty("direction",i,"important"),t.prevTextDirection=s)}function Zi(t,i){void 0!==i&&(delete t.prevTextDirection,t.canvas.style.setProperty("direction",i[0],i[1]))}function Ki(t,i,e){return t.options.clip?t[e]:i[e]}
14
+ /*!
15
+ * Chart.js v4.5.1
16
+ * https://www.chartjs.org
17
+ * (c) 2025 Chart.js Contributors
18
+ * Released under the MIT License
19
+ */
20
+ class Qi{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(t,i,e,s){const n=i.duration;i.listeners[s].forEach((s=>s({chart:t,initial:i.initial,numSteps:n,currentStep:Math.min(e-i.start,n)})))}_refresh(){this._request||(this._running=!0,this._request=Ct.call(window,(()=>{this._update(),this._request=null,this._running&&this._refresh()})))}_update(t=Date.now()){let i=0;this._charts.forEach(((e,s)=>{if(!e.running||!e.items.length)return;const n=e.items;let r,o=n.length-1,h=!1;for(;o>=0;--o)r=n[o],r._active?(r._total>e.duration&&(e.duration=r._total),r.tick(t),h=!0):(n[o]=n[n.length-1],n.pop());h&&(s.draw(),this._notify(s,e,t,"progress")),n.length||(e.running=!1,this._notify(s,e,t,"complete"),e.initial=!1),i+=n.length})),this._lastDate=t,0===i&&(this._running=!1)}_getAnims(t){const i=this._charts;let e=i.get(t);return e||(e={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},i.set(t,e)),e}listen(t,i,e){this._getAnims(t).listeners[i].push(e)}add(t,i){i&&i.length&&this._getAnims(t).items.push(...i)}has(t){return this._getAnims(t).items.length>0}start(t){const i=this._charts.get(t);i&&(i.running=!0,i.start=Date.now(),i.duration=i.items.reduce(((t,i)=>Math.max(t,i._duration)),0),this._refresh())}running(t){if(!this._running)return!1;const i=this._charts.get(t);return!!(i&&i.running&&i.items.length)}stop(t){const i=this._charts.get(t);if(!i||!i.items.length)return;const e=i.items;let s=e.length-1;for(;s>=0;--s)e[s].cancel();i.items=[],this._notify(t,i,Date.now(),"complete")}remove(t){return this._charts.delete(t)}}var qi=new Qi;const Gi="transparent",Ji={boolean:(t,i,e)=>e>.5?i:t,color(t,i,e){const s=Nt(t||Gi),n=s.valid&&Nt(i||Gi);return n&&n.valid?n.mix(s,e).hexString():i},number:(t,i,e)=>t+(i-t)*e};class te{constructor(t,i,e,s){const n=i[e];s=vi([t.to,s,n,t.from]);const r=vi([t.from,n,s]);this._active=!0,this._fn=t.fn||Ji[t.type||typeof r],this._easing=Bt[t.easing]||Bt.linear,this._start=Math.floor(Date.now()+(t.delay||0)),this._duration=this._total=Math.floor(t.duration),this._loop=!!t.loop,this._target=i,this._prop=e,this._from=r,this._to=s,this._promises=void 0}active(){return this._active}update(t,i,e){if(this._active){this._notify(!1);const s=this._target[this._prop],n=e-this._start,r=this._duration-n;this._start=e,this._duration=Math.floor(Math.max(r,t.duration)),this._total+=n,this._loop=!!t.loop,this._to=vi([t.to,i,s,t.from]),this._from=vi([t.from,s,i])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(t){const i=t-this._start,e=this._duration,s=this._prop,n=this._from,r=this._loop,o=this._to;let h;if(this._active=n!==o&&(r||i<e),!this._active)return this._target[s]=o,void this._notify(!0);i<0?this._target[s]=n:(h=i/e%2,h=r&&h>1?2-h:h,h=this._easing(Math.min(1,Math.max(0,h))),this._target[s]=this._fn(n,o,h))}wait(){const t=this._promises||(this._promises=[]);return new Promise(((i,e)=>{t.push({res:i,rej:e})}))}_notify(t){const i=t?"res":"rej",e=this._promises||[];for(let t=0;t<e.length;t++)e[t][i]()}}class ie{constructor(t,i){this._chart=t,this._properties=new Map,this.configure(i)}configure(t){if(!H(t))return;const i=Object.keys(Gt.animation),e=this._properties;Object.getOwnPropertyNames(t).forEach((s=>{const n=t[s];if(!H(n))return;const r={};for(const t of i)r[t]=n[t];(z(n.properties)&&n.properties||[s]).forEach((t=>{t!==s&&e.has(t)||e.set(t,r)}))}))}_animateOptions(t,i){const e=i.options,s=function(t,i){if(!i)return;let e=t.options;if(e)return e.$shared&&(t.options=e=Object.assign({},e,{$shared:!1,$animations:{}})),e;t.options=i}(t,e);if(!s)return[];const n=this._createAnimations(s,e);return e.$shared&&function(t,i){const e=[],s=Object.keys(i);for(let i=0;i<s.length;i++){const n=t[s[i]];n&&n.active()&&e.push(n.wait())}return Promise.all(e)}(t.options.$animations,e).then((()=>{t.options=e}),(()=>{})),n}_createAnimations(t,i){const e=this._properties,s=[],n=t.$animations||(t.$animations={}),r=Object.keys(i),o=Date.now();let h;for(h=r.length-1;h>=0;--h){const a=r[h];if("$"===a.charAt(0))continue;if("options"===a){s.push(...this._animateOptions(t,i));continue}const c=i[a];let l=n[a];const u=e.get(a);if(l){if(u&&l.active()){l.update(u,c,o);continue}l.cancel()}u&&u.duration?(n[a]=l=new te(u,t,a,c),s.push(l)):t[a]=c}return s}update(t,i){if(0===this._properties.size)return void Object.assign(t,i);const e=this._createAnimations(t,i);return e.length?(qi.add(this._chart,e),!0):void 0}}function ee(t,i){const e=t&&t.options||{},s=e.reverse,n=void 0===e.min?i:0,r=void 0===e.max?i:0;return{start:s?r:n,end:s?n:r}}function se(t,i){const e=[],s=t._getSortedDatasetMetas(i);let n,r;for(n=0,r=s.length;n<r;++n)e.push(s[n].index);return e}function ne(t,i,e,s={}){const n=t.keys,r="single"===s.mode;let o,h,a,c;if(null===i)return;let l=!1;for(o=0,h=n.length;o<h;++o){if(a=+n[o],a===e){if(l=!0,s.all)continue;break}c=t.values[a],$(c)&&(r||0===i||pt(i)===pt(c))&&(i+=c)}return l||s.all?i:0}function re(t,i){const e=t&&t.options.stacked;return e||void 0===e&&void 0!==i.stack}function oe(t,i,e){const s=t[i]||(t[i]={});return s[e]||(s[e]={})}function he(t,i,e,s){for(const n of i.getMatchingVisibleMetas(s).reverse()){const i=t[n.index];if(e&&i>0||!e&&i<0)return n.index}return null}function ae(t,i){const{chart:e,_cachedMeta:s}=t,n=e._stacks||(e._stacks={}),{iScale:r,vScale:o,index:h}=s,a=r.axis,c=o.axis,l=function(t,i,e){return`${t.id}.${i.id}.${e.stack||e.type}`}(r,o,s),u=i.length;let f;for(let t=0;t<u;++t){const e=i[t],{[a]:r,[c]:u}=e;f=(e._stacks||(e._stacks={}))[c]=oe(n,l,r),f[h]=u,f._top=he(f,o,!0,s.type),f._bottom=he(f,o,!1,s.type),(f._visualValues||(f._visualValues={}))[h]=u}}function ce(t,i){const e=t.scales;return Object.keys(e).filter((t=>e[t].axis===i)).shift()}function le(t,i){const e=t.controller.index,s=t.vScale&&t.vScale.axis;if(s){i=i||t._parsed;for(const t of i){const i=t._stacks;if(!i||void 0===i[s]||void 0===i[s][e])return;delete i[s][e],void 0!==i[s]._visualValues&&void 0!==i[s]._visualValues[e]&&delete i[s]._visualValues[e]}}}const ue=t=>"reset"===t||"none"===t,fe=(t,i)=>i?t:Object.assign({},t);class de{static defaults={};static datasetElementType=null;static dataElementType=null;constructor(t,i){this.chart=t,this._ctx=t.ctx,this.index=i,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.supportsDecimation=!1,this.$context=void 0,this._syncList=[],this.datasetElementType=new.target.datasetElementType,this.dataElementType=new.target.dataElementType,this.initialize()}initialize(){const t=this._cachedMeta;this.configure(),this.linkScales(),t._stacked=re(t.vScale,t),this.addElements(),this.options.fill&&!this.chart.isPluginEnabled("filler")&&console.warn("Tried to use the 'fill' option without the 'Filler' plugin enabled. Please import and register the 'Filler' plugin and make sure it is not disabled in the options")}updateIndex(t){this.index!==t&&le(this._cachedMeta),this.index=t}linkScales(){const t=this.chart,i=this._cachedMeta,e=this.getDataset(),s=(t,i,e,s)=>"x"===t?i:"r"===t?s:e,n=i.xAxisID=V(e.xAxisID,ce(t,"x")),r=i.yAxisID=V(e.yAxisID,ce(t,"y")),o=i.rAxisID=V(e.rAxisID,ce(t,"r")),h=i.indexAxis,a=i.iAxisID=s(h,n,r,o),c=i.vAxisID=s(h,r,n,o);i.xScale=this.getScaleForId(n),i.yScale=this.getScaleForId(r),i.rScale=this.getScaleForId(o),i.iScale=this.getScaleForId(a),i.vScale=this.getScaleForId(c)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(t){return this.chart.scales[t]}_getOtherScale(t){const i=this._cachedMeta;return t===i.iScale?i.vScale:i.iScale}reset(){this._update("reset")}_destroy(){const t=this._cachedMeta;this._data&&Rt(this._data,this),t._stacked&&le(t)}_dataCheck(){const t=this.getDataset(),i=t.data||(t.data=[]),e=this._data;if(H(i))this._data=function(t,i){const{iScale:e,vScale:s}=i,n="x"===e.axis?"x":"y",r="x"===s.axis?"x":"y",o=Object.keys(t),h=new Array(o.length);let a,c,l;for(a=0,c=o.length;a<c;++a)l=o[a],h[a]={[n]:l,[r]:t[l]};return h}(i,this._cachedMeta);else if(e!==i){if(e){Rt(e,this);const t=this._cachedMeta;le(t),t._parsed=[]}i&&Object.isExtensible(i)&&((s=i)._chartjs?s._chartjs.listeners.push(this):(Object.defineProperty(s,"_chartjs",{configurable:!0,enumerable:!1,value:{listeners:[this]}}),jt.forEach((t=>{const i="_onData"+nt(t),e=s[t];Object.defineProperty(s,t,{configurable:!0,enumerable:!1,value(...t){const n=e.apply(this,t);return s._chartjs.listeners.forEach((e=>{"function"==typeof e[i]&&e[i](...t)})),n}})})))),this._syncList=[],this._data=i}var s}addElements(){const t=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(t.dataset=new this.datasetElementType)}buildOrUpdateElements(t){const i=this._cachedMeta,e=this.getDataset();let s=!1;this._dataCheck();const n=i._stacked;i._stacked=re(i.vScale,i),i.stack!==e.stack&&(s=!0,le(i),i.stack=e.stack),this._resyncElements(t),(s||n!==i._stacked)&&(ae(this,i._parsed),i._stacked=re(i.vScale,i))}configure(){const t=this.chart.config,i=t.datasetScopeKeys(this._type),e=t.getOptionScopes(this.getDataset(),i,!0);this.options=t.createResolver(e,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(t,i){const{_cachedMeta:e,_data:s}=this,{iScale:n,_stacked:r}=e,o=n.axis;let h,a,c,l=0===t&&i===s.length||e._sorted,u=t>0&&e._parsed[t-1];if(!1===this._parsing)e._parsed=s,e._sorted=!0,c=s;else{c=z(s[t])?this.parseArrayData(e,s,t,i):H(s[t])?this.parseObjectData(e,s,t,i):this.parsePrimitiveData(e,s,t,i);const n=()=>null===a[o]||u&&a[o]<u[o];for(h=0;h<i;++h)e._parsed[h+t]=a=c[h],l&&(n()&&(l=!1),u=a);e._sorted=l}r&&ae(this,c)}parsePrimitiveData(t,i,e,s){const{iScale:n,vScale:r}=t,o=n.axis,h=r.axis,a=n.getLabels(),c=n===r,l=new Array(s);let u,f,d;for(u=0,f=s;u<f;++u)d=u+e,l[u]={[o]:c||n.parse(a[d],d),[h]:r.parse(i[d],d)};return l}parseArrayData(t,i,e,s){const{xScale:n,yScale:r}=t,o=new Array(s);let h,a,c,l;for(h=0,a=s;h<a;++h)c=h+e,l=i[c],o[h]={x:n.parse(l[0],c),y:r.parse(l[1],c)};return o}parseObjectData(t,i,e,s){const{xScale:n,yScale:r}=t,{xAxisKey:o="x",yAxisKey:h="y"}=this._parsing,a=new Array(s);let c,l,u,f;for(c=0,l=s;c<l;++c)u=c+e,f=i[u],a[c]={x:n.parse(st(f,o),u),y:r.parse(st(f,h),u)};return a}getParsed(t){return this._cachedMeta._parsed[t]}getDataElement(t){return this._cachedMeta.data[t]}applyStack(t,i,e){const s=this._cachedMeta,n=i[t.axis];return ne({keys:se(this.chart,!0),values:i._stacks[t.axis]._visualValues},n,s.index,{mode:e})}updateRangeFromParsed(t,i,e,s){const n=e[i.axis];let r=null===n?NaN:n;const o=s&&e._stacks[i.axis];s&&o&&(s.values=o,r=ne(s,n,this._cachedMeta.index)),t.min=Math.min(t.min,r),t.max=Math.max(t.max,r)}getMinMax(t,i){const e=this._cachedMeta,s=e._parsed,n=e._sorted&&t===e.iScale,r=s.length,o=this._getOtherScale(t),h=((t,i)=>t&&!i.hidden&&i._stacked&&{keys:se(this.chart,!0),values:null})(i,e),a={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:c,max:l}=function(t){const{min:i,max:e,minDefined:s,maxDefined:n}=t.getUserBounds();return{min:s?i:Number.NEGATIVE_INFINITY,max:n?e:Number.POSITIVE_INFINITY}}(o);let u,f;function d(){f=s[u];const i=f[o.axis];return!$(f[t.axis])||c>i||l<i}for(u=0;u<r&&(d()||(this.updateRangeFromParsed(a,t,f,h),!n));++u);if(n)for(u=r-1;u>=0;--u)if(!d()){this.updateRangeFromParsed(a,t,f,h);break}return a}getAllParsedValues(t){const i=this._cachedMeta._parsed,e=[];let s,n,r;for(s=0,n=i.length;s<n;++s)r=i[s][t.axis],$(r)&&e.push(r);return e}getMaxOverflow(){return!1}getLabelAndValue(t){const i=this._cachedMeta,e=i.iScale,s=i.vScale,n=this.getParsed(t);return{label:e?""+e.getLabelForValue(n[e.axis]):"",value:s?""+s.getLabelForValue(n[s.axis]):""}}_update(t){const i=this._cachedMeta;this.update(t||"default"),i._clip=function(t){let i,e,s,n;return H(t)?(i=t.top,e=t.right,s=t.bottom,n=t.left):i=e=s=n=t,{top:i,right:e,bottom:s,left:n,disabled:!1===t}}(V(this.options.clip,function(t,i,e){if(!1===e)return!1;const s=ee(t,e),n=ee(i,e);return{top:n.end,right:s.end,bottom:n.start,left:s.start}}(i.xScale,i.yScale,this.getMaxOverflow())))}update(t){}draw(){const t=this._ctx,i=this._cachedMeta,e=i.data||[],s=this.chart.chartArea,n=[],r=this._drawStart||0,o=this._drawCount||e.length-r,h=this.options.drawActiveElementsOnTop;let a;for(i.dataset&&i.dataset.draw(t,s,r,o),a=r;a<r+o;++a){const i=e[a];i.hidden||(i.active&&h?n.push(i):i.draw(t,s))}for(a=0;a<n.length;++a)n[a].draw(t,s)}getStyle(t,i){const e=i?"active":"default";return void 0===t&&this._cachedMeta.dataset?this.resolveDatasetElementOptions(e):this.resolveDataElementOptions(t||0,e)}getContext(t,i,e){const s=this.getDataset();let n;if(t>=0&&t<this._cachedMeta.data.length){const i=this._cachedMeta.data[t];n=i.$context||(i.$context=function(t,i,e){return yi(t,{active:!1,dataIndex:i,parsed:void 0,raw:void 0,element:e,index:i,mode:"default",type:"data"})}(this.getContext(),t,i)),n.parsed=this.getParsed(t),n.raw=s.data[t],n.index=n.dataIndex=t}else n=this.$context||(this.$context=function(t,i){return yi(t,{active:!1,dataset:void 0,datasetIndex:i,index:i,mode:"default",type:"dataset"})}(this.chart.getContext(),this.index)),n.dataset=s,n.index=n.datasetIndex=this.index;return n.active=!!i,n.mode=e,n}resolveDatasetElementOptions(t){return this._resolveElementOptions(this.datasetElementType.id,t)}resolveDataElementOptions(t,i){return this._resolveElementOptions(this.dataElementType.id,i,t)}_resolveElementOptions(t,i="default",e){const s="active"===i,n=this._cachedDataOpts,r=t+"-"+i,o=n[r],h=this.enableOptionSharing&&rt(e);if(o)return fe(o,h);const a=this.chart.config,c=a.datasetElementScopeKeys(this._type,t),l=s?[`${t}Hover`,"hover",t,""]:[t,""],u=a.getOptionScopes(this.getDataset(),c),f=Object.keys(Gt.elements[t]),d=a.resolveNamedOptions(u,f,(()=>this.getContext(e,s,i)),l);return d.$shared&&(d.$shared=h,n[r]=Object.freeze(fe(d,h))),d}_resolveAnimations(t,i,e){const s=this.chart,n=this._cachedDataOpts,r=`animation-${i}`,o=n[r];if(o)return o;let h;if(!1!==s.options.animation){const s=this.chart.config,n=s.datasetAnimationScopeKeys(this._type,i),r=s.getOptionScopes(this.getDataset(),n);h=s.createResolver(r,this.getContext(t,e,i))}const a=new ie(s,h&&h.animations);return h&&h._cacheable&&(n[r]=Object.freeze(a)),a}getSharedOptions(t){if(t.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},t))}includeOptions(t,i){return!i||ue(t)||this.chart._animationsDisabled}_getSharedOptions(t,i){const e=this.resolveDataElementOptions(t,i),s=this._sharedOptions,n=this.getSharedOptions(e),r=this.includeOptions(i,n)||n!==s;return this.updateSharedOptions(n,i,e),{sharedOptions:n,includeOptions:r}}updateElement(t,i,e,s){ue(s)?Object.assign(t,e):this._resolveAnimations(i,s).update(t,e)}updateSharedOptions(t,i,e){t&&!ue(i)&&this._resolveAnimations(void 0,i).update(t,e)}_setStyle(t,i,e,s){t.active=s;const n=this.getStyle(i,s);this._resolveAnimations(i,e,s).update(t,{options:!s&&this.getSharedOptions(n)||n})}removeHoverStyle(t,i,e){this._setStyle(t,e,"active",!1)}setHoverStyle(t,i,e){this._setStyle(t,e,"active",!0)}_removeDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!1)}_setDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!0)}_resyncElements(t){const i=this._data,e=this._cachedMeta.data;for(const[t,i,e]of this._syncList)this[t](i,e);this._syncList=[];const s=e.length,n=i.length,r=Math.min(n,s);r&&this.parse(0,r),n>s?this._insertElements(s,n-s,t):n<s&&this._removeElements(n,s-n)}_insertElements(t,i,e=!0){const s=this._cachedMeta,n=s.data,r=t+i;let o;const h=t=>{for(t.length+=i,o=t.length-1;o>=r;o--)t[o]=t[o-i]};for(h(n),o=t;o<r;++o)n[o]=new this.dataElementType;this._parsing&&h(s._parsed),this.parse(t,i),e&&this.updateElements(n,t,i,"reset")}updateElements(t,i,e,s){}_removeElements(t,i){const e=this._cachedMeta;if(this._parsing){const s=e._parsed.splice(t,i);e._stacked&&le(e,s)}e.data.splice(t,i)}_sync(t){if(this._parsing)this._syncList.push(t);else{const[i,e,s]=t;this[i](e,s)}this.chart._dataChanges.push([this.index,...t])}_onDataPush(){const t=arguments.length;this._sync(["_insertElements",this.getDataset().data.length-t,t])}_onDataPop(){this._sync(["_removeElements",this._cachedMeta.data.length-1,1])}_onDataShift(){this._sync(["_removeElements",0,1])}_onDataSplice(t,i){i&&this._sync(["_removeElements",t,i]);const e=arguments.length-2;e&&this._sync(["_insertElements",t,e])}_onDataUnshift(){this._sync(["_insertElements",0,arguments.length])}}function be(t,i,e,s){return z(t)?function(t,i,e,s){const n=e.parse(t[0],s),r=e.parse(t[1],s),o=Math.min(n,r),h=Math.max(n,r);let a=o,c=h;Math.abs(o)>Math.abs(h)&&(a=h,c=o),i[e.axis]=c,i._custom={barStart:a,barEnd:c,start:n,end:r,min:o,max:h}}(t,i,e,s):i[e.axis]=e.parse(t,s),i}function ge(t,i,e,s){const n=t.iScale,r=t.vScale,o=n.getLabels(),h=n===r,a=[];let c,l,u,f;for(c=e,l=e+s;c<l;++c)f=i[c],u={},u[n.axis]=h||n.parse(o[c],c),a.push(be(f,u,r,c));return a}function pe(t){return t&&void 0!==t.barStart&&void 0!==t.barEnd}function me(t,i,e,s){let n=i.borderSkipped;const r={};if(!n)return void(t.borderSkipped=r);if(!0===n)return void(t.borderSkipped={top:!0,right:!0,bottom:!0,left:!0});const{start:o,end:h,reverse:a,top:c,bottom:l}=function(t){let i,e,s,n,r;return t.horizontal?(i=t.base>t.x,e="left",s="right"):(i=t.base<t.y,e="bottom",s="top"),i?(n="end",r="start"):(n="start",r="end"),{start:e,end:s,reverse:i,top:n,bottom:r}}(t);"middle"===n&&e&&(t.enableBorderRadius=!0,(e._top||0)===s?n=c:(e._bottom||0)===s?n=l:(r[xe(l,o,h,a)]=!0,n=c)),r[xe(n,o,h,a)]=!0,t.borderSkipped=r}function xe(t,i,e,s){var n,r,o;return s?(o=e,t=ve(t=(n=t)===(r=i)?o:n===o?r:n,e,i)):t=ve(t,i,e),t}function ve(t,i,e){return"start"===t?i:"end"===t?e:t}function ye(t,{inflateAmount:i},e){t.inflateAmount="auto"===i?1===e?.33:0:i}class Me extends de{static id="doughnut";static defaults={datasetElementType:!1,dataElementType:"arc",animation:{animateRotate:!0,animateScale:!1},animations:{numbers:{type:"number",properties:["circumference","endAngle","innerRadius","outerRadius","startAngle","x","y","offset","borderWidth","spacing"]}},cutout:"50%",rotation:0,circumference:360,radius:"100%",spacing:0,indexAxis:"r"};static descriptors={_scriptable:t=>"spacing"!==t,_indexable:t=>"spacing"!==t&&!t.startsWith("borderDash")&&!t.startsWith("hoverBorderDash")};static overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const i=t.data,{labels:{pointStyle:e,textAlign:s,color:n,useBorderRadius:r,borderRadius:o}}=t.legend.options;return i.labels.length&&i.datasets.length?i.labels.map(((i,h)=>{const a=t.getDatasetMeta(0).controller.getStyle(h);return{text:i,fillStyle:a.backgroundColor,fontColor:n,hidden:!t.getDataVisibility(h),lineDash:a.borderDash,lineDashOffset:a.borderDashOffset,lineJoin:a.borderJoinStyle,lineWidth:a.borderWidth,strokeStyle:a.borderColor,textAlign:s,pointStyle:e,borderRadius:r&&(o||a.borderRadius),index:h}})):[]}},onClick(t,i,e){e.chart.toggleDataVisibility(i.index),e.chart.update()}}}};constructor(t,i){super(t,i),this.enableOptionSharing=!0,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0}linkScales(){}parse(t,i){const e=this.getDataset().data,s=this._cachedMeta;if(!1===this._parsing)s._parsed=e;else{let n,r,o=t=>+e[t];if(H(e[t])){const{key:t="value"}=this._parsing;o=i=>+st(e[i],t)}for(n=t,r=t+i;n<r;++n)s._parsed[n]=o(n)}}_getRotation(){return yt(this.options.rotation-90)}_getCircumference(){return yt(this.options.circumference)}_getRotationExtents(){let t=ct,i=-ct;for(let e=0;e<this.chart.data.datasets.length;++e)if(this.chart.isDatasetVisible(e)&&this.chart.getDatasetMeta(e).type===this._type){const s=this.chart.getDatasetMeta(e).controller,n=s._getRotation(),r=s._getCircumference();t=Math.min(t,n),i=Math.max(i,n+r)}return{rotation:t,circumference:i-t}}update(t){const i=this.chart,{chartArea:e}=i,s=this._cachedMeta,n=s.data,r=this.getMaxBorderWidth()+this.getMaxOffset(n)+this.options.spacing,o=Math.max((Math.min(e.width,e.height)-r)/2,0),h=Math.min((c=o,"string"==typeof(a=this.options.cutout)&&a.endsWith("%")?parseFloat(a)/100:+a/c),1);var a,c;const l=this._getRingWeight(this.index),{circumference:u,rotation:f}=this._getRotationExtents(),{ratioX:d,ratioY:b,offsetX:g,offsetY:p}=function(t,i,e){let s=1,n=1,r=0,o=0;if(i<ct){const h=t,a=h+i,c=Math.cos(h),l=Math.sin(h),u=Math.cos(a),f=Math.sin(a),d=(t,i,s)=>_t(t,h,a,!0)?1:Math.max(i,i*e,s,s*e),b=(t,i,s)=>_t(t,h,a,!0)?-1:Math.min(i,i*e,s,s*e),g=d(0,c,u),p=d(ft,l,f),m=b(at,c,u),x=b(at+ft,l,f);s=(g-m)/2,n=(p-x)/2,r=-(g+m)/2,o=-(p+x)/2}return{ratioX:s,ratioY:n,offsetX:r,offsetY:o}}(f,u,h),m=Math.max(Math.min((e.width-r)/d,(e.height-r)/b)/2,0),x=X(this.options.radius,m),v=(x-Math.max(x*h,0))/this._getVisibleDatasetWeightTotal();this.offsetX=g*x,this.offsetY=p*x,s.total=this.calculateTotal(),this.outerRadius=x-v*this._getRingWeightOffset(this.index),this.innerRadius=Math.max(this.outerRadius-v*l,0),this.updateElements(n,0,n.length,t)}_circumference(t,i){const e=this.options,s=this._cachedMeta,n=this._getCircumference();return i&&e.animation.animateRotate||!this.chart.getDataVisibility(t)||null===s._parsed[t]||s.data[t].hidden?0:this.calculateCircumference(s._parsed[t]*n/ct)}updateElements(t,i,e,s){const n="reset"===s,r=this.chart,o=r.chartArea,h=(o.left+o.right)/2,a=(o.top+o.bottom)/2,c=n&&r.options.animation.animateScale,l=c?0:this.innerRadius,u=c?0:this.outerRadius,{sharedOptions:f,includeOptions:d}=this._getSharedOptions(i,s);let b,g=this._getRotation();for(b=0;b<i;++b)g+=this._circumference(b,n);for(b=i;b<i+e;++b){const i=this._circumference(b,n),e=t[b],r={x:h+this.offsetX,y:a+this.offsetY,startAngle:g,endAngle:g+i,circumference:i,outerRadius:u,innerRadius:l};d&&(r.options=f||this.resolveDataElementOptions(b,e.active?"active":s)),g+=i,this.updateElement(e,b,r,s)}}calculateTotal(){const t=this._cachedMeta,i=t.data;let e,s=0;for(e=0;e<i.length;e++){const n=t._parsed[e];null===n||isNaN(n)||!this.chart.getDataVisibility(e)||i[e].hidden||(s+=Math.abs(n))}return s}calculateCircumference(t){const i=this._cachedMeta.total;return i>0&&!isNaN(t)?ct*(Math.abs(t)/i):0}getLabelAndValue(t){const i=this.chart,e=i.data.labels||[],s=Vt(this._cachedMeta._parsed[t],i.options.locale);return{label:e[t]||"",value:s}}getMaxBorderWidth(t){let i=0;const e=this.chart;let s,n,r,o,h;if(!t)for(s=0,n=e.data.datasets.length;s<n;++s)if(e.isDatasetVisible(s)){r=e.getDatasetMeta(s),t=r.data,o=r.controller;break}if(!t)return 0;for(s=0,n=t.length;s<n;++s)h=o.resolveDataElementOptions(s),"inner"!==h.borderAlign&&(i=Math.max(i,h.borderWidth||0,h.hoverBorderWidth||0));return i}getMaxOffset(t){let i=0;for(let e=0,s=t.length;e<s;++e){const t=this.resolveDataElementOptions(e);i=Math.max(i,t.offset||0,t.hoverOffset||0)}return i}_getRingWeightOffset(t){let i=0;for(let e=0;e<t;++e)this.chart.isDatasetVisible(e)&&(i+=this._getRingWeight(e));return i}_getRingWeight(t){return Math.max(V(this.chart.data.datasets[t].weight,1),0)}_getVisibleDatasetWeightTotal(){return this._getRingWeightOffset(this.chart.data.datasets.length)||1}}class we extends de{static id="polarArea";static defaults={dataElementType:"arc",animation:{animateRotate:!0,animateScale:!0},animations:{numbers:{type:"number",properties:["x","y","startAngle","endAngle","innerRadius","outerRadius"]}},indexAxis:"r",startAngle:0};static overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const i=t.data;if(i.labels.length&&i.datasets.length){const{labels:{pointStyle:e,color:s}}=t.legend.options;return i.labels.map(((i,n)=>{const r=t.getDatasetMeta(0).controller.getStyle(n);return{text:i,fillStyle:r.backgroundColor,strokeStyle:r.borderColor,fontColor:s,lineWidth:r.borderWidth,pointStyle:e,hidden:!t.getDataVisibility(n),index:n}}))}return[]}},onClick(t,i,e){e.chart.toggleDataVisibility(i.index),e.chart.update()}}},scales:{r:{type:"radialLinear",angleLines:{display:!1},beginAtZero:!0,grid:{circular:!0},pointLabels:{display:!1},startAngle:0}}};constructor(t,i){super(t,i),this.innerRadius=void 0,this.outerRadius=void 0}getLabelAndValue(t){const i=this.chart,e=i.data.labels||[],s=Vt(this._cachedMeta._parsed[t].r,i.options.locale);return{label:e[t]||"",value:s}}parseObjectData(t,i,e,s){return Pi.bind(this)(t,i,e,s)}update(t){const i=this._cachedMeta.data;this._updateRadius(),this.updateElements(i,0,i.length,t)}getMinMax(){const t={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY};return this._cachedMeta.data.forEach(((i,e)=>{const s=this.getParsed(e).r;!isNaN(s)&&this.chart.getDataVisibility(e)&&(s<t.min&&(t.min=s),s>t.max&&(t.max=s))})),t}_updateRadius(){const t=this.chart,i=t.chartArea,e=t.options,s=Math.min(i.right-i.left,i.bottom-i.top),n=Math.max(s/2,0),r=(n-Math.max(e.cutoutPercentage?n/100*e.cutoutPercentage:1,0))/t.getVisibleDatasetCount();this.outerRadius=n-r*this.index,this.innerRadius=this.outerRadius-r}updateElements(t,i,e,s){const n="reset"===s,r=this.chart,o=r.options.animation,h=this._cachedMeta.rScale,a=h.xCenter,c=h.yCenter,l=h.getIndexAngle(0)-.5*at;let u,f=l;const d=360/this.countVisibleElements();for(u=0;u<i;++u)f+=this._computeAngle(u,s,d);for(u=i;u<i+e;u++){const i=t[u];let e=f,b=f+this._computeAngle(u,s,d),g=r.getDataVisibility(u)?h.getDistanceFromCenterForValue(this.getParsed(u).r):0;f=b,n&&(o.animateScale&&(g=0),o.animateRotate&&(e=b=l));const p={x:a,y:c,innerRadius:0,outerRadius:g,startAngle:e,endAngle:b,options:this.resolveDataElementOptions(u,i.active?"active":s)};this.updateElement(i,u,p,s)}}countVisibleElements(){let t=0;return this._cachedMeta.data.forEach(((i,e)=>{!isNaN(this.getParsed(e).r)&&this.chart.getDataVisibility(e)&&t++})),t}_computeAngle(t,i,e){return this.chart.getDataVisibility(t)?yt(this.resolveDataElementOptions(t,i).angle||e):0}}function _e(t,i,e,s){const{controller:n,data:r,_sorted:o}=t,h=n._cachedMeta.iScale,a=t.dataset&&t.dataset.options?t.dataset.options.spanGaps:null;if(h&&i===h.axis&&"r"!==i&&o&&r.length){const o=h._reversePixels?Dt:At;if(!s){const s=o(r,i,e);if(a){const{vScale:i}=n._cachedMeta,{_parsed:e}=t,r=e.slice(0,s.lo+1).reverse().findIndex((t=>!N(t[i.axis])));s.lo-=Math.max(0,r);const o=e.slice(s.hi).findIndex((t=>!N(t[i.axis])));s.hi+=Math.max(0,o)}return s}if(n._sharedOptions){const t=r[0],s="function"==typeof t.getRange&&t.getRange(i);if(s){const t=o(r,i,e-s),n=o(r,i,e+s);return{lo:t.lo,hi:n.hi}}}}return{lo:0,hi:r.length-1}}function ke(t,i,e,s,n){const r=t.getSortedVisibleDatasetMetas(),o=e[i];for(let t=0,e=r.length;t<e;++t){const{index:e,data:h}=r[t],{lo:a,hi:c}=_e(r[t],i,o,n);for(let t=a;t<=c;++t){const i=h[t];i.skip||s(i,e,t)}}}function Oe(t,i,e,s,n){const r=[];return n||t.isPointInArea(i)?(ke(t,e,i,(function(e,o,h){(n||ni(e,t.chartArea,0))&&e.inRange(i.x,i.y,s)&&r.push({element:e,datasetIndex:o,index:h})}),!0),r):r}function Se(t,i,e,s,n,r){return r||t.isPointInArea(i)?"r"!==e||s?function(t,i,e,s,n,r){let o=[];const h=function(t){const i=-1!==t.indexOf("x"),e=-1!==t.indexOf("y");return function(t,s){const n=i?Math.abs(t.x-s.x):0,r=e?Math.abs(t.y-s.y):0;return Math.sqrt(Math.pow(n,2)+Math.pow(r,2))}}(e);let a=Number.POSITIVE_INFINITY;return ke(t,e,i,(function(e,c,l){const u=e.inRange(i.x,i.y,n);if(s&&!u)return;const f=e.getCenterPoint(n);if(!r&&!t.isPointInArea(f)&&!u)return;const d=h(i,f);d<a?(o=[{element:e,datasetIndex:c,index:l}],a=d):d===a&&o.push({element:e,datasetIndex:c,index:l})})),o}(t,i,e,s,n,r):function(t,i,e,s){let n=[];return ke(t,e,i,(function(t,e,r){const{startAngle:o,endAngle:h}=t.getProps(["startAngle","endAngle"],s),{angle:a}=function(t,i){const e=i.x-t.x,s=i.y-t.y,n=Math.sqrt(e*e+s*s);let r=Math.atan2(s,e);return r<-.5*at&&(r+=ct),{angle:r,distance:n}}(t,{x:i.x,y:i.y});_t(a,o,h)&&n.push({element:t,datasetIndex:e,index:r})})),n}(t,i,e,n):[]}function Ae(t,i,e,s,n){const r=[],o="x"===e?"inXRange":"inYRange";let h=!1;return ke(t,e,i,((t,s,a)=>{t[o]&&t[o](i[e],n)&&(r.push({element:t,datasetIndex:s,index:a}),h=h||t.inRange(i.x,i.y,n))})),s&&!h?[]:r}var De={modes:{index(t,i,e,s){const n=zi(i,t),r=e.axis||"x",o=e.includeInvisible||!1,h=e.intersect?Oe(t,n,r,s,o):Se(t,n,r,!1,s,o),a=[];return h.length?(t.getSortedVisibleDatasetMetas().forEach((t=>{const i=h[0].index,e=t.data[i];e&&!e.skip&&a.push({element:e,datasetIndex:t.index,index:i})})),a):[]},dataset(t,i,e,s){const n=zi(i,t),r=e.axis||"xy",o=e.includeInvisible||!1;let h=e.intersect?Oe(t,n,r,s,o):Se(t,n,r,!1,s,o);if(h.length>0){const i=h[0].datasetIndex,e=t.getDatasetMeta(i).data;h=[];for(let t=0;t<e.length;++t)h.push({element:e[t],datasetIndex:i,index:t})}return h},point:(t,i,e,s)=>Oe(t,zi(i,t),e.axis||"xy",s,e.includeInvisible||!1),nearest:(t,i,e,s)=>Se(t,zi(i,t),e.axis||"xy",e.intersect,s,e.includeInvisible||!1),x:(t,i,e,s)=>Ae(t,zi(i,t),"x",e.intersect,s),y:(t,i,e,s)=>Ae(t,zi(i,t),"y",e.intersect,s)}};const je=["left","top","right","bottom"];function Re(t,i){return t.filter((t=>t.pos===i))}function Ce(t,i){return t.filter((t=>-1===je.indexOf(t.pos)&&t.box.axis===i))}function Ee(t,i){return t.sort(((t,e)=>{const s=i?e:t,n=i?t:e;return s.weight===n.weight?s.index-n.index:s.weight-n.weight}))}function Le(t,i,e,s){return Math.max(t[e],i[e])+Math.max(t[s],i[s])}function Pe(t,i){t.top=Math.max(t.top,i.top),t.left=Math.max(t.left,i.left),t.bottom=Math.max(t.bottom,i.bottom),t.right=Math.max(t.right,i.right)}function Te(t,i,e,s){const{pos:n,box:r}=e,o=t.maxPadding;if(!H(n)){e.size&&(t[n]-=e.size);const i=s[e.stack]||{size:0,count:1};i.size=Math.max(i.size,e.horizontal?r.height:r.width),e.size=i.size/i.count,t[n]+=e.size}r.getPadding&&Pe(o,r.getPadding());const h=Math.max(0,i.outerWidth-Le(o,t,"left","right")),a=Math.max(0,i.outerHeight-Le(o,t,"top","bottom")),c=h!==t.w,l=a!==t.h;return t.w=h,t.h=a,e.horizontal?{same:c,other:l}:{same:l,other:c}}function Ie(t,i){const e=i.maxPadding;return function(t){const s={left:0,top:0,right:0,bottom:0};return t.forEach((t=>{s[t]=Math.max(i[t],e[t])})),s}(t?["left","right"]:["top","bottom"])}function Fe(t,i,e,s){const n=[];let r,o,h,a,c,l;for(r=0,o=t.length,c=0;r<o;++r){h=t[r],a=h.box,a.update(h.width||i.w,h.height||i.h,Ie(h.horizontal,i));const{same:o,other:u}=Te(i,e,h,s);c|=o&&n.length,l=l||u,a.fullSize||n.push(h)}return c&&Fe(n,i,e,s)||l}function Be(t,i,e,s,n){t.top=e,t.left=i,t.right=i+s,t.bottom=e+n,t.width=s,t.height=n}function We(t,i,e,s){const n=e.padding;let{x:r,y:o}=i;for(const h of t){const t=h.box,a=s[h.stack]||{placed:0,weight:1},c=h.stackWeight/a.weight||1;if(h.horizontal){const s=i.w*c,r=a.size||t.height;rt(a.start)&&(o=a.start),t.fullSize?Be(t,n.left,o,e.outerWidth-n.right-n.left,r):Be(t,i.left+a.placed,o,s,r),a.start=o,a.placed+=s,o=t.bottom}else{const s=i.h*c,o=a.size||t.width;rt(a.start)&&(r=a.start),t.fullSize?Be(t,r,n.top,o,e.outerHeight-n.bottom-n.top):Be(t,r,i.top+a.placed,o,s),a.start=r,a.placed+=s,r=t.right}}i.x=r,i.y=o}var Ne={addBox(t,i){t.boxes||(t.boxes=[]),i.fullSize=i.fullSize||!1,i.position=i.position||"top",i.weight=i.weight||0,i._layers=i._layers||function(){return[{z:0,draw(t){i.draw(t)}}]},t.boxes.push(i)},removeBox(t,i){const e=t.boxes?t.boxes.indexOf(i):-1;-1!==e&&t.boxes.splice(e,1)},configure(t,i,e){i.fullSize=e.fullSize,i.position=e.position,i.weight=e.weight},update(t,i,e,s){if(!t)return;const n=mi(t.options.layout.padding),r=Math.max(i-n.width,0),o=Math.max(e-n.height,0),h=function(t){const i=function(t){const i=[];let e,s,n,r,o,h;for(e=0,s=(t||[]).length;e<s;++e)n=t[e],({position:r,options:{stack:o,stackWeight:h=1}}=n),i.push({index:e,box:n,pos:r,horizontal:n.isHorizontal(),weight:n.weight,stack:o&&r+o,stackWeight:h});return i}(t),e=Ee(i.filter((t=>t.box.fullSize)),!0),s=Ee(Re(i,"left"),!0),n=Ee(Re(i,"right")),r=Ee(Re(i,"top"),!0),o=Ee(Re(i,"bottom")),h=Ce(i,"x"),a=Ce(i,"y");return{fullSize:e,leftAndTop:s.concat(r),rightAndBottom:n.concat(a).concat(o).concat(h),chartArea:Re(i,"chartArea"),vertical:s.concat(n).concat(a),horizontal:r.concat(o).concat(h)}}(t.boxes),a=h.vertical,c=h.horizontal;Z(t.boxes,(t=>{"function"==typeof t.beforeLayout&&t.beforeLayout()}));const l=a.reduce(((t,i)=>i.box.options&&!1===i.box.options.display?t:t+1),0)||1,u=Object.freeze({outerWidth:i,outerHeight:e,padding:n,availableWidth:r,availableHeight:o,vBoxMaxWidth:r/2/l,hBoxMaxHeight:o/2}),f=Object.assign({},n);Pe(f,mi(s));const d=Object.assign({maxPadding:f,w:r,h:o,x:n.left,y:n.top},n),b=function(t,i){const e=function(t){const i={};for(const e of t){const{stack:t,pos:s,stackWeight:n}=e;if(!t||!je.includes(s))continue;const r=i[t]||(i[t]={count:0,placed:0,weight:0,size:0});r.count++,r.weight+=n}return i}(t),{vBoxMaxWidth:s,hBoxMaxHeight:n}=i;let r,o,h;for(r=0,o=t.length;r<o;++r){h=t[r];const{fullSize:o}=h.box,a=e[h.stack],c=a&&h.stackWeight/a.weight;h.horizontal?(h.width=c?c*s:o&&i.availableWidth,h.height=n):(h.width=s,h.height=c?c*n:o&&i.availableHeight)}return e}(a.concat(c),u);Fe(h.fullSize,d,u,b),Fe(a,d,u,b),Fe(c,d,u,b)&&Fe(a,d,u,b),function(t){const i=t.maxPadding;function e(e){const s=Math.max(i[e]-t[e],0);return t[e]+=s,s}t.y+=e("top"),t.x+=e("left"),e("right"),e("bottom")}(d),We(h.leftAndTop,d,u,b),d.x+=d.w,d.y+=d.h,We(h.rightAndBottom,d,u,b),t.chartArea={left:d.left,top:d.top,right:d.left+d.w,bottom:d.top+d.h,height:d.h,width:d.w},Z(h.chartArea,(i=>{const e=i.box;Object.assign(e,t.chartArea),e.update(d.w,d.h,{left:0,top:0,right:0,bottom:0})}))}};class ze{acquireContext(t,i){}releaseContext(t){return!1}addEventListener(t,i,e){}removeEventListener(t,i,e){}getDevicePixelRatio(){return 1}getMaximumSize(t,i,e,s){return i=Math.max(0,i||t.width),e=e||t.height,{width:i,height:Math.max(0,s?Math.floor(i/s):e)}}isAttached(t){return!0}updateConfig(t){}}class He extends ze{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const $e="$chartjs",Ye={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},Ve=t=>null===t||""===t,Xe=!!Yi&&{passive:!0};function Ue(t,i,e){t&&t.canvas&&t.canvas.removeEventListener(i,e,Xe)}function Ze(t,i){for(const e of t)if(e===i||e.contains(i))return!0}function Ke(t,i,e){const s=t.canvas,n=new MutationObserver((t=>{let i=!1;for(const e of t)i=i||Ze(e.addedNodes,s),i=i&&!Ze(e.removedNodes,s);i&&e()}));return n.observe(document,{childList:!0,subtree:!0}),n}function Qe(t,i,e){const s=t.canvas,n=new MutationObserver((t=>{let i=!1;for(const e of t)i=i||Ze(e.removedNodes,s),i=i&&!Ze(e.addedNodes,s);i&&e()}));return n.observe(document,{childList:!0,subtree:!0}),n}const qe=new Map;let Ge=0;function Je(){const t=window.devicePixelRatio;t!==Ge&&(Ge=t,qe.forEach(((i,e)=>{e.currentDevicePixelRatio!==t&&i()})))}function ts(t,i,e){const s=t.canvas,n=s&&Ii(s);if(!n)return;const r=Et(((t,i)=>{const s=n.clientWidth;e(t,i),s<n.clientWidth&&e()}),window),o=new ResizeObserver((t=>{const i=t[0],e=i.contentRect.width,s=i.contentRect.height;0===e&&0===s||r(e,s)}));return o.observe(n),function(t,i){qe.size||window.addEventListener("resize",Je),qe.set(t,i)}(t,r),o}function is(t,i,e){e&&e.disconnect(),"resize"===i&&function(t){qe.delete(t),qe.size||window.removeEventListener("resize",Je)}(t)}function es(t,i,e){const s=t.canvas,n=Et((i=>{null!==t.ctx&&e(function(t,i){const e=Ye[t.type]||t.type,{x:s,y:n}=zi(t,i);return{type:e,chart:i,native:t,x:void 0!==s?s:null,y:void 0!==n?n:null}}(i,t))}),t);return function(t,i,e){t&&t.addEventListener(i,e,Xe)}(s,i,n),n}class ss extends ze{acquireContext(t,i){const e=t&&t.getContext&&t.getContext("2d");return e&&e.canvas===t?(function(t,i){const e=t.style,s=t.getAttribute("height"),n=t.getAttribute("width");if(t[$e]={initial:{height:s,width:n,style:{display:e.display,height:e.height,width:e.width}}},e.display=e.display||"block",e.boxSizing=e.boxSizing||"border-box",Ve(n)){const i=Vi(t,"width");void 0!==i&&(t.width=i)}if(Ve(s))if(""===t.style.height)t.height=t.width/(i||2);else{const i=Vi(t,"height");void 0!==i&&(t.height=i)}}(t,i),e):null}releaseContext(t){const i=t.canvas;if(!i[$e])return!1;const e=i[$e].initial;["height","width"].forEach((t=>{const s=e[t];N(s)?i.removeAttribute(t):i.setAttribute(t,s)}));const s=e.style||{};return Object.keys(s).forEach((t=>{i.style[t]=s[t]})),i.width=i.width,delete i[$e],!0}addEventListener(t,i,e){this.removeEventListener(t,i),(t.$proxies||(t.$proxies={}))[i]=({attach:Ke,detach:Qe,resize:ts}[i]||es)(t,i,e)}removeEventListener(t,i){const e=t.$proxies||(t.$proxies={}),s=e[i];s&&(({attach:is,detach:is,resize:is}[i]||Ue)(t,i,s),e[i]=void 0)}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,i,e,s){return function(t,i,e,s){const n=Bi(t),r=Ni(n,"margin"),o=Fi(n.maxWidth,t,"clientWidth")||lt,h=Fi(n.maxHeight,t,"clientHeight")||lt,a=function(t,i,e){let s,n;if(void 0===i||void 0===e){const r=t&&Ii(t);if(r){const t=r.getBoundingClientRect(),o=Bi(r),h=Ni(o,"border","width"),a=Ni(o,"padding");i=t.width-a.width-h.width,e=t.height-a.height-h.height,s=Fi(o.maxWidth,r,"clientWidth"),n=Fi(o.maxHeight,r,"clientHeight")}else i=t.clientWidth,e=t.clientHeight}return{width:i,height:e,maxWidth:s||lt,maxHeight:n||lt}}(t,i,e);let{width:c,height:l}=a;if("content-box"===n.boxSizing){const t=Ni(n,"border","width"),i=Ni(n,"padding");c-=i.width+t.width,l-=i.height+t.height}return c=Math.max(0,c-r.width),l=Math.max(0,s?c/s:l-r.height),c=Hi(Math.min(c,o,a.maxWidth)),l=Hi(Math.min(l,h,a.maxHeight)),c&&!l&&(l=Hi(c/2)),(void 0!==i||void 0!==e)&&s&&a.height&&l>a.height&&(l=a.height,c=Hi(Math.floor(l*s))),{width:c,height:l}}(t,i,e,s)}isAttached(t){const i=t&&Ii(t);return!(!i||!i.isConnected)}}class ns{static defaults={};static defaultRoutes=void 0;x;y;active=!1;options;$animations;tooltipPosition(t){const{x:i,y:e}=this.getProps(["x","y"],t);return{x:i,y:e}}hasValue(){return vt(this.x)&&vt(this.y)}getProps(t,i){const e=this.$animations;if(!i||!e)return this;const s={};return t.forEach((t=>{s[t]=e[t]&&e[t].active()?e[t]._to:this[t]})),s}}function rs(t,i,e,s,n){const r=V(s,0),o=Math.min(V(n,t.length),t.length);let h,a,c,l=0;for(e=Math.ceil(e),n&&(h=n-s,e=h/Math.floor(h/e)),c=r;c<0;)l++,c=Math.round(r+l*e);for(a=Math.max(r,0);a<o;a++)a===c&&(i.push(t[a]),l++,c=Math.round(r+l*e))}const os=(t,i,e)=>"top"===i||"left"===i?t[i]+e:t[i]-e,hs=(t,i)=>Math.min(i||t,t);function as(t,i){const e=[],s=t.length/i,n=t.length;let r=0;for(;r<n;r+=s)e.push(t[Math.floor(r)]);return e}function cs(t,i,e){const s=t.ticks.length,n=Math.min(i,s-1),r=t._startPixel,o=t._endPixel,h=1e-6;let a,c=t.getPixelForTick(n);if(!(e&&(a=1===s?Math.max(c-r,o-c):0===i?(t.getPixelForTick(1)-c)/2:(c-t.getPixelForTick(n-1))/2,c+=n<i?a:-a,c<r-h||c>o+h)))return c}function ls(t){return t.drawTicks?t.tickLength:0}function us(t,i){if(!t.display)return 0;const e=xi(t.font,i),s=mi(t.padding);return(z(t.text)?t.text.length:1)*e.lineHeight+s.height}function fs(t,i,e){let s=Lt(t);return(e&&"right"!==i||!e&&"right"===i)&&(s=(t=>"left"===t?"right":"right"===t?"left":t)(s)),s}class ds extends ns{constructor(t){super(),this.id=t.id,this.type=t.type,this.options=void 0,this.ctx=t.ctx,this.chart=t.chart,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this._margins={left:0,right:0,top:0,bottom:0},this.maxWidth=void 0,this.maxHeight=void 0,this.paddingTop=void 0,this.paddingBottom=void 0,this.paddingLeft=void 0,this.paddingRight=void 0,this.axis=void 0,this.labelRotation=void 0,this.min=void 0,this.max=void 0,this._range=void 0,this.ticks=[],this._gridLineItems=null,this._labelItems=null,this._labelSizes=null,this._length=0,this._maxLength=0,this._longestTextCache={},this._startPixel=void 0,this._endPixel=void 0,this._reversePixels=!1,this._userMax=void 0,this._userMin=void 0,this._suggestedMax=void 0,this._suggestedMin=void 0,this._ticksLength=0,this._borderValue=0,this._cache={},this._dataLimitsCached=!1,this.$context=void 0}init(t){this.options=t.setContext(this.getContext()),this.axis=t.axis,this._userMin=this.parse(t.min),this._userMax=this.parse(t.max),this._suggestedMin=this.parse(t.suggestedMin),this._suggestedMax=this.parse(t.suggestedMax)}parse(t,i){return t}getUserBounds(){let{_userMin:t,_userMax:i,_suggestedMin:e,_suggestedMax:s}=this;return t=Y(t,Number.POSITIVE_INFINITY),i=Y(i,Number.NEGATIVE_INFINITY),e=Y(e,Number.POSITIVE_INFINITY),s=Y(s,Number.NEGATIVE_INFINITY),{min:Y(t,e),max:Y(i,s),minDefined:$(t),maxDefined:$(i)}}getMinMax(t){let i,{min:e,max:s,minDefined:n,maxDefined:r}=this.getUserBounds();if(n&&r)return{min:e,max:s};const o=this.getMatchingVisibleMetas();for(let h=0,a=o.length;h<a;++h)i=o[h].controller.getMinMax(this,t),n||(e=Math.min(e,i.min)),r||(s=Math.max(s,i.max));return e=r&&e>s?s:e,s=n&&e>s?e:s,{min:Y(e,Y(s,e)),max:Y(s,Y(e,s))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){const t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels||[]}getLabelItems(t=this.chart.chartArea){return this._labelItems||(this._labelItems=this._computeLabelItems(t))}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){U(this.options.beforeUpdate,[this])}update(t,i,e){const{beginAtZero:s,grace:n,ticks:r}=this.options,o=r.sampleSize;this.beforeUpdate(),this.maxWidth=t,this.maxHeight=i,this._margins=e=Object.assign({left:0,right:0,top:0,bottom:0},e),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+e.left+e.right:this.height+e.top+e.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=function(t,i,e){const{min:s,max:n}=t,r=X(i,(n-s)/2),o=(t,i)=>e&&0===t?0:t+i;return{min:o(s,-Math.abs(r)),max:o(n,r)}}(this,n,s),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const h=o<this.ticks.length;this._convertTicksToLabels(h?as(this.ticks,o):this.ticks),this.configure(),this.beforeCalculateLabelRotation(),this.calculateLabelRotation(),this.afterCalculateLabelRotation(),r.display&&(r.autoSkip||"auto"===r.source)&&(this.ticks=function(t,i){const e=t.options.ticks,s=function(t){const i=t.options.offset,e=t._tickSize();return Math.floor(Math.min(t._length/e+(i?0:1),t._maxLength/e))}(t),n=Math.min(e.maxTicksLimit||s,s),r=e.major.enabled?function(t){const i=[];let e,s;for(e=0,s=t.length;e<s;e++)t[e].major&&i.push(e);return i}(i):[],o=r.length,h=r[0],a=r[o-1],c=[];if(o>n)return function(t,i,e,s){let n,r=0,o=e[0];for(s=Math.ceil(s),n=0;n<t.length;n++)n===o&&(i.push(t[n]),r++,o=e[r*s])}(i,c,r,o/n),c;const l=function(t,i,e){const s=function(t){const i=t.length;let e,s;if(i<2)return!1;for(s=t[0],e=1;e<i;++e)if(t[e]-t[e-1]!==s)return!1;return s}(t),n=i.length/e;if(!s)return Math.max(n,1);const r=function(t){const i=[],e=Math.sqrt(t);let s;for(s=1;s<e;s++)t%s==0&&(i.push(s),i.push(t/s));return e===(0|e)&&i.push(e),i.sort(((t,i)=>t-i)).pop(),i}(s);for(let t=0,i=r.length-1;t<i;t++){const i=r[t];if(i>n)return i}return Math.max(n,1)}(r,i,n);if(o>0){let t,e;const s=o>1?Math.round((a-h)/(o-1)):null;for(rs(i,c,l,N(s)?0:h-s,h),t=0,e=o-1;t<e;t++)rs(i,c,l,r[t],r[t+1]);return rs(i,c,l,a,N(s)?i.length:a+s),c}return rs(i,c,l),c}(this,this.ticks),this._labelSizes=null,this.afterAutoSkip()),h&&this._convertTicksToLabels(this.ticks),this.beforeFit(),this.fit(),this.afterFit(),this.afterUpdate()}configure(){let t,i,e=this.options.reverse;this.isHorizontal()?(t=this.left,i=this.right):(t=this.top,i=this.bottom,e=!e),this._startPixel=t,this._endPixel=i,this._reversePixels=e,this._length=i-t,this._alignToPixels=this.options.alignToPixels}afterUpdate(){U(this.options.afterUpdate,[this])}beforeSetDimensions(){U(this.options.beforeSetDimensions,[this])}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=0,this.right=this.width):(this.height=this.maxHeight,this.top=0,this.bottom=this.height),this.paddingLeft=0,this.paddingTop=0,this.paddingRight=0,this.paddingBottom=0}afterSetDimensions(){U(this.options.afterSetDimensions,[this])}_callHooks(t){this.chart.notifyPlugins(t,this.getContext()),U(this.options[t],[this])}beforeDataLimits(){this._callHooks("beforeDataLimits")}determineDataLimits(){}afterDataLimits(){this._callHooks("afterDataLimits")}beforeBuildTicks(){this._callHooks("beforeBuildTicks")}buildTicks(){return[]}afterBuildTicks(){this._callHooks("afterBuildTicks")}beforeTickToLabelConversion(){U(this.options.beforeTickToLabelConversion,[this])}generateTickLabels(t){const i=this.options.ticks;let e,s,n;for(e=0,s=t.length;e<s;e++)n=t[e],n.label=U(i.callback,[n.value,e,t],this)}afterTickToLabelConversion(){U(this.options.afterTickToLabelConversion,[this])}beforeCalculateLabelRotation(){U(this.options.beforeCalculateLabelRotation,[this])}calculateLabelRotation(){const t=this.options,i=t.ticks,e=hs(this.ticks.length,t.ticks.maxTicksLimit),s=i.minRotation||0,n=i.maxRotation;let r,o,h,a=s;if(!this._isVisible()||!i.display||s>=n||e<=1||!this.isHorizontal())return void(this.labelRotation=s);const c=this._getLabelSizes(),l=c.widest.width,u=c.highest.height,f=kt(this.chart.width-l,0,this.maxWidth);r=t.offset?this.maxWidth/e:f/(e-1),l+6>r&&(r=f/(e-(t.offset?.5:1)),o=this.maxHeight-ls(t.grid)-i.padding-us(t.title,this.chart.options.font),h=Math.sqrt(l*l+u*u),a=Math.min(Math.asin(kt((c.highest.height+6)/r,-1,1)),Math.asin(kt(o/h,-1,1))-Math.asin(kt(u/h,-1,1)))*(180/at),a=Math.max(s,Math.min(n,a))),this.labelRotation=a}afterCalculateLabelRotation(){U(this.options.afterCalculateLabelRotation,[this])}afterAutoSkip(){}beforeFit(){U(this.options.beforeFit,[this])}fit(){const t={width:0,height:0},{chart:i,options:{ticks:e,title:s,grid:n}}=this,r=this._isVisible(),o=this.isHorizontal();if(r){const r=us(s,i.options.font);if(o?(t.width=this.maxWidth,t.height=ls(n)+r):(t.height=this.maxHeight,t.width=ls(n)+r),e.display&&this.ticks.length){const{first:i,last:s,widest:n,highest:r}=this._getLabelSizes(),h=2*e.padding,a=yt(this.labelRotation),c=Math.cos(a),l=Math.sin(a);o?t.height=Math.min(this.maxHeight,t.height+(e.mirror?0:l*n.width+c*r.height)+h):t.width=Math.min(this.maxWidth,t.width+(e.mirror?0:c*n.width+l*r.height)+h),this._calculatePadding(i,s,l,c)}}this._handleMargins(),o?(this.width=this._length=i.width-this._margins.left-this._margins.right,this.height=t.height):(this.width=t.width,this.height=this._length=i.height-this._margins.top-this._margins.bottom)}_calculatePadding(t,i,e,s){const{ticks:{align:n,padding:r},position:o}=this.options,h=0!==this.labelRotation,a="top"!==o&&"x"===this.axis;if(this.isHorizontal()){const o=this.getPixelForTick(0)-this.left,c=this.right-this.getPixelForTick(this.ticks.length-1);let l=0,u=0;h?a?(l=s*t.width,u=e*i.height):(l=e*t.height,u=s*i.width):"start"===n?u=i.width:"end"===n?l=t.width:"inner"!==n&&(l=t.width/2,u=i.width/2),this.paddingLeft=Math.max((l-o+r)*this.width/(this.width-o),0),this.paddingRight=Math.max((u-c+r)*this.width/(this.width-c),0)}else{let e=i.height/2,s=t.height/2;"start"===n?(e=0,s=t.height):"end"===n&&(e=i.height,s=0),this.paddingTop=e+r,this.paddingBottom=s+r}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom))}afterFit(){U(this.options.afterFit,[this])}isHorizontal(){const{axis:t,position:i}=this.options;return"top"===i||"bottom"===i||"x"===t}isFullSize(){return this.options.fullSize}_convertTicksToLabels(t){let i,e;for(this.beforeTickToLabelConversion(),this.generateTickLabels(t),i=0,e=t.length;i<e;i++)N(t[i].label)&&(t.splice(i,1),e--,i--);this.afterTickToLabelConversion()}_getLabelSizes(){let t=this._labelSizes;if(!t){const i=this.options.ticks.sampleSize;let e=this.ticks;i<e.length&&(e=as(e,i)),this._labelSizes=t=this._computeLabelSizes(e,e.length,this.options.ticks.maxTicksLimit)}return t}_computeLabelSizes(t,i,e){const{ctx:s,_longestTextCache:n}=this,r=[],o=[],h=Math.floor(i/hs(i,e));let a,c,l,u,f,d,b,g,p,m,x,v=0,y=0;for(a=0;a<i;a+=h){if(u=t[a].label,f=this._resolveTickFontOptions(a),s.font=d=f.string,b=n[d]=n[d]||{data:{},gc:[]},g=f.lineHeight,p=m=0,N(u)||z(u)){if(z(u))for(c=0,l=u.length;c<l;++c)x=u[c],N(x)||z(x)||(p=Jt(s,b.data,b.gc,p,x),m+=g)}else p=Jt(s,b.data,b.gc,p,u),m=g;r.push(p),o.push(m),v=Math.max(p,v),y=Math.max(m,y)}!function(t,i){Z(t,(t=>{const e=t.gc,s=e.length/2;let n;if(s>i){for(n=0;n<s;++n)delete t.data[e[n]];e.splice(0,s)}}))}(n,i);const M=r.indexOf(v),w=o.indexOf(y),_=t=>({width:r[t]||0,height:o[t]||0});return{first:_(0),last:_(i-1),widest:_(M),highest:_(w),widths:r,heights:o}}getLabelForValue(t){return t}getPixelForValue(t,i){return NaN}getValueForPixel(t){}getPixelForTick(t){const i=this.ticks;return t<0||t>i.length-1?null:this.getPixelForValue(i[t].value)}getPixelForDecimal(t){this._reversePixels&&(t=1-t);const i=this._startPixel+t*this._length;return kt(this._alignToPixels?ti(this.chart,i,0):i,-32768,32767)}getDecimalForPixel(t){const i=(t-this._startPixel)/this._length;return this._reversePixels?1-i:i}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:t,max:i}=this;return t<0&&i<0?i:t>0&&i>0?t:0}getContext(t){const i=this.ticks||[];if(t>=0&&t<i.length){const e=i[t];return e.$context||(e.$context=function(t,i,e){return yi(t,{tick:e,index:i,type:"tick"})}(this.getContext(),t,e))}return this.$context||(this.$context=yi(this.chart.getContext(),{scale:this,type:"scale"}))}_tickSize(){const t=this.options.ticks,i=yt(this.labelRotation),e=Math.abs(Math.cos(i)),s=Math.abs(Math.sin(i)),n=this._getLabelSizes(),r=t.autoSkipPadding||0,o=n?n.widest.width+r:0,h=n?n.highest.height+r:0;return this.isHorizontal()?h*e>o*s?o/e:h/s:h*s<o*e?h/e:o/s}_isVisible(){const t=this.options.display;return"auto"!==t?!!t:this.getMatchingVisibleMetas().length>0}_computeGridLineItems(t){const i=this.axis,e=this.chart,s=this.options,{grid:n,position:r,border:o}=s,h=n.offset,a=this.isHorizontal(),c=this.ticks.length+(h?1:0),l=ls(n),u=[],f=o.setContext(this.getContext()),d=f.display?f.width:0,b=d/2,g=function(t){return ti(e,t,d)};let p,m,x,v,y,M,w,_,k,O,S,A;if("top"===r)p=g(this.bottom),M=this.bottom-l,_=p-b,O=g(t.top)+b,A=t.bottom;else if("bottom"===r)p=g(this.top),O=t.top,A=g(t.bottom)-b,M=p+b,_=this.top+l;else if("left"===r)p=g(this.right),y=this.right-l,w=p-b,k=g(t.left)+b,S=t.right;else if("right"===r)p=g(this.left),k=t.left,S=g(t.right)-b,y=p+b,w=this.left+l;else if("x"===i){if("center"===r)p=g((t.top+t.bottom)/2+.5);else if(H(r)){const t=Object.keys(r)[0];p=g(this.chart.scales[t].getPixelForValue(r[t]))}O=t.top,A=t.bottom,M=p+b,_=M+l}else if("y"===i){if("center"===r)p=g((t.left+t.right)/2);else if(H(r)){const t=Object.keys(r)[0];p=g(this.chart.scales[t].getPixelForValue(r[t]))}y=p-b,w=y-l,k=t.left,S=t.right}const D=V(s.ticks.maxTicksLimit,c),j=Math.max(1,Math.ceil(c/D));for(m=0;m<c;m+=j){const t=this.getContext(m),i=n.setContext(t),s=o.setContext(t),r=i.lineWidth,c=i.color,l=s.dash||[],f=s.dashOffset,d=i.tickWidth,b=i.tickColor,g=i.tickBorderDash||[],p=i.tickBorderDashOffset;x=cs(this,m,h),void 0!==x&&(v=ti(e,x,r),a?y=w=k=S=v:M=_=O=A=v,u.push({tx1:y,ty1:M,tx2:w,ty2:_,x1:k,y1:O,x2:S,y2:A,width:r,color:c,borderDash:l,borderDashOffset:f,tickWidth:d,tickColor:b,tickBorderDash:g,tickBorderDashOffset:p}))}return this._ticksLength=c,this._borderValue=p,u}_computeLabelItems(t){const i=this.axis,e=this.options,{position:s,ticks:n}=e,r=this.isHorizontal(),o=this.ticks,{align:h,crossAlign:a,padding:c,mirror:l}=n,u=ls(e.grid),f=u+c,d=l?-c:f,b=-yt(this.labelRotation),g=[];let p,m,x,v,y,M,w,_,k,O,S,A,D="middle";if("top"===s)M=this.bottom-d,w=this._getXAxisLabelAlignment();else if("bottom"===s)M=this.top+d,w=this._getXAxisLabelAlignment();else if("left"===s){const t=this._getYAxisLabelAlignment(u);w=t.textAlign,y=t.x}else if("right"===s){const t=this._getYAxisLabelAlignment(u);w=t.textAlign,y=t.x}else if("x"===i){if("center"===s)M=(t.top+t.bottom)/2+f;else if(H(s)){const t=Object.keys(s)[0];M=this.chart.scales[t].getPixelForValue(s[t])+f}w=this._getXAxisLabelAlignment()}else if("y"===i){if("center"===s)y=(t.left+t.right)/2-f;else if(H(s)){const t=Object.keys(s)[0];y=this.chart.scales[t].getPixelForValue(s[t])}w=this._getYAxisLabelAlignment(u).textAlign}"y"===i&&("start"===h?D="top":"end"===h&&(D="bottom"));const j=this._getLabelSizes();for(p=0,m=o.length;p<m;++p){x=o[p],v=x.label;const t=n.setContext(this.getContext(p));_=this.getPixelForTick(p)+n.labelOffset,k=this._resolveTickFontOptions(p),O=k.lineHeight,S=z(v)?v.length:1;const i=S/2,e=t.color,h=t.textStrokeColor,c=t.textStrokeWidth;let u,f=w;if(r?(y=_,"inner"===w&&(f=p===m-1?this.options.reverse?"left":"right":0===p?this.options.reverse?"right":"left":"center"),A="top"===s?"near"===a||0!==b?-S*O+O/2:"center"===a?-j.highest.height/2-i*O+O:O/2-j.highest.height:"near"===a||0!==b?O/2:"center"===a?j.highest.height/2-i*O:j.highest.height-S*O,l&&(A*=-1),0===b||t.showLabelBackdrop||(y+=O/2*Math.sin(b))):(M=_,A=(1-S)*O/2),t.showLabelBackdrop){const i=mi(t.backdropPadding),e=j.heights[p],s=j.widths[p];let n=A-i.top,r=0-i.left;switch(D){case"middle":n-=e/2;break;case"bottom":n-=e}switch(w){case"center":r-=s/2;break;case"right":r-=s;break;case"inner":p===m-1?r-=s:p>0&&(r-=s/2)}u={left:r,top:n,width:s+i.width,height:e+i.height,color:t.backdropColor}}g.push({label:v,font:k,textOffset:A,options:{rotation:b,color:e,strokeColor:h,strokeWidth:c,textAlign:f,textBaseline:D,translation:[y,M],backdrop:u}})}return g}_getXAxisLabelAlignment(){const{position:t,ticks:i}=this.options;if(-yt(this.labelRotation))return"top"===t?"left":"right";let e="center";return"start"===i.align?e="left":"end"===i.align?e="right":"inner"===i.align&&(e="inner"),e}_getYAxisLabelAlignment(t){const{position:i,ticks:{crossAlign:e,mirror:s,padding:n}}=this.options,r=t+n,o=this._getLabelSizes().widest.width;let h,a;return"left"===i?s?(a=this.right+n,"near"===e?h="left":"center"===e?(h="center",a+=o/2):(h="right",a+=o)):(a=this.right-r,"near"===e?h="right":"center"===e?(h="center",a-=o/2):(h="left",a=this.left)):"right"===i?s?(a=this.left+n,"near"===e?h="right":"center"===e?(h="center",a-=o/2):(h="left",a-=o)):(a=this.left+r,"near"===e?h="left":"center"===e?(h="center",a+=o/2):(h="right",a=this.right)):h="right",{textAlign:h,x:a}}_computeLabelArea(){if(this.options.ticks.mirror)return;const t=this.chart,i=this.options.position;return"left"===i||"right"===i?{top:0,left:this.left,bottom:t.height,right:this.right}:"top"===i||"bottom"===i?{top:this.top,left:0,bottom:this.bottom,right:t.width}:void 0}drawBackground(){const{ctx:t,options:{backgroundColor:i},left:e,top:s,width:n,height:r}=this;i&&(t.save(),t.fillStyle=i,t.fillRect(e,s,n,r),t.restore())}getLineWidthForValue(t){const i=this.options.grid;if(!this._isVisible()||!i.display)return 0;const e=this.ticks.findIndex((i=>i.value===t));return e>=0?i.setContext(this.getContext(e)).lineWidth:0}drawGrid(t){const i=this.options.grid,e=this.ctx,s=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(t));let n,r;const o=(t,i,s)=>{s.width&&s.color&&(e.save(),e.lineWidth=s.width,e.strokeStyle=s.color,e.setLineDash(s.borderDash||[]),e.lineDashOffset=s.borderDashOffset,e.beginPath(),e.moveTo(t.x,t.y),e.lineTo(i.x,i.y),e.stroke(),e.restore())};if(i.display)for(n=0,r=s.length;n<r;++n){const t=s[n];i.drawOnChartArea&&o({x:t.x1,y:t.y1},{x:t.x2,y:t.y2},t),i.drawTicks&&o({x:t.tx1,y:t.ty1},{x:t.tx2,y:t.ty2},{color:t.tickColor,width:t.tickWidth,borderDash:t.tickBorderDash,borderDashOffset:t.tickBorderDashOffset})}}drawBorder(){const{chart:t,ctx:i,options:{border:e,grid:s}}=this,n=e.setContext(this.getContext()),r=e.display?n.width:0;if(!r)return;const o=s.setContext(this.getContext(0)).lineWidth,h=this._borderValue;let a,c,l,u;this.isHorizontal()?(a=ti(t,this.left,r)-r/2,c=ti(t,this.right,o)+o/2,l=u=h):(l=ti(t,this.top,r)-r/2,u=ti(t,this.bottom,o)+o/2,a=c=h),i.save(),i.lineWidth=n.width,i.strokeStyle=n.color,i.beginPath(),i.moveTo(a,l),i.lineTo(c,u),i.stroke(),i.restore()}drawLabels(t){if(!this.options.ticks.display)return;const i=this.ctx,e=this._computeLabelArea();e&&ri(i,e);const s=this.getLabelItems(t);for(const t of s)ci(i,t.label,0,t.textOffset,t.font,t.options);e&&oi(i)}drawTitle(){const{ctx:t,options:{position:i,title:e,reverse:s}}=this;if(!e.display)return;const n=xi(e.font),r=mi(e.padding),o=e.align;let h=n.lineHeight/2;"bottom"===i||"center"===i||H(i)?(h+=r.bottom,z(e.text)&&(h+=n.lineHeight*(e.text.length-1))):h+=r.top;const{titleX:a,titleY:c,maxWidth:l,rotation:u}=function(t,i,e,s){const{top:n,left:r,bottom:o,right:h,chart:a}=t,{chartArea:c,scales:l}=a;let u,f,d,b=0;const g=o-n,p=h-r;if(t.isHorizontal()){if(f=Pt(s,r,h),H(e)){const t=Object.keys(e)[0];d=l[t].getPixelForValue(e[t])+g-i}else d="center"===e?(c.bottom+c.top)/2+g-i:os(t,e,i);u=h-r}else{if(H(e)){const t=Object.keys(e)[0];f=l[t].getPixelForValue(e[t])-p+i}else f="center"===e?(c.left+c.right)/2-p+i:os(t,e,i);d=Pt(s,o,n),b="left"===e?-ft:ft}return{titleX:f,titleY:d,maxWidth:u,rotation:b}}(this,h,i,o);ci(t,e.text,0,0,n,{color:e.color,maxWidth:l,rotation:u,textAlign:fs(o,i,s),textBaseline:"middle",translation:[a,c]})}draw(t){this._isVisible()&&(this.drawBackground(),this.drawGrid(t),this.drawBorder(),this.drawTitle(),this.drawLabels(t))}_layers(){const t=this.options,i=t.ticks&&t.ticks.z||0,e=V(t.grid&&t.grid.z,-1),s=V(t.border&&t.border.z,0);return this._isVisible()&&this.draw===ds.prototype.draw?[{z:e,draw:t=>{this.drawBackground(),this.drawGrid(t),this.drawTitle()}},{z:s,draw:()=>{this.drawBorder()}},{z:i,draw:t=>{this.drawLabels(t)}}]:[{z:i,draw:t=>{this.draw(t)}}]}getMatchingVisibleMetas(t){const i=this.chart.getSortedVisibleDatasetMetas(),e=this.axis+"AxisID",s=[];let n,r;for(n=0,r=i.length;n<r;++n){const r=i[n];r[e]!==this.id||t&&r.type!==t||s.push(r)}return s}_resolveTickFontOptions(t){return xi(this.options.ticks.setContext(this.getContext(t)).font)}_maxDigits(){const t=this._resolveTickFontOptions(0).lineHeight;return(this.isHorizontal()?this.width:this.height)/t}}class bs{constructor(t,i,e){this.type=t,this.scope=i,this.override=e,this.items=Object.create(null)}isForType(t){return Object.prototype.isPrototypeOf.call(this.type.prototype,t.prototype)}register(t){const i=Object.getPrototypeOf(t);let e;(function(t){return"id"in t&&"defaults"in t})(i)&&(e=this.register(i));const s=this.items,n=t.id,r=this.scope+"."+n;if(!n)throw new Error("class does not have id: "+t);return n in s||(s[n]=t,function(t,i,e){const s=J(Object.create(null),[e?Gt.get(e):{},Gt.get(i),t.defaults]);Gt.set(i,s),t.defaultRoutes&&function(t,i){Object.keys(i).forEach((e=>{const s=e.split("."),n=s.pop(),r=[t].concat(s).join("."),o=i[e].split("."),h=o.pop(),a=o.join(".");Gt.route(r,n,a,h)}))}(i,t.defaultRoutes),t.descriptors&&Gt.describe(i,t.descriptors)}(t,r,e),this.override&&Gt.override(t.id,t.overrides)),r}get(t){return this.items[t]}unregister(t){const i=this.items,e=t.id,s=this.scope;e in i&&delete i[e],s&&e in Gt[s]&&(delete Gt[s][e],this.override&&delete Ut[e])}}class gs{constructor(){this.controllers=new bs(de,"datasets",!0),this.elements=new bs(ns,"elements"),this.plugins=new bs(Object,"plugins"),this.scales=new bs(ds,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...t){this._each("register",t)}remove(...t){this._each("unregister",t)}addControllers(...t){this._each("register",t,this.controllers)}addElements(...t){this._each("register",t,this.elements)}addPlugins(...t){this._each("register",t,this.plugins)}addScales(...t){this._each("register",t,this.scales)}getController(t){return this._get(t,this.controllers,"controller")}getElement(t){return this._get(t,this.elements,"element")}getPlugin(t){return this._get(t,this.plugins,"plugin")}getScale(t){return this._get(t,this.scales,"scale")}removeControllers(...t){this._each("unregister",t,this.controllers)}removeElements(...t){this._each("unregister",t,this.elements)}removePlugins(...t){this._each("unregister",t,this.plugins)}removeScales(...t){this._each("unregister",t,this.scales)}_each(t,i,e){[...i].forEach((i=>{const s=e||this._getRegistryForType(i);e||s.isForType(i)||s===this.plugins&&i.id?this._exec(t,s,i):Z(i,(i=>{const s=e||this._getRegistryForType(i);this._exec(t,s,i)}))}))}_exec(t,i,e){const s=nt(t);U(e["before"+s],[],e),i[t](e),U(e["after"+s],[],e)}_getRegistryForType(t){for(let i=0;i<this._typedRegistries.length;i++){const e=this._typedRegistries[i];if(e.isForType(t))return e}return this.plugins}_get(t,i,e){const s=i.get(t);if(void 0===s)throw new Error('"'+t+'" is not a registered '+e+".");return s}}var ps=new gs;class ms{constructor(){this._init=void 0}notify(t,i,e,s){if("beforeInit"===i&&(this._init=this._createDescriptors(t,!0),this._notify(this._init,t,"install")),void 0===this._init)return;const n=s?this._descriptors(t).filter(s):this._descriptors(t),r=this._notify(n,t,i,e);return"afterDestroy"===i&&(this._notify(n,t,"stop"),this._notify(this._init,t,"uninstall"),this._init=void 0),r}_notify(t,i,e,s){s=s||{};for(const n of t){const t=n.plugin;if(!1===U(t[e],[i,s,n.options],t)&&s.cancelable)return!1}return!0}invalidate(){N(this._cache)||(this._oldCache=this._cache,this._cache=void 0)}_descriptors(t){if(this._cache)return this._cache;const i=this._cache=this._createDescriptors(t);return this._notifyStateChanges(t),i}_createDescriptors(t,i){const e=t&&t.config,s=V(e.options&&e.options.plugins,{}),n=function(t){const i={},e=[],s=Object.keys(ps.plugins.items);for(let t=0;t<s.length;t++)e.push(ps.getPlugin(s[t]));const n=t.plugins||[];for(let t=0;t<n.length;t++){const s=n[t];-1===e.indexOf(s)&&(e.push(s),i[s.id]=!0)}return{plugins:e,localIds:i}}(e);return!1!==s||i?function(t,{plugins:i,localIds:e},s,n){const r=[],o=t.getContext();for(const h of i){const i=h.id,a=xs(s[i],n);null!==a&&r.push({plugin:h,options:vs(t.config,{plugin:h,local:e[i]},a,o)})}return r}(t,n,s,i):[]}_notifyStateChanges(t){const i=this._oldCache||[],e=this._cache,s=(t,i)=>t.filter((t=>!i.some((i=>t.plugin.id===i.plugin.id))));this._notify(s(i,e),t,"stop"),this._notify(s(e,i),t,"start")}}function xs(t,i){return i||!1!==t?!0===t?{}:t:null}function vs(t,{plugin:i,local:e},s,n){const r=t.pluginScopeKeys(i),o=t.getOptionScopes(s,r);return e&&i.defaults&&o.push(i.defaults),t.createResolver(o,n,[""],{scriptable:!1,indexable:!1,allKeys:!0})}function ys(t,i){return((i.datasets||{})[t]||{}).indexAxis||i.indexAxis||(Gt.datasets[t]||{}).indexAxis||"x"}function Ms(t){if("x"===t||"y"===t||"r"===t)return t}function ws(t,...i){if(Ms(t))return t;for(const s of i){const i=s.axis||("top"===(e=s.position)||"bottom"===e?"x":"left"===e||"right"===e?"y":void 0)||t.length>1&&Ms(t[0].toLowerCase());if(i)return i}var e;throw new Error(`Cannot determine type of '${t}' axis. Please provide 'axis' or 'position' option.`)}function _s(t,i,e){if(e[i+"AxisID"]===t)return{axis:i}}function ks(t){const i=t.options||(t.options={});i.plugins=V(i.plugins,{}),i.scales=function(t,i){const e=Ut[t.type]||{scales:{}},s=i.scales||{},n=ys(t.type,i),r=Object.create(null);return Object.keys(s).forEach((i=>{const o=s[i];if(!H(o))return console.error(`Invalid scale configuration for scale: ${i}`);if(o._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${i}`);const h=ws(i,o,function(t,i){if(i.data&&i.data.datasets){const e=i.data.datasets.filter((i=>i.xAxisID===t||i.yAxisID===t));if(e.length)return _s(t,"x",e[0])||_s(t,"y",e[0])}return{}}(i,t),Gt.scales[o.type]),a=function(t,i){return t===i?"_index_":"_value_"}(h,n),c=e.scales||{};r[i]=tt(Object.create(null),[{axis:h},o,c[h],c[a]])})),t.data.datasets.forEach((e=>{const n=e.type||t.type,o=e.indexAxis||ys(n,i),h=(Ut[n]||{}).scales||{};Object.keys(h).forEach((t=>{const i=function(t,i){let e=t;return"_index_"===t?e=i:"_value_"===t&&(e="x"===i?"y":"x"),e}(t,o),n=e[i+"AxisID"]||i;r[n]=r[n]||Object.create(null),tt(r[n],[{axis:i},s[n],h[t]])}))})),Object.keys(r).forEach((t=>{const i=r[t];tt(i,[Gt.scales[i.type],Gt.scale])})),r}(t,i)}function Os(t){return(t=t||{}).datasets=t.datasets||[],t.labels=t.labels||[],t}const Ss=new Map,As=new Set;function Ds(t,i){let e=Ss.get(t);return e||(e=i(),Ss.set(t,e),As.add(e)),e}const js=(t,i,e)=>{const s=st(i,e);void 0!==s&&t.add(s)};class Rs{constructor(t){this._config=function(t){return(t=t||{}).data=Os(t.data),ks(t),t}(t),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(t){this._config.type=t}get data(){return this._config.data}set data(t){this._config.data=Os(t)}get options(){return this._config.options}set options(t){this._config.options=t}get plugins(){return this._config.plugins}update(){const t=this._config;this.clearCache(),ks(t)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(t){return Ds(t,(()=>[[`datasets.${t}`,""]]))}datasetAnimationScopeKeys(t,i){return Ds(`${t}.transition.${i}`,(()=>[[`datasets.${t}.transitions.${i}`,`transitions.${i}`],[`datasets.${t}`,""]]))}datasetElementScopeKeys(t,i){return Ds(`${t}-${i}`,(()=>[[`datasets.${t}.elements.${i}`,`datasets.${t}`,`elements.${i}`,""]]))}pluginScopeKeys(t){const i=t.id;return Ds(`${this.type}-plugin-${i}`,(()=>[[`plugins.${i}`,...t.additionalOptionScopes||[]]]))}_cachedScopes(t,i){const e=this._scopeCache;let s=e.get(t);return s&&!i||(s=new Map,e.set(t,s)),s}getOptionScopes(t,i,e){const{options:s,type:n}=this,r=this._cachedScopes(t,e),o=r.get(i);if(o)return o;const h=new Set;i.forEach((i=>{t&&(h.add(t),i.forEach((i=>js(h,t,i)))),i.forEach((t=>js(h,s,t))),i.forEach((t=>js(h,Ut[n]||{},t))),i.forEach((t=>js(h,Gt,t))),i.forEach((t=>js(h,Zt,t)))}));const a=Array.from(h);return 0===a.length&&a.push(Object.create(null)),As.has(i)&&r.set(i,a),a}chartOptionScopes(){const{options:t,type:i}=this;return[t,Ut[i]||{},Gt.datasets[i]||{},{type:i},Gt,Zt]}resolveNamedOptions(t,i,e,s=[""]){const n={$shared:!0},{resolver:r,subPrefixes:o}=Cs(this._resolverCache,t,s);let h=r;(function(t,i){const{isScriptable:e,isIndexable:s}=_i(t);for(const n of i){const i=e(n),r=s(n),o=(r||i)&&t[n];if(i&&(ot(o)||Es(o))||r&&z(o))return!0}return!1})(r,i)&&(n.$shared=!1,h=wi(r,e=ot(e)?e():e,this.createResolver(t,e,o)));for(const t of i)n[t]=h[t];return n}createResolver(t,i,e=[""],s){const{resolver:n}=Cs(this._resolverCache,t,e);return H(i)?wi(n,i,void 0,s):n}}function Cs(t,i,e){let s=t.get(i);s||(s=new Map,t.set(i,s));const n=e.join();let r=s.get(n);return r||(r={resolver:Mi(i,e),subPrefixes:e.filter((t=>!t.toLowerCase().includes("hover")))},s.set(n,r)),r}const Es=t=>H(t)&&Object.getOwnPropertyNames(t).some((i=>ot(t[i]))),Ls=["top","bottom","left","right","chartArea"];function Ps(t,i){return"top"===t||"bottom"===t||-1===Ls.indexOf(t)&&"x"===i}function Ts(t,i){return function(e,s){return e[t]===s[t]?e[i]-s[i]:e[t]-s[t]}}function Is(t){const i=t.chart,e=i.options.animation;i.notifyPlugins("afterRender"),U(e&&e.onComplete,[t],i)}function Fs(t){const i=t.chart,e=i.options.animation;U(e&&e.onProgress,[t],i)}function Bs(t){return Ti()&&"string"==typeof t?t=document.getElementById(t):t&&t.length&&(t=t[0]),t&&t.canvas&&(t=t.canvas),t}const Ws={},Ns=t=>{const i=Bs(t);return Object.values(Ws).filter((t=>t.canvas===i)).pop()};function zs(t,i,e){const s=Object.keys(t);for(const n of s){const s=+n;if(s>=i){const r=t[n];delete t[n],(e>0||s>i)&&(t[s+e]=r)}}}class Hs{static defaults=Gt;static instances=Ws;static overrides=Ut;static registry=ps;static version="4.5.1";static getChart=Ns;static register(...t){ps.add(...t),$s()}static unregister(...t){ps.remove(...t),$s()}constructor(t,i){const e=this.config=new Rs(i),s=Bs(t),n=Ns(s);if(n)throw new Error("Canvas is already in use. Chart with ID '"+n.id+"' must be destroyed before the canvas with ID '"+n.canvas.id+"' can be reused.");const r=e.createResolver(e.chartOptionScopes(),this.getContext());this.platform=new(e.platform||function(t){return!Ti()||"undefined"!=typeof OffscreenCanvas&&t instanceof OffscreenCanvas?He:ss}(s)),this.platform.updateConfig(e);const o=this.platform.acquireContext(s,r.aspectRatio),h=o&&o.canvas,a=h&&h.height,c=h&&h.width;this.id=W(),this.ctx=o,this.canvas=h,this.width=c,this.height=a,this._options=r,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new ms,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=function(t,i){let e;return function(...s){return i?(clearTimeout(e),e=setTimeout(t,i,s)):t.apply(this,s),i}}((t=>this.update(t)),r.resizeDelay||0),this._dataChanges=[],Ws[this.id]=this,o&&h?(qi.listen(this,"complete",Is),qi.listen(this,"progress",Fs),this._initialize(),this.attached&&this.update()):console.error("Failed to create chart: can't acquire context from the given item")}get aspectRatio(){const{options:{aspectRatio:t,maintainAspectRatio:i},width:e,height:s,_aspectRatio:n}=this;return N(t)?i&&n?n:s?e/s:null:t}get data(){return this.config.data}set data(t){this.config.data=t}get options(){return this._options}set options(t){this.config.options=t}get registry(){return ps}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():$i(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return ii(this.canvas,this.ctx),this}stop(){return qi.stop(this),this}resize(t,i){qi.running(this)?this._resizeBeforeDraw={width:t,height:i}:this._resize(t,i)}_resize(t,i){const e=this.options,s=this.platform.getMaximumSize(this.canvas,t,i,e.maintainAspectRatio&&this.aspectRatio),n=e.devicePixelRatio||this.platform.getDevicePixelRatio(),r=this.width?"resize":"attach";this.width=s.width,this.height=s.height,this._aspectRatio=this.aspectRatio,$i(this,n,!0)&&(this.notifyPlugins("resize",{size:s}),U(e.onResize,[this,s],this),this.attached&&this._doResize(r)&&this.render())}ensureScalesHaveIDs(){Z(this.options.scales||{},((t,i)=>{t.id=i}))}buildOrUpdateScales(){const t=this.options,i=t.scales,e=this.scales,s=Object.keys(e).reduce(((t,i)=>(t[i]=!1,t)),{});let n=[];i&&(n=n.concat(Object.keys(i).map((t=>{const e=i[t],s=ws(t,e),n="r"===s,r="x"===s;return{options:e,dposition:n?"chartArea":r?"bottom":"left",dtype:n?"radialLinear":r?"category":"linear"}})))),Z(n,(i=>{const n=i.options,r=n.id,o=ws(r,n),h=V(n.type,i.dtype);void 0!==n.position&&Ps(n.position,o)===Ps(i.dposition)||(n.position=i.dposition),s[r]=!0;let a=null;r in e&&e[r].type===h?a=e[r]:(a=new(ps.getScale(h))({id:r,type:h,ctx:this.ctx,chart:this}),e[a.id]=a),a.init(n,t)})),Z(s,((t,i)=>{t||delete e[i]})),Z(e,(t=>{Ne.configure(this,t,t.options),Ne.addBox(this,t)}))}_updateMetasets(){const t=this._metasets,i=this.data.datasets.length,e=t.length;if(t.sort(((t,i)=>t.index-i.index)),e>i){for(let t=i;t<e;++t)this._destroyDatasetMeta(t);t.splice(i,e-i)}this._sortedMetasets=t.slice(0).sort(Ts("order","index"))}_removeUnreferencedMetasets(){const{_metasets:t,data:{datasets:i}}=this;t.length>i.length&&delete this._stacks,t.forEach(((t,e)=>{0===i.filter((i=>i===t._dataset)).length&&this._destroyDatasetMeta(e)}))}buildOrUpdateControllers(){const t=[],i=this.data.datasets;let e,s;for(this._removeUnreferencedMetasets(),e=0,s=i.length;e<s;e++){const s=i[e];let n=this.getDatasetMeta(e);const r=s.type||this.config.type;if(n.type&&n.type!==r&&(this._destroyDatasetMeta(e),n=this.getDatasetMeta(e)),n.type=r,n.indexAxis=s.indexAxis||ys(r,this.options),n.order=s.order||0,n.index=e,n.label=""+s.label,n.visible=this.isDatasetVisible(e),n.controller)n.controller.updateIndex(e),n.controller.linkScales();else{const i=ps.getController(r),{datasetElementType:s,dataElementType:o}=Gt.datasets[r];Object.assign(i,{dataElementType:ps.getElement(o),datasetElementType:s&&ps.getElement(s)}),n.controller=new i(this,e),t.push(n.controller)}}return this._updateMetasets(),t}_resetElements(){Z(this.data.datasets,((t,i)=>{this.getDatasetMeta(i).controller.reset()}),this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(t){const i=this.config;i.update();const e=this._options=i.createResolver(i.chartOptionScopes(),this.getContext()),s=this._animationsDisabled=!e.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),!1===this.notifyPlugins("beforeUpdate",{mode:t,cancelable:!0}))return;const n=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let r=0;for(let t=0,i=this.data.datasets.length;t<i;t++){const{controller:i}=this.getDatasetMeta(t),e=!s&&-1===n.indexOf(i);i.buildOrUpdateElements(e),r=Math.max(+i.getMaxOverflow(),r)}r=this._minPadding=e.layout.autoPadding?r:0,this._updateLayout(r),s||Z(n,(t=>{t.reset()})),this._updateDatasets(t),this.notifyPlugins("afterUpdate",{mode:t}),this._layers.sort(Ts("z","_idx"));const{_active:o,_lastEvent:h}=this;h?this._eventHandler(h,!0):o.length&&this._updateHoverStyles(o,o,!0),this.render()}_updateScales(){Z(this.scales,(t=>{Ne.removeBox(this,t)})),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const t=this.options,i=new Set(Object.keys(this._listeners)),e=new Set(t.events);ht(i,e)&&!!this._responsiveListeners===t.responsive||(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){const{_hiddenIndices:t}=this,i=this._getUniformDataChanges()||[];for(const{method:e,start:s,count:n}of i)zs(t,s,"_removeElements"===e?-n:n)}_getUniformDataChanges(){const t=this._dataChanges;if(!t||!t.length)return;this._dataChanges=[];const i=this.data.datasets.length,e=i=>new Set(t.filter((t=>t[0]===i)).map(((t,i)=>i+","+t.splice(1).join(",")))),s=e(0);for(let t=1;t<i;t++)if(!ht(s,e(t)))return;return Array.from(s).map((t=>t.split(","))).map((t=>({method:t[1],start:+t[2],count:+t[3]})))}_updateLayout(t){if(!1===this.notifyPlugins("beforeLayout",{cancelable:!0}))return;Ne.update(this,this.width,this.height,t);const i=this.chartArea,e=i.width<=0||i.height<=0;this._layers=[],Z(this.boxes,(t=>{e&&"chartArea"===t.position||(t.configure&&t.configure(),this._layers.push(...t._layers()))}),this),this._layers.forEach(((t,i)=>{t._idx=i})),this.notifyPlugins("afterLayout")}_updateDatasets(t){if(!1!==this.notifyPlugins("beforeDatasetsUpdate",{mode:t,cancelable:!0})){for(let t=0,i=this.data.datasets.length;t<i;++t)this.getDatasetMeta(t).controller.configure();for(let i=0,e=this.data.datasets.length;i<e;++i)this._updateDataset(i,ot(t)?t({datasetIndex:i}):t);this.notifyPlugins("afterDatasetsUpdate",{mode:t})}}_updateDataset(t,i){const e=this.getDatasetMeta(t),s={meta:e,index:t,mode:i,cancelable:!0};!1!==this.notifyPlugins("beforeDatasetUpdate",s)&&(e.controller._update(i),s.cancelable=!1,this.notifyPlugins("afterDatasetUpdate",s))}render(){!1!==this.notifyPlugins("beforeRender",{cancelable:!0})&&(qi.has(this)?this.attached&&!qi.running(this)&&qi.start(this):(this.draw(),Is({chart:this})))}draw(){let t;if(this._resizeBeforeDraw){const{width:t,height:i}=this._resizeBeforeDraw;this._resizeBeforeDraw=null,this._resize(t,i)}if(this.clear(),this.width<=0||this.height<=0)return;if(!1===this.notifyPlugins("beforeDraw",{cancelable:!0}))return;const i=this._layers;for(t=0;t<i.length&&i[t].z<=0;++t)i[t].draw(this.chartArea);for(this._drawDatasets();t<i.length;++t)i[t].draw(this.chartArea);this.notifyPlugins("afterDraw")}_getSortedDatasetMetas(t){const i=this._sortedMetasets,e=[];let s,n;for(s=0,n=i.length;s<n;++s){const n=i[s];t&&!n.visible||e.push(n)}return e}getSortedVisibleDatasetMetas(){return this._getSortedDatasetMetas(!0)}_drawDatasets(){if(!1===this.notifyPlugins("beforeDatasetsDraw",{cancelable:!0}))return;const t=this.getSortedVisibleDatasetMetas();for(let i=t.length-1;i>=0;--i)this._drawDataset(t[i]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(t){const i=this.ctx,e={meta:t,index:t.index,cancelable:!0},s=function(t,i){const e=i._clip;if(e.disabled)return!1;const s=function(t,i){const{xScale:e,yScale:s}=t;return e&&s?{left:Ki(e,i,"left"),right:Ki(e,i,"right"),top:Ki(s,i,"top"),bottom:Ki(s,i,"bottom")}:i}(i,t.chartArea);return{left:!1===e.left?0:s.left-(!0===e.left?0:e.left),right:!1===e.right?t.width:s.right+(!0===e.right?0:e.right),top:!1===e.top?0:s.top-(!0===e.top?0:e.top),bottom:!1===e.bottom?t.height:s.bottom+(!0===e.bottom?0:e.bottom)}}(this,t);!1!==this.notifyPlugins("beforeDatasetDraw",e)&&(s&&ri(i,s),t.controller.draw(),s&&oi(i),e.cancelable=!1,this.notifyPlugins("afterDatasetDraw",e))}isPointInArea(t){return ni(t,this.chartArea,this._minPadding)}getElementsAtEventForMode(t,i,e,s){const n=De.modes[i];return"function"==typeof n?n(this,t,e,s):[]}getDatasetMeta(t){const i=this.data.datasets[t],e=this._metasets;let s=e.filter((t=>t&&t._dataset===i)).pop();return s||(s={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:i&&i.order||0,index:t,_dataset:i,_parsed:[],_sorted:!1},e.push(s)),s}getContext(){return this.$context||(this.$context=yi(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){const i=this.data.datasets[t];if(!i)return!1;const e=this.getDatasetMeta(t);return"boolean"==typeof e.hidden?!e.hidden:!i.hidden}setDatasetVisibility(t,i){this.getDatasetMeta(t).hidden=!i}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateVisibility(t,i,e){const s=e?"show":"hide",n=this.getDatasetMeta(t),r=n.controller._resolveAnimations(void 0,s);rt(i)?(n.data[i].hidden=!e,this.update()):(this.setDatasetVisibility(t,e),r.update(n,{visible:e}),this.update((i=>i.datasetIndex===t?s:void 0)))}hide(t,i){this._updateVisibility(t,i,!1)}show(t,i){this._updateVisibility(t,i,!0)}_destroyDatasetMeta(t){const i=this._metasets[t];i&&i.controller&&i.controller._destroy(),delete this._metasets[t]}_stop(){let t,i;for(this.stop(),qi.remove(this),t=0,i=this.data.datasets.length;t<i;++t)this._destroyDatasetMeta(t)}destroy(){this.notifyPlugins("beforeDestroy");const{canvas:t,ctx:i}=this;this._stop(),this.config.clearCache(),t&&(this.unbindEvents(),ii(t,i),this.platform.releaseContext(i),this.canvas=null,this.ctx=null),delete Ws[this.id],this.notifyPlugins("afterDestroy")}toBase64Image(...t){return this.canvas.toDataURL(...t)}bindEvents(){this.bindUserEvents(),this.options.responsive?this.bindResponsiveEvents():this.attached=!0}bindUserEvents(){const t=this._listeners,i=this.platform,e=(e,s)=>{i.addEventListener(this,e,s),t[e]=s},s=(t,i,e)=>{t.offsetX=i,t.offsetY=e,this._eventHandler(t)};Z(this.options.events,(t=>e(t,s)))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const t=this._responsiveListeners,i=this.platform,e=(e,s)=>{i.addEventListener(this,e,s),t[e]=s},s=(e,s)=>{t[e]&&(i.removeEventListener(this,e,s),delete t[e])},n=(t,i)=>{this.canvas&&this.resize(t,i)};let r;const o=()=>{s("attach",o),this.attached=!0,this.resize(),e("resize",n),e("detach",r)};r=()=>{this.attached=!1,s("resize",n),this._stop(),this._resize(0,0),e("attach",o)},i.isAttached(this.canvas)?o():r()}unbindEvents(){Z(this._listeners,((t,i)=>{this.platform.removeEventListener(this,i,t)})),this._listeners={},Z(this._responsiveListeners,((t,i)=>{this.platform.removeEventListener(this,i,t)})),this._responsiveListeners=void 0}updateHoverStyle(t,i,e){const s=e?"set":"remove";let n,r,o,h;for("dataset"===i&&(n=this.getDatasetMeta(t[0].datasetIndex),n.controller["_"+s+"DatasetHoverStyle"]()),o=0,h=t.length;o<h;++o){r=t[o];const i=r&&this.getDatasetMeta(r.datasetIndex).controller;i&&i[s+"HoverStyle"](r.element,r.datasetIndex,r.index)}}getActiveElements(){return this._active||[]}setActiveElements(t){const i=this._active||[],e=t.map((({datasetIndex:t,index:i})=>{const e=this.getDatasetMeta(t);if(!e)throw new Error("No dataset found at index "+t);return{datasetIndex:t,element:e.data[i],index:i}}));!K(e,i)&&(this._active=e,this._lastEvent=null,this._updateHoverStyles(e,i))}notifyPlugins(t,i,e){return this._plugins.notify(this,t,i,e)}isPluginEnabled(t){return 1===this._plugins._cache.filter((i=>i.plugin.id===t)).length}_updateHoverStyles(t,i,e){const s=this.options.hover,n=(t,i)=>t.filter((t=>!i.some((i=>t.datasetIndex===i.datasetIndex&&t.index===i.index)))),r=n(i,t),o=e?t:n(t,i);r.length&&this.updateHoverStyle(r,s.mode,!1),o.length&&s.mode&&this.updateHoverStyle(o,s.mode,!0)}_eventHandler(t,i){const e={event:t,replay:i,cancelable:!0,inChartArea:this.isPointInArea(t)},s=i=>(i.options.events||this.options.events).includes(t.native.type);if(!1===this.notifyPlugins("beforeEvent",e,s))return;const n=this._handleEvent(t,i,e.inChartArea);return e.cancelable=!1,this.notifyPlugins("afterEvent",e,s),(n||e.changed)&&this.render(),this}_handleEvent(t,i,e){const{_active:s=[],options:n}=this,r=this._getActiveElements(t,s,e,i),o=function(t){return"mouseup"===t.type||"click"===t.type||"contextmenu"===t.type}(t),h=function(t,i,e,s){return e&&"mouseout"!==t.type?s?i:t:null}(t,this._lastEvent,e,o);e&&(this._lastEvent=null,U(n.onHover,[t,r,this],this),o&&U(n.onClick,[t,r,this],this));const a=!K(r,s);return(a||i)&&(this._active=r,this._updateHoverStyles(r,s,i)),this._lastEvent=h,a}_getActiveElements(t,i,e,s){if("mouseout"===t.type)return[];if(!e)return i;const n=this.options.hover;return this.getElementsAtEventForMode(t,n.mode,n,s)}}function $s(){return Z(Hs.instances,(t=>t._plugins.invalidate()))}function Ys(t,i){const{x:e,y:s,base:n,width:r,height:o}=t.getProps(["x","y","base","width","height"],i);let h,a,c,l,u;return t.horizontal?(u=o/2,h=Math.min(e,n),a=Math.max(e,n),c=s-u,l=s+u):(u=r/2,h=e-u,a=e+u,c=Math.min(s,n),l=Math.max(s,n)),{left:h,top:c,right:a,bottom:l}}function Vs(t,i,e,s){return t?0:kt(i,e,s)}function Xs(t,i,e,s){const n=null===i,r=null===e,o=t&&!(n&&r)&&Ys(t,s);return o&&(n||Ot(i,o.left,o.right))&&(r||Ot(e,o.top,o.bottom))}function Us(t,i){t.rect(i.x,i.y,i.w,i.h)}function Zs(t,i,e={}){const s=t.x!==e.x?-i:0,n=t.y!==e.y?-i:0;return{x:t.x+s,y:t.y+n,w:t.w+((t.x+t.w!==e.x+e.w?i:0)-s),h:t.h+((t.y+t.h!==e.y+e.h?i:0)-n),radius:t.radius}}const Ks=["rgb(54, 162, 235)","rgb(255, 99, 132)","rgb(255, 159, 64)","rgb(255, 205, 86)","rgb(75, 192, 192)","rgb(153, 102, 255)","rgb(201, 203, 207)"],Qs=Ks.map((t=>t.replace("rgb(","rgba(").replace(")",", 0.5)")));function qs(t){return Ks[t%Ks.length]}function Gs(t){return Qs[t%Qs.length]}function Js(t){let i;for(i in t)if(t[i].borderColor||t[i].backgroundColor)return!0;return!1}var tn={id:"colors",defaults:{enabled:!0,forceOverride:!1},beforeLayout(t,i,e){if(!e.enabled)return;const{data:{datasets:s},options:n}=t.config,{elements:r}=n,o=Js(s)||(h=n)&&(h.borderColor||h.backgroundColor)||r&&Js(r)||"rgba(0,0,0,0.1)"!==Gt.borderColor||"rgba(0,0,0,0.1)"!==Gt.backgroundColor;var h;if(!e.forceOverride&&o)return;const a=function(t){let i=0;return(e,s)=>{const n=t.getDatasetMeta(s).controller;n instanceof Me?i=function(t,i){return t.backgroundColor=t.data.map((()=>qs(i++))),i}(e,i):n instanceof we?i=function(t,i){return t.backgroundColor=t.data.map((()=>Gs(i++))),i}(e,i):n&&(i=function(t,i){return t.borderColor=qs(i),t.backgroundColor=Gs(i),++i}(e,i))}}(t);s.forEach(a)}};const en=(t,i)=>{let{boxHeight:e=i,boxWidth:s=i}=t;return t.usePointStyle&&(e=Math.min(e,i),s=t.pointStyleWidth||Math.min(s,i)),{boxWidth:s,boxHeight:e,itemHeight:Math.max(i,e)}};class sn extends ns{constructor(t){super(),this._added=!1,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=!1,this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this.legendItems=void 0,this.columnSizes=void 0,this.lineWidths=void 0,this.maxHeight=void 0,this.maxWidth=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.height=void 0,this.width=void 0,this._margins=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,i,e){this.maxWidth=t,this.maxHeight=i,this._margins=e,this.setDimensions(),this.buildLabels(),this.fit()}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=this._margins.left,this.right=this.width):(this.height=this.maxHeight,this.top=this._margins.top,this.bottom=this.height)}buildLabels(){const t=this.options.labels||{};let i=U(t.generateLabels,[this.chart],this)||[];t.filter&&(i=i.filter((i=>t.filter(i,this.chart.data)))),t.sort&&(i=i.sort(((i,e)=>t.sort(i,e,this.chart.data)))),this.options.reverse&&i.reverse(),this.legendItems=i}fit(){const{options:t,ctx:i}=this;if(!t.display)return void(this.width=this.height=0);const e=t.labels,s=xi(e.font),n=s.size,r=this._computeTitleHeight(),{boxWidth:o,itemHeight:h}=en(e,n);let a,c;i.font=s.string,this.isHorizontal()?(a=this.maxWidth,c=this._fitRows(r,n,o,h)+10):(c=this.maxHeight,a=this._fitCols(r,s,o,h)+10),this.width=Math.min(a,t.maxWidth||this.maxWidth),this.height=Math.min(c,t.maxHeight||this.maxHeight)}_fitRows(t,i,e,s){const{ctx:n,maxWidth:r,options:{labels:{padding:o}}}=this,h=this.legendHitBoxes=[],a=this.lineWidths=[0],c=s+o;let l=t;n.textAlign="left",n.textBaseline="middle";let u=-1,f=-c;return this.legendItems.forEach(((t,d)=>{const b=e+i/2+n.measureText(t.text).width;(0===d||a[a.length-1]+b+2*o>r)&&(l+=c,a[a.length-(d>0?0:1)]=0,f+=c,u++),h[d]={left:0,top:f,row:u,width:b,height:s},a[a.length-1]+=b+o})),l}_fitCols(t,i,e,s){const{ctx:n,maxHeight:r,options:{labels:{padding:o}}}=this,h=this.legendHitBoxes=[],a=this.columnSizes=[],c=r-t;let l=o,u=0,f=0,d=0,b=0;return this.legendItems.forEach(((t,r)=>{const{itemWidth:g,itemHeight:p}=function(t,i,e,s,n){const r=function(t,i,e,s){let n=t.text;return n&&"string"!=typeof n&&(n=n.reduce(((t,i)=>t.length>i.length?t:i))),i+e.size/2+s.measureText(n).width}(s,t,i,e),o=function(t,i,e){let s=t;return"string"!=typeof i.text&&(s=nn(i,e)),s}(n,s,i.lineHeight);return{itemWidth:r,itemHeight:o}}(e,i,n,t,s);r>0&&f+p+2*o>c&&(l+=u+o,a.push({width:u,height:f}),d+=u+o,b++,u=f=0),h[r]={left:d,top:f,col:b,width:g,height:p},u=Math.max(u,g),f+=p+o})),l+=u,a.push({width:u,height:f}),l}adjustHitBoxes(){if(!this.options.display)return;const t=this._computeTitleHeight(),{legendHitBoxes:i,options:{align:e,labels:{padding:s},rtl:n}}=this,r=Xi(n,this.left,this.width);if(this.isHorizontal()){let n=0,o=Pt(e,this.left+s,this.right-this.lineWidths[n]);for(const h of i)n!==h.row&&(n=h.row,o=Pt(e,this.left+s,this.right-this.lineWidths[n])),h.top+=this.top+t+s,h.left=r.leftForLtr(r.x(o),h.width),o+=h.width+s}else{let n=0,o=Pt(e,this.top+t+s,this.bottom-this.columnSizes[n].height);for(const h of i)h.col!==n&&(n=h.col,o=Pt(e,this.top+t+s,this.bottom-this.columnSizes[n].height)),h.top=o,h.left+=this.left+s,h.left=r.leftForLtr(r.x(h.left),h.width),o+=h.height+s}}isHorizontal(){return"top"===this.options.position||"bottom"===this.options.position}draw(){if(this.options.display){const t=this.ctx;ri(t,this),this._draw(),oi(t)}}_draw(){const{options:t,columnSizes:i,lineWidths:e,ctx:s}=this,{align:n,labels:r}=t,o=Gt.color,h=Xi(t.rtl,this.left,this.width),a=xi(r.font),{padding:c}=r,l=a.size,u=l/2;let f;this.drawTitle(),s.textAlign=h.textAlign("left"),s.textBaseline="middle",s.lineWidth=.5,s.font=a.string;const{boxWidth:d,boxHeight:b,itemHeight:g}=en(r,l),p=this.isHorizontal(),m=this._computeTitleHeight();f=p?{x:Pt(n,this.left+c,this.right-e[0]),y:this.top+c+m,line:0}:{x:this.left+c,y:Pt(n,this.top+m+c,this.bottom-i[0].height),line:0},Ui(this.ctx,t.textDirection);const x=g+c;this.legendItems.forEach(((v,y)=>{s.strokeStyle=v.fontColor,s.fillStyle=v.fontColor;const M=s.measureText(v.text).width,w=h.textAlign(v.textAlign||(v.textAlign=r.textAlign)),_=d+u+M;let k=f.x,O=f.y;h.setWidth(this.width),p?y>0&&k+_+c>this.right&&(O=f.y+=x,f.line++,k=f.x=Pt(n,this.left+c,this.right-e[f.line])):y>0&&O+x>this.bottom&&(k=f.x=k+i[f.line].width+c,f.line++,O=f.y=Pt(n,this.top+m+c,this.bottom-i[f.line].height)),function(t,i,e){if(isNaN(d)||d<=0||isNaN(b)||b<0)return;s.save();const n=V(e.lineWidth,1);if(s.fillStyle=V(e.fillStyle,o),s.lineCap=V(e.lineCap,"butt"),s.lineDashOffset=V(e.lineDashOffset,0),s.lineJoin=V(e.lineJoin,"miter"),s.lineWidth=n,s.strokeStyle=V(e.strokeStyle,o),s.setLineDash(V(e.lineDash,[])),r.usePointStyle){const o={radius:b*Math.SQRT2/2,pointStyle:e.pointStyle,rotation:e.rotation,borderWidth:n},a=h.xPlus(t,d/2);si(s,o,a,i+u,r.pointStyleWidth&&d)}else{const r=i+Math.max((l-b)/2,0),o=h.leftForLtr(t,d),a=pi(e.borderRadius);s.beginPath(),Object.values(a).some((t=>0!==t))?li(s,{x:o,y:r,w:d,h:b,radius:a}):s.rect(o,r,d,b),s.fill(),0!==n&&s.stroke()}s.restore()}(h.x(k),O,v),k=((t,i,e,s)=>t===(s?"left":"right")?e:"center"===t?(i+e)/2:i)(w,k+d+u,p?k+_:this.right,t.rtl),function(t,i,e){ci(s,e.text,t,i+g/2,a,{strikethrough:e.hidden,textAlign:h.textAlign(e.textAlign)})}(h.x(k),O,v),p?f.x+=_+c:f.y+="string"!=typeof v.text?nn(v,a.lineHeight)+c:x})),Zi(this.ctx,t.textDirection)}drawTitle(){const t=this.options,i=t.title,e=xi(i.font),s=mi(i.padding);if(!i.display)return;const n=Xi(t.rtl,this.left,this.width),r=this.ctx,o=i.position,h=s.top+e.size/2;let a,c=this.left,l=this.width;if(this.isHorizontal())l=Math.max(...this.lineWidths),a=this.top+h,c=Pt(t.align,c,this.right-l);else{const i=this.columnSizes.reduce(((t,i)=>Math.max(t,i.height)),0);a=h+Pt(t.align,this.top,this.bottom-i-t.labels.padding-this._computeTitleHeight())}const u=Pt(o,c,c+l);r.textAlign=n.textAlign(Lt(o)),r.textBaseline="middle",r.strokeStyle=i.color,r.fillStyle=i.color,r.font=e.string,ci(r,i.text,u,a,e)}_computeTitleHeight(){const t=this.options.title,i=xi(t.font),e=mi(t.padding);return t.display?i.lineHeight+e.height:0}_getLegendItemAt(t,i){let e,s,n;if(Ot(t,this.left,this.right)&&Ot(i,this.top,this.bottom))for(n=this.legendHitBoxes,e=0;e<n.length;++e)if(s=n[e],Ot(t,s.left,s.left+s.width)&&Ot(i,s.top,s.top+s.height))return this.legendItems[e];return null}handleEvent(t){const i=this.options;if(!function(t,i){return!("mousemove"!==t&&"mouseout"!==t||!i.onHover&&!i.onLeave)||!(!i.onClick||"click"!==t&&"mouseup"!==t)}(t.type,i))return;const e=this._getLegendItemAt(t.x,t.y);if("mousemove"===t.type||"mouseout"===t.type){const r=this._hoveredItem,o=(n=e,null!==(s=r)&&null!==n&&s.datasetIndex===n.datasetIndex&&s.index===n.index);r&&!o&&U(i.onLeave,[t,r,this],this),this._hoveredItem=e,e&&!o&&U(i.onHover,[t,e,this],this)}else e&&U(i.onClick,[t,e,this],this);var s,n}}function nn(t,i){return i*(t.text?t.text.length:0)}var rn={id:"legend",_element:sn,start(t,i,e){const s=t.legend=new sn({ctx:t.ctx,options:e,chart:t});Ne.configure(t,s,e),Ne.addBox(t,s)},stop(t){Ne.removeBox(t,t.legend),delete t.legend},beforeUpdate(t,i,e){const s=t.legend;Ne.configure(t,s,e),s.options=e},afterUpdate(t){const i=t.legend;i.buildLabels(),i.adjustHitBoxes()},afterEvent(t,i){i.replay||t.legend.handleEvent(i.event)},defaults:{display:!0,position:"top",align:"center",fullSize:!0,reverse:!1,weight:1e3,onClick(t,i,e){const s=i.datasetIndex,n=e.chart;n.isDatasetVisible(s)?(n.hide(s),i.hidden=!0):(n.show(s),i.hidden=!1)},onHover:null,onLeave:null,labels:{color:t=>t.chart.options.color,boxWidth:40,padding:10,generateLabels(t){const i=t.data.datasets,{labels:{usePointStyle:e,pointStyle:s,textAlign:n,color:r,useBorderRadius:o,borderRadius:h}}=t.legend.options;return t._getSortedDatasetMetas().map((t=>{const a=t.controller.getStyle(e?0:void 0),c=mi(a.borderWidth);return{text:i[t.index].label,fillStyle:a.backgroundColor,fontColor:r,hidden:!t.visible,lineCap:a.borderCapStyle,lineDash:a.borderDash,lineDashOffset:a.borderDashOffset,lineJoin:a.borderJoinStyle,lineWidth:(c.width+c.height)/4,strokeStyle:a.borderColor,pointStyle:s||a.pointStyle,rotation:a.rotation,textAlign:n||a.textAlign,borderRadius:o&&(h||a.borderRadius),datasetIndex:t.index}}),this)}},title:{color:t=>t.chart.options.color,display:!1,position:"center",text:""}},descriptors:{_scriptable:t=>!t.startsWith("on"),labels:{_scriptable:t=>!["generateLabels","filter","sort"].includes(t)}}};class on extends ns{constructor(t){super(),this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this._padding=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,i){const e=this.options;if(this.left=0,this.top=0,!e.display)return void(this.width=this.height=this.right=this.bottom=0);this.width=this.right=t,this.height=this.bottom=i;const s=z(e.text)?e.text.length:1;this._padding=mi(e.padding);const n=s*xi(e.font).lineHeight+this._padding.height;this.isHorizontal()?this.height=n:this.width=n}isHorizontal(){const t=this.options.position;return"top"===t||"bottom"===t}_drawArgs(t){const{top:i,left:e,bottom:s,right:n,options:r}=this,o=r.align;let h,a,c,l=0;return this.isHorizontal()?(a=Pt(o,e,n),c=i+t,h=n-e):("left"===r.position?(a=e+t,c=Pt(o,s,i),l=-.5*at):(a=n-t,c=Pt(o,i,s),l=.5*at),h=s-i),{titleX:a,titleY:c,maxWidth:h,rotation:l}}draw(){const t=this.ctx,i=this.options;if(!i.display)return;const e=xi(i.font),s=e.lineHeight/2+this._padding.top,{titleX:n,titleY:r,maxWidth:o,rotation:h}=this._drawArgs(s);ci(t,i.text,0,0,e,{color:i.color,maxWidth:o,rotation:h,textAlign:Lt(i.align),textBaseline:"middle",translation:[n,r]})}}var hn={id:"title",_element:on,start(t,i,e){!function(t,i){const e=new on({ctx:t.ctx,options:i,chart:t});Ne.configure(t,e,i),Ne.addBox(t,e),t.titleBlock=e}(t,e)},stop(t){Ne.removeBox(t,t.titleBlock),delete t.titleBlock},beforeUpdate(t,i,e){const s=t.titleBlock;Ne.configure(t,s,e),s.options=e},defaults:{align:"center",display:!1,font:{weight:"bold"},fullSize:!0,padding:10,position:"top",text:"",weight:2e3},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}};const an={average(t){if(!t.length)return!1;let i,e,s=new Set,n=0,r=0;for(i=0,e=t.length;i<e;++i){const e=t[i].element;if(e&&e.hasValue()){const t=e.tooltipPosition();s.add(t.x),n+=t.y,++r}}return 0!==r&&0!==s.size&&{x:[...s].reduce(((t,i)=>t+i))/s.size,y:n/r}},nearest(t,i){if(!t.length)return!1;let e,s,n,r=i.x,o=i.y,h=Number.POSITIVE_INFINITY;for(e=0,s=t.length;e<s;++e){const s=t[e].element;if(s&&s.hasValue()){const t=(a=i,c=s.getCenterPoint(),Math.sqrt(Math.pow(c.x-a.x,2)+Math.pow(c.y-a.y,2)));t<h&&(h=t,n=s)}}var a,c;if(n){const t=n.tooltipPosition();r=t.x,o=t.y}return{x:r,y:o}}};function cn(t,i){return i&&(z(i)?Array.prototype.push.apply(t,i):t.push(i)),t}function ln(t){return("string"==typeof t||t instanceof String)&&t.indexOf("\n")>-1?t.split("\n"):t}function un(t,i){const{element:e,datasetIndex:s,index:n}=i,r=t.getDatasetMeta(s).controller,{label:o,value:h}=r.getLabelAndValue(n);return{chart:t,label:o,parsed:r.getParsed(n),raw:t.data.datasets[s].data[n],formattedValue:h,dataset:r.getDataset(),dataIndex:n,datasetIndex:s,element:e}}function fn(t,i){const e=t.chart.ctx,{body:s,footer:n,title:r}=t,{boxWidth:o,boxHeight:h}=i,a=xi(i.bodyFont),c=xi(i.titleFont),l=xi(i.footerFont),u=r.length,f=n.length,d=s.length,b=mi(i.padding);let g=b.height,p=0,m=s.reduce(((t,i)=>t+i.before.length+i.lines.length+i.after.length),0);m+=t.beforeBody.length+t.afterBody.length,u&&(g+=u*c.lineHeight+(u-1)*i.titleSpacing+i.titleMarginBottom),m&&(g+=d*(i.displayColors?Math.max(h,a.lineHeight):a.lineHeight)+(m-d)*a.lineHeight+(m-1)*i.bodySpacing),f&&(g+=i.footerMarginTop+f*l.lineHeight+(f-1)*i.footerSpacing);let x=0;const v=function(t){p=Math.max(p,e.measureText(t).width+x)};return e.save(),e.font=c.string,Z(t.title,v),e.font=a.string,Z(t.beforeBody.concat(t.afterBody),v),x=i.displayColors?o+2+i.boxPadding:0,Z(s,(t=>{Z(t.before,v),Z(t.lines,v),Z(t.after,v)})),x=0,e.font=l.string,Z(t.footer,v),e.restore(),p+=b.width,{width:p,height:g}}function dn(t,i,e,s){const{x:n,width:r}=e,{width:o,chartArea:{left:h,right:a}}=t;let c="center";return"center"===s?c=n<=(h+a)/2?"left":"right":n<=r/2?c="left":n>=o-r/2&&(c="right"),function(t,i,e,s){const{x:n,width:r}=s,o=e.caretSize+e.caretPadding;return"left"===t&&n+r+o>i.width||"right"===t&&n-r-o<0||void 0}(c,t,i,e)&&(c="center"),c}function bn(t,i,e){const s=e.yAlign||i.yAlign||function(t,i){const{y:e,height:s}=i;return e<s/2?"top":e>t.height-s/2?"bottom":"center"}(t,e);return{xAlign:e.xAlign||i.xAlign||dn(t,i,e,s),yAlign:s}}function gn(t,i,e,s){const{caretSize:n,caretPadding:r,cornerRadius:o}=t,{xAlign:h,yAlign:a}=e,c=n+r,{topLeft:l,topRight:u,bottomLeft:f,bottomRight:d}=pi(o);let b=function(t,i){let{x:e,width:s}=t;return"right"===i?e-=s:"center"===i&&(e-=s/2),e}(i,h);const g=function(t,i,e){let{y:s,height:n}=t;return"top"===i?s+=e:s-="bottom"===i?n+e:n/2,s}(i,a,c);return"center"===a?"left"===h?b+=c:"right"===h&&(b-=c):"left"===h?b-=Math.max(l,f)+n:"right"===h&&(b+=Math.max(u,d)+n),{x:kt(b,0,s.width-i.width),y:kt(g,0,s.height-i.height)}}function pn(t,i,e){const s=mi(e.padding);return"center"===i?t.x+t.width/2:"right"===i?t.x+t.width-s.right:t.x+s.left}function mn(t){return cn([],ln(t))}function xn(t,i){const e=i&&i.dataset&&i.dataset.tooltip&&i.dataset.tooltip.callbacks;return e?t.override(e):t}const vn={beforeTitle:B,title(t){if(t.length>0){const i=t[0],e=i.chart.data.labels,s=e?e.length:0;if(this&&this.options&&"dataset"===this.options.mode)return i.dataset.label||"";if(i.label)return i.label;if(s>0&&i.dataIndex<s)return e[i.dataIndex]}return""},afterTitle:B,beforeBody:B,beforeLabel:B,label(t){if(this&&this.options&&"dataset"===this.options.mode)return t.label+": "+t.formattedValue||t.formattedValue;let i=t.dataset.label||"";i&&(i+=": ");const e=t.formattedValue;return N(e)||(i+=e),i},labelColor(t){const i=t.chart.getDatasetMeta(t.datasetIndex).controller.getStyle(t.dataIndex);return{borderColor:i.borderColor,backgroundColor:i.backgroundColor,borderWidth:i.borderWidth,borderDash:i.borderDash,borderDashOffset:i.borderDashOffset,borderRadius:0}},labelTextColor(){return this.options.bodyColor},labelPointStyle(t){const i=t.chart.getDatasetMeta(t.datasetIndex).controller.getStyle(t.dataIndex);return{pointStyle:i.pointStyle,rotation:i.rotation}},afterLabel:B,afterBody:B,beforeFooter:B,footer:B,afterFooter:B};function yn(t,i,e,s){const n=t[i].call(e,s);return void 0===n?vn[i].call(e,s):n}class Mn extends ns{static positioners=an;constructor(t){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const i=this.chart,e=this.options.setContext(this.getContext()),s=e.enabled&&i.options.animation&&e.animations,n=new ie(this.chart,s);return s._cacheable&&(this._cachedAnimations=Object.freeze(n)),n}getContext(){return this.$context||(this.$context=yi(this.chart.getContext(),{tooltip:this,tooltipItems:this._tooltipItems,type:"tooltip"}))}getTitle(t,i){const{callbacks:e}=i,s=yn(e,"beforeTitle",this,t),n=yn(e,"title",this,t),r=yn(e,"afterTitle",this,t);let o=[];return o=cn(o,ln(s)),o=cn(o,ln(n)),o=cn(o,ln(r)),o}getBeforeBody(t,i){return mn(yn(i.callbacks,"beforeBody",this,t))}getBody(t,i){const{callbacks:e}=i,s=[];return Z(t,(t=>{const i={before:[],lines:[],after:[]},n=xn(e,t);cn(i.before,ln(yn(n,"beforeLabel",this,t))),cn(i.lines,yn(n,"label",this,t)),cn(i.after,ln(yn(n,"afterLabel",this,t))),s.push(i)})),s}getAfterBody(t,i){return mn(yn(i.callbacks,"afterBody",this,t))}getFooter(t,i){const{callbacks:e}=i,s=yn(e,"beforeFooter",this,t),n=yn(e,"footer",this,t),r=yn(e,"afterFooter",this,t);let o=[];return o=cn(o,ln(s)),o=cn(o,ln(n)),o=cn(o,ln(r)),o}_createItems(t){const i=this._active,e=this.chart.data,s=[],n=[],r=[];let o,h,a=[];for(o=0,h=i.length;o<h;++o)a.push(un(this.chart,i[o]));return t.filter&&(a=a.filter(((i,s,n)=>t.filter(i,s,n,e)))),t.itemSort&&(a=a.sort(((i,s)=>t.itemSort(i,s,e)))),Z(a,(i=>{const e=xn(t.callbacks,i);s.push(yn(e,"labelColor",this,i)),n.push(yn(e,"labelPointStyle",this,i)),r.push(yn(e,"labelTextColor",this,i))})),this.labelColors=s,this.labelPointStyles=n,this.labelTextColors=r,this.dataPoints=a,a}update(t,i){const e=this.options.setContext(this.getContext()),s=this._active;let n,r=[];if(s.length){const t=an[e.position].call(this,s,this._eventPosition);r=this._createItems(e),this.title=this.getTitle(r,e),this.beforeBody=this.getBeforeBody(r,e),this.body=this.getBody(r,e),this.afterBody=this.getAfterBody(r,e),this.footer=this.getFooter(r,e);const i=this._size=fn(this,e),o=Object.assign({},t,i),h=bn(this.chart,e,o),a=gn(e,o,h,this.chart);this.xAlign=h.xAlign,this.yAlign=h.yAlign,n={opacity:1,x:a.x,y:a.y,width:i.width,height:i.height,caretX:t.x,caretY:t.y}}else 0!==this.opacity&&(n={opacity:0});this._tooltipItems=r,this.$context=void 0,n&&this._resolveAnimations().update(this,n),t&&e.external&&e.external.call(this,{chart:this.chart,tooltip:this,replay:i})}drawCaret(t,i,e,s){const n=this.getCaretPosition(t,e,s);i.lineTo(n.x1,n.y1),i.lineTo(n.x2,n.y2),i.lineTo(n.x3,n.y3)}getCaretPosition(t,i,e){const{xAlign:s,yAlign:n}=this,{caretSize:r,cornerRadius:o}=e,{topLeft:h,topRight:a,bottomLeft:c,bottomRight:l}=pi(o),{x:u,y:f}=t,{width:d,height:b}=i;let g,p,m,x,v,y;return"center"===n?(v=f+b/2,"left"===s?(g=u,p=g-r,x=v+r,y=v-r):(g=u+d,p=g+r,x=v-r,y=v+r),m=g):(p="left"===s?u+Math.max(h,c)+r:"right"===s?u+d-Math.max(a,l)-r:this.caretX,"top"===n?(x=f,v=x-r,g=p-r,m=p+r):(x=f+b,v=x+r,g=p+r,m=p-r),y=x),{x1:g,x2:p,x3:m,y1:x,y2:v,y3:y}}drawTitle(t,i,e){const s=this.title,n=s.length;let r,o,h;if(n){const a=Xi(e.rtl,this.x,this.width);for(t.x=pn(this,e.titleAlign,e),i.textAlign=a.textAlign(e.titleAlign),i.textBaseline="middle",r=xi(e.titleFont),o=e.titleSpacing,i.fillStyle=e.titleColor,i.font=r.string,h=0;h<n;++h)i.fillText(s[h],a.x(t.x),t.y+r.lineHeight/2),t.y+=r.lineHeight+o,h+1===n&&(t.y+=e.titleMarginBottom-o)}}_drawColorBox(t,i,e,s,n){const r=this.labelColors[e],o=this.labelPointStyles[e],{boxHeight:h,boxWidth:a}=n,c=xi(n.bodyFont),l=pn(this,"left",n),u=s.x(l),f=i.y+(h<c.lineHeight?(c.lineHeight-h)/2:0);if(n.usePointStyle){const i={radius:Math.min(a,h)/2,pointStyle:o.pointStyle,rotation:o.rotation,borderWidth:1},e=s.leftForLtr(u,a)+a/2,c=f+h/2;t.strokeStyle=n.multiKeyBackground,t.fillStyle=n.multiKeyBackground,ei(t,i,e,c),t.strokeStyle=r.borderColor,t.fillStyle=r.backgroundColor,ei(t,i,e,c)}else{t.lineWidth=H(r.borderWidth)?Math.max(...Object.values(r.borderWidth)):r.borderWidth||1,t.strokeStyle=r.borderColor,t.setLineDash(r.borderDash||[]),t.lineDashOffset=r.borderDashOffset||0;const i=s.leftForLtr(u,a),e=s.leftForLtr(s.xPlus(u,1),a-2),o=pi(r.borderRadius);Object.values(o).some((t=>0!==t))?(t.beginPath(),t.fillStyle=n.multiKeyBackground,li(t,{x:i,y:f,w:a,h,radius:o}),t.fill(),t.stroke(),t.fillStyle=r.backgroundColor,t.beginPath(),li(t,{x:e,y:f+1,w:a-2,h:h-2,radius:o}),t.fill()):(t.fillStyle=n.multiKeyBackground,t.fillRect(i,f,a,h),t.strokeRect(i,f,a,h),t.fillStyle=r.backgroundColor,t.fillRect(e,f+1,a-2,h-2))}t.fillStyle=this.labelTextColors[e]}drawBody(t,i,e){const{body:s}=this,{bodySpacing:n,bodyAlign:r,displayColors:o,boxHeight:h,boxWidth:a,boxPadding:c}=e,l=xi(e.bodyFont);let u=l.lineHeight,f=0;const d=Xi(e.rtl,this.x,this.width),b=function(e){i.fillText(e,d.x(t.x+f),t.y+u/2),t.y+=u+n},g=d.textAlign(r);let p,m,x,v,y,M,w;for(i.textAlign=r,i.textBaseline="middle",i.font=l.string,t.x=pn(this,g,e),i.fillStyle=e.bodyColor,Z(this.beforeBody,b),f=o&&"right"!==g?"center"===r?a/2+c:a+2+c:0,v=0,M=s.length;v<M;++v){for(p=s[v],m=this.labelTextColors[v],i.fillStyle=m,Z(p.before,b),x=p.lines,o&&x.length&&(this._drawColorBox(i,t,v,d,e),u=Math.max(l.lineHeight,h)),y=0,w=x.length;y<w;++y)b(x[y]),u=l.lineHeight;Z(p.after,b)}f=0,u=l.lineHeight,Z(this.afterBody,b),t.y-=n}drawFooter(t,i,e){const s=this.footer,n=s.length;let r,o;if(n){const h=Xi(e.rtl,this.x,this.width);for(t.x=pn(this,e.footerAlign,e),t.y+=e.footerMarginTop,i.textAlign=h.textAlign(e.footerAlign),i.textBaseline="middle",r=xi(e.footerFont),i.fillStyle=e.footerColor,i.font=r.string,o=0;o<n;++o)i.fillText(s[o],h.x(t.x),t.y+r.lineHeight/2),t.y+=r.lineHeight+e.footerSpacing}}drawBackground(t,i,e,s){const{xAlign:n,yAlign:r}=this,{x:o,y:h}=t,{width:a,height:c}=e,{topLeft:l,topRight:u,bottomLeft:f,bottomRight:d}=pi(s.cornerRadius);i.fillStyle=s.backgroundColor,i.strokeStyle=s.borderColor,i.lineWidth=s.borderWidth,i.beginPath(),i.moveTo(o+l,h),"top"===r&&this.drawCaret(t,i,e,s),i.lineTo(o+a-u,h),i.quadraticCurveTo(o+a,h,o+a,h+u),"center"===r&&"right"===n&&this.drawCaret(t,i,e,s),i.lineTo(o+a,h+c-d),i.quadraticCurveTo(o+a,h+c,o+a-d,h+c),"bottom"===r&&this.drawCaret(t,i,e,s),i.lineTo(o+f,h+c),i.quadraticCurveTo(o,h+c,o,h+c-f),"center"===r&&"left"===n&&this.drawCaret(t,i,e,s),i.lineTo(o,h+l),i.quadraticCurveTo(o,h,o+l,h),i.closePath(),i.fill(),s.borderWidth>0&&i.stroke()}_updateAnimationTarget(t){const i=this.chart,e=this.$animations,s=e&&e.x,n=e&&e.y;if(s||n){const e=an[t.position].call(this,this._active,this._eventPosition);if(!e)return;const r=this._size=fn(this,t),o=Object.assign({},e,this._size),h=bn(i,t,o),a=gn(t,o,h,i);s._to===a.x&&n._to===a.y||(this.xAlign=h.xAlign,this.yAlign=h.yAlign,this.width=r.width,this.height=r.height,this.caretX=e.x,this.caretY=e.y,this._resolveAnimations().update(this,a))}}_willRender(){return!!this.opacity}draw(t){const i=this.options.setContext(this.getContext());let e=this.opacity;if(!e)return;this._updateAnimationTarget(i);const s={width:this.width,height:this.height},n={x:this.x,y:this.y};e=Math.abs(e)<.001?0:e;const r=mi(i.padding);i.enabled&&(this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length)&&(t.save(),t.globalAlpha=e,this.drawBackground(n,t,s,i),Ui(t,i.textDirection),n.y+=r.top,this.drawTitle(n,t,i),this.drawBody(n,t,i),this.drawFooter(n,t,i),Zi(t,i.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,i){const e=this._active,s=t.map((({datasetIndex:t,index:i})=>{const e=this.chart.getDatasetMeta(t);if(!e)throw new Error("Cannot find a dataset at index "+t);return{datasetIndex:t,element:e.data[i],index:i}})),n=!K(e,s),r=this._positionChanged(s,i);(n||r)&&(this._active=s,this._eventPosition=i,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,i,e=!0){if(i&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const s=this.options,n=this._active||[],r=this._getActiveElements(t,n,i,e),o=this._positionChanged(r,t),h=i||!K(r,n)||o;return h&&(this._active=r,(s.enabled||s.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,i))),h}_getActiveElements(t,i,e,s){const n=this.options;if("mouseout"===t.type)return[];if(!s)return i.filter((t=>this.chart.data.datasets[t.datasetIndex]&&void 0!==this.chart.getDatasetMeta(t.datasetIndex).controller.getParsed(t.index)));const r=this.chart.getElementsAtEventForMode(t,n.mode,n,e);return n.reverse&&r.reverse(),r}_positionChanged(t,i){const{caretX:e,caretY:s,options:n}=this,r=an[n.position].call(this,t,i);return!1!==r&&(e!==r.x||s!==r.y)}}var wn={id:"tooltip",_element:Mn,positioners:an,afterInit(t,i,e){e&&(t.tooltip=new Mn({chart:t,options:e}))},beforeUpdate(t,i,e){t.tooltip&&t.tooltip.initialize(e)},reset(t,i,e){t.tooltip&&t.tooltip.initialize(e)},afterDraw(t){const i=t.tooltip;if(i&&i._willRender()){const e={tooltip:i};if(!1===t.notifyPlugins("beforeTooltipDraw",{...e,cancelable:!0}))return;i.draw(t.ctx),t.notifyPlugins("afterTooltipDraw",e)}},afterEvent(t,i){t.tooltip&&t.tooltip.handleEvent(i.event,i.replay,i.inChartArea)&&(i.changed=!0)},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(t,i)=>i.bodyFont.size,boxWidth:(t,i)=>i.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:vn},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:t=>"filter"!==t&&"itemSort"!==t&&"external"!==t,_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};function _n(t){const i=this.getLabels();return t>=0&&t<i.length?i[t]:t}function kn(t,i,{horizontal:e,minRotation:s}){const n=yt(s),r=(e?Math.sin(n):Math.cos(n))||.001;return Math.min(i/r,.75*i*(""+t).length)}class On extends ds{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,i){return N(t)||("number"==typeof t||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const{beginAtZero:t}=this.options,{minDefined:i,maxDefined:e}=this.getUserBounds();let{min:s,max:n}=this;const r=t=>s=i?s:t,o=t=>n=e?n:t;if(t){const t=pt(s),i=pt(n);t<0&&i<0?o(0):t>0&&i>0&&r(0)}if(s===n){let i=0===n?1:Math.abs(.05*n);o(n+i),t||r(s-i)}this.min=s,this.max=n}getTickLimit(){const t=this.options.ticks;let i,{maxTicksLimit:e,stepSize:s}=t;return s?(i=Math.ceil(this.max/s)-Math.floor(this.min/s)+1,i>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${s} would result generating up to ${i} ticks. Limiting to 1000.`),i=1e3)):(i=this.computeTickLimit(),e=e||11),e&&(i=Math.min(e,i)),i}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this.options,i=t.ticks;let e=this.getTickLimit();e=Math.max(2,e);const s=function(t,i){const e=[],{bounds:s,step:n,min:r,max:o,precision:h,count:a,maxTicks:c,maxDigits:l,includeBounds:u}=t,f=n||1,d=c-1,{min:b,max:g}=i,p=!N(r),m=!N(o),x=!N(a),v=(g-b)/(l+1);let y,M,w,_,k=xt((g-b)/d/f)*f;if(k<1e-14&&!p&&!m)return[{value:b},{value:g}];_=Math.ceil(g/k)-Math.floor(b/k),_>d&&(k=xt(_*k/d/f)*f),N(h)||(y=Math.pow(10,h),k=Math.ceil(k*y)/y),"ticks"===s?(M=Math.floor(b/k)*k,w=Math.ceil(g/k)*k):(M=b,w=g),p&&m&&n&&function(t,i){const e=Math.round(t);return e-i<=t&&e+i>=t}((o-r)/n,k/1e3)?(_=Math.round(Math.min((o-r)/k,c)),k=(o-r)/_,M=r,w=o):x?(M=p?r:M,w=m?o:w,_=a-1,k=(w-M)/_):(_=(w-M)/k,_=mt(_,Math.round(_),k/1e3)?Math.round(_):Math.ceil(_));const O=Math.max(Mt(k),Mt(M));y=Math.pow(10,N(h)?O:h),M=Math.round(M*y)/y,w=Math.round(w*y)/y;let S=0;for(p&&(u&&M!==r?(e.push({value:r}),M<r&&S++,mt(Math.round((M+S*k)*y)/y,r,kn(r,v,t))&&S++):M<r&&S++);S<_;++S){const t=Math.round((M+S*k)*y)/y;if(m&&t>o)break;e.push({value:t})}return m&&u&&w!==o?e.length&&mt(e[e.length-1].value,o,kn(o,v,t))?e[e.length-1].value=o:e.push({value:o}):m&&w!==o||e.push({value:w}),e}({maxTicks:e,bounds:t.bounds,min:t.min,max:t.max,precision:i.precision,step:i.stepSize,count:i.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:i.minRotation||0,includeBounds:!1!==i.includeBounds},this._range||this);return"ticks"===t.bounds&&function(t,i){let e,s,n;for(e=0,s=t.length;e<s;e++)n=t[e].value,isNaN(n)||(i.min=Math.min(i.min,n),i.max=Math.max(i.max,n))}(s,this),t.reverse?(s.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),s}configure(){const t=this.ticks;let i=this.min,e=this.max;if(super.configure(),this.options.offset&&t.length){const s=(e-i)/Math.max(t.length-1,1)/2;i-=s,e+=s}this._startValue=i,this._endValue=e,this._valueRange=e-i}getLabelForValue(t){return Vt(t,this.chart.options.locale,this.options.ticks.format)}}Hs.register(tn,class extends de{static id="bar";static defaults={datasetElementType:!1,dataElementType:"bar",categoryPercentage:.8,barPercentage:.9,grouped:!0,animations:{numbers:{type:"number",properties:["x","y","base","width","height"]}}};static overrides={scales:{_index_:{type:"category",offset:!0,grid:{offset:!0}},_value_:{type:"linear",beginAtZero:!0}}};parsePrimitiveData(t,i,e,s){return ge(t,i,e,s)}parseArrayData(t,i,e,s){return ge(t,i,e,s)}parseObjectData(t,i,e,s){const{iScale:n,vScale:r}=t,{xAxisKey:o="x",yAxisKey:h="y"}=this._parsing,a="x"===n.axis?o:h,c="x"===r.axis?o:h,l=[];let u,f,d,b;for(u=e,f=e+s;u<f;++u)b=i[u],d={},d[n.axis]=n.parse(st(b,a),u),l.push(be(st(b,c),d,r,u));return l}updateRangeFromParsed(t,i,e,s){super.updateRangeFromParsed(t,i,e,s);const n=e._custom;n&&i===this._cachedMeta.vScale&&(t.min=Math.min(t.min,n.min),t.max=Math.max(t.max,n.max))}getMaxOverflow(){return 0}getLabelAndValue(t){const i=this._cachedMeta,{iScale:e,vScale:s}=i,n=this.getParsed(t),r=n._custom,o=pe(r)?"["+r.start+", "+r.end+"]":""+s.getLabelForValue(n[s.axis]);return{label:""+e.getLabelForValue(n[e.axis]),value:o}}initialize(){this.enableOptionSharing=!0,super.initialize(),this._cachedMeta.stack=this.getDataset().stack}update(t){const i=this._cachedMeta;this.updateElements(i.data,0,i.data.length,t)}updateElements(t,i,e,s){const n="reset"===s,{index:r,_cachedMeta:{vScale:o}}=this,h=o.getBasePixel(),a=o.isHorizontal(),c=this._getRuler(),{sharedOptions:l,includeOptions:u}=this._getSharedOptions(i,s);for(let f=i;f<i+e;f++){const i=this.getParsed(f),e=n||N(i[o.axis])?{base:h,head:h}:this._calculateBarValuePixels(f),d=this._calculateBarIndexPixels(f,c),b=(i._stacks||{})[o.axis],g={horizontal:a,base:e.base,enableBorderRadius:!b||pe(i._custom)||r===b._top||r===b._bottom,x:a?e.head:d.center,y:a?d.center:e.head,height:a?d.size:Math.abs(e.size),width:a?Math.abs(e.size):d.size};u&&(g.options=l||this.resolveDataElementOptions(f,t[f].active?"active":s));const p=g.options||t[f].options;me(g,p,b,r),ye(g,p,c.ratio),this.updateElement(t[f],f,g,s)}}_getStacks(t,i){const{iScale:e}=this._cachedMeta,s=e.getMatchingVisibleMetas(this._type).filter((t=>t.controller.options.grouped)),n=e.options.stacked,r=[],o=this._cachedMeta.controller.getParsed(i),h=o&&o[e.axis],a=t=>{const i=t._parsed.find((t=>t[e.axis]===h)),s=i&&i[t.vScale.axis];if(N(s)||isNaN(s))return!0};for(const e of s)if((void 0===i||!a(e))&&((!1===n||-1===r.indexOf(e.stack)||void 0===n&&void 0===e.stack)&&r.push(e.stack),e.index===t))break;return r.length||r.push(void 0),r}_getStackCount(t){return this._getStacks(void 0,t).length}_getAxisCount(){return this._getAxis().length}getFirstScaleIdForIndexAxis(){const t=this.chart.scales,i=this.chart.options.indexAxis;return Object.keys(t).filter((e=>t[e].axis===i)).shift()}_getAxis(){const t={},i=this.getFirstScaleIdForIndexAxis();for(const e of this.chart.data.datasets)t[V("x"===this.chart.options.indexAxis?e.xAxisID:e.yAxisID,i)]=!0;return Object.keys(t)}_getStackIndex(t,i,e){const s=this._getStacks(t,e),n=void 0!==i?s.indexOf(i):-1;return-1===n?s.length-1:n}_getRuler(){const t=this.options,i=this._cachedMeta,e=i.iScale,s=[];let n,r;for(n=0,r=i.data.length;n<r;++n)s.push(e.getPixelForValue(this.getParsed(n)[e.axis],n));const o=t.barThickness,h=o||function(t){const i=t.iScale,e=function(t,i){if(!t._cache.$bar){const e=t.getMatchingVisibleMetas(i);let s=[];for(let i=0,n=e.length;i<n;i++)s=s.concat(e[i].controller.getAllParsedValues(t));t._cache.$bar=function(t){const i=new Set(t);return i.size===t.length?t:Array.from(i)}(s.sort(((t,i)=>t-i)))}return t._cache.$bar}(i,t.type);let s,n,r,o,h=i._length;const a=()=>{32767!==r&&-32768!==r&&(rt(o)&&(h=Math.min(h,Math.abs(r-o)||h)),o=r)};for(s=0,n=e.length;s<n;++s)r=i.getPixelForValue(e[s]),a();for(o=void 0,s=0,n=i.ticks.length;s<n;++s)r=i.getPixelForTick(s),a();return h}(i);return{min:h,pixels:s,start:e._startPixel,end:e._endPixel,stackCount:this._getStackCount(),scale:e,grouped:t.grouped,ratio:o?1:t.categoryPercentage*t.barPercentage}}_calculateBarValuePixels(t){const{_cachedMeta:{vScale:i,_stacked:e,index:s},options:{base:n,minBarLength:r}}=this,o=n||0,h=this.getParsed(t),a=h._custom,c=pe(a);let l,u,f=h[i.axis],d=0,b=e?this.applyStack(i,h,e):f;b!==f&&(d=b-f,b=f),c&&(f=a.barStart,b=a.barEnd-a.barStart,0!==f&&pt(f)!==pt(a.barEnd)&&(d=0),d+=f);const g=N(n)||c?d:n;let p=i.getPixelForValue(g);if(l=this.chart.getDataVisibility(t)?i.getPixelForValue(d+b):p,u=l-p,Math.abs(u)<r){u=function(t,i,e){return 0!==t?pt(t):(i.isHorizontal()?1:-1)*(i.min>=e?1:-1)}(u,i,o)*r,f===o&&(p-=u/2);const t=i.getPixelForDecimal(0),n=i.getPixelForDecimal(1),a=Math.min(t,n),d=Math.max(t,n);p=Math.max(Math.min(p,d),a),l=p+u,e&&!c&&(h._stacks[i.axis]._visualValues[s]=i.getValueForPixel(l)-i.getValueForPixel(p))}if(p===i.getPixelForValue(o)){const t=pt(u)*i.getLineWidthForValue(o)/2;p+=t,u-=t}return{size:u,base:p,head:l,center:l+u/2}}_calculateBarIndexPixels(t,i){const e=i.scale,s=this.options,n=s.skipNull,r=V(s.maxBarThickness,1/0);let o,h;const a=this._getAxisCount();if(i.grouped){const e=n?this._getStackCount(t):i.stackCount,c="flex"===s.barThickness?function(t,i,e,s){const n=i.pixels,r=n[t];let o=t>0?n[t-1]:null,h=t<n.length-1?n[t+1]:null;const a=e.categoryPercentage;null===o&&(o=r-(null===h?i.end-i.start:h-r)),null===h&&(h=r+r-o);const c=r-(r-Math.min(o,h))/2*a;return{chunk:Math.abs(h-o)/2*a/s,ratio:e.barPercentage,start:c}}(t,i,s,e*a):function(t,i,e,s){const n=e.barThickness;let r,o;return N(n)?(r=i.min*e.categoryPercentage,o=e.barPercentage):(r=n*s,o=1),{chunk:r/s,ratio:o,start:i.pixels[t]-r/2}}(t,i,s,e*a),l="x"===this.chart.options.indexAxis?this.getDataset().xAxisID:this.getDataset().yAxisID,u=this._getAxis().indexOf(V(l,this.getFirstScaleIdForIndexAxis())),f=this._getStackIndex(this.index,this._cachedMeta.stack,n?t:void 0)+u;o=c.start+c.chunk*f+c.chunk/2,h=Math.min(r,c.chunk*c.ratio)}else o=e.getPixelForValue(this.getParsed(t)[e.axis],t),h=Math.min(r,i.min*i.ratio);return{base:o-h/2,head:o+h/2,center:o,size:h}}draw(){const t=this._cachedMeta,i=t.vScale,e=t.data,s=e.length;let n=0;for(;n<s;++n)null===this.getParsed(n)[i.axis]||e[n].hidden||e[n].draw(this._ctx)}},class extends ns{static id="bar";static defaults={borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0};static defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};constructor(t){super(),this.options=void 0,this.horizontal=void 0,this.base=void 0,this.width=void 0,this.height=void 0,this.inflateAmount=void 0,t&&Object.assign(this,t)}draw(t){const{inflateAmount:i,options:{borderColor:e,backgroundColor:s}}=this,{inner:n,outer:r}=function(t){const i=Ys(t),e=i.right-i.left,s=i.bottom-i.top,n=function(t,i,e){const s=t.borderSkipped,n=gi(t.options.borderWidth);return{t:Vs(s.top,n.top,0,e),r:Vs(s.right,n.right,0,i),b:Vs(s.bottom,n.bottom,0,e),l:Vs(s.left,n.left,0,i)}}(t,e/2,s/2),r=function(t,i,e){const{enableBorderRadius:s}=t.getProps(["enableBorderRadius"]),n=t.options.borderRadius,r=pi(n),o=Math.min(i,e),h=t.borderSkipped,a=s||H(n);return{topLeft:Vs(!a||h.top||h.left,r.topLeft,0,o),topRight:Vs(!a||h.top||h.right,r.topRight,0,o),bottomLeft:Vs(!a||h.bottom||h.left,r.bottomLeft,0,o),bottomRight:Vs(!a||h.bottom||h.right,r.bottomRight,0,o)}}(t,e/2,s/2);return{outer:{x:i.left,y:i.top,w:e,h:s,radius:r},inner:{x:i.left+n.l,y:i.top+n.t,w:e-n.l-n.r,h:s-n.t-n.b,radius:{topLeft:Math.max(0,r.topLeft-Math.max(n.t,n.l)),topRight:Math.max(0,r.topRight-Math.max(n.t,n.r)),bottomLeft:Math.max(0,r.bottomLeft-Math.max(n.b,n.l)),bottomRight:Math.max(0,r.bottomRight-Math.max(n.b,n.r))}}}}(this),o=(h=r.radius).topLeft||h.topRight||h.bottomLeft||h.bottomRight?li:Us;var h;t.save(),r.w===n.w&&r.h===n.h||(t.beginPath(),o(t,Zs(r,i,n)),t.clip(),o(t,Zs(n,-i,r)),t.fillStyle=e,t.fill("evenodd")),t.beginPath(),o(t,Zs(n,i)),t.fillStyle=s,t.fill(),t.restore()}inRange(t,i,e){return Xs(this,t,i,e)}inXRange(t,i){return Xs(this,t,null,i)}inYRange(t,i){return Xs(this,null,t,i)}getCenterPoint(t){const{x:i,y:e,base:s,horizontal:n}=this.getProps(["x","y","base","horizontal"],t);return{x:n?(i+s)/2:i,y:n?e:(e+s)/2}}getRange(t){return"x"===t?this.width/2:this.height/2}},class extends ds{static id="category";static defaults={ticks:{callback:_n}};constructor(t){super(t),this._startValue=void 0,this._valueRange=0,this._addedLabels=[]}init(t){const i=this._addedLabels;if(i.length){const t=this.getLabels();for(const{index:e,label:s}of i)t[e]===s&&t.splice(e,1);this._addedLabels=[]}super.init(t)}parse(t,i){if(N(t))return null;const e=this.getLabels();return((t,i)=>null===t?null:kt(Math.round(t),0,i))(i=isFinite(i)&&e[i]===t?i:function(t,i,e,s){const n=t.indexOf(i);return-1===n?((t,i,e,s)=>("string"==typeof i?(e=t.push(i)-1,s.unshift({index:e,label:i})):isNaN(i)&&(e=null),e))(t,i,e,s):n!==t.lastIndexOf(i)?e:n}(e,t,V(i,t),this._addedLabels),e.length-1)}determineDataLimits(){const{minDefined:t,maxDefined:i}=this.getUserBounds();let{min:e,max:s}=this.getMinMax(!0);"ticks"===this.options.bounds&&(t||(e=0),i||(s=this.getLabels().length-1)),this.min=e,this.max=s}buildTicks(){const t=this.min,i=this.max,e=this.options.offset,s=[];let n=this.getLabels();n=0===t&&i===n.length-1?n:n.slice(t,i+1),this._valueRange=Math.max(n.length-(e?0:1),1),this._startValue=this.min-(e?.5:0);for(let e=t;e<=i;e++)s.push({value:e});return s}getLabelForValue(t){return _n.call(this,t)}configure(){super.configure(),this.isHorizontal()||(this._reversePixels=!this._reversePixels)}getPixelForValue(t){return"number"!=typeof t&&(t=this.parse(t)),null===t?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getPixelForTick(t){const i=this.ticks;return t<0||t>i.length-1?null:this.getPixelForValue(i[t].value)}getValueForPixel(t){return Math.round(this._startValue+this.getDecimalForPixel(t)*this._valueRange)}getBasePixel(){return this.bottom}},class extends On{static id="linear";static defaults={ticks:{callback:Xt.formatters.numeric}};determineDataLimits(){const{min:t,max:i}=this.getMinMax(!0);this.min=$(t)?t:0,this.max=$(i)?i:1,this.handleTickRangeOptions()}computeTickLimit(){const t=this.isHorizontal(),i=t?this.width:this.height,e=yt(this.options.ticks.minRotation),s=(t?Math.sin(e):Math.cos(e))||.001,n=this._resolveTickFontOptions(0);return Math.ceil(i/Math.min(40,n.lineHeight/s))}getPixelForValue(t){return null===t?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getValueForPixel(t){return this._startValue+this.getDecimalForPixel(t)*this._valueRange}},rn,wn,hn);const Sn=class{constructor(e){t(this,e),this.errorEvent=i(this,"error-event"),this.loading=!0,this.errorMessage=""}componentDidLoad(){this.getGrossPayment&&this.fetchData()}propChanged(){this.getGrossPayment&&this.fetchData()}grossVolumeReportChanged(t){t&&(this.chart?this.updateChartData(t):this.initChart(t))}async fetchData(){this.loading=!0,this.getGrossPayment({onSuccess:t=>{this.loading=!1,this.grossVolumeReport=t},onError:({error:t,code:i,severity:e})=>{this.loading=!1,this.errorMessage=t,this.errorEvent.emit({errorCode:i,message:t,severity:e})}})}initChart(t){const{dates:i,total:e}=t,s=i.reverse(),o=((t,i,e)=>({type:"bar",options:{plugins:{legend:{display:!1},title:{display:!0,text:["Trailing 30 Days","Gross Payments",n(t)],position:"top",align:"start"},tooltip:{displayColors:!1,intersect:!1,callbacks:{label:t=>{let s=t.dataIndex;return[r(i[s].date,e),n(i[s].value)]}}}},scales:{x:{grid:{drawOnChartArea:!1,drawTicks:!1},ticks:{callback:t=>{if(0===t||t===i.length-1)return r(i[t].date,e)}}},y:{display:!1}}},data:{labels:i.map((()=>"")),datasets:[{label:"Gross Volume by Date",data:i.map((t=>t.value))}]}}))(e,s,s[i.length-1].date);this.chart=new Hs(this.chartRef.getContext("2d"),o)}updateChartData(t){const i=t.dates.map((t=>t.value));this.chart.data.datasets.forEach((t=>{t.data=i})),this.chart.update()}disconnectedCallback(){this.chart&&this.chart.destroy()}render(){return e(s,{key:"23c2f499d03273189d31adaa1786831a04b65b8d"},this.loading&&e(h,{key:"0b57cbb314d3b87c24e09d4ea7660e6e0a988dc6"}),this.errorMessage?o(this.errorMessage):e("canvas",{id:"chart",ref:t=>this.chartRef=t}))}static get watchers(){return{getGrossPayment:["propChanged"],grossVolumeReport:["grossVolumeReportChanged"]}}};export{Sn as gross_payment_chart_core}
@@ -0,0 +1 @@
1
+ import{r as e,h as a}from"./p-DOjVAAtq.js";import"./p-a6tcNl_T.js";import"./p-HXpYMWUU.js";import"./p-Cjcsf8ku.js";import{I as t,a as s}from"./p-C98BC5W5.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";import{f as l,p,c}from"./p-lKnUT24T.js";import{e as o,s as r,p as i}from"./p-xDbRW9xn.js";import{S as d}from"./p-BhCH9S0e.js";import"./p-CZfYo5-1.js";import"./p-DdMxswn1.js";import"./p-Bgnhf5c9.js";import"./p-Dt-vy9Le.js";import"./p-BX8GieXu.js";const m=class{constructor(a){e(this,a),this.setParamsOnChange=(e,a)=>{l[e]=a}}componentWillLoad(){Object.entries({status:this.checkoutStatus,payment_mode:this.paymentMode}).forEach((([e,a])=>{a&&(p[e]=a)}))}get checkoutStatusOptions(){return[{label:"All",value:""},{label:"Created",value:t.created},{label:"Completed",value:t.completed},{label:"Attempted",value:t.attempted},{label:"Expired",value:t.expired}]}get checkoutPaymentModeOptions(){return[{label:"All",value:""},{label:"E-commerce",value:s.ecom},{label:"BNPL",value:s.bnpl}]}render(){const e=Object.assign({},l);return a(d,{key:"e68f5bd4687eaad5aae4890d81baec603f72b6de"},a("table-filters-menu",{key:"c09285765839dbfad618bc13f39883e3f11ae991",params:e,clearParams:c,part:o},a("div",{key:"96e32ecba5c64ccda108ceb583a82b1554b347a8",class:"grid-cols-2 gap-3 p-1"},a("div",{key:"7ce51a9f065004c169b577bcdd33af8ad7b01ac2",class:"p-2"},a("form-control-select",{key:"b6dfda04a58f51b989b1dc655df00500071fea98",name:"status",label:"Status",options:this.checkoutStatusOptions,inputHandler:this.setParamsOnChange,defaultValue:this.checkoutStatus||l.status||"",disabled:!!this.checkoutStatus,part:r})),a("div",{key:"4feb8c837611e6d0ec9cad6cb7a9f032db8cbbf5",class:"p-2"},a("form-control-select",{key:"5a2a6c0e21cb62ee792bce703ccdfc9e08a46cc0",name:"payment_mode",label:"Payment Mode",options:this.checkoutPaymentModeOptions,inputHandler:this.setParamsOnChange,defaultValue:this.paymentMode||l.payment_mode||"",disabled:!!this.paymentMode,part:i})))))}};export{m as justifi_checkouts_list_filters}
@@ -0,0 +1 @@
1
+ import{r as t,c as s,h as a,H as e}from"./p-DOjVAAtq.js";import{a4 as i,a5 as h,a6 as r,a7 as c,a8 as o,l as d}from"./p-xDbRW9xn.js";const f=class{constructor(a){t(this,a),this.formControlInput=s(this,"formControlInput"),this.formControlBlur=s(this,"formControlBlur"),this.isFocused=!1,this.handleFormControlInput=t=>{const s=t.target.getAttribute("name");this.inputHandler(s,this.value),this.formControlInput.emit({name:s,value:this.value})}}get part(){return this.errorText?i:this.isFocused&&this.checked?h:this.checked?r:this.isFocused?c:o}render(){return a(e,{key:"22c8d00ad3ac42efb24eb601f4a56870ff4a546a",class:"form-group d-flex flex-column"},a("div",{key:"35348f22933cc6c02ed7ac802d5fe99c430b425b",class:"form-check"},a("input",{key:"02e95c2f92aabfeda66a9b39c889140a2daac14a",ref:t=>this.radioElement=t,type:"radio",id:`${this.name}-${this.value}`,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onChange:this.handleFormControlInput,part:this.part,class:this.errorText?"form-check-input is-invalid":"form-check-input",disabled:this.disabled,value:this.value,checked:this.checked}),a("label",{key:"71514aeb916b728b1d5c139db7d8bbf61875565d",class:"form-check-label",htmlFor:`${this.name}-${this.value}`,part:d},this.label)),a("form-control-help-text",{key:"4b80544c0dde725a998d3d4a4ad96e48150a2ebf",helpText:this.helpText,name:this.name}),a("form-control-error-text",{key:"d5b711dc19ec9025989de7833839804df37f66dc",errorText:this.errorText,name:this.name}))}};export{f as form_control_radio}
@@ -0,0 +1 @@
1
+ import{r as l,h as i,H as t}from"./p-DOjVAAtq.js";import{c as e,D as s}from"./p-CH8Y3GSr.js";import{n as o,s as d,o as v}from"./p-Bgnhf5c9.js";import"./p-xDbRW9xn.js";import"./p-HXpYMWUU.js";const u=class{constructor(i){l(this,i)}render(){return!this.additionalQuestions||o(this.additionalQuestions)?null:i("div",null,i(s,{sectionTitle:"Additional Questions"}),i("div",{class:"d-flex flex-column gap-2 w-100 mt-3"},i("div",{class:"row gy-3"},i("div",{class:"col-12 col-md-6"},i(e,{title:"Business Revenue",value:this.additionalQuestions.business_revenue}),i(e,{title:"Business Payment Volume",value:this.additionalQuestions.business_payment_volume})))))}},a=class{constructor(i){l(this,i)}render(){return this.business?i("div",null,i(s,{sectionTitle:"Business Core Info Details"}),i("div",{class:"d-table gap-2 w-100 mt-3"},i("div",{class:"row gy-3"},i("div",{class:"col-12 col-md-6"},i(e,{title:"Legal Name",value:this.business.legal_name}),i(e,{title:"Doing Business As (DBA)",value:this.business.doing_business_as}),i(e,{title:"Business Classification",value:d(this.business.classification)}),i(e,{title:"Industry",value:this.business.industry})),i("div",{class:"col-12 col-md-6"},i(e,{title:"Tax ID",value:this.business.tax_id}),i(e,{title:"Website URL",value:this.business.website_url}),i(e,{title:"Email Address",value:this.business.email}),i(e,{title:"Phone Number",value:this.business.phone}))))):null}},n=class{constructor(i){l(this,i)}render(){var l,t,d,v,u,a,n;return!this.legalAddress||o(this.legalAddress)?null:i("div",null,i(s,{sectionTitle:"Business Legal Address Details"}),i("div",{class:"d-table gap-2 w-100 mt-3"},i("div",{class:"row gy-3"},i("div",{class:"col-12 col-md-6"},i(e,{title:"Country",value:null===(l=this.legalAddress)||void 0===l?void 0:l.country}),i(e,{title:"Legal Address",value:null===(t=this.legalAddress)||void 0===t?void 0:t.line1}),i(e,{title:"Address Line 2",value:null===(d=this.legalAddress)||void 0===d?void 0:d.line2})),i("div",{class:"col-12 col-md-6"},i(e,{title:"City",value:null===(v=this.legalAddress)||void 0===v?void 0:v.city}),i(e,{title:"State",value:null===(u=this.legalAddress)||void 0===u?void 0:u.state}),i(e,{title:"Postal Code",value:null===(n=null===(a=this.legalAddress)||void 0===a?void 0:a.postal_code)||void 0===n?void 0:n.toString()})))))}},r=class{constructor(i){l(this,i)}render(){var l;return(null===(l=null==this?void 0:this.owners)||void 0===l?void 0:l.length)?i(t,null,!!(null==this?void 0:this.owners.length)&&this.owners.map((l=>{var t,o,d,u,a;return[i(s,{sectionTitle:`Owner ${null==l?void 0:l.name}'s Details`}),i("div",{class:"d-flex flex-column gap-2 w-100 mt-3"},i("div",{class:"col-md-6"},i(e,{title:"Name",value:null==l?void 0:l.name}),i(e,{title:"Title",value:null==l?void 0:l.title}),i(e,{title:"Email",value:null==l?void 0:l.email}),i(e,{title:"Phone",value:null==l?void 0:l.phone}),i(e,{title:"Date of Birth",value:v(new Date(Number(null==l?void 0:l.dob_day),Number(null==l?void 0:l.dob_month),Number(null==l?void 0:l.dob_year)))}),i(e,{title:"Identification Number",value:`********${null==l?void 0:l.ssn_last4}`}),i(e,{title:"Line 1",value:null===(t=null==l?void 0:l.address)||void 0===t?void 0:t.line1}),i(e,{title:"Line 2",value:null===(o=null==l?void 0:l.address)||void 0===o?void 0:o.line2}),i(e,{title:"City",value:null===(d=null==l?void 0:l.address)||void 0===d?void 0:d.city}),i(e,{title:"State",value:null===(u=null==l?void 0:l.address)||void 0===u?void 0:u.state}),i(e,{title:"Zip",value:null===(a=null==l?void 0:l.address)||void 0===a?void 0:a.postal_code})))]}))):null}},c=class{constructor(i){l(this,i)}render(){var l,t,d,u,a,n,r,c,h,m,p,f,g,D;return!this.representative||o(this.representative)?null:i("div",null,i(s,{sectionTitle:"Representative Details"}),i("div",{class:"d-flex flex-column gap-2 w-100 mt-3"},i("div",{class:"row gy-3"},i("div",{class:"col-12 col-md-6"},i(e,{title:"Name",value:null===(l=this.representative)||void 0===l?void 0:l.name}),i(e,{title:"ID",value:null===(t=this.representative)||void 0===t?void 0:t.id}),i(e,{title:"Address",value:null===(u=null===(d=this.representative)||void 0===d?void 0:d.address)||void 0===u?void 0:u.line1}),i(e,{title:"Created At",value:(null===(a=this.representative)||void 0===a?void 0:a.created_at)&&v(null===(n=this.representative)||void 0===n?void 0:n.created_at)})),i("div",{class:"col-12 col-md-6"},i(e,{title:"Title",value:null===(r=this.representative)||void 0===r?void 0:r.title}),i(e,{title:"Is Owner?",value:null===(c=this.representative)||void 0===c?void 0:c.is_owner.toString()}),i(e,{title:"Date Of Birth",value:this.representative&&v(new Date(Number(null===(h=this.representative)||void 0===h?void 0:h.dob_year),Number(null===(m=this.representative)||void 0===m?void 0:m.dob_month)-1,Number(null===(p=this.representative)||void 0===p?void 0:p.dob_day)))}),i(e,{title:"Email",value:null===(f=this.representative)||void 0===f?void 0:f.email}),i(e,{title:"Phone",value:null===(g=this.representative)||void 0===g?void 0:g.phone}),i(e,{title:"Updated At",value:this.representative&&v(null===(D=this.representative)||void 0===D?void 0:D.updated_at)})))))}};export{u as additional_questions_details,a as core_info_details,n as legal_address_details,r as owner_details,c as representative_details}
@@ -1 +1 @@
1
- import{h as s,F as t,r as i,c as e}from"./p-_b8l4IX7.js";import{E as l}from"./p-D1Na2I0C.js";import{S as r}from"./p-DTwFW2k_.js";import"./p-CZfYo5-1.js";import{S as o}from"./p-CE-MNrID.js";import"./p-CA_TyBed.js";const n=()=>{const i=()=>s("div",{class:"mt-5"},s(o,{width:"40%",height:"1.5rem"}),s("hr",null),s("div",{class:"row g-3"},s("div",{class:"col-12 col-md-6"},s(o,null),s(o,null),s(o,null)),s("div",{class:"col-12 col-md-6"},s(o,null),s(o,null),s(o,null))));return s(t,null,s(i,null),s(i,null),s(i,null),s(i,null))};var a;!function(s){s.LOADING="loading",s.READY="ready",s.ERROR="error"}(a||(a={}));const d=class{constructor(s){i(this,s),this.errorEvent=e(this,"error-event"),this.renderState=a.LOADING}async componentWillLoad(){this.getBusiness&&this.fetchData()}fetchData(){this.renderState=a.LOADING,this.getBusiness({onSuccess:({business:s})=>{this.business=s,this.renderState=a.READY},onError:({error:s,code:t,severity:i})=>{this.errorMessage=s,this.renderState=a.ERROR,this.errorEvent.emit({errorCode:t,message:s,severity:i})}})}render(){return s(r,null,this.renderState===a.LOADING?s(n,null):this.renderState===a.ERROR?l(this.errorMessage):s("justifi-details",{"error-message":this.errorMessage},s("div",{slot:"detail-sections"},s("core-info-details",{business:this.business}),s("legal-address-details",{legalAddress:this.business.legal_address}),s("representative-details",{representative:this.business.representative}),s("owner-details",{owners:this.business.owners}),s("additional-questions-details",{additionalQuestions:this.business.additional_questions}))))}};export{d as business_details_core}
1
+ import{h as s,F as t,r as i,c as e}from"./p-DOjVAAtq.js";import{E as r}from"./p-CH8Y3GSr.js";import{S as l}from"./p-BhCH9S0e.js";import"./p-CZfYo5-1.js";import{S as o}from"./p-T2yENPvU.js";import"./p-xDbRW9xn.js";const n=()=>{const i=()=>s("div",{class:"mt-5"},s(o,{width:"40%",height:"1.5rem"}),s("hr",null),s("div",{class:"row g-3"},s("div",{class:"col-12 col-md-6"},s(o,null),s(o,null),s(o,null)),s("div",{class:"col-12 col-md-6"},s(o,null),s(o,null),s(o,null))));return s(t,null,s(i,null),s(i,null),s(i,null),s(i,null))};var a;!function(s){s.LOADING="loading",s.READY="ready",s.ERROR="error"}(a||(a={}));const d=class{constructor(s){i(this,s),this.errorEvent=e(this,"error-event"),this.renderState=a.LOADING}async componentWillLoad(){this.getBusiness&&this.fetchData()}fetchData(){this.renderState=a.LOADING,this.getBusiness({onSuccess:({business:s})=>{this.business=s,this.renderState=a.READY},onError:({error:s,code:t,severity:i})=>{this.errorMessage=s,this.renderState=a.ERROR,this.errorEvent.emit({errorCode:t,message:s,severity:i})}})}render(){return s(l,null,this.renderState===a.LOADING?s(n,null):this.renderState===a.ERROR?r(this.errorMessage):s("justifi-details",{"error-message":this.errorMessage},s("div",{slot:"detail-sections"},s("core-info-details",{business:this.business}),s("legal-address-details",{legalAddress:this.business.legal_address}),s("representative-details",{representative:this.business.representative}),s("owner-details",{owners:this.business.owners}),s("additional-questions-details",{additionalQuestions:this.business.additional_questions}))))}};export{d as business_details_core}
@@ -0,0 +1 @@
1
+ import{r as e,h as a}from"./p-DOjVAAtq.js";import{l as t}from"./p-Bde7dY9t.js";import{f as s,p as d,c as i}from"./p-C2JJBtMc.js";import{f as l,g as f,t as r,h as c,j as p,k as o}from"./p-xDbRW9xn.js";import{S as n}from"./p-BhCH9S0e.js";import"./p-CZfYo5-1.js";import{c as b,a as m}from"./p-Bgnhf5c9.js";import"./p-BFTU3MAI.js";import"./p-DdMxswn1.js";import"./p-HXpYMWUU.js";const u=class{constructor(a){e(this,a),this.setParamsOnChange=(e,a)=>{s[e]=a},this.handleDateInput=(e,a)=>{const t=b(a,{setExactTime:!0});this.setParamsOnChange(e,t)}}componentWillLoad(){this.debouncedSetParamsOnChange=t.debounce(this.setParamsOnChange,300),Object.entries({payment_id:this.paymentId,terminal_id:this.terminalId,payment_status:this.paymentStatus,created_after:this.createdAfter,created_before:this.createdBefore}).forEach((([e,a])=>{a&&(d[e]=a)}))}get paymentStatusOptions(){return[{label:"All",value:""},{label:"Pending",value:"pending"},{label:"Authorized",value:"authorized"},{label:"Succeeded",value:"succeeded"},{label:"Failed",value:"failed"},{label:"Disputed",value:"disputed"},{label:"Refunded",value:"refunded"}]}render(){const e=Object.assign({},s);return a(n,{key:"a7558557fc2568a6d2a1b440b421d534f62a6163"},a("table-filters-menu",{key:"4e185e33a7835795b6858ec8419fc2ba8ab64a9d",params:e,clearParams:i,part:l},a("div",{key:"619b459dbd961cc2c5eb192f830f51f123f59604",class:"grid-cols-2 gap-3 p-1"},a("div",{key:"53e8c53aa1f1aff0ecebc9ebb1f13bff2a053795",class:"p-2"},a("form-control-text",{key:"04698a7742b278abbb720d4884f041509f5ac8ad",name:"payment_id",label:"Payment ID",inputHandler:this.debouncedSetParamsOnChange,defaultValue:this.paymentId||s.payment_id,disabled:!!this.paymentId,part:f})),a("div",{key:"967ef74a4642cfd758801e5f942a20fd7375fbe3",class:"p-2"},a("form-control-text",{key:"3ca21f2ca7b45bba64a1d6d734be9beaf00c14fe",name:"terminal_id",label:"Terminal ID",inputHandler:this.debouncedSetParamsOnChange,defaultValue:this.terminalId||s.terminal_id,disabled:!!this.terminalId,part:r})),a("div",{key:"a5ec7ca0881d8d1bf2f0efa2c84270d3cd68832f",class:"p-2"},a("form-control-select",{key:"fd2d57c06e46ee77493ccfdc81927caa41c4d867",name:"payment_status",label:"Status",options:this.paymentStatusOptions,inputHandler:this.setParamsOnChange,defaultValue:this.paymentStatus||s.payment_status||"",disabled:!!this.paymentStatus,part:c})),a("div",{key:"b272738dc727933cb4f21405ae222973aadde76d",class:"p-2"},a("form-control-date",{key:"3cfb486fc05e023a3eb9960de13e0bbf2d179d79",name:"created_after",label:"Created After",inputHandler:this.handleDateInput,defaultValue:m(this.createdAfter,{showInputDateTime:!0})||m(s.created_after,{showInputDateTime:!0}),showTime:!0,disabled:!!this.createdAfter,part:p})),a("div",{key:"008a9c18830cadcf0da9d971077e8efd6ca9a714",class:"p-2"},a("form-control-date",{key:"a8805f485e37268df0897c6d5eff19e9c2324542",name:"created_before",label:"Created Before",inputHandler:this.handleDateInput,defaultValue:m(this.createdBefore,{showInputDateTime:!0})||m(s.created_before,{showInputDateTime:!0}),showTime:!0,disabled:!!this.createdBefore,part:o})))))}};export{u as justifi_payments_list_filters}
@@ -0,0 +1 @@
1
+ import{c as s}from"./p-DdMxswn1.js";const t={},a={},o=s((()=>t)),{state:c,on:e}=o,p=s((()=>a)),{state:j}=p,n=()=>Object.assign(Object.assign({},c),j),r=()=>{o.reset()};export{r as c,c as f,n as g,e as o,j as p}
@@ -1 +1 @@
1
- import{r as e,h as n,H as t,c as i,g as o}from"./p-_b8l4IX7.js";import{c as r}from"./p-hj8k0lRi.js";import{i as a,b as s,a as c,c as d,l as u}from"./p-CA_TyBed.js";import{g as f}from"./p-BFTU3MAI.js";import{F as l}from"./p-BgFM_jvF.js";import{p as h}from"./p-BRhnhmpB.js";const m=r({focused:{boxShadow:"",border:""},focusedAndInvalid:{boxShadow:"",border:""},fontStyles:{fontFamily:"",fontSize:"",fontWeight:"",lineHeight:"",margin:"",padding:""}}),{state:w,set:g}=m,b=class{constructor(n){e(this,n),this.isFocused=!1,this.errorText=""}async componentDidLoad(){const e=await this.getBaseFontStyles();g("fontStyles",e);const n=await this.getFocusedStyles();g("focused",n);const t=await this.getFocusedAndInvalidStyles();g("focusedAndInvalid",t)}async getBaseFontStyles(){return new Promise((e=>{setTimeout((()=>{const n=getComputedStyle(this.hiddenInput);e({fontFamily:n.fontFamily,fontSize:n.fontSize,fontWeight:n.fontWeight,lineHeight:n.lineHeight,margin:n.margin,padding:n.padding,color:n.color})}),500)}))}async getFocusedStyles(){return new Promise((e=>{this.hiddenInput.focus(),setTimeout((()=>{this.hiddenInput.blur();let n=getComputedStyle(this.hiddenInput);e({boxShadow:n.boxShadow,border:n.border})}),500)}))}async getFocusedAndInvalidStyles(){return new Promise((e=>{this.hiddenInput.focus(),this.errorText="Error",setTimeout((()=>{const n=getComputedStyle(this.hiddenInput),t={boxShadow:n.boxShadow,border:n.border};this.hiddenInput.blur(),e(t)}),500)}))}get part(){return this.isFocused&&this.errorText?a:this.errorText?s:this.isFocused?c:d}render(){return n(t,{key:"1058a3fea9276fe3f9eb3158365a839603e06532"},n("input",{key:"856ad55446d13a3a8d935e90bbdba5a0ea77b706",ref:e=>this.hiddenInput=e,type:"text",class:this.errorText?"form-control is-invalid":"form-control",onFocus:()=>this.isFocused=!0,onBlur:()=>this.isFocused=!1,part:this.part,tabindex:"-1",style:{height:"0",opacity:"0",pointerEvents:"none",animation:"none"}}))}};var p,y,v={exports:{}},k=f((p||(p=1,y=v,console.info("\nIFRAME-RESIZER\n\nIframe-Resizer 5 is now available via the following two packages:\n\n * @iframe-resizer/parent\n * @iframe-resizer/child\n\nAdditionally their are also new versions of iframe-resizer for React, Vue, and jQuery.\n\nVersion 5 of iframe-resizer has been extensively rewritten to use modern browser APIs, which has enabled significantly better performance and greater accuracy in the detection of content resizing events.\n\nPlease see https://iframe-resizer.com/upgrade for more details.\n"),function(e){if("undefined"!=typeof window){var n,t,i=0,o=!1,r=!1,a="[iFrameSizer]",s=null,c=window.requestAnimationFrame,d=Object.freeze({max:1,scroll:1,bodyScroll:1,documentElementScroll:1}),u={},f=null,l=Object.freeze({autoResize:!0,bodyBackground:null,bodyMargin:null,bodyMarginV1:8,bodyPadding:null,checkOrigin:!0,inPageLinks:!1,enablePublicMethods:!0,heightCalculationMethod:"bodyOffset",id:"iFrameResizer",interval:32,license:"1jqr0si6pnt",log:!1,maxHeight:1/0,maxWidth:1/0,minHeight:0,minWidth:0,mouseEvents:!0,resizeFrom:"parent",scrolling:!1,sizeHeight:!0,sizeWidth:!1,warningTimeout:5e3,tolerance:0,widthCalculationMethod:"scroll",onClose:function(){return!0},onClosed:function(){},onInit:function(){},onMessage:function(){k("onMessage function not defined")},onMouseEnter:function(){},onMouseLeave:function(){},onResized:function(){},onScroll:function(){return!0}}),h={};window.jQuery!==e&&((t=window.jQuery).fn?t.fn.iFrameResize||(t.fn.iFrameResize=function(e){return this.filter("iframe").each((function(n,t){A(t,e)})).end()}):v("","Unable to bind to jQuery, it is not fully loaded.")),y.exports=P(),window.iFrameResize=window.iFrameResize||P()}function m(){return window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver}function w(e,n,t){e.addEventListener(n,t,!1)}function g(e,n,t){e.removeEventListener(n,t,!1)}function b(e){return u[e]?u[e].log:o}function p(e,n){x("log",e,n,b(e))}function v(e,n){x("info",e,n,b(e))}function k(e,n){x("warn",e,n,!0)}function x(e,n,t,i){!0===i&&"object"==typeof window.console&&console[e](function(e){return a+"["+function(e){var n="Host page: "+e;return window.top!==window.self&&(n=window.parentIFrame&&window.parentIFrame.getId?window.parentIFrame.getId()+": "+e:"Nested host page: "+e),n}(e)+"]"}(n),t)}function F(e){function n(){t("Height"),t("Width"),C((function(){O(W),j(H),l("onResized",W)}),W,"init")}function t(e){var n=Number(u[H]["max"+e]),t=Number(u[H]["min"+e]),i=e.toLowerCase(),o=Number(W[i]);p(H,"Checking "+i+" is in range "+t+"-"+n),o<t&&(o=t,p(H,"Set "+i+" to min value")),o>n&&(o=n,p(H,"Set "+i+" to max value")),W[i]=""+o}function i(e){return A.slice(A.indexOf(":")+7+e)}function o(e,n){var t,i;t=function(){var t,i;E("Send Page Info","pageInfo:"+(t=document.body.getBoundingClientRect(),i=W.iframe.getBoundingClientRect(),JSON.stringify({iframeHeight:i.height,iframeWidth:i.width,clientHeight:Math.max(document.documentElement.clientHeight,window.innerHeight||0),clientWidth:Math.max(document.documentElement.clientWidth,window.innerWidth||0),offsetTop:parseInt(i.top-t.top,10),offsetLeft:parseInt(i.left-t.left,10),scrollTop:window.pageYOffset,scrollLeft:window.pageXOffset,documentHeight:document.documentElement.clientHeight,documentWidth:document.documentElement.clientWidth,windowHeight:window.innerHeight,windowWidth:window.innerWidth})),e,n)},h[i=n]||(h[i]=setTimeout((function(){h[i]=null,t()}),32))}function r(e){var n=e.getBoundingClientRect();return M(H),{x:Math.floor(Number(n.left)+Number(s.x)),y:Math.floor(Number(n.top)+Number(s.y))}}function c(e){var n=e?r(W.iframe):{x:0,y:0},t={x:Number(W.width)+n.x,y:Number(W.height)+n.y};p(H,"Reposition requested from iFrame (offset x:"+n.x+" y:"+n.y+")"),window.top===window.self?(s=t,d(),p(H,"--")):window.parentIFrame?window.parentIFrame["scrollTo"+(e?"Offset":"")](t.x,t.y):k(H,"Unable to scroll to requested position, window.parentIFrame not found")}function d(){!1===l("onScroll",s)?T():j(H)}function f(e){var n={};if(0===Number(W.width)&&0===Number(W.height)){var t=i(9).split(":");n={x:t[1],y:t[0]}}else n={x:W.width,y:W.height};l(e,{iframe:W.iframe,screenX:Number(n.x),screenY:Number(n.y),type:W.type})}function l(e,n){return I(H,e,n)}var m,b,y,x,F,z,A=e.data,W={},H=null;"[iFrameResizerChild]Ready"===A?function(){for(var e in u)E("iFrame requested init",N(e),u[e].iframe,e)}():a===(""+A).slice(0,13)&&A.slice(13).split(":")[0]in u?(x=(y=A.slice(13).split(":"))[1]?parseInt(y[1],10):0,F=u[y[0]]&&u[y[0]].iframe,z=getComputedStyle(F),W={iframe:F,id:y[0],height:x+function(e){return"border-box"!==e.boxSizing?0:(e.paddingTop?parseInt(e.paddingTop,10):0)+(e.paddingBottom?parseInt(e.paddingBottom,10):0)}(z)+function(e){return"border-box"!==e.boxSizing?0:(e.borderTopWidth?parseInt(e.borderTopWidth,10):0)+(e.borderBottomWidth?parseInt(e.borderBottomWidth,10):0)}(z),width:y[2],type:y[3]},u[H=W.id]&&(u[H].loaded=!0),(b=W.type in{true:1,false:1,undefined:1})&&p(H,"Ignoring init message from meta parent page"),!b&&function(e){var n=!0;return u[e]||(n=!1,k(W.type+" No settings for "+e+". Message was: "+A)),n}(H)&&(p(H,"Received: "+A),m=!0,null===W.iframe&&(k(H,"IFrame ("+W.id+") not found"),m=!1),m&&function(){var n,t=e.origin,i=u[H]&&u[H].checkOrigin;if(i&&""+t!="null"&&!(i.constructor===Array?function(){var e=0,n=!1;for(p(H,"Checking connection is from allowed list of origins: "+i);e<i.length;e++)if(i[e]===t){n=!0;break}return n}():(p(H,"Checking connection is from: "+(n=u[H]&&u[H].remoteHost)),t===n)))throw new Error("Unexpected message received from: "+t+" for "+W.iframe.id+". Message was: "+e.data+". This error can be disabled by setting the checkOrigin: false option or by providing of array of trusted domains.");return!0}()&&function(){switch(u[H]&&u[H].firstRun&&u[H]&&(u[H].firstRun=!1),W.type){case"close":S(W.iframe);break;case"message":m=i(6),p(H,"onMessage passed: {iframe: "+W.iframe.id+", message: "+m+"}"),l("onMessage",{iframe:W.iframe,message:JSON.parse(m)}),p(H,"--");break;case"mouseenter":f("onMouseEnter");break;case"mouseleave":f("onMouseLeave");break;case"autoResize":u[H].autoResize=JSON.parse(i(9));break;case"scrollTo":c(!1);break;case"scrollToOffset":c(!0);break;case"pageInfo":o(u[H]&&u[H].iframe,H),function(){function e(e,i){function r(){u[t]?o(u[t].iframe,t):n()}["scroll","resize"].forEach((function(n){p(t,e+n+" listener for sendPageInfo"),i(window,n,r)}))}function n(){e("Remove ",g)}var t=H;e("Add ",w),u[t]&&(u[t].stopPageInfo=n)}();break;case"pageInfoStop":u[H]&&u[H].stopPageInfo&&(u[H].stopPageInfo(),delete u[H].stopPageInfo);break;case"inPageLink":t=i(9).split("#")[1]||"",a=decodeURIComponent(t),(h=document.getElementById(a)||document.getElementsByName(a)[0])?(e=r(h),p(H,"Moving to in page link (#"+t+") at x: "+e.x+" y: "+e.y),s={x:e.x,y:e.y},d(),p(H,"--")):window.top===window.self?p(H,"In page link #"+t+" not found"):window.parentIFrame?window.parentIFrame.moveToAnchor(t):p(H,"In page link #"+t+" not found and window.parentIFrame not found");break;case"reset":R(W);break;case"init":n(),l("onInit",W.iframe);break;default:0===Number(W.width)&&0===Number(W.height)?k("Unsupported message received ("+W.type+"), this is likely due to the iframe containing a later version of iframe-resizer than the parent page"):n()}var e,t,a,h,m}())):v(H,"Ignored: "+A)}function I(e,n,t){var i=null,o=null;if(u[e]){if("function"!=typeof(i=u[e][n]))throw new TypeError(n+" on iFrame["+e+"] is not a function");o=i(t)}return o}function z(e){delete u[e.id]}function S(e){var t=e.id;if(!1!==I(t,"onClose",t)){p(t,"Removing iFrame: "+t);try{e.parentNode&&e.parentNode.removeChild(e)}catch(e){k(e)}I(t,"onClosed",t),p(t,"--"),z(e),n&&(n.disconnect(),n=null)}else p(t,"Close iframe cancelled by onClose event")}function M(n){null===s&&p(n,"Get page position: "+(s={x:window.pageXOffset===e?document.documentElement.scrollLeft:window.pageXOffset,y:window.pageYOffset===e?document.documentElement.scrollTop:window.pageYOffset}).x+","+s.y)}function j(e){null!==s&&(window.scrollTo(s.x,s.y),p(e,"Set page position: "+s.x+","+s.y),T())}function T(){s=null}function R(e){p(e.id,"Size reset requested by "+("init"===e.type?"host page":"iFrame")),M(e.id),C((function(){O(e),E("reset","reset",e.iframe,e.id)}),e,"reset")}function O(e){function n(n){r||"0"!==e[n]||(r=!0,p(i,"Hidden iFrame detected, creating visibility listener"),function(){function e(){Object.keys(u).forEach((function(e){!function(e){function n(n){return"0px"===(u[e]&&u[e].iframe.style[n])}u[e]&&null!==u[e].iframe.offsetParent&&(n("height")||n("width"))&&E("Visibility change","resize",u[e].iframe,e)}(e)}))}function n(n){p("window","Mutation observed: "+n[0].target+" "+n[0].type),W(e,16)}var t,i=m();i&&(t=document.querySelector("body"),new i(n).observe(t,{attributes:!0,attributeOldValue:!1,characterData:!0,characterDataOldValue:!1,childList:!0,subtree:!0}))}())}function t(t){!function(n){e.id?(e.iframe.style[n]=e[n]+"px",p(e.id,"IFrame ("+i+") "+n+" set to "+e[n]+"px")):p("undefined","messageData id not set")}(t),n(t)}var i=e.iframe.id;u[i]&&(u[i].sizeHeight&&t("height"),u[i].sizeWidth&&t("width"))}function C(e,n,t){t!==n.type&&c&&!window.jasmine?(p(n.id,"Requesting animation frame"),c(e)):e()}function E(e,n,t,i,o){var r,s=!1;u[i=i||t.id]&&(t&&"contentWindow"in t&&null!==t.contentWindow?(p(i,"["+e+"] Sending msg to iframe["+i+"] ("+n+") targetOrigin: "+(r=u[i]&&u[i].targetOrigin)),t.contentWindow.postMessage(a+n,r)):k(i,"["+e+"] IFrame("+i+") not found"),o&&u[i]&&u[i].warningTimeout&&(u[i].msgTimeout=setTimeout((function(){!u[i]||u[i].loaded||s||(s=!0,k(i,"IFrame has not responded within "+u[i].warningTimeout/1e3+" 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."))}),u[i].warningTimeout)))}function N(e){return e+":"+u[e].bodyMarginV1+":"+u[e].sizeWidth+":"+u[e].log+":"+u[e].interval+":"+u[e].enablePublicMethods+":"+u[e].autoResize+":"+u[e].bodyMargin+":"+u[e].heightCalculationMethod+":"+u[e].bodyBackground+":"+u[e].bodyPadding+":"+u[e].tolerance+":"+u[e].inPageLinks+":"+u[e].resizeFrom+":"+u[e].widthCalculationMethod+":"+u[e].mouseEvents}function A(t,r){function a(e){var n=e.split("Callback");if(2===n.length){var t="on"+n[0].charAt(0).toUpperCase()+n[0].slice(1);this[t]=this[e],delete this[e],k(f,"Deprecated: '"+e+"' has been renamed '"+t+"'. The old method will be removed in the next major version.")}}var s,c,f=function(e){if("string"!=typeof e)throw new TypeError("Invaild id for iFrame. Expected String");var n;return""===e&&(t.id=(n=r&&r.id||l.id+i++,null!==document.getElementById(n)&&(n+=i++),e=n),o=(r||{}).log,p(e,"Added missing iframe ID: "+e+" ("+t.src+")")),e}(t.id);f in u&&"iFrameResizer"in t?k(f,"Ignored iFrame, already setup."):(function(e){var n;e=e||{},u[f]=Object.create(null),u[f].iframe=t,u[f].firstRun=!0,u[f].remoteHost=t.src&&t.src.split("/").slice(0,3).join("/"),function(e){if("object"!=typeof e)throw new TypeError("Options is not an object")}(e),Object.keys(e).forEach(a,e),function(e){for(var n in l)Object.prototype.hasOwnProperty.call(l,n)&&(u[f][n]=Object.prototype.hasOwnProperty.call(e,n)?e[n]:l[n])}(e),u[f]&&(u[f].targetOrigin=!0===u[f].checkOrigin?""===(n=u[f].remoteHost)||null!==n.match(/^(about:blank|javascript:|file:\/\/)/)?"*":n:"*")}(r),function(){switch(p(f,"IFrame scrolling "+(u[f]&&u[f].scrolling?"enabled":"disabled")+" for "+f),t.style.overflow=!1===(u[f]&&u[f].scrolling)?"hidden":"auto",u[f]&&u[f].scrolling){case"omit":break;case!0:t.scrolling="yes";break;case!1:t.scrolling="no";break;default:t.scrolling=u[f]?u[f].scrolling:"no"}}(),function(){function e(e){var n=u[f][e];1/0!==n&&0!==n&&(t.style[e]="number"==typeof n?n+"px":n,p(f,"Set "+e+" = "+t.style[e]))}function n(e){if(u[f]["min"+e]>u[f]["max"+e])throw new Error("Value for min"+e+" can not be greater than max"+e)}n("Height"),n("Width"),e("maxHeight"),e("minHeight"),e("maxWidth"),e("minWidth")}(),"number"!=typeof(u[f]&&u[f].bodyMargin)&&"0"!==(u[f]&&u[f].bodyMargin)||(u[f].bodyMarginV1=u[f].bodyMargin,u[f].bodyMargin=u[f].bodyMargin+"px"),s=N(f),(c=m())&&(n=function(e){if(!t.parentNode)return null;var n=new e((function(e){e.forEach((function(e){Array.prototype.slice.call(e.removedNodes).forEach((function(e){e===t&&S(t)}))}))}));return n.observe(t.parentNode,{childList:!0}),n}(c)),w(t,"load",(function(){E("iFrame.onload",s,t,e,!0),(!u[f]||!u[f].firstRun)&&u[f]&&u[f].heightCalculationMethod in d&&R({iframe:t,height:0,width:0,type:"init"})})),E("init",s,t,e,!0),u[f]&&(u[f].iframe.iFrameResizer={close:S.bind(null,u[f].iframe),removeListeners:z.bind(null,u[f].iframe),resize:E.bind(null,"Window resize","resize",u[f].iframe),moveToAnchor:function(e){E("Move to anchor","moveToAnchor:"+e,u[f].iframe,f)},sendMessage:function(e){E("Send Message","message:"+(e=JSON.stringify(e)),u[f].iframe,f)}}))}function W(e,n){null===f&&(f=setTimeout((function(){f=null,e()}),n))}function H(){"hidden"!==document.visibilityState&&(p("document","Trigger event: Visibility change"),W((function(){L("Tab Visible","resize")}),16))}function L(e,n){Object.keys(u).forEach((function(t){(function(e){return u[e]&&"parent"===u[e].resizeFrom&&u[e].autoResize&&!u[e].firstRun})(t)&&E(e,n,u[t].iframe,t)}))}function P(){function n(e,n){n&&(function(){if(!n.tagName)throw new TypeError("Object is not a valid DOM element");if("IFRAME"!==n.tagName.toUpperCase())throw new TypeError("Expected <IFRAME> tag, found <"+n.tagName+">")}(),A(n,e),t.push(n))}var t;return function(){var e,n=["moz","webkit","o","ms"];for(e=0;e<n.length&&!c;e+=1)c=window[n[e]+"RequestAnimationFrame"];c?c=c.bind(window):p("setup","RequestAnimationFrame not supported")}(),w(window,"message",F),w(window,"resize",(function(){p("window","Trigger event: resize"),W((function(){L("Window resize","resize")}),16)})),w(document,"visibilitychange",H),w(document,"-webkit-visibilitychange",H),function(i,o){switch(t=[],function(e){e&&e.enablePublicMethods&&k("enablePublicMethods option has been removed, public methods are now always available in the iFrame")}(i),typeof o){case"undefined":case"string":Array.prototype.forEach.call(document.querySelectorAll(o||"iframe"),n.bind(e,i));break;case"object":n(i,o);break;default:throw new TypeError("Unexpected data type ("+typeof o+")")}return t}}}()),v.exports));class x{constructor(e,n){this.iframe=e,this.iframeOrigin=n}postMessage(e,n){const t=Object.assign({eventType:e},n);this.iframe.contentWindow.postMessage(t,this.iframeOrigin)}addMessageListener(e){window.addEventListener("message",e)}removeMessageListener(e){window.removeEventListener("message",e)}postMessageWithResponseListener(e,n){return new Promise((t=>{const i=n=>{n.data.eventType===e&&(window.removeEventListener("message",i),t(n.data.data))};window.addEventListener("message",i),this.postMessage(e,n)}))}}const F=class{constructor(n){e(this,n),this.iframeLoaded=i(this,"iframeLoaded"),this.isFocused=!1,this.isValid=!0,this.dispatchMessageEvent=e=>{const{eventType:n,data:t}=e.data;(null==t?void 0:t.id)===this.inputId&&("focused"===n&&(this.isFocused=!0),"blurred"===n&&(this.isFocused=!1))}}disconnectedCallback(){this.frameService.removeMessageListener(this.dispatchMessageEvent)}async validate(){const e=await this.frameService.postMessageWithResponseListener("validate");return this.isValid=e.isValid,this.errorText=e.error.message,e}async tokenize(e,n,t){return this.frameService.postMessageWithResponseListener("tokenize",{clientId:e,paymentMethodMetadata:n,account:t,componentVersion:h.version})}initializeFrameCommunicationService(){var e;this.frameService=new x(this.iframeElement,this.iframeOrigin),null===(e=this.frameService)||void 0===e||e.addMessageListener(this.dispatchMessageEvent)}get part(){return this.isFocused&&!this.isValid?a:this.isValid?this.isFocused?c:d:s}get style(){return this.isFocused?this.isValid?w.focused:w.focusedAndInvalid:null}get urlParams(){const e=Object.fromEntries(Object.entries(w.fontStyles).map((([e,n])=>[e,btoa(String(n))])));return new URLSearchParams(e).toString()}render(){return n(t,{key:"0c3f4427120c3405bf47f60dd3bde638f0c3176e",class:"form-group d-flex flex-column"},n("div",{key:"6ba2a62c8df9db7b01341ea06fbe1df25a87e604",style:{visibility:this.iframeLoaded?"visible":"hidden",height:this.iframeLoaded?"auto":"0"}},n("label",{key:"cc7dfd2299382e473f6ce279c5ffe61794d56e59",class:"form-label",htmlFor:"",part:u},this.label||""),n("div",{key:"62406d7581a21dcdec52c993edc2a03cd8fce1ef",class:"p-0 d-flex form-control "+(this.isValid?"":"is-invalid"),part:this.part,style:Object.assign(Object.assign({},this.style),{overflow:"hidden"})},n("iframe",{key:"7c804be15e9029e003684bea21f93578269bdac7",id:this.inputId,name:this.inputId,src:`${this.iframeOrigin}?${this.urlParams}`,ref:e=>{this.iframeElement=e,this.initializeFrameCommunicationService()},width:"100%",onLoad:()=>{k({log:!1,onResized:()=>{this.iframeLoaded.emit()}},this.iframeElement)}})),n(l,{key:"2cb6be114be8cea65d880b6c21eacdf46052468c",errorText:this.errorText,name:this.inputId})))}get el(){return o(this)}};export{b as hidden_input,F as iframe_input}
1
+ import{r as e,h as n,H as t,c as i,g as o}from"./p-DOjVAAtq.js";import{c as r}from"./p-DdMxswn1.js";import{i as a,b as s,a as c,c as d,l as u}from"./p-xDbRW9xn.js";import{g as f}from"./p-BFTU3MAI.js";import{F as l}from"./p-NAjz1Xfo.js";import{p as h}from"./p-YyotqiSL.js";const m=r({focused:{boxShadow:"",border:""},focusedAndInvalid:{boxShadow:"",border:""},fontStyles:{fontFamily:"",fontSize:"",fontWeight:"",lineHeight:"",margin:"",padding:""}}),{state:w,set:g}=m,b=class{constructor(n){e(this,n),this.isFocused=!1,this.errorText=""}async componentDidLoad(){const e=await this.getBaseFontStyles();g("fontStyles",e);const n=await this.getFocusedStyles();g("focused",n);const t=await this.getFocusedAndInvalidStyles();g("focusedAndInvalid",t)}async getBaseFontStyles(){return new Promise((e=>{setTimeout((()=>{const n=getComputedStyle(this.hiddenInput);e({fontFamily:n.fontFamily,fontSize:n.fontSize,fontWeight:n.fontWeight,lineHeight:n.lineHeight,margin:n.margin,padding:n.padding,color:n.color})}),500)}))}async getFocusedStyles(){return new Promise((e=>{this.hiddenInput.focus(),setTimeout((()=>{this.hiddenInput.blur();let n=getComputedStyle(this.hiddenInput);e({boxShadow:n.boxShadow,border:n.border})}),500)}))}async getFocusedAndInvalidStyles(){return new Promise((e=>{this.hiddenInput.focus(),this.errorText="Error",setTimeout((()=>{const n=getComputedStyle(this.hiddenInput),t={boxShadow:n.boxShadow,border:n.border};this.hiddenInput.blur(),e(t)}),500)}))}get part(){return this.isFocused&&this.errorText?a:this.errorText?s:this.isFocused?c:d}render(){return n(t,{key:"547220ec7d5fec026ca4a3a0c8698ffc1e87d207"},n("input",{key:"dfc3979a87ec4e993e10c010d55d1bebdc0f003f",ref:e=>this.hiddenInput=e,type:"text",class:this.errorText?"form-control is-invalid":"form-control",onFocus:()=>this.isFocused=!0,onBlur:()=>this.isFocused=!1,part:this.part,tabindex:"-1",style:{height:"0",opacity:"0",pointerEvents:"none",animation:"none"}}))}};var p,y,v={exports:{}},k=f((p||(p=1,y=v,console.info("\nIFRAME-RESIZER\n\nIframe-Resizer 5 is now available via the following two packages:\n\n * @iframe-resizer/parent\n * @iframe-resizer/child\n\nAdditionally their are also new versions of iframe-resizer for React, Vue, and jQuery.\n\nVersion 5 of iframe-resizer has been extensively rewritten to use modern browser APIs, which has enabled significantly better performance and greater accuracy in the detection of content resizing events.\n\nPlease see https://iframe-resizer.com/upgrade for more details.\n"),function(e){if("undefined"!=typeof window){var n,t,i=0,o=!1,r=!1,a="[iFrameSizer]",s=null,c=window.requestAnimationFrame,d=Object.freeze({max:1,scroll:1,bodyScroll:1,documentElementScroll:1}),u={},f=null,l=Object.freeze({autoResize:!0,bodyBackground:null,bodyMargin:null,bodyMarginV1:8,bodyPadding:null,checkOrigin:!0,inPageLinks:!1,enablePublicMethods:!0,heightCalculationMethod:"bodyOffset",id:"iFrameResizer",interval:32,license:"1jqr0si6pnt",log:!1,maxHeight:1/0,maxWidth:1/0,minHeight:0,minWidth:0,mouseEvents:!0,resizeFrom:"parent",scrolling:!1,sizeHeight:!0,sizeWidth:!1,warningTimeout:5e3,tolerance:0,widthCalculationMethod:"scroll",onClose:function(){return!0},onClosed:function(){},onInit:function(){},onMessage:function(){k("onMessage function not defined")},onMouseEnter:function(){},onMouseLeave:function(){},onResized:function(){},onScroll:function(){return!0}}),h={};window.jQuery!==e&&((t=window.jQuery).fn?t.fn.iFrameResize||(t.fn.iFrameResize=function(e){return this.filter("iframe").each((function(n,t){E(t,e)})).end()}):v("","Unable to bind to jQuery, it is not fully loaded.")),y.exports=P(),window.iFrameResize=window.iFrameResize||P()}function m(){return window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver}function w(e,n,t){e.addEventListener(n,t,!1)}function g(e,n,t){e.removeEventListener(n,t,!1)}function b(e){return u[e]?u[e].log:o}function p(e,n){x("log",e,n,b(e))}function v(e,n){x("info",e,n,b(e))}function k(e,n){x("warn",e,n,!0)}function x(e,n,t,i){!0===i&&"object"==typeof window.console&&console[e](function(e){return a+"["+function(e){var n="Host page: "+e;return window.top!==window.self&&(n=window.parentIFrame&&window.parentIFrame.getId?window.parentIFrame.getId()+": "+e:"Nested host page: "+e),n}(e)+"]"}(n),t)}function z(e){function n(){t("Height"),t("Width"),N((function(){R(W),j(L),l("onResized",W)}),W,"init")}function t(e){var n=Number(u[L]["max"+e]),t=Number(u[L]["min"+e]),i=e.toLowerCase(),o=Number(W[i]);p(L,"Checking "+i+" is in range "+t+"-"+n),o<t&&(o=t,p(L,"Set "+i+" to min value")),o>n&&(o=n,p(L,"Set "+i+" to max value")),W[i]=""+o}function i(e){return E.slice(E.indexOf(":")+7+e)}function o(e,n){var t,i;t=function(){var t,i;A("Send Page Info","pageInfo:"+(t=document.body.getBoundingClientRect(),i=W.iframe.getBoundingClientRect(),JSON.stringify({iframeHeight:i.height,iframeWidth:i.width,clientHeight:Math.max(document.documentElement.clientHeight,window.innerHeight||0),clientWidth:Math.max(document.documentElement.clientWidth,window.innerWidth||0),offsetTop:parseInt(i.top-t.top,10),offsetLeft:parseInt(i.left-t.left,10),scrollTop:window.pageYOffset,scrollLeft:window.pageXOffset,documentHeight:document.documentElement.clientHeight,documentWidth:document.documentElement.clientWidth,windowHeight:window.innerHeight,windowWidth:window.innerWidth})),e,n)},h[i=n]||(h[i]=setTimeout((function(){h[i]=null,t()}),32))}function r(e){var n=e.getBoundingClientRect();return M(L),{x:Math.floor(Number(n.left)+Number(s.x)),y:Math.floor(Number(n.top)+Number(s.y))}}function c(e){var n=e?r(W.iframe):{x:0,y:0},t={x:Number(W.width)+n.x,y:Number(W.height)+n.y};p(L,"Reposition requested from iFrame (offset x:"+n.x+" y:"+n.y+")"),window.top===window.self?(s=t,d(),p(L,"--")):window.parentIFrame?window.parentIFrame["scrollTo"+(e?"Offset":"")](t.x,t.y):k(L,"Unable to scroll to requested position, window.parentIFrame not found")}function d(){!1===l("onScroll",s)?T():j(L)}function f(e){var n={};if(0===Number(W.width)&&0===Number(W.height)){var t=i(9).split(":");n={x:t[1],y:t[0]}}else n={x:W.width,y:W.height};l(e,{iframe:W.iframe,screenX:Number(n.x),screenY:Number(n.y),type:W.type})}function l(e,n){return I(L,e,n)}var m,b,y,x,z,F,E=e.data,W={},L=null;"[iFrameResizerChild]Ready"===E?function(){for(var e in u)A("iFrame requested init",C(e),u[e].iframe,e)}():a===(""+E).slice(0,13)&&E.slice(13).split(":")[0]in u?(x=(y=E.slice(13).split(":"))[1]?parseInt(y[1],10):0,z=u[y[0]]&&u[y[0]].iframe,F=getComputedStyle(z),W={iframe:z,id:y[0],height:x+function(e){return"border-box"!==e.boxSizing?0:(e.paddingTop?parseInt(e.paddingTop,10):0)+(e.paddingBottom?parseInt(e.paddingBottom,10):0)}(F)+function(e){return"border-box"!==e.boxSizing?0:(e.borderTopWidth?parseInt(e.borderTopWidth,10):0)+(e.borderBottomWidth?parseInt(e.borderBottomWidth,10):0)}(F),width:y[2],type:y[3]},u[L=W.id]&&(u[L].loaded=!0),(b=W.type in{true:1,false:1,undefined:1})&&p(L,"Ignoring init message from meta parent page"),!b&&function(e){var n=!0;return u[e]||(n=!1,k(W.type+" No settings for "+e+". Message was: "+E)),n}(L)&&(p(L,"Received: "+E),m=!0,null===W.iframe&&(k(L,"IFrame ("+W.id+") not found"),m=!1),m&&function(){var n,t=e.origin,i=u[L]&&u[L].checkOrigin;if(i&&""+t!="null"&&!(i.constructor===Array?function(){var e=0,n=!1;for(p(L,"Checking connection is from allowed list of origins: "+i);e<i.length;e++)if(i[e]===t){n=!0;break}return n}():(p(L,"Checking connection is from: "+(n=u[L]&&u[L].remoteHost)),t===n)))throw new Error("Unexpected message received from: "+t+" for "+W.iframe.id+". Message was: "+e.data+". This error can be disabled by setting the checkOrigin: false option or by providing of array of trusted domains.");return!0}()&&function(){switch(u[L]&&u[L].firstRun&&u[L]&&(u[L].firstRun=!1),W.type){case"close":S(W.iframe);break;case"message":m=i(6),p(L,"onMessage passed: {iframe: "+W.iframe.id+", message: "+m+"}"),l("onMessage",{iframe:W.iframe,message:JSON.parse(m)}),p(L,"--");break;case"mouseenter":f("onMouseEnter");break;case"mouseleave":f("onMouseLeave");break;case"autoResize":u[L].autoResize=JSON.parse(i(9));break;case"scrollTo":c(!1);break;case"scrollToOffset":c(!0);break;case"pageInfo":o(u[L]&&u[L].iframe,L),function(){function e(e,i){function r(){u[t]?o(u[t].iframe,t):n()}["scroll","resize"].forEach((function(n){p(t,e+n+" listener for sendPageInfo"),i(window,n,r)}))}function n(){e("Remove ",g)}var t=L;e("Add ",w),u[t]&&(u[t].stopPageInfo=n)}();break;case"pageInfoStop":u[L]&&u[L].stopPageInfo&&(u[L].stopPageInfo(),delete u[L].stopPageInfo);break;case"inPageLink":t=i(9).split("#")[1]||"",a=decodeURIComponent(t),(h=document.getElementById(a)||document.getElementsByName(a)[0])?(e=r(h),p(L,"Moving to in page link (#"+t+") at x: "+e.x+" y: "+e.y),s={x:e.x,y:e.y},d(),p(L,"--")):window.top===window.self?p(L,"In page link #"+t+" not found"):window.parentIFrame?window.parentIFrame.moveToAnchor(t):p(L,"In page link #"+t+" not found and window.parentIFrame not found");break;case"reset":O(W);break;case"init":n(),l("onInit",W.iframe);break;default:0===Number(W.width)&&0===Number(W.height)?k("Unsupported message received ("+W.type+"), this is likely due to the iframe containing a later version of iframe-resizer than the parent page"):n()}var e,t,a,h,m}())):v(L,"Ignored: "+E)}function I(e,n,t){var i=null,o=null;if(u[e]){if("function"!=typeof(i=u[e][n]))throw new TypeError(n+" on iFrame["+e+"] is not a function");o=i(t)}return o}function F(e){delete u[e.id]}function S(e){var t=e.id;if(!1!==I(t,"onClose",t)){p(t,"Removing iFrame: "+t);try{e.parentNode&&e.parentNode.removeChild(e)}catch(e){k(e)}I(t,"onClosed",t),p(t,"--"),F(e),n&&(n.disconnect(),n=null)}else p(t,"Close iframe cancelled by onClose event")}function M(n){null===s&&p(n,"Get page position: "+(s={x:window.pageXOffset===e?document.documentElement.scrollLeft:window.pageXOffset,y:window.pageYOffset===e?document.documentElement.scrollTop:window.pageYOffset}).x+","+s.y)}function j(e){null!==s&&(window.scrollTo(s.x,s.y),p(e,"Set page position: "+s.x+","+s.y),T())}function T(){s=null}function O(e){p(e.id,"Size reset requested by "+("init"===e.type?"host page":"iFrame")),M(e.id),N((function(){R(e),A("reset","reset",e.iframe,e.id)}),e,"reset")}function R(e){function n(n){r||"0"!==e[n]||(r=!0,p(i,"Hidden iFrame detected, creating visibility listener"),function(){function e(){Object.keys(u).forEach((function(e){!function(e){function n(n){return"0px"===(u[e]&&u[e].iframe.style[n])}u[e]&&null!==u[e].iframe.offsetParent&&(n("height")||n("width"))&&A("Visibility change","resize",u[e].iframe,e)}(e)}))}function n(n){p("window","Mutation observed: "+n[0].target+" "+n[0].type),W(e,16)}var t,i=m();i&&(t=document.querySelector("body"),new i(n).observe(t,{attributes:!0,attributeOldValue:!1,characterData:!0,characterDataOldValue:!1,childList:!0,subtree:!0}))}())}function t(t){!function(n){e.id?(e.iframe.style[n]=e[n]+"px",p(e.id,"IFrame ("+i+") "+n+" set to "+e[n]+"px")):p("undefined","messageData id not set")}(t),n(t)}var i=e.iframe.id;u[i]&&(u[i].sizeHeight&&t("height"),u[i].sizeWidth&&t("width"))}function N(e,n,t){t!==n.type&&c&&!window.jasmine?(p(n.id,"Requesting animation frame"),c(e)):e()}function A(e,n,t,i,o){var r,s=!1;u[i=i||t.id]&&(t&&"contentWindow"in t&&null!==t.contentWindow?(p(i,"["+e+"] Sending msg to iframe["+i+"] ("+n+") targetOrigin: "+(r=u[i]&&u[i].targetOrigin)),t.contentWindow.postMessage(a+n,r)):k(i,"["+e+"] IFrame("+i+") not found"),o&&u[i]&&u[i].warningTimeout&&(u[i].msgTimeout=setTimeout((function(){!u[i]||u[i].loaded||s||(s=!0,k(i,"IFrame has not responded within "+u[i].warningTimeout/1e3+" 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."))}),u[i].warningTimeout)))}function C(e){return e+":"+u[e].bodyMarginV1+":"+u[e].sizeWidth+":"+u[e].log+":"+u[e].interval+":"+u[e].enablePublicMethods+":"+u[e].autoResize+":"+u[e].bodyMargin+":"+u[e].heightCalculationMethod+":"+u[e].bodyBackground+":"+u[e].bodyPadding+":"+u[e].tolerance+":"+u[e].inPageLinks+":"+u[e].resizeFrom+":"+u[e].widthCalculationMethod+":"+u[e].mouseEvents}function E(t,r){function a(e){var n=e.split("Callback");if(2===n.length){var t="on"+n[0].charAt(0).toUpperCase()+n[0].slice(1);this[t]=this[e],delete this[e],k(f,"Deprecated: '"+e+"' has been renamed '"+t+"'. The old method will be removed in the next major version.")}}var s,c,f=function(e){if("string"!=typeof e)throw new TypeError("Invaild id for iFrame. Expected String");var n;return""===e&&(t.id=(n=r&&r.id||l.id+i++,null!==document.getElementById(n)&&(n+=i++),e=n),o=(r||{}).log,p(e,"Added missing iframe ID: "+e+" ("+t.src+")")),e}(t.id);f in u&&"iFrameResizer"in t?k(f,"Ignored iFrame, already setup."):(function(e){var n;e=e||{},u[f]=Object.create(null),u[f].iframe=t,u[f].firstRun=!0,u[f].remoteHost=t.src&&t.src.split("/").slice(0,3).join("/"),function(e){if("object"!=typeof e)throw new TypeError("Options is not an object")}(e),Object.keys(e).forEach(a,e),function(e){for(var n in l)Object.prototype.hasOwnProperty.call(l,n)&&(u[f][n]=Object.prototype.hasOwnProperty.call(e,n)?e[n]:l[n])}(e),u[f]&&(u[f].targetOrigin=!0===u[f].checkOrigin?""===(n=u[f].remoteHost)||null!==n.match(/^(about:blank|javascript:|file:\/\/)/)?"*":n:"*")}(r),function(){switch(p(f,"IFrame scrolling "+(u[f]&&u[f].scrolling?"enabled":"disabled")+" for "+f),t.style.overflow=!1===(u[f]&&u[f].scrolling)?"hidden":"auto",u[f]&&u[f].scrolling){case"omit":break;case!0:t.scrolling="yes";break;case!1:t.scrolling="no";break;default:t.scrolling=u[f]?u[f].scrolling:"no"}}(),function(){function e(e){var n=u[f][e];1/0!==n&&0!==n&&(t.style[e]="number"==typeof n?n+"px":n,p(f,"Set "+e+" = "+t.style[e]))}function n(e){if(u[f]["min"+e]>u[f]["max"+e])throw new Error("Value for min"+e+" can not be greater than max"+e)}n("Height"),n("Width"),e("maxHeight"),e("minHeight"),e("maxWidth"),e("minWidth")}(),"number"!=typeof(u[f]&&u[f].bodyMargin)&&"0"!==(u[f]&&u[f].bodyMargin)||(u[f].bodyMarginV1=u[f].bodyMargin,u[f].bodyMargin=u[f].bodyMargin+"px"),s=C(f),(c=m())&&(n=function(e){if(!t.parentNode)return null;var n=new e((function(e){e.forEach((function(e){Array.prototype.slice.call(e.removedNodes).forEach((function(e){e===t&&S(t)}))}))}));return n.observe(t.parentNode,{childList:!0}),n}(c)),w(t,"load",(function(){A("iFrame.onload",s,t,e,!0),(!u[f]||!u[f].firstRun)&&u[f]&&u[f].heightCalculationMethod in d&&O({iframe:t,height:0,width:0,type:"init"})})),A("init",s,t,e,!0),u[f]&&(u[f].iframe.iFrameResizer={close:S.bind(null,u[f].iframe),removeListeners:F.bind(null,u[f].iframe),resize:A.bind(null,"Window resize","resize",u[f].iframe),moveToAnchor:function(e){A("Move to anchor","moveToAnchor:"+e,u[f].iframe,f)},sendMessage:function(e){A("Send Message","message:"+(e=JSON.stringify(e)),u[f].iframe,f)}}))}function W(e,n){null===f&&(f=setTimeout((function(){f=null,e()}),n))}function L(){"hidden"!==document.visibilityState&&(p("document","Trigger event: Visibility change"),W((function(){H("Tab Visible","resize")}),16))}function H(e,n){Object.keys(u).forEach((function(t){(function(e){return u[e]&&"parent"===u[e].resizeFrom&&u[e].autoResize&&!u[e].firstRun})(t)&&A(e,n,u[t].iframe,t)}))}function P(){function n(e,n){n&&(function(){if(!n.tagName)throw new TypeError("Object is not a valid DOM element");if("IFRAME"!==n.tagName.toUpperCase())throw new TypeError("Expected <IFRAME> tag, found <"+n.tagName+">")}(),E(n,e),t.push(n))}var t;return function(){var e,n=["moz","webkit","o","ms"];for(e=0;e<n.length&&!c;e+=1)c=window[n[e]+"RequestAnimationFrame"];c?c=c.bind(window):p("setup","RequestAnimationFrame not supported")}(),w(window,"message",z),w(window,"resize",(function(){p("window","Trigger event: resize"),W((function(){H("Window resize","resize")}),16)})),w(document,"visibilitychange",L),w(document,"-webkit-visibilitychange",L),function(i,o){switch(t=[],function(e){e&&e.enablePublicMethods&&k("enablePublicMethods option has been removed, public methods are now always available in the iFrame")}(i),typeof o){case"undefined":case"string":Array.prototype.forEach.call(document.querySelectorAll(o||"iframe"),n.bind(e,i));break;case"object":n(i,o);break;default:throw new TypeError("Unexpected data type ("+typeof o+")")}return t}}}()),v.exports));class x{constructor(e,n){this.iframe=e,this.iframeOrigin=n}postMessage(e,n){const t=Object.assign({eventType:e},n);this.iframe.contentWindow.postMessage(t,this.iframeOrigin)}addMessageListener(e){window.addEventListener("message",e)}removeMessageListener(e){window.removeEventListener("message",e)}postMessageWithResponseListener(e,n){return new Promise((t=>{const i=n=>{n.data.eventType===e&&(window.removeEventListener("message",i),t(n.data.data))};window.addEventListener("message",i),this.postMessage(e,n)}))}}const z=class{constructor(n){e(this,n),this.iframeLoaded=i(this,"iframeLoaded"),this.isFocused=!1,this.isValid=!0,this.dispatchMessageEvent=e=>{const{eventType:n,data:t}=e.data;(null==t?void 0:t.id)===this.inputId&&("focused"===n&&(this.isFocused=!0),"blurred"===n&&(this.isFocused=!1))}}disconnectedCallback(){this.frameService.removeMessageListener(this.dispatchMessageEvent)}async validate(){const e=await this.frameService.postMessageWithResponseListener("validate");return this.isValid=e.isValid,this.errorText=e.error.message,e}async tokenize(e,n,t){return this.frameService.postMessageWithResponseListener("tokenize",{clientId:e,paymentMethodMetadata:n,account:t,componentVersion:h.version})}initializeFrameCommunicationService(){var e;this.frameService=new x(this.iframeElement,this.iframeOrigin),null===(e=this.frameService)||void 0===e||e.addMessageListener(this.dispatchMessageEvent)}get part(){return this.isFocused&&!this.isValid?a:this.isValid?this.isFocused?c:d:s}get style(){return this.isFocused?this.isValid?w.focused:w.focusedAndInvalid:null}get urlParams(){const e=Object.fromEntries(Object.entries(w.fontStyles).map((([e,n])=>[e,btoa(String(n))])));return new URLSearchParams(e).toString()}render(){return n(t,{key:"ecddfb4d179827cff3373a379a34da18fa1a09e5",class:"form-group d-flex flex-column"},n("div",{key:"b19d2290c3a67433a58f0156bdd88f3eb0dd015f",style:{visibility:this.iframeLoaded?"visible":"hidden",height:this.iframeLoaded?"auto":"0"}},n("label",{key:"30a49b71d2e590fde1c14294078c38dc424e26b8",class:"form-label",htmlFor:"",part:u},this.label||""),n("div",{key:"d485f9ce44de38330a611ccbd6d4569dad8e3790",class:"p-0 d-flex form-control "+(this.isValid?"":"is-invalid"),part:this.part,style:Object.assign(Object.assign({},this.style),{overflow:"hidden"})},n("iframe",{key:"92607fa74dc6564b53616c2985e42cd605719ca4",id:this.inputId,name:this.inputId,src:`${this.iframeOrigin}?${this.urlParams}`,ref:e=>{this.iframeElement=e,this.initializeFrameCommunicationService()},width:"100%",onLoad:()=>{k({log:!1,onResized:()=>{this.iframeLoaded.emit()}},this.iframeElement)}})),n(l,{key:"c94856c9b819ad651a69b93f0fea1443003b9054",errorText:this.errorText,name:this.inputId})))}get el(){return o(this)}};export{b as hidden_input,z as iframe_input}
@@ -1 +1 @@
1
- import{d as t}from"./p-B5rtFhtR.js";const b=(t,b)=>{t.setValues(Object.assign(Object.assign({},t.values.getValue()),b))},e=(t,e)=>{b(t,{address:Object.assign(Object.assign({},t.values.getValue().address),e)})},o=(e,o)=>{const s=t(e.detail);b(o,Object.assign(Object.assign({},o.values.getValue()),{dob_day:s.dob_day,dob_month:s.dob_month,dob_year:s.dob_year}))};export{e as a,o as b,b as u}
1
+ import{d as t}from"./p-Dt-vy9Le.js";const b=(t,b)=>{t.setValues(Object.assign(Object.assign({},t.values.getValue()),b))},e=(t,e)=>{b(t,{address:Object.assign(Object.assign({},t.values.getValue().address),e)})},o=(e,o)=>{const s=t(e.detail);b(o,Object.assign(Object.assign({},o.values.getValue()),{dob_day:s.dob_day,dob_month:s.dob_month,dob_year:s.dob_year}))};export{e as a,o as b,b as u}