Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Component modifies the file name giving an incorrect extra file extension #135

Closed
mballen-1 opened this issue Apr 18, 2020 · 8 comments · Fixed by #137, #151 or #152
Closed

Component modifies the file name giving an incorrect extra file extension #135

mballen-1 opened this issue Apr 18, 2020 · 8 comments · Fixed by #137, #151 or #152
Assignees
Labels

Comments

@mballen-1
Copy link

mballen-1 commented Apr 18, 2020

Hi @Yuvaleros, thanks for this cool component

I found an issue while providing initialFiles as initialFiles={[https://images.pexels.com/photos/1909603/pexels-photo-1909603.jpeg`]}` Dropzone component modifies the file name giving an incorrect extra extension. This is an unexpected behaviour

image

Are you guys able to fix this issue? Thanks a lot

@mballen-1 mballen-1 changed the title Appending extension to initialFiles names Providing initialFiles URLS component modifies the file name giving an incorrect extra file extension Apr 18, 2020
@mballen-1 mballen-1 changed the title Providing initialFiles URLS component modifies the file name giving an incorrect extra file extension Component modifies the file name giving an incorrect extra file extension Apr 18, 2020
@panz3r panz3r added the bug label Apr 20, 2020
@panz3r panz3r self-assigned this Apr 20, 2020
@mballen-1
Copy link
Author

Hi @panz3r Today I've updated material ui dropzone to ^2.5.0 package but unfortunately issue is still presenting ... Am I missing any configuration or something ? Thanks for your attention to this!

@panz3r
Copy link
Contributor

panz3r commented Apr 24, 2020

Hi @mballeng91 ,

You are right, although the changes have been merged they are yet to be published to npm, for now if you need to upgrade you can install the module directly from GitHub

for release v3.x

❯ npm i yuvaleros/material-ui-dropzone#d9f1c22

(the same also works with yarn)

for release v2.x

❯ npm i yuvaleros/material-ui-dropzone#d26e28b

To see the differences between the 2 version see the CHANGELOG.

Thanks for your feedback and patience.

@mballen-1
Copy link
Author

Thanks a lot!

@mballen-1
Copy link
Author

Hi @panz3r I've tried both versions you suggested me, but none of them seems to work with the fix. Could you please check once again ? Thanks for your patience with this request

@panz3r
Copy link
Contributor

panz3r commented Apr 30, 2020

Hi @mballeng91 ,

Thanks for your feedback.

I'll check this once again, I think to know the cause of the issue and should be related to extensions not matching MIME types (like jpeg and jpg both matching image/jpeg).

Have you got an example filename that's causing you issues?

@panz3r panz3r reopened this Apr 30, 2020
@mballen-1
Copy link
Author

Sure, whenever I try to load an image which extension is jpg... It's name is automatically changed
image
The original file name was 'EFFECTS.jpg' but it's modified to 'EFFECTS.jpg.jpeg'

@panz3r
Copy link
Contributor

panz3r commented May 1, 2020

Hi @mballeng91 ,

Merged the fix for this issue into both master and v2.x branches.

Until published to npm, for release v3.x use

❯ npm i yuvaleros/material-ui-dropzone#be31b59

(the same also works with yarn)

for release v2.x

❯ npm i yuvaleros/material-ui-dropzone#2dab561

To see the differences between the 2 version see the CHANGELOG.

Thanks for your feedback and patience.

@mballen-1
Copy link
Author

The component works perfectly now (v3), Thanks a lot @panz3r

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment