import React, { ReactNode } from 'react'; import { Box, as } from 'folds'; export type MediaControlProps = { before?: ReactNode; after?: ReactNode; leftControl?: ReactNode; rightControl?: ReactNode; }; export const MediaControl = as<'div', MediaControlProps>( ({ before, after, leftControl, rightControl, children, ...props }, ref) => ( {before && {before}} {leftControl} {rightControl} {after && {after}} {children} ) );