import { ComponentPropsWithRef, ReactNode, ComponentType, memo, forwardRef } from 'react'; import { type ViewStyle, type StyleProp, type ViewProps, View } from 'react-native'; import { dialogContentStyles } from './utils'; export type Props = ViewProps & ComponentPropsWithRef> & { /** * ContainerComponent prop allows to replace the default container used in DrawerContent - ScrollView * */ ContainerComponent?: ComponentType; /** * Content of the `DialogContent`. */ children: ReactNode; style?: StyleProp; }; const DialogContent = ({ ContainerComponent, children, style, ...rest }: Props, ref: any) => { const Container = ContainerComponent || View; return ( {children} ); }; DialogContent.displayName = 'Dialog_Content'; export default memo(forwardRef(DialogContent));