@piveau/dpi 0.1.0-beta.8 → 0.1.0-twinby.0

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 (49) hide show
  1. package/dist/assets/dpi.css +1 -1
  2. package/dist/data-provider-interface/DPIMenu.vue.js +7 -7
  3. package/dist/data-provider-interface/DataProviderInterface.vue2.js +18 -17
  4. package/dist/data-provider-interface/HappyFlowComponents/ui/Autocomplete/Autocomplete.vue.js +7 -0
  5. package/dist/data-provider-interface/HappyFlowComponents/ui/Autocomplete/Autocomplete.vue2.js +122 -0
  6. package/dist/data-provider-interface/HappyFlowComponents/ui/Autocomplete/AutocompleteInputDefinition.js +14 -0
  7. package/dist/data-provider-interface/HappyFlowComponents/ui/Autocomplete/AutocompleteVocabFormKit.vue.js +75 -0
  8. package/dist/data-provider-interface/HappyFlowComponents/ui/Autocomplete/AutocompleteVocabFormKit.vue2.js +4 -0
  9. package/dist/data-provider-interface/HappyFlowComponents/ui/BasicInfosStep/ProjectNameStep.vue.js +29 -0
  10. package/dist/data-provider-interface/HappyFlowComponents/ui/BasicInfosStep/ProjectOrganisationStep.vue.js +7 -0
  11. package/dist/data-provider-interface/HappyFlowComponents/ui/BasicInfosStep/ProjectOrganisationStep.vue2.js +70 -0
  12. package/dist/data-provider-interface/HappyFlowComponents/ui/Chip.vue.js +19 -20
  13. package/dist/data-provider-interface/HappyFlowComponents/ui/DpiModalBase.vue.js +1 -1
  14. package/dist/data-provider-interface/HappyFlowComponents/ui/DpiModalBase.vue2.js +32 -28
  15. package/dist/data-provider-interface/HappyFlowComponents/ui/Dropdown.vue.js +1 -1
  16. package/dist/data-provider-interface/HappyFlowComponents/ui/InputField/InputFieldDefinition.js +21 -0
  17. package/dist/data-provider-interface/HappyFlowComponents/ui/InputField/InputFieldFormKit.vue.js +60 -0
  18. package/dist/data-provider-interface/HappyFlowComponents/ui/InputField/InputFieldFormKit.vue2.js +4 -0
  19. package/dist/data-provider-interface/HappyFlowComponents/ui/ListBox/Listbox.vue.js +7 -0
  20. package/dist/data-provider-interface/HappyFlowComponents/ui/ListBox/Listbox.vue2.js +98 -0
  21. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/AvailabilityV3.vue.js +16 -21
  22. package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/DistributionModal.vue.js +83 -81
  23. package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/EssentialsModal.vue.js +2 -4
  24. package/dist/data-provider-interface/components/DistLicense.vue.js +61 -63
  25. package/dist/data-provider-interface/components/DistributionSimplePage.vue.js +791 -779
  26. package/dist/data-provider-interface/components/HVDPage.vue.js +45 -43
  27. package/dist/data-provider-interface/components/InputPageStep.vue.js +9 -11
  28. package/dist/data-provider-interface/components/ProgressSteps.vue.js +7 -0
  29. package/dist/data-provider-interface/components/ProgressSteps.vue2.js +106 -0
  30. package/dist/data-provider-interface/components/ReviewAndPublishPage.vue.js +204 -204
  31. package/dist/data-provider-interface/composables/useDpiSimpleLoader.js +211 -212
  32. package/dist/data-provider-interface/composables/useDpiStepper.js +80 -39
  33. package/dist/data-provider-interface/config/dcatapdeHappyFlow/converter.js +145 -105
  34. package/dist/data-provider-interface/store/modules/conversionStore.js +130 -0
  35. package/dist/data-provider-interface/store/modules/dpiStore.js +18 -16
  36. package/dist/data-provider-interface/utils/RDFconverter.js +226 -0
  37. package/dist/data-provider-interface/utils/inputConverter.js +255 -0
  38. package/dist/data-provider-interface/utils/useSteps.js +39 -30
  39. package/dist/data-provider-interface/views/InputPage.vue.js +80 -92
  40. package/dist/data-provider-interface/views/InputPageProject.vue.js +528 -0
  41. package/dist/index.js +31 -27
  42. package/dist/stories/components/DemoStep.vue.js +331 -0
  43. package/dist/stories/components/DemoStepper.vue.js +7 -0
  44. package/dist/stories/components/DemoStepper.vue2.js +160 -0
  45. package/dist/stories/components/PartnerCard.vue.js +7 -0
  46. package/dist/stories/components/PartnerCard.vue2.js +32 -0
  47. package/dist/stories/components/ReviewStepDemo.vue.js +7 -0
  48. package/dist/stories/components/ReviewStepDemo.vue2.js +98 -0
  49. package/package.json +11 -4
@@ -1,78 +1,80 @@
1
- import { ref as i, computed as D, onMounted as P, createElementBlock as m, openBlock as f, createElementVNode as o, createCommentVNode as C, createVNode as v, toDisplayString as d, unref as p, getCurrentInstance as H } from "vue";
2
- import { useI18n as I } from "vue-i18n";
3
- import { getHvdCategories as x } from "../HappyFlowComponents/services/dpiV3_apis.js";
1
+ import { ref as i, computed as D, onMounted as P, createElementBlock as m, openBlock as f, createElementVNode as o, createCommentVNode as S, createVNode as v, toDisplayString as p, unref as u, getCurrentInstance as C } from "vue";
2
+ import { useI18n as H } from "vue-i18n";
3
+ import { getHvdCategories as I } from "../HappyFlowComponents/services/dpiV3_apis.js";
4
4
  /* empty css */
5
5
  /* empty css */
6
6
  import k from "../HappyFlowComponents/ui/SwitchV3.vue.js";
7
7
  import F from "../HappyFlowComponents/ui/Dropdown.vue.js";
8
8
  import { PhWarning as T } from "@phosphor-icons/vue";
9
+ import { useFormValues as $ } from "../composables/useDpiFormValues.js";
9
10
  /* empty css */
10
- import $ from "../../_virtual/_plugin-vue_export-helper.js";
11
- const W = { class: "V3-typography" }, B = { class: "dpiV3_Frame_831" }, E = { class: "dpiV3_Frame_840" }, K = { class: "dpiV3_title" }, N = { class: "dpiV3_intro copy-large-regular" }, O = { class: "dpiV3_Frame_830" }, z = { class: "dpiV3_Switch" }, L = { class: "dpiV3_Switch_Label copy-large-semi-bold" }, M = { class: "dpiV3_Sub_Info copy-large-regular" }, U = {
11
+ import x from "../../_virtual/_plugin-vue_export-helper.js";
12
+ const O = { class: "V3-typography" }, W = { class: "dpiV3_Frame_831" }, B = { class: "dpiV3_Frame_840" }, E = { class: "dpiV3_title" }, K = { class: "dpiV3_intro copy-large-regular" }, N = { class: "dpiV3_Frame_830" }, j = { class: "dpiV3_Switch" }, z = { class: "dpiV3_Switch_Label copy-large-semi-bold" }, L = { class: "dpiV3_Sub_Info copy-large-regular" }, M = {
12
13
  key: 0,
13
14
  class: "dpiV3_errormsgWrapper"
14
- }, j = {
15
+ }, U = {
15
16
  __name: "HVDPage",
16
17
  props: {
17
18
  context: Object
18
19
  },
19
- setup(g) {
20
- const { t: A } = I(), s = i(!1), r = i(""), _ = i([]), h = i(null), c = i([]);
20
+ setup(A) {
21
+ const { t: R } = H(), { formValues: d } = $(), s = i(!1), r = i(""), g = i([]), _ = i(null), c = i([]);
21
22
  let l = i([{ isValid: !0 }]);
22
- const V = (e) => {
23
- s.value = !e, s.value ? (l.value[0] = { isValid: !1 }, r.value = "") : (l.value[0] = { isValid: !0 }, r.value = ""), console.log("switchStateValue: ", s.value);
24
- }, u = g;
25
- u.context.node.value.length === 0 && u.context.node.input(l.value);
26
- const b = D(
23
+ const h = (e) => {
24
+ s.value = !e, s.value ? (l.value[0] = { isValid: !1 }, r.value = "") : (d.value.Discoverability.hvdPage = [{ isValid: !0 }], l.value[0] = { isValid: !0 }, r.value = ""), console.log("switchStateValue: ", s.value);
25
+ };
26
+ Object.keys(d.value.Discoverability.hvdPage).length === 0 && (d.value.Discoverability.hvdPage = l.value);
27
+ const V = D(
27
28
  () => c.value.map((e) => ({
28
29
  "@value": e.label,
29
30
  selected: !1
30
31
  }))
31
- ), w = (e) => {
32
- const t = c.value.find(
33
- (a) => a.label === e.target.innerHTML
32
+ ), b = (e) => {
33
+ l.value[0].isValid = !0;
34
+ const a = c.value.find(
35
+ (t) => t.label === e.target.innerHTML
34
36
  );
35
- u.context.node.input([
36
- { isValid: !0, label: t.label, uri: t.uri }
37
- ]), console.log(t);
38
- }, S = async () => {
37
+ d.value.Discoverability.hvdPage = [
38
+ { isValid: !0, label: a.label, uri: a.uri }
39
+ ];
40
+ }, w = async () => {
39
41
  try {
40
- const e = H().appContext.app.config.globalProperties.$env, a = (await x(e.api.baseUrl)).sort(
42
+ const e = C().appContext.app.config.globalProperties.$env, t = (await I(e.api.baseUrl)).sort(
41
43
  (n, y) => n.pref_label.de.localeCompare(y.pref_label.de)
42
44
  );
43
- _.value = a, c.value = a.map((n) => ({
45
+ g.value = t, c.value = t.map((n) => ({
44
46
  label: n.pref_label.de,
45
47
  uri: n.resource
46
48
  }));
47
49
  } catch (e) {
48
- console.error("Error in component:", e), h.value = e;
50
+ console.error("Error in component:", e), _.value = e;
49
51
  }
50
52
  };
51
53
  return P(() => {
52
- S();
53
- }), (e, t) => (f(), m("div", W, [
54
- o("div", B, [
55
- o("div", E, [
56
- o("h4", K, d(e.$t("message.dataupload.datasets.hvdPage.title")), 1),
57
- o("div", N, d(e.$t("message.dataupload.datasets.hvdPage.intro-text")), 1),
58
- o("div", O, [
59
- o("div", z, [
54
+ w();
55
+ }), (e, a) => (f(), m("div", O, [
56
+ o("div", W, [
57
+ o("div", B, [
58
+ o("h4", E, p(e.$t("message.dataupload.datasets.hvdPage.title")), 1),
59
+ o("div", K, p(e.$t("message.dataupload.datasets.hvdPage.intro-text")), 1),
60
+ o("div", N, [
61
+ o("div", j, [
60
62
  v(k, {
61
- onSwitchToggled: t[0] || (t[0] = (a) => p(l)[0].isValid === !0 ? V(s.value) : (p(l)[0].isValid = !0, s.value = !s.value)),
63
+ onSwitchToggled: a[0] || (a[0] = (t) => u(l)[0].isValid === !0 ? h(s.value) : (u(l)[0].isValid = !0, s.value = !s.value)),
62
64
  hasIcon: !1,
63
65
  defaultChecked: !1,
64
66
  disabled: !1
65
67
  })
66
68
  ]),
67
- o("div", L, d(e.$t("message.dataupload.datasets.hvdPage.switch-label")), 1)
69
+ o("div", z, p(e.$t("message.dataupload.datasets.hvdPage.switch-label")), 1)
68
70
  ]),
69
- o("div", M, d(e.$t("message.dataupload.datasets.hvdPage.sub-info")), 1),
71
+ o("div", L, p(e.$t("message.dataupload.datasets.hvdPage.sub-info")), 1),
70
72
  v(F, {
71
73
  dropdownWidth: "large",
72
74
  isDisabled: !s.value,
73
75
  type: "inputField",
74
76
  modelValue: r.value,
75
- "onUpdate:modelValue": t[1] || (t[1] = (a) => r.value = a),
77
+ "onUpdate:modelValue": a[1] || (a[1] = (t) => r.value = t),
76
78
  inputFieldProps: {
77
79
  isDisabled: !s.value,
78
80
  addOnText: !1,
@@ -86,21 +88,21 @@ const W = { class: "V3-typography" }, B = { class: "dpiV3_Frame_831" }, E = { cl
86
88
  inputFieldSize: "large",
87
89
  modelValue: r.value
88
90
  },
89
- data: b.value,
90
- onClick: t[2] || (t[2] = (a) => w(a))
91
+ data: V.value,
92
+ onClick: a[2] || (a[2] = (t) => b(t))
91
93
  }, null, 8, ["isDisabled", "modelValue", "inputFieldProps", "data"])
92
94
  ]),
93
- p(l).find((a) => a.isValid === !1) ? (f(), m("div", U, [
94
- v(p(T), {
95
+ u(l).find((t) => t.isValid === !1) ? (f(), m("div", M, [
96
+ v(u(T), {
95
97
  size: 16,
96
98
  weight: "fill"
97
99
  }),
98
- t[3] || (t[3] = o("span", { class: "copy-mini-regular" }, "Bitte wählen Sie eine HVD-Kategorie aus, bevor Sie fortfahren.", -1))
99
- ])) : C("", !0)
100
+ a[3] || (a[3] = o("span", { class: "copy-mini-regular" }, "Bitte wählen Sie eine HVD-Kategorie aus, bevor Sie fortfahren.", -1))
101
+ ])) : S("", !0)
100
102
  ])
101
103
  ]));
102
104
  }
103
- }, ae = /* @__PURE__ */ $(j, [["__scopeId", "data-v-9c7f317c"]]);
105
+ }, se = /* @__PURE__ */ x(U, [["__scopeId", "data-v-dbc7ac7f"]]);
104
106
  export {
105
- ae as default
107
+ se as default
106
108
  };
@@ -1,6 +1,6 @@
1
- import { defineComponent as i, inject as a, computed as s, resolveComponent as c, withDirectives as m, createElementBlock as l, openBlock as d, normalizeClass as u, createVNode as v, withCtx as S, renderSlot as f, vShow as _ } from "vue";
1
+ import { defineComponent as i, inject as a, computed as s, resolveComponent as m, withDirectives as c, createElementBlock as l, openBlock as d, normalizeClass as u, createVNode as v, withCtx as f, renderSlot as S, vShow as _ } from "vue";
2
2
  import { dpiStepperKey as h } from "../utils/injectionKeys.js";
3
- const K = /* @__PURE__ */ i({
3
+ const k = /* @__PURE__ */ i({
4
4
  __name: "InputPageStep",
5
5
  props: {
6
6
  name: {}
@@ -10,12 +10,10 @@ const K = /* @__PURE__ */ i({
10
10
  if (!t)
11
11
  throw new Error("dpiStepper is not provided. Please make sure to use this component inside InputPage");
12
12
  t.registerStep(e.name);
13
- const o = s(() => t.activeStep.value === e.name), {
14
- activeStep: w
15
- } = t;
16
- return (r, g) => {
17
- const p = c("FormKit");
18
- return m((d(), l("section", {
13
+ const o = s(() => t.activeStep.value === e.name);
14
+ return (r, w) => {
15
+ const p = m("FormKit");
16
+ return c((d(), l("section", {
19
17
  class: u({ activeSection: o.value })
20
18
  }, [
21
19
  v(p, {
@@ -24,8 +22,8 @@ const K = /* @__PURE__ */ i({
24
22
  name: e.name,
25
23
  ref: e.name
26
24
  }, {
27
- default: S(() => [
28
- f(r.$slots, "default")
25
+ default: f(() => [
26
+ S(r.$slots, "default")
29
27
  ]),
30
28
  _: 3
31
29
  }, 8, ["id", "name"])
@@ -36,5 +34,5 @@ const K = /* @__PURE__ */ i({
36
34
  }
37
35
  });
38
36
  export {
39
- K as default
37
+ k as default
40
38
  };
@@ -0,0 +1,7 @@
1
+ import o from "./ProgressSteps.vue2.js";
2
+ /* empty css */
3
+ import r from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const p = /* @__PURE__ */ r(o, [["__scopeId", "data-v-1c5f25e6"]]);
5
+ export {
6
+ p as default
7
+ };
@@ -0,0 +1,106 @@
1
+ import { defineComponent as w, mergeModels as B, computed as f, useModel as k, createElementBlock as l, openBlock as c, Fragment as S, renderList as x, withDirectives as i, createElementVNode as s, vModelCheckbox as y, unref as a, normalizeClass as C, toDisplayString as M, vShow as m } from "vue";
2
+ import { looseIndexOf as b } from "@vue/shared";
3
+ import D from "../HappyFlowComponents/img/Circle.svg.js";
4
+ import E from "../HappyFlowComponents/img/CircleFill.svg.js";
5
+ const F = { class: "progress-steps" }, U = ["value"], j = { class: "progress-step__headline" }, z = ["src"], I = { class: "progress-step__content" }, L = { class: "progress-step__content-line-container" }, P = { class: "progress-steps progress-steps--substep" }, R = ["value"], q = { class: "progress-step__headline" }, A = ["src"], G = { class: "progress-step__content" }, H = { class: "progress-step__content-line-container" }, W = /* @__PURE__ */ w({
6
+ __name: "ProgressSteps",
7
+ props: /* @__PURE__ */ B({
8
+ steps: {},
9
+ currentStep: {},
10
+ visitedSteps: { default: () => [] }
11
+ }, {
12
+ checked: {
13
+ default: () => []
14
+ },
15
+ checkedModifiers: {},
16
+ current: {
17
+ default: () => "moo"
18
+ },
19
+ currentModifiers: {}
20
+ }),
21
+ emits: ["update:checked", "update:current"],
22
+ setup(p) {
23
+ const v = p, h = f(() => {
24
+ const n = {};
25
+ return v.steps.forEach((e) => {
26
+ const t = e.includes("/") ? e.split("/")[0] : e;
27
+ n[t] || (n[t] = []), n[t].push(e);
28
+ }), Object.entries(n).map(([e, t]) => ({ name: e, substeps: t }));
29
+ }), N = (n) => n.includes("/") ? n.split("/")[1] : n, g = (n) => !n.includes("/"), o = k(p, "checked");
30
+ function d(n) {
31
+ return b(o.value, n) !== -1;
32
+ }
33
+ const u = k(p, "current");
34
+ return f(() => b(v.steps, u.value)), (n, e) => (c(), l("div", F, [
35
+ (c(!0), l(S, null, x(h.value, (t, O) => (c(), l("div", {
36
+ class: "progress-step",
37
+ key: t.name
38
+ }, [
39
+ i(s("input", {
40
+ name: "progress-step",
41
+ type: "checkbox",
42
+ class: "progress-input",
43
+ "onUpdate:modelValue": e[0] || (e[0] = (r) => o.value = r),
44
+ value: t.name
45
+ }, null, 8, U), [
46
+ [y, o.value]
47
+ ]),
48
+ s("div", j, [
49
+ s("img", {
50
+ src: d(t.name) ? a(E) : a(D),
51
+ class: "progress-step__headline__icon",
52
+ alt: ""
53
+ }, null, 8, z),
54
+ s("span", {
55
+ class: C({ "progress-step__headline__span--checked": u.value === t.name })
56
+ }, M(t.name), 3)
57
+ ]),
58
+ s("div", I, [
59
+ i(s("div", L, e[2] || (e[2] = [
60
+ s("div", { class: "progress-step__content-line" }, null, -1)
61
+ ]), 512), [
62
+ [m, O < h.value.length - 1]
63
+ ]),
64
+ i(s("div", P, [
65
+ (c(!0), l(S, null, x(t.substeps.filter((r) => !g(r)), (r, V) => (c(), l("div", {
66
+ class: "progress-step",
67
+ key: r
68
+ }, [
69
+ i(s("input", {
70
+ name: "progress-step",
71
+ type: "checkbox",
72
+ class: "progress-input",
73
+ "onUpdate:modelValue": e[1] || (e[1] = (_) => o.value = _),
74
+ value: r
75
+ }, null, 8, R), [
76
+ [y, o.value]
77
+ ]),
78
+ s("div", q, [
79
+ s("img", {
80
+ src: d(r) ? a(E) : a(D),
81
+ class: "progress-step__headline__icon",
82
+ alt: ""
83
+ }, null, 8, A),
84
+ s("span", {
85
+ class: C({ "progress-step__headline__span--checked": u.value === r })
86
+ }, M(N(r)), 3)
87
+ ]),
88
+ s("div", G, [
89
+ i(s("div", H, e[3] || (e[3] = [
90
+ s("div", { class: "progress-step__content-line" }, null, -1)
91
+ ]), 512), [
92
+ [m, V < t.substeps.filter((_) => !g(_)).length - 1]
93
+ ])
94
+ ])
95
+ ]))), 128))
96
+ ], 512), [
97
+ [m, !d(t.name)]
98
+ ])
99
+ ])
100
+ ]))), 128))
101
+ ]));
102
+ }
103
+ });
104
+ export {
105
+ W as default
106
+ };