Skip to content

Commit

Permalink
Merge pull request #28 from LizaHCarter/UX2
Browse files Browse the repository at this point in the history
Ux2
  • Loading branch information
abarnhard committed Sep 2, 2014
2 parents ce6a2e5 + c469639 commit c371f51
Show file tree
Hide file tree
Showing 12 changed files with 261 additions and 71 deletions.
2 changes: 1 addition & 1 deletion app/controllers/users.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ exports.authenticate = function(req, res){
req.session.regenerate(function(){
req.session.userId = user._id;
req.session.save(function(){
res.redirect('/');
res.redirect('/marketplace');
});
});
}else{
Expand Down
2 changes: 1 addition & 1 deletion app/static/css/style.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

174 changes: 168 additions & 6 deletions app/static/css/style.less
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
@bidButton: #ebebeb;
@themeBlue: #0f1c3c;
@themeRed: #711a1a;
@themeGray: #ECECEC;

#brand:hover{
color: #711a1a;
Expand All @@ -15,7 +16,7 @@
}
body{
color: @themeBlue;
background-color: #ECECEC;
background-color: @themeGray;
}

#brand{
Expand Down Expand Up @@ -49,10 +50,7 @@ body{
}

.panel-body{
background-color: #ECECEC;
}
.homePage {
height: 1080px;
background-color: @themeGray;
}

.profile-photo {
Expand Down Expand Up @@ -173,7 +171,7 @@ body{
.bid-photo{
height: 200px;
background-size: cover;
/*background-repeat: no-repeat;*/
background-repeat: no-repeat;
}

.bid-name {
Expand Down Expand Up @@ -209,9 +207,173 @@ body{
background-color: white;
}

// views/user/edit
#editProfile {
background-color:@themeBlue;
}

.input-bar{
margin: 0px;
background-color: @themeRed;
padding: 40px;
color: @themeBlue;
font-size: 20px;
border: 0px;
border-radius: 10px;
text-align: center;
}

.input-bar:hover {
background-color: white;
}

#labels {
background-color: white;
width: 2000px;
margin: 0px;
}

// /user/new.jade

#register {
text-align: center;
}

.btn {
background-color: @themeBlue;
color: white;
}

.btn:hover {
background-color: @themeRed;
color: white;
}

@media screen and (max-width: 480px) {

.register {
text-align: center;
color: @themeBlue;
position: relative;
}
.content-main {
position: relative;
left: 0%;
border: 1px solid @themeBlue;
}
}

@media screen and (min-width: 660px) {

.register {
text-align: center;
color: @themeBlue;
position: relative;
}
.content-main {
position: relative;
left: 38%;
}
form.regLog {
padding: 15px;
border: 1px solid @themeBlue;
width: 400px;
border-radius: 15px;
margin-top: 20px;
}
.backgroundImage {
background-image: url("/img/wine_cellar_bg.png");
background-size: cover;
background-repeat: no-repeat;
}
.cheers {
position: relative;
right: 635px;
top: 75px;
font-size: 100px;
font-family: 'Berkshire Swash', cursive;
}
}

// home/index.jade

.navbar {
margin: 0px;
padding: 15px;
}

.homePage {
background-image: url("/img/wine_cellar_home.png");
background-size: cover;
height: 975px;
position: relative;
margin: 0px auto;
}

#goRegister a {
color: @themeRed;
text-align: center;
font-size: 20px;
position: absolute;
left: 930px;
top: 500px;
/*font-family: 'Berkshire Swash', cursive;*/
font-size: 50px;
padding: 30px;
}


#goLogin a {
color: @themeRed;
text-align: center;
font-size: 20px;
position: absolute;
left: 530px;
top: 500px;
/*font-family: 'Berkshire Swash', cursive;*/
font-size: 50px;
padding: 30px;
}

#goLogin a:hover {
border: 1px solid @themeRed;
border-radius: 15%;
}

#goRegister a:hover {
border: 1px solid @themeRed;
border-radius: 15%;
}

.slogan {
position: absolute;
left: 540px;
top: 150px;
font-family: 'Berkshire Swash', cursive;
font-size: 45px;
color: @themeGray;

}














//
table#ItemsOnSale.table.table-stribed.table-hover.table-bordered {
border: 3px solid #0f1c3c;
}





Binary file added app/static/img/wine_cellar_bg.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/static/img/wine_cellar_home.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 10 additions & 0 deletions app/static/js/user/new-register.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
(function(){
'use strict';

$(document).ready(function(){
$('body').css('display', 'none');
$('body').fadeIn(3000);
});

})();

8 changes: 7 additions & 1 deletion app/views/home/index.jade
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
extends ../shared/template
block content
.homePage(style='background-image: url("/img/wine_seller.png");')
body
.homePage
#goRegister: a(href= '/register') Register
#goLogin: a(href='/login') Login
.slogan . <br/> Bid.<br/> &nbsp &nbsp &nbsp Trade.<br/> &nbsp &nbsp &nbsp &nbsp &nbsp &nbsp &nbsp &nbsp Drink...


block scripts
script(src='/js/user/home.js')

52 changes: 27 additions & 25 deletions app/views/users/edit.jade
Original file line number Diff line number Diff line change
@@ -1,30 +1,32 @@
extends ../shared/template
block content
h2 Edit Profile
.row
.col-xs-6
form(role='form', method='post', action='/profile')
input(type='hidden', name='_method', value='put')
.form-group
label(for='name') Name
input.form-control#name(type='text', name='name', value=user.name, autofocus=true)
.form-group
label(for='email') Email
input.form-control#email(type='email', name='email', value=user.email)
.form-group
label(for='phone') Phone
input.form-control#phone(type='tel', name='phone', value=user.phone)
.form-group
label(for='photo') Photo
input.form-control#photo(type='text', name='photo', value=user.photo)
.form-group
label(for='bio') Bio
input.form-control#bio(type='text', name='bio', value=user.bio)
.form-group
label(for='favorite') Favorite Wine
input.form-control#favorite(type='text', name='favorite', value=user.favorite)
body#editProfile
.row
.col-xs-12.col-md-4
form(role='form', method='post', action='/profile')
input(type='hidden', name='_method', value='put')
.form-group
label(for='name')#labels
input.form-control#name(type='text', name='name', value=user.name, autofocus=true)
.form-group
label(for='email') Email
input.form-control#email(type='email', name='email', value=user.email)
.form-group
label(for='phone') Phone
input.form-control#phone(type='tel', name='phone', value=user.phone)
.form-group
label(for='photo') Photo
input.form-control#photo(type='text', name='photo', value=user.photo)
.form-group
label(for='bio') Bio
input.form-control#bio(type='text', name='bio', value=user.bio)
.form-group
label(for='favorite') Favorite Wine
input.form-control.textBox#favorite(type='text', name='favorite', value=user.favorite)

button.btn.btn-primary(type='submit') Update Profile
.col-xs-6
button.btn.btn-primary(type='submit') Update Profile

.row
.col-xs-12.col-md-12

block scripts
31 changes: 18 additions & 13 deletions app/views/users/login.jade
Original file line number Diff line number Diff line change
@@ -1,17 +1,22 @@
extends ../shared/template
block content
h2 Login
.row
.col-xs-6
form(role='form', method='post', action='/login')
.form-group
label(for='email') Email
input.form-control#email(type='email', name='email', autofocus=true)
.form-group
label(for='password') Password
input.form-control#password(type='password', name='password')
button.btn.btn-success(type='submit') Submit
.col-xs-6
body.backgroundImage
div.register
div.content-main
.row
.col-xs-12.col-md-3
h2.register Login
form.regLog(role='form', method='post', action='/login')
.form-group
label(for='email')
input.form-control.input-bar#email(type='email', name='email', autofocus=true, placeholder= 'Email')
.form-group
label(for='password')
input.form-control.input-bar#password(type='password', name='password', placeholder= 'Password')
button.btn(type='submit') Submit
.cheers Cheers!
.row
.col-xs-12.col-md-3

block scripts
block scripts

49 changes: 27 additions & 22 deletions app/views/users/new.jade
Original file line number Diff line number Diff line change
@@ -1,26 +1,31 @@
extends ../shared/template
block content
h2 Register
.row
.col-xs-6
form(role='form', method='post', action='/register')
.form-group
label(for='name') Name
input.form-control#name(type='text', name='name', autofocus=true)
.form-group
label(for='photo') Photo
input.form-control#photo(type='text', name='photo', placeholder='http://example.com/pic.jpg')
.form-group
label(for='email') Email
input.form-control#email(type='email', name='email')
.form-group
label(for='phone') Phone
input.form-control#phone(type='text', name='phone', placeholder='xxx-xxx-xxxx')
.form-group
label(for='password') Password
input.form-control#password(type='password', name='password')
button.btn.btn-primary(type='submit') Submit
.col-xs-6
body.backgroundImage
div.register
div.content-main
.row
.col-xs-12.col-md-3
h2.register Register
form.regLog(role='form', method='post', action='/register')
.form-group
label(for='name')
input.form-control.input-bar#name(type='text', name='name', placeholder='User Name', autofocus=true)
.form-group
label(for='photo')
input.form-control.input-bar#photo(type='text', name='photo', placeholder='Picture URL')
.form-group
label(for='phone')
input.form-control.input-bar#phone(type='text', name='phone', placeholder='xxx-xxx-xxxx')
.form-group
label(for='email')
input.form-control.input-bar#email(type='email', name='email', placeholder ='Email')
.form-group
label(for='password')
input.form-control.input-bar#password(type='password', name='password', placeholder='Password')
button.btn(type='submit') Submit
.row
.col-xs-12

block scripts
block scripts
script(src='/js/user/new-register.js')

0 comments on commit c371f51

Please sign in to comment.