공개 문서
docs/reference/omni-command-palette/README.md
아래는 docs/reference/omni-command-palette/README.md 와 동일한 원문입니다. Markdown과 HTML 변환 결과를 각각 복사할 수 있습니다.
공개 문서 원문 (Markdown)
# Omni Command Palette
> **컴포넌트**: `components/ui/omni-command-palette.tsx` · **데모**: `/omni-demo` (⌘K / Ctrl+K)
## 개요
허브·대시보드에서 **명령·페이지·사람** 등을 fuzzy 검색하는 **Radix Dialog + Command** 기반 팔레트입니다.
`HubCommandPalette`·허브 사이드바 ⌘K 와 별도로, **재사용 가능한 UI 프리미티브**로 분리되어 있습니다.
## import
```tsx
import {
OmniCommandPalette,
type OmniItem,
type OmniSource,
} from "@/components/ui/omni-command-palette";
// 또는 배럴: @/components/ui
```
## 주요 props
| prop | 설명 |
|------|------|
| `sources` | `OmniSource[]` — 그룹별 `fetch(query)` 로 항목 로드 |
| `open` / `onOpenChange` | 제어형 열림 상태 |
| `storageKey` | 최근 실행 항목 localStorage 키 |
| `openKeys` | 단축키 (기본 ⌘K / Ctrl+K) |
| `showRecents` | 최근 항목 섹션 표시 |
## OmniItem 필드
- `id`, `label`, `groupId` (필수)
- `subtitle`, `href`, `icon`, `shortcut`, `keywords`
- `onAction` — 클릭 시 커스텀 동작
- `pinned` — 상단 고정
## 데모
로컬·프로덕션 모두 `/omni-demo` 에서 `OmniCommandPaletteDemo` 로 동작을 확인할 수 있습니다.
## 관련 규칙
- `.cursor/rules/apple-theme-ui-components.mdc` — `components/ui` import·금지 사항
- `docs/reference/frontend-section-conventions.md` — Tailwind·라우팅 컨벤션
## 허브 메뉴
OpenClaw 허브 사이드바 **OMNI → README / 요약·주의사항** 은 이 폴더 문서를 `/openclaw-files/docs/reference/omni-command-palette/*` 로 서빙합니다.
공개 문서 변환 코드 (HTML)
<h1>Omni Command Palette</h1>
<blockquote>
<p><strong>컴포넌트</strong>: <code>components/ui/omni-command-palette.tsx</code> · <strong>데모</strong>: <code>/omni-demo</code> (⌘K / Ctrl+K)</p>
</blockquote>
<h2>개요</h2>
<p>허브·대시보드에서 <strong>명령·페이지·사람</strong> 등을 fuzzy 검색하는 <strong>Radix Dialog + Command</strong> 기반 팔레트입니다.<br><code>HubCommandPalette</code>·허브 사이드바 ⌘K 와 별도로, <strong>재사용 가능한 UI 프리미티브</strong>로 분리되어 있습니다.</p>
<h2>import</h2>
<pre><code class="language-tsx">import {
OmniCommandPalette,
type OmniItem,
type OmniSource,
} from "@/components/ui/omni-command-palette";
// 또는 배럴: @/components/ui
</code></pre>
<h2>주요 props</h2>
<table>
<thead>
<tr>
<th>prop</th>
<th>설명</th>
</tr>
</thead>
<tbody><tr>
<td><code>sources</code></td>
<td><code>OmniSource[]</code> — 그룹별 <code>fetch(query)</code> 로 항목 로드</td>
</tr>
<tr>
<td><code>open</code> / <code>onOpenChange</code></td>
<td>제어형 열림 상태</td>
</tr>
<tr>
<td><code>storageKey</code></td>
<td>최근 실행 항목 localStorage 키</td>
</tr>
<tr>
<td><code>openKeys</code></td>
<td>단축키 (기본 ⌘K / Ctrl+K)</td>
</tr>
<tr>
<td><code>showRecents</code></td>
<td>최근 항목 섹션 표시</td>
</tr>
</tbody></table>
<h2>OmniItem 필드</h2>
<ul>
<li><code>id</code>, <code>label</code>, <code>groupId</code> (필수)</li>
<li><code>subtitle</code>, <code>href</code>, <code>icon</code>, <code>shortcut</code>, <code>keywords</code></li>
<li><code>onAction</code> — 클릭 시 커스텀 동작</li>
<li><code>pinned</code> — 상단 고정</li>
</ul>
<h2>데모</h2>
<p>로컬·프로덕션 모두 <code>/omni-demo</code> 에서 <code>OmniCommandPaletteDemo</code> 로 동작을 확인할 수 있습니다.</p>
<h2>관련 규칙</h2>
<ul>
<li><code>.cursor/rules/apple-theme-ui-components.mdc</code> — <code>components/ui</code> import·금지 사항</li>
<li><code>docs/reference/frontend-section-conventions.md</code> — Tailwind·라우팅 컨벤션</li>
</ul>
<h2>허브 메뉴</h2>
<p>OpenClaw 허브 사이드바 <strong>OMNI → README / 요약·주의사항</strong> 은 이 폴더 문서를 <code>/openclaw-files/docs/reference/omni-command-palette/*</code> 로 서빙합니다.</p>