by conradfr · 2y ago · 0 comments
Not true anymore (edit: didn't see the 2014) but the productivity cost of not being able to just "vertical-align: middle;" inside divs for the last 30 years must be billions of dollars.
Also does anyone remember the fade of the overline style on :hover links? It must has been around the IE4 or IE6 era.
Tables were also used to make divs and buttons with rounded corners, but that was true into the 2000s as well. The agony of designing and splicing them in Photoshop and putting them in table cells...
> Not true anymore (edit: didn't see the 2014) but the productivity cost of not being able to just "vertical-align: middle;" inside divs for the last 30 years must be billions of dollars.
Even back then (possibly even back in the 90s? I know this existed in the 2000s) we had "VALIGN=MIDDLE" inside table cells.
All of the vertical align, layering, etc hacks came from people not wanting to use tables anymore and divs (and other block elements) finally becoming more usable. Those hacks were the growing pains of an entire shift in paradigm.
Trying to hack a table layout together often led to frequent edits and initial attempts to maintain clean layout comments ended. You're left with never ending <tr><td><tr><td><tr><td> that you hopefully at least indented to maintain sanity. But god help you if your stumbled into another person's table layout code...
Spending time just entering "here", saving the file, and seeing where the "here" shows up. By the time 5pm rolled around "here" often turned into something like "ass" or "fuck", or if it's really bad "fuck you". IYKYK
Have you checked how HN does layout?
Like, cool that we can now do rounded corners in CSS but why can't I vertically align in a div yet? (this was before flexbox)
It's hilariously stupid.
How much we were held back by backward compatibility before useful standards for things came ... But nowadays I just ignore non-standard styling. Just use the standard, because support is sufficient and browsers not supporting the standard sufficiently to make the website unusable are rare. By using the standard one also gives their developers a set target to get implemented.
No no, it's going to take our jobs!
/s
Why do so many hackers have so much difficulty seeing that the current state of public LLMs is not the pinnacle of AI technology? Nobody ever even claimed that they were.
From writing sql boilerplate to copy-pasting my entire pico8 game and going “add repulsion force to enemies so they don’t clump up on one tile” to using it to provide examples instead of synthesizing them from a manpage, it’s insanely good.
It marginally increases my productivity and reduces some friction, honestly I'm more than happy for it to write as much code as it can on my behalf, it just can't.
I suspect those for whom it is a big game changer, were likely engaged in lots of activity which is cookie cutter.
i remember when that was all the rage. So much time spent on freaking corners...
I remember that being far harder than it needed to be. I was a child though so maybe I just didn't get CSS well enough.
To solve that, there's svh (small), lvh (large), and dvh (dynamic).
If you want to make a div stretch to the height of the window, so that something can appear exactly at the bottom before scrolling,
{ height: 100vh; height: 100svh; }
works best... the first line is there as a fallback for the few browsers that don't yet support svh... and if svh is supported it will replace the first line.
Flexbox today is better IMO.
body {
display: grid;
grid-template-rows: auto 1fr auto;
min-height: 100dvh;
}
main {
display: grid;
align-content: center;
}
One of my favorite CSS hacks, it doesn't always work in every single situation though...
div { display: table-cell; vertical-align: middle; }
Feels dirty at first but separation of concerns is still enforced, and I can't see any other downsides.
so while "technically" flex was available at the time it wasn't really widespread yet.
Wasn't an image with a click <map> easier? I wasn't old enough to write very complicated html pages so my experience is lacking here.
left-top corner: no stretch
left: stretch vertically
top: stretch horizontally
...
and so on.I still remember learning to make the layout of a whole page as a table layout in school, with images in table cells for drawing nice borders around sections of the website. And we did that with GIMP!
it's solving a different problem
it's referring to using a 9-cell table to make an element where the corner sizes stay static, while the middle column and middle row stretch horizontally and vertically respectively to match the size of the central cell (which e.g. has variable length text)
then with background image tiling in the left/right and top/bottom middle cells you can get an effect like a drop-shadowed panel that sizes responsively
you'd probably set the flexible cells to width=100% and then have a 1-pixel gif in the edge cells to enforce the desired min-width
I was sad the article didn't mention anything about the 216-colour "web safe" palette, but perhaps the author wasn't old enough to remember having to support users with < 24-bit colour displays... or when 1024x768 took over from 640x480 as the min screen size, allowing use of fixed-width layouts >600 pixels (the max possible: 640, minus browser default page margin, minus scroll bar)...
I kind of wish that attention to detail for payload size was more common today.
Macromedia had this crazy system where you could slice your art up in Fireworks, and then ask it to generate the HTML and Javascript, then you could fine-tune it in Dreamweaver.
It was a mess.
Wasn't there a Photoshop-adjacent tool that did the slicing for you? I remember a print designer on my first job feeding what was, essentially, a full-bleed leaflet design through it, and producing a "landing page" with hundreds of table cells.
I think that’s what you’re remembering.
A page I have for one community project still uses those Imageready generated maps :)
She was great to work with.
I think there was a Chrome developers blog post about it recently.
Don't miss those days.