@pylerai/design-system 2.1.0 → 2.2.1

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/README.md CHANGED
@@ -86,13 +86,21 @@ module.exports = {
86
86
  };
87
87
  ```
88
88
 
89
- 이미 `extend.colors`를 쓰고 있어 색상 맵만 필요하다면:
89
+ 이미 자체 `theme.extend`가 있어 프리셋 대신 조각만 합치려면 (`darkMode` 등 프리셋의 다른 설정은 들어오지 않습니다):
90
90
 
91
91
  ```javascript
92
92
  const { dsColors } = require("@pylerai/design-system/pyler-tailwind-colors");
93
+ const { pylerTypographyThemeExtend } = require("@pylerai/design-system/pyler-typography");
94
+ const { pylerShadowRadiusThemeExtend } = require("@pylerai/design-system/pyler-shadow-radius");
93
95
 
94
96
  module.exports = {
95
- theme: { extend: { colors: { ds: dsColors } } },
97
+ theme: {
98
+ extend: {
99
+ colors: { ds: dsColors },
100
+ ...pylerTypographyThemeExtend, // fontFamily.sans, fontSize.text-*
101
+ ...pylerShadowRadiusThemeExtend, // boxShadow.ds-*, borderRadius.ds-*
102
+ },
103
+ },
96
104
  };
97
105
  ```
98
106
 
@@ -229,6 +237,23 @@ import { PYLER_TYPOGRAPHY_STYLE } from "@pylerai/design-system";
229
237
  // shadow: ds-default, ds-modal
230
238
  ```
231
239
 
240
+ Tailwind 클래스를 쓸 수 없는 자리(Chakra `radii`/`shadows` foundation, `sx`, inline style)에는 `DS_RADIUS`·`DS_SHADOW`를 넘깁니다. 값은 `var(--ds-*)` 문자열이라 `style.css`가 로드돼 있어야 합니다.
241
+
242
+ ```tsx
243
+ import { DS_RADIUS, DS_SHADOW } from "@pylerai/design-system";
244
+
245
+ // Chakra: theme foundation 에 등록하면 borderRadius="ds-md" 처럼 토큰 이름으로 쓸 수 있습니다
246
+ extendTheme({
247
+ radii: { "ds-xs": DS_RADIUS.xs, "ds-ss": DS_RADIUS.ss, "ds-md": DS_RADIUS.md, "ds-lg": DS_RADIUS.lg },
248
+ shadows: { "ds-default": DS_SHADOW.default, "ds-modal": DS_SHADOW.modal },
249
+ });
250
+
251
+ <Box borderRadius="ds-md" boxShadow="ds-default" />
252
+ <div style={{ borderRadius: DS_RADIUS.md }} />
253
+ ```
254
+
255
+ 앱에서 `rounded-[8px]`·`shadow-[0px_5px_16px_…]` 같은 리터럴을 새로 쓰지 않습니다. 값이 같아도 토큰이 바뀌면 리터럴만 남아 드리프트합니다.
256
+
232
257
  Dim은 `var(--ds-dim-default)`로 제공됩니다. Storybook **Foundation → Radius / Shadow / Dim** 참고.
233
258
 
234
259
  ## ♿ 접근성
@@ -23,21 +23,21 @@ const b = {
23
23
  md: { padding: "px-2 pt-[5px] pb-[3px]", text: "text-body-3-m" },
24
24
  sm: { padding: "px-1 pt-[3px] pb-[1px]", text: "text-label-1-r" }
25
25
  }, g = l.forwardRef(
26
- ({ color: r = "normal", size: e = "md", className: t, children: o, ...d }, a) => {
27
- const { border: s, text: n } = b[r], { padding: p, text: m } = c[e];
26
+ ({ color: r = "normal", size: e = "md", className: t, children: o, ...s }, d) => {
27
+ const { border: a, text: n } = b[r], { padding: p, text: m } = c[e];
28
28
  return /* @__PURE__ */ x(
29
29
  "span",
30
30
  {
31
- ref: a,
31
+ ref: d,
32
32
  className: i(
33
- "inline-flex items-center justify-center border rounded-[4px] bg-ds-background-default whitespace-nowrap",
34
- s,
33
+ "inline-flex items-center justify-center border rounded-ds-ss bg-ds-background-default whitespace-nowrap",
34
+ a,
35
35
  p,
36
36
  n,
37
37
  m,
38
38
  t
39
39
  ),
40
- ...d,
40
+ ...s,
41
41
  children: o
42
42
  }
43
43
  );
@@ -9,10 +9,10 @@ const v = R(
9
9
  {
10
10
  variants: {
11
11
  variant: {
12
- filled: "rounded-lg",
13
- outlined: "rounded-lg border border-ds-line-normal bg-ds-background-default text-ds-text-strong hover:bg-ds-surface-normal active:bg-ds-surface-strong disabled:bg-ds-surface-normal disabled:text-ds-text-disabled",
14
- text: "rounded-lg bg-transparent text-ds-text-strong disabled:text-ds-text-disabled",
15
- icon: "rounded-lg",
12
+ filled: "rounded-ds-md",
13
+ outlined: "rounded-ds-md border border-ds-line-normal bg-ds-background-default text-ds-text-strong hover:bg-ds-surface-normal active:bg-ds-surface-strong disabled:bg-ds-surface-normal disabled:text-ds-text-disabled",
14
+ text: "rounded-ds-md bg-transparent text-ds-text-strong disabled:text-ds-text-disabled",
15
+ icon: "rounded-ds-md",
16
16
  indicator: "rounded-full inline-block"
17
17
  },
18
18
  color: {
@@ -116,12 +116,12 @@ const v = R(
116
116
  asChild: c = !1,
117
117
  shape: u = "square",
118
118
  iconStyle: x = "filled",
119
- leftIcon: t,
120
- rightIcon: d,
119
+ leftIcon: d,
120
+ rightIcon: t,
121
121
  children: b,
122
122
  ...h
123
123
  }, y) => {
124
- const f = c ? B : "button", N = e === "icon" && x === "outlined" ? "bg-ds-background-default border border-ds-line-normal text-ds-text-strong hover:bg-ds-surface-normal active:bg-ds-surface-strong disabled:text-ds-text-disabled" : void 0, l = !!t, p = !!d, z = e !== "icon" && e !== "indicator" && (l || p) ? (() => {
124
+ const f = c ? B : "button", N = e === "icon" && x === "outlined" ? "bg-ds-background-default border border-ds-line-normal text-ds-text-strong hover:bg-ds-surface-normal active:bg-ds-surface-strong disabled:text-ds-text-disabled" : void 0, l = !!d, p = !!t, z = e !== "icon" && e !== "indicator" && (l || p) ? (() => {
125
125
  const n = r ?? "md", o = {
126
126
  sm: { leftOnly: "pl-1 pr-2", rightOnly: "pl-2 pr-1", both: "px-1" },
127
127
  md: { leftOnly: "pl-2 pr-3", rightOnly: "pl-3 pr-2", both: "px-2" },
@@ -143,9 +143,9 @@ const v = R(
143
143
  ref: y,
144
144
  ...h,
145
145
  children: c ? b : /* @__PURE__ */ O(k, { children: [
146
- t && /* @__PURE__ */ a("span", { className: "shrink-0", children: t }),
146
+ d && /* @__PURE__ */ a("span", { className: "shrink-0", children: d }),
147
147
  b,
148
- d && /* @__PURE__ */ a("span", { className: "shrink-0", children: d })
148
+ t && /* @__PURE__ */ a("span", { className: "shrink-0", children: t })
149
149
  ] })
150
150
  }
151
151
  );
@@ -4,20 +4,20 @@ import { XIcon as b } from "../../lib/icons.js";
4
4
  import { cn as n } from "../../lib/utils.js";
5
5
  import * as f from "react";
6
6
  const h = f.forwardRef(
7
- ({ size: l = "md", selected: i = !1, disabled: e = !1, onRemove: a, onClick: r, children: p, className: d }, c) => {
7
+ ({ size: l = "md", selected: i = !1, disabled: e = !1, onRemove: a, onClick: r, children: d, className: p }, c) => {
8
8
  const s = l === "md", t = !!a, u = r ? "button" : "span";
9
9
  return /* @__PURE__ */ x(
10
10
  "div",
11
11
  {
12
12
  ref: c,
13
13
  className: n(
14
- "inline-flex items-center border rounded-[4px] bg-ds-background-default select-none transition-colors",
14
+ "inline-flex items-center border rounded-ds-ss bg-ds-background-default select-none transition-colors",
15
15
  // 좌우 여백은 컨테이너가 아니라 본문(클릭 대상)이 갖는다.
16
16
  // 컨테이너에 두면 여백 영역이 클릭되지 않는 죽은 공간이 된다.
17
17
  s ? t ? "h-8 pr-1" : "h-8" : t ? "h-[26px] pr-0.5" : "h-[26px]",
18
18
  s ? "text-body-3-r" : "text-body-4-r",
19
19
  e ? "border-ds-line-normal text-ds-text-disabled cursor-not-allowed" : i ? "border-ds-primary-blue-normal text-ds-text-strong cursor-pointer" : "border-ds-line-normal text-ds-text-strong cursor-pointer hover:border-ds-line-strong",
20
- d
20
+ p
21
21
  ),
22
22
  children: [
23
23
  /* @__PURE__ */ o(
@@ -36,7 +36,7 @@ const h = f.forwardRef(
36
36
  r && !e && "cursor-pointer",
37
37
  r && "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ds-primary-blue-normal rounded-[3px]"
38
38
  ),
39
- children: p
39
+ children: d
40
40
  }
41
41
  ),
42
42
  t && /* @__PURE__ */ o(
@@ -1,10 +1,10 @@
1
1
  "use client";
2
2
  import { jsxs as u, jsx as r } from "react/jsx-runtime";
3
- import { DropdownArrowIcon as _, SelectCheckIcon as C, CheckboxCheckedIcon as V, CheckboxUncheckedIcon as ee, RadioCheckedIcon as te, RadioUncheckedIcon as re } from "../../lib/icons.js";
3
+ import { DropdownArrowIcon as V, SelectCheckIcon as ee, CheckboxCheckedIcon as te, CheckboxUncheckedIcon as re, RadioCheckedIcon as se, RadioUncheckedIcon as ne } from "../../lib/icons.js";
4
4
  import { cn as m } from "../../lib/utils.js";
5
- import * as a from "react";
6
- import { Button as q } from "./button.js";
7
- const k = {
5
+ import * as n from "react";
6
+ import { Button as B } from "./button.js";
7
+ const v = {
8
8
  lg: {
9
9
  trigger: "h-11 pl-3 pr-2 gap-1.5",
10
10
  option: "h-11 pl-3 pr-2",
@@ -20,111 +20,111 @@ const k = {
20
20
  option: "h-8 pl-3 pr-2",
21
21
  text: "text-body-3-r"
22
22
  }
23
- }, se = a.forwardRef(
23
+ }, ae = n.forwardRef(
24
24
  ({
25
- type: o = "default",
26
- options: d,
25
+ type: d = "default",
26
+ options: i,
27
27
  value: A,
28
28
  onValueChange: w,
29
- values: n,
29
+ values: a,
30
30
  onValuesChange: N,
31
31
  placeholder: L = "선택해주세요",
32
- label: g,
33
- showLabel: v = !0,
32
+ label: h,
33
+ showLabel: y = !0,
34
34
  require: M,
35
- size: h = "lg",
35
+ size: g = "lg",
36
36
  disabled: x,
37
- readOnly: y,
37
+ readOnly: I,
38
38
  error: b,
39
- hint: I,
39
+ hint: S,
40
40
  leftIcon: O,
41
- showButtons: z,
42
- cancelLabel: B = "취소",
43
- confirmLabel: H = "확인",
41
+ showButtons: H,
42
+ cancelLabel: F = "취소",
43
+ confirmLabel: G = "확인",
44
44
  onCancel: R,
45
- onConfirm: S,
46
- wrapperClassName: F,
47
- className: G,
48
- "aria-label": J
49
- }, P) => {
50
- const [s, i] = a.useState(!1), [c, D] = a.useState(-1), E = a.useRef(null), U = a.useRef(null), K = a.useRef(null), f = a.useId(), j = (e) => `${f}-option-${e}`;
51
- a.useEffect(() => {
45
+ onConfirm: D,
46
+ wrapperClassName: J,
47
+ className: P,
48
+ "aria-label": Q
49
+ }, W) => {
50
+ const [s, o] = n.useState(!1), [c, k] = n.useState(-1), [U, K] = n.useState("keyboard"), E = n.useRef(null), T = n.useRef(null), q = n.useRef(null), f = n.useId(), j = (e) => `${f}-option-${e}`;
51
+ n.useEffect(() => {
52
52
  const e = (t) => {
53
- E.current && !E.current.contains(t.target) && i(!1);
53
+ E.current && !E.current.contains(t.target) && o(!1);
54
54
  };
55
55
  return document.addEventListener("mousedown", e), () => document.removeEventListener("mousedown", e);
56
- }, []), a.useEffect(() => {
57
- s || D(-1);
58
- }, [s]), a.useEffect(() => {
56
+ }, []), n.useEffect(() => {
57
+ s || k(-1);
58
+ }, [s]), n.useEffect(() => {
59
59
  var e, t;
60
- !s || c < 0 || (t = (e = U.current) == null ? void 0 : e.querySelector(`#${CSS.escape(j(c))}`)) == null || t.scrollIntoView({ block: "nearest" });
60
+ !s || c < 0 || (t = (e = T.current) == null ? void 0 : e.querySelector(`#${CSS.escape(j(c))}`)) == null || t.scrollIntoView({ block: "nearest" });
61
61
  }, [s, c]);
62
- const Q = (e) => o === "checkbox" ? (n == null ? void 0 : n.includes(e)) ?? !1 : e === A, $ = d.find((e) => e.value === A), W = () => o === "checkbox" ? !n || n.length === 0 ? L : d.filter((t) => n.includes(t.value)).map((t) => t.label).join(", ") : $ ? $.label : L, X = () => {
63
- x || y || i((e) => !e);
64
- }, T = (e) => {
65
- if (o === "checkbox") {
66
- const t = n ?? [], l = t.includes(e) ? t.filter((p) => p !== e) : [...t, e];
62
+ const X = (e) => d === "checkbox" ? (a == null ? void 0 : a.includes(e)) ?? !1 : e === A, $ = i.find((e) => e.value === A), Y = () => d === "checkbox" ? !a || a.length === 0 ? L : i.filter((t) => a.includes(t.value)).map((t) => t.label).join(", ") : $ ? $.label : L, Z = () => {
63
+ x || I || o((e) => !e);
64
+ }, z = (e) => {
65
+ if (d === "checkbox") {
66
+ const t = a ?? [], l = t.includes(e) ? t.filter((p) => p !== e) : [...t, e];
67
67
  N == null || N(l);
68
68
  } else
69
- w == null || w(e), i(!1);
70
- }, Y = o === "checkbox" ? ((n == null ? void 0 : n.length) ?? 0) > 0 : !!$, Z = (e) => {
69
+ w == null || w(e), o(!1);
70
+ }, _ = d === "checkbox" ? ((a == null ? void 0 : a.length) ?? 0) > 0 : !!$, C = (e) => {
71
71
  var l;
72
- if (x || y) return;
72
+ if (x || I) return;
73
73
  const t = (p) => {
74
- e.preventDefault(), s || i(!0), D(p);
74
+ e.preventDefault(), s || o(!0), K("keyboard"), k(p);
75
75
  };
76
76
  switch (e.key) {
77
77
  case "ArrowDown":
78
- return t(s ? Math.min(c + 1, d.length - 1) : 0);
78
+ return t(s ? Math.min(c + 1, i.length - 1) : 0);
79
79
  case "ArrowUp":
80
- return t(s ? Math.max(c - 1, 0) : d.length - 1);
80
+ return t(s ? Math.max(c - 1, 0) : i.length - 1);
81
81
  case "Home":
82
82
  return s ? t(0) : void 0;
83
83
  case "End":
84
- return s ? t(d.length - 1) : void 0;
84
+ return s ? t(i.length - 1) : void 0;
85
85
  case "Enter":
86
86
  case " ":
87
- e.preventDefault(), s ? c >= 0 && T(d[c].value) : i(!0);
87
+ e.preventDefault(), s ? c >= 0 && z(i[c].value) : o(!0);
88
88
  return;
89
89
  case "Escape":
90
- s && (e.preventDefault(), i(!1), (l = K.current) == null || l.focus());
90
+ s && (e.preventDefault(), o(!1), (l = q.current) == null || l.focus());
91
91
  return;
92
92
  case "Tab":
93
- i(!1);
93
+ o(!1);
94
94
  return;
95
95
  default:
96
96
  return;
97
97
  }
98
98
  };
99
- return /* @__PURE__ */ u("div", { ref: P, className: m("flex flex-col gap-2", F), children: [
100
- v && g && /* @__PURE__ */ u("div", { className: "flex items-start gap-0.5 whitespace-nowrap", children: [
101
- /* @__PURE__ */ r("span", { id: `${f}-label`, className: "text-body-2-r text-ds-text-strong", children: g }),
99
+ return /* @__PURE__ */ u("div", { ref: W, className: m("flex flex-col gap-2", J), children: [
100
+ y && h && /* @__PURE__ */ u("div", { className: "flex items-start gap-0.5 whitespace-nowrap", children: [
101
+ /* @__PURE__ */ r("span", { id: `${f}-label`, className: "text-body-2-r text-ds-text-strong", children: h }),
102
102
  M && /* @__PURE__ */ r("span", { "aria-hidden": "true", className: "text-body-2-r text-ds-primary-red-normal", children: "*" })
103
103
  ] }),
104
104
  /* @__PURE__ */ u("div", { ref: E, className: "relative", children: [
105
105
  /* @__PURE__ */ u(
106
106
  "button",
107
107
  {
108
- ref: K,
108
+ ref: q,
109
109
  type: "button",
110
110
  role: "combobox",
111
111
  "aria-expanded": s,
112
112
  "aria-haspopup": "listbox",
113
113
  "aria-controls": s ? f : void 0,
114
114
  "aria-activedescendant": s && c >= 0 ? j(c) : void 0,
115
- "aria-labelledby": v && g ? `${f}-label` : void 0,
116
- "aria-label": v && g ? void 0 : J,
115
+ "aria-labelledby": y && h ? `${f}-label` : void 0,
116
+ "aria-label": y && h ? void 0 : Q,
117
117
  "aria-invalid": b ? !0 : void 0,
118
- "aria-describedby": b || I ? `${f}-description` : void 0,
118
+ "aria-describedby": b || S ? `${f}-description` : void 0,
119
119
  "aria-required": M || void 0,
120
120
  disabled: x,
121
- onClick: X,
122
- onKeyDown: Z,
121
+ onClick: Z,
122
+ onKeyDown: C,
123
123
  className: m(
124
- "flex items-center w-full rounded-lg border transition-colors",
125
- x ? "bg-ds-surface-strong border-ds-line-normal cursor-not-allowed" : y ? "bg-ds-surface-normal border-ds-line-normal cursor-default" : b ? "bg-ds-background-default border-ds-primary-red-normal hover:bg-ds-surface-normal" : s ? "bg-ds-background-default border-ds-primary-blue-normal" : "bg-ds-background-default border-ds-line-normal hover:bg-ds-surface-normal hover:border-ds-line-strong",
126
- k[h].trigger,
127
- G
124
+ "flex items-center w-full rounded-ds-md border transition-colors",
125
+ x ? "bg-ds-surface-strong border-ds-line-normal cursor-not-allowed" : I ? "bg-ds-surface-normal border-ds-line-normal cursor-default" : b ? "bg-ds-background-default border-ds-primary-red-normal hover:bg-ds-surface-normal" : s ? "bg-ds-background-default border-ds-primary-blue-normal" : "bg-ds-background-default border-ds-line-normal hover:bg-ds-surface-normal hover:border-ds-primary-blue-normal",
126
+ v[g].trigger,
127
+ P
128
128
  ),
129
129
  children: [
130
130
  O && /* @__PURE__ */ r("span", { className: "shrink-0 flex items-center justify-center text-ds-icon-normal", children: O }),
@@ -133,10 +133,10 @@ const k = {
133
133
  {
134
134
  className: m(
135
135
  "flex-1 min-w-0 text-left truncate font-sans",
136
- k[h].text,
137
- Y ? "text-ds-text-strong" : x ? "text-ds-text-disabled" : "text-ds-text-normal"
136
+ v[g].text,
137
+ _ ? "text-ds-text-strong" : x ? "text-ds-text-disabled" : "text-ds-text-normal"
138
138
  ),
139
- children: W()
139
+ children: Y()
140
140
  }
141
141
  ),
142
142
  /* @__PURE__ */ r(
@@ -147,7 +147,7 @@ const k = {
147
147
  s && "rotate-180",
148
148
  x ? "text-ds-text-disabled" : "text-ds-text-normal"
149
149
  ),
150
- children: /* @__PURE__ */ r(_, {})
150
+ children: /* @__PURE__ */ r(V, {})
151
151
  }
152
152
  )
153
153
  ]
@@ -156,14 +156,17 @@ const k = {
156
156
  s && /* @__PURE__ */ u(
157
157
  "ul",
158
158
  {
159
- ref: U,
159
+ ref: T,
160
160
  id: f,
161
161
  role: "listbox",
162
- "aria-multiselectable": o === "checkbox" ? !0 : void 0,
163
- className: "absolute top-full left-0 z-50 mt-1 min-w-full w-max max-w-sm bg-ds-background-default border border-ds-line-normal rounded-lg p-1 shadow-ds-default",
162
+ "aria-multiselectable": d === "checkbox" ? !0 : void 0,
163
+ className: "absolute top-full left-0 z-50 mt-1 min-w-full w-max max-w-sm bg-ds-background-default border border-ds-line-normal rounded-ds-md p-1 shadow-ds-default",
164
+ onMouseLeave: () => {
165
+ U === "mouse" && k(-1);
166
+ },
164
167
  children: [
165
- d.map((e, t) => {
166
- const l = Q(e.value), p = t === c;
168
+ i.map((e, t) => {
169
+ const l = X(e.value), p = t === c;
167
170
  return (
168
171
  // 키보드 조작은 aria-activedescendant 패턴에 따라 combobox 트리거의
169
172
  // onKeyDown이 전담한다(옵션은 포커스를 받지 않는 것이 WAI-ARIA 권고).
@@ -175,14 +178,16 @@ const k = {
175
178
  id: j(t),
176
179
  role: "option",
177
180
  "aria-selected": l,
178
- onClick: () => T(e.value),
179
- onMouseEnter: () => D(t),
181
+ onClick: () => z(e.value),
182
+ onMouseEnter: () => {
183
+ K("mouse"), k(t);
184
+ },
180
185
  className: m(
181
- "flex items-center rounded-lg cursor-pointer gap-1.5 transition-colors",
182
- k[h].option,
186
+ "flex items-center rounded-ds-md cursor-pointer gap-1.5 transition-colors",
187
+ v[g].option,
183
188
  l ? "bg-ds-surface-normal" : "bg-ds-background-default hover:bg-ds-surface-normal",
184
- // 키보드 이동 위치 표시 (마우스 hover와 구분되도록 링으로)
185
- p && "ring-1 ring-inset ring-ds-primary-blue-normal"
189
+ // 키보드 이동 위치 표시 (마우스 hover와 구분되도록 링으로, 키보드 이동에만)
190
+ p && U === "keyboard" && "ring-1 ring-inset ring-ds-primary-blue-normal"
186
191
  ),
187
192
  children: [
188
193
  /* @__PURE__ */ r(
@@ -190,45 +195,45 @@ const k = {
190
195
  {
191
196
  className: m(
192
197
  "flex-1 min-w-0 truncate font-sans",
193
- k[h].text,
198
+ v[g].text,
194
199
  "text-ds-text-strong"
195
200
  ),
196
201
  children: e.label
197
202
  }
198
203
  ),
199
- o === "default" && l && /* @__PURE__ */ r("span", { className: "shrink-0 flex items-center justify-center text-ds-text-strong", children: /* @__PURE__ */ r(C, {}) }),
200
- o === "checkbox" && /* @__PURE__ */ r("span", { className: "shrink-0 flex items-center justify-center", children: l ? /* @__PURE__ */ r(V, {}) : /* @__PURE__ */ r(ee, {}) }),
201
- o === "radio" && /* @__PURE__ */ r("span", { className: "shrink-0 flex items-center justify-center", children: l ? /* @__PURE__ */ r(te, {}) : /* @__PURE__ */ r(re, {}) })
204
+ d === "default" && l && /* @__PURE__ */ r("span", { className: "shrink-0 flex items-center justify-center text-ds-text-strong", children: /* @__PURE__ */ r(ee, {}) }),
205
+ d === "checkbox" && /* @__PURE__ */ r("span", { className: "shrink-0 flex items-center justify-center", children: l ? /* @__PURE__ */ r(te, {}) : /* @__PURE__ */ r(re, {}) }),
206
+ d === "radio" && /* @__PURE__ */ r("span", { className: "shrink-0 flex items-center justify-center", children: l ? /* @__PURE__ */ r(se, {}) : /* @__PURE__ */ r(ne, {}) })
202
207
  ]
203
208
  },
204
209
  e.value
205
210
  )
206
211
  );
207
212
  }),
208
- z && /* @__PURE__ */ u("li", { className: "flex gap-2 pt-1", children: [
213
+ H && /* @__PURE__ */ u("li", { className: "flex gap-2 pt-1", children: [
209
214
  /* @__PURE__ */ r(
210
- q,
215
+ B,
211
216
  {
212
217
  variant: "outlined",
213
218
  size: "lg",
214
219
  className: "flex-1",
215
220
  onClick: () => {
216
- R == null || R(), i(!1);
221
+ R == null || R(), o(!1);
217
222
  },
218
- children: B
223
+ children: F
219
224
  }
220
225
  ),
221
226
  /* @__PURE__ */ r(
222
- q,
227
+ B,
223
228
  {
224
229
  variant: "filled",
225
230
  color: "blue",
226
231
  size: "lg",
227
232
  className: "flex-1",
228
233
  onClick: () => {
229
- S == null || S(), i(!1);
234
+ D == null || D(), o(!1);
230
235
  },
231
- children: H
236
+ children: G
232
237
  }
233
238
  )
234
239
  ] })
@@ -236,7 +241,7 @@ const k = {
236
241
  }
237
242
  )
238
243
  ] }),
239
- (b || I) && /* @__PURE__ */ r(
244
+ (b || S) && /* @__PURE__ */ r(
240
245
  "p",
241
246
  {
242
247
  id: `${f}-description`,
@@ -244,13 +249,13 @@ const k = {
244
249
  "text-body-4-r",
245
250
  b ? "text-ds-primary-red-normal" : "text-ds-text-normal"
246
251
  ),
247
- children: b ?? I
252
+ children: b ?? S
248
253
  }
249
254
  )
250
255
  ] });
251
256
  }
252
257
  );
253
- se.displayName = "Dropdown";
258
+ ae.displayName = "Dropdown";
254
259
  export {
255
- se as Dropdown
260
+ ae as Dropdown
256
261
  };
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { jsxs as i, jsx as e } from "react/jsx-runtime";
3
3
  import { EyeOnIcon as E, EyeOffIcon as P } from "../../lib/icons.js";
4
- import { cn as r } from "../../lib/utils.js";
4
+ import { cn as d } from "../../lib/utils.js";
5
5
  import * as o from "react";
6
6
  const I = {
7
7
  lg: {
@@ -18,7 +18,7 @@ const I = {
18
18
  }
19
19
  }, V = o.forwardRef(
20
20
  ({
21
- label: d,
21
+ label: r,
22
22
  showLabel: c = !0,
23
23
  require: l,
24
24
  message: n,
@@ -44,17 +44,17 @@ const I = {
44
44
  children: m ? /* @__PURE__ */ e(E, {}) : /* @__PURE__ */ e(P, {})
45
45
  }
46
46
  ) : null);
47
- return /* @__PURE__ */ i("div", { className: r("flex flex-col gap-2", F), children: [
48
- c && d && /* @__PURE__ */ i("div", { className: "flex items-start gap-0.5 whitespace-nowrap", children: [
49
- /* @__PURE__ */ e("label", { htmlFor: y, className: "text-body-2-r text-ds-text-strong", children: d }),
47
+ return /* @__PURE__ */ i("div", { className: d("flex flex-col gap-2", F), children: [
48
+ c && r && /* @__PURE__ */ i("div", { className: "flex items-start gap-0.5 whitespace-nowrap", children: [
49
+ /* @__PURE__ */ e("label", { htmlFor: y, className: "text-body-2-r text-ds-text-strong", children: r }),
50
50
  l && /* @__PURE__ */ e("span", { "aria-hidden": "true", className: "text-body-2-r text-ds-primary-red-normal", children: "*" })
51
51
  ] }),
52
52
  n && /* @__PURE__ */ e("p", { id: N, className: "text-body-4-r text-ds-text-strong", children: n }),
53
53
  /* @__PURE__ */ i(
54
54
  "div",
55
55
  {
56
- className: r(
57
- "flex items-center overflow-hidden bg-ds-background-default border rounded-lg transition-colors",
56
+ className: d(
57
+ "flex items-center overflow-hidden bg-ds-background-default border rounded-ds-md transition-colors",
58
58
  t ? "border-ds-primary-red-normal" : "border-ds-line-normal hover:border-ds-line-strong focus-within:border-ds-primary-blue-normal",
59
59
  (b || f) && "bg-ds-surface-normal",
60
60
  I[a].container
@@ -69,7 +69,7 @@ const I = {
69
69
  "aria-invalid": t ? !0 : void 0,
70
70
  "aria-describedby": B,
71
71
  "aria-required": l || void 0,
72
- className: r(
72
+ className: d(
73
73
  "flex-1 min-w-0 bg-transparent outline-none font-sans",
74
74
  "text-ds-text-strong placeholder:text-ds-text-normal",
75
75
  "disabled:text-ds-text-disabled",
@@ -89,7 +89,7 @@ const I = {
89
89
  "p",
90
90
  {
91
91
  id: v,
92
- className: r(
92
+ className: d(
93
93
  "text-body-4-r",
94
94
  t ? "text-ds-primary-red-normal" : "text-ds-text-normal"
95
95
  ),
@@ -101,16 +101,16 @@ const I = {
101
101
  );
102
102
  V.displayName = "InputField";
103
103
  const $ = o.forwardRef(
104
- ({ label: d, showLabel: c = !0, wrapperClassName: l, className: n, ...s }, t) => {
104
+ ({ label: r, showLabel: c = !0, wrapperClassName: l, className: n, ...s }, t) => {
105
105
  const x = o.useId(), a = s.id ?? x;
106
- return /* @__PURE__ */ i("div", { className: r("flex flex-col gap-2", l), children: [
107
- c && d && /* @__PURE__ */ e("label", { htmlFor: a, className: "text-body-2-r text-ds-text-strong", children: d }),
108
- /* @__PURE__ */ e("div", { className: "overflow-hidden border border-ds-line-normal bg-ds-background-default rounded-lg p-3 hover:border-ds-line-strong focus-within:border-ds-primary-blue-normal transition-colors", children: /* @__PURE__ */ e(
106
+ return /* @__PURE__ */ i("div", { className: d("flex flex-col gap-2", l), children: [
107
+ c && r && /* @__PURE__ */ e("label", { htmlFor: a, className: "text-body-2-r text-ds-text-strong", children: r }),
108
+ /* @__PURE__ */ e("div", { className: "overflow-hidden border border-ds-line-normal bg-ds-background-default rounded-ds-md p-3 hover:border-ds-line-strong focus-within:border-ds-primary-blue-normal transition-colors", children: /* @__PURE__ */ e(
109
109
  "textarea",
110
110
  {
111
111
  ref: t,
112
112
  id: a,
113
- className: r(
113
+ className: d(
114
114
  "w-full min-h-[114px] resize-none bg-transparent outline-none font-sans",
115
115
  "text-body-3-r text-ds-text-strong placeholder:text-ds-text-normal",
116
116
  "disabled:text-ds-text-disabled",