An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作
TypeScript agentic-aiai-agentknowledge-baselocal-firstmarkdownmcpmindmapnote-takingself-hostedsiyuanworkspace
:art: https://github.com/siyuan-note/siyuan/issues/16239
Vanessa2d1f12ec3327
diff --git a/app/src/assets/scss/component/_typography.scss b/app/src/assets/scss/component/_typography.scssindex c1a2f73348..8c9f2893e1 100644--- a/app/src/assets/scss/component/_typography.scss+++ b/app/src/assets/scss/component/_typography.scss@@ -408,10 +408,13 @@[data-subtype="NodeIFrame"],[data-subtype="widget"] {+ height: 256px;+ width: 100%;+.iframe-content {+ position: relative;+ height: 100%;width: 100%;- height: 256px;- max-width: 100%;}iframe {diff --git a/app/src/assets/scss/protyle/_wysiwyg.scss b/app/src/assets/scss/protyle/_wysiwyg.scssindex 26c98d4617..539eeb8983 100644--- a/app/src/assets/scss/protyle/_wysiwyg.scss+++ b/app/src/assets/scss/protyle/_wysiwyg.scss@@ -513,11 +513,6 @@-webkit-user-modify: read-only;}- .iframe-content {- display: inline-block;- position: relative;- }-&--drag {.iframe-content::after {content: "";diff --git a/app/src/protyle/gutter/index.ts b/app/src/protyle/gutter/index.tsindex 912c0d2771..28a2622595 100644--- a/app/src/protyle/gutter/index.ts+++ b/app/src/protyle/gutter/index.ts@@ -2102,6 +2102,8 @@ export class Gutter {this.genClick(nodeElements, protyle, (e: HTMLElement) => {if (e.classList.contains("av")) {e.style.justifyContent = "";+ } else if (["NodeIFrame", "widget"].includes(e.getAttribute("data-subtype"))) {+ e.style.margin = "";} else {e.style.textAlign = "left";}@@ -2116,6 +2118,8 @@ export class Gutter {this.genClick(nodeElements, protyle, (e: HTMLElement) => {if (e.classList.contains("av")) {e.style.justifyContent = "center";+ } else if (["NodeIFrame", "widget"].includes(e.getAttribute("data-subtype"))) {+ e.style.margin = "0 auto";} else {e.style.textAlign = "center";}@@ -2130,6 +2134,8 @@ export class Gutter {this.genClick(nodeElements, protyle, (e: HTMLElement) => {if (e.classList.contains("av")) {e.style.justifyContent = "flex-end";+ } else if (["NodeIFrame", "widget"].includes(e.getAttribute("data-subtype"))) {+ e.style.margin = "0 0 0 auto";} else {e.style.textAlign = "right";}@@ -2180,6 +2186,8 @@ export class Gutter {this.genClick(nodeElements, protyle, (e: HTMLElement) => {if (e.classList.contains("av")) {e.style.justifyContent = "";+ } else if (["NodeIFrame", "widget"].includes(e.getAttribute("data-subtype"))) {+ e.style.margin = "";} else {e.style.textAlign = "";e.style.direction = "";diff --git a/app/src/protyle/wysiwyg/index.ts b/app/src/protyle/wysiwyg/index.tsindex c3b37ee2b8..c9ca0ca175 100644--- a/app/src/protyle/wysiwyg/index.ts+++ b/app/src/protyle/wysiwyg/index.ts@@ -923,11 +923,16 @@ export class WYSIWYG {return;}let isCenter = true;- if (["NodeIFrame", "NodeWidget", "NodeVideo"].includes(nodeElement.getAttribute("data-type"))) {+ if ("NodeVideo" === nodeElement.dataset.type) {nodeElement.classList.add("iframe--drag");if (["left", "right", ""].includes(nodeElement.style.textAlign)) {isCenter = false;}+ } else if (["NodeIFrame", "NodeWidget"].includes(nodeElement.dataset.type)) {+ nodeElement.classList.add("iframe--drag");+ if (!nodeElement.style.margin) {+ isCenter = false;+ }} else if (target.parentElement.parentElement.getAttribute("data-type") === "img") {target.parentElement.parentElement.classList.add("img--drag");}@@ -943,6 +948,11 @@ export class WYSIWYG {if (dragElement.tagName === "IMG") {img3115(imgElement);}+ // 3.4.1 以前历史数据兼容+ if (dragElement.tagName === "IFRAME") {+ dragElement.style.height = "";+ dragElement.style.width = "";+ }documentSelf.onmousemove = (moveEvent: MouseEvent) => {if (dragElement.tagName === "IMG") {dragElement.style.height = "";@@ -952,7 +962,7 @@ export class WYSIWYG {if (dragElement.tagName === "IMG") {dragElement.parentElement.style.width = Math.max(17, dragWidth + (moveEvent.clientX - x) * multiple) + "px";} else if (dragElement.tagName === "IFRAME") {- dragElement.parentElement.style.width = Math.max(17, dragWidth + (moveEvent.clientX - x) * multiple) + "px";+ nodeElement.style.width = Math.max(17, dragWidth + (moveEvent.clientX - x) * multiple) + "px";} else {dragElement.style.width = Math.max(17, dragWidth + (moveEvent.clientX - x) * multiple) + "px";}@@ -960,7 +970,7 @@ export class WYSIWYG {if (dragElement.tagName !== "IMG") {if (moveEvent.clientY > y - dragHeight + 8 && moveEvent.clientY < mostBottom) {if (dragElement.tagName === "IFRAME") {- dragElement.parentElement.style.height = (dragHeight + (moveEvent.clientY - y)) + "px";+ nodeElement.style.height = (dragHeight + (moveEvent.clientY - y)) + "px";} else {dragElement.style.height = (dragHeight + (moveEvent.clientY - y)) + "px";}