Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
Amogh-Bharadwaj committed Mar 4, 2024
1 parent 0270a71 commit 7ac6a98
Showing 1 changed file with 8 additions and 10 deletions.
18 changes: 8 additions & 10 deletions ui/components/SidebarComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,7 @@ export default function SidebarComponent() {
width: '100%',
}}
>
{sidebarState == 'closed' ? (
<></>
) : (
{sidebarState === 'open' && (
<Label as={Link} href='/'>
<div className='cursor-pointer'>
<BrandLogo />
Expand All @@ -64,19 +62,19 @@ export default function SidebarComponent() {
variant='normalBorderless'
aria-label='iconButton'
onClick={() =>
setSidebarState(sidebarState == 'open' ? 'closed' : 'open')
setSidebarState(sidebarState === 'open' ? 'closed' : 'open')
}
>
<Icon
name={
sidebarState == 'closed' ? 'chevron_right' : 'chevron_left'
sidebarState === 'closed' ? 'chevron_right' : 'chevron_left'
}
/>
</Button>
</div>
}
bottomRow={
sidebarState == 'open' ? (
sidebarState === 'open' ? (
<>
<div style={centerFlexStyle}>
<RowWithSelect
Expand Down Expand Up @@ -111,7 +109,7 @@ export default function SidebarComponent() {
)
}
bottomLabel={
sidebarState == 'open' ? (
sidebarState === 'open' ? (
<div style={centerFlexStyle}>
<Label as='label' style={{ textAlign: 'center', fontSize: 15 }}>
{' '}
Expand All @@ -129,21 +127,21 @@ export default function SidebarComponent() {
href={'/peers'}
leadingIcon={<Icon name='cable' />}
>
{sidebarState == 'open' && 'Peers'}
{sidebarState === 'open' && 'Peers'}
</SidebarItem>
<SidebarItem
as={Link}
href={'/mirrors'}
leadingIcon={<Icon name='compare_arrows' />}
>
{sidebarState == 'open' && 'Mirrors'}
{sidebarState === 'open' && 'Mirrors'}
</SidebarItem>
<SidebarItem
as={Link}
href={'/alert-config'}
leadingIcon={<Icon name='notifications' />}
>
{sidebarState == 'open' && 'Alert Configuration'}
{sidebarState === 'open' && 'Alert Configuration'}
</SidebarItem>
</Sidebar>
</SessionProvider>
Expand Down

0 comments on commit 7ac6a98

Please sign in to comment.