@@ -23,49 +23,49 @@ export class TripPlannerComponent implements OnInit {
2323 @Input ( ) private estimatedTime : any ;
2424 @Input ( ) private estimatedDistance : any ;
2525
26- @ViewChild ( " pickupInput" )
26+ @ViewChild ( ' pickupInput' )
2727 public pickupInputElementRef : ElementRef ;
2828
29- @ViewChild ( " pickupOutput" )
29+ @ViewChild ( ' pickupOutput' )
3030 public pickupOutputElementRef : ElementRef ;
3131
3232 @ViewChild ( GMapsDirectionsService ) service : GMapsDirectionsService ;
3333
3434 constructor (
35- private ngZone : NgZone ,
36- private mapsAPILoader : MapsAPILoader ,
37- private gmapsApi : GoogleMapsAPIWrapper ,
35+ private ngZone : NgZone ,
36+ private mapsAPILoader : MapsAPILoader ,
37+ private gmapsApi : GoogleMapsAPIWrapper ,
3838 private _elementRef : ElementRef ) {
3939 }
4040
4141 ngOnInit ( ) {
42- //Default Map View
42+ // Default Map View
4343 this . latitude = 26.089595 ;
4444 this . longitude = - 80.366791 ;
4545 this . zoom = 14 ;
4646
4747 this . destinationInput = new FormControl ( ) ;
4848 this . destinationOutput = new FormControl ( ) ;
4949
50- //Update Map View
50+ // Update Map View
5151 this . setCurrentPosition ( ) ;
52-
53- //Load Autocomplete for Inputs
52+
53+ // Load Autocomplete for Inputs
5454 this . mapsAPILoader . load ( ) . then ( ( ) => {
55- let autocompleteInput = new google . maps . places . Autocomplete ( this . pickupInputElementRef . nativeElement , {
56- types : [ " address" ]
55+ const autocompleteInput = new google . maps . places . Autocomplete ( this . pickupInputElementRef . nativeElement , {
56+ types : [ ' address' ]
5757 } ) ;
5858
59- let autocompleteOutput = new google . maps . places . Autocomplete ( this . pickupOutputElementRef . nativeElement , {
60- types : [ " address" ]
59+ const autocompleteOutput = new google . maps . places . Autocomplete ( this . pickupOutputElementRef . nativeElement , {
60+ types : [ ' address' ]
6161 } ) ;
6262 this . setupPlaceChangedListener ( autocompleteInput , 'pickup' ) ;
6363 this . setupPlaceChangedListener ( autocompleteOutput , 'destination' ) ;
6464 } ) ;
6565 }
6666
6767 setCurrentPosition ( ) {
68- if ( " geolocation" in navigator ) {
68+ if ( ' geolocation' in navigator ) {
6969 navigator . geolocation . getCurrentPosition ( ( position ) => {
7070 this . latitude = position . coords . latitude ;
7171 this . longitude = position . coords . longitude ;
@@ -74,9 +74,9 @@ export class TripPlannerComponent implements OnInit {
7474 }
7575
7676 private setupPlaceChangedListener ( autocomplete :any , inputType :string ) {
77- autocomplete . addListener ( " place_changed" , ( ) => {
77+ autocomplete . addListener ( ' place_changed' , ( ) => {
7878 this . ngZone . run ( ( ) => {
79- let place : google . maps . places . PlaceResult = autocomplete . getPlace ( ) ;
79+ const place : google . maps . places . PlaceResult = autocomplete . getPlace ( ) ;
8080 if ( place . geometry === undefined ) {
8181 return ;
8282 }
@@ -104,7 +104,7 @@ export class TripPlannerComponent implements OnInit {
104104 }
105105
106106 onFindRideClick ( event ) {
107- console . log ( " Clicked find ride." ) ;
107+ console . log ( ' Clicked find ride.' ) ;
108108 }
109109
110110}
0 commit comments