Optimize user-generated images for reduced bandwidth (#961)

* Optimize user-generated images for reduced bandwidth

* run prepare

* Finish compression
This commit is contained in:
Geometrically
2024-09-07 17:44:49 -07:00
committed by GitHub
parent cb0f03ca9c
commit 5b5599128a
51 changed files with 1306 additions and 1016 deletions
+2
View File
@@ -357,6 +357,7 @@ impl From<Version> for LegacyVersion {
#[derive(Serialize, Deserialize, Clone, Debug)]
pub struct LegacyGalleryItem {
pub url: String,
pub raw_url: String,
pub featured: bool,
pub title: Option<String>,
pub description: Option<String>,
@@ -368,6 +369,7 @@ impl LegacyGalleryItem {
fn from(data: crate::models::projects::GalleryItem) -> Self {
Self {
url: data.url,
raw_url: data.raw_url,
featured: data.featured,
title: data.name,
description: data.description,
+2
View File
@@ -215,6 +215,7 @@ impl From<QueryProject> for Project {
.into_iter()
.map(|x| GalleryItem {
url: x.image_url,
raw_url: x.raw_image_url,
featured: x.featured,
name: x.name,
description: x.description,
@@ -387,6 +388,7 @@ impl Project {
#[derive(Serialize, Deserialize, Clone, Debug)]
pub struct GalleryItem {
pub url: String,
pub raw_url: String,
pub featured: bool,
pub name: Option<String>,
pub description: Option<String>,