@bigtablet/design-system 3.30.2 → 3.31.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.
@@ -19,6 +19,15 @@ $tap_target_compact: 40px; // 데스크탑 기본
19
19
  $tap_target_comfortable: 48px; // 모바일/터치 기본 (44 초과)
20
20
  $tap_target_spacious: 56px; // 강조 CTA, 풀스크린 액션
21
21
 
22
+ // ── Control height (의미 alias) ─────────────────────────────────────────
23
+ // 컨트롤·아바타처럼 크기 단계가 있는 요소는 픽셀을 직접 쓰지 말고 이 단계를 참조한다.
24
+ // 값은 위 tap target 과 같다 - 이름만 "크기 단계" 로 읽히게 붙인 것이라 responsive_height 의
25
+ // 승급 규칙(sm→md→lg→xl)도 그대로 맞물린다.
26
+ $control_height_sm: $tap_target_dense; // 32
27
+ $control_height_md: $tap_target_compact; // 40
28
+ $control_height_lg: $tap_target_comfortable; // 48
29
+ $control_height_xl: $tap_target_spacious; // 56
30
+
22
31
  // ── Responsive height mixin ─────────────────────────────────────────────
23
32
  // 데스크탑 height 기준으로 compact breakpoint(<600px)에서 한 단계 키움.
24
33
  // 명시적으로 $mobile 지정 시 그 값을 사용.
@@ -170,6 +170,12 @@ Reach for an inline style only when the value is genuinely dynamic (computed at
170
170
  // ✓ OK - --bt-color-* IS emitted by the React entry's style.css
171
171
  <div style={{ background: "var(--bt-color-bg-solid-dim)" }} />
172
172
 
173
+ // ✓ Same, typed - cssVars mirrors colors / elevation / a11y focus rings as var() strings
174
+ <div style={{ background: cssVars.colors.bg.solidDim, boxShadow: cssVars.elevation.level2 }} />
175
+
176
+ // ✗ Avoid - colors.* / elevation.* are fixed light values and stay light in dark mode
177
+ <div style={{ background: colors.bg.solidDim }} />
178
+
173
179
  // ✗ Never - hardcoded hex breaks dark mode
174
180
  <div style={{ background: "#F2F5F8" }} />
175
181
 
@@ -233,14 +239,18 @@ Organized by category. **Always** import from the package root (`@bigtablet/desi
233
239
  |-----------|---------|-----------|
234
240
  | `Button` | Primary action button. | `variant` (filled/outline/tonal/text), `size` (sm/md/lg/xl), `danger`, `radius`, `leadingIcon`, `trailingIcon`, `fullWidth` |
235
241
  | `IconButton` | Icon-only button. | `variant` (standard/filled/tonal/outlined), `size` (sm/md), `icon`, `aria-label` (required) |
242
+ | `CopyButton` | Copy-to-clipboard button: shows "copied" for 2s and announces via hidden `role="status"`. Hook: `useClipboard()` → `{ copy, status, error, reset }`; `copyText()` one-shot. Falls back to `execCommand` (in-app browsers, http). | `text` (string or fn), `label`/`copiedLabel`/`failedLabel`, `iconOnly` (label = accessible name), `size`, `variant`, `resetAfter`, `onCopy`, `onError`. |
236
243
  | `TextField` | Single-line text input with label. | `label`, `placeholder`, `supportingText`, `error`, `size`, `leadingIcon`/`trailingIcon` (decorative only - `aria-hidden`), `leadingAction`/`trailingAction` (focusable content), `showPasswordToggle` + `passwordToggleLabels` (app-injected i18n), `clearable`, `onValueChange`, `imeStrategy` (delayed/immediate - use `immediate` for live search w/ Korean IME) |
237
244
  | `Textarea` | Multi-line text input. | `label`, `placeholder`, `supportingText`, `error`, `size`, `rows`, `minRows`/`maxRows` (auto-grow), `maxLength` + `showCounter`, `resize` (none/vertical/both), `onChangeAction`, `imeStrategy`. Same tokens/visuals as TextField. |
238
245
  | `Checkbox` | Boolean selection. | `checked`, `indeterminate`, `disabled`, `error`, `label` |
239
246
  | `Radio` | Single choice. | `value`, `checked`, `name`, `size`, `label`. Standalone, or auto-wired inside `RadioGroup`. |
240
247
  | `RadioGroup` | Groups `Radio`s via Context. | `value`/`defaultValue`/`onValueChange`, `name` (auto), `label`, `supportingText`, `error`, `size`, `orientation` (vertical/horizontal), `disabled`. Children = `Radio value=...`. |
248
+ | `SegmentedControl` | One value from 2-5 short options on one line (currency, locale, period). Not for panel switching (use `Tabs`). | `items` (`{ value, label?, icon?, ariaLabel?, disabled? }[]`), `value`/`defaultValue`/`onValueChange` (generic `T extends string`), `size` (sm/md), `fullWidth`, `disabled`, `required`, `name`. Needs `aria-label` or a `Field`. |
249
+ | `FilterBar` | List-page filter form: field grid + Enter submit + search/reset buttons. Holds no filter state. | `children` (fields), `onSubmit`, `onReset` (shows reset), `canSubmit`, `canReset`, `loading`, `disabled`, `submitLabel`/`resetLabel`, `fieldMinWidth` (default 200). Renders `<form role="search">` - give it `aria-label`. Fits `DataView` `toolbar.filters`. |
241
250
  | `Toggle` | On/off switch. | `checked`, `size` (sm/md), `disabled` |
242
251
  | `Dropdown` | Value-selection menu. | `options`, `value`, `onChange`, `label`, `supportingText`, `placeholder`, `size`. Block-level - fills parent. |
243
252
  | `DatePicker` | Year/month/day select. | `value`, `onChange`, `mode` (year-month/year-month-day), `min`, `max`, `fullWidth` |
253
+ | `DateCalendar` | Standalone month calendar (single date). Also the DatePicker calendar popover. | Values are `"YYYY-MM-DD"` strings (month `"YYYY-MM"`) - no time zone. `value`/`defaultValue`/`onValueChange`, `month`/`defaultMonth`/`onMonthChange`, `min`/`max`, `isDateDisabled`, `today`, `weekStartsOn`, `renderDay` (decoration, aria-hidden) + `describeDay` (adds meaning to the accessible name). |
244
254
  | `FileInput` | File upload. | `variant` (button/preview), `multiple`, `accept`, `onFiles`, `previewSize` (for preview variant), `disabled` |
245
255
  | `OTPInput` | Single-digit code boxes. | `length`, `value`, `onChange`, `autoFocus`, `error` |
246
256
 
@@ -265,7 +275,9 @@ Organized by category. **Always** import from the package root (`@bigtablet/desi
265
275
  | Component | Purpose | Key props |
266
276
  |-----------|---------|-----------|
267
277
  | `Alert` (via `useAlert`) | Confirm/alert dialog. | `showAlert({ title, message, variant, showCancel, destructive, onConfirm, onCancel })` |
278
+ | `useConfirm` | Promise-based confirm on the same `AlertProvider`. | `const ok = await confirm({ title, message, variant, destructive, confirmText, cancelText, onConfirm })` → `true` on confirm, `false` on cancel/Escape/overlay (exactly once). A new confirm replaces an open one (old → `false`). Async `onConfirm` keeps it open with a spinner and blocks double submit; reject keeps it open for retry. |
268
279
  | `Toast` (via `useToast`) | Transient notification. | `toast.success("...")` / `.error(...)` / `.warning(...)` / `.info(...)` / `.message(...)`. Second arg = duration ms. |
280
+ | `InlineAlert` | Persistent in-page notice (expiring plan, maintenance, dev env, save result). Not transient (`Toast`) or confirm (`AlertProvider`). | `tone` (neutral/info/success/warning/error), `title`, `children`, `icon` (`null` hides), `action`, `onDismiss` (shows close button; parent removes it), `dismissLabel`. No live region by default - pass `role="status"`/`role="alert"` only when it appears later. |
269
281
  | `Spinner` | Inline loading indicator. | `size` (px), `ariaLabel`. Vercel-style 12-bar fade. |
270
282
  | `TopLoading` | Top-of-page progress bar. | `progress` (0-100, or undefined for indeterminate), `height`, `color`, `isLoading`, `ariaLabel` |
271
283
  | `LinearProgress` | Step progress with dots. | `totalSteps`, `currentStep`, `aria-label`. Renders N+1 checkpoints. |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bigtablet/design-system",
3
- "version": "3.30.2",
3
+ "version": "3.31.0",
4
4
  "description": "Bigtablet Design System UI Components",
5
5
  "type": "module",
6
6
  "types": "dist/index.d.ts",