From d459cb8ba228d96c097b430ae10f2588d090f430 Mon Sep 17 00:00:00 2001 From: ThatOneCalculator Date: Thu, 27 Oct 2022 15:28:02 -0700 Subject: [PATCH] =?UTF-8?q?feat:=20=E2=9C=A8=20Append=20caption=20to=20tex?= =?UTF-8?q?tarea?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 2 +- packages/client/src/components/MkMediaCaption.vue | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index c67e7591f..ff151207b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "calckey", - "version": "12.119.0-calc.6.1", + "version": "12.119.0-calc.6.2", "codename": "aqua", "repository": { "type": "git", diff --git a/packages/client/src/components/MkMediaCaption.vue b/packages/client/src/components/MkMediaCaption.vue index 6abaa73dd..1ede61756 100644 --- a/packages/client/src/components/MkMediaCaption.vue +++ b/packages/client/src/components/MkMediaCaption.vue @@ -7,7 +7,6 @@ {{ remainingLength }}
-
@@ -142,12 +141,11 @@ export default defineComponent({ caption() { const img = document.getElementById('imgtocaption') as HTMLImageElement; + const ta = document.getElementById('captioninput') as HTMLTextAreaElement; os.api('drive/files/caption-image', { url: img.src, }).then(text => { - document.getElementById('recognized-text').innerText = text; - const allowedLength = 512 - this.inputValue.length; - this.inputValue += text.slice(0, allowedLength); + ta.value += text.slice(0, (512 - ta.value.length)); }); }, },