Skip to content
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

Help Wanted: Styling uBO and uMatrix elements on Windows #58

Closed
overdodactyl opened this issue Jan 20, 2018 · 9 comments
Closed

Help Wanted: Styling uBO and uMatrix elements on Windows #58

overdodactyl opened this issue Jan 20, 2018 · 9 comments

Comments

@overdodactyl
Copy link
Owner

This is being carried over from problems brought up in #6 and #42.

It appears certain elements in both uBlock Origin and uMatrix are not getting styled on Windows the same way they are on a Mac:

Mac Windows
screen shot 2018-01-20 at 3 57 48 pm uMatrix_wind
Mac Windows
uBO-mac uBO-win

I've ruled out this being a difference in FF version, and I can only assume it is due to the OS.

Without current access to a Windows computer, there unfortunately isn't a whole lot I can do to fix this myself. If anyone could help figure out what's going on here, I would greatly appreciate the help! :)

@Asteaguinity
Copy link

Asteaguinity commented Jan 21, 2018

As far as I can tell, you won't be able to fix this problem on your side for the following reasons:

  1. Opening the relevant moz-extension url of the popup page in a tab shows a fully styled page, so your styling itself is obviously perfectly fine.
  2. The bigger problem is that setting the preference extensions.webextensions.remote to false fixes the styling problem for me.

Somehow, styling seems to be a tad broken in webextension popups when this preference is set, which is why I assume a fix on Mozilla's side is necessary. For reference, have these two images showing both working cases.

Perfectly styled popup loaded in a tab:
image

Perfectly styled popup with extensions.webextensions.remote=false:
image

According to Bug 1385403 OOP webextensions are disabled on Mac for the moment, which would explain why you wouldn't have been able to see the problem , assuming Macs would even have the same problem.

I guess the best way to continue in this matter would be to open a bug report on bugzilla and see what the devs have to tell us regarding this issue.

@overdodactyl
Copy link
Owner Author

Hi @Asteaguinity, thank you so much for this, I really appreciate the help - I'm not sure I would have thought to look into extensions.webextensions.remote.

It is disabled by default on a Mac, and apparently for a good reason: enabling it rendered most extension popups completely useless and caused FF to crash multiple times. Notably, however, uBO's popup wasn't effected and contained all the proper styling.

I'll file a bug report ASAP...are you ok with me using the screenshots you provided in it?

Thanks again!

@Asteaguinity
Copy link

Feel free to use them. Let's hope this get's fixed asap. Firefox is so much easier on the eyes using your theme.

@overdodactyl
Copy link
Owner Author

@overdodactyl
Copy link
Owner Author

Bug was labeled as WONTFIX because, "userContent.css is not officially supported." Disappointing to say the least.

Since the FF devs won't look into this, I guess our best bet would be to determine if this is truly isolated as a userContent.css problem, or if it extends beyond that.

I think the following would be the easiest way to test this:

On a mac, starting at line 170 is the following:

#extraTools {
    background-color: #eee;
    border: 0;
    color: #aaa;
    margin: 0.8em 0 0 0;
    padding: 4px 0;
    text-align: center;
    }

change the background-color to something else...maybe red.

  • Save the file

  • Add the modified uBO as a temporary addon (about:debugging#addons > select "Load Temporary Add-on" > navigate to the uncompressed [email protected] folder where you made the changes > select manifest.json > open)

  • See if the bottom bar is red

@Asteaguinity, would you possibly mind giving this a try and letting me know the results?

@Asteaguinity
Copy link

image
As one can see in the image above, setting the background color via extension internal css works as expected.
I really do wonder though why userContent.css doesn't completely apply its css in a remote extension popup, as there's no really obvious reason for it from an outsider's perspective...

@overdodactyl
Copy link
Owner Author

Bummer. I was kind of hoping that wouldn't result in the proper styling, as that probably would have forced the FF devs to re-open the bug.

I'm kind of at a loss for why userContent.css isn't styling a select few items either. Oddly the only 2 issues that have been reported to me are extensions written by gorhill, so perhaps it's worth looking more into the makeup of those extensions/specific elements. But there's certainly no obvious reason that sticks out in popup.css.

@Asteaguinity
Copy link

Fortunate update: It seems the bug causing this has been fixed through work on other bugs.
Since the Nightly build of 2018-02-02 the popups are completely styled, even with remote webextensions enabled.
This being fixed was the result of one of the patches in this pushlog, but I didn't bother looking further into it because, hey, as long as the styling works it doesn't really matter anyway.

@overdodactyl
Copy link
Owner Author

Thanks for the update!

That's actually really good to hear, I didn't have high hopes of that getting fixed.

I'll update the known issues section of the wiki accordingly

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants