Skip to content
This repository has been archived by the owner on Jul 28, 2018. It is now read-only.

8 profile page #17

Open
wants to merge 35 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
1ac62e2
Fetch Data Servise Done
dukadiesel Nov 21, 2017
15d2a4d
redirection Done
dukadiesel Nov 21, 2017
5a8131b
UI partly done
dukadiesel Nov 21, 2017
ba9d2f6
Merge pull request #4 from Srkinator/2-Login-Page
Srkinator Nov 21, 2017
a478a05
Merge pull request #5 from Srkinator/3-service-for-communication
Srkinator Nov 21, 2017
70dfd88
Login done, #403 KEY SERVER ERROR
dukadiesel Nov 21, 2017
0cb45ae
Merge pull request #7 from Srkinator/4-Authentification
Srkinator Nov 22, 2017
6a3c37a
Authentication finished
dukadiesel Nov 22, 2017
a1b82fa
Merge pull request #8 from Srkinator/4-Authentication
Srkinator Nov 22, 2017
0f6b7a8
Input validation partially done
dukadiesel Nov 22, 2017
5f36a99
Merge pull request #10 from Srkinator/4-Authentication
Srkinator Nov 22, 2017
52b7a57
ERROR HANDLING needs small fix, validation, authentication and
Srkinator Nov 22, 2017
b9a54cf
Input validation done
dukadiesel Nov 23, 2017
3937fd0
Merged told us so remote-tracking branch 'upstream/master'
dukadiesel Nov 23, 2017
76b4f36
login-register button highlight done
dukadiesel Nov 23, 2017
9396a3f
First 6 issues finished.
dukadiesel Nov 23, 2017
c8ad5aa
Merge pull request #14 from Srkinator/button-highlight
Srkinator Nov 23, 2017
1294e6e
Data Service started - continued by Jovan and Darko
dukadiesel Nov 23, 2017
7dafe97
Merge pull request #16 from Srkinator/7-Data-Service
Srkinator Nov 23, 2017
3c4e3cf
Profile Page works
dukadiesel Nov 23, 2017
b133a76
profile page- work in progres
dukadiesel Nov 23, 2017
8770052
testing git options
dukadiesel Nov 23, 2017
c020e8b
Data Service and a bit of Profile Page
dukadiesel Nov 23, 2017
950ef62
Merge pull request #17 from Srkinator/7-Data-Service
Srkinator Nov 23, 2017
8be920e
Hell of a merge
dukadiesel Nov 23, 2017
07bf58f
Updating profile in process, PUT METHOD not implemented
dukadiesel Nov 23, 2017
f33c5db
Error handling fixed and editing profile done
dukadiesel Nov 24, 2017
bfad2f3
profile-page WIP
dukadiesel Nov 24, 2017
93983a7
profile padge almost finished, modal - work in progress
Jovisa Nov 24, 2017
ddb11e3
profile padge modal - work in progress
Jovisa Nov 25, 2017
09e4dd5
8-profile-page finished , exept close button in update-profile menu
dukadiesel Nov 25, 2017
61d58ec
profile page -finished, background implemented, modal-finished,exept …
Jovisa Nov 25, 2017
7755b21
modal style finished
Jovisa Nov 25, 2017
4da6343
entry-page design finished , spavas li mirno Cukemberze
Jovisa Nov 26, 2017
e4a9c10
design fine tuning
dukadiesel Nov 27, 2017
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3,217 changes: 2,215 additions & 1,002 deletions package-lock.json

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,11 @@
"author": "BIT",
"license": "ISC",
"dependencies": {
"axios": "^0.17.1",
"babel-polyfill": "^6.26.0",
"react": "^16.1.0",
"react-dom": "^16.1.0",
"react-modal": "^3.1.3",
"react-router-dom": "^4.2.2"
},
"devDependencies": {
Expand Down
1 change: 1 addition & 0 deletions src/assets/css/bootstrapTheme.css

Large diffs are not rendered by default.

113 changes: 113 additions & 0 deletions src/assets/css/main.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
html {
min-height: 100%;
}

.bg {
background-image: url("https://wallpaperlayer.com/img/2015/6/gaussian-blur-wallpaper-3225-3429-hd-wallpapers.jpg");
height: 100%;
background-position: center;
background-repeat: no-repeat;
background-size: cover;
}

.checked{
background-color: rgba(116, 208, 146, 0.2);
box-shadow: -12px 11px 34px -1px rgba(44,62,80,0.34);
}

.hover:link {
text-decoration: none;
}


.hover:hover {
background-color: rgba(116, 208, 146, 0.2);
}

.hover:active {
box-shadow: -12px 11px 34px -1px rgba(44,62,80,0.34);
}

.navColor {
background-color: rgba(65, 105, 144, 1);
}

.navLink:hover {
font-weight: bold;
}

.profileName {
font-weight: bold;
color: rgba(44, 62, 80, 0.9)

}

.profileButton {
margin: 30px 20%;
}

.loginProfileButton {
width: 60%;
margin: 10px 0px 30px 0;
box-shadow: -12px 11px 34px -1px rgba(44,62,80,0.34);
}

.loginProfileButton:hover {
width: 90%;
}

.updateProfileForm {
display: block;
width: 60%;
margin: 30px auto;
}

.updateProfileCloseButton {
float: right;
margin-bottom: 30px;
width: 20%;
}

.updateProfileCloseButton:hover {
width: 30%;
}

.updateProfileUpdateButton {
width: 30%;

}

.updateProfileUpdateButton:hover {
width: 40%;
}

.updateProfileHeading {
color: rgba(67, 93, 119,0.9);
}

.modalNavColor {
background-color: rgba(116, 162, 208, 0.3);
}

.labelStyle {
color: rgba(46, 79, 96, 0.9);
}

.entryPageButton {
width: 25%;
}
.entryPageButton:hover {
width: 50%;
}

.welcomeStyle {
text-align: center;
color: rgba(44, 62, 80, 1);
padding-right: 15%;
line-height: 2em;
}





22 changes: 20 additions & 2 deletions src/components/app.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,32 @@
import React from "react";
import { Switch, Route, Redirect } from "react-router-dom";

import HelloWorld from "./helloWorld/helloWorld";
import EntryPage from "./entryPage/entryPage";
import Main from "./userPages/main";

import AuthenticationService from "../services/authenticationService";

class App extends React.Component {
constructor(props) {
super(props);

this.auth = new AuthenticationService();
}

render() {
return <HelloWorld />;
if (!this.auth.isUserAuthenticated()) {
return (
<div className="container">
<Switch>
<Redirect exact from='/' to='/login' />
<Route path='/login' component={EntryPage} />
<Route path='/register' component={EntryPage} />
</Switch>
</div>
);
}

return <Main />;
}
}

Expand Down
59 changes: 59 additions & 0 deletions src/components/common/header.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
import React, { Component } from "react";
import { Link } from "react-router-dom";

import AuthenticationService from "../../services/authenticationService";

const navLinkStyle = {
transition: "font-weight 0.2s",
transitionTimingFunction: "step-start",
paddingLeft: "25px"

};

class Header extends Component {
constructor(props) {
super(props);

this.logout = new AuthenticationService();
}
render() {
return (
<div>
<nav className="navbar navbar-expand-lg navbar-dark navColor ">
<Link to="feed">
<p className="navbar-brand" style={{ fontSize: "1.7em", fontWeight: "bold", paddingLeft: "15px", paddingTop: "10px" }}>BitBook</p>
</Link>
<button className="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarColor01" aria-controls="navbarColor01" aria-expanded="false" aria-label="Toggle navigation">
<span className="navbar-toggler-icon"></span>
</button>
<div className="collapse navbar-collapse justify-content-end pull-right" id="navbarColor01">
<ul className="navbar-nav" style={{ fontSize: "1.2em" }}>
<Link to="/feed">
<li className="nav-item">
<p className="nav-link navLink" style={navLinkStyle}>Feed <span className="sr-only">(current)</span></p>
</li>
</Link>
<Link to="/people">
<li className="nav-item navLink" style={navLinkStyle}>
<p className="nav-link">People</p>
</li>
</Link>
<Link to="/profile">
<li className="nav-item navLink" style={navLinkStyle}>
<p className="nav-link">Profile</p>
</li>
</Link>
<Link to="/login">
<li className="nav-item navLink" style={navLinkStyle} onClick={this.logout.logout}>
<p className="nav-link">Log Out</p>
</li>
</Link>
</ul>
</div>
</nav>
</div>
);
}
}

export default Header;
63 changes: 63 additions & 0 deletions src/components/entryPage/entryPage.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
import React from "react";
import { Switch, Route } from "react-router-dom";
import { Link } from "react-router-dom";

import Login from "./login";
import Register from "./register";
import Welcome from "./welcome";

const formStyle = {
fontSize: "1.5em",
padding: "5px",
float: "left",
borderRadius: "5px",
width: "50%",
height: "50px",
textAlign: "center",
margin: "10px 0",
color: "rgba(46, 79, 96, 0.7)"
};

const switchBox = {
borderRadius: "5px",
boxShadow: "-12px 11px 34px -1px rgba(44,62,80,0.34)",
display: "inline-block",
width: "100%",
backgroundColor: "rgba(116, 208, 146, 0.2)",
padding: "30px 20px 20px 20px",
minHeight: "400px",
positon: "relative"
};

class EntryPage extends React.Component {
constructor(props) {
super(props);
}

render() {
return (
<div className="row" style={{ marginTop: "100px" }}>
<div className="col-12 col-sm-12 col-md-12 col-lg-6 col-xl-6">
<Welcome />
</div>
<div className="col-12 col-sm-12 col-md-12 col-lg-6 col-xl-6 table">
<div>
<Link to="/"><h3 style={formStyle} className={ window.location.hash.indexOf("/register") !== -1 ? "hover" : "hover checked"} onClick={this.changeClass} >Log In</h3></Link>
<Link to="/register"><h3 style={formStyle} className={ window.location.hash.indexOf("/register") !== -1 ? "hover checked" : "hover"}>Register</h3></Link>
</div>
<div style={switchBox}>
<div>
<Switch>
<Route exact path="/login" component={Login} />
<Route exact path="/register" component={Register} />
</Switch>
</div>
</div>
</div>
</div>

);
}
}

export default EntryPage;
Loading