From fe609ed2394ebe5595bb07cf7892d9b1ca1bfc88 Mon Sep 17 00:00:00 2001 From: WOSHIMAHAIFENG Date: Thu, 14 Mar 2024 17:43:33 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A1=A5=E5=85=85hoverclass=E9=BB=98=E8=AE=A4?= =?UTF-8?q?=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/component/button/button.uvue | 23 ++++++++++++++--------- pages/component/button/buttonstatus.uvue | 15 ++++++++++++--- 2 files changed, 26 insertions(+), 12 deletions(-) diff --git a/pages/component/button/button.uvue b/pages/component/button/button.uvue index 7a000f30..8e9e346a 100644 --- a/pages/component/button/button.uvue +++ b/pages/component/button/button.uvue @@ -35,14 +35,14 @@ uni.navigateTo({ url: 'buttonstatus', }) - }, - //用于自动化测试 - checkUniButtonElement(): boolean { - const button = uni.getElementById("testButton") - if(button != null && button instanceof UniButtonElement) { - return true - } - return false + }, + //用于自动化测试 + checkUniButtonElement() : boolean { + const button = uni.getElementById("testButton") + if (button != null && button instanceof UniButtonElement) { + return true + } + return false } } } @@ -65,7 +65,7 @@ - + @@ -97,4 +97,9 @@ background-color: #179b16; border-color: #179b16; } + + .button-hover { + color: rgba(0, 0, 0, 0.6); + background-color: #dedede; + } diff --git a/pages/component/button/buttonstatus.uvue b/pages/component/button/buttonstatus.uvue index fb255740..ecaeb94b 100644 --- a/pages/component/button/buttonstatus.uvue +++ b/pages/component/button/buttonstatus.uvue @@ -180,7 +180,16 @@ .container { width: 100%; - height: 60px; - /* background-color: orange; */ - } + height: 60px; + } + .is-hover { + color: rgba(255, 255, 255, 0.6); + background-color: #179b16; + border-color: #179b16; + } + + .button-hover { + color: rgba(0, 0, 0, 0.6); + background-color: #dedede; + } -- GitLab