From 55f7d0f5510ce16a2a2e400bcfccb105be6971ce Mon Sep 17 00:00:00 2001 From: Rowan Cockett Date: Mon, 25 Sep 2023 20:52:26 -0600 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Navigation=20clicking=20in=20boo?= =?UTF-8?q?k=20theme=20(#235)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .changeset/giant-owls-matter.md | 5 +++++ packages/site/src/components/Navigation/TableOfContents.tsx | 3 +-- 2 files changed, 6 insertions(+), 2 deletions(-) create mode 100644 .changeset/giant-owls-matter.md diff --git a/.changeset/giant-owls-matter.md b/.changeset/giant-owls-matter.md new file mode 100644 index 000000000..70fa9b7b1 --- /dev/null +++ b/.changeset/giant-owls-matter.md @@ -0,0 +1,5 @@ +--- +'@myst-theme/site': patch +--- + +Fix z-index bug from a11y reordering diff --git a/packages/site/src/components/Navigation/TableOfContents.tsx b/packages/site/src/components/Navigation/TableOfContents.tsx index 161515a1b..bc49a95a8 100644 --- a/packages/site/src/components/Navigation/TableOfContents.tsx +++ b/packages/site/src/components/Navigation/TableOfContents.tsx @@ -168,8 +168,7 @@ export const TableOfContents = ({ 'fixed', `xl:${grid}`, // for example, xl:article-grid 'grid-gap xl:w-screen xl:pointer-events-none overflow-auto max-xl:min-w-[300px]', - { hidden: !open }, - { 'z-30': open }, + { hidden: !open, 'z-30': open, 'z-10': !open }, )} style={{ top }} >