Browse Source

:lipstick: https://github.com/siyuan-note/siyuan/issues/12855

Vanessa 9 months ago
parent
commit
0fdac67a8d
2 changed files with 3 additions and 1 deletions
  1. 2 0
      app/src/assets/scss/component/_typography.scss
  2. 1 1
      app/src/menus/protyle.ts

+ 2 - 0
app/src/assets/scss/component/_typography.scss

@@ -434,6 +434,8 @@
       color: var(--b3-theme-on-surface);
       color: var(--b3-theme-on-surface);
       word-break: break-word;
       word-break: break-word;
       white-space: break-spaces;
       white-space: break-spaces;
+      line-height: normal;
+      padding: 4px 0;
     }
     }
   }
   }
 
 

+ 1 - 1
app/src/menus/protyle.ts

@@ -1036,7 +1036,7 @@ export const imgMenu = (protyle: IProtyle, range: Range, assetElement: HTMLEleme
                         assetElement.querySelector(".protyle-action__drag").insertAdjacentHTML("afterend", '<span class="img__net"><svg><use xlink:href="#iconLanguage"></use></svg></span>');
                         assetElement.querySelector(".protyle-action__drag").insertAdjacentHTML("afterend", '<span class="img__net"><svg><use xlink:href="#iconLanguage"></use></svg></span>');
                     }
                     }
                 });
                 });
-                textElements[1].value = titleElement.textContent;
+                textElements[1].value = titleElement.innerText;
                 textElements[1].addEventListener("input", (event) => {
                 textElements[1].addEventListener("input", (event) => {
                     const value = (event.target as HTMLInputElement).value;
                     const value = (event.target as HTMLInputElement).value;
                     imgElement.setAttribute("title", value);
                     imgElement.setAttribute("title", value);