zed-industries / zed

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
https://zed.dev
Other
39.56k stars 2.06k forks source link

Support for WebP files #11863

Open jsarnowski-un7 opened 1 month ago

jsarnowski-un7 commented 1 month ago

Check for existing issues

Describe the feature

Currently, there's no preview for .webp files in Zed.

If applicable, add mockups / screenshots to help present your vision of the feature

example.zip

bbb651 commented 1 month ago

It seems img element is broken for webp in general, it does correctly opens an image preview editor but the image (taken from here) doesn't display inside it: image With this error:

[ERROR util] crates/gpui/src/elements/img.rs:345: Image(Unsupported(UnsupportedError { format: Exact(WebP), kind: GenericFeature("VP8L") }))

that comes from image, it's odd because afaict the webp feature should be enabled by default, I'll look into it more later