import React, { FunctionComponent, HTMLAttributes, ReactNode } from 'react'; import getClassName from '../../helpers/getClassName'; import classNames from '../../lib/classNames'; import usePlatform from '../../hooks/usePlatform'; export interface InfoRowProps extends HTMLAttributes { header: ReactNode; } const InfoRow: FunctionComponent = ({ header, className, children, ...restProps }: InfoRowProps) => { const platform = usePlatform(); const baseClassName = getClassName('InfoRow', platform); return (
{header &&
{header}
} {children}
); }; export default InfoRow;