@m4l/components 0.1.59 → 0.1.61
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/components/CommonActions/components/ActionFormCancel/{index.5852dbc5.js → index.209c6c18.js} +11 -11
- package/components/CommonActions/components/ActionIntro/{index.12e8f032.js → index.0316f6fd.js} +1 -1
- package/components/CommonActions/components/Actions/{index.63c3d3a3.js → index.ada3dad0.js} +10 -10
- package/components/DataGrid/dictionary.d.ts +5 -2
- package/components/DataGrid/{index.947577ed.js → index.e0dbed95.js} +33 -20
- package/components/DynamicFilter/classes/index.d.ts +1 -1
- package/components/DynamicFilter/classes/types.d.ts +7 -2
- package/components/DynamicFilter/constants.d.ts +1 -1
- package/components/DynamicFilter/contexts/DynamicFilterContext/store.d.ts +22 -5
- package/components/DynamicFilter/dictionary.d.ts +0 -2
- package/components/DynamicFilter/{index.7843c415.js → index.4b678a4c.js} +140 -129
- package/components/DynamicFilter/subcomponents/ApplyedFilters/index.d.ts +5 -0
- package/components/DynamicFilter/subcomponents/ClearFilters/index.d.ts +1 -1
- package/components/DynamicFilter/types.d.ts +16 -2
- package/components/ErrorLabel/{index.908fb555.js → index.e140421c.js} +3 -3
- package/components/LanguagePopover/{index.14d4d878.js → index.df9b47a6.js} +3 -3
- package/components/ModalDialog/{index.708aa5a5.js → index.f604a139.js} +2 -2
- package/components/ObjectLogs/{index.389c3814.js → index.16bec4d1.js} +13 -13
- package/components/Period/{index.5494a974.js → index.08eb0046.js} +11 -11
- package/components/areas/components/AreasAdmin/{index.4f8dffdd.js → index.b9c660f6.js} +4 -4
- package/components/areas/components/AreasContainer/{index.1658078b.js → index.0a1e3e83.js} +2 -2
- package/components/areas/components/GridLayout/{index.55821687.js → index.e8a4734f.js} +4 -4
- package/components/areas/components/Window/icons.d.ts +3 -0
- package/components/areas/components/Window/{index.8cfef0db.js → index.e5df21bb.js} +30 -27
- package/components/areas/components/WindowPopUp/{index.54401e43.js → index.86a4e480.js} +27 -27
- package/components/areas/components/{index.c299e20f.js → index.3f3f9812.js} +8 -8
- package/components/areas/contexts/AreaContext/{index.d497504c.js → index.0c6a855b.js} +4 -2
- package/components/areas/contexts/AreasContext/{index.002c04af.js → index.75ccd2bf.js} +1 -1
- package/components/areas/contexts/{index.6bee8850.js → index.24da4b7b.js} +1 -1
- package/components/areas/hooks/{index.cb80f6a9.js → index.67a0b978.js} +1 -1
- package/components/areas/hooks/useArea/{index.91e7484b.js → index.ccbdccbb.js} +2 -2
- package/components/areas/{index.c9c73495.js → index.ff7f0e3c.js} +6 -6
- package/components/formatters/BooleanFormatter/dictionary.d.ts +7 -0
- package/components/formatters/BooleanFormatter/{index.a50933fb.js → index.bf947220.js} +16 -3
- package/components/formatters/PeriodFormatter/dictionary.d.ts +9 -0
- package/components/formatters/dictionary.d.ts +1 -8
- package/components/formatters/{index.7d2ad9ca.js → index.12ac825b.js} +25 -25
- package/components/hook-form/RHFAutocomplete/{index.8eab6160.js → index.b06ed59c.js} +1 -1
- package/components/hook-form/RHFAutocompleteAsync/{index.5be8b7a8.js → index.1296f3c7.js} +1 -1
- package/components/hook-form/RHFCheckbox/{index.da7bc824.js → index.6e80f572.js} +1 -1
- package/components/hook-form/RHFPeriod/{index.19ef4171.js → index.d5cd4e1a.js} +2 -2
- package/components/hook-form/RHFTextField/{index.3f6a18e3.js → index.a3fd0cdf.js} +2 -2
- package/components/modal/{WindowBase.545521d2.js → WindowBase.bda5a80a.js} +1 -1
- package/components/modal/{WindowConfirm.547d3fa0.js → WindowConfirm.d9c87591.js} +11 -11
- package/components/modal/{index.1da0fe8f.js → index.9fbe9933.js} +11 -11
- package/components/mui_extended/Accordion/{index.002bad72.js → index.725a10af.js} +1 -1
- package/components/mui_extended/IconButton/{index.460c0476.js → index.afa201a7.js} +1 -0
- package/components/mui_extended/Pager/{index.458f9f0d.js → index.d4d1a1a0.js} +1 -1
- package/components/mui_extended/{index.5095705d.js → index.9ce0bca3.js} +3 -3
- package/contexts/ModalContext/{index.5a9041b8.js → index.9ddde31c.js} +1 -1
- package/hooks/useModal/{index.404c0539.js → index.3aca4716.js} +1 -1
- package/index.js +61 -68
- package/package.json +1 -2
- package/{vendor.c2aabf37.js → vendor.afa62d25.js} +31 -31
package/components/CommonActions/components/ActionFormCancel/{index.5852dbc5.js → index.209c6c18.js}
RENAMED
|
@@ -3,28 +3,28 @@ import { useModuleDictionary, useModuleSkeleton } from "@m4l/core";
|
|
|
3
3
|
import { Skeleton } from "@mui/material";
|
|
4
4
|
import { B as Button } from "../../../mui_extended/Button/index.8406ed5b.js";
|
|
5
5
|
import { useCallback } from "react";
|
|
6
|
-
import { u as useModal } from "../../../../hooks/useModal/index.
|
|
6
|
+
import { u as useModal } from "../../../../hooks/useModal/index.3aca4716.js";
|
|
7
7
|
import "../../../../react-draggable.6471b07e.js";
|
|
8
|
-
import "../../../ModalDialog/index.
|
|
8
|
+
import "../../../ModalDialog/index.f604a139.js";
|
|
9
9
|
import "../../../Resizeable/index.04fa8de5.js";
|
|
10
10
|
import { jsx } from "react/jsx-runtime";
|
|
11
11
|
import "@m4l/graphics";
|
|
12
|
-
import { W as WindowConfirm } from "../../../modal/WindowConfirm.
|
|
13
|
-
import "../../../modal/WindowBase.
|
|
12
|
+
import { W as WindowConfirm } from "../../../modal/WindowConfirm.d9c87591.js";
|
|
13
|
+
import "../../../modal/WindowBase.bda5a80a.js";
|
|
14
14
|
import "../../../Icon/index.b29ff2d9.js";
|
|
15
15
|
import "@mui/material/styles";
|
|
16
|
-
import "../../../areas/components/index.
|
|
17
|
-
import "../../../areas/components/AreasAdmin/index.
|
|
18
|
-
import "../../../mui_extended/IconButton/index.
|
|
16
|
+
import "../../../areas/components/index.3f3f9812.js";
|
|
17
|
+
import "../../../areas/components/AreasAdmin/index.b9c660f6.js";
|
|
18
|
+
import "../../../mui_extended/IconButton/index.afa201a7.js";
|
|
19
19
|
import "zustand";
|
|
20
|
-
import "../../../areas/contexts/AreasContext/index.
|
|
20
|
+
import "../../../areas/contexts/AreasContext/index.75ccd2bf.js";
|
|
21
21
|
import "zustand/shallow";
|
|
22
|
-
import "../../../areas/components/AreasContainer/index.
|
|
22
|
+
import "../../../areas/components/AreasContainer/index.0a1e3e83.js";
|
|
23
23
|
import "react-grid-layout/css/styles.css";
|
|
24
24
|
import "../../../../react-resizable.b620abed.js";
|
|
25
|
-
import "../../../areas/contexts/index.
|
|
25
|
+
import "../../../areas/contexts/index.24da4b7b.js";
|
|
26
26
|
import "../../../areas/contexts/DynamicMFParmsContext/index.c19cb8cc.js";
|
|
27
|
-
import { u as useWindowToolsMF } from "../../../areas/hooks/index.
|
|
27
|
+
import { u as useWindowToolsMF } from "../../../areas/hooks/index.67a0b978.js";
|
|
28
28
|
function ActionFormCancel() {
|
|
29
29
|
const {
|
|
30
30
|
getLabel
|
package/components/CommonActions/components/ActionIntro/{index.12e8f032.js → index.0316f6fd.js}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useModuleDictionary } from "@m4l/core";
|
|
2
2
|
import { B as Button } from "../../../mui_extended/Button/index.8406ed5b.js";
|
|
3
|
-
import { T as TEST_PROP_ID } from "../../../../vendor.
|
|
3
|
+
import { T as TEST_PROP_ID } from "../../../../vendor.afa62d25.js";
|
|
4
4
|
import { jsx } from "react/jsx-runtime";
|
|
5
5
|
const ACTIONINTRO_TEST_ID = "m4lactions";
|
|
6
6
|
const ActionIntro = (props) => {
|
|
@@ -6,25 +6,25 @@ import "@mui/material/Button";
|
|
|
6
6
|
import "../../../mui_extended/Button/index.8406ed5b.js";
|
|
7
7
|
import "react-hook-form";
|
|
8
8
|
import "react";
|
|
9
|
-
import "../../../../contexts/ModalContext/index.
|
|
9
|
+
import "../../../../contexts/ModalContext/index.9ddde31c.js";
|
|
10
10
|
import "../../../../react-draggable.6471b07e.js";
|
|
11
|
-
import "../../../ModalDialog/index.
|
|
11
|
+
import "../../../ModalDialog/index.f604a139.js";
|
|
12
12
|
import "../../../Resizeable/index.04fa8de5.js";
|
|
13
13
|
import "@m4l/graphics";
|
|
14
14
|
import "@mui/lab";
|
|
15
|
-
import "../../../modal/WindowConfirm.
|
|
15
|
+
import "../../../modal/WindowConfirm.d9c87591.js";
|
|
16
16
|
import "../../../Icon/index.b29ff2d9.js";
|
|
17
|
-
import "../../../modal/WindowBase.
|
|
18
|
-
import "../../../areas/components/index.
|
|
19
|
-
import "../../../areas/components/AreasAdmin/index.
|
|
20
|
-
import "../../../mui_extended/IconButton/index.
|
|
17
|
+
import "../../../modal/WindowBase.bda5a80a.js";
|
|
18
|
+
import "../../../areas/components/index.3f3f9812.js";
|
|
19
|
+
import "../../../areas/components/AreasAdmin/index.b9c660f6.js";
|
|
20
|
+
import "../../../mui_extended/IconButton/index.afa201a7.js";
|
|
21
21
|
import "zustand";
|
|
22
|
-
import "../../../areas/contexts/AreasContext/index.
|
|
22
|
+
import "../../../areas/contexts/AreasContext/index.75ccd2bf.js";
|
|
23
23
|
import "zustand/shallow";
|
|
24
|
-
import "../../../areas/components/AreasContainer/index.
|
|
24
|
+
import "../../../areas/components/AreasContainer/index.0a1e3e83.js";
|
|
25
25
|
import "react-grid-layout/css/styles.css";
|
|
26
26
|
import "../../../../react-resizable.b620abed.js";
|
|
27
|
-
import "../../../areas/contexts/index.
|
|
27
|
+
import "../../../areas/contexts/index.24da4b7b.js";
|
|
28
28
|
import "../../../areas/contexts/DynamicMFParmsContext/index.c19cb8cc.js";
|
|
29
29
|
const WrapperStandarActions = styled("div")(({
|
|
30
30
|
theme
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
-
import { Dictionary } from '@m4l/core';
|
|
2
1
|
export declare function getDataGridComponentsDictionary(): string[];
|
|
3
|
-
export declare const
|
|
2
|
+
export declare const dictionary: {
|
|
3
|
+
LABEL_ACTIONS: string;
|
|
4
|
+
LABEL_ROWS_PER_PAGE: string;
|
|
5
|
+
LABEL_OF: string;
|
|
6
|
+
};
|
|
@@ -7,36 +7,36 @@ import { SvgIcon, Checkbox, InputBase, Skeleton } from "@mui/material";
|
|
|
7
7
|
import { jsx, jsxs, Fragment } from "react/jsx-runtime";
|
|
8
8
|
import { voidFunction, useModuleDictionary, useModuleSkeleton, getPropertyByString, useEnvironment } from "@m4l/core";
|
|
9
9
|
import { M as MenuActions } from "../mui_extended/MenuActions/index.1affe51a.js";
|
|
10
|
-
import {
|
|
11
|
-
import { I as IconButton } from "../mui_extended/IconButton/index.
|
|
12
|
-
import { u as useModal } from "../../hooks/useModal/index.
|
|
10
|
+
import { g as getPagerComponentsDictionary, P as Pager } from "../mui_extended/Pager/index.d4d1a1a0.js";
|
|
11
|
+
import { I as IconButton } from "../mui_extended/IconButton/index.afa201a7.js";
|
|
12
|
+
import { u as useModal } from "../../hooks/useModal/index.3aca4716.js";
|
|
13
13
|
import { A as ActionCancel } from "../CommonActions/components/ActionCancel/index.a81752ef.js";
|
|
14
|
-
import { A as ActionIntro } from "../CommonActions/components/ActionIntro/index.
|
|
14
|
+
import { A as ActionIntro } from "../CommonActions/components/ActionIntro/index.0316f6fd.js";
|
|
15
15
|
import "../../react-draggable.6471b07e.js";
|
|
16
|
-
import { g as getModalDialogComponentsDictionary } from "../ModalDialog/index.
|
|
16
|
+
import { g as getModalDialogComponentsDictionary } from "../ModalDialog/index.f604a139.js";
|
|
17
17
|
import "../Resizeable/index.04fa8de5.js";
|
|
18
18
|
import { useResponsiveDesktop } from "@m4l/graphics";
|
|
19
|
-
import { A as Actions$1 } from "../CommonActions/components/Actions/index.
|
|
19
|
+
import { A as Actions$1 } from "../CommonActions/components/Actions/index.ada3dad0.js";
|
|
20
20
|
import "react-hook-form";
|
|
21
21
|
import "@mui/material/Button";
|
|
22
22
|
import "../mui_extended/Button/index.8406ed5b.js";
|
|
23
|
-
import "../areas/components/index.
|
|
24
|
-
import "../areas/components/AreasAdmin/index.
|
|
23
|
+
import "../areas/components/index.3f3f9812.js";
|
|
24
|
+
import "../areas/components/AreasAdmin/index.b9c660f6.js";
|
|
25
25
|
import "zustand";
|
|
26
|
-
import "../areas/contexts/AreasContext/index.
|
|
26
|
+
import "../areas/contexts/AreasContext/index.75ccd2bf.js";
|
|
27
27
|
import "zustand/shallow";
|
|
28
|
-
import "../areas/components/AreasContainer/index.
|
|
28
|
+
import "../areas/components/AreasContainer/index.0a1e3e83.js";
|
|
29
29
|
import "react-grid-layout/css/styles.css";
|
|
30
30
|
import "../../react-resizable.b620abed.js";
|
|
31
|
-
import "../areas/contexts/index.
|
|
31
|
+
import "../areas/contexts/index.24da4b7b.js";
|
|
32
32
|
import "../areas/contexts/DynamicMFParmsContext/index.c19cb8cc.js";
|
|
33
33
|
import "@mui/lab";
|
|
34
|
-
import "../modal/WindowConfirm.
|
|
34
|
+
import "../modal/WindowConfirm.d9c87591.js";
|
|
35
35
|
import "../Icon/index.b29ff2d9.js";
|
|
36
|
-
import { W as WindowBase } from "../modal/WindowBase.
|
|
37
|
-
import { B as BooleanFormatter } from "../formatters/BooleanFormatter/index.
|
|
36
|
+
import { W as WindowBase } from "../modal/WindowBase.bda5a80a.js";
|
|
37
|
+
import { B as BooleanFormatter } from "../formatters/BooleanFormatter/index.bf947220.js";
|
|
38
38
|
import { D as DateFormatter } from "../formatters/DateFormatter/index.578a9f53.js";
|
|
39
|
-
import { C as ConcatenatedFormatter } from "../formatters/index.
|
|
39
|
+
import { C as ConcatenatedFormatter } from "../formatters/index.12ac825b.js";
|
|
40
40
|
const WrapperGrid = styled("div")(() => ({
|
|
41
41
|
display: "flex",
|
|
42
42
|
flexDirection: "column",
|
|
@@ -711,7 +711,7 @@ function ActionsFormatter(props) {
|
|
|
711
711
|
}
|
|
712
712
|
const ActionsColumn = {
|
|
713
713
|
key: ACTIONS_COLUMN_KEY,
|
|
714
|
-
name:
|
|
714
|
+
name: getActionLabel(),
|
|
715
715
|
width: 60,
|
|
716
716
|
withFilter: false,
|
|
717
717
|
resizable: true,
|
|
@@ -720,6 +720,9 @@ const ActionsColumn = {
|
|
|
720
720
|
type: "custom",
|
|
721
721
|
formatter: ActionsFormatter
|
|
722
722
|
};
|
|
723
|
+
function getActionLabel() {
|
|
724
|
+
return "";
|
|
725
|
+
}
|
|
723
726
|
const WrapperSkeleton = styled("div")(() => ({
|
|
724
727
|
display: "flex",
|
|
725
728
|
width: "100%",
|
|
@@ -1570,12 +1573,23 @@ const WrapperActions = styled("div")(({ theme }) => ({
|
|
|
1570
1573
|
overflow: "hidden"
|
|
1571
1574
|
}
|
|
1572
1575
|
}));
|
|
1576
|
+
function getDataGridComponentsDictionary() {
|
|
1577
|
+
return ["data_grid"].concat(getPagerComponentsDictionary()).concat(getModalDialogComponentsDictionary());
|
|
1578
|
+
}
|
|
1579
|
+
const dictionary = {
|
|
1580
|
+
LABEL_ACTIONS: "actions",
|
|
1581
|
+
LABEL_ROWS_PER_PAGE: "pager.rows_per_page",
|
|
1582
|
+
LABEL_OF: "pager.of"
|
|
1583
|
+
};
|
|
1573
1584
|
function Actions(props) {
|
|
1574
1585
|
const isDesktop = useResponsiveDesktop();
|
|
1575
1586
|
const {
|
|
1576
1587
|
rowHeights
|
|
1577
1588
|
} = useDataGrid();
|
|
1578
1589
|
const isSkeleton = useModuleSkeleton();
|
|
1590
|
+
const {
|
|
1591
|
+
getLabel
|
|
1592
|
+
} = useModuleDictionary();
|
|
1579
1593
|
const {
|
|
1580
1594
|
withRowsCount = true,
|
|
1581
1595
|
withPager = true,
|
|
@@ -1591,7 +1605,9 @@ function Actions(props) {
|
|
|
1591
1605
|
...pagerOptions,
|
|
1592
1606
|
totalRecords: pagerOptions.totalRecords,
|
|
1593
1607
|
isSkeleton,
|
|
1594
|
-
isDesktop
|
|
1608
|
+
isDesktop,
|
|
1609
|
+
labelRows: getLabel(dictionary.LABEL_ROWS_PER_PAGE),
|
|
1610
|
+
labelOf: getLabel(dictionary.LABEL_OF)
|
|
1595
1611
|
}), typeof rowHeights !== "number" && /* @__PURE__ */ jsx(Density, {}), withLocalFilters && /* @__PURE__ */ jsx(Filter, {}), withSettings && /* @__PURE__ */ jsx(Settings, {
|
|
1596
1612
|
...settingsProps
|
|
1597
1613
|
})]
|
|
@@ -1690,9 +1706,6 @@ function columnConcatenatedValuesFormatter(props) {
|
|
|
1690
1706
|
});
|
|
1691
1707
|
};
|
|
1692
1708
|
}
|
|
1693
|
-
function getDataGridComponentsDictionary() {
|
|
1694
|
-
return ["data_grid"].concat(getPagerComponentsDictionary()).concat(getModalDialogComponentsDictionary());
|
|
1695
|
-
}
|
|
1696
1709
|
const Input = styled("input")(() => ({
|
|
1697
1710
|
appearance: "none",
|
|
1698
1711
|
boxSizing: "border-box",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DynamicFilterClasses } from './types';
|
|
2
2
|
import { OwnerState } from '../contexts/DynamicFilterContext/store';
|
|
3
3
|
export declare const dynamicFilterClasses: DynamicFilterClasses;
|
|
4
|
-
export declare const useUtilityClasses: (ownerState: OwnerState) => Record<"root" | "containerFistRow" | "filterButton" | "containerInputFilter" | "wrapperApplyedFilters" | "containerApplyedFilters" | "applyedFilter" | "
|
|
4
|
+
export declare const useUtilityClasses: (ownerState: OwnerState) => Record<"root" | "containerFistRow" | "filterButton" | "containerInputFilter" | "wrapperApplyedFilters" | "containerApplyedFilters" | "applyedFilter" | "clearFiltersButton" | "popoverMenuFields" | "popoverMenuFieldsPaper" | "popoverMenuFieldsItem" | "popoverFilter" | "popoverFilterPaper" | "popoverFilterHeader" | "containerBooleanFilter" | "containerDateTimeFilter" | "containerNumberFilter" | "containerStringFilter", string>;
|
|
5
5
|
export declare type Classes = ReturnType<typeof useUtilityClasses>;
|
|
@@ -6,17 +6,22 @@ export interface DynamicFilterClasses {
|
|
|
6
6
|
wrapperApplyedFilters: string;
|
|
7
7
|
containerApplyedFilters: string;
|
|
8
8
|
applyedFilter: string;
|
|
9
|
-
|
|
9
|
+
clearFiltersButton: string;
|
|
10
|
+
popoverMenuFields: string;
|
|
11
|
+
popoverMenuFieldsPaper: string;
|
|
10
12
|
popoverMenuFieldsItem: string;
|
|
13
|
+
popoverFilter: string;
|
|
11
14
|
popoverFilterPaper: string;
|
|
12
15
|
popoverFilterHeader: string;
|
|
13
16
|
containerBooleanFilter: string;
|
|
14
17
|
containerDateTimeFilter: string;
|
|
15
18
|
containerNumberFilter: string;
|
|
16
19
|
containerStringFilter: string;
|
|
20
|
+
isSkeleton: string;
|
|
17
21
|
inEdition: string;
|
|
18
|
-
|
|
22
|
+
isInvalid: string;
|
|
19
23
|
isDirty: string;
|
|
20
24
|
isMobile: string;
|
|
25
|
+
noSetted: string;
|
|
21
26
|
}
|
|
22
27
|
export declare type DynamicFilterClassesKey = keyof DynamicFilterClasses;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { BooleanOperator, DateTimeOperator, Field, NumberOperator, Operator, StringOperator } from './types';
|
|
2
|
-
export declare const COMPONENT_TEST_ID = "
|
|
2
|
+
export declare const COMPONENT_TEST_ID = "M4LDynamicFilter";
|
|
3
3
|
export declare const COMPONENT_CLASS_NAME = "M4LDynamicFilter";
|
|
4
4
|
export declare const ASSETS_URL = "/frontend/components/dynamic_filter/assets/icons/";
|
|
5
5
|
export declare const ASSETS: {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GetLabelType } from '@m4l/core';
|
|
2
|
-
import { Field, FilterFieldApplyed, FilterToEditApply, InitialFilterApplyed
|
|
2
|
+
import { Field, FilterFieldApplyed, FilterToEditApply, InitialFilterApplyed } from '../../types';
|
|
3
3
|
import { Classes } from '../../classes';
|
|
4
4
|
import { WritableDraft } from 'immer/dist/internal';
|
|
5
5
|
export declare type OpenFor = 'add' | 'edit';
|
|
@@ -38,6 +38,10 @@ export declare type PopoverFilterData = PopoverFilterDataAdd | PopoverFilterData
|
|
|
38
38
|
* @description Interface que define la variables que se van a usar en clases del componente
|
|
39
39
|
*/
|
|
40
40
|
export declare type OwnerState = {
|
|
41
|
+
/**
|
|
42
|
+
* "isSkeleton" indica si el componente está en skeleton.
|
|
43
|
+
*/
|
|
44
|
+
isSkeleton: boolean;
|
|
41
45
|
/**
|
|
42
46
|
* "inEdition" se establece cuando se está en edición.
|
|
43
47
|
*/
|
|
@@ -55,6 +59,12 @@ export declare type OwnerState = {
|
|
|
55
59
|
*/
|
|
56
60
|
isMobile: boolean;
|
|
57
61
|
};
|
|
62
|
+
/**
|
|
63
|
+
* @type
|
|
64
|
+
* @name ExternalOwnerState
|
|
65
|
+
* @description Estados que se actulizan por fuera del store, a través de hooks
|
|
66
|
+
*/
|
|
67
|
+
export declare type ExternalOwnerState = Pick<OwnerState, 'isMobile' | 'isSkeleton'>;
|
|
58
68
|
/**
|
|
59
69
|
* @interface DynamicFilterState
|
|
60
70
|
* @name DynamicFilterState
|
|
@@ -95,8 +105,15 @@ export interface DynamicFilterState {
|
|
|
95
105
|
* @description Campos disponibles para filtrar
|
|
96
106
|
*/
|
|
97
107
|
availableFields: Array<Field>;
|
|
108
|
+
/**
|
|
109
|
+
* "applyedFilters" Filtros aplicados actualmente
|
|
110
|
+
*/
|
|
98
111
|
applyedFilters: Array<FilterFieldApplyed>;
|
|
99
|
-
|
|
112
|
+
/**
|
|
113
|
+
* "countOnChangeFiltersApplyed" Cantid de veces que el filtro se ha aplicado, sirve para suscribirse y aplicar el filtro.
|
|
114
|
+
* Esto se debe hacer porque no se puede lanzar un handler que modifica valores, durante una renderización.
|
|
115
|
+
*/
|
|
116
|
+
countOnChangeFiltersApplyed: number;
|
|
100
117
|
/** popoverFilterData: para emerger el popuup de modificación campos */
|
|
101
118
|
popoverFilterData?: PopoverFilterData;
|
|
102
119
|
classes: Classes;
|
|
@@ -177,11 +194,11 @@ export interface DynamicFilterStateWithActions extends DynamicFilterState {
|
|
|
177
194
|
*/
|
|
178
195
|
setInEdition: (newInEdition: boolean) => void;
|
|
179
196
|
/**
|
|
180
|
-
* @description Modifica
|
|
197
|
+
* @description Modifica los estados que se actualizan externamente al Store
|
|
181
198
|
* @param newIsMobile
|
|
182
199
|
* @returns
|
|
183
200
|
*/
|
|
184
|
-
|
|
201
|
+
setExternalState: (newExternalState: ExternalOwnerState) => void;
|
|
185
202
|
/**
|
|
186
203
|
* @description Establece la función de apertura del menuu de campos
|
|
187
204
|
* @param anchorEl
|
|
@@ -194,7 +211,7 @@ export interface DynamicFilterStateWithActions extends DynamicFilterState {
|
|
|
194
211
|
closePopoverMenuFields: (newInEdition?: boolean) => void;
|
|
195
212
|
};
|
|
196
213
|
}
|
|
197
|
-
declare type InitialStoreProps = Pick<DynamicFilterState, 'automatic' | '
|
|
214
|
+
declare type InitialStoreProps = Pick<DynamicFilterState, 'automatic' | 'automatic' | 'fields' | 'withAllField' | 'getLabel' | 'getLabel' | 'allField' | 'ownerState'>;
|
|
198
215
|
/**
|
|
199
216
|
* @description Crea el store de zustand para el componente DynamicFilter
|
|
200
217
|
* @param initProps Variables iniciales que necesita store para poder inicializarlo
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import { Dictionary } from '@m4l/core';
|
|
2
1
|
export declare const DYNAMICFILTER_DICTIONARY_ID = "dynamic_filter";
|
|
3
2
|
export declare function getDynamicFilterComponentsDictionary(): string[];
|
|
4
|
-
export declare const defaultDynamicFilterDictionary: Dictionary;
|
|
5
3
|
export declare const LABEL_FILTER_BUTTON = "filter_tooltip";
|
|
6
4
|
export declare const DICCTIONARY: {
|
|
7
5
|
readonly input_placeholder: "input_placeholder";
|