From 19306fbef90b6a945552d2ebff75ddad18682a9c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B0=B1=E7=9C=A0=E5=84=80=E5=BC=8F?= <854085467@qq.com> Date: Wed, 9 Feb 2022 13:45:27 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BE=9B=E9=99=A4=20primary=20?= =?UTF-8?q?=E5=A4=96=E7=9A=84=E5=85=B6=E4=BB=96=E6=AC=A1=E8=89=B2=E5=8F=98?= =?UTF-8?q?=E9=87=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/component/button/index.less | 12 +++++++++--- src/theme/variable.less | 12 ++++++++++++ 2 files changed, 21 insertions(+), 3 deletions(-) diff --git a/src/component/button/index.less b/src/component/button/index.less index 06cf201e..6039e320 100644 --- a/src/component/button/index.less +++ b/src/component/button/index.less @@ -3,11 +3,17 @@ @button-primary-color: var(--button-primary-color); @button-border-radius: var(--button-border-radius); @button-border-color: var(--button-border-color); +@button-normal-color: var(--button-normal-color); +@button-warm-color: var(--button-warm-color); +@button-danger-color: var(--button-danger-color); :root { --button-primary-color: @global-primary-color; --button-border-radius: @global-border-radius; --button-border-color: #d2d2d2; + --button-normal-color: @global-normal-color; + --button-warm-color: @global-warm-color; + --button-danger-color: @global-danger-color; } .layui-btn { @@ -60,15 +66,15 @@ } .layui-btn-normal { - background-color: #1e9fff; + background-color: @button-normal-color; } .layui-btn-warm { - background-color: #ffb800; + background-color: @button-warm-color; } .layui-btn-danger { - background-color: #ff5722; + background-color: @button-danger-color; } .layui-btn-lg { diff --git a/src/theme/variable.less b/src/theme/variable.less index 1fabcefe..433ae4ef 100644 --- a/src/theme/variable.less +++ b/src/theme/variable.less @@ -1,5 +1,11 @@ @global-primary-color: var(--global-primary-color); +@global-normal-color: var(--global-normal-color); + +@global-warm-color: var(--global-warm-color); + +@global-danger-color: var(--global-danger-color); + @global-checked-color: var(--global-checked-color); @global-border-radius: var(--global-border-radius); @@ -14,6 +20,12 @@ --global-primary-color: #009688; + --global-normal-color: #1e9fff; + + --global-warm-color: #ffb800; + + --global-danger-color: #ff5722; + --global-checked-color: #5fb878; --global-border-color: #eee;