@piveau/piveau-hub-ui-modules 4.5.6 → 4.5.7

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.
@@ -0,0 +1,2 @@
1
+ declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
2
+ export default _default;
@@ -0,0 +1,292 @@
1
+ import { ref as r, openBlock as p, createElementBlock as f, createElementVNode as l, createTextVNode as e, toDisplayString as B, unref as s, Fragment as D, renderList as L, normalizeClass as y, createCommentVNode as w, withDirectives as W, vModelText as A, isRef as k } from "vue";
2
+ import { onClickOutside as U } from "../external/@vueuse/core/index";
3
+ import "./CatalogueMQA.vue2.mjs";
4
+ import Z from "../_virtual/_plugin-vue_export-helper.mjs";
5
+ const j = { class: "container mb-3" }, O = { key: 0 }, P = { class: "mqaWrapper" }, G = { class: "mailItems" }, H = ["value", "readonly", "onInput"], J = ["onClick"], K = ["onClick"], X = {
6
+ key: 0,
7
+ class: "errormsg"
8
+ }, Y = { class: "my-3 d-flex" }, h = ["disabled"], _ = {
9
+ key: 1,
10
+ class: "errormsg"
11
+ }, c = { class: "mqaWrapper" }, tt = { class: "d-flex" }, lt = { class: "mr-3 my-3" }, et = ["onClick"], nt = ["disabled"], st = { class: "my-3" }, it = ["disabled"], ot = { class: "caretWrap" }, at = { class: "mqaWrapper" }, ut = { class: "w-50" }, dt = { class: "actionWrapper" }, rt = {
12
+ __name: "CatalogueMQA",
13
+ setup(vt) {
14
+ let a = r(!1), u = r(!1), v = r({ mail: "", valid: !0 }), I = r(null);
15
+ r(!0);
16
+ let x = r("Activate"), g = r(!1), C = r(!1), m = r(), N = ["Mo", "Tue", "We", "Th", "Fr", "Sa", "Su"], o = r(1);
17
+ const M = r(0), R = /^(2[0-8]|[1-9])$/;
18
+ m.value = [{ mail: "mail@mail2.com", readonly: !0, valid: !0 }, { mail: "mail@mail1.com", readonly: !0, valid: !0 }], U(I, (i) => {
19
+ m.value.forEach((t) => {
20
+ t.readonly = !0;
21
+ });
22
+ });
23
+ const q = () => {
24
+ const i = document.getElementsByClassName("dayButtons");
25
+ for (let t = 0; t < i.length; t++)
26
+ i[t].classList.remove("activeItem");
27
+ }, E = (i) => {
28
+ i === "up" && o.value < 28 ? (o.value > 8 && (g.value = !0), o.value++) : o.value > 1 && (o.value < 11 && (g.value = !1), o.value--);
29
+ }, z = (i, t) => {
30
+ t.target.classList.toggle("activeItem");
31
+ }, S = () => {
32
+ R.test(o.value) || (o.value = "28"), o.value > 8 ? g.value = !0 : g.value = !1;
33
+ }, T = () => {
34
+ v.value.mail != "" && (m.value.push({ mail: v.value.mail, readonly: !0, valid: !0 }), v.value = { mail: "", valid: !0 });
35
+ }, V = () => {
36
+ C.value ? (C.value = !1, x.value = "Activate") : (C.value = !0, x.value = "Deactivate");
37
+ }, Q = (i) => {
38
+ m.value.forEach((t) => {
39
+ t.readonly = !0;
40
+ }), i.readonly = !i.readonly;
41
+ }, $ = (i, t) => {
42
+ const n = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/, d = i.target.value;
43
+ n.test(d) || d === "" ? (m.value.forEach((b) => {
44
+ b.mail === t && (b.mail = d, b.valid = !0);
45
+ }), t === void 0 && (v.value.valid = !0)) : (m.value.forEach((b) => {
46
+ b.mail === t && (b.valid = !1);
47
+ }), t === void 0 && (v.value.valid = !1));
48
+ }, F = (i) => {
49
+ let t = -1;
50
+ m.value.forEach((n, d) => {
51
+ n.mail === i && (t = d);
52
+ }), t !== -1 && m.value.splice(t, 1);
53
+ };
54
+ return (i, t) => (p(), f("div", j, [
55
+ l("div", null, [
56
+ t[13] || (t[13] = l("div", null, [
57
+ l("h1", null, "MQA Report Settings"),
58
+ e(),
59
+ l("p", null, "Configuration for"),
60
+ e(),
61
+ l("p", null, [
62
+ e("For this Catalogue the "),
63
+ l("b", null, "MQA Rating Checks "),
64
+ e("are currently "),
65
+ l("b", null, "deactivated"),
66
+ e(".")
67
+ ])
68
+ ], -1)),
69
+ t[14] || (t[14] = e()),
70
+ l("button", {
71
+ type: "button",
72
+ class: "btn btn-secondary",
73
+ onClick: t[0] || (t[0] = (n) => V())
74
+ }, B(s(x)), 1)
75
+ ]),
76
+ t[53] || (t[53] = e()),
77
+ s(C) ? (p(), f("div", O, [
78
+ l("div", P, [
79
+ t[21] || (t[21] = l("h3", null, "Recipients Mail", -1)),
80
+ t[22] || (t[22] = e()),
81
+ t[23] || (t[23] = l("span", null, "Add and edit mail addresses for recieving the MQA report", -1)),
82
+ t[24] || (t[24] = e()),
83
+ s(m).length != 0 ? (p(), f("table", {
84
+ key: 0,
85
+ ref_key: "mailButtonWrap",
86
+ ref: I
87
+ }, [
88
+ t[18] || (t[18] = l("tr", null, [
89
+ l("th", null, "Mail")
90
+ ], -1)),
91
+ t[19] || (t[19] = e()),
92
+ (p(!0), f(D, null, L(s(m), (n) => (p(), f("tr", G, [
93
+ l("td", null, [
94
+ l("input", {
95
+ type: "text",
96
+ value: n.mail,
97
+ readonly: n.readonly,
98
+ class: y({ editable: !n.readonly, invalid: !n.valid }),
99
+ onInput: (d) => $(d, n.mail)
100
+ }, null, 42, H),
101
+ t[16] || (t[16] = e()),
102
+ l("div", null, [
103
+ l("button", {
104
+ type: "button",
105
+ class: "btn btn-secondary",
106
+ onClick: (d) => Q(n)
107
+ }, "Edit", 8, J),
108
+ t[15] || (t[15] = e()),
109
+ l("button", {
110
+ type: "button",
111
+ class: "btn btn-secondary",
112
+ onClick: (d) => F(n.mail)
113
+ }, "Delete", 8, K)
114
+ ])
115
+ ]),
116
+ t[17] || (t[17] = e()),
117
+ n.valid ? w("", !0) : (p(), f("span", X, "*Invalid email format"))
118
+ ]))), 256))
119
+ ], 512)) : w("", !0),
120
+ t[25] || (t[25] = e()),
121
+ l("div", Y, [
122
+ W(l("input", {
123
+ type: "text",
124
+ "onUpdate:modelValue": t[1] || (t[1] = (n) => s(v).mail = n),
125
+ onInput: t[2] || (t[2] = (n) => $(n)),
126
+ class: y({ invalidNewMail: !s(v).valid }),
127
+ style: { padding: "0.25rem" }
128
+ }, null, 34), [
129
+ [A, s(v).mail]
130
+ ]),
131
+ t[20] || (t[20] = e()),
132
+ l("button", {
133
+ type: "button",
134
+ class: "btn btn-secondary mx-3",
135
+ disabled: !s(v).valid,
136
+ onClick: t[3] || (t[3] = (n) => T())
137
+ }, `+
138
+ add Mail`, 8, h)
139
+ ]),
140
+ t[26] || (t[26] = e()),
141
+ s(v).valid ? w("", !0) : (p(), f("span", _, "*Invalid email format"))
142
+ ]),
143
+ t[50] || (t[50] = e()),
144
+ l("div", c, [
145
+ t[36] || (t[36] = l("h3", null, "Frequency of Rating Checks", -1)),
146
+ t[37] || (t[37] = e()),
147
+ t[38] || (t[38] = l("span", null, `Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut
148
+ labore et dolore magna aliquyam erat, sed diam voluptua`, -1)),
149
+ t[39] || (t[39] = e()),
150
+ l("div", tt, [
151
+ l("div", lt, [
152
+ l("button", {
153
+ type: "button",
154
+ class: y(["btn btn-secondary", { activeChoiceButton: s(u) === !0 }]),
155
+ onClick: t[4] || (t[4] = (n) => {
156
+ k(u) ? u.value = !s(u) : u = !s(u), k(a) ? a.value = !1 : a = !1;
157
+ })
158
+ }, "Weekly", 2),
159
+ t[27] || (t[27] = e()),
160
+ l("div", {
161
+ class: y(["weekdays", { blur: !s(u) }])
162
+ }, [
163
+ (p(!0), f(D, null, L(s(N), (n) => (p(), f("span", {
164
+ onClick: (d) => z(n, d)
165
+ }, [
166
+ l("button", {
167
+ disabled: !s(u),
168
+ class: "dayButtons"
169
+ }, B(n), 9, nt)
170
+ ], 8, et))), 256))
171
+ ], 2)
172
+ ]),
173
+ t[35] || (t[35] = e()),
174
+ l("div", st, [
175
+ l("button", {
176
+ type: "button",
177
+ class: y([{ activeChoiceButton: s(a) === !0 }, "btn btn-secondary"]),
178
+ onClick: t[5] || (t[5] = (n) => {
179
+ k(a) ? a.value = !s(a) : a = !s(a), k(u) ? u.value = !1 : u = !1, q();
180
+ })
181
+ }, "Monthly", 2),
182
+ t[34] || (t[34] = e()),
183
+ l("div", {
184
+ class: y(["d-flex daypicker my-3", { blur: !s(a) }])
185
+ }, [
186
+ W(l("input", {
187
+ "onUpdate:modelValue": t[6] || (t[6] = (n) => k(o) ? o.value = n : o = n),
188
+ onInput: t[7] || (t[7] = (n) => S()),
189
+ class: y({ dynamicWidth: s(g) }),
190
+ disabled: !s(a)
191
+ }, null, 42, it), [
192
+ [A, s(o)]
193
+ ]),
194
+ t[31] || (t[31] = e(`.
195
+ `)),
196
+ l("div", ot, [
197
+ l("button", {
198
+ onClick: t[8] || (t[8] = (n) => E("up")),
199
+ class: "caretButtons ml-1"
200
+ }, t[28] || (t[28] = [
201
+ l("svg", {
202
+ xmlns: "http://www.w3.org/2000/svg",
203
+ width: "12",
204
+ height: "12",
205
+ fill: "currentColor",
206
+ class: "bi bi-caret-up-fill",
207
+ viewBox: "0 0 16 16"
208
+ }, [
209
+ l("path", { d: "m7.247 4.86-4.796 5.481c-.566.647-.106 1.659.753 1.659h9.592a1 1 0 0 0 .753-1.659l-4.796-5.48a1 1 0 0 0-1.506 0z" })
210
+ ], -1)
211
+ ])),
212
+ t[30] || (t[30] = e()),
213
+ l("button", {
214
+ onClick: t[9] || (t[9] = (n) => E()),
215
+ class: "caretButtons mr-1"
216
+ }, t[29] || (t[29] = [
217
+ l("svg", {
218
+ xmlns: "http://www.w3.org/2000/svg",
219
+ width: "12",
220
+ height: "12",
221
+ fill: "currentColor",
222
+ class: "bi bi-caret-down-fill",
223
+ viewBox: "0 0 16 16"
224
+ }, [
225
+ l("path", { d: "M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z" })
226
+ ], -1)
227
+ ]))
228
+ ]),
229
+ t[32] || (t[32] = e()),
230
+ t[33] || (t[33] = l("span", null, "day of the month", -1))
231
+ ], 2)
232
+ ])
233
+ ])
234
+ ]),
235
+ t[51] || (t[51] = e()),
236
+ l("div", at, [
237
+ t[45] || (t[45] = l("h3", null, "Notification Treshold", -1)),
238
+ t[46] || (t[46] = e()),
239
+ t[47] || (t[47] = l("span", null, `Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut
240
+ labore et dolore magna aliquyam erat, sed diam voluptua`, -1)),
241
+ t[48] || (t[48] = e()),
242
+ l("div", ut, [
243
+ t[42] || (t[42] = l("div", { class: "d-flex justify-content-between" }, [
244
+ l("span", null, [
245
+ l("b", null, "0")
246
+ ]),
247
+ e(),
248
+ l("span", null, [
249
+ l("b", null, "400")
250
+ ])
251
+ ], -1)),
252
+ t[43] || (t[43] = e()),
253
+ W(l("input", {
254
+ type: "range",
255
+ "onUpdate:modelValue": t[10] || (t[10] = (n) => M.value = n),
256
+ min: "0",
257
+ max: "400"
258
+ }, null, 512), [
259
+ [A, M.value]
260
+ ]),
261
+ t[44] || (t[44] = e()),
262
+ l("p", null, [
263
+ t[40] || (t[40] = e("Lower than ")),
264
+ l("b", null, B(M.value), 1),
265
+ t[41] || (t[41] = e(" Points"))
266
+ ])
267
+ ])
268
+ ]),
269
+ t[52] || (t[52] = e()),
270
+ l("div", dt, [
271
+ l("button", {
272
+ type: "button",
273
+ class: "btn btn-secondary",
274
+ onClick: t[11] || (t[11] = () => {
275
+ })
276
+ }, "Save"),
277
+ t[49] || (t[49] = e()),
278
+ l("button", {
279
+ type: "button",
280
+ class: "btn btn-secondary",
281
+ onClick: t[12] || (t[12] = () => {
282
+ })
283
+ }, "Cancel")
284
+ ])
285
+ ])) : w("", !0)
286
+ ]));
287
+ }
288
+ }, bt = /* @__PURE__ */ Z(rt, [["__scopeId", "data-v-f00ed272"]]);
289
+ export {
290
+ bt as default
291
+ };
292
+ //# sourceMappingURL=CatalogueMQA.vue.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CatalogueMQA.vue.mjs","sources":["../../lib/data-provider-interface/CatalogueMQA.vue"],"sourcesContent":["<template>\n <div class=\"container mb-3\">\n <div>\n <div>\n <h1>MQA Report Settings</h1>\n <p>Configuration for</p>\n <p>For this Catalogue the <b>MQA Rating Checks </b>are currently <b>deactivated</b>.</p>\n </div>\n\n <button type=\"button\" class=\"btn btn-secondary\" @click=\"handleActivate()\">{{ activatedString }}</button>\n </div>\n <div v-if=\"active\">\n <div class=\"mqaWrapper\">\n <h3>Recipients Mail</h3>\n <span>Add and edit mail addresses for recieving the MQA report</span>\n <table ref=\"mailButtonWrap\" v-if=\"mailList.length != 0\">\n <tr>\n <th>Mail</th>\n </tr>\n <tr v-for=\"item in mailList\" class=\"mailItems\">\n <td>\n <input type=\"text\" :value=\"item.mail\" :readonly=\"item.readonly\"\n :class=\"{ 'editable': !item.readonly, 'invalid': !item.valid }\"\n @input=\"handleMailinput($event, item.mail)\">\n <div>\n <button type=\"button\" class=\"btn btn-secondary\"\n @click=\"handleReadonly(item)\">Edit</button>\n <button type=\"button\" class=\"btn btn-secondary\"\n @click=\"handleDelete(item.mail)\">Delete</button>\n </div>\n </td>\n <span class=\"errormsg\" v-if=\"!item.valid\">*Invalid email format</span>\n </tr>\n </table>\n <div class=\"my-3 d-flex\">\n <input type=\"text\" v-model=\"newMail.mail\" @input=\"handleMailinput($event)\"\n :class=\"{ 'invalidNewMail': !newMail.valid }\" style=\"padding:0.25rem\">\n <button type=\"button\" class=\"btn btn-secondary mx-3\" :disabled=\"!newMail.valid\"\n @click=\"addNewMail()\">+\n add Mail</button>\n </div>\n \n <span class=\"errormsg\" v-if=\"!newMail.valid\">*Invalid email format</span>\n </div>\n <div class=\"mqaWrapper\">\n <h3>Frequency of Rating Checks</h3>\n <span>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut\n labore et dolore magna aliquyam erat, sed diam voluptua</span>\n <div class=\"d-flex\">\n <div class=\"mr-3 my-3\">\n <button type=\"button\" class=\"btn btn-secondary\" @click=\"weekly = !weekly; monthly = false\"\n :class=\"{ 'activeChoiceButton': weekly === true }\">Weekly</button>\n <div class=\"weekdays\" :class=\"{ 'blur': !weekly }\">\n <span v-for=\"day in week\" @click=\"currentday(day, $event)\">\n <button :disabled=\"!weekly\" class=\"dayButtons\">{{ day }}</button>\n </span>\n </div>\n </div>\n <div class=\"my-3\">\n <button type=\"button\" :class=\"{ 'activeChoiceButton': monthly === true }\"\n class=\"btn btn-secondary\"\n @click=\"monthly = !monthly; weekly = false; resetWeekdays()\">Monthly</button>\n <div class=\"d-flex daypicker my-3\" :class=\"{ 'blur': !monthly }\">\n <input v-model=\"daysInMonth\" @input=\"adjustWidth()\" :class=\"{ dynamicWidth: inputWidth }\"\n :disabled=\"!monthly\">.\n <div class=\"caretWrap\">\n <button @click=\"editDate('up')\" class=\"caretButtons ml-1\"><svg\n xmlns=\"http://www.w3.org/2000/svg\" width=\"12\" height=\"12\" fill=\"currentColor\"\n class=\"bi bi-caret-up-fill\" viewBox=\"0 0 16 16\">\n <path\n d=\"m7.247 4.86-4.796 5.481c-.566.647-.106 1.659.753 1.659h9.592a1 1 0 0 0 .753-1.659l-4.796-5.48a1 1 0 0 0-1.506 0z\" />\n </svg></button>\n <button @click=\"editDate()\" class=\"caretButtons mr-1\"><svg\n xmlns=\"http://www.w3.org/2000/svg\" width=\"12\" height=\"12\" fill=\"currentColor\"\n class=\"bi bi-caret-down-fill\" viewBox=\"0 0 16 16\">\n <path\n d=\"M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z\" />\n </svg></button>\n </div>\n <span>day of the month</span>\n </div>\n </div>\n </div>\n </div>\n <div class=\"mqaWrapper\">\n <h3>Notification Treshold</h3>\n <span>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut\n labore et dolore magna aliquyam erat, sed diam voluptua</span>\n <div class=\"w-50\">\n <div class=\"d-flex justify-content-between\">\n <span><b>0</b></span>\n <span><b>400</b></span>\n </div>\n <input type=\"range\" v-model=\"value\" min=\"0\" max=\"400\" />\n <p>Lower than <b>{{ value }}</b> Points</p>\n </div>\n </div>\n <div class=\"actionWrapper\">\n <button type=\"button\" class=\"btn btn-secondary\" @click=\"\">Save</button>\n <button type=\"button\" class=\"btn btn-secondary\" @click=\"\">Cancel</button>\n </div>\n </div>\n </div>\n\n</template>\n<script setup>\nimport { ref } from 'vue';\nimport { onClickOutside } from '@vueuse/core'\n\nlet monthly = ref(false)\nlet weekly = ref(false)\nlet newMail = ref({ 'mail': '', 'valid': true })\nlet mailButtonWrap = ref(null)\nlet isReadonly = ref(true)\nlet activatedString = ref('Activate')\nlet inputWidth = ref(false)\nlet active = ref(false)\nlet mailList = ref()\nlet week = ['Mo', 'Tue', 'We', 'Th', 'Fr', 'Sa', 'Su']\nlet daysInMonth = ref(1)\n\nconst value = ref(0);\nconst regex = /^(2[0-8]|[1-9])$/;\n\nmailList.value = [{ 'mail': \"mail@mail2.com\", readonly: true, valid: true }, { 'mail': \"mail@mail1.com\", readonly: true, valid: true }]\n\n\nonClickOutside(mailButtonWrap, event => {\n mailList.value.forEach(element => {\n element.readonly = true\n })\n});\nconst resetWeekdays = () => {\n const arr = document.getElementsByClassName('dayButtons')\n for (let index = 0; index < arr.length; index++) {\n arr[index].classList.remove('activeItem')\n }\n\n\n}\nconst editDate = (count) => {\n if (count === \"up\" && daysInMonth.value < 28) {\n if (daysInMonth.value > 8) {\n inputWidth.value = true\n }\n daysInMonth.value++\n }\n else if (daysInMonth.value > 1) {\n if (daysInMonth.value < 11) {\n inputWidth.value = false\n }\n daysInMonth.value--\n }\n}\nconst currentday = (day, event) => {\n event.target.classList.toggle('activeItem')\n}\nconst adjustWidth = () => {\n\n if (!regex.test(daysInMonth.value)) {\n daysInMonth.value = '28';\n }\n if (daysInMonth.value > 8) {\n inputWidth.value = true\n }\n else inputWidth.value = false\n}\nconst addNewMail = () => {\n if (newMail.value.mail != '') {\n mailList.value.push({ 'mail': newMail.value.mail, readonly: true, valid: true })\n newMail.value = { 'mail': '', 'valid': true }\n }\n\n}\nconst handleActivate = () => {\n if (!active.value) {\n active.value = true\n activatedString.value = 'Deactivate'\n } else {\n active.value = false\n activatedString.value = 'Activate'\n }\n}\nconst handleReadonly = (item) => {\n mailList.value.forEach(element => {\n element.readonly = true\n });\n item.readonly = !item.readonly\n}\nconst handleMailinput = (e, mail) => {\n const emailRegex = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\\.[a-zA-Z]{2,}$/;\n const newEmail = e.target.value;\n if (emailRegex.test(newEmail) || newEmail === '') {\n mailList.value.forEach(element => {\n if (element.mail === mail) {\n element.mail = newEmail\n element.valid = true\n }\n });\n if (mail === undefined) {\n newMail.value.valid = true\n\n\n }\n } else {\n mailList.value.forEach(element => {\n if (element.mail === mail) {\n element.valid = false\n }\n });\n if (mail === undefined) {\n newMail.value.valid = false\n\n\n }\n }\n\n}\nconst handleDelete = (mail) => {\n let indexToDelete = -1; // Variable zum Speichern des Index\n\n mailList.value.forEach((element, index) => {\n if (element.mail === mail) {\n indexToDelete = index; // Speichere den Index, wenn die Bedingung erfüllt ist\n }\n });\n\n // Wenn ein gültiger Index gefunden wurde, lösche das Element\n if (indexToDelete !== -1) {\n mailList.value.splice(indexToDelete, 1);\n }\n}\n</script>\n<style scoped>\n.errormsg {\n color: red;\n font-size: 10px;\n}\n\n.activeChoiceButton {\n background-color: var(--primary);\n color: white;\n\n &:active {\n background-color: #3E6CD5 !important;\n }\n\n &:focus {\n outline: none;\n background-color: #3E6CD5;\n }\n\n &:focus-visible {\n outline: none;\n background-color: #3E6CD5;\n }\n}\n\n.blur {\n opacity: 0.3;\n}\n\n.mailItems {\n input {\n outline: none;\n background: none;\n border: none;\n width: 20rem;\n }\n}\n\n.invalidNewMail {\n\n border-radius: 2px;\n border: 2px solid rgba(255, 0, 0, 0.336);\n\n &:focus {\n border-radius: 2px;\n box-shadow: 0 0 0 0.1rem rgba(255, 0, 0, 0.774);\n border: 1px solid rgba(255, 0, 0, 0.336);\n }\n\n &:focus-visible {\n outline: 0;\n border-radius: 2px;\n box-shadow: 0 0 0 0.1rem rgba(255, 0, 0, 0.774);\n border: 1px solid rgba(255, 0, 0, 0.336);\n }\n}\n\n.editable {\n transition: all 200ms ease-in-out;\n padding-left: 0.5rem;\n border-bottom: 2px solid var(--primary) !important;\n}\n\n.invalid {\n border-bottom: 1px solid red !important;\n}\n\n.caretButtons {\n all: unset;\n cursor: pointer;\n}\n\n.caretWrap {\n display: contents;\n\n}\n\n.actionWrapper {\n display: flex;\n flex-direction: row-reverse;\n\n button {\n margin-left: 1rem;\n }\n}\n\ninput[type=\"range\"] {\n width: 100%;\n}\n\n.mqaWrapper {\n margin: 3rem 0;\n}\n\ntable {\n margin-top: 1rem;\n min-width: 50%;\n}\n\nth {\n border-bottom: 1px solid lightgray;\n}\n\ntd {\n display: flex;\n justify-content: space-between;\n padding: 1rem 0;\n}\n\n.daypicker {\n padding: 1rem;\n border: 1px solid lightgray;\n border-radius: 15px;\n\n input {\n width: 13px;\n border: none;\n background-color: unset;\n }\n\n}\n\n.dynamicWidth {\n width: 22px !important;\n}\n\n.activeItem {\n background-color: var(--primary);\n color: white;\n}\n\n.weekdays {\n border: 1px solid lightgray;\n border-radius: 15px;\n margin: 1rem 0;\n overflow: hidden;\n\n .dayButtons {\n border: none;\n display: inline-block;\n text-align: center;\n flex-direction: row;\n min-width: 60px;\n padding: 1rem;\n border-right: 1px solid lightgray;\n cursor: pointer;\n\n &:focus-visible {\n outline: unset;\n background-color: #3E6CD5;\n color: white;\n }\n\n &:hover {\n background-color: #3E6CD5;\n color: white;\n }\n }\n\n span:last-child button {\n border: none;\n }\n}\n\n.mqaWrapper {\n padding: 1rem;\n background-color: #FBFBFB;\n}\n\nbutton {\n background-color: unset;\n border: 1px solid var(--primary);\n color: black;\n\n &:hover {\n background-color: #3E6CD5;\n color: white;\n }\n}\n\nbutton,\nspan {\n transition: all 100ms ease-in-out;\n}\n</style>"],"names":["monthly","ref","weekly","newMail","mailButtonWrap","activatedString","inputWidth","active","mailList","week","daysInMonth","value","regex","onClickOutside","event","element","resetWeekdays","arr","index","editDate","count","currentday","day","adjustWidth","addNewMail","handleActivate","handleReadonly","item","handleMailinput","e","mail","emailRegex","newEmail","handleDelete","indexToDelete"],"mappings":"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"}
@@ -0,0 +1,5 @@
1
+ const e = "";
2
+ export {
3
+ e as default
4
+ };
5
+ //# sourceMappingURL=CatalogueMQA.vue2.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CatalogueMQA.vue2.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1,64 +1,129 @@
1
- import { getCurrentInstance as b, ref as D, computed as I, onMounted as N, openBlock as l, createElementBlock as r, createElementVNode as i, toDisplayString as n, createTextVNode as o, Fragment as m, renderList as p, unref as d, createVNode as f, withCtx as g, createCommentVNode as $ } from "vue";
2
- import { useStore as q } from "vuex";
3
- import v from "../../widgets/AppLink.vue.mjs";
4
- import w from "axios";
5
- import { has as C, isNil as h } from "lodash-es";
1
+ import { getCurrentInstance as U, ref as w, computed as A, onMounted as E, openBlock as n, createElementBlock as r, Fragment as d, createElementVNode as e, toDisplayString as o, createTextVNode as l, renderList as p, unref as m, createVNode as f, withCtx as g, createCommentVNode as L } from "vue";
2
+ import { useStore as M } from "vuex";
3
+ import c from "../../widgets/AppLink.vue.mjs";
4
+ import P from "axios";
5
+ import { useRouter as V, useRoute as j } from "vue-router";
6
+ import { has as v, isNil as k } from "lodash-es";
6
7
  import "./UserCataloguesPage.vue2.mjs";
7
- const x = { class: "catOverview" }, L = { class: "d-flex flex-column bg-transparent container-fluid justify-content-between content" }, V = { class: "small-headline" }, j = { class: "m-0" }, E = { class: "catWrap" }, M = {
8
+ import Q from "../../_virtual/_plugin-vue_export-helper.mjs";
9
+ const B = { class: "catOverview" }, O = { class: "d-flex flex-column bg-transparent container-fluid justify-content-between content" }, R = { class: "small-headline" }, S = { class: "m-0" }, F = { class: "catWrap" }, T = ["onClick"], W = ["onClick"], z = ["onClick"], G = {
8
10
  __name: "UserCataloguesPage",
9
- setup(U) {
10
- let _ = b().appContext.app.config.globalProperties.$env;
11
- const y = q();
12
- let a = D([]), c = I(() => y.getters["auth/getUserCatalogIds"]), k = async () => {
13
- let t;
14
- await w.get(_.api.baseUrl + "search?filter=catalogue&limit=1000").then((e) => t = e).catch((e) => {
15
- reject(e);
16
- }), t.data.result.results.forEach((e) => {
17
- C(e, "title") && !h(e.title) && C(e, "id") && !h(e.id) && a.value.push({ title: Object.values(e.title)[0], id: e.id });
18
- }), a.value = a.value.filter((e) => c.value.includes(e.id)).map((e) => ({ id: e.id, name: e.title }));
11
+ setup(H) {
12
+ const $ = V(), D = j();
13
+ let q = U().appContext.app.config.globalProperties.$env;
14
+ const I = M();
15
+ let i = w([]), y = A(() => I.getters["auth/getUserCatalogIds"]), h = async () => {
16
+ let a;
17
+ await P.get(q.api.baseUrl + "search?filter=catalogue&limit=1000").then((t) => a = t).catch((t) => {
18
+ reject(t);
19
+ }), a.data.result.results.forEach((t) => {
20
+ v(t, "title") && !k(t.title) && v(t, "id") && !k(t.id) && i.value.push({ title: Object.values(t.title)[0], id: t.id });
21
+ }), i.value = i.value.filter((t) => y.value.includes(t.id)).map((t) => ({ id: t.id, name: t.title }));
19
22
  };
20
- return N(async () => {
21
- k();
22
- }), (t, e) => (l(), r("div", x, [
23
- i("div", L, [
24
- i("h1", V, n(t.$t("message.dataupload.info.userCatalogues")), 1),
25
- e[1] || (e[1] = o()),
26
- i("p", j, n(t.$t("message.dataupload.info.userCatDescription")), 1),
27
- e[2] || (e[2] = o()),
28
- i("div", E, [
29
- (l(!0), r(m, null, p(d(a), (s, u) => (l(), r("div", {
30
- key: u,
31
- class: "annifItems"
32
- }, [
33
- f(v, {
34
- to: { name: "CatalogueDetails", query: { locale: t.$route.query.locale }, params: { ctlg_id: s.id } }
35
- }, {
36
- default: g(() => [
37
- o(n(s.name), 1)
38
- ]),
39
- _: 2
40
- }, 1032, ["to"])
41
- ]))), 128)),
42
- e[0] || (e[0] = o()),
43
- d(a).length === 0 ? (l(!0), r(m, { key: 0 }, p(d(c), (s, u) => (l(), r("div", {
44
- key: u,
45
- class: "annifItems"
46
- }, [
47
- f(v, {
48
- to: { name: "CatalogueDetails", query: { locale: t.$route.query.locale }, params: { ctlg_id: s } }
23
+ const N = (a) => {
24
+ $.push({
25
+ name: "DataProviderInterface-UserCatalogues-MQA",
26
+ params: { id: a.id },
27
+ query: { locale: D.query.locale }
28
+ }).catch(() => {
29
+ });
30
+ }, C = () => {
31
+ };
32
+ return E(async () => {
33
+ h();
34
+ }), (a, t) => (n(), r(d, null, [
35
+ e("div", B, [
36
+ e("div", O, [
37
+ e("h1", R, o(a.$t("message.dataupload.info.userCatalogues")), 1),
38
+ t[1] || (t[1] = l()),
39
+ e("p", S, o(a.$t("message.dataupload.info.userCatDescription")), 1),
40
+ t[2] || (t[2] = l()),
41
+ e("div", F, [
42
+ (n(!0), r(d, null, p(m(i), (s, u) => (n(), r("div", {
43
+ key: u,
44
+ class: "annifItems"
45
+ }, [
46
+ f(c, {
47
+ to: { name: "CatalogueDetails", query: { locale: a.$route.query.locale }, params: { ctlg_id: s.id } }
48
+ }, {
49
+ default: g(() => [
50
+ l(o(s.name), 1)
51
+ ]),
52
+ _: 2
53
+ }, 1032, ["to"])
54
+ ]))), 128)),
55
+ t[0] || (t[0] = l()),
56
+ m(i).length === 0 ? (n(!0), r(d, { key: 0 }, p(m(y), (s, u) => (n(), r("div", {
57
+ key: u,
58
+ class: "annifItems"
59
+ }, [
60
+ f(c, {
61
+ to: { name: "CatalogueDetails", query: { locale: a.$route.query.locale }, params: { ctlg_id: s } }
62
+ }, {
63
+ default: g(() => [
64
+ l(o(s), 1)
65
+ ]),
66
+ _: 2
67
+ }, 1032, ["to"])
68
+ ]))), 128)) : L("", !0)
69
+ ])
70
+ ])
71
+ ]),
72
+ t[10] || (t[10] = l()),
73
+ e("table", null, [
74
+ e("thead", null, [
75
+ e("tr", null, [
76
+ e("th", null, o(a.$t("message.metadata.catalog")) + " - ID", 1),
77
+ t[3] || (t[3] = l()),
78
+ e("th", null, o(a.$t("message.metadata.description")), 1),
79
+ t[4] || (t[4] = l()),
80
+ e("th", null, o(a.$t("message.dataupload.menu.actions")), 1)
81
+ ])
82
+ ]),
83
+ t[9] || (t[9] = l()),
84
+ (n(!0), r(d, null, p(m(i), (s, u) => (n(), r("tr", { key: u }, [
85
+ e("td", null, [
86
+ f(c, {
87
+ to: { name: "CatalogueDetails", query: { locale: a.$route.query.locale }, params: { ctlg_id: s.id } }
49
88
  }, {
50
89
  default: g(() => [
51
- o(n(s), 1)
90
+ l(o(s.id), 1)
52
91
  ]),
53
92
  _: 2
54
93
  }, 1032, ["to"])
55
- ]))), 128)) : $("", !0)
56
- ])
94
+ ]),
95
+ t[7] || (t[7] = l()),
96
+ e("td", null, [
97
+ e("span", null, o(s.name), 1)
98
+ ]),
99
+ t[8] || (t[8] = l()),
100
+ e("td", null, [
101
+ e("button", {
102
+ type: "button",
103
+ class: "btn btn-secondary",
104
+ onClick: (b) => C(a.id)
105
+ }, o(a.$t("message.metadata.linkedData")), 9, T),
106
+ t[5] || (t[5] = l()),
107
+ e("button", {
108
+ type: "button",
109
+ class: "btn btn-secondary",
110
+ onClick: (b) => C(a.id)
111
+ }, o(a.$t("message.dataupload.menu.edit")), 9, W),
112
+ t[6] || (t[6] = l()),
113
+ e("button", {
114
+ type: "button",
115
+ class: "btn btn-secondary",
116
+ onClick: (b) => N(s)
117
+ }, `configure MQA report
118
+
119
+ `, 8, z)
120
+ ])
121
+ ]))), 128))
57
122
  ])
58
- ]));
123
+ ], 64));
59
124
  }
60
- };
125
+ }, et = /* @__PURE__ */ Q(G, [["__scopeId", "data-v-2b11be04"]]);
61
126
  export {
62
- M as default
127
+ et as default
63
128
  };
64
129
  //# sourceMappingURL=UserCataloguesPage.vue.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"UserCataloguesPage.vue.mjs","sources":["../../../lib/data-provider-interface/views/UserCataloguesPage.vue"],"sourcesContent":["<script setup>\nimport { useStore } from 'vuex';\nimport { ref, computed, onMounted, } from 'vue';\nimport AppLink from \"../../widgets/AppLink.vue\";\nimport axios from 'axios'\nimport { getCurrentInstance } from \"vue\";\nimport {\n has,\n isNil,\n} from 'lodash-es';\n\nlet env = getCurrentInstance().appContext.app.config.globalProperties.$env;\nconst store = useStore();\nlet filteredCatalogs = ref([])\nlet userCatIDList = computed(() => store.getters['auth/getUserCatalogIds'])\n\nlet filterCatList = async () => {\n let cache;\n await axios\n .get(env.api.baseUrl + 'search?filter=catalogue&limit=1000')\n .then(response => (cache = response))\n .catch((err) => {\n reject(err);\n });\n\n cache.data.result.results.forEach((e) => {\n if (has(e, 'title') && !isNil(e.title) && has(e, 'id') && !isNil(e.id)) filteredCatalogs.value.push({ title: Object.values(e.title)[0], id: e.id })\n });\n\n filteredCatalogs.value = filteredCatalogs.value\n .filter(item => userCatIDList.value.includes(item.id))\n .map(item => ({ id: item.id, name: item.title }));\n}\nonMounted(async () => {\n filterCatList()\n});\n</script>\n<template>\n <div class=\"catOverview\">\n <div class=\"d-flex flex-column bg-transparent container-fluid justify-content-between content \">\n <h1 class=\"small-headline\">{{ $t('message.dataupload.info.userCatalogues') }}</h1>\n <p class=\"m-0 \">{{ $t('message.dataupload.info.userCatDescription') }}</p>\n <div class=\"catWrap\">\n <div v-for=\"(catalog, index) in filteredCatalogs\" :key=\"index\" class=\"annifItems \">\n <app-link\n :to=\"{ name: 'CatalogueDetails', query: { locale: $route.query.locale }, params: { ctlg_id: catalog.id } }\">{{\n catalog.name }}</app-link>\n </div>\n <div v-if=\"filteredCatalogs.length === 0\" v-for=\"(catalog, index) in userCatIDList\" :key=\"index\" class=\"annifItems \">\n <app-link\n :to=\"{ name: 'CatalogueDetails', query: { locale: $route.query.locale }, params: { ctlg_id: catalog } }\">{{\n catalog }}</app-link>\n </div>\n </div>\n </div>\n </div>\n\n</template>\n<style>\n.catOverview {\n min-height: 60vh;\n}\n\n.catWrap {\n display: flex;\n flex-wrap: wrap;\n margin-top: 10px;\n padding-top: 10px;\n border-top: 1px solid lightgray;\n justify-content: space-between;\n}\n\n.catWrap .annifItems {\n background: #ECECEC;\n flex-grow: 1;\n text-align: center;\n}\n\n.subline {\n font-size: 12px;\n color: lightgray;\n\n}\n</style>"],"names":["env","getCurrentInstance","store","useStore","filteredCatalogs","ref","userCatIDList","computed","filterCatList","cache","axios","response","err","has","isNil","item","onMounted"],"mappings":";;;;;;;;;AAWA,QAAIA,IAAMC,EAAkB,EAAG,WAAW,IAAI,OAAO,iBAAiB;AACtE,UAAMC,IAAQC,EAAQ;AACtB,QAAIC,IAAmBC,EAAI,EAAE,GACzBC,IAAgBC,EAAS,MAAML,EAAM,QAAQ,wBAAwB,CAAC,GAEtEM,IAAgB,YAAY;AAC9B,UAAIC;AACJ,YAAMC,EACH,IAAIV,EAAI,IAAI,UAAU,oCAAoC,EAC1D,KAAK,CAAAW,MAAaF,IAAQE,CAAS,EACnC,MAAM,CAACC,MAAQ;AACd,eAAOA,CAAG;AAAA,MAChB,CAAK,GAEHH,EAAM,KAAK,OAAO,QAAQ,QAAQ,CAAC,MAAM;AACvC,QAAII,EAAI,GAAG,OAAO,KAAK,CAACC,EAAM,EAAE,KAAK,KAAKD,EAAI,GAAG,IAAI,KAAK,CAACC,EAAM,EAAE,EAAE,KAAGV,EAAiB,MAAM,KAAK,EAAE,OAAO,OAAO,OAAO,EAAE,KAAK,EAAE,CAAC,GAAG,IAAI,EAAE,GAAE,CAAE;AAAA,MACtJ,CAAG,GAEDA,EAAiB,QAAQA,EAAiB,MACvC,OAAO,CAAAW,MAAQT,EAAc,MAAM,SAASS,EAAK,EAAE,CAAC,EACpD,IAAI,CAAAA,OAAS,EAAE,IAAIA,EAAK,IAAI,MAAMA,EAAK,MAAO,EAAC;AAAA,IACpD;AACA,WAAAC,EAAU,YAAY;AACpB,MAAAR,EAAc;AAAA,IAChB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"UserCataloguesPage.vue.mjs","sources":["../../../lib/data-provider-interface/views/UserCataloguesPage.vue"],"sourcesContent":["<script setup>\nimport { useStore } from 'vuex';\nimport { ref, computed, onMounted, } from 'vue';\nimport AppLink from \"../../widgets/AppLink.vue\";\nimport axios from 'axios'\nimport { useRouter, useRoute } from 'vue-router';\nimport { getCurrentInstance } from \"vue\";\n\nimport {\n has,\n isNil,\n} from 'lodash-es';\n\nconst router = useRouter();\nconst route = useRoute();\n\nlet env = getCurrentInstance().appContext.app.config.globalProperties.$env;\nconst store = useStore();\nlet filteredCatalogs = ref([])\nlet userCatIDList = computed(() => store.getters['auth/getUserCatalogIds'])\n\nlet filterCatList = async () => {\n let cache;\n await axios\n .get(env.api.baseUrl + 'search?filter=catalogue&limit=1000')\n .then(response => (cache = response))\n .catch((err) => {\n reject(err);\n });\n\n cache.data.result.results.forEach((e) => {\n if (has(e, 'title') && !isNil(e.title) && has(e, 'id') && !isNil(e.id)) filteredCatalogs.value.push({ title: Object.values(e.title)[0], id: e.id })\n });\n\n filteredCatalogs.value = filteredCatalogs.value\n .filter(item => userCatIDList.value.includes(item.id))\n .map(item => ({ id: item.id, name: item.title }));\n}\nconst handleMQA = (cat) => {\n\n router.push({\n name: 'DataProviderInterface-UserCatalogues-MQA',\n params: { id: cat.id },\n query: { locale: route.query.locale }\n }).catch(() => { });\n}\nconst handleEdit = () => {\n\n}\nonMounted(async () => {\n filterCatList()\n});\n</script>\n<template>\n <div class=\"catOverview\">\n <div class=\"d-flex flex-column bg-transparent container-fluid justify-content-between content \">\n <h1 class=\"small-headline\">{{ $t('message.dataupload.info.userCatalogues') }}</h1>\n <p class=\"m-0 \">{{ $t('message.dataupload.info.userCatDescription') }}</p>\n <div class=\"catWrap\">\n <div v-for=\"(catalog, index) in filteredCatalogs\" :key=\"index\" class=\"annifItems \">\n <app-link\n :to=\"{ name: 'CatalogueDetails', query: { locale: $route.query.locale }, params: { ctlg_id: catalog.id } }\">{{\n catalog.name }}</app-link>\n </div>\n <div v-if=\"filteredCatalogs.length === 0\" v-for=\"(catalog, index) in userCatIDList\" :key=\"index\"\n class=\"annifItems \">\n <app-link\n :to=\"{ name: 'CatalogueDetails', query: { locale: $route.query.locale }, params: { ctlg_id: catalog } }\">{{\n catalog }}</app-link>\n </div>\n </div>\n </div>\n </div>\n\n <table>\n <thead>\n <tr>\n <th>{{ $t('message.metadata.catalog') }} - ID</th>\n <th>{{ $t('message.metadata.description') }}</th>\n <th>{{ $t('message.dataupload.menu.actions') }}</th>\n </tr>\n </thead>\n\n <tr v-for=\"(catalog, index) in filteredCatalogs\" :key=\"index\">\n <td>\n\n <app-link\n :to=\"{ name: 'CatalogueDetails', query: { locale: $route.query.locale }, params: { ctlg_id: catalog.id } }\">{{\n catalog.id }}</app-link>\n\n </td>\n <td>\n <span>{{ catalog.name }}</span>\n </td>\n <td>\n <button type=\"button\" class=\"btn btn-secondary\" @click=\"handleEdit(id, catalog)\">{{\n $t('message.metadata.linkedData') }}</button>\n <button type=\"button\" class=\"btn btn-secondary\" @click=\"handleEdit(id, catalog)\">{{\n $t('message.dataupload.menu.edit') }}</button>\n\n <button type=\"button\" class=\"btn btn-secondary\" @click=\"handleMQA(catalog)\">configure MQA report\n\n </button>\n\n </td>\n </tr>\n\n\n </table>\n\n</template>\n<style scoped>\n.catOverview {\n min-height: 60vh;\n}\n\n.catWrap {\n display: flex;\n flex-wrap: wrap;\n margin-top: 10px;\n padding-top: 10px;\n border-top: 1px solid lightgray;\n justify-content: space-between;\n}\n\n.catWrap .annifItems {\n background: #ECECEC;\n flex-grow: 1;\n text-align: center;\n}\n\n.subline {\n font-size: 12px;\n color: lightgray;\n\n}\n\ntable {\n margin: auto\n}\n\nth,\ntd {\n padding: 1rem;\n\n}\n\ntr {\n padding: 1rem;\n border-bottom: 1px solid lightgray;\n}\n\nthead {\n border-bottom: 1px solid lightgray;\n}\n</style>"],"names":["router","useRouter","route","useRoute","env","getCurrentInstance","store","useStore","filteredCatalogs","ref","userCatIDList","computed","filterCatList","cache","axios","response","err","e","has","isNil","item","handleMQA","cat","handleEdit","onMounted"],"mappings":";;;;;;;;;;;AAaA,UAAMA,IAASC,EAAS,GAClBC,IAAQC,EAAQ;AAEtB,QAAIC,IAAMC,EAAkB,EAAG,WAAW,IAAI,OAAO,iBAAiB;AACtE,UAAMC,IAAQC,EAAQ;AACtB,QAAIC,IAAmBC,EAAI,EAAE,GACzBC,IAAgBC,EAAS,MAAML,EAAM,QAAQ,wBAAwB,CAAC,GAEtEM,IAAgB,YAAY;AAC9B,UAAIC;AACJ,YAAMC,EACH,IAAIV,EAAI,IAAI,UAAU,oCAAoC,EAC1D,KAAK,CAAAW,MAAaF,IAAQE,CAAS,EACnC,MAAM,CAACC,MAAQ;AACd,eAAOA,CAAG;AAAA,MAChB,CAAK,GAEHH,EAAM,KAAK,OAAO,QAAQ,QAAQ,CAACI,MAAM;AACvC,QAAIC,EAAID,GAAG,OAAO,KAAK,CAACE,EAAMF,EAAE,KAAK,KAAKC,EAAID,GAAG,IAAI,KAAK,CAACE,EAAMF,EAAE,EAAE,KAAGT,EAAiB,MAAM,KAAK,EAAE,OAAO,OAAO,OAAOS,EAAE,KAAK,EAAE,CAAC,GAAG,IAAIA,EAAE,GAAE,CAAE;AAAA,MACtJ,CAAG,GAEDT,EAAiB,QAAQA,EAAiB,MACvC,OAAO,CAAAY,MAAQV,EAAc,MAAM,SAASU,EAAK,EAAE,CAAC,EACpD,IAAI,CAAAA,OAAS,EAAE,IAAIA,EAAK,IAAI,MAAMA,EAAK,MAAO,EAAC;AAAA,IACpD;AACA,UAAMC,IAAY,CAACC,MAAQ;AAEzB,MAAAtB,EAAO,KAAK;AAAA,QACV,MAAM;AAAA,QACN,QAAQ,EAAE,IAAIsB,EAAI,GAAI;AAAA,QACtB,OAAO,EAAE,QAAQpB,EAAM,MAAM,OAAO;AAAA,MACxC,CAAG,EAAE,MAAM,MAAM;AAAA,MAAA,CAAG;AAAA,IACpB,GACMqB,IAAa,MAAM;AAAA,IAEzB;AACA,WAAAC,EAAU,YAAY;AACpB,MAAAZ,EAAc;AAAA,IAChB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -109,7 +109,7 @@ function _(s, t, o, C, i, e) {
109
109
  ]))
110
110
  ]);
111
111
  }
112
- const T = /* @__PURE__ */ k(I, [["render", _], ["__scopeId", "data-v-9ed03189"]]);
112
+ const T = /* @__PURE__ */ k(I, [["render", _], ["__scopeId", "data-v-5cf6c042"]]);
113
113
  export {
114
114
  T as default
115
115
  };