@datagouv/components-next 0.2.0 → 1.0.1
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/README.md +1 -1
- package/assets/main.css +49 -22
- package/dist/Control-BNCDn-8E.js +148 -0
- package/dist/{Datafair.client-x39O4yfF.js → Datafair.client-B5lBpOl8.js} +2 -2
- package/dist/Event-BOgJUhNR.js +738 -0
- package/dist/Image-BN-4XkIn.js +247 -0
- package/dist/{JsonPreview.client-BMsC5JcY.js → JsonPreview.client-Doz1Z0BS.js} +23 -23
- package/dist/Map-BdT3i2C4.js +7609 -0
- package/dist/MapContainer.client-oiieO8H-.js +105 -0
- package/dist/OSM-CamriM9b.js +71 -0
- package/dist/PdfPreview.client-CdAhkDFJ.js +14513 -0
- package/dist/{Pmtiles.client-BaiIo4VZ.js → Pmtiles.client-B0v8tGJQ.js} +3 -3
- package/dist/ScaleLine-BiesrgOv.js +165 -0
- package/dist/Swagger.client-CsK65JnG.js +4 -0
- package/dist/Tile-DCuqwNOI.js +1206 -0
- package/dist/TileImage-CmZf8EdU.js +1067 -0
- package/dist/View-DcDc7N2K.js +2858 -0
- package/dist/{XmlPreview.client-CAdN0w_Y.js → XmlPreview.client-CrjHf74q.js} +17 -17
- package/dist/common-C4rDcQpp.js +243 -0
- package/dist/components-next.css +1 -1
- package/dist/components-next.js +158 -117
- package/dist/components.css +1 -1
- package/dist/{MapContainer.client-DeSo8EvG.js → index-Bbu9rOHt.js} +4975 -21416
- package/dist/leaflet-src-7m1mB8LI.js +6338 -0
- package/dist/{main-Dgri3TQL.js → main-CiH8ZmBI.js} +56973 -51462
- package/dist/proj-CKwYjU38.js +1569 -0
- package/dist/tilecoord-YW3qEH_j.js +884 -0
- package/dist/{vue3-xml-viewer.common-D6skc_Ai.js → vue3-xml-viewer.common-Bi_bsV6C.js} +1 -1
- package/package.json +6 -2
- package/src/components/ActivityList/ActivityList.vue +6 -2
- package/src/components/AppLink.vue +4 -1
- package/src/components/Avatar.vue +2 -2
- package/src/components/AvatarWithName.vue +8 -4
- package/src/components/BouncingDots.vue +21 -0
- package/src/components/BrandedButton.vue +2 -0
- package/src/components/CopyButton.vue +19 -7
- package/src/components/DataserviceCard.vue +85 -120
- package/src/components/DatasetCard.vue +110 -171
- package/src/components/DatasetInformation/DatasetEmbedSection.vue +43 -0
- package/src/components/DatasetInformation/DatasetInformationSection.vue +73 -0
- package/src/components/DatasetInformation/DatasetSchemaSection.vue +74 -0
- package/src/components/DatasetInformation/DatasetSpatialSection.vue +59 -0
- package/src/components/DatasetInformation/DatasetTemporalitySection.vue +45 -0
- package/src/components/DatasetInformation/index.ts +5 -0
- package/src/components/DatasetQuality.vue +23 -16
- package/src/components/DatasetQualityInline.vue +13 -17
- package/src/components/DatasetQualityScore.vue +12 -15
- package/src/components/DatasetQualityTooltipContent.vue +3 -3
- package/src/components/DescriptionList.vue +1 -4
- package/src/components/DescriptionListDetails.vue +5 -0
- package/src/components/DescriptionListTerm.vue +5 -0
- package/src/components/DiscussionMessageCard.vue +63 -0
- package/src/components/ExtraAccordion.vue +4 -4
- package/src/components/Form/BadgeSelect.vue +35 -0
- package/src/components/Form/FormatSelect.vue +28 -0
- package/src/components/Form/GeozoneSelect.vue +52 -0
- package/src/components/Form/GranularitySelect.vue +29 -0
- package/src/components/Form/LicenseSelect.vue +30 -0
- package/src/components/Form/OrganizationSelect.vue +62 -0
- package/src/components/Form/OrganizationTypeSelect.vue +34 -0
- package/src/components/Form/ReuseTopicSelect.vue +29 -0
- package/src/components/Form/SchemaSelect.vue +30 -0
- package/src/components/Form/SearchableSelect.vue +334 -0
- package/src/components/Form/SelectGroup.vue +132 -0
- package/src/components/Form/TagSelect.vue +38 -0
- package/src/components/LeafletMap.vue +31 -0
- package/src/components/LicenseBadge.vue +24 -0
- package/src/components/LoadingBlock.vue +23 -2
- package/src/components/MarkdownViewer.vue +3 -1
- package/src/components/ObjectCard.vue +42 -0
- package/src/components/ObjectCardBadge.vue +22 -0
- package/src/components/ObjectCardHeader.vue +35 -0
- package/src/components/ObjectCardOwner.vue +43 -0
- package/src/components/ObjectCardShortDescription.vue +28 -0
- package/src/components/OrganizationCard.vue +35 -20
- package/src/components/OrganizationHorizontalCard.vue +87 -0
- package/src/components/OrganizationLogo.vue +1 -1
- package/src/components/OrganizationNameWithCertificate.vue +12 -6
- package/src/components/OwnerTypeIcon.vue +1 -0
- package/src/components/Pagination.vue +1 -1
- package/src/components/Placeholder.vue +5 -2
- package/src/components/PostCard.vue +62 -0
- package/src/components/ProgressBar.vue +31 -0
- package/src/components/RadioGroup.vue +32 -0
- package/src/components/RadioInput.vue +64 -0
- package/src/components/ResourceAccordion/Datafair.client.vue +1 -1
- package/src/components/ResourceAccordion/EditButton.vue +2 -3
- package/src/components/ResourceAccordion/JsonPreview.client.vue +3 -3
- package/src/components/ResourceAccordion/MapContainer.client.vue +21 -17
- package/src/components/ResourceAccordion/Metadata.vue +11 -24
- package/src/components/ResourceAccordion/PdfPreview.client.vue +70 -74
- package/src/components/ResourceAccordion/Pmtiles.client.vue +2 -2
- package/src/components/ResourceAccordion/Preview.vue +2 -2
- package/src/components/ResourceAccordion/ResourceAccordion.vue +35 -28
- package/src/components/ResourceAccordion/ResourceIcon.vue +1 -0
- package/src/components/ResourceAccordion/SchemaBadge.vue +2 -2
- package/src/components/ResourceAccordion/XmlPreview.client.vue +3 -3
- package/src/components/ResourceExplorer/ResourceExplorer.vue +243 -0
- package/src/components/ResourceExplorer/ResourceExplorerSidebar.vue +116 -0
- package/src/components/ResourceExplorer/ResourceExplorerViewer.vue +410 -0
- package/src/components/ReuseCard.vue +8 -28
- package/src/components/ReuseHorizontalCard.vue +80 -0
- package/src/components/Search/BasicAndAdvancedFilters.vue +49 -0
- package/src/components/Search/Filter/AccessTypeFilter.vue +37 -0
- package/src/components/Search/Filter/DatasetBadgeFilter.vue +40 -0
- package/src/components/Search/Filter/FilterButtonGroup.vue +78 -0
- package/src/components/Search/Filter/FormatFamilyFilter.vue +39 -0
- package/src/components/Search/Filter/LastUpdateRangeFilter.vue +37 -0
- package/src/components/Search/Filter/ProducerTypeFilter.vue +49 -0
- package/src/components/Search/Filter/ReuseTypeFilter.vue +42 -0
- package/src/components/Search/GlobalSearch.vue +707 -0
- package/src/components/Search/SearchInput.vue +63 -0
- package/src/components/Search/Sidemenu.vue +38 -0
- package/src/components/StatBox.vue +5 -5
- package/src/components/Tag.vue +30 -0
- package/src/components/Toggletip.vue +11 -4
- package/src/components/Tooltip.vue +2 -3
- package/src/components/TopicCard.vue +134 -0
- package/src/components/radioGroupContext.ts +9 -0
- package/src/composables/useDebouncedRef.ts +31 -0
- package/src/composables/useHasTabularData.ts +15 -0
- package/src/composables/useMetrics.ts +4 -3
- package/src/composables/useResourceCapabilities.ts +131 -0
- package/src/composables/useRouteQueryBoolean.ts +10 -0
- package/src/composables/useSelectModelSync.ts +89 -0
- package/src/composables/useStableQueryParams.ts +84 -0
- package/src/composables/useTranslation.ts +2 -1
- package/src/config.ts +4 -0
- package/src/functions/api.ts +25 -6
- package/src/functions/api.types.ts +5 -3
- package/src/functions/datasets.ts +1 -29
- package/src/functions/description.ts +33 -0
- package/src/functions/helpers.ts +11 -0
- package/src/functions/markdown.ts +60 -16
- package/src/functions/metrics.ts +33 -0
- package/src/functions/organizations.ts +5 -5
- package/src/functions/resourceCapabilities.ts +55 -0
- package/src/main.ts +96 -7
- package/src/types/dataservices.ts +14 -12
- package/src/types/datasets.ts +20 -7
- package/src/types/discussions.ts +20 -0
- package/src/types/licenses.ts +3 -3
- package/src/types/organizations.ts +13 -1
- package/src/types/owned.ts +4 -2
- package/src/types/pages.ts +70 -0
- package/src/types/posts.ts +27 -0
- package/src/types/resources.ts +16 -0
- package/src/types/reuses.ts +14 -5
- package/src/types/search.ts +407 -0
- package/src/types/users.ts +12 -3
- package/dist/PdfPreview.client-COOkEkRA.js +0 -107
- package/dist/Swagger.client-CpLgaLg6.js +0 -4
- package/dist/pdf-vue3-IkJO65RH.js +0 -273
- package/dist/pdf.min-f72cfa08-CdgJTooZ.js +0 -9501
- package/src/components/DatasetInformationPanel.vue +0 -211
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { defineComponent as G, useTemplateRef as W, ref as z, onMounted as B, createBlock as F, createElementBlock as N, openBlock as u, withCtx as V, createVNode as U, createElementVNode as q, unref as m, toDisplayString as A } from "vue";
|
|
2
|
+
import { a as D, _ as O, F as P } from "./main-CiH8ZmBI.js";
|
|
3
|
+
const j = /* @__PURE__ */ G({
|
|
4
|
+
__name: "MapContainer.client",
|
|
5
|
+
props: {
|
|
6
|
+
resource: {}
|
|
7
|
+
},
|
|
8
|
+
setup(f) {
|
|
9
|
+
const a = f, { t: d } = D();
|
|
10
|
+
let e = null;
|
|
11
|
+
const r = W("mapRef"), n = z(!1);
|
|
12
|
+
async function w() {
|
|
13
|
+
const [
|
|
14
|
+
{ default: i },
|
|
15
|
+
{ default: s },
|
|
16
|
+
{ default: y },
|
|
17
|
+
{ default: h },
|
|
18
|
+
{ default: C },
|
|
19
|
+
_
|
|
20
|
+
] = await Promise.all([
|
|
21
|
+
import("./View-DcDc7N2K.js").then((t) => t.M),
|
|
22
|
+
import("./Map-BdT3i2C4.js").then((t) => t.U),
|
|
23
|
+
import("./ScaleLine-BiesrgOv.js"),
|
|
24
|
+
import("./Tile-DCuqwNOI.js").then((t) => t.d),
|
|
25
|
+
import("./OSM-CamriM9b.js"),
|
|
26
|
+
// @ts-expect-error no types provided
|
|
27
|
+
import("./index-Bbu9rOHt.js")
|
|
28
|
+
]), { CRS: g, GeoportalAttribution: S, GeoportalFullScreen: M, GeoportalZoom: b, LayerImport: v, LayerSwitcher: L } = _;
|
|
29
|
+
await Promise.resolve({ }), await Promise.resolve({ }), await Promise.resolve({ }), await Promise.resolve({ }), g.load(), e = new s({
|
|
30
|
+
target: r.value,
|
|
31
|
+
layers: [
|
|
32
|
+
new h({
|
|
33
|
+
source: new C()
|
|
34
|
+
})
|
|
35
|
+
],
|
|
36
|
+
view: new i({
|
|
37
|
+
center: [288074.8449901076, 6247982515792289e-9],
|
|
38
|
+
zoom: 8,
|
|
39
|
+
constrainResolution: !0
|
|
40
|
+
})
|
|
41
|
+
});
|
|
42
|
+
const R = new y({
|
|
43
|
+
units: "metric",
|
|
44
|
+
bar: !1
|
|
45
|
+
});
|
|
46
|
+
e.addControl(R);
|
|
47
|
+
const k = new M({
|
|
48
|
+
position: "top-right"
|
|
49
|
+
});
|
|
50
|
+
e.addControl(k);
|
|
51
|
+
const T = new b({
|
|
52
|
+
position: "bottom-left"
|
|
53
|
+
});
|
|
54
|
+
e.addControl(T);
|
|
55
|
+
const x = new L({
|
|
56
|
+
options: {
|
|
57
|
+
position: "top-right"
|
|
58
|
+
}
|
|
59
|
+
});
|
|
60
|
+
e.addControl(x);
|
|
61
|
+
const E = new S({
|
|
62
|
+
position: "bottom-right"
|
|
63
|
+
});
|
|
64
|
+
e.addControl(E);
|
|
65
|
+
const o = new v({
|
|
66
|
+
position: "bottom-left",
|
|
67
|
+
listable: !0,
|
|
68
|
+
layerTypes: ["WMS"]
|
|
69
|
+
});
|
|
70
|
+
o._serviceUrlImportInput.value = a.resource.url, o._formContainer.dispatchEvent(new CustomEvent("submit", { cancelable: !0 })), e.addControl(o);
|
|
71
|
+
const l = 500;
|
|
72
|
+
let p = 20;
|
|
73
|
+
function c() {
|
|
74
|
+
if (!o._getCapResponseWMSLayers)
|
|
75
|
+
p--, p > 0 ? setTimeout(c, l) : n.value = !0;
|
|
76
|
+
else {
|
|
77
|
+
const t = o._getCapResponseWMSLayers.filter((I) => I.Name == a.resource.title)[0];
|
|
78
|
+
o._addGetCapWMSLayer(t);
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
setTimeout(c, l);
|
|
82
|
+
}
|
|
83
|
+
return B(() => {
|
|
84
|
+
w();
|
|
85
|
+
}), (i, s) => n.value ? (u(), F(O, {
|
|
86
|
+
key: 0,
|
|
87
|
+
type: "warning",
|
|
88
|
+
class: "flex items-center space-x-2"
|
|
89
|
+
}, {
|
|
90
|
+
default: V(() => [
|
|
91
|
+
U(m(P), { class: "shrink-0 size-6" }),
|
|
92
|
+
q("span", null, A(m(d)("L'aperçu cartographique de ce fichier n'a pas pu être chargé.")), 1)
|
|
93
|
+
]),
|
|
94
|
+
_: 1
|
|
95
|
+
})) : (u(), N("div", {
|
|
96
|
+
key: 1,
|
|
97
|
+
id: "map",
|
|
98
|
+
ref_key: "mapRef",
|
|
99
|
+
ref: r
|
|
100
|
+
}, null, 512));
|
|
101
|
+
}
|
|
102
|
+
});
|
|
103
|
+
export {
|
|
104
|
+
j as default
|
|
105
|
+
};
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { T as l, c as n, e as c } from "./TileImage-CmZf8EdU.js";
|
|
2
|
+
class u extends l {
|
|
3
|
+
/**
|
|
4
|
+
* @param {Options} [options] XYZ options.
|
|
5
|
+
*/
|
|
6
|
+
constructor(e) {
|
|
7
|
+
e = e || {};
|
|
8
|
+
const r = e.projection !== void 0 ? e.projection : "EPSG:3857", t = e.tileGrid !== void 0 ? e.tileGrid : n({
|
|
9
|
+
extent: c(r),
|
|
10
|
+
maxResolution: e.maxResolution,
|
|
11
|
+
maxZoom: e.maxZoom,
|
|
12
|
+
minZoom: e.minZoom,
|
|
13
|
+
tileSize: e.tileSize
|
|
14
|
+
});
|
|
15
|
+
super({
|
|
16
|
+
attributions: e.attributions,
|
|
17
|
+
cacheSize: e.cacheSize,
|
|
18
|
+
crossOrigin: e.crossOrigin,
|
|
19
|
+
interpolate: e.interpolate,
|
|
20
|
+
projection: r,
|
|
21
|
+
reprojectionErrorThreshold: e.reprojectionErrorThreshold,
|
|
22
|
+
tileGrid: t,
|
|
23
|
+
tileLoadFunction: e.tileLoadFunction,
|
|
24
|
+
tilePixelRatio: e.tilePixelRatio,
|
|
25
|
+
tileUrlFunction: e.tileUrlFunction,
|
|
26
|
+
url: e.url,
|
|
27
|
+
urls: e.urls,
|
|
28
|
+
wrapX: e.wrapX !== void 0 ? e.wrapX : !0,
|
|
29
|
+
transition: e.transition,
|
|
30
|
+
attributionsCollapsible: e.attributionsCollapsible,
|
|
31
|
+
zDirection: e.zDirection
|
|
32
|
+
}), this.gutter_ = e.gutter !== void 0 ? e.gutter : 0;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* @return {number} Gutter.
|
|
36
|
+
* @override
|
|
37
|
+
*/
|
|
38
|
+
getGutter() {
|
|
39
|
+
return this.gutter_;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
const d = '© <a href="https://www.openstreetmap.org/copyright" target="_blank">OpenStreetMap</a> contributors.';
|
|
43
|
+
class m extends u {
|
|
44
|
+
/**
|
|
45
|
+
* @param {Options} [options] Open Street Map options.
|
|
46
|
+
*/
|
|
47
|
+
constructor(e) {
|
|
48
|
+
e = e || {};
|
|
49
|
+
let r;
|
|
50
|
+
e.attributions !== void 0 ? r = e.attributions : r = [d];
|
|
51
|
+
const t = e.crossOrigin !== void 0 ? e.crossOrigin : "anonymous", a = e.url !== void 0 ? e.url : "https://tile.openstreetmap.org/{z}/{x}/{y}.png";
|
|
52
|
+
super({
|
|
53
|
+
attributions: r,
|
|
54
|
+
attributionsCollapsible: !1,
|
|
55
|
+
cacheSize: e.cacheSize,
|
|
56
|
+
crossOrigin: t,
|
|
57
|
+
interpolate: e.interpolate,
|
|
58
|
+
maxZoom: e.maxZoom !== void 0 ? e.maxZoom : 19,
|
|
59
|
+
reprojectionErrorThreshold: e.reprojectionErrorThreshold,
|
|
60
|
+
tileLoadFunction: e.tileLoadFunction,
|
|
61
|
+
transition: e.transition,
|
|
62
|
+
url: a,
|
|
63
|
+
wrapX: e.wrapX,
|
|
64
|
+
zDirection: e.zDirection
|
|
65
|
+
});
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
export {
|
|
69
|
+
d as ATTRIBUTION,
|
|
70
|
+
m as default
|
|
71
|
+
};
|