fix: fixed image transparency by adding alpha option to preserve image alpha channel (#8895)

added alpha option to preserve image alpha channel
This commit is contained in:
Antonio Della Fortuna
2024-12-10 13:41:10 +01:00
committed by GitHub
parent 8a1152ce36
commit 9b401f6ea3

View File

@ -329,7 +329,7 @@ export const resizeImageFile = async (
}
return new File(
[await reduce.toBlob(file, { max: opts.maxWidthOrHeight })],
[await reduce.toBlob(file, { max: opts.maxWidthOrHeight, alpha: true })],
file.name,
{
type: opts.outputType || file.type,