How can I prevent 'scrolling to the top of the page behavior' when clicking on clr-dg-action-overflow in a datagrid that overflows its container on the y axis? #6438
Replies: 2 comments 2 replies
-
I could confirm the issue, don't have an idea why this is happening - it seems that we need to use |
Beta Was this translation helpful? Give feedback.
-
The example does scroll but the behavior is related to some early css/layout decisions we made back in 2016. The correct way to have a datagrid with rows that overflow its container is to use it in the I forked the stackblitz and added the correct Clarity (angular) application layout. If using the application layout as documented is not an option you will need to recreate something similar with flexbox or grid so that the container for the datagrid has an auto overflow-y and the body doesn't have any content overflow. This has come up before so instead of closing the issue I'll convert this to a discussion so that future folks can find it. |
Beta Was this translation helpful? Give feedback.
-
Describe the bug
I have a page that I use clr-datagrid. I want to make some actions and for this reason I use clr-dg-action-overflow tag. However when I click on the clr-dg-action-overflow, although the menu opens, the whole page scrolls to the top.
How to reproduce
The error can be reproduced in Clarity Project v5.
Steps to reproduce the behavior:
Expected behavior
The page shouldn't scroll to the top
Versions
Clarity project:
Clarity version:
Framework:
Framework version:
ie: Angular 10,11,12
Device:
Beta Was this translation helpful? Give feedback.
All reactions