import { InfoWindow as GoogleMapsInfoWindow, type InfoWindowProps as GoogleMapsInfoWindowProps, } from "@vis.gl/react-google-maps" import styles from "./infoWindow.module.css" import type { MouseEventHandler } from "react" interface InfoWindowProps extends React.PropsWithChildren< Omit > { pixelOffsetY?: number onMouseEnter?: MouseEventHandler onMouseLeave?: MouseEventHandler } export function InfoWindow({ children, pixelOffsetY = -12, onMouseEnter, onMouseLeave, ...options }: InfoWindowProps) { function onMouseEnterHandler(e: React.MouseEvent) { if (onMouseEnter) { onMouseEnter(e) } } function onMouseLeaveHandler(e: React.MouseEvent) { if (onMouseLeave) { onMouseLeave(e) } } return (
{children}
) }