Skip to content

Commit

Permalink
Merge pull request #38 from FAC-11/styling
Browse files Browse the repository at this point in the history
Styling is 💯
  • Loading branch information
Jen-Harris authored Aug 17, 2017
2 parents 9010a00 + 990547f commit daecdee
Show file tree
Hide file tree
Showing 11 changed files with 210 additions and 23 deletions.
62 changes: 62 additions & 0 deletions public/LightBulb2.svg
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 public/lightbulb-white.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 public/lightbulb-yellow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
26 changes: 25 additions & 1 deletion public/main.js
Original file line number Diff line number Diff line change
@@ -1 +1,25 @@

(function () {
var icon = document.getElementById('js-icon');
var text = document.getElementsByClassName('text');
var isOn = false;
for(var i = 0; i < text.length; i++){
text[i].style.color = 'white';
}
icon.addEventListener('click', function(e) {
if (!isOn) {
icon.setAttribute('src', '/lightbulb-yellow.png');
document.body.style.backgroundColor = 'white';
for(var i = 0; i < text.length; i++){
text[i].style.color = 'black';
}
isOn = true;
} else {
icon.src = '/lightbulb-white.png';
document.body.style.backgroundColor = '#2b2b2b';
for(var i = 0; i < text.length; i++){
text[i].style.color = 'white';
}
isOn = false;
}
});
})();
108 changes: 101 additions & 7 deletions public/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@

body {
text-align: center;
margin: auto;
background-color: #2b2b2b;
font-family: 'Dosis', sans-serif;
transition: 2s ease;
}

a {
Expand All @@ -16,17 +20,107 @@ h1 {
}

img {
display: block;
margin: 0 auto;
display: block;
margin: 0 auto;
}

.fa-lightbulb-o {
font-size: 250px;
.icon {
width: 10vw;
margin: 5vh auto;
transition: 2s ease;
}

.landing_btn {
display: block;
margin: 10px auto;
width: 300px;
height: 100px;
font-size: 3vw;
padding: 2rem;
margin: 1.5rem auto;
border-radius: 10px;
font-family: 'Dosis', sans-serif;
cursor: pointer;
text-decoration: none;
}

.landing_btn--skills {
background-color: #FF7C4C;
border: 1px solid #C63C09;
box-shadow: 0px 6px 0px #D13700, 0px 3px 15px rgba(0, 0, 0, .4);
box-shadow: inset 0px 1px 0px rgba(255, 255, 255, .3);
box-shadow: inset 0px 0px 3px rgba(255, 255, 255, .5);
-webkit-box-shadow: 0px 6px 0px #D13700, 0px 3px 15px rgba(0, 0, 0, .4), inset 0px 1px 0px rgba(255, 255, 255, .3), inset 0px 0px 3px rgba(255, 255, 255, .5);
-moz-box-shadow: 0px 6px 0px #D13700, 0px 3px 15px rgba(0, 0, 0, .4), inset 0px 1px 0px rgba(255, 255, 255, .3), inset 0px 0px 3px rgba(255, 255, 255, .5);
box-shadow: 0px 6px 0px #C63C09, 0px 3px 15px rgba(0, 0, 0, .4), inset 0px 1px 0px rgba(255, 255, 255, .3), inset 0px 0px 3px rgba(255, 255, 255, .5);
}

.landing_btn--idea {
background-color: #8AE1FC;
border: 1px solid #2d6898;
box-shadow: 0px 6px 0px #2b638f, 0px 3px 15px rgba(0, 0, 0, .4);
box-shadow: inset 0px 1px 0px rgba(255, 255, 255, .3);
box-shadow: inset 0px 0px 3px rgba(255, 255, 255, .5);
-webkit-box-shadow: 0px 6px 0px #2b638f, 0px 3px 15px rgba(0, 0, 0, .4), inset 0px 1px 0px rgba(255, 255, 255, .3), inset 0px 0px 3px rgba(255, 255, 255, .5);
-moz-box-shadow: 0px 6px 0px #2b638f, 0px 3px 15px rgba(0, 0, 0, .4), inset 0px 1px 0px rgba(255, 255, 255, .3), inset 0px 0px 3px rgba(255, 255, 255, .5);
box-shadow: 0px 6px 0px #2b638f, 0px 3px 15px rgba(0, 0, 0, .4), inset 0px 1px 0px rgba(255, 255, 255, .3), inset 0px 0px 3px rgba(255, 255, 255, .5);
}
}

.header {
color: white;
font-family: 'Dosis', sans-serif;
font-size: 2rem;
}

.footer {
color: white;
font-family: 'Dosis', sans-serif;
font-size: 1.5rem;
margin-top: 2rem;
}

a {
text-decoration: none;
color: inherit;
}

.form__label{
display: block;
font-size: 2vw;
color: white;
margin-bottom: 1vh;
}

.idea-form input {
margin-bottom: 3.5vh;
width: 30vw;
font-size: 2vw;
}

.idea-form textarea {
font-size: 2vw;

}
.submit {
font-size: 5vh;
background-color: #44FFD1;
padding: 1vw;
width: auto;
margin-top: 2vh;
border-radius: 10px;
background-color: #44FFD1;
border: 1px solid #207d66;
box-shadow: 0px 6px 0px #207d66, 0px 3px 15px rgba(0, 0, 0, .4);
box-shadow: inset 0px 1px 0px rgba(255, 255, 255, .3);
box-shadow: inset 0px 0px 3px rgba(255, 255, 255, .5);
-webkit-box-shadow: 0px 6px 0px #207d66, 0px 3px 15px rgba(0, 0, 0, .4), inset 0px 1px 0px rgba(255, 255, 255, .3), inset 0px 0px 3px rgba(255, 255, 255, .5);
-moz-box-shadow: 0px 6px 0px #207d66, 0px 3px 15px rgba(0, 0, 0, .4), inset 0px 1px 0px rgba(255, 255, 255, .3), inset 0px 0px 3px rgba(255, 255, 255, .5);
box-shadow: 0px 6px 0px #207d66, 0px 3px 15px rgba(0, 0, 0, .4), inset 0px 1px 0px rgba(255, 255, 255, .3), inset 0px 0px 3px rgba(255, 255, 255, .5);
cursor: pointer;
}

.btn_browse {
display: inline;
}

.block {
display: inline-block;
}
6 changes: 4 additions & 2 deletions src/views/browse.hbs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{{#each data}}
<a href="/browse/{{this.userid}}">
<h1 style="text-align: center; font-family: sans-serif;">{{this.ideatitle}}</h1>
<a href="/browse/{{this.userid}}" class="block">
<button class="landing_btn btn_browse">
{{this.ideatitle}}
</button>
</a>
{{/each}}
7 changes: 2 additions & 5 deletions src/views/home.hbs
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
<i class="fa fa-lightbulb-o" aria-hidden="true"></i>



<a href="/new-idea"><button type="button" name="btn_haveidea" class="landing_btn">HAVE AN IDEA?</button></a>
<a href="/browse"><button type="button" name="btn_gotskills" class="landing_btn">GOT SKILLS?</button></a>
<a href="/new-idea"><button type="button" name="btn_haveidea" class="landing_btn landing_btn--idea">Have an idea?</button></a>
<a href="/browse"><button type="button" name="btn_gotskills" class="landing_btn landing_btn--skills">Got the skillz?</button></a>
15 changes: 10 additions & 5 deletions src/views/new-idea.hbs
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@

<form class="idea-form" action="/new-idea" method="POST">
<input type="text" name="firstname"></input>
<input type="email" name="email"></input>
<input type="text" name="ideatitle"></input>
<textarea rows="4" cols="50" name="ideadesc"></textarea>
<input type="submit">
<label for="form-name" class="form__label text">First name: </label>
<input id="form-name" type="text" name="firstname" class="idea-form__name" placeholder="Type your firstname" aria-label="Type your firstname"></input>
<label for="form-email" class="form__label text">Your email: </label>
<input id="form-email" type="email" name="email" class="idea-form__email" placeholder="Type your email address" aria-label="Type your email address"></input>
<label for="form-idea" class="form__label text">Your idea: </label>
<input id="form-idea" type="text" name="ideatitle" class="idea-form__ideatitle" placeholder="Your idea!" aria-label="name your idea"></input>
<label for="form-ideadesc" class="form__label text">Tell us more! </label>
<textarea id="form-ideadesc" rows="4" cols="25" name="ideadesc" class="idea-form__ideadesc" placeholder="A little bit more detail..." aria-label="describe your idea"></textarea>
<input type="submit" class="submit">
</form>
6 changes: 4 additions & 2 deletions src/views/partials/footer.hbs
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
<footer>
<footer class="footer text">

Brought to you by <a href="https://github.com/maxgerber">Max, </a><a href="https://github.com/rebecacalvoquintero">Rebeca, </a><a href="https://github.com/AbdullahChaudhry">Abdullah and </a><a href="https://github.com/Jen-Harris">Jen </a>
<br>
&copy;2017



</footer>
<script src="/main.js"></script>
2 changes: 1 addition & 1 deletion src/views/partials/header.hbs
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<p>This is where the header will go</p>
<img class="icon" src="/lightbulb-white.png" id="js-icon">
1 change: 1 addition & 0 deletions src/views/partials/htmlHead.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
<!-- add handlebars if here, to check if active page is '/', then load the font awesome library, and turn on the css class -->
{{#if activePage.home }} <script src="https://use.fontawesome.com/21e1269ed9.js"></script>
{{/if}}
<link href="https://fonts.googleapis.com/css?family=Dosis" rel="stylesheet">
<link rel="stylesheet" href="style.css">
<title>FACtory</title>
</head>

0 comments on commit daecdee

Please sign in to comment.