mirror of
https://github.com/ant-design/ant-design.git
synced 2024-12-15 00:29:12 +08:00
fc24f382fc
* style: remove fixed height in badge.ribbon * docs: update demo * test: update snapshot
55 lines
1.6 KiB
TypeScript
55 lines
1.6 KiB
TypeScript
import React from 'react';
|
|
import { Badge, Card, Space } from 'antd';
|
|
|
|
const App: React.FC = () => (
|
|
<Space direction="vertical" size="middle" style={{ width: '100%' }}>
|
|
<Badge.Ribbon text="Hippies">
|
|
<Card title="Pushes open the window" size="small">
|
|
and raises the spyglass.
|
|
</Card>
|
|
</Badge.Ribbon>
|
|
<Badge.Ribbon text={
|
|
<div>
|
|
Hippies <br />
|
|
Happy
|
|
</div>
|
|
} color="pink">
|
|
<Card title="Pushes open the window" size="small">
|
|
and raises the spyglass.
|
|
</Card>
|
|
</Badge.Ribbon>
|
|
<Badge.Ribbon text="Hippies" color="red">
|
|
<Card title="Pushes open the window" size="small">
|
|
and raises the spyglass.
|
|
</Card>
|
|
</Badge.Ribbon>
|
|
<Badge.Ribbon text="Hippies" color="cyan">
|
|
<Card title="Pushes open the window" size="small">
|
|
and raises the spyglass.
|
|
</Card>
|
|
</Badge.Ribbon>
|
|
<Badge.Ribbon text="Hippies" color="green">
|
|
<Card title="Pushes open the window" size="small">
|
|
and raises the spyglass.
|
|
</Card>
|
|
</Badge.Ribbon>
|
|
<Badge.Ribbon text="Hippies" color="purple">
|
|
<Card title="Pushes open the window" size="small">
|
|
and raises the spyglass.
|
|
</Card>
|
|
</Badge.Ribbon>
|
|
<Badge.Ribbon text="Hippies" color="volcano">
|
|
<Card title="Pushes open the window" size="small">
|
|
and raises the spyglass.
|
|
</Card>
|
|
</Badge.Ribbon>
|
|
<Badge.Ribbon text="Hippies" color="magenta">
|
|
<Card title="Pushes open the window" size="small">
|
|
and raises the spyglass.
|
|
</Card>
|
|
</Badge.Ribbon>
|
|
</Space>
|
|
);
|
|
|
|
export default App;
|