mirror of
https://github.com/ant-design/ant-design.git
synced 2024-12-02 07:39:36 +08:00
6776bb8916
* docs: update demo * chore: add script * test: fix demo test * docs: convert demos * chore: move script * test: remove react-dom import * chore: update deps * docs: update riddle js * test: fix image test * docs: fix riddle demo
31 lines
750 B
Markdown
31 lines
750 B
Markdown
---
|
|
order: 2
|
|
title:
|
|
zh-CN: 带图标的步骤条
|
|
en-US: With icon
|
|
---
|
|
|
|
## zh-CN
|
|
|
|
通过设置 `Steps.Step` 的 `icon` 属性,可以启用自定义图标。
|
|
|
|
## en-US
|
|
|
|
You can use your own custom icons by setting the property `icon` for `Steps.Step`.
|
|
|
|
```jsx
|
|
import { Steps } from 'antd';
|
|
import { UserOutlined, SolutionOutlined, LoadingOutlined, SmileOutlined } from '@ant-design/icons';
|
|
|
|
const { Step } = Steps;
|
|
|
|
export default () => (
|
|
<Steps>
|
|
<Step status="finish" title="Login" icon={<UserOutlined />} />
|
|
<Step status="finish" title="Verification" icon={<SolutionOutlined />} />
|
|
<Step status="process" title="Pay" icon={<LoadingOutlined />} />
|
|
<Step status="wait" title="Done" icon={<SmileOutlined />} />
|
|
</Steps>
|
|
);
|
|
```
|