Re: 1.4.12 text spacing

On 28/09/2022 14:27, Marc Haunschild wrote:
> Sorry, my auto correction and I have some issues. Next try:
> 
> I thought user styles are commonly used with an AddOn like Stylus…

No, bookmarklets and extensions like Stylus inject styles into the page, 
so they effectively are on par with "author styles" (keeping in mind the 
hierarchy of "browser styles, user styles, authors styles" and the 
inversion of it when !important is used - see "Origin and importance" 
https://developer.mozilla.org/en-US/docs/Web/CSS/Cascade#cascading_order) 
- they don't do "real" user styles. In the specific case of Stylus, it 
injects a `<style>` block after the closing `</body>` but before the 
closing `</html>`.

And then, within author styles, any styles defined with inline 
style="..." attributes have the highest specificity, and if they also 
have "!important", they're effectively non-overridable except by 
directly modifying those style attributes (even if you define something 
with "!important" in your Stylus etc styles, it won't be able to 
override a style attribute that's set to "!important" ... only real user 
styles would trump those styles, but the ability to do real user styles 
is now vanishing). 
https://developer.mozilla.org/en-US/docs/Web/CSS/important#inline_styles

Long story short: not even Stylus can override something like

<p style="line-height: 1 !important"> ... </p>

when it's defined as a style attribute on an element, as it has the 
highest possible specificity for author styles, and Stylus and co can 
only set author styles.

P
-- 
Patrick H. Lauke

https://www.splintered.co.uk/ | https://github.com/patrickhlauke
https://flickr.com/photos/redux/ | https://www.deviantart.com/redux
twitter: @patrick_h_lauke | skype: patrick_h_lauke

Received on Wednesday, 28 September 2022 14:58:45 UTC