From e96cf69bcbed8c28963befa8d11ecd5a8ec51107 Mon Sep 17 00:00:00 2001 From: wangzhiyusss Date: Wed, 8 Mar 2023 11:07:24 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=A4=87=E5=BF=98=E5=BD=95?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E4=BC=B8=E7=BC=A9=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: wangzhiyusss --- common/resources/src/main/resources/rawfile/editor.html | 2 +- common/resources/src/main/resources/rawfile/rich_editor.js | 6 +++--- .../src/main/ets/components/NoteContentCompPortrait.ets | 1 + 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/common/resources/src/main/resources/rawfile/editor.html b/common/resources/src/main/resources/rawfile/editor.html index 9bda9dd..ceef7e4 100644 --- a/common/resources/src/main/resources/rawfile/editor.html +++ b/common/resources/src/main/resources/rawfile/editor.html @@ -5,7 +5,7 @@ "editorJs" - + diff --git a/common/resources/src/main/resources/rawfile/rich_editor.js b/common/resources/src/main/resources/rawfile/rich_editor.js index 2b0fb72..2141a1b 100644 --- a/common/resources/src/main/resources/rawfile/rich_editor.js +++ b/common/resources/src/main/resources/rawfile/rich_editor.js @@ -27,7 +27,7 @@ RICH_EDITOR.setHtml = function (contents) { }; RICH_EDITOR.getHtml = function () { - return document.getElementById('editorjs_box').editor.innerHTML; + return document.getElementById('editorjs_box').innerHTML; }; RICH_EDITOR.undo = function () { @@ -279,8 +279,8 @@ RICH_EDITOR.insertImage = function (url) { var html = '

picvision

'; - document.getElementById('editorjs').innerHTML += html - document.getElementById('editorjs').scrollIntoView(false); + document.getElementById('editorjs_img').innerHTML += html + document.getElementById('editorjs_img').scrollIntoView(false); }; RICH_EDITOR.insertHTML = function (html) { diff --git a/features/src/main/ets/components/NoteContentCompPortrait.ets b/features/src/main/ets/components/NoteContentCompPortrait.ets index 2000c1e..1198e61 100644 --- a/features/src/main/ets/components/NoteContentCompPortrait.ets +++ b/features/src/main/ets/components/NoteContentCompPortrait.ets @@ -253,6 +253,7 @@ export struct NoteContentCompPortrait { Column() { Web({ src: $rawfile('editor.html'), controller: this.controllerShow }) + .overviewModeAccess(false) .javaScriptAccess(true) .javaScriptProxy({ object: this.noteContent, -- Gitee