Skip to content

Commit

Permalink
add overflow-y to Doc sidebar and TOC (#176)
Browse files Browse the repository at this point in the history
  • Loading branch information
Roma36 authored Sep 22, 2023
1 parent 95a4fab commit 50d2edd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/theme/DocPage/Layout/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export default function DocPageLayoutSidebar({
return (
<aside className={className}>
<ResetOnSidebarChange>
<div className="p-2 xl:p-4 text-sm xl:text-base w-full sticky top-0">
<div className="p-2 xl:p-4 text-sm xl:text-base w-full sticky top-0 max-h-screen overflow-y-auto">
<DocSidebar
sidebar={sidebar}
path={pathname}
Expand Down
2 changes: 1 addition & 1 deletion src/theme/TOC/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export default function TOC({ className, ...props }: Props) {
return (
<div
className={clsx(
"sticky top-0 p-2 xl:p-4 text-sm xl:text-base",
"sticky top-0 p-2 xl:p-4 text-sm xl:text-base max-h-screen overflow-y-auto",
className,
)}
>
Expand Down

0 comments on commit 50d2edd

Please sign in to comment.