From 45d1dc10e8118154d43e82d9c06f1391e06ddfc6 Mon Sep 17 00:00:00 2001 From: Vanessa Date: Wed, 24 Apr 2024 21:33:31 +0800 Subject: [PATCH] :iphone: status --- app/src/dialog/processSystem.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/src/dialog/processSystem.ts b/app/src/dialog/processSystem.ts index 0d08c19fd..e7d497247 100644 --- a/app/src/dialog/processSystem.ts +++ b/app/src/dialog/processSystem.ts @@ -278,6 +278,7 @@ export const transactionError = () => { }); }; +let statusMobileTimeout:number; export const progressStatus = (data: IWebSocketData) => { const statusElement = document.querySelector("#status") as HTMLElement; if (!statusElement) { @@ -287,9 +288,10 @@ export const progressStatus = (data: IWebSocketData) => { if (!document.querySelector("#keyboardToolbar").classList.contains("fn__none")) { return; } + clearTimeout(statusMobileTimeout); statusElement.innerHTML = data.msg; statusElement.style.bottom = "0"; - setTimeout(() => { + statusMobileTimeout = window.setTimeout(() => { statusElement.style.bottom = ""; }, 5000); return;