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

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (120) hide show
  1. package/dist/adyen-platform-experience-web.css +1 -1
  2. package/dist/{angle-right-DYQ6toZV.cjs → angle-right-BWzcy0ip.cjs} +2 -2
  3. package/dist/{angle-right-DYQ6toZV.cjs.map → angle-right-BWzcy0ip.cjs.map} +1 -1
  4. package/dist/{checkmark-BvHe3XDD.cjs → checkmark-DfFWWmc9.cjs} +2 -2
  5. package/dist/{checkmark-BvHe3XDD.cjs.map → checkmark-DfFWWmc9.cjs.map} +1 -1
  6. package/dist/{checkmark-circle-fill-BBm-SExF.cjs → checkmark-circle-fill-6Nbm2YQh.cjs} +2 -2
  7. package/dist/{checkmark-circle-fill-BBm-SExF.cjs.map → checkmark-circle-fill-6Nbm2YQh.cjs.map} +1 -1
  8. package/dist/{checkmark-square-fill-GaJYfE7I.cjs → checkmark-square-fill-U1_7-7K9.cjs} +2 -2
  9. package/dist/{checkmark-square-fill-GaJYfE7I.cjs.map → checkmark-square-fill-U1_7-7K9.cjs.map} +1 -1
  10. package/dist/{chevron-down-DiKqNmGu.cjs → chevron-down-BSR5ajTW.cjs} +2 -2
  11. package/dist/{chevron-down-DiKqNmGu.cjs.map → chevron-down-BSR5ajTW.cjs.map} +1 -1
  12. package/dist/{chevron-left-D2wsIWaC.cjs → chevron-left-C1QqpQ4S.cjs} +2 -2
  13. package/dist/{chevron-left-D2wsIWaC.cjs.map → chevron-left-C1QqpQ4S.cjs.map} +1 -1
  14. package/dist/{chevron-right-ClwwBk5G.cjs → chevron-right-C9cu2vQN.cjs} +2 -2
  15. package/dist/{chevron-right-ClwwBk5G.cjs.map → chevron-right-C9cu2vQN.cjs.map} +1 -1
  16. package/dist/{chevron-up-CjIuhiba.cjs → chevron-up-QJhPvS-j.cjs} +2 -2
  17. package/dist/{chevron-up-CjIuhiba.cjs.map → chevron-up-QJhPvS-j.cjs.map} +1 -1
  18. package/dist/cjs/index.js +1 -1
  19. package/dist/{copy-DWaCTvhj.cjs → copy-CvOYWx2Z.cjs} +2 -2
  20. package/dist/{copy-DWaCTvhj.cjs.map → copy-CvOYWx2Z.cjs.map} +1 -1
  21. package/dist/{cross-BaBGJ7V7.cjs → cross-C1NPFb0O.cjs} +2 -2
  22. package/dist/{cross-BaBGJ7V7.cjs.map → cross-C1NPFb0O.cjs.map} +1 -1
  23. package/dist/{cross-circle-fill-D1r6vt_G.cjs → cross-circle-fill-BIL8DKBy.cjs} +2 -2
  24. package/dist/{cross-circle-fill-D1r6vt_G.cjs.map → cross-circle-fill-BIL8DKBy.cjs.map} +1 -1
  25. package/dist/{download-BwlYYru1.cjs → download-B0HG76gQ.cjs} +2 -2
  26. package/dist/{download-BwlYYru1.cjs.map → download-B0HG76gQ.cjs.map} +1 -1
  27. package/dist/es/assets/translations/en-US.json.js +4 -0
  28. package/dist/es/components/external/CapitalOffer/components/CapitalOfferSummary/CapitalOfferSummary.js +21 -21
  29. package/dist/es/components/external/CapitalOverview/components/GrantDetails/GrantDetails.js +24 -24
  30. package/dist/es/components/external/CapitalOverview/components/GrantItem/GrantItem.js +6 -6
  31. package/dist/es/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeFlow.js +21 -17
  32. package/dist/es/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeReason.js +93 -90
  33. package/dist/es/components/external/DisputeManagement/components/DisputesData/DisputeData.js +113 -113
  34. package/dist/es/components/external/DisputesOverview/components/DisputesOverview/DisputesOverview.js +1 -1
  35. package/dist/es/components/external/TransactionsOverview/components/SummaryItem/SummaryItem.js +18 -18
  36. package/dist/es/components/external/TransactionsOverview/components/TransactionTotalItem/TransactionTotalItem.js +2 -2
  37. package/dist/es/components/external/TransactionsOverview/components/TransactionTotals/TotalsCard.js +17 -17
  38. package/dist/es/components/external/TransactionsOverview/components/TransactionsTable/TransactionsTable.js +26 -26
  39. package/dist/es/components/external/TransactionsOverview/components/utils.js +6 -5
  40. package/dist/es/components/internal/Calendar/hooks/useTimezone.js +20 -20
  41. package/dist/es/components/internal/CopyText/CopyText.js +49 -68
  42. package/dist/es/components/internal/DatePicker/components/TimeRangeSelector/useTimeRangeSelection.js +17 -16
  43. package/dist/es/components/internal/FormFields/InputBase.js +59 -52
  44. package/dist/es/components/internal/FormFields/utils.js +20 -0
  45. package/dist/es/components/internal/Tooltip/Tooltip.js +14 -14
  46. package/dist/es/components/types.js +1 -1
  47. package/dist/es/components/utils/capital/getCapitalErrorMessage.js +6 -6
  48. package/dist/es/components/utils/disputes/getDisputesErrorMessage.js +3 -3
  49. package/dist/es/core/Analytics/analytics/customTranslations.js +6 -6
  50. package/dist/es/core/Http/utils.js +1 -1
  51. package/dist/es/core/Localization/datetime/restamper/restamper.js +1 -1
  52. package/dist/es/core/Localization/datetime/restamper/utils.js +21 -21
  53. package/dist/es/core/core.js +1 -1
  54. package/dist/es/hooks/useAnalytics/useAnalytics.js +1 -1
  55. package/dist/es/hooks/useDefaultOverviewFilterParams.js +12 -12
  56. package/dist/es/primitives/async/abortable/main.js +22 -21
  57. package/dist/{external-link-C2HjWZuO.cjs → external-link-BpOC7Iux.cjs} +2 -2
  58. package/dist/{external-link-C2HjWZuO.cjs.map → external-link-BpOC7Iux.cjs.map} +1 -1
  59. package/dist/{filter-BIRwG0Vl.cjs → filter-D2r4Jsb0.cjs} +2 -2
  60. package/dist/{filter-BIRwG0Vl.cjs.map → filter-D2r4Jsb0.cjs.map} +1 -1
  61. package/dist/index-C2bfolFC.cjs +12 -0
  62. package/dist/index-C2bfolFC.cjs.map +1 -0
  63. package/dist/{info-filled-vKjjns_Y.cjs → info-filled-BnyHuXP-.cjs} +2 -2
  64. package/dist/{info-filled-vKjjns_Y.cjs.map → info-filled-BnyHuXP-.cjs.map} +1 -1
  65. package/dist/{minus-circle-outline-eV-2HTVp.cjs → minus-circle-outline-BCQ8qMpL.cjs} +2 -2
  66. package/dist/{minus-circle-outline-eV-2HTVp.cjs.map → minus-circle-outline-BCQ8qMpL.cjs.map} +1 -1
  67. package/dist/{plus-BBN-BevV.cjs → plus-C4IhUDjd.cjs} +2 -2
  68. package/dist/{plus-BBN-BevV.cjs.map → plus-C4IhUDjd.cjs.map} +1 -1
  69. package/dist/{plus-circle-outline-D9hOKkhU.cjs → plus-circle-outline-Di_cvYHz.cjs} +2 -2
  70. package/dist/{plus-circle-outline-D9hOKkhU.cjs.map → plus-circle-outline-Di_cvYHz.cjs.map} +1 -1
  71. package/dist/{square-CTh_Pt6M.cjs → square-CxVyMMY-.cjs} +2 -2
  72. package/dist/{square-CTh_Pt6M.cjs.map → square-CxVyMMY-.cjs.map} +1 -1
  73. package/dist/{trash-can-DLq5jE_J.cjs → trash-can-DJheGbfF.cjs} +2 -2
  74. package/dist/{trash-can-DLq5jE_J.cjs.map → trash-can-DJheGbfF.cjs.map} +1 -1
  75. package/dist/types/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeFlow.d.ts.map +1 -1
  76. package/dist/types/components/external/DisputeManagement/components/DefendDisputeFlow/DefendDisputeReason.d.ts.map +1 -1
  77. package/dist/types/components/external/DisputeManagement/components/DisputesData/DisputeData.d.ts.map +1 -1
  78. package/dist/types/components/external/TransactionsOverview/components/SummaryItem/SummaryItem.d.ts +1 -1
  79. package/dist/types/components/external/TransactionsOverview/components/SummaryItem/SummaryItem.d.ts.map +1 -1
  80. package/dist/types/components/external/TransactionsOverview/components/SummaryItem/types.d.ts +2 -2
  81. package/dist/types/components/external/TransactionsOverview/components/SummaryItem/types.d.ts.map +1 -1
  82. package/dist/types/components/external/TransactionsOverview/components/TransactionTotalItem/TransactionTotalItem.d.ts +1 -1
  83. package/dist/types/components/external/TransactionsOverview/components/TransactionTotalItem/TransactionTotalItem.d.ts.map +1 -1
  84. package/dist/types/components/external/TransactionsOverview/components/TransactionTotalItem/types.d.ts +1 -1
  85. package/dist/types/components/external/TransactionsOverview/components/TransactionTotalItem/types.d.ts.map +1 -1
  86. package/dist/types/components/external/TransactionsOverview/components/utils.d.ts.map +1 -1
  87. package/dist/types/components/internal/Calendar/hooks/useTimezone.d.ts.map +1 -1
  88. package/dist/types/components/internal/CopyText/CopyText.d.ts +3 -3
  89. package/dist/types/components/internal/CopyText/CopyText.d.ts.map +1 -1
  90. package/dist/types/components/internal/DatePicker/components/TimeRangeSelector/useTimeRangeSelection.d.ts +3 -19
  91. package/dist/types/components/internal/DatePicker/components/TimeRangeSelector/useTimeRangeSelection.d.ts.map +1 -1
  92. package/dist/types/components/internal/FormFields/InputBase.d.ts.map +1 -1
  93. package/dist/types/components/internal/FormFields/types.d.ts +1 -2
  94. package/dist/types/components/internal/FormFields/types.d.ts.map +1 -1
  95. package/dist/types/components/internal/FormFields/utils.d.ts +9 -0
  96. package/dist/types/components/internal/FormFields/utils.d.ts.map +1 -0
  97. package/dist/types/components/internal/StructuredList/useStructuredListItem.d.ts +1 -1
  98. package/dist/types/components/internal/Tooltip/Tooltip.d.ts +1 -1
  99. package/dist/types/components/internal/Tooltip/types.d.ts +1 -1
  100. package/dist/types/components/types.d.ts +2 -1
  101. package/dist/types/components/types.d.ts.map +1 -1
  102. package/dist/types/core/Analytics/analytics/customTranslations.d.ts.map +1 -1
  103. package/dist/types/core/Localization/datetime/restamper/utils.d.ts.map +1 -1
  104. package/dist/types/core/utils.d.ts.map +1 -1
  105. package/dist/types/hooks/useDefaultOverviewFilterParams.d.ts +14 -20
  106. package/dist/types/hooks/useDefaultOverviewFilterParams.d.ts.map +1 -1
  107. package/dist/types/primitives/async/abortable/main.d.ts.map +1 -1
  108. package/dist/types/primitives/async/abortable/types.d.ts +1 -1
  109. package/dist/types/primitives/async/abortable/types.d.ts.map +1 -1
  110. package/dist/types/translations/index.d.ts +4 -0
  111. package/dist/types/translations/index.d.ts.map +1 -1
  112. package/dist/{upload-Cbt8Rwse.cjs → upload-CTy5JC9H.cjs} +2 -2
  113. package/dist/{upload-Cbt8Rwse.cjs.map → upload-CTy5JC9H.cjs.map} +1 -1
  114. package/dist/{warning-DB0fHdXY.cjs → warning-CUSU9so2.cjs} +2 -2
  115. package/dist/{warning-DB0fHdXY.cjs.map → warning-CUSU9so2.cjs.map} +1 -1
  116. package/dist/{warning-filled-B14QLF2h.cjs → warning-filled-OlZVURzS.cjs} +2 -2
  117. package/dist/{warning-filled-B14QLF2h.cjs.map → warning-filled-OlZVURzS.cjs.map} +1 -1
  118. package/package.json +2 -2
  119. package/dist/index-COVW71Qe.cjs +0 -12
  120. package/dist/index-COVW71Qe.cjs.map +0 -1
@@ -1,47 +1,47 @@
1
1
  import { jsx as t } from "../../../../../external/preact/jsx-runtime/dist/jsxRuntime.module.js";
2
- import { AmountSkeleton as f } from "../AmountSkeleton/AmountSkeleton.js";
3
- import { BASE_CLASS as S, PLACEHOLDER_CLASS as T, AMOUNT_CLASS as b, LABEL_CLASS as E, BODY_CLASS as N } from "./constants.js";
2
+ import { AmountSkeleton as b } from "../AmountSkeleton/AmountSkeleton.js";
3
+ import { BASE_CLASS as S, PLACEHOLDER_CLASS as f, AMOUNT_CLASS as T, LABEL_CLASS as E, BODY_CLASS as N } from "./constants.js";
4
4
  import { SummaryItemLabel as h } from "./SummaryItemLabel.js";
5
5
  import { Tooltip as B } from "../../../../internal/Tooltip/Tooltip.js";
6
- import { TypographyVariant as s, TypographyElement as I } from "../../../../internal/Typography/types.js";
6
+ import { TypographyVariant as n, TypographyElement as I } from "../../../../internal/Typography/types.js";
7
7
  import O from "../../../../internal/Typography/Typography.js";
8
8
  import _ from "../../../../../core/Context/useCoreContext.js";
9
9
  import p from "classnames";
10
- import { useEffect as x, useCallback as H } from "../../../../../external/preact/hooks/dist/hooks.module.js";
10
+ import { useEffect as x, useCallback as D } from "../../../../../external/preact/hooks/dist/hooks.module.js";
11
11
  /* empty css */
12
- import { useResponsiveContainer as D, containerQueries as M } from "../../../../../hooks/useResponsiveContainer.js";
12
+ import { useResponsiveContainer as H, containerQueries as M } from "../../../../../hooks/useResponsiveContainer.js";
13
13
  const $ = ({
14
14
  columnConfigs: i,
15
15
  isHeader: u = !1,
16
- isHovered: C = !1,
17
- isSkeletonVisible: l = !1,
18
- isLoading: d = !1,
16
+ showLabelUnderline: d = !1,
17
+ isSkeletonVisible: o = !1,
18
+ isLoading: C = !1,
19
19
  widths: m,
20
20
  onWidthsSet: L,
21
21
  isEmpty: A
22
22
  }) => {
23
- const { i18n: n } = _();
23
+ const { i18n: s } = _();
24
24
  x(() => {
25
25
  const e = i.map((r) => {
26
- var a, o;
27
- return ((o = (a = r.ref) == null ? void 0 : a.current) == null ? void 0 : o.getBoundingClientRect().width) ?? 0;
26
+ var a, l;
27
+ return ((l = (a = r.ref) == null ? void 0 : a.current) == null ? void 0 : l.getBoundingClientRect().width) ?? 0;
28
28
  });
29
29
  L(e);
30
30
  }, [L]);
31
- const c = (e) => ({ width: m && m[e] ? m[e] : "auto" }), y = D(M.only.xs), v = H(
32
- (e, r) => e.valueHasLabelStyle ? s.CAPTION : r && !y ? s.BODY : s.TITLE,
31
+ const c = (e) => ({ width: m && m[e] ? m[e] : "auto" }), y = H(M.only.xs), v = D(
32
+ (e, r) => e.valueHasLabelStyle ? n.CAPTION : r && !y ? n.BODY : n.TITLE,
33
33
  [y]
34
34
  );
35
35
  return /* @__PURE__ */ t("div", { className: p(S, { [N]: !u }), children: i.map((e, r) => {
36
- const a = e.getValue(), o = !!a && a.length > 12;
36
+ const a = e.getValue(), l = !!a && a.length > 12;
37
37
  return /* @__PURE__ */ t("div", { children: [
38
- u && /* @__PURE__ */ t("div", { role: "presentation", children: e.tooltipLabel ? /* @__PURE__ */ t(B, { content: n.get(`${e.tooltipLabel}`), isContainerHovered: C, children: /* @__PURE__ */ t(h, { config: e, i18n: n, isSkeletonVisible: l }) }) : /* @__PURE__ */ t(h, { config: e, i18n: n, isSkeletonVisible: l }) }),
39
- l ? /* @__PURE__ */ t(f, { isLoading: d, hasMargin: e.hasSkeletonMargin, width: e.skeletonWidth + "px" }) : A ? /* @__PURE__ */ t("span", { className: p([S, T]) }) : /* @__PURE__ */ t("div", { id: e.elemId, ref: e.ref, style: c(r), "aria-label": e.ariaLabel, role: "presentation", children: /* @__PURE__ */ t(
38
+ u && /* @__PURE__ */ t("div", { role: "presentation", children: e.tooltipLabel ? /* @__PURE__ */ t(B, { content: s.get(`${e.tooltipLabel}`), isUnderlineVisible: d, children: /* @__PURE__ */ t(h, { config: e, i18n: s, isSkeletonVisible: o }) }) : /* @__PURE__ */ t(h, { config: e, i18n: s, isSkeletonVisible: o }) }),
39
+ o ? /* @__PURE__ */ t(b, { isLoading: C, hasMargin: e.hasSkeletonMargin, width: e.skeletonWidth + "px" }) : A ? /* @__PURE__ */ t("span", { className: p([S, f]) }) : /* @__PURE__ */ t("div", { id: e.elemId, ref: e.ref, style: c(r), "aria-label": e.ariaLabel, role: "presentation", children: /* @__PURE__ */ t(
40
40
  O,
41
41
  {
42
42
  el: I.SPAN,
43
- variant: v(e, o),
44
- className: p({ [E]: e.valueHasLabelStyle, [b]: !e.valueHasLabelStyle }),
43
+ variant: v(e, l),
44
+ className: p({ [E]: e.valueHasLabelStyle, [T]: !e.valueHasLabelStyle }),
45
45
  children: a
46
46
  }
47
47
  ) })
@@ -6,7 +6,7 @@ const K = ({
6
6
  total: e,
7
7
  hiddenField: n,
8
8
  isHeader: o = !1,
9
- isHovered: i = !1,
9
+ showLabelUnderline: i = !1,
10
10
  isSkeleton: r = !1,
11
11
  isLoading: a = !1,
12
12
  widths: l,
@@ -50,7 +50,7 @@ const K = ({
50
50
  return /* @__PURE__ */ x(
51
51
  C,
52
52
  {
53
- isHovered: i,
53
+ showLabelUnderline: i,
54
54
  isEmpty: !e,
55
55
  columnConfigs: y,
56
56
  isHeader: o,
@@ -1,24 +1,24 @@
1
1
  import { jsx as r } from "../../../../../external/preact/jsx-runtime/dist/jsxRuntime.module.js";
2
2
  import { memo as h } from "../../../../../external/preact/compat/dist/compat.module.js";
3
3
  import { useState as $, useMemo as i } from "../../../../../external/preact/hooks/dist/hooks.module.js";
4
- import y from "../../../../../core/Context/useCoreContext.js";
5
- import w from "../../../../internal/ExpandableCard/ExpandableCard.js";
4
+ import w from "../../../../../core/Context/useCoreContext.js";
5
+ import y from "../../../../internal/ExpandableCard/ExpandableCard.js";
6
6
  import { TransactionTotalItem as v } from "../TransactionTotalItem/TransactionTotalItem.js";
7
7
  import { useMaxWidthsState as M } from "../../hooks/useMaxWidths.js";
8
8
  /* empty css */
9
9
  import { Fragment as C } from "../../../../../external/preact/dist/preact.module.js";
10
10
  import { uniqueId as I } from "../../../../../utils/random/uniqueId.js";
11
- const P = h(({ totals: p, isLoading: o, hiddenField: t, fullWidth: x, ...E }) => {
12
- const { i18n: n } = y(), [m, a] = M(), [l, c] = $(!1), d = i(() => n.get("transactions.overview.totals.currency.label"), [n]), [s, ...u] = i(() => p.map((e) => (e.key = `${e.currency}-${Math.random()}`, e.expensesElemId = I("elem"), e.incomingsElemId = I("elem"), e)), [p]), f = i(() => {
13
- switch (t) {
11
+ const B = h(({ totals: p, isLoading: o, hiddenField: n, fullWidth: x, ...E }) => {
12
+ const { i18n: t } = w(), [m, a] = M(), [l, c] = $(!1), d = i(() => t.get("transactions.overview.totals.currency.label"), [t]), [s, ...u] = i(() => p.map((e) => (e.key = `${e.currency}-${Math.random()}`, e.expensesElemId = I("elem"), e.incomingsElemId = I("elem"), e)), [p]), f = i(() => {
13
+ switch (n) {
14
14
  case "expenses":
15
- return n.get("transactions.overview.totals.lists.incoming");
15
+ return t.get("transactions.overview.totals.lists.incoming");
16
16
  case "incomings":
17
- return n.get("transactions.overview.totals.lists.outgoing");
17
+ return t.get("transactions.overview.totals.lists.outgoing");
18
18
  default:
19
- return n.get("transactions.overview.totals.lists.default");
19
+ return t.get("transactions.overview.totals.lists.default");
20
20
  }
21
- }, [n, t]), g = i(
21
+ }, [t, n]), g = i(
22
22
  () => /* @__PURE__ */ r(
23
23
  "div",
24
24
  {
@@ -28,9 +28,9 @@ const P = h(({ totals: p, isLoading: o, hiddenField: t, fullWidth: x, ...E }) =>
28
28
  children: /* @__PURE__ */ r(
29
29
  v,
30
30
  {
31
- isHovered: l,
31
+ showLabelUnderline: l,
32
32
  total: s,
33
- hiddenField: t,
33
+ hiddenField: n,
34
34
  widths: m,
35
35
  isHeader: !0,
36
36
  isSkeleton: o,
@@ -42,7 +42,7 @@ const P = h(({ totals: p, isLoading: o, hiddenField: t, fullWidth: x, ...E }) =>
42
42
  )
43
43
  }
44
44
  ),
45
- [l, s, t, m, o, a, d]
45
+ [l, s, n, m, o, a, d]
46
46
  ), b = i(() => !o && u.length ? /* @__PURE__ */ r(C, { children: u.map((e) => /* @__PURE__ */ r(
47
47
  "div",
48
48
  {
@@ -52,9 +52,9 @@ const P = h(({ totals: p, isLoading: o, hiddenField: t, fullWidth: x, ...E }) =>
52
52
  children: /* @__PURE__ */ r(
53
53
  v,
54
54
  {
55
- isHovered: l,
55
+ showLabelUnderline: l,
56
56
  total: e,
57
- hiddenField: t,
57
+ hiddenField: n,
58
58
  widths: m,
59
59
  onWidthsSet: a,
60
60
  expensesElemId: e.expensesElemId,
@@ -63,9 +63,9 @@ const P = h(({ totals: p, isLoading: o, hiddenField: t, fullWidth: x, ...E }) =>
63
63
  )
64
64
  },
65
65
  e.key
66
- )) }) : void 0, [o, u, l, t, m, a, d]);
66
+ )) }) : void 0, [o, u, l, n, m, a, d]);
67
67
  return /* @__PURE__ */ r(
68
- w,
68
+ y,
69
69
  {
70
70
  renderContent: ({ collapsibleContent: e }) => /* @__PURE__ */ r("div", { role: "list", "aria-label": f, children: [
71
71
  g,
@@ -82,5 +82,5 @@ const P = h(({ totals: p, isLoading: o, hiddenField: t, fullWidth: x, ...E }) =>
82
82
  );
83
83
  });
84
84
  export {
85
- P as TotalsCard
85
+ B as TotalsCard
86
86
  };
@@ -1,22 +1,22 @@
1
1
  import { jsx as t } from "../../../../../external/preact/jsx-runtime/dist/jsxRuntime.module.js";
2
- import { useState as H, useCallback as I, useMemo as x } from "../../../../../external/preact/hooks/dist/hooks.module.js";
3
- import K from "../../../../internal/DataOverviewError/DataOverviewError.js";
4
- import U from "../../../../../core/Context/useCoreContext.js";
2
+ import { useState as I, useCallback as x, useMemo as H } from "../../../../../external/preact/hooks/dist/hooks.module.js";
3
+ import U from "../../../../internal/DataOverviewError/DataOverviewError.js";
4
+ import K from "../../../../../core/Context/useCoreContext.js";
5
5
  import { getCurrencyCode as B } from "../../../../../core/Localization/amount/amount-util.js";
6
6
  import $ from "../../../../../hooks/useTimezoneAwareDateFormatting.js";
7
7
  import { Tooltip as G } from "../../../../internal/Tooltip/Tooltip.js";
8
8
  import { TypographyVariant as n, TypographyElement as a } from "../../../../internal/Typography/types.js";
9
9
  import i from "../../../../internal/Typography/Typography.js";
10
- import { getTransactionCategory as j, getTransactionCategoryDescription as q } from "../../../../utils/translation/getters.js";
10
+ import { getTransactionCategory as V, getTransactionCategoryDescription as j } from "../../../../utils/translation/getters.js";
11
11
  import { useResponsiveContainer as c, containerQueries as d } from "../../../../../hooks/useResponsiveContainer.js";
12
- import { BASE_CLASS as z, DATE_AND_PAYMENT_METHOD_CLASS as Q, DATE_METHOD_CLASS as V, AMOUNT_CLASS as X } from "./constants.js";
12
+ import { BASE_CLASS as q, DATE_AND_PAYMENT_METHOD_CLASS as z, DATE_METHOD_CLASS as Q, AMOUNT_CLASS as X } from "./constants.js";
13
13
  /* empty css */
14
14
  import S from "./PaymentMethodCell.js";
15
15
  import { useTableColumns as Z } from "../../../../../hooks/useTableColumns.js";
16
16
  import g from "../../../../internal/DataGrid/DataGrid.js";
17
17
  import J from "../../../../internal/Pagination/Pagination.js";
18
18
  import { DATE_FORMAT_TRANSACTIONS_MOBILE as W, DATE_FORMAT_TRANSACTIONS as tt } from "../../../../../constants/dateFormats.js";
19
- const et = ["createdAt", "paymentMethod", "transactionType", "amount"], C = {
19
+ const et = ["createdAt", "paymentMethod", "transactionType", "amount"], M = {
20
20
  amount: "transactions.overview.list.fields.amount",
21
21
  createdAt: "transactions.overview.list.fields.createdAt",
22
22
  // currency: 'transactions.overview.list.fields.currency',
@@ -28,19 +28,19 @@ const et = ["createdAt", "paymentMethod", "transactionType", "amount"], C = {
28
28
  availableCurrencies: m,
29
29
  error: l,
30
30
  hasMultipleCurrencies: p,
31
- loading: M,
31
+ loading: C,
32
32
  onContactSupport: A,
33
33
  onRowClick: D,
34
34
  showDetails: ot,
35
35
  showPagination: E,
36
- transactions: w,
37
- customColumns: N,
38
- ..._
36
+ transactions: b,
37
+ customColumns: w,
38
+ ...N
39
39
  }) => {
40
- const { i18n: r } = U(), { dateFormat: T } = $(s == null ? void 0 : s.timeZone), [b, y] = H(), u = c(d.up.sm), O = c(d.up.md), L = c(d.down.xs), R = r.get(C.amount), F = Z({
41
- customColumns: N,
40
+ const { i18n: r } = K(), { dateFormat: T } = $(s == null ? void 0 : s.timeZone), [_, y] = I(), u = c(d.up.sm), O = c(d.up.md), L = c(d.down.xs), R = r.get(M.amount), F = Z({
41
+ customColumns: w,
42
42
  fields: et,
43
- fieldsKeys: C,
43
+ fieldsKeys: M,
44
44
  columnConfig: {
45
45
  amount: {
46
46
  label: p ? void 0 : `${R} ${m && m[0] ? `(${B(m[0])})` : ""}`,
@@ -53,23 +53,23 @@ const et = ["createdAt", "paymentMethod", "transactionType", "amount"], C = {
53
53
  }), P = {
54
54
  title: "transactions.overview.errors.listEmpty",
55
55
  message: ["common.errors.updateFilters"]
56
- }, k = I(
56
+ }, k = x(
57
57
  (e) => {
58
58
  y(e ?? void 0);
59
59
  },
60
60
  [y]
61
- ), Y = x(
62
- () => () => /* @__PURE__ */ t(K, { error: l, onContactSupport: A, errorMessage: "transactions.overview.errors.listUnavailable" }),
61
+ ), Y = H(
62
+ () => () => /* @__PURE__ */ t(U, { error: l, onContactSupport: A, errorMessage: "transactions.overview.errors.listUnavailable" }),
63
63
  [l, A]
64
64
  );
65
- return /* @__PURE__ */ t("div", { className: z, children: /* @__PURE__ */ t(
65
+ return /* @__PURE__ */ t("div", { className: q, children: /* @__PURE__ */ t(
66
66
  g,
67
67
  {
68
68
  errorDisplay: Y,
69
69
  error: l,
70
70
  columns: F,
71
- data: w,
72
- loading: M,
71
+ data: b,
72
+ loading: C,
73
73
  outline: !1,
74
74
  onRowClick: { callback: D },
75
75
  onRowHover: k,
@@ -85,10 +85,10 @@ const et = ["createdAt", "paymentMethod", "transactionType", "amount"], C = {
85
85
  // );
86
86
  // },
87
87
  transactionType: ({ item: e, rowIndex: o }) => {
88
- const v = j(r, e.category);
89
- if (v) {
90
- const f = q(r, e.category), h = () => /* @__PURE__ */ t(i, { el: a.SPAN, variant: n.BODY, children: v });
91
- return f ? /* @__PURE__ */ t(G, { content: f, isContainerHovered: o === b, children: /* @__PURE__ */ t("span", { children: h() }) }) : h();
88
+ const f = V(r, e.category);
89
+ if (f) {
90
+ const h = j(r, e.category), v = () => /* @__PURE__ */ t(i, { el: a.SPAN, variant: n.BODY, children: f });
91
+ return h ? /* @__PURE__ */ t(G, { content: h, isUnderlineVisible: o === _, children: /* @__PURE__ */ t("span", { children: v() }) }) : v();
92
92
  }
93
93
  return null;
94
94
  },
@@ -96,16 +96,16 @@ const et = ["createdAt", "paymentMethod", "transactionType", "amount"], C = {
96
96
  const o = r.amount(e.value, e.currency, { hideCurrency: !p });
97
97
  return /* @__PURE__ */ t(i, { el: a.SPAN, variant: n.BODY, className: X, children: o });
98
98
  },
99
- createdAt: ({ item: e, value: o }) => L ? /* @__PURE__ */ t("div", { className: Q, children: [
99
+ createdAt: ({ item: e, value: o }) => L ? /* @__PURE__ */ t("div", { className: z, children: [
100
100
  /* @__PURE__ */ t(S, { paymentMethod: e.paymentMethod, bankAccount: e.bankAccount }),
101
- /* @__PURE__ */ t("time", { dateTime: e.createdAt, className: V, children: /* @__PURE__ */ t(i, { el: a.SPAN, variant: n.BODY, children: T(e.createdAt, W) }) })
101
+ /* @__PURE__ */ t("time", { dateTime: e.createdAt, className: Q, children: /* @__PURE__ */ t(i, { el: a.SPAN, variant: n.BODY, children: T(e.createdAt, W) }) })
102
102
  ] }) : /* @__PURE__ */ t("time", { dateTime: o, children: /* @__PURE__ */ t(i, { el: a.SPAN, variant: n.BODY, children: T(o, tt) }) }),
103
103
  paymentMethod: ({ item: e }) => /* @__PURE__ */ t(S, { paymentMethod: e.paymentMethod, bankAccount: e.bankAccount })
104
104
  },
105
105
  children: E && /* @__PURE__ */ t(g.Footer, { children: /* @__PURE__ */ t(
106
106
  J,
107
107
  {
108
- ..._,
108
+ ...N,
109
109
  ariaLabelKey: "transactions.overview.pagination.label",
110
110
  limitSelectAriaLabelKey: "transactions.overview.pagination.controls.limitSelect.label"
111
111
  }
@@ -1,10 +1,11 @@
1
- const a = Object.freeze({
1
+ const i = Object.freeze({
2
2
  klarna: "Klarna",
3
- paypal: "PayPal"
3
+ paypal: "PayPal",
4
+ klarna_paynow: "Klarna Pay Now"
4
5
  });
5
- function s(r, i) {
6
- return r.lastFourDigits ? i === "detail" ? "•••• •••• •••• " + r.lastFourDigits : r.lastFourDigits : r.description || a[r.type] || r.type;
6
+ function l(a, r) {
7
+ return a.lastFourDigits ? r === "detail" ? "•••• •••• •••• " + a.lastFourDigits : a.lastFourDigits : a.description || i[a.type] || a.type;
7
8
  }
8
9
  export {
9
- s as parsePaymentMethodType
10
+ l as parsePaymentMethodType
10
11
  };
@@ -1,28 +1,28 @@
1
- import { useMemo as c, useRef as d, useState as g } from "../../../../external/preact/hooks/dist/hooks.module.js";
2
- import { getTimezoneOffsetFromFormattedDateString as l, getGMTSuffixForTimezoneOffset as E } from "../../../../core/Localization/datetime/restamper/utils.js";
1
+ import { useMemo as c, useState as d, useEffect as g } from "../../../../external/preact/hooks/dist/hooks.module.js";
2
+ import { getTimezoneOffsetFromFormattedDateString as p, getGMTSuffixForTimezoneOffset as E } from "../../../../core/Localization/datetime/restamper/utils.js";
3
3
  import { clock as M } from "../../../../primitives/time/clock/main.js";
4
- import { isWatchlistUnsubscribeToken as _ } from "../../../../primitives/reactive/watchlist/main.js";
5
- import G from "../../../../core/Localization/datetime/restamper/restamper.js";
6
- import { EMPTY_OBJECT as O, EMPTY_ARRAY as S } from "../../../../utils/value/constants.js";
7
- import { boolOrFalse as R } from "../../../../utils/value/bool.js";
8
- import { noop as a } from "../../../../utils/common.js";
9
- const { getTimezoneTime: U, getUsedTimezone: A } = (() => {
10
- const m = /\d{2}:\d{2}(?=:\d{2}(?:\.\d+)?\s+([AP]M))/i, n = /^GMT|0(?=\d:00)|:00/g, e = G();
11
- return { getTimezoneTime: (t, i = Date.now()) => {
4
+ import { isWatchlistUnsubscribeToken as l } from "../../../../primitives/reactive/watchlist/main.js";
5
+ import _ from "../../../../core/Localization/datetime/restamper/restamper.js";
6
+ import { EMPTY_OBJECT as G, EMPTY_ARRAY as O } from "../../../../utils/value/constants.js";
7
+ import { boolOrFalse as S } from "../../../../utils/value/bool.js";
8
+ const { getTimezoneTime: U, getUsedTimezone: F } = (() => {
9
+ const s = /\d{2}:\d{2}(?=:\d{2}(?:\.\d+)?\s+([AP]M))/i, m = /^GMT|0(?=\d:00)|:00/g, e = _();
10
+ return { getTimezoneTime: (t, T = Date.now()) => {
12
11
  e.tz = t;
13
- const { formatted: o } = e(i), [f = "", s = ""] = (o == null ? void 0 : o.match(m)) ?? S, u = l(o), z = `${f}${s && ` ${s}`}`, p = E(u).replace(n, "");
14
- return [z, p];
12
+ const { formatted: o } = e(T), [i = "", f = ""] = (o == null ? void 0 : o.match(s)) ?? O, a = p(o), u = `${i}${f && ` ${f}`}`, z = E(a).replace(m, "");
13
+ return [u, z];
15
14
  }, getUsedTimezone: (t) => (e.tz = t, e.tz.current) };
16
- })(), N = ({ timezone: m, withClock: n = !1 } = O) => {
17
- const e = c(() => R(n), [n]), r = c(() => A(m), [m]), T = d(a), [t, i] = g(Date.now()), [o, f] = c(() => U(r, t), [t, r]);
18
- return c(() => {
19
- T.current(), T.current = e ? M.subscribe((s) => {
20
- _(s) || i(s.now);
21
- }) : a;
22
- }, [i, e]), { clockTime: o, GMTOffset: f, timestamp: t, timezone: r };
15
+ })(), N = ({ timezone: s, withClock: m = !1 } = G) => {
16
+ const e = c(() => S(m), [m]), n = c(() => F(s), [s]), [r, t] = d(Date.now()), [T, o] = c(() => U(n, r), [r, n]);
17
+ return g(() => {
18
+ if (e)
19
+ return M.subscribe((i) => {
20
+ l(i) || t(i.now);
21
+ });
22
+ }, [t, e]), { clockTime: T, GMTOffset: o, timestamp: r, timezone: n };
23
23
  };
24
24
  export {
25
25
  N as default,
26
26
  U as getTimezoneTime,
27
- A as getUsedTimezone
27
+ F as getUsedTimezone
28
28
  };
@@ -1,86 +1,67 @@
1
- import { jsx as o } from "../../../external/preact/jsx-runtime/dist/jsxRuntime.module.js";
2
- import r from "classnames";
3
- import { useState as x, useCallback as u, useMemo as _ } from "../../../external/preact/hooks/dist/hooks.module.js";
1
+ import { jsx as e } from "../../../external/preact/jsx-runtime/dist/jsxRuntime.module.js";
2
+ import y from "classnames";
3
+ import { useState as B, useCallback as u, useMemo as f } from "../../../external/preact/hooks/dist/hooks.module.js";
4
4
  import C from "../../../core/Context/useCoreContext.js";
5
5
  import { Tooltip as b } from "../Tooltip/Tooltip.js";
6
- import { ButtonVariant as g } from "../Button/types.js";
6
+ import { ButtonVariant as I } from "../Button/types.js";
7
7
  /* empty css */
8
- import B from "../Button/Button.js";
9
- import { Icon as S } from "../Icon/Icon.js";
10
- const n = "adyen-pe-copy-text", a = {
11
- base: n,
12
- container: n + "__container",
13
- containerInformation: n + "__container--information",
14
- icon: n + "__icon",
15
- iconInformation: n + "__icon--information",
16
- information: n + "__information",
17
- label: n + "__label",
18
- text: n + "__text"
8
+ import S from "../Button/Button.js";
9
+ import { Icon as T } from "../Icon/Icon.js";
10
+ const a = "adyen-pe-copy-text", t = {
11
+ base: a,
12
+ container: a + "__container",
13
+ icon: a + "__icon",
14
+ information: a + "__information",
15
+ label: a + "__label",
16
+ text: a + "__text"
19
17
  }, D = ({
20
18
  copyButtonAriaLabelKey: s,
21
- isHovered: h,
22
- textToCopy: i,
23
- visibleText: l,
19
+ isUnderlineVisible: _,
20
+ textToCopy: o,
21
+ visibleText: r,
24
22
  onCopyText: c,
25
- showCopyTextTooltip: v = !0,
26
- type: e = "Link",
27
- ...I
23
+ showCopyTextTooltip: h = !0,
24
+ type: n = "Trimmed",
25
+ ...v
28
26
  }) => {
29
- const { i18n: t } = C(), [m, d] = x(!1), f = u(() => d(!1), []), k = _(() => t.get(s ?? "common.actions.copy.labels.default"), [t, s]), L = u(async () => {
30
- if (i)
27
+ const { i18n: i } = C(), [l, m] = B(!1), d = u(() => m(!1), []), N = f(() => i.get(s ?? "common.actions.copy.labels.default"), [i, s]), x = u(async () => {
28
+ if (o)
31
29
  try {
32
- await navigator.clipboard.writeText(i), d(!0), c && c();
33
- } catch (N) {
34
- console.error(N);
30
+ await navigator.clipboard.writeText(o), m(!0), c && c();
31
+ } catch (g) {
32
+ console.error(g);
35
33
  }
36
- }, [i, c]), p = _(
37
- () => /* @__PURE__ */ o(
34
+ }, [o, c]), p = f(
35
+ () => /* @__PURE__ */ e(
38
36
  "span",
39
37
  {
40
- className: r({
41
- [a.label]: e !== "Default",
42
- [a.information]: e === "Link",
43
- [a.text]: e === "Text"
38
+ className: y({
39
+ [t.label]: n !== "Default",
40
+ [t.information]: n === "Trimmed",
41
+ [t.text]: n === "Text"
44
42
  }),
45
- children: l || i
43
+ children: r || o
46
44
  }
47
45
  ),
48
- [l, i, e]
49
- );
50
- return /* @__PURE__ */ o(
51
- "span",
52
- {
53
- className: r(a.container, {
54
- [a.containerInformation]: e === "Link"
55
- }),
56
- ...I,
57
- children: [
58
- v ? /* @__PURE__ */ o(b, { content: i, isContainerHovered: h, children: p }) : p,
59
- /* @__PURE__ */ o(b, { content: t.get(m ? "common.actions.copy.labels.done" : "common.actions.copy.labels.default"), children: /* @__PURE__ */ o(
60
- B,
61
- {
62
- variant: g.TERTIARY,
63
- className: a.base,
64
- onClick: L,
65
- onBlur: f,
66
- onMouseLeaveCapture: f,
67
- "aria-label": k,
68
- "data-testid": "copyText",
69
- children: /* @__PURE__ */ o(
70
- "div",
71
- {
72
- className: r(a.icon, {
73
- [a.iconInformation]: e === "Link"
74
- }),
75
- children: /* @__PURE__ */ o(S, { name: "copy", "data-testid": "copy-icon" })
76
- }
77
- )
78
- }
79
- ) }),
80
- /* @__PURE__ */ o("div", { className: "adyen-pe-visually-hidden", "aria-atomic": "true", "aria-live": "polite", children: m && t.get("common.actions.copy.labels.done") })
81
- ]
82
- }
46
+ [r, o, n]
83
47
  );
48
+ return /* @__PURE__ */ e("span", { className: t.container, ...v, children: [
49
+ h ? /* @__PURE__ */ e(b, { content: o, isUnderlineVisible: _, children: p }) : p,
50
+ /* @__PURE__ */ e(b, { content: i.get(l ? "common.actions.copy.labels.done" : "common.actions.copy.labels.default"), children: /* @__PURE__ */ e(
51
+ S,
52
+ {
53
+ variant: I.TERTIARY,
54
+ className: t.base,
55
+ onClick: x,
56
+ onBlur: d,
57
+ onMouseLeaveCapture: d,
58
+ "aria-label": N,
59
+ "data-testid": "copyText",
60
+ children: /* @__PURE__ */ e("div", { className: t.icon, children: /* @__PURE__ */ e(T, { name: "copy", "data-testid": "copy-icon" }) })
61
+ }
62
+ ) }),
63
+ /* @__PURE__ */ e("div", { className: "adyen-pe-visually-hidden", "aria-atomic": "true", "aria-live": "polite", children: l && i.get("common.actions.copy.labels.done") })
64
+ ] });
84
65
  };
85
66
  export {
86
67
  D as default
@@ -1,14 +1,15 @@
1
- import { useState as a, useRef as C, useMemo as i, useCallback as R } from "../../../../../external/preact/hooks/dist/hooks.module.js";
1
+ import { useState as a, useRef as R, useMemo as i, useCallback as W } from "../../../../../external/preact/hooks/dist/hooks.module.js";
2
2
  import N from "../../../../../core/Context/useCoreContext.js";
3
3
  import q from "../../../Calendar/calendar/timerange/presets/yearToDate.js";
4
4
  import A from "../../../Calendar/calendar/timerange/presets/lastMonth.js";
5
5
  import E from "../../../Calendar/calendar/timerange/presets/thisMonth.js";
6
6
  import K from "../../../Calendar/calendar/timerange/presets/lastWeek.js";
7
7
  import Z from "../../../Calendar/calendar/timerange/presets/thisWeek.js";
8
- import W from "../../../Calendar/calendar/timerange/presets/lastNDays.js";
8
+ import y from "../../../Calendar/calendar/timerange/presets/lastNDays.js";
9
9
  const Y = () => Object.freeze({
10
- "common.filters.types.date.rangeSelect.options.last7Days": W(7),
11
- "common.filters.types.date.rangeSelect.options.last30Days": W(30),
10
+ "common.filters.types.date.rangeSelect.options.last7Days": y(7),
11
+ "common.filters.types.date.rangeSelect.options.last30Days": y(30),
12
+ "common.filters.types.date.rangeSelect.options.last90Days": y(90),
12
13
  "common.filters.types.date.rangeSelect.options.thisWeek": Z(),
13
14
  "common.filters.types.date.rangeSelect.options.lastWeek": K(),
14
15
  "common.filters.types.date.rangeSelect.options.thisMonth": E(),
@@ -20,33 +21,33 @@ const Y = () => Object.freeze({
20
21
  selectedOption: m,
21
22
  timezone: l
22
23
  }) => {
23
- const { i18n: p } = N(), [j, S] = a(), [M, y] = a(), [f, u] = a(), O = C(), h = C(), [e, D, s] = i(() => {
24
+ const { i18n: p } = N(), [j, S] = a(), [M, O] = a(), [f, u] = a(), h = R(), D = R(), [e, T, s] = i(() => {
24
25
  const o = p.get("common.filters.types.date.rangeSelect.options.custom"), t = Object.keys(n), c = Object.freeze(t.map((d) => p.get(d)));
25
26
  return [o, (d, v = c) => {
26
27
  const z = v.findIndex((I) => I === d);
27
28
  return n[t[z]];
28
29
  }, c];
29
- }, [p, n]), [T, b] = a(m === e), k = i(() => Object.freeze([...s, e]), [e, s]), x = i(
30
- () => T ? k : s,
31
- [T, s, k]
32
- ), g = R(
30
+ }, [p, n]), [b, k] = a(m === e), C = i(() => Object.freeze([...s, e]), [e, s]), x = i(
31
+ () => b ? C : s,
32
+ [b, s, C]
33
+ ), g = W(
33
34
  (o) => {
34
- const t = D(o, s);
35
- t && (S(t.from), y(t.to), b(!1), u(o));
35
+ const t = T(o, s);
36
+ t && (S(t.from), O(t.to), k(!1), u(o));
36
37
  },
37
- [e, D, f, s]
38
- ), F = R(() => {
39
- S(void 0), y(void 0), b(!0), u(e);
38
+ [e, T, f, s]
39
+ ), F = W(() => {
40
+ S(void 0), O(void 0), k(!0), u(e);
40
41
  }, [e]);
41
42
  return i(() => {
42
43
  m === e ? u(e) : g(m);
43
44
  }, []), i(() => {
44
45
  var o;
45
- if (O.current !== r || h.current !== l) {
46
+ if (h.current !== r || D.current !== l) {
46
47
  const t = Object.values(n);
47
48
  t.forEach((c) => {
48
49
  c.now = r, c.timezone = l;
49
- }), O.current = r, h.current = (o = t[0]) == null ? void 0 : o.timezone, g(f);
50
+ }), h.current = r, D.current = (o = t[0]) == null ? void 0 : o.timezone, g(f);
50
51
  }
51
52
  }, [r, l, n]), {
52
53
  customSelection: F,