@datagouv/components-next 0.0.32 → 0.1.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/README.md +5 -15
- package/assets/labels/hvd.svg +15 -0
- package/assets/labels/inspire.svg +20 -0
- package/assets/labels/sl.svg +5 -0
- package/assets/labels/spd.svg +5 -0
- package/assets/labels/sr.svg +5 -0
- package/dist/JsonPreview.client-NQ9byxF5.js +92 -0
- package/dist/{MapContainer.client-Dhfz-YU8.js → MapContainer.client-D7Y0OXMU.js} +17587 -6826
- package/dist/{PdfPreview.client--W0FK7CN.js → PdfPreview.client-DU6FbUh0.js} +47 -48
- package/dist/{Pmtiles.client-B6vRTwrm.js → Pmtiles.client-DCOxft6M.js} +7609 -7503
- package/dist/Swagger.client-DTHhEAFT.js +4 -0
- package/dist/XmlPreview.client-BEOCeCP8.js +84 -0
- package/dist/components-next.css +6 -6
- package/dist/components-next.js +95 -80
- package/dist/components.css +2 -2
- package/dist/en-CuSmdvir.js +30 -0
- package/dist/hvd-DYeke1vM.js +4 -0
- package/dist/inspire-BLXeJvob.js +4 -0
- package/dist/{main-yWiuApVL.js → main-DFEQrdg5.js} +53395 -55984
- package/dist/{pdf-vue3-Dm2ZCc3P.js → pdf-vue3-IkJO65RH.js} +2 -2
- package/dist/{pdf.min-f72cfa08-DAetWL3M.js → pdf.min-f72cfa08-CdgJTooZ.js} +78 -78
- package/dist/sl-VR8Tb1_u.js +4 -0
- package/dist/spd-BJ-Omhgt.js +4 -0
- package/dist/sr-DjSF-8xW.js +4 -0
- package/dist/{text-clamp.esm-Mb7Qdtu9.js → text-clamp.esm-B5kW_XMt.js} +54 -55
- package/dist/{vue3-json-viewer-B1fiyuLU.js → vue3-json-viewer-BXwup7nO.js} +88 -93
- package/dist/{vue3-xml-viewer.common-1QyofKqS.js → vue3-xml-viewer.common-RC76oYFu.js} +54 -54
- package/package.json +12 -11
- package/src/components/ActivityList/ActivityList.vue +159 -0
- package/src/components/ActivityList/UserActivityList.vue +30 -0
- package/src/components/AppLink.vue +3 -3
- package/src/components/Avatar.vue +1 -0
- package/src/components/DataserviceCard.vue +3 -3
- package/src/components/DatasetCard.vue +19 -18
- package/src/components/DatasetInformationPanel.vue +16 -16
- package/src/components/DatasetLabelTag.vue +40 -0
- package/src/components/DatasetQuality.vue +13 -10
- package/src/components/DatasetQualityInline.vue +5 -2
- package/src/components/DatasetQualityScore.vue +3 -3
- package/src/components/DatasetQualityTooltipContent.vue +2 -2
- package/src/components/DateRangeDetails.vue +7 -3
- package/src/components/ExtraAccordion.vue +3 -1
- package/src/components/OrganizationNameWithCertificate.vue +2 -2
- package/src/components/PaddedContainer.vue +28 -0
- package/src/components/Pagination.vue +2 -2
- package/src/components/Placeholder.vue +1 -1
- package/src/components/ReadMore.vue +17 -17
- package/src/components/ResourceAccordion/DataStructure.vue +8 -3
- package/src/components/ResourceAccordion/EditButton.vue +2 -2
- package/src/components/ResourceAccordion/JsonPreview.client.vue +7 -5
- package/src/components/ResourceAccordion/MapContainer.client.vue +2 -2
- package/src/components/ResourceAccordion/Metadata.vue +10 -10
- package/src/components/ResourceAccordion/PdfPreview.client.vue +7 -5
- package/src/components/ResourceAccordion/Pmtiles.client.vue +2 -2
- package/src/components/ResourceAccordion/Preview.vue +2 -2
- package/src/components/ResourceAccordion/ResourceAccordion.vue +23 -15
- package/src/components/ResourceAccordion/SchemaBadge.vue +4 -4
- package/src/components/ResourceAccordion/XmlPreview.client.vue +7 -5
- package/src/components/ReuseCard.vue +3 -3
- package/src/components/ReuseDetails.vue +2 -2
- package/src/components/SmallChart.vue +33 -30
- package/src/components/StatBox.vue +6 -6
- package/src/components/Toggletip.vue +0 -1
- package/src/components/TranslationT.vue +51 -0
- package/src/composables/useTranslation.ts +169 -0
- package/src/functions/activities.ts +36 -0
- package/src/functions/api.ts +4 -4
- package/src/functions/datasets.ts +28 -0
- package/src/functions/dates.ts +4 -4
- package/src/functions/helpers.ts +3 -3
- package/src/functions/organizations.ts +2 -2
- package/src/functions/pagination.ts +9 -0
- package/src/functions/resources.ts +2 -2
- package/src/functions/reuses.ts +3 -3
- package/src/main.ts +24 -20
- package/src/types/activity.ts +24 -0
- package/src/types/api.ts +8 -0
- package/src/types/badges.ts +4 -0
- package/src/types/dataservices.ts +6 -8
- package/src/types/datasets.ts +2 -1
- package/src/types/site.ts +1 -0
- package/src/types/topics.ts +17 -2
- package/dist/JsonPreview.client-BRhCOHlE.js +0 -93
- package/dist/Swagger.client-ch5H8aT2.js +0 -4
- package/dist/XmlPreview.client-BcbnRWAp.js +0 -85
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { g as Ke } from "./main-
|
|
1
|
+
import { g as Ke } from "./main-DFEQrdg5.js";
|
|
2
2
|
import We from "vue";
|
|
3
3
|
function Fe(I, K) {
|
|
4
4
|
for (var V = 0; V < K.length; V++) {
|
|
@@ -18,94 +18,94 @@ function Fe(I, K) {
|
|
|
18
18
|
}
|
|
19
19
|
var Y = { exports: {} }, ee;
|
|
20
20
|
function ze() {
|
|
21
|
-
return ee || (ee = 1, function(I) {
|
|
21
|
+
return ee || (ee = 1, (function(I) {
|
|
22
22
|
(function() {
|
|
23
23
|
var K = {
|
|
24
24
|
/***/
|
|
25
25
|
118: (
|
|
26
26
|
/***/
|
|
27
|
-
function(_, a, e) {
|
|
27
|
+
(function(_, a, e) {
|
|
28
28
|
e.r(a);
|
|
29
29
|
var t = e(246), n = /* @__PURE__ */ e.n(t), r = e(143), u = /* @__PURE__ */ e.n(r), l = u()(n());
|
|
30
30
|
l.push([_.id, ".no-margin-padding[data-v-3c430bce]{margin:0;padding:0}.margin-left-sm[data-v-3c430bce]{margin-left:8px}.assignment[data-v-3c430bce]{color:var(--xml-viewer-assignment-color)}.quote[data-v-3c430bce]{color:var(--xml-viewer-quote-color)}", ""]), a.default = l;
|
|
31
|
-
}
|
|
31
|
+
})
|
|
32
32
|
),
|
|
33
33
|
/***/
|
|
34
34
|
743: (
|
|
35
35
|
/***/
|
|
36
|
-
function(_, a, e) {
|
|
36
|
+
(function(_, a, e) {
|
|
37
37
|
e.r(a);
|
|
38
38
|
var t = e(246), n = /* @__PURE__ */ e.n(t), r = e(143), u = /* @__PURE__ */ e.n(r), l = u()(n());
|
|
39
39
|
l.push([_.id, ".attribute-name[data-v-17010745]{color:var(--xml-viewer-attribute-name-color)}", ""]), a.default = l;
|
|
40
|
-
}
|
|
40
|
+
})
|
|
41
41
|
),
|
|
42
42
|
/***/
|
|
43
43
|
102: (
|
|
44
44
|
/***/
|
|
45
|
-
function(_, a, e) {
|
|
45
|
+
(function(_, a, e) {
|
|
46
46
|
e.r(a);
|
|
47
47
|
var t = e(246), n = /* @__PURE__ */ e.n(t), r = e(143), u = /* @__PURE__ */ e.n(r), l = u()(n());
|
|
48
48
|
l.push([_.id, ".attribute-value[data-v-36c46cbc]{color:var(--xml-viewer-attribute-value-color);padding:0;margin:0}", ""]), a.default = l;
|
|
49
|
-
}
|
|
49
|
+
})
|
|
50
50
|
),
|
|
51
51
|
/***/
|
|
52
52
|
80: (
|
|
53
53
|
/***/
|
|
54
|
-
function(_, a, e) {
|
|
54
|
+
(function(_, a, e) {
|
|
55
55
|
e.r(a);
|
|
56
56
|
var t = e(246), n = /* @__PURE__ */ e.n(t), r = e(143), u = /* @__PURE__ */ e.n(r), l = u()(n());
|
|
57
57
|
l.push([_.id, ".content[data-v-0fce587a]{color:var(--xml-viewer-cdata-content-color)}.inline[data-v-0fce587a]{display:inline}.no-margin-padding[data-v-0fce587a]{margin:0;padding:0}", ""]), a.default = l;
|
|
58
|
-
}
|
|
58
|
+
})
|
|
59
59
|
),
|
|
60
60
|
/***/
|
|
61
61
|
722: (
|
|
62
62
|
/***/
|
|
63
|
-
function(_, a, e) {
|
|
63
|
+
(function(_, a, e) {
|
|
64
64
|
e.r(a);
|
|
65
65
|
var t = e(246), n = /* @__PURE__ */ e.n(t), r = e(143), u = /* @__PURE__ */ e.n(r), l = u()(n());
|
|
66
66
|
l.push([_.id, ".xml-element[data-v-d071a178]{white-space:nowrap;font-size:14px;font-family:Consolas,Menlo,Courier,monospace}.bracket[data-v-d071a178],.caret[data-v-d071a178],.dots[data-v-d071a178]{color:var(--xml-viewer-bracket-color)}.caret[data-v-d071a178]{fill:var(--xml-viewer-bracket-color)}.child-elements>div[data-v-d071a178]{margin-left:20px}.clickable[data-v-d071a178]{cursor:pointer}", ""]), a.default = l;
|
|
67
|
-
}
|
|
67
|
+
})
|
|
68
68
|
),
|
|
69
69
|
/***/
|
|
70
70
|
715: (
|
|
71
71
|
/***/
|
|
72
|
-
function(_, a, e) {
|
|
72
|
+
(function(_, a, e) {
|
|
73
73
|
e.r(a);
|
|
74
74
|
var t = e(246), n = /* @__PURE__ */ e.n(t), r = e(143), u = /* @__PURE__ */ e.n(r), l = u()(n());
|
|
75
75
|
l.push([_.id, ".content[data-v-75f773a5]{color:var(--xml-viewer-element-content-color)}", ""]), a.default = l;
|
|
76
|
-
}
|
|
76
|
+
})
|
|
77
77
|
),
|
|
78
78
|
/***/
|
|
79
79
|
204: (
|
|
80
80
|
/***/
|
|
81
|
-
function(_, a, e) {
|
|
81
|
+
(function(_, a, e) {
|
|
82
82
|
e.r(a);
|
|
83
83
|
var t = e(246), n = /* @__PURE__ */ e.n(t), r = e(143), u = /* @__PURE__ */ e.n(r), l = u()(n());
|
|
84
84
|
l.push([_.id, ".bracket[data-v-5a0ac6a5]{color:var(--xml-viewer-bracket-color)}.element-name[data-v-5a0ac6a5]{color:var(--xml-viewer-element-name-color)}", ""]), a.default = l;
|
|
85
|
-
}
|
|
85
|
+
})
|
|
86
86
|
),
|
|
87
87
|
/***/
|
|
88
88
|
904: (
|
|
89
89
|
/***/
|
|
90
|
-
function(_, a, e) {
|
|
90
|
+
(function(_, a, e) {
|
|
91
91
|
e.r(a);
|
|
92
92
|
var t = e(246), n = /* @__PURE__ */ e.n(t), r = e(143), u = /* @__PURE__ */ e.n(r), l = u()(n());
|
|
93
93
|
l.push([_.id, ".content[data-v-7bc574c6]{color:var(--xml-viewer-remark-content-color)}.inline[data-v-7bc574c6]{display:inline}.no-margin-padding[data-v-7bc574c6]{margin:0;padding:0}", ""]), a.default = l;
|
|
94
|
-
}
|
|
94
|
+
})
|
|
95
95
|
),
|
|
96
96
|
/***/
|
|
97
97
|
834: (
|
|
98
98
|
/***/
|
|
99
|
-
function(_, a, e) {
|
|
99
|
+
(function(_, a, e) {
|
|
100
100
|
e.r(a);
|
|
101
101
|
var t = e(246), n = /* @__PURE__ */ e.n(t), r = e(143), u = /* @__PURE__ */ e.n(r), l = u()(n());
|
|
102
102
|
l.push([_.id, ":root{--xml-viewer-bracket-color:#111;--xml-viewer-assignment-color:#986801;--xml-viewer-quote-color:#50a14f;--xml-viewer-attribute-name-color:#986801;--xml-viewer-attribute-value-color:#50a14f;--xml-viewer-cdata-content-color:#50a14f;--xml-viewer-element-content-color:#383a42;--xml-viewer-element-name-color:#e45649;--xml-viewer-remark-content-color:#a0a1a7}.dark{--xml-viewer-bracket-color:#e1e4e8;--xml-viewer-assignment-color:#b392f0;--xml-viewer-quote-color:#9ecbff;--xml-viewer-attribute-name-color:#b392f0;--xml-viewer-attribute-value-color:#9ecbff;--xml-viewer-cdata-content-color:#9ecbff;--xml-viewer-element-content-color:#e1e4e8;--xml-viewer-element-name-color:#85e89d;--xml-viewer-remark-content-color:#6a737d}", ""]), a.default = l;
|
|
103
|
-
}
|
|
103
|
+
})
|
|
104
104
|
),
|
|
105
105
|
/***/
|
|
106
106
|
143: (
|
|
107
107
|
/***/
|
|
108
|
-
function(_) {
|
|
108
|
+
(function(_) {
|
|
109
109
|
_.exports = function(a) {
|
|
110
110
|
var e = [];
|
|
111
111
|
return e.toString = function() {
|
|
@@ -127,123 +127,123 @@ function ze() {
|
|
|
127
127
|
}
|
|
128
128
|
}, e;
|
|
129
129
|
};
|
|
130
|
-
}
|
|
130
|
+
})
|
|
131
131
|
),
|
|
132
132
|
/***/
|
|
133
133
|
246: (
|
|
134
134
|
/***/
|
|
135
|
-
function(_) {
|
|
135
|
+
(function(_) {
|
|
136
136
|
_.exports = function(a) {
|
|
137
137
|
return a[1];
|
|
138
138
|
};
|
|
139
|
-
}
|
|
139
|
+
})
|
|
140
140
|
),
|
|
141
141
|
/***/
|
|
142
142
|
708: (
|
|
143
143
|
/***/
|
|
144
|
-
function(_, a) {
|
|
144
|
+
(function(_, a) {
|
|
145
145
|
a.A = (e, t) => {
|
|
146
146
|
const n = e.__vccOpts || e;
|
|
147
147
|
for (const [r, u] of t)
|
|
148
148
|
n[r] = u;
|
|
149
149
|
return n;
|
|
150
150
|
};
|
|
151
|
-
}
|
|
151
|
+
})
|
|
152
152
|
),
|
|
153
153
|
/***/
|
|
154
154
|
873: (
|
|
155
155
|
/***/
|
|
156
|
-
function(_, a, e) {
|
|
156
|
+
(function(_, a, e) {
|
|
157
157
|
var t = e(118);
|
|
158
158
|
t.__esModule && (t = t.default), typeof t == "string" && (t = [[_.id, t, ""]]), t.locals && (_.exports = t.locals);
|
|
159
159
|
var n = e(434).A;
|
|
160
160
|
n("f80e68c0", t, !0, { sourceMap: !1, shadowMode: !1 });
|
|
161
|
-
}
|
|
161
|
+
})
|
|
162
162
|
),
|
|
163
163
|
/***/
|
|
164
164
|
656: (
|
|
165
165
|
/***/
|
|
166
|
-
function(_, a, e) {
|
|
166
|
+
(function(_, a, e) {
|
|
167
167
|
var t = e(743);
|
|
168
168
|
t.__esModule && (t = t.default), typeof t == "string" && (t = [[_.id, t, ""]]), t.locals && (_.exports = t.locals);
|
|
169
169
|
var n = e(434).A;
|
|
170
170
|
n("6c444b0c", t, !0, { sourceMap: !1, shadowMode: !1 });
|
|
171
|
-
}
|
|
171
|
+
})
|
|
172
172
|
),
|
|
173
173
|
/***/
|
|
174
174
|
679: (
|
|
175
175
|
/***/
|
|
176
|
-
function(_, a, e) {
|
|
176
|
+
(function(_, a, e) {
|
|
177
177
|
var t = e(102);
|
|
178
178
|
t.__esModule && (t = t.default), typeof t == "string" && (t = [[_.id, t, ""]]), t.locals && (_.exports = t.locals);
|
|
179
179
|
var n = e(434).A;
|
|
180
180
|
n("df6a1d4a", t, !0, { sourceMap: !1, shadowMode: !1 });
|
|
181
|
-
}
|
|
181
|
+
})
|
|
182
182
|
),
|
|
183
183
|
/***/
|
|
184
184
|
261: (
|
|
185
185
|
/***/
|
|
186
|
-
function(_, a, e) {
|
|
186
|
+
(function(_, a, e) {
|
|
187
187
|
var t = e(80);
|
|
188
188
|
t.__esModule && (t = t.default), typeof t == "string" && (t = [[_.id, t, ""]]), t.locals && (_.exports = t.locals);
|
|
189
189
|
var n = e(434).A;
|
|
190
190
|
n("f473a604", t, !0, { sourceMap: !1, shadowMode: !1 });
|
|
191
|
-
}
|
|
191
|
+
})
|
|
192
192
|
),
|
|
193
193
|
/***/
|
|
194
194
|
309: (
|
|
195
195
|
/***/
|
|
196
|
-
function(_, a, e) {
|
|
196
|
+
(function(_, a, e) {
|
|
197
197
|
var t = e(722);
|
|
198
198
|
t.__esModule && (t = t.default), typeof t == "string" && (t = [[_.id, t, ""]]), t.locals && (_.exports = t.locals);
|
|
199
199
|
var n = e(434).A;
|
|
200
200
|
n("6c4cedf4", t, !0, { sourceMap: !1, shadowMode: !1 });
|
|
201
|
-
}
|
|
201
|
+
})
|
|
202
202
|
),
|
|
203
203
|
/***/
|
|
204
204
|
174: (
|
|
205
205
|
/***/
|
|
206
|
-
function(_, a, e) {
|
|
206
|
+
(function(_, a, e) {
|
|
207
207
|
var t = e(715);
|
|
208
208
|
t.__esModule && (t = t.default), typeof t == "string" && (t = [[_.id, t, ""]]), t.locals && (_.exports = t.locals);
|
|
209
209
|
var n = e(434).A;
|
|
210
210
|
n("cb1de664", t, !0, { sourceMap: !1, shadowMode: !1 });
|
|
211
|
-
}
|
|
211
|
+
})
|
|
212
212
|
),
|
|
213
213
|
/***/
|
|
214
214
|
643: (
|
|
215
215
|
/***/
|
|
216
|
-
function(_, a, e) {
|
|
216
|
+
(function(_, a, e) {
|
|
217
217
|
var t = e(204);
|
|
218
218
|
t.__esModule && (t = t.default), typeof t == "string" && (t = [[_.id, t, ""]]), t.locals && (_.exports = t.locals);
|
|
219
219
|
var n = e(434).A;
|
|
220
220
|
n("7a820381", t, !0, { sourceMap: !1, shadowMode: !1 });
|
|
221
|
-
}
|
|
221
|
+
})
|
|
222
222
|
),
|
|
223
223
|
/***/
|
|
224
224
|
197: (
|
|
225
225
|
/***/
|
|
226
|
-
function(_, a, e) {
|
|
226
|
+
(function(_, a, e) {
|
|
227
227
|
var t = e(904);
|
|
228
228
|
t.__esModule && (t = t.default), typeof t == "string" && (t = [[_.id, t, ""]]), t.locals && (_.exports = t.locals);
|
|
229
229
|
var n = e(434).A;
|
|
230
230
|
n("0607c4c6", t, !0, { sourceMap: !1, shadowMode: !1 });
|
|
231
|
-
}
|
|
231
|
+
})
|
|
232
232
|
),
|
|
233
233
|
/***/
|
|
234
234
|
417: (
|
|
235
235
|
/***/
|
|
236
|
-
function(_, a, e) {
|
|
236
|
+
(function(_, a, e) {
|
|
237
237
|
var t = e(834);
|
|
238
238
|
t.__esModule && (t = t.default), typeof t == "string" && (t = [[_.id, t, ""]]), t.locals && (_.exports = t.locals);
|
|
239
239
|
var n = e(434).A;
|
|
240
240
|
n("8f2d6e24", t, !0, { sourceMap: !1, shadowMode: !1 });
|
|
241
|
-
}
|
|
241
|
+
})
|
|
242
242
|
),
|
|
243
243
|
/***/
|
|
244
244
|
434: (
|
|
245
245
|
/***/
|
|
246
|
-
function(_, a, e) {
|
|
246
|
+
(function(_, a, e) {
|
|
247
247
|
e.d(a, {
|
|
248
248
|
A: function() {
|
|
249
249
|
return (
|
|
@@ -342,13 +342,13 @@ function ze() {
|
|
|
342
342
|
d();
|
|
343
343
|
};
|
|
344
344
|
}
|
|
345
|
-
var M = /* @__PURE__ */ function() {
|
|
345
|
+
var M = /* @__PURE__ */ (function() {
|
|
346
346
|
var s = [];
|
|
347
347
|
return function(m, d) {
|
|
348
348
|
return s[m] = d, s.filter(Boolean).join(`
|
|
349
349
|
`);
|
|
350
350
|
};
|
|
351
|
-
}();
|
|
351
|
+
})();
|
|
352
352
|
function H(s, m, d, i) {
|
|
353
353
|
var c = d ? "" : i.css;
|
|
354
354
|
if (s.styleSheet)
|
|
@@ -370,7 +370,7 @@ function ze() {
|
|
|
370
370
|
s.appendChild(document.createTextNode(d));
|
|
371
371
|
}
|
|
372
372
|
}
|
|
373
|
-
}
|
|
373
|
+
})
|
|
374
374
|
)
|
|
375
375
|
/******/
|
|
376
376
|
}, V = {};
|
|
@@ -404,22 +404,22 @@ function ze() {
|
|
|
404
404
|
);
|
|
405
405
|
return p.d(a, { a }), a;
|
|
406
406
|
};
|
|
407
|
-
})(), function() {
|
|
407
|
+
})(), (function() {
|
|
408
408
|
p.d = function(_, a) {
|
|
409
409
|
for (var e in a)
|
|
410
410
|
p.o(a, e) && !p.o(_, e) && Object.defineProperty(_, e, { enumerable: !0, get: a[e] });
|
|
411
411
|
};
|
|
412
|
-
}(), function() {
|
|
412
|
+
})(), (function() {
|
|
413
413
|
p.o = function(_, a) {
|
|
414
414
|
return Object.prototype.hasOwnProperty.call(_, a);
|
|
415
415
|
};
|
|
416
|
-
}(), function() {
|
|
416
|
+
})(), (function() {
|
|
417
417
|
p.r = function(_) {
|
|
418
418
|
typeof Symbol < "u" && Symbol.toStringTag && Object.defineProperty(_, Symbol.toStringTag, { value: "Module" }), Object.defineProperty(_, "__esModule", { value: !0 });
|
|
419
419
|
};
|
|
420
|
-
}(), function() {
|
|
420
|
+
})(), (function() {
|
|
421
421
|
p.p = "";
|
|
422
|
-
}();
|
|
422
|
+
})();
|
|
423
423
|
var X = {};
|
|
424
424
|
(function() {
|
|
425
425
|
if (p.r(X), p.d(X, {
|
|
@@ -747,7 +747,7 @@ function ze() {
|
|
|
747
747
|
}), Ve = /* @__PURE__ */ (0, M.A)(Ne, [["render", t]]), $e = Ve, Ie = $e;
|
|
748
748
|
})(), I.exports = X;
|
|
749
749
|
})();
|
|
750
|
-
}(Y)), Y.exports;
|
|
750
|
+
})(Y)), Y.exports;
|
|
751
751
|
}
|
|
752
752
|
var te = ze();
|
|
753
753
|
const Ge = /* @__PURE__ */ Ke(te), lt = /* @__PURE__ */ Fe({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@datagouv/components-next",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.1.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./src/main.ts",
|
|
@@ -25,6 +25,7 @@
|
|
|
25
25
|
"@floating-ui/vue": "^1.1.8",
|
|
26
26
|
"@headlessui/vue": "^1.7.23",
|
|
27
27
|
"@remixicon/vue": "^4.5.0",
|
|
28
|
+
"@types/hast": "^3.0.4",
|
|
28
29
|
"@vueuse/core": "^13.1.0",
|
|
29
30
|
"chart.js": "^4.4.8",
|
|
30
31
|
"dompurify": "^3.2.5",
|
|
@@ -34,7 +35,7 @@
|
|
|
34
35
|
"ol": "^10.6.1",
|
|
35
36
|
"pdf-vue3": "^1.0.12",
|
|
36
37
|
"pmtiles": "^4.3.0",
|
|
37
|
-
"popmotion": "^
|
|
38
|
+
"popmotion": "^11.0",
|
|
38
39
|
"rehype-highlight": "^7.0.2",
|
|
39
40
|
"rehype-raw": "^7.0.0",
|
|
40
41
|
"rehype-sanitize": "^6.0.0",
|
|
@@ -46,12 +47,12 @@
|
|
|
46
47
|
"remark-parse": "^11.0.0",
|
|
47
48
|
"remark-rehype": "^11.1.2",
|
|
48
49
|
"strip-markdown": "^6.0.0",
|
|
50
|
+
"stylefire": "^7.0.3",
|
|
49
51
|
"swagger-ui-dist": "^5.27.1",
|
|
50
52
|
"unified": "^11.0.5",
|
|
51
53
|
"unist-util-visit": "^5.0.0",
|
|
52
54
|
"vue": "^3.5.13",
|
|
53
55
|
"vue-content-loader": "^2.0.1",
|
|
54
|
-
"vue-i18n": "^10.0.6",
|
|
55
56
|
"vue-router": "^4.5.0",
|
|
56
57
|
"vue3-json-viewer": "^2.4.1",
|
|
57
58
|
"vue3-text-clamp": "^0.1.2",
|
|
@@ -64,20 +65,20 @@
|
|
|
64
65
|
"@tsconfig/node22": "^22.0.0",
|
|
65
66
|
"@types/geojson": "^7946.0.16",
|
|
66
67
|
"@types/node": "^22.13.1",
|
|
67
|
-
"@vitejs/plugin-vue": "^
|
|
68
|
+
"@vitejs/plugin-vue": "^6.0",
|
|
68
69
|
"@vue/eslint-config-prettier": "^10.2.0",
|
|
69
70
|
"@vue/eslint-config-typescript": "^14.3.0",
|
|
70
|
-
"@vue/tsconfig": "^0.
|
|
71
|
+
"@vue/tsconfig": "^0.8.0",
|
|
71
72
|
"eslint": "^9.18.0",
|
|
72
|
-
"eslint-plugin-vue": "^
|
|
73
|
+
"eslint-plugin-vue": "^10.0",
|
|
73
74
|
"jiti": "^2.4.2",
|
|
74
|
-
"npm-run-all2": "^
|
|
75
|
+
"npm-run-all2": "^8.0",
|
|
75
76
|
"prettier": "^3.0.0",
|
|
76
77
|
"tailwindcss": "^4.0.8",
|
|
77
|
-
"typescript": "
|
|
78
|
-
"vite": "^
|
|
79
|
-
"vite-plugin-vue-devtools": "^
|
|
80
|
-
"vue-tsc": "^
|
|
78
|
+
"typescript": "^5.7.3",
|
|
79
|
+
"vite": "^7.0",
|
|
80
|
+
"vite-plugin-vue-devtools": "^8.0",
|
|
81
|
+
"vue-tsc": "^3.0"
|
|
81
82
|
},
|
|
82
83
|
"scarfSettings": {
|
|
83
84
|
"enabled": false
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<PaddedContainer class="p-4 pr-7">
|
|
3
|
+
<LoadingBlock :status>
|
|
4
|
+
<template v-if="activities && activities.total">
|
|
5
|
+
<div
|
|
6
|
+
v-for="(monthlyActivities, month) in groupedActivities"
|
|
7
|
+
:key="month"
|
|
8
|
+
class="my-1"
|
|
9
|
+
>
|
|
10
|
+
<p class="pl-3 mb-1 text-xs text-gray-medium">
|
|
11
|
+
{{ month }}
|
|
12
|
+
</p>
|
|
13
|
+
<ul
|
|
14
|
+
class="space-y-2 p-0 m-0"
|
|
15
|
+
>
|
|
16
|
+
<li
|
|
17
|
+
v-for="(activity, activityIndex) in monthlyActivities"
|
|
18
|
+
:key="`${activity.key}${activity.created_at}`"
|
|
19
|
+
class="relative flex"
|
|
20
|
+
>
|
|
21
|
+
<div :class="[activityIndex === monthlyActivities.length - 1 ? 'h-6' : '-bottom-6', 'absolute left-0 top-0 flex w-6 justify-center']">
|
|
22
|
+
<div class="w-px bg-gray-silver" />
|
|
23
|
+
</div>
|
|
24
|
+
<div class="relative flex size-6 flex-none items-center justify-center bg-white">
|
|
25
|
+
<div class="size-[7px] rounded-full bg-gray-silver" />
|
|
26
|
+
</div>
|
|
27
|
+
<div class="flex w-full gap-x-3 items-start">
|
|
28
|
+
<div class="flex flex-none items-center">
|
|
29
|
+
<Avatar
|
|
30
|
+
:rounded="true"
|
|
31
|
+
:size="16"
|
|
32
|
+
:user="activity.actor"
|
|
33
|
+
class="block"
|
|
34
|
+
/>
|
|
35
|
+
<p class="m-0 text-xs font-bold ml-0.5 text-gray-title">
|
|
36
|
+
{{ activity.actor.first_name }}
|
|
37
|
+
{{ activity.actor.last_name }}
|
|
38
|
+
</p>
|
|
39
|
+
</div>
|
|
40
|
+
<details
|
|
41
|
+
v-if="hasChanges(activity)"
|
|
42
|
+
class="min-w-0 flex-1"
|
|
43
|
+
>
|
|
44
|
+
<summary class="m-0 text-xs text-gray-title">
|
|
45
|
+
<slot
|
|
46
|
+
name="activity"
|
|
47
|
+
v-bind="{ class: 'px-3.5', activity }"
|
|
48
|
+
>
|
|
49
|
+
{{ getActivityTranslation(activity) }}
|
|
50
|
+
</slot>
|
|
51
|
+
</summary>
|
|
52
|
+
<p class="m-2 text-xs">
|
|
53
|
+
{{ t('Aucun Champs mis à jour : | 1 Champ mis à jour : | {n} Champs mis à jour :', { n: activity.changes?.length ?? 0 }) }}
|
|
54
|
+
</p>
|
|
55
|
+
<div class="font-mono text-xs rounded-sm bg-gray-some p-4 m-2">
|
|
56
|
+
<ul class="list-['-'] pl-2 m-0">
|
|
57
|
+
<li
|
|
58
|
+
v-for="change in activity.changes"
|
|
59
|
+
:key="change"
|
|
60
|
+
class="pl-1"
|
|
61
|
+
>
|
|
62
|
+
{{ change }}
|
|
63
|
+
</li>
|
|
64
|
+
</ul>
|
|
65
|
+
</div>
|
|
66
|
+
</details>
|
|
67
|
+
<p
|
|
68
|
+
v-else
|
|
69
|
+
class="m-0 text-xs text-gray-title min-w-0 flex-1"
|
|
70
|
+
>
|
|
71
|
+
<slot
|
|
72
|
+
name="activity"
|
|
73
|
+
v-bind="{ class: '', activity }"
|
|
74
|
+
>
|
|
75
|
+
{{ getActivityTranslation(activity) }}
|
|
76
|
+
</slot>
|
|
77
|
+
</p>
|
|
78
|
+
<p class="m-0 flex-none text-xs text-gray-medium">
|
|
79
|
+
{{ t('le {date}', { date: formatDate(activity.created_at) }) }}
|
|
80
|
+
</p>
|
|
81
|
+
</div>
|
|
82
|
+
</li>
|
|
83
|
+
</ul>
|
|
84
|
+
</div>
|
|
85
|
+
<Pagination
|
|
86
|
+
:total-results="activities.total"
|
|
87
|
+
:page-size="activities.page_size"
|
|
88
|
+
:page="activities.page"
|
|
89
|
+
:link="getLink"
|
|
90
|
+
@change="(newPage: number) => page = newPage"
|
|
91
|
+
/>
|
|
92
|
+
</template>
|
|
93
|
+
<div
|
|
94
|
+
v-else
|
|
95
|
+
class="flex flex-col items-center"
|
|
96
|
+
>
|
|
97
|
+
<nuxt-img
|
|
98
|
+
src="/illustrations/list.svg"
|
|
99
|
+
class="h-32"
|
|
100
|
+
/>
|
|
101
|
+
<p class="fr-text--bold fr-my-3v">
|
|
102
|
+
{{ t(`Il n'y a pas encore d'activité`) }}
|
|
103
|
+
</p>
|
|
104
|
+
</div>
|
|
105
|
+
</LoadingBlock>
|
|
106
|
+
</PaddedContainer>
|
|
107
|
+
</template>
|
|
108
|
+
|
|
109
|
+
<script setup lang="ts">
|
|
110
|
+
import { computed, ref } from 'vue'
|
|
111
|
+
import { useRoute } from 'vue-router'
|
|
112
|
+
import { useTranslation } from '../../composables/useTranslation'
|
|
113
|
+
import { getActivityTranslation } from '../../functions/activities'
|
|
114
|
+
import { useFetch } from '../../functions/api'
|
|
115
|
+
import { useFormatDate } from '../../functions/dates'
|
|
116
|
+
import { getLink } from '../../functions/pagination'
|
|
117
|
+
import type { PaginatedArray } from '../../types/api'
|
|
118
|
+
import type { Activity } from '../../types/activity'
|
|
119
|
+
import Avatar from '../Avatar.vue'
|
|
120
|
+
import Pagination from '../Pagination.vue'
|
|
121
|
+
import PaddedContainer from '../PaddedContainer.vue'
|
|
122
|
+
|
|
123
|
+
const props = defineProps<{
|
|
124
|
+
id?: string
|
|
125
|
+
user?: string
|
|
126
|
+
}>()
|
|
127
|
+
|
|
128
|
+
const route = useRoute()
|
|
129
|
+
const { formatDate } = useFormatDate()
|
|
130
|
+
const { t } = useTranslation()
|
|
131
|
+
|
|
132
|
+
const page = ref(parseInt(route.query.page as string | undefined ?? '1', 10))
|
|
133
|
+
|
|
134
|
+
const { data: activities, status } = await useFetch<PaginatedArray<Activity>>('/api/1/activity/', {
|
|
135
|
+
query: {
|
|
136
|
+
related_to: props.id ?? undefined,
|
|
137
|
+
user: props.user ?? undefined,
|
|
138
|
+
page,
|
|
139
|
+
},
|
|
140
|
+
})
|
|
141
|
+
|
|
142
|
+
const groupedActivities = computed(() => activities.value?.data.reduce((grouped, activity) => {
|
|
143
|
+
const activityMonth = formatDate(activity.created_at, {
|
|
144
|
+
dateStyle: undefined,
|
|
145
|
+
day: undefined,
|
|
146
|
+
month: 'long',
|
|
147
|
+
year: 'numeric',
|
|
148
|
+
})
|
|
149
|
+
if (!grouped[activityMonth]) {
|
|
150
|
+
grouped[activityMonth] = []
|
|
151
|
+
}
|
|
152
|
+
grouped[activityMonth].push(activity)
|
|
153
|
+
return grouped
|
|
154
|
+
}, {} as Record<string, Array<Activity>>))
|
|
155
|
+
|
|
156
|
+
function hasChanges(activity: Activity) {
|
|
157
|
+
return activity.changes && Array.isArray(activity.changes) && activity.changes.length
|
|
158
|
+
}
|
|
159
|
+
</script>
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<ActivityList :user>
|
|
3
|
+
<template #activity="{ class: cls, activity }">
|
|
4
|
+
{{ getActivityTranslation(activity) }}
|
|
5
|
+
<slot :activity>
|
|
6
|
+
<div :class="cls">
|
|
7
|
+
<AppLink
|
|
8
|
+
:to="activity.related_to_url"
|
|
9
|
+
class="link flex truncate"
|
|
10
|
+
target="_blank"
|
|
11
|
+
>
|
|
12
|
+
<span
|
|
13
|
+
class="truncate"
|
|
14
|
+
>{{ activity.related_to }}</span>
|
|
15
|
+
</AppLink>
|
|
16
|
+
</div>
|
|
17
|
+
</slot>
|
|
18
|
+
</template>
|
|
19
|
+
</ActivityList>
|
|
20
|
+
</template>
|
|
21
|
+
|
|
22
|
+
<script setup lang="ts">
|
|
23
|
+
import { getActivityTranslation } from '../../functions/activities'
|
|
24
|
+
import AppLink from '../AppLink.vue'
|
|
25
|
+
import ActivityList from './ActivityList.vue'
|
|
26
|
+
|
|
27
|
+
defineProps<{
|
|
28
|
+
user: string
|
|
29
|
+
}>()
|
|
30
|
+
</script>
|
|
@@ -21,12 +21,12 @@
|
|
|
21
21
|
<script setup lang="ts">
|
|
22
22
|
import { computed } from 'vue'
|
|
23
23
|
import { RouterLink } from 'vue-router'
|
|
24
|
-
import { useI18n } from 'vue-i18n'
|
|
25
24
|
import type { RouteLocationRaw } from 'vue-router'
|
|
26
25
|
import { useComponentsConfig } from '../config'
|
|
26
|
+
import { useTranslation } from '../composables/useTranslation'
|
|
27
27
|
|
|
28
28
|
const config = useComponentsConfig()
|
|
29
|
-
const { locale } =
|
|
29
|
+
const { locale } = useTranslation()
|
|
30
30
|
|
|
31
31
|
const props = defineProps<{
|
|
32
32
|
to: string | RouteLocationRaw
|
|
@@ -44,7 +44,7 @@ const to = computed(() => {
|
|
|
44
44
|
if (isExternal.value) return props.to
|
|
45
45
|
|
|
46
46
|
// TODO harden this for path not starting with "/"x
|
|
47
|
-
if (typeof props.to === 'string') return `/${locale
|
|
47
|
+
if (typeof props.to === 'string') return `/${locale}${props.to}`
|
|
48
48
|
|
|
49
49
|
return props.to
|
|
50
50
|
})
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<article
|
|
3
|
-
class="my-4 p-4 bg-white border fr-enlarge-link"
|
|
3
|
+
class="my-4 p-4 bg-white hover:bg-gray-some border fr-enlarge-link"
|
|
4
4
|
:class="{
|
|
5
5
|
'border-tabular-api': isTabularApi,
|
|
6
6
|
'border-gray-default': !isTabularApi,
|
|
@@ -128,7 +128,6 @@
|
|
|
128
128
|
|
|
129
129
|
<script setup lang="ts">
|
|
130
130
|
import { computed, ref, watchEffect } from 'vue'
|
|
131
|
-
import { useI18n } from 'vue-i18n'
|
|
132
131
|
import type { RouteLocationRaw } from 'vue-router'
|
|
133
132
|
import { RiEyeLine, RiLockLine, RiPassValidLine, RiSparklingLine, RiStarLine, RiSubtractLine, RiTerminalLine } from '@remixicon/vue'
|
|
134
133
|
import { useComponentsConfig } from '../config'
|
|
@@ -137,6 +136,7 @@ import { summarize } from '../functions/helpers'
|
|
|
137
136
|
import { removeMarkdown } from '../functions/markdown'
|
|
138
137
|
import { getOwnerName } from '../functions/owned'
|
|
139
138
|
import type { Dataservice } from '../types/dataservices'
|
|
139
|
+
import { useTranslation } from '../composables/useTranslation'
|
|
140
140
|
import OrganizationNameWithCertificate from './OrganizationNameWithCertificate.vue'
|
|
141
141
|
import AppLink from './AppLink.vue'
|
|
142
142
|
|
|
@@ -164,7 +164,7 @@ const props = withDefaults(defineProps<Props>(), {
|
|
|
164
164
|
|
|
165
165
|
const dataserviceUrl = computed(() => props.dataserviceUrl || props.dataservice.self_web_url)
|
|
166
166
|
|
|
167
|
-
const { t } =
|
|
167
|
+
const { t } = useTranslation()
|
|
168
168
|
const { formatRelativeIfRecentDate } = useFormatDate()
|
|
169
169
|
const ownerName = computed(() => getOwnerName(props.dataservice))
|
|
170
170
|
const showBadge = computed(() => props.dataservice.access_type === 'restricted' || props.dataservice.access_type === 'open_with_account' || props.dataservice.private || props.dataservice.archived_at)
|