Expand description
A collapsible block: a titled section of a Studio panel that the reader opens and closes.
Its heading is a button — the drawn chevron, then the title in the panel-title type — that says whether the block is expanded and names the region it controls. A closed block is its heading alone and opens wherever it is clicked; an open block closes from its heading, never from its content. Its content stays in the page while it is closed, hidden, so whatever state the content keeps survives a close.
The owner keeps the open state, so the reader’s choice outlives the block’s content coming and going:
use logicaffeine_web::ui::components::collapsible::Collapsible;
let open = use_signal(|| false);
rsx! {
Collapsible { title: "Syntax Tree", open, p { "…" } }
}Re-exports§
pub use Collapsible_completions::Component::Collapsible;
Structs§
- Collapsible
Props - Properties for the
Collapsiblecomponent.
Functions§
- Collapsible
- A titled block of a panel that the reader opens and closes.