@box/metadata-filter 1.52.3 → 1.53.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.
Files changed (28) hide show
  1. package/dist/chunks/index.js +58 -59
  2. package/dist/chunks/metadata-float-field.module.js +4 -6
  3. package/dist/chunks/types.js +2 -2
  4. package/dist/chunks/types2.js +2 -2
  5. package/dist/chunks/use-float-validation.js +13 -13
  6. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-date-field/date-conversion-utils.js +34 -35
  7. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-date-field/metadata-date-field-advanced.js +52 -52
  8. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-date-field/metadata-date-field-relative.js +92 -92
  9. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-date-field/use-date-validation.js +22 -22
  10. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-date-field/use-integer-validation.js +2 -2
  11. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-enum-field/metadata-enum-field.js +19 -19
  12. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-float-field/handlers.js +12 -12
  13. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-float-field/utils.js +30 -33
  14. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-multi-select-field/metadata-multi-select-field-advanced.js +54 -54
  15. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-multi-select-field/metadata-multi-select-field.js +36 -39
  16. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-multi-select-field/utils.js +11 -11
  17. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-string-field/metadata-string-field.js +55 -55
  18. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-string-field/utils.js +12 -12
  19. package/dist/esm/lib/components/metadata-filter-fields/components/metadata-taxonomy-field/metadata-taxonomy-field.js +52 -52
  20. package/dist/esm/lib/components/metadata-filter-fields/field-processing-utils.js +10 -10
  21. package/dist/esm/lib/components/metadata-filter-fields/is-modified-utils.js +9 -13
  22. package/dist/esm/lib/components/metadata-filter-fields/metadata-filter-fields-accordion.js +67 -67
  23. package/dist/esm/lib/components/metadata-filter-fields/metadata-filter-fields.js +53 -53
  24. package/dist/i18n/en-x-pseudo.js +54 -54
  25. package/dist/i18n/en-x-pseudo.properties +54 -54
  26. package/dist/styles/metadata-date-field.css +1 -1
  27. package/dist/styles/metadata-float-field.css +1 -1
  28. package/package.json +7 -7
@@ -1,76 +1,75 @@
1
- import { Text as D, Select as c } from "@box/blueprint-web";
2
- import { Field as k } from "formik";
3
- import { useState as B, useCallback as M } from "react";
4
- import { useIntl as N } from "react-intl";
5
- import l from "../esm/lib/messages.js";
6
- import { jsxs as _, Fragment as $, jsx as e } from "react/jsx-runtime";
7
- import '../styles/index.css';const q = "_noAttributesText_2lw3u_1", z = "_fieldLabel_2lw3u_5", E = "_selectContainer_2lw3u_10", G = "_comboboxContainer_2lw3u_15", H = "_modifiedIcon_2lw3u_19", d = {
8
- noAttributesText: q,
9
- fieldLabel: z,
10
- selectContainer: E,
11
- comboboxContainer: G,
12
- modifiedIcon: H
13
- }, W = ({
14
- label: m,
15
- fieldNamePrefix: i,
16
- fieldAdvancedFilterOptions: h,
17
- filterOptionsMap: n,
18
- disableForm: b,
19
- portalElement: x,
20
- onAdvancedFilterOptionChange: s,
21
- onValueChange: u,
1
+ import { Text as S, Select as s } from "@box/blueprint-web";
2
+ import { Field as j } from "formik";
3
+ import { useState as D, useCallback as k } from "react";
4
+ import { useIntl as B } from "react-intl";
5
+ import a from "../esm/lib/messages.js";
6
+ import { jsxs as b, Fragment as N, jsx as e } from "react/jsx-runtime";
7
+ import '../styles/index.css';const $ = "_noAttributesText_2lw3u_1", q = "_fieldLabel_2lw3u_5", z = "_selectContainer_2lw3u_10", E = "_modifiedIcon_2lw3u_19", c = {
8
+ noAttributesText: $,
9
+ fieldLabel: q,
10
+ selectContainer: z,
11
+ modifiedIcon: E
12
+ }, U = ({
13
+ label: d,
14
+ fieldNamePrefix: l,
15
+ fieldAdvancedFilterOptions: _,
16
+ filterOptionsMap: h,
17
+ disableForm: m,
18
+ portalElement: p,
19
+ onAdvancedFilterOptionChange: n,
20
+ onValueChange: f,
22
21
  defaultValue: v = "",
23
- showLabel: C = !0,
24
- advancedFilterFieldName: L = `${i}.value.advancedFilterOption`,
25
- value: r,
26
- labelClassName: g = d.fieldLabel,
22
+ showLabel: L = !0,
23
+ advancedFilterFieldName: g = `${l}.value.advancedFilterOption`,
24
+ value: i,
25
+ labelClassName: x = c.fieldLabel,
27
26
  labelAs: A = "div",
28
27
  open: I,
29
- onOpenChange: w,
30
- isModified: T
28
+ onOpenChange: C,
29
+ isModified: M
31
30
  }) => {
32
- const a = N(), [F, p] = B(h || v), y = r !== void 0 ? r : F, S = M((t, ...o) => {
33
- r === void 0 && p(t), s && s(i, t), u(t, ...o);
34
- }, [i, s, u, r]);
35
- return /* @__PURE__ */ _($, {
36
- children: [C && /* @__PURE__ */ _(D, {
31
+ const o = B(), [T, w] = D(_ || v), F = i !== void 0 ? i : T, y = k((t, ...r) => {
32
+ i === void 0 && w(t), n && n(l, t), f(t, ...r);
33
+ }, [l, n, f, i]);
34
+ return /* @__PURE__ */ b(N, {
35
+ children: [L && /* @__PURE__ */ b(S, {
37
36
  as: A,
38
- className: g,
37
+ className: x,
39
38
  color: "textOnLightDefault",
40
39
  variant: "bodyDefaultBold",
41
- children: [m, T && /* @__PURE__ */ e("div", {
42
- "aria-label": a.formatMessage(l.filterModifiedAriaLabel),
43
- className: d.modifiedIcon,
40
+ children: [d, M && /* @__PURE__ */ e("div", {
41
+ "aria-label": o.formatMessage(a.filterModifiedAriaLabel),
42
+ className: c.modifiedIcon,
44
43
  role: "img"
45
44
  })]
46
- }), /* @__PURE__ */ e(k, {
47
- name: L,
45
+ }), /* @__PURE__ */ e(j, {
46
+ name: g,
48
47
  children: ({
49
48
  field: t,
50
- meta: o
49
+ meta: r
51
50
  }) => /* @__PURE__ */ e("div", {
52
- className: d.selectContainer,
53
- children: /* @__PURE__ */ e(c, {
51
+ className: c.selectContainer,
52
+ children: /* @__PURE__ */ e(s, {
54
53
  ...t,
55
- "aria-disabled": b,
56
- "aria-label": a.formatMessage(l.advancedFilterOptionAriaLabel, {
57
- label: m
54
+ "aria-disabled": m,
55
+ "aria-label": o.formatMessage(a.advancedFilterOptionAriaLabel, {
56
+ label: d
58
57
  }),
59
- disabled: b,
60
- error: o.touched && o.error ? o.error : void 0,
58
+ disabled: m,
59
+ error: r.touched && r.error ? r.error : void 0,
61
60
  hideLabel: !0,
62
- label: a.formatMessage(l.selectFilterType),
63
- onOpenChange: w,
64
- onValueChange: S,
61
+ label: o.formatMessage(a.selectFilterType),
62
+ onOpenChange: C,
63
+ onValueChange: y,
65
64
  open: I,
66
- placeholder: a.formatMessage(l.selectOptionPlaceholder),
67
- value: y,
68
- children: /* @__PURE__ */ e(c.Content, {
69
- container: x,
70
- children: n == null ? void 0 : n.map(([f, j]) => /* @__PURE__ */ e(c.Option, {
71
- text: j,
72
- value: f
73
- }, f))
65
+ placeholder: o.formatMessage(a.selectOptionPlaceholder),
66
+ value: F,
67
+ children: /* @__PURE__ */ e(s.Content, {
68
+ container: p,
69
+ children: h?.map(([u, O]) => /* @__PURE__ */ e(s.Option, {
70
+ text: O,
71
+ value: u
72
+ }, u))
74
73
  })
75
74
  })
76
75
  })
@@ -78,6 +77,6 @@ import '../styles/index.css';const q = "_noAttributesText_2lw3u_1", z = "_fieldL
78
77
  });
79
78
  };
80
79
  export {
81
- W as A,
82
- d as s
80
+ U as A,
81
+ c as s
83
82
  };
@@ -1,10 +1,8 @@
1
- import '../styles/metadata-float-field.css';const n = "_container_uvlwq_1", e = "_rangeInputsContainer_uvlwq_6", t = "_inputContainer_uvlwq_16", a = "_advancedFilterContainer_uvlwq_23", i = "_fieldLabel_uvlwq_44", o = "_selectContainer_uvlwq_49", r = {
1
+ import '../styles/metadata-float-field.css';const n = "_container_uvlwq_1", t = "_rangeInputsContainer_uvlwq_6", e = "_inputContainer_uvlwq_16", a = "_advancedFilterContainer_uvlwq_23", r = {
2
2
  container: n,
3
- rangeInputsContainer: e,
4
- inputContainer: t,
5
- advancedFilterContainer: a,
6
- fieldLabel: i,
7
- selectContainer: o
3
+ rangeInputsContainer: t,
4
+ inputContainer: e,
5
+ advancedFilterContainer: a
8
6
  };
9
7
  export {
10
8
  r as s
@@ -1,6 +1,6 @@
1
- let O = /* @__PURE__ */ function(t) {
1
+ let O = /* @__PURE__ */ (function(t) {
2
2
  return t[t.TO = 0] = "TO", t[t.FROM = 1] = "FROM", t;
3
- }({});
3
+ })({});
4
4
  export {
5
5
  O as R
6
6
  };
@@ -1,6 +1,6 @@
1
- let I = /* @__PURE__ */ function(A) {
1
+ let I = /* @__PURE__ */ (function(A) {
2
2
  return A[A.MAX = 0] = "MAX", A[A.OVERLAPPING = 1] = "OVERLAPPING", A[A.INVALID = 2] = "INVALID", A;
3
- }({});
3
+ })({});
4
4
  export {
5
5
  I as E
6
6
  };
@@ -1,24 +1,24 @@
1
1
  import { useState as I } from "react";
2
2
  import { useIntl as d } from "react-intl";
3
- import e from "../esm/lib/messages.js";
3
+ import r from "../esm/lib/messages.js";
4
4
  import { R as p } from "./types.js";
5
- let V = /* @__PURE__ */ function(t) {
5
+ let V = /* @__PURE__ */ (function(t) {
6
6
  return t[t.INVALID = 0] = "INVALID", t[t.OVERLAPPING = 1] = "OVERLAPPING", t;
7
- }({});
8
- const c = (t, r = !1) => t != null && t.length ? r ? /^[-+]?(\d+(\.\d*)?|\.\d+)$/.test(t) : /^[-+]?\d+(\.\d+)?$/.test(t) : !0, R = (t, r, a) => {
9
- const n = parseFloat(t), l = parseFloat(r);
7
+ })({});
8
+ const c = (t, e = !1) => t?.length ? e ? /^[-+]?(\d+(\.\d*)?|\.\d+)$/.test(t) : /^[-+]?\d+(\.\d+)?$/.test(t) : !0, R = (t, e, a) => {
9
+ const n = parseFloat(t), l = parseFloat(e);
10
10
  return a ? l <= n : l < n;
11
- }, O = (t, r, a) => r ? t ? a.formatMessage(e.floatFieldInvalidMinValueRange) : a.formatMessage(e.floatFieldInvalidMaxValueRange) : t ? a.formatMessage(e.floatFieldInvalidFromValueRange) : a.formatMessage(e.floatFieldInvalidToValueRange), M = (t, r, a) => r ? a.formatMessage(e.mustBeANumber) : t ? a.formatMessage(e.floatFieldInvalidFromValue) : a.formatMessage(e.floatFieldInvalidToValue), A = () => {
12
- const t = d(), [r, a] = I(null), [n, l] = I(null), u = (i, s) => i === p.FROM ? a(s) : l(s);
11
+ }, O = (t, e, a) => e ? t ? a.formatMessage(r.floatFieldInvalidMinValueRange) : a.formatMessage(r.floatFieldInvalidMaxValueRange) : t ? a.formatMessage(r.floatFieldInvalidFromValueRange) : a.formatMessage(r.floatFieldInvalidToValueRange), M = (t, e, a) => e ? a.formatMessage(r.mustBeANumber) : t ? a.formatMessage(r.floatFieldInvalidFromValue) : a.formatMessage(r.floatFieldInvalidToValue), A = () => {
12
+ const t = d(), [e, a] = I(null), [n, l] = I(null), g = (i, s) => i === p.FROM ? a(s) : l(s);
13
13
  return {
14
- validateFloats: (i, s, f, o = !1) => {
15
- const g = f === p.FROM, m = c(i, o), F = c(s, o);
16
- if (!(g ? m : F))
17
- return u(f, V.INVALID), M(g, o, t);
14
+ validateFloats: (i, s, u, o = !1) => {
15
+ const f = u === p.FROM, m = c(i, o), F = c(s, o);
16
+ if (!(f ? m : F))
17
+ return g(u, V.INVALID), M(f, o, t);
18
18
  if (m && F && R(i, s, o))
19
- return u(f, V.OVERLAPPING), O(g, o, t);
19
+ return g(u, V.OVERLAPPING), O(f, o, t);
20
20
  },
21
- fromErrorType: r,
21
+ fromErrorType: e,
22
22
  toErrorType: n
23
23
  };
24
24
  };
@@ -1,36 +1,35 @@
1
- import { toCalendarDateTime as c, parseAbsolute as F, parseAbsoluteToLocal as w, toCalendarDate as D, Time as v, toZoned as p, fromAbsolute as f } from "@box/blueprint-web";
2
- import { R as d } from "../../../../../../chunks/types.js";
3
- const h = (o, t) => {
1
+ import { fromAbsolute as v, toCalendarDateTime as d, parseAbsolute as g, parseAbsoluteToLocal as w, toCalendarDate as b, Time as f, toZoned as D } from "@box/blueprint-web";
2
+ import { R as i } from "../../../../../../chunks/types.js";
3
+ const F = (o, t) => {
4
4
  try {
5
- const s = t ? c(F(o, "UTC")) : w(o);
6
- return D(s);
5
+ const e = t ? d(g(o, "UTC")) : w(o);
6
+ return b(e);
7
7
  } catch {
8
8
  return null;
9
9
  }
10
- }, z = (o, t, s) => {
11
- let e = "";
10
+ }, y = (o, t, e) => {
11
+ let r = "";
12
12
  if (o) {
13
- const n = s === d.FROM ? o : c(o, new v(23, 59, 59, 999));
14
- e = p(n, t).toAbsoluteString();
13
+ const n = e === i.FROM ? o : d(o, new f(23, 59, 59, 999));
14
+ r = D(n, t).toAbsoluteString();
15
15
  }
16
- return e;
17
- }, u = (o, t) => {
18
- let s = "";
16
+ return r;
17
+ }, c = (o, t) => {
18
+ let e = "";
19
19
  if (o) {
20
- const e = t === d.FROM ? c(o, new v(0, 0, 0, 0)) : c(o, new v(23, 59, 59, 999));
21
- s = p(e, "UTC").toAbsoluteString();
20
+ const r = t === i.FROM ? d(o, new f(0, 0, 0, 0)) : d(o, new f(23, 59, 59, 999));
21
+ e = D(r, "UTC").toAbsoluteString();
22
22
  }
23
- return s;
24
- }, A = (o, t, s = (/* @__PURE__ */ new Date()).getTime()) => {
25
- var C;
23
+ return e;
24
+ }, M = (o, t, e = (/* @__PURE__ */ new Date()).getTime()) => {
26
25
  if ((o === "next" || o === "past" || o === "olderThan") && (t === void 0 || isNaN(t)))
27
26
  return {
28
27
  from: void 0,
29
28
  to: void 0
30
29
  };
31
- const e = (i) => i === void 0 ? void 0 : i, n = e(f(s, "UTC")), a = (i) => e(n == null ? void 0 : n.add({
32
- days: i * t
33
- })), T = {
30
+ const r = (T) => T === void 0 ? void 0 : T, n = r(v(e, "UTC")), a = (T) => r(n?.add({
31
+ days: T * t
32
+ })), s = {
34
33
  today: () => ({
35
34
  from: n,
36
35
  to: n
@@ -44,27 +43,27 @@ const h = (o, t) => {
44
43
  to: n
45
44
  }),
46
45
  olderThan: () => ({
47
- from: e(f(0, "UTC")),
46
+ from: r(v(0, "UTC")),
48
47
  to: a(-1)
49
48
  })
50
- }, r = (C = T[o]) == null ? void 0 : C.call(T), m = r == null ? void 0 : r.from, b = r == null ? void 0 : r.to;
49
+ }[o]?.(), m = s?.from, l = s?.to;
51
50
  return {
52
- from: m ? u(m, d.FROM) : void 0,
53
- to: b ? u(b, d.TO) : void 0
51
+ from: m ? c(m, i.FROM) : void 0,
52
+ to: l ? c(l, i.TO) : void 0
54
53
  };
55
- }, R = (o, t) => {
56
- const s = (r) => r === void 0 ? void 0 : r, e = s(f((/* @__PURE__ */ new Date()).getTime(), "UTC")), n = (r, m) => s(e == null ? void 0 : e.add({
57
- days: r * m
58
- })), a = n(o < 1 ? -1 : 1, Math.abs(o)), T = n(t < 1 ? -1 : 1, Math.abs(t));
54
+ }, O = (o, t) => {
55
+ const e = (s) => s === void 0 ? void 0 : s, r = e(v((/* @__PURE__ */ new Date()).getTime(), "UTC")), n = (s, m) => e(r?.add({
56
+ days: s * m
57
+ })), a = n(o < 1 ? -1 : 1, Math.abs(o)), u = n(t < 1 ? -1 : 1, Math.abs(t));
59
58
  return {
60
- from: a ? u(a, d.FROM) : void 0,
61
- to: T ? u(T, d.TO) : void 0
59
+ from: a ? c(a, i.FROM) : void 0,
60
+ to: u ? c(u, i.TO) : void 0
62
61
  };
63
62
  };
64
63
  export {
65
- h as convertToDatePickerValue,
66
- z as convertToFormikValue,
67
- u as convertToFormikValueRanged,
68
- R as getCustomFromToValues,
69
- A as getRelativeFromToValues
64
+ F as convertToDatePickerValue,
65
+ y as convertToFormikValue,
66
+ c as convertToFormikValueRanged,
67
+ O as getCustomFromToValues,
68
+ M as getRelativeFromToValues
70
69
  };
@@ -16,7 +16,7 @@ import { jsx as n, jsxs as W } from "react/jsx-runtime";
16
16
  import { A as Te } from "../../../../../../chunks/index.js";
17
17
  const $e = ({
18
18
  disableForm: h,
19
- fieldNamePrefix: u,
19
+ fieldNamePrefix: d,
20
20
  label: I,
21
21
  locale: C,
22
22
  portalElement: M,
@@ -26,9 +26,9 @@ const $e = ({
26
26
  hasAccordion: Z,
27
27
  isModified: ee
28
28
  }) => {
29
- const T = `${u}.value.advancedFilterOption`, m = `${u}.value.relativeDays`, o = `${u}.value.range.gt`, r = `${u}.value.range.lt`, {
29
+ const T = `${d}.value.advancedFilterOption`, u = `${d}.value.relativeDays`, r = `${d}.value.range.gt`, o = `${d}.value.range.lt`, {
30
30
  values: E,
31
- setFieldValue: a,
31
+ setFieldValue: t,
32
32
  setFieldTouched: S
33
33
  } = ve(), {
34
34
  validateDates: B,
@@ -36,76 +36,76 @@ const $e = ({
36
36
  toDatePickerValue: D,
37
37
  fromErrorType: x,
38
38
  toErrorType: P
39
- } = Fe(E, o, r, C, !0), {
40
- validatePositiveInteger: te
41
- } = De(), l = ge(), [f, ae] = L(N || ""), [U, V] = L(!1), d = pe(E, m), [_, R] = L(s.FROM), y = X(F), O = X(D), $ = {
39
+ } = Fe(E, r, o, C, !0), {
40
+ validatePositiveInteger: ae
41
+ } = De(), l = ge(), [m, te] = L(N || ""), [U, V] = L(!1), f = pe(E, u), [_, y] = L(s.FROM), R = X(F), O = X(D), $ = {
42
42
  clearDatePickerAriaLabel: l.formatMessage(i.clearSelectedDate),
43
43
  nextMonthAriaLabel: l.formatMessage(i.switchToNextMonth),
44
44
  openCalendarDropdownAriaLabel: l.formatMessage(i.openCalendar),
45
45
  previousMonthAriaLabel: l.formatMessage(i.switchToNextMonth)
46
46
  }, w = v(() => {
47
- if (f === "today") {
47
+ if (m === "today") {
48
48
  const {
49
49
  from: e,
50
- to: t
50
+ to: a
51
51
  } = J("today", void 0);
52
- a(o, e), a(r, t);
53
- } else if (d !== void 0) {
54
- const e = typeof d == "string" ? Number(d) : d;
52
+ t(r, e), t(o, a);
53
+ } else if (f !== void 0) {
54
+ const e = typeof f == "string" ? Number(f) : f;
55
55
  if (!isNaN(e) && e > 0) {
56
- const t = f;
57
- if (["next", "past", "olderThan"].includes(t)) {
56
+ const a = m;
57
+ if (["next", "past", "olderThan"].includes(a)) {
58
58
  const {
59
59
  from: c,
60
60
  to: k
61
- } = J(t, e);
62
- a(o, c), a(r, k);
61
+ } = J(a, e);
62
+ t(r, c), t(o, k);
63
63
  }
64
64
  }
65
65
  }
66
- }, [f, d, o, r, a]);
66
+ }, [m, f, r, o, t]);
67
67
  he(() => {
68
68
  U && (w(), V(!1));
69
69
  }, [U, w]);
70
- const oe = v((e) => {
71
- const t = e;
72
- ae(t), a(T, t), g && g(u, t);
70
+ const re = v((e) => {
71
+ const a = e;
72
+ te(a), t(T, a), g && g(d, a);
73
73
  const c = () => {
74
- a(m, void 0), a(o, void 0), a(r, void 0);
74
+ t(u, void 0), t(r, void 0), t(o, void 0);
75
75
  }, k = () => {
76
- a(o, void 0), a(r, void 0);
76
+ t(r, void 0), t(o, void 0);
77
77
  };
78
- ["isBlank", "isNotBlank", "selectFilterType"].includes(t) || !t || t === "customRange" ? c() : t === "today" ? (a(m, void 0), V(!0)) : k();
79
- }, [u, g, a, T, m, o, r]), re = v((e) => {
78
+ ["isBlank", "isNotBlank", "selectFilterType"].includes(a) || !a || a === "customRange" ? c() : a === "today" ? (t(u, void 0), V(!0)) : k();
79
+ }, [d, g, t, T, u, r, o]), oe = v((e) => {
80
80
  const {
81
- valueToStore: t,
81
+ valueToStore: a,
82
82
  shouldTriggerUpdate: c
83
83
  } = Me(e);
84
- a(m, t), c && V(!0);
85
- }, [a, m]), se = v((e) => {
86
- const t = K(e, s.FROM);
87
- y.current = e, a(o, t), R(s.FROM);
88
- }, [a, o]), ne = v((e) => {
89
- const t = K(e, s.TO);
90
- O.current = e, a(r, t), R(s.TO);
91
- }, [a, r]), j = v((e) => {
92
- const t = e === s.FROM ? o : r;
93
- S(t, !0), R(e);
94
- }, [S, o, r]), le = q(() => Q(D, z), [D]), ie = q(() => Q(F), [F]), G = (e, t, c) => !!(t === A.MAX && e === A.OVERLAPPING || e === A.OVERLAPPING && c), ce = ["isBlank", "isNotBlank", "selectFilterType", "today"], de = () => !f || ce.includes(f) ? null : f === "customRange" ? /* @__PURE__ */ W("div", {
84
+ t(u, a), c && V(!0);
85
+ }, [t, u]), se = v((e) => {
86
+ const a = K(e, s.FROM);
87
+ R.current = e, t(r, a), y(s.FROM);
88
+ }, [t, r]), ne = v((e) => {
89
+ const a = K(e, s.TO);
90
+ O.current = e, t(o, a), y(s.TO);
91
+ }, [t, o]), j = v((e) => {
92
+ const a = e === s.FROM ? r : o;
93
+ S(a, !0), y(e);
94
+ }, [S, r, o]), le = q(() => Q(D, z), [D]), ie = q(() => Q(F), [F]), G = (e, a, c) => !!(a === A.MAX && e === A.OVERLAPPING || e === A.OVERLAPPING && c), ce = ["isBlank", "isNotBlank", "selectFilterType", "today"], de = () => !m || ce.includes(m) ? null : m === "customRange" ? /* @__PURE__ */ W("div", {
95
95
  className: fe(p.rangeInputsContainer, p.verticalLayout),
96
96
  children: [/* @__PURE__ */ n(b, {
97
- name: o,
98
- validate: (e) => B(y.current, O.current, s.FROM),
97
+ name: r,
98
+ validate: (e) => B(R.current, O.current, s.FROM),
99
99
  children: ({
100
100
  field: e,
101
- meta: t
101
+ meta: a
102
102
  }) => /* @__PURE__ */ n("div", {
103
103
  className: p.datePicker,
104
104
  children: /* @__PURE__ */ n(H, {
105
105
  ...e,
106
106
  ...$,
107
107
  calendarAriaLabel: l.formatMessage(i.selectStartDate),
108
- error: !G(x, P, _ !== s.FROM) && t.error,
108
+ error: !G(x, P, _ !== s.FROM) && a.error,
109
109
  isDisabled: h,
110
110
  label: l.formatMessage(i.afterDate),
111
111
  maxValue: le,
@@ -116,18 +116,18 @@ const $e = ({
116
116
  })
117
117
  })
118
118
  }), /* @__PURE__ */ n(b, {
119
- name: r,
120
- validate: (e) => B(y.current, O.current, s.TO),
119
+ name: o,
120
+ validate: (e) => B(R.current, O.current, s.TO),
121
121
  children: ({
122
122
  field: e,
123
- meta: t
123
+ meta: a
124
124
  }) => /* @__PURE__ */ n("div", {
125
125
  className: p.datePicker,
126
126
  children: /* @__PURE__ */ n(H, {
127
127
  ...e,
128
128
  ...$,
129
129
  calendarAriaLabel: l.formatMessage(i.selectEndDate),
130
- error: !G(P, x, _ !== s.TO) && t.error,
130
+ error: !G(P, x, _ !== s.TO) && a.error,
131
131
  isDisabled: h,
132
132
  label: l.formatMessage(i.beforeDate),
133
133
  maxValue: z,
@@ -140,22 +140,22 @@ const $e = ({
140
140
  })
141
141
  })]
142
142
  }) : /* @__PURE__ */ n(b, {
143
- name: m,
144
- validate: (e) => te((e == null ? void 0 : e.toString()) || ""),
143
+ name: u,
144
+ validate: (e) => ae(e?.toString() || ""),
145
145
  children: ({
146
146
  field: e,
147
- meta: t
147
+ meta: a
148
148
  }) => /* @__PURE__ */ n("div", {
149
149
  className: p.daysInputContainer,
150
150
  children: /* @__PURE__ */ n(me, {
151
151
  ...e,
152
152
  disabled: h,
153
- error: t.touched && t.error,
153
+ error: a.touched && a.error,
154
154
  hideLabel: !0,
155
155
  label: l.formatMessage(i.relativeDaysSelectLabel),
156
- onChange: (c) => re(c.target.value),
156
+ onChange: (c) => oe(c.target.value),
157
157
  placeholder: l.formatMessage(i.numberOfDays),
158
- value: (d == null ? void 0 : d.toString()) || ""
158
+ value: f?.toString() || ""
159
159
  })
160
160
  })
161
161
  });
@@ -168,15 +168,15 @@ const $e = ({
168
168
  advancedFilterFieldName: T,
169
169
  disableForm: h,
170
170
  fieldAdvancedFilterOptions: N,
171
- fieldNamePrefix: u,
171
+ fieldNamePrefix: d,
172
172
  filterOptionsMap: Y,
173
173
  isModified: ee,
174
174
  label: I,
175
175
  onAdvancedFilterOptionChange: g,
176
- onValueChange: oe,
176
+ onValueChange: re,
177
177
  portalElement: M,
178
178
  showLabel: !Z,
179
- value: f
179
+ value: m
180
180
  }), de()]
181
181
  })
182
182
  });