@@ -12,37 +12,6 @@ import * as GMPX from '@googlemaps/extended-component-library/react';
1212import { OverlayLayout } from '@googlemaps/extended-component-library/overlay_layout.js' ;
1313import { PlacePicker } from '@googlemaps/extended-component-library/place_picker.js' ;
1414
15- /* Google Maps JS SDK typings, which are
16- * published as `@types/google.maps`. However, sometimes there is a delay
17- * in published typings. Components should use types from this file so we
18- * can centrally shim/unshim them when necessary.
19- */
20-
21- export declare interface AuthorAttribution {
22- displayName : string ;
23- photoURI : string | null ;
24- uri : string | null ;
25- }
26-
27- export declare type Photo = Omit < google . maps . places . Photo , 'attributions' > & {
28- authorAttributions : AuthorAttribution [ ] ;
29- } ;
30-
31- export declare type Review =
32- Omit < google . maps . places . Review , 'author' | 'authorURI' | 'authorPhotoURI' > & {
33- authorAttribution : AuthorAttribution | null ;
34- } ;
35-
36- export declare interface Place extends Omit <
37- google . maps . places . Place ,
38- 'photos' | 'reviews' | 'fetchFields' | 'accessibilityOptions' > {
39- photos ?: Photo [ ] ;
40- reviews ?: Review [ ] ;
41- accessibilityOptions ?: { hasWheelchairAccessibleEntrance : boolean | null } | null ;
42- fetchFields : ( options : google . maps . places . FetchFieldsRequest ) =>
43- Promise < { place : Place } > ;
44- }
45-
4615const API_KEY =
4716 globalThis . GOOGLE_MAPS_API_KEY ?? ( "YOUR_API_KEY" ) ;
4817const DEFAULT_CENTER = { lat : - 34.397 , lng : 150.644 } ;
@@ -55,7 +24,7 @@ const DEFAULT_ZOOM_WITH_LOCATION = 16;
5524const App = ( ) => {
5625 const overlayLayoutRef = useRef < OverlayLayout > ( null ) ;
5726 const pickerRef = useRef < PlacePicker > ( null ) ;
58- const [ college , setCollege ] = useState < Place | undefined > ( undefined ) ;
27+ const [ college , setCollege ] = useState < google . maps . places . Place | undefined > ( undefined ) ;
5928
6029 return (
6130 < div className = "App" >
0 commit comments