New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
During installer, better detect adblockers that may block Matomo css/js files #12493
Conversation
also check for CSS and JS
It will be useful to have adblocker detection in the web installer!
|
That's what I expected. I honestly don't know a good solution, I tried moving I'm open for suggestions on how to improve it. |
Does anything speaks against setting https://www.thoughtco.com/display-none-vs-visibility-hidden-3466884 |
Yes, if I'm not mistaken it doesn't remove the element from the flow which would cause an empty space at the top of every page. Does anything speak for using it? |
Well, you asked for ways to not have the jumping effect. That is a way ;) |
@Findus23 Maybe we could move the Adblocker message to the bottom of the page so there is no jumping effect, yet the message would still be visible above the fold for most users? |
@mattab On the other hand I opened the pull request mainly because the warning is very far below on the site and isn't really visible (especially when there is no CSS and therefore all languages are shown on a separate line |
Simply moved the notice messages to the bottom to avoid the jumping. It still shows up when the page loads for a few milliseconds, which is not ideal, but maybe better than nothing. @Findus23 maybe you could in a new PR somehow reuse the same technique that is used in core, where the messages shows at the top in case of adblocker, but it does not jump/flash on screen? |
* better adblock detection also check for CSS and JS * Move the adblock notice messages to the bottom
extends #5094, fixes #11660 and hopefully also fixes #10652
I just remembered that I once opened an issue about AdBlock detection.
Improvements:
This needs some testing as there are a lot of edge cases that I didn't test.
I have no idea how the error message should read, so it's just a placeholder