--- order: 10 title: zh-CN: 预设宽度 en-US: Presetted size --- ## zh-CN 抽屉的默认宽度为 `378px`,另外还提供一个大号抽屉 `736px`,可以用 `size` 属性来设置。 ## en-US The default width (or height) of Drawer is `378px`, and there is a presetted large size `736px`. ```tsx import { Button, Drawer, Space } from 'antd'; import type { DrawerProps } from 'antd/es/drawer'; import React, { useState } from 'react'; const App: React.FC = () => { const [open, setOpen] = useState(false); const [size, setSize] = useState(); const showDefaultDrawer = () => { setSize('default'); setOpen(true); }; const showLargeDrawer = () => { setSize('large'); setOpen(true); }; const onClose = () => { setOpen(false); }; return ( <> } >

Some contents...

Some contents...

Some contents...

); }; export default App; ```