mirror of
https://github.com/ant-design/ant-design.git
synced 2024-12-16 01:29:11 +08:00
55 lines
943 B
Markdown
55 lines
943 B
Markdown
---
|
|
order: 4
|
|
title:
|
|
zh-CN: 栅格卡片
|
|
en-US: Card in column
|
|
---
|
|
|
|
## zh-CN
|
|
|
|
在系统概览页面常常和栅格进行配合。
|
|
|
|
## en-US
|
|
|
|
Cards usually cooperate with grid column layout in overview page.
|
|
|
|
```tsx
|
|
import { Card, Col, Row } from 'antd';
|
|
import React from 'react';
|
|
|
|
const App: React.FC = () => (
|
|
<div className="site-card-wrapper">
|
|
<Row gutter={16}>
|
|
<Col span={8}>
|
|
<Card title="Card title" bordered={false}>
|
|
Card content
|
|
</Card>
|
|
</Col>
|
|
<Col span={8}>
|
|
<Card title="Card title" bordered={false}>
|
|
Card content
|
|
</Card>
|
|
</Col>
|
|
<Col span={8}>
|
|
<Card title="Card title" bordered={false}>
|
|
Card content
|
|
</Card>
|
|
</Col>
|
|
</Row>
|
|
</div>
|
|
);
|
|
|
|
export default App;
|
|
```
|
|
|
|
<style>
|
|
.site-card-wrapper {
|
|
padding: 30px;
|
|
background: #ececec;
|
|
}
|
|
|
|
[data-theme="dark"] .site-card-wrapper {
|
|
background: #303030;
|
|
}
|
|
</style>
|