修改缩略图

This commit is contained in:
sjy
2026-07-28 17:33:48 +08:00
parent 7077d05d6a
commit 15deed1cf4
8 changed files with 141 additions and 132 deletions
+5
View File
@@ -0,0 +1,5 @@
/** 构建图片预览 URL,自动拼接 /static 前缀和缩放参数 */
export function buildImagePreviewUrl(url: string): string {
const cleanPath = url.startsWith('/') ? url.slice(1) : url;
return `/static/${cleanPath}&w=300&q=50`;
}