From 22b0bd2e908c5b0066634fa0d24321fba0e53735 Mon Sep 17 00:00:00 2001 From: Vanessa Date: Wed, 19 Jun 2024 11:21:37 +0800 Subject: [PATCH] :art: https://github.com/siyuan-note/siyuan/issues/11757 --- app/src/menus/protyle.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/menus/protyle.ts b/app/src/menus/protyle.ts index a7fb80203..0c3f3c87f 100644 --- a/app/src/menus/protyle.ts +++ b/app/src/menus/protyle.ts @@ -1464,11 +1464,11 @@ const genImageWidthMenu = (label: string, assetElement: HTMLElement, imgElement: click() { nodeElement.setAttribute("updated", dayjs().format("YYYYMMDDHHmmss")); if (label === window.siyuan.languages.default) { - const isCenter = assetElement.style.display === "block"; + const isCenter = assetElement.style.display === "block" || assetElement.style.minWidth; assetElement.removeAttribute("style"); imgElement.removeAttribute("style"); if (isCenter) { - assetElement.style.display = "block"; + assetElement.style.minWidth = "calc(100% - 0.1em)"; } } else { assetElement.style.width = label;