Debian Codegraph @

node/@patternfly/react-core/src/components/Tabs/TabContentBody.tsx

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