🌱 公告解析重构

This commit is contained in:
目棃
2024-08-13 20:07:55 +08:00
parent 46214a6d64
commit 9fb95c6ade
7 changed files with 398 additions and 32 deletions

View File

@@ -28,6 +28,7 @@ export interface TpImage {
align?: "center"; // 待补充
};
}
interface TpImageProps {
data: TpImage;
}
@@ -66,6 +67,7 @@ function getImageTitle(): string {
function getImageUrl(): string {
const img = props.data.insert.image;
const append = "?x-oss-process=image/format,png";
console.log("getImageUrl", img, append);
if (img.endsWith(".gif")) return img;
return img + append;
}