# @hyeonse/design-system Installed package version: 0.5.0 ## Setup - Import @hyeonse/design-system/tokens.css before @hyeonse/design-system/components.css, once each. - Run preferenceScript or createPreferenceScript(...) in the document head before CSS paints; match storageKey and defaults with PreferencesProvider. - Import utilities from /preferences, display settings from /react, existing primitives from /primitives, expanded forms from /fields, menus and dialogs from /overlays, navigation/feedback from /display, and size scopes and layouts from /layout. Do not import internal src/ or dist/ paths. - Interactive React components require React and React DOM 19. The package uses Base UI 1.9.0 for accessible interaction foundations. - Provide DM Sans and Noto Sans KR font assets in the consuming app if those faces are needed; the package only declares a font stack. ## Provided - Role tokens in tokens.css and styles for display settings, forms, overlays, navigation, layout, and feedback in components.css. - Preference validation, first-paint script, provider, hook, and display-setting controls. - Button, TextField, Checkbox, and Badge React components with native element attributes and refs. - Reusable input and selection controls, menus, dialogs, tooltips, toast notifications, navigation, tables, cards, and feedback components. ## Not provided - An application router, server data fetching, rich-text editor, chart engine, or virtualized data grid. - Font files for consuming applications; provide fonts with the required character coverage separately. - A design-token interchange format such as DTCG. Generated from the package declarations, CSS and authored usage metadata. Do not edit this output. Props summaries contain locally declared props; module declarations preserve inherited native attributes and refs. # API ## preferencesKey Default localStorage key: hyeonse-site-preferences. Kind: utility · Import: `@hyeonse/design-system/preferences` ```typescript export declare const preferencesKey = "hyeonse-site-preferences"; ``` ### Usage - Pass the same key to createPreferenceScript and PreferencesProvider when overriding it. Examples: `hds example display-settings` ## defaultPreferences Default choices: system theme, cobalt accent, comfortable density, crisp corners, full motion. Kind: utility · Import: `@hyeonse/design-system/preferences` ```typescript export declare const defaultPreferences: Preferences; ``` ### Usage - Use as the baseline when no valid stored choice or site default exists. ### States - system - cobalt - comfortable - crisp - full ### Limits - This constant does not include site-specific defaults. Examples: `hds example display-settings` ## validatePreferences Validate each preference against the allowed choices. Kind: utility · Import: `@hyeonse/design-system/preferences` ```typescript export declare function validatePreferences(value: unknown, defaults?: Partial): Preferences; ``` ### Usage - A valid stored field wins; missing or invalid fields use valid site defaults, then defaultPreferences. ### States - system/light/dark - cobalt/forest/coral - comfortable/compact - crisp/soft - full/reduced ### Limits - Non-object and array inputs are treated as empty preferences. Examples: `hds example display-settings` ## parsePreferences Parse and validate a stored JSON preference string. Kind: utility · Import: `@hyeonse/design-system/preferences` ```typescript export declare function parsePreferences(raw: string | null, defaults?: Partial): Preferences; ``` ### Usage - Malformed JSON and null fall back through validatePreferences with optional site defaults. Examples: `hds example display-settings` ## serializePreferences Serialize validated preferences to JSON. Kind: utility · Import: `@hyeonse/design-system/preferences` ```typescript export declare function serializePreferences(value: Preferences): string; ``` ### Usage - Invalid fields fall back to package defaults before serialization. ### Limits - This function does not accept site-specific defaults. Examples: `hds example display-settings` ## resolvedTheme Resolve system/light/dark to the effective light or dark theme. Kind: utility · Import: `@hyeonse/design-system/preferences` ```typescript export declare function resolvedTheme(theme: ThemePreference, systemDark: boolean): 'light' | 'dark'; ``` ### Usage - The system choice follows the supplied systemDark boolean. ### States - light - dark Examples: `hds example display-settings` ## effectiveMotion Resolve the motion choice with the device reduced-motion preference. Kind: utility · Import: `@hyeonse/design-system/preferences` ```typescript export declare function effectiveMotion(motion: MotionPreference, systemReduced: boolean): MotionPreference; ``` ### Usage - A true systemReduced value forces reduced even when the stored choice is full. ### States - full - reduced ### Accessibility - Device reduced motion takes precedence. Examples: `hds example display-settings` ## createPreferenceScript Create the inline first-paint preference script with optional key and site defaults. Kind: utility · Import: `@hyeonse/design-system/preferences` ```typescript export declare function createPreferenceScript(storageKey?: string, defaults?: Partial): string; ``` ### Usage - Insert the result in the document head before CSS paints. - Pass the same storageKey and defaults to PreferencesProvider. ### States - Sets data-theme, data-theme-preference, data-accent, data-density, data-corners, and data-motion on the document root. ### Accessibility - Applies the device reduced-motion preference. ### Limits - The generated script reads storage and media preferences once; PreferencesProvider handles later changes. Examples: `hds example display-settings` ## preferenceScript Ready-made first-paint script using the package key and defaults. Kind: utility · Import: `@hyeonse/design-system/preferences` ```typescript export declare const preferenceScript: string; ``` ### Usage - Insert in the document head before CSS paints. ### Accessibility - Applies the device reduced-motion preference. ### Limits - Use createPreferenceScript for a different key or site defaults. Examples: `hds example display-settings` ## PreferencesProvider Provide display preferences and keep document attributes in sync. Kind: provider · Import: `@hyeonse/design-system/react` ```typescript export declare function PreferencesProvider({ children, storageKey, eventName, defaults }: { children: ReactNode; storageKey?: string; eventName?: string; defaults?: Partial; }): import("react").JSX.Element; ``` ### Locally declared props - `children`: `ReactNode` - `storageKey?`: `string` - `eventName?`: `string` - `defaults?`: `Partial` ### Usage - Wrap consumers of usePreferences, ThemeToggle, and PreferencesPanel. - The defaults prop supplies valid site defaults for missing or invalid stored fields and reset. ### States - Reads storage on mount; listens for matching-key or cleared storage events and device color/motion changes. - Updates this tab and dispatches the configured CustomEvent after applying document attributes. ### Accessibility - The device reduced-motion preference overrides a full-motion choice. ### Limits - Storage writes may fail; the current tab still updates. - Server rendering starts with validated defaults before browser storage is read. Examples: `hds example display-settings` ## usePreferences Read preferences and the setPreference/resetPreferences actions from context. Kind: hook · Import: `@hyeonse/design-system/react` ```typescript export declare function usePreferences(): PreferenceContext; ``` ### Usage - Call inside PreferencesProvider. - resetPreferences restores the validated site defaults. ### Limits - Throws when used outside PreferencesProvider. Examples: `hds example display-settings` ## ThemeToggle Cycle theme preference through system, light, and dark. Kind: component · Import: `@hyeonse/design-system/react` ```typescript export declare function ThemeToggle({ locale }: { locale?: Locale; }): import("react").JSX.Element; ``` ### Locally declared props - `locale?`: `Locale` ### Usage - Render inside PreferencesProvider; locale defaults to ko and also accepts en. - Import components.css for the provided visual styles. ### States - system - light - dark ### Accessibility - Native button with a changing accessible label describing current and next modes. ### Limits - Only theme preference is changed; the effective theme still follows the device in system mode. Examples: `hds example display-settings` ## PreferencesPanel Display controls for theme, accent, density, corners, and motion. Kind: component · Import: `@hyeonse/design-system/react` ```typescript export declare function PreferencesPanel({ locale }: { locale?: Locale; }): import("react").JSX.Element; ``` ### Locally declared props - `locale?`: `Locale` ### Usage - Render inside PreferencesProvider; locale defaults to ko and also accepts en. - Import components.css for the provided visual styles. ### States - system/light/dark - cobalt/forest/coral - comfortable/compact - crisp/soft - full/reduced ### Accessibility - Uses fieldset legends, native radio inputs, pressed-state accent buttons, and a live status. ### Limits - It controls only the provided display preferences. Examples: `hds example display-settings` ## Button Native button with primary, secondary, and ghost visual variants. Kind: component · Import: `@hyeonse/design-system/primitives` ```typescript export declare function Button({ variant, size, loading, loadingLabel, type, disabled, className, children, ref, 'aria-busy': ariaBusy, 'aria-label': ariaLabel, 'aria-labelledby': ariaLabelledBy, ...props }: ButtonProps): import("react").JSX.Element; ``` ### Locally declared props - `variant?`: `'primary' | 'secondary' | 'ghost'` - `size?`: `HdsSize` - `loading?`: `boolean` - `loadingLabel?`: `string` ### Usage - Import from @hyeonse/design-system/primitives and import components.css after tokens.css. - Native button attributes and ref are forwarded; type defaults to button. The caller manages loading state. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - primary/secondary/ghost variants - xs/sm/md/lg/xl sizes; inherited md default - enabled/disabled/loading ### Accessibility - Native button keyboard behavior. - Loading disables the button, sets aria-busy, and uses loadingLabel as visible and accessible text when supplied. ### Limits - Loading does not start or track an asynchronous operation. - Renders a button element, not a link. Examples: `hds example form-controls` ## TextField Labeled single-line input with optional hint and error text. Kind: component · Import: `@hyeonse/design-system/primitives` ```typescript export declare function TextField({ label, hint, error, size, inputSize, type, id, className, disabled, ref, 'aria-describedby': ariaDescribedBy, 'aria-invalid': ariaInvalid, ...props }: TextFieldProps): import("react").JSX.Element; ``` ### Locally declared props - `size?`: `HdsSize` - `inputSize?`: `number` - `label`: `string` - `type?`: `TextInputType` - `hint?`: `string` - `error?`: `string` ### Usage - Import from @hyeonse/design-system/primitives and import components.css after tokens.css. - Native input attributes and ref are forwarded; className applies to the input element. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - text/email/password/search/tel/url types - enabled/disabled/readOnly - hint/error ### Accessibility - The label targets the supplied id or a generated id. - Hint and error IDs are added to aria-describedby alongside a caller-supplied description; an error sets aria-invalid. ### Limits - Single-line input only; the caller owns validation and error messages. Examples: `hds example form-controls` ## Checkbox Labeled native checkbox with optional hint and error text. Kind: component · Import: `@hyeonse/design-system/primitives` ```typescript export declare function Checkbox({ label, hint, error, size, inputSize, id, className, disabled, readOnly, ref, onClick, onChange, 'aria-describedby': ariaDescribedBy, 'aria-invalid': ariaInvalid, 'aria-readonly': ariaReadOnly, ...props }: CheckboxProps): import("react").JSX.Element; ``` ### Locally declared props - `size?`: `HdsSize` - `inputSize?`: `number` - `label`: `string` - `hint?`: `string` - `error?`: `string` ### Usage - Import from @hyeonse/design-system/primitives and import components.css after tokens.css. - Native checkbox attributes, checked/defaultChecked, and ref are forwarded; className applies to the input element. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - checked/unchecked - enabled/disabled/readOnly - hint/error ### Accessibility - The label targets the supplied id or a generated id. - Hint and error IDs are added to aria-describedby alongside a caller-supplied description; an error sets aria-invalid. - readOnly exposes aria-readonly and prevents click changes while retaining focus. ### Limits - A checkbox has no native readOnly behavior; the component cancels clicks to preserve its value. - The caller owns validation and error messages. Examples: `hds example form-controls` ## Badge Noninteractive span badge for a short status or category. Kind: component · Import: `@hyeonse/design-system/primitives` ```typescript export declare function Badge({ size, tone, className, children, ref, ...props }: BadgeProps): import("react").JSX.Element; ``` ### Locally declared props - `size?`: `HdsSize` - `tone?`: `'neutral' | 'accent' | 'success' | 'warning' | 'danger'` ### Usage - Import from @hyeonse/design-system/primitives and import components.css after tokens.css. - Native span attributes and ref are forwarded; include text that communicates the status without color alone. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - neutral/accent/success/warning/danger tones ### Accessibility - Renders a span with its text content; tone alone does not announce meaning. ### Limits - No interaction or live-region behavior is added. Examples: `hds example form-controls` ## Input Styled native single-line input for custom compositions. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function Input({ type, size, inputSize, className, ref, ...props }: InputProps): import("react").JSX.Element; ``` ### Locally declared props - `type?`: `TextualType` - `size?`: `HdsSize` - `inputSize?`: `number` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - text/email/search/tel/url - disabled/readOnly/required - controlled/uncontrolled ### Accessibility - Provide an associated label or aria-label at the call site. - Native input semantics and ref are retained. ### Limits - No built-in label or error message; use a labeled field when those are needed. Examples: `hds example expanded-forms` ## Textarea Labeled native multiline input with hint and error. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function Textarea({ label, hint, error, size, id, className, disabled, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid, ...props }: TextareaProps): import("react").JSX.Element; ``` ### Locally declared props - `label`: `string` - `hint?`: `string` - `error?`: `string` - `size?`: `HdsSize` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - enabled/disabled/readOnly - hint/error - controlled/uncontrolled ### Accessibility - Label, hint, and error are linked with unique IDs; error sets aria-invalid. - Native textarea ref and form behavior remain available. ### Limits - The caller sets rows, maxLength, and validation rules. Examples: `hds example expanded-forms` ## Select Labeled single-choice dropdown from fixed options. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function Select({ label, hint, error, size, options, name, form, id, required, disabled, readOnly, value, defaultValue, onValueChange, placeholder, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid }: SelectProps): import("react").JSX.Element; ``` ### Locally declared props - `label`: `string` - `hint?`: `string` - `error?`: `string` - `size?`: `HdsSize` - `options`: `readonly FieldOption[]` - `name?`: `string` - `form?`: `string` - `id?`: `string` - `required?`: `boolean` - `disabled?`: `boolean` - `readOnly?`: `boolean` - `value?`: `string | null` - `defaultValue?`: `string | null` - `onValueChange?`: `(value: string | null) => void` - `placeholder?`: `string` - `className?`: `string` - `aria-describedby?`: `string` - `aria-invalid?`: `boolean | 'grammar' | 'spelling'` - `ref?`: `Ref` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - empty/selected - enabled/disabled/readOnly - required - hint/error ### Accessibility - Base UI manages listbox keyboard navigation, option states, and form submission. - Visible label names the trigger; hint and error describe it. ### Limits - Options are not searchable; use Combobox for filtering. - Option values must be unique strings. Examples: `hds example expanded-forms` ## NativeSelect Labeled browser-native single-choice picker for fixed options. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function NativeSelect({ label, hint, error, size, options, name, form, id, required, disabled, value, defaultValue, onValueChange, placeholder, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid }: NativeSelectProps): import("react").JSX.Element; ``` ### Locally declared props - `form?`: `string` - `label`: `string` - `size?`: `HdsSize` - `disabled?`: `boolean` - `name?`: `string` - `placeholder?`: `string` - `required?`: `boolean` - `value?`: `string | null` - `defaultValue?`: `string | null` - `className?`: `string` - `id?`: `string` - `aria-describedby?`: `string` - `aria-invalid?`: `boolean | 'grammar' | 'spelling'` - `hint?`: `string` - `error?`: `string` - `options`: `readonly FieldOption[]` - `onValueChange?`: `(value: string | null) => void` - `ref?`: `Ref` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - empty/selected - enabled/disabled - required - hint/error - controlled/uncontrolled ### Accessibility - The native select uses the browser and screen reader picker without Base UI focus guards. - Visible label, hint, and error are linked to the control. ### Limits - Option values must be unique nonempty strings; empty string is reserved for the placeholder. - Native select has no readOnly mode, and picker appearance follows the browser and operating system. Examples: `hds example expanded-forms` ## Combobox Searchable single-choice field restricted to supplied options. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function Combobox({ label, hint, error, size, options, name, form, id, required, disabled, readOnly, value, defaultValue, onValueChange, placeholder, emptyText, openLabel, inputValue, defaultInputValue, onInputValueChange, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid }: ComboboxProps): import("react").JSX.Element; ``` ### Locally declared props - `label`: `string` - `hint?`: `string` - `error?`: `string` - `size?`: `HdsSize` - `options`: `readonly FieldOption[]` - `name?`: `string` - `form?`: `string` - `id?`: `string` - `required?`: `boolean` - `disabled?`: `boolean` - `readOnly?`: `boolean` - `value?`: `string | null` - `defaultValue?`: `string | null` - `onValueChange?`: `(value: string | null) => void` - `placeholder?`: `string` - `className?`: `string` - `aria-describedby?`: `string` - `aria-invalid?`: `boolean | 'grammar' | 'spelling'` - `ref?`: `Ref` - `emptyText?`: `string` - `openLabel?`: `string` - `inputValue?`: `string` - `defaultInputValue?`: `string` - `onInputValueChange?`: `(value: string) => void` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - query/empty/selected - enabled/disabled/readOnly - required - hint/error ### Accessibility - Base UI manages combobox navigation, announcements, and form submission. - Search input has a visible label; the open button has a configurable accessible name. ### Limits - Typed text is a query, not a free-form submitted value. - Option values must be unique strings. Examples: `hds example expanded-forms` ## MultiSelect Searchable multiple-choice field with removable selected chips. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function MultiSelect({ label, hint, error, size, options, name, form, id, required, disabled, readOnly, value, defaultValue, onValueChange, placeholder, emptyText, openLabel, selectedLabel, removeLabel, chipDescription, inputDescription, inputValue, defaultInputValue, onInputValueChange, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid }: MultiSelectProps): import("react").JSX.Element; ``` ### Locally declared props - `form?`: `string` - `label`: `string` - `size?`: `HdsSize` - `disabled?`: `boolean` - `name?`: `string` - `placeholder?`: `string` - `readOnly?`: `boolean` - `required?`: `boolean` - `className?`: `string` - `id?`: `string` - `aria-describedby?`: `string` - `aria-invalid?`: `boolean | 'grammar' | 'spelling'` - `hint?`: `string` - `error?`: `string` - `options`: `readonly FieldOption[]` - `ref?`: `Ref` - `value?`: `readonly string[]` - `defaultValue?`: `readonly string[]` - `onValueChange?`: `(value: string[]) => void` - `emptyText?`: `string` - `openLabel?`: `string` - `selectedLabel?`: `string` - `removeLabel?`: `(label: string) => string` - `chipDescription?`: `string` - `inputDescription?`: `(count: number) => string` - `inputValue?`: `string` - `defaultInputValue?`: `string` - `onInputValueChange?`: `(value: string) => void` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - query/empty/multiple selections - enabled/disabled/readOnly - required - hint/error ### Accessibility - Base UI manages selection, chip keyboard behavior, and form values. - Selected set, removal, and keyboard hints have configurable accessible strings. ### Limits - Typed text is a query, not a free-form submitted value. - Option values must be unique strings. Examples: `hds example expanded-forms` ## Switch Labeled binary switch with native form participation. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function Switch({ label, hint, error, size, id, name, form, value, uncheckedValue, required, disabled, readOnly, checked, defaultChecked, onCheckedChange, ref, className, 'aria-describedby': describedBy, 'aria-invalid': invalid }: SwitchProps): import("react").JSX.Element; ``` ### Locally declared props - `label`: `string` - `hint?`: `string` - `error?`: `string` - `size?`: `HdsSize` - `id?`: `string` - `name?`: `string` - `form?`: `string` - `value?`: `string` - `uncheckedValue?`: `string` - `required?`: `boolean` - `disabled?`: `boolean` - `readOnly?`: `boolean` - `checked?`: `boolean` - `defaultChecked?`: `boolean` - `onCheckedChange?`: `(checked: boolean) => void` - `ref?`: `Ref` - `className?`: `string` - `aria-describedby?`: `string` - `aria-invalid?`: `boolean | 'grammar' | 'spelling'` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - A controlled checked value is preserved when reading FormData immediately after form.reset(). - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - on/off - enabled/disabled/readOnly - required - hint/error ### Accessibility - Base UI provides switch semantics and keyboard interaction. - Visible text and optional descriptions communicate state without color alone. ### Limits - An unchecked switch submits no value unless uncheckedValue is supplied. Examples: `hds example expanded-forms` ## RadioGroup Labeled set of mutually exclusive choices. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function RadioGroup({ label, hint, error, size, options, name, form, required, disabled, readOnly, value, defaultValue, onValueChange, ref, className, 'aria-describedby': describedBy, 'aria-invalid': invalid }: RadioGroupProps): import("react").JSX.Element; ``` ### Locally declared props - `label`: `string` - `hint?`: `string` - `error?`: `string` - `size?`: `HdsSize` - `options`: `readonly FieldOption[]` - `name?`: `string` - `form?`: `string` - `required?`: `boolean` - `disabled?`: `boolean` - `readOnly?`: `boolean` - `value?`: `string` - `defaultValue?`: `string` - `onValueChange?`: `(value: string) => void` - `ref?`: `Ref` - `className?`: `string` - `aria-describedby?`: `string` - `aria-invalid?`: `boolean | 'grammar' | 'spelling'` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - A controlled selection is preserved when reading FormData immediately after form.reset(). - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - empty/selected - enabled/disabled/readOnly - required - hint/error ### Accessibility - Base UI provides radio keyboard navigation and form participation. - The group is named by visible label and described by hint or error. ### Limits - Option values must be unique strings. Examples: `hds example expanded-forms` ## Slider Labeled native single-value range input. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function Slider({ label, hint, error, size, inputSize, id, disabled, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid, ...props }: SliderProps): import("react").JSX.Element; ``` ### Locally declared props - `label`: `string` - `hint?`: `string` - `error?`: `string` - `size?`: `HdsSize` - `inputSize?`: `number` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - min/max/step - enabled/disabled - controlled/uncontrolled - hint/error ### Accessibility - Native range keyboard behavior and form value. - Label, hint, and error are linked; provide aria-valuetext for a nonnumeric meaning. ### Limits - Single thumb only; no readonly mode or dual-ended range. Examples: `hds example expanded-forms` ## NumberField Labeled numeric entry with increment and decrement controls. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function NumberField({ label, hint, error, size, id, name, form, required, disabled, readOnly, value, defaultValue, onValueChange, min, max, step, locale, placeholder, incrementLabel, decrementLabel, ref, className, 'aria-describedby': describedBy, 'aria-invalid': invalid }: NumberFieldProps): import("react").JSX.Element; ``` ### Locally declared props - `label`: `string` - `hint?`: `string` - `error?`: `string` - `size?`: `HdsSize` - `id?`: `string` - `name?`: `string` - `form?`: `string` - `required?`: `boolean` - `disabled?`: `boolean` - `readOnly?`: `boolean` - `value?`: `number | null` - `defaultValue?`: `number` - `onValueChange?`: `(value: number | null) => void` - `min?`: `number` - `max?`: `number` - `step?`: `number | 'any'` - `locale?`: `Intl.LocalesArgument` - `placeholder?`: `string` - `incrementLabel?`: `string` - `decrementLabel?`: `string` - `ref?`: `Ref` - `className?`: `string` - `aria-describedby?`: `string` - `aria-invalid?`: `boolean | 'grammar' | 'spelling'` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - empty/value - min/max/step - enabled/disabled/readOnly - hint/error ### Accessibility - Base UI provides numeric keyboard controls, bounds, and form participation. - Step buttons have configurable accessible labels. ### Limits - Returns number or null, not a formatted text string. Examples: `hds example expanded-forms` ## DateField Labeled native date input. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function DateField({ label, hint, error, size, inputSize, id, disabled, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid, ...props }: DateFieldProps): import("react").JSX.Element; ``` ### Locally declared props - `label`: `string` - `hint?`: `string` - `error?`: `string` - `size?`: `HdsSize` - `inputSize?`: `number` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - empty/date - min/max - enabled/disabled/readOnly - hint/error ### Accessibility - Native date control and form submission. - Label, hint, and error are linked with unique IDs. ### Limits - Picker appearance and date presentation follow the browser and operating system. Examples: `hds example expanded-forms` ## FileInput Labeled native file picker. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function FileInput({ label, hint, error, size, inputSize, id, disabled, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid, ...props }: FileInputProps): import("react").JSX.Element; ``` ### Locally declared props - `label`: `string` - `hint?`: `string` - `error?`: `string` - `size?`: `HdsSize` - `inputSize?`: `number` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - empty/files - accept/multiple - enabled/disabled - hint/error ### Accessibility - Native file picker and form submission. - Label, hint, and error are linked with unique IDs. ### Limits - File input values are browser-managed and cannot be controlled with value/defaultValue; use form reset to clear. - No readonly mode. Examples: `hds example expanded-forms` ## PasswordField Labeled password input with a show or hide button. Kind: component · Import: `@hyeonse/design-system/fields` ```typescript export declare function PasswordField({ label, hint, error, size, inputSize, id, disabled, className, ref, showLabel, hideLabel, 'aria-describedby': describedBy, 'aria-invalid': invalid, ...props }: PasswordFieldProps): import("react").JSX.Element; ``` ### Locally declared props - `label`: `string` - `hint?`: `string` - `error?`: `string` - `size?`: `HdsSize` - `inputSize?`: `number` - `showLabel?`: `string` - `hideLabel?`: `string` ### Usage - Import from @hyeonse/design-system/fields; load tokens.css before components.css. - The caller owns validation, error text, and controlled state. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - hidden/visible - enabled/disabled/readOnly - controlled/uncontrolled - hint/error ### Accessibility - Reveal button has configurable show and hide labels and pressed state. - Password input retains native name, autocomplete, ref, and form behavior. ### Limits - Visibility state is local to this component. Examples: `hds example expanded-forms` ## DropdownMenu Button-triggered action, checkbox, separator, and nested menus. Kind: component · Import: `@hyeonse/design-system/overlays` ```typescript export declare function DropdownMenu({ size, trigger, items, open, defaultOpen, onOpenChange }: DropdownMenuProps): import("react").JSX.Element; ``` ### Locally declared props - `trigger`: `ReactElement` - `items`: `readonly MenuEntry[]` - `open?`: `boolean` - `defaultOpen?`: `boolean` - `onOpenChange?`: `(open: boolean) => void` - `size?`: `HdsSize` ### Usage - Import from @hyeonse/design-system/overlays and load tokens.css then components.css. - Pass a button element as trigger and stable item IDs. Checkbox state is owned by the caller. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - controlled or uncontrolled open - action/checkbox/separator/submenu items - disabled and danger actions ### Accessibility - Base UI supplies menu keyboard navigation, typeahead, Escape dismissal, outside dismissal, and focus return. - Trigger composition preserves forwarded handlers and refs. ### Limits - The supplied trigger component must forward its ref and DOM props. - Danger is visual only; the caller owns confirmation and effects. Examples: `hds example overlay-patterns` ## ContextMenu Right-click or long-press menu using the same item model as DropdownMenu. Kind: component · Import: `@hyeonse/design-system/overlays` ```typescript export declare function ContextMenu({ size, trigger, items, open, defaultOpen, onOpenChange }: ContextMenuProps): import("react").JSX.Element; ``` ### Locally declared props - `trigger`: `ReactElement` - `items`: `readonly MenuEntry[]` - `open?`: `boolean` - `defaultOpen?`: `boolean` - `onOpenChange?`: `(open: boolean) => void` - `size?`: `HdsSize` ### Usage - Pass an interactive or labeled region as trigger and the menu entries as items. - Provide a visible way to perform important actions outside the context menu. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - controlled or uncontrolled open - action/checkbox/separator/submenu items ### Accessibility - Base UI supplies right-click, long-press, keyboard operation, Escape dismissal, and focus management. ### Limits - The supplied trigger component must forward its ref and DOM props. - Context menus should supplement visible controls. Examples: `hds example overlay-patterns` ## Dialog Modal dialog with a title, optional description, body, footer, and close control. Kind: component · Import: `@hyeonse/design-system/overlays` ```typescript export declare function Dialog({ size, trigger, title, description, children, footer, closeLabel, open, defaultOpen, onOpenChange }: DialogProps): import("react").JSX.Element; ``` ### Locally declared props - `trigger`: `ReactElement` - `title`: `string` - `description?`: `string` - `children?`: `ReactNode` - `footer?`: `ReactNode` - `closeLabel?`: `string` - `open?`: `boolean` - `defaultOpen?`: `boolean` - `onOpenChange?`: `(open: boolean) => void` - `size?`: `HdsSize` ### Usage - Pass a button trigger and a required title. - Render task content in children and actions in footer. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - controlled or uncontrolled open - optional description and footer ### Accessibility - Base UI supplies modal focus containment, Escape and outside dismissal, and focus return. - Close button has a configurable Korean accessible label. ### Limits - Caller controls business actions in children and footer. - The supplied trigger component must forward its ref and DOM props. Examples: `hds example overlay-patterns` ## NativeDialog Browser-native modal dialog with a title, optional description, body, footer, and close control. Kind: component · Import: `@hyeonse/design-system/overlays` ```typescript export declare function NativeDialog({ size, trigger, title, description, children, footer, closeLabel, open, defaultOpen, onOpenChange }: DialogProps): import("react").JSX.Element; ``` ### Locally declared props - `trigger`: `ReactElement` - `title`: `string` - `description?`: `string` - `children?`: `ReactNode` - `footer?`: `ReactNode` - `closeLabel?`: `string` - `open?`: `boolean` - `defaultOpen?`: `boolean` - `onOpenChange?`: `(open: boolean) => void` - `size?`: `HdsSize` ### Usage - Import from @hyeonse/design-system/overlays and load tokens.css then components.css. - Pass a button trigger and a required title; use this native path when Base UI popup composition is unnecessary. - With controlled open, a method="dialog" form requests onOpenChange(false). Keep open true to continue editing. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - controlled or uncontrolled open - optional description and footer - xs/sm/md/lg/xl size ### Accessibility - showModal supplies the native modal top layer; this wrapper keeps Tab and Shift+Tab inside without Base UI focus guards. - Escape, close, outside dismissal, and trigger focus return are checked across browser engines. ### Limits - Browser and screen-reader presentation can vary; actual VoiceOver speech still needs direct confirmation. - The trigger must forward onClick and DOM ARIA props. Nested Base UI popup components can still render their own guards. Examples: `hds example overlay-patterns` ## AlertDialog Confirmation dialog that calls onConfirm only from its confirm button. Kind: component · Import: `@hyeonse/design-system/overlays` ```typescript export declare function AlertDialog({ size, trigger, title, description, children, confirmLabel, cancelLabel, onConfirm, onError, pending, confirmDisabled, open, defaultOpen, onOpenChange }: AlertDialogProps): import("react").JSX.Element; ``` ### Locally declared props - `trigger`: `ReactElement` - `title`: `string` - `description?`: `string` - `children?`: `ReactNode` - `confirmLabel`: `string` - `cancelLabel`: `string` - `onConfirm`: `() => void | Promise` - `onError?`: `(error: unknown) => void` - `pending?`: `boolean` - `confirmDisabled?`: `boolean` - `open?`: `boolean` - `defaultOpen?`: `boolean` - `onOpenChange?`: `(open: boolean) => void` - `size?`: `HdsSize` ### Usage - Pass required title, confirmLabel, cancelLabel, and onConfirm. - Use pending or confirmDisabled for externally controlled work; a rejected promise keeps the dialog open and is sent to onError. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - controlled or uncontrolled open - pending - confirmDisabled - confirming ### Accessibility - Base UI supplies alert dialog focus and announcement semantics. - Cancel and confirm are separate controls with at least 44px targets on coarse-pointer devices. ### Limits - An externally controlled open prop must be updated by the caller after onOpenChange. - The caller should present an error message when onConfirm rejects. Examples: `hds example overlay-patterns` ## Sheet Modal side panel with bounded sizes and scrollable content. Kind: component · Import: `@hyeonse/design-system/overlays` ```typescript export declare function Sheet({ trigger, title, description, children, footer, closeLabel, side, size, open, defaultOpen, onOpenChange }: SheetProps): import("react").JSX.Element; ``` ### Locally declared props - `trigger`: `ReactElement` - `title`: `string` - `description?`: `string` - `children?`: `ReactNode` - `footer?`: `ReactNode` - `closeLabel?`: `string` - `open?`: `boolean` - `defaultOpen?`: `boolean` - `onOpenChange?`: `(open: boolean) => void` - `size?`: `HdsSize` - `side?`: `'left' | 'right'` ### Usage - Pass a button trigger and required title. - Use side left/right and size xs/sm/md/lg/xl. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - controlled or uncontrolled open - left/right side - xs/sm/md/lg/xl size ### Accessibility - Uses Base UI dialog focus containment, dismissal, and return focus. - Close button remains visible above scrollable content. ### Limits - Caller controls content and footer actions. Examples: `hds example overlay-patterns` ## Popover Anchored nonmodal content panel with title and close control. Kind: component · Import: `@hyeonse/design-system/overlays` ```typescript export declare function Popover({ size, trigger, title, description, children, closeLabel, open, defaultOpen, onOpenChange }: PopoverProps): import("react").JSX.Element; ``` ### Locally declared props - `trigger`: `ReactElement` - `title`: `string` - `description?`: `string` - `children?`: `ReactNode` - `closeLabel?`: `string` - `open?`: `boolean` - `defaultOpen?`: `boolean` - `onOpenChange?`: `(open: boolean) => void` - `size?`: `HdsSize` ### Usage - Pass a button trigger, required title, and optional body content. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - controlled or uncontrolled open - optional description and body ### Accessibility - Base UI manages anchor placement, Escape and outside dismissal, and focus return. - Close button has a configurable accessible label. ### Limits - The supplied trigger component must forward its ref and DOM props. Examples: `hds example overlay-patterns` ## Tooltip Brief visual hint on hover or focus. Kind: component · Import: `@hyeonse/design-system/overlays` ```typescript export declare function Tooltip({ size, trigger, content, delay }: TooltipProps): import("react").JSX.Element; ``` ### Locally declared props - `trigger`: `ReactElement` - `content`: `string` - `delay?`: `number` - `size?`: `HdsSize` ### Usage - Pass an accessible, focusable trigger and a short plain-text content string. - Keep the trigger accessible without relying on tooltip text alone. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - hover - focus - Escape dismissal ### Accessibility - Base UI handles hover/focus timing and Escape. - Tooltip does not intercept pointer events. ### Limits - No interactive content or touch-only instructions. - The supplied trigger component must forward its ref and DOM props. Examples: `hds example overlay-patterns` ## ToastProvider Scoped, limited stack of transient announcements. Kind: provider · Import: `@hyeonse/design-system/overlays` ```typescript export declare function ToastProvider({ size, children, viewportLabel, closeLabel, timeout, limit }: ToastProviderProps): import("react").JSX.Element; ``` ### Locally declared props - `children`: `ReactNode` - `viewportLabel?`: `string` - `closeLabel?`: `string` - `timeout?`: `number` - `limit?`: `number` - `size?`: `HdsSize` ### Usage - Wrap useToast consumers once per independent region. - Default viewport label is 알림 and close label is 알림 닫기; timeout defaults to 5000ms and visible limit to 3. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - neutral/success/warning/danger tone - auto expiry - manual close - limited queue ### Accessibility - Base UI provides live announcements, F6 viewport focus, and pause behavior. - Each toast has a close button with at least a 44px target on coarse-pointer devices. ### Limits - The provider must mount in a client React tree. - Only text title and description are exposed by this wrapper. Examples: `hds example overlay-patterns` ## useToast Add and close toasts within the nearest ToastProvider. Kind: hook · Import: `@hyeonse/design-system/overlays` ```typescript export declare function useToast(): { add: (message: ToastMessage) => string; close: (id: string) => void; }; ``` ### Usage - Call inside ToastProvider. - add returns an ID to pass to close. ### States - add - close ### Accessibility - Toast messages are announced by Base UI with priority low. ### Limits - Throws outside a Base UI Toast provider. - Do not use as the sole channel for critical persistent information. Examples: `hds example overlay-patterns` ## Tabs Controlled or uncontrolled tab set. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Tabs({ size, className, ...props }: TabsProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` - `size?`: `HdsSize` ### Usage - Import Tabs from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## TabsList Keyboard navigable tab list. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function TabsList({ className, ...props }: TabsListProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import TabsList from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## TabsTab Tab trigger linked to a panel. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function TabsTab({ className, ...props }: TabsTabProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import TabsTab from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## TabsPanel Content panel for a tab. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function TabsPanel({ className, ...props }: TabsPanelProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import TabsPanel from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## Accordion Single or multiple expandable sections. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Accordion({ size, className, ...props }: AccordionProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` - `size?`: `HdsSize` ### Usage - Import Accordion from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## AccordionItem One expandable section. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function AccordionItem({ className, ...props }: AccordionItemProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import AccordionItem from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## AccordionHeader Semantic heading for an accordion item. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function AccordionHeader({ className, ...props }: AccordionHeaderProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import AccordionHeader from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## AccordionTrigger Button controlling an accordion panel. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function AccordionTrigger({ className, ...props }: AccordionTriggerProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import AccordionTrigger from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## AccordionPanel Expandable accordion content. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function AccordionPanel({ className, ...props }: AccordionPanelProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import AccordionPanel from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## Collapsible Independent expandable region. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Collapsible({ size, className, ...props }: CollapsibleProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` - `size?`: `HdsSize` ### Usage - Import Collapsible from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## CollapsibleTrigger Button controlling a collapsible panel. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function CollapsibleTrigger({ className, ...props }: CollapsibleTriggerProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import CollapsibleTrigger from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## CollapsiblePanel Collapsible content. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function CollapsiblePanel({ className, ...props }: CollapsiblePanelProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import CollapsiblePanel from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## Breadcrumb Ordered navigation path. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Breadcrumb({ size, items, separator, className, 'aria-label': ariaLabel, ref, ...props }: BreadcrumbProps): import("react").JSX.Element; ``` ### Locally declared props - `items`: `readonly BreadcrumbItem[]` - `separator?`: `ReactNode` - `size?`: `HdsSize` ### Usage - Import Breadcrumb from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## Pagination Finite page navigation with previous and next controls. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Pagination({ size, page, pageCount, onPageChange, locale, siblingCount, className, 'aria-label': ariaLabel, ref, ...props }: PaginationProps): import("react").JSX.Element; ``` ### Locally declared props - `page`: `number` - `pageCount`: `number` - `onPageChange`: `(page: number) => void` - `locale?`: `'ko' | 'en'` - `siblingCount?`: `number` - `size?`: `HdsSize` ### Usage - Import Pagination from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## Stepper Read only ordered process steps. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Stepper({ size, steps, currentStep, className, ref, ...props }: StepperProps): import("react").JSX.Element; ``` ### Locally declared props - `steps`: `readonly StepperItem[]` - `currentStep`: `number` - `size?`: `HdsSize` ### Usage - Import Stepper from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## SegmentedControl Single or multiple selection toggle group. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function SegmentedControl({ size, className, multiple, ...props }: SegmentedControlProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` - `size?`: `HdsSize` ### Usage - Import SegmentedControl from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## Toggle Pressed state button. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Toggle({ size, className, ...props }: ToggleProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` - `size?`: `HdsSize` ### Usage - Import Toggle from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## Card Content surface with optional heading, description and footer. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Card({ size, title, description, footer, children, className, ref, ...props }: CardProps): import("react").JSX.Element; ``` ### Locally declared props - `title?`: `ReactNode` - `description?`: `ReactNode` - `footer?`: `ReactNode` - `size?`: `HdsSize` ### Usage - Import Card from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## Table Semantic table with keyboard accessible overflow container. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Table({ size, containerClassName, scrollLabel, className, ref, ...props }: TableProps): import("react").JSX.Element; ``` ### Locally declared props - `containerClassName?`: `string` - `scrollLabel?`: `string` - `size?`: `HdsSize` ### Usage - Import Table from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## TableHeader Table header section. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function TableHeader({ className, ...props }: TableHeaderProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import TableHeader from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## TableBody Table body section. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function TableBody({ className, ...props }: TableBodyProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import TableBody from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## TableRow Table row. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function TableRow({ className, ...props }: TableRowProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import TableRow from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## TableHead Column or row header cell. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function TableHead({ className, scope, ...props }: TableHeadProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import TableHead from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## TableCell Data cell. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function TableCell({ className, ...props }: TableCellProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import TableCell from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## TableCaption Table caption. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function TableCaption({ className, ...props }: TableCaptionProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import TableCaption from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## DataTable Controlled semantic table with sorting, single-row selection, and finite pagination. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function DataTable({ caption, columns, rows, getRowId, getRowLabel, sort, onSortChange, selectedRowId, onSelectedRowIdChange, page, pageCount, onPageChange, pageSize, totalRows, state, emptyMessage, errorMessage, locale, size, className, }: DataTableProps): import("react").JSX.Element; ``` ### Locally declared props - `caption`: `string` - `columns`: `readonly DataTableColumn[]` - `rows`: `readonly Row[]` - `getRowId`: `(row: Row) => string` - `getRowLabel?`: `(row: Row) => string` - `sort`: `DataTableSort | null` - `onSortChange`: `(sort: DataTableSort) => void` - `selectedRowId`: `string | null` - `onSelectedRowIdChange`: `(rowId: string | null) => void` - `page`: `number` - `pageCount`: `number` - `onPageChange`: `(page: number) => void` - `pageSize`: `number` - `totalRows`: `number` - `state?`: `'ready' | 'loading' | 'error'` - `emptyMessage?`: `string` - `errorMessage?`: `string` - `locale?`: `'ko' | 'en'` - `size?`: `HdsSize` - `className?`: `string` ### Usage - Import DataTable from @hyeonse/design-system/display and load tokens.css before components.css. - Pass already sorted current-page rows, stable row IDs, and controlled sort, selection, page, pageCount, totalRows, and pageSize. - Keep selection by stable ID when it leaves the current page; clear it explicitly when a record is deleted. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. ### States - ready - loading - error - empty - selected row on another page ### Accessibility - Uses a captioned native table with aria-sort on the active column, labeled sort buttons and row checkboxes. - Moves focus to the named table scroll region after pagination; announces the current range and off-page selection. ### Limits - Sorting, paging, and data fetching are controlled by the application. Examples: `hds example data-table` ## Alert Status or urgent message with semantic role. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Alert({ size, tone, title, children, className, role, ref, ...props }: AlertProps): import("react").JSX.Element; ``` ### Locally declared props - `tone?`: `'info' | 'success' | 'warning' | 'danger'` - `title?`: `ReactNode` - `size?`: `HdsSize` ### Usage - Import Alert from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## Avatar Image with visible fallback on failure. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Avatar({ src, alt, fallback, size, className, ref, ...props }: AvatarProps): import("react").JSX.Element; ``` ### Locally declared props - `src?`: `string` - `alt`: `string` - `fallback`: `ReactNode` - `size?`: `HdsSize` ### Usage - Import Avatar from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## Separator Decorative or semantic divider. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Separator({ size, decorative, className, ref, ...props }: SeparatorProps): import("react").JSX.Element; ``` ### Locally declared props - `decorative?`: `boolean` - `size?`: `HdsSize` ### Usage - Import Separator from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## Skeleton Decorative loading placeholder. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Skeleton({ size, width, height, style, className, ref, ...props }: SkeletonProps): import("react").JSX.Element; ``` ### Locally declared props - `width?`: `string | number` - `height?`: `string | number` - `size?`: `HdsSize` ### Usage - Import Skeleton from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## Spinner Labeled loading status. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Spinner({ size, label, className, ref, ...props }: SpinnerProps): import("react").JSX.Element; ``` ### Locally declared props - `label?`: `string` - `size?`: `HdsSize` ### Usage - Import Spinner from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## Progress Determinate or indeterminate progress indicator. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Progress({ size, value, max, label, className, ref, ...props }: ProgressProps): import("react").JSX.Element; ``` ### Locally declared props - `value?`: `number` - `max?`: `number` - `label`: `string` - `size?`: `HdsSize` ### Usage - Import Progress from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## EmptyState Content for an empty result. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function EmptyState({ size, title, description, action, className, ref, ...props }: EmptyStateProps): import("react").JSX.Element; ``` ### Locally declared props - `title`: `ReactNode` - `description?`: `ReactNode` - `action?`: `ReactNode` - `size?`: `HdsSize` ### Usage - Import EmptyState from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## AspectRatio Aspect ratio box. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function AspectRatio({ size, ratio, style, className, ref, ...props }: AspectRatioProps): import("react").JSX.Element; ``` ### Locally declared props - `ratio?`: `number` - `size?`: `HdsSize` ### Usage - Import AspectRatio from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## ScrollArea Labeled keyboard scroll region. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function ScrollArea({ size, maxHeight, label, style, className, ref, ...props }: ScrollAreaProps): import("react").JSX.Element; ``` ### Locally declared props - `maxHeight?`: `string | number` - `label`: `string` - `size?`: `HdsSize` ### Usage - Import ScrollArea from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## Label Native form label. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function Label({ size, required, children, className, ref, ...props }: LabelProps): import("react").JSX.Element; ``` ### Locally declared props - `required?`: `boolean` - `size?`: `HdsSize` ### Usage - Import Label from @hyeonse/design-system/display and load tokens.css then components.css. - size accepts xs/sm/md/lg/xl; omitted size inherits the nearest SizeProvider or layout, falling back to md. A child size overrides its parent, including across portals. Examples: `hds example display-patterns` ## VisuallyHidden Screen reader visible text. Kind: component · Import: `@hyeonse/design-system/display` ```typescript export declare function VisuallyHidden({ className, ref, ...props }: VisuallyHiddenProps): import("react").JSX.Element; ``` ### Locally declared props - `className?`: `string` ### Usage - Import VisuallyHidden from @hyeonse/design-system/display and load tokens.css then components.css. Examples: `hds example display-patterns` ## SizeProvider Provide one size to nested components, including React portals. Kind: provider · Import: `@hyeonse/design-system/layout` ```typescript export declare function SizeProvider({ size, children }: SizeProviderProps): import("react").JSX.Element; ``` ### Locally declared props - `size`: `Size` - `children?`: `ReactNode` ### Usage - Pass one required size: xs, sm, md, lg, or xl; adds no DOM element. - Children inherit this size unless they supply an explicit size. ### States - xs/sm/md/lg/xl ### Accessibility - Touch controls retain at least 44px targets. ### Limits - Layout adds no application landmarks or route behavior. Examples: `hds example layout-sizing` ## Stack Vertical layout with inherited size and optional gap override. Kind: component · Import: `@hyeonse/design-system/layout` ```typescript export declare function Stack({ size, gap, align, className, style, children, ...props }: StackProps): import("react").JSX.Element; ``` ### Locally declared props - `size?`: `Size` - `gap?`: `Size` - `align?`: `'start' | 'center' | 'end' | 'stretch'` ### Usage - Use size for child components and gap for spacing only. - Omitted size inherits the nearest provider or layout; default md. Explicit child size wins. ### States - xs/sm/md/lg/xl ### Accessibility - Touch controls retain at least 44px targets. ### Limits - Layout adds no application landmarks or route behavior. Examples: `hds example layout-sizing` ## Inline Wrapping horizontal layout with alignment and justification. Kind: component · Import: `@hyeonse/design-system/layout` ```typescript export declare function Inline({ size, gap, align, justify, wrap, className, children, ...props }: InlineProps): import("react").JSX.Element; ``` ### Locally declared props - `size?`: `Size` - `gap?`: `Size` - `align?`: `'start' | 'center' | 'end' | 'stretch'` - `justify?`: `'start' | 'center' | 'end' | 'between'` - `wrap?`: `boolean` ### Usage - Use wrap=false only when content is known to fit; wrapping is the default. - Omitted size inherits the nearest provider or layout; default md. Explicit child size wins. ### States - xs/sm/md/lg/xl ### Accessibility - Touch controls retain at least 44px targets. ### Limits - Layout adds no application landmarks or route behavior. Examples: `hds example layout-sizing` ## Grid Responsive grid with a preferred column count. Kind: component · Import: `@hyeonse/design-system/layout` ```typescript export declare function Grid({ size, gap, columns, minItemWidth, style, className, children, ...props }: GridProps): import("react").JSX.Element; ``` ### Locally declared props - `size?`: `Size` - `gap?`: `Size` - `columns?`: `1 | 2 | 3 | 4` - `minItemWidth?`: `string` ### Usage - columns accepts 1–4; columns collapse as available width drops below minItemWidth. - Omitted size inherits the nearest provider or layout; default md. Explicit child size wins. ### States - xs/sm/md/lg/xl ### Accessibility - Touch controls retain at least 44px targets. ### Limits - Layout adds no application landmarks or route behavior. Examples: `hds example layout-sizing` ## Container Centered fluid content container with a size-based maximum width. Kind: component · Import: `@hyeonse/design-system/layout` ```typescript export declare function Container({ size, fluid, className, children, ...props }: ContainerProps): import("react").JSX.Element; ``` ### Locally declared props - `size?`: `Size` - `fluid?`: `boolean` ### Usage - Use fluid to remove the maximum width while retaining scaled horizontal padding. - Omitted size inherits the nearest provider or layout; default md. Explicit child size wins. ### States - xs/sm/md/lg/xl ### Accessibility - Touch controls retain at least 44px targets. ### Limits - Layout adds no application landmarks or route behavior. Examples: `hds example layout-sizing` # Type context ## @hyeonse/design-system/preferences ```typescript export type ThemePreference = 'system' | 'light' | 'dark'; export type AccentPreference = 'cobalt' | 'forest' | 'coral'; export type DensityPreference = 'comfortable' | 'compact'; export type CornersPreference = 'crisp' | 'soft'; export type MotionPreference = 'full' | 'reduced'; export type Preferences = { theme: ThemePreference; accent: AccentPreference; density: DensityPreference; corners: CornersPreference; motion: MotionPreference; }; export declare const preferencesKey = "hyeonse-site-preferences"; export declare const defaultPreferences: Preferences; export declare function validatePreferences(value: unknown, defaults?: Partial): Preferences; export declare function parsePreferences(raw: string | null, defaults?: Partial): Preferences; export declare function serializePreferences(value: Preferences): string; export declare function resolvedTheme(theme: ThemePreference, systemDark: boolean): 'light' | 'dark'; export declare function effectiveMotion(motion: MotionPreference, systemReduced: boolean): MotionPreference; export declare function createPreferenceScript(storageKey?: string, defaults?: Partial): string; export declare const preferenceScript: string; ``` ## @hyeonse/design-system/react ```typescript import type { ReactNode } from 'react'; import type { Preferences } from './preferences.js'; export type Locale = 'ko' | 'en'; type PreferenceContext = { preferences: Preferences; setPreference: (key: K, value: Preferences[K]) => void; resetPreferences: () => void; }; export declare function PreferencesProvider({ children, storageKey, eventName, defaults }: { children: ReactNode; storageKey?: string; eventName?: string; defaults?: Partial; }): import("react").JSX.Element; export declare function usePreferences(): PreferenceContext; export declare function ThemeToggle({ locale }: { locale?: Locale; }): import("react").JSX.Element; export declare function PreferencesPanel({ locale }: { locale?: Locale; }): import("react").JSX.Element; export {}; ``` ## @hyeonse/design-system/primitives ```typescript import type { HdsSize } from './sizing.js'; import type { ComponentPropsWithRef } from 'react'; export type ButtonProps = ComponentPropsWithRef<'button'> & { variant?: 'primary' | 'secondary' | 'ghost'; size?: HdsSize; loading?: boolean; loadingLabel?: string; }; export declare function Button({ variant, size, loading, loadingLabel, type, disabled, className, children, ref, 'aria-busy': ariaBusy, 'aria-label': ariaLabel, 'aria-labelledby': ariaLabelledBy, ...props }: ButtonProps): import("react").JSX.Element; type TextInputType = 'text' | 'email' | 'password' | 'search' | 'tel' | 'url'; export type TextFieldProps = Omit, 'type' | 'children' | 'size'> & { size?: HdsSize; inputSize?: number; label: string; type?: TextInputType; hint?: string; error?: string; }; export declare function TextField({ label, hint, error, size, inputSize, type, id, className, disabled, ref, 'aria-describedby': ariaDescribedBy, 'aria-invalid': ariaInvalid, ...props }: TextFieldProps): import("react").JSX.Element; export type CheckboxProps = Omit, 'type' | 'children' | 'size'> & { size?: HdsSize; inputSize?: number; label: string; hint?: string; error?: string; }; export declare function Checkbox({ label, hint, error, size, inputSize, id, className, disabled, readOnly, ref, onClick, onChange, 'aria-describedby': ariaDescribedBy, 'aria-invalid': ariaInvalid, 'aria-readonly': ariaReadOnly, ...props }: CheckboxProps): import("react").JSX.Element; export type BadgeProps = ComponentPropsWithRef<'span'> & { size?: HdsSize; tone?: 'neutral' | 'accent' | 'success' | 'warning' | 'danger'; }; export declare function Badge({ size, tone, className, children, ref, ...props }: BadgeProps): import("react").JSX.Element; export {}; ``` ## @hyeonse/design-system/fields ```typescript import type { ComponentPropsWithRef, Ref } from 'react'; import type { HdsSize } from './sizing.js'; type FieldText = { label: string; hint?: string; error?: string; size?: HdsSize; }; type TextualType = 'text' | 'email' | 'search' | 'tel' | 'url'; export type InputProps = Omit, 'type' | 'children' | 'size'> & { type?: TextualType; size?: HdsSize; inputSize?: number; }; export declare function Input({ type, size, inputSize, className, ref, ...props }: InputProps): import("react").JSX.Element; export type TextareaProps = Omit, 'children'> & FieldText; export declare function Textarea({ label, hint, error, size, id, className, disabled, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid, ...props }: TextareaProps): import("react").JSX.Element; export type FieldOption = { value: string; label: string; disabled?: boolean; }; type ChoiceProps = FieldText & { options: readonly FieldOption[]; name?: string; form?: string; id?: string; required?: boolean; disabled?: boolean; readOnly?: boolean; value?: string | null; defaultValue?: string | null; onValueChange?: (value: string | null) => void; placeholder?: string; className?: string; 'aria-describedby'?: string; 'aria-invalid'?: boolean | 'grammar' | 'spelling'; }; export type SelectProps = ChoiceProps & { ref?: Ref; }; export declare function Select({ label, hint, error, size, options, name, form, id, required, disabled, readOnly, value, defaultValue, onValueChange, placeholder, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid }: SelectProps): import("react").JSX.Element; /** Native picker for fixed choices when browser and screen-reader controls are preferred. */ export type NativeSelectProps = Omit & { ref?: Ref; }; export declare function NativeSelect({ label, hint, error, size, options, name, form, id, required, disabled, value, defaultValue, onValueChange, placeholder, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid }: NativeSelectProps): import("react").JSX.Element; export type ComboboxProps = ChoiceProps & { ref?: Ref; emptyText?: string; openLabel?: string; inputValue?: string; defaultInputValue?: string; onInputValueChange?: (value: string) => void; }; export declare function Combobox({ label, hint, error, size, options, name, form, id, required, disabled, readOnly, value, defaultValue, onValueChange, placeholder, emptyText, openLabel, inputValue, defaultInputValue, onInputValueChange, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid }: ComboboxProps): import("react").JSX.Element; export type MultiSelectProps = Omit & { ref?: Ref; value?: readonly string[]; defaultValue?: readonly string[]; onValueChange?: (value: string[]) => void; emptyText?: string; openLabel?: string; selectedLabel?: string; removeLabel?: (label: string) => string; chipDescription?: string; inputDescription?: (count: number) => string; inputValue?: string; defaultInputValue?: string; onInputValueChange?: (value: string) => void; }; export declare function MultiSelect({ label, hint, error, size, options, name, form, id, required, disabled, readOnly, value, defaultValue, onValueChange, placeholder, emptyText, openLabel, selectedLabel, removeLabel, chipDescription, inputDescription, inputValue, defaultInputValue, onInputValueChange, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid }: MultiSelectProps): import("react").JSX.Element; export type SwitchProps = FieldText & { id?: string; name?: string; form?: string; value?: string; uncheckedValue?: string; required?: boolean; disabled?: boolean; readOnly?: boolean; checked?: boolean; defaultChecked?: boolean; onCheckedChange?: (checked: boolean) => void; ref?: Ref; className?: string; 'aria-describedby'?: string; 'aria-invalid'?: boolean | 'grammar' | 'spelling'; }; export declare function Switch({ label, hint, error, size, id, name, form, value, uncheckedValue, required, disabled, readOnly, checked, defaultChecked, onCheckedChange, ref, className, 'aria-describedby': describedBy, 'aria-invalid': invalid }: SwitchProps): import("react").JSX.Element; export type RadioGroupProps = FieldText & { options: readonly FieldOption[]; name?: string; form?: string; required?: boolean; disabled?: boolean; readOnly?: boolean; value?: string; defaultValue?: string; onValueChange?: (value: string) => void; ref?: Ref; className?: string; 'aria-describedby'?: string; 'aria-invalid'?: boolean | 'grammar' | 'spelling'; }; export declare function RadioGroup({ label, hint, error, size, options, name, form, required, disabled, readOnly, value, defaultValue, onValueChange, ref, className, 'aria-describedby': describedBy, 'aria-invalid': invalid }: RadioGroupProps): import("react").JSX.Element; export type SliderProps = Omit, 'type' | 'children' | 'size' | 'readOnly'> & FieldText & { inputSize?: number; }; export declare function Slider({ label, hint, error, size, inputSize, id, disabled, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid, ...props }: SliderProps): import("react").JSX.Element; export type NumberFieldProps = FieldText & { id?: string; name?: string; form?: string; required?: boolean; disabled?: boolean; readOnly?: boolean; value?: number | null; defaultValue?: number; onValueChange?: (value: number | null) => void; min?: number; max?: number; step?: number | 'any'; locale?: Intl.LocalesArgument; placeholder?: string; incrementLabel?: string; decrementLabel?: string; ref?: Ref; className?: string; 'aria-describedby'?: string; 'aria-invalid'?: boolean | 'grammar' | 'spelling'; }; export declare function NumberField({ label, hint, error, size, id, name, form, required, disabled, readOnly, value, defaultValue, onValueChange, min, max, step, locale, placeholder, incrementLabel, decrementLabel, ref, className, 'aria-describedby': describedBy, 'aria-invalid': invalid }: NumberFieldProps): import("react").JSX.Element; export type DateFieldProps = Omit, 'type' | 'children' | 'size'> & FieldText & { inputSize?: number; }; export declare function DateField({ label, hint, error, size, inputSize, id, disabled, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid, ...props }: DateFieldProps): import("react").JSX.Element; export type FileInputProps = Omit, 'type' | 'children' | 'size' | 'value' | 'defaultValue' | 'readOnly'> & FieldText & { inputSize?: number; }; export declare function FileInput({ label, hint, error, size, inputSize, id, disabled, className, ref, 'aria-describedby': describedBy, 'aria-invalid': invalid, ...props }: FileInputProps): import("react").JSX.Element; export type PasswordFieldProps = Omit, 'type' | 'children' | 'size'> & FieldText & { inputSize?: number; showLabel?: string; hideLabel?: string; }; export declare function PasswordField({ label, hint, error, size, inputSize, id, disabled, className, ref, showLabel, hideLabel, 'aria-describedby': describedBy, 'aria-invalid': invalid, ...props }: PasswordFieldProps): import("react").JSX.Element; export {}; ``` ## @hyeonse/design-system/overlays ```typescript import type { ReactElement, ReactNode } from 'react'; import type { HdsSize } from './sizing.js'; export type MenuEntry = { kind: 'action'; id: string; label: string; onSelect: () => void; disabled?: boolean; danger?: boolean; } | { kind: 'checkbox'; id: string; label: string; checked: boolean; onCheckedChange: (checked: boolean) => void; disabled?: boolean; } | { kind: 'separator'; id: string; } | { kind: 'submenu'; id: string; label: string; items: readonly MenuEntry[]; disabled?: boolean; }; export type DropdownMenuProps = { trigger: ReactElement; items: readonly MenuEntry[]; open?: boolean; defaultOpen?: boolean; onOpenChange?: (open: boolean) => void; size?: HdsSize; }; export declare function DropdownMenu({ size, trigger, items, open, defaultOpen, onOpenChange }: DropdownMenuProps): import("react").JSX.Element; export type ContextMenuProps = { trigger: ReactElement; items: readonly MenuEntry[]; open?: boolean; defaultOpen?: boolean; onOpenChange?: (open: boolean) => void; size?: HdsSize; }; export declare function ContextMenu({ size, trigger, items, open, defaultOpen, onOpenChange }: ContextMenuProps): import("react").JSX.Element; export type DialogProps = { trigger: ReactElement; title: string; description?: string; children?: ReactNode; footer?: ReactNode; closeLabel?: string; open?: boolean; defaultOpen?: boolean; onOpenChange?: (open: boolean) => void; size?: HdsSize; }; export declare function Dialog({ size, trigger, title, description, children, footer, closeLabel, open, defaultOpen, onOpenChange }: DialogProps): import("react").JSX.Element; /** Native modal alternative for journeys that do not need Base UI's popup composition. */ export declare function NativeDialog({ size, trigger, title, description, children, footer, closeLabel, open, defaultOpen, onOpenChange }: DialogProps): import("react").JSX.Element; export type AlertDialogProps = { trigger: ReactElement; title: string; description?: string; children?: ReactNode; confirmLabel: string; cancelLabel: string; onConfirm: () => void | Promise; onError?: (error: unknown) => void; pending?: boolean; confirmDisabled?: boolean; open?: boolean; defaultOpen?: boolean; onOpenChange?: (open: boolean) => void; size?: HdsSize; }; export declare function AlertDialog({ size, trigger, title, description, children, confirmLabel, cancelLabel, onConfirm, onError, pending, confirmDisabled, open, defaultOpen, onOpenChange }: AlertDialogProps): import("react").JSX.Element; export type SheetProps = DialogProps & { side?: 'left' | 'right'; size?: HdsSize; }; export declare function Sheet({ trigger, title, description, children, footer, closeLabel, side, size, open, defaultOpen, onOpenChange }: SheetProps): import("react").JSX.Element; export type PopoverProps = { trigger: ReactElement; title: string; description?: string; children?: ReactNode; closeLabel?: string; open?: boolean; defaultOpen?: boolean; onOpenChange?: (open: boolean) => void; size?: HdsSize; }; export declare function Popover({ size, trigger, title, description, children, closeLabel, open, defaultOpen, onOpenChange }: PopoverProps): import("react").JSX.Element; export type TooltipProps = { trigger: ReactElement; content: string; delay?: number; size?: HdsSize; }; export declare function Tooltip({ size, trigger, content, delay }: TooltipProps): import("react").JSX.Element; export type ToastMessage = { title: string; description?: string; tone?: 'neutral' | 'success' | 'warning' | 'danger'; timeout?: number; }; export type ToastProviderProps = { children: ReactNode; viewportLabel?: string; closeLabel?: string; timeout?: number; limit?: number; size?: HdsSize; }; export declare function ToastProvider({ size, children, viewportLabel, closeLabel, timeout, limit }: ToastProviderProps): import("react").JSX.Element; export declare function useToast(): { add: (message: ToastMessage) => string; close: (id: string) => void; }; ``` ## @hyeonse/design-system/display ```typescript import type { ComponentPropsWithRef, ReactNode } from 'react'; import type { HdsSize } from './sizing.js'; import { Tabs as BaseTabs, Accordion as BaseAccordion, Collapsible as BaseCollapsible, ToggleGroup as BaseToggleGroup, Toggle as BaseToggle } from '@base-ui/react'; export type TabsProps = Omit, 'className'> & { className?: string; size?: HdsSize; }; export declare function Tabs({ size, className, ...props }: TabsProps): import("react").JSX.Element; export type TabsListProps = Omit, 'className'> & { className?: string; }; export declare function TabsList({ className, ...props }: TabsListProps): import("react").JSX.Element; export type TabsTabProps = Omit, 'className'> & { className?: string; }; export declare function TabsTab({ className, ...props }: TabsTabProps): import("react").JSX.Element; export type TabsPanelProps = Omit, 'className'> & { className?: string; }; export declare function TabsPanel({ className, ...props }: TabsPanelProps): import("react").JSX.Element; export type AccordionProps = Omit, 'className'> & { className?: string; size?: HdsSize; }; export declare function Accordion({ size, className, ...props }: AccordionProps): import("react").JSX.Element; export type AccordionItemProps = Omit, 'className'> & { className?: string; }; export declare function AccordionItem({ className, ...props }: AccordionItemProps): import("react").JSX.Element; export type AccordionHeaderProps = Omit, 'className'> & { className?: string; }; export declare function AccordionHeader({ className, ...props }: AccordionHeaderProps): import("react").JSX.Element; export type AccordionTriggerProps = Omit, 'className'> & { className?: string; }; export declare function AccordionTrigger({ className, ...props }: AccordionTriggerProps): import("react").JSX.Element; export type AccordionPanelProps = Omit, 'className'> & { className?: string; }; export declare function AccordionPanel({ className, ...props }: AccordionPanelProps): import("react").JSX.Element; export type CollapsibleProps = Omit, 'className'> & { className?: string; size?: HdsSize; }; export declare function Collapsible({ size, className, ...props }: CollapsibleProps): import("react").JSX.Element; export type CollapsibleTriggerProps = Omit, 'className'> & { className?: string; }; export declare function CollapsibleTrigger({ className, ...props }: CollapsibleTriggerProps): import("react").JSX.Element; export type CollapsiblePanelProps = Omit, 'className'> & { className?: string; }; export declare function CollapsiblePanel({ className, ...props }: CollapsiblePanelProps): import("react").JSX.Element; export type BreadcrumbItem = { label: ReactNode; href?: string; }; export type BreadcrumbProps = Omit, 'children'> & { items: readonly BreadcrumbItem[]; separator?: ReactNode; size?: HdsSize; }; export declare function Breadcrumb({ size, items, separator, className, 'aria-label': ariaLabel, ref, ...props }: BreadcrumbProps): import("react").JSX.Element; export type PaginationProps = Omit, 'children'> & { page: number; pageCount: number; onPageChange: (page: number) => void; locale?: 'ko' | 'en'; siblingCount?: number; size?: HdsSize; }; export declare function Pagination({ size, page, pageCount, onPageChange, locale, siblingCount, className, 'aria-label': ariaLabel, ref, ...props }: PaginationProps): import("react").JSX.Element; export type StepperItem = { label: ReactNode; description?: ReactNode; }; export type StepperProps = Omit, 'children'> & { steps: readonly StepperItem[]; currentStep: number; size?: HdsSize; }; export declare function Stepper({ size, steps, currentStep, className, ref, ...props }: StepperProps): import("react").JSX.Element; export type SegmentedControlProps = Omit, 'className'> & { className?: string; size?: HdsSize; }; export declare function SegmentedControl({ size, className, multiple, ...props }: SegmentedControlProps): import("react").JSX.Element; export type ToggleProps = Omit, 'className'> & { className?: string; size?: HdsSize; }; export declare function Toggle({ size, className, ...props }: ToggleProps): import("react").JSX.Element; export type CardProps = Omit, 'title'> & { title?: ReactNode; description?: ReactNode; footer?: ReactNode; size?: HdsSize; }; export declare function Card({ size, title, description, footer, children, className, ref, ...props }: CardProps): import("react").JSX.Element; export type TableProps = ComponentPropsWithRef<'table'> & { containerClassName?: string; scrollLabel?: string; size?: HdsSize; }; export declare function Table({ size, containerClassName, scrollLabel, className, ref, ...props }: TableProps): import("react").JSX.Element; export type TableHeaderProps = ComponentPropsWithRef<'thead'> & { className?: string; }; export declare function TableHeader({ className, ...props }: TableHeaderProps): import("react").JSX.Element; export type TableBodyProps = ComponentPropsWithRef<'tbody'> & { className?: string; }; export declare function TableBody({ className, ...props }: TableBodyProps): import("react").JSX.Element; export type TableRowProps = ComponentPropsWithRef<'tr'> & { className?: string; }; export declare function TableRow({ className, ...props }: TableRowProps): import("react").JSX.Element; export type TableHeadProps = ComponentPropsWithRef<'th'> & { className?: string; }; export declare function TableHead({ className, scope, ...props }: TableHeadProps): import("react").JSX.Element; export type TableCellProps = ComponentPropsWithRef<'td'> & { className?: string; }; export declare function TableCell({ className, ...props }: TableCellProps): import("react").JSX.Element; export type TableCaptionProps = ComponentPropsWithRef<'caption'> & { className?: string; }; export declare function TableCaption({ className, ...props }: TableCaptionProps): import("react").JSX.Element; export type DataTableSort = { columnId: string; direction: 'asc' | 'desc'; }; export type DataTableColumn = { id: string; header: string; cell: (row: Row) => ReactNode; sortable?: boolean; }; export type DataTableProps = { caption: string; columns: readonly DataTableColumn[]; rows: readonly Row[]; getRowId: (row: Row) => string; getRowLabel?: (row: Row) => string; sort: DataTableSort | null; onSortChange: (sort: DataTableSort) => void; selectedRowId: string | null; onSelectedRowIdChange: (rowId: string | null) => void; page: number; pageCount: number; onPageChange: (page: number) => void; pageSize: number; totalRows: number; state?: 'ready' | 'loading' | 'error'; emptyMessage?: string; errorMessage?: string; locale?: 'ko' | 'en'; size?: HdsSize; className?: string; }; export declare function DataTable({ caption, columns, rows, getRowId, getRowLabel, sort, onSortChange, selectedRowId, onSelectedRowIdChange, page, pageCount, onPageChange, pageSize, totalRows, state, emptyMessage, errorMessage, locale, size, className, }: DataTableProps): import("react").JSX.Element; export type AlertProps = Omit, 'title'> & { tone?: 'info' | 'success' | 'warning' | 'danger'; title?: ReactNode; size?: HdsSize; }; export declare function Alert({ size, tone, title, children, className, role, ref, ...props }: AlertProps): import("react").JSX.Element; export type AvatarProps = Omit, 'children'> & { src?: string; alt: string; fallback: ReactNode; size?: HdsSize; }; export declare function Avatar({ src, alt, fallback, size, className, ref, ...props }: AvatarProps): import("react").JSX.Element; export type SeparatorProps = ComponentPropsWithRef<'hr'> & { decorative?: boolean; size?: HdsSize; }; export declare function Separator({ size, decorative, className, ref, ...props }: SeparatorProps): import("react").JSX.Element; export type SkeletonProps = ComponentPropsWithRef<'span'> & { width?: string | number; height?: string | number; size?: HdsSize; }; export declare function Skeleton({ size, width, height, style, className, ref, ...props }: SkeletonProps): import("react").JSX.Element; export type SpinnerProps = ComponentPropsWithRef<'span'> & { label?: string; size?: HdsSize; }; export declare function Spinner({ size, label, className, ref, ...props }: SpinnerProps): import("react").JSX.Element; export type ProgressProps = Omit, 'children'> & { value?: number; max?: number; label: string; size?: HdsSize; }; export declare function Progress({ size, value, max, label, className, ref, ...props }: ProgressProps): import("react").JSX.Element; export type EmptyStateProps = Omit, 'title'> & { title: ReactNode; description?: ReactNode; action?: ReactNode; size?: HdsSize; }; export declare function EmptyState({ size, title, description, action, className, ref, ...props }: EmptyStateProps): import("react").JSX.Element; export type AspectRatioProps = ComponentPropsWithRef<'div'> & { ratio?: number; size?: HdsSize; }; export declare function AspectRatio({ size, ratio, style, className, ref, ...props }: AspectRatioProps): import("react").JSX.Element; export type ScrollAreaProps = ComponentPropsWithRef<'div'> & { maxHeight?: string | number; label: string; size?: HdsSize; }; export declare function ScrollArea({ size, maxHeight, label, style, className, ref, ...props }: ScrollAreaProps): import("react").JSX.Element; export type LabelProps = ComponentPropsWithRef<'label'> & { required?: boolean; size?: HdsSize; }; export declare function Label({ size, required, children, className, ref, ...props }: LabelProps): import("react").JSX.Element; export type VisuallyHiddenProps = ComponentPropsWithRef<'span'> & { className?: string; }; export declare function VisuallyHidden({ className, ref, ...props }: VisuallyHiddenProps): import("react").JSX.Element; ``` ## @hyeonse/design-system/layout ```typescript import type { ComponentPropsWithRef, ReactNode } from 'react'; import type { HdsSize } from './sizing.js'; /** Five consistent size steps. Omitted sizes inherit the nearest layout/provider. */ export type Size = HdsSize; export type SizeProviderProps = { size: Size; children?: ReactNode; }; /** Shares size through React portals without adding an element to the page. */ export declare function SizeProvider({ size, children }: SizeProviderProps): import("react").JSX.Element; type LayoutProps = ComponentPropsWithRef<'div'> & { size?: Size; }; export type StackProps = LayoutProps & { gap?: Size; align?: 'start' | 'center' | 'end' | 'stretch'; }; export declare function Stack({ size, gap, align, className, style, children, ...props }: StackProps): import("react").JSX.Element; export type InlineProps = LayoutProps & { gap?: Size; align?: 'start' | 'center' | 'end' | 'stretch'; justify?: 'start' | 'center' | 'end' | 'between'; wrap?: boolean; }; export declare function Inline({ size, gap, align, justify, wrap, className, children, ...props }: InlineProps): import("react").JSX.Element; export type GridProps = LayoutProps & { gap?: Size; columns?: 1 | 2 | 3 | 4; minItemWidth?: string; }; /** Columns collapse with available width; minItemWidth controls the preferred item width. */ export declare function Grid({ size, gap, columns, minItemWidth, style, className, children, ...props }: GridProps): import("react").JSX.Element; export type ContainerProps = LayoutProps & { fluid?: boolean; }; /** A centered, fluid container capped by its size with scaled horizontal padding. */ export declare function Container({ size, fluid, className, children, ...props }: ContainerProps): import("react").JSX.Element; export {}; ``` # CSS tokens Values are CSS expressions, with their original selector and media-query conditions. This is the package catalog format, not a DTCG token interchange file. ## --ink Primary foreground text Default: `#101114` - `:root[data-theme='dark']` → `#f2f4f8` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#f2f4f8` ## --paper Page background Default: `#ffffff` - `:root[data-theme='dark']` → `#111318` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#111318` ## --muted Secondary text Default: `#5a606b` - `:root[data-theme='dark']` → `#b2b8c4` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#b2b8c4` ## --line Subtle dividing line Default: `#d8dbe3` - `:root[data-theme='dark']` → `#444a56` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#444a56` ## --surface Grouped content surface Default: `#f3f5f8` - `:root[data-theme='dark']` → `#1c2028` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#1c2028` ## --surface-raised Raised content surface Default: `#ffffff` - `:root[data-theme='dark']` → `#282d37` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#282d37` ## --accent-solid Solid accent surface Default: `#204cfc` - `:root[data-accent='forest']` → `#087451` - `:root[data-accent='coral']` → `#b93d20` ## --accent-text Accent text, link, selection, and focus Default: `#204cfc` - `:root[data-accent='forest']` → `#087451` - `:root[data-accent='coral']` → `#b93d20` - `:root[data-theme='dark']` → `#9aafff` - `:root[data-theme='dark'][data-accent='forest']` → `#68dfb1` - `:root[data-theme='dark'][data-accent='coral']` → `#ffa58e` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#9aafff` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])[data-accent='forest']` → `#68dfb1` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])[data-accent='coral']` → `#ffa58e` ## --palette-cobalt Cobalt palette reference Default: `#204cfc` ## --palette-forest Forest palette reference Default: `#087451` ## --palette-coral Coral palette reference Default: `#b93d20` ## --on-accent Foreground on solid accent surface Default: `#ffffff` ## --blue Alias of accent text Default: `var(--accent-text)` ## --about-surface About section surface Default: `var(--accent-solid)` - `:root[data-theme='dark']` → `#1b2540` - `:root[data-theme='dark'][data-accent='forest']` → `#173029` - `:root[data-theme='dark'][data-accent='coral']` → `#35231f` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#1b2540` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])[data-accent='forest']` → `#173029` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])[data-accent='coral']` → `#35231f` ## --about-ink About section primary text Default: `#ffffff` - `:root[data-theme='dark']` → `#f5f7ff` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#f5f7ff` ## --about-muted About section secondary text Default: `#dce3ff` - `:root[data-accent='forest']` → `#d4f5e8` - `:root[data-accent='coral']` → `#ffe1d9` - `:root[data-theme='dark']` → `#c1c9de` - `:root[data-theme='dark'][data-accent='forest']` → `#b7e1d1` - `:root[data-theme='dark'][data-accent='coral']` → `#e7c1b8` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#c1c9de` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])[data-accent='forest']` → `#b7e1d1` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])[data-accent='coral']` → `#e7c1b8` ## --inverse-surface Inverse panel surface Default: `#101114` - `:root[data-theme='dark']` → `#f2f4f8` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#f2f4f8` ## --inverse-ink Text on inverse panel Default: `#ffffff` - `:root[data-theme='dark']` → `#101114` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#101114` ## --radius-card Card corner radius Default: `0px` - `:root[data-corners='soft']` → `20px` ## --radius-control Control corner radius Default: `2px` - `:root[data-corners='soft']` → `12px` ## --space-factor Multiplier used by compact spacing Default: `1` - `:root[data-density='compact']` → `.8` ## --font-sans Sans-serif font stack; font files are supplied by the app Default: `'DM Sans', 'Noto Sans KR', sans-serif` ## --gutter Responsive page gutter Default: `clamp(22px, 4.1vw, 72px)` - @media (max-width: 700px) · `:root` → `22px` ## --control-min-size Minimum control size Default: `44px` ## --text-control Control text size Default: `12px` ## --control-border Border of form controls Default: `#858d9a` - `:root[data-theme='dark']` → `#737e90` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#737e90` ## --focus-ring Visible keyboard focus outline Default: `var(--accent-text)` ## --disabled-ink Foreground text for disabled controls Default: `#727987` - `:root[data-theme='dark']` → `#99a2b2` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#99a2b2` ## --disabled-surface Surface for disabled controls Default: `#e9ecf1` - `:root[data-theme='dark']` → `#202631` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#202631` ## --success-text Success status text Default: `#176b4e` - `:root[data-theme='dark']` → `#8cdeb7` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#8cdeb7` ## --success-surface Success status background Default: `#edf8f2` - `:root[data-theme='dark']` → `#142b23` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#142b23` ## --success-line Success status border Default: `#3c8668` - `:root[data-theme='dark']` → `#4e9a78` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#4e9a78` ## --warning-text Warning status text Default: `#80520c` - `:root[data-theme='dark']` → `#f3cc83` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#f3cc83` ## --warning-surface Warning status background Default: `#fff7e3` - `:root[data-theme='dark']` → `#302719` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#302719` ## --warning-line Warning status border Default: `#ab751f` - `:root[data-theme='dark']` → `#b28d46` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#b28d46` ## --danger-text Danger or validation-error text Default: `#b42332` - `:root[data-theme='dark']` → `#ff9ba5` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#ff9ba5` ## --danger-surface Danger or validation-error background Default: `#fff1f2` - `:root[data-theme='dark']` → `#351f25` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#351f25` ## --danger-line Danger or validation-error border Default: `#c64a59` - `:root[data-theme='dark']` → `#c26b77` - @media (prefers-color-scheme: dark) · `:root:not([data-theme])` → `#c26b77` ## --space-1 Spacing step 1 (4px); pair with --space-factor for density-aware spacing Default: `4px` ## --space-2 Spacing step 2 (8px); pair with --space-factor for density-aware spacing Default: `8px` ## --space-3 Spacing step 3 (12px); pair with --space-factor for density-aware spacing Default: `12px` ## --space-4 Spacing step 4 (16px); pair with --space-factor for density-aware spacing Default: `16px` ## --space-5 Spacing step 5 (24px); pair with --space-factor for density-aware spacing Default: `24px` ## --space-6 Spacing step 6 (32px); pair with --space-factor for density-aware spacing Default: `32px` ## --space-7 Spacing step 7 (48px); pair with --space-factor for density-aware spacing Default: `48px` ## --space-8 Spacing step 8 (64px); pair with --space-factor for density-aware spacing Default: `64px` ## --text-xs Extra-small text size Default: `12px` ## --text-sm Small text size Default: `14px` ## --text-base Base text size Default: `16px` ## --text-lg Large text size Default: `20px` ## --leading-body Body text line-height Default: `1.6` ## --duration-fast Fast interaction transition duration Default: `140ms` ## --overlay-scrim Background scrim behind modal overlays Default: `rgba(0, 0, 0, .48)` ## --shadow-popover Elevation shadow for menus, select popups, and popovers Default: `0 8px 28px rgba(0, 0, 0, .16)` ## --shadow-dialog Elevation shadow for modal dialogs and sheets Default: `0 24px 72px rgba(0, 0, 0, .24)` # Examples ## layout-sizing Five size steps, inherited component sizing and responsive layout primitives. ### examples/layout-sizing.tsx ```tsx import { Container, Grid, Inline, Stack, SizeProvider } from '@hyeonse/design-system/layout'; import { Button, TextField } from '@hyeonse/design-system/primitives'; import { Card } from '@hyeonse/design-system/display'; export function LayoutSizingExample() { return 공개 범위를 정해요. ; } ``` ## display-settings React display settings with first-paint preferences and public imports. ### examples/preferences.ts ```typescript import { createPreferenceScript } from '@hyeonse/design-system/preferences'; import type { Preferences } from '@hyeonse/design-system/preferences'; // Share these values between the document head and the client Provider. export const storageKey = 'example-display-preferences'; export const siteDefaults = { corners: 'soft' } satisfies Partial; export const initialPreferenceScript = createPreferenceScript(storageKey, siteDefaults); // Insert initialPreferenceScript in a