Skip to content

Commit

Permalink
Feat/7409 assets list rice (#19621)
Browse files Browse the repository at this point in the history
* feat(7409): Removed security side nav

* feat(7409): Removed unused components
  • Loading branch information
zeeklop authored Jun 17, 2024
1 parent a36aa56 commit 90ae3de
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 218 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,10 @@
*/
import styled, { css } from 'styled-components';

import { NAV_BAR_WIDTH } from './SideNav';

const ContentArea = styled.div<{ $sideNavIsOpen: boolean; $isSecurityPerspective?: boolean; }>(({ $sideNavIsOpen, $isSecurityPerspective, theme }) => css`
const ContentArea = styled.div<{ $isSecurityPerspective?: boolean; }>(({ $isSecurityPerspective, theme }) => css`
display: flex;
flex-direction: column;
padding-left: ${$sideNavIsOpen ? `${NAV_BAR_WIDTH}px` : '0px'};
padding-left: 0px;
padding-top: ${$isSecurityPerspective ? '0px' : '15px'};
transition: all 0.33s ease-in-out;
position: relative;
Expand Down

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,3 @@
*/
export { default as ContentArea } from './ContentArea';
export { default as Container } from './Container';
export { default as SideNav } from './SideNav';
export { default as SideNavItem } from './SideNavItem';
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,7 @@ import { useState } from 'react';

import { Alert, Button } from 'components/bootstrap';
import { Icon, ConfirmDialog } from 'components/common';
import { SideNav, SideNavItem, ContentArea, Container } from 'components/security/page-layout';
import Routes from 'routing/Routes';
import { ContentArea, Container } from 'components/security/page-layout';

const StyledAlert = styled(Alert)`
padding: ${({ theme }) => theme.spacings.lg};
Expand Down Expand Up @@ -94,57 +93,13 @@ const RIGHT_COLUMN_ITEM_LIST = [
'SOAR Integrations',
];

const navItems = [
{
path: Routes.SECURITY.OVERVIEW,
iconName: 'ballot',
end: true,
title: 'Overview',
},
{
path: Routes.SECURITY.USER_ACTIVITY,
iconName: 'person',
end: false,
title: 'User Activity',
},
{
path: Routes.SECURITY.HOST_ACTIVITY,
iconName: 'tv',
end: false,
title: 'Host Activity',
},
{
path: Routes.SECURITY.NETWORK_ACTIVITY,
iconName: 'wifi',
end: false,
title: 'Network Activity',
},
{
path: Routes.SECURITY.ANOMALIES,
iconName: 'zoom_in',
end: false,
title: 'Anomalies',
},
] as const;

const TeaserPageLayout = ({ children }: PropsWithChildren) => {
const [showSideBar, setShowSideBar] = useState(true);
const [showModal, setShowModal] = useState(true);

return (
<>
<Container>
<SideNav isOpen={showSideBar} toggleIsOpen={() => setShowSideBar((cur) => !cur)}>
{navItems.map((route) => (
<SideNavItem key={route.title}
iconName={route.iconName}
linkTarget={route.path}
linkEnd={route.end}>
{route.title}
</SideNavItem>
))}
</SideNav>
<ContentArea $sideNavIsOpen={showSideBar}>
<ContentArea>
<StyledAlert bsStyle="info" noIcon>
<Banner>
<LeftItems>
Expand Down

0 comments on commit 90ae3de

Please sign in to comment.