import { FunctionComponent } from 'react' interface TabsProps { activeTab: string onChange: (x) => void showCount?: Array tabs: Array } interface ShowCount { tabName: string count: number } const Tabs: FunctionComponent = ({ activeTab, onChange, showCount, tabs, }) => { return (
v === activeTab) * 100 }%)`, width: `${100 / tabs.length}%`, }} />
) } export default Tabs const Count = ({ count }) => ( {count} )