@adyen/adyen-platform-experience-web 1.7.0 → 1.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (772) hide show
  1. package/dist/adyen-platform-experience-web.css +1 -1
  2. package/dist/{angle-right-BYzD_-Ft.cjs → angle-right-DYQ6toZV.cjs} +2 -2
  3. package/dist/{angle-right-BYzD_-Ft.cjs.map → angle-right-DYQ6toZV.cjs.map} +1 -1
  4. package/dist/{checkmark-BvN7Hdc4.cjs → checkmark-BvHe3XDD.cjs} +2 -2
  5. package/dist/{checkmark-BvN7Hdc4.cjs.map → checkmark-BvHe3XDD.cjs.map} +1 -1
  6. package/dist/{checkmark-circle-fill-B2FBCXMi.cjs → checkmark-circle-fill-BBm-SExF.cjs} +2 -2
  7. package/dist/{checkmark-circle-fill-B2FBCXMi.cjs.map → checkmark-circle-fill-BBm-SExF.cjs.map} +1 -1
  8. package/dist/{checkmark-square-fill-C0yzqh08.cjs → checkmark-square-fill-GaJYfE7I.cjs} +2 -2
  9. package/dist/{checkmark-square-fill-C0yzqh08.cjs.map → checkmark-square-fill-GaJYfE7I.cjs.map} +1 -1
  10. package/dist/{chevron-down-Bh5iG-g7.cjs → chevron-down-DiKqNmGu.cjs} +2 -2
  11. package/dist/{chevron-down-Bh5iG-g7.cjs.map → chevron-down-DiKqNmGu.cjs.map} +1 -1
  12. package/dist/{chevron-left-CslKDyxG.cjs → chevron-left-D2wsIWaC.cjs} +2 -2
  13. package/dist/{chevron-left-CslKDyxG.cjs.map → chevron-left-D2wsIWaC.cjs.map} +1 -1
  14. package/dist/{chevron-right-B86-08tq.cjs → chevron-right-ClwwBk5G.cjs} +2 -2
  15. package/dist/{chevron-right-B86-08tq.cjs.map → chevron-right-ClwwBk5G.cjs.map} +1 -1
  16. package/dist/{chevron-up-DRKXzgCM.cjs → chevron-up-CjIuhiba.cjs} +2 -2
  17. package/dist/{chevron-up-DRKXzgCM.cjs.map → chevron-up-CjIuhiba.cjs.map} +1 -1
  18. package/dist/cjs/index.js +1 -1
  19. package/dist/{copy--wgagwiQ.cjs → copy-DWaCTvhj.cjs} +2 -2
  20. package/dist/{copy--wgagwiQ.cjs.map → copy-DWaCTvhj.cjs.map} +1 -1
  21. package/dist/{cross-BWhI1OkU.cjs → cross-BaBGJ7V7.cjs} +2 -2
  22. package/dist/{cross-BWhI1OkU.cjs.map → cross-BaBGJ7V7.cjs.map} +1 -1
  23. package/dist/{cross-circle-fill-CNa1fp55.cjs → cross-circle-fill-D1r6vt_G.cjs} +2 -2
  24. package/dist/{cross-circle-fill-CNa1fp55.cjs.map → cross-circle-fill-D1r6vt_G.cjs.map} +1 -1
  25. package/dist/{download-v3aQcc7_.cjs → download-BwlYYru1.cjs} +2 -2
  26. package/dist/{download-v3aQcc7_.cjs.map → download-BwlYYru1.cjs.map} +1 -1
  27. package/dist/es/assets/translations/en-US.json.js +848 -0
  28. package/dist/es/components/external/CapitalOffer/components/CapitalOffer/CapitalOffer.js +30 -30
  29. package/dist/es/components/external/CapitalOffer/components/CapitalOfferLegalNotice/CapitalOfferLegalNotice.js +12 -12
  30. package/dist/es/components/external/CapitalOffer/components/CapitalOfferSelection/CapitalOfferSelection.js +70 -67
  31. package/dist/es/components/external/CapitalOffer/components/CapitalOfferSummary/CapitalOfferSummary.js +134 -126
  32. package/dist/es/components/external/CapitalOffer/components/utils/CapitalErrorMessageDisplay.js +11 -11
  33. package/dist/es/components/external/CapitalOverview/CapitalOverviewElement.js +11 -11
  34. package/dist/es/components/external/CapitalOverview/components/AccountDetails/AccountDetail.js +36 -16
  35. package/dist/es/components/external/CapitalOverview/components/AccountDetails/AccountDetails.js +20 -18
  36. package/dist/es/components/external/CapitalOverview/components/AccountDetails/utils.js +48 -17
  37. package/dist/es/components/external/CapitalOverview/components/CapitalOverview/CapitalOverview.js +27 -27
  38. package/dist/es/components/external/CapitalOverview/components/GrantActions/GrantActions.js +77 -73
  39. package/dist/es/components/external/CapitalOverview/components/GrantAdjustmentDetails/GrantAdjustmentDetails.js +13 -13
  40. package/dist/es/components/external/CapitalOverview/components/GrantDetails/GrantDetails.js +53 -47
  41. package/dist/es/components/external/CapitalOverview/components/GrantItem/GrantItem.js +112 -73
  42. package/dist/es/components/external/CapitalOverview/components/GrantItem/utils.js +33 -33
  43. package/dist/es/components/external/CapitalOverview/components/GrantList/GrantsDisplay.js +20 -19
  44. package/dist/es/components/external/CapitalOverview/components/GrantRepaymentDetails/GrantRepaymentDetails.js +59 -43
  45. package/dist/es/components/external/CapitalOverview/components/PreQualifiedIntro.js +18 -18
  46. package/dist/es/components/external/CapitalOverview/components/Unqualified.js +8 -9
  47. package/dist/es/components/external/DisputeManagement/DisputeManagementElement.js +5 -5
  48. package/dist/es/components/external/DisputeManagement/components/AcceptDisputeFlow/AcceptDisputeFlow.js +57 -56
  49. package/dist/es/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeFileUpload.js +116 -115
  50. package/dist/es/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeFlow.js +15 -14
  51. package/dist/es/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeReason.js +82 -69
  52. package/dist/es/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeResponse.js +27 -27
  53. package/dist/es/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDocumentUpload.js +26 -26
  54. package/dist/es/components/external/DisputeManagement/components/DefendDisputeFlow/SelectAndUploadOptionalDoc.js +72 -67
  55. package/dist/es/components/external/DisputeManagement/components/DisputeDetails/DisputeDetails.js +28 -22
  56. package/dist/es/components/external/DisputeManagement/components/DisputesData/DisputeData.js +127 -112
  57. package/dist/es/components/external/DisputeManagement/components/DisputesData/DisputeDataProperties.js +152 -117
  58. package/dist/es/components/external/DisputeManagement/components/DisputesData/DisputeIssuerComments.js +14 -12
  59. package/dist/es/components/external/DisputeManagement/context/dispute/context.js +80 -61
  60. package/dist/es/components/external/DisputeManagement/utils/index.js +15 -17
  61. package/dist/es/components/external/DisputesOverview/DisputesOverviewElement.js +10 -17
  62. package/dist/es/components/external/DisputesOverview/components/DisputeManagementModal/DisputeManagementModal.js +23 -24
  63. package/dist/es/components/external/DisputesOverview/components/DisputesContainer/DisputesContainer.js +7 -7
  64. package/dist/es/components/external/DisputesOverview/components/DisputesOverview/DisputesOverview.js +199 -165
  65. package/dist/es/components/external/DisputesOverview/components/DisputesTable/DisputeStatusTag.js +8 -8
  66. package/dist/es/components/external/DisputesOverview/components/DisputesTable/DisputesTable.js +157 -117
  67. package/dist/es/components/external/PayoutDetails/PayoutDetails.js +5 -5
  68. package/dist/es/components/external/PayoutDetails/components/PayoutData.js +138 -122
  69. package/dist/es/components/external/PayoutsOverview/PayoutsOverviewElement.js +10 -17
  70. package/dist/es/components/external/PayoutsOverview/components/PayoutsOverview/PayoutsOverview.js +67 -66
  71. package/dist/es/components/external/PayoutsOverview/components/PayoutsOverviewContainer/PayoutsOverviewContainer.js +10 -10
  72. package/dist/es/components/external/PayoutsOverview/components/PayoutsTable/PayoutsTable.js +81 -61
  73. package/dist/es/components/external/ReportsOverview/ReportsOverviewElement.js +11 -20
  74. package/dist/es/components/external/ReportsOverview/components/ReportsOverview/ReportsOverview.js +31 -31
  75. package/dist/es/components/external/ReportsOverview/components/ReportsOverviewContainer/ReportsOverviewContainer.js +9 -9
  76. package/dist/es/components/external/ReportsOverview/components/ReportsTable/ReportsTable.js +82 -68
  77. package/dist/es/components/external/TransactionDetails/TransactionDetails.js +7 -14
  78. package/dist/es/components/external/TransactionDetails/components/TransactionData/TransactionDataContent.js +82 -81
  79. package/dist/es/components/external/TransactionDetails/components/TransactionData/TransactionStatusTag.js +18 -17
  80. package/dist/es/components/external/TransactionDetails/components/details/TransactionDataProperties.js +84 -57
  81. package/dist/es/components/external/TransactionDetails/components/refund/TransactionRefundAmount.js +31 -31
  82. package/dist/es/components/external/TransactionDetails/components/refund/TransactionRefundNotice.js +15 -14
  83. package/dist/es/components/external/TransactionDetails/components/refund/TransactionRefundReason.js +32 -26
  84. package/dist/es/components/external/TransactionDetails/context/constants.js +9 -2
  85. package/dist/es/components/external/TransactionDetails/context/details/context.js +83 -70
  86. package/dist/es/components/external/TransactionDetails/context/refund/context.js +62 -57
  87. package/dist/es/components/external/TransactionDetails/context/refund/hooks/useRefundAction.js +44 -32
  88. package/dist/es/components/external/TransactionDetails/context/refund/hooks/useRefundContextActions.js +15 -15
  89. package/dist/es/components/external/TransactionDetails/hooks/useTransactionRefundMetadata/useTransactionRefundMetadata.js +86 -88
  90. package/dist/es/components/external/TransactionsOverview/TransactionsOverviewElement.js +11 -18
  91. package/dist/es/components/external/TransactionsOverview/components/BalanceItem/BalanceItem.js +31 -18
  92. package/dist/es/components/external/TransactionsOverview/components/Balances/Balances.js +70 -43
  93. package/dist/es/components/external/TransactionsOverview/components/MultiSelectionFilter/MultiSelectionFilter.js +14 -11
  94. package/dist/es/components/external/TransactionsOverview/components/SummaryItem/SummaryItem.js +25 -24
  95. package/dist/es/components/external/TransactionsOverview/components/SummaryItem/SummaryItemLabel.js +11 -11
  96. package/dist/es/components/external/TransactionsOverview/components/TransactionTotalItem/TransactionTotalItem.js +38 -28
  97. package/dist/es/components/external/TransactionsOverview/components/TransactionTotals/TotalsCard.js +74 -35
  98. package/dist/es/components/external/TransactionsOverview/components/TransactionTotals/TransactionTotals.js +63 -36
  99. package/dist/es/components/external/TransactionsOverview/components/TransactionsOverview/TransactionsOverview.js +234 -165
  100. package/dist/es/components/external/TransactionsOverview/components/TransactionsOverviewContainer/TransactionsOverviewContainer.js +6 -6
  101. package/dist/es/components/external/TransactionsOverview/components/TransactionsTable/PaymentMethodCell.js +11 -11
  102. package/dist/es/components/external/TransactionsOverview/components/TransactionsTable/TransactionsTable.js +95 -75
  103. package/dist/es/components/external/UIElement/UIElement.js +31 -28
  104. package/dist/es/components/internal/Accordion/Accordion.js +25 -26
  105. package/dist/es/components/internal/Alert/Alert.js +37 -24
  106. package/dist/es/components/internal/Button/DownloadButton/DownloadButton.js +40 -38
  107. package/dist/es/components/internal/Calendar/Calendar.js +15 -14
  108. package/dist/es/components/internal/Calendar/components/CalendarGrid/CalendarGrid.js +14 -14
  109. package/dist/es/components/internal/Calendar/hooks/useCalendarControlsRendering.js +18 -18
  110. package/dist/es/components/internal/CapitalHeader/helpers.js +27 -27
  111. package/dist/es/components/internal/CapitalSlider/CapitalSlider.js +46 -41
  112. package/dist/es/components/internal/Card/Card.js +40 -41
  113. package/dist/es/components/internal/CopyText/CopyText.js +66 -55
  114. package/dist/es/components/internal/DataGrid/DataGrid.js +35 -35
  115. package/dist/es/components/internal/DataGrid/components/InteractiveBody.js +39 -38
  116. package/dist/es/components/internal/DataGrid/components/TableBody.js +20 -22
  117. package/dist/es/components/internal/DataOverviewContainer/DataOverviewContainer.js +23 -23
  118. package/dist/es/components/internal/DataOverviewDetails/DataOverviewDetails.js +63 -54
  119. package/dist/es/components/internal/DataOverviewDetails/useDataOverviewDetailsTitle.js +13 -14
  120. package/dist/es/components/internal/DataOverviewDisplay/DataDetailsModal.js +17 -16
  121. package/dist/es/components/internal/DatePicker/DatePicker.js +40 -27
  122. package/dist/es/components/internal/DatePicker/components/TimeRangeSelector/TimeRangeSelector.js +12 -10
  123. package/dist/es/components/internal/DatePicker/components/TimeRangeSelector/useTimeRangeSelection.js +48 -48
  124. package/dist/es/components/internal/ErrorMessageDisplay/ErrorMessageDisplay.js +53 -49
  125. package/dist/es/components/internal/ExpandableCard/ExpandableCard.js +57 -59
  126. package/dist/es/components/internal/ExpandableCard/constants.js +6 -7
  127. package/dist/es/components/internal/FilterBar/FilterBar.js +50 -34
  128. package/dist/es/components/internal/FilterBar/filters/AmountFilter/AmountFilter.js +54 -46
  129. package/dist/es/components/internal/FilterBar/filters/AmountFilter/RangeSelection.js +47 -44
  130. package/dist/es/components/internal/FilterBar/filters/BaseFilter/BaseFilter.js +88 -86
  131. package/dist/es/components/internal/FilterBar/filters/DateFilter/DateFilter.js +31 -30
  132. package/dist/es/components/internal/FilterBar/filters/DateFilter/DateFilterCore.js +85 -81
  133. package/dist/es/components/internal/FormFields/FileInput/FileInput.js +30 -30
  134. package/dist/es/components/internal/FormFields/FileInput/components/Dropzone.js +12 -12
  135. package/dist/es/components/internal/FormFields/FileInput/components/UploadedFile.js +8 -8
  136. package/dist/es/components/internal/FormFields/Select/BalanceAccountSelector/BalanceAccountSelector.js +26 -25
  137. package/dist/es/components/internal/FormFields/Select/Select.js +146 -143
  138. package/dist/es/components/internal/FormFields/Select/components/SelectButton.js +57 -52
  139. package/dist/es/components/internal/FormFields/Select/components/SelectList.js +43 -42
  140. package/dist/es/components/internal/Header/Header.js +38 -20
  141. package/dist/es/components/internal/Modal/Modal.js +59 -49
  142. package/dist/es/components/internal/Modal/ModalContent/ModalContent.js +10 -15
  143. package/dist/es/components/internal/Pagination/Pagination.js +80 -55
  144. package/dist/es/components/internal/Pagination/hooks/usePagination.js +16 -16
  145. package/dist/es/components/internal/Popover/Popover.js +99 -95
  146. package/dist/es/components/internal/Popover/PopoverDismissButton/PopoverDismissButton.js +10 -10
  147. package/dist/es/components/internal/ProgressBar/ProgressBar.js +18 -18
  148. package/dist/es/components/internal/SegmentedControl/SegmentedControl.js +26 -21
  149. package/dist/es/components/internal/StatusBox/StatusBox.js +12 -12
  150. package/dist/es/components/internal/StatusBox/useStatusBox.js +8 -8
  151. package/dist/es/components/internal/StructuredList/StructuredList.js +26 -25
  152. package/dist/es/components/internal/Tabs/Tabs.js +25 -20
  153. package/dist/es/components/internal/Tooltip/Tooltip.js +34 -28
  154. package/dist/es/components/internal/Tooltip/useTooltipListeners.js +24 -20
  155. package/dist/es/components/internal/Typography/Typography.js +9 -9
  156. package/dist/es/components/utils/capital/getCapitalErrorMessage.js +32 -32
  157. package/dist/es/components/utils/disputes/constants.js +30 -30
  158. package/dist/es/components/utils/disputes/getDisputesErrorMessage.js +16 -16
  159. package/dist/es/components/utils/getCommonErrorCode.js +13 -10
  160. package/dist/es/components/utils/getErrorMessage.js +17 -17
  161. package/dist/es/components/utils/translation/factory.js +13 -0
  162. package/dist/es/components/utils/translation/getters.js +17 -0
  163. package/dist/es/config/translations/swapConfig.json.js +848 -0
  164. package/dist/es/core/Analytics/analytics/customTranslations.js +837 -0
  165. package/dist/es/core/Analytics/analytics/user-events.js +114 -0
  166. package/dist/es/core/Analytics/analytics/utils.js +16 -0
  167. package/dist/es/core/Assets/Assets.js +17 -0
  168. package/dist/es/core/ConfigContext/context.js +9 -9
  169. package/dist/es/core/ConfigContext/session/AuthSession.js +13 -7
  170. package/dist/es/core/ConfigContext/session/SetupContext.js +74 -40
  171. package/dist/es/core/ConfigContext/session/utils/sessionAwareComponentAvailability/helpers/componentAvailabilityErrors.js +14 -10
  172. package/dist/es/core/Context/CoreProvider.js +25 -18
  173. package/dist/es/core/Context/analytics/AnalyticsContext.js +17 -0
  174. package/dist/es/core/Context/analytics/AnalyticsProvider.js +12 -0
  175. package/dist/es/core/Context/analytics/useAnalyticsContext.js +11 -0
  176. package/dist/es/core/Http/http.js +29 -25
  177. package/dist/es/core/Http/utils.js +6 -6
  178. package/dist/es/core/Localization/Localization.js +115 -80
  179. package/dist/es/core/Localization/constants/localization.js +21 -9
  180. package/dist/es/core/Localization/localization-utils.js +13 -11
  181. package/dist/es/core/Localization/utils.js +20 -20
  182. package/dist/es/core/constants.js +11 -0
  183. package/dist/es/core/core.js +42 -24
  184. package/dist/es/core/utils.js +38 -12
  185. package/dist/es/hooks/element/useClickOutside.js +33 -36
  186. package/dist/es/hooks/element/useFocusTrap.js +7 -7
  187. package/dist/es/hooks/useAnalytics/useAnalytics.js +37 -0
  188. package/dist/es/hooks/useAnalytics/usePushAnalyticEvent.js +35 -0
  189. package/dist/es/hooks/useBalanceAccountSelection.js +32 -25
  190. package/dist/es/hooks/useCommitAction/useCommitAction.js +25 -17
  191. package/dist/es/hooks/useComponentHeadingElement.js +29 -0
  192. package/dist/es/hooks/useCustomColumnsData.js +18 -18
  193. package/dist/es/hooks/useDefaultOverviewFilterParams.js +8 -8
  194. package/dist/es/hooks/useReactiveState/useReactiveState.js +14 -14
  195. package/dist/es/hooks/useTabbedControl.js +37 -37
  196. package/dist/es/hooks/useTableColumns.js +19 -20
  197. package/dist/es/hooks/useUniqueId.js +7 -0
  198. package/dist/es/primitives/dom/tabbableRoot/tabbable.js +61 -48
  199. package/dist/es/translations/index.js +16 -16
  200. package/dist/{external-link-Y0ITwX_D.cjs → external-link-C2HjWZuO.cjs} +2 -2
  201. package/dist/{external-link-Y0ITwX_D.cjs.map → external-link-C2HjWZuO.cjs.map} +1 -1
  202. package/dist/{filter-B0jf9LNT.cjs → filter-BIRwG0Vl.cjs} +2 -2
  203. package/dist/{filter-B0jf9LNT.cjs.map → filter-BIRwG0Vl.cjs.map} +1 -1
  204. package/dist/index-COVW71Qe.cjs +12 -0
  205. package/dist/index-COVW71Qe.cjs.map +1 -0
  206. package/dist/{info-filled-DWI7yYIK.cjs → info-filled-vKjjns_Y.cjs} +2 -2
  207. package/dist/{info-filled-DWI7yYIK.cjs.map → info-filled-vKjjns_Y.cjs.map} +1 -1
  208. package/dist/{minus-circle-outline-TX4FRKCq.cjs → minus-circle-outline-eV-2HTVp.cjs} +2 -2
  209. package/dist/{minus-circle-outline-TX4FRKCq.cjs.map → minus-circle-outline-eV-2HTVp.cjs.map} +1 -1
  210. package/dist/{plus-WkQleJCL.cjs → plus-BBN-BevV.cjs} +2 -2
  211. package/dist/{plus-WkQleJCL.cjs.map → plus-BBN-BevV.cjs.map} +1 -1
  212. package/dist/{plus-circle-outline-BSbUWJEJ.cjs → plus-circle-outline-D9hOKkhU.cjs} +2 -2
  213. package/dist/{plus-circle-outline-BSbUWJEJ.cjs.map → plus-circle-outline-D9hOKkhU.cjs.map} +1 -1
  214. package/dist/{square-wBNy5hkk.cjs → square-CTh_Pt6M.cjs} +2 -2
  215. package/dist/{square-wBNy5hkk.cjs.map → square-CTh_Pt6M.cjs.map} +1 -1
  216. package/dist/{trash-can-BtOHiu0D.cjs → trash-can-DLq5jE_J.cjs} +2 -2
  217. package/dist/{trash-can-BtOHiu0D.cjs.map → trash-can-DLq5jE_J.cjs.map} +1 -1
  218. package/dist/types/components/external/CapitalOffer/components/CapitalOfferSelection/CapitalOfferSelection.d.ts.map +1 -1
  219. package/dist/types/components/external/CapitalOffer/components/CapitalOfferSummary/CapitalOfferSummary.d.ts +2 -2
  220. package/dist/types/components/external/CapitalOffer/components/CapitalOfferSummary/CapitalOfferSummary.d.ts.map +1 -1
  221. package/dist/types/components/external/CapitalOffer/components/utils/CapitalErrorMessageDisplay.d.ts +5 -5
  222. package/dist/types/components/external/CapitalOffer/components/utils/CapitalErrorMessageDisplay.d.ts.map +1 -1
  223. package/dist/types/components/external/CapitalOffer/components/utils/utils.d.ts.map +1 -1
  224. package/dist/types/components/external/CapitalOverview/CapitalOverviewElement.d.ts.map +1 -1
  225. package/dist/types/components/external/CapitalOverview/components/AccountDetails/AccountDetail.d.ts +2 -0
  226. package/dist/types/components/external/CapitalOverview/components/AccountDetails/AccountDetail.d.ts.map +1 -1
  227. package/dist/types/components/external/CapitalOverview/components/AccountDetails/AccountDetails.d.ts +1 -2
  228. package/dist/types/components/external/CapitalOverview/components/AccountDetails/AccountDetails.d.ts.map +1 -1
  229. package/dist/types/components/external/CapitalOverview/components/AccountDetails/types.d.ts +2 -1
  230. package/dist/types/components/external/CapitalOverview/components/AccountDetails/types.d.ts.map +1 -1
  231. package/dist/types/components/external/CapitalOverview/components/AccountDetails/utils.d.ts +2 -0
  232. package/dist/types/components/external/CapitalOverview/components/AccountDetails/utils.d.ts.map +1 -1
  233. package/dist/types/components/external/CapitalOverview/components/GrantActions/GrantActions.d.ts.map +1 -1
  234. package/dist/types/components/external/CapitalOverview/components/GrantActions/utils.d.ts.map +1 -1
  235. package/dist/types/components/external/CapitalOverview/components/GrantDetails/GrantDetails.d.ts.map +1 -1
  236. package/dist/types/components/external/CapitalOverview/components/GrantItem/GrantItem.d.ts.map +1 -1
  237. package/dist/types/components/external/CapitalOverview/components/GrantItem/utils.d.ts.map +1 -1
  238. package/dist/types/components/external/CapitalOverview/components/GrantList/GrantsDisplay.d.ts.map +1 -1
  239. package/dist/types/components/external/CapitalOverview/components/GrantRepaymentDetails/GrantRepaymentDetails.d.ts.map +1 -1
  240. package/dist/types/components/external/CapitalOverview/components/PreQualified/PreQualified.d.ts.map +1 -1
  241. package/dist/types/components/external/CapitalOverview/components/PreQualifiedIntro.d.ts +1 -1
  242. package/dist/types/components/external/CapitalOverview/components/PreQualifiedIntro.d.ts.map +1 -1
  243. package/dist/types/components/external/CapitalOverview/components/Unqualified.d.ts +1 -1
  244. package/dist/types/components/external/CapitalOverview/components/Unqualified.d.ts.map +1 -1
  245. package/dist/types/components/external/DisputeManagement/components/AcceptDisputeFlow/AcceptDisputeFlow.d.ts +1 -1
  246. package/dist/types/components/external/DisputeManagement/components/AcceptDisputeFlow/AcceptDisputeFlow.d.ts.map +1 -1
  247. package/dist/types/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeFileUpload.d.ts.map +1 -1
  248. package/dist/types/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeFlow.d.ts +1 -1
  249. package/dist/types/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeFlow.d.ts.map +1 -1
  250. package/dist/types/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeReason.d.ts.map +1 -1
  251. package/dist/types/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeResponse.d.ts +1 -1
  252. package/dist/types/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeResponse.d.ts.map +1 -1
  253. package/dist/types/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDocumentUpload.d.ts +1 -1
  254. package/dist/types/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDocumentUpload.d.ts.map +1 -1
  255. package/dist/types/components/external/DisputeManagement/components/DefendDisputeFlow/SelectAndUploadOptionalDoc.d.ts +3 -3
  256. package/dist/types/components/external/DisputeManagement/components/DefendDisputeFlow/SelectAndUploadOptionalDoc.d.ts.map +1 -1
  257. package/dist/types/components/external/DisputeManagement/components/DisputeDetails/DisputeDetails.d.ts +1 -1
  258. package/dist/types/components/external/DisputeManagement/components/DisputeDetails/DisputeDetails.d.ts.map +1 -1
  259. package/dist/types/components/external/DisputeManagement/components/DisputeDetailsContainer/DisputeDetailsContainer.d.ts.map +1 -1
  260. package/dist/types/components/external/DisputeManagement/components/DisputesData/DisputeData.d.ts +4 -4
  261. package/dist/types/components/external/DisputeManagement/components/DisputesData/DisputeData.d.ts.map +1 -1
  262. package/dist/types/components/external/DisputeManagement/components/DisputesData/DisputeDataProperties.d.ts +3 -1
  263. package/dist/types/components/external/DisputeManagement/components/DisputesData/DisputeDataProperties.d.ts.map +1 -1
  264. package/dist/types/components/external/DisputeManagement/components/DisputesData/DisputeIssuerComments.d.ts.map +1 -1
  265. package/dist/types/components/external/DisputeManagement/components/DisputesData/constants.d.ts +1 -1
  266. package/dist/types/components/external/DisputeManagement/context/dispute/context.d.ts +4 -0
  267. package/dist/types/components/external/DisputeManagement/context/dispute/context.d.ts.map +1 -1
  268. package/dist/types/components/external/DisputeManagement/types.d.ts +1 -1
  269. package/dist/types/components/external/DisputeManagement/utils/index.d.ts +7 -2
  270. package/dist/types/components/external/DisputeManagement/utils/index.d.ts.map +1 -1
  271. package/dist/types/components/external/DisputesOverview/DisputesOverviewElement.d.ts.map +1 -1
  272. package/dist/types/components/external/DisputesOverview/components/DisputeManagementModal/DisputeManagementModal.d.ts +0 -1
  273. package/dist/types/components/external/DisputesOverview/components/DisputeManagementModal/DisputeManagementModal.d.ts.map +1 -1
  274. package/dist/types/components/external/DisputesOverview/components/DisputesOverview/DisputesOverview.d.ts.map +1 -1
  275. package/dist/types/components/external/DisputesOverview/components/DisputesTable/DisputeStatusTag.d.ts.map +1 -1
  276. package/dist/types/components/external/DisputesOverview/components/DisputesTable/DisputesTable.d.ts +16 -16
  277. package/dist/types/components/external/DisputesOverview/components/DisputesTable/DisputesTable.d.ts.map +1 -1
  278. package/dist/types/components/external/PayoutDetails/components/PayoutData.d.ts +5 -42
  279. package/dist/types/components/external/PayoutDetails/components/PayoutData.d.ts.map +1 -1
  280. package/dist/types/components/external/PayoutsOverview/PayoutsOverviewElement.d.ts.map +1 -1
  281. package/dist/types/components/external/PayoutsOverview/components/PayoutsOverview/PayoutsOverview.d.ts.map +1 -1
  282. package/dist/types/components/external/PayoutsOverview/components/PayoutsTable/PayoutsTable.d.ts.map +1 -1
  283. package/dist/types/components/external/ReportsOverview/ReportsOverviewElement.d.ts.map +1 -1
  284. package/dist/types/components/external/ReportsOverview/components/ReportsOverview/ReportsOverview.d.ts.map +1 -1
  285. package/dist/types/components/external/ReportsOverview/components/ReportsTable/ReportsTable.d.ts.map +1 -1
  286. package/dist/types/components/external/TransactionDetails/TransactionDetails.d.ts.map +1 -1
  287. package/dist/types/components/external/TransactionDetails/components/TransactionData/TransactionData.d.ts.map +1 -1
  288. package/dist/types/components/external/TransactionDetails/components/TransactionData/TransactionDataContent.d.ts.map +1 -1
  289. package/dist/types/components/external/TransactionDetails/components/TransactionData/TransactionStatusTag.d.ts.map +1 -1
  290. package/dist/types/components/external/TransactionDetails/components/constants.d.ts +1 -1
  291. package/dist/types/components/external/TransactionDetails/components/details/TransactionDataProperties.d.ts.map +1 -1
  292. package/dist/types/components/external/TransactionDetails/components/details/TransactionDetailsDataContainer.d.ts +1 -1
  293. package/dist/types/components/external/TransactionDetails/components/details/TransactionDetailsDataContainer.d.ts.map +1 -1
  294. package/dist/types/components/external/TransactionDetails/components/refund/TransactionRefundAmount.d.ts.map +1 -1
  295. package/dist/types/components/external/TransactionDetails/components/refund/TransactionRefundNotice.d.ts.map +1 -1
  296. package/dist/types/components/external/TransactionDetails/components/refund/TransactionRefundReason.d.ts.map +1 -1
  297. package/dist/types/components/external/TransactionDetails/components/utils.d.ts.map +1 -1
  298. package/dist/types/components/external/TransactionDetails/context/constants.d.ts +7 -0
  299. package/dist/types/components/external/TransactionDetails/context/constants.d.ts.map +1 -1
  300. package/dist/types/components/external/TransactionDetails/context/details/context.d.ts.map +1 -1
  301. package/dist/types/components/external/TransactionDetails/context/refund/context.d.ts +1 -1
  302. package/dist/types/components/external/TransactionDetails/context/refund/context.d.ts.map +1 -1
  303. package/dist/types/components/external/TransactionDetails/context/refund/helpers.d.ts +1 -1
  304. package/dist/types/components/external/TransactionDetails/context/refund/helpers.d.ts.map +1 -1
  305. package/dist/types/components/external/TransactionDetails/context/refund/hooks/useRefundAction.d.ts +4 -2
  306. package/dist/types/components/external/TransactionDetails/context/refund/hooks/useRefundAction.d.ts.map +1 -1
  307. package/dist/types/components/external/TransactionDetails/context/refund/hooks/useRefundContextActions.d.ts.map +1 -1
  308. package/dist/types/components/external/TransactionDetails/context/refund/hooks/useRefundContextAmount.d.ts.map +1 -1
  309. package/dist/types/components/external/TransactionDetails/context/refund/hooks/useRefundContextLineItems.d.ts +9 -12
  310. package/dist/types/components/external/TransactionDetails/context/refund/hooks/useRefundContextLineItems.d.ts.map +1 -1
  311. package/dist/types/components/external/TransactionDetails/context/refund/hooks/useRefundContextReason.d.ts +2 -1
  312. package/dist/types/components/external/TransactionDetails/context/refund/hooks/useRefundContextReason.d.ts.map +1 -1
  313. package/dist/types/components/external/TransactionDetails/context/refund/types.d.ts +1 -0
  314. package/dist/types/components/external/TransactionDetails/context/refund/types.d.ts.map +1 -1
  315. package/dist/types/components/external/TransactionDetails/hooks/useTransaction/useTransaction.d.ts +12 -61
  316. package/dist/types/components/external/TransactionDetails/hooks/useTransaction/useTransaction.d.ts.map +1 -1
  317. package/dist/types/components/external/TransactionDetails/hooks/useTransactionRefundMetadata/helpers.d.ts +1 -1
  318. package/dist/types/components/external/TransactionDetails/hooks/useTransactionRefundMetadata/helpers.d.ts.map +1 -1
  319. package/dist/types/components/external/TransactionDetails/hooks/useTransactionRefundMetadata/useTransactionRefundMetadata.d.ts +1 -1
  320. package/dist/types/components/external/TransactionDetails/hooks/useTransactionRefundMetadata/useTransactionRefundMetadata.d.ts.map +1 -1
  321. package/dist/types/components/external/TransactionDetails/types.d.ts +1 -1
  322. package/dist/types/components/external/TransactionsOverview/TransactionsOverviewElement.d.ts.map +1 -1
  323. package/dist/types/components/external/TransactionsOverview/components/BalanceItem/BalanceItem.d.ts +1 -1
  324. package/dist/types/components/external/TransactionsOverview/components/BalanceItem/BalanceItem.d.ts.map +1 -1
  325. package/dist/types/components/external/TransactionsOverview/components/BalanceItem/types.d.ts +1 -0
  326. package/dist/types/components/external/TransactionsOverview/components/BalanceItem/types.d.ts.map +1 -1
  327. package/dist/types/components/external/TransactionsOverview/components/Balances/Balances.d.ts.map +1 -1
  328. package/dist/types/components/external/TransactionsOverview/components/Balances/types.d.ts +1 -0
  329. package/dist/types/components/external/TransactionsOverview/components/Balances/types.d.ts.map +1 -1
  330. package/dist/types/components/external/TransactionsOverview/components/MultiSelectionFilter/MultiSelectionFilter.d.ts +1 -5
  331. package/dist/types/components/external/TransactionsOverview/components/MultiSelectionFilter/MultiSelectionFilter.d.ts.map +1 -1
  332. package/dist/types/components/external/TransactionsOverview/components/MultiSelectionFilter/useMultiSelectionFilter/constants.d.ts +2 -5
  333. package/dist/types/components/external/TransactionsOverview/components/MultiSelectionFilter/useMultiSelectionFilter/constants.d.ts.map +1 -1
  334. package/dist/types/components/external/TransactionsOverview/components/MultiSelectionFilter/useMultiSelectionFilter/useMultiSelectionFilter.d.ts.map +1 -1
  335. package/dist/types/components/external/TransactionsOverview/components/MultiSelectionFilter/useMultiSelectionFilter/utils.d.ts +1 -1
  336. package/dist/types/components/external/TransactionsOverview/components/MultiSelectionFilter/useMultiSelectionFilter/utils.d.ts.map +1 -1
  337. package/dist/types/components/external/TransactionsOverview/components/SummaryItem/SummaryItem.d.ts.map +1 -1
  338. package/dist/types/components/external/TransactionsOverview/components/SummaryItem/SummaryItemLabel.d.ts +7 -7
  339. package/dist/types/components/external/TransactionsOverview/components/SummaryItem/types.d.ts +2 -0
  340. package/dist/types/components/external/TransactionsOverview/components/SummaryItem/types.d.ts.map +1 -1
  341. package/dist/types/components/external/TransactionsOverview/components/TransactionTotalItem/TransactionTotalItem.d.ts +1 -1
  342. package/dist/types/components/external/TransactionsOverview/components/TransactionTotalItem/TransactionTotalItem.d.ts.map +1 -1
  343. package/dist/types/components/external/TransactionsOverview/components/TransactionTotalItem/types.d.ts +2 -0
  344. package/dist/types/components/external/TransactionsOverview/components/TransactionTotalItem/types.d.ts.map +1 -1
  345. package/dist/types/components/external/TransactionsOverview/components/TransactionTotals/TotalsCard.d.ts +2 -2
  346. package/dist/types/components/external/TransactionsOverview/components/TransactionTotals/TotalsCard.d.ts.map +1 -1
  347. package/dist/types/components/external/TransactionsOverview/components/TransactionTotals/TransactionTotals.d.ts +1 -1
  348. package/dist/types/components/external/TransactionsOverview/components/TransactionTotals/TransactionTotals.d.ts.map +1 -1
  349. package/dist/types/components/external/TransactionsOverview/components/TransactionTotals/types.d.ts +4 -1
  350. package/dist/types/components/external/TransactionsOverview/components/TransactionTotals/types.d.ts.map +1 -1
  351. package/dist/types/components/external/TransactionsOverview/components/TransactionsOverview/TransactionsOverview.d.ts.map +1 -1
  352. package/dist/types/components/external/TransactionsOverview/components/TransactionsTable/PaymentMethodCell.d.ts +2 -2
  353. package/dist/types/components/external/TransactionsOverview/components/TransactionsTable/PaymentMethodCell.d.ts.map +1 -1
  354. package/dist/types/components/external/TransactionsOverview/components/TransactionsTable/TransactionsTable.d.ts.map +1 -1
  355. package/dist/types/components/external/TransactionsOverview/hooks/useMaxWidths.d.ts.map +1 -1
  356. package/dist/types/components/external/TransactionsOverview/hooks/useTransactionsOverviewMultiSelectionFilters.d.ts +5 -5
  357. package/dist/types/components/external/TransactionsOverview/hooks/useTransactionsOverviewMultiSelectionFilters.d.ts.map +1 -1
  358. package/dist/types/components/external/UIElement/UIElement.d.ts +8 -8
  359. package/dist/types/components/external/UIElement/UIElement.d.ts.map +1 -1
  360. package/dist/types/components/internal/Accordion/Accordion.d.ts.map +1 -1
  361. package/dist/types/components/internal/Alert/Alert.d.ts.map +1 -1
  362. package/dist/types/components/internal/Alert/AlertIcon.d.ts.map +1 -1
  363. package/dist/types/components/internal/Button/DownloadButton/DownloadButton.d.ts +2 -1
  364. package/dist/types/components/internal/Button/DownloadButton/DownloadButton.d.ts.map +1 -1
  365. package/dist/types/components/internal/Button/DownloadButton/useDownload.d.ts +59 -427
  366. package/dist/types/components/internal/Button/DownloadButton/useDownload.d.ts.map +1 -1
  367. package/dist/types/components/internal/Button/hooks/useButton.d.ts +11 -11
  368. package/dist/types/components/internal/Button/hooks/useButton.d.ts.map +1 -1
  369. package/dist/types/components/internal/Calendar/Calendar.d.ts.map +1 -1
  370. package/dist/types/components/internal/Calendar/calendar/constants.d.ts.map +1 -1
  371. package/dist/types/components/internal/Calendar/calendar/timeframe/common/utils.d.ts.map +1 -1
  372. package/dist/types/components/internal/Calendar/calendar/timeframe/frames/MonthFrame.d.ts +2 -24
  373. package/dist/types/components/internal/Calendar/calendar/timeframe/frames/MonthFrame.d.ts.map +1 -1
  374. package/dist/types/components/internal/Calendar/calendar/timeframe/frames/TimeFrame.d.ts +2 -21
  375. package/dist/types/components/internal/Calendar/calendar/timeframe/frames/TimeFrame.d.ts.map +1 -1
  376. package/dist/types/components/internal/Calendar/calendar/timeframe/frames/YearFrame.d.ts +2 -24
  377. package/dist/types/components/internal/Calendar/calendar/timeframe/frames/YearFrame.d.ts.map +1 -1
  378. package/dist/types/components/internal/Calendar/calendar/timerange/factory.d.ts.map +1 -1
  379. package/dist/types/components/internal/Calendar/calendar/timerange/presets/lastNDays.d.ts.map +1 -1
  380. package/dist/types/components/internal/Calendar/calendar/timerange/presets/shared/offsetMonth.d.ts.map +1 -1
  381. package/dist/types/components/internal/Calendar/calendar/timerange/presets/shared/offsetWeek.d.ts.map +1 -1
  382. package/dist/types/components/internal/Calendar/calendar/timerange/utils.d.ts +4 -15
  383. package/dist/types/components/internal/Calendar/calendar/timerange/utils.d.ts.map +1 -1
  384. package/dist/types/components/internal/Calendar/calendar/timeslice/index.d.ts.map +1 -1
  385. package/dist/types/components/internal/Calendar/calendar/utils.d.ts.map +1 -1
  386. package/dist/types/components/internal/Calendar/components/CalendarControls/CalendarControls.d.ts.map +1 -1
  387. package/dist/types/components/internal/Calendar/components/CalendarGrid/CalendarGridDate.d.ts +2 -2
  388. package/dist/types/components/internal/Calendar/components/CalendarGrid/CalendarGridDayOfWeek.d.ts.map +1 -1
  389. package/dist/types/components/internal/Calendar/components/CalendarGrid/types.d.ts +1 -0
  390. package/dist/types/components/internal/Calendar/components/CalendarGrid/types.d.ts.map +1 -1
  391. package/dist/types/components/internal/Calendar/components/CalendarGrid/utils.d.ts +2 -2
  392. package/dist/types/components/internal/Calendar/components/CalendarGrid/utils.d.ts.map +1 -1
  393. package/dist/types/components/internal/Calendar/hooks/useCalendar.d.ts.map +1 -1
  394. package/dist/types/components/internal/Calendar/hooks/useCalendarControlsRendering.d.ts +1 -1
  395. package/dist/types/components/internal/Calendar/hooks/useCalendarControlsRendering.d.ts.map +1 -1
  396. package/dist/types/components/internal/Calendar/hooks/useTimezone.d.ts +1 -1
  397. package/dist/types/components/internal/Calendar/hooks/useTimezone.d.ts.map +1 -1
  398. package/dist/types/components/internal/Calendar/types.d.ts +2 -1
  399. package/dist/types/components/internal/Calendar/types.d.ts.map +1 -1
  400. package/dist/types/components/internal/CapitalHeader/helpers.d.ts.map +1 -1
  401. package/dist/types/components/internal/CapitalSlider/CapitalSlider.d.ts.map +1 -1
  402. package/dist/types/components/internal/Card/Card.d.ts +1 -1
  403. package/dist/types/components/internal/Card/Card.d.ts.map +1 -1
  404. package/dist/types/components/internal/Card/types.d.ts +0 -1
  405. package/dist/types/components/internal/Card/types.d.ts.map +1 -1
  406. package/dist/types/components/internal/CopyText/CopyText.d.ts +7 -4
  407. package/dist/types/components/internal/CopyText/CopyText.d.ts.map +1 -1
  408. package/dist/types/components/internal/DataGrid/components/Icon.d.ts +2 -2
  409. package/dist/types/components/internal/DataGrid/components/Icon.d.ts.map +1 -1
  410. package/dist/types/components/internal/DataGrid/components/InteractiveBody.d.ts +1 -1
  411. package/dist/types/components/internal/DataGrid/components/InteractiveBody.d.ts.map +1 -1
  412. package/dist/types/components/internal/DataGrid/components/SkeletonBody.d.ts +1 -1
  413. package/dist/types/components/internal/DataGrid/components/SkeletonBody.d.ts.map +1 -1
  414. package/dist/types/components/internal/DataGrid/components/TableBody.d.ts +1 -1
  415. package/dist/types/components/internal/DataGrid/components/TableBody.d.ts.map +1 -1
  416. package/dist/types/components/internal/DataGrid/components/TableCells.d.ts +2 -2
  417. package/dist/types/components/internal/DataGrid/components/TableCells.d.ts.map +1 -1
  418. package/dist/types/components/internal/DataGrid/components/TableHeaderCell.d.ts +1 -1
  419. package/dist/types/components/internal/DataGrid/components/TableHeaderCell.d.ts.map +1 -1
  420. package/dist/types/components/internal/DataGrid/hooks/useInteractiveDataGrid.d.ts.map +1 -1
  421. package/dist/types/components/internal/DataGrid/utils/DataGridProvider.d.ts.map +1 -1
  422. package/dist/types/components/internal/DataOverviewDetails/DataOverviewDetails.d.ts.map +1 -1
  423. package/dist/types/components/internal/DataOverviewDetails/DataOverviewDetailsSkeleton.d.ts +1 -1
  424. package/dist/types/components/internal/DataOverviewDetails/DataOverviewDetailsSkeleton.d.ts.map +1 -1
  425. package/dist/types/components/internal/DataOverviewDetails/useDataOverviewDetailsTitle.d.ts +3 -3
  426. package/dist/types/components/internal/DataOverviewDetails/useDataOverviewDetailsTitle.d.ts.map +1 -1
  427. package/dist/types/components/internal/DataOverviewDisplay/DataDetailsModal.d.ts +2 -0
  428. package/dist/types/components/internal/DataOverviewDisplay/DataDetailsModal.d.ts.map +1 -1
  429. package/dist/types/components/internal/DataOverviewError/DataOverviewError.d.ts +1 -1
  430. package/dist/types/components/internal/DataOverviewError/DataOverviewError.d.ts.map +1 -1
  431. package/dist/types/components/internal/DatePicker/DatePicker.d.ts +1 -1
  432. package/dist/types/components/internal/DatePicker/DatePicker.d.ts.map +1 -1
  433. package/dist/types/components/internal/DatePicker/components/TimeRangeSelector/TimeRangeSelector.d.ts +4 -3
  434. package/dist/types/components/internal/DatePicker/components/TimeRangeSelector/TimeRangeSelector.d.ts.map +1 -1
  435. package/dist/types/components/internal/DatePicker/components/TimeRangeSelector/useTimeRangeSelection.d.ts +7 -7
  436. package/dist/types/components/internal/DatePicker/components/TimeRangeSelector/useTimeRangeSelection.d.ts.map +1 -1
  437. package/dist/types/components/internal/ErrorMessageDisplay/ErrorMessageDisplay.d.ts +2 -5
  438. package/dist/types/components/internal/ErrorMessageDisplay/ErrorMessageDisplay.d.ts.map +1 -1
  439. package/dist/types/components/internal/ExpandableCard/ExpandableCard.d.ts +2 -2
  440. package/dist/types/components/internal/ExpandableCard/ExpandableCard.d.ts.map +1 -1
  441. package/dist/types/components/internal/ExpandableCard/constants.d.ts +0 -1
  442. package/dist/types/components/internal/ExpandableCard/constants.d.ts.map +1 -1
  443. package/dist/types/components/internal/ExpandableCard/types.d.ts +8 -3
  444. package/dist/types/components/internal/ExpandableCard/types.d.ts.map +1 -1
  445. package/dist/types/components/internal/FilterBar/FilterBar.d.ts +2 -1
  446. package/dist/types/components/internal/FilterBar/FilterBar.d.ts.map +1 -1
  447. package/dist/types/components/internal/FilterBar/filters/AmountFilter/AmountFilter.d.ts.map +1 -1
  448. package/dist/types/components/internal/FilterBar/filters/AmountFilter/RangeSelection.d.ts.map +1 -1
  449. package/dist/types/components/internal/FilterBar/filters/BaseFilter/BaseFilter.d.ts +1 -1
  450. package/dist/types/components/internal/FilterBar/filters/BaseFilter/BaseFilter.d.ts.map +1 -1
  451. package/dist/types/components/internal/FilterBar/filters/BaseFilter/types.d.ts +4 -2
  452. package/dist/types/components/internal/FilterBar/filters/BaseFilter/types.d.ts.map +1 -1
  453. package/dist/types/components/internal/FilterBar/filters/DateFilter/DateFilter.d.ts +2 -7
  454. package/dist/types/components/internal/FilterBar/filters/DateFilter/DateFilter.d.ts.map +1 -1
  455. package/dist/types/components/internal/FilterBar/filters/DateFilter/DateFilterCore.d.ts +1 -1
  456. package/dist/types/components/internal/FilterBar/filters/DateFilter/DateFilterCore.d.ts.map +1 -1
  457. package/dist/types/components/internal/FilterBar/filters/DateFilter/types.d.ts +1 -0
  458. package/dist/types/components/internal/FilterBar/filters/DateFilter/types.d.ts.map +1 -1
  459. package/dist/types/components/internal/FilterBar/types.d.ts +4 -0
  460. package/dist/types/components/internal/FilterBar/types.d.ts.map +1 -1
  461. package/dist/types/components/internal/FormFields/Select/BalanceAccountSelector/BalanceAccountSelector.d.ts +1 -1
  462. package/dist/types/components/internal/FormFields/Select/BalanceAccountSelector/BalanceAccountSelector.d.ts.map +1 -1
  463. package/dist/types/components/internal/FormFields/Select/Select.d.ts +1 -1
  464. package/dist/types/components/internal/FormFields/Select/Select.d.ts.map +1 -1
  465. package/dist/types/components/internal/FormFields/Select/components/SelectButton.d.ts +1 -1
  466. package/dist/types/components/internal/FormFields/Select/components/SelectButton.d.ts.map +1 -1
  467. package/dist/types/components/internal/FormFields/Select/components/SelectList.d.ts +1 -1
  468. package/dist/types/components/internal/FormFields/Select/components/SelectList.d.ts.map +1 -1
  469. package/dist/types/components/internal/FormFields/Select/components/SelectListItem.d.ts +4 -13
  470. package/dist/types/components/internal/FormFields/Select/components/SelectListItem.d.ts.map +1 -1
  471. package/dist/types/components/internal/FormFields/Select/hooks/useSelect.d.ts +1 -1
  472. package/dist/types/components/internal/FormFields/Select/hooks/useSelect.d.ts.map +1 -1
  473. package/dist/types/components/internal/FormFields/Select/types.d.ts +7 -4
  474. package/dist/types/components/internal/FormFields/Select/types.d.ts.map +1 -1
  475. package/dist/types/components/internal/FormFields/index.d.ts +2 -10
  476. package/dist/types/components/internal/FormFields/index.d.ts.map +1 -1
  477. package/dist/types/components/internal/Header/Header.d.ts +3 -2
  478. package/dist/types/components/internal/Header/Header.d.ts.map +1 -1
  479. package/dist/types/components/internal/Icon/Icon.d.ts +0 -1
  480. package/dist/types/components/internal/Icon/Icon.d.ts.map +1 -1
  481. package/dist/types/components/internal/Image/Image.d.ts.map +1 -1
  482. package/dist/types/components/internal/InfoBox/InfoBox.d.ts.map +1 -1
  483. package/dist/types/components/internal/Modal/Modal.d.ts +1 -1
  484. package/dist/types/components/internal/Modal/Modal.d.ts.map +1 -1
  485. package/dist/types/components/internal/Modal/ModalContent/ModalContent.d.ts +0 -1
  486. package/dist/types/components/internal/Modal/ModalContent/ModalContent.d.ts.map +1 -1
  487. package/dist/types/components/internal/Pagination/Pagination.d.ts +1 -1
  488. package/dist/types/components/internal/Pagination/Pagination.d.ts.map +1 -1
  489. package/dist/types/components/internal/Pagination/hooks/useCursorPaginatedRecords.d.ts.map +1 -1
  490. package/dist/types/components/internal/Pagination/hooks/useCursorPagination.d.ts.map +1 -1
  491. package/dist/types/components/internal/Pagination/hooks/useOffsetPaginatedRecords.d.ts.map +1 -1
  492. package/dist/types/components/internal/Pagination/hooks/useOffsetPagination.d.ts.map +1 -1
  493. package/dist/types/components/internal/Pagination/hooks/usePageLimit.d.ts +1 -1
  494. package/dist/types/components/internal/Pagination/hooks/usePageLimit.d.ts.map +1 -1
  495. package/dist/types/components/internal/Pagination/hooks/usePaginatedRecords.d.ts.map +1 -1
  496. package/dist/types/components/internal/Pagination/hooks/usePaginatedRecordsFilters.d.ts.map +1 -1
  497. package/dist/types/components/internal/Pagination/hooks/usePagination.d.ts +1 -1
  498. package/dist/types/components/internal/Pagination/hooks/usePagination.d.ts.map +1 -1
  499. package/dist/types/components/internal/Pagination/types.d.ts +5 -1
  500. package/dist/types/components/internal/Pagination/types.d.ts.map +1 -1
  501. package/dist/types/components/internal/Pagination/utils.d.ts.map +1 -1
  502. package/dist/types/components/internal/Popover/Popover.d.ts +1 -1
  503. package/dist/types/components/internal/Popover/Popover.d.ts.map +1 -1
  504. package/dist/types/components/internal/Popover/types.d.ts +2 -1
  505. package/dist/types/components/internal/Popover/types.d.ts.map +1 -1
  506. package/dist/types/components/internal/ProgressBar/ProgressBar.d.ts.map +1 -1
  507. package/dist/types/components/internal/SegmentedControl/SegmentedControl.d.ts +2 -1
  508. package/dist/types/components/internal/SegmentedControl/SegmentedControl.d.ts.map +1 -1
  509. package/dist/types/components/internal/Slider/Slider.d.ts.map +1 -1
  510. package/dist/types/components/internal/Spinner/Spinner.d.ts.map +1 -1
  511. package/dist/types/components/internal/StatusBox/StatusBox.d.ts +1 -8
  512. package/dist/types/components/internal/StatusBox/StatusBox.d.ts.map +1 -1
  513. package/dist/types/components/internal/StatusBox/useStatusBox.d.ts +2 -1
  514. package/dist/types/components/internal/StatusBox/useStatusBox.d.ts.map +1 -1
  515. package/dist/types/components/internal/StatusBox/utils.d.ts.map +1 -1
  516. package/dist/types/components/internal/StructuredList/StructuredList.d.ts +2 -1
  517. package/dist/types/components/internal/StructuredList/StructuredList.d.ts.map +1 -1
  518. package/dist/types/components/internal/StructuredList/useStructuredListItem.d.ts +2 -2
  519. package/dist/types/components/internal/StructuredList/useStructuredListItem.d.ts.map +1 -1
  520. package/dist/types/components/internal/Tabs/Tabs.d.ts +2 -1
  521. package/dist/types/components/internal/Tabs/Tabs.d.ts.map +1 -1
  522. package/dist/types/components/internal/Tag/Tag.d.ts.map +1 -1
  523. package/dist/types/components/internal/Tooltip/Tooltip.d.ts +1 -1
  524. package/dist/types/components/internal/Tooltip/Tooltip.d.ts.map +1 -1
  525. package/dist/types/components/internal/Tooltip/types.d.ts +0 -2
  526. package/dist/types/components/internal/Tooltip/types.d.ts.map +1 -1
  527. package/dist/types/components/internal/Tooltip/useTooltipListeners.d.ts +3 -3
  528. package/dist/types/components/internal/Tooltip/useTooltipListeners.d.ts.map +1 -1
  529. package/dist/types/components/internal/Typography/Typography.d.ts +2 -1
  530. package/dist/types/components/internal/Typography/Typography.d.ts.map +1 -1
  531. package/dist/types/components/utils/capital/getCapitalErrorMessage.d.ts +4 -4
  532. package/dist/types/components/utils/capital/getCapitalErrorMessage.d.ts.map +1 -1
  533. package/dist/types/components/utils/customData/hasCustomField.d.ts +1 -1
  534. package/dist/types/components/utils/customData/hasCustomField.d.ts.map +1 -1
  535. package/dist/types/components/utils/customData/mergeRecords.d.ts.map +1 -1
  536. package/dist/types/components/utils/disputes/actionNeeded.d.ts +3 -3
  537. package/dist/types/components/utils/disputes/actionNeeded.d.ts.map +1 -1
  538. package/dist/types/components/utils/disputes/constants.d.ts +21 -21
  539. package/dist/types/components/utils/disputes/getDisputesErrorMessage.d.ts.map +1 -1
  540. package/dist/types/components/utils/getCommonErrorCode.d.ts +2 -2
  541. package/dist/types/components/utils/getCommonErrorCode.d.ts.map +1 -1
  542. package/dist/types/components/utils/getErrorMessage.d.ts.map +1 -1
  543. package/dist/types/components/utils/translation/factory.d.ts +17 -0
  544. package/dist/types/components/utils/translation/factory.d.ts.map +1 -0
  545. package/dist/types/components/utils/translation/getters.d.ts +11 -0
  546. package/dist/types/components/utils/translation/getters.d.ts.map +1 -0
  547. package/dist/types/core/Analytics/analytics/customTranslations.d.ts +4 -0
  548. package/dist/types/core/Analytics/analytics/customTranslations.d.ts.map +1 -0
  549. package/dist/types/core/Analytics/analytics/user-events.d.ts +122 -0
  550. package/dist/types/core/Analytics/analytics/user-events.d.ts.map +1 -0
  551. package/dist/types/core/Analytics/analytics/utils.d.ts +3 -0
  552. package/dist/types/core/Analytics/analytics/utils.d.ts.map +1 -0
  553. package/dist/types/core/Assets/Assets.d.ts +15 -0
  554. package/dist/types/core/Assets/Assets.d.ts.map +1 -0
  555. package/dist/types/core/ConfigContext/context.d.ts +412 -935
  556. package/dist/types/core/ConfigContext/context.d.ts.map +1 -1
  557. package/dist/types/core/ConfigContext/session/AuthSession.d.ts +811 -1855
  558. package/dist/types/core/ConfigContext/session/AuthSession.d.ts.map +1 -1
  559. package/dist/types/core/ConfigContext/session/AuthSessionSpecification.d.ts.map +1 -1
  560. package/dist/types/core/ConfigContext/session/SetupContext.d.ts +416 -935
  561. package/dist/types/core/ConfigContext/session/SetupContext.d.ts.map +1 -1
  562. package/dist/types/core/ConfigContext/session/utils/sessionAwareComponentAvailability/helpers/componentAvailabilityErrors.d.ts.map +1 -1
  563. package/dist/types/core/ConfigContext/session/utils/sessionAwareComponentAvailability/sessionAwareComponentAvailability.d.ts.map +1 -1
  564. package/dist/types/core/ConfigContext/session/utils/sessionReady.d.ts.map +1 -1
  565. package/dist/types/core/ConfigContext/types.d.ts.map +1 -1
  566. package/dist/types/core/Context/CoreContext.d.ts +1 -1
  567. package/dist/types/core/Context/CoreProvider.d.ts +1 -1
  568. package/dist/types/core/Context/CoreProvider.d.ts.map +1 -1
  569. package/dist/types/core/Context/analytics/AnalyticsContext.d.ts +3 -0
  570. package/dist/types/core/Context/analytics/AnalyticsContext.d.ts.map +1 -0
  571. package/dist/types/core/Context/analytics/AnalyticsProvider.d.ts +10 -0
  572. package/dist/types/core/Context/analytics/AnalyticsProvider.d.ts.map +1 -0
  573. package/dist/types/core/Context/analytics/useAnalyticsContext.d.ts +3 -0
  574. package/dist/types/core/Context/analytics/useAnalyticsContext.d.ts.map +1 -0
  575. package/dist/types/core/Context/types.d.ts +8 -0
  576. package/dist/types/core/Context/types.d.ts.map +1 -1
  577. package/dist/types/core/Context/useCoreContext.d.ts +1 -1
  578. package/dist/types/core/Http/http.d.ts.map +1 -1
  579. package/dist/types/core/Http/types.d.ts +2 -0
  580. package/dist/types/core/Http/types.d.ts.map +1 -1
  581. package/dist/types/core/Http/utils.d.ts +1 -1
  582. package/dist/types/core/Http/utils.d.ts.map +1 -1
  583. package/dist/types/core/Localization/Localization.d.ts +1 -1
  584. package/dist/types/core/Localization/Localization.d.ts.map +1 -1
  585. package/dist/types/core/Localization/amount/amount-util.d.ts +0 -28
  586. package/dist/types/core/Localization/amount/amount-util.d.ts.map +1 -1
  587. package/dist/types/core/Localization/constants/localization.d.ts +3 -3
  588. package/dist/types/core/Localization/constants/localization.d.ts.map +1 -1
  589. package/dist/types/core/Localization/datetime/restamper/utils.d.ts +4 -7
  590. package/dist/types/core/Localization/datetime/restamper/utils.d.ts.map +1 -1
  591. package/dist/types/core/Localization/localization-utils.d.ts +5 -16
  592. package/dist/types/core/Localization/localization-utils.d.ts.map +1 -1
  593. package/dist/types/core/Localization/types.d.ts +2 -0
  594. package/dist/types/core/Localization/types.d.ts.map +1 -1
  595. package/dist/types/core/Localization/utils.d.ts +5 -15
  596. package/dist/types/core/Localization/utils.d.ts.map +1 -1
  597. package/dist/types/core/constants.d.ts +9 -0
  598. package/dist/types/core/constants.d.ts.map +1 -0
  599. package/dist/types/core/core.d.ts +11 -20
  600. package/dist/types/core/core.d.ts.map +1 -1
  601. package/dist/types/core/types.d.ts +6 -1
  602. package/dist/types/core/types.d.ts.map +1 -1
  603. package/dist/types/core/utils.d.ts +15 -1
  604. package/dist/types/core/utils.d.ts.map +1 -1
  605. package/dist/types/hooks/element/useClickOutside.d.ts +1 -1
  606. package/dist/types/hooks/element/useClickOutside.d.ts.map +1 -1
  607. package/dist/types/hooks/element/useDetachedRender.d.ts.map +1 -1
  608. package/dist/types/hooks/element/useFocusCursor.d.ts.map +1 -1
  609. package/dist/types/hooks/element/useFocusTrap.d.ts +1 -1
  610. package/dist/types/hooks/element/useFocusTrap.d.ts.map +1 -1
  611. package/dist/types/hooks/element/usePopoverPositioner.d.ts.map +1 -1
  612. package/dist/types/hooks/element/useUniqueIdentifier.d.ts.map +1 -1
  613. package/dist/types/hooks/useAnalytics/useAnalytics.d.ts +13 -0
  614. package/dist/types/hooks/useAnalytics/useAnalytics.d.ts.map +1 -0
  615. package/dist/types/hooks/useAnalytics/usePushAnalyticEvent.d.ts +3 -0
  616. package/dist/types/hooks/useAnalytics/usePushAnalyticEvent.d.ts.map +1 -0
  617. package/dist/types/hooks/useBalanceAccountSelection.d.ts +1 -1
  618. package/dist/types/hooks/useBalanceAccountSelection.d.ts.map +1 -1
  619. package/dist/types/hooks/useBalanceAccounts.d.ts +1 -1
  620. package/dist/types/hooks/useBalanceAccounts.d.ts.map +1 -1
  621. package/dist/types/hooks/useBooleanState.d.ts.map +1 -1
  622. package/dist/types/hooks/useCommitAction/types.d.ts +1 -0
  623. package/dist/types/hooks/useCommitAction/types.d.ts.map +1 -1
  624. package/dist/types/hooks/useCommitAction/useCommitAction.d.ts +1 -1
  625. package/dist/types/hooks/useCommitAction/useCommitAction.d.ts.map +1 -1
  626. package/dist/types/hooks/useComponentHeadingElement.d.ts +14 -0
  627. package/dist/types/hooks/useComponentHeadingElement.d.ts.map +1 -0
  628. package/dist/types/hooks/useContainerQuery.d.ts +4 -4
  629. package/dist/types/hooks/useContainerQuery.d.ts.map +1 -1
  630. package/dist/types/hooks/useCustomColumnsData.d.ts +2 -2
  631. package/dist/types/hooks/useCustomColumnsData.d.ts.map +1 -1
  632. package/dist/types/hooks/useDefaultOverviewFilterParams.d.ts +10 -10
  633. package/dist/types/hooks/useDefaultOverviewFilterParams.d.ts.map +1 -1
  634. package/dist/types/hooks/useFreezePeriod.d.ts.map +1 -1
  635. package/dist/types/hooks/useImageUrl.d.ts.map +1 -1
  636. package/dist/types/hooks/useModalDetails/useModalDetails.d.ts.map +1 -1
  637. package/dist/types/hooks/useMounted.d.ts +1 -1
  638. package/dist/types/hooks/useMounted.d.ts.map +1 -1
  639. package/dist/types/hooks/useMutation/useMutation.d.ts.map +1 -1
  640. package/dist/types/hooks/useReactiveState/useReactiveState.d.ts.map +1 -1
  641. package/dist/types/hooks/useReflex.d.ts.map +1 -1
  642. package/dist/types/hooks/useTabbedControl.d.ts.map +1 -1
  643. package/dist/types/hooks/useTableColumns.d.ts +7 -7
  644. package/dist/types/hooks/useTableColumns.d.ts.map +1 -1
  645. package/dist/types/hooks/useTimezoneAwareDateFormatting.d.ts.map +1 -1
  646. package/dist/types/hooks/useTrackedRef.d.ts +1 -1
  647. package/dist/types/hooks/useTrackedRef.d.ts.map +1 -1
  648. package/dist/types/hooks/useUniqueId.d.ts +3 -0
  649. package/dist/types/hooks/useUniqueId.d.ts.map +1 -0
  650. package/dist/types/primitives/async/abortable/main.d.ts +1 -1
  651. package/dist/types/primitives/async/abortable/main.d.ts.map +1 -1
  652. package/dist/types/primitives/async/deferred/main.d.ts +2 -1
  653. package/dist/types/primitives/async/deferred/main.d.ts.map +1 -1
  654. package/dist/types/primitives/async/promisor/main.d.ts +1 -1
  655. package/dist/types/primitives/async/promisor/main.d.ts.map +1 -1
  656. package/dist/types/primitives/auxiliary/errorContainer/main.d.ts.map +1 -1
  657. package/dist/types/primitives/auxiliary/indexed/helpers.d.ts.map +1 -1
  658. package/dist/types/primitives/auxiliary/indexed/main.d.ts.map +1 -1
  659. package/dist/types/primitives/context/session/internal/autofresher.d.ts +2 -2
  660. package/dist/types/primitives/context/session/internal/autofresher.d.ts.map +1 -1
  661. package/dist/types/primitives/context/session/internal/deadline.d.ts +1 -1
  662. package/dist/types/primitives/context/session/internal/deadline.d.ts.map +1 -1
  663. package/dist/types/primitives/context/session/internal/refresher.d.ts +1 -1
  664. package/dist/types/primitives/context/session/internal/refresher.d.ts.map +1 -1
  665. package/dist/types/primitives/dom/tabbableRoot/tabbable.d.ts.map +1 -1
  666. package/dist/types/primitives/reactive/effectStack/main.d.ts.map +1 -1
  667. package/dist/types/primitives/reactive/eventEmitter/main.d.ts.map +1 -1
  668. package/dist/types/primitives/reactive/reflex/helpers.d.ts.map +1 -1
  669. package/dist/types/primitives/reactive/reflex/main.d.ts.map +1 -1
  670. package/dist/types/primitives/reactive/watchlist/helpers.d.ts.map +1 -1
  671. package/dist/types/primitives/reactive/watchlist/main.d.ts +1 -1
  672. package/dist/types/primitives/reactive/watchlist/main.d.ts.map +1 -1
  673. package/dist/types/primitives/time/interval/main.d.ts.map +1 -1
  674. package/dist/types/primitives/time/today/main.d.ts +1 -1
  675. package/dist/types/translations/index.d.ts +864 -804
  676. package/dist/types/translations/index.d.ts.map +1 -1
  677. package/dist/types/translations/local.d.ts +36 -0
  678. package/dist/types/translations/local.d.ts.map +1 -0
  679. package/dist/types/types/api/endpoints.d.ts +2 -1
  680. package/dist/types/types/api/endpoints.d.ts.map +1 -1
  681. package/dist/types/types/api/models/disputes.d.ts +1 -0
  682. package/dist/types/types/api/models/disputes.d.ts.map +1 -1
  683. package/dist/types/types/api/resources/CapitalGrantsResource.d.ts +10 -4
  684. package/dist/types/types/api/resources/CapitalGrantsResource.d.ts.map +1 -1
  685. package/dist/types/types/api/resources/PlatformComponentsUxdsResource.d.ts +112 -0
  686. package/dist/types/types/api/resources/PlatformComponentsUxdsResource.d.ts.map +1 -0
  687. package/dist/types/types/api/resources/SetupResource.d.ts +1 -1
  688. package/dist/types/types/api/resources/SetupResource.d.ts.map +1 -1
  689. package/dist/types/utils/abort/internals.d.ts.map +1 -1
  690. package/dist/types/utils/abort/main.d.ts +0 -4
  691. package/dist/types/utils/abort/main.d.ts.map +1 -1
  692. package/dist/types/utils/async/main.d.ts +1 -1
  693. package/dist/types/utils/async/main.d.ts.map +1 -1
  694. package/dist/types/utils/collection/main.d.ts +1 -1
  695. package/dist/types/utils/collection/main.d.ts.map +1 -1
  696. package/dist/types/utils/common.d.ts +2 -2
  697. package/dist/types/utils/common.d.ts.map +1 -1
  698. package/dist/types/utils/datetime/main.d.ts.map +1 -1
  699. package/dist/types/utils/file/read.d.ts.map +1 -1
  700. package/dist/types/utils/file/size.d.ts.map +1 -1
  701. package/dist/types/utils/file/upload.d.ts +1 -1
  702. package/dist/types/utils/file/upload.d.ts.map +1 -1
  703. package/dist/types/utils/preact/className.d.ts.map +1 -1
  704. package/dist/types/utils/preact/fixedForwardRef.d.ts +3 -3
  705. package/dist/types/utils/preact/fixedForwardRef.d.ts.map +1 -1
  706. package/dist/types/utils/preact/props.d.ts.map +1 -1
  707. package/dist/types/utils/struct/main.d.ts +1 -1
  708. package/dist/types/utils/struct/main.d.ts.map +1 -1
  709. package/dist/types/utils/struct/property.d.ts.map +1 -1
  710. package/dist/types/utils/value/bool.d.ts.map +1 -1
  711. package/dist/types/utils/value/compare.d.ts.map +1 -1
  712. package/dist/types/utils/value/constants.d.ts.map +1 -1
  713. package/dist/types/utils/value/is.d.ts +3 -3
  714. package/dist/types/utils/value/is.d.ts.map +1 -1
  715. package/dist/types/utils/value/number.d.ts.map +1 -1
  716. package/dist/types/utils/value/string.d.ts.map +1 -1
  717. package/dist/{upload-CwRQ9v3Y.cjs → upload-Cbt8Rwse.cjs} +2 -2
  718. package/dist/{upload-CwRQ9v3Y.cjs.map → upload-Cbt8Rwse.cjs.map} +1 -1
  719. package/dist/{warning-DBphva9h.cjs → warning-DB0fHdXY.cjs} +2 -2
  720. package/dist/{warning-DBphva9h.cjs.map → warning-DB0fHdXY.cjs.map} +1 -1
  721. package/dist/{warning-filled-Ctsg1oEC.cjs → warning-filled-B14QLF2h.cjs} +2 -2
  722. package/dist/{warning-filled-Ctsg1oEC.cjs.map → warning-filled-B14QLF2h.cjs.map} +1 -1
  723. package/package.json +13 -10
  724. package/dist/da-DK-DzyB6ApY.cjs +0 -2
  725. package/dist/da-DK-DzyB6ApY.cjs.map +0 -1
  726. package/dist/de-DE-C_manCYP.cjs +0 -2
  727. package/dist/de-DE-C_manCYP.cjs.map +0 -1
  728. package/dist/es/components/external/TransactionsOverview/components/Category/Category.js +0 -13
  729. package/dist/es/components/internal/DataOverviewDisplay/DataOverviewHeader/DataOverviewHeader.js +0 -19
  730. package/dist/es/components/utils/getLabel.js +0 -23
  731. package/dist/es/images/generic-use-first-touch.svg.js +0 -4
  732. package/dist/es/images/no-data-female.svg.js +0 -4
  733. package/dist/es/images/no-results.svg.js +0 -4
  734. package/dist/es/translations/da-DK.json.js +0 -905
  735. package/dist/es/translations/de-DE.json.js +0 -905
  736. package/dist/es/translations/en-US.json.js +0 -909
  737. package/dist/es/translations/es-ES.json.js +0 -905
  738. package/dist/es/translations/fi-FI.json.js +0 -905
  739. package/dist/es/translations/fr-FR.json.js +0 -905
  740. package/dist/es/translations/it-IT.json.js +0 -905
  741. package/dist/es/translations/nl-NL.json.js +0 -905
  742. package/dist/es/translations/no-NO.json.js +0 -905
  743. package/dist/es/translations/pt-BR.json.js +0 -905
  744. package/dist/es/translations/sv-SE.json.js +0 -905
  745. package/dist/es-ES-D4yWVVk4.cjs +0 -2
  746. package/dist/es-ES-D4yWVVk4.cjs.map +0 -1
  747. package/dist/fi-FI-ziHSaIAM.cjs +0 -2
  748. package/dist/fi-FI-ziHSaIAM.cjs.map +0 -1
  749. package/dist/fr-FR-B-twXuu4.cjs +0 -2
  750. package/dist/fr-FR-B-twXuu4.cjs.map +0 -1
  751. package/dist/index-CldOsFs0.cjs +0 -12
  752. package/dist/index-CldOsFs0.cjs.map +0 -1
  753. package/dist/it-IT-CNU9GJon.cjs +0 -2
  754. package/dist/it-IT-CNU9GJon.cjs.map +0 -1
  755. package/dist/nl-NL-CWr5RWqD.cjs +0 -2
  756. package/dist/nl-NL-CWr5RWqD.cjs.map +0 -1
  757. package/dist/no-NO-CU-dleiK.cjs +0 -2
  758. package/dist/no-NO-CU-dleiK.cjs.map +0 -1
  759. package/dist/pt-BR-DJUsdwmX.cjs +0 -2
  760. package/dist/pt-BR-DJUsdwmX.cjs.map +0 -1
  761. package/dist/sv-SE-Btn3_SAD.cjs +0 -2
  762. package/dist/sv-SE-Btn3_SAD.cjs.map +0 -1
  763. package/dist/types/components/external/TransactionsOverview/components/Category/Category.d.ts +0 -4
  764. package/dist/types/components/external/TransactionsOverview/components/Category/Category.d.ts.map +0 -1
  765. package/dist/types/components/external/TransactionsOverview/components/Category/types.d.ts +0 -6
  766. package/dist/types/components/external/TransactionsOverview/components/Category/types.d.ts.map +0 -1
  767. package/dist/types/components/internal/DataOverviewDisplay/DataOverviewHeader/DataOverviewHeader.d.ts +0 -13
  768. package/dist/types/components/internal/DataOverviewDisplay/DataOverviewHeader/DataOverviewHeader.d.ts.map +0 -1
  769. package/dist/types/components/internal/DataOverviewDisplay/DataOverviewHeader/index.d.ts +0 -3
  770. package/dist/types/components/internal/DataOverviewDisplay/DataOverviewHeader/index.d.ts.map +0 -1
  771. package/dist/types/components/utils/getLabel.d.ts +0 -23
  772. package/dist/types/components/utils/getLabel.d.ts.map +0 -1
@@ -1,12 +0,0 @@
1
- "use strict";var cf=Object.defineProperty;var cl=e=>{throw TypeError(e)};var lf=(e,t,n)=>t in e?cf(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var Y=(e,t,n)=>lf(e,typeof t!="symbol"?t+"":t,n),ia=(e,t,n)=>t.has(e)||cl("Cannot "+n);var m=(e,t,n)=>(ia(e,t,"read from private field"),n?n.call(e):t.get(e)),$=(e,t,n)=>t.has(e)?cl("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),k=(e,t,n,s)=>(ia(e,t,"write to private field"),s?s.call(e,n):t.set(e,n),n),K=(e,t,n)=>(ia(e,t,"access private method"),n);var Wn=(e,t,n,s)=>({set _(r){k(e,t,r,n)},get _(){return m(e,t,s)}});const M=require("classnames"),Sa="test",df=e=>{var t;return(t=e==null?void 0:e.replace)==null?void 0:t.call(e,/([^\/])$/,"$1/")},uf=e=>e==null?void 0:e.replace(/^([^\/])/,"/$1"),hf=(()=>{const e={test:"https://platform-components-external-test.adyen.com/platform-components-external/api/",live:"https://platform-components-external-live.adyen.com/platform-components-external/api/"};return t=>e[t??Sa]||e[Sa]})(),ls=Function.prototype.bind.bind(Function.prototype.call),pf=async()=>{},fo=e=>e,he=()=>{},ff=ls(Object.prototype.toString),mf=e=>ff(e).slice(8,-1),Gd=e=>(Object.keys(e).forEach(t=>{const n=e[t];n&&typeof n=="object"&&!Object.isFrozen(n)&&Gd(n)}),Object.freeze(e)),Ea=e=>e===!!e,ee=e=>typeof e=="function",Ko=e=>e===null,xe=e=>e==null,fr=e=>typeof e=="number",Ri=e=>mf(e)==="Object",Dt=e=>typeof e=="string",_f=e=>typeof e=="symbol",oe=e=>e===void 0,ll="abort",gf="signal is aborted without reason",As=(e,t=e)=>Ea(e)?e:!!t,Ve=e=>e===!0,en=e=>e!==!1,Tf=e=>!1,Na=e=>!0,X=(e,t=!1)=>({writable:Ve(t),enumerable:!0,value:e}),ve=(e,t=!0)=>({enumerable:en(t),get:e}),Zt=ls(Object.prototype.hasOwnProperty),ds=(e,t)=>e===t||!(e===e||t===t);if(!Zt(AbortSignal.prototype,"reason"))try{Object.defineProperty(AbortSignal.prototype,"reason",{...ve(function(){return this.aborted?xr():void 0},!0),configurable:!0})}catch{}Zt(AbortSignal.prototype,"throwIfAborted")||(AbortSignal.prototype.throwIfAborted=function(){if(this.aborted)throw this.reason??xr()});const xr=(e=gf)=>new DOMException(e,"AbortError"),Yd=(e,t)=>{if(!ds(e.reason,t))try{Object.defineProperty(e,"reason",X(t))}catch{}return e},yf=(e=xr())=>{if("abort"in AbortSignal)return AbortSignal.abort(e);const t=new AbortController,n=oe(e)?xr():e,{signal:s}=t;return t.abort(n),Yd(s,n),s},Ci=e=>{if("any"in AbortSignal)return AbortSignal.any(e);let t=new Set,n=new AbortController;const{signal:s}=n;let r=function(){t.forEach(o=>o.removeEventListener(ll,r)),t.clear();const a=(this==null?void 0:this.reason)??xr();n.abort(a),Yd(s,a),n=t=r=void 0};e:{const a=Symbol("<NIL_EXCEPTION>");let o=a;t:{try{for(const c of e){if(!mo(c))throw new TypeError("Failed to convert value to 'AbortSignal'");if(c.aborted)break t;t.add(c)}}catch(c){o=c;break t}t.forEach(c=>c.addEventListener(ll,r));break e}if(r.call(s),o!==a)throw o}return s},mo=e=>e instanceof AbortSignal,Se=Object.freeze([]),z=Object.freeze(Object.create(null)),ir=Promise.resolve();Promise.race(Se);const Ln=function(e,...t){return new Promise(n=>n(e.call(this,...t)))},Af=(e,t,n)=>{let s=t.get(e);return oe(s)&&ee(n)&&(oe(s=n(e,t))||t.set(e,s)),s},qn=(e,t=Se)=>{const n=`${e||""}`.trim(),s=n?n.split(/(?:\s*,\s*)+/).filter(fo):Se;return s.length?s:t},yr=(e,t,n)=>e.includes(t)?t:xe(t)?e[0]:e.includes(n)?n:e[0],dl=ls(Array.prototype.some),qd=function e(t,n,s=new Set){for(const r of n)Array.isArray(r)?e(t,r,s):(t&&s.delete(r),s.add(r));return s};ls(qd,void 0,!1);ls(qd,void 0,!0);const oc=(...e)=>{const[t]=e,s=(e.length>=2?new Date(...e):t instanceof Date?t:new Date(Dt(t)||Number.isFinite(t)?t:void 0)).getTime();return Number.isFinite(s)?s:void 0},Et=(e,t,n)=>(Math.min(e,n)!==e&&([e,n]=[n,e]),Math.max(e,Math.min(t,n))),Br=e=>!_f(e)&&e===~~e,ss=e=>fr(e)&&1/e===0,jd=(e,t)=>{if(Number.isInteger(e)&&Number.isInteger(t))return e+Math.floor((t-e)/2);throw TypeError(`Expects 2 integer values: [${e}, ${t}]`)},_o=(e,t)=>(e%t+t)%t,vf=3,Rf=e=>e<=1?0:Math.floor(Math.log(e)/Math.log(1024)),Cf=e=>{let t=0,n=Math.max(0,Math.round(e));return n>999&&(t=Et(1,Rf(n),vf),n=Math.round(Number((n/1024**t).toPrecision(3))*10)/10),{scale:t,size:n}},Vd=e=>{const{scale:t,size:n}=Cf(e);switch(t){case 0:return`${n} byte${n===1?"":"s"}`;case 1:return`${n} KB`;case 2:return`${n} MB`;case 3:return`${n} GB`}},Sf=e=>{const t=new Set;if(e!=null&&e.items)for(const n of e.items){if(n.kind!=="file")continue;const s=n.getAsFile();s&&t.add(s)}return Array.from(t.size===0?new Set((e==null?void 0:e.files)??t):t)},vn=(()=>{let e=Date.now();return(t="adyen-pe")=>`${t}-${++e}`})(),Si=(()=>{const e="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx";return()=>e.replace(/[xy]/g,t=>{const n=Math.random()*16|0;return(t=="x"?n:n&3|8).toString(16)})})(),$r=(e,t=z)=>Ri(e)?e:$r(t,z),mr=ls(Object.create,void 0),de=ls(mr,void 0,null),Ei=(e=z)=>Object.freeze({...e,defineProperty:Na,set:Na}),Ef=e=>e&&(e==null?void 0:e.length)>0?`${e[0].toUpperCase()}${e.slice(1)}`:e,Da=e=>xe(e)||Dt(e)&&/^\s*$/.test(e),Nf="/setup",Df=Ve(void 0),ul=(()=>{let e=0;if(Number.isFinite(e)&&(e=Math.max(0,~~e)))return e})();class ba extends Error{constructor(n,s,r,a){super(r);Y(this,"type");Y(this,"errorCode");Y(this,"requestId");this.type=n,this.name=n,this.errorCode=a,this.requestId=s}}const bf=/^[^]*?filename[^;\n]*=\s*(?:UTF-\d['"]*)?(?:(['"])([^]*?)\1|([^;\n]*))?[^]*?$/;var Ur=(e=>(e.HTTP_ERROR="HTTP_ERROR",e.NETWORK_ERROR="NETWORK_ERROR",e.CANCEL="CANCEL",e.IMPLEMENTATION_ERROR="IMPLEMENTATION_ERROR",e.ERROR="ERROR",e.EXPIRED_TOKEN="EXPIRED_TOKEN",e))(Ur||{});const Of=e=>{switch(e){case 401:return"EXPIRED_TOKEN";default:return"HTTP_ERROR"}},If=e=>{var t;return(t=e.headers.get("Content-Type"))==null?void 0:t.split(";",1)[0]},Pf=e=>{const n=(e.headers.get("Content-Disposition")??"").replace(bf,"$2$3");return decodeURIComponent(n)},kf=(e,t)=>{switch(t){case"application/json":return JSON.stringify(e);case"multipart/form-data":return e instanceof FormData?e:new FormData;default:return String(e)}},wf=e=>{var a;const{headers:t=[],method:n="GET"}=e,s="1.7.0",r=((a=e.contentType)==null?void 0:a.toLowerCase())??"application/json";return{method:n,mode:"cors",cache:"default",credentials:"same-origin",headers:{Accept:"application/json, text/plain, */*",...t,...r&&r!=="multipart/form-data"&&{"Content-Type":r},"SDK-Version":s},redirect:"follow",signal:e.signal,referrerPolicy:"no-referrer-when-downgrade",...n==="POST"&&e.body&&{body:kf(e.body,r)}}};function Lf({message:e,level:t,errorCode:n,type:s="NETWORK_ERROR",requestId:r}){switch(t){case"silent":break;case"info":case"warn":console[t](e);break;case"error":default:throw new ba(s,r,e,n)}}function Ff(e){return e&&e.errorCode&&e.type&&(e.detail||e.invalidFields)&&e.status}function Mf(e){const t=new URLSearchParams;for(const n of Object.keys(e)){const s=e[n];xe(s)||(Array.isArray(s)?s.forEach(r=>t.append(n,r)):t.set(n,String(s)))}return t}const zd=e=>{let t,n,s;const r=()=>{if(oe(t))return;const d=t.abort.bind(t);t=void 0,d()},a=()=>(s=new Promise((d,l)=>{if(n.addEventListener("abort",function h(){n.removeEventListener("abort",h),l(e)}),n.aborted)throw e}),s.catch(he),s),o=()=>(oe(t)&&(t=new AbortController,n=t.signal,s=a()),c),c=de({abort:X(r),promise:ve(()=>s),reason:X(e),refresh:X(o),signal:ve(()=>n)});return o()},Kd=()=>{let e,t,n;const s=()=>{const a=n??he,o=new Promise((c,d)=>{n=c,t=d});return a(e=o),r},r=de({promise:ve(()=>e),refresh:X(s),reject:X(a=>t(a)),resolve:X(a=>n(a))});return s()},go=e=>{const t=zd(),n=Kd();let s;return Object.defineProperties(function(...a){oe(s)?n.refresh():t.abort();const o=Ln.call(this,e,t.refresh().signal,...a);return(async()=>{let c=s===(s=o);try{const d=await o.finally(()=>{c=s===o,c&&(s=void 0)});c&&n.resolve(d)}catch(d){c&&n.reject(d)}})(),o},{abort:X(t.abort),promise:ve(()=>n.promise),refresh:X(()=>void n.refresh())})};class xf{constructor(t){Y(this,"_endpoints",z);Y(this,"_extraConfig",z);Y(this,"_revokeEndpointsProxy",he);Y(this,"_beforeHttp",async()=>{await this._refreshPromisor.promise.catch(he)});Y(this,"_refreshPromisor",go((t,n)=>{const s=mo(n)?Ci([n,t]):t;return this._fetchSetupEndpoint(s)}));this._session=t;let n;this.refresh=s=>(this._refreshPromisor(s).catch(he),n??(n=this._refreshPromisor.promise.finally(()=>n=void 0).then(({endpoints:r,...a})=>{this._resetEndpoints(),{proxy:this._endpoints,revoke:this._revokeEndpointsProxy}=this._getEndpointsProxy(r),this._extraConfig=Gd(a)})))}get endpoints(){return this._endpoints}get extraConfig(){return this._extraConfig}_fetchSetupEndpoint(t){return this._session.http(null,{method:"POST",path:Nf,errorLevel:"fatal",loadingContext:this.loadingContext,signal:t})}_getEndpointsProxy(t){const n=new Set(Object.keys(t)),s=de();return Proxy.revocable(z,Ei({get:(r,a,o)=>n.has(a)?(s[a]??(s[a]=(()=>{const{method:c="GET",url:d}=t[a];if(!oe(d||void 0))return(...l)=>{const h=this._getHttpOptions(c,d,...l);return this._session.http(this._beforeHttp,h)}})()),s[a]):Reflect.get(r,a,o)}))}_getHttpOptions(t,n,...s){const{loadingContext:r}=this,[a,o]=s,{path:c,query:d}=$r(o),l=d&&Mf(d);if(Ri(c))for(const h of Object.keys(c))n=n.replace(`{${h}}`,c[h]);return{loadingContext:r,...a,method:t,params:l,path:n}}_resetEndpoints(){this._revokeEndpointsProxy(),this._revokeEndpointsProxy=he,this._endpoints=z}}const Xd=Symbol("Error<SESSION_EXPIRED>"),Bf=Symbol("Error<SESSION_FACTORY_UNAVAILABLE>"),$f=Symbol("Error<SESSION_HTTP_UNAVAILABLE>"),Uf=Symbol("Error<SESSION_INVALID>"),Zd=Symbol("Error<SESSION_REFRESH_ABORTED>"),Ni="_sessionExpired",Qd="_sessionReady",Wf="_sessionRefreshed",Hf="_sessionRefreshingEnd",Gf="_sessionRefreshingStart",Jd="_session.deadline",eu="_session.ready",tu="_session.refreshingEnd",nu="_session.refreshingStart",Yf=async e=>{const{specification:t}=e.context,n=await Ln(async()=>{const s=t.autoRefresh;return ee(s)?s.call(t,e.session):s}).catch(Tf);return Ve(n)},qf=e=>{let t=e.context.emitter.on(Ni,()=>r(!1)),n,s=go(async(c,d=!1)=>{n=c;const l=Ve(d)||await Yf(e);n===c&&l&&e.pending&&!e.refreshing&&e.refresh(n).catch(he)}),r=(c=!1)=>{e.refreshing||s(c)},a=()=>{t(),s.abort(),s=n=t=void 0,r=a=he};return Object.defineProperties((c=!1)=>r(c),{destruct:ve(()=>a,!1)})},hl=1e3,jf=2147483647,Vf=(e,t=hl,n=!1)=>{var h;let s=new AbortController,r=Et(0,~~t,jf),a=Ve(n);Number.isFinite(r)||(r=hl);const o=((h=document.timeline)==null?void 0:h.currentTime)??performance.now(),c=()=>{s==null||s.abort(),s=void 0},d=u=>{!s||s.signal.aborted||(l(u),e(u))},l=u=>{let p=0;if(!a){const f=u-o,T=Math.round(f/r)*r;p=o+T+r-performance.now()}setTimeout(()=>requestAnimationFrame(d),p)};return l(o),a=!1,de({cancel:X(c),delay:X(t),signal:X(s.signal)})},zf=e=>{const t={},n=Object.getOwnPropertyDescriptors(e);for(const s of Object.keys(e)){const{get:r,value:a}=n[s];t[s]=ve(r||(ee(a)?a.bind(e):()=>a))}return de(t)},Kf=()=>{const e={idle:null,resume:null},t={};for(const n of Object.keys(e))t[n]={get:()=>e[n]??he,set:s=>{xe(s)?e[n]=null:ee(s)&&s!==e[n]&&(e[n]=s)}};return de(t)},su=Symbol("<<UNSUBSCRIBE>>"),us=e=>e===su,To=e=>{let t;const n=zf(e),s=Kf(),r=new Map,a=new WeakMap,o=()=>Object.freeze({...n}),c=()=>r.size===0,d=h=>{if(c())return;if(us(h)){const p=[];return r.forEach((f,T)=>{p.push(T);const g=a.get(T);for(;f--;)g==null||g()}),p.forEach(f=>f(h)),!0}const u=t;t=o();for(const p of Object.keys(t))if(!ds(t[p],u[p]))return r.forEach((f,T)=>T(t)),!0;return!1},l=h=>{if(!ee(h))return he;const u=Af(h,a,()=>{let f=()=>{const T=r.get(h)||0;T===1?(f=void 0,r.delete(h),a.delete(h),c()&&(t=void 0,s.idle())):T>1&&r.set(h,T-1)};return()=>{f==null||f()}}),p=c();return r.set(h,(r.get(h)||0)+1),p&&(t=o(),s.resume()),h(t),u};return de({idle:ve(c),on:X(s),cancelSubscriptions:X(()=>d(su)),requestNotification:X(()=>d()),snapshot:ve(()=>t??o()),subscribe:X(l)})},ic=(()=>{let e;const{cancelSubscriptions:t,requestNotification:n,subscribe:s,on:r}=To({now:()=>Date.now()});return r.resume=()=>{e=Vf(n,1e3,!1)},r.idle=()=>{e==null||e.cancel(),e=void 0},de({cancelSubscriptions:X(t),subscribe:X(s)})})(),ac=()=>{const e=new class extends EventTarget{},t=(s,...r)=>{const[a]=r;r.length&&oe(a)&&console.warn("Unexpected value `undefined` provided for event detail.\n Turn off this warning by doing either of the following:\n (1) omit the optional event detail parameter.\n (2) explicitly pass `null` for the event detail parameter (instead of `undefined`).\n");const o=new CustomEvent(s,de({bubbles:X(!1),cancelable:X(!1),detail:X(a??null)}));return e.dispatchEvent(o)},n=(s,r)=>{if(!ee(r))return he;const a=o=>r.call(null,de({detail:X(o.detail),timeStamp:X(o.timeStamp),type:X(o.type)}));return e.addEventListener(s,a),()=>e.removeEventListener(s,a)};return de({emit:X(t),on:X(n)})},Xf=(e,t)=>{let n,s=1/0,r,a;const o=zd(),c=ac(),d=()=>{n==null||n.removeEventListener("abort",d),s=1/0,a==null||a(),o.refresh(),c.emit(Jd)},l=go(async(u,p)=>{r=u;const f=await Ln(()=>{const g=t.deadline;return ee(g)?g.call(t,p,u):g}).catch(he);if(r!==u)return;const T=(Array.isArray(f)?f:[f]).filter(g=>g||g===0);if(T.length>0){let g=!1,y=new Set;for(const _ of T)if(mo(_)){if(g=_.aborted)break;y.add(_)}else if(s=Math.min(s,oc(_)??1/0),g=s<=Date.now())break;g||(g=y.size<1&&!Number.isFinite(s)),g?n??(n=yf()):(n=Ci([...y,o.signal]),n.addEventListener("abort",d),h()),T.length=0,y.clear()}else n=void 0}),h=()=>{if(!Number.isFinite(s))return;let u=ic.subscribe(p=>{if(us(p))return d();p.now>=s&&o.abort()});a=()=>{u==null||u(),u=a=void 0}};return de({elapse:X(o.abort),elapsed:ve(()=>n&&n.aborted),on:X(c.on),refresh:X(l.bind(void 0)),signal:ve(()=>o.signal)})},Zf=(e,t)=>{let n=!1,s,r,a=!0,o;const c=Symbol("<next_session>"),d=ac();function l(f){var T;try{(T=t.assert)==null||T.call(t,f)}catch{throw Uf}}function h(f){if(!ee(f))throw Bf}const u=go((f,T)=>{if(!r)r=f;else return p(mo(T)?Ci([T,f]):f)}),p=async f=>{let T=c;try{n=!1,r=f,a&&await(s??(s=(async()=>{await ir,a=!1,d.emit(nu)})())),h(t.onRefresh),T=await Ln(()=>t.onRefresh(o,f)).finally(()=>{if(f.aborted)throw Zd})}finally{if(r===f)try{T!==c&&(l(T),o=T,d.emit(eu))}finally{s=void 0,a=!0,d.emit(tu)}}};return e.on(Ni,()=>n=!s),u(),de({context:X(de({emitter:X(e),specification:X(t)})),on:X(d.on),pending:ve(()=>n),promise:ve(()=>u.promise),refresh:X(u.bind(void 0)),refreshing:ve(()=>!!s),session:ve(()=>o),signal:ve(()=>r)})};class Qf{constructor(t){Y(this,"_session");Y(this,"_autofresh");Y(this,"_deadline");Y(this,"_refresher");Y(this,"_eventEmitter",ac());this._specification=t,this._deadline=Xf(this._eventEmitter,this._specification),this._refresher=Zf(this._eventEmitter,this._specification),this._autofresh=qf(this._refresher),this._deadline.on(Jd,()=>this._eventEmitter.emit(Ni)),this._refresher.on(nu,()=>this._eventEmitter.emit(Gf)),this._refresher.on(tu,()=>this._eventEmitter.emit(Hf)),this._refresher.on(eu,()=>{this._session=this._refresher.session,this._deadline.refresh(this._session).finally(()=>this._eventEmitter.emit(Wf)),this._eventEmitter.emit(Qd)}),this.http=this._sessionHttp.bind(this),this.on=this._eventEmitter.on,this.refresh=this._refresher.refresh}get isExpired(){return this._deadline.elapsed}get refreshing(){return this._refresher.refreshing}_assertSessionHttp(t){if(!ee(t))throw $f}async _sessionHttp(t,...n){for(this._autofresh(!0);;)try{await this._refresher.promise.catch(he);const{signal:s}=this._deadline;return await(t==null?void 0:t(this._session,s,...n)),this._assertSessionHttp(this._specification.http),await this._specification.http(this._session,s,...n)}catch(s){if(s!==Xd)throw s;if(this._refresher.pending)continue;this._deadline.elapse()}}}const Jf="v1",aa=(e,t)=>{try{e==null||e(t)}catch{throw t}};async function em(e){const{errorLevel:t,loadingContext:n="",path:s}=e,r=wf(e),a=new URL(`${df(n)}${Jf}${uf(s)}`);return e.params&&e.params.forEach((o,c)=>{const d=decodeURIComponent(o);d&&a.searchParams.append(c,d)}),(async()=>{let o=!1;const c={level:t};try{const d=await fetch(a,r);if(d.ok){if(d.status===204)return null;try{switch(If(d)){case"application/json":return await d.json();default:const u=await d.blob(),p=Pf(d);return{blob:u,filename:p}}}catch(h){throw o=!0,h}}c.type=Of(d.status);const l=await d.json();c.message=e.errorMessage||`Service at ${a} not available`,c.errorCode=(l==null?void 0:l.status)==null?void 0:String(l.status),c.requestId=l==null?void 0:l.requestId,Ff(l)&&(c.message=l.detail,c.errorCode=l.errorCode,c.status=l.status),aa(e.errorHandler,c)}catch(d){if(o)throw aa(e.errorHandler,d),d;c.type||(c.type=Ur.NETWORK_ERROR),aa(e.errorHandler,d),c.message=e.errorMessage||`Call to ${a} failed. Error: ${d}`}Lf(c)})()}class tm{constructor(t){Y(this,"assert",t=>{if(Ri(t)){const n=Dt(t.id)?t.id.trim():void 0,s=Dt(t.token)?t.token.trim():void 0;if(n&&s)return}throw void 0});Y(this,"deadline",t=>{const n=[];let s,r;try{({iat:s,exp:r}=JSON.parse(atob(t==null?void 0:t.token.split(".")[1]))),n.push(r)}catch{s=Date.now()}if(!oe(ul)){const a=new Date(s);n.push(a.setMilliseconds(a.getMilliseconds()+ul))}return n});Y(this,"http",async(t,n,s)=>{const{headers:r,signal:a,...o}=s;try{const c={...o,headers:{...r,...t&&{Authorization:`Bearer ${t.token}`}},errorHandler:this._errorHandler,signal:mo(a)?Ci([n,a]):n};return await em(c)}catch(c){throw(c==null?void 0:c.type)===Ur.EXPIRED_TOKEN?Xd:c}});this.onSessionCreate=t,this._errorHandler=this._errorHandler.bind(this),Object.defineProperties(this,{autoRefresh:X(Df),onRefresh:X((n,s)=>this.onSessionCreate(s))})}_errorHandler(t){try{this.errorHandler&&this.errorHandler(t)}catch{}throw t}}const Sr=Symbol("<<NO_ERR>>");function nm(e){/* istanbul ignore if -- @preserve */if(e===Sr)throw new TypeError("Illegal error")}const sm=()=>{let e=Sr;const t=()=>{e=Sr},n=s=>{nm(s),e=s};return de({error:ve(()=>e===Sr?void 0:e),hasError:ve(()=>e!==Sr),reset:X(t),set:X(n)})};class rm{constructor(){Y(this,"_canSkipSessionRefresh",!1);Y(this,"_refreshPromisorSignal");Y(this,"_sessionIsFrozen",!1);Y(this,"_errorContainer",sm());Y(this,"_specification",new tm);Y(this,"_sessionContext",new Qf(this._specification));Y(this,"_setupContext",new xf(this._sessionContext));Y(this,"_refreshPromisor",go(async(t,n=!1)=>{let s=!this._refreshPromisorSignal,r=this._refreshPromisorSignal===(this._refreshPromisorSignal=t);const a=Ve(n)&&this._canSkipSessionRefresh;s&&(s=!1,this._errorContainer.reset(),this._onAuthStateChanged());try{await(a?this._setupContext:this._sessionContext).refresh(t).finally(()=>r=this._refreshPromisorSignal===t)}catch(o){if(!r)return;!t.aborted&&(a||o!==Zd)&&this._errorContainer.set(o),s=!a}finally{(s||a&&r)&&(this._refreshPromisorSignal=void 0,this._onAuthStateChanged())}}));Y(this,"_watchlist",To({endpoints:()=>this._setupContext.endpoints,extraConfig:()=>this._setupContext.extraConfig,hasError:()=>this._errorContainer.hasError,isExpired:()=>this._sessionContext.isExpired,isFrozen:()=>this._sessionIsFrozen,refreshing:()=>!!this._refreshPromisorSignal}));Y(this,"freeze",()=>{this._sessionIsFrozen=!0,this._watchlist.on.resume=void 0,this._watchlist.cancelSubscriptions()});Y(this,"http",this._sessionContext.http.bind(this._sessionContext,null));Y(this,"refresh",this._refresh.bind(this));Y(this,"subscribe",this._watchlist.subscribe);this._watchlist.on.resume=()=>{const t=[this._sessionContext.on(Ni,()=>{this._canSkipSessionRefresh=!1,this._onAuthStateChanged()}),this._sessionContext.on(Qd,()=>{this._refresh(this._canSkipSessionRefresh=!0)})];this._watchlist.on.idle=()=>{this._watchlist.on.idle=void 0,t.forEach(n=>n()),t.length=0},!this.context.refreshing&&en(this.context.isExpired)&&this._refresh()}}get context(){return this._watchlist.snapshot}set loadingContext(t){this._setupContext.loadingContext=t}set errorHandler(t){this._specification.errorHandler=t}set onSessionCreate(t){this._specification.onSessionCreate!==t&&(this._specification.onSessionCreate=t,this._refreshPromisorSignal&&ee(this._specification.onSessionCreate)&&(this._canSkipSessionRefresh=!1,this._refresh()))}_onAuthStateChanged(){this._watchlist.requestNotification()}_refresh(t=!1){this._refreshPromisor(t)}}const om="Account",im="Account Balance",am="Account description",cm="Account ID",lm="Additions",dm="Adjustments",um="Amount",hm="and",pm="Apply",fm="Back",mm="Balance account",_m="Balance account ID",gm="Booked",Tm="Captured",ym="Category",Am="Chargebacks",vm="Close",Rm="Contact support",Cm="Contact support for help.",Sm="Contact support for help and share error code %{requestId}",Em="Copied",Nm="Copy",Dm="Corrections",bm="Currency",Om="Date",Im="Date range",Pm="Description",km="Dismiss",wm="Download",Lm="Downloading",Fm="Email",Mm="Entity was not found",xm="Transaction not found for the specified Account Holder",Bm="Fees",$m="File",Um="Filter bar",Wm="From",Hm="Full",Gm="Funds captured",Ym="Go back",qm="Grant issued",jm="Grant repayments",Vm="Hide content",zm="ID",Km="Incomplete field",Xm="In progress",Zm="Loading",Qm="max",Jm="min",e0="Mobile",t0="Net payout",n0="Next Payouts",s0="No data",r0="No negative numbers allowed",o0="No payouts found",i0="No reports found",a0="No transactions found",c0="Other",l0="Paginated navigation",d0="Partial",u0="Payment ID",h0="Payment method",p0="Payout Details",f0="Payout information is generated each day at midnight, UTC time.",m0="Payouts",_0="Pending",g0="Please come back later.",T0="Please, reach out to support for assistance.",y0="Reach out to support",A0="Reference ID",v0="Refresh",R0="Refunds",C0="Refund payment",S0="We couldn’t process the refund. Try again later.",E0="Something went wrong.",N0="Your customer will receive the money in a maximum of 40 days. When the refund is successful you will see a new Refund transaction on your list.",D0="Refund is sent!",b0="Amount to refund",O0="Refunds can take up to 40 days depending on the payment method. Fees are included.",I0="Refund %{amount}",P0="Reason for refund",k0="Reference",w0="Remaining amount",L0="Report",F0="Reports are generated each day at midnight, UTC time.",M0="Reports",x0="Reset",B0="Reversed",$0="Something went wrong.",U0="Something went wrong. Try refreshing the page or come back later.",W0="Status",H0="Structured list",G0="Subtractions",Y0="Sum of same-day payouts",q0="Tabs",j0="The error code is %{requestId}",V0="There are no results",z0="The request is missing required fields or contains invalid data.",K0="There was an unexpected error",X0="The selected balance account is incorrect",Z0="Timezone",Q0="To",J0="Total incoming",e2="Total outgoing",t2="To value should be equal or greater than the From value",n2="Transaction details",s2="Transactions",r2="Transactions overview",o2="Transaction type",i2="Transfers",a2="Try a different search or reset your filters, and we’ll try again.",c2="Try refreshing the page or come back later.",l2="Amount",d2="Type",u2="Value",h2="We couldn't load the payouts overview.",p2="We couldn't load the reports overview.",f2="We couldn't load the transactions overview.",m2="We couldn't load your balance accounts.",_2="We couldn't load your payouts.",g2="We couldn't load your reports.",T2="We couldn't load your transactions.",y2={account:om,accountBalance:im,accountDescription:am,accountID:cm,additions:lm,adjustments:dm,amount:um,and:hm,apply:pm,back:fm,balanceAccount:mm,balanceAccountId:_m,"balanceAccounts.all":"All accounts",Booked:gm,"button.clearAll":"Clear all","calendar.controls":"Calendar navigation controls","calendar.nextMonth":"Next month","calendar.previousMonth":"Previous month","calendar.timezone":"Timezone is set on: GMT%{offset} (%{time})","capital.accountIsInactive":"Your account is inactive","capital.actionNeeded":"Action needed","capital.annualPercentageRate":"Annual percentage rate","capital.annualPercentageRateIsTheCostOfBorrowingForALoan":"The Annual Percentage Rate (APR) is the cost of borrowing of this loan under Adyen Capital User Terms, expressed as an annual rate.","capital.bankAccountDetails":"Bank account details","capital.bankAccountIban":"IBAN","capital.bankAccountNumber":"Account number","capital.bankCountryOrRegion":"Country/region","capital.bankRoutingNumber":"Routing number","capital.bankSortCode":"Sort code","capital.businessFinancing":"Business financing","capital.businessFinancingOffer":"Business financing offer","capital.businessFinancingSummary":"Business financing summary","capital.closed":"Closed","capital.couldNotContinueWithTheOffer":"We couldn't continue with the offer.","capital.couldNotLoadFinancialOffers":"We couldn't load financial offers.","capital.dailyRepaymentRate":"Daily repayment rate","capital.daysAndDaysLeft":"%{days} days (%{daysLeft} days left)","capital.expectedRepaymentPeriod":"Expected repayment period","capital.failed":"Failed","capital.fees":"Fees","capital.fullyRepaid":"Fully repaid","capital.goToTermsAndConditions":"Go to Terms & Conditions","capital.grantID":"Grant ID","capital.howMuchMoneyDoYouNeed":"How much money do you need?","capital.inProgress":"In progress","capital.legalSubtitleAU":"Adyen Capital is provided by Adyen Australia Pty Limited.","capital.legalSubtitleCA":"Adyen Capital is provided by Adyen Canada Ltd.","capital.legalSubtitleEU":"Loans are issued by Adyen N.V.","capital.legalSubtitleGB":"Loans are issued by Adyen N.V. represented by its London Branch.","capital.legalSubtitleUS":"Loans are issued by Adyen N.V. San Francisco Branch and subject to credit approval.","capital.maximumRepaymentPeriod":"Maximum repayment period","capital.minimumRepaymentToRepayTheFinancingOnTime":"Minimum repayment every %{days} days to repay the financing on time","capital.needSomeExtraMoney":"Need some extra money?","capital.offerLegalNoticeDescriptionUS":"If your application for business credit is denied, you have the right to a written statement of the specific reasons for the denial. To obtain the statement, please contact Adyen's Credit Support Team by emailing %{email} within 60 days from the date you are notified of our decision. We will send you a written statement of reasons for the denial within 30 days of receiving your request for the statement. %{break} The Federal Equal Credit Opportunity Act prohibits creditors from discriminating against credit applicants on the basis of race, color, religion, national origin, sex, marital status, age (provided that the applicant has the legal capacity to enter into a binding contract), because all or part of the applicant's income derives from any public assistance program, or because the applicant has in good faith exercised any right under the Consumer Credit Protection Act. The federal agency that administers compliance with this law concerning this creditor is the Office of the Comptroller of the Currency (OCC), Customer Assistance Group, PO Box 53570, Houston, TX 77052.","capital.offerLegalNoticeTitleUS":"Creditor: Adyen N.V. – San Francisco Branch %{break} 505 Brannan Street, San Francisco, CA 94107.","capital.oneMonth":"1 month","capital.pending":"Pending","capital.primaryAccount":"Primary account","capital.remaining":"Remaining","capital.remainingAmount":"Remaining amount","capital.remainingFees":"Remaining fees","capital.repaid":"Repaid","capital.repaidAmount":"Repaid amount","capital.repaidFees":"Repaid fees","capital.repaymentBalanceInfo":"Your current remaining amount, including fees, is %{amount}","capital.repaymentThreshold":"Repayment threshold","capital.requestedFunds":"Requested funds","capital.requestFunds":"Request funds","capital.requesting":"Requesting","capital.reviewOffer":"Review offer","capital.revoked":"Revoked","capital.seeNewOffer":"See new offer","capital.seeOptions":"See options","capital.sendRepayment":"Send repayment","capital.sendRepaymentNotice":"The additional repayment bank transfer made towards your loan could take 2-3 business days for it to be reflected on your loan account.","capital.sendRepaymentSubtitle":"Transfer money to this bank account to repay back part of your loan or the entirety of it.","capital.signTermsAndConditionsToReceiveFunds":"Sign the Terms & Conditions to receive your funds.","capital.signTheTermsToReceiveYourFunds":"Sign the terms to receive your funds","capital.submitInformation":"Submit information","capital.termEnds":"Term ends: ","capital.thereIsNoPrimaryAccountConfigured":"There is no primary account configured","capital.thisOfferExpiresOn":"This offer expires on %{date}.","capital.totalFees":"Total fees","capital.totalRepaymentAmount":"Total repayment amount","capital.unsupportedRegionDescription":"Business financing isn’t available in your region yet, but check back here for an offer.","capital.unsupportedRegionTitle":"Stay tuned!","capital.weCouldNotContinueWithTheOffer":"We couldn't continue with the offer.","capital.weCouldNotContinueWithTheOfferContactSupportForHelp":"We couldn't continue with the offer. Contact support for help.","capital.weCouldNotLoadFinancialOffers":"We couldn't load financial offers.","capital.weCouldNotProcessThisRequestTryAgain":"We couldn't process this request. Try again with a new offer.","capital.weNeedABitMoreInformationToProcessYourFundsPleaseCompleteTheseActions":"We need a bit more information to process your funds. Please complete these actions:","capital.weNeedABitMoreInformationToProcessYourFundsPleaseCompleteThisAction":"We need a bit more information to process your funds. Please complete this action:","capital.weNeedABitMoreInformationToProcessYourFundsPleaseCompleteThisActionBy":"We need a bit more information to process your funds. Please complete this action by %{date}:","capital.weReceivedYourRequestAndWeAreWorkingOnItNowCheckBackSoon":"We received your request and we’re working on it now. Check back soon for the next steps.","capital.writtenOff":"Written off","capital.xDays":"%{days} days","capital.xMonths":"%{months} months","capital.xPercent":"%{percentage}%","capital.youAcceptedButThenReturnedTheseFunds":"You accepted but then returned these funds","capital.youAcceptedTheseFundsButDidNotRepayThem":"You accepted these funds but did not repay them","capital.youAreRequestingFundingOf":"You’re requesting funding of","capital.youHaveBeenPrequalifiedForBusinessFinancingUpToX.part1":"You have been pre-qualified for business financing","capital.youHaveBeenPrequalifiedForBusinessFinancingUpToX.part2":" up to %{amount}.","capital.yourRequestedFundsWere":"Your requested funds were: ","capital.youShouldGetTheFundsWithinOneBusinessDay":"You should get the funds within one business day","capital.youWillNeedToRepayAMinimumOfXEveryXDaysToPayOffTheFunds":"You will need to repay a minimum of %{amount} every %{days} days to fully pay off the funds by %{date}.","capital.youWillSoonQualifyForAFinancialOffer":"You will soon qualify for a financial offer!",capture:Tm,category:ym,chargeback:Am,closeIconLabel:vm,contactSupport:Rm,contactSupportForHelp:Cm,contactSupportForHelpAndShareErrorCode:Sm,copied:Em,copy:Nm,correction:Dm,currency:bm,date:Om,dateRange:Im,default:"Default",description:Pm,dismiss:km,"disputes.accept":"Accept","disputes.accept.accepted":"Accepted","disputes.accept.chargeback":"Accept chargeback","disputes.accept.disputeAccepted":"Chargeback has been accepted","disputes.accept.disputeDisclaimer":"By accepting, you agree that the disputed amount will not be returned to your account.","disputes.accept.iAgree":"I agree","disputes.accept.requestForInformation":"Accept request for information","disputes.accept.requestForInformationAccepted":"Request for information has been accepted","disputes.accept.requestForInformationDisclaimer":"Once this request for information is accepted, it will be marked as expired and may lead to a chargeback in the future.","disputes.acceptedOn":"Accepted on","disputes.account":"Account","disputes.alert.autoDefended":"This chargeback was defended automatically.","disputes.alert.notDefendable":"This chargeback can’t be defended. Contact support for details.","disputes.alert.notDefendedExpired":"This request for information wasn’t responded to and was lost by default.","disputes.alert.notDefendedLost":"This chargeback wasn’t defended and was lost by default.","disputes.alert.responseDeadline":"The response deadline is %{date}","disputes.contactSupport.toDefendDispute":"Contact support to defend this dispute.","disputes.contactSupport.toDefendRequestForInformation":"Contact support to respond to this request for information.","disputes.contactSupport.toResolveNotificationOfFraud":"Contact support to resolve this notification of fraud. Refund this payment to avoid a future chargeback and paying extra fees.","disputes.currency":"Currency","disputes.defend.chargeback":"Defend chargeback","disputes.defend.chargebackFeeInformation":"A fee is charged for every defended chargeback. We recommend responding only when you have clear and convincing evidence.","disputes.defend.continue":"Continue","disputes.defend.defended":"Defended","disputes.defend.evidenceSubmitted":"Evidence has been submitted","disputes.defend.selectDefenseReason":"Select the reason you’re defending this chargeback.","disputes.defend.somethingWentWrong":"Something went wrong","disputes.defend.submit":"Submit","disputes.defend.submitSuccessfulInformation":"The chargeback details will be reviewed by the scheme, which can take up to 60 days.","disputes.defend.uploadDocumentsInformation":"Upload documents that support your dispute defense. Once submitted, no changes can be made.","disputes.defendedOn":"Defended on","disputes.defenseDocument.acquirerRepresentmentForm":"Acquirer Representment Form","disputes.defenseDocument.acquirerRepresentmentFormAutomaticallyGenerated":"The Acquirer Representment Form is an automatically generated document that contains an overview of key dispute details.","disputes.defenseDocument.acquirerRetrievalFulfilmentForm":"Acquirer Retrieval Fulfilment Form","disputes.defenseDocument.acquirerRetrievalFulfilmentFormAutomaticallyGenerated":"The Acquirer Retrieval Fulfilment Form is an automatically generated document that contains an overview of key dispute details.","disputes.defenseDocument.additionalInformation":"Additional Information","disputes.defenseDocument.additionalTransactions":"Additional Transactions","disputes.defenseDocument.additionalTransactionsConnectedWithDisputedFlight":"Additional transactions connected with the disputed flight, such as upgrades, excess baggage charges, and in-flight purchases","disputes.defenseDocument.alternativeDefenseMaterial":"Alternative defense material","disputes.defenseDocument.amexFaxCover":"Amex Fax Cover","disputes.defenseDocument.appropriateExplanation":"Appropriate explanation","disputes.defenseDocument.appropriateExplanationAndDocTwoSeparateTransactions":"An appropriate explanation and documentation showing two separate transactions.","disputes.defenseDocument.authorizationNotObtained":"Authorization Not Obtained","disputes.defenseDocument.authorizationNotObtainedHelp":"Authorization Not Obtained (Help)","disputes.defenseDocument.autoGeneratedDocRetrievalRequestFulfilled":"Automatically generated document showing that the retrieval request was fulfilled","disputes.defenseDocument.automaticallyGeneratedTransactionDetails":"Automatically generated transaction details","disputes.defenseDocument.avsDocumentation":"AVS Documentation","disputes.defenseDocument.cancelledRecurringBilling":"Cancelled recurring billing","disputes.defenseDocument.cardholderAgreedToAmountRange":"Documentation supporting the claim that the cardholder agreed to a reasonable amount range.","disputes.defenseDocument.cardholderResponsibleForAddendumTransaction":"Documentation to establish the cardholder is responsible for the addendum transaction","disputes.defenseDocument.cardholderResponsibleForDisputedAmount":"Documentation to support that the cardholder is responsible for the disputed amount.","disputes.defenseDocument.cardRecoveryBulletinOrExceptionFile":"Card Recovery Bulletin or Exception File","disputes.defenseDocument.cardRecoveryBulletinOrExceptionFileHelp":"Card Recovery Bulletin or Exception File (Help)","disputes.defenseDocument.chargebackRemediedOrInvalid":"Documentation to support that the chargeback is remedied or invalid.","disputes.defenseDocument.chargeToWrongAccountNumber":"Charge to Wrong Account Number","disputes.defenseDocument.chargeToWrongAccountNumberHelp":"Charge to Wrong Account Number (Help)","disputes.defenseDocument.clearingText":"Clearing Text","disputes.defenseDocument.compellingEvidence":"Compelling Evidence","disputes.defenseDocument.copyOfInvoice":"Copy of the invoice or similar document","disputes.defenseDocument.copyOfInvoiceOrOtherRelevantTransactionDetails":"Copy of the invoice, terminal receipt, sales ticket or any other document (Transaction Information Document) that provides the relevant transaction details like transaction amount, delivery address (if applicable) and description of the merchandise.","disputes.defenseDocument.CopyOfSalesDraftDetails":"Copy of the invoice, terminal receipt, sales ticket or any other document (transaction information document) that provides the relevant details like transaction amount, delivery address (if applicable) and description of the merchandise","disputes.defenseDocument.CopyOfSalesDraftTitle":"Copy of original Sales Draft","disputes.defenseDocument.copyOfTid":"A copy of the TID as proof that the transaction involved a retail sale rather than a credit.","disputes.defenseDocument.coverPageForAmexDisputes":"A cover page that will be sent for Amex disputes","disputes.defenseDocument.creditNotProcessed":"Credit Not Processed","disputes.defenseDocument.creditNotProcessedHelp":"Credit Not Processed (Help)","disputes.defenseDocument.creditNotProcessedReason":"Credit Not Processed Reason","disputes.defenseDocument.creditsOfMilesShowingConnectionToCardholder":"Credits of frequent flyer miles for the flight, showing connection to the cardholder","disputes.defenseDocument.customerWrittenConfirmation":"The customer's written confirmation of registration to receive electronic delivery of goods or services.","disputes.defenseDocument.defenseMaterial":"Defense Material","disputes.defenseDocument.deffectiveMerchandise":"Deffective Merchandise","disputes.defenseDocument.deffectiveMerchandiseHelp":"Deffective Merchandise (Help)","disputes.defenseDocument.deliveryOfFlightTicketAtAddress":"Proof of delivery of the flight ticket at cardholder's address","disputes.defenseDocument.descriptionOfDisputeReason":"A description of the dispute reason","disputes.defenseDocument.descriptionOfMerchandiseOrServices":"A description of the merchandise or services. This can be for example the invoice.","disputes.defenseDocument.differentSignature":"Different Signature","disputes.defenseDocument.differentSignatureHelp":"Different Signature (Help)","disputes.defenseDocument.disclosureAtPointOfInteraction":"Disclosure at the Point of Interaction","disputes.defenseDocument.docAllOfFollowing":"A merchant statement documenting all of the following:","disputes.defenseDocument.docCardholderIssuedPaperAirlineTickets":"Documentation establishing that the cardholder was issued paper airline tickets.","disputes.defenseDocument.docChargebackCodeNotApplicable":"Documentation to support that the chargeback code is not applicable","disputes.defenseDocument.docCorrectCurrency":"Documentation proving the correct currency was provided or specified","disputes.defenseDocument.docIdentifyTransaction":"Documentation that would further identify the transaction","disputes.defenseDocument.docMerchandiseNotCounterfeit":"Documentation to support the claim that the merchandise was not counterfeit","disputes.defenseDocument.docProvingCardHolderParticipated":"Documentation proving the card holder participated in the transacion. This can be:","disputes.defenseDocument.docRemediesChargeback":"Defense Material that remedies the chargeback.","disputes.defenseDocument.docsTwoTransactionsWithSameShopper":"Provide copies of two documents (for example terminal receipts or invoices) belonging to two separate transactions with the same shopper.","disputes.defenseDocument.docTermsOfSaleNotMisrepresented":"Documentation to prove that the terms of sale of the merchandise or services were not misrepresented","disputes.defenseDocument.docTransactionOccurredOnPos":"Documentation that show that the transaction occurred on an attended POS terminal","disputes.defenseDocument.docTwoDifferentTransactions":"Documentation showing Two Different Transactions","disputes.defenseDocument.documentationOfPositiveAvsResponseXOrY":"Documentation of positive AVS response X or Y","disputes.defenseDocument.documentCanBeCreditReasonDue":"A document can be a credit due reason.","disputes.defenseDocument.documentCanBeProofOfDelivery":"A document can be a proof of delivery signature or a proof of receipt copy.","disputes.defenseDocument.documentCanBeSubscriptionAgreement":"A document can be a subscription agreement.","disputes.defenseDocument.documentCanBetUrlReturnPolicy":"A document can be a description, item URL, return policy, or a copy of a contract or an affidavit.","disputes.defenseDocument.documentContainingImportantShipmentData":"A document containing important shipment data. It should include at least the shipment date.","disputes.defenseDocument.documentShipmentDate":"Document containing Shipment Date","disputes.defenseDocument.docViaFraudReporter":"Documentation that supports the second presentment from the Acquirer’s Loss Data File, the Acquirer Loss Data Report or the Acquirer Transaction Data Report via Fraud Reporter.","disputes.defenseDocument.duplicateProcessing":"Duplicate Processing","disputes.defenseDocument.duplicateProcessingHelp":"Duplicate Processing (Help)","disputes.defenseDocument.evidenceCardHolderParticipation":"Compelling Evidence of Card holder Participation","disputes.defenseDocument.evidenceProofingParticipationOfCardholder":"Compelling evidence proofing the participation of the cardholder in the transaction.","disputes.defenseDocument.evidenceTransactionWasRecurring":"Description of the goods or services being provided with evidence that the transaction was recurring by providing the start date of the recurring transaction and, if used, an indication that SecureCode or CVC2 has been used on the initial transaction.","disputes.defenseDocument.expiredCard":"Expired Card","disputes.defenseDocument.expiredCardHelp":"Expired Card (Help)","disputes.defenseDocument.explanation":"Explanation","disputes.defenseDocument.explanationWhyCancellationCodeInvalid":"Explanation why the cancellation code is invalid.","disputes.defenseDocument.falseTransaction":"False ransaction (Help)","disputes.defenseDocument.firstChargebackNumberAndDate":"Reference number and date of first chargeback","disputes.defenseDocument.flightManifest":"Flight Manifest","disputes.defenseDocument.flightManifestShowingCardholderName":"Flight manifest showing the cardholder's name","disputes.defenseDocument.flightTicket":"Flight Ticket","disputes.defenseDocument.flightTicketUsed":"Flight Ticket Used","disputes.defenseDocument.flightTicketWithCardholderName":"Flight Ticket or boarding pass showing the cardholder's name","disputes.defenseDocument.flightTookPlace":"Flight Took Place","disputes.defenseDocument.frequentFlyerInformation":"Frequent Flyer Information","disputes.defenseDocument.ifDelayedProofShowingMerchantAbleToProvideServices":"If the service is delayed, proof showing that the merchant is able to provide the services (for example, documentation showing that the merchant is not out of business)","disputes.defenseDocument.incorrectAmount":"Incorrect amount","disputes.defenseDocument.latePresentment":"Late Presentment","disputes.defenseDocument.latePresentmentHelp":"Late Presentment (Help)","disputes.defenseDocument.latestRecurringTransactions":"Latest Recurring Transactions","disputes.defenseDocument.memberMessageText":"Member Message Text","disputes.defenseDocument.memberMessageTextSentToSchemes":"Member Message Text sent to the schemes.","disputes.defenseDocument.merchandiseDescription":"Merchandise Description","disputes.defenseDocument.merchandiseNotAsDescribed":"Merchandise not as described.","disputes.defenseDocument.merchandiseNotReceived":"Merchandise Not Received","disputes.defenseDocument.merchandiseNotReceivedHelp":"Merchandise Not Received (Help)","disputes.defenseDocument.merchandiseSentToAvsConfirmedBillingAddress":" Documentation that shows the merchandise was sent to the AVS-confirmed billing address","disputes.defenseDocument.merchantFraudPerformanceProgram":"Merchant Fraud Performance Program","disputes.defenseDocument.merchantFraudPerformanceProgramHelp":"Merchant Fraud Performance Program (Help)","disputes.defenseDocument.merchantObtainedCardAtTimeReservationMade":"Documentation establishing that the merchant obtained the cardholder's account number, name present on the card, and the confirmation number provided at the time the reservation was made.","disputes.defenseDocument.merchantWrittenRebuttal":"Merchant's written rebuttal","disputes.defenseDocument.missingSignature":"Missing Signature","disputes.defenseDocument.missingSignatureHelp":"Missing Signature (Help)","disputes.defenseDocument.moreThanOneTransactionProcessed":"More than one transaction was processed by providing the date(s) of previous transaction(s).","disputes.defenseDocument.mpiData":"MPI Data","disputes.defenseDocument.nonMatchingAccountNumber":"Non Matching Account Number","disputes.defenseDocument.nonMatchingAccountNumberHelp":"Non Matching Account Number (Help)","disputes.defenseDocument.noNotification":"Proof of No Notification","disputes.defenseDocument.numberAndDateOfOriginalChargeback":"First chargeback reference number and date of original chargeback","disputes.defenseDocument.originalAmount":"Original Amount","disputes.defenseDocument.originalAmountIfDisputedRepresentsPartialShipment":"The original transaction amount if the disputed transaction represents partial shipment","disputes.defenseDocument.other":"Other","disputes.defenseDocument.otherHelp":"Other (Help)","disputes.defenseDocument.paidByOtherMeansThanJCBCard":"Paid By Other Means Than JCB Card","disputes.defenseDocument.paidByOtherMeansThanJCBCardHelp":"Paid By Other Means Than JCB Card (Help)","disputes.defenseDocument.paperAirlineTicket":"Paper Airline Ticket","disputes.defenseDocument.passengerId":"Passenger Identification Documentation","disputes.defenseDocument.passengerIdLinkedToCardholder":"Passenger identification documentation showing a link to the cardholder","disputes.defenseDocument.previousTransactionsNotDisputed":"Previous transactions were not disputed.","disputes.defenseDocument.printedSignedReceipt":"A printed, signed terminal receipt","disputes.defenseDocument.processingError":"Processing Error","disputes.defenseDocument.processingErrorHelp":"Processing Error (Help)","disputes.defenseDocument.proofAirlineTicketsWereUsed":"Documentation proving that the airline tickets were used by the cardholder or persons that the cardholder authorized.","disputes.defenseDocument.proofCardAndCardholderSignature":"Proof of card presence and cardholder signature","disputes.defenseDocument.proofCardPresence":"Proof of Card Presence","disputes.defenseDocument.proofFlightTookPlace":"Documentation proving that the airline rendered the service (the flight took place)","disputes.defenseDocument.proofGoodsServicesWereProvided":"Proof showing that the goods or services of the merchant were provided to the card holder","disputes.defenseDocument.proofGoodsWereDeliveredAsDescribed":"Proof showing that the goods were delivered as described.","disputes.defenseDocument.proofMerchantHadNotReceivedPreviousChargeback":"Proof showing that the merchant had not received a previous chargeback from the cardholder at the time of settlement.","disputes.defenseDocument.proofMerchantHadNotReceivedPreviousChargebackAutoGenerated":"Proof showing that the merchant had not received a previous chargeback from the cardholder at the time of settlement. (This proof is automatically generated.)","disputes.defenseDocument.proofMerchantNotNotifiedOfCancellation":"Proof showing that the merchant or acquirer was not notified of the cancellation at the time of settlement.","disputes.defenseDocument.proofOfAccountTakeover":"Proof of Account Takeover","disputes.defenseDocument.proofOfAddendum":"Proof of Addendum","disputes.defenseDocument.proofOfDelayedDelivery":"Proof of Delayed Delivery","disputes.defenseDocument.proofOfFulfillment":"Proof of Fulfillment","disputes.defenseDocument.proofOfInvalidChargeback":"Proof of Invalid Chargeback","disputes.defenseDocument.proofOfNoCancellation":"Proof of No Cancellation","disputes.defenseDocument.proofOfNoChargebackReceived":"Proof of No Chargeback Received","disputes.defenseDocument.proofOfNoShow":"Proof of No-Show","disputes.defenseDocument.proofOfRecurringTransaction":"Merchant's Proof of Recurring Transaction","disputes.defenseDocument.proofOfRefund":"Proof of Refund","disputes.defenseDocument.proofOfRetailSale":"Proof of Retail Sale","disputes.defenseDocument.proofProvidedMerchandise":"Proof of Provided Merchandise","disputes.defenseDocument.proofRecurringContractNotCancelledAtTimeOfSettlement":"Proof showing that the recurring contract was not cancelled at the time of settlement.","disputes.defenseDocument.proofRenewedMembership":"Proof of Renewed Membership","disputes.defenseDocument.proofShowingCardholderRenewedMembership":"Proof showing that the cardholder renewed his membership to the service after the cancellation received.","disputes.defenseDocument.proofShowingTrackingInformation":"Proof showing Tracking Info, Tracking Number.","disputes.defenseDocument.proofValidIncreaseOfAmount":"Proof of Valid Increase of Amount","disputes.defenseDocument.provideRefundId":"Provide the refund ID, for the difference in amount.","disputes.defenseDocument.provingTransactionResultedFromAccountTakeover":"Documentation that supports the second presentment by proving that the transaction resulted from an account takeover. For example: The Acquirer Loss File report, the SAFE Acquirer Transaction Data report or a statement from the authorized cardholder confirming that the account was in fact taken over and that fraud subsequently occurred.","disputes.defenseDocument.reasonableAmount":"Proof of reasonable amount","disputes.defenseDocument.reasonForInvalidation":"Reason for Invalidation","disputes.defenseDocument.reasonForInvalidationOfChargeback":"Reason for the invalidation of the chargeback. Please notice that this reason should be technical from nature, for example: the issuer submitted documentation that failed to support the chargeback.","disputes.defenseDocument.rebuttalCancellationNotAccepted":"Rebuttal of Cancellation Never Accepted","disputes.defenseDocument.rebuttalGivenToCardholder":"Rebuttal or proper disclosure given to the cardholder at the point of interaction.","disputes.defenseDocument.rebuttalStatingCancellationNotAccepted":"Rebuttal stating that the cancellation was never accepted","disputes.defenseDocument.receiptOfFlightTicketAtBillingAddress":"Proof of receipt of the flight ticket at the cardholder's billing address","disputes.defenseDocument.receiptOrOther":"A receipt, work order, or other document signed by the customer substantiating that the goods or services were received by the customer.","disputes.defenseDocument.resultsOfMpiCalls":"Results of MPI lookup service calls.","disputes.defenseDocument.retrievalRequestFulfilled":"Proof showing that the retrieval request was fulfilled","disputes.defenseDocument.retrievalRequestNotHonored":"Retrieval Request Not Honored","disputes.defenseDocument.retrievalRequestNotHonoredHelp":"Retrieval Request Not Honored (Help)","disputes.defenseDocument.serviceNotRendered":"Service Not Rendered","disputes.defenseDocument.serviceNotRenderedHelp":"Service Not Rendered (Help)","disputes.defenseDocument.shipmentDocumentation":"Shipment Documentation","disputes.defenseDocument.shipToAddress":"Ship-To Address","disputes.defenseDocument.shipToAddressIfApplicable":'"Ship to" address (if applicable)',"disputes.defenseDocument.signatureOrChipPinEvidence":"Signature or Chip PIN Evidence","disputes.defenseDocument.signedTerminalReceipt":"Signed Terminal Receipt","disputes.defenseDocument.SplitSales":"Duplicate Processing","disputes.defenseDocument.SplitSalesHelp":"Duplicate Processing (Help)","disputes.defenseDocument.statementMerchantDidNotReceiveGoods":"Statement from the merchant stating that the merchant did not receive the goods.","disputes.defenseDocument.SupplementalDocumentsDetails":"Complimentary information to the sales draft (e.g. Cardholder’s permission for recurring Transaction, MOTO/Electronic Commerce ordering form, Magnetic-stripe phone record.)","disputes.defenseDocument.SupplementalDocumentsTitle":"Additional transaction documents","disputes.defenseDocument.TEDocumentDetails":"Information related to the delivery of the travel and entertainment service (e.g. Hotel guest folio, Signature on file, Car rental agreement, etc.)","disputes.defenseDocument.TEDocumentTitle":"Travel and Entertainment information","disputes.defenseDocument.transactionAfterReservationCancelled":"Transaction After Reservation Cancelled","disputes.defenseDocument.transactionAfterReservationCancelledHelp":"Transaction After Reservation Cancelled (Help)","disputes.defenseDocument.transactionNotRecognizedChipLiabilityShift":"Transaction Not Recognized - Contactless and Card Not Presented","disputes.defenseDocument.transactionNotRecognizedChipLiabilityShiftHelp":"Transaction Not Recognized - Contactless and Card Not Presented (Help)","disputes.defenseDocument.transactionNotRecognizedContactlessAndCardNotPresented":"Transaction Not Recognized - Contactless and Card Not Presented","disputes.defenseDocument.transactionNotRecognizedContactlessAndCardNotPresentedHelp":"Transaction Not Recognized - Contactless and Card Not Presented (Help)","disputes.defenseDocument.unauthorisedReason":"Unauthorised reason","disputes.defenseDocument.uploadListOfRefundIds":"Upload list of Refund Id(s).","disputes.defenseDocument.writtenCorrespondenceExchanged":"Copies of written correspondence exchanged between the merchant and the customer (such as letter, email, or fax) showing that the customer participated in the transaction.","disputes.defenseDocument.writtenRebutalGoodsRepairedOrReplaced":"Written rebutal documenting that the goods were repaired or replaced.","disputes.defenseReason":"Defense reason","disputes.defenseReason.3dSecureFullyAuthenticatedTransaction":"3D Secure Fully Authenticated Transaction","disputes.defenseReason.3dSecureLiabilityShiftNotFullyAuthenticated":"3D Secure Liability Shift (not fully authenticated)","disputes.defenseReason.accountNumberNotListedInExceptions":"The Account Number was not listed on the Exception File","disputes.defenseReason.accountNumberNotListedInExceptionsFor60Days":"Account Number has not been on the Exception File with a Pickup Response for a minimum of 60 calendar days.","disputes.defenseReason.accountTakeover":"Account Takeover","disputes.defenseReason.acquirerDefendChargebackIfIssuerRequested":"The acquirer can defend the chargeback if the issuer requested it or if friendly-fraud is suspected. This might lead to further escalation with the issuer.","disputes.defenseReason.acquirerProvidesCorrectDateWithinTimeLimit":"The acquirer provides the correct transaction date that is within applicable time limit set forth in section Time Frame for First Presentment.","disputes.defenseReason.additionalInformation":"Additional Information","disputes.defenseReason.addressMerchandiseSentAvsConfirmed":"The merchant can provide documentation that it received a positive Address Verification Service (AVS) response of X (Both the nine-digit Postal zip code as well as the first five numerical characters contained in the address match) or Y (Both the five-digit Postal zip code as well as the first five numerical characters contained in the address match) for the transaction and documentation showing that the address to which the merchandise was sent is the same as the AVS confirmed address.","disputes.defenseReason.addressVerificationService":"Address Verification Service (AVS)","disputes.defenseReason.addressVerificationServiceAdditionalInformation":"Address Verification Service (AVS) Additional Information","disputes.defenseReason.airlineCompellingEvidence":"Airline Compelling Evidence","disputes.defenseReason.airlineFlightProvided":"Airline Flight Provided","disputes.defenseReason.atmDispute":"ATM Dispute","disputes.defenseReason.authorisationReceivedForAmount":"Authorisation was received for the transaction amount or greater from the issuer.","disputes.defenseReason.authorisedOnline":"Transaction was Authorised Online","disputes.defenseReason.autoGeneratedRecurringTransactionDetails":"Automatically generated recurring transaction details.","disputes.defenseReason.autoResponseSentToIssuer":"An automatically generated response has been sent to the issuer. This response was generated just before the Request for Information expires and contains the relevant data present in the system. Please notice that this response may be incomplete (for example if the merchandise description was not provided), which may lead to an invalid response. It is therefore recommended for the merchant to always upload the invoice (or the other requested information) for RFI's.","disputes.defenseReason.autoResponseToRfi":"Automatically Generated Response to a Request for Information","disputes.defenseReason.buyerExceededWindowToFileReturn":"Buyer has exceeded the window to file a return","disputes.defenseReason.cancellationCodeWasInvalidAsShownByExplanationProvided":"The cancellation code was invalid as is shown by the explanation provided.","disputes.defenseReason.cancellationContractFailed":"Cancellation Terms of the Contract failed","disputes.defenseReason.cancellationOrReturns":"Cancellation or Returns","disputes.defenseReason.cardAndSignatureForCorporateFleetCardTransaction":"Card was present and a signature exists for a Corporate Fleet Card transaction.","disputes.defenseReason.cardholderAgreedToAmountAsReasonable":"The cardholder agreed to an amount range as reasonable, and the transaction amount did not exceed this amount range.","disputes.defenseReason.cardholderBilledForSeparateAdditionalAmount":"For example, after the cardholder initially is billed for a vehicle rental, the cardholder is billed for a separate additional amount that represents unpaid parking tickets. The cardholder claims that he or she did not authorize the transaction for the parking tickets. The merchant should provide information about the violations showing that they were issued during the period that the vehicle was rented by the cardholder, as well as the rental agreement with proof of card presence and signature authorizing such charges.","disputes.defenseReason.cardholderCancelledRecurringServiceButRenewedLater":"The cardholder cancelled the recurring service, but renewed his membership after the cancellation.","disputes.defenseReason.cardholderDidNotMeetCancellationTerms":"The cardholder failed to meet the cancellation terms of the contract.","disputes.defenseReason.cardholderNotifiedBeforeRecurringTransaction":"The transaction amount was not within the range of amounts preauthorized but the Merchant notified the Cardholder before processing Recurring Transaction","disputes.defenseReason.cardholderNotifiedButNoReply":"Cardholder was notified but did not reply","disputes.defenseReason.cardholderParticipated":"The Cardholder Participated in the Transaction","disputes.defenseReason.cardholderResponsibleForAddendumTransaction":"Merchants may remedy the dispute with documentation substantiating the cardholder has participated in the original transaction and documentation to establish the cardholder is responsible for the addendum transaction.","disputes.defenseReason.cardholderResponsibleForDisputedAmount":"The merchant also must include documentation substantiating that the cardholder is responsible for the disputed amount if the amount represents final audit charges not included in the original hotel/motel or vehicle cardholder billing.","disputes.defenseReason.cardholderShouldHaveReturnedGoods":"The cardholder should have returned the goods to the merchant, but the merchant never received these goods.","disputes.defenseReason.cardPresenceProof":"Proof of Card Presence Available","disputes.defenseReason.cardPresentAndChipUsedNoPinProvided":"Card was present and Chip was used, but no PIN provided.","disputes.defenseReason.cardWithSignatureNotProcessedMastercardNetwork":"Card was present and a signature exists for a transaction that was not processed via the MasterCard Wordlwide Network.","disputes.defenseReason.cbCodeNotApplicable":"Chargeback code not applicable (card present transaction)","disputes.defenseReason.chargebackBundlingInvalid":"Chargeback bundling invalid for this reason code or MCC code","disputes.defenseReason.chargebackCodeNA3dSecureNotOffered":"Chargeback code is not applicable because 3D secure was not offered for the original transaction.","disputes.defenseReason.chargebackInvalidCorrectAmountAndCurrencyProvided":"The acquirer determines that the chargeback was invalid the correct transaction amount and currency code were provided.","disputes.defenseReason.chargebackReceivedAfterMastercardTimeLimit":"The chargeback was received after MasterCard's 120 days time limit after the authorisation.","disputes.defenseReason.chipLiabilityShift":"Chip Liability Shift","disputes.defenseReason.chipTransaction":"Chip Transaction","disputes.defenseReason.chipTransactionReportedSAFE":"Chip Transaction Reported to SAFE","disputes.defenseReason.claimNotJustifiedSinceTransactionNotChargebacked":"The issuer claims that a previous chargeback indicated the cancellation of the service. This claim is however not justified, since the transaction indicated by the issuer is not chargebacked or was not chargebacked at the time of settlement.","disputes.defenseReason.compellingEvidence":"Compelling Evidence","disputes.defenseReason.compellingEvidenceRecurringTransactions":"Compelling Evidence for Recurring Transactions","disputes.defenseReason.correctTransactionAmount":"Correct Transaction Amount","disputes.defenseReason.correctTransactionCurrency":"Correct transaction currency","disputes.defenseReason.correctTransactionDateProvided":"Correct transaction date provided","disputes.defenseReason.creditOrCancellationPolicyDisclosed":"Credit or Cancellation Policy Properly Disclosed","disputes.defenseReason.creditOrCancellationPolicyDisclosedToCardholder":"The merchant can substantiate that the credit or cancellation policy was properly disclosed to the cardholder at the point of interaction.","disputes.defenseReason.creditPreviouslyIssued":"Credit previously issued","disputes.defenseReason.cvc2ValidationProgram":"CVC 2 Validation Program","disputes.defenseReason.de22DontMatchInFaceToFaceTransaction":"DE 22 (Point of Service [POS] Entry Mode) of the authorization message and DE 22 (Point of Service Data Code) of the clearing messages do not match in a Face-to-Face transaction.","disputes.defenseReason.defenseReasonIfProblemsWithScans":"This defense reason can only be used if there are problems with the quality of the MasterCom scan of the documentation. Do not use this defense reason if the substance of the documentation received shows that the issuer processed an invalid first chargeback. One must use this defense reason when the first chargeback documentation does not correspond to the transaction being charged back (for example, the documentation concerns a different transaction) or when the documentation is incomplete because of a scanning error. For example, the documentation provided is a partial scan with missing information, or it relates to another card or to another transaction.","disputes.defenseReason.deficiencyCorrected":"Deficiency Corrected","disputes.defenseReason.delayInSubmittingTransaction":"The acquirer delayed presentment due to the merchant’s delay in submitting the transaction, as permitted under Chapter 3, Transaction Records of the Transaction Processing Rules, or a national bank holiday of at least four consecutive days prevented the acquirer from receiving the transaction within the applicable seven-calendar-day time frame.","disputes.defenseReason.disputedSurcharge":"Disputed Surcharge","disputes.defenseReason.disputedSurchargeIncorrectCalculation":"Disputed Surcharge - Incorrect Pro-rated Calculation","disputes.defenseReason.docToProveNoPaymentByOtherMean":"Documents (other than Transaction Receipt) to prove that Merchant did not receive payment by other means for the same merchandise or service.","disputes.defenseReason.documentationIncreasedDebitCardholderAccount":"The merchant can provide documentation that validates the increased debit to the cardholder's account. For example, documentation showing that the cardholder is responsible for the additional charges applied to his account.","disputes.defenseReason.documentationReceivedWasIllegible":"Documentation Received was Illegible","disputes.defenseReason.documentsSentToFulfillRetrievalRequest":"The supporting documents have been sent to fulfill the retrieval request.","disputes.defenseReason.duplicateChargeback":"Duplicate Chargeback","disputes.defenseReason.emergencyPaymentAuthorizationService":"Emergency Payment Authorization Service","disputes.defenseReason.emvDeviceNonEmvCard":"EMV liability shift: EMV device, non-EMV card","disputes.defenseReason.emvLiabilityShift":"EMV Liability Shift","disputes.defenseReason.evidenceCardholderAuthorizedTransaction":"The transaction was a non face-to-face (for example e-commerce) transaction. There is however evidence that the cardholder authorized the transaction.","disputes.defenseReason.evidenceGoodsNotDamaged":"There is evidence that the goods or services described on the invoice were delivered as described (not damaged or incomplete). For example, the merchant documents that the cardholder signed acknowledging the goods were received in good condition.","disputes.defenseReason.evidenceServicesProvidedAndReceivedWrittenCorrespondence":"The merchant can provide additional compelling evidence such as description of the goods or services provided; a receipt, work order or other document acknowledged by the customer that the goods or services were received by the customer; the customer's written confirmation of registration; any written correspondence exchanged between the merchant and the customer (such as letter, email or fax).","disputes.defenseReason.evidenceThatCardholderParticipated":"The merchant can provide compelling evidence to establish that the cardholder participated in the transaction.","disputes.defenseReason.faceToFaceTransactionNoConflictingInformation":"Face-to-Face Transaction with No Conflicting Information in Authorization and Clearing Message","disputes.defenseReason.faceToFaceTransactionWithConflictingInformation":"Face-to-Face Transaction with Conflicting Information in Authorization and Clearing Message","disputes.defenseReason.fallbackDefenseReasonCode":"Fallback defense reason code if all other defense reason codes do not apply. Use this reason if there is any documentation available that remedies the chargeback.","disputes.defenseReason.firstChargebackCodeNotApplicable":"Chargeback code used for the First Chargeback is not applicable to the Transaction.","disputes.defenseReason.firstChargebackDoesNotMeetPrerequisites":"The first chargeback does not meet the prerequisites for the dispute reason code. For example, an issuer processes a chargeback for message reason code 4837 (No Cardholder Authorization), with a cardholder letter alleging nonreceipt of merchandise. Since message reason code 4837 does not address issues related to nonreceipt of merchandise, the issuer's first chargeback was invalid, since it does not meet the prerequisites of message reason code 4837, which require the chargeback to include a cardholder letter stating that the transaction was not authorized.","disputes.defenseReason.firstChargebackInvalid":"Information provided by the issuer that is relevant is illegible to the point where it cannot be established that the first chargeback is valid. One must make every attempt to qualify the documentation before using this defense reason.","disputes.defenseReason.formatCbmmddyyArdXxxExpected":"The issuer did not provide the information required properly. Expected was the DE72 message text to be in the format CBMMDDYY ARD XXXXXXXXXXXXXXXXXXXXXXX, where MMDDYY denotes the date and XXXXXXXXXXXXXXXXXXXXXXX the Acquirer Reference Data of the chargeback containing the documentation to support this chargeback.","disputes.defenseReason.formatMultipleTransactionsNnnExpected":"The issuer did not provide the information required properly. Expected was the DE72 message text to be in the format MULTIPLE TRANSACTIONS NNN, where NNN denotes the number of chargebacks to which the supplied documentation applies to.","disputes.defenseReason.formatRpcsMmddyyExpected":"The issuer did not provide the information required properly. Expected was the DE72 message text to be in the format RPCS MMDDYY, where MMDDYY denotes date the account number was listed in the Recurring Payment Cancellation Service (RPCS).","disputes.defenseReason.fraudEvidence":"Card Present Fraud Evidence","disputes.defenseReason.goodsNotReturned":"Goods not Returned","disputes.defenseReason.goodsOrServicesProvided":"The goods or services were provided","disputes.defenseReason.goodsRepairedOrReplaced":"Goods Repaired or Replaced","disputes.defenseReason.goodsWereAsDescribed":"Goods were as Described","disputes.defenseReason.goodsWereRepairedOrReplaced":"The merchant can document that the goods that led to the chargeback, were repaired or replaced.","disputes.defenseReason.identifiedAddendum":"Identified Addendum","disputes.defenseReason.increasedTransactionAmount":"Increased Transaction Amount","disputes.defenseReason.intraregionalTransactionReportedSAFE":"The acquirer can demonstrate that the intraregional transaction was reported to SAFE as counterfeit fraud and occurred at a hybrid terminal (except for the U.S. region).","disputes.defenseReason.invalidAcquirerReferenceData":"Invalid Acquirer Reference Data on chargeback","disputes.defenseReason.invalidCancellationCode":"Invalid Cancellation Code","disputes.defenseReason.invalidChargeback":"Invalid Chargeback","disputes.defenseReason.invalidChargebackBasedOnMcc":"Invalid chargeback based on MCC","disputes.defenseReason.invalidChargebackReasonCode":"Invalid chargeback reason code for E-commerce/ POS payment","disputes.defenseReason.invalidMessageText":"Invalid Message Text","disputes.defenseReason.invalidReferenceDataDocumentationNotRequired":"Invalid Acquirer Reference Data on chargeback; documentation was provided or not required.","disputes.defenseReason.issuerDidNotIncludeTwoSetsOfArns":"The issuer did not include two sets of acquirer reference numbers (ARNs). Without this information one cannot validate the issuer's claim.","disputes.defenseReason.issuerDidNotProvideRequiredDocumentation":"The issuer did not provide the required documentation for this chargeback. This reason can only be chosen between 9 and 45 days of the first chargeback.","disputes.defenseReason.issuerHasInitiatedTooManyFraudulentDisputes":"The acquirer can defend the chargeback if the issuer has initiated too many fraudulent disputes on this PAN eg. more than 35 within the previous 120 calendar days for Visa.","disputes.defenseReason.issuerProcessedChargebackMoreThanOnce":"Use this defense strategy to remedy situations where the issuer has processed a first chargeback for the same transaction more than once.","disputes.defenseReason.justifiedDelayedPresentment":"Justified delayed presentment","disputes.defenseReason.liabilityShiftFullAuthenticated":"3D Secure Fully Authenticated Transaction","disputes.defenseReason.manyFraudulentChargebacks":"Too Many Fraudulent Chargebacks","disputes.defenseReason.membershipRenewedAfterCancellation":"Membership was Renewed after Cancellation","disputes.defenseReason.merchandiseNotReturned":"The merchandise was never returned","disputes.defenseReason.merchandiseWasNotCounterfeit":"Merchandise was not counterfeit","disputes.defenseReason.merchandiseWasReceivedByShopper":"The merchandise was received by the shopper","disputes.defenseReason.merchantCanProvideAdditionalCompellingEvidence":"The transaction is recurring, merchant can provide additional compelling evidence such as description of the goods or services provided; a receipt, work order or other document acknowledged by the customer that the goods or services were received by the customer; the customer's written confirmation of registration; any written correspondence exchanged between the merchant and the customer (such as letter, email or fax).","disputes.defenseReason.merchantCanProvideAdditionalInformation":"The merchant can provide additional information that would help to identify the transaction. This should include at least a description of the merchandise or services. This could, for example, be an invoice.","disputes.defenseReason.merchantCantReceiveThisChargebackBasedOnTheirMcc":"The merchant can not receive this chargeback based on their MCC","disputes.defenseReason.merchantNotNotifiedOfCancellation":"Merchant was not Notified of Cancellation","disputes.defenseReason.merchantProvidedServicesToCardholderProof":"There is proof that the merchant provided the services to the cardholder or person that the cardholder authorized.","disputes.defenseReason.merchantProvideMissingDocuments":"The merchant can provide the documents that were missing or were illegible, causing the chargeback.","disputes.defenseReason.noCreditSlip":"No credit slip or other advisement has been given to the card holder","disputes.defenseReason.noPriorChargebackReceived":"No prior chargeback received","disputes.defenseReason.noShowTransaction":"No Show Transaction","disputes.defenseReason.not3dSecureTransaction":"Not a 3D Secure transaction","disputes.defenseReason.notAgreeWithRefund":"The merchant did not agree with the refund","disputes.defenseReason.notPosTransaction":"Transaction was not a POS transaction","disputes.defenseReason.parcelServiceReceipt":"Proof that the cardholder received the merchandise or a person authorized by the cardholder received the merchandise. For example, the card acceptor provided proof of a United Parcel Service (UPS) receipt.","disputes.defenseReason.pastChargebackTimeLimit":"Past Chargeback Time Limit","disputes.defenseReason.paymentByOtherMeans":"Payment by Other Means","disputes.defenseReason.paypassAmountBelowProtectionAmount":"The transaction was a PayPass transaction with an amount below the chargeback protection amount.","disputes.defenseReason.paypassTransaction":"PayPass Transaction","disputes.defenseReason.pinForOneOrBothTransactions":"A PIN was present for one or both transactions.","disputes.defenseReason.pinTransaction":"PIN Transaction","disputes.defenseReason.pinUsedToVerifyCardholder":"PIN was used to verify the cardholder's presence in a POS environment.","disputes.defenseReason.posTransactionAndSignedTerminalReceiptAvailable":"The transaction was a POS transaction and a signed terminal receipt is available.","disputes.defenseReason.posTransactionCardholderWasPresentProof":"The transaction was a POS transaction and documentation is avaible to proof that the cardholder was present.","disputes.defenseReason.prevChargedbackTwoTransactionsWithSameAccount":"The issuer previously charged back two or more transactions involving the same MasterCard card account prior to the authorization approval date of the disputed transaction","disputes.defenseReason.previousChargebackCancellingRecurringContract":"The issuer claims that a previous transaction was chargebacked, cancelling the recurring contract. There is however proof that no prior transaction has been chargebacked at the time of settlement.","disputes.defenseReason.proofCardholderReceivedMerchandise":"There is proof that the cardholder or person that the cardholder authorized received the merchandise. For example:","disputes.defenseReason.proofDeficiencyCorrected":"The acquirer can document it corrected the deficiency that led to the chargeback.","disputes.defenseReason.proofOfCardPresenceAvailableNotAuthorisedMastercardNetwork":"Proof of Card Presence Available (Not authorised via MasterCard Wold Wide Network)","disputes.defenseReason.proofOfCardPresenceMastercardCorporateFleet":"Proof of Card Presence Available (Mastercard Corporate Fleet Card)","disputes.defenseReason.provideInformationForCollectionOrFraudCase":"Provide the required information for collection or fraud case","disputes.defenseReason.provideMissingInformation":"Provide Missing Information","disputes.defenseReason.provideTransactionalInformation":"Provide the requested transactional information to the issuer. At least this should include a copy of the invoice, receipt, sales ticket or any other document that provides the relevant order details, like the description of merchandise or services and the shipping data (if applicable).","disputes.defenseReason.provideTransactionalInfoTravelDetails":"Provide the requested transactional information to the issuer. At least this should include a copy of the invoice, receipt, sales ticket or any other document that provides the relevant order details, like the passenger name, travel agency (if applicable), ticket number (if applicable) and airline flight information.","disputes.defenseReason.purchaseProperlyPosted":"Purchase Properly Posted","disputes.defenseReason.qpsTransaction":"QPS Transaction","disputes.defenseReason.qpsTransactionWithAmountLessThanChargebackProtectionAmount":"The transaction was a QPS transaction with a transaction amount equal to or less than the chargeback protection amount.","disputes.defenseReason.receiptWithItemsBilledBecauseOfLossTheftDamages":"Card was present and a signed terminal receipt is available. The transaction involves loss, theft or damage. The merchant should provide the receipt containing specially the items that were additionally billed, because of the loss, theft or damages.","disputes.defenseReason.recurringTransactionCompellingEvidence":"Recurring Transaction Compelling Evidence","disputes.defenseReason.recurringTransactionCompellingMerchantEvidence":"Recurring Transaction Compelling Merchant Evidence","disputes.defenseReason.reponseToRfi":"Response to Request for Information","disputes.defenseReason.reponseToRfiCardPresent":"Response to a Request for Information (Card Present only)","disputes.defenseReason.requiredDocumentationNotReceived":"Non-receipt of Required Documentation to Support Chargeback","disputes.defenseReason.responseToRfiAirlines":"Response to Request for Information (Airlines only)","disputes.defenseReason.responseToRfiCarRental":"Response to Request for Information (Car Rental only)","disputes.defenseReason.retrievalRequestFulfilled":"Retrieval request fulfilled","disputes.defenseReason.returnNotAccepted":"The cancellation of services or the return of the merchandise was not accepted.","disputes.defenseReason.scanningError":"Scanning error - unrelated documents or partial scan","disputes.defenseReason.serviceCancelledButMerchantNotNotified":"The service was cancelled, but the merchant and acquirer were not notified in time to prevent the recurring transaction.","disputes.defenseReason.serviceNotCancelled":"Service was not Cancelled","disputes.defenseReason.serviceNotCancelledEvidence":"There is evidence that shows that the service was not cancelled at the time of the settlement.","disputes.defenseReason.servicesProvidedAfterCancellation":"Services Provided after Cancellation","disputes.defenseReason.servicesProvidedAndUsedAfterCancellation":"The merchant has provided services after the cancellation date, which have been used by the cardholder.","disputes.defenseReason.shopperClaimsRefundWasPromisedButNotExecuted":"The shopper claims that a refund was promised but not executed. To defend against this, simply upload a statement that this was not agreed.","disputes.defenseReason.shopperUsedAirlineTicket":"Shopper has or could have used the provided airline ticket","disputes.defenseReason.signedImprintedSalesSlipInvoicePosReceipt":"A signed and imprinted sales slip, invoice, or terminal-generated POS receipt showing that the cardholder, or a person that the cardholder authorized, picked up the merchandise. This documentation proves that the merchant did not ship or deliver the merchandise.","disputes.defenseReason.signedTerminalReceiptAvailable":"Signed Terminal Receipt Available","disputes.defenseReason.supplyDefenseMaterial":"Supply Defense Material","disputes.defenseReason.surchargeCorrectlyProcessed":"The acquirer substantiates that the surcharge was correctly processed.","disputes.defenseReason.surchargeIncorrectlyCalculatedByIssuer":"The acquirer substantiates that the pro-rated surcharge was incorrectly calculated by the issuer.","disputes.defenseReason.termsOfSaleWereNotMisrepresented":"Terms of sale were not misrepresented","disputes.defenseReason.thisReasonIsTechnical":"Please take care when using this dispute reason; this reason is technical in nature and does not always address the true nature of the dispute.","disputes.defenseReason.timeBetweenAuthorisationAndSettlementWithinTimeLimits":"The time between the authorisation and the settlement was within the time limits set by the schemes. For normal transactions the time limit is 180 days. In case the card account is no longer active/valid, the settlement should take place within 30 days for normal cards and 6 days for Visa Electron cards.","disputes.defenseReason.transactioAuthorisedEmergencyPaymentAuthorizationService":"The transaction was authorised through the Emergency Payment Authorization Service.","disputes.defenseReason.transactionAmountAlreadyRefunded":"The credit was previously issued, for example, the merchant already refunded the full transaction amount to the card holder.","disputes.defenseReason.transactionApproved3dSecureAuthenticated":"The transaction approved by the issuer was fully (directory and authentication response both Y) 3D Secure authenticated.","disputes.defenseReason.transactionBetweenChipLiabilityShiftProgramCustomers":"The transaction was between customers that participate in the appropriate Chip Liability Shift Program, occurred at a hybrid terminal, and was initiated with a non-EMV chip card.","disputes.defenseReason.transactionFallsCvc2ValidationProgram":"The transaction falls under the CVC2 Validation Program","disputes.defenseReason.transactionFromAccountTakeover":"The transaction resulted from an account takeover.","disputes.defenseReason.transactionInformationDocument":"The Transaction Information Document (TID) shows that the amount was processed correctly","disputes.defenseReason.transactionIssuerApproved3dSecureAuthenticated":"The transaction approved by the issuer was fully (directory and authentication response both Y) 3D Secure authenticated.","disputes.defenseReason.transactionNotChargebackedAutoDefense":"The issuer claims that a previous chargeback indicated the cancellation of the service. This claim is however not justified, since the transaction indicated by the issuer is not chargebacked or was not chargebacked at the time of settlement. This can be defended automatically by the system.","disputes.defenseReason.transactionNotFully3dSecureAuthenticated":"The transaction approved by the issuer was not fully 3D Secure authenticated, but there was a liability shift for the given dispute reason.","disputes.defenseReason.transactionNotRecurring":"Transaction is not Recurring","disputes.defenseReason.transactionNotRecurringTransactionInstallment":"The transaction was not recurring. For example, if the transaction is an installment.","disputes.defenseReason.transactionSettledWithinTimeLimit":"Transaction was settled within Time Limit","disputes.defenseReason.transactionsInitiatedDueToLossTheftOrDamages":"Transactions was initiated due to loss, theft or damages","disputes.defenseReason.transactionWasAuthorised":"Transaction was Authorised","disputes.defenseReason.transactionWasAuthorisedOnline":"Transaction was authorised online.","disputes.defenseReason.transactionWasECommerceGivenChargebackReasonNotApplicable":"The transaction was a E-Commerce, MOTO or Recurring transaction. The given chargeback reason is not applicable for these transaction types.","disputes.defenseReason.transactionWasInFaceToFaceEnvironment":"The transaction took place in a face-to-face (POS) environment.","disputes.defenseReason.transactionWasProperlyIdentifiedAsInstallmentTransaction":"The issuer claimed that the transaction was not for an installment billing, and transaction was properly identified as an installment transaction in the authorization request.","disputes.defenseReason.transactionWasResultOfGuaranteedReservation":"The transaction was the result of Guaranteed Reservation Service (a No-Show)","disputes.defenseReason.twoDifferentTidsNonAtm":"Two Different TIDs-Non-ATM","disputes.defenseReason.twoDifferentTidsWithSameCardholderAccount":"The Merchant can provide documentation to support two separate transactions by providing two different TIDs with the same cardholder account number.","disputes.defenseReason.twoDifferentTransactions":"Two Different Transactions","disputes.defenseReason.twoPreviousFraudRelatedChargebacks":"Two or More Previous Fraud-related Chargebacks","disputes.defenseReason.twoSeparateTransactions":"There is documentation available to support the claim that there were two separate transactions.","disputes.defenseReason.unfoundedCardholderDispute":"Unfounded cardholder dispute","disputes.defenseReason.unreasonableAmount":"Unreasonable Amount","disputes.defenseReason.uploadReturnPolicyDocument":"To defend against this dispute, upload a document that states the return policy, e.g. ToS","disputes.defenseReason.useThisDefenseReasonIfApplicable":"Use this defense reason if one of the following is applicable:","disputes.defenseReason.validityOfTransactionChargedExplanation":"The merchant can provide an explanation that substantiates the validity of the transaction charged.","disputes.defenseReason.waiverFormAbsolvingMerchantResponsibility":"A written merchant rebuttal to the claim of non-receipt of merchandise, such as a waiver form absolving merchant responsibility.","disputes.disputedAmount":"Disputed amount","disputes.disputeManagementTitle":"Dispute management","disputes.disputeReason":"Reason","disputes.disputeReference":"Dispute reference","disputes.documentRequirements":"Document requirements","disputes.documentRequirements.acceptableFormatAndSize":"Max 2MB for PDF or 10MB for JPEG, JPG, TIFF","disputes.documentRequirements.mustBeInEnglish":"Must be in English","disputes.documentRequirements.recommendedSize":"Recommended A4 or US letter size","disputes.empty.noChargebacksFound":"No chargebacks found","disputes.empty.noDisputesFound":"No disputes found","disputes.empty.noFraudAlertsFound":"No fraud alerts found","disputes.empty.tryDifferentSearchOrCheckAgainLaterForNewChargebacks":"Try different filters or check again later for new chargebacks.","disputes.empty.tryDifferentSearchOrCheckAgainLaterForNewDisputes":"Try different filters or check again later for new disputes.","disputes.empty.tryDifferentSearchOrCheckAgainLaterForNewFraudAlerts":"Try different filters or check again later for new fraud alerts.","disputes.error.couldNotLoadDisputesOverview":"We could not load the disputes overview component","disputes.error.entityWasNotFound":"Entity was not found","disputes.error.entityWasNotFoundDetail":"Dispute not found for the specified Account Holder","disputes.error.failedRetry":"Failed, retry","disputes.error.weCouldNotLoadYourDispute":"We could not load your dispute.","disputes.error.weCouldNotLoadYourDisputes":"We could not load your disputes.","disputes.error.weCouldNotProcessTheDisputePleaseTryAgainOrContactSupport":"We couldn't process this dispute. Please try again, or contact support if you continue to have problems.","disputes.evidence":"Evidence","disputes.expiredOn":"Expired on","disputes.goBack":"Go back","disputes.gridCell.dueDate":"Due: %{dueDate}","disputes.inputError.fileIsOverSizeLimitForTypeChooseASmallerFileAndTryAgain":"File is over %{size} limit for %{type}. Choose a smaller file and try again.","disputes.inputError.somethingWentWrongPleaseCheckYourDocuments":"Something went wrong, please check that your documents are meeting requirements.","disputes.inputError.uploadAtLeastOneSupportingDocumentToContinue":"Upload at least one supporting document to continue","disputes.issuerComment.showLess":"Show less","disputes.issuerComment.showMore":"Show more","disputes.issuerComment.title":"The issuer came back with some feedback:","disputes.merchantReference":"Merchant reference","disputes.openedOn":"Opened on","disputes.paymentMethod":"Payment method","disputes.paymentReference":"Payment reference","disputes.reason":"Reason","disputes.reasonCategory.adjustment":"Adjustment","disputes.reasonCategory.authorisationError":"Authorisation error","disputes.reasonCategory.consumerDispute":"Consumer dispute","disputes.reasonCategory.fraud":"Fraud","disputes.reasonCategory.other":"Other","disputes.reasonCategory.processingError":"Processing error","disputes.reasonCategory.requestForInformation":"Request for information","disputes.reasonCode":"Reason code","disputes.respondBy":"Respond by","disputes.showDisputeDetails":"Show details","disputes.status":"Status","disputes.status.accepted":"Accepted","disputes.status.expired":"Expired","disputes.status.lost":"Lost","disputes.status.pending":"Pending","disputes.status.responded":"Responded","disputes.status.undefended":"Undefended","disputes.status.unresponded":"Unresponded","disputes.status.won":"Won","disputes.statusGroup.chargebacks":"Chargebacks","disputes.statusGroup.fraudAlerts":"Fraud alerts","disputes.statusGroup.ongoingAndClosed":"Ongoing & closed","disputes.title":"Disputes","disputes.totalPaymentAmount":"Total payment amount","disputes.type.chargeback":"Chargeback","disputes.type.notificationOfFraud":"Notification of fraud","disputes.type.requestForInformation":"Request for information","disputes.uploadDocuments.addOptionalDocument":"Add optional document","disputes.uploadDocuments.extraRequiredDocument":"Required document","disputes.uploadDocuments.optionalDocument":"Optional document","disputes.uploadDocuments.selectDocumentType":"Select document type","disputes.uploadDocuments.selectOneOfTheRequiredOptions":"Select one of the required options",download:wm,downloading:Lm,email:Fm,entityWasNotFound:Mm,entityWasNotFoundDetail:xm,"error.pleaseTryAgainLater":"Please try again later.","error.somethingWentWrongWithDownload":"Something went wrong with the download","expandableCard.collapse":"Collapse","expandableCard.expand":"Expand",export:"Export",fee:Bm,file:$m,"filter.date.since":"Since %{date}","filter.date.until":"Until %{date}",filterBar:Um,"filterPlaceholder.category":"Type","filterPlaceholder.currency":"Currency","filterPlaceholder.status":"Status",from:Wm,full:Hm,fundsCaptured:Gm,goBack:Ym,grantIssued:qm,grantRepayment:jm,hideContent:Vm,id:zm,incompleteField:Km,inProgress:Xm,"inputError.disallowedFileType":"File type not accepted","inputError.fileRequired":"File required","inputError.tooManyFiles":"Too many files","inputError.veryLargeFile":"File size exceeds the maximum file size",loading:Zm,max:Qm,min:Jm,mobile:e0,netPayout:t0,nextPayouts:n0,noData:s0,noNegativeNumbersAllowed:r0,noPayoutsFound:o0,noReportsFound:i0,noTransactionsFound:a0,other:c0,paginatedNavigation:l0,"pagination.nextPage":"Next page","pagination.previousPage":"Previous page","pagination.showing":"Showing",partial:d0,paymentId:u0,paymentMethod:h0,payoutDetails:p0,payoutsNotice:f0,payoutsTitle:m0,Pending:_0,pleaseComeBackLater:g0,pleaseReachOutToSupportForAssistance:T0,"rangePreset.custom":"Custom","rangePreset.last30Days":"Last 30 days","rangePreset.last7Days":"Last 7 days","rangePreset.lastMonth":"Last month","rangePreset.lastWeek":"Last week","rangePreset.thisMonth":"This month","rangePreset.thisWeek":"This week","rangePreset.yearToDate":"Year to date",reachOutToSupport:y0,referenceID:A0,refresh:v0,refund:R0,"refund.amountAlreadyRefunded":"You already refunded %{amount}","refund.amountFailed":"The refund for %{amount} has failed. It is not currently possible to refund this amount. Please contact support.","refund.amountInProgress":"The partial refund of %{amount} is being processed.","refund.fee":"Fee","refund.fullAmountFailed":"It is not possible to refund this payment. Please contact support.","refund.fullAmountRefunded":"The full amount has been refunded back to the customer","refund.goToPayment":"Go to payment","refund.maximumRefundable":"You can only refund a maximum of %{amount}","refund.onlyRefundable":"You can only refund %{amount}","refund.originalAmount":"Original Amount","refund.originalPayment":"Original Payment","refund.paymentPspReference":"Payment PSP Reference","refund.pspReference":"PSP Reference","refund.refundFee":"Refund Fee","refund.refundPspReference":"Refund PSP Reference","refund.returnToRefund":"Return to refund","refund.theRefundIsBeingProcessed":"The refund is being processed.",refundAction:C0,refundActionErrorSubtitle:S0,refundActionErrorTitle:E0,refundActionSuccessSubtitle:N0,refundActionSuccessTitle:D0,refundAmount:b0,"refundAmount.excess":"You cannot exceed the available amount of %{amount}","refundAmount.required":"Enter a refund amount","refunded.full":"Fully refunded","refunded.partial":"Partially refunded",refundNotice:O0,refundPayment:I0,refundReason:P0,"refundReason.duplicate":"Duplicate","refundReason.fraudulent":"Fraudulent","refundReason.issue_with_item_sold":"Issue with item sold","refundReason.other":"Other","refundReason.requested_by_customer":"Requested by customer",refundReference:k0,"refundReference.placeholder":"Enter the reference here",remainingAmount:w0,report:L0,"reportsError.tooManyDownloads":"We couldn't download all the files. Please try again later.",reportsNotice:F0,reportsTitle:M0,"reportType.payout":"Payout",reset:x0,Reversed:B0,"select.filter.placeholder":"Placeholder","select.noOptionsFound":"No options match this search",somethingWentWrong:$0,somethingWentWrongTryRefreshingOrComeBackLater:U0,status:W0,structuredList:H0,subtractions:G0,sumOfSameDayPayouts:Y0,tabs:q0,theErrorCodeIs:j0,thereAreNoResults:V0,theRequestIsMissingRequiredFieldsOrContainsInvalidData:z0,thereWasAnUnexpectedError:K0,theSelectedBalanceAccountIsIncorrect:X0,timezone:Z0,to:Q0,"tooltip.ATM":"Money withdrawn at an ATM","tooltip.Capital":"Money from an incoming loan grant or outgoing loan repayment","tooltip.Chargeback":"Money returned to a customer after a disputed transaction","tooltip.Correction":"Adjustments to your funds, including transaction reversals and deposit corrections","tooltip.Fee":"Transaction costs and payment method fees","tooltip.Other":"Transactions not in another category, usually an adjustment","tooltip.Payment":"Money received to your account from a sales transaction","tooltip.Refund":"Money sent back to a customer from a refunded transaction","tooltip.totalIncoming":"All money received into your account based on the selected filters","tooltip.totalOutgoing":"All fees, refunds, payouts, and other charges based on the selected filters","tooltip.Transfer":"Money moved between your account and another account",totalIncoming:J0,totalOutgoing:e2,toValueShouldBeGreaterThanTheFromValue:t2,transactionDetails:n2,transactions:s2,transactionsOverviewTitle:r2,transactionType:o2,transfer:i2,tryDifferentSearchOrResetYourFiltersAndWeWillTryAgain:a2,tryRefreshingThePageOrComeBackLater:c2,txAmount:l2,"txType.ATM":"ATM","txType.Capital":"Capital","txType.Chargeback":"Chargeback","txType.Correction":"Correction","txType.Fee":"Fee","txType.Other":"Other","txType.Payment":"Payment","txType.Refund":"Refund","txType.Transfer":"Transfer",type:d2,"uploadedFile.remove":"Delete %{filename} file","uploadFile.browse":"Browse files",value:u2,weCouldNotLoadThePayoutsOverview:h2,weCouldNotLoadTheReportsOverview:p2,weCouldNotLoadTheTransactionsOverview:f2,weCouldNotLoadYourBalanceAccounts:m2,weCouldNotLoadYourPayouts:_2,weCouldNotLoadYourReports:g2,weCouldNotLoadYourTransactions:T2},A2={...y2},nn=e=>e.then(({default:t})=>t),ru={da_DK:()=>nn(Promise.resolve().then(()=>require("./da-DK-DzyB6ApY.cjs")))},ou={de_DE:()=>nn(Promise.resolve().then(()=>require("./de-DE-C_manCYP.cjs")))},iu={es_ES:()=>nn(Promise.resolve().then(()=>require("./es-ES-D4yWVVk4.cjs")))},au={fi_FI:()=>nn(Promise.resolve().then(()=>require("./fi-FI-ziHSaIAM.cjs")))},cu={fr_FR:()=>nn(Promise.resolve().then(()=>require("./fr-FR-B-twXuu4.cjs")))},lu={it_IT:()=>nn(Promise.resolve().then(()=>require("./it-IT-CNU9GJon.cjs")))},du={nl_NL:()=>nn(Promise.resolve().then(()=>require("./nl-NL-CWr5RWqD.cjs")))},uu={no_NO:()=>nn(Promise.resolve().then(()=>require("./no-NO-CU-dleiK.cjs")))},hu={pt_BR:()=>nn(Promise.resolve().then(()=>require("./pt-BR-DJUsdwmX.cjs")))},pu={sv_SE:()=>nn(Promise.resolve().then(()=>require("./sv-SE-Btn3_SAD.cjs")))},Xo={en_US:A2},cc={...ru,...ou,...Xo,...iu,...au,...cu,...lu,...du,...uu,...hu,...pu},jn="en-US",fu=cc.en_US,lc={year:"numeric",month:"2-digit",day:"2-digit"},v2=["constructor","i18n","watch","preferredTranslations"],mu=e=>[...new Set(Object.keys(e).map(t=>t.replace(/_/g,"-")).sort())],R2=mu(cc),_u={AED:"د.إ",AFN:"؋",ALL:"L",ANG:"ƒ",AOA:"Kz",ARS:"$",AUD:"$",AWG:"ƒ",AZN:"₼",BAM:"KM",BBD:"$",BDT:"৳",BGN:"лв",BHD:".د.ب",BIF:"FBu",BMD:"$",BND:"$",BOB:"Bs.",BRL:"R$",BSD:"$",BTC:"฿",BTN:"Nu.",BWP:"P",BYR:"p.",BYN:"Br",BZD:"BZ$",CAD:"$",CDF:"FC",CHF:"Fr.",CLP:"$",CNY:"¥",COP:"$",CRC:"₡",CUC:"$",CUP:"₱",CVE:"$",CZK:"Kč",DJF:"Fdj",DKK:"kr",DOP:"RD$",DZD:"دج",EEK:"kr",EGP:"£",ERN:"Nfk",ETB:"Br",EUR:"€",FJD:"$",FKP:"£",GBP:"£",GEL:"₾",GGP:"£",GHC:"₵",GHS:"GH₵",GIP:"£",GMD:"D",GNF:"FG",GTQ:"Q",GYD:"$",HKD:"$",HNL:"L",HRK:"kn",HTG:"G",HUF:"Ft",IDR:"Rp",ILS:"₪",IMP:"£",INR:"₹",IQD:"ع.د",IRR:"﷼",ISK:"kr",JEP:"£",JMD:"J$",JPY:"¥",KES:"KSh",KGS:"лв",KHR:"៛",KMF:"CF",KPW:"₩",KRW:"₩",KYD:"$",KZT:"₸",LAK:"₭",LBP:"£",LKR:"₨",LRD:"$",LSL:"M",LTL:"Lt",LVL:"Ls",MAD:"MAD",MDL:"lei",MGA:"Ar",MKD:"ден",MMK:"K",MNT:"₮",MOP:"MOP$",MUR:"₨",MVR:"Rf",MWK:"MK",MXN:"$",MYR:"RM",MZN:"MT",NAD:"$",NGN:"₦",NIO:"C$",NOK:"kr",NPR:"₨",NZD:"$",OMR:"﷼",PAB:"B/.",PEN:"S/.",PGK:"K",PHP:"₱",PKR:"₨",PLN:"zł",PYG:"Gs",QAR:"﷼",RMB:"¥",RON:"lei",RSD:"Дин.",RUB:"₽",RWF:"R₣",SAR:"﷼",SBD:"$",SCR:"₨",SDG:"ج.س.",SEK:"kr",SGD:"$",SHP:"£",SLL:"Le",SOS:"S",SRD:"$",SSP:"£",STD:"Db",SVC:"$",SYP:"£",SZL:"E",THB:"฿",TJS:"SM",TMT:"T",TND:"د.ت",TOP:"T$",TRL:"₤",TRY:"₺",TTD:"TT$",TVD:"$",TWD:"NT$",TZS:"TSh",UAH:"₴",UGX:"USh",USD:"$",UYU:"$U",UZS:"лв",VEF:"Bs",VND:"₫",VUV:"VT",WST:"WS$",XAF:"FCFA",XBT:"Ƀ",XCD:"$",XOF:"CFA",XPF:"₣",YER:"﷼",ZAR:"R",ZWD:"Z$"},C2={IDR:1,JPY:1,KRW:1,VND:1,BYR:1,CVE:1,DJF:1,GHC:1,GNF:1,KMF:1,PYG:1,RWF:1,UGX:1,VUV:1,XAF:1,XOF:1,XPF:1,MRO:10,BHD:1e3,IQD:1e3,JOD:1e3,KWD:1e3,OMR:1e3,LYD:1e3,TND:1e3},gu=e=>C2[e]||100,S2=e=>!!_u[e],Tu=e=>S2(e)?_u[e]:null,yu=(e,t)=>{const n=gu(t);return parseInt(String(e),10)/n},E2=(e,t,n,s=!1,r={})=>{const a=e.toString(),o=yu(a,n),c=t.replace("_","-"),d={style:"currency",currency:n,currencyDisplay:"symbol",...r};try{return s?N2(c,d,o):o.toLocaleString(c,d)}catch{return a}},N2=(e,t,n)=>Intl.NumberFormat(e,t).formatToParts(n).filter(s=>s.type!=="currency").reduce((s,r)=>s+r.value,"").trim(),D2=/GMT(?:[-+](?:0?\d|1[0-4])(?::?[0-5]\d)?)?$/,{BASE_FORMAT_OPTIONS:Au,BASE_LOCALE:Di,SYSTEM_TIMEZONE:bo,SYSTEM_TIMEZONE_FORMATTER:Ns}=(()=>{const e="en-US",t="2-digit",n="numeric",o=Object.freeze({year:n,month:"short",day:n,hour:t,minute:t,second:t,fractionalSecondDigits:3,timeZoneName:"longOffset"});let c,d;try{d=new Intl.DateTimeFormat(e,o),c=d.resolvedOptions().timeZone}catch{c=void 0}return{BASE_FORMAT_OPTIONS:o,BASE_LOCALE:e,SYSTEM_TIMEZONE:c,SYSTEM_TIMEZONE_FORMATTER:d}})(),b2=/\+(?=-)|([+-]00:00)/g,O2=/(^\D?)(\d)$/,I2=([e,t])=>(Math.abs(e*60)+t)*(e<0?-1:1),P2=e=>Object.freeze([Math.floor(e/60),_o(e,60)]),k2=e=>parseInt(e,10)||0,w2=e=>`GMT+${P2(e).map(s=>`${s}`.replace(O2,"$10$2")).join(":")}`.replace(b2,""),Oa=e=>{var n;const t=((n=e==null?void 0:e.match(D2))==null?void 0:n[0].replace("GMT","").split(":",2).map(k2))??Se;return I2(t.concat(0,0).slice(0,2))},L2=(e,t=Ns)=>{const n=Oa(Ns==null?void 0:Ns.format(e));return Oa(t==null?void 0:t.format(e))-n},vu=(e,t,n=1)=>{const{offset:s,timestamp:r}=e(t);return r-s*n*6e4},Kt=(e,t)=>vu(e,t,1),_n=(e,t)=>vu(e,t,-1),yo=(()=>{let e,t;oe(bo)||(e=function(){return this.TIMEZONE},t=function(s){if(xe(s))this.TIMEZONE=bo,this.formatter=Ns;else try{const r=new Intl.DateTimeFormat(Di,{...Au,timeZone:s}),a=r.resolvedOptions().timeZone;if(this.TIMEZONE===a)return;this.TIMEZONE=a,this.formatter=r}catch{}});function n(...s){if(s.length===0)return n.call(this,Date.now());const r=s[0],a=new Date(r).getTime(),o=this.formatter??Ns;return Object.freeze({formatted:o==null?void 0:o.format(a),offset:L2(a,o),timestamp:a})}return()=>{const s={TIMEZONE:bo},r=t==null?void 0:t.bind(s),a=de({current:{get:e==null?void 0:e.bind(s),set:r},system:{value:bo}});return Object.defineProperties(n.bind(s),{tz:{get:()=>a,set:r}})}})(),F2={values:z,count:0},M2=/^[a-z]{2}-[A-Z]{2}$/,Zo=e=>e.substring(0,2).toLowerCase();function x2(e,t){if(!e)return null;const n=Zo(e);return t.find(s=>Zo(s)===n)||null}function dc(e){const t=e.replace("_","-");if(M2.test(t))return t;const[n,s]=t.split("-");if(!n||!s)return null;const r=`${n.toLowerCase()}-${s.toUpperCase()}`;return r.length===5?r:null}function uc(e,t){const n=e.trim();if(!n||n.length<1||n.length>5)return jn;const s=dc(n);return s&&t.includes(s)?s:x2(s??n,t)}function B2(e=z,t){return e===z?e:Object.keys(e).reduce((n,s)=>{const r=dc(s)||uc(s,t);return r&&e[s]&&(n[r]=e[s]),n},{})}const ca=(e,t)=>{if(ee(t)){const n=new Map;let s=-1;return e.replace(/%{(\w+)}/g,(r,a)=>{let o=n.get(a)??-1;const c=t(a,++s,++o)??"";return n.set(a,o),c})}return e.replace(/%{(\w+)}/g,(n,s)=>(t==null?void 0:t[s])??"")},pl=(e,t,n=F2)=>{const s=n.count??0,r=`${t}__${s}`;if(Zt(e,r)&&e[r])return ca(e[r],n.values);const a=`${t}__plural`;return Zt(e,a)&&s>1&&e[a]?ca(e[a],n.values):Zt(e,t)&&e[t]?ca(e[t],n.values):null},$2=async(e,t=z,n=z)=>{const s=uc(e,Object.keys(t))||jn,r=t[s];return{...fu,...await(ee(r)?r():r)??z,...$r(n==null?void 0:n[e])}};function U2(){let e=this.locale,t=e,n=[...this.supportedLocales];return de({load:{value:s=>$2(e,this.preferredTranslations,s)},locale:{get:()=>e,set:s=>{t=s,e=dc(s)||uc(s,n)||jn}},supportedLocales:{get:()=>n,set(s){n=s,this.locale=t}}})}function W2(){var t;const e={};for(const[n,s]of Object.entries(Object.getOwnPropertyDescriptors(bi.prototype)))v2.includes(n)||(ee(s.get)?e[n]={get:s.get.bind(this),...n==="timezone"&&{set:(t=s.set)==null?void 0:t.bind(this)}}:ee(s.value)?e[n]={value:s.value.bind(this)}:e[n]={get:()=>this[n]});return e}var qt,zr,xs,Kr,Bs,$s,ln,Xr,Kn,Xn,Us,Ws,Zr,Ia;class bi{constructor(t=jn,n){$(this,Zr);$(this,qt,jn);$(this,zr,Zo(m(this,qt)));$(this,xs,[jn]);$(this,Kr,m(this,xs));$(this,Bs);$(this,$s,fu);$(this,ln,U2.call(this));$(this,Xr,ir);$(this,Kn);$(this,Xn);$(this,Us,To({timestamp:()=>performance.now()}));$(this,Ws,yo());Y(this,"watch",m(this,Us).subscribe.bind(void 0));Y(this,"i18n",de(W2.call(this)));Y(this,"preferredTranslations");this.watch(he),this.preferredTranslations=Object.freeze((n==null?void 0:n.reduce((s,r)=>({...s,...r}),Xo))??{...Xo}),k(this,xs,mu(this.preferredTranslations)),this.locale=t}get customTranslations(){return m(this,Bs)??{}}set customTranslations(t){let n,s=[...m(this,xs)];if(!xe(t)){n=B2(t,R2);const r=Object.keys(n);s=[...s,...r].sort().filter((a,o,c)=>c.indexOf(a)===o)}m(this,ln).supportedLocales=s,K(this,Zr,Ia).call(this,n)}get languageCode(){return m(this,zr)}get lastRefreshTimestamp(){return m(this,Us).snapshot.timestamp}get locale(){return m(this,qt)}set locale(t){if(xe(t))this.locale=jn;else{if(m(this,ln).locale=t,m(this,qt)===m(this,ln).locale)return;K(this,Zr,Ia).call(this,m(this,Bs))}}get ready(){return m(this,Xr)}get supportedLocales(){return m(this,Kr)}get timezone(){return m(this,Ws).tz.current}set timezone(t){m(this,Ws).tz=t}get(t,n){const s=pl(m(this,$s),t,n);return Ko(s)?t:s}has(t,n){return!!pl(m(this,$s),t,n)}amount(t,n,s){const{hideCurrency:r,...a}=s||{},o=E2(t,m(this,qt),n,r,{...a,currencyDisplay:"symbol",signDisplay:"never"});return t<0?`- ${o}`:o}date(t,n={}){const s={...lc,timeZone:m(this,Ws).tz.current,...n};return new Date(t).toLocaleDateString(m(this,qt),s)}fullDate(t){return this.date(t,{month:"short",hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1})}}qt=new WeakMap,zr=new WeakMap,xs=new WeakMap,Kr=new WeakMap,Bs=new WeakMap,$s=new WeakMap,ln=new WeakMap,Xr=new WeakMap,Kn=new WeakMap,Xn=new WeakMap,Us=new WeakMap,Ws=new WeakMap,Zr=new WeakSet,Ia=function(t){oe(m(this,Xn))&&k(this,Xr,new Promise(r=>{k(this,Xn,()=>{r(m(this,Kn)),k(this,Kn,k(this,Xn,void 0))})}));const n=()=>{var r;m(this,Kn)===s&&((r=m(this,Xn))==null||r.call(this))},s=k(this,Kn,(async()=>{k(this,$s,await m(this,ln).load(t)),k(this,qt,m(this,ln).locale),k(this,Kr,Object.freeze(m(this,ln).supportedLocales)),k(this,Bs,t),k(this,zr,Zo(m(this,qt))),m(this,Us).requestNotification()})());s.then(n).catch(r=>{n(),console.error(r)})};class hc{constructor(t){Y(this,"components",[]);Y(this,"options");Y(this,"localization");Y(this,"loadingContext");Y(this,"session",new rm);Y(this,"onError");Y(this,"update",async(t=z)=>(this.setOptions(t),await this.initialize(),this.components.forEach(n=>{n.props.core===this&&n.update(this.getPropsForComponent(this.options))}),this));Y(this,"remove",t=>(this.components=this.components.filter(n=>n._id!==t._id),t.unmount(),this));Y(this,"registerComponent",t=>{t.props.core===this&&this.components.push(t)});Y(this,"setOptions",t=>{var n,s;return this.options={...this.options,...t},this.localization.locale=(n=this.options)==null?void 0:n.locale,this.localization.customTranslations=(s=this.options)==null?void 0:s.translations,this.session.loadingContext=this.loadingContext,this.session.onSessionCreate=this.options.onSessionCreate,this});this.options={environment:Sa,...t},this.localization=new bi(t.locale,t.availableTranslations),this.loadingContext=hf(this.options.environment),this.setOptions(t)}async initialize(){return Promise.all([this.localization.ready]).then(()=>this)}getPropsForComponent(t){return{...t}}}Y(hc,"version","1.7.0");var Ao,fe,Ru,Cu,Gn,fl,Su,Eu,Nu,pc,Pa,ka,Du,Wr={},bu=[],H2=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,vo=Array.isArray;function Xt(e,t){for(var n in t)e[n]=t[n];return e}function fc(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function ar(e,t,n){var s,r,a,o={};for(a in t)a=="key"?s=t[a]:a=="ref"?r=t[a]:o[a]=t[a];if(arguments.length>2&&(o.children=arguments.length>3?Ao.call(arguments,2):n),typeof e=="function"&&e.defaultProps!=null)for(a in e.defaultProps)o[a]===void 0&&(o[a]=e.defaultProps[a]);return Pr(e,o,s,r,null)}function Pr(e,t,n,s,r){var a={type:e,props:t,key:n,ref:s,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:r??++Ru,__i:-1,__u:0};return r==null&&fe.vnode!=null&&fe.vnode(a),a}function G2(){return{current:null}}function Q(e){return e.children}function yn(e,t){this.props=e,this.context=t}function cr(e,t){if(t==null)return e.__?cr(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null)return n.__e;return typeof e.type=="function"?cr(e):null}function Ou(e){var t,n;if((e=e.__)!=null&&e.__c!=null){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null){e.__e=e.__c.base=n.__e;break}return Ou(e)}}function wa(e){(!e.__d&&(e.__d=!0)&&Gn.push(e)&&!Qo.__r++||fl!==fe.debounceRendering)&&((fl=fe.debounceRendering)||Su)(Qo)}function Qo(){for(var e,t,n,s,r,a,o,c=1;Gn.length;)Gn.length>c&&Gn.sort(Eu),e=Gn.shift(),c=Gn.length,e.__d&&(n=void 0,r=(s=(t=e).__v).__e,a=[],o=[],t.__P&&((n=Xt({},s)).__v=s.__v+1,fe.vnode&&fe.vnode(n),mc(t.__P,n,s,t.__n,t.__P.namespaceURI,32&s.__u?[r]:null,a,r??cr(s),!!(32&s.__u),o),n.__v=s.__v,n.__.__k[n.__i]=n,ku(a,n,o),n.__e!=r&&Ou(n)));Qo.__r=0}function Iu(e,t,n,s,r,a,o,c,d,l,h){var u,p,f,T,g,y,_=s&&s.__k||bu,v=t.length;for(d=Y2(n,t,_,d,v),u=0;u<v;u++)(f=n.__k[u])!=null&&(p=f.__i===-1?Wr:_[f.__i]||Wr,f.__i=u,y=mc(e,f,p,r,a,o,c,d,l,h),T=f.__e,f.ref&&p.ref!=f.ref&&(p.ref&&_c(p.ref,null,f),h.push(f.ref,f.__c||T,f)),g==null&&T!=null&&(g=T),4&f.__u||p.__k===f.__k?d=Pu(f,d,e):typeof f.type=="function"&&y!==void 0?d=y:T&&(d=T.nextSibling),f.__u&=-7);return n.__e=g,d}function Y2(e,t,n,s,r){var a,o,c,d,l,h=n.length,u=h,p=0;for(e.__k=new Array(r),a=0;a<r;a++)(o=t[a])!=null&&typeof o!="boolean"&&typeof o!="function"?(d=a+p,(o=e.__k[a]=typeof o=="string"||typeof o=="number"||typeof o=="bigint"||o.constructor==String?Pr(null,o,null,null,null):vo(o)?Pr(Q,{children:o},null,null,null):o.constructor===void 0&&o.__b>0?Pr(o.type,o.props,o.key,o.ref?o.ref:null,o.__v):o).__=e,o.__b=e.__b+1,c=null,(l=o.__i=q2(o,n,d,u))!==-1&&(u--,(c=n[l])&&(c.__u|=2)),c==null||c.__v===null?(l==-1&&(r>h?p--:r<h&&p++),typeof o.type!="function"&&(o.__u|=4)):l!=d&&(l==d-1?p--:l==d+1?p++:(l>d?p--:p++,o.__u|=4))):e.__k[a]=null;if(u)for(a=0;a<h;a++)(c=n[a])!=null&&(2&c.__u)==0&&(c.__e==s&&(s=cr(c)),Lu(c,c));return s}function Pu(e,t,n){var s,r;if(typeof e.type=="function"){for(s=e.__k,r=0;s&&r<s.length;r++)s[r]&&(s[r].__=e,t=Pu(s[r],t,n));return t}e.__e!=t&&(t&&e.type&&!n.contains(t)&&(t=cr(e)),n.insertBefore(e.__e,t||null),t=e.__e);do t=t&&t.nextSibling;while(t!=null&&t.nodeType==8);return t}function Mn(e,t){return t=t||[],e==null||typeof e=="boolean"||(vo(e)?e.some(function(n){Mn(n,t)}):t.push(e)),t}function q2(e,t,n,s){var r,a,o=e.key,c=e.type,d=t[n];if(d===null&&e.key==null||d&&o==d.key&&c===d.type&&(2&d.__u)==0)return n;if(s>(d!=null&&(2&d.__u)==0?1:0))for(r=n-1,a=n+1;r>=0||a<t.length;){if(r>=0){if((d=t[r])&&(2&d.__u)==0&&o==d.key&&c===d.type)return r;r--}if(a<t.length){if((d=t[a])&&(2&d.__u)==0&&o==d.key&&c===d.type)return a;a++}}return-1}function ml(e,t,n){t[0]=="-"?e.setProperty(t,n??""):e[t]=n==null?"":typeof n!="number"||H2.test(t)?n:n+"px"}function Oo(e,t,n,s,r){var a;e:if(t=="style")if(typeof n=="string")e.style.cssText=n;else{if(typeof s=="string"&&(e.style.cssText=s=""),s)for(t in s)n&&t in n||ml(e.style,t,"");if(n)for(t in n)s&&n[t]===s[t]||ml(e.style,t,n[t])}else if(t[0]=="o"&&t[1]=="n")a=t!=(t=t.replace(Nu,"$1")),t=t.toLowerCase()in e||t=="onFocusOut"||t=="onFocusIn"?t.toLowerCase().slice(2):t.slice(2),e.l||(e.l={}),e.l[t+a]=n,n?s?n.t=s.t:(n.t=pc,e.addEventListener(t,a?ka:Pa,a)):e.removeEventListener(t,a?ka:Pa,a);else{if(r=="http://www.w3.org/2000/svg")t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(t!="width"&&t!="height"&&t!="href"&&t!="list"&&t!="form"&&t!="tabIndex"&&t!="download"&&t!="rowSpan"&&t!="colSpan"&&t!="role"&&t!="popover"&&t in e)try{e[t]=n??"";break e}catch{}typeof n=="function"||(n==null||n===!1&&t[4]!="-"?e.removeAttribute(t):e.setAttribute(t,t=="popover"&&n==1?"":n))}}function _l(e){return function(t){if(this.l){var n=this.l[t.type+e];if(t.u==null)t.u=pc++;else if(t.u<n.t)return;return n(fe.event?fe.event(t):t)}}}function mc(e,t,n,s,r,a,o,c,d,l){var h,u,p,f,T,g,y,_,v,N,S,D,R,b,E,P,w,W=t.type;if(t.constructor!==void 0)return null;128&n.__u&&(d=!!(32&n.__u),a=[c=t.__e=n.__e]),(h=fe.__b)&&h(t);e:if(typeof W=="function")try{if(_=t.props,v="prototype"in W&&W.prototype.render,N=(h=W.contextType)&&s[h.__c],S=h?N?N.props.value:h.__:s,n.__c?y=(u=t.__c=n.__c).__=u.__E:(v?t.__c=u=new W(_,S):(t.__c=u=new yn(_,S),u.constructor=W,u.render=V2),N&&N.sub(u),u.props=_,u.state||(u.state={}),u.context=S,u.__n=s,p=u.__d=!0,u.__h=[],u._sb=[]),v&&u.__s==null&&(u.__s=u.state),v&&W.getDerivedStateFromProps!=null&&(u.__s==u.state&&(u.__s=Xt({},u.__s)),Xt(u.__s,W.getDerivedStateFromProps(_,u.__s))),f=u.props,T=u.state,u.__v=t,p)v&&W.getDerivedStateFromProps==null&&u.componentWillMount!=null&&u.componentWillMount(),v&&u.componentDidMount!=null&&u.__h.push(u.componentDidMount);else{if(v&&W.getDerivedStateFromProps==null&&_!==f&&u.componentWillReceiveProps!=null&&u.componentWillReceiveProps(_,S),!u.__e&&(u.shouldComponentUpdate!=null&&u.shouldComponentUpdate(_,u.__s,S)===!1||t.__v==n.__v)){for(t.__v!=n.__v&&(u.props=_,u.state=u.__s,u.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.some(function(x){x&&(x.__=t)}),D=0;D<u._sb.length;D++)u.__h.push(u._sb[D]);u._sb=[],u.__h.length&&o.push(u);break e}u.componentWillUpdate!=null&&u.componentWillUpdate(_,u.__s,S),v&&u.componentDidUpdate!=null&&u.__h.push(function(){u.componentDidUpdate(f,T,g)})}if(u.context=S,u.props=_,u.__P=e,u.__e=!1,R=fe.__r,b=0,v){for(u.state=u.__s,u.__d=!1,R&&R(t),h=u.render(u.props,u.state,u.context),E=0;E<u._sb.length;E++)u.__h.push(u._sb[E]);u._sb=[]}else do u.__d=!1,R&&R(t),h=u.render(u.props,u.state,u.context),u.state=u.__s;while(u.__d&&++b<25);u.state=u.__s,u.getChildContext!=null&&(s=Xt(Xt({},s),u.getChildContext())),v&&!p&&u.getSnapshotBeforeUpdate!=null&&(g=u.getSnapshotBeforeUpdate(f,T)),P=h,h!=null&&h.type===Q&&h.key==null&&(P=wu(h.props.children)),c=Iu(e,vo(P)?P:[P],t,n,s,r,a,o,c,d,l),u.base=t.__e,t.__u&=-161,u.__h.length&&o.push(u),y&&(u.__E=u.__=null)}catch(x){if(t.__v=null,d||a!=null)if(x.then){for(t.__u|=d?160:128;c&&c.nodeType==8&&c.nextSibling;)c=c.nextSibling;a[a.indexOf(c)]=null,t.__e=c}else for(w=a.length;w--;)fc(a[w]);else t.__e=n.__e,t.__k=n.__k;fe.__e(x,t,n)}else a==null&&t.__v==n.__v?(t.__k=n.__k,t.__e=n.__e):c=t.__e=j2(n.__e,t,n,s,r,a,o,d,l);return(h=fe.diffed)&&h(t),128&t.__u?void 0:c}function ku(e,t,n){for(var s=0;s<n.length;s++)_c(n[s],n[++s],n[++s]);fe.__c&&fe.__c(t,e),e.some(function(r){try{e=r.__h,r.__h=[],e.some(function(a){a.call(r)})}catch(a){fe.__e(a,r.__v)}})}function wu(e){return typeof e!="object"||e==null?e:vo(e)?e.map(wu):Xt({},e)}function j2(e,t,n,s,r,a,o,c,d){var l,h,u,p,f,T,g,y=n.props,_=t.props,v=t.type;if(v=="svg"?r="http://www.w3.org/2000/svg":v=="math"?r="http://www.w3.org/1998/Math/MathML":r||(r="http://www.w3.org/1999/xhtml"),a!=null){for(l=0;l<a.length;l++)if((f=a[l])&&"setAttribute"in f==!!v&&(v?f.localName==v:f.nodeType==3)){e=f,a[l]=null;break}}if(e==null){if(v==null)return document.createTextNode(_);e=document.createElementNS(r,v,_.is&&_),c&&(fe.__m&&fe.__m(t,a),c=!1),a=null}if(v===null)y===_||c&&e.data===_||(e.data=_);else{if(a=a&&Ao.call(e.childNodes),y=n.props||Wr,!c&&a!=null)for(y={},l=0;l<e.attributes.length;l++)y[(f=e.attributes[l]).name]=f.value;for(l in y)if(f=y[l],l!="children"){if(l=="dangerouslySetInnerHTML")u=f;else if(!(l in _)){if(l=="value"&&"defaultValue"in _||l=="checked"&&"defaultChecked"in _)continue;Oo(e,l,null,f,r)}}for(l in _)f=_[l],l=="children"?p=f:l=="dangerouslySetInnerHTML"?h=f:l=="value"?T=f:l=="checked"?g=f:c&&typeof f!="function"||y[l]===f||Oo(e,l,f,y[l],r);if(h)c||u&&(h.__html===u.__html||h.__html===e.innerHTML)||(e.innerHTML=h.__html),t.__k=[];else if(u&&(e.innerHTML=""),Iu(t.type==="template"?e.content:e,vo(p)?p:[p],t,n,s,v=="foreignObject"?"http://www.w3.org/1999/xhtml":r,a,o,a?a[0]:n.__k&&cr(n,0),c,d),a!=null)for(l=a.length;l--;)fc(a[l]);c||(l="value",v=="progress"&&T==null?e.removeAttribute("value"):T!==void 0&&(T!==e[l]||v=="progress"&&!T||v=="option"&&T!==y[l])&&Oo(e,l,T,y[l],r),l="checked",g!==void 0&&g!==e[l]&&Oo(e,l,g,y[l],r))}return e}function _c(e,t,n){try{if(typeof e=="function"){var s=typeof e.__u=="function";s&&e.__u(),s&&t==null||(e.__u=e(t))}else e.current=t}catch(r){fe.__e(r,n)}}function Lu(e,t,n){var s,r;if(fe.unmount&&fe.unmount(e),(s=e.ref)&&(s.current&&s.current!==e.__e||_c(s,null,t)),(s=e.__c)!=null){if(s.componentWillUnmount)try{s.componentWillUnmount()}catch(a){fe.__e(a,t)}s.base=s.__P=null}if(s=e.__k)for(r=0;r<s.length;r++)s[r]&&Lu(s[r],t,n||typeof e.type!="function");n||fc(e.__e),e.__c=e.__=e.__e=void 0}function V2(e,t,n){return this.constructor(e,n)}function Ds(e,t,n){var s,r,a,o;t==document&&(t=document.documentElement),fe.__&&fe.__(e,t),r=(s=!1)?null:t.__k,a=[],o=[],mc(t,e=t.__k=ar(Q,null,[e]),r||Wr,Wr,t.namespaceURI,r?null:t.firstChild?Ao.call(t.childNodes):null,a,r?r.__e:t.firstChild,s,o),ku(a,e,o)}function Fu(e,t,n){var s,r,a,o,c=Xt({},e.props);for(a in e.type&&e.type.defaultProps&&(o=e.type.defaultProps),t)a=="key"?s=t[a]:a=="ref"?r=t[a]:c[a]=t[a]===void 0&&o!==void 0?o[a]:t[a];return arguments.length>2&&(c.children=arguments.length>3?Ao.call(arguments,2):n),Pr(e.type,c,s||e.key,r||e.ref,null)}function hs(e){function t(n){var s,r;return this.getChildContext||(s=new Set,(r={})[t.__c]=this,this.getChildContext=function(){return r},this.componentWillUnmount=function(){s=null},this.shouldComponentUpdate=function(a){this.props.value!==a.value&&s.forEach(function(o){o.__e=!0,wa(o)})},this.sub=function(a){s.add(a);var o=a.componentWillUnmount;a.componentWillUnmount=function(){s&&s.delete(a),o&&o.call(a)}}),n.children}return t.__c="__cC"+Du++,t.__=e,t.Provider=t.__l=(t.Consumer=function(n,s){return n.children(s)}).contextType=t,t}Ao=bu.slice,fe={__e:function(e,t,n,s){for(var r,a,o;t=t.__;)if((r=t.__c)&&!r.__)try{if((a=r.constructor)&&a.getDerivedStateFromError!=null&&(r.setState(a.getDerivedStateFromError(e)),o=r.__d),r.componentDidCatch!=null&&(r.componentDidCatch(e,s||{}),o=r.__d),o)return r.__E=r}catch(c){e=c}throw e}},Ru=0,Cu=function(e){return e!=null&&e.constructor==null},yn.prototype.setState=function(e,t){var n;n=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=Xt({},this.state),typeof e=="function"&&(e=e(Xt({},n),this.props)),e&&Xt(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),wa(this))},yn.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),wa(this))},yn.prototype.render=Q,Gn=[],Su=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Eu=function(e,t){return e.__v.__b-t.__v.__b},Qo.__r=0,Nu=/(PointerCapture)$|Capture$/i,pc=0,Pa=_l(!1),ka=_l(!0),Du=0;var z2=0;function i(e,t,n,s,r,a){t||(t={});var o,c,d=t;if("ref"in d)for(c in d={},t)c=="ref"?o=t[c]:d[c]=t[c];var l={type:e,props:d,key:n,ref:o,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:--z2,__i:-1,__u:0,__source:r,__self:a};if(typeof e=="function"&&(o=e.defaultProps))for(c in o)d[c]===void 0&&(d[c]=o[c]);return fe.vnode&&fe.vnode(l),l}var os,Be,la,gl,lr=0,Mu=[],Ye=fe,Tl=Ye.__b,yl=Ye.__r,Al=Ye.diffed,vl=Ye.__c,Rl=Ye.unmount,Cl=Ye.__;function Ro(e,t){Ye.__h&&Ye.__h(Be,e,lr||t),lr=0;var n=Be.__H||(Be.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({}),n.__[e]}function F(e){return lr=1,Oi(xu,e)}function Oi(e,t,n){var s=Ro(os++,2);if(s.t=e,!s.__c&&(s.__=[n?n(t):xu(void 0,t),function(c){var d=s.__N?s.__N[0]:s.__[0],l=s.t(d,c);d!==l&&(s.__N=[l,s.__[1]],s.__c.setState({}))}],s.__c=Be,!Be.__f)){var r=function(c,d,l){if(!s.__c.__H)return!0;var h=s.__c.__H.__.filter(function(p){return!!p.__c});if(h.every(function(p){return!p.__N}))return!a||a.call(this,c,d,l);var u=s.__c.props!==c;return h.forEach(function(p){if(p.__N){var f=p.__[0];p.__=p.__N,p.__N=void 0,f!==p.__[0]&&(u=!0)}}),a&&a.call(this,c,d,l)||u};Be.__f=!0;var a=Be.shouldComponentUpdate,o=Be.componentWillUpdate;Be.componentWillUpdate=function(c,d,l){if(this.__e){var h=a;a=void 0,r(c,d,l),a=h}o&&o.call(this,c,d,l)},Be.shouldComponentUpdate=r}return s.__N||s.__}function G(e,t){var n=Ro(os++,3);!Ye.__s&&gc(n.__H,t)&&(n.__=e,n.u=t,Be.__H.__h.push(n))}function dr(e,t){var n=Ro(os++,4);!Ye.__s&&gc(n.__H,t)&&(n.__=e,n.u=t,Be.__h.push(n))}function q(e){return lr=5,A(function(){return{current:e}},[])}function K2(e,t,n){lr=6,dr(function(){if(typeof e=="function"){var s=e(t());return function(){e(null),s&&typeof s=="function"&&s()}}if(e)return e.current=t(),function(){return e.current=null}},n==null?n:n.concat(e))}function A(e,t){var n=Ro(os++,7);return gc(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function C(e,t){return lr=8,A(function(){return e},t)}function ps(e){var t=Be.context[e.__c],n=Ro(os++,9);return n.c=e,t?(n.__==null&&(n.__=!0,t.sub(Be)),t.props.value):e.__}function X2(){for(var e;e=Mu.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach($o),e.__H.__h.forEach(La),e.__H.__h=[]}catch(t){e.__H.__h=[],Ye.__e(t,e.__v)}}Ye.__b=function(e){Be=null,Tl&&Tl(e)},Ye.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),Cl&&Cl(e,t)},Ye.__r=function(e){yl&&yl(e),os=0;var t=(Be=e.__c).__H;t&&(la===Be?(t.__h=[],Be.__h=[],t.__.forEach(function(n){n.__N&&(n.__=n.__N),n.u=n.__N=void 0})):(t.__h.forEach($o),t.__h.forEach(La),t.__h=[],os=0)),la=Be},Ye.diffed=function(e){Al&&Al(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(Mu.push(t)!==1&&gl===Ye.requestAnimationFrame||((gl=Ye.requestAnimationFrame)||Z2)(X2)),t.__H.__.forEach(function(n){n.u&&(n.__H=n.u),n.u=void 0})),la=Be=null},Ye.__c=function(e,t){t.some(function(n){try{n.__h.forEach($o),n.__h=n.__h.filter(function(s){return!s.__||La(s)})}catch(s){t.some(function(r){r.__h&&(r.__h=[])}),t=[],Ye.__e(s,n.__v)}}),vl&&vl(e,t)},Ye.unmount=function(e){Rl&&Rl(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(s){try{$o(s)}catch(r){t=r}}),n.__H=void 0,t&&Ye.__e(t,n.__v))};var Sl=typeof requestAnimationFrame=="function";function Z2(e){var t,n=function(){clearTimeout(s),Sl&&cancelAnimationFrame(t),setTimeout(e)},s=setTimeout(n,100);Sl&&(t=requestAnimationFrame(n))}function $o(e){var t=Be,n=e.__c;typeof n=="function"&&(e.__c=void 0,n()),Be=t}function La(e){var t=Be;e.__c=e.__(),Be=t}function gc(e,t){return!e||e.length!==t.length||t.some(function(n,s){return n!==e[s]})}function xu(e,t){return typeof t=="function"?t(e):t}const at="adyen-pe-typography";var O=(e=>(e.CAPTION="caption",e.BODY="body",e.SUBTITLE="subtitle",e.TITLE="title",e))(O||{}),Gt=(e=>(e.WIDE="wide",e.STRONGER="stronger",e.STRONGER_WIDE="stronger-wide",e.STRONGEST="strongest",e.STRONGEST_WIDE="strongest-wide",e.MEDIUM="m",e.LARGE="l",e.MOBILE="mobile",e))(Gt||{}),J=(e=>(e.H1="h1",e.H2="h2",e.H3="h3",e.H4="h4",e.H5="h5",e.H6="h6",e.DIV="div",e.PARAGRAPH="p",e.SPAN="span",e))(J||{});function Bu(e,t){for(var n in t)e[n]=t[n];return e}function Fa(e,t){for(var n in e)if(n!=="__source"&&!(n in t))return!0;for(var s in t)if(s!=="__source"&&e[s]!==t[s])return!0;return!1}function El(e,t){this.props=e,this.context=t}function Ue(e,t){function n(r){var a=this.props.ref,o=a==r.ref;return!o&&a&&(a.call?a(null):a.current=null),t?!t(this.props,r)||!o:Fa(this.props,r)}function s(r){return this.shouldComponentUpdate=n,ar(e,r)}return s.displayName="Memo("+(e.displayName||e.name)+")",s.prototype.isReactComponent=!0,s.__f=!0,s}(El.prototype=new yn).isPureReactComponent=!0,El.prototype.shouldComponentUpdate=function(e,t){return Fa(this.props,e)||Fa(this.state,t)};var Nl=fe.__b;fe.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),Nl&&Nl(e)};var Q2=typeof Symbol<"u"&&Symbol.for&&Symbol.for("react.forward_ref")||3911;function _r(e){function t(n){var s=Bu({},n);return delete s.ref,e(s,n.ref||null)}return t.$$typeof=Q2,t.render=t,t.prototype.isReactComponent=t.__f=!0,t.displayName="ForwardRef("+(e.displayName||e.name)+")",t}var J2=fe.__e;fe.__e=function(e,t,n,s){if(e.then){for(var r,a=t;a=a.__;)if((r=a.__c)&&r.__c)return t.__e==null&&(t.__e=n.__e,t.__k=n.__k),r.__c(e,t)}J2(e,t,n,s)};var Dl=fe.unmount;function $u(e,t,n){return e&&(e.__c&&e.__c.__H&&(e.__c.__H.__.forEach(function(s){typeof s.__c=="function"&&s.__c()}),e.__c.__H=null),(e=Bu({},e)).__c!=null&&(e.__c.__P===n&&(e.__c.__P=t),e.__c=null),e.__k=e.__k&&e.__k.map(function(s){return $u(s,t,n)})),e}function Uu(e,t,n){return e&&n&&(e.__v=null,e.__k=e.__k&&e.__k.map(function(s){return Uu(s,t,n)}),e.__c&&e.__c.__P===t&&(e.__e&&n.appendChild(e.__e),e.__c.__e=!0,e.__c.__P=n)),e}function da(){this.__u=0,this.o=null,this.__b=null}function Wu(e){var t=e.__.__c;return t&&t.__a&&t.__a(e)}function Io(){this.i=null,this.l=null}fe.unmount=function(e){var t=e.__c;t&&t.__R&&t.__R(),t&&32&e.__u&&(e.type=null),Dl&&Dl(e)},(da.prototype=new yn).__c=function(e,t){var n=t.__c,s=this;s.o==null&&(s.o=[]),s.o.push(n);var r=Wu(s.__v),a=!1,o=function(){a||(a=!0,n.__R=null,r?r(c):c())};n.__R=o;var c=function(){if(!--s.__u){if(s.state.__a){var d=s.state.__a;s.__v.__k[0]=Uu(d,d.__c.__P,d.__c.__O)}var l;for(s.setState({__a:s.__b=null});l=s.o.pop();)l.forceUpdate()}};s.__u++||32&t.__u||s.setState({__a:s.__b=s.__v.__k[0]}),e.then(o,o)},da.prototype.componentWillUnmount=function(){this.o=[]},da.prototype.render=function(e,t){if(this.__b){if(this.__v.__k){var n=document.createElement("div"),s=this.__v.__k[0].__c;this.__v.__k[0]=$u(this.__b,n,s.__O=s.__P)}this.__b=null}var r=t.__a&&ar(Q,null,e.fallback);return r&&(r.__u&=-33),[ar(Q,null,t.__a?null:e.children),r]};var bl=function(e,t,n){if(++n[1]===n[0]&&e.l.delete(t),e.props.revealOrder&&(e.props.revealOrder[0]!=="t"||!e.l.size))for(n=e.i;n;){for(;n.length>3;)n.pop()();if(n[1]<n[0])break;e.i=n=n[2]}};function e_(e){return this.getChildContext=function(){return e.context},e.children}function t_(e){var t=this,n=e.h;t.componentWillUnmount=function(){Ds(null,t.v),t.v=null,t.h=null},t.h&&t.h!==n&&t.componentWillUnmount(),t.v||(t.h=n,t.v={nodeType:1,parentNode:n,childNodes:[],contains:function(){return!0},appendChild:function(s){this.childNodes.push(s),t.h.appendChild(s)},insertBefore:function(s,r){this.childNodes.push(s),t.h.insertBefore(s,r)},removeChild:function(s){this.childNodes.splice(this.childNodes.indexOf(s)>>>1,1),t.h.removeChild(s)}}),Ds(ar(e_,{context:t.context},e.__v),t.v)}function Hu(e,t){var n=ar(t_,{__v:e,h:t});return n.containerInfo=t,n}(Io.prototype=new yn).__a=function(e){var t=this,n=Wu(t.__v),s=t.l.get(e);return s[0]++,function(r){var a=function(){t.props.revealOrder?(s.push(r),bl(t,e,s)):r()};n?n(a):a()}},Io.prototype.render=function(e){this.i=null,this.l=new Map;var t=Mn(e.children);e.revealOrder&&e.revealOrder[0]==="b"&&t.reverse();for(var n=t.length;n--;)this.l.set(t[n],this.i=[1,0,this.i]);return e.children},Io.prototype.componentDidUpdate=Io.prototype.componentDidMount=function(){var e=this;this.l.forEach(function(t,n){bl(e,n,t)})};var n_=typeof Symbol<"u"&&Symbol.for&&Symbol.for("react.element")||60103,s_=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,r_=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,o_=/[A-Z0-9]/g,i_=typeof document<"u",a_=function(e){return(typeof Symbol<"u"&&typeof Symbol()=="symbol"?/fil|che|rad/:/fil|che|ra/).test(e)};yn.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(e){Object.defineProperty(yn.prototype,e,{configurable:!0,get:function(){return this["UNSAFE_"+e]},set:function(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,value:t})}})});var Ol=fe.event;function c_(){}function l_(){return this.cancelBubble}function d_(){return this.defaultPrevented}fe.event=function(e){return Ol&&(e=Ol(e)),e.persist=c_,e.isPropagationStopped=l_,e.isDefaultPrevented=d_,e.nativeEvent=e};var u_={enumerable:!1,configurable:!0,get:function(){return this.class}},Il=fe.vnode;fe.vnode=function(e){typeof e.type=="string"&&function(t){var n=t.props,s=t.type,r={},a=s.indexOf("-")===-1;for(var o in n){var c=n[o];if(!(o==="value"&&"defaultValue"in n&&c==null||i_&&o==="children"&&s==="noscript"||o==="class"||o==="className")){var d=o.toLowerCase();o==="defaultValue"&&"value"in n&&n.value==null?o="value":o==="download"&&c===!0?c="":d==="translate"&&c==="no"?c=!1:d[0]==="o"&&d[1]==="n"?d==="ondoubleclick"?o="ondblclick":d!=="onchange"||s!=="input"&&s!=="textarea"||a_(n.type)?d==="onfocus"?o="onfocusin":d==="onblur"?o="onfocusout":r_.test(o)&&(o=d):d=o="oninput":a&&s_.test(o)?o=o.replace(o_,"-$&").toLowerCase():c===null&&(c=void 0),d==="oninput"&&r[o=d]&&(o="oninputCapture"),r[o]=c}}s=="select"&&r.multiple&&Array.isArray(r.value)&&(r.value=Mn(n.children).forEach(function(l){l.props.selected=r.value.indexOf(l.props.value)!=-1})),s=="select"&&r.defaultValue!=null&&(r.value=Mn(n.children).forEach(function(l){l.props.selected=r.multiple?r.defaultValue.indexOf(l.props.value)!=-1:r.defaultValue==l.props.value})),n.class&&!n.className?(r.class=n.class,Object.defineProperty(r,"className",u_)):(n.className&&!n.class||n.class&&n.className)&&(r.class=r.className=n.className),t.props=r}(e),e.$$typeof=n_,Il&&Il(e)};var Pl=fe.__r;fe.__r=function(e){Pl&&Pl(e),e.__c};var kl=fe.diffed;fe.diffed=function(e){kl&&kl(e);var t=e.props,n=e.__e;n!=null&&e.type==="textarea"&&"value"in t&&t.value!==n.value&&(n.value=t.value==null?"":t.value)};function h_({el:e,className:t,stronger:n,strongest:s,variant:r,medium:a,large:o,testId:c,wide:d,children:l}){const h=e||"p",u=A(()=>({[`${at}--${O.CAPTION}`]:r===O.CAPTION,[`${at}--${O.CAPTION}-${Gt.WIDE}`]:r===O.CAPTION&&d,[`${at}--${O.CAPTION}-${Gt.STRONGER}`]:r===O.CAPTION&&n,[`${at}--${O.BODY}`]:r===O.BODY,[`${at}--${O.BODY}-${Gt.WIDE}`]:r===O.BODY&&d,[`${at}--${O.BODY}-${Gt.STRONGER}`]:r===O.BODY&&n,[`${at}--${O.BODY}-${Gt.STRONGEST}`]:r===O.BODY&&s,[`${at}--${O.SUBTITLE}`]:r===O.SUBTITLE,[`${at}--${O.SUBTITLE}-${Gt.STRONGER}`]:r===O.SUBTITLE&&n,[`${at}--${O.TITLE}`]:r===O.TITLE&&!a&&!o,[`${at}--${O.TITLE}-${Gt.MEDIUM}`]:r===O.TITLE&&a,[`${at}--${O.TITLE}-${Gt.LARGE}`]:r===O.TITLE&&o}),[r,d,n,a,o,s]);return i(h,{className:M([`${at}`,u,t]),"data-testid":c,children:l})}const I=Ue(h_),Gu=hs({i18n:new bi().i18n,loadingContext:"",commonProps:{},updateCore:he,componentRef:{current:null}}),H=()=>ps(Gu),p_="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='223'%20height='169'%20fill='none'%20viewBox='0%200%20223%20169'%3e%3cpath%20fill='%23EAB1A0'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M36.6%20112.2c.6-.1%201-.7%201-1.3l-.9-8.7%202.1%206.6c.2.6.8.8%201.4.7.6-.1%201-.7.8-1.2l-1.3-6.8%202.9-4.8-5.9-5.5-7.6%209%205%204.7%201%206.2c0%20.7.7%201.2%201.5%201Z'/%3e%3cpath%20fill='%23EAB1A0'%20d='M31.7%20103.6c.3.4%201.2%206.6%201.5%209%200%20.5.6%201%201.1%201h.3c.7%200%201.2-.6%201.1-1.3l-.7-9.1'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M31.7%20103.6c.3.4%201.2%206.6%201.5%209%200%20.5.6%201%201.1%201h.3c.7%200%201.2-.6%201.1-1.3l-.7-9.1'/%3e%3cpath%20fill='%23EAB1A0'%20d='M30.4%2099.3v13.1c0%20.6.5%201.1%201.2%201.1.5%200%201-.4%201-1l1.2-9.3'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M30.4%2099.3v13.1c0%20.6.5%201.1%201.2%201.1.5%200%201-.4%201-1l1.2-9.3'/%3e%3cpath%20fill='%23EAB1A0'%20d='M35.8%2092s-6.5%204.8-6.6%206.2a995%20995%200%200%200-.9%2010.3c1.5%200%202.8-1%203.2-2.3.6-2.1%201.2-4.9%201-5.1-.1-.3%205-.7%205.8-3.8'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M35.8%2092s-6.5%204.8-6.6%206.2a995%20995%200%200%200-.9%2010.3c1.5%200%202.8-1%203.2-2.3.6-2.1%201.2-4.9%201-5.1-.1-.3%205-.7%205.8-3.8'/%3e%3cpath%20fill='%233300C2'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M95.3%2046.7S78%2053%2070.5%2059.4c-7.6%206.4-36.1%2031.2-36.1%2031.2l11.2%2011%2038-27.3c3.5-2.6%2011.7-27.6%2011.7-27.6Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='m45.6%20101.7-11.2-11%2029.8-2.5-18.6%2013.5ZM186.4%2090.4h-7.1v25.3h7.1V90.4ZM215.6%2066.7h-7.2V92h7.2V66.7ZM173.7%20167.8h-7l8.3-44h7l-8.3%2044ZM26.3%20167.8h-7l8.3-44h7l-8.3%2044ZM209.2%20167.8h-7l-8.3-44h7l8.3%2044ZM68%2091.1h-7v25h7V91Z'/%3e%3cpath%20fill='%23F3F6F9'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M208.4%2066.7H39V92h169.3V66.7Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M208.4%20123.4v-7.6H39v7.6h169.5Z'/%3e%3cpath%20fill='%23F3F6F9'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M193.7%20123.4V116H15.3v7.5h178.4Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M77.4%20167.8h-7l-8.3-44h7l8.3%2044ZM42.2%20150.4l-.8%203h16.2l.7-3.1h-16ZM80.1%20150.3l1.4%203h15.1l-1-3H80Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='m97.8%20115.9-28.4.1-7.7%2034.7h-23l9.5-40.6a18%2018%200%200%201%2016.7-12l54-.5-.5%202.6c-2%209.1-10.6%2015.6-20.6%2015.7Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M110.7%20115.9H85.5L99%20150.3h-25L62.9%20117c-3-9%203.6-18.6%2013.6-19.4h.8l54.5-1.3-.6%203.9a20.7%2020.7%200%200%201-20.4%2015.7Z'/%3e%3cpath%20fill='%23F3F6F9'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M57.6%20153.4H41.4l-.8%202.7-16.8%204.2c-2%20.7-3.7%202.1-4.7%203.9H55l2.6-10.8ZM96.6%20153.4H81.5l1.3%202.9-15.2%204c-2%20.7-3.6%202.1-4.6%203.8h37.3l-3.7-10.7Z'/%3e%3cpath%20fill='%23fff'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='m54%20168%201-3.8H19a8%208%200%200%200-1%203.8h36ZM101.7%20168l-1.3-3.8H63a8%208%200%200%200-1%203.8h39.6Z'/%3e%3cpath%20fill='%233300C2'%20d='M86.9%2059.6c.3%2020-5.4%2037.7-5.4%2037.7l50.3-.1s4.7-18.7%202-31c-2.6-12.3-16.2-21.8-22.5-22.3-6.2-.6-20.6%204.6-20.6%204.6'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M86.9%2059.6c.3%2020-5.4%2037.7-5.4%2037.7l50.3-.1s4.7-18.7%202-31c-2.6-12.3-16.2-21.8-22.5-22.3-6.2-.6-20.6%204.6-20.6%204.6'/%3e%3cpath%20fill='%23fff'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M96.7%2047.1s.6%205.5%202%209c1.2%203.6%202%207.3%202%207.3s6.8-17.5%208.3-19.6c0%200-8%206.5-12.3%203.3Z'/%3e%3cpath%20fill='%23EAB1A0'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='m105.8%2038.3%203.1%205.5s-4%206.8-8.6%206.7c-4.7%200-3.5-5.6-3.5-5.6l9-6.6Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='m101.8%2044.7-4%204.9-1-2.5%205-2.4ZM97%2083.1H85.6l-3.3-17.9h11.1l3.4%2017.9Z'/%3e%3cpath%20fill='%23EAB1A0'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M101.6%2082.6c-1-1.6-2.3-3-3.2-4.5-1.2-2-1.7-4.5-2.3-6.8-2.5-.7-2.6%204-2.4%206%20.3%201.8%201%203.7%201%203.7-2-.4-10.4-4.7-10.4-4.7.3%200-1.4%202.3-.7%203.3l1%201.3s-.7%201.3-.7%202c-.1%201.2%201.1%202.2%201.1%202.2l.1%202.3c.2.8%201.5%201.5%201.5%201.5s0%201.4.7%201.8c.7.3%2011.2%201.2%2015.8%201.4%200-1.6.5-3.4.3-5%200-1.5-1-3.2-1.8-4.5Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M111.7%2021.9c.4.8-.2%201.8-1%202.4-.7.5-1.7.7-2.6%201%201.2-.4%202.6-.2%203.8.2.4.2.8.4%201%20.7.3.5.1%201.2-.2%201.6-.3.4-.8.8-1.3%201-1.4.7-3%201.2-4.5%201.3%201%200%201.5%201.1%201.1%201.9-.4.8-1.3%201.2-2.2%201.4-1.5.4-3.3.4-4.5-.4-.7-.4-1.1-1-1.5-1.5a7%207%200%200%201-.2-7.4%209%209%200%200%201%205.7-3.8c1.7-.3%205.6-.3%206.4%201.6Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M68.7%2025c.5%201.7%203%202%204.6%201.3-1.2.2-2.4.4-3.3%201.2-1%20.9-1.1%202.4-.1%203%20.3.3.8.4%201.3.4a9%209%200%200%200%204.6-1c-1%20.6-2%201.9-1.3%203%20.6.9%202.2.8%203.2.2%201-.6%202-1.5%203-1.8-.6.4-1.3.8-1.5%201.5-.3.6%200%201.6.6%201.7.5.1%201%200%201.4-.2%201.1-.6%202.2-1.3%203-2.3-1%20.3-.8%201.9.1%202.3%201%20.4%202%200%203-.6a8.5%208.5%200%200%200%202.8-3c-.3.4%200%201.1.6%201.5%201%20.6%202.4.7%203.5.3a9%209%200%200%200%203-2%207%207%200%200%200%202-2.4c.6-1.4.2-3-.7-4.2A10%2010%200%200%200%2095%2021c-4.3-2.3-9.8-3-14.6-1.7a6.6%206.6%200%200%200-6.8-2c-.7.3-1.5.7-1.8%201.4-.5%201.2.5%202.3%201.6%202.8-2%200-5.4%201-4.6%203.5Z'/%3e%3cpath%20fill='%23EAB1A0'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M80.6%2027.7c.7-.7%2010.6-6.8%2010.6-6.8l10.2%203.8%204.8%209.1v.2c.9%207.4-3.1%2010.5-8.8%2013.2-5%202.4-16-1.6-16.9-19.4%200%200%200%200%200%200Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M70.3%2017.3c-.3-.9-.3-1.8.2-2.4.5-.5%201.2-.7%201.9-.6.7%200%201.3.4%201.9.7-.9-.8-.3-2.3.8-2.7%201.1-.3%202.4.1%203.2%201%20.5.4%201%204.3%201.5%204.4.6.1%201%200%201.5-.2%202.4-.9%205-1.5%207.4-1.8%201.9-.3%203.8-.4%205.6-.2%202.1.3%204.2%201%206.2%201.9v0c3.4.2%207.4%2010.5%206.4%2010.8-.9.2.2%200-.1.1-2.1.7-6.4-.7-7.6-1.1a12%2012%200%200%201-3.1-2.1c-1.8-1.4-4-2.2-6.2-2.6l-1.4-.2c-1.8.7-3.8%201-5.8.7-.7%200-1.5-.3-2-.8-.3-.4-.3-1.2.2-1.5-1%20.5-2.1.7-3.3.7-.7%200-1.6%200-2.2-.7-.6-.5-.5-1.6.3-1.8-1.3.3-2.8.7-4%200-.7-.5-1.2-.7-1.4-1.6Z'/%3e%3cpath%20fill='%23EAB1A0'%20d='M100%2027.8c-.6-1.7.7-4.3%202.4-4.6%202.6-.5%204%202%204.5%204%20.5%201.8.6%203.8-.2%205.6-.3.5-.6%201-1.2%201.4'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M100%2027.8c-.6-1.7.7-4.3%202.4-4.6%202.6-.5%204%202%204.5%204%20.5%201.8.6%203.8-.2%205.6-.3.5-.6%201-1.2%201.4'/%3e%3cpath%20fill='%23F3F6F9'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M96.8%207.7c2%200%203.6-1.5%203.6-3.4%200-1.8-1.6-3.3-3.6-3.3s-3.6%201.5-3.6%203.3c0%201.9%201.6%203.4%203.6%203.4Z'/%3e%3cpath%20fill='%23F3F6F9'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M107.4%2022.1c0-.1%200-3.3-1.5-7.5-1.6-4-4.9-9.1-11.6-10.4-8.2-1.2-13.2%204-15.4%207.3-2.3%203.2-2.4%205.3-2.4%205.3a67%2067%200%200%201%2030.9%205.3Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M93.3%2017.9c.7-.9.4-2.2-.6-2.7-1-.4-2.4.2-2.7%201.2.7-.9.4-2.2-.5-2.9-.9-.7-2.3-.7-3.2%200-1%20.6-1.3%201.9-1%202.9%200-.7%200-1.5-.2-2.1-.3-.7-1-1.3-1.7-1.3-.5%200-1%20.2-1.4.5a3%203%200%200%200-1%203c-.3-1-.5-2.1-1.2-3-.7-1-1.8-1.6-3-1.4-1%20.2-2%201.3-2%202.3%200%201%20.7%202%201.5%202.7.1%200%2014.6%204%2017%20.8Z'/%3e%3cpath%20fill='%233300C2'%20d='M128%2054.8s22%2026.5%2018.9%2037.8c-2%206.7-47%204.9-47%204.9l2.5-14.3%2023.7-1.5-9.7-12.5'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M128%2054.8s22%2026.5%2018.9%2037.8c-2%206.7-47%204.9-47%204.9l2.5-14.3%2023.7-1.5-9.7-12.5'/%3e%3cpath%20fill='%23fff'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M57.4%201.4H1v29.4h33.2L48.9%2045l-.2-14.2h8.7V1.4Z'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M2.3%20168h219.4'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='M29.2%2026.3c6.2%200%2011.3-4.7%2011.3-10.5S35.4%205.2%2029.2%205.2C23%205.2%2017.9%2010%2017.9%2015.8s5%2010.5%2011.3%2010.5Z'/%3e%3cpath%20stroke='%23fff'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20stroke-width='.6'%20d='m25.2%2012%208%207.5M33.2%2012l-8%207.5'/%3e%3c/svg%3e",Cn=e=>_r(e),Jo=(()=>{const e=new Set,t=(s,r,a,o)=>{let c=o==null?void 0:o[a];return c=ee(c)?c:fo,!ds(c(s[a]),c(r[a]))};return Object.defineProperty(s=>(r,a)=>{try{for(const o in r)if(e.add(o),t(r,a,o,s))return!1;for(const o in a)if(!e.has(o)&&(e.add(o),t(r,a,o,s)))return!1;return!0}finally{e.clear()}},"exclude",{value:he})})(),wl=/^\s+|\s+(?=\s|$)/g,rs=(e,t)=>(t?typeof t=="string"?t:(t==null?void 0:t.value)??"":"").replace(wl,"")||e.replace(wl,"")||void 0,ei=(e,t,n)=>M(rs("",n),rs(rs("",t)||"",e)),Tc=(e,t=[],n=[])=>M([...n,...t==null?void 0:t.map(s=>e?`${e}--${s}`:s)]),Ii=e=>As(e,(e==null?void 0:e.value)??e),mt="adyen-pe-button",f_="adyen-pe-button__anchor",Ma=`${mt}-actions`,m_=`${mt}--icon`,__=`${mt}--icon-content`,g_=`${Ma}__container-wrapper`,Yu=`${mt}__label`,T_=`${mt}__icon-right`,y_=`${mt}__icon-left`,A_=`${mt}--condensed`,v_=`${mt}--full-width`,R_=`${mt}--loading`,C_=`${Yu}--centered`,qu=({inline:e=!1,size:t="large"})=>i("div",{className:`adyen-pe-spinner__wrapper ${e?"adyen-pe-spinner__wrapper--inline":""}`,children:i("div",{className:`adyen-pe-spinner adyen-pe-spinner--${t}`})}),Pi=(e,t,n,s,r,a)=>{const{children:o,iconLeft:c,iconRight:d,iconButton:l=!1,fullWidth:h,condensed:u,state:p="default"}=r,f=C(_=>{_.preventDefault(),s||a==null||a(_)},[s,a]),T=A(()=>Tc(n,t,[n,e]),[n,t,e]),g=A(()=>({...r,className:M(T,{[m_]:l,[A_]:u,[v_]:h,[R_]:p==="loading"}),disabled:s||p==="loading"}),[T,u,s,h,l,r,p]),y=A(()=>l?i("div",{className:`${__}`,children:o}):i(Q,{children:[p==="loading"&&i(qu,{size:"x-small"}),c&&i("span",{className:y_,children:c}),i(I,{className:M(Yu,{[C_]:r.align==="center"}),el:J.SPAN,variant:O.BODY,children:o}),d&&i("span",{className:T_,children:d})]}),[o,l,c,d,r.align,p]);return{classes:T,click:f,allChildren:y,allProps:g}};var te=(e=>(e.PRIMARY="primary",e.SECONDARY="secondary",e.TERTIARY="tertiary",e.TERTIARY_WITH_BACKGROUND="tertiary-with-background",e.LINK="link",e))(te||{});function S_(e,t){const n=A(()=>rs("",e.className)||"",[e.className]),s=A(()=>Ii(e.disabled||!1),[e.disabled]),{click:r,allChildren:a,allProps:o}=Pi(n,[...e.classNameModifiers||[],e.variant||te.PRIMARY],mt,s,e,e.onClick),{classNameModifiers:c,...d}=o;return i("button",{...d,ref:t,type:e.type||"button",onClick:r,children:a})}const _e=Cn(S_),Ll={md:680},Qt=({title:e,message:t,imageDesktop:n,imageMobile:s,withImage:r,centered:a,refreshComponent:o,onContactSupport:c,translationValues:d,absolutePosition:l=!0,outlined:h=!0,renderSecondaryButton:u,withBackground:p})=>{const{i18n:f,updateCore:T}=H(),g=C(y=>Array.isArray(y)?y.map((_,v)=>v===0?i(Q,{children:[f.get(_),d&&d[_]&&i(Q,{children:d[_]})]}):i(Q,{children:[i("br",{}),f.get(_),d&&d[_]&&i(Q,{children:d[_]})]})):f.get(y),[f,d]);return i("div",{className:M(["adyen-pe-error-message-display"],{"adyen-pe-error-message-display--absolute-position":l,"adyen-pe-error-message-display--outlined":h,"adyen-pe-error-message-display--with-background":p!==!1&&!h,"adyen-pe-error-message-display--centered":a}),children:[(n||s||r)&&i("div",{className:"adyen-pe-error-message-display__illustration",children:i("picture",{children:[i("source",{type:"image/svg+xml",media:`(min-width: ${Ll.md}px)`,srcSet:n}),i("source",{type:"image/svg+xml",media:`(max-width: ${Ll.md}px)`,srcSet:s}),i("img",{srcSet:n??p_,alt:f.get("thereWasAnUnexpectedError")})]})}),i(I,{variant:O.TITLE,children:f.get(e)}),t&&i(I,{variant:O.BODY,children:g(t)}),(c||o||u)&&i("div",{className:"adyen-pe-error-message-display__button",children:[u&&u(),c&&i(_e,{onClick:c,children:f.get("reachOutToSupport")}),!c&&o&&i(_e,{onClick:T,children:f.get("refresh")})]})]})},an=(e,t)=>ee(e.endpoints[t]),ua={transactions:e=>an(e,"getTransactions"),transactionDetails:e=>an(e,"getTransaction"),payouts:e=>an(e,"getPayouts"),payoutDetails:e=>an(e,"getPayout"),reports:e=>an(e,"getReports"),capitalOverview:e=>an(e,"getDynamicGrantOffersConfiguration"),capitalOffer:e=>an(e,"getDynamicGrantOffer"),disputes:e=>an(e,"getDisputeList"),disputesManagement:e=>an(e,"getDisputeDetail")},ju=async e=>{const t=Kd(),n=t.promise,s=e.context.refreshing;let r,a,o=e.subscribe(c=>{if(us(c)){t.resolve();return}if(r??(r=e.context.refreshing),!e.context.refreshing){if(en(e.context.isExpired)&&(a??(a=!(s||r)))){a=!1,e.refresh();return}t.resolve()}});return n.finally(()=>{o(),o=null}),n},E_=async(e,t)=>{var n;return await ju(t),Ve(await((n=ua[e])==null?void 0:n.call(ua,t.context)))},N_=e=>{switch(e){case"payouts":return"weCouldNotLoadThePayoutsOverview";case"transactions":return"weCouldNotLoadTheTransactionsOverview";case"transactionDetails":return"weCouldNotLoadYourTransactions";case"payoutDetails":return"weCouldNotLoadYourPayouts";case"reports":return"weCouldNotLoadTheReportsOverview";default:return"somethingWentWrong"}},Vu=hs({endpoints:z,extraConfig:z,hasError:!1,http:pf,isExpired:void 0,isFrozen:!1,refresh:he,refreshing:!1}),D_=({children:e,session:t,type:n})=>{const{http:s,refresh:r}=A(()=>t,[t]),[,a]=F(0),[o,c]=F(0),[d,l]=F();return G(()=>{E_(n,t).then(l)},[t,n]),G(()=>t.subscribe(h=>{(us(h)?c:a)(p=>p+1)}),[o]),i(Vu.Provider,{value:{...t.context,http:s,refresh:r},children:!oe(d)&&(d?Mn(e):i(Qt,{withImage:!0,centered:!0,title:"somethingWentWrong",message:[N_(n),"contactSupportForHelp"]}))})},Ee=()=>ps(Vu),Vt=(e=!1)=>{const[t,n]=F(e),s=C(a=>n(a),[]),r=C(()=>n(a=>!a),[]);return[t,s,r]},b_=({i18n:e=new bi().i18n,children:t,commonProps:n,loadingContext:s,updateCore:r,externalErrorHandler:a,componentRef:o})=>{const[c,d]=Vt(!1),l=A(()=>n||{},[n]),h=A(()=>s??"",[s]);return G(()=>{(async()=>{await(e==null?void 0:e.ready),d(!0)})().catch()},[]),c?i(Gu.Provider,{value:{i18n:e,commonProps:l,loadingContext:h,updateCore:r,externalErrorHandler:a,componentRef:o},children:Mn(t)}):null};var Ud;class zu{constructor(t){Y(this,"_component");Y(this,"_node",null);Y(this,"_id",`${(Ud=this.constructor)==null?void 0:Ud.type}-${Si()}`);Y(this,"defaultProps",{});Y(this,"props");Y(this,"state",{});this.props=this.formatProps({...this==null?void 0:this.defaultProps,...t}),this.props.core.registerComponent(this)}formatProps(t){return t}formatData(){return{}}setState(t){this.state={...this.state,...t}}get data(){return{...this.formatData(),clientStateDataIndicator:!0}}render(){throw new Error("Component cannot be rendered.")}mount(t){const n=Dt(t)?document.querySelector(t):t;if(!n)throw new Error("Component could not mount. Root node was not found.");return this._node&&this.unmount(),this._node=n,this._component=this.render(),Ds(this._component,n),this}update(t){return this.props=this.formatProps({...this.props,...t}),this._component=this.render(),this._node&&Ds(this._component,this._node),this}remount(t){if(!this._node)throw new Error("Component is not mounted.");const n=t||this.render();return Ds(n,this._node),this}unmount(){return this._node&&Ds(null,this._node),this}remove(){this.unmount(),this.props.core.remove(this)}}Y(zu,"type");class Sn extends zu{constructor(n){super(n);Y(this,"componentRef",null);Y(this,"componentToRender",null);Y(this,"elementRef");Y(this,"onContactSupport");Y(this,"customClassNames");Y(this,"compRef");Y(this,"setUIElementStatus");this.setState=this.setState.bind(this),this.onContactSupport=n.onContactSupport,this.elementRef=this,this.compRef=G2()}get isValid(){return!!this.state.isValid}get displayName(){return this.type}get accessibleName(){return this.displayName}get type(){var n;return(n=this.constructor)==null?void 0:n.type}formatProps(n){return n}formatData(){return{...this.state}}setState(n){this.state={...this.state,...n}}setStatus(n,s){var r,a;return(r=this.componentRef)!=null&&r.setStatus?this.componentRef.setStatus(n,s):(a=this.setUIElementStatus)==null||a.call(this,n),this}render(){const n=this.props.core,s=n.update.bind(n),r=this.props.onError||n.onError||null;return n.session.errorHandler=r,i(D_,{type:this.type,session:n.session,children:i(b_,{i18n:n.localization.i18n,loadingContext:n.loadingContext,updateCore:s,externalErrorHandler:r,componentRef:this.compRef,children:this.componentToRender&&i("div",{ref:this.compRef,className:M("adyen-pe-component",this.customClassNames),children:i("div",{className:"adyen-pe-component__container",children:this.componentToRender()})})})},performance.now())}}function bt({fetchOptions:{keepPrevData:e,onSuccess:t,enabled:n}={keepPrevData:!0},queryFn:s}){const r=q(!1),a={error:void 0,data:void 0,isFetching:en(n)},o=(h,u)=>{switch(u.type){case"loading":return{...a,isFetching:!0,data:e?h.data:void 0};case"fetched":return{...a,data:u.payload,isFetching:!1};case"error":return{...a,error:u.payload,isFetching:!1};default:return h}},[c,d]=Oi(o,a),l=C(async()=>{d({type:"loading"});try{if(r.current)return;const h=await s();t==null||t(h),d({type:"fetched",payload:h})}catch(h){if(r.current)return;d({type:"error",payload:h})}},[d,s,t]);return G(()=>(r.current=!1,en(n)&&l(),()=>{r.current=!0}),[n,l]),c}const yc="adyen-pe-accordion",Ac=yc+"__header",O_=Ac+"-container",I_=Ac+"-controller",P_=yc+"__content",Fl={"angle-right":()=>Promise.resolve().then(()=>require("./angle-right-BYzD_-Ft.cjs")),"checkmark-circle-fill":()=>Promise.resolve().then(()=>require("./checkmark-circle-fill-B2FBCXMi.cjs")),"checkmark-square-fill":()=>Promise.resolve().then(()=>require("./checkmark-square-fill-C0yzqh08.cjs")),checkmark:()=>Promise.resolve().then(()=>require("./checkmark-BvN7Hdc4.cjs")),"chevron-down":()=>Promise.resolve().then(()=>require("./chevron-down-Bh5iG-g7.cjs")),"chevron-left":()=>Promise.resolve().then(()=>require("./chevron-left-CslKDyxG.cjs")),"chevron-right":()=>Promise.resolve().then(()=>require("./chevron-right-B86-08tq.cjs")),"chevron-up":()=>Promise.resolve().then(()=>require("./chevron-up-DRKXzgCM.cjs")),copy:()=>Promise.resolve().then(()=>require("./copy--wgagwiQ.cjs")),"cross-circle-fill":()=>Promise.resolve().then(()=>require("./cross-circle-fill-CNa1fp55.cjs")),cross:()=>Promise.resolve().then(()=>require("./cross-BWhI1OkU.cjs")),download:()=>Promise.resolve().then(()=>require("./download-v3aQcc7_.cjs")),"external-link":()=>Promise.resolve().then(()=>require("./external-link-Y0ITwX_D.cjs")),filter:()=>Promise.resolve().then(()=>require("./filter-B0jf9LNT.cjs")),"info-filled":()=>Promise.resolve().then(()=>require("./info-filled-DWI7yYIK.cjs")),"minus-circle-outline":()=>Promise.resolve().then(()=>require("./minus-circle-outline-TX4FRKCq.cjs")),plus:()=>Promise.resolve().then(()=>require("./plus-WkQleJCL.cjs")),"plus-circle-outline":()=>Promise.resolve().then(()=>require("./plus-circle-outline-BSbUWJEJ.cjs")),square:()=>Promise.resolve().then(()=>require("./square-wBNy5hkk.cjs")),"trash-can":()=>Promise.resolve().then(()=>require("./trash-can-BtOHiu0D.cjs")),upload:()=>Promise.resolve().then(()=>require("./upload-CwRQ9v3Y.cjs")),"warning-filled":()=>Promise.resolve().then(()=>require("./warning-filled-Ctsg1oEC.cjs")),warning:()=>Promise.resolve().then(()=>require("./warning-DBphva9h.cjs"))},ue=({className:e,name:t,...n})=>{const[s,r]=F(null);return G(()=>{Fl[t]?Fl[t]().then(({default:a})=>{r(i(a,{}))}):(r(null),console.error(`Icon with name "${t}" does not exist.`))},[t]),s&&i("span",{className:M("adyen-pe-icon",e),role:"img","aria-hidden":!0,...n,children:s})};function Ml({children:e,classNames:t,header:n,headerInformation:s}){var d;const[r,a]=F(!1),o=q(null),c=C(()=>{a(!r)},[r]);return i("div",{className:M(yc,t),children:[i("h3",{className:Ac,children:[i("button",{id:"accordion-controller","aria-controls":"accordion-content",className:O_,onClick:c,"aria-expanded":r,children:i("div",{className:I_,children:[n,r?i(ue,{name:"chevron-up"}):i(ue,{name:"chevron-down"})]})}),s&&i("div",{children:s})]}),i("div",{role:"region",id:"accordion-content","aria-labelledby":"accordion-controller",style:{maxHeight:r?(d=o==null?void 0:o.current)==null?void 0:d.offsetHeight:0},className:P_,children:i("div",{ref:o,children:e})})]})}var ne=(e=>(e.ARROW_DOWN="ArrowDown",e.ARROW_LEFT="ArrowLeft",e.ARROW_RIGHT="ArrowRight",e.ARROW_UP="ArrowUp",e.BACKSPACE="Backspace",e.END="End",e.ENTER="Enter",e.ESCAPE="Escape",e.HOME="Home",e.PAGE_DOWN="PageDown",e.PAGE_UP="PageUp",e.SPACE="Space",e.TAB="Tab",e))(ne||{}),re=(e=>(e.BALANCE_ACCOUNT="balanceAccount",e.CATEGORIES="categories",e.CURRENCIES="currencies",e.CREATED_SINCE="createdSince",e.CREATED_UNTIL="createdUntil",e.STATUSES="statuses",e.MIN_AMOUNT="minAmount",e.MAX_AMOUNT="maxAmount",e))(re||{});const It="adyen-pe-card",k_=`${It}--expandable`,w_=`${It}__toggle`,Ku=`${It}__body`,Xu=`${It}__header`,L_=`${It}__title`,F_=`${It}__subtitle`,M_=`${Xu}-content`,x_=`${Ku}--with-title`,B_=`${It}--no-outline`,$_=`${It}--no-padding`,U_=`${It}--filled`,W_=`${It}__footer`,H_=`${It}--compact`,kr=({title:e,subTitle:t,children:n,expandable:s=!1,footer:r,el:a,renderHeader:o,renderFooter:c,filled:d,noOutline:l,noPadding:h,classNameModifiers:u,testId:p,compact:f})=>{const T=a||"header",[g,y]=F(!1),_=A(()=>Si(),[]),v=C(()=>{s&&y(D=>!D)},[s]),N=C(D=>{switch(D.code){case ne.ENTER:case ne.SPACE:D.preventDefault(),v();return}},[v]),S=A(()=>s?{role:"button",tabIndex:0,onClick:v,onKeyDown:N,"aria-controls":_,"aria-expanded":g}:{},[s,g,_,N,v]);return i("section",{"data-testid":p,className:M(It,u,{[U_]:d,[B_]:l,[$_]:h,[k_]:s,[H_]:f}),...S,children:[(e||o)&&i(T,{className:M(Xu),children:i("div",{className:M(M_),children:[s&&i(ue,{name:g?"chevron-up":"chevron-down",className:w_,role:"presentation"}),o||i("span",{className:L_,children:e}),t&&i("div",{className:F_,children:t})]})}),(!s||g)&&i("div",{id:_,className:M(Ku,{[x_]:e||o}),children:n}),(r||c)&&i("footer",{className:W_,children:c||r})]})},xa="2-digit",ki="long",Ba="numeric",vc="short",Rc="shortOffset",xn={month:ki,day:Ba,year:Ba},Zu={hour:xa,minute:xa},Cc={...xn,...Zu,month:vc,hour12:!1},Qu={...Cc,year:void 0},G_={...xn,month:"short"},Y_={...xn,month:"long"},q_=xn,j_=Qu,V_={...xn,weekday:ki},xl={...xn,month:vc},z_=Cc,K_=Qu,X_={...xn,...Zu,weekday:ki,timeZoneName:Rc},Bl=xn,Ar={...Cc,hour12:!0,timeZoneName:Rc},Z_={month:vc,weekday:ki,hour:xa,minute:Ba,year:void 0,timeZoneName:Rc},Ht={sm:480,md:768,lg:1024},gr="adyen-pe-structured-list",Q_=`${gr}--align-end`,Ju=`${gr}__item`,$l=`${gr}__grid`,J_=`${gr}__content`,eg=`${gr}__label`,tg=`${Ju}--has-highlight`,ng=e=>{const{i18n:t}=H();return A(()=>e.map(n=>({key:n.key,value:n.value,id:Si(),label:t.get(n.key),type:n.type,config:n.config})),[t,e])},sg="6-6";function gn({items:e,highlightable:t,renderValue:n,renderLabel:s,layout:r=sg,grid:a=!0,classNames:o,align:c="end"}){const[d,l]=A(()=>r.split("-").map(p=>`${$l}--width-${p}-of-12`),[r]),h=ng(e),{i18n:u}=H();return i("dl",{"aria-label":u.get("structuredList"),className:M(gr,o,{[Q_]:c==="end"}),children:h.map((p,f)=>i("div",{className:M(Ju,{[tg]:t,[$l]:a}),children:[i("dt",{className:M(eg,d),children:s?s(p.label,e[f].key):i(I,{variant:O.BODY,children:p.label})}),i("dd",{"aria-label":`${u.get(p.key)} ${u.get("value")}`,className:M(J_,l),children:n?n(p.value,p.key,p.type,p.config):i(I,{variant:O.BODY,children:p.value})})]},`${f}_${p.id||"0"}`))})}const eh="adyen-pe-overview-details",Sc=`${eh}__skeleton`,rg=`${Sc}-container`,og=`${Sc}--loading-content`,ig=`${eh}__status-skeleton`,ag=({skeletonRowNumber:e=0})=>{const t=M(Sc,og),n=Array.from({length:e}),s=Array.from({length:2});return i("div",{className:rg,children:[i("div",{className:ig,children:s.map((r,a)=>i("span",{className:t},`status-skeleton-${a}`))}),n.map((r,a)=>i("span",{className:t},`skeleton-${a}`))]})},Ec=Ue(ag),$a=e=>{const{i18n:t}=H();return C((...n)=>{const s=t.timezone;try{return e(...n)}finally{t.timezone=s}},[t,e])},cg=e=>{const{i18n:t}=H(),n=$a(C(()=>(t.timezone=void 0,t.timezone=e,t.timezone),[t,e]));return A(n,[n])},Pt=e=>{const{i18n:t}=H(),n=cg(e),s=$a(C((...a)=>(t.timezone=n,t.date(...a)),[t,n])),r=$a(C((...a)=>(t.timezone=n,t.fullDate(...a)),[t,n]));return{dateFormat:s,fullDateFormat:r}},Ut="adyen-pe-payout-data",lg=`${Ut}__title-container`,dg=`${Ut}__title`,ug=`${Ut}__title--with-extra-details`,hg=`${Ut}__title--ba-id`,Nc=`${Ut}__content`,pg=`${Ut}__extra-details`,fg=`${Ut}__extra-details-label`,mg=`${Ut}__extra-details-icon`,_g=`${Ut}__button-actions`,vs=`${Nc}--section`,Uo=`${Nc}--card`,Ul=`${Uo}-title`,wr=`${vs}-amount`,Wl=`${wr}-gross`,gg=`${wr}-net`,Tg=`${Ut}--unpaid-amount`;var Oe=(e=>(e.DEFAULT="default",e.WARNING="warning",e.ERROR="error",e.SUCCESS="success",e.WHITE="white",e.LIGHT="light",e.LIGHT_WITH_OUTLINE="light-with-outline",e.BLUE="blue",e))(Oe||{});const ot=Ue(({variant:e=Oe.DEFAULT,label:t,children:n})=>i("div",{className:M("adyen-pe-tag",{"adyen-pe-tag--success":e===Oe.SUCCESS,"adyen-pe-tag--default":e===Oe.DEFAULT,"adyen-pe-tag--warning":e===Oe.WARNING,"adyen-pe-tag--error":e===Oe.ERROR,"adyen-pe-tag--primary":e===Oe.WHITE,"adyen-pe-tag--light":e===Oe.LIGHT,"adyen-pe-tag--light-with-outline":e===Oe.LIGHT_WITH_OUTLINE,"adyen-pe-tag--blue":e===Oe.BLUE}),children:n||t}));function wi({href:e,children:t,variant:n="default",truncate:s,target:r="_blank",withIcon:a=!0,classNames:o=[],...c}){const d=C(l=>l.stopPropagation(),[]);return i("a",{className:M("adyen-pe-link",[...o],{[`adyen-pe-link--${n}`]:n!=="default","adyen-pe-link--truncate":s}),href:e,target:r,rel:"noopener noreferrer",onClick:d,...c,children:[i(I,{className:"adyen-pe-link__text",el:J.SPAN,variant:O.BODY,children:t}),a&&r==="_blank"&&i(ue,{name:"external-link"})]})}const Li=({className:e,alt:t,url:n})=>i("div",{className:"adyen-pe-data-grid__icon-container",children:i("img",{className:M("adyen-pe-data-grid__icon",e),alt:t,src:n})}),th=hs(z),Dc=()=>ps(th);function Hl({children:e,column:t,position:n,...s}){const{registerCells:r}=Dc(),a=q(null);return G(()=>{var o;a.current&&r({column:t,width:(o=a.current)==null?void 0:o.getBoundingClientRect().width})},[t,r]),i("div",{role:"cell",className:M("adyen-pe-data-grid__cell",{"adyen-pe-data-grid__cell--right":n==="right","adyen-pe-data-grid__cell--center":n==="center"}),...s,children:e&&Cu(e)?Fu(e,{...e==null?void 0:e.props,ref:a,style:{width:"min-content"}}):null})}const Jt=e=>!!e&&typeof e=="object"&&"value"in e,Gl=e=>!!e&&typeof e=="object"&&e.type==="icon",yg=e=>!!e&&typeof e=="object"&&e.type==="button",Ag=e=>!!e&&typeof e=="object"&&e.type==="link",nh=({columns:e,customCells:t,item:n,rowIndex:s})=>i(Q,{children:e.map(({key:r,position:a})=>{var u,p,f,T,g,y,_;if(t!=null&&t[r])return i(Hl,{"aria-labelledby":String(r),column:r,position:a,children:i("div",{style:{width:"min-content"},children:t[r]({key:r,value:n[r],item:n,rowIndex:s})})},r);const o=n[r],{value:c,type:d}=Jt(o)?o:{value:o,type:"text"},l=Gl(o)?{url:(u=o==null?void 0:o.config)==null?void 0:u.src,alt:((p=o==null?void 0:o.config)==null?void 0:p.alt)!==void 0&&((f=o==null?void 0:o.config)==null?void 0:f.alt)!==null?(T=o==null?void 0:o.config)==null?void 0:T.alt:o.value}:void 0,h=yg(o)?v=>{var N;v.stopPropagation(),(N=o==null?void 0:o.config)==null||N.action()}:void 0;return i(Hl,{"aria-labelledby":String(r),column:r,position:a,children:i("div",{className:"adyen-pe-data-grid__cell-value",children:[Gl(o)&&o.config&&(l==null?void 0:l.url)&&i("div",{className:M("adyen-pe-data-grid__icon-cell",(g=o==null?void 0:o.config)==null?void 0:g.className),children:[i(Li,{...l}),c.trim()&&i("span",{children:c})]}),d==="text"&&i("span",{className:M((y=o==null?void 0:o.config)==null?void 0:y.className),children:c}),d==="button"&&o.config&&h&&i(_e,{className:M((_=o.config)==null?void 0:_.className),onClick:h,variant:te.SECONDARY,children:c}),Ag(o)&&o.config&&i(wi,{classNames:o.config.className?[o.config.className]:[],href:o.config.href,target:o.config.target,children:c})]})},r)})});var Co=(e=>(e.BUTTONS_END="buttons-end",e.FILL_CONTAINER="fill-container",e.SPACE_BETWEEN="space-between",e.VERTICAL_STACK="vertical-stack",e))(Co||{}),sh=(e=>(e.BUTTONS_START="buttons-start",e))(sh||{});const vg={...Co,...sh};function Rg({actions:e,layout:t=vg.BUTTONS_END}){const n=()=>`${Ma}--${t}`,s=a=>{const o=e.length-1;return a===o?te.PRIMARY:te.SECONDARY},r=A(()=>[...e].reverse(),[e]);return i("div",{className:Ma,children:i("div",{className:`${g_} ${n()}`,role:"group",children:r.map((a,o)=>i(_e,{className:M(a.classNames),"aria-label":a.title,disabled:a.disabled,variant:a.variant||s(o),onClick:a.event,state:a.state??"default",children:a.renderTitle?a.renderTitle(a.title):a.title},`${o}_${a.title||"0"}`))})})}const fs=Ue(Rg),Cg=({balanceAccountId:e,balanceAccountDescription:t,payout:n,extraFields:s})=>{var p;const{payout:r}=n??z,{dateFormat:a}=Pt("UTC"),{i18n:o}=H(),c=A(()=>{var T,g;const f=(g=(T=n==null?void 0:n.amountBreakdowns)==null?void 0:T.adjustmentBreakdown)==null?void 0:g.reduce((y,_)=>{var R,b,E,P,w,W,x;const v=(R=_==null?void 0:_.amount)!=null&&R.value&&((b=_==null?void 0:_.amount)!=null&&b.currency)?o.amount((E=_==null?void 0:_.amount)==null?void 0:E.value,(P=_==null?void 0:_.amount)==null?void 0:P.currency,{hideCurrency:!0}):(((w=_==null?void 0:_.amount)==null?void 0:w.value)??"").toString(),N=`${_==null?void 0:_.category}`,S=o.get(N),D=_!=null&&_.category&&S!==N?S:_==null?void 0:_.category;return _!=null&&_.category&&v&&D&&y[(W=_==null?void 0:_.amount)!=null&&W.value&&((x=_==null?void 0:_.amount)==null?void 0:x.value)<0?"subtractions":"additions"].push({key:D,value:v}),y},{subtractions:[],additions:[]});return f==null||f.subtractions.sort((y,_)=>y.key.localeCompare(_.key)),f==null||f.additions.sort((y,_)=>y.key.localeCompare(_.key)),f},[o,n]),d=A(()=>{var T,g;const f=(g=(T=n==null?void 0:n.amountBreakdowns)==null?void 0:T.fundsCapturedBreakdown)==null?void 0:g.reduce((y,_)=>{var v,N,S,D;return((v=_==null?void 0:_.amount)==null?void 0:v.value)===0||(N=_==null?void 0:_.amount)!=null&&N.value&&_.category&&y.push({key:_.category,value:o.amount((S=_==null?void 0:_.amount)==null?void 0:S.value,(D=_==null?void 0:_.amount)==null?void 0:D.currency,{hideCurrency:!0})}),y},[]);return f==null||f.sort((y,_)=>y.key==="capture"?-1:_.key==="capture"?1:y.key.localeCompare(_.key)),f},[n,o]),l=A(()=>r!=null&&r.createdAt?a(new Date(r==null?void 0:r.createdAt),V_):"",[r,a]),h=Object.entries(s||{}).filter(([,f])=>f.type!=="button"&&f.visibility!=="hidden").map(([f,T])=>({key:f,value:Jt(T)?T.value:T,type:Jt(T)?T.type:"text",config:Jt(T)?T.config:void 0}))||[],u=A(()=>[...s?Object.values(s).filter(g=>g.type==="button").map(g=>{var y,_,v;return{title:g.value,variant:te.SECONDARY,event:(y=g.config)==null?void 0:y.action,classNames:(_=g==null?void 0:g.config)!=null&&_.className?[(v=g==null?void 0:g.config)==null?void 0:v.className]:[]}}):[]].filter(Boolean),[s]);return i(Q,{children:r?i("div",{className:Ut,children:[i("div",{className:M(dg,{[ug]:h.length}),children:[i("div",{className:lg,children:[i(I,{variant:O.SUBTITLE,stronger:!0,children:o.get("netPayout")}),r.isSumOfSameDayPayouts&&i(ot,{variant:Oe.BLUE,label:o.get("sumOfSameDayPayouts")})]}),i(I,{variant:O.TITLE,large:!0,children:`${o.amount(r.payoutAmount.value,r.payoutAmount.currency,{hideCurrency:!0})} ${r.payoutAmount.currency}`}),i(I,{variant:O.BODY,children:l}),i("div",{className:vs,children:[t&&i(I,{variant:O.CAPTION,stronger:!0,wide:!0,children:`${t}`}),i(I,{variant:O.CAPTION,className:hg,children:`${e}`})]})]}),h&&h.length>0?i("div",{children:i(gn,{classNames:pg,items:h,align:"start",layout:"5-7",renderLabel:f=>i("div",{className:fg,children:f}),renderValue:(f,T,g,y)=>{if(g==="link"&&y)return i(wi,{classNames:[M(y==null?void 0:y.className)],href:y.href,target:y.target||"_blank",children:f});if(g==="icon"&&y){const _={url:y.src,alt:y.alt||f};return i("div",{className:M(mg,y==null?void 0:y.className),children:[i(Li,{..._}),i(I,{variant:O.BODY,children:f})]})}return i(I,{className:M(y==null?void 0:y.className),variant:O.BODY,children:f})}})}):null,i("div",{className:Nc,children:[i("div",{className:vs,children:(r==null?void 0:r.fundsCapturedAmount)&&(d&&Object.keys(d).length>0?i(Ml,{header:i(I,{variant:O.BODY,children:o.get("fundsCaptured")}),headerInformation:i(I,{variant:O.BODY,children:o.amount(r.fundsCapturedAmount.value,r.fundsCapturedAmount.currency)}),children:i("div",{className:vs,children:i("div",{className:Uo,children:i(kr,{noPadding:!0,children:i(gn,{items:d})})})})}):i("div",{className:M(wr,Wl),children:[i(I,{variant:O.BODY,children:o.get("fundsCaptured")}),i(I,{variant:O.BODY,children:o.amount(r.fundsCapturedAmount.value,r.fundsCapturedAmount.currency)})]}))}),i("div",{className:vs,children:c!=null&&c.subtractions&&Object.keys(c==null?void 0:c.subtractions).length>0||c!=null&&c.additions&&Object.keys(c==null?void 0:c.additions).length>0?i(Ml,{header:i(I,{variant:O.BODY,children:o.get("adjustments")}),headerInformation:i(I,{variant:O.BODY,children:o.amount(r.adjustmentAmount.value,r.adjustmentAmount.currency)}),children:[(c==null?void 0:c.additions)&&Object.keys(c==null?void 0:c.additions).length>0&&i("div",{className:Uo,children:i(kr,{noPadding:!0,renderHeader:i(I,{className:Ul,variant:O.CAPTION,stronger:!0,children:o.get("additions")}),children:i(gn,{items:c==null?void 0:c.additions})})}),(c==null?void 0:c.subtractions)&&Object.keys(c==null?void 0:c.subtractions).length>0&&i("div",{className:Uo,children:i(kr,{noPadding:!0,renderHeader:i(I,{className:Ul,variant:O.CAPTION,stronger:!0,children:o.get("subtractions")}),children:i(gn,{items:c==null?void 0:c.subtractions})})})]}):i("div",{className:M(wr,Wl),children:[i(I,{variant:O.BODY,children:o.get("adjustments")}),i(I,{variant:O.BODY,children:o.amount(r.adjustmentAmount.value,r.adjustmentAmount.currency)})]})}),i("div",{className:M(vs),children:i("div",{className:M(wr,gg),children:[i(I,{variant:O.BODY,stronger:!0,children:o.get("netPayout")}),i(I,{variant:O.BODY,stronger:!0,children:o.amount(r.payoutAmount.value,r.payoutAmount.currency)})]})})]}),((p=n==null?void 0:n.payout)==null?void 0:p.unpaidAmount)&&i("div",{className:Tg,children:[i(I,{variant:O.BODY,children:o.get("remainingAmount")}),i(I,{variant:O.BODY,children:o.amount(n.payout.unpaidAmount.value,n.payout.unpaidAmount.currency)})]}),u.length?i("div",{className:_g,children:i(fs,{actions:u,layout:Co.BUTTONS_END})}):null]}):i(Ec,{skeletonRowNumber:6})})};var be=(e=>(e.WARNING="warning",e.CRITICAL="critical",e.HIGHLIGHT="highlight",e.SUCCESS="success",e))(be||{}),it=(e=>(e.DEFAULT="default",e.TIP="tip",e))(it||{});const Sg=({className:e,type:t})=>{switch(t){case be.WARNING:return i(ue,{name:"warning-filled",className:e});case be.CRITICAL:return i(ue,{name:"cross-circle-fill",className:e});case be.HIGHLIGHT:return i(ue,{name:"info-filled",className:e});case be.SUCCESS:default:return i(ue,{name:"checkmark-circle-fill",className:e})}},et=({className:e,description:t,title:n,type:s,children:r,onClose:a,variant:o=it.DEFAULT})=>i("div",{className:M("adyen-pe-alert",`adyen-pe-alert--${s}`,`adyen-pe-alert--${o}`,e),role:"alert",children:[i(Sg,{type:s,className:"adyen-pe-alert__icon"}),i("div",{className:"adyen-pe-alert__content",children:[n&&o!==it.TIP&&i(I,{className:"adyen-pe-alert__title",el:J.DIV,variant:O.BODY,wide:!0,strongest:!0,children:n}),t&&i(I,{className:"adyen-pe-alert__description",el:J.DIV,variant:o!==it.TIP?O.CAPTION:O.BODY,wide:!0,children:t}),r]}),a&&o!==it.TIP&&i("div",{className:"adyen-pe-alert__close-button",children:i(_e,{iconButton:!0,variant:te.TERTIARY,onClick:a,children:i(ue,{name:"cross"})})})]}),Eg=Object.freeze({klarna:"Klarna",paypal:"PayPal"});function rh(e,t){return e.lastFourDigits?t==="detail"?"•••• •••• •••• "+e.lastFourDigits:e.lastFourDigits:e.description||Eg[e.type]||e.type}const Ng=e=>e!=null&&e.paymentMethod?e.paymentMethod.type:e!=null&&e.bankAccount?"bankTransfer":null,Dg=e=>{var t;return e!=null&&e.paymentMethod?rh(e.paymentMethod,"detail"):(t=e==null?void 0:e.bankAccount)==null?void 0:t.accountNumberLastFourDigits},oh=({timezone:e,paymentMethodData:t,bankAccount:n,amountData:s,createdAt:r})=>{const a=A(()=>({paymentMethod:t,bankAccount:n}),[t,n]),{i18n:o}=H(),{dateFormat:c}=Pt(e),d=A(()=>{if(s){const{currency:p,value:f}=s;return`${o.amount(f,p,{hideCurrency:!0})} ${p}`}},[s,o]),l=A(()=>Ng(a),[a]),h=A(()=>Dg(a),[a]),u=A(()=>r&&c(new Date(r),X_),[r,c]);return{amount:d,date:u,paymentMethod:h,paymentMethodType:l}};var ft=(e=>(e[e.DETAILS=0]="DETAILS",e[e.REFUND=1]="REFUND",e[e.REFUND_SUCCESS=2]="REFUND_SUCCESS",e[e.REFUND_ERROR=3]="REFUND_ERROR",e))(ft||{}),Fs=(e=>(e[e.INDETERMINATE=0]="INDETERMINATE",e[e.PARTIAL=1]="PARTIAL",e[e.FULL=2]="FULL",e))(Fs||{}),Xe=(e=>(e.NON_REFUNDABLE="non_refundable",e.PARTIAL_AMOUNT="partially_refundable_any_amount",e.PARTIAL_LINE_ITEMS="partially_refundable_with_line_items_required",e.FULL_AMOUNT="fully_refundable_only",e))(Xe||{}),Er=(e=>(e.IN_PROGRESS="in_progress",e.COMPLETED="completed",e.FAILED="failed",e))(Er||{}),Vn=(e=>(e.PARTIAL="partial",e.FULL="full",e))(Vn||{});const ih=hs({availableItems:Se,primaryAction:he,secondaryAction:he,transaction:z,extraFields:z,dataCustomization:z}),bg=Ue(({children:e,lineItems:t,refundAvailable:n,refundDisabled:s,setActiveView:r,setPrimaryAction:a,setSecondaryAction:o,transaction:c,transactionNavigator:d,extraFields:l,dataCustomization:h})=>{const{i18n:u}=H(),{currentTransaction:p,canNavigateBackward:f,canNavigateForward:T,backward:g,forward:y}=d,_=A(()=>({title:u.get("refundAction")}),[u]),v=A(()=>!n||s,[n,s]),N=C(()=>void(!v&&r(ft.REFUND)),[v,r]),S=A(()=>{if(p===c.id){if(f)return 2;if(T)return 1}},[f,T,p,c]),D=C(()=>{switch(S){case 2:return void g();case 1:return void y()}},[S,g,y]),R=A(()=>{switch(S){case 2:return{title:u.get("refund.returnToRefund"),renderTitle:b=>i(Q,{children:[i(ue,{style:{transform:"scaleX(-1)"},name:"angle-right"}),i("span",{children:b})]})};case 1:return{title:u.get("refund.goToPayment"),renderTitle:b=>i(Q,{children:[i(ue,{name:"angle-right"}),i("span",{children:b})]})}}},[S,u]);return G(()=>{a(n?Object.freeze({disabled:v,event:N,variant:te.PRIMARY,..._}):void 0)},[N,n,v,_,a]),G(()=>{o(S&&R?Object.freeze({disabled:!1,event:D,variant:te.SECONDARY,...R}):void 0)},[S,D,R,o]),i(ih.Provider,{value:{availableItems:t,primaryAction:N,secondaryAction:D,transaction:c,extraFields:l,dataCustomization:h},children:e})}),Og=()=>ps(ih),bc=Object.freeze(["requested_by_customer","issue_with_item_sold","fraudulent","duplicate","other"]),Ig=({refundAmount:e,refundReason:t,refundInProgress:n,refundTransaction:s,setActiveView:r,transactionId:a})=>{const{i18n:o}=H(),c=A(()=>{const T=o.amount(e.value,e.currency);return{title:o.get("refundPayment",{values:{amount:T}})}},[e,o]),d=A(()=>({title:o.get("refundAction")}),[o]),l=A(()=>({title:`${o.get("inProgress")}..`,state:"loading"}),[o]),h=A(()=>({path:{transactionId:a}}),[a]),u=A(()=>({amount:e,refundReason:t}),[e,t]),p=C(()=>s==null?void 0:s({body:u,contentType:"application/json"},h).then(()=>{r(ft.REFUND_SUCCESS)}).catch(()=>{r(ft.REFUND_ERROR)}),[s,h,u,r]),f=A(()=>n?l:e.value>0?c:d,[e,n,c,d,l]);return{refundAction:p,refundActionLabel:f}},Pg=({interactionsDisabled:e,refundAmount:t,setActiveView:n,setPrimaryAction:s,setSecondaryAction:r,...a})=>{const{refundAction:o,refundActionLabel:c}=Ig({...a,refundAmount:t,setActiveView:n}),{i18n:d}=H(),l=A(()=>e||t.value<=0,[t,e]),h=C(()=>!l&&o(),[l,o]),u=e,p=A(()=>d.get("back"),[d]),f=C(()=>void(!u&&n(ft.DETAILS)),[u,n]);return G(()=>{s(Object.freeze({disabled:l,event:h,variant:te.PRIMARY,...c}))},[h,l,c,s]),G(()=>{r(Object.freeze({disabled:u,event:f,title:p,variant:te.SECONDARY}))},[f,u,p,r]),{primaryAction:h,secondaryAction:f}},kg=({availableAmount:e,currency:t,interactionsDisabled:n,items:s,refundMode:r})=>{const[a,o]=F(0),c=A(()=>{switch(r){case Xe.NON_REFUNDABLE:return 0;case Xe.PARTIAL_LINE_ITEMS:case Xe.PARTIAL_AMOUNT:return a;case Xe.FULL_AMOUNT:default:return e}},[e,s,r,a]),d=A(()=>Object.freeze({currency:t,value:c}),[c,t]),l=A(()=>!n&&r===Xe.PARTIAL_AMOUNT,[n,r]),h=C(u=>void(l&&o(Et(0,u,e))),[e,l]);return G(()=>{o(e)},[e]),[d,h]},Yl=(e,t,n,s=0)=>{const{...r}=e.get(n.id),a=Et(0,Math.trunc(s),r.quantity+=n.quantity);r.quantity-=a,e.set(n.id,Object.freeze(r)),a>0&&t.push(Object.freeze({...r,quantity:a}))},ql=(e,t,n=Se)=>{const s=new Map((n==null?void 0:n.map(({id:a,quantity:o})=>[a,o]))??Se),r=[];return t.forEach(a=>{const o=s.get(a.id);oe(o)?r.push(a):s.delete(a.id)&&Yl(e,r,a,o)}),s.forEach((a,o)=>{Yl(e,r,{id:o,quantity:0},a)}),r.length>0?Object.freeze(r):Se},wg=({currency:e,lineItems:t})=>{const[n,s]=F(Se),r=A(()=>{const d=t==null?void 0:t.filter(l=>{if(l.amountIncludingTax.currency!==e)return;const h=l.availableQuantity;return h>0&&Number.isFinite(h)&&Math.trunc(h)===h}).map(({id:l,...h})=>[l,Object.freeze({amount:h.amountIncludingTax.value,quantity:h.availableQuantity,id:l})]);return new Map(d??Se)},[e,t]),a=A(()=>(t==null?void 0:t.filter(({id:d})=>r.has(d)))??Se,[n,t,r]),o=C(function(d){s(l=>{const u=[...arguments.length===0?new Map(l.map(({id:p})=>[p,0])):new Map((d==null?void 0:d.map(p=>[p,0]))??Se)].map(([p,f])=>({id:p,quantity:f}));return ql(r,l,u)})},[r]),c=C(d=>s(l=>ql(r,l,d)),[r]);return{availableItems:a,clearItems:o,items:n,updateItems:c}},Lg=({interactionsDisabled:e,refundMode:t})=>{const[n,s]=F(bc[0]),r=A(()=>!e&&t!==Xe.NON_REFUNDABLE,[e,t]),a=C(o=>void(r&&s(o)),[r]);return[n,a]},Po=e=>{setTimeout(()=>{throw e},0)};function is({queryFn:e,options:t}){const{retry:n=!1,retryDelay:s=1e3,onSuccess:r,onError:a,onSettled:o,shouldRetry:c}=t||z,[d,l]=F(null),[h,u]=F(null),[p,f]=F("idle"),T=q(!0),g=q(0),y=C(()=>{l(null),u(null),f("idle"),g.current=0},[]),_=C(()=>{g.current=0},[]),v=C(async(...N)=>{try{f("loading"),u(null);const S=await(e==null?void 0:e(...N));return T.current&&(l(S),f("success")),ir.then(()=>{r&&Ln(r,S).catch(Po),o&&Ln(o,S,null).catch(Po),_()}),S}catch(S){let D=0;if(fr(n)&&(!c||c(S))?D=Math.max(0,Math.floor(n)):D=0,g.current++<D){const R=ee(s)?s(g.current):s??1e3;return await new Promise(b=>setTimeout(b,R)),v(...N)}throw T.current&&(u(S),f("error")),ir.then(()=>{a&&Ln(a,S).catch(Po),o&&Ln(o,void 0,S).catch(Po),_()}),S}},[e,r,o,n,c,s,_,a]);return G(()=>()=>{T.current=!1},[]),A(()=>({data:d,error:h,status:p,isIdle:p==="idle",isLoading:p==="loading",isSuccess:p==="success",isError:p==="error",mutate:v,reset:y}),[d,h,p,v,y])}const ah=hs({amount:0,availableAmount:0,availableItems:Se,clearItems:he,currency:"",interactionsDisabled:!1,items:Se,primaryAction:he,refundMode:Xe.FULL_AMOUNT,refundReason:bc[0],secondaryAction:he,setAmount:he,setRefundReason:he,transactionId:"",updateItems:he}),Fg=Ue(({availableAmount:e,children:t,currency:n,lineItems:s,refreshTransaction:r,refundMode:a,setActiveView:o,setPrimaryAction:c,setSecondaryAction:d,transactionId:l})=>{const{isLoading:h,mutate:u}=is({queryFn:Ee().endpoints.initiateRefund}),{availableItems:p,clearItems:f,items:T,updateItems:g}=wg({currency:n,lineItems:s}),y=h,[_,v]=kg({availableAmount:e,currency:n,interactionsDisabled:y,items:T,refundMode:a}),[N,S]=Lg({interactionsDisabled:y,refundMode:a}),{value:D}=_,{primaryAction:R,secondaryAction:b}=Pg({interactionsDisabled:y,refreshTransaction:r,refundAmount:_,refundInProgress:h,refundReason:N,refundTransaction:u,setActiveView:o,setPrimaryAction:c,setSecondaryAction:d,transactionId:l});return i(ah.Provider,{value:{amount:D,availableAmount:e,availableItems:p,clearItems:f,currency:n,interactionsDisabled:y,items:T,primaryAction:R,refundMode:a,refundReason:N,secondaryAction:b,setAmount:v,setRefundReason:S,transactionId:l,updateItems:g},children:t})}),Oc=()=>ps(ah),Mg=()=>{let[e,t,n,s]=Se;const r=()=>!!(e&&e===s&&n),a=()=>!!(e&&e===n&&s);let o=null;const c=()=>{r()&&(t=e,e=n,u())},d=()=>{a()&&(t=e,e=s,u())},l=(p,f)=>{const T=e;e=t=n=s=void 0,!Da(p)&&!Da(f)&&(n=p,s=f,e=T===n||T===s?T:n,T!==e&&u())},h=p=>{xe(p)?o=null:ee(p)&&o!==(o=p)&&u()},u=()=>{const p=t,f=e;t=void 0,o==null||o(de({from:ve(()=>p),to:ve(()=>f)}))};return de({backward:X(c),forward:X(d),canNavigateBackward:ve(r),canNavigateForward:ve(a),currentTransaction:ve(()=>e),onNavigation:{set:h},reset:X(l)})},xg=e=>{const[t,n]=F(e),[s,r]=F(e.id),[a,o]=F(performance.now()),{getTransaction:c}=Ee().endpoints,d=q(Mg()),l=d.current,h=q(!1),u=q(!1),p=q(e),f=q(s),T=A(()=>!!c&&!!s&&h.current,[s,c]),g=C(()=>c(z,{path:{transactionId:s}}),[s,c]),{data:y,error:_,isFetching:v}=bt({fetchOptions:{enabled:T},queryFn:g}),N=C(()=>r(void 0),[]);return G(()=>{s||r(t.id)},[s,t]),G(()=>{var R;const S=d.current,D=p.current;return D.category==="Refund"&&(S.reset(D.id,(R=D.refundMetadata)==null?void 0:R.originalPaymentId),S.onNavigation=({to:b})=>{h.current=!0,o(performance.now()),b&&r(b)}),()=>{h.current=!1,S.onNavigation=null,S.reset()}},[]),G(()=>{if(u.current!==v&&!(u.current=v))if(!y||_)r(f.current);else{const S=p.current;n(()=>({...y.id===S.id?S:z,...y})),f.current=s}},[y,_,v,s,a]),{fetchingTransaction:v,refreshTransaction:N,transaction:t,transactionNavigator:l}},Bg=(e,t)=>{let n=t?(t==null?void 0:t.length)>0:!1,s=!1;return t==null||t.forEach(r=>{const a=!!e(r);n&&(n=a),s||(s=a)}),{every:n,some:s}},ko=["completed","in_progress","failed"],$g=e=>{var N,S,D;const{i18n:t}=H(),n=e==null?void 0:e.refundDetails,s=(n==null?void 0:n.refundMode)??Xe.FULL_AMOUNT,r=Ve(n==null?void 0:n.refundLocked),a=s!==Xe.NON_REFUNDABLE,o=(N=e==null?void 0:e.originalAmount)==null?void 0:N.value,c=A(()=>{var R;return e?Math.max(0,((R=n==null?void 0:n.refundableAmount)==null?void 0:R.value)??0):0},[n,e]),d=ee(Ee().endpoints.initiateRefund),l=d&&a&&c>0,h=((S=n==null?void 0:n.refundableAmount)==null?void 0:S.currency)??(e==null?void 0:e.amount.currency)??"",u=!l||r,p=A(()=>{var b;const R=((b=e==null?void 0:e.refundDetails)==null?void 0:b.refundStatuses)??[];return(R==null?void 0:R.filter(E=>E.amount.value!==0).sort((E,P)=>ko.includes(E.status)&&ko.includes(P.status)&&ko.indexOf(E.status)>ko.indexOf(P.status)?0:-1).reduce((E,P)=>{var x;const w=P.status,W=~P.amount.value+1;return E!=null&&E[w]?((x=E==null?void 0:E[w])==null||x.amounts.push(W),E):{...E,[w]:{amounts:[W],currency:P.amount.currency}}},{}))??{}},[(D=e==null?void 0:e.refundDetails)==null?void 0:D.refundStatuses]),f=A(()=>{var b,E;const R=(E=(b=p.completed)==null?void 0:b.amounts)==null?void 0:E.reduce((P,w)=>P+w,0);return R?Math.max(0,R??0):0},[p]),{some:T,every:g}=A(()=>Bg(({status:R})=>R===Er.COMPLETED,n==null?void 0:n.refundStatuses),[n==null?void 0:n.refundStatuses]),y=A(()=>{var R;return c===0&&f>0&&g&&f===o?[{type:be.HIGHLIGHT,label:t.get("refund.fullAmountRefunded")}]:((R=Object.keys(p))==null?void 0:R.map(E=>{var x,j;const P=E,w=(x=p==null?void 0:p[P])==null?void 0:x.amounts.reduce((L,U,ie)=>{var V,Z,ge;const le=(V=p==null?void 0:p[P])==null?void 0:V.amounts.length;return le>1&&ie===le-1?`${L?`${L}`:""} ${t.get("and")} ${t.amount(U,(Z=p==null?void 0:p[P])==null?void 0:Z.currency)}`:`${L?`${L},`:""} ${t.amount(U,(ge=p==null?void 0:p[P])==null?void 0:ge.currency)}`},""),W=(j=p==null?void 0:p[P])==null?void 0:j.amounts.reduce((L,U)=>L+U,0);switch(E){case Er.COMPLETED:return{type:be.HIGHLIGHT,label:t.get("refund.amountAlreadyRefunded",{values:{amount:w}})};case Er.IN_PROGRESS:return W===o?{type:be.HIGHLIGHT,label:t.get("refund.theRefundIsBeingProcessed")}:{type:be.HIGHLIGHT,label:t.get("refund.amountInProgress",{values:{amount:w}})};case Er.FAILED:return W===o?{type:be.WARNING,label:t.get("refund.fullAmountFailed")}:{type:be.WARNING,label:t.get("refund.amountFailed",{values:{amount:w}})};default:return}}))??[]},[c,o,t,f,p,g]),_=A(()=>{if(c>0){const R=t.amount(c,h);switch(s){case Xe.FULL_AMOUNT:return{type:be.HIGHLIGHT,description:t.get("refund.onlyRefundable",{values:{amount:R}})};case Xe.PARTIAL_AMOUNT:return{type:be.HIGHLIGHT,description:t.get("refund.maximumRefundable",{values:{amount:R}})};default:return null}}return null},[t,c,h,s]),v=A(()=>{switch(s){case Xe.NON_REFUNDABLE:if(c===0&&f>0&&g&&f===o)return Fs.FULL}switch(s){case Xe.PARTIAL_AMOUNT:case Xe.PARTIAL_LINE_ITEMS:if(c>0&&T&&f>0&&!oe(o)&&f<o)return Fs.PARTIAL}return Fs.INDETERMINATE},[c,f,s,o,T,g]);return{refundableAmount:c,refundable:a,refundableAmountLabel:_,refundAvailable:l,refundAuthorization:d,refundCurrency:h,refundDisabled:u,refundedAmount:f,refundedState:v,refundStatuses:y,refundLocked:r,refundMode:s}},Ct="adyen-pe-popover",ch="adyen-pe-tooltip",Ug=`${Ct}-container`,jl=`${Ct}__header`,Wg=`${Ct}__header-title`,ha=`${Ct}__content`,lh=`${ch}__content`,Hg=`${Ct}__footer`;function Gg({image:e=!0,onClick:t}){const{i18n:n}=H();return i(Q,{children:i(_e,{className:e?"adyen-pe-popover-dismiss-button--on-image":"",iconButton:!0,variant:te.TERTIARY,onClick:t,"aria-label":n.get("closeIconLabel"),children:i("svg",{role:"img",xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",fill:"none",children:[i("title",{children:"dismiss"}),i("path",{fill:"#00112C",fillRule:"evenodd",d:"M11.4697 12.5303C11.7626 12.8232 12.2374 12.8232 12.5303 12.5303C12.8232 12.2374 12.8232 11.7626 12.5303 11.4697L9.06066 8L12.5303 4.53033C12.8232 4.23744 12.8232 3.76256 12.5303 3.46967C12.2374 3.17678 11.7626 3.17678 11.4697 3.46967L8 6.93934L4.53033 3.46967C4.23744 3.17678 3.76256 3.17678 3.46967 3.46967C3.17678 3.76256 3.17678 4.23744 3.46967 4.53033L6.93934 8L3.46967 11.4697C3.17678 11.7626 3.17678 12.2374 3.46967 12.5303C3.76256 12.8232 4.23744 12.8232 4.53033 12.5303L8 9.06066L11.4697 12.5303Z",clipRule:"evenodd"})]})})})}const Yg=Ue(Gg);function qg({title:e,isImageTitle:t=!1}){return i(I,{strongest:!t,variant:t?O.SUBTITLE:O.BODY,children:e})}const jg=Ue(qg);var st=(e=>(e.TOOLTIP="tooltip",e.POPOVER="popover",e))(st||{}),se=(e=>(e.TOP="top",e.RIGHT="right",e.BOTTOM="bottom",e.LEFT="left",e.TOP_LEFT="top-left",e.TOP_RIGHT="top-right",e.BOTTOM_LEFT="bottom-left",e.BOTTOM_RIGHT="bottom-right",e))(se||{}),Hr=(e=>(e.MEDIUM="medium",e.WIDE="wide",e))(Hr||{});const bs=(()=>{let e=[];const t=o=>{const c=o.reduce((d,l)=>{const h=l instanceof Node?e.findIndex(u=>{const p=u.element.getAttribute("id"),f=l&&(l!=null&&l.getAttribute)?l==null?void 0:l.getAttribute("id"):null;return p===f}):-1;return d===-1&&h!==-1?h:d},-1);c===-1?r(0):c+1<=e.length-1&&r(c+1)},n=o=>{const c=e.findIndex(d=>d.element.getAttribute("id")===o.getAttribute("id"));c>=0&&e.splice(c,1)},s=(o,c)=>{e.findIndex(l=>l.element.getAttribute("id")===o.getAttribute("id"))>=0||e.push({element:o,callback:c})},r=o=>{var d,l;const c=e.length;for(let h=o;h<c;h++)(l=(d=e==null?void 0:e[h])==null?void 0:d.callback)==null||l.call(d);e.splice(o)};return{add:s,remove:n,closeAll:()=>{e.forEach(o=>{var c;return(c=o==null?void 0:o.callback)==null?void 0:c.call(o)}),e=[]},closePopoversOutsideOfClick:t}})(),Gr=Symbol("_ref");class dh extends Error{}class Vg extends dh{}class zg extends dh{}function Ic(e){if(!ee(e))throw new zg}const Kg=e=>{try{if(ee(e)&&Zt(e,"current")&&Zt(e,Gr)&&!ds(e,e[Gr])){const t=e.actions.get(z),n=e.actions.size;return oe(t)&&Number.isInteger(n)&&n>=0}}catch{}return!1},Yr=e=>Kg(e)?Yr(e[Gr]):e;function Vl(e){return!!e.current}const Xg=(()=>{const e=(s,r)=>{const a=s.get(r);if(!a)throw new Vg;return a},t=(s,r,a)=>{let o,c;const d=Yr(r);try{o=e(s,d)}catch{Ic(a)}if(o)[,c]=o;else{const l=ee(d),h=l?f=>{d(p=f)}:f=>{d&&(d.current=f,p=d.current)},u=f=>{if(c.size===0)return;const T=p;if(h(f),!ds(p,T))for(const[g]of c)g(p,T)};let p=l?null:d.current;s.set(d,o=[u,c=new Map]),Object.defineProperties(u,{[Gr]:{value:d},actions:{value:de({get:{value:c.get.bind(c)},size:{get:()=>c.size}})},current:{get:()=>p,set:l?void 0:u}})}return a&&c.set(a,1+(c.get(a)||0)),o[0]},n=(s,r,a)=>{const o=Yr(r),[,c]=e(s,o),d=c.get(a)||0;d===1?c.delete(a):d>1&&c.set(a,d-1),c.size===0&&o&&s.delete(o)};return()=>{const s=new WeakMap;return de({bind:X(t.bind(void 0,s)),unbind:X(n.bind(void 0,s))})}})(),Zg=Xg(),Qg=e=>{Ic(e);const t=new WeakMap([[e,1]]),n=r=>{if(ds(s,r))return;const a=s;e(s=r,a)};let s=null;return Object.defineProperties(n,{[Gr]:{value:n},actions:{value:de({get:{value:t.get.bind(t)},size:{value:1}})},current:{get:()=>s,set:n}})},Jg=(e=Zg)=>{let t,n=null,s,r=!1;const a=l=>{t=void 0,n=null,s=l,r=!1},o=()=>{r||(c(),r=!0)},c=()=>{try{if(!n)return;e.unbind(n,s)}catch{}};return de({action:{get:()=>s},reflex:{get:()=>t},release:{value:o},update:{value:(l,h)=>{Ic(l),r&&a(l);const u=xe(h)?null:h;if(s===l&&n===u){if(t)return}else if(n){if(ds(Yr(n),Yr(u))){t=e.bind(n,l),c(),s=l;return}c()}s=l,t=(n=u)?e.bind(n,s):Qg(s)}}})},En=(e,t)=>{const n=q(Jg());return dr(()=>n.current.release,[]),A(()=>(n.current.update(e,t),n.current.reflex),[e,t])},Os=Symbol("__control.Elem.");var uh=(e=>(e.POPOVER="POPOVER",e.DEFAULT="DEFAULT",e))(uh||{});const zl=e=>{e.stopImmediatePropagation()},Pc=(e,t,n,s)=>{const r=q(null),a=C(c=>{const d=c.composedPath();if(r&&r.current)if(s==="POPOVER")bs.closePopoversOutsideOfClick(d);else{let l=0,h=!1,u=d[l];for(;u instanceof Element&&!(h||(h=u==null?void 0:u.isSameNode(r.current)));)u=d[++l]??u.parentElement,(u==null?void 0:u[Os])instanceof Element&&(u=u[Os],d.length=0);t&&!h&&t(!0)}},[r,t,s]),o=q(a);return G(()=>()=>{r.current&&bs.remove(r.current),document.removeEventListener("click",o.current,!0)},[]),G(()=>(document.removeEventListener("click",o.current,!0),o.current=a,document.addEventListener("click",o.current,!0),s==="POPOVER"&&r.current instanceof Element&&bs.add(r.current,t),()=>{r.current&&bs.remove(r.current),document.removeEventListener("click",o.current,!0)}),[a,t,s]),G(()=>{n?document.removeEventListener("click",o.current,!0):document.addEventListener("click",o.current,!0)},[n]),En(C((c,d)=>{d instanceof Element&&d.removeEventListener("focusout",zl,!0),c instanceof Element&&(n||(c.addEventListener("focusout",zl,!0),r.current=c))},[n,s]),e)},kc=`
2
- a[href],
3
- audio[controls],
4
- video[controls],
5
- button,
6
- input,
7
- select,
8
- textarea,
9
- [contenteditable],
10
- [tabindex]
11
- `.replace(/\s+/,""),eT=["contenteditable","controls","disabled","hidden","href","inert","tabindex"],Kl=new Map,hh=e=>e.tagName==="INPUT",tT=e=>hh(e)&&e.type==="radio",nT=e=>{const t=e.name,n=e.form,s=Kl.get(n);let r=s==null?void 0:s.get(t);return oe(r)&&n&&(r=n.querySelector(`input[type=radio][name='${t}']:checked`)||null,Kl.set(n,(s||new Map).set(t,r))),r===e},sT=(e,t)=>{for(const n of t)if(n.type!=="attributes"){if(dl(n.addedNodes,s=>s instanceof Element&&Ua(s))||dl(n.removedNodes,s=>e.includes(s)))return!0}else{if(Ua(n.target))return!0;if(e.includes(n.target))return!0}return!1},wc=(e=document.body,t)=>{if(oe(e))return!1;if(xe(t))return!!document.activeElement&&wc(e,document.activeElement);let n=t==null?void 0:t.parentNode;for(;n;){if(n===e)return!0;n=n==null?void 0:n.parentNode}return!1},Lc=e=>!(!e.matches(kc)||e!=null&&e.disabled||/^(true)?$/.test(e.getAttribute("inert"))||hh(e)&&e.hidden),Ua=e=>!(tT(e)&&!nT(e)||(e==null?void 0:e.tabIndex)<0||!Lc(e)),rT=()=>{const e=new MutationObserver(c=>sT(t,c)&&a()),t=[];let n=-1,s=null;const r=c=>{var l;if(c<0)return;const d=Math.min(c,t.length-1);n!==d&&(n=d),(l=t[n])==null||l.focus()},a=()=>{t.length=0,s instanceof Element&&(s.querySelectorAll(kc).forEach(c=>Ua(c)&&t.push(c)),wc(s)&&(o.current=document.activeElement))},o=Object.create(null,{current:{get:()=>t[n]??null,set:c=>{if(c){if(!fr(c))return r(t.indexOf(c));if(c===~~c)return r(_o(n+c,t.length))}}},root:{get:()=>s,set:c=>{c!==s&&(s&&e.disconnect(),s=c instanceof Element?c:null,t.length=0,s&&(e.observe(s,{attributeFilter:eT,attributes:!0,childList:!0,subtree:!0}),a()))}},tabbables:{value:t}});return o},oT=(e,t)=>{const n=q(!1),s=q(null),r=q(!1),a=A(rT,[]),o=A(()=>{let h=null,u;return p=>{oe(u)||cancelAnimationFrame(u);let f=p.target;for(;f&&f!==p.currentTarget;){if(Lc(f)){h=f,u=requestAnimationFrame(()=>{u=requestAnimationFrame(()=>{var T;s.current!==h&&h instanceof HTMLElement&&((T=s.current=h)==null||T.focus()),h=null,u=void 0})});return}f=f.parentNode}}},[]),c=C(h=>{a.current=s.current=h.target},[]),d=C(h=>{a.tabbables.includes(h.relatedTarget)||wc(h.currentTarget,h.relatedTarget)||r.current||(n.current=!0,requestAnimationFrame(()=>{n.current&&t(n.current=!1)}))},[]),l=A(()=>{let h;return u=>{switch(u.code){case ne.ARROW_DOWN:case ne.ARROW_LEFT:case ne.ARROW_RIGHT:case ne.ARROW_UP:case ne.END:case ne.ESCAPE:case ne.HOME:case ne.PAGE_DOWN:case ne.PAGE_UP:case ne.TAB:cancelAnimationFrame(h),h=requestAnimationFrame(()=>{h=requestAnimationFrame(()=>{r.current=!1,h=void 0})}),r.current=!0;break}u.code===ne.TAB?(u.preventDefault(),a.current=u.shiftKey?-1:1):u.code===ne.ESCAPE&&t(!0)}},[]);return En(C((h,u)=>{u instanceof Element&&(u.removeEventListener("keydown",l,!0),u.removeEventListener("focusin",c,!0),u.removeEventListener("focusout",d,!0),h.removeEventListener("click",o,!0)),h instanceof Element?(h.addEventListener("keydown",l,!0),h.addEventListener("focusin",c,!0),h.addEventListener("focusout",d,!0),h.addEventListener("click",o,!0),n.current=!1,a.root=h):a.root=null},[]),e)},pa=(()=>{const e=new WeakMap,t=de({remove:X(function(){s(this.observerCallback)})}),n=(r,a)=>{let o=e.get(r);if(oe(o)){const c=new IntersectionObserver(d=>{d.forEach(l=>{r&&r(l)})},{root:a??null,rootMargin:"",threshold:[1]});o=mr(t,{observerCallback:X(r),observer:X(c)}),e.set(r,o)}return o},s=r=>{const a=e.get(r);a==null||a.observer.disconnect(),e.delete(r)};return n})(),Xl=[se.BOTTOM_RIGHT,se.BOTTOM_LEFT,se.TOP_RIGHT,se.TOP_LEFT],iT=5,Zl=4,aT=10,cT=({position:e,variant:t,offset:n,additionalStyle:s,fixedPositioning:r,fullWidth:a,popover:o,targetElement:c})=>{let d=0,l=0;const h=t===st.TOOLTIP,u=o.clientHeight,p=o.clientWidth,f=o.firstChild,T=f.offsetHeight,g=f.offsetWidth,y=document.body.getBoundingClientRect(),_=c.getBoundingClientRect(),v=y.x+(y.width-g)/2,N=_.x+(_.width-g)/2,S=_.y+(_.height-T)/2,D=window.scrollX,R=window.scrollY;switch(e){case se.BOTTOM:d=a?v:h?N:_.x,l=_.y+_.height+n[1],r||(a||(d+=D),l+=R);break;case se.TOP:d=h?N:_.x,l=_.y-(u+n[0]),r||(d+=D,l+=R-f.clientHeight+u);break;case se.RIGHT:d=_.x+_.width+n[2],l=h?S:_.y-_.height/2,r||(d+=D,l+=R);break;case se.LEFT:d=_.x-(p+n[3]),l=h?S:_.y-_.height/2,r||(d+=D,l+=R);break;case se.BOTTOM_LEFT:d=5,l=_.y+_.height+n[1],r||(d+=D,l+=R);break;case se.BOTTOM_RIGHT:d=-5,l=_.y+_.height+n[1],r||(d+=D,l+=R);break;case se.TOP_LEFT:d=iT,l=_.y-u,r||(d+=D,l+=R-f.clientHeight+u);break;case se.TOP_RIGHT:d=-5,l=_.y-u,r||(d+=D,l+=R-f.clientHeight+u);break}const b={};if(s){const P=!!s.maxY&&l+(o==null?void 0:o.clientHeight)>s.maxY,w=!!s.minY&&l<s.minY;if(P&&s.maxY){const W=_.y+_.height+8,x=Math.max(0,s.maxY-W);x>20&&(b.height=`${x}px`),b["overflow-y"]="scroll"}if(w&&s.minY&&l){const W=o.offsetHeight??o.clientHeight,x=Math.max(0,W-(s.minY-l));b.height=`${x}px`,x&&(b["overflow-y"]="scroll")}w&&(l=s.minY??0)}const E=e===se.TOP_RIGHT||e===se.BOTTOM_RIGHT;return{inset:E?"0 0 auto auto":"0 auto auto 0",margin:"0",position:r?"fixed":"absolute",transform:`translate3d(${d}px, ${l}px, 0)`,visibility:"hidden",right:E?0:"auto",...b}},lT=(e,t,n,s,r,a,o,c,d,l,h,u)=>{const[p,f]=F(!0),[T,g]=F(c?!c:!!s),[y,_]=F(s||se.TOP),[v,N]=F([]),S=C(R=>{var P;const b=document.documentElement.clientWidth,E=(P=t.current)==null?void 0:P.getBoundingClientRect();if(R.intersectionRatio===1)return g(!0);if(!p&&R.intersectionRatio!==1){if(v&&v.length===(c?8:4)){const w=v.reduce((W,x)=>x[1]>W[1]?x:W,v[0]);return _(w[0]),g(!0)}switch(g(!1),y){case se.TOP:N(w=>[...w,[se.TOP,R.intersectionRatio]]),_(se.BOTTOM);break;case se.BOTTOM:N(w=>[...w,[se.BOTTOM,R.intersectionRatio]]),_(c?((E==null?void 0:E.x)||0)>b/2?se.BOTTOM_RIGHT:se.BOTTOM_LEFT:se.RIGHT);break;case se.BOTTOM_LEFT:N(w=>[...w,[se.BOTTOM_LEFT,R.intersectionRatio]]),_(c?se.TOP_LEFT:se.RIGHT);break;case se.BOTTOM_RIGHT:N(w=>[...w,[se.BOTTOM_RIGHT,R.intersectionRatio]]),_(c?se.TOP_RIGHT:se.RIGHT);break;case se.TOP_LEFT:N(w=>[...w,[se.TOP_LEFT,R.intersectionRatio]]),_(c?se.BOTTOM_LEFT:se.RIGHT);break;case se.TOP_RIGHT:N(w=>[...w,[se.TOP_RIGHT,R.intersectionRatio]]),_(c?se.BOTTOM_RIGHT:se.RIGHT);break;case se.RIGHT:N(w=>[...w,[se.RIGHT,R.intersectionRatio]]),_(se.LEFT);break;case se.LEFT:N(w=>[...w,[se.LEFT,R.intersectionRatio]]),_(se.TOP);break}}},[t,p,v,c,y]),D=q(S);return G(()=>{pa(D.current).remove(),D.current=S},[S]),En(C((R,b)=>{var E,P,w;if(b&&(!s||c)&&pa(S).observer.unobserve(b),R&&t.current){if((!s||c)&&pa(S).observer.observe(R),!(R instanceof Element))return;const x={...cT({variant:n,offset:e,additionalStyle:l,fixedPositioning:d,fullWidth:o,popover:R,position:y,targetElement:t.current}),...T&&{visibility:"visible"},...a&&{"min-width":"fit-content",width:`${t.current.clientWidth}px`}};if(R.setAttribute("style",Object.entries(x).map(j=>j.join(":")).join(";")),p&&f(!1),n&&n===st.TOOLTIP&&r&&Vl(r)&&((E=r.current)==null||E.setAttribute("data-popover-placement",y),Xl.includes(y))){const j=t.current.getBoundingClientRect(),L=R.firstChild,U=L.offsetWidth,ie=j.x+(j.width-U)/2,le=L.offsetHeight,V=y===se.BOTTOM_RIGHT||y===se.BOTTOM_LEFT?le+Zl:Zl;(P=r.current)==null||P.setAttribute("style",`transform: translate3d(${ie}px, -${V}px, 0) rotate(45deg); inset: 0 0 auto auto`)}if(n&&n===st.TOOLTIP&&u&&Vl(u)&&Xl.includes(y)){const j=document.documentElement.clientWidth;(w=u.current)==null||w.setAttribute("style",`max-width: ${j-aT}px`)}}},[s,c,t,S,n,e,l,d,o,y,T,a,p,r,u]),h)},Lr=e=>{const t=q();return En(C((n,s)=>{s instanceof Element&&s.id===t.current&&(s.id=""),n instanceof Element&&(n.id=t.current||(t.current=vn()))},[e]),e)},dT=e=>{var s;let t;const n=(s=e.querySelector(`.${lh}`))==null?void 0:s.querySelectorAll(kc);return n?(Array.prototype.some.call(n,r=>{if(Lc(r))return t=r}),t):null},uT=e=>e===st.TOOLTIP?[10,3,5,5]:[8,8,8,8];function ti({actions:e,disableFocusTrap:t=!1,actionsLayout:n=Co.SPACE_BETWEEN,variant:s=st.TOOLTIP,title:r,open:a,dismissible:o,modifiers:c,divider:d,fitContent:l,withoutSpace:h,containerSize:u,position:p,targetElement:f,setToTargetWidth:T,dismiss:g,children:y,withContentPadding:_,classNameModifiers:v,showOverlay:N=!1,fitPosition:S,fixedPositioning:D=!1,additionalStyle:R,...b}){const E=A(()=>ee(g)&&en(o),[g,o]),P=Lr(),w=Lr(),W=q(),x=C(Ce=>{var ae;g&&g(),Ce&&((ae=f==null?void 0:f.current)==null||ae.focus())},[g,f]),j=C(Ce=>{Ce.code===ne.ESCAPE&&(g&&g(),(f==null?void 0:f.current).focus())},[g,f]),L=q(j),U=q(),ie=Pc(lT(uT(s),f,s,p,P,T,N,S,D,R,void 0,w),g,s===st.TOOLTIP&&!a,uh.POPOVER),le=oT(t?null:ie,x),V=En(C((Ce,ae)=>{ae instanceof Element&&(ae[Os]=void 0,delete ae[Os]),Ce instanceof Element&&(Ce[Os]=f.current,cancelAnimationFrame(U.current),U.current=requestAnimationFrame(()=>{if(W.current===a||!(W.current=a))return;const ye=dT(Ce);ye==null||ye.focus()}))},[a,f]),t?ie:le),Z=Lr(V),ge=A(()=>({[`${Ct}--medium`]:u===Hr.MEDIUM,[`${Ct}--with-divider`]:!!d,[`${Ct}--wide`]:u===Hr.WIDE,[`${Ct}--fit-content`]:l,[`${Ct}--without-space`]:h,[`${Ct}--auto-width`]:N}),[u,d,h,l,N]);G(()=>{V.current&&(V.current[Os]=f.current)},[V,f]),G(()=>(document.removeEventListener("keydown",L.current),document.addEventListener("keydown",L.current=j),()=>document.removeEventListener("keydown",L.current)),[j]);const Ne=s===st.TOOLTIP?ch:`${Ct} ${Ug}`,me=s===st.TOOLTIP?lh:`${ha}`;return Hu(i(Q,{children:a?i(Q,{children:[N&&i("div",{className:"adyen-pe-popover__overlay"}),i("div",{id:"popover",ref:Z,...b,className:M(Ne,ge,v),style:{visibility:"hidden"},role:b.role??(s===st.POPOVER?"dialog":"tooltip"),children:[(r||E)&&i("div",{className:Tc(jl,c,[jl]),children:[r&&i("div",{className:Wg,children:i(jg,{title:r})}),E&&i(Yg,{onClick:g})]}),y&&i(Q,{children:[i("div",{className:M(me,{[`${ha}--with-padding`]:_,[`${ha}--overlay`]:N}),ref:w,children:y}),s===st.TOOLTIP&&i("span",{"data-popover-placement":"hidden",ref:P,className:"adyen-pe-tooltip__arrow"})]}),e&&i("div",{className:Hg,children:i(fs,{actions:e,layout:n})})]})]}):null}),document.getElementsByTagName("body")[0])}const hT=()=>{const[e,t]=Vt(),n=C(()=>t(!0),[t]),s=C(()=>t(!1),[t]),r=C(a=>{switch(a.code){case ne.ESCAPE:s();break}},[s]);return{listeners:{onfocusoutCapture:s,onMouseLeave:s,onKeyDown:r,onFocus:n,onMouseEnter:n},isVisible:e}},pT=e=>typeof e=="string",Rn=({content:e,children:t,triggerRef:n,showTooltip:s,position:r,isContainerHovered:a=!1})=>{var l,h,u;const o=Lr(),{isVisible:c,listeners:d}=hT();return i(Q,{children:[t?Fu(t,{...t==null?void 0:t.props,role:"button",tabIndex:-1,ref:o,className:(l=t==null?void 0:t.props)!=null&&l.className?M(`${(h=t==null?void 0:t.props)==null?void 0:h.className} adyen-pe__tooltip-target`,{" adyen-pe__tooltip-target--hovered":a}):M("adyen-pe__tooltip-target",{"adyen-pe__tooltip-target--hovered":a}),...d,"aria-describedby":`tooltip-${(u=o.current)==null?void 0:u.id}`}):null,(c||s)&&i(ti,{fitPosition:!0,variant:st.TOOLTIP,targetElement:n??o,position:r,open:c||s,children:i(Q,{children:e&&pT(e)?i(I,{variant:O.CAPTION,children:e}):{content:e}})})]})};function fT({value:e,isContainerHovered:t}){const{i18n:n}=H(),s=`tooltip.${e}`;return i(Q,{children:n.has(s)&&i(Rn,{content:n.get(s),isContainerHovered:t,children:i("span",{children:i(I,{variant:O.BODY,children:n.has(`txType.${e}`)?n.get(`txType.${e}`):`${e}`})})})})}const qr={title:"thereWasAnUnexpectedError",message:["contactSupportForHelp"]},ph=(e,t)=>{if(!e)return null;switch(e.errorCode){case"29_001":return{title:"theRequestIsMissingRequiredFieldsOrContainsInvalidData",message:["contactSupportForHelp"],onContactSupport:t};case"30_112":return{title:"entityWasNotFound",message:["entityWasNotFoundDetail"],onContactSupport:t};case"00_403":return qr;default:return null}},$t=({textToCopy:e,isHovered:t,buttonLabel:n,showCopyTextTooltip:s=!0,type:r="Link",...a})=>{const{i18n:o}=H(),[c,d]=F(o.get("copy")),l=C(async()=>{if(e)try{await navigator.clipboard.writeText(e),d(o.get("copied"))}catch(u){console.log(u)}},[o,e]),h=C(()=>{d(o.get("copy"))},[o]);return i("span",{className:M("adyen-pe-copy-text__container",{"adyen-pe-copy-text__container--information":r==="Link"}),...a,children:[s?i(Rn,{content:e,isContainerHovered:t,children:i("span",{className:M({"adyen-pe-copy-text__label":r!=="Default","adyen-pe-copy-text__information":r==="Link","adyen-pe-copy-text__text":r==="Text"}),children:n||e})}):i("span",{className:M({"adyen-pe-copy-text__label":r!=="Default","adyen-pe-copy-text__information":r==="Link","adyen-pe-copy-text__text":r==="Text"}),children:n||e}),i(Rn,{content:c,children:i(_e,{variant:te.TERTIARY,className:"adyen-pe-copy-text",onClick:l,onBlur:h,onMouseLeaveCapture:h,"data-testid":"copyText",children:i("div",{className:M("adyen-pe-copy-text__icon",{"adyen-pe-copy-text__icon--information":r==="Link"}),children:i(ue,{name:"copy","data-testid":"copy-icon"})})})})]})},Fc=(e,t,n)=>{if(!e)return qr;const s=ph(e,n);if(s)return s;switch(e.errorCode){case void 0:return{title:"somethingWentWrong",message:[t,"tryRefreshingThePageOrComeBackLater"],refreshComponent:!0};case"00_500":{const r=n?"theErrorCodeIs":"contactSupportForHelpAndShareErrorCode";return{title:"somethingWentWrong",message:[t,r],translationValues:{[r]:e.requestId?i($t,{textToCopy:e.requestId}):null},onContactSupport:n}}default:return qr}},Fi=({error:e,errorMessage:t,onContactSupport:n})=>{const{title:s,message:r,refreshComponent:a,translationValues:o,onContactSupport:c}=Fc(e,t,n);return i(Qt,{title:s,message:r,translationValues:o,withImage:!0,centered:!0,refreshComponent:a,onContactSupport:c})},mT=({data:e,columns:t,customCells:n,onRowHover:s})=>{const{i18n:r}=H();return i(Q,{children:e==null?void 0:e.map((a,o)=>i("div",{role:"row",tabIndex:0,className:"adyen-pe-data-grid__row",onMouseEnter:r.has(`tooltip.${a==null?void 0:a.category}`)&&s?()=>s(o):he,onFocus:r.has(`tooltip.${a==null?void 0:a.category}`)&&s?()=>s(o):he,onMouseLeave:r.has(`tooltip.${a==null?void 0:a.category}`)&&s?()=>s():he,onBlur:r.has(`tooltip.${a==null?void 0:a.category}`)&&s?()=>s():he,children:i(nh,{columns:t,customCells:n,item:a,rowIndex:o})},a))})},_T=({totalRows:e})=>{const[t,n]=Oi((o,c)=>{const d=e;if(d>1){const l=c.index;if(l<d&&l>=0)return c.type==="ACTIVE"?Object.freeze({...o,index:c.index??0,activeIndex:c.index}):Object.freeze({...o,index:c.index??0,activeIndex:-1})}return o},RT),s=En(C(o=>{var d;if(!(o instanceof Element))return;const c=Number((d=o.dataset)==null?void 0:d.index);t.activeIndex===-1&&c===0||c===t.index?o.setAttribute("tabindex","0"):o.setAttribute("tabindex","-1"),c===t.activeIndex&&(o==null||o.focus())},[t.activeIndex,t.index])),r=C(o=>{var d,l;if(!(((d=o.target)==null?void 0:d.getAttribute("role"))==="row")){o.code===ne.ARROW_LEFT&&n({type:"ACTIVE",index:t.index});return}switch(o.code){case ne.ARROW_DOWN:case ne.ARROW_UP:n({type:"ACTIVE",index:o.code===ne.ARROW_DOWN?t.index+1:t.index-1});break;case ne.HOME:n({type:"ACTIVE",index:0});break;case ne.END:n({type:"ACTIVE",index:e-1});break;case ne.ENTER:(l=o.currentTarget)==null||l.click();break;default:return}o.stopPropagation()},[e,t.index]),a=C(o=>c=>{var l;(!(((l=c.target)==null?void 0:l.localName)==="tr")||t.index===-1)&&n({type:"CURRENT",index:o})},[t.index]);return{listeners:{onKeyDownCapture:r,onFocusCapture:a},ref:s,activeIndex:t.activeIndex,currentIndex:t.index}},gT=({data:e,columns:t,onRowClick:n,customCells:s,onRowHover:r})=>{const a=C(h=>()=>n==null?void 0:n.callback(n!=null&&n.retrievedField?h[n.retrievedField]:h),[n]),{i18n:o}=H(),{currentIndex:c,listeners:d,ref:l}=_T({totalRows:(e==null?void 0:e.length)??0});return i(Q,{children:e==null?void 0:e.map((h,u)=>i("div",{role:"row",tabIndex:0,onMouseEnter:o.has(`tooltip.${h==null?void 0:h.category}`)&&r?()=>r(u):he,onFocus:o.has(`tooltip.${h==null?void 0:h.category}`)&&r?()=>r(u):he,onMouseLeave:o.has(`tooltip.${h==null?void 0:h.category}`)&&r?()=>r():he,onBlur:o.has(`tooltip.${h==null?void 0:h.category}`)&&r?()=>r():he,ref:l,"aria-selected":u===c,"data-index":u,className:"adyen-pe-data-grid__row adyen-pe-data-grid__row--clickable",onClick:a(h),onFocusCapture:d.onFocusCapture(u),onKeyDownCapture:d.onKeyDownCapture,children:i(nh,{columns:t,customCells:s,item:h,rowIndex:u})},h))})},TT=({columnsNumber:e,loading:t,emptyMessageDisplay:n})=>{const s=Array.from({length:10},(a,o)=>o),r=Array.from({length:e},(a,o)=>o);return i(Q,{children:[s.map((a,o)=>i("div",{className:"adyen-pe-data-grid__row",children:r.map((c,d)=>i("div",{className:"adyen-pe-data-grid__cell adyen-pe-data-grid__skeleton-cell",children:i("span",{className:M({"adyen-pe-data-grid__skeleton-cell-content adyen-pe-data-grid__skeleton-cell-content--loading":t,"adyen-pe-data-grid__empty-cell":!t})})},`adyen-pe-data-grid-skeleton-cell-${d}`))},`adyen-pe-data-grid-skeleton-row-${o}`)),!t&&n&&n]})},yT="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='300'%20height='200'%20viewBox='0%200%20300%20200'%20fill='none'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23BF7C6A'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M189.3%20113.7c-1-.3%2036.3%2028.6%2047.7%2026.4%209.3-1.8%2014.3-59%2014.3-59h-9.9l-10.8%2036.3s-30.4-22.3-31.8-22.3c-1.4%200-8%2019.1-9.5%2018.6Z'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='m230.1%20116.7%202%203.2'/%3e%3cpath%20fill='%23BF7C6A'%20d='m259.8%2074.6%2010-3.6.7-8.1c.1-.9-.6-1.6-1.4-1.7-.8-.1-1.5.5-1.7%201.3l-1.3%206.6-12.6%204.8'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='m259.8%2074.6%2010-3.6.7-8.1c.1-.9-.6-1.6-1.4-1.7-.8-.1-1.5.5-1.7%201.3l-1.3%206.6-12.6%204.8'/%3e%3cpath%20fill='%23BF7C6A'%20d='m260.5%2075.5%2011.1-3.5%202.9-7.1c.3-.8-.1-1.7-.9-2.1-.8-.3-1.6%200-2%20.7l-3.2%205.9-10.2%203.2'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='m260.5%2075.5%2011.1-3.5%202.9-7.1c.3-.8-.1-1.7-.9-2.1-.8-.3-1.6%200-2%20.7l-3.2%205.9-10.2%203.2'/%3e%3cpath%20fill='%23BF7C6A'%20d='m254%2076.5%207.4-7.8c.7-.6.8-1.5.2-2.2-.5-.7-1.5-.8-2.2-.4-2%201.3-6.2%205-10.7%207.1-3.1%201.4-5.2%205.8-5.8%207.3'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='m254%2076.5%207.4-7.8c.7-.6.8-1.5.2-2.2-.5-.7-1.5-.8-2.2-.4-2%201.3-6.2%205-10.7%207.1-3.1%201.4-5.2%205.8-5.8%207.3'/%3e%3cpath%20fill='%23BF7C6A'%20d='M250.3%2082.2c1.2-.3%2021.6-8.6%2026.7-10.3.9-.3%201.4-1.2%201.1-2.1-.2-.9-1-1.1-1.9-1-4.4.8-17.9%203.9-19.5%204.2-1.5.2-5.3.6-10.9%203.1a9%209%200%200%200-5.2%208'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M250.3%2082.2c1.2-.3%2021.6-8.6%2026.7-10.3.9-.3%201.4-1.2%201.1-2.1-.2-.9-1-1.1-1.9-1-4.4.8-17.9%203.9-19.5%204.2-1.5.2-5.3.6-10.9%203.1a9%209%200%200%200-5.2%208'/%3e%3cpath%20fill='%2300112C'%20d='M130.9%2063.1c.8%207.3%204.7%2014.1%2010.3%2018l-3.1-6.4c-.5-1-.9-2-1-3.1l-.1-.3c-.1-.1-.1.2%200%20.1'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M130.9%2063.1c.8%207.3%204.7%2014.1%2010.3%2018l-3.1-6.4c-.5-1-.9-2-1-3.1l-.1-.3c-.1-.1-.1.2%200%20.1'/%3e%3cpath%20fill='%23BF7C6A'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='m158.9%2074.8-13.2.2-1.5%2018%208.4%203.6%207.9-3.8-1.6-18Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M151.9%2083.9c-4.7%200-6.4-2.7-6.4-2.7v-4.6h13.4l.3%206c-.1.1-2.5%201.3-7.3%201.3Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M134.5%2070.7c2.4%203%206.3%205.7%209.8%207.3%203.6%201.6%2015.3%201.7%2019.5-1.1%208.8-5.9%2010.5-20.3%208.2-30.6-.7-3.4-1.8-6.8-3.7-9.7a22%2022%200%200%200-19.8-9.3c-7.5.5-19.3%205.9-20.8%2014.2-1.7%209.6.8%2021.6%206.8%2029.2Z'/%3e%3cpath%20fill='%23BF7C6A'%20d='M133.2%2058.9s-5.1-7-7.8-1.6%204.8%2013.4%2010.8%2011.2'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M133.2%2058.9s-5.1-7-7.8-1.6%204.8%2013.4%2010.8%2011.2'/%3e%3cpath%20fill='%23BF7C6A'%20d='M169.5%2052.4s2.3-8.3%206.7-4.2c4.4%204.1.2%2014.2-6.2%2014.3'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M169.5%2052.4s2.3-8.3%206.7-4.2c4.4%204.1.2%2014.2-6.2%2014.3'/%3e%3cpath%20fill='%23BF7C6A'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M166.9%2041.2c-6.3-12-33.4-8.2-34.9%206.3A38.2%2038.2%200%200%200%20142%2077c5.7%205.2%2012%204.5%2014.1%204.1%202.1-.3%208.2-1.8%2011.7-8.8a37.2%2037.2%200%200%200-.9-31.1Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M134.1%2055c7.8-1.1%2015.5-2.6%2023.1-4.4l-.4-4.8c1%201.6%201.8%202.7%202.4%204.5%203-1.3%206.3-1.5%209.5-1.6%203.1-.1-4.2-14.3-6.1-15.6a16.2%2016.2%200%200%200-7.1-2.1c-5.7-.6-11.7-.4-16.7%202.3-4%202.2-7.3%206.4-7.6%2011%200%201.5.5%2011%202.9%2010.7Z'/%3e%3cpath%20fill='%23BF7C6A'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M114.5%20113.7c1-.3-36.3%2028.6-47.7%2026.4-9.3-1.8-14.3-59-14.3-59h9.9l10.8%2036.3s30.4-22.3%2031.8-22.3c1.5-.1%208.1%2019.1%209.5%2018.6Z'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='m73.8%20116.7-2.1%203.2'/%3e%3cpath%20fill='%23BF7C6A'%20d='M44%2074.6%2034%2071l-.7-8.1c-.1-.9.6-1.6%201.4-1.7.8-.1%201.5.5%201.7%201.3l1.3%206.6%2012.6%204.8'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M44%2074.6%2034%2071l-.7-8.1c-.1-.9.6-1.6%201.4-1.7.8-.1%201.5.5%201.7%201.3l1.3%206.6%2012.6%204.8'/%3e%3cpath%20fill='%23BF7C6A'%20d='M43.3%2075.5%2032.2%2072l-2.9-7c-.3-.8.1-1.7.9-2.1.8-.3%201.6%200%202%20.7l3.2%205.9%2010.2%203.2'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M43.3%2075.5%2032.2%2072l-2.9-7c-.3-.8.1-1.7.9-2.1.8-.3%201.6%200%202%20.7l3.2%205.9%2010.2%203.2'/%3e%3cpath%20fill='%23BF7C6A'%20d='m49.8%2076.5-7.4-7.8c-.7-.6-.8-1.5-.2-2.2.5-.7%201.5-.8%202.2-.4%202%201.3%206.2%205%2010.7%207.1%203.1%201.4%205.2%205.8%205.8%207.3'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='m49.8%2076.5-7.4-7.8c-.7-.6-.8-1.5-.2-2.2.5-.7%201.5-.8%202.2-.4%202%201.3%206.2%205%2010.7%207.1%203.1%201.4%205.2%205.8%205.8%207.3'/%3e%3cpath%20fill='%23BF7C6A'%20d='M53.5%2082.2C52.4%2081.9%2032%2073.7%2026.8%2072a1.6%201.6%200%200%201-1.1-2.1c.2-.9%201-1.1%201.9-1%204.4.8%2017.9%203.9%2019.5%204.2%201.5.2%205.3.6%2010.9%203.1a9%209%200%200%201%205.2%208'/%3e%3cpath%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M53.5%2082.2C52.4%2081.9%2032%2073.7%2026.8%2072a1.6%201.6%200%200%201-1.1-2.1c.2-.9%201-1.1%201.9-1%204.4.8%2017.9%203.9%2019.5%204.2%201.5.2%205.3.6%2010.9%203.1a9%209%200%200%201%205.2%208'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='M139.9%2087.6c-1.4-3.4-6.3-12.5-9.8-11.7a90.7%2090.7%200%200%200-46.2%2029.7c-4.4%205.4-2%208.7-2%208.7l7.1%2018.8s3.6%202%2015.4%201.7c17.4-.5%2038.8-26.8%2039.5-30.6.4-2.6-1.7-10.8-4-16.6Z'/%3e%3cpath%20fill='%233300C2'%20d='m196.6%20232.8-18.7-58.1h-51l-20.2%2058.1'/%3e%3cpath%20stroke='%230C112C'%20stroke-miterlimit='10'%20d='m196.6%20232.8-18.7-58.1h-51l-20.2%2058.1'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='m159.1%2091.8-16.8.1s-20.4%201-21.3%206.8c-1.6%2010.6%206.1%2052.6%205.9%2056.2l-4.8%2020.4.2.1c10.7%205%2022.7%207.2%2034.6%206.2l23.1-1.9-3.2-18.2c-.2-2.7%207.3-46%206.9-61.3-.1-7.1-24.6-8.4-24.6-8.4Z'/%3e%3cpath%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-miterlimit='10'%20d='m141.4%2092%201.6-5.6h18.7l1.1%204.9c-.1.1-8.9%2011-21.4.7Zm23.1-4.4c1.4-3.4%206.3-12.5%209.8-11.7a90.7%2090.7%200%200%201%2046.2%2029.7c4.4%205.4%202%208.7%202%208.7l-7.1%2018.8s-3.6%202-15.4%201.7c-17.4-.5-38.8-26.8-39.5-30.6a48.3%2048.3%200%200%201%204-16.6ZM119.9%2018c0-2.5%201.1-4.9%202.7-6.8%201.9-2.2%204.5-3.8%207.4-4.2%202.9-.4%205.9.6%207.9%202.7a4.8%204.8%200%200%200-3-4.1s5-.2%207.1.4a14.7%2014.7%200%200%201%2011%2017.8c-2.3%208.8-14.2%207-21%205.6-5.6-1.2-12-4.9-12.1-11.4Z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h300v200H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",AT=({children:e})=>{const t=A(()=>new Map,[]),n=C(({column:r,width:a})=>{if(t.has(r)){const o=t.get(r);a>o&&t.set(r,a)}else t.set(r,a)},[t]),s=C(r=>t.get(r),[t]);return i(th.Provider,{value:{registerCells:n,getMinWidthByColumn:s},children:Mn(e)})},vT=({cellKey:e,position:t,label:n})=>{const{registerCells:s}=Dc(),r=q(null);return G(()=>{var a;r.current&&s({column:e,width:(a=r.current)==null?void 0:a.getBoundingClientRect().width})},[e,s]),i("div",{role:"columnheader",id:String(e),className:M("adyen-pe-data-grid__cell adyen-pe-data-grid__cell--heading",{"adyen-pe-data-grid__cell--right":t==="right","adyen-pe-data-grid__cell--center":t==="center"}),children:i("div",{ref:r,className:"adyen-pe-data-grid__cell--heading-content",children:n})})},RT=Object.freeze({activeIndex:-1,index:-1});function tn({errorDisplay:e,...t}){return i("div",{style:{width:"100%"},children:i(AT,{children:i(CT,{...t,errorDisplay:e})})})}function CT({autoFitColumns:e,errorDisplay:t,...n}){var h,u;const s=A(()=>Mn(n.children),[n.children]),r=A(()=>s.find(p=>(p==null?void 0:p.type)===fh),[s]),a=A(()=>{var p;return((p=n.data)==null?void 0:p.length)===0},[n.data]),o=A(()=>!n.loading&&(a||n.error),[a,n.error,n.loading]),{getMinWidthByColumn:c}=Dc(),d=n.columns.filter(p=>p.visible!==!1).map(p=>({...p,minWidth:c(p.key)})),l=d.map(p=>`minmax(${(p.minWidth||100)+40}px, ${p.flex||1}fr)`).join(" ");return i("div",{className:M("adyen-pe-data-grid",{"adyen-pe-data-grid--condensed":n.condensed,"adyen-pe-data-grid--outline":n.outline,"adyen-pe-data-grid--scrollable":n.scrollable,"adyen-pe-data-grid--loading":n.loading,"adyen-pe-data-grid--empty":a||n.error}),style:e?void 0:{"--adyen-pe-data-grid-cols":d.length,"--adyen-pe-data-grid-cells":l},children:i(Q,{children:[i("div",{className:"adyen-pe-data-grid__table-wrapper",children:[i("div",{role:"table",className:"adyen-pe-data-grid__table",children:[i("div",{className:"adyen-pe-data-grid__head",role:"rowgroup",children:i("div",{role:"rowheader",className:"adyen-pe-data-grid__header",style:n.loading?{width:"100%"}:{},children:d.map(p=>i(vT,{label:p.label,position:p.position,cellKey:p.key},p.key))})}),i(ST,{...n,columns:d,emptyBody:a})]}),o&&(a&&!n.error?i(Qt,{title:((h=n.emptyTableMessage)==null?void 0:h.title)??"thereAreNoResults",message:(u=n.emptyTableMessage)==null?void 0:u.message,imageDesktop:yT,centered:!0}):n.error&&t?t():null)]}),r]})})}function ST(e){const t=A(()=>e.loading||e.emptyBody||e.error,[e.emptyBody,e.error,e.loading]);return i("div",{role:"rowgroup",className:M("adyen-pe-data-grid__body"),style:t&&{display:"grid",gridTemplateColumns:"1fr"},children:t?i(TT,{columnsNumber:e.columns.length,loading:e.loading}):e.onRowClick?i(gT,{onRowHover:e.onRowHover,data:e.data,columns:e.columns,onRowClick:e.onRowClick,customCells:e.customCells}):i(mT,{onRowHover:e.onRowHover,data:e.data,customCells:e.customCells,columns:e.columns})})}tn.Footer=fh;function fh({children:e}){return i("div",{className:"adyen-pe-data-grid__footer",children:e})}tn.defaultProps={condensed:!1,outline:!0,scrollable:!0};const ni="-ariaError";var Je=(e=>(e[e.NONE=0]="NONE",e[e.APPLY=1]="APPLY",e[e.CLEAR=2]="CLEAR",e))(Je||{});const mh=({applyDisabled:e,applyTitle:t,resetDisabled:n,resetTitle:s}=z)=>{const{i18n:r}=H(),[a,o]=F(Je.NONE),c=C(()=>o(Je.APPLY),[o]),d=C(()=>o(Je.CLEAR),[o]),l=C(()=>o(Je.NONE),[o]),h=A(()=>({disabled:Ve(e),event:c,title:(t==null?void 0:t.trim())||r.get("apply"),variant:te.PRIMARY}),[r,c,e,t]),u=A(()=>({disabled:Ve(n),event:d,title:(s==null?void 0:s.trim())||r.get("reset"),variant:te.SECONDARY}),[r,d,n,s]),p=A(()=>[h,u],[h,u]),f=A(()=>a!==Je.NONE,[a]);return G(()=>{switch(a){case Je.APPLY:case Je.CLEAR:l();break}},[a,l]),{commitAction:a,commitActionButtons:p,committing:f,resetCommitAction:l}};function _h(e){const{backgroundUrl:t="",className:n="",classNameModifiers:s=[],src:r="",alt:a="",showOnError:o=!1}=e,[c,d]=F(!1),l=q(null),h=()=>{d(!0)},u=()=>{d(o)},p=M([n],"adyen-pe-image",{"adyen-pe-image--loaded":c},...s.map(f=>`adyen-pe-image--${f}`));return G(()=>{const f=t?new Image:l.current;f&&(f.src=t||r,f.onload=h),d(!!(f!=null&&f.complete))},[]),t?i("div",{style:{backgroundUrl:t},...e,className:p}):i("img",{...e,alt:a,ref:l,className:p,onError:u})}const ur="adyen-pe-dropdown",ET=Tc(mt,[te.SECONDARY],[mt]),sn=`${ur}__button`,NT=`${sn}--active`,DT=`${sn}-collapse-indicator`,bT=`${sn}--has-selection`,OT=`${sn}-icon`,IT=`${sn}-multiselect-counter`,PT=`${sn}--readonly`,kT=`${sn}-text`,wT=`${sn}--valid`,LT=`${sn}--invalid`,Nn=`${ur}__element`,FT=`${Nn}--active`,MT=`${Nn}-checkbox`,xT=`${Nn}-checkmark`,BT=`${Nn}-content`,$T=`${Nn}--disabled`,UT=`${Nn}-icon`,WT=`${Nn}--no-option`,gh=`${ur}__list`,HT=`${gh}--active`,GT=`${ur}--multiselect`,YT=({active:e,disabled:t,className:n,filterable:s,toggleButtonRef:r,...a})=>{const o=A(()=>s?M(ET,n):n,[n,s]);return s?i("div",{...a,className:o,ref:r}):i(_e,{...a,className:o,disabled:t,variant:te.SECONDARY,ref:r})},qT=e=>{var p,f;const{i18n:t}=H(),{active:n,filterable:s,multiSelect:r,placeholder:a,readonly:o,showList:c,withoutCollapseIndicator:d}=e,l=A(()=>(a==null?void 0:a.trim())||t.get("select.filter.placeholder"),[t,a]),h=A(()=>Ve(r)?void 0:n[0],[n,r]),u=A(()=>{var T;return((T=h==null?void 0:h.name)==null?void 0:T.trim())||l},[h,l]);return i(YT,{active:n,disabled:o,"aria-disabled":o,"aria-expanded":c,"aria-haspopup":"listbox",className:M(sn,{[NT]:c,[bT]:!!n.length,[PT]:o,[LT]:e.isInvalid,[wT]:e.isValid}),filterable:s,onClick:o?void 0:e.toggleList,onKeyDown:o?void 0:e.onButtonKeyDown,role:s?"button":void 0,tabIndex:0,title:u,toggleButtonRef:e.toggleButtonRef,type:s?void 0:"button","aria-describedby":e.ariaDescribedBy,id:e.id??"",children:[c&&s?i("input",{"aria-autocomplete":"list","aria-controls":e.selectListId,"aria-expanded":c,"aria-owns":e.selectListId,autoComplete:"off",className:"adyen-pe-filter-input",onInput:e.onInput,placeholder:l,ref:e.filterInputRef,role:"combobox",type:"text"}):i(Q,{children:[(h==null?void 0:h.icon)&&i(_h,{className:OT,src:h.icon,alt:((p=h==null?void 0:h.name)==null?void 0:p.trim())??""}),i("span",{className:kT,children:((f=h==null?void 0:h.selectedOptionName)==null?void 0:f.trim())||u}),r&&e.appliedFilterNumber>0&&i("div",{className:IT,children:i(I,{el:J.SPAN,variant:O.BODY,stronger:!0,children:e.appliedFilterNumber})})]}),!d&&i("span",{className:DT,children:i(ue,{name:"chevron-down"})})]})},jT=e=>{var d;const{componentRef:t}=H(),[n,s]=F(((d=t.current)==null?void 0:d.offsetWidth)||0),[r,a,o]=e;let c=!1;switch(r){case"up":c=n>=a;break;case"down":c=n<=a;break;case"only":if(o){const{min:l,max:h}=o;c=h?n<=h:l?n>=l:!1}else c=n===a;break}return G(()=>{const l=t.current;if(!l)return;const h=new ResizeObserver(u=>{for(const p of u)p.target===l&&s(l.offsetWidth)});return h.observe(l),()=>{h.unobserve(l),h.disconnect()}},[t]),c},Ie={up:{sm:["up",Ht.sm],md:["up",Ht.md]},down:{xs:["down",Ht.sm-1],sm:["down",Ht.md-1]},only:{xs:["only",Ht.sm-1,{max:Ht.sm-1}],sm:["only",Ht.sm,{max:Ht.md-1}],md:["only",Ht.md,{max:Ht.lg-1}]}},Pe=jT;function VT(e){var c;const[t,n]=F(performance.now()),[s,r]=F(),a=C(d=>d&&e.fixedPositioning?d.scrollHeight>d.offsetHeight:!1,[e.fixedPositioning]),o=(c=e.targetElement.current)==null?void 0:c.offsetParent;return G(()=>{if(!a(o))return;const{height:d,y:l}=o.getBoundingClientRect();r({minY:l,maxY:l+d});let h=null;const u=()=>{h&&cancelAnimationFrame(h),h=requestAnimationFrame(()=>{h=null,n(performance.now())})};return o.addEventListener("scroll",u,{passive:!0}),()=>{o.removeEventListener("scroll",u),h&&cancelAnimationFrame(h),h=null}},[o,a]),e.fixedPositioning?i(ti,{...e,position:se.BOTTOM,additionalStyle:s}):i(ti,{...e})}const zT=e=>e.multiSelect?i("span",{className:MT,children:e.selected?i(ue,{name:"checkmark-square-fill"}):i(ue,{name:"square"})}):null,Th=e=>e.multiSelect?null:i("span",{className:xT,children:e.selected&&i(ue,{name:"checkmark"})}),KT=e=>i(Q,{children:[zT(e),i("div",{className:e.contentClassName,children:[e.item.icon&&i(_h,{className:e.iconClassName,alt:e.item.name,src:e.item.icon}),i("span",{children:e.item.name})]}),Th(e)]}),XT=({item:e,multiSelect:t,onKeyDown:n,onSelect:s,renderListItem:r,selected:a})=>{const o=!!e.disabled,c=Ve(e.disabled)||null,d=M(Nn,{[FT]:a,[$T]:o});return i("li",{"aria-disabled":o,"aria-selected":a,className:d,"data-disabled":c,"data-value":e.id,onClick:s,onKeyDown:n,title:e.name,role:"option",tabIndex:-1,children:r({item:e,multiSelect:t,selected:a,contentClassName:BT,iconClassName:UT})})},ZT=Ue(XT),QT=Cn(({active:e,commitActions:t,items:n,multiSelect:s,onKeyDown:r,onSelect:a,renderListItem:o,selectListId:c,showList:d,textFilter:l,toggleButtonRef:h,dismissPopover:u,setToTargetWidth:p,popoverClassNameModifiers:f,showOverlay:T,fitPosition:g,fixedPopoverPositioning:y},_)=>{const{i18n:v}=H(),N=Pe(Ie.down.xs),S=n.filter(P=>!l||P.name.toLowerCase().includes(l)),D=M(gh,{[HT]:d}),R=M(Nn,WT),b=A(()=>ee(o)?o:KT,[o]),E=A(()=>Ve(s),[s]);return d?i(VT,{classNameModifiers:f,actions:E?t:void 0,disableFocusTrap:!0,divider:!0,dismiss:u,dismissible:!1,open:d,setToTargetWidth:p,containerSize:Hr.MEDIUM,variant:st.POPOVER,targetElement:h,withContentPadding:!1,position:se.BOTTOM,showOverlay:T&&N,fitPosition:g,fixedPositioning:y,children:i("ul",{className:D,id:c,ref:_,role:"listbox","aria-multiselectable":E,children:S.length?S.map(P=>i(ZT,{item:P,multiSelect:E,onKeyDown:r,onSelect:a,renderListItem:b,selected:e.includes(P)},P.id)):i("div",{className:R,children:v.get("select.noOptionsFound")})})}):null}),JT=Ue(QT),e1=({items:e,multiSelect:t,selected:n})=>{const s=C((d=Se)=>{const l=Se.concat(d??Se).filter(Boolean),h=e.filter(p=>l.includes(p.id)),u=t?h:h.slice(0,1);return u.length?Object.freeze(u):Se},[e,t]),[r,a]=F(s(n)),o=C((d=Se)=>{const l=d.filter(h=>e.includes(h));a(l.length?Object.freeze(l):Se)},[e,a]),c=C(d=>{a(l=>{const h=l.indexOf(d);if(h<0)return Object.freeze((t?l:Se).concat(d));if(!t)return l;const u=[...l];return u.splice(h,1),u.length?Object.freeze(u):Se})},[t,a]);return G(()=>a(s(n)),[s,n,a]),{resetSelection:o,select:c,selection:r}},Bn=({className:e,classNameModifiers:t=Se,popoverClassNameModifiers:n,items:s=Se,filterable:r=!1,multiSelect:a=!1,readonly:o=!1,onChange:c=he,selected:d,name:l,isInvalid:h,isValid:u,placeholder:p,uniqueId:f,renderListItem:T,isCollatingErrors:g,setToTargetWidth:y,withoutCollapseIndicator:_=!1,showOverlay:v=!1,fitPosition:N,fixedPopoverPositioning:S})=>{const{resetSelection:D,select:R,selection:b}=e1({items:s,multiSelect:a,selected:d}),[E,P]=F(!1),[w,W]=F(""),x=q(null),j=q(null),L=q(null),U=q(`select-${Si()}`),ie=q(),le=q(!0),V=q(!1),Z=q(b),ge=q(b),Ne=A(()=>b.length,[b]),me=C(()=>{W(""),P(!1),E&&(D(Z.current),le.current=!0)},[D,P,W,E]),Ce=A(()=>M([ur,{[GT]:Ve(a)},...t.map(Te=>`${ur}--${Te}`),e]),[e,t,a]),{commitAction:ae,commitActionButtons:ye,committing:We,resetCommitAction:pe}=mh({resetDisabled:!b.length}),$e=C(()=>{var Te;W(""),P(!1),pe(),le.current?le.current=!1:(Te=L.current)==null||Te.focus()},[pe,P,W]),He=C(()=>{Z.current=b;const Te=`${b.map(({id:we})=>we)}`;c({target:{value:Te,name:l}})},[l,c,b]);G(()=>{switch(ae){case Je.APPLY:He();break;case Je.CLEAR:D(),V.current=!0;break}},[ae,He,D]);const De=C(Te=>{var Le;Te.preventDefault();const we=Te.currentTarget&&((Le=j==null?void 0:j.current)!=null&&Le.contains(Te.currentTarget))?Te.currentTarget:null;if(we&&!we.getAttribute("data-disabled")){const on=we.getAttribute("data-value"),$n=s.find(_s=>_s.id===on);R($n)}},[s,R]);G(()=>{ge.current!==b&&(ge.current=b,(!a||V.current)&&(He(),$e())),V.current=!1},[$e,He,a,b]),G(()=>{We&&$e()},[We,$e]);const gt=C(Te=>{switch(Te.code){case ne.ESCAPE:case ne.TAB:E&&$e(),le.current=Te.key===ne.TAB;return;case ne.ENTER:case ne.SPACE:if(r&&E){if(Te.key===ne.ENTER)if(w)De(Te);else break;return}break;case ne.ARROW_DOWN:case ne.ARROW_UP:break;default:return}Te.preventDefault(),P(!0)},[$e,r,De,E,P,w]);G(()=>{E&&(cancelAnimationFrame(ie.current),ie.current=requestAnimationFrame(()=>{var Te;e:{let we=(Te=j.current)==null?void 0:Te.firstElementChild,Le;for(;we;){if(!(we.dataset.disabled&&we.dataset.disabled==="true")){if(we.getAttribute("aria-selected")==="true"){we.focus();break e}Le=Le||we}we=we.nextElementSibling}Le&&Le.focus()}}))},[E]);const bn=C(Te=>{const we=Te.target;switch(Te.code){case ne.ESCAPE:Te.preventDefault(),$e();break;case ne.ENTER:case ne.SPACE:De(Te);break;case ne.ARROW_DOWN:{Te.preventDefault();let Le=we.nextElementSibling;for(;Le;){if(!(Le.dataset.disabled&&Le.dataset.disabled==="true")){Le.focus();break}Le=Le.nextElementSibling}break}case ne.ARROW_UP:{Te.preventDefault();e:{let Le=we.previousElementSibling;for(;Le;){if(!(Le.dataset.disabled&&Le.dataset.disabled==="true")){Le.focus();break e}Le=Le.previousElementSibling}r&&x.current&&x.current.focus()}break}case ne.TAB:$e();break}},[$e,r,De]),rn=C(Te=>{const we=Te.target.value;W(we.toLowerCase())},[W]),Tr=C(Te=>{Te.preventDefault(),P(we=>!we),E&&D(Z.current)},[P,E,D]);return G(()=>{var Te;E&&r&&((Te=x.current)==null||Te.focus())},[r,E]),i("div",{className:Ce,children:[i(qT,{id:f??void 0,appliedFilterNumber:Ne,active:b,filterInputRef:x,filterable:r,isInvalid:h,isValid:u,onButtonKeyDown:gt,onInput:rn,multiSelect:a,placeholder:p,readonly:o,selectListId:U.current,showList:E,toggleButtonRef:L,toggleList:Tr,withoutCollapseIndicator:_,ariaDescribedBy:!g&&f?`${f}${ni}`:void 0}),i(JT,{popoverClassNameModifiers:n,setToTargetWidth:y,dismissPopover:me,active:b,commitActions:ye,items:s,multiSelect:a,onKeyDown:bn,onSelect:De,selectListId:U.current,ref:j,toggleButtonRef:L,renderListItem:T,showList:E,showOverlay:v,textFilter:w,fitPosition:N,fixedPopoverPositioning:S})]})};function Mi({next:e,hasNext:t,hasPrev:n,prev:s,limit:r,limitOptions:a,onLimitSelection:o}){const{i18n:c}=H(),d=A(()=>a&&Object.freeze(a.map(h=>({id:`${h}`,name:`${h}`}))),[a]),l=C(({target:h})=>{xe(h==null?void 0:h.value)||o==null||o(+h.value)},[o]);return i("div",{"aria-label":c.get("paginatedNavigation"),className:`adyen-pe-pagination ${M({})}`,children:[i("div",{className:"adyen-pe-pagination__context",children:d&&o&&i(Q,{children:[i("span",{children:c.get("pagination.showing")}),i("div",{className:"adyen-pe-pagination__limit-selector",children:i(Bn,{setToTargetWidth:!0,filterable:!1,multiSelect:!1,items:d,onChange:l,selected:`${r??""}`})})]})}),i("div",{className:"adyen-pe-pagination__controls",children:[i(_e,{variant:te.TERTIARY,disabled:!n,iconButton:!0,classNameModifiers:["circle"].concat(n?Se:"disabled"),onClick:s,children:[i(ue,{name:"chevron-left"}),i("span",{className:"adyen-pe-visually-hidden",children:c.get("pagination.previousPage")})]}),i(_e,{variant:te.TERTIARY,disabled:!t,iconButton:!0,classNameModifiers:["circle"].concat(t?Se:"disabled"),onClick:e,children:[i("span",{className:"adyen-pe-visually-hidden",children:c.get("pagination.nextPage")}),i(ue,{name:"chevron-right"})]})]})]})}const ms="adyen-pe-transactions-table",t1=ms+"__amount",n1=ms+"__payment-method",s1=ms+"__payment-method-logo-container",r1=ms+"__payment-method-logo",o1=ms+"__date-and-payment-method",i1=ms+"__date-and-payment-method--date",a1="https://cdf6519016.cdn.adyen.com/checkoutshopper/",c1=({name:e,resourceContext:t,imageFolder:n="logos/",parentFolder:s="",extension:r="svg",size:a="",subFolder:o=""})=>{const c=`/images/${n}/${o}/${s}/${e}${a}.${r}`.replace(/\/+/g,"/");return`${t}${c}`},l1=({options:e=z,name:t})=>{const{loadingContext:n}=H();return A(()=>c1({resourceContext:a1,name:t,...e}),[n,t,e])},yh=({folder:e="components/",className:t,alt:n,name:s,extension:r})=>{const a=l1({options:A(()=>({imageFolder:e,extension:r}),[r,e]),name:s});return i("img",{className:M("adyen-pe__image",t),alt:n,src:a})},Is=({paymentMethod:e,bankAccount:t})=>{const{i18n:n}=H(),s=Pe(Ie.down.xs);return i("div",{className:n1,children:e||t?i(Q,{children:[i("div",{className:s1,children:i(yh,{name:e?e.type:"bankTransfer",alt:e?e.type:"bankTransfer",folder:"logos/",className:r1})}),i(I,{variant:O.BODY,stronger:s,children:e?rh(e):t==null?void 0:t.accountNumberLastFourDigits})]}):i(ot,{label:n.get("noData"),variant:Oe.LIGHT_WITH_OUTLINE})})},d1={id:"paymentId",transactionType:"transactionType",createdAt:"date",balanceAccountId:"balanceAccount",accountHolderId:"account",amount:"txAmount",description:"description",status:"status",category:"category",paymentMethod:"paymentMethod",currency:"currency",fundsCapturedAmount:"fundsCaptured",payoutAmount:"netPayout",adjustmentAmount:"adjustments",dateAndPaymentMethod:"date",dateAndReportType:"date",reportType:"report",reportFile:"file"},Ah=e=>d1[e]||e;function u1(e){let t={};for(const n of Object.keys(e))oe(e[n])||(t={...t,[n]:e[n]});return t}const xi=({fields:e,customColumns:t,columnConfig:n,fieldsKeys:s})=>{const{i18n:r}=H(),a=A(()=>e.map(d=>({key:d})),[e]),o=Pe(Ie.up.sm);return A(()=>{const d=(t==null?void 0:t.filter(p=>!(e!=null&&e.some(f=>f===p.key))).map(p=>p.key))||[],l=[...a,...(t==null?void 0:t.filter(p=>p==null?void 0:p.key))||[]],h=(t==null?void 0:t.reduce((p,f)=>(p[f.key]=f,p),{}))||{},u=new Map;return l.forEach(p=>{const f=h[p.key];if((f==null?void 0:f.visibility)!=="hidden")if(u.has(p.key)){const T=u.get(p.key);u.set(p.key,{...T,...p,visible:p.visibility!=="hidden",position:p.align||T.position})}else{const{key:T,flex:g,align:y}=p,_=r.get(Ah((s==null?void 0:s[T])||T)),v=u1((n==null?void 0:n[T])||z);u.set(p.key,{key:T,label:_,visible:d.includes(p.key)?o:!0,flex:g,position:y,...v})}}),Array.from(u.values())},[n,t,e,r,o,a])},Mc=["createdAt","paymentMethod","transactionType","amount"],h1=({activeBalanceAccount:e,availableCurrencies:t,error:n,hasMultipleCurrencies:s,loading:r,onContactSupport:a,onRowClick:o,showDetails:c,showPagination:d,transactions:l,customColumns:h,...u})=>{const{i18n:p}=H(),{dateFormat:f}=Pt(e==null?void 0:e.timeZone),[T,g]=F(),y=Pe(Ie.up.sm),_=Pe(Ie.up.md),v=Pe(Ie.down.xs),N=p.get("amount"),S=xi({fields:Mc,customColumns:h,columnConfig:{amount:{label:s?void 0:`${N} ${t&&t[0]?`(${Tu(t[0])})`:""}`,position:"right",flex:y?1.5:void 0},transactionType:{visible:_},paymentMethod:{visible:y}}}),D={title:"noTransactionsFound",message:["tryDifferentSearchOrResetYourFiltersAndWeWillTryAgain"]},R=C(E=>{g(E??void 0)},[g]),b=A(()=>()=>i(Fi,{error:n,onContactSupport:a,errorMessage:"weCouldNotLoadYourTransactions"}),[n,a]);return i("div",{className:ms,children:i(tn,{errorDisplay:b,error:n,columns:S,data:l,loading:r,outline:!1,onRowClick:{callback:o},onRowHover:R,emptyTableMessage:D,customCells:{transactionType:({item:E,rowIndex:P})=>{const w=`tooltip.${E.category}`;return E.category?p.has(w)?i(fT,{isContainerHovered:P===T,value:E.category}):i(I,{variant:O.BODY,children:p.has(`txType.${E.category}`)?p.get(`txType.${E.category}`):`${E.category}`}):null},amount:({value:E})=>{const P=p.amount(E.value,E.currency,{hideCurrency:!s});return i(I,{variant:O.BODY,className:t1,children:P})},createdAt:({item:E,value:P})=>v?i("div",{className:o1,children:[i(Is,{paymentMethod:E.paymentMethod,bankAccount:E.bankAccount}),i(I,{variant:O.BODY,className:i1,children:f(E.createdAt,K_)})]}):i(I,{variant:O.BODY,children:f(P,z_)}),paymentMethod:({item:E})=>i(Is,{paymentMethod:E.paymentMethod,bankAccount:E.bankAccount})},children:d&&i(tn.Footer,{children:i(Mi,{...u})})})})},_t="adyen-pe-transaction-data",p1=`${_t}__amount`,f1=`${_t}__action-bar`,Bi=`${_t}__container`,m1=`${_t}__head-container`,xc=`${_t}__input`,So=`${xc}-container`,vh=`${So}--short`,_1=`${So}--text-input`,g1=`${So}--with-error`,Rh=`${xc}-head`,T1=`${_t}__label`,y1=`${_t}__list`,A1=`${_t}__tags`,v1=`${_t}__status-box`,R1=`${_t}__refund-response`,si=`${_t}__refund-response-icon`,C1=`${si}--success`,S1=`${si}--error`,E1=`${_t}__refund-statuses-container`,Ch=new Set(["status","category","paymentMethod","bankAccount","balanceAccount","id","balanceAccountId",...Mc,"deductedAmount","lineItems","originalAmount","paymentPspReference","refundDetails","refundMetadata"]),N1=()=>{var r;const{i18n:e}=H(),{transaction:t,extraFields:n,dataCustomization:s}=Og();return A(()=>{const{balanceAccount:a,category:o,id:c,paymentPspReference:d,refundMetadata:l}=t,h=o==="Refund",u=null,p=S=>{if(xe(S))return null;const{value:D,currency:R}=S;return e.amount(D,R)},f=p(t.deductedAmount),T=p(t.originalAmount),g=h?"refund.refundFee":"refund.fee",y=h?"refund.originalPayment":"refund.originalAmount",_=h?"refund.paymentPspReference":"refund.pspReference",N=[...[T?{key:y,value:T,id:"originalAmount"}:u,f?{key:g,value:f,id:"deductedAmount"}:u,a!=null&&a.description?{key:"account",value:a.description,id:"description"}:u,h&&(l!=null&&l.refundReason)?{key:"refundReason",value:e.has(`refundReason.${l.refundReason}`)?e.get(`refundReason.${l.refundReason}`):l.refundReason,id:"refundReason"}:u,{key:"referenceID",value:i($t,{type:"Default",textToCopy:c,showCopyTextTooltip:!1}),id:"id"},h&&(l!=null&&l.refundPspReference)?{key:"refund.refundPspReference",value:l.refundPspReference,id:"refundPspReference"}:u,d?{key:_,value:d,id:"paymentPspReference"}:u].filter(Boolean).filter(S=>{var D,R;return!((R=(D=s==null?void 0:s.details)==null?void 0:D.fields)!=null&&R.some(b=>b.key===S.id&&b.visibility==="hidden"))}),...Object.entries(n||{}).filter(([S,D])=>!Ch.has(S)&&D.type!=="button"&&D.visibility!=="hidden").map(([S,D])=>({key:S,value:Jt(D)?D.value:D,type:Jt(D)?D.type:"text",config:Jt(D)?D.config:void 0}))||{}];return i(gn,{classNames:y1,items:N,layout:"5-7",align:"start",renderLabel:S=>i("div",{className:T1,children:S}),renderValue:(S,D,R,b)=>{if(R==="link"&&b)return i(wi,{classNames:[M(b==null?void 0:b.className)],href:b.href,target:b.target||"_blank",children:S});if(R==="icon"&&b){const E={url:b==null?void 0:b.src,alt:b.alt||S};return i("div",{className:M("adyen-pe-transaction-data__list-icon-value",b==null?void 0:b.className),children:[i(Li,{...E}),i(I,{variant:O.BODY,children:[" ",S," "]})]})}return i(I,{className:M(b==null?void 0:b.className),variant:O.BODY,children:S})}})},[(r=s==null?void 0:s.details)==null?void 0:r.fields,n,e,t])},Ql=({children:e,className:t})=>i("div",{className:M(Bi,t),children:e}),Eo="adyen-pe-status-box",D1=`${Eo}__amount`,b1=`${Eo}__label`,Bc=`${Eo}__payment-method`,O1=`${Bc}-detail`,Sh=`${Bc}-logo`,I1=`${Sh}-container`,P1=`${Eo}__tags`,k1=({tag:e,amount:t,paymentMethod:n,paymentMethodType:s,date:r,classNames:a})=>i("div",{className:Eo,children:[e&&i("div",{className:P1,children:e}),t&&i("div",{className:M(D1,a==null?void 0:a.amount),children:t}),s&&i("div",{className:Bc,children:[i("div",{className:I1,children:i(yh,{className:Sh,name:s,alt:s,folder:"logos/"})}),i("div",{className:O1,children:n})]}),r&&i("div",{className:b1,children:r})]}),Eh=Ue(k1);function Nh({onInput:e,onKeyUp:t,trimOnBlur:n,onBlurHandler:s,onBlur:r,onFocusHandler:a,errorMessage:o,...c},d){const{autoCorrect:l,classNameModifiers:h,isInvalid:u,isValid:p,readonly:f=!1,spellCheck:T,type:g,uniqueId:y,isCollatingErrors:_,disabled:v}=c;Zt(c,"onChange")&&console.error("Error: Form fields that rely on InputBase may not have an onChange property");const N=C(L=>{e==null||e(L)},[e]),S=C(L=>{t&&t(L)},[t]),D=C(L=>{s==null||s(L),n&&(L.target.value=L.target.value.trim()),r==null||r(L)},[r,s,n]),R=C(L=>{a==null||a(L)},[a]),b=M("adyen-pe-input",[`adyen-pe-input--${g}`],c.className,{"adyen-pe-input--invalid":u,"adyen-pe-input--valid":p},h==null?void 0:h.map(L=>`adyen-pe-input--${L}`)),{classNameModifiers:E,uniqueId:P,isInvalid:w,isValid:W,isCollatingErrors:x,...j}=c;return i(Q,{children:[i("input",{id:y,...j,type:g,className:b,readOnly:f,"aria-describedby":_?void 0:`${y}${ni}`,"aria-invalid":u,onInput:N,onBlurCapture:D,onFocus:R,onKeyUp:S,disabled:v,ref:d}),u&&o&&i("span",{className:"adyen-pe-input__invalid-value",id:`${y}${ni}`,children:o})]})}Nh.defaultProps={type:"text",classNameModifiers:[],onInput:()=>{}};const ri=_r(Nh),Dh=(e,t)=>yu(e,t).toFixed(Wa(t)),Wa=e=>Math.log10(gu(e)),bh=({currency:e,disabled:t,errorMessage:n,errorMessageArg:s,onInput:r,value:a})=>{const{i18n:o}=H(),c=q(vn()),d=q(vn()),l=n?s?o.get(n,{values:{amount:s}}):o.get(n):"";return i("div",{className:Bi,children:[i("div",{className:Rh,children:i("div",{id:d.current,children:i(I,{el:J.SPAN,variant:O.BODY,stronger:!0,children:o.get("refundAmount")})})}),i("div",{className:M({[So]:!0,[vh]:!0,[_1]:!0,[g1]:!!n}),children:[i("label",{htmlFor:c.current,"aria-labelledby":d.current,children:[e&&i(ot,{label:e,variant:Oe.DEFAULT}),i(ri,{min:0,type:"number",className:xc,disabled:Ve(t),lang:o.locale,onInput:r,value:a,uniqueId:c.current})]}),n&&i("div",{className:"adyen-pe-input__refund-invalid-value",id:`${c.current}${ni}`,children:[i(ue,{name:"cross-circle-fill"}),i(I,{el:J.SPAN,variant:O.BODY,children:l})]})]})]})},w1=()=>{const{availableAmount:e,currency:t}=Oc();return i(bh,{currency:t,errorMessage:null,value:Dh(e,t),disabled:!0})},L1=({locale:e})=>{const{availableAmount:t,currency:n,interactionsDisabled:s,setAmount:r}=Oc(),[a,o]=F(null),[c,d]=F(`${Dh(t,n)}`),{i18n:l}=H(),h=A(()=>{const p=Wa(n);return f=>Math.trunc(+`${parseFloat(f)}e${p}`)||0},[n]),u=p=>{var v;let f=p.currentTarget.value.trim();const T=h(f);let g=null;T||f?(T<0&&(g="noNegativeNumbersAllowed"),T>t&&(g="refundAmount.excess")):g="refundAmount.required";const y=((v=1.1.toLocaleString(e).match(/\d(.*?)\d/))==null?void 0:v[1])||".",_=f.split(y);if(_.length===2){const N=Wa(n),S=_[0];let D=_[1];D.length>=N&&(D=D.substring(0,N),f=S+y+D,p.currentTarget.value=f)}d(f),o(g),r(g?0:T)};return i(bh,{currency:n,errorMessage:a,errorMessageArg:l.amount(t,n),onInput:u,value:c,disabled:s})},F1=()=>{const{i18n:e}=H();return A(()=>i("div",{className:`${Bi} ${m1}`,children:[i(I,{el:J.DIV,variant:O.SUBTITLE,stronger:!0,children:e.get("refundAction")}),i(I,{variant:O.BODY,children:e.get("refundNotice")})]}),[e])},M1=()=>{const{i18n:e}=H(),{interactionsDisabled:t,refundReason:n,setRefundReason:s}=Oc(),r=A(()=>Object.freeze(bc.map(o=>({id:o,name:e.has(`refundReason.${o}`)?e.get(`refundReason.${o}`):o}))),[e]),a=C(o=>{var d;const c=(d=o.target)==null?void 0:d.value;c&&s(c)},[s]);return i("div",{className:Bi,children:[i("div",{className:Rh,children:i(I,{el:J.SPAN,variant:O.BODY,stronger:!0,children:e.get("refundReason")})}),i("div",{className:`${So} ${vh}`,children:i(Bn,{items:r,readonly:t,filterable:!1,multiSelect:!1,onChange:a,selected:n})})]})},x1=e=>{switch(e==null?void 0:e.status){case"Booked":return"default";case"Reversed":return"error";default:return"pending"}},B1=e=>{if(e.category==="Refund"){const{refundType:t}=e.refundMetadata??z;switch(t){case Vn.FULL:return Vn.FULL;case Vn.PARTIAL:return Vn.PARTIAL}}},$1=({transaction:e,refundedState:t})=>{const{i18n:n}=H(),{category:s}=e,r=B1(e);return i("div",{className:A1,children:[s&&i(ot,{label:n.get(`txType.${s}`),variant:Oe.DEFAULT}),r&&i(Q,{children:[r===Vn.FULL&&i(ot,{label:n.get("full"),variant:Oe.SUCCESS}),r===Vn.PARTIAL&&i(ot,{label:n.get("partial"),variant:Oe.BLUE})]}),t===Fs.FULL&&i(ot,{label:n.get("refunded.full"),variant:Oe.SUCCESS}),t===Fs.PARTIAL&&i(ot,{label:n.get("refunded.partial"),variant:Oe.BLUE})]})},Jl=({children:e,renderViewActionButtons:t,renderViewMessageBox:n})=>i("div",{className:_t,children:[e,n&&n(),t()]}),ed=({action:e,title:t,renderIcon:n,subtitle:s})=>i("div",{className:R1,children:[n&&n(),i(I,{className:Gt.MEDIUM,variant:O.TITLE,children:t}),i(I,{variant:O.BODY,children:s}),e&&e()]}),U1=({transaction:e,extraFields:t,dataCustomization:n})=>{var ye,We;const[s,r]=F(ft.DETAILS),[a,o]=F(),[c,d]=F(),[l,h]=F(!1),{fetchingTransaction:u,refreshTransaction:p,transaction:f,transactionNavigator:T}=xg(e),{refundable:g,refundableAmount:y,refundableAmountLabel:_,refundAvailable:v,refundCurrency:N,refundDisabled:S,refundedState:D,refundStatuses:R,refundMode:b,refundLocked:E}=$g(f),P=A(()=>S||l,[S,l]),{i18n:w}=H(),W=Object.freeze((f==null?void 0:f.lineItems)??Se),x=C(pe=>o(pe),[]),j=C(pe=>d(pe),[]),L=C(pe=>pe===ft.REFUND&&P,[P]),{getBalanceAccounts:U}=Ee().endpoints,{data:ie}=bt(A(()=>({fetchOptions:{enabled:!!U&&!f.balanceAccount&&!!f.balanceAccountId,keepPrevData:!0},queryFn:async()=>U==null?void 0:U(z)}),[f.balanceAccountId,f.balanceAccount,U])),le=C(pe=>void(L(pe)||r(pe)),[L]),V=C(()=>{const pe=t?Object.values(t).filter(He=>He.type==="button").map(He=>{var De,gt;return{title:He.value,variant:te.SECONDARY,event:(De=He.config)==null?void 0:De.action,classNames:(gt=He.config)!=null&&gt.className?[He.config.className]:[]}}):[],$e=[a,c,...pe].filter(Boolean);return $e.length?i(Ql,{className:f1,children:i(fs,{actions:$e,layout:Co.BUTTONS_END})}):null},[t,a,c]),Z=C(()=>{p(),h(!0)},[h,p]),ge={timezone:(ye=f.balanceAccount)==null?void 0:ye.timeZone,createdAt:f.createdAt,amountData:f.amount,paymentMethodData:f.paymentMethod,bankAccount:f.bankAccount},Ne=oh(ge),me=C(()=>R!=null&&R.length||E||l?i("div",{className:E1,children:[(E||l)&&i(et,{type:be.HIGHLIGHT,variant:it.TIP,description:`${w.get("refund.theRefundIsBeingProcessed")} ${w.get("pleaseComeBackLater")}`}),R.map((pe,$e)=>i(et,{variant:it.TIP,type:(pe==null?void 0:pe.type)??be.HIGHLIGHT,description:pe==null?void 0:pe.label},`${Math.random()}-${$e}`))]}):null,[w,R,E,l]),Ce=f.balanceAccount??((We=ie==null?void 0:ie.data)==null?void 0:We.find(pe=>pe.id===f.balanceAccountId));if(dr(()=>{r(ft.DETAILS)},[f]),dr(()=>{P&&r(ft.DETAILS)},[P]),u)return i(Ec,{skeletonRowNumber:5});if(L(s))return null;const ae={lineItems:W,refundAvailable:v,refundDisabled:P,setActiveView:le,setPrimaryAction:x,setSecondaryAction:j};switch(s){case ft.DETAILS:return i(Jl,{renderViewActionButtons:V,renderViewMessageBox:me,children:i(bg,{...ae,transaction:!f.balanceAccount&&Ce?{...f,balanceAccount:Ce}:{...f},transactionNavigator:T,extraFields:t,dataCustomization:n,children:[i(Ql,{className:v1,children:i(Eh,{...Ne,tag:i($1,{transaction:f,refundedState:D}),classNames:{amount:`${p1}--${x1(f)}`}})}),i(N1,{})]})});case ft.REFUND:return i(Jl,{renderViewActionButtons:V,children:i(Fg,{...ae,availableAmount:y,currency:N,refundMode:b,refreshTransaction:p,transactionId:f.id,children:[i(F1,{}),g&&i(M1,{}),b===Xe.FULL_AMOUNT&&i(w1,{}),(b===Xe.PARTIAL_AMOUNT||b===Xe.PARTIAL_LINE_ITEMS)&&i(L1,{locale:w.locale}),_&&i(et,{variant:it.TIP,type:_.type,description:_.description})]})});case ft.REFUND_SUCCESS:return i(ed,{renderIcon:()=>i(ue,{name:"checkmark-circle-fill",className:M(si,C1)}),title:w.get("refundActionSuccessTitle"),subtitle:w.get("refundActionSuccessSubtitle"),action:()=>i(_e,{variant:te.SECONDARY,onClick:Z,children:w.get("goBack")})});case ft.REFUND_ERROR:return i(ed,{renderIcon:()=>i(ue,{name:"cross-circle-fill",className:M(si,S1)}),title:w.get("refundActionErrorTitle"),subtitle:w.get("refundActionErrorSubtitle"),action:()=>i(_e,{variant:te.SECONDARY,onClick:p,children:w.get("goBack")})});default:return null}},W1=({error:e,isFetching:t,transaction:n,extraFields:s,dataCustomization:r})=>Ve(t)||!(n||e)?i(Ec,{skeletonRowNumber:5}):n?i(U1,{dataCustomization:r,transaction:n,extraFields:s}):null,No=(e,t)=>{const{getBalanceAccounts:n}=Ee().endpoints,{data:s,isFetching:r,error:a}=bt(A(()=>({fetchOptions:{enabled:!!n&&(t??!0),keepPrevData:!0},queryFn:async()=>n==null?void 0:n(z)}),[n])),o=A(()=>s==null?void 0:s.data.filter(d=>e?d.id===e:!0),[s==null?void 0:s.data,e]),c=A(()=>!!e&&!!(s!=null&&s.data.length)&&(o==null?void 0:o.length)===0,[o==null?void 0:o.length,s==null?void 0:s.data.length,e]);return{balanceAccounts:o,isBalanceAccountIdWrong:c,isFetching:r,error:a}},Oh=hs({withinModal:!1}),H1=()=>ps(Oh);function Ih({title:e,children:t,classNameModifiers:n=[],isOpen:s,onClose:r,isDismissible:a=!0,headerWithBorder:o=!0,size:c="fluid",...d}){const l=Pe(Ie.down.xs),{i18n:h}=H(),u=Pc(null,r),p=C(f=>{f.key==="Escape"&&s&&a&&r()},[s,a,r]);return G(()=>(s?window.addEventListener("keydown",p):window.removeEventListener("keydown",p),()=>window.removeEventListener("keydown",p)),[s,p]),i(Q,{children:s&&i("div",{className:M("adyen-pe-modal-wrapper",n.map(f=>`adyen-pe-modal-wrapper--${f}`),{"adyen-pe-modal-wrapper--open":s,"adyen-pe-modal-wrapper--dismissible":a}),role:"dialog","aria-modal":"true","aria-hidden":!open,...d,children:i(Oh.Provider,{value:{withinModal:!0},children:i("div",{className:M("adyen-pe-modal",{"adyen-pe-modal--fluid":c==="fluid","adyen-pe-modal--small":c==="small","adyen-pe-modal--large":c==="large","adyen-pe-modal--extra-large":c==="extra-large","adyen-pe-modal--full-screen":c==="full-screen"||l}),ref:u,children:[i("div",{className:M("adyen-pe-modal__header",{"adyen-pe-modal__header--with-title":e,"adyen-pe-modal__header--with-border-bottom":o}),children:[e&&i("div",{className:"adyen-pe-modal__header__title",children:e}),a&&i(_e,{onClick:r,variant:te.TERTIARY,iconButton:!0,classNameModifiers:["circle"],className:"adyen-pe-modal__header-icon","aria-label":h.get("dismiss"),children:i(ue,{name:"cross"})})]}),i("div",{className:"adyen-pe-modal__content",children:t})]})})})})}const G1={transaction:"transactionDetails",payout:"payoutDetails"},Y1=({hideTitle:e,type:t})=>{const{i18n:n}=H(),{withinModal:s}=H1(),[r,a]=F(!1),o=A(()=>r||Ve(e),[r,e]),c=A(()=>n.get(G1[t]),[n,t]);return G(()=>{a(s)},[s]),{hideTitle:o,title:c}},Ph="adyen-pe-payouts-table",q1=`${Ph}__net-payout`,kh=["fundsCapturedAmount","adjustmentAmount","payoutAmount"],$i=["createdAt",...kh],j1=e=>kh.includes(e),V1=({error:e,loading:t,onContactSupport:n,onRowClick:s,showDetails:r,showPagination:a,data:o,customColumns:c,...d})=>{const{i18n:l}=H(),{dateFormat:h}=Pt("UTC"),{refreshing:u}=Ee(),p=A(()=>t||u,[t,u]),f=Pe(Ie.up.sm),T=C(v=>{var S,D,R,b;const N=l.get(Ah(v));if(j1(v))return{label:(D=(S=o==null?void 0:o[0])==null?void 0:S[v])!=null&&D.currency?`${N} (${Tu((b=(R=o==null?void 0:o[0])==null?void 0:R[v])==null?void 0:b.currency)})`:N,position:"right"}},[o,l]),g=xi({fields:$i,customColumns:c,columnConfig:A(()=>({fundsCapturedAmount:{...T("fundsCapturedAmount"),visible:f},adjustmentAmount:{...T("adjustmentAmount"),visible:f},payoutAmount:T("payoutAmount")}),[T,f])}),y={title:"noPayoutsFound",message:["tryDifferentSearchOrResetYourFiltersAndWeWillTryAgain"]},_=A(()=>()=>i(Fi,{error:e,errorMessage:"weCouldNotLoadYourPayouts",onContactSupport:n}),[e,n]);return i("div",{className:Ph,children:i(tn,{errorDisplay:_,error:e,columns:g,data:o,loading:p,outline:!1,onRowClick:{callback:s},emptyTableMessage:y,customCells:{createdAt:({value:v})=>v?f?v&&i(I,{variant:O.BODY,children:h(v,q_)}):h(v,j_):null,fundsCapturedAmount:({value:v})=>v&&i(I,{variant:O.BODY,children:l.amount(v.value,v.currency,{hideCurrency:!0})}),adjustmentAmount:({value:v})=>v&&i(I,{variant:O.BODY,children:l.amount(v.value,v.currency,{hideCurrency:!0})}),payoutAmount:({value:v})=>v&&i(I,{variant:O.BODY,className:M({[`${q1}--strong`]:!f}),children:l.amount(v.value,v.currency,{hideCurrency:f})})},children:a&&i(tn.Footer,{children:i(Mi,{...d})})})})},z1={transaction:"getTransaction",payout:"getPayout",dispute:"getDisputeDetail"},wo=e=>!("data"in e);function $c(e){var v;const t=A(()=>wo(e)?null:e.data,[e]),n=A(()=>wo(e)?e.id:null,[e]),s=Ee().endpoints[z1[e.type]],{hideTitle:r,title:a}=Y1(e),{data:o,error:c,isFetching:d}=bt(A(()=>({fetchOptions:{enabled:!!n&&!!s},queryFn:async()=>{let N=null;switch(e.type){case"transaction":N={path:{transactionId:n}};break;case"payout":N={query:{balanceAccountId:n,createdAt:e.date}};break;default:break}return s(z,{...N})}}),[n,s,e])),l=e.type==="payout"?e.id:o==null?void 0:o.balanceAccountId,h=e.type==="payout"?e==null?void 0:e.balanceAccountDescription:e==null?void 0:e.balanceAccount,{balanceAccounts:u}=No(l,!h),p=A(()=>{if(c)return Fc(c,"weCouldNotLoadYourTransactions",e.onContactSupport)},[c,e.onContactSupport]),f=t??o,[T,g]=F(),y=C(async()=>{var N,S,D,R,b;if(o&&(wo(e)&&e.type==="transaction"||e.type==="payout")){const E=await((D=(S=(N=e.dataCustomization)==null?void 0:N.details)==null?void 0:S.onDataRetrieve)==null?void 0:D.call(S,o));g((b=(R=e.dataCustomization)==null?void 0:R.details)==null?void 0:b.fields.reduce((P,w)=>Ch.has(w.key)||$i.includes(w.key)||(w==null?void 0:w.visibility)==="hidden"?P:{...P,...E!=null&&E[w.key]?{[w.key]:E[w.key]}:{}},{}))}},[o,e]),_=wo(e)&&e.type==="transaction"||e.type==="payout"?e.dataCustomization:void 0;return G(()=>{y()},[y]),i("div",{className:"adyen-pe-overview-details",children:[!r&&i("div",{className:"adyen-pe-overview-details--title",children:i(I,{variant:O.TITLE,medium:!0,children:a})}),c&&p&&i("div",{className:"adyen-pe-overview-details--error-container",children:i(Qt,{withImage:!0,...p})}),e.type==="transaction"&&i(W1,{transaction:f?{...f||z,balanceAccount:(e==null?void 0:e.balanceAccount)||(u==null?void 0:u[0])}:void 0,error:!!(c&&p),isFetching:d,extraFields:T,dataCustomization:_}),e.type==="payout"&&f&&i(Cg,{balanceAccountId:n,payout:f,balanceAccountDescription:(e==null?void 0:e.balanceAccountDescription)||((v=u==null?void 0:u[0])==null?void 0:v.description),isFetching:d,extraFields:T,dataCustomization:_})]})}class wh extends Sn{constructor(n){super(n);Y(this,"componentToRender",()=>i($c,{...this.props,type:"payout",ref:n=>void(this.componentRef=n)}));this.componentToRender=this.componentToRender.bind(this)}}Y(wh,"type","payoutDetails");const K1="adyen-pe-data-overview-container--with-error";function Ui({balanceAccountsError:e,children:t,className:n,errorMessage:s,isBalanceAccountIdWrong:r,onContactSupport:a}){const{hasError:o}=Ee();return i("div",{className:M(n,{[K1]:o}),children:o?i(Qt,{withImage:!0,centered:!0,title:"somethingWentWrong",message:[s,"tryRefreshingThePageOrComeBackLater"],refreshComponent:!0}):e?i(Qt,{withImage:!0,centered:!0,...Fc(e,"weCouldNotLoadYourBalanceAccounts",a)}):r?i(Qt,{withImage:!0,centered:!0,title:"somethingWentWrong",message:[s,"theSelectedBalanceAccountIsIncorrect"]}):i(Q,{children:t})})}const X1="adyen-pe-payouts-overview",Z1="adyen-pe-payouts-details",Q1=new Date("2024-04-16T00:00:00.000Z").toString(),td="adyen-pe-filter-bar-mobile-switch",Wi=()=>{const e=Pe(Ie.down.xs),[t,n]=F(!e);return G(()=>{n(!e)},[e]),{isMobileContainer:e,showingFilters:t,setShowingFilters:n}},Hi=({isMobileContainer:e,showingFilters:t,setShowingFilters:n})=>e?i("div",{className:td,children:i(_e,{iconButton:!0,className:`${td}__button`,disabled:!ee(n),onClick:()=>n==null?void 0:n(!t),variant:te.SECONDARY,children:i(ue,{name:t?"cross":"filter"})})}):null,Gi=e=>{const{i18n:t}=H();return e.showingFilters?i("div",{"aria-label":t.get("filterBar"),className:M("adyen-pe-filter-bar",{"adyen-pe-filter-bar__content--mobile":e.isMobileContainer}),children:[e.children,e.canResetFilters&&!!e.resetFilters&&i(_e,{variant:te.TERTIARY,onClick:e.resetFilters,children:t.get("button.clearAll")})]}):null},oi=vn(),Yi=(e,t=!1)=>{const{i18n:n}=H(),[s,r]=F(0),a=C(()=>r(0),[]),o=A(()=>e&&[...e,...t?[{...e[0]??{},id:oi,description:void 0}]:[]],[t,e]),c=A(()=>o==null?void 0:o[s],[o,s]),d=A(()=>e&&e.length>1?Object.freeze(o==null?void 0:o.map(({description:h,id:u})=>{const p=u===oi?n.get("balanceAccounts.all"):Ef(h);return{id:u,name:p}})):void 0,[o,e,n]),l=C(({target:h})=>{const u=h==null?void 0:h.value,p=o==null?void 0:o.findIndex(({id:f})=>f===u);p>=0&&r(p)},[o]);return{activeBalanceAccount:c,balanceAccountSelectionOptions:d,onBalanceAccountSelection:l,resetBalanceAccountSelection:a}},Uc="adyen-pe-balance-account-selector",J1=`${Uc}__account-id`,nd=`${Uc}__account-label`,qi=Ue(({activeBalanceAccount:e,balanceAccountSelectionOptions:t,onBalanceAccountSelection:n})=>{const s=Pe(Ie.down.xs),{i18n:r}=H(),a=C(o=>i(Q,{children:[i("div",{className:o.contentClassName,children:[o.item.name&&i("span",{className:nd,children:o.item.name}),o.item.id!==oi&&i("span",{className:o.item.name?J1:nd,children:o.item.id})]}),Th(o)]}),[]);return t&&t.length>1?i(Bn,{popoverClassNameModifiers:[Uc],onChange:n,filterable:!1,multiSelect:!1,placeholder:(e==null?void 0:e.id)||r.get("balanceAccount"),selected:e==null?void 0:e.id,withoutCollapseIndicator:!0,items:t,renderListItem:a,showOverlay:s}):null}),ji=Object.freeze([10,20]),ey=100,hr=10,Ha=e=>{const t=~~e;return t===e&&t>0?Math.min(t,ey):Math.max(t,0)},ty=(e,t)=>{const n=e.length-1;if(n<0)return t;if(t<=e[0])return e[0];if(t>=e[n])return e[n];let s=0,r=0,a=n;for(;;){const o=e[s=jd(r,a)];if(r>a||t===o)return o;t>o?r=s+1:a=s-1}},ny=({preferredLimit:e=hr,preferredLimitOptions:t})=>{const n=q(),s=q(),r=A(()=>{try{const o=new Set;for(const c of t){const d=Ha(c);d>0&&o.add(d)}return Object.freeze([...o].sort((c,d)=>c-d))}catch{}},[t]);return{limit:A(()=>{let o=Ha(e)||hr;e:try{if(n.current===r)break e;const c=new Set(n.current=r);if(c.size===0){n.current=void 0;break e}if(s.current!==o)t:{if(c.size===c.add(o).size)break t;if(c.delete(o),c.size===c.add(s.current).size){if(fr(s.current)){o=s.current;break t}}else c.delete(s.current);o=ty(n.current,o)}}catch{}return s.current=o},[r,e]),limitOptions:r}},Wc=e=>{const t=q(!1),n=A(()=>e,[e]);return G(()=>(t.current=!0,()=>{t.current=!1,n&&n()}),[n]),t},Lh=(e,t,n)=>{const s=q(),r=q(),a=q(),o=q(),c=Wc(C(()=>{var w;(w=s.current)==null||w.abort(),s.current=void 0},[])),[d,l]=F(o.current),[h,u]=Vt(!1),p=A(()=>Ha(n),[n]),{getPageCount:f,getPageParams:T,resetPageCount:g,updatePagination:y}=e,_=A(()=>t?w=>{var L;if(!(p&&Number.isInteger(w)))return;const W=f(),x=w<0?w+W+1:w;x>0&&(W?x<=W:x===1)&&((L=s.current)==null||L.abort(),s.current=new AbortController,c.current&&(((o.current=x)>1||W)&&l(o.current),(async()=>{const{signal:U}=s.current,ie={...T(x,p),limit:p,page:x};try{const le=await t(ie,U);if(!le||!c.current)return;const{size:V,...Z}=le;y(x,p,Z),r.current=o.current&&Math.max(o.current,r.current||-1/0),o.current&&o.current===r.current&&(a.current=V),o.current===1&&V>0&&l(o.current),o.current=void 0,u(!0)}catch(le){if(U.aborted)return;console.error(le)}})()))}:he,[p,t]),v=C(()=>{d&&_(Math.min(d+1,f()))},[_,d]),N=C(()=>{d&&_(Math.max(d-1,1))},[_,d]),S=A(()=>f()||d||void 0,[_,h]),D=A(()=>!!(d&&S)&&d<S,[d,S]),R=A(()=>!!d&&d>1,[d]),b=A(()=>r.current?(r.current-1)*p+(a.current||0):0,[_,h]),E=A(()=>p&&Math.min(p,b||1/0)%p,[p,b]),P=C(()=>{g(),r.current=a.current=o.current=void 0,c.current&&l(o.current)},[g]);return G(()=>{c.current&&h&&u(!1)},[h]),{goto:_,hasNext:D,hasPrev:R,limit:p,next:v,page:d,pages:S,pageSize:E,prev:N,resetPagination:P,size:b}},sy=e=>Dt(e.next),ry=e=>Dt(e.prev),oy=(e,t)=>{const n=A(()=>{const s=[],r=()=>s.length,a=()=>{s.length=0},o=l=>({cursor:s[l-1]}),c=(l,h)=>{const u=s[h-1];(h===1||h===(s.length||1)+1)&&oe(u)&&(s[h-1]=l?decodeURIComponent(l):void 0)};return{getPageCount:r,getPageParams:o,resetPageCount:a,updatePagination:(l,h,u)=>{sy(u)&&c(u.next,l+1),ry(u)&&c(u.prev,l-1)}}},[]);return Lh(n,e,t)},iy=e=>e.next,ay=(e,t)=>{const n=A(()=>{let s=0;return{getPageCount:()=>s,getPageParams:(d,l)=>({offset:(d-1)*l}),resetPageCount:()=>{s=0},updatePagination:(d,l,h)=>{iy(h)&&h.next&&(s=Math.max(s,d+1))}}},[]);return Lh(n,e,t)},cy=(e=z,t=!0)=>{const n=q(t),s=q(Object.freeze({...e})),r=q(new Set(Object.keys(s.current))),a=q(new Set),o=Wc(),[c,d]=A(()=>{const p=f=>{o.current&&h(f)};return[()=>p("reset"),f=>p(f)]},[o]),[l,h]=Oi((p,f)=>{if(f==="reset")return a.current.clear(),s.current;const T={...f},g=[0];Object.keys(T).forEach((_,v)=>{if(!r.current.has(_))return;const N=p[_]??void 0,S=s.current[_]??void 0,D=T[_]??S;if(D===N)return;const R=Math.floor(v/32),b=1<<v%32;T[_]=D,g[R]|=b,a.current[D===S?"delete":"add"](_)});const y=g.some(_=>_)?n.current&&a.current.size===0?s.current:Object.freeze({...p,...T}):p;return n.current||(s.current=y,n.current=!0),y},s.current),u=A(()=>!!a.current.size,[]);return G(()=>{s.current=Object.freeze({...e}),r.current=new Set(Object.keys(s.current)),n.current=t,c()},[t,e,c]),{canResetState:u,defaultState:s.current,resetState:c,state:l,updateState:d}},ly=(e=z,t)=>{const{canResetState:n,defaultState:s,resetState:r,state:a,updateState:o}=cy(e,t);return{canResetFilters:n,defaultFilters:s,filters:a,resetFilters:r,updateFilters:o}};var Ga=(e=>(e.NEXT="next",e.PREV="prev",e))(Ga||{}),Hc=(e=>(e.CURSOR="cursor",e.OFFSET="offset",e))(Hc||{});const dy=["hasNext","hasPrevious"],Fh=e=>{const t=Object.getOwnPropertyNames(e);return!dy.some(n=>t.includes(n))},uy=(e,t="data")=>{const n=e[t];if(Fh(e)){const s=Object.fromEntries(Object.entries(e._links).map(([r,a])=>[r,a.cursor]));return{records:n,paginationData:s}}throw new TypeError("MALFORMED_PAGINATED_DATA")},hy=(e,t="data")=>{const n=e[t];if(!Fh(e)){const{hasNext:s,hasPrevious:r}=e,a={[Ga.NEXT]:Ve(s),[Ga.PREV]:Ve(r)};return{records:n,paginationData:a}}throw new TypeError("MALFORMED_PAGINATED_DATA")},py=({dataField:e="data",fetchRecords:t,filterParams:n=z,initialFiltersSameAsDefault:s=!0,initialize:r,onFiltersChanged:a,pagination:o,preferredLimit:c,preferredLimitOptions:d,enabled:l})=>{const[h,u]=F([]),[p,f]=Vt(!0),[T,g]=F(),[y,_]=F(c),v=Wc(),N=q(!0),S=q(1),D=ly(n,s),{limit:R,limitOptions:b}=ny({preferredLimit:y,preferredLimitOptions:d}),{defaultFilters:E,filters:P,updateFilters:w,...W}=D,[x,j]=A(()=>o===Hc.CURSOR?[uy,oy]:[hy,ay],[]),L=C(ge=>_(ge),[]),{goto:U,page:ie,pages:le,resetPagination:V,...Z}=j(C(async({page:ge,...Ne},me)=>{try{if(g(void 0),S.current=ge,!v.current||f(!0))return;const Ce=await t({...Ne,...P},me),{records:ae,paginationData:ye}=x(Ce,e);return N.current&&(r==null||r([ae,ye],D),N.current=!1),v.current&&(u(ae),f(!1)),{...ye,size:ae==null?void 0:ae.length}}catch(Ce){if(me!=null&&me.aborted)return;f(!1),g(Ce),console.error(Ce)}},[t,P,R]),R);return A(()=>{N.current=!0},[n]),A(()=>{V(),S.current=1},[P,R,V]),G(()=>{l&&U(S.current)},[U,l]),G(()=>{a==null||a(P)},[P]),{error:T,fetching:p,filters:P,goto:U,limitOptions:b,page:ie,pages:le,records:h,updateFilters:w,updateLimit:L,...W,...Z}},Vi=e=>py({...e,pagination:Hc.CURSOR}),{getTimezoneTime:fy,getUsedTimezone:my}=(()=>{const e=/\d{2}:\d{2}(?=:\d{2}(?:\.\d+)?\s+([AP]M))/i,t=/^GMT|0(?=\d:00)|:00/g,n=yo();return{getTimezoneTime:(a,o=Date.now())=>{n.tz=a;const{formatted:c}=n(o),[d="",l=""]=(c==null?void 0:c.match(e))??Se,h=Oa(c),u=`${d}${l&&` ${l}`}`,p=w2(h).replace(t,"");return[u,p]},getUsedTimezone:a=>(n.tz=a,n.tz.current)}})(),_y=({timezone:e,withClock:t=!1}=z)=>{const n=A(()=>Ve(t),[t]),s=A(()=>my(e),[e]),r=q(he),[a,o]=F(Date.now()),[c,d]=A(()=>fy(s,a),[a,s]);return A(()=>{r.current(),r.current=n?ic.subscribe(l=>{us(l)||o(l.now)}):he},[o,n]),{clockTime:c,GMTOffset:d,timestamp:a,timezone:s}},gy=e=>Object.freeze({systemToTimezone:X(t=>Kt(e,t)),timezoneToSystem:X(t=>_n(e,t)),timezoneOffset:X(t=>e(t).offset)}),Mh=(e,t,n=e)=>{const s=(r,a)=>{let o=r;xe(r)?o=n:Br(r)||(o=a??n);const c=Et(e,o,t);return c===o?c:a??n};return r=>{const a=ve(()=>o);let o=s(r);return de({value:a,descriptor:X({...a,set(c){const d=o;o=s(c,o),d!==o&&(this.now=this.now)}})})}},Ty=(e,t)=>n=>ee(n)?n.call(e,t):n,yy=e=>!Zt(e,"offsets"),Ay=e=>Zt(e,"from"),zi=({now:e})=>e,vy=(()=>{const e=new Map;return t=>{let n=e.get(t);return oe(n)&&(n=Object.freeze([0,0,t,0,0,0,-1]),e.set(t,n)),n}})(),gs=e=>{try{const t=e instanceof Date||+e===e?e:void 0,n=new Date(t).getTime();return isNaN(n)?void 0:n}catch{}},Ki=(e=z,t=z)=>{const n=$r(e),s=$r(t);return()=>{const r=yo(),a=ve(()=>u),o=ve(()=>r.tz.current),c=de({now:a,timezone:o,...gy(r)}),d=Ty(n,c);let{from:l,to:h,now:u}=z;const p=T=>{u=gs(T??Date.now())??u;e:{if(yy(n)){l=gs(d(n.from))??u,h=gs(d(n.to))??u;break e}let g,y,_;(_=Ay(n))?(g=new Date(l=gs(d(n.from))??u),y=1):(g=new Date(h=gs(d(n.to))??u),y=-1),g=new Date(c.timezoneToSystem(g));const[v=0,N=0,S=0,D=0,R=0,b=0,E=0]=d(n.offsets);g.setFullYear(g.getFullYear()+v*y,g.getMonth()+N*y,g.getDate()+S*y),g.setHours(g.getHours()+D*y,g.getMinutes()+R*y,g.getSeconds()+b*y,g.getMilliseconds()+E*y);const P=gs(c.systemToTimezone(g))??u;_?h=P:l=P}l>h&&([l,h]=[h,l])},f=T=>{const g=r.tz,y=g.current;r.tz=T,g.current!==y&&p(u)};return p(),de({...s,from:ve(()=>l),now:{...a,set:p},timezone:{...o,set:f},to:ve(()=>h)})}},Ry=/^(\d{2})\/(\d{2})\/(-?\d+),\s+(\d{2}):(\d{2}):(\d{2}).(\d{3})/,Xi=(e=fo)=>(t,n,...s)=>{const r=An(n),a=new Date(_n(r,t));return a.setHours(0,0,0,0),Kt(r,e(a,...s))},xh=Xi(),Bh=Xi(e=>e.setDate(1)),Cy=Xi(e=>e.setMonth(0,1)),$h=Xi((e,t)=>{const n=Ey(e.getDay(),t??0);return e.setDate(e.getDate()-n)}),Sy=e=>(e%100?e%4:e%400)===0,fa=(e,t,n=0)=>{const s=e+n,r=_o(s,12),a=t+Math.floor(s/12);let o=31;switch(r){case 1:o=Sy(a)?29:28;break;case 3:case 5:case 8:case 10:o=30;break}return[o,r,a]},Ey=(e,t=0)=>(7-t+e)%7,Ps=(e,t)=>ss(e)?0:e-xh(e,t),sd=e=>oe(e)?e:new Date(e),Ny=(e,t=z)=>{const n=An(t.timeZone),s={...lc,...t,timeZone:n.tz.current};return new Date(e).toLocaleDateString(Di,s)},On=(e,t)=>{const n=Ny(e,{...Au,...lc,timeZone:t,hour12:!1}),[,s="",r="",a="",o="",c="",d="",l=""]=n.match(Ry)??Se;return[+a,+s-1,+r,+o%24,+c,+d,+l]},Ya=(e,t,n)=>{if(ss(e)||ss(t))return 1/0;const[s,r]=On(e,n),[a,o]=On(t,n);return Math.abs(o-r+(a-s)*12)},An=(()=>{const e=yo();return t=>(e.tz=void 0,e.tz=t,e)})(),Gc=1,Dy=vy(7),by=Mh(0,6,Gc),Uh=(e=0)=>{const t=~~Et(0,e,1/0)||0;return(n=Gc)=>{const s=t?{offsets:Dy}:{to:zi},r=by(n);return Ki({from:({now:a,timezone:o,systemToTimezone:c,timezoneToSystem:d})=>{const l=new Date(d($h(a,o,r.value)));return l.setDate(l.getDate()-t*7),c(l)},...s},{firstWeekDay:r.descriptor})()}},Oy=Object.freeze([0,1,0,0,0,0,-1]),Wh=(e=0)=>{const t=~~Et(0,e,1/0)||0;return Ki({from:({now:s,timezone:r,systemToTimezone:a,timezoneToSystem:o})=>{const c=new Date(o(Bh(s,r)));return c.setMonth(c.getMonth()-t),a(c)},...t?{offsets:Oy}:{to:zi}})},Iy=Wh(1),Py=365,ky=1,wy=1,Ly=Mh(ky,Py,wy),rd=e=>{const t=Ly(e);return Ki({from:({now:n,timezone:s,systemToTimezone:r,timezoneToSystem:a})=>{const o=new Date(a(xh(n,s)));return o.setDate(o.getDate()-t.value+1),r(o)},to:zi},{numberOfDays:t.descriptor})()},Fy=Uh(1),My=Wh(0),xy=Uh(0),By=Ki({from:({now:e,timezone:t})=>Cy(e,t),to:zi}),$y=()=>Object.freeze({"rangePreset.last7Days":rd(7),"rangePreset.last30Days":rd(30),"rangePreset.thisWeek":xy(),"rangePreset.lastWeek":Fy(),"rangePreset.thisMonth":My(),"rangePreset.lastMonth":Iy(),"rangePreset.yearToDate":By()}),Uy=({now:e=Date.now(),options:t,selectedOption:n,timezone:s})=>{const{i18n:r}=H(),[a,o]=F(),[c,d]=F(),[l,h]=F(),u=q(),p=q(),[f,T,g]=A(()=>{const R=r.get("rangePreset.custom"),b=Object.keys(t),E=Object.freeze(b.map(w=>r.get(w)));return[R,(w,W=E)=>{const x=W.findIndex(j=>j===w);return t[b[x]]},E]},[r,t]),[y,_]=F(n===f),v=A(()=>Object.freeze([...g,f]),[f,g]),N=A(()=>y?v:g,[y,g,v]),S=C(R=>{const b=T(R,g);b&&(o(b.from),d(b.to),_(!1),h(R))},[f,T,l,g]),D=C(()=>{o(void 0),d(void 0),_(!0),h(f)},[f]);return A(()=>{n===f?h(f):S(n)},[]),A(()=>{var R;if(u.current!==e||p.current!==s){const b=Object.values(t);b.forEach(E=>{E.now=e,E.timezone=s}),u.current=e,p.current=(R=b[0])==null?void 0:R.timezone,S(l)}},[e,s,t]),{customSelection:D,from:a,onSelection:S,options:N,selectedOption:l,to:c}},Wy=({calendarRef:e,onTimeRangeSelected:t,timestamp:n,...s})=>{const{customSelection:r,from:a,onSelection:o,options:c,selectedOption:d,to:l}=Uy(s),h=A(()=>Object.freeze(c.map(T=>({id:T,name:T}))),[c]),u=C(({target:T})=>o(T==null?void 0:T.value),[o]),p=q(!0),f=q(n);return G(()=>{e!=null&&e.current&&a&&l&&(p.current=!0,e.current.from=new Date(a),e.current.to=new Date(l))},[e,a,l]),G(()=>{f.current!==n&&(f.current=n,p.current?p.current=!1:r())},[r,n]),G(()=>{d&&(t==null||t(d))},[d,t]),i(Bn,{setToTargetWidth:!0,items:h,filterable:!1,multiSelect:!1,onChange:u,selected:d})},St=(()=>{const e=s=>Object.freeze(mr(z,Object.fromEntries(Object.entries(s).map(([r,a])=>[r,{value:a}])))),t=s=>{try{return Object.getPrototypeOf(s)===z}catch{return!1}},n=(s,r)=>{if(!s)return e(X(r,en(s)));let a=r;return e({enumerable:!0,get:()=>a,set:o=>{a=s(o)}})};return Object.defineProperties(n,{is:{value:t},isObject:{value:Ri},immutable:{value:s=>n(!1,s)},mutable:{value:s=>n(void 0,s)},restricted:{value:()=>n(!1)}})})(),Hh=(()=>{const e=(n={},s=!1)=>{const r=de();for(const[a,o]of Object.entries(n)){try{const c=St.is(o),d=St.isObject(o);if(c||d){Object.defineProperty(r,a,c?o:e(o,s));continue}else if(s){Object.defineProperty(r,a,St.immutable(o));continue}}catch{}r[a]=o}return St((a={})=>Object.assign(r,a),r)};return Object.defineProperties(e,{unwrapped:{value:(n={},s=!1)=>{const r=e(n,s);return de({P:r}).P}}})})();var Yc=(e=>(e[e.DATE=0]="DATE",e[e.DAY_OF_WEEK=1]="DAY_OF_WEEK",e[e.MONTH_HEADER=2]="MONTH_HEADER",e))(Yc||{});const Gh="adyen-pe-calendar__cell adyen-pe-calendar__cell--date",Yh="adyen-pe-calendar__date",Hy=(e=z,t)=>{const n=Hh.unwrapped({childClassName:St.mutable(Yh),childProps:{children:St.restricted(),className:""},className:St.mutable(Gh),props:{...e,children:St.restricted(),className:""}},!0);return t==null||t(Yc.DATE,n),n},Gy=Cn(({grid:e,prepare:t,datetime:n,flags:s,index:r,label:a,onlyCellsWithin:o},c)=>{const d=s.WITHIN_BLOCK,l={"data-cursor-position":r,"data-within-month":d,tabIndex:-1};if(d){const g=s.WITHIN_RANGE;l["data-today"]=s.CURRENT,l["data-first-week-day"]=s.LINE_START,l["data-last-week-day"]=s.LINE_END,l["data-weekend"]=s.WEEKEND,l["data-first-month-day"]=s.BLOCK_START,l["data-last-month-day"]=s.BLOCK_END,l["data-within-range"]=g,g&&(l["data-range-end"]=s.RANGE_END,l["data-range-start"]=s.RANGE_START,l["data-selection-end"]=s.SELECTION_END,l["data-selection-start"]=s.SELECTION_START,l["data-within-selection"]=s.WITHIN_SELECTION,l["aria-selected"]=`${!!(s.SELECTION_END||s.SELECTION_START||s.WITHIN_SELECTION)}`),r===+e.cursor&&(l.ref=c)}const h=Hy(l,t),{children:u,className:p,...f}=h.props||z,T=ei(h.className,Gh,p);return i("td",{...f,...l,className:T,children:(!o||d)&&(()=>{const{children:g,className:y,..._}=h.childProps||z,v=ei(h.childClassName,Yh,y);return i("time",{..._,className:v,dateTime:n,children:a})})()})}),Yy=Ue(Gy,Jo({block:Jo.exclude,flags:e=>+e})),qh="adyen-pe-calendar__cell adyen-pe-calendar__cell--day-of-week",jh="adyen-pe-calendar__day-of-week",qy=(e=z,t)=>{const n=Hh.unwrapped({childClassName:St.mutable(jh),childProps:{children:St.restricted(),className:""},className:St.mutable(qh),props:{...e,children:St.restricted(),className:""}},!0);return t==null||t(Yc.DAY_OF_WEEK,n),n},jy=({prepare:e,flags:t,labels:{long:n,short:s}})=>{const r={"aria-label":n,"data-first-week-day":t.LINE_START,"data-last-week-day":t.LINE_END,"data-weekend":t.WEEKEND,scope:"col"},a=qy(r,e),{children:o,className:c,onCommand:d,...l}=a.props||z,h=ei(a.className,qh,c),{children:u,className:p,...f}=a.childProps||z,T=ei(a.childClassName,jh,p);return i("th",{...l,ref:l.ref,...r,className:h,children:i("abbr",{...f,className:T,children:s})})},Vy=Ue(jy,Jo({block:Jo.exclude,flags:e=>+e})),zy=_r(({cursorRootProps:e,onlyCellsWithin:t,prepare:n,grid:s},r)=>i("ol",{className:"adyen-pe-calendar",role:"none",...e,children:s.map(a=>i("li",{className:"adyen-pe-calendar__month",role:"none",children:[i("div",{className:"adyen-pe-calendar__month-name",role:"none",children:i("time",{dateTime:a.datetime,"aria-hidden":"true",children:a.label})}),i("table",{role:"grid","aria-multiselectable":!0,"aria-label":`${a.label} calendar`,className:"adyen-pe-calendar__grid",style:{"--adyen-pe-calendar-rowspan":s.rowspan},children:[i("thead",{children:i("tr",{className:"adyen-pe-calendar__row",children:s.weekdays.map((o,c)=>i(Vy,{grid:s,block:a,prepare:n,cell:c,...o},o.labels.long))})}),i("tbody",{children:a.map((o,c)=>i("tr",{className:"adyen-pe-calendar__row",children:o.map((d,l)=>i(Yy,{ref:r,grid:s,block:a,prepare:n,cell:l,onlyCellsWithin:t,row:c,...d},`${a.month}:${d.timestamp}`))},`${a.month}:${c}`))})]})]},a.datetime))})),Ky=Ue(zy),jr=864e5,Xy=["narrow","short","long"],Vh=[0,1,6],Ms=[1,2,3,4,6,12],od=42,Zy=[0,1],qc=Symbol(),jc=Symbol(),Vc=Symbol(),id=[Vc,jc,qc],Yn=Symbol(),ks=Symbol(),ws=Symbol(),Qy=[ks,ws,Yn],zh=Symbol(),Kh=Symbol(),Xh=Symbol(),Zh=Symbol(),Qh=Symbol(),Jh=Symbol(),ep=Symbol(),tp=Symbol(),np=Symbol(),sp=Symbol(),zc=Symbol(),Kc=Symbol(),rp=Symbol(),ad=Symbol(),tt=Symbol(),cd=Symbol(),yt=Symbol(),op=Symbol(),Wo=Symbol(),Ho=Symbol(),ld=(e,t)=>{if(t>=e)return e;let n=Math.max(1,Ms.indexOf(e));for(;--n&&t<Ms[n];);return Ms[n]},Jy=e=>Ms[Math.max(Ms.indexOf(e),0)],dd=(e=0)=>Object.freeze(Zy.map(t=>_o(6-e+t,7)));var Qr,dt,ut,Hs,Gs;class ud{constructor(...t){$(this,Qr,1/0);$(this,dt,1/0);$(this,ut,-1/0);$(this,Hs,0);$(this,Gs,0);if(t.length>=3){let n=new Date(t[1]).getTime();if(typeof t[2]!="symbol")k(this,ut,n||m(this,ut)),k(this,dt,new Date(t[2]).getTime()||m(this,dt)),m(this,dt)<m(this,ut)&&([Wn(this,dt)._,Wn(this,ut)._]=[m(this,ut),m(this,dt)]),k(this,Gs,Ps(m(this,ut),t[0])),k(this,Hs,Ps(m(this,dt),t[0])),k(this,Qr,Ya(m(this,ut),m(this,dt),t[0])+1);else if(!isNaN(n))switch(t[2]){case Kc:k(this,dt,n),k(this,Hs,Ps(m(this,dt),t[0]));break;case zc:default:k(this,ut,n),k(this,Gs,Ps(m(this,ut),t[0]));break}}}get numberOfMonths(){return m(this,Qr)}get endTimestamp(){return m(this,dt)}get endTimestampOffset(){return m(this,Hs)}get startTimestamp(){return m(this,ut)}get startTimestampOffset(){return m(this,Gs)}}Qr=new WeakMap,dt=new WeakMap,ut=new WeakMap,Hs=new WeakMap,Gs=new WeakMap;const Zi=(...e)=>{let t=An().tz.current,n=new ud(t,...e);return de({from:ve(()=>n.startTimestamp,!1),to:ve(()=>n.endTimestamp,!1),offsets:{value:de({from:ve(()=>n.startTimestampOffset,!1),to:ve(()=>n.endTimestampOffset,!1)})},span:ve(()=>n.numberOfMonths,!1),timezone:{...ve(()=>t,!1),set:s=>{const r=t;t=An(s??void 0).tz.current,t!==r&&(n=new ud(t,...e))}}})},Fr=Zi(),eA=()=>Zi(Date.now(),zc),tA=()=>Zi(Date.now(),Kc),ip=(...e)=>e.length===0?Fr:Zi(...e);var Ge=(e=>(e[e.CURRENT=1]="CURRENT",e[e.CURSOR=2]="CURSOR",e[e.WEEKEND=4]="WEEKEND",e[e.LINE_START=8]="LINE_START",e[e.LINE_END=16]="LINE_END",e[e.WITHIN_BLOCK=32]="WITHIN_BLOCK",e[e.BLOCK_START=64]="BLOCK_START",e[e.BLOCK_END=128]="BLOCK_END",e[e.WITHIN_RANGE=256]="WITHIN_RANGE",e[e.RANGE_START=512]="RANGE_START",e[e.RANGE_END=1024]="RANGE_END",e[e.WITHIN_SELECTION=2048]="WITHIN_SELECTION",e[e.SELECTION_START=4096]="SELECTION_START",e[e.SELECTION_END=8192]="SELECTION_END",e[e.ALL=16383]="ALL",e))(Ge||{}),Rs=(e=>(e[e.PREV=1]="PREV",e[e.BLOCK=0]="BLOCK",e[e.FRAME=2]="FRAME",e[e.PERIOD=4]="PERIOD",e))(Rs||{}),qa=(e=>(e[e.PREV_PERIOD=5]="PREV_PERIOD",e[e.PREV_FRAME=3]="PREV_FRAME",e[e.PREV=1]="PREV",e[e.NEXT=0]="NEXT",e[e.NEXT_FRAME=2]="NEXT_FRAME",e[e.NEXT_PERIOD=4]="NEXT_PERIOD",e))(qa||{});const ap=(()=>{const e={},t=Object.keys(Ge).filter(s=>isNaN(+s)),n=s=>s!=="ALL"&&Dt(s)&&t.includes(s);return s=>{const r=s&Ge.ALL;return e[r]||(e[r]=new Proxy(de({valueOf:{value:()=>r}}),Ei({get:(a,o)=>{switch(o){case"valueOf":return a.valueOf;case Symbol.toStringTag:return"_";default:if(!n(o))return}return r&Ge[o]?1:void 0}}))),e[r]}})(),nA=e=>(t,n,s)=>{if(Dt(n)){const r=+n;if(r>=0&&r<t.length)return e(r)}return Reflect.get(t,n,s)},hd=function*(e=fo,t){for(let n=0;n<this.length;n++)yield e.call(t,this[n],n,this)},sA=Object.freeze(de({[Symbol.iterator]:{value(){return hd.call(this)}},map:{value(e,t){return[...hd.call(this,e,t)]}}})),Tn=(e,t)=>ee(e)?Tn({length:{get:e}},t):fr(e)?Tn({length:{value:e}},t):new Proxy(mr(sA,e),{get:nA(t),set:Na}),ii=(()=>{const e=new Map,t=yo(),n=(s=Date.now())=>{const r=new Date(_n(t,s)),a=Kt(t,r.setHours(0,0,0,0)),o=Kt(t,r.setDate(r.getDate()+1));return[a,o-a]};return s=>{t.tz=s;const r=t.tz.current;return e.get(r)??(()=>{let a=null,o=null,c=null;const d=()=>(t.tz=r,a??n()[0]),l=(g=Date.now())=>{t.tz=r,[a,o]=n(g)},{cancelSubscriptions:h,requestNotification:u,subscribe:p,on:f}=To({timestamp:d});f.resume=()=>{c=ic.subscribe(g=>{if(us(g))return;const{now:y}=g;if(Ko(a)||Ko(o))return l(y);y-a<o||(l(y),u())})},f.idle=()=>{c==null||c(),a=o=c=null};const T=de({cancelSubscriptions:X(h),timestamp:ve(d),timezone:X(r),subscribe:X(p)});return e.set(r,T),T})()}})();var Ys,nt,Jr,eo,to,no,Lt,ht,dn,qs,js,Vs,Zn,un,so,ze,qe,je,zs,hn,Qn,Ks,Ft,ro,oo,Pn,pn,io,ao,ui,hi,Ae,cp,lp,Cs,dp,lt,Nr,Va;const Ls=class Ls{constructor(){$(this,Ae);$(this,nt,0);$(this,Jr);$(this,eo);$(this,to,-1);$(this,no,-1);$(this,Lt);$(this,ht);$(this,dn);$(this,qs,!1);$(this,js);$(this,Vs,0);$(this,Zn,[]);$(this,un,m(Ls,Ys));$(this,so,12);$(this,ze);$(this,qe);$(this,je,1);$(this,zs);$(this,hn);$(this,Qn);$(this,Ks,ii());$(this,Ft);$(this,ro,-1/0);$(this,oo,1/0);$(this,Pn,-1/0);$(this,pn,1/0);$(this,io,1/0);$(this,ao,0);Y(this,"daysInWeek",0);Y(this,"origin");Y(this,"originTimestamp");$(this,ui,Tn(()=>this.daysInWeek,this.getDayOfWeekAtIndex.bind(this)));$(this,hi,Tn(()=>m(this,je),K(this,Ae,dp).bind(this)))}get fromTimestamp(){return m(this,ro)}get toTimestamp(){return m(this,oo)}get numberOfBlocks(){return m(this,io)}get blankSelection(){return m(this,ze)===m(this,qe)&&oe(m(this,qe))}get cursor(){return m(this,Lt)??-1}get daysOfWeek(){return m(this,ui)}get dynamicBlockHeight(){return m(this,qs)}set dynamicBlockHeight(t){xe(t)?k(this,qs,!!t):Ea(t)&&k(this,qs,t)}set effect(t){xe(t)?k(this,js,void 0):ee(t)&&k(this,js,t)}get firstWeekDay(){return m(this,Vs)}set firstWeekDay(t){if(xe(t))this.firstWeekDay=0;else if(!Vh.includes(t)||m(this,Vs)===k(this,Vs,t))return}get frameBlocks(){return m(this,hi)}get isAtEnd(){return!ss(m(this,pn))&&m(this,pn)===m(this,je)-1}get isAtStart(){return!ss(m(this,Pn))&&m(this,Pn)===0}get locale(){return m(this,un)}set locale(t){const n=m(this,un);if(xe(t))k(this,un,m(Ls,Ys));else if(typeof Intl<"u")try{k(this,un,new Intl.Locale(t).toString())}catch{k(this,un,m(Ls,Ys))}m(this,un)!==n&&this.refreshFrame(!0)}get selectionStart(){return m(this,ze)}get selectionEnd(){return m(this,qe)}get size(){return m(this,je)}set size(t){const n=Math.min(!xe(t)&&Jy(t)||1,m(this,so));m(this,je)!==k(this,je,n)&&(K(this,Ae,Va).call(this),this.refreshFrame())}get timeslice(){return m(this,hn)}set timeslice(t){if(t===m(this,zs)||xe(t)&&m(this,zs)===Fr)return;const{from:n,to:s,timezone:r}=k(this,zs,t??Fr);k(this,hn,ip(n,s)),this.timezone=r}get timezone(){return m(this,Qn)}set timezone(t){m(this,hn).timezone=t,k(this,Qn,m(this,hn).timezone),k(this,Ks,ii(m(this,Qn))),m(this,Ft)&&(m(this,Ft).call(this),k(this,Ft,m(this,Ks).subscribe(this.refreshFrame.bind(this,!0)))),K(this,Ae,cp).call(this)}set trackCurrentDay(t){Ea(t)?t&&!m(this,Ft)?k(this,Ft,m(this,Ks).subscribe(this.refreshFrame.bind(this,!0))):!t&&m(this,Ft)&&(m(this,Ft).call(this),k(this,Ft,void 0)):xe(t)&&(this.trackCurrentDay=!1)}get units(){return m(this,ao)}initialize(){this.timeslice=Fr}refreshFrame(t=!1){var n;if(m(this,Zn).length=0,!(oe(m(this,ht))||t)){const s=this.getFrameBlockAtIndex(m(this,nt)),{from:r,to:a}=s.inner,[o]=K(this,Ae,Cs).call(this,this.getTimestampAtIndex(r+m(this,ht)),!1);k(this,ht,this.getUnitsOffsetForTimestamp(this.getTimestampAtIndex(r),o));const c=r+m(this,ht),d=Et(r,c,a);if(d>c)return k(this,ht,this.getUnitsForFrameBlockAtIndex(--Wn(this,nt)._)+c-d),m(this,nt)>=0?this.refreshFrame():(k(this,nt,m(this,je)-1),this.shiftFrameByOffset(-1,Wo));if(d<c)return k(this,ht,c-d-1),++Wn(this,nt)._<m(this,je)?this.refreshFrame():(k(this,nt,0),this.shiftFrameByOffset(1,Wo));k(this,Jr,r),k(this,eo,a),k(this,dn,K(this,Ae,Cs).call(this,this.getTimestampAtIndex(c),!1)[0]),k(this,ht,this.getCursorBlockOriginTimestampOffset(m(this,dn))),k(this,Lt,r+m(this,ht));const l=m(this,nt)>0?this.getFrameBlockAtIndex(0):s,h=m(this,nt)<m(this,je)-1?this.getFrameBlockAtIndex(m(this,je)-1):s;k(this,to,l.inner.from),k(this,no,h.inner.to),k(this,ao,h.outer.to+1)}this.withCurrentDayTimestamp(),(n=m(this,js))==null||n.call(this)}shiftFrameByOffset(t,n){if(t&&Br(t))switch(n){case op:return K(this,Ae,Nr).call(this,t);case Ho:return K(this,Ae,Nr).call(this,t*12);case Wo:default:return K(this,Ae,Nr).call(this,t*m(this,je))}}shiftFrameCursor(t){switch(t){case zh:return K(this,Ae,lt).call(this,-1);case Qh:return K(this,Ae,lt).call(this,1);case sp:return K(this,Ae,lt).call(this,-this.rowspan);case Zh:return K(this,Ae,lt).call(this,this.rowspan);case Xh:return K(this,Ae,lt).call(this,m(this,Jr)-m(this,Lt));case Kh:return K(this,Ae,lt).call(this,m(this,eo)-m(this,Lt));case ep:return K(this,Ae,lt).call(this,-(m(this,Lt)%this.rowspan));case Jh:return K(this,Ae,lt).call(this,this.rowspan-(m(this,Lt)%this.rowspan+1));case np:return K(this,Ae,lt).call(this,-this.getUnitsForFrameBlockAtIndex((m(this,nt)??0)-1));case tp:return K(this,Ae,lt).call(this,this.getUnitsForFrameBlockAtIndex(m(this,nt)??0))}if(!(t<0)&&t>=m(this,to)&&t<=m(this,no))return K(this,Ae,lt).call(this,t-m(this,Lt))}shiftFrameToTimestamp(t){k(this,dn,this.originTimestamp=K(this,Ae,Cs).call(this,t,!1).reduce((n,s)=>n+s)),k(this,ht,this.getCursorBlockOriginTimestampOffset(m(this,dn))),this.reoriginate(),[Wn(this,Pn)._,Wn(this,pn)._]=this.getEdgeBlockOffsetsFromOrigin(),K(this,Ae,Va).call(this),this.refreshFrame(),K(this,Ae,lt).call(this,this.getUnitsOffsetForTimestamp(this.getTimestampAtIndex(m(this,Lt)),m(this,dn)))}clearSelection(){this.blankSelection||(k(this,ze,k(this,qe,void 0)),this.refreshFrame(!0))}updateSelection(t,n){const s=m(this,ze),r=m(this,qe),a=K(this,Ae,Cs).call(this,t,!1).reduce((o,c)=>o+c);switch(n===ad&&(a<=s?n=yt:a>=r&&(n=tt)),n){case tt:k(this,ze,a),k(this,qe,Math.max(m(this,ze),r??a));break;case yt:k(this,qe,a),k(this,ze,Math.min(s??a,m(this,qe)));break;case ad:case cd:{let o=Math.abs(a-(s??a)),c=Math.abs(a-(r??a));n===cd&&([o,c]=[c,o]),o>c?k(this,ze,a):k(this,qe,a);break}case rp:default:k(this,ze,k(this,qe,a));break}(m(this,ze)!==s||m(this,qe)!==r)&&this.refreshFrame(!0)}};Ys=new WeakMap,nt=new WeakMap,Jr=new WeakMap,eo=new WeakMap,to=new WeakMap,no=new WeakMap,Lt=new WeakMap,ht=new WeakMap,dn=new WeakMap,qs=new WeakMap,js=new WeakMap,Vs=new WeakMap,Zn=new WeakMap,un=new WeakMap,so=new WeakMap,ze=new WeakMap,qe=new WeakMap,je=new WeakMap,zs=new WeakMap,hn=new WeakMap,Qn=new WeakMap,Ks=new WeakMap,Ft=new WeakMap,ro=new WeakMap,oo=new WeakMap,Pn=new WeakMap,pn=new WeakMap,io=new WeakMap,ao=new WeakMap,ui=new WeakMap,hi=new WeakMap,Ae=new WeakSet,cp=function(){const{from:t,to:n,span:s,offsets:r}=m(this,hn);k(this,ro,t-r.from),k(this,oo,n-r.to),k(this,io,s);const a=oe(m(this,ze))?m(this,ze):Math.max(m(this,ze),t),o=oe(m(this,qe))?m(this,qe):Math.min(m(this,qe),n);a===m(this,ze)||o===m(this,qe)?(k(this,ze,a),k(this,qe,o)):k(this,ze,k(this,qe,void 0)),this.reslice(),k(this,so,ld(12,this.numberOfBlocks)),k(this,je,ld(m(this,je),this.numberOfBlocks)),this.shiftFrameToTimestamp(m(this,dn))},lp=function(t){return Et(m(this,Pn),t||0,m(this,pn)-m(this,je)+1)},Cs=function(t,n=!0){let s=new Date(t).getTime();if(isNaN(s))return K(this,Ae,Cs).call(this,Date.now());const{from:r,to:a}=m(this,hn),o=Et(r,s,a);o!==s&&n?(s=jd(r,a),(isNaN(s)||ss(s))&&(s=o)):s=o;const c=Ps(s,m(this,Qn));return[s-c,c]},dp=function(t){if(Br(t)&&t>=0&&t<m(this,je)){if(!m(this,Zn)[t]){const n=this.getFrameBlockAtIndex(t);if(!n)return;const[s,r]=this.getFormattedDataForFrameBlock(n[n.inner.from][0]+jr/2),a=n.outer.from;m(this,Zn)[t]=Tn({datetime:X(r),label:X(s),length:X(Math.ceil(n.outer.units/this.rowspan)),month:X(n.month),year:X(n.year)},o=>{const c=o*this.rowspan;return Tn(this.rowspan,d=>{const[l,h]=n[d+c],[u,p]=this.getFormattedDataForBlockCell(l+jr/2);return de({datetime:X(p),flags:X(ap(h)),index:X(a+d+c),label:X(u),timestamp:X(l)})})})}return m(this,Zn)[t]}},lt=function(t){t!==0&&(k(this,ht,m(this,ht)+t),this.refreshFrame())},Nr=function(t){const n=K(this,Ae,lp).call(this,t);n&&(this.shiftOrigin(n),k(this,Pn,m(this,Pn)-n),k(this,pn,m(this,pn)-n),k(this,nt,_o(m(this,nt)-n,m(this,je))),this.refreshFrame())},Va=function(){const t=m(this,je)-1,n=Math.min(t-this.origin%m(this,je),m(this,pn))-t;n&&K(this,Ae,Nr).call(this,n)},$(Ls,Ys,Di);let ja=Ls;var Jn,es,Xs,co,Zs,Qs,lo,Js,uo,er,tr,nr,Ze,za,Ka,Ss,Go;class rA extends ja{constructor(){super();$(this,Ze);$(this,Jn,7);$(this,es,[]);$(this,Xs,dd(this.firstWeekDay));$(this,co);$(this,Zs,-1/0);$(this,Qs,1/0);$(this,lo,1/0);$(this,Js);$(this,uo);$(this,er);$(this,tr);$(this,nr);Y(this,"daysInWeek",m(this,Jn));this.initialize()}get fromTimestamp(){return m(this,Zs)}get toTimestamp(){return m(this,Qs)}get numberOfBlocks(){return m(this,lo)}get currentDayTimestamp(){return m(this,co)}get dynamicBlockHeight(){return super.dynamicBlockHeight}set dynamicBlockHeight(n){const s=this.dynamicBlockHeight;super.dynamicBlockHeight=n,this.dynamicBlockHeight!==s&&this.refreshFrame(!0)}get rowspan(){return m(this,Jn)}get firstWeekDay(){return super.firstWeekDay}set firstWeekDay(n){const s=this.firstWeekDay;super.firstWeekDay=n,this.firstWeekDay!==s&&(m(this,es).length=0,k(this,Xs,dd(this.firstWeekDay)),this.reoriginate(),this.refreshFrame())}getCursorBlockOriginTimestampOffset(n){return On(n,this.timezone)[2]-1}getDayOfWeekAtIndex(n){if(!m(this,es)[n]){const s=new Date(this.getTimestampAtIndex(n));let r=0;m(this,Xs).includes(n)&&(r|=Ge.WEEKEND),n===0?r|=Ge.LINE_START:n===6&&(r|=Ge.LINE_END);const a={};for(const o of Xy)a[o]=X(s.toLocaleDateString(this.locale,{weekday:o,timeZone:this.timezone}));m(this,es)[n]=de({flags:X(ap(r)),labels:X(de(a))})}return m(this,es)[n]}getEdgeBlockOffsetsFromOrigin(){return[K(this,Ze,za).call(this,m(this,Zs)),K(this,Ze,za).call(this,m(this,Qs))]}getFormattedDataForBlockCell(n){const[s,r,a]=On(n,this.timezone);return[Number(a).toLocaleString(this.locale),`${s}-${`${r+1}`.padStart(2,"0")}-${`${a}`.padStart(2,"0")}`]}getFormattedDataForFrameBlock(n){const[s,r]=On(n,this.timezone);return[new Date(n).toLocaleDateString(this.locale,{month:"long",year:"numeric",timeZone:this.timezone}),`${s}-${`${r+1}`.padStart(2,"0")}`]}getFrameBlockAtIndex(n){const[s,r,a]=fa(this.origin,m(this,er),n),o=n>0?this.getFrameBlockAtIndex(n-1).inner.to+1:m(this,Js),c=o+s-1,d=Math.floor(o/7)*7,l=this.dynamicBlockHeight?Math.ceil((c+1)/7)*7:d+od,h=this.dynamicBlockHeight?l-d:od,u=new Proxy(de(),Ei({get:(p,f,T)=>{if(Dt(f)){const g=+f;if(Br(g)&&g>=0&&g<h){const y=d+g,_=this.getTimestampAtIndex(y),v=y%m(this,Jn);let N=_===this.currentDayTimestamp?Ge.CURRENT:0;return y===this.cursor&&(N|=Ge.CURSOR),m(this,Xs).includes(v)&&(N|=Ge.WEEKEND),v===0?N|=Ge.LINE_START:v===m(this,Jn)-1&&(N|=Ge.LINE_END),y>=o&&y<=c&&(y===o?N|=Ge.BLOCK_START:y===c&&(N|=Ge.BLOCK_END),N|=Ge.WITHIN_BLOCK),_>=this.fromTimestamp&&_<=this.toTimestamp&&(_===this.fromTimestamp&&(N|=Ge.RANGE_START),_===this.toTimestamp&&(N|=Ge.RANGE_END),N|=Ge.WITHIN_RANGE),_>=m(this,tr)&&_<=m(this,nr)&&(_===m(this,tr)&&(N|=Ge.SELECTION_START),_===m(this,nr)&&(N|=Ge.SELECTION_END),N|=Ge.WITHIN_SELECTION),[_,N]}}return Reflect.get(p,f,T)}}));return mr(u,{inner:{value:de({from:{value:o},to:{value:c},units:{value:s}})},month:{value:r},outer:{value:de({from:{value:d},to:{value:l-1},units:{value:h}})},year:{value:a}})}getUnitsForFrameBlockAtIndex(n){return fa(this.origin,m(this,er),n)[0]}getUnitsOffsetForTimestamp(n,s){return Math.round((s-n)/jr)}reoriginate(){this.originTimestamp=Bh(this.originTimestamp,this.timezone);const[n,s]=On(this.originTimestamp,this.timezone),r=$h(this.originTimestamp,this.timezone,this.firstWeekDay);this.origin=s,k(this,er,n),k(this,Js,this.getUnitsOffsetForTimestamp(r,this.originTimestamp)),k(this,uo,K(this,Ze,Ka).call(this,this.originTimestamp,-m(this,Js)))}reslice(){K(this,Ze,Go).call(this),k(this,Zs,K(this,Ze,Ss).call(this,super.fromTimestamp)),k(this,Qs,K(this,Ze,Ss).call(this,super.toTimestamp)),k(this,lo,Ya(super.fromTimestamp,super.toTimestamp,this.timezone)+1)}shiftOrigin(n){const[s,r]=On(this.originTimestamp,this.timezone),[,a,o]=fa(r,s,n),c=An(this.timezone),d=new Date(_n(c,this.originTimestamp)).setFullYear(o,a);this.originTimestamp=Kt(c,d),this.reoriginate()}clearSelection(){super.clearSelection(),K(this,Ze,Go).call(this),this.refreshFrame(!0)}getTimestampAtIndex(n){return K(this,Ze,Ka).call(this,m(this,uo),n)}updateSelection(n,s){super.updateSelection(n,s),K(this,Ze,Go).call(this),this.refreshFrame(!0)}withCurrentDayTimestamp(){k(this,co,K(this,Ze,Ss).call(this,Date.now()))}}Jn=new WeakMap,es=new WeakMap,Xs=new WeakMap,co=new WeakMap,Zs=new WeakMap,Qs=new WeakMap,lo=new WeakMap,Js=new WeakMap,uo=new WeakMap,er=new WeakMap,tr=new WeakMap,nr=new WeakMap,Ze=new WeakSet,za=function(n){const s=Ya(n,this.originTimestamp,this.timezone);return n<this.originTimestamp?0-s:s},Ka=function(n,s=0){const r=An(this.timezone),a=_n(r,n),o=Kt(r,a+s*jr);let[,,,c,d]=On(o,this.timezone),l=0;return(c>0||d>0)&&(c=(c>12?24:0)-c,d=(c>1?1:-1)*d,l=c*36e5+d*6e4),o+l},Ss=function(n){return oe(n)||ss(n)?n:n-Ps(n,this.timezone)},Go=function(){k(this,tr,K(this,Ze,Ss).call(this,this.selectionStart)),k(this,nr,K(this,Ze,Ss).call(this,this.selectionEnd))};const pd=Symbol("<<NO_EXCEPTION>>"),fd=e=>{const t=[];return de({bind:X(s=>function(...r){let a=pd;try{return t.push(s),s.call(this,...r)}catch(o){throw a=o}finally{t.pop(),t.length===0&&a===pd&&e()}}),effect:X(e)})};var Wd,Hd,Me,Mt,B,xt,At,Bt,Qe,ts,pt,sr,fn,mn,vt,jt,rr,ho,kn,Rt,pi,wn,or,ns,po,fi,ke,mi,_i,gi,Ti,yi,Ai,Nt,up,hp,pp,vi,Yo,ce,Dr,Xa,fp,mp,_p,gp,Za,Tp,br,Qa,qo,Ja,ec,tc,nc;let oA=(ke=class{constructor(){$(this,ce);Y(this,"grid");Y(this,"kill");$(this,Me,z);$(this,Mt,!1);$(this,B);$(this,xt);$(this,At);$(this,Bt,!1);$(this,Qe,ks);$(this,ts,!1);$(this,pt);$(this,sr,(Wd=m(this,pt))==null?void 0:Wd.join(" "));$(this,fn);$(this,mn);$(this,vt);$(this,jt);$(this,rr);$(this,ho,ii());$(this,kn,[]);$(this,Rt);$(this,pi,new Proxy(Tn(()=>{var t;return((t=m(this,Rt))==null?void 0:t.length)??0},K(this,ce,Za).bind(this)),Ei({get:(t,n,s)=>{var a,o;const r=((a=m(this,Rt))==null?void 0:a.indexOf(n))??-1;return r>=0?(o=K(this,ce,Za).call(this,r))==null?void 0:o[1]:Reflect.get(t,n,s)}})));$(this,wn,To({blocks:()=>{var t;return(t=m(this,B))==null?void 0:t.size},cells:()=>{var t;return(t=m(this,B))==null?void 0:t.units},controls:()=>yr(id,m(this,Me).controls),cursor:()=>{var t;return(t=m(this,B))==null?void 0:t.cursor},from:()=>{var t;return(t=m(this,B))==null?void 0:t.selectionStart},highlight:()=>m(this,Qe),locale:()=>{var t;return(t=m(this,B))==null?void 0:t.locale},minified:()=>As(m(this,Me).minified),origin:()=>{var t;return(t=m(this,B))==null?void 0:t.getTimestampAtIndex(0)},timezone:()=>{var t;return(t=m(this,B))==null?void 0:t.timezone},to:()=>{var t;return(t=m(this,B))==null?void 0:t.selectionEnd},today:()=>m(this,ho).timestamp}));$(this,or,(Hd=m(this,wn))==null?void 0:Hd.snapshot);$(this,ns,fd(()=>{var t;return m(this,vt)&&((t=m(this,wn))==null?void 0:t.requestNotification())}));$(this,po,fd(()=>{var t;return(t=m(this,vt))==null?void 0:t.call(m(this,ce,Dr))}));$(this,fi,mr(Tn(()=>{var t;return((t=m(this,B))==null?void 0:t.size)??0},t=>{var n;return(n=m(this,B))==null?void 0:n.frameBlocks[t]}),{config:{value:Object.defineProperties(t=>(t&&K(this,ce,mp).call(this,t),m(this,ce,Dr)),{cursorIndex:{get:()=>m(this,fn),set:t=>{m(this,Mt)||(xe(t)?k(this,fn,void 0):ee(t)&&k(this,fn,t))}},shiftFactor:{get:()=>m(this,mn),set:t=>{m(this,Mt)||(xe(t)?k(this,mn,void 0):ee(t)&&k(this,mn,t))}},watch:{get:()=>m(this,vt),set:t=>{var n,s,r,a,o;if(!m(this,Mt))if(ee(t)){if(k(this,vt,t),!m(this,jt)){const c=(n=m(this,ns))==null?void 0:n.bind(m(ke,vi).bind(this));c&&(k(this,jt,(s=m(this,ns))==null?void 0:s.bind(he)),k(this,rr,(a=m(this,wn))==null?void 0:a.subscribe((r=m(this,po))==null?void 0:r.bind(c))),m(this,B)&&(m(this,B).effect=m(this,jt)))}if(!m(this,ts))return;k(this,ts,!1),(o=m(this,jt))==null||o.call(this)}else xe(t)&&k(this,vt,void 0)}}})},controls:{value:m(this,pi)},cursor:{value:Object.defineProperties(t=>K(ke,Nt,Yo).call(this,n=>!!(n&&K(this,ce,_p).call(this,n)))(t),{valueOf:{value:()=>{var t;return((t=m(this,B))==null?void 0:t.cursor)??-1}}})},highlight:{value:(()=>{const t=()=>m(this,xt)===m(this,At)&&oe(m(this,At)),n=s=>r=>K(ke,Nt,Yo).call(this,a=>{var o,c,d,l,h;if(!(m(this,Mt)||!m(this,Qe)||m(this,Qe)===ks)){if(xe(a))return K(this,ce,Qa).call(this);t()?(c=m(this,B))==null||c.updateSelection(a,rp):((o=m(this,B))==null||o.updateSelection(a,s),m(this,Qe)===Yn&&m(this,pt)&&K(this,ce,qo).call(this,a,s===tt?yt:tt,m(this,pt))),k(this,xt,(d=m(this,B))==null?void 0:d.selectionStart),k(this,At,(l=m(this,B))==null?void 0:l.selectionEnd),(h=m(this,B))==null||h.shiftFrameToTimestamp(s===tt?m(this,xt):m(this,At))}})(r);return de({blank:{get:t},from:{get:()=>{var s;return((s=m(this,B))==null?void 0:s.selectionStart)??m(this,xt)},set:n(tt)},to:{get:()=>{var s;return((s=m(this,B))==null?void 0:s.selectionEnd)??m(this,At)},set:n(yt)}})})()},rowspan:{get:()=>{var t;return((t=m(this,B))==null?void 0:t.rowspan)??0}},weekdays:{get:()=>{var t;return((t=m(this,B))==null?void 0:t.daysOfWeek)??m(ke,gi)}}}));this.grid=m(this,fi),this.kill=K(this,ce,gp).bind(this)}},Me=new WeakMap,Mt=new WeakMap,B=new WeakMap,xt=new WeakMap,At=new WeakMap,Bt=new WeakMap,Qe=new WeakMap,ts=new WeakMap,pt=new WeakMap,sr=new WeakMap,fn=new WeakMap,mn=new WeakMap,vt=new WeakMap,jt=new WeakMap,rr=new WeakMap,ho=new WeakMap,kn=new WeakMap,Rt=new WeakMap,pi=new WeakMap,wn=new WeakMap,or=new WeakMap,ns=new WeakMap,po=new WeakMap,fi=new WeakMap,mi=new WeakMap,_i=new WeakMap,gi=new WeakMap,Ti=new WeakMap,yi=new WeakMap,Ai=new WeakMap,Nt=new WeakSet,up=function(t){if(!Dt(t)||!m(ke,mi).test(t))return;const n=t.split(/\s+/);return Array.from({length:6},(s,r)=>parseInt(n[r]??"0"))},hp=function(t){switch(t&~Rs.PREV){case Rs.FRAME:return Wo;case Rs.PERIOD:return Ho;case Rs.BLOCK:default:return op}},pp=function(t){return t&Rs.PREV?-1:1},vi=new WeakMap,Yo=function(t){var n;return((n=m(this,ns))==null?void 0:n.bind(t))??t},ce=new WeakSet,Dr=function(){return{...m(this,Me)}},Xa=function(){return new rA},fp=function(t){return!!m(this,B)&&!(t>0?m(this,B).isAtEnd:m(this,B).isAtStart)},mp=function(t){var r,a;if(m(this,Mt))return;k(this,pt,void 0);const n=t==null?void 0:t.highlight,s=As(m(this,Me).minified);if(Dt(n)?k(this,pt,K(r=ke,Nt,up).call(r,n))&&k(this,Qe,Yn):k(this,Qe,yr(Qy,n,m(this,Qe))),k(this,Me,{...m(this,Me),...t,blocks:yr(Ms,t==null?void 0:t.blocks,m(this,Me).blocks),controls:yr(id,t==null?void 0:t.controls,m(this,Me).controls),firstWeekDay:yr(Vh,t==null?void 0:t.firstWeekDay,m(this,Me).firstWeekDay),fixedBlockHeight:As(t==null?void 0:t.fixedBlockHeight,m(this,Me).fixedBlockHeight),highlight:m(this,Qe),minified:As(t==null?void 0:t.minified,m(this,Me).minified),trackCurrentDay:As(t==null?void 0:t.trackCurrentDay,m(this,Me).trackCurrentDay)}),!ee(m(this,vt))){m(this,B)?k(this,ts,!0):(k(this,B,m(this,ce,Xa)),K(this,ce,ec).call(this),K(this,ce,nc).call(this),K(this,ce,tc).call(this));return}(!m(this,B)||s!==m(this,Me).minified)&&(k(this,B,m(this,ce,Xa)),m(this,B).effect=m(this,jt)),K(this,ce,ec).call(this),(a=m(this,jt))==null||a.call(this)},_p=function(t){if(t&&m(this,B)&&ee(m(this,vt))){if(t instanceof KeyboardEvent){switch(t.code){case ne.ARROW_LEFT:m(this,B).shiftFrameCursor(zh);break;case ne.ARROW_RIGHT:m(this,B).shiftFrameCursor(Qh);break;case ne.ARROW_UP:m(this,B).shiftFrameCursor(sp);break;case ne.ARROW_DOWN:m(this,B).shiftFrameCursor(Zh);break;case ne.HOME:m(this,B).shiftFrameCursor(t.ctrlKey?Xh:ep);break;case ne.END:m(this,B).shiftFrameCursor(t.ctrlKey?Kh:Jh);break;case ne.PAGE_UP:t.shiftKey?m(this,B).shiftFrameByOffset(-1,Ho):m(this,B).shiftFrameCursor(np);break;case ne.PAGE_DOWN:t.shiftKey?m(this,B).shiftFrameByOffset(1,Ho):m(this,B).shiftFrameCursor(tp);break;case ne.SPACE:case ne.ENTER:return K(this,ce,br).call(this),!0;default:return}return m(this,Bt)&&K(this,ce,br).call(this,z),!0}if(t instanceof MouseEvent&&m(ke,_i).includes(t.type)&&ee(m(this,fn))){const n=m(this,fn).call(m(this,ce,Dr),t);if(!Br(n))return;const s=t.type==="click";if(!(s||m(this,Bt)))return;if(m(this,B).shiftFrameCursor(n),m(this,B).cursor===n)return s?K(this,ce,br).call(this):K(this,ce,br).call(this,z),!0}}},gp=function(){var t;m(this,Mt)||((t=m(this,rr))==null||t.call(this),k(this,ns,k(this,po,k(this,fn,k(this,B,k(this,Qe,k(this,sr,k(this,or,k(this,pt,k(this,mn,k(this,rr,k(this,wn,k(this,jt,k(this,vt,void 0))))))))))))),k(this,Me,z),k(this,Bt,k(this,ts,!1)),k(this,Mt,!0))},Za=function(t){var s,r;if(!m(this,Rt)||t<0||t>=m(this,Rt).length)return;const n=m(this,Rt)[t];if(!m(this,kn)[t]){const a=qa[n],o=K(s=ke,Nt,hp).call(s,a),c=K(r=ke,Nt,pp).call(r,a);m(this,kn)[t]=(...d)=>K(ke,Nt,Yo).call(this,(...l)=>{var p;const h=K(this,ce,fp).call(this,c);if(!(h&&l.length))return h;const u=K(this,ce,Tp).call(this,n,l[0]);return oe(u)?!1:((p=m(this,B))==null||p.shiftFrameByOffset(c*u,o),!0)})(...d)}return[n,m(this,kn)[t]]},Tp=function(t,n){if(!(m(this,B)&&ee(m(this,vt))))return;if(n instanceof MouseEvent){if(n.type!=="click")return}else if(n instanceof KeyboardEvent){if(!m(ke,Ti).includes(n.code))return}else return;let s=1;if(ee(m(this,mn))){const r=Number(m(this,mn).call(m(this,ce,Dr),n,t));s=Number.isInteger(r)&&r>=1?r:s}return s},br=function(t){if(m(this,Mt)||!m(this,B))return;switch(m(this,Qe)){case Yn:case ws:break;case ks:default:return}const n=m(this,B).cursor,s=Math.max(m(this,B).getTimestampAtIndex(n),m(this,B).timeslice.from),r=Math.min(m(this,B).getTimestampAtIndex(n+1)-1,m(this,B).timeslice.to),a=m(this,pt);if(m(this,Qe)===ws||m(this,B).blankSelection||a)if(k(this,Bt,!(m(this,Qe)===ws||a)),m(this,Qe)===Yn&&a){const o=r>=m(this,B).selectionEnd?tt:yt;o===tt?m(this,B).updateSelection(r,yt):m(this,B).updateSelection(s,tt),K(this,ce,qo).call(this,o===tt?m(this,B).selectionEnd:m(this,B).selectionStart,o,a)}else m(this,B).updateSelection(s,tt),m(this,B).updateSelection(r,yt);else{const o=t===z,c=An(m(this,B).timezone);if(o||k(this,Bt,!1),s<=m(this,B).selectionStart){const d=new Date(_n(c,m(this,B).selectionStart)),l=Math.min(Kt(c,d.setDate(d.getDate()+1)-1),m(this,B).timeslice.to);s===m(this,B).selectionStart&&r<=l&&m(this,B).updateSelection(r,yt),m(this,B).updateSelection(s,tt)}else{const d=new Date(_n(c,m(this,B).selectionEnd)),l=Math.max(Kt(c,d.setHours(0,0,0,0)),m(this,B).timeslice.from);s<=m(this,B).selectionEnd&&s>=l&&m(this,B).updateSelection(s,tt),m(this,B).updateSelection(r,yt)}if(o)return}k(this,xt,m(this,B).selectionStart),k(this,At,m(this,B).selectionEnd)},Qa=function(){var t;(t=m(this,B))==null||t.clearSelection(),k(this,Bt,!1),k(this,xt,k(this,At,void 0))},qo=function(t,n,s){var f;if(!m(this,B))return;const r=An((f=m(this,B))==null?void 0:f.timezone),a=new Date(_n(r,t)),o=n===tt?-1:1,[c=0,d=0,l=0,h=0,u=0,p=0]=s??[];a.setFullYear(a.getFullYear()+c*o,a.getMonth()+d*o,a.getDate()+l*o),a.setHours(a.getHours()+h*o,a.getMinutes()+u*o,a.getSeconds()+p*o),m(this,B).updateSelection(Kt(r,a.getTime()-o),n)},Ja=function(){var t,n;m(this,xt)&&((t=m(this,B))==null||t.updateSelection(m(this,xt),tt)),m(this,At)&&((n=m(this,B))==null||n.updateSelection(m(this,At),yt)),k(this,Bt,!1)},ec=function(){m(this,B)&&(m(this,B).timeslice=m(this,Me).timeslice,m(this,B).dynamicBlockHeight=!m(this,Me).fixedBlockHeight,m(this,B).firstWeekDay=m(this,Me).firstWeekDay,m(this,B).locale=m(this,Me).locale,m(this,B).size=m(this,Me).blocks,m(this,B).timezone=m(this,Me).timezone,m(this,B).trackCurrentDay=m(this,Me).trackCurrentDay,k(this,ho,ii(m(this,B).timezone)),K(this,ce,Ja).call(this))},tc=function(){var t,n,s,r,a,o;switch(m(this,Qe)){case Yn:!en((t=m(this,B))==null?void 0:t.blankSelection)&&m(this,pt)&&K(this,ce,qo).call(this,(n=m(this,B))==null?void 0:n.selectionStart,yt,m(this,pt));break;case ws:if(!en((s=m(this,B))==null?void 0:s.blankSelection)){const c=An((r=m(this,B))==null?void 0:r.timezone),d=new Date(_n(c,(a=m(this,B))==null?void 0:a.selectionStart));(o=m(this,B))==null||o.updateSelection(Kt(c,d.setHours(23,59,59,999)),yt)}break;case ks:default:K(this,ce,Qa).call(this);return}},nc=function(){var t,n;switch((t=m(this,wn))==null?void 0:t.snapshot.controls){case qc:k(this,Rt,m(ke,yi));break;case jc:k(this,Rt,m(ke,Ai));break;case Vc:default:k(this,Rt,void 0)}m(this,kn).length=0,m(this,kn).length=((n=m(this,Rt))==null?void 0:n.length)??0},$(ke,Nt),$(ke,mi,/^(?:0|[1-9]\d*)(\s+(?:0|[1-9]\d*)?){0,5}?$/),$(ke,_i,["click","mouseover","pointerover"]),$(ke,gi,Tn(0,he)),$(ke,Ti,[ne.ENTER,ne.SPACE]),$(ke,yi,Object.keys(qa).filter(t=>isNaN(+t))),$(ke,Ai,["PREV","NEXT"]),$(ke,vi,function(t){var o,c;if(us(t))return;let n=!1,s=!1,r=!1;const a=(o=m(this,pt))==null?void 0:o.join(" ");for(const d of Object.keys(t))t[d]!==((c=m(this,or))==null?void 0:c[d])&&(d==="controls"?n=!0:d==="highlight"?s=!0:(d==="from"||d==="to")&&(r=!0));m(this,sr)!==a&&(k(this,sr,a),s=!0),k(this,or,t),m(this,Bt)&&!r&&K(this,ce,Ja).call(this),n&&K(this,ce,nc).call(this),s&&K(this,ce,tc).call(this)}),ke);const Yt=Object.defineProperties(t=>{const{grid:n,kill:s}=new oA;return fr(t)?n.config({blocks:t}):ee(t)?ir.then(()=>{n.config.watch=t}):n.config(t),de({grid:X(n),kill:X(s)})},{controls:{value:de({ALL:{value:qc},MINIMAL:{value:jc},NONE:{value:Vc}})},highlight:{value:de({ONE:{value:ws},MANY:{value:Yn},NONE:{value:ks}})},slice:{value:Object.defineProperties(ip.bind(null),{FROM:{value:zc},TO:{value:Kc},UNBOUNDED:{value:Fr},SINCE_NOW:{get:eA},UNTIL_NOW:{get:tA}})}}),iA=({config:e,grid:{controls:t},renderer:n})=>e.controls===Yt.controls.NONE||!ee(n)?null:i(Q,{children:t.map(([s,r])=>n(s,r))}),aA=Ue(iA),cA=e=>{const t=C((n,s)=>{s instanceof Element&&s.setAttribute("tabindex","-1"),n instanceof Element&&(n.setAttribute("tabindex","0"),ir.then(()=>n==null?void 0:n.focus()))},[]);return En(C((n,s)=>{try{e==null||e(n,s)}finally{t(n,s)}},[e]))},lA=({blocks:e,controls:t,dynamicBlockRows:n,firstWeekDay:s,highlight:r,locale:a,onHighlight:o,originDate:c,renderControl:d,sinceDate:l,timezone:h,trackCurrentDay:u,untilDate:p,useYearView:f},T)=>{const{i18n:g}=H(),[y,_]=F(performance.now()),v=A(()=>Yt.slice(l,p),[l,p]),N=q(z),S=A(()=>t??(ee(d)?Yt.controls.MINIMAL:Yt.controls.NONE),[t,d]),D=A(()=>r??(ee(o)?Yt.highlight.ONE:Yt.highlight.NONE),[r,o]),{grid:R,kill:b}=A(()=>{const{grid:w,kill:W}=Yt(function(){_(performance.now()),N.current=this,!(x===w.highlight.from&&j===w.highlight.to)&&(x=w.highlight.from,j=w.highlight.to,o==null||o(x,j))});let{from:x,to:j}=w.highlight;return w.config.cursorIndex=L=>{let U=L.target;for(;U&&U!==L.currentTarget;){const ie=Number(U.dataset.cursorPosition);if(Number.isFinite(ie))return ie;U=U.parentNode}},w.config.shiftFactor=function(L){if(this.controls===Yt.controls.MINIMAL)return L!=null&&L.shiftKey?12:L!=null&&L.altKey?this.blocks:1},{grid:w,kill:W}},[]),E=A(()=>{const w=W=>{R.cursor(W)};return{onClickCapture:w,onMouseOverCapture:w,onPointerOverCapture:w,onKeyDownCapture:W=>{R.cursor(W)&&W.preventDefault()}}},[R]),P=cA(C((w,W)=>{W instanceof Element&&W.removeAttribute("aria-selected"),w instanceof Element&&w.setAttribute("aria-selected","true")},[]));return K2(T,()=>{const{from:w,to:W}=(R==null?void 0:R.highlight)||z;return{clear:()=>{R!=null&&R.highlight&&(R.highlight.from=void 0)},get config(){return{...N.current??z}},get from(){return sd(w)},set from(x){R!=null&&R.highlight&&x&&(R.highlight.from=x.getTime())},get to(){return sd(W)},set to(x){R!=null&&R.highlight&&x&&(R.highlight.to=x.getTime())}}},[R,y]),G(()=>{R.config({blocks:e,controls:S,firstWeekDay:s,fixedBlockHeight:!n,highlight:D,locale:a??g.locale,minified:f,timeslice:v,timezone:h,trackCurrentDay:u})},[S,D,e,n,s,R,g,a,v,h,u,f]),G(()=>{const w=[].concat(c).slice(0,2).map(Number).filter(Boolean);return w[0]&&(R.highlight.from=+w[0]),w[1]&&(R.highlight.to=+w[1]),b},[]),{cursorElementRef:P,cursorRootProps:E,grid:R}},dA=_r((e,t)=>{const n=lA(e,t),s=n.grid.config();return i("div",{role:"none",children:[i(aA,{config:s,grid:n.grid,renderer:e.renderControl}),i(Ky,{ref:n.cursorElementRef,config:s,cursorRootProps:n.cursorRootProps,grid:n.grid,onlyCellsWithin:e.onlyCellsWithin,prepare:e.prepare})]})}),uA=Ue(dA),hA=(e,t)=>{const[n,s]=F(),r=En(A(()=>{const a=o=>(...c)=>{const d=e(o,...c);return d&&Hu(d,o)};return s(void 0),o=>s(o instanceof Element?()=>a(o):void 0)},[e,t]),t);return[n,r]},pA=e=>{const{i18n:t}=H();return hA(C((n,s,r)=>{if(!(n instanceof HTMLElement))return null;if(ee(e))return e(s,r);let a,o,c;switch(s){case"PREV":a="prev",o="previous",c="chevron-left";break;case"NEXT":a=o="next",c="chevron-right";break;default:return null}const d=r();return d?i(_e,{"aria-label":t.get(`calendar.${o}Month`),variant:te.TERTIARY,disabled:!d,classNameModifiers:["circle",a],iconButton:!0,onClick:r,children:i(ue,{name:c})},s):null},[t,e]))},fA=_r((e,t)=>{const{i18n:n}=H(),[s,r]=pA(e.renderControl),[a,o]=F(performance.now()),c=A(()=>en(e.showTimezoneInfo),[e.showTimezoneInfo]),{clockTime:d,GMTOffset:l}=_y({timezone:e.timezone,withClock:c}),h=A(()=>M([{"adyen-pe-datepicker--with-timezone":c},"adyen-pe-datepicker"]),[c]),u=A(()=>c?{values:{offset:l,time:d}}:z,[l,d,c]),p=En(he,t),f=C(()=>{var T,g,y,_,v;o(performance.now()),(T=p.current)!=null&&T.from&&((g=p.current)!=null&&g.to)&&((v=e.onHighlight)==null||v.call(e,+((y=p.current)==null?void 0:y.from),+((_=p.current)==null?void 0:_.to)))},[o,e.onHighlight]);return i("div",{className:h,children:[i("div",{className:"adyen-pe-datepicker__selector-container",children:i(Wy,{now:e.now,calendarRef:p,onTimeRangeSelected:e.onPresetOptionSelected,options:e.timeRangePresetOptions,selectedOption:e.selectedPresetOption,timestamp:a,timezone:e.timezone})}),i("div",{ref:r,role:"group",className:"adyen-pe-datepicker__controls","aria-label":n.get("calendar.controls")}),i(uA,{...e,ref:p,firstWeekDay:Gc,dynamicBlockRows:!0,onlyCellsWithin:!0,controls:e.controls??Yt.controls.MINIMAL,highlight:e.highlight??Yt.highlight.MANY,onHighlight:f,renderControl:s,trackCurrentDay:!0}),c&&i("div",{className:"adyen-pe-datepicker__timezone",children:n.get("calendar.timezone",u)})]})}),mA="adyen-pe-filter-button";function _A(e,t){const{className:n,classNameModifiers:s=[],children:r,disabled:a,onClick:o,...c}=e,d=A(()=>rs("",n)||"",[n]),l=A(()=>Ii(a),[a]),{classes:h,click:u}=Pi(d,s,mA,l,e,o);return i("button",{className:h,ref:t,onClick:u,...c,children:i(I,{el:J.DIV,variant:O.BODY,stronger:!0,children:r})})}const gA=Cn(_A),TA=_r(function(t,n){return i(ri,{classNameModifiers:t.classNameModifiers,...t,ref:n,"aria-required":t.required,type:"text"})}),yA=e=>!e||Da(e),AA=(()=>{const e=t=>{const{editAction:n,name:s,onChange:r,onValueUpdated:a}=t,[o,c]=F(t.value),d=C(l=>{const h=l.target.value.trim();c(h),a(h)},[a]);return G(()=>{if(n===Je.CLEAR){const l="";c(l),a(l),r(l)}n===Je.APPLY&&r(o??"")},[o,n,r,a]),i(TA,{name:s,value:o,onInput:d})};return t=>i(e,{...t})})(),vA=({render:e,...t})=>{var W;const n=Pe(Ie.down.xs),[s,r]=Vt(!1),[a,o]=Vt(!1),c=A(()=>t.isValueEmpty??yA,[t.isValueEmpty]),[d,l]=Vt(c(t.value)),[h,u]=Vt(!1),[p,f]=Vt(!1),[T,g]=Vt(c(t.value)),y=Lr(),_=A(()=>e??AA,[e]),v=C(x=>{const j=c(x??void 0);l(j),g(Ko(x)),f(h?x!==t.value:!j)},[c,l,g,f,h,t.value]),{commitAction:N,commitActionButtons:S,committing:D,resetCommitAction:R}=mh({applyDisabled:T||!p,resetDisabled:d}),[b,E]=A(()=>{const x=j=>()=>{j!==s&&(j&&(R(),f(!1),u(!1)),r(j),o(j))};return[x(!1),x(!0)]},[r,s,R,o,u,f]);G(()=>{if(a){const x=c(t.value);o(!1),l(x),u(!x)}},[t.value,a,c,o,l,u]),G(()=>{D&&b(),l(d)},[D,b,l,d]);const P=Pe(Ie.only.sm),w=Pe(Ie.only.md);return i(Q,{children:[i("div",{className:`adyen-pe-filter adyen-pe-filter--${t.type}`,children:A(()=>i(gA,{classNameModifiers:[...t.appliedFilterAmount?["with-counter"]:[],...t.classNameModifiers??[],...s?["active"]:[],...d?[]:["has-selection"]],onClick:s?b:E,tabIndex:0,ref:y,children:i("div",{className:"adyen-pe-filter-button__default-container",children:[i(I,{el:J.SPAN,variant:O.BODY,stronger:!0,className:"adyen-pe-filter-button__label",children:t.label}),!!t.appliedFilterAmount&&i("div",{className:"adyen-pe-filter-button__counter-wrapper",children:i(I,{el:J.SPAN,variant:O.BODY,stronger:!0,className:"adyen-pe-filter-button__counter",children:t.appliedFilterAmount})})]})}),[t.appliedFilterAmount,t.classNameModifiers,t.label,s,d,b,E,y])}),s&&i(ti,{actions:S,title:(W=t.title)==null?void 0:W.trim(),variant:st.POPOVER,modifiers:["filter"],open:s,"aria-label":`${t.label}`,dismiss:b,dismissible:!1,withContentPadding:t.withContentPadding??!0,divider:!0,targetElement:y,disableFocusTrap:!1,position:se.BOTTOM,containerSize:t.containerSize,showOverlay:n,fitPosition:P||w,children:_({...t,editAction:N,onValueUpdated:v})})]})},yp=Ue(vA);var Vr=(e=>(e.FROM="from",e.TO="to",e))(Vr||{});const RA={month:"short",day:"numeric",year:"numeric"},Ap=(e,t,n,s)=>{const r=n&&t(n),a=s&&t(s);if(r&&a)return`${r} - ${a}`;if(r)return e.get("filter.date.since",{values:{date:r}});if(a)return e.get("filter.date.until",{values:{date:a}})},zt=e=>{try{return new Date(e||"").toISOString()}catch{return""}},CA=(()=>{const e=({editAction:t,from:n,to:s,now:r,onChange:a,onValueUpdated:o,showTimezoneInfo:c,selectedPresetOption:d,timeRangePresetOptions:l,timezone:h,sinceDate:u,untilDate:p})=>{const{i18n:f}=H(),{fullDateFormat:T}=Pt(h),[g,y]=F(d),_=A(()=>[new Date(n),new Date(s)],[n,s]),v=q(),N=C((S,D)=>{o(Ap(f,T,zt(S),zt(D)))},[f,T,o]);return G(()=>{var S,D,R;switch(t){case Je.APPLY:a({selectedPresetOption:g,[Vr.FROM]:zt((S=v.current)==null?void 0:S.from),[Vr.TO]:zt((D=v.current)==null?void 0:D.to)});break;case Je.CLEAR:(R=v.current)==null||R.clear(),a()}},[t,a,g]),i(fA,{ref:v,now:r,originDate:_,onHighlight:N,onPresetOptionSelected:y,selectedPresetOption:d,timeRangePresetOptions:l,timezone:h,showTimezoneInfo:c,sinceDate:zt(u),untilDate:zt(p)})};return t=>i(e,{...t})})(),SA=(e,t,n)=>e.formatRange(t,n);function EA({title:e,from:t,to:n,selectedPresetOption:s,...r}){const{i18n:a}=H(),{fullDateFormat:o}=Pt(r.timezone),[c,d]=F(),[l,h]=F(),[u,p]=F(),f=C(_=>{const{from:v,to:N,selectedPresetOption:S}=_??z;try{d(c??S),h(zt(l??v)),p(zt(u??N))}finally{r.onChange({from:v,to:N,selectedPresetOption:S})}},[c,l,u,r]),T=A(()=>a.get("rangePreset.custom"),[a]),g=A(()=>{const _={...RA,timeZone:r.timezone};let v=new Intl.DateTimeFormat(Di,_);try{v=new Intl.DateTimeFormat(a.locale,_)}catch{}return v},[a,r.timezone]);G(()=>d(s),[s]),G(()=>h(zt(t||Date.now())),[t]),G(()=>p(zt(n||Date.now())),[n]);const y=A(()=>s===T&&l&&u?SA(g,new Date(l),new Date(u)):s??r.label,[T,g,l,u,s,r.label]);return i(yp,{...r,from:t,to:n,type:"date",label:y,onChange:f,render:CA,selectedPresetOption:s,value:Ap(a,o,t,n),withContentPadding:!1})}const Qi=({timezone:e,canResetFilters:t,defaultParams:n,filters:s,nowTimestamp:r,refreshNowTimestamp:a,sinceDate:o,untilDate:c,updateFilters:d})=>{const{i18n:l}=H(),h=A(()=>l.get(n.current.defaultTimeRange),[l]),[u,p]=F(h),f=C((T=z)=>{for(const[g,y]of Object.entries(T)){switch(g){case"selectedPresetOption":p(y||h);break;case Vr.FROM:d({[re.CREATED_SINCE]:y||n.current.defaultFilterParams[re.CREATED_SINCE]});break;case Vr.TO:d({[re.CREATED_UNTIL]:y||n.current.defaultFilterParams[re.CREATED_UNTIL]});break;default:return}a()}},[h,a,d]);return A(()=>!t&&p(h),[t,h]),i(EA,{label:l.get("dateRange"),name:re.CREATED_SINCE,sinceDate:o,untilDate:c??new Date(r).toString(),from:s[re.CREATED_SINCE],to:s[re.CREATED_UNTIL],selectedPresetOption:u,timeRangePresetOptions:n.current.timeRangeOptions,timezone:e,onChange:f,showTimezoneInfo:!0,now:r})};function NA(e){return"callback"in e}function Xc(e){const[t,n]=F(null),s=C(o=>{var c;return o&&NA(e[o.selection.type])?{callback:(c=e==null?void 0:e[o.selection.type])!=null&&c.callback?d=>{var l,h;return(h=(l=e[o.selection.type])==null?void 0:l.callback)==null?void 0:h.call(l,{showModal:()=>n(o),...d})}:()=>{var d;return((d=e[o.selection.type])==null?void 0:d.showDetails)&&n(o)}}:(n(o),{})},[e]),r=C(()=>n(null),[]),a=A(()=>{const o={};for(const c in e){const d=e[c];o[c]=!(d!=null&&d.showDetails)||!!d.callback}return o},[e]);return{selectedDetail:t,updateDetails:s,detailsToShow:a,resetDetails:r}}const ai=Ue(({placeholder:e,selection:t,selectionOptions:n,updateSelection:s})=>{const r=Pe(Ie.down.xs),a=Pe(Ie.only.sm),o=Pe(Ie.only.md);return n&&n.length>1?i(Bn,{onChange:s,filterable:!1,multiSelect:!0,placeholder:e,selected:t,withoutCollapseIndicator:!0,items:n,showOverlay:r,fitPosition:o||a}):null}),DA=(e,t)=>{const n=ee(t)?t:fo;return Object.freeze(e.map(s=>({id:s,name:n(s)??s})))},Mr=({filterParam:e,filterValues:t,filters:n,defaultFilters:s,updateFilters:r,mapFilterOptionName:a})=>{const o=A(()=>qn((n==null?void 0:n[e])??(s==null?void 0:s[e])??""),[s,n,e]),c=A(()=>t&&DA(t,a),[t,a]),d=C(({target:l})=>{r==null||r({[e]:(l==null?void 0:l.value)||""})},[r,e]);return{selection:o,selectionOptions:c,updateSelection:d}},bA=[re.CURRENCIES,re.CATEGORIES,re.STATUSES],jo=Object.freeze(Object.fromEntries(bA.map(e=>[e,""]))),OA=["ATM","Capital","Chargeback","Correction","Fee","Payment","Refund","Transfer","Other"],IA=["Booked","Pending","Reversed"],PA=e=>{const t=$y(),n="rangePreset.last30Days",{from:s,to:r}=t[n];return{defaultFilterParams:{...e==="transactions"&&{...jo,[re.MIN_AMOUNT]:void 0,[re.MAX_AMOUNT]:void 0},[re.BALANCE_ACCOUNT]:void 0,[re.CREATED_SINCE]:new Date(s).toISOString(),[re.CREATED_UNTIL]:new Date(r).toISOString()},defaultTimeRange:n,timeRangeOptions:t}},Ji=(e,t)=>{const[n,s]=F(Date.now()),r=PA(e),a=q(r),o=C(()=>s(Date.now()),[s]);return G(()=>{o()},[t,o]),{defaultParams:a,nowTimestamp:n,refreshNowTimestamp:o}},kA="adyen-pe-data-overview-header",wA=({baseClassName:e=kA,children:t,hideTitle:n,titleKey:s,descriptionKey:r})=>{const{i18n:a}=H();return i("header",{className:e,children:[i("div",{className:`${e}__headings`,children:[!n&&s&&i("div",{className:`${e}__title`,children:i(I,{el:J.SPAN,variant:O.TITLE,medium:!0,children:a.get(s)})}),r&&i("p",{className:`${e}__description`,children:i(I,{el:J.SPAN,variant:O.BODY,children:a.get(r)})})]}),t&&i("div",{className:`${e}__controls`,children:t})]})},LA={base:"adyen-pe-modal-content"};function FA({type:e,data:t,dataCustomization:n,...s}){const r=A(()=>{switch(e){case"payout":return{...t,type:e,...s};case"transaction":return{id:t,type:e,...s};default:return{data:t,type:e}}},[t,s,e]);return i(Q,{children:r&&i("div",{className:LA.base,children:i($c,{...r,dataCustomization:n})})})}const vp=({children:e,className:t,selectedDetail:n,resetDetails:s,dataCustomization:r})=>{const{i18n:a}=H(),o=!!n;return G(()=>{o&&bs.closeAll()},[o]),i("div",{className:t,children:[e,n&&i(Ih,{title:n!=null&&n.title?a.get(n.title):void 0,isOpen:!!n,"aria-label":a.get("payoutDetails"),onClose:s,isDismissible:!0,headerWithBorder:!1,size:(n==null?void 0:n.modalSize)??"large",children:n&&i(FA,{dataCustomization:{details:r},...n==null?void 0:n.selection})})]})},Zc=({records:e,hasCustomColumn:t=!1,onDataRetrieve:n,mergeCustomData:s})=>{const[r,a]=F(e),[o,c]=F(!1),d=C(async()=>{try{if(t&&ee(n)){const l=await n(e);if(Array.isArray(l))a(s({records:e,retrievedData:(l==null?void 0:l.filter(Boolean))||[]}));else throw new Error("Retrieved data should be an array")}else a(e)}catch(l){a(e),console.error(l)}finally{c(!1)}},[t,n,s,e]);return G(()=>{e.length&&(c(!0),d())},[d,e]),{customRecords:r,loadingCustomRecords:o}},Qc=(e,t=Se)=>{var n;if(Array.isArray(e))for(const s of e)try{const r=typeof s=="object"?(n=s==null?void 0:s.key)==null?void 0:n.trim():!1;if(typeof r=="string"&&r&&!t.includes(r))return!0}catch{}return!1},Jc=(e,t,n)=>{const s=[];for(let r=0;r<e.length;r++){const a=e[r],o=t.find(c=>n(c,a,r));s[r]={...o??z,...a}}return s},MA=({onFiltersChanged:e,balanceAccounts:t,allowLimitSelection:n=!0,preferredLimit:s=hr,onRecordSelection:r,showDetails:a,isLoadingBalanceAccount:o,onContactSupport:c,hideTitle:d,dataCustomization:l})=>{var We,pe,$e,He;const{getPayouts:h}=Ee().endpoints,{activeBalanceAccount:u,balanceAccountSelectionOptions:p,onBalanceAccountSelection:f}=Yi(t),{defaultParams:T,nowTimestamp:g,refreshNowTimestamp:y}=Ji("payouts",u),_=C(async(De,gt)=>h({signal:gt,errorLevel:"error"},{query:{...De,createdSince:De[re.CREATED_SINCE]??T.current.defaultFilterParams[re.CREATED_SINCE],createdUntil:De[re.CREATED_UNTIL]??T.current.defaultFilterParams[re.CREATED_UNTIL],balanceAccountId:(u==null?void 0:u.id)??""}}),[u==null?void 0:u.id,T,h]),v=Wi(),N=A(()=>ee(e)?e:void 0,[e]),S=A(()=>n?ji:void 0,[n]),{canResetFilters:D,error:R,fetching:b,filters:E,limit:P,limitOptions:w,records:W,resetFilters:x,updateFilters:j,updateLimit:L,...U}=Vi({fetchRecords:_,dataField:"data",filterParams:T.current.defaultFilterParams,initialFiltersSameAsDefault:!0,onFiltersChanged:N,preferredLimit:s,preferredLimitOptions:S,enabled:!!(u!=null&&u.id)&&!!h});G(()=>{y()},[E,y]);const ie=A(()=>({showDetails:a??!0,callback:r}),[a,r]),le=C(({records:De,retrievedData:gt})=>Jc(De,gt,(bn,rn)=>bn.createdAt===rn.createdAt),[]),V=A(()=>{var De;return Qc((De=l==null?void 0:l.list)==null?void 0:De.fields,$i)},[(We=l==null?void 0:l.list)==null?void 0:We.fields]),{customRecords:Z,loadingCustomRecords:ge}=Zc({records:W,hasCustomColumn:V,onDataRetrieve:(pe=l==null?void 0:l.list)==null?void 0:pe.onDataRetrieve,mergeCustomData:le}),Ne=A(()=>({payout:ie}),[ie]),{updateDetails:me,resetDetails:Ce,selectedDetail:ae}=Xc(Ne),ye=C(De=>{me({selection:{type:"payout",data:{id:u==null?void 0:u.id,balanceAccountDescription:(u==null?void 0:u.description)||"",date:De.createdAt}},modalSize:"small"}).callback({balanceAccountId:(u==null?void 0:u.id)||"",date:De.createdAt})},[me,u==null?void 0:u.id,u==null?void 0:u.description]);return i("div",{className:X1,children:[i(wA,{hideTitle:d,titleKey:"payoutsTitle",descriptionKey:"payoutsNotice",children:i(Hi,{...v})}),i(Gi,{...v,children:[i(qi,{activeBalanceAccount:u,balanceAccountSelectionOptions:p,onBalanceAccountSelection:f}),i(Qi,{canResetFilters:D,defaultParams:T,filters:E,nowTimestamp:g,refreshNowTimestamp:y,sinceDate:Q1,timezone:"UTC",updateFilters:j})]}),i(vp,{className:Z1,onContactSupport:c,selectedDetail:ae,resetDetails:Ce,dataCustomization:l==null?void 0:l.details,children:i(V1,{loading:b||o||!t||ge,data:($e=l==null?void 0:l.list)!=null&&$e.onDataRetrieve?Z:W,showPagination:!0,onRowClick:ye,showDetails:a,limit:P,limitOptions:w,onContactSupport:c,onLimitSelection:L,error:R,customColumns:(He=l==null?void 0:l.list)==null?void 0:He.fields,...U})})]})},xA="adyen-pe-payouts-overview-container";function BA({...e}){const{balanceAccounts:t,isBalanceAccountIdWrong:n,isFetching:s,error:r}=No(e.balanceAccountId);return i(Ui,{balanceAccountsError:r,className:xA,errorMessage:"weCouldNotLoadThePayoutsOverview",isBalanceAccountIdWrong:n,onContactSupport:e.onContactSupport,children:i(MA,{...e,balanceAccounts:t,isLoadingBalanceAccount:s})})}class Rp extends Sn{constructor(n){super(n);Y(this,"componentToRender",()=>i(BA,{...this.props,balanceAccountId:this.props.balanceAccountId,ref:n=>void(this.componentRef=n)}));this.componentToRender=this.componentToRender.bind(this)}}Y(Rp,"type","payouts");class Cp extends Sn{constructor(n){super(n);Y(this,"componentToRender",()=>i($c,{...this.props,type:"transaction",ref:n=>void(this.componentRef=n)}));this.componentToRender=this.componentToRender.bind(this)}}Y(Cp,"type","transactionDetails");const $A={base:"adyen-pe-divider"},UA=({className:e})=>i("hr",{className:M($A.base,e)}),WA="adyen-pe-header",Do=({baseClassName:e=WA,children:t,hasDivider:n,hideTitle:s,titleKey:r,subtitleKey:a,subtitleConfig:o})=>{const{i18n:c}=H();return i("header",{className:e,children:[i("div",{className:`${e}__headings`,children:[!s&&r&&i("div",{className:`${e}__title`,children:i(I,{el:J.SPAN,variant:O.TITLE,medium:!0,children:c.get(r)})}),a&&i("div",{className:M(`${e}__subtitle`,o==null?void 0:o.classNames),children:i(I,{el:(o==null?void 0:o.typographyEl)??J.SPAN,variant:(o==null?void 0:o.variant)??O.BODY,children:c.get(a)})}),n&&i(UA,{className:`${e}__divider`})]}),t&&i("div",{className:`${e}__controls`,children:t})]})},HA="adyen-pe-transaction-totals",md="adyen-pe-transaction-totals__item",GA="adyen-pe-base-button";function YA(e,t){const n=A(()=>rs("",e.className)||"",[e.className]),s=A(()=>Ii(e.disabled||!1),[e.disabled]),{click:r,allProps:a}=Pi(n,[...e.classNameModifiers||[],...e.fullWidth?["full-width"]:[]],GA,s,e,e.onClick);return i("button",{type:e.type||"button",onClick:r,ref:t,...a,children:e.children})}const _d=Cn(YA),Sp="adyen-pe-expandable-card",ea=Sp,Fn=ea+"__container",Vo=ea+"__content",gd=ea+"__chevron",Td=Fn+"--button",ma=Fn+"--filled",qA=Fn+"--hidden",jA=Fn+"--in-flow",Ep=Fn+"--overlay",yd=Vo+"--expandable",Ad=`--${Sp}-height`,_a=Ep,el=({renderHeader:e,children:t,filled:n,fullWidth:s,inFlow:r,...a})=>{const{i18n:o}=H(),[c,d]=F(!1),[l,h]=F(0),u=A(()=>r===!0,[r]),p=C(()=>d(v=>!v),[d]),f=q(null),T=q(null),g=q(!1),y=q(c),_=Pc(void 0,C(()=>{c&&(p(),g.current=!0)},[c,p]));return dr(()=>{const v=T.current;v&&(u?v.style.setProperty(Ad,`${l}px`):c||v.style.removeProperty(Ad))},[l,u,c]),G(()=>{if(!u)return void h(0);const v=f.current;if(!v)return;const N=new ResizeObserver(S=>{for(const D of S)D.target===v&&h(v.offsetHeight||0)});return N.observe(v),()=>{N.unobserve(v),N.disconnect()}},[u]),G(()=>{var v,N;c?(v=_.current)==null||v.focus():(y.current!==c&&!g.current&&((N=f.current)==null||N.focus()),g.current=!1),y.current=c},[c,_]),i("div",{ref:T,className:ea,children:t?i(Q,{children:[i(_d,{className:M(Fn,Td,{[ma]:n}),disabled:c,fullWidth:s,"aria-controls":_a,"aria-expanded":c,"aria-hidden":c,onClick:p,ref:f,"data-testid":"expand-button",...a,children:[i("span",{className:"adyen-pe-visually-hidden",children:o.get("expandableCard.expand")}),i("div",{className:M(Vo,yd),children:e}),i("div",{className:gd,children:i(ue,{name:"chevron-down"})})]}),i(_d,{id:_a,className:M(Fn,Td,Ep,{[ma]:n,[qA]:!c,[jA]:u}),disabled:!c,fullWidth:s,"aria-controls":_a,"aria-expanded":c,"aria-hidden":!c,onClick:p,ref:_,"data-testid":"collapse-button",...a,children:[i("span",{className:"adyen-pe-visually-hidden",children:o.get("expandableCard.collapse")}),i("div",{className:M(Vo,yd),children:[e,i("div",{children:t})]}),i("div",{className:gd,children:i(ue,{name:"chevron-up"})})]})]}):i("div",{className:M(Fn,{[ma]:n}),...a,children:i("div",{className:Vo,children:e})})})},tl="adyen-pe-amount-skeleton",VA=tl+"--has-margin",zA=tl+"--loading",KA=({hasMargin:e=!1,isLoading:t=!1,width:n})=>i("span",{className:M(tl,{[zA]:t,[VA]:e}),style:{width:n}}),as="adyen-pe-summary-item",Np=as+"__label-container",XA=Np+"--loading",ZA=as+"--body",Dp=as+"__label",QA=as+"__placeholder",JA=as+"__amount",vd=Cn(({config:e,i18n:t,isSkeletonVisible:n,className:s,...r},a)=>i("span",{className:M(Np,s,{[XA]:n}),style:{cursor:"default"},ref:a,...r,children:e.labelKey&&i(I,{variant:O.CAPTION,className:Dp,children:t.get(e.labelKey)})})),bp=({columnConfigs:e,isHeader:t=!1,isHovered:n=!1,isSkeletonVisible:s=!1,isLoading:r=!1,widths:a,onWidthsSet:o,isEmpty:c})=>{const{i18n:d}=H();G(()=>{const p=e.map(f=>{var T,g;return((g=(T=f.ref)==null?void 0:T.current)==null?void 0:g.getBoundingClientRect().width)??0});o(p)},[o]);const l=p=>({width:a&&a[p]?a[p]:"auto"}),h=Pe(Ie.only.xs),u=C((p,f)=>p.valueHasLabelStyle?O.CAPTION:f&&!h?O.BODY:O.TITLE,[h]);return i("div",{className:M(as,{[ZA]:!t}),children:e.map((p,f)=>{const T=p.getValue(),g=!!T&&T.length>12;return i("div",{children:[t&&(p.tooltipLabel?i(Rn,{content:d.get(`${p.tooltipLabel}`),isContainerHovered:n,children:i(vd,{config:p,i18n:d,isSkeletonVisible:s})}):i(vd,{config:p,i18n:d,isSkeletonVisible:s})),s?i(KA,{isLoading:r,hasMargin:p.hasSkeletonMargin,width:p.skeletonWidth+"px"}):c?i("span",{className:M([as,QA])}):i("div",{ref:p.ref,style:l(f),children:i(I,{variant:u(p,g),className:M({[Dp]:p.valueHasLabelStyle,[JA]:!p.valueHasLabelStyle}),children:T})})]},f)})})},Rd=({total:e,hiddenField:t,isHeader:n=!1,isHovered:s=!1,isSkeleton:r=!1,isLoading:a=!1,widths:o,onWidthsSet:c})=>{const{i18n:d}=H(),l=q(null),h=q(null),u=q(null),p=A(()=>{const f={labelKey:"totalIncoming",ref:l,skeletonWidth:80,getValue:()=>e&&d.amount(e.incomings,e.currency),tooltipLabel:"tooltip.totalIncoming"},T={labelKey:"totalOutgoing",ref:h,skeletonWidth:80,getValue:()=>e&&d.amount(e.expenses,e.currency),tooltipLabel:"tooltip.totalOutgoing"};return[...t!=="incomings"?[f]:[],...t!=="expenses"?[T]:[],{ref:u,skeletonWidth:40,valueHasLabelStyle:!0,getValue:()=>e==null?void 0:e.currency}]},[e,t,d]);return i(bp,{isHovered:s,isEmpty:!e,columnConfigs:p,isHeader:n,isSkeletonVisible:r,isLoading:a,widths:o,onWidthsSet:c})},ev="adyen-pe-base-list",nl=({children:e,classNames:t})=>i("ul",{className:M(ev,[t]),children:e}),Op=()=>{const[e,t]=F([]),n=C(s=>{t(r=>s.every(a=>!a)?s:s.map((a,o)=>{const c=r[o];return!c||a>c?a:c}))},[]);return[e,n]},ga=Ue(({totals:e,isLoading:t,hiddenField:n,fullWidth:s})=>{const[r,a]=Op(),[o,c]=F(!1),[d,...l]=A(()=>e.map(h=>(h.key=`${h.currency}-${Math.random()}`,h)),[e]);return i(el,{renderHeader:i(Rd,{isHovered:o,total:d,hiddenField:n,widths:r,isHeader:!0,isSkeleton:t,isLoading:t,onWidthsSet:a}),fullWidth:s,onMouseEnter:()=>c(!0),onFocus:()=>c(!0),onMouseLeave:()=>c(!1),onBlur:()=>c(!1),children:!t&&l.length&&i(nl,{children:l.map(h=>i("li",{children:i(Rd,{isHovered:o,total:h,hiddenField:n,widths:r,onWidthsSet:a})},h.key))})})}),tv=Ue(({availableCurrencies:e,isAvailableCurrenciesFetching:t,balanceAccountId:n,createdSince:s,createdUntil:r,categories:a,statuses:o,maxAmount:c,minAmount:d,currencies:l,fullWidth:h})=>{const{getTransactionTotals:u}=Ee().endpoints,p=C(async()=>u==null?void 0:u(z,{query:{createdSince:s,createdUntil:r,categories:a,statuses:o,maxAmount:c,minAmount:d,currencies:l,balanceAccountId:n}}),[n,a,s,r,l,u,c,d,o]),{data:f,isFetching:T}=bt({fetchOptions:A(()=>({enabled:!!n&&!!u}),[n,u]),queryFn:p}),g=!n||T||t,_=C(()=>{if(!e||!f)return f==null?void 0:f.data;const N=e.map(S=>f.data.find(R=>R.currency===S)||{currency:S,incomings:0,expenses:0});return N.concat(f.data.filter(S=>!N.includes(S)))},[e,f])()??[],v=Pe(Ie.only.xs);return i("div",{className:HA,children:v?i(Q,{children:[i("div",{className:md,children:i(ga,{totals:_,isLoading:g,hiddenField:"expenses",fullWidth:h})}),i("div",{className:md,children:i(ga,{totals:_,isLoading:g,hiddenField:"incomings",fullWidth:h})})]}):i(ga,{totals:_,isLoading:g,fullWidth:h})})}),nv="adyen-pe-balances",Cd=({balance:e,isHeader:t=!1,isSkeleton:n=!1,isLoading:s=!1,widths:r,onWidthsSet:a,isEmpty:o})=>{const{i18n:c}=H(),d=q(null),l=q(null),h=A(()=>[{labelKey:"accountBalance",ref:d,skeletonWidth:80,getValue:()=>e&&c.amount(e.value,e.currency)},{ref:l,skeletonWidth:40,valueHasLabelStyle:!0,getValue:()=>e==null?void 0:e.currency}],[e,d,c]);return i(bp,{isEmpty:o,columnConfigs:h,isHeader:t,isSkeletonVisible:n,isLoading:s,widths:r,onWidthsSet:a})},sv=Ue(({balanceAccountId:e,defaultCurrencyCode:t,onCurrenciesChange:n,fullWidth:s})=>{const{getBalances:r}=Ee().endpoints,a=C(async()=>r==null?void 0:r(z,{path:{balanceAccountId:e}}),[e,r]),{data:o,error:c,isFetching:d}=bt({fetchOptions:A(()=>({enabled:!!e&&!!r}),[e,r]),queryFn:a}),l=!e||d,h=!!c||!(o!=null&&o.data.length),u=A(()=>(o==null?void 0:o.data)&&[...o.data].sort(({currency:y},{currency:_})=>{if(t){if(y===t)return-1;if(_===t)return 1}return y.localeCompare(_)}),[o==null?void 0:o.data,t]),[p,...f]=A(()=>(u==null?void 0:u.map(y=>(y.key=`${y.currency}-${Math.random()}`,y)))??[],[u]),[T,g]=Op();return G(()=>{const y=new Set((u==null?void 0:u.map(({currency:_})=>_))||[]);n(Array.from(y),d)},[u,d,n]),i("div",{className:nv,children:i(el,{renderHeader:i(Cd,{isEmpty:h,balance:p,widths:T,isHeader:!0,isSkeleton:l,isLoading:l,onWidthsSet:g}),filled:!0,fullWidth:s,children:f.length&&i(nl,{children:f.map(y=>i("li",{children:i(Cd,{balance:y,widths:T,onWidthsSet:g})},y.key))})})})}),rv=(e,t)=>{const n=Mr({filterParam:re.CATEGORIES,filterValues:OA,defaultFilters:jo,...e}),s=Mr({filterParam:re.STATUSES,filterValues:IA,defaultFilters:jo,...e}),r=Mr({filterParam:re.CURRENCIES,filterValues:t,defaultFilters:jo,...e});return{categoriesFilter:n,currenciesFilter:r,statusesFilter:s}},ci=1e5,ov=({onChange:e,editAction:t,onValueUpdated:n,selectedCurrencies:s,availableCurrencies:r,value:a,...o})=>{const{i18n:c}=H(),[d,l]=F(oe(o.minAmount)?void 0:parseFloat(o.minAmount)/ci),[h,u]=F(oe(o.maxAmount)?void 0:parseFloat(o.maxAmount)/ci),p=C(()=>{e({minAmount:d,maxAmount:h})},[h,d,e]),f=C(()=>{e({minAmount:void 0,maxAmount:void 0}),u(void 0),l(void 0)},[e]);G(()=>{t===Je.APPLY&&p(),t===Je.CLEAR&&f()},[p,f,t]);const T=A(()=>({minAmount:Number(d),maxAmount:Number(h)}),[h,d]);return G(()=>{const{maxAmount:g,minAmount:y}=T;oe(g)&&oe(y)||y>g?n(null):n(`${y}-${g}`)},[T,n]),i("div",{className:"adyen-pe-range-selection-filter",children:[i("div",{className:"adyen-pe-range-selection-filter__input",children:[i("label",{htmlFor:"minValue",children:`${c.get("from")}:`}),i(ri,{"data-testid":"minValueFilter",lang:c.locale,name:"minValue",type:"number",value:d,onInput:g=>{g.currentTarget&&l(g.currentTarget.value!==""?g.currentTarget.value:void 0)},min:0,isInvalid:d?d<0:!1,errorMessage:c.get("noNegativeNumbersAllowed")})]}),i("div",{className:"adyen-pe-range-selection-filter__input",children:[i("label",{htmlFor:"maxValue",children:`${c.get("to")}:`}),i(ri,{"data-testid":"maxValueFilter",lang:c.locale,name:"maxValue",type:"number",value:h,onInput:g=>{g.currentTarget&&u(g.currentTarget.value!==""?g.currentTarget.value:void 0)},min:d,isInvalid:!oe(h)&&!oe(d)&&h<d,errorMessage:c.get("toValueShouldBeGreaterThanTheFromValue")})]})]})},iv=({updateFilters:e,selectedCurrencies:t,availableCurrencies:n,...s})=>{const{i18n:r}=H(),[a,o]=F(),[c,d]=F(),l=A(()=>(t==null?void 0:t.length)===1||(n==null?void 0:n.length)===1,[n==null?void 0:n.length,t==null?void 0:t.length]),h=C((p,f)=>{const T=(t==null?void 0:t[0])||(n==null?void 0:n[0]),g=f&&T?{style:"currency",currency:T,currencyDisplay:"symbol"}:void 0;return p.toLocaleString(r.locale,g)},[n,r,t]),u=C(p=>{const{minAmount:f,maxAmount:T}=p??z;o({minAmount:f,maxAmount:T}),oe(f)&&oe(T)&&d(void 0),e({minAmount:oe(f)?void 0:String(Math.round(f*ci)),maxAmount:oe(T)?void 0:String(Math.round(T*ci))})},[e]);if(a&&(a.minAmount||a.maxAmount)){const{minAmount:p,maxAmount:f}=a??{};!oe(p)&&!oe(f)&&p<=f?d(`${h(p,l)} ${r.get("to").toLowerCase()} ${h(f,l)}`):!oe(p)&&oe(f)&&p>=0?d(`${r.get("from")} ${h(p,l)}`):oe(p)&&!oe(f)?d(`${r.get("to")} ${h(f,l)}`):d(void 0)}return i(yp,{...s,updateFilters:e,minAmount:s.minAmount,maxAmount:s.maxAmount,onChange:u,value:c,label:c||s.label,type:"text",containerSize:Hr.MEDIUM,selectedCurrencies:t,availableCurrencies:n,render:ov})},Ip="adyen-pe-transactions",Pp=`${Ip}-overview`,av=`${Ip}-details`,kp=`${Pp}__summary`,Sd=`${kp}-item`,cv=24,lv=({onFiltersChanged:e,balanceAccounts:t,allowLimitSelection:n=!0,preferredLimit:s=hr,onRecordSelection:r,showDetails:a,isLoadingBalanceAccount:o,onContactSupport:c,hideTitle:d,dataCustomization:l})=>{var on,$n,_s,Un;const{i18n:h}=H(),{getTransactions:u}=Ee().endpoints,{activeBalanceAccount:p,balanceAccountSelectionOptions:f,onBalanceAccountSelection:T}=Yi(t),{defaultParams:g,nowTimestamp:y,refreshNowTimestamp:_}=Ji("transactions",p),v=C(async({balanceAccount:Re,...Fe},Wt)=>u({signal:Wt,errorLevel:"error"},{query:{...Fe,statuses:qn(Fe[re.STATUSES]),categories:qn(Fe[re.CATEGORIES]),currencies:qn(Fe[re.CURRENCIES]),createdSince:Fe[re.CREATED_SINCE]??g.current.defaultFilterParams[re.CREATED_SINCE],createdUntil:Fe[re.CREATED_UNTIL]??g.current.defaultFilterParams[re.CREATED_UNTIL],sortDirection:"desc",balanceAccountId:(p==null?void 0:p.id)??"",minAmount:oe(Fe.minAmount)?void 0:parseFloat(Fe.minAmount),maxAmount:oe(Fe.maxAmount)?void 0:parseFloat(Fe.maxAmount)}}),[p==null?void 0:p.id,g,u]),N=Wi(),S=A(()=>ee(e)?e:void 0,[e]),D=A(()=>n?ji:void 0,[n]),{canResetFilters:R,error:b,fetching:E,filters:P,limit:w,limitOptions:W,records:x,resetFilters:j,updateFilters:L,updateLimit:U,...ie}=Vi({fetchRecords:v,dataField:"data",filterParams:g.current.defaultFilterParams,initialFiltersSameAsDefault:!0,onFiltersChanged:S,preferredLimit:s,preferredLimitOptions:D,enabled:!!(p!=null&&p.id)&&!!u}),[le,V]=F([]),[Z,ge]=F(!1),Ne=C((Re,Fe)=>{V(Re),ge(Fe)},[]),{categoriesFilter:me,currenciesFilter:Ce,statusesFilter:ae}=rv({filters:P,updateFilters:L},le);G(()=>{V(void 0),L({[re.BALANCE_ACCOUNT]:p==null?void 0:p.id,[re.CURRENCIES]:void 0})},[L,p==null?void 0:p.id]),G(()=>{_()},[P,_]),G(()=>{ae.updateSelection({target:{value:"Booked",name:"status"}})},[ae]);const ye=Pe(Ie.down.sm),We=!!le&&le.length>1,pe=A(()=>({showDetails:a??!0,callback:r}),[a,r]),$e=A(()=>({transaction:pe}),[pe]),He=C(({records:Re,retrievedData:Fe})=>Jc(Re,Fe,(Wt,oa)=>Wt.id===oa.id),[]),De=A(()=>{var Re;return Qc((Re=l==null?void 0:l.list)==null?void 0:Re.fields,Mc)},[(on=l==null?void 0:l.list)==null?void 0:on.fields]),{customRecords:gt,loadingCustomRecords:bn}=Zc({records:x,hasCustomColumn:De,onDataRetrieve:($n=l==null?void 0:l.list)==null?void 0:$n.onDataRetrieve,mergeCustomData:He}),{updateDetails:rn,resetDetails:Tr,selectedDetail:Te}=Xc($e),we=C(({id:Re})=>{rn({selection:{type:"transaction",data:Re,balanceAccount:p||""},modalSize:"small"}).callback({id:Re})},[p,rn]),Le=A(()=>{const Re=new Date(y);return Re.setMonth(Re.getMonth()-cv),Re.toString()},[y]);return i("div",{className:Pp,children:[i(Do,{hideTitle:d,titleKey:"transactionsOverviewTitle",children:i(Hi,{...N})}),i(Gi,{...N,children:[i(qi,{activeBalanceAccount:p,balanceAccountSelectionOptions:f,onBalanceAccountSelection:T}),i(Qi,{canResetFilters:R,defaultParams:g,filters:P,nowTimestamp:y,refreshNowTimestamp:_,sinceDate:Le,timezone:p==null?void 0:p.timeZone,updateFilters:L}),i(ai,{...me,placeholder:h.get("filterPlaceholder.category")}),i(iv,{availableCurrencies:le,selectedCurrencies:qn(P[re.CURRENCIES]),name:"range",label:h.get("amount"),minAmount:P[re.MIN_AMOUNT],maxAmount:P[re.MAX_AMOUNT],updateFilters:L,onChange:L}),i(ai,{...Ce,placeholder:h.get("filterPlaceholder.currency")})]}),i("div",{className:kp,children:[i("div",{className:Sd,children:i(tv,{availableCurrencies:le,isAvailableCurrenciesFetching:Z,balanceAccountId:p==null?void 0:p.id,statuses:ae.selection,categories:me.selection,createdUntil:P[re.CREATED_UNTIL],createdSince:P[re.CREATED_SINCE],currencies:Ce.selection,minAmount:P[re.MIN_AMOUNT]?parseFloat(P[re.MIN_AMOUNT]):void 0,maxAmount:P[re.MAX_AMOUNT]?parseFloat(P[re.MAX_AMOUNT]):void 0,fullWidth:ye})}),i("div",{className:Sd,children:i(sv,{balanceAccountId:p==null?void 0:p.id,onCurrenciesChange:Ne,defaultCurrencyCode:p==null?void 0:p.defaultCurrencyCode,fullWidth:ye})})]}),i(vp,{dataCustomization:l==null?void 0:l.details,selectedDetail:Te,resetDetails:Tr,className:av,children:i(h1,{activeBalanceAccount:p,availableCurrencies:le,error:b,hasMultipleCurrencies:We,limit:w,limitOptions:W,loading:E||o||!t||bn,onContactSupport:c,onLimitSelection:U,onRowClick:we,showPagination:!0,transactions:(_s=l==null?void 0:l.list)!=null&&_s.onDataRetrieve?gt:x,customColumns:(Un=l==null?void 0:l.list)==null?void 0:Un.fields,...ie})})]})},dv="adyen-pe-transactions-overview-container";function uv({...e}){const{balanceAccounts:t,isBalanceAccountIdWrong:n,isFetching:s,error:r}=No(e.balanceAccountId);return i(Ui,{balanceAccountsError:r,className:dv,errorMessage:"weCouldNotLoadTheTransactionsOverview",isBalanceAccountIdWrong:n,onContactSupport:e.onContactSupport,children:i(lv,{...e,balanceAccounts:t,isLoadingBalanceAccount:s})})}class wp extends Sn{constructor(n){super(n);Y(this,"componentToRender",()=>i(uv,{...this.props,balanceAccountId:this.props.balanceAccountId,ref:n=>void(this.componentRef=n)}));this.componentToRender=this.componentToRender.bind(this)}}Y(wp,"type","transactions");var zn=(e=>(e.AU="AU",e.EU="EU",e.GB="GB",e.US="US",e.CA="CA",e))(zn||{});const hv=["AU","GB","US","CA"],pv=["EU"],Lp=e=>{var n;const t=(n=e==null?void 0:e.regions)==null?void 0:n.find(s=>s.type==="capital");return(t==null?void 0:t.value)??""},fv=e=>{switch(e){case zn.EU:return"capital.legalSubtitleEU";default:return null}},mv=e=>{switch(e){case zn.AU:return"capital.legalSubtitleAU";case zn.GB:return"capital.legalSubtitleGB";case zn.US:return"capital.legalSubtitleUS";case zn.CA:return"capital.legalSubtitleCA";default:return null}},_v=e=>{const t=Lp(e),n=e==null?void 0:e.countryCode;return mv(n)??fv(t)},sl=e=>{const t=Lp(e),n=(e==null?void 0:e.countryCode)??"";return hv.includes(n)||pv.includes(t)},cn={contactSupportForHelp:"contactSupportForHelp",couldNotLoadOffers:"capital.weCouldNotLoadFinancialOffers",tryRefreshingThePage:"tryRefreshingThePageOrComeBackLater",somethingWentWrong:"somethingWentWrong"},Ta={title:cn.somethingWentWrong,message:[cn.couldNotLoadOffers,cn.tryRefreshingThePage],refreshComponent:!0},Fp=(e,t)=>{if(!e)return Ta;const n=ph(e,t);if(n)return n;const s=t?"theErrorCodeIs":"contactSupportForHelpAndShareErrorCode";switch(e.errorCode){case void 0:return{...Ta,...t?{onContactSupport:t}:{}};case"30_016":return{title:cn.somethingWentWrong,message:[cn.couldNotLoadOffers,s],translationValues:{[s]:e.requestId?i($t,{textToCopy:e.requestId}):null},onContactSupport:t};case"30_011":return{title:"capital.accountIsInactive",message:[cn.couldNotLoadOffers,s],translationValues:{[s]:e.requestId?i($t,{textToCopy:e.requestId}):null},onContactSupport:t};case"30_600":return{title:cn.somethingWentWrong,message:["capital.weCouldNotContinueWithTheOffer",s],translationValues:{[s]:e.requestId?i($t,{textToCopy:e.requestId}):null},onContactSupport:t};case"EMPTY_CONFIG":return{title:cn.somethingWentWrong,message:["capital.weCouldNotContinueWithTheOffer",cn.contactSupportForHelp]};case"UNSUPPORTED_REGION":return{title:"capital.unsupportedRegionTitle",message:"capital.unsupportedRegionDescription"};default:return{...Ta,refreshComponent:!0}}},ta=({emptyGrantOffer:e,error:t,onContactSupport:n,onBack:s,unsupportedRegion:r})=>{const{i18n:a}=H(),o=C(()=>i(Q,{children:s&&i(_e,{variant:te.SECONDARY,onClick:s,children:a.get("back")})}),[a,s]),c=A(()=>r?new ba(Ur.ERROR,"UnsupportedRegion","Unsupported Region Configuration","UNSUPPORTED_REGION"):e?new ba(Ur.ERROR,"EmptyConfig","Empty Configuration","EMPTY_CONFIG"):t,[e,r,t]);return i(Qt,{absolutePosition:!1,withImage:!0,onContactSupport:n,renderSecondaryButton:o,outlined:!1,...Fp(c,n)})},Ed={base:"adyen-pe-capital-offer",errorContainer:"adyen-pe-capital-offer__error-container"},cs=e=>{var s;const t=(s=Ee().extraConfig)==null?void 0:s.legalEntity,n=A(()=>{const r=_v(t);return r?{subtitleKey:r}:{}},[t]);return i(Do,{...e,...n,subtitleConfig:{variant:O.CAPTION,classNames:"adyen-pe-capital-header__subtitle"}})},na=({className:e,el:t="div",children:n})=>i(t,{className:M("adyen-pe-info-box",e),children:n}),gv=(e,t=0)=>new Date(new Date(e).setUTCHours(0,0,0,0)+Math.floor(t)*jr),Mp=e=>oc(gv(new Date,e)),Tv=e=>e?Math.ceil(e/30):null,yv=(e,t)=>{let n,s;function r(...a){clearTimeout(n),s=a,n=setTimeout(()=>{e(s),s=void 0},t)}return r.cancel=()=>{n&&(clearTimeout(n),n=void 0,s=void 0)},r},li=e=>e/100;function Av(e,t,n,s){if(t>=n)return 0;const r=s>0?s:1;if(r>n-t)return 0;const o=(Math.round((e-t)/r)*r+t-t)*100/(n-t);return Number(Et(0,o,100).toFixed(2))}function vv(e,t,n){const s=t/2;let r=Math.round(s/n)*n;return r<e?r=e:r>t&&(r=t),r}const Rv=({min:e=0,max:t=100,step:n=1,value:s=e,onChange:r,className:a,...o})=>{const c=A(()=>Av(s,e,t,n),[s,e,t,n]);return i("input",{type:"range",className:M("adyen-pe-slider",a),min:e,max:t,step:n,value:s,onChange:r,style:{backgroundSize:`${c}% 100%`},...o})},Cv=({dynamicOffersConfig:e,value:t=e.minAmount.value,onValueChange:n,onRelease:s,className:r})=>{const a=vn(),{i18n:o}=H(),c=l=>{const h=Number(l.target.value);n==null||n(h)},d=l=>{const h=Number(l.target.value);s==null||s(h)};return i("div",{className:M("adyen-pe-capital-slider",r),children:[i("label",{htmlFor:a,className:"adyen-pe-capital-slider__label",children:i(I,{variant:O.BODY,stronger:!0,children:o.get("capital.howMuchMoneyDoYouNeed")})}),i("div",{children:[i("output",{htmlFor:a,className:"adyen-pe-capital-slider__value","aria-live":"polite",children:i(I,{variant:O.TITLE,strongest:!0,children:o.amount(t,e.minAmount.currency,{maximumFractionDigits:0})})}),i(Rv,{id:a,value:t,min:e.minAmount.value,max:e.maxAmount.value,step:e.step,onChange:c,onMouseUp:d,onTouchEnd:d,onKeyUp:d,className:"adyen-pe-capital-slider__input"})]}),i("div",{className:"adyen-pe-capital-slider__labels",children:[i("label",{children:[i(I,{variant:O.CAPTION,children:o.get("min")}),i(I,{variant:O.BODY,children:o.amount(e.minAmount.value,e.minAmount.currency,{maximumFractionDigits:0})})]}),i("label",{children:[i(I,{variant:O.CAPTION,children:o.get("max")}),i(I,{variant:O.BODY,children:o.amount(e.maxAmount.value,e.maxAmount.currency,{maximumFractionDigits:0})})]})]})]})},di=30,Sv=()=>i("div",{className:"adyen-pe-capital-offer-selection__loading-container",children:[...Array(4)].map((e,t)=>i("div",{className:"adyen-pe-capital-offer-selection__loading-skeleton"},t))}),Ev=({data:e})=>{const{i18n:t}=H(),n=A(()=>{const s=e.expectedRepaymentPeriodDays&&Mp(e.expectedRepaymentPeriodDays);return s?t.date(s,{month:"long"}):null},[e,t]);return i("div",{className:"adyen-pe-capital-offer-selection__information",children:[i(I,{el:J.SPAN,variant:O.BODY,wide:!0,children:n&&t.get("capital.youWillNeedToRepayAMinimumOfXEveryXDaysToPayOffTheFunds",{values:{amount:t.amount(e.thresholdAmount.value,e.thresholdAmount.currency),days:di,date:n}})}),i(gn,{renderValue:s=>i(I,{el:J.SPAN,stronger:!0,variant:O.CAPTION,children:s}),renderLabel:s=>i(I,{el:J.SPAN,variant:O.CAPTION,children:s}),items:[{key:"capital.fees",value:t.amount(e.feesAmount.value,e.feesAmount.currency)},{key:"capital.dailyRepaymentRate",value:`${t.get("capital.xPercent",{values:{percentage:li(e.repaymentRate)}})}`},{key:"capital.expectedRepaymentPeriod",value:t.get("capital.xDays",{values:{days:e.expectedRepaymentPeriodDays}})}]})]})},Nv=({dynamicOffersConfig:e,dynamicOffersConfigError:t,emptyGrantOffer:n,onContactSupport:s,onOfferDismiss:r,onOfferSelect:a,requestedAmount:o})=>{const{i18n:c}=H(),d=A(()=>{if(e)return vv(e.minAmount.value,e.maxAmount.value,e.step)},[e]),[l,h]=F(void 0),u=A(()=>e==null?void 0:e.minAmount.currency,[e==null?void 0:e.minAmount.currency]),{createGrantOffer:p,getDynamicGrantOffer:f}=Ee().endpoints,T=is({queryFn:f,options:{retry:1,shouldRetry:C(E=>E.status===500,[]),onSettled:C(()=>{N(!1)},[])}}),g=is({queryFn:p,options:{onSuccess:E=>a(E)}}),y=C(()=>{var E,P;g.mutate({body:{amount:((E=T.data)==null?void 0:E.grantAmount.value)||l,currency:((P=T.data)==null?void 0:P.grantAmount.currency)||u},contentType:"application/json"})},[u,T.data,l,g]),_=C(E=>T.mutate({},{query:{amount:E,currency:u}}),[u,T]),[v,N]=F(!1),S=yv(_,300),D=C(E=>{S.cancel(),N(!0),h(E)},[S]),R=E=>S(E);G(()=>{e&&!T.data&&!l&&(h(E=>E||(o?Number(o):d||e.minAmount.value)),_(l||d||e.minAmount.value))},[e,T.data,_,d,o,l]);const b=A(()=>g.isLoading||T.isLoading||v,[T.isLoading,v,g.isLoading]);return i("div",{className:"adyen-pe-capital-offer-selection",children:g.error||T.error||n||t?i(ta,{error:g.error||T.error||t,onBack:r,onContactSupport:s,emptyGrantOffer:n}):i(Q,{children:[e&&i(Cv,{value:l,dynamicOffersConfig:e,onValueChange:D,onRelease:R}),i(na,{className:"adyen-pe-capital-offer-selection__details",children:!T.data||T.isLoading||v?i(Sv,{}):T.data?i(Ev,{data:T.data}):null}),i("div",{className:"adyen-pe-capital-offer-selection__buttons",children:[r&&i(_e,{variant:te.SECONDARY,onClick:r,children:c.get("back")}),i(_e,{variant:te.PRIMARY,state:b?"loading":void 0,onClick:y,disabled:g.isLoading||!(e!=null&&e.minAmount),children:c.get(b?"loading":"capital.reviewOffer")})]})]})})},Dv=(e,t)=>{const{variant:n=te.PRIMARY,disabled:s=!1,onClick:r,classNameModifiers:a=[],className:o}=e,c=A(()=>rs("",o)||"",[o]),d=A(()=>Ii(s),[s]),{click:l,allChildren:h,allProps:u}=Pi(c,[...a,n],`${mt} ${f_}`,d,e,r),p=A(()=>({...u,...e.onClick&&l?{onClick:l}:{}}),[l,u,e.onClick]);return i("a",{...p,href:e.href,ref:t,children:h})},bv=Cn(Dv),Nd=e=>ee(e)?e:()=>e,pr=({count:e,defaultFill:t,fills:n,translationKey:s})=>{const{i18n:r}=H(),a=A(()=>{const o=Nd(t);return n!==void 0?(...c)=>{const[d,l]=c;for(const h of[d,l]){const u=Nd(n[h])(...c);if(u!=null)return u}return o(...c)}:o},[n,t]);return A(()=>{const o=[],c=vn("translation"),d=(...u)=>(o.push(a(...u)??null),c),[l,...h]=r.get(s,{count:e,values:d}).split(c);return i(Q,{children:[l,h.map((u,p)=>i(Q,{children:[o[p],u]},`${c}__${p}`))]})},[r,e,a,s])},Dd="capital-support@adyen.com",Ov=()=>{var t,n,s;return((s=(n=(t=Ee())==null?void 0:t.extraConfig)==null?void 0:n.legalEntity)==null?void 0:s.countryCode)===zn.US?i(kr,{filled:!0,noOutline:!0,children:[i(I,{variant:O.CAPTION,className:"adyen-pe-capital-offer-legal-notice--title",children:i(pr,{translationKey:"capital.offerLegalNoticeTitleUS",fills:{break:i("br",{})}})}),i("br",{}),i(I,{variant:O.CAPTION,className:"adyen-pe-capital-offer-legal-notice--description",children:i(pr,{translationKey:"capital.offerLegalNoticeDescriptionUS",fills:{email:i(bv,{href:`mailto:${Dd}`,variant:te.TERTIARY,className:"adyen-pe-capital-offer-summary__info--email",children:Dd}),break:i(Q,{children:[i("br",{}),i("br",{})]})}})})]}):null},Iv=["30_013"],Pv=({grantOffer:e,onBack:t,onFundsRequest:n,onContactSupport:s})=>{const{i18n:r}=H(),a=A(()=>{const f=Mp(e.expectedRepaymentPeriodDays);return f?r.date(f,{month:"long"}):null},[e,r]),{requestFunds:o}=Ee().endpoints,c=is({queryFn:o,options:{onSuccess:f=>n==null?void 0:n(f)}}),d=C(f=>{c.mutate(z,{path:{grantOfferId:f}})},[c]),l=C(()=>{e.id&&d(e.id)},[e.id,d]),h=A(()=>Tv(e.maximumRepaymentPeriodDays),[e.maximumRepaymentPeriodDays]),u=A(()=>{const f=c.error?c.error:null;if(f&&Iv.includes(f.errorCode))switch(f.errorCode){case"30_013":return{title:r.get("capital.thereIsNoPrimaryAccountConfigured"),message:r.get("capital.weCouldNotContinueWithTheOfferContactSupportForHelp"),errorCode:"30_013"};default:return{title:r.get("somethingWentWrong"),message:r.get("capital.weCouldNotLoadFinancialOffers")}}return null},[r,c.error]),p=A(()=>{const f=[{key:"capital.fees",value:r.amount(e.feesAmount.value,e.feesAmount.currency)},{key:"capital.totalRepaymentAmount",value:r.amount(e.totalAmount.value,e.totalAmount.currency)},{key:"capital.repaymentThreshold",value:r.amount(e.thresholdAmount.value,e.thresholdAmount.currency)},{key:"capital.dailyRepaymentRate",value:r.get("capital.xPercent",{values:{percentage:li(e.repaymentRate)}})},{key:"capital.expectedRepaymentPeriod",value:r.get("capital.xDays",{values:{days:e.expectedRepaymentPeriodDays}})},{key:"account",value:r.get("capital.primaryAccount")}];return h&&f.splice(4,0,{key:"capital.maximumRepaymentPeriod",value:h===1?r.get("capital.oneMonth"):r.get("capital.xMonths",{values:{months:h}})}),e.aprBasisPoints&&f.splice(1,0,{key:"capital.annualPercentageRate",value:r.get("capital.xPercent",{values:{percentage:li(e.aprBasisPoints)}})}),f},[e,r,h]);return!u&&c.error?i(ta,{error:c.error,onBack:t,onContactSupport:s}):i("div",{className:"adyen-pe-capital-offer-summary",children:[i(na,{className:"adyen-pe-capital-offer-summary__grant-summary",children:[i(I,{el:J.PARAGRAPH,variant:O.BODY,children:[r.get("capital.youAreRequestingFundingOf")," ",i("strong",{children:`${r.amount(e.grantAmount.value,e.grantAmount.currency,{minimumFractionDigits:0})}.`})]}),i(I,{el:J.PARAGRAPH,variant:O.CAPTION,children:r.get("capital.youWillNeedToRepayAMinimumOfXEveryXDaysToPayOffTheFunds",{values:{amount:r.amount(e.thresholdAmount.value,e.thresholdAmount.currency),days:di,date:a??""}})})]}),i(gn,{classNames:"adyen-pe-capital-offer-summary__details",renderLabel:(f,T)=>T==="capital.repaymentThreshold"?i(Rn,{isContainerHovered:!0,content:r.get("capital.minimumRepaymentToRepayTheFinancingOnTime",{values:{days:di}}),children:i("span",{children:i(I,{className:"adyen-pe-capital-offer-summary__list-label",el:J.SPAN,variant:O.CAPTION,children:f})})}):T==="capital.annualPercentageRate"?i(Rn,{isContainerHovered:!0,content:r.get("capital.annualPercentageRateIsTheCostOfBorrowingForALoan"),children:i("span",{children:i(I,{className:"adyen-pe-capital-offer-summary__list-label",el:J.SPAN,variant:O.CAPTION,children:f})})}):i(I,{className:"adyen-pe-capital-offer-summary__list-label",el:J.SPAN,variant:O.CAPTION,children:f}),renderValue:(f,T)=>{const g=T==="account"&&c.error&&u&&u.errorCode==="30_013";return i(I,{className:M({"adyen-pe-capital-offer-summary__details--error":g}),el:J.SPAN,variant:O.CAPTION,stronger:!0,children:[g?i(ue,{name:"warning-filled","data-testid":"primary-account-warning-icon"}):null,f]})},items:p}),u&&i(et,{className:"adyen-pe-capital-offer-summary__error-alert",type:be.WARNING,title:u.title,description:u.message,children:s?i(_e,{className:"adyen-pe-capital-offer-summary__error-alert-button",onClick:s,children:r.get("contactSupport")}):null}),i(Ov,{}),i("div",{className:"adyen-pe-capital-offer-summary__buttons",children:[c.error&&!u?null:i(_e,{variant:te.SECONDARY,onClick:t,children:r.get("back")}),i(_e,{variant:te.PRIMARY,state:c.isLoading?"loading":void 0,onClick:l,disabled:c.isLoading||!!c.error||!!c.data,children:r.get(c.isLoading?"capital.requesting":"capital.requestFunds")})]})]})},rl=({externalDynamicOffersConfig:e,hideTitle:t,onContactSupport:n,onFundsRequest:s,onOfferDismiss:r,onOfferSelect:a})=>{var D,R;const{getDynamicGrantOffersConfiguration:o}=Ee().endpoints,c=(R=(D=Ee())==null?void 0:D.extraConfig)==null?void 0:R.legalEntity,d=A(()=>sl(c),[c]),[l,h]=F(!1),u=C(b=>{h(!b)},[]),{data:p,error:f}=bt({fetchOptions:{enabled:!e&&!!o&&d,onSuccess:u},queryFn:C(async()=>o==null?void 0:o(z),[o])}),T=e||p,[g,y]=F(),[_,v]=F(),N=C(b=>{a?a(b):(v(b==null?void 0:b.grantAmount.value),y(b))},[a]),S=A(()=>g?"OfferSummary":"OfferSelection",[g]);return d?i("div",{className:Ed.base,children:[i(cs,{hasDivider:!0,hideTitle:t,titleKey:S==="OfferSummary"?"capital.businessFinancingSummary":"capital.businessFinancingOffer"}),S==="OfferSelection"&&i(Nv,{requestedAmount:_,dynamicOffersConfig:T,dynamicOffersConfigError:f,onOfferDismiss:r,onOfferSelect:N,emptyGrantOffer:l,onContactSupport:n}),S==="OfferSummary"&&i(Pv,{grantOffer:g,onBack:()=>y(void 0),onFundsRequest:s,onContactSupport:n})]}):i("div",{className:Ed.errorContainer,children:[i(cs,{hideTitle:t,titleKey:"capital.businessFinancing"}),i(ta,{unsupportedRegion:!0})]})};class xp extends Sn{constructor(n){super(n);Y(this,"componentToRender",()=>i(rl,{...this.props}));this.componentToRender=this.componentToRender.bind(this),this.customClassNames="adyen-pe-capital-offer-component"}}Y(xp,"type","capitalOffer");const kv=(e=1e3,t=!1)=>{const[n,s]=F(t),r=q(),a=q(),o=C(()=>{n||(a.current=setTimeout(()=>{r.current=requestAnimationFrame(()=>s(!1))},e),s(!0))},[n,e]);return G(()=>()=>{cancelAnimationFrame(r.current),clearTimeout(a.current),r.current=a.current=null},[e]),{freeze:o,frozen:n}},wv=(e,t,n)=>{const s=Ee().endpoints[e];return bt({fetchOptions:{enabled:!!s&&n,keepPrevData:!0},queryFn:async()=>s(z,{...t})})};function Lv({blob:e,filename:t}){const n=document.createElement("a"),s=URL.createObjectURL(e);n.href=s,n.download=t||"download";const r=()=>{setTimeout(()=>{URL.revokeObjectURL(s)},150)};n.addEventListener("click",r,{once:!0}),n.click()}function Bp({className:e,disabled:t,endpointName:n,requestParams:s,setError:r,errorDisplay:a,onDownloadRequested:o,iconButton:c=!1,errorMessage:d}){const{i18n:l}=H(),[h,u]=F(!1),p=Pe(Ie.down.xs),{data:f,error:T,isFetching:g}=wv(n,s,h);G(()=>{h&&u(!1)},[h]),G(()=>{f&&Lv(f)},[f]),G(()=>{r&&T&&r(T)},[T,r]);const y=()=>{u(!0),o==null||o()},_=A(()=>g?i(qu,{size:"small"}):i(ue,{name:"download"}),[g]),v=A(()=>c?_:g?`${l.get("downloading")}..`:l.get("download"),[_,l,g,c]);return i(Q,{children:[i("div",{className:M("adyen-pe-download",{"adyen-pe-download-icon-button-container":c}),children:[p?i(_e,{iconButton:!0,variant:te.TERTIARY,onClick:y,children:_}):i(_e,{className:M("adyen-pe-download__button",{"adyen-pe-download__button--loading":g,"adyen-pe-download__button--icon":c},e),disabled:t||g,variant:c?te.TERTIARY:te.SECONDARY,onClick:y,...!c&&{iconLeft:_},children:v}),T&&a&&i("div",{className:"adyen-pe-download__error",children:a})]}),T&&d&&d(T)]})}const Fv=1e3,$p="adyen-pe-reports-table",Up=`${$p}-date-report-type`,Mv=`${Up}--date`,Wp=["createdAt","dateAndReportType","reportType","reportFile"],xv=({error:e,loading:t,balanceAccountId:n,onContactSupport:s,showPagination:r,data:a,customColumns:o,...c})=>{const{i18n:d}=H(),{dateFormat:l}=Pt("UTC"),{freeze:h,frozen:u}=kv(Fv),[p,f]=F(null),{refreshing:T}=Ee(),g=A(()=>t||T,[t,T]),y=Pe(Ie.up.sm),_=Pe(Ie.down.xs),v=xi({fields:Wp,customColumns:o,columnConfig:A(()=>({dateAndReportType:{visible:_},createdAt:{visible:y},reportType:{visible:y},reportFile:{visible:!0,position:_?"right":void 0}}),[y,_])}),N=C(()=>{f(null)},[]),S={title:"noReportsFound",message:["tryDifferentSearchOrResetYourFiltersAndWeWillTryAgain"]},D=A(()=>()=>i(Fi,{error:e,errorMessage:"weCouldNotLoadYourReports",onContactSupport:s}),[e,s]),R=A(()=>i(ue,{name:"warning"}),[]),b=A(()=>E=>{const P={};switch(E==null?void 0:E.errorCode){case"999_429_001":P.title=d.get("error.somethingWentWrongWithDownload"),P.description=d.get("reportsError.tooManyDownloads");break;case"00_500":default:P.title=d.get("error.somethingWentWrongWithDownload"),P.description=d.get("error.pleaseTryAgainLater");break}f(P)},[d]);return t&&f(null),i("div",{className:$p,children:[p&&i(et,{onClose:N,type:be.WARNING,className:"adyen-pe-reports-table-alert",...p}),i(tn,{errorDisplay:D,error:e,columns:v,data:a,loading:g,outline:!1,emptyTableMessage:S,customCells:{createdAt:({value:E})=>E?E&&i(I,{variant:O.BODY,children:l(E,xl)}):null,dateAndReportType:({item:E})=>i("div",{className:Up,children:[i(I,{variant:O.BODY,stronger:!0,children:d.get(`reportType.${E==null?void 0:E.type}`)}),i(I,{className:Mv,variant:O.BODY,children:l(E.createdAt,xl)})]}),reportType:({item:E})=>(E==null?void 0:E.type)&&i(I,{variant:O.BODY,children:d.get(`reportType.${E==null?void 0:E.type}`)}),reportFile:({item:E})=>{const P={query:{balanceAccountId:n,createdAt:E.createdAt,type:E.type}};return i(Bp,{className:"adyen-pe-reports-table--download",endpointName:"downloadReport",disabled:u,requestParams:P,onDownloadRequested:h,setError:b,errorDisplay:R})}},children:r&&i(tn.Footer,{children:i(Mi,{...c})})})]})},Bv="adyen-pe-reports-overview",$v=new Date("2024-04-16T00:00:00.000Z").toString(),Uv=({onFiltersChanged:e,balanceAccounts:t,allowLimitSelection:n=!0,preferredLimit:s=hr,isLoadingBalanceAccount:r,onContactSupport:a,hideTitle:o,dataCustomization:c})=>{var V,Z,ge,Ne;const{getReports:d}=Ee().endpoints,{activeBalanceAccount:l,balanceAccountSelectionOptions:h,onBalanceAccountSelection:u}=Yi(t),{defaultParams:p,nowTimestamp:f,refreshNowTimestamp:T}=Ji("reports",l),g=C(async(me,Ce)=>d({signal:Ce,errorLevel:"error"},{query:{...me,type:"payout",createdSince:me[re.CREATED_SINCE]??p.current.defaultFilterParams[re.CREATED_SINCE],createdUntil:me[re.CREATED_UNTIL]??p.current.defaultFilterParams[re.CREATED_UNTIL],balanceAccountId:(l==null?void 0:l.id)??""}}),[l==null?void 0:l.id,p,d]),y=Wi(),_=A(()=>ee(e)?e:void 0,[e]),v=A(()=>n?ji:void 0,[n]),{canResetFilters:N,error:S,fetching:D,filters:R,limit:b,limitOptions:E,records:P,resetFilters:w,updateFilters:W,updateLimit:x,...j}=Vi({fetchRecords:g,dataField:"data",filterParams:p.current.defaultFilterParams,initialFiltersSameAsDefault:!0,onFiltersChanged:_,preferredLimit:s,preferredLimitOptions:v,enabled:!!(l!=null&&l.id)&&!!d}),L=C(({records:me,retrievedData:Ce})=>Jc(me,Ce,(ae,ye)=>ae.createdAt===ye.createdAt),[]),U=A(()=>{var me;return Qc((me=c==null?void 0:c.list)==null?void 0:me.fields,Wp)},[(V=c==null?void 0:c.list)==null?void 0:V.fields]),{customRecords:ie,loadingCustomRecords:le}=Zc({records:P,hasCustomColumn:U,onDataRetrieve:(Z=c==null?void 0:c.list)==null?void 0:Z.onDataRetrieve,mergeCustomData:L});return G(()=>{T()},[R,T]),i("div",{className:Bv,children:[i(Do,{hideTitle:o,titleKey:"reportsTitle",subtitleKey:"reportsNotice",children:i(Hi,{...y})}),i(Gi,{...y,children:[i(qi,{activeBalanceAccount:l,balanceAccountSelectionOptions:h,onBalanceAccountSelection:u}),i(Qi,{canResetFilters:N,defaultParams:p,filters:R,nowTimestamp:f,refreshNowTimestamp:T,sinceDate:$v,timezone:"UTC",updateFilters:W})]}),i(xv,{balanceAccountId:l==null?void 0:l.id,loading:D||r||!t||!l||le,data:(ge=c==null?void 0:c.list)!=null&&ge.onDataRetrieve?ie:P,showPagination:!0,limit:b,limitOptions:E,onContactSupport:a,onLimitSelection:x,error:S,customColumns:(Ne=c==null?void 0:c.list)==null?void 0:Ne.fields,...j})]})},Wv="adyen-pe-reports-overview-container";function Hv({...e}){const{balanceAccounts:t,isBalanceAccountIdWrong:n,isFetching:s,error:r}=No(e.balanceAccountId);return i(Ui,{balanceAccountsError:r,className:Wv,errorMessage:"weCouldNotLoadTheReportsOverview",isBalanceAccountIdWrong:n,onContactSupport:e.onContactSupport,children:i(Uv,{...e,balanceAccounts:t,isLoadingBalanceAccount:s})})}class Hp extends Sn{constructor(n){super(n);Y(this,"componentToRender",()=>i(Hv,{...this.props,balanceAccountId:this.props.balanceAccountId,ref:n=>{this.componentRef=n}}));this.componentToRender=this.componentToRender.bind(this)}}Y(Hp,"type","reports");const In={base:"adyen-pe-capital-overview",skeleton:"adyen-pe-capital-overview__skeleton",headerSkeleton:"adyen-pe-capital-overview__header-skeleton",skeletonContainer:"adyen-pe-capital-overview__header-skeleton-container",preQualifiedGrant:"adyen-pe-capital-overview__pre-qualified-grant",preQualifiedGrantButton:"adyen-pe-capital-overview__pre-qualified-grant-review-button",errorContainer:"adyen-pe-capital-overview__error-container"},Gv="data:image/svg+xml,%3csvg%20width='254'%20height='132'%20viewBox='0%200%20254%20132'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M68.0772%2069.5256C68.0287%2069.3932%2066.6957%2058.4056%2066.6957%2058.4056C66.576%2057.682%2064.6702%2055.0296%2064.4049%2054.5676L53.5013%2036.8958C52.618%2035.639%2051.1199%2036.0946%2050.4728%2036.6244C49.9325%2037.0379%2049.4601%2037.7293%2050.3272%2039.3769C51.7832%2042.1489%2057.4842%2052.9393%2057.4842%2052.9393L55.7144%2056.3348L52.7927%2058.9872C52.9836%2059.3231%2048.6124%2058.4993%2048.6124%2058.4993C48.4798%2058.3313%2050.9776%2071.0117%2057.4421%2074.7529C57.4421%2074.7529%2065.2591%2087.724%2065.0294%2087.8274L73.1635%2078.8397L68.0772%2069.5289V69.5256Z'%20fill='%23B34B36'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M51.534%2055.2108C51.534%2055.2108%2047.6805%2054.975%2048.6155%2058.4932C49.5506%2062.0146%2053.6079%2068.3984%2055.4069%2066.838C57.2058%2065.2776%2053.2844%2059.5238%2053.2844%2059.5238'%20fill='%23B34B36'/%3e%3cpath%20d='M51.534%2055.2108C51.534%2055.2108%2047.6805%2054.975%2048.6155%2058.4932C49.5506%2062.0146%2053.6079%2068.3984%2055.4069%2066.838C57.2058%2065.2776%2053.2844%2059.5238%2053.2844%2059.5238'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M53.6048%2052.245C53.6048%2052.245%2049.7513%2052.0092%2050.6863%2055.5274C51.6214%2059.0488%2055.6787%2065.4326%2057.4777%2063.8722C59.2766%2062.3118%2055.3552%2056.558%2055.3552%2056.558'%20fill='%23B34B36'/%3e%3cpath%20d='M53.6048%2052.245C53.6048%2052.245%2049.7513%2052.0092%2050.6863%2055.5274C51.6214%2059.0488%2055.6787%2065.4326%2057.4777%2063.8722C59.2766%2062.3118%2055.3552%2056.558%2055.3552%2056.558'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M56.1903%2050.5459C56.1903%2050.5459%2051.8191%2049.0404%2052.7542%2052.5619C53.6893%2056.0833%2057.7466%2062.4671%2059.5455%2060.9067C61.3445%2059.3463%2056.1903%2050.5459%2056.1903%2050.5459Z'%20fill='%23B34B36'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M66.6955%2058.4029C66.6955%2058.4029%2065.5081%2049.147%2063.7253%2048.0615C61.9425%2046.9759%2057.8852%2043.3641%2056.8142%2044.091C55.7433%2044.8146%2056.1186%2046.4849%2056.8369%2047.4024C57.5552%2048.3199%2061.2469%2051.8381%2061.2469%2051.8381C61.2469%2051.8381%2056.3677%2059.3365%2058.872%2064.8481'%20fill='%23B34B36'/%3e%3cpath%20d='M66.6955%2058.4029C66.6955%2058.4029%2065.5081%2049.147%2063.7253%2048.0615C61.9425%2046.9759%2057.8852%2043.3641%2056.8142%2044.091C55.7433%2044.8146%2056.1186%2046.4849%2056.8369%2047.4024C57.5552%2048.3199%2061.2469%2051.8381%2061.2469%2051.8381C61.2469%2051.8381%2056.3677%2059.3365%2058.872%2064.8481'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M118.833%2023.1365C116.105%2020.3161%20116.157%2017.247%20116.856%2014.7691C116.862%2014.7432%20116.869%2014.7206%20116.879%2014.6948C117.869%2011.3155%20121.479%209.48044%20124.89%2010.3721C127.465%2011.0473%20130.222%2011.1572%20132.907%2011.1442C136.748%2011.1281%20140.66%2010.9116%20144.364%2011.9261C148.069%2012.9373%20150.829%2014.5397%20151.867%2018.2291C163.078%2023.0557%20156.41%2033.3325%20156.41%2033.3325L150.822%2042.3364L127.381%2038.8182C121.855%2038.1236%20117.882%2033.171%20118.406%2027.6368L118.833%2023.1365Z'%20fill='%230ABF53'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M123.178%2023.6825C121.062%2022.3709%20120.467%2019.2629%20121.677%2017.0887C122.887%2014.9145%20125.56%2013.774%20128.035%2014.0389C129.484%2014.194%20130.853%2014.7658%20132.257%2015.1568C133.661%2015.5477%20135.205%2015.7512%20136.551%2015.1858C137.893%2014.6205%20138.903%2013.0633%20138.424%2011.687'%20stroke='%2385DFA9'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M150.725%2040.7211C150.783%2039.2382%20152.158%2037.9847%20153.64%2037.8813C155.122%2037.778%20156.574%2038.7116%20157.273%2040.0201C157.972%2041.3285%20157.975%2042.9438%20157.474%2044.3395C157.115%2045.3377%20156.487%2046.265%20155.594%2046.84C154.384%2047.6154%20152.792%2047.6541%20151.449%2047.1405C150.107%2046.6268%20149.003%2045.6091%20148.172%2044.4396'%20fill='%23B34B36'/%3e%3cpath%20d='M150.725%2040.7211C150.783%2039.2382%20152.158%2037.9847%20153.64%2037.8813C155.122%2037.778%20156.574%2038.7116%20157.273%2040.0201C157.972%2041.3285%20157.975%2042.9438%20157.474%2044.3395C157.115%2045.3377%20156.487%2046.265%20155.594%2046.84C154.384%2047.6154%20152.792%2047.6541%20151.449%2047.1405C150.107%2046.6268%20149.003%2045.6091%20148.172%2044.4396'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M120.641%2036.9443C120.951%2035.4937%20119.932%2033.9365%20118.521%2033.4713C117.111%2033.0061%20115.474%2033.5489%20114.471%2034.6441C113.468%2035.7393%20113.066%2037.3029%20113.205%2038.7793C113.306%2039.8358%20113.684%2040.889%20114.406%2041.6643C115.386%2042.7143%20116.92%2043.1472%20118.347%2042.9792C119.774%2042.8112%20121.097%2042.1005%20122.194%2041.1733'%20fill='%23B34B36'/%3e%3cpath%20d='M120.641%2036.9443C120.951%2035.4937%20119.932%2033.9365%20118.521%2033.4713C117.111%2033.0061%20115.474%2033.5489%20114.471%2034.6441C113.468%2035.7393%20113.066%2037.3029%20113.205%2038.7793C113.306%2039.8358%20113.684%2040.889%20114.406%2041.6643C115.386%2042.7143%20116.92%2043.1472%20118.347%2042.9792C119.774%2042.8112%20121.097%2042.1005%20122.194%2041.1733'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M153.317%2064.6669H152.567C148.937%2064.6669%20145.995%2061.727%20145.995%2058.1054V49.3535H125.097V58.1054C125.097%2061.7302%20122.153%2064.6669%20118.526%2064.6669H117.775L135.516%2080.7977L153.324%2064.6669H153.317Z'%20fill='%23B34B36'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M118.293%2043.2381L122.273%2052.6361C122.668%2053.5666%20121.982%2054.5971%20120.972%2054.5971H113.013C112%2054.5971%20111.317%2053.5666%20111.712%2052.6361L115.692%2043.2381C116.177%2042.088%20117.808%2042.088%20118.296%2043.2381H118.293Z'%20fill='%2385DFA9'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M155.138%2047.7447L159.535%2056.9553C159.972%2057.8664%20159.334%2058.926%20158.322%2058.9713L150.372%2059.3266C149.362%2059.3719%20148.631%2058.3736%20148.984%2057.427L152.537%2047.861C152.97%2046.6914%20154.601%2046.6171%20155.138%2047.7447Z'%20fill='%2385DFA9'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M125.543%2056.5576L125.096%2056.1828V53.0781H145.926V56.1828L145.574%2056.48C143.063%2058.609%20139.918%2059.8658%20136.628%2060.0079C135.741%2060.0467%20134.851%2060.0402%20133.968%2059.9853C130.868%2059.7947%20127.924%2058.5477%20125.543%2056.5543V56.5576Z'%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M147.713%2022.2967C141.423%2025.2624%20134.202%2026.2381%20127.355%2024.9911C126.158%2024.7746%20124.919%2024.4354%20123.777%2023.9379C121.457%2026.923%20119.833%2030.7158%20119.296%2034.9674C117.921%2045.9%20124.24%2055.6954%20133.416%2056.8456C142.588%2057.9957%20151.143%2050.0676%20152.518%2039.135C153.346%2032.567%20151.392%2026.4126%20147.71%2022.2935L147.713%2022.2967Z'%20fill='%23B34B36'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M119.625%2020.3711C120.754%2022.2158%20122.595%2023.5275%20124.653%2024.2802'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M132.249%2035.6243C132.444%2034.0771%20131.084%2032.6321%20129.212%2032.397C127.34%2032.1618%20125.664%2033.2254%20125.469%2034.7727C125.274%2036.3199%20126.634%2037.7649%20128.506%2038C130.378%2038.2352%20132.054%2037.1716%20132.249%2035.6243Z'%20fill='white'/%3e%3cpath%20d='M130.497%2041.3389C130.497%2041.3389%20128.646%2044.9152%20133.943%2045.5775C139.239%2046.243%20138.084%2042.2887%20138.084%2042.2887'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M125.459%2034.7669C125.459%2034.7669%20125.812%2031.9659%20129.199%2032.3923C132.587%2032.8188%20132.234%2035.6198%20132.234%2035.6198'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M127.726%2036.9931C128.968%2036.9931%20129.975%2035.9878%20129.975%2034.7478C129.975%2033.5077%20128.968%2032.5024%20127.726%2032.5024C126.484%2032.5024%20125.478%2033.5077%20125.478%2034.7478C125.478%2035.9878%20126.484%2036.9931%20127.726%2036.9931Z'%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M123.944%2033.5752C123.944%2033.5752%20125.048%2034.9256%20126.161%2034.7609L123.944%2033.5752Z'%20fill='%2300112C'/%3e%3cpath%20d='M123.944%2033.5752C123.944%2033.5752%20125.048%2034.9256%20126.161%2034.7609'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M146.765%2036.4375C146.765%2036.4375%20145.361%2037.4713%20144.325%2037.0384L146.765%2036.4375Z'%20fill='%2300112C'/%3e%3cpath%20d='M146.765%2036.4375C146.765%2036.4375%20145.361%2037.4713%20144.325%2037.0384'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M144.949%2037.2181C145.144%2035.6708%20143.785%2034.2259%20141.912%2033.9907C140.04%2033.7555%20138.364%2034.8192%20138.169%2036.3664C137.974%2037.9137%20139.334%2039.3586%20141.206%2039.5938C143.079%2039.829%20144.754%2038.7653%20144.949%2037.2181Z'%20fill='white'/%3e%3cpath%20d='M138.158%2036.3631C138.158%2036.3631%20138.511%2033.5621%20141.898%2033.9885C145.286%2034.415%20144.933%2037.216%20144.933%2037.216'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M133.784%2046.9853C130.581%2046.5847%20129.06%2048.1031%20129.06%2048.1031C129.06%2048.1031%20128.801%2051.6859%20133.263%2052.2448C137.725%2052.8037%20138.013%2049.3437%20138.013%2049.3437C138.013%2049.3437%20137.223%2047.415%20133.787%2046.982L133.784%2046.9853Z'%20fill='%2389382B'/%3e%3cpath%20d='M128.361%2047.7129C131.526%2049.6093%20135.334%2050.123%20138.89%2049.1344L139.136%2049.0665'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M125.485%2029.0653C126.695%2028.4838%20128.089%2028.2996%20129.41%2028.5419C130.73%2028.7842%20131.966%2029.453%20132.891%2030.4254'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M145.984%2030.8031C145.114%2029.7854%20143.913%2029.052%20142.606%2028.7419C141.302%2028.4318%20139.898%2028.5448%20138.662%2029.0585'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M140.583%2038.6054C141.825%2038.6054%20142.831%2037.6001%20142.831%2036.3601C142.831%2035.12%20141.825%2034.1147%20140.583%2034.1147C139.341%2034.1147%20138.334%2035.12%20138.334%2036.3601C138.334%2037.6001%20139.341%2038.6054%20140.583%2038.6054Z'%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M154.285%2023.02C154.285%2023.02%20156.686%2025.33%20155.223%2030.8027'%20stroke='%2385DFA9'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M124.708%2064.8447C123.245%2064.1016%20121.679%2063.6009%20120.055%2063.3586C115.723%2062.7124%20107.294%2066.8121%20100.011%2070.9603C89.8645%2076.74%2080.3262%2090.0019%2080.3262%2090.0019L69.607%2069.8328C69.2187%2069.1059%2068.2222%2068.9929%2067.6851%2069.6164C64.3784%2073.4447%2054.9081%2084.5744%2055.1475%2086.2447C55.4355%2088.2671%2067.3033%20128.437%2081.1966%20120.348C95.0899%20112.258%20106.087%20102.718%20106.087%20102.718L107.951%20131.494H138.119C138.119%20131.494%20138.216%2078.9821%20138.216%2077.538C138.216%2076.4137%20128.843%2066.9414%20124.704%2064.8414L124.708%2064.8447Z'%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M152.566%2064.6665L138.217%2077.5408L138.12%20131.496H169.899V104.359L185.84%20131.496H211.297C211.297%20131.496%20193.473%2089.0323%20179.767%2074.2487C172.503%2066.4111%20152.566%2064.6665%20152.566%2064.6665Z'%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M15.9987%201H13.3003V49.1274H15.9987V1Z'%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M13%2024.6216L1%2024.6216'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20opacity='0.75'%20d='M80.2651%201.22607H16.0015V49.3535H80.2651V1.22607Z'%20fill='white'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M80.2651%201H16.0015V49.1274H80.2651V1Z'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M29.8433%2025.0622C29.8433%2023.8378%2030.8398%2022.8428%2032.0661%2022.8428C33.2923%2022.8428%2034.2889%2023.8378%2034.2889%2025.0622C34.2889%2026.2867%2033.2923%2027.2817%2032.0661%2027.2817C30.8398%2027.2817%2029.8433%2026.2867%2029.8433%2025.0622Z'%20fill='%23F7F8F9'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M64.1984%2027.2817C65.426%2027.2817%2066.4212%2026.288%2066.4212%2025.0622C66.4212%2023.8365%2065.426%2022.8428%2064.1984%2022.8428C62.9708%2022.8428%2061.9756%2023.8365%2061.9756%2025.0622C61.9756%2026.288%2062.9708%2027.2817%2064.1984%2027.2817Z'%20fill='%23F7F8F9'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M48.1344%2027.2817C49.362%2027.2817%2050.3572%2026.288%2050.3572%2025.0622C50.3572%2023.8365%2049.362%2022.8428%2048.1344%2022.8428C46.9068%2022.8428%2045.9116%2023.8365%2045.9116%2025.0622C45.9116%2026.288%2046.9068%2027.2817%2048.1344%2027.2817Z'%20fill='%23F7F8F9'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20opacity='0.75'%20d='M226.125%20106.581V46.6392H181.1V106.581H226.125Z'%20fill='white'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M180.99%2046.6392H178.469V106.581H180.99V46.6392Z'%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M253%2076.6216H226'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M225.866%2046.6392H212.345V60.1402H225.866V46.6392Z'%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M244.779%2027.5757H214.763V57.5467H244.779V27.5757Z'%20fill='%230ABF53'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M225.499%2043.4868L228.443%2046.4235L236.176%2038.7021'%20stroke='white'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cpath%20d='M220.919%20116.949L216.163%2096.2178L234.832%20106.113L220.919%20116.949Z'%20fill='%2300112C'%20stroke='%2300112C'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3c/svg%3e",Yv=({hideTitle:e})=>{const{i18n:t}=H();return i(Q,{children:[i(cs,{hideTitle:e,titleKey:"capital.needSomeExtraMoney"}),i("div",{className:"adyen-pe-capital-overview__unqualified-state",children:[i("div",{className:"adyen-pe-capital-overview__unqualified-state-img",children:i("img",{srcSet:Gv,alt:""})}),i(I,{el:J.PARAGRAPH,variant:O.BODY,large:!0,children:t.get("capital.youWillSoonQualifyForAFinancialOffer")})]})]})},qv=({dynamicOfferConfig:e,hideTitle:t,onOfferOptionsRequest:n})=>{const{i18n:s}=H();return i(Q,{children:[i(cs,{hideTitle:t,titleKey:"capital.needSomeExtraMoney"}),i("div",{className:In.preQualifiedGrant,children:[i(na,{children:i(I,{variant:O.BODY,children:[s.get("capital.youHaveBeenPrequalifiedForBusinessFinancingUpToX.part1"),i("strong",{children:s.get("capital.youHaveBeenPrequalifiedForBusinessFinancingUpToX.part2",{values:{amount:s.amount(e.maxAmount.value,e.maxAmount.currency,{minimumFractionDigits:0})}})})]})}),i(_e,{className:In.preQualifiedGrantButton,onClick:n,children:s.get("capital.seeOptions")})]})]})},jv=({hideTitle:e,dynamicOffer:t,skipPreQualifiedIntro:n,onOfferOptionsRequest:s,onFundsRequest:r,onOfferDismiss:a})=>{const[o,c]=F(n?"capitalOffer":"intro"),d=C(()=>{s?s():c("capitalOffer")},[s]),l=A(()=>!n||!!a,[a,n]),h=C(()=>{a?a():c("intro")},[a]);return i(Q,{children:o==="intro"?i(qv,{hideTitle:e,dynamicOfferConfig:t,onOfferOptionsRequest:d}):i(rl,{onFundsRequest:r,onOfferDismiss:l?h:void 0,externalDynamicOffersConfig:t})})},Vv=({max:e=1,value:t,labels:n,tooltips:s,className:r})=>{const a=A(()=>Et(0,t*100/e,100),[t,e]),o=!!(n!=null&&n.current||n!=null&&n.max),c=(n==null?void 0:n.ariaLabel)??(n!=null&&n.current?`${n.current}: ${t}`:`${t}/${e}`);return i("div",{role:"progressbar","aria-valuenow":t,"aria-valuemin":0,"aria-valuemax":e,"aria-valuetext":`${a}%`,"aria-label":c,className:M("adyen-pe-progress-bar",r),children:[i("div",{className:"adyen-pe-progress-bar__track",children:[i("div",{className:"adyen-pe-progress-bar__track-background"}),i(bd,{tooltipContent:s==null?void 0:s.progress,title:n==null?void 0:n.current,percentage:a,className:"adyen-pe-progress-bar__track-fill"}),i(bd,{tooltipContent:s==null?void 0:s.remaining,title:n==null?void 0:n.max,percentage:100-a,className:"adyen-pe-progress-bar__track-remaining"})]}),o&&i("div",{className:"adyen-pe-progress-bar__legend","aria-hidden":"true",children:[n.current&&i(I,{el:J.SPAN,variant:O.CAPTION,className:"adyen-pe-progress-bar__legend-label",children:n.current}),n.max&&i(I,{el:J.SPAN,variant:O.CAPTION,className:"adyen-pe-progress-bar__legend-label",children:n.max})]})]})},bd=({tooltipContent:e,title:t,percentage:n,className:s})=>{const r=a=>i("div",{className:s,title:a,style:{width:`${n}%`}});return e?i(Rn,{content:e,children:r()}):r(t)},kt={base:"adyen-pe-grant-item",actionsBar:"adyen-pe-grant-item__actions-bar",alert:"adyen-pe-grant-item__alert",cardContent:"adyen-pe-grant-item__card-content",grantID:"adyen-pe-grant-item__grant-id",mainActionBtn:"adyen-pe-grant-item__main-action-button",progressBar:"adyen-pe-grant-item__progress-bar",statusContainer:"adyen-pe-grant-item__status-container",textSecondary:"adyen-pe-grant-item__text--secondary"},zv=e=>e==="Active",Kv=e=>e==="Repaid",Xv=e=>e==="Active"?"capital.remaining":"capital.requestedFunds",Zv=e=>e.status==="Active"?e.remainingTotalAmount:e.grantAmount,Qv=({status:e,missingActions:t})=>{switch(e){case"Active":return;case"Failed":return"capital.failed";case"Pending":return t&&t.length?"capital.actionNeeded":"capital.pending";case"Repaid":return"capital.fullyRepaid";case"Revoked":return"capital.revoked";case"WrittenOff":return"capital.writtenOff"}},Jv=({status:e,missingActions:t})=>{switch(e){case"Failed":return Oe.ERROR;case"Pending":return t!=null&&t.length?Oe.WARNING:Oe.DEFAULT;case"Repaid":return Oe.LIGHT;case"Revoked":case"WrittenOff":return Oe.WARNING;default:return Oe.DEFAULT}},eR=e=>{const t=new Date,n=new Date;return n.setDate(t.getDate()+e),n},tR=e=>{var n,s;const t=((n=e.missingActions)==null?void 0:n.some(r=>r.type==="signToS"))||!1;switch(e.status){case"Pending":return(s=e.missingActions)!=null&&s.length?t?"capital.signTheTermsToReceiveYourFunds":void 0:"capital.youShouldGetTheFundsWithinOneBusinessDay";case"Failed":return"capital.weCouldNotProcessThisRequestTryAgain";case"WrittenOff":return"capital.youAcceptedTheseFundsButDidNotRepayThem";case"Revoked":return"capital.youAcceptedButThenReturnedTheseFunds";default:return}},Gp=e=>{var s;const t=e.status==="Active",n=e.status==="Pending";return{amount:Zv(e),amountLabelKey:Xv(e.status),hasAlerts:n,hasDetails:zv(e.status),hasUnscheduledRepaymentDetails:t&&!!((s=e.unscheduledRepaymentAccounts)!=null&&s.length),isAmountColorSecondary:!t,isBackgroundFilled:Kv(e.status),isGrantIdVisible:!t,isLabelColorSecondary:t,isProgressBarVisible:t,repaymentPeriodEndDate:eR(e.repaymentPeriodLeft),statusKey:Qv(e),statusTagVariant:Jv(e),statusTooltipKey:tR(e)}},vr={base:"adyen-pe-grant-details",content:"adyen-pe-grant-details__content",header:"adyen-pe-grant-details__header",label:"adyen-pe-grant-details__label"},nR=({grant:e})=>{const{i18n:t}=H(),n=C(r=>t.amount(r.value,r.currency),[t]),s=A(()=>{const r=e.maximumRepaymentPeriodDays?Math.ceil(e.maximumRepaymentPeriodDays/30):null,a=[{key:"capital.remainingAmount",value:t.amount(e.remainingGrantAmount.value,e.remainingGrantAmount.currency)},{key:"capital.remainingFees",value:n(e.remainingFeesAmount)},{key:"capital.repaidAmount",value:n(e.repaidGrantAmount)},{key:"capital.repaidFees",value:n(e.repaidFeesAmount)},{key:"capital.dailyRepaymentRate",value:`${t.get("capital.xPercent",{values:{percentage:li(e.repaymentRate)}})}`},{key:"capital.expectedRepaymentPeriod",value:t.get("capital.daysAndDaysLeft",{values:{days:e.expectedRepaymentPeriodDays,daysLeft:e.repaymentPeriodLeft}})},{key:"capital.totalFees",value:n(e.feesAmount)},{key:"capital.totalRepaymentAmount",value:n(e.totalAmount)},{key:"capital.repaymentThreshold",value:n(e.thresholdAmount)},{key:"capital.grantID",value:e.id},{key:"accountDescription",value:e.balanceAccountDescription},{key:"accountID",value:e.balanceAccountCode}];return r&&a.splice(5,0,{key:"capital.maximumRepaymentPeriod",value:t.get("capital.xMonths",{values:{months:r}})}),a},[e,n,t]);return i("div",{className:vr.base,children:i("div",{className:vr.content,children:[i("div",{className:vr.header,children:[i(I,{el:J.SPAN,variant:O.BODY,children:t.get("capital.yourRequestedFundsWere")}),i(I,{el:J.SPAN,variant:O.BODY,strongest:!0,children:t.amount(e.grantAmount.value,e.grantAmount.currency)})]}),i(gn,{renderLabel:(r,a)=>a==="capital.repaymentThreshold"?i(Rn,{isContainerHovered:!0,content:t.get("capital.minimumRepaymentToRepayTheFinancingOnTime",{values:{days:di}}),children:i("span",{children:i(I,{className:vr.label,el:J.SPAN,variant:O.CAPTION,children:r})})}):i(I,{className:vr.label,el:J.SPAN,variant:O.CAPTION,children:r}),renderValue:r=>i(I,{el:J.SPAN,stronger:!0,variant:O.CAPTION,children:r}),items:s})]})})},Hn={button:"adyen-pe-grant-action__button",buttonLabel:"adyen-pe-grant-action__button-label",actionsContainer:"adyen-pe-grant-action__actions-container",actionsInformation:"adyen-pe-grant-action__actions-information"},sR=()=>{var e;return((e=window.top)==null?void 0:e.location.href)||window.location.href},rR=e=>{window.top?window.top.location.href=e:window.location.href=e},oR=({missingActions:e=[],offerExpiresAt:t,className:n})=>{const{i18n:s,updateCore:r}=H(),{dateFormat:a}=Pt(),{endpoints:o}=Ee(),c=A(()=>({signToS:{getTitle:g=>`${s.get("capital.signTermsAndConditionsToReceiveFunds")}${g?` ${s.get("capital.thisOfferExpiresOn",{values:{date:g}})}`:""}`,buttonLabelKey:"capital.goToTermsAndConditions"},AnaCredit:{getTitle:g=>g?s.get("capital.weNeedABitMoreInformationToProcessYourFundsPleaseCompleteThisActionBy",{values:{date:g}}):s.get("capital.weNeedABitMoreInformationToProcessYourFundsPleaseCompleteThisAction"),buttonLabelKey:"capital.submitInformation"}}),[s]),[d,l]=F(null),h=C(g=>{g!=null&&g.url?rR(g.url):l(null)},[]),u=is({queryFn:g=>{let y=null;switch(g){case"signToS":y=o.signToSActionDetails;break;case"AnaCredit":y=o.anaCreditActionDetails;break;default:break}const _=y,v={query:{redirectUrl:sR(),locale:s.locale}};return _==null?void 0:_(z,v)},options:{onSuccess:h,onError:()=>{l(null)}}}),p=A(()=>t?a(t,Y_):void 0,[a,t]);if(u.error)return i(et,{className:n,type:be.CRITICAL,title:s.get("somethingWentWrongTryRefreshingOrComeBackLater"),description:i(_e,{className:Hn.button,onClick:r,children:s.get("refresh")})});if(!e.length)return null;if(e.length>1)return i(et,{className:n,type:be.WARNING,title:s.get("capital.weNeedABitMoreInformationToProcessYourFundsPleaseCompleteTheseActions"),description:i("div",{className:Hn.actionsInformation,children:[i("ol",{className:Hn.actionsContainer,children:e.map(g=>{const y=c[g.type],_=d===g.type;return i("li",{children:i(_e,{className:Hn.button,onClick:()=>{l(g.type),u.mutate(g.type)},disabled:_||u.isLoading,state:_?"loading":void 0,variant:te.TERTIARY,children:i("span",{className:Hn.buttonLabel,children:s.get(y.buttonLabelKey)})})},g.type)})}),p?i(I,{el:J.SPAN,variant:O.BODY,strongest:!0,children:s.get("capital.thisOfferExpiresOn",{values:{date:p}})}):null]})});const f=e[0],T=c[f.type];return i(et,{className:n,type:be.WARNING,title:T.getTitle(p),description:i(_e,{className:Hn.button,onClick:()=>{l(f.type),u.mutate(f.type)},disabled:!!d,state:d?"loading":void 0,variant:te.TERTIARY,children:i("span",{className:Hn.buttonLabel,children:s.get(T.buttonLabelKey)})})})},iR=({grant:e,showDetails:t})=>{const{i18n:n}=H(),{dateFormat:s}=Pt(),r=A(()=>Gp(e),[e]),a=C(()=>t==null?void 0:t("unscheduledRepayment"),[t]),o=A(()=>{var c,d;return i("div",{className:kt.cardContent,children:[i("div",{className:kt.statusContainer,children:[i(I,{variant:O.CAPTION,className:M({[kt.textSecondary]:r.isLabelColorSecondary}),testId:"grant-amount-label",children:n.get(r.amountLabelKey)}),i("div",{children:e.status==="Active"?i(Q,{children:[i(I,{variant:O.CAPTION,el:J.SPAN,children:n.get("capital.termEnds")}),i(I,{variant:O.CAPTION,stronger:!0,el:J.SPAN,children:s(r.repaymentPeriodEndDate,G_)})]}):r.statusKey?r.statusTooltipKey?i(Rn,{content:n.get(r.statusTooltipKey),children:i("div",{children:i(ot,{label:n.get(r.statusKey),variant:r.statusTagVariant})})}):i(ot,{label:n.get(r.statusKey),variant:r.statusTagVariant}):null})]}),i(I,{variant:O.TITLE,medium:!0,className:M({[kt.textSecondary]:r.isAmountColorSecondary}),children:n.amount(r.amount.value,r.amount.currency)}),r.isProgressBarVisible&&i(Vv,{className:kt.progressBar,value:e.repaidTotalAmount.value,max:e.totalAmount.value,labels:{current:n.get("capital.repaid"),max:n.get("capital.remaining")},tooltips:{remaining:`${n.amount(e.remainingTotalAmount.value,e.remainingTotalAmount.currency)} ${(c=n.get("capital.remaining"))==null?void 0:c.toLowerCase()}`,progress:`${n.amount(e.repaidTotalAmount.value,e.repaidTotalAmount.currency)} ${(d=n.get("capital.repaid"))==null?void 0:d.toLowerCase()}`}}),r.isGrantIdVisible?i("div",{className:kt.grantID,children:i($t,{textToCopy:e.id,buttonLabel:n.get("capital.grantID"),isHovered:!0,type:"Text","data-testid":"grant-id-copy-text"})}):null,r.hasAlerts?i(Q,{children:e.missingActions&&e.missingActions.length?i(oR,{missingActions:e.missingActions,className:kt.alert,offerExpiresAt:e.offerExpiresAt}):i(et,{className:kt.alert,type:be.HIGHLIGHT,title:n.get("capital.weReceivedYourRequestAndWeAreWorkingOnItNowCheckBackSoon")})}):r.hasUnscheduledRepaymentDetails&&i("div",{className:kt.actionsBar,children:i(_e,{onClick:a,className:kt.mainActionBtn,variant:te.SECONDARY,fullWidth:!0,children:n.get("capital.sendRepayment")})})]})},[n,s,e,r,a]);return i("div",{className:kt.base,children:i(el,{renderHeader:o,filled:r.isBackgroundFilled,inFlow:!0,children:r.hasDetails&&i(nR,{grant:e})})})},aR={unscheduledRepayment:"unscheduledRepayment"},cR=({className:e,content:t,contentClassName:n,textToCopy:s,label:r,labelClassName:a})=>{const{i18n:o}=H();return i("div",{className:e,children:[i("dt",{className:a,children:i(I,{el:J.SPAN,variant:O.CAPTION,children:o.get(r)})}),i("dd",{className:n,children:s?i($t,{buttonLabel:t,textToCopy:s,showCopyTextTooltip:!1,type:"Text"}):i(I,{el:J.SPAN,variant:O.BODY,children:t})})]})},lR=(e,t=!0)=>{const n=t?" ":" ";return e.replace(/\s+/g,"").replace(/([A-Z\d]{4}(?!$))/gi,`$1${n}`)},dR=e=>{switch(e){case"iban":case"accountNumber":case"routingNumber":case"sortCode":return!0;case"region":default:return!1}},uR=(e,t)=>dR(e)?t:void 0,hR=(e,t)=>{switch(e){case"iban":return t&&lR(t);default:return t}},pR=e=>{switch(e){case"region":return"capital.bankCountryOrRegion";case"iban":return"capital.bankAccountIban";case"accountNumber":return"capital.bankAccountNumber";case"routingNumber":return"capital.bankRoutingNumber";case"sortCode":return"capital.bankSortCode";default:return e}},zo="adyen-pe-capital-account-details",ya={detail:`${zo}__detail`,detailContent:`${zo}__detail-content`,detailLabel:`${zo}__detail-label`},fR=({bankAccount:e,className:t})=>{const n=A(()=>{const{accountNumber:s,iban:r,order:a,region:o,...c}=e,d=Object.keys({iban:r,accountNumber:s,...c,region:o}),l=Array.isArray(a)?a.filter(h=>d.includes(h)):d;return[...new Set(l)]},[e]);return i("dl",{className:M(zo,t),children:n.map(s=>{const r=e[s];return r?i(Q,{children:i(cR,{className:ya.detail,contentClassName:ya.detailContent,labelClassName:ya.detailLabel,label:pR(s),content:hR(s,r),textToCopy:uR(s,r)})},s):null})})},mR=({children:e,className:t,headerTitleKey:n,headerSubtitleKey:s,onDetailsClose:r})=>{const{i18n:a}=H();return i("div",{className:M("adyen-pe-grant-adjustment-details",t),children:[i(Do,{titleKey:n,subtitleKey:s,children:i(_e,{onClick:r,variant:te.TERTIARY,iconButton:!0,classNameModifiers:["circle"],"aria-label":a.get("dismiss"),children:i(ue,{name:"cross"})})}),e]})},Or="adyen-pe-grant-repayment-details",Lo={balanceInfo:`${Or}__balance-info`,repaymentInfo:`${Or}__repayment-info`,repaymentAccount:`${Or}__repayment-account`,repaymentNotice:`${Or}__repayment-notice`},_R=({grant:e,onDetailsClose:t})=>{const{i18n:n}=H(),s=A(()=>{var a;return(a=e.unscheduledRepaymentAccounts)==null?void 0:a[0]},[e.unscheduledRepaymentAccounts]),r=A(()=>{const{currency:a,value:o}=e.remainingTotalAmount;return n.amount(o,a)},[n,e.remainingTotalAmount]);return s?i(mR,{className:Or,onDetailsClose:t,headerTitleKey:"capital.sendRepayment",headerSubtitleKey:"capital.sendRepaymentSubtitle",children:[i("div",{className:Lo.repaymentInfo,children:[i("section",{className:Lo.repaymentAccount,children:[i(I,{el:J.SPAN,variant:O.BODY,stronger:!0,children:n.get("capital.bankAccountDetails")}),i(fR,{bankAccount:s})]}),i("section",{className:Lo.repaymentNotice,children:i(I,{el:J.PARAGRAPH,variant:O.CAPTION,children:n.get("capital.sendRepaymentNotice")})})]}),i(na,{className:Lo.balanceInfo,children:i(I,{variant:O.BODY,children:i(pr,{translationKey:"capital.repaymentBalanceInfo",fills:{amount:i(I,{el:J.SPAN,variant:O.BODY,strongest:!0,children:r})}})})})]}):null},sc=e=>(e==null?void 0:e.disabled)===!0,Ir=(e,t,n)=>{const s=e.length;if(s){let r=t,a=s;for(;a--;){for(;r<0;)r+=s;if(r>=s&&(r%=s),!sc(e[r]))return r;r+=n}}return 0},Od=(e,t,n=0)=>{if(!t)return n;const s=e.findIndex(o=>o.id===t),r=s===-1?n:s,a=Ir(e,r,1);return r===a?r:n},Yp=({options:e,activeOption:t,onChange:n})=>{const[s,r]=F(!1),[a,o]=F(Od(e,t)),c=e[a],d=q(c),l=q([]),h=q(vn().replace(/.*?(?=\d+$)/,"")).current,u=A(()=>{const T=[];for(let g=0;g<e.length;g++)T[g]=y=>l.current[g]=y;return T},[e]),p=C(T=>{const g=l.current.findIndex(y=>y===T.currentTarget);sc(l.current[g])||(T.preventDefault(),o(g))},[]),f=A(()=>{const T={[ne.ARROW_LEFT]:()=>o(g=>Ir(l.current,g-1,-1)),[ne.ARROW_RIGHT]:()=>o(g=>Ir(l.current,g+1,1)),[ne.HOME]:()=>o(Ir(l.current,0,1)),[ne.END]:()=>o(Ir(l.current,-1,-1))};return g=>{var y;T[g.key]&&(g.preventDefault(),(y=T[g.key])==null||y.call(T),r(!0))}},[]);return G(()=>{o(T=>Od(e,t,T))},[e,t]),G(()=>{if(s){const T=l.current[a];sc(T)||T==null||T.focus(),r(!1)}},[a,s]),G(()=>{d.current!==c&&(d.current=c,n==null||n(c))},[c,n]),{activeIndex:a,onClick:p,onKeyDown:f,refs:u,uniqueId:h}};function gR({activeItem:e,items:t,onChange:n}){const{activeIndex:s,onClick:r,onKeyDown:a,refs:o,uniqueId:c}=Yp({onChange:n,options:t,activeOption:e}),{i18n:d}=H();return i("div",{children:[i("div",{role:"radiogroup",className:"adyen-pe-segmented-control",children:t.map((l,h)=>{const u=s===h;return i("button",{role:"radio",name:l.id,ref:o[h],id:`item:${c}-${l.id}`,className:"adyen-pe-segmented-control__item","aria-checked":u,"aria-controls":`segment:${c}-${l.id}`,onClick:u?void 0:r,onKeyDown:a,disabled:l.disabled,tabIndex:u?0:-1,children:i(I,{el:J.SPAN,variant:O.BODY,className:"adyen-pe-segmented-control__item-label",stronger:!0,children:d.get(l.label)})},`item:${c}-${l.id}`)})}),i("div",{className:"adyen-pe-segmented-content-container",children:t.map((l,h)=>i("section",{id:`segment:${c}-${l.id}`,className:"adyen-pe-segmented-content","aria-labelledby":`item:${c}-${l.id}`,hidden:s!==h,children:l.content},`segment:${c}-${l.id}`))})]})}const Aa=({grants:e,showDetails:t})=>i(nl,{classNames:"adyen-pe-grant-list__items",children:e.map(n=>i("li",{children:i(iR,{grant:n,showDetails:t.bind(null,n)})},n.id))}),TR=({grantList:e,hideTitle:t,newOfferAvailable:n,onNewOfferRequest:s})=>{const[r,a]=F(),[o,c]=F(),{i18n:d}=H(),[l,h]=A(()=>{const y=[],_=[];return e==null||e.forEach(v=>{v.status==="Active"||v.status==="Pending"?y.push(v):_.push(v)}),[y,_]},[e]),u=A(()=>e.length>1&&l.length&&h.length?"SegmentedGrants":"UnifiedGrants",[l.length,e.length,h.length]),p=A(()=>n&&!l.some(y=>y.status==="Pending"),[l,n]),f=A(()=>o&&Gp(o),[o]),T=C(()=>a(void 0),[]),g=C((y,_)=>{a(_),c(y)},[]);if(o)switch(r){case aR.unscheduledRepayment:{if(f!=null&&f.hasUnscheduledRepaymentDetails)return i(_R,{grant:o,onDetailsClose:T});break}}return i("div",{className:"adyen-pe-grant-list",children:[i("div",{className:"adyen-pe-grant-list__header-container",children:[i(cs,{hideTitle:t,titleKey:"capital.businessFinancing"}),p?i(_e,{onClick:s,className:"adyen-pe-grant-list__offer-button",variant:te.SECONDARY,children:d.get("capital.seeNewOffer")}):null]}),u==="UnifiedGrants"&&i(Aa,{grants:e,showDetails:g}),u==="SegmentedGrants"&&i(gR,{items:[{label:"capital.inProgress",content:i(Aa,{grants:l,showDetails:g}),id:"active"},{label:"capital.closed",content:i(Aa,{grants:h,showDetails:g}),id:"inactive"}],activeItem:"active"})]})},yR=({externalDynamicOffersConfig:e,grantList:t,newOfferAvailable:n,onFundsRequest:s,onGrantListUpdateRequest:r,onOfferDismiss:a})=>{const[o,c]=F(!1),d=C(()=>c(!1),[]),l=C(()=>c(!0),[]),h=C(()=>{a?a(d):d()},[d,a]),u=C(p=>{s?s(p):(r(p),c(!1))},[s,r]);return i(Q,{children:o?i(rl,{externalDynamicOffersConfig:e,onFundsRequest:u,onOfferDismiss:h}):i(TR,{grantList:t,newOfferAvailable:n,onNewOfferRequest:l})})},AR=({hideTitle:e,onContactSupport:t,onFundsRequest:n,onOfferDismiss:s,onOfferOptionsRequest:r,skipPreQualifiedIntro:a})=>{var S,D,R;const o=(D=(S=Ee())==null?void 0:S.extraConfig)==null?void 0:D.legalEntity,c=A(()=>sl(o),[o]),{getGrants:d,getDynamicGrantOffersConfiguration:l}=Ee().endpoints,h=bt({fetchOptions:{enabled:!!d&&c},queryFn:C(async()=>d==null?void 0:d(z),[d])}),u=bt({fetchOptions:{enabled:!!l&&c},queryFn:C(async()=>l==null?void 0:l(z),[l])}),p=u.data,[f,T]=F(),g=A(()=>{var b,E;return f?[f,...((b=h.data)==null?void 0:b.data)||[]]:(E=h.data)==null?void 0:E.data},[(R=h.data)==null?void 0:R.data,f]),y=C(b=>{n?n(b):T(b)},[n]),_=A(()=>!!(u.error&&h.error||u.error&&!(g!=null&&g.length)),[u.error,g==null?void 0:g.length,h.error]),v=A(()=>{if(c){if(_)return"Error";if(!d&&!l||!p&&!g||h.isFetching||u.isFetching)return"Loading";if(g!=null&&g.length)return"GrantList";if(p!=null&&p.maxAmount&&(p!=null&&p.minAmount))return"PreQualified"}else return"UnsupportedRegion";return"Unqualified"},[l,p,u.isFetching,g,d,h.isFetching,_,c]),N=A(()=>!!(p&&p.minAmount&&p.maxAmount),[p]);return i("div",{className:In.base,children:(()=>{switch(v){case"Loading":return i("div",{className:In.skeletonContainer,children:[i("div",{className:In.headerSkeleton}),i("div",{className:In.skeleton})]});case"Error":return i("div",{className:In.errorContainer,children:[i(cs,{hideTitle:e,titleKey:"capital.businessFinancing"}),i(Qt,{absolutePosition:!1,outlined:!1,withImage:!0,onContactSupport:t,...Fp(u.error,t)})]});case"GrantList":return g&&i(yR,{externalDynamicOffersConfig:p,grantList:g,hideTitle:e,newOfferAvailable:N,onFundsRequest:n,onGrantListUpdateRequest:T,onOfferDismiss:s});case"PreQualified":return i(jv,{onOfferDismiss:s,onOfferOptionsRequest:r,skipPreQualifiedIntro:a,hideTitle:e,dynamicOffer:p,onFundsRequest:y});case"Unqualified":return i(Yv,{hideTitle:e});case"UnsupportedRegion":return i("div",{className:In.errorContainer,children:[i(cs,{hideTitle:e,titleKey:"capital.businessFinancing"}),i(ta,{unsupportedRegion:!0})]});default:return null}})()})};class qp extends Sn{constructor(n){super(n);Y(this,"componentToRender",()=>i(AR,{...this.props,ref:n=>void(this.componentRef=n)}));this.customClassNames="adyen-pe-capital-overview-component",this.componentToRender=this.componentToRender.bind(this)}async getState(){var l,h;const{session:n}=this.props.core;await ju(n);const{getDynamicGrantOffersConfiguration:s,getGrants:r}=n.context.endpoints,a=(l=n.context.extraConfig)==null?void 0:l.legalEntity;if(!sl(a))return{state:"isInUnsupportedRegion"};const[o,c]=await Promise.all([s==null?void 0:s(z).catch(he),r==null?void 0:r(z).catch(he)]);let d="isUnqualified";return c&&((h=c.data)==null?void 0:h.length)>0?d="hasRequestedGrants":o&&o.minAmount&&(d="isPreQualified"),{state:d}}}Y(qp,"type","capitalOverview");const ol="adyen-pe-disputes-overview",vR=`${ol}--xs`,RR=`${ol}__tabs-container`,CR="2025-05-22T00:00:00.000Z",SR=10,jp={mc:"Mastercard",visa:"Visa",ach:"ACH Direct Debit",amex:"American Express",discover:"Discover",elo:"Elo",jcb:"JCB",pulse:"PULSE",sepadirectdebit:"SEPA Direct Debit",others:"Others"},sa={FRAUD:"disputes.reasonCategory.fraud",CONSUMER_DISPUTE:"disputes.reasonCategory.consumerDispute",PROCESSING_ERROR:"disputes.reasonCategory.processingError",REQUEST_FOR_INFORMATION:"disputes.reasonCategory.requestForInformation",AUTHORISATION_ERROR:"disputes.reasonCategory.authorisationError",ADJUSTMENT:"disputes.reasonCategory.adjustment",OTHER:"disputes.reasonCategory.other"},il={CHARGEBACKS:"disputes.statusGroup.chargebacks",FRAUD_ALERTS:"disputes.statusGroup.fraudAlerts",ONGOING_AND_CLOSED:"disputes.statusGroup.ongoingAndClosed"},ER={ACCEPTED:"disputes.status.accepted",EXPIRED:"disputes.status.expired",LOST:"disputes.status.lost",PENDING:"disputes.status.pending",RESPONDED:"disputes.status.responded",UNDEFENDED:"disputes.status.undefended",UNRESPONDED:"disputes.status.unresponded",WON:"disputes.status.won"},NR={CHARGEBACK:"disputes.type.chargeback",NOTIFICATION_OF_FRAUD:"disputes.type.notificationOfFraud",REQUEST_FOR_INFORMATION:"disputes.type.requestForInformation"},Vp=e=>{switch(e.status){case"UNDEFENDED":case"UNRESPONDED":{const t=oc(e.dueDate);if(t!=null){const n=Date.now(),s=new Date(t);if(new Date(s).setHours(s.getHours()-24)<=n)return 7;if(new Date(s).setDate(s.getDate()-SR)<=n)return 3}return 1}}return 0},zp=e=>Vp(e)>0,Kp=e=>Vp(e)>1,Es="adyen-pe-disputes-table",Xp=({dispute:e})=>{const{i18n:t}=H(),n=A(()=>t.get(ER[e.status]),[t,e]),s=A(()=>e.status==="WON"?Oe.SUCCESS:Kp(e)?Oe.ERROR:Oe.DEFAULT,[e]);return i(ot,{variant:s,label:n})},Zp={status:"disputes.status",respondBy:"disputes.respondBy",createdAt:"disputes.openedOn",paymentMethod:"disputes.paymentMethod",disputeReason:"disputes.disputeReason",reason:"disputes.reason",currency:"disputes.currency",disputedAmount:"disputes.disputedAmount",totalPaymentAmount:"disputes.totalPaymentAmount"},Id={CHARGEBACKS:{title:"disputes.empty.noChargebacksFound",message:"disputes.empty.tryDifferentSearchOrCheckAgainLaterForNewChargebacks"},FRAUD_ALERTS:{title:"disputes.empty.noFraudAlertsFound",message:"disputes.empty.tryDifferentSearchOrCheckAgainLaterForNewFraudAlerts"},ONGOING_AND_CLOSED:{title:"disputes.empty.noDisputesFound",message:"disputes.empty.tryDifferentSearchOrCheckAgainLaterForNewDisputes"}},DR=Object.keys(Zp),wt={cellContent:`${Es}__cell-content`,cellContentVStack:`${Es}__cell-content--vstack`,cellTextGrey:`${Es}__cell-text--grey`,statusContent:`${Es}__status-content`,statusContentUrgent:`${Es}__status-content--urgent`},bR=({error:e,loading:t,balanceAccountId:n,onContactSupport:s,showPagination:r,onRowClick:a,data:o,customColumns:c,activeBalanceAccount:d,statusGroup:l,...h})=>{const{i18n:u}=H(),{refreshing:p}=Ee(),{dateFormat:f}=Pt(d==null?void 0:d.timeZone),[T,g]=F(null),y=A(()=>t||p,[t,p]),_=Pe(Ie.down.xs),v=xi({fields:DR,fieldsKeys:Zp,customColumns:c,columnConfig:A(()=>({status:{visible:l==="ONGOING_AND_CLOSED"},reason:{visible:l==="FRAUD_ALERTS"&&!_,flex:2},respondBy:{visible:l==="CHARGEBACKS"},currency:{visible:!_,flex:.5},disputedAmount:{visible:l!=="FRAUD_ALERTS",position:"right"},createdAt:{visible:!_||l==="FRAUD_ALERTS"},paymentMethod:{visible:!_},disputeReason:{visible:l!=="FRAUD_ALERTS"&&!_},totalPaymentAmount:{visible:l==="FRAUD_ALERTS",position:"right"}}),[_,l])}),N=C(()=>g(null),[]),S={title:Id[l].title,message:[Id[l].message]},D=A(()=>()=>i(Fi,{error:e,errorMessage:"disputes.error.weCouldNotLoadYourDisputes",onContactSupport:s}),[e,s]);return G(()=>{y&&N()},[y,N]),i("div",{className:Es,children:[T&&i(et,{onClose:N,type:be.WARNING,className:"adyen-pe-disputes-table-alert",...T}),i(tn,{autoFitColumns:_,errorDisplay:D,error:e,columns:v,data:o,loading:y,outline:!1,onRowClick:{callback:a},emptyTableMessage:S,customCells:{status:({item:R})=>i("div",{className:M(wt.cellContent,{[wt.cellContentVStack]:_}),children:[i(Xp,{dispute:R}),_&&i(Is,{paymentMethod:R.paymentMethod})]}),reason:({item:R})=>R.reason.title,respondBy:({item:R})=>{const b=Kp(R),E=()=>i(Q,{children:[f(R.dueDate,Bl),b&&i(ue,{name:"warning-filled"})]});return i("div",{className:M(wt.cellContent,{[wt.cellContentVStack]:_}),children:[R.dueDate?i(I,{variant:O.BODY,className:M(wt.statusContent,{[wt.cellTextGrey]:_&&!b,[wt.statusContentUrgent]:b}),children:_?i(pr,{translationKey:"disputes.gridCell.dueDate",fills:{dueDate:E}}):E()}):null,_&&i(Is,{paymentMethod:R.paymentMethod})]})},currency:({item:R})=>i(ot,{children:R.amount.currency}),disputedAmount:({item:R})=>R.amount&&i(I,{variant:O.BODY,stronger:!0,children:u.amount(R.amount.value,R.amount.currency,{hideCurrency:!1})}),createdAt:({item:R})=>i("div",{className:M(wt.cellContent,{[wt.cellContentVStack]:_}),children:[i(I,{variant:O.BODY,className:M(wt.statusContent,{[wt.cellTextGrey]:_}),children:f(R.createdAt,Bl)}),_&&i(Is,{paymentMethod:R.paymentMethod})]}),paymentMethod:({item:R})=>i(Is,{paymentMethod:R.paymentMethod}),disputeReason:({item:R})=>i("span",{children:u.get(sa[R.reason.category])}),totalPaymentAmount:({item:R})=>R&&i(I,{variant:O.BODY,stronger:!0,children:u.amount(R.amount.value,R.amount.currency,{hideCurrency:!1})})},children:r&&i(tn.Footer,{children:i(Mi,{...h})})})]})},Fo=e=>{const t=new FormData;for(const[n,s]of e.entries())s instanceof File?t.set(n,s,s.name):t.set(n,s);return t},Qp=hs(void 0),OR=Ue(({dispute:e,setDispute:t,children:n})=>{const[s,r]=F("details"),[a,o]=F(null),[c,d]=F([]),[l,h]=F(null),[u,p]=F(null),f=C(()=>{h(S=>{if(S){const D=[...S.keys()].filter(R=>R!=="defenseReason");if(D.length>0){const R=Fo(S);return D.forEach(b=>R.delete(b)),R}}return S})},[]),T=C(()=>{switch(s){case"defendReasonSelectionView":r("details");break;case"accept":r("details");break;case"uploadDefenseFilesView":f(),r("defendReasonSelectionView");break;default:r("details");break}},[f,s]),g=C(()=>{o(null),d(null),h(null),p(null),t(void 0)},[t]),y=C((S,D)=>{h(R=>{const b=R?Fo(R):new FormData;return b.set(S,D,D.name),b})},[]),_=C((S,D)=>{h(R=>{if(R&&R.has(S)){const b=R.get(S),E=Fo(R);return E.delete(S),b instanceof File?E.set(D,b,b.name):E.set(D,b),E}return R})},[]),v=C(S=>{h(D=>{if(D&&D.has(S)){const R=Fo(D);return R.delete(S),R}return D})},[]),N=C(S=>{p(S)},[]);return G(()=>{h(()=>{if(a){const S=new FormData;return S.set("defenseReason",a),S}return null})},[a]),i(Qp.Provider,{value:{addFileToDefendPayload:y,applicableDocuments:c,clearFiles:f,clearStates:g,defendResponse:u,dispute:e,flowState:s,goBack:T,setApplicableDocuments:d,setFlowState:r,setDispute:t,selectedDefenseReason:a,setSelectedDefenseReason:o,defendDisputePayload:l,onDefendSubmit:N,moveFieldInDefendPayload:_,removeFieldFromDefendPayload:v},children:n})}),Dn=()=>{const e=ps(Qp);if(!e)throw new Error("useDisputeFlow must be used within DisputeFlowProvider");return e},IR=({onDisputeAccept:e})=>{const{i18n:t}=H(),{acceptDispute:n}=Ee().endpoints,{dispute:s,clearStates:r,goBack:a}=Dn(),o=q(s).current??s,c=o==null?void 0:o.dispute.pspReference,l=(o==null?void 0:o.dispute.type)==="REQUEST_FOR_INFORMATION",h=q("disputes.accept.disputeAccepted"),u=q("disputes.accept.disputeDisclaimer"),p=q("disputes.accept.chargeback"),f=q("disputes.accept.chargeback"),T=q(l);(T.current||(T.current=l))&&(h.current="disputes.accept.requestForInformationAccepted",u.current="disputes.accept.requestForInformationDisclaimer",p.current="disputes.accept.requestForInformation",f.current="disputes.accept");const[g,y]=F(!1),[_,v]=F(!1),N=is({queryFn:n,options:{onSuccess:C(()=>{r(),v(!0)},[r])}}),S=N.isLoading||_,D=g&&!S,R=C(()=>{D&&N.mutate(z,{path:{disputePspReference:c}})},[D,c,N]),b=C(()=>{S||y(W=>!W)},[S]),E=A(()=>[{title:t.get(f.current),disabled:!D,state:N.isLoading?"loading":"default",variant:te.PRIMARY,event:R,classNames:_?["adyen-pe-accept-dispute__accepted-btn"]:void 0,renderTitle:W=>_?i(Q,{children:[i(ue,{name:"checkmark-circle-fill",className:"adyen-pe-accept-dispute__accepted-icon"}),t.get("disputes.accept.accepted")]}):W},{title:t.get("disputes.goBack"),disabled:N.isLoading,variant:te.SECONDARY,event:a}],[t,R,N.isLoading,D,a,_]),P=q(!1),w=q(vn()).current;return G(()=>{P.current||_&&c&&ee(e)&&(P.current=!0,e({id:c}))},[_,c,e]),i("div",{className:"adyen-pe-accept-dispute__container",children:_?i("div",{className:"adyen-pe-accept-dispute__success",children:[i(ue,{name:"checkmark-circle-fill",className:"adyen-pe-accept-dispute__success-icon"}),i(I,{variant:O.TITLE,children:t.get(h.current)}),i(_e,{variant:te.SECONDARY,onClick:a,children:t.get("disputes.showDisputeDetails")})]}):i(Q,{children:[i(I,{className:"adyen-pe-accept-dispute__title",variant:O.TITLE,medium:!0,children:t.get(p.current)}),i(I,{variant:O.BODY,medium:!0,children:t.get(u.current)}),i("div",{className:"adyen-pe-accept-dispute__input",children:[i("input",{type:"checkbox",disabled:S,className:"adyen-pe-visually-hidden",id:w,onInput:b}),i("label",{className:"adyen-pe-accept-dispute__label",htmlFor:w,children:[g?i(ue,{name:"checkmark-square-fill"}):i(ue,{name:"square"}),i(I,{el:J.SPAN,variant:O.BODY,children:t.get("disputes.accept.iAgree")})]})]}),i("div",{className:"adyen-pe-accept-dispute__actions",children:i(fs,{actions:E})})]})})},Ke="adyen-pe-file-input",PR=["application/pdf","image/jpeg","image/jpg","image/png"],Pd=2097152,rt={DISALLOWED_FILE_TYPE:"disallowed_file_type",FILE_REQUIRED:"file_required",TOO_MANY_FILES:"too_many_files",VERY_LARGE_FILE:"very_large_file"},Ts={fileBase:`${Ke}__file`,fileButton:`${Ke}__file-button`,fileDetails:`${Ke}__file-details`,fileIcon:`${Ke}__file-icon`,fileName:`${Ke}__file-name`,fileSize:`${Ke}__file-size`};function kR({file:e,deleteFile:t,disabled:n}){const s=A(()=>Vd(e.size),[e.size]);return i("div",{className:Ts.fileBase,children:[i("div",{className:Ts.fileDetails,children:[i(ue,{name:"checkmark-circle-fill",className:Ts.fileIcon}),i("div",{className:Ts.fileName,title:e.name,children:i(I,{el:J.SPAN,variant:O.BODY,stronger:!0,children:e.name})}),i(I,{className:Ts.fileSize,el:J.SPAN,variant:O.BODY,children:s})]}),i(_e,{className:Ts.fileButton,disabled:n,variant:te.TERTIARY,onClick:t,children:[i(ue,{name:"trash-can"}),i("span",{className:"adyen-pe-visually-hidden",children:i(pr,{translationKey:"uploadedFile.remove",fills:{filename:e.name}})})]})]})}const wR=e=>A(()=>{let t=(e==null?void 0:e.current)??null,n=he;e&&(n=ee(e)?e:r=>void(e.current=r));const s=r=>{t=r,n(r)};return Object.defineProperty(s,"current",{enumerable:!0,get:()=>t,set:s})},[e]),Tt={dropzone:`${Ke}__dropzone`,dropzoneDisabled:`${Ke}__dropzone--disabled`,dropzoneDragOver:`${Ke}__dropzone--dragover`,dropzoneError:`${Ke}__dropzone--error`,label:`${Ke}__label`,labelDefault:`${Ke}__label-default-content`,labelIcon:`${Ke}__label-icon`,labelText:`${Ke}__label-text`,error:`${Ke}__error`,errorIcon:`${Ke}__error-icon`,errorText:`${Ke}__error-text`},LR=Cn((e,t)=>{const{id:n,name:s,children:r,disabled:a=!1,required:o=!1,maxFileSize:c=Pd,allowedFileTypes:d=PR,mapError:l,uploadFiles:h}=e,{i18n:u}=H(),[p,f]=F(""),[T,g]=F(),[y,_]=F(!1),v=!!p,N=s==null?void 0:s.trim(),S=A(()=>n||vn(),[n]),D=wR(t),R=L=>{var ie;Array.from(((ie=L.dataTransfer)==null?void 0:ie.types)??[]).some(le=>le==="Files")&&(L.preventDefault(),_(!0))},b=L=>{L.preventDefault(),_(!1)},E=L=>{L.preventDefault(),_(!1),j(L.dataTransfer)},P=L=>{T&&g(void 0),j(L.target)},w=async L=>{var U;L.target!==document.activeElement&&((U=L.target)==null||U.checkValidity())},W=async L=>{!p&&L.target.validity.valueMissing&&x(rt.FILE_REQUIRED)},x=C(L=>{const U=D.current;if(U){const ie=U.required;U.required=!1,U.setCustomValidity(L),f(U.validationMessage??""),U.required=ie}},[D]),j=C(L=>{const U=Sf(L);if(U.length>1)return x(rt.TOO_MANY_FILES);try{const ie=U.filter(le=>{if(!d.includes(le.type))throw rt.DISALLOWED_FILE_TYPE;const V=ee(c)?c(le.type)??Pd:c;if(le.size>V)throw g({type:le.type,limit:V}),rt.VERY_LARGE_FILE;return!0});x(""),h(ie)}catch(ie){switch(ie){case rt.DISALLOWED_FILE_TYPE:case rt.VERY_LARGE_FILE:return x(ie)}}},[d,c,x,h]);return i(Q,{children:[i("div",{role:"region",className:M(Tt.dropzone,{[Tt.dropzoneDisabled]:a,[Tt.dropzoneDragOver]:y,[Tt.dropzoneError]:v}),onDragOver:a?void 0:R,onDragLeave:a?void 0:b,onDrop:a?void 0:E,children:[i("input",{type:"file",className:"adyen-pe-visually-hidden",id:S,ref:D,name:N,disabled:a,required:o,accept:String(d),onBlur:w,onChange:P,onInvalid:W,"aria-invalid":v,"data-testId":"dropzone-input"}),i("label",{className:Tt.label,htmlFor:S,children:r??i("div",{className:M(Tt.labelDefault),children:[v?i(ue,{name:"warning-filled",className:Tt.labelIcon}):i(ue,{name:"upload",className:Tt.labelIcon}),i(I,{className:Tt.labelText,el:J.SPAN,variant:O.BODY,stronger:!0,children:u.get("uploadFile.browse")})]})})]}),v&&i("div",{className:Tt.error,children:[i(ue,{name:"cross-circle-fill",className:Tt.errorIcon}),i(I,{className:Tt.errorText,el:J.SPAN,variant:O.BODY,children:ee(l)?l(p,T?{size:T.limit,type:T.type}:void 0):u.get(p)})]})]})}),Jp=Cn(({onChange:e,mapError:t,onDelete:n,...s},r)=>{const[a,o]=F([]),c=q(a),d=a[0],{i18n:l}=H(),{disabled:h}=s,u=C(g=>{switch(g){case rt.DISALLOWED_FILE_TYPE:return l.get("inputError.disallowedFileType");case rt.FILE_REQUIRED:return l.get("inputError.fileRequired");case rt.TOO_MANY_FILES:return l.get("inputError.tooManyFiles");case rt.VERY_LARGE_FILE:return l.get("inputError.veryLargeFile")}},[l]),p=A(()=>ee(t)?t:u,[t]),f=C(g=>{h||(o(y=>{const _=y.findIndex(N=>N===g);if(_<0)return y;const[...v]=y;return v.splice(_,1),v}),n==null||n())},[h,n]),T=C(g=>{h||o(y=>y.length===0&&g.length===0?y:g)},[h]);return G(()=>{c.current!==a&&(c.current=a,e==null||e([...a]))},[a,e]),i("div",{className:Ke,children:d?i(kR,{disabled:h,file:d,deleteFile:()=>f(d)}):i(LR,{...s,ref:r,mapError:p,uploadFiles:T})})}),FR={title:"clearingText",help:"descriptionOfDisputeReason"},MR={title:"latestRecurringTransactions",help:"latestRecurringTransactions"},xR={title:"acquirerRepresentmentForm",help:"acquirerRepresentmentFormAutomaticallyGenerated"},BR={title:"acquirerRetrievalFulfilmentForm",help:"acquirerRetrievalFulfilmentFormAutomaticallyGenerated"},$R={title:"automaticallyGeneratedTransactionDetails",help:"automaticallyGeneratedTransactionDetails"},UR={title:"proofOfAddendum",help:"cardholderResponsibleForAddendumTransaction"},WR={title:"additionalInformation",help:"docIdentifyTransaction"},HR={title:"additionalTransactions",help:"additionalTransactionsConnectedWithDisputedFlight"},GR={title:"alternativeDefenseMaterial",help:"docRemediesChargeback"},YR={title:"amexFaxCover",help:"coverPageForAmexDisputes"},qR={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},jR={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},VR={title:"rebuttalCancellationNotAccepted",help:"rebuttalStatingCancellationNotAccepted"},zR={title:"evidenceCardHolderParticipation",help:"docProvingCardHolderParticipated",helpitems:["receiptOrOther","customerWrittenConfirmation","writtenCorrespondenceExchanged"]},KR={title:"proofRenewedMembership",help:"proofShowingCardholderRenewedMembership"},XR={title:"proofCardPresence",help:"proofCardAndCardholderSignature"},ZR={title:"docChargebackCodeNotApplicable"},QR={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},JR={title:"defenseMaterial",help:"docViaFraudReporter"},eC={title:"CopyOfSalesDraftTitle",help:"CopyOfSalesDraftDetails"},tC={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},nC={title:"defenseMaterial",help:"docCorrectCurrency"},sC={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},rC={title:"documentShipmentDate",help:"documentContainingImportantShipmentData"},oC={title:"defenseMaterial",help:"docRemediesChargeback"},iC={title:"disclosureAtPointOfInteraction",help:"rebuttalGivenToCardholder"},aC={title:"firstChargebackNumberAndDate",help:"numberAndDateOfOriginalChargeback"},cC={title:"compellingEvidence",help:"evidenceProofingParticipationOfCardholder"},lC={title:"flightManifest",help:"flightManifestShowingCardholderName"},dC={title:"flightTicket",help:"flightTicketWithCardholderName"},uC={title:"deliveryOfFlightTicketAtAddress",help:"receiptOfFlightTicketAtBillingAddress"},hC={title:"flightTicketUsed",help:"proofAirlineTicketsWereUsed"},pC={title:"flightTookPlace",help:"proofFlightTookPlace"},fC={title:"frequentFlyerInformation",help:"creditsOfMilesShowingConnectionToCardholder"},mC={title:"merchantWrittenRebuttal",help:"statementMerchantDidNotReceiveGoods"},_C={title:"merchantWrittenRebuttal",help:"writtenRebutalGoodsRepairedOrReplaced"},gC={title:"merchantWrittenRebuttal",help:"proofGoodsWereDeliveredAsDescribed"},TC={title:"proofValidIncreaseOfAmount",help:"cardholderResponsibleForDisputedAmount"},yC={title:"explanation",help:"explanationWhyCancellationCodeInvalid"},AC={title:"proofOfInvalidChargeback",help:"chargebackRemediedOrInvalid"},vC={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},RC={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},CC={title:"merchandiseDescription",help:"descriptionOfMerchandiseOrServices"},SC={title:"defenseMaterial",help:"docMerchandiseNotCounterfeit"},EC={title:"proofOfRecurringTransaction",help:"docAllOfFollowing",helpitems:["evidenceTransactionWasRecurring","moreThanOneTransactionProcessed","previousTransactionsNotDisputed"]},NC={title:"mpiData",help:"resultsOfMpiCalls"},DC={title:"proofOfNoCancellation",help:"proofRecurringContractNotCancelledAtTimeOfSettlement"},bC={title:"proofOfNoChargebackReceived",help:"proofMerchantHadNotReceivedPreviousChargeback"},OC={title:"proofOfNoChargebackReceived",help:"proofMerchantHadNotReceivedPreviousChargebackAutoGenerated"},IC={title:"noNotification",help:"proofMerchantNotNotifiedOfCancellation"},PC={title:"originalAmount",help:"originalAmountIfDisputedRepresentsPartialShipment"},kC={title:"paperAirlineTicket",help:"docCardholderIssuedPaperAirlineTickets"},wC={title:"passengerId",help:"passengerIdLinkedToCardholder"},LC={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},FC={title:"appropriateExplanation",help:"appropriateExplanationAndDocTwoSeparateTransactions"},MC={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},xC={title:"avsDocumentation",help:"documentationOfPositiveAvsResponseXOrY"},BC={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},$C={title:"signedTerminalReceipt",help:"printedSignedReceipt"},UC={title:"proofOfDelayedDelivery",help:"ifDelayedProofShowingMerchantAbleToProvideServices"},WC={title:"proofOfAccountTakeover",help:"provingTransactionResultedFromAccountTakeover"},HC={title:"proofCardPresence",help:"docTransactionOccurredOnPos"},GC={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},YC={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},qC={title:"signatureOrChipPinEvidence"},jC={title:"proofProvidedMerchandise",help:"proofGoodsServicesWereProvided"},VC={title:"proofOfNoShow",help:"merchantObtainedCardAtTimeReservationMade"},zC={title:"proofOfRecurringTransaction",help:"docAllOfFollowing",helpitems:["evidenceTransactionWasRecurring","moreThanOneTransactionProcessed","previousTransactionsNotDisputed"]},KC={title:"proofOfRetailSale",help:"copyOfTid"},XC={title:"reasonForInvalidation",help:"reasonForInvalidationOfChargeback"},ZC={title:"retrievalRequestFulfilled",help:"autoGeneratedDocRetrievalRequestFulfilled"},QC={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},JC={title:"defenseMaterial",help:"docTermsOfSaleNotMisrepresented"},eS={title:"shipmentDocumentation",help:"merchandiseSentToAvsConfirmedBillingAddress"},tS={title:"shipToAddress",help:"shipToAddressIfApplicable"},nS={title:"SupplementalDocumentsTitle",help:"SupplementalDocumentsDetails"},sS={title:"TEDocumentTitle",help:"TEDocumentDetails"},rS={title:"copyOfInvoice",help:"copyOfInvoiceOrOtherRelevantTransactionDetails"},oS={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},iS={title:"docTwoDifferentTransactions",help:"docsTwoTransactionsWithSameShopper"},aS={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},cS={title:"memberMessageText",help:"memberMessageTextSentToSchemes"},lS={title:"reasonableAmount",help:"cardholderAgreedToAmountRange"},dS={title:"duplicateProcessing",help:"duplicateProcessingHelp"},uS={title:"chargeToWrongAccountNumber",help:"chargeToWrongAccountNumberHelp"},hS={title:"SplitSales",help:"SplitSalesHelp"},pS={title:"missingSignature",help:"missingSignatureHelp"},fS={title:"processingError",help:"processingErrorHelp"},mS={title:"expiredCard",help:"expiredCardHelp"},_S={title:"latePresentment",help:"latePresentmentgHelp"},gS={title:"falseTransaction",help:"falseTransactionHelp"},TS={title:"authorizationNotObtained",help:"authorizationNotObtainedHelp"},yS={title:"transactionNotRecognizedContactlessAndCardNotPresented",help:"transactionNotRecognizedContactlessAndCardNotPresentedHelp"},AS={title:"transactionNotRecognizedChipLiabilityShift",help:"transactionNotRecognizedChipLiabilityShiftHelp"},vS={title:"deffectiveMerchandise",help:"deffectiveMerchandiseHelp"},RS={title:"merchandiseNotReceived",help:"merchandiseNotReceivedHelp"},CS={title:"serviceNotRendered",help:"serviceNotRenderedHelp"},SS={title:"cardRecoveryBulletinOrExceptionFile",help:"cardRecoveryBulletinOrExceptionFileHelp"},ES={title:"transactionAfterReservationCancelled",help:"transactionAfterReservationCancelledHelp"},NS={title:"differentSignature",help:"differentSignatureHelp"},DS={title:"retrievalRequestNotHonored",help:"retrievalRequestNotHonoredHelp"},bS={title:"creditNotProcessed",help:"creditNotProcessedHelp"},OS={title:"paidByOtherMeansThanJCBCard",help:"paidByOtherMeansThanJCBCardHelp"},IS={title:"nonMatchingAccountNumber",help:"nonMatchingAccountNumberHelp"},PS={title:"merchantFraudPerformanceProgram",help:"merchantFraudPerformanceProgramHelp"},kS={title:"other",help:"otherHelp"},wS={title:"proofOfFulfillment",help:"proofShowingTrackingInformation"},LS={title:"proofOfRefund",help:"uploadListOfRefundIds"},FS={title:"merchandiseNotAsDescribed",help:"documentCanBetUrlReturnPolicy"},MS={title:"cancelledRecurringBilling",help:"documentCanBeSubscriptionAgreement"},xS={title:"incorrectAmount",help:"provideRefundId"},BS={title:"incorrectAmount",help:"provideRefundId"},$S={title:"unauthorisedReason",help:"documentCanBeProofOfDelivery"},US={title:"creditNotProcessedReason",help:"documentCanBeCreditReasonDue"},WS={AcquirerMemberMessageText:FR,AcquirerRecurringTransactionDetails:MR,AcquirerRepresentmentForm:xR,AcquirerRetrievalFulfilmentForm:BR,AcquirerRFItransactionDetails:$R,AddendumDocumentation:UR,AdditionalInformation:WR,AdditionalTransactions:HR,AlternativeDefenseMaterial:GR,AmexFaxCover:YR,ARDnotProvided:qR,AuthorisedTransaction:jR,CancellationNeverAccepted:VR,CardholderIdentification:zR,CardholderRenewedMembership:KR,CardPresent:XR,ChargebackCodeNotApplicable:ZR,ChipLiabilityShift:QR,ChipTransactionReportedToSAFE:JR,CopyOfSalesDraft:eC,CompellingEvidence:tC,CorrectTransactionCurrency:nC,CreditPreviouslyIssued:sC,DateMerchandiseShipped:rC,DefenseMaterial:oC,DisclosureAtPointOfInteraction:iC,DuplicateChargeback:aC,EvidenceOfCardholderParticipation:cC,FlightManifest:lC,FlightTicket:dC,FlightTicketAtBillingAddress:uC,FlightTicketUsed:hC,FligthTookPlace:pC,FrequentFlyer:fC,GoodsNotReturned:mC,GoodsRepairedOrReplaced:_C,GoodsWereAsDescribed:gC,IncreasedTransactionAmount:TC,InvalidCancellationCode:yC,InvalidChargeback:AC,LiabilityShiftFullUCAF:vC,LiabilityShiftMerchantUCAF:RC,MerchandiseDescription:CC,MerchandiseNotCounterfeit:SC,MerchantProofOfRecurringTransaction:EC,MPIdata:NC,NotCancelled:DC,NotChargebacked:bC,NotChargebackedAuto:OC,NotNotified:IC,OriginalAmount:PC,PaperAirlineTicket:kC,PassengerIdentification:wC,PastChargebackTimeLimit:LC,PaymentByOtherMeans:FC,PINTransaction:MC,PositiveAVS:xC,PresentmentWithinTimeLimit:BC,PrintedSignedTerminalReceipt:$C,ProofOfAbilityToProvideServices:UC,ProofOfAccountTakeover:WC,ProofOfAttendedPOSTerminal:HC,ProofOfCardPresenceAndSignatureChipNoPIN:GC,ProofOfCardPresenceAndSignatureWithTerminalReceipt:YC,ProofOfCardPresenceSignatureOrChipPIN:qC,ProofOfGoodsOrServicesProvided:jC,ProofOfNoShow:VC,ProofOfRecurringTransaction:zC,ProofOfRetailSaleRatherThanCredit:KC,ReasonForReturn:XC,RetrievalRequestFulfilled:ZC,ReturnedMerchandiseNotReceived:QC,SaleTermsNotMisrepresented:JC,ShippedToAVS:eS,ShipToAddress:tS,SupplementalDocuments:nS,TEDocument:sS,TIDorInvoice:rS,TransactionNotPOS:oS,TwoDifferentTIDs:iS,TwoPINTransactions:aS,TwoPriorFraudChargebacks:cS,UnreasonableAmount:lS,DuplicateProcessing:dS,ChargeToWrongAccountNumber:uS,SplitSales:hS,MissingSignature:pS,ProcessingError:fS,ExpiredCard:mS,LatePresentment:_S,FalseTransaction:gS,AuthorizationNotObtained:TS,TransactionNotRecognizedContactlessAndCardNotPresented:yS,TransactionNotRecognizedChipLiabilityShift:AS,DeffectiveMerchandise:vS,MerchandiseNotReceived:RS,ServiceNotRendered:CS,CardRecoveryBulletinOrExceptionFile:SS,TransactionAfterReservationCancelled:ES,DifferentSignature:NS,RetrievalRequestNotHonored:DS,CreditNotProcessed:bS,PaidByOtherMeansThanJCBCard:OS,NonMatchingAccountNumber:IS,MerchantFraudPerformanceProgram:PS,Other:kS,ProofOfFulfillment:wS,ProofOfRefund:LS,MerchandiseNotAsDescribedReason:FS,CancelledRecurringBillingReason:MS,IncorrectAmountReason:xS,ProofOfRefundForAmountDifference:BS,UnauthorisedReason:$S,CreditNotProcessedReason:US},HS={title:"atmDispute",help:"invalidChargebackReasonCode"},GS={title:"accountTakeover",help:"transactionFromAccountTakeover"},YS={title:"additionalInformation",help:"merchantCanProvideAdditionalInformation"},qS={title:"airlineCompellingEvidence",help:"evidenceCardholderAuthorizedTransaction"},jS={title:"airlineFlightProvided",help:"shopperUsedAirlineTicket"},VS={title:"responseToRfiAirlines",help:"provideTransactionalInfoTravelDetails"},zS={title:"transactionWasAuthorised",help:"authorisationReceivedForAmount"},KS={title:"autoResponseToRfi",help:"autoResponseSentToIssuer"},XS={title:"cvc2ValidationProgram",help:"transactionFallsCvc2ValidationProgram"},ZS={title:"cancellationOrReturns",help:"useThisDefenseReasonIfApplicable",helpitems:["noCreditSlip","returnNotAccepted","merchandiseNotReturned"]},QS={title:"cancellationContractFailed",help:"cardholderDidNotMeetCancellationTerms"},JS={title:"responseToRfiCarRental",help:"provideTransactionalInfoTravelDetails"},eE={title:"accountNumberNotListedInExceptions",help:"accountNumberNotListedInExceptionsFor60Days"},tE={title:"reponseToRfi",help:"provideTransactionalInformation"},nE={title:"fraudEvidence"},sE={title:"cbCodeNotApplicable",help:"firstChargebackCodeNotApplicable"},rE={title:"reponseToRfiCardPresent",help:"provideTransactionalInformation"},oE={title:"cardholderNotifiedButNoReply",help:"cardholderNotifiedBeforeRecurringTransaction"},iE={title:"cardholderParticipated",help:"evidenceThatCardholderParticipated"},aE={title:"membershipRenewedAfterCancellation",help:"cardholderCancelledRecurringServiceButRenewedLater"},cE={title:"chipLiabilityShift",help:"transactionBetweenChipLiabilityShiftProgramCustomers"},lE={title:"chipTransactionReportedSAFE",help:"intraregionalTransactionReportedSAFE"},dE={title:"reponseToRfi",help:"provideTransactionalInformation"},uE={title:"compellingEvidence",help:"evidenceCardholderAuthorizedTransaction"},hE={title:"compellingEvidenceRecurringTransactions",help:"evidenceServicesProvidedAndReceivedWrittenCorrespondence"},pE={title:"correctTransactionAmount",help:"transactionInformationDocument"},fE={title:"correctTransactionCurrency",help:"chargebackInvalidCorrectAmountAndCurrencyProvided"},mE={title:"correctTransactionDateProvided",help:"acquirerProvidesCorrectDateWithinTimeLimit"},_E={title:"creditOrCancellationPolicyDisclosed",help:"creditOrCancellationPolicyDisclosedToCardholder"},gE={title:"creditPreviouslyIssued",help:"transactionAmountAlreadyRefunded"},TE={title:"deficiencyCorrected",help:"proofDeficiencyCorrected"},yE={title:"disputedSurcharge",help:"surchargeCorrectlyProcessed"},AE={title:"disputedSurchargeIncorrectCalculation",help:"surchargeIncorrectlyCalculatedByIssuer"},vE={title:"duplicateChargeback",help:"issuerProcessedChargebackMoreThanOnce"},RE={title:"emvLiabilityShift",help:"emvDeviceNonEmvCard"},CE={title:"emergencyPaymentAuthorizationService",help:"transactioAuthorisedEmergencyPaymentAuthorizationService"},SE={title:"faceToFaceTransactionNoConflictingInformation",help:"transactionWasInFaceToFaceEnvironment"},EE={title:"faceToFaceTransactionWithConflictingInformation",help:"de22DontMatchInFaceToFaceTransaction"},NE={title:"goodsNotReturned",help:"cardholderShouldHaveReturnedGoods"},DE={title:"goodsOrServicesProvided",help:"proofCardholderReceivedMerchandise",helpitems:["signedImprintedSalesSlipInvoicePosReceipt","parcelServiceReceipt","waiverFormAbsolvingMerchantResponsibility"]},bE={title:"goodsRepairedOrReplaced",help:"goodsWereRepairedOrReplaced"},OE={title:"goodsWereAsDescribed",help:"evidenceGoodsNotDamaged"},IE={title:"identifiedAddendum",help:["cardholderResponsibleForAddendumTransaction","cardholderResponsibleForDisputedAmount","cardholderBilledForSeparateAdditionalAmount"]},PE={title:"documentationReceivedWasIllegible",help:"firstChargebackInvalid"},kE={title:"increasedTransactionAmount",help:"documentationIncreasedDebitCardholderAccount"},wE={title:"invalidAcquirerReferenceData",help:"invalidReferenceDataDocumentationNotRequired"},LE={title:"invalidCancellationCode",help:"cancellationCodeWasInvalidAsShownByExplanationProvided"},FE={title:"invalidChargeback",help:["firstChargebackDoesNotMeetPrerequisites","thisReasonIsTechnical"]},ME={title:"invalidChargeback",help:["firstChargebackDoesNotMeetPrerequisites","thisReasonIsTechnical"]},xE={title:"chargebackBundlingInvalid",help:"chargebackBundlingInvalid"},BE={title:"invalidMessageText",help:"formatCbmmddyyArdXxxExpected"},$E={title:"invalidMessageText",help:"formatMultipleTransactionsNnnExpected"},UE={title:"invalidMessageText",help:"formatRpcsMmddyyExpected"},WE={title:"invalidChargebackBasedOnMcc",help:"merchantCantReceiveThisChargebackBasedOnTheirMcc"},HE={title:"reponseToRfi",help:"provideTransactionalInformation"},GE={title:"justifiedDelayedPresentment",help:"delayInSubmittingTransaction"},YE={title:"liabilityShiftFullAuthenticated",help:"transactionIssuerApproved3dSecureAuthenticated"},qE={title:"3dSecureFullyAuthenticatedTransaction",help:"transactionApproved3dSecureAuthenticated"},jE={title:"3dSecureLiabilityShiftNotFullyAuthenticated",help:"transactionNotFully3dSecureAuthenticated"},VE={title:"merchandiseWasNotCounterfeit"},zE={title:"merchandiseWasReceivedByShopper",help:"proofCardholderReceivedMerchandise",helpitems:["signedImprintedSalesSlipInvoicePosReceipt","parcelServiceReceipt","waiverFormAbsolvingMerchantResponsibility"]},KE={title:"provideMissingInformation",help:"merchantProvideMissingDocuments"},XE={title:"invalidMessageText",help:"issuerDidNotIncludeTwoSetsOfArns"},ZE={title:"noShowTransaction",help:"transactionWasResultOfGuaranteedReservation"},QE={title:"requiredDocumentationNotReceived",help:"issuerDidNotProvideRequiredDocumentation"},JE={title:"requiredDocumentationNotReceived",help:"issuerDidNotProvideRequiredDocumentation"},eN={title:"not3dSecureTransaction",help:"chargebackCodeNA3dSecureNotOffered"},tN={title:"serviceNotCancelled",help:"serviceNotCancelledEvidence"},nN={title:"noPriorChargebackReceived",help:"claimNotJustifiedSinceTransactionNotChargebacked"},sN={title:"noPriorChargebackReceived",help:"transactionNotChargebackedAutoDefense"},rN={title:"merchantNotNotifiedOfCancellation",help:"serviceCancelledButMerchantNotNotified"},oN={title:"additionalInformation",help:"docToProveNoPaymentByOtherMean"},iN={title:"transactionNotRecurring",help:"transactionNotRecurringTransactionInstallment"},aN={title:"pinTransaction",help:"pinUsedToVerifyCardholder"},cN={title:"pastChargebackTimeLimit",help:"chargebackReceivedAfterMastercardTimeLimit"},lN={title:"paypassTransaction",help:"paypassAmountBelowProtectionAmount"},dN={title:"paymentByOtherMeans",help:"validityOfTransactionChargedExplanation"},uN={title:"transactionSettledWithinTimeLimit",help:"timeBetweenAuthorisationAndSettlementWithinTimeLimits"},hN={title:"noPriorChargebackReceived",help:"previousChargebackCancellingRecurringContract"},pN={title:"chipTransaction",help:"cardPresentAndChipUsedNoPinProvided"},fN={title:"transactionsInitiatedDueToLossTheftOrDamages",help:"receiptWithItemsBilledBecauseOfLossTheftDamages"},mN={title:"proofOfCardPresenceMastercardCorporateFleet",help:"cardAndSignatureForCorporateFleetCardTransaction"},_N={title:"proofOfCardPresenceAvailableNotAuthorisedMastercardNetwork",help:"cardWithSignatureNotProcessedMastercardNetwork"},gN={title:"signedTerminalReceiptAvailable",help:"posTransactionAndSignedTerminalReceiptAvailable"},TN={title:"cardPresenceProof",help:"posTransactionCardholderWasPresentProof"},yN={title:"provideInformationForCollectionOrFraudCase"},AN={title:"purchaseProperlyPosted",help:"transactionWasProperlyIdentifiedAsInstallmentTransaction"},vN={title:"qpsTransaction",help:"qpsTransactionWithAmountLessThanChargebackProtectionAmount"},RN={title:"recurringTransactionCompellingEvidence",help:"autoGeneratedRecurringTransactionDetails"},CN={title:"recurringTransactionCompellingMerchantEvidence",help:"merchantCanProvideAdditionalCompellingEvidence"},SN={title:"notAgreeWithRefund",help:"shopperClaimsRefundWasPromisedButNotExecuted"},EN={title:"retrievalRequestFulfilled",help:"documentsSentToFulfillRetrievalRequest"},NN={title:"buyerExceededWindowToFileReturn",help:"uploadReturnPolicyDocument"},DN={title:"termsOfSaleWereNotMisrepresented"},bN={title:"scanningError",help:"defenseReasonIfProblemsWithScans"},ON={title:"goodsOrServicesProvided",help:"merchantProvidedServicesToCardholderProof"},IN={title:"servicesProvidedAfterCancellation",help:"servicesProvidedAndUsedAfterCancellation"},PN={title:"addressVerificationService",help:"addressMerchandiseSentAvsConfirmed"},kN={title:"addressVerificationServiceAdditionalInformation",help:"addressMerchandiseSentAvsConfirmed"},wN={title:"supplyDefenseMaterial",help:"fallbackDefenseReasonCode"},LN={title:"supplyDefenseMaterial",help:"fallbackDefenseReasonCode"},FN={title:"manyFraudulentChargebacks",help:"issuerHasInitiatedTooManyFraudulentDisputes"},MN={title:"authorisedOnline",help:"transactionWasAuthorisedOnline"},xN={title:"notPosTransaction",help:"transactionWasECommerceGivenChargebackReasonNotApplicable"},BN={title:"twoDifferentTransactions",help:"twoSeparateTransactions"},$N={title:"twoDifferentTidsNonAtm",help:"twoDifferentTidsWithSameCardholderAccount"},UN={title:"pinTransaction",help:"pinForOneOrBothTransactions"},WN={title:"twoPreviousFraudRelatedChargebacks",help:"prevChargedbackTwoTransactionsWithSameAccount"},HN={title:"unfoundedCardholderDispute",help:"acquirerDefendChargebackIfIssuerRequested"},GN={title:"unreasonableAmount",help:"cardholderAgreedToAmountAsReasonable"},YN={ATMDispute:HS,AccountTakeover:GS,AdditionalInformation:YS,AirlineCompellingEvidence:qS,AirlineFlightProvided:jS,AirlineRFIresponse:VS,AuthorisedTransaction:zS,AutomaticRFIresponse:KS,CVC2ValidationProgram:XS,CancellationOrReturns:ZS,CancellationTermsFailed:QS,CarRentalRFIresponse:JS,CardNotOnExceptionFile:eE,CardNotPresentRFIresponse:tE,CardPresentFraud:nE,CardPresentNotApplicable:sE,CardPresentRFIresponse:rE,CardholderNotReplied:oE,CardholderParticipated:iE,CardholderRenewedMembership:aE,ChipLiabilityShift:cE,ChipTransactionReportedToSAFE:lE,CieloRFIresponse:dE,CompellingEvidence:uE,CompellingEvidenceRecurringTransactions:hE,CorrectTransactionAmount:pE,CorrectTransactionCurrency:fE,CorrectTransactionDate:mE,CreditOrCancellationPolicyProperlyDisclosed:_E,CreditPreviouslyIssued:gE,DeficiencyCorrected:TE,DisputedSurcharge:yE,DisputedSurchargeIncorrectProratedCalculation:AE,DuplicateChargeback:vE,EMVLiabilityShift:RE,EmergencyPaymentAuthorizationService:CE,FaceToFace:SE,FaceToFaceConflictingMessages:EE,GoodsNotReturned:NE,GoodsOrServicesProvided:DE,GoodsRepairedOrReplaced:bE,GoodsWereAsDescribed:OE,IdentifiedAddendum:IE,IllegibleDocumentationReceived:PE,IncreasedTransactionAmount:kE,InvalidARD:wE,InvalidCancellationCode:LE,InvalidChargeback:FE,InvalidChargebackAllocation:ME,InvalidChargebackBundling:xE,InvalidDE72CB:BE,InvalidDE72MultipleTransactions:$E,InvalidDE72RPCS:UE,InvalidReasonCodeForMCC:WE,JCBRFIResponse:HE,JustifiedDelayedPresentment:GE,LiabilityShiftFullAuthenticated:YE,LiabilityShiftFullUCAF:qE,LiabilityShiftMerchantUCAF:jE,MerchandiseNotCounterfeit:VE,MerchandiseReceived:zE,MissingInformation:KE,NoARDprovidedInMessageText:XE,NoShowTransaction:ZE,NonReceiptOfRequiredDocuments:QE,NonReceiptOfRequiredDocumentsAutoDefense:JE,Not3DSecure:eN,NotCancelled:tN,NotChargebacked:nN,NotChargebackedAuto:sN,NotNotified:rN,NotPaidByOtherMeans:oN,NotRecurring:iN,PINTransaction:aN,PastChargebackTimeLimit:cN,PayPassTransaction:lN,PaymentByOtherMeans:dN,PresentmentWithinTimeLimit:uN,PreviousTransactionNotChargebacked:hN,ProofOfCardPresenceAndSignatureChipNoPIN:pN,ProofOfCardPresenceAndSignatureLossTheftOrDamage:fN,ProofOfCardPresenceAndSignatureMasterCardCorporateFleetCard:mN,ProofOfCardPresenceAndSignatureNotMasterCardWorldWideNetwork:_N,ProofOfCardPresenceAndSignatureWithTerminalReceipt:gN,ProofOfCardPresenceAndSignatureWithoutTerminalReceipt:TN,ProvideInformation:yN,PurchaseProperlyPosted:AN,QPSTransaction:vN,RecurringTransactionsCompellingEvidence:RN,RecurringTransactionsCompellingMerchantEvidence:CN,RefundNotAgreed:SN,RetrievalRequestFulfilled:EN,ReturnPeriodExpired:NN,SaleTermsNotMisrepresented:DN,ScanningError:bN,ServicesProvided:ON,ServicesProvidedAfterCancellation:IN,ShippedToAVS:PN,ShippedToAVSAdditionalInformation:kN,SupplyDefenseDocument:wN,SupplyDefenseMaterial:LN,TooManyFraudulentChargebacks:FN,TransactionAuthorisedOnline:MN,TransactionNotPOS:xN,TwoDifferentTIDs:BN,TwoDifferentTIDsPOS:$N,TwoPINTransactions:UN,TwoPriorFraudChargebacks:WN,UnfoundedCardholderDispute:HN,UnreasonableAmount:GN},va=(e,t,n)=>{const s=`${t}.${n}`;return e.has(s)?e.get(s):void 0},ef=(e,t,n,s)=>{const r=t[n];if(!r)return;const a=va(e,s,r.title),o=r.help?Array.isArray(r.help)?r.help:[r.help]:void 0,c=o==null?void 0:o.map(l=>va(e,s,l)).filter(l=>l!==void 0),d=[];return r.helpitems&&r.helpitems.forEach(l=>{const h=va(e,s,l);h&&d.push(h)}),{title:a||"",...c!=null&&c.length?{primaryDescriptionItems:c}:{},...d!=null&&d.length?{secondaryDescriptionItems:d}:{}}},ra=(e,t)=>ef(e,WS,t,"disputes.defenseDocument"),rc=(e,t)=>ef(e,YN,t,"disputes.defenseReason"),Mo={"2MB":2097152,"10MB":10485760},tf=["application/pdf","image/jpeg","image/jpg","image/tiff"],nf={"application/pdf":Mo["2MB"],"image/jpeg":Mo["10MB"],"image/jpg":Mo["10MB"],"image/tiff":Mo["10MB"]},qN=({document:e,disabled:t,required:n,mapError:s})=>{const{i18n:r}=H(),{title:a,primaryDescriptionItems:o}=A(()=>ra(r,e),[r,e])||{},{removeFieldFromDefendPayload:c,addFileToDefendPayload:d}=Dn();return i("div",{className:"adyen-pe-defend-dispute-document-upload",children:[i("div",{children:[i(I,{strongest:!0,className:"adyen-pe-defend-dispute-document-upload__title",variant:O.BODY,el:J.DIV,children:a||e}),o&&o.length>0?o.map((l,h)=>i(I,{className:"adyen-pe-defend-dispute-document-upload__description",variant:O.BODY,children:l},`${h}-description`)):null]}),i(Jp,{allowedFileTypes:tf,maxFileSize:l=>nf[l],mapError:s,onDelete:()=>{e&&c(e)},disabled:t,required:n,onChange:l=>{l[0]?d(e,l[0]):c(e)}},e)]})},Rr="adyen-pe-defend-dispute-document-upload-box",Cr={deleteButton:Rr+"__delete-button-container",dropdownList:Rr+"__dropdown-list",dropdownListMobile:Rr+"__dropdown-list--mobile",extraDocuments:Rr+"__extra-documents-selector",extraDocumentsTitle:Rr+"__extra-documents-selector-title"},kd=({items:e,selection:t,setSelection:n,disabled:s,required:r,title:a,index:o,onRemoveOption:c,mapError:d})=>{var y,_;const{i18n:l}=H(),{addFileToDefendPayload:h,moveFieldInDefendPayload:u,removeFieldFromDefendPayload:p}=Dn(),f=C(v=>ra(l,v),[l]),T=Pe(Ie.down.xs),g=C(v=>{t&&u(t,v),n(v,o)},[o,u,t,n]);return G(()=>{const v=e.filter(({disabled:N})=>N!==!0);v.length===1&&!t&&g(v[0].id)},[e,t,g]),i("div",{className:Cr.extraDocuments,children:[i("div",{className:Cr.deleteButton,children:[i(I,{strongest:!0,className:Cr.extraDocumentsTitle,variant:O.BODY,el:J.DIV,children:a}),c&&i(_e,{disabled:s,onClick:()=>o!==void 0&&!s&&c(o),variant:te.TERTIARY,fullWidth:!1,align:"center",children:i(ue,{name:"trash-can"})})]}),i("div",{children:[i(Bn,{onChange:v=>{const N=v.target.value;g(N)},filterable:!1,selected:t,readonly:s,multiSelect:!1,items:e,popoverClassNameModifiers:[M(Cr.dropdownList,{[Cr.dropdownListMobile]:T})],showOverlay:!1,placeholder:l.get("disputes.uploadDocuments.selectDocumentType"),fixedPopoverPositioning:!0}),t&&((_=(y=f(t))==null?void 0:y.primaryDescriptionItems)==null?void 0:_.map(v=>i(I,{className:"adyen-pe-defend-dispute-document-upload__description",variant:O.BODY,el:J.PARAGRAPH,children:v},v)))]}),i(Jp,{maxFileSize:v=>nf[v],allowedFileTypes:tf,mapError:d,onDelete:()=>{t&&p(t)},disabled:s||!t,required:r,onChange:v=>{t&&(v[0]?h(t,v[0]):p(t))}})]})},jN=["disputes.documentRequirements.mustBeInEnglish","disputes.documentRequirements.recommendedSize","disputes.documentRequirements.acceptableFormatAndSize"],VN=()=>{const{i18n:e}=H(),{defendDispute:t}=Ee().endpoints,{clearFiles:n,clearStates:s,dispute:r,applicableDocuments:a,goBack:o,defendDisputePayload:c,defendResponse:d,onDefendSubmit:l,removeFieldFromDefendPayload:h,setFlowState:u}=Dn(),p=r==null?void 0:r.dispute.pspReference,[f,T]=F(void 0),[g,y]=F([]),_=C(()=>{s(),u("details")},[s,u]),v=C((V,Z)=>{var ge,Ne;switch(V){case rt.DISALLOWED_FILE_TYPE:return e.get("inputError.disallowedFileType");case rt.FILE_REQUIRED:return e.get("disputes.inputError.uploadAtLeastOneSupportingDocumentToContinue");case rt.TOO_MANY_FILES:return e.get("inputError.tooManyFiles");case rt.VERY_LARGE_FILE:return e.get("disputes.inputError.fileIsOverSizeLimitForTypeChooseASmallerFileAndTryAgain",{values:{size:(Z==null?void 0:Z.size)===void 0?void 0:Vd(Z.size),type:(Ne=(ge=Z==null?void 0:Z.type)==null?void 0:ge.replace(/^([^/]+\/)*/gi,""))==null?void 0:Ne.toUpperCase()}});default:return e.get("disputes.inputError.somethingWentWrongPleaseCheckYourDocuments")}},[e]),{requiredDocuments:N,optionalDocuments:S,oneOrMoreDocuments:D}=A(()=>{const V={requiredDocuments:[],optionalDocuments:[],oneOrMoreDocuments:[]};return(a??[]).forEach(({documentTypeCode:Z,requirementLevel:ge})=>{var me;const Ne=((me=ra(e,Z))==null?void 0:me.title)||Z;switch(ge){case"REQUIRED":V.requiredDocuments.push(Z);break;case"OPTIONAL":V.optionalDocuments.push({id:Z,name:Ne});break;case"ONE_OR_MORE":V.oneOrMoreDocuments.push({id:Z,name:Ne});break}return V}),V},[a,e]),R=A(()=>{if(!c)return!1;let V=N.every(Z=>c.get(Z)instanceof File);return D.length>0&&V&&(V=D.some(Z=>c.get(Z.id)instanceof File)),V},[c,D,N]),b=is({queryFn:t,options:{onSuccess:C(()=>{n(),l("success"),u("defenseSubmitResponseView")},[n,l,u]),onError:C(()=>{n(),l("error"),u("defenseSubmitResponseView")},[n,l,u])}}),E=d==="success",P=b.isLoading||E,w=c&&R&&!P,W=C(()=>{w&&b.mutate({contentType:"multipart/form-data",body:c},{path:{disputePspReference:p}})},[w,p,b,c]),x=A(()=>[{title:e.get("disputes.defend.submit"),disabled:!w,state:b.isLoading?"loading":"default",variant:te.PRIMARY,event:W,classNames:E?["adyen-pe-defend-dispute__defended-btn"]:void 0,renderTitle:V=>E?i(Q,{children:[i(ue,{name:"checkmark-circle-fill",className:"adyen-pe-defend-dispute__defended-icon"}),e.get("disputes.defend.defended")]}):V},{title:e.get("disputes.goBack"),disabled:b.isLoading,variant:te.SECONDARY,event:E?_:o}],[e,W,b.isLoading,E,o]),j=C((V,Z)=>{V===void 0?y(ge=>[...ge,V]):Z!==void 0&&y(ge=>{if(ge[Z]===V)return ge;const Ne=[...ge];return Ne[Z]=V,Ne})},[]),L=A(()=>{if(P)return!1;const V=S.length+Math.max(0,D.length-1);return!!(V&&V!==g.length)},[P,D,S,g]),U=C(()=>{L&&j()},[L,j]),ie=A(()=>[...D.filter(Z=>Z.id!==f),...S].map(Z=>({...Z,disabled:g.includes(Z.id)})),[D,f,S,g]),le=C(V=>{y(Z=>{if(V<0||V>=Z.length)return Z;const ge=Z[V];return ge&&h(ge),Z.filter((Ne,me)=>me!==V)})},[h]);return i(Q,{children:i(Q,{children:[i(I,{className:"adyen-pe-defend-dispute-file-uploader__subtitle",variant:O.BODY,children:e.get("disputes.defend.uploadDocumentsInformation")}),i(kr,{renderHeader:i(I,{variant:O.BODY,stronger:!0,className:"adyen-pe-defend-dispute-document-requirements",children:e.get("disputes.documentRequirements")}),filled:!0,expandable:!0,compact:!0,children:i("ul",{className:"adyen-pe-defend-dispute-document-requirements--list",children:jN.map((V,Z)=>i("li",{className:"adyen-pe-defend-dispute-document-requirements--item",children:i(I,{variant:O.BODY,children:e.get(V)})},`${V}-${Z}`))})}),i("div",{className:"adyen-pe-defend-dispute-file-uploader__container",children:[N.length||D.length?i("div",{className:"adyen-pe-defend-dispute-document-upload-box",children:[N.length?i("div",{className:"adyen-pe-defend-dispute-document-upload-box__required-documents",children:N==null?void 0:N.map(V=>i(qN,{mapError:v,disabled:P,document:V,required:!0},V))}):null,D.length?i(kd,{mapError:v,disabled:P,selection:f,setSelection:V=>T(V),items:D,title:e.get("disputes.uploadDocuments.extraRequiredDocument"),required:!0}):null]}):null,g.length?g.map((V,Z)=>i("div",{className:"adyen-pe-defend-dispute-document-upload-box",children:i(kd,{mapError:v,disabled:P,onRemoveOption:le,selection:V,setSelection:j,index:Z,items:ie,title:e.get("disputes.uploadDocuments.optionalDocument"),required:!0})},`optional-doc-${Z}`)):null,L&&i(_e,{align:"center",onClick:U,variant:te.SECONDARY,fullWidth:!0,children:[i(ue,{name:"plus"}),e.get("disputes.uploadDocuments.addOptionalDocument")]})]}),i("div",{className:"adyen-pe-defend-file-uploader__actions",children:i(fs,{actions:x})})]})})},xo="adyen-pe-defend-dispute-reason",Bo={selector:xo+"__selector",description:xo+"__description",dropdownList:xo+"__dropdown-list",dropdownListMobile:xo+"__dropdown-list--mobile"},zN=()=>{var w,W,x,j;const{i18n:e}=H(),{applicableDocuments:t,dispute:n,goBack:s,setFlowState:r,setSelectedDefenseReason:a,selectedDefenseReason:o,setApplicableDocuments:c}=Dn(),d=(w=n==null?void 0:n.dispute)==null?void 0:w.allowedDefenseReasons,l=(W=n==null?void 0:n.dispute)==null?void 0:W.pspReference,[h,u]=F(!1),p=Pe(Ie.down.xs),f=A(()=>Object.freeze(d==null?void 0:d.map(L=>{var U;return{id:L,disabled:d.length===1,name:((U=rc(e,L))==null?void 0:U.title)??L}}))??[],[e,d]),T=A(()=>{var L,U;return o?(L=f.find(ie=>ie.id===o))==null?void 0:L.id:((U=f==null?void 0:f[0])==null?void 0:U.id)??null},[o,f]),{getApplicableDefenseDocuments:g}=Ee().endpoints,y=C(async()=>g==null?void 0:g(z,{query:{defenseReason:o},path:{disputePspReference:l}}),[o,l,g]),{error:_,isFetching:v}=bt({queryFn:y,fetchOptions:{enabled:h,onSuccess:C(L=>{u(!1),c((L==null?void 0:L.data)??null),L!=null&&L.data&&(L==null?void 0:L.data.length)>0&&r("uploadDefenseFilesView")},[c,u,r])}});G(()=>{u(!1)},[_]);const N=C(()=>{if(t!=null&&t.length)return r("uploadDefenseFilesView");u(!0)},[t,r]),S=C(L=>{var U;o!==L.target.value&&(t!=null&&t.length)&&c([]),(U=L==null?void 0:L.target)!=null&&U.value&&a(L.target.value)},[t,o,c,a]),D=A(()=>[{title:e.get("disputes.defend.continue"),disabled:h||v,event:N},{title:e.get("disputes.goBack"),disabled:h||v,event:s}],[v,h,e,s,N]),[R,b]=F(!0),E=C(()=>{b(!1)},[]),P=A(()=>T?rc(e,T):void 0,[e,T]);return!f||!T?null:i(Q,{children:[i("div",{className:Bo.selector,children:[i(I,{className:"adyen-pe-defend-dispute__reason-description",variant:O.BODY,children:e.get("disputes.defend.selectDefenseReason")}),i(Bn,{items:f,onChange:S,selected:T,popoverClassNameModifiers:[M(Bo.dropdownList,{[Bo.dropdownListMobile]:p})],fixedPopoverPositioning:!0}),(x=P==null?void 0:P.primaryDescriptionItems)==null?void 0:x.map((L,U)=>i(I,{el:J.PARAGRAPH,className:Bo.description,variant:O.BODY,children:L},`description-${U}`)),((j=P==null?void 0:P.secondaryDescriptionItems)==null?void 0:j.length)&&i("ul",{className:"adyen-pe-defend-dispute-reason__secondary-description-items-container",children:P.secondaryDescriptionItems.map((L,U)=>i("li",{className:"adyen-pe-defend-dispute-reason__secondary-description-item",children:i(I,{el:J.PARAGRAPH,className:"adyen-pe-defend-dispute-reason__description",variant:O.BODY,children:L})},`description-item-${U}`))})]}),R&&i(et,{onClose:E,type:be.HIGHLIGHT,variant:it.DEFAULT,children:i(I,{className:"adyen-pe-alert__description",el:J.DIV,variant:O.BODY,wide:!0,children:e.get("disputes.defend.chargebackFeeInformation")})}),i("div",{className:"adyen-pe-defend-dispute__actions",children:i(fs,{actions:D})})]})},KN=({onDisputeDefend:e})=>{const{i18n:t}=H(),{clearFiles:n,clearStates:s,dispute:r,setFlowState:a,defendResponse:o}=Dn(),c=C(()=>{s(),a("details")},[s,a]),d=C(()=>{n(),a("uploadDefenseFilesView")},[n,a]),l=q(!1);return G(()=>{if(!l.current&&o==="success"&&ee(e)){const h=r==null?void 0:r.dispute.pspReference;h&&(l.current=!0,e({id:h}))}},[o,r,e]),i("div",{className:"adyen-pe-defend-dispute__response",children:o==="success"?i("div",{className:"adyen-pe-defend-dispute__success",children:[i(ue,{name:"checkmark-circle-fill",className:"adyen-pe-defend-dispute__success-icon"}),i(I,{variant:O.TITLE,children:t.get("disputes.defend.evidenceSubmitted")}),i(I,{variant:O.BODY,className:"adyen-pe-defend-dispute__success-description",children:t.get("disputes.defend.submitSuccessfulInformation")}),i("div",{className:"adyen-pe-defend-dispute__success-buttons",children:i(_e,{variant:te.SECONDARY,onClick:c,children:t.get("disputes.showDisputeDetails")})})]}):i("div",{className:"adyen-pe-defend-dispute__error",children:[i(ue,{name:"cross-circle-fill",className:"adyen-pe-defend-dispute__error-icon"}),i(I,{variant:O.TITLE,medium:!0,children:t.get("disputes.defend.somethingWentWrong")}),i(I,{variant:O.BODY,children:t.get("disputes.error.weCouldNotProcessTheDisputePleaseTryAgainOrContactSupport")}),i(_e,{variant:te.SECONDARY,onClick:d,children:t.get("disputes.goBack")})]})})},XN=({onDisputeDefend:e})=>{const{i18n:t}=H(),{applicableDocuments:n,flowState:s}=Dn();return i("div",{className:"adyen-pe-defend-dispute__container",children:[s!=="defenseSubmitResponseView"&&i(I,{className:"adyen-pe-defend-dispute__title",variant:O.TITLE,medium:!0,children:t.get("disputes.defend.chargeback")}),s==="defendReasonSelectionView"&&i(zN,{}),s==="uploadDefenseFilesView"&&!!(n!=null&&n.length)&&i(VN,{}),s==="defenseSubmitResponseView"&&i(KN,{onDisputeDefend:e})]})},Ot="adyen-pe-dispute-data",wd="adyen-pe-dispute-data--mobile",ZN=`${Ot}__status-box`,QN=`${Ot}__action-bar`,JN=`${Ot}__label`,eD=`${Ot}__list`,tD=`${Ot}__list--evidence`,nD=`${Ot}__list-evidence-error-message`,Ld=`${Ot}__issuer-comment`,al=`${Ot}__issuer-comments`,sD=`${al}--expanded`,rD=`${al}--truncated`,oD=`${Ot}__issuer-comments-alert`,iD=`${Ot}__issuer-comments-group`,aD="adyen-pe-dispute-data__error-container",cD="adyen-pe-dispute-data__status-box-skeleton",lD="adyen-pe-dispute-data__properties-skeleton",Fd="adyen-pe-dispute-data__properties-skeleton-element",dD="adyen-pe-dispute-data__properties-skeleton-container",uD="adyen-pe-dispute-data__status-box-status-container",Md="adyen-pe-dispute-data__status-box-status",hD="adyen-pe-dispute-data__status-box-amount",xd="adyen-pe-dispute-data__status-box-payment-method",pD="adyen-pe-dispute-data__skeleton-container",fD="adyen-pe-dispute-data__status-box-payment-method-container",Bd=new Set(["allowedDefenseReasons","balanceAccount","amount","createdAt","defensibility","dueDate","id","latestDefense","paymentMerchantReference","paymentMethod","paymentPspReference","reasonCode","reasonGroup","status"]),mD=({issuerComments:e})=>{const{i18n:t}=H(),[n,s]=F(0),[r,a]=F(0),[o,c]=F(!1),[d,l]=F(!1),h=q(null),u=p=>{var f;p.preventDefault(),l(!d),(f=h.current)==null||f.style.setProperty("max-height",`${d?n:r}px`)};return dr(()=>{var p;if(h.current){const f=h.current,T=f.querySelector(`.${Ld}`),g=T?parseInt(getComputedStyle(T).getPropertyValue("line-height")):0,y=Math.min((T==null?void 0:T.clientHeight)||1/0,g*3),_=f.scrollHeight;s(y),a(_),c(_>y),(p=h.current)==null||p.style.setProperty("max-height",`${y}px`)}},[]),i(et,{type:be.HIGHLIGHT,variant:it.TIP,description:i("div",{className:oD,children:[i(I,{el:J.DIV,variant:O.BODY,strongest:!0,children:t.get("disputes.issuerComment.title")}),i("div",{className:M(al,{[sD]:d,[rD]:o}),children:i("ul",{ref:h,className:iD,children:e.map((p,f)=>i("li",{children:i(I,{className:Ld,el:J.PARAGRAPH,variant:O.BODY,children:p})},f))})}),o&&i(_e,{variant:te.TERTIARY,onClick:u,children:t.get(d?"disputes.issuerComment.showLess":"disputes.issuerComment.showMore")})]})})},ct={acceptedOn:"disputes.acceptedOn",account:"disputes.account",defendedOn:"disputes.defendedOn",defenseReason:"disputes.defenseReason",disputeEvidence:"disputes.evidence",disputeReason:"disputes.disputeReason",disputeReference:"disputes.disputeReference",expiredOn:"disputes.expiredOn",merchantReference:"disputes.merchantReference",openedOn:"disputes.openedOn",paymentReference:"disputes.paymentReference",reasonCode:"disputes.reasonCode",respondBy:"disputes.respondBy"},_D=["ACCEPTED","EXPIRED"],gD=({dispute:e,dataCustomization:t})=>{var c;const{i18n:n}=H(),{dateFormat:s}=Pt(e.payment.balanceAccount.timeZone),[r,a]=F(),o=C(async()=>{var d,l,h;if(e){const u=await((l=(d=t==null?void 0:t.details)==null?void 0:d.onDataRetrieve)==null?void 0:l.call(d,e));a((h=t==null?void 0:t.details)==null?void 0:h.fields.reduce((p,f)=>Bd.has(f.key)||$i.includes(f.key)||(f==null?void 0:f.visibility)==="hidden"?p:{...p,...u!=null&&u[f.key]?{[f.key]:u[f.key]}:{}},{}))}},[e,t]);return G(()=>{o()},[o]),A(()=>{var W;const{pspReference:d,reason:l,acceptedDate:h,createdAt:u,dueDate:p,status:f,type:T}=e.dispute,{pspReference:g,merchantReference:y,balanceAccount:_}=e.payment,{reason:v,defendedOn:N,suppliedDocuments:S}=e.defense||{},D=T==="NOTIFICATION_OF_FRAUD",R=f==="EXPIRED"||f==="LOST"&&!D&&!N,b=zp(e.dispute)&&e.dispute.defensibility!=="NOT_ACTIONABLE",E=null,w=[...[{key:ct.disputeReason,value:`${n.get(sa[l.category])} - ${l.title}`,id:"disputeReason"},D?E:{key:ct.reasonCode,value:l.code,id:"reasonCode"},{key:ct.openedOn,value:s(u,Ar),id:"openedOn"},p&&b?{key:ct.respondBy,value:s(p,Ar),id:"respondBy"}:E,{key:ct.disputeReference,value:i($t,{type:"Default",textToCopy:d,showCopyTextTooltip:!1}),id:"disputeId"},{key:ct.account,value:_.description,id:"account"},{key:ct.paymentReference,value:i($t,{type:"Default",textToCopy:g,showCopyTextTooltip:!1}),id:"paymentPspReference"},y?{key:ct.merchantReference,value:i($t,{type:"Default",textToCopy:y,showCopyTextTooltip:!1}),id:"paymentMerchantReference"}:E,v?{key:ct.defenseReason,value:((W=rc(n,v))==null?void 0:W.title)??v,id:"defenseReason"}:E,N?{key:ct.defendedOn,value:s(N,Ar),id:"defendedOn"}:E,S&&S.length>0?{key:ct.disputeEvidence,value:i(Q,{children:S.map((x,j)=>{var U;const L={path:{disputePspReference:d},query:{documentType:x}};return i("div",{className:tD,children:[i(ot,{label:((U=ra(n,x))==null?void 0:U.title)??x}),i(Bp,{className:"adyen-pe-dispute-document-download",endpointName:"downloadDefenseDocument",disabled:!1,requestParams:L,iconButton:!0,errorMessage:()=>i("div",{className:nD,children:[i(ue,{name:"info-filled"}),i(I,{variant:O.CAPTION,el:J.SPAN,children:n.get("disputes.error.failedRetry")})]}),onDownloadRequested:()=>console.warn("Download failed for",x)})]},`${x}-${j}`)})}),id:"disputeEvidence"}:E,h&&_D.includes(f)?{key:ct.acceptedOn,value:s(h,Ar),id:"acceptedOn"}:E,p&&R?{key:ct.expiredOn,value:s(p,Ar),id:"expiredOn"}:E].filter(Boolean).filter(x=>{var j,L;return!((L=(j=t==null?void 0:t.details)==null?void 0:j.fields)!=null&&L.some(U=>U.key===x.id&&U.visibility==="hidden"))}),...Object.entries(r||{}).filter(([x,j])=>!Bd.has(x)&&j.type!=="button"&&j.visibility!=="hidden").map(([x,j])=>({key:x,value:Jt(j)?j.value:j,type:Jt(j)?j.type:"text",config:Jt(j)?j.config:void 0}))||{}];return i(gn,{classNames:eD,items:w,layout:"4-8",align:"start",renderLabel:x=>i("div",{className:JN,children:x}),renderValue:(x,j,L,U)=>{if(L==="link"&&U)return i(wi,{classNames:[M(U==null?void 0:U.className)],href:U.href,target:U.target||"_blank",children:x});if(L==="icon"&&U){const ie={url:U==null?void 0:U.src,alt:U.alt||x};return i("div",{className:M("adyen-pe-dispute-data__list-icon-value",U==null?void 0:U.className),children:[i(Li,{...ie}),i(I,{variant:O.BODY,children:x})]})}return i(I,{className:M(U==null?void 0:U.className),variant:O.BODY,children:x})}})},[e,n,s,r,(c=t==null?void 0:t.details)==null?void 0:c.fields])},TD=(e,t,n)=>{if(!e)return qr;switch(e.errorCode){case void 0:return{title:"somethingWentWrong",message:[t,"tryRefreshingThePageOrComeBackLater"],refreshComponent:!0};case"00_500":{const s=n?"theErrorCodeIs":"contactSupportForHelpAndShareErrorCode";return{title:"somethingWentWrong",message:[t,s],translationValues:{[s]:e.requestId?i($t,{textToCopy:e.requestId}):null},onContactSupport:n}}case"30_112":return{title:"disputes.error.entityWasNotFound",message:["disputes.error.entityWasNotFoundDetail"],onContactSupport:n};default:return qr}},yD=e=>!!e&&typeof e=="object"&&e.type==="button",AD=({alertMode:e,dispute:t,timeZone:n})=>{const{i18n:s}=H(),{dateFormat:r}=Pt(n);switch(e){case"contactSupport":{const{dueDate:a,type:o}=t,c=o==="REQUEST_FOR_INFORMATION"?"disputes.contactSupport.toDefendRequestForInformation":o==="NOTIFICATION_OF_FRAUD"?"disputes.contactSupport.toResolveNotificationOfFraud":"disputes.contactSupport.toDefendDispute";return i(et,{type:be.WARNING,variant:it.TIP,description:i(Q,{children:[s.get(c),o!=="NOTIFICATION_OF_FRAUD"&&!!a&&i(Q,{children:[" ",i(pr,{translationKey:"disputes.alert.responseDeadline",fills:{date:i(I,{variant:O.BODY,el:J.SPAN,stronger:!0,children:r(a,Z_)})}})]})]})})}case"autoDefended":return i(et,{type:be.HIGHLIGHT,variant:it.TIP,description:s.get("disputes.alert.autoDefended")});case"notDefended":{const a=t.status==="EXPIRED"?"disputes.alert.notDefendedExpired":"disputes.alert.notDefendedLost";return i(et,{type:be.HIGHLIGHT,variant:it.TIP,description:s.get(a)})}case"notDefendable":return i(et,{type:be.HIGHLIGHT,variant:it.TIP,description:s.get("disputes.alert.notDefendable")})}return null},vD=({disputeId:e,dataCustomization:t,onContactSupport:n,onDismiss:s})=>{var Ne,me,Ce;const{i18n:r}=H(),{dispute:a,setDispute:o,setFlowState:c}=Dn(),{getDisputeDetail:d,getApplicableDefenseDocuments:l,acceptDispute:h}=Ee().endpoints,u=ee(h),p=ee(l),f=Pe(Ie.up.sm),{data:T,isFetching:g,error:y}=bt(A(()=>({fetchOptions:{enabled:!!e&&!!d&&!a,onSuccess:ae=>{o(ae)}},queryFn:async()=>d(z,{path:{disputePspReference:e}})}),[a,e,d,o])),_=a||T,v=(Ne=_==null?void 0:_.dispute)==null?void 0:Ne.defensibility,N=oh({amountData:_==null?void 0:_.dispute.amount,paymentMethodData:_==null?void 0:_.payment.paymentMethod}),S=A(()=>{const{chargeback:ae,preArbitration:ye}=(_==null?void 0:_.dispute.issuerExtraData)??{},We=[];return[ye,ae].forEach(pe=>{pe&&["LIABILITY_NOT_ACCEPTED_FULLY","PRE_ARB_REASON","NOTE"].forEach($e=>{const He=pe[$e],De=He==null?void 0:He.trim();De&&We.push(De)})}),We.filter(Boolean)},[_]),D=A(()=>{const ae=_==null?void 0:_.dispute.type;return ae&&r.get(NR[ae])},[r,_]),R=!!v&&["ACCEPTABLE","DEFENDABLE_EXTERNALLY"].includes(v)||(_==null?void 0:_.dispute.type)==="NOTIFICATION_OF_FRAUD",b=!!v&&v==="DEFENDABLE"&&p,E=!!v&&["ACCEPTABLE","DEFENDABLE"].includes(v)&&u,P=C(()=>{c("accept")},[c]),w=C(()=>{c("defendReasonSelectionView")},[c]),[W,x]=F([]),j=C(async()=>{var ye,We;const ae=T&&await((We=(ye=t==null?void 0:t.details)==null?void 0:ye.onDataRetrieve)==null?void 0:We.call(ye,T));if(ae)return x(Object.values(ae).filter(pe=>yD(pe)))},[T,t==null?void 0:t.details]);G(()=>{j()},[j]);const L=A(()=>{const ae=[];return b&&ae.push({title:r.get("disputes.defend.chargeback"),event:w}),E&&ae.push({title:r.get("disputes.accept"),event:P,variant:te.SECONDARY}),R&&ee(n)&&ae.push({title:r.get("contactSupport"),event:n,variant:te.SECONDARY}),W&&W.length&&W.forEach(ye=>{var We;ae.push({title:ye==null?void 0:ye.value,event:(We=ye==null?void 0:ye.config)==null?void 0:We.action,variant:te.SECONDARY})}),ae},[b,r,w,E,R,n,W,P]),U=A(()=>!!_&&zp(_.dispute),[_]),ie=C(()=>i(_e,{variant:te.SECONDARY,onClick:s,children:r.get("disputes.goBack")}),[r,s]);if(!_&&!y||g){const ae=Array.from({length:5});return i("div",{className:M(Ot,{[wd]:!f}),children:i("div",{className:pD,children:[i("div",{className:cD,children:[i("div",{className:uD,children:[i("span",{className:Md}),i("span",{className:Md})]}),i("span",{className:hD}),i("div",{className:fD,children:[i("span",{className:xd}),i("span",{className:xd})]})]}),i("div",{className:dD,children:ae.map((ye,We)=>i("div",{className:lD,children:[i("span",{className:Fd}),i("span",{className:Fd})]},`skeleton-${We}`))})]})})}const le=(_==null?void 0:_.dispute.type)==="NOTIFICATION_OF_FRAUD",V=!!(_!=null&&_.defense&&_.defense.defendedOn);let Z;((me=_==null?void 0:_.defense)==null?void 0:me.autodefended)===!0?Z="autoDefended":U&&v==="NOT_ACTIONABLE"?Z="notDefendable":U&&R||R&&le?Z="contactSupport":((_==null?void 0:_.dispute.status)==="EXPIRED"||(_==null?void 0:_.dispute.status)==="LOST"&&!(le||V))&&(Z="notDefended");const ge=TD(y,"disputes.error.weCouldNotLoadYourDispute",n);return i("div",{className:M(Ot,{[wd]:!f}),children:y?i("div",{className:aD,children:i(Qt,{renderSecondaryButton:s?ie:void 0,withImage:!0,outlined:!1,absolutePosition:!1,withBackground:!1,...ge})}):_?i(Q,{children:[i("div",{className:ZN,children:i(Eh,{...N,tag:i(Q,{children:[D&&i(ot,{label:D}),!le&&i(Xp,{dispute:_.dispute})]})})}),S.length>0&&i(mD,{issuerComments:S}),Z&&i(AD,{alertMode:Z,dispute:_.dispute,timeZone:(Ce=_.payment.balanceAccount)==null?void 0:Ce.timeZone}),i(gD,{dispute:_,dataCustomization:t}),L.length>0?i("div",{className:QN,children:i(fs,{actions:L})}):null]}):null})},RD=({id:e,hideTitle:t,dataCustomization:n,onContactSupport:s,onDisputeAccept:r,onDisputeDefend:a,onDismiss:o})=>{const{flowState:c}=Dn(),{i18n:d}=H();switch(c){case"details":return i(Q,{children:[!t&&i(I,{variant:O.TITLE,medium:!0,children:d.get("disputes.disputeManagementTitle")}),i(vD,{disputeId:e,dataCustomization:n,onContactSupport:s,onDismiss:o})]});case"accept":return i(IR,{onDisputeAccept:r});case"defendReasonSelectionView":case"defenseSubmitResponseView":case"uploadDefenseFilesView":return i(XN,{onDisputeDefend:a});default:return null}},sf=e=>{const[t,n]=F(),s=C(r=>{n(r)},[]);return i(OR,{dispute:t,setDispute:s,children:i("div",{className:"adyen-pe-dispute__container",children:i(RD,{...e})})})},CD=({children:e,selectedDetail:t,resetDetails:n,dataCustomization:s,onContactSupport:r,refreshDisputesList:a,setModalVisible:o})=>{const{i18n:c}=H(),[d,l]=F(!1),h=!!t,u=C(()=>{d&&(l(!1),a("CHARGEBACKS")),o(!1),n()},[d,a,n,o]),p=C(()=>{l(!0)},[]);return G(()=>{h&&(o(!0),bs.closeAll())},[h,o]),i("div",{children:[e,t&&i(Ih,{isOpen:h,"aria-label":c.get("disputes.disputeManagementTitle"),onClose:u,isDismissible:!0,headerWithBorder:!1,size:t.modalSize||"large",children:i("div",{className:"adyen-pe-dispute-management-modal-content",children:i(sf,{id:t.selection.data,dataCustomization:s,onDisputeAccept:p,onDisputeDefend:p,onContactSupport:r,onDismiss:n,hideTitle:!0})})})]})};function SD({activeTab:e,tabs:t,onChange:n}){const{activeIndex:s,onClick:r,onKeyDown:a,refs:o,uniqueId:c}=Yp({onChange:n,options:t,activeOption:e}),{i18n:d}=H();return i("section",{"aria-label":d.get("tabs"),children:[i("div",{className:"adyen-pe-tabs",role:"tablist","aria-orientation":"horizontal",children:t.map((l,h)=>{const u=s===h;return i("button",{role:"tab",name:l.id,ref:o[h],id:`tab:${c}-${l.id}`,className:"adyen-pe-tabs__tab","aria-controls":`panel:${c}-${l.id}`,"aria-selected":u,onClick:u?void 0:r,onKeyDown:a,disabled:l.disabled,tabIndex:u?0:-1,children:i(I,{el:J.SPAN,variant:O.BODY,className:"adyen-pe-tabs__tab-label",stronger:!0,children:d.get(l.label)})},`tab:${c}-${l.id}`)})}),i("div",{className:"adyen-pe-tabpanels",children:t.map((l,h)=>i("section",{role:"tabpanel",id:`panel:${c}-${l.id}`,className:"adyen-pe-tabpanels__panel","aria-labelledby":`tab:${c}-${l.id}`,hidden:s!==h,children:l.content},`panel:${c}-${l.id}`))})]})}const $d="CHARGEBACKS",Ra="schemeCodes",ys="reasonCategories",Ca="_t",ED=Object.keys(jp),ND=Object.keys(sa),DD=Object.keys(il),rf=Object.entries(il).map(([e,t])=>({id:e,label:t,content:null})),bD=({activeTab:e,onChange:t})=>{const{i18n:n}=H(),[s,r]=F(e),a=A(()=>Object.entries(il).map(([o,c])=>({id:o,name:n.get(c)})),[n]);return G(()=>{const o=rf.find(c=>c.id===s);o&&t(o)},[t,s]),G(()=>r(e),[e]),i(Bn,{items:a,selected:s,onChange:({target:o})=>r(o.value),showOverlay:!0,multiSelect:!1,filterable:!1})},OD=({onFiltersChanged:e,balanceAccounts:t,allowLimitSelection:n=!0,preferredLimit:s=hr,isLoadingBalanceAccount:r,onContactSupport:a,hideTitle:o,onRecordSelection:c,showDetails:d,dataCustomization:l})=>{const{i18n:h}=H(),{getDisputeList:u}=Ee().endpoints,{activeBalanceAccount:p,balanceAccountSelectionOptions:f,onBalanceAccountSelection:T}=Yi(t,!0),{defaultParams:g,nowTimestamp:y,refreshNowTimestamp:_}=Ji("disputes",p),[v,N]=F(!1),[S,D]=F(),[R,b]=F($d),[E,P]=F(!1),[w,W]=F(R),x=A(()=>({showDetails:d??!0,callback:c}),[d,c]),j=A(()=>({dispute:x}),[x]),L=C(async({[Ca]:Re,...Fe},Wt)=>u({signal:Wt,errorLevel:"error"},{query:{...Fe,...(p==null?void 0:p.id)!==oi&&{balanceAccountId:(p==null?void 0:p.id)??""},reasonCategories:qn(Fe[ys]),schemeCodes:qn(Fe[Ra]),createdSince:Fe[re.CREATED_SINCE]??g.current.defaultFilterParams[re.CREATED_SINCE],createdUntil:Fe[re.CREATED_UNTIL]??g.current.defaultFilterParams[re.CREATED_UNTIL]}}),[p==null?void 0:p.id,g,u]),U=Wi(),ie=A(()=>ee(e)?e:void 0,[e]),le=A(()=>n?ji:void 0,[n]),V=Object.assign(g.current.defaultFilterParams,{[ys]:void 0,[Ra]:void 0,[Ca]:performance.now(),statusGroup:$d}),{canResetFilters:Z,error:ge,fetching:Ne,filters:me,limit:Ce,limitOptions:ae,records:ye,resetFilters:We,updateFilters:pe,updateLimit:$e,...He}=Vi({fetchRecords:L,dataField:"data",filterParams:V,initialFiltersSameAsDefault:!0,onFiltersChanged:ie,preferredLimit:s,preferredLimitOptions:le,enabled:!!(p!=null&&p.id)&&!!u}),De=q(void 0),gt=Mr({mapFilterOptionName:C(Re=>h.get(sa[Re]),[h]),filterParam:ys,filterValues:ND,defaultFilters:{...V,[ys]:De.current},updateFilters:pe,filters:me}),bn=Mr({mapFilterOptionName:C(Re=>jp[Re],[]),filterParam:Ra,filterValues:ED,defaultFilters:V,updateFilters:pe,filters:me}),{updateDetails:rn,resetDetails:Tr,selectedDetail:Te}=Xc(j),we=C(({disputePspReference:Re})=>{rn({selection:{type:"dispute",data:Re},modalSize:"small"}).callback({id:Re})},[rn]),Le=A(()=>{const Re=new Date(y),Fe=Re.setFullYear(Re.getFullYear()-1),Wt=new Date(CR).getTime();return new Date(Math.max(Wt,Fe)).toString()},[y]),on=q(null),$n=C(({id:Re})=>{on.current&&clearTimeout(on.current),on.current=setTimeout(()=>{requestAnimationFrame(()=>P(!1));const Fe=ys,Wt={statusGroup:Re,[Fe]:void 0};Re!=="FRAUD_ALERTS"&&(Wt[Fe]=De.current),pe(Wt),on.current=null},500),b(Re),P(!0),W(void 0)},[pe]),_s=C(Re=>{Re&&DD.includes(Re)&&Re!==R?W(Re):pe({[Ca]:performance.now()})},[R,pe]),Un=Pe(Ie.down.xs);return G(()=>{D(Un&&v?{maxHeight:0,overflowY:"hidden"}:void 0)},[Un,v]),G(()=>{_(),me.statusGroup!=="FRAUD_ALERTS"&&(De.current=me[ys])},[me,_]),i("div",{style:S,className:M(ol,{[vR]:Un}),children:[i(Do,{hideTitle:o,titleKey:"disputes.title",children:i(Hi,{...U})}),i("div",{children:[i("div",{className:RR,children:Un?i(bD,{activeTab:w??R,onChange:$n}):i(SD,{tabs:rf,activeTab:w,onChange:$n})}),i(Gi,{...U,children:[i(qi,{activeBalanceAccount:p,balanceAccountSelectionOptions:f,onBalanceAccountSelection:T}),i(Qi,{canResetFilters:Z,defaultParams:g,filters:me,nowTimestamp:y,refreshNowTimestamp:_,sinceDate:Le,timezone:p==null?void 0:p.timeZone,updateFilters:pe}),i(ai,{...bn,placeholder:h.get("disputes.paymentMethod")}),R!=="FRAUD_ALERTS"&&i(ai,{...gt,placeholder:h.get("disputes.disputeReason")})]})]}),i(CD,{dataCustomization:(l==null?void 0:l.details)&&{details:l==null?void 0:l.details},selectedDetail:Te,resetDetails:Tr,onContactSupport:a,refreshDisputesList:_s,setModalVisible:N,children:i(bR,{activeBalanceAccount:p,balanceAccountId:p==null?void 0:p.id,loading:E||Ne||r||!t||!p,data:ye,showPagination:!0,limit:Ce,limitOptions:ae,onContactSupport:a,onLimitSelection:$e,error:ge,onRowClick:we,statusGroup:R,...He})})]})};function ID({...e}){const{balanceAccounts:t,isBalanceAccountIdWrong:n,isFetching:s,error:r}=No(e.balanceAccountId);return i(Ui,{balanceAccountsError:r,className:"adyen-pe-disputes-overview-container",errorMessage:"disputes.error.couldNotLoadDisputesOverview",isBalanceAccountIdWrong:n,onContactSupport:e.onContactSupport,children:i(OD,{...e,balanceAccounts:t,isLoadingBalanceAccount:s})})}class of extends Sn{constructor(n){super(n);Y(this,"componentToRender",()=>i(ID,{...this.props,balanceAccountId:this.props.balanceAccountId,ref:n=>void(this.componentRef=n)}));this.componentToRender=this.componentToRender.bind(this)}}Y(of,"type","disputes");class af extends Sn{constructor(n){super(n);Y(this,"componentToRender",()=>i(sf,{...this.props,ref:n=>void(this.componentRef=n)}));this.componentToRender=this.componentToRender.bind(this)}}Y(af,"type","disputesManagement");async function PD(e){return await new hc(e).initialize()}exports.AdyenPlatformExperience=PD;exports.CapitalOfferElement=xp;exports.CapitalOverviewElement=qp;exports.Core=hc;exports.DisputeManagementElement=af;exports.DisputesOverviewElement=of;exports.PayoutElement=wh;exports.PayoutsElement=Rp;exports.ReportsElement=Hp;exports.TransactionElement=Cp;exports.TransactionsElement=wp;exports.all_locales=cc;exports.da_DK=ru;exports.de_DE=ou;exports.en_US=Xo;exports.es_ES=iu;exports.fi_FI=au;exports.fr_FR=cu;exports.it_IT=lu;exports.nl_NL=du;exports.no_NO=uu;exports.pt_BR=hu;exports.sv_SE=pu;exports.u=i;
12
- //# sourceMappingURL=index-CldOsFs0.cjs.map