@m4l/components 9.2.59 → 9.2.60-13062025.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.
Files changed (131) hide show
  1. package/.storybook/decorators/WithAppearanceContext/WithAppearanceContext.d.ts +1 -1
  2. package/.storybook/decorators/WithWindowsToolsAndParmsMFContexts/WithWindowsToolsAndParmsMFContexts.d.ts +5 -0
  3. package/components/DataGrid/Datagrid.styles.js +4 -12
  4. package/components/DataGrid/contexts/DataGridContext/types.d.ts +4 -0
  5. package/components/DataGrid/subcomponents/Table/hooks/useSortColumnsRows.js +2 -0
  6. package/components/DynamicFilter/DynamicFilter.styles.js +87 -91
  7. package/components/DynamicFilter/slots/SlotsEnum.d.ts +0 -3
  8. package/components/DynamicFilter/slots/SlotsEnum.js +0 -3
  9. package/components/DynamicFilter/slots/dynamicFilterSlots.d.ts +0 -9
  10. package/components/DynamicFilter/slots/dynamicFilterSlots.js +3 -19
  11. package/components/DynamicFilter/store/DynamicFilterContext.js +5 -6
  12. package/components/DynamicFilter/subcomponents/FilterActions/FilterActions.js +1 -1
  13. package/components/DynamicFilter/subcomponents/FilterActions/useFilterActions.d.ts +1 -0
  14. package/components/DynamicFilter/subcomponents/FilterActions/useFilterActions.js +2 -1
  15. package/components/DynamicFilter/subcomponents/InputFilter/InputFilter.js +2 -0
  16. package/components/DynamicFilter/subcomponents/PopoverFilter/PopoverFilter.js +23 -18
  17. package/components/DynamicFilter/subcomponents/PopoverMenuFields/PopoverMenuFields.js +4 -1
  18. package/components/DynamicSort/DynamicSort.styles.js +86 -87
  19. package/components/DynamicSort/slots/DynamicSortSlots.d.ts +0 -9
  20. package/components/DynamicSort/slots/DynamicSortSlots.js +5 -21
  21. package/components/DynamicSort/slots/SlotsEnum.d.ts +1 -4
  22. package/components/DynamicSort/slots/SlotsEnum.js +1 -4
  23. package/components/DynamicSort/subcomponents/InputSort/InputSort.js +2 -0
  24. package/components/DynamicSort/subcomponents/PopoverSort/PopoverSort.js +21 -17
  25. package/components/DynamicSort/subcomponents/SortActions/SortActions.js +2 -2
  26. package/components/DynamicSort/subcomponents/SortActions/useSortActions.d.ts +2 -0
  27. package/components/DynamicSort/subcomponents/SortActions/useSortActions.js +2 -1
  28. package/components/NumberInput/hooks/useNumberInput/useNumberInput.js +2 -0
  29. package/components/PaperForm/styles.js +2 -1
  30. package/components/PropertyValue/PropertyValue.styles.js +2 -1
  31. package/components/SideBar/SideBar.js +4 -2
  32. package/components/SideBar/constants.d.ts +26 -2
  33. package/components/SideBar/constants.js +19 -7
  34. package/components/SideBar/context/sideBarContext/index.js +19 -5
  35. package/components/SideBar/context/sideBarContext/types.d.ts +22 -1
  36. package/components/SideBar/helpers/getMenuDataWithState/index.js +22 -8
  37. package/components/SideBar/hooks/useCollapse/index.d.ts +1 -0
  38. package/components/SideBar/hooks/useCollapse/useCollapse.d.ts +11 -0
  39. package/components/SideBar/hooks/useCollapse/useCollapse.js +23 -0
  40. package/components/SideBar/slots/SideBarEnum.d.ts +5 -5
  41. package/components/SideBar/slots/SideBarEnum.js +9 -11
  42. package/components/SideBar/slots/SideBarSlots.d.ts +9 -3
  43. package/components/SideBar/slots/SideBarSlots.js +36 -28
  44. package/components/SideBar/styles.js +2 -4
  45. package/components/SideBar/subcomponents/ContentComponent/index.js +39 -19
  46. package/components/SideBar/subcomponents/ContentComponent/style.js +166 -22
  47. package/components/SideBar/subcomponents/{FooterSidebar → Promotion}/index.d.ts +2 -2
  48. package/components/SideBar/subcomponents/{FooterSidebar → Promotion}/index.js +8 -15
  49. package/components/SideBar/subcomponents/{FooterSidebar → Promotion}/styles.js +2 -2
  50. package/components/SideBar/subcomponents/Promotion/types.d.ts +5 -0
  51. package/components/SideBar/subcomponents/SideBarDesktop/index.js +1 -1
  52. package/components/SideBar/subcomponents/SideBarDesktop/styles.js +10 -14
  53. package/components/SideBar/subcomponents/SideBarMobile/index.js +1 -1
  54. package/components/SideBar/subcomponents/TreeGroupItems/index.d.ts +5 -0
  55. package/components/SideBar/subcomponents/{ContentGroups → TreeGroupItems}/index.js +16 -18
  56. package/components/SideBar/subcomponents/{ContentGroups → TreeGroupItems}/styles.js +5 -7
  57. package/components/SideBar/subcomponents/{ContentGroups/subcomponents/ContainerMenuItemsMain → TreeGroupItems}/subcomponents/ArrowIcon/index.js +10 -7
  58. package/components/SideBar/subcomponents/{ContentGroups/subcomponents/ContainerMenuItemsMain → TreeGroupItems/subcomponents/NodeMenuItem}/index.d.ts +3 -3
  59. package/components/SideBar/subcomponents/TreeGroupItems/subcomponents/NodeMenuItem/index.js +53 -0
  60. package/components/SideBar/subcomponents/TreeGroupItems/subcomponents/NodeMenuItem/types.d.ts +8 -0
  61. package/components/SideBar/subcomponents/TreeGroupItems/subcomponents/NodeMenuItemMain/NodeMenuItemMain.d.ts +5 -0
  62. package/components/SideBar/subcomponents/TreeGroupItems/subcomponents/NodeMenuItemMain/NodeMenuItemMain.js +55 -0
  63. package/components/SideBar/subcomponents/TreeGroupItems/subcomponents/NodeMenuItemMain/index.d.ts +1 -0
  64. package/components/SideBar/subcomponents/TreeGroupItems/types.d.ts +4 -0
  65. package/components/SideBar/types.d.ts +7 -3
  66. package/components/WindowBase/WindowBase.js +4 -1
  67. package/components/WindowBase/WindowBase.styles.js +48 -13
  68. package/components/WindowBase/contexts/WindowToolsMFContext/types.d.ts +10 -0
  69. package/components/WindowBase/hooks/useDynamicMFParameters/index.js +2 -2
  70. package/components/WindowBase/slots/WindowBaseEnum.d.ts +2 -1
  71. package/components/WindowBase/slots/WindowBaseEnum.js +1 -0
  72. package/components/WindowBase/slots/WindowBaseSlots.d.ts +3 -0
  73. package/components/WindowBase/slots/WindowBaseSlots.js +6 -1
  74. package/components/WindowBase/subcomponents/Header/HeaderWindowBase.js +5 -3
  75. package/components/WindowBase/subcomponents/Header/useButtonActions.js +4 -2
  76. package/components/WindowBase/subcomponents/MemoizedIconButton/MemoizedIconButton.d.ts +1 -1
  77. package/components/WindowBase/subcomponents/MemoizedIconButton/MemoizedIconButton.js +1 -1
  78. package/components/WindowBase/subcomponents/MemoizedIconButton/types.d.ts +5 -0
  79. package/components/WindowBase/types.d.ts +11 -0
  80. package/components/areas/components/AreasViewer/subcomponents/Area/subcomponents/Window/Window.js +17 -0
  81. package/components/areas/components/AreasViewer/subcomponents/Area/subcomponents/Window/hooks/useRightActions.js +1 -0
  82. package/components/areas/components/AreasViewer/subcomponents/Area/subcomponents/Window/hooks/useWindow.d.ts +2 -0
  83. package/components/areas/components/AreasViewer/subcomponents/Area/subcomponents/Window/hooks/useWindow.js +8 -5
  84. package/components/areas/contexts/AreasContext/store.js +18 -2
  85. package/components/areas/contexts/AreasContext/types.d.ts +2 -0
  86. package/components/areas/hooks/index.d.ts +0 -1
  87. package/components/areas/types.d.ts +4 -0
  88. package/components/extended/React-resizable-panels/SplitLayout.js +6 -3
  89. package/components/extended/React-resizable-panels/SplitLayout.styles.js +78 -36
  90. package/components/extended/React-resizable-panels/constants.d.ts +6 -0
  91. package/components/extended/React-resizable-panels/constants.js +5 -1
  92. package/components/extended/React-resizable-panels/slots/SplitLayoutEnum.d.ts +2 -1
  93. package/components/extended/React-resizable-panels/slots/SplitLayoutEnum.js +1 -0
  94. package/components/extended/React-resizable-panels/slots/SplitLayoutSlots.d.ts +3 -0
  95. package/components/extended/React-resizable-panels/slots/SplitLayoutSlots.js +7 -1
  96. package/components/hook-form/RHFAutocompleteAsync/reducer/RHFAutocompleteReducer.js +5 -0
  97. package/components/mui_extended/Accordion/styles.js +1 -0
  98. package/components/mui_extended/Divider/index.d.ts +1 -0
  99. package/components/mui_extended/Divider/index.js +1 -0
  100. package/components/mui_extended/TabContent/TabContent.styles.js +2 -2
  101. package/components/mui_extended/Typography/slots/typographySlots.d.ts +1 -1
  102. package/components/mui_extended/index.d.ts +1 -0
  103. package/components/popups/components/PopupsProvider/hooks/usePopups.js +2 -1
  104. package/hooks/useDynamicFilterAndSort/styles.js +1 -1
  105. package/index.js +67 -67
  106. package/package.json +19 -18
  107. package/storybook/components/DynamicFilter/DynamicFilter.stories.d.ts +27 -11
  108. package/storybook/components/DynamicSort/DynamicSort.stories.d.ts +26 -10
  109. package/storybook/components/SideBar/subcomponents/FooterPromotion/FooterPromotion.d.ts +4 -0
  110. package/storybook/components/SideBar/subcomponents/FooterPromotion/constants.d.ts +3 -0
  111. package/storybook/components/SideBar/subcomponents/FooterPromotion/index.d.ts +1 -0
  112. package/storybook/components/extended/mui/IconButton/IconButton.stories.d.ts +1 -0
  113. package/.storybook/decorators/WithWindowsToolsContext/WithContextWindowTools.d.ts +0 -5
  114. package/components/SideBar/subcomponents/ContentGroups/index.d.ts +0 -5
  115. package/components/SideBar/subcomponents/ContentGroups/subcomponents/ContainerMenuItemsMain/index.js +0 -63
  116. package/components/SideBar/subcomponents/ContentGroups/subcomponents/ContainerMenuItemsMain/styles.d.ts +0 -2
  117. package/components/SideBar/subcomponents/ContentGroups/subcomponents/ContainerMenuItemsMain/styles.js +0 -47
  118. package/components/SideBar/subcomponents/ContentGroups/subcomponents/ContainerMenuItemsMain/types.d.ts +0 -7
  119. package/components/SideBar/subcomponents/ContentGroups/types.d.ts +0 -4
  120. package/components/SideBar/subcomponents/FooterSidebar/types.d.ts +0 -5
  121. package/components/SideBar/subcomponents/HeaderSidebar/index.js +0 -25
  122. package/components/areas/hooks/useSetWindowsTitle/index.d.ts +0 -1
  123. package/components/areas/hooks/useSetWindowsTitle/useSetWindowsTitle.d.ts +0 -6
  124. package/components/areas/hooks/useSetWindowsTitle/useSetWindowsTitle.js +0 -31
  125. package/storybook/components/WindowBase/subcomponents/WithContextWindowToolsProvider.d.ts +0 -5
  126. package/storybook/components/commonActions/components/ActionFormCancel/WindowToolsMFProvider.d.ts +0 -5
  127. /package/components/{areas/hooks/useSetWindowsTitle → SideBar/hooks/useCollapse}/index.js +0 -0
  128. /package/components/SideBar/subcomponents/{FooterSidebar → Promotion}/styles.d.ts +0 -0
  129. /package/components/SideBar/subcomponents/{ContentGroups → TreeGroupItems}/styles.d.ts +0 -0
  130. /package/components/SideBar/subcomponents/{ContentGroups/subcomponents/ContainerMenuItemsMain → TreeGroupItems}/subcomponents/ArrowIcon/index.d.ts +0 -0
  131. /package/components/SideBar/subcomponents/{ContentGroups/subcomponents/ContainerMenuItemsMain → TreeGroupItems}/subcomponents/ArrowIcon/types.d.ts +0 -0
@@ -5,50 +5,55 @@ const dynamicSortStyles = {
5
5
  /**
6
6
  * Root: Estilos del contenedor principal del componente.
7
7
  */
8
- root: () => ({
8
+ root: ({ theme, ownerState }) => ({
9
9
  containerName: CONTAINER_QUERY_NAME,
10
10
  containerType: "inline-size",
11
11
  width: "100%",
12
12
  height: "auto",
13
- padding: 0
13
+ padding: 0,
14
+ ...getSizeStyles(
15
+ theme,
16
+ ownerState?.size || "medium",
17
+ "container",
18
+ (size) => ({
19
+ height: size,
20
+ maxHeight: size,
21
+ minHeight: size
22
+ })
23
+ )
14
24
  }),
15
25
  /**
16
26
  * innerContainer: Estilos del contenedor interno del componente.
17
27
  */
18
28
  innerContainer: ({ theme, ownerState }) => ({
19
- display: "grid",
20
- gridTemplateColumns: "auto 1fr auto",
21
- gridTemplateAreas: '"input-sort applied-sorts actions-sort"',
29
+ display: "flex",
22
30
  alignItems: "center",
23
31
  justifyContent: "flex-start",
24
32
  width: "100%",
25
33
  height: "fit-content",
26
- border: theme.vars.size.borderStroke.container,
27
- borderRadius: theme.vars.size.borderRadius.r1,
28
- borderColor: ownerState?.isValid ? theme.vars.palette.border?.default : theme.vars.palette.error.enabled,
34
+ borderRadius: theme.vars.size.borderRadius.r2,
29
35
  background: theme.vars.palette.background.default,
36
+ boxShadow: ownerState?.isValid ? `inset 0px 0px 0px 1px ${theme.vars.palette.border.secondary}` : `inset 0px 0px 0px 1px ${theme.vars.palette.error.enabled}`,
37
+ overflow: "hidden",
30
38
  '&:has([aria-expanded="true"])': {
31
- borderColor: ownerState?.isValid ? theme.vars.palette.primary.active : theme.vars.palette.error.enabled
39
+ boxShadow: ownerState?.isValid ? `inset 0px 0px 0px 1.3px ${theme.vars.palette.border.main}` : `inset 0px 0px 0px 1px ${theme.vars.palette.error.enabled}`
32
40
  }
33
41
  }),
34
42
  /**
35
43
  * inputSort: Estilos del contenedor del campo de entrada de ordenamiento.
36
44
  */
37
45
  inputSort: ({ theme, ownerState }) => ({
38
- gridArea: "input-sort",
39
46
  display: "flex",
40
47
  flexDirection: "row",
41
- paddingLeft: theme.vars.size.baseSpacings.sp1,
48
+ paddingLeft: theme.vars.size.baseSpacings.sp2,
42
49
  paddingRight: theme.vars.size.baseSpacings.sp1,
43
50
  height: "100%",
44
51
  overflow: "hidden",
45
- maxWidth: "135px",
52
+ maxWidth: "120px",
46
53
  width: "100%",
47
54
  alignItems: "center",
48
55
  borderTopLeftRadius: theme.vars.size.borderRadius.r1,
49
56
  borderBottomLeftRadius: theme.vars.size.borderRadius.r1,
50
- borderRight: theme.vars.size.borderStroke.container,
51
- borderColor: theme.vars.palette.border?.default,
52
57
  ...getSizeStyles(
53
58
  theme,
54
59
  ownerState?.size || "medium",
@@ -62,6 +67,8 @@ const dynamicSortStyles = {
62
67
  * inputSortInput: Estilos del campo de entrada de ordenamiento.
63
68
  */
64
69
  inputSortInput: ({ theme, ownerState }) => ({
70
+ width: "100%",
71
+ background: "#ffffff00",
65
72
  ...getSizeStyles(
66
73
  theme,
67
74
  ownerState?.size || "medium",
@@ -72,51 +79,57 @@ const dynamicSortStyles = {
72
79
  maxHeight: size
73
80
  })
74
81
  ),
82
+ fontFamily: "inherit",
75
83
  ...getTypographyStyles(
76
84
  theme.generalSettings.isMobile,
77
85
  ownerState?.size || "medium",
78
86
  "body"
79
87
  ),
80
- background: theme.vars.palette.background.default,
81
88
  color: theme.vars.palette.text.secondary,
82
89
  border: 0,
83
90
  borderColor: "transparent",
84
91
  paddingLeft: theme.vars.size.baseSpacings.sp2,
85
92
  paddingRight: theme.vars.size.baseSpacings.sp2,
86
- width: "100%",
87
93
  height: "100%",
88
94
  "&::placeholder": {
89
95
  color: theme.vars.palette.text.secondary
90
96
  },
91
97
  "&:focus-visible": {
92
98
  color: theme.vars.palette.text.secondary,
93
- border: theme.vars.size.borderStroke.container,
99
+ border: "unset",
94
100
  borderColor: theme.vars.palette.primary.opacity,
95
- background: theme.vars.palette.primary.opacity,
96
101
  BorderRadius: theme.vars.size.borderRadius["r0-5"],
97
102
  outline: "none!important"
98
- },
99
- "&:hover": {
100
- borderColor: theme.vars.palette.primary?.toneOpacity,
101
- background: theme.vars.palette.background?.hover
102
103
  }
103
104
  }),
104
105
  /**
105
106
  * appliedSorts: Estilos del contenedor de los campos de ordenamiento aplicados.
106
107
  */
107
- appliedSorts: ({ theme }) => ({
108
- gridArea: "applied-sorts",
108
+ appliedSorts: ({ theme, ownerState }) => ({
109
109
  width: "100%",
110
110
  height: "fit-content",
111
- overflow: "hidden",
111
+ display: "flex",
112
+ alignItems: "center",
112
113
  borderLeft: "none",
113
114
  margin: "0px",
114
- padding: `0px ${theme.vars.size.baseSpacings.sp1}`
115
+ padding: `0px ${theme.vars.size.baseSpacings.sp1}`,
116
+ flex: 1,
117
+ overflow: "hidden",
118
+ ...getSizeStyles(
119
+ theme,
120
+ ownerState?.size || "medium",
121
+ "container",
122
+ (size) => ({
123
+ height: size,
124
+ maxHeight: size,
125
+ minHeight: size
126
+ })
127
+ )
115
128
  }),
116
129
  /**
117
130
  * appliedSortInnerContainer: Estilos del contenedor interno de los campos de ordenamiento aplicados.
118
131
  */
119
- appliedSortInnerContainer: ({ theme }) => ({
132
+ appliedSortInnerContainer: ({ theme, ownerState }) => ({
120
133
  padding: theme.vars.size.baseSpacings["sp0-5"],
121
134
  gap: theme.vars.size.baseSpacings.sp1,
122
135
  height: "fit-content",
@@ -126,13 +139,30 @@ const dynamicSortStyles = {
126
139
  justifyContent: "flex-start",
127
140
  alignItems: "center",
128
141
  overflow: "auto hidden",
129
- position: "relative"
142
+ position: "relative",
143
+ "& .M4LChip-root": {
144
+ borderRadius: theme.vars.size.borderRadius.r1,
145
+ ...getSizeStyles(
146
+ theme,
147
+ ownerState?.size || "medium",
148
+ "action",
149
+ (size) => ({
150
+ height: size
151
+ })
152
+ ),
153
+ "& .M4LIconButton-styledMUIIconButton:hover": {
154
+ backgroundColor: `${theme.vars.palette.chips.error.contained.backgroundHover} !important`,
155
+ "& .M4LIcon-icon": {
156
+ backgroundColor: `${theme.vars.palette.chips.error.contained.backgroundColorTone} !important`
157
+ }
158
+ }
159
+ }
130
160
  }),
131
161
  /**
132
162
  * actions: Estilos del contenedor de los botones de acción.
133
163
  */
134
164
  actions: ({ theme, ownerState }) => ({
135
- gridArea: "actions-sort",
165
+ gridArea: "actions-filter",
136
166
  overflow: "hidden",
137
167
  display: "flex",
138
168
  flexDirection: "row",
@@ -142,19 +172,33 @@ const dynamicSortStyles = {
142
172
  alignItems: "center",
143
173
  borderTopRightRadius: theme.vars.size.borderRadius.r1,
144
174
  borderBottomRightRadius: theme.vars.size.borderRadius.r1,
145
- borderLeft: !ownerState?.visibleRefresh && !ownerState?.isDirty ? "none" : theme.vars.size.borderStroke.container,
146
- borderColor: theme.vars.palette.border?.default
175
+ boxShadow: `inset 1px 0px 0px 0px ${theme.vars.palette.border.secondary}`,
176
+ ...!ownerState?.visibleRefresh && !ownerState?.isDirty && {
177
+ display: "none"
178
+ },
179
+ ...ownerState?.inEdition && ownerState?.isValid && {
180
+ boxShadow: `inset 1px 0px 0px 0px ${theme.vars.palette.border.main}`
181
+ },
182
+ ...!ownerState?.isValid && {
183
+ boxShadow: `inset 1px 0px 0px 0px ${theme.vars.palette.error.enabled}`
184
+ }
185
+ }),
186
+ /**
187
+ * actionsClearButton: Estilos del botón de acción de limpiar.
188
+ */
189
+ actionsClearButton: ({ theme }) => ({
190
+ visibility: "visible",
191
+ "&:hover": {
192
+ backgroundColor: `${theme.vars.palette.chips.error.contained.backgroundHover} !important`,
193
+ "& .M4LIcon-icon": {
194
+ backgroundColor: `${theme.vars.palette.chips.error.contained.backgroundColorTone} !important`
195
+ }
196
+ }
147
197
  }),
148
- actionsClearButton: {
149
- visibility: "visible"
150
- },
151
198
  /**
152
199
  * actionsSubmitButton: Estilos del botón de acción de envío de formulario.
153
200
  */
154
201
  actionsSubmitButton: ({ theme, ownerState }) => ({
155
- ...ownerState?.isValid === false ? { border: `1px dashed ${theme.vars.palette.error.enabled}` } : {
156
- visibility: "visible"
157
- },
158
202
  ...ownerState?.isDirty ? {
159
203
  animation: "changeBgColor 0.9s ease infinite",
160
204
  "& .M4LIcon-icon": {
@@ -209,66 +253,21 @@ const dynamicSortStyles = {
209
253
  }
210
254
  }
211
255
  }),
212
- /**
213
- * popoverSortHeader: Estilos del encabezado del menú emergente de ordenamiento.
214
- */
215
- popoverSortHeader: ({ theme, ownerState }) => ({
216
- display: "flex",
217
- alignItems: "center",
218
- gap: theme.vars.size.baseSpacings.sp2,
219
- padding: theme.vars.size.baseSpacings.sp1,
220
- paddingLeft: theme.vars.size.baseSpacings.sp2,
221
- borderTopLeftRadius: theme.vars.size.borderRadius.r1,
222
- borderTopRightRadius: theme.vars.size.borderRadius.r1,
223
- borderBottom: theme.vars.size.borderStroke.container,
224
- borderColor: theme.vars.palette.border.secondary,
225
- "& .MuiTypography-root": {
226
- color: theme.vars.palette.primary.main
227
- },
228
- "& .M4LIcon-icon": {
229
- backgroundColor: theme.vars.palette.primary.main
230
- },
231
- ...getSizeStyles(
232
- theme,
233
- ownerState?.size || "medium",
234
- "container",
235
- (size) => ({
236
- height: size
237
- })
238
- )
239
- }),
240
- /**
241
- * popoverSortHeaderTitle: Estilos del título del menú emergente de ordenamiento.
242
- */
243
- popoverSortHeaderTitle: ({ theme }) => ({
244
- color: `${theme.vars.palette.primary.main} !important`
245
- }),
246
256
  /**
247
257
  * popoverSortContainerFields: Estilos del contenedor de campos del menú emergente de ordenamiento.
248
258
  */
249
- popoverSortContainerFields: () => ({
259
+ popoverSortContainerFields: ({ theme }) => ({
250
260
  height: "fit-content",
251
261
  "& > div": {
252
- display: "flex",
253
- height: "auto",
254
- flexDirection: "column"
262
+ display: "grid",
263
+ flexDirection: "column",
264
+ gap: theme.vars.size.baseSpacings.sp2
255
265
  }
256
266
  }),
257
- /**
258
- * contentSort: Estilos del contenedor entre el change sort y actions
259
- */
260
- contentSort: ({ theme }) => ({
261
- display: "flex",
262
- flexDirection: "column",
263
- padding: theme.vars.size.baseSpacings.sp3,
264
- gap: theme.vars.size.baseSpacings.sp3
265
- }),
266
267
  /**
267
268
  * popoverSortActions: Estilos del contenedor de acciones del menú emergente de ordenamiento.
268
269
  */
269
- popoverSortActions: ({ theme }) => ({
270
- padding: `${theme.vars.size.baseSpacings.sp3} 0px`
271
- }),
270
+ popoverSortActions: {},
272
271
  /**
273
272
  * inputSortInputSkeleton: Estilos del esqueleto del campo de entrada de ordenamiento.
274
273
  */
@@ -34,15 +34,6 @@ export declare const PopoverStyled: import('@emotion/styled').StyledComponent<Pi
34
34
  export declare const PopoverContainerFieldsStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
35
35
  ownerState?: (Partial<import('../types').DynamicSortOwnerState> & Record<string, unknown>) | undefined;
36
36
  }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
37
- export declare const PopoverHeaderStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
38
- ownerState?: (Partial<import('../types').DynamicSortOwnerState> & Record<string, unknown>) | undefined;
39
- }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
40
- export declare const ContentSortStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
41
- ownerState?: (Partial<import('../types').DynamicSortOwnerState> & Record<string, unknown>) | undefined;
42
- }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
43
- export declare const PopoverHeaderTitleStyled: import('@emotion/styled').StyledComponent<Pick<import('../../mui_extended/Typography/types').TypographyProps, keyof import('../../mui_extended/Typography/types').TypographyProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
44
- ownerState?: (Partial<import('../types').DynamicSortOwnerState> & Record<string, unknown>) | undefined;
45
- }, {}, {}>;
46
37
  export declare const PopoverHeaderActionsStyled: import('@emotion/styled').StyledComponent<Pick<import('../../CommonActions/components/ActionsContainer').ActionsContainerProps & import('react').RefAttributes<HTMLDivElement>, keyof import('react').RefAttributes<HTMLDivElement> | keyof import('../../CommonActions/components/ActionsContainer').ActionsContainerProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
47
38
  ownerState?: (Partial<import('../types').DynamicSortOwnerState> & Record<string, unknown>) | undefined;
48
39
  }, {}, {}>;
@@ -4,7 +4,6 @@ import { D as DYNAMIC_SORT_KEY_COMPONENT } from "../constants.js";
4
4
  import { D as DynamicSortSlots } from "./SlotsEnum.js";
5
5
  import { S as Skeleton } from "../../mui_extended/Skeleton/Skeleton.js";
6
6
  import { I as IconButton } from "../../mui_extended/IconButton/IconButton.js";
7
- import { T as Typography } from "../../mui_extended/Typography/Typography.js";
8
7
  import { A as ActionsContainer } from "../../CommonActions/components/ActionsContainer/ActionsContainer.js";
9
8
  import { P as Popover } from "../../mui_extended/Popover/Popover.js";
10
9
  const RootStyled = styled("div", {
@@ -55,18 +54,6 @@ const PopoverContainerFieldsStyled = styled("div", {
55
54
  name: DYNAMIC_SORT_KEY_COMPONENT,
56
55
  slot: DynamicSortSlots.popoverSortContainerFields
57
56
  })(dynamicSortStyles?.popoverSortContainerFields);
58
- const PopoverHeaderStyled = styled("div", {
59
- name: DYNAMIC_SORT_KEY_COMPONENT,
60
- slot: DynamicSortSlots.popoverSortHeader
61
- })(dynamicSortStyles?.popoverSortHeader);
62
- const ContentSortStyled = styled("div", {
63
- name: DYNAMIC_SORT_KEY_COMPONENT,
64
- slot: DynamicSortSlots.contentSort
65
- })(dynamicSortStyles?.contentSort);
66
- const PopoverHeaderTitleStyled = styled(Typography, {
67
- name: DYNAMIC_SORT_KEY_COMPONENT,
68
- slot: DynamicSortSlots.popoverSortHeaderTitle
69
- })(dynamicSortStyles?.popoverSortHeaderTitle);
70
57
  const PopoverHeaderActionsStyled = styled(ActionsContainer, {
71
58
  name: DYNAMIC_SORT_KEY_COMPONENT,
72
59
  slot: DynamicSortSlots.popoverSortActions
@@ -77,7 +64,6 @@ const InputSortInputSkeletonStyled = styled(Skeleton, {
77
64
  })(dynamicSortStyles?.inputSortInputSkeleton);
78
65
  export {
79
66
  AppliedSortsStyled as A,
80
- ContentSortStyled as C,
81
67
  InnerContainerStyled as I,
82
68
  PopoverMenuStyled as P,
83
69
  RootStyled as R,
@@ -86,11 +72,9 @@ export {
86
72
  InputSortInputSkeletonStyled as c,
87
73
  InputSortInputStyled as d,
88
74
  PopoverStyled as e,
89
- PopoverHeaderStyled as f,
90
- PopoverHeaderTitleStyled as g,
91
- PopoverContainerFieldsStyled as h,
92
- PopoverHeaderActionsStyled as i,
93
- ActionsStyled as j,
94
- ActionsClearButtonStyled as k,
95
- ActionsSubmitButtonStyled as l
75
+ PopoverContainerFieldsStyled as f,
76
+ PopoverHeaderActionsStyled as g,
77
+ ActionsStyled as h,
78
+ ActionsClearButtonStyled as i,
79
+ ActionsSubmitButtonStyled as j
96
80
  };
@@ -11,9 +11,6 @@ export declare enum DynamicSortSlots {
11
11
  popoverMenu = "popoverMenu",
12
12
  popoverSort = "popoverSort",
13
13
  popoverSortContainerFields = "popoverSortContainerFields",
14
- popoverSortHeader = "popoverSortHeader",
15
- contentSort = "contentSort",
16
- popoverSortHeaderTitle = "popoverSortHeaderTitle",
17
14
  popoverSortActions = "popoverSortActions",
18
- inputSortInputSkeleton = "inputSortInputSkeleton"
15
+ inputSortInputSkeleton = "inputSortInputSkelecontentSortton"
19
16
  }
@@ -11,11 +11,8 @@ var DynamicSortSlots = /* @__PURE__ */ ((DynamicSortSlots2) => {
11
11
  DynamicSortSlots2["popoverMenu"] = "popoverMenu";
12
12
  DynamicSortSlots2["popoverSort"] = "popoverSort";
13
13
  DynamicSortSlots2["popoverSortContainerFields"] = "popoverSortContainerFields";
14
- DynamicSortSlots2["popoverSortHeader"] = "popoverSortHeader";
15
- DynamicSortSlots2["contentSort"] = "contentSort";
16
- DynamicSortSlots2["popoverSortHeaderTitle"] = "popoverSortHeaderTitle";
17
14
  DynamicSortSlots2["popoverSortActions"] = "popoverSortActions";
18
- DynamicSortSlots2["inputSortInputSkeleton"] = "inputSortInputSkeleton";
15
+ DynamicSortSlots2["inputSortInputSkeleton"] = "inputSortInputSkelecontentSortton";
19
16
  return DynamicSortSlots2;
20
17
  })(DynamicSortSlots || {});
21
18
  export {
@@ -33,6 +33,8 @@ const InputSort = () => {
33
33
  value: inputData,
34
34
  placeholder: inputPlaceHolder,
35
35
  ownerState: { ...ownerState },
36
+ role: "searchbox",
37
+ "aria-label": "searchbox",
36
38
  ...inputHandlersProps
37
39
  }
38
40
  ),
@@ -1,10 +1,10 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
- import { I as Icon } from "../../../Icon/Icon.js";
3
2
  import { u as useDynamicSortBase } from "../DynamicSortBase/useDynamicSortBase.js";
4
3
  import { D as DataTypeComponent } from "../FieldTypes/DataTypeComponent.js";
5
4
  import { u as usePopoverSort } from "./usePopoverSort.js";
6
- import { e as PopoverStyled, f as PopoverHeaderStyled, g as PopoverHeaderTitleStyled, C as ContentSortStyled, h as PopoverContainerFieldsStyled, i as PopoverHeaderActionsStyled } from "../../slots/DynamicSortSlots.js";
5
+ import { e as PopoverStyled, f as PopoverContainerFieldsStyled, g as PopoverHeaderActionsStyled } from "../../slots/DynamicSortSlots.js";
7
6
  import { R as RHFormProvider } from "../../../hook-form/RHFormContext/index.js";
7
+ import { W as WindowBase } from "../../../WindowBase/WindowBase.js";
8
8
  import { A as ActionCancel } from "../../../CommonActions/components/ActionCancel/ActionCancel.js";
9
9
  import { A as ActionIntro } from "../../../CommonActions/components/ActionIntro/ActionIntro.js";
10
10
  function PopoverSort() {
@@ -22,7 +22,7 @@ function PopoverSort() {
22
22
  statusLoad,
23
23
  canRender
24
24
  } = usePopoverSort();
25
- const { ownerState, size } = useDynamicSortBase();
25
+ const { size } = useDynamicSortBase();
26
26
  if (!canRender) {
27
27
  return null;
28
28
  }
@@ -38,26 +38,30 @@ function PopoverSort() {
38
38
  anchorEl,
39
39
  onKeyDown: handleKeyDownPopper,
40
40
  onClose: handleClosePopover,
41
- children: /* @__PURE__ */ jsxs(
41
+ children: /* @__PURE__ */ jsx(
42
42
  RHFormProvider,
43
43
  {
44
44
  onSubmit,
45
45
  values: sortFormValue,
46
46
  validationSchema: popupValidationSchema,
47
47
  statusLoad,
48
- children: [
49
- /* @__PURE__ */ jsxs(PopoverHeaderStyled, { ownerState: { ...ownerState }, children: [
50
- field.urlIcon && /* @__PURE__ */ jsx(Icon, { src: field.urlIcon, size }),
51
- /* @__PURE__ */ jsx(PopoverHeaderTitleStyled, { variant: "paragraphDens", size, children: labelField })
52
- ] }),
53
- /* @__PURE__ */ jsxs(ContentSortStyled, { children: [
54
- /* @__PURE__ */ jsx(PopoverContainerFieldsStyled, { children: /* @__PURE__ */ jsx(DataTypeComponent, { formSort, statusLoad }) }),
55
- /* @__PURE__ */ jsxs(PopoverHeaderActionsStyled, { children: [
56
- /* @__PURE__ */ jsx(ActionCancel, { size, onClick: onClose }),
57
- /* @__PURE__ */ jsx(ActionIntro, { size })
58
- ] })
59
- ] })
60
- ]
48
+ children: /* @__PURE__ */ jsxs(
49
+ WindowBase,
50
+ {
51
+ title: labelField,
52
+ iconUrl: field.urlIcon,
53
+ variant: "text",
54
+ type: "popup",
55
+ selected: true,
56
+ children: [
57
+ /* @__PURE__ */ jsx(PopoverContainerFieldsStyled, { children: /* @__PURE__ */ jsx(DataTypeComponent, { formSort, statusLoad }) }),
58
+ /* @__PURE__ */ jsxs(PopoverHeaderActionsStyled, { children: [
59
+ /* @__PURE__ */ jsx(ActionCancel, { size, onClick: onClose }),
60
+ /* @__PURE__ */ jsx(ActionIntro, { size, "aria-label": "applySort" })
61
+ ] })
62
+ ]
63
+ }
64
+ )
61
65
  }
62
66
  )
63
67
  }
@@ -3,7 +3,7 @@ import { useModuleDictionary } from "@m4l/core";
3
3
  import { g as getDynamicSortDictionary, D as DICCTIONARY } from "../../dictionary.js";
4
4
  import { u as useDynamicSortBase } from "../DynamicSortBase/useDynamicSortBase.js";
5
5
  import { u as useSortActions } from "./useSortActions.js";
6
- import { j as ActionsStyled, k as ActionsClearButtonStyled, l as ActionsSubmitButtonStyled } from "../../slots/DynamicSortSlots.js";
6
+ import { h as ActionsStyled, i as ActionsClearButtonStyled, j as ActionsSubmitButtonStyled } from "../../slots/DynamicSortSlots.js";
7
7
  function SortActions() {
8
8
  const {
9
9
  sortIconUrl,
@@ -16,7 +16,7 @@ function SortActions() {
16
16
  } = useSortActions();
17
17
  const { size, visibleRefresh, ownerState: { isDirty } } = useDynamicSortBase();
18
18
  const { getLabel } = useModuleDictionary();
19
- return /* @__PURE__ */ jsxs(ActionsStyled, { ownerState: { isDirty: canShowRemoveAction, visibleRefresh }, children: [
19
+ return /* @__PURE__ */ jsxs(ActionsStyled, { ownerState: { isDirty: canShowRemoveAction, visibleRefresh, isValid: ownerState?.isValid, inEdition: ownerState?.inEdition }, children: [
20
20
  canShowRemoveAction && /* @__PURE__ */ jsx(
21
21
  ActionsClearButtonStyled,
22
22
  {
@@ -11,6 +11,8 @@ declare function useSortActions(): {
11
11
  sortButtonDictionaryTooltip: string;
12
12
  ownerState: {
13
13
  isValid: boolean;
14
+ isDirty: boolean;
15
+ inEdition: boolean;
14
16
  };
15
17
  };
16
18
  export default useSortActions;
@@ -9,6 +9,7 @@ function useSortActions() {
9
9
  const isValid = useDynamicSortStore((state) => state.ownerState?.isValid);
10
10
  const isDirty = useDynamicSortStore((state) => state.ownerState?.isDirty);
11
11
  const appliedSorts = useDynamicSortStore((state) => state.appliedSorts);
12
+ const inEdition = useDynamicSortStore((state) => state.ownerState?.inEdition);
12
13
  const { hidePopoverSort, clearSorts, fireOnChangeSorts } = useDynamicSortStore(
13
14
  (state) => state.actions
14
15
  );
@@ -31,7 +32,7 @@ function useSortActions() {
31
32
  onClickClearSorts,
32
33
  onClickSort: fireOnChangeSorts,
33
34
  sortButtonDictionaryTooltip,
34
- ownerState: { isValid }
35
+ ownerState: { isValid, isDirty, inEdition }
35
36
  };
36
37
  }
37
38
  export {
@@ -56,9 +56,11 @@ const useNumberInput = (parameters) => {
56
56
  (event, field, fieldValue, reason) => {
57
57
  if (field === "value" && typeof fieldValue !== "string") {
58
58
  switch (reason) {
59
+ // only a blur event will dispatch `numberInput:clamp`
59
60
  case "numberInput:inputChange":
60
61
  onChange?.(event, fieldValue);
61
62
  break;
63
+ // only a blur event will dispatch `numberInput:clamp`
62
64
  case "numberInput:clamp":
63
65
  onChange?.(event, fieldValue);
64
66
  break;
@@ -13,7 +13,8 @@ const paperFormStyles = {
13
13
  borderColor: theme.vars.palette.border.default,
14
14
  overflow: "hidden",
15
15
  width: "100%",
16
- height: "auto"
16
+ height: "auto",
17
+ container: "container / inline-size"
17
18
  }),
18
19
  /**
19
20
  * ************************************************************
@@ -9,7 +9,8 @@ const propertyValueStyles = {
9
9
  minWidth: `${maxWidth}px`,
10
10
  [`@container ${CONTAINER_QUERY_NAME} (max-width: ${maxWidth - 1}px)`]: {
11
11
  minWidth: "100px",
12
- maxWidth: "100%"
12
+ maxWidth: "100%",
13
+ width: "100%"
13
14
  }
14
15
  });
15
16
  const semanticStylesMap = {
@@ -23,7 +23,8 @@ const SideBar = memo((props) => {
23
23
  expandedWidth = "230px",
24
24
  companyName,
25
25
  companySlogan,
26
- urlIconPrefix = `${host_static_assets}/${environment_assets}${PATH_ICONS}`
26
+ urlIconPrefix = `${host_static_assets}/${environment_assets}${PATH_ICONS}`,
27
+ promotion
27
28
  } = props;
28
29
  const menuDataWithState = useMemo(() => getMenuDataWithState({ menuData: menuData ?? getDataToSkeleton(), moduleSelectedId }), [menuData, moduleSelectedId]);
29
30
  const isMobile = useIsMobile();
@@ -44,7 +45,8 @@ const SideBar = memo((props) => {
44
45
  expandedWidth,
45
46
  companyName,
46
47
  companySlogan,
47
- urlIconPrefix
48
+ urlIconPrefix,
49
+ promotion
48
50
  },
49
51
  children: !isMobile ? /* @__PURE__ */ jsx(SideBarDesktop, {}) : /* @__PURE__ */ jsx(SideBarMobile, {})
50
52
  }
@@ -1,8 +1,32 @@
1
+ import { HeaderSidebarSlots, ContentGroupsSlots, SideBarDesktopSlots, SideBarFooterSlots, SideBarMobileSlots, ContentComponentSlots } from './slots/SideBarEnum';
1
2
  export declare const SIDEBAR_KEY_COMPONENT = "M4LSideBar";
2
3
  export declare const CONTAINER_BTN_ANCHORED = "M4LSideBarButtonAnchored";
3
4
  export declare const LIST_MENU_ITEM = "M4LListMenuItem";
4
- export declare const ITEM_ACTIVE = "M4LItemActive";
5
- export declare const ITEM_IN_TREE_ACTIVE = "M4LItemInTreeActive";
6
5
  export declare const PATH_ICONS = "/frontend/domain/microfrontends/";
7
6
  export declare const PATH_ARROW_DOWN_ICON = "frontend/components/sidebar/assets/icons/ChevronRight.svg";
8
7
  export declare const PATH_ARROW_RIGHT_ICON = "frontend/components/sidebar/assets/icons/arrow_right.svg";
8
+ export declare const ALL_SIDEBAR_SLOTS: {
9
+ contentComponentRoot: ContentComponentSlots.contentComponentRoot;
10
+ contentComponentHide: ContentComponentSlots.contentComponentHide;
11
+ containerTreeItemsAndPromotion: ContentComponentSlots.containerTreeItemsAndPromotion;
12
+ containerNodeMenuItem: ContentComponentSlots.containerNodeMenuItem;
13
+ containerNodeMenuItemMain: ContentComponentSlots.containerNodeMenuItemMain;
14
+ menuItemMain: ContentComponentSlots.menuItemMain;
15
+ containerFooter: SideBarFooterSlots.containerFooter;
16
+ containerHeaderSidebarRoot: HeaderSidebarSlots.containerHeaderSidebarRoot;
17
+ containerTitleSubtitle: HeaderSidebarSlots.containerTitleSubtitle;
18
+ containerTreeGroupItems: ContentGroupsSlots.containerTreeGroupItems;
19
+ containerContentGroups: ContentGroupsSlots.containerContentGroups;
20
+ containerContentTitle: ContentGroupsSlots.containerContentTitle;
21
+ containerContentNavItems: ContentGroupsSlots.containerContentNavItems;
22
+ containerContentItem: ContentGroupsSlots.containerContentItem;
23
+ containerArrowIconRoot: ContentGroupsSlots.containerArrowIconRoot;
24
+ containerSideBarMobile: SideBarMobileSlots.containerSideBarMobile;
25
+ containerDesktopRoot: SideBarDesktopSlots.containerDesktopRoot;
26
+ containerDesktopContent: SideBarDesktopSlots.containerDesktopContent;
27
+ containerBtnAnchored: SideBarDesktopSlots.containerBtnAnchored;
28
+ };
29
+ export declare const CLASS_NAME_IS_ROOT = "is-root";
30
+ export declare const CLASS_NAME_MENU_ACTIVE = "menu-active";
31
+ export declare const CLASS_NAME_ITEM_IN_TREE_ACTIVE = "item-in-tree-active";
32
+ export declare const CLASS_NAME_HAS_CHILDREN = "has-children";
@@ -1,18 +1,30 @@
1
+ import { C as ContentComponentSlots, S as SideBarFooterSlots, H as HeaderSidebarSlots, a as ContentGroupsSlots, b as SideBarMobileSlots, c as SideBarDesktopSlots } from "./slots/SideBarEnum.js";
1
2
  const SIDEBAR_KEY_COMPONENT = "M4LSideBar";
2
3
  const CONTAINER_BTN_ANCHORED = "M4LSideBarButtonAnchored";
3
- const LIST_MENU_ITEM = "M4LListMenuItem";
4
- const ITEM_ACTIVE = "M4LItemActive";
5
- const ITEM_IN_TREE_ACTIVE = "M4LItemInTreeActive";
6
4
  const PATH_ICONS = "/frontend/domain/microfrontends/";
7
5
  const PATH_ARROW_DOWN_ICON = "frontend/components/sidebar/assets/icons/ChevronRight.svg";
8
6
  const PATH_ARROW_RIGHT_ICON = "frontend/components/sidebar/assets/icons/arrow_right.svg";
7
+ const ALL_SIDEBAR_SLOTS = {
8
+ ...SideBarDesktopSlots,
9
+ ...SideBarMobileSlots,
10
+ ...ContentGroupsSlots,
11
+ ...HeaderSidebarSlots,
12
+ ...SideBarFooterSlots,
13
+ ...ContentComponentSlots
14
+ };
15
+ const CLASS_NAME_IS_ROOT = "is-root";
16
+ const CLASS_NAME_MENU_ACTIVE = "menu-active";
17
+ const CLASS_NAME_ITEM_IN_TREE_ACTIVE = "item-in-tree-active";
18
+ const CLASS_NAME_HAS_CHILDREN = "has-children";
9
19
  export {
20
+ ALL_SIDEBAR_SLOTS as A,
10
21
  CONTAINER_BTN_ANCHORED as C,
11
- ITEM_ACTIVE as I,
12
- LIST_MENU_ITEM as L,
13
22
  PATH_ICONS as P,
14
23
  SIDEBAR_KEY_COMPONENT as S,
15
24
  PATH_ARROW_RIGHT_ICON as a,
16
- ITEM_IN_TREE_ACTIVE as b,
17
- PATH_ARROW_DOWN_ICON as c
25
+ CLASS_NAME_IS_ROOT as b,
26
+ CLASS_NAME_MENU_ACTIVE as c,
27
+ CLASS_NAME_ITEM_IN_TREE_ACTIVE as d,
28
+ CLASS_NAME_HAS_CHILDREN as e,
29
+ PATH_ARROW_DOWN_ICON as f
18
30
  };