import React from 'react' ; export interface GroupProps { x ? : number ; y ? : number ; children ? : React . ReactNode ; onMouseEnter ? : ( ) => void ; onMouseLeave ? : ( ) => void ; } export function Group ( props ) { const { x , y , children , ... restProps } = props ; const transform = `translate(${ x },${ y })` ; return ( < g transform = { transform } { ... restProps } > { children } < /g>); } Group . defaultProps = { x : 0 , y : 0 , } ;