Wrong documentation of sizing attribute of c-button-group
Closed this issue · 4 comments
In the "Sizing" section of the c-button-group documentation, the example uses "sizing" as attribute for changing the size of all buttons inside the group.
But it is visible, that this is not working, since all buttons of the three displayed groups have the same size.
In the "API" section it is declared, that the attribute should be "size" and this works in my project.
So either the documentation or the attribute needs to be corrected.
It may be important to keep in mind, that the related attribute for the FormLabelDirective is "sizing". So one would assume, that it should be "sizing" for ButtonGroupComponent too. Therefore the documentation is correct and the API needs to be adjusted.
"size" seems to be more used by other controls. So maybe the "sizing" of FormLabelDirective should be changed to "size"?
Correcting the documentation would be enough of course.
The reason behind using the sizing property was to prevent conflicts with the size html attribute (input, select). Since sizing is determined by size modifiers (usually lg, sm, default: md), adopting a consistent property name seemed logical. Unfortunately, this rule wasn’t followed for certain components.
The API modification introduces a breaking change, but we’re open to reasonable suggestions to address the inconsistency.
I understand and it is really just a minor problem.
But the documentation should be corrected.
@bernik1980 - fixed, thanks!