This commit is contained in:
Vanessa 2024-12-20 12:23:49 +08:00
parent 20b4579170
commit 59360f363e
3 changed files with 24 additions and 16 deletions

View file

@ -0,0 +1,9 @@
export const img3115 = (imgElement: HTMLElement) => {
// 移除 3.1.15 以前 .img width 样式
if (imgElement.style.minWidth) {
// 居中需要 minWidth 样式,不能移除 style 属性
imgElement.style.width = "";
} else {
imgElement.removeAttribute("style");
}
}