[GoLUG] Fancy HTML, CSS, and maybe JS visual effects tools

Ron / BCLUG admin at bclug.ca
Sun Nov 26 03:38:07 EST 2023


Steve Litt wrote on 2023-11-26 00:16:

> Don't actually do this in production, but what happens if you label the 
> first one !important?

Pretty sure it'll override the 2nd one that way, since it now has 
equivalent to greater specificity.

I think...

If you haven't seen this site yet, it's the *best* for CSS:

https://css-tricks.com/almanac/properties/b/box-shadow/

In that box-shadow page, about ⅓ of the way down, they have the paper & 
shadow demo: 8 different styles.

I notice that the eight variants exclude "all corners" and "both left| 
both right".  I'm now fairly convinced it's not possible (within 
reasonable effort).


They also have "edges, not corners get shadows", which I may eventually 
implement. It's pretty!


> By the way, I consider !important as bad as gotos 
> or the Cobol ALTER statement.

Yeah, use *sparingly* and with careful deliberation.

My Thunderbird v115 userChrome.css is peppered with them. It feels kinda 
dirty & old fashioned.  But, what the heck, I'm trying to override a ton 
of CSS that I don't control, so...


 > I can't help because you're miles ahead of me. I never even heard
 > about z-index until this email. It's pretty cute though.

It's great.

But... beware the stacking contexts and required `position: ...;` on 
parent elements, lest one gets no or inexplicable effects.



Thanks for your input Steve!

rb




More information about the GoLUG mailing list