组件演示[{"title":"标准型","id":"components-tabs-demo-open","tags":[],"filepath":"site/components/tabs/demo/open.md","directory":"components/tabs/demo","filename":"open","meta":{"title":"标准型","description":"\n<p>开放型样式</p>\n","order":"0","filepath":"site/components/tabs/demo/open.md","filename":"open","directory":"components/tabs/demo","id":"components-tabs-demo-open","template":"demos","html":"<script>(function(){\"use strict\";\n\nvar _uxcore = require(\"uxcore\");\n\nvar TabPane = _uxcore.Tabs.TabPane;\n\nReactDOM.render(React.createElement(\n _uxcore.Tabs,\n { defaultActiveKey: \"2\", type: \"open\" },\n React.createElement(\n TabPane,\n { tab: \"tab 1\", key: \"1\" },\n \"\\u9009\\u9879\\u5361\\u4E00\"\n ),\n React.createElement(\n TabPane,\n { tab: \"tab 2\", key: \"2\" },\n \"\\u9009\\u9879\\u5361\\u4E8C\"\n ),\n React.createElement(\n TabPane,\n { tab: \"tab 3\", key: \"3\" },\n \"\\u9009\\u9879\\u5361\\u4E09\"\n )\n), document.getElementById('components-tabs-demo-open'));})()</script><div class=\"highlight\"><pre><code class=\"javascript\"><span class=\"hljs-keyword\">import</span> { Tabs } <span class=\"hljs-keyword\">from</span> <span class=\"hljs-string\">'uxcore'</span>;\n<span class=\"hljs-keyword\">const</span> TabPane = Tabs.TabPane;\n\nReactDOM.render(\n <span class=\"xml\"><span class=\"hljs-tag\"><<span class=\"hljs-title\">Tabs</span> <span class=\"hljs-attribute\">defaultActiveKey</span>=<span class=\"hljs-value\">\"2\"</span> <span class=\"hljs-attribute\">type</span>=<span class=\"hljs-value\">\"open\"</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 1\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"1\"</span>></span>选项卡一<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 2\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"2\"</span>></span>选项卡二<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 3\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"3\"</span>></span>选项卡三<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"></<span class=\"hljs-title\">Tabs</span>></span>\n, document.getElementById('components-tabs-demo-open'));</span></code></pre></div>"},"status":"public","toc":""},{"title":"卡片式","id":"components-tabs-demo-basic","tags":[],"filepath":"site/components/tabs/demo/basic.md","directory":"components/tabs/demo","filename":"basic","meta":{"title":"卡片式","description":"\n","order":"1","filepath":"site/components/tabs/demo/basic.md","filename":"basic","directory":"components/tabs/demo","id":"components-tabs-demo-basic","template":"demos","html":"<script>(function(){\"use strict\";\n\nvar _uxcore = require(\"uxcore\");\n\nvar TabPane = _uxcore.Tabs.TabPane;\n\nReactDOM.render(React.createElement(\n _uxcore.Tabs,\n { defaultActiveKey: \"2\" },\n React.createElement(\n TabPane,\n { tab: \"tab 1\", key: \"1\" },\n \"\\u9009\\u9879\\u5361\\u4E00\"\n ),\n React.createElement(\n TabPane,\n { tab: \"tab 2\", key: \"2\" },\n \"\\u9009\\u9879\\u5361\\u4E8C\"\n ),\n React.createElement(\n TabPane,\n { tab: \"tab 3\", key: \"3\" },\n \"\\u9009\\u9879\\u5361\\u4E09\"\n )\n), document.getElementById('components-tabs-demo-basic'));})()</script><div class=\"highlight\"><pre><code class=\"javascript\"><span class=\"hljs-keyword\">import</span> { Tabs } <span class=\"hljs-keyword\">from</span> <span class=\"hljs-string\">'uxcore'</span>;\n<span class=\"hljs-keyword\">const</span> TabPane = Tabs.TabPane;\n\nReactDOM.render(\n <span class=\"xml\"><span class=\"hljs-tag\"><<span class=\"hljs-title\">Tabs</span> <span class=\"hljs-attribute\">defaultActiveKey</span>=<span class=\"hljs-value\">\"2\"</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 1\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"1\"</span>></span>选项卡一<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 2\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"2\"</span>></span>选项卡二<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 3\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"3\"</span>></span>选项卡三<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"></<span class=\"hljs-title\">Tabs</span>></span>\n, document.getElementById('components-tabs-demo-basic'));</span></code></pre></div>"},"status":"public","toc":""},{"title":"小尺寸","id":"components-tabs-demo-small","tags":[],"filepath":"site/components/tabs/demo/small.md","directory":"components/tabs/demo","filename":"small","meta":{"title":"小尺寸","description":"\n<p>小(局部)tab</p>\n","order":"2","filepath":"site/components/tabs/demo/small.md","filename":"small","directory":"components/tabs/demo","id":"components-tabs-demo-small","template":"demos","html":"<script>(function(){\"use strict\";\n\nvar _uxcore = require(\"uxcore\");\n\nvar TabPane = _uxcore.Tabs.TabPane;\n\nReactDOM.render(React.createElement(\n _uxcore.Tabs,\n { defaultActiveKey: \"2\", type: \"small\" },\n React.createElement(\n TabPane,\n { tab: \"tab 1\", key: \"1\" },\n \"\\u9009\\u9879\\u5361\\u4E00\"\n ),\n React.createElement(\n TabPane,\n { tab: \"tab 2\", key: \"2\" },\n \"\\u9009\\u9879\\u5361\\u4E8C\"\n ),\n React.createElement(\n TabPane,\n { tab: \"tab 3\", key: \"3\" },\n \"\\u9009\\u9879\\u5361\\u4E09\"\n )\n), document.getElementById('components-tabs-demo-small'));})()</script><div class=\"highlight\"><pre><code class=\"javascript\"><span class=\"hljs-keyword\">import</span> { Tabs } <span class=\"hljs-keyword\">from</span> <span class=\"hljs-string\">'uxcore'</span>;\n<span class=\"hljs-keyword\">const</span> TabPane = Tabs.TabPane;\n\nReactDOM.render(\n <span class=\"xml\"><span class=\"hljs-tag\"><<span class=\"hljs-title\">Tabs</span> <span class=\"hljs-attribute\">defaultActiveKey</span>=<span class=\"hljs-value\">\"2\"</span> <span class=\"hljs-attribute\">type</span>=<span class=\"hljs-value\">\"small\"</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 1\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"1\"</span>></span>选项卡一<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 2\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"2\"</span>></span>选项卡二<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 3\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"3\"</span>></span>选项卡三<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"></<span class=\"hljs-title\">Tabs</span>></span>\n, document.getElementById('components-tabs-demo-small'));</span></code></pre></div>"},"status":"public","toc":""},{"title":"胶囊型","id":"components-tabs-demo-brick","tags":[],"filepath":"site/components/tabs/demo/brick.md","directory":"components/tabs/demo","filename":"brick","meta":{"title":"胶囊型","description":"\n<p>BRICK</p>\n","order":"4","filepath":"site/components/tabs/demo/brick.md","filename":"brick","directory":"components/tabs/demo","id":"components-tabs-demo-brick","template":"demos","html":"<script>(function(){\"use strict\";\n\nvar _uxcore = require(\"uxcore\");\n\nvar TabPane = _uxcore.Tabs.TabPane;\n\nReactDOM.render(React.createElement(\n _uxcore.Tabs,\n { defaultActiveKey: \"2\", type: \"brick\" },\n React.createElement(\n TabPane,\n { tab: \"tab 1\", key: \"1\" },\n \"\\u9009\\u9879\\u5361\\u4E00\"\n ),\n React.createElement(\n TabPane,\n { tab: \"tab 2\", key: \"2\" },\n \"\\u9009\\u9879\\u5361\\u4E8C\"\n ),\n React.createElement(\n TabPane,\n { tab: \"tab 3\", key: \"3\" },\n \"\\u9009\\u9879\\u5361\\u4E09\"\n )\n), document.getElementById('components-tabs-demo-brick'));})()</script><div class=\"highlight\"><pre><code class=\"javascript\"><span class=\"hljs-keyword\">import</span> { Tabs } <span class=\"hljs-keyword\">from</span> <span class=\"hljs-string\">'uxcore'</span>;\n<span class=\"hljs-keyword\">const</span> TabPane = Tabs.TabPane;\n\nReactDOM.render(\n <span class=\"xml\"><span class=\"hljs-tag\"><<span class=\"hljs-title\">Tabs</span> <span class=\"hljs-attribute\">defaultActiveKey</span>=<span class=\"hljs-value\">\"2\"</span> <span class=\"hljs-attribute\">type</span>=<span class=\"hljs-value\">\"brick\"</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 1\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"1\"</span>></span>选项卡一<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 2\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"2\"</span>></span>选项卡二<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 3\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"3\"</span>></span>选项卡三<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"></<span class=\"hljs-title\">Tabs</span>></span>\n, document.getElementById('components-tabs-demo-brick'));</span></code></pre></div>"},"status":"public","toc":""},{"title":"禁用","id":"components-tabs-demo-disabled","tags":[],"filepath":"site/components/tabs/demo/disabled.md","directory":"components/tabs/demo","filename":"disabled","meta":{"title":"禁用","description":"\n<p>禁用某一项。</p>\n","order":"5","filepath":"site/components/tabs/demo/disabled.md","filename":"disabled","directory":"components/tabs/demo","id":"components-tabs-demo-disabled","template":"demos","html":"<script>(function(){\"use strict\";\n\nvar _uxcore = require(\"uxcore\");\n\nvar TabPane = _uxcore.Tabs.TabPane;\n\nfunction callback(key) {}\n\nReactDOM.render(React.createElement(\n _uxcore.Tabs,\n { defaultActiveKey: \"1\", onChange: callback },\n React.createElement(\n TabPane,\n { tab: \"tab 1\", key: \"1\" },\n \"\\u9009\\u9879\\u5361\\u4E00\"\n ),\n React.createElement(\n TabPane,\n { tab: \"tab 2\", disabled: true, key: \"2\" },\n \"\\u9009\\u9879\\u5361\\u4E8C\"\n ),\n React.createElement(\n TabPane,\n { tab: \"tab 3\", key: \"3\" },\n \"\\u9009\\u9879\\u5361\\u4E09\"\n )\n), document.getElementById('components-tabs-demo-disabled'));})()</script><div class=\"highlight\"><pre><code class=\"javascript\"><span class=\"hljs-keyword\">import</span> { Tabs } <span class=\"hljs-keyword\">from</span> <span class=\"hljs-string\">'uxcore'</span>;\n<span class=\"hljs-keyword\">const</span> TabPane = Tabs.TabPane;\n\n<span class=\"hljs-function\"><span class=\"hljs-keyword\">function</span> <span class=\"hljs-title\">callback</span>(<span class=\"hljs-params\">key</span>) </span>{}\n\nReactDOM.render(\n <span class=\"xml\"><span class=\"hljs-tag\"><<span class=\"hljs-title\">Tabs</span> <span class=\"hljs-attribute\">defaultActiveKey</span>=<span class=\"hljs-value\">\"1\"</span> <span class=\"hljs-attribute\">onChange</span>=<span class=\"hljs-value\">{callback}</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 1\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"1\"</span>></span>选项卡一<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 2\"</span> <span class=\"hljs-attribute\">disabled</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"2\"</span>></span>选项卡二<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 3\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"3\"</span>></span>选项卡三<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"></<span class=\"hljs-title\">Tabs</span>></span>\n, document.getElementById('components-tabs-demo-disabled'));</span></code></pre></div>"},"status":"public","toc":""},{"title":"溢出","id":"components-tabs-demo-overflow","tags":[],"filepath":"site/components/tabs/demo/overflow.md","directory":"components/tabs/demo","filename":"overflow","meta":{"title":"溢出","description":"\n<p>开放型样式</p>\n","order":"6","filepath":"site/components/tabs/demo/overflow.md","filename":"overflow","directory":"components/tabs/demo","id":"components-tabs-demo-overflow","template":"demos","html":"<script>(function(){'use strict';\n\nvar _uxcore = require('uxcore');\n\nvar TabPane = _uxcore.Tabs.TabPane;\n\nReactDOM.render(React.createElement(\n 'div',\n { style: { width: '600px' } },\n React.createElement(\n _uxcore.Tabs,\n { defaultActiveKey: '2', type: 'open' },\n React.createElement(\n TabPane,\n { tab: 'tab 1', key: '1' },\n '\\u9009\\u9879\\u5361\\u4E00'\n ),\n React.createElement(\n TabPane,\n { tab: 'tab 2', key: '2' },\n '\\u9009\\u9879\\u5361\\u4E8C'\n ),\n React.createElement(\n TabPane,\n { tab: 'tab 3', key: '3' },\n '\\u9009\\u9879\\u5361\\u4E09'\n ),\n React.createElement(\n TabPane,\n { tab: 'tab 4', key: '4' },\n '\\u9009\\u9879\\u5361\\u56DB'\n ),\n React.createElement(\n TabPane,\n { tab: 'tab 5', key: '5' },\n '\\u9009\\u9879\\u5361\\u4E94'\n ),\n React.createElement(\n TabPane,\n { tab: 'tab 6', key: '6' },\n '\\u9009\\u9879\\u5361\\u516D'\n ),\n React.createElement(\n TabPane,\n { tab: 'tab 7', key: '7' },\n '\\u9009\\u9879\\u5361\\u4E03'\n ),\n React.createElement(\n TabPane,\n { tab: 'tab 8', key: '8' },\n '\\u9009\\u9879\\u5361\\u516B'\n ),\n React.createElement(\n TabPane,\n { tab: 'tab 9', key: '9' },\n '\\u9009\\u9879\\u5361\\u4E5D'\n ),\n React.createElement(\n TabPane,\n { tab: 'tab 10', key: '10' },\n '\\u9009\\u9879\\u5361\\u5341'\n ),\n React.createElement(\n TabPane,\n { tab: 'tab 11', key: '11' },\n '\\u9009\\u9879\\u5361\\u5341\\u4E00'\n ),\n React.createElement(\n TabPane,\n { tab: 'tab 12', key: '12' },\n '\\u9009\\u9879\\u5361\\u5341\\u4E8C'\n )\n )\n), document.getElementById('components-tabs-demo-overflow'));})()</script><div class=\"highlight\"><pre><code class=\"javascript\"><span class=\"hljs-keyword\">import</span> { Tabs } <span class=\"hljs-keyword\">from</span> <span class=\"hljs-string\">'uxcore'</span>;\n<span class=\"hljs-keyword\">const</span> TabPane = Tabs.TabPane;\n\nReactDOM.render(\n <span class=\"xml\"><span class=\"hljs-tag\"><<span class=\"hljs-title\">div</span> <span class=\"hljs-attribute\">style</span>=<span class=\"hljs-value\">{{</span> <span class=\"hljs-attribute\">width:</span> '<span class=\"hljs-attribute\">600px</span>' }}></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">Tabs</span> <span class=\"hljs-attribute\">defaultActiveKey</span>=<span class=\"hljs-value\">\"2\"</span> <span class=\"hljs-attribute\">type</span>=<span class=\"hljs-value\">\"open\"</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 1\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"1\"</span>></span>选项卡一<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 2\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"2\"</span>></span>选项卡二<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 3\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"3\"</span>></span>选项卡三<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 4\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"4\"</span>></span>选项卡四<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 5\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"5\"</span>></span>选项卡五<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 6\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"6\"</span>></span>选项卡六<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 7\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"7\"</span>></span>选项卡七<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 8\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"8\"</span>></span>选项卡八<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 9\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"9\"</span>></span>选项卡九<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 10\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"10\"</span>></span>选项卡十<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 11\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"11\"</span>></span>选项卡十一<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"><<span class=\"hljs-title\">TabPane</span> <span class=\"hljs-attribute\">tab</span>=<span class=\"hljs-value\">\"tab 12\"</span> <span class=\"hljs-attribute\">key</span>=<span class=\"hljs-value\">\"12\"</span>></span>选项卡十二<span class=\"hljs-tag\"></<span class=\"hljs-title\">TabPane</span>></span>\n <span class=\"hljs-tag\"></<span class=\"hljs-title\">Tabs</span>></span>\n <span class=\"hljs-tag\"></<span class=\"hljs-title\">div</span>></span>\n, document.getElementById('components-tabs-demo-overflow'));</span></code></pre></div>"},"status":"public","toc":""}]标准型 开放型样式 import { Tabs } from 'uxcore'; const TabPane = Tabs.TabPane; ReactDOM.render( <Tabs defaultActiveKey="2" type="open"> <TabPane tab="tab 1" key="1">选项卡一</TabPane> <TabPane tab="tab 2" key="2">选项卡二</TabPane> <TabPane tab="tab 3" key="3">选项卡三</TabPane> </Tabs> , document.getElementById('components-tabs-demo-open'));卡片式 import { Tabs } from 'uxcore'; const TabPane = Tabs.TabPane; ReactDOM.render( <Tabs defaultActiveKey="2"> <TabPane tab="tab 1" key="1">选项卡一</TabPane> <TabPane tab="tab 2" key="2">选项卡二</TabPane> <TabPane tab="tab 3" key="3">选项卡三</TabPane> </Tabs> , document.getElementById('components-tabs-demo-basic'));小尺寸 小(局部)tab import { Tabs } from 'uxcore'; const TabPane = Tabs.TabPane; ReactDOM.render( <Tabs defaultActiveKey="2" type="small"> <TabPane tab="tab 1" key="1">选项卡一</TabPane> <TabPane tab="tab 2" key="2">选项卡二</TabPane> <TabPane tab="tab 3" key="3">选项卡三</TabPane> </Tabs> , document.getElementById('components-tabs-demo-small'));胶囊型 BRICK import { Tabs } from 'uxcore'; const TabPane = Tabs.TabPane; ReactDOM.render( <Tabs defaultActiveKey="2" type="brick"> <TabPane tab="tab 1" key="1">选项卡一</TabPane> <TabPane tab="tab 2" key="2">选项卡二</TabPane> <TabPane tab="tab 3" key="3">选项卡三</TabPane> </Tabs> , document.getElementById('components-tabs-demo-brick'));禁用 禁用某一项。 import { Tabs } from 'uxcore'; const TabPane = Tabs.TabPane; function callback(key) {} ReactDOM.render( <Tabs defaultActiveKey="1" onChange={callback}> <TabPane tab="tab 1" key="1">选项卡一</TabPane> <TabPane tab="tab 2" disabled key="2">选项卡二</TabPane> <TabPane tab="tab 3" key="3">选项卡三</TabPane> </Tabs> , document.getElementById('components-tabs-demo-disabled'));溢出 开放型样式 import { Tabs } from 'uxcore'; const TabPane = Tabs.TabPane; ReactDOM.render( <div style={{ width: '600px' }}> <Tabs defaultActiveKey="2" type="open"> <TabPane tab="tab 1" key="1">选项卡一</TabPane> <TabPane tab="tab 2" key="2">选项卡二</TabPane> <TabPane tab="tab 3" key="3">选项卡三</TabPane> <TabPane tab="tab 4" key="4">选项卡四</TabPane> <TabPane tab="tab 5" key="5">选项卡五</TabPane> <TabPane tab="tab 6" key="6">选项卡六</TabPane> <TabPane tab="tab 7" key="7">选项卡七</TabPane> <TabPane tab="tab 8" key="8">选项卡八</TabPane> <TabPane tab="tab 9" key="9">选项卡九</TabPane> <TabPane tab="tab 10" key="10">选项卡十</TabPane> <TabPane tab="tab 11" key="11">选项卡十一</TabPane> <TabPane tab="tab 12" key="12">选项卡十二</TabPane> </Tabs> </div> , document.getElementById('components-tabs-demo-overflow'));const Tabs = require('uxcore-tabs'); const TabPane = Tabs.TabPane; const callback = function (key) { }; ReactDOM.render( ( <Tabs defaultActiveKey="2" onChange={callback}> <TabPane tab="tab 1" key="1">first</TabPane> <TabPane tab="tab 2" key="2">second</TabPane> <TabPane tab="tab 3" key="3">third</TabPane> </Tabs> ), document.getElementById('t2'));APITabs name type default description activeKey String current active tabPanel's key defaultActiveKey String first active tabPanel's key initial active tabPanel's key if activeKey is absent onChange Function (key) called when tabPanel is changed onTabClick Function (key) called when tab is clicked destroyInactiveTabPane Boolean false whether destroy inactive tabpane when change tab type string large large small filter brick TabPane name type default description key Object corresponding to activeKey tab String current tab's title corresponding to current tabPane