Currently it’s possible to attach images to messages. The frontend restricts these to be square, and they are reduced in size before upload.
If would be useful if people could attach images such that they maintain their original aspect ratio and size. Additionally, being able to add other kinds of files as attachment has been requested multiple times.
I looked at what telegram and whatsapp do in this regard.
Telegram desktop pops open a message compose dialog when you attach a file, that allows you to add a “caption” (which is sort of instead of the message), add more files, and manipulate the file. If you select an image, it’ll include an option to “compress the image”, which downsizes it and makes is show inline as a gallery… otherwise it adds it as a file.
Telegram mobile makes you choose image (“gallery”) or file initially (and a range of other options), and has a multi-select “bottom sheet” style dialog.
If any design-orientated people here, e.g. @bruno or @hwojcik want to try out some sketches for a new conversation compose (the bit where you write a message), then I would welcome that! … I’m thinking to make it a bit like the slack one…
something to differentiate the WHOLE conversation compose thing, slack has a thin border…
add buttons along the bottom of that (rather than the right side of the input field)
attachment button, and message formatting tips on left, preview and submit buttons on the right
allow to add files, so they show up a bit like the images do right now
allow to add multiple files/images at once
don’t crop images (even if the preview shows as square, upload full image)
if adding any image editing, make that in a dialog that opens when you click the image
One unresolved thing is files vs images…
many platforms separate images that will show inline as a gallery, vs files as attachments (that might include images)
when adding an “image” specifically, platforms often downsize them, reduces upload size
when adding a “file” (image or other) they will upload the full size
I’ve actually made two variations of the backend:
treat everything as “attachments”, which might be an image or file
have both “images” and “attachments” independently, which makes the code somewhat easier for some cases
The slack-like approach does not distinguish though, whereas telegram/whatsapp do.
-we go for the Slack model of attaching images and files and showing a preview below the message.
preserve distinction of choosing between images and attachments, and maybe add Camera option
plus button to attach something
placed below the field for writing the message (on the left?), and shrink the help for markdown to a help icon only (?)
when clicking comes the choice option as “fab” style menu on desktop, and on mobile maybe a bottom sheet dialog
keep send button on the same place…
preview for images keep the correct aspect ratio, and have a a remove button on it only
bonus: open the image for basic editing (rotate, zooming, and more stuff in the future)
when attaching file file: show preview with the name and size. Upload the whole thing. If an image is attached as a file, there’s no image preview and it’s uploaded full size
Image attachments will be compressed, maybe a download icon on the corner of the image when viewing the image after posted
when composing a message with attachments, add a gap and/or a frame to distinguish it from previous messages on the wall
how to solve that on a chat (activity or application chat for ex.)