Skip to content

Commit

Permalink
fix(readme): conflict with search page (#524)
Browse files Browse the repository at this point in the history
  • Loading branch information
kyrie25 authored Jun 24, 2023
1 parent a63004f commit 6b5445a
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/components/ReadmePage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,14 @@ class ReadmePage extends React.Component<
const main = document.querySelector("#marketplace-readme")?.closest("main");
if (main) {
const callScrollbar = setInterval(() => {
if (!document.querySelector("#marketplace-readme")) {
clearInterval(callScrollbar);
main.style.removeProperty("overflow-y");
return;
}
// TODO: see if it's possible to use some load event or mutation observer to do this
main.style.overflowY = "visible";
main.style.overflowY = "auto";
if (!document.querySelector(".os-scrollbar-vertical.os-scrollbar-unusable") || !main)
clearInterval(callScrollbar);
}, 1000);
}

Expand Down

0 comments on commit 6b5445a

Please sign in to comment.