@abyss-project/commons-front-core 20.3.0 → 20.4.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/CHANGELOG.md +15 -0
- package/catalog/captures-plan.ts +10 -2
- package/catalog/pages/DeliveryHistory.tsx +142 -142
- package/catalog/pages/DeliverySubscriptions.tsx +50 -2
- package/catalog/pages/ScheduledTasks.tsx +116 -2
- package/catalog/specs/captures.spec.ts +156 -145
- package/catalog/specs/write-capture-index.ts +82 -81
- package/dist/{CookieConsentSettings-BPBNaNNI.js → CookieConsentSettings-JQqB3ZoC.js} +1 -1
- package/dist/{Surface-DmHRzUtQ.js → Surface-rKrLIx9x.js} +170 -44
- package/dist/{Tabs-CxBeR0D-.js → Tabs-C3ZY5xT8.js} +1 -1
- package/dist/components/business/Deliveries/DeliverySubscriptionForm.d.ts +7 -2
- package/dist/components/business/Deliveries/ScheduledTaskForm.d.ts +8 -2
- package/dist/components/business/Deliveries/ScheduledTaskPanel.d.ts +30 -0
- package/dist/components/business/Deliveries/ScheduledTasks.component.d.ts +3 -2
- package/dist/components/business/Deliveries/deliveries.logic.d.ts +36 -1
- package/dist/components/business/Deliveries/deliveries.types.d.ts +68 -3
- package/dist/components/business/Deliveries/test-support/deliveries.fixtures.d.ts +2 -1
- package/dist/cookie-consent.js +2 -2
- package/dist/{design-theme-HWymeGb7.js → design-theme-CeGUipuM.js} +877 -872
- package/dist/{editors-BmRsTu0H.js → editors-DNQ00p6Y.js} +27 -27
- package/dist/editors.js +1 -1
- package/dist/hooks/use-rich-intl.hook.d.ts +134 -16
- package/dist/{index-ChCpWPzk.js → index-2mUgohFa.js} +4 -4
- package/dist/{index-DnweGlM_.js → index-7lQ_E_am.js} +2 -2
- package/dist/{index-Dco3zEwV.js → index-8lBj2Ffk.js} +2 -2
- package/dist/{index-BAH9H4GE.js → index-BQUxvLoP.js} +3 -3
- package/dist/{index-DLIvsZA_.js → index-BQlO5Fp0.js} +2 -2
- package/dist/{index-CsZJyqSF.js → index-BXfdxGL2.js} +2 -2
- package/dist/{index-Cv8TWKKk.js → index-CHy_RxpP.js} +2 -2
- package/dist/{index-DVyE9B4I.js → index-CIpdjZHz.js} +2 -2
- package/dist/{index-BTwuilx5.js → index-CJnZcgwL.js} +3 -3
- package/dist/{index-CJjWI7qL.js → index-CQ9U6YlK.js} +3 -3
- package/dist/{index-RjzeFVe-.js → index-CzCDSQiD.js} +2 -2
- package/dist/{index-ClEFydIA.js → index-DAVJlVe-.js} +2 -2
- package/dist/{index-DsxBk5OJ.js → index-DQtcZD9Y.js} +1 -1
- package/dist/{index-DYdLhNjl.js → index-DWnlMFqj.js} +3 -3
- package/dist/{index-BwugEq4x.js → index-DgiI-dK3.js} +2 -2
- package/dist/{index-Buo7Iim6.js → index-DpR-QTUA.js} +4 -4
- package/dist/{index-DuLb3GSj.js → index-GvBY_FDT.js} +4 -4
- package/dist/{index-CSl9Kc0V.js → index-On5L36UF.js} +2 -2
- package/dist/{index-CI0SMeOa.js → index-a47WpMOx.js} +2 -2
- package/dist/{index-ZL-d1iKb.js → index-ehhIl57c.js} +2 -2
- package/dist/{index-BGAmhhJZ.js → index-qGV3av53.js} +2 -2
- package/dist/index.js +9809 -9486
- package/dist/legacy.js +745 -750
- package/dist/translations/en.d.ts +63 -0
- package/dist/translations/fr.d.ts +63 -0
- package/package.json +5 -5
- package/test-results/catalog/.last-run.json +4 -0
|
@@ -80,7 +80,7 @@ const he = 266, c = (e, t) => ({ l: e, c: t, h: he }), ht = {
|
|
|
80
80
|
compact: { row: 30, control: 28 },
|
|
81
81
|
touchTarget: 44
|
|
82
82
|
};
|
|
83
|
-
var
|
|
83
|
+
var N = /* @__PURE__ */ ((e) => (e.Mobile = "mobile", e.Tablet = "tablet", e.Desktop = "desktop", e))(N || {});
|
|
84
84
|
const ee = {
|
|
85
85
|
tablet: V.md,
|
|
86
86
|
desktop: V.lg
|
|
@@ -112,30 +112,30 @@ const ee = {
|
|
|
112
112
|
)}`;
|
|
113
113
|
}
|
|
114
114
|
}
|
|
115
|
-
}, fe = 0.14, a = (e) => `${e}px`, P = (e) => `1px solid ${e}`,
|
|
115
|
+
}, fe = 0.14, a = (e) => `${e}px`, P = (e) => `1px solid ${e}`, Tt = (e) => se(e, fe), Ae = (e) => ({
|
|
116
116
|
outline: `2px solid ${e.design.tokens["focus.ring"]}`,
|
|
117
117
|
outlineOffset: "2px"
|
|
118
|
-
}),
|
|
119
|
-
[w.down(
|
|
118
|
+
}), St = (e, t) => t === "small" ? e.design.densityValues.compact.control : e.design.densityValues[e.design.density].control, Rt = (e) => e.design.densityValues[e.design.density].row, Nt = (e) => ({
|
|
119
|
+
[w.down(N.Tablet)]: {
|
|
120
120
|
minHeight: a(e.design.densityValues.touchTarget)
|
|
121
121
|
}
|
|
122
122
|
}), ye = (e) => ({
|
|
123
|
-
[w.down(
|
|
123
|
+
[w.down(N.Tablet)]: {
|
|
124
124
|
minWidth: a(e.design.densityValues.touchTarget),
|
|
125
125
|
minHeight: a(e.design.densityValues.touchTarget)
|
|
126
126
|
}
|
|
127
127
|
}), Ee = (e, t, o = "fast") => t.map(
|
|
128
128
|
(r) => `${r} ${e.design.durations[o]}ms ${e.design.easings.standard}`
|
|
129
129
|
).join(", "), ve = () => {
|
|
130
|
-
const e = H(w.up(
|
|
130
|
+
const e = H(w.up(N.Desktop), {
|
|
131
131
|
noSsr: !0
|
|
132
|
-
}), t = H(w.down(
|
|
132
|
+
}), t = H(w.down(N.Tablet), {
|
|
133
133
|
noSsr: !0
|
|
134
134
|
});
|
|
135
|
-
return e ?
|
|
135
|
+
return e ? N.Desktop : t ? N.Mobile : N.Tablet;
|
|
136
136
|
};
|
|
137
137
|
var _ = /* @__PURE__ */ ((e) => (e.Top = "top", e.Bottom = "bottom", e.Left = "left", e.Right = "right", e))(_ || {});
|
|
138
|
-
const L = (e, t) => `calc(${a(t)} + env(safe-area-inset-${e}))`, be = 0.3,
|
|
138
|
+
const L = (e, t) => `calc(${a(t)} + env(safe-area-inset-${e}))`, be = 0.3, Te = h("div")({
|
|
139
139
|
position: "absolute",
|
|
140
140
|
left: 0,
|
|
141
141
|
right: 0,
|
|
@@ -143,7 +143,7 @@ const L = (e, t) => `calc(${a(t)} + env(safe-area-inset-${e}))`, be = 0.3, Se =
|
|
|
143
143
|
maxHeight: "100%",
|
|
144
144
|
display: "flex",
|
|
145
145
|
outline: "none"
|
|
146
|
-
}),
|
|
146
|
+
}), Se = h("div")(({ theme: e }) => {
|
|
147
147
|
const { tokens: t, radii: o, space: r, elevations: i, fonts: n } = e.design;
|
|
148
148
|
return {
|
|
149
149
|
flex: "1 1 auto",
|
|
@@ -166,12 +166,12 @@ const L = (e, t) => `calc(${a(t)} + env(safe-area-inset-${e}))`, be = 0.3, Se =
|
|
|
166
166
|
outline: "none",
|
|
167
167
|
position: "relative"
|
|
168
168
|
};
|
|
169
|
-
}),
|
|
169
|
+
}), Re = h(J)(({ theme: e }) => ({
|
|
170
170
|
position: "absolute",
|
|
171
171
|
top: a(e.design.space[1]),
|
|
172
172
|
right: L(_.Right, e.design.space[2]),
|
|
173
173
|
...ye(e)
|
|
174
|
-
})),
|
|
174
|
+
})), Ne = h("div")(({ theme: e }) => {
|
|
175
175
|
const { space: t, densityValues: o } = e.design;
|
|
176
176
|
return {
|
|
177
177
|
flex: "none",
|
|
@@ -222,18 +222,18 @@ function De({
|
|
|
222
222
|
closeLabel: i,
|
|
223
223
|
children: n
|
|
224
224
|
}) {
|
|
225
|
-
const g = le(), y = G(), E = F(), f = Y(null), A = Y(null), [v,
|
|
226
|
-
|
|
227
|
-
}, p = (
|
|
228
|
-
A.current !== null &&
|
|
229
|
-
}, b = (
|
|
225
|
+
const g = le(), y = G(), E = F(), f = Y(null), A = Y(null), [v, R] = j(0), [u, l] = j(!1), s = (S) => {
|
|
226
|
+
S.currentTarget.setPointerCapture(S.pointerId), A.current = S.clientY, l(!0);
|
|
227
|
+
}, p = (S) => {
|
|
228
|
+
A.current !== null && R(Math.max(0, S.clientY - A.current));
|
|
229
|
+
}, b = (S) => {
|
|
230
230
|
var z;
|
|
231
231
|
if (A.current === null)
|
|
232
232
|
return;
|
|
233
|
-
const I = Math.max(0,
|
|
234
|
-
A.current = null, l(!1),
|
|
235
|
-
},
|
|
236
|
-
A.current = null, l(!1),
|
|
233
|
+
const I = Math.max(0, S.clientY - A.current), B = ((z = f.current) == null ? void 0 : z.getBoundingClientRect().height) ?? 0;
|
|
234
|
+
A.current = null, l(!1), R(0), B > 0 && I >= B * be && t();
|
|
235
|
+
}, T = () => {
|
|
236
|
+
A.current = null, l(!1), R(0);
|
|
237
237
|
};
|
|
238
238
|
return /* @__PURE__ */ d(ce, { open: e, onClose: () => t(), children: /* @__PURE__ */ d(
|
|
239
239
|
de,
|
|
@@ -242,8 +242,8 @@ function De({
|
|
|
242
242
|
direction: "up",
|
|
243
243
|
timeout: g.design.durations.slow,
|
|
244
244
|
easing: g.design.easings.sheet,
|
|
245
|
-
children: /* @__PURE__ */ d(
|
|
246
|
-
|
|
245
|
+
children: /* @__PURE__ */ d(Te, { children: /* @__PURE__ */ C(
|
|
246
|
+
Se,
|
|
247
247
|
{
|
|
248
248
|
ref: f,
|
|
249
249
|
role: "dialog",
|
|
@@ -260,13 +260,13 @@ function De({
|
|
|
260
260
|
},
|
|
261
261
|
children: [
|
|
262
262
|
/* @__PURE__ */ C(
|
|
263
|
-
|
|
263
|
+
Ne,
|
|
264
264
|
{
|
|
265
265
|
"data-testid": "bottom-sheet-drag-zone",
|
|
266
266
|
onPointerDown: s,
|
|
267
267
|
onPointerMove: p,
|
|
268
268
|
onPointerUp: b,
|
|
269
|
-
onPointerCancel:
|
|
269
|
+
onPointerCancel: T,
|
|
270
270
|
children: [
|
|
271
271
|
/* @__PURE__ */ d(Ce, { "aria-hidden": "true" }),
|
|
272
272
|
o ? /* @__PURE__ */ C(Ie, { id: E, besideClose: i !== void 0, children: [
|
|
@@ -276,7 +276,7 @@ function De({
|
|
|
276
276
|
]
|
|
277
277
|
}
|
|
278
278
|
),
|
|
279
|
-
i !== void 0 && /* @__PURE__ */ d(
|
|
279
|
+
i !== void 0 && /* @__PURE__ */ d(Re, { "aria-label": i, onClick: () => t(), children: /* @__PURE__ */ d(Q, { "aria-hidden": !0 }) }),
|
|
280
280
|
/* @__PURE__ */ d(_e, { children: n })
|
|
281
281
|
]
|
|
282
282
|
}
|
|
@@ -373,7 +373,7 @@ function _t({
|
|
|
373
373
|
actions: g,
|
|
374
374
|
children: y
|
|
375
375
|
}) {
|
|
376
|
-
const E = G(), f = ve() ===
|
|
376
|
+
const E = G(), f = ve() === N.Mobile, A = F(), v = F();
|
|
377
377
|
return f ? /* @__PURE__ */ C(
|
|
378
378
|
De,
|
|
379
379
|
{
|
|
@@ -1470,6 +1470,7 @@ const He = {
|
|
|
1470
1470
|
event: {
|
|
1471
1471
|
MONITOR_EVENT: "Événement Monitor",
|
|
1472
1472
|
MONITOR_SENTINEL: "Sonde Monitor",
|
|
1473
|
+
MONITOR_FEEDBACK_RESPONDED: "Réponse à une demande d’avis",
|
|
1473
1474
|
STORAGE_UPLOAD: "Fichier déposé",
|
|
1474
1475
|
STORAGE_WRITE: "Fichier modifié",
|
|
1475
1476
|
STORAGE_DELETE: "Fichier supprimé",
|
|
@@ -1738,6 +1739,15 @@ const He = {
|
|
|
1738
1739
|
timeout: "Délai maximal",
|
|
1739
1740
|
retries: "Nouvelles tentatives",
|
|
1740
1741
|
"retry-delay": "Délai entre deux tentatives",
|
|
1742
|
+
"retry-backoff": "Progression du délai",
|
|
1743
|
+
"retry-backoff-option": {
|
|
1744
|
+
LINEAR: "Croissante",
|
|
1745
|
+
FIXED: "Fixe"
|
|
1746
|
+
},
|
|
1747
|
+
"retry-backoff-help": {
|
|
1748
|
+
LINEAR: "Chaque nouvelle tentative attend un délai de plus : 1×, 2×, 3× le délai entre deux tentatives.",
|
|
1749
|
+
FIXED: "Chaque tentative attend le même délai."
|
|
1750
|
+
},
|
|
1741
1751
|
enabled: "Tâche active",
|
|
1742
1752
|
"error-name": "Saisissez un nom.",
|
|
1743
1753
|
"error-schedule": "Saisissez une planification.",
|
|
@@ -1758,11 +1768,64 @@ const He = {
|
|
|
1758
1768
|
pagination: "Pages des exécutions",
|
|
1759
1769
|
empty: "Aucune exécution",
|
|
1760
1770
|
"empty-desc": "Les exécutions de cette tâche apparaissent ici.",
|
|
1771
|
+
"empty-filtered": "Aucune exécution ne correspond à ces filtres",
|
|
1772
|
+
"empty-filtered-desc": "Élargissez la période ou effacez l’identifiant de requête.",
|
|
1761
1773
|
column: {
|
|
1762
1774
|
status: "Statut",
|
|
1763
1775
|
"scheduled-for": "Prévue le",
|
|
1764
1776
|
duration: "Durée",
|
|
1765
1777
|
code: "Code de réponse"
|
|
1778
|
+
},
|
|
1779
|
+
action: {
|
|
1780
|
+
detail: "Détail de l’exécution"
|
|
1781
|
+
},
|
|
1782
|
+
filters: {
|
|
1783
|
+
period: "Période",
|
|
1784
|
+
preset: {
|
|
1785
|
+
today: "Aujourd’hui",
|
|
1786
|
+
"last-7-days": "7 derniers jours",
|
|
1787
|
+
"last-30-days": "30 derniers jours"
|
|
1788
|
+
},
|
|
1789
|
+
"request-id": "Identifiant de requête",
|
|
1790
|
+
"request-id-invalid": "Saisissez l’identifiant complet, tel qu’envoyé dans l’en-tête x-request-id.",
|
|
1791
|
+
outcome: "Résultat",
|
|
1792
|
+
"outcome-option": {
|
|
1793
|
+
all: "Tous les résultats",
|
|
1794
|
+
succeeded: "Réussies",
|
|
1795
|
+
failed: "En échec ou délai dépassé",
|
|
1796
|
+
skipped: "Ignorées"
|
|
1797
|
+
},
|
|
1798
|
+
"outcome-subset": "{shown, number} sur {count, plural, one {# exécution} other {# exécutions}} de cette page ont ce résultat.",
|
|
1799
|
+
"outcome-empty": "Aucune exécution de cette page n’a ce résultat.",
|
|
1800
|
+
reset: "Effacer les filtres"
|
|
1801
|
+
}
|
|
1802
|
+
},
|
|
1803
|
+
run: {
|
|
1804
|
+
back: "Retour aux exécutions",
|
|
1805
|
+
logs: "Voir les journaux de cette requête",
|
|
1806
|
+
request: "Requête",
|
|
1807
|
+
"scheduled-for": "Prévue le",
|
|
1808
|
+
"started-at": "Démarrée le",
|
|
1809
|
+
"not-started": "Pas encore démarrée",
|
|
1810
|
+
attempt: "Tentative",
|
|
1811
|
+
duration: "Durée",
|
|
1812
|
+
response: "Réponse",
|
|
1813
|
+
"response-code": "Code de réponse",
|
|
1814
|
+
"response-headers": "En-têtes de la réponse",
|
|
1815
|
+
"response-body": "Corps de la réponse",
|
|
1816
|
+
error: "Erreur",
|
|
1817
|
+
none: "Aucun",
|
|
1818
|
+
archived: {
|
|
1819
|
+
title: "Détail archivé",
|
|
1820
|
+
description: "Les en-têtes, le corps de la réponse et l’erreur de cette exécution sont dans l’archive."
|
|
1821
|
+
}
|
|
1822
|
+
},
|
|
1823
|
+
panel: {
|
|
1824
|
+
title: "Tâche planifiée",
|
|
1825
|
+
"load-failed": "La tâche n’a pas pu être chargée.",
|
|
1826
|
+
"not-found": {
|
|
1827
|
+
title: "Tâche introuvable",
|
|
1828
|
+
description: "Cette tâche n’existe pas ou plus : elle a peut-être été supprimée."
|
|
1766
1829
|
}
|
|
1767
1830
|
}
|
|
1768
1831
|
}
|
|
@@ -4008,6 +4071,7 @@ const He = {
|
|
|
4008
4071
|
event: {
|
|
4009
4072
|
MONITOR_EVENT: "Monitor event",
|
|
4010
4073
|
MONITOR_SENTINEL: "Monitor probe",
|
|
4074
|
+
MONITOR_FEEDBACK_RESPONDED: "Feedback request answered",
|
|
4011
4075
|
STORAGE_UPLOAD: "File uploaded",
|
|
4012
4076
|
STORAGE_WRITE: "File modified",
|
|
4013
4077
|
STORAGE_DELETE: "File deleted",
|
|
@@ -4276,6 +4340,15 @@ const He = {
|
|
|
4276
4340
|
timeout: "Maximum time",
|
|
4277
4341
|
retries: "Retries",
|
|
4278
4342
|
"retry-delay": "Delay between attempts",
|
|
4343
|
+
"retry-backoff": "Delay growth",
|
|
4344
|
+
"retry-backoff-option": {
|
|
4345
|
+
LINEAR: "Growing",
|
|
4346
|
+
FIXED: "Fixed"
|
|
4347
|
+
},
|
|
4348
|
+
"retry-backoff-help": {
|
|
4349
|
+
LINEAR: "Each new attempt waits one delay more: 1×, 2×, 3× the delay between attempts.",
|
|
4350
|
+
FIXED: "Every attempt waits the same delay."
|
|
4351
|
+
},
|
|
4279
4352
|
enabled: "Task active",
|
|
4280
4353
|
"error-name": "Enter a name.",
|
|
4281
4354
|
"error-schedule": "Enter a schedule.",
|
|
@@ -4296,11 +4369,64 @@ const He = {
|
|
|
4296
4369
|
pagination: "Run pages",
|
|
4297
4370
|
empty: "No run",
|
|
4298
4371
|
"empty-desc": "The runs of this task show up here.",
|
|
4372
|
+
"empty-filtered": "No run matches these filters",
|
|
4373
|
+
"empty-filtered-desc": "Widen the period or clear the request id.",
|
|
4299
4374
|
column: {
|
|
4300
4375
|
status: "Status",
|
|
4301
4376
|
"scheduled-for": "Scheduled for",
|
|
4302
4377
|
duration: "Duration",
|
|
4303
4378
|
code: "Response code"
|
|
4379
|
+
},
|
|
4380
|
+
action: {
|
|
4381
|
+
detail: "Run detail"
|
|
4382
|
+
},
|
|
4383
|
+
filters: {
|
|
4384
|
+
period: "Period",
|
|
4385
|
+
preset: {
|
|
4386
|
+
today: "Today",
|
|
4387
|
+
"last-7-days": "Last 7 days",
|
|
4388
|
+
"last-30-days": "Last 30 days"
|
|
4389
|
+
},
|
|
4390
|
+
"request-id": "Request id",
|
|
4391
|
+
"request-id-invalid": "Enter the whole id, as sent in the x-request-id header.",
|
|
4392
|
+
outcome: "Outcome",
|
|
4393
|
+
"outcome-option": {
|
|
4394
|
+
all: "All outcomes",
|
|
4395
|
+
succeeded: "Succeeded",
|
|
4396
|
+
failed: "Failed or timed out",
|
|
4397
|
+
skipped: "Skipped"
|
|
4398
|
+
},
|
|
4399
|
+
"outcome-subset": "{shown, number} of {count, plural, one {# run} other {# runs}} on this page have this outcome.",
|
|
4400
|
+
"outcome-empty": "No run on this page has this outcome.",
|
|
4401
|
+
reset: "Clear the filters"
|
|
4402
|
+
}
|
|
4403
|
+
},
|
|
4404
|
+
run: {
|
|
4405
|
+
back: "Back to the runs",
|
|
4406
|
+
logs: "See the logs of this request",
|
|
4407
|
+
request: "Request",
|
|
4408
|
+
"scheduled-for": "Scheduled for",
|
|
4409
|
+
"started-at": "Started at",
|
|
4410
|
+
"not-started": "Not started yet",
|
|
4411
|
+
attempt: "Attempt",
|
|
4412
|
+
duration: "Duration",
|
|
4413
|
+
response: "Response",
|
|
4414
|
+
"response-code": "Response code",
|
|
4415
|
+
"response-headers": "Response headers",
|
|
4416
|
+
"response-body": "Response body",
|
|
4417
|
+
error: "Error",
|
|
4418
|
+
none: "None",
|
|
4419
|
+
archived: {
|
|
4420
|
+
title: "Detail archived",
|
|
4421
|
+
description: "The headers, the response body and the error of this run are in the archive."
|
|
4422
|
+
}
|
|
4423
|
+
},
|
|
4424
|
+
panel: {
|
|
4425
|
+
title: "Scheduled task",
|
|
4426
|
+
"load-failed": "The task could not be loaded.",
|
|
4427
|
+
"not-found": {
|
|
4428
|
+
title: "Task not found",
|
|
4429
|
+
description: "This task does not exist, or no longer does: it may have been deleted."
|
|
4304
4430
|
}
|
|
4305
4431
|
}
|
|
4306
4432
|
}
|
|
@@ -5724,10 +5850,10 @@ function Je() {
|
|
|
5724
5850
|
function o(i, n) {
|
|
5725
5851
|
n = n || {};
|
|
5726
5852
|
const g = n.delimiter || ".", y = n.maxDepth, E = n.transformKey || t, f = {};
|
|
5727
|
-
function A(v,
|
|
5853
|
+
function A(v, R, u) {
|
|
5728
5854
|
u = u || 1, Object.keys(v).forEach(function(l) {
|
|
5729
|
-
const s = v[l], p = n.safe && Array.isArray(s), b = Object.prototype.toString.call(s),
|
|
5730
|
-
if (!p && !
|
|
5855
|
+
const s = v[l], p = n.safe && Array.isArray(s), b = Object.prototype.toString.call(s), T = e(s), S = b === "[object Object]" || b === "[object Array]", I = R ? R + g + E(l) : E(l);
|
|
5856
|
+
if (!p && !T && S && Object.keys(s).length && (!n.maxDepth || u < y))
|
|
5731
5857
|
return A(s, I, u + 1);
|
|
5732
5858
|
f[I] = s;
|
|
5733
5859
|
});
|
|
@@ -5743,9 +5869,9 @@ function Je() {
|
|
|
5743
5869
|
const s = Number(l);
|
|
5744
5870
|
return isNaN(s) || l.indexOf(".") !== -1 || n.object ? l : s;
|
|
5745
5871
|
}
|
|
5746
|
-
function
|
|
5747
|
-
return Object.keys(p).reduce(function(b,
|
|
5748
|
-
return b[l + g +
|
|
5872
|
+
function R(l, s, p) {
|
|
5873
|
+
return Object.keys(p).reduce(function(b, T) {
|
|
5874
|
+
return b[l + g + T] = p[T], b;
|
|
5749
5875
|
}, s);
|
|
5750
5876
|
}
|
|
5751
5877
|
function u(l) {
|
|
@@ -5759,23 +5885,23 @@ function Je() {
|
|
|
5759
5885
|
}
|
|
5760
5886
|
return i = Object.keys(i).reduce(function(l, s) {
|
|
5761
5887
|
const p = Object.prototype.toString.call(i[s]);
|
|
5762
|
-
return !(p === "[object Object]" || p === "[object Array]") || u(i[s]) ? (l[s] = i[s], l) :
|
|
5888
|
+
return !(p === "[object Object]" || p === "[object Array]") || u(i[s]) ? (l[s] = i[s], l) : R(
|
|
5763
5889
|
s,
|
|
5764
5890
|
l,
|
|
5765
5891
|
o(i[s], n)
|
|
5766
5892
|
);
|
|
5767
5893
|
}, {}), Object.keys(i).forEach(function(l) {
|
|
5768
5894
|
const s = l.split(g).map(E);
|
|
5769
|
-
let p = v(s.shift()), b = v(s[0]),
|
|
5895
|
+
let p = v(s.shift()), b = v(s[0]), T = f;
|
|
5770
5896
|
for (; b !== void 0; ) {
|
|
5771
5897
|
if (p === "__proto__")
|
|
5772
5898
|
return;
|
|
5773
|
-
const
|
|
5774
|
-
if (!y && !I && typeof
|
|
5899
|
+
const S = Object.prototype.toString.call(T[p]), I = S === "[object Object]" || S === "[object Array]";
|
|
5900
|
+
if (!y && !I && typeof T[p] < "u")
|
|
5775
5901
|
return;
|
|
5776
|
-
(y && !I || !y &&
|
|
5902
|
+
(y && !I || !y && T[p] == null) && (T[p] = typeof b == "number" && !n.object ? [] : {}), T = T[p], s.length > 0 && (p = v(s.shift()), b = v(s[0]));
|
|
5777
5903
|
}
|
|
5778
|
-
|
|
5904
|
+
T[p] = r(i[l], n);
|
|
5779
5905
|
}), f;
|
|
5780
5906
|
}
|
|
5781
5907
|
return x;
|
|
@@ -5873,7 +5999,7 @@ export {
|
|
|
5873
5999
|
Ot as A,
|
|
5874
6000
|
De as B,
|
|
5875
6001
|
Le as C,
|
|
5876
|
-
|
|
6002
|
+
N as D,
|
|
5877
6003
|
Et as E,
|
|
5878
6004
|
vt as F,
|
|
5879
6005
|
Ke as G,
|
|
@@ -5903,16 +6029,16 @@ export {
|
|
|
5903
6029
|
me as l,
|
|
5904
6030
|
be as m,
|
|
5905
6031
|
At as n,
|
|
5906
|
-
|
|
6032
|
+
St as o,
|
|
5907
6033
|
a as p,
|
|
5908
6034
|
V as q,
|
|
5909
6035
|
ft as r,
|
|
5910
|
-
|
|
5911
|
-
|
|
6036
|
+
Tt as s,
|
|
6037
|
+
Nt as t,
|
|
5912
6038
|
wt as u,
|
|
5913
6039
|
gt as v,
|
|
5914
6040
|
L as w,
|
|
5915
6041
|
yt as x,
|
|
5916
6042
|
fe as y,
|
|
5917
|
-
|
|
6043
|
+
Rt as z
|
|
5918
6044
|
};
|
|
@@ -8,7 +8,7 @@ import hn from "@mui/material/Select";
|
|
|
8
8
|
import { styled as l, useTheme as bn, getContrastRatio as ke } from "@mui/material/styles";
|
|
9
9
|
import { visuallyHidden as fe } from "@mui/utils";
|
|
10
10
|
import { useIntl as P } from "react-intl";
|
|
11
|
-
import { a as A, p as o, h as D, d as Z, D as K, g as yn, t as De, s as de, i as oe, j as te, c as Pe, e as He, k as vn, B as wn } from "./Surface-
|
|
11
|
+
import { a as A, p as o, h as D, d as Z, D as K, g as yn, t as De, s as de, i as oe, j as te, c as Pe, e as He, k as vn, B as wn } from "./Surface-rKrLIx9x.js";
|
|
12
12
|
import { i as xn, b as Cn, r as kn, u as Sn, A as In, E as Fn } from "./index-C27b790L.js";
|
|
13
13
|
import Y from "@mui/material/Button";
|
|
14
14
|
import { byteSizeIEC as Wn } from "@abyss-project/main";
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
1
2
|
import { DeliveryEventType, FlowDeliverySource, ICreateDeliverySubscriptionBody, IDeliverySubscription, IUpdateDeliverySubscriptionBody } from '@abyss-project/flow';
|
|
3
|
+
import { DeliveryFiltersSlotProps } from './deliveries.types';
|
|
2
4
|
/** What the form hands back: a creation, or the editable part of a subscription. */
|
|
3
5
|
export type DeliverySubscriptionFormResult = {
|
|
4
6
|
create: ICreateDeliverySubscriptionBody;
|
|
@@ -13,12 +15,15 @@ interface DeliverySubscriptionFormProps {
|
|
|
13
15
|
/** A rejection stays in the form, with the message of the rejection. */
|
|
14
16
|
onSubmit(result: DeliverySubscriptionFormResult): Promise<void>;
|
|
15
17
|
onCancel(): void;
|
|
18
|
+
/** The host's filters editor; without it, the filters are neither shown nor sent. */
|
|
19
|
+
renderFilters?(props: DeliveryFiltersSlotProps): ReactNode;
|
|
16
20
|
}
|
|
17
21
|
/**
|
|
18
22
|
* The body of the create and edit drawer. It lives inside the drawer so that closing it drops the
|
|
19
23
|
* typed values. The source is chosen at creation and cannot change after (no choice is drawn when
|
|
20
24
|
* the host offers one source); its event types are the only ones offered, and the body format only
|
|
21
|
-
* exists for a Form subscription.
|
|
25
|
+
* exists for a Form subscription. The filters are the host's editor, when it passes one: a change of
|
|
26
|
+
* source empties them.
|
|
22
27
|
*/
|
|
23
|
-
export declare function DeliverySubscriptionForm({ subscription, sources, eventTypesBySource, onSubmit, onCancel, }: DeliverySubscriptionFormProps): import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
export declare function DeliverySubscriptionForm({ subscription, sources, eventTypesBySource, onSubmit, onCancel, renderFilters, }: DeliverySubscriptionFormProps): import("react/jsx-runtime").JSX.Element;
|
|
24
29
|
export {};
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
1
2
|
import { ICreateScheduledTaskBody, IScheduledTask, IUpdateScheduledTaskBody } from '@abyss-project/flow';
|
|
3
|
+
import { ScheduledTaskIncidentPolicySlotProps } from './deliveries.types';
|
|
2
4
|
/** What the form hands back: a creation, or the editable part of a task. */
|
|
3
5
|
export type ScheduledTaskFormResult = {
|
|
4
6
|
create: ICreateScheduledTaskBody;
|
|
@@ -11,11 +13,15 @@ interface ScheduledTaskFormProps {
|
|
|
11
13
|
/** A rejection stays in the form, with the message of the rejection. */
|
|
12
14
|
onSubmit(result: ScheduledTaskFormResult): Promise<void>;
|
|
13
15
|
onCancel(): void;
|
|
16
|
+
/** The host's incident-policy editor; without it, the policy is neither shown nor sent. */
|
|
17
|
+
renderIncidentPolicy?(props: ScheduledTaskIncidentPolicySlotProps): ReactNode;
|
|
14
18
|
}
|
|
15
19
|
/**
|
|
16
20
|
* The body of the create and edit drawer. It lives inside the drawer so that closing it drops the
|
|
17
21
|
* typed values. The schedule is checked by Flow: an invalid cron comes back as a rejection and its
|
|
18
|
-
* message is shown at the top of the form. The retry settings left empty keep Flow's defaults
|
|
22
|
+
* message is shown at the top of the form. The retry settings left empty keep Flow's defaults; the
|
|
23
|
+
* backoff is always sent (a new task starts on Flow's default, linear). The incident policy is the
|
|
24
|
+
* host's editor, when it passes one.
|
|
19
25
|
*/
|
|
20
|
-
export declare function ScheduledTaskForm({ task, onSubmit, onCancel, }: ScheduledTaskFormProps): import("react/jsx-runtime").JSX.Element;
|
|
26
|
+
export declare function ScheduledTaskForm({ task, onSubmit, onCancel, renderIncidentPolicy, }: ScheduledTaskFormProps): import("react/jsx-runtime").JSX.Element;
|
|
21
27
|
export {};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { IScheduledTask } from '@abyss-project/flow';
|
|
3
|
+
import { ScheduledTasksProps } from './deliveries.types';
|
|
4
|
+
interface TaskPanelProps {
|
|
5
|
+
task: IScheduledTask;
|
|
6
|
+
listRuns: ScheduledTasksProps['listRuns'];
|
|
7
|
+
runLogsHref: ScheduledTasksProps['runLogsHref'];
|
|
8
|
+
renderTaskState: ScheduledTasksProps['renderTaskState'];
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* The panel of one task: the host's state card, then its runs, newest first, with their filters
|
|
12
|
+
* (a period and a request id, applied by Flow; an outcome, applied to the page loaded, which a
|
|
13
|
+
* line says), and the detail of a run in place of the list. The list stays mounted under the
|
|
14
|
+
* detail: going back finds the same page and the same filters.
|
|
15
|
+
*/
|
|
16
|
+
export declare function TaskPanel({ task, listRuns, runLogsHref, renderTaskState, }: TaskPanelProps): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
interface LinkedTaskProps {
|
|
18
|
+
taskId: string;
|
|
19
|
+
get: ScheduledTasksProps['get'];
|
|
20
|
+
/** The task, once loaded: the panel's title names it. */
|
|
21
|
+
onLoaded(task: IScheduledTask): void;
|
|
22
|
+
children(task: IScheduledTask): ReactElement;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* The task a link points to, loaded by its id: a skeleton meanwhile, then its panel. A task that
|
|
26
|
+
* does not exist (any more: deleted, or the id of a task Flow never had) says so; any other
|
|
27
|
+
* failure offers a retry.
|
|
28
|
+
*/
|
|
29
|
+
export declare function LinkedTask({ taskId, get, onLoaded, children, }: LinkedTaskProps): import("react/jsx-runtime").JSX.Element;
|
|
30
|
+
export {};
|
|
@@ -3,7 +3,8 @@ import { ScheduledTasksProps } from './deliveries.types';
|
|
|
3
3
|
/**
|
|
4
4
|
* The scheduled tasks of a scope: the list, the create and edit drawer, the secret shown once
|
|
5
5
|
* after a creation or a regeneration, the enable switch, « run now », the confirmed delete and the
|
|
6
|
-
*
|
|
7
|
-
*
|
|
6
|
+
* panel of a task (the host's state card, the runs with their filters and the detail of a run),
|
|
7
|
+
* which a link to one task (`initialTaskId`) opens on arrival. Data and actions come through props
|
|
8
|
+
* (see `ScheduledTasksProps`); the actions a viewer lacks the permission for are not drawn.
|
|
8
9
|
*/
|
|
9
10
|
export declare const ScheduledTasks: FC<ScheduledTasksProps>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { IntlShape } from 'react-intl';
|
|
2
|
-
import { DeliveryFormat, DeliveryStatus, FlowDeliverySource, IDelivery, ScheduledTaskRunStatus } from '@abyss-project/flow';
|
|
2
|
+
import { DeliveryFormat, DeliveryStatus, FlowDeliverySource, IDelivery, IPaginateScheduledTaskRunQuery, IScheduledTaskRun, ScheduledTaskRetryBackoff, ScheduledTaskRunStatus } from '@abyss-project/flow';
|
|
3
3
|
import { ExecutionState } from '../../../theme/tokens/domain';
|
|
4
4
|
import { StatusTone } from '../../meaning/StatusBadge/StatusBadge';
|
|
5
5
|
/**
|
|
@@ -36,6 +36,41 @@ export declare const isReplayable: (delivery: IDelivery) => boolean;
|
|
|
36
36
|
export declare const deliveryHeaders: (delivery: IDelivery) => Array<[name: string, value: string]>;
|
|
37
37
|
/** Presets the schedule field offers beside a free cron (the aliases Flow accepts). */
|
|
38
38
|
export declare const SCHEDULE_PRESETS: readonly ["@hourly", "@daily", "@weekly", "@monthly"];
|
|
39
|
+
/**
|
|
40
|
+
* How the wait between two attempts of a run grows: `LINEAR` (Flow's default, retry n waits
|
|
41
|
+
* `retryDelayMs` times n) first, then `FIXED` (`retryDelayMs` every time).
|
|
42
|
+
*/
|
|
43
|
+
export declare const RETRY_BACKOFFS: ScheduledTaskRetryBackoff[];
|
|
44
|
+
/** The backoff of a new task, Flow's own default. */
|
|
45
|
+
export declare const DEFAULT_RETRY_BACKOFF: ScheduledTaskRetryBackoff;
|
|
46
|
+
/** What the outcome filter of the runs keeps. */
|
|
47
|
+
export declare enum RunOutcome {
|
|
48
|
+
All = "all",
|
|
49
|
+
Succeeded = "succeeded",
|
|
50
|
+
/** Failed or timed out. */
|
|
51
|
+
Failed = "failed",
|
|
52
|
+
Skipped = "skipped"
|
|
53
|
+
}
|
|
54
|
+
/** Whether a run has the outcome the filter keeps; a pending or running run is only in « all ». */
|
|
55
|
+
export declare const runHasOutcome: (run: Pick<IScheduledTaskRun, "status">, outcome: RunOutcome) => boolean;
|
|
56
|
+
export declare const isRequestId: (value: string) => boolean;
|
|
57
|
+
/** The filters of the runs that Flow applies, as typed by the viewer. */
|
|
58
|
+
export interface RunServerFilters {
|
|
59
|
+
range: {
|
|
60
|
+
from: Date | null;
|
|
61
|
+
to: Date | null;
|
|
62
|
+
};
|
|
63
|
+
/** Trimmed; empty when the viewer filters on no request. */
|
|
64
|
+
requestId: string;
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* The query of these filters: the bounds are whole days of the viewer (the first instant of the
|
|
68
|
+
* start day, the last of the end day), in ISO 8601; a request id that is not complete is left out
|
|
69
|
+
* (the field says so).
|
|
70
|
+
*/
|
|
71
|
+
export declare const runFilterQuery: (filters: RunServerFilters) => Pick<IPaginateScheduledTaskRunQuery, "from" | "to" | "requestId">;
|
|
72
|
+
/** The headers a run's answer came with, sorted by name; none when Flow kept none. */
|
|
73
|
+
export declare const runResponseHeaders: (run: Pick<IScheduledTaskRun, "responseHeaders">) => Array<[name: string, value: string]>;
|
|
39
74
|
/**
|
|
40
75
|
* What a rejected call says, when it says something: the validation message of a Flow answer, its
|
|
41
76
|
* message, or the message of a plain `Error`. `null` when the rejection carries no text (the
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { BasePaginate, DeliveryEventType, FlowDeliverySource, ICreateDeliverySubscriptionBody, ICreateScheduledTaskBody, ICreateRehydrationBody, ICreateRehydrationData, IDelivery, IDeliverySubscription, IEstimateRehydrationData, IEstimateRehydrationQuery, IArchivedDay, IListRehydrationData, IPurgeArchiveBody, IPurgeArchiveData, IRehydrationJob, IPaginateDeliveryQuery, IPaginateDeliverySubscriptionQuery, IPaginateScheduledTaskQuery, IPaginateScheduledTaskRunQuery, IScheduledTask, IScheduledTaskRun, IUpdateDeliverySubscriptionBody, IUpdateScheduledTaskBody, ScheduledTaskIncidentPolicy } from '@abyss-project/flow';
|
|
2
3
|
/**
|
|
3
4
|
* The Deliveries components are data-agnostic: every datum and every action goes through a prop
|
|
4
5
|
* that returns a promise, so each service front binds its own Flow SDK calls (scope included) and
|
|
@@ -26,6 +27,23 @@ export interface ScheduledTaskWithSecret {
|
|
|
26
27
|
scheduledTask: IScheduledTask;
|
|
27
28
|
secret: string;
|
|
28
29
|
}
|
|
30
|
+
/** The `filters` of a subscription as Flow stores them: blocks keyed by kind, or none. */
|
|
31
|
+
export type DeliverySubscriptionFilters = IDeliverySubscription['filters'];
|
|
32
|
+
/** What the host's filters editor receives, inside the create and edit drawer. */
|
|
33
|
+
export interface DeliveryFiltersSlotProps {
|
|
34
|
+
/** The source chosen in the form: a change of source empties the filters. */
|
|
35
|
+
source: FlowDeliverySource;
|
|
36
|
+
/**
|
|
37
|
+
* The event types ticked in the form. A block of filters requires its event type (Flow refuses
|
|
38
|
+
* it otherwise): the editor drops or hides a block whose type is no longer ticked.
|
|
39
|
+
*/
|
|
40
|
+
eventTypes: DeliveryEventType[];
|
|
41
|
+
/** The filters being edited: those of the subscription, `null` at creation. */
|
|
42
|
+
value: DeliverySubscriptionFilters;
|
|
43
|
+
onChange(next: DeliverySubscriptionFilters): void;
|
|
44
|
+
/** The subscription edited; `null` at creation. */
|
|
45
|
+
subscription: IDeliverySubscription | null;
|
|
46
|
+
}
|
|
29
47
|
export interface DeliverySubscriptionsProps {
|
|
30
48
|
/** The sources the host may subscribe to (the form offers these only). */
|
|
31
49
|
sources: FlowDeliverySource[];
|
|
@@ -43,6 +61,13 @@ export interface DeliverySubscriptionsProps {
|
|
|
43
61
|
*/
|
|
44
62
|
flowUrl?: string;
|
|
45
63
|
permissions: DeliverySubscriptionPermissions;
|
|
64
|
+
/**
|
|
65
|
+
* The filters editor of the host, drawn in the form under the event types. With it, the creation
|
|
66
|
+
* and the update send `filters` (what it holds, `null` for none: an update replaces the
|
|
67
|
+
* filters, never merges them); without it, `filters` is never sent and an update keeps the
|
|
68
|
+
* subscription's own.
|
|
69
|
+
*/
|
|
70
|
+
renderFilters?(props: DeliveryFiltersSlotProps): ReactNode;
|
|
46
71
|
}
|
|
47
72
|
/**
|
|
48
73
|
* The archive of one subscription's history, past the 30 days where a delivery keeps its body:
|
|
@@ -87,6 +112,14 @@ export interface DeliveryHistoryProps {
|
|
|
87
112
|
/** Where « Ouvrir dans Flow » leads; without it, no link is drawn. */
|
|
88
113
|
flowUrl?: string;
|
|
89
114
|
}
|
|
115
|
+
/** What the host's incident-policy editor receives, inside the create and edit drawer. */
|
|
116
|
+
export interface ScheduledTaskIncidentPolicySlotProps {
|
|
117
|
+
/** The policy being edited: the task's, `null` at creation or for a task without one. */
|
|
118
|
+
value: ScheduledTaskIncidentPolicy | null;
|
|
119
|
+
onChange(next: ScheduledTaskIncidentPolicy | null): void;
|
|
120
|
+
/** The task edited; `null` at creation. */
|
|
121
|
+
task: IScheduledTask | null;
|
|
122
|
+
}
|
|
90
123
|
export interface ScheduledTasksProps {
|
|
91
124
|
list(params: IPaginateScheduledTaskQuery): Promise<BasePaginate<IScheduledTask>>;
|
|
92
125
|
create(body: ICreateScheduledTaskBody): Promise<ScheduledTaskWithSecret>;
|
|
@@ -95,8 +128,40 @@ export interface ScheduledTasksProps {
|
|
|
95
128
|
regenerateSecret(id: string): Promise<ScheduledTaskWithSecret>;
|
|
96
129
|
/** « Run now »: queues one run at once. */
|
|
97
130
|
trigger(id: string): Promise<void>;
|
|
131
|
+
/**
|
|
132
|
+
* The runs of a task, newest first. The date range and the request id of the run filters are
|
|
133
|
+
* Flow's (`from`, `to`, `requestId`); the outcome filter narrows the page loaded.
|
|
134
|
+
*/
|
|
98
135
|
listRuns(id: string, params: IPaginateScheduledTaskRunQuery): Promise<BasePaginate<IScheduledTaskRun>>;
|
|
136
|
+
/**
|
|
137
|
+
* One task, for a deep link (`initialTaskId`). A rejection whose answer is a 404 is drawn as a
|
|
138
|
+
* task that does not exist (any more); any other one as a failure with a retry.
|
|
139
|
+
*/
|
|
140
|
+
get(id: string): Promise<IScheduledTask>;
|
|
99
141
|
permissions: ScheduledTaskPermissions;
|
|
100
|
-
/** Where « Ouvrir dans Flow » leads. */
|
|
101
|
-
flowUrl
|
|
142
|
+
/** Where « Ouvrir dans Flow » leads. Without it, no link is drawn. */
|
|
143
|
+
flowUrl?: string;
|
|
144
|
+
/**
|
|
145
|
+
* The task whose panel (its state, its runs) opens on arrival, loaded with `get`: the target of
|
|
146
|
+
* a link to one task. A new value opens that task.
|
|
147
|
+
*/
|
|
148
|
+
initialTaskId?: string;
|
|
149
|
+
/** The panel of a task was closed: a host on the route of one task goes back to the list's. */
|
|
150
|
+
onCloseTask?(): void;
|
|
151
|
+
/**
|
|
152
|
+
* The screen of the host's logs for the request of a run (its `requestId`, sent as
|
|
153
|
+
* `x-request-id`), drawn as a link in the run detail. `undefined`: no link for that run.
|
|
154
|
+
*/
|
|
155
|
+
runLogsHref?(run: IScheduledTaskRun): string | undefined;
|
|
156
|
+
/**
|
|
157
|
+
* The host's incident-policy editor, drawn in the form under the retry settings. With it, the
|
|
158
|
+
* creation and the update send `incidentPolicy` (what it holds, `null` for none); without it,
|
|
159
|
+
* `incidentPolicy` is never sent and an update keeps the task's own.
|
|
160
|
+
*/
|
|
161
|
+
renderIncidentPolicy?(props: ScheduledTaskIncidentPolicySlotProps): ReactNode;
|
|
162
|
+
/**
|
|
163
|
+
* The host's card of a task's state (failure streak, open incident), drawn at the head of the
|
|
164
|
+
* task's panel, above its runs.
|
|
165
|
+
*/
|
|
166
|
+
renderTaskState?(task: IScheduledTask): ReactNode;
|
|
102
167
|
}
|