@adyen/adyen-platform-experience-web 1.0.3 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/index.js +2 -2
- package/dist/cjs/index.js.map +1 -1
- package/dist/da-DK-a148e492.cjs +2 -0
- package/dist/da-DK-a148e492.cjs.map +1 -0
- package/dist/de-DE-a39a50e8.cjs +2 -0
- package/dist/de-DE-a39a50e8.cjs.map +1 -0
- package/dist/es/components/external/PayoutDetails/components/PayoutData.js +41 -41
- package/dist/es/components/external/PayoutsOverview/components/PayoutsOverview/PayoutsOverview.js +93 -94
- package/dist/es/components/external/PayoutsOverview/components/PayoutsTable/PayoutsTable.js +76 -69
- package/dist/es/components/external/ReportsOverview/ReportsOverviewElement.js +25 -0
- package/dist/es/components/external/ReportsOverview/components/ReportsOverview/ReportsOverview.js +112 -0
- package/dist/es/components/external/ReportsOverview/components/ReportsOverview/ReportsOverview.scss.js +4 -0
- package/dist/es/components/external/ReportsOverview/components/ReportsOverview/constants.js +5 -0
- package/dist/es/components/external/ReportsOverview/components/ReportsOverviewContainer/ReportsOverviewContainer.js +30 -0
- package/dist/es/components/external/ReportsOverview/components/ReportsOverviewContainer/constants.js +4 -0
- package/dist/es/components/external/ReportsOverview/components/ReportsTable/ReportsTable.js +149 -0
- package/dist/es/components/external/ReportsOverview/components/ReportsTable/ReportsTable.scss.js +4 -0
- package/dist/es/components/external/ReportsOverview/components/ReportsTable/constants.js +7 -0
- package/dist/es/components/external/TransactionDetails/components/TransactionData.js +67 -46
- package/dist/es/components/external/TransactionDetails/components/TransactionDataSkeleton.js +28 -17
- package/dist/es/components/external/TransactionsOverview/components/AmountSkeleton/AmountSkeleton.js +13 -13
- package/dist/es/components/external/TransactionsOverview/components/Category/Category.js +19 -14
- package/dist/es/components/external/TransactionsOverview/components/MultiSelectionFilter/MultiSelectionFilter.js +1 -1
- package/dist/es/components/external/TransactionsOverview/components/SummaryItem/SummaryItem.js +10 -10
- package/dist/es/components/external/TransactionsOverview/components/SummaryItem/SummaryItemLabel.js +11 -11
- package/dist/es/components/external/TransactionsOverview/components/TransactionTotals/TransactionTotals.js +1 -1
- package/dist/es/components/external/TransactionsOverview/components/TransactionsOverview/TransactionsOverview.js +183 -164
- package/dist/es/components/external/TransactionsOverview/components/TransactionsTable/PaymentMethodCell.js +31 -24
- package/dist/es/components/external/TransactionsOverview/components/TransactionsTable/TransactionsTable.js +95 -89
- package/dist/es/components/external/TransactionsOverview/components/TransactionsTable/constants.js +6 -5
- package/dist/es/components/hooks/useCustomColumnsData.js +29 -0
- package/dist/es/components/hooks/useFreezePeriod.js +18 -0
- package/dist/es/components/{external/TransactionsOverview/hooks → hooks}/useResponsiveViewport.js +2 -2
- package/dist/es/components/hooks/useTableColumns.js +46 -0
- package/dist/es/components/internal/Accordion/Accordion.js +15 -15
- package/dist/es/components/internal/Alert/Alert.js +62 -0
- package/dist/es/components/internal/Alert/Alert.scss.js +4 -0
- package/dist/es/components/internal/Alert/types.js +4 -0
- package/dist/es/components/internal/Button/DownloadButton/DownloadButton.js +81 -0
- package/dist/es/components/internal/Button/DownloadButton/DownloadButton.scss.js +4 -0
- package/dist/es/components/internal/Button/DownloadButton/useDownload.js +18 -0
- package/dist/es/components/internal/Card/Card.js +15 -15
- package/dist/es/components/internal/DataGrid/DataGrid.js +4 -4
- package/dist/es/components/internal/DataGrid/DataGridCell.js +12 -12
- package/dist/es/components/internal/DataGrid/components/Icon.js +17 -0
- package/dist/es/components/internal/DataGrid/components/SkeletonBody.js +7 -7
- package/dist/es/components/internal/DataGrid/components/TableCells.js +54 -37
- package/dist/es/components/internal/DataOverviewContainer/DataOverviewContainer.js +11 -11
- package/dist/es/components/internal/DataOverviewDetails/DataOverviewDetails.js +54 -54
- package/dist/es/components/internal/DataOverviewDisplay/DataOverviewHeader/DataOverviewHeader.js +45 -0
- package/dist/es/components/internal/DataOverviewDisplay/DataOverviewHeader/DataOverviewHeader.scss.js +4 -0
- package/dist/es/components/internal/DataOverviewDisplay/constants.js +30 -24
- package/dist/es/components/internal/DatePicker/DatePicker.js +10 -10
- package/dist/es/components/internal/ExpandableCard/ExpandableCard.js +13 -13
- package/dist/es/components/internal/FilterBar/FilterBar.js +50 -42
- package/dist/es/components/internal/FilterBar/components/FilterButton/FilterButton.js +7 -7
- package/dist/es/components/internal/FilterBar/filters/AmountFilter/RangeSelection.js +54 -50
- package/dist/es/components/internal/FilterBar/filters/BaseFilter/BaseFilter.js +1 -1
- package/dist/es/components/internal/FormFields/InputBase.js +25 -25
- package/dist/es/components/internal/FormFields/Select/BalanceAccountSelector/BalanceAccountSelector.js +1 -1
- package/dist/es/components/internal/FormFields/Select/Select.js +5 -5
- package/dist/es/components/internal/FormFields/Select/components/SelectList.js +5 -5
- package/dist/es/components/internal/Image/Image.js +6 -6
- package/dist/es/components/internal/Img/Img.js +4 -4
- package/dist/es/components/internal/Modal/Modal.js +6 -6
- package/dist/es/components/internal/Pagination/Pagination.js +17 -17
- package/dist/es/components/internal/Popover/Popover.js +11 -11
- package/dist/es/components/internal/SVGIcons/Download.js +21 -0
- package/dist/es/components/internal/SVGIcons/Warning.js +23 -0
- package/dist/es/components/internal/SVGIcons/WarningFilled.js +18 -0
- package/dist/es/components/internal/StructuredList/StructuredList.js +8 -8
- package/dist/es/components/internal/Tag/Tag.js +8 -8
- package/dist/es/components/internal/Tooltip/Tooltip.js +20 -20
- package/dist/es/components/internal/Typography/Typography.js +12 -12
- package/dist/es/components/utils/getLabel.js +6 -3
- package/dist/es/core/Http/http.js +34 -31
- package/dist/es/core/Http/utils.js +39 -30
- package/dist/es/core/Localization/Localization.js +74 -76
- package/dist/es/core/Localization/constants/localization.js +9 -6
- package/dist/es/core/Localization/localization-utils.js +11 -12
- package/dist/es/core/Localization/utils.js +45 -47
- package/dist/es/core/core.js +1 -1
- package/dist/es/index.js +14 -12
- package/dist/es/translations/da-DK.json.js +2 -218
- package/dist/es/translations/de-DE.json.js +2 -218
- package/dist/es/translations/en-US.json.js +2 -218
- package/dist/es/translations/es-ES.json.js +2 -218
- package/dist/es/translations/fr-FR.json.js +2 -218
- package/dist/es/translations/index.js +41 -45
- package/dist/es/translations/it-IT.json.js +2 -218
- package/dist/es/translations/nl-NL.json.js +2 -218
- package/dist/es/translations/no-NO.json.js +2 -218
- package/dist/es/translations/pt-BR.json.js +2 -218
- package/dist/es/translations/sv-SE.json.js +2 -218
- package/dist/es/utils/preact/className.js +3 -3
- package/dist/es-ES-153e5f15.cjs +2 -0
- package/dist/es-ES-153e5f15.cjs.map +1 -0
- package/dist/fr-FR-69b3df0d.cjs +2 -0
- package/dist/fr-FR-69b3df0d.cjs.map +1 -0
- package/dist/it-IT-efca230f.cjs +2 -0
- package/dist/it-IT-efca230f.cjs.map +1 -0
- package/dist/nl-NL-ffbb8184.cjs +2 -0
- package/dist/nl-NL-ffbb8184.cjs.map +1 -0
- package/dist/no-NO-eaf65f6f.cjs +2 -0
- package/dist/no-NO-eaf65f6f.cjs.map +1 -0
- package/dist/pt-BR-590ccc53.cjs +2 -0
- package/dist/pt-BR-590ccc53.cjs.map +1 -0
- package/dist/style.css +1 -1
- package/dist/sv-SE-18f4e86e.cjs +2 -0
- package/dist/sv-SE-18f4e86e.cjs.map +1 -0
- package/dist/types/components/external/PayoutsOverview/components/PayoutsOverview/PayoutsOverview.d.ts.map +1 -1
- package/dist/types/components/external/PayoutsOverview/components/PayoutsTable/PayoutsTable.d.ts +2 -2
- package/dist/types/components/external/PayoutsOverview/components/PayoutsTable/PayoutsTable.d.ts.map +1 -1
- package/dist/types/components/external/ReportsOverview/ReportsOverviewElement.d.ts +9 -0
- package/dist/types/components/external/ReportsOverview/ReportsOverviewElement.d.ts.map +1 -0
- package/dist/types/components/external/ReportsOverview/components/ReportsOverview/ReportsOverview.d.ts +8 -0
- package/dist/types/components/external/ReportsOverview/components/ReportsOverview/ReportsOverview.d.ts.map +1 -0
- package/dist/types/components/external/ReportsOverview/components/ReportsOverview/constants.d.ts +3 -0
- package/dist/types/components/external/ReportsOverview/components/ReportsOverview/constants.d.ts.map +1 -0
- package/dist/types/components/external/ReportsOverview/components/ReportsOverviewContainer/ReportsOverviewContainer.d.ts +4 -0
- package/dist/types/components/external/ReportsOverview/components/ReportsOverviewContainer/ReportsOverviewContainer.d.ts.map +1 -0
- package/dist/types/components/external/ReportsOverview/components/ReportsOverviewContainer/constants.d.ts +2 -0
- package/dist/types/components/external/ReportsOverview/components/ReportsOverviewContainer/constants.d.ts.map +1 -0
- package/dist/types/components/external/ReportsOverview/components/ReportsTable/ReportsTable.d.ts +15 -0
- package/dist/types/components/external/ReportsOverview/components/ReportsTable/ReportsTable.d.ts.map +1 -0
- package/dist/types/components/external/ReportsOverview/components/ReportsTable/constants.d.ts +5 -0
- package/dist/types/components/external/ReportsOverview/components/ReportsTable/constants.d.ts.map +1 -0
- package/dist/types/components/external/ReportsOverview/index.d.ts +2 -0
- package/dist/types/components/external/ReportsOverview/index.d.ts.map +1 -0
- package/dist/types/components/external/TransactionDetails/components/TransactionData.d.ts +20 -2
- package/dist/types/components/external/TransactionDetails/components/TransactionData.d.ts.map +1 -1
- package/dist/types/components/external/TransactionDetails/components/TransactionDataSkeleton.d.ts.map +1 -1
- package/dist/types/components/external/TransactionDetails/types.d.ts +5 -1
- package/dist/types/components/external/TransactionDetails/types.d.ts.map +1 -1
- package/dist/types/components/external/TransactionsOverview/components/Category/Category.d.ts.map +1 -1
- package/dist/types/components/external/TransactionsOverview/components/SummaryItem/types.d.ts +1 -1
- package/dist/types/components/external/TransactionsOverview/components/SummaryItem/types.d.ts.map +1 -1
- package/dist/types/components/external/TransactionsOverview/components/TransactionsOverview/TransactionsOverview.d.ts +1 -1
- package/dist/types/components/external/TransactionsOverview/components/TransactionsOverview/TransactionsOverview.d.ts.map +1 -1
- package/dist/types/components/external/TransactionsOverview/components/TransactionsTable/PaymentMethodCell.d.ts.map +1 -1
- package/dist/types/components/external/TransactionsOverview/components/TransactionsTable/TransactionsTable.d.ts +3 -1
- package/dist/types/components/external/TransactionsOverview/components/TransactionsTable/TransactionsTable.d.ts.map +1 -1
- package/dist/types/components/external/TransactionsOverview/components/TransactionsTable/constants.d.ts +1 -0
- package/dist/types/components/external/TransactionsOverview/components/TransactionsTable/constants.d.ts.map +1 -1
- package/dist/types/components/external/TransactionsOverview/components/TransactionsTable/types.d.ts +5 -0
- package/dist/types/components/external/TransactionsOverview/components/TransactionsTable/types.d.ts.map +1 -1
- package/dist/types/components/external/index.d.ts +1 -0
- package/dist/types/components/external/index.d.ts.map +1 -1
- package/dist/types/components/hooks/useCustomColumnsData.d.ts +13 -0
- package/dist/types/components/hooks/useCustomColumnsData.d.ts.map +1 -0
- package/dist/types/components/hooks/useFreezePeriod.d.ts +6 -0
- package/dist/types/components/hooks/useFreezePeriod.d.ts.map +1 -0
- package/dist/types/components/{external/TransactionsOverview/hooks → hooks}/useResponsiveViewport.d.ts +1 -1
- package/dist/types/components/hooks/useResponsiveViewport.d.ts.map +1 -0
- package/dist/types/components/hooks/useTableColumns.d.ts +20 -0
- package/dist/types/components/hooks/useTableColumns.d.ts.map +1 -0
- package/dist/types/components/internal/Alert/Alert.d.ts +5 -0
- package/dist/types/components/internal/Alert/Alert.d.ts.map +1 -0
- package/dist/types/components/internal/Alert/types.d.ts +17 -0
- package/dist/types/components/internal/Alert/types.d.ts.map +1 -0
- package/dist/types/components/internal/Button/DownloadButton/DownloadButton.d.ts +16 -0
- package/dist/types/components/internal/Button/DownloadButton/DownloadButton.d.ts.map +1 -0
- package/dist/types/components/internal/Button/DownloadButton/useDownload.d.ts +143 -0
- package/dist/types/components/internal/Button/DownloadButton/useDownload.d.ts.map +1 -0
- package/dist/types/components/internal/DataGrid/DataGrid.d.ts +2 -5
- package/dist/types/components/internal/DataGrid/DataGrid.d.ts.map +1 -1
- package/dist/types/components/internal/DataGrid/components/Icon.d.ts +7 -0
- package/dist/types/components/internal/DataGrid/components/Icon.d.ts.map +1 -0
- package/dist/types/components/internal/DataGrid/components/TableCells.d.ts.map +1 -1
- package/dist/types/components/internal/DataGrid/types.d.ts +4 -3
- package/dist/types/components/internal/DataGrid/types.d.ts.map +1 -1
- package/dist/types/components/internal/DataOverviewContainer/DataOverviewContainer.d.ts +1 -1
- package/dist/types/components/internal/DataOverviewContainer/DataOverviewContainer.d.ts.map +1 -1
- package/dist/types/components/internal/DataOverviewDetails/DataOverviewDetails.d.ts.map +1 -1
- package/dist/types/components/internal/DataOverviewDetails/types.d.ts +3 -2
- package/dist/types/components/internal/DataOverviewDetails/types.d.ts.map +1 -1
- package/dist/types/components/internal/DataOverviewDisplay/DataOverviewHeader/DataOverviewHeader.d.ts +13 -0
- package/dist/types/components/internal/DataOverviewDisplay/DataOverviewHeader/DataOverviewHeader.d.ts.map +1 -0
- package/dist/types/components/internal/DataOverviewDisplay/DataOverviewHeader/index.d.ts +3 -0
- package/dist/types/components/internal/DataOverviewDisplay/DataOverviewHeader/index.d.ts.map +1 -0
- package/dist/types/components/internal/DataOverviewDisplay/constants.d.ts +5 -2
- package/dist/types/components/internal/DataOverviewDisplay/constants.d.ts.map +1 -1
- package/dist/types/components/internal/DataOverviewError/DataOverviewError.d.ts +1 -1
- package/dist/types/components/internal/DataOverviewError/DataOverviewError.d.ts.map +1 -1
- package/dist/types/components/internal/DatePicker/components/TimeRangeSelector/useTimeRangeSelection.d.ts +1 -1
- package/dist/types/components/internal/DatePicker/components/TimeRangeSelector/useTimeRangeSelection.d.ts.map +1 -1
- package/dist/types/components/internal/ErrorMessageDisplay/ErrorMessageDisplay.d.ts +1 -1
- package/dist/types/components/internal/ErrorMessageDisplay/ErrorMessageDisplay.d.ts.map +1 -1
- package/dist/types/components/internal/FilterBar/FilterBar.d.ts +9 -2
- package/dist/types/components/internal/FilterBar/FilterBar.d.ts.map +1 -1
- package/dist/types/components/internal/FilterBar/filters/AmountFilter/RangeSelection.d.ts.map +1 -1
- package/dist/types/components/internal/FilterBar/index.d.ts +1 -0
- package/dist/types/components/internal/FilterBar/index.d.ts.map +1 -1
- package/dist/types/components/internal/FilterBar/types.d.ts +11 -1
- package/dist/types/components/internal/FilterBar/types.d.ts.map +1 -1
- package/dist/types/components/internal/FormFields/Select/hooks/useSelect.d.ts +1 -1
- package/dist/types/components/internal/Pagination/Pagination.d.ts.map +1 -1
- package/dist/types/components/internal/SVGIcons/Download.d.ts +4 -0
- package/dist/types/components/internal/SVGIcons/Download.d.ts.map +1 -0
- package/dist/types/components/internal/SVGIcons/Warning.d.ts +4 -0
- package/dist/types/components/internal/SVGIcons/Warning.d.ts.map +1 -0
- package/dist/types/components/internal/SVGIcons/WarningFilled.d.ts +4 -0
- package/dist/types/components/internal/SVGIcons/WarningFilled.d.ts.map +1 -0
- package/dist/types/components/internal/StructuredList/types.d.ts +1 -1
- package/dist/types/components/internal/StructuredList/types.d.ts.map +1 -1
- package/dist/types/components/internal/StructuredList/useStructuredListItem.d.ts +2 -2
- package/dist/types/components/internal/StructuredList/useStructuredListItem.d.ts.map +1 -1
- package/dist/types/components/types.d.ts +33 -1
- package/dist/types/components/types.d.ts.map +1 -1
- package/dist/types/components/utils/getCommonErrorCode.d.ts +1 -1
- package/dist/types/components/utils/getCommonErrorCode.d.ts.map +1 -1
- package/dist/types/components/utils/getErrorMessage.d.ts +1 -1
- package/dist/types/components/utils/getErrorMessage.d.ts.map +1 -1
- package/dist/types/components/utils/getLabel.d.ts +4 -1
- package/dist/types/components/utils/getLabel.d.ts.map +1 -1
- package/dist/types/core/Auth/context.d.ts +8 -6
- package/dist/types/core/Auth/context.d.ts.map +1 -1
- package/dist/types/core/Auth/session/AuthSession.d.ts +8 -6
- package/dist/types/core/Auth/session/AuthSession.d.ts.map +1 -1
- package/dist/types/core/Auth/session/AuthSetupContext.d.ts +8 -6
- package/dist/types/core/Auth/session/AuthSetupContext.d.ts.map +1 -1
- package/dist/types/core/Http/http.d.ts.map +1 -1
- package/dist/types/core/Http/utils.d.ts +2 -0
- package/dist/types/core/Http/utils.d.ts.map +1 -1
- package/dist/types/core/Localization/Localization.d.ts +8 -10
- package/dist/types/core/Localization/Localization.d.ts.map +1 -1
- package/dist/types/core/Localization/constants/localization.d.ts +5 -2
- package/dist/types/core/Localization/constants/localization.d.ts.map +1 -1
- package/dist/types/core/Localization/localization-utils.d.ts +4 -4
- package/dist/types/core/Localization/localization-utils.d.ts.map +1 -1
- package/dist/types/core/Localization/types.d.ts +0 -19
- package/dist/types/core/Localization/types.d.ts.map +1 -1
- package/dist/types/core/Localization/utils.d.ts +7 -271
- package/dist/types/core/Localization/utils.d.ts.map +1 -1
- package/dist/types/core/core.d.ts +2 -3
- package/dist/types/core/core.d.ts.map +1 -1
- package/dist/types/core/types.d.ts +5 -4
- package/dist/types/core/types.d.ts.map +1 -1
- package/dist/types/hooks/useFetch/useFetch.d.ts +1 -1
- package/dist/types/hooks/useFetch/useFetch.d.ts.map +1 -1
- package/dist/types/hooks/useModalDetails/types.d.ts +1 -1
- package/dist/types/hooks/useModalDetails/types.d.ts.map +1 -1
- package/dist/types/index.d.ts +2 -3
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/translations/index.d.ts +189 -2529
- package/dist/types/translations/index.d.ts.map +1 -1
- package/dist/types/types/api/models/reports.d.ts +1 -1
- package/dist/types/types/api/models/reports.d.ts.map +1 -1
- package/dist/types/types/api/resources/ReportsResource.d.ts +18 -19
- package/dist/types/types/api/resources/ReportsResource.d.ts.map +1 -1
- package/dist/types/utils/types.d.ts +3 -0
- package/dist/types/utils/types.d.ts.map +1 -1
- package/package.json +7 -5
- package/dist/es/core/Localization/constants/locale.js +0 -7
- package/dist/types/components/external/TransactionsOverview/hooks/useResponsiveViewport.d.ts.map +0 -1
- package/dist/types/core/Localization/constants/locale.d.ts +0 -139
- package/dist/types/core/Localization/constants/locale.d.ts.map +0 -1
|
@@ -1,68 +1,68 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
1
|
+
var U = Object.defineProperty;
|
|
2
|
+
var b = (r, t, e) => t in r ? U(r, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[t] = e;
|
|
3
|
+
var R = (r, t, e) => (b(r, typeof t != "symbol" ? t + "" : t, e), e), z = (r, t, e) => {
|
|
4
4
|
if (!t.has(r))
|
|
5
5
|
throw TypeError("Cannot " + e);
|
|
6
6
|
};
|
|
7
|
-
var s = (r, t, e) => (
|
|
7
|
+
var s = (r, t, e) => (z(r, t, "read from private field"), e ? e.call(r) : t.get(r)), o = (r, t, e) => {
|
|
8
8
|
if (t.has(r))
|
|
9
9
|
throw TypeError("Cannot add the same private member more than once");
|
|
10
10
|
t instanceof WeakSet ? t.add(r) : t.set(r, e);
|
|
11
|
-
},
|
|
12
|
-
var
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import { createTranslationsLoader as
|
|
17
|
-
import { toTwoLetterCode as
|
|
18
|
-
import {
|
|
19
|
-
import
|
|
20
|
-
import
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
class nt {
|
|
11
|
+
}, a = (r, t, e, i) => (z(r, t, "write to private field"), i ? i.call(r, e) : t.set(r, e), e);
|
|
12
|
+
var C = (r, t, e) => (z(r, t, "access private method"), e);
|
|
13
|
+
import { FALLBACK_LOCALE as E, DEFAULT_TRANSLATIONS as j, getLocalesFromTranslationSourcesRecord as x, DEFAULT_DATETIME_FORMAT as I, SUPPORTED_LOCALES as M } from "./constants/localization.js";
|
|
14
|
+
import { en_US as _ } from "../../translations/index.js";
|
|
15
|
+
import { getLocalisedAmount as W } from "./amount/amount-util.js";
|
|
16
|
+
import { createTranslationsLoader as $, getLocalizationProxyDescriptors as k } from "./localization-utils.js";
|
|
17
|
+
import { toTwoLetterCode as w, formatCustomTranslations as q, getTranslation as F } from "./utils.js";
|
|
18
|
+
import { createWatchlist as v } from "../../primitives/reactive/watchlist/main.js";
|
|
19
|
+
import B from "./datetime/restamper/restamper.js";
|
|
20
|
+
import { isNullish as N, isUndefined as K, isNull as V } from "../../utils/value/is.js";
|
|
21
|
+
import { ALREADY_RESOLVED_PROMISE as Y } from "../../utils/async/constants.js";
|
|
22
|
+
import { struct as Z } from "../../utils/struct/main.js";
|
|
23
|
+
import { noop as G } from "../../utils/common.js";
|
|
24
|
+
var h, g, u, T, f, p, c, A, l, m, d, L, D, S;
|
|
25
|
+
class ht {
|
|
27
26
|
constructor(t = E, e) {
|
|
28
|
-
o(this,
|
|
27
|
+
o(this, D);
|
|
29
28
|
o(this, h, E);
|
|
30
|
-
o(this,
|
|
31
|
-
o(this,
|
|
32
|
-
o(this,
|
|
33
|
-
o(this,
|
|
34
|
-
o(this,
|
|
35
|
-
o(this,
|
|
36
|
-
o(this,
|
|
29
|
+
o(this, g, w(s(this, h)));
|
|
30
|
+
o(this, u, [E]);
|
|
31
|
+
o(this, T, s(this, u));
|
|
32
|
+
o(this, f, void 0);
|
|
33
|
+
o(this, p, j);
|
|
34
|
+
o(this, c, $.call(this));
|
|
35
|
+
o(this, A, Y);
|
|
36
|
+
o(this, l, void 0);
|
|
37
37
|
o(this, m, void 0);
|
|
38
|
-
o(this, d,
|
|
38
|
+
o(this, d, v({
|
|
39
39
|
timestamp: () => performance.now()
|
|
40
40
|
}));
|
|
41
|
-
o(this,
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
this.watch(
|
|
41
|
+
o(this, L, B());
|
|
42
|
+
R(this, "watch", s(this, d).subscribe.bind(void 0));
|
|
43
|
+
R(this, "i18n", Z(k.call(this)));
|
|
44
|
+
R(this, "preferredTranslations");
|
|
45
|
+
this.watch(G), this.preferredTranslations = Object.freeze((e == null ? void 0 : e.reduce((i, n) => ({
|
|
46
46
|
...i,
|
|
47
|
-
...
|
|
48
|
-
}), {
|
|
49
|
-
|
|
50
|
-
}), this.locale = t;
|
|
47
|
+
...n
|
|
48
|
+
}), _)) ?? {
|
|
49
|
+
..._
|
|
50
|
+
}), a(this, u, x(this.preferredTranslations)), this.locale = t;
|
|
51
51
|
}
|
|
52
52
|
get customTranslations() {
|
|
53
|
-
return s(this,
|
|
53
|
+
return s(this, f) ?? {};
|
|
54
54
|
}
|
|
55
55
|
set customTranslations(t) {
|
|
56
|
-
let e, i = [...
|
|
57
|
-
if (!
|
|
58
|
-
e =
|
|
59
|
-
const
|
|
60
|
-
i = [...
|
|
56
|
+
let e, i = [...s(this, u)];
|
|
57
|
+
if (!N(t)) {
|
|
58
|
+
e = q(t, M);
|
|
59
|
+
const n = Object.keys(e);
|
|
60
|
+
i = [...i, ...n].sort().filter((y, O, P) => P.indexOf(y) === O);
|
|
61
61
|
}
|
|
62
|
-
s(this,
|
|
62
|
+
s(this, c).supportedLocales = i, C(this, D, S).call(this, e);
|
|
63
63
|
}
|
|
64
64
|
get languageCode() {
|
|
65
|
-
return s(this,
|
|
65
|
+
return s(this, g);
|
|
66
66
|
}
|
|
67
67
|
get lastRefreshTimestamp() {
|
|
68
68
|
return s(this, d).snapshot.timestamp;
|
|
@@ -71,25 +71,25 @@ class nt {
|
|
|
71
71
|
return s(this, h);
|
|
72
72
|
}
|
|
73
73
|
set locale(t) {
|
|
74
|
-
if (
|
|
74
|
+
if (N(t))
|
|
75
75
|
this.locale = E;
|
|
76
76
|
else {
|
|
77
|
-
if (s(this,
|
|
77
|
+
if (s(this, c).locale = t, s(this, h) === s(this, c).locale)
|
|
78
78
|
return;
|
|
79
|
-
|
|
79
|
+
C(this, D, S).call(this, s(this, f));
|
|
80
80
|
}
|
|
81
81
|
}
|
|
82
82
|
get ready() {
|
|
83
|
-
return s(this,
|
|
83
|
+
return s(this, A);
|
|
84
84
|
}
|
|
85
85
|
get supportedLocales() {
|
|
86
|
-
return s(this,
|
|
86
|
+
return s(this, T);
|
|
87
87
|
}
|
|
88
88
|
get timezone() {
|
|
89
|
-
return s(this,
|
|
89
|
+
return s(this, L).tz.current;
|
|
90
90
|
}
|
|
91
91
|
set timezone(t) {
|
|
92
|
-
s(this,
|
|
92
|
+
s(this, L).tz = t;
|
|
93
93
|
}
|
|
94
94
|
/**
|
|
95
95
|
* Returns a translated string from a key in the current {@link Localization.locale}
|
|
@@ -98,8 +98,8 @@ class nt {
|
|
|
98
98
|
* @returns Translated string
|
|
99
99
|
*/
|
|
100
100
|
get(t, e) {
|
|
101
|
-
const i =
|
|
102
|
-
return
|
|
101
|
+
const i = F(s(this, p), t, e);
|
|
102
|
+
return V(i) ? t : i;
|
|
103
103
|
}
|
|
104
104
|
/**
|
|
105
105
|
* Returns a boolean that checks if the translation key exists in the current {@link Localization.locale}
|
|
@@ -108,7 +108,7 @@ class nt {
|
|
|
108
108
|
* @returns boolean
|
|
109
109
|
*/
|
|
110
110
|
has(t, e) {
|
|
111
|
-
return !!
|
|
111
|
+
return !!F(s(this, p), t, e);
|
|
112
112
|
}
|
|
113
113
|
/**
|
|
114
114
|
* Returns a localized string for an amount
|
|
@@ -118,14 +118,14 @@ class nt {
|
|
|
118
118
|
*/
|
|
119
119
|
amount(t, e, i) {
|
|
120
120
|
const {
|
|
121
|
-
hideCurrency:
|
|
122
|
-
...
|
|
123
|
-
} = i || {},
|
|
124
|
-
...
|
|
121
|
+
hideCurrency: n,
|
|
122
|
+
...y
|
|
123
|
+
} = i || {}, O = W(t, s(this, h), e, n, {
|
|
124
|
+
...y,
|
|
125
125
|
currencyDisplay: "symbol",
|
|
126
126
|
signDisplay: "never"
|
|
127
127
|
});
|
|
128
|
-
return t < 0 ? `- ${
|
|
128
|
+
return t < 0 ? `- ${O}` : O;
|
|
129
129
|
}
|
|
130
130
|
/**
|
|
131
131
|
* Returns a localized string for a date
|
|
@@ -134,8 +134,8 @@ class nt {
|
|
|
134
134
|
*/
|
|
135
135
|
date(t, e = {}) {
|
|
136
136
|
const i = {
|
|
137
|
-
...
|
|
138
|
-
timeZone: s(this,
|
|
137
|
+
...I,
|
|
138
|
+
timeZone: s(this, L).tz.current,
|
|
139
139
|
...e
|
|
140
140
|
};
|
|
141
141
|
return new Date(t).toLocaleDateString(s(this, h), i);
|
|
@@ -146,9 +146,7 @@ class nt {
|
|
|
146
146
|
*/
|
|
147
147
|
fullDate(t) {
|
|
148
148
|
return this.date(t, {
|
|
149
|
-
day: "2-digit",
|
|
150
149
|
month: "short",
|
|
151
|
-
year: "numeric",
|
|
152
150
|
hour: "2-digit",
|
|
153
151
|
minute: "2-digit",
|
|
154
152
|
second: "2-digit",
|
|
@@ -156,22 +154,22 @@ class nt {
|
|
|
156
154
|
});
|
|
157
155
|
}
|
|
158
156
|
}
|
|
159
|
-
h = new WeakMap(),
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
157
|
+
h = new WeakMap(), g = new WeakMap(), u = new WeakMap(), T = new WeakMap(), f = new WeakMap(), p = new WeakMap(), c = new WeakMap(), A = new WeakMap(), l = new WeakMap(), m = new WeakMap(), d = new WeakMap(), L = new WeakMap(), D = new WeakSet(), S = function(t) {
|
|
158
|
+
K(s(this, m)) && a(this, A, new Promise((n) => {
|
|
159
|
+
a(this, m, () => {
|
|
160
|
+
n(s(this, l)), a(this, l, a(this, m, void 0));
|
|
163
161
|
});
|
|
164
162
|
}));
|
|
165
163
|
const e = () => {
|
|
166
|
-
var
|
|
167
|
-
s(this,
|
|
168
|
-
}, i =
|
|
169
|
-
|
|
164
|
+
var n;
|
|
165
|
+
s(this, l) === i && ((n = s(this, m)) == null || n.call(this));
|
|
166
|
+
}, i = a(this, l, (async () => {
|
|
167
|
+
a(this, p, await s(this, c).load(t)), a(this, h, s(this, c).locale), a(this, T, Object.freeze(s(this, c).supportedLocales)), a(this, f, t), a(this, g, w(s(this, h))), s(this, d).requestNotification();
|
|
170
168
|
})());
|
|
171
|
-
i.then(e).catch((
|
|
172
|
-
e(), console.error(
|
|
169
|
+
i.then(e).catch((n) => {
|
|
170
|
+
e(), console.error(n);
|
|
173
171
|
});
|
|
174
172
|
};
|
|
175
173
|
export {
|
|
176
|
-
|
|
174
|
+
ht as default
|
|
177
175
|
};
|
|
@@ -1,11 +1,14 @@
|
|
|
1
|
-
|
|
1
|
+
import { all_locales as o } from "../../../translations/index.js";
|
|
2
|
+
const c = "en-US", s = o.en_US, a = {
|
|
2
3
|
year: "numeric",
|
|
3
4
|
month: "2-digit",
|
|
4
5
|
day: "2-digit"
|
|
5
|
-
},
|
|
6
|
+
}, L = ["constructor", "i18n", "watch", "preferredTranslations"], n = (t) => [...new Set(Object.keys(t).map((e) => e.replace(/_/g, "-")).sort())], A = n(o);
|
|
6
7
|
export {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
a as DEFAULT_DATETIME_FORMAT,
|
|
9
|
+
s as DEFAULT_TRANSLATIONS,
|
|
10
|
+
L as EXCLUDE_PROPS,
|
|
11
|
+
c as FALLBACK_LOCALE,
|
|
12
|
+
A as SUPPORTED_LOCALES,
|
|
13
|
+
n as getLocalesFromTranslationSourcesRecord
|
|
11
14
|
};
|
|
@@ -1,19 +1,18 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import p from "./Localization.js";
|
|
1
|
+
import i from "./Localization.js";
|
|
2
|
+
import { loadTranslations as a, formatLocale as l, parseLocale as n } from "./utils.js";
|
|
3
|
+
import { FALLBACK_LOCALE as c, EXCLUDE_PROPS as p } from "./constants/localization.js";
|
|
5
4
|
import { struct as f } from "../../utils/struct/main.js";
|
|
6
5
|
import { isFunction as s } from "../../utils/value/is.js";
|
|
7
|
-
function
|
|
6
|
+
function h() {
|
|
8
7
|
let o = this.locale, r = o, t = [...this.supportedLocales];
|
|
9
8
|
return f({
|
|
10
9
|
load: {
|
|
11
|
-
value: (e) =>
|
|
10
|
+
value: (e) => a(o, this.preferredTranslations, e)
|
|
12
11
|
},
|
|
13
12
|
locale: {
|
|
14
13
|
get: () => o,
|
|
15
14
|
set: (e) => {
|
|
16
|
-
r = e, o =
|
|
15
|
+
r = e, o = l(e) || n(e, t) || c;
|
|
17
16
|
}
|
|
18
17
|
},
|
|
19
18
|
supportedLocales: {
|
|
@@ -24,11 +23,11 @@ function b() {
|
|
|
24
23
|
}
|
|
25
24
|
});
|
|
26
25
|
}
|
|
27
|
-
function
|
|
26
|
+
function b() {
|
|
28
27
|
var r;
|
|
29
28
|
const o = {};
|
|
30
|
-
for (const [t, e] of Object.entries(Object.getOwnPropertyDescriptors(
|
|
31
|
-
|
|
29
|
+
for (const [t, e] of Object.entries(Object.getOwnPropertyDescriptors(i.prototype)))
|
|
30
|
+
p.includes(t) || (s(e.get) ? o[t] = {
|
|
32
31
|
get: e.get.bind(this),
|
|
33
32
|
...t === "timezone" && {
|
|
34
33
|
set: (r = e.set) == null ? void 0 : r.bind(this)
|
|
@@ -41,6 +40,6 @@ function O() {
|
|
|
41
40
|
return o;
|
|
42
41
|
}
|
|
43
42
|
export {
|
|
44
|
-
|
|
45
|
-
|
|
43
|
+
h as createTranslationsLoader,
|
|
44
|
+
b as getLocalizationProxyDescriptors
|
|
46
45
|
};
|
|
@@ -1,66 +1,64 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { en_US as A } from "../../translations/index.js";
|
|
1
|
+
import { FALLBACK_LOCALE as d, DEFAULT_TRANSLATIONS as A } from "./constants/localization.js";
|
|
3
2
|
import { hasOwnProperty as f } from "../../utils/struct/property.js";
|
|
4
|
-
import { EMPTY_OBJECT as
|
|
5
|
-
import {
|
|
6
|
-
|
|
7
|
-
|
|
3
|
+
import { EMPTY_OBJECT as c } from "../../utils/value/constants.js";
|
|
4
|
+
import { isFunction as C } from "../../utils/value/is.js";
|
|
5
|
+
import { asPlainObject as O } from "../../utils/struct/main.js";
|
|
6
|
+
const m = {
|
|
7
|
+
values: c,
|
|
8
8
|
count: 0
|
|
9
|
-
},
|
|
10
|
-
|
|
11
|
-
}, _ = (e) => e.substring(0, 2).toLowerCase();
|
|
12
|
-
function S(e, n) {
|
|
9
|
+
}, p = /^[a-z]{2}-[A-Z]{2}$/, l = (e) => e.substring(0, 2).toLowerCase();
|
|
10
|
+
function g(e, r) {
|
|
13
11
|
if (!e)
|
|
14
12
|
return null;
|
|
15
|
-
const
|
|
16
|
-
return
|
|
13
|
+
const t = l(e);
|
|
14
|
+
return r.find((o) => l(o) === t) || null;
|
|
17
15
|
}
|
|
18
|
-
function
|
|
19
|
-
const
|
|
20
|
-
if (
|
|
21
|
-
return
|
|
22
|
-
const [
|
|
23
|
-
if (!
|
|
16
|
+
function i(e) {
|
|
17
|
+
const r = e.replace("_", "-");
|
|
18
|
+
if (p.test(r))
|
|
19
|
+
return r;
|
|
20
|
+
const [t, o] = r.split("-");
|
|
21
|
+
if (!t || !o)
|
|
24
22
|
return null;
|
|
25
|
-
const
|
|
26
|
-
return
|
|
23
|
+
const n = `${t.toLowerCase()}-${o.toUpperCase()}`;
|
|
24
|
+
return n.length === 5 ? n : null;
|
|
27
25
|
}
|
|
28
|
-
function
|
|
29
|
-
const
|
|
30
|
-
if (!
|
|
31
|
-
return
|
|
32
|
-
const
|
|
33
|
-
return
|
|
26
|
+
function _(e, r) {
|
|
27
|
+
const t = e.trim();
|
|
28
|
+
if (!t || t.length < 1 || t.length > 5)
|
|
29
|
+
return d;
|
|
30
|
+
const o = i(t);
|
|
31
|
+
return o && r.includes(o) ? o : g(o ?? t, r);
|
|
34
32
|
}
|
|
35
|
-
function
|
|
36
|
-
return e ===
|
|
37
|
-
const
|
|
38
|
-
return
|
|
33
|
+
function F(e = c, r) {
|
|
34
|
+
return e === c ? e : Object.keys(e).reduce((t, o) => {
|
|
35
|
+
const n = i(o) || _(o, r);
|
|
36
|
+
return n && e[o] && (t[n] = e[o]), t;
|
|
39
37
|
}, {});
|
|
40
38
|
}
|
|
41
|
-
const L = (e,
|
|
42
|
-
const
|
|
43
|
-
if (f(e,
|
|
44
|
-
return L(e[
|
|
45
|
-
const
|
|
46
|
-
return f(e,
|
|
47
|
-
},
|
|
48
|
-
const
|
|
39
|
+
const L = (e, r) => e.replace(/%{(\w+)}/g, (t, o) => (r == null ? void 0 : r[o]) || ""), N = (e, r, t = m) => {
|
|
40
|
+
const o = t.count ?? 0, n = `${r}__${o}`;
|
|
41
|
+
if (f(e, n) && e[n])
|
|
42
|
+
return L(e[n], t.values);
|
|
43
|
+
const u = `${r}__plural`;
|
|
44
|
+
return f(e, u) && o > 1 && e[u] ? L(e[u], t.values) : f(e, r) && e[r] ? L(e[r], t.values) : null;
|
|
45
|
+
}, S = async (e, r = c, t = c) => {
|
|
46
|
+
const o = _(e, Object.keys(r)) || d, n = r[o];
|
|
49
47
|
return {
|
|
50
|
-
...
|
|
48
|
+
...A,
|
|
51
49
|
// Default en-US translations (in case any other translation file is missing any key)
|
|
52
|
-
...c,
|
|
50
|
+
...await (C(n) ? n() : n) ?? c,
|
|
53
51
|
// Merge with our locale file of the locale they are loading
|
|
54
|
-
...
|
|
52
|
+
...O(t == null ? void 0 : t[e])
|
|
55
53
|
// Merge with their custom locales if available
|
|
56
54
|
};
|
|
57
55
|
};
|
|
58
56
|
export {
|
|
59
|
-
|
|
60
|
-
|
|
57
|
+
F as formatCustomTranslations,
|
|
58
|
+
i as formatLocale,
|
|
61
59
|
N as getTranslation,
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
60
|
+
S as loadTranslations,
|
|
61
|
+
g as matchLocale,
|
|
62
|
+
_ as parseLocale,
|
|
63
|
+
l as toTwoLetterCode
|
|
66
64
|
};
|
package/dist/es/core/core.js
CHANGED
package/dist/es/index.js
CHANGED
|
@@ -1,25 +1,27 @@
|
|
|
1
1
|
import "./components/shared.scss.js";
|
|
2
2
|
import "./style/index.scss.js";
|
|
3
|
-
import
|
|
4
|
-
import { all_locales as l, da_DK as p, de_DE as
|
|
3
|
+
import r from "./core/core.js";
|
|
4
|
+
import { all_locales as l, da_DK as p, de_DE as m, en_US as _, es_ES as c, fr_FR as u, it_IT as d, nl_NL as x, no_NO as v, pt_BR as w, sv_SE as y } from "./translations/index.js";
|
|
5
5
|
import { default as E } from "./components/external/TransactionsOverview/TransactionsOverviewElement.js";
|
|
6
6
|
import { default as P } from "./components/external/TransactionDetails/TransactionDetails.js";
|
|
7
|
-
import { default as
|
|
8
|
-
import { default as
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
import { default as S } from "./components/external/PayoutsOverview/PayoutsOverviewElement.js";
|
|
8
|
+
import { default as N } from "./components/external/PayoutDetails/PayoutDetails.js";
|
|
9
|
+
import { default as A } from "./components/external/ReportsOverview/ReportsOverviewElement.js";
|
|
10
|
+
async function s(e) {
|
|
11
|
+
return await new r(e).initialize();
|
|
11
12
|
}
|
|
12
13
|
export {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
s as AdyenPlatformExperience,
|
|
15
|
+
r as Core,
|
|
16
|
+
N as PayoutDetails,
|
|
17
|
+
S as PayoutsOverview,
|
|
18
|
+
A as ReportsOverview,
|
|
17
19
|
P as TransactionDetails,
|
|
18
20
|
E as TransactionsOverview,
|
|
19
21
|
l as all_locales,
|
|
20
22
|
p as da_DK,
|
|
21
|
-
|
|
22
|
-
|
|
23
|
+
m as de_DE,
|
|
24
|
+
_ as en_US,
|
|
23
25
|
c as es_ES,
|
|
24
26
|
u as fr_FR,
|
|
25
27
|
d as it_IT,
|