dfa1234 / ngx-image-compress

Angular library for uploading and compressing images
https://image-library.app
MIT License
86 stars 37 forks source link

Add reject on cancel for 'uploadAndGetImageWithMaxSize' method #103

Closed detobel36 closed 1 year ago

detobel36 commented 1 year ago

Hello,

I need to detect when the user cancel the selection of file with the method uploadAndGetImageWithMaxSize. Here is a PR where I add this option. Notice that a default value has been added to be retro-compatible.

I add example in app.component.html. I didn't add tests, but if it's required, I can do it.

dfa1234 commented 1 year ago

@detobel36 great improvement but I will make some minor adjustments before merging, probably tomorrow (for the console logs in particular)

Avec ta permission 😉

detobel36 commented 1 year ago

@detobel36 great improvement but I will make some minor adjustments before merging, probably tomorrow (for the console logs in particular)

Avec ta permission wink

Thank you for your reply!

Obviously, you can change what you want, it's your project :wink:

Tell me if I can help :stuck_out_tongue_winking_eye:

FR Reply Merci pour ta réponse. J'ai continué en anglais pour que des éventuels contributeurs anglophone puisse suivrent :wink: Tu modifies évidemment tout ce que tu veux... C'est ton projet. Dit moi si je sais aider :stuck_out_tongue_winking_eye: