Debian Codegraph @

node/@patternfly/react-core/src/components/Drawer/DrawerPanelBody.tsx

raw
1 import styles from '@patternfly/react-styles/css/components/Drawer/drawer';
2 import { css } from '@patternfly/react-styles';
3
4 export interface DrawerPanelBodyProps extends React.HTMLProps<HTMLDivElement> {
5 /** Additional classes added to the Drawer. */
6 className?: string;
7 /** Content to be rendered in the drawer */
8 children?: React.ReactNode;
9 /** Indicates if there should be no padding around the drawer panel body */
10 hasNoPadding?: boolean;
11 }
12
13 export const DrawerPanelBody: React.FunctionComponent<DrawerPanelBodyProps> = ({
14 className = '',
15 children,
16 hasNoPadding = false,
17 ...props
18 }: DrawerPanelBodyProps) => (
19 <div className={css(styles.drawerBody, hasNoPadding && styles.modifiers.noPadding, className)} {...props}>
20 {children}
21 </div>
22 );
23 DrawerPanelBody.displayName = 'DrawerPanelBody';