@piveau/dpi 0.2.0-alpha.14 → 0.2.0-alpha.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (68) hide show
  1. package/dist/assets/dpi.css +1 -1
  2. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/AboutProject.vue.js +46 -48
  3. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/DPIHome.vue.js +48 -31
  4. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/HomeTable.vue.js +107 -88
  5. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ProjectTable.vue.js +1 -1
  6. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ProjectTable.vue2.js +86 -62
  7. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/services/dpiV3_apis.js +36 -68
  8. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/BasicInfosStep/ProjectDescriptionStep.vue.js +14 -14
  9. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/BasicInfosStep/ProjectNameStep.vue.js +7 -4
  10. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/BasicInfosStep/ProjectOrganisationStep.vue.js +2 -2
  11. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/BasicInfosStep/ProjectOrganisationStep.vue2.js +26 -27
  12. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/BasicInfosStep/ProjectStatusStep.vue.js +8 -8
  13. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DataCollection/BasicInformationStep.vue.js +2 -2
  14. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DataCollection/BasicInformationStep.vue2.js +19 -19
  15. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DataProcessing/BasicInformationStep.vue.js +2 -2
  16. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DataProcessing/BasicInformationStep.vue2.js +38 -39
  17. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DataSimulation/BasicInformationStep.vue.js +2 -2
  18. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DataSimulation/BasicInformationStep.vue2.js +72 -67
  19. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DataVisualisation/BasicInformationStep.vue.js +1 -1
  20. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DataVisualisation/BasicInformationStep.vue2.js +84 -97
  21. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Dropdown.vue.js +103 -88
  22. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Findability/ApplicationsStep.vue.js +1 -1
  23. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Findability/ApplicationsStep.vue2.js +18 -17
  24. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Findability/CategoriesStep.vue.js +2 -2
  25. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Findability/CategoriesStep.vue2.js +35 -28
  26. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Findability/DiscoverabilityStep.vue.js +11 -10
  27. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/InputField/InputFieldDefinition.js +4 -3
  28. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/InputField/InputFieldFormKit.vue.js +46 -40
  29. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/InputField.vue.js +144 -134
  30. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/OptionalDataStep/OptionalDataStep.vue.js +2 -2
  31. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/OptionalDataStep/OptionalDataStep.vue2.js +189 -155
  32. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/DatasetForm.vue.js +2 -2
  33. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/DatasetForm.vue2.js +44 -38
  34. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/HardwareForm.vue.js +2 -2
  35. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/HardwareForm.vue2.js +128 -123
  36. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/SoftwareForm.vue.js +2 -2
  37. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/SoftwareForm.vue2.js +50 -45
  38. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/utils.js +17 -17
  39. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ReviewStep/ReviewStep.vue.js +2 -2
  40. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ReviewStep/ReviewStep.vue2.js +337 -337
  41. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/SectionItems/CoverageModal.vue.js +38 -71
  42. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/SectionItems/CoverageModal.vue2.js +4 -0
  43. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/TableRowV3.vue.js +157 -141
  44. package/dist/packages/dpi/src/data-provider-interface/components/Spatial.vue.js +7 -0
  45. package/dist/packages/dpi/src/data-provider-interface/components/Spatial.vue2.js +172 -0
  46. package/dist/packages/dpi/src/data-provider-interface/components/SpatialPage.vue.js +7 -0
  47. package/dist/packages/dpi/src/data-provider-interface/components/SpatialPage.vue2.js +44 -0
  48. package/dist/packages/dpi/src/data-provider-interface/components/StepActionsSection.vue.js +1 -1
  49. package/dist/packages/dpi/src/data-provider-interface/components/StepActionsSection.vue2.js +2 -2
  50. package/dist/packages/dpi/src/data-provider-interface/components/TheErrorDialog.vue.js +57 -46
  51. package/dist/packages/dpi/src/data-provider-interface/composables/project-transformer/encodeProject.js +53 -55
  52. package/dist/packages/dpi/src/data-provider-interface/composables/useDpiEditMode.js +61 -59
  53. package/dist/packages/dpi/src/data-provider-interface/composables/useDpiSimpleLoader.js +185 -180
  54. package/dist/packages/dpi/src/data-provider-interface/composables/useDpiStepper.js +60 -61
  55. package/dist/packages/dpi/src/data-provider-interface/composables/useProjectActions.js +76 -46
  56. package/dist/packages/dpi/src/data-provider-interface/composables/useTwinbyHome.js +67 -34
  57. package/dist/packages/dpi/src/data-provider-interface/composables/useTwinbyUser.js +85 -0
  58. package/dist/packages/dpi/src/data-provider-interface/config/dcatapdeHappyFlow/converter.js +19 -19
  59. package/dist/packages/dpi/src/data-provider-interface/views/InputPage.vue.js +333 -308
  60. package/dist/packages/dpi/src/data-provider-interface/views/InputPageProject.vue.js +314 -307
  61. package/dist/packages/dpi/src/form/inputDefinitions.js +52 -53
  62. package/dist/packages/dpi/src/stories/components/PartnerCard.vue.js +2 -2
  63. package/dist/packages/dpi/src/stories/components/PartnerCard.vue2.js +14 -14
  64. package/dist/packages/dpi/src/stories/components/ScreenshotCard.vue.js +2 -2
  65. package/dist/packages/dpi/src/stories/components/ScreenshotCard.vue2.js +9 -8
  66. package/package.json +5 -5
  67. package/dist/packages/dpi/src/data-provider-interface/components/PolGeoUriPage.vue.js +0 -124
  68. package/dist/packages/dpi/src/data-provider-interface/composables/project-transformer/__tests__/fixtures/theProjectForm.js +0 -281
@@ -1,4 +1,4 @@
1
- import { defineJsonldResolver as Z, dcatDatasetTransformer as ee, datasetResolvers as te } from "@piveau/jsonld";
1
+ import { datasetResolvers as Z, defineJsonldResolver as ee, dcatDatasetTransformer as te } from "@piveau/jsonld";
2
2
  import { useAsyncState as re } from "@vueuse/core";
3
3
  import { isEmpty as ie } from "lodash-es";
4
4
  import { toRef as oe, ref as ae, toValue as F, computed as z, watch as K } from "vue";
@@ -19,67 +19,67 @@ function ne(e) {
19
19
  )
20
20
  );
21
21
  }
22
- function ve(e, i) {
23
- const { enabled: r, hubSearchUrl: t } = i, c = oe(r), { safeTransform: h } = Z({
22
+ function De(e, i) {
23
+ const { enabled: r, hubSearchUrl: t } = i, a = oe(r), R = [...Z()].filter((l) => l.name !== "licence"), { safeTransform: u } = ee({
24
24
  baseUrl: t,
25
- resolvers: te(),
26
- transformer: ee
27
- }), d = ae([]), {
28
- state: p,
29
- isReady: b,
30
- isLoading: g,
31
- error: m,
32
- execute: L
25
+ resolvers: R,
26
+ transformer: te
27
+ }), f = ae([]), {
28
+ state: m,
29
+ isReady: g,
30
+ isLoading: b,
31
+ error: L,
32
+ execute: T
33
33
  } = re(
34
34
  async () => {
35
35
  var A;
36
36
  if (!i.preprocess && !i.transform) {
37
- const a = await h(F(e));
38
- if (a.error)
39
- return d.value.push({
37
+ const n = await u(F(e));
38
+ if (n.error)
39
+ return f.value.push({
40
40
  code: "transform_failed",
41
- message: a.error.message
41
+ message: n.error.message
42
42
  }), null;
43
- const y = a.data;
44
- return (!y || !((A = y["dpi:isDPIv3"]) != null && A["@value"])) && d.value.push({
43
+ const y = n.data;
44
+ return (!y || !((A = y["dpi:isDPIv3"]) != null && A["@value"])) && f.value.push({
45
45
  code: "not_dpi_v3",
46
46
  message: `The dataset is not a DPI v3 dataset. ID ${y["@id"]}`
47
47
  }), {
48
- dpiData: ge(y),
48
+ dpiData: ge(y, i.visibility || "public"),
49
49
  data: y
50
50
  };
51
51
  }
52
52
  let D;
53
53
  if (i.preprocess)
54
54
  try {
55
- const a = await i.preprocess(F(e));
56
- if (a && typeof a == "object" && "error" in a && a.error)
57
- return d.value.push({
55
+ const n = await i.preprocess(F(e));
56
+ if (n && typeof n == "object" && "error" in n && n.error)
57
+ return f.value.push({
58
58
  code: "preprocess_failed",
59
- message: a.error.message || "Preprocess failed"
59
+ message: n.error.message || "Preprocess failed"
60
60
  }), null;
61
- D = a && typeof a == "object" && "data" in a ? a.data : a;
62
- } catch (a) {
63
- return d.value.push({
61
+ D = n && typeof n == "object" && "data" in n ? n.data : n;
62
+ } catch (n) {
63
+ return f.value.push({
64
64
  code: "preprocess_failed",
65
- message: (a == null ? void 0 : a.message) || String(a)
65
+ message: (n == null ? void 0 : n.message) || String(n)
66
66
  }), null;
67
67
  }
68
68
  else
69
69
  D = F(e);
70
70
  if (!i.transform)
71
- return d.value.push({
71
+ return f.value.push({
72
72
  code: "missing_transform",
73
73
  message: "No transform function provided. Either supply a transform or omit both preprocess and transform to use the default DCAT dataset path."
74
74
  }), null;
75
75
  let P;
76
76
  try {
77
- const a = i.preprocess ? D : F(e);
78
- P = await i.transform(a);
79
- } catch (a) {
80
- return d.value.push({
77
+ const n = i.preprocess ? D : F(e);
78
+ P = await i.transform(n);
79
+ } catch (n) {
80
+ return f.value.push({
81
81
  code: "transform_apply_failed",
82
- message: (a == null ? void 0 : a.message) || String(a)
82
+ message: (n == null ? void 0 : n.message) || String(n)
83
83
  }), null;
84
84
  }
85
85
  return {
@@ -89,34 +89,34 @@ function ve(e, i) {
89
89
  },
90
90
  null,
91
91
  { immediate: !1 }
92
- ), R = z(
93
- () => c.value && !g.value && !!b.value
92
+ ), v = z(
93
+ () => a.value && !b.value && !!g.value
94
94
  ), B = z(
95
- () => c.value && !!R.value
96
- ), T = z(() => B.value), I = z(() => {
97
- var u;
98
- return (u = p.value) == null ? void 0 : u.dpiData;
99
- }), S = z(() => {
100
- var u;
101
- return (u = p.value) == null ? void 0 : u.data;
95
+ () => a.value && !!v.value
96
+ ), I = z(() => B.value), S = z(() => {
97
+ var l;
98
+ return (l = m.value) == null ? void 0 : l.dpiData;
99
+ }), V = z(() => {
100
+ var l;
101
+ return (l = m.value) == null ? void 0 : l.data;
102
102
  });
103
103
  return K(
104
104
  () => F(e),
105
- (u) => u && c.value ? L() : null
106
- ), K(S, (u) => {
107
- console.log("jsonld resolved result:", u);
108
- }), K(m, (u) => {
109
- console.log("jsonld error:", u);
105
+ (l) => l && a.value ? T() : null
106
+ ), K(V, (l) => {
107
+ console.log("jsonld resolved result:", l);
108
+ }), K(L, (l) => {
109
+ console.log("jsonld error:", l);
110
110
  }), {
111
- processedInput: p,
112
- isProcessedInputReady: R,
113
- result: I,
111
+ processedInput: m,
112
+ isProcessedInputReady: v,
113
+ result: S,
114
114
  isMaterialized: B,
115
- isReady: T,
116
- errors: d
115
+ isReady: I,
116
+ errors: f
117
117
  };
118
118
  }
119
- function f(e) {
119
+ function p(e) {
120
120
  if (typeof e == "string")
121
121
  return e;
122
122
  if (e && typeof e == "object") {
@@ -127,7 +127,7 @@ function f(e) {
127
127
  }
128
128
  return "";
129
129
  }
130
- function l(e, i = "de") {
130
+ function d(e, i = "de") {
131
131
  if (!e)
132
132
  return "";
133
133
  if (typeof e == "string")
@@ -136,14 +136,14 @@ function l(e, i = "de") {
136
136
  return e[i] || Object.values(e)[0] || "";
137
137
  if (Array.isArray(e)) {
138
138
  const r = e.find(
139
- (c) => c["@language"] === i
139
+ (a) => a["@language"] === i
140
140
  );
141
141
  if (r)
142
142
  return r["@value"] || "";
143
143
  const t = e[0];
144
- return (t == null ? void 0 : t["@value"]) || f(t) || "";
144
+ return (t == null ? void 0 : t["@value"]) || p(t) || "";
145
145
  }
146
- return e["@language"] && e["@value"] ? e["@value"] : f(e);
146
+ return e["@language"] && e["@value"] ? e["@value"] : p(e);
147
147
  }
148
148
  function E(e) {
149
149
  return {
@@ -155,7 +155,7 @@ function x(e, i) {
155
155
  const r = e.prefLabel;
156
156
  return E({
157
157
  uri: e["@id"] || e["purl:identifier"] || "",
158
- "@value": r ? l(r) : e["purl:identifier"] || ""
158
+ "@value": r ? d(r) : e["purl:identifier"] || ""
159
159
  });
160
160
  }
161
161
  function N(e) {
@@ -177,7 +177,7 @@ function H(e, i = "de") {
177
177
  "@value": t["@value"],
178
178
  "@language": t["@language"]
179
179
  }) : U({
180
- "@value": f(t),
180
+ "@value": p(t),
181
181
  "@language": i
182
182
  }) : U({
183
183
  "@value": "",
@@ -188,14 +188,14 @@ function ce(e, i) {
188
188
  return e ? M(e).map(
189
189
  (t) => U({
190
190
  "@type": i,
191
- "@value": f(t)
191
+ "@value": p(t)
192
192
  })
193
193
  ) : [];
194
194
  }
195
195
  function X(e, i) {
196
196
  const r = { isValid: !0 };
197
- for (const [t, c] of Object.entries(i))
198
- r[t] = f(e == null ? void 0 : e[c]);
197
+ for (const [t, a] of Object.entries(i))
198
+ r[t] = p(e == null ? void 0 : e[a]);
199
199
  return r;
200
200
  }
201
201
  function de(e) {
@@ -203,32 +203,37 @@ function de(e) {
203
203
  happyFlowLandingPage: {}
204
204
  };
205
205
  }
206
- function le(e) {
207
- const i = {
206
+ function le(e, i) {
207
+ const r = {
208
208
  discoverabilityPage: [{ isValid: !0 }]
209
209
  };
210
210
  if (e["dcatap:hvdCategory"]) {
211
- const r = M(e["dcatap:hvdCategory"]).filter(Boolean);
212
- i.hvdPage = r == null ? void 0 : r.map((t) => ({
211
+ const t = M(e["dcatap:hvdCategory"]).filter(Boolean);
212
+ r.hvdPage = t == null ? void 0 : t.map((a) => ({
213
213
  isValid: !0,
214
- uri: t["@id"],
215
- label: l(t.prefLabel)
214
+ uri: a["@id"],
215
+ label: d(a.prefLabel)
216
216
  }));
217
217
  }
218
218
  if (e["dcat:theme"]) {
219
- const r = M(e["dcat:theme"]);
220
- i.discoverabilityPage = [
219
+ const t = M(e["dcat:theme"]);
220
+ r.discoverabilityPage = [
221
221
  { isValid: !0 },
222
- ...r.map(
223
- (t) => U({
224
- id: f(t).split("/").pop(),
225
- uri: f(t),
226
- label: l(t.prefLabel)
222
+ ...t.map(
223
+ (a) => U({
224
+ id: p(a).split("/").pop(),
225
+ uri: p(a),
226
+ label: d(a.prefLabel)
227
227
  })
228
228
  )
229
229
  ];
230
230
  }
231
- return i;
231
+ return i && (r.visibilityPage = [
232
+ {
233
+ isValid: !0,
234
+ visibility: i
235
+ }
236
+ ]), r;
232
237
  }
233
238
  function se(e) {
234
239
  var t;
@@ -246,9 +251,9 @@ function se(e) {
246
251
  e["dct:modified"],
247
252
  "http://www.w3.org/2001/XMLSchema#date"
248
253
  )), e["dct:publisher"]) {
249
- const c = o(e["dct:publisher"]);
254
+ const a = o(e["dct:publisher"]);
250
255
  r["dct:publisher"] = [
251
- X(c, {
256
+ X(a, {
252
257
  "foaf:name": "foaf:name",
253
258
  "foaf:mbox": "foaf:mbox",
254
259
  "foaf:homepage": "foaf:homepage"
@@ -256,9 +261,9 @@ function se(e) {
256
261
  ];
257
262
  }
258
263
  if (e["dcat:contactPoint"]) {
259
- const c = o(e["dcat:contactPoint"]);
264
+ const a = o(e["dcat:contactPoint"]);
260
265
  r["dcat:contactPoint"] = [
261
- X(c, {
266
+ X(a, {
262
267
  "vcard:fn": "vcard:fn",
263
268
  "vcard:hasEmail": "vcard:hasEmail",
264
269
  "vcard:hasTelephone": "vcard:hasTelephone"
@@ -271,8 +276,8 @@ function ue(e) {
271
276
  var i, r;
272
277
  return {
273
278
  "dcatde:politicalGeocodingURI": (i = e["dcatapde:politicalGeocodingURI"]) == null ? void 0 : i.map((t) => {
274
- var p;
275
- const h = {
279
+ var f;
280
+ const R = {
276
281
  districtKey: "Kreis",
277
282
  governmentDistrictKey: "Bezirk",
278
283
  municipalityKey: "Gemeindeschlüssel",
@@ -280,27 +285,27 @@ function ue(e) {
280
285
  stateKey: "Bundesland",
281
286
  regionalKey: "Regionalschlüssel"
282
287
  };
283
- let d = t["@id"].split("/").slice(-2, -1)[0];
284
- return d = h[d] || d, {
288
+ let u = t["@id"].split("/").slice(-2, -1)[0];
289
+ return u = R[u] || u, {
285
290
  isValid: !0,
286
291
  uri: t["@id"],
287
- id: ((p = t.prefLabel) == null ? void 0 : p.de) || t["@id"].split("/").pop(),
288
- label: l(t.altLabel),
289
- inVoc: d
292
+ id: ((f = t.prefLabel) == null ? void 0 : f.de) || t["@id"].split("/").pop(),
293
+ label: d(t.altLabel),
294
+ inVoc: u
290
295
  };
291
296
  }),
292
- "dcat:temporalResolution": (r = e["dct:temporal"]) == null ? void 0 : r.reduce((t, c) => {
293
- const d = o(c["dcat:startDate"]), p = o(c["dcat:endDate"]), b = f(d) || "", g = f(p) || "", m = typeof d != "string" && (d == null ? void 0 : d["@type"]) === "http://www.w3.org/2001/XMLSchema#dateTime" ? "dateTime" : "date", L = m === "date" ? b : b.split("T")[0], R = m === "date" ? g : g.split("T")[0], B = m === "dateTime" ? b.split("T")[1] : "", T = m === "dateTime" ? g.split("T")[1] : "";
297
+ "dcat:temporalResolution": (r = e["dct:temporal"]) == null ? void 0 : r.reduce((t, a) => {
298
+ const u = o(a["dcat:startDate"]), f = o(a["dcat:endDate"]), m = p(u) || "", g = p(f) || "", b = typeof u != "string" && (u == null ? void 0 : u["@type"]) === "http://www.w3.org/2001/XMLSchema#dateTime" ? "dateTime" : "date", L = b === "date" ? m : m.split("T")[0], T = b === "date" ? g : g.split("T")[0], v = b === "dateTime" ? m.split("T")[1] : "", B = b === "dateTime" ? g.split("T")[1] : "";
294
299
  return {
295
300
  isValid: !0,
296
301
  type: "dct:PeriodOfTime",
297
302
  "dct:temporal": [
298
303
  {
299
- dataType: m,
304
+ dataType: b,
300
305
  "dcat:startDate": L,
301
- "dcat:endDate": R,
302
- startTime: B || "",
303
- endTime: T || ""
306
+ "dcat:endDate": T,
307
+ startTime: v || "",
308
+ endTime: B || ""
304
309
  }
305
310
  ]
306
311
  };
@@ -308,77 +313,77 @@ function ue(e) {
308
313
  };
309
314
  }
310
315
  function fe(e, i) {
311
- var t, c, h, d, p, b, g, m, L, R, B, T, I, S, u, D, P, A, a, y, V;
316
+ var t, a, R, u, f, m, g, b, L, T, v, B, I, S, V, l, D, P, A, n, y;
312
317
  if (!e)
313
318
  return {};
314
319
  const r = o(e["spdx:checksum"]);
315
320
  return {
316
321
  isValid: !0,
317
322
  id: i + 1,
318
- "dcat:accessURL": f(o(e["dcat:accessURL"])) || "",
323
+ "dcat:accessURL": p(o(e["dcat:accessURL"])) || "",
319
324
  "dct:format": {
320
325
  // redundancy in label and title for better compatibility
321
326
  label: ((t = o(e["dct:format"])) == null ? void 0 : t["purl:identifier"]) || "",
322
- title: ((c = o(e["dct:format"])) == null ? void 0 : c["purl:identifier"]) || "",
323
- uri: ((h = o(e["dct:format"])) == null ? void 0 : h["@id"]) || ""
327
+ title: ((a = o(e["dct:format"])) == null ? void 0 : a["purl:identifier"]) || "",
328
+ uri: ((R = o(e["dct:format"])) == null ? void 0 : R["@id"]) || ""
324
329
  },
325
- "dct:title": l(e["dct:title"]),
326
- "dct:description": l(e["dct:description"]),
327
- "dct:modified": f(o(e["dct:modified"])),
328
- "dct:issued": f(o(e["dct:issued"])),
329
- "dcat:byteSize": f(o(e["dcat:byteSize"])),
330
- "dcatde:licenseAttributionByText": l(e["dcatapde:licenseAttributionByText"]) || "",
330
+ "dct:title": d(e["dct:title"]),
331
+ "dct:description": d(e["dct:description"]),
332
+ "dct:modified": p(o(e["dct:modified"])),
333
+ "dct:issued": p(o(e["dct:issued"])),
334
+ "dcat:byteSize": p(o(e["dcat:byteSize"])),
335
+ "dcatde:licenseAttributionByText": d(e["dcatapde:licenseAttributionByText"]) || "",
331
336
  "dct:license": e["dct:license"] ? [{
332
337
  isValid: !0,
333
- uri: ((d = o(e["dct:license"])) == null ? void 0 : d["@id"]) || "",
334
- "dcterms:license": l((p = o(e["dct:license"])) == null ? void 0 : p.altLabel) || "",
335
- label: l((b = o(e["dct:license"])) == null ? void 0 : b.prefLabel) || "",
336
- title: l((g = o(e["dct:license"])) == null ? void 0 : g.prefLabel) || ""
338
+ uri: ((u = o(e["dct:license"])) == null ? void 0 : u["@id"]) || "",
339
+ "dcterms:license": d((f = o(e["dct:license"])) == null ? void 0 : f.altLabel) || "",
340
+ label: d((m = o(e["dct:license"])) == null ? void 0 : m.prefLabel) || "",
341
+ title: d((g = o(e["dct:license"])) == null ? void 0 : g.prefLabel) || ""
337
342
  }] : [],
338
- "dct:accessRights": f(o(e["dct:accessRights"])),
343
+ "dct:accessRights": p(o(e["dct:accessRights"])),
339
344
  "dcatap:availability": {
340
345
  // Redundant label and title for better compatibility
341
- label: ((m = o(e["dcatap:availability"])) == null ? void 0 : m.prefLabel) || "",
346
+ label: ((b = o(e["dcatap:availability"])) == null ? void 0 : b.prefLabel) || "",
342
347
  title: ((L = o(e["dcatap:availability"])) == null ? void 0 : L.prefLabel) || "",
343
- uri: ((R = o(e["dcatap:availability"])) == null ? void 0 : R["@id"]) || ""
348
+ uri: ((T = o(e["dcatap:availability"])) == null ? void 0 : T["@id"]) || ""
344
349
  },
345
- "dct:language": ((B = e["dct:language"]) == null ? void 0 : B.map((v) => x(v)).filter(Boolean)) || [],
350
+ "dct:language": ((v = e["dct:language"]) == null ? void 0 : v.map((h) => x(h)).filter(Boolean)) || [],
346
351
  "dcat:mediaType": E({
347
- label: l(
348
- (T = o(e["dcat:mediaType"])) == null ? void 0 : T.prefLabel
352
+ label: d(
353
+ (B = o(e["dcat:mediaType"])) == null ? void 0 : B.prefLabel
349
354
  ) || "",
350
355
  uri: ((I = o(e["dcat:mediaType"])) == null ? void 0 : I["@id"]) || ""
351
356
  }),
352
357
  "dcat:compressFormat": E({
353
- label: l(
358
+ label: d(
354
359
  (S = o(e["dcat:compressFormat"])) == null ? void 0 : S.prefLabel
355
360
  ) || "",
356
- uri: ((u = o(e["dcat:compressFormat"])) == null ? void 0 : u["@id"]) || ""
361
+ uri: ((V = o(e["dcat:compressFormat"])) == null ? void 0 : V["@id"]) || ""
357
362
  }),
358
363
  "dcat:packageFormat": E({
359
- label: l(
360
- (D = o(e["dcat:packageFormat"])) == null ? void 0 : D.prefLabel
364
+ label: d(
365
+ (l = o(e["dcat:packageFormat"])) == null ? void 0 : l.prefLabel
361
366
  ) || "",
362
- uri: ((P = o(e["dcat:packageFormat"])) == null ? void 0 : P["@id"]) || ""
367
+ uri: ((D = o(e["dcat:packageFormat"])) == null ? void 0 : D["@id"]) || ""
363
368
  }),
364
- "adms:status": ((A = o(e["adms:status"])) == null ? void 0 : A["@id"]) || "",
369
+ "adms:status": ((P = o(e["adms:status"])) == null ? void 0 : P["@id"]) || "",
365
370
  checksum: {
366
- title: f(o(r == null ? void 0 : r["spdx:checksumValue"])),
367
- "spdx:checksum": ((a = f(o(r == null ? void 0 : r["spdx:algorithm"]))) == null ? void 0 : a.split("_").pop()) || "",
368
- uri: (y = f(
371
+ title: p(o(r == null ? void 0 : r["spdx:checksumValue"])),
372
+ "spdx:checksum": ((A = p(o(r == null ? void 0 : r["spdx:algorithm"]))) == null ? void 0 : A.split("_").pop()) || "",
373
+ uri: (n = p(
369
374
  o(r == null ? void 0 : r["spdx:algorithm"])
370
- )) == null ? void 0 : y.replace("spdx:", "http://spdx.org/rdf/terms#")
375
+ )) == null ? void 0 : n.replace("spdx:", "http://spdx.org/rdf/terms#")
371
376
  },
372
377
  accessServices: ye(e["dcat:accessService"] || []),
373
- conformsToItems: (V = e["dct:conformsTo"]) == null ? void 0 : V.map((v, j) => ({
378
+ conformsToItems: (y = e["dct:conformsTo"]) == null ? void 0 : y.map((h, j) => ({
374
379
  // for some reason dct:conformsTo is different from the one on dcat:dataset level
375
380
  id: j + 1,
376
- "dcat:accessURL": v["@id"],
377
- "dct:title": l(v["rdfs:label"]) || "",
378
- "dcat:downloadURL": v["@id"],
381
+ "dcat:accessURL": h["@id"],
382
+ "dct:title": d(h["rdfs:label"]) || "",
383
+ "dcat:downloadURL": h["@id"],
379
384
  // redundancy to match properties on dcat:dataset level
380
- "rdfs:label": l(v["rdfs:label"]) || "",
381
- uri: v["@id"]
385
+ "rdfs:label": d(h["rdfs:label"]) || "",
386
+ uri: h["@id"]
382
387
  })).filter(Boolean)
383
388
  };
384
389
  }
@@ -388,7 +393,7 @@ function pe(e) {
388
393
  };
389
394
  if (e["dcat:distribution"]) {
390
395
  const r = M(e["dcat:distribution"]);
391
- i["dcat:distribution"] = r.map((t, c) => fe(t, c)).filter((t) => Object.keys(t).length > 0);
396
+ i["dcat:distribution"] = r.map((t, a) => fe(t, a)).filter((t) => Object.keys(t).length > 0);
392
397
  }
393
398
  return console.log(i), i;
394
399
  }
@@ -398,96 +403,96 @@ function me(e) {
398
403
  };
399
404
  }
400
405
  function be(e) {
401
- var r, t, c, h, d, p, b, g, m, L, R, B, T, I, S, u, D, P, A, a, y, V, v, j, C, G, q;
406
+ var r, t, a, R, u, f, m, g, b, L, T, v, B, I, S, V, l, D, P, A, n, y, h, j, C, G, q;
402
407
  const i = {
403
- "dct:language": (r = e["dct:language"]) == null ? void 0 : r.map((n) => x(n)).filter(Boolean),
404
- "dct:conformsTo": (t = e["dct:conformsTo"]) == null ? void 0 : t.map((n) => ({
405
- "rdfs:label": l(n["rdfs:label"]) || "",
406
- "@id": n["@id"]
408
+ "dct:language": (r = e["dct:language"]) == null ? void 0 : r.map((c) => x(c)).filter(Boolean),
409
+ "dct:conformsTo": (t = e["dct:conformsTo"]) == null ? void 0 : t.map((c) => ({
410
+ "rdfs:label": d(c["rdfs:label"]) || "",
411
+ "@id": c["@id"]
407
412
  })).filter(Boolean),
408
413
  "dct:accessRights": e["dct:accessRights"] ? s(x(e["dct:accessRights"])) : [],
409
- "dct:provenance": (c = e["dct:provenance"]) == null ? void 0 : c.map((n) => ({
410
- "rdfs:label": l(n["rdfs:label"]) || "",
411
- uri: n["@id"]
414
+ "dct:provenance": (a = e["dct:provenance"]) == null ? void 0 : a.map((c) => ({
415
+ "rdfs:label": d(c["rdfs:label"]) || "",
416
+ uri: c["@id"]
412
417
  })).filter(Boolean),
413
418
  "dct:accrualPeriodicity": e["dct:accrualPeriodicity"] ? s(x(e["dct:accrualPeriodicity"])) : [],
414
- "dct:type": (h = e["dct:type"]) == null ? void 0 : h.map((n) => x(n)).filter(Boolean),
415
- "dcat:spatialResolutionInMeters": ((d = e["dcat:spatialResolutionInMeters"]) == null ? void 0 : d.map(N)) || void 0,
416
- "dcat:temporalResolution": e["dcat:temporalResolution"] ? e["dcat:temporalResolution"].map(N).map((n) => {
417
- const _ = n["@value"].match(/^P(?:(\d+)Y)?(?:(\d+)M)?(?:(\d+)D)?(?:T(?:(\d+)H)?(?:(\d+)M)?(?:(\d+)S)?)?$/);
419
+ "dct:type": (R = e["dct:type"]) == null ? void 0 : R.map((c) => x(c)).filter(Boolean),
420
+ "dcat:spatialResolutionInMeters": ((u = e["dcat:spatialResolutionInMeters"]) == null ? void 0 : u.map(N)) || void 0,
421
+ "dcat:temporalResolution": e["dcat:temporalResolution"] ? e["dcat:temporalResolution"].map(N).map((c) => {
422
+ const _ = c["@value"].match(/^P(?:(\d+)Y)?(?:(\d+)M)?(?:(\d+)D)?(?:T(?:(\d+)H)?(?:(\d+)M)?(?:(\d+)S)?)?$/);
418
423
  if (_) {
419
424
  const [, O, k, Y, $, J, Q] = _.map((W) => W || "0");
420
425
  return { Year: O, Month: k, Day: Y, Hour: $, Minute: J, Second: Q };
421
426
  }
422
427
  }).filter(Boolean) : void 0,
423
- "dcat:qualifiedRelation": (p = s(
428
+ "dcat:qualifiedRelation": (f = s(
424
429
  e["dcat:qualifiedRelation"]
425
- )) == null ? void 0 : p.filter(Boolean),
426
- "dct:creator": (b = s(e["dct:creator"])) == null ? void 0 : b.filter(Boolean),
430
+ )) == null ? void 0 : f.filter(Boolean),
431
+ "dct:creator": (m = s(e["dct:creator"])) == null ? void 0 : m.filter(Boolean),
427
432
  "dct:contributor": (g = s(e["dct:contributor"])) == null ? void 0 : g.filter(Boolean),
428
- "dcatde:contributorID": (m = e["dcatapde:contributorID"]) == null ? void 0 : m.map((n) => x(n)).filter(Boolean),
433
+ "dcatde:contributorID": (b = e["dcatapde:contributorID"]) == null ? void 0 : b.map((c) => x(c)).filter(Boolean),
429
434
  "dcatde:geocodingDescription": (L = s(
430
435
  e["dcatapde:geocodingDescription"]
431
436
  )) == null ? void 0 : L.filter(Boolean),
432
- "dct:identifier": (R = e["dct:identifier"]) == null ? void 0 : R.map((n) => ({
433
- "@value": n
437
+ "dct:identifier": (T = e["dct:identifier"]) == null ? void 0 : T.map((c) => ({
438
+ "@value": c
434
439
  })),
435
- "adms:identifier": (B = s(e["adms:identifier"])) == null ? void 0 : B.filter(Boolean),
436
- "owl:versionInfo": (T = e["owl:versionInfo"]) == null ? void 0 : T.map((n) => ({
437
- "@value": n
440
+ "adms:identifier": (v = s(e["adms:identifier"])) == null ? void 0 : v.filter(Boolean),
441
+ "owl:versionInfo": (B = e["owl:versionInfo"]) == null ? void 0 : B.map((c) => ({
442
+ "@value": c
438
443
  })),
439
444
  "adms:versionNotes": e["adms:versionNotes"],
440
445
  "dcatde:legalBasis": (I = s(e["dcatapde:legalBasis"])) == null ? void 0 : I.filter(
441
446
  Boolean
442
447
  ),
443
448
  "dct:relation": (S = s(e["dct:relation"])) == null ? void 0 : S.filter(Boolean),
444
- "dcat:landingPage": (u = s(e["dcat:landingPage"])) == null ? void 0 : u.filter(
449
+ "dcat:landingPage": (V = s(e["dcat:landingPage"])) == null ? void 0 : V.filter(
445
450
  Boolean
446
451
  ),
447
- "prov:wasGeneratedBy": (D = s(e["prov:wasGeneratedBy"])) == null ? void 0 : D.filter(
452
+ "prov:wasGeneratedBy": (l = s(e["prov:wasGeneratedBy"])) == null ? void 0 : l.filter(
448
453
  Boolean
449
454
  ),
450
- "dct:isReferencedBy": (P = s(e["dct:isReferencedBy"])) == null ? void 0 : P.filter(
455
+ "dct:isReferencedBy": (D = s(e["dct:isReferencedBy"])) == null ? void 0 : D.filter(
451
456
  Boolean
452
457
  ),
453
- "dct:source": (A = s(e["dct:source"])) == null ? void 0 : A.filter(Boolean),
454
- "dct:hasVersion": (a = s(e["dct:hasVersion"])) == null ? void 0 : a.filter(Boolean),
455
- "dct:isVersionOf": (y = s(e["dct:isVersionOf"])) == null ? void 0 : y.filter(Boolean),
456
- "prov:qualifiedAttribution": (V = s(
458
+ "dct:source": (P = s(e["dct:source"])) == null ? void 0 : P.filter(Boolean),
459
+ "dct:hasVersion": (A = s(e["dct:hasVersion"])) == null ? void 0 : A.filter(Boolean),
460
+ "dct:isVersionOf": (n = s(e["dct:isVersionOf"])) == null ? void 0 : n.filter(Boolean),
461
+ "prov:qualifiedAttribution": (y = s(
457
462
  e["prov:qualifiedAttribution"]
458
- )) == null ? void 0 : V.filter(Boolean),
459
- "dcat:keyword": (v = s(e["dcat:keyword"])) == null ? void 0 : v.filter(Boolean),
463
+ )) == null ? void 0 : y.filter(Boolean),
464
+ "dcat:keyword": (h = s(e["dcat:keyword"])) == null ? void 0 : h.filter(Boolean),
460
465
  "dct:spatial": (j = s(e["dct:spatial"])) == null ? void 0 : j.filter(Boolean),
461
466
  "dct:references": (C = s(e["dct:references"])) == null ? void 0 : C.filter(Boolean),
462
- "foaf:page": (G = s(e["foaf:page"])) == null ? void 0 : G.filter(Boolean).map((n) => {
463
- if (!n)
467
+ "foaf:page": (G = s(e["foaf:page"])) == null ? void 0 : G.filter(Boolean).map((c) => {
468
+ if (!c)
464
469
  return;
465
- const w = o(n["dct:format"]);
470
+ const w = o(c["dct:format"]);
466
471
  return {
467
- "dct:title": o(n["dct:title"]),
468
- "dct:description": o(n["dct:description"]),
469
- "@value": w ? l(w.prefLabel) : "",
472
+ "dct:title": o(c["dct:title"]),
473
+ "dct:description": o(c["dct:description"]),
474
+ "@value": w ? d(w.prefLabel) : "",
470
475
  uri: w ? w["@id"] : "",
471
- "foaf:homepage": o(n["foaf:homepage"]) || ""
476
+ "foaf:homepage": o(c["foaf:homepage"]) || ""
472
477
  };
473
478
  }),
474
- "dcatap:availability": (q = e["dcatap:availability"]) == null ? void 0 : q.map((n) => {
479
+ "dcatap:availability": (q = e["dcatap:availability"]) == null ? void 0 : q.map((c) => {
475
480
  var w, _, O, k;
476
481
  return {
477
482
  // Redundant label and title for better compatibility
478
- label: ((w = o(n)) == null ? void 0 : w.prefLabel) || "",
479
- title: ((_ = o(n)) == null ? void 0 : _.prefLabel) || "",
480
- uri: ((O = o(n)) == null ? void 0 : O["@id"]) || "",
481
- "@value": l((k = o(n)) == null ? void 0 : k.prefLabel) || ""
483
+ label: ((w = o(c)) == null ? void 0 : w.prefLabel) || "",
484
+ title: ((_ = o(c)) == null ? void 0 : _.prefLabel) || "",
485
+ uri: ((O = o(c)) == null ? void 0 : O["@id"]) || "",
486
+ "@value": d((k = o(c)) == null ? void 0 : k.prefLabel) || ""
482
487
  };
483
488
  })
484
489
  };
485
490
  return ne(i);
486
491
  }
487
- function ge(e) {
492
+ function ge(e, i) {
488
493
  return {
489
494
  Landing: de(),
490
- Discoverability: le(e),
495
+ Discoverability: le(e, i),
491
496
  BasicInfos: se(e),
492
497
  Covering: ue(e),
493
498
  DistributionSimple: pe(e),
@@ -497,24 +502,24 @@ function ge(e) {
497
502
  }
498
503
  function ye(e) {
499
504
  return !e || !Array.isArray(e) || e.length === 0 ? [] : e.map((i, r) => {
500
- var t, c;
505
+ var t, a;
501
506
  return {
502
507
  id: r + 1,
503
508
  "dcat:downloadURL": ((t = o(i["dcat:endpointURL"])) == null ? void 0 : t["@id"]) || "",
504
- "dcat:endpointURL": ((c = o(i["dcat:endpointURL"])) == null ? void 0 : c["@id"]) || "",
505
- "dct:description": l(i["dct:description"]) || "",
506
- "dct:title": l(i["dct:title"]) || ""
509
+ "dcat:endpointURL": ((a = o(i["dcat:endpointURL"])) == null ? void 0 : a["@id"]) || "",
510
+ "dct:description": d(i["dct:description"]) || "",
511
+ "dct:title": d(i["dct:title"]) || ""
507
512
  };
508
513
  });
509
514
  }
510
515
  export {
511
516
  s as asSomeArray,
512
- l as extractLocalizedString,
513
- f as extractStringValue,
517
+ d as extractLocalizedString,
518
+ p as extractStringValue,
514
519
  o as getFirstItem,
515
520
  M as normalizeToArray,
516
521
  ne as purgeNullishAndEmptyProperties,
517
522
  ye as toAccessService,
518
523
  ge as toDpi,
519
- ve as useDpiSimpleLoader
524
+ De as useDpiSimpleLoader
520
525
  };