@@ -89,6 +89,9 @@
watch: {
activeRasterData: {
handler(data) {
+ if (data.length === 0) {
+ return
+ }
const datasets = this.getDatasets
const meta = datasets[this.getActiveRasterLayer].metadata
const raster = datasets[this.getActiveRasterLayer].raster
diff --git a/components/disclaimer-modal.vue b/components/disclaimer-modal.vue
index f89c3623..6028482b 100644
--- a/components/disclaimer-modal.vue
+++ b/components/disclaimer-modal.vue
@@ -46,9 +46,6 @@
import UiCheckbox from './ui-checkbox.vue'
import UiButton from './ui-button.vue'
- import userAgreements from '~/assets/docs/user-agreements.md'
- import cookieAgreement from '~/assets/docs/cookie-agreements.md'
-
export default {
components: {
UiCheckbox,
@@ -59,8 +56,8 @@
data() {
return {
open: true,
- userAgreements: userAgreements.html,
- cookieAgreement: cookieAgreement.html,
+ userAgreements: '',
+ cookieAgreement: '',
agree: false,
cookie: false,
}
@@ -72,6 +69,23 @@
this.open = false
}
},
+ mounted() {
+ fetch('/docs/user-agreements.md')
+ .then(res => {
+ return res.text()
+ })
+ .then(response => {
+ this.userAgreements = response
+ })
+
+ fetch('/docs/cookie-agreements.md')
+ .then(res => {
+ return res.text()
+ })
+ .then(response => {
+ this.cookieAgreement = response
+ })
+ },
validations: {
cookie: {
required,
diff --git a/components/graph-line.vue b/components/graph-line.vue
index b8c54010..729d6a40 100644
--- a/components/graph-line.vue
+++ b/components/graph-line.vue
@@ -330,12 +330,13 @@
diff --git a/assets/docs/about-text.md b/static/docs/about-text.md
similarity index 69%
rename from assets/docs/about-text.md
rename to static/docs/about-text.md
index 882469d0..06422ba6 100644
--- a/assets/docs/about-text.md
+++ b/static/docs/about-text.md
@@ -1,13 +1,13 @@
-This is a beta release of the Blue Earth Data platform. The Blue Earth Data platform has been developed by Deltares as a free, web-based application to support the study and sharing of integrated water and subsoil-related data. The platform provides indicative data, which is primarily intended for professional specialists and researchers.
+This is a beta release of the Blue Earth Data platform. The Blue Earth Data platform has been developed by Deltares as a free, web-based application to support the study and sharing of integrated water and subsoil-related data. The platform provides indicative data, which is primarily intended for professional specialists and researchers.
-Users are presented with global water and subsoil-related data through use of our multi-data viewer. The datasets included are subdivided over different themes and areas of interest, which can be selected on the left side of the screen. The global data is grouped under the Flooding, Coastal Management and Offshore themes. These themes incorporate datasets for amongst others global shoreline changes, global bathymetry, global river discharge and storm surge forecasts and global metocean conditions. Additionally, some regional datasets are added for the North Sea. Further information with each dataset is provided through the data selection menu.
+Users are presented with global water and subsoil-related data through use of our multi-data viewer. The datasets included are subdivided over different themes and areas of interest, which can be selected on the left side of the screen. The global data is grouped under the Flooding, Coastal Management and Offshore themes. These themes incorporate datasets for amongst others global shoreline changes, global bathymetry, global river discharge and storm surge forecasts and global metocean conditions. Additionally, some regional datasets are added for the North Sea. Further information with each dataset is provided through the data selection menu.
-Datasets can be selected by using the selection menu on the right side of the screen. By activating the radial button, spatial maps can be enabled for each dataset. By activating the toggle button, time series can be enabled for each dataset at selected locations. If available at a location, time series for multiple datasets can be shown simultaneously. Furthermore, after registration the platform allows users to download selected data to the users device.
+Datasets can be selected by using the selection menu on the right side of the screen. By activating the radial button, spatial maps can be enabled for each dataset. By activating the toggle button, time series can be enabled for each dataset at selected locations. If available at a location, time series for multiple datasets can be shown simultaneously. Furthermore, after registration the platform allows users to download selected data to the users device.
-If you want to find out more about this initiative, please visit the [link WiKi](https://publicwiki.deltares.nl/display/BED).
+If you want to find out more about this initiative, please visit the [WiKi](https://publicwiki.deltares.nl/display/BED).
-Your feedback will help us to further improve Blue Earth Data. To provide your feedback, please use the following [link form](https://forms.gle/qaNHX1CCkGhf5m7i6).
+Your feedback will help us to further improve Blue Earth Data. To provide your feedback, please use the following [form](https://forms.gle/qaNHX1CCkGhf5m7i6).
For further questions regarding the platform or the datasets included, please contact us at dataservices@deltares.nl.
-Deltares values your privacy. Our general Privacy Statement can be found [link here]( https://oss.deltares.nl/web/delft-fews/privacy-declaration).
+Deltares values your privacy. Our general Privacy Statement can be found [here](https://oss.deltares.nl/web/delft-fews/privacy-declaration).
diff --git a/assets/docs/cookie-agreements.md b/static/docs/cookie-agreements.md
similarity index 97%
rename from assets/docs/cookie-agreements.md
rename to static/docs/cookie-agreements.md
index 195a4f09..3e9001e2 100644
--- a/assets/docs/cookie-agreements.md
+++ b/static/docs/cookie-agreements.md
@@ -6,4 +6,4 @@ Deltares uses two types of cookies for this website: functional cookies and anal
The functional cookies are used to identify you for the duration of your session, and are needed to make the website work properly. The session cookie is removed by your browser after you close your browser.
-The analytical cookies in anonymous mode are used to measure your and other visitors’ use of this website, for purposes of improving the website. Your IP address is anonymized so that it is never stored or written to disk. For more information, please see the Google Analytics’ Privacy Overview and Google Analytics Cookie Usage on Websites.
+The analytical cookies in anonymous mode are used to measure your and other visitors’ use of this website, for purposes of improving the website. Your IP address is anonymized so that it is never stored or written to disk. For more information, please see the Google Analytics’ Privacy Overview and Google Analytics Cookie Usage on Websites.
diff --git a/assets/docs/user-agreements.md b/static/docs/user-agreements.md
similarity index 100%
rename from assets/docs/user-agreements.md
rename to static/docs/user-agreements.md
diff --git a/test/unit/lib/mapbox/layers/get-spatial-layer.spec.js b/test/unit/lib/mapbox/layers/get-spatial-layer.spec.js
index f3039cc1..1068e9d9 100644
--- a/test/unit/lib/mapbox/layers/get-spatial-layer.spec.js
+++ b/test/unit/lib/mapbox/layers/get-spatial-layer.spec.js
@@ -35,7 +35,7 @@ describe('add', () => {
type: 'raster',
},
})
- expect(mapbox.addLayer.mock.calls[0][1]).toBe('background-features')
+ expect(mapbox.addLayer.mock.calls[0][1]).toBe('water-border')
})
test('dont add when tiles are empty', () => {
const mapbox = {
@@ -66,7 +66,7 @@ describe('update', () => {
rasterLayer.update(mapbox)
expect(removeLayer).toHaveBeenCalledWith('raster')
expect(removeSource).toHaveBeenCalledWith('raster')
- expect(addLayer).toHaveBeenCalledWith(rasterLayer, 'background-features')
+ expect(addLayer).toHaveBeenCalledWith(rasterLayer, 'water-border')
})
test('do not remove layer when its not defined in mapbox', () => {
@@ -84,7 +84,7 @@ describe('update', () => {
rasterLayer.update(mapbox)
expect(removeLayer).not.toHaveBeenCalledWith('raster')
expect(removeSource).not.toHaveBeenCalledWith('raster')
- expect(addLayer).toHaveBeenCalledWith(rasterLayer, 'background-features')
+ expect(addLayer).toHaveBeenCalledWith(rasterLayer, 'water-border')
})
test('do not add new layer when tiles are empty', () => {