Module Value_selector.Button
Button selectors.
The value is selected by clicking in a list of buttons. See the styling information.
Selector
val v :
?class':Jstr.t ->
?enabled:bool Note.signal ->
?button_class:('a -> Jstr.t) ->
?button_tip:('a -> Jstr.t Note.signal) ->
?xdir_align:Note_brr_kit.Ui.Group.align ->
?dir_align:Note_brr_kit.Ui.Group.align ->
dir:Note_brr_kit.Ui.Group.dir ->
('a -> Brr.El.t list Note.signal) ->
'a list Note.signal ->
'a option Note.signal ->
'a Note_brr_kit.Ui.Group.tv ~class' ~enaled ~eq label choices sel is list of buttons for selecting a value. S.eq sel is used to test values for equality in the list of choices.
labelis used to label the choice buttons.choicesare the values among which to selectselis the value shown as selected, if any. It must be included inchoicesbutton_classis a class for choice buttons.enabledindicates if the selector can be interacted with. Defaults toNote.S.Bool.true'class'is added to the underlying element's classes.
The Group.action of the result occurs whenever a new selection occurs.
Styling
The returned group and buttons makes use of the following CSS classes (the group styling also applies):
ui-button-selectoralways on the groupui-selectedon the button currently selectedui-disabledon the group and buttons wheneverenabledisfalse.