github: shadowy octopus with the head of a robot, emblazoned with the Dreamwidth swirl (Default)
github ([personal profile] github) wrote in [site community profile] changelog2020-06-02 07:46 pm

[dreamwidth/dw-free] 7fc1eb: [2650] Improved image shrinking, part three

Branch: refs/heads/master
Home: https://github.com/dreamwidth/dw-free
Commit: 7fc1ebdd0254047bfb2343500b669cad7de60e07
https://github.com/dreamwidth/dw-free/commit/7fc1ebdd0254047bfb2343500b669cad7de60e07
Author: Nick Fagerlund <nick.fagerlund@gmail.com>
Date: 2020-06-02 (Tue, 02 Jun 2020)

Changed paths:
M htdocs/js/jquery.imageshrink.js
M htdocs/scss/components/imageshrink.scss

Log Message:
-----------
[2650] Improved image shrinking, part three

We currently constrain the size of images in entry and comment content. But the
REASON we do this is so that people can casually post medium-sized images
and not stress about annoying their friends and readers; the beginning and end
of it is to make it easier to post on DW.

There's another set of user behaviors that's basically the OPPOSITE of casually
posting a medium image, where people express themselves by doing weird intricate
HTML shit no modern site would allow. It's part of DW's fandom-centric culture,
so we'd rather not interfere with it or make it harder.

This commit uses some extra javascript to try and guess which images are part of
a complex hunk of decorative / narrative markup, and changes the CSS to leave
said images alone (under the assumption that the author knows what they're
trying to accomplish and doesn't need any "help").

And while I'm at it, it also removes the "zoom in" cursor from images that are
already actual size and thus don't need to zoom. (That part uses an ultra-modern
API with stringent browser requirements, because 1. it's kind of just a vanity
thing, and 2. it has to update on window resize, but any tangible performance
cost is unacceptable, so if we can't do it for nearly-free then we shouldn't do
it at all. Native ResizeObserver is nearly-free, polyfills ain't.)


Commit: 128aa48726a78a3b3c1264869e4c5948df8c1164
https://github.com/dreamwidth/dw-free/commit/128aa48726a78a3b3c1264869e4c5948df8c1164
Author: Nick Fagerlund <nick.fagerlund@gmail.com>
Date: 2020-06-02 (Tue, 02 Jun 2020)

Changed paths:
M htdocs/scss/foundation/components/_global.scss

Log Message:
-----------
Comment out default global Foundation rules for images

These rules make too many assumptions to be compatible with this site, and in
particular they interfere badly with user-provided content. As far as I can
tell, none of the current pages rely on these CSS rules.

If we were using a viable living framework here, hacking the core files like
this would be a bad plan. But Foundation 5 is extremely end-of-life, AKA we
bought it so we might as well break it. We're already carrying patches to fix
upstream bugs that will never be addressed, so hey, what's one more.


Commit: dbc8417a3363e8cee79318f13abb00081f1bc4ba
https://github.com/dreamwidth/dw-free/commit/dbc8417a3363e8cee79318f13abb00081f1bc4ba
Author: Mark Smith <mark@qq.is>
Date: 2020-06-02 (Tue, 02 Jun 2020)

Changed paths:
M htdocs/js/jquery.imageshrink.js

Log Message:
-----------
Update htdocs/js/jquery.imageshrink.js

WHERE WILL THIS COMMIT END UP NOBODY KNOWS

Co-authored-by: Nick Fagerlund <nick.fagerlund@gmail.com>


Compare: https://github.com/dreamwidth/dw-free/compare/061ff79f7617...dbc8417a3363