From 16ce2b8dc39ffd8f9fb7c1d9aaa68cba80cede3d Mon Sep 17 00:00:00 2001 From: Timofey Boyko Date: Fri, 1 Apr 2022 17:11:25 +0300 Subject: [PATCH] Web:Common:Section: display main bar in select module page --- .../components/Section/index.js | 26 +++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) diff --git a/packages/asc-web-common/components/Section/index.js b/packages/asc-web-common/components/Section/index.js index 9f28a28f43..f47c6cc86a 100644 --- a/packages/asc-web-common/components/Section/index.js +++ b/packages/asc-web-common/components/Section/index.js @@ -79,6 +79,22 @@ const StyledMainBar = styled.div` min-width: 100vw; } `} + + ${(props) => + !props.isSectionHeaderAvailable && + css` + width: 100vw !important; + max-width: 100vw !important; + + ${isMobile && + css` + position: fixed; + top: 48px; + left: 0; + margin-left: 0 !important; + box-sizing: border-box; + `} + `} `; function SectionHeader() { @@ -238,6 +254,8 @@ class Section extends React.Component { isSectionBodyAvailable || isSectionPagingAvailable; + console.log(isSectionAvailable); + const renderSection = () => { return ( <> @@ -261,12 +279,13 @@ class Section extends React.Component { maintenanceExist={maintenanceExist} isSectionBarAvailable={isSectionBarAvailable} > - {isSectionBarAvailable && !isMobile && ( + {!isMobile && ( - {isSectionBarAvailable && isMobile && ( + {isMobile && (