@basemaps/landing 8.6.0 → 8.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (209) hide show
  1. package/build/src/__tests__/geojson.test.js +1 -1
  2. package/build/src/__tests__/geojson.test.js.map +1 -1
  3. package/build/src/components/map.d.ts +2 -1
  4. package/build/src/components/map.js +24 -12
  5. package/build/src/components/map.js.map +1 -1
  6. package/build/src/components/map.label.js +1 -0
  7. package/build/src/components/map.label.js.map +1 -1
  8. package/build/src/components/map.switcher.js +17 -2
  9. package/build/src/components/map.switcher.js.map +1 -1
  10. package/build/src/components/terrain.control.d.ts +14 -0
  11. package/build/src/components/terrain.control.js +101 -0
  12. package/build/src/components/terrain.control.js.map +1 -0
  13. package/build/src/config.layer.d.ts +11 -1
  14. package/build/src/config.map.js +8 -1
  15. package/build/src/config.map.js.map +1 -1
  16. package/build/src/tile.matrix.d.ts +1 -0
  17. package/build/src/tile.matrix.js +1 -0
  18. package/build/src/tile.matrix.js.map +1 -1
  19. package/build/tsconfig.tsbuildinfo +1 -1
  20. package/package.json +8 -11
  21. package/dist/android-chrome-192x192.png +0 -0
  22. package/dist/android-chrome-512x512.png +0 -0
  23. package/dist/apple-touch-icon.png +0 -0
  24. package/dist/assets/clear.svg +0 -1
  25. package/dist/assets/fonts/OpenSans-Bold.woff2 +0 -0
  26. package/dist/assets/fonts/OpenSans-Italic.woff2 +0 -0
  27. package/dist/assets/fonts/OpenSans-Light.woff2 +0 -0
  28. package/dist/assets/fonts/OpenSans-Regular.woff2 +0 -0
  29. package/dist/assets/fonts/OpenSans-SemiBold.woff2 +0 -0
  30. package/dist/assets/logo-linz.svg +0 -124
  31. package/dist/assets/logo-nz-govt.svg +0 -196
  32. package/dist/assets/whats_new_updates.svg +0 -1
  33. package/dist/basemaps-card.jpeg +0 -0
  34. package/dist/docs/404.html +0 -2173
  35. package/dist/docs/assets/images/favicon.png +0 -0
  36. package/dist/docs/assets/javascripts/bundle.83f73b43.min.js +0 -16
  37. package/dist/docs/assets/javascripts/bundle.83f73b43.min.js.map +0 -7
  38. package/dist/docs/assets/javascripts/lunr/min/lunr.ar.min.js +0 -1
  39. package/dist/docs/assets/javascripts/lunr/min/lunr.da.min.js +0 -18
  40. package/dist/docs/assets/javascripts/lunr/min/lunr.de.min.js +0 -18
  41. package/dist/docs/assets/javascripts/lunr/min/lunr.du.min.js +0 -18
  42. package/dist/docs/assets/javascripts/lunr/min/lunr.el.min.js +0 -1
  43. package/dist/docs/assets/javascripts/lunr/min/lunr.es.min.js +0 -18
  44. package/dist/docs/assets/javascripts/lunr/min/lunr.fi.min.js +0 -18
  45. package/dist/docs/assets/javascripts/lunr/min/lunr.fr.min.js +0 -18
  46. package/dist/docs/assets/javascripts/lunr/min/lunr.he.min.js +0 -1
  47. package/dist/docs/assets/javascripts/lunr/min/lunr.hi.min.js +0 -1
  48. package/dist/docs/assets/javascripts/lunr/min/lunr.hu.min.js +0 -18
  49. package/dist/docs/assets/javascripts/lunr/min/lunr.hy.min.js +0 -1
  50. package/dist/docs/assets/javascripts/lunr/min/lunr.it.min.js +0 -18
  51. package/dist/docs/assets/javascripts/lunr/min/lunr.ja.min.js +0 -1
  52. package/dist/docs/assets/javascripts/lunr/min/lunr.jp.min.js +0 -1
  53. package/dist/docs/assets/javascripts/lunr/min/lunr.kn.min.js +0 -1
  54. package/dist/docs/assets/javascripts/lunr/min/lunr.ko.min.js +0 -1
  55. package/dist/docs/assets/javascripts/lunr/min/lunr.multi.min.js +0 -1
  56. package/dist/docs/assets/javascripts/lunr/min/lunr.nl.min.js +0 -18
  57. package/dist/docs/assets/javascripts/lunr/min/lunr.no.min.js +0 -18
  58. package/dist/docs/assets/javascripts/lunr/min/lunr.pt.min.js +0 -18
  59. package/dist/docs/assets/javascripts/lunr/min/lunr.ro.min.js +0 -18
  60. package/dist/docs/assets/javascripts/lunr/min/lunr.ru.min.js +0 -18
  61. package/dist/docs/assets/javascripts/lunr/min/lunr.sa.min.js +0 -1
  62. package/dist/docs/assets/javascripts/lunr/min/lunr.stemmer.support.min.js +0 -1
  63. package/dist/docs/assets/javascripts/lunr/min/lunr.sv.min.js +0 -18
  64. package/dist/docs/assets/javascripts/lunr/min/lunr.ta.min.js +0 -1
  65. package/dist/docs/assets/javascripts/lunr/min/lunr.te.min.js +0 -1
  66. package/dist/docs/assets/javascripts/lunr/min/lunr.th.min.js +0 -1
  67. package/dist/docs/assets/javascripts/lunr/min/lunr.tr.min.js +0 -18
  68. package/dist/docs/assets/javascripts/lunr/min/lunr.vi.min.js +0 -1
  69. package/dist/docs/assets/javascripts/lunr/min/lunr.zh.min.js +0 -1
  70. package/dist/docs/assets/javascripts/lunr/tinyseg.js +0 -206
  71. package/dist/docs/assets/javascripts/lunr/wordcut.js +0 -6708
  72. package/dist/docs/assets/javascripts/swagger-ui-bundle.js +0 -2
  73. package/dist/docs/assets/javascripts/swagger-ui-bundle.js.map +0 -1
  74. package/dist/docs/assets/javascripts/swagger-ui-standalone-preset.js +0 -2
  75. package/dist/docs/assets/javascripts/swagger-ui-standalone-preset.js.map +0 -1
  76. package/dist/docs/assets/javascripts/workers/search.6ce7567c.min.js +0 -42
  77. package/dist/docs/assets/javascripts/workers/search.6ce7567c.min.js.map +0 -7
  78. package/dist/docs/assets/stylesheets/main.0253249f.min.css +0 -1
  79. package/dist/docs/assets/stylesheets/main.0253249f.min.css.map +0 -1
  80. package/dist/docs/assets/stylesheets/palette.06af60db.min.css +0 -1
  81. package/dist/docs/assets/stylesheets/palette.06af60db.min.css.map +0 -1
  82. package/dist/docs/assets/stylesheets/swagger-ui-dark.css +0 -849
  83. package/dist/docs/assets/stylesheets/swagger-ui.css +0 -3
  84. package/dist/docs/assets/stylesheets/swagger-ui.css.map +0 -1
  85. package/dist/docs/assets/swagger-ui/oauth2-redirect.html +0 -79
  86. package/dist/docs/configuration/index.html +0 -2337
  87. package/dist/docs/deployment/index.html +0 -2288
  88. package/dist/docs/developer-guide/cli-methods/bundle-the-basemaps-assets-archive/index.html +0 -2539
  89. package/dist/docs/developer-guide/cli-methods/bundle-the-basemaps-config-file/index.html +0 -2459
  90. package/dist/docs/developer-guide/index.html +0 -2241
  91. package/dist/docs/developer-guide/run-basemaps-locally/index.html +0 -2471
  92. package/dist/docs/developer-guide/server-methods/serve-basemaps-with-bundled-config-file/index.html +0 -2469
  93. package/dist/docs/developer-guide/server-methods/serve-basemaps-with-collection-of-geotiff-files/index.html +0 -2358
  94. package/dist/docs/examples/_overview/index.html +0 -2226
  95. package/dist/docs/examples/index.leaflet.xyz.3857.html +0 -38
  96. package/dist/docs/examples/index.maplibre.opacity.3857.html +0 -215
  97. package/dist/docs/examples/index.maplibre.vector.3857.html +0 -45
  98. package/dist/docs/examples/leaflet.xyz.3857/index.html +0 -2260
  99. package/dist/docs/examples/maplibre.opacity.3857/index.html +0 -2437
  100. package/dist/docs/examples/maplibre.vector.3857/index.html +0 -2267
  101. package/dist/docs/index.css +0 -3
  102. package/dist/docs/index.html +0 -2497
  103. package/dist/docs/linz-motif.svg +0 -124
  104. package/dist/docs/operator-guide/cog-quality/index.html +0 -2477
  105. package/dist/docs/operator-guide/empty-tiles/index.html +0 -2347
  106. package/dist/docs/operator-guide/gebco/index.html +0 -2312
  107. package/dist/docs/operator-guide/index.html +0 -2215
  108. package/dist/docs/operator-guide/quick-start/index.html +0 -2460
  109. package/dist/docs/operator-guide/relief-shade/index.html +0 -2327
  110. package/dist/docs/operator-guide/static/2023-06-26-gisborne-2023.png +0 -0
  111. package/dist/docs/operator-guide/static/projection_beehive_fakenztm2000.webp +0 -0
  112. package/dist/docs/operator-guide/static/projection_beehive_nztm2000quad.webp +0 -0
  113. package/dist/docs/operator-guide/static/projection_nztm2000quad_0_0_0.webp +0 -0
  114. package/dist/docs/operator-guide/static/quality__005_006_0_bilinear.webp +0 -0
  115. package/dist/docs/operator-guide/static/quality__005_006_0_lanczos.webp +0 -0
  116. package/dist/docs/operator-guide/static/quality__i6.bilinear.webp +0 -0
  117. package/dist/docs/operator-guide/static/quality__i6.cubic.webp +0 -0
  118. package/dist/docs/operator-guide/static/quality__i6.lanczos.webp +0 -0
  119. package/dist/docs/operator-guide/static/quality__resampling-overview.webp +0 -0
  120. package/dist/docs/operator-guide/static/quick-start__layers.png +0 -0
  121. package/dist/docs/operator-guide/static/relief__aerial.webp +0 -0
  122. package/dist/docs/operator-guide/static/relief__base.webp +0 -0
  123. package/dist/docs/operator-guide/static/relief__darken.webp +0 -0
  124. package/dist/docs/operator-guide/static/relief__lighten.webp +0 -0
  125. package/dist/docs/operator-guide/texture-shade/index.html +0 -2370
  126. package/dist/docs/operator-guide/xyz-projection/index.html +0 -2375
  127. package/dist/docs/quick-start/index.html +0 -2228
  128. package/dist/docs/sitemap.xml +0 -219
  129. package/dist/docs/sitemap.xml.gz +0 -0
  130. package/dist/docs/static/basemaps-service.png +0 -0
  131. package/dist/docs/static/tile-resize.png +0 -0
  132. package/dist/docs/static/workflow-run.png +0 -0
  133. package/dist/docs/user-guide/_get-started/index.html +0 -2463
  134. package/dist/docs/user-guide/api-documentation/index.html +0 -840
  135. package/dist/docs/user-guide/api-documentation/swagger-3b2ee5d5.html +0 -120
  136. package/dist/docs/user-guide/swagger-api.json +0 -393
  137. package/dist/docs/user-guide/technical-documentation/index.html +0 -2860
  138. package/dist/docs/user-guide/use-in-esri-software/how-to-add-emergency-imagery-to-arcgis/index.html +0 -2220
  139. package/dist/docs/user-guide/use-in-esri-software/how-to-add-emergency-imagery-to-arcgis/static/emergency-response-group.png +0 -0
  140. package/dist/docs/user-guide/use-in-esri-software/how-to-add-individual-linz-basemaps-layers-to-arcgis/index.html +0 -2268
  141. package/dist/docs/user-guide/use-in-esri-software/how-to-add-individual-linz-basemaps-layers-to-arcgis/static/basemaps-menu-button.png +0 -0
  142. package/dist/docs/user-guide/use-in-esri-software/how-to-add-individual-linz-basemaps-layers-to-arcgis/static/copy-url-apikey.png +0 -0
  143. package/dist/docs/user-guide/use-in-esri-software/how-to-add-individual-linz-basemaps-layers-to-arcgis/static/custom-parameters.png +0 -0
  144. package/dist/docs/user-guide/use-in-esri-software/how-to-add-individual-linz-basemaps-layers-to-arcgis/static/layer-search.png +0 -0
  145. package/dist/docs/user-guide/use-in-esri-software/how-to-add-individual-linz-basemaps-layers-to-arcgis/static/layer-selector.png +0 -0
  146. package/dist/docs/user-guide/use-in-esri-software/how-to-add-individual-linz-basemaps-layers-to-arcgis/static/move-apikey-info.png +0 -0
  147. package/dist/docs/user-guide/use-in-esri-software/how-to-add-linz-aerial-imagery-basemaps-to-arcgis-online/index.html +0 -2243
  148. package/dist/docs/user-guide/use-in-esri-software/how-to-add-linz-aerial-imagery-basemaps-to-arcgis-online/static/step-1-agol-map-viewer.png +0 -0
  149. package/dist/docs/user-guide/use-in-esri-software/how-to-add-linz-aerial-imagery-basemaps-to-arcgis-online/static/step-2-layers-panel.png +0 -0
  150. package/dist/docs/user-guide/use-in-esri-software/how-to-add-linz-aerial-imagery-basemaps-to-arcgis-online/static/step-3-browse-layers-option.png +0 -0
  151. package/dist/docs/user-guide/use-in-esri-software/how-to-add-linz-aerial-imagery-basemaps-to-arcgis-online/static/step-4-agol-option.png +0 -0
  152. package/dist/docs/user-guide/use-in-esri-software/how-to-add-linz-aerial-imagery-basemaps-to-arcgis-online/static/step-5-search-box.png +0 -0
  153. package/dist/docs/user-guide/use-in-esri-software/how-to-add-linz-aerial-imagery-basemaps-to-arcgis-online/static/step-6-desired-layer-on-map.png +0 -0
  154. package/dist/docs/user-guide/use-in-esri-software/how-to-add-linz-basemaps-to-arcgis-online-basemaps/index.html +0 -2229
  155. package/dist/docs/user-guide/use-in-esri-software/how-to-add-linz-basemaps-to-arcgis-online-basemaps/static/LINZ-basemaps-group.png +0 -0
  156. package/dist/docs/user-guide/use-in-esri-software/how-to-add-linz-basemaps-to-arcgis-online-basemaps/static/basemaps-in-esri-chooser.png +0 -0
  157. package/dist/docs/user-guide/use-in-esri-software/index.html +0 -2217
  158. package/dist/docs/user-guide/working-with-vector-tiles/creation/index.html +0 -2310
  159. package/dist/docs/user-guide/working-with-vector-tiles/creation/inputs/json-schema-file/index.html +0 -2302
  160. package/dist/docs/user-guide/working-with-vector-tiles/index.html +0 -2286
  161. package/dist/docs/user-guide/working-with-vector-tiles/schema/addresses/index.html +0 -2408
  162. package/dist/docs/user-guide/working-with-vector-tiles/schema/aerialways/index.html +0 -2797
  163. package/dist/docs/user-guide/working-with-vector-tiles/schema/boundaries/index.html +0 -2408
  164. package/dist/docs/user-guide/working-with-vector-tiles/schema/buildings/index.html +0 -2571
  165. package/dist/docs/user-guide/working-with-vector-tiles/schema/contours/index.html +0 -2719
  166. package/dist/docs/user-guide/working-with-vector-tiles/schema/dam_lines/index.html +0 -2561
  167. package/dist/docs/user-guide/working-with-vector-tiles/schema/ferries/index.html +0 -2541
  168. package/dist/docs/user-guide/working-with-vector-tiles/schema/land/index.html +0 -7134
  169. package/dist/docs/user-guide/working-with-vector-tiles/schema/parcel_boundaries/index.html +0 -2408
  170. package/dist/docs/user-guide/working-with-vector-tiles/schema/pier_lines/index.html +0 -2541
  171. package/dist/docs/user-guide/working-with-vector-tiles/schema/place_labels/index.html +0 -2428
  172. package/dist/docs/user-guide/working-with-vector-tiles/schema/pois/index.html +0 -2538
  173. package/dist/docs/user-guide/working-with-vector-tiles/schema/public_transport/index.html +0 -2802
  174. package/dist/docs/user-guide/working-with-vector-tiles/schema/sites/index.html +0 -3324
  175. package/dist/docs/user-guide/working-with-vector-tiles/schema/street_labels/index.html +0 -2817
  176. package/dist/docs/user-guide/working-with-vector-tiles/schema/street_polygons/index.html +0 -2684
  177. package/dist/docs/user-guide/working-with-vector-tiles/schema/streets/index.html +0 -3371
  178. package/dist/docs/user-guide/working-with-vector-tiles/schema/water_lines/index.html +0 -3708
  179. package/dist/docs/user-guide/working-with-vector-tiles/schema/water_polygons/index.html +0 -3477
  180. package/dist/docs/user-guide/working-with-vector-tiles/static/labels.png +0 -0
  181. package/dist/docs/user-guide/working-with-vector-tiles/static/topographic.png +0 -0
  182. package/dist/docs/user-guide/working-with-vector-tiles/static/topolite.png +0 -0
  183. package/dist/docs/user-guide/working-with-vector-tiles/styling/index.html +0 -2584
  184. package/dist/docs/user-guide/working-with-vector-tiles/styling/index.maplibre.vector.3857.html +0 -80
  185. package/dist/docs/user-guide/working-with-vector-tiles/styling/static/add-filter.webp +0 -0
  186. package/dist/docs/user-guide/working-with-vector-tiles/styling/static/contours.webp +0 -0
  187. package/dist/docs/user-guide/working-with-vector-tiles/styling/static/modify-paint.webp +0 -0
  188. package/dist/docs/user-guide/working-with-vector-tiles/usage/index.html +0 -2425
  189. package/dist/docs/user-guide/working-with-vector-tiles/usage/index.maplibre.vector.3857.html +0 -22
  190. package/dist/examples/index.html +0 -34
  191. package/dist/examples/index.leaflet.xyz.3857.html +0 -43
  192. package/dist/examples/index.maplibre.compare.3857.html +0 -111
  193. package/dist/examples/index.maplibre.elevation.3857.html +0 -100
  194. package/dist/examples/index.maplibre.opacity.3857.html +0 -218
  195. package/dist/examples/index.maplibre.vector.3857.html +0 -48
  196. package/dist/examples/index.openlayers.attribution.wmts.3857.html +0 -55
  197. package/dist/examples/index.openlayers.wmts.3857.html +0 -49
  198. package/dist/examples/index.openlayers.xyz.3857.html +0 -49
  199. package/dist/favicon-16x16.png +0 -0
  200. package/dist/favicon-32x32.png +0 -0
  201. package/dist/favicon.ico +0 -0
  202. package/dist/index-8.6.0-c101a024188933aa.js +0 -65922
  203. package/dist/index-8.6.0-c5e57c4593cca04a.css +0 -7686
  204. package/dist/index.css +0 -7686
  205. package/dist/index.html +0 -24
  206. package/dist/index.js +0 -65922
  207. package/dist/json-schema/stac-basemaps-extension/1.0/schema.json +0 -144
  208. package/dist/lib/attribution-8.6.0-7e26e43200746f3c.js +0 -10632
  209. package/dist/lib/attribution.js +0 -10632
@@ -1,22 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <script src='https://unpkg.com/maplibre-gl@4.5.0/dist/maplibre-gl.js'></script>
5
- <link href='https://unpkg.com/maplibre-gl@4.5.0/dist/maplibre-gl.css' rel='stylesheet' />
6
- <style>
7
- body { margin: 0; }
8
- #map { height: 100vh; width: 100vw; }
9
- </style>
10
- </head>
11
- <body>
12
- <div id="map"></div>
13
- <script>
14
- const map = new maplibregl.Map({
15
- container: 'map',
16
- style: 'https://basemaps.linz.govt.nz/v1/styles/topolite-v2.json?api=c01jwykec5weqkbr50vc30xwzgs',
17
- center: [174.7633, -36.8485],
18
- zoom: 10
19
- });
20
- </script>
21
- </body>
22
- </html>
@@ -1,34 +0,0 @@
1
- <!DOCTYPE html>
2
- <html lang="en">
3
-
4
- <head>
5
- <link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png" />
6
- <link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png" />
7
- <title>Basemaps Examples | Land Information New Zealand (LINZ)</title>
8
- </head>
9
-
10
- <body>
11
- <h1>Examples of accessing basemaps from a browser</h1>
12
- <p id="noApiKey" style="display:none">
13
- Please first visit <a href="/" >basemaps</a> to be automatically allocated a 90 day API key.
14
- </p>
15
- <ul>
16
- <li><a href="/examples/index.leaflet.xyz.3857.html">index.leaflet.xyz.3857.html</a></li>
17
- <li><a href="/examples/index.openlayers.attribution.wmts.3857.html">index.openlayers.attribution.wmts.3857.html</a></li>
18
- <li><a href="/examples/index.openlayers.wmts.3857.html">index.openlayers.wmts.3857.html</a></li>
19
- <li><a href="/examples/index.openlayers.xyz.3857.html">index.openlayers.xyz.3857.html</a></li>
20
- <li><a href="/examples/index.maplibre.elevation.3857.html">index.maplibre.elevation.3857.html</a></li>
21
- <li><a href="/examples/index.maplibre.vector.3857.html">index.maplibre.vector.3857.html</a></li>
22
- <li><a href="/examples/index.maplibre.compare.3857.html">index.maplibre.compare.3857.html</a></li>
23
- <li><a href="/examples/index.maplibre.opacity.3857.html">index.maplibre.opacity.3857.html</a></li>
24
- </ul>
25
- <p>
26
- Source code available at <a href="https://github.com/linz/basemaps">https://github.com/linz/basemaps</a>
27
- </p>
28
- <script>
29
- if (! localStorage.getItem("api-key")) {
30
- document.getElementById('noApiKey').style.display = "";
31
- }
32
- </script>
33
- </body>
34
- </html>
@@ -1,43 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <meta charset="UTF-8" />
5
- <title>Leaflet WGS84 Basemaps Demo</title>
6
- <link
7
- rel="stylesheet"
8
- href="https://unpkg.com/leaflet@1.6.0/dist/leaflet.css"
9
- />
10
- <script src="https://unpkg.com/leaflet@1.6.0/dist/leaflet.js"></script>
11
- <style>
12
- html,
13
- body {
14
- height: 100%;
15
- margin: 0;
16
- }
17
- </style>
18
- </head>
19
-
20
- <body>
21
- <div id="map" style="width: 600px; height: 400px;"></div>
22
- <script>
23
- const apiKey = localStorage.getItem('api-key');
24
- if (! apiKey) {
25
- throw new Error('Missing api-key in localStorage');
26
- }
27
-
28
- const startPos = [-40.5, 173];
29
- const startZoom = 6;
30
-
31
- const url = 'https://basemaps.linz.govt.nz/v1/tiles/aerial/EPSG:3857/{z}/{x}/{y}.webp?api='+apiKey;
32
-
33
- const tiles = L.tileLayer(url, {
34
- attribution: '<a href="https://www.linz.govt.nz/data/linz-data/linz-basemaps/data-attribution">LINZ CC BY 4.0 © Imagery Basemap contributors</a>'
35
- });
36
-
37
- L.map('map')
38
- .addLayer(tiles)
39
- .setView(startPos, startZoom);
40
-
41
- </script>
42
- </body>
43
- </html>
@@ -1,111 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <title>Maplibre WGS84 Swipe between raster and vector maps Demo</title>
6
- <meta name="viewport" content="initial-scale=1,maximum-scale=1,user-scalable=no" />
7
- <script
8
- src="https://api.mapbox.com/mapbox-gl-js/v2.3.0/mapbox-gl.js"
9
- integrity="sha384-jzJlE25T0D6awCZu40rkb9hFa6fxUC8/IN9wKY49uH9k/PP5efecoiru/RGCszy2"
10
- crossorigin="anonymous"
11
- ></script>
12
- <script
13
- src="https://unpkg.com/maplibre-gl@1.14.0-rc.1/dist/maplibre-gl.js"
14
- integrity="sha384-YAsv3Nk7n9hAR/gbvgvtGvq2TV1hvEpFks3bGIs451f9D0jSn070rHje6Swuo7bL"
15
- crossorigin="anonymous"
16
- ></script>
17
- <link href="https://unpkg.com/maplibre-gl@1.14.0-rc.1/dist/maplibre-gl.css" rel="stylesheet" />
18
- <script
19
- src="https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-compare/v0.4.0/mapbox-gl-compare.js"
20
- integrity="sha384-4vY2uVrBcMvF9vEZC0sp2hF66Ux2LY8PbIv23Mx1LQ1J+WyNUajJwqfiWVAIBUGA"
21
- crossorigin="anonymous"
22
- ></script>
23
- <link
24
- rel="stylesheet"
25
- href="https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-compare/v0.4.0/mapbox-gl-compare.css"
26
- type="text/css"
27
- />
28
- <style>
29
- body {
30
- margin: 0;
31
- padding: 0;
32
- overflow: hidden;
33
- }
34
-
35
- body * {
36
- -webkit-touch-callout: none;
37
- -webkit-user-select: none;
38
- -moz-user-select: none;
39
- -ms-user-select: none;
40
- user-select: none;
41
- }
42
-
43
- .map {
44
- position: absolute;
45
- top: 0;
46
- bottom: 0;
47
- width: 100%;
48
- }
49
- </style>
50
- </head>
51
- <body>
52
- <div id="comparison-container"></div>
53
- <div id="raster" class="map"></div>
54
- <div id="vector" class="map"></div>
55
- </div>
56
- <script>
57
- const apiKey = localStorage.getItem('api-key');
58
- if (!apiKey) {
59
- throw new Error('Missing api-key in localStorage');
60
- }
61
-
62
- // vector layers
63
- const styleUrl =
64
- 'https://basemaps.linz.govt.nz/v1/tiles/topographic/EPSG:3857/style/topographic.json?api=' + apiKey;
65
-
66
- // Raster layers
67
- const url = 'https://basemaps.linz.govt.nz/v1/tiles/aerial/EPSG:3857/{z}/{x}/{y}.webp?api=' + apiKey;
68
-
69
- const startPos = [173, -40.5];
70
- const startZoom = 6;
71
-
72
- var raster = new maplibregl.Map({
73
- container: 'raster', // Container ID
74
- style: {
75
- version: 8,
76
- sources: {
77
- 'raster-tiles': {
78
- type: 'raster',
79
- tiles: [url],
80
- tileSize: 256,
81
- },
82
- },
83
- layers: [
84
- {
85
- id: 'LINZ Raster Basemaps',
86
- type: 'raster',
87
- source: 'raster-tiles',
88
- },
89
- ],
90
- },
91
- center: startPos,
92
- zoom: startZoom,
93
- });
94
-
95
- var vector = new maplibregl.Map({
96
- container: 'vector', // Container ID
97
- style: styleUrl,
98
- center: startPos,
99
- zoom: startZoom,
100
- });
101
-
102
- // A selector or reference to HTML element
103
- var container = '#comparison-container';
104
-
105
- new mapboxgl.Compare(raster, vector, container, {
106
- mousemove: true, // Optional. Set to true to enable swiping during cursor movement.
107
- orientation: 'vertical', // Optional. Sets the orientation of swiper to horizontal or vertical, defaults to vertical
108
- });
109
- </script>
110
- </body>
111
- </html>
@@ -1,100 +0,0 @@
1
- <!doctype html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <title>Maplibre Elevation With Terrain-rgb Demo</title>
6
- <meta name="viewport" content="initial-scale=1,maximum-scale=1,user-scalable=no" />
7
- <script
8
- src="https://unpkg.com/maplibre-gl@4.0.1/dist/maplibre-gl.js"
9
- integrity="sha384-QjD9FqfhisGHV+cOv+EZTmWGaKkTJgx6gRP7pgmyQns3aWACZb18pTpxTmRRAaDF"
10
- crossorigin="anonymous"
11
- ></script>
12
- <link href="https://unpkg.com/maplibre-gl@4.0.1/dist/maplibre-gl.css" rel="stylesheet" />
13
- <style>
14
- body {
15
- margin: 0;
16
- padding: 0;
17
- }
18
-
19
- #map {
20
- position: absolute;
21
- top: 0;
22
- bottom: 0;
23
- width: 100%;
24
- }
25
- </style>
26
- </head>
27
-
28
- <body>
29
- <div id="map"></div>
30
- <script>
31
- const apiKey = localStorage.getItem('api-key');
32
- if (apiKey == null) throw new Error('Missing api-key in localStorage');
33
-
34
- var map = new maplibregl.Map({
35
- hash: true,
36
- center: [173, -40.5],
37
- zoom: 6,
38
- container: 'map', // container id
39
- style: {
40
- version: 8,
41
- sources: {
42
- osm: {
43
- type: 'raster',
44
- tiles: ['/v1/tiles/aerial/WebMercatorQuad/{z}/{x}/{y}.webp?api=' + apiKey],
45
- tileSize: 256,
46
- maxzoom: 22,
47
- },
48
- // Use a different source for terrain and hillshade layers, to improve render quality
49
- terrainSource: {
50
- type: 'raster-dem',
51
- tiles: ['/v1/tiles/elevation/WebMercatorQuad/{z}/{x}/{y}.png?pipeline=terrain-rgb&api=' + apiKey],
52
- tileSize: 256,
53
- },
54
- hillshadeSource: {
55
- type: 'raster-dem',
56
- tiles: ['/v1/tiles/elevation/WebMercatorQuad/{z}/{x}/{y}.png?pipeline=terrain-rgb&api=' + apiKey],
57
- tileSize: 256,
58
- },
59
- },
60
- layers: [
61
- {
62
- id: 'osm',
63
- type: 'raster',
64
- source: 'osm',
65
- },
66
- {
67
- id: 'hills',
68
- type: 'hillshade',
69
- source: 'hillshadeSource',
70
- layout: { visibility: 'visible' },
71
- paint: {
72
- 'hillshade-shadow-color': '#030303',
73
- 'hillshade-highlight-color': '#0c0c0c',
74
- 'hillshade-accent-color': '#dcdcdc',
75
- },
76
- },
77
- ],
78
- terrain: {
79
- source: 'terrainSource',
80
- exaggeration: 1,
81
- },
82
- },
83
- });
84
- map.addControl(
85
- new maplibregl.NavigationControl({
86
- visualizePitch: true,
87
- showZoom: true,
88
- showCompass: true,
89
- }),
90
- );
91
-
92
- map.addControl(
93
- new maplibregl.TerrainControl({
94
- source: 'terrainSource',
95
- exaggeration: 1,
96
- }),
97
- );
98
- </script>
99
- </body>
100
- </html>
@@ -1,218 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <title>Adjust a layer's opacity</title>
6
- <meta name="viewport" content="initial-scale=1,maximum-scale=1,user-scalable=no" />
7
- <script
8
- src="https://unpkg.com/maplibre-gl@1.14.0-rc.1/dist/maplibre-gl.js"
9
- integrity="sha384-YAsv3Nk7n9hAR/gbvgvtGvq2TV1hvEpFks3bGIs451f9D0jSn070rHje6Swuo7bL"
10
- crossorigin="anonymous"
11
- ></script>
12
- <link href="https://unpkg.com/maplibre-gl@1.14.0-rc.1/dist/maplibre-gl.css" rel="stylesheet" />
13
- <style>
14
- body {
15
- margin: 0;
16
- padding: 0;
17
- overflow: hidden;
18
- }
19
-
20
- body * {
21
- -webkit-touch-callout: none;
22
- -webkit-user-select: none;
23
- -moz-user-select: none;
24
- -ms-user-select: none;
25
- user-select: none;
26
- }
27
-
28
- .map {
29
- position: absolute;
30
- top: 0;
31
- bottom: 0;
32
- width: 100%;
33
- }
34
-
35
- .map-overlay {
36
- font: bold 12px/20px 'Helvetica Neue', Arial, Helvetica, sans-serif;
37
- position: absolute;
38
- width: 25%;
39
- top: 0;
40
- left: 0;
41
- padding: 10px;
42
- }
43
-
44
- .map-overlay .map-overlay-inner {
45
- background-color: #fff;
46
- box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
47
- border-radius: 3px;
48
- padding: 10px;
49
- margin-bottom: 10px;
50
- }
51
-
52
- .map-overlay label {
53
- display: block;
54
- margin: 0 0 10px;
55
- }
56
-
57
- .map-overlay input {
58
- background-color: transparent;
59
- display: inline-block;
60
- width: 100%;
61
- position: relative;
62
- margin: 0;
63
- cursor: ew-resize;
64
- }
65
- </style>
66
- </head>
67
- <body>
68
- <div id="raster" class="map"></div>
69
- <div id="vector" class="map"></div>
70
-
71
- <div class="map-overlay top">
72
- <div class="map-overlay-inner">
73
- <label>Layer opacity: <span id="slider-value">100%</span></label>
74
- <input id="slider" type="range" min="0" max="100" step="0" value="100" />
75
- </div>
76
- </div>
77
-
78
- <script>
79
- const apiKey = localStorage.getItem('api-key');
80
- if (!apiKey) {
81
- throw new Error('Missing api-key in localStorage');
82
- }
83
-
84
- // vector layers
85
- const styleUrl =
86
- 'https://basemaps.linz.govt.nz/v1/tiles/topographic/EPSG:3857/style/topographic.json?api=' + apiKey;
87
-
88
- // Raster layers
89
- const url = 'https://basemaps.linz.govt.nz/v1/tiles/aerial/EPSG:3857/{z}/{x}/{y}.webp?api=' + apiKey;
90
-
91
- const startPos = [173, -40.5];
92
- const startZoom = 6;
93
-
94
- var raster = new maplibregl.Map({
95
- container: 'raster', // Container ID
96
- style: {
97
- version: 8,
98
- sources: {
99
- 'raster-tiles': {
100
- type: 'raster',
101
- tiles: [url],
102
- tileSize: 256,
103
- },
104
- },
105
- layers: [
106
- {
107
- id: 'LINZ Raster Basemaps',
108
- type: 'raster',
109
- source: 'raster-tiles',
110
- },
111
- ],
112
- },
113
- center: startPos,
114
- zoom: startZoom,
115
- });
116
-
117
- var vector = new maplibregl.Map({
118
- container: 'vector', // Container ID
119
- style: styleUrl,
120
- center: startPos,
121
- zoom: startZoom,
122
- });
123
-
124
- var slider = document.getElementById('slider');
125
- var sliderValue = document.getElementById('slider-value');
126
-
127
- vector.on('load', function () {
128
- slider.addEventListener('input', function (e) {
129
- var vectorMap = document.querySelector('#vector');
130
- vectorMap.style.opacity = parseInt(e.target.value, 10) / 100;
131
- sliderValue.textContent = e.target.value + '%';
132
- });
133
- });
134
-
135
- // Copyright (c) 2016, Mapbox
136
- // https://github.com/mapbox/mapbox-gl-sync-move
137
- function moveToMapPosition(master, clones) {
138
- let center = master.getCenter();
139
- let zoom = master.getZoom();
140
- let bearing = master.getBearing();
141
- let pitch = master.getPitch();
142
-
143
- clones.forEach(function (clone) {
144
- clone.jumpTo({
145
- center: center,
146
- zoom: zoom,
147
- bearing: bearing,
148
- pitch: pitch,
149
- });
150
- });
151
- }
152
-
153
- // Sync movements of two maps.
154
- //
155
- // All interactions that result in movement end up firing
156
- // a "move" event. The trick here, though, is to
157
- // ensure that movements don't cycle from one map
158
- // to the other and back again, because such a cycle
159
- // - could cause an infinite loop
160
- // - prematurely halts prolonged movements like
161
- // double-click zooming, box-zooming, and flying
162
- function syncMaps() {
163
- let maps;
164
- let argLen = arguments.length;
165
- if (argLen === 1) {
166
- maps = arguments[0];
167
- } else {
168
- maps = [];
169
- for (let i = 0; i < argLen; i++) {
170
- maps.push(arguments[i]);
171
- }
172
- }
173
-
174
- // Create all the movement functions, because if they're created every time
175
- // they wouldn't be the same and couldn't be removed.
176
- let fns = [];
177
- maps.forEach(function (map, index) {
178
- fns[index] = sync.bind(
179
- null,
180
- map,
181
- maps.filter(function (o, i) {
182
- return i !== index;
183
- }),
184
- );
185
- });
186
-
187
- function on() {
188
- maps.forEach(function (map, index) {
189
- map.on('move', fns[index]);
190
- });
191
- }
192
-
193
- function off() {
194
- maps.forEach(function (map, index) {
195
- map.off('move', fns[index]);
196
- });
197
- }
198
-
199
- // When one map moves, we turn off the movement listeners
200
- // on all the maps, move it, then turn the listeners on again
201
- function sync(master, clones) {
202
- off();
203
- moveToMapPosition(master, clones);
204
- on();
205
- }
206
-
207
- on();
208
- return function () {
209
- off();
210
- fns = [];
211
- maps = [];
212
- };
213
- }
214
-
215
- syncMaps(raster, vector);
216
- </script>
217
- </body>
218
- </html>
@@ -1,48 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <title>Maplibre WGS84 Topographic Vector Basemaps Demo</title>
6
- <meta name="viewport" content="initial-scale=1,maximum-scale=1,user-scalable=no" />
7
- <script
8
- src="https://unpkg.com/maplibre-gl@1.14.0-rc.1/dist/maplibre-gl.js"
9
- integrity="sha384-YAsv3Nk7n9hAR/gbvgvtGvq2TV1hvEpFks3bGIs451f9D0jSn070rHje6Swuo7bL"
10
- crossorigin="anonymous"
11
- ></script>
12
- <link href="https://unpkg.com/maplibre-gl@1.14.0-rc.1/dist/maplibre-gl.css" rel="stylesheet" />
13
- <style>
14
- body {
15
- margin: 0;
16
- padding: 0;
17
- }
18
- #map {
19
- position: absolute;
20
- top: 0;
21
- bottom: 0;
22
- width: 100%;
23
- }
24
- </style>
25
- </head>
26
- <body>
27
- <div id="map"></div>
28
- <script>
29
- const apiKey = localStorage.getItem('api-key');
30
- if (!apiKey) {
31
- throw new Error('Missing api-key in localStorage');
32
- }
33
-
34
- const startPos = [173, -40.5];
35
- const startZoom = 6;
36
-
37
- // vector layers
38
- const style =
39
- 'https://basemaps.linz.govt.nz/v1/tiles/topographic/EPSG:3857/style/topographic.json?api=' + apiKey;
40
- var map = new maplibregl.Map({
41
- container: 'map', // container id
42
- style: style, // style URL
43
- center: startPos, // starting position [lng, lat]
44
- zoom: startZoom, // starting zoom
45
- });
46
- </script>
47
- </body>
48
- </html>
@@ -1,55 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
-
4
- <head>
5
- <meta charset="UTF-8" />
6
- <title>OpenLayers WMTS Basemaps Demo</title>
7
- <link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/openlayers/openlayers.github.io@master/en/v6.3.1/css/ol.css"
8
- type="text/css" />
9
- <script src="https://cdn.jsdelivr.net/gh/openlayers/openlayers.github.io@master/en/v6.3.1/build/ol.js"></script>
10
- <script src="../lib/attribution-8.6.0-7e26e43200746f3c.js" integrity="sha512-fibkMgB0bzx2rB2y2Ae0B3aywGWDyrtiVUWCjhqvV/EqSZTPb8nYape5tbhHlaCacPTsahfZ4thvPPMSyX6DzQ=="></script>
11
- </head>
12
-
13
- <body>
14
- <div id="map" style="width: 800px; height: 600px;"></div>
15
- <script>
16
- (async () => {
17
- const apiKey = localStorage.getItem('api-key');
18
- if (!apiKey) throw new Error('Missing api-key in localStorage');
19
-
20
- const projection = 'EPSG:3857';
21
- const baseUrl = 'https://basemaps.linz.govt.nz/v1/tiles/aerial/' + projection;
22
- const loadingWmts = fetch(baseUrl + '/WMTSCapabilities.xml?api=' + apiKey);
23
-
24
- const parser = new ol.format.WMTSCapabilities();
25
- const wmtsXml = parser.read(await (await loadingWmts).text());
26
- const options = ol.source.WMTS.optionsFromCapabilities(wmtsXml, {
27
- layer: 'aerial',
28
- matrixSet: projection,
29
- });
30
-
31
- const view = new ol.View({ center: [19467552, -5074414], zoom: 6, });
32
-
33
- const source = new ol.source.WMTS(options);
34
-
35
- const map = new ol.Map({
36
- target: 'map',
37
- layers: [new ol.layer.Tile({ source, projection })],
38
- controls: ol.control.defaults({ attributionOptions: { collapsed: false, collapsible: false } }),
39
- view,
40
- });
41
-
42
- const attributions = await BasemapsAttribution.load(baseUrl + '/attribution.json?api=' + apiKey);
43
- // Ignore the hillshade layers from attribution
44
- attributions.isIgnored = a => a.collection.title.toLowerCase().includes('geographx')
45
- map.addEventListener('moveend', () => {
46
- // Transform the extent into Lat/Long
47
- const extent = ol.proj.transformExtent(view.calculateExtent(), projection, 'EPSG:4326');
48
- const filtered = attributions.filter({ extent, zoom: view.getZoom() });
49
- source.setAttributions(attributions.renderList(filtered));
50
- });
51
- })();
52
- </script>
53
- </body>
54
-
55
- </html>
@@ -1,49 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <meta charset="UTF-8" />
5
- <title>OpenLayers WMTS Basemaps Demo</title>
6
- <link
7
- rel="stylesheet"
8
- href="https://cdn.jsdelivr.net/gh/openlayers/openlayers.github.io@master/en/v6.3.1/css/ol.css"
9
- type="text/css"
10
- />
11
- <script src="https://cdn.jsdelivr.net/gh/openlayers/openlayers.github.io@master/en/v6.3.1/build/ol.js"></script>
12
- </head>
13
-
14
- <body>
15
- <div id="map" style="width: 800px; height: 600px;"></div>
16
- <script>
17
- (async () => {
18
- const apiKey = localStorage.getItem('api-key');
19
- if (! apiKey) {
20
- throw new Error('Missing api-key in localStorage');
21
- }
22
-
23
- const projection = 'EPSG:3857';
24
- const baseUrl = 'https://basemaps.linz.govt.nz/v1/tiles/aerial/' + projection;
25
- const loadingWmts = fetch(baseUrl+'/WMTSCapabilities.xml?api='+apiKey);
26
-
27
- const parser = new ol.format.WMTSCapabilities();
28
- const wmtsXml = parser.read(await (await loadingWmts).text());
29
- const options = ol.source.WMTS.optionsFromCapabilities(wmtsXml, {
30
- layer: 'aerial',
31
- matrixSet: projection,
32
- });
33
-
34
- const source = new ol.source.WMTS(options);
35
- source.setAttributions('<a href="https://www.linz.govt.nz/data/linz-data/linz-basemaps/data-attribution">LINZ CC BY 4.0 © Imagery Basemap contributors</a>');
36
-
37
- new ol.Map({
38
- target: 'map',
39
- layers: [new ol.layer.Tile({ source, projection })],
40
- controls: ol.control.defaults({ attributionOptions: { collapsed: false, collapsible: false } }),
41
- view: new ol.View({
42
- center: [19467552, -5074414],
43
- zoom: 6,
44
- }),
45
- });
46
- })();
47
- </script>
48
- </body>
49
- </html>