@mtes-mct/monitor-ui 24.56.0 → 24.56.1
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 +6 -0
- package/fields/CheckTreePicker/index.d.ts.map +1 -1
- package/index.js +86 -93
- package/libs/CustomSearch/index.d.ts.map +1 -1
- package/package.json +1 -2
- package/stats.html +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
## [24.56.0](https://github.com/MTES-MCT/monitor-ui/compare/v24.55.6...v24.56.0) (2026-07-13)
|
|
2
|
+
|
|
3
|
+
### Features
|
|
4
|
+
|
|
5
|
+
* **components:** delete button as button ([b4662dc](https://github.com/MTES-MCT/monitor-ui/commit/b4662dc76324ac5e57b623be68a4a76afc6bcfa3))
|
|
6
|
+
|
|
1
7
|
## [24.55.6](https://github.com/MTES-MCT/monitor-ui/compare/v24.55.5...v24.55.6) (2026-07-08)
|
|
2
8
|
|
|
3
9
|
### Bug Fixes
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/fields/CheckTreePicker/index.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;AAKjD,OAAc,EAEZ,KAAK,cAAc,EAOpB,MAAM,OAAO,CAAA;AACd,OAAO,EAGL,KAAK,oBAAoB,IAAI,0BAA0B,EACxD,MAAM,QAAQ,CAAA;AAmBf,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAA;AAEzC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,WAAW,CAAA;AAE3C,MAAM,MAAM,oBAAoB,GAAG,IAAI,CACrC,0BAA0B,EAC1B,IAAI,GAAG,WAAW,GAAG,MAAM,GAAG,cAAc,GAAG,IAAI,GAAG,UAAU,GAAG,gBAAgB,GAAG,OAAO,CAC9F,GAAG;IACF,YAAY,CAAC,EAAE,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728
|
-
#
|
|
10728
|
+
#e;
|
|
10729
10729
|
/** See {@link CustomSearchOptions.isDiacriticSensitive}. */
|
|
10730
|
-
#
|
|
10730
|
+
#r;
|
|
10731
10731
|
/** See {@link CustomSearchOptions.isStrict}. */
|
|
10732
|
-
#
|
|
10733
|
-
#e;
|
|
10732
|
+
#n;
|
|
10734
10733
|
constructor(t, r, {
|
|
10735
10734
|
cacheKey: n,
|
|
10736
10735
|
childrenKey: i,
|
|
@@ -10741,8 +10740,8 @@ class M9 {
|
|
|
10741
10740
|
threshold: c = 0.4,
|
|
10742
10741
|
withCacheInvalidation: d = !1
|
|
10743
10742
|
} = {}) {
|
|
10744
|
-
const f = x9(t, n, d), h = this.#
|
|
10745
|
-
if (this.#
|
|
10743
|
+
const f = x9(t, n, d), h = this.#i(t, i), p = f?.normalizedCollection ?? a ? h : w9(x2(h), r);
|
|
10744
|
+
if (this.#e = new Ot(
|
|
10746
10745
|
p,
|
|
10747
10746
|
{
|
|
10748
10747
|
ignoreLocation: u,
|
|
@@ -10752,9 +10751,9 @@ class M9 {
|
|
|
10752
10751
|
useExtendedSearch: l
|
|
10753
10752
|
},
|
|
10754
10753
|
f ? Ot.parseIndex(f.fuseSearchIndex) : void 0
|
|
10755
|
-
), this.#
|
|
10754
|
+
), this.#r = a, this.#n = l, this.#t = h, n && !f) {
|
|
10756
10755
|
const A = {
|
|
10757
|
-
fuseSearchIndex: this.#
|
|
10756
|
+
fuseSearchIndex: this.#e.getIndex(),
|
|
10758
10757
|
normalizedCollection: p,
|
|
10759
10758
|
originalCollection: t,
|
|
10760
10759
|
originalCollectionHash: _a(t)
|
|
@@ -10770,29 +10769,15 @@ class M9 {
|
|
|
10770
10769
|
* @returns A list of matching items
|
|
10771
10770
|
*/
|
|
10772
10771
|
find(t, r) {
|
|
10773
|
-
const n = (this.#
|
|
10774
|
-
return this.#e
|
|
10775
|
-
}
|
|
10776
|
-
/**
|
|
10777
|
-
* Recursively filters tree nodes based on the search.
|
|
10778
|
-
*/
|
|
10779
|
-
#o(t, r, n) {
|
|
10780
|
-
return t.map((i) => {
|
|
10781
|
-
const o = this.#e ? i[this.#e] : void 0;
|
|
10782
|
-
let a;
|
|
10783
|
-
if (o && Array.isArray(o) && (a = this.#o(o, r)), this.#r.search(r, n ? { limit: n } : void 0).some((u) => this.#t[u.refIndex] === i) || a && a.length > 0)
|
|
10784
|
-
return {
|
|
10785
|
-
...i,
|
|
10786
|
-
...a ? { [this.#e]: a } : {}
|
|
10787
|
-
};
|
|
10788
|
-
}).filter((i) => i !== void 0);
|
|
10772
|
+
const n = (this.#r ? t : yo.remove(t)).trim(), i = this.#n ? n.split(/\s+/).map((o) => `'${o}`).join(" ") : n;
|
|
10773
|
+
return this.#e.search(i, r ? { limit: r } : void 0).map(({ refIndex: o }) => this.#t[o]);
|
|
10789
10774
|
}
|
|
10790
|
-
#
|
|
10775
|
+
#i(t, r) {
|
|
10791
10776
|
return t.reduce((n, i) => {
|
|
10792
10777
|
const { [r]: o, ...a } = i;
|
|
10793
10778
|
n.push(a);
|
|
10794
10779
|
const l = i[r];
|
|
10795
|
-
return l?.length && n.push(...this.#
|
|
10780
|
+
return l?.length && n.push(...this.#i(l, r)), n;
|
|
10796
10781
|
}, []);
|
|
10797
10782
|
}
|
|
10798
10783
|
}
|
|
@@ -11400,7 +11385,7 @@ function z9({
|
|
|
11400
11385
|
[E, e, I]
|
|
11401
11386
|
);
|
|
11402
11387
|
ne(() => {
|
|
11403
|
-
B &&
|
|
11388
|
+
B && re(j);
|
|
11404
11389
|
}, [j, B]);
|
|
11405
11390
|
const le = P(
|
|
11406
11391
|
() => r ?? new M9(
|
|
@@ -11419,39 +11404,39 @@ function z9({
|
|
|
11419
11404
|
{ childrenKey: e, isStrict: !0, withCacheInvalidation: !0 }
|
|
11420
11405
|
),
|
|
11421
11406
|
[r, j, m, e]
|
|
11422
|
-
), [Me,
|
|
11407
|
+
), [Me, re] = ee(B ? j : []), [de, ye] = ee([]), He = P(
|
|
11423
11408
|
() => I9(j, I, e),
|
|
11424
11409
|
[j, e, I]
|
|
11425
11410
|
), me = P(() => {
|
|
11426
|
-
const
|
|
11411
|
+
const te = D9(O, j, e, I);
|
|
11427
11412
|
return ye(
|
|
11428
|
-
!d &&
|
|
11429
|
-
),
|
|
11413
|
+
!d && te ? L9(d, te, j, e, I, m) : []
|
|
11414
|
+
), te;
|
|
11430
11415
|
}, [e, d, j, O, I, m]), st = P(
|
|
11431
|
-
() => aa((
|
|
11416
|
+
() => aa((te) => {
|
|
11432
11417
|
Y(() => {
|
|
11433
|
-
if (Z(
|
|
11434
|
-
|
|
11418
|
+
if (Z(te), !le || te.trim().length < n) {
|
|
11419
|
+
re(j);
|
|
11435
11420
|
return;
|
|
11436
11421
|
}
|
|
11437
|
-
const Et = le.find(
|
|
11422
|
+
const Et = le.find(te).map((ht) => ht[I]), Rt = (pi(Et, j, !1, e, I, m) ?? []).map((ht) => {
|
|
11438
11423
|
const Wr = ht?.[e];
|
|
11439
11424
|
return !Wr || Wr.length === 0 ? { [m]: ht?.[m], [I]: ht?.[I] } : ht;
|
|
11440
11425
|
}).filter((ht) => ht !== void 0), Pe = pi(me ?? [], j, !1, e, I, m) ?? [], Ht = rl([...Rt, ...Pe], e, I, m);
|
|
11441
|
-
|
|
11426
|
+
re(Ht);
|
|
11442
11427
|
});
|
|
11443
11428
|
}, 150),
|
|
11444
11429
|
[e, n, m, le, j, me, I]
|
|
11445
11430
|
), At = z(
|
|
11446
|
-
(
|
|
11447
|
-
st(
|
|
11431
|
+
(te, Fe) => {
|
|
11432
|
+
st(te), C && C(te, Fe);
|
|
11448
11433
|
},
|
|
11449
11434
|
[st, C]
|
|
11450
|
-
), Se = z((
|
|
11451
|
-
se(
|
|
11435
|
+
), Se = z((te) => {
|
|
11436
|
+
se(te);
|
|
11452
11437
|
}, []), bt = P(() => {
|
|
11453
|
-
const
|
|
11454
|
-
return !u || U.trim().length >= n ?
|
|
11438
|
+
const te = B ? Me : j;
|
|
11439
|
+
return !u || U.trim().length >= n ? te : el(te, new Set(X), e, I, m);
|
|
11455
11440
|
}, [
|
|
11456
11441
|
B,
|
|
11457
11442
|
Me,
|
|
@@ -11464,17 +11449,17 @@ function z9({
|
|
|
11464
11449
|
n,
|
|
11465
11450
|
u
|
|
11466
11451
|
]), Ct = z(
|
|
11467
|
-
(
|
|
11452
|
+
(te) => {
|
|
11468
11453
|
if (!y)
|
|
11469
11454
|
return;
|
|
11470
|
-
const Fe = me && me.length > 0, Rt = h && Fe ?
|
|
11455
|
+
const Fe = me && me.length > 0, Rt = h && Fe ? te.filter((Ht) => !me.includes(Ht)) : te, Pe = pi(Rt, j, !0, e, I, m);
|
|
11471
11456
|
y(Pe), h && N.current?.close?.();
|
|
11472
11457
|
},
|
|
11473
11458
|
[e, h, m, y, j, me, I]
|
|
11474
11459
|
), zt = z(
|
|
11475
|
-
(
|
|
11460
|
+
(te, Fe) => {
|
|
11476
11461
|
Fe.stopPropagation();
|
|
11477
|
-
const Et = me?.filter((Rt) => !
|
|
11462
|
+
const Et = me?.filter((Rt) => !te.includes(Rt));
|
|
11478
11463
|
Ct(Et ?? []);
|
|
11479
11464
|
},
|
|
11480
11465
|
[Ct, me]
|
|
@@ -11483,7 +11468,7 @@ function z9({
|
|
|
11483
11468
|
he();
|
|
11484
11469
|
}, [he]), ne(() => () => st.cancel(), [st]);
|
|
11485
11470
|
const ke = z(
|
|
11486
|
-
(
|
|
11471
|
+
(te, Fe) => /* @__PURE__ */ s(Z9, { children: /* @__PURE__ */ s(
|
|
11487
11472
|
ut,
|
|
11488
11473
|
{
|
|
11489
11474
|
accent: ae.TERTIARY,
|
|
@@ -11494,7 +11479,7 @@ function z9({
|
|
|
11494
11479
|
) }),
|
|
11495
11480
|
[]
|
|
11496
11481
|
), we = z(
|
|
11497
|
-
(
|
|
11482
|
+
(te) => typeof te[m] != "string" ? te[m] : /* @__PURE__ */ s("span", { title: te[m], children: /* @__PURE__ */ s(h4, { label: te[m], query: U }) }),
|
|
11498
11483
|
[m, U]
|
|
11499
11484
|
), Ze = z(() => {
|
|
11500
11485
|
if (h && me && me.length > 0) {
|
|
@@ -11507,7 +11492,7 @@ function z9({
|
|
|
11507
11492
|
);
|
|
11508
11493
|
return /* @__PURE__ */ s("span", { title: Pe, children: Pe });
|
|
11509
11494
|
}
|
|
11510
|
-
const
|
|
11495
|
+
const te = Mo(me, j, !1, e, I, m), Fe = tl(te, e), Et = [...te, ...Fe].filter(Boolean);
|
|
11511
11496
|
if (!F)
|
|
11512
11497
|
return /* @__PURE__ */ v(Re, { children: [
|
|
11513
11498
|
/* @__PURE__ */ v("span", { className: "rs-picker-value-list", title: w, children: [
|
|
@@ -11515,7 +11500,7 @@ function z9({
|
|
|
11515
11500
|
" ",
|
|
11516
11501
|
/* @__PURE__ */ v(Js, { children: [
|
|
11517
11502
|
"(",
|
|
11518
|
-
|
|
11503
|
+
te.length,
|
|
11519
11504
|
")"
|
|
11520
11505
|
] })
|
|
11521
11506
|
] }),
|
|
@@ -11608,10 +11593,10 @@ function z9({
|
|
|
11608
11593
|
loading: W,
|
|
11609
11594
|
onChange: Ct,
|
|
11610
11595
|
onClose: () => {
|
|
11611
|
-
st.cancel(),
|
|
11596
|
+
st.cancel(), re(j), Z(""), se([]);
|
|
11612
11597
|
},
|
|
11613
|
-
onExpand: (
|
|
11614
|
-
Se(
|
|
11598
|
+
onExpand: (te) => {
|
|
11599
|
+
Se(te);
|
|
11615
11600
|
},
|
|
11616
11601
|
onSearch: At,
|
|
11617
11602
|
readOnly: b,
|
|
@@ -11668,6 +11653,14 @@ const Js = S.span`
|
|
|
11668
11653
|
display: flex;
|
|
11669
11654
|
align-items: center;
|
|
11670
11655
|
cursor: pointer;
|
|
11656
|
+
/* Its containing rsuite element (.rs-tree-node-custom-icon) collapses to 0x0, so this
|
|
11657
|
+
* absolutely positioned box escapes to the whole row. Without this, it silently intercepts
|
|
11658
|
+
* hover/click on the row's label too, blocking the label's title tooltip. */
|
|
11659
|
+
pointer-events: none;
|
|
11660
|
+
|
|
11661
|
+
> * {
|
|
11662
|
+
pointer-events: auto;
|
|
11663
|
+
}
|
|
11671
11664
|
`, U9 = S.div`
|
|
11672
11665
|
display: contents;
|
|
11673
11666
|
`, G9 = S.div`
|
|
@@ -13635,10 +13628,10 @@ var _6 = ["_blocks"], Tt = /* @__PURE__ */ (function(e) {
|
|
|
13635
13628
|
}
|
|
13636
13629
|
}
|
|
13637
13630
|
if (se != null && he != null) {
|
|
13638
|
-
for (var
|
|
13639
|
-
var de = this._blocks[
|
|
13631
|
+
for (var re = se; re < this._blocks.length; ++re) {
|
|
13632
|
+
var de = this._blocks[re], ye = de.nearestInputPos(0, ie.FORCE_RIGHT);
|
|
13640
13633
|
if (ye !== de.value.length)
|
|
13641
|
-
return this._blockStartPos(
|
|
13634
|
+
return this._blockStartPos(re) + ye;
|
|
13642
13635
|
}
|
|
13643
13636
|
return o === ie.FORCE_RIGHT ? this.value.length : he;
|
|
13644
13637
|
}
|
|
@@ -17415,11 +17408,11 @@ function Il() {
|
|
|
17415
17408
|
}, M.valueOf = function() {
|
|
17416
17409
|
return this.$d.getTime();
|
|
17417
17410
|
}, M.startOf = function(T, B) {
|
|
17418
|
-
var V = this, U = !!I.u(B) || B, Z = I.p(T), W = function(
|
|
17419
|
-
var ye = I.w(V.$u ? Date.UTC(V.$y, de,
|
|
17411
|
+
var V = this, U = !!I.u(B) || B, Z = I.p(T), W = function(re, de) {
|
|
17412
|
+
var ye = I.w(V.$u ? Date.UTC(V.$y, de, re) : new Date(V.$y, de, re), V);
|
|
17420
17413
|
return U ? ye : ye.endOf(c);
|
|
17421
|
-
}, Y = function(
|
|
17422
|
-
return I.w(V.toDate()[
|
|
17414
|
+
}, Y = function(re, de) {
|
|
17415
|
+
return I.w(V.toDate()[re].apply(V.toDate("s"), (U ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(de)), V);
|
|
17423
17416
|
}, X = this.$W, se = this.$M, he = this.$D, j = "set" + (this.$u ? "UTC" : "");
|
|
17424
17417
|
switch (Z) {
|
|
17425
17418
|
case p:
|
|
@@ -17476,7 +17469,7 @@ function Il() {
|
|
|
17476
17469
|
return de && (de[ye] || de(B, U)) || He[ye].slice(0, me);
|
|
17477
17470
|
}, Me = function(de) {
|
|
17478
17471
|
return I.s(W % 12 || 12, de, "0");
|
|
17479
|
-
},
|
|
17472
|
+
}, re = j || function(de, ye, He) {
|
|
17480
17473
|
var me = de < 12 ? "AM" : "PM";
|
|
17481
17474
|
return He ? me.toLowerCase() : me;
|
|
17482
17475
|
};
|
|
@@ -17516,9 +17509,9 @@ function Il() {
|
|
|
17516
17509
|
case "hh":
|
|
17517
17510
|
return Me(2);
|
|
17518
17511
|
case "a":
|
|
17519
|
-
return
|
|
17512
|
+
return re(W, Y, !0);
|
|
17520
17513
|
case "A":
|
|
17521
|
-
return
|
|
17514
|
+
return re(W, Y, !1);
|
|
17522
17515
|
case "m":
|
|
17523
17516
|
return String(Y);
|
|
17524
17517
|
case "mm":
|
|
@@ -18441,8 +18434,8 @@ function c7({
|
|
|
18441
18434
|
);
|
|
18442
18435
|
eo(C, () => ({
|
|
18443
18436
|
box: E.current,
|
|
18444
|
-
focus: (
|
|
18445
|
-
|
|
18437
|
+
focus: (re = !1) => {
|
|
18438
|
+
re ? b.current?.focus() : k.current?.focus();
|
|
18446
18439
|
},
|
|
18447
18440
|
getValueAsPartialTimeTuple: () => [
|
|
18448
18441
|
k.current?.value.length ? k.current.value : void 0,
|
|
@@ -18457,17 +18450,17 @@ function c7({
|
|
|
18457
18450
|
q(!1);
|
|
18458
18451
|
}, []), X = z(() => {
|
|
18459
18452
|
q(!0), h && h();
|
|
18460
|
-
}, [h]), se = z((
|
|
18461
|
-
L(
|
|
18453
|
+
}, [h]), se = z((re) => {
|
|
18454
|
+
L(re);
|
|
18462
18455
|
}, []), he = z(
|
|
18463
|
-
(
|
|
18464
|
-
const de =
|
|
18456
|
+
(re) => {
|
|
18457
|
+
const de = re.length ? new RegExp(`^${re}`) : /.*/;
|
|
18465
18458
|
B(de), p();
|
|
18466
18459
|
},
|
|
18467
18460
|
[p]
|
|
18468
18461
|
), j = z(
|
|
18469
|
-
(
|
|
18470
|
-
Z(), w(
|
|
18462
|
+
(re) => {
|
|
18463
|
+
Z(), w(re), f(re);
|
|
18471
18464
|
},
|
|
18472
18465
|
[Z, f]
|
|
18473
18466
|
), le = z(() => {
|
|
@@ -18480,8 +18473,8 @@ function c7({
|
|
|
18480
18473
|
return;
|
|
18481
18474
|
}
|
|
18482
18475
|
Z();
|
|
18483
|
-
const
|
|
18484
|
-
f(
|
|
18476
|
+
const re = [k.current.value, b.current.value];
|
|
18477
|
+
f(re);
|
|
18485
18478
|
}, [U, Z, f]);
|
|
18486
18479
|
return Lo(E, Z, e), Bo(Z, e), ne(() => {
|
|
18487
18480
|
Xe(y, V) || H || w(y);
|
|
@@ -18637,7 +18630,7 @@ function f7({
|
|
|
18637
18630
|
return;
|
|
18638
18631
|
const [zt, ke] = q.current.getValueAsPartialTimeTuple();
|
|
18639
18632
|
!Se && !bt && !Ct && !zt && !ke && k(void 0);
|
|
18640
|
-
}, [k, F]),
|
|
18633
|
+
}, [k, F]), re = z(() => {
|
|
18641
18634
|
U(!1);
|
|
18642
18635
|
}, []), de = z(() => {
|
|
18643
18636
|
!F || !q.current || q.current.focus();
|
|
@@ -18661,9 +18654,9 @@ function f7({
|
|
|
18661
18654
|
// with a time set to the start (or end) of the day
|
|
18662
18655
|
Y,
|
|
18663
18656
|
l
|
|
18664
|
-
), T.current = Se, B.current = It(M.current),
|
|
18657
|
+
), T.current = Se, B.current = It(M.current), re(), he(), le(), F && q.current && q.current.focus();
|
|
18665
18658
|
},
|
|
18666
|
-
[le,
|
|
18659
|
+
[le, re, Y, he, l, F]
|
|
18667
18660
|
), me = z(() => {
|
|
18668
18661
|
T.current = void 0, B.current = void 0, he();
|
|
18669
18662
|
}, [he]), st = z(
|
|
@@ -18678,7 +18671,7 @@ function f7({
|
|
|
18678
18671
|
), At = z(() => {
|
|
18679
18672
|
n || b || U(!0);
|
|
18680
18673
|
}, [n, b]);
|
|
18681
|
-
return Lo([O, I],
|
|
18674
|
+
return Lo([O, I], re, e), Oe(m && n, k, me), Bo(re, e), ne(() => {
|
|
18682
18675
|
if (!N.current) {
|
|
18683
18676
|
N.current = !0;
|
|
18684
18677
|
return;
|
|
@@ -18743,7 +18736,7 @@ function f7({
|
|
|
18743
18736
|
name: E,
|
|
18744
18737
|
onBack: () => H.current?.focus(!0),
|
|
18745
18738
|
onChange: st,
|
|
18746
|
-
onFocus:
|
|
18739
|
+
onFocus: re,
|
|
18747
18740
|
onInput: Me,
|
|
18748
18741
|
onPrevious: () => H.current?.focus(!0),
|
|
18749
18742
|
readOnly: b,
|
|
@@ -18892,12 +18885,12 @@ function v7({
|
|
|
18892
18885
|
] : void 0,
|
|
18893
18886
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
18894
18887
|
[U.current, T.current]
|
|
18895
|
-
),
|
|
18888
|
+
), re = z(() => {
|
|
18896
18889
|
if (!C || !M.current || !V.current)
|
|
18897
18890
|
return;
|
|
18898
18891
|
if (h) {
|
|
18899
|
-
const
|
|
18900
|
-
C([
|
|
18892
|
+
const te = M.current.utc().toISOString(), Fe = V.current.utc().toISOString();
|
|
18893
|
+
C([te, Fe]);
|
|
18901
18894
|
return;
|
|
18902
18895
|
}
|
|
18903
18896
|
const ke = M.current.toDate(), we = V.current.toDate();
|
|
@@ -18905,15 +18898,15 @@ function v7({
|
|
|
18905
18898
|
}, [h, C]), de = z(() => {
|
|
18906
18899
|
if (!O.current || !H.current || !C)
|
|
18907
18900
|
return;
|
|
18908
|
-
const [ke, we, Ze] = O.current.getValueAsPartialDateTuple(), [
|
|
18909
|
-
if (!w && !ke && !we && !Ze && !
|
|
18901
|
+
const [ke, we, Ze] = O.current.getValueAsPartialDateTuple(), [te, Fe, Et] = H.current.getValueAsPartialDateTuple();
|
|
18902
|
+
if (!w && !ke && !we && !Ze && !te && !Fe && !Et) {
|
|
18910
18903
|
C(void 0);
|
|
18911
18904
|
return;
|
|
18912
18905
|
}
|
|
18913
18906
|
if (!I.current || !q.current)
|
|
18914
18907
|
return;
|
|
18915
18908
|
const [Rt, Pe] = I.current.getValueAsPartialTimeTuple(), [Ht, ht] = q.current.getValueAsPartialTimeTuple();
|
|
18916
|
-
!ke && !we && !Ze && !Rt && !Pe && !
|
|
18909
|
+
!ke && !we && !Ze && !Rt && !Pe && !te && !Fe && !Et && !Ht && !ht && C(void 0);
|
|
18917
18910
|
}, [C, w]), ye = z(() => {
|
|
18918
18911
|
Y(!1);
|
|
18919
18912
|
}, []), He = z(() => {
|
|
@@ -18940,14 +18933,14 @@ function v7({
|
|
|
18940
18933
|
(ke, we, Ze) => {
|
|
18941
18934
|
if (ke === Xt.START) {
|
|
18942
18935
|
if (T.current = we, !w || w && x || w && B.current) {
|
|
18943
|
-
const
|
|
18944
|
-
B.current =
|
|
18936
|
+
const te = B.current ? B.current : ["00", "00"], Fe = dt(we, te);
|
|
18937
|
+
B.current = te, M.current = Fe, re();
|
|
18945
18938
|
}
|
|
18946
18939
|
Ze && (At(), le());
|
|
18947
18940
|
} else {
|
|
18948
18941
|
if (U.current = we, !w || w && x || w && Z.current) {
|
|
18949
|
-
const
|
|
18950
|
-
Z.current =
|
|
18942
|
+
const te = Z.current ? Z.current : ["23", "59"], Fe = dt(we, te, !0);
|
|
18943
|
+
Z.current = te, V.current = Fe, re();
|
|
18951
18944
|
}
|
|
18952
18945
|
if (Ze) {
|
|
18953
18946
|
if (w && x) {
|
|
@@ -18963,7 +18956,7 @@ function v7({
|
|
|
18963
18956
|
le,
|
|
18964
18957
|
x,
|
|
18965
18958
|
w,
|
|
18966
|
-
|
|
18959
|
+
re,
|
|
18967
18960
|
me,
|
|
18968
18961
|
At
|
|
18969
18962
|
]
|
|
@@ -18977,9 +18970,9 @@ function v7({
|
|
|
18977
18970
|
Ze,
|
|
18978
18971
|
Z.current,
|
|
18979
18972
|
!0
|
|
18980
|
-
)), I.current?.focus()), T.current = we, B.current = It(M.current), U.current = Ze, Z.current = It(V.current), ye(),
|
|
18973
|
+
)), I.current?.focus()), T.current = we, B.current = It(M.current), U.current = Ze, Z.current = It(V.current), ye(), re();
|
|
18981
18974
|
},
|
|
18982
|
-
[
|
|
18975
|
+
[re, ye, x, w]
|
|
18983
18976
|
), Ct = z(
|
|
18984
18977
|
(ke, we) => {
|
|
18985
18978
|
if (H.current) {
|
|
@@ -19000,10 +18993,10 @@ function v7({
|
|
|
19000
18993
|
}
|
|
19001
18994
|
Z.current = we;
|
|
19002
18995
|
}
|
|
19003
|
-
|
|
18996
|
+
re();
|
|
19004
18997
|
}
|
|
19005
18998
|
},
|
|
19006
|
-
[
|
|
18999
|
+
[re]
|
|
19007
19000
|
), zt = z(() => {
|
|
19008
19001
|
n || E || Y(!0);
|
|
19009
19002
|
}, [n, E]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/libs/CustomSearch/index.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAA2B,eAAe,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAA;AAC5F,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAA;AAExD,qBAAa,YAAY,CAAC,CAAC,SAAS,SAAS,GAAG,SAAS;;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/libs/CustomSearch/index.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAA2B,eAAe,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAA;AAC5F,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAA;AAExD,qBAAa,YAAY,CAAC,CAAC,SAAS,SAAS,GAAG,SAAS;;gBASrD,UAAU,EAAE,CAAC,EAAE,EACf,IAAI,EAAE,KAAK,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,EAC/B,EACE,QAAQ,EACR,WAAW,EACX,eAAuB,EACvB,oBAA4B,EAC5B,QAAgB,EAChB,oBAA2B,EAC3B,SAAe,EACf,qBAA6B,EAC9B,GAAE,mBAAwB;IA8C7B;;;;;;OAMG;IACH,IAAI,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,CAAC,EAAE;CAqCzC;AAED,YAAY,EAAE,eAAe,EAAE,mBAAmB,EAAE,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mtes-mct/monitor-ui",
|
|
3
3
|
"description": "Common React components, hooks, utilities and CSS stylesheets for MonitorFish, MonitorEnv and RapportNav.",
|
|
4
|
-
"version": "24.56.
|
|
4
|
+
"version": "24.56.1",
|
|
5
5
|
"license": "AGPL-3.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"engines": {
|
|
@@ -24,7 +24,6 @@
|
|
|
24
24
|
"cypress": "^14.0.0 || ^15.0.0",
|
|
25
25
|
"formik": "^2.0.0",
|
|
26
26
|
"react": "^18.0.0 || ^19.0.0",
|
|
27
|
-
"react-router-dom": "^6.0.0 || ^7.0.0",
|
|
28
27
|
"rsuite": "^5.83.1",
|
|
29
28
|
"styled-components": "^5.0.0 || ^6.0.0"
|
|
30
29
|
},
|