@clearstory/drywall-react 5.3.1 → 5.3.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.
@@ -1,47 +1,48 @@
1
- import { jsxs as c, jsx as r } from "react/jsx-runtime";
1
+ import { jsxs as f, jsx as e } from "react/jsx-runtime";
2
2
  import { forwardRef as y } from "react";
3
3
  import { D } from "../../Datepicker-BbdXCdvk.js";
4
- import { FormSublabel as b } from "../FormSublabel/FormSublabel.js";
4
+ import { FormSublabel as u } from "../FormSublabel/FormSublabel.js";
5
5
  import { useId as w } from "../../hooks/useId.js";
6
6
  import "../../icons/ClearstoryIcon.js";
7
7
  import "../../icons/InternalOnlyIcon.js";
8
8
  import "../../icons/MoneyBucketIcon.js";
9
9
  import "../../icons/MoreCircleOutlineIcon.js";
10
10
  import "../../icons/SparkleIcon.js";
11
- import { I as u } from "../../Info-BIwRC_L9.js";
11
+ import { I as $ } from "../../Info-BIwRC_L9.js";
12
12
  import { F as B } from "../../FormControl-DRR12yE7.js";
13
13
  import { B as C } from "../../Box-DRIsV4J3.js";
14
- import { F as $ } from "../../FormLabel-r7XSjt-O.js";
15
- import { T as j } from "../../Tooltip-CslS55e6.js";
16
- import { F as T } from "../../FormHelperText-CmONy7Rj.js";
17
- const v = y(
14
+ import { F as j } from "../../FormLabel-r7XSjt-O.js";
15
+ import { T } from "../../Tooltip-CslS55e6.js";
16
+ import { F as v } from "../../FormHelperText-CmONy7Rj.js";
17
+ const E = y(
18
18
  ({
19
- disabled: m = !1,
20
- error: a = !1,
21
- fullWidth: p,
22
- helperText: o,
19
+ disabled: a = !1,
20
+ error: m = !1,
21
+ fullWidth: l,
22
+ helperText: i,
23
23
  label: t,
24
- name: f,
25
- required: s = !1,
26
- size: h = "small",
27
- slotProps: e = {},
28
- sublabel: n,
29
- sx: x,
24
+ name: s,
25
+ required: h = !1,
26
+ size: x = "small",
27
+ slotProps: r = {},
28
+ sublabel: p,
29
+ sx: b,
30
30
  tooltip: d,
31
31
  ...I
32
32
  }, g) => {
33
- const k = w("datepicker"), i = f || k, l = o ? `${i}-helper` : void 0;
34
- return /* @__PURE__ */ c(
33
+ const k = w("datepicker"), o = s || k, n = r.label?.id ?? `${o}-label`, c = i ? `${o}-helper` : void 0;
34
+ return /* @__PURE__ */ f(
35
35
  B,
36
36
  {
37
- component: "fieldset",
38
- disabled: m,
39
- error: a,
40
- fullWidth: p,
41
- sx: x,
42
- ...e.root,
37
+ "aria-labelledby": n,
38
+ disabled: a,
39
+ error: m,
40
+ fullWidth: l,
41
+ role: "group",
42
+ sx: b,
43
+ ...r.root,
43
44
  children: [
44
- /* @__PURE__ */ c(
45
+ /* @__PURE__ */ f(
45
46
  C,
46
47
  {
47
48
  sx: {
@@ -50,17 +51,9 @@ const v = y(
50
51
  gap: "0.25rem"
51
52
  },
52
53
  children: [
53
- /* @__PURE__ */ r(
54
+ /* @__PURE__ */ e(j, { id: n, required: h, ...r.label, children: t }),
55
+ d && /* @__PURE__ */ e(T, { title: d, arrow: !0, children: /* @__PURE__ */ e(
54
56
  $,
55
- {
56
- component: "legend",
57
- required: s,
58
- ...e.label,
59
- children: t
60
- }
61
- ),
62
- d && /* @__PURE__ */ r(j, { title: d, arrow: !0, children: /* @__PURE__ */ r(
63
- u,
64
57
  {
65
58
  sx: ({ vars: F }) => ({
66
59
  color: F?.palette.text.secondary,
@@ -73,36 +66,36 @@ const v = y(
73
66
  ]
74
67
  }
75
68
  ),
76
- n && /* @__PURE__ */ r(b, { ...e.sublabel, children: n }),
77
- /* @__PURE__ */ r(
69
+ p && /* @__PURE__ */ e(u, { ...r.sublabel, children: p }),
70
+ /* @__PURE__ */ e(
78
71
  D,
79
72
  {
80
73
  ref: g,
81
- disabled: m,
82
- name: i,
83
- error: a,
84
- size: h,
74
+ disabled: a,
75
+ name: o,
76
+ error: m,
77
+ size: x,
85
78
  slotProps: {
86
79
  field: {
87
- id: i,
88
- "aria-describedby": l,
89
- ...p && { sx: { width: "100%" } }
80
+ id: o,
81
+ "aria-describedby": c,
82
+ ...l && { sx: { width: "100%" } }
90
83
  },
91
84
  popper: {
92
85
  "aria-label": `Date picker${typeof t == "string" && ` for ${t}`}`
93
86
  },
94
- ...e?.datepicker
87
+ ...r?.datepicker
95
88
  },
96
89
  ...I
97
90
  }
98
91
  ),
99
- o && /* @__PURE__ */ r(T, { id: l, ...e.helperText, children: o })
92
+ i && /* @__PURE__ */ e(v, { id: c, ...r.helperText, children: i })
100
93
  ]
101
94
  }
102
95
  );
103
96
  }
104
97
  );
105
- v.displayName = "DatepickerControl";
98
+ E.displayName = "DatepickerControl";
106
99
  export {
107
- v as DatepickerControl
100
+ E as DatepickerControl
108
101
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@clearstory/drywall-react",
3
- "version": "5.3.1",
3
+ "version": "5.3.2",
4
4
  "license": "UNLICENSED",
5
5
  "description": "a Clearstory software design system",
6
6
  "type": "module",