@m4l/components 9.2.62-B08072025beta.2 → 9.2.62-B09072025beta.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 (108) hide show
  1. package/@types/types.d.ts +8 -0
  2. package/components/AppBar/AppBar.js +10 -12
  3. package/components/AppBar/constants.d.ts +1 -1
  4. package/components/AppBar/constants.js +1 -1
  5. package/components/AppBar/slots/AppBarEnum.d.ts +5 -1
  6. package/components/AppBar/slots/AppBarEnum.js +4 -0
  7. package/components/AppBar/slots/AppBarSlots.d.ts +18 -4
  8. package/components/AppBar/slots/AppBarSlots.js +27 -3
  9. package/components/AppBar/styles.js +42 -0
  10. package/components/AppBar/types.d.ts +0 -8
  11. package/components/ContainerFlow/ContainerFlow.d.ts +7 -0
  12. package/components/ContainerFlow/ContainerFlow.js +25 -0
  13. package/components/ContainerFlow/ContainerFlow.styles.d.ts +2 -0
  14. package/components/ContainerFlow/ContainerFlow.styles.js +46 -0
  15. package/components/ContainerFlow/constants.d.ts +8 -0
  16. package/components/ContainerFlow/constants.js +19 -0
  17. package/components/ContainerFlow/helpers/getSpacingValue/getSpacingValue.d.ts +7 -0
  18. package/components/ContainerFlow/helpers/getSpacingValue/getSpacingValue.js +10 -0
  19. package/components/ContainerFlow/helpers/getSpacingValue/getSpacingValue.test.d.ts +1 -0
  20. package/components/ContainerFlow/index.d.ts +2 -0
  21. package/components/ContainerFlow/slots/ContainerFlowEnum.d.ts +4 -0
  22. package/components/ContainerFlow/slots/ContainerFlowEnum.js +8 -0
  23. package/components/ContainerFlow/slots/ContainerFlowSlots.d.ts +6 -0
  24. package/components/ContainerFlow/slots/ContainerFlowSlots.js +16 -0
  25. package/components/ContainerFlow/slots/index.d.ts +0 -0
  26. package/components/ContainerFlow/tests/ContainerFlow.test.d.ts +1 -0
  27. package/components/ContainerFlow/types.d.ts +41 -0
  28. package/components/Image/Image.js +4 -2
  29. package/components/Image/image.styles.js +6 -3
  30. package/components/Image/types.d.ts +2 -0
  31. package/components/LoadingError/slots/LoadingErrorSlots.js +1 -1
  32. package/components/PropertyValue/PropertyValue.styles.js +1 -1
  33. package/components/SideBar/SideBar.js +2 -6
  34. package/components/SideBar/constants.d.ts +6 -7
  35. package/components/SideBar/constants.js +7 -7
  36. package/components/SideBar/context/sideBarContext/index.js +10 -9
  37. package/components/SideBar/context/sideBarContext/types.d.ts +10 -2
  38. package/components/SideBar/slots/SideBarEnum.d.ts +7 -7
  39. package/components/SideBar/slots/SideBarEnum.js +5 -5
  40. package/components/SideBar/slots/SideBarSlots.d.ts +9 -9
  41. package/components/SideBar/slots/SideBarSlots.js +28 -31
  42. package/components/SideBar/styles.js +3 -3
  43. package/components/SideBar/subcomponents/ContentComponent/index.js +68 -12
  44. package/components/SideBar/subcomponents/ContentComponent/style.js +103 -103
  45. package/components/SideBar/subcomponents/HeaderSidebar/index.d.ts +6 -0
  46. package/components/SideBar/subcomponents/HeaderSidebar/styles.d.ts +2 -0
  47. package/components/SideBar/subcomponents/HeaderSidebar/styles.js +24 -0
  48. package/components/SideBar/subcomponents/HeaderSidebar/types.d.ts +5 -0
  49. package/components/SideBar/subcomponents/{FooterComponent → Promotion}/index.d.ts +1 -1
  50. package/components/SideBar/subcomponents/{FooterComponent → Promotion}/index.js +4 -4
  51. package/components/SideBar/subcomponents/{FooterComponent → Promotion}/styles.js +1 -7
  52. package/components/SideBar/subcomponents/SideBarDesktop/index.js +3 -4
  53. package/components/SideBar/subcomponents/SideBarDesktop/styles.js +32 -4
  54. package/components/SideBar/subcomponents/SideBarMobile/index.js +1 -1
  55. package/components/SideBar/subcomponents/TreeGroupItems/index.js +3 -4
  56. package/components/SideBar/subcomponents/TreeGroupItems/styles.js +2 -90
  57. package/components/SideBar/subcomponents/TreeGroupItems/subcomponents/NodeMenuItem/index.js +4 -6
  58. package/components/SideBar/subcomponents/TreeGroupItems/subcomponents/NodeMenuItem/types.d.ts +0 -1
  59. package/components/SideBar/subcomponents/TreeGroupItems/subcomponents/NodeMenuItemMain/NodeMenuItemMain.js +3 -8
  60. package/components/SideBar/types.d.ts +7 -12
  61. package/components/commercial/HamburgerMenu/HamburgerMenu.js +2 -1
  62. package/components/hook-form/RHFPeriod/subcomponents/Period/dictionary.js +4 -5
  63. package/components/index.d.ts +1 -0
  64. package/components/mui_extended/Accordion/styles.js +3 -5
  65. package/components/mui_extended/TabContent/TabContent.js +2 -2
  66. package/components/mui_extended/TabContent/TabContent.styles.js +4 -1
  67. package/components/mui_extended/TabContent/constants.d.ts +1 -0
  68. package/components/mui_extended/TabContent/constants.js +2 -0
  69. package/components/mui_extended/TabContent/types.d.ts +1 -1
  70. package/components/mui_extended/Typography/Typography.js +3 -1
  71. package/components/mui_extended/Typography/types.d.ts +5 -0
  72. package/components/mui_extended/Typography/typography.styles.js +7 -1
  73. package/index.js +32 -30
  74. package/package.json +3 -3
  75. package/storybook/components/ContainerFlow/ContainerFlow.stories.d.ts +32 -0
  76. package/storybook/components/ContainerFlow/subcomponents/RenderFlexColumn/index.d.ts +5 -0
  77. package/storybook/components/ContainerFlow/subcomponents/RenderFlexColumn1Wrappers/index.d.ts +5 -0
  78. package/storybook/components/ContainerFlow/subcomponents/RenderFlexColumn2Wrappers/index.d.ts +5 -0
  79. package/storybook/components/ContainerFlow/subcomponents/RenderFlexColumn3Wrappers/index.d.ts +5 -0
  80. package/storybook/components/ContainerFlow/subcomponents/RenderFlexWrap/index.d.ts +5 -0
  81. package/storybook/components/ContainerFlow/subcomponents/RenderGridLayout/index.d.ts +5 -0
  82. package/storybook/components/ContainerFlow/wrapperItems/index.d.ts +10 -0
  83. package/storybook/components/SideBar/SideBar.stories.d.ts +11 -5
  84. package/storybook/components/SideBar/subcomponents/FooterPromotion/FooterPromotion.d.ts +4 -0
  85. package/storybook/components/SideBar/subcomponents/FooterPromotion/index.d.ts +1 -0
  86. package/utils/getSizeStyles/getSizeStyles.d.ts +1 -1
  87. package/components/SideBar/subcomponents/HeaderComponent/HeaderComponent.d.ts +0 -5
  88. package/components/SideBar/subcomponents/HeaderComponent/HeaderComponent.js +0 -37
  89. package/components/SideBar/subcomponents/HeaderComponent/index.d.ts +0 -1
  90. package/components/SideBar/subcomponents/HeaderComponent/styles.d.ts +0 -2
  91. package/components/SideBar/subcomponents/HeaderComponent/styles.js +0 -44
  92. package/components/SideBar/subcomponents/TreeGroupItems/subcomponents/AdormentIcon/AdormentIcon.d.ts +0 -7
  93. package/components/SideBar/subcomponents/TreeGroupItems/subcomponents/AdormentIcon/AdormentIcon.js +0 -12
  94. package/components/SideBar/subcomponents/TreeGroupItems/subcomponents/AdormentIcon/types.d.ts +0 -4
  95. package/storybook/components/SideBar/subcomponents/FooterComponentHost/FooterComponentHost.d.ts +0 -4
  96. package/storybook/components/SideBar/subcomponents/FooterComponentHost/index.d.ts +0 -1
  97. package/storybook/components/SideBar/subcomponents/FooterComponentMicrofrontend/FooterComponentMicrofrontend.d.ts +0 -4
  98. package/storybook/components/SideBar/subcomponents/FooterComponentMicrofrontend/FooterComponentMicrofrontend.stories.d.ts +0 -14
  99. package/storybook/components/SideBar/subcomponents/FooterComponentMicrofrontend/constants.d.ts +0 -1
  100. package/storybook/components/SideBar/subcomponents/FooterComponentMicrofrontend/index.d.ts +0 -1
  101. package/storybook/components/SideBar/subcomponents/HeaderComponentHost/HeaderComponentHost.d.ts +0 -5
  102. package/storybook/components/SideBar/subcomponents/HeaderComponentHost/constants.d.ts +0 -1
  103. package/storybook/components/SideBar/subcomponents/HeaderComponentMicrofrontend/HeaderComponentMicrofrontend.d.ts +0 -5
  104. package/storybook/components/SideBar/subcomponents/HeaderComponentMicrofrontend/constants.d.ts +0 -1
  105. /package/components/{SideBar/subcomponents/HeaderComponent → ContainerFlow}/index.js +0 -0
  106. /package/components/SideBar/subcomponents/{FooterComponent → Promotion}/styles.d.ts +0 -0
  107. /package/components/SideBar/subcomponents/{FooterComponent → Promotion}/types.d.ts +0 -0
  108. /package/storybook/components/SideBar/subcomponents/{FooterComponentHost → FooterPromotion}/constants.d.ts +0 -0
@@ -85,7 +85,7 @@ const propertyValueStyles = {
85
85
  width: "100%",
86
86
  display: "flex",
87
87
  justifyContent: "flex-start",
88
- alignItems: "center",
88
+ alignItems: "flex-start",
89
89
  overflow: "hidden",
90
90
  height: ownerState?.valueHeight ? ownerState?.valueHeight : "auto",
91
91
  ...ownerState?.isForm && {
@@ -24,9 +24,7 @@ const SideBar = memo((props) => {
24
24
  companyName,
25
25
  companySlogan,
26
26
  urlIconPrefix = `${host_static_assets}/${environment_assets}${PATH_ICONS}`,
27
- headerComponent,
28
- footerComponent,
29
- variant = "host"
27
+ promotion
30
28
  } = props;
31
29
  const menuDataWithState = useMemo(() => getMenuDataWithState({ menuData: menuData ?? getDataToSkeleton(), moduleSelectedId }), [menuData, moduleSelectedId]);
32
30
  const isMobile = useIsMobile();
@@ -48,9 +46,7 @@ const SideBar = memo((props) => {
48
46
  companyName,
49
47
  companySlogan,
50
48
  urlIconPrefix,
51
- variant,
52
- headerComponent,
53
- footerComponent
49
+ promotion
54
50
  },
55
51
  children: !isMobile ? /* @__PURE__ */ jsx(SideBarDesktop, {}) : /* @__PURE__ */ jsx(SideBarMobile, {})
56
52
  }
@@ -4,30 +4,29 @@ export declare const CONTAINER_BTN_ANCHORED = "M4LSideBarButtonAnchored";
4
4
  export declare const LIST_MENU_ITEM = "M4LListMenuItem";
5
5
  export declare const PATH_ICONS = "/frontend/domain/microfrontends/";
6
6
  export declare const PATH_ARROW_DOWN_ICON = "frontend/components/sidebar/assets/icons/ChevronRight.svg";
7
- export declare const PATH_ARROW_RIGHT_ICON = "frontend/components/sidebar/assets/icons/panel-left-close.svg";
7
+ export declare const PATH_ARROW_RIGHT_ICON = "frontend/components/sidebar/assets/icons/arrow_right.svg";
8
8
  export declare const ALL_SIDEBAR_SLOTS: {
9
9
  contentComponentRoot: ContentComponentSlots.contentComponentRoot;
10
- containerTreeItemsHeaderFooter: ContentComponentSlots.containerTreeItemsHeaderFooter;
10
+ contentComponentHide: ContentComponentSlots.contentComponentHide;
11
+ containerTreeItemsAndPromotion: ContentComponentSlots.containerTreeItemsAndPromotion;
11
12
  containerNodeMenuItem: ContentComponentSlots.containerNodeMenuItem;
12
13
  containerNodeMenuItemMain: ContentComponentSlots.containerNodeMenuItemMain;
13
14
  menuItemMain: ContentComponentSlots.menuItemMain;
14
15
  containerFooter: SideBarFooterSlots.containerFooter;
15
- headerContainerComponent: HeaderSidebarSlots.headerContainerComponent;
16
- buttonAnchored: HeaderSidebarSlots.buttonAnchored;
16
+ containerHeaderSidebarRoot: HeaderSidebarSlots.containerHeaderSidebarRoot;
17
+ containerTitleSubtitle: HeaderSidebarSlots.containerTitleSubtitle;
17
18
  containerTreeGroupItems: ContentGroupsSlots.containerTreeGroupItems;
18
19
  containerContentGroups: ContentGroupsSlots.containerContentGroups;
19
20
  containerContentTitle: ContentGroupsSlots.containerContentTitle;
20
21
  containerContentNavItems: ContentGroupsSlots.containerContentNavItems;
21
22
  containerContentItem: ContentGroupsSlots.containerContentItem;
22
23
  containerArrowIconRoot: ContentGroupsSlots.containerArrowIconRoot;
23
- containerAdornmentIcon: ContentGroupsSlots.containerAdornmentIcon;
24
- backgroundAdornmentIcon: ContentGroupsSlots.backgroundAdornmentIcon;
25
24
  containerSideBarMobile: SideBarMobileSlots.containerSideBarMobile;
26
25
  containerDesktopRoot: SideBarDesktopSlots.containerDesktopRoot;
27
26
  containerDesktopContent: SideBarDesktopSlots.containerDesktopContent;
27
+ containerBtnAnchored: SideBarDesktopSlots.containerBtnAnchored;
28
28
  };
29
29
  export declare const CLASS_NAME_IS_ROOT = "is-root";
30
30
  export declare const CLASS_NAME_MENU_ACTIVE = "menu-active";
31
31
  export declare const CLASS_NAME_ITEM_IN_TREE_ACTIVE = "item-in-tree-active";
32
32
  export declare const CLASS_NAME_HAS_CHILDREN = "has-children";
33
- export declare const CLASS_NAME_ITEM_CLOSED = "item-closed";
@@ -1,8 +1,9 @@
1
1
  import { C as ContentComponentSlots, S as SideBarFooterSlots, H as HeaderSidebarSlots, a as ContentGroupsSlots, b as SideBarMobileSlots, c as SideBarDesktopSlots } from "./slots/SideBarEnum.js";
2
2
  const SIDEBAR_KEY_COMPONENT = "M4LSideBar";
3
+ const CONTAINER_BTN_ANCHORED = "M4LSideBarButtonAnchored";
3
4
  const PATH_ICONS = "/frontend/domain/microfrontends/";
4
5
  const PATH_ARROW_DOWN_ICON = "frontend/components/sidebar/assets/icons/ChevronRight.svg";
5
- const PATH_ARROW_RIGHT_ICON = "frontend/components/sidebar/assets/icons/panel-left-close.svg";
6
+ const PATH_ARROW_RIGHT_ICON = "frontend/components/sidebar/assets/icons/arrow_right.svg";
6
7
  const ALL_SIDEBAR_SLOTS = {
7
8
  ...SideBarDesktopSlots,
8
9
  ...SideBarMobileSlots,
@@ -15,16 +16,15 @@ const CLASS_NAME_IS_ROOT = "is-root";
15
16
  const CLASS_NAME_MENU_ACTIVE = "menu-active";
16
17
  const CLASS_NAME_ITEM_IN_TREE_ACTIVE = "item-in-tree-active";
17
18
  const CLASS_NAME_HAS_CHILDREN = "has-children";
18
- const CLASS_NAME_ITEM_CLOSED = "item-closed";
19
19
  export {
20
20
  ALL_SIDEBAR_SLOTS as A,
21
- CLASS_NAME_IS_ROOT as C,
21
+ CONTAINER_BTN_ANCHORED as C,
22
22
  PATH_ICONS as P,
23
23
  SIDEBAR_KEY_COMPONENT as S,
24
- CLASS_NAME_MENU_ACTIVE as a,
25
- CLASS_NAME_HAS_CHILDREN as b,
26
- CLASS_NAME_ITEM_CLOSED as c,
24
+ PATH_ARROW_RIGHT_ICON as a,
25
+ CLASS_NAME_IS_ROOT as b,
26
+ CLASS_NAME_MENU_ACTIVE as c,
27
27
  CLASS_NAME_ITEM_IN_TREE_ACTIVE as d,
28
- PATH_ARROW_RIGHT_ICON as e,
28
+ CLASS_NAME_HAS_CHILDREN as e,
29
29
  PATH_ARROW_DOWN_ICON as f
30
30
  };
@@ -1,5 +1,5 @@
1
1
  import { jsx, Fragment } from "react/jsx-runtime";
2
- import { createContext } from "react";
2
+ import { useState, createContext } from "react";
3
3
  import { g as getComponentClasses } from "../../../../utils/getComponentSlotRoot.js";
4
4
  import { A as ALL_SIDEBAR_SLOTS, S as SIDEBAR_KEY_COMPONENT } from "../../constants.js";
5
5
  const classes = getComponentClasses(SIDEBAR_KEY_COMPONENT, ALL_SIDEBAR_SLOTS);
@@ -19,12 +19,15 @@ const initialState = {
19
19
  companyName: "",
20
20
  companySlogan: "",
21
21
  classes,
22
- headerComponent: /* @__PURE__ */ jsx(Fragment, {}),
23
- footerComponent: /* @__PURE__ */ jsx(Fragment, {})
22
+ promotion: /* @__PURE__ */ jsx(Fragment, {}),
23
+ isHover: false,
24
+ setIsHover: (_isHover) => {
25
+ }
24
26
  };
25
27
  const SideBarContext = createContext(initialState);
26
28
  const SideBarProvider = (props) => {
27
29
  const { value, children } = props;
30
+ const [isHover, setIsHover] = useState(false);
28
31
  const {
29
32
  anchored,
30
33
  visible,
@@ -39,9 +42,7 @@ const SideBarProvider = (props) => {
39
42
  companyName,
40
43
  companySlogan,
41
44
  urlIconPrefix,
42
- headerComponent,
43
- footerComponent,
44
- variant
45
+ promotion
45
46
  } = value;
46
47
  return (
47
48
  // Proporcionar el contexto con las propiedades desestructuradas
@@ -63,9 +64,9 @@ const SideBarProvider = (props) => {
63
64
  companySlogan,
64
65
  urlIconPrefix,
65
66
  classes,
66
- headerComponent,
67
- footerComponent,
68
- variant
67
+ promotion,
68
+ isHover,
69
+ setIsHover
69
70
  },
70
71
  children
71
72
  }
@@ -17,7 +17,15 @@ export interface SideBarProviderValue extends SideBarProps {
17
17
  /**
18
18
  * Promoción del sidebar, se renderiza en el footer del sidebar
19
19
  */
20
- footerComponent: SideBarProps['footerComponent'];
20
+ promotion: SideBarProps['promotion'];
21
+ /**
22
+ * Indica si el sidebar está siendo hoverado
23
+ */
24
+ isHover: boolean;
25
+ /**
26
+ * Función para establecer el estado de hover
27
+ */
28
+ setIsHover: (value: boolean) => void;
21
29
  }
22
30
  /**
23
31
  * Propiedades para el proveedor del contexto Sidebar.
@@ -30,5 +38,5 @@ export interface SideBarProviderProps {
30
38
  /**
31
39
  * Promoción del sidebar, se renderiza en el footer del sidebar
32
40
  */
33
- promotion?: SideBarProps['footerComponent'];
41
+ promotion?: SideBarProps['promotion'];
34
42
  }
@@ -1,6 +1,7 @@
1
1
  export declare enum SideBarDesktopSlots {
2
2
  containerDesktopRoot = "containerDesktopRoot",
3
- containerDesktopContent = "containerDesktopContent"
3
+ containerDesktopContent = "containerDesktopContent",
4
+ containerBtnAnchored = "containerBtnAnchored"
4
5
  }
5
6
  export declare enum SideBarMobileSlots {
6
7
  containerSideBarMobile = "containerSideBarMobile"
@@ -11,20 +12,19 @@ export declare enum ContentGroupsSlots {
11
12
  containerContentTitle = "containerContentTitle",
12
13
  containerContentNavItems = "containerContentNavItems",
13
14
  containerContentItem = "containerContentItem",
14
- containerArrowIconRoot = "containerArrowIconRoot",
15
- containerAdornmentIcon = "containerAdornmentIcon",
16
- backgroundAdornmentIcon = "backgroundAdornmentIcon"
15
+ containerArrowIconRoot = "containerArrowIconRoot"
17
16
  }
18
17
  export declare enum HeaderSidebarSlots {
19
- headerContainerComponent = "headerContainerComponent",
20
- buttonAnchored = "buttonAnchored"
18
+ containerHeaderSidebarRoot = "containerHeaderSidebarRoot",
19
+ containerTitleSubtitle = "containerTitleSubtitle"
21
20
  }
22
21
  export declare enum SideBarFooterSlots {
23
22
  containerFooter = "containerFooter"
24
23
  }
25
24
  export declare enum ContentComponentSlots {
26
25
  contentComponentRoot = "contentComponentRoot",
27
- containerTreeItemsHeaderFooter = "containerTreeItemsHeaderFooter",
26
+ contentComponentHide = "contentComponentHide",
27
+ containerTreeItemsAndPromotion = "containerTreeItemsAndPromotion",
28
28
  containerNodeMenuItem = "containerNodeMenuItem",
29
29
  containerNodeMenuItemMain = "containerNodeMenuItemMain",
30
30
  menuItemMain = "menuItemMain"
@@ -1,6 +1,7 @@
1
1
  var SideBarDesktopSlots = /* @__PURE__ */ ((SideBarDesktopSlots2) => {
2
2
  SideBarDesktopSlots2["containerDesktopRoot"] = "containerDesktopRoot";
3
3
  SideBarDesktopSlots2["containerDesktopContent"] = "containerDesktopContent";
4
+ SideBarDesktopSlots2["containerBtnAnchored"] = "containerBtnAnchored";
4
5
  return SideBarDesktopSlots2;
5
6
  })(SideBarDesktopSlots || {});
6
7
  var SideBarMobileSlots = /* @__PURE__ */ ((SideBarMobileSlots2) => {
@@ -14,13 +15,11 @@ var ContentGroupsSlots = /* @__PURE__ */ ((ContentGroupsSlots2) => {
14
15
  ContentGroupsSlots2["containerContentNavItems"] = "containerContentNavItems";
15
16
  ContentGroupsSlots2["containerContentItem"] = "containerContentItem";
16
17
  ContentGroupsSlots2["containerArrowIconRoot"] = "containerArrowIconRoot";
17
- ContentGroupsSlots2["containerAdornmentIcon"] = "containerAdornmentIcon";
18
- ContentGroupsSlots2["backgroundAdornmentIcon"] = "backgroundAdornmentIcon";
19
18
  return ContentGroupsSlots2;
20
19
  })(ContentGroupsSlots || {});
21
20
  var HeaderSidebarSlots = /* @__PURE__ */ ((HeaderSidebarSlots2) => {
22
- HeaderSidebarSlots2["headerContainerComponent"] = "headerContainerComponent";
23
- HeaderSidebarSlots2["buttonAnchored"] = "buttonAnchored";
21
+ HeaderSidebarSlots2["containerHeaderSidebarRoot"] = "containerHeaderSidebarRoot";
22
+ HeaderSidebarSlots2["containerTitleSubtitle"] = "containerTitleSubtitle";
24
23
  return HeaderSidebarSlots2;
25
24
  })(HeaderSidebarSlots || {});
26
25
  var SideBarFooterSlots = /* @__PURE__ */ ((SideBarFooterSlots2) => {
@@ -29,7 +28,8 @@ var SideBarFooterSlots = /* @__PURE__ */ ((SideBarFooterSlots2) => {
29
28
  })(SideBarFooterSlots || {});
30
29
  var ContentComponentSlots = /* @__PURE__ */ ((ContentComponentSlots2) => {
31
30
  ContentComponentSlots2["contentComponentRoot"] = "contentComponentRoot";
32
- ContentComponentSlots2["containerTreeItemsHeaderFooter"] = "containerTreeItemsHeaderFooter";
31
+ ContentComponentSlots2["contentComponentHide"] = "contentComponentHide";
32
+ ContentComponentSlots2["containerTreeItemsAndPromotion"] = "containerTreeItemsAndPromotion";
33
33
  ContentComponentSlots2["containerNodeMenuItem"] = "containerNodeMenuItem";
34
34
  ContentComponentSlots2["containerNodeMenuItemMain"] = "containerNodeMenuItemMain";
35
35
  ContentComponentSlots2["menuItemMain"] = "menuItemMain";
@@ -4,6 +4,9 @@ export declare const ContainerDesktopRootStyled: import('@emotion/styled').Style
4
4
  export declare const ContainerDesktopContentStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
5
5
  ownerState?: (Partial<import('../types').SideBarOwnerState> & Record<string, unknown>) | undefined;
6
6
  }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
7
+ export declare const ContainerBtnAnchoredStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
8
+ ownerState?: (Partial<import('../types').SideBarOwnerState> & Record<string, unknown>) | undefined;
9
+ }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
7
10
  export declare const ContainerTreeGroupItemsStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
8
11
  ownerState?: (Partial<import('../types').SideBarOwnerState> & Record<string, unknown>) | undefined;
9
12
  }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLElement>, HTMLElement>, keyof import('react').HTMLAttributes<HTMLElement> | keyof import('react').ClassAttributes<HTMLElement>>, {}>;
@@ -22,18 +25,12 @@ export declare const ContainerContentItemStyled: import('@emotion/styled').Style
22
25
  export declare const ContainerArrowIconRootStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
23
26
  ownerState?: (Partial<import('../types').SideBarOwnerState> & Record<string, unknown>) | undefined;
24
27
  }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
25
- export declare const HeaderContainerComponentStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
28
+ export declare const ContainerHeaderSidebarRootStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
26
29
  ownerState?: (Partial<import('../types').SideBarOwnerState> & Record<string, unknown>) | undefined;
27
30
  }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLElement>, HTMLElement>, keyof import('react').HTMLAttributes<HTMLElement> | keyof import('react').ClassAttributes<HTMLElement>>, {}>;
28
- export declare const ContainerAdornmentIconStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
29
- ownerState?: (Partial<import('../types').SideBarOwnerState> & Record<string, unknown>) | undefined;
30
- }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
31
- export declare const BackgroundAdornmentIconStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
31
+ export declare const ContainerTitleSubtitleStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
32
32
  ownerState?: (Partial<import('../types').SideBarOwnerState> & Record<string, unknown>) | undefined;
33
33
  }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
34
- export declare const ButtonAnchoredStyled: import('@emotion/styled').StyledComponent<Pick<Omit<import('../../mui_extended/IconButton/types').IconButtonProps, "ref"> & import('react').RefAttributes<HTMLButtonElement>, "value" | "size" | "children" | "title" | "component" | "name" | "id" | "type" | "selected" | "disabled" | "action" | "hidden" | "color" | "content" | "style" | "icon" | "tooltip" | "variant" | "translate" | "className" | "classes" | "src" | "sx" | "form" | "slot" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoCapitalize" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "enterKeyHint" | "lang" | "nonce" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "exportparts" | "part" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-braillelabel" | "aria-brailleroledescription" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colindextext" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-description" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowindextext" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerLeave" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "instaceDataTestId" | "placement" | "rotationAngle" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple" | "edge" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "badgeProps" | keyof import('react').RefAttributes<HTMLButtonElement>> & import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
35
- ownerState?: (Partial<import('../types').SideBarOwnerState> & Record<string, unknown>) | undefined;
36
- }, {}, {}>;
37
34
  export declare const ContainerFooterStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
38
35
  ownerState?: (Partial<import('../types').SideBarOwnerState> & Record<string, unknown>) | undefined;
39
36
  }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
@@ -43,7 +40,10 @@ export declare const ContainerSideBarMobileStyled: import('@emotion/styled').Sty
43
40
  export declare const ContentComponentRootStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
44
41
  ownerState?: (Partial<import('../types').SideBarOwnerState> & Record<string, unknown>) | undefined;
45
42
  }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
46
- export declare const ContainerTreeItemsHeaderFooterStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
43
+ export declare const ContentComponentHideStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
44
+ ownerState?: (Partial<import('../types').SideBarOwnerState> & Record<string, unknown>) | undefined;
45
+ }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
46
+ export declare const ContainerTreeItemsAndPromotionStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
47
47
  ownerState?: (Partial<import('../types').SideBarOwnerState> & Record<string, unknown>) | undefined;
48
48
  }, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
49
49
  export declare const ContainerNodeMenuItemStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
@@ -1,8 +1,7 @@
1
1
  import { styled } from "@mui/material/styles";
2
- import { c as SideBarDesktopSlots, b as SideBarMobileSlots, C as ContentComponentSlots, S as SideBarFooterSlots, H as HeaderSidebarSlots, a as ContentGroupsSlots } from "./SideBarEnum.js";
2
+ import { c as SideBarDesktopSlots, b as SideBarMobileSlots, C as ContentComponentSlots, S as SideBarFooterSlots, a as ContentGroupsSlots, H as HeaderSidebarSlots } from "./SideBarEnum.js";
3
3
  import { S as SIDEBAR_KEY_COMPONENT } from "../constants.js";
4
4
  import { s as sideBarStyles } from "../styles.js";
5
- import { I as IconButton } from "../../mui_extended/IconButton/IconButton.js";
6
5
  import { M as MenuItem } from "../../mui_extended/MenuItem/MenuItem.js";
7
6
  const ContainerDesktopRootStyled = styled("section", {
8
7
  name: SIDEBAR_KEY_COMPONENT,
@@ -12,6 +11,10 @@ const ContainerDesktopContentStyled = styled("div", {
12
11
  name: SIDEBAR_KEY_COMPONENT,
13
12
  slot: SideBarDesktopSlots.containerDesktopContent
14
13
  })(sideBarStyles?.containerDesktopContent);
14
+ const ContainerBtnAnchoredStyled = styled("div", {
15
+ name: SIDEBAR_KEY_COMPONENT,
16
+ slot: SideBarDesktopSlots.containerBtnAnchored
17
+ })(sideBarStyles?.containerBtnAnchored);
15
18
  const ContainerTreeGroupItemsStyled = styled("section", {
16
19
  name: SIDEBAR_KEY_COMPONENT,
17
20
  slot: ContentGroupsSlots.containerTreeGroupItems
@@ -36,22 +39,14 @@ const ContainerArrowIconRootStyled = styled("div", {
36
39
  name: SIDEBAR_KEY_COMPONENT,
37
40
  slot: ContentGroupsSlots.containerArrowIconRoot
38
41
  })(sideBarStyles?.containerArrowIconRoot);
39
- const HeaderContainerComponentStyled = styled("section", {
40
- name: SIDEBAR_KEY_COMPONENT,
41
- slot: HeaderSidebarSlots.headerContainerComponent
42
- })(sideBarStyles?.headerContainerComponent);
43
- const ContainerAdornmentIconStyled = styled("div", {
44
- name: SIDEBAR_KEY_COMPONENT,
45
- slot: ContentGroupsSlots.containerAdornmentIcon
46
- })(sideBarStyles?.containerAdornmentIcon);
47
- const BackgroundAdornmentIconStyled = styled("div", {
42
+ styled("section", {
48
43
  name: SIDEBAR_KEY_COMPONENT,
49
- slot: ContentGroupsSlots.backgroundAdornmentIcon
50
- })(sideBarStyles?.backgroundAdornmentIcon);
51
- const ButtonAnchoredStyled = styled(IconButton, {
44
+ slot: HeaderSidebarSlots.containerHeaderSidebarRoot
45
+ })(sideBarStyles?.containerHeaderSidebarRoot);
46
+ styled("div", {
52
47
  name: SIDEBAR_KEY_COMPONENT,
53
- slot: HeaderSidebarSlots.buttonAnchored
54
- })(sideBarStyles?.buttonAnchored);
48
+ slot: HeaderSidebarSlots.containerTitleSubtitle
49
+ })(sideBarStyles?.containerTitleSubtitle);
55
50
  const ContainerFooterStyled = styled("div", {
56
51
  name: SIDEBAR_KEY_COMPONENT,
57
52
  slot: SideBarFooterSlots.containerFooter
@@ -64,10 +59,14 @@ const ContentComponentRootStyled = styled("div", {
64
59
  name: SIDEBAR_KEY_COMPONENT,
65
60
  slot: ContentComponentSlots.contentComponentRoot
66
61
  })(sideBarStyles?.contentComponentRoot);
67
- const ContainerTreeItemsHeaderFooterStyled = styled("div", {
62
+ const ContentComponentHideStyled = styled("div", {
63
+ name: SIDEBAR_KEY_COMPONENT,
64
+ slot: ContentComponentSlots.contentComponentHide
65
+ })(sideBarStyles?.contentComponentHide);
66
+ const ContainerTreeItemsAndPromotionStyled = styled("div", {
68
67
  name: SIDEBAR_KEY_COMPONENT,
69
- slot: ContentComponentSlots.containerTreeItemsHeaderFooter
70
- })(sideBarStyles?.containerTreeItemsHeaderFooter);
68
+ slot: ContentComponentSlots.containerTreeItemsAndPromotion
69
+ })(sideBarStyles?.containerTreeItemsAndPromotion);
71
70
  const ContainerNodeMenuItemStyled = styled("div", {
72
71
  name: SIDEBAR_KEY_COMPONENT,
73
72
  slot: ContentComponentSlots.containerNodeMenuItem
@@ -81,20 +80,18 @@ const MenuItemMainStyled = styled(MenuItem, {
81
80
  slot: ContentComponentSlots.menuItemMain
82
81
  })(sideBarStyles?.menuItemMain);
83
82
  export {
84
- ButtonAnchoredStyled as B,
85
83
  ContentComponentRootStyled as C,
86
- HeaderContainerComponentStyled as H,
87
84
  MenuItemMainStyled as M,
88
- ContainerTreeItemsHeaderFooterStyled as a,
89
- ContainerFooterStyled as b,
90
- ContainerDesktopContentStyled as c,
91
- ContainerDesktopRootStyled as d,
92
- ContainerSideBarMobileStyled as e,
93
- ContainerTreeGroupItemsStyled as f,
94
- ContainerContentGroupsStyled as g,
95
- ContainerContentTitleStyled as h,
96
- ContainerAdornmentIconStyled as i,
97
- BackgroundAdornmentIconStyled as j,
85
+ ContainerBtnAnchoredStyled as a,
86
+ ContentComponentHideStyled as b,
87
+ ContainerTreeItemsAndPromotionStyled as c,
88
+ ContainerFooterStyled as d,
89
+ ContainerDesktopContentStyled as e,
90
+ ContainerDesktopRootStyled as f,
91
+ ContainerSideBarMobileStyled as g,
92
+ ContainerTreeGroupItemsStyled as h,
93
+ ContainerContentGroupsStyled as i,
94
+ ContainerContentTitleStyled as j,
98
95
  ContainerArrowIconRootStyled as k,
99
96
  ContainerNodeMenuItemStyled as l,
100
97
  ContainerNodeMenuItemMainStyled as m
@@ -1,14 +1,14 @@
1
1
  import { s as sideBarDesktopStyles } from "./subcomponents/SideBarDesktop/styles.js";
2
2
  import { c as contentGroupStyles } from "./subcomponents/TreeGroupItems/styles.js";
3
- import { h as headerComponentStyles } from "./subcomponents/HeaderComponent/styles.js";
4
- import { f as footerSideBarStyles } from "./subcomponents/FooterComponent/styles.js";
3
+ import { h as headerSidebarStyles } from "./subcomponents/HeaderSidebar/styles.js";
4
+ import { f as footerSideBarStyles } from "./subcomponents/Promotion/styles.js";
5
5
  import { c as contentComponentStyles } from "./subcomponents/ContentComponent/style.js";
6
6
  import { s as sideBarMobileStyles } from "./subcomponents/SideBarMobile/styles.js";
7
7
  const sideBarStyles = {
8
8
  ...sideBarDesktopStyles,
9
9
  ...sideBarMobileStyles,
10
10
  ...contentGroupStyles,
11
- ...headerComponentStyles,
11
+ ...headerSidebarStyles,
12
12
  ...footerSideBarStyles,
13
13
  ...contentComponentStyles
14
14
  };
@@ -1,23 +1,79 @@
1
- import { jsx, jsxs } from "react/jsx-runtime";
1
+ import { jsxs, jsx } from "react/jsx-runtime";
2
+ import { useIsMobile } from "@m4l/graphics";
3
+ import { useEnvironment } from "@m4l/core";
2
4
  import { u as useSideBar } from "../../hooks/useSideBar/index.js";
3
- import { C as ContentComponentRootStyled, a as ContainerTreeItemsHeaderFooterStyled } from "../../slots/SideBarSlots.js";
5
+ import { C as ContentComponentRootStyled, a as ContainerBtnAnchoredStyled, b as ContentComponentHideStyled, c as ContainerTreeItemsAndPromotionStyled } from "../../slots/SideBarSlots.js";
4
6
  import { T as TreeGroupItems } from "../TreeGroupItems/index.js";
5
- import { F as FooterComponent } from "../FooterComponent/index.js";
7
+ import { P as Promotion } from "../Promotion/index.js";
8
+ import { a as getComponentSlotRoot } from "../../../../utils/getComponentSlotRoot.js";
9
+ import { a as PATH_ARROW_RIGHT_ICON, C as CONTAINER_BTN_ANCHORED } from "../../constants.js";
10
+ import { useRef } from "react";
6
11
  import { u as useComponentSize } from "../../../../hooks/useComponentSize/useComponentSize.js";
7
- import { H as HeaderComponent } from "../HeaderComponent/HeaderComponent.js";
12
+ import { I as IconButton } from "../../../mui_extended/IconButton/IconButton.js";
8
13
  const ContentComponent = () => {
9
- const { anchored, onToggleAnchored, expandedWidth, size, variant } = useSideBar();
14
+ const { anchored, onToggleAnchored, expandedWidth, size, classes, isHover, setIsHover } = useSideBar();
10
15
  const ownerState = {
11
16
  expandedWidth,
12
- anchored,
13
- variant
17
+ anchored
14
18
  };
19
+ const btnAnchoredRef = useRef(null);
20
+ const contentRef = useRef(null);
21
+ const { host_static_assets, environment_assets } = useEnvironment();
22
+ const isDesktop = !useIsMobile();
15
23
  const { currentSize } = useComponentSize(size);
16
- return /* @__PURE__ */ jsx(ContentComponentRootStyled, { ownerState, children: /* @__PURE__ */ jsxs(ContainerTreeItemsHeaderFooterStyled, { ownerState, children: [
17
- /* @__PURE__ */ jsx(HeaderComponent, {}),
18
- /* @__PURE__ */ jsx(TreeGroupItems, { size: currentSize }),
19
- /* @__PURE__ */ jsx(FooterComponent, { onToggleAnchored, anchored })
20
- ] }) });
24
+ const classRootBtnAnchored = getComponentSlotRoot(CONTAINER_BTN_ANCHORED);
25
+ const handlerAnchoredButton = () => {
26
+ onToggleAnchored(!anchored);
27
+ };
28
+ return /* @__PURE__ */ jsxs(ContentComponentRootStyled, { ownerState, children: [
29
+ isDesktop && /* @__PURE__ */ jsx(
30
+ ContainerBtnAnchoredStyled,
31
+ {
32
+ ref: btnAnchoredRef,
33
+ className: classRootBtnAnchored,
34
+ ownerState,
35
+ onMouseLeave: (event) => {
36
+ if (!anchored && contentRef.current && !contentRef.current.contains(event.relatedTarget)) {
37
+ setIsHover(false);
38
+ }
39
+ },
40
+ children: /* @__PURE__ */ jsx(
41
+ IconButton,
42
+ {
43
+ role: "anchored-button",
44
+ variant: anchored ? "contained" : "outline",
45
+ rotationAngle: !anchored ? 0 : 180,
46
+ onClick: handlerAnchoredButton,
47
+ src: `${host_static_assets}/${environment_assets}/${PATH_ARROW_RIGHT_ICON}`,
48
+ color: anchored ? "primary" : "default"
49
+ }
50
+ )
51
+ }
52
+ ),
53
+ /* @__PURE__ */ jsx(
54
+ ContentComponentHideStyled,
55
+ {
56
+ ref: contentRef,
57
+ ownerState: { ...ownerState, isDesktop, isHover },
58
+ className: classes.contentComponentHide,
59
+ role: "complementary",
60
+ "aria-label": "hidden content",
61
+ onMouseEnter: () => {
62
+ !anchored && setIsHover(true);
63
+ },
64
+ onMouseLeave: (event) => {
65
+ if (!anchored && btnAnchoredRef.current && btnAnchoredRef.current.contains(event.relatedTarget)) {
66
+ return;
67
+ }
68
+ setIsHover(false);
69
+ },
70
+ children: /* @__PURE__ */ jsxs(ContainerTreeItemsAndPromotionStyled, { ownerState, children: [
71
+ /* @__PURE__ */ jsx(TreeGroupItems, { size: currentSize }),
72
+ /* @__PURE__ */ jsx(Promotion, { onToggleAnchored, anchored })
73
+ ] })
74
+ }
75
+ )
76
+ ] });
21
77
  };
22
78
  export {
23
79
  ContentComponent as C