the-djmaze / snappymail

Simple, modern & fast web-based email client
https://snappymail.eu
GNU Affero General Public License v3.0
981 stars 114 forks source link

Resize image #1280

Open BiglifeMatt opened 11 months ago

BiglifeMatt commented 11 months ago

I know there was a previous request for this but it was closed with the CKEditor as an option. I do not even see that as a plugin option anymore and would still love a handle-based resize tool if possible.

the-djmaze commented 10 months ago

In #262 i explain why it is bad to use the CKEditor (or any other) image resizer.

At the end of that issue there's a commit that forces images to be a maximum of 1024px https://github.com/the-djmaze/snappymail/commit/6129fb42333a82752c444fda9cdc7c50f05a727e

That code could be enhanced to allow more "shrink" but not enlarge!

BiglifeMatt commented 10 months ago

Will ckeditor 5 be included as an extension? I'm not concerned with the file size, only the appearance of inline images.

the-djmaze commented 10 months ago

I understand you, but people like to put 5-10 images of their family foto's inline and send 25+MB emails that get bounced by recipients.

CKEditor5 does not solve that, but someone might develop the integration. I could push some draft code to github

grrosminet commented 8 months ago

In #262 i explain why it is bad to use the CKEditor (or any other) image resizer.

At the end of that issue there's a commit that forces images to be a maximum of 1024px 6129fb4 resizing image to 1024px max is very limitative : today people's screens are getting even more larger

Even if Rainloop only resizes image display (and not it's real weight) it allows you to completely manage the formatting of your e-mail, easily and quickly. Of course it might be better to really reduce image weight (but not always)

Moreover, you can create JPEG/PNG images that are only a few hundreds kb and very large

That code could be enhanced to allow more "shrink" but not enlarge!

Why ?! let user decide ! If the user want to resize a 100px image to 10000px why not, it's ugly and that's his problem

the-djmaze commented 8 months ago

Why ?! let user decide ! If the user want to resize a 100px image to 10000px why not, it's ugly and that's his problem

Maybe use this option:

<a href="cid:original-size"><img src="cropped"></a>

And the cid is the original sized image (including private metadata like the camera used aka EXIF data). The user can then still decide to delete the original from the attachments area

grrosminet commented 8 months ago

That's all we are asking for : an interface that will allow lambda user to insert html attributes without having to be html dev.

fabiodepin commented 3 months ago

Hello,

I have this feature ready https://github.com/the-djmaze/snappymail/issues/1593

As soon as possible, I will carry out the necessary validations to request PR.

Thanks.