import React, { useState } from 'react'; import { Button, Radio, Slider, Space } from 'antd'; import type { SizeType } from 'antd/es/config-provider/SizeContext'; const App: React.FC = () => { const [size, setSize] = useState('small'); const [customSize, setCustomSize] = React.useState(0); return ( <> setSize(e.target.value)}> {['small', 'middle', 'large', 'customize'].map((item) => ( {item} ))}

{size === 'customize' && ( <>
)} ); }; export default App;