From 1163d8e23ddcb22ef1c94dfb3d6bd21807fc1629 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=8C=E8=B4=A7=E6=9C=BA=E5=99=A8=E4=BA=BA?= Date: Tue, 21 Apr 2020 23:26:41 +0800 Subject: [PATCH] docs: Update demo (#23451) --- .../__tests__/__snapshots__/demo.test.js.snap | 241 ++++++++++++++++-- components/tag/demo/status.md | 47 +++- 2 files changed, 254 insertions(+), 34 deletions(-) diff --git a/components/tag/__tests__/__snapshots__/demo.test.js.snap b/components/tag/__tests__/__snapshots__/demo.test.js.snap index e29fc1f69a..bfbc8259ac 100644 --- a/components/tag/__tests__/__snapshots__/demo.test.js.snap +++ b/components/tag/__tests__/__snapshots__/demo.test.js.snap @@ -604,31 +604,218 @@ exports[`renders ./components/tag/demo/icon.md correctly 1`] = ` `; exports[`renders ./components/tag/demo/status.md correctly 1`] = ` -
- - success - - - processing - - - error - - - default - - - warning - -
+Array [ +
+

+ Without icon +

+ + success + + + processing + + + error + + + warning + + + default + +
, +
+

+ With icon +

+ + + + + + success + + + + + + + + processing + + + + + + + + error + + + + + + + + warning + + + + + + + + waiting + + + + + + + + stop + + +
, +] `; diff --git a/components/tag/demo/status.md b/components/tag/demo/status.md index 6667db98c0..9566981343 100644 --- a/components/tag/demo/status.md +++ b/components/tag/demo/status.md @@ -15,15 +15,48 @@ We preset five different colors, you can set color property such as `success`,`p ```jsx import { Tag } from 'antd'; +import { + CheckCircleOutlined, + SyncOutlined, + CloseCircleOutlined, + ExclamationCircleOutlined, + ClockCircleOutlined, + MinusCircleOutlined, +} from '@ant-design/icons'; ReactDOM.render( -
- success - processing - error - default - warning -
, + <> +
+

Without icon

+ success + processing + error + warning + default +
+ +
+

With icon

+ } color="success"> + success + + } color="processing"> + processing + + } color="error"> + error + + } color="warning"> + warning + + } color="default"> + waiting + + } color="default"> + stop + +
+ , mountNode, ); ```