Merge pull request #10034 from openlayers/experiment
Mark experimental examples as experimental
This commit is contained in:
@@ -7,6 +7,7 @@ docs: >
|
|||||||
makes it so the map view uses geographic coordinates (even if the view projection is
|
makes it so the map view uses geographic coordinates (even if the view projection is
|
||||||
not geographic).
|
not geographic).
|
||||||
tags: "geographic"
|
tags: "geographic"
|
||||||
|
experimental: true
|
||||||
---
|
---
|
||||||
<div id="map" class="map"></div>
|
<div id="map" class="map"></div>
|
||||||
<select id="mode">
|
<select id="mode">
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ docs: >
|
|||||||
to store the year of impact.
|
to store the year of impact.
|
||||||
|
|
||||||
tags: "webgl, icon, sprite, filter, feature"
|
tags: "webgl, icon, sprite, filter, feature"
|
||||||
|
experimental: true
|
||||||
---
|
---
|
||||||
<div id="map" class="map"></div>
|
<div id="map" class="map"></div>
|
||||||
<form>
|
<form>
|
||||||
|
|||||||
@@ -7,6 +7,7 @@ docs: >
|
|||||||
makes it so the map view uses geographic coordinates (even if the view projection is
|
makes it so the map view uses geographic coordinates (even if the view projection is
|
||||||
not geographic).
|
not geographic).
|
||||||
tags: "geographic"
|
tags: "geographic"
|
||||||
|
experimental: true
|
||||||
resources:
|
resources:
|
||||||
- https://code.jquery.com/jquery-2.2.3.min.js
|
- https://code.jquery.com/jquery-2.2.3.min.js
|
||||||
- https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css
|
- https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ docs: >
|
|||||||
|
|
||||||
The dataset contains around 80k points and can be found here: https://www.kaggle.com/NUFORC/ufo-sightings
|
The dataset contains around 80k points and can be found here: https://www.kaggle.com/NUFORC/ufo-sightings
|
||||||
tags: "webgl, icon, sprite, point, ufo"
|
tags: "webgl, icon, sprite, point, ufo"
|
||||||
|
experimental: true
|
||||||
cloak:
|
cloak:
|
||||||
- key: pk.eyJ1IjoidHNjaGF1YiIsImEiOiJjaW5zYW5lNHkxMTNmdWttM3JyOHZtMmNtIn0.CDIBD8H-G2Gf-cPkIuWtRg
|
- key: pk.eyJ1IjoidHNjaGF1YiIsImEiOiJjaW5zYW5lNHkxMTNmdWttM3JyOHZtMmNtIn0.CDIBD8H-G2Gf-cPkIuWtRg
|
||||||
value: Your Mapbox access token from https://mapbox.com/ here
|
value: Your Mapbox access token from https://mapbox.com/ here
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ shortdesc: Example of a Mapbox-gl-js layer integration.
|
|||||||
docs: >
|
docs: >
|
||||||
Show how to add a mapbox-gl-js layer in an openlayers map. **Note**: Make sure to get your own API key at https://www.maptiler.com/cloud/ when using this example. No map will be visible when the API key has expired.
|
Show how to add a mapbox-gl-js layer in an openlayers map. **Note**: Make sure to get your own API key at https://www.maptiler.com/cloud/ when using this example. No map will be visible when the API key has expired.
|
||||||
tags: "simple, mapbox, vector, tiles, maptiler"
|
tags: "simple, mapbox, vector, tiles, maptiler"
|
||||||
|
experimental: true
|
||||||
resources:
|
resources:
|
||||||
- https://unpkg.com/mapbox-gl@0.54.0/dist/mapbox-gl.js
|
- https://unpkg.com/mapbox-gl@0.54.0/dist/mapbox-gl.js
|
||||||
- https://unpkg.com/mapbox-gl@0.54.0/dist/mapbox-gl.css
|
- https://unpkg.com/mapbox-gl@0.54.0/dist/mapbox-gl.css
|
||||||
|
|||||||
@@ -8,3 +8,4 @@ The `.html` files in this folder are built by applying the templates in the `tem
|
|||||||
* docs: Documentation of the example. Can be markdown.
|
* docs: Documentation of the example. Can be markdown.
|
||||||
* tags: Tags for the example index
|
* tags: Tags for the example index
|
||||||
* resources: Additional js or css resources required by the example. This is a YAML list of URLs.
|
* resources: Additional js or css resources required by the example. This is a YAML list of URLs.
|
||||||
|
* experimental: if true, a warning will appear on the example page mentioning the fact that it uses features not part of the API.
|
||||||
|
|||||||
@@ -3,8 +3,8 @@ layout: example.html
|
|||||||
title: Semi-Transparent Layer
|
title: Semi-Transparent Layer
|
||||||
shortdesc: Example of a map with a semi-transparent layer.
|
shortdesc: Example of a map with a semi-transparent layer.
|
||||||
docs: >
|
docs: >
|
||||||
This example will display a tiled MaxBox layer semi-transparently over an OSM background. The OSM layer is changed to back and white by using a CSS filter.
|
This example will display a tiled MaxBox layer semi-transparently over an OSM background. The OSM layer is changed to black and white by using a CSS filter.
|
||||||
tags: "transparent, osm, tilejson"
|
tags: "transparent, osm, tilejson, css"
|
||||||
cloak:
|
cloak:
|
||||||
- key: pk.eyJ1IjoiYWhvY2V2YXIiLCJhIjoiY2pzbmg0Nmk5MGF5NzQzbzRnbDNoeHJrbiJ9.7_-_gL8ur7ZtEiNwRfCy7Q
|
- key: pk.eyJ1IjoiYWhvY2V2YXIiLCJhIjoiY2pzbmg0Nmk5MGF5NzQzbzRnbDNoeHJrbiJ9.7_-_gL8ur7ZtEiNwRfCy7Q
|
||||||
value: Your Mapbox access token from https://mapbox.com/ here
|
value: Your Mapbox access token from https://mapbox.com/ here
|
||||||
|
|||||||
@@ -99,6 +99,12 @@
|
|||||||
This example uses OpenLayers v<span>{{ olVersion }}</span>. The <a id="latest-link" href="#" class="alert-link">latest</a> is v<span id="latest-version"></span>.
|
This example uses OpenLayers v<span>{{ olVersion }}</span>. The <a id="latest-link" href="#" class="alert-link">latest</a> is v<span id="latest-version"></span>.
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div id="experimental-notice" class="alert alert-warning alert-dismissible" role="alert" style="display:none">
|
||||||
|
<button id="experimental-dismiss" type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||||
|
This example uses features that are not part of the stable API and subject to change between releases. Consult the <a href="https://openlayers.org/en/latest/apidoc/">API documentation</a>
|
||||||
|
to see what is supported in the latest release.
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="row-fluid">
|
<div class="row-fluid">
|
||||||
<a class="codepen-button pull-right"><i class="fa fa-codepen"></i> Edit</a>
|
<a class="codepen-button pull-right"><i class="fa fa-codepen"></i> Edit</a>
|
||||||
<div class="span12">
|
<div class="span12">
|
||||||
@@ -183,6 +189,15 @@
|
|||||||
document.cookie = cookieText;
|
document.cookie = cookieText;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var experimentalNotice = document.getElementById('experimental-notice');
|
||||||
|
if (window.experimental) {
|
||||||
|
experimentalNotice.style.display = 'block';
|
||||||
|
document.getElementById('experimental-dismiss').onclick = function() {
|
||||||
|
experimentalNotice.style.display = 'none';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -18,6 +18,7 @@ docs: >
|
|||||||
</p>
|
</p>
|
||||||
|
|
||||||
tags: "webgl, point, layer, feature"
|
tags: "webgl, point, layer, feature"
|
||||||
|
experimental: true
|
||||||
---
|
---
|
||||||
|
|
||||||
<div id="map" class="map"></div>
|
<div id="map" class="map"></div>
|
||||||
|
|||||||
@@ -200,6 +200,12 @@ ExampleBuilder.prototype.render = async function(dir, chunk) {
|
|||||||
tag: `<script src="${this.common}.js"></script><script src="${jsName}"></script>`,
|
tag: `<script src="${this.common}.js"></script><script src="${jsName}"></script>`,
|
||||||
source: jsSource
|
source: jsSource
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if (data.experimental) {
|
||||||
|
const prelude = '<script>window.experimental = true;</script>';
|
||||||
|
data.js.tag = prelude + data.js.tag;
|
||||||
|
}
|
||||||
|
|
||||||
data.pkgJson = JSON.stringify({
|
data.pkgJson = JSON.stringify({
|
||||||
name: name,
|
name: name,
|
||||||
dependencies: getDependencies(jsSource),
|
dependencies: getDependencies(jsSource),
|
||||||
|
|||||||
@@ -3,8 +3,9 @@ layout: example.html
|
|||||||
title: Worker
|
title: Worker
|
||||||
shortdesc: This example should be deleted.
|
shortdesc: This example should be deleted.
|
||||||
docs: >
|
docs: >
|
||||||
When you move the map, a message is sent to a worker. In response, the woker sends a
|
When you move the map, a message is sent to a worker. In response, the worker sends a
|
||||||
message back with the version identifier.
|
message back with the version identifier.
|
||||||
tags: "worker"
|
tags: "worker"
|
||||||
|
experimental: true
|
||||||
---
|
---
|
||||||
<div id="map" class="map"></div>
|
<div id="map" class="map"></div>
|
||||||
|
|||||||
Reference in New Issue
Block a user