Skip to content

Commit

Permalink
TASK-30
Browse files Browse the repository at this point in the history
  • Loading branch information
venglov committed Nov 26, 2020
1 parent 3a9b37b commit 0c94148
Show file tree
Hide file tree
Showing 7 changed files with 83 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,13 @@ import React from "react";
import SchedulePage from "./components/schedule-page/schedule-page.component";
import WorkersPage from "./components/workers-page/workers-page.component";
import { CustomGlobalHotKeys } from "./components/common-components/tools/globalhotkeys.component";
import Header from "./components/common-components/header/header";

function App(): JSX.Element {
return (
<React.Fragment>
<CustomGlobalHotKeys />
<Header />
<Switch>
<Route path="/" component={SchedulePage} exact />
<Route path="/workers" component={WorkersPage} />
Expand Down
Binary file added src/assets/images/arrow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/images/header-logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions src/assets/styles/styles-all.scss
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,5 @@
@import "styles/custom/tables";
@import "styles/custom/toolbar";
@import "styles/custom/add-worker-modal";
@import "styles/custom/header";
@import "styles/custom/month-switch";
3 changes: 3 additions & 0 deletions src/assets/styles/styles/bootstrap/_variables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@
// Color system
//

$primary-header-color: #1d3557 !default;
$primary-header-color-selected: #162740 !default;

$white: #fff !default;
$gray-100: #f8f9fa !default;
$gray-200: #e9ecef !default;
Expand Down
43 changes: 43 additions & 0 deletions src/assets/styles/styles/custom/_header.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
#header {
display: flex;
flex-direction: row;
width: 100%;
height: 5%;
background-color: $primary-header-color;
padding: 0 20px 0 20px;
align-items: center;
justify-content: left;

ul {
list-style-type: none;
margin: 0 20px 0 20px;
padding: 0;
overflow: hidden;
height: 100%;
}

li {
float: left;
}

li a {
display: block;
color: $white;
text-align: center;
padding: 14px 16px;
text-decoration: none;
}

li a:hover {
background-color: $primary-header-color-selected;
color: $white;
}

.active {
font-weight: bold;
}

.filler {
flex-grow: 1;
}
}
34 changes: 34 additions & 0 deletions src/components/common-components/header/header.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
import React from "react";
import { Link } from "react-router-dom";

export default function Header(): JSX.Element {
return (
<>
<div id={"header"}>
<img src={require("../../../assets/images/header-logo.png")} title={""} alt={""} />

<ul>
<li className={"active"}>
<Link to="/">Plan</Link>
</li>

<li>
<Link to="/workers/">Zarządzanie</Link>
</li>
</ul>

<div className={"filler"}></div>

<ul>
<li>
<Link to="/">Imię i nazwisko</Link>
</li>
</ul>

<Link to={"/"}>
<img src={require("../../../assets/images/arrow.png")} title={""} alt={""} />
</Link>
</div>
</>
);
}

0 comments on commit 0c94148

Please sign in to comment.