-
Notifications
You must be signed in to change notification settings - Fork 878
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ScrollArea] Content with ellipsis CSS bursts out of container. #926
Comments
This is blocking us from adopting Scroll Area in the one component we really want it. |
Any updates on this? Also experiencing issues here |
@funwithtriangles We haven't had time to look into any of this yet I'm afraid so no updates. |
@jjenzz no worries. For anyone who's also having problems, I'm just overriding the inline styles for now to get rid of const StyledViewport = styled(ScrollAreaPrimitive.Viewport, {
...
"> div[style]": {
display: "block !important",
},
}) |
I hope this issue is resolved quickly. 🙏 ScrollArea is a really nice component, but this issues make it difficult to use. (I wonder if there is any reason to keep |
@jjenzz do you remember what the reason why for |
it was something to do with making that div the same width of the content for overflow-x calculations i believe. if you remove it and test that things overflow the horizontal axis in a way that matches native scroll behaviour then should be good. |
I have a similar problem and ended up overriding the table to flex instead. In my case I need to stack 2 items per row and I can't see how to achieve that with table. With flex I can set it to flex-wrap, and set each item to be 50% of the width so only 2 items fit before wrapping. |
I have a similar problem and I ended up overriding the table to block as follows:
|
With Tailwind, adding For example: <RadixScrollArea.Root className="overflow-hidden">
<RadixScrollArea.Viewport className="w-full h-full [&>div]:!block">
{children}
</RadixScrollArea.Viewport>
</RadixScrollArea.Root> |
The other workaround is to place div with display:grid as a child of the Viewport, allows to not override viewport style |
When I changed the display from
|
Any updates? |
This comment was marked as duplicate.
This comment was marked as duplicate.
This comment was marked as duplicate.
This comment was marked as duplicate.
This is probably the more inconvenient problem in scrollarea =/ |
it might be possible to remove edit: ah, i just saw there is a PR with an alternate approach already 🙈 ignore! |
Had to revert the fix in #2945, so reopening this. |
@chaance issue is not re-opened? |
Any updates here? I see this issue was opened in 2021, and we are in 2025 now. |
Issue: https://codesandbox.io/s/frosty-cerf-poy3y?file=/src/styles.css
Example of native scrollable without this issue: https://codepen.io/jjenzz/pen/jOLMjvJ
I'm wondering if we still need the
display: table
stuff now so will investigate getting rid of that as a potential solution at some stage.The text was updated successfully, but these errors were encountered: