Where did you install Firefox from? Help Mozilla uncover 3rd party websites that offer problematic Firefox installation by taking part in our campaign. There will be swag, and you'll be featured in our blog if you manage to report at least 10 valid reports!

搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

Learn More

::before behaves differently on macOS and Windows10

  • 4 个回答
  • 1 人有此问题
  • 1 次查看
  • 最后回复者为 Sherlock907

more options

Hello! I hope this is the right place to ask.

So i used glassmorphism on a simple webapp (backdrop-filter). Wrote a Fallback for firefox with the help of ::before and filter:blur() as backdrop-fillter's are sadly still not supported, eventhough they look really really nice.

How ever the fallback works on macOS as expected but on Windows Firefox behaves very very wierd. First of all the blured effect is behind everything else and you have to change the z-index to actually see it and if you do it is actually much larger than it should be. If you play around with the z-indexes you actually get the blur at the right position but the area is still much larger than on mac and not fitting the border at all and after a few hours of trying, I'm not sure if this is a bad by me or not. Kinda feels like it shouldnt behave like that.


Website: https://get-youtube-playlist-length.herokuapp.com/

Hello! I hope this is the right place to ask. So i used glassmorphism on a simple webapp (backdrop-filter). Wrote a Fallback for firefox with the help of ::before and filter:blur() as backdrop-fillter's are sadly still not supported, eventhough they look really really nice. How ever the fallback works on macOS as expected but on Windows Firefox behaves very very wierd. First of all the blured effect is behind everything else and you have to change the z-index to actually see it and if you do it is actually much larger than it should be. If you play around with the z-indexes you actually get the blur at the right position but the area is still much larger than on mac and not fitting the border at all and after a few hours of trying, I'm not sure if this is a bad by me or not. Kinda feels like it shouldnt behave like that. Website: https://get-youtube-playlist-length.herokuapp.com/

被采纳的解决方案

The CSS backdrop-filter property is disabled by default, and also doesn't work if WebRender is disabled. Per the MDN implementation note:

From version 70: this feature is behind the layout.css.backdrop-filter.enabled preference (needs to be set to true) and the gfx.webrender.all preference (needs to be set to true). To change preferences in Firefox, visit about:config. Source: https://developer.mozilla.org/docs/Web/CSS/backdrop-filter ("Browser Compatibility" section after clicking the * under Firefox)

That could explain why one Firefox behaves differently than another.

定位到答案原位置 👍 1

所有回复 (4)

more options

For some reason the images are black so here a link: https://prnt.sc/IMBdNeWS5ZnI On the right you see Firefox on MacOS and on the left Firefox in Windows 10. Same html, same css...


Just noticed this is because browser on mac I had backdrop-filter enabled in about:config and the windows one didnt. Oddly enough it doesnt enable backdrop-filter but filter: blur() on both. I guess i'll have to let firefox users just see a purple background with lower opacity -.-

Very disappointing.

more options

https://github.com/Sherlock907/yt-playlist-length


They now behave the same. This was just me having different settings in about:config. But its sad that after all these years firefox still doesnt support backdrop filter. And its wierd that backdrop-filter enabled in about:config enables filter:blur() but not the actual backdrop filter.

more options

选择的解决方案

The CSS backdrop-filter property is disabled by default, and also doesn't work if WebRender is disabled. Per the MDN implementation note:

From version 70: this feature is behind the layout.css.backdrop-filter.enabled preference (needs to be set to true) and the gfx.webrender.all preference (needs to be set to true). To change preferences in Firefox, visit about:config. Source: https://developer.mozilla.org/docs/Web/CSS/backdrop-filter ("Browser Compatibility" section after clicking the * under Firefox)

That could explain why one Firefox behaves differently than another.

more options

I found a solution that works but its probably not best practise and nothing for bigger sites.. Now i just used a pre-blured image and set is as background for the section that would use the backdrop-filter (as Fallback for Firefox). So far it looks good, works and it even looks better than the first fall back attempt with filter:blur(). :D


Please Firefox - Team add backdrop-filter support!