Closed cx0onl closed 3 years ago
Hi @cx0onl, thanks for reporting! I cannot think of a way we can fix it on our side, as it seems to be a browser behavior. Maybe you have any ideas?
It looks like the problem is comming from the calculation of the child width.
For each child element, the spacing is subtracted. 3 children = 3 gaps. This is wrong.
@rtivital You added this lines in July: https://github.com/mantinedev/mantine/commit/53d903fd888fab38ea577a193a10e2865a3f4333
calc(${100 / count}% - ${(count - 1/count) * theme.fn.size({ size: spacing, sizes: theme.spacing })}px)
Mayby this should fix it? Only add count - 1 / count (eg. 2/3) spacing to each child.
I've released a patch 3.2.2 with a fix, can you please update and see if it works for you?
Yes. Now it works like a charm. :-)
Issue is closed.
Hello together!
First of all congratulations and thanks for Mantine! This is by far the best library for React out there!
I use the Group component very often in my UI. In doing so, I have noticed several bugs:
1.) An unwanted gap is inserted after the last item. Therefore the items do not use the whole available width.
2.) With the combination of "grow" and "apart" the spacings between the items are no longer correct.
I would expect both variants ("left/grow" and "apart/grow") to give the same result: Three items of equal (grown) width with two correct spacings in between.
Thanks!