Add label method to Toggler

This commit is contained in:
Héctor Ramón Jiménez 2024-09-11 00:20:23 +02:00
parent c741688b4c
commit 6e4970c01a
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
5 changed files with 17 additions and 11 deletions

View file

@ -77,7 +77,8 @@ impl Styling {
let checkbox = checkbox("Check me!", self.checkbox_value)
.on_toggle(Message::CheckboxToggled);
let toggler = toggler(Some("Toggle me!"), self.toggler_value)
let toggler = toggler(self.toggler_value)
.label("Toggle me!")
.on_toggle(Message::TogglerToggled)
.spacing(10);