antfu / icones

⚡️ Icon Explorer with Instant searching, powered by Iconify

Home Page:https://icones.js.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

"overflow-y: overlay" is not supported in Firefox

rururux opened this issue · comments

https://developer.mozilla.org/en-US/docs/Web/CSS/overflow#Values

overlay
Only supported in WebKit-based (e.g., Safari) and Blink-based (e.g., Chrome or Opera) browsers.

i'm using firefox, so i can't scroll down😢

Do you know any workaround?

It doesn't seem to be possible to do the same in Firefox, so how about use overflow: auto instead of overflow: overlay, or something like this:

:root {
  --overflow: overlay;
}

@supports not (overflow: overlay) {
  :root {
    --overflow: auto;
  }
}

.overflow-overlay {
  overflow: var(--overflow)
}

Thanks for the tips. Should be fixed now. And the code can actually be simpler 😉

.overflow-overlay {
  overflow: auto;
  overflow: overlay;
}

thank you! 😳