2016-03-31 09:40:55 +08:00
|
|
|
---
|
|
|
|
order: 0
|
2016-07-11 11:45:42 +08:00
|
|
|
title:
|
|
|
|
zh-CN: 独立使用
|
|
|
|
en-US: Standalone
|
2016-03-31 09:40:55 +08:00
|
|
|
---
|
2015-12-18 17:27:22 +08:00
|
|
|
|
2016-07-11 11:45:42 +08:00
|
|
|
## zh-CN
|
|
|
|
|
2015-12-18 17:27:22 +08:00
|
|
|
不包裹任何元素即是独立使用,可自定样式展现。
|
|
|
|
|
|
|
|
> 在右上角的 badge 则限定为红色。
|
|
|
|
|
2016-07-11 11:45:42 +08:00
|
|
|
## en-US
|
|
|
|
|
|
|
|
Used in standalone when children is empty.
|
|
|
|
|
2015-12-18 17:27:22 +08:00
|
|
|
````jsx
|
|
|
|
import { Badge } from 'antd';
|
|
|
|
|
|
|
|
ReactDOM.render(<div>
|
|
|
|
<Badge count={25} />
|
2016-01-27 16:44:50 +08:00
|
|
|
<Badge count={4} style={{ backgroundColor: '#fff', color: '#999', borderColor: '#d9d9d9' }} />
|
|
|
|
<Badge count={109} style={{ backgroundColor: '#87d068' }} />
|
2015-12-29 12:08:58 +08:00
|
|
|
</div>, mountNode);
|
2015-12-18 17:27:22 +08:00
|
|
|
````
|