Skip to content

Commit

Permalink
Ensure only one element has scroll
Browse files Browse the repository at this point in the history
Apparently having multiple elements with scroll confuses the
`react-beautiful-dnd` mechanism to determine the position of the
elements. Adding `overflowY` to the app root fixes it.
  • Loading branch information
Alejandro Fernández Gómez committed Feb 20, 2020
1 parent e23b547 commit a1c32a6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions x-pack/plugins/infra/public/apps/start_app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ export async function startApp(
// expected.
element.style.height = '100%';
element.style.display = 'flex';
element.style.overflowY = 'hidden'; // Prevent having scroll within a container having scroll. It messes up with drag-n-drop elements
element.className += ` ${CONTAINER_CLASSNAME}`;

ReactDOM.render(<App />, element);
Expand Down

0 comments on commit a1c32a6

Please sign in to comment.