sellmate-design-system-react 9.0.0-beta.2 → 9.0.0-beta.20

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 (130) hide show
  1. package/AGENTS.md +463 -89
  2. package/README.md +101 -0
  3. package/dist/components/SBadge/README.md +24 -0
  4. package/dist/components/SBadge/SBadge.d.ts +1 -1
  5. package/dist/components/SBarcodeInput/README.md +9 -1
  6. package/dist/components/SBarcodeInput/SBarcodeInput.d.ts +7 -1
  7. package/dist/components/SButton/README.md +36 -0
  8. package/dist/components/SCalendar/README.md +13 -0
  9. package/dist/components/SCallout/README.md +15 -0
  10. package/dist/components/SCard/SCard.d.ts +1 -1
  11. package/dist/components/SCheckbox/README.md +8 -0
  12. package/dist/components/SChipFilter/README.md +288 -5
  13. package/dist/components/SChipFilter/SChipFilter.d.ts +95 -40
  14. package/dist/components/SChipFilter/index.d.ts +1 -1
  15. package/dist/components/SChipInput/README.md +15 -1
  16. package/dist/components/SChipInput/SChipInput.d.ts +7 -1
  17. package/dist/components/SCircleProgress/README.md +8 -0
  18. package/dist/components/SConfirmModal/README.md +16 -0
  19. package/dist/components/SDatePicker/README.md +60 -4
  20. package/dist/components/SDatePicker/SDatePicker.d.ts +61 -5
  21. package/dist/components/SDatePicker/index.d.ts +1 -1
  22. package/dist/components/SDateRangePicker/README.md +17 -2
  23. package/dist/components/SDateRangePicker/SDateRangePicker.d.ts +16 -3
  24. package/dist/components/SDivider/README.md +4 -0
  25. package/dist/components/SDraggableItem/README.md +37 -0
  26. package/dist/components/SDraggableItem/SDraggableItem.d.ts +2 -0
  27. package/dist/components/SDraggableList/README.md +29 -0
  28. package/dist/components/SDraggableList/SDraggableList.d.ts +10 -0
  29. package/dist/components/SDraggableList/index.d.ts +1 -1
  30. package/dist/components/SDrawer/README.md +8 -0
  31. package/dist/components/SDropdownButton/README.md +19 -0
  32. package/dist/components/SEditor/EditorBody.d.ts +40 -0
  33. package/dist/components/SEditor/EditorToolbar.d.ts +87 -0
  34. package/dist/components/SEditor/README.md +230 -0
  35. package/dist/components/SEditor/SEditor.d.ts +124 -0
  36. package/dist/components/SEditor/editor-icons.d.ts +59 -0
  37. package/dist/components/SEditor/editor.config.d.ts +85 -0
  38. package/dist/components/SEditor/index.d.ts +2 -0
  39. package/dist/components/SEditor/tiptap-api.d.ts +29 -0
  40. package/dist/components/SEditor/use-is-mobile.d.ts +14 -0
  41. package/dist/components/SExpansionItem/README.md +36 -0
  42. package/dist/components/SField/README.md +27 -2
  43. package/dist/components/SField/SField.d.ts +22 -4
  44. package/dist/components/SFilePicker/README.md +15 -1
  45. package/dist/components/SFilePicker/SFilePicker.d.ts +7 -1
  46. package/dist/components/SFooter/README.md +21 -0
  47. package/dist/components/SForm/README.md +11 -0
  48. package/dist/components/SGhostButton/README.md +20 -2
  49. package/dist/components/SGnb/README.md +45 -0
  50. package/dist/components/SGnb/gnb.config.d.ts +7 -0
  51. package/dist/components/SGuide/README.md +15 -0
  52. package/dist/components/SIcon/README.md +4 -0
  53. package/dist/components/SIcon/SIcon.d.ts +1 -1
  54. package/dist/components/SIcon/icons.gen.d.ts +2 -0
  55. package/dist/components/SImage/README.md +14 -0
  56. package/dist/components/SInput/README.md +3 -1
  57. package/dist/components/SInput/SInput.d.ts +7 -1
  58. package/dist/components/SKeyValueTable/README.md +87 -0
  59. package/dist/components/SKeyValueTable/SKeyValueTable.d.ts +14 -3
  60. package/dist/components/SLayout/README.md +16 -0
  61. package/dist/components/SLinearProgress/README.md +8 -0
  62. package/dist/components/SList/README.md +5 -1
  63. package/dist/components/SList/SList.d.ts +0 -2
  64. package/dist/components/SListItem/README.md +41 -0
  65. package/dist/components/SLoadingModal/README.md +8 -0
  66. package/dist/components/SNumberInput/README.md +9 -1
  67. package/dist/components/SNumberInput/SNumberInput.d.ts +7 -1
  68. package/dist/components/SPage/README.md +41 -1
  69. package/dist/components/SPage/SPage.d.ts +24 -2
  70. package/dist/components/SPage/index.d.ts +1 -1
  71. package/dist/components/SPage/page.config.d.ts +8 -0
  72. package/dist/components/SPopover/README.md +15 -0
  73. package/dist/components/SPopup/README.md +19 -0
  74. package/dist/components/SPortal/README.md +14 -0
  75. package/dist/components/SRadio/README.md +20 -0
  76. package/dist/components/SRadioButton/README.md +18 -0
  77. package/dist/components/SScrollArea/README.md +14 -0
  78. package/dist/components/SSearchInput/README.md +61 -0
  79. package/dist/components/SSearchInput/SSearchInput.d.ts +52 -0
  80. package/dist/components/SSearchInput/index.d.ts +1 -0
  81. package/dist/components/SSectionHeaderCard/README.md +39 -20
  82. package/dist/components/SSectionHeaderCard/SSectionHeaderCard.d.ts +21 -14
  83. package/dist/components/SSectionHeaderCard/index.d.ts +1 -1
  84. package/dist/components/SSelect/README.md +25 -3
  85. package/dist/components/SSelect/SSelect.d.ts +13 -1
  86. package/dist/components/SSplitter/README.md +15 -0
  87. package/dist/components/SStepper/README.md +26 -0
  88. package/dist/components/SSwitch/README.md +13 -0
  89. package/dist/components/STable/README.md +72 -1
  90. package/dist/components/STable/STable.d.ts +129 -11
  91. package/dist/components/STable/index.d.ts +1 -1
  92. package/dist/components/STabs/README.md +12 -1
  93. package/dist/components/STabs/STabs.d.ts +2 -4
  94. package/dist/components/STabs/index.d.ts +1 -1
  95. package/dist/components/STabs/tabs.config.d.ts +3 -4
  96. package/dist/components/STag/README.md +47 -0
  97. package/dist/components/STextLink/README.md +17 -0
  98. package/dist/components/STextLink/STextLink.d.ts +2 -0
  99. package/dist/components/STextarea/README.md +1 -1
  100. package/dist/components/STextarea/STextarea.d.ts +7 -1
  101. package/dist/components/STimePicker/README.md +15 -1
  102. package/dist/components/STimePicker/STimePicker.d.ts +7 -1
  103. package/dist/components/STimePicker/timepicker.config.d.ts +7 -0
  104. package/dist/components/STimeRangePicker/README.md +27 -1
  105. package/dist/components/STimeRangePicker/STimeRangePicker.d.ts +7 -1
  106. package/dist/components/SToast/README.md +24 -0
  107. package/dist/components/SToggle/README.md +8 -0
  108. package/dist/components/STooltip/README.md +22 -0
  109. package/dist/components/STree/README.md +41 -0
  110. package/dist/components/STree/STree.d.ts +8 -0
  111. package/dist/components/STree/index.d.ts +1 -1
  112. package/dist/index.cjs +3987 -496
  113. package/dist/index.cjs.map +1 -1
  114. package/dist/index.d.ts +3 -0
  115. package/dist/index.js +3970 -496
  116. package/dist/index.js.map +1 -1
  117. package/dist/lib/field-width.d.ts +31 -0
  118. package/dist/lib/story-docs.d.ts +19 -3
  119. package/dist/lib/truncated-value-tooltip.d.ts +18 -0
  120. package/dist/llms-full.txt +2312 -198
  121. package/dist/llms.txt +465 -91
  122. package/dist/styles.css +672 -41
  123. package/dist/theme.css +22 -6
  124. package/eslint/index.mjs +10 -0
  125. package/eslint/lib/table-column.mjs +26 -0
  126. package/eslint/rules/field-width-grade.d.mts +41 -0
  127. package/eslint/rules/field-width-grade.mjs +311 -0
  128. package/eslint/rules/table-column-width.mjs +110 -0
  129. package/eslint/scale.gen.mjs +3 -0
  130. package/package.json +13 -1
@@ -0,0 +1,61 @@
1
+ # SSearchInput
2
+
3
+ > 자동 생성 문서 — `npm run docs:gen`. 소스: 각 컴포넌트의 Props/Handle 인터페이스 + import 의존성.
4
+
5
+ ### SSearchInput
6
+
7
+ #### Props
8
+
9
+ | Prop | Type | Default | Description |
10
+ |------|------|---------|-------------|
11
+ | `value?` | `string \| number` | — | 값 (제어) |
12
+ | `size?` | `SSearchInputSize` | `'sm'` | 크기 |
13
+ | `placeholder?` | `string` | `'결과 내 검색'` | 플레이스홀더 |
14
+ | `clearable?` | `boolean` | `false` | 지우기 버튼 — 값이 있을 때만 나타난다 |
15
+ | `disabled?` | `boolean` | `false` | 비활성 |
16
+ | `width?` | `SFieldWidth` | — | 컨트롤 너비 — 폭 등급(`'xs' | 'sm' | 'md' | 'lg' | 'xl'`) · 숫자=px · CSS 길이. 등급은 `--cmp-field-width-*` 토큰으로 풀리므로 토큰이 바뀌면 화면이 따라간다. 값 길이에 상한이 없으면 `"100%"` 로 두어 행 전체를 쓴다. 미지정 시 부모 폭을 채운다. |
17
+ | `focused?` | `boolean` | — | 포커스 상태 (제어/반영) |
18
+ | `hovered?` | `boolean` | — | 호버 상태 (제어/반영) |
19
+ | `inputClass?` | `string` | — | 내부 input 요소 className |
20
+ | `inputStyle?` | `CSSProperties` | — | 내부 input 요소 style |
21
+ | `className?` | `string` | — | |
22
+ | `style?` | `CSSProperties` | — | |
23
+
24
+ #### Events
25
+
26
+ | Event | Type | Description |
27
+ |-------|------|-------------|
28
+ | `onValueChange` | `(value: string) => void` | 값 변경 — 문자열 전달 |
29
+ | `onChange` | `InputHTMLAttributes<HTMLInputElement>['onChange']` | 네이티브 onChange (form-agnostic 연동용, RHF 등) |
30
+ | `onSearch` | `(value: string) => void` | 검색 실행 — Enter 키에서 현재 값과 함께 호출된다. 한글 조합 중의 Enter(IME 확정)는 검색으로 치지 않는다. |
31
+
32
+ ## Types
33
+
34
+ ### SSearchInputSize
35
+
36
+ ```ts
37
+ export type SSearchInputSize = SFieldSize;
38
+ ```
39
+
40
+ ## Dependencies
41
+
42
+ ### Used by
43
+
44
+ - [SSelect](../SSelect)
45
+
46
+ ### Depends on
47
+
48
+ - [SField](../SField)
49
+ - [SGhostButton](../SGhostButton)
50
+ - [SIcon](../SIcon)
51
+
52
+ ### Graph
53
+
54
+ ```mermaid
55
+ graph TD;
56
+ SSearchInput --> SField
57
+ SSearchInput --> SGhostButton
58
+ SSearchInput --> SIcon
59
+ SSelect --> SSearchInput
60
+ style SSearchInput fill:#f9f,stroke:#333,stroke-width:4px
61
+ ```
@@ -0,0 +1,52 @@
1
+ import { type CSSProperties, type InputHTMLAttributes } from 'react';
2
+ import { type SFieldSize } from '../SField';
3
+ import { type SFieldWidth } from '../../lib/field-width';
4
+ export type SSearchInputSize = SFieldSize;
5
+ export interface SSearchInputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'value' | 'onChange' | 'type' | 'prefix' | 'suffix'> {
6
+ /** 값 (제어) */
7
+ value?: string | number;
8
+ /** 값 변경 — 문자열 전달 */
9
+ onValueChange?: (value: string) => void;
10
+ /** 네이티브 onChange (form-agnostic 연동용, RHF 등) */
11
+ onChange?: InputHTMLAttributes<HTMLInputElement>['onChange'];
12
+ /**
13
+ * 검색 실행 — Enter 키에서 현재 값과 함께 호출된다.
14
+ * 한글 조합 중의 Enter(IME 확정)는 검색으로 치지 않는다.
15
+ */
16
+ onSearch?: (value: string) => void;
17
+ /** 크기 */
18
+ size?: SSearchInputSize;
19
+ /** 플레이스홀더 */
20
+ placeholder?: string;
21
+ /** 지우기 버튼 — 값이 있을 때만 나타난다 */
22
+ clearable?: boolean;
23
+ /** 비활성 */
24
+ disabled?: boolean;
25
+ /**
26
+ * 컨트롤 너비 — 폭 등급(`'xs' | 'sm' | 'md' | 'lg' | 'xl'`) · 숫자=px · CSS 길이.
27
+ * 등급은 `--cmp-field-width-*` 토큰으로 풀리므로 토큰이 바뀌면 화면이 따라간다.
28
+ * 값 길이에 상한이 없으면 `"100%"` 로 두어 행 전체를 쓴다.
29
+ * 미지정 시 부모 폭을 채운다.
30
+ */
31
+ width?: SFieldWidth;
32
+ /** 포커스 상태 (제어/반영) */
33
+ focused?: boolean;
34
+ /** 호버 상태 (제어/반영) */
35
+ hovered?: boolean;
36
+ /** 내부 input 요소 className */
37
+ inputClass?: string;
38
+ /** 내부 input 요소 style */
39
+ inputStyle?: CSSProperties;
40
+ className?: string;
41
+ style?: CSSProperties;
42
+ }
43
+ /**
44
+ * SSearchInput — 목록·결과를 검색어로 좁히는 한 줄 입력.
45
+ *
46
+ * 테두리 박스(border/radius/배경 + hover·focus 강조)는 `SField` 가 소유하고,
47
+ * 이 컴포넌트는 그 안의 돋보기 아이콘 + input 만 그린다.
48
+ * 좌측 아이콘은 **장식**이라 클릭 대상이 아니다 — 검색 실행은 Enter(`onSearch`) 다.
49
+ *
50
+ * 라벨·검증·에러 메시지가 필요한 폼 필드라면 `SInput` 을 쓴다.
51
+ */
52
+ export declare const SSearchInput: import("react").ForwardRefExoticComponent<SSearchInputProps & import("react").RefAttributes<HTMLInputElement>>;
@@ -0,0 +1 @@
1
+ export { SSearchInput, type SSearchInputProps, type SSearchInputSize } from './SSearchInput';
@@ -2,37 +2,56 @@
2
2
 
3
3
  > 자동 생성 문서 — `npm run docs:gen`. 소스: 각 컴포넌트의 Props/Handle 인터페이스 + import 의존성.
4
4
 
5
- ### SSectionHeaderCardBody
6
-
7
- #### Props
8
-
9
- | Prop | Type | Default | Description |
10
- |------|------|---------|-------------|
11
- | `children?` | `SSectionHeaderCardBodyChildren` | — | 바디 슬롯. 특정 컴포넌트 타입으로 제한하지 않습니다. |
12
- | `padding?` | `SSectionHeaderCardBodyPadding` | `'default'` | 안쪽 여백. 기본은 `default`. 성격이 다른 요소가 세 종류 이상 섞인 영역에만 `wide`, 표를 가장자리까지 채울 때만 `none`. |
13
-
14
- ### SSectionHeaderCardHeader
5
+ ### SSectionHeaderCard
15
6
 
16
7
  #### Props
17
8
 
18
9
  | Prop | Type | Default | Description |
19
10
  |------|------|---------|-------------|
20
- | `title` | `ReactNode` | — | 헤더 제목 |
21
- | `titleSize?` | `SSectionHeaderCardTitleSize` | `'xs'` | 제목 크기 |
22
- | `marker?` | `boolean` | `false` | 제목 앞 점 표시 여부 |
23
- | `required?` | `boolean` | `false` | 제목 뒤 필수 별 표시 여부 |
11
+ | `title?` | `ReactNode` | — | 헤더 제목 |
12
+ | `titleSize?` | `SSectionHeaderCardTitleSize` | — | 제목 크기 |
13
+ | `marker?` | `boolean` | — | 제목 앞 점 표시 여부 |
14
+ | `required?` | `boolean` | — | 제목 뒤 필수 별 표시 여부 |
24
15
  | `helpText?` | `string[]` | — | 도움말 툴팁 메시지 |
25
16
  | `subtitle?` | `ReactNode` | — | 부제 |
26
17
  | `slot?` | `ReactNode` | — | 헤더 우측 슬롯 |
27
- | `thickness?` | `SSectionHeaderCardThickness` | `false` | 상단 border 색상 타입. false면 표시하지 않습니다. |
18
+ | `thickness?` | `SSectionHeaderCardThickness` | — | 상단 border 색상 타입. false면 표시하지 않습니다. |
19
+ | `headerClassName?` | `string` | — | 헤더 영역 클래스 |
20
+ | `padding?` | `SSectionHeaderCardBodyPadding` | — | 바디 안쪽 여백. 기본은 `default`. 성격이 다른 요소가 세 종류 이상 섞인 영역에만 `wide`, 표를 가장자리까지 채울 때만 `none`. |
21
+ | `background?` | `SSectionHeaderCardBodyBackground` | — | 본문 배경. 기본은 `frame` — 카드가 깐 흰 면을 그대로 쓴다. `neutral` 은 바탕을 한 단계 눌러앉혀, 흰 면 덩어리(표·리스트)가 여럿일 때 그것들이 **"면 위에 놓인 객체"로 읽히게** 한다. 위계를 한 단계 더 주고 싶을 때 고르는 선택지이며, **기본값이 틀린 것은 아니다** — 표·리스트는 테두리·라운드·헤더 줄과 간격을 이미 갖고 있어 흰 바탕에서도 경계가 읽힌다. 깔아도 **효과가 없는** 자리가 있다 — 덩어리가 가장자리까지 차는 경우(`padding="none"` 으로 표를 채우면 바탕이 완전히 가려진다), 덩어리에 회색 면이 섞인 경우(그 덩어리가 바탕에 묻힌다), 맨 텍스트나 폼 컨트롤만 있는 본문(떠오를 흰 면이 없다). |
22
+ | `children?` | `SSectionHeaderCardChildren` | — | 바디 콘텐츠. 특정 컴포넌트 타입으로 제한하지 않습니다. |
28
23
 
29
- ### SSectionHeaderCard
24
+ ## Types
30
25
 
31
- #### Props
26
+ ### SSectionHeaderCardTitleSize
32
27
 
33
- | Prop | Type | Default | Description |
34
- |------|------|---------|-------------|
35
- | `children?` | `SSectionHeaderCardChildren` | — | SSectionHeaderCard 슬롯. 특정 컴포넌트 타입으로 제한하지 않습니다. |
28
+ ```ts
29
+ export type SSectionHeaderCardTitleSize = 'xs' | 'sm';
30
+ ```
31
+
32
+ ### SSectionHeaderCardThickness
33
+
34
+ ```ts
35
+ export type SSectionHeaderCardThickness = false | 'default' | 'accent';
36
+ ```
37
+
38
+ ### SSectionHeaderCardBodyPadding
39
+
40
+ ```ts
41
+ export type SSectionHeaderCardBodyPadding = 'default' | 'wide' | 'none';
42
+ ```
43
+
44
+ ### SSectionHeaderCardBodyBackground
45
+
46
+ ```ts
47
+ export type SSectionHeaderCardBodyBackground = 'frame' | 'neutral';
48
+ ```
49
+
50
+ ### SSectionHeaderCardChildren
51
+
52
+ ```ts
53
+ export type SSectionHeaderCardChildren = ReactNode;
54
+ ```
36
55
 
37
56
  ## Dependencies
38
57
 
@@ -4,9 +4,10 @@ export type SSectionHeaderCardChildren = ReactNode;
4
4
  export type SSectionHeaderCardThickness = false | 'default' | 'accent';
5
5
  export type SSectionHeaderCardTitleSize = 'xs' | 'sm';
6
6
  export type SSectionHeaderCardBodyPadding = 'default' | 'wide' | 'none';
7
- export interface SSectionHeaderCardHeaderProps extends Omit<HTMLAttributes<HTMLDivElement>, 'slot' | 'title'> {
7
+ export type SSectionHeaderCardBodyBackground = 'frame' | 'neutral';
8
+ export interface SSectionHeaderCardProps extends Omit<HTMLAttributes<HTMLDivElement>, 'slot' | 'title'> {
8
9
  /** 헤더 제목 */
9
- title: ReactNode;
10
+ title?: ReactNode;
10
11
  /** 제목 크기 */
11
12
  titleSize?: SSectionHeaderCardTitleSize;
12
13
  /** 제목 앞 점 표시 여부 */
@@ -21,21 +22,27 @@ export interface SSectionHeaderCardHeaderProps extends Omit<HTMLAttributes<HTMLD
21
22
  slot?: ReactNode;
22
23
  /** 상단 border 색상 타입. false면 표시하지 않습니다. */
23
24
  thickness?: SSectionHeaderCardThickness;
24
- }
25
- export interface SSectionHeaderCardBodyProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children'> {
26
- /** 바디 슬롯. 특정 컴포넌트 타입으로 제한하지 않습니다. */
27
- children?: SSectionHeaderCardBodyChildren;
25
+ /** 헤더 영역 클래스 */
26
+ headerClassName?: string;
28
27
  /**
29
- * 안쪽 여백. 기본은 `default`.
28
+ * 바디 안쪽 여백. 기본은 `default`.
30
29
  * 성격이 다른 요소가 세 종류 이상 섞인 영역에만 `wide`, 표를 가장자리까지 채울 때만 `none`.
31
30
  */
32
31
  padding?: SSectionHeaderCardBodyPadding;
33
- }
34
- export interface SSectionHeaderCardProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title'> {
35
- /** SSectionHeaderCard 슬롯. 특정 컴포넌트 타입으로 제한하지 않습니다. */
32
+ /**
33
+ * 본문 배경. 기본은 `frame` — 카드가 깐 흰 면을 그대로 쓴다.
34
+ *
35
+ * `neutral` 은 바탕을 한 단계 눌러앉혀, 흰 면 덩어리(표·리스트)가 여럿일 때 그것들이
36
+ * **"면 위에 놓인 객체"로 읽히게** 한다. 위계를 한 단계 더 주고 싶을 때 고르는 선택지이며,
37
+ * **기본값이 틀린 것은 아니다** — 표·리스트는 테두리·라운드·헤더 줄과 간격을 이미 갖고 있어
38
+ * 흰 바탕에서도 경계가 읽힌다.
39
+ *
40
+ * 깔아도 **효과가 없는** 자리가 있다 — 덩어리가 가장자리까지 차는 경우(`padding="none"` 으로
41
+ * 표를 채우면 바탕이 완전히 가려진다), 덩어리에 회색 면이 섞인 경우(그 덩어리가 바탕에 묻힌다),
42
+ * 맨 텍스트나 폼 컨트롤만 있는 본문(떠오를 흰 면이 없다).
43
+ */
44
+ background?: SSectionHeaderCardBodyBackground;
45
+ /** 바디 콘텐츠. 특정 컴포넌트 타입으로 제한하지 않습니다. */
36
46
  children?: SSectionHeaderCardChildren;
37
47
  }
38
- export declare const SSectionHeaderCard: import("react").ForwardRefExoticComponent<SSectionHeaderCardProps & import("react").RefAttributes<HTMLDivElement>> & {
39
- Header: import("react").ForwardRefExoticComponent<SSectionHeaderCardHeaderProps & import("react").RefAttributes<HTMLDivElement>>;
40
- Body: import("react").ForwardRefExoticComponent<SSectionHeaderCardBodyProps & import("react").RefAttributes<HTMLDivElement>>;
41
- };
48
+ export declare const SSectionHeaderCard: import("react").ForwardRefExoticComponent<SSectionHeaderCardProps & import("react").RefAttributes<HTMLDivElement>>;
@@ -1 +1 @@
1
- export { SSectionHeaderCard, type SSectionHeaderCardBodyChildren, type SSectionHeaderCardBodyPadding, type SSectionHeaderCardBodyProps, type SSectionHeaderCardChildren, type SSectionHeaderCardHeaderProps, type SSectionHeaderCardProps, type SSectionHeaderCardThickness, type SSectionHeaderCardTitleSize, } from './SSectionHeaderCard';
1
+ export { SSectionHeaderCard, type SSectionHeaderCardBodyBackground, type SSectionHeaderCardBodyChildren, type SSectionHeaderCardBodyPadding, type SSectionHeaderCardChildren, type SSectionHeaderCardProps, type SSectionHeaderCardThickness, type SSectionHeaderCardTitleSize, } from './SSectionHeaderCard';
@@ -18,6 +18,7 @@
18
18
  | `allSelectedLabel?` | `string` | `'전체'` | 전체선택 레이블 |
19
19
  | `placeholder?` | `string` | `'선택'` | placeholder |
20
20
  | `disabled?` | `boolean` | `false` | 비활성 |
21
+ | `clearable?` | `boolean` | `false` | 선택값 지우기(×) 버튼 노출. 선택값이 있고 비활성이 아닐 때만 나타나며, 누르면 드롭다운을 열지 않고 값만 비운다. |
21
22
  | `error?` | `boolean` | `false` | 에러 상태 |
22
23
  | `rules?` | `Rule[]` | — | 유효성 규칙 — 닫힐 때 자동 검증 |
23
24
  | `labelTooltipProps?` | `Partial<STooltipProps>` | — | 레이블 툴팁 상세 옵션 |
@@ -33,7 +34,7 @@
33
34
  | `addonAlign?` | `SFieldAddonAlign` | — | 어드온 정렬 |
34
35
  | `hint?` | `string` | — | |
35
36
  | `errorMessage?` | `string` | — | |
36
- | `width?` | `number \| string` | — | |
37
+ | `width?` | `SFieldWidth` | — | 컨트롤 너비 — 폭 등급(`'xs' | 'sm' | 'md' | 'lg' | 'xl'`) · 숫자=px · CSS 길이. 등급은 `--cmp-field-width-*` 토큰으로 풀리므로 토큰이 바뀌면 화면이 따라간다. 값 길이에 상한이 없으면 `"100%"` 로 두어 행 전체를 쓴다. 셀렉트는 `maxLength` 개념이 없어 목록 최장값을 담는 등급으로 고른다. |
37
38
  | `className?` | `string` | — | |
38
39
  | `style?` | `CSSProperties` | — | |
39
40
 
@@ -51,28 +52,49 @@
51
52
  | `focus` | `() => void` | 트리거 버튼에 포커스 (sdFocus) |
52
53
  | `open` | `() => void` | 드롭다운 열기 (sdOpen) |
53
54
 
55
+ ## Types
56
+
57
+ ### SSelectOption
58
+
59
+ ```ts
60
+ export interface SSelectOption {
61
+ value: string | number;
62
+ label: string;
63
+ disabled?: boolean;
64
+ children?: SSelectOption[];
65
+ }
66
+ ```
67
+
68
+ ### SSelectType
69
+
70
+ ```ts
71
+ export type SSelectType = 'default' | 'multi' | 'default_depth' | 'multi_depth';
72
+ ```
73
+
54
74
  ## Dependencies
55
75
 
56
76
  ### Used by
57
77
 
78
+ - [SChipFilter](../SChipFilter)
58
79
  - [SKeyValueTable](../SKeyValueTable)
59
80
  - [STable](../STable)
60
81
 
61
82
  ### Depends on
62
83
 
63
84
  - [SField](../SField)
64
- - [SGhostButton](../SGhostButton)
65
85
  - [SIcon](../SIcon)
66
86
  - [SPortal](../SPortal)
87
+ - [SSearchInput](../SSearchInput)
67
88
 
68
89
  ### Graph
69
90
 
70
91
  ```mermaid
71
92
  graph TD;
72
93
  SSelect --> SField
73
- SSelect --> SGhostButton
74
94
  SSelect --> SIcon
75
95
  SSelect --> SPortal
96
+ SSelect --> SSearchInput
97
+ SChipFilter --> SSelect
76
98
  SKeyValueTable --> SSelect
77
99
  STable --> SSelect
78
100
  style SSelect fill:#f9f,stroke:#333,stroke-width:4px
@@ -5,6 +5,7 @@ import { type SIconName } from '../SIcon';
5
5
  import { type SColor } from '../../lib/color';
6
6
  import { type STooltipProps } from '../STooltip';
7
7
  import { type SSelectOption, type SSelectType } from './select.config';
8
+ import { type SFieldWidth } from '../../lib/field-width';
8
9
  export type { SSelectOption, SSelectType } from './select.config';
9
10
  export interface SSelectHandle {
10
11
  /** 트리거 버튼에 포커스 (sdFocus) */
@@ -37,6 +38,11 @@ export interface SSelectProps {
37
38
  placeholder?: string;
38
39
  /** 비활성 */
39
40
  disabled?: boolean;
41
+ /**
42
+ * 선택값 지우기(×) 버튼 노출. 선택값이 있고 비활성이 아닐 때만 나타나며,
43
+ * 누르면 드롭다운을 열지 않고 값만 비운다.
44
+ */
45
+ clearable?: boolean;
40
46
  /** 에러 상태 */
41
47
  error?: boolean;
42
48
  /** 유효성 규칙 — 닫힐 때 자동 검증 */
@@ -62,7 +68,13 @@ export interface SSelectProps {
62
68
  addonAlign?: SFieldAddonAlign;
63
69
  hint?: string;
64
70
  errorMessage?: string;
65
- width?: number | string;
71
+ /**
72
+ * 컨트롤 너비 — 폭 등급(`'xs' | 'sm' | 'md' | 'lg' | 'xl'`) · 숫자=px · CSS 길이.
73
+ * 등급은 `--cmp-field-width-*` 토큰으로 풀리므로 토큰이 바뀌면 화면이 따라간다.
74
+ * 값 길이에 상한이 없으면 `"100%"` 로 두어 행 전체를 쓴다.
75
+ * 셀렉트는 `maxLength` 개념이 없어 목록 최장값을 담는 등급으로 고른다.
76
+ */
77
+ width?: SFieldWidth;
66
78
  className?: string;
67
79
  style?: CSSProperties;
68
80
  }
@@ -25,3 +25,18 @@
25
25
  |-------|------|-------------|
26
26
  | `onValueChange` | `(value: number) => void` | 크기가 확정될 때. emitImmediately 가 아니면 드래그를 놓는 순간 한 번만 온다 |
27
27
 
28
+ ## Types
29
+
30
+ ### SSplitterUnit
31
+
32
+ ```ts
33
+ /** 모델·limits 를 읽는 단위. Quasar QSplitter 의 `unit` 과 같다. */
34
+ export type SSplitterUnit = (typeof SSPLITTER_UNITS)[number];
35
+ ```
36
+
37
+ ### SSPLITTER_UNITS
38
+
39
+ ```ts
40
+ export const SSPLITTER_UNITS = ['%', 'px'] as const;
41
+ ```
42
+
@@ -30,6 +30,32 @@
30
30
  | `showItemTooltip` | `() => void` | error 아이템 중 첫 번째에 툴팁을 연다. error 아이템이 없으면 아무 일도 일어나지 않는다. |
31
31
  | `hideItemTooltip` | `() => void` | 열려있는 커스텀 툴팁을 닫는다. 활성 단계(value prop)가 바뀌면 별도 호출 없이도 자동으로 닫힌다. |
32
32
 
33
+ ## Types
34
+
35
+ ### SStepperItem
36
+
37
+ ```ts
38
+ export type SStepperItem = {
39
+ label: string;
40
+ value?: string;
41
+ group?: string;
42
+ completed?: boolean;
43
+ error?: boolean;
44
+ };
45
+ ```
46
+
47
+ ### SStepperSize
48
+
49
+ ```ts
50
+ export type SStepperSize = (typeof STEPPER_SIZES)[number];
51
+ ```
52
+
53
+ ### STEPPER_SIZES
54
+
55
+ ```ts
56
+ export const STEPPER_SIZES = ['sm', 'lg'] as const;
57
+ ```
58
+
33
59
  ## Dependencies
34
60
 
35
61
  ### Depends on
@@ -22,3 +22,16 @@
22
22
  |-------|------|-------------|
23
23
  | `onValueChange` | `(value: boolean) => void` | 변경 (sdUpdate) |
24
24
 
25
+ ## Dependencies
26
+
27
+ ### Used by
28
+
29
+ - [SKeyValueTable](../SKeyValueTable)
30
+
31
+ ### Graph
32
+
33
+ ```mermaid
34
+ graph TD;
35
+ SKeyValueTable --> SSwitch
36
+ style SSwitch fill:#f9f,stroke:#333,stroke-width:4px
37
+ ```
@@ -13,20 +13,23 @@
13
13
  | `rowKey?` | `string` | `'id'` | 행 식별 필드 |
14
14
  | `selectable?` | `boolean` | `false` | 행 선택 체크박스 |
15
15
  | `selected?` | `SRow[]` | `[]` | |
16
+ | `sort?` | `STableSort \| null` | `null` | 정렬 상태 (controlled). `null`·미지정이면 정렬 없음. 컴포넌트는 정렬 상태를 갖지 않는다 — 서버 정렬이면 이 값이 곧 조회 조건이고, 뒤로가기·새로고침·링크 공유로 복원돼야 하므로 진실은 URL·store 쪽에 있어야 한다. 행을 실제로 정렬하는 것도 소비 앱 몫이다 (`STable` 은 받은 순서대로 그린다). |
16
17
  | `resizable?` | `boolean` | `false` | 컬럼 너비 조절 |
17
18
  | `width?` | `string` | — | |
18
19
  | `height?` | `string` | — | |
19
20
  | `stickyHeader?` | `boolean` | — | |
20
21
  | `stickyColumn?` | `STableStickyColumn` | — | 고정할 좌/우 컬럼 수 |
21
22
  | `radius?` | `'default' \| 'useTop' \| 'full'` | `'default'` | border-radius 제어 |
23
+ | `bordered?` | `boolean` | `true` | 바깥 테두리. 기본은 `true`. `SSectionHeaderCard` 의 `padding="none"` 안에 넣어 카드 가장자리까지 채울 때 `false` 로 끈다 — 카드가 이미 바깥 테두리를 그리므로, 켜 두면 1px 두 개가 나란히 놓여 그 변만 2px 로 보인다. 페이지네이션 바의 테두리와 1px 겹침(`-mt-px`)도 함께 꺼진다. 본문 테두리가 없으면 겹칠 대상이 없어, 그대로 두면 페이지네이션만 테두리를 갖고 1px 어긋난다. |
22
24
  | `noDataLabel?` | `string` | `'데이터가 없습니다.'` | |
23
25
  | `noDataSlot?` | `ReactNode` | — | 데이터가 없을 때 body 영역 전체를 대체하는 슬롯. 지정하면 `noDataLabel` 대신 이 콘텐츠가 헤더 아래 영역을 채우며, 버튼 등 인터랙션도 동작한다. |
24
26
  | `isLoading?` | `boolean` | `false` | |
25
- | `dense?` | `boolean` | `false` | |
27
+ | `dense?` | `boolean` | `false` | 행 높이를 좁게 (세로 여백만 줄인다 — 좌우 패딩은 그대로) |
26
28
  | `noHover?` | `boolean` | `false` | true면 행에 마우스를 올려도 hover 배경(grey_05)을 표시하지 않는다 |
27
29
  | `pagination?` | `STablePagination` | — | 페이지네이션 (있으면 하단 표시) |
28
30
  | `useInternalPagination?` | `boolean` | `false` | 테이블 내부에서 페이지네이션을 직접 관리 (rows를 내부 슬라이싱) |
29
31
  | `useRowsPerPageSelect?` | `boolean` | `false` | 페이지당 행 수 셀렉트 표시 |
32
+ | `useDensityToggle?` | `boolean` | `false` | 페이지네이션 바에 밀도 토글(`좁게 보기` · `넓게 보기`) 표시. **페이지네이션이 있을 때만 나타난다** — 토글이 사는 곳이 그 바이기 때문이다. `onDenseChange` 와 함께 준다. 밀도는 컴포넌트가 갖지 않으므로, 핸들러 없이 켜면 눌러도 아무 일도 일어나지 않는다. |
30
33
  | `rowsPerPageOption?` | `SSelectOption[]` | `DEFAULT_ROWS_PER_PAGE_OPTION` | |
31
34
  | `useVirtualScroll?` | `boolean` | `false` | 가상 스크롤 |
32
35
  | `rowHeight?` | `number` | — | |
@@ -41,6 +44,8 @@
41
44
  | Event | Type | Description |
42
45
  |-------|------|-------------|
43
46
  | `onSelectedChange` | `(rows: SRow[]) => void` | |
47
+ | `onSortChange` | `(sort: STableSort \| null) => void` | 정렬 헤더 클릭 (`asc → desc → 해제` 3단). 해제되면 `null` 이 온다. 다중 정렬은 1차 안에서 지원하지 않는다. |
48
+ | `onDenseChange` | `(dense: boolean) => void` | 밀도 변경 (`useDensityToggle` 로 띄운 토글을 눌렀을 때). 컴포넌트는 밀도 상태를 갖지 않는다 — `dense` 가 곧 현재 상태이고, 그 진실은 페이지에 있다. 사용자가 고른 밀도를 다음 방문까지 기억해 두는 것(로컬 저장 등)도 페이지 몫이다. |
44
49
  | `onPageChange` | `(page: number) => void` | |
45
50
  | `onRowsPerPageChange` | `(perPage: number) => void` | |
46
51
  | `onVirtualUpdate` | `(range: { from: number; to: number }) => void` | |
@@ -59,15 +64,77 @@
59
64
  | `updateRowSelect` | `(row: SRow) => void` | 단일 행 선택 토글 (sd-table updateRowSelect) — onSelectedChange 발생 |
60
65
  | `toggleSelectAll` | `(checked: boolean, rows: SRow[]) => void` | 주어진 행들 전체 선택/해제 (sd-table toggleSelectAll) — onSelectedChange 발생 |
61
66
 
67
+ ## Types
68
+
69
+ ### STableColumn
70
+
71
+ ```ts
72
+ /**
73
+ * `autoWidth` 스페이서 열은 값을 그리지 않으므로 `field` 를 생략할 수 있다.
74
+ * 그 밖의 열은 값 접근자가 있어야 한다.
75
+ */
76
+ export type STableColumn = STableColumnBase &
77
+ (
78
+ { autoWidth: true; field?: STableColumnField } | { autoWidth?: false; field: STableColumnField }
79
+ );
80
+ ```
81
+
82
+ ### SRow
83
+
84
+ ```ts
85
+ export type SRow = Record<string, any>;
86
+ ```
87
+
88
+ ### STableSort
89
+
90
+ ```ts
91
+ /** 정렬 상태 — 어느 열을 어느 방향으로 정렬했는가 */
92
+ export interface STableSort {
93
+ /** 정렬 기준 컬럼의 `name` */
94
+ name: string;
95
+ dir: 'asc' | 'desc';
96
+ }
97
+ ```
98
+
99
+ ### STableStickyColumn
100
+
101
+ ```ts
102
+ export interface STableStickyColumn {
103
+ left?: number;
104
+ right?: number;
105
+ }
106
+ ```
107
+
108
+ ### STablePagination
109
+
110
+ ```ts
111
+ export interface STablePagination {
112
+ page: number;
113
+ rowsPerPage: number;
114
+ lastPage?: number;
115
+ }
116
+ ```
117
+
118
+ ### STableColumnField
119
+
120
+ ```ts
121
+ /** 값 접근: 필드명 또는 접근 함수 */
122
+ export type STableColumnField = string | ((row: SRow) => any);
123
+ ```
124
+
62
125
  ## Dependencies
63
126
 
64
127
  ### Depends on
65
128
 
66
129
  - [SCheckbox](../SCheckbox)
67
130
  - [SCircleProgress](../SCircleProgress)
131
+ - [SDivider](../SDivider)
132
+ - [SGhostButton](../SGhostButton)
68
133
  - [SIcon](../SIcon)
69
134
  - [SPagination](../SPagination)
70
135
  - [SSelect](../SSelect)
136
+ - [STextLink](../STextLink)
137
+ - [STooltip](../STooltip)
71
138
 
72
139
  ### Graph
73
140
 
@@ -75,8 +142,12 @@
75
142
  graph TD;
76
143
  STable --> SCheckbox
77
144
  STable --> SCircleProgress
145
+ STable --> SDivider
146
+ STable --> SGhostButton
78
147
  STable --> SIcon
79
148
  STable --> SPagination
80
149
  STable --> SSelect
150
+ STable --> STextLink
151
+ STable --> STooltip
81
152
  style STable fill:#f9f,stroke:#333,stroke-width:4px
82
153
  ```