Skip to content

Updated peer dependencies to support React 17 #516

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 21 commits into from
Mar 2, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,3 @@ npm-debug.log
node_modules
.env
public/
dist
37 changes: 30 additions & 7 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ export interface IProvidedProps {
loaded?: boolean
}

type mapEventHandler = (mapProps?: IMapProps, map?: google.maps.Map, event?) => any
type mapEventHandler = (mapProps?: IMapProps, map?: google.maps.Map, event?: any) => any

type Style = Object<string, string | number | boolean>
type Style = Object

export interface IMapProps extends google.maps.MapOptions {
google: GoogleAPI
Expand All @@ -39,6 +39,15 @@ export interface IMapProps extends google.maps.MapOptions {
centerAroundCurrentLocation?: boolean
initialCenter?: google.maps.LatLngLiteral
center?: google.maps.LatLngLiteral
zoom?: number

zoomControl?: boolean
mapTypeControl?: boolean
scaleControl?: boolean
streetViewControl?: boolean
panControl?: boolean
rotateControl?: boolean
fullscreenControl?: boolean

visible?: boolean

Expand All @@ -64,13 +73,23 @@ export interface IMapProps extends google.maps.MapOptions {
onZoomChanged?: mapEventHandler
}

type markerEventHandler = (props?: IMarkerProps, marker?: google.maps.Marker, event?) => any
type markerEventHandler = (props?: IMarkerProps, marker?: google.maps.Marker, event?: any) => any

export interface IMarkerProps extends Partial<google.maps.MarkerOptions> {
mapCenter?: google.maps.LatLng | google.maps.LatLngLiteral
position?: google.maps.LatLngLiteral
label?: string
title?: string
name?: string

onClick?: markerEventHandler
onDblclick?: markerEventHandler
onDragend?: markerEventHandler
onMousedown?: markerEventHandler
onMouseout?: markerEventHandler
onMouseover?: markerEventHandler
onMouseup?: markerEventHandler
onRecenter?: markerEventHandler
}

export class Map extends React.Component<IMapProps, any> {
Expand All @@ -94,13 +113,17 @@ export class Circle extends React.Component<any, any> {
}

export interface IInfoWindowProps extends Partial<google.maps.InfoWindowOptions> {
google: typeof google
map: google.maps.Map
marker: google.maps.Marker
google?: typeof google
map?: google.maps.Map
marker?: google.maps.Marker

mapCenter?: google.maps.LatLng | google.maps.LatLngLiteral
position?: google.maps.LatLng | google.maps.LatLngLiteral
visible?: boolean

children: React.ReactNode
onClose?(): void
onOpen?(): void

}

export class InfoWindow extends React.Component<IInfoWindowProps, any> {
Expand Down
Loading
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy