diff options
Diffstat (limited to 'docs/public')
-rw-r--r-- | docs/public/index.css | 17 | ||||
-rw-r--r-- | docs/public/nav.js | 37 | ||||
-rw-r--r-- | docs/public/theme.css | 5 |
3 files changed, 1 insertions, 58 deletions
diff --git a/docs/public/index.css b/docs/public/index.css index ee0673702..5f382e7d0 100644 --- a/docs/public/index.css +++ b/docs/public/index.css @@ -282,21 +282,6 @@ img { align-items: center; } -header button { - background-color: var(--theme-bg); -} - -header button:hover, -header button:focus { - outline: var(--theme-text) solid 1px; -} - -header button:active, -header button[aria-pressed='true'] { - background: var(--theme-text); - color: var(--theme-bg); -} - button { display: flex; align-items: center; @@ -452,7 +437,7 @@ h2.heading { font-size: larger; top: 0.5rem; left: 0.5rem; - z-index: 999; + z-index: 9; display: block; background-color: var(--theme-bg); color: var(--theme-text-accent); diff --git a/docs/public/nav.js b/docs/public/nav.js deleted file mode 100644 index d6c2bcda3..000000000 --- a/docs/public/nav.js +++ /dev/null @@ -1,37 +0,0 @@ -const nav = document.querySelector('body > header'); - -if (!window.matchMedia('(prefers-reduced-motion)').matches) { - window.addEventListener('scroll', onScroll, { passive: true }); -} - -let prev = -1; -let prevDir = 0; -let threshold = 32; - -function onScroll() { - const curr = window.scrollY; - const dir = curr > prev ? 1 : -1; - - if (curr < threshold) { - show(); - document.documentElement.classList.add('initial'); - } else if (dir !== prevDir) { - if (dir === 1) { - hide(); - } else { - show(); - } - } - - prev = curr; -} - -const hide = () => { - nav.classList.add('hidden'); - document.documentElement.classList.add('scrolled'); - document.documentElement.classList.remove('initial'); -}; -const show = () => { - nav.classList.remove('hidden'); - document.documentElement.classList.remove('scrolled'); -}; diff --git a/docs/public/theme.css b/docs/public/theme.css index c43a9e303..1eec0a709 100644 --- a/docs/public/theme.css +++ b/docs/public/theme.css @@ -77,7 +77,6 @@ --theme-code-text: hsla(var(--color-gray-95), 1); --theme-navbar-bg: hsla(var(--color-base-white), 100%, 1); --theme-navbar-height: 6rem; - --theme-sidebar-offset: var(--theme-navbar-height); --theme-selection-color: hsla(var(--color-orange), 1); --theme-selection-bg: hsla(var(--color-orange), var(--theme-accent-opacity)); } @@ -87,10 +86,6 @@ body { color: var(--theme-text); } -:root.scrolled { - --theme-sidebar-offset: 0; -} - :root.theme-dark { color-scheme: dark; --theme-accent-opacity: 0.4; |