@piveau/dpi 0.1.0-beta.47 → 0.1.0-beta.49

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.
@@ -1,5 +1,5 @@
1
- import { mergeModels as A, ref as R, getCurrentInstance as z, useModel as H, computed as N, watch as o, createElementBlock as u, openBlock as c, createElementVNode as l, createVNode as s, createCommentVNode as d, unref as h, toDisplayString as n } from "vue";
2
- import p from "../InputField.vue.js";
1
+ import { mergeModels as A, ref as R, getCurrentInstance as z, useModel as H, computed as N, watch as o, createElementBlock as u, openBlock as c, createElementVNode as s, createVNode as l, createCommentVNode as d, unref as p, toDisplayString as n } from "vue";
2
+ import h from "../InputField.vue.js";
3
3
  import x from "../TextAreaV3.vue.js";
4
4
  import { PhWarning as m } from "@phosphor-icons/vue";
5
5
  import "@formkit/core";
@@ -7,31 +7,31 @@ import "@formkit/vue";
7
7
  import { useFormValues as D } from "../../../composables/useDpiFormValues.js";
8
8
  /* empty css */
9
9
  import F from "../../../../_virtual/_plugin-vue_export-helper.js";
10
- const L = { class: "dpiV3_innerRapModalWrapper" }, O = { class: "dpiV3_innerRapModalWrapper__section" }, Z = {
10
+ const O = { class: "dpiV3_innerRapModalWrapper" }, L = { class: "dpiV3_innerRapModalWrapper__section" }, Z = {
11
11
  key: 0,
12
12
  class: "dpiV3_field_error_text"
13
- }, j = { class: "copy-mini-regular" }, q = {
14
- key: 1,
13
+ }, j = { class: "copy-mini-regular" }, q = { class: "topSpacing" }, G = {
14
+ key: 0,
15
15
  class: "dpiV3_field_error_text"
16
- }, G = { class: "copy-mini-regular" }, J = { class: "dpiV3_innerRapModalWrapper__section" }, K = { class: "headline-5 gap3BottomAsMargin" }, Q = {
16
+ }, J = { class: "copy-mini-regular" }, K = { class: "topSpacing" }, Q = { class: "dpiV3_innerRapModalWrapper__section" }, X = { class: "headline-5 gap3BottomAsMargin" }, Y = { class: "topSpacing" }, ee = {
17
17
  key: 0,
18
18
  class: "dpiV3_field_error_text"
19
- }, X = { class: "copy-mini-regular" }, Y = {
20
- key: 1,
19
+ }, te = { class: "copy-mini-regular" }, ae = { class: "topSpacing" }, re = {
20
+ key: 0,
21
21
  class: "dpiV3_field_error_text"
22
- }, ee = { class: "copy-mini-regular" }, te = {
23
- key: 2,
22
+ }, se = { class: "copy-mini-regular" }, le = { class: "topSpacing" }, ie = {
23
+ key: 0,
24
24
  class: "dpiV3_field_error_text"
25
- }, re = { class: "copy-mini-regular" }, ae = { class: "dpiV3_innerRapModalWrapper__section" }, se = { class: "headline-5 gap3BottomAsMargin" }, le = {
25
+ }, oe = { class: "copy-mini-regular" }, ne = { class: "dpiV3_innerRapModalWrapper__section" }, ue = { class: "headline-5 gap3BottomAsMargin" }, ce = { class: "topSpacing" }, de = {
26
26
  key: 0,
27
27
  class: "dpiV3_field_error_text"
28
- }, ie = { class: "copy-mini-regular" }, oe = {
29
- key: 1,
28
+ }, pe = { class: "copy-mini-regular" }, he = { class: "topSpacing" }, me = {
29
+ key: 0,
30
30
  class: "dpiV3_field_error_text"
31
- }, ne = { class: "copy-mini-regular" }, ue = {
32
- key: 2,
31
+ }, ge = { class: "copy-mini-regular" }, be = { class: "topSpacing" }, ve = {
32
+ key: 0,
33
33
  class: "dpiV3_field_error_text"
34
- }, ce = { class: "copy-mini-regular" }, de = {
34
+ }, fe = { class: "copy-mini-regular" }, Ee = {
35
35
  __name: "EssentialsModal",
36
36
  props: /* @__PURE__ */ A({
37
37
  context: Object,
@@ -70,78 +70,77 @@ const L = { class: "dpiV3_innerRapModalWrapper" }, O = { class: "dpiV3_innerRapM
70
70
  emits: ["update:modelValue"],
71
71
  setup(I, { expose: W }) {
72
72
  R([]), z().appContext.app.config.globalProperties.$env;
73
- const { formValues: he } = D(), e = H(I, "modelValue"), b = (t) => /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(t.trim()), M = (t) => {
73
+ const { formValues: Pe } = D(), e = H(I, "modelValue"), g = (t) => /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(t.trim()), P = (t) => {
74
74
  if (!t || t.trim() === "")
75
75
  return !0;
76
- const r = t.replace(/[\s\-().]/g, "");
77
- if (!/^[+]?\d+$/.test(r))
76
+ const a = t.replace(/[\s\-().]/g, "");
77
+ if (!/^[+]?\d+$/.test(a))
78
78
  return !1;
79
- const a = r.replace(/\D/g, "");
80
- return a.length >= 6 && a.length <= 15;
81
- }, E = (t) => !t || !t.trim() ? !1 : t.trim().length >= 2, f = (t) => {
79
+ const r = a.replace(/\D/g, "");
80
+ return r.length >= 6 && r.length <= 15;
81
+ }, v = (t) => !t || !t.trim() ? !1 : t.trim().length >= 2, f = (t) => {
82
82
  try {
83
- const r = t.trim(), a = r.startsWith("http://") || r.startsWith("https://") ? r : `https://${r}`;
84
- return new URL(a), !0;
83
+ const a = t.trim(), r = a.startsWith("http://") || a.startsWith("https://") ? a : `https://${a}`;
84
+ return new URL(r), !0;
85
85
  } catch {
86
86
  return !1;
87
87
  }
88
- }, g = (t) => !t || !t.trim() ? !1 : /[a-zA-Z0-9]/.test(t.trim()), v = (t) => t && t.trim().length > 0, i = (t, r) => {
88
+ }, b = (t) => !t || !t.trim() ? !1 : /[a-zA-Z0-9]/.test(t.trim()), E = (t) => t && t.trim().length > 0, i = (t, a) => {
89
89
  switch (t) {
90
90
  case "title":
91
- return g(r) ? (e.value.showErrorTitle = !1, e.value.titleErrorMessage = "", !0) : (e.value.showErrorTitle = !0, e.value.titleErrorMessage = "Bitte geben Sie einen Titel ein, bevor Sie fortfahren.", !1);
91
+ return b(a) ? (e.value.showErrorTitle = !1, e.value.titleErrorMessage = "", !0) : (e.value.showErrorTitle = !0, e.value.titleErrorMessage = "Bitte geben Sie einen Titel ein, bevor Sie fortfahren.", !1);
92
92
  case "description":
93
- return v(r) ? (e.value.showErrorDescription = !1, e.value.descriptionErrorMessage = "", !0) : (e.value.showErrorDescription = !0, e.value.descriptionErrorMessage = "Bitte geben Sie eine Beschreibung ein, bevor Sie fortfahren.", !1);
94
- case "publisherMail":
95
- return r && r.trim() && !b(r) ? (e.value.showErrorPublisherMail = !0, e.value.publisherMailErrorMessage = "Bitte geben Sie eine gültige E-Mail-Adresse ein.", !1) : (e.value.showErrorPublisherMail = !1, e.value.publisherMailErrorMessage = "", !0);
96
- case "publisherWebsite":
97
- return r && r.trim() && !f(r) ? (e.value.showErrorPublisherWebsite = !0, e.value.publisherWebsiteErrorMessage = "Bitte geben Sie eine gültige URL ein.", !1) : (e.value.showErrorPublisherWebsite = !1, e.value.publisherWebsiteErrorMessage = "", !0);
93
+ return E(a) ? (e.value.showErrorDescription = !1, e.value.descriptionErrorMessage = "", !0) : (e.value.showErrorDescription = !0, e.value.descriptionErrorMessage = "Bitte geben Sie eine Beschreibung ein, bevor Sie fortfahren.", !1);
98
94
  case "publisherName":
99
- return g(r) ? (e.value.showErrorPublisherName = !1, e.value.publisherNameErrorMessage = "", !0) : (e.value.showErrorPublisherName = !0, e.value.publisherNameErrorMessage = "Publisher-Name ist erforderlich und muss mindestens ein alphanumerisches Zeichen enthalten.", !1);
95
+ return b(a) ? (e.value.showErrorPublisherName = !1, e.value.publisherNameErrorMessage = "", !0) : (e.value.showErrorPublisherName = !0, e.value.publisherNameErrorMessage = "Bitte geben Sie einen gültigen Organisationsnamen ein.", !1);
100
96
  case "publisherMail":
101
- return r && r.trim() && !b(r) ? (e.value.showErrorPublisherMail = !0, e.value.publisherMailErrorMessage = "Ungültige E-Mail-Adresse.", !1) : (e.value.showErrorPublisherMail = !1, e.value.publisherMailErrorMessage = "", !0);
97
+ return !a || !a.trim() || !g(a) ? (e.value.showErrorPublisherMail = !0, e.value.publisherMailErrorMessage = "Bitte geben Sie eine gültige E-Mail-Adresse ein.", !1) : (e.value.showErrorPublisherMail = !1, e.value.publisherMailErrorMessage = "", !0);
102
98
  case "publisherWebsite":
103
- return r && r.trim() && !f(r) ? (e.value.showErrorPublisherWebsite = !0, e.value.publisherWebsiteErrorMessage = "Ungültige Website-URL.", !1) : (e.value.showErrorPublisherWebsite = !1, e.value.publisherWebsiteErrorMessage = "", !0);
99
+ return !a || !a.trim() || !f(a) ? (e.value.showErrorPublisherWebsite = !0, e.value.publisherWebsiteErrorMessage = "Bitte geben Sie eine gültige URL ein.", !1) : (e.value.showErrorPublisherWebsite = !1, e.value.publisherWebsiteErrorMessage = "", !0);
104
100
  case "contactPointName":
105
- return E(r) ? (e.value.showErrorContactPointName = !1, e.value.contactPointNameErrorMessage = "", !0) : (e.value.showErrorContactPointName = !0, e.value.contactPointNameErrorMessage = "Bitte geben Sie einen gültigen Namen ein (mindestens 2 Zeichen).", !1);
101
+ return v(a) ? (e.value.showErrorContactPointName = !1, e.value.contactPointNameErrorMessage = "", !0) : (e.value.showErrorContactPointName = !0, e.value.contactPointNameErrorMessage = "Bitte geben Sie einen gültigen Namen ein (mindestens 2 Zeichen).", !1);
106
102
  case "contactPointMail":
107
- return r && r.trim() && !b(r) ? (e.value.showErrorContactPointMail = !0, e.value.contactPointMailErrorMessage = "Bitte geben Sie eine gültige E-Mail-Adresse ein.", !1) : (e.value.showErrorContactPointMail = !1, e.value.contactPointMailErrorMessage = "", !0);
103
+ return !a || !a.trim() || !g(a) ? (e.value.showErrorContactPointMail = !0, e.value.contactPointMailErrorMessage = "Bitte geben Sie eine gültige E-Mail-Adresse ein.", !1) : (e.value.showErrorContactPointMail = !1, e.value.contactPointMailErrorMessage = "", !0);
108
104
  case "contactPointPhone":
109
- return r && r.trim() && !M(r) ? (e.value.showErrorContactPointPhone = !0, e.value.contactPointPhoneErrorMessage = "Bitte geben Sie eine gültige Telefonnummer ein.", !1) : (e.value.showErrorContactPointPhone = !1, e.value.contactPointPhoneErrorMessage = "", !0);
105
+ return a && a.trim() && !P(a) ? (e.value.showErrorContactPointPhone = !0, e.value.contactPointPhoneErrorMessage = "Bitte geben Sie eine gültige Telefonnummer ein.", !1) : (e.value.showErrorContactPointPhone = !1, e.value.contactPointPhoneErrorMessage = "", !0);
110
106
  default:
111
107
  return !0;
112
108
  }
113
- }, C = N(() => {
114
- var P, w, V, _;
115
- const t = g(e.value.title), r = v(e.value.description), a = g(e.value.publisherName), y = !((P = e.value.publisherMail) != null && P.trim()) || b(e.value.publisherMail), B = !((w = e.value.publisherWebsite) != null && w.trim()) || f(e.value.publisherWebsite), S = E(e.value.contactPointName), U = !((V = e.value.contactPointMail) != null && V.trim()) || b(e.value.contactPointMail), k = !((_ = e.value.contactPointPhone) != null && _.trim()) || M(e.value.contactPointPhone);
116
- return t && r && a && y && B && S && U && k;
109
+ }, S = N(() => {
110
+ var M, w, _, V;
111
+ const t = b(e.value.title), a = E(e.value.description), r = b(e.value.publisherName), $ = ((M = e.value.publisherMail) == null ? void 0 : M.trim()) && g(e.value.publisherMail), y = ((w = e.value.publisherWebsite) == null ? void 0 : w.trim()) && f(e.value.publisherWebsite), B = v(e.value.contactPointName), U = ((_ = e.value.contactPointMail) == null ? void 0 : _.trim()) && g(e.value.contactPointMail), k = !((V = e.value.contactPointPhone) != null && V.trim()) || P(e.value.contactPointPhone);
112
+ return t && a && r && $ && y && B && U && k;
117
113
  });
118
114
  o(() => e.value.title, (t) => i("title", t)), o(() => e.value.description, (t) => i("description", t)), o(() => e.value.publisherName, (t) => i("publisherName", t)), o(() => e.value.publisherMail, (t) => i("publisherMail", t)), o(() => e.value.publisherWebsite, (t) => i("publisherWebsite", t)), o(() => e.value.contactPointMail, (t) => i("contactPointMail", t)), o(() => e.value.contactPointName, (t) => i("contactPointName", t)), o(() => e.value.contactPointMail, (t) => i("contactPointMail", t)), o(() => e.value.contactPointPhone, (t) => i("contactPointPhone", t));
119
- const T = N(() => ({
120
- title: !g(e.value.title),
121
- description: !v(e.value.description),
122
- publisherName: !g(e.value.publisherName),
123
- publisherMail: e.value.publisherMail && e.value.publisherMail.trim() && !b(e.value.publisherMail),
124
- publisherWebsite: e.value.publisherWebsite && e.value.publisherWebsite.trim() && !f(e.value.publisherWebsite),
125
- contactPointName: !E(e.value.contactPointName),
126
- // Now always validated
127
- contactPointMail: e.value.contactPointMail && e.value.contactPointMail.trim() && !b(e.value.contactPointMail)
128
- })), $ = () => {
115
+ const C = N(() => {
116
+ var t, a, r;
117
+ return {
118
+ title: !b(e.value.title),
119
+ description: !E(e.value.description),
120
+ publisherName: !b(e.value.publisherName),
121
+ publisherMail: !((t = e.value.publisherMail) != null && t.trim()) || !g(e.value.publisherMail),
122
+ publisherWebsite: !((a = e.value.publisherWebsite) != null && a.trim()) || !f(e.value.publisherWebsite),
123
+ contactPointName: !v(e.value.contactPointName),
124
+ // Now always validated
125
+ contactPointMail: !((r = e.value.contactPointMail) != null && r.trim()) || !g(e.value.contactPointMail)
126
+ };
127
+ }), T = () => {
129
128
  const t = [];
130
129
  return e.value.showErrorTitle && t.push(e.value.titleErrorMessage), e.value.showErrorDescription && t.push(e.value.descriptionErrorMessage), e.value.showErrorPublisherName && t.push(e.value.publisherNameErrorMessage), e.value.showErrorPublisherMail && t.push(e.value.publisherMailErrorMessage), e.value.showErrorPublisherWebsite && t.push(e.value.publisherWebsiteErrorMessage), e.value.showErrorContactPointName && t.push(e.value.contactPointNameErrorMessage), e.value.showErrorContactPointMail && t.push(e.value.contactPointMailErrorMessage), e.value.showErrorContactPointPhone && t.push(e.value.contactPointPhoneErrorMessage), t.length > 0 ? t : ["Bitte füllen Sie alle erforderlichen Felder korrekt aus."];
131
130
  };
132
131
  return o(() => e.value, () => {
133
132
  }, { deep: !0 }), W({
134
- isValid: C,
135
- validationErrors: T,
136
- getValidationErrorMessages: $,
133
+ isValid: S,
134
+ validationErrors: C,
135
+ getValidationErrorMessages: T,
137
136
  validateField: i
138
- }), (t, r) => (c(), u("div", L, [
139
- l("div", O, [
140
- s(p, {
137
+ }), (t, a) => (c(), u("div", O, [
138
+ s("div", L, [
139
+ l(h, {
141
140
  class: "",
142
141
  label: t.$t("message.metadata.title"),
143
142
  modelValue: e.value.title,
144
- "onUpdate:modelValue": r[0] || (r[0] = (a) => e.value.title = a),
143
+ "onUpdate:modelValue": a[0] || (a[0] = (r) => e.value.title = r),
145
144
  placeholder: "",
146
145
  infoIcon: !1,
147
146
  preIcon: !1,
@@ -150,171 +149,187 @@ const L = { class: "dpiV3_innerRapModalWrapper" }, O = { class: "dpiV3_innerRapM
150
149
  showError: e.value.showErrorTitle
151
150
  }, null, 8, ["label", "modelValue", "showError"]),
152
151
  e.value.showErrorTitle && e.value.titleErrorMessage ? (c(), u("div", Z, [
153
- s(h(m), {
152
+ l(p(m), {
154
153
  size: 16,
155
154
  weight: "fill"
156
155
  }),
157
- l("span", j, n(e.value.titleErrorMessage), 1)
156
+ s("span", j, n(e.value.titleErrorMessage), 1)
158
157
  ])) : d("", !0),
159
- s(x, {
160
- class: "",
161
- label: t.$t("message.metadata.description"),
162
- modelValue: e.value.description,
163
- "onUpdate:modelValue": r[1] || (r[1] = (a) => e.value.description = a)
164
- }, null, 8, ["label", "modelValue"]),
165
- e.value.showErrorDescription && e.value.descriptionErrorMessage ? (c(), u("div", q, [
166
- s(h(m), {
167
- size: 16,
168
- weight: "fill"
169
- }),
170
- l("span", G, n(e.value.descriptionErrorMessage), 1)
171
- ])) : d("", !0),
172
- s(p, {
173
- label: t.$t("message.dataupload.datasets.rap.essentials.modifiedHeader"),
174
- infoIcon: !1,
175
- preIcon: !1,
176
- datePicker: !0,
177
- showEndIcon: !1,
178
- modelValue: e.value.modified,
179
- "onUpdate:modelValue": r[2] || (r[2] = (a) => e.value.modified = a),
180
- defaultInput: !0,
181
- inputType: "date",
182
- initialHintText: !1
183
- }, null, 8, ["label", "modelValue"])
158
+ s("div", q, [
159
+ l(x, {
160
+ class: "",
161
+ label: t.$t("message.metadata.description"),
162
+ modelValue: e.value.description,
163
+ "onUpdate:modelValue": a[1] || (a[1] = (r) => e.value.description = r)
164
+ }, null, 8, ["label", "modelValue"]),
165
+ e.value.showErrorDescription && e.value.descriptionErrorMessage ? (c(), u("div", G, [
166
+ l(p(m), {
167
+ size: 16,
168
+ weight: "fill"
169
+ }),
170
+ s("span", J, n(e.value.descriptionErrorMessage), 1)
171
+ ])) : d("", !0)
172
+ ]),
173
+ s("div", K, [
174
+ l(h, {
175
+ label: t.$t("message.dataupload.datasets.rap.essentials.modifiedHeader"),
176
+ infoIcon: !1,
177
+ preIcon: !1,
178
+ datePicker: !0,
179
+ showEndIcon: !1,
180
+ modelValue: e.value.modified,
181
+ "onUpdate:modelValue": a[2] || (a[2] = (r) => e.value.modified = r),
182
+ defaultInput: !0,
183
+ inputType: "date",
184
+ initialHintText: !1
185
+ }, null, 8, ["label", "modelValue"])
186
+ ])
184
187
  ]),
185
- l("div", J, [
186
- l("h5", K, n(t.$t("message.metadata.publisher")), 1),
187
- s(p, {
188
- label: t.$t("message.dataupload.datasets.dct:publisher.nameInput.title"),
189
- infoIcon: !1,
190
- preIcon: !1,
191
- placeholder: t.$t("message.dataupload.datasets.dct:publisher.nameInput.placeholder"),
192
- initialHintText: !1,
193
- showEndIcon: !1,
194
- class: "",
195
- modelValue: e.value.publisherName,
196
- "onUpdate:modelValue": r[3] || (r[3] = (a) => e.value.publisherName = a),
197
- showError: e.value.showErrorPublisherName,
198
- error_message: "Bitte geben Sie einen gültigen Organisationsnamen ein."
199
- }, null, 8, ["label", "placeholder", "modelValue", "showError"]),
200
- e.value.showErrorPublisherName && e.value.publisherNameErrorMessage ? (c(), u("div", Q, [
201
- s(h(m), {
202
- size: 16,
203
- weight: "fill"
204
- }),
205
- l("span", X, n(e.value.publisherNameErrorMessage), 1)
206
- ])) : d("", !0),
207
- s(p, {
208
- label: t.$t("message.dataupload.datasets.dct:publisher.mailInput.title"),
209
- placeholder: t.$t("message.dataupload.datasets.dct:publisher.mailInput.placeholder"),
210
- infoIcon: !1,
211
- preIcon: !1,
212
- initialHintText: !1,
213
- showEndIcon: !1,
214
- class: "",
215
- modelValue: e.value.publisherMail,
216
- "onUpdate:modelValue": r[4] || (r[4] = (a) => e.value.publisherMail = a),
217
- showError: e.value.showErrorPublisherMail,
218
- error_message: "Bitte geben Sie eine gültige E-Mail-Adresse ein."
219
- }, null, 8, ["label", "placeholder", "modelValue", "showError"]),
220
- e.value.showErrorPublisherMail && e.value.publisherMailErrorMessage ? (c(), u("div", Y, [
221
- s(h(m), {
222
- size: 16,
223
- weight: "fill"
224
- }),
225
- l("span", ee, n(e.value.publisherMailErrorMessage), 1)
226
- ])) : d("", !0),
227
- s(p, {
228
- label: t.$t("message.dataupload.datasets.dct:publisher.websiteInput.title"),
229
- placeholder: t.$t("message.dataupload.datasets.dct:publisher.websiteInput.placeholder"),
230
- infoIcon: !1,
231
- preIcon: !1,
232
- initialHintText: !1,
233
- showEndIcon: !1,
234
- modelValue: e.value.publisherWebsite,
235
- "onUpdate:modelValue": r[5] || (r[5] = (a) => e.value.publisherWebsite = a),
236
- showError: e.value.showErrorPublisherWebsite,
237
- error_message: "Bitte geben Sie eine gültige URL ein."
238
- }, null, 8, ["label", "placeholder", "modelValue", "showError"]),
239
- e.value.showErrorPublisherWebsite && e.value.publisherWebsiteErrorMessage ? (c(), u("div", te, [
240
- s(h(m), {
241
- size: 16,
242
- weight: "fill"
243
- }),
244
- l("span", re, n(e.value.publisherWebsiteErrorMessage), 1)
245
- ])) : d("", !0)
188
+ s("div", Q, [
189
+ s("h5", X, n(t.$t("message.metadata.publisher")), 1),
190
+ s("div", Y, [
191
+ l(h, {
192
+ label: t.$t("message.dataupload.datasets.dct:publisher.nameInput.title"),
193
+ infoIcon: !1,
194
+ preIcon: !1,
195
+ placeholder: t.$t("message.dataupload.datasets.dct:publisher.nameInput.placeholder"),
196
+ initialHintText: !1,
197
+ showEndIcon: !1,
198
+ class: "",
199
+ modelValue: e.value.publisherName,
200
+ "onUpdate:modelValue": a[3] || (a[3] = (r) => e.value.publisherName = r),
201
+ showError: e.value.showErrorPublisherName,
202
+ error_message: "Bitte geben Sie einen gültigen Organisationsnamen ein."
203
+ }, null, 8, ["label", "placeholder", "modelValue", "showError"]),
204
+ e.value.showErrorPublisherName && e.value.publisherNameErrorMessage ? (c(), u("div", ee, [
205
+ l(p(m), {
206
+ size: 16,
207
+ weight: "fill"
208
+ }),
209
+ s("span", te, n(e.value.publisherNameErrorMessage), 1)
210
+ ])) : d("", !0)
211
+ ]),
212
+ s("div", ae, [
213
+ l(h, {
214
+ label: t.$t("message.dataupload.datasets.dct:publisher.mailInput.title"),
215
+ placeholder: t.$t("message.dataupload.datasets.dct:publisher.mailInput.placeholder"),
216
+ infoIcon: !1,
217
+ preIcon: !1,
218
+ initialHintText: !1,
219
+ showEndIcon: !1,
220
+ class: "",
221
+ modelValue: e.value.publisherMail,
222
+ "onUpdate:modelValue": a[4] || (a[4] = (r) => e.value.publisherMail = r),
223
+ showError: e.value.showErrorPublisherMail,
224
+ error_message: "Bitte geben Sie eine gültige E-Mail-Adresse ein."
225
+ }, null, 8, ["label", "placeholder", "modelValue", "showError"]),
226
+ e.value.showErrorPublisherMail && e.value.publisherMailErrorMessage ? (c(), u("div", re, [
227
+ l(p(m), {
228
+ size: 16,
229
+ weight: "fill"
230
+ }),
231
+ s("span", se, n(e.value.publisherMailErrorMessage), 1)
232
+ ])) : d("", !0)
233
+ ]),
234
+ s("div", le, [
235
+ l(h, {
236
+ label: t.$t("message.dataupload.datasets.dct:publisher.websiteInput.title"),
237
+ placeholder: t.$t("message.dataupload.datasets.dct:publisher.websiteInput.placeholder"),
238
+ infoIcon: !1,
239
+ preIcon: !1,
240
+ initialHintText: !1,
241
+ showEndIcon: !1,
242
+ modelValue: e.value.publisherWebsite,
243
+ "onUpdate:modelValue": a[5] || (a[5] = (r) => e.value.publisherWebsite = r),
244
+ showError: e.value.showErrorPublisherWebsite,
245
+ error_message: "Bitte geben Sie eine gültige URL ein."
246
+ }, null, 8, ["label", "placeholder", "modelValue", "showError"]),
247
+ e.value.showErrorPublisherWebsite && e.value.publisherWebsiteErrorMessage ? (c(), u("div", ie, [
248
+ l(p(m), {
249
+ size: 16,
250
+ weight: "fill"
251
+ }),
252
+ s("span", oe, n(e.value.publisherWebsiteErrorMessage), 1)
253
+ ])) : d("", !0)
254
+ ])
246
255
  ]),
247
- l("div", ae, [
248
- l("h5", se, n(t.$t("message.header.subnav.contact")), 1),
249
- s(p, {
250
- modelValue: e.value.contactPointName,
251
- "onUpdate:modelValue": r[6] || (r[6] = (a) => e.value.contactPointName = a),
252
- label: t.$t("message.dataupload.datasets.dcat:contactPoint.nameInput.title"),
253
- placeholder: t.$t(
254
- "message.dataupload.datasets.dcat:contactPoint.nameInput.placeholder"
255
- ),
256
- infoIcon: !1,
257
- preIcon: !1,
258
- initialHintText: !1,
259
- showEndIcon: !1,
260
- class: "",
261
- showError: e.value.showErrorContactPointName,
262
- error_message: "Bitte geben Sie einen gültigen Namen ein (mindestens 2 Zeichen)."
263
- }, null, 8, ["modelValue", "label", "placeholder", "showError"]),
264
- e.value.showErrorContactPointName && e.value.contactPointNameErrorMessage ? (c(), u("div", le, [
265
- s(h(m), {
266
- size: 16,
267
- weight: "fill"
268
- }),
269
- l("span", ie, n(e.value.contactPointNameErrorMessage), 1)
270
- ])) : d("", !0),
271
- s(p, {
272
- label: t.$t("message.dataupload.datasets.dcat:contactPoint.mailInput.title"),
273
- infoIcon: !1,
274
- preIcon: !1,
275
- initialHintText: !1,
276
- placeholder: t.$t(
277
- "message.dataupload.datasets.dcat:contactPoint.mailInput.placeholder"
278
- ),
279
- showEndIcon: !1,
280
- class: "",
281
- modelValue: e.value.contactPointMail,
282
- "onUpdate:modelValue": r[7] || (r[7] = (a) => e.value.contactPointMail = a),
283
- showError: e.value.showErrorContactPointMail,
284
- error_message: "Bitte geben Sie eine gültige E-Mail-Adresse ein."
285
- }, null, 8, ["label", "placeholder", "modelValue", "showError"]),
286
- e.value.showErrorContactPointMail && e.value.contactPointMailErrorMessage ? (c(), u("div", oe, [
287
- s(h(m), {
288
- size: 16,
289
- weight: "fill"
290
- }),
291
- l("span", ne, n(e.value.contactPointMailErrorMessage), 1)
292
- ])) : d("", !0),
293
- s(p, {
294
- label: t.$t("message.dataupload.datasets.dcat:contactPoint.telInput.title"),
295
- infoIcon: !1,
296
- placeholder: t.$t(
297
- "message.dataupload.datasets.dcat:contactPoint.telInput.placeholder"
298
- ),
299
- preIcon: !1,
300
- initialHintText: !1,
301
- showEndIcon: !1,
302
- modelValue: e.value.contactPointPhone,
303
- "onUpdate:modelValue": r[8] || (r[8] = (a) => e.value.contactPointPhone = a),
304
- showError: e.value.showErrorContactPointPhone,
305
- error_message: "Bitte geben Sie eine gültige Telefonnummer ein."
306
- }, null, 8, ["label", "placeholder", "modelValue", "showError"]),
307
- e.value.showErrorContactPointPhone && e.value.contactPointPhoneErrorMessage ? (c(), u("div", ue, [
308
- s(h(m), {
309
- size: 16,
310
- weight: "fill"
311
- }),
312
- l("span", ce, n(e.value.contactPointPhoneErrorMessage), 1)
313
- ])) : d("", !0)
256
+ s("div", ne, [
257
+ s("h5", ue, n(t.$t("message.header.subnav.contact")), 1),
258
+ s("div", ce, [
259
+ l(h, {
260
+ modelValue: e.value.contactPointName,
261
+ "onUpdate:modelValue": a[6] || (a[6] = (r) => e.value.contactPointName = r),
262
+ label: t.$t("message.dataupload.datasets.dcat:contactPoint.nameInput.title"),
263
+ placeholder: t.$t(
264
+ "message.dataupload.datasets.dcat:contactPoint.nameInput.placeholder"
265
+ ),
266
+ infoIcon: !1,
267
+ preIcon: !1,
268
+ initialHintText: !1,
269
+ showEndIcon: !1,
270
+ class: "",
271
+ showError: e.value.showErrorContactPointName,
272
+ error_message: "Bitte geben Sie einen gültigen Namen ein (mindestens 2 Zeichen)."
273
+ }, null, 8, ["modelValue", "label", "placeholder", "showError"]),
274
+ e.value.showErrorContactPointName && e.value.contactPointNameErrorMessage ? (c(), u("div", de, [
275
+ l(p(m), {
276
+ size: 16,
277
+ weight: "fill"
278
+ }),
279
+ s("span", pe, n(e.value.contactPointNameErrorMessage), 1)
280
+ ])) : d("", !0)
281
+ ]),
282
+ s("div", he, [
283
+ l(h, {
284
+ label: t.$t("message.dataupload.datasets.dcat:contactPoint.mailInput.title"),
285
+ infoIcon: !1,
286
+ preIcon: !1,
287
+ initialHintText: !1,
288
+ placeholder: t.$t(
289
+ "message.dataupload.datasets.dcat:contactPoint.mailInput.placeholder"
290
+ ),
291
+ showEndIcon: !1,
292
+ class: "",
293
+ modelValue: e.value.contactPointMail,
294
+ "onUpdate:modelValue": a[7] || (a[7] = (r) => e.value.contactPointMail = r),
295
+ showError: e.value.showErrorContactPointMail,
296
+ error_message: "Bitte geben Sie eine gültige E-Mail-Adresse ein."
297
+ }, null, 8, ["label", "placeholder", "modelValue", "showError"]),
298
+ e.value.showErrorContactPointMail && e.value.contactPointMailErrorMessage ? (c(), u("div", me, [
299
+ l(p(m), {
300
+ size: 16,
301
+ weight: "fill"
302
+ }),
303
+ s("span", ge, n(e.value.contactPointMailErrorMessage), 1)
304
+ ])) : d("", !0)
305
+ ]),
306
+ s("div", be, [
307
+ l(h, {
308
+ label: t.$t("message.dataupload.datasets.dcat:contactPoint.telInput.title"),
309
+ infoIcon: !1,
310
+ placeholder: t.$t(
311
+ "message.dataupload.datasets.dcat:contactPoint.telInput.placeholder"
312
+ ),
313
+ preIcon: !1,
314
+ initialHintText: !1,
315
+ showEndIcon: !1,
316
+ modelValue: e.value.contactPointPhone,
317
+ "onUpdate:modelValue": a[8] || (a[8] = (r) => e.value.contactPointPhone = r),
318
+ showError: e.value.showErrorContactPointPhone,
319
+ error_message: "Bitte geben Sie eine gültige Telefonnummer ein."
320
+ }, null, 8, ["label", "placeholder", "modelValue", "showError"]),
321
+ e.value.showErrorContactPointPhone && e.value.contactPointPhoneErrorMessage ? (c(), u("div", ve, [
322
+ l(p(m), {
323
+ size: 16,
324
+ weight: "fill"
325
+ }),
326
+ s("span", fe, n(e.value.contactPointPhoneErrorMessage), 1)
327
+ ])) : d("", !0)
328
+ ])
314
329
  ])
315
330
  ]));
316
331
  }
317
- }, we = /* @__PURE__ */ F(de, [["__scopeId", "data-v-de07dd77"]]);
332
+ }, Te = /* @__PURE__ */ F(Ee, [["__scopeId", "data-v-8225049b"]]);
318
333
  export {
319
- we as default
334
+ Te as default
320
335
  };
@@ -1,4 +1,4 @@
1
- import { ref as u, computed as S, watch as q, createElementBlock as F, openBlock as c, Fragment as O, createElementVNode as d, createBlock as g, createCommentVNode as b, withKeys as v, normalizeClass as P, withModifiers as m, unref as s, toDisplayString as W, isRef as _ } from "vue";
1
+ import { ref as u, computed as S, watch as q, createElementBlock as F, openBlock as c, Fragment as O, createElementVNode as d, createBlock as g, createCommentVNode as D, withKeys as v, normalizeClass as P, withModifiers as m, unref as s, toDisplayString as W, isRef as _ } from "vue";
2
2
  import R from "./StateTag.vue.js";
3
3
  import G from "./Dropdown.vue.js";
4
4
  import Q from "./ModalSimpleV3.vue.js";
@@ -31,17 +31,17 @@ const se = { class: "dpiV3_tableRowInner" }, oe = { class: "dpiV3_TableRowDescCo
31
31
  dataset: Object
32
32
  },
33
33
  setup(C) {
34
- const D = Y();
34
+ const b = Y();
35
35
  Z();
36
36
  let o = u(!1), r = u(!1), f = u(!1), l = u({}), i = u({}), w = u({ edit: { fromDraft: !1 } });
37
37
  B() && (w = B());
38
- const $ = ae(), k = S(() => D.getters["auth/getUserData"]), M = S(() => k.value && k.value.rtpToken), t = C, { toEditMode: A } = ee(), I = () => {
38
+ const $ = ae(), k = S(() => b.getters["auth/getUserData"]), M = S(() => k.value && k.value.rtpToken), t = C, { toEditMode: A } = ee(), I = () => {
39
39
  const n = t.draft, e = t.catalogue, a = t.id || t.dataset.id || t.catalogue.id;
40
40
  A({ id: a, catalogId: e, isDraft: n, locale: "de" });
41
41
  }, E = (n, e, a, h) => {
42
- console.log(t.dataset), D.dispatch("auth/putDatasetToDraft", { id: n, catalog: e, title: a, description: h });
42
+ console.log(t.dataset), b.dispatch("auth/putDatasetToDraft", { id: n, catalog: e, title: a, description: h });
43
43
  }, K = async (n, e) => {
44
- await D.dispatch("auth/publishUserDraftById", { id: n, catalog: e });
44
+ await b.dispatch("auth/publishUserDraftById", { id: n, catalog: e });
45
45
  }, y = async (n, e) => {
46
46
  const a = n || t.dataset && t.dataset.id || t.catalogue && t.catalogue.id, h = e || t.catalogue, H = $.api.hubUrl, J = !!t.draft ? `drafts/datasets/${a}?catalogue=${h}` : `datasets/${a}?useNormalizedId=true&catalogue=${h}`, j = `${H}${J}`;
47
47
  await te.delete(j, {
@@ -195,7 +195,7 @@ const se = { class: "dpiV3_tableRowInner" }, oe = { class: "dpiV3_TableRowDescCo
195
195
  ])
196
196
  ], 32),
197
197
  d("div", ie, [
198
- s(w).edit.fromDraft ? b("", !0) : (c(), g(G, {
198
+ s(w).edit.enabled ? D("", !0) : (c(), g(G, {
199
199
  key: 0,
200
200
  onClick: x,
201
201
  type: "moreButton",
@@ -217,7 +217,7 @@ const se = { class: "dpiV3_tableRowInner" }, oe = { class: "dpiV3_TableRowDescCo
217
217
  onClose: e[7] || (e[7] = (a) => _(o) ? o.value = !1 : o = !1),
218
218
  action: s(l).action,
219
219
  onActionHandling: e[8] || (e[8] = (a) => U(a))
220
- }, null, 8, ["buttons", "headerText", "text", "action"])) : b("", !0),
220
+ }, null, 8, ["buttons", "headerText", "text", "action"])) : D("", !0),
221
221
  s(r) ? (c(), g(X, {
222
222
  key: 1,
223
223
  type: s(i).type,
@@ -227,10 +227,10 @@ const se = { class: "dpiV3_tableRowInner" }, oe = { class: "dpiV3_TableRowDescCo
227
227
  action: s(i).action,
228
228
  onMouseenter: e[9] || (e[9] = (a) => _(f) ? f.value = !0 : f = !0),
229
229
  onMouseleave: L
230
- }, null, 8, ["type", "text", "button", "action"])) : b("", !0)
230
+ }, null, 8, ["type", "text", "button", "action"])) : D("", !0)
231
231
  ], 64));
232
232
  }
233
- }, Ve = /* @__PURE__ */ ne(ue, [["__scopeId", "data-v-faa1fe1c"]]);
233
+ }, Ve = /* @__PURE__ */ ne(ue, [["__scopeId", "data-v-9539571e"]]);
234
234
  export {
235
235
  Ve as default
236
236
  };