import React, { useState } from 'react'; import type { ConfigProviderProps, RadioChangeEvent } from 'antd'; import { Radio, Tabs } from 'antd'; type SizeType = ConfigProviderProps['componentSize']; const App: React.FC = () => { const [size, setSize] = useState('small'); const onChange = (e: RadioChangeEvent) => { setSize(e.target.value); }; return (
Small Middle Large { const id = String(i + 1); return { label: `Tab ${id}`, key: id, children: `Content of tab ${id}`, }; })} /> { const id = String(i + 1); return { label: `Card Tab ${id}`, key: id, children: `Content of card tab ${id}`, }; })} />
); }; export default App;