mirror of
https://github.com/mealie-recipes/mealie.git
synced 2025-08-05 13:35:23 +02:00
Feature/image minify (#256)
* fix settings * app info cleanup * bottom-bar experiment * remove dup key * type hints * add dependency * updated image with query parameters * read image options * add image minification * add image minification step * alt image routes * add image minification * set mobile bar to top Co-authored-by: hay-kot <hay-kot@pm.me>
This commit is contained in:
parent
bc595d5cfa
commit
95213fa41b
31 changed files with 487 additions and 172 deletions
|
@ -56,9 +56,7 @@ export const recipeAPI = {
|
|||
const fd = new FormData();
|
||||
fd.append("image", fileObject);
|
||||
fd.append("extension", fileObject.name.split(".").pop());
|
||||
|
||||
let response = apiReq.put(recipeURLs.updateImage(recipeSlug), fd);
|
||||
|
||||
return response;
|
||||
},
|
||||
|
||||
|
@ -87,4 +85,16 @@ export const recipeAPI = {
|
|||
|
||||
return response.data;
|
||||
},
|
||||
|
||||
recipeImage(recipeSlug) {
|
||||
return `/api/recipes/${recipeSlug}/image?image_type=original`;
|
||||
},
|
||||
|
||||
recipeSmallImage(recipeSlug) {
|
||||
return `/api/recipes/${recipeSlug}/image?image_type=small`;
|
||||
},
|
||||
|
||||
recipeTinyImage(recipeSlug) {
|
||||
return `/api/recipes/${recipeSlug}/image?image_type=tiny`;
|
||||
},
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue