Closed Bug 1953332 Opened 9 days ago Closed 9 days ago

userContent.css no longer works with 136

Categories

(Firefox :: Untriaged, defect)

Firefox 136
defect

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: atakhmaz, Unassigned)

Details

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:136.0) Gecko/20100101 Firefox/136.0

Steps to reproduce:

userContent.css in chrome profile folder:

@-moz-document url(about:home), url(about:newtab) {
.top-sites-list { display: flex; justify-content: center; }
:nth-child(n+7 of li.top-site-outer) { display:none !important; }
}

The following flag enabled: toolkit.legacyUserProfileCustomizations.stylesheets

Actual results:

The console outputs this error and the stylesheet is not applied:

Content-Security-Policy: The page’s settings blocked an event handler (script-src-attr) from being executed because it violates the following directive: “script-src resource: chrome:”
Source: function() {
[native code]
}

Expected results:

No error, only 6 shortcuts shown, centered.

I was able to fix this with the following edits:

@-moz-document url(about:home), url(about:newtab) {
.top-sites-list { display: flex !important; justify-content: center !important; }
:nth-child(n+7 of li.top-site-outer) { display:none !important; }
}

Status: UNCONFIRMED → RESOLVED
Closed: 9 days ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.