Frezyx/group_button

Consider api deduplication

vasilich6107 opened this issue · 1 comments

Currently package has
selectedButton
selectedButtons

also has
_selectedIndexes
_selectedIndex

Consider simplifying the api to be more generic.
In case of isRadio the _selectedIndexes could be limited to only one item - this will simplifies the api and internal logic

Now this is solved only by factory constructors, which simplify creation of different types buttons.
GroupButton.radio()
GroupButton.checkbox()

In future, I want to do this at controller level, to simplify package logic and make him more lightweight. But now i don't understand how i can make it.