mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-19 06:10:31 +00:00
re-structure to monorepo.
This commit is contained in:
43
packages/webapp/src/containers/Dashboard/Sidebar/Sidebar.tsx
Normal file
43
packages/webapp/src/containers/Dashboard/Sidebar/Sidebar.tsx
Normal file
@@ -0,0 +1,43 @@
|
||||
// @ts-nocheck
|
||||
import React from 'react';
|
||||
|
||||
import { SidebarContainer } from './SidebarContainer';
|
||||
import { SidebarHead } from './SidebarHead';
|
||||
import { SidebarMenu } from './SidebarMenu';
|
||||
import { useMainSidebarMenu } from './hooks';
|
||||
import { SidebarOverlayBinded } from '../SidebarOverlay';
|
||||
|
||||
import '@/style/containers/Dashboard/Sidebar.scss';
|
||||
|
||||
/**
|
||||
* Dashboard sidebar.
|
||||
* @returns {JSX.Element}
|
||||
*/
|
||||
export function Sidebar() {
|
||||
const menu = useMainSidebarMenu();
|
||||
|
||||
return (
|
||||
<SidebarContainer>
|
||||
<SidebarHead />
|
||||
|
||||
<div className="sidebar__menu">
|
||||
<SidebarMenu menu={menu} />
|
||||
</div>
|
||||
<SidebarOverlayBinded />
|
||||
<SidebarFooterVersion />
|
||||
</SidebarContainer>
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Sidebar footer version.
|
||||
* @returns {React.JSX}
|
||||
*/
|
||||
function SidebarFooterVersion() {
|
||||
const { VERSION } = process.env;
|
||||
|
||||
if (!VERSION) {
|
||||
return null;
|
||||
}
|
||||
return <div class="sidebar__version">v{VERSION}</div>;
|
||||
}
|
||||
Reference in New Issue
Block a user