From 8f8f2b6100846e1d496a47b7c8a793b086eab34b Mon Sep 17 00:00:00 2001 From: Vanessa Date: Tue, 19 Jul 2022 00:48:53 +0800 Subject: [PATCH] :art: fix https://github.com/siyuan-note/siyuan/issues/5454 --- app/src/protyle/gutter/index.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/app/src/protyle/gutter/index.ts b/app/src/protyle/gutter/index.ts index f825ce8fe..a945189c7 100644 --- a/app/src/protyle/gutter/index.ts +++ b/app/src/protyle/gutter/index.ts @@ -974,10 +974,14 @@ export class Gutter { element.querySelector("input").addEventListener("change", (event) => { const newHeight = ((event.target as HTMLInputElement).value || "420") + "px"; (nodeElement as HTMLElement).style.height = newHeight; - (nodeElement.firstElementChild as HTMLElement).style.height = newHeight; + (nodeElement.firstElementChild.nextElementSibling as HTMLElement).style.height = newHeight; updateTransaction(protyle, id, nodeElement.outerHTML, html); html = nodeElement.outerHTML; event.stopPropagation(); + const chartInstance = echarts.getInstanceById(nodeElement.firstElementChild.nextElementSibling.getAttribute("_echarts_instance_")); + if (chartInstance) { + chartInstance.resize(); + } }); } }, {