mirror of
https://github.com/visgl/react-map-gl.git
synced 2026-01-25 16:02:50 +00:00
Update InteractiveMap prop types (#1324)
This commit is contained in:
parent
b7d641ba90
commit
deb4303fcb
12
src/components/interactive-map.d.ts
vendored
12
src/components/interactive-map.d.ts
vendored
@ -42,13 +42,13 @@ export type InteractiveMapProps = StaticMapProps & Partial<{
|
||||
onTransitionInterrupt: Function,
|
||||
onTransitionEnd: Function,
|
||||
|
||||
scrollZoom: boolean,
|
||||
dragPan: boolean,
|
||||
dragRotate: boolean,
|
||||
scrollZoom: boolean | {speed?: number, smooth?: boolean},
|
||||
dragPan: boolean | {inertia?: number},
|
||||
dragRotate: boolean | {inertia?: number},
|
||||
doubleClickZoom: boolean,
|
||||
touchZoom: boolean,
|
||||
touchRotate: boolean,
|
||||
keyboard: boolean,
|
||||
touchZoom: boolean | {inertia?: number},
|
||||
touchRotate: boolean | {inertia?: number},
|
||||
keyboard: boolean | {zoomSpeed?: number, moveSpeed?: number, rotateSpeedX?: number, rotateSpeedY?: number},
|
||||
touchAction: string,
|
||||
eventRecognizerOptions: any,
|
||||
clickRadius: number,
|
||||
|
||||
@ -48,19 +48,19 @@ const propTypes = Object.assign({}, StaticMap.propTypes, {
|
||||
|
||||
/** Enables control event handling */
|
||||
// Scroll to zoom
|
||||
scrollZoom: PropTypes.bool,
|
||||
scrollZoom: PropTypes.oneOfType([PropTypes.bool, PropTypes.object]),
|
||||
// Drag to pan
|
||||
dragPan: PropTypes.bool,
|
||||
dragPan: PropTypes.oneOfType([PropTypes.bool, PropTypes.object]),
|
||||
// Drag to rotate
|
||||
dragRotate: PropTypes.bool,
|
||||
dragRotate: PropTypes.oneOfType([PropTypes.bool, PropTypes.object]),
|
||||
// Double click to zoom
|
||||
doubleClickZoom: PropTypes.bool,
|
||||
// Multitouch zoom
|
||||
touchZoom: PropTypes.bool,
|
||||
touchZoom: PropTypes.oneOfType([PropTypes.bool, PropTypes.object]),
|
||||
// Multitouch rotate
|
||||
touchRotate: PropTypes.bool,
|
||||
touchRotate: PropTypes.oneOfType([PropTypes.bool, PropTypes.object]),
|
||||
// Keyboard
|
||||
keyboard: PropTypes.bool,
|
||||
keyboard: PropTypes.oneOfType([PropTypes.bool, PropTypes.object]),
|
||||
|
||||
/** Event callbacks */
|
||||
onHover: PropTypes.func,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user