@m4l/components 9.1.131 → 9.1.133

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 (41) hide show
  1. package/components/Chip/Chip.js +21 -21
  2. package/components/Chip/ChipStyles.js +22 -50
  3. package/components/Chip/slots/ChipSlots.js +2 -2
  4. package/components/Chip/types.d.ts +1 -1
  5. package/components/DynamicFilter/store/DynamicFilterContext.js +2 -2
  6. package/components/DynamicSort/DynamicSort.styles.js +13 -16
  7. package/components/Icon/Icon.js +13 -7
  8. package/components/Icon/Icon.styles.js +23 -20
  9. package/components/Icon/types.d.ts +9 -6
  10. package/components/Label/Label.styles.js +1 -1
  11. package/components/NumberInput/NumberInput.styles.js +1 -1
  12. package/components/ObjectLogs/components/DetailFormatter/index.js +2 -2
  13. package/components/PaperForm/styles.js +1 -1
  14. package/components/SideBar/subcomponents/ContentGroups/subcomponents/ContainerMenuItemsMain/styles.js +1 -1
  15. package/components/areas/components/AreasAdmin/AreasAdmin.styles.js +1 -1
  16. package/components/areas/components/AreasViewer/subcomponents/Area/subcomponents/Window/hooks/useHeaderActions/useHeaderActions.js +2 -2
  17. package/components/areas/components/AreasViewer/subcomponents/Area/subcomponents/WindowModal/WindowModal.js +2 -2
  18. package/components/areas/contexts/AreasContext/index.js +2 -2
  19. package/components/extended/React-Spinners/PropagateLoaderSpinner/PropagateLoaderSpinner.styles.js +1 -1
  20. package/components/hook-form/RHFAutocomplete/RHFAutocomplete.js +2 -2
  21. package/components/hook-form/RHFTextFieldPassword/RHFTextFieldPassword.styles.js +1 -1
  22. package/components/mui_extended/Autocomplete/Autocomplete.styles.js +1 -1
  23. package/components/mui_extended/CheckBox/CheckBox.styles.js +1 -1
  24. package/components/mui_extended/DateTimePicker/DateTimePicker.styles.js +1 -1
  25. package/components/mui_extended/IconButton/IconButton.d.ts +2 -1
  26. package/components/mui_extended/IconButton/IconButton.js +18 -20
  27. package/components/mui_extended/IconButton/IconButton.styles.js +118 -162
  28. package/components/mui_extended/IconButton/types.d.ts +3 -4
  29. package/components/mui_extended/MenuDivider/MenuDivider.styles.js +1 -1
  30. package/components/mui_extended/MenuItem/MenuItem.js +27 -20
  31. package/components/mui_extended/MenuItem/MenuItem.styles.js +1 -1
  32. package/components/mui_extended/MenuItem/slots/MenuItemSlots.js +6 -6
  33. package/components/mui_extended/NavLink/NavLink.styles.js +1 -1
  34. package/components/mui_extended/Select/Select.styles.js +1 -3
  35. package/components/mui_extended/TextField/TextField.styles.js +1 -1
  36. package/components/mui_extended/Typography/typography.styles.js +1 -2
  37. package/components/popups/components/PopupsProvider/hooks/useHeaderActionsPopups/useHeaderActionsPopups.js +2 -2
  38. package/index.js +7 -7
  39. package/package.json +4 -4
  40. package/utils/getSizeStyles/getSizeStyles.d.ts +1 -2
  41. package/utils/getSizeStyles/getSizeStyles.js +4 -4
@@ -1,10 +1,10 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import { useModuleSkeleton, useEnvironment } from "@m4l/core";
3
3
  import clsx from "clsx";
4
- import { forwardRef } from "react";
4
+ import { forwardRef, useMemo } from "react";
5
5
  import { C as CHIP_CLASSES } from "./constants.js";
6
6
  import { u as useComponentSize } from "../../hooks/useComponentSize/useComponentSize.js";
7
- import { S as SkeletonChipStyled, C as ChipRootStyled, T as TextChipStyled, I as IconButtonStyled, a as IconStyled } from "./slots/ChipSlots.js";
7
+ import { I as IconStyled, S as SkeletonChipStyled, C as ChipRootStyled, T as TextChipStyled, a as IconButtonStyled } from "./slots/ChipSlots.js";
8
8
  const Chip = forwardRef((props, ref) => {
9
9
  const {
10
10
  endIcon,
@@ -26,30 +26,16 @@ const Chip = forwardRef((props, ref) => {
26
26
  const isSkeleton = useModuleSkeleton();
27
27
  const { host_static_assets, environment_assets } = useEnvironment();
28
28
  const adjustedSize = currentSize === "small" || currentSize === "medium" ? currentSize : "medium";
29
- const ownerState = {
29
+ const ownerState = useMemo(() => ({
30
30
  interactive: !!onClick,
31
31
  size: adjustedSize,
32
+ chipSize: adjustedSize,
32
33
  variant,
33
34
  color,
34
35
  opacity,
35
36
  externalColor
36
- };
37
- const handleDelete = (e) => {
38
- e.stopPropagation();
39
- onDeleted?.(e);
40
- };
41
- if (isSkeleton) {
42
- return /* @__PURE__ */ jsx(
43
- SkeletonChipStyled,
44
- {
45
- "data-testid": "SkeletonButton",
46
- width: skeletonWidth,
47
- ownerState: { ...ownerState }
48
- }
49
- );
50
- }
51
- const iconClose = `${host_static_assets}/${environment_assets}/frontend/components/chip/assets/icons/closeSmall.svg`;
52
- const renderIcon = (icon, instaceDataTestId) => {
37
+ }), [adjustedSize, variant, color, opacity, externalColor, onClick]);
38
+ const renderIcon = useMemo(() => (icon, instaceDataTestId) => {
53
39
  if (!icon) {
54
40
  return null;
55
41
  }
@@ -59,7 +45,6 @@ const Chip = forwardRef((props, ref) => {
59
45
  return /* @__PURE__ */ jsx(
60
46
  IconStyled,
61
47
  {
62
- color,
63
48
  ownerState: { ...ownerState },
64
49
  src: icon,
65
50
  size: adjustedSize,
@@ -67,6 +52,21 @@ const Chip = forwardRef((props, ref) => {
67
52
  }
68
53
  );
69
54
  }
55
+ }, [ownerState, adjustedSize]);
56
+ if (isSkeleton) {
57
+ return /* @__PURE__ */ jsx(
58
+ SkeletonChipStyled,
59
+ {
60
+ "data-testid": "SkeletonButton",
61
+ width: skeletonWidth,
62
+ ownerState: { ...ownerState }
63
+ }
64
+ );
65
+ }
66
+ const iconClose = `${host_static_assets}/${environment_assets}/frontend/components/chip/assets/icons/closeSmall.svg`;
67
+ const handleDelete = (e) => {
68
+ e.stopPropagation();
69
+ onDeleted?.(e);
70
70
  };
71
71
  return /* @__PURE__ */ jsxs(
72
72
  ChipRootStyled,
@@ -1,4 +1,4 @@
1
- import { g as getHeightSizeStyles } from "../../utils/getSizeStyles/getSizeStyles.js";
1
+ import { g as getSizeStyles } from "../../utils/getSizeStyles/getSizeStyles.js";
2
2
  const getColors = (theme, ownerState) => {
3
3
  const keyColor = ownerState.variant === "contained" ? ownerState.color + "Contained" : ownerState.color + "Outlined";
4
4
  const finalPalette = ownerState.externalColor ? ownerState.externalColor : theme.vars.palette.chips[keyColor ?? "default"];
@@ -24,11 +24,8 @@ const chipStyles = {
24
24
  cursor: "pointer",
25
25
  color,
26
26
  backgroundColor: !(ownerState.variant === "outlined") ? bgColor : "transparent",
27
- // '& .M4LIcon-icon': {
28
- // backgroundColor: `${color} !important`,
29
- // },
30
- ...getHeightSizeStyles(
31
- theme.generalSettings.isMobile,
27
+ ...getSizeStyles(
28
+ theme,
32
29
  ownerState.size || "medium",
33
30
  "base"
34
31
  ),
@@ -81,30 +78,16 @@ const chipStyles = {
81
78
  "& .M4LIcon-icon": {
82
79
  backgroundColor: `${color} !important`
83
80
  },
84
- // Estilos específicos para el tamaño small
85
- ...ownerState.size === "small" && {
86
- ...theme.generalSettings.isMobile ? {
87
- height: theme.vars.size.mobile.small.base,
88
- width: theme.vars.size.mobile.small.base,
89
- minHeight: theme.vars.size.mobile.small.base
90
- } : {
91
- height: theme.vars.size.desktop.small.base,
92
- width: theme.vars.size.desktop.small.base,
93
- minHeight: theme.vars.size.desktop.small.base
94
- }
95
- },
96
- // Estilos específicos para el tamaño medium
97
- ...ownerState.size === "medium" && {
98
- ...theme.generalSettings.isMobile ? {
99
- height: theme.vars.size.mobile.medium.base,
100
- width: theme.vars.size.mobile.medium.base,
101
- minHeight: theme.vars.size.mobile.medium.base
102
- } : {
103
- height: theme.vars.size.desktop.medium.base,
104
- width: theme.vars.size.desktop.medium.base,
105
- minHeight: theme.vars.size.desktop.medium.base
106
- }
107
- }
81
+ ...getSizeStyles(
82
+ theme,
83
+ ownerState.size || "medium",
84
+ "base",
85
+ (size) => ({
86
+ height: size,
87
+ width: size,
88
+ minHeight: size
89
+ })
90
+ )
108
91
  };
109
92
  },
110
93
  /**
@@ -113,26 +96,15 @@ const chipStyles = {
113
96
  skeletonChip: ({ theme, ownerState }) => ({
114
97
  width: "100%",
115
98
  background: theme.vars.palette.skeleton.transition,
116
- // Estilos específicos para el tamaño small
117
- ...ownerState.size === "small" && {
118
- ...theme.generalSettings.isMobile ? {
119
- height: theme.vars.size.mobile.small.base,
120
- minHeight: theme.vars.size.mobile.small.base
121
- } : {
122
- height: theme.vars.size.desktop.small.base,
123
- minHeight: theme.vars.size.desktop.small.base
124
- }
125
- },
126
- // Estilos específicos para el tamaño medium
127
- ...ownerState.size === "medium" && {
128
- ...theme.generalSettings.isMobile ? {
129
- height: theme.vars.size.mobile.medium.base,
130
- minHeight: theme.vars.size.mobile.medium.base
131
- } : {
132
- height: theme.vars.size.desktop.medium.base,
133
- minHeight: theme.vars.size.desktop.medium.base
134
- }
135
- }
99
+ ...getSizeStyles(
100
+ theme,
101
+ ownerState.size || "medium",
102
+ "base",
103
+ (size) => ({
104
+ height: size,
105
+ minHeight: size
106
+ })
107
+ )
136
108
  })
137
109
  };
138
110
  export {
@@ -28,8 +28,8 @@ const IconButtonStyled = styled(IconButton, {
28
28
  })(chipStyles?.iconButton);
29
29
  export {
30
30
  ChipRootStyled as C,
31
- IconButtonStyled as I,
31
+ IconStyled as I,
32
32
  SkeletonChipStyled as S,
33
33
  TextChipStyled as T,
34
- IconStyled as a
34
+ IconButtonStyled as a
35
35
  };
@@ -63,7 +63,7 @@ export interface ChipProps {
63
63
  */
64
64
  className?: string;
65
65
  /**
66
- * Focusable `Chip`.
66
+ * If the `Chip` is focusable.
67
67
  */
68
68
  focusable?: boolean;
69
69
  }
@@ -3,7 +3,7 @@ import { createContext, useRef, useEffect } from "react";
3
3
  import { useStore } from "zustand";
4
4
  import { shallow } from "zustand/shallow";
5
5
  import { useModuleDictionary, useEnvironment, useModuleSkeleton } from "@m4l/core";
6
- import { useResponsiveDesktop, useFirstRender } from "@m4l/graphics";
6
+ import { useIsMobile, useFirstRender } from "@m4l/graphics";
7
7
  import { c as createDynamicFilterStore } from "./DynamicFilterStore.js";
8
8
  import { A as ALL_FIELD } from "../constants.js";
9
9
  import { f as formatToRawFilter } from "../helpers/formatToRowFilter.js";
@@ -24,7 +24,7 @@ function DynamicFilterProvider(props) {
24
24
  const { getLabel } = useModuleDictionary();
25
25
  const dynamicFilterStoreRef = useRef();
26
26
  const { host_static_assets, environment_assets } = useEnvironment();
27
- const isDesktop = useResponsiveDesktop();
27
+ const isDesktop = !useIsMobile();
28
28
  const isSkeleton = useModuleSkeleton();
29
29
  const isFirstRender = useFirstRender([isDesktop, isSkeleton]);
30
30
  if (!dynamicFilterStoreRef.current) {
@@ -1,6 +1,6 @@
1
1
  import { c as containerQuery } from "../../utils/containerQuery.js";
2
2
  import { g as getTypographyStyles } from "../../utils/getTypographyStyles.js";
3
- import { a as getSizeStyles } from "../../utils/getSizeStyles/getSizeStyles.js";
3
+ import { g as getSizeStyles } from "../../utils/getSizeStyles/getSizeStyles.js";
4
4
  const CONTAINER_QUERY_NAME = "dynamic";
5
5
  const dynamicSortStyles = {
6
6
  /**
@@ -55,13 +55,12 @@ const dynamicSortStyles = {
55
55
  overflow: "hidden",
56
56
  ...getSizeStyles(
57
57
  theme,
58
- theme.generalSettings.isMobile,
59
58
  ownerState.size || "medium",
60
59
  "container",
61
- (height) => ({
62
- height,
63
- minHeight: height,
64
- maxHeight: height
60
+ (size) => ({
61
+ height: size,
62
+ minHeight: size,
63
+ maxHeight: size
65
64
  })
66
65
  ),
67
66
  maxWidth: "135px",
@@ -81,13 +80,12 @@ const dynamicSortStyles = {
81
80
  inputSortInput: ({ theme, ownerState }) => ({
82
81
  ...getSizeStyles(
83
82
  theme,
84
- theme.generalSettings.isMobile,
85
83
  ownerState.size || "medium",
86
84
  "action",
87
- (height) => ({
88
- height,
89
- minHeight: height,
90
- maxHeight: height
85
+ (size) => ({
86
+ height: size,
87
+ minHeight: size,
88
+ maxHeight: size
91
89
  })
92
90
  ),
93
91
  ...getTypographyStyles(
@@ -314,13 +312,12 @@ const dynamicSortStyles = {
314
312
  marginRight: theme.vars.size.baseSpacings.sp2,
315
313
  ...getSizeStyles(
316
314
  theme,
317
- theme.generalSettings.isMobile,
318
315
  ownerState.size || "medium",
319
316
  "base",
320
- (height) => ({
321
- height,
322
- minHeight: height,
323
- maxHeight: height
317
+ (size) => ({
318
+ height: size,
319
+ minHeight: size,
320
+ maxHeight: size
324
321
  })
325
322
  )
326
323
  })
@@ -17,16 +17,21 @@ const Icon = (props) => {
17
17
  className,
18
18
  placement = "bottom",
19
19
  instaceDataTestId,
20
- disabled
20
+ disabled,
21
+ selected,
22
+ enabledSelected
21
23
  } = props;
22
24
  const { currentSize } = useComponentSize(size);
25
+ const adjustedSize = currentSize === "small" || currentSize === "medium" ? currentSize : "medium";
23
26
  const isSkeleton = useModuleSkeleton();
24
27
  const ownerState = {
25
- iconSize: currentSize,
26
- iconColor: color,
27
- iconSrc: src,
28
- iconDisabled: disabled,
29
- iconRotationAngle: rotationAngle,
28
+ size: adjustedSize,
29
+ color,
30
+ src,
31
+ disabled,
32
+ rotationAngle,
33
+ selected,
34
+ enabledSelected,
30
35
  isSkeleton
31
36
  };
32
37
  const classKey = getComponentClasses(ICON_KEY_COMPONENT, IconSlots);
@@ -38,6 +43,7 @@ const Icon = (props) => {
38
43
  title: tooltipContent,
39
44
  ownerState: { ...ownerState },
40
45
  placement,
46
+ size: adjustedSize,
41
47
  ...getPropDataTestId(ICON_PREFIX, IconSlots.tooltip, instaceDataTestId),
42
48
  children: /* @__PURE__ */ jsx(
43
49
  RootStyled,
@@ -74,7 +80,7 @@ const Icon = (props) => {
74
80
  )
75
81
  }
76
82
  ),
77
- isSkeleton && /* @__PURE__ */ jsx(IconSkeletonStyled, { className: classKey.iconSkeleton, role: "icon-skeleton", variant: "rectangular", ownerState: { ...ownerState } })
83
+ isSkeleton && /* @__PURE__ */ jsx(IconSkeletonStyled, { className: classKey.iconSkeleton, role: "icon-skeleton", size: adjustedSize, variant: "rectangular", ownerState: { ...ownerState } })
78
84
  ] });
79
85
  };
80
86
  export {
@@ -14,7 +14,7 @@ const iconStyles = {
14
14
  alignItems: "center",
15
15
  width: "fit-content",
16
16
  transition: "transform 0.5s ease-in-out",
17
- ...ownerState.iconSize === "medium" && {
17
+ ...ownerState.size === "medium" && {
18
18
  ...theme.generalSettings.isMobile ? {
19
19
  width: theme.vars.size.mobile.medium.base,
20
20
  height: theme.vars.size.mobile.medium.base
@@ -23,7 +23,7 @@ const iconStyles = {
23
23
  height: theme.vars.size.desktop.medium.base
24
24
  }
25
25
  },
26
- ...ownerState.iconSize === "small" && {
26
+ ...ownerState.size === "small" && {
27
27
  ...theme.generalSettings.isMobile ? {
28
28
  width: theme.vars.size.mobile.small.base,
29
29
  height: theme.vars.size.mobile.small.base
@@ -40,22 +40,25 @@ const iconStyles = {
40
40
  * del ícono basada en el ángulo de rotación proporcionado, y el color de fondo que
41
41
  * se ajusta de acuerdo con el estado de deshabilitación o no del ícono.
42
42
  */
43
- icon: ({ theme, ownerState }) => ({
44
- maskPosition: "center",
45
- maskRepeat: "no-repeat",
46
- maskSize: "cover",
47
- WebkitMaskRepeat: "no-repeat",
48
- mask: `url(${ownerState.iconSrc})`,
49
- WebkitMask: `url(${ownerState.iconSrc})`,
50
- WebkitMaskSize: "cover",
51
- ...ownerState.iconRotationAngle && {
52
- transform: `rotate(${ownerState.iconRotationAngle}deg)`
53
- },
54
- backgroundColor: !ownerState.iconDisabled ? getPropertyByString(theme.vars.palette, String(ownerState.iconColor) || "text.primary") : theme.vars.palette.text.disabled,
55
- width: "inherit",
56
- height: "inherit",
57
- variants: []
58
- }),
43
+ icon: ({ theme, ownerState }) => {
44
+ const backgroundColor = ownerState.disabled ? theme.vars.palette.text.disabled : ownerState.selected && ownerState.enabledSelected ? `${theme.vars.palette.primary.selected} !important` : getPropertyByString(theme.vars.palette, String(ownerState.color), "text.primary");
45
+ return {
46
+ maskPosition: "center",
47
+ maskRepeat: "no-repeat",
48
+ maskSize: "cover",
49
+ WebkitMaskRepeat: "no-repeat",
50
+ mask: `url(${ownerState.src})`,
51
+ WebkitMask: `url(${ownerState.src})`,
52
+ WebkitMaskSize: "cover",
53
+ ...ownerState.rotationAngle && {
54
+ transform: `rotate(${ownerState.rotationAngle}deg)`
55
+ },
56
+ backgroundColor,
57
+ width: "inherit",
58
+ height: "inherit",
59
+ variants: []
60
+ };
61
+ },
59
62
  /**
60
63
  * Slot iconSkeleton: Define los estilos para el esqueleto del ícono.
61
64
  * Se utiliza cuando el ícono aún no está completamente cargado, proporcionando
@@ -65,7 +68,7 @@ const iconStyles = {
65
68
  iconSkeleton: ({ theme, ownerState }) => ({
66
69
  "&.M4lclassCssSpecificity": {
67
70
  borderRadius: theme.size.borderRadius.r1,
68
- ...ownerState.iconSize === "medium" && {
71
+ ...ownerState.size === "medium" && {
69
72
  ...theme.generalSettings.isMobile ? {
70
73
  width: theme.vars.size.mobile.medium.base,
71
74
  height: theme.vars.size.mobile.medium.base
@@ -74,7 +77,7 @@ const iconStyles = {
74
77
  height: theme.vars.size.desktop.medium.base
75
78
  }
76
79
  },
77
- ...ownerState.iconSize === "small" && {
80
+ ...ownerState.size === "small" && {
78
81
  ...theme.generalSettings.isMobile ? {
79
82
  width: theme.vars.size.mobile.small.base,
80
83
  height: theme.vars.size.mobile.small.base
@@ -43,16 +43,19 @@ export interface IconProps extends Pick<TooltipProps, 'placement'> {
43
43
  * Valor que en caso de ser verdadero debe de pintar el svg con color text disabled.
44
44
  */
45
45
  disabled?: boolean;
46
+ /**
47
+ * Valor que define si el icono debe de estar seleccionado pero depende de la propiedad enableSelected.
48
+ */
49
+ selected?: boolean;
50
+ /**
51
+ * Valor que define si el icono debe de estar seleccionado pero depende de la propiedad selected.
52
+ */
53
+ enabledSelected?: boolean;
46
54
  }
47
55
  /**
48
56
  * Define las las propiedades usadas para estilizar el componente desde el css.
49
57
  */
50
- export interface IconOwnerState {
51
- iconSize: Sizes;
52
- iconRotationAngle?: number;
53
- iconColor: IconColors;
54
- iconDisabled?: boolean;
55
- iconSrc: string;
58
+ export interface IconOwnerState extends Pick<IconProps, 'selected' | 'enabledSelected' | 'size' | 'rotationAngle' | 'color' | 'disabled' | 'src'> {
56
59
  isSkeleton: boolean;
57
60
  }
58
61
  export type IconSlotsType = keyof typeof IconSlots;
@@ -1,5 +1,5 @@
1
1
  import { g as getTypographyStyles } from "../../utils/getTypographyStyles.js";
2
- import { g as getHeightSizeStyles } from "../../utils/getSizeStyles/getSizeStyles.js";
2
+ import { a as getHeightSizeStyles } from "../../utils/getSizeStyles/getSizeStyles.js";
3
3
  const labelStyles = {
4
4
  /**
5
5
  * Estilos para el contenedor raíz del Label 🏷️
@@ -1,5 +1,5 @@
1
1
  import { g as getTypographyStyles } from "../../utils/getTypographyStyles.js";
2
- import { g as getHeightSizeStyles } from "../../utils/getSizeStyles/getSizeStyles.js";
2
+ import { a as getHeightSizeStyles } from "../../utils/getSizeStyles/getSizeStyles.js";
3
3
  const numberInputStyles = {
4
4
  /**
5
5
  * Estilos aplicados al contenedor principal (root).
@@ -4,7 +4,7 @@ import { D as DetailDialog } from "../DetailDialog/index.js";
4
4
  import { u as useModal } from "../../../../hooks/useModal/index.js";
5
5
  import { useModuleDictionary, useEnvironment } from "@m4l/core";
6
6
  import { I as Icon } from "../../../Icon/Icon.js";
7
- import { useResponsiveDesktop } from "@m4l/graphics";
7
+ import { useIsMobile } from "@m4l/graphics";
8
8
  import { S as Stack } from "../../../mui_extended/Stack/Stack.js";
9
9
  import { W as WindowBase } from "../../../WindowBase/WindowBase.js";
10
10
  function DetailFormatter(props) {
@@ -12,7 +12,7 @@ function DetailFormatter(props) {
12
12
  const { openModal } = useModal();
13
13
  const { getLabel } = useModuleDictionary();
14
14
  const { host_static_assets, environment_assets } = useEnvironment();
15
- const isDesktop = useResponsiveDesktop();
15
+ const isDesktop = !useIsMobile();
16
16
  const onClickDetail = () => {
17
17
  openModal({
18
18
  // onQueryClose: () => closeModal(),
@@ -1,4 +1,4 @@
1
- import { g as getHeightSizeStyles } from "../../utils/getSizeStyles/getSizeStyles.js";
1
+ import { a as getHeightSizeStyles } from "../../utils/getSizeStyles/getSizeStyles.js";
2
2
  const paperFormStyles = {
3
3
  /**
4
4
  *************************************************************
@@ -1,4 +1,4 @@
1
- import { g as getHeightSizeStyles } from "../../../../../../utils/getSizeStyles/getSizeStyles.js";
1
+ import { a as getHeightSizeStyles } from "../../../../../../utils/getSizeStyles/getSizeStyles.js";
2
2
  import { a as ITEM_IN_TREE_ACTIVE, I as ITEM_ACTIVE } from "../../../../constants.js";
3
3
  const containerMenuItemsMainStyles = {
4
4
  /**
@@ -1,4 +1,4 @@
1
- import { g as getHeightSizeStyles } from "../../../../utils/getSizeStyles/getSizeStyles.js";
1
+ import { a as getHeightSizeStyles } from "../../../../utils/getSizeStyles/getSizeStyles.js";
2
2
  const areasAdminStyles = {
3
3
  /**
4
4
  * Root areas admin Styles
@@ -5,7 +5,7 @@ import { I as ICONS } from "../../../../../../../../icons.js";
5
5
  import { g as getAreasDictionary, A as AREAS_DICCTIONARY } from "../../../../../../../../dictionary.js";
6
6
  import { g as getMainActions, a as getMenuActions } from "./helper.js";
7
7
  import { shallow } from "zustand/shallow";
8
- import { useResponsiveDesktop } from "@m4l/graphics";
8
+ import { useIsMobile } from "@m4l/graphics";
9
9
  const useHeaderActions = ({
10
10
  windowId,
11
11
  areaId,
@@ -13,7 +13,7 @@ const useHeaderActions = ({
13
13
  }) => {
14
14
  const { host_static_assets, environment_assets } = useEnvironment();
15
15
  const { getLabel } = useModuleDictionary();
16
- const isDesktop = useResponsiveDesktop();
16
+ const isDesktop = !useIsMobile();
17
17
  const urlPrefix = `${host_static_assets}/${environment_assets}`;
18
18
  const moduleActions = useAreasStore(
19
19
  (state) => {
@@ -4,12 +4,12 @@ import { R as ResizableBox } from "../../../../../../../extended/React-Resizable
4
4
  import { u as useAreasStore } from "../../../../../../hooks/useAreas/index.js";
5
5
  import { W as Window } from "../Window/Window.js";
6
6
  import Draggable from "react-draggable";
7
- import { useResponsiveDesktop } from "@m4l/graphics";
7
+ import { useIsMobile } from "@m4l/graphics";
8
8
  import { b as WrapperWindowModalStyled } from "../../../../slots/AreasViewerSlots.js";
9
9
  const WindowModal = (props) => {
10
10
  const { windowId } = props;
11
11
  const { onClose } = useAreasStore((state) => state.hashWindowsModals[windowId]);
12
- const isDesktop = useResponsiveDesktop();
12
+ const isDesktop = !useIsMobile();
13
13
  const DragabblePaperComponent = (_props) => {
14
14
  return /* @__PURE__ */ jsx(
15
15
  Draggable,
@@ -2,7 +2,7 @@ import { jsx } from "react/jsx-runtime";
2
2
  import { createContext, useRef, useCallback, useEffect } from "react";
3
3
  import { useStore } from "zustand";
4
4
  import { shallow } from "zustand/shallow";
5
- import { useResponsiveDesktop, useFirstRender } from "@m4l/graphics";
5
+ import { useIsMobile, useFirstRender } from "@m4l/graphics";
6
6
  import { useHostTools, useModuleDictionary, useNetwork, useModuleSkeleton, useFlagsStore, CommonFlags, EmitEvents } from "@m4l/core";
7
7
  import { c as createAreasStore } from "./store.js";
8
8
  const AreasContext = createContext(null);
@@ -11,7 +11,7 @@ function AreasProvider(props) {
11
11
  const { events_add_listener, events_remove_listener } = useHostTools();
12
12
  const { getLabel } = useModuleDictionary();
13
13
  const { networkOperation } = useNetwork();
14
- const isDesktop = useResponsiveDesktop();
14
+ const isDesktop = !useIsMobile();
15
15
  const isSkeleton = useModuleSkeleton();
16
16
  const isFirstRender = useFirstRender([getLabel]);
17
17
  const { addFlag } = useFlagsStore((state) => state.flagsActions);
@@ -1,4 +1,4 @@
1
- import { g as getHeightSizeStyles } from "../../../../utils/getSizeStyles/getSizeStyles.js";
1
+ import { a as getHeightSizeStyles } from "../../../../utils/getSizeStyles/getSizeStyles.js";
2
2
  const propagateLoaderSpinnerStyles = {
3
3
  /**
4
4
  * Estilos del componente raíz del contenedor de la ventana.
@@ -1,6 +1,6 @@
1
1
  import { jsx, jsxs, Fragment } from "react/jsx-runtime";
2
2
  import { getPropertyByString } from "@m4l/core";
3
- import { useResponsiveDesktop } from "@m4l/graphics";
3
+ import { useIsMobile } from "@m4l/graphics";
4
4
  import { useTheme } from "@mui/material";
5
5
  import { useState, useEffect } from "react";
6
6
  import { useFormContext, Controller } from "react-hook-form";
@@ -32,7 +32,7 @@ function RHFAutocomplete(props) {
32
32
  } = props;
33
33
  const theme = useTheme();
34
34
  const [open, setOpen] = useState(false);
35
- const isDesktop = useResponsiveDesktop();
35
+ const isDesktop = !useIsMobile();
36
36
  const onCloseLocal = (event, reason) => {
37
37
  setOpen(false);
38
38
  if (onClose) {
@@ -1,4 +1,4 @@
1
- import { g as getHeightSizeStyles } from "../../../utils/getSizeStyles/getSizeStyles.js";
1
+ import { a as getHeightSizeStyles } from "../../../utils/getSizeStyles/getSizeStyles.js";
2
2
  const rhfTextFieldPasswordStyles = {
3
3
  /**
4
4
  * Elemento Root
@@ -1,4 +1,4 @@
1
- import { g as getHeightSizeStyles } from "../../../utils/getSizeStyles/getSizeStyles.js";
1
+ import { a as getHeightSizeStyles } from "../../../utils/getSizeStyles/getSizeStyles.js";
2
2
  const autocompleteSyles = {
3
3
  /**
4
4
  * Styles for the root component.
@@ -1,4 +1,4 @@
1
- import { g as getHeightSizeStyles } from "../../../utils/getSizeStyles/getSizeStyles.js";
1
+ import { a as getHeightSizeStyles } from "../../../utils/getSizeStyles/getSizeStyles.js";
2
2
  const checkBoxStyles = {
3
3
  /**
4
4
  * Estilos generales para el checkbox 🟦
@@ -1,5 +1,5 @@
1
1
  import { g as getTypographyStyles } from "../../../utils/getTypographyStyles.js";
2
- import { g as getHeightSizeStyles } from "../../../utils/getSizeStyles/getSizeStyles.js";
2
+ import { a as getHeightSizeStyles } from "../../../utils/getSizeStyles/getSizeStyles.js";
3
3
  const dateTimePickerStyles = {
4
4
  /**
5
5
  * Estilos para el root cuando esta en Desktop 💻
@@ -1,7 +1,8 @@
1
+ import { default as React } from 'react';
1
2
  import { IconButtonProps } from './types';
2
3
  /**
3
4
  *Los Icon button son habitualmente ubicados en barras de aplicaciones y barras de herramientas. Además, resulta adecuado emplear iconos en botones de alternancia que posibilitan la selección o deselección de una única opción, como añadir o eliminar una estrella a un elemento.
4
5
  * @param props
5
6
  * @returns
6
7
  */
7
- export declare const IconButton: import('react').ForwardRefExoticComponent<Omit<IconButtonProps, "ref"> & import('react').RefAttributes<HTMLButtonElement>>;
8
+ export declare const IconButton: React.ForwardRefExoticComponent<Omit<IconButtonProps, "ref"> & React.RefAttributes<HTMLButtonElement>>;