@piveau/dpi 0.2.0-alpha.6 → 0.2.0-alpha.8

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 +20 -17
  3. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/DPIHome.vue.js +4 -4
  4. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ProjectTable.vue.js +45 -44
  5. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ActionCard.vue.js +1 -1
  6. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ActionCard.vue2.js +24 -22
  7. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/BasicInfosStep/ProjectDescriptionStep.vue.js +2 -2
  8. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/BasicInfosStep/ProjectStatusStep.vue.js +18 -21
  9. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Chip.vue.js +49 -41
  10. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ChipToggleList/ChipToggleList.vue.js +2 -2
  11. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ChipToggleList/ChipToggleList.vue2.js +30 -24
  12. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DataCollection/BasicInformationStep.vue.js +2 -2
  13. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DataCollection/BasicInformationStep.vue2.js +105 -133
  14. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DataProcessing/BasicInformationStep.vue.js +7 -0
  15. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DataProcessing/BasicInformationStep.vue2.js +180 -0
  16. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DpiModalBase.vue.js +3 -3
  17. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Findability/ApplicationsStep.vue.js +1 -1
  18. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Findability/ApplicationsStep.vue2.js +63 -61
  19. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Findability/DiscoverabilityStep.vue.js +48 -39
  20. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/InputField/InputFieldFormKit.vue.js +40 -36
  21. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/InputField.vue.js +1 -1
  22. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ListBox/ListBoxDefinition.js +8 -3
  23. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ListBox/ListBoxFormKit.vue.js +65 -37
  24. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ListBox/Listbox.vue.js +2 -2
  25. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ListBox/Listbox.vue2.js +21 -22
  26. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/OptionalDataStep/OptionalDataStep.vue.js +2 -2
  27. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/OptionalDataStep/OptionalDataStep.vue2.js +96 -93
  28. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/DatasetStep.vue.js +3 -3
  29. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/DatasetStep.vue2.js +59 -56
  30. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/GetResource.vue.js +38 -0
  31. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/GetResource.vue2.js +4 -0
  32. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/ProcessStepsOverviewStep.vue.js +12 -12
  33. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/SoftwareStep.vue.js +1 -1
  34. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/SoftwareStep.vue2.js +32 -34
  35. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Projektphasen/InitiierenStep.vue.js +38 -33
  36. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Projektphasen/PlanenStep.vue.js +38 -32
  37. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Projektphasen/ProjektPhasenOverviewStep.vue.js +7 -7
  38. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Projektphasen/UmstezenStep.vue.js +36 -31
  39. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Projektphasen/WeiterdenkenStep.vue.js +35 -30
  40. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ReviewStep/ReviewStep.vue.js +7 -0
  41. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ReviewStep/ReviewStep.vue2.js +1055 -0
  42. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/StateTag.vue.js +17 -13
  43. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/SummaryBox.vue.js +1 -1
  44. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/SummaryBox.vue2.js +14 -10
  45. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/TableRowV3.vue.js +84 -73
  46. package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/TextAreaV3.vue.js +2 -2
  47. package/dist/packages/dpi/src/data-provider-interface/components/StepActionsSection.vue.js +2 -2
  48. package/dist/packages/dpi/src/data-provider-interface/components/StepActionsSection.vue2.js +70 -65
  49. package/dist/packages/dpi/src/data-provider-interface/components/TheCancelConfirmationDialog.vue.js +7 -0
  50. package/dist/packages/dpi/src/data-provider-interface/components/TheCancelConfirmationDialog.vue2.js +42 -0
  51. package/dist/packages/dpi/src/data-provider-interface/components/dev-tools/ProjectDpiDevTools.vue.js +7 -0
  52. package/dist/packages/dpi/src/data-provider-interface/components/dev-tools/ProjectDpiDevTools.vue2.js +249 -0
  53. package/dist/packages/dpi/src/data-provider-interface/components/dev-tools/fixtures.js +287 -0
  54. package/dist/packages/dpi/src/data-provider-interface/composables/project-transformer/__tests__/fixtures/theProjectForm.js +281 -0
  55. package/dist/packages/dpi/src/data-provider-interface/composables/project-transformer/decodeProject.js +244 -0
  56. package/dist/packages/dpi/src/data-provider-interface/composables/project-transformer/encodeProject.js +330 -0
  57. package/dist/packages/dpi/src/data-provider-interface/composables/project-transformer/shared.js +37 -0
  58. package/dist/packages/dpi/src/data-provider-interface/schema/projectLdSchema.js +114 -0
  59. package/dist/packages/dpi/src/data-provider-interface/views/InputPageProject.vue.js +406 -371
  60. package/dist/packages/dpi/src/stories/components/LinkCard.vue.js +3 -3
  61. package/dist/packages/dpi/src/stories/components/LinkCard.vue2.js +12 -11
  62. package/dist/packages/dpi/src/stories/components/PartnerCard.vue.js +2 -2
  63. package/dist/packages/dpi/src/stories/components/PartnerCard.vue2.js +21 -16
  64. package/dist/packages/dpi/src/stories/components/ScreenshotCard.vue.js +2 -2
  65. package/dist/packages/dpi/src/stories/components/ScreenshotCard.vue2.js +8 -6
  66. package/package.json +5 -2
  67. package/dist/packages/dpi/src/stories/components/MethodsCard.vue.js +0 -7
  68. package/dist/packages/dpi/src/stories/components/MethodsCard.vue2.js +0 -45
@@ -0,0 +1,330 @@
1
+ import { pipe as s } from "effect";
2
+ import * as n from "effect/Option";
3
+ import { theProjectForm as C } from "./__tests__/fixtures/theProjectForm.js";
4
+ import { PREFIXES as F } from "./shared.js";
5
+ function Q(e, i) {
6
+ if (e)
7
+ return {
8
+ "@value": e,
9
+ "@type": i
10
+ };
11
+ }
12
+ function $(e) {
13
+ return (e ?? []).map((t) => {
14
+ var r, o;
15
+ return { name: (r = t.name) == null ? void 0 : r.trim(), url: (o = t.url) == null ? void 0 : o.trim() };
16
+ }).filter((t) => !!t.name && t.name.length > 0).map((t) => ({
17
+ "foaf:name": t.name,
18
+ ...t.url && t.url.length > 0 ? { "foaf:homepage": t.url } : {}
19
+ }));
20
+ }
21
+ function H(e, i) {
22
+ return e ? [{ "@value": e, "@language": i }] : void 0;
23
+ }
24
+ function X(e) {
25
+ return (i) => H(i, e);
26
+ }
27
+ function A(e) {
28
+ if (e)
29
+ return {
30
+ "@id": e
31
+ };
32
+ }
33
+ function U(e) {
34
+ return e != null;
35
+ }
36
+ function Z(e, i = "http://www.w3.org/2001/XMLSchema#string") {
37
+ return s(
38
+ n.fromNullable(e),
39
+ n.map((t) => t.trim()),
40
+ n.filter((t) => t.length > 0),
41
+ n.flatMap((t) => n.fromNullable(Q(t, i)))
42
+ );
43
+ }
44
+ const B = (e) => (e ?? "").trim(), q = (e) => e.length > 0;
45
+ function m(e) {
46
+ return s(
47
+ n.fromNullable(e ?? void 0),
48
+ n.map(B),
49
+ n.filter(q)
50
+ );
51
+ }
52
+ function J(e) {
53
+ return s(
54
+ n.fromNullable(e),
55
+ n.map((i) => i.map(B).filter(q)),
56
+ n.filter((i) => i.length > 0),
57
+ n.map((i) => [...i])
58
+ );
59
+ }
60
+ function G(e) {
61
+ return s(
62
+ n.fromNullable(e),
63
+ n.map((i) => i.map((t) => A(t)).filter(U)),
64
+ n.filter((i) => i.length > 0),
65
+ n.map((i) => [...i])
66
+ );
67
+ }
68
+ function R(e, i) {
69
+ return s(
70
+ m(e),
71
+ n.flatMap((t) => n.fromNullable(i(t)))
72
+ );
73
+ }
74
+ function Y(e) {
75
+ return L(e).flatMap((i) => [...i]);
76
+ }
77
+ function V(e, i, t) {
78
+ return s(
79
+ n.fromNullable(e),
80
+ n.map((r) => r.map(i).filter(U)),
81
+ n.filter((r) => r.length > 0),
82
+ n.map((r) => M(r, t)),
83
+ n.filter((r) => r.length > 0),
84
+ n.map((r) => [...r])
85
+ );
86
+ }
87
+ function I(e) {
88
+ if (e == null || typeof e != "object")
89
+ return e;
90
+ if (Array.isArray(e))
91
+ return e.map((r) => I(r)).filter((r) => r != null);
92
+ const i = {};
93
+ for (const [t, r] of Object.entries(e)) {
94
+ if (r == null)
95
+ continue;
96
+ const o = I(r);
97
+ o != null && (i[t] = o);
98
+ }
99
+ return i;
100
+ }
101
+ function L(e) {
102
+ return e.map(n.getOrUndefined).filter(U);
103
+ }
104
+ function c(e) {
105
+ const i = e ? [...e] : [];
106
+ return i.length > 0 ? i : void 0;
107
+ }
108
+ function ee(e, i) {
109
+ const t = e ?? {}, r = [];
110
+ for (const [o, a] of Object.entries(i)) {
111
+ const f = s(
112
+ n.fromNullable(t[o]),
113
+ n.map((u) => u.trim()),
114
+ n.filter((u) => u.length > 0),
115
+ n.map((u) => ({
116
+ "@type": "schema:Question",
117
+ "schema:text": a,
118
+ "schema:acceptedAnswer": u
119
+ })),
120
+ n.getOrUndefined
121
+ );
122
+ f && r.push(f);
123
+ }
124
+ return r;
125
+ }
126
+ function D(e, i, t) {
127
+ const r = ee(e, t);
128
+ return r.length === 0 ? n.none() : n.some({
129
+ "@type": "schema:QAPage",
130
+ "dct:type": i,
131
+ "schema:question": r
132
+ });
133
+ }
134
+ function ne(e) {
135
+ return (e ?? []).map((t) => {
136
+ var r, o;
137
+ return { name: (r = t.name) == null ? void 0 : r.trim(), description: (o = t.description) == null ? void 0 : o.trim() };
138
+ }).filter((t) => !!t.name && t.name.length > 0 && !!t.description && t.description.length > 0).map((t) => ({
139
+ "@type": "prov:used",
140
+ "dct:title": t.name,
141
+ "dct:description": t.description
142
+ }));
143
+ }
144
+ function M(e, i) {
145
+ return (e ?? []).map((r) => ({
146
+ "@type": "rdfs:Resource",
147
+ "dct:type": i,
148
+ "schema:url": r.url,
149
+ "dct:title": r.name,
150
+ "dct:description": s(
151
+ n.fromNullable(r.description),
152
+ n.map((o) => o.trim()),
153
+ n.filter((o) => o.length > 0),
154
+ n.getOrUndefined
155
+ )
156
+ }));
157
+ }
158
+ function te(e) {
159
+ return (e ?? []).map((t) => ({
160
+ "@type": "pv:SoftwareLink",
161
+ "dct:identifier": t.id,
162
+ "schema:featureList": c((t.functionalities ?? []).map((r) => r == null ? void 0 : r.trim()).filter((r) => !!r && r.length > 0))
163
+ }));
164
+ }
165
+ function re(e) {
166
+ return (e ?? []).map((t) => ({
167
+ "@type": "dcat:Dataset",
168
+ "dct:identifier": t.id
169
+ }));
170
+ }
171
+ function ie(e, i) {
172
+ return (e ?? []).map((r) => {
173
+ var o;
174
+ return {
175
+ "@type": "ssn:Deployment",
176
+ "dct:identifier": "__TODO__",
177
+ "dct:description": s(
178
+ n.fromNullable(r.description),
179
+ n.map((a) => a.trim()),
180
+ n.filter((a) => a.length > 0),
181
+ n.flatMap((a) => n.fromNullable(i(a))),
182
+ n.getOrUndefined
183
+ ),
184
+ "ssn:deployedSystem": A(r.id),
185
+ "ssn:forProperty": c((r.forProperty ?? []).map((a) => a == null ? void 0 : a.trim()).filter((a) => !!a && a.length > 0)),
186
+ "sosa:hasLocation": c((r.locations ?? []).map((a) => ({
187
+ "@type": "dct:Location",
188
+ "geo:lat": a.lat,
189
+ "geo:long": a.lng
190
+ }))),
191
+ "foaf:depiction": c((r.depictions ?? []).map((a) => A(a)).filter(U)),
192
+ // Corresponds to functionalities of hardware;
193
+ // not to be confused with functionalities of software (schema:featureList)
194
+ "ssn-system:hasSystemCapability": c((r.functionalities ?? []).map((a) => a == null ? void 0 : a.trim()).filter((a) => !!a && a.length > 0)),
195
+ "dct:references": c(M((o = r.references) == null ? void 0 : o.map((a) => ({
196
+ name: a.name ?? "",
197
+ url: a.url ?? "",
198
+ description: a.description
199
+ })).filter((a) => a.url.length > 0 && ((a == null ? void 0 : a.name) || "").length > 0), "documentation"))
200
+ };
201
+ });
202
+ }
203
+ function P(e) {
204
+ var h, b, y;
205
+ const { prefixKey: i, activityLabel: t, input: r, toLanged: o } = e, a = `${i}/Grundlegende Informationen`, f = `${i}/Software`, u = `${i}/Datensätze`, j = `${i}/Hardware`, d = r[a], N = d == null ? void 0 : d.description, x = s(
206
+ n.fromNullable(N),
207
+ n.map((g) => g.trim()),
208
+ n.filter((g) => g.length > 0),
209
+ n.getOrUndefined
210
+ ), W = d == null ? void 0 : d.methods, z = d == null ? void 0 : d.links, v = (h = r[f]) == null ? void 0 : h.selected, w = (b = r[u]) == null ? void 0 : b.selected, S = (y = r[j]) == null ? void 0 : y.selected, p = [
211
+ ...te(v),
212
+ ...re(w),
213
+ ...ie(S, o)
214
+ ], k = {
215
+ "@type": "p-plan:Step",
216
+ "dct:identifier": "__TODO__",
217
+ "p-plan:Activity": t,
218
+ "dct:description": o(x ?? ""),
219
+ "prov:used": c(ne(W)),
220
+ "dct:references": c(M(z, "documentation")),
221
+ "p-plan:hasInputVar": p.length > 0 ? p : void 0
222
+ };
223
+ return n.some(k);
224
+ }
225
+ function ae(e, i) {
226
+ var v, w, S, p, k, h, b, y, g, K, T, _, E;
227
+ const t = {
228
+ "@type": "schema:Project"
229
+ }, r = (i == null ? void 0 : i.language) ?? "de", o = X(r);
230
+ t["dct:title"] = s(R((v = e["Grundlegende Informationen/Name"]) == null ? void 0 : v.projectName, o), n.getOrUndefined), t["dct:description"] = s(R((w = e["Grundlegende Informationen/Beschreibung"]) == null ? void 0 : w.projectDescription, o), n.getOrUndefined), t["dct:identifier"] = ["__TODO__"], t["dcat:theme"] = s(G((S = e["Auffindbarkeit/Kategorien"]) == null ? void 0 : S.categories), n.getOrUndefined), t["schema:application"] = s(G((p = e["Auffindbarkeit/Anwendungsbereiche"]) == null ? void 0 : p.applications), n.getOrUndefined), t["schema:status"] = s(m((k = e["Grundlegende Informationen/Projektstatus"]) == null ? void 0 : k.projectName), n.getOrUndefined), t["schema:amount"] = s(
231
+ Z((h = e["Optionale Daten"]) == null ? void 0 : h.budget, "http://www.w3.org/2001/XMLSchema#integer"),
232
+ n.map((l) => ({
233
+ "@type": "schema:MonetaryAmount",
234
+ "schema:currency": "EUR",
235
+ "schema:value": l
236
+ })),
237
+ n.getOrUndefined
238
+ ), t["schema:skills"] = s(J((b = e["Optionale Daten"]) == null ? void 0 : b.requiredExpertise), n.getOrUndefined), t["schema:startDate"] = s(m((y = e["Optionale Daten"]) == null ? void 0 : y.startDate), n.getOrUndefined), t["schema:endDate"] = s(m((g = e["Optionale Daten"]) == null ? void 0 : g.endDate), n.getOrUndefined);
239
+ const a = [
240
+ V(
241
+ (K = e["Optionale Daten"]) == null ? void 0 : K.links,
242
+ (l) => {
243
+ const O = s(m(l.url), n.getOrUndefined);
244
+ if (O)
245
+ return {
246
+ url: O,
247
+ name: s(m(l.name), n.getOrUndefined),
248
+ description: s(m(l.description), n.getOrUndefined)
249
+ };
250
+ },
251
+ "documentation"
252
+ ),
253
+ V(
254
+ (T = e["Optionale Daten"]) == null ? void 0 : T.references,
255
+ (l) => {
256
+ const O = s(m(l.homepage), n.getOrUndefined);
257
+ if (O)
258
+ return {
259
+ url: O,
260
+ name: void 0,
261
+ description: void 0
262
+ };
263
+ },
264
+ "image"
265
+ )
266
+ ], f = Y(a);
267
+ t["dct:references"] = f.length > 0 ? f : void 0, t["dcat:contactPoint"] = s(
268
+ n.fromNullable((_ = e["Grundlegende Informationen/Organisation"]) == null ? void 0 : _.contact),
269
+ n.map((l) => ({
270
+ "@type": "vcard:Kind",
271
+ "vcard:fn": l.name,
272
+ "vcard:hasEmail": l.mail,
273
+ "vcard:hasTelephone": l.phone
274
+ })),
275
+ n.map((l) => [l]),
276
+ n.getOrUndefined
277
+ ), t["dct:contributor"] = s(
278
+ n.fromNullable((E = e["Optionale Daten"]) == null ? void 0 : E.partners),
279
+ n.map((l) => $(l)),
280
+ n.filter((l) => l.length > 0),
281
+ n.getOrUndefined
282
+ );
283
+ const u = {
284
+ projectTriggers: "Was waren Ausloeser fuer das Projekt (z. B. rechtliche oder politische Vorgaben, intrinsische Motivation oder inspirierende Projekte aus anderen Kommunen)?",
285
+ involvedStakeholders: "Welche relevanten Akteure innerhalb oder ausserhalb Ihrer Organisation haben Sie fruehzeitig involviert (z. B. um politische Rueckendeckung sicherzustellen)?",
286
+ dataCollectionMethod: "Wie haben Sie den Bestand vorhandener Daten erhoben?",
287
+ budgetPlanning: "Wie haben Sie das erste Budget berechnet und nachhaltig gesichert?"
288
+ }, j = {
289
+ requirementsGatherings: "Wie haben Sie die Anforderungen erhoben und dokumentiert (z. B. durch Markterkundung, externe Berater oder Workshops)?",
290
+ tenderFormat: "Welche Ausschreibungsform haben Sie gewaehlt und warum? Gab es eine Vorlage oder Muster-Leistungsbeschreibung, die hilfreich war?",
291
+ tenderTips: "Welche Tipps haben Sie fuer eine erfolgreiche Ausschreibung?",
292
+ resourcePlanning: "Wie haben Sie die Ressourcenplanung fuer die Entwicklung und den Betrieb Ihres Digitalen Zwillings gestaltet und gesichert?"
293
+ }, d = {
294
+ projectTriggers: "Wie haben Sie die Zusammenarbeit mit den Dienstleistern organisiert und wie wurden relevante Stakeholder in Entscheidungsprozesse eingebunden?",
295
+ involvedStakeholders: "Gab es Verzoegerungen und wenn ja, was waren die Gruende?",
296
+ dataCollectionMethod: "Welche Schnittstellen wurden genutzt und traten technische Herausforderungen auf?",
297
+ budgetPlanning: "Welche Ueberlegungen sind in Ihre Entscheidung fuer eine Open-Source-Loesung eingeflossen und welche Erfahrungen haben Sie gemacht?"
298
+ }, N = {
299
+ projectTriggers: "Was sind Ihre wichtigsten Learnings aus dem Projekt? Was wuerden Sie beim naechsten Use Case anders machen?",
300
+ involvedStakeholders: "Wird die Wirksamkeit Ihres Projekts ueberwacht und wenn ja, wie? Ist der erwartete Nutzen eingetreten?",
301
+ dataCollectionMethod: "Gibt es Plaene fuer eine Skalierung oder Weiterentwicklung? Wenn ja, wie sichern Sie die Finanzierung dafuer?",
302
+ budgetPlanning: "Welche externen Unterstuetzungsangebote haben Ihnen geholfen oder auch gefehlt?"
303
+ }, x = L([
304
+ D(e["Projektphasen (optional)/Initiieren"], "Initiieren", u),
305
+ D(e["Projektphasen (optional)/Planen"], "Planen", j),
306
+ D(e["Projektphasen (optional)/Umsetzen"], "Umsetzen", d),
307
+ D(e["Projektphasen (optional)/Weiterdenken"], "Weiterdenken", N)
308
+ ]);
309
+ t["schema:hasPart"] = c(x);
310
+ const W = L([
311
+ P({ prefixKey: "1. Datenerfassung", activityLabel: "Data collection", input: e, toLanged: o }),
312
+ P({ prefixKey: "2. Datenverarbeitung", activityLabel: "Processing", input: e, toLanged: o }),
313
+ P({ prefixKey: "3. Datensimulation", activityLabel: "Simulation", input: e, toLanged: o }),
314
+ P({ prefixKey: "4. Datenvisualisierung", activityLabel: "Visualization", input: e, toLanged: o })
315
+ ]);
316
+ return t["p-plan:hasStep"] = c(W), {
317
+ "@context": {
318
+ ...F
319
+ },
320
+ "@graph": I(t)
321
+ };
322
+ }
323
+ console.log(JSON.stringify(ae(C), null, 2));
324
+ export {
325
+ ae as encodeProject,
326
+ U as isNonNullable,
327
+ H as toLangedValue,
328
+ A as toNodeReference,
329
+ Q as toTypedValue
330
+ };
@@ -0,0 +1,37 @@
1
+ import { pipe as s } from "effect";
2
+ import * as w from "effect/Option";
3
+ const p = {
4
+ dcat: "http://www.w3.org/ns/dcat#",
5
+ dcatap: "http://data.europa.eu/r5r/",
6
+ dct: "http://purl.org/dc/terms/",
7
+ ex: "http://example.org/",
8
+ foaf: "http://xmlns.com/foaf/0.1/",
9
+ geo: "http://www.w3.org/2003/01/geo/wgs84_pos#",
10
+ lcon: "http://www.w3.org/ns/locn#",
11
+ owl: "http://www.w3.org/2002/07/owl#",
12
+ "p-plan": "http://www.opmw.org/model/p-plan/",
13
+ prov: "http://www.w3.org/ns/prov#",
14
+ pv: "https://piveau.eu/ns/voc#",
15
+ rdf: "http://www.w3.org/1999/02/22-rdf-syntax-ns#",
16
+ rdfs: "http://www.w3.org/2000/01/rdf-schema#",
17
+ schema: "https://schema.org/",
18
+ sh: "http://www.w3.org/ns/shacl#",
19
+ skos: "http://www.w3.org/2004/02/skos/core#",
20
+ sosa: "http://www.w3.org/ns/sosa/",
21
+ ssn: "http://www.w3.org/ns/ssn/",
22
+ "ssn-system": "http://www.w3.org/ns/ssn/systems/",
23
+ vcard: "http://www.w3.org/2006/vcard/ns#",
24
+ xsd: "http://www.w3.org/2001/XMLSchema#"
25
+ };
26
+ function n(o) {
27
+ return s(
28
+ w.fromNullable(o),
29
+ w.map((t) => t.trim()),
30
+ w.filter((t) => t.length > 0),
31
+ w.getOrUndefined
32
+ );
33
+ }
34
+ export {
35
+ p as PREFIXES,
36
+ n as nonEmpty
37
+ };
@@ -0,0 +1,114 @@
1
+ import { schemaDateField as s, takeFirst as e, schemaFoafAgent as i, schemaContactPoint as p, schemaIriString as o, schemaLanguageContainer as a, schemaTypedLiteral as c } from "@piveau/jsonld";
2
+ import * as t from "zod/v4";
3
+ const r = t.object({
4
+ "@id": t.string().optional(),
5
+ "@type": t.string().optional(),
6
+ "dct:type": t.preprocess(e, t.string().optional()),
7
+ "schema:url": t.preprocess(e, t.string().optional()),
8
+ "dct:title": t.preprocess(e, t.string().optional()),
9
+ "dct:description": t.preprocess(e, t.string().optional())
10
+ }), l = t.object({
11
+ "dct:title": t.preprocess(e, t.string().optional()),
12
+ "dct:description": t.preprocess(e, t.string().optional())
13
+ }), n = t.object({
14
+ "@type": t.preprocess(e, t.string().optional())
15
+ }), d = n.extend({
16
+ "@type": t.literal("pv:SoftwareLink"),
17
+ "dct:identifier": t.preprocess(e, t.string().optional()),
18
+ "schema:featureList": t.array(t.string()).optional()
19
+ }), y = n.extend({
20
+ "@type": t.literal("dcat:Dataset"),
21
+ "dct:identifier": t.preprocess(e, t.string().optional())
22
+ }), m = t.object({
23
+ "@type": t.string().optional(),
24
+ "geo:lat": t.preprocess(e, t.string().optional()),
25
+ "geo:long": t.preprocess(e, t.string().optional())
26
+ }), g = n.extend({
27
+ "@type": t.literal("ssn:Deployment"),
28
+ "dct:description": t.array(a).optional(),
29
+ "ssn:deployedSystem": t.preprocess(e, o.optional()),
30
+ /**
31
+ * The purpose of the hardware instance ("Zwecke")
32
+ */
33
+ "ssn:forProperty": t.array(t.string()).optional(),
34
+ "sosa:hasLocation": t.array(m).optional(),
35
+ "foaf:depiction": t.array(o).optional(),
36
+ "dct:references": t.array(r).optional(),
37
+ /**
38
+ * Corresponds to functionalities of hardware;
39
+ * not to be confused with schema:featureList of software
40
+ */
41
+ "ssn-system:hasSystemCapability": t.array(t.string()).optional()
42
+ }), h = t.discriminatedUnion("@type", [
43
+ d,
44
+ y,
45
+ g
46
+ ]), f = t.object({
47
+ "@type": t.string(),
48
+ "schema:text": t.preprocess(e, t.string().optional()),
49
+ "schema:acceptedAnswer": t.preprocess(e, t.string().optional())
50
+ }), j = t.object({
51
+ "@type": t.string(),
52
+ "dct:identifier": t.preprocess(e, t.string().optional()),
53
+ "dct:type": t.preprocess(e, t.string().optional()),
54
+ "schema:question": t.array(f).optional(),
55
+ "p-plan:isPrecededBy": t.preprocess(e, o.optional()),
56
+ "dct:references": t.array(r).optional()
57
+ }), u = t.object({
58
+ "@type": t.string(),
59
+ "dct:identifier": t.preprocess(e, t.string().optional()),
60
+ "p-plan:Activity": t.preprocess(e, t.string().optional()),
61
+ "dct:description": t.array(a).optional(),
62
+ "schema:about": t.array(t.string()).optional(),
63
+ "p-plan:isPrecededBy": t.preprocess(e, o.optional()),
64
+ "prov:used": t.array(l).optional(),
65
+ "p-plan:hasInputVar": t.array(h).optional(),
66
+ "dct:references": t.array(r).optional()
67
+ }), P = t.object({
68
+ "@type": t.string(),
69
+ "schema:currency": t.preprocess(e, t.string().optional()),
70
+ "schema:value": t.preprocess(e, c.optional())
71
+ }), L = t.object({
72
+ "@id": t.string().optional(),
73
+ "@type": t.string(),
74
+ // Core identifiers and labels
75
+ "dct:identifier": t.array(t.string()).optional(),
76
+ "dct:title": t.array(a).optional(),
77
+ "dct:description": t.array(a).optional(),
78
+ // Themes/categories as simple IRI nodes
79
+ "dcat:theme": t.array(o).optional(),
80
+ // Applications and status as literals
81
+ "schema:application": t.array(o).optional(),
82
+ "schema:status": t.preprocess(e, t.string().optional()),
83
+ // Optional dates (date/dateTime)
84
+ "schema:startDate": s,
85
+ "schema:endDate": s,
86
+ // Optional skills (literals)
87
+ "schema:skills": t.array(t.string()).optional(),
88
+ // Contact and partners
89
+ "dcat:contactPoint": t.array(p).optional(),
90
+ "dct:contributor": t.array(i).optional(),
91
+ // Optional budget
92
+ "schema:amount": t.preprocess(e, P.optional()),
93
+ // Organizational and technical steps
94
+ "schema:hasPart": t.array(j).optional(),
95
+ "p-plan:hasStep": t.array(u).optional(),
96
+ // References and last modified
97
+ "dct:references": t.array(r).optional(),
98
+ "prov:generatedAtTime": s
99
+ });
100
+ export {
101
+ y as schemaDatasetLink,
102
+ g as schemaHardwareInstance,
103
+ m as schemaHardwareLocation,
104
+ L as schemaProject,
105
+ h as schemaProjectInputLink,
106
+ n as schemaProjectInputLinkBase,
107
+ l as schemaProjectMethodsUsed,
108
+ P as schemaProjectMonetaryAmount,
109
+ j as schemaProjectQAPage,
110
+ f as schemaProjectQuestionAnswer,
111
+ r as schemaProjectResource,
112
+ u as schemaProjectTechnicalStep,
113
+ d as schemaSoftwareLink
114
+ };