@bestow-ui/react 0.10.0 → 0.12.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.
- package/README.md +30 -12
- package/dist/index.cjs +2097 -731
- package/dist/index.cjs.map +1 -1
- package/dist/index.css +1092 -754
- package/dist/index.css.map +1 -1
- package/dist/index.d.cts +480 -39
- package/dist/index.d.ts +480 -39
- package/dist/index.js +2066 -721
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -3,12 +3,17 @@
|
|
|
3
3
|
[](https://www.npmjs.com/package/@bestow-ui/react)
|
|
4
4
|
[](https://github.com/Dev-BestOW/BestOW-UI/blob/main/LICENSE)
|
|
5
5
|
|
|
6
|
-
React
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
- **
|
|
10
|
-
|
|
11
|
-
- **
|
|
6
|
+
**A React design system for building Korean services — with accessibility you can verify.**
|
|
7
|
+
Built on [vanilla-extract](https://vanilla-extract.style) and [Radix UI](https://www.radix-ui.com).
|
|
8
|
+
|
|
9
|
+
- **Korean service kit** — terms agreement (agree-to-all), SMS verification code (one-time-code autofill, countdown), phone / business registration
|
|
10
|
+
number (checksum) / amount (Korean reading like “12만 5,000원”), address (Kakao postcode), and a date picker (Sunday-first, holidays).
|
|
11
|
+
- **Accessibility, tested** — every story is rendered in a real browser and checked with axe in both light and dark themes on CI.
|
|
12
|
+
Item-by-item notes for KWCAG 2.2 (the Korean web accessibility standard), plus a log of real issues the checks caught.
|
|
13
|
+
- **One brand color → accessible theme** — brand colors keep 4.5:1 text contrast (including hover) and a 3:1 focus ring, light and dark.
|
|
14
|
+
Try the [Theme Builder](https://dev-bestow.github.io/BestOW-UI/?path=/story/foundations-theme-builder--builder).
|
|
15
|
+
- **Zero-runtime CSS & RSC-friendly** — works with the Next.js App Router; tree-shakable (a single `Button` is about 1.5 kB, minified + brotli).
|
|
16
|
+
- **Korean by default, any language** — default UI strings are Korean; switch them all with `LocaleProvider` (English included).
|
|
12
17
|
|
|
13
18
|
📖 **Docs & live examples:** [Storybook](https://dev-bestow.github.io/BestOW-UI/) · [Next.js example app](https://dev-bestow.github.io/BestOW-UI/playground/)
|
|
14
19
|
|
|
@@ -41,7 +46,7 @@ export function App() {
|
|
|
41
46
|
|
|
42
47
|
function SaveButton() {
|
|
43
48
|
const { toast } = useToast();
|
|
44
|
-
return <Button onClick={() => toast({ title: 'Saved',
|
|
49
|
+
return <Button onClick={() => toast({ title: 'Saved', color: 'success' })}>Save</Button>;
|
|
45
50
|
}
|
|
46
51
|
```
|
|
47
52
|
|
|
@@ -78,6 +83,16 @@ All tokens are plain CSS variables with stable names, so you can also override t
|
|
|
78
83
|
}
|
|
79
84
|
```
|
|
80
85
|
|
|
86
|
+
## Locale
|
|
87
|
+
|
|
88
|
+
Default UI strings (close buttons, "no results", calendar labels, …) are Korean. Switch them all with `LocaleProvider`:
|
|
89
|
+
|
|
90
|
+
```tsx
|
|
91
|
+
import { LocaleProvider, en } from '@bestow-ui/react';
|
|
92
|
+
|
|
93
|
+
<LocaleProvider messages={en}>…</LocaleProvider>
|
|
94
|
+
```
|
|
95
|
+
|
|
81
96
|
## Components
|
|
82
97
|
|
|
83
98
|
| Category | Components |
|
|
@@ -90,6 +105,8 @@ All tokens are plain CSS variables with stable names, so you can also override t
|
|
|
90
105
|
| Overlays | `Modal`, `Drawer`, `Popover`, `Tooltip`, `DropdownMenu` |
|
|
91
106
|
| Navigation | `Tabs`, `Accordion`, `Pagination`, `Breadcrumb` |
|
|
92
107
|
| Display | `Avatar`, `Table` |
|
|
108
|
+
| Korean kit | `AgreementGroup` (약관 동의), `VerificationCodeInput` (인증번호), `PhoneNumberInput`, `BusinessNumberInput`, `AmountInput`, `AddressInput`, `DatePicker`, `Calendar` (+ `formatPhoneNumber`, `formatBusinessNumber`, `isValidBusinessNumber`, `formatKoreanAmount`, `formatKoreanDate`, `parseISODate`, `toISODate`) |
|
|
109
|
+
| Locale | `LocaleProvider`, `en` (English messages) |
|
|
93
110
|
| Theming | `ThemeProvider`, `createTheme`, `createIntentColors`, `vars`, `useTheme`, `usePortalProps` |
|
|
94
111
|
|
|
95
112
|
## Links
|
|
@@ -106,12 +123,13 @@ All tokens are plain CSS variables with stable names, so you can also override t
|
|
|
106
123
|
|
|
107
124
|
## 한국어
|
|
108
125
|
|
|
109
|
-
|
|
126
|
+
**한국 서비스를 만들 때 바로 쓰는, 접근성이 검증된 React 디자인 시스템**이에요.
|
|
110
127
|
|
|
111
|
-
-
|
|
112
|
-
-
|
|
113
|
-
-
|
|
114
|
-
-
|
|
128
|
+
- **한국 서비스 키트** — 약관 동의, 인증번호(문자 자동 채우기·남은 시간), 전화번호·사업자등록번호·금액·주소·날짜 입력.
|
|
129
|
+
- **검사로 증명하는 접근성** — 모든 스토리를 라이트·다크에서 axe 로 검사(CI), [KWCAG 2.2 항목별 대응 근거](https://dev-bestow.github.io/BestOW-UI/?path=/docs/accessibility-kwcag-2-2-%EB%8C%80%EC%9D%91--docs).
|
|
130
|
+
- **대표색 하나로 테마** — 브랜드 색을 넣어도 대비 기준을 자동으로 지켜요. [테마 빌더](https://dev-bestow.github.io/BestOW-UI/?path=/story/foundations-theme-builder--builder)
|
|
131
|
+
- **가벼움** — 런타임 CSS 0, 서버 컴포넌트 지원, 쓰는 컴포넌트만 번들에.
|
|
132
|
+
- **다국어** — 기본 문구는 한국어, `LocaleProvider` 로 한 번에 바꿔요.
|
|
115
133
|
|
|
116
134
|
```bash
|
|
117
135
|
npm install @bestow-ui/react
|