Expand description
Product-neutral components and interaction primitives for GPUI.
Components read gpui_kit_theme::Theme from the application context and
caller-owned data. They do not know about transports, databases,
credentials, or application hosts. Anything that has to survive a frame —
a text field, a menu, a dialog — is a Render view; everything else is a
RenderOnce builder.
§Modules
foundation— the contracts every component implements:Ident,Disableable,Sizable,Selectable, and the one focus ring,FocusRing.content— rendered Markdown and a conversation, the two surfaces that draw text nobody in this crate wrote. Nothing here executes HTML, opens a link, or fetches an image.controls— actions and editable fields.display— status, grouping, and waiting vocabulary.navigation— tabs, accordions, trails, rails, and pages.data— list, table, and tree.datetime— calendar, date field, range, and time, over a host-suppliedDateAdapter. This crate owns no calendar.layout— split panes, scroll areas, and toolbars.media— an audio player, a video player, and a bounded 3D model viewer, over aMediaTransportthis crate does not implement and a glTF reader that refuses more than it accepts.overlay— anchored and modal surfaces, menus, notifications.interaction— drag and drop, the one gesture that starts in one component and finishes in another.motion— token-driven animation.state— the explicit async states a truthful surface distinguishes.strings— every word this library shows, and the host’s right to replace any of them without losing the English behind the rest.scenes— one canonical rendering per component, shared by the gallery, the capture task, and the headless audit.
§Documentation
docs/components.md— every component and the rules it keeps.docs/coverage.md— what is provided, and what is deliberately not.docs/truthful-ui.md— why a refusal is never rendered as an absence.docs/semantic-automation.md— the semantic tree and what a node reports.docs/token-model.md— where visible values come from.docs/interaction.md— the drag contract: what a drop reports, what a drag publishes, and what the host has to do with it.docs/content.md— what a rendered document is not allowed to do, and what a conversation’s five delivery states mean.
Button::new("settings.save")
.label("Save")
.primary()
.on_click(|_window, _cx| {})Re-exports§
pub use gpui_kit_assets as assets;pub use gpui_kit_semantics as semantics;pub use gpui_kit_theme as theme;pub use gpui_kit_tokens as tokens;
Modules§
- agent
- The vocabulary an agent application needs and a conversation does not.
- canvas
- A run drawn as connected steps on a canvas.
- content
- Prose and conversation: the two surfaces that draw content nobody in this crate wrote.
- controls
- Interactive controls that emit caller-owned actions.
- data
- Large-data surfaces: a virtualized list, two tables, and a tree.
- datetime
- Date and time selection over a calendar this crate does not own.
- display
- Components that present caller-owned data without owning it.
- foundation
- The contracts every component in this library implements.
- interaction
- Interaction systems that span more than one component.
- layout
- Frames that decide where other components sit.
- media
- Sound, moving pictures, and geometry — none of it decoded here.
- motion
- Motion primitives that respect the user’s reduced-motion preference.
- navigation
- Navigation and disclosure: tabs, accordion sections, a breadcrumb trail, a collapsible rail, and page controls.
- overlay
- Floating surfaces that render above the page.
- prelude
- Everything a view needs to build with this library.
- scenes
- One canonical rendering per component.
- state
- Explicit async states for truthful user interfaces.
- strings
- The words this library puts on screen, and the host’s right to replace them.
- structured
- Structured data a host hands over: a value tree, and a form generated from a description of one.
Functions§
- install
- Installs fonts, the theme global, and the semantic registry.