mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-15 20:30:33 +00:00
WIP Frontend structure & authentication.
This commit is contained in:
16
client/src/components/Sidebar/Sidebar.js
Normal file
16
client/src/components/Sidebar/Sidebar.js
Normal file
@@ -0,0 +1,16 @@
|
||||
import React from 'react';
|
||||
import SidebarContainer from 'components/Sidebar/SidebarContainer';
|
||||
import SidebarHead from 'components/Sidebar/SidebarHead';
|
||||
import SidebarMenu from 'components/Sidebar/SidebarMenu';
|
||||
|
||||
export default function Sidebar() {
|
||||
return (
|
||||
<SidebarContainer>
|
||||
<SidebarHead />
|
||||
|
||||
<div className="sidebar__menu">
|
||||
<SidebarMenu />
|
||||
</div>
|
||||
</SidebarContainer>
|
||||
)
|
||||
}
|
||||
9
client/src/components/Sidebar/SidebarContainer.js
Normal file
9
client/src/components/Sidebar/SidebarContainer.js
Normal file
@@ -0,0 +1,9 @@
|
||||
import React from 'react';
|
||||
|
||||
export default function SidebarContainer(props) {
|
||||
return (
|
||||
<div className="sidebar" id="sidebar">
|
||||
{props.children}
|
||||
</div>
|
||||
)
|
||||
}
|
||||
19
client/src/components/Sidebar/SidebarHead.js
Normal file
19
client/src/components/Sidebar/SidebarHead.js
Normal file
@@ -0,0 +1,19 @@
|
||||
import React from 'react';
|
||||
|
||||
export default function() {
|
||||
return (
|
||||
<div className="sidebar__head">
|
||||
<div className="sidebar__head-logo">
|
||||
|
||||
</div>
|
||||
|
||||
<div className="sidebar__head-company-meta">
|
||||
<span className="comapny-name">
|
||||
|
||||
</span>
|
||||
|
||||
<span className="company-meta"></span>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
21
client/src/components/Sidebar/SidebarMenu.js
Normal file
21
client/src/components/Sidebar/SidebarMenu.js
Normal file
@@ -0,0 +1,21 @@
|
||||
import React from 'react';
|
||||
import {Menu, MenuItem, MenuDivider} from "@blueprintjs/core";
|
||||
import sidebarMenuList from 'config/sidebarMenu';
|
||||
|
||||
export default function SidebarMenu() {
|
||||
const items = sidebarMenuList.map((item) =>
|
||||
(item.divider) ?
|
||||
<MenuDivider
|
||||
title={item.title} /> :
|
||||
<MenuItem
|
||||
icon={item.icon}
|
||||
text={item.text}
|
||||
label={item.label}
|
||||
disabled={item.disabled} />
|
||||
);
|
||||
return (
|
||||
<Menu className="sidebar-menu">
|
||||
{items}
|
||||
</Menu>
|
||||
)
|
||||
};
|
||||
Reference in New Issue
Block a user