Skip to content

Commit

Permalink
💄(react) use overflow auto instead of scroll
Browse files Browse the repository at this point in the history
Currently, Tooltip and Datagrid components are set to always scroll bar.
This is weird, as the scrollbar is always shown even if this is not
needed. Instead, we use `auto` value to display it only when
it is needed
  • Loading branch information
jbpenrath committed Aug 20, 2024
1 parent 1514e4f commit b374eb8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/hip-masks-love.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@openfun/cunningham-react": patch
---

Use `overflow:auto` instead of `overflow:scroll`
2 changes: 1 addition & 1 deletion packages/react/src/components/DataGrid/_index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

&__table__container {
width: 100%;
overflow: scroll;
overflow: auto;

> table {
border-collapse: collapse;
Expand Down
2 changes: 1 addition & 1 deletion packages/react/src/components/Tooltip/_index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
}

&__content {
overflow: scroll;
overflow: auto;
}
}

Expand Down

0 comments on commit b374eb8

Please sign in to comment.