You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

44 lines
859 B

---
order: 0
title:
zh-CN: 典型卡片
en-US: Basic card
---
9 years ago
## zh-CN
9 years ago
包含标题、内容、操作区域。
## en-US
A basic card containing a title, content and an extra corner content. Supports two sizes: `default` and `small`.
```tsx
9 years ago
import { Card } from 'antd';
import React from 'react';
9 years ago
const App: React.FC = () => (
<>
<Card title="Default size card" extra={<a href="#">More</a>} style={{ width: 300 }}>
<p>Card content</p>
<p>Card content</p>
<p>Card content</p>
</Card>
<Card size="small" title="Small size card" extra={<a href="#">More</a>} style={{ width: 300 }}>
<p>Card content</p>
<p>Card content</p>
<p>Card content</p>
</Card>
</>
);
export default App;
```
<style>
.code-box-demo p {
margin: 0;
}
#components-card-demo-basic .ant-card { margin-bottom: 30px; }
</style>