From e3ad856543089f5714c04790f722e61f34b68bdf Mon Sep 17 00:00:00 2001 From: Konv Suu <2583695112@qq.com> Date: Tue, 22 Aug 2023 14:03:09 +0800 Subject: [PATCH] fix(badge): dot with processing status (#6874) * fix(badge): dot with processing status * tests: update snapshot --- .../__tests__/__snapshots__/demo.test.js.snap | 279 ++++++++++-------- components/badge/style/index.ts | 2 +- 2 files changed, 155 insertions(+), 126 deletions(-) diff --git a/components/badge/__tests__/__snapshots__/demo.test.js.snap b/components/badge/__tests__/__snapshots__/demo.test.js.snap index b08e26cb0..1e3a9a8f6 100644 --- a/components/badge/__tests__/__snapshots__/demo.test.js.snap +++ b/components/badge/__tests__/__snapshots__/demo.test.js.snap @@ -33,19 +33,19 @@ exports[`renders ./components/badge/demo/change.vue correctly 1`] = ` exports[`renders ./components/badge/demo/colors.vue correctly 1`] = `

Presets:

-
pink
-
red
-
yellow
-
orange
-
cyan
-
green
-
blue
-
purple
-
geekblue
-
magenta
-
volcano
-
gold
-
lime
+
pink
+
red
+
yellow
+
orange
+
cyan
+
green
+
blue
+
purple
+
geekblue
+
magenta
+
volcano
+
gold
+
lime
#f50 @@ -89,141 +89,167 @@ exports[`renders ./components/badge/demo/overflow.vue correctly 1`] = ` `; exports[`renders ./components/badge/demo/ribbon.vue correctly 1`] = ` -
-
-
-
-
Pushes open the window
+
+
+
+
+
+
+
Pushes open the window
+ +
+ +
+ +
and raises the spyglass.
- +
Hippies +
+
- -
and raises the spyglass.
-
-
Hippies -
-
-
-
-
-
-
-
Pushes open the window
+ +
+
+
+
+
+
Pushes open the window
+ +
+ +
+ +
and raises the spyglass.
- +
Hippies +
+
- -
and raises the spyglass.
-
-
Hippies -
-
-
-
-
-
-
-
Pushes open the window
+ +
+
+
+
+
+
Pushes open the window
+ +
+ +
+ +
and raises the spyglass.
- +
Hippies +
+
- -
and raises the spyglass.
-
-
Hippies -
-
-
-
-
-
-
-
Pushes open the window
+ +
+
+
+
+
+
Pushes open the window
+ +
+ +
+ +
and raises the spyglass.
- +
Hippies +
+
- -
and raises the spyglass.
-
-
Hippies -
-
-
-
-
-
-
-
Pushes open the window
+ +
+
+
+
+
+
Pushes open the window
+ +
+ +
+ +
and raises the spyglass.
- +
Hippies +
+
- -
and raises the spyglass.
-
-
Hippies -
-
-
-
-
-
-
-
Pushes open the window
+ +
+
+
+
+
+
Pushes open the window
+ +
+ +
+ +
and raises the spyglass.
- +
Hippies +
+
- -
and raises the spyglass.
-
-
Hippies -
-
-
-
-
-
-
-
Pushes open the window
+ +
+
+
+
+
+
Pushes open the window
+ +
+ +
+ +
and raises the spyglass.
- +
Hippies +
+
- -
and raises the spyglass.
-
-
Hippies -
-
-
-
-
-
-
-
Pushes open the window
+ +
+
+
+
+
+
Pushes open the window
+ +
+ +
+ +
and raises the spyglass.
- +
Hippies +
+
- -
and raises the spyglass.
- -
-
Hippies -
+
`; @@ -234,15 +260,18 @@ exports[`renders ./components/badge/demo/status.vue correctly 1`] = `
-Success -
-Error -
-Default -
-Processing -
-warning +
+
Success
+ +
Error
+ +
Default
+ +
Processing
+ +
warning
+ +
`; exports[`renders ./components/badge/demo/title.vue correctly 1`] = ` diff --git a/components/badge/style/index.ts b/components/badge/style/index.ts index 67ac2c829..7589799b6 100644 --- a/components/badge/style/index.ts +++ b/components/badge/style/index.ts @@ -178,7 +178,7 @@ const genSharedBadgeStyle: GenerateStyle = (token: BadgeToken): CSSO backgroundColor: token.colorSuccess, }, [`${componentCls}-status-processing`]: { - position: 'relative', + overflow: 'visible', color: token.colorPrimary, backgroundColor: token.colorPrimary,