Post AdTsHoEstdSi8Pk8a8 by kizu@front-end.social
(DIR) More posts by kizu@front-end.social
(DIR) Post #AdTsHURyTG36lDiJCy by kizu@front-end.social
2024-01-03T20:51:57Z
0 likes, 1 repeats
New post: “Cap-Height Vertical Align”.https://blog.kizu.dev/cap-height-align/The new year is here, and, with it, a season where people put out their CSS wishlists for the future.One thing caught my attention in @tylersticka’s list: an ability to vertically align to the middle of the font’s cap-height. I am thrilled to report that there are at least two relatively ok workarounds available in the most recent browsers, courtesy of the new `cap` unit!
(DIR) Post #AdTsHmLtuZt0Hb0iEy by kizu@front-end.social
2024-01-03T20:54:49Z
0 likes, 0 repeats
As usual, credits:- @tylersticka (wishlist, and the original CSSWG issue!)- @xgebi (I mentioned her wishlist from December!)- @michaeltaranto (Capsize!)- @pepelsbey (pointed me towards the Baseline URL on MDN)
(DIR) Post #AdTsHoEstdSi8Pk8a8 by kizu@front-end.social
2024-01-03T21:01:13Z
0 likes, 0 repeats
(oops, forgot to put hashtags for the post's announcement: #CSS and #Typography — here you go!)
(DIR) Post #AdTsHoJ8dorgLbjXDE by kizu@front-end.social
2024-01-03T21:07:24Z
0 likes, 0 repeats
For years, what I was mindlessly doing instead: applying a negative margin with “random” values of 0.2em-0.3em for cases like this, which, coincidentally, almost the same!Intuitively, and by testing, I was pleased with these values all this time, but having a proper method on one hand, and a confirmation that this type of adjustment results in what the fallback ends up being in the end is nice, haha.