From ad1046ede0f70ea08dffd8af73225322e52f8396 Mon Sep 17 00:00:00 2001
From: afeiship <1290657123@qq.com>
Date: Sun, 4 Apr 2021 12:15:45 +0800
Subject: [PATCH] =?UTF-8?q?feat:=20=E6=B7=BB=E5=8A=A0=20is-samll=20for=20w?=
=?UTF-8?q?sui-tag?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
__stories__/components/tag.html | 7 +++++++
src/components/tag.scss | 11 ++++++++---
2 files changed, 15 insertions(+), 3 deletions(-)
diff --git a/__stories__/components/tag.html b/__stories__/components/tag.html
index 38ba095..63ccd30 100644
--- a/__stories__/components/tag.html
+++ b/__stories__/components/tag.html
@@ -2,3 +2,10 @@
Tag1
Tag2
+
+
+
+
+ Tag1
+ Tag2
+
diff --git a/src/components/tag.scss b/src/components/tag.scss
index 88f42be..376cbf8 100644
--- a/src/components/tag.scss
+++ b/src/components/tag.scss
@@ -1,8 +1,8 @@
.#{$prefix}-tag {
$color: #4e1cc7;
color: $color;
- background: lighten($color, 50%);
- border:1px dashed lighten($color, 40%);
+ background: lighten($color, 50%);
+ border: 1px dashed lighten($color, 40%);
font-family: Menlo, "Dank Mono", Inconsolata, "Operator Mono", Consolas, "Andale Mono WT", "Andale Mono",
"Lucida Console", "Lucida Sans Typewriter", "DejaVu Sans Mono", "Bitstream Vera Sans Mono", "Liberation Mono",
"Nimbus Mono L", "Courier New", Courier, monospace;
@@ -12,7 +12,12 @@
font-size: 14px;
cursor: pointer;
transition: background 0.3s;
- &:hover{
+ &:hover {
background: lighten($color: $color, $amount: 40%);
}
+
+ &.is-small {
+ padding: 0.15em 0.5em;
+ font-size: 12px;
+ }
}