import { useState } from 'react' import { Text, Tabs } from '../../src' import { Demo } from '../components/Demo' import { PropsTable } from '../components/PropsTable' import { Section } from '../components/Section' const ITEMS = [ { key: 'detail', label: '详情' }, { key: 'comments', label: '评论 6' }, { key: 'history', label: '历史(暂不可用)', disabled: true }, ] export function TabsSection() { const [tab, setTab] = useState('detail') const [pillTab, setPillTab] = useState('all') return (
{tab} 面板
`} > 当前面板:{tab}
`} > void', required: true, desc: '切换回调' }, { name: 'variant', type: "'line' | 'pill'", defaultValue: "'line'", desc: '下划线 / 胶囊' }, ]} />
) }