import { getSystemStyle, SystemProps } from '../utils/systemProps';

interface BoxProps extends SystemProps {
  style?: React.CSSProperties;
  children?: React.ReactNode;
};

const Box: React.FC<BoxProps> = ({ style, children, ...props}) => {
  const systemStyle = getSystemStyle(props, style);

  return (
    <div style={systemStyle}>
      { children }
    </div>
  );
};

export default Box;
