feat: compute thumbhash for images (#596)

* feat: compute thumbhash for images

Signed-off-by: newt <hi@newty.dev>

* Merge branch 'main' into feat/thumbhash

Signed-off-by: newt <hi@newty.dev>

* style: move comment onto newline

Signed-off-by: newt <hi@newty.dev>

* feat: make thumbhash optional

Signed-off-by: newt <hi@newty.dev>

---------

Signed-off-by: newt <hi@newty.dev>
Signed-off-by: newt (: <hi@newty.dev>
Signed-off-by: Tom <iamtomahawkx@gmail.com>
Co-authored-by: Tom <iamtomahawkx@gmail.com>
This commit is contained in:
newt (
2026-03-28 00:29:55 +00:00
committed by GitHub
parent 91783b9066
commit c2d4369e16
7 changed files with 34 additions and 5 deletions

View File

@@ -19,6 +19,7 @@ pub async fn strip_metadata(
Metadata::Image {
width,
height,
thumbhash,
animated,
} => match mime {
// // little_exif does not appear to parse JPEGs correctly? had 2/2 files fail
@@ -102,6 +103,7 @@ pub async fn strip_metadata(
Metadata::Image {
width,
height,
thumbhash: thumbhash.clone(),
animated: *animated,
},
))