@ogcio/design-system-react 1.31.1 → 1.33.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 (114) hide show
  1. package/dist/Heading.d.ts +5 -0
  2. package/dist/Heading.js +22 -0
  3. package/dist/accordion/accordion-item.js +62 -57
  4. package/dist/alert/alert.d.ts +3 -0
  5. package/dist/alert/alert.js +40 -57
  6. package/dist/alert/variants.d.ts +49 -52
  7. package/dist/alert/variants.js +17 -18
  8. package/dist/atoms/{DsButton.d.ts → Button.d.ts} +5 -5
  9. package/dist/atoms/{DsButton.js → Button.js} +22 -36
  10. package/dist/atoms/heading/H1.d.ts +3 -0
  11. package/dist/atoms/heading/H1.js +20 -0
  12. package/dist/atoms/heading/H2.d.ts +3 -0
  13. package/dist/atoms/heading/H2.js +20 -0
  14. package/dist/atoms/heading/H3.d.ts +3 -0
  15. package/dist/atoms/heading/H3.js +20 -0
  16. package/dist/atoms/heading/H4.d.ts +3 -0
  17. package/dist/atoms/heading/H4.js +20 -0
  18. package/dist/atoms/heading/H5.d.ts +3 -0
  19. package/dist/atoms/heading/H5.js +20 -0
  20. package/dist/atoms/heading/H6.d.ts +3 -0
  21. package/dist/atoms/heading/H6.js +20 -0
  22. package/dist/atoms/heading/index.d.ts +9 -0
  23. package/dist/atoms/heading/index.js +18 -0
  24. package/dist/atoms/heading/styles.d.ts +65 -0
  25. package/dist/atoms/heading/styles.js +17 -0
  26. package/dist/atoms/heading/types.d.ts +15 -0
  27. package/dist/atoms/heading/types.js +11 -0
  28. package/dist/atoms/heading/utils.d.ts +2 -0
  29. package/dist/atoms/heading/utils.js +5 -0
  30. package/dist/atoms/icons/ArrowLeft.d.ts +3 -0
  31. package/dist/atoms/icons/ArrowLeft.js +23 -0
  32. package/dist/atoms/icons/ArrowRight.d.ts +3 -0
  33. package/dist/atoms/icons/ArrowRight.js +23 -0
  34. package/dist/atoms/icons/CheckCircle.d.ts +3 -0
  35. package/dist/atoms/icons/CheckCircle.js +23 -0
  36. package/dist/atoms/icons/Error.d.ts +3 -0
  37. package/dist/atoms/icons/Error.js +23 -0
  38. package/dist/atoms/icons/FirstPage.d.ts +3 -0
  39. package/dist/atoms/icons/FirstPage.js +23 -0
  40. package/dist/atoms/icons/Info.d.ts +3 -0
  41. package/dist/atoms/icons/Info.js +23 -0
  42. package/dist/atoms/icons/KeyboardArrowLeft.d.ts +3 -0
  43. package/dist/atoms/icons/KeyboardArrowLeft.js +23 -0
  44. package/dist/atoms/icons/KeyboardArrowRight.d.ts +3 -0
  45. package/dist/atoms/icons/KeyboardArrowRight.js +23 -0
  46. package/dist/atoms/icons/LastPage.d.ts +3 -0
  47. package/dist/atoms/icons/LastPage.js +23 -0
  48. package/dist/atoms/icons/Warning.d.ts +3 -0
  49. package/dist/atoms/icons/Warning.js +23 -0
  50. package/dist/atoms/icons/index.d.ts +12 -2
  51. package/dist/atoms/icons/index.js +30 -10
  52. package/dist/atoms/index.d.ts +2 -1
  53. package/dist/atoms/index.js +48 -12
  54. package/dist/atoms/storybook/Heading.meta.d.ts +60 -0
  55. package/dist/atoms/storybook/Heading.meta.js +70 -0
  56. package/dist/atoms/storybook/Icons.meta.d.ts +51 -0
  57. package/dist/atoms/storybook/Icons.meta.js +130 -0
  58. package/dist/atoms/storybook/InsetText.meta.d.ts +52 -0
  59. package/dist/atoms/storybook/InsetText.meta.js +64 -0
  60. package/dist/atoms/storybook/Logos.meta.d.ts +35 -0
  61. package/dist/atoms/storybook/Logos.meta.js +54 -0
  62. package/dist/breadcrumbs/breadcrumbs.js +20 -19
  63. package/dist/button/button.d.ts +2 -9
  64. package/dist/button/button.js +65 -32
  65. package/dist/button/helpers.d.ts +2 -1
  66. package/dist/button/types.d.ts +25 -8
  67. package/dist/button-group/button-group.js +43 -45
  68. package/dist/button-group/types.d.ts +5 -5
  69. package/dist/card/card-legacy.js +1 -1
  70. package/dist/card/types.d.ts +1 -1
  71. package/dist/combo-box/dropdown-item.js +1 -1
  72. package/dist/cookie-banner/cookie-banner.d.ts +1 -1
  73. package/dist/data-table/data-table-header.js +1 -1
  74. package/dist/drawer/drawer.d.ts +1 -1
  75. package/dist/drawer/drawer.js +17 -17
  76. package/dist/error-text/error-text.js +28 -27
  77. package/dist/forms/form-field/form-field.js +24 -25
  78. package/dist/header/components/header-menu.js +21 -21
  79. package/dist/header/components/header-search.js +5 -5
  80. package/dist/hint-text/hint-text.js +26 -20
  81. package/dist/icon/icon.js +85 -63
  82. package/dist/icon/icons.d.ts +1 -1
  83. package/dist/icon-button/icon-button.d.ts +3 -5
  84. package/dist/icons/index.d.ts +1 -1
  85. package/dist/icons/index.js +19 -10
  86. package/dist/index-Bh2cTIps.js +33899 -0
  87. package/dist/index.d.ts +2 -2
  88. package/dist/index.js +1 -1
  89. package/dist/input-text/input-text.js +1 -1
  90. package/dist/input-text/type.d.ts +1 -1
  91. package/dist/label/label.d.ts +78 -30
  92. package/dist/label/label.js +29 -14
  93. package/dist/modal/modal.content.js +1 -1
  94. package/dist/modal/modal.d.ts +1 -1
  95. package/dist/modal/modal.js +39 -39
  96. package/dist/modal/types.d.ts +5 -4
  97. package/dist/pagination/pagination.js +137 -134
  98. package/dist/paragraph/paragraph.d.ts +1 -1
  99. package/dist/paragraph/paragraph.js +13 -11
  100. package/dist/score-select/type.d.ts +2 -2
  101. package/dist/select/select-next.js +87 -87
  102. package/dist/side-nav/side-nav.js +4 -4
  103. package/dist/side-nav/types.d.ts +1 -1
  104. package/dist/styles.css +1 -1
  105. package/dist/table/table-pagination.js +17 -13
  106. package/dist/tabs/tab-item.js +53 -71
  107. package/dist/tabs/variants.d.ts +269 -0
  108. package/dist/tabs/variants.js +87 -0
  109. package/dist/tooltip/tooltip.js +27 -35
  110. package/dist/tooltip/variants.d.ts +115 -0
  111. package/dist/tooltip/variants.js +59 -0
  112. package/package.json +7 -6
  113. package/dist/heading/heading.d.ts +0 -150
  114. package/dist/heading/heading.js +0 -50
@@ -1,40 +1,41 @@
1
- import { jsx as a } from "react/jsx-runtime";
2
- import { c as m } from "../index-CB-zPpNk.js";
3
- const d = {
1
+ import { jsx as m } from "react/jsx-runtime";
2
+ import { c as s } from "../index-CB-zPpNk.js";
3
+ const l = {
4
4
  Small: "sm",
5
5
  Medium: "md",
6
6
  Large: "lg"
7
- }, l = m({
8
- base: "gi-error-text",
9
- variants: {
10
- size: {
11
- sm: "gi-error-text-sm",
12
- md: "gi-error-text-md",
13
- lg: "gi-error-text-lg"
14
- }
15
- },
16
- defaultVariants: {
17
- size: "md"
18
- }
19
- }), x = ({
20
- text: r,
7
+ }, d = ({
8
+ text: t,
21
9
  className: e,
22
- size: t = d.Medium,
10
+ size: r = l.Medium,
23
11
  dataTestid: i,
24
- children: o,
25
- ...s
26
- }) => /* @__PURE__ */ a(
12
+ children: a,
13
+ ...o
14
+ }) => /* @__PURE__ */ m(
27
15
  "div",
28
16
  {
29
17
  role: "alert",
30
- className: l({ size: t, className: e }),
18
+ className: n({ size: r, className: e }),
31
19
  "data-testid": i,
32
- ...s,
33
- children: o ?? r
20
+ ...o,
21
+ children: a ?? t
34
22
  }
35
23
  );
36
- x.displayName = "ErrorText";
24
+ d.displayName = "ErrorText";
25
+ const n = s({
26
+ base: "gi-font-normal gi-text-color-text-intent-error-default",
27
+ variants: {
28
+ size: {
29
+ sm: "gi-text-sm",
30
+ md: "gi-text-md",
31
+ lg: "gi-text-lg"
32
+ }
33
+ },
34
+ defaultVariants: {
35
+ size: "md"
36
+ }
37
+ });
37
38
  export {
38
- d as ErrorSize,
39
- x as ErrorText
39
+ l as ErrorSize,
40
+ d as ErrorText
40
41
  };
@@ -1,19 +1,19 @@
1
1
  "use client";
2
- import { jsx as l, jsxs as m, Fragment as x } from "react/jsx-runtime";
2
+ import { jsx as l, jsxs as d, Fragment as x } from "react/jsx-runtime";
3
3
  import { S as p } from "../../index-D_wwt4P0.js";
4
- import { createContext as N, useContext as v, Children as C } from "react";
5
- import { cn as d } from "../../cn.js";
4
+ import { createContext as v, useContext as N, Children as C } from "react";
5
+ import { cn as s } from "../../cn.js";
6
6
  import { ErrorText as L } from "../../error-text/error-text.js";
7
7
  import { HintText as E } from "../../hint-text/hint-text.js";
8
8
  import { Label as H, styles as P } from "../../label/label.js";
9
9
  import { getSpecialComponentType as F, isSpecialComponent as w } from "../../utils/utilities.js";
10
- const f = N(null);
10
+ const f = v(null);
11
11
  function b(e) {
12
- v(f) || console.error(`[${e}] must be used within a <FormField>.`);
12
+ N(f) || console.error(`[${e}] must be used within a <FormField>.`);
13
13
  }
14
14
  const U = (e) => ["error", "hint", "label"].some((r) => r in e) ? (console.warn(
15
15
  "[FormField] Using legacy props. Please migrate to the new composable API."
16
- ), /* @__PURE__ */ l(f.Provider, { value: !0, children: /* @__PURE__ */ m(y, { ...e, children: [
16
+ ), /* @__PURE__ */ l(f.Provider, { value: !0, children: /* @__PURE__ */ d(y, { ...e, children: [
17
17
  e.label && /* @__PURE__ */ l(u, { ...e.label }),
18
18
  e.hint && /* @__PURE__ */ l(h, { ...e.hint }),
19
19
  e.error && /* @__PURE__ */ l(g, { ...e.error }),
@@ -25,31 +25,31 @@ const U = (e) => ["error", "hint", "label"].some((r) => r in e) ? (console.warn(
25
25
  }) => {
26
26
  const r = C.toArray(e), n = r.find(
27
27
  (t) => F(t) === "FormFieldLabel"
28
- ), c = r.find(
28
+ ), m = r.find(
29
29
  (t) => F(t) === "FormFieldHint"
30
30
  ), a = r.find(
31
31
  (t) => F(t) === "FormFieldError"
32
- ), s = r.filter(
32
+ ), c = r.filter(
33
33
  (t) => !w(t, [
34
34
  "FormFieldLabel",
35
35
  "FormFieldHint",
36
36
  "FormFieldError"
37
37
  ])
38
38
  );
39
- return /* @__PURE__ */ m(
39
+ return /* @__PURE__ */ d(
40
40
  "fieldset",
41
41
  {
42
- className: d({ "gi-error-state": !!a }, i),
42
+ className: s({ "gi-error-state": !!a }, i),
43
43
  ...o,
44
44
  children: [
45
- /* @__PURE__ */ m("div", { className: "gi-pb-3 gi-flex gi-flex-col gi-gap-1", children: [
46
- /* @__PURE__ */ m("div", { children: [
45
+ /* @__PURE__ */ d("div", { className: "gi-pb-3 gi-flex gi-flex-col gi-gap-1", children: [
46
+ /* @__PURE__ */ d("div", { children: [
47
47
  n,
48
- c
48
+ m
49
49
  ] }),
50
50
  a
51
51
  ] }),
52
- /* @__PURE__ */ l(p, { children: s })
52
+ /* @__PURE__ */ l(p, { children: c })
53
53
  ]
54
54
  }
55
55
  );
@@ -59,32 +59,31 @@ const U = (e) => ["error", "hint", "label"].some((r) => r in e) ? (console.warn(
59
59
  size: o,
60
60
  htmlFor: r,
61
61
  className: n,
62
- secondaryLabel: c,
62
+ secondaryLabel: m,
63
63
  ...a
64
64
  }) => {
65
65
  b("FormFieldLabel");
66
- const s = /* @__PURE__ */ m(x, { children: [
66
+ const c = /* @__PURE__ */ d(x, { children: [
67
67
  i ?? e,
68
- c ? /* @__PURE__ */ l("span", { className: "gi-secondary-label", children: c }) : null
68
+ m ? /* @__PURE__ */ l("span", { className: "gi-secondary-label", children: m }) : null
69
69
  ] });
70
70
  return r ? /* @__PURE__ */ l(
71
71
  H,
72
72
  {
73
73
  size: o,
74
74
  htmlFor: r,
75
- className: d("gi-font-bold", n),
75
+ className: s("gi-font-bold", n),
76
76
  ...a,
77
- children: s
77
+ children: c
78
78
  }
79
79
  ) : /* @__PURE__ */ l(
80
80
  "legend",
81
81
  {
82
- className: P({
83
- size: o,
84
- className: d("gi-font-bold", n)
82
+ className: P({ size: o }).base({
83
+ className: s("gi-font-bold", n)
85
84
  }),
86
85
  ...a,
87
- children: s
86
+ children: c
88
87
  }
89
88
  );
90
89
  };
@@ -94,7 +93,7 @@ Object.defineProperty(u, "componentType", {
94
93
  enumerable: !1
95
94
  });
96
95
  u.displayName = "FormFieldLabel";
97
- const h = ({ children: e, text: i, size: o, className: r }) => (b("FormFieldHint"), /* @__PURE__ */ l(E, { text: i, size: o, className: d("gi-mb-1", r), children: e }));
96
+ const h = ({ children: e, text: i, size: o, className: r }) => (b("FormFieldHint"), /* @__PURE__ */ l(E, { text: i, size: o, className: r, children: e }));
98
97
  Object.defineProperty(h, "componentType", {
99
98
  value: "FormFieldHint",
100
99
  writable: !1,
@@ -112,7 +111,7 @@ const g = ({
112
111
  {
113
112
  text: i,
114
113
  size: o,
115
- className: d("gi-mb-1", r),
114
+ className: s("gi-mb-1", r),
116
115
  ...n,
117
116
  children: e
118
117
  }
@@ -1,10 +1,10 @@
1
1
  "use client";
2
- import { jsxs as i, jsx as n } from "react/jsx-runtime";
2
+ import { jsxs as i, jsx as l } from "react/jsx-runtime";
3
3
  import { useState as h } from "react";
4
- import { cn as f } from "../../cn.js";
5
- import { Icon as g } from "../../icon/icon.js";
4
+ import f from "../../atoms/icons/KeyboardArrowRight.js";
5
+ import { cn as g } from "../../cn.js";
6
6
  import { ListItem as s } from "../../list-item/list-item.js";
7
- const p = ({ index: l, item: e }) => {
7
+ const p = ({ index: n, item: e }) => {
8
8
  const [r, c] = h(!1), o = () => {
9
9
  c((a) => !a);
10
10
  }, t = (a) => {
@@ -13,35 +13,35 @@ const p = ({ index: l, item: e }) => {
13
13
  return /* @__PURE__ */ i(
14
14
  "div",
15
15
  {
16
- id: `Accordion-item-${l}`,
16
+ id: `Accordion-item-${n}`,
17
17
  className: "gi-accordion-item-container",
18
18
  "data-open": r.toString(),
19
19
  role: "presentation",
20
20
  children: [
21
- /* @__PURE__ */ n(
21
+ /* @__PURE__ */ l(
22
22
  "div",
23
23
  {
24
24
  "aria-label": e.label,
25
- id: `Accordion-header-${l}`,
25
+ id: `Accordion-header-${n}`,
26
26
  role: "button",
27
27
  "aria-expanded": r,
28
- "aria-controls": `Accordion-slot-${l}`,
28
+ "aria-controls": `Accordion-slot-${n}`,
29
29
  className: "gi-header-accordion-item-toggle",
30
30
  tabIndex: 0,
31
31
  onClick: o,
32
32
  onKeyDown: t,
33
33
  children: /* @__PURE__ */ i("div", { children: [
34
- /* @__PURE__ */ n("span", { className: "gi-text-sm gi-font-bold gi-ml-1", children: e.label }),
35
- /* @__PURE__ */ n(g, { icon: "chevron_right", className: "gi-accordion-item-icon" })
34
+ /* @__PURE__ */ l("span", { className: "gi-text-sm gi-font-bold gi-ml-1", children: e.label }),
35
+ /* @__PURE__ */ l(f, { className: "gi-block gi-shrink-0 gi-accordion-item-icon" })
36
36
  ] })
37
37
  }
38
38
  ),
39
- /* @__PURE__ */ n(
39
+ /* @__PURE__ */ l(
40
40
  "div",
41
41
  {
42
- id: `Accordion-slot-${l}`,
42
+ id: `Accordion-slot-${n}`,
43
43
  role: "region",
44
- className: f("gi-accordion-item-slot", {
44
+ className: g("gi-accordion-item-slot", {
45
45
  "gi-hidden": !r
46
46
  }),
47
47
  children: e.slot
@@ -49,13 +49,13 @@ const p = ({ index: l, item: e }) => {
49
49
  )
50
50
  ]
51
51
  },
52
- `Accordion-item-${l}`
52
+ `Accordion-item-${n}`
53
53
  );
54
- }, m = ({
55
- items: l,
54
+ }, I = ({
55
+ items: n,
56
56
  secondaryLinks: e
57
57
  }) => /* @__PURE__ */ i("ul", { children: [
58
- l == null ? void 0 : l.map(({ itemType: r, label: c, ...o }, t) => {
58
+ n == null ? void 0 : n.map(({ itemType: r, label: c, ...o }, t) => {
59
59
  const [a, d] = [
60
60
  r === "link" || r === "custom-link",
61
61
  r === "slot"
@@ -63,7 +63,7 @@ const p = ({ index: l, item: e }) => {
63
63
  if (!c)
64
64
  return null;
65
65
  if (a)
66
- return /* @__PURE__ */ n("li", { children: /* @__PURE__ */ n(
66
+ return /* @__PURE__ */ l("li", { children: /* @__PURE__ */ l(
67
67
  s,
68
68
  {
69
69
  href: o == null ? void 0 : o.href,
@@ -73,7 +73,7 @@ const p = ({ index: l, item: e }) => {
73
73
  }
74
74
  ) }, `navLink-${c}-${t}`);
75
75
  if (d)
76
- return /* @__PURE__ */ n("li", { children: /* @__PURE__ */ n(
76
+ return /* @__PURE__ */ l("li", { children: /* @__PURE__ */ l(
77
77
  p,
78
78
  {
79
79
  index: t,
@@ -84,7 +84,7 @@ const p = ({ index: l, item: e }) => {
84
84
  }
85
85
  ) }, `toolItems-${c}-${t}`);
86
86
  }),
87
- e == null ? void 0 : e.map((r, c) => /* @__PURE__ */ n("li", { children: /* @__PURE__ */ n(
87
+ e == null ? void 0 : e.map((r, c) => /* @__PURE__ */ l("li", { children: /* @__PURE__ */ l(
88
88
  s,
89
89
  {
90
90
  href: r.href,
@@ -96,5 +96,5 @@ const p = ({ index: l, item: e }) => {
96
96
  ] });
97
97
  export {
98
98
  p as MenuItemAccordion,
99
- m as MobileHeaderMenuItems
99
+ I as MobileHeaderMenuItems
100
100
  };
@@ -1,6 +1,6 @@
1
1
  import { jsxs as r, jsx as e } from "react/jsx-runtime";
2
- import { Button as c } from "../../button/button.js";
3
- import { Heading as h } from "../../heading/heading.js";
2
+ import c from "../../Heading.js";
3
+ import h from "../../atoms/Button.js";
4
4
  import { translate as a } from "../../i18n/utility.js";
5
5
  import { IconButton as d } from "../../icon-button/icon-button.js";
6
6
  import { InputText as m } from "../../input-text/input-text.js";
@@ -17,7 +17,7 @@ function b({
17
17
  "data-testid": "header-search-form",
18
18
  "aria-label": a("header.searchForm", { defaultValue: "Search Form" }),
19
19
  children: [
20
- /* @__PURE__ */ e(h, { as: "h4", children: "Search the website" }),
20
+ /* @__PURE__ */ e(c, { as: "h4", children: "Search the website" }),
21
21
  /* @__PURE__ */ r("div", { className: "gi-flex gi-items-end gi-mt-4", children: [
22
22
  /* @__PURE__ */ e(
23
23
  m,
@@ -33,9 +33,9 @@ function b({
33
33
  }
34
34
  ),
35
35
  /* @__PURE__ */ e("div", { className: "gi-ml-1 gi-flex-none gi-hidden md:gi-block", children: /* @__PURE__ */ e(
36
- c,
36
+ h,
37
37
  {
38
- "aria-label": a("header.submitSearch", {
38
+ ariaLabel: a("header.submitSearch", {
39
39
  defaultValue: "Submit Search"
40
40
  }),
41
41
  children: a("header.search", { defaultValue: "Search" })
@@ -1,30 +1,36 @@
1
- import { jsx as n } from "react/jsx-runtime";
2
- import { c as a } from "../index-CB-zPpNk.js";
3
- const d = {
1
+ import { jsx as a } from "react/jsx-runtime";
2
+ import { c as o } from "../index-CB-zPpNk.js";
3
+ const n = {
4
4
  Small: "sm",
5
5
  Medium: "md",
6
6
  Large: "lg"
7
- }, l = a({
8
- base: "gi-hint-text",
7
+ }, r = ({
8
+ text: t,
9
+ children: e,
10
+ className: i,
11
+ size: m = n.Medium,
12
+ ...s
13
+ }) => /* @__PURE__ */ a(
14
+ "div",
15
+ {
16
+ className: l({ size: m, className: i }),
17
+ "data-testid": "hint-text",
18
+ ...s,
19
+ children: e ?? t
20
+ }
21
+ );
22
+ r.displayName = "HintText";
23
+ const l = o({
24
+ base: "gi-font-normal gi-text-color-text-system-neutral-muted gi-stroke-color-text-system-neutral-muted gi-mb-0",
9
25
  variants: {
10
26
  size: {
11
- sm: "gi-hint-text-sm",
12
- md: "gi-hint-text-md",
13
- lg: "gi-hint-text-lg"
27
+ sm: "gi-text-sm",
28
+ md: "gi-text-md",
29
+ lg: "gi-text-lg"
14
30
  }
15
- },
16
- defaultVariants: {
17
- size: "md"
18
31
  }
19
- }), r = ({
20
- text: t,
21
- children: i,
22
- className: e,
23
- size: m = d.Medium,
24
- ...s
25
- }) => /* @__PURE__ */ n("div", { className: l({ size: m, className: e }), ...s, children: i ?? t });
26
- r.displayName = "HintText";
32
+ });
27
33
  export {
28
- d as HintSize,
34
+ n as HintSize,
29
35
  r as HintText
30
36
  };
package/dist/icon/icon.js CHANGED
@@ -1,98 +1,120 @@
1
1
  "use client";
2
- import { jsx as m } from "react/jsx-runtime";
2
+ import { jsx as s } from "react/jsx-runtime";
3
3
  import { forwardRef as u } from "react";
4
- import x from "../atoms/icons/KeyboardArrowDown.js";
5
- import h from "../atoms/icons/KeyboardArrowUp.js";
6
- import w from "../atoms/icons/Close.js";
7
- import I from "../atoms/icons/Visibility.js";
8
- import S from "../atoms/icons/VisibilityOff.js";
9
- import { cn as l } from "../cn.js";
10
- import v from "./svgs/bluesky.js";
11
- import A from "./svgs/facebook.js";
12
- import R from "./svgs/instagram.js";
13
- import z from "./svgs/linkedin.js";
14
- import T from "./svgs/placeholder.js";
15
- import V from "./svgs/threads.js";
16
- import D from "./svgs/tiktok.js";
17
- import E from "./svgs/x.js";
18
- import F from "./svgs/youtube.js";
19
- const d = {
4
+ import x from "../atoms/icons/Close.js";
5
+ import A from "../atoms/icons/Visibility.js";
6
+ import I from "../atoms/icons/VisibilityOff.js";
7
+ import l from "../atoms/icons/KeyboardArrowLeft.js";
8
+ import p from "../atoms/icons/KeyboardArrowRight.js";
9
+ import v from "../atoms/icons/KeyboardArrowDown.js";
10
+ import R from "../atoms/icons/KeyboardArrowUp.js";
11
+ import L from "../atoms/icons/ArrowLeft.js";
12
+ import S from "../atoms/icons/ArrowRight.js";
13
+ import K from "../atoms/icons/FirstPage.js";
14
+ import P from "../atoms/icons/LastPage.js";
15
+ import z from "../atoms/icons/Info.js";
16
+ import E from "../atoms/icons/Error.js";
17
+ import F from "../atoms/icons/Warning.js";
18
+ import T from "../atoms/icons/CheckCircle.js";
19
+ import { cn as f } from "../cn.js";
20
+ import V from "./svgs/bluesky.js";
21
+ import D from "./svgs/facebook.js";
22
+ import G from "./svgs/instagram.js";
23
+ import N from "./svgs/linkedin.js";
24
+ import O from "./svgs/placeholder.js";
25
+ import Y from "./svgs/threads.js";
26
+ import $ from "./svgs/tiktok.js";
27
+ import j from "./svgs/x.js";
28
+ import B from "./svgs/youtube.js";
29
+ const g = {
20
30
  sm: "16px",
21
31
  md: "24px",
22
32
  lg: "32px",
23
33
  xl: "48px"
24
- }, G = {
25
- social_bluesky: { Component: v, disabledClass: "gi-stroke-gray-700" },
26
- social_facebook: { Component: A, disabledClass: "gi-stroke-gray-700" },
34
+ }, M = {
35
+ social_bluesky: { Component: V, disabledClass: "gi-stroke-gray-700" },
36
+ social_facebook: { Component: D, disabledClass: "gi-stroke-gray-700" },
27
37
  social_instagram: {
28
- Component: R,
38
+ Component: G,
29
39
  disabledClass: "gi-stroke-gray-700"
30
40
  },
31
- social_linkedin: { Component: z, disabledClass: "gi-stroke-gray-700" },
32
- social_threads: { Component: V, disabledClass: "gi-stroke-gray-700" },
33
- social_tiktok: { Component: D, disabledClass: "gi-stroke-gray-700" },
34
- social_x: { Component: E, disabledClass: "gi-stroke-gray-700" },
35
- social_youtube: { Component: F, disabledClass: "gi-stroke-gray-700" },
36
- placeholder: { Component: T },
37
- keyboard_arrow_down: { Component: x },
38
- keyboard_arrow_up: { Component: h },
39
- close: { Component: w },
40
- visibility: { Component: I },
41
- visibility_off: { Component: S }
42
- }, W = u(
41
+ social_linkedin: { Component: N, disabledClass: "gi-stroke-gray-700" },
42
+ social_threads: { Component: Y, disabledClass: "gi-stroke-gray-700" },
43
+ social_tiktok: { Component: $, disabledClass: "gi-stroke-gray-700" },
44
+ social_x: { Component: j, disabledClass: "gi-stroke-gray-700" },
45
+ social_youtube: { Component: B, disabledClass: "gi-stroke-gray-700" },
46
+ placeholder: { Component: O },
47
+ keyboard_arrow_down: { Component: v },
48
+ keyboard_arrow_up: { Component: R },
49
+ close: { Component: x },
50
+ visibility: { Component: A },
51
+ visibility_off: { Component: I },
52
+ info: { Component: z },
53
+ error: { Component: E },
54
+ warning: { Component: F },
55
+ check_circle: { Component: T },
56
+ keyboard_arrow_left: { Component: l },
57
+ keyboard_arrow_right: { Component: p },
58
+ chevron_left: { Component: l },
59
+ chevron_right: { Component: p },
60
+ arrow_left_alt: { Component: L },
61
+ arrow_right_alt: { Component: S },
62
+ first_page: { Component: K },
63
+ last_page: { Component: P }
64
+ }, ho = u(
43
65
  ({
44
- icon: r,
45
- size: g = "md",
46
- filled: p,
47
- disabled: s,
66
+ icon: i,
67
+ size: d = "md",
68
+ filled: C,
69
+ disabled: e,
48
70
  ariaHidden: c,
49
- ariaLabel: e,
71
+ ariaLabel: n,
50
72
  inline: o,
51
- className: a,
52
- onClick: f,
53
- useFontIcon: C,
54
- ...i
55
- }, b) => {
56
- const t = d[g] ?? d.md, n = G[String(r)];
57
- if (n && !C) {
58
- const { Component: k, disabledClass: y } = n, _ = l(
73
+ className: m,
74
+ onClick: b,
75
+ useFontIcon: k,
76
+ ...r
77
+ }, y) => {
78
+ const t = g[d] ?? g.md, a = M[String(i)];
79
+ if (a && !k) {
80
+ const { Component: _, disabledClass: h } = a, w = f(
59
81
  { "gi-block": !o, "gi-inline-block": o },
60
82
  "gi-shrink-0",
61
- s && (y || "gi-fill-gray-700"),
62
- a
83
+ e && (h || "gi-fill-gray-700"),
84
+ m
63
85
  );
64
- return /* @__PURE__ */ m(k, { size: t, className: _ });
86
+ return /* @__PURE__ */ s(_, { size: t, className: w });
65
87
  }
66
- return /* @__PURE__ */ m(
88
+ return /* @__PURE__ */ s(
67
89
  "span",
68
90
  {
69
91
  "aria-hidden": c,
70
- "aria-label": e,
92
+ "aria-label": n,
71
93
  "data-testid": "govie-icon",
72
- ...i,
73
- ref: b,
74
- onClick: f,
75
- role: e ? "img" : "presentation",
76
- className: l(
94
+ ...r,
95
+ ref: y,
96
+ onClick: b,
97
+ role: n ? "img" : "presentation",
98
+ className: f(
77
99
  {
78
100
  "gi-block": !o,
79
101
  "gi-inline-block": o,
80
- "gi-text-gray-700": s
102
+ "gi-text-gray-700": e
81
103
  },
82
104
  "material-symbols-outlined",
83
- a
105
+ m
84
106
  ),
85
107
  style: {
86
108
  fontSize: t,
87
- fontVariationSettings: `'FILL' ${p ? 1 : 0}, 'wght' 400, 'GRAD' 0, 'opsz' ${t}`,
88
- ...i == null ? void 0 : i.style
109
+ fontVariationSettings: `'FILL' ${C ? 1 : 0}, 'wght' 400, 'GRAD' 0, 'opsz' ${t}`,
110
+ ...r == null ? void 0 : r.style
89
111
  },
90
- children: r
112
+ children: i
91
113
  }
92
114
  );
93
115
  }
94
116
  );
95
117
  export {
96
- W as Icon,
97
- W as default
118
+ ho as Icon,
119
+ ho as default
98
120
  };
@@ -1,2 +1,2 @@
1
1
  export declare const iconIds: readonly ["accessibility_new", "add_circle", "apps", "arrow_back", "arrow_downward", "arrow_drop_down", "arrow_drop_up", "arrow_forward", "arrow_left_alt", "arrow_outward", "arrow_right_alt", "arrow_upward", "attach_file", "block", "call", "cancel", "candlestick_chart", "chat_bubble", "check", "check_circle", "chevron_left", "chevron_right", "child_care", "close", "content_copy", "credit_card", "delete", "directions_car", "do_not_disturb_on", "download", "edit", "error", "event", "filter_list", "health_and_safety", "home", "info", "keyboard_arrow_down", "keyboard_arrow_up", "link", "location_on", "login", "logout", "mail", "menu", "mic", "more_horiz", "more_vert", "open_in_new", "person", "person_cancel", "person_check", "refresh", "search", "send", "settings", "sort", "space_dashboard", "sync", "swap_vert", "thumb_down", "thumb_up", "unfold_more", "upload", "visibility", "visibility_off", "warning", "work", "social_bluesky", "social_facebook", "social_instagram", "social_linkedin", "social_threads", "social_tiktok", "social_x", "social_youtube", "placeholder", "first_page", "last_page"];
2
- export declare const Icons: ("search" | "link" | "sort" | "menu" | "keyboard_arrow_down" | "keyboard_arrow_up" | "close" | "visibility" | "accessibility_new" | "add_circle" | "apps" | "arrow_back" | "arrow_downward" | "arrow_drop_down" | "arrow_drop_up" | "arrow_forward" | "arrow_left_alt" | "arrow_outward" | "arrow_right_alt" | "arrow_upward" | "attach_file" | "block" | "call" | "cancel" | "candlestick_chart" | "chat_bubble" | "check" | "check_circle" | "chevron_left" | "chevron_right" | "child_care" | "content_copy" | "credit_card" | "delete" | "directions_car" | "do_not_disturb_on" | "download" | "edit" | "error" | "event" | "filter_list" | "health_and_safety" | "home" | "info" | "location_on" | "login" | "logout" | "mail" | "mic" | "more_horiz" | "more_vert" | "open_in_new" | "person" | "person_cancel" | "person_check" | "refresh" | "send" | "settings" | "space_dashboard" | "sync" | "swap_vert" | "thumb_down" | "thumb_up" | "unfold_more" | "upload" | "visibility_off" | "warning" | "work" | "social_bluesky" | "social_facebook" | "social_instagram" | "social_linkedin" | "social_threads" | "social_tiktok" | "social_x" | "social_youtube" | "placeholder" | "first_page" | "last_page")[];
2
+ export declare const Icons: ("search" | "link" | "sort" | "menu" | "close" | "visibility" | "keyboard_arrow_down" | "keyboard_arrow_up" | "first_page" | "last_page" | "info" | "error" | "warning" | "check_circle" | "accessibility_new" | "add_circle" | "apps" | "arrow_back" | "arrow_downward" | "arrow_drop_down" | "arrow_drop_up" | "arrow_forward" | "arrow_left_alt" | "arrow_outward" | "arrow_right_alt" | "arrow_upward" | "attach_file" | "block" | "call" | "cancel" | "candlestick_chart" | "chat_bubble" | "check" | "chevron_left" | "chevron_right" | "child_care" | "content_copy" | "credit_card" | "delete" | "directions_car" | "do_not_disturb_on" | "download" | "edit" | "event" | "filter_list" | "health_and_safety" | "home" | "location_on" | "login" | "logout" | "mail" | "mic" | "more_horiz" | "more_vert" | "open_in_new" | "person" | "person_cancel" | "person_check" | "refresh" | "send" | "settings" | "space_dashboard" | "sync" | "swap_vert" | "thumb_down" | "thumb_up" | "unfold_more" | "upload" | "visibility_off" | "work" | "social_bluesky" | "social_facebook" | "social_instagram" | "social_linkedin" | "social_threads" | "social_tiktok" | "social_x" | "social_youtube" | "placeholder")[];
@@ -1,10 +1,8 @@
1
1
  import { ButtonProps } from '../button/types.js';
2
2
  import { IconProps } from '../icon/icon.js';
3
- export type IconButtonProps = Omit<ButtonProps, 'children'> & {
3
+ export type IconButtonProps = Omit<ButtonProps, 'children' | 'size'> & {
4
4
  icon: Omit<IconProps, 'size'>;
5
5
  className?: string;
6
+ size?: 'medium' | 'small' | 'large' | 'extraLarge';
6
7
  };
7
- export declare const IconButton: import('react').ForwardRefExoticComponent<Omit<ButtonProps, "children"> & {
8
- icon: Omit<IconProps, "size">;
9
- className?: string;
10
- } & import('react').RefAttributes<HTMLButtonElement>>;
8
+ export declare const IconButton: import('react').ForwardRefExoticComponent<Omit<IconButtonProps, "ref"> & import('react').RefAttributes<HTMLButtonElement>>;
@@ -1 +1 @@
1
- export { Close, KeyboardArrowDown, KeyboardArrowUp, Visibility, VisibilityOff, } from '../atoms/icons';
1
+ export { Close, KeyboardArrowDown, KeyboardArrowUp, Visibility, VisibilityOff, CheckCircle, Error, Info, Warning, } from '../atoms/icons';
@@ -1,12 +1,21 @@
1
- import { default as e } from "../atoms/icons/KeyboardArrowDown.js";
2
- import { default as f } from "../atoms/icons/KeyboardArrowUp.js";
3
- import { default as i } from "../atoms/icons/Close.js";
4
- import { default as s } from "../atoms/icons/Visibility.js";
5
- import { default as p } from "../atoms/icons/VisibilityOff.js";
1
+ import { default as a } from "../atoms/icons/Close.js";
2
+ import { default as t } from "../atoms/icons/Visibility.js";
3
+ import { default as s } from "../atoms/icons/VisibilityOff.js";
4
+ import "react/jsx-runtime";
5
+ import { default as i } from "../atoms/icons/KeyboardArrowDown.js";
6
+ import { default as m } from "../atoms/icons/KeyboardArrowUp.js";
7
+ import { default as x } from "../atoms/icons/Info.js";
8
+ import { default as n } from "../atoms/icons/Error.js";
9
+ import { default as w } from "../atoms/icons/Warning.js";
10
+ import { default as c } from "../atoms/icons/CheckCircle.js";
6
11
  export {
7
- i as Close,
8
- e as KeyboardArrowDown,
9
- f as KeyboardArrowUp,
10
- s as Visibility,
11
- p as VisibilityOff
12
+ c as CheckCircle,
13
+ a as Close,
14
+ n as Error,
15
+ x as Info,
16
+ i as KeyboardArrowDown,
17
+ m as KeyboardArrowUp,
18
+ t as Visibility,
19
+ s as VisibilityOff,
20
+ w as Warning
12
21
  };