@ogcio/design-system-react 1.31.1 → 1.32.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 (82) hide show
  1. package/dist/Heading.d.ts +5 -0
  2. package/dist/Heading.js +22 -0
  3. package/dist/alert/alert.d.ts +3 -0
  4. package/dist/alert/alert.js +46 -61
  5. package/dist/atoms/{DsButton.d.ts → Button.d.ts} +3 -3
  6. package/dist/atoms/{DsButton.js → Button.js} +20 -35
  7. package/dist/atoms/heading/H1.d.ts +3 -0
  8. package/dist/atoms/heading/H1.js +20 -0
  9. package/dist/atoms/heading/H2.d.ts +3 -0
  10. package/dist/atoms/heading/H2.js +20 -0
  11. package/dist/atoms/heading/H3.d.ts +3 -0
  12. package/dist/atoms/heading/H3.js +20 -0
  13. package/dist/atoms/heading/H4.d.ts +3 -0
  14. package/dist/atoms/heading/H4.js +20 -0
  15. package/dist/atoms/heading/H5.d.ts +3 -0
  16. package/dist/atoms/heading/H5.js +20 -0
  17. package/dist/atoms/heading/H6.d.ts +3 -0
  18. package/dist/atoms/heading/H6.js +20 -0
  19. package/dist/atoms/heading/index.d.ts +9 -0
  20. package/dist/atoms/heading/index.js +18 -0
  21. package/dist/atoms/heading/styles.d.ts +65 -0
  22. package/dist/atoms/heading/styles.js +17 -0
  23. package/dist/atoms/heading/types.d.ts +15 -0
  24. package/dist/atoms/heading/types.js +11 -0
  25. package/dist/atoms/heading/utils.d.ts +2 -0
  26. package/dist/atoms/heading/utils.js +5 -0
  27. package/dist/atoms/icons/ArrowLeft.d.ts +3 -0
  28. package/dist/atoms/icons/ArrowLeft.js +23 -0
  29. package/dist/atoms/icons/ArrowRight.d.ts +3 -0
  30. package/dist/atoms/icons/ArrowRight.js +23 -0
  31. package/dist/atoms/icons/CheckCircle.d.ts +3 -0
  32. package/dist/atoms/icons/CheckCircle.js +23 -0
  33. package/dist/atoms/icons/Error.d.ts +3 -0
  34. package/dist/atoms/icons/Error.js +23 -0
  35. package/dist/atoms/icons/FirstPage.d.ts +3 -0
  36. package/dist/atoms/icons/FirstPage.js +23 -0
  37. package/dist/atoms/icons/Info.d.ts +3 -0
  38. package/dist/atoms/icons/Info.js +23 -0
  39. package/dist/atoms/icons/KeyboardArrowLeft.d.ts +3 -0
  40. package/dist/atoms/icons/KeyboardArrowLeft.js +23 -0
  41. package/dist/atoms/icons/KeyboardArrowRight.d.ts +3 -0
  42. package/dist/atoms/icons/KeyboardArrowRight.js +23 -0
  43. package/dist/atoms/icons/LastPage.d.ts +3 -0
  44. package/dist/atoms/icons/LastPage.js +23 -0
  45. package/dist/atoms/icons/Warning.d.ts +3 -0
  46. package/dist/atoms/icons/Warning.js +23 -0
  47. package/dist/atoms/icons/index.d.ts +12 -2
  48. package/dist/atoms/icons/index.js +30 -10
  49. package/dist/atoms/index.d.ts +2 -1
  50. package/dist/atoms/index.js +48 -12
  51. package/dist/atoms/storybook/Heading.meta.d.ts +60 -0
  52. package/dist/atoms/storybook/Heading.meta.js +70 -0
  53. package/dist/atoms/storybook/Icons.meta.d.ts +51 -0
  54. package/dist/atoms/storybook/Icons.meta.js +130 -0
  55. package/dist/atoms/storybook/InsetText.meta.d.ts +52 -0
  56. package/dist/atoms/storybook/InsetText.meta.js +64 -0
  57. package/dist/atoms/storybook/Logos.meta.d.ts +35 -0
  58. package/dist/atoms/storybook/Logos.meta.js +54 -0
  59. package/dist/breadcrumbs/breadcrumbs.js +20 -19
  60. package/dist/header/components/header-menu.js +21 -21
  61. package/dist/header/components/header-search.js +4 -4
  62. package/dist/icon/icon.js +85 -63
  63. package/dist/icon/icons.d.ts +1 -1
  64. package/dist/icons/index.d.ts +1 -1
  65. package/dist/icons/index.js +19 -10
  66. package/dist/index-Bh2cTIps.js +33899 -0
  67. package/dist/index.d.ts +1 -1
  68. package/dist/index.js +1 -1
  69. package/dist/input-text/input-text.js +1 -1
  70. package/dist/input-text/type.d.ts +1 -1
  71. package/dist/modal/modal.d.ts +1 -1
  72. package/dist/modal/modal.js +1 -1
  73. package/dist/pagination/pagination.js +139 -135
  74. package/dist/paragraph/paragraph.d.ts +1 -1
  75. package/dist/paragraph/paragraph.js +13 -11
  76. package/dist/side-nav/side-nav.js +4 -4
  77. package/dist/side-nav/types.d.ts +1 -1
  78. package/dist/styles.css +1 -1
  79. package/dist/table/table-pagination.js +17 -13
  80. package/package.json +7 -6
  81. package/dist/heading/heading.d.ts +0 -150
  82. package/dist/heading/heading.js +0 -50
package/dist/index.d.ts CHANGED
@@ -40,7 +40,7 @@ export { HeaderSearch, type HeaderSearchProps, } from './header/components/heade
40
40
  export { Header } from './header/header.js';
41
41
  export * from './header/header-next/index.js';
42
42
  export type { HeaderItem, HeaderProps } from './header/types.js';
43
- export { Heading, type HeadingProps } from './heading/heading.js';
43
+ export { default as Heading, type Props as HeadingProps } from './Heading.js';
44
44
  export type { HintTextProps } from './hint-text/types.js';
45
45
  export * from './i18n/config.js';
46
46
  export { IconButton, type IconButtonProps } from './icon-button/icon-button.js';
package/dist/index.js CHANGED
@@ -37,7 +37,7 @@ import { HeaderMenuItemButton as We } from "./header/header-next/components/menu
37
37
  import { HeaderMenuItemLink as Ue } from "./header/header-next/components/menu/components/header-menu-item-link.js";
38
38
  import { HeaderMenuItemSeparator as qe } from "./header/header-next/components/menu/components/header-menu-item-separator.js";
39
39
  import { HeaderMenuItemSlot as Je } from "./header/header-next/components/menu/components/header-menu-item-slot.js";
40
- import { Heading as Oe } from "./heading/heading.js";
40
+ import { default as Oe } from "./Heading.js";
41
41
  import { initI18n as Xe } from "./i18n/config.js";
42
42
  import { IconButton as Ze } from "./icon-button/icon-button.js";
43
43
  import { Icon as $e } from "./icon/icon.js";
@@ -142,7 +142,7 @@ const H = d(
142
142
  icon: r
143
143
  },
144
144
  "data-testid": t,
145
- "aria-label": e || "",
145
+ "aria-label": e || void 0,
146
146
  onClick: a,
147
147
  variant: "flat",
148
148
  size: "small",
@@ -4,7 +4,7 @@ export type InputActionButtonProps = {
4
4
  icon: IconId;
5
5
  onClick: (event: React.MouseEvent<HTMLButtonElement>) => void;
6
6
  disabled?: boolean;
7
- ariaLabel?: string;
7
+ ariaLabel: string;
8
8
  dataTestId?: string;
9
9
  ref?: React.Ref<HTMLButtonElement>;
10
10
  };
@@ -1,5 +1,5 @@
1
1
  import { ReactNode } from 'react';
2
- import { HeadingProps } from '../heading/heading.js';
2
+ import { Props as HeadingProps } from '../Heading.js';
3
3
  import { ModalFooterProps, ModalProps, ModalWrapperProps } from './types.js';
4
4
  export declare const ModalWrapper: ({ position, size, closeOnClick, closeOnOverlayClick, isOpen, onClose, closeButtonLabel, className, children, closeButtonSize, closeOnEscape, dataTestId, ...props }: ModalWrapperProps) => import("react/jsx-runtime").JSX.Element;
5
5
  export declare const ModalTitle: {
@@ -2,9 +2,9 @@
2
2
  import { jsx as l, jsxs as y, Fragment as j } from "react/jsx-runtime";
3
3
  import { isValidElement as K, cloneElement as T, useState as A, useRef as U, useMemo as W, Children as _, useId as z, useEffect as C } from "react";
4
4
  import { createPortal as G } from "react-dom";
5
+ import J from "../Heading.js";
5
6
  import { Button as E } from "../button/button.js";
6
7
  import { cn as u } from "../cn.js";
7
- import { Heading as J } from "../heading/heading.js";
8
8
  import { useAriaHider as Q } from "../hooks/use-aria-hider.js";
9
9
  import { useFocusTrap as X } from "../hooks/use-focus-trap.js";
10
10
  import { Icon as Y } from "../icon/icon.js";
@@ -1,17 +1,21 @@
1
1
  "use client";
2
- import { jsxs as R, jsx as j } from "react/jsx-runtime";
3
- import J, { createElement as z, isValidElement as D, cloneElement as K, Children as de, Fragment as he, useContext as ge, useState as ye, useEffect as ve } from "react";
2
+ import { jsxs as B, jsx as j } from "react/jsx-runtime";
3
+ import J, { createElement as R, isValidElement as D, cloneElement as Q, Children as me, Fragment as de, useContext as he, useState as ge, useEffect as ye } from "react";
4
+ import "../atoms/Button.js";
5
+ import "../atoms/heading/styles.js";
6
+ import be from "../atoms/icons/ArrowLeft.js";
7
+ import ve from "../atoms/icons/ArrowRight.js";
4
8
  import { Button as U } from "../button/button.js";
5
- import { useBreakpoint as be, Breakpoint as re } from "../hooks/use-breakpoint.js";
6
- import { Icon as X } from "../icon/icon.js";
7
- import { getDisplayPages as se } from "../utils/utilities.js";
8
- import { w as oe, i as L, a as Y, b as _, I as Ne, u as xe } from "../useTranslation-DiBQuy8S.js";
9
- import { k as Ae } from "../i18next-Bfi2-LyH.js";
10
- import { g as Ee } from "../_commonjsHelpers-DaMA6jEr.js";
11
- import { g as le, b as ce, u as $e } from "../i18nInstance-AYICsHJu.js";
12
- var Q, ae;
13
- function Te() {
14
- return ae || (ae = 1, Q = {
9
+ import { useBreakpoint as Ne, Breakpoint as ne } from "../hooks/use-breakpoint.js";
10
+ import { Icon as xe } from "../icon/icon.js";
11
+ import { getDisplayPages as re } from "../utils/utilities.js";
12
+ import { w as ie, i as _, a as X, b as S, I as Ae, u as Ee } from "../useTranslation-DiBQuy8S.js";
13
+ import { k as $e } from "../i18next-Bfi2-LyH.js";
14
+ import { g as Te } from "../_commonjsHelpers-DaMA6jEr.js";
15
+ import { g as oe, b as le, u as ke } from "../i18nInstance-AYICsHJu.js";
16
+ var Y, se;
17
+ function Ce() {
18
+ return se || (se = 1, Y = {
15
19
  area: !0,
16
20
  base: !0,
17
21
  br: !0,
@@ -26,25 +30,25 @@ function Te() {
26
30
  source: !0,
27
31
  track: !0,
28
32
  wbr: !0
29
- }), Q;
33
+ }), Y;
30
34
  }
31
- var Ce = Te();
32
- const ke = /* @__PURE__ */ Ee(Ce);
33
- var Oe = /\s([^'"/\s><]+?)[\s/>]|([^\s=]+)=\s?(".*?"|'.*?')/g;
34
- function ie(e) {
35
+ var Oe = Ce();
36
+ const Ve = /* @__PURE__ */ Te(Oe);
37
+ var je = /\s([^'"/\s><]+?)[\s/>]|([^\s=]+)=\s?(".*?"|'.*?')/g;
38
+ function ae(e) {
35
39
  var t = { type: "tag", name: "", voidElement: !1, attrs: {}, children: [] }, n = e.match(/<\/?([^\s]+?)[/\s>]/);
36
- if (n && (t.name = n[1], (ke[n[1]] || e.charAt(e.length - 2) === "/") && (t.voidElement = !0), t.name.startsWith("!--"))) {
40
+ if (n && (t.name = n[1], (Ve[n[1]] || e.charAt(e.length - 2) === "/") && (t.voidElement = !0), t.name.startsWith("!--"))) {
37
41
  var r = e.indexOf("-->");
38
42
  return { type: "comment", comment: r !== -1 ? e.slice(4, r) : "" };
39
43
  }
40
- for (var a = new RegExp(Oe), s = null; (s = a.exec(e)) !== null; ) if (s[0].trim()) if (s[1]) {
44
+ for (var a = new RegExp(je), s = null; (s = a.exec(e)) !== null; ) if (s[0].trim()) if (s[1]) {
41
45
  var o = s[1].trim(), c = [o, ""];
42
46
  o.indexOf("=") > -1 && (c = o.split("=")), t.attrs[c[0]] = c[1], a.lastIndex--;
43
47
  } else s[2] && (t.attrs[s[2]] = s[3].trim().substring(1, s[3].length - 1));
44
48
  return t;
45
49
  }
46
- var Ve = /<[a-zA-Z0-9\-\!\/](?:"[^"]*"|'[^']*'|[^'">])*>/g, je = /^\s*$/, Ie = /* @__PURE__ */ Object.create(null);
47
- function ue(e, t) {
50
+ var Ie = /<[a-zA-Z0-9\-\!\/](?:"[^"]*"|'[^']*'|[^'">])*>/g, Se = /^\s*$/, Le = /* @__PURE__ */ Object.create(null);
51
+ function ce(e, t) {
48
52
  switch (t.type) {
49
53
  case "text":
50
54
  return e + t.content;
@@ -53,37 +57,37 @@ function ue(e, t) {
53
57
  var r = [];
54
58
  for (var a in n) r.push(a + '="' + n[a] + '"');
55
59
  return r.length ? " " + r.join(" ") : "";
56
- })(t.attrs) : "") + (t.voidElement ? "/>" : ">"), t.voidElement ? e : e + t.children.reduce(ue, "") + "</" + t.name + ">";
60
+ })(t.attrs) : "") + (t.voidElement ? "/>" : ">"), t.voidElement ? e : e + t.children.reduce(ce, "") + "</" + t.name + ">";
57
61
  case "comment":
58
62
  return e + "<!--" + t.comment + "-->";
59
63
  }
60
64
  }
61
65
  var _e = { parse: function(e, t) {
62
- t || (t = {}), t.components || (t.components = Ie);
66
+ t || (t = {}), t.components || (t.components = Le);
63
67
  var n, r = [], a = [], s = -1, o = !1;
64
68
  if (e.indexOf("<") !== 0) {
65
69
  var c = e.indexOf("<");
66
70
  r.push({ type: "text", content: c === -1 ? e : e.substring(0, c) });
67
71
  }
68
- return e.replace(Ve, function(f, m) {
72
+ return e.replace(Ie, function(f, m) {
69
73
  if (o) {
70
74
  if (f !== "</" + n.name + ">") return;
71
75
  o = !1;
72
76
  }
73
77
  var p, N = f.charAt(1) !== "/", $ = f.startsWith("<!--"), g = m + f.length, l = e.charAt(g);
74
78
  if ($) {
75
- var T = ie(f);
79
+ var T = ae(f);
76
80
  return s < 0 ? (r.push(T), r) : ((p = a[s]).children.push(T), r);
77
81
  }
78
- if (N && (s++, (n = ie(f)).type === "tag" && t.components[n.name] && (n.type = "component", o = !0), n.voidElement || o || !l || l === "<" || n.children.push({ type: "text", content: e.slice(g, e.indexOf("<", g)) }), s === 0 && r.push(n), (p = a[s - 1]) && p.children.push(n), a[s] = n), (!N || n.voidElement) && (s > -1 && (n.voidElement || n.name === f.slice(2, -1)) && (s--, n = s === -1 ? r : a[s]), !o && l !== "<" && l)) {
82
+ if (N && (s++, (n = ae(f)).type === "tag" && t.components[n.name] && (n.type = "component", o = !0), n.voidElement || o || !l || l === "<" || n.children.push({ type: "text", content: e.slice(g, e.indexOf("<", g)) }), s === 0 && r.push(n), (p = a[s - 1]) && p.children.push(n), a[s] = n), (!N || n.voidElement) && (s > -1 && (n.voidElement || n.name === f.slice(2, -1)) && (s--, n = s === -1 ? r : a[s]), !o && l !== "<" && l)) {
79
83
  p = s === -1 ? r : a[s].children;
80
84
  var h = e.indexOf("<", g), x = e.slice(g, h === -1 ? void 0 : h);
81
- je.test(x) && (x = " "), (h > -1 && s + p.length >= 0 || x !== " ") && p.push({ type: "text", content: x });
85
+ Se.test(x) && (x = " "), (h > -1 && s + p.length >= 0 || x !== " ") && p.push({ type: "text", content: x });
82
86
  }
83
87
  }), r;
84
88
  }, stringify: function(e) {
85
89
  return e.reduce(function(t, n) {
86
- return t + ue("", n);
90
+ return t + ce("", n);
87
91
  }, "");
88
92
  } };
89
93
  const G = (e, t) => {
@@ -95,27 +99,27 @@ const G = (e, t) => {
95
99
  var n, r;
96
100
  if (!e) return [];
97
101
  const t = ((n = e.props) == null ? void 0 : n.children) ?? e.children;
98
- return (r = e.props) != null && r.i18nIsDynamicList ? S(t) : t;
99
- }, Se = (e) => Array.isArray(e) && e.every(D), S = (e) => Array.isArray(e) ? e : [e], Le = (e, t) => {
102
+ return (r = e.props) != null && r.i18nIsDynamicList ? L(t) : t;
103
+ }, Fe = (e) => Array.isArray(e) && e.every(D), L = (e) => Array.isArray(e) ? e : [e], we = (e, t) => {
100
104
  const n = {
101
105
  ...t
102
106
  };
103
107
  return n.props = Object.assign(e.props, t.props), n;
104
- }, Fe = (e) => {
108
+ }, Re = (e) => {
105
109
  const t = {};
106
110
  if (!e) return t;
107
111
  const n = (r) => {
108
- S(r).forEach((s) => {
109
- L(s) || (G(s) ? n(q(s)) : _(s) && !D(s) && Object.assign(t, s));
112
+ L(r).forEach((s) => {
113
+ _(s) || (G(s) ? n(q(s)) : S(s) && !D(s) && Object.assign(t, s));
110
114
  });
111
115
  };
112
116
  return n(e), t;
113
- }, pe = (e, t, n, r) => {
117
+ }, ue = (e, t, n, r) => {
114
118
  if (!e) return "";
115
119
  let a = "";
116
- const s = S(e), o = t != null && t.transSupportBasicHtmlNodes ? t.transKeepBasicHtmlNodesFor ?? [] : [];
120
+ const s = L(e), o = t != null && t.transSupportBasicHtmlNodes ? t.transKeepBasicHtmlNodesFor ?? [] : [];
117
121
  return s.forEach((c, f) => {
118
- if (L(c)) {
122
+ if (_(c)) {
119
123
  a += `${c}`;
120
124
  return;
121
125
  }
@@ -132,21 +136,21 @@ const G = (e, t) => {
132
136
  a += `<${f}></${f}>`;
133
137
  return;
134
138
  }
135
- if ($ && N === 1 && L(g)) {
139
+ if ($ && N === 1 && _(g)) {
136
140
  a += `<${p}>${g}</${p}>`;
137
141
  return;
138
142
  }
139
- const l = pe(g, t, n, r);
143
+ const l = ue(g, t, n, r);
140
144
  a += `<${f}>${l}</${f}>`;
141
145
  return;
142
146
  }
143
147
  if (c === null) {
144
- Y(n, "TRANS_NULL_VALUE", "Passed in a null value as child", {
148
+ X(n, "TRANS_NULL_VALUE", "Passed in a null value as child", {
145
149
  i18nKey: r
146
150
  });
147
151
  return;
148
152
  }
149
- if (_(c)) {
153
+ if (S(c)) {
150
154
  const {
151
155
  format: m,
152
156
  ...p
@@ -156,18 +160,18 @@ const G = (e, t) => {
156
160
  a += `{{${$}}}`;
157
161
  return;
158
162
  }
159
- Y(n, "TRANS_INVALID_OBJ", "Invalid child - Object should only have keys {{ value, format }} (format is optional).", {
163
+ X(n, "TRANS_INVALID_OBJ", "Invalid child - Object should only have keys {{ value, format }} (format is optional).", {
160
164
  i18nKey: r,
161
165
  child: c
162
166
  });
163
167
  return;
164
168
  }
165
- Y(n, "TRANS_INVALID_VAR", "Passed in a variable like {number} - pass variables for interpolation as full objects like {{number}}.", {
169
+ X(n, "TRANS_INVALID_VAR", "Passed in a variable like {number} - pass variables for interpolation as full objects like {{number}}.", {
166
170
  i18nKey: r,
167
171
  child: c
168
172
  });
169
173
  }), a;
170
- }, we = (e, t = [], n = {}) => {
174
+ }, ze = (e, t = [], n = {}) => {
171
175
  if (!e) return e;
172
176
  const r = Object.keys(n), a = [...t, ...r];
173
177
  let s = "", o = 0;
@@ -190,124 +194,124 @@ const G = (e, t) => {
190
194
  } else
191
195
  s += e[o], o += 1;
192
196
  return s;
193
- }, ze = (e, t, n, r, a, s, o) => {
197
+ }, Be = (e, t, n, r, a, s, o) => {
194
198
  if (n === "") return [];
195
199
  const c = a.transKeepBasicHtmlNodesFor || [], f = n && new RegExp(c.map((u) => `<${u}`).join("|")).test(n);
196
200
  if (!e && !t && !f && !o) return [n];
197
201
  const m = t ?? {}, p = (u) => {
198
- S(u).forEach((y) => {
199
- L(y) || (G(y) ? p(q(y)) : _(y) && !D(y) && Object.assign(m, y));
202
+ L(u).forEach((y) => {
203
+ _(y) || (G(y) ? p(q(y)) : S(y) && !D(y) && Object.assign(m, y));
200
204
  });
201
205
  };
202
206
  p(e);
203
- const N = we(n, c, m), $ = _e.parse(`<0>${N}</0>`), g = {
207
+ const N = ze(n, c, m), $ = _e.parse(`<0>${N}</0>`), g = {
204
208
  ...m,
205
209
  ...s
206
210
  }, l = (u, A, y) => {
207
211
  var d;
208
212
  const E = q(u), I = h(E, A.children, y);
209
- return Se(E) && I.length === 0 || (d = u.props) != null && d.i18nIsDynamicList ? E : I;
213
+ return Fe(E) && I.length === 0 || (d = u.props) != null && d.i18nIsDynamicList ? E : I;
210
214
  }, T = (u, A, y, E, I) => {
211
- u.dummy ? (u.children = A, y.push(K(u, {
215
+ u.dummy ? (u.children = A, y.push(Q(u, {
212
216
  key: E
213
- }, I ? void 0 : A))) : y.push(...de.map([u], (d) => {
217
+ }, I ? void 0 : A))) : y.push(...me.map([u], (d) => {
214
218
  const i = "data-i18n-is-dynamic-list", O = {
215
219
  key: E,
216
220
  [i]: void 0
217
221
  };
218
- return d && d.props && Object.keys(d.props).forEach((C) => {
219
- C === "ref" || C === "children" || C === "i18nIsDynamicList" || C === i || (O[C] = d.props[C]);
220
- }), K(d, O, I ? null : A);
222
+ return d && d.props && Object.keys(d.props).forEach((k) => {
223
+ k === "ref" || k === "children" || k === "i18nIsDynamicList" || k === i || (O[k] = d.props[k]);
224
+ }), Q(d, O, I ? null : A);
221
225
  }));
222
226
  }, h = (u, A, y) => {
223
- const E = S(u);
224
- return S(A).reduce((d, i, O) => {
227
+ const E = L(u);
228
+ return L(A).reduce((d, i, O) => {
225
229
  var F, H;
226
- const C = ((H = (F = i.children) == null ? void 0 : F[0]) == null ? void 0 : H.content) && r.services.interpolator.interpolate(i.children[0].content, g, r.language);
230
+ const k = ((H = (F = i.children) == null ? void 0 : F[0]) == null ? void 0 : H.content) && r.services.interpolator.interpolate(i.children[0].content, g, r.language);
227
231
  if (i.type === "tag") {
228
- let k = E[parseInt(i.name, 10)];
229
- !k && t && (k = t[i.name]), y.length === 1 && !k && (k = y[0][i.name]), k || (k = {});
232
+ let C = E[parseInt(i.name, 10)];
233
+ !C && t && (C = t[i.name]), y.length === 1 && !C && (C = y[0][i.name]), C || (C = {});
230
234
  const V = {
231
235
  ...i.attrs
232
236
  };
233
- o && Object.keys(V).forEach((b) => {
234
- const B = V[b];
235
- L(B) && (V[b] = $e(B));
237
+ o && Object.keys(V).forEach((v) => {
238
+ const z = V[v];
239
+ _(z) && (V[v] = ke(z));
236
240
  });
237
- const v = Object.keys(V).length !== 0 ? Le({
241
+ const b = Object.keys(V).length !== 0 ? we({
238
242
  props: V
239
- }, k) : k, w = D(v), M = w && G(i, !0) && !i.voidElement, W = f && _(v) && v.dummy && !w, Z = _(t) && Object.hasOwnProperty.call(t, i.name);
240
- if (L(v)) {
241
- const b = r.services.interpolator.interpolate(v, g, r.language);
242
- d.push(b);
243
- } else if (G(v) || M) {
244
- const b = l(v, i, y);
245
- T(v, b, d, O);
243
+ }, C) : C, w = D(b), M = w && G(i, !0) && !i.voidElement, W = f && S(b) && b.dummy && !w, Z = S(t) && Object.hasOwnProperty.call(t, i.name);
244
+ if (_(b)) {
245
+ const v = r.services.interpolator.interpolate(b, g, r.language);
246
+ d.push(v);
247
+ } else if (G(b) || M) {
248
+ const v = l(b, i, y);
249
+ T(b, v, d, O);
246
250
  } else if (W) {
247
- const b = h(E, i.children, y);
248
- T(v, b, d, O);
251
+ const v = h(E, i.children, y);
252
+ T(b, v, d, O);
249
253
  } else if (Number.isNaN(parseFloat(i.name)))
250
254
  if (Z) {
251
- const b = l(v, i, y);
252
- T(v, b, d, O, i.voidElement);
255
+ const v = l(b, i, y);
256
+ T(b, v, d, O, i.voidElement);
253
257
  } else if (a.transSupportBasicHtmlNodes && c.indexOf(i.name) > -1)
254
258
  if (i.voidElement)
255
- d.push(z(i.name, {
259
+ d.push(R(i.name, {
256
260
  key: `${i.name}-${O}`
257
261
  }));
258
262
  else {
259
- const b = h(E, i.children, y);
260
- d.push(z(i.name, {
263
+ const v = h(E, i.children, y);
264
+ d.push(R(i.name, {
261
265
  key: `${i.name}-${O}`
262
- }, b));
266
+ }, v));
263
267
  }
264
268
  else if (i.voidElement)
265
269
  d.push(`<${i.name} />`);
266
270
  else {
267
- const b = h(E, i.children, y);
268
- d.push(`<${i.name}>${b}</${i.name}>`);
271
+ const v = h(E, i.children, y);
272
+ d.push(`<${i.name}>${v}</${i.name}>`);
269
273
  }
270
- else if (_(v) && !w) {
271
- const b = i.children[0] ? C : null;
272
- b && d.push(b);
274
+ else if (S(b) && !w) {
275
+ const v = i.children[0] ? k : null;
276
+ v && d.push(v);
273
277
  } else
274
- T(v, C, d, O, i.children.length !== 1 || !C);
278
+ T(b, k, d, O, i.children.length !== 1 || !k);
275
279
  } else if (i.type === "text") {
276
- const k = a.transWrapTextNodes, V = typeof a.unescape == "function" ? a.unescape : ce().unescape, v = o ? V(r.services.interpolator.interpolate(i.content, g, r.language)) : r.services.interpolator.interpolate(i.content, g, r.language);
277
- k ? d.push(z(k, {
280
+ const C = a.transWrapTextNodes, V = typeof a.unescape == "function" ? a.unescape : le().unescape, b = o ? V(r.services.interpolator.interpolate(i.content, g, r.language)) : r.services.interpolator.interpolate(i.content, g, r.language);
281
+ C ? d.push(R(C, {
278
282
  key: `${i.name}-${O}`
279
- }, v)) : d.push(v);
283
+ }, b)) : d.push(b);
280
284
  }
281
285
  return d;
282
286
  }, []);
283
287
  }, x = h([{
284
288
  dummy: !0,
285
289
  children: e || []
286
- }], $, S(e || []));
290
+ }], $, L(e || []));
287
291
  return q(x[0]);
288
- }, fe = (e, t, n) => {
289
- const r = e.key || t, a = K(e, {
292
+ }, pe = (e, t, n) => {
293
+ const r = e.key || t, a = Q(e, {
290
294
  key: r
291
295
  });
292
296
  if (!a.props || !a.props.children || n.indexOf(`${t}/>`) < 0 && n.indexOf(`${t} />`) < 0)
293
297
  return a;
294
298
  function s() {
295
- return z(he, null, a);
299
+ return R(de, null, a);
296
300
  }
297
- return z(s, {
301
+ return R(s, {
298
302
  key: r
299
303
  });
300
- }, Be = (e, t) => e.map((n, r) => fe(n, r, t)), Re = (e, t) => {
304
+ }, De = (e, t) => e.map((n, r) => pe(n, r, t)), He = (e, t) => {
301
305
  const n = {};
302
306
  return Object.keys(e).forEach((r) => {
303
307
  Object.assign(n, {
304
- [r]: fe(e[r], r, t)
308
+ [r]: pe(e[r], r, t)
305
309
  });
306
310
  }), n;
307
- }, De = (e, t, n, r) => e ? Array.isArray(e) ? Be(e, t) : _(e) ? Re(e, t) : (oe(n, "TRANS_INVALID_COMPONENTS", '<Trans /> "components" prop expects an object or array', {
311
+ }, Me = (e, t, n, r) => e ? Array.isArray(e) ? De(e, t) : S(e) ? He(e, t) : (ie(n, "TRANS_INVALID_COMPONENTS", '<Trans /> "components" prop expects an object or array', {
308
312
  i18nKey: r
309
- }), null) : null, He = (e) => !_(e) || Array.isArray(e) ? !1 : Object.keys(e).reduce((t, n) => t && Number.isNaN(Number.parseFloat(n)), !0);
310
- function Me({
313
+ }), null) : null, We = (e) => !S(e) || Array.isArray(e) ? !1 : Object.keys(e).reduce((t, n) => t && Number.isNaN(Number.parseFloat(n)), !0);
314
+ function Ze({
311
315
  children: e,
312
316
  count: t,
313
317
  parent: n,
@@ -323,18 +327,18 @@ function Me({
323
327
  shouldUnescape: $,
324
328
  ...g
325
329
  }) {
326
- var b, B, P, ee, te, ne;
327
- const l = p || le();
330
+ var v, z, K, P, ee, te;
331
+ const l = p || oe();
328
332
  if (!l)
329
- return oe(l, "NO_I18NEXT_INSTANCE", "Trans: You need to pass in an i18next instance using i18nextReactModule", {
333
+ return ie(l, "NO_I18NEXT_INSTANCE", "Trans: You need to pass in an i18next instance using i18nextReactModule", {
330
334
  i18nKey: r
331
335
  }), e;
332
- const T = N || l.t.bind(l) || ((me) => me), h = {
333
- ...ce(),
334
- ...(b = l.options) == null ? void 0 : b.react
336
+ const T = N || l.t.bind(l) || ((fe) => fe), h = {
337
+ ...le(),
338
+ ...(v = l.options) == null ? void 0 : v.react
335
339
  };
336
- let x = m || T.ns || ((B = l.options) == null ? void 0 : B.defaultNS);
337
- x = L(x) ? [x] : x || ["translation"];
340
+ let x = m || T.ns || ((z = l.options) == null ? void 0 : z.defaultNS);
341
+ x = _(x) ? [x] : x || ["translation"];
338
342
  const {
339
343
  transDefaultProps: u
340
344
  } = h, A = u != null && u.tOptions ? {
@@ -346,24 +350,24 @@ function Me({
346
350
  } : o, I = u != null && u.components ? {
347
351
  ...u.components,
348
352
  ...f
349
- } : f, d = pe(e, h, l, r), i = c || (A == null ? void 0 : A.defaultValue) || d || h.transEmptyNodeValue || (typeof r == "function" ? Ae(r) : r), {
353
+ } : f, d = ue(e, h, l, r), i = c || (A == null ? void 0 : A.defaultValue) || d || h.transEmptyNodeValue || (typeof r == "function" ? $e(r) : r), {
350
354
  hashTransKey: O
351
- } = h, C = r || (O ? O(d || i) : d || i);
352
- (ee = (P = l.options) == null ? void 0 : P.interpolation) != null && ee.defaultVariables ? o = E && Object.keys(E).length > 0 ? {
355
+ } = h, k = r || (O ? O(d || i) : d || i);
356
+ (P = (K = l.options) == null ? void 0 : K.interpolation) != null && P.defaultVariables ? o = E && Object.keys(E).length > 0 ? {
353
357
  ...E,
354
358
  ...l.options.interpolation.defaultVariables
355
359
  } : {
356
360
  ...l.options.interpolation.defaultVariables
357
361
  } : o = E;
358
- const F = Fe(e);
362
+ const F = Re(e);
359
363
  F && typeof F.count == "number" && t === void 0 && (t = F.count);
360
- const H = o || t !== void 0 && !((ne = (te = l.options) == null ? void 0 : te.interpolation) != null && ne.alwaysFormat) || !e ? A.interpolation : {
364
+ const H = o || t !== void 0 && !((te = (ee = l.options) == null ? void 0 : ee.interpolation) != null && te.alwaysFormat) || !e ? A.interpolation : {
361
365
  interpolation: {
362
366
  ...A.interpolation,
363
367
  prefix: "#$?",
364
368
  suffix: "?$#"
365
369
  }
366
- }, k = {
370
+ }, C = {
367
371
  ...A,
368
372
  context: a || A.context,
369
373
  count: t,
@@ -372,15 +376,15 @@ function Me({
372
376
  defaultValue: i,
373
377
  ns: x
374
378
  };
375
- let V = C ? T(C, k) : i;
376
- V === C && i && (V = i);
377
- const v = De(I, V, l, r);
378
- let w = v || e, M = null;
379
- He(v) && (M = v, w = e);
380
- const W = ze(w, M, V, l, h, k, y), Z = n ?? h.defaultTransParent;
381
- return Z ? z(Z, g, W) : W;
379
+ let V = k ? T(k, C) : i;
380
+ V === k && i && (V = i);
381
+ const b = Me(I, V, l, r);
382
+ let w = b || e, M = null;
383
+ We(b) && (M = b, w = e);
384
+ const W = Be(w, M, V, l, h, C, y), Z = n ?? h.defaultTransParent;
385
+ return Z ? R(Z, g, W) : W;
382
386
  }
383
- function We({
387
+ function Ge({
384
388
  children: e,
385
389
  count: t,
386
390
  parent: n,
@@ -400,8 +404,8 @@ function We({
400
404
  const {
401
405
  i18n: l,
402
406
  defaultNS: T
403
- } = ge(Ne) || {}, h = p || l || le(), x = N || (h == null ? void 0 : h.t.bind(h));
404
- return Me({
407
+ } = he(Ae) || {}, h = p || l || oe(), x = N || (h == null ? void 0 : h.t.bind(h));
408
+ return Ze({
405
409
  children: e,
406
410
  count: t,
407
411
  parent: n,
@@ -418,22 +422,22 @@ function We({
418
422
  ...g
419
423
  });
420
424
  }
421
- const et = ({
425
+ const it = ({
422
426
  currentPage: e,
423
427
  totalPages: t,
424
428
  onPageChange: n,
425
429
  dataTestid: r
426
430
  }) => {
427
- const { t: a } = xe();
431
+ const { t: a } = Ee();
428
432
  if (t === 0)
429
433
  return null;
430
- const { breakpoint: s, width: o } = be(), [c, f] = ye(!1);
431
- ve(() => {
434
+ const { breakpoint: s, width: o } = Ne(), [c, f] = ge(!1);
435
+ ye(() => {
432
436
  f(!0);
433
437
  }, []);
434
- const m = c && s === re.ExtraSmall, p = c && o !== null && o < 639, N = () => (c && s ? se(e, t, s) : se(e, t, re.Large)).map(
438
+ const m = c && s === ne.ExtraSmall, p = c && o !== null && o < 639, N = () => (c && s ? re(e, t, s) : re(e, t, ne.Large)).map(
435
439
  (l, T) => l === -1 || l === -2 ? /* @__PURE__ */ j(J.Fragment, { children: /* @__PURE__ */ j(
436
- X,
440
+ xe,
437
441
  {
438
442
  role: "presentation",
439
443
  className: "gi-text-gray-700",
@@ -454,14 +458,14 @@ const et = ({
454
458
  },
455
459
  l
456
460
  )
457
- ), $ = () => /* @__PURE__ */ j("span", { className: "gi-text-md gi-leading-6", "aria-live": "polite", children: /* @__PURE__ */ R(
458
- We,
461
+ ), $ = () => /* @__PURE__ */ j("span", { className: "gi-text-md gi-leading-6", "aria-live": "polite", children: /* @__PURE__ */ B(
462
+ Ge,
459
463
  {
460
464
  i18nKey: "pagination.page",
461
465
  values: { currentPage: e, totalPages: t },
462
466
  components: { bold: /* @__PURE__ */ j("span", { className: "gi-font-bold" }) },
463
467
  children: [
464
- /* @__PURE__ */ R("span", { className: "gi-font-bold", children: [
468
+ /* @__PURE__ */ B("span", { className: "gi-font-bold", children: [
465
469
  "Page ",
466
470
  e
467
471
  ] }),
@@ -470,7 +474,7 @@ const et = ({
470
474
  ]
471
475
  }
472
476
  ) });
473
- return /* @__PURE__ */ R(
477
+ return /* @__PURE__ */ B(
474
478
  "div",
475
479
  {
476
480
  className: "gi-pagination",
@@ -482,7 +486,7 @@ const et = ({
482
486
  }),
483
487
  "data-testid": r,
484
488
  children: [
485
- /* @__PURE__ */ R(
489
+ /* @__PURE__ */ B(
486
490
  U,
487
491
  {
488
492
  variant: "flat",
@@ -496,13 +500,13 @@ const et = ({
496
500
  className: p ? "gi-icon-btn-large" : "",
497
501
  dataTestid: "govie-pagination-prev-btn",
498
502
  children: [
499
- /* @__PURE__ */ j(J.Fragment, { children: /* @__PURE__ */ j(X, { icon: "arrow_left_alt" }) }, "previous-btn-pagination"),
503
+ /* @__PURE__ */ j(J.Fragment, { children: /* @__PURE__ */ j(be, { className: "gi-block gi-shrink-0" }) }, "previous-btn-pagination"),
500
504
  !p && a("pagination.previous", { defaultValue: "Previous" })
501
505
  ]
502
506
  }
503
507
  ),
504
508
  m ? $() : N(),
505
- /* @__PURE__ */ R(
509
+ /* @__PURE__ */ B(
506
510
  U,
507
511
  {
508
512
  disabled: e === t,
@@ -515,7 +519,7 @@ const et = ({
515
519
  dataTestid: "govie-pagination-next-btn",
516
520
  children: [
517
521
  !p && a("pagination.next", { defaultValue: "Next" }),
518
- /* @__PURE__ */ j(J.Fragment, { children: /* @__PURE__ */ j(X, { icon: "arrow_right_alt" }) }, "next-btn-pagination")
522
+ /* @__PURE__ */ j(J.Fragment, { children: /* @__PURE__ */ j(ve, { className: "gi-block gi-shrink-0" }) }, "next-btn-pagination")
519
523
  ]
520
524
  }
521
525
  )
@@ -524,5 +528,5 @@ const et = ({
524
528
  );
525
529
  };
526
530
  export {
527
- et as Pagination
531
+ it as Pagination
528
532
  };
@@ -1,5 +1,5 @@
1
1
  export type ParagraphAs = 'p' | 'span';
2
- export type ParagraphSize = 'lg' | 'md' | 'sm';
2
+ export type ParagraphSize = 'xl' | 'lg' | 'md' | 'sm';
3
3
  export type ParagraphAlign = 'start' | 'center' | 'end' | 'justify';
4
4
  export type ParagraphWhitespace = 'normal' | 'pre' | 'pre-wrap' | 'break-spaces';
5
5
  export type ParagraphProps = {