()
| 147 | new EventEmitter<google.maps.Rectangle>(); |
| 148 | |
| 149 | ngOnInit() { |
| 150 | if (this._map._isBrowser) { |
| 151 | this._combineOptions() |
| 152 | .pipe(take(1)) |
| 153 | .subscribe(options => { |
| 154 | if (google.maps.Rectangle && this._map.googleMap) { |
| 155 | this._initialize(this._map.googleMap, google.maps.Rectangle, options); |
| 156 | } else { |
| 157 | this._ngZone.runOutsideAngular(() => { |
| 158 | Promise.all([this._map._resolveMap(), google.maps.importLibrary('maps')]).then( |
| 159 | ([map, lib]) => { |
| 160 | this._initialize(map, (lib as google.maps.MapsLibrary).Rectangle, options); |
| 161 | }, |
| 162 | ); |
| 163 | }); |
| 164 | } |
| 165 | }); |
| 166 | } |
| 167 | } |
| 168 | |
| 169 | private _initialize( |
| 170 | map: google.maps.Map, |
nothing calls this directly
no test coverage detected