mirror of
https://github.com/ant-design/ant-design.git
synced 2024-11-26 04:00:13 +08:00
658 B
658 B
图标
- order: 2
带有图标。
var Tab = antd.Tab;
var TabPane = Tab.TabPane;
function callback() {}
var tabContent = [
<span><i className="anticon anticon-lock"></i>tab 1</span>,
<span><i className="anticon anticon-lock"></i>tab 2</span>,
<span><i className="anticon anticon-lock"></i>tab 3</span>,
]
React.render(
<Tab defaultActiveKey="2" onChange={callback}>
<TabPane tab={tabContent[0]} key="1">选项卡一</TabPane>
<TabPane tab={tabContent[1]} key="2">选项卡一</TabPane>
<TabPane tab={tabContent[2]} key="3">选项卡一</TabPane>
</Tab>
, document.getElementById('components-tabs-demo-icon'));