ant-design/components/layout/demo/flex-order.md

26 lines
420 B
Markdown
Raw Normal View History

2015-06-18 15:26:29 +08:00
# Flex排序
2015-06-09 22:19:35 +08:00
- order: 6
2015-06-09 22:19:35 +08:00
2015-06-15 17:46:42 +08:00
通过 Flex 布局的 Order 来改变元素的排序。
2015-06-09 22:19:35 +08:00
---
2015-10-27 23:52:17 +08:00
````jsx
import { Row, Col } from 'antd';
2015-10-27 23:52:17 +08:00
ReactDOM.render(
<div>
<Row type="flex">
2016-02-25 15:53:28 +08:00
<Col span={6} order={4}>1 col-order-4</Col>
<Col span={6} order={3}>2 col-order-3</Col>
<Col span={6} order={2}>3 col-order-2</Col>
<Col span={6} order={1}>4 col-order-1</Col>
2015-10-27 23:52:17 +08:00
</Row>
</div>,
mountNode
2015-10-27 23:52:17 +08:00
);
2015-06-09 22:19:35 +08:00
````