From 753b9f0c362da2a9efee5b08e518db5042649059 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Dro=C5=84?= Date: Thu, 27 Jul 2023 13:27:47 +0200 Subject: [PATCH] Add horizontal scrollbar to datagrid views (#4006) * Add scrollbar * Add changeset * Add overflow-y: hidden to prevent scrolling to ghost row --- .changeset/strange-flies-complain.md | 5 +++++ src/components/Datagrid/styles.ts | 6 +----- 2 files changed, 6 insertions(+), 5 deletions(-) create mode 100644 .changeset/strange-flies-complain.md diff --git a/.changeset/strange-flies-complain.md b/.changeset/strange-flies-complain.md new file mode 100644 index 000000000..752bd7270 --- /dev/null +++ b/.changeset/strange-flies-complain.md @@ -0,0 +1,5 @@ +--- +"saleor-dashboard": patch +--- + +Add horizontal scrollbar on datagrid diff --git a/src/components/Datagrid/styles.ts b/src/components/Datagrid/styles.ts index e03b79f68..6d5901f89 100644 --- a/src/components/Datagrid/styles.ts +++ b/src/components/Datagrid/styles.ts @@ -91,15 +91,11 @@ const useStyles = makeStyles<{ actionButtonPosition?: "left" | "right" }>( datagrid: { "& .dvn-scroller": { overscrollBehaviorX: "none", - scrollbarWidth: "none", - }, - "& .dvn-scroller::-webkit-scrollbar": { - display: "none", + overflowY: "hidden", }, borderRadius: 0, boxSizing: "content-box", width: "100%", - paddingBottom: "1px", }, root: { position: "relative",