# Drawer
<flow-drawer>
The drawer component a dismissable sidebar to contain navigation or informational UI.
The drawer comprises a main body, which may be scrollable if the content exceeds the height of the drawer. A fixed header and/or footer may also be included. By design, the drawer does not pad content. If required, content may be wrapped in a container element to add padding.
Drawers can be positioned on the left and/or right side of the UI. They can be opened and closed programmatically or by clicking on the side tab (if enabled).
Content can also be placed into the header
and footer
slots to add a fixed header and/or footer. The main body of the drawer will be sized to accommodate the header and footer.
WARNING
When a drawer is placed in a container rather than directly in the document body, the container should have relative positioning with overflow hidden.
# Examples
# Drawer Positioning
Set the position
attribute to specify which side of the UI to attach the drawer. In standard LTR mode, start
corresponds to the left side and end
corresponds to the right side of the UI.
# Drawer Headers and Footers
Place content into the header
and/or footer
slot to add headers and footers. The content may be a single HTML element or a complex container element with text, icons and controls.
# Drawer Styling
The drawer container element can be styled to remove the default box shadow or add custom borders. CSS Custom Properties can also be used to change the width of the drawer.