Connect, collaborate, and grow with a community of TypeScript developers
add custom scrollbar to avoid layout shift (#199) (#220)
Ernesto Resendee43809919a67
diff --git a/src/app/challenge/[id]/left-wrapper.tsx b/src/app/challenge/[id]/left-wrapper.tsxindex 39df3ffd..78e5324f 100644--- a/src/app/challenge/[id]/left-wrapper.tsx+++ b/src/app/challenge/[id]/left-wrapper.tsx@@ -30,7 +30,7 @@ export function LeftWrapper({ challengeId, children }: Props) {return (<TabsdefaultValue={selectedTab}- className="flex h-full w-full flex-col overflow-y-auto overflow-x-hidden"+ className="custom-scrollable-element flex h-full w-full flex-col overflow-x-hidden overflow-y-scroll"><TabsList className="sticky top-0 z-10 grid h-auto w-full grid-cols-3 rounded-none rounded-tl-2xl rounded-tr-xl border-b border-zinc-300 bg-background/90 backdrop-blur-sm dark:border-zinc-700 dark:bg-muted/90"><TabsTriggerdiff --git a/src/styles/globals.css b/src/styles/globals.cssindex a925d848..45442a7e 100644--- a/src/styles/globals.css+++ b/src/styles/globals.css@@ -138,3 +138,11 @@ main {.w-md-editor-preview .wmde-markdown {@apply bg-muted;}++.custom-scrollable-element {+ scrollbar-width: none;+}++.custom-scrollable-element::-webkit-scrollbar {+ width: 0;+}