mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-20 12:46:36 +08:00
Add support for gestureHandling for Google Maps (#16287)
Add support for the gestureHandling property on the MapOptions interface.
This commit is contained in:
committed by
Mohamed Hegazy
parent
da8970e975
commit
ce6ecda5cd
@@ -11,6 +11,7 @@ let map = new google.maps.Map(
|
||||
fullscreenControlOptions: {
|
||||
position: google.maps.ControlPosition.RIGHT_TOP
|
||||
},
|
||||
gestureHandling: "cooperative",
|
||||
scrollwheel: true,
|
||||
zoom: 4
|
||||
});
|
||||
|
||||
12
types/googlemaps/index.d.ts
vendored
12
types/googlemaps/index.d.ts
vendored
@@ -1,6 +1,6 @@
|
||||
// Type definitions for Google Maps JavaScript API 3.26
|
||||
// Project: https://developers.google.com/maps/
|
||||
// Definitions by: Folia A/S <http://www.folia.dk>, Chris Wrench <https://github.com/cgwrench>, Kiarash Ghiaseddin <https://github.com/Silver-Connection/DefinitelyTyped>, Grant Hutchins <https://github.com/nertzy>, Denis Atyasov <https://github.com/xaolas>, Michael McMullin <https://github.com/mrmcnerd>
|
||||
// Definitions by: Folia A/S <http://www.folia.dk>, Chris Wrench <https://github.com/cgwrench>, Kiarash Ghiaseddin <https://github.com/Silver-Connection/DefinitelyTyped>, Grant Hutchins <https://github.com/nertzy>, Denis Atyasov <https://github.com/xaolas>, Michael McMullin <https://github.com/mrmcnerd>, Martin Costello <https://github.com/martincostello>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
/*
|
||||
@@ -95,6 +95,10 @@ declare namespace google.maps {
|
||||
fullscreenControl?: boolean;
|
||||
/** The display options for the Fullscreen control. */
|
||||
fullscreenControlOptions?: FullscreenControlOptions;
|
||||
/**
|
||||
* This setting controls how gestures on the map are handled.
|
||||
*/
|
||||
gestureHandling?: GestureHandlingOptions;
|
||||
/**
|
||||
* The heading for aerial imagery in degrees measured clockwise from cardinal
|
||||
* direction North. Headings are snapped to the nearest available angle for
|
||||
@@ -250,6 +254,12 @@ declare namespace google.maps {
|
||||
opened?: boolean;
|
||||
}
|
||||
|
||||
export type GestureHandlingOptions =
|
||||
"cooperative" |
|
||||
"greedy" |
|
||||
"none" |
|
||||
"auto";
|
||||
|
||||
/** Options for the rendering of the pan control. */
|
||||
export interface PanControlOptions {
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user