@piveau/piveau-hub-ui-modules 4.2.1 → 4.3.0-beta.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.
- package/dist/data-provider-interface/components/AutocompleteInput.vue.mjs +98 -98
- package/dist/data-provider-interface/components/AutocompleteInput.vue.mjs.map +1 -1
- package/dist/data-provider-interface/components/ConditionalInput.vue.mjs +135 -129
- package/dist/data-provider-interface/components/ConditionalInput.vue.mjs.map +1 -1
- package/dist/data-provider-interface/components/DistributionStepper.vue.mjs +60 -60
- package/dist/data-provider-interface/components/DistributionStepper.vue.mjs.map +1 -1
- package/dist/data-provider-interface/components/FileUpload.vue.mjs +2 -2
- package/dist/data-provider-interface/components/FileUpload.vue.mjs.map +1 -1
- package/dist/data-provider-interface/components/SimpleInput.vue.mjs +16 -20
- package/dist/data-provider-interface/components/SimpleInput.vue.mjs.map +1 -1
- package/dist/data-provider-interface/components/SimpleSelect.vue.mjs +31 -31
- package/dist/data-provider-interface/components/SimpleSelect.vue.mjs.map +1 -1
- package/dist/data-provider-interface/components/SpatialInput.vue.mjs +90 -94
- package/dist/data-provider-interface/components/SpatialInput.vue.mjs.map +1 -1
- package/dist/data-provider-interface/components/SpatialInput.vue2.mjs +2 -2
- package/dist/data-provider-interface/components/UniqueIdentifierInput.vue.mjs +41 -30
- package/dist/data-provider-interface/components/UniqueIdentifierInput.vue.mjs.map +1 -1
- package/dist/data-provider-interface/config/dcatapde/input-definition.mjs +19 -39
- package/dist/data-provider-interface/config/dcatapde/input-definition.mjs.map +1 -1
- package/dist/data-provider-interface/views/DistributionInputPage.vue.mjs +52 -52
- package/dist/data-provider-interface/views/DistributionInputPage.vue.mjs.map +1 -1
- package/dist/data-provider-interface/views/InputPage.vue.mjs +67 -67
- package/dist/data-provider-interface/views/InputPage.vue.mjs.map +1 -1
- package/dist/form/Repeatable.vue.mjs +18 -18
- package/dist/form/Repeatable.vue.mjs.map +1 -1
- package/dist/piveau-hub-ui-modules.css +1 -1
- package/package.json +1 -1
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import { ref as h, resolveComponent as
|
|
2
|
-
import
|
|
3
|
-
import { onClickOutside as
|
|
4
|
-
import { useRuntimeEnv as
|
|
1
|
+
import { ref as h, watchEffect as A, resolveComponent as L, openBlock as n, createElementBlock as a, createElementVNode as t, toDisplayString as f, createTextVNode as i, unref as r, createCommentVNode as d, withDirectives as V, isRef as D, vModelText as E, Fragment as g, renderList as x, createVNode as _, createBlock as P, createStaticVNode as T } from "vue";
|
|
2
|
+
import U from "./AutocompleteInput.vue.mjs";
|
|
3
|
+
import { onClickOutside as B } from "../../external/@vueuse/core/index";
|
|
4
|
+
import { useRuntimeEnv as N } from "../../composables/useRuntimeEnv.mjs";
|
|
5
|
+
import { useI18n as $ } from "vue-i18n";
|
|
5
6
|
import "./ConditionalInput.vue2.mjs";
|
|
6
|
-
const
|
|
7
|
+
const F = { class: "formkitProperty" }, j = { class: "formkitHeader" }, O = {
|
|
7
8
|
key: 0,
|
|
8
9
|
class: "d-flex infoLicense py-5"
|
|
9
|
-
},
|
|
10
|
+
}, R = /* @__PURE__ */ t("svg", {
|
|
10
11
|
xmlns: "http://www.w3.org/2000/svg",
|
|
11
12
|
width: "30px",
|
|
12
13
|
height: "30px",
|
|
@@ -14,33 +15,21 @@ const E = { class: "formkitProperty" }, P = { class: "formkitHeader" }, S = {
|
|
|
14
15
|
class: "bi bi-info-circle mx-3 mb-3 mt-1 infoboxI",
|
|
15
16
|
viewBox: "0 0 16 16"
|
|
16
17
|
}, [
|
|
17
|
-
/* @__PURE__ */
|
|
18
|
-
/* @__PURE__ */
|
|
19
|
-
/* @__PURE__ */
|
|
20
|
-
], -1),
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
/* @__PURE__ */ o(` by which Creative Commons Attribution
|
|
30
|
-
4.0 International Public License (CC BY 4.0) is adopted as an open licence for the Commission’s reuse policy.
|
|
31
|
-
Additionally, raw data, metadata or other documents of comparable nature may alternatively be distributed under
|
|
32
|
-
the provisions of the Creative Commons Universal Public Domain Dedication deed (CC0 1.0).
|
|
33
|
-
`),
|
|
34
|
-
/* @__PURE__ */ e("br"),
|
|
35
|
-
/* @__PURE__ */ e("br"),
|
|
36
|
-
/* @__PURE__ */ o(`
|
|
37
|
-
The Council and the European Court of Auditors have approved similar decisions on reuse. It is advisable that
|
|
38
|
-
you check the reuse policy of your organisation before publishing or submitting your dataset.
|
|
39
|
-
`)
|
|
40
|
-
], -1), j = {
|
|
18
|
+
/* @__PURE__ */ t("path", { d: "M8 15A7 7 0 1 1 8 1a7 7 0 0 1 0 14m0 1A8 8 0 1 0 8 0a8 8 0 0 0 0 16" }),
|
|
19
|
+
/* @__PURE__ */ i(),
|
|
20
|
+
/* @__PURE__ */ t("path", { d: "m8.93 6.588-2.29.287-.082.38.45.083c.294.07.352.176.288.469l-.738 3.468c-.194.897.105 1.319.808 1.319.545 0 1.178-.252 1.465-.598l.088-.416c-.2.176-.492.246-.686.246-.275 0-.375-.193-.304-.533zM9 4.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0" })
|
|
21
|
+
], -1), X = /* @__PURE__ */ T(`<div class="w-80"><p><em>For <strong>European</strong> <strong>Commission's datasets</strong>, bear in mind
|
|
22
|
+
that <ins>Decision 2011/833/EU</ins> <a href="https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX:32011D0833]" target="_blank" rel="nofollow noopener">[link</a> ] allows for their commercial reuse without prior authorisation,
|
|
23
|
+
except for the material subject to the third party intellectual property rights. This Decision has been
|
|
24
|
+
implemented under the <ins>Decision C(2019) 1655 final</ins> <a href="https://ec.europa.eu/transparency/documents-register/detail?ref=C(2019)1655&lang=en]" target="_blank" rel="nofollow noopener">[link</a> ] by which Creative Commons Attribution 4.0
|
|
25
|
+
International Public License (CC BY 4.0) is adopted as an open licence for the Commission's reuse policy.
|
|
26
|
+
Additionally, raw data, metadata or other documents of comparable nature may alternatively be distributed
|
|
27
|
+
under the provisions of the Creative Commons Universal Public Domain Dedication deed (CC0 1.0).</em></p> <p><em>The <strong>Council</strong> and the <strong>European Court of Auditors</strong> have
|
|
28
|
+
approved similar decisions on reuse. It is advisable that you check <strong>the reuse policy of your
|
|
29
|
+
organisation</strong> before publishing or submitting your dataset.</em></p> <p>If you need further information regarding copyright issues, please contact us at <a href="mailto:op-copyright@publications.europa.eu" target="_blank" rel="nofollow noopener">op-copyright@publications.europa.eu</a></p></div>`, 1), z = {
|
|
41
30
|
key: 1,
|
|
42
31
|
class: "d-flex infoLicense py-5"
|
|
43
|
-
},
|
|
32
|
+
}, K = /* @__PURE__ */ t("svg", {
|
|
44
33
|
xmlns: "http://www.w3.org/2000/svg",
|
|
45
34
|
width: "30px",
|
|
46
35
|
height: "30px",
|
|
@@ -48,161 +37,178 @@ const E = { class: "formkitProperty" }, P = { class: "formkitHeader" }, S = {
|
|
|
48
37
|
class: "bi bi-info-circle mx-3 mb-3 mt-1 infoboxI",
|
|
49
38
|
viewBox: "0 0 16 16"
|
|
50
39
|
}, [
|
|
51
|
-
/* @__PURE__ */
|
|
52
|
-
/* @__PURE__ */
|
|
53
|
-
/* @__PURE__ */
|
|
54
|
-
], -1),
|
|
55
|
-
/* @__PURE__ */
|
|
40
|
+
/* @__PURE__ */ t("path", { d: "M8 15A7 7 0 1 1 8 1a7 7 0 0 1 0 14m0 1A8 8 0 1 0 8 0a8 8 0 0 0 0 16" }),
|
|
41
|
+
/* @__PURE__ */ i(),
|
|
42
|
+
/* @__PURE__ */ t("path", { d: "m8.93 6.588-2.29.287-.082.38.45.083c.294.07.352.176.288.469l-.738 3.468c-.194.897.105 1.319.808 1.319.545 0 1.178-.252 1.465-.598l.088-.416c-.2.176-.492.246-.686.246-.275 0-.375-.193-.304-.533zM9 4.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0" })
|
|
43
|
+
], -1), W = /* @__PURE__ */ t("p", { class: "textInfoI" }, [
|
|
44
|
+
/* @__PURE__ */ i(`As owner of your dataset, you guarantee that it does not violate the copyright, other
|
|
56
45
|
intellectual property or
|
|
57
46
|
privacy rights of any third party. In particular, if third party material is included in the dataset, you must
|
|
58
47
|
ensure that all necessary permissions have been obtained and appropriate acknowledgment is given, if necessary.
|
|
59
48
|
`),
|
|
60
|
-
/* @__PURE__ */
|
|
61
|
-
/* @__PURE__ */
|
|
62
|
-
/* @__PURE__ */
|
|
49
|
+
/* @__PURE__ */ t("br"),
|
|
50
|
+
/* @__PURE__ */ t("br"),
|
|
51
|
+
/* @__PURE__ */ i(`
|
|
63
52
|
If you need further information regarding copyright issues, please contact us at
|
|
64
53
|
`),
|
|
65
|
-
/* @__PURE__ */
|
|
66
|
-
], -1),
|
|
54
|
+
/* @__PURE__ */ t("a", { href: "mailto:op-copyright@publications.europa.eu" }, "op-copyright@publications.europa.eu")
|
|
55
|
+
], -1), H = {
|
|
67
56
|
key: 2,
|
|
68
57
|
class: "formkitCmpWrap simpleConditional"
|
|
69
|
-
},
|
|
58
|
+
}, Y = { class: "m-3" }, q = { class: "conditionalSelectDiv" }, G = { key: 0 }, J = { class: "selectListConditional" }, Q = { class: "conditionalManual" }, Z = {
|
|
70
59
|
key: 0,
|
|
71
60
|
class: "d-flex"
|
|
72
|
-
},
|
|
61
|
+
}, ee = { key: 0 }, te = {
|
|
73
62
|
key: 3,
|
|
74
63
|
class: "formkitCmpWrap simpleConditional"
|
|
75
|
-
},
|
|
64
|
+
}, oe = { class: "m-3" }, ne = { class: "conditionalSelectDiv" }, ae = ["placeholder"], ie = { key: 0 }, se = { class: "selectListConditional" }, le = ["onClick"], re = { class: "conditionalManual" }, de = {
|
|
76
65
|
key: 0,
|
|
77
66
|
class: "d-flex"
|
|
78
|
-
}, ne = {
|
|
79
|
-
key: 0,
|
|
80
|
-
class: "conditionalVocabulary"
|
|
81
67
|
}, ce = {
|
|
68
|
+
key: 0,
|
|
69
|
+
class: ""
|
|
70
|
+
}, ue = {
|
|
71
|
+
key: 1,
|
|
72
|
+
class: "conditionalVocabulary d-flex"
|
|
73
|
+
}, pe = { class: "autocompleteInputSingleValue" }, xe = {
|
|
82
74
|
__name: "ConditionalInput",
|
|
83
75
|
props: {
|
|
84
76
|
context: Object
|
|
85
77
|
},
|
|
86
|
-
setup(
|
|
87
|
-
let
|
|
88
|
-
const t =
|
|
89
|
-
let
|
|
90
|
-
|
|
78
|
+
setup(M) {
|
|
79
|
+
let b = N();
|
|
80
|
+
const e = M, { t: k } = $();
|
|
81
|
+
let l = h(), u = h(!1), p = h(!1);
|
|
82
|
+
A(() => {
|
|
83
|
+
e.context.value.name && (l.value = k("message.dataupload.datasets.conditional.vocabulary")), e.context.value["foaf:name"] && (l.value = k("message.dataupload.datasets.conditional.manually"));
|
|
84
|
+
});
|
|
85
|
+
const v = h(null), C = (c) => {
|
|
91
86
|
p.value = !p.value;
|
|
92
|
-
},
|
|
93
|
-
|
|
87
|
+
}, S = () => {
|
|
88
|
+
e.context.node.reset();
|
|
89
|
+
}, w = (c, s) => {
|
|
90
|
+
l.value = s, u.value = c, e.context.node.reset(), e.context.value = "";
|
|
94
91
|
};
|
|
95
|
-
return
|
|
96
|
-
const
|
|
97
|
-
return
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
])) :
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
])) :
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
92
|
+
return B(v, (c) => p.value = !1), (c, s) => {
|
|
93
|
+
const y = L("FormKit");
|
|
94
|
+
return n(), a("div", F, [
|
|
95
|
+
t("h4", j, f(c.$t("message.dataupload.datasets." + e.context.attrs.identifier + ".label")), 1),
|
|
96
|
+
i(),
|
|
97
|
+
e.context.attrs.identifier === "licence" && r(b).content.dataProviderInterface.annifIntegration ? (n(), a("div", O, [
|
|
98
|
+
R,
|
|
99
|
+
i(),
|
|
100
|
+
X
|
|
101
|
+
])) : d("", !0),
|
|
102
|
+
i(),
|
|
103
|
+
e.context.attrs.identifier === "rights" && r(b).content.dataProviderInterface.annifIntegration ? (n(), a("div", z, [
|
|
104
|
+
K,
|
|
105
|
+
i(),
|
|
106
|
+
W
|
|
107
|
+
])) : d("", !0),
|
|
108
|
+
i(),
|
|
109
|
+
e.context.attrs.identifier === "rights" ? (n(), a("div", H, [
|
|
110
|
+
t("div", Y, [
|
|
111
|
+
t("div", q, [
|
|
112
|
+
V(t("input", {
|
|
116
113
|
ref_key: "I1",
|
|
117
|
-
ref:
|
|
114
|
+
ref: v,
|
|
118
115
|
type: "text",
|
|
119
116
|
class: "conditionalSelect formkit-input formkit-inner",
|
|
120
|
-
onClick:
|
|
117
|
+
onClick: s[0] || (s[0] = (o) => C()),
|
|
121
118
|
placeholder: "Choose input method",
|
|
122
|
-
"onUpdate:modelValue":
|
|
119
|
+
"onUpdate:modelValue": s[1] || (s[1] = (o) => D(l) ? l.value = o : l = o)
|
|
123
120
|
}, null, 512), [
|
|
124
|
-
[
|
|
121
|
+
[E, r(l)]
|
|
125
122
|
]),
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
(
|
|
123
|
+
i(),
|
|
124
|
+
r(p) ? (n(), a("div", G, [
|
|
125
|
+
t("ul", J, [
|
|
126
|
+
(n(!0), a(g, null, x(e.context.attrs.selection, (o, m) => (n(), a("li", {
|
|
130
127
|
class: "p-2 border-b border-gray-200",
|
|
131
|
-
onClick:
|
|
132
|
-
},
|
|
128
|
+
onClick: s[2] || (s[2] = (I) => w(I))
|
|
129
|
+
}, f(o), 1))), 256))
|
|
133
130
|
])
|
|
134
|
-
])) :
|
|
131
|
+
])) : d("", !0)
|
|
135
132
|
]),
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
_(
|
|
133
|
+
i(),
|
|
134
|
+
t("div", Q, [
|
|
135
|
+
r(u) === "url" || e.context.node.value["@type"] === "url" ? (n(), a("div", Z, [
|
|
136
|
+
_(y, {
|
|
140
137
|
type: "url",
|
|
141
138
|
placeholder: "Please provide a valid URL",
|
|
142
139
|
name: "rdfs:label",
|
|
143
140
|
validation: "url",
|
|
144
141
|
class: "w-100",
|
|
145
142
|
identifier: "rightsUrl",
|
|
146
|
-
modelValue:
|
|
147
|
-
"onUpdate:modelValue":
|
|
143
|
+
modelValue: e.context.value["rdfs:value"],
|
|
144
|
+
"onUpdate:modelValue": s[3] || (s[3] = (o) => e.context.value["rdfs:value"] = o)
|
|
148
145
|
}, null, 8, ["modelValue"])
|
|
149
|
-
])) :
|
|
146
|
+
])) : d("", !0)
|
|
150
147
|
]),
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
_(
|
|
148
|
+
i(),
|
|
149
|
+
r(u) === "text" || e.context.value["@type"] === "text" ? (n(), a("div", ee, [
|
|
150
|
+
_(y, {
|
|
154
151
|
type: "text",
|
|
155
152
|
placeholder: "Please provide a Text",
|
|
156
153
|
name: "rdfs:label",
|
|
157
154
|
class: "w-100",
|
|
158
155
|
identifier: "rightsText",
|
|
159
|
-
modelValue:
|
|
160
|
-
"onUpdate:modelValue":
|
|
156
|
+
modelValue: e.context.value["rdfs:value"],
|
|
157
|
+
"onUpdate:modelValue": s[4] || (s[4] = (o) => e.context.value["rdfs:value"] = o)
|
|
161
158
|
}, null, 8, ["modelValue"])
|
|
162
|
-
])) :
|
|
159
|
+
])) : d("", !0)
|
|
163
160
|
])
|
|
164
|
-
])) : (
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
161
|
+
])) : (n(), a("div", te, [
|
|
162
|
+
t("div", oe, [
|
|
163
|
+
t("div", ne, [
|
|
164
|
+
V(t("input", {
|
|
168
165
|
ref_key: "I1",
|
|
169
|
-
ref:
|
|
166
|
+
ref: v,
|
|
170
167
|
type: "text",
|
|
171
168
|
class: "conditionalSelect formkit-input formkit-inner",
|
|
172
|
-
onClick:
|
|
173
|
-
placeholder:
|
|
174
|
-
"onUpdate:modelValue":
|
|
175
|
-
}, null,
|
|
176
|
-
[
|
|
169
|
+
onClick: s[5] || (s[5] = (o) => C()),
|
|
170
|
+
placeholder: e.context.attrs.placeholder,
|
|
171
|
+
"onUpdate:modelValue": s[6] || (s[6] = (o) => D(l) ? l.value = o : l = o)
|
|
172
|
+
}, null, 8, ae), [
|
|
173
|
+
[E, r(l)]
|
|
177
174
|
]),
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
(
|
|
175
|
+
i(),
|
|
176
|
+
r(p) ? (n(), a("div", ie, [
|
|
177
|
+
t("ul", se, [
|
|
178
|
+
(n(!0), a(g, null, x(e.context.attrs.selection, (o, m) => (n(), a("li", {
|
|
182
179
|
class: "p-2 border-b border-gray-200",
|
|
183
|
-
onClick:
|
|
184
|
-
},
|
|
180
|
+
onClick: (I) => w(o, c.$t("message.dataupload.datasets.conditional." + o))
|
|
181
|
+
}, f(c.$t("message.dataupload.datasets.conditional." + o)), 9, le))), 256))
|
|
185
182
|
])
|
|
186
|
-
])) :
|
|
183
|
+
])) : d("", !0)
|
|
187
184
|
]),
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
(
|
|
185
|
+
i(),
|
|
186
|
+
t("div", re, [
|
|
187
|
+
r(u) === "manually" || Object.keys(e.context.value).length > 0 && e.context.value["foaf:name"] && r(u) != "vocabulary" ? (n(), a("div", de, [
|
|
188
|
+
(n(!0), a(g, null, x(e.context.attrs.options, (o, m) => (n(), P(y, {
|
|
192
189
|
type: m,
|
|
193
|
-
placeholder:
|
|
194
|
-
name:
|
|
190
|
+
placeholder: c.$t("message.dataupload.datasets.individual." + o),
|
|
191
|
+
name: o,
|
|
195
192
|
validation: m,
|
|
196
193
|
class: "w-100"
|
|
197
194
|
}, null, 8, ["type", "placeholder", "name", "validation"]))), 256))
|
|
198
|
-
])) :
|
|
195
|
+
])) : d("", !0)
|
|
199
196
|
]),
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
_(
|
|
203
|
-
context:
|
|
197
|
+
i(),
|
|
198
|
+
r(u) === "vocabulary" && !e.context.value.name ? (n(), a("div", ce, [
|
|
199
|
+
_(U, {
|
|
200
|
+
context: e.context
|
|
204
201
|
}, null, 8, ["context"])
|
|
205
|
-
])) :
|
|
202
|
+
])) : d("", !0),
|
|
203
|
+
i(),
|
|
204
|
+
e.context.value.name ? (n(), a("div", ue, [
|
|
205
|
+
t("a", pe, f(e.context.value.name), 1),
|
|
206
|
+
i(),
|
|
207
|
+
t("div", {
|
|
208
|
+
class: "removeX",
|
|
209
|
+
onClick: S
|
|
210
|
+
})
|
|
211
|
+
])) : d("", !0)
|
|
206
212
|
])
|
|
207
213
|
]))
|
|
208
214
|
]);
|
|
@@ -210,6 +216,6 @@ const E = { class: "formkitProperty" }, P = { class: "formkitHeader" }, S = {
|
|
|
210
216
|
}
|
|
211
217
|
};
|
|
212
218
|
export {
|
|
213
|
-
|
|
219
|
+
xe as default
|
|
214
220
|
};
|
|
215
221
|
//# sourceMappingURL=ConditionalInput.vue.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ConditionalInput.vue.mjs","sources":["../../../lib/data-provider-interface/components/ConditionalInput.vue"],"sourcesContent":["<template>\n <div class=\"formkitProperty\">\n <h4 class=\"formkitHeader\">{{ props.context.attrs.identifier.charAt(0).toUpperCase() +\n props.context.attrs.identifier.slice(1) }}</h4>\n <div v-if=\"props.context.attrs.identifier === 'licence' && env.content.dataProviderInterface.annifIntegration\"\n class=\"d-flex infoLicense py-5\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"30px\" height=\"30px\" fill=\"currentColor\"\n class=\"bi bi-info-circle mx-3 mb-3 mt-1 infoboxI \" viewBox=\"0 0 16 16\">\n <path d=\"M8 15A7 7 0 1 1 8 1a7 7 0 0 1 0 14m0 1A8 8 0 1 0 8 0a8 8 0 0 0 0 16\" />\n <path\n d=\"m8.93 6.588-2.29.287-.082.38.45.083c.294.07.352.176.288.469l-.738 3.468c-.194.897.105 1.319.808 1.319.545 0 1.178-.252 1.465-.598l.088-.416c-.2.176-.492.246-.686.246-.275 0-.375-.193-.304-.533zM9 4.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0\" />\n </svg>\n <p class=\"textInfoI\">For European Commission’s datasets, bear in mind that Decision <a\n href=\"https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX:32011D0833\">2011/833/EU</a> allows for their\n commercial reuse\n without prior authorisation, except for the material subject to the third party intellectual property rights.\n This Decision has been implemented under the <a\n href=\"https://ec.europa.eu/transparency/documents-register/detail?ref=C(2019)1655&lang=en\">Decision C(2019)\n 1655 final</a> by which Creative Commons Attribution\n 4.0 International Public License (CC BY 4.0) is adopted as an open licence for the Commission’s reuse policy.\n Additionally, raw data, metadata or other documents of comparable nature may alternatively be distributed under\n the provisions of the Creative Commons Universal Public Domain Dedication deed (CC0 1.0).\n <br><br>\n The Council and the European Court of Auditors have approved similar decisions on reuse. It is advisable that\n you check the reuse policy of your organisation before publishing or submitting your dataset.\n </p>\n </div>\n <div v-if=\"props.context.attrs.identifier === 'rights' && env.content.dataProviderInterface.annifIntegration\"\n class=\"d-flex infoLicense py-5\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"30px\" height=\"30px\" fill=\"currentColor\"\n class=\"bi bi-info-circle mx-3 mb-3 mt-1 infoboxI\" viewBox=\"0 0 16 16\">\n <path d=\"M8 15A7 7 0 1 1 8 1a7 7 0 0 1 0 14m0 1A8 8 0 1 0 8 0a8 8 0 0 0 0 16\" />\n <path\n d=\"m8.93 6.588-2.29.287-.082.38.45.083c.294.07.352.176.288.469l-.738 3.468c-.194.897.105 1.319.808 1.319.545 0 1.178-.252 1.465-.598l.088-.416c-.2.176-.492.246-.686.246-.275 0-.375-.193-.304-.533zM9 4.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0\" />\n </svg>\n <p class=\"textInfoI\">As owner of your dataset, you guarantee that it does not violate the copyright, other\n intellectual property or\n privacy rights of any third party. In particular, if third party material is included in the dataset, you must\n ensure that all necessary permissions have been obtained and appropriate acknowledgment is given, if necessary.\n <br><br>\n If you need further information regarding copyright issues, please contact us at\n <a href=\"mailto:op-copyright@publications.europa.eu\">op-copyright@publications.europa.eu</a>\n </p>\n </div>\n <!-- Choice between text and URL -->\n <div class=\"formkitCmpWrap simpleConditional\" v-if=\"props.context.attrs.identifier === 'rights'\">\n <div class=\"m-3\">\n <div class=\"conditionalSelectDiv\">\n <input ref=\"I1\" type=\"text\" class=\"conditionalSelect formkit-input formkit-inner\" @click=\"openSelect($event)\"\n placeholder=\"Choose input method\" v-model=\"selectModeVal\">\n <div v-if=\"showSelect\">\n <ul class=\"selectListConditional\">\n <li v-for=\"el, index in props.context.attrs.selection\" class=\"p-2 border-b border-gray-200 \"\n @click=\"selectMode($event)\">{{ el }}</li>\n </ul>\n </div>\n </div>\n <div class=\"conditionalManual\">\n <div class=\"d-flex\" v-if=\"selectedItem === 'url' || props.context.node.value['@type'] === 'url'\">\n <FormKit type=\"url\" placeholder=\"Please provide a valid URL\" name=\"rdfs:label\" validation=\"url\"\n class=\"w-100\" identifier=\"rightsUrl\" v-model=\"props.context.value['rdfs:value']\"></FormKit>\n </div>\n </div>\n <div v-if=\"selectedItem === 'text' || props.context.value['@type'] === 'text'\">\n <FormKit type=\"text\" placeholder=\"Please provide a Text\" name=\"rdfs:label\" class=\"w-100\"\n identifier=\"rightsText\" v-model=\"props.context.value['rdfs:value']\"></FormKit>\n </div>\n </div>\n </div>\n\n <!-- Choice between manualinput and vocabulary search -->\n <div class=\"formkitCmpWrap simpleConditional\" v-else>\n <div class=\"m-3\">\n <div class=\"conditionalSelectDiv\">\n <input ref=\"I1\" type=\"text\" class=\"conditionalSelect formkit-input formkit-inner\" @click=\"openSelect($event)\"\n placeholder=\"Choose input method\" v-model=\"selectModeVal\">\n <div v-if=\"showSelect\">\n <ul class=\"selectListConditional\">\n <li v-for=\"el, index in props.context.attrs.selection\" class=\"p-2 border-b border-gray-200 \"\n @click=\"selectMode($event)\">{{ el }}</li>\n </ul>\n </div>\n </div>\n <div class=\"conditionalManual\">\n <div class=\"d-flex\" v-if=\"selectedItem === 'manually' ||\n Object.keys(props.context.value).length > 0 && props.context.value['foaf:name']\n && selectedItem != 'vocabulary'\">\n <FormKit v-for=\"el, key in props.context.attrs.options\" :type=\"key\" :placeholder=\"key\" :name=\"el\"\n :validation=\"key\" class=\"w-100\"></FormKit>\n </div>\n </div>\n <div v-if=\"selectedItem === 'vocabulary' || Object.keys(props.context.value).length > 0\n && props.context.value.name && selectedItem != 'manually'\" class=\"conditionalVocabulary\">\n <AutocompleteInput :context=\"props.context\"></AutocompleteInput>\n </div>\n\n\n </div>\n\n </div>\n </div>\n\n</template>\n<script setup>\nimport { ref } from 'vue';\nimport AutocompleteInput from './AutocompleteInput.vue';\nimport { onClickOutside } from '@vueuse/core'\nimport { useRuntimeEnv } from \"../../composables/useRuntimeEnv.ts\";\n\nlet env = useRuntimeEnv()\nconst props = defineProps({\n context: Object,\n})\nlet selectModeVal = ref()\nlet selectedItem = ref(false)\nlet showSelect = ref(false)\n\n\nconst I1 = ref(null)\n\nconst openSelect = (e) => {\n\n showSelect.value = !showSelect.value\n\n}\nconst selectMode = (e) => {\n\n console.log(e.target.innerHTML);\n \n selectModeVal.value = e.target.innerHTML\n\n if (e.target.innerHTML === 'manually'|| e.target.innerHTML === 'manually') { selectedItem.value = \"manually\" }\n if (e.target.innerHTML === 'Vocabulary' || e.target.innerHTML === 'vocabulary') { selectedItem.value = \"vocabulary\" }\n if (e.target.innerHTML === 'URL' ||e.target.innerHTML === 'url') { selectedItem.value = \"url\" }\n if (e.target.innerHTML === 'Text' || e.target.innerHTML === 'text') { selectedItem.value = \"text\" }\n\n props.context.node.reset()\n props.context.value = \"\"\n}\n\nonClickOutside(I1, event => showSelect.value = false)\n\n</script>\n<style>\n.conditionalManual {\n .formkit-outer {\n width: 100%;\n }\n}\n\n.infoLicense {\n a {\n color: blue;\n }\n\n padding: 1rem;\n background-color: rgb(171, 225, 165)\n}\n\n.infoboxI {\n width: 5%;\n}\n\n.textInfoI {\n width: 95%;\n}\n</style>"],"names":["env","useRuntimeEnv","props","__props","selectModeVal","ref","selectedItem","showSelect","I1","openSelect","e","selectMode","onClickOutside","event"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA6GA,QAAIA,IAAMC,EAAe;AACzB,UAAMC,IAAQC;AAGd,QAAIC,IAAgBC,EAAK,GACrBC,IAAeD,EAAI,EAAK,GACxBE,IAAaF,EAAI,EAAK;AAG1B,UAAMG,IAAKH,EAAI,IAAI,GAEbI,IAAa,CAACC,MAAM;AAExB,MAAAH,EAAW,QAAQ,CAACA,EAAW;AAAA,IAEjC,GACMI,IAAa,CAACD,MAAM;AAExB,cAAQ,IAAIA,EAAE,OAAO,SAAS,GAE9BN,EAAc,QAAQM,EAAE,OAAO,YAE3BA,EAAE,OAAO,cAAc,cAAaA,EAAE,OAAO,cAAc,gBAAcJ,EAAa,QAAQ,cAC9FI,EAAE,OAAO,cAAc,gBAAgBA,EAAE,OAAO,cAAc,kBAAgBJ,EAAa,QAAQ,gBACnGI,EAAE,OAAO,cAAc,SAAQA,EAAE,OAAO,cAAc,WAASJ,EAAa,QAAQ,SACpFI,EAAE,OAAO,cAAc,UAAUA,EAAE,OAAO,cAAc,YAAUJ,EAAa,QAAQ,SAE3FJ,EAAM,QAAQ,KAAK,MAAO,GAC1BA,EAAM,QAAQ,QAAQ;AAAA,IACxB;AAEA,WAAAU,EAAeJ,GAAI,CAAAK,MAASN,EAAW,QAAQ,EAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"ConditionalInput.vue.mjs","sources":["../../../lib/data-provider-interface/components/ConditionalInput.vue"],"sourcesContent":["<template>\n <div class=\"formkitProperty\">\n <!-- <h4 class=\"formkitHeader\">{{ props.context.attrs.identifier.charAt(0).toUpperCase() +\n props.context.attrs.identifier.slice(1) }}</h4> -->\n <h4 class=\"formkitHeader\">\n {{ $t('message.dataupload.datasets.' + props.context.attrs.identifier + '.label') }}\n </h4>\n <div v-if=\"props.context.attrs.identifier === 'licence' && env.content.dataProviderInterface.annifIntegration\"\n class=\"d-flex infoLicense py-5\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"30px\" height=\"30px\" fill=\"currentColor\"\n class=\"bi bi-info-circle mx-3 mb-3 mt-1 infoboxI \" viewBox=\"0 0 16 16\">\n <path d=\"M8 15A7 7 0 1 1 8 1a7 7 0 0 1 0 14m0 1A8 8 0 1 0 8 0a8 8 0 0 0 0 16\" />\n <path\n d=\"m8.93 6.588-2.29.287-.082.38.45.083c.294.07.352.176.288.469l-.738 3.468c-.194.897.105 1.319.808 1.319.545 0 1.178-.252 1.465-.598l.088-.416c-.2.176-.492.246-.686.246-.275 0-.375-.193-.304-.533zM9 4.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0\" />\n </svg>\n <div class=\"w-80\">\n <p><em>For <strong>European</strong> <strong>Commission's datasets</strong>, bear in mind\n that <ins>Decision 2011/833/EU</ins> <a\n href=\"https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX:32011D0833]\" target=\"_blank\"\n rel=\"nofollow noopener\">[link</a> ] allows for their commercial reuse without prior authorisation,\n except for the material subject to the third party intellectual property rights. This Decision has been\n implemented under the <ins>Decision C(2019) 1655 final</ins> <a\n href=\"https://ec.europa.eu/transparency/documents-register/detail?ref=C(2019)1655&lang=en]\"\n target=\"_blank\" rel=\"nofollow noopener\">[link</a> ] by which Creative Commons Attribution 4.0\n International Public License (CC BY 4.0) is adopted as an open licence for the Commission's reuse policy.\n Additionally, raw data, metadata or other documents of comparable nature may alternatively be distributed\n under the provisions of the Creative Commons Universal Public Domain Dedication deed (CC0 1.0).</em></p>\n <p><em>The <strong>Council</strong> and the <strong>European Court of Auditors</strong> have\n approved similar decisions on reuse. It is advisable that you check <strong>the reuse policy of your\n organisation</strong> before publishing or submitting your dataset.</em></p>\n <p>If you need further information regarding copyright issues, please contact us at <a\n href=\"mailto:op-copyright@publications.europa.eu\" target=\"_blank\"\n rel=\"nofollow noopener\">op-copyright@publications.europa.eu</a></p>\n </div>\n\n\n </div>\n <div v-if=\"props.context.attrs.identifier === 'rights' && env.content.dataProviderInterface.annifIntegration\"\n class=\"d-flex infoLicense py-5\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"30px\" height=\"30px\" fill=\"currentColor\"\n class=\"bi bi-info-circle mx-3 mb-3 mt-1 infoboxI\" viewBox=\"0 0 16 16\">\n <path d=\"M8 15A7 7 0 1 1 8 1a7 7 0 0 1 0 14m0 1A8 8 0 1 0 8 0a8 8 0 0 0 0 16\" />\n <path\n d=\"m8.93 6.588-2.29.287-.082.38.45.083c.294.07.352.176.288.469l-.738 3.468c-.194.897.105 1.319.808 1.319.545 0 1.178-.252 1.465-.598l.088-.416c-.2.176-.492.246-.686.246-.275 0-.375-.193-.304-.533zM9 4.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0\" />\n </svg>\n <p class=\"textInfoI\">As owner of your dataset, you guarantee that it does not violate the copyright, other\n intellectual property or\n privacy rights of any third party. In particular, if third party material is included in the dataset, you must\n ensure that all necessary permissions have been obtained and appropriate acknowledgment is given, if necessary.\n <br><br>\n If you need further information regarding copyright issues, please contact us at\n <a href=\"mailto:op-copyright@publications.europa.eu\">op-copyright@publications.europa.eu</a>\n </p>\n </div>\n <!-- Choice between text and URL -->\n <div class=\"formkitCmpWrap simpleConditional\" v-if=\"props.context.attrs.identifier === 'rights'\">\n <div class=\"m-3\">\n <div class=\"conditionalSelectDiv\">\n <input ref=\"I1\" type=\"text\" class=\"conditionalSelect formkit-input formkit-inner\" @click=\"openSelect($event)\"\n placeholder=\"Choose input method\" v-model=\"selectModeVal\">\n <div v-if=\"showSelect\">\n <ul class=\"selectListConditional\">\n <li v-for=\"el, index in props.context.attrs.selection\" class=\"p-2 border-b border-gray-200 \"\n @click=\"selectMode($event)\">{{ el }}</li>\n </ul>\n </div>\n </div>\n <div class=\"conditionalManual\">\n <div class=\"d-flex\" v-if=\"selectedItem === 'url' || props.context.node.value['@type'] === 'url'\">\n <FormKit type=\"url\" placeholder=\"Please provide a valid URL\" name=\"rdfs:label\" validation=\"url\"\n class=\"w-100\" identifier=\"rightsUrl\" v-model=\"props.context.value['rdfs:value']\"></FormKit>\n </div>\n </div>\n <div v-if=\"selectedItem === 'text' || props.context.value['@type'] === 'text'\">\n <FormKit type=\"text\" placeholder=\"Please provide a Text\" name=\"rdfs:label\" class=\"w-100\"\n identifier=\"rightsText\" v-model=\"props.context.value['rdfs:value']\"></FormKit>\n </div>\n </div>\n </div>\n\n <!-- Choice between manualinput and vocabulary search -->\n <div class=\"formkitCmpWrap simpleConditional\" v-else>\n <div class=\"m-3\">\n <div class=\"conditionalSelectDiv\">\n <input ref=\"I1\" type=\"text\" class=\"conditionalSelect formkit-input formkit-inner\" @click=\"openSelect($event)\"\n :placeholder=props.context.attrs.placeholder v-model=\"selectModeVal\">\n <div v-if=\"showSelect\">\n <ul class=\"selectListConditional\">\n <li v-for=\"el, index in props.context.attrs.selection\" class=\"p-2 border-b border-gray-200 \"\n @click=\"selectMode(el, $t('message.dataupload.datasets.conditional.' + el))\">{{\n $t('message.dataupload.datasets.conditional.' + el) }}</li>\n </ul>\n </div>\n </div>\n <div class=\"conditionalManual\">\n <div class=\"d-flex\" v-if=\"selectedItem === 'manually' ||\n Object.keys(props.context.value).length > 0 && props.context.value['foaf:name']\n && selectedItem != 'vocabulary'\">\n <FormKit v-for=\"el, key in props.context.attrs.options\" :type=\"key\"\n :placeholder=\"$t('message.dataupload.datasets.individual.' + el)\" :name=\"el\" :validation=\"key\"\n class=\"w-100\"></FormKit>\n </div>\n </div>\n <div v-if=\"selectedItem === 'vocabulary' && !props.context.value['name']\" class=\"\">\n <AutocompleteInput :context=\"props.context\"></AutocompleteInput>\n </div>\n <div v-if=\"props.context.value['name']\" class=\"conditionalVocabulary d-flex\">\n <a class=\"autocompleteInputSingleValue\">{{\n props.context.value['name'] }}</a>\n <div class=\"removeX\" @click=\"removeProperty\"></div>\n\n </div>\n\n\n </div>\n\n </div>\n </div>\n\n</template>\n<script setup>\nimport { ref, watchEffect } from 'vue';\nimport AutocompleteInput from './AutocompleteInput.vue';\nimport { onClickOutside } from '@vueuse/core'\nimport { useRuntimeEnv } from \"../../composables/useRuntimeEnv.ts\";\nimport { useI18n } from 'vue-i18n';\n\nlet env = useRuntimeEnv()\nconst props = defineProps({\n context: Object,\n})\nconst { t } = useI18n();\nlet selectModeVal = ref()\nlet selectedItem = ref(false)\nlet showSelect = ref(false)\n\n\n\nwatchEffect(() => {\n if (props.context.value['name']) {\n selectModeVal.value = t('message.dataupload.datasets.conditional.' + 'vocabulary');\n }\n if (props.context.value['foaf:name']) {\n selectModeVal.value = t('message.dataupload.datasets.conditional.' + 'manually');\n }\n});\n\nconst I1 = ref(null)\n\nconst openSelect = (e) => {\n\n showSelect.value = !showSelect.value\n\n}\nconst removeProperty = () => {\n props.context.node.reset()\n}\nconst selectMode = (e, translatedString) => {\n selectModeVal.value = translatedString\n selectedItem.value = e\n props.context.node.reset()\n props.context.value = \"\"\n}\n\nonClickOutside(I1, event => showSelect.value = false)\n\n</script>\n<style>\n.conditionalManual {\n .formkit-outer {\n width: 100%;\n }\n}\n\n.hover {\n text-decoration: underline;\n}\n\n.conditionalVocabulary {\n display: flex;\n align-items: center;\n margin: 1rem 0;\n}\n\n.w-80 {\n width: 80%;\n}\n\n.infoLicense {\n a {\n color: blue;\n }\n\n padding: 1rem;\n background-color: rgb(171, 225, 165)\n}\n\n.infoboxI {\n width: 5%;\n}\n\n.textInfoI {\n width: 95%;\n}\n</style>"],"names":["env","useRuntimeEnv","props","__props","t","useI18n","selectModeVal","ref","selectedItem","showSelect","watchEffect","I1","openSelect","e","removeProperty","selectMode","translatedString","onClickOutside","event"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA+HA,QAAIA,IAAMC,EAAe;AACzB,UAAMC,IAAQC,GAGR,EAAE,GAAAC,EAAC,IAAKC;AACd,QAAIC,IAAgBC,EAAK,GACrBC,IAAeD,EAAI,EAAK,GACxBE,IAAaF,EAAI,EAAK;AAI1B,IAAAG,EAAY,MAAM;AAChB,MAAIR,EAAM,QAAQ,MAAM,SACtBI,EAAc,QAAQF,EAAE,oDAAyD,IAE/EF,EAAM,QAAQ,MAAM,WAAW,MACjCI,EAAc,QAAQF,EAAE,kDAAuD;AAAA,IAEnF,CAAC;AAED,UAAMO,IAAKJ,EAAI,IAAI,GAEbK,IAAa,CAACC,MAAM;AAExB,MAAAJ,EAAW,QAAQ,CAACA,EAAW;AAAA,IAEjC,GACMK,IAAiB,MAAM;AAC3B,MAAAZ,EAAM,QAAQ,KAAK,MAAO;AAAA,IAC5B,GACMa,IAAa,CAACF,GAAGG,MAAqB;AAC1C,MAAAV,EAAc,QAAQU,GACtBR,EAAa,QAAQK,GACrBX,EAAM,QAAQ,KAAK,MAAO,GAC1BA,EAAM,QAAQ,QAAQ;AAAA,IACxB;AAEA,WAAAe,EAAeN,GAAI,CAAAO,MAAST,EAAW,QAAQ,EAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|