# Upstage Design System — Sidebar (product)
- context: product · group: navigation
- source revision: lift-1.2.3 (Lift 1.2.3, zip sha256 8d5d9377c2b4…)
- status: content source-derived · availability implemented · verification static-only
- human docs: /ko/components/product/sidebar/ · machine doc: /agent/components/product/sidebar.md
## Required references (read these)
- /components/navigation/Sidebar.jsx — implementation · sha256 d763f885de5e…
- /components/_types.d.ts — api · key SidebarProps
- /components/navigation/Sidebar.prompt.md — usage-note · sha256 993ba1539e7a…
- /kit/rules/a11y-contract.json — a11y · key Sidebar
## API (components/_types.d.ts SidebarProps)
- items?: Array<{ id: string; label: React.ReactNode; icon?: React.ReactNode; section?: string }> (default [])
- activeId?: string
- onSelect?: (id: string) => void
- header?: React.ReactNode
- footer?: React.ReactNode
- width?: number (default 232)
- ariaLabel?: string (default 섹션 내비게이션) — <nav>의 접근성 이름.
- style?: React.CSSProperties
## Accessibility contract
- keys: -
- aria: aria-label, aria-current=page
## Unverified
- Browser behaviour is not verified here (static source check only).
지원 환경
Lift 1.2.3 의 참조 구현은 React 18 함수 컴포넌트다. 스타일은 인라인이고 색은 Product 토큰(hsl(var(--*)))을 참조하므로 styles.product.css 가 로드돼 있어야 한다. npm 패키지와의 대응은 이 저장소에서 확인하지 못했다.
API
components/_types.d.ts 의 SidebarProps 를 그대로 옮겼다.
| prop | type | default | doc |
|---|---|---|---|
items | Array<{ id: string; label: React.ReactNode; icon?: React.ReactNode; section?: string }> | [] | |
activeId | string | — | |
onSelect | (id: string) => void | — | |
header | React.ReactNode | — | |
footer | React.ReactNode | — | |
width | number | 232 | |
ariaLabel | string | 섹션 내비게이션 | <nav>의 접근성 이름. |
style | React.CSSProperties | — |
코드
가져오기 한 줄과 사용 지침 원문의 예시 코드다.
import { Sidebar } from "./components/navigation/Sidebar.jsx";<Sidebar
header={<img src="assets/brand/upstage_lockup_black.svg" height="20" />}
items={[{id:"keys", label:"API Keys", section:"Manage"}]}
activeId="keys" onSelect={go}
/>토큰 연결
구현 파일이 var() 로 직접 참조하는 토큰. 조건에 따라 이름을 조립하는 토큰(예: --state-${tone}-fg)은 빠진다.
--duration-fast, --font-sans, --foreground, --muted-foreground, --sidebar-background, --sidebar-border, --sidebar-foreground, --sidebar-item-highlight
출처
components/navigation/Sidebar.jsximplementation · sha256 d763f885de5e…components/_types.d.tsapi · SidebarPropscomponents/navigation/Sidebar.prompt.mdusage-note · sha256 993ba1539e7a…kit/rules/a11y-contract.jsona11y · Sidebar