-
Notifications
You must be signed in to change notification settings - Fork 9
Component ButtonGroup
MeowLynxSea edited this page Jun 18, 2026
·
4 revisions
A horizontal or vertical container that visually groups buttons.
use yororen_ui::headless::button::button;
use yororen_ui::headless::button_group::button_group;
button_group("align", cx)
.attached(true)
.child(button("left", cx).caption("Left").render(cx))
.child(button("center", cx).caption("Center").render(cx))
.child(button("right", cx).caption("Right").render(cx))
.render(cx)| Method | Purpose |
|---|---|
vertical() |
Stack children top-to-bottom (default: horizontal). |
attached(v) |
Visually merge children into a single segmented control. |
child(stateful) |
Append one rendered child (Stateful<Div>). |
Children must be passed in already-rendered form — call .render(cx) on each child and pass the result to .child(...).
.render(cx) returns Stateful<Div>.
See also: Button, ToggleButton.
Yororen UI v0.3.0 · repository · Apache-2.0 · This wiki documents Yororen UI v0.3.0.
This wiki documents Yororen UI v0.3.0 — the headless-core, swappable-renderer build.