@piveau/dpi 0.2.0-alpha.13 → 0.2.0-alpha.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/dpi.css +1 -1
- package/dist/packages/dpi/src/data-provider-interface/DataProviderInterface.vue2.js +48 -47
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/HomeTable.vue.js +74 -71
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ProjectTable.vue.js +4 -94
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ProjectTable.vue2.js +104 -0
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Autocomplete/AutocompleteVocab.vue.js +2 -2
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Autocomplete/AutocompleteVocab.vue2.js +64 -52
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/BasicInfosStep/ProjectNameStep.vue.js +8 -8
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DpiModalBase.vue.js +2 -2
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/DpiModalBase.vue2.js +1 -1
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Findability/CategoriesStep.vue.js +2 -2
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/Findability/CategoriesStep.vue2.js +4 -4
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/OptionalDataStep/OptionalDataStep.vue.js +2 -2
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/OptionalDataStep/OptionalDataStep.vue2.js +21 -21
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/DatasetStep.vue.js +2 -2
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/DatasetStep.vue2.js +73 -71
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/GetResource.vue.js +4 -4
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/HardwareForm.vue.js +2 -2
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/HardwareStep.vue.js +2 -2
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/HardwareStep.vue2.js +133 -131
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/SoftwareStep.vue.js +2 -2
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ProcessSteps/SoftwareStep.vue2.js +85 -83
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ReviewStep/ReviewStep.vue.js +2 -2
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/ReviewStep/ReviewStep.vue2.js +4 -4
- package/dist/packages/dpi/src/data-provider-interface/HappyFlowComponents/ui/TableRowV3.vue.js +179 -133
- package/dist/packages/dpi/src/data-provider-interface/components/StepActionsSection.vue.js +2 -2
- package/dist/packages/dpi/src/data-provider-interface/components/StepActionsSection.vue2.js +111 -91
- package/dist/packages/dpi/src/data-provider-interface/components/TheCancelConfirmationDialog.vue.js +3 -3
- package/dist/packages/dpi/src/data-provider-interface/components/TheCancelConfirmationDialog.vue2.js +24 -19
- package/dist/packages/dpi/src/data-provider-interface/components/dev-tools/ProjectDpiDevTools.vue.js +2 -2
- package/dist/packages/dpi/src/data-provider-interface/components/dev-tools/ProjectDpiDevTools.vue2.js +137 -94
- package/dist/packages/dpi/src/data-provider-interface/composables/project-transformer/decodeProject.js +152 -135
- package/dist/packages/dpi/src/data-provider-interface/composables/project-transformer/encodeProject.js +201 -164
- package/dist/packages/dpi/src/data-provider-interface/composables/useDpiContext.js +9 -10
- package/dist/packages/dpi/src/data-provider-interface/composables/useDpiEditMode.js +88 -66
- package/dist/packages/dpi/src/data-provider-interface/composables/useDpiSimpleLoader.js +274 -273
- package/dist/packages/dpi/src/data-provider-interface/composables/useDpiStepper.js +33 -32
- package/dist/packages/dpi/src/data-provider-interface/composables/useDpiUtils.js +18 -9
- package/dist/packages/dpi/src/data-provider-interface/composables/useProjectActions.js +65 -0
- package/dist/packages/dpi/src/data-provider-interface/composables/useTwinbyHome.js +50 -0
- package/dist/packages/dpi/src/data-provider-interface/schema/projectLdSchema.js +48 -45
- package/dist/packages/dpi/src/data-provider-interface/views/InputPageProject.vue.js +386 -397
- package/dist/packages/dpi/src/utils/schema/schemaProject.js +210 -0
- package/dist/packages/dpi/src/utils/schema/shared.js +23 -0
- package/package.json +3 -3
|
@@ -1,12 +1,16 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { getNode as
|
|
3
|
-
import { getValidationMessages as
|
|
4
|
-
import { PhExclamationMark as
|
|
5
|
-
import
|
|
6
|
-
import
|
|
1
|
+
import { defineComponent as W, inject as j, ref as v, watch as F, computed as I, createElementBlock as r, openBlock as o, normalizeClass as $, createElementVNode as m, createBlock as p, createCommentVNode as V, createVNode as s, renderSlot as w, unref as N, normalizeStyle as K, withDirectives as h, vShow as y, Fragment as E, withCtx as g, renderList as R, toDisplayString as O, nextTick as U } from "vue";
|
|
2
|
+
import { getNode as Z, isNode as q } from "@formkit/core";
|
|
3
|
+
import { getValidationMessages as G } from "@formkit/validation";
|
|
4
|
+
import { PhExclamationMark as H } from "@phosphor-icons/vue";
|
|
5
|
+
import l from "../HappyFlowComponents/ui/ButtonV3.vue.js";
|
|
6
|
+
import J from "../HappyFlowComponents/ui/Card.vue.js";
|
|
7
7
|
import { dpiStepperKey as Q } from "../utils/injectionKeys.js";
|
|
8
8
|
import X from "./TheCancelConfirmationDialog.vue.js";
|
|
9
|
-
|
|
9
|
+
import { useEditModeInfo as Y } from "../composables/useDpiEditMode.js";
|
|
10
|
+
const _ = { class: "step-actions" }, ee = { class: "step-actions__prev-and-next" }, te = {
|
|
11
|
+
key: 0,
|
|
12
|
+
class: "validation-errors"
|
|
13
|
+
}, me = /* @__PURE__ */ W({
|
|
10
14
|
__name: "StepActionsSection",
|
|
11
15
|
props: {
|
|
12
16
|
hideCancel: { type: Boolean, default: !1 },
|
|
@@ -17,132 +21,148 @@ const Y = { class: "step-actions" }, _ = { class: "step-actions__prev-and-next"
|
|
|
17
21
|
previousText: { default: "Zurück" },
|
|
18
22
|
nextText: { default: "Weiter" },
|
|
19
23
|
nextVariant: { default: "primary" },
|
|
20
|
-
classList: {}
|
|
24
|
+
classList: {},
|
|
25
|
+
showDetailedErrorSummary: { type: Boolean, default: !1 }
|
|
21
26
|
},
|
|
22
|
-
emits: ["submit"],
|
|
23
|
-
setup(
|
|
24
|
-
const
|
|
25
|
-
|
|
26
|
-
function
|
|
27
|
-
return
|
|
27
|
+
emits: ["submit", "closeWithSaving"],
|
|
28
|
+
setup(ne, { emit: B }) {
|
|
29
|
+
const x = B, t = j(Q);
|
|
30
|
+
t || console.warn("dpiStepper is not provided. Please use StepActionsSection inside InputPage");
|
|
31
|
+
function C(e) {
|
|
32
|
+
return e !== void 0;
|
|
28
33
|
}
|
|
29
|
-
const
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
return;
|
|
33
|
-
const n = H(t);
|
|
34
|
-
!n || n.size === 0 || (a.value = [...n.entries()].flatMap(([o, w]) => w.map((B) => String(B.value))));
|
|
35
|
-
}
|
|
36
|
-
e && D(e.activeStep, () => {
|
|
37
|
-
a.value.splice(0, a.value.length), s.value = !1;
|
|
34
|
+
const c = v(!1), u = v(!1), i = v([]);
|
|
35
|
+
t && F(t.activeStep, () => {
|
|
36
|
+
i.value.splice(0, i.value.length), u.value = !1;
|
|
38
37
|
});
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
var o;
|
|
42
|
-
const n = (o = b.value) == null ? void 0 : o[t];
|
|
43
|
-
return n ? n.valid : !1;
|
|
38
|
+
function S() {
|
|
39
|
+
c.value = !0;
|
|
44
40
|
}
|
|
45
|
-
function
|
|
46
|
-
|
|
41
|
+
function f() {
|
|
42
|
+
t == null || t.goToPreviousStep();
|
|
47
43
|
}
|
|
48
|
-
function
|
|
49
|
-
|
|
44
|
+
async function b() {
|
|
45
|
+
var k, T;
|
|
46
|
+
if (!C(t))
|
|
47
|
+
return !1;
|
|
48
|
+
t.triggerValidationCurrentStep(), await U();
|
|
49
|
+
const e = t.activeStep.value;
|
|
50
|
+
if (!e)
|
|
51
|
+
return !1;
|
|
52
|
+
const n = Z(e);
|
|
53
|
+
if (!q(n))
|
|
54
|
+
return console.error("Current step node is not a FormKitNode", n), !1;
|
|
55
|
+
const a = G(n), D = !!((T = (k = t.steps) == null ? void 0 : k[e]) != null && T.valid);
|
|
56
|
+
return a && a.size > 0 || !D ? (i.value = [...a.entries()].flatMap(([oe, M]) => M.map((A) => String(A.value))), u.value = !0, !1) : (i.value.splice(0, i.value.length), u.value = !1, !0);
|
|
50
57
|
}
|
|
51
|
-
function
|
|
52
|
-
|
|
58
|
+
async function d() {
|
|
59
|
+
!C(t) || !await b() || (t != null && t.isLast.value ? x("submit") : t == null || t.goToNextStep());
|
|
53
60
|
}
|
|
54
|
-
const
|
|
55
|
-
async function
|
|
56
|
-
|
|
57
|
-
return;
|
|
58
|
-
e.triggerValidationCurrentStep(), await Z();
|
|
59
|
-
const t = P.value;
|
|
60
|
-
if (t ? !p((e == null ? void 0 : e.activeStep.value) || "") : !1) {
|
|
61
|
-
if (!G(t)) {
|
|
62
|
-
console.error("Current step node is not a FormKitNode", t);
|
|
63
|
-
return;
|
|
64
|
-
}
|
|
65
|
-
N(t), s.value = !0;
|
|
66
|
-
}
|
|
67
|
-
e != null && e.isLast.value ? V("submit") : k();
|
|
61
|
+
const { isEditMode: P } = Y();
|
|
62
|
+
async function z() {
|
|
63
|
+
!t || !await b() || t == null || t.goToStep(Object.keys(t.steps).pop() || "");
|
|
68
64
|
}
|
|
69
|
-
|
|
70
|
-
|
|
65
|
+
const L = I(() => t == null ? void 0 : t.isLast.value);
|
|
66
|
+
return (e, n) => (o(), r("div", {
|
|
67
|
+
class: $([e.classList, "step-actions-container"])
|
|
71
68
|
}, [
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
69
|
+
m("div", _, [
|
|
70
|
+
N(P) ? (o(), r(E, { key: 1 }, [
|
|
71
|
+
L.value ? h((o(), p(l, {
|
|
72
|
+
key: 1,
|
|
73
|
+
class: "edit-save-button",
|
|
74
|
+
size: "large",
|
|
75
|
+
variant: e.nextVariant,
|
|
76
|
+
type: "button",
|
|
77
|
+
"button-text": e.nextText,
|
|
78
|
+
"icon-end": e.nextText === "Als Entwurf Speichern" ? null : "CaretRight",
|
|
79
|
+
onClick: d
|
|
80
|
+
}, null, 8, ["variant", "button-text", "icon-end"])), [
|
|
81
|
+
[y, !e.hideNext]
|
|
82
|
+
]) : (o(), p(l, {
|
|
83
|
+
key: 0,
|
|
84
|
+
class: "edit-save-button",
|
|
85
|
+
size: "large",
|
|
86
|
+
variant: "primary",
|
|
87
|
+
type: "button",
|
|
88
|
+
"button-text": "Speichern",
|
|
89
|
+
onClick: z
|
|
90
|
+
}))
|
|
91
|
+
], 64)) : w(e.$slots, "default", {
|
|
92
|
+
key: 0,
|
|
93
|
+
handleCancel: S,
|
|
94
|
+
handlePrevious: f,
|
|
95
|
+
handleSubmit: d
|
|
77
96
|
}, () => [
|
|
78
|
-
|
|
79
|
-
style:
|
|
97
|
+
s(l, {
|
|
98
|
+
style: K({ opacity: e.hideCancel ? 0 : 1 }),
|
|
80
99
|
variant: "tertiary",
|
|
81
100
|
size: "large",
|
|
82
101
|
type: "button",
|
|
83
|
-
"button-text":
|
|
84
|
-
onClick:
|
|
102
|
+
"button-text": e.cancelText,
|
|
103
|
+
onClick: S
|
|
85
104
|
}, null, 8, ["style", "button-text"]),
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
hidePrevious:
|
|
89
|
-
hideNext:
|
|
90
|
-
previousText:
|
|
91
|
-
nextText:
|
|
92
|
-
handlePrevious:
|
|
93
|
-
handleSubmit:
|
|
105
|
+
m("div", ee, [
|
|
106
|
+
w(e.$slots, "prev-and-next", {
|
|
107
|
+
hidePrevious: e.hidePrevious,
|
|
108
|
+
hideNext: e.hideNext,
|
|
109
|
+
previousText: e.previousText,
|
|
110
|
+
nextText: e.nextText,
|
|
111
|
+
handlePrevious: f,
|
|
112
|
+
handleSubmit: d
|
|
94
113
|
}, () => [
|
|
95
|
-
|
|
114
|
+
h(s(l, {
|
|
96
115
|
variant: "secondary",
|
|
97
116
|
size: "large",
|
|
98
117
|
type: "button",
|
|
99
|
-
"button-text":
|
|
118
|
+
"button-text": e.previousText,
|
|
100
119
|
"icon-start": "CaretLeft",
|
|
101
|
-
onClick:
|
|
120
|
+
onClick: f
|
|
102
121
|
}, null, 8, ["button-text"]), [
|
|
103
|
-
[y, !
|
|
122
|
+
[y, !e.hidePrevious]
|
|
104
123
|
]),
|
|
105
|
-
|
|
124
|
+
h(s(l, {
|
|
106
125
|
size: "large",
|
|
107
|
-
variant:
|
|
126
|
+
variant: e.nextVariant,
|
|
108
127
|
type: "button",
|
|
109
|
-
"button-text":
|
|
110
|
-
"icon-end":
|
|
111
|
-
onClick:
|
|
128
|
+
"button-text": e.nextText,
|
|
129
|
+
"icon-end": e.nextText === "Als Entwurf Speichern" || e.nextText === "Projektanlage starten" ? null : "CaretRight",
|
|
130
|
+
onClick: d
|
|
112
131
|
}, null, 8, ["variant", "button-text", "icon-end"]), [
|
|
113
|
-
[y, !
|
|
132
|
+
[y, !e.hideNext]
|
|
114
133
|
])
|
|
115
134
|
], !0)
|
|
116
135
|
])
|
|
117
136
|
], !0)
|
|
118
137
|
]),
|
|
119
|
-
|
|
138
|
+
u.value && i.value.length ? (o(), p(J, {
|
|
120
139
|
key: 0,
|
|
121
140
|
variant: "error"
|
|
122
141
|
}, {
|
|
123
|
-
icon:
|
|
124
|
-
|
|
142
|
+
icon: g(() => [
|
|
143
|
+
s(N(H), {
|
|
125
144
|
size: 32,
|
|
126
145
|
color: "currentColor"
|
|
127
146
|
})
|
|
128
147
|
]),
|
|
129
|
-
title:
|
|
130
|
-
|
|
148
|
+
title: g(() => n[2] || (n[2] = [
|
|
149
|
+
m("p", null, "Bitte korrigieren Sie die folgenden Fehler", -1)
|
|
131
150
|
])),
|
|
132
|
-
default:
|
|
133
|
-
|
|
134
|
-
(
|
|
135
|
-
])
|
|
151
|
+
default: g(() => [
|
|
152
|
+
e.showDetailedErrorSummary ? (o(), r("ul", te, [
|
|
153
|
+
(o(!0), r(E, null, R(i.value, (a) => (o(), r("li", { key: a }, O(a), 1))), 128))
|
|
154
|
+
])) : V("", !0)
|
|
136
155
|
]),
|
|
137
156
|
_: 1
|
|
138
|
-
})) :
|
|
139
|
-
|
|
140
|
-
modelValue:
|
|
141
|
-
"onUpdate:modelValue": n[0] || (n[0] = (
|
|
157
|
+
})) : V("", !0),
|
|
158
|
+
s(X, {
|
|
159
|
+
modelValue: c.value,
|
|
160
|
+
"onUpdate:modelValue": n[0] || (n[0] = (a) => c.value = a),
|
|
161
|
+
onCloseWithSaving: n[1] || (n[1] = (a) => x("closeWithSaving"))
|
|
142
162
|
}, null, 8, ["modelValue"])
|
|
143
163
|
], 2));
|
|
144
164
|
}
|
|
145
165
|
});
|
|
146
166
|
export {
|
|
147
|
-
|
|
167
|
+
me as default
|
|
148
168
|
};
|
package/dist/packages/dpi/src/data-provider-interface/components/TheCancelConfirmationDialog.vue.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./TheCancelConfirmationDialog.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
|
-
import
|
|
4
|
-
const
|
|
3
|
+
import t from "../../../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
+
const i = /* @__PURE__ */ t(o, [["__scopeId", "data-v-0b6e98c6"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
i as default
|
|
7
7
|
};
|
package/dist/packages/dpi/src/data-provider-interface/components/TheCancelConfirmationDialog.vue2.js
CHANGED
|
@@ -1,42 +1,47 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import g from "../
|
|
4
|
-
|
|
1
|
+
import { defineComponent as d, mergeModels as f, useModel as p, createBlock as c, openBlock as v, withCtx as o, createElementVNode as n, createVNode as a } from "vue";
|
|
2
|
+
import { useRouter as V } from "vue-router";
|
|
3
|
+
import { useProjectActions as g } from "../composables/useProjectActions.js";
|
|
4
|
+
import i from "../HappyFlowComponents/ui/ButtonV3.vue.js";
|
|
5
|
+
import h from "../HappyFlowComponents/ui/DpiModalBase.vue.js";
|
|
6
|
+
const y = /* @__PURE__ */ d({
|
|
5
7
|
__name: "TheCancelConfirmationDialog",
|
|
6
8
|
props: {
|
|
7
9
|
modelValue: { type: Boolean },
|
|
8
10
|
modelModifiers: {}
|
|
9
11
|
},
|
|
10
|
-
emits: /* @__PURE__ */
|
|
11
|
-
setup(
|
|
12
|
-
const
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
12
|
+
emits: /* @__PURE__ */ f(["closeWithoutSaving", "closeWithSaving"], ["update:modelValue"]),
|
|
13
|
+
setup(l, { emit: k }) {
|
|
14
|
+
const s = V(), t = p(l, "modelValue"), { submitDraft: u } = g();
|
|
15
|
+
async function m() {
|
|
16
|
+
await u.execute(), s.push({ name: "DPI-Home-HappyFlow" });
|
|
17
|
+
}
|
|
18
|
+
return (w, e) => (v(), c(h, {
|
|
19
|
+
modelValue: t.value,
|
|
20
|
+
"onUpdate:modelValue": e[1] || (e[1] = (r) => t.value = r)
|
|
16
21
|
}, {
|
|
17
|
-
header: o(() => e[
|
|
18
|
-
|
|
22
|
+
header: o(() => e[2] || (e[2] = [
|
|
23
|
+
n("h4", { class: "cancel-header" }, " Projektanlage später fortführen ", -1)
|
|
19
24
|
])),
|
|
20
25
|
footer: o(() => [
|
|
21
|
-
i
|
|
26
|
+
a(i, {
|
|
22
27
|
"button-text": "Bearbeitung verwerfen",
|
|
23
28
|
variant: "secondary",
|
|
24
|
-
onClick: e[0] || (e[0] = (
|
|
29
|
+
onClick: e[0] || (e[0] = (r) => t.value = !1)
|
|
25
30
|
}),
|
|
26
|
-
i
|
|
31
|
+
a(i, {
|
|
27
32
|
"button-text": "Projekt als Entwurf speichern",
|
|
28
33
|
variant: "primary",
|
|
29
|
-
onClick:
|
|
34
|
+
onClick: m
|
|
30
35
|
})
|
|
31
36
|
]),
|
|
32
37
|
default: o(() => [
|
|
33
|
-
e[
|
|
38
|
+
e[3] || (e[3] = n("div", null, " Sie können die Projektanlage später fortführen und Ihren bisherigen Fortschritt entweder verwerfen oder als Entwurf speichern. ", -1))
|
|
34
39
|
]),
|
|
35
40
|
_: 1,
|
|
36
|
-
__: [
|
|
41
|
+
__: [3]
|
|
37
42
|
}, 8, ["modelValue"]));
|
|
38
43
|
}
|
|
39
44
|
});
|
|
40
45
|
export {
|
|
41
|
-
|
|
46
|
+
y as default
|
|
42
47
|
};
|
package/dist/packages/dpi/src/data-provider-interface/components/dev-tools/ProjectDpiDevTools.vue.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./ProjectDpiDevTools.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../../../../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const
|
|
4
|
+
const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-fd08af1e"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
p as default
|
|
7
7
|
};
|