Skip to content
This repository has been archived by the owner on Aug 28, 2023. It is now read-only.

Commit

Permalink
Merge pull request #1366 from flibbertigibbet/bugfix/kak/fix-angular-…
Browse files Browse the repository at this point in the history
…linter-errors

Bugfix/kak/fix angular linter errors
  • Loading branch information
flibbertigibbet authored Dec 3, 2019
2 parents 2b7f222 + 983eb26 commit 924894c
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import {
import { Injectable } from '@angular/core';

import { Observable } from 'rxjs';
import { AuthService } from '../services/auth.service';
import { environment } from '../../../environments/environment';
import { AuthService } from '../services/auth.service';

/** Pass untouched request through to the next request handler. */
@Injectable()
Expand Down
14 changes: 7 additions & 7 deletions src/angular/planit/src/app/core/utilities/map.utility.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { QueryList, ViewChildren } from '@angular/core';

import { Observable, of as observableOf } from 'rxjs';
import { delay, map, take } from 'rxjs/operators';
import { applyStyle } from 'ol-mapbox-style';
import MVT from 'ol/format/MVT';
import VectorTileLayer from 'ol/layer/VectorTile';
import Map from 'ol/Map';
import { createXYZ } from 'ol/tilegrid';
import VectorTileSource from 'ol/source/VectorTile';
import { createXYZ } from 'ol/tilegrid';
import Map from 'ol/Map';
import { Observable, of as observableOf } from 'rxjs';
import { delay, map, take } from 'rxjs/operators';


import basemapStyle from './basemapStyle.json';
Expand All @@ -27,7 +27,7 @@ const BASEMAP_TILE_URL = 'https://basemaps.arcgis.com/arcgis/rest/services/World
const BASEMAP_Z_INDEX = 0;
const LABELS_Z_INDEX = 99;

export function addBasemapToMap(map: Map, labelsZIndex = LABELS_Z_INDEX) {
export function addBasemapToMap(olMap: Map, labelsZIndex = LABELS_Z_INDEX) {
const sourceOpts = {
format: new MVT(),
url: BASEMAP_TILE_URL
Expand All @@ -38,13 +38,13 @@ export function addBasemapToMap(map: Map, labelsZIndex = LABELS_Z_INDEX) {
zIndex: BASEMAP_Z_INDEX,
});
applyStyle(basemapLayer, basemapStyle, 'esri');
map.addLayer(basemapLayer);
olMap.addLayer(basemapLayer);

const labelsLayer = new VectorTileLayer({
renderMode: 'hybrid',
source: new VectorTileSource(sourceOpts),
zIndex: labelsZIndex,
});
applyStyle(labelsLayer, labelsStyle, 'esri');
map.addLayer(labelsLayer);
olMap.addLayer(labelsLayer);
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@ import {
} from 'ngx-openlayers';
import { ToastrService } from 'ngx-toastr';
import { applyStyle } from 'ol-mapbox-style';
import Collection from 'ol/Collection';
import { containsCoordinate } from 'ol/extent';
import GeoJSON from 'ol/format/GeoJSON';
import OLPolygon from 'ol/geom/Polygon';
import { DrawEvent } from 'ol/interaction/Draw';
import Feature from 'ol/Feature';
import GeoJSON from 'ol/format/GeoJSON';
import { transformExtent } from 'ol/proj';
import VectorSource from 'ol/source/Vector';
import { getArea } from 'ol/sphere';
import Collection from 'ol/Collection';
import Feature from 'ol/Feature';
import { Observable, Subscription, of as observableOf } from 'rxjs';
import { delay, map, take } from 'rxjs/operators';

Expand Down

0 comments on commit 924894c

Please sign in to comment.