@piveau/piveau-hub-ui-modules 4.6.53 → 4.6.55
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.
- package/dist/datasetDetails/DatasetDetailsDataset.vue.mjs +1 -1
- package/dist/datasetDetails/DatasetDetailsDataset.vue.mjs.map +1 -1
- package/dist/datasetDetails/DatasetDetailsDataset.vue2.mjs +56 -44
- package/dist/datasetDetails/DatasetDetailsDataset.vue2.mjs.map +1 -1
- package/dist/piveau-hub-ui-modules.css +1 -1
- package/dist/services/catalogService.mjs +10 -10
- package/dist/services/catalogService.mjs.map +1 -1
- package/dist/store/modules/datasetDetailsStore.mjs +9 -3
- package/dist/store/modules/datasetDetailsStore.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -109,7 +109,7 @@ function _(s, t, o, C, i, e) {
|
|
|
109
109
|
]))
|
|
110
110
|
]);
|
|
111
111
|
}
|
|
112
|
-
const T = /* @__PURE__ */ k(I, [["render", _], ["__scopeId", "data-v-
|
|
112
|
+
const T = /* @__PURE__ */ k(I, [["render", _], ["__scopeId", "data-v-a79787c5"]]);
|
|
113
113
|
export {
|
|
114
114
|
T as default
|
|
115
115
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DatasetDetailsDataset.vue.mjs","sources":["../../lib/datasetDetails/DatasetDetailsDataset.vue"],"sourcesContent":["<template>\n <div>\n <resource-access-popup ref=\"externalResourceModal\" />\n <span property=\"dc:issued\" :content=\"getReleaseDate\"></span>\n <span property=\"dc:modified\" :content=\"getModificationDate\"></span>\n <div v-if=\"loadingDatasetDetails\">\n <dataset-details-skeleton type=\"DatasetDetails\"></dataset-details-skeleton>\n </div>\n <div v-if=\"!loadingDatasetDetails\" class=\"dsd-dataset\">\n <dataset-details-description\n v-if=\"showDatasetDescription\"\n :dateIncorrect=\"dateIncorrect\"\n :machineTranslated=\"machineTranslated\"\n :translationNotAvailable=\"translationNotAvailable\"\n />\n <distributions\n :openModal=\"openModal\"\n :getDistributions=\"getDistributions\"\n :expandedDistributions=\"expandedDistributions\"\n :expandedDistributionDescriptions=\"expandedDistributionDescriptions\"\n :displayedDistributions=\"displayedDistributions\"\n :isDistributionsAllDisplayed=\"isDistributionsAllDisplayed\"\n :distributions=\"distributions\"\n :setDistributionsDisplayCount=\"setDistributionsDisplayCount\"\n :pages=\"pages\"\n :showDownloadUrls=\"showDownloadUrls\"\n :isOnlyOneUrl=\"isOnlyOneUrl\"\n :getDistributionFormat=\"getDistributionFormat\"\n :distributionFormatTruncated=\"distributionFormatTruncated\"\n :getDistributionTitle=\"getDistributionTitle\"\n :distributionVisibleContent=\"distributionVisibleContent\"\n :distributionExpandedContent=\"distributionExpandedContent\"\n :distributionDescriptionIsExpanded=\"distributionDescriptionIsExpanded\"\n :distributionDescriptionIsExpandable=\"distributionDescriptionIsExpandable\"\n :distributionIsExpanded=\"distributionIsExpanded\"\n :showNumber=\"showNumber\"\n :showObject=\"showObject\"\n :showDownloadDropdown=\"showDownloadDropdown\"\n :showLicence=\"showLicence\"\n :showLicensingAssistant=\"showLicensingAssistant\"\n :filterDateFormatEU=\"filterDateFormatEU\"\n :showArray=\"showArray\"\n :showObjectArray=\"showObjectArray\"\n :getVisualisationLink=\"getVisualisationLink\"\n :getDownloadUrl=\"getDownloadUrl\"\n :trackGoto=\"trackGoto\"\n :showAccessUrls=\"showAccessUrls\"\n :replaceHttp=\"replaceHttp\"\n :previewLinkCallback=\"previewLinkCallback\"\n :toggleDistribution=\"toggleDistribution\"\n :toggleDistributionDescription=\"toggleDistributionDescription\"\n :increaseNumDisplayedDistributions=\"increaseNumDisplayedDistributions\"\n :nonOverflowingIncrementsForDistributions=\"nonOverflowingIncrementsForDistributions\"\n :appendCurrentLocaleToURL=\"appendCurrentLocaleToURL\"\n :isUrlInvalid=\"isUrlInvalid\"\n :openIfValidUrl=\"openIfValidUrl\"\n :showTooltipVisualiseButton=\"showTooltipVisualiseButton\"\n :showPublisher=\"showPublisher\"\n :embed=\"embed\"\n />\n <dataset-details-features\n :getKeywords=\"getKeywords\"\n :pages=\"pages\"\n :increaseNumDisplayedPages=\"increaseNumDisplayedPages\"\n :nonOverflowingIncrementsForPages=\"nonOverflowingIncrementsForPages\"\n :showKeyword=\"showKeyword\"\n :trackGoto=\"trackGoto\"\n :showObjectArray=\"showObjectArray\"\n :showArray=\"showArray\"\n :showObject=\"showObject\"\n />\n <dataset-details-properties v-if=\"showDatasetProperties\">\n <template #property-header><slot name=\"property-header\"></slot></template>\n <template #property-table-before><slot name=\"property-table-before\"></slot></template>\n <template #property-table><slot name=\"property-table\"></slot></template>\n <template #property-table-after><slot name=\"property-table-after\"></slot></template>\n </dataset-details-properties>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\">\n // @ts-nocheck\n /* eslint-disable no-confusing-arrow, no-nested-ternary, no-return-assign, no-confusing-arrow */\n import $ from 'jquery';\n import { mapActions, mapGetters } from 'vuex';\n import {\n has,\n isNil,\n isArray,\n isObject,\n isString,\n isNumber,\n isEmpty,\n } from 'lodash';\n import AppLink from '../widgets/AppLink.vue';\n import Tooltip from '../widgets/Tooltip.vue';\n import Distributions from './distributions/Distributions.vue';\n import dateFilters from '../filters/dateFilters';\n import {\n getTranslationFor, getCountryFlagImg, truncate, replaceHttp, appendCurrentLocaleToURL\n } from '../utils/helpers';\n import ResourceAccessPopup from '../widgets/ResourceAccessPopup.vue';\n import DatasetDetailsExtendedMetaData\n from \"../datasetDetails/features/DatasetDetailsIsUsedBy.vue\";\n import DatasetDetailsSkeleton from \"../datasetDetails/DatasetDetailsSkeleton.vue\";\n import * as metaInfo from '../composables/head';\n\n export default {\n name: 'datasetDetailsDataset',\n components: {\n DatasetDetailsSkeleton,\n DatasetDetailsExtendedMetaData,\n AppLink,\n Tooltip,\n Distributions,\n ResourceAccessPopup\n },\n props: {\n distributionVisibleContent: {\n type: Array,\n default: () => ['license', 'licenseAttributionByText', 'modificationDate'],\n },\n distributionExpandedContent: {\n type: Array,\n default: () => [\n 'releaseDate',\n 'language',\n 'availability',\n 'status',\n 'rights',\n 'mediaType',\n 'byteSize',\n 'checksum',\n 'pages',\n 'type',\n 'compressFormat',\n 'packageFormat',\n 'hasPolicy',\n 'conformsTo',\n 'spatialResolutionInMeters',\n 'temporalResolution',\n ],\n },\n showDatasetDescription: {\n type: Boolean,\n default: () => true,\n },\n showDatasetProperties: {\n type: Boolean,\n default: () => true,\n },\n showPublisher: {\n type: Boolean,\n default: () => false,\n },\n embed: {\n type: Boolean,\n default: () => false,\n },\n },\n data() {\n return {\n defaultLocale: this.$env.languages.locale,\n // has to be INITIAL_DATASET_DESCRIPTION_LENGTH\n isDatasetDescriptionExpanded: false,\n loadingDatasetDetails: false,\n machineTranslated: false,\n translationNotAvailable: false,\n expandedDistributions: [],\n expandedDistributionDescriptions: [],\n distributions: {\n displayAll: this.$env.content.datasetDetails.distributions.displayAll,\n displayCount: this.$env.content.datasetDetails.distributions.displayCount,\n incrementSteps: this.$env.content.datasetDetails.distributions.incrementSteps,\n descriptionMaxLines: this.$env.content.datasetDetails.distributions.descriptionMaxLines,\n descriptionMaxChars: this.$env.content.datasetDetails.distributions.descriptionMaxChars,\n licencingAssistantUrl: this.$env.content.datasetDetails.distributions.licencingAssistantUrl,\n },\n pages: {\n isVisible: this.$env.content.datasetDetails.pages.isVisible,\n displayAll: this.$env.content.datasetDetails.pages.displayAll,\n displayCount: this.$env.content.datasetDetails.pages.displayCount,\n incrementSteps: this.$env.content.datasetDetails.pages.incrementSteps,\n descriptionMaxLines: this.$env.content.datasetDetails.pages.descriptionMaxLines,\n descriptionMaxChars: this.$env.content.datasetDetails.pages.descriptionMaxChars,\n },\n showDescription: true,\n };\n },\n computed: {\n // import store-getters\n ...mapGetters('datasetDetails', [\n 'getKeywords',\n 'getAccessRights',\n 'getAccrualPeriodicity',\n 'getCatalog',\n 'getContactPoints',\n 'getDateIncorrect',\n 'getDescription',\n 'getDistributions',\n 'getID',\n 'getLanguages',\n 'getLicences',\n 'getModificationDate',\n 'getOtherIdentifiers',\n 'getPages',\n 'getPublisher',\n 'getReleaseDate',\n 'getSpatial',\n 'getTranslationMetaData',\n 'getTitle',\n 'getIsHvd',\n 'getHvdCategories',\n 'getCountry',\n 'getCategories',\n ]),\n dateIncorrect() {\n return this.getDateIncorrect;\n },\n displayedDistributions() {\n const sorted = [...this.getDistributions].sort((a, b) => {\n if (getTranslationFor(a.title, this.$route.query.locale, this.getLanguages) < getTranslationFor(b.title, this.$route.query.locale, this.getLanguages)) { return -1; }\n if (getTranslationFor(a.title, this.$route.query.locale, this.getLanguages) > getTranslationFor(b.title, this.$route.query.locale, this.getLanguages)) { return 1; }\n return 0;\n });\n return this.distributions.displayAll\n ? Object.freeze(sorted)\n : Object.freeze(sorted.slice(0, this.distributions.displayCount));\n },\n isDistributionsAllDisplayed() {\n return this.distributions.displayCount === this.getDistributions.length;\n },\n remainingDistributions() {\n return this.getDistributions.length - this.distributions.displayCount;\n }\n },\n methods: {\n ...mapActions('datasetDetails', [\n 'loadDatasetDetails',\n 'setLoading',\n ]),\n has,\n isNil,\n isArray,\n isObject,\n isString,\n isNumber,\n appendCurrentLocaleToURL,\n getTranslationFor,\n getCountryFlagImg,\n truncate,\n replaceHttp,\n initDatasetDetails() {\n this.piwikMetaPush();\n setTimeout(() => {\n if (typeof this.$piwik?.resume === \"function\") this.$piwik.resume();\n }, 500);\n this.$nextTick(() => {\n // Display/hide translation banners\n this.setTranslationBanners();\n $('[data-toggle=\"tooltip\"]').tooltip({\n container: 'body',\n });\n });\n },\n setDistributionsDisplayCount(count: number) {\n this.distributions.displayCount = count;\n },\n openModal(callback, toggleDownloadPopup) {\n this.$refs.externalResourceModal.openModal(callback, toggleDownloadPopup)\n },\n previewLinkCallback(distribution) {\n return () => {\n this.$emit('track-link', this.getVisualisationLink(distribution), 'link');\n window.open(this.getVisualisationLink(distribution), '_blank');\n };\n },\n filterDateFormatEU(date) {\n return dateFilters.formatEU(date);\n },\n /* ABSTRACT SHOW FUNCTIONS */\n showString(string) {\n return !isNil(string) && isString(string);\n },\n showNumber(number) {\n return !isNil(number) && isNumber(number);\n },\n showObject(object) {\n return !isNil(object) && isObject(object) && !Object.values(object).reduce((keyUndefined, currentValue) => keyUndefined && currentValue === undefined, true);\n },\n showArray(array) {\n return !isNil(array) && isArray(array) && array.length > 0;\n },\n showObjectArray(objectArray) {\n return this.showArray(objectArray) && !objectArray.reduce((objectUndefined, currentObject) => objectUndefined && Object.values(currentObject).reduce((keyUndefined, currentValue) => keyUndefined && currentValue === undefined, true), true);\n },\n /* SPECIFIC SHOW FUNCTIONS */\n /* for now show all licences */\n showLicence(licence) {\n // return (has(licence, 'id') && !isNil(licence.id))\n // || (has(licence, 'label') && !isNil(licence.label))\n return true\n },\n showLicensingAssistant(distribution) {\n return has(distribution, 'licence.la_url') && this.showString(distribution.licence.la_url);\n },\n showDownloadDropdown(distribution) {\n return this.showAccessUrls(distribution) || this.showDownloadUrls(distribution);\n },\n isOnlyOneUrl(distribution) {\n return (this.showAccessUrls(distribution) && !this.showDownloadUrls(distribution))\n || (!this.showAccessUrls(distribution) && this.showDownloadUrls(distribution) && distribution.downloadUrls.length === 1);\n },\n getDownloadUrl(distribution) {\n let url;\n if (this.showAccessUrls(distribution) && !this.showDownloadUrls(distribution)) {\n url = distribution.accessUrl[0];\n }\n if (!this.showAccessUrls(distribution) && this.showDownloadUrls(distribution) && distribution.downloadUrls.length === 1) {\n url = distribution.downloadUrls[0];\n }\n return url;\n },\n showAccessUrls(distribution) {\n return has(distribution, 'accessUrl') && this.showArray(distribution.accessUrl);\n },\n showDownloadUrls(distribution) {\n return has(distribution, 'downloadUrls') && this.showArray(distribution.downloadUrls);\n },\n showKeyword(keyword) {\n return has(keyword, 'id')\n && has(keyword, 'title')\n && !isNil(keyword.id)\n && !isNil(keyword.title);\n },\n\n /* GETTER / SETTER FUNCTIONS */\n\n setDatasetOriginalLanguage(originalLanguage) {\n this.$i18n.locale = originalLanguage;\n },\n distributionIsExpanded(id) {\n setTimeout(() => {\n $('[data-toggle=\"tooltip\"]').tooltip({\n container: 'body',\n });\n }, 500);\n return this.expandedDistributions.includes(id);\n },\n distributionDescriptionIsExpanded(id) {\n return this.expandedDistributionDescriptions.includes(id);\n },\n distributionDescriptionIsExpandable(description) {\n return isNil(description) ? false : description.length > this.distributions.descriptionMaxChars;\n },\n getDistributionFormat(distribution) {\n return has(distribution, 'format.label') && !isNil(distribution.format.label) ? distribution.format.label : '';\n },\n distributionFormatTruncated(distribution) {\n return this.getDistributionFormat(distribution).length > 4;\n },\n getDistributionTitle(distribution) {\n return distribution.title\n ? getTranslationFor(distribution.title, this.$route.query.locale, this.getLanguages)\n : this.getID || '-';\n },\n getVisualisationLink(distribution) {\n // Return Visualisation Link\n const accessUrl = distribution.downloadUrls && distribution.downloadUrls.length ? distribution.downloadUrls[0] : distribution.accessUrl[0];\n return `/data/visualisation/?file=${encodeURIComponent(accessUrl)}`;\n },\n // getSubjectLink(subject) {\n // return { path: `/datasets?subject=${subject.id}`, query: Object.assign({}, { locale: this.$route.query.locale }) };\n // },\n toggleDistribution(id) {\n const index = this.expandedDistributions.indexOf(id);\n if (index > -1) this.expandedDistributions.splice(index, 1);\n else this.expandedDistributions.push(id);\n },\n toggleDistributionDescription(id) {\n const index = this.expandedDistributionDescriptions.indexOf(id);\n if (index > -1) this.expandedDistributionDescriptions.splice(index, 1);\n else this.expandedDistributionDescriptions.push(id);\n },\n setTranslationBanners() {\n if (!this.$i18n) return;\n const translationMetaData = this.getTranslationMetaData;\n // Check if translation of dataset is available in selected language\n if (!isNil(translationMetaData.details) && has(translationMetaData.details, this.$route.query.locale)) {\n // Check if dataset if machine translated\n this.machineTranslated = translationMetaData.details[this.$route.query.locale].machine_translated;\n } else {\n // No translation of this dataset available for the selected language\n this.translationNotAvailable = true;\n }\n },\n // Emit a Matomo event when user clicks on 'go to resource' element\n trackGoto() {\n const paq = window._paq || []; // eslint-disable-line\n // paq.push(['trackEvent', 'GoToResource', 'Clicked']);\n this.$piwik.trackGotoResource();\n },\n clamp(n, min, max) {\n return Math.min(Math.max(n, min), max);\n },\n // Increases the current number of distributions displayed\n // and clamps the result so that it never exceeds the number of all distributions.\n increaseNumDisplayedDistributions(increment) {\n const clampedSum = this.clamp(this.distributions.displayCount + increment, 0, this.getDistributions.length);\n this.distributions.displayCount = clampedSum;\n },\n nonOverflowingIncrementsForDistributions(incrementStep) {\n return this.distributions.displayCount + incrementStep <= this.getDistributions.length;\n },\n // Increases the current number of distributions displayed\n // and clamps the result so that it never exceeds the number of all distributions.\n increaseNumDisplayedPages(increment) {\n const clampedSum = this.clamp(this.pages.displayCount + increment, 0, this.getPages.length);\n this.pages.displayCount = clampedSum;\n },\n nonOverflowingIncrementsForPages(incrementStep) {\n return this.pages.displayCount + incrementStep <= this.getPages.length;\n },\n piwikMetaPush() {\n this.$piwik.trackDatasetDetailsPageView(null, null, {\n dataset_AccessRights: this.getAccessRights,\n dataset_AccrualPeriodicity: this.getAccrualPeriodicity,\n dataset_Catalog: this.getCatalog,\n // dataset_Categories: this.getCategories,\n // dataset_ConformsTo: this.getConformsTo,\n // dataset_ContactPoints: this.getContactPoints,\n // dataset_Country: this.getCountry,\n // dataset_Creator: this.getCreator,\n // dataset_Description: this.getDescription,\n // dataset_Distributions: this.getDistributions,\n // dataset_DistributionFormats: this.getDistributionFormats,\n // dataset_Documentations: this.getDocumentations,\n // dataset_Frequency: this.getFrequency,\n // dataset_HasVersion: this.getHasVersion,\n dataset_ID: this.getID,\n // dataset_Identifiers: this.getIdentifiers,\n // dataset_IdName: this.getIdName,\n // dataset_IsVersionOf: this.getIsVersionOf,\n // datest_Keywords: this.getKeywords,\n // dataset_LandingPages: this.getLandingPagesResource,\n // dataset_Languages: this.getLanguages,\n // dataset_Licences: this.getLicences,\n // dataset_Loading: this.getLoading,\n // dataset_ModificationDate: this.getModificationDate,\n // dataset_OriginalLanguage: this.getOriginalLanguage,\n // dataset_OtherIdentifiers: this.getOtherIdentifiers,\n // dataset_Pages: this.getPages,\n // dataset_Provenances: this.getProvenances,\n dataset_Publisher: this.getPublisher,\n // dataset_RelatedResources: this.getRelatedResources,\n // dataset_ReleaseDate: this.getReleaseDate,\n // dataset_Sources: this.getSources,\n // dataset_Spatial: this.getSpatial,\n // dataset_SpatialResource: this.getSpatialResource,\n // dataset_Temporal: this.getTemporal,\n dataset_Title: this.getTitle,\n // dataset_TranslationMetaData: this.getTranslationMetaData,\n // dataset_VersionInfo: this.getVersionInfo,\n // dataset_VersionNotes: this.getVersionNotes,\n dataset_type: this.getIsHvd ? 'High-Value Dataset' : 'Dataset',\n dataset_scope: this.getCountry?.id === 'io'\n ? 'International Data'\n : this.getCountry?.id === 'eu'\n ? 'European Union Data'\n : 'National Data',\n dataset_provenance: this.getCountry?.name || this.getCountry?.id || '',\n dataset_category: this.getCategories?.map(category => category.label?.en || category.id).filter(Boolean)\n\n });\n },\n isUrlInvalid(url) {\n if (url) {\n try {\n /* eslint-disable no-useless-escape */\n return !(new RegExp(\"^((https?:\\/\\/(www\\.)?)([-a-zA-Z0-9@:%._\\+~#=]{1,256})([-a-zA-Z0-9()@:%_\\+.~#?&//=]*))$\", \"i\")).test(decodeURIComponent(url.split(\"=\").pop()));\n /* eslint-enable no-useless-escape */\n } catch (e) {\n console.error(e);\n }\n }\n },\n openIfValidUrl(isValid, previewLinkCallback, distribution, event) {\n if (isValid) {\n // for (let key in this.$children) {\n // if(this.$children[key].$refs[\"externalResourceModal\"]) {\n // this.$children[key].$refs[\"externalResourceModal\"].openModal(previewLinkCallback(distribution), false);\n // }\n // }\n this.openModal(previewLinkCallback(distribution), false);\n } else {\n event.preventDefault();\n event.stopPropagation();\n }\n },\n showTooltipVisualiseButton(invalidUrl) {\n if (invalidUrl) {\n return this.$t('message.tooltip.invalidVisualise');\n }\n return ''\n },\n },\n mounted() {\n // Duplicated API call, execute only if data not already loaded\n if (this.$route.params.ds_id !== this.getID) {\n this.$Progress.start();\n this.loadingDatasetDetails = true;\n this.loadDatasetDetails(this.$route.params.ds_id)\n .then(() => {\n this.$Progress.finish();\n this.loadingDatasetDetails = false;\n this.initDatasetDetails();\n })\n .catch((err) => {\n console.warn(err); // eslint-disable-line\n this.$Progress.fail();\n if (typeof this.$piwik?.resume === \"function\") this.$piwik.resume();\n this.$router.replace({\n name: 'NotFound',\n query: { locale: this.$route.query.locale, dataset: this.$route.params.ds_id },\n });\n })\n .finally(() => this.$root.$emit('contentLoaded'));\n } else {\n this.initDatasetDetails();\n this.$root.$emit('contentLoaded')\n }\n\n const distributionsConf = this.$env.content.datasetDetails && this.$env.content.datasetDetails.distributions;\n if (distributionsConf) {\n this.distributions.displayAll = distributionsConf.displayAll || this.distributions.displayAll;\n this.distributions.displayCount = parseInt(distributionsConf.displayCount, 10) || this.distributions.displayCount;\n\n if (typeof distributionsConf.incrementSteps === 'string') {\n // Need to parse as json array since env variables are string only\n distributionsConf.incrementSteps = JSON.parse(distributionsConf.incrementSteps);\n }\n this.distributions.incrementSteps = distributionsConf.incrementSteps || this.distributions.incrementSteps;\n }\n\n if (this.distributions.displayAll) this.distributions.displayCount = this.getDistributions.length;\n\n const pagesConf = this.$env.content.datasetDetails && this.$env.content.datasetDetails.pages;\n if (pagesConf) {\n this.pages.displayAll = pagesConf.displayAll || this.pages.displayAll;\n this.pages.displayCount = parseInt(pagesConf.displayCount, 10) || this.pages.displayCount;\n\n if (typeof pagesConf.incrementSteps === 'string') {\n // Need to parse as json array since env variables are string only\n pagesConf.incrementSteps = JSON.parse(pagesConf.incrementSteps);\n }\n this.pages.incrementSteps = pagesConf.incrementSteps || this.pages.incrementSteps;\n }\n\n if (this.pages.displayAll) this.pages.displayCount = this.getPages.length;\n },\n beforeUnmount() {\n $('.tooltip').remove();\n },\n setup() {\n metaInfo.useDatasetDetailsDatasetHead();\n }\n };\n</script>\n\n<style lang=\"scss\" scoped>\n\n .catalogue-label {\n white-space: pre-line;\n }\n\n .cursor-pointer {\n cursor: pointer;\n }\n\n .tag-color {\n background-color: var(--tag-color);\n }\n\n .btn-color {\n &:hover {\n background-color: #196fd2;\n border-color: #196fd2;\n }\n }\n\n .heading, .arrow, .copy-text {\n cursor: pointer;\n }\n\n .details-link {\n cursor: pointer;\n\n &:hover {\n text-decoration: underline;\n }\n }\n\n .text-break {\n word-break: break-word;\n }\n\n td {\n padding-left: 0 !important;\n padding-top: 1% !important;\n padding-bottom: 1% !important;\n }\n\n .download-all-btn {\n min-width: 100px;\n height: 31px;\n }\n\n .d-inline-table {\n display: inline-table;\n }\n\n /*** BOOTSTRAP ***/\n button:focus {\n outline:0;\n }\n .options, .download {\n .dropdown-menu {\n .dropdown-item {\n &:hover {\n color: initial;\n background-color: initial;\n }\n }\n }\n }\n.spinner-grow {\n width: 20px;\n height: 20px;\n}\n\n /*** FONT AWESOME ICONS ***/\n .fa-check-square {\n color: #28a745;\n width: 16px;\n height: 16px;\n }\n\n /*** MATERIAL ICONS ***/\n %modal-icon {\n font-size: 18px;\n cursor: default;\n }\n\n .help-icon {\n @extend %modal-icon;\n }\n\n .check-icon {\n @extend %modal-icon;\n color: #28a745;\n }\n\n .material-icons.small-icon {\n font-size: 20px;\n }\n\n .distributions {\n\n &__item {\n position: relative;\n\n &--preview {\n width: 100%;\n height: 100%;\n position: absolute;\n top: 0;\n left: 0;\n background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, white 55%);\n z-index: 10;\n }\n }\n\n &__actions {\n display: flex;\n justify-content: center;\n align-items: flex-end;\n height: 100%;\n z-index: 11;\n }\n }\n .mt-4 {\n margin-top: 1.5rem !important;\n }\n\n .keywords {\n\n &__item {\n position: relative;\n }\n\n &__actions {\n display: flex;\n justify-content: center;\n align-items: flex-end;\n height: 100%;\n z-index: 11;\n }\n }\n .sectionList {\n list-style-type: '→ ';\n margin-left:6.5%;\n }\n @media only screen and (max-width: 991px) {\n .sectionList {\n margin-left: 0;\n }\n}\n</style>\n"],"names":["_hoisted_1","_hoisted_3","_hoisted_4","_component_dataset_details_properties","_resolveComponent","_openBlock","_createElementBlock","_createVNode","_component_resource_access_popup","_cache","_createTextVNode","getReleaseDate","_ctx","getModificationDate","_hoisted_2","$data","_component_dataset_details_skeleton","_createCommentVNode","$props","_createBlock","_component_dataset_details_description","$options","_component_distributions","getDistributions","getKeywords","_component_dataset_details_features","_withCtx","_renderSlot"],"mappings":";;;;AAAA,MAAAA,IAAA,CAAA,SAAA,oBAAAC,IAAA,EAAA,KAAA,KAQuCC,IAAM;AAAA,EAAA,KAAA;AAAA;;;4KAsErCC,IAAAC,EAAA,4BAAA;AA9ER,SAAAC,EAAA,GAAAC,EAAA,OAAA,MAAA;AAAA,IAGIC,EAA4DC,GAAA,EAAA,KAAA,wBAAA,GAAA,MAAA,GAAA;AAAA,IAAAC,EAAtD,OAASA,EAAW,CAAA,IAAAC,EAAA;AAAA,IAAWC,EAAAA,QAAAA;AAAAA,MAHzC,UAAA;AAAA,MAAA,SAAAC,EAAA;AAAA,OAIuE,MAAA,GAAAZ,CAAA;AAAA,IAAAS,EAA7D,OAASA,EAAa,CAAA,IAAAC,EAAA;AAAA,IAAWG,EAAAA,QAAAA;AAAAA,MAJ3C,UAAA;AAAA,MAAA,SAAAD,EAAA;AAAA,IAKe,GAAA,MAAA,GAAAE,CAAA;AAAA,IAAAL,EAAA,CAAA,MAAAA,EAAX,CAEM,IAAAC,EAAA;AAAA,IADJK,EAAA,yBAAAV,EAAA,GAAAC,EAAA,OAAAL,GAAA;AAAA,MANNM,EAAAS,GAAA,EAAA,MAAA,iBAAA,CAAA;AAAA,IAAA,CAAA,KAQgBC,EAAqB,IAAA,EAAA;AAAA,IAAAR,EAAA,CAAA,MAAAA,EAAjC,CAqEM,IAAAC,EAAA;AAAA,IAAAK,EAnEI,wBAVdE,EAAA,IAAA,EAAA,KAcQZ,EAAA,GAAAC,EAAA,OAAAJ,GAAA;AAAA,MAdRgB,EAAA,0BAAAb,KAWsBc,EAAEC,GAAa;AAAA,QAC5B,KAAA;AAAA,QACA,eAAuBC,EAAA;AAAA,QAAA,mBAAAN,EAAA;AAA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;UA3EjFe,EAAAf,EAAA,QAAA,wBAAA,CAAA,GAAA,QAAA,EAAA;AAAA,QAAA,CAAA;AAAA,QAAA,GAAA;AAAA,MAAA,CAAA,KAAAK,EAAA,IAAA,EAAA;AAAA,IAAA,CAAA;AAAA;;;"}
|
|
1
|
+
{"version":3,"file":"DatasetDetailsDataset.vue.mjs","sources":["../../lib/datasetDetails/DatasetDetailsDataset.vue"],"sourcesContent":["<template>\n <div>\n <resource-access-popup ref=\"externalResourceModal\" />\n <span property=\"dc:issued\" :content=\"getReleaseDate\"></span>\n <span property=\"dc:modified\" :content=\"getModificationDate\"></span>\n <div v-if=\"loadingDatasetDetails\">\n <dataset-details-skeleton type=\"DatasetDetails\"></dataset-details-skeleton>\n </div>\n <div v-if=\"!loadingDatasetDetails\" class=\"dsd-dataset\">\n <dataset-details-description\n v-if=\"showDatasetDescription\"\n :dateIncorrect=\"dateIncorrect\"\n :machineTranslated=\"machineTranslated\"\n :translationNotAvailable=\"translationNotAvailable\"\n />\n <distributions\n :openModal=\"openModal\"\n :getDistributions=\"getDistributions\"\n :expandedDistributions=\"expandedDistributions\"\n :expandedDistributionDescriptions=\"expandedDistributionDescriptions\"\n :displayedDistributions=\"displayedDistributions\"\n :isDistributionsAllDisplayed=\"isDistributionsAllDisplayed\"\n :distributions=\"distributions\"\n :setDistributionsDisplayCount=\"setDistributionsDisplayCount\"\n :pages=\"pages\"\n :showDownloadUrls=\"showDownloadUrls\"\n :isOnlyOneUrl=\"isOnlyOneUrl\"\n :getDistributionFormat=\"getDistributionFormat\"\n :distributionFormatTruncated=\"distributionFormatTruncated\"\n :getDistributionTitle=\"getDistributionTitle\"\n :distributionVisibleContent=\"distributionVisibleContent\"\n :distributionExpandedContent=\"distributionExpandedContent\"\n :distributionDescriptionIsExpanded=\"distributionDescriptionIsExpanded\"\n :distributionDescriptionIsExpandable=\"distributionDescriptionIsExpandable\"\n :distributionIsExpanded=\"distributionIsExpanded\"\n :showNumber=\"showNumber\"\n :showObject=\"showObject\"\n :showDownloadDropdown=\"showDownloadDropdown\"\n :showLicence=\"showLicence\"\n :showLicensingAssistant=\"showLicensingAssistant\"\n :filterDateFormatEU=\"filterDateFormatEU\"\n :showArray=\"showArray\"\n :showObjectArray=\"showObjectArray\"\n :getVisualisationLink=\"getVisualisationLink\"\n :getDownloadUrl=\"getDownloadUrl\"\n :trackGoto=\"trackGoto\"\n :showAccessUrls=\"showAccessUrls\"\n :replaceHttp=\"replaceHttp\"\n :previewLinkCallback=\"previewLinkCallback\"\n :toggleDistribution=\"toggleDistribution\"\n :toggleDistributionDescription=\"toggleDistributionDescription\"\n :increaseNumDisplayedDistributions=\"increaseNumDisplayedDistributions\"\n :nonOverflowingIncrementsForDistributions=\"nonOverflowingIncrementsForDistributions\"\n :appendCurrentLocaleToURL=\"appendCurrentLocaleToURL\"\n :isUrlInvalid=\"isUrlInvalid\"\n :openIfValidUrl=\"openIfValidUrl\"\n :showTooltipVisualiseButton=\"showTooltipVisualiseButton\"\n :showPublisher=\"showPublisher\"\n :embed=\"embed\"\n />\n <dataset-details-features\n :getKeywords=\"getKeywords\"\n :pages=\"pages\"\n :increaseNumDisplayedPages=\"increaseNumDisplayedPages\"\n :nonOverflowingIncrementsForPages=\"nonOverflowingIncrementsForPages\"\n :showKeyword=\"showKeyword\"\n :trackGoto=\"trackGoto\"\n :showObjectArray=\"showObjectArray\"\n :showArray=\"showArray\"\n :showObject=\"showObject\"\n />\n <dataset-details-properties v-if=\"showDatasetProperties\">\n <template #property-header><slot name=\"property-header\"></slot></template>\n <template #property-table-before><slot name=\"property-table-before\"></slot></template>\n <template #property-table><slot name=\"property-table\"></slot></template>\n <template #property-table-after><slot name=\"property-table-after\"></slot></template>\n </dataset-details-properties>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\">\n // @ts-nocheck\n /* eslint-disable no-confusing-arrow, no-nested-ternary, no-return-assign, no-confusing-arrow */\n import $ from 'jquery';\n import { mapActions, mapGetters } from 'vuex';\n import {\n has,\n isNil,\n isArray,\n isObject,\n isString,\n isNumber,\n isEmpty,\n } from 'lodash';\n import AppLink from '../widgets/AppLink.vue';\n import Tooltip from '../widgets/Tooltip.vue';\n import Distributions from './distributions/Distributions.vue';\n import dateFilters from '../filters/dateFilters';\n import {\n getTranslationFor, getCountryFlagImg, truncate, replaceHttp, appendCurrentLocaleToURL\n } from '../utils/helpers';\n import ResourceAccessPopup from '../widgets/ResourceAccessPopup.vue';\n import DatasetDetailsExtendedMetaData\n from \"../datasetDetails/features/DatasetDetailsIsUsedBy.vue\";\n import DatasetDetailsSkeleton from \"../datasetDetails/DatasetDetailsSkeleton.vue\";\n import * as metaInfo from '../composables/head';\n\n export default {\n name: 'datasetDetailsDataset',\n components: {\n DatasetDetailsSkeleton,\n DatasetDetailsExtendedMetaData,\n AppLink,\n Tooltip,\n Distributions,\n ResourceAccessPopup\n },\n props: {\n distributionVisibleContent: {\n type: Array,\n default: () => ['license', 'licenseAttributionByText', 'modificationDate'],\n },\n distributionExpandedContent: {\n type: Array,\n default: () => [\n 'releaseDate',\n 'language',\n 'availability',\n 'status',\n 'rights',\n 'mediaType',\n 'byteSize',\n 'checksum',\n 'pages',\n 'type',\n 'compressFormat',\n 'packageFormat',\n 'hasPolicy',\n 'conformsTo',\n 'spatialResolutionInMeters',\n 'temporalResolution',\n ],\n },\n showDatasetDescription: {\n type: Boolean,\n default: () => true,\n },\n showDatasetProperties: {\n type: Boolean,\n default: () => true,\n },\n showPublisher: {\n type: Boolean,\n default: () => false,\n },\n embed: {\n type: Boolean,\n default: () => false,\n },\n },\n data() {\n return {\n defaultLocale: this.$env.languages.locale,\n // has to be INITIAL_DATASET_DESCRIPTION_LENGTH\n isDatasetDescriptionExpanded: false,\n loadingDatasetDetails: false,\n machineTranslated: false,\n translationNotAvailable: false,\n expandedDistributions: [],\n expandedDistributionDescriptions: [],\n distributions: {\n displayAll: this.$env.content.datasetDetails.distributions.displayAll,\n displayCount: this.$env.content.datasetDetails.distributions.displayCount,\n incrementSteps: this.$env.content.datasetDetails.distributions.incrementSteps,\n descriptionMaxLines: this.$env.content.datasetDetails.distributions.descriptionMaxLines,\n descriptionMaxChars: this.$env.content.datasetDetails.distributions.descriptionMaxChars,\n licencingAssistantUrl: this.$env.content.datasetDetails.distributions.licencingAssistantUrl,\n },\n pages: {\n isVisible: this.$env.content.datasetDetails.pages.isVisible,\n displayAll: this.$env.content.datasetDetails.pages.displayAll,\n displayCount: this.$env.content.datasetDetails.pages.displayCount,\n incrementSteps: this.$env.content.datasetDetails.pages.incrementSteps,\n descriptionMaxLines: this.$env.content.datasetDetails.pages.descriptionMaxLines,\n descriptionMaxChars: this.$env.content.datasetDetails.pages.descriptionMaxChars,\n },\n showDescription: true,\n };\n },\n computed: {\n // import store-getters\n ...mapGetters('datasetDetails', [\n 'getKeywords',\n 'getAccessRights',\n 'getAccrualPeriodicity',\n 'getCatalog',\n 'getContactPoints',\n 'getDateIncorrect',\n 'getDescription',\n 'getDistributions',\n 'getID',\n 'getLanguages',\n 'getLicences',\n 'getModificationDate',\n 'getOtherIdentifiers',\n 'getPages',\n 'getPublisher',\n 'getReleaseDate',\n 'getSpatial',\n 'getTranslationMetaData',\n 'getTitle',\n 'getIsHvd',\n 'getHvdCategories',\n 'getCountry',\n 'getCategories',\n 'getLoading',\n ]),\n dateIncorrect() {\n return this.getDateIncorrect;\n },\n displayedDistributions() {\n const sorted = [...this.getDistributions].sort((a, b) => {\n if (getTranslationFor(a.title, this.$route.query.locale, this.getLanguages) < getTranslationFor(b.title, this.$route.query.locale, this.getLanguages)) { return -1; }\n if (getTranslationFor(a.title, this.$route.query.locale, this.getLanguages) > getTranslationFor(b.title, this.$route.query.locale, this.getLanguages)) { return 1; }\n return 0;\n });\n return this.distributions.displayAll\n ? Object.freeze(sorted)\n : Object.freeze(sorted.slice(0, this.distributions.displayCount));\n },\n isDistributionsAllDisplayed() {\n return this.distributions.displayCount === this.getDistributions.length;\n },\n remainingDistributions() {\n return this.getDistributions.length - this.distributions.displayCount;\n }\n },\n watch: {\n getLoading: {\n handler(newVal, oldVal) {\n const isLoadingStopped = !newVal && oldVal;\n const isAlreadyLoadedSuccessfully = !newVal && !oldVal && this.getID;\n if (isLoadingStopped || isAlreadyLoadedSuccessfully) {\n this.piwikMetaPush();\n }\n },\n immediate: true\n }\n },\n methods: {\n ...mapActions('datasetDetails', [\n 'loadDatasetDetails',\n 'setLoading',\n ]),\n has,\n isNil,\n isArray,\n isObject,\n isString,\n isNumber,\n appendCurrentLocaleToURL,\n getTranslationFor,\n getCountryFlagImg,\n truncate,\n replaceHttp,\n initDatasetDetails() {\n setTimeout(() => {\n if (typeof this.$piwik?.resume === \"function\") this.$piwik.resume();\n }, 500);\n this.$nextTick(() => {\n // Display/hide translation banners\n this.setTranslationBanners();\n $('[data-toggle=\"tooltip\"]').tooltip({\n container: 'body',\n });\n });\n },\n setDistributionsDisplayCount(count: number) {\n this.distributions.displayCount = count;\n },\n openModal(callback, toggleDownloadPopup) {\n this.$refs.externalResourceModal.openModal(callback, toggleDownloadPopup)\n },\n previewLinkCallback(distribution) {\n return () => {\n this.$emit('track-link', this.getVisualisationLink(distribution), 'link');\n window.open(this.getVisualisationLink(distribution), '_blank');\n };\n },\n filterDateFormatEU(date) {\n return dateFilters.formatEU(date);\n },\n /* ABSTRACT SHOW FUNCTIONS */\n showString(string) {\n return !isNil(string) && isString(string);\n },\n showNumber(number) {\n return !isNil(number) && isNumber(number);\n },\n showObject(object) {\n return !isNil(object) && isObject(object) && !Object.values(object).reduce((keyUndefined, currentValue) => keyUndefined && currentValue === undefined, true);\n },\n showArray(array) {\n return !isNil(array) && isArray(array) && array.length > 0;\n },\n showObjectArray(objectArray) {\n return this.showArray(objectArray) && !objectArray.reduce((objectUndefined, currentObject) => objectUndefined && Object.values(currentObject).reduce((keyUndefined, currentValue) => keyUndefined && currentValue === undefined, true), true);\n },\n /* SPECIFIC SHOW FUNCTIONS */\n /* for now show all licences */\n showLicence(licence) {\n // return (has(licence, 'id') && !isNil(licence.id))\n // || (has(licence, 'label') && !isNil(licence.label))\n return true\n },\n showLicensingAssistant(distribution) {\n return has(distribution, 'licence.la_url') && this.showString(distribution.licence.la_url);\n },\n showDownloadDropdown(distribution) {\n return this.showAccessUrls(distribution) || this.showDownloadUrls(distribution);\n },\n isOnlyOneUrl(distribution) {\n return (this.showAccessUrls(distribution) && !this.showDownloadUrls(distribution))\n || (!this.showAccessUrls(distribution) && this.showDownloadUrls(distribution) && distribution.downloadUrls.length === 1);\n },\n getDownloadUrl(distribution) {\n let url;\n if (this.showAccessUrls(distribution) && !this.showDownloadUrls(distribution)) {\n url = distribution.accessUrl[0];\n }\n if (!this.showAccessUrls(distribution) && this.showDownloadUrls(distribution) && distribution.downloadUrls.length === 1) {\n url = distribution.downloadUrls[0];\n }\n return url;\n },\n showAccessUrls(distribution) {\n return has(distribution, 'accessUrl') && this.showArray(distribution.accessUrl);\n },\n showDownloadUrls(distribution) {\n return has(distribution, 'downloadUrls') && this.showArray(distribution.downloadUrls);\n },\n showKeyword(keyword) {\n return has(keyword, 'id')\n && has(keyword, 'title')\n && !isNil(keyword.id)\n && !isNil(keyword.title);\n },\n\n /* GETTER / SETTER FUNCTIONS */\n\n setDatasetOriginalLanguage(originalLanguage) {\n this.$i18n.locale = originalLanguage;\n },\n distributionIsExpanded(id) {\n setTimeout(() => {\n $('[data-toggle=\"tooltip\"]').tooltip({\n container: 'body',\n });\n }, 500);\n return this.expandedDistributions.includes(id);\n },\n distributionDescriptionIsExpanded(id) {\n return this.expandedDistributionDescriptions.includes(id);\n },\n distributionDescriptionIsExpandable(description) {\n return isNil(description) ? false : description.length > this.distributions.descriptionMaxChars;\n },\n getDistributionFormat(distribution) {\n return has(distribution, 'format.label') && !isNil(distribution.format.label) ? distribution.format.label : '';\n },\n distributionFormatTruncated(distribution) {\n return this.getDistributionFormat(distribution).length > 4;\n },\n getDistributionTitle(distribution) {\n return distribution.title\n ? getTranslationFor(distribution.title, this.$route.query.locale, this.getLanguages)\n : this.getID || '-';\n },\n getVisualisationLink(distribution) {\n // Return Visualisation Link\n const accessUrl = distribution.downloadUrls && distribution.downloadUrls.length ? distribution.downloadUrls[0] : distribution.accessUrl[0];\n return `/data/visualisation/?file=${encodeURIComponent(accessUrl)}`;\n },\n // getSubjectLink(subject) {\n // return { path: `/datasets?subject=${subject.id}`, query: Object.assign({}, { locale: this.$route.query.locale }) };\n // },\n toggleDistribution(id) {\n const index = this.expandedDistributions.indexOf(id);\n if (index > -1) this.expandedDistributions.splice(index, 1);\n else this.expandedDistributions.push(id);\n },\n toggleDistributionDescription(id) {\n const index = this.expandedDistributionDescriptions.indexOf(id);\n if (index > -1) this.expandedDistributionDescriptions.splice(index, 1);\n else this.expandedDistributionDescriptions.push(id);\n },\n setTranslationBanners() {\n if (!this.$i18n) return;\n const translationMetaData = this.getTranslationMetaData;\n // Check if translation of dataset is available in selected language\n if (!isNil(translationMetaData.details) && has(translationMetaData.details, this.$route.query.locale)) {\n // Check if dataset if machine translated\n this.machineTranslated = translationMetaData.details[this.$route.query.locale].machine_translated;\n } else {\n // No translation of this dataset available for the selected language\n this.translationNotAvailable = true;\n }\n },\n // Emit a Matomo event when user clicks on 'go to resource' element\n trackGoto() {\n const paq = window._paq || []; // eslint-disable-line\n // paq.push(['trackEvent', 'GoToResource', 'Clicked']);\n this.$piwik.trackGotoResource();\n },\n clamp(n, min, max) {\n return Math.min(Math.max(n, min), max);\n },\n // Increases the current number of distributions displayed\n // and clamps the result so that it never exceeds the number of all distributions.\n increaseNumDisplayedDistributions(increment) {\n const clampedSum = this.clamp(this.distributions.displayCount + increment, 0, this.getDistributions.length);\n this.distributions.displayCount = clampedSum;\n },\n nonOverflowingIncrementsForDistributions(incrementStep) {\n return this.distributions.displayCount + incrementStep <= this.getDistributions.length;\n },\n // Increases the current number of distributions displayed\n // and clamps the result so that it never exceeds the number of all distributions.\n increaseNumDisplayedPages(increment) {\n const clampedSum = this.clamp(this.pages.displayCount + increment, 0, this.getPages.length);\n this.pages.displayCount = clampedSum;\n },\n nonOverflowingIncrementsForPages(incrementStep) {\n return this.pages.displayCount + incrementStep <= this.getPages.length;\n },\n async piwikMetaPush() {\n await this.$nextTick();\n const obj = {\n dataset_AccessRights: this.getAccessRights,\n dataset_AccrualPeriodicity: this.getAccrualPeriodicity,\n dataset_Catalog: this.getCatalog,\n // dataset_Categories: this.getCategories,\n // dataset_ConformsTo: this.getConformsTo,\n // dataset_ContactPoints: this.getContactPoints,\n // dataset_Country: this.getCountry,\n // dataset_Creator: this.getCreator,\n // dataset_Description: this.getDescription,\n // dataset_Distributions: this.getDistributions,\n // dataset_DistributionFormats: this.getDistributionFormats,\n // dataset_Documentations: this.getDocumentations,\n // dataset_Frequency: this.getFrequency,\n // dataset_HasVersion: this.getHasVersion,\n dataset_ID: this.getID,\n // dataset_Identifiers: this.getIdentifiers,\n // dataset_IdName: this.getIdName,\n // dataset_IsVersionOf: this.getIsVersionOf,\n // datest_Keywords: this.getKeywords,\n // dataset_LandingPages: this.getLandingPagesResource,\n // dataset_Languages: this.getLanguages,\n // dataset_Licences: this.getLicences,\n // dataset_Loading: this.getLoading,\n // dataset_ModificationDate: this.getModificationDate,\n // dataset_OriginalLanguage: this.getOriginalLanguage,\n // dataset_OtherIdentifiers: this.getOtherIdentifiers,\n // dataset_Pages: this.getPages,\n // dataset_Provenances: this.getProvenances,\n dataset_Publisher: this.getPublisher,\n // dataset_RelatedResources: this.getRelatedResources,\n // dataset_ReleaseDate: this.getReleaseDate,\n // dataset_Sources: this.getSources,\n // dataset_Spatial: this.getSpatial,\n // dataset_SpatialResource: this.getSpatialResource,\n // dataset_Temporal: this.getTemporal,\n dataset_Title: this.getTitle,\n // dataset_TranslationMetaData: this.getTranslationMetaData,\n // dataset_VersionInfo: this.getVersionInfo,\n // dataset_VersionNotes: this.getVersionNotes,\n dataset_type: this.getIsHvd ? 'High-Value Dataset' : 'Dataset',\n dataset_scope: this.getCountry?.id === 'io'\n ? 'International Data'\n : this.getCountry?.id === 'eu'\n ? 'European Union Data'\n : 'National Data',\n dataset_provenance: this.getCountry?.name || this.getCountry?.id || '',\n dataset_category: this.getCategories?.map(category => category.label?.en || category.id).filter(Boolean)\n\n };\n this.$piwik.trackDatasetDetailsPageView(null, null, obj);\n },\n isUrlInvalid(url) {\n if (url) {\n try {\n /* eslint-disable no-useless-escape */\n return !(new RegExp(\"^((https?:\\/\\/(www\\.)?)([-a-zA-Z0-9@:%._\\+~#=]{1,256})([-a-zA-Z0-9()@:%_\\+.~#?&//=]*))$\", \"i\")).test(decodeURIComponent(url.split(\"=\").pop()));\n /* eslint-enable no-useless-escape */\n } catch (e) {\n console.error(e);\n }\n }\n },\n openIfValidUrl(isValid, previewLinkCallback, distribution, event) {\n if (isValid) {\n // for (let key in this.$children) {\n // if(this.$children[key].$refs[\"externalResourceModal\"]) {\n // this.$children[key].$refs[\"externalResourceModal\"].openModal(previewLinkCallback(distribution), false);\n // }\n // }\n this.openModal(previewLinkCallback(distribution), false);\n } else {\n event.preventDefault();\n event.stopPropagation();\n }\n },\n showTooltipVisualiseButton(invalidUrl) {\n if (invalidUrl) {\n return this.$t('message.tooltip.invalidVisualise');\n }\n return ''\n },\n },\n mounted() {\n // Duplicated API call, execute only if data not already loaded\n if (this.$route.params.ds_id !== this.getID) {\n this.$Progress.start();\n this.loadingDatasetDetails = true;\n this.loadDatasetDetails(this.$route.params.ds_id)\n .then(() => {\n this.$Progress.finish();\n this.loadingDatasetDetails = false;\n this.initDatasetDetails();\n })\n .catch((err) => {\n console.warn(err); // eslint-disable-line\n this.$Progress.fail();\n if (typeof this.$piwik?.resume === \"function\") this.$piwik.resume();\n this.$router.replace({\n name: 'NotFound',\n query: { locale: this.$route.query.locale, dataset: this.$route.params.ds_id },\n });\n })\n .finally(() => this.$root.$emit('contentLoaded'));\n } else {\n this.initDatasetDetails();\n this.$root.$emit('contentLoaded')\n }\n\n const distributionsConf = this.$env.content.datasetDetails && this.$env.content.datasetDetails.distributions;\n if (distributionsConf) {\n this.distributions.displayAll = distributionsConf.displayAll || this.distributions.displayAll;\n this.distributions.displayCount = parseInt(distributionsConf.displayCount, 10) || this.distributions.displayCount;\n\n if (typeof distributionsConf.incrementSteps === 'string') {\n // Need to parse as json array since env variables are string only\n distributionsConf.incrementSteps = JSON.parse(distributionsConf.incrementSteps);\n }\n this.distributions.incrementSteps = distributionsConf.incrementSteps || this.distributions.incrementSteps;\n }\n\n if (this.distributions.displayAll) this.distributions.displayCount = this.getDistributions.length;\n\n const pagesConf = this.$env.content.datasetDetails && this.$env.content.datasetDetails.pages;\n if (pagesConf) {\n this.pages.displayAll = pagesConf.displayAll || this.pages.displayAll;\n this.pages.displayCount = parseInt(pagesConf.displayCount, 10) || this.pages.displayCount;\n\n if (typeof pagesConf.incrementSteps === 'string') {\n // Need to parse as json array since env variables are string only\n pagesConf.incrementSteps = JSON.parse(pagesConf.incrementSteps);\n }\n this.pages.incrementSteps = pagesConf.incrementSteps || this.pages.incrementSteps;\n }\n\n if (this.pages.displayAll) this.pages.displayCount = this.getPages.length;\n },\n beforeUnmount() {\n $('.tooltip').remove();\n },\n setup() {\n metaInfo.useDatasetDetailsDatasetHead();\n }\n };\n</script>\n\n<style lang=\"scss\" scoped>\n\n .catalogue-label {\n white-space: pre-line;\n }\n\n .cursor-pointer {\n cursor: pointer;\n }\n\n .tag-color {\n background-color: var(--tag-color);\n }\n\n .btn-color {\n &:hover {\n background-color: #196fd2;\n border-color: #196fd2;\n }\n }\n\n .heading, .arrow, .copy-text {\n cursor: pointer;\n }\n\n .details-link {\n cursor: pointer;\n\n &:hover {\n text-decoration: underline;\n }\n }\n\n .text-break {\n word-break: break-word;\n }\n\n td {\n padding-left: 0 !important;\n padding-top: 1% !important;\n padding-bottom: 1% !important;\n }\n\n .download-all-btn {\n min-width: 100px;\n height: 31px;\n }\n\n .d-inline-table {\n display: inline-table;\n }\n\n /*** BOOTSTRAP ***/\n button:focus {\n outline:0;\n }\n .options, .download {\n .dropdown-menu {\n .dropdown-item {\n &:hover {\n color: initial;\n background-color: initial;\n }\n }\n }\n }\n.spinner-grow {\n width: 20px;\n height: 20px;\n}\n\n /*** FONT AWESOME ICONS ***/\n .fa-check-square {\n color: #28a745;\n width: 16px;\n height: 16px;\n }\n\n /*** MATERIAL ICONS ***/\n %modal-icon {\n font-size: 18px;\n cursor: default;\n }\n\n .help-icon {\n @extend %modal-icon;\n }\n\n .check-icon {\n @extend %modal-icon;\n color: #28a745;\n }\n\n .material-icons.small-icon {\n font-size: 20px;\n }\n\n .distributions {\n\n &__item {\n position: relative;\n\n &--preview {\n width: 100%;\n height: 100%;\n position: absolute;\n top: 0;\n left: 0;\n background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, white 55%);\n z-index: 10;\n }\n }\n\n &__actions {\n display: flex;\n justify-content: center;\n align-items: flex-end;\n height: 100%;\n z-index: 11;\n }\n }\n .mt-4 {\n margin-top: 1.5rem !important;\n }\n\n .keywords {\n\n &__item {\n position: relative;\n }\n\n &__actions {\n display: flex;\n justify-content: center;\n align-items: flex-end;\n height: 100%;\n z-index: 11;\n }\n }\n .sectionList {\n list-style-type: '→ ';\n margin-left:6.5%;\n }\n @media only screen and (max-width: 991px) {\n .sectionList {\n margin-left: 0;\n }\n}\n</style>\n"],"names":["_hoisted_1","_hoisted_3","_hoisted_4","_component_dataset_details_properties","_resolveComponent","_openBlock","_createElementBlock","_createVNode","_component_resource_access_popup","_cache","_createTextVNode","getReleaseDate","_ctx","getModificationDate","_hoisted_2","$data","_component_dataset_details_skeleton","_createCommentVNode","$props","_createBlock","_component_dataset_details_description","$options","_component_distributions","getDistributions","getKeywords","_component_dataset_details_features","_withCtx","_renderSlot"],"mappings":";;;;AAAA,MAAAA,IAAA,CAAA,SAAA,oBAAAC,IAAA,EAAA,KAAA,KAQuCC,IAAM;AAAA,EAAA,KAAA;AAAA;;;4KAsErCC,IAAAC,EAAA,4BAAA;AA9ER,SAAAC,EAAA,GAAAC,EAAA,OAAA,MAAA;AAAA,IAGIC,EAA4DC,GAAA,EAAA,KAAA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,kBAAA,8BAAA,iBAAA,OAAA,CAAA;AAAA,MATCT,EAAA,CAAA,MAAWA,EAAEe,CAAW,IAAAd,EAAA;AAAA,MAAAH,EACjBkB,GAAK;AAAA,QACZ,aAAAb,EAAA;AAAA,QACA,OAAAG,EAAA;AAAA,QACA,2BAAaM,EAAW;AAAA,QACxB,kCAAoBA,EAAA;AAAA,QACpB,aAAiBA,EAAA;AAAA,QACjB,WAAWA,EAAA;AAAA,QACX,iBAAYA,EAAA;AAAA,QAAA,WAAAA,EAAA;AAAA;SAEmB,MAAqB,GAAA,CAAA,eAAA,SAAA,6BAAA,oCAAA,eAAA,aAAA,mBAAA,aAAA,YAAA,CAAA;AAAA,MAAAZ,EAAA,CAAA,MAAAA,EAAvD,CAK6B,IAAAC,EAAA;AAAA,MAAAQ,EAJhB,8BAAoDC,EAAAhB,GAAA,EAAA,KAAA,KAAA;AAAA,QAAA,mBAAAuB,EAAA,MAAA;AAAA,UACpDC,EAAAf,EAAA,QAAqB,mBAA2C,CAAA,GAAA,QAAA,EAAA;AAAA,QAAA,CAAA;AAAA;UAChEe,EAAAf,EAAc,QAAC,yBAAmC,CAAA,GAAA,QAAA,EAAA;AAAA,QAAA,CAAA;AAAA;UAClDe,EAAAf,EAAA,QAAoB,kBAA0C,CAAA,GAAA,QAAA,EAAA;AAAA,QAAA,CAAA;AAAA;UA3EjFe,EAAAf,EAAA,QAAA,wBAAA,CAAA,GAAA,QAAA,EAAA;AAAA,QAAA,CAAA;AAAA,QAAA,GAAA;AAAA,MAAA,CAAA,KAAAK,EAAA,IAAA,EAAA;AAAA,IAAA,CAAA;AAAA;;;"}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import l from "jquery";
|
|
2
|
-
import { mapGetters as
|
|
3
|
-
import { has as n, isNil as a, isArray as
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import { getTranslationFor as o, appendCurrentLocaleToURL as
|
|
2
|
+
import { mapGetters as m, mapActions as y } from "vuex";
|
|
3
|
+
import { has as n, isNil as a, isArray as u, isObject as c, isString as g, isNumber as D } from "lodash-es";
|
|
4
|
+
import f from "../widgets/AppLink.vue.mjs";
|
|
5
|
+
import b from "../widgets/Tooltip.vue.mjs";
|
|
6
|
+
import w from "./distributions/Distributions.vue.mjs";
|
|
7
|
+
import $ from "../filters/dateFilters.mjs";
|
|
8
|
+
import { getTranslationFor as o, appendCurrentLocaleToURL as C, getCountryFlagImg as A, truncate as U, replaceHttp as x } from "../utils/helpers.mjs";
|
|
9
9
|
import v from "../widgets/ResourceAccessPopup.vue.mjs";
|
|
10
|
-
import
|
|
11
|
-
import
|
|
10
|
+
import L from "./features/DatasetDetailsIsUsedBy.vue.mjs";
|
|
11
|
+
import S from "./DatasetDetailsSkeleton.vue.mjs";
|
|
12
12
|
import "@unhead/vue";
|
|
13
13
|
import "merge-anything";
|
|
14
14
|
import "../configurations/config-schema/apiSchema.mjs";
|
|
@@ -23,15 +23,15 @@ import "../configurations/config-schema/configSchema.mjs";
|
|
|
23
23
|
import "vue";
|
|
24
24
|
import "vue-router";
|
|
25
25
|
import "vue-i18n";
|
|
26
|
-
import { useDatasetDetailsDatasetHead as
|
|
27
|
-
const
|
|
26
|
+
import { useDatasetDetailsDatasetHead as I } from "../composables/head/useDatasetDetailsDatasetHead.mjs";
|
|
27
|
+
const st = {
|
|
28
28
|
name: "datasetDetailsDataset",
|
|
29
29
|
components: {
|
|
30
|
-
DatasetDetailsSkeleton:
|
|
31
|
-
DatasetDetailsExtendedMetaData:
|
|
32
|
-
AppLink:
|
|
33
|
-
Tooltip:
|
|
34
|
-
Distributions:
|
|
30
|
+
DatasetDetailsSkeleton: S,
|
|
31
|
+
DatasetDetailsExtendedMetaData: L,
|
|
32
|
+
AppLink: f,
|
|
33
|
+
Tooltip: b,
|
|
34
|
+
Distributions: w,
|
|
35
35
|
ResourceAccessPopup: v
|
|
36
36
|
},
|
|
37
37
|
props: {
|
|
@@ -108,7 +108,7 @@ const et = {
|
|
|
108
108
|
},
|
|
109
109
|
computed: {
|
|
110
110
|
// import store-getters
|
|
111
|
-
...
|
|
111
|
+
...m("datasetDetails", [
|
|
112
112
|
"getKeywords",
|
|
113
113
|
"getAccessRights",
|
|
114
114
|
"getAccrualPeriodicity",
|
|
@@ -131,7 +131,8 @@ const et = {
|
|
|
131
131
|
"getIsHvd",
|
|
132
132
|
"getHvdCategories",
|
|
133
133
|
"getCountry",
|
|
134
|
-
"getCategories"
|
|
134
|
+
"getCategories",
|
|
135
|
+
"getLoading"
|
|
135
136
|
]),
|
|
136
137
|
dateIncorrect() {
|
|
137
138
|
return this.getDateIncorrect;
|
|
@@ -147,24 +148,33 @@ const et = {
|
|
|
147
148
|
return this.getDistributions.length - this.distributions.displayCount;
|
|
148
149
|
}
|
|
149
150
|
},
|
|
151
|
+
watch: {
|
|
152
|
+
getLoading: {
|
|
153
|
+
handler(t, e) {
|
|
154
|
+
const s = !t && e, i = !t && !e && this.getID;
|
|
155
|
+
(s || i) && this.piwikMetaPush();
|
|
156
|
+
},
|
|
157
|
+
immediate: !0
|
|
158
|
+
}
|
|
159
|
+
},
|
|
150
160
|
methods: {
|
|
151
|
-
...
|
|
161
|
+
...y("datasetDetails", [
|
|
152
162
|
"loadDatasetDetails",
|
|
153
163
|
"setLoading"
|
|
154
164
|
]),
|
|
155
165
|
has: n,
|
|
156
166
|
isNil: a,
|
|
157
|
-
isArray:
|
|
158
|
-
isObject:
|
|
159
|
-
isString:
|
|
160
|
-
isNumber:
|
|
161
|
-
appendCurrentLocaleToURL:
|
|
167
|
+
isArray: u,
|
|
168
|
+
isObject: c,
|
|
169
|
+
isString: g,
|
|
170
|
+
isNumber: D,
|
|
171
|
+
appendCurrentLocaleToURL: C,
|
|
162
172
|
getTranslationFor: o,
|
|
163
|
-
getCountryFlagImg:
|
|
164
|
-
truncate:
|
|
165
|
-
replaceHttp:
|
|
173
|
+
getCountryFlagImg: A,
|
|
174
|
+
truncate: U,
|
|
175
|
+
replaceHttp: x,
|
|
166
176
|
initDatasetDetails() {
|
|
167
|
-
|
|
177
|
+
setTimeout(() => {
|
|
168
178
|
var t;
|
|
169
179
|
typeof ((t = this.$piwik) == null ? void 0 : t.resume) == "function" && this.$piwik.resume();
|
|
170
180
|
}, 500), this.$nextTick(() => {
|
|
@@ -185,20 +195,20 @@ const et = {
|
|
|
185
195
|
};
|
|
186
196
|
},
|
|
187
197
|
filterDateFormatEU(t) {
|
|
188
|
-
return
|
|
198
|
+
return $.formatEU(t);
|
|
189
199
|
},
|
|
190
200
|
/* ABSTRACT SHOW FUNCTIONS */
|
|
191
201
|
showString(t) {
|
|
192
|
-
return !a(t) &&
|
|
202
|
+
return !a(t) && g(t);
|
|
193
203
|
},
|
|
194
204
|
showNumber(t) {
|
|
195
|
-
return !a(t) &&
|
|
205
|
+
return !a(t) && D(t);
|
|
196
206
|
},
|
|
197
207
|
showObject(t) {
|
|
198
|
-
return !a(t) &&
|
|
208
|
+
return !a(t) && c(t) && !Object.values(t).reduce((e, s) => e && s === void 0, !0);
|
|
199
209
|
},
|
|
200
210
|
showArray(t) {
|
|
201
|
-
return !a(t) &&
|
|
211
|
+
return !a(t) && u(t) && t.length > 0;
|
|
202
212
|
},
|
|
203
213
|
showObjectArray(t) {
|
|
204
214
|
return this.showArray(t) && !t.reduce((e, s) => e && Object.values(s).reduce((i, r) => i && r === void 0, !0), !0);
|
|
@@ -302,9 +312,10 @@ const et = {
|
|
|
302
312
|
nonOverflowingIncrementsForPages(t) {
|
|
303
313
|
return this.pages.displayCount + t <= this.getPages.length;
|
|
304
314
|
},
|
|
305
|
-
piwikMetaPush() {
|
|
306
|
-
var
|
|
307
|
-
this.$
|
|
315
|
+
async piwikMetaPush() {
|
|
316
|
+
var e, s, i, r, d;
|
|
317
|
+
await this.$nextTick();
|
|
318
|
+
const t = {
|
|
308
319
|
dataset_AccessRights: this.getAccessRights,
|
|
309
320
|
dataset_AccrualPeriodicity: this.getAccrualPeriodicity,
|
|
310
321
|
dataset_Catalog: this.getCatalog,
|
|
@@ -345,13 +356,14 @@ const et = {
|
|
|
345
356
|
// dataset_VersionInfo: this.getVersionInfo,
|
|
346
357
|
// dataset_VersionNotes: this.getVersionNotes,
|
|
347
358
|
dataset_type: this.getIsHvd ? "High-Value Dataset" : "Dataset",
|
|
348
|
-
dataset_scope: ((
|
|
349
|
-
dataset_provenance: ((
|
|
350
|
-
dataset_category: (
|
|
351
|
-
var
|
|
352
|
-
return ((
|
|
359
|
+
dataset_scope: ((e = this.getCountry) == null ? void 0 : e.id) === "io" ? "International Data" : ((s = this.getCountry) == null ? void 0 : s.id) === "eu" ? "European Union Data" : "National Data",
|
|
360
|
+
dataset_provenance: ((i = this.getCountry) == null ? void 0 : i.name) || ((r = this.getCountry) == null ? void 0 : r.id) || "",
|
|
361
|
+
dataset_category: (d = this.getCategories) == null ? void 0 : d.map((p) => {
|
|
362
|
+
var h;
|
|
363
|
+
return ((h = p.label) == null ? void 0 : h.en) || p.id;
|
|
353
364
|
}).filter(Boolean)
|
|
354
|
-
}
|
|
365
|
+
};
|
|
366
|
+
this.$piwik.trackDatasetDetailsPageView(null, null, t);
|
|
355
367
|
},
|
|
356
368
|
isUrlInvalid(t) {
|
|
357
369
|
if (t)
|
|
@@ -387,10 +399,10 @@ const et = {
|
|
|
387
399
|
l(".tooltip").remove();
|
|
388
400
|
},
|
|
389
401
|
setup() {
|
|
390
|
-
|
|
402
|
+
I();
|
|
391
403
|
}
|
|
392
404
|
};
|
|
393
405
|
export {
|
|
394
|
-
|
|
406
|
+
st as default
|
|
395
407
|
};
|
|
396
408
|
//# sourceMappingURL=DatasetDetailsDataset.vue2.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DatasetDetailsDataset.vue2.mjs","sources":["../../lib/datasetDetails/DatasetDetailsDataset.vue"],"sourcesContent":["<template>\n <div>\n <resource-access-popup ref=\"externalResourceModal\" />\n <span property=\"dc:issued\" :content=\"getReleaseDate\"></span>\n <span property=\"dc:modified\" :content=\"getModificationDate\"></span>\n <div v-if=\"loadingDatasetDetails\">\n <dataset-details-skeleton type=\"DatasetDetails\"></dataset-details-skeleton>\n </div>\n <div v-if=\"!loadingDatasetDetails\" class=\"dsd-dataset\">\n <dataset-details-description\n v-if=\"showDatasetDescription\"\n :dateIncorrect=\"dateIncorrect\"\n :machineTranslated=\"machineTranslated\"\n :translationNotAvailable=\"translationNotAvailable\"\n />\n <distributions\n :openModal=\"openModal\"\n :getDistributions=\"getDistributions\"\n :expandedDistributions=\"expandedDistributions\"\n :expandedDistributionDescriptions=\"expandedDistributionDescriptions\"\n :displayedDistributions=\"displayedDistributions\"\n :isDistributionsAllDisplayed=\"isDistributionsAllDisplayed\"\n :distributions=\"distributions\"\n :setDistributionsDisplayCount=\"setDistributionsDisplayCount\"\n :pages=\"pages\"\n :showDownloadUrls=\"showDownloadUrls\"\n :isOnlyOneUrl=\"isOnlyOneUrl\"\n :getDistributionFormat=\"getDistributionFormat\"\n :distributionFormatTruncated=\"distributionFormatTruncated\"\n :getDistributionTitle=\"getDistributionTitle\"\n :distributionVisibleContent=\"distributionVisibleContent\"\n :distributionExpandedContent=\"distributionExpandedContent\"\n :distributionDescriptionIsExpanded=\"distributionDescriptionIsExpanded\"\n :distributionDescriptionIsExpandable=\"distributionDescriptionIsExpandable\"\n :distributionIsExpanded=\"distributionIsExpanded\"\n :showNumber=\"showNumber\"\n :showObject=\"showObject\"\n :showDownloadDropdown=\"showDownloadDropdown\"\n :showLicence=\"showLicence\"\n :showLicensingAssistant=\"showLicensingAssistant\"\n :filterDateFormatEU=\"filterDateFormatEU\"\n :showArray=\"showArray\"\n :showObjectArray=\"showObjectArray\"\n :getVisualisationLink=\"getVisualisationLink\"\n :getDownloadUrl=\"getDownloadUrl\"\n :trackGoto=\"trackGoto\"\n :showAccessUrls=\"showAccessUrls\"\n :replaceHttp=\"replaceHttp\"\n :previewLinkCallback=\"previewLinkCallback\"\n :toggleDistribution=\"toggleDistribution\"\n :toggleDistributionDescription=\"toggleDistributionDescription\"\n :increaseNumDisplayedDistributions=\"increaseNumDisplayedDistributions\"\n :nonOverflowingIncrementsForDistributions=\"nonOverflowingIncrementsForDistributions\"\n :appendCurrentLocaleToURL=\"appendCurrentLocaleToURL\"\n :isUrlInvalid=\"isUrlInvalid\"\n :openIfValidUrl=\"openIfValidUrl\"\n :showTooltipVisualiseButton=\"showTooltipVisualiseButton\"\n :showPublisher=\"showPublisher\"\n :embed=\"embed\"\n />\n <dataset-details-features\n :getKeywords=\"getKeywords\"\n :pages=\"pages\"\n :increaseNumDisplayedPages=\"increaseNumDisplayedPages\"\n :nonOverflowingIncrementsForPages=\"nonOverflowingIncrementsForPages\"\n :showKeyword=\"showKeyword\"\n :trackGoto=\"trackGoto\"\n :showObjectArray=\"showObjectArray\"\n :showArray=\"showArray\"\n :showObject=\"showObject\"\n />\n <dataset-details-properties v-if=\"showDatasetProperties\">\n <template #property-header><slot name=\"property-header\"></slot></template>\n <template #property-table-before><slot name=\"property-table-before\"></slot></template>\n <template #property-table><slot name=\"property-table\"></slot></template>\n <template #property-table-after><slot name=\"property-table-after\"></slot></template>\n </dataset-details-properties>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\">\n // @ts-nocheck\n /* eslint-disable no-confusing-arrow, no-nested-ternary, no-return-assign, no-confusing-arrow */\n import $ from 'jquery';\n import { mapActions, mapGetters } from 'vuex';\n import {\n has,\n isNil,\n isArray,\n isObject,\n isString,\n isNumber,\n isEmpty,\n } from 'lodash';\n import AppLink from '../widgets/AppLink.vue';\n import Tooltip from '../widgets/Tooltip.vue';\n import Distributions from './distributions/Distributions.vue';\n import dateFilters from '../filters/dateFilters';\n import {\n getTranslationFor, getCountryFlagImg, truncate, replaceHttp, appendCurrentLocaleToURL\n } from '../utils/helpers';\n import ResourceAccessPopup from '../widgets/ResourceAccessPopup.vue';\n import DatasetDetailsExtendedMetaData\n from \"../datasetDetails/features/DatasetDetailsIsUsedBy.vue\";\n import DatasetDetailsSkeleton from \"../datasetDetails/DatasetDetailsSkeleton.vue\";\n import * as metaInfo from '../composables/head';\n\n export default {\n name: 'datasetDetailsDataset',\n components: {\n DatasetDetailsSkeleton,\n DatasetDetailsExtendedMetaData,\n AppLink,\n Tooltip,\n Distributions,\n ResourceAccessPopup\n },\n props: {\n distributionVisibleContent: {\n type: Array,\n default: () => ['license', 'licenseAttributionByText', 'modificationDate'],\n },\n distributionExpandedContent: {\n type: Array,\n default: () => [\n 'releaseDate',\n 'language',\n 'availability',\n 'status',\n 'rights',\n 'mediaType',\n 'byteSize',\n 'checksum',\n 'pages',\n 'type',\n 'compressFormat',\n 'packageFormat',\n 'hasPolicy',\n 'conformsTo',\n 'spatialResolutionInMeters',\n 'temporalResolution',\n ],\n },\n showDatasetDescription: {\n type: Boolean,\n default: () => true,\n },\n showDatasetProperties: {\n type: Boolean,\n default: () => true,\n },\n showPublisher: {\n type: Boolean,\n default: () => false,\n },\n embed: {\n type: Boolean,\n default: () => false,\n },\n },\n data() {\n return {\n defaultLocale: this.$env.languages.locale,\n // has to be INITIAL_DATASET_DESCRIPTION_LENGTH\n isDatasetDescriptionExpanded: false,\n loadingDatasetDetails: false,\n machineTranslated: false,\n translationNotAvailable: false,\n expandedDistributions: [],\n expandedDistributionDescriptions: [],\n distributions: {\n displayAll: this.$env.content.datasetDetails.distributions.displayAll,\n displayCount: this.$env.content.datasetDetails.distributions.displayCount,\n incrementSteps: this.$env.content.datasetDetails.distributions.incrementSteps,\n descriptionMaxLines: this.$env.content.datasetDetails.distributions.descriptionMaxLines,\n descriptionMaxChars: this.$env.content.datasetDetails.distributions.descriptionMaxChars,\n licencingAssistantUrl: this.$env.content.datasetDetails.distributions.licencingAssistantUrl,\n },\n pages: {\n isVisible: this.$env.content.datasetDetails.pages.isVisible,\n displayAll: this.$env.content.datasetDetails.pages.displayAll,\n displayCount: this.$env.content.datasetDetails.pages.displayCount,\n incrementSteps: this.$env.content.datasetDetails.pages.incrementSteps,\n descriptionMaxLines: this.$env.content.datasetDetails.pages.descriptionMaxLines,\n descriptionMaxChars: this.$env.content.datasetDetails.pages.descriptionMaxChars,\n },\n showDescription: true,\n };\n },\n computed: {\n // import store-getters\n ...mapGetters('datasetDetails', [\n 'getKeywords',\n 'getAccessRights',\n 'getAccrualPeriodicity',\n 'getCatalog',\n 'getContactPoints',\n 'getDateIncorrect',\n 'getDescription',\n 'getDistributions',\n 'getID',\n 'getLanguages',\n 'getLicences',\n 'getModificationDate',\n 'getOtherIdentifiers',\n 'getPages',\n 'getPublisher',\n 'getReleaseDate',\n 'getSpatial',\n 'getTranslationMetaData',\n 'getTitle',\n 'getIsHvd',\n 'getHvdCategories',\n 'getCountry',\n 'getCategories',\n ]),\n dateIncorrect() {\n return this.getDateIncorrect;\n },\n displayedDistributions() {\n const sorted = [...this.getDistributions].sort((a, b) => {\n if (getTranslationFor(a.title, this.$route.query.locale, this.getLanguages) < getTranslationFor(b.title, this.$route.query.locale, this.getLanguages)) { return -1; }\n if (getTranslationFor(a.title, this.$route.query.locale, this.getLanguages) > getTranslationFor(b.title, this.$route.query.locale, this.getLanguages)) { return 1; }\n return 0;\n });\n return this.distributions.displayAll\n ? Object.freeze(sorted)\n : Object.freeze(sorted.slice(0, this.distributions.displayCount));\n },\n isDistributionsAllDisplayed() {\n return this.distributions.displayCount === this.getDistributions.length;\n },\n remainingDistributions() {\n return this.getDistributions.length - this.distributions.displayCount;\n }\n },\n methods: {\n ...mapActions('datasetDetails', [\n 'loadDatasetDetails',\n 'setLoading',\n ]),\n has,\n isNil,\n isArray,\n isObject,\n isString,\n isNumber,\n appendCurrentLocaleToURL,\n getTranslationFor,\n getCountryFlagImg,\n truncate,\n replaceHttp,\n initDatasetDetails() {\n this.piwikMetaPush();\n setTimeout(() => {\n if (typeof this.$piwik?.resume === \"function\") this.$piwik.resume();\n }, 500);\n this.$nextTick(() => {\n // Display/hide translation banners\n this.setTranslationBanners();\n $('[data-toggle=\"tooltip\"]').tooltip({\n container: 'body',\n });\n });\n },\n setDistributionsDisplayCount(count: number) {\n this.distributions.displayCount = count;\n },\n openModal(callback, toggleDownloadPopup) {\n this.$refs.externalResourceModal.openModal(callback, toggleDownloadPopup)\n },\n previewLinkCallback(distribution) {\n return () => {\n this.$emit('track-link', this.getVisualisationLink(distribution), 'link');\n window.open(this.getVisualisationLink(distribution), '_blank');\n };\n },\n filterDateFormatEU(date) {\n return dateFilters.formatEU(date);\n },\n /* ABSTRACT SHOW FUNCTIONS */\n showString(string) {\n return !isNil(string) && isString(string);\n },\n showNumber(number) {\n return !isNil(number) && isNumber(number);\n },\n showObject(object) {\n return !isNil(object) && isObject(object) && !Object.values(object).reduce((keyUndefined, currentValue) => keyUndefined && currentValue === undefined, true);\n },\n showArray(array) {\n return !isNil(array) && isArray(array) && array.length > 0;\n },\n showObjectArray(objectArray) {\n return this.showArray(objectArray) && !objectArray.reduce((objectUndefined, currentObject) => objectUndefined && Object.values(currentObject).reduce((keyUndefined, currentValue) => keyUndefined && currentValue === undefined, true), true);\n },\n /* SPECIFIC SHOW FUNCTIONS */\n /* for now show all licences */\n showLicence(licence) {\n // return (has(licence, 'id') && !isNil(licence.id))\n // || (has(licence, 'label') && !isNil(licence.label))\n return true\n },\n showLicensingAssistant(distribution) {\n return has(distribution, 'licence.la_url') && this.showString(distribution.licence.la_url);\n },\n showDownloadDropdown(distribution) {\n return this.showAccessUrls(distribution) || this.showDownloadUrls(distribution);\n },\n isOnlyOneUrl(distribution) {\n return (this.showAccessUrls(distribution) && !this.showDownloadUrls(distribution))\n || (!this.showAccessUrls(distribution) && this.showDownloadUrls(distribution) && distribution.downloadUrls.length === 1);\n },\n getDownloadUrl(distribution) {\n let url;\n if (this.showAccessUrls(distribution) && !this.showDownloadUrls(distribution)) {\n url = distribution.accessUrl[0];\n }\n if (!this.showAccessUrls(distribution) && this.showDownloadUrls(distribution) && distribution.downloadUrls.length === 1) {\n url = distribution.downloadUrls[0];\n }\n return url;\n },\n showAccessUrls(distribution) {\n return has(distribution, 'accessUrl') && this.showArray(distribution.accessUrl);\n },\n showDownloadUrls(distribution) {\n return has(distribution, 'downloadUrls') && this.showArray(distribution.downloadUrls);\n },\n showKeyword(keyword) {\n return has(keyword, 'id')\n && has(keyword, 'title')\n && !isNil(keyword.id)\n && !isNil(keyword.title);\n },\n\n /* GETTER / SETTER FUNCTIONS */\n\n setDatasetOriginalLanguage(originalLanguage) {\n this.$i18n.locale = originalLanguage;\n },\n distributionIsExpanded(id) {\n setTimeout(() => {\n $('[data-toggle=\"tooltip\"]').tooltip({\n container: 'body',\n });\n }, 500);\n return this.expandedDistributions.includes(id);\n },\n distributionDescriptionIsExpanded(id) {\n return this.expandedDistributionDescriptions.includes(id);\n },\n distributionDescriptionIsExpandable(description) {\n return isNil(description) ? false : description.length > this.distributions.descriptionMaxChars;\n },\n getDistributionFormat(distribution) {\n return has(distribution, 'format.label') && !isNil(distribution.format.label) ? distribution.format.label : '';\n },\n distributionFormatTruncated(distribution) {\n return this.getDistributionFormat(distribution).length > 4;\n },\n getDistributionTitle(distribution) {\n return distribution.title\n ? getTranslationFor(distribution.title, this.$route.query.locale, this.getLanguages)\n : this.getID || '-';\n },\n getVisualisationLink(distribution) {\n // Return Visualisation Link\n const accessUrl = distribution.downloadUrls && distribution.downloadUrls.length ? distribution.downloadUrls[0] : distribution.accessUrl[0];\n return `/data/visualisation/?file=${encodeURIComponent(accessUrl)}`;\n },\n // getSubjectLink(subject) {\n // return { path: `/datasets?subject=${subject.id}`, query: Object.assign({}, { locale: this.$route.query.locale }) };\n // },\n toggleDistribution(id) {\n const index = this.expandedDistributions.indexOf(id);\n if (index > -1) this.expandedDistributions.splice(index, 1);\n else this.expandedDistributions.push(id);\n },\n toggleDistributionDescription(id) {\n const index = this.expandedDistributionDescriptions.indexOf(id);\n if (index > -1) this.expandedDistributionDescriptions.splice(index, 1);\n else this.expandedDistributionDescriptions.push(id);\n },\n setTranslationBanners() {\n if (!this.$i18n) return;\n const translationMetaData = this.getTranslationMetaData;\n // Check if translation of dataset is available in selected language\n if (!isNil(translationMetaData.details) && has(translationMetaData.details, this.$route.query.locale)) {\n // Check if dataset if machine translated\n this.machineTranslated = translationMetaData.details[this.$route.query.locale].machine_translated;\n } else {\n // No translation of this dataset available for the selected language\n this.translationNotAvailable = true;\n }\n },\n // Emit a Matomo event when user clicks on 'go to resource' element\n trackGoto() {\n const paq = window._paq || []; // eslint-disable-line\n // paq.push(['trackEvent', 'GoToResource', 'Clicked']);\n this.$piwik.trackGotoResource();\n },\n clamp(n, min, max) {\n return Math.min(Math.max(n, min), max);\n },\n // Increases the current number of distributions displayed\n // and clamps the result so that it never exceeds the number of all distributions.\n increaseNumDisplayedDistributions(increment) {\n const clampedSum = this.clamp(this.distributions.displayCount + increment, 0, this.getDistributions.length);\n this.distributions.displayCount = clampedSum;\n },\n nonOverflowingIncrementsForDistributions(incrementStep) {\n return this.distributions.displayCount + incrementStep <= this.getDistributions.length;\n },\n // Increases the current number of distributions displayed\n // and clamps the result so that it never exceeds the number of all distributions.\n increaseNumDisplayedPages(increment) {\n const clampedSum = this.clamp(this.pages.displayCount + increment, 0, this.getPages.length);\n this.pages.displayCount = clampedSum;\n },\n nonOverflowingIncrementsForPages(incrementStep) {\n return this.pages.displayCount + incrementStep <= this.getPages.length;\n },\n piwikMetaPush() {\n this.$piwik.trackDatasetDetailsPageView(null, null, {\n dataset_AccessRights: this.getAccessRights,\n dataset_AccrualPeriodicity: this.getAccrualPeriodicity,\n dataset_Catalog: this.getCatalog,\n // dataset_Categories: this.getCategories,\n // dataset_ConformsTo: this.getConformsTo,\n // dataset_ContactPoints: this.getContactPoints,\n // dataset_Country: this.getCountry,\n // dataset_Creator: this.getCreator,\n // dataset_Description: this.getDescription,\n // dataset_Distributions: this.getDistributions,\n // dataset_DistributionFormats: this.getDistributionFormats,\n // dataset_Documentations: this.getDocumentations,\n // dataset_Frequency: this.getFrequency,\n // dataset_HasVersion: this.getHasVersion,\n dataset_ID: this.getID,\n // dataset_Identifiers: this.getIdentifiers,\n // dataset_IdName: this.getIdName,\n // dataset_IsVersionOf: this.getIsVersionOf,\n // datest_Keywords: this.getKeywords,\n // dataset_LandingPages: this.getLandingPagesResource,\n // dataset_Languages: this.getLanguages,\n // dataset_Licences: this.getLicences,\n // dataset_Loading: this.getLoading,\n // dataset_ModificationDate: this.getModificationDate,\n // dataset_OriginalLanguage: this.getOriginalLanguage,\n // dataset_OtherIdentifiers: this.getOtherIdentifiers,\n // dataset_Pages: this.getPages,\n // dataset_Provenances: this.getProvenances,\n dataset_Publisher: this.getPublisher,\n // dataset_RelatedResources: this.getRelatedResources,\n // dataset_ReleaseDate: this.getReleaseDate,\n // dataset_Sources: this.getSources,\n // dataset_Spatial: this.getSpatial,\n // dataset_SpatialResource: this.getSpatialResource,\n // dataset_Temporal: this.getTemporal,\n dataset_Title: this.getTitle,\n // dataset_TranslationMetaData: this.getTranslationMetaData,\n // dataset_VersionInfo: this.getVersionInfo,\n // dataset_VersionNotes: this.getVersionNotes,\n dataset_type: this.getIsHvd ? 'High-Value Dataset' : 'Dataset',\n dataset_scope: this.getCountry?.id === 'io'\n ? 'International Data'\n : this.getCountry?.id === 'eu'\n ? 'European Union Data'\n : 'National Data',\n dataset_provenance: this.getCountry?.name || this.getCountry?.id || '',\n dataset_category: this.getCategories?.map(category => category.label?.en || category.id).filter(Boolean)\n\n });\n },\n isUrlInvalid(url) {\n if (url) {\n try {\n /* eslint-disable no-useless-escape */\n return !(new RegExp(\"^((https?:\\/\\/(www\\.)?)([-a-zA-Z0-9@:%._\\+~#=]{1,256})([-a-zA-Z0-9()@:%_\\+.~#?&//=]*))$\", \"i\")).test(decodeURIComponent(url.split(\"=\").pop()));\n /* eslint-enable no-useless-escape */\n } catch (e) {\n console.error(e);\n }\n }\n },\n openIfValidUrl(isValid, previewLinkCallback, distribution, event) {\n if (isValid) {\n // for (let key in this.$children) {\n // if(this.$children[key].$refs[\"externalResourceModal\"]) {\n // this.$children[key].$refs[\"externalResourceModal\"].openModal(previewLinkCallback(distribution), false);\n // }\n // }\n this.openModal(previewLinkCallback(distribution), false);\n } else {\n event.preventDefault();\n event.stopPropagation();\n }\n },\n showTooltipVisualiseButton(invalidUrl) {\n if (invalidUrl) {\n return this.$t('message.tooltip.invalidVisualise');\n }\n return ''\n },\n },\n mounted() {\n // Duplicated API call, execute only if data not already loaded\n if (this.$route.params.ds_id !== this.getID) {\n this.$Progress.start();\n this.loadingDatasetDetails = true;\n this.loadDatasetDetails(this.$route.params.ds_id)\n .then(() => {\n this.$Progress.finish();\n this.loadingDatasetDetails = false;\n this.initDatasetDetails();\n })\n .catch((err) => {\n console.warn(err); // eslint-disable-line\n this.$Progress.fail();\n if (typeof this.$piwik?.resume === \"function\") this.$piwik.resume();\n this.$router.replace({\n name: 'NotFound',\n query: { locale: this.$route.query.locale, dataset: this.$route.params.ds_id },\n });\n })\n .finally(() => this.$root.$emit('contentLoaded'));\n } else {\n this.initDatasetDetails();\n this.$root.$emit('contentLoaded')\n }\n\n const distributionsConf = this.$env.content.datasetDetails && this.$env.content.datasetDetails.distributions;\n if (distributionsConf) {\n this.distributions.displayAll = distributionsConf.displayAll || this.distributions.displayAll;\n this.distributions.displayCount = parseInt(distributionsConf.displayCount, 10) || this.distributions.displayCount;\n\n if (typeof distributionsConf.incrementSteps === 'string') {\n // Need to parse as json array since env variables are string only\n distributionsConf.incrementSteps = JSON.parse(distributionsConf.incrementSteps);\n }\n this.distributions.incrementSteps = distributionsConf.incrementSteps || this.distributions.incrementSteps;\n }\n\n if (this.distributions.displayAll) this.distributions.displayCount = this.getDistributions.length;\n\n const pagesConf = this.$env.content.datasetDetails && this.$env.content.datasetDetails.pages;\n if (pagesConf) {\n this.pages.displayAll = pagesConf.displayAll || this.pages.displayAll;\n this.pages.displayCount = parseInt(pagesConf.displayCount, 10) || this.pages.displayCount;\n\n if (typeof pagesConf.incrementSteps === 'string') {\n // Need to parse as json array since env variables are string only\n pagesConf.incrementSteps = JSON.parse(pagesConf.incrementSteps);\n }\n this.pages.incrementSteps = pagesConf.incrementSteps || this.pages.incrementSteps;\n }\n\n if (this.pages.displayAll) this.pages.displayCount = this.getPages.length;\n },\n beforeUnmount() {\n $('.tooltip').remove();\n },\n setup() {\n metaInfo.useDatasetDetailsDatasetHead();\n }\n };\n</script>\n\n<style lang=\"scss\" scoped>\n\n .catalogue-label {\n white-space: pre-line;\n }\n\n .cursor-pointer {\n cursor: pointer;\n }\n\n .tag-color {\n background-color: var(--tag-color);\n }\n\n .btn-color {\n &:hover {\n background-color: #196fd2;\n border-color: #196fd2;\n }\n }\n\n .heading, .arrow, .copy-text {\n cursor: pointer;\n }\n\n .details-link {\n cursor: pointer;\n\n &:hover {\n text-decoration: underline;\n }\n }\n\n .text-break {\n word-break: break-word;\n }\n\n td {\n padding-left: 0 !important;\n padding-top: 1% !important;\n padding-bottom: 1% !important;\n }\n\n .download-all-btn {\n min-width: 100px;\n height: 31px;\n }\n\n .d-inline-table {\n display: inline-table;\n }\n\n /*** BOOTSTRAP ***/\n button:focus {\n outline:0;\n }\n .options, .download {\n .dropdown-menu {\n .dropdown-item {\n &:hover {\n color: initial;\n background-color: initial;\n }\n }\n }\n }\n.spinner-grow {\n width: 20px;\n height: 20px;\n}\n\n /*** FONT AWESOME ICONS ***/\n .fa-check-square {\n color: #28a745;\n width: 16px;\n height: 16px;\n }\n\n /*** MATERIAL ICONS ***/\n %modal-icon {\n font-size: 18px;\n cursor: default;\n }\n\n .help-icon {\n @extend %modal-icon;\n }\n\n .check-icon {\n @extend %modal-icon;\n color: #28a745;\n }\n\n .material-icons.small-icon {\n font-size: 20px;\n }\n\n .distributions {\n\n &__item {\n position: relative;\n\n &--preview {\n width: 100%;\n height: 100%;\n position: absolute;\n top: 0;\n left: 0;\n background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, white 55%);\n z-index: 10;\n }\n }\n\n &__actions {\n display: flex;\n justify-content: center;\n align-items: flex-end;\n height: 100%;\n z-index: 11;\n }\n }\n .mt-4 {\n margin-top: 1.5rem !important;\n }\n\n .keywords {\n\n &__item {\n position: relative;\n }\n\n &__actions {\n display: flex;\n justify-content: center;\n align-items: flex-end;\n height: 100%;\n z-index: 11;\n }\n }\n .sectionList {\n list-style-type: '→ ';\n margin-left:6.5%;\n }\n @media only screen and (max-width: 991px) {\n .sectionList {\n margin-left: 0;\n }\n}\n</style>\n"],"names":["_sfc_main","DatasetDetailsSkeleton","DatasetDetailsExtendedMetaData","AppLink","Tooltip","Distributions","ResourceAccessPopup","mapGetters","sorted","a","b","getTranslationFor","mapActions","has","isNil","isArray","isObject","isString","isNumber","appendCurrentLocaleToURL","getCountryFlagImg","truncate","replaceHttp","_a","$","count","callback","toggleDownloadPopup","distribution","date","dateFilters","string","number","object","keyUndefined","currentValue","array","objectArray","objectUndefined","currentObject","licence","url","keyword","originalLanguage","id","description","accessUrl","index","translationMetaData","n","min","max","increment","clampedSum","incrementStep","_b","_c","_d","_e","category","isValid","previewLinkCallback","event","invalidUrl","err","distributionsConf","pagesConf","metaInfo.useDatasetDetailsDatasetHead"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AA4GE,MAAeA,KAAA;AAAA,EACb,MAAM;AAAA,EACN,YAAY;AAAA,IACV,wBAAAC;AAAA,IAAA,gCACAC;AAAAA,IACA,SAAAC;AAAA,IACA,SAAAC;AAAA,IACA,eAAAC;AAAA,IACA,qBAAAC;AAAA,EACF;AAAA,EACA,OAAO;AAAA,IACL,4BAA4B;AAAA,MAC1B,MAAM;AAAA,MACN,SAAS,MAAM,CAAC,WAAW,4BAA4B,kBAAkB;AAAA,IAC3E;AAAA,IACA,6BAA6B;AAAA,MAC3B,MAAM;AAAA,MACN,SAAS,MAAM;AAAA,QACX;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,MACJ;AAAA,IACF;AAAA,IACA,w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AAM,aAAaA,EAAU,cAAc,KAAK,MAAM,YACtD,KAAA,MAAM,eAAe,SAASA,EAAU,cAAc,EAAE,KAAK,KAAK,MAAM,cAEzE,OAAOA,EAAU,kBAAmB,aAEtCA,EAAU,iBAAiB,KAAK,MAAMA,EAAU,cAAc,IAEhE,KAAK,MAAM,iBAAiBA,EAAU,kBAAkB,KAAK,MAAM,iBAGjE,KAAK,MAAM,eAAiB,KAAA,MAAM,eAAe,KAAK,SAAS;AAAA,EACrE;AAAA,EACA,gBAAgB;AACZ,IAAA1C,EAAA,UAAU,EAAE;EAChB;AAAA,EACA,QAAQ;AACN2C,IAAAA;EACF;AACF;"}
|
|
1
|
+
{"version":3,"file":"DatasetDetailsDataset.vue2.mjs","sources":["../../lib/datasetDetails/DatasetDetailsDataset.vue"],"sourcesContent":["<template>\n <div>\n <resource-access-popup ref=\"externalResourceModal\" />\n <span property=\"dc:issued\" :content=\"getReleaseDate\"></span>\n <span property=\"dc:modified\" :content=\"getModificationDate\"></span>\n <div v-if=\"loadingDatasetDetails\">\n <dataset-details-skeleton type=\"DatasetDetails\"></dataset-details-skeleton>\n </div>\n <div v-if=\"!loadingDatasetDetails\" class=\"dsd-dataset\">\n <dataset-details-description\n v-if=\"showDatasetDescription\"\n :dateIncorrect=\"dateIncorrect\"\n :machineTranslated=\"machineTranslated\"\n :translationNotAvailable=\"translationNotAvailable\"\n />\n <distributions\n :openModal=\"openModal\"\n :getDistributions=\"getDistributions\"\n :expandedDistributions=\"expandedDistributions\"\n :expandedDistributionDescriptions=\"expandedDistributionDescriptions\"\n :displayedDistributions=\"displayedDistributions\"\n :isDistributionsAllDisplayed=\"isDistributionsAllDisplayed\"\n :distributions=\"distributions\"\n :setDistributionsDisplayCount=\"setDistributionsDisplayCount\"\n :pages=\"pages\"\n :showDownloadUrls=\"showDownloadUrls\"\n :isOnlyOneUrl=\"isOnlyOneUrl\"\n :getDistributionFormat=\"getDistributionFormat\"\n :distributionFormatTruncated=\"distributionFormatTruncated\"\n :getDistributionTitle=\"getDistributionTitle\"\n :distributionVisibleContent=\"distributionVisibleContent\"\n :distributionExpandedContent=\"distributionExpandedContent\"\n :distributionDescriptionIsExpanded=\"distributionDescriptionIsExpanded\"\n :distributionDescriptionIsExpandable=\"distributionDescriptionIsExpandable\"\n :distributionIsExpanded=\"distributionIsExpanded\"\n :showNumber=\"showNumber\"\n :showObject=\"showObject\"\n :showDownloadDropdown=\"showDownloadDropdown\"\n :showLicence=\"showLicence\"\n :showLicensingAssistant=\"showLicensingAssistant\"\n :filterDateFormatEU=\"filterDateFormatEU\"\n :showArray=\"showArray\"\n :showObjectArray=\"showObjectArray\"\n :getVisualisationLink=\"getVisualisationLink\"\n :getDownloadUrl=\"getDownloadUrl\"\n :trackGoto=\"trackGoto\"\n :showAccessUrls=\"showAccessUrls\"\n :replaceHttp=\"replaceHttp\"\n :previewLinkCallback=\"previewLinkCallback\"\n :toggleDistribution=\"toggleDistribution\"\n :toggleDistributionDescription=\"toggleDistributionDescription\"\n :increaseNumDisplayedDistributions=\"increaseNumDisplayedDistributions\"\n :nonOverflowingIncrementsForDistributions=\"nonOverflowingIncrementsForDistributions\"\n :appendCurrentLocaleToURL=\"appendCurrentLocaleToURL\"\n :isUrlInvalid=\"isUrlInvalid\"\n :openIfValidUrl=\"openIfValidUrl\"\n :showTooltipVisualiseButton=\"showTooltipVisualiseButton\"\n :showPublisher=\"showPublisher\"\n :embed=\"embed\"\n />\n <dataset-details-features\n :getKeywords=\"getKeywords\"\n :pages=\"pages\"\n :increaseNumDisplayedPages=\"increaseNumDisplayedPages\"\n :nonOverflowingIncrementsForPages=\"nonOverflowingIncrementsForPages\"\n :showKeyword=\"showKeyword\"\n :trackGoto=\"trackGoto\"\n :showObjectArray=\"showObjectArray\"\n :showArray=\"showArray\"\n :showObject=\"showObject\"\n />\n <dataset-details-properties v-if=\"showDatasetProperties\">\n <template #property-header><slot name=\"property-header\"></slot></template>\n <template #property-table-before><slot name=\"property-table-before\"></slot></template>\n <template #property-table><slot name=\"property-table\"></slot></template>\n <template #property-table-after><slot name=\"property-table-after\"></slot></template>\n </dataset-details-properties>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\">\n // @ts-nocheck\n /* eslint-disable no-confusing-arrow, no-nested-ternary, no-return-assign, no-confusing-arrow */\n import $ from 'jquery';\n import { mapActions, mapGetters } from 'vuex';\n import {\n has,\n isNil,\n isArray,\n isObject,\n isString,\n isNumber,\n isEmpty,\n } from 'lodash';\n import AppLink from '../widgets/AppLink.vue';\n import Tooltip from '../widgets/Tooltip.vue';\n import Distributions from './distributions/Distributions.vue';\n import dateFilters from '../filters/dateFilters';\n import {\n getTranslationFor, getCountryFlagImg, truncate, replaceHttp, appendCurrentLocaleToURL\n } from '../utils/helpers';\n import ResourceAccessPopup from '../widgets/ResourceAccessPopup.vue';\n import DatasetDetailsExtendedMetaData\n from \"../datasetDetails/features/DatasetDetailsIsUsedBy.vue\";\n import DatasetDetailsSkeleton from \"../datasetDetails/DatasetDetailsSkeleton.vue\";\n import * as metaInfo from '../composables/head';\n\n export default {\n name: 'datasetDetailsDataset',\n components: {\n DatasetDetailsSkeleton,\n DatasetDetailsExtendedMetaData,\n AppLink,\n Tooltip,\n Distributions,\n ResourceAccessPopup\n },\n props: {\n distributionVisibleContent: {\n type: Array,\n default: () => ['license', 'licenseAttributionByText', 'modificationDate'],\n },\n distributionExpandedContent: {\n type: Array,\n default: () => [\n 'releaseDate',\n 'language',\n 'availability',\n 'status',\n 'rights',\n 'mediaType',\n 'byteSize',\n 'checksum',\n 'pages',\n 'type',\n 'compressFormat',\n 'packageFormat',\n 'hasPolicy',\n 'conformsTo',\n 'spatialResolutionInMeters',\n 'temporalResolution',\n ],\n },\n showDatasetDescription: {\n type: Boolean,\n default: () => true,\n },\n showDatasetProperties: {\n type: Boolean,\n default: () => true,\n },\n showPublisher: {\n type: Boolean,\n default: () => false,\n },\n embed: {\n type: Boolean,\n default: () => false,\n },\n },\n data() {\n return {\n defaultLocale: this.$env.languages.locale,\n // has to be INITIAL_DATASET_DESCRIPTION_LENGTH\n isDatasetDescriptionExpanded: false,\n loadingDatasetDetails: false,\n machineTranslated: false,\n translationNotAvailable: false,\n expandedDistributions: [],\n expandedDistributionDescriptions: [],\n distributions: {\n displayAll: this.$env.content.datasetDetails.distributions.displayAll,\n displayCount: this.$env.content.datasetDetails.distributions.displayCount,\n incrementSteps: this.$env.content.datasetDetails.distributions.incrementSteps,\n descriptionMaxLines: this.$env.content.datasetDetails.distributions.descriptionMaxLines,\n descriptionMaxChars: this.$env.content.datasetDetails.distributions.descriptionMaxChars,\n licencingAssistantUrl: this.$env.content.datasetDetails.distributions.licencingAssistantUrl,\n },\n pages: {\n isVisible: this.$env.content.datasetDetails.pages.isVisible,\n displayAll: this.$env.content.datasetDetails.pages.displayAll,\n displayCount: this.$env.content.datasetDetails.pages.displayCount,\n incrementSteps: this.$env.content.datasetDetails.pages.incrementSteps,\n descriptionMaxLines: this.$env.content.datasetDetails.pages.descriptionMaxLines,\n descriptionMaxChars: this.$env.content.datasetDetails.pages.descriptionMaxChars,\n },\n showDescription: true,\n };\n },\n computed: {\n // import store-getters\n ...mapGetters('datasetDetails', [\n 'getKeywords',\n 'getAccessRights',\n 'getAccrualPeriodicity',\n 'getCatalog',\n 'getContactPoints',\n 'getDateIncorrect',\n 'getDescription',\n 'getDistributions',\n 'getID',\n 'getLanguages',\n 'getLicences',\n 'getModificationDate',\n 'getOtherIdentifiers',\n 'getPages',\n 'getPublisher',\n 'getReleaseDate',\n 'getSpatial',\n 'getTranslationMetaData',\n 'getTitle',\n 'getIsHvd',\n 'getHvdCategories',\n 'getCountry',\n 'getCategories',\n 'getLoading',\n ]),\n dateIncorrect() {\n return this.getDateIncorrect;\n },\n displayedDistributions() {\n const sorted = [...this.getDistributions].sort((a, b) => {\n if (getTranslationFor(a.title, this.$route.query.locale, this.getLanguages) < getTranslationFor(b.title, this.$route.query.locale, this.getLanguages)) { return -1; }\n if (getTranslationFor(a.title, this.$route.query.locale, this.getLanguages) > getTranslationFor(b.title, this.$route.query.locale, this.getLanguages)) { return 1; }\n return 0;\n });\n return this.distributions.displayAll\n ? Object.freeze(sorted)\n : Object.freeze(sorted.slice(0, this.distributions.displayCount));\n },\n isDistributionsAllDisplayed() {\n return this.distributions.displayCount === this.getDistributions.length;\n },\n remainingDistributions() {\n return this.getDistributions.length - this.distributions.displayCount;\n }\n },\n watch: {\n getLoading: {\n handler(newVal, oldVal) {\n const isLoadingStopped = !newVal && oldVal;\n const isAlreadyLoadedSuccessfully = !newVal && !oldVal && this.getID;\n if (isLoadingStopped || isAlreadyLoadedSuccessfully) {\n this.piwikMetaPush();\n }\n },\n immediate: true\n }\n },\n methods: {\n ...mapActions('datasetDetails', [\n 'loadDatasetDetails',\n 'setLoading',\n ]),\n has,\n isNil,\n isArray,\n isObject,\n isString,\n isNumber,\n appendCurrentLocaleToURL,\n getTranslationFor,\n getCountryFlagImg,\n truncate,\n replaceHttp,\n initDatasetDetails() {\n setTimeout(() => {\n if (typeof this.$piwik?.resume === \"function\") this.$piwik.resume();\n }, 500);\n this.$nextTick(() => {\n // Display/hide translation banners\n this.setTranslationBanners();\n $('[data-toggle=\"tooltip\"]').tooltip({\n container: 'body',\n });\n });\n },\n setDistributionsDisplayCount(count: number) {\n this.distributions.displayCount = count;\n },\n openModal(callback, toggleDownloadPopup) {\n this.$refs.externalResourceModal.openModal(callback, toggleDownloadPopup)\n },\n previewLinkCallback(distribution) {\n return () => {\n this.$emit('track-link', this.getVisualisationLink(distribution), 'link');\n window.open(this.getVisualisationLink(distribution), '_blank');\n };\n },\n filterDateFormatEU(date) {\n return dateFilters.formatEU(date);\n },\n /* ABSTRACT SHOW FUNCTIONS */\n showString(string) {\n return !isNil(string) && isString(string);\n },\n showNumber(number) {\n return !isNil(number) && isNumber(number);\n },\n showObject(object) {\n return !isNil(object) && isObject(object) && !Object.values(object).reduce((keyUndefined, currentValue) => keyUndefined && currentValue === undefined, true);\n },\n showArray(array) {\n return !isNil(array) && isArray(array) && array.length > 0;\n },\n showObjectArray(objectArray) {\n return this.showArray(objectArray) && !objectArray.reduce((objectUndefined, currentObject) => objectUndefined && Object.values(currentObject).reduce((keyUndefined, currentValue) => keyUndefined && currentValue === undefined, true), true);\n },\n /* SPECIFIC SHOW FUNCTIONS */\n /* for now show all licences */\n showLicence(licence) {\n // return (has(licence, 'id') && !isNil(licence.id))\n // || (has(licence, 'label') && !isNil(licence.label))\n return true\n },\n showLicensingAssistant(distribution) {\n return has(distribution, 'licence.la_url') && this.showString(distribution.licence.la_url);\n },\n showDownloadDropdown(distribution) {\n return this.showAccessUrls(distribution) || this.showDownloadUrls(distribution);\n },\n isOnlyOneUrl(distribution) {\n return (this.showAccessUrls(distribution) && !this.showDownloadUrls(distribution))\n || (!this.showAccessUrls(distribution) && this.showDownloadUrls(distribution) && distribution.downloadUrls.length === 1);\n },\n getDownloadUrl(distribution) {\n let url;\n if (this.showAccessUrls(distribution) && !this.showDownloadUrls(distribution)) {\n url = distribution.accessUrl[0];\n }\n if (!this.showAccessUrls(distribution) && this.showDownloadUrls(distribution) && distribution.downloadUrls.length === 1) {\n url = distribution.downloadUrls[0];\n }\n return url;\n },\n showAccessUrls(distribution) {\n return has(distribution, 'accessUrl') && this.showArray(distribution.accessUrl);\n },\n showDownloadUrls(distribution) {\n return has(distribution, 'downloadUrls') && this.showArray(distribution.downloadUrls);\n },\n showKeyword(keyword) {\n return has(keyword, 'id')\n && has(keyword, 'title')\n && !isNil(keyword.id)\n && !isNil(keyword.title);\n },\n\n /* GETTER / SETTER FUNCTIONS */\n\n setDatasetOriginalLanguage(originalLanguage) {\n this.$i18n.locale = originalLanguage;\n },\n distributionIsExpanded(id) {\n setTimeout(() => {\n $('[data-toggle=\"tooltip\"]').tooltip({\n container: 'body',\n });\n }, 500);\n return this.expandedDistributions.includes(id);\n },\n distributionDescriptionIsExpanded(id) {\n return this.expandedDistributionDescriptions.includes(id);\n },\n distributionDescriptionIsExpandable(description) {\n return isNil(description) ? false : description.length > this.distributions.descriptionMaxChars;\n },\n getDistributionFormat(distribution) {\n return has(distribution, 'format.label') && !isNil(distribution.format.label) ? distribution.format.label : '';\n },\n distributionFormatTruncated(distribution) {\n return this.getDistributionFormat(distribution).length > 4;\n },\n getDistributionTitle(distribution) {\n return distribution.title\n ? getTranslationFor(distribution.title, this.$route.query.locale, this.getLanguages)\n : this.getID || '-';\n },\n getVisualisationLink(distribution) {\n // Return Visualisation Link\n const accessUrl = distribution.downloadUrls && distribution.downloadUrls.length ? distribution.downloadUrls[0] : distribution.accessUrl[0];\n return `/data/visualisation/?file=${encodeURIComponent(accessUrl)}`;\n },\n // getSubjectLink(subject) {\n // return { path: `/datasets?subject=${subject.id}`, query: Object.assign({}, { locale: this.$route.query.locale }) };\n // },\n toggleDistribution(id) {\n const index = this.expandedDistributions.indexOf(id);\n if (index > -1) this.expandedDistributions.splice(index, 1);\n else this.expandedDistributions.push(id);\n },\n toggleDistributionDescription(id) {\n const index = this.expandedDistributionDescriptions.indexOf(id);\n if (index > -1) this.expandedDistributionDescriptions.splice(index, 1);\n else this.expandedDistributionDescriptions.push(id);\n },\n setTranslationBanners() {\n if (!this.$i18n) return;\n const translationMetaData = this.getTranslationMetaData;\n // Check if translation of dataset is available in selected language\n if (!isNil(translationMetaData.details) && has(translationMetaData.details, this.$route.query.locale)) {\n // Check if dataset if machine translated\n this.machineTranslated = translationMetaData.details[this.$route.query.locale].machine_translated;\n } else {\n // No translation of this dataset available for the selected language\n this.translationNotAvailable = true;\n }\n },\n // Emit a Matomo event when user clicks on 'go to resource' element\n trackGoto() {\n const paq = window._paq || []; // eslint-disable-line\n // paq.push(['trackEvent', 'GoToResource', 'Clicked']);\n this.$piwik.trackGotoResource();\n },\n clamp(n, min, max) {\n return Math.min(Math.max(n, min), max);\n },\n // Increases the current number of distributions displayed\n // and clamps the result so that it never exceeds the number of all distributions.\n increaseNumDisplayedDistributions(increment) {\n const clampedSum = this.clamp(this.distributions.displayCount + increment, 0, this.getDistributions.length);\n this.distributions.displayCount = clampedSum;\n },\n nonOverflowingIncrementsForDistributions(incrementStep) {\n return this.distributions.displayCount + incrementStep <= this.getDistributions.length;\n },\n // Increases the current number of distributions displayed\n // and clamps the result so that it never exceeds the number of all distributions.\n increaseNumDisplayedPages(increment) {\n const clampedSum = this.clamp(this.pages.displayCount + increment, 0, this.getPages.length);\n this.pages.displayCount = clampedSum;\n },\n nonOverflowingIncrementsForPages(incrementStep) {\n return this.pages.displayCount + incrementStep <= this.getPages.length;\n },\n async piwikMetaPush() {\n await this.$nextTick();\n const obj = {\n dataset_AccessRights: this.getAccessRights,\n dataset_AccrualPeriodicity: this.getAccrualPeriodicity,\n dataset_Catalog: this.getCatalog,\n // dataset_Categories: this.getCategories,\n // dataset_ConformsTo: this.getConformsTo,\n // dataset_ContactPoints: this.getContactPoints,\n // dataset_Country: this.getCountry,\n // dataset_Creator: this.getCreator,\n // dataset_Description: this.getDescription,\n // dataset_Distributions: this.getDistributions,\n // dataset_DistributionFormats: this.getDistributionFormats,\n // dataset_Documentations: this.getDocumentations,\n // dataset_Frequency: this.getFrequency,\n // dataset_HasVersion: this.getHasVersion,\n dataset_ID: this.getID,\n // dataset_Identifiers: this.getIdentifiers,\n // dataset_IdName: this.getIdName,\n // dataset_IsVersionOf: this.getIsVersionOf,\n // datest_Keywords: this.getKeywords,\n // dataset_LandingPages: this.getLandingPagesResource,\n // dataset_Languages: this.getLanguages,\n // dataset_Licences: this.getLicences,\n // dataset_Loading: this.getLoading,\n // dataset_ModificationDate: this.getModificationDate,\n // dataset_OriginalLanguage: this.getOriginalLanguage,\n // dataset_OtherIdentifiers: this.getOtherIdentifiers,\n // dataset_Pages: this.getPages,\n // dataset_Provenances: this.getProvenances,\n dataset_Publisher: this.getPublisher,\n // dataset_RelatedResources: this.getRelatedResources,\n // dataset_ReleaseDate: this.getReleaseDate,\n // dataset_Sources: this.getSources,\n // dataset_Spatial: this.getSpatial,\n // dataset_SpatialResource: this.getSpatialResource,\n // dataset_Temporal: this.getTemporal,\n dataset_Title: this.getTitle,\n // dataset_TranslationMetaData: this.getTranslationMetaData,\n // dataset_VersionInfo: this.getVersionInfo,\n // dataset_VersionNotes: this.getVersionNotes,\n dataset_type: this.getIsHvd ? 'High-Value Dataset' : 'Dataset',\n dataset_scope: this.getCountry?.id === 'io'\n ? 'International Data'\n : this.getCountry?.id === 'eu'\n ? 'European Union Data'\n : 'National Data',\n dataset_provenance: this.getCountry?.name || this.getCountry?.id || '',\n dataset_category: this.getCategories?.map(category => category.label?.en || category.id).filter(Boolean)\n\n };\n this.$piwik.trackDatasetDetailsPageView(null, null, obj);\n },\n isUrlInvalid(url) {\n if (url) {\n try {\n /* eslint-disable no-useless-escape */\n return !(new RegExp(\"^((https?:\\/\\/(www\\.)?)([-a-zA-Z0-9@:%._\\+~#=]{1,256})([-a-zA-Z0-9()@:%_\\+.~#?&//=]*))$\", \"i\")).test(decodeURIComponent(url.split(\"=\").pop()));\n /* eslint-enable no-useless-escape */\n } catch (e) {\n console.error(e);\n }\n }\n },\n openIfValidUrl(isValid, previewLinkCallback, distribution, event) {\n if (isValid) {\n // for (let key in this.$children) {\n // if(this.$children[key].$refs[\"externalResourceModal\"]) {\n // this.$children[key].$refs[\"externalResourceModal\"].openModal(previewLinkCallback(distribution), false);\n // }\n // }\n this.openModal(previewLinkCallback(distribution), false);\n } else {\n event.preventDefault();\n event.stopPropagation();\n }\n },\n showTooltipVisualiseButton(invalidUrl) {\n if (invalidUrl) {\n return this.$t('message.tooltip.invalidVisualise');\n }\n return ''\n },\n },\n mounted() {\n // Duplicated API call, execute only if data not already loaded\n if (this.$route.params.ds_id !== this.getID) {\n this.$Progress.start();\n this.loadingDatasetDetails = true;\n this.loadDatasetDetails(this.$route.params.ds_id)\n .then(() => {\n this.$Progress.finish();\n this.loadingDatasetDetails = false;\n this.initDatasetDetails();\n })\n .catch((err) => {\n console.warn(err); // eslint-disable-line\n this.$Progress.fail();\n if (typeof this.$piwik?.resume === \"function\") this.$piwik.resume();\n this.$router.replace({\n name: 'NotFound',\n query: { locale: this.$route.query.locale, dataset: this.$route.params.ds_id },\n });\n })\n .finally(() => this.$root.$emit('contentLoaded'));\n } else {\n this.initDatasetDetails();\n this.$root.$emit('contentLoaded')\n }\n\n const distributionsConf = this.$env.content.datasetDetails && this.$env.content.datasetDetails.distributions;\n if (distributionsConf) {\n this.distributions.displayAll = distributionsConf.displayAll || this.distributions.displayAll;\n this.distributions.displayCount = parseInt(distributionsConf.displayCount, 10) || this.distributions.displayCount;\n\n if (typeof distributionsConf.incrementSteps === 'string') {\n // Need to parse as json array since env variables are string only\n distributionsConf.incrementSteps = JSON.parse(distributionsConf.incrementSteps);\n }\n this.distributions.incrementSteps = distributionsConf.incrementSteps || this.distributions.incrementSteps;\n }\n\n if (this.distributions.displayAll) this.distributions.displayCount = this.getDistributions.length;\n\n const pagesConf = this.$env.content.datasetDetails && this.$env.content.datasetDetails.pages;\n if (pagesConf) {\n this.pages.displayAll = pagesConf.displayAll || this.pages.displayAll;\n this.pages.displayCount = parseInt(pagesConf.displayCount, 10) || this.pages.displayCount;\n\n if (typeof pagesConf.incrementSteps === 'string') {\n // Need to parse as json array since env variables are string only\n pagesConf.incrementSteps = JSON.parse(pagesConf.incrementSteps);\n }\n this.pages.incrementSteps = pagesConf.incrementSteps || this.pages.incrementSteps;\n }\n\n if (this.pages.displayAll) this.pages.displayCount = this.getPages.length;\n },\n beforeUnmount() {\n $('.tooltip').remove();\n },\n setup() {\n metaInfo.useDatasetDetailsDatasetHead();\n }\n };\n</script>\n\n<style lang=\"scss\" scoped>\n\n .catalogue-label {\n white-space: pre-line;\n }\n\n .cursor-pointer {\n cursor: pointer;\n }\n\n .tag-color {\n background-color: var(--tag-color);\n }\n\n .btn-color {\n &:hover {\n background-color: #196fd2;\n border-color: #196fd2;\n }\n }\n\n .heading, .arrow, .copy-text {\n cursor: pointer;\n }\n\n .details-link {\n cursor: pointer;\n\n &:hover {\n text-decoration: underline;\n }\n }\n\n .text-break {\n word-break: break-word;\n }\n\n td {\n padding-left: 0 !important;\n padding-top: 1% !important;\n padding-bottom: 1% !important;\n }\n\n .download-all-btn {\n min-width: 100px;\n height: 31px;\n }\n\n .d-inline-table {\n display: inline-table;\n }\n\n /*** BOOTSTRAP ***/\n button:focus {\n outline:0;\n }\n .options, .download {\n .dropdown-menu {\n .dropdown-item {\n &:hover {\n color: initial;\n background-color: initial;\n }\n }\n }\n }\n.spinner-grow {\n width: 20px;\n height: 20px;\n}\n\n /*** FONT AWESOME ICONS ***/\n .fa-check-square {\n color: #28a745;\n width: 16px;\n height: 16px;\n }\n\n /*** MATERIAL ICONS ***/\n %modal-icon {\n font-size: 18px;\n cursor: default;\n }\n\n .help-icon {\n @extend %modal-icon;\n }\n\n .check-icon {\n @extend %modal-icon;\n color: #28a745;\n }\n\n .material-icons.small-icon {\n font-size: 20px;\n }\n\n .distributions {\n\n &__item {\n position: relative;\n\n &--preview {\n width: 100%;\n height: 100%;\n position: absolute;\n top: 0;\n left: 0;\n background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, white 55%);\n z-index: 10;\n }\n }\n\n &__actions {\n display: flex;\n justify-content: center;\n align-items: flex-end;\n height: 100%;\n z-index: 11;\n }\n }\n .mt-4 {\n margin-top: 1.5rem !important;\n }\n\n .keywords {\n\n &__item {\n position: relative;\n }\n\n &__actions {\n display: flex;\n justify-content: center;\n align-items: flex-end;\n height: 100%;\n z-index: 11;\n }\n }\n .sectionList {\n list-style-type: '→ ';\n margin-left:6.5%;\n }\n @media only screen and (max-width: 991px) {\n .sectionList {\n margin-left: 0;\n }\n}\n</style>\n"],"names":["_sfc_main","DatasetDetailsSkeleton","DatasetDetailsExtendedMetaData","AppLink","Tooltip","Distributions","ResourceAccessPopup","mapGetters","sorted","a","b","getTranslationFor","newVal","oldVal","isLoadingStopped","isAlreadyLoadedSuccessfully","mapActions","has","isNil","isArray","isObject","isString","isNumber","appendCurrentLocaleToURL","getCountryFlagImg","truncate","replaceHttp","_a","$","count","callback","toggleDownloadPopup","distribution","date","dateFilters","string","number","object","keyUndefined","currentValue","array","objectArray","objectUndefined","currentObject","licence","url","keyword","originalLanguage","id","description","accessUrl","index","translationMetaData","n","min","max","increment","clampedSum","incrementStep","obj","_b","_c","_d","_e","category","isValid","previewLinkCallback","event","invalidUrl","err","distributionsConf","pagesConf","metaInfo.useDatasetDetailsDatasetHead"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AA4GE,MAAeA,KAAA;AAAA,EACb,MAAM;AAAA,EACN,YAAY;AAAA,IACV,wBAAAC;AAAA,IAAA,gCACAC;AAAAA,IACA,SAAAC;AAAA,IACA,SAAAC;AAAA,IACA,eAAAC;AAAA,IACA,qBAAAC;AAAA,EACF;AAAA,EACA,OAAO;AAAA,IACL,4BAA4B;AAAA,MAC1B,MAAM;AAAA,MACN,SAAS,MAAM,CAAC,WAAW,4BAA4B,kBAAkB;AAAA,IAC3E;AAAA,IACA,6BAA6B;AAAA,MAC3B,MAAM;AAAA,MACN,SAAS,MAAM;AAAA,QACX;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,MACJ;AAAA,IACF;AAAA,IACA,wBAAwB;AAAA,MACtB,MAAM;AAAA,MACN,SAAS,MAAM;AAAA,IACjB;AAAA,IACA,uBAAuB;AAAA,MACrB,MAAM;AAAA,MACN,SAAS,MAAM;AAAA,IACjB;AAAA,IACA,eAAe;AAAA,MACb,MAAM;AAAA,MACN,SAAS,MAAM;AAAA,IACjB;AAAA,IACA,OAAO;AAAA,MACL,MAAM;AAAA,MACN,SAAS,MAAM;AAAA,IACjB;AAAA,EACF;AAAA,EACA,OAAO;AACE,WAAA;AAAA,MACL,eAAe,KAAK,KAAK,UAAU;AAAA;AAAA,MAEnC,8BAA8B;AAAA,MAC9B,uBAAuB;AAAA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