ButtonGroupWidget
extends CInputWidget
in package
Creates a Buttongroup that behaves like a switch with radio input type
Table of Contents
Properties
- $ariaLabel : string
- $checkedOption : array<string|int, mixed>
- $htmlOptions : array<string|int, mixed>
- $selectOptions : array<string|int, mixed>
Methods
- init() : mixed
- Initializes the widget
- registerClientScript() : mixed
- Registers required script files
- renderButtons() : mixed
- Renders the button group
- run() : mixed
- Executes the widget
Properties
$ariaLabel
public
string
$ariaLabel
= ''
aria label for btn-group
$checkedOption
public
array<string|int, mixed>
$checkedOption
= ''
the value that is currently checked/selected
$htmlOptions
public
array<string|int, mixed>
$htmlOptions
= []
html options
$selectOptions
public
array<string|int, mixed>
$selectOptions
= []
Available buttons as value=>caption array
Methods
init()
Initializes the widget
public
init() : mixed
registerClientScript()
Registers required script files
public
registerClientScript() : mixed
renderButtons()
Renders the button group
public
renderButtons() : mixed
run()
Executes the widget
public
run() : mixed