DBeaverやNavicatなどの接続情報を取り込むWASM拡張の実装から、マニフェスト設定、ホスト連携、表示やプレビューの不具合調査まで扱います。
- 新しい接続インポーターを作りたいとき
- WASM拡張が表示されない原因を調べたいとき
- 接続プレビューの停止を調査したいとき
GPUIアプリのUIをgpui-componentで組み立てる際に、コンポーネントの選び方や状態管理、テーマ、レイアウト、操作設計、実装規約を確認できます。
How to use the gpui-component UI library in GPUI applications, and the normative Design and Coding Guides that govern it. Use when building UIs with gpui-component components (Button, Input, Select, Dialog, Tabs, Sidebar, List, Table, etc.), setting up the library, handling component state or theming, finding the right component for a UI need, and also when designing layouts, spacing, visual hierarchy, or interaction states, writing interface copy, or making application architecture, state-ownership, or public API decisions.
実行スコア 未検証
インストール方法を見るGPUIアプリでgpui-componentを使うためのコンポーネント選択、セットアップ、状態管理、テーマ設定を案内します。Button、Input、Select、Dialog、Tabs、Sidebar、List、Tableなどの用途を確認でき、フォーム、通知、ポップアップ、ナビゲーション、データ表示、チャートも扱います。画面を変更する前には、デザインガイドとコーディングガイドの該当箇所を確認する前提です。ガイドはレイアウトや余白、視覚的な優先順位、操作状態、状態の所有場所、公開APIなどの判断基準を示します。
GPUIで画面を新しく作るとき、既存画面にコンポーネントを追加するとき、UIの一貫性やアプリ構成を検討するときに向いています。部品のAPIや使い分けを確認したい開発者にも役立ちます。
gpui-componentを使うGPUIアプリが対象です。UIやアーキテクチャを変更する前に、付属のガイドを確認する必要があります。
この紹介文は、公開されている SKILL.md をもとに AI(OpenAI Codex)が作成しました。正確な仕様は下の原文を確認してください。
インストールする前に、エージェントに与えられる指示の中身を確認できます。
Before changing UI, interaction, interface language, layout, styling, components, or application architecture, read the relevant guide:
| Guide | Read before |
|---|---|
| Design Guides | Choosing components, layout, spacing, hierarchy, color, density, interaction states, overlays, interface copy |
| Coding Guides | Crate layering, RenderOnce vs Entity<T>, state ownership, ElementId, focus, async, public API, testing |
These guides are requirements, not optional inspiration. Do not copy generic web conventions, infer a design system from one existing screen, or add a control merely because the underlying feature exists. Review the finished work against both guides before considering it complete.
Read the guide file itself. Do not answer from what this page summarizes, from an existing screen in the codebase, or from training data — those are the three ways the guides get quietly ignored.
These are a floor, not a substitute. Read the guide for anything past this list.
Button vs Link. Button for every in-app command — use ghost or
outline when it should read quietly. Link only for external URLs and
email addresses.rgb(...) in application UI; use
cx.theme() semantic tokens. Use rem-based helpers (p_2(), gap_3(),
text_sm()) so window zoom works. Any spacing number you see quoted is the
current default scale, not a literal to repeat.ElementIds, not
list indexes.Delete “Roadmap”? with a Delete
button, not Are you sure? with OK.https://longbridge.github.io/gpui-component/llms-full.txthttps://longbridge.github.io/gpui-component/docs/components/{name}.md
button.md, input.md, select.md, dialog.md, data-table.md.md to the URLSetup — always required:
gpui_component::init(cx); // in app.run(), must be first
Root::new(view, window, cx) // first-level view in every window
Stateless — use directly in render:
Button::new("id").primary().label("OK").on_click(|_, _, _| {})
Stateful — hold Entity<State> in struct, pass ref in render:
// in new(): let input = cx.new(|cx| InputState::new(window, cx));
// in render: Input::new(&self.input)
Sizes: .xsmall() .small() .medium() (default) .large()
Theme: cx.theme().primary · .background · .foreground · .border · .muted
When you need a component, find it here. For full API, fetch its .md doc.
| Component | Import | Notes |
|---|---|---|
Input | input::{Input, InputState} | Stateful. Text, password, mask, validation |
NumberInput | input::{NumberInput, NumberInputEvent} | Stateful. Numeric with step |
OtpInput | input::OtpInput | Stateful. One-time password |
Select | select::{Select, SelectState} | Stateful. Dropdown picker |
Combobox | combobox::{Combobox, ComboboxState} | Stateful. Searchable select |
Checkbox | checkbox::Checkbox | Stateless. `on_click( |
Switch | switch::Switch | Stateless. Toggle |
Radio | radio::{Radio, RadioGroup} | Stateless. |
Slider | slider::{Slider, SliderState} | Stateful. |
Toggle | button::Toggle | Stateless. |
Rating | rating::Rating | Stateless. |
Stepper | stepper::Stepper | Stateless. Increment/decrement |
ColorPicker | color_picker::{ColorPicker, ColorPickerState} | Stateful. |
DatePicker | date_picker::{DatePicker, DatePickerState} | Stateful. |
Form | form::{v_form, h_form, field} | Layout container for form fields |
| Component | Import | Notes |
|---|---|---|
Button | button::{Button, ButtonGroup} | Stateless. Primary UI action |
Icon | {Icon, IconName} | Stateless. Lucide icons |
Badge | badge::Badge | Stateless. |
Tag | tag::Tag | Stateless. Closable tags |
Avatar | avatar::Avatar | Stateless. |
Label | label::Label | Stateless. Form label |
Kbd | kbd::Kbd | Stateless. Keyboard key display |
Alert | alert::Alert | Stateless. Info/success/warning/error |
Spinner | spinner::Spinner | Stateless. Loading indicator |
Skeleton | skeleton::Skeleton | Stateless. Loading placeholder |
Progress | progress::{Progress, ProgressCircle} | Stateless. |
Tooltip | tooltip::Tooltip | Via .tooltip() on elements |
HoverCard | hover_card::{HoverCard, HoverCardState} | Stateful. |
Clipboard | clipboard::Clipboard | Stateless. Copy button |
| Component | Import | Notes |
|---|---|---|
Dialog | dialog::Dialog + WindowExt | Via window.open_dialog(...) |
AlertDialog | WindowExt | Via window.open_alert_dialog(...) |
Sheet | sheet::Sheet + WindowExt | Side panel, via window.open_sheet(...) |
Notification | notification::Notification + WindowExt | Via window.push_notification(...) |
Popover | popover::Popover | Floating overlay |
Menu | menu::{PopupMenu, DropdownMenu} | Context menus |
DropdownButton | button::DropdownButton | Button with dropdown menu |
| Component | Import | Notes |
|---|---|---|
Tabs / TabBar | tab::{Tab, TabBar} | Tabbed interface |
Sidebar | sidebar::{Sidebar, SidebarMenu, ...} | App navigation panel |
TitleBar | TitleBar | Window title bar |
Breadcrumb | breadcrumb::Breadcrumb | Navigation breadcrumb |
Pagination | pagination::Pagination | Page navigation |
Accordion | accordion::Accordion | Collapsible sections |
Collapsible | collapsible::Collapsible | Single collapsible |
GroupBox | group_box::GroupBox | Labeled container |
Resizable | resizable::{h_resizable, v_resizable, resizable_panel, ResizableState} | Draggable split panes |
Scrollable | scroll::Scrollbar | Custom scrollbar |
FocusTrap | gpui_base::focus_trap::FocusTrapElement | Keyboard trap for modals |
| Component | Import | Notes |
|---|---|---|
DataTable | table::{DataTable, TableState, TableDelegate} | Stateful. Full-featured table |
Table | table::{Table, ...} | Simpler table |
VirtualList | {v_virtual_list, h_virtual_list} | High-perf large lists |
List | list::{List, ListState, ListDelegate} | Stateful. Searchable list |
Tree | tree::{Tree, TreeState, TreeItem, TreeEntry} | Stateful. Hierarchy |
DescriptionList | description_list::DescriptionList | Key-value pairs |
Settings | setting::Settings | Settings panel |
| Component | Import | Notes |
|---|---|---|
Chart | chart::{AreaChart, BarChart, LineChart, PieChart, RadarChart} | Bar, line, area, pie charts |
Plot | plot::Plot | #[derive(IntoPlot)] for data |
まだレビューはありません。使ってみた感想をお寄せください。
ログインなしで書き込めます。使ってみた感想、質問、動かなかった環境などを気軽にどうぞ。
まだコメントはありません。最初のコメントを書いてみませんか。
DBeaverやNavicatなどの接続情報を取り込むWASM拡張の実装から、マニフェスト設定、ホスト連携、表示やプレビューの不具合調査まで扱います。
GPUIアプリの開発で、キー操作や画面レイアウト、状態管理、イベント、テストなどのAPIや実装パターンを調べ、必要な知識を参照できます。
onetcliのIPCデータベースドライバーを、マニフェストやJSON-RPCの契約に沿って設計・実装・レビューし、メタデータ、DDL、入出力や配布まで扱うスキルです。
起動中のNavopデスクトップアプリが公開するリソースや操作を、CLIから確認して実行できます。利用可能なツールや権限を調べ、承認に沿って処理を進めます。
Navopの変更内容を中国語と英語でまとめ、CHANGELOG.mdを基準にGitHub ReleasesやR2のリリースノートを準備・確認するスキルです。
既存の実装やデザイン規則に沿って、GPUIの新しいUIコンポーネントを設計・実装し、関連ドキュメントとストーリーも用意するスキルです。