@piveau/dpi 0.1.0-beta.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (194) hide show
  1. package/dist/_virtual/_plugin-vue_export-helper.js +9 -0
  2. package/dist/assets/dpi.css +1 -0
  3. package/dist/composables/useRuntimeEnv.js +11 -0
  4. package/dist/composables/useTed.js +9 -0
  5. package/dist/data-provider-interface/DPIMenu.vue.js +457 -0
  6. package/dist/data-provider-interface/DataProviderInterface.vue.js +43 -0
  7. package/dist/data-provider-interface/DataProviderInterface.vue2.js +144 -0
  8. package/dist/data-provider-interface/HappyFlowComponents/BlogDPIHome.vue.js +13 -0
  9. package/dist/data-provider-interface/HappyFlowComponents/CommunityDPI.vue.js +11 -0
  10. package/dist/data-provider-interface/HappyFlowComponents/ComponentLibrary.vue.js +1052 -0
  11. package/dist/data-provider-interface/HappyFlowComponents/ConsultingDPI.vue.js +11 -0
  12. package/dist/data-provider-interface/HappyFlowComponents/DPIHome.vue.js +26 -0
  13. package/dist/data-provider-interface/HappyFlowComponents/FAQDPIHome.vue.js +11 -0
  14. package/dist/data-provider-interface/HappyFlowComponents/HomeTable.vue.js +109 -0
  15. package/dist/data-provider-interface/HappyFlowComponents/ServiceDPIHome.vue.js +11 -0
  16. package/dist/data-provider-interface/HappyFlowComponents/img/CheckCircleFill.svg.js +4 -0
  17. package/dist/data-provider-interface/HappyFlowComponents/img/Circle.svg.js +4 -0
  18. package/dist/data-provider-interface/HappyFlowComponents/img/CircleFill.svg.js +4 -0
  19. package/dist/data-provider-interface/HappyFlowComponents/img/DatenbereitstellerV3.svg.js +4 -0
  20. package/dist/data-provider-interface/HappyFlowComponents/img/Ellipse2Error.svg.js +4 -0
  21. package/dist/data-provider-interface/HappyFlowComponents/img/Ellipse2Published.svg.js +4 -0
  22. package/dist/data-provider-interface/HappyFlowComponents/img/Ellipse2Warning.svg.js +4 -0
  23. package/dist/data-provider-interface/HappyFlowComponents/img/FurV3.svg.js +4 -0
  24. package/dist/data-provider-interface/HappyFlowComponents/img/IllustrationCelebrate.svg.js +4 -0
  25. package/dist/data-provider-interface/HappyFlowComponents/img/IllustrationStart.svg.js +4 -0
  26. package/dist/data-provider-interface/HappyFlowComponents/img/InfoFill.svg.js +4 -0
  27. package/dist/data-provider-interface/HappyFlowComponents/img/Selected1.svg.js +4 -0
  28. package/dist/data-provider-interface/HappyFlowComponents/img/Selected1_2.svg.js +4 -0
  29. package/dist/data-provider-interface/HappyFlowComponents/img/Selected2.svg.js +4 -0
  30. package/dist/data-provider-interface/HappyFlowComponents/img/Selected2_2.svg.js +4 -0
  31. package/dist/data-provider-interface/HappyFlowComponents/img/Selected3.svg.js +4 -0
  32. package/dist/data-provider-interface/HappyFlowComponents/img/Selected3_2.svg.js +4 -0
  33. package/dist/data-provider-interface/HappyFlowComponents/img/Selected4.svg.js +4 -0
  34. package/dist/data-provider-interface/HappyFlowComponents/img/Selected4_2.svg.js +4 -0
  35. package/dist/data-provider-interface/HappyFlowComponents/img/Selected5.svg.js +4 -0
  36. package/dist/data-provider-interface/HappyFlowComponents/img/Selected5_2.svg.js +4 -0
  37. package/dist/data-provider-interface/HappyFlowComponents/img/WarningFill.svg.js +4 -0
  38. package/dist/data-provider-interface/HappyFlowComponents/img/bydata_logo_blue_small.svg.js +4 -0
  39. package/dist/data-provider-interface/HappyFlowComponents/img/iconRight.svg.js +4 -0
  40. package/dist/data-provider-interface/HappyFlowComponents/img/x-circleFill.svg.js +4 -0
  41. package/dist/data-provider-interface/HappyFlowComponents/services/dpiV3_apis.js +135 -0
  42. package/dist/data-provider-interface/HappyFlowComponents/services/eventBus.js +16 -0
  43. package/dist/data-provider-interface/HappyFlowComponents/ui/ButtonV3.vue.js +256 -0
  44. package/dist/data-provider-interface/HappyFlowComponents/ui/CheckboxV3.vue.js +96 -0
  45. package/dist/data-provider-interface/HappyFlowComponents/ui/Chip.vue.js +91 -0
  46. package/dist/data-provider-interface/HappyFlowComponents/ui/CloseOpenButtonV3.vue.js +67 -0
  47. package/dist/data-provider-interface/HappyFlowComponents/ui/CrossOutButton.vue.js +63 -0
  48. package/dist/data-provider-interface/HappyFlowComponents/ui/DatasetStatus.vue.js +52 -0
  49. package/dist/data-provider-interface/HappyFlowComponents/ui/DpiModalBase.vue.js +7 -0
  50. package/dist/data-provider-interface/HappyFlowComponents/ui/DpiModalBase.vue2.js +96 -0
  51. package/dist/data-provider-interface/HappyFlowComponents/ui/Dropdown.vue.js +231 -0
  52. package/dist/data-provider-interface/HappyFlowComponents/ui/Illustration.vue.js +33 -0
  53. package/dist/data-provider-interface/HappyFlowComponents/ui/InputField.vue.js +477 -0
  54. package/dist/data-provider-interface/HappyFlowComponents/ui/InputV3.vue.js +182 -0
  55. package/dist/data-provider-interface/HappyFlowComponents/ui/LogoV3.vue.js +40 -0
  56. package/dist/data-provider-interface/HappyFlowComponents/ui/ModalSimpleV3.vue.js +123 -0
  57. package/dist/data-provider-interface/HappyFlowComponents/ui/ModalV3.vue.js +566 -0
  58. package/dist/data-provider-interface/HappyFlowComponents/ui/MoreButton.vue.js +56 -0
  59. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/AccessRightsV3.vue.js +41 -0
  60. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/AccessServiceV3.vue.js +157 -0
  61. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/AvailabilityV3.vue.js +80 -0
  62. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/ByteSizeV3.vue.js +50 -0
  63. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/ChangeLicenseV3.vue.js +113 -0
  64. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/ChecksumV3.vue.js +116 -0
  65. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/ConformsToV3.vue.js +157 -0
  66. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/DescriptionV3.vue.js +40 -0
  67. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/DocumentationsV3.vue.js +227 -0
  68. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/FileFormatV3.vue.js +148 -0
  69. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/IssuedDateV3.vue.js +43 -0
  70. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/LanguageV3.vue.js +70 -0
  71. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/LicenseAttributionByText.vue.js +46 -0
  72. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/ModifiedDateV3.vue.js +43 -0
  73. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/PolicyV3.vue.js +130 -0
  74. package/dist/data-provider-interface/HappyFlowComponents/ui/OptionalInformation/StatusV3.vue.js +67 -0
  75. package/dist/data-provider-interface/HappyFlowComponents/ui/RapModal.vue.js +157 -0
  76. package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/AdditionalsModal.vue.js +106 -0
  77. package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/AdditionalsSubModal.vue.js +247 -0
  78. package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/CoverageModal.vue.js +79 -0
  79. package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/DistributionModal.vue.js +73 -0
  80. package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/EssentialsModal.vue.js +134 -0
  81. package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/FindabilityChips.vue.js +43 -0
  82. package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/HVDSwitch.vue.js +68 -0
  83. package/dist/data-provider-interface/HappyFlowComponents/ui/StateTag.vue.js +64 -0
  84. package/dist/data-provider-interface/HappyFlowComponents/ui/SwitchV3.vue.js +195 -0
  85. package/dist/data-provider-interface/HappyFlowComponents/ui/TableRowV3.vue.js +207 -0
  86. package/dist/data-provider-interface/HappyFlowComponents/ui/TextAreaV3.vue.js +115 -0
  87. package/dist/data-provider-interface/HappyFlowComponents/ui/TextButtonLarge.vue.js +108 -0
  88. package/dist/data-provider-interface/HappyFlowComponents/ui/TextButtonSmall.vue.js +125 -0
  89. package/dist/data-provider-interface/HappyFlowComponents/ui/Toast.vue.js +69 -0
  90. package/dist/data-provider-interface/components/AutocompleteInput.vue.js +279 -0
  91. package/dist/data-provider-interface/components/BasicInfosPage.vue.js +9 -0
  92. package/dist/data-provider-interface/components/ConditionalInput.vue.js +196 -0
  93. package/dist/data-provider-interface/components/ContactPage.vue.js +246 -0
  94. package/dist/data-provider-interface/components/CoveringPage.vue.js +9 -0
  95. package/dist/data-provider-interface/components/DataFetchingComponent.vue.js +49 -0
  96. package/dist/data-provider-interface/components/DiscoverabilityPage.vue.js +60 -0
  97. package/dist/data-provider-interface/components/DistLicense.vue.js +160 -0
  98. package/dist/data-provider-interface/components/DistributionSimplePage.vue.js +1147 -0
  99. package/dist/data-provider-interface/components/DistributionStepper.vue.js +212 -0
  100. package/dist/data-provider-interface/components/Dropup.vue.js +62 -0
  101. package/dist/data-provider-interface/components/FileUpload.vue.js +278 -0
  102. package/dist/data-provider-interface/components/HVDPage.vue.js +106 -0
  103. package/dist/data-provider-interface/components/HappyFlowLandingPage.vue.js +70 -0
  104. package/dist/data-provider-interface/components/InfoSlot.vue.js +81 -0
  105. package/dist/data-provider-interface/components/InputPageStep.vue.js +40 -0
  106. package/dist/data-provider-interface/components/InputPageStep.vue2.js +4 -0
  107. package/dist/data-provider-interface/components/LanguageSelector.vue.js +65 -0
  108. package/dist/data-provider-interface/components/Navigation.vue.js +256 -0
  109. package/dist/data-provider-interface/components/Navigation.vue2.js +1 -0
  110. package/dist/data-provider-interface/components/PolGeoUriPage.vue.js +81 -0
  111. package/dist/data-provider-interface/components/PublisherPage.vue.js +176 -0
  112. package/dist/data-provider-interface/components/ReviewAndPublishPage.vue.js +413 -0
  113. package/dist/data-provider-interface/components/SelectControlledGroup.vue.js +55 -0
  114. package/dist/data-provider-interface/components/SelectControlledGroup.vue2.js +4 -0
  115. package/dist/data-provider-interface/components/SimpleAccessURLInput.vue.js +32 -0
  116. package/dist/data-provider-interface/components/SimpleInput.vue.js +35 -0
  117. package/dist/data-provider-interface/components/SimpleSelect.vue.js +111 -0
  118. package/dist/data-provider-interface/components/SpatialInput.vue.js +276 -0
  119. package/dist/data-provider-interface/components/TempResPage.vue.js +211 -0
  120. package/dist/data-provider-interface/components/TheErrorDialog.vue.js +90 -0
  121. package/dist/data-provider-interface/components/TheErrorDialog.vue2.js +4 -0
  122. package/dist/data-provider-interface/components/TitelPage.vue.js +52 -0
  123. package/dist/data-provider-interface/components/UniqueIdentifierInput.vue.js +75 -0
  124. package/dist/data-provider-interface/components/UpdateDate.vue.js +75 -0
  125. package/dist/data-provider-interface/components/dpiV3Description.vue.js +44 -0
  126. package/dist/data-provider-interface/composables/aucotomplete.js +50 -0
  127. package/dist/data-provider-interface/composables/useDpiContext.js +17 -0
  128. package/dist/data-provider-interface/composables/useDpiEditMode.js +88 -0
  129. package/dist/data-provider-interface/composables/useDpiFormValues.js +8 -0
  130. package/dist/data-provider-interface/composables/useDpiSimpleLoader.js +384 -0
  131. package/dist/data-provider-interface/composables/useDpiStepper.js +47 -0
  132. package/dist/data-provider-interface/composables/useDpiUtils.js +39 -0
  133. package/dist/data-provider-interface/composables/useErrorDialog.js +31 -0
  134. package/dist/data-provider-interface/composables/useFormSchema.js +56 -0
  135. package/dist/data-provider-interface/composables/useRequestUriName.js +58 -0
  136. package/dist/data-provider-interface/config/dcatap/format-types.js +256 -0
  137. package/dist/data-provider-interface/config/dcatap/input-definition.js +1842 -0
  138. package/dist/data-provider-interface/config/dcatap/page-content-config.js +23 -0
  139. package/dist/data-provider-interface/config/dcatap/prefixes.js +25 -0
  140. package/dist/data-provider-interface/config/dcatap/vocab-prefixes.js +24 -0
  141. package/dist/data-provider-interface/config/dcatapde/format-types.js +274 -0
  142. package/dist/data-provider-interface/config/dcatapde/input-definition.js +2131 -0
  143. package/dist/data-provider-interface/config/dcatapde/page-content-config.js +23 -0
  144. package/dist/data-provider-interface/config/dcatapde/prefixes.js +27 -0
  145. package/dist/data-provider-interface/config/dcatapde/vocab-prefixes.js +33 -0
  146. package/dist/data-provider-interface/config/dcatapdeHappyFlow/converter.js +161 -0
  147. package/dist/data-provider-interface/config/dcatapdeHappyFlow/format-types.js +5 -0
  148. package/dist/data-provider-interface/config/dcatapdeHappyFlow/input-definition.js +2196 -0
  149. package/dist/data-provider-interface/config/dcatapdeHappyFlow/page-content-config.js +82 -0
  150. package/dist/data-provider-interface/config/dcatapdeHappyFlow/prefixes.js +5 -0
  151. package/dist/data-provider-interface/config/dcatapdeHappyFlow/vocab-prefixes.js +5 -0
  152. package/dist/data-provider-interface/config/dcatapdeODB/format-types.js +5 -0
  153. package/dist/data-provider-interface/config/dcatapdeODB/input-definition.js +18 -0
  154. package/dist/data-provider-interface/config/dcatapdeODB/page-content-config.js +5 -0
  155. package/dist/data-provider-interface/config/dcatapdeODB/prefixes.js +5 -0
  156. package/dist/data-provider-interface/config/dcatapdeODB/vocab-prefixes.js +5 -0
  157. package/dist/data-provider-interface/config/dpi-spec-config.js +54 -0
  158. package/dist/data-provider-interface/config/selector-languages.json.js +57 -0
  159. package/dist/data-provider-interface/plugins/userConfigShimPlugin.js +10 -0
  160. package/dist/data-provider-interface/store/dpiStore.js +33 -0
  161. package/dist/data-provider-interface/store/modules/formSchemaStore.js +94 -0
  162. package/dist/data-provider-interface/store/modules/navigationStore.js +24 -0
  163. package/dist/data-provider-interface/utils/general-helper.js +218 -0
  164. package/dist/data-provider-interface/utils/injectionKeys.js +5 -0
  165. package/dist/data-provider-interface/utils/translation-helper.js +31 -0
  166. package/dist/data-provider-interface/utils/useSteps.js +34 -0
  167. package/dist/data-provider-interface/views/DistributionInputPage.vue.js +100 -0
  168. package/dist/data-provider-interface/views/DistributionOverview.vue.js +201 -0
  169. package/dist/data-provider-interface/views/DraftsPage.vue.js +278 -0
  170. package/dist/data-provider-interface/views/InputPage.vue.js +1182 -0
  171. package/dist/data-provider-interface/views/LinkedDataViewer.vue.js +105 -0
  172. package/dist/data-provider-interface/views/OverviewPage/CatalogueOverview.vue.js +86 -0
  173. package/dist/data-provider-interface/views/OverviewPage/DatasetOverview.vue.js +214 -0
  174. package/dist/data-provider-interface/views/OverviewPage/DistributionOverview.vue.js +219 -0
  175. package/dist/data-provider-interface/views/OverviewPage/Properties/MultilingualProp.vue.js +19 -0
  176. package/dist/data-provider-interface/views/OverviewPage/Properties/SpecialProp.vue.js +397 -0
  177. package/dist/data-provider-interface/views/OverviewPage/Properties/StringProp.vue.js +56 -0
  178. package/dist/data-provider-interface/views/OverviewPage/Properties/URIProp.vue.js +109 -0
  179. package/dist/data-provider-interface/views/OverviewPage/Properties/URLProp.vue.js +92 -0
  180. package/dist/data-provider-interface/views/OverviewPage/PropertyEntry.vue.js +103 -0
  181. package/dist/data-provider-interface/views/OverviewPage.vue.js +189 -0
  182. package/dist/data-provider-interface/views/PropertyChooser.vue.js +41 -0
  183. package/dist/data-provider-interface/views/UserCataloguesPage.vue.js +74 -0
  184. package/dist/data-provider-interface/views/UserProfilePage.vue.js +83 -0
  185. package/dist/filters/dateFilters.js +39 -0
  186. package/dist/form/FormKitGroup.vue.js +55 -0
  187. package/dist/form/Repeatable.vue.js +7 -0
  188. package/dist/form/Repeatable.vue2.js +72 -0
  189. package/dist/form/inputDefinitions.js +131 -0
  190. package/dist/index.d.ts +1 -0
  191. package/dist/index.js +124 -0
  192. package/dist/utils/helpers.js +32 -0
  193. package/dist/widgets/AppLink.vue.js +118 -0
  194. package/package.json +96 -0
@@ -0,0 +1,103 @@
1
+ import _ from "./Properties/URIProp.vue.js";
2
+ import L from "./Properties/URLProp.vue.js";
3
+ import g from "./Properties/StringProp.vue.js";
4
+ import P from "./Properties/SpecialProp.vue.js";
5
+ import f from "./Properties/MultilingualProp.vue.js";
6
+ import S from "../../utils/general-helper.js";
7
+ import "lodash-es";
8
+ import { resolveComponent as l, createElementBlock as a, openBlock as t, createCommentVNode as r, createBlock as o, createVNode as n, Fragment as k, renderList as R } from "vue";
9
+ import U from "../../../_virtual/_plugin-vue_export-helper.js";
10
+ const h = {
11
+ components: {
12
+ URIProp: _,
13
+ URLProp: L,
14
+ StringProp: g,
15
+ SpecialProp: P,
16
+ MultilingualProp: f
17
+ },
18
+ props: {
19
+ profile: String,
20
+ data: Object,
21
+ property: String,
22
+ value: Object,
23
+ dpiLocale: String,
24
+ distId: Number,
25
+ type: String,
26
+ inHeader: String
27
+ },
28
+ computed: {
29
+ isSet() {
30
+ return S.propertyHasValue(this.data[this.property]);
31
+ }
32
+ }
33
+ }, I = {
34
+ key: 0,
35
+ class: "align-items-center"
36
+ }, s = {
37
+ key: 4,
38
+ class: "w-100"
39
+ }, H = { key: 0 }, b = { key: 1 }, x = { key: 2 };
40
+ function B(M, N, e, V, j, u) {
41
+ const d = l("URIProp"), c = l("URLProp"), y = l("StringProp"), p = l("MultilingualProp"), i = l("SpecialProp");
42
+ return t(), a("div", null, [
43
+ u.isSet ? (t(), a("tr", I, [
44
+ e.value.type === "singularURI" || e.value.type === "multiURI" || e.value.type === "singularURI" ? (t(), o(d, {
45
+ key: 0,
46
+ property: e.property,
47
+ value: e.value,
48
+ data: e.data,
49
+ inHeader: e.inHeader
50
+ }, null, 8, ["property", "value", "data", "inHeader"])) : r("", !0),
51
+ e.value.type === "singularURL" || e.value.type === "multiURL" ? (t(), o(c, {
52
+ key: 1,
53
+ property: e.property,
54
+ value: e.value,
55
+ data: e.data
56
+ }, null, 8, ["property", "value", "data"])) : r("", !0),
57
+ e.value.type === "singularString" || e.value.type === "multiString" ? (t(), o(y, {
58
+ key: 2,
59
+ property: e.property,
60
+ value: e.value,
61
+ data: e.data,
62
+ dpiLocale: e.dpiLocale
63
+ }, null, 8, ["property", "value", "data", "dpiLocale"])) : r("", !0),
64
+ e.value.type === "multiLingual" ? (t(), o(p, {
65
+ key: 3,
66
+ property: e.property,
67
+ value: e.value,
68
+ data: e.data,
69
+ dpiLocale: e.dpiLocale
70
+ }, null, 8, ["property", "value", "data", "dpiLocale"])) : r("", !0),
71
+ e.value.type === "special" ? (t(), a("div", s, [
72
+ e.property === "dct:publisher" || e.property === "dct:license" ? (t(), a("div", H, [
73
+ n(i, {
74
+ property: e.property,
75
+ value: e.value,
76
+ data: e.data,
77
+ dpiLocale: e.dpiLocale
78
+ }, null, 8, ["property", "value", "data", "dpiLocale"])
79
+ ])) : e.property != "dct:creator" && e.property != "dcat:temporalResolution" && e.property != "spdx:checksum" ? (t(), a("div", b, [
80
+ (t(!0), a(k, null, R(e.data[e.property], (m, v) => (t(), a("div", { key: v }, [
81
+ n(i, {
82
+ property: e.property,
83
+ value: e.value,
84
+ data: m,
85
+ dpiLocale: e.dpiLocale
86
+ }, null, 8, ["property", "value", "data", "dpiLocale"])
87
+ ]))), 128))
88
+ ])) : (t(), a("div", x, [
89
+ n(i, {
90
+ property: e.property,
91
+ value: e.value,
92
+ data: e.data[e.property],
93
+ dpiLocale: e.dpiLocale
94
+ }, null, 8, ["property", "value", "data", "dpiLocale"])
95
+ ]))
96
+ ])) : r("", !0)
97
+ ])) : r("", !0)
98
+ ]);
99
+ }
100
+ const G = /* @__PURE__ */ U(h, [["render", B]]);
101
+ export {
102
+ G as default
103
+ };
@@ -0,0 +1,189 @@
1
+ import g from "axios";
2
+ import { mapActions as w, mapGetters as d } from "vuex";
3
+ import y from "../components/LanguageSelector.vue.js";
4
+ import b from "./OverviewPage/DatasetOverview.vue.js";
5
+ import x from "./OverviewPage/CatalogueOverview.vue.js";
6
+ import { useIntersectionObserver as _ } from "@vueuse/core";
7
+ import { resolveComponent as n, createElementBlock as r, openBlock as o, Fragment as C, createElementVNode as s, createCommentVNode as c, createTextVNode as I, createVNode as k, toDisplayString as D, createBlock as f, createStaticVNode as L, useTemplateRef as O, ref as V, getCurrentInstance as A } from "vue";
8
+ /* empty css */
9
+ import E from "../../_virtual/_plugin-vue_export-helper.js";
10
+ const P = {
11
+ components: {
12
+ LanguageSelector: y,
13
+ DatasetOverview: b,
14
+ CatalogueOverview: x
15
+ },
16
+ props: {
17
+ property: {
18
+ type: String
19
+ },
20
+ context: {
21
+ type: Object
22
+ }
23
+ },
24
+ data() {
25
+ var e;
26
+ return {
27
+ instance: A().appContext.app.config.globalProperties.$env,
28
+ dpiLocale: ((e = this.$route.query) == null ? void 0 : e.locale) || this.$i18n.locale || this.$i18n.fallbackLocale || "en"
29
+ };
30
+ },
31
+ computed: {
32
+ ...d("auth", ["getIsEditMode"]),
33
+ ...d("dpiStore", ["getData"]),
34
+ showDatasetsOverview() {
35
+ return this.property === "datasets";
36
+ },
37
+ showCatalogsOverview() {
38
+ return this.property === "catalogues";
39
+ }
40
+ },
41
+ methods: {
42
+ ...w("dpiStore", ["clearAll", "saveLocalstorageValues"]),
43
+ clear() {
44
+ this.clearAll();
45
+ },
46
+ /*** Overview Page checker functionality ***/
47
+ // checkDatasetMandatory() {
48
+ // if (!JSON.parse(localStorage.getItem('dpi_mandatory'))['datasets']) {
49
+ // this.$router.push({
50
+ // name: 'DataProviderInterface-Input',
51
+ // params: {
52
+ // property: 'datasets',
53
+ // page: 'step1'
54
+ // },
55
+ // query: {
56
+ // error: 'mandatoryDataset',
57
+ // locale: this.$route.query.locale
58
+ // }
59
+ // });
60
+ // }
61
+ // },
62
+ // checkDistributionMandatory() {
63
+ // if (!JSON.parse(localStorage.getItem('dpi_mandatory'))['distributions'].length > 0 && !JSON.parse(localStorage.getItem('dpi_mandatory'))['distributions'].every(el => el === true)) {
64
+ // this.$router.push({
65
+ // name: 'DataProviderInterface-Input',
66
+ // path: '/dpi/datasets/distoverview',
67
+ // params: {
68
+ // property: 'datasets',
69
+ // page: 'distoverview',
70
+ // },
71
+ // query: {
72
+ // error: 'mandatoryDistribution',
73
+ // locale: this.$route.query.locale
74
+ // },
75
+ // });
76
+ // }
77
+ // },
78
+ // checkCatalogueMandatory() {
79
+ // if (!JSON.parse(localStorage.getItem('dpi_mandatory'))['catalogues']) {
80
+ // this.$router.push({
81
+ // name: 'DataProviderInterface-Input',
82
+ // params: {
83
+ // property: 'catalogues',
84
+ // page: 'step1'
85
+ // },
86
+ // query: {
87
+ // error: 'mandatoryCatalog',
88
+ // locale: this.$route.query.locale
89
+ // }
90
+ // });
91
+ // }
92
+ // },
93
+ checkID(e) {
94
+ this.getIsEditMode || this.checkUniqueID(e).then((t) => {
95
+ t || this.$router.push({
96
+ name: "DataProviderInterface-Input",
97
+ params: {
98
+ property: e,
99
+ page: "step1"
100
+ },
101
+ query: {
102
+ error: "id",
103
+ locale: this.$route.query.locale
104
+ }
105
+ });
106
+ });
107
+ },
108
+ checkUniqueID(e) {
109
+ return new Promise((t) => {
110
+ if (this.getData(e)["@id"] !== "") {
111
+ const i = `${this.$env.api.hubUrl}${e}/${this.getData(e)["@id"]}?useNormalizedId=true`;
112
+ g.head(i).then(() => {
113
+ t(!1);
114
+ }).catch(() => {
115
+ t(!0);
116
+ });
117
+ }
118
+ });
119
+ }
120
+ },
121
+ created() {
122
+ this.$nextTick(() => {
123
+ this.property, this.property;
124
+ });
125
+ },
126
+ setup() {
127
+ const e = O("overview-page"), t = V(!1);
128
+ return _(
129
+ e,
130
+ ([{ isIntersecting: i }]) => {
131
+ t.value = i;
132
+ },
133
+ {
134
+ rootMargin: "999999px 999999px 999999px 999999px"
135
+ }
136
+ ), { overviewPageIsVisible: t };
137
+ }
138
+ }, S = {
139
+ ref: "overview-page",
140
+ class: "col-12"
141
+ }, M = { class: "mt-5 mb-0" }, N = { class: "row" }, T = { class: "col-10" }, q = {
142
+ key: 0,
143
+ class: "mb-3"
144
+ }, B = {
145
+ key: 1,
146
+ class: "mb-3"
147
+ }, U = {
148
+ key: 0,
149
+ class: "legalnotice py-5",
150
+ style: { width: "90%", margin: "0 auto" }
151
+ };
152
+ function $(e, t, i, l, a, p) {
153
+ const u = n("LanguageSelector"), v = n("DatasetOverview"), h = n("CatalogueOverview");
154
+ return o(), r(C, null, [
155
+ s("div", S, [
156
+ s("div", M, [
157
+ s("div", N, [
158
+ s("div", T, [
159
+ I(D(e.$t("message.dataupload.info.selectDisplayLanguage")) + ": ", 1),
160
+ k(u, {
161
+ class: "ml-1",
162
+ modelValue: a.dpiLocale,
163
+ "onUpdate:modelValue": t[0] || (t[0] = (m) => a.dpiLocale = m)
164
+ }, null, 8, ["modelValue"])
165
+ ])
166
+ ])
167
+ ]),
168
+ p.showDatasetsOverview && l.overviewPageIsVisible ? (o(), r("div", q, [
169
+ (o(), f(v, {
170
+ dpiLocale: a.dpiLocale,
171
+ key: a.dpiLocale
172
+ }, null, 8, ["dpiLocale"]))
173
+ ])) : c("", !0),
174
+ p.showCatalogsOverview && l.overviewPageIsVisible ? (o(), r("div", B, [
175
+ (o(), f(h, {
176
+ dpiLocale: a.dpiLocale,
177
+ key: a.dpiLocale
178
+ }, null, 8, ["dpiLocale"]))
179
+ ])) : c("", !0)
180
+ ], 512),
181
+ a.instance.content.dataProviderInterface.annifIntegration ? (o(), r("div", U, t[1] || (t[1] = [
182
+ L('<div class="d-flex align-items-start" data-v-c1ff99c2><svg xmlns="http://www.w3.org/2000/svg" width="30px" height="30px" fill="currentColor" class="bi bi-info-circle mx-3 mb-3 mt-1 infoboxI" viewBox="0 0 16 16" data-v-c1ff99c2><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" data-v-c1ff99c2></path><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" data-v-c1ff99c2></path></svg><div class="w-80" data-v-c1ff99c2><p data-v-c1ff99c2> For <strong data-v-c1ff99c2>European</strong> <strong data-v-c1ff99c2>Commission&#39;s datasets</strong>, bear in mind that <a class="external-link" href="https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX:32011D0833" target="_blank" rel="nofollow noopener" data-v-c1ff99c2><ins data-v-c1ff99c2>Decision 2011/833/EU</ins></a> allows for their commercial reuse without prior authorisation, except for the material subject to the third party intellectual property rights. This Decision has been implemented under the <a class="external-link" href="https://ec.europa.eu/transparency/documents-register/detail?ref=C(2019)1655&amp;lang=en" target="_blank" rel="nofollow noopener" data-v-c1ff99c2><ins data-v-c1ff99c2>Decision C(2019) 1655 final</ins></a> by which Creative Commons Attribution 4.0 International Public License (CC BY 4.0) is adopted as an open licence for the Commission&#39;s reuse policy. Additionally, raw data, metadata or other documents of comparable nature may alternatively be distributed under the provisions of the Creative Commons Universal Public Domain Dedication deed (CC0 1.0). </p><p data-v-c1ff99c2> The <strong data-v-c1ff99c2>Council</strong> and the <strong data-v-c1ff99c2>European Court of Auditors</strong> have approved similar decisions on reuse. It is advisable that you check <strong data-v-c1ff99c2>the reuse policy of your organisation</strong> before publishing or submitting your dataset. </p></div></div><div class="d-flex align-items-start mt-4" data-v-c1ff99c2><svg xmlns="http://www.w3.org/2000/svg" width="30px" height="30px" fill="currentColor" class="bi bi-info-circle mx-3 mb-3 mt-1 infoboxI" viewBox="0 0 16 16" data-v-c1ff99c2><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" data-v-c1ff99c2></path><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" data-v-c1ff99c2></path></svg><div class="w-80" data-v-c1ff99c2><p data-v-c1ff99c2> As owner of your dataset, you guarantee that it does not violate the copyright, other intellectual property or privacy rights of any third party. In particular, if third party material is included in the dataset, you must ensure that all necessary permissions have been obtained and appropriate acknowledgment is given, if necessary. </p><p data-v-c1ff99c2> If you need further information regarding <strong data-v-c1ff99c2>licenses or copyright</strong> issues, please contact us at <span class="nobr" data-v-c1ff99c2><a class="external-link" href="mailto:op-copyright@publications.europa.eu" target="_blank" rel="nofollow noopener" data-v-c1ff99c2>op-copyright@publications.europa.eu</a></span></p></div></div>', 2)
183
+ ]))) : c("", !0)
184
+ ], 64);
185
+ }
186
+ const K = /* @__PURE__ */ E(P, [["render", $], ["__scopeId", "data-v-c1ff99c2"]]);
187
+ export {
188
+ K as default
189
+ };
@@ -0,0 +1,41 @@
1
+ import { defineComponent as d, createElementBlock as r, openBlock as n, createCommentVNode as s, createElementVNode as o, createTextVNode as i, Fragment as p, renderList as a, toDisplayString as m } from "vue";
2
+ import u from "../../_virtual/_plugin-vue_export-helper.js";
3
+ const f = d({
4
+ props: {
5
+ properties: {},
6
+ step: ""
7
+ },
8
+ data() {
9
+ return {
10
+ camel2title: (t) => t.replace(/([A-Z])/g, (e) => ` ${e}`).replace(/^./, (e) => e.toUpperCase()).trim()
11
+ };
12
+ }
13
+ }), h = { class: "propertyChooser" }, c = { key: 0 }, y = { key: 1 };
14
+ function g(t, e, k, v, b, w) {
15
+ return n(), r("div", h, [
16
+ t.step === "recommended" ? (n(), r("div", c, e[0] || (e[0] = [
17
+ o("h4", null, "Recommended properties", -1),
18
+ i(" The following properties are decribing recommended Informations regarding the dataset. If you'd like to display any of the properties in the following list, just klick them. You can also find information on them when you hover over the", -1),
19
+ o("div", { class: "infoI d-inline-block" }, null, -1),
20
+ i("symbol. ", -1)
21
+ ]))) : s("", !0),
22
+ t.step === "advised" ? (n(), r("div", y, e[1] || (e[1] = [
23
+ o("h4", null, "Advised properties", -1),
24
+ i(" The following properties are decribing advised Informations regarding the dataset. If you'd like to display any of the properties in the following list, just klick them. You can also find information on them when you hover over the", -1),
25
+ o("div", { class: "infoI d-inline-block" }, null, -1),
26
+ i("symbol. ", -1)
27
+ ]))) : s("", !0),
28
+ e[2] || (e[2] = o("hr", null, null, -1)),
29
+ o("ul", null, [
30
+ (n(!0), r(p, null, a(t.properties, (l) => (n(), r("li", {
31
+ key: l,
32
+ class: ""
33
+ }, m(t.camel2title(l.identifier)), 1))), 128))
34
+ ]),
35
+ e[3] || (e[3] = o("hr", null, null, -1))
36
+ ]);
37
+ }
38
+ const $ = /* @__PURE__ */ u(f, [["render", g]]);
39
+ export {
40
+ $ as default
41
+ };
@@ -0,0 +1,74 @@
1
+ import { getCurrentInstance as C, ref as v, computed as b, onMounted as y, createElementBlock as r, openBlock as n, createElementVNode as t, toDisplayString as l, Fragment as $, renderList as k, unref as D, createVNode as I, withCtx as q, createTextVNode as w } from "vue";
2
+ import { useStore as A } from "vuex";
3
+ import L from "../../widgets/AppLink.vue.js";
4
+ import M from "axios";
5
+ import { useRouter as N, useRoute as P } from "vue-router";
6
+ import { has as i, isNil as u } from "lodash-es";
7
+ /* empty css */
8
+ import U from "../../_virtual/_plugin-vue_export-helper.js";
9
+ const j = { class: "catOverview" }, x = { class: "d-flex flex-column bg-transparent container-fluid justify-content-between content" }, E = { class: "small-headline" }, Q = { class: "m-0" }, S = ["onClick"], V = {
10
+ __name: "UserCataloguesPage",
11
+ setup(B) {
12
+ const c = N(), d = P();
13
+ let p = C().appContext.app.config.globalProperties.$env;
14
+ const m = A();
15
+ let o = v([]), f = b(() => m.getters["auth/getUserCatalogIds"]), g = async () => {
16
+ let a;
17
+ await M.get(p.api.baseUrl + "search?filter=catalogue&limit=1000").then((e) => a = e).catch((e) => {
18
+ reject(e);
19
+ }), a.data.result.results.forEach((e) => {
20
+ i(e, "title") && !u(e.title) && i(e, "id") && !u(e.id) && o.value.push({ title: Object.values(e.title)[0], id: e.id });
21
+ }), o.value = o.value.filter((e) => f.value.includes(e.id)).map((e) => ({ id: e.id, name: e.title }));
22
+ };
23
+ const h = (a) => {
24
+ c.push({
25
+ name: "DataProviderInterface-MQASettings",
26
+ params: { id: a.id },
27
+ query: { locale: d.query.locale }
28
+ }).catch(() => {
29
+ });
30
+ };
31
+ return y(async () => {
32
+ g();
33
+ }), (a, e) => (n(), r("div", j, [
34
+ t("div", x, [
35
+ t("h1", E, l(a.$t("message.dataupload.info.userCatalogues")), 1),
36
+ t("p", Q, l(a.$t("message.dataupload.info.userCatDescription")), 1),
37
+ t("table", null, [
38
+ t("thead", null, [
39
+ t("tr", null, [
40
+ t("th", null, l(a.$t("message.metadata.catalog")) + " - ID", 1),
41
+ t("th", null, l(a.$t("message.metadata.description")), 1),
42
+ t("th", null, l(a.$t("message.dataupload.menu.actions")), 1)
43
+ ])
44
+ ]),
45
+ (n(!0), r($, null, k(D(o), (s, _) => (n(), r("tr", { key: _ }, [
46
+ t("td", null, [
47
+ I(L, {
48
+ to: { name: "CatalogueDetails", query: { locale: a.$route.query.locale }, params: { ctlg_id: s.id } }
49
+ }, {
50
+ default: q(() => [
51
+ w(l(s.id), 1)
52
+ ]),
53
+ _: 2
54
+ }, 1032, ["to"])
55
+ ]),
56
+ t("td", null, [
57
+ t("span", null, l(s.name), 1)
58
+ ]),
59
+ t("td", null, [
60
+ t("button", {
61
+ type: "button",
62
+ class: "btn btn-action",
63
+ onClick: (O) => h(s)
64
+ }, "Configure MQA report ", 8, S)
65
+ ])
66
+ ]))), 128))
67
+ ])
68
+ ])
69
+ ]));
70
+ }
71
+ }, W = /* @__PURE__ */ U(V, [["__scopeId", "data-v-7d69041b"]]);
72
+ export {
73
+ W as default
74
+ };
@@ -0,0 +1,83 @@
1
+ import { mapGetters as c } from "vuex";
2
+ import { createElementBlock as r, openBlock as o, createElementVNode as e, createCommentVNode as d, createTextVNode as l, toDisplayString as i, Fragment as u, renderList as p, getCurrentInstance as m } from "vue";
3
+ /* empty css */
4
+ import f from "../../_virtual/_plugin-vue_export-helper.js";
5
+ const _ = {
6
+ name: "DataProviderInterface-UserProfile",
7
+ // props: [],
8
+ // data() {
9
+ // return {
10
+ // values: {},
11
+ // };
12
+ // },
13
+ data() {
14
+ return {
15
+ // Need to assign the URL for userProfileDashboardUrl in the config files.
16
+ userProfileDashboardUrl: m().appContext.app.config.globalProperties.$env.content.dataProviderInterface.userProfileDashboardUrl || ""
17
+ };
18
+ },
19
+ computed: {
20
+ ...c("auth", [
21
+ "getUserName",
22
+ "getUserData"
23
+ ])
24
+ }
25
+ // methods: {},
26
+ // created() { },
27
+ }, g = { class: "d-flex flex-column bg-transparent container-fluid justify-content-between content" }, h = { class: "panel-body inf-content" }, b = { class: "row" }, y = { class: "col-md-12" }, v = { class: "table-responsive" }, P = { class: "table table-user-information" }, U = { class: "text-primary value-column" }, x = { class: "text-primary value-column" }, D = { key: 0 }, k = { class: "text-primary value-column" }, I = ["href"];
28
+ function N(n, t, C, E, a, V) {
29
+ return o(), r("div", g, [
30
+ t[3] || (t[3] = e("h1", { class: "small-headline dataset-details-title" }, "My Profile", -1)),
31
+ e("div", h, [
32
+ e("div", b, [
33
+ e("div", y, [
34
+ e("div", v, [
35
+ e("table", P, [
36
+ e("tbody", null, [
37
+ e("tr", null, [
38
+ t[0] || (t[0] = e("td", { class: "label-column" }, [
39
+ e("strong", null, [
40
+ e("span", { class: "glyphicon glyphicon-user text-primary" }),
41
+ l(" User ID: ")
42
+ ])
43
+ ], -1)),
44
+ e("td", U, i(n.getUserName), 1)
45
+ ]),
46
+ e("tr", null, [
47
+ t[1] || (t[1] = e("td", { class: "label-column" }, [
48
+ e("strong", null, [
49
+ e("span", { class: "glyphicon glyphicon-user text-primary" }),
50
+ l(" Roles: ")
51
+ ])
52
+ ], -1)),
53
+ e("td", x, [
54
+ (o(!0), r(u, null, p(n.getUserData.roles.filter((s) => !s.startsWith("default-roles") && !["offline_access", "uma_authorization"].includes(s)), (s) => (o(), r("p", { key: s }, i(s), 1))), 128))
55
+ ])
56
+ ]),
57
+ a.userProfileDashboardUrl ? (o(), r("tr", D, [
58
+ t[2] || (t[2] = e("td", { class: "label-column" }, [
59
+ e("strong", null, [
60
+ e("span", { class: "glyphicon glyphicon-user text-primary" }),
61
+ l(" User Profile: ")
62
+ ])
63
+ ], -1)),
64
+ e("td", k, [
65
+ e("a", {
66
+ href: a.userProfileDashboardUrl,
67
+ target: "_blank",
68
+ class: "btn btn-link"
69
+ }, "Edit Profile", 8, I)
70
+ ])
71
+ ])) : d("", !0)
72
+ ])
73
+ ])
74
+ ])
75
+ ])
76
+ ])
77
+ ])
78
+ ]);
79
+ }
80
+ const z = /* @__PURE__ */ f(_, [["render", N], ["__scopeId", "data-v-42311d9f"]]);
81
+ export {
82
+ z as default
83
+ };
@@ -0,0 +1,39 @@
1
+ import n from "dayjs";
2
+ const i = "", f = {
3
+ setLocale(r = "en", t = {}) {
4
+ n.locale("en");
5
+ },
6
+ /**
7
+ * @description Transforms the given date into a US Date Format String
8
+ * @param {date} date - The given date
9
+ * @returns {String}
10
+ */
11
+ formatUS(r) {
12
+ if (r === void 0) return i;
13
+ const t = n(String(r)), o = r.split("T");
14
+ return t.isValid() ? o.length === 1 ? t.format("MM/DD/YYYY") : t.format("MM/DD/YYYY HH:mm") : i;
15
+ },
16
+ /**
17
+ * @description Transforms the given date into a US Date Format String
18
+ * @param {date} date - The given date
19
+ * @returns {String}
20
+ */
21
+ formatEU(r) {
22
+ if (String(r)[0] === "_" && (r = String(r).replace("_", "")), r === void 0) return i;
23
+ const t = n(String(r)), o = r.split("T");
24
+ return t.isValid() ? o.length === 1 ? t.format("DD.MM.YYYY") : t.format("DD MMMM YYYY") : i;
25
+ },
26
+ /**
27
+ * @description Returns a String representing the expired time from the given date to now.
28
+ * @param {date} date - The given date
29
+ * @returns {String}
30
+ */
31
+ fromNow(r) {
32
+ if (r === void 0) return i;
33
+ const t = n(String(r));
34
+ return t.isValid() ? t.fromNow : i;
35
+ }
36
+ };
37
+ export {
38
+ f as default
39
+ };
@@ -0,0 +1,55 @@
1
+ import { token as l } from "@formkit/utils";
2
+ import { resolveComponent as m, createElementBlock as s, openBlock as i, Fragment as d, renderList as p, normalizeClass as u, createElementVNode as o, toDisplayString as h, renderSlot as _, createVNode as f } from "vue";
3
+ /* empty css */
4
+ import k from "../_virtual/_plugin-vue_export-helper.js";
5
+ const v = {
6
+ props: {
7
+ name: String,
8
+ children: Array,
9
+ context: Object
10
+ },
11
+ data() {
12
+ return {
13
+ values: [],
14
+ items: [this.newId()],
15
+ camel2title: (t) => t.replace(/([A-Z])/g, (e) => ` ${e}`).replace(/^./, (e) => e.toUpperCase()).trim()
16
+ };
17
+ },
18
+ methods: {
19
+ newId() {
20
+ return `${this.name}_${l()}`;
21
+ },
22
+ addItem() {
23
+ this.items.push(this.newId());
24
+ },
25
+ removeItem(t) {
26
+ const e = t.target.getAttribute("data-key"), r = this.items.indexOf(e);
27
+ r >= 0 && this.items.splice(r, 1);
28
+ }
29
+ }
30
+ }, x = { class: "horizontal-wrapper" }, g = { class: "formkitCmpWrap w-100" }, w = { class: "formkitWrapRepeatable" };
31
+ function y(t, e, r, b, n, I) {
32
+ const a = m("FormKit");
33
+ return i(!0), s(d, null, p(n.items, (c) => (i(), s("div", {
34
+ class: u(["formkitProperty", [r.context.attrs.identifier]]),
35
+ key: c
36
+ }, [
37
+ o("h4", null, h(r.context.label), 1),
38
+ o("div", x, [
39
+ o("div", g, [
40
+ o("div", w, [
41
+ _(t.$slots, "default", {}, () => [
42
+ f(a, {
43
+ "outer-class": "w-100",
44
+ placeholder: "Please provide a number"
45
+ })
46
+ ])
47
+ ])
48
+ ])
49
+ ])
50
+ ], 2))), 128);
51
+ }
52
+ const K = /* @__PURE__ */ k(v, [["render", y]]);
53
+ export {
54
+ K as default
55
+ };
@@ -0,0 +1,7 @@
1
+ import o from "./Repeatable.vue2.js";
2
+ /* empty css */
3
+ import t from "../_virtual/_plugin-vue_export-helper.js";
4
+ const r = /* @__PURE__ */ t(o, [["__scopeId", "data-v-49be454c"]]);
5
+ export {
6
+ r as default
7
+ };
@@ -0,0 +1,72 @@
1
+ import { defineComponent as $, ref as _, resolveComponent as x, createElementBlock as i, openBlock as l, Fragment as N, renderList as R, normalizeClass as h, createElementVNode as n, toDisplayString as r, createVNode as S, withCtx as g, renderSlot as B } from "vue";
2
+ import { whenever as O } from "@vueuse/core";
3
+ const z = { key: 0 }, D = { key: 1 }, E = { class: "horizontal-wrapper" }, J = { class: "repeatableWrap" }, W = { class: "interactionHeaderRepeatable my-1" }, j = ["onClick"], F = ["onClick", "data-key"], H = { class: "formkitWrapRepeatable" }, q = /* @__PURE__ */ $({
4
+ __name: "Repeatable",
5
+ props: {
6
+ context: Object
7
+ },
8
+ setup(k) {
9
+ const t = k, a = _([{ value: "init", nonce: 0 }]), c = _(0);
10
+ O(() => {
11
+ var e;
12
+ return (e = t.context) == null ? void 0 : e.value;
13
+ }, (e, o) => {
14
+ JSON.stringify(e) !== JSON.stringify(o) && (!e || e.length === 0 ? a.value = [{ value: "init", nonce: 0 }] : a.value = e.filter(Boolean).map((s, d) => ({ value: s["@value"] ?? s.name ?? s, nonce: d })), c.value = a.value.length);
15
+ }, {
16
+ immediate: !1
17
+ });
18
+ const b = (e) => {
19
+ var o;
20
+ a.value.push({ item: (o = t.context) == null ? void 0 : o.value[e]["@value"], nonce: c.value }), c.value += 1;
21
+ }, y = (e, o) => {
22
+ o != 1 && a.value.splice(e, 1);
23
+ };
24
+ return (e, o) => {
25
+ const s = x("i18n-t");
26
+ return l(!0), i(N, null, R(a.value, ({ item: d, nonce: C }, p) => {
27
+ var v, m, f;
28
+ return l(), i("div", {
29
+ class: h(["repeatable formkitProperty", [(v = t.context) == null ? void 0 : v.attrs.identifier]]),
30
+ key: `${C}`
31
+ }, [
32
+ (m = t.context) != null && m.attrs.class && t.context.attrs.class.includes("inDistribution") ? (l(), i("h4", z, r(e.$t("message.dataupload.distributions." + t.context.attrs.identifier + ".label")), 1)) : (l(), i("h4", D, r(e.$t("message.dataupload.datasets." + ((f = t.context) == null ? void 0 : f.attrs.identifier) + ".label")), 1)),
33
+ n("div", E, [
34
+ n("div", J, [
35
+ n("div", W, [
36
+ S(s, {
37
+ keypath: "message.dataupload.info.repeatable",
38
+ scope: "global",
39
+ tag: "p"
40
+ }, {
41
+ add: g(() => [
42
+ n("a", {
43
+ class: "add",
44
+ onClick: (u) => b(p)
45
+ }, "+ " + r(e.$t("message.dataupload.info.add")), 9, j)
46
+ ]),
47
+ remove: g(() => {
48
+ var u;
49
+ return [
50
+ n("a", {
51
+ class: h(["remove", { disabledRemove: ((u = t.context) == null ? void 0 : u.value.length) === 1 }]),
52
+ onClick: (I) => y(p, a.value.length),
53
+ "data-key": d
54
+ }, "- " + r(e.$t("message.dataupload.info.remove")), 11, F)
55
+ ];
56
+ }),
57
+ _: 2
58
+ }, 1024)
59
+ ]),
60
+ n("div", H, [
61
+ B(e.$slots, "default", {}, void 0, !0)
62
+ ])
63
+ ])
64
+ ])
65
+ ], 2);
66
+ }), 128);
67
+ };
68
+ }
69
+ });
70
+ export {
71
+ q as default
72
+ };