Expand description
§use-ui-component
Component identity and metadata primitives for RustUse UI.
§Purpose
use-ui-component describes component names, IDs, parts, slots, variants, sizes, and semantic roles. It does not implement actual UI components or bind to any component framework.
§Example
use use_ui_component::{ComponentName, ComponentRole, ComponentSize, ComponentSlot};
let name = ComponentName::new("button");
let slot = ComponentSlot::new("leading");
assert_eq!(name.as_str(), "button");
assert_eq!(slot.as_str(), "leading");
assert_eq!(ComponentSize::Md.as_str(), "md");
assert!(ComponentRole::Control.is_interactive_role());§Main types
ComponentNameComponentIdComponentPartComponentSlotComponentVariantComponentSizeComponentRole
§Facade relationship
The use-ui facade exposes this crate as use_ui::component when the component or full feature is enabled.
Structs§
Enums§
- Component
Role - Semantic component roles.
- Component
Size - Component size labels.