Nov. 27th, 2019

roadrunnertwice: Dialogue: "I have caught many hapless creatures in my own inter-net." (Hapless creatures (Rainy Days))
[personal profile] roadrunnertwice

A while back, I submitted a patch that sometimes shrinks images within post and comment bodies, to make sure they fit inside their container and fit on a single screen.

It seems to mostly be working, but there's also times when you don't WANT it to work; for example, it's perfectly fine for a long vertical comic strip to flow off the page.

So I'm messing with a way to let people click-to-zoom on individual images!

»» Here's the demo. ««

That demo has several different cases I thought about — for example, I'm not enabling click-to-zoom for images that are links, because links already do something when you click on them (and most of the time it's "go to the full size image" anyway). I'm also not zooming poll bar graph images, because those are special and weird.

Anyway, the trick with this is to make it do what people want most of the time, but hopefully never do anything really nonsensical. So I need help thinking of things that people do with images in their posts/comments that might cause nonsense, and then I can figure out which nonsense to mitigate and which nonsense to just accept. The only ones I came up with so far are:

  • If an image didn't need to shrink, it gets a "click to zoom" cursor on hover but it doesn't actually do anything.
  • If someone used the width="x" / height="x" attributes to make an image bigger than its natural size, the zoom cursor hints will be reversed (i.e. "zoom in" will actually shrink it).

What else have you got?

Profile

dw_dev: The word "develop" using the Swirly D logo.  (Default)
Dreamwidth Open Source Development

July 2025

S M T W T F S
  12345
6789101112
13141516171819
20212223 242526
2728293031  

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Aug. 23rd, 2025 09:27 pm
Powered by Dreamwidth Studios