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

Preresize images before storing them #3354

Open
kof opened this issue May 14, 2024 · 1 comment
Open

Preresize images before storing them #3354

kof opened this issue May 14, 2024 · 1 comment
Labels
area:assets Assets manager and rendering prio:2 Always look for prio:1 issues first before working on prio:2 type:bug Something isn't working type:feature Big task affecting the end user

Comments

@kof
Copy link
Member

kof commented May 14, 2024

As a user I don't want to care about the size of the images I upload, webstudio should take care of that.

Reported bug:

Try to upload any image with a big resolution, e.g. 9800px. It will start uploading in asset manager, then show erorred/broken thumb.

I can see this in the response

image

What we can do

  • Preresize the image if it has too large dimensions or too big file size before storing it in our storage
  • This will also ensure optimium speed on image resizer because it can take too much time on first render if the image is too big
  • additionally for lightbox type of use cases, we should probably have 2 types of images:
    • under 2k for general usage for fast resizing
    • 4k for large views like lightbox, if the original allows
@kof kof added type:bug Something isn't working prio:2 Always look for prio:1 issues first before working on prio:2 area:assets Assets manager and rendering labels May 14, 2024
@kof
Copy link
Member Author

kof commented May 15, 2024

we need to check why CF resizer showing this error and catch it before they do ourselves to show user a meaningful error

@kof kof changed the title Too big image dimension result in an error with no particular description Preresize images before storing them Jun 7, 2024
@kof kof added the type:feature Big task affecting the end user label Jun 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:assets Assets manager and rendering prio:2 Always look for prio:1 issues first before working on prio:2 type:bug Something isn't working type:feature Big task affecting the end user
Projects
None yet
Development

No branches or pull requests

1 participant