You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I encountered a bug when used maxSize prop on the Dropzone component. I passed 20 * 1024 * 1024 that equals to 20MB. When I uploaded a file of size 20.3MB the error state didn't occurred. I investigated deeper and found out that 20 * 1024 * 1024 = 20971520 that is bigger than 20312736 (the file size).
In that time the component displays the error correctly when I pass a file of 80MB. It says that File must be less than 20MB..
As a work around I passed 20 * 1000 * 1000 and obtained the desired behavior of the error state but the alert displays inaccurate value of 19.07MB.
The text was updated successfully, but these errors were encountered:
monteri
added
the
bug
Report of or fix for something that isn't working as intended
label
Feb 23, 2024
monteri
changed the title
[bug]: Inaccurate file size calculations in Dropzone
[bug] Inaccurate file size calculations in Dropzone
Feb 23, 2024
I encountered a bug when used
maxSize
prop on theDropzone
component. I passed20 * 1024 * 1024
that equals to20MB
. When I uploaded a file of size20.3MB
the error state didn't occurred. I investigated deeper and found out that20 * 1024 * 1024 = 20971520
that is bigger than20312736
(the file size).In that time the component displays the error correctly when I pass a file of
80MB
. It says thatFile must be less than 20MB.
.As a work around I passed
20 * 1000 * 1000
and obtained the desired behavior of the error state but the alert displays inaccurate value of19.07MB
.The text was updated successfully, but these errors were encountered: