@pittorica/select-react 0.23.1 → 0.23.2

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.
package/dist/Select.d.ts CHANGED
@@ -8,17 +8,28 @@ export interface SelectRootProps extends BoxProps {
8
8
  error?: boolean;
9
9
  color?: PittoricaColor;
10
10
  disabled?: boolean;
11
+ name?: string;
11
12
  /** @default 'sm' */
12
13
  size?: SelectSize;
13
14
  }
14
- export declare const SelectRoot: ({ children, label, helperText, error, color, disabled, size, className, style, ...props }: SelectRootProps) => import("react/jsx-runtime").JSX.Element;
15
+ /**
16
+ * Root component for the Select system.
17
+ * Manages accessibility IDs and shared state.
18
+ */
19
+ export declare const SelectRoot: ({ children, label, helperText, error, color, disabled, name, size, className, style, ...props }: SelectRootProps) => import("react/jsx-runtime").JSX.Element;
15
20
  export type SelectContentProps = React.SelectHTMLAttributes<HTMLSelectElement>;
21
+ /**
22
+ * The actual select element. Must be used inside Select.Root.
23
+ */
16
24
  export declare const SelectContent: ({ children, className, ref, ...props }: SelectContentProps & {
17
25
  ref?: Ref<HTMLSelectElement>;
18
26
  }) => import("react/jsx-runtime").JSX.Element;
27
+ /**
28
+ * Optional slot for icons or additional content inside the select wrapper.
29
+ */
19
30
  export declare const SelectSlot: ({ children, className, ...props }: BoxProps) => import("react/jsx-runtime").JSX.Element;
20
31
  export declare const Select: {
21
- Root: ({ children, label, helperText, error, color, disabled, size, className, style, ...props }: SelectRootProps) => import("react/jsx-runtime").JSX.Element;
32
+ Root: ({ children, label, helperText, error, color, disabled, name, size, className, style, ...props }: SelectRootProps) => import("react/jsx-runtime").JSX.Element;
22
33
  Content: ({ children, className, ref, ...props }: SelectContentProps & {
23
34
  ref?: Ref<HTMLSelectElement>;
24
35
  }) => import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"Select.d.ts","sourceRoot":"","sources":["../src/Select.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAiB,KAAK,SAAS,EAAE,KAAK,GAAG,EAAc,MAAM,OAAO,CAAC;AAM5E,OAAO,EAAO,KAAK,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAG5D,KAAK,UAAU,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAmBnD,MAAM,WAAW,eAAgB,SAAQ,QAAQ;IAC/C,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,UAAU,CAAC,EAAE,SAAS,CAAC;IACvB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,KAAK,CAAC,EAAE,cAAc,CAAC;IACvB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,oBAAoB;IACpB,IAAI,CAAC,EAAE,UAAU,CAAC;CACnB;AAED,eAAO,MAAM,UAAU,GAAI,2FAWxB,eAAe,4CA2DjB,CAAC;AAGF,MAAM,MAAM,kBAAkB,GAAG,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,CAAC;AAE/E,eAAO,MAAM,aAAa,GAAI,wCAK3B,kBAAkB,GAAG;IAAE,GAAG,CAAC,EAAE,GAAG,CAAC,iBAAiB,CAAC,CAAA;CAAE,4CAevD,CAAC;AAGF,eAAO,MAAM,UAAU,GAAI,mCAAmC,QAAQ,4CAIrE,CAAC;AAEF,eAAO,MAAM,MAAM;sGA7FhB,eAAe;sDAqEf,kBAAkB,GAAG;QAAE,GAAG,CAAC,EAAE,GAAG,CAAC,iBAAiB,CAAC,CAAA;KAAE;8CAkBM,QAAQ;CAUrE,CAAC"}
1
+ {"version":3,"file":"Select.d.ts","sourceRoot":"","sources":["../src/Select.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAiB,KAAK,SAAS,EAAE,KAAK,GAAG,EAAc,MAAM,OAAO,CAAC;AAM5E,OAAO,EAAO,KAAK,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAG5D,KAAK,UAAU,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAoBnD,MAAM,WAAW,eAAgB,SAAQ,QAAQ;IAC/C,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,UAAU,CAAC,EAAE,SAAS,CAAC;IACvB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,KAAK,CAAC,EAAE,cAAc,CAAC;IACvB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,oBAAoB;IACpB,IAAI,CAAC,EAAE,UAAU,CAAC;CACnB;AAED;;;GAGG;AACH,eAAO,MAAM,UAAU,GAAI,iGAYxB,eAAe,4CA2DjB,CAAC;AAGF,MAAM,MAAM,kBAAkB,GAAG,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,CAAC;AAE/E;;GAEG;AACH,eAAO,MAAM,aAAa,GAAI,wCAK3B,kBAAkB,GAAG;IAAE,GAAG,CAAC,EAAE,GAAG,CAAC,iBAAiB,CAAC,CAAA;CAAE,4CAgBvD,CAAC;AAGF;;GAEG;AACH,eAAO,MAAM,UAAU,GAAI,mCAAmC,QAAQ,4CAIrE,CAAC;AAEF,eAAO,MAAM,MAAM;4GApGhB,eAAe;sDAwEf,kBAAkB,GAAG;QAAE,GAAG,CAAC,EAAE,GAAG,CAAC,iBAAiB,CAAC,CAAA;KAAE;8CAsBM,QAAQ;CAUrE,CAAC"}
package/dist/index.js CHANGED
@@ -1,16 +1,16 @@
1
- import { jsx as f, jsxs as L } from "react/jsx-runtime";
2
- import { forwardRef as M, createElement as B, createContext as z, useId as F, use as G } from "react";
3
- function W(t) {
1
+ import { jsx as u, jsxs as L } from "react/jsx-runtime";
2
+ import { forwardRef as z, createElement as j, createContext as G, useId as W, use as H } from "react";
3
+ function I(t) {
4
4
  var i, r, e = "";
5
5
  if (typeof t == "string" || typeof t == "number") e += t;
6
6
  else if (typeof t == "object") if (Array.isArray(t)) {
7
7
  var a = t.length;
8
- for (i = 0; i < a; i++) t[i] && (r = W(t[i])) && (e && (e += " "), e += r);
8
+ for (i = 0; i < a; i++) t[i] && (r = I(t[i])) && (e && (e += " "), e += r);
9
9
  } else for (r in t) t[r] && (e && (e += " "), e += r);
10
10
  return e;
11
11
  }
12
- function j() {
13
- for (var t, i, r = 0, e = "", a = arguments.length; r < a; r++) (t = arguments[r]) && (i = W(t)) && (e && (e += " "), e += i);
12
+ function F() {
13
+ for (var t, i, r = 0, e = "", a = arguments.length; r < a; r++) (t = arguments[r]) && (i = I(t)) && (e && (e += " "), e += i);
14
14
  return e;
15
15
  }
16
16
  /**
@@ -19,7 +19,7 @@ function j() {
19
19
  * This source code is licensed under the MIT license.
20
20
  * See the LICENSE file in the root directory of this source tree.
21
21
  */
22
- var H = {
22
+ var J = {
23
23
  outline: {
24
24
  xmlns: "http://www.w3.org/2000/svg",
25
25
  width: 24,
@@ -46,24 +46,24 @@ var H = {
46
46
  * This source code is licensed under the MIT license.
47
47
  * See the LICENSE file in the root directory of this source tree.
48
48
  */
49
- const J = (t, i, r, e) => {
50
- const a = M(
51
- ({ color: n = "currentColor", size: s = 24, stroke: d = 2, title: l, className: h, children: c, ...p }, g) => B(
49
+ const K = (t, i, r, e) => {
50
+ const a = z(
51
+ ({ color: o = "currentColor", size: c = 24, stroke: s = 2, title: p, className: h, children: l, ...d }, m) => j(
52
52
  "svg",
53
53
  {
54
- ref: g,
55
- ...H[t],
56
- width: s,
57
- height: s,
54
+ ref: m,
55
+ ...J[t],
56
+ width: c,
57
+ height: c,
58
58
  className: ["tabler-icon", `tabler-icon-${i}`, h].join(" "),
59
- strokeWidth: d,
60
- stroke: n,
61
- ...p
59
+ strokeWidth: s,
60
+ stroke: o,
61
+ ...d
62
62
  },
63
63
  [
64
- l && B("title", { key: "svg-title" }, l),
65
- ...e.map(([m, u]) => B(m, u)),
66
- ...Array.isArray(c) ? c : [c]
64
+ p && j("title", { key: "svg-title" }, p),
65
+ ...e.map(([f, g]) => j(f, g)),
66
+ ...Array.isArray(l) ? l : [l]
67
67
  ]
68
68
  )
69
69
  );
@@ -75,36 +75,36 @@ const J = (t, i, r, e) => {
75
75
  * This source code is licensed under the MIT license.
76
76
  * See the LICENSE file in the root directory of this source tree.
77
77
  */
78
- const K = [["path", { d: "M6 9l6 6l6 -6", key: "svg-0" }]], O = J("outline", "chevron-down", "ChevronDown", K);
79
- function I(t) {
78
+ const O = [["path", { d: "M6 9l6 6l6 -6", key: "svg-0" }]], P = K("outline", "chevron-down", "ChevronDown", O);
79
+ function T(t) {
80
80
  var i, r, e = "";
81
81
  if (typeof t == "string" || typeof t == "number") e += t;
82
82
  else if (typeof t == "object") if (Array.isArray(t)) {
83
83
  var a = t.length;
84
- for (i = 0; i < a; i++) t[i] && (r = I(t[i])) && (e && (e += " "), e += r);
84
+ for (i = 0; i < a; i++) t[i] && (r = T(t[i])) && (e && (e += " "), e += r);
85
85
  } else for (r in t) t[r] && (e && (e += " "), e += r);
86
86
  return e;
87
87
  }
88
- function P() {
89
- for (var t, i, r = 0, e = "", a = arguments.length; r < a; r++) (t = arguments[r]) && (i = I(t)) && (e && (e += " "), e += i);
88
+ function Q() {
89
+ for (var t, i, r = 0, e = "", a = arguments.length; r < a; r++) (t = arguments[r]) && (i = T(t)) && (e && (e += " "), e += i);
90
90
  return e;
91
91
  }
92
- const T = ({
92
+ const q = ({
93
93
  ref: t,
94
94
  as: i = "div",
95
95
  children: r,
96
96
  display: e,
97
97
  m: a,
98
- mt: n,
99
- mr: s,
100
- mb: d,
101
- ml: l,
98
+ mt: o,
99
+ mr: c,
100
+ mb: s,
101
+ ml: p,
102
102
  p: h,
103
- pt: c,
104
- pr: p,
105
- pb: g,
106
- pl: m,
107
- width: u,
103
+ pt: l,
104
+ pr: d,
105
+ pb: m,
106
+ pl: f,
107
+ width: g,
108
108
  height: v,
109
109
  position: y,
110
110
  style: b,
@@ -114,75 +114,77 @@ const T = ({
114
114
  rel: N,
115
115
  htmlFor: S,
116
116
  type: C,
117
- disabled: A,
118
- ...k
117
+ name: A,
118
+ disabled: k,
119
+ ...R
119
120
  }) => {
120
- const o = {};
121
- e && (o.display = e), u && (o.width = u), v && (o.height = v), y && (o.position = y), a && (o.margin = `var(--pittorica-space-${a})`), n && (o.marginTop = `var(--pittorica-space-${n})`), s && (o.marginRight = `var(--pittorica-space-${s})`), d && (o.marginBottom = `var(--pittorica-space-${d})`), l && (o.marginLeft = `var(--pittorica-space-${l})`), h && (o.padding = `var(--pittorica-space-${h})`), c && (o.paddingTop = `var(--pittorica-space-${c})`), p && (o.paddingRight = `var(--pittorica-space-${p})`), g && (o.paddingBottom = `var(--pittorica-space-${g})`), m && (o.paddingLeft = `var(--pittorica-space-${m})`);
122
- const R = {
121
+ const n = {};
122
+ e && (n.display = e), g && (n.width = g), v && (n.height = v), y && (n.position = y), a && (n.margin = `var(--pittorica-space-${a})`), o && (n.marginTop = `var(--pittorica-space-${o})`), c && (n.marginRight = `var(--pittorica-space-${c})`), s && (n.marginBottom = `var(--pittorica-space-${s})`), p && (n.marginLeft = `var(--pittorica-space-${p})`), h && (n.padding = `var(--pittorica-space-${h})`), l && (n.paddingTop = `var(--pittorica-space-${l})`), d && (n.paddingRight = `var(--pittorica-space-${d})`), m && (n.paddingBottom = `var(--pittorica-space-${m})`), f && (n.paddingLeft = `var(--pittorica-space-${f})`);
123
+ const B = {
123
124
  ...b,
124
- ...o
125
+ ...n
125
126
  };
126
- return /* @__PURE__ */ f(
127
+ return /* @__PURE__ */ u(
127
128
  i,
128
129
  {
129
130
  ref: t,
130
- className: P("pittorica-box", w),
131
- style: R,
131
+ className: Q("pittorica-box", w),
132
+ style: B,
132
133
  href: $,
133
134
  target: x,
134
135
  rel: N,
135
136
  htmlFor: S,
136
137
  type: C,
137
- disabled: A,
138
- ...k,
138
+ name: A,
139
+ disabled: k,
140
+ ...R,
139
141
  children: r
140
142
  }
141
143
  );
142
144
  };
143
- T.displayName = "Box";
144
- function q(t) {
145
+ q.displayName = "Box";
146
+ function D(t) {
145
147
  var i, r, e = "";
146
148
  if (typeof t == "string" || typeof t == "number") e += t;
147
149
  else if (typeof t == "object") if (Array.isArray(t)) {
148
150
  var a = t.length;
149
- for (i = 0; i < a; i++) t[i] && (r = q(t[i])) && (e && (e += " "), e += r);
151
+ for (i = 0; i < a; i++) t[i] && (r = D(t[i])) && (e && (e += " "), e += r);
150
152
  } else for (r in t) t[r] && (e && (e += " "), e += r);
151
153
  return e;
152
154
  }
153
- function Q() {
154
- for (var t, i, r = 0, e = "", a = arguments.length; r < a; r++) (t = arguments[r]) && (i = q(t)) && (e && (e += " "), e += i);
155
+ function U() {
156
+ for (var t, i, r = 0, e = "", a = arguments.length; r < a; r++) (t = arguments[r]) && (i = D(t)) && (e && (e += " "), e += i);
155
157
  return e;
156
158
  }
157
- function D(t) {
159
+ function E(t) {
158
160
  var i, r, e = "";
159
161
  if (typeof t == "string" || typeof t == "number") e += t;
160
162
  else if (typeof t == "object") if (Array.isArray(t)) {
161
163
  var a = t.length;
162
- for (i = 0; i < a; i++) t[i] && (r = D(t[i])) && (e && (e += " "), e += r);
164
+ for (i = 0; i < a; i++) t[i] && (r = E(t[i])) && (e && (e += " "), e += r);
163
165
  } else for (r in t) t[r] && (e && (e += " "), e += r);
164
166
  return e;
165
167
  }
166
- function U() {
167
- for (var t, i, r = 0, e = "", a = arguments.length; r < a; r++) (t = arguments[r]) && (i = D(t)) && (e && (e += " "), e += i);
168
+ function V() {
169
+ for (var t, i, r = 0, e = "", a = arguments.length; r < a; r++) (t = arguments[r]) && (i = E(t)) && (e && (e += " "), e += i);
168
170
  return e;
169
171
  }
170
- const E = ({
172
+ const _ = ({
171
173
  ref: t,
172
174
  as: i = "div",
173
175
  children: r,
174
176
  display: e,
175
177
  m: a,
176
- mt: n,
177
- mr: s,
178
- mb: d,
179
- ml: l,
178
+ mt: o,
179
+ mr: c,
180
+ mb: s,
181
+ ml: p,
180
182
  p: h,
181
- pt: c,
182
- pr: p,
183
- pb: g,
184
- pl: m,
185
- width: u,
183
+ pt: l,
184
+ pr: d,
185
+ pb: m,
186
+ pl: f,
187
+ width: g,
186
188
  height: v,
187
189
  position: y,
188
190
  style: b,
@@ -192,49 +194,52 @@ const E = ({
192
194
  rel: N,
193
195
  htmlFor: S,
194
196
  type: C,
195
- disabled: A,
196
- ...k
197
+ name: A,
198
+ disabled: k,
199
+ ...R
197
200
  }) => {
198
- const o = {};
199
- e && (o.display = e), u && (o.width = u), v && (o.height = v), y && (o.position = y), a && (o.margin = `var(--pittorica-space-${a})`), n && (o.marginTop = `var(--pittorica-space-${n})`), s && (o.marginRight = `var(--pittorica-space-${s})`), d && (o.marginBottom = `var(--pittorica-space-${d})`), l && (o.marginLeft = `var(--pittorica-space-${l})`), h && (o.padding = `var(--pittorica-space-${h})`), c && (o.paddingTop = `var(--pittorica-space-${c})`), p && (o.paddingRight = `var(--pittorica-space-${p})`), g && (o.paddingBottom = `var(--pittorica-space-${g})`), m && (o.paddingLeft = `var(--pittorica-space-${m})`);
200
- const R = {
201
+ const n = {};
202
+ e && (n.display = e), g && (n.width = g), v && (n.height = v), y && (n.position = y), a && (n.margin = `var(--pittorica-space-${a})`), o && (n.marginTop = `var(--pittorica-space-${o})`), c && (n.marginRight = `var(--pittorica-space-${c})`), s && (n.marginBottom = `var(--pittorica-space-${s})`), p && (n.marginLeft = `var(--pittorica-space-${p})`), h && (n.padding = `var(--pittorica-space-${h})`), l && (n.paddingTop = `var(--pittorica-space-${l})`), d && (n.paddingRight = `var(--pittorica-space-${d})`), m && (n.paddingBottom = `var(--pittorica-space-${m})`), f && (n.paddingLeft = `var(--pittorica-space-${f})`);
203
+ const B = {
201
204
  ...b,
202
- ...o
205
+ ...n
203
206
  };
204
- return /* @__PURE__ */ f(
207
+ return /* @__PURE__ */ u(
205
208
  i,
206
209
  {
207
210
  ref: t,
208
- className: U("pittorica-box", w),
209
- style: R,
211
+ className: V("pittorica-box", w),
212
+ style: B,
210
213
  href: $,
211
214
  target: x,
212
215
  rel: N,
213
216
  htmlFor: S,
214
217
  type: C,
215
- disabled: A,
216
- ...k,
218
+ name: A,
219
+ disabled: k,
220
+ ...R,
217
221
  children: r
218
222
  }
219
223
  );
220
224
  };
221
- E.displayName = "Box";
222
- const V = ({
225
+ _.displayName = "Box";
226
+ const X = ({
223
227
  children: t,
224
228
  as: i = "span",
225
229
  weight: r = "regular",
226
230
  align: e,
227
231
  truncate: a = !1,
228
- color: n,
229
- className: s,
230
- style: d,
231
- href: l,
232
+ color: o,
233
+ className: c,
234
+ style: s,
235
+ href: p,
232
236
  target: h,
233
- rel: c,
234
- htmlFor: p,
235
- ...g
237
+ rel: l,
238
+ htmlFor: d,
239
+ name: m,
240
+ ...f
236
241
  }) => {
237
- const m = (n == null ? void 0 : n.startsWith("#")) || (n == null ? void 0 : n.startsWith("rgb")) || (n == null ? void 0 : n.startsWith("hsl")), u = /* @__PURE__ */ new Set([
242
+ const g = (o == null ? void 0 : o.startsWith("#")) || (o == null ? void 0 : o.startsWith("rgb")) || (o == null ? void 0 : o.startsWith("hsl")), v = /* @__PURE__ */ new Set([
238
243
  "danger",
239
244
  "success",
240
245
  "error",
@@ -246,67 +251,69 @@ const V = ({
246
251
  "slate",
247
252
  "blue",
248
253
  "red"
249
- ]), v = (() => {
250
- if (n)
251
- return n === "inherit" ? "inherit" : m ? n : u.has(n) ? `var(--pittorica-${n}-9)` : n;
252
- })(), y = {
253
- ...d,
254
+ ]), y = (() => {
255
+ if (o)
256
+ return o === "inherit" ? "inherit" : g ? o : v.has(o) ? `var(--pittorica-${o}-9)` : o;
257
+ })(), b = {
258
+ ...s,
254
259
  textAlign: e,
255
- color: v
260
+ color: y
256
261
  };
257
- return /* @__PURE__ */ f(
258
- E,
262
+ return /* @__PURE__ */ u(
263
+ _,
259
264
  {
260
265
  as: i,
261
- className: Q(
266
+ className: U(
262
267
  "pittorica-text",
263
268
  { "pittorica-text--truncate": a },
264
- s
269
+ c
265
270
  ),
266
271
  "data-weight": r,
267
- style: y,
268
- href: l,
272
+ style: b,
273
+ href: p,
269
274
  target: h,
270
- rel: c,
271
- htmlFor: p,
272
- ...g,
275
+ rel: l,
276
+ htmlFor: d,
277
+ name: m,
278
+ ...f,
273
279
  children: t
274
280
  }
275
281
  );
276
- }, _ = z(null), X = () => {
277
- const t = G(_);
282
+ }, M = G(null), Y = () => {
283
+ const t = H(M);
278
284
  if (!t)
279
285
  throw new Error("Select components must be wrapped in <Select.Root />");
280
286
  return t;
281
- }, Y = ({
287
+ }, Z = ({
282
288
  children: t,
283
289
  label: i,
284
290
  helperText: r,
285
291
  error: e,
286
292
  color: a = "indigo",
287
- disabled: n,
293
+ disabled: o,
294
+ name: c,
288
295
  size: s = "sm",
289
- className: d,
290
- style: l,
291
- ...h
296
+ className: p,
297
+ style: h,
298
+ ...l
292
299
  }) => {
293
- const c = F(), p = F(), m = a !== "inherit" && !(a != null && a.startsWith("#")) && !(a != null && a.startsWith("rgb")) ? `var(--pittorica-${a}-9)` : a;
294
- return /* @__PURE__ */ f(_, { value: { inputId: c, helperId: p, disabled: n, size: s }, children: /* @__PURE__ */ L(
295
- T,
300
+ const d = W(), m = W(), g = a !== "inherit" && !(a != null && a.startsWith("#")) && !(a != null && a.startsWith("rgb")) ? `var(--pittorica-${a}-9)` : a;
301
+ return /* @__PURE__ */ u(M, { value: { inputId: d, helperId: m, disabled: o, size: s, name: c }, children: /* @__PURE__ */ L(
302
+ q,
296
303
  {
297
- ...h,
298
- className: j(
304
+ ...l,
305
+ className: F(
299
306
  "pittorica-select-root",
300
307
  `pittorica-select--${s}`,
301
- d
308
+ p
302
309
  ),
303
310
  "data-error": e,
304
311
  children: [
305
- i && /* @__PURE__ */ f(
306
- V,
312
+ i && /* @__PURE__ */ u(
313
+ X,
307
314
  {
308
315
  as: "label",
309
- htmlFor: c,
316
+ htmlFor: d,
310
317
  weight: "medium",
311
318
  style: {
312
319
  paddingLeft: "4px",
@@ -321,48 +328,49 @@ const V = ({
321
328
  "div",
322
329
  {
323
330
  className: "pittorica-select-wrapper",
324
- "data-disabled": n,
331
+ "data-disabled": o,
325
332
  style: {
326
- "--pittorica-source-color": m,
327
- ...l
333
+ "--pittorica-source-color": g,
334
+ ...h
328
335
  },
329
336
  children: [
330
337
  t,
331
- /* @__PURE__ */ f("div", { className: "pittorica-select-chevron", children: /* @__PURE__ */ f(O, { size: s === "xs" ? 14 : 18 }) })
338
+ /* @__PURE__ */ u("div", { className: "pittorica-select-chevron", children: /* @__PURE__ */ u(P, { size: s === "xs" ? 14 : 18 }) })
332
339
  ]
333
340
  }
334
341
  ),
335
- r && /* @__PURE__ */ f("div", { id: p, className: "pittorica-select-helper", children: r })
342
+ r && /* @__PURE__ */ u("div", { id: m, className: "pittorica-select-helper", children: r })
336
343
  ]
337
344
  }
338
345
  ) });
339
- }, Z = ({
346
+ }, tt = ({
340
347
  children: t,
341
348
  className: i,
342
349
  ref: r,
343
350
  ...e
344
351
  }) => {
345
- const { inputId: a, helperId: n, disabled: s } = X();
346
- return /* @__PURE__ */ f(
352
+ const { inputId: a, helperId: o, disabled: c, name: s } = Y();
353
+ return /* @__PURE__ */ u(
347
354
  "select",
348
355
  {
356
+ name: s,
349
357
  ...e,
350
358
  id: a,
351
359
  ref: r,
352
- disabled: s,
353
- "aria-describedby": n,
354
- className: j("pittorica-select-input", i),
360
+ disabled: c,
361
+ "aria-describedby": o,
362
+ className: F("pittorica-select-input", i),
355
363
  children: t
356
364
  }
357
365
  );
358
- }, tt = ({ children: t, className: i, ...r }) => /* @__PURE__ */ f("div", { className: j("pittorica-select-slot", i), ...r, children: t }), it = {
359
- Root: Y,
360
- Content: Z,
361
- Slot: tt
366
+ }, et = ({ children: t, className: i, ...r }) => /* @__PURE__ */ u("div", { className: F("pittorica-select-slot", i), ...r, children: t }), at = {
367
+ Root: Z,
368
+ Content: tt,
369
+ Slot: et
362
370
  };
363
371
  export {
364
- it as Select,
365
- Z as SelectContent,
366
- Y as SelectRoot,
367
- tt as SelectSlot
372
+ at as Select,
373
+ tt as SelectContent,
374
+ Z as SelectRoot,
375
+ et as SelectSlot
368
376
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pittorica/select-react",
3
- "version": "0.23.1",
3
+ "version": "0.23.2",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",
@@ -11,8 +11,8 @@
11
11
  "dependencies": {
12
12
  "@tabler/icons-react": "^3.36.1",
13
13
  "clsx": "^2.1.1",
14
- "@pittorica/box-react": "0.23.1",
15
- "@pittorica/text-react": "0.23.1"
14
+ "@pittorica/box-react": "0.23.2",
15
+ "@pittorica/text-react": "0.23.2"
16
16
  },
17
17
  "devDependencies": {
18
18
  "@testing-library/jest-dom": "^6.9.1",
@@ -24,9 +24,9 @@
24
24
  "typescript": "^5.0.0",
25
25
  "vite": "^5.0.0",
26
26
  "vitest": "^2.1.9",
27
- "@pittorica/flex-react": "0.23.1",
28
- "@pittorica/theme-react": "0.23.1",
29
- "pittorica": "0.23.1"
27
+ "@pittorica/flex-react": "0.23.2",
28
+ "@pittorica/theme-react": "0.23.2",
29
+ "pittorica": "0.23.2"
30
30
  },
31
31
  "peerDependencies": {
32
32
  "react": ">=19",