@pismo/marola 1.0.0-beta.29 → 1.0.0-beta.3

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 (127) hide show
  1. package/dist/{Button-BAljjMv3.js → Button-2b1peDFT.js} +2 -2
  2. package/dist/{ClickAwayListener-DbEYZpyh.js → ClickAwayListener-BSW-Nd-y.js} +3 -4
  3. package/dist/Dialog.module-DFEmFdYT.js +30 -0
  4. package/dist/{Popup-Ck3XlWMq.js → Popup-B6ZSGIEI.js} +3 -3
  5. package/dist/{Portal-oY3enyAm.js → Portal-DIeBsWdL.js} +2 -2
  6. package/dist/SelectButton-C8JQKaf4.js +61 -0
  7. package/dist/{Tabs.module-BGGTkDc5.js → Tabs.module-jkH1Qjn7.js} +7 -7
  8. package/dist/Toggle-BCgIItCc.js +142 -0
  9. package/dist/assets/Advice.css +1 -1
  10. package/dist/assets/Button.css +1 -1
  11. package/dist/assets/Checkbox.css +1 -1
  12. package/dist/assets/Dialog.css +1 -1
  13. package/dist/assets/IconButton.css +1 -1
  14. package/dist/assets/Input.css +1 -1
  15. package/dist/assets/PageHeader.css +1 -1
  16. package/dist/assets/Pagination.css +1 -1
  17. package/dist/assets/SelectButton.css +1 -1
  18. package/dist/assets/Snackbar.css +1 -1
  19. package/dist/assets/SortTooltip.css +1 -1
  20. package/dist/assets/Stepper.css +1 -1
  21. package/dist/assets/Table.css +1 -1
  22. package/dist/assets/Tabs.css +1 -1
  23. package/dist/assets/TextDisplay.css +1 -1
  24. package/dist/assets/Toggle.css +1 -1
  25. package/dist/assets/Toggle2.css +1 -1
  26. package/dist/assets/Typography.css +1 -1
  27. package/dist/{combineHooksSlotProps-C-zYvfnF.js → combineHooksSlotProps-DVjg9PRh.js} +1 -1
  28. package/dist/components/Advice/Advice.d.ts +17 -32
  29. package/dist/components/Advice/Advice.js +40 -39
  30. package/dist/components/Advice/Advice.stories.d.ts +3 -4
  31. package/dist/components/Button/Button.d.ts +0 -2
  32. package/dist/components/Button/Button.js +49 -51
  33. package/dist/components/Checkbox/Checkbox.js +52 -52
  34. package/dist/components/Chip/Chip.d.ts +12 -6
  35. package/dist/components/Chip/Chip.js +5 -7
  36. package/dist/components/Chip/Chip.stories.d.ts +14 -5
  37. package/dist/components/Dialog/Actions.js +1 -1
  38. package/dist/components/Dialog/Backdrop.d.ts +3 -3
  39. package/dist/components/Dialog/Backdrop.js +7 -8
  40. package/dist/components/Dialog/CloseIconButton.d.ts +2 -1
  41. package/dist/components/Dialog/CloseIconButton.js +18 -15
  42. package/dist/components/Dialog/Dialog.d.ts +6 -9
  43. package/dist/components/Dialog/Dialog.js +139 -139
  44. package/dist/components/Dialog/Dialog.stories.d.ts +46 -50
  45. package/dist/components/Dialog/DialogTitle.js +1 -1
  46. package/dist/components/EllipsisTooltip/EllipsisTooltip.js +17 -30
  47. package/dist/components/EllipsisTooltip/EllipsisTooltip.stories.d.ts +1 -2
  48. package/dist/components/Icon/Icon.js +47 -93
  49. package/dist/components/Icon/types.d.ts +1 -1
  50. package/dist/components/IconButton/IconButton.js +42 -42
  51. package/dist/components/Input/Input.d.ts +5 -50
  52. package/dist/components/Input/Input.js +239 -243
  53. package/dist/components/Input/Input.stories.d.ts +3 -4
  54. package/dist/components/InputSearch/InputSearch.stories.d.ts +2 -3
  55. package/dist/components/PageHeader/PageHeader.js +57 -57
  56. package/dist/components/Pagination/Pagination.d.ts +1 -5
  57. package/dist/components/Pagination/Pagination.js +185 -87
  58. package/dist/components/Pagination/Pagination.stories.d.ts +1 -1
  59. package/dist/components/Select/Select.d.ts +0 -7
  60. package/dist/components/Select/Select.js +365 -409
  61. package/dist/components/Select/SelectButton.d.ts +0 -1
  62. package/dist/components/Select/SelectButton.js +1 -1
  63. package/dist/components/Skeleton/Skeleton.d.ts +1 -3
  64. package/dist/components/Skeleton/Skeleton.js +12 -18
  65. package/dist/components/Skeleton/SkeletonTable.stories.d.ts +1 -1
  66. package/dist/components/Snackbar/Snackbar.js +94 -94
  67. package/dist/components/Snackbar/Snackbar.stories.d.ts +3 -3
  68. package/dist/components/SortTooltip/SortTooltip.js +46 -46
  69. package/dist/components/Stepper/Stepper.js +35 -35
  70. package/dist/components/Table/Table.d.ts +1 -3
  71. package/dist/components/Table/Table.js +85 -88
  72. package/dist/components/Table/Table.stories.d.ts +1 -1
  73. package/dist/components/Tabs/Tab.d.ts +3 -5
  74. package/dist/components/Tabs/Tab.js +36 -38
  75. package/dist/components/Tabs/TabPanel.d.ts +2 -4
  76. package/dist/components/Tabs/TabPanel.js +40 -51
  77. package/dist/components/Tabs/Tabs.d.ts +4 -6
  78. package/dist/components/Tabs/Tabs.js +128 -131
  79. package/dist/components/TextDisplay/TextDisplay.d.ts +3 -9
  80. package/dist/components/TextDisplay/TextDisplay.js +31 -45
  81. package/dist/components/TextDisplay/TextDisplay.stories.d.ts +1 -2
  82. package/dist/components/Toggle/Toggle.js +56 -56
  83. package/dist/components/ToggleGroup/Toggle.js +4 -5
  84. package/dist/components/ToggleGroup/ToggleGroup.js +1 -1
  85. package/dist/components/Tooltip/Tooltip.d.ts +1 -3
  86. package/dist/components/Tooltip/Tooltip.js +4 -4
  87. package/dist/components/Tooltip/Tooltip.stories.d.ts +0 -1
  88. package/dist/components/Typography/Typography.js +47 -47
  89. package/dist/{useSlotProps-C_I1kEHr.js → index-CH45lKw7.js} +99 -99
  90. package/dist/{index-bQFToy-I.js → index-CjW42-M-.js} +1 -1
  91. package/dist/main.d.ts +0 -5
  92. package/dist/main.js +76 -85
  93. package/dist/{useButton-DcihopJG.js → useButton-DNk3wrQp.js} +1 -1
  94. package/dist/useCompoundItem-D1iRfg8D.js +84 -0
  95. package/dist/useEventCallback-xTG9piMa.js +45 -0
  96. package/dist/{useList-B9C55YB7.js → useList-B0hog_3-.js} +2 -2
  97. package/package.json +2 -8
  98. package/dist/Dialog.module-D9e4RsKo.js +0 -30
  99. package/dist/SelectButton-BlVl6pJn.js +0 -70
  100. package/dist/Toggle-Buew6bzm.js +0 -182
  101. package/dist/assets/Adornment.css +0 -1
  102. package/dist/assets/Autocomplete.css +0 -1
  103. package/dist/assets/ResultWithChips.css +0 -1
  104. package/dist/assets/StepperNavigator.css +0 -1
  105. package/dist/components/Adornment/Adornment.d.ts +0 -20
  106. package/dist/components/Adornment/Adornment.js +0 -13
  107. package/dist/components/Adornment/Adornment.stories.d.ts +0 -14
  108. package/dist/components/Adornment/adornment.test.d.ts +0 -1
  109. package/dist/components/Autocomplete/Autocomplete.d.ts +0 -20
  110. package/dist/components/Autocomplete/Autocomplete.js +0 -679
  111. package/dist/components/Autocomplete/Autocomplete.stories.d.ts +0 -23
  112. package/dist/components/Pagination/usePagination.d.ts +0 -90
  113. package/dist/components/Pagination/usePagination.js +0 -79
  114. package/dist/components/ResultWithChips/ResultWithChips.d.ts +0 -12
  115. package/dist/components/ResultWithChips/ResultWithChips.js +0 -33
  116. package/dist/components/RowItem/RowItem.d.ts +0 -25
  117. package/dist/components/RowItem/RowItem.js +0 -20
  118. package/dist/components/RowItem/RowItem.stories.d.ts +0 -17
  119. package/dist/components/RowItem/rowItem.test.d.ts +0 -1
  120. package/dist/components/StepperNavigator/StepperNavigator.d.ts +0 -43
  121. package/dist/components/StepperNavigator/StepperNavigator.js +0 -56
  122. package/dist/components/StepperNavigator/StepperNavigator.stories.d.ts +0 -16
  123. package/dist/components/StepperNavigator/StepperNavigator.test.d.ts +0 -1
  124. package/dist/ownerDocument-YGhwAnr1.js +0 -33
  125. package/dist/useCompoundItem-B7Eo_qZk.js +0 -68
  126. package/dist/useEventCallback-BAQJJ3ye.js +0 -14
  127. package/dist/useId-BW-oWmul.js +0 -19
@@ -1,58 +1,58 @@
1
1
  import '../../assets/Input.css';
2
- import { jsxs as H, jsx as T } from "react/jsx-runtime";
3
- import * as f from "react";
4
- import { forwardRef as de, useState as ce, useId as _e } from "react";
5
- import { c as E } from "../../clsx-DB4S2d7J.js";
2
+ import { jsxs as q, jsx as B } from "react/jsx-runtime";
3
+ import * as h from "react";
4
+ import { useState as de, useId as ce } from "react";
5
+ import { c as R } from "../../clsx-DB4S2d7J.js";
6
6
  import { Typography as L } from "../Typography/Typography.js";
7
- import { g as he, a as fe, u as me, f as z, b as m, _ as ye, c as Q, i as ge, P as e, d as be, e as Ce } from "../../useSlotProps-C_I1kEHr.js";
8
- function we(a) {
9
- let s = "https://mui.com/production-error/?code=" + a;
10
- for (let u = 1; u < arguments.length; u += 1)
11
- s += "&args[]=" + encodeURIComponent(arguments[u]);
12
- return "Minified MUI error #" + a + "; visit " + s + " for the full message.";
13
- }
14
- const X = "Input";
7
+ import { g as _e, a as he, u as me, f as z, b as m, _ as fe, c as Q, i as be, P as e, d as ye, e as ge } from "../../index-CH45lKw7.js";
15
8
  function ve(a) {
16
- return he(X, a);
9
+ let l = "https://mui.com/production-error/?code=" + a;
10
+ for (let s = 1; s < arguments.length; s += 1)
11
+ l += "&args[]=" + encodeURIComponent(arguments[s]);
12
+ return "Minified MUI error #" + a + "; visit " + l + " for the full message.";
13
+ }
14
+ const X = /* @__PURE__ */ h.createContext(void 0);
15
+ process.env.NODE_ENV !== "production" && (X.displayName = "FormControlContext");
16
+ function Ce() {
17
+ return h.useContext(X);
17
18
  }
18
- fe(X, ["root", "formControl", "focused", "disabled", "error", "multiline", "input", "inputMultiline", "inputTypeSearch", "adornedStart", "adornedEnd"]);
19
- const Z = /* @__PURE__ */ f.createContext(void 0);
20
- process.env.NODE_ENV !== "production" && (Z.displayName = "FormControlContext");
21
- function xe() {
22
- return f.useContext(Z);
19
+ const Z = "Input";
20
+ function we(a) {
21
+ return _e(Z, a);
23
22
  }
24
- function qe(a = {}) {
23
+ he(Z, ["root", "formControl", "focused", "disabled", "error", "multiline", "input", "inputMultiline", "inputTypeSearch", "adornedStart", "adornedEnd"]);
24
+ function ke(a = {}) {
25
25
  const {
26
- defaultValue: s,
27
- disabled: u = !1,
28
- error: i = !1,
29
- onBlur: p,
30
- onChange: _,
26
+ defaultValue: l,
27
+ disabled: s = !1,
28
+ error: f = !1,
29
+ onBlur: i,
30
+ onChange: b,
31
31
  onFocus: x,
32
- required: q = !1,
33
- value: R,
34
- inputRef: N
35
- } = a, o = xe();
36
- let g, h, b, C, y;
32
+ required: N = !1,
33
+ value: g,
34
+ inputRef: V
35
+ } = a, o = Ce();
36
+ let P, _, v, C, y;
37
37
  if (o) {
38
- var F, d, I;
39
- if (g = void 0, h = (F = o.disabled) != null ? F : !1, b = (d = o.error) != null ? d : !1, C = (I = o.required) != null ? I : !1, y = o.value, process.env.NODE_ENV !== "production") {
38
+ var F, p, I;
39
+ if (P = void 0, _ = (F = o.disabled) != null ? F : !1, v = (p = o.error) != null ? p : !1, C = (I = o.required) != null ? I : !1, y = o.value, process.env.NODE_ENV !== "production") {
40
40
  const t = ["defaultValue", "disabled", "error", "required", "value"].filter((r) => a[r] !== void 0);
41
41
  t.length > 0 && console.warn(["MUI: You have set props on an input that is inside a FormControl.", "Set these props on a FormControl instead. Otherwise they will be ignored.", `Ignored props: ${t.join(", ")}`].join(`
42
42
  `));
43
43
  }
44
44
  } else
45
- g = s, h = u, b = i, C = q, y = R;
45
+ P = l, _ = s, v = f, C = N, y = g;
46
46
  const {
47
- current: S
48
- } = f.useRef(y != null), k = f.useCallback((t) => {
47
+ current: U
48
+ } = h.useRef(y != null), M = h.useCallback((t) => {
49
49
  process.env.NODE_ENV !== "production" && t && t.nodeName !== "INPUT" && !t.focus && console.error(["MUI: You have provided a `slots.input` to the input component", "that does not correctly handle the `ref` prop.", "Make sure the `ref` prop is called with a HTMLInputElement."].join(`
50
50
  `));
51
- }, []), w = f.useRef(null), O = me(w, N, k), [P, v] = f.useState(!1);
52
- f.useEffect(() => {
53
- !o && h && P && (v(!1), p == null || p());
54
- }, [o, h, P, p]);
55
- const B = (t) => (r) => {
51
+ }, []), w = h.useRef(null), O = me(w, V, M), [k, E] = h.useState(!1);
52
+ h.useEffect(() => {
53
+ !o && _ && k && (E(!1), i == null || i());
54
+ }, [o, _, k, i]);
55
+ const A = (t) => (r) => {
56
56
  var n;
57
57
  if (o != null && o.disabled) {
58
58
  r.stopPropagation();
@@ -62,40 +62,40 @@ function qe(a = {}) {
62
62
  var c;
63
63
  o == null || (c = o.onFocus) == null || c.call(o);
64
64
  } else
65
- v(!0);
66
- }, V = (t) => (r) => {
65
+ E(!0);
66
+ }, D = (t) => (r) => {
67
67
  var n;
68
- (n = t.onBlur) == null || n.call(t, r), o && o.onBlur ? o.onBlur() : v(!1);
69
- }, U = (t) => (r, ...n) => {
70
- var c, j;
71
- if (!S && (r.target || w.current) == null)
72
- throw new Error(process.env.NODE_ENV !== "production" ? "MUI: Expected valid input target. Did you use a custom `slots.input` and forget to forward refs? See https://mui.com/r/input-component-ref-interface for more info." : we(17));
73
- o == null || (c = o.onChange) == null || c.call(o, r), (j = t.onChange) == null || j.call(t, r, ...n);
74
- }, M = (t) => (r) => {
68
+ (n = t.onBlur) == null || n.call(t, r), o && o.onBlur ? o.onBlur() : E(!1);
69
+ }, T = (t) => (r, ...n) => {
70
+ var c, H;
71
+ if (!U && (r.target || w.current) == null)
72
+ throw new Error(process.env.NODE_ENV !== "production" ? "MUI: Expected valid input target. Did you use a custom `slots.input` and forget to forward refs? See https://mui.com/r/input-component-ref-interface for more info." : ve(17));
73
+ o == null || (c = o.onChange) == null || c.call(o, r), (H = t.onChange) == null || H.call(t, r, ...n);
74
+ }, j = (t) => (r) => {
75
75
  var n;
76
76
  w.current && r.currentTarget === r.target && w.current.focus(), (n = t.onClick) == null || n.call(t, r);
77
77
  };
78
78
  return {
79
- disabled: h,
80
- error: b,
81
- focused: P,
79
+ disabled: _,
80
+ error: v,
81
+ focused: k,
82
82
  formControlContext: o,
83
83
  getInputProps: (t = {}) => {
84
84
  const n = m({}, {
85
- onBlur: p,
86
- onChange: _,
85
+ onBlur: i,
86
+ onChange: b,
87
87
  onFocus: x
88
88
  }, z(t)), c = m({}, n, {
89
- onBlur: V(n),
90
- onChange: U(n),
91
- onFocus: B(n)
89
+ onBlur: D(n),
90
+ onChange: T(n),
91
+ onFocus: A(n)
92
92
  });
93
93
  return m({}, c, {
94
- "aria-invalid": b || void 0,
95
- defaultValue: g,
94
+ "aria-invalid": v || void 0,
95
+ defaultValue: P,
96
96
  value: y,
97
97
  required: C,
98
- disabled: h
98
+ disabled: _
99
99
  }, t, {
100
100
  ref: O
101
101
  }, c);
@@ -103,7 +103,7 @@ function qe(a = {}) {
103
103
  getRootProps: (t = {}) => {
104
104
  const r = z(a, ["onBlur", "onChange", "onFocus"]), n = m({}, r, z(t));
105
105
  return m({}, t, n, {
106
- onClick: M(n)
106
+ onClick: j(n)
107
107
  });
108
108
  },
109
109
  inputRef: O,
@@ -111,115 +111,115 @@ function qe(a = {}) {
111
111
  value: y
112
112
  };
113
113
  }
114
- const Ne = ["aria-describedby", "aria-label", "aria-labelledby", "autoComplete", "autoFocus", "className", "defaultValue", "disabled", "endAdornment", "error", "id", "multiline", "name", "onClick", "onChange", "onKeyDown", "onKeyUp", "onFocus", "onBlur", "placeholder", "readOnly", "required", "startAdornment", "value", "type", "rows", "slotProps", "slots", "minRows", "maxRows"], Pe = (a) => {
114
+ const xe = ["aria-describedby", "aria-label", "aria-labelledby", "autoComplete", "autoFocus", "className", "defaultValue", "disabled", "endAdornment", "error", "id", "multiline", "name", "onClick", "onChange", "onKeyDown", "onKeyUp", "onFocus", "onBlur", "placeholder", "readOnly", "required", "startAdornment", "value", "type", "rows", "slotProps", "slots", "minRows", "maxRows"], Ne = (a) => {
115
115
  const {
116
- disabled: s,
117
- error: u,
118
- focused: i,
119
- formControlContext: p,
120
- multiline: _,
116
+ disabled: l,
117
+ error: s,
118
+ focused: f,
119
+ formControlContext: i,
120
+ multiline: b,
121
121
  startAdornment: x,
122
- endAdornment: q
122
+ endAdornment: N
123
123
  } = a;
124
- return be({
125
- root: ["root", s && "disabled", u && "error", i && "focused", !!p && "formControl", _ && "multiline", !!x && "adornedStart", !!q && "adornedEnd"],
126
- input: ["input", s && "disabled", _ && "multiline"]
127
- }, Ce(ve));
128
- }, ee = /* @__PURE__ */ f.forwardRef(function(s, u) {
129
- var i, p, _;
124
+ return ye({
125
+ root: ["root", l && "disabled", s && "error", f && "focused", !!i && "formControl", b && "multiline", !!x && "adornedStart", !!N && "adornedEnd"],
126
+ input: ["input", l && "disabled", b && "multiline"]
127
+ }, ge(we));
128
+ }, ee = /* @__PURE__ */ h.forwardRef(function(l, s) {
129
+ var f, i, b;
130
130
  const {
131
131
  "aria-describedby": x,
132
- "aria-label": q,
133
- "aria-labelledby": R,
134
- autoComplete: N,
132
+ "aria-label": N,
133
+ "aria-labelledby": g,
134
+ autoComplete: V,
135
135
  autoFocus: o,
136
- className: g,
137
- defaultValue: h,
138
- disabled: b,
136
+ className: P,
137
+ defaultValue: _,
138
+ disabled: v,
139
139
  endAdornment: C,
140
140
  error: y,
141
141
  id: F,
142
- multiline: d = !1,
142
+ multiline: p = !1,
143
143
  name: I,
144
- onClick: S,
145
- onChange: k,
144
+ onClick: U,
145
+ onChange: M,
146
146
  onKeyDown: w,
147
147
  onKeyUp: O,
148
- onFocus: P,
149
- onBlur: v,
150
- placeholder: B,
151
- readOnly: V,
152
- required: U,
153
- startAdornment: M,
154
- value: A,
155
- type: D,
148
+ onFocus: k,
149
+ onBlur: E,
150
+ placeholder: A,
151
+ readOnly: D,
152
+ required: T,
153
+ startAdornment: j,
154
+ value: d,
155
+ type: S,
156
156
  rows: t,
157
157
  slotProps: r = {},
158
158
  slots: n = {},
159
159
  minRows: c,
160
- maxRows: j
161
- } = s, Y = ye(s, Ne), {
160
+ maxRows: H
161
+ } = l, Y = fe(l, xe), {
162
162
  getRootProps: te,
163
163
  getInputProps: oe,
164
164
  focused: ne,
165
165
  formControlContext: re,
166
166
  error: ae,
167
167
  disabled: se
168
- } = qe({
169
- disabled: b,
170
- defaultValue: h,
168
+ } = ke({
169
+ disabled: v,
170
+ defaultValue: _,
171
171
  error: y,
172
- onBlur: v,
173
- onClick: S,
174
- onChange: k,
175
- onFocus: P,
176
- required: U,
177
- value: A
178
- }), W = d ? void 0 : D ?? "text", $ = m({}, s, {
172
+ onBlur: E,
173
+ onClick: U,
174
+ onChange: M,
175
+ onFocus: k,
176
+ required: T,
177
+ value: d
178
+ }), W = p ? void 0 : S ?? "text", $ = m({}, l, {
179
179
  disabled: se,
180
180
  error: ae,
181
181
  focused: ne,
182
182
  formControlContext: re,
183
- multiline: d,
183
+ multiline: p,
184
184
  type: W
185
- }), G = Pe($), le = {
185
+ }), G = Ne($), le = {
186
186
  "aria-describedby": x,
187
- "aria-label": q,
188
- "aria-labelledby": R,
189
- autoComplete: N,
187
+ "aria-label": N,
188
+ "aria-labelledby": g,
189
+ autoComplete: V,
190
190
  autoFocus: o,
191
191
  id: F,
192
192
  onKeyDown: w,
193
193
  onKeyUp: O,
194
194
  name: I,
195
- placeholder: B,
196
- readOnly: V,
195
+ placeholder: A,
196
+ readOnly: D,
197
197
  type: W
198
- }, J = (i = n.root) != null ? i : "div", ue = Q({
198
+ }, J = (f = n.root) != null ? f : "div", ue = Q({
199
199
  elementType: J,
200
200
  getSlotProps: te,
201
201
  externalSlotProps: r.root,
202
202
  externalForwardedProps: Y,
203
203
  additionalProps: {
204
- ref: u
204
+ ref: s
205
205
  },
206
206
  ownerState: $,
207
- className: [G.root, g]
208
- }), K = d ? (p = n.textarea) != null ? p : "textarea" : (_ = n.input) != null ? _ : "input", ie = Q({
207
+ className: [G.root, P]
208
+ }), K = p ? (i = n.textarea) != null ? i : "textarea" : (b = n.input) != null ? b : "input", ie = Q({
209
209
  elementType: K,
210
210
  getSlotProps: (pe) => oe(m({}, le, pe)),
211
211
  externalSlotProps: r.input,
212
212
  additionalProps: m({
213
- rows: d ? t : void 0
214
- }, d && !ge(K) && {
213
+ rows: p ? t : void 0
214
+ }, p && !be(K) && {
215
215
  minRows: t || c,
216
- maxRows: t || j
216
+ maxRows: t || H
217
217
  }),
218
218
  ownerState: $,
219
219
  className: G.input
220
220
  });
221
- return process.env.NODE_ENV !== "production" && d && t && (c || j) && console.warn("MUI: You can not use the `minRows` or `maxRows` props when the input `rows` prop is set."), /* @__PURE__ */ H(J, m({}, ue, {
222
- children: [M, /* @__PURE__ */ T(K, m({}, ie)), C]
221
+ return process.env.NODE_ENV !== "production" && p && t && (c || H) && console.warn("MUI: You can not use the `minRows` or `maxRows` props when the input `rows` prop is set."), /* @__PURE__ */ q(J, m({}, ue, {
222
+ children: [j, /* @__PURE__ */ B(K, m({}, ie)), C]
223
223
  }));
224
224
  });
225
225
  process.env.NODE_ENV !== "production" && (ee.propTypes = {
@@ -372,141 +372,137 @@ process.env.NODE_ENV !== "production" && (ee.propTypes = {
372
372
  */
373
373
  value: e.any
374
374
  });
375
- const Ee = (a) => /* @__PURE__ */ f.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", "data-waves-icon": "fa/solid/circle-exclamation", fill: "currentColor", color: "currentColor", width: "1em", height: "1em", style: {
375
+ const Pe = (a) => /* @__PURE__ */ h.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", "data-waves-icon": "fa/solid/circle-exclamation", fill: "currentColor", color: "currentColor", width: "1em", height: "1em", style: {
376
376
  fill: "currentcolor",
377
377
  color: "currentcolor",
378
378
  width: "1em",
379
379
  height: "1em"
380
- }, ...a }, /* @__PURE__ */ f.createElement("path", { d: "M256 0C114.6 0 0 114.6 0 256s114.6 256 256 256s256-114.6 256-256S397.4 0 256 0zM232 152C232 138.8 242.8 128 256 128s24 10.75 24 24v128c0 13.25-10.75 24-24 24S232 293.3 232 280V152zM256 400c-17.36 0-31.44-14.08-31.44-31.44c0-17.36 14.07-31.44 31.44-31.44s31.44 14.08 31.44 31.44C287.4 385.9 273.4 400 256 400z" })), Re = "_input__label_1lq2e_78", Fe = "_input_1lq2e_57", l = {
381
- "u-typography-h1": "_u-typography-h1_1lq2e_1",
382
- "u-typography-h2": "_u-typography-h2_1lq2e_8",
383
- "u-typography-h3": "_u-typography-h3_1lq2e_15",
384
- "u-typography-h4": "_u-typography-h4_1lq2e_22",
385
- "u-typography-h5": "_u-typography-h5_1lq2e_29",
386
- "u-typography-h6": "_u-typography-h6_1lq2e_36",
387
- "u-typography-base": "_u-typography-base_1lq2e_43",
388
- "u-typography-base--xxl": "_u-typography-base--xxl_1lq2e_49",
389
- "u-typography-base--xl": "_u-typography-base--xl_1lq2e_53",
390
- "u-typography-base--lg": "_u-typography-base--lg_1lq2e_57",
391
- "input__input-el": "_input__input-el_1lq2e_57",
392
- "u-typography-base--sm": "_u-typography-base--sm_1lq2e_61",
393
- "u-typography-base--bold": "_u-typography-base--bold_1lq2e_65",
394
- "u-typography-base--strikethrough": "_u-typography-base--strikethrough_1lq2e_68",
395
- "u-typography-base--underlined": "_u-typography-base--underlined_1lq2e_71",
396
- "u-typography-base--strikethrough-underlined": "_u-typography-base--strikethrough-underlined_1lq2e_74",
397
- input__label: Re,
398
- "input__input-el-wrapper": "_input__input-el-wrapper_1lq2e_83",
399
- "input__left-icon": "_input__left-icon_1lq2e_101",
400
- "input__right-icon": "_input__right-icon_1lq2e_101",
401
- "input__messages-wrapper": "_input__messages-wrapper_1lq2e_113",
402
- "input__info-message": "_input__info-message_1lq2e_121",
403
- "input__error-message": "_input__error-message_1lq2e_121",
404
- "input__chars-counter": "_input__chars-counter_1lq2e_132",
405
- "input--disabled": "_input--disabled_1lq2e_136",
406
- input: Fe,
407
- "input--focused": "_input--focused_1lq2e_142",
408
- "input--error": "_input--error_1lq2e_145"
409
- }, Be = de(
410
- ({
411
- label: a,
412
- infoMessage: s,
413
- error: u,
414
- errorMessage: i,
415
- leftIcon: p,
416
- rightIcon: _,
417
- id: x,
418
- disabled: q,
419
- type: R = "text",
420
- maxLength: N,
421
- hideCharsCounter: o = !1,
422
- onChange: g,
423
- classNameWrapper: h,
424
- classNameLabel: b,
425
- classNameInput: C,
426
- classNameInfoMessage: y,
427
- classNameErrorMessage: F,
428
- classNameCharsCounter: d,
429
- "data-testid-wrapper": I,
430
- "data-testid-label": S,
431
- "data-testid-input": k,
432
- "data-testid-infoMessage": w,
433
- "data-testid-errorMessage": O,
434
- "data-testid-charsCounter": P,
435
- ...v
436
- }, B) => {
437
- const [V, U] = ce(0), M = _e(), A = x || `input_${M}`;
438
- Object.assign(v, { "data-testid": k });
439
- const D = (t) => {
440
- var r, n;
441
- U((n = (r = t == null ? void 0 : t.target) == null ? void 0 : r.value) == null ? void 0 : n.length), g && g(t);
442
- };
443
- return /* @__PURE__ */ H("div", { className: E(l.input, h), "data-testid": I, children: [
444
- a && /* @__PURE__ */ T(
380
+ }, ...a }, /* @__PURE__ */ h.createElement("path", { d: "M256 0C114.6 0 0 114.6 0 256s114.6 256 256 256s256-114.6 256-256S397.4 0 256 0zM232 152C232 138.8 242.8 128 256 128s24 10.75 24 24v128c0 13.25-10.75 24-24 24S232 293.3 232 280V152zM256 400c-17.36 0-31.44-14.08-31.44-31.44c0-17.36 14.07-31.44 31.44-31.44s31.44 14.08 31.44 31.44C287.4 385.9 273.4 400 256 400z" })), Ee = "_input__label_19vkb_77", Re = "_input_19vkb_56", u = {
381
+ "u-typography-h1": "_u-typography-h1_19vkb_1",
382
+ "u-typography-h2": "_u-typography-h2_19vkb_8",
383
+ "u-typography-h3": "_u-typography-h3_19vkb_15",
384
+ "u-typography-h4": "_u-typography-h4_19vkb_22",
385
+ "u-typography-h5": "_u-typography-h5_19vkb_29",
386
+ "u-typography-h6": "_u-typography-h6_19vkb_36",
387
+ "u-typography-base": "_u-typography-base_19vkb_43",
388
+ "u-typography-base--xxl": "_u-typography-base--xxl_19vkb_48",
389
+ "u-typography-base--xl": "_u-typography-base--xl_19vkb_52",
390
+ "u-typography-base--lg": "_u-typography-base--lg_19vkb_56",
391
+ "input__input-el": "_input__input-el_19vkb_56",
392
+ "u-typography-base--sm": "_u-typography-base--sm_19vkb_60",
393
+ "u-typography-base--bold": "_u-typography-base--bold_19vkb_64",
394
+ "u-typography-base--strikethrough": "_u-typography-base--strikethrough_19vkb_67",
395
+ "u-typography-base--underlined": "_u-typography-base--underlined_19vkb_70",
396
+ "u-typography-base--strikethrough-underlined": "_u-typography-base--strikethrough-underlined_19vkb_73",
397
+ input__label: Ee,
398
+ "input__input-el-wrapper": "_input__input-el-wrapper_19vkb_82",
399
+ "input__left-icon": "_input__left-icon_19vkb_100",
400
+ "input__right-icon": "_input__right-icon_19vkb_100",
401
+ "input__messages-wrapper": "_input__messages-wrapper_19vkb_112",
402
+ "input__info-message": "_input__info-message_19vkb_120",
403
+ "input__error-message": "_input__error-message_19vkb_120",
404
+ "input__chars-counter": "_input__chars-counter_19vkb_131",
405
+ "input--disabled": "_input--disabled_19vkb_135",
406
+ input: Re,
407
+ "input--focused": "_input--focused_19vkb_141",
408
+ "input--error": "_input--error_19vkb_144"
409
+ }, Be = ({
410
+ label: a,
411
+ infoMessage: l,
412
+ errorMessage: s,
413
+ leftIcon: f,
414
+ rightIcon: i,
415
+ id: b,
416
+ disabled: x,
417
+ type: N = "text",
418
+ maxLength: g,
419
+ hideCharsCounter: V = !1,
420
+ onChange: o,
421
+ classNameWrapper: P,
422
+ classNameLabel: _,
423
+ classNameInput: v,
424
+ classNameInfoMessage: C,
425
+ classNameErrorMessage: y,
426
+ classNameCharsCounter: F,
427
+ "data-testid-wrapper": p,
428
+ "data-testid-label": I,
429
+ "data-testid-input": U,
430
+ "data-testid-infoMessage": M,
431
+ "data-testid-errorMessage": w,
432
+ "data-testid-charsCounter": O,
433
+ ...k
434
+ }) => {
435
+ const [E, A] = de(0), D = ce(), T = b || `input_${D}`;
436
+ Object.assign(k, { "data-testid": U });
437
+ const j = (d) => {
438
+ var S, t;
439
+ A((t = (S = d == null ? void 0 : d.target) == null ? void 0 : S.value) == null ? void 0 : t.length), o && o(d);
440
+ };
441
+ return /* @__PURE__ */ q("div", { className: R(u.input, P), "data-testid": p, children: [
442
+ a && /* @__PURE__ */ B(
443
+ L,
444
+ {
445
+ element: "label",
446
+ elementProps: { htmlFor: T },
447
+ className: R(u.input__label, _),
448
+ "data-testid": I,
449
+ children: a
450
+ }
451
+ ),
452
+ /* @__PURE__ */ B(
453
+ ee,
454
+ {
455
+ id: T,
456
+ type: N,
457
+ disabled: x,
458
+ error: !!s,
459
+ "aria-label": a,
460
+ slotProps: {
461
+ root: (d) => ({
462
+ className: R(u["input__input-el-wrapper"], {
463
+ [u["input--disabled"]]: d.disabled,
464
+ [u["input--focused"]]: d.focused,
465
+ [u["input--error"]]: d.error
466
+ })
467
+ }),
468
+ input: {
469
+ className: R(u["input__input-el"], v),
470
+ maxLength: g,
471
+ onChange: j,
472
+ ...k
473
+ }
474
+ },
475
+ startAdornment: f && /* @__PURE__ */ B("span", { className: u["input__left-icon"], children: f }),
476
+ endAdornment: i && /* @__PURE__ */ B("span", { className: u["input__right-icon"], children: i })
477
+ }
478
+ ),
479
+ /* @__PURE__ */ q("div", { className: u["input__messages-wrapper"], children: [
480
+ (s || l) && /* @__PURE__ */ q(
445
481
  L,
446
482
  {
447
- element: "label",
448
- elementProps: { htmlFor: A },
449
- className: E(l.input__label, b),
450
- "data-testid": S,
451
- children: a
483
+ className: s ? R(u["input__error-message"], y) : R(u["input__info-message"], C),
484
+ "data-testid": s ? w : M,
485
+ children: [
486
+ /* @__PURE__ */ B(Pe, {}),
487
+ s || l
488
+ ]
452
489
  }
453
490
  ),
454
- /* @__PURE__ */ T(
455
- ee,
491
+ g && !V && /* @__PURE__ */ q(
492
+ L,
456
493
  {
457
- id: A,
458
- type: R,
459
- disabled: q,
460
- error: typeof u == "boolean" ? u : !!i,
461
- "aria-label": a,
462
- slotProps: {
463
- root: (t) => ({
464
- className: E(l["input__input-el-wrapper"], {
465
- [l["input--disabled"]]: t.disabled,
466
- [l["input--focused"]]: t.focused,
467
- [l["input--error"]]: t.error
468
- })
469
- }),
470
- input: {
471
- ref: B,
472
- className: E(l["input__input-el"], C),
473
- maxLength: N,
474
- onChange: D,
475
- ...v
476
- }
477
- },
478
- startAdornment: p && /* @__PURE__ */ T("span", { className: l["input__left-icon"], children: p }),
479
- endAdornment: _ && /* @__PURE__ */ T("span", { className: l["input__right-icon"], children: _ })
494
+ className: R(u["input__chars-counter"], F),
495
+ "data-testid": O,
496
+ children: [
497
+ E,
498
+ " / ",
499
+ g
500
+ ]
480
501
  }
481
- ),
482
- /* @__PURE__ */ H("div", { className: l["input__messages-wrapper"], children: [
483
- (i || s) && /* @__PURE__ */ H(
484
- L,
485
- {
486
- className: i ? E(l["input__error-message"], F) : E(l["input__info-message"], y),
487
- "data-testid": i ? O : w,
488
- children: [
489
- /* @__PURE__ */ T(Ee, {}),
490
- i || s
491
- ]
492
- }
493
- ),
494
- N && !o && /* @__PURE__ */ H(
495
- L,
496
- {
497
- className: E(l["input__chars-counter"], d),
498
- "data-testid": P,
499
- children: [
500
- V,
501
- " / ",
502
- N
503
- ]
504
- }
505
- )
506
- ] })
507
- ] });
508
- }
509
- );
502
+ )
503
+ ] })
504
+ ] });
505
+ };
510
506
  export {
511
507
  Be as Input
512
508
  };
@@ -2,14 +2,13 @@ import { StoryObj } from '@storybook/react';
2
2
 
3
3
  declare const meta: {
4
4
  title: string;
5
- component: import('react').ForwardRefExoticComponent<import('react').InputHTMLAttributes<HTMLInputElement> & {
5
+ component: ({ label, infoMessage, errorMessage, leftIcon, rightIcon, id, disabled, type, maxLength, hideCharsCounter, onChange, classNameWrapper, classNameLabel, classNameInput, classNameInfoMessage, classNameErrorMessage, classNameCharsCounter, "data-testid-wrapper": testIdWrapper, "data-testid-label": testIdLabel, "data-testid-input": testIdInput, "data-testid-infoMessage": testIdInfoMessage, "data-testid-errorMessage": testIdErrorMessage, "data-testid-charsCounter": testIdCharsCounter, ...rest }: import('react').InputHTMLAttributes<HTMLInputElement> & {
6
6
  label?: string | undefined;
7
7
  infoMessage?: string | undefined;
8
- error?: boolean | undefined;
9
8
  errorMessage?: string | undefined;
10
9
  leftIcon?: import('react').ReactNode;
11
10
  rightIcon?: import('react').ReactNode;
12
- type?: ("number" | "url" | "file" | "color" | "search" | (string & {}) | "button" | "time" | "image" | "text" | "reset" | "tel" | "email" | "date" | "hidden" | "range" | "datetime-local" | "month" | "password" | "week") | undefined;
11
+ type?: "search" | "text" | "password" | undefined;
13
12
  hideCharsCounter?: boolean | undefined;
14
13
  classNameWrapper?: string | undefined;
15
14
  classNameLabel?: string | undefined;
@@ -23,7 +22,7 @@ declare const meta: {
23
22
  'data-testid-infoMessage'?: string | undefined;
24
23
  'data-testid-errorMessage'?: string | undefined;
25
24
  'data-testid-charsCounter'?: string | undefined;
26
- } & import('react').RefAttributes<HTMLInputElement>>;
25
+ }) => import("react/jsx-runtime").JSX.Element;
27
26
  tags: string[];
28
27
  parameters: {
29
28
  layout: string;