Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

Add custom scrollbar style to users table

Terry Suttonbfc6966fe9c7
diff --git a/studio/components/interfaces/Auth/Users/Users.tsx b/studio/components/interfaces/Auth/Users/Users.tsx
index 7b98567c2e1..48fc8b5fb3c 100644
--- a/studio/components/interfaces/Auth/Users/Users.tsx
+++ b/studio/components/interfaces/Auth/Users/Users.tsx
@@ -53,7 +53,7 @@ const Users = () => {
}
return (
- <div className="overflow-scroll hide-scrollbar">
+ <div>
<div className="justify-between px-6 pt-6 pb-2 md:flex">
<div className="relative flex space-x-4">
<Input
@@ -108,8 +108,8 @@ const Users = () => {
{inviteEnabled && <InviteUserModal />}
</div>
</div>
- <section className="mt-4 overflow-visible px-6">
- <div className="section-block--body relative overflow-scroll rounded hide-scrollbar">
+ <section className="users-table-container mt-4 overflow-visible px-6">
+ <div className="section-block--body relative overflow-scroll rounded">
<div className="inline-block min-w-full align-middle">
<UsersList />
</div>
diff --git a/studio/pages/_app.tsx b/studio/pages/_app.tsx
index 64b3e5375c8..deefe6cd8ee 100644
--- a/studio/pages/_app.tsx
+++ b/studio/pages/_app.tsx
@@ -10,6 +10,7 @@ import 'styles/contextMenu.scss'
import 'styles/react-data-grid-logs.scss'
import 'styles/date-picker.scss'
import 'styles/grid.scss'
+import 'styles/users-table.scss'
import dayjs from 'dayjs'
import customParseFormat from 'dayjs/plugin/customParseFormat'
diff --git a/studio/styles/users-table.scss b/studio/styles/users-table.scss
new file mode 100644
index 00000000000..c582fb0ff86
--- /dev/null
+++ b/studio/styles/users-table.scss
@@ -0,0 +1,32 @@
+.users-table-container {
+ ::-webkit-scrollbar {
+ background: var(--colors-slate2);
+ height: 3px;
+ width: 0px;
+ border-radius: 0;
+
+ .dark & {
+ background: var(--colors-slate6);
+ }
+ }
+
+ ::-webkit-scrollbar-track {
+ -webkit-box-shadow: inset 0 0 6px var(--colors-slate6);
+ -webkit-border-radius: 5px;
+ border-radius: 5px;
+
+ .dark & {
+ -webkit-box-shadow: inset 0 0 6px var(--colors-slate8);
+ }
+ }
+
+ ::-webkit-scrollbar-thumb {
+ -webkit-border-radius: 5px;
+ border-radius: 5px;
+ background: var(--colors-slate9);
+
+ .dark & {
+ -webkit-box-shadow: inset 0 0 6px var(--colors-slate12);
+ }
+ }
+}