@ogcio/design-system-react 1.12.4 → 1.13.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 (96) hide show
  1. package/dist/accordion/accordion-item.js +1 -1
  2. package/dist/alert/alert.js +1 -1
  3. package/dist/autocomplete/autocomplete.js +124 -198
  4. package/dist/autocomplete/types.d.ts +23 -5
  5. package/dist/autocomplete/use-autocomplete-controller.d.ts +10 -0
  6. package/dist/autocomplete/use-autocomplete-controller.js +125 -0
  7. package/dist/button/helpers.d.ts +1 -1
  8. package/dist/button/helpers.js +14 -12
  9. package/dist/button/types.d.ts +1 -1
  10. package/dist/button-group/button-group.d.ts +1 -0
  11. package/dist/button-group/button-group.js +67 -60
  12. package/dist/card/card-next.js +28 -28
  13. package/dist/checkbox/checkbox.d.ts +7 -1
  14. package/dist/combo-box/dropdown-item.js +30 -30
  15. package/dist/data-grid/editable-table-cell.d.ts +3 -0
  16. package/dist/data-grid/editable-table-cell.js +73 -0
  17. package/dist/data-grid/tanstack/tanstack-helpers.d.ts +11 -0
  18. package/dist/data-grid/tanstack/tanstack-helpers.js +1799 -0
  19. package/dist/data-grid/types.d.ts +20 -0
  20. package/dist/data-grid/types.js +1 -0
  21. package/dist/drawer/drawer.content.js +6 -6
  22. package/dist/drawer/drawer.js +8 -8
  23. package/dist/error-text/error-text.js +1 -1
  24. package/dist/forms/form-field/form-field.js +4 -4
  25. package/dist/forms/form-field-with-tag/form-field-with-tag.js +1 -1
  26. package/dist/header/components/header-slot.js +38 -27
  27. package/dist/header/header.js +5 -5
  28. package/dist/heading/heading.js +1 -1
  29. package/dist/hint-text/hint-text.js +1 -1
  30. package/dist/hooks/use-aria-hider.d.ts +1 -0
  31. package/dist/hooks/use-aria-hider.js +20 -0
  32. package/dist/hooks/use-focus-trap.d.ts +2 -0
  33. package/dist/hooks/use-focus-trap.js +678 -0
  34. package/dist/icon/icon.js +32 -32
  35. package/dist/icon/icons.d.ts +2 -2
  36. package/dist/icon/icons.js +5 -1
  37. package/dist/icon/svgs/placeholder.js +2 -2
  38. package/dist/icon-button/icon-button.js +17 -17
  39. package/dist/index-2sRBqKFV.js +78 -0
  40. package/dist/{index-DNkhmzZp.js → index-CB-zPpNk.js} +44 -44
  41. package/dist/index.d.ts +6 -4
  42. package/dist/index.js +135 -130
  43. package/dist/input-checkbox/input-checkbox.d.ts +9 -2
  44. package/dist/input-checkbox/input-checkbox.js +65 -42
  45. package/dist/input-checkbox/types.d.ts +5 -0
  46. package/dist/input-checkbox-group/input-checkbox-group.js +22 -16
  47. package/dist/input-checkbox-group/types.d.ts +1 -0
  48. package/dist/input-radio/input-radio.js +15 -15
  49. package/dist/input-radio-group/input-radio-group.js +24 -17
  50. package/dist/input-radio-group/types.d.ts +1 -0
  51. package/dist/input-text/input-text.d.ts +22 -0
  52. package/dist/input-text/input-text.js +121 -100
  53. package/dist/input-text/type.d.ts +5 -0
  54. package/dist/label/label.js +1 -1
  55. package/dist/link/link.js +1 -1
  56. package/dist/list/list.js +2 -2
  57. package/dist/lodash-D1c5hFAM.js +3677 -0
  58. package/dist/modal/modal.content.js +1 -1
  59. package/dist/modal/modal.js +141 -127
  60. package/dist/popover/popover.js +464 -466
  61. package/dist/primitives/anchor.js +1 -1
  62. package/dist/progress-bar/progress-bar.js +8 -8
  63. package/dist/progress-stepper/progress-stepper.js +12 -12
  64. package/dist/score-select/score-select.js +3 -3
  65. package/dist/select/select-menu.d.ts +1 -1
  66. package/dist/select/select-menu.js +96 -90
  67. package/dist/select/select-native.d.ts +5 -2
  68. package/dist/select/select-native.js +45 -15
  69. package/dist/select/select-next.d.ts +3 -2
  70. package/dist/select/select-next.js +125 -92
  71. package/dist/select/select-search.d.ts +3 -0
  72. package/dist/select/select-search.js +24 -0
  73. package/dist/select/select.d.ts +4 -2
  74. package/dist/select/select.js +3 -2
  75. package/dist/select/types.d.ts +22 -0
  76. package/dist/side-nav/side-nav.js +23 -23
  77. package/dist/spinner/spinner.js +1 -1
  78. package/dist/stack/stack.js +40 -49
  79. package/dist/styles.css +2 -3
  80. package/dist/table/index.d.ts +8 -0
  81. package/dist/table/index.js +19 -0
  82. package/dist/table/table-data.d.ts +16 -2
  83. package/dist/table/table-data.js +64 -17
  84. package/dist/table/table-header.d.ts +4 -1
  85. package/dist/table/table-header.js +58 -18
  86. package/dist/table/table-pagination.d.ts +8 -0
  87. package/dist/table/table-pagination.js +97 -0
  88. package/dist/table/table-row.js +7 -6
  89. package/dist/table/table.d.ts +4 -1
  90. package/dist/table/table.js +22 -15
  91. package/dist/text-input/text-input.d.ts +1 -0
  92. package/dist/textarea/textarea.js +18 -17
  93. package/dist/toast/ds-toast.js +1 -1
  94. package/dist/tooltip/tooltip.js +1 -1
  95. package/package.json +6 -6
  96. package/dist/index-ntYL1VRC.js +0 -64
@@ -1,5 +1,5 @@
1
1
  import { jsx as t } from "react/jsx-runtime";
2
- import { a } from "../index-ntYL1VRC.js";
2
+ import { a } from "../index-2sRBqKFV.js";
3
3
  const f = ({
4
4
  external: o = !1,
5
5
  asChild: r,
@@ -1,13 +1,13 @@
1
1
  import { jsxs as l, jsx as a } from "react/jsx-runtime";
2
- import { cn as n } from "../cn.js";
3
- import { translate as t } from "../i18n/utility.js";
2
+ import { cn as t } from "../cn.js";
3
+ import { translate as g } from "../i18n/utility.js";
4
4
  function d({
5
5
  value: s = 0,
6
6
  max: e = 100,
7
7
  isIndeterminate: r,
8
- label: i
8
+ label: o
9
9
  }) {
10
- const o = s * 100 / e;
10
+ const i = s * 100 / e;
11
11
  return /* @__PURE__ */ l("div", { className: "gi-progress-bar-container", children: [
12
12
  /* @__PURE__ */ a(
13
13
  "div",
@@ -16,7 +16,7 @@ function d({
16
16
  "aria-valuenow": r ? void 0 : s,
17
17
  "aria-valuemin": 0,
18
18
  "aria-valuemax": e,
19
- "aria-label": t("progressBar.progressBar", {
19
+ "aria-label": g("progressBar.progressBar", {
20
20
  defaultValue: "Progress bar"
21
21
  }),
22
22
  "data-testid": "progress-bar",
@@ -24,15 +24,15 @@ function d({
24
24
  children: /* @__PURE__ */ a(
25
25
  "div",
26
26
  {
27
- className: n({
27
+ className: t({
28
28
  "gi-progress-bar-indeterminate": r
29
29
  }),
30
- style: r ? {} : { width: `${o}%` }
30
+ style: r ? {} : { width: `${i}%` }
31
31
  }
32
32
  )
33
33
  }
34
34
  ),
35
- i && /* @__PURE__ */ a("span", { children: i })
35
+ o && /* @__PURE__ */ a("span", { children: o })
36
36
  ] });
37
37
  }
38
38
  export {
@@ -1,8 +1,8 @@
1
- import { jsxs as f, jsx as r } from "react/jsx-runtime";
1
+ import { jsxs as v, jsx as r } from "react/jsx-runtime";
2
2
  import { Children as P } from "react";
3
3
  import { cn as $ } from "../cn.js";
4
4
  import { Icon as z } from "../icon/icon.js";
5
- import { ProgressStepperIndicator as v } from "./types.js";
5
+ import { ProgressStepperIndicator as f } from "./types.js";
6
6
  const j = (e) => `calc(100% + ${e * 4 - 36}px)`, k = ({
7
7
  isNextStep: e,
8
8
  orientation: t = "horizontal",
@@ -11,7 +11,7 @@ const j = (e) => `calc(100% + ${e * 4 - 36}px)`, k = ({
11
11
  verticalGap: l
12
12
  }) => {
13
13
  const o = t === "vertical" ? { height: j(l) } : void 0;
14
- return /* @__PURE__ */ f(
14
+ return /* @__PURE__ */ v(
15
15
  "div",
16
16
  {
17
17
  "data-orientation": t,
@@ -28,19 +28,19 @@ const j = (e) => `calc(100% + ${e * 4 - 36}px)`, k = ({
28
28
  }
29
29
  );
30
30
  }, x = (e) => ({
31
- [v.Hashtag]: {
31
+ [f.Hashtag]: {
32
32
  completed: /* @__PURE__ */ r(z, { icon: "check" }),
33
33
  current: () => "#",
34
34
  next: () => "#"
35
35
  },
36
- [v.Number]: {
36
+ [f.Number]: {
37
37
  completed: /* @__PURE__ */ r(z, { icon: "check" }),
38
38
  current: (s) => s,
39
39
  next: (s) => s
40
40
  }
41
41
  })[e], V = (e, t, s, a) => {
42
42
  const { current: l, completed: o, next: i } = x(
43
- e || v.Hashtag
43
+ e || f.Hashtag
44
44
  );
45
45
  return s ? o : a ? l(t) : i(t);
46
46
  }, B = ({
@@ -58,8 +58,8 @@ const j = (e) => `calc(100% + ${e * 4 - 36}px)`, k = ({
58
58
  verticalGap: h
59
59
  }) => {
60
60
  const m = !t && !e, c = l === "vertical" && (e || d || t), p = !!o;
61
- return /* @__PURE__ */ f("div", { className: "gi-relative", children: [
62
- /* @__PURE__ */ f(
61
+ return /* @__PURE__ */ v("div", { className: "gi-relative", children: [
62
+ /* @__PURE__ */ v(
63
63
  "div",
64
64
  {
65
65
  className: "gi-progress-stepper-step-container",
@@ -68,13 +68,12 @@ const j = (e) => `calc(100% + ${e * 4 - 36}px)`, k = ({
68
68
  "data-completed": t,
69
69
  "data-next": m,
70
70
  "data-indicator": i,
71
- role: "listitem",
72
71
  "aria-labelledby": `step-label-${a}`,
73
72
  "data-testid": u || `step-label-${a}`,
74
73
  "aria-label": p ? void 0 : g,
75
74
  children: [
76
75
  /* @__PURE__ */ r("div", { className: "gi-progress-stepper-step", "data-indicator": i, children: V(
77
- i || v.Hashtag,
76
+ i || f.Hashtag,
78
77
  a,
79
78
  t,
80
79
  e
@@ -126,9 +125,10 @@ const j = (e) => `calc(100% + ${e * 4 - 36}px)`, k = ({
126
125
  }) => {
127
126
  var g, h;
128
127
  const d = (h = (g = e[t]) == null ? void 0 : g.props) == null ? void 0 : h.children, u = s === "horizontal" && d;
129
- return /* @__PURE__ */ f(
128
+ return /* @__PURE__ */ v(
130
129
  "div",
131
130
  {
131
+ role: "presentation",
132
132
  className: $("gi-w-full", {
133
133
  "gi-flex": s === "vertical"
134
134
  }),
@@ -158,7 +158,7 @@ const j = (e) => `calc(100% + ${e * 4 - 36}px)`, k = ({
158
158
  c === e.length - 1,
159
159
  l || c < t && c !== t
160
160
  ];
161
- return /* @__PURE__ */ r("div", { className: "gi-w-full", children: /* @__PURE__ */ r(
161
+ return /* @__PURE__ */ r("div", { className: "gi-w-full", role: "listitem", children: /* @__PURE__ */ r(
162
162
  B,
163
163
  {
164
164
  stepNumber: c + 1,
@@ -2,7 +2,7 @@
2
2
  import { jsxs as u, jsx as d } from "react/jsx-runtime";
3
3
  import k from "react";
4
4
  import { ButtonGroup as y, ButtonGroupItem as N } from "../button-group/button-group.js";
5
- import { FormField as f, FormFieldLabel as x, FormFieldHint as j } from "../forms/form-field/form-field.js";
5
+ import { FormField as x, FormFieldLabel as f, FormFieldHint as j } from "../forms/form-field/form-field.js";
6
6
  const _ = ({
7
7
  name: p,
8
8
  size: $ = "medium",
@@ -57,8 +57,8 @@ const _ = ({
57
57
  break;
58
58
  }
59
59
  }
60
- return /* @__PURE__ */ u(f, { className: "gi-w-full", children: [
61
- /* @__PURE__ */ d(x, { id: v, children: F }),
60
+ return /* @__PURE__ */ u(x, { className: "gi-w-full", children: [
61
+ /* @__PURE__ */ d(f, { id: v, children: F }),
62
62
  i && /* @__PURE__ */ d(j, { id: b, children: i }),
63
63
  /* @__PURE__ */ u(
64
64
  "div",
@@ -1,5 +1,5 @@
1
1
  import { SelectMenuOptionProps, SelectMenuProps } from './types.js';
2
- export declare const SelectMenu: ({ children, className, onChange, enableSearch, }: SelectMenuProps) => import("react/jsx-runtime").JSX.Element;
2
+ export declare const SelectMenu: ({ children, className, onChange, enableSearch, isLoading, showNoData, }: SelectMenuProps) => import("react/jsx-runtime").JSX.Element;
3
3
  export declare const SelectMenuOption: ({ children, value, selected, onChange, disabled, dataTestid, className, hidden, enableSearch, isHighlighted, ...props }: SelectMenuOptionProps) => import("react/jsx-runtime").JSX.Element | null;
4
4
  export declare const SelectMenuGroupItem: ({ children, label, ...props }: {
5
5
  children?: any;
@@ -1,142 +1,148 @@
1
1
  "use client";
2
- import { jsxs as h, jsx as c } from "react/jsx-runtime";
3
- import { useState as C, useEffect as K, Children as D, isValidElement as $, cloneElement as w } from "react";
4
- import { cn as A } from "../cn.js";
5
- import { Icon as P } from "../icon/icon.js";
6
- import { InputText as V } from "../input-text/input-text.js";
7
- import { Label as z } from "../label/label.js";
8
- const W = ({
9
- children: n,
10
- className: s,
11
- onChange: l,
12
- enableSearch: r
2
+ import { jsxs as N, jsx as n } from "react/jsx-runtime";
3
+ import { useState as h, useEffect as A, Children as K, isValidElement as P, cloneElement as v } from "react";
4
+ import { cn as V } from "../cn.js";
5
+ import { translate as q } from "../i18n/utility.js";
6
+ import { Icon as H } from "../icon/icon.js";
7
+ import { InputText as J } from "../input-text/input-text.js";
8
+ import { Label as Q } from "../label/label.js";
9
+ import { Spinner as R } from "../spinner/spinner.js";
10
+ const re = ({
11
+ children: o,
12
+ className: i,
13
+ onChange: s,
14
+ enableSearch: r,
15
+ isLoading: c,
16
+ showNoData: m
13
17
  }) => {
14
- const [e, d] = C(""), [u, g] = C([]);
15
- K(() => {
16
- const S = D.toArray(n).filter(
17
- (i) => $(i)
18
- ).map((i) => {
19
- var b, v, N, x, L, M;
20
- const y = (b = i == null ? void 0 : i.type) == null ? void 0 : b.componentType, a = e.toLowerCase();
21
- switch (y) {
18
+ const [l, g] = h(""), [S, f] = h(!1), [y, O] = h([]);
19
+ A(() => {
20
+ f(!1), m && setTimeout(() => f(!0), 0);
21
+ }, [m]), A(() => {
22
+ const B = K.toArray(o).filter(
23
+ (a) => P(a)
24
+ ).map((a) => {
25
+ var D, L, M, T, I, k;
26
+ const F = (D = a == null ? void 0 : a.type) == null ? void 0 : D.componentType, x = l.toLowerCase();
27
+ switch (F) {
22
28
  case "SelectMenuOption": {
23
- const t = i;
24
- if (typeof t.props.value == "string") {
25
- const I = ((x = (N = (v = t == null ? void 0 : t.props) == null ? void 0 : v.children) == null ? void 0 : N.toString()) == null ? void 0 : x.toLowerCase()) || "", T = (M = (L = t == null ? void 0 : t.props) == null ? void 0 : L.value) == null ? void 0 : M.toLowerCase();
26
- if (I.includes(a) || T.includes(a))
27
- return w(t, {
28
- onChange: l,
29
+ const e = a;
30
+ if (typeof e.props.value == "string") {
31
+ const E = ((T = (M = (L = e == null ? void 0 : e.props) == null ? void 0 : L.children) == null ? void 0 : M.toString()) == null ? void 0 : T.toLowerCase()) || "", G = (k = (I = e == null ? void 0 : e.props) == null ? void 0 : I.value) == null ? void 0 : k.toLowerCase();
32
+ if (E.includes(x) || G.includes(x))
33
+ return v(e, {
34
+ onChange: s,
29
35
  enableSearch: r
30
36
  });
31
37
  }
32
38
  break;
33
39
  }
34
40
  case "SelectMenuGroupItem": {
35
- const t = i, k = D.toArray(t.props.children).filter(
36
- (o) => $(o)
37
- ).map((o) => {
41
+ const e = a, j = K.toArray(e.props.children).filter(
42
+ (t) => P(t)
43
+ ).map((t) => {
38
44
  var p;
39
- return ((p = o == null ? void 0 : o.type) == null ? void 0 : p.componentType) === "SelectMenuOption" ? w(o, { onChange: l }) : null;
45
+ return ((p = t == null ? void 0 : t.type) == null ? void 0 : p.componentType) === "SelectMenuOption" ? v(t, { onChange: s }) : null;
40
46
  }).filter(
41
- (o) => o !== null
42
- ).filter((o) => {
43
- var E, G, j;
44
- const p = ((G = (E = o.props.children) == null ? void 0 : E.toString()) == null ? void 0 : G.toLowerCase()) || "", f = ((j = o.props.value) == null ? void 0 : j.toLowerCase()) || "";
45
- return (p == null ? void 0 : p.includes(e.toLowerCase())) || (f == null ? void 0 : f.includes(e.toLowerCase()));
47
+ (t) => t !== null
48
+ ).filter((t) => {
49
+ var C, $, z;
50
+ const p = (($ = (C = t.props.children) == null ? void 0 : C.toString()) == null ? void 0 : $.toLowerCase()) || "", d = ((z = t.props.value) == null ? void 0 : z.toLowerCase()) || "";
51
+ return (p == null ? void 0 : p.includes(l.toLowerCase())) || (d == null ? void 0 : d.includes(l.toLowerCase()));
46
52
  });
47
- return k.length > 0 || e === "" ? w(t, {
48
- children: k
53
+ return j.length > 0 || l === "" ? v(e, {
54
+ children: j
49
55
  }) : null;
50
56
  }
51
57
  default:
52
58
  return null;
53
59
  }
54
60
  }).filter(Boolean);
55
- g(S);
56
- }, [n, e, l]);
57
- const O = (m) => {
58
- d(m.target.value);
59
- };
60
- return /* @__PURE__ */ h("div", { className: A("gi-select-menu-container", s), children: [
61
- r && /* @__PURE__ */ c("div", { className: "gi-select-menu-input-container", children: /* @__PURE__ */ c(
62
- V,
61
+ O(B);
62
+ }, [o, l, s]);
63
+ const w = (b) => {
64
+ g(b.target.value);
65
+ }, u = () => c ? /* @__PURE__ */ n("div", { className: "gi-select-menu-loading", children: /* @__PURE__ */ n(R, { size: "md" }) }) : S ? /* @__PURE__ */ n("div", { className: "gi-select-menu-option-not-found", children: q("autocomplete.noData") }) : /* @__PURE__ */ n("ul", { children: y });
66
+ return /* @__PURE__ */ N("div", { className: V("gi-select-menu-container", i), children: [
67
+ r && /* @__PURE__ */ n("div", { className: "gi-select-menu-input-container", children: /* @__PURE__ */ n(
68
+ J,
63
69
  {
64
70
  tabIndex: 0,
65
71
  placeholder: "Search",
66
72
  iconEnd: "search",
67
- onChange: O,
68
- value: e
73
+ onChange: w,
74
+ value: l
69
75
  }
70
76
  ) }),
71
- /* @__PURE__ */ c("div", { className: "gi-select-menu-option-container", children: u.length > 0 ? /* @__PURE__ */ c("ul", { children: u }) : /* @__PURE__ */ c("div", { className: "gi-select-menu-option-not-found", children: "No data found." }) })
77
+ /* @__PURE__ */ n("div", { className: "gi-select-menu-option-container", children: u() })
72
78
  ] });
73
- }, B = ({
74
- children: n,
75
- value: s,
76
- selected: l,
79
+ }, U = ({
80
+ children: o,
81
+ value: i,
82
+ selected: s,
77
83
  onChange: r,
78
- disabled: e,
79
- dataTestid: d,
80
- className: u,
84
+ disabled: c,
85
+ dataTestid: m,
86
+ className: l,
81
87
  hidden: g,
82
- enableSearch: O,
83
- isHighlighted: m,
84
- ...S
88
+ enableSearch: S,
89
+ isHighlighted: f,
90
+ ...y
85
91
  }) => {
86
- const i = (a) => {
87
- (a.key === "Enter" || a.key === " ") && (a.preventDefault(), r == null || r(s));
88
- }, y = () => {
89
- e || r == null || r(s);
92
+ const O = (u) => {
93
+ (u.key === "Enter" || u.key === " ") && (u.preventDefault(), r == null || r(i));
94
+ }, w = () => {
95
+ c || r == null || r(i);
90
96
  };
91
- return g ? null : /* @__PURE__ */ h(
97
+ return g ? null : /* @__PURE__ */ N(
92
98
  "li",
93
99
  {
94
100
  role: "option",
95
- tabIndex: e ? -1 : 0,
96
- "aria-selected": l,
97
- "aria-label": n == null ? void 0 : n.toString(),
98
- "aria-disabled": e,
99
- onKeyDown: i,
100
- onClick: y,
101
- className: A(
101
+ tabIndex: c ? -1 : 0,
102
+ "aria-selected": s,
103
+ "aria-label": o == null ? void 0 : o.toString(),
104
+ "aria-disabled": c,
105
+ onKeyDown: O,
106
+ onClick: w,
107
+ className: V(
102
108
  "gi-select-option-item",
103
109
  {
104
- "gi-select-option-item-disabled": e,
105
- "gi-select-option-item-highlighted": m
110
+ "gi-select-option-item-disabled": c,
111
+ "gi-select-option-item-highlighted": f
106
112
  },
107
- u
113
+ l
108
114
  ),
109
- "data-search-enabled": O,
110
- "data-testid": d || `option-${s}`,
111
- ...S,
115
+ "data-search-enabled": S,
116
+ "data-testid": m || `option-${i}`,
117
+ ...y,
112
118
  children: [
113
- /* @__PURE__ */ c("span", { className: "gi-text-sm", children: n }),
114
- l && /* @__PURE__ */ c(P, { icon: "check" })
119
+ /* @__PURE__ */ n("span", { className: "gi-text-sm", children: o }),
120
+ s && /* @__PURE__ */ n(H, { icon: "check" })
115
121
  ]
116
122
  },
117
- `${n}-${s}`
123
+ `${o}-${i}`
118
124
  );
119
125
  };
120
- Object.defineProperty(B, "componentType", {
126
+ Object.defineProperty(U, "componentType", {
121
127
  value: "SelectMenuOption",
122
128
  writable: !1,
123
129
  enumerable: !1
124
130
  });
125
- const F = ({
126
- children: n,
127
- label: s,
128
- ...l
129
- }) => /* @__PURE__ */ h("div", { ...l, role: "group", className: "gi-px-3", children: [
130
- /* @__PURE__ */ c(z, { text: s, size: "sm", className: "gi-font-bold gi-pb-1" }),
131
- n
131
+ const W = ({
132
+ children: o,
133
+ label: i,
134
+ ...s
135
+ }) => /* @__PURE__ */ N("div", { ...s, role: "group", className: "gi-px-3", children: [
136
+ /* @__PURE__ */ n(Q, { text: i, size: "sm", className: "gi-font-bold gi-pb-1" }),
137
+ o
132
138
  ] });
133
- Object.defineProperty(F, "componentType", {
139
+ Object.defineProperty(W, "componentType", {
134
140
  value: "SelectMenuGroupItem",
135
141
  writable: !1,
136
142
  enumerable: !1
137
143
  });
138
144
  export {
139
- W as SelectMenu,
140
- F as SelectMenuGroupItem,
141
- B as SelectMenuOption
145
+ re as SelectMenu,
146
+ W as SelectMenuGroupItem,
147
+ U as SelectMenuOption
142
148
  };
@@ -1,5 +1,8 @@
1
1
  import { FC } from 'react';
2
- import { SelectGroupItemProps, SelectItemProps, SelectProps } from './types.js';
2
+ import { SelectGroupItemProps, SelectItemProps, SelectTableCellProps, SelectProps } from './types.js';
3
3
  export declare const SelectGroupItem: ({ children, ...props }: SelectGroupItemProps) => import("react/jsx-runtime").JSX.Element;
4
4
  export declare const SelectItem: ({ children, ...props }: SelectItemProps) => import("react/jsx-runtime").JSX.Element;
5
- export declare const SelectNative: FC<SelectProps>;
5
+ export declare const SelectNative: FC<SelectProps & {
6
+ containerProps?: any;
7
+ }>;
8
+ export declare const SelectTableCell: ({ options, defaultValue, onChange, error, ...props }: SelectTableCellProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,27 +1,57 @@
1
- import { jsx as c, jsxs as l } from "react/jsx-runtime";
1
+ import { jsx as a, jsxs as d } from "react/jsx-runtime";
2
2
  import { cn as o } from "../cn.js";
3
- import { Icon as r } from "../icon/icon.js";
4
- const m = ({
5
- children: t,
3
+ import { Icon as m } from "../icon/icon.js";
4
+ const b = ({
5
+ children: c,
6
6
  ...e
7
- }) => /* @__PURE__ */ c("optgroup", { ...e, role: "group", children: t }), d = ({ children: t, ...e }) => /* @__PURE__ */ c(
7
+ }) => /* @__PURE__ */ a("optgroup", { ...e, role: "group", children: c }), r = ({ children: c, ...e }) => /* @__PURE__ */ a(
8
8
  "option",
9
9
  {
10
10
  className: o("gi-select-option", e.className),
11
11
  "aria-selected": e.selected ? "true" : "false",
12
12
  ...e,
13
- children: t
13
+ children: c
14
14
  }
15
15
  ), g = ({
16
- children: t,
16
+ children: c,
17
17
  className: e,
18
- ...s
19
- }) => /* @__PURE__ */ l("div", { className: "gi-select-container", children: [
20
- /* @__PURE__ */ c("select", { className: o("gi-select", e), ...s, children: t }),
21
- /* @__PURE__ */ c(r, { className: "gi-select-icon", icon: "keyboard_arrow_down" })
22
- ] });
18
+ containerProps: i,
19
+ ...t
20
+ }) => {
21
+ var l;
22
+ return /* @__PURE__ */ d("div", { className: "gi-select-container", ...i, children: [
23
+ /* @__PURE__ */ a("select", { className: o("gi-select", e), ...t, children: c }),
24
+ /* @__PURE__ */ a(
25
+ m,
26
+ {
27
+ className: "gi-select-icon",
28
+ icon: "keyboard_arrow_down",
29
+ "data-disabled": (l = t == null ? void 0 : t.disabled) == null ? void 0 : l.toString()
30
+ }
31
+ )
32
+ ] });
33
+ }, f = ({
34
+ options: c,
35
+ defaultValue: e,
36
+ onChange: i,
37
+ error: t,
38
+ ...l
39
+ }) => /* @__PURE__ */ a(
40
+ g,
41
+ {
42
+ ...l,
43
+ containerProps: {
44
+ "data-table-cell": "true",
45
+ "data-table-cell-error-state": t == null ? void 0 : t.toString()
46
+ },
47
+ defaultValue: e,
48
+ onChange: i,
49
+ children: c.map(({ value: n, label: s }) => /* @__PURE__ */ a(r, { value: n, children: s }, `${n}-${s}`))
50
+ }
51
+ );
23
52
  export {
24
- m as SelectGroupItem,
25
- d as SelectItem,
26
- g as SelectNative
53
+ b as SelectGroupItem,
54
+ r as SelectItem,
55
+ g as SelectNative,
56
+ f as SelectTableCell
27
57
  };
@@ -1,5 +1,6 @@
1
1
  import { FC } from 'react';
2
- import { SelectNextGroupProps, SelectNextProps, SelectNextOptionProps } from './types.js';
3
- export declare const SelectNext: ({ children, onChange: onSelectNextChange, onMenuClose, defaultValue, enableSearch, disabled, ...props }: SelectNextProps) => import("react/jsx-runtime").JSX.Element;
2
+ import { SelectNextGroupProps, SelectNextProps, SelectNextOptionProps, SelectNextTableCellProps } from './types.js';
3
+ export declare const SelectNext: ({ children, value: controlledValue, defaultValue, onChange: onSelectNextChange, onMenuClose, enableSearch, disabled, ...props }: SelectNextProps) => import("react/jsx-runtime").JSX.Element;
4
4
  export declare const SelectItemNext: FC<SelectNextOptionProps>;
5
5
  export declare const SelectGroupItemNext: FC<SelectNextGroupProps>;
6
+ export declare const SelectNextTableCell: (props: SelectNextTableCellProps) => import("react/jsx-runtime").JSX.Element;