From 460d92caddcbf2fe8a3c91e83931d3b09f7e68a8 Mon Sep 17 00:00:00 2001 From: wood Date: Sat, 29 Jul 2023 02:20:09 +0800 Subject: [PATCH] =?UTF-8?q?git=E9=94=99=E8=AF=AF=E5=90=8E=E6=AD=A3?= =?UTF-8?q?=E5=BC=8F=E7=89=88=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- index.html | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/index.html b/index.html index 3aeb726..09964c7 100644 --- a/index.html +++ b/index.html @@ -340,6 +340,19 @@ font-size: 30px; /* 调整为适当的大小 */ } + + button.loading::before { + content: ""; + display: inline-block; + margin-right: .5rem; + border: 2px solid #fff; + border-top-color: transparent; + border-bottom-color: transparent; + border-radius: 50%; + width: .75rem; + height: .75rem; + animation: rotate .5s linear infinite; + } @@ -358,8 +371,7 @@

输入 API KEY

本站不保存 KEY 信息,查询后请自行保存

-

+

@@ -551,6 +563,11 @@ //查询函数 function sendRequest() { + let button = document.querySelector("button"); + button.textContent = "加载中..."; + button.disabled = true; + button.classList.add("loading") + let apiKeyInput = document.getElementById("api-key-input"); let apiUrlSelect = document.getElementById("api-url-select"); let customUrlInput = document.getElementById("custom-url-input"); @@ -710,6 +727,10 @@ serialNumber++; // 增加序列号 h2.style.display = 'block'; table.style.display = 'table'; + + button.textContent = "查询"; + button.disabled = false; + button.classList.remove("loading") }) }