@x-plat/design-system 0.9.0 → 0.10.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 (103) hide show
  1. package/dist/components/AutoResizeTextArea/index.d.cts +1 -0
  2. package/dist/components/AutoResizeTextArea/index.d.ts +1 -0
  3. package/dist/components/Badge/index.cjs +5 -1
  4. package/dist/components/Badge/index.css +1 -0
  5. package/dist/components/Badge/index.d.cts +1 -0
  6. package/dist/components/Badge/index.d.ts +1 -0
  7. package/dist/components/Badge/index.js +5 -1
  8. package/dist/components/Box/index.d.cts +3 -0
  9. package/dist/components/Box/index.d.ts +3 -0
  10. package/dist/components/Chart/index.cjs +7 -6
  11. package/dist/components/Chart/index.d.cts +12 -1
  12. package/dist/components/Chart/index.d.ts +12 -1
  13. package/dist/components/Chart/index.js +7 -6
  14. package/dist/components/ChatInput/index.d.cts +6 -0
  15. package/dist/components/ChatInput/index.d.ts +6 -0
  16. package/dist/components/CheckBox/index.cjs +6 -2
  17. package/dist/components/CheckBox/index.css +2 -0
  18. package/dist/components/CheckBox/index.d.cts +10 -2
  19. package/dist/components/CheckBox/index.d.ts +10 -2
  20. package/dist/components/CheckBox/index.js +6 -2
  21. package/dist/components/Chip/index.d.cts +2 -0
  22. package/dist/components/Chip/index.d.ts +2 -0
  23. package/dist/components/DatePicker/index.cjs +4 -3
  24. package/dist/components/DatePicker/index.js +4 -3
  25. package/dist/components/Drawer/index.d.cts +1 -0
  26. package/dist/components/Drawer/index.d.ts +1 -0
  27. package/dist/components/FileUpload/index.d.cts +6 -0
  28. package/dist/components/FileUpload/index.d.ts +6 -0
  29. package/dist/components/ImageSelector/index.d.cts +3 -0
  30. package/dist/components/ImageSelector/index.d.ts +3 -0
  31. package/dist/components/Input/index.d.cts +4 -0
  32. package/dist/components/Input/index.d.ts +4 -0
  33. package/dist/components/NotificationBadge/index.cjs +5 -1
  34. package/dist/components/NotificationBadge/index.css +1 -0
  35. package/dist/components/NotificationBadge/index.d.cts +6 -2
  36. package/dist/components/NotificationBadge/index.d.ts +6 -2
  37. package/dist/components/NotificationBadge/index.js +5 -1
  38. package/dist/components/Pagination/index.cjs +6 -2
  39. package/dist/components/Pagination/index.css +1 -0
  40. package/dist/components/Pagination/index.d.cts +13 -2
  41. package/dist/components/Pagination/index.d.ts +13 -2
  42. package/dist/components/Pagination/index.js +6 -2
  43. package/dist/components/Progress/index.cjs +6 -2
  44. package/dist/components/Progress/index.css +1 -0
  45. package/dist/components/Progress/index.d.cts +11 -2
  46. package/dist/components/Progress/index.d.ts +11 -2
  47. package/dist/components/Progress/index.js +6 -2
  48. package/dist/components/Radio/index.cjs +6 -2
  49. package/dist/components/Radio/index.css +2 -0
  50. package/dist/components/Radio/index.d.cts +11 -2
  51. package/dist/components/Radio/index.d.ts +11 -2
  52. package/dist/components/Radio/index.js +6 -2
  53. package/dist/components/Select/index.d.cts +5 -1
  54. package/dist/components/Select/index.d.ts +5 -1
  55. package/dist/components/Skeleton/index.d.cts +3 -0
  56. package/dist/components/Skeleton/index.d.ts +3 -0
  57. package/dist/components/Spinner/index.cjs +6 -2
  58. package/dist/components/Spinner/index.css +1 -0
  59. package/dist/components/Spinner/index.d.cts +8 -2
  60. package/dist/components/Spinner/index.d.ts +8 -2
  61. package/dist/components/Spinner/index.js +6 -2
  62. package/dist/components/Steps/index.cjs +6 -2
  63. package/dist/components/Steps/index.css +11 -0
  64. package/dist/components/Steps/index.d.cts +9 -2
  65. package/dist/components/Steps/index.d.ts +9 -2
  66. package/dist/components/Steps/index.js +6 -2
  67. package/dist/components/Switch/index.cjs +6 -2
  68. package/dist/components/Switch/index.css +2 -0
  69. package/dist/components/Switch/index.d.cts +10 -2
  70. package/dist/components/Switch/index.d.ts +10 -2
  71. package/dist/components/Switch/index.js +6 -2
  72. package/dist/components/Tab/index.cjs +4 -3
  73. package/dist/components/Tab/index.d.cts +12 -1
  74. package/dist/components/Tab/index.d.ts +12 -1
  75. package/dist/components/Tab/index.js +4 -3
  76. package/dist/components/Tag/index.cjs +5 -3
  77. package/dist/components/Tag/index.d.cts +12 -2
  78. package/dist/components/Tag/index.d.ts +12 -2
  79. package/dist/components/Tag/index.js +5 -3
  80. package/dist/components/TextArea/index.d.cts +3 -0
  81. package/dist/components/TextArea/index.d.ts +3 -0
  82. package/dist/components/Tooltip/index.cjs +4 -2
  83. package/dist/components/Tooltip/index.d.cts +11 -1
  84. package/dist/components/Tooltip/index.d.ts +11 -1
  85. package/dist/components/Tooltip/index.js +4 -2
  86. package/dist/components/index.cjs +46 -29
  87. package/dist/components/index.css +21 -0
  88. package/dist/components/index.d.cts +1 -0
  89. package/dist/components/index.d.ts +1 -0
  90. package/dist/components/index.js +46 -29
  91. package/dist/index.cjs +46 -29
  92. package/dist/index.css +21 -0
  93. package/dist/index.d.cts +1 -0
  94. package/dist/index.d.ts +1 -0
  95. package/dist/index.js +46 -29
  96. package/dist/status-g_KP3qT6.d.cts +8 -0
  97. package/dist/status-g_KP3qT6.d.ts +8 -0
  98. package/guidelines/AGENT_PROMPT.md +15 -0
  99. package/guidelines/components/card.md +3 -3
  100. package/guidelines/components/feedback.md +1 -1
  101. package/guidelines/components/navigation.md +16 -15
  102. package/guidelines/components/overlay.md +43 -4
  103. package/package.json +1 -1
@@ -1,3 +1,6 @@
1
+ // src/tokens/interface/status.ts
2
+ var normalizeStatus = (value) => value === "brand" ? "primary" : value;
3
+
1
4
  // ../../node_modules/clsx/dist/clsx.mjs
2
5
  function r(e) {
3
6
  var t, f, n = "";
@@ -19,12 +22,13 @@ import { jsx, jsxs } from "react/jsx-runtime";
19
22
  var Spinner = (props) => {
20
23
  const {
21
24
  size = "md",
22
- type = "brand"
25
+ type = "primary"
23
26
  } = props;
27
+ const statusType = normalizeStatus(type);
24
28
  return /* @__PURE__ */ jsx(
25
29
  "div",
26
30
  {
27
- className: clsx_default("lib-xplat-spinner", size, type),
31
+ className: clsx_default("lib-xplat-spinner", size, statusType),
28
32
  role: "status",
29
33
  "aria-label": "\uB85C\uB529 \uC911",
30
34
  children: /* @__PURE__ */ jsxs("svg", { viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
@@ -24,6 +24,9 @@ __export(Steps_exports, {
24
24
  });
25
25
  module.exports = __toCommonJS(Steps_exports);
26
26
 
27
+ // src/tokens/interface/status.ts
28
+ var normalizeStatus = (value) => value === "brand" ? "primary" : value;
29
+
27
30
  // src/tokens/svg/action/CopyIcon.tsx
28
31
  var import_jsx_runtime = require("react/jsx-runtime");
29
32
 
@@ -946,9 +949,10 @@ var Steps = (props) => {
946
949
  const {
947
950
  items,
948
951
  current,
949
- type = "brand"
952
+ type = "primary"
950
953
  } = props;
951
- return /* @__PURE__ */ (0, import_jsx_runtime295.jsx)("div", { className: clsx_default("lib-xplat-steps", type), children: items.map((item, index) => {
954
+ const statusType = normalizeStatus(type);
955
+ return /* @__PURE__ */ (0, import_jsx_runtime295.jsx)("div", { className: clsx_default("lib-xplat-steps", statusType), children: items.map((item, index) => {
952
956
  const status = index < current ? "completed" : index === current ? "active" : "pending";
953
957
  return /* @__PURE__ */ (0, import_jsx_runtime295.jsxs)("div", { className: clsx_default("step-item", status), children: [
954
958
  /* @__PURE__ */ (0, import_jsx_runtime295.jsx)("div", { className: "step-circle", children: status === "completed" ? /* @__PURE__ */ (0, import_jsx_runtime295.jsx)(CheckIcon_default, {}) : /* @__PURE__ */ (0, import_jsx_runtime295.jsx)("span", { children: index + 1 }) }),
@@ -63,6 +63,17 @@
63
63
  color: var(--semantic-text-tertiary);
64
64
  margin-top: 2px;
65
65
  }
66
+ .lib-xplat-steps.primary .step-item.completed .step-circle {
67
+ color: var(--semantic-text-inverse);
68
+ background-color: var(--semantic-surface-primary-default);
69
+ }
70
+ .lib-xplat-steps.primary .step-item.completed::after {
71
+ background-color: var(--semantic-surface-primary-default);
72
+ }
73
+ .lib-xplat-steps.primary .step-item.active .step-circle {
74
+ color: var(--semantic-text-inverse);
75
+ background-color: var(--semantic-surface-primary-default);
76
+ }
66
77
  .lib-xplat-steps.brand .step-item.completed .step-circle {
67
78
  color: var(--semantic-text-inverse);
68
79
  background-color: var(--semantic-surface-brand-default);
@@ -1,14 +1,21 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { L as LegacyStatusType } from '../../status-g_KP3qT6.cjs';
2
3
 
3
4
  interface StepItem {
4
5
  title: string;
5
6
  description?: string;
6
7
  }
7
- type StepsType = "brand" | "success" | "error" | "warning" | "info";
8
+ /** Steps 의 상태 색 */
9
+ type StepsType = "primary" | "success" | "error" | "warning" | "info";
10
+ /** 입력으로는 예전 이름 `brand` 도 받는다 (= `primary`) */
11
+ type StepsTypeInput = StepsType | LegacyStatusType;
8
12
  interface StepsProps {
13
+ /** 단계 목록. 순서대로 그려진다 */
9
14
  items: StepItem[];
15
+ /** 진행 중인 단계 인덱스 (0부터). 앞은 완료, 뒤는 대기로 표시된다 */
10
16
  current: number;
11
- type?: StepsType;
17
+ /** 완료·진행 단계의 색 */
18
+ type?: StepsTypeInput;
12
19
  }
13
20
  declare const Steps: {
14
21
  (props: StepsProps): react_jsx_runtime.JSX.Element;
@@ -1,14 +1,21 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { L as LegacyStatusType } from '../../status-g_KP3qT6.js';
2
3
 
3
4
  interface StepItem {
4
5
  title: string;
5
6
  description?: string;
6
7
  }
7
- type StepsType = "brand" | "success" | "error" | "warning" | "info";
8
+ /** Steps 의 상태 색 */
9
+ type StepsType = "primary" | "success" | "error" | "warning" | "info";
10
+ /** 입력으로는 예전 이름 `brand` 도 받는다 (= `primary`) */
11
+ type StepsTypeInput = StepsType | LegacyStatusType;
8
12
  interface StepsProps {
13
+ /** 단계 목록. 순서대로 그려진다 */
9
14
  items: StepItem[];
15
+ /** 진행 중인 단계 인덱스 (0부터). 앞은 완료, 뒤는 대기로 표시된다 */
10
16
  current: number;
11
- type?: StepsType;
17
+ /** 완료·진행 단계의 색 */
18
+ type?: StepsTypeInput;
12
19
  }
13
20
  declare const Steps: {
14
21
  (props: StepsProps): react_jsx_runtime.JSX.Element;
@@ -1,3 +1,6 @@
1
+ // src/tokens/interface/status.ts
2
+ var normalizeStatus = (value) => value === "brand" ? "primary" : value;
3
+
1
4
  // src/tokens/svg/action/CopyIcon.tsx
2
5
  import { jsx, jsxs } from "react/jsx-runtime";
3
6
 
@@ -920,9 +923,10 @@ var Steps = (props) => {
920
923
  const {
921
924
  items,
922
925
  current,
923
- type = "brand"
926
+ type = "primary"
924
927
  } = props;
925
- return /* @__PURE__ */ jsx295("div", { className: clsx_default("lib-xplat-steps", type), children: items.map((item, index) => {
928
+ const statusType = normalizeStatus(type);
929
+ return /* @__PURE__ */ jsx295("div", { className: clsx_default("lib-xplat-steps", statusType), children: items.map((item, index) => {
926
930
  const status = index < current ? "completed" : index === current ? "active" : "pending";
927
931
  return /* @__PURE__ */ jsxs189("div", { className: clsx_default("step-item", status), children: [
928
932
  /* @__PURE__ */ jsx295("div", { className: "step-circle", children: status === "completed" ? /* @__PURE__ */ jsx295(CheckIcon_default, {}) : /* @__PURE__ */ jsx295("span", { children: index + 1 }) }),
@@ -37,6 +37,9 @@ module.exports = __toCommonJS(Switch_exports);
37
37
  // src/components/Switch/Switch.tsx
38
38
  var import_react = __toESM(require("react"), 1);
39
39
 
40
+ // src/tokens/interface/status.ts
41
+ var normalizeStatus = (value) => value === "brand" ? "primary" : value;
42
+
40
43
  // ../../node_modules/clsx/dist/clsx.mjs
41
44
  function r(e) {
42
45
  var t, f, n = "";
@@ -193,11 +196,12 @@ var Switch = (props) => {
193
196
  const {
194
197
  value,
195
198
  size = "md",
196
- type = "brand",
199
+ type = "primary",
197
200
  disabled,
198
201
  onChange,
199
202
  validations
200
203
  } = props;
204
+ const statusType = normalizeStatus(type);
201
205
  const [isAnimating, setIsAnimating] = import_react.default.useState(false);
202
206
  const timeoutRef = import_react.default.useRef(null);
203
207
  import_react.default.useEffect(() => {
@@ -221,7 +225,7 @@ var Switch = (props) => {
221
225
  className: clsx_default(
222
226
  "lib-xplat-switch",
223
227
  size,
224
- type,
228
+ statusType,
225
229
  value ? "checked" : void 0,
226
230
  disabled && "disabled",
227
231
  isAnimating && "animating"
@@ -89,10 +89,12 @@
89
89
  pointer-events: none;
90
90
  cursor: wait;
91
91
  }
92
+ .lib-xplat-switch.primary.checked,
92
93
  .lib-xplat-switch.brand.checked {
93
94
  background-color: var(--semantic-surface-brand-default);
94
95
  border-color: var(--semantic-surface-brand-default);
95
96
  }
97
+ .lib-xplat-switch.primary.checked:hover:not(.disabled):not(.animating),
96
98
  .lib-xplat-switch.brand.checked:hover:not(.disabled):not(.animating) {
97
99
  background-color: var(--semantic-surface-brand-strong);
98
100
  border-color: var(--semantic-surface-brand-strong);
@@ -1,15 +1,23 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { L as LegacyStatusType } from '../../status-g_KP3qT6.cjs';
2
3
  import { V as Validation } from '../../validation-Dqo1zqhT.cjs';
3
4
 
4
5
  type SwitchSize = "sm" | "md" | "lg";
5
- type SwitchType = "brand" | "success" | "error" | "warning" | "info";
6
+ /** Switch 의 상태 색 */
7
+ type SwitchType = "primary" | "success" | "error" | "warning" | "info";
8
+ /** 입력으로는 예전 이름 `brand` 도 받는다 (= `primary`) */
9
+ type SwitchTypeInput = SwitchType | LegacyStatusType;
6
10
  interface SwitchProps {
11
+ /** 켜짐 여부. controlled 전용이라 onChange 와 함께 쓴다 */
7
12
  value: boolean;
8
13
  /** 컨트롤 아래에 표시할 검증 메시지. DS 폼 컴포넌트 공통 */
9
14
  validations?: Validation[];
15
+ /** 스위치 크기 */
10
16
  size?: SwitchSize;
11
- type?: SwitchType;
17
+ /** 켜졌을 때의 색 */
18
+ type?: SwitchTypeInput;
12
19
  disabled?: boolean;
20
+ /** 토글될 때 바뀐 값을 준다 */
13
21
  onChange?: (value: boolean) => void;
14
22
  }
15
23
  declare const Switch: {
@@ -1,15 +1,23 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { L as LegacyStatusType } from '../../status-g_KP3qT6.js';
2
3
  import { V as Validation } from '../../validation-Dqo1zqhT.js';
3
4
 
4
5
  type SwitchSize = "sm" | "md" | "lg";
5
- type SwitchType = "brand" | "success" | "error" | "warning" | "info";
6
+ /** Switch 의 상태 색 */
7
+ type SwitchType = "primary" | "success" | "error" | "warning" | "info";
8
+ /** 입력으로는 예전 이름 `brand` 도 받는다 (= `primary`) */
9
+ type SwitchTypeInput = SwitchType | LegacyStatusType;
6
10
  interface SwitchProps {
11
+ /** 켜짐 여부. controlled 전용이라 onChange 와 함께 쓴다 */
7
12
  value: boolean;
8
13
  /** 컨트롤 아래에 표시할 검증 메시지. DS 폼 컴포넌트 공통 */
9
14
  validations?: Validation[];
15
+ /** 스위치 크기 */
10
16
  size?: SwitchSize;
11
- type?: SwitchType;
17
+ /** 켜졌을 때의 색 */
18
+ type?: SwitchTypeInput;
12
19
  disabled?: boolean;
20
+ /** 토글될 때 바뀐 값을 준다 */
13
21
  onChange?: (value: boolean) => void;
14
22
  }
15
23
  declare const Switch: {
@@ -1,6 +1,9 @@
1
1
  // src/components/Switch/Switch.tsx
2
2
  import React from "react";
3
3
 
4
+ // src/tokens/interface/status.ts
5
+ var normalizeStatus = (value) => value === "brand" ? "primary" : value;
6
+
4
7
  // ../../node_modules/clsx/dist/clsx.mjs
5
8
  function r(e) {
6
9
  var t, f, n = "";
@@ -157,11 +160,12 @@ var Switch = (props) => {
157
160
  const {
158
161
  value,
159
162
  size = "md",
160
- type = "brand",
163
+ type = "primary",
161
164
  disabled,
162
165
  onChange,
163
166
  validations
164
167
  } = props;
168
+ const statusType = normalizeStatus(type);
165
169
  const [isAnimating, setIsAnimating] = React.useState(false);
166
170
  const timeoutRef = React.useRef(null);
167
171
  React.useEffect(() => {
@@ -185,7 +189,7 @@ var Switch = (props) => {
185
189
  className: clsx_default(
186
190
  "lib-xplat-switch",
187
191
  size,
188
- type,
192
+ statusType,
189
193
  value ? "checked" : void 0,
190
194
  disabled && "disabled",
191
195
  isAnimating && "animating"
@@ -74,7 +74,8 @@ var TabItem_default = TabItem;
74
74
  // src/components/Tab/Tab.tsx
75
75
  var import_jsx_runtime2 = require("react/jsx-runtime");
76
76
  var Tab = (props) => {
77
- const { activeIndex, onChange, tabs, type, size = "md" } = props;
77
+ const { activeIndex, onChange, tabs, variant, type, size = "md" } = props;
78
+ const shape = variant ?? type ?? "default";
78
79
  const [underlineStyle, setUnderlineStyle] = import_react2.default.useState({
79
80
  left: 0,
80
81
  width: 0
@@ -89,7 +90,7 @@ var Tab = (props) => {
89
90
  setUnderlineStyle({ left: el.offsetLeft, width: el.offsetWidth });
90
91
  }
91
92
  }, [activeIndex, tabs.length]);
92
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { className: clsx_default("lib-xplat-tab", `type-${type}`, size), children: [
93
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { className: clsx_default("lib-xplat-tab", `type-${shape}`, size), children: [
93
94
  tabs.map((tab, idx) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
94
95
  TabItem_default,
95
96
  {
@@ -102,7 +103,7 @@ var Tab = (props) => {
102
103
  },
103
104
  `${tab.value}_${idx}`
104
105
  )),
105
- type === "toggle" && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
106
+ shape === "toggle" && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
106
107
  "div",
107
108
  {
108
109
  className: "tab-toggle-underline",
@@ -5,11 +5,22 @@ interface TabItemType {
5
5
  title: string;
6
6
  }
7
7
  type TabSize = "sm" | "md" | "lg";
8
+ type TabVariant = "default" | "toggle";
8
9
  interface TabProps {
10
+ /** 활성 탭 인덱스. controlled 전용이라 onChange 와 함께 쓴다 */
9
11
  activeIndex: number;
12
+ /** 탭 목록. children 을 받지 않는다 */
10
13
  tabs: TabItemType[];
14
+ /** 첫 인자가 탭 객체, **두 번째가 인덱스**다. setActiveIndex 를 그대로 넘기면 안 된다 */
11
15
  onChange: (value: TabItemType, index: number) => void;
12
- type: "default" | "toggle";
16
+ /** 탭 모양. `default` 는 채워진 평면 탭, `toggle` 은 밑줄 인디케이터가 슬라이드 */
17
+ variant?: TabVariant;
18
+ /**
19
+ * @deprecated 모양 변형은 `variant` 로 받는다. `type` 은 상태 색 전용이다.
20
+ * 기존 사용처가 깨지지 않도록 계속 받는다 — 둘 다 주면 `variant` 가 이긴다.
21
+ */
22
+ type?: TabVariant;
23
+ /** 탭 높이와 글자 크기 */
13
24
  size?: TabSize;
14
25
  }
15
26
  declare const Tab: {
@@ -5,11 +5,22 @@ interface TabItemType {
5
5
  title: string;
6
6
  }
7
7
  type TabSize = "sm" | "md" | "lg";
8
+ type TabVariant = "default" | "toggle";
8
9
  interface TabProps {
10
+ /** 활성 탭 인덱스. controlled 전용이라 onChange 와 함께 쓴다 */
9
11
  activeIndex: number;
12
+ /** 탭 목록. children 을 받지 않는다 */
10
13
  tabs: TabItemType[];
14
+ /** 첫 인자가 탭 객체, **두 번째가 인덱스**다. setActiveIndex 를 그대로 넘기면 안 된다 */
11
15
  onChange: (value: TabItemType, index: number) => void;
12
- type: "default" | "toggle";
16
+ /** 탭 모양. `default` 는 채워진 평면 탭, `toggle` 은 밑줄 인디케이터가 슬라이드 */
17
+ variant?: TabVariant;
18
+ /**
19
+ * @deprecated 모양 변형은 `variant` 로 받는다. `type` 은 상태 색 전용이다.
20
+ * 기존 사용처가 깨지지 않도록 계속 받는다 — 둘 다 주면 `variant` 가 이긴다.
21
+ */
22
+ type?: TabVariant;
23
+ /** 탭 높이와 글자 크기 */
13
24
  size?: TabSize;
14
25
  }
15
26
  declare const Tab: {
@@ -38,7 +38,8 @@ var TabItem_default = TabItem;
38
38
  // src/components/Tab/Tab.tsx
39
39
  import { jsx as jsx2, jsxs } from "react/jsx-runtime";
40
40
  var Tab = (props) => {
41
- const { activeIndex, onChange, tabs, type, size = "md" } = props;
41
+ const { activeIndex, onChange, tabs, variant, type, size = "md" } = props;
42
+ const shape = variant ?? type ?? "default";
42
43
  const [underlineStyle, setUnderlineStyle] = React2.useState({
43
44
  left: 0,
44
45
  width: 0
@@ -53,7 +54,7 @@ var Tab = (props) => {
53
54
  setUnderlineStyle({ left: el.offsetLeft, width: el.offsetWidth });
54
55
  }
55
56
  }, [activeIndex, tabs.length]);
56
- return /* @__PURE__ */ jsxs("div", { className: clsx_default("lib-xplat-tab", `type-${type}`, size), children: [
57
+ return /* @__PURE__ */ jsxs("div", { className: clsx_default("lib-xplat-tab", `type-${shape}`, size), children: [
57
58
  tabs.map((tab, idx) => /* @__PURE__ */ jsx2(
58
59
  TabItem_default,
59
60
  {
@@ -66,7 +67,7 @@ var Tab = (props) => {
66
67
  },
67
68
  `${tab.value}_${idx}`
68
69
  )),
69
- type === "toggle" && /* @__PURE__ */ jsx2(
70
+ shape === "toggle" && /* @__PURE__ */ jsx2(
70
71
  "div",
71
72
  {
72
73
  className: "tab-toggle-underline",
@@ -939,20 +939,22 @@ var import_jsx_runtime295 = require("react/jsx-runtime");
939
939
  var Tag = (props) => {
940
940
  const {
941
941
  children,
942
- type = "neutral",
942
+ variant,
943
+ type,
943
944
  onClose,
944
945
  size = "md",
945
946
  disabled = false,
946
947
  colorIndex
947
948
  } = props;
949
+ const shape = variant ?? type ?? "neutral";
948
950
  return /* @__PURE__ */ (0, import_jsx_runtime295.jsxs)(
949
951
  "span",
950
952
  {
951
953
  className: clsx_default(
952
954
  "lib-xplat-tag",
953
- type,
955
+ shape,
954
956
  size,
955
- type === "categorical" && colorIndex !== void 0 && `cat-${colorIndex}`,
957
+ shape === "categorical" && colorIndex !== void 0 && `cat-${colorIndex}`,
956
958
  disabled && "disabled"
957
959
  ),
958
960
  children: [
@@ -1,14 +1,24 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import React from 'react';
3
3
 
4
- type TagType = "neutral" | "categorical";
4
+ type TagVariant = "neutral" | "categorical";
5
5
  type TagSize = "sm" | "md" | "lg";
6
6
  interface TagProps {
7
7
  children: React.ReactNode;
8
- type?: TagType;
8
+ /** 태그 배색. `categorical` 은 `colorIndex` 로 계열 색을 고른다 */
9
+ variant?: TagVariant;
10
+ /**
11
+ * @deprecated 모양 변형은 `variant` 로 받는다. `type` 은 상태 색 전용이다.
12
+ * 기존 사용처가 깨지지 않도록 계속 받는다 — 둘 다 주면 `variant` 가 이긴다.
13
+ */
14
+ type?: TagVariant;
15
+ /** 주면 오른쪽에 닫기 버튼이 생긴다. 제거 가능한 태그로 쓸 때 */
9
16
  onClose?: () => void;
17
+ /** 태그 크기 */
10
18
  size?: TagSize;
19
+ /** 흐리게 표시하고 닫기 버튼을 막는다 */
11
20
  disabled?: boolean;
21
+ /** variant 가 categorical 일 때 쓸 계열 색 번호 (1~8) */
12
22
  colorIndex?: number;
13
23
  }
14
24
  declare const Tag: {
@@ -1,14 +1,24 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import React from 'react';
3
3
 
4
- type TagType = "neutral" | "categorical";
4
+ type TagVariant = "neutral" | "categorical";
5
5
  type TagSize = "sm" | "md" | "lg";
6
6
  interface TagProps {
7
7
  children: React.ReactNode;
8
- type?: TagType;
8
+ /** 태그 배색. `categorical` 은 `colorIndex` 로 계열 색을 고른다 */
9
+ variant?: TagVariant;
10
+ /**
11
+ * @deprecated 모양 변형은 `variant` 로 받는다. `type` 은 상태 색 전용이다.
12
+ * 기존 사용처가 깨지지 않도록 계속 받는다 — 둘 다 주면 `variant` 가 이긴다.
13
+ */
14
+ type?: TagVariant;
15
+ /** 주면 오른쪽에 닫기 버튼이 생긴다. 제거 가능한 태그로 쓸 때 */
9
16
  onClose?: () => void;
17
+ /** 태그 크기 */
10
18
  size?: TagSize;
19
+ /** 흐리게 표시하고 닫기 버튼을 막는다 */
11
20
  disabled?: boolean;
21
+ /** variant 가 categorical 일 때 쓸 계열 색 번호 (1~8) */
12
22
  colorIndex?: number;
13
23
  }
14
24
  declare const Tag: {
@@ -913,20 +913,22 @@ import { jsx as jsx295, jsxs as jsxs189 } from "react/jsx-runtime";
913
913
  var Tag = (props) => {
914
914
  const {
915
915
  children,
916
- type = "neutral",
916
+ variant,
917
+ type,
917
918
  onClose,
918
919
  size = "md",
919
920
  disabled = false,
920
921
  colorIndex
921
922
  } = props;
923
+ const shape = variant ?? type ?? "neutral";
922
924
  return /* @__PURE__ */ jsxs189(
923
925
  "span",
924
926
  {
925
927
  className: clsx_default(
926
928
  "lib-xplat-tag",
927
- type,
929
+ shape,
928
930
  size,
929
- type === "categorical" && colorIndex !== void 0 && `cat-${colorIndex}`,
931
+ shape === "categorical" && colorIndex !== void 0 && `cat-${colorIndex}`,
930
932
  disabled && "disabled"
931
933
  ),
932
934
  children: [
@@ -5,10 +5,13 @@ import { V as Validation } from '../../validation-Dqo1zqhT.cjs';
5
5
  type TextAreaSize = "sm" | "md" | "lg";
6
6
  type TextAreaResize = "none" | "vertical" | "horizontal" | "both";
7
7
  interface TextAreaProps extends Omit<TextareaAttributes, "size"> {
8
+ /** 안쪽 여백과 글자 크기 */
8
9
  size?: TextAreaSize;
9
10
  /** 컨트롤 아래에 표시할 검증 메시지. DS 폼 컴포넌트 공통 */
10
11
  validations?: Validation[];
12
+ /** 사용자가 크기를 조절할 방향 */
11
13
  resize?: TextAreaResize;
14
+ /** 기본으로 보일 줄 수 */
12
15
  rows?: number;
13
16
  }
14
17
  declare const TextArea: React.ForwardRefExoticComponent<TextAreaProps & React.RefAttributes<HTMLTextAreaElement>>;
@@ -5,10 +5,13 @@ import { V as Validation } from '../../validation-Dqo1zqhT.js';
5
5
  type TextAreaSize = "sm" | "md" | "lg";
6
6
  type TextAreaResize = "none" | "vertical" | "horizontal" | "both";
7
7
  interface TextAreaProps extends Omit<TextareaAttributes, "size"> {
8
+ /** 안쪽 여백과 글자 크기 */
8
9
  size?: TextAreaSize;
9
10
  /** 컨트롤 아래에 표시할 검증 메시지. DS 폼 컴포넌트 공통 */
10
11
  validations?: Validation[];
12
+ /** 사용자가 크기를 조절할 방향 */
11
13
  resize?: TextAreaResize;
14
+ /** 기본으로 보일 줄 수 */
12
15
  rows?: number;
13
16
  }
14
17
  declare const TextArea: React.ForwardRefExoticComponent<TextAreaProps & React.RefAttributes<HTMLTextAreaElement>>;
@@ -72,10 +72,12 @@ var Tooltip = (props) => {
72
72
  children,
73
73
  title,
74
74
  description,
75
- type = "dark",
75
+ variant,
76
+ type,
76
77
  follow = false,
77
78
  disabled = false
78
79
  } = props;
80
+ const shape = variant ?? type ?? "dark";
79
81
  const triggerRef = import_react.default.useRef(null);
80
82
  const tooltipRef = import_react.default.useRef(null);
81
83
  const [visible, setVisible] = import_react.default.useState(false);
@@ -185,7 +187,7 @@ var Tooltip = (props) => {
185
187
  {
186
188
  ref: tooltipRef,
187
189
  role: "tooltip",
188
- className: clsx_default("lib-xplat-tooltip", type),
190
+ className: clsx_default("lib-xplat-tooltip", shape),
189
191
  style: { position: "fixed", left: pos.left, top: pos.top },
190
192
  children: [
191
193
  title && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "tooltip-title", children: title }),
@@ -1,10 +1,19 @@
1
1
  import React from 'react';
2
2
 
3
+ type TooltipVariant = "dark" | "light";
3
4
  interface TooltipProps {
4
5
  children: React.ReactNode;
6
+ /** 말풍선 첫 줄. 굵게 표시된다 */
5
7
  title?: React.ReactNode;
8
+ /** 말풍선 본문. title 과 둘 중 하나는 있어야 뜬다 */
6
9
  description?: React.ReactNode;
7
- type?: "dark" | "light";
10
+ /** 말풍선 배색 */
11
+ variant?: TooltipVariant;
12
+ /**
13
+ * @deprecated 모양 변형은 `variant` 로 받는다. `type` 은 상태 색 전용이다.
14
+ * 기존 사용처가 깨지지 않도록 계속 받는다 — 둘 다 주면 `variant` 가 이긴다.
15
+ */
16
+ type?: TooltipVariant;
8
17
  /**
9
18
  * 커서를 따라다닌다. 기본값은 `false` — 트리거 요소 기준으로 고정된다
10
19
  * (PopOver/Dropdown/Select 와 같은 방식).
@@ -13,6 +22,7 @@ interface TooltipProps {
13
22
  * 아이콘처럼 대상이 작은 경우는 고정이 읽기 편하다.
14
23
  */
15
24
  follow?: boolean;
25
+ /** 말풍선을 띄우지 않는다 */
16
26
  disabled?: boolean;
17
27
  }
18
28
  declare const Tooltip: React.FC<TooltipProps>;
@@ -1,10 +1,19 @@
1
1
  import React from 'react';
2
2
 
3
+ type TooltipVariant = "dark" | "light";
3
4
  interface TooltipProps {
4
5
  children: React.ReactNode;
6
+ /** 말풍선 첫 줄. 굵게 표시된다 */
5
7
  title?: React.ReactNode;
8
+ /** 말풍선 본문. title 과 둘 중 하나는 있어야 뜬다 */
6
9
  description?: React.ReactNode;
7
- type?: "dark" | "light";
10
+ /** 말풍선 배색 */
11
+ variant?: TooltipVariant;
12
+ /**
13
+ * @deprecated 모양 변형은 `variant` 로 받는다. `type` 은 상태 색 전용이다.
14
+ * 기존 사용처가 깨지지 않도록 계속 받는다 — 둘 다 주면 `variant` 가 이긴다.
15
+ */
16
+ type?: TooltipVariant;
8
17
  /**
9
18
  * 커서를 따라다닌다. 기본값은 `false` — 트리거 요소 기준으로 고정된다
10
19
  * (PopOver/Dropdown/Select 와 같은 방식).
@@ -13,6 +22,7 @@ interface TooltipProps {
13
22
  * 아이콘처럼 대상이 작은 경우는 고정이 읽기 편하다.
14
23
  */
15
24
  follow?: boolean;
25
+ /** 말풍선을 띄우지 않는다 */
16
26
  disabled?: boolean;
17
27
  }
18
28
  declare const Tooltip: React.FC<TooltipProps>;
@@ -36,10 +36,12 @@ var Tooltip = (props) => {
36
36
  children,
37
37
  title,
38
38
  description,
39
- type = "dark",
39
+ variant,
40
+ type,
40
41
  follow = false,
41
42
  disabled = false
42
43
  } = props;
44
+ const shape = variant ?? type ?? "dark";
43
45
  const triggerRef = React.useRef(null);
44
46
  const tooltipRef = React.useRef(null);
45
47
  const [visible, setVisible] = React.useState(false);
@@ -149,7 +151,7 @@ var Tooltip = (props) => {
149
151
  {
150
152
  ref: tooltipRef,
151
153
  role: "tooltip",
152
- className: clsx_default("lib-xplat-tooltip", type),
154
+ className: clsx_default("lib-xplat-tooltip", shape),
153
155
  style: { position: "fixed", left: pos.left, top: pos.top },
154
156
  children: [
155
157
  title && /* @__PURE__ */ jsx("div", { className: "tooltip-title", children: title }),