@xfilecom/front-core 0.2.28 → 0.2.31
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 +10 -0
- package/dist/base.css +717 -0
- package/dist/components/atoms/Accordion.d.ts +18 -0
- package/dist/components/atoms/Accordion.js +68 -0
- package/dist/components/atoms/Alert.d.ts +12 -0
- package/dist/components/atoms/Alert.js +24 -0
- package/dist/components/atoms/AspectRatio.d.ts +8 -0
- package/dist/components/atoms/AspectRatio.js +10 -0
- package/dist/components/atoms/Avatar.d.ts +22 -0
- package/dist/components/atoms/Avatar.js +32 -0
- package/dist/components/atoms/Breadcrumb.d.ts +15 -0
- package/dist/components/atoms/Breadcrumb.js +27 -0
- package/dist/components/atoms/Collapsible.d.ts +12 -0
- package/dist/components/atoms/Collapsible.js +42 -0
- package/dist/components/atoms/Label.d.ts +8 -0
- package/dist/components/atoms/Label.js +10 -0
- package/dist/components/atoms/Pagination.d.ts +13 -0
- package/dist/components/atoms/Pagination.js +25 -0
- package/dist/components/atoms/Progress.d.ts +8 -0
- package/dist/components/atoms/Progress.js +9 -0
- package/dist/components/atoms/RadioGroup.d.ts +15 -0
- package/dist/components/atoms/RadioGroup.js +37 -0
- package/dist/components/atoms/ScrollArea.d.ts +8 -0
- package/dist/components/atoms/ScrollArea.js +15 -0
- package/dist/components/atoms/Separator.d.ts +10 -0
- package/dist/components/atoms/Separator.js +17 -0
- package/dist/components/atoms/Skeleton.d.ts +6 -0
- package/dist/components/atoms/Skeleton.js +15 -0
- package/dist/components/atoms/Slider.d.ts +4 -0
- package/dist/components/atoms/Slider.js +9 -0
- package/dist/components/atoms/Switch.d.ts +10 -0
- package/dist/components/atoms/Switch.js +12 -0
- package/dist/components/atoms/Table.d.ts +20 -0
- package/dist/components/atoms/Table.js +38 -0
- package/dist/components/atoms/Tabs.d.ts +20 -0
- package/dist/components/atoms/Tabs.js +54 -0
- package/dist/components/atoms/Toggle.d.ts +8 -0
- package/dist/components/atoms/Toggle.js +23 -0
- package/dist/components/atoms/Tooltip.d.ts +10 -0
- package/dist/components/atoms/Tooltip.js +12 -0
- package/dist/components/atoms/index.d.ts +22 -3
- package/dist/components/atoms/index.js +76 -7
- package/dist/generatedVersion.d.ts +1 -1
- package/dist/generatedVersion.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +51 -1
- package/dist/showcase/DesignSystemShowcase.d.ts +2 -0
- package/dist/showcase/DesignSystemShowcase.js +19 -0
- package/dist/showcase/ShowcaseContext.d.ts +48 -0
- package/dist/showcase/ShowcaseContext.js +117 -0
- package/dist/showcase/components/CodeBlock.d.ts +7 -0
- package/dist/showcase/components/CodeBlock.js +11 -0
- package/dist/showcase/components/SectionTitle.d.ts +4 -0
- package/dist/showcase/components/SectionTitle.js +8 -0
- package/dist/showcase/components/ShowcaseChrome.d.ts +2 -0
- package/dist/showcase/components/ShowcaseChrome.js +25 -0
- package/dist/showcase/components/ShowcaseDemo.d.ts +10 -0
- package/dist/showcase/components/ShowcaseDemo.js +9 -0
- package/dist/showcase/components/icons.d.ts +2 -0
- package/dist/showcase/components/icons.js +11 -0
- package/dist/showcase/index.d.ts +4 -0
- package/dist/showcase/index.js +10 -0
- package/dist/showcase/nav.d.ts +26 -0
- package/dist/showcase/nav.js +13 -0
- package/dist/showcase/sections/ActionsSection.d.ts +1 -0
- package/dist/showcase/sections/ActionsSection.js +24 -0
- package/dist/showcase/sections/FeedbackSection.d.ts +1 -0
- package/dist/showcase/sections/FeedbackSection.js +17 -0
- package/dist/showcase/sections/FormsSection.d.ts +1 -0
- package/dist/showcase/sections/FormsSection.js +20 -0
- package/dist/showcase/sections/LayoutSection.d.ts +1 -0
- package/dist/showcase/sections/LayoutSection.js +19 -0
- package/dist/showcase/sections/OverlaysSection.d.ts +1 -0
- package/dist/showcase/sections/OverlaysSection.js +25 -0
- package/dist/showcase/sections/OverviewSection.d.ts +1 -0
- package/dist/showcase/sections/OverviewSection.js +17 -0
- package/dist/showcase/sections/SurfacesSection.d.ts +1 -0
- package/dist/showcase/sections/SurfacesSection.js +38 -0
- package/dist/showcase/sections/TypographySection.d.ts +1 -0
- package/dist/showcase/sections/TypographySection.js +24 -0
- package/dist/showcase.css +235 -0
- package/docs/COMPONENTS.md +26 -0
- package/docs/SHADCN.md +66 -0
- package/package.json +8 -3
|
@@ -0,0 +1,235 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @xfilecom/front-core — 디자인 시스템 쇼케이스 (npm: @xfilecom/front-core/showcase.css)
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
.xfc-ds {
|
|
6
|
+
display: flex;
|
|
7
|
+
align-items: flex-start;
|
|
8
|
+
gap: var(--xfc-space-xl);
|
|
9
|
+
max-width: 1180px;
|
|
10
|
+
margin: 0 auto;
|
|
11
|
+
padding: 0 var(--xfc-space-lg) var(--xfc-space-2xl);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.xfc-ds-nav {
|
|
15
|
+
position: sticky;
|
|
16
|
+
top: var(--xfc-space-md);
|
|
17
|
+
flex: 0 0 200px;
|
|
18
|
+
max-height: calc(100dvh - var(--xfc-space-xl));
|
|
19
|
+
overflow: auto;
|
|
20
|
+
padding: var(--xfc-space-md);
|
|
21
|
+
border-radius: var(--xfc-radius-md);
|
|
22
|
+
background: var(--xfc-bg-elevated);
|
|
23
|
+
border: 1px solid var(--xfc-border);
|
|
24
|
+
box-shadow: var(--xfc-shadow-xs);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.xfc-ds-nav-title {
|
|
28
|
+
margin: 0 0 var(--xfc-space-sm);
|
|
29
|
+
font-size: var(--xfc-text-small);
|
|
30
|
+
font-weight: 700;
|
|
31
|
+
color: var(--xfc-fg-muted);
|
|
32
|
+
text-transform: uppercase;
|
|
33
|
+
letter-spacing: 0.06em;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.xfc-ds-nav-list {
|
|
37
|
+
margin: 0;
|
|
38
|
+
padding: 0;
|
|
39
|
+
list-style: none;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.xfc-ds-nav-list li {
|
|
43
|
+
margin: 0;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.xfc-ds-nav-link {
|
|
47
|
+
display: block;
|
|
48
|
+
padding: var(--xfc-space-xs) var(--xfc-space-sm);
|
|
49
|
+
margin: 2px 0;
|
|
50
|
+
font-size: var(--xfc-text-small);
|
|
51
|
+
font-weight: 500;
|
|
52
|
+
color: var(--xfc-fg-label);
|
|
53
|
+
text-decoration: none;
|
|
54
|
+
border-radius: var(--xfc-radius-xs);
|
|
55
|
+
transition: background 0.15s ease, color 0.15s ease;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.xfc-ds-nav-link:hover {
|
|
59
|
+
background: var(--xfc-accent-soft);
|
|
60
|
+
color: var(--xfc-accent);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.xfc-ds-main {
|
|
64
|
+
flex: 1 1 0;
|
|
65
|
+
min-width: 0;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.xfc-ds-section {
|
|
69
|
+
scroll-margin-top: var(--xfc-space-xl);
|
|
70
|
+
margin-bottom: var(--xfc-space-2xl);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.xfc-ds-section-head {
|
|
74
|
+
margin-bottom: var(--xfc-space-md);
|
|
75
|
+
padding-bottom: var(--xfc-space-sm);
|
|
76
|
+
border-bottom: 1px solid var(--xfc-border);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.xfc-ds-section-lead {
|
|
80
|
+
margin: 0 0 var(--xfc-space-lg);
|
|
81
|
+
font-size: var(--xfc-text-small);
|
|
82
|
+
line-height: 1.55;
|
|
83
|
+
color: var(--xfc-fg-muted);
|
|
84
|
+
max-width: 52rem;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.xfc-ds-demo-grid {
|
|
88
|
+
display: grid;
|
|
89
|
+
gap: var(--xfc-space-lg);
|
|
90
|
+
margin-top: var(--xfc-space-md);
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
@media (min-width: 720px) {
|
|
94
|
+
.xfc-ds-demo-grid--2 {
|
|
95
|
+
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.xfc-ds-demo {
|
|
100
|
+
margin-bottom: var(--xfc-space-lg);
|
|
101
|
+
border: 1px solid var(--xfc-border);
|
|
102
|
+
border-radius: var(--xfc-radius-md);
|
|
103
|
+
background: var(--xfc-bg-elevated);
|
|
104
|
+
box-shadow: var(--xfc-shadow-xs);
|
|
105
|
+
overflow: hidden;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.xfc-ds-demo:last-child {
|
|
109
|
+
margin-bottom: 0;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.xfc-ds-demo__header {
|
|
113
|
+
padding: var(--xfc-space-md) var(--xfc-space-lg);
|
|
114
|
+
border-bottom: 1px solid var(--xfc-border);
|
|
115
|
+
background: linear-gradient(180deg, var(--xfc-bg-muted) 0%, var(--xfc-bg-elevated) 100%);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.xfc-ds-demo__title {
|
|
119
|
+
margin: 0;
|
|
120
|
+
font-size: var(--xfc-text-small);
|
|
121
|
+
font-weight: 700;
|
|
122
|
+
letter-spacing: 0.02em;
|
|
123
|
+
color: var(--xfc-fg-label);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.xfc-ds-demo__desc {
|
|
127
|
+
margin-top: var(--xfc-space-xs);
|
|
128
|
+
font-size: var(--xfc-text-small);
|
|
129
|
+
line-height: 1.5;
|
|
130
|
+
color: var(--xfc-fg-muted);
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.xfc-ds-demo__preview {
|
|
134
|
+
padding: var(--xfc-space-lg);
|
|
135
|
+
background: var(--xfc-bg);
|
|
136
|
+
min-height: 3rem;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
.xfc-ds-demo__details {
|
|
140
|
+
border-top: 1px solid var(--xfc-border);
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.xfc-ds-demo__summary {
|
|
144
|
+
list-style: none;
|
|
145
|
+
cursor: pointer;
|
|
146
|
+
padding: var(--xfc-space-sm) var(--xfc-space-lg);
|
|
147
|
+
font-size: var(--xfc-text-small);
|
|
148
|
+
font-weight: 600;
|
|
149
|
+
color: var(--xfc-accent);
|
|
150
|
+
background: var(--xfc-bg-elevated);
|
|
151
|
+
transition: background 0.15s ease;
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
.xfc-ds-demo__summary::-webkit-details-marker {
|
|
155
|
+
display: none;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
.xfc-ds-demo__summary::before {
|
|
159
|
+
content: '';
|
|
160
|
+
display: inline-block;
|
|
161
|
+
width: 0.35em;
|
|
162
|
+
height: 0.35em;
|
|
163
|
+
margin-right: var(--xfc-space-sm);
|
|
164
|
+
border-right: 2px solid currentColor;
|
|
165
|
+
border-bottom: 2px solid currentColor;
|
|
166
|
+
transform: rotate(-45deg);
|
|
167
|
+
vertical-align: 0.15em;
|
|
168
|
+
transition: transform 0.2s ease;
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
details[open] > .xfc-ds-demo__summary::before {
|
|
172
|
+
transform: rotate(45deg);
|
|
173
|
+
vertical-align: 0.05em;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.xfc-ds-demo__summary:hover {
|
|
177
|
+
background: var(--xfc-accent-soft);
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
.xfc-ds-demo__code {
|
|
181
|
+
padding: 0 var(--xfc-space-lg) var(--xfc-space-lg);
|
|
182
|
+
background: var(--xfc-bg-muted);
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
.xfc-ds-code-wrap--embedded .xfc-ds-code {
|
|
186
|
+
margin-top: var(--xfc-space-sm);
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
.xfc-ds-code-wrap .xfc-ds-code-caption {
|
|
190
|
+
margin-top: var(--xfc-space-sm);
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
.xfc-ds-code {
|
|
194
|
+
margin: var(--xfc-space-md) 0 0;
|
|
195
|
+
padding: var(--xfc-space-md) var(--xfc-space-lg);
|
|
196
|
+
font-family: var(--xfc-font-mono);
|
|
197
|
+
font-size: 0.8125rem;
|
|
198
|
+
line-height: 1.5;
|
|
199
|
+
color: var(--xfc-fg-label);
|
|
200
|
+
background: var(--xfc-bg-muted);
|
|
201
|
+
border: 1px solid var(--xfc-border);
|
|
202
|
+
border-radius: var(--xfc-radius-sm);
|
|
203
|
+
overflow-x: auto;
|
|
204
|
+
white-space: pre-wrap;
|
|
205
|
+
word-break: break-word;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
.xfc-ds-code-caption {
|
|
209
|
+
margin: 0 0 var(--xfc-space-xs);
|
|
210
|
+
font-size: var(--xfc-text-small);
|
|
211
|
+
font-weight: 600;
|
|
212
|
+
color: var(--xfc-fg-muted);
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
.xfc-ds-paper-row {
|
|
216
|
+
display: flex;
|
|
217
|
+
flex-wrap: wrap;
|
|
218
|
+
gap: var(--xfc-space-md);
|
|
219
|
+
align-items: flex-start;
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
@media (max-width: 840px) {
|
|
223
|
+
.xfc-ds {
|
|
224
|
+
flex-direction: column;
|
|
225
|
+
padding-inline: var(--xfc-space-md);
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
.xfc-ds-nav {
|
|
229
|
+
position: relative;
|
|
230
|
+
top: 0;
|
|
231
|
+
flex: none;
|
|
232
|
+
width: 100%;
|
|
233
|
+
max-height: none;
|
|
234
|
+
}
|
|
235
|
+
}
|
package/docs/COMPONENTS.md
CHANGED
|
@@ -94,6 +94,32 @@ import { Card, Button } from '@xfilecom/front-core';
|
|
|
94
94
|
|
|
95
95
|
커스텀 모달에 동일한 스크롤 잠금·포커스 트랩을 쓰려면 [overlayHooks.ts](../src/components/overlays/overlayHooks.ts)의 `useFocusTrap`, `useBodyScrollLock`, `useEscapeKey`를 루트에서 import 한다.
|
|
96
96
|
|
|
97
|
+
## shadcn/ui 스타일 원자
|
|
98
|
+
|
|
99
|
+
[SHADCN.md](./SHADCN.md)에 **전체 매핑표**(캘린더·콤보박스 등 앱 의존 항목 포함)가 있다. 아래는 패키지에 포함된 대응 컴포넌트 요약.
|
|
100
|
+
|
|
101
|
+
| 이름 | 소스 |
|
|
102
|
+
|------|------|
|
|
103
|
+
| `Separator` | [atoms/Separator.tsx](../src/components/atoms/Separator.tsx) |
|
|
104
|
+
| `Skeleton` | [atoms/Skeleton.tsx](../src/components/atoms/Skeleton.tsx) |
|
|
105
|
+
| `Label` | [atoms/Label.tsx](../src/components/atoms/Label.tsx) |
|
|
106
|
+
| `Switch` | [atoms/Switch.tsx](../src/components/atoms/Switch.tsx) |
|
|
107
|
+
| `Progress` | [atoms/Progress.tsx](../src/components/atoms/Progress.tsx) |
|
|
108
|
+
| `Tabs` · `TabsList` · `TabsTrigger` · `TabsContent` | [atoms/Tabs.tsx](../src/components/atoms/Tabs.tsx) |
|
|
109
|
+
| `Accordion` · … | [atoms/Accordion.tsx](../src/components/atoms/Accordion.tsx) |
|
|
110
|
+
| `Alert` · `AlertTitle` · `AlertDescription` | [atoms/Alert.tsx](../src/components/atoms/Alert.tsx) |
|
|
111
|
+
| `Avatar` · `AvatarImage` · `AvatarFallback` · `AvatarAuto` | [atoms/Avatar.tsx](../src/components/atoms/Avatar.tsx) |
|
|
112
|
+
| `Breadcrumb` · … | [atoms/Breadcrumb.tsx](../src/components/atoms/Breadcrumb.tsx) |
|
|
113
|
+
| `Table` · … | [atoms/Table.tsx](../src/components/atoms/Table.tsx) |
|
|
114
|
+
| `ScrollArea` | [atoms/ScrollArea.tsx](../src/components/atoms/ScrollArea.tsx) |
|
|
115
|
+
| `Toggle` | [atoms/Toggle.tsx](../src/components/atoms/Toggle.tsx) |
|
|
116
|
+
| `RadioGroup` · `RadioGroupItem` | [atoms/RadioGroup.tsx](../src/components/atoms/RadioGroup.tsx) |
|
|
117
|
+
| `AspectRatio` | [atoms/AspectRatio.tsx](../src/components/atoms/AspectRatio.tsx) |
|
|
118
|
+
| `Tooltip` | [atoms/Tooltip.tsx](../src/components/atoms/Tooltip.tsx) |
|
|
119
|
+
| `Collapsible` · … | [atoms/Collapsible.tsx](../src/components/atoms/Collapsible.tsx) |
|
|
120
|
+
| `Slider` | [atoms/Slider.tsx](../src/components/atoms/Slider.tsx) |
|
|
121
|
+
| `Pagination` · … | [atoms/Pagination.tsx](../src/components/atoms/Pagination.tsx) |
|
|
122
|
+
|
|
97
123
|
## CSS
|
|
98
124
|
|
|
99
125
|
| 파일 | 용도 |
|
package/docs/SHADCN.md
ADDED
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# shadcn/ui 대응표
|
|
2
|
+
|
|
3
|
+
[shadcn/ui](https://ui.shadcn.com/)는 **Radix UI + Tailwind** 기반의 복사-붙여넣기 컴포넌트 모음이다. `@xfilecom/front-core`는 **Radix·Tailwind 없이** 동일한 **역할·이름에 가까운** API를 토큰(`--xfc-*`) + `base.css`로 제공한다. 고급 포지셔닝(드롭다운 앵커, 날짜 그리드 등)은 앱에서 전용 라이브러리를 쓰는 것을 권장한다.
|
|
4
|
+
|
|
5
|
+
## 컴포넌트 매핑
|
|
6
|
+
|
|
7
|
+
| shadcn | front-core | 비고 |
|
|
8
|
+
|--------|------------|------|
|
|
9
|
+
| Accordion | `Accordion`, `AccordionItem`, `AccordionTrigger`, `AccordionContent` | single 전용; multiple는 추후 확장 가능 |
|
|
10
|
+
| Alert | `Alert`, `AlertTitle`, `AlertDescription` | |
|
|
11
|
+
| Alert Dialog | `ConfirmDialog` | 문구·버튼 props로 조합 |
|
|
12
|
+
| Aspect Ratio | `AspectRatio` | |
|
|
13
|
+
| Avatar | `Avatar`, `AvatarImage`, `AvatarFallback`, `AvatarAuto` | 이미지+대체는 `AvatarAuto` 권장 |
|
|
14
|
+
| Badge | `Badge` | tone API는 shadcn과 다름 |
|
|
15
|
+
| Breadcrumb | `Breadcrumb`, `BreadcrumbList`, … | |
|
|
16
|
+
| Button | `Button` | variant 이름 다름 (`primary` 등) |
|
|
17
|
+
| Calendar | — | 앱에서 `react-day-picker` 등 |
|
|
18
|
+
| Card | `Card`, `Paper` | `Card`는 헤더/푸터 패턴 |
|
|
19
|
+
| Carousel | — | 앱에서 embla 등 |
|
|
20
|
+
| Chart | — | 앱에서 recharts 등 |
|
|
21
|
+
| Checkbox | `Checkbox` | |
|
|
22
|
+
| Collapsible | `Collapsible`, `CollapsibleTrigger`, `CollapsibleContent` | |
|
|
23
|
+
| Combobox | — | `Select` + 앱 로직 또는 외부 라이브러리 |
|
|
24
|
+
| Command | — | 앱에서 cmdk 등 |
|
|
25
|
+
| Context Menu | — | 앱에서 Radix 등 |
|
|
26
|
+
| Data Table | `Table` + 앱 | 정렬·페이지네이션은 앱 상태 |
|
|
27
|
+
| Date Picker | — | 앱에서 date 라이브러리 |
|
|
28
|
+
| Dialog | `Dialog` | |
|
|
29
|
+
| Drawer | `BottomSheet` | 모바일 퍼스트 시트 |
|
|
30
|
+
| Dropdown Menu | — | 앱에서 Radix Menu 등 |
|
|
31
|
+
| Form | `Field` + 앱 검증 | react-hook-form 등과 조합 |
|
|
32
|
+
| Hover Card | — | `Tooltip` 단순 버전 또는 Radix |
|
|
33
|
+
| Input | `Input` | |
|
|
34
|
+
| Input OTP | — | 앱 전용 |
|
|
35
|
+
| Label | `Label` | `Field`와 병행 가능 |
|
|
36
|
+
| Menubar | — | |
|
|
37
|
+
| Navigation Menu | — | |
|
|
38
|
+
| Pagination | `Pagination`, `PaginationContent`, `PaginationLink`, … | |
|
|
39
|
+
| Popover | — | `Dialog` 소형 또는 Radix |
|
|
40
|
+
| Progress | `Progress` | |
|
|
41
|
+
| Radio Group | `RadioGroup`, `RadioGroupItem` | |
|
|
42
|
+
| Resizable | — | |
|
|
43
|
+
| Scroll Area | `ScrollArea` | 네이티브 스크롤 |
|
|
44
|
+
| Select | `Select` | 네이티브 `<select>` 스타일 |
|
|
45
|
+
| Separator | `Separator` | |
|
|
46
|
+
| Sheet | `BottomSheet` / `Dialog` | |
|
|
47
|
+
| Skeleton | `Skeleton` | |
|
|
48
|
+
| Slider | `Slider` | 네이티브 `range` |
|
|
49
|
+
| Sonner / Toast | `Toast`, `ToastList` | |
|
|
50
|
+
| Switch | `Switch` | |
|
|
51
|
+
| Table | `Table`, `TableHeader`, `TableBody`, … | |
|
|
52
|
+
| Tabs | `Tabs`, `TabsList`, `TabsTrigger`, `TabsContent` | |
|
|
53
|
+
| Textarea | `Textarea` | |
|
|
54
|
+
| Toggle | `Toggle` | |
|
|
55
|
+
| Toggle Group | — | `Toggle` 여러 개 + 앱 상태 |
|
|
56
|
+
| Tooltip | `Tooltip` | 인라인 단순 툴팁 |
|
|
57
|
+
|
|
58
|
+
## 스타일·접근성
|
|
59
|
+
|
|
60
|
+
- 포커스 링: `base.css`의 `--xfc-focus-ring` 계열.
|
|
61
|
+
- 다크: `tokens.css` — `html.dark` / `data-theme="dark"`.
|
|
62
|
+
- shadcn과 **클래스 이름은 다름** — 마이그레이션 시 JSX만 교체하고 앱 `app.css`에서 보정한다.
|
|
63
|
+
|
|
64
|
+
## 소스 위치
|
|
65
|
+
|
|
66
|
+
신규 원자는 `src/components/atoms/*.tsx` (예: `Tabs.tsx`, `Table.tsx`). 스타일은 `src/base.css`의 **shadcn/ui-style primitives** 블록.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xfilecom/front-core",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.31",
|
|
4
4
|
"description": "Shared design tokens, base CSS, and atomic React components (browser-only; no Nest dependency)",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -18,7 +18,12 @@
|
|
|
18
18
|
"./overlays": {
|
|
19
19
|
"types": "./dist/components/overlays/index.d.ts",
|
|
20
20
|
"default": "./dist/components/overlays/index.js"
|
|
21
|
-
}
|
|
21
|
+
},
|
|
22
|
+
"./showcase": {
|
|
23
|
+
"types": "./dist/showcase/index.d.ts",
|
|
24
|
+
"default": "./dist/showcase/index.js"
|
|
25
|
+
},
|
|
26
|
+
"./showcase.css": "./dist/showcase.css"
|
|
22
27
|
},
|
|
23
28
|
"files": [
|
|
24
29
|
"dist",
|
|
@@ -29,7 +34,7 @@
|
|
|
29
34
|
"prepublishOnly": "npm run build",
|
|
30
35
|
"build": "node scripts/write-version.js && npm run build:ts && npm run build:css",
|
|
31
36
|
"build:ts": "tsc",
|
|
32
|
-
"build:css": "cp src/tokens.css dist/tokens.css && cp src/base.css dist/base.css"
|
|
37
|
+
"build:css": "cp src/tokens.css dist/tokens.css && cp src/base.css dist/base.css && cp src/showcase/showcase.css dist/showcase.css"
|
|
33
38
|
},
|
|
34
39
|
"peerDependencies": {
|
|
35
40
|
"react": ">=18.0.0",
|