Skip to content

Commit 8298719

Browse files
committed
Website updates
1 parent 8f9d52b commit 8298719

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+60
-100
lines changed

dist/en/main/examples/cog-modeltransformation.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,15 +165,15 @@ <h5 class="modal-title" id="tag-example-title"></h5>
165165

166166
<div class="row-fluid">
167167
<h5 class="source-heading">main.js</h5>
168-
<pre><code id="example-js-source" class="language-js">import proj4 from &#x27;proj4&#x27;;
169-
import Map from &#x27;ol/Map.js&#x27;;
168+
<pre><code id="example-js-source" class="language-js">import Map from &#x27;ol/Map.js&#x27;;
170169
import View from &#x27;ol/View.js&#x27;;
171170
import TileLayer from &#x27;ol/layer/WebGLTile.js&#x27;;
172171
import {fromEPSGCode, register} from &#x27;ol/proj/proj4.js&#x27;;
173172
import {transformExtent} from &#x27;ol/proj.js&#x27;;
174173
import GeoTIFF from &#x27;ol/source/GeoTIFF.js&#x27;;
175174
import OSM from &#x27;ol/source/OSM.js&#x27;;
176175
import TileDebug from &#x27;ol/source/TileDebug.js&#x27;;
176+
import proj4 from &#x27;proj4&#x27;;
177177

178178
register(proj4);
179179

dist/en/main/examples/cog-projection.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,8 +203,7 @@ <h5 class="modal-title" id="tag-example-title"></h5>
203203

204204
<div class="row-fluid">
205205
<h5 class="source-heading">main.js</h5>
206-
<pre><code id="example-js-source" class="language-js">import proj4 from &#x27;proj4&#x27;;
207-
import Map from &#x27;ol/Map.js&#x27;;
206+
<pre><code id="example-js-source" class="language-js">import Map from &#x27;ol/Map.js&#x27;;
208207
import TileLayer from &#x27;ol/layer/WebGLTile.js&#x27;;
209208
import {
210209
epsgLookupMapTiler,
@@ -214,6 +213,7 @@ <h5 class="source-heading">main.js</h5>
214213
} from &#x27;ol/proj/proj4.js&#x27;;
215214
import GeoTIFF from &#x27;ol/source/GeoTIFF.js&#x27;;
216215
import XYZ from &#x27;ol/source/XYZ.js&#x27;;
216+
import proj4 from &#x27;proj4&#x27;;
217217

218218
const key &#x3D; &#x27;Get your own API key at https://www.maptiler.com/cloud/&#x27;;
219219
const attributions &#x3D;

dist/en/main/examples/d3.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,14 +109,14 @@ <h5 class="source-heading">main.js</h5>
109109
<pre><code id="example-js-source" class="language-js">import {json} from &#x27;d3-fetch&#x27;;
110110
import {geoBounds, geoMercator, geoPath} from &#x27;d3-geo&#x27;;
111111
import {select} from &#x27;d3-selection&#x27;;
112-
import {feature} from &#x27;topojson-client&#x27;;
113112
import Map from &#x27;ol/Map.js&#x27;;
114113
import View from &#x27;ol/View.js&#x27;;
115114
import {getCenter, getWidth} from &#x27;ol/extent.js&#x27;;
116115
import Layer from &#x27;ol/layer/Layer.js&#x27;;
117116
import TileLayer from &#x27;ol/layer/Tile.js&#x27;;
118117
import {fromLonLat, toLonLat} from &#x27;ol/proj.js&#x27;;
119118
import StadiaMaps from &#x27;ol/source/StadiaMaps.js&#x27;;
119+
import {feature} from &#x27;topojson-client&#x27;;
120120

121121
class CanvasLayer extends Layer {
122122
constructor(options) {

dist/en/main/examples/declutter-group.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -252,8 +252,7 @@ <h5 class="modal-title" id="tag-example-title"></h5>
252252

253253
<div class="row-fluid">
254254
<h5 class="source-heading">main.js</h5>
255-
<pre><code id="example-js-source" class="language-js">import {apply} from &#x27;ol-mapbox-style&#x27;;
256-
import Feature from &#x27;ol/Feature.js&#x27;;
255+
<pre><code id="example-js-source" class="language-js">import Feature from &#x27;ol/Feature.js&#x27;;
257256
import Map from &#x27;ol/Map.js&#x27;;
258257
import View from &#x27;ol/View.js&#x27;;
259258
import {getCenter} from &#x27;ol/extent.js&#x27;;
@@ -262,6 +261,7 @@ <h5 class="source-heading">main.js</h5>
262261
import LayerGroup from &#x27;ol/layer/Group.js&#x27;;
263262
import VectorLayer from &#x27;ol/layer/Vector.js&#x27;;
264263
import VectorSource from &#x27;ol/source/Vector.js&#x27;;
264+
import {apply} from &#x27;ol-mapbox-style&#x27;;
265265

266266
const square &#x3D; [-12e6, 3.5e6, -10e6, 5.5e6];
267267
const overlay &#x3D; new VectorLayer({

dist/en/main/examples/draw-shapes.html

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -274,10 +274,7 @@ <h5 class="source-heading">main.js</h5>
274274
<pre><code id="example-js-source" class="language-js">import Map from &#x27;ol/Map.js&#x27;;
275275
import View from &#x27;ol/View.js&#x27;;
276276
import Polygon from &#x27;ol/geom/Polygon.js&#x27;;
277-
import Draw, {
278-
createBox,
279-
createRegularPolygon,
280-
} from &#x27;ol/interaction/Draw.js&#x27;;
277+
import Draw, {createBox, createRegularPolygon} from &#x27;ol/interaction/Draw.js&#x27;;
281278
import TileLayer from &#x27;ol/layer/Tile.js&#x27;;
282279
import VectorLayer from &#x27;ol/layer/Vector.js&#x27;;
283280
import OSM from &#x27;ol/source/OSM.js&#x27;;

dist/en/main/examples/getfeatureinfo-image.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ <h5 class="source-heading">main.js</h5>
151151

152152
map.on(&#x27;singleclick&#x27;, function (evt) {
153153
document.getElementById(&#x27;info&#x27;).innerHTML &#x3D; &#x27;&#x27;;
154-
const viewResolution &#x3D; /** @type {number} */ (view.getResolution());
154+
const viewResolution &#x3D; view.getResolution();
155155
const url &#x3D; wmsSource.getFeatureInfoUrl(
156156
evt.coordinate,
157157
viewResolution,

dist/en/main/examples/getfeatureinfo-tile.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ <h5 class="source-heading">main.js</h5>
151151

152152
map.on(&#x27;singleclick&#x27;, function (evt) {
153153
document.getElementById(&#x27;info&#x27;).innerHTML &#x3D; &#x27;&#x27;;
154-
const viewResolution &#x3D; /** @type {number} */ (view.getResolution());
154+
const viewResolution &#x3D; view.getResolution();
155155
const url &#x3D; wmsSource.getFeatureInfoUrl(
156156
evt.coordinate,
157157
viewResolution,

dist/en/main/examples/igc.html

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -342,10 +342,7 @@ <h5 class="source-heading">main.js</h5>
342342
const value &#x3D; parseInt(control.value, 10) / 100;
343343
const m &#x3D; time.start + time.duration * value;
344344
vectorSource.forEachFeature(function (feature) {
345-
const geometry &#x3D;
346-
/** @type {import(&#x27;ol/geom/LineString.js&#x27;).default} */ (
347-
feature.getGeometry()
348-
);
345+
const geometry &#x3D; feature.getGeometry();
349346
const coordinate &#x3D; geometry.getCoordinateAtM(m, true);
350347
let highlight &#x3D; feature.get(&#x27;highlight&#x27;);
351348
if (highlight &#x3D;&#x3D;&#x3D; undefined) {

dist/en/main/examples/layer-extent.html

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,8 +147,7 @@ <h5 class="source-heading">main.js</h5>
147147
Sweden: transform([11.02737, 55.36174, 23.90338, 69.10625]),
148148
};
149149

150-
const key &#x3D;
151-
&#x27;Your Mapbox access token from https://mapbox.com/ here&#x27;;
150+
const key &#x3D; &#x27;Your Mapbox access token from https://mapbox.com/ here&#x27;;
152151

153152
const base &#x3D; new TileLayer({
154153
source: new TileJSON({

dist/en/main/examples/layer-group.html

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -226,8 +226,7 @@ <h5 class="source-heading">main.js</h5>
226226
import OSM from &#x27;ol/source/OSM.js&#x27;;
227227
import TileJSON from &#x27;ol/source/TileJSON.js&#x27;;
228228

229-
const key &#x3D;
230-
&#x27;Your Mapbox access token from https://mapbox.com/ here&#x27;;
229+
const key &#x3D; &#x27;Your Mapbox access token from https://mapbox.com/ here&#x27;;
231230

232231
const map &#x3D; new Map({
233232
layers: [

0 commit comments

Comments
 (0)