@m4l/components 9.3.23 → 9.3.24-JT04112025.beta.2
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/@types/export.d.ts +6 -0
- package/@types/types.d.ts +26 -1
- package/components/DataGrid/DataGrid.js +6 -2
- package/components/DataGrid/Datagrid.styles.js +67 -18
- package/components/DataGrid/constants.d.ts +19 -0
- package/components/DataGrid/formatters/ColumnIconFormatter/formatter.d.ts +1 -2
- package/components/DataGrid/formatters/ColumnIconFormatter/formatter.js +3 -6
- package/components/DataGrid/formatters/ColumnIconFormatter/types.d.ts +2 -4
- package/components/DataGrid/formatters/ColumnSetCheckFormatter/formatter.js +7 -1
- package/components/DataGrid/formatters/ColumnSetCheckFormatter/types.d.ts +1 -0
- package/components/DataGrid/formatters/ColumnTagsFormatter/formatter.d.ts +8 -0
- package/components/DataGrid/formatters/ColumnTagsFormatter/formatter.js +16 -0
- package/components/DataGrid/formatters/ColumnTagsFormatter/index.d.ts +3 -0
- package/components/DataGrid/formatters/ColumnTagsFormatter/index.js +1 -0
- package/components/DataGrid/formatters/ColumnTagsFormatter/types.d.ts +5 -0
- package/components/DataGrid/formatters/ColumnTagsFormatter/useColumnTags.d.ts +9 -0
- package/components/DataGrid/formatters/ColumnTagsFormatter/useColumnTags.js +60 -0
- package/components/DataGrid/formatters/index.d.ts +1 -0
- package/components/DataGrid/hooks/useModalCardDetail.d.ts +2 -2
- package/components/DataGrid/hooks/useModalCardDetail.js +49 -48
- package/components/DataGrid/slots/DataGridEnum.d.ts +2 -0
- package/components/DataGrid/slots/DataGridEnum.js +2 -0
- package/components/DataGrid/slots/DataGridSlot.d.ts +3 -1
- package/components/DataGrid/slots/DataGridSlot.js +45 -37
- package/components/DataGrid/subcomponents/Cards/helpers/calculateCardHeight.d.ts +18 -0
- package/components/DataGrid/subcomponents/Cards/helpers/calculateCardHeight.js +10 -0
- package/components/DataGrid/subcomponents/Cards/helpers/scrollToCardElement.d.ts +9 -0
- package/components/DataGrid/subcomponents/Cards/helpers/scrollToCardElement.js +25 -0
- package/components/DataGrid/subcomponents/Cards/hooks/useCardContent.d.ts +1 -2
- package/components/DataGrid/subcomponents/Cards/hooks/useCardContent.js +62 -73
- package/components/DataGrid/subcomponents/Cards/index.js +71 -16
- package/components/DataGrid/subcomponents/Cards/subcomponents/CardDetails/index.js +36 -18
- package/components/DataGrid/subcomponents/Cards/subcomponents/CardHeader/index.d.ts +1 -1
- package/components/DataGrid/subcomponents/Cards/subcomponents/CardHeader/index.js +13 -20
- package/components/DataGrid/subcomponents/Cards/subcomponents/CardRow/index.d.ts +6 -1
- package/components/DataGrid/subcomponents/Cards/subcomponents/CardRow/index.js +67 -36
- package/components/DataGrid/subcomponents/Cards/subcomponents/IntersectCard/index.js +9 -2
- package/components/DataGrid/subcomponents/Cards/subcomponents/LazyLoadCard/index.js +4 -2
- package/components/DataGrid/subcomponents/Cards/types.d.ts +50 -1
- package/components/DataGrid/subcomponents/CheckboxCellAdapter/index.js +5 -2
- package/components/DataGrid/subcomponents/ControlNavigate/ControlNavigate.js +1 -1
- package/components/DataGrid/subcomponents/HeaderActions/index.js +1 -1
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/RowsCount/index.js +1 -1
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/Settings/subcomponents/ColumnsConfig/index.js +1 -1
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/Settings/subcomponents/ColumnsConfigCards/index.js +1 -1
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/ViewMode/index.js +1 -1
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/hooks/useModalSettings/index.js +1 -1
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/hooks/useModalSettingsCards/index.js +1 -1
- package/components/DataGrid/subcomponents/Table/index.js +60 -41
- package/components/DataGrid/subcomponents/Table/subcomponents/CheckboxFormatter.js +16 -18
- package/components/DataGrid/subcomponents/Table/subcomponents/DraggableHeaderRenderer.js +3 -3
- package/components/DataGrid/subcomponents/Table/subcomponents/HeaderRenderClick/HeaderRenderClick.js +1 -1
- package/components/DataGrid/subcomponents/editors/TextEditor/index.js +1 -1
- package/components/DataGrid/tests/helpers/types.d.ts +3 -0
- package/components/DataGrid/types.d.ts +17 -2
- package/components/DynamicFilter/helpers/formatToInitialFilters.js +3 -3
- package/components/DynamicFilter/subcomponents/FieldTypes/BooleanFilter/helpers.js +11 -3
- package/components/DynamicFilter/subcomponents/FieldTypes/DateTimeFilter/helpers.js +16 -4
- package/components/DynamicFilter/subcomponents/FieldTypes/NumberFilter/helpers.js +11 -8
- package/components/DynamicFilter/subcomponents/FieldTypes/SelectAsyncFilter/helpers.js +21 -8
- package/components/DynamicFilter/subcomponents/FieldTypes/SelectFilter/helpers.js +18 -8
- package/components/DynamicFilter/subcomponents/FieldTypes/StringFilter/helpers.js +5 -3
- package/components/ObjectLogs/slots/ObjectLogsSlots.js +3 -5
- package/components/formatters/IconsFormatter/IconsFormatter.d.ts +6 -0
- package/components/formatters/IconsFormatter/IconsFormatter.js +22 -0
- package/components/formatters/IconsFormatter/IconsFormatter.styles.d.ts +2 -0
- package/components/formatters/IconsFormatter/IconsFormatter.styles.js +29 -0
- package/components/formatters/IconsFormatter/constants.d.ts +1 -0
- package/components/formatters/IconsFormatter/constants.js +4 -0
- package/components/{DataGrid/formatters/ColumnIconFormatter → formatters/IconsFormatter}/helpers/renderIcon.d.ts +2 -2
- package/components/formatters/IconsFormatter/helpers/renderIcon.js +24 -0
- package/components/formatters/IconsFormatter/helpers/renderMultipleIcons.d.ts +7 -0
- package/components/formatters/IconsFormatter/helpers/renderMultipleIcons.js +16 -0
- package/components/formatters/IconsFormatter/index.d.ts +3 -0
- package/components/formatters/IconsFormatter/index.js +1 -0
- package/components/formatters/IconsFormatter/slots/IconsFormatterEnum.d.ts +5 -0
- package/components/formatters/IconsFormatter/slots/IconsFormatterEnum.js +9 -0
- package/components/formatters/IconsFormatter/slots/IconsFormatterSlots.d.ts +9 -0
- package/components/formatters/IconsFormatter/slots/IconsFormatterSlots.js +22 -0
- package/components/formatters/IconsFormatter/types.d.ts +57 -0
- package/components/formatters/IconsFormatter/types.js +1 -0
- package/components/formatters/TagsFormatter/TagsFormatter.d.ts +5 -0
- package/components/formatters/TagsFormatter/TagsFormatter.js +28 -0
- package/components/formatters/TagsFormatter/TagsFormatter.styles.d.ts +2 -0
- package/components/formatters/TagsFormatter/TagsFormatter.styles.js +41 -0
- package/components/formatters/TagsFormatter/constants.d.ts +5 -0
- package/components/formatters/TagsFormatter/constants.js +11 -0
- package/components/formatters/TagsFormatter/helpers/renderMultipleTag.d.ts +8 -0
- package/components/formatters/TagsFormatter/helpers/renderMultipleTag.js +19 -0
- package/components/formatters/TagsFormatter/helpers/renderTag.d.ts +7 -0
- package/components/formatters/TagsFormatter/helpers/renderTag.js +9 -0
- package/components/formatters/TagsFormatter/helpers/validateHexColor.d.ts +8 -0
- package/components/formatters/TagsFormatter/helpers/validateHexColor.js +9 -0
- package/components/formatters/TagsFormatter/index.d.ts +2 -0
- package/components/formatters/TagsFormatter/index.js +1 -0
- package/components/formatters/TagsFormatter/slots/TagsFormatterEnum.d.ts +5 -0
- package/components/formatters/TagsFormatter/slots/TagsFormatterEnum.js +9 -0
- package/components/formatters/TagsFormatter/slots/TagsFormatterSlots.d.ts +6 -0
- package/components/formatters/TagsFormatter/slots/TagsFormatterSlots.js +16 -0
- package/components/formatters/TagsFormatter/subcomponents/Tag/Tag.d.ts +5 -0
- package/components/formatters/TagsFormatter/subcomponents/Tag/Tag.js +35 -0
- package/components/formatters/TagsFormatter/subcomponents/Tag/index.d.ts +0 -0
- package/components/formatters/TagsFormatter/types.d.ts +47 -0
- package/components/formatters/index.d.ts +6 -5
- package/contexts/ModalContext/index.js +5 -5
- package/index.js +62 -56
- package/package.json +1 -1
- package/components/DataGrid/formatters/ColumnIconFormatter/constants.js +0 -4
- package/components/DataGrid/formatters/ColumnIconFormatter/helpers/renderIcon.js +0 -58
- package/components/DataGrid/formatters/ColumnIconFormatter/helpers/renderMultipleIcons.d.ts +0 -7
- package/components/DataGrid/formatters/ColumnIconFormatter/helpers/renderMultipleIcons.js +0 -19
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { g as getComponentClasses } from "../../../utils/getComponentSlotRoot.js";
|
|
2
|
+
import { T as TagsFormatterSlots } from "./slots/TagsFormatterEnum.js";
|
|
3
|
+
const TAGS_FORMATTER_KEY_COMPONENT = "M4LTagsFormatter";
|
|
4
|
+
const TAGS_FORMATTER_CLASSES = getComponentClasses(
|
|
5
|
+
TAGS_FORMATTER_KEY_COMPONENT,
|
|
6
|
+
TagsFormatterSlots
|
|
7
|
+
);
|
|
8
|
+
export {
|
|
9
|
+
TAGS_FORMATTER_KEY_COMPONENT as T,
|
|
10
|
+
TAGS_FORMATTER_CLASSES as a
|
|
11
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { TagConfig } from '../types';
|
|
2
|
+
/**
|
|
3
|
+
* Helper que renderiza múltiples tags
|
|
4
|
+
* @param tags - Array de tags
|
|
5
|
+
* @param size - Tamaño de los chips
|
|
6
|
+
* @returns Array de componentes de tags renderizados
|
|
7
|
+
*/
|
|
8
|
+
export declare const renderMultipleTags: (tags: TagConfig[], size: "small" | "medium", className?: string) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { T as TagsContainerStyled } from "../slots/TagsFormatterSlots.js";
|
|
3
|
+
import { r as renderTag } from "./renderTag.js";
|
|
4
|
+
const renderMultipleTags = (tags, size, className) => {
|
|
5
|
+
return /* @__PURE__ */ jsx(TagsContainerStyled, { children: tags.map((tag, index) => {
|
|
6
|
+
const tagWithKey = {
|
|
7
|
+
...tag,
|
|
8
|
+
key: tag.key || `${tag.label}-${index}`
|
|
9
|
+
};
|
|
10
|
+
return renderTag({
|
|
11
|
+
tag: tagWithKey,
|
|
12
|
+
size,
|
|
13
|
+
className
|
|
14
|
+
});
|
|
15
|
+
}) });
|
|
16
|
+
};
|
|
17
|
+
export {
|
|
18
|
+
renderMultipleTags as r
|
|
19
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { T as Tag } from "../subcomponents/Tag/Tag.js";
|
|
3
|
+
const renderTag = (props) => {
|
|
4
|
+
const { tag, size, className } = props;
|
|
5
|
+
return /* @__PURE__ */ jsx(Tag, { ...tag, size, className });
|
|
6
|
+
};
|
|
7
|
+
export {
|
|
8
|
+
renderTag as r
|
|
9
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Valida que un color sea hexadecimal válido
|
|
3
|
+
* - Debe existir
|
|
4
|
+
* - Debe empezar con #
|
|
5
|
+
* @param backgroundColor - Color a validar
|
|
6
|
+
* @returns true si el color es válido, false en caso contrario
|
|
7
|
+
*/
|
|
8
|
+
export declare const validateHexColor: (backgroundColor: string) => boolean;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
var TagsFormatterSlots = /* @__PURE__ */ ((TagsFormatterSlots2) => {
|
|
2
|
+
TagsFormatterSlots2["root"] = "root";
|
|
3
|
+
TagsFormatterSlots2["tagsContainer"] = "tagsContainer";
|
|
4
|
+
TagsFormatterSlots2["tag"] = "tag";
|
|
5
|
+
return TagsFormatterSlots2;
|
|
6
|
+
})(TagsFormatterSlots || {});
|
|
7
|
+
export {
|
|
8
|
+
TagsFormatterSlots as T
|
|
9
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export declare const TagsContainerStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Record<string, unknown> & {
|
|
2
|
+
ownerState?: any;
|
|
3
|
+
}, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
|
|
4
|
+
export declare const TagStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Record<string, unknown> & {
|
|
5
|
+
ownerState?: any;
|
|
6
|
+
}, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { styled } from "@mui/material";
|
|
2
|
+
import { T as TAGS_FORMATTER_KEY_COMPONENT } from "../constants.js";
|
|
3
|
+
import { T as TagsFormatterSlots } from "./TagsFormatterEnum.js";
|
|
4
|
+
import { t as tagsFormatterStyles } from "../TagsFormatter.styles.js";
|
|
5
|
+
const TagsContainerStyled = styled("div", {
|
|
6
|
+
name: TAGS_FORMATTER_KEY_COMPONENT,
|
|
7
|
+
slot: TagsFormatterSlots.tagsContainer
|
|
8
|
+
})(tagsFormatterStyles.tagsContainer);
|
|
9
|
+
const TagStyled = styled("div", {
|
|
10
|
+
name: TAGS_FORMATTER_KEY_COMPONENT,
|
|
11
|
+
slot: TagsFormatterSlots.tag
|
|
12
|
+
})(tagsFormatterStyles.tag);
|
|
13
|
+
export {
|
|
14
|
+
TagsContainerStyled as T,
|
|
15
|
+
TagStyled as a
|
|
16
|
+
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useMemo } from "react";
|
|
3
|
+
import { v as validateHexColor } from "../../helpers/validateHexColor.js";
|
|
4
|
+
import { a as TagStyled } from "../../slots/TagsFormatterSlots.js";
|
|
5
|
+
import clsx from "clsx";
|
|
6
|
+
import { a as TAGS_FORMATTER_CLASSES } from "../../constants.js";
|
|
7
|
+
import { u as useComponentSize } from "../../../../../hooks/useComponentSize/useComponentSize.js";
|
|
8
|
+
const Tag = (props) => {
|
|
9
|
+
const { label, backgroundColor, size, className } = props;
|
|
10
|
+
const { currentSize } = useComponentSize(size);
|
|
11
|
+
const ownerState = useMemo(
|
|
12
|
+
() => ({
|
|
13
|
+
size: currentSize,
|
|
14
|
+
backgroundColor
|
|
15
|
+
}),
|
|
16
|
+
[currentSize, backgroundColor]
|
|
17
|
+
);
|
|
18
|
+
if (!validateHexColor(backgroundColor)) {
|
|
19
|
+
console.error(
|
|
20
|
+
`Color no válido: "${backgroundColor}". Color debe ser un color hexadecimal.`
|
|
21
|
+
);
|
|
22
|
+
return null;
|
|
23
|
+
}
|
|
24
|
+
return /* @__PURE__ */ jsx(
|
|
25
|
+
TagStyled,
|
|
26
|
+
{
|
|
27
|
+
ownerState,
|
|
28
|
+
className: clsx(className, TAGS_FORMATTER_CLASSES.root),
|
|
29
|
+
children: label
|
|
30
|
+
}
|
|
31
|
+
);
|
|
32
|
+
};
|
|
33
|
+
export {
|
|
34
|
+
Tag as T
|
|
35
|
+
};
|
|
File without changes
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { Maybe } from '@m4l/core';
|
|
2
|
+
import { Sizes } from '@m4l/styles';
|
|
3
|
+
import { M4LOverridesStyleRules } from '../../../@types/augmentations';
|
|
4
|
+
import { Theme } from '@mui/material';
|
|
5
|
+
import { TAGS_FORMATTER_KEY_COMPONENT } from './constants';
|
|
6
|
+
import { TagsFormatterSlots } from './slots/TagsFormatterEnum';
|
|
7
|
+
/**
|
|
8
|
+
* Props de configuración de un tag
|
|
9
|
+
*/
|
|
10
|
+
export interface TagConfig {
|
|
11
|
+
key?: number | string;
|
|
12
|
+
label: string;
|
|
13
|
+
backgroundColor: string;
|
|
14
|
+
size?: Extract<Sizes, 'small' | 'medium'>;
|
|
15
|
+
className?: string;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Props del TagFormatter
|
|
19
|
+
*/
|
|
20
|
+
export interface TagsFormatterProps {
|
|
21
|
+
tags: Maybe<TagConfig | TagConfig[]>;
|
|
22
|
+
className?: string;
|
|
23
|
+
dataTestId?: string;
|
|
24
|
+
size?: Extract<Sizes, 'small' | 'medium'>;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Props del renderTag
|
|
28
|
+
*/
|
|
29
|
+
export interface RenderTagProps {
|
|
30
|
+
tag: TagConfig;
|
|
31
|
+
size?: Extract<Sizes, 'small' | 'medium'>;
|
|
32
|
+
className?: string;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Owner state del TagFormatter
|
|
36
|
+
*/
|
|
37
|
+
export interface TagFormatterOwnerState extends Pick<TagConfig, 'size'> {
|
|
38
|
+
backgroundColor?: string;
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Tipos de slots disponibles para el TagFormatter
|
|
42
|
+
*/
|
|
43
|
+
export type TagsFormatterSlotsType = TagsFormatterSlots;
|
|
44
|
+
/**
|
|
45
|
+
* Estilos aplicables al TagFormatter
|
|
46
|
+
*/
|
|
47
|
+
export type TagsFormatterStyles = M4LOverridesStyleRules<TagsFormatterSlotsType, typeof TAGS_FORMATTER_KEY_COMPONENT, Theme>;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
export { BooleanFormatter } from './BooleanFormatter/BooleanFormatter';
|
|
2
2
|
export * from './ChipStatusFormatter';
|
|
3
3
|
export { getFormatDate, DateFormatter } from './DateFormatter/DateFormatter';
|
|
4
|
-
export { UncertaintyFormatter, getUncertaintyFormat } from './UncertaintyFormatter/UncertaintyFormatter';
|
|
5
|
-
export { PointsFormatter, getFormatPoints } from './PointsFormatter/PointsFormatter';
|
|
6
|
-
export { getFormatConcatenated, ConcatenatedFormatter } from './ConcatenatedFormatter/ConcatenatedFormatter';
|
|
7
|
-
export { useFormatPeriod, PeriodFormatter } from './PeriodFormatter/PeriodFormatter';
|
|
8
|
-
export { PriceFormatter, getFormatPrice } from './PriceFormatter/PriceFormatter';
|
|
4
|
+
export { UncertaintyFormatter, getUncertaintyFormat, } from './UncertaintyFormatter/UncertaintyFormatter';
|
|
5
|
+
export { PointsFormatter, getFormatPoints, } from './PointsFormatter/PointsFormatter';
|
|
6
|
+
export { getFormatConcatenated, ConcatenatedFormatter, } from './ConcatenatedFormatter/ConcatenatedFormatter';
|
|
7
|
+
export { useFormatPeriod, PeriodFormatter, } from './PeriodFormatter/PeriodFormatter';
|
|
8
|
+
export { PriceFormatter, getFormatPrice, } from './PriceFormatter/PriceFormatter';
|
|
9
9
|
export * from './DistanceToNowFormatter';
|
|
10
10
|
export type { UncertaintyRange } from './UncertaintyFormatter/types';
|
|
11
|
+
export { TagsFormatter } from './TagsFormatter';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import { createContext, useState } from "react";
|
|
2
|
+
import { createContext, useState, useCallback } from "react";
|
|
3
3
|
import { M as ModalDialog } from "../../components/ModalDialog/ModalDialog.js";
|
|
4
4
|
const ModalContext = createContext(null);
|
|
5
5
|
function ModalProvider({ children }) {
|
|
@@ -7,7 +7,7 @@ function ModalProvider({ children }) {
|
|
|
7
7
|
open: false,
|
|
8
8
|
fullScreen: false
|
|
9
9
|
});
|
|
10
|
-
const openModal = (modalOpenProps) => {
|
|
10
|
+
const openModal = useCallback((modalOpenProps) => {
|
|
11
11
|
setModalOptions({
|
|
12
12
|
open: true,
|
|
13
13
|
initialWidth: 300,
|
|
@@ -15,10 +15,10 @@ function ModalProvider({ children }) {
|
|
|
15
15
|
...modalOpenProps,
|
|
16
16
|
isCloseable: modalOpenProps.isCloseable
|
|
17
17
|
});
|
|
18
|
-
};
|
|
19
|
-
const closeModal = () => {
|
|
18
|
+
}, []);
|
|
19
|
+
const closeModal = useCallback(() => {
|
|
20
20
|
setModalOptions((last) => ({ ...last, open: false }));
|
|
21
|
-
};
|
|
21
|
+
}, []);
|
|
22
22
|
return /* @__PURE__ */ jsxs(
|
|
23
23
|
ModalContext.Provider,
|
|
24
24
|
{
|
package/index.js
CHANGED
|
@@ -57,6 +57,8 @@ import { C as C13 } from "./components/DataGrid/formatters/ColumnUncertaintyForm
|
|
|
57
57
|
import { u as u10 } from "./components/DataGrid/formatters/ColumnUncertaintyFormatter/useColumnUncertainty.js";
|
|
58
58
|
import { C as C14 } from "./components/DataGrid/formatters/ColumnChipStatusFormatter/formatter.js";
|
|
59
59
|
import { u as u11 } from "./components/DataGrid/formatters/ColumnChipStatusFormatter/useColumnChipStatus.js";
|
|
60
|
+
import { C as C15 } from "./components/DataGrid/formatters/ColumnTagsFormatter/formatter.js";
|
|
61
|
+
import { u as u12 } from "./components/DataGrid/formatters/ColumnTagsFormatter/useColumnTags.js";
|
|
60
62
|
import { D as D3 } from "./components/DragResizeWindowRND/DragResizeWindowRND.js";
|
|
61
63
|
import { d as d2 } from "./components/DragResizeWindowRND/classes/index.js";
|
|
62
64
|
import { W } from "./components/DragResizeWindowRND/constants.js";
|
|
@@ -78,7 +80,7 @@ import { R as R3 } from "./components/extended/React-Json-Viewer/ReactJsonViewer
|
|
|
78
80
|
import { A as A14 } from "./components/mui_extended/Avatar/Avatar.js";
|
|
79
81
|
import { B as B2 } from "./components/mui_extended/BoxIcon/index.js";
|
|
80
82
|
import { B as B3 } from "./components/mui_extended/Breadcrumbs/index.js";
|
|
81
|
-
import { C as
|
|
83
|
+
import { C as C16 } from "./components/mui_extended/CircularProgress/CircularProgress.js";
|
|
82
84
|
import { B as B4 } from "./components/mui_extended/Badge/Badge.js";
|
|
83
85
|
import { L as L3 } from "./components/mui_extended/LinearProgress/index.js";
|
|
84
86
|
import { L as L4 } from "./components/mui_extended/LinkWithRoute/index.js";
|
|
@@ -88,7 +90,7 @@ import { A as A15 } from "./components/mui_extended/Accordion/Accordion.js";
|
|
|
88
90
|
import { T as T3 } from "./components/mui_extended/Tooltip/Tooltip.js";
|
|
89
91
|
import { I as I2 } from "./components/mui_extended/IconButton/IconButton.js";
|
|
90
92
|
import { B as B5 } from "./components/mui_extended/Button/Button.js";
|
|
91
|
-
import { C as
|
|
93
|
+
import { C as C17 } from "./components/mui_extended/CheckBox/CheckBox.js";
|
|
92
94
|
import { I as I3 } from "./components/mui_extended/ImageButton/ImageButton.js";
|
|
93
95
|
import { P as P2 } from "./components/mui_extended/Popover/Popover.js";
|
|
94
96
|
import { S as S4 } from "./components/mui_extended/Select/Select.js";
|
|
@@ -116,13 +118,14 @@ import { B as B6 } from "./components/formatters/BooleanFormatter/BooleanFormatt
|
|
|
116
118
|
import { D as D8, g as g12 } from "./components/formatters/DateFormatter/DateFormatter.js";
|
|
117
119
|
import { U, g as g13 } from "./components/formatters/UncertaintyFormatter/UncertaintyFormatter.js";
|
|
118
120
|
import { P as P3, g as g14 } from "./components/formatters/PointsFormatter/PointsFormatter.js";
|
|
119
|
-
import { C as
|
|
120
|
-
import { P as P4, u as
|
|
121
|
+
import { C as C18, g as g15 } from "./components/formatters/ConcatenatedFormatter/ConcatenatedFormatter.js";
|
|
122
|
+
import { P as P4, u as u13 } from "./components/formatters/PeriodFormatter/PeriodFormatter.js";
|
|
121
123
|
import { P as P5, g as g16 } from "./components/formatters/PriceFormatter/PriceFormatter.js";
|
|
122
|
-
import {
|
|
124
|
+
import { T as T17 } from "./components/formatters/TagsFormatter/TagsFormatter.js";
|
|
125
|
+
import { C as C19 } from "./components/formatters/ChipStatusFormatter/ChipStatusFormatter.js";
|
|
123
126
|
import { g as g17 } from "./components/formatters/DistanceToNowFormatter/dictionary.js";
|
|
124
127
|
import { D as D9 } from "./components/formatters/DistanceToNowFormatter/DistanceToNowFormatter.js";
|
|
125
|
-
import { u as
|
|
128
|
+
import { u as u14 } from "./components/formatters/DistanceToNowFormatter/hooks/useDistanceToNowFormatter.js";
|
|
126
129
|
import { g as g18 } from "./components/formatters/dictionary.js";
|
|
127
130
|
import { F as F2 } from "./components/FormContainer/FormContainer.js";
|
|
128
131
|
import { G } from "./components/GridLayout/GridLayout.js";
|
|
@@ -176,18 +179,18 @@ import { g as g27 } from "./components/ObjectLogs/dictionary.js";
|
|
|
176
179
|
import { O } from "./components/ObjectLogs/ObjectLogs.js";
|
|
177
180
|
import { P as P7 } from "./components/PaperForm/PaperForm.js";
|
|
178
181
|
import { P as P8 } from "./components/PDFViewer/PDFViewer.js";
|
|
179
|
-
import { u as
|
|
182
|
+
import { u as u15 } from "./components/popups/components/PopupsProvider/hooks/usePopupsStore.js";
|
|
180
183
|
import { a as a10, P as P9 } from "./components/popups/components/PopupsProvider/contexts/PopupsContext/PopupsContext.js";
|
|
181
184
|
import { P as P10 } from "./components/popups/components/PopupsViewer/PopupsViewer.js";
|
|
182
185
|
import { P as P11 } from "./components/PrintingSystem/PrintingSystem.js";
|
|
183
186
|
import { P as P12 } from "./components/PropertyValue/PropertyValue.js";
|
|
184
187
|
import { S as S8 } from "./components/ScrollBar/ScrollBar.js";
|
|
185
188
|
import { S as S9 } from "./components/SideBar/SideBar.js";
|
|
186
|
-
import { T as
|
|
187
|
-
import { T as
|
|
189
|
+
import { T as T18 } from "./components/ToastContainer/ToastContainer.js";
|
|
190
|
+
import { T as T19 } from "./components/ToastContainer/subcomponents/ToastMessage/ToastMessage.js";
|
|
188
191
|
import { W as W2 } from "./components/WindowBase/WindowBase.js";
|
|
189
|
-
import { u as
|
|
190
|
-
import { u as
|
|
192
|
+
import { u as u16 } from "./components/WindowBase/hooks/useWindowToolsMF/index.js";
|
|
193
|
+
import { u as u17, a as a11 } from "./components/WindowBase/hooks/useDynamicMFParameters/index.js";
|
|
191
194
|
import { M as M6, W as W3, a as a12 } from "./components/WindowBase/contexts/WindowToolsMFContext/WindowToolsMFContext.js";
|
|
192
195
|
import { c as c3 } from "./components/WindowBase/contexts/DynamicMFParmsContext/store.js";
|
|
193
196
|
import { D as D10, a as a13, M as M7 } from "./components/WindowBase/contexts/DynamicMFParmsContext/DynamicMFParmsContext.js";
|
|
@@ -196,7 +199,7 @@ import { a as a14, g as g28 } from "./components/ModalDialog/dictionary.js";
|
|
|
196
199
|
import { M as M8 } from "./components/ModalDialog/ModalDialog.js";
|
|
197
200
|
import { S as S10 } from "./components/SettingsLayout/SettingsLayout.js";
|
|
198
201
|
import { P as P13 } from "./components/Pager/Pager.js";
|
|
199
|
-
import { u as
|
|
202
|
+
import { u as u18 } from "./components/Stepper/hooks/useStepper/index.js";
|
|
200
203
|
import { S as S11 } from "./components/Stepper/Stepper.js";
|
|
201
204
|
import { S as S12 } from "./components/Stepper/subcomponents/StepperContent/index.js";
|
|
202
205
|
import { S as S13 } from "./components/Stepper/subcomponents/StepperContent/subcomponents/Step/index.js";
|
|
@@ -209,27 +212,27 @@ import { S as S19 } from "./components/Stepper/subcomponents/StepperButtons/Step
|
|
|
209
212
|
import { S as S20 } from "./components/Stepper/subcomponents/StepperButtons/StepperSubmitButton/index.js";
|
|
210
213
|
import { e as e2 } from "./components/Stepper/helpers/evaluateVisibilityStepCondition/index.js";
|
|
211
214
|
import { g as g29 } from "./components/Stepper/dictionary.js";
|
|
212
|
-
import { F as F3, R as R23, u as
|
|
215
|
+
import { F as F3, R as R23, u as u19 } from "./components/hook-form/RHFormContext/index.js";
|
|
213
216
|
import { g as g30 } from "./components/hook-form/RHFormContext/dictionary.js";
|
|
214
|
-
import { u as
|
|
217
|
+
import { u as u20 } from "./contexts/AppearanceComponentContext/useAppearanceComponentStore.js";
|
|
215
218
|
import { A as A16 } from "./contexts/AppearanceComponentContext/AppearanceComponentContext.js";
|
|
216
219
|
import { a as a15, M as M9 } from "./contexts/ModalContext/index.js";
|
|
217
|
-
import { u as
|
|
218
|
-
import { u as
|
|
219
|
-
import { u as
|
|
220
|
+
import { u as u21 } from "./hooks/useFormAddEdit/index.js";
|
|
221
|
+
import { u as u22 } from "./hooks/useModal/index.js";
|
|
222
|
+
import { u as u23 } from "./hooks/useTab/index.js";
|
|
220
223
|
import { g as g31 } from "./hooks/useFormAddEdit/dictionary.js";
|
|
221
|
-
import { u as
|
|
222
|
-
import { u as
|
|
223
|
-
import { u as
|
|
224
|
-
import { u as
|
|
225
|
-
import { u as
|
|
224
|
+
import { u as u24 } from "./hooks/useFormFocus/index.js";
|
|
225
|
+
import { u as u25 } from "./hooks/useInterval/index.js";
|
|
226
|
+
import { u as u26 } from "./hooks/useComponentSize/useComponentSize.js";
|
|
227
|
+
import { u as u27 } from "./hooks/useFormReadyForUpdate/index.js";
|
|
228
|
+
import { u as u28 } from "./hooks/useStateRef/index.js";
|
|
226
229
|
import { S as S21 } from "./hooks/useSvgColor/constants.js";
|
|
227
|
-
import { u as
|
|
228
|
-
import { u as
|
|
229
|
-
import { u as
|
|
230
|
-
import { u as
|
|
231
|
-
import { u as
|
|
232
|
-
import { u as
|
|
230
|
+
import { u as u29 } from "./hooks/useSvgColor/useSvgColor.js";
|
|
231
|
+
import { u as u30 } from "./hooks/useDynamicFilterAndSort/useDynamicFilterAndSort.js";
|
|
232
|
+
import { u as u31 } from "./hooks/useDataGridPersistence/useDataGridPersistence.js";
|
|
233
|
+
import { u as u32 } from "./hooks/usePopoverContainer/usePopoverContainer.js";
|
|
234
|
+
import { u as u33 } from "./hooks/useIsVisible/useIsVisible.js";
|
|
235
|
+
import { u as u34 } from "./hooks/useSizeContainer/index.js";
|
|
233
236
|
import { c as c4 } from "./utils/capitalizeFirstLetter.js";
|
|
234
237
|
import { i as i2 } from "./utils/isValidDate.js";
|
|
235
238
|
import { g as g32 } from "./utils/getComponentUtilityClass.js";
|
|
@@ -270,10 +273,10 @@ export {
|
|
|
270
273
|
B3 as Breadcrumbs,
|
|
271
274
|
B5 as Button,
|
|
272
275
|
C as Card,
|
|
273
|
-
|
|
276
|
+
C17 as CheckBox,
|
|
274
277
|
C2 as Chip,
|
|
275
|
-
|
|
276
|
-
|
|
278
|
+
C19 as ChipStatusFormatter,
|
|
279
|
+
C16 as CircularProgress,
|
|
277
280
|
C4 as ColumnBooleanFormatter,
|
|
278
281
|
C14 as ColumnChipStatusFormatter,
|
|
279
282
|
C5 as ColumnConcatenatedValueFormatter,
|
|
@@ -284,8 +287,9 @@ export {
|
|
|
284
287
|
C10 as ColumnPointsFormatter,
|
|
285
288
|
C11 as ColumnPriceFormatter,
|
|
286
289
|
C12 as ColumnSetCheckFormatter,
|
|
290
|
+
C15 as ColumnTagsFormatter,
|
|
287
291
|
C13 as ColumnUncertaintyFormatter,
|
|
288
|
-
|
|
292
|
+
C18 as ConcatenatedFormatter,
|
|
289
293
|
C3 as ContainerFlow,
|
|
290
294
|
b3 as DATAGRID_ROW_HEADER_HEIGHTS,
|
|
291
295
|
a4 as DATAGRID_ROW_HEIGHTS,
|
|
@@ -408,9 +412,10 @@ export {
|
|
|
408
412
|
T7 as TabContext,
|
|
409
413
|
a7 as TabProvider,
|
|
410
414
|
T5 as Tabs,
|
|
415
|
+
T17 as TagsFormatter,
|
|
411
416
|
T2 as TextEditor,
|
|
412
|
-
|
|
413
|
-
|
|
417
|
+
T18 as ToastContainer,
|
|
418
|
+
T19 as ToastMessage,
|
|
414
419
|
T9 as ToggleButton,
|
|
415
420
|
T12 as ToggleButtonRootStyled,
|
|
416
421
|
T11 as ToggleButtonSlots,
|
|
@@ -491,7 +496,7 @@ export {
|
|
|
491
496
|
r as rhfPeriodStyles,
|
|
492
497
|
t as toggleButtonStyles,
|
|
493
498
|
t2 as toggleIconButtonStyles,
|
|
494
|
-
|
|
499
|
+
u20 as useAppearanceComponentStore,
|
|
495
500
|
u as useAreasStore,
|
|
496
501
|
u2 as useColumnBoolean,
|
|
497
502
|
u11 as useColumnChipStatus,
|
|
@@ -502,29 +507,30 @@ export {
|
|
|
502
507
|
u7 as useColumnPoints,
|
|
503
508
|
u8 as useColumnPrice,
|
|
504
509
|
u9 as useColumnSetCheck,
|
|
510
|
+
u12 as useColumnTags,
|
|
505
511
|
u10 as useColumnUncertanity,
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
+
u26 as useComponentSize,
|
|
513
|
+
u19 as useCustomForm,
|
|
514
|
+
u31 as useDataGridPersistence,
|
|
515
|
+
u14 as useDistanceToNowFormatter,
|
|
516
|
+
u30 as useDynamicFilterAndSort,
|
|
517
|
+
u17 as useDynamicMFParameters,
|
|
512
518
|
a11 as useDynamicMFParametersStore,
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
519
|
+
u21 as useFormAddEdit,
|
|
520
|
+
u24 as useFormFocus,
|
|
521
|
+
u27 as useFormReadyForUpdate,
|
|
522
|
+
u13 as useFormatPeriod,
|
|
523
|
+
u25 as useInterval,
|
|
524
|
+
u33 as useIsVisible,
|
|
525
|
+
u22 as useModal,
|
|
526
|
+
u32 as usePopoverContainer,
|
|
527
|
+
u15 as usePopupsStore,
|
|
528
|
+
u34 as useSizeContainer,
|
|
529
|
+
u28 as useStateRef,
|
|
530
|
+
u18 as useStepper,
|
|
531
|
+
u29 as useSvgColor,
|
|
532
|
+
u23 as useTab,
|
|
533
|
+
u16 as useWindowToolsMF,
|
|
528
534
|
v2 as varBounce,
|
|
529
535
|
v3 as varContainer,
|
|
530
536
|
v as varFade,
|
package/package.json
CHANGED
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
import { jsx, Fragment } from "react/jsx-runtime";
|
|
2
|
-
import React from "react";
|
|
3
|
-
import { C as COLUMN_ICON_KEY_COMPONENT } from "../constants.js";
|
|
4
|
-
import { g as getPropDataTestId } from "../../../../../test/getNameDataTestId.js";
|
|
5
|
-
import { I as IconClickeableStyled, a as IconStyled } from "../../../../ObjectLogs/slots/ObjectLogsSlots.js";
|
|
6
|
-
function renderIcon(iconConfig, key) {
|
|
7
|
-
const {
|
|
8
|
-
iconUrl,
|
|
9
|
-
onClick,
|
|
10
|
-
tooltip,
|
|
11
|
-
dataTestId,
|
|
12
|
-
Component,
|
|
13
|
-
componentProps,
|
|
14
|
-
color,
|
|
15
|
-
visible,
|
|
16
|
-
size
|
|
17
|
-
} = iconConfig;
|
|
18
|
-
if (visible === false) {
|
|
19
|
-
return /* @__PURE__ */ jsx(Fragment, { children: "-" });
|
|
20
|
-
}
|
|
21
|
-
const IconComponent = onClick ? IconClickeableStyled : IconStyled;
|
|
22
|
-
if (Component && Component !== React.Fragment) {
|
|
23
|
-
return /* @__PURE__ */ jsx(
|
|
24
|
-
Component,
|
|
25
|
-
{
|
|
26
|
-
...componentProps,
|
|
27
|
-
...getPropDataTestId(COLUMN_ICON_KEY_COMPONENT, "container", dataTestId),
|
|
28
|
-
children: /* @__PURE__ */ jsx(
|
|
29
|
-
IconComponent,
|
|
30
|
-
{
|
|
31
|
-
src: iconUrl,
|
|
32
|
-
...onClick && { onClick },
|
|
33
|
-
tooltipContent: tooltip,
|
|
34
|
-
instaceDataTestId: dataTestId,
|
|
35
|
-
color,
|
|
36
|
-
size
|
|
37
|
-
}
|
|
38
|
-
)
|
|
39
|
-
},
|
|
40
|
-
key
|
|
41
|
-
);
|
|
42
|
-
}
|
|
43
|
-
return /* @__PURE__ */ jsx(
|
|
44
|
-
IconComponent,
|
|
45
|
-
{
|
|
46
|
-
src: iconUrl,
|
|
47
|
-
...onClick && { onClick },
|
|
48
|
-
tooltipContent: tooltip,
|
|
49
|
-
instaceDataTestId: dataTestId,
|
|
50
|
-
color,
|
|
51
|
-
size
|
|
52
|
-
},
|
|
53
|
-
key
|
|
54
|
-
);
|
|
55
|
-
}
|
|
56
|
-
export {
|
|
57
|
-
renderIcon as r
|
|
58
|
-
};
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { ColumnIconResponse } from '../types';
|
|
2
|
-
/**
|
|
3
|
-
* Helper que renderiza múltiples iconos
|
|
4
|
-
* @param iconsConfig - Array de configuraciones de iconos
|
|
5
|
-
* @returns Componente contenedor con múltiples iconos
|
|
6
|
-
*/
|
|
7
|
-
export declare function renderMultipleIcons(iconsConfig: ColumnIconResponse[]): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { jsx, Fragment } from "react/jsx-runtime";
|
|
2
|
-
import { a as ColumnIconFormatterStyled } from "../../../slots/DataGridSlot.js";
|
|
3
|
-
import { r as renderIcon } from "./renderIcon.js";
|
|
4
|
-
function renderMultipleIcons(iconsConfig) {
|
|
5
|
-
if (!iconsConfig || iconsConfig.length === 0) {
|
|
6
|
-
return /* @__PURE__ */ jsx(Fragment, { children: "-" });
|
|
7
|
-
}
|
|
8
|
-
const visibleIcons = iconsConfig.filter((icon) => icon.visible !== false);
|
|
9
|
-
if (visibleIcons.length === 0) {
|
|
10
|
-
return /* @__PURE__ */ jsx(Fragment, { children: "-" });
|
|
11
|
-
}
|
|
12
|
-
if (visibleIcons.length === 1) {
|
|
13
|
-
return renderIcon(visibleIcons[0]);
|
|
14
|
-
}
|
|
15
|
-
return /* @__PURE__ */ jsx(ColumnIconFormatterStyled, { children: visibleIcons.map((iconConfig, index) => renderIcon(iconConfig, index)) });
|
|
16
|
-
}
|
|
17
|
-
export {
|
|
18
|
-
renderMultipleIcons as r
|
|
19
|
-
};
|