@m4l/components 9.3.21-JAEBeta.2 → 9.3.21-JT20102025.beta.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/components/DataGrid/DataGrid.js +9 -4
- package/components/DataGrid/Datagrid.styles.js +270 -0
- package/components/DataGrid/constants.js +2 -2
- package/components/DataGrid/contexts/DataGridContext/index.js +317 -112
- package/components/DataGrid/contexts/DataGridContext/types.d.ts +63 -4
- package/components/DataGrid/dictionary.d.ts +5 -0
- package/components/DataGrid/dictionary.js +6 -1
- package/components/DataGrid/formatters/ColumnSetCheckFormatter/formatter.js +2 -2
- package/components/DataGrid/hooks/useModalCardDetail.d.ts +6 -0
- package/components/DataGrid/hooks/useModalCardDetail.js +74 -0
- package/components/DataGrid/hooks/useProcessedColumns.d.ts +50 -0
- package/components/DataGrid/hooks/useProcessedColumns.js +44 -0
- package/components/DataGrid/icons.d.ts +7 -0
- package/components/DataGrid/icons.js +5 -1
- package/components/DataGrid/index.d.ts +1 -1
- package/components/DataGrid/slots/DataGridEnum.d.ts +22 -1
- package/components/DataGrid/slots/DataGridEnum.js +21 -0
- package/components/DataGrid/slots/DataGridSlot.d.ts +24 -0
- package/components/DataGrid/slots/DataGridSlot.js +123 -21
- package/components/DataGrid/subcomponents/Cards/hooks/useCardContent.d.ts +9 -0
- package/components/DataGrid/subcomponents/Cards/hooks/useCardContent.js +91 -0
- package/components/DataGrid/subcomponents/Cards/index.d.ts +5 -0
- package/components/DataGrid/subcomponents/Cards/index.js +40 -0
- package/components/DataGrid/subcomponents/Cards/subcomponents/CardDetails/index.d.ts +8 -0
- package/components/DataGrid/subcomponents/Cards/subcomponents/CardDetails/index.js +79 -0
- package/components/DataGrid/subcomponents/Cards/subcomponents/CardHeader/index.d.ts +7 -0
- package/components/DataGrid/subcomponents/Cards/subcomponents/CardHeader/index.js +98 -0
- package/components/DataGrid/subcomponents/Cards/subcomponents/CardRow/index.d.ts +6 -0
- package/components/DataGrid/subcomponents/Cards/subcomponents/CardRow/index.js +71 -0
- package/components/DataGrid/subcomponents/Cards/subcomponents/IntersectCard/index.d.ts +20 -0
- package/components/DataGrid/subcomponents/Cards/subcomponents/IntersectCard/index.js +46 -0
- package/components/DataGrid/subcomponents/Cards/subcomponents/LazyLoadCard/index.d.ts +17 -0
- package/components/DataGrid/subcomponents/Cards/subcomponents/LazyLoadCard/index.js +34 -0
- package/components/DataGrid/subcomponents/Cards/types.d.ts +118 -0
- package/components/DataGrid/subcomponents/CheckboxCellAdapter/index.d.ts +7 -0
- package/components/DataGrid/subcomponents/CheckboxCellAdapter/index.js +43 -0
- package/components/DataGrid/subcomponents/CheckboxCellAdapter/types.d.ts +7 -0
- package/components/DataGrid/subcomponents/ControlNavigate/ControlNavigate.js +1 -1
- package/components/DataGrid/subcomponents/HeaderActions/index.js +5 -3
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/RowsCount/index.js +1 -1
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/Settings/index.js +11 -2
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/Settings/subcomponents/ColumnsConfig/index.js +1 -1
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/Settings/subcomponents/ColumnsConfigCards/index.d.ts +2 -0
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/Settings/subcomponents/ColumnsConfigCards/index.js +304 -0
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/Settings/subcomponents/ColumnsConfigCards/types.d.ts +31 -0
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/ViewMode/index.d.ts +4 -0
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/ViewMode/index.js +125 -0
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/hooks/useModalSettings/index.js +2 -2
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/hooks/useModalSettingsCards/index.d.ts +7 -0
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/hooks/useModalSettingsCards/index.js +74 -0
- package/components/DataGrid/subcomponents/HeaderActions/subcomponents/hooks/useModalSettingsCards/types.d.ts +4 -0
- package/components/DataGrid/subcomponents/RenderContent/index.d.ts +5 -0
- package/components/DataGrid/subcomponents/RenderContent/index.js +11 -0
- package/components/DataGrid/subcomponents/Table/hooks/useHeaderMenuActions.js +2 -2
- package/components/DataGrid/subcomponents/Table/hooks/useSortColumnsRows.js +1 -1
- package/components/DataGrid/subcomponents/Table/index.js +1 -1
- package/components/DataGrid/subcomponents/Table/subcomponents/ActionsColumn.js +1 -1
- package/components/DataGrid/subcomponents/Table/subcomponents/DraggableHeaderRenderer.js +1 -1
- 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/components/CardDetails.test.d.ts +1 -0
- package/components/DataGrid/tests/components/CardHeader.test.d.ts +1 -0
- package/components/DataGrid/tests/components/CardRow.test.d.ts +1 -0
- package/components/DataGrid/tests/components/Cards.test.d.ts +1 -0
- package/components/DataGrid/tests/components/CheckboxCellAdapter.test.d.ts +1 -0
- package/components/DataGrid/tests/components/ColumnsConfigCards.test.d.ts +1 -0
- package/components/DataGrid/tests/components/IntersectCard.test.d.ts +1 -0
- package/components/DataGrid/tests/components/ViewMode.test.d.ts +1 -0
- package/components/DataGrid/tests/helpers/useCardsViewConfig.d.ts +24 -0
- package/components/DataGrid/tests/helpers/useCustomCardExample.d.ts +7 -0
- package/components/DataGrid/tests/hooks/useCardContent.test.d.ts +1 -0
- package/components/DataGrid/tests/hooks/useModalDetail.test.d.ts +1 -0
- package/components/DataGrid/tests/hooks/useModalSettingsCards.test.d.ts +1 -0
- package/components/DataGrid/tests/hooks/useProcessedColumns.test.d.ts +1 -0
- package/components/DataGrid/types.d.ts +86 -5
- package/components/MFIsolationAppStorybook/MFIsolationAppStorybook.d.ts +5 -0
- package/components/MFIsolationAppStorybook/constants.d.ts +1 -0
- package/components/MFIsolationAppStorybook/icons.d.ts +3 -0
- package/components/MFIsolationAppStorybook/index.d.ts +1 -0
- package/components/MFIsolationAppStorybook/subcomponents/AppBarSettings/AppBarSettings.d.ts +4 -0
- package/components/MFIsolationAppStorybook/subcomponents/AppBarSettings/index.d.ts +1 -0
- package/components/MFIsolationAppStorybook/subcomponents/MFAuthAppStorybook/MFAuthAppStorybook.d.ts +5 -0
- package/components/MFIsolationAppStorybook/subcomponents/MFAuthAppStorybook/index.d.ts +1 -0
- package/components/MFIsolationAppStorybook/subcomponents/MFAuthAppStorybook/types.d.ts +4 -0
- package/components/MFIsolationAppStorybook/types.d.ts +31 -0
- package/components/MenuActions/MenuActions.js +105 -55
- package/components/areas/contexts/AreasContext/store.js +2 -2
- package/components/hook-form/RHFormContext/index.d.ts +1 -1
- package/hooks/useDataGridPersistence/helpers.d.ts +2 -2
- package/hooks/useDataGridPersistence/useDataGridPersistence.d.ts +2 -2
- package/hooks/useDataGridPersistence/useDataGridPersistence.js +5 -0
- package/index.js +8 -8
- package/package.json +1 -1
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { T as Table } from "./subcomponents/Table/index.js";
|
|
3
2
|
import { H as HeaderActions } from "./subcomponents/HeaderActions/index.js";
|
|
4
3
|
import { F as FilterProvider } from "./contexts/FilterContext/index.js";
|
|
5
4
|
import { D as DataGridProvider } from "./contexts/DataGridContext/index.js";
|
|
@@ -12,6 +11,7 @@ import { a as getComponentSlotRoot } from "../../utils/getComponentSlotRoot.js";
|
|
|
12
11
|
import { useRef } from "react";
|
|
13
12
|
import { C as ControlNavigate } from "./subcomponents/ControlNavigate/ControlNavigate.js";
|
|
14
13
|
import { useModuleSkeleton } from "@m4l/core";
|
|
14
|
+
import { R as RenderContent } from "./subcomponents/RenderContent/index.js";
|
|
15
15
|
import { u as useComponentSize } from "../../hooks/useComponentSize/useComponentSize.js";
|
|
16
16
|
function DataGrid(props) {
|
|
17
17
|
const {
|
|
@@ -37,7 +37,9 @@ function DataGrid(props) {
|
|
|
37
37
|
onChangeUserColumns,
|
|
38
38
|
size,
|
|
39
39
|
externalSortSettings,
|
|
40
|
-
externalFilterSettings
|
|
40
|
+
externalFilterSettings,
|
|
41
|
+
defaultViewMode,
|
|
42
|
+
cardsViewConfig
|
|
41
43
|
} = props;
|
|
42
44
|
const {
|
|
43
45
|
withSettings,
|
|
@@ -91,6 +93,8 @@ function DataGrid(props) {
|
|
|
91
93
|
size: currentSize,
|
|
92
94
|
externalSortSettings,
|
|
93
95
|
externalFilterSettings,
|
|
96
|
+
defaultViewMode,
|
|
97
|
+
cardsViewConfig,
|
|
94
98
|
children: /* @__PURE__ */ jsxs(FilterProvider, { initialActiveFilters: false, children: [
|
|
95
99
|
withActions && actionsProps && /* @__PURE__ */ jsx(
|
|
96
100
|
HeaderActions,
|
|
@@ -108,7 +112,7 @@ function DataGrid(props) {
|
|
|
108
112
|
),
|
|
109
113
|
CustomHeader ? /* @__PURE__ */ jsx(CustomHeaderStyled, { ownerState, children: CustomHeader }) : null,
|
|
110
114
|
/* @__PURE__ */ jsx(
|
|
111
|
-
|
|
115
|
+
RenderContent,
|
|
112
116
|
{
|
|
113
117
|
id,
|
|
114
118
|
withActions,
|
|
@@ -117,7 +121,8 @@ function DataGrid(props) {
|
|
|
117
121
|
selectedRows,
|
|
118
122
|
onSelectedRowsChange,
|
|
119
123
|
rowKeyGetter,
|
|
120
|
-
onRowsChange
|
|
124
|
+
onRowsChange,
|
|
125
|
+
cardsViewConfig
|
|
121
126
|
}
|
|
122
127
|
),
|
|
123
128
|
withPager && /* @__PURE__ */ jsx(
|
|
@@ -639,6 +639,276 @@ const dataGridStyles = {
|
|
|
639
639
|
}
|
|
640
640
|
};
|
|
641
641
|
},
|
|
642
|
+
/**
|
|
643
|
+
* Estilos para el wrapper del CheckboxCellAdapter
|
|
644
|
+
* Aplica los mismos estilos que los checkboxes dentro de celdas rdg
|
|
645
|
+
*/
|
|
646
|
+
checkboxCellWrapper: ({ theme, ownerState }) => ({
|
|
647
|
+
"& .checkbox-checked": {
|
|
648
|
+
"& path:first-of-type": {
|
|
649
|
+
fill: theme.vars.palette.primary.main
|
|
650
|
+
},
|
|
651
|
+
...getSizeStyles(theme, ownerState?.size || "medium", "base", (size) => ({
|
|
652
|
+
minHeight: size,
|
|
653
|
+
height: size
|
|
654
|
+
}))
|
|
655
|
+
},
|
|
656
|
+
"& .checkbox-unChecked": {
|
|
657
|
+
"& path": {
|
|
658
|
+
fill: theme.vars.palette.text.primary
|
|
659
|
+
},
|
|
660
|
+
...getSizeStyles(theme, ownerState?.size || "medium", "base", (size) => ({
|
|
661
|
+
minHeight: size,
|
|
662
|
+
height: size
|
|
663
|
+
}))
|
|
664
|
+
},
|
|
665
|
+
"& .MuiCheckbox-root": {
|
|
666
|
+
"& > svg": {
|
|
667
|
+
color: theme.vars.palette.text.secondary
|
|
668
|
+
}
|
|
669
|
+
}
|
|
670
|
+
}),
|
|
671
|
+
/**
|
|
672
|
+
* Contenedor de los cards
|
|
673
|
+
*/
|
|
674
|
+
containerToggleCards: ({ theme }) => ({
|
|
675
|
+
display: "grid",
|
|
676
|
+
gridTemplateColumns: "repeat(2, minmax(0, 1fr))",
|
|
677
|
+
gap: theme.vars.size.baseSpacings.sp3,
|
|
678
|
+
padding: theme.vars.size.baseSpacings.sp3
|
|
679
|
+
}),
|
|
680
|
+
/**
|
|
681
|
+
* Botón de toggle de cards
|
|
682
|
+
*/
|
|
683
|
+
cardToggleCardButton: ({ theme, ownerState }) => ({
|
|
684
|
+
display: "flex",
|
|
685
|
+
flexDirection: "column",
|
|
686
|
+
alignItems: "center",
|
|
687
|
+
cursor: "pointer",
|
|
688
|
+
height: theme.vars.size.baseSpacings.sp14,
|
|
689
|
+
width: theme.vars.size.baseSpacings.sp14,
|
|
690
|
+
gap: theme.vars.size.baseSpacings.sp2,
|
|
691
|
+
borderColor: ownerState?.isActive ? theme.vars.palette.primary.toneOpacity : theme.vars.palette.border.disabled
|
|
692
|
+
}),
|
|
693
|
+
/**
|
|
694
|
+
* Texto del botón de toggle de cards
|
|
695
|
+
*/
|
|
696
|
+
textToggleCardButton: ({ theme, ownerState }) => ({
|
|
697
|
+
"&.M4LTypography-root": {
|
|
698
|
+
color: ownerState?.isActive ? theme.vars.palette.primary.semanticText : theme.vars.palette.text.secondary,
|
|
699
|
+
cursor: "pointer"
|
|
700
|
+
}
|
|
701
|
+
}),
|
|
702
|
+
/**
|
|
703
|
+
* Contenedor de los cards
|
|
704
|
+
*/
|
|
705
|
+
cardsContainer: () => ({
|
|
706
|
+
height: "auto",
|
|
707
|
+
overflow: "auto"
|
|
708
|
+
}),
|
|
709
|
+
/**
|
|
710
|
+
* Card de la vista cards
|
|
711
|
+
*/
|
|
712
|
+
card: ({ theme, ownerState }) => ({
|
|
713
|
+
display: "flex",
|
|
714
|
+
flexDirection: "column",
|
|
715
|
+
alignItems: "start",
|
|
716
|
+
minWidth: "280px",
|
|
717
|
+
maxWidth: "580px",
|
|
718
|
+
cursor: "pointer",
|
|
719
|
+
// Si está checked (pero no selected), border de checked
|
|
720
|
+
...ownerState?.checked && !ownerState?.selected && {
|
|
721
|
+
borderColor: theme.vars.palette.primary.activeOpacity
|
|
722
|
+
},
|
|
723
|
+
// Si está selected, usar el color original del Card (primary.enabled)
|
|
724
|
+
// Este tiene prioridad sobre checked
|
|
725
|
+
...ownerState?.selected && {
|
|
726
|
+
borderColor: theme.vars.palette.primary.selected
|
|
727
|
+
}
|
|
728
|
+
}),
|
|
729
|
+
/**
|
|
730
|
+
* Header de la card con checkbox y acciones
|
|
731
|
+
*/
|
|
732
|
+
cardHeader: ({ theme }) => ({
|
|
733
|
+
display: "flex",
|
|
734
|
+
justifyContent: "space-between",
|
|
735
|
+
alignItems: "center",
|
|
736
|
+
width: "100%",
|
|
737
|
+
height: "24px",
|
|
738
|
+
gap: theme.vars.size.baseSpacings.sp2
|
|
739
|
+
}),
|
|
740
|
+
/**
|
|
741
|
+
* Lado izquierdo del header (checkbox)
|
|
742
|
+
*/
|
|
743
|
+
cardHeaderLeft: () => ({
|
|
744
|
+
display: "flex",
|
|
745
|
+
alignItems: "center"
|
|
746
|
+
}),
|
|
747
|
+
/**
|
|
748
|
+
* Lado derecho del header (botones de acción)
|
|
749
|
+
*/
|
|
750
|
+
cardHeaderRight: ({ theme }) => ({
|
|
751
|
+
display: "flex",
|
|
752
|
+
alignItems: "center",
|
|
753
|
+
gap: theme.vars.size.baseSpacings.sp1
|
|
754
|
+
}),
|
|
755
|
+
/**
|
|
756
|
+
* Contenedor de las columnas de la card
|
|
757
|
+
*/
|
|
758
|
+
containerLabelValueColumn: ({ theme, ownerState }) => ({
|
|
759
|
+
display: "flex",
|
|
760
|
+
flexDirection: ownerState?.hasActions ? "row" : "column",
|
|
761
|
+
justifyContent: ownerState?.hasActions ? "space-between" : "flex-start",
|
|
762
|
+
alignItems: ownerState?.hasActions ? "center" : "start",
|
|
763
|
+
gap: theme.vars.size.baseSpacings["sp0-5"],
|
|
764
|
+
width: ownerState?.hasActions ? "100%" : "auto"
|
|
765
|
+
}),
|
|
766
|
+
/**
|
|
767
|
+
* Contenedor del contenido de la columna
|
|
768
|
+
*/
|
|
769
|
+
contentWrapperColumn: ({ theme, ownerState }) => ({
|
|
770
|
+
flex: ownerState?.hasActions ? 1 : "none",
|
|
771
|
+
display: "flex",
|
|
772
|
+
flexDirection: "column",
|
|
773
|
+
alignItems: "start",
|
|
774
|
+
gap: theme.vars.size.baseSpacings["sp0-5"]
|
|
775
|
+
}),
|
|
776
|
+
/**
|
|
777
|
+
* Contenedor del detalle de la card
|
|
778
|
+
*/
|
|
779
|
+
cardDetailContainer: ({ theme }) => ({
|
|
780
|
+
display: "flex",
|
|
781
|
+
flexDirection: "column",
|
|
782
|
+
gap: theme.vars.size.baseSpacings.sp3,
|
|
783
|
+
padding: theme.vars.size.baseSpacings.sp3,
|
|
784
|
+
height: "100%",
|
|
785
|
+
overflow: "auto"
|
|
786
|
+
}),
|
|
787
|
+
/**
|
|
788
|
+
* Etiqueta de la columna
|
|
789
|
+
*/
|
|
790
|
+
labelHeaderColumn: () => ({}),
|
|
791
|
+
/**
|
|
792
|
+
* Valor de la columna
|
|
793
|
+
*/
|
|
794
|
+
valueColumn: () => ({}),
|
|
795
|
+
/**
|
|
796
|
+
* Contenedor del editor en la card
|
|
797
|
+
*/
|
|
798
|
+
editorCellWrapper: ({ theme, ownerState }) => ({
|
|
799
|
+
overflow: "clip",
|
|
800
|
+
outline: "none",
|
|
801
|
+
color: theme.vars.palette.text.primary,
|
|
802
|
+
paddingBlock: 0,
|
|
803
|
+
alignContent: "center",
|
|
804
|
+
backgroundColor: "inherit",
|
|
805
|
+
whiteSpace: "nowrap",
|
|
806
|
+
textOverflow: "ellipsis",
|
|
807
|
+
inlineSize: "100%",
|
|
808
|
+
alignSelf: "stretch",
|
|
809
|
+
boxSizing: "border-box",
|
|
810
|
+
...getTypographyStyles(
|
|
811
|
+
theme.generalSettings.isMobile,
|
|
812
|
+
ownerState?.size || "medium",
|
|
813
|
+
"body"
|
|
814
|
+
),
|
|
815
|
+
...getSizeStyles(theme, ownerState?.size || "medium", "base", (size) => ({
|
|
816
|
+
minHeight: size,
|
|
817
|
+
height: 24,
|
|
818
|
+
lineHeight: `${size} !important`
|
|
819
|
+
})),
|
|
820
|
+
"& input": {
|
|
821
|
+
width: "100%",
|
|
822
|
+
textAlign: "inherit",
|
|
823
|
+
color: theme.vars.palette.text.secondary,
|
|
824
|
+
padding: `${theme.vars.size.baseSpacings.sp0} ${theme.vars.size.baseSpacings.sp2}`,
|
|
825
|
+
border: theme.vars.size.baseSpacings.sp0,
|
|
826
|
+
borderTop: "0.5px solid",
|
|
827
|
+
borderBottom: theme.vars.size.borderStroke.container,
|
|
828
|
+
borderLeft: "0.5px solid",
|
|
829
|
+
borderRight: "0.5px solid",
|
|
830
|
+
borderColor: "transparent",
|
|
831
|
+
...theme.colorSchemes.finalTheme.typography.body,
|
|
832
|
+
"&:focus": {
|
|
833
|
+
borderTop: "0.5px solid",
|
|
834
|
+
borderBottom: theme.vars.size.borderStroke.container,
|
|
835
|
+
borderLeft: "0.5px solid",
|
|
836
|
+
borderRight: "0.5px solid",
|
|
837
|
+
borderColor: `${theme.vars.palette.primary.focusVisible} !important`,
|
|
838
|
+
outline: "none",
|
|
839
|
+
boxShadow: "none"
|
|
840
|
+
},
|
|
841
|
+
"&:hover": {
|
|
842
|
+
borderTop: "0.5px solid",
|
|
843
|
+
borderBottom: theme.vars.size.borderStroke.container,
|
|
844
|
+
borderLeft: "0.5px solid",
|
|
845
|
+
borderRight: "0.5px solid",
|
|
846
|
+
borderColor: "transparent",
|
|
847
|
+
outline: "none"
|
|
848
|
+
}
|
|
849
|
+
}
|
|
850
|
+
}),
|
|
851
|
+
/**
|
|
852
|
+
* Header de la card personalizada (avatar + nombre + email)
|
|
853
|
+
*/
|
|
854
|
+
customCardHeader: ({ theme }) => ({
|
|
855
|
+
display: "flex",
|
|
856
|
+
gap: theme.vars.size.baseSpacings.sp4,
|
|
857
|
+
alignItems: "center",
|
|
858
|
+
marginBottom: theme.vars.size.baseSpacings.sp2
|
|
859
|
+
}),
|
|
860
|
+
/**
|
|
861
|
+
* Avatar con iniciales
|
|
862
|
+
*/
|
|
863
|
+
customCardAvatar: ({ theme }) => ({
|
|
864
|
+
width: "32px",
|
|
865
|
+
height: "32px",
|
|
866
|
+
borderRadius: theme.vars.size.borderRadius.r3,
|
|
867
|
+
border: theme.vars.size.borderStroke.container,
|
|
868
|
+
borderColor: theme.vars.palette.primary.toneOpacity,
|
|
869
|
+
display: "flex",
|
|
870
|
+
alignItems: "center",
|
|
871
|
+
justifyContent: "center",
|
|
872
|
+
flexShrink: 0
|
|
873
|
+
}),
|
|
874
|
+
/**
|
|
875
|
+
* Contenedor del nombre y email
|
|
876
|
+
*/
|
|
877
|
+
customCardNameEmail: ({ theme }) => ({
|
|
878
|
+
display: "flex",
|
|
879
|
+
flexDirection: "column",
|
|
880
|
+
gap: theme.vars.size.baseSpacings["sp0-5"]
|
|
881
|
+
}),
|
|
882
|
+
/**
|
|
883
|
+
* Campo con icono (reutilizable para phone, IP, etc)
|
|
884
|
+
*/
|
|
885
|
+
customCardFieldWithIcon: ({ theme }) => ({
|
|
886
|
+
display: "flex",
|
|
887
|
+
alignItems: "center",
|
|
888
|
+
gap: theme.vars.size.baseSpacings.sp3
|
|
889
|
+
}),
|
|
890
|
+
/**
|
|
891
|
+
* Contenedor del contenido del campo (label + valor)
|
|
892
|
+
*/
|
|
893
|
+
customCardFieldContent: ({ theme }) => ({
|
|
894
|
+
display: "flex",
|
|
895
|
+
flexDirection: "column",
|
|
896
|
+
gap: theme.vars.size.baseSpacings["sp0-5"]
|
|
897
|
+
}),
|
|
898
|
+
/**
|
|
899
|
+
* Contenedor del icono con border
|
|
900
|
+
*/
|
|
901
|
+
customCardIconContainer: ({ theme }) => ({
|
|
902
|
+
width: "24px",
|
|
903
|
+
height: "24px",
|
|
904
|
+
display: "flex",
|
|
905
|
+
alignItems: "center",
|
|
906
|
+
justifyContent: "center",
|
|
907
|
+
borderRadius: theme.vars.size.borderRadius.r2,
|
|
908
|
+
border: theme.vars.size.borderStroke.container,
|
|
909
|
+
borderColor: theme.vars.palette.primary.toneOpacity,
|
|
910
|
+
flexShrink: 0
|
|
911
|
+
}),
|
|
642
912
|
/**
|
|
643
913
|
* Estilos para el header del componente
|
|
644
914
|
*/
|
|
@@ -35,7 +35,7 @@ export {
|
|
|
35
35
|
DATAGRID_ROW_HEADER_HEIGHTS as b,
|
|
36
36
|
DATAGRID_ID_DICTIONARY as c,
|
|
37
37
|
DATAGRID_SELECT_COLUMN_KEY as d,
|
|
38
|
-
|
|
39
|
-
|
|
38
|
+
DATAGRID_ACTIONS_COLUMN_KEY as e,
|
|
39
|
+
DATAGRID_SEMANTIC_WIDTHS as f,
|
|
40
40
|
DATAGRID_HEADER_RENDER_CLICK_KEY as g
|
|
41
41
|
};
|