Incomplete List of Mistakes in the Design of CSS
21–30 of 154 posts
Re: Incomplete List of Mistakes in the Design of CSS
#22Earlier quoted context omitted.
> three column layouts with headers and footers I was appalled when I saw what was needed to make this use case, used by 1/2 he web pages in existence.
originally CSS had no layout facilities. (as it should be, see other comment). Layout was hacked in to css by abusing the "float" property into doing things it was never meant to be doing.
So if CSS wasn’t supposed to do layout, despite that being what people needed, and if you weren’t supposed to use tables for layouts despite that being what worked... then what on earth were you supposed to be using for layout? I don’t recall any other serious options out there.
Re: Incomplete List of Mistakes in the Design of CSS
#23Earlier quoted context omitted.
pointer-events: none; is actually pretty useful in many cases when you temporarily need to disable interactions, like drag/drop
It's useful as long as every browser supports it. When it doesn't, and you want to polyfill, the polyfill needs to download all linked CSS files a second time, implement a CSS parser to find the pointer-events properties, and after all that, patch in not entirely identical behaviour with javascript. But then, this is behavior . what's it doing in a language that's supposed to be strictly about style/presentation? Why…
Re: Incomplete List of Mistakes in the Design of CSS
#24Re: Incomplete List of Mistakes in the Design of CSS
#25Is there some reason why margin/padding is top, right, bottom, left instead of left, top, right, bottom or left, right, top, bottom or both of which would seem more common in other APIs
Re: Incomplete List of Mistakes in the Design of CSS
#26here's my pet peeves: 1. CSS should not have adopted a hyphenated naming scheme for properties, since it makes it difficult to access css properties from javascript or other languages. 2. CSS should never have been used for layout, and nobody should have suggested it should be. CSS defines properties on individual elements, while layout fundamentally needs to define relationships between elements, which requires real…
I couldn't agree more! Does anyone know a language/toolkit/something that gets layout right? I remember getting excited by Grid Stylesheets [1] but the project seems dead now...
Re: Incomplete List of Mistakes in the Design of CSS
#27> background-position and border-spacing (all 2-axis properties) should take vertical first, to match with the 4-direction properties like margin. Is there some reason why margin/padding is top, right, bottom, left instead of left, top, right, bottom or left, right, top, bottom or both of which would seem more common in other APIs
Re: Incomplete List of Mistakes in the Design of CSS
#28Earlier quoted context omitted.
pointer-events: none; is actually pretty useful in many cases when you temporarily need to disable interactions, like drag/drop
It's useful as long as every browser supports it. When it doesn't, and you want to polyfill, the polyfill needs to download all linked CSS files a second time, implement a CSS parser to find the pointer-events properties, and after all that, patch in not entirely identical behaviour with javascript. But then, this is behavior . what's it doing in a language that's supposed to be strictly about style/presentation? Why…
sure, but the same can be said of every web api and other open standard with multiple implementations.
https://caniuse.com/#feat=pointer-events
> But then, this is behavior.
there's not always a clean separation. what about opacity:0 and visibility: hidden? this affects intractability despite being presentation, right?
Re: Incomplete List of Mistakes in the Design of CSS
#29here's my pet peeves: 1. CSS should not have adopted a hyphenated naming scheme for properties, since it makes it difficult to access css properties from javascript or other languages. 2. CSS should never have been used for layout, and nobody should have suggested it should be. CSS defines properties on individual elements, while layout fundamentally needs to define relationships between elements, which requires real…
Re: Incomplete List of Mistakes in the Design of CSS
#30They seem to favor implied behavior rather than explicitly defined behavior which is incredibly annoying. For example, space between inline-block elements that is not accounted for by margins. The fact that margin-top and margin-bottom percentages are computed based on the width of the parent element, not the height. The fact that certain properties like max-height are oftentimes not respected if they use a %, even if the height can be precisely calculated. The fact that I have to add body { margin: 0; } to everything. I'm sure there have been more but just what I can think of off the top of my head.
Oh, and COLLAPSING MARGINS.... WHAT THE HELL