logoalt Hacker News

bastawhiztoday at 2:20 AM1 replyview on HN

Margins don't help. What if you have an image of variable height? Or a table with borders that don't evenly divide by your line height? Or in your block quote example, what if you wanted the font size to be slightly larger or smaller than your normal font style? It's immediately broken.

Everything after CSS1, more or less, could be accomplished with hacks or JavaScript. But sometimes it's nice to be able to say `block-step-size: 20px` and have it look the way you intend instead of having to write your own layout engine.


Replies

systolltoday at 6:01 AM

You’re not wrong, though it seems like we’re going to wind up with:

    box-sizing: border-box;
    height: calc-size(auto, round(up, size, 1rlh))
Solving most of the big issues before this will land anywhere.
show 1 reply