@piveau/dpi 0.1.0-beta.5 → 0.1.0-beta.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.
- package/dist/assets/dpi.css +1 -1
- package/dist/data-provider-interface/DataProviderInterface.vue2.js +45 -40
- package/dist/data-provider-interface/HappyFlowComponents/HomeTable.vue.js +15 -15
- package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/AdditionalsSubModal.vue.js +15 -14
- package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/DistributionModal.vue.js +73 -32
- package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/FindabilityChips.vue.js +26 -24
- package/dist/data-provider-interface/HappyFlowComponents/ui/SectionItems/HVDSwitch.vue.js +23 -22
- package/dist/data-provider-interface/HappyFlowComponents/ui/TableRowV3.vue.js +88 -85
- package/dist/data-provider-interface/components/DistributionSimplePage.vue.js +382 -382
- package/dist/data-provider-interface/components/ReviewAndPublishPage.vue.js +183 -174
- package/dist/data-provider-interface/composables/useDpiContext.js +5 -7
- package/dist/data-provider-interface/composables/useDpiEditMode.js +15 -13
- package/dist/data-provider-interface/composables/useDpiSimpleLoader.js +7 -7
- package/dist/data-provider-interface/store/index.js +32 -0
- package/dist/data-provider-interface/store/modules/authStore.js +301 -0
- package/dist/data-provider-interface/store/modules/catalogueDetailsStore.js +34 -0
- package/dist/data-provider-interface/store/modules/cataloguesStore.js +256 -0
- package/dist/data-provider-interface/store/modules/datasetDetailsStore.js +644 -0
- package/dist/data-provider-interface/store/modules/datasetsStore.js +361 -0
- package/dist/data-provider-interface/store/{dpiStore.js → modules/dpiStore.js} +11 -12
- package/dist/data-provider-interface/store/modules/snackbarStore.js +45 -0
- package/dist/data-provider-interface/views/InputPage.vue.js +100 -99
- package/dist/index.js +4 -4
- package/dist/utils/draftApi.js +33 -0
- package/dist/utils/helpers.js +36 -22
- package/dist/utils/identifiersApi.js +16 -0
- package/dist/utils/jwt.js +7 -0
- package/package.json +6 -4
- package/dist/data-provider-interface/store/modules/formSchemaStore.js +0 -94
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@piveau/dpi",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.1.0-beta.
|
|
4
|
+
"version": "0.1.0-beta.7",
|
|
5
5
|
"private": false,
|
|
6
6
|
"sideEffects": [
|
|
7
7
|
"*.css"
|
|
@@ -37,10 +37,10 @@
|
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
39
|
"@antfu/eslint-config": "^4.19.0",
|
|
40
|
-
"@formkit/core": "^1",
|
|
41
|
-
"@formkit/themes": "^1",
|
|
40
|
+
"@formkit/core": "^1.6.9",
|
|
41
|
+
"@formkit/themes": "^1.6.9",
|
|
42
42
|
"@formkit/utils": "^1.6.9",
|
|
43
|
-
"@formkit/vue": "^1",
|
|
43
|
+
"@formkit/vue": "^1.6.9",
|
|
44
44
|
"@headlessui/vue": "^1.7.23",
|
|
45
45
|
"@histoire/plugin-vue": "1.0.0-alpha.2",
|
|
46
46
|
"@phosphor-icons/vue": "^2.2.1",
|
|
@@ -48,6 +48,7 @@
|
|
|
48
48
|
"@popperjs/core": "^2.11.8",
|
|
49
49
|
"@types/jsonld": "^1.5.15",
|
|
50
50
|
"@types/node": "^24.1.0",
|
|
51
|
+
"@vee-validate/zod": "^4.15.1",
|
|
51
52
|
"@vitejs/plugin-vue": "^5.2.3",
|
|
52
53
|
"@vue/tsconfig": "^0.7.0",
|
|
53
54
|
"@vueuse/core": "^10.11.1",
|
|
@@ -63,6 +64,7 @@
|
|
|
63
64
|
"qs": "^6.14.0",
|
|
64
65
|
"sass": "^1.89.2",
|
|
65
66
|
"typescript": "~5.8.3",
|
|
67
|
+
"vee-validate": "^4.15.1",
|
|
66
68
|
"vite": "^6.3.5",
|
|
67
69
|
"vite-plugin-dts": "^4.5.4",
|
|
68
70
|
"vite-plugin-lib-inject-css": "^2.2.2",
|
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
import { isEmpty as l } from "lodash-es";
|
|
2
|
-
import r from "../../utils/translation-helper.js";
|
|
3
|
-
const m = {
|
|
4
|
-
schema: {
|
|
5
|
-
datasets: {},
|
|
6
|
-
distributions: {},
|
|
7
|
-
catalogues: {}
|
|
8
|
-
},
|
|
9
|
-
usersCatalogs: {}
|
|
10
|
-
}, h = {
|
|
11
|
-
getSchema: (e) => (t) => (console.log(e.schema[t]), e.schema[t])
|
|
12
|
-
}, d = {
|
|
13
|
-
/**
|
|
14
|
-
* Commits page properties and related DCATAP property definitions for current view for later building of schema
|
|
15
|
-
* @param {Object} param0
|
|
16
|
-
* @param {Object} param1 Object containing property (datasets/catalogues), page (step1/step2/step3) and subpage (distribution1/distribution2/distribution3) of current view
|
|
17
|
-
*/
|
|
18
|
-
createSchema({ commit: e, state: t, rootGetters: a }, { property: n, page: c }) {
|
|
19
|
-
const s = a["dpiStore/getSpecification"], o = s.pageConent[n][c], i = s.inputDefinition[n];
|
|
20
|
-
e("extractSchema", { pageProperties: o, propertyDefinitions: i, property: n, page: c });
|
|
21
|
-
},
|
|
22
|
-
/**
|
|
23
|
-
* Calls mutation function for translating translatable properties of schema
|
|
24
|
-
* @param {*} param0
|
|
25
|
-
*/
|
|
26
|
-
translateSchema({ commit: e }, { property: t, page: a }) {
|
|
27
|
-
e("translateSchemaProperties", { property: t, page: a });
|
|
28
|
-
},
|
|
29
|
-
/**
|
|
30
|
-
* Commits current property and users catalogs to mutation function
|
|
31
|
-
* @param {*} param0
|
|
32
|
-
* @param {*} param1 Object containing curren tproperty (datasets/catalogues) and all catalog options the user has permissions for
|
|
33
|
-
*/
|
|
34
|
-
addCatalogOptions({ commit: e }, { property: t, catalogs: a }) {
|
|
35
|
-
e("saveCatalogOptions", { property: t, catalogs: a });
|
|
36
|
-
}
|
|
37
|
-
}, f = {
|
|
38
|
-
/**
|
|
39
|
-
* Builds schema based on given pageProperties and their definitions provided by propertyDefinition
|
|
40
|
-
* @param {Object} state
|
|
41
|
-
* @param {Object} param1 Object containing the properties which should be displayed within the view
|
|
42
|
-
* (pageProperties) and the form definitions of the properties defined by DCATAP (propertyDefinition)
|
|
43
|
-
*/
|
|
44
|
-
extractSchema(e, { pageProperties: t, propertyDefinitions: a, property: n, page: c }) {
|
|
45
|
-
const s = [];
|
|
46
|
-
for (let o = 0; o < t.length; o += 1) {
|
|
47
|
-
const i = t[o];
|
|
48
|
-
try {
|
|
49
|
-
s.push(a[i]);
|
|
50
|
-
} catch {
|
|
51
|
-
console.warn(`DCATAP doens't include a property called: ${i}`);
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
e.schema[n][c] = s;
|
|
55
|
-
},
|
|
56
|
-
/**
|
|
57
|
-
* All translatable properties within the existing schema will be translated and added to the schema
|
|
58
|
-
* @param {*} state
|
|
59
|
-
* @param {String} property String defining current property (datasets/ distribution/ catalogues)
|
|
60
|
-
*/
|
|
61
|
-
translateSchemaProperties(e, { property: t, page: a }) {
|
|
62
|
-
r(e.schema[t][a], t);
|
|
63
|
-
},
|
|
64
|
-
/**
|
|
65
|
-
* Saves all catalogs the current user has permissions for as options within the schema
|
|
66
|
-
* @param {*} state
|
|
67
|
-
* @param {*} param1 Object containing current property and the users catalog options
|
|
68
|
-
*/
|
|
69
|
-
saveCatalogOptions(e, { property: t, catalogs: a }) {
|
|
70
|
-
if (t === "datasets") {
|
|
71
|
-
let n;
|
|
72
|
-
for (let c in e.schema[t]) {
|
|
73
|
-
const s = e.schema[t][c].filter((o) => o.name === "dcat:catalog");
|
|
74
|
-
l(s) || (n = s[0]);
|
|
75
|
-
}
|
|
76
|
-
if (!l(n)) {
|
|
77
|
-
const c = {};
|
|
78
|
-
for (let s = 0; s < a.length; s += 1) {
|
|
79
|
-
const o = a[s];
|
|
80
|
-
c[o] = o;
|
|
81
|
-
}
|
|
82
|
-
n.options = c;
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
}, p = {
|
|
87
|
-
state: m,
|
|
88
|
-
getters: h,
|
|
89
|
-
actions: d,
|
|
90
|
-
mutations: f
|
|
91
|
-
};
|
|
92
|
-
export {
|
|
93
|
-
p as default
|
|
94
|
-
};
|