Closed julianYaman closed 1 year ago
It is already possible, if I'm not wrong. The buttons doesn't have defined sizes by default, they will fit to the parent size. It means that, if you do something like:
<Button.Group>
<div className="w-10">
<Button color="gray">Profile</Button>
</div>
<div className="w-10">
<Button color="gray">Settings</Button>
</div>
<div className="w-10">
<Button color="gray">Messages</Button>
</div>
</Button.Group>
It should limit the size of the buttons. Could you please check if it works for you?
@julianYaman does it help?
Hey @rluders sorry, missed replying to you. Had my final exams recently. I'm going to try it with your solution, thanks 👍
@rluders That solution doesn't work because ButtonGroup
currently assumes the immediate children are Button
s. We might need to add a ButtonGroupContext
and switch off of prop drilling to allow that behavior.
See related #318
This can be done by using the theme system.
Is your feature request related to a problem? Please describe. I would like to have a Button group of small buttons in the same row as the Pagination component. But that's not really the issue. I just would like them to have the same size (small in this case).
Describe the solution you'd like Add an attribute to allow for sizing of the Pagination component buttons
Describe alternatives you've considered There aren't really any alternatives. Maybe to make the buttons larger again, which I don't really prefer.
Additional context