Live data from Hacker News

A Single Div

a.singlediv.com

81–90 of 146 posts

Re: A Single Div

#81
I'm surprised at the comments. To the person that did this: Great job! This is very neat and shows the kind of boundaries you can push with CSS. So what if this is not practical per se, it does show that you can potentially do simpler things than this in pure CSS and that may, in fact, be practical in some cases. Seeing an example like this makes it abundantly clear that that simple of effect you might be wondering if is possible to do in CSS is definitely because clearly this exists.

Besides that, this is HackerNews; it's relevant.

Re: A Single Div

#82
post #67
post #66

Making images in css is like making a game engine in cobol. it wasn't a good language/model to begin with, and this is a particularly difficult application of the subject that only occurs to people because we're stuck with the technology.

I think this kind of thing isn't born out of necessity, since we're locked in with the tech, but more because its a challenging experiment that requires some pretty clever CSS to accomplish. You should certainly not do this in the wild.

I didn't mean that this is done out of necessity, I mean people only give a half-baked mess of standards that is modern web-layout/css the time of day because it's foisted upon us.

If CSS were just another layout engine for just another platform, people would laugh it out of the room and not bother with this kind of artistic stunts.

CSS does not deserve the kind of respect that would go into this sort of craftmanship.

Re: A Single Div

#83
post #59

For those who don't understand. Each image is not in fact an image, it's css styles applied to a single html element. Very impressive. http://i.imgur.com/V8HYrhK.png

It's amazing how powerful css is. I recently worked with changing the checkboxes on a form of mine to look like the iOS7 toggle. Check it out: http://designcouch.com/home/why/2013/09/19/ios7-style-pure-c...

It's amazing how CSS lets you do stuff like this but still can't center things easily.

Nice demo by the way, but why on earth did you use an id rather than a class?

Re: A Single Div

#84
post #71

Earlier quoted context omitted.

Ok fair point I shouldn't have been so glib as puet is pretty horrible from a web design standpoint. It's a website for the demoscene, where people do stuff like this https://www.youtube.com/watch?v=wqu_IpkOYBg in 177 kilobytes.

They do that complete render in 177kb...? I remember crack intros but that's insane. Is this in C?

C++, maybe a little assembly, and lots of shader code.

Re: A Single Div

#85
post #16

I am unmoved by the many "... in pure CSS" posts, but I guess they are the equivalent of "HTTP server in x86 assembly" for CSS designers.

I like this, it's neat art. However I must agree that I'm unmoved, I invite anyone who thinks this is particularly clever to visit www.pouet.net for a bit of re-calibration. It's all relative.

Do go to a site like pouet.net, and recalibrate yourself based on what people were doing way back toward the genesis of the scene, when there weren't any demo competitions and it was just a few guys fooling around with stuff for hack value.

Compare a hack like this to what people were doing back when even something like copper bars was seen as being pretty cool. Don't compare people doing the equivalent of display hacks using a relatively new technology to what the culture around display hacks grew into after several decades of active fermentation. That'd be right up there with poo-pooing a local recreational sports league because the players aren't as good as what you're used to seeing in the professional leagues on TV.

Re: A Single Div

#86
post #42

I haven't seen so much nay-saying on HN in a while. It's like because there's an artistic element this or it's pure-web tech the appreciation of a cool hack and interesting exploration of a technology is completely gone. This is a classic example of a "hack", pushing CSS slightly beyond what it was intended for and potentially what is practical. But it's beautiful and clever, and if you truly can't appreciate it, tha…

Scanning through the comments, it looks like most of the naysaying was downvoted and the comments about how it's neat floated to the top, including yours.

I posted my comment when those that are now downvoted were at the top, and the link had already been up for 3 hours and was near the top of the homepage. If it had been just a few unfortunate comments on a fresh thread, I would not have bothered. I'm glad things adjusted, but I was providing a point of view that was barely represented at the time.

Re: A Single Div

#87
post #42

I haven't seen so much nay-saying on HN in a while. It's like because there's an artistic element this or it's pure-web tech the appreciation of a cool hack and interesting exploration of a technology is completely gone. This is a classic example of a "hack", pushing CSS slightly beyond what it was intended for and potentially what is practical. But it's beautiful and clever, and if you truly can't appreciate it, tha…

> But it's beautiful and clever, and if you truly can't appreciate it, that's sad.

Interesting. Is it as sad as the fact that one still cannot vertically center a div in CSS without using elaborate hacks?

Re: A Single Div

#89

Earlier quoted context omitted.

It's amazing how powerful css is. I recently worked with changing the checkboxes on a form of mine to look like the iOS7 toggle. Check it out: http://designcouch.com/home/why/2013/09/19/ios7-style-pure-c...

It's amazing how CSS lets you do stuff like this but still can't center things easily. Nice demo by the way, but why on earth did you use an id rather than a class?

> It's amazing how CSS lets you do stuff like this but still can't center things easily.

It's trivial to do if you can use flexbox. And I do mean trivial, we're talking 3 properties including "opting into" flexbox: http://jsfiddle.net/1vd9xLdy/ (note: didn't bother with prefixes or older syntaxes so IE >= 11, Firefox >= 28, Chrome >= 29, Opera 12.1 or >= 19)

Re: A Single Div

#90
post #87
post #42

I haven't seen so much nay-saying on HN in a while. It's like because there's an artistic element this or it's pure-web tech the appreciation of a cool hack and interesting exploration of a technology is completely gone. This is a classic example of a "hack", pushing CSS slightly beyond what it was intended for and potentially what is practical. But it's beautiful and clever, and if you truly can't appreciate it, tha…

> But it's beautiful and clever, and if you truly can't appreciate it, that's sad. Interesting. Is it as sad as the fact that one still cannot vertically center a div in CSS without using elaborate hacks?

I believe Flexbox, which is supported by most major browsers, allows vertically centering content without hacks:

http://philipwalton.github.io/solved-by-flexbox/demos/vertic...

Post reply on HN