Rename _ol_source_VectorTile_ to VectorTileSource
This commit is contained in:
@@ -3,7 +3,7 @@ import Map from '../src/ol/Map.js';
|
||||
import View from '../src/ol/View.js';
|
||||
import GeoJSON from '../src/ol/format/GeoJSON.js';
|
||||
import OSM from '../src/ol/source/OSM.js';
|
||||
import _ol_source_VectorTile_ from '../src/ol/source/VectorTile.js';
|
||||
import VectorTileSource from '../src/ol/source/VectorTile.js';
|
||||
import TileLayer from '../src/ol/layer/Tile.js';
|
||||
import _ol_layer_VectorTile_ from '../src/ol/layer/VectorTile.js';
|
||||
import _ol_proj_Projection_ from '../src/ol/proj/Projection.js';
|
||||
@@ -74,7 +74,7 @@ fetch(url).then(function(response) {
|
||||
extent: 4096,
|
||||
debug: 1
|
||||
});
|
||||
var vectorSource = new _ol_source_VectorTile_({
|
||||
var vectorSource = new VectorTileSource({
|
||||
format: new GeoJSON(),
|
||||
tileLoadFunction: function(tile) {
|
||||
var format = tile.getFormat();
|
||||
|
||||
@@ -3,7 +3,7 @@ import View from '../src/ol/View.js';
|
||||
import MVT from '../src/ol/format/MVT.js';
|
||||
import _ol_layer_VectorTile_ from '../src/ol/layer/VectorTile.js';
|
||||
import {get as getProjection} from '../src/ol/proj.js';
|
||||
import _ol_source_VectorTile_ from '../src/ol/source/VectorTile.js';
|
||||
import VectorTileSource from '../src/ol/source/VectorTile.js';
|
||||
import _ol_style_Fill_ from '../src/ol/style/Fill.js';
|
||||
import _ol_style_Icon_ from '../src/ol/style/Icon.js';
|
||||
import _ol_style_Stroke_ from '../src/ol/style/Stroke.js';
|
||||
@@ -33,7 +33,7 @@ function tileUrlFunction(tileCoord) {
|
||||
var map = new Map({
|
||||
layers: [
|
||||
new _ol_layer_VectorTile_({
|
||||
source: new _ol_source_VectorTile_({
|
||||
source: new VectorTileSource({
|
||||
attributions: '© <a href="https://www.mapbox.com/map-feedback/">Mapbox</a> ' +
|
||||
'© <a href="https://www.openstreetmap.org/copyright">' +
|
||||
'OpenStreetMap contributors</a>',
|
||||
|
||||
@@ -2,7 +2,7 @@ import Map from '../src/ol/Map.js';
|
||||
import View from '../src/ol/View.js';
|
||||
import MVT from '../src/ol/format/MVT.js';
|
||||
import _ol_layer_VectorTile_ from '../src/ol/layer/VectorTile.js';
|
||||
import _ol_source_VectorTile_ from '../src/ol/source/VectorTile.js';
|
||||
import VectorTileSource from '../src/ol/source/VectorTile.js';
|
||||
import _ol_style_Fill_ from '../src/ol/style/Fill.js';
|
||||
import _ol_style_Icon_ from '../src/ol/style/Icon.js';
|
||||
import _ol_style_Stroke_ from '../src/ol/style/Stroke.js';
|
||||
@@ -16,7 +16,7 @@ var map = new Map({
|
||||
layers: [
|
||||
new _ol_layer_VectorTile_({
|
||||
declutter: true,
|
||||
source: new _ol_source_VectorTile_({
|
||||
source: new VectorTileSource({
|
||||
attributions: '© <a href="https://www.mapbox.com/map-feedback/">Mapbox</a> ' +
|
||||
'© <a href="https://www.openstreetmap.org/copyright">' +
|
||||
'OpenStreetMap contributors</a>',
|
||||
|
||||
@@ -3,7 +3,7 @@ import View from '../src/ol/View.js';
|
||||
import TopoJSON from '../src/ol/format/TopoJSON.js';
|
||||
import _ol_layer_VectorTile_ from '../src/ol/layer/VectorTile.js';
|
||||
import {fromLonLat} from '../src/ol/proj.js';
|
||||
import _ol_source_VectorTile_ from '../src/ol/source/VectorTile.js';
|
||||
import VectorTileSource from '../src/ol/source/VectorTile.js';
|
||||
import _ol_style_Fill_ from '../src/ol/style/Fill.js';
|
||||
import _ol_style_Stroke_ from '../src/ol/style/Stroke.js';
|
||||
import _ol_style_Style_ from '../src/ol/style/Style.js';
|
||||
@@ -61,7 +61,7 @@ var roadStyle = function(feature) {
|
||||
var map = new Map({
|
||||
layers: [
|
||||
new _ol_layer_VectorTile_({
|
||||
source: new _ol_source_VectorTile_({
|
||||
source: new VectorTileSource({
|
||||
attributions: '© OpenStreetMap contributors, Who’s On First, ' +
|
||||
'Natural Earth, and openstreetmapdata.com',
|
||||
format: new TopoJSON({
|
||||
|
||||
@@ -2,7 +2,7 @@ import Map from '../src/ol/Map.js';
|
||||
import View from '../src/ol/View.js';
|
||||
import MVT from '../src/ol/format/MVT.js';
|
||||
import _ol_layer_VectorTile_ from '../src/ol/layer/VectorTile.js';
|
||||
import _ol_source_VectorTile_ from '../src/ol/source/VectorTile.js';
|
||||
import VectorTileSource from '../src/ol/source/VectorTile.js';
|
||||
|
||||
var map = new Map({
|
||||
target: 'map',
|
||||
@@ -11,7 +11,7 @@ var map = new Map({
|
||||
zoom: 2
|
||||
}),
|
||||
layers: [new _ol_layer_VectorTile_({
|
||||
source: new _ol_source_VectorTile_({
|
||||
source: new VectorTileSource({
|
||||
format: new MVT(),
|
||||
url: 'https://basemaps.arcgis.com/v1/arcgis/rest/services/World_Basemap/VectorTileServer/tile/{z}/{y}/{x}.pbf'
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user