2015-06-15 16:11:28 +08:00
|
|
|
# 图标
|
|
|
|
|
|
|
|
- order: 2
|
|
|
|
|
2015-06-17 20:28:02 +08:00
|
|
|
有图标的标签。
|
2015-06-15 16:11:28 +08:00
|
|
|
|
|
|
|
---
|
|
|
|
|
|
|
|
````jsx
|
2015-06-15 19:56:58 +08:00
|
|
|
var Tabs = antd.Tabs;
|
|
|
|
var TabPane = Tabs.TabPane;
|
2015-06-15 16:11:28 +08:00
|
|
|
|
|
|
|
var tabContent = [
|
2015-08-06 16:47:01 +08:00
|
|
|
<span><i className="anticon anticon-apple"></i>选项卡一</span>,
|
|
|
|
<span><i className="anticon anticon-android"></i>选项卡二</span>,
|
|
|
|
<span><i className="anticon anticon-lock"></i>选项卡三</span>,
|
2015-06-19 15:45:40 +08:00
|
|
|
];
|
2015-06-15 16:11:28 +08:00
|
|
|
|
|
|
|
React.render(
|
2015-08-06 16:47:01 +08:00
|
|
|
<Tabs defaultActiveKey="2">
|
2015-06-15 16:11:28 +08:00
|
|
|
<TabPane tab={tabContent[0]} key="1">选项卡一</TabPane>
|
2015-08-06 16:47:01 +08:00
|
|
|
<TabPane tab={tabContent[1]} key="2">选项卡二</TabPane>
|
|
|
|
<TabPane tab={tabContent[2]} key="3">选项卡三</TabPane>
|
2015-06-15 19:56:58 +08:00
|
|
|
</Tabs>
|
|
|
|
, document.getElementById('components-tabs-demo-icon'));
|
2015-06-15 16:11:28 +08:00
|
|
|
````
|