Sometimes dvh units are what you want - but I actually expect to use svh the most in my #css work.
Dynamic units for a hero image or similar will make your page jump around on mobile. That's not great. And in most cases, something like that doesn't have to be exact-viewport-height-at-all-times.
I'd only use dvh for something actually positioned at the bottom of the viewport.
Does anybody know what color space/interpolation method #CSS gradients use when you don't specify one?
I can't find any documentation that specifies, including the spec. As far as I can tell testing, the behavior doesn't quite match any of the color spaces I can specify (it's closest to oklch or maybe xyz-d50, but not exact)
Próbuję sobie ostylować domyślny wygląd webowy #Mastodon i o ile w przypadku odpowiedzi na posty - sobie poradziłem, tak za cholerę nie mogę odnaleźć klasy, która odpowiadałaby za podbicia.
Albo coś mnie zaślepiło, albo treść podbicia nie jest zamknięta w żadnej klasie?
What's always been "weird" to you about #CSS? As in, how something works? Less intuitive aspects? Stuff that trips you up even though you "know" how it works?
This is not a gripe thread, I'm looking for constructive input, thanks!
Hitting some "fun glitches" with #css page transitions that seem to be related in some way to dynamic injection of classes on the transferring elements. For example, my header I'm expecting to "not animate" because:
html {
view-transition-name: none;
}
header {
view-transition-name: site-header;
}
But instead it's glitching a stretched partially styled version and blending between.
New tech... "is it a bug, is it me doing something weird?"
Momentous decision taken: the #css book will copy W3C and only treat features that are interoperably implemented in at least two browsers - and not behind flags, either.
So right now no masonry, no anchored position.
However, I will review the situation when I'm writing draft 2.
What is your approach when using logical properties in #CSS? They have broad browser support now, but supporting browsers that are more than two years old by prefixing and not using shorthand properties seems reasonable, right? 🤔
I mean, 91.58 % globally are not 98.34 %… 😉 https://caniuse.com/css-logical-props
I must be missing something simple, but I can't get position sticky to work, applied to a footer. It just displays as default at the top, both Safari and Chrome - help?
1/4
When it comes to web dev, I'm a huge fan of finding simple solutions that leverage fundamental web technologies.
Here are two excellent articles I've stumbled across recently, one explaining 5 new CSS properties and the other about structuring vanilla JavaScript, both very much highlighting some great web fundamentals.
Coincidentally, both were written by a Chris that I admire so that's neat.
Ian "Hixie" Hickson editor of #WhatWG HTML specification for 10 years, in January 2023 criticises the use of #HTML, #CSS, #Javascript for intricate #Web applications, and proposes an alternate approach based on 4 lower-level #OpenStandards:
I know that #CSS style queries probably need a container to avoid looping situations, but couldn’t there just be some rule that you can’t style the property being queried? I guess that still wouldn’t solve the problem since you could have multiple style queries affecting each other. Seems like a solvable problem though with some rules, like maybe style queries don’t run for properties that are the result of another style query?
New #CSS Toy shows off the "angle," optional first parameter to show what the various angles can do. Feel free to fork and play with it. I so so love CSS gradients after being terrified of them for, uh, a decade. https://codepen.io/artlung/full/qBwOYeJ