feat(编辑阅读): 完善保真编辑与跨文档复制,优化后端缓存和大文件性能
build.yaml / build (push) Successful in 41s

This commit is contained in:
xiaoqidun committed 2026-09-24 13:48:48 +08:00
1 parent 06b5df9173
commit 697a059162
18 files changed
+694 -130

No files matched your search

+3
View File
@@ -1186,10 +1186,12 @@ export class CanvasEditor {
input.setAttribute("aria-label", "编辑文字");
input.setAttribute("role", "textbox");
input.setAttribute("aria-multiline", "true");
input.setAttribute("dir", "auto");
input.contentEditable = "true";
input.spellcheck = false;
for (const text of item.text.split("\n")) {
const paragraph = document.createElement("div");
paragraph.setAttribute("dir", "auto");
if (text) paragraph.textContent = text;
else paragraph.append(document.createElement("br"));
input.append(paragraph);
@@ -1206,6 +1208,7 @@ export class CanvasEditor {
minHeight: autoSize ? "0px" : `${frame.height * PX_PER_MM + 4}px`,
transform: `matrix(${a},${b},${c},${d},${(e + a * left) * PX_PER_MM},${(f + b * left) * PX_PER_MM})`,
whiteSpace: item.wrap ? "pre-wrap" : "pre",
unicodeBidi: "plaintext",
fontFamily: `"${face.family}"`, fontSize: `${item.size * PX_PER_MM}px`,
lineHeight: item.paragraphHeight || item.lineHeight ? `${(item.paragraphHeight || item.lineHeight) * PX_PER_MM}px` : "normal", color: item.color,
textAlign: item.align || "left",