Page MenuHomePhabricator

Use preview images for macros and memes
AbandonedPublic

Authored by hach-que on Aug 19 2015, 1:06 AM.
Tags
None
Referenced Files
F13096002: D13933.diff
Thu, Apr 25, 1:38 PM
Unknown Object (File)
Thu, Apr 25, 12:47 AM
Unknown Object (File)
Thu, Apr 11, 8:36 AM
Unknown Object (File)
Mar 21 2024, 11:17 AM
Unknown Object (File)
Mar 3 2024, 7:36 PM
Unknown Object (File)
Feb 9 2024, 3:55 PM
Unknown Object (File)
Jan 28 2024, 4:53 AM
Unknown Object (File)
Jan 7 2024, 4:46 PM
Tokens
"Doubloon" token, awarded by joshuaspence.

Details

Summary

As per discussion in Z1336. This resizes macros and memes on the fly with the transforms API.

Currently this is not configurable, but the way forward here if needed would be to add a new column onto macros with "renderOriginalSize" that disables the preview resizing logic.

Test Plan

Viewed it:

pasted_file (958×422 px, 101 KB)

Diff Detail

Repository
rP Phabricator
Branch
meme-thumbnail
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 7678
Build 8393: [Placeholder Plan] Wait for 30 Seconds
Build 8392: arc lint + arc unit

Event Timeline

hach-que retitled this revision from to Use preview images for macros and memes.
hach-que updated this object.
hach-que edited the test plan for this revision. (Show Details)
hach-que added reviewers: chad, epriestley.
hach-que edited edge metadata.

Yeah, I think we need the per macro option of rendering as original. This also feels to small for me as a default. Macros should be cool.

awwyiss

hach-que edited edge metadata.

Allow macro resizing to be configurable

I don't think it does; I didn't change how the meme image is generated (I just added an additional step to transform the transformed image).

What's the actual problem that this is trying to solve?

It's something like "it would be more convenient if you didn't have to open Photoshop to resize a macro", right? Not "all macros should have a standard size" or "users upload macros that are too big" or whatever?

If the file upload dialog had some simple image editing options (e.g., for v0, a UI to resize and maybe crop images) that would completely solve this problem in a more general and flexible way and obsolete this change, right?

I feel as though destroying the original uploaded image by resizing or cropping them on upload is probably undesirable; there have been times when I've uploaded images to services, resized them and then a while later needed the original resolution which I no longer have.

Substantially this is no different to the way that {F1234} syntax works in that it thumbnails embedded images; this just does the same for macros and memes so that they aren't ridiculous sizes on people's screens.

We could add a size=full option to the {meme} markup to allow people to use the original size, but I think most people just want sensible defaults here. When I upload a non-macro image, it gets resized for me inline (thumbnail with a link to original size); when I upload a macro image, it doesn't get resized. Moving the work from a desktop tool to having to pick a sensible macro size that will work on all layout forms (mobile, desktop, email) ahead of time seems less desirable than just allowing Phabricator to make the smart decision of how big something should be for usual meme consumption.

I feel as though destroying the original uploaded image by resizing or cropping them on upload is probably undesirable; there have been times when I've uploaded images to services, resized them and then a while later needed the original resolution which I no longer have.

Substantially this is no different to the way that {F1234} syntax works in that it thumbnails embedded images; this just does the same for macros and memes so that they aren't ridiculous sizes on people's screens.

We could add a size=full option to the {meme} markup to allow people to use the original size, but I think most people just want sensible defaults here. When I upload a non-macro image, it gets resized for me inline (thumbnail with a link to original size); when I upload a macro image, it doesn't get resized. Moving the work from a desktop tool to having to pick a sensible macro size that will work on all layout forms (mobile, desktop, email) ahead of time seems less desirable than just allowing Phabricator to make the smart decision of how big something should be for usual meme consumption.

+1