Skip to content

Commit

Permalink
Got the next page/last page nav arrows working at the top of the page
Browse files Browse the repository at this point in the history
Also renamed some CSS into SuitCSS style utils to make things a little easier to refactor / understand
  • Loading branch information
Sam Jewell committed Dec 12, 2014
1 parent b55a637 commit 27d2bb4
Show file tree
Hide file tree
Showing 15 changed files with 157 additions and 106 deletions.
18 changes: 9 additions & 9 deletions guide/assets/css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,26 +7,26 @@ body {
margin: 0;
}

.right {
.u-floatRight {
float: right;
}

.left {
.u-floatLeft {
float: left;
}

.tar {
.u-textCenter {
text-align: center;
}

.u-textRight {
text-align: right;
}

li {
padding-bottom: 4px;
}

.nav {
text-align: center;
}

.wrapper {
width: 600px;
margin: 30px auto;
Expand All @@ -44,7 +44,7 @@ li {
.hand {
font-size: 40px;
padding: 9px 12px;
/* color: #ff00ff;*/
color: #0087ff;
}

.challenge-band h2, .number-band h2 {
Expand Down Expand Up @@ -281,6 +281,6 @@ n, v, adj {
opacity: 0.8;
}

.u-inline-block {
.u-inlineBlock {
display: inline-block;
}
5 changes: 4 additions & 1 deletion guide/buildpages.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,13 +69,16 @@ function makeTitleName(filename) {

function buildHeader(filename) {
var num = filename.split('/').pop().split('_')[0]
var data = getPrevious(num)
var title = makeTitleName(filename)
var source = fs.readFileSync(__dirname + '/partials/header.html').toString()
var template = Handlebars.compile(source)
var content = {
challengetitle: title,
challengenumber: num,
lang: lang ? '-' + lang : ''
lang: lang ? '-' + lang : '',
preurl: data.preurl,
nexturl: data.nexturl
}
return template(content)
}
Expand Down
20 changes: 12 additions & 8 deletions guide/challenges/branches_arent_just_for_birds.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,22 @@
<![endif]-->

<header class="site-header">
<div class="nav">
<!-- <span class="left hand">☜</span> -->
<div class="u-textCenter">
<a href="forks_and_clones.html"
<span class="u-floatLeft hand"></span>
</a>
<span class="filledblock"><a href="../index.html">Git-it</a></span>
<!-- <span class="right hand">☞</span> -->
<a href="its_a_small_world.html"
<span class="u-floatRight hand"></span>
</a>
</div>

<div class="wrapper">
<div class="challenge-band left">
<div class="challenge-band u-floatLeft">
<span class="meta">CHALLENGE</span>
<h2>branches aren&#x27;t just for birds</h2>
</div>
<div class="number-band right tar">
<div class="number-band u-floatRight u-textRight">
<span class="meta">NUMBER</span>
<h2>7 / 11</h2>
<div>
Expand Down Expand Up @@ -142,13 +146,13 @@ <h2>Tips</h2>


<div class="prenext">
<div class="pre lef meta">
<div class="pre u-floatLeft meta">
<a href="forks_and_clones.html" class="u-inline-block">forks and clones
<div></div>
</a>
</div>
<div class="next tar right meta">
<a href="its_a_small_world.html" class="u-inline-block">it&#x27;s a small world
<div class="next u-textRight u-floatRight meta">
<a href="its_a_small_world.html" class="u-inlineBlock">it&#x27;s a small world
<div></div>
</a>
</div>
Expand Down
20 changes: 12 additions & 8 deletions guide/challenges/commit_to_it.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,22 @@
<![endif]-->

<header class="site-header">
<div class="nav">
<!-- <span class="left hand">☜</span> -->
<div class="u-textCenter">
<a href="repository.html"
<span class="u-floatLeft hand"></span>
</a>
<span class="filledblock"><a href="../index.html">Git-it</a></span>
<!-- <span class="right hand">☞</span> -->
<a href="githubbin.html"
<span class="u-floatRight hand"></span>
</a>
</div>

<div class="wrapper">
<div class="challenge-band left">
<div class="challenge-band u-floatLeft">
<span class="meta">CHALLENGE</span>
<h2>commit to it</h2>
</div>
<div class="number-band right tar">
<div class="number-band u-floatRight u-textRight">
<span class="meta">NUMBER</span>
<h2>3 / 11</h2>
<div>
Expand Down Expand Up @@ -97,13 +101,13 @@ <h2>Tips</h2>


<div class="prenext">
<div class="pre lef meta">
<div class="pre u-floatLeft meta">
<a href="repository.html" class="u-inline-block">repository
<div></div>
</a>
</div>
<div class="next tar right meta">
<a href="githubbin.html" class="u-inline-block">GitHubbin
<div class="next u-textRight u-floatRight meta">
<a href="githubbin.html" class="u-inlineBlock">GitHubbin
<div></div>
</a>
</div>
Expand Down
20 changes: 12 additions & 8 deletions guide/challenges/forks_and_clones.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,22 @@
<![endif]-->

<header class="site-header">
<div class="nav">
<!-- <span class="left hand">☜</span> -->
<div class="u-textCenter">
<a href="remote_control.html"
<span class="u-floatLeft hand"></span>
</a>
<span class="filledblock"><a href="../index.html">Git-it</a></span>
<!-- <span class="right hand">☞</span> -->
<a href="branches_arent_just_for_birds.html"
<span class="u-floatRight hand"></span>
</a>
</div>

<div class="wrapper">
<div class="challenge-band left">
<div class="challenge-band u-floatLeft">
<span class="meta">CHALLENGE</span>
<h2>forks and clones</h2>
</div>
<div class="number-band right tar">
<div class="number-band u-floatRight u-textRight">
<span class="meta">NUMBER</span>
<h2>6 / 11</h2>
<div>
Expand Down Expand Up @@ -110,13 +114,13 @@ <h2>Tips</h2>


<div class="prenext">
<div class="pre lef meta">
<div class="pre u-floatLeft meta">
<a href="remote_control.html" class="u-inline-block">remote control
<div></div>
</a>
</div>
<div class="next tar right meta">
<a href="branches_arent_just_for_birds.html" class="u-inline-block">branches aren&#x27;t just for birds
<div class="next u-textRight u-floatRight meta">
<a href="branches_arent_just_for_birds.html" class="u-inlineBlock">branches aren&#x27;t just for birds
<div></div>
</a>
</div>
Expand Down
20 changes: 12 additions & 8 deletions guide/challenges/get_git.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,22 @@
<![endif]-->

<header class="site-header">
<div class="nav">
<!-- <span class="left hand">☜</span> -->
<div class="u-textCenter">
<a href="../index.html"
<span class="u-floatLeft hand"></span>
</a>
<span class="filledblock"><a href="../index.html">Git-it</a></span>
<!-- <span class="right hand">☞</span> -->
<a href="repository.html"
<span class="u-floatRight hand"></span>
</a>
</div>

<div class="wrapper">
<div class="challenge-band left">
<div class="challenge-band u-floatLeft">
<span class="meta">CHALLENGE</span>
<h2>get git</h2>
</div>
<div class="number-band right tar">
<div class="number-band u-floatRight u-textRight">
<span class="meta">NUMBER</span>
<h2>1 / 11</h2>
<div>
Expand Down Expand Up @@ -102,13 +106,13 @@ <h2>Tips</h2>


<div class="prenext">
<div class="pre lef meta">
<div class="pre u-floatLeft meta">
<a href="../index.html" class="u-inline-block">All Challenges
<div></div>
</a>
</div>
<div class="next tar right meta">
<a href="repository.html" class="u-inline-block">repository
<div class="next u-textRight u-floatRight meta">
<a href="repository.html" class="u-inlineBlock">repository
<div></div>
</a>
</div>
Expand Down
20 changes: 12 additions & 8 deletions guide/challenges/githubbin.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,22 @@
<![endif]-->

<header class="site-header">
<div class="nav">
<!-- <span class="left hand">☜</span> -->
<div class="u-textCenter">
<a href="commit_to_it.html"
<span class="u-floatLeft hand"></span>
</a>
<span class="filledblock"><a href="../index.html">Git-it</a></span>
<!-- <span class="right hand">☞</span> -->
<a href="remote_control.html"
<span class="u-floatRight hand"></span>
</a>
</div>

<div class="wrapper">
<div class="challenge-band left">
<div class="challenge-band u-floatLeft">
<span class="meta">CHALLENGE</span>
<h2>GitHubbin</h2>
</div>
<div class="number-band right tar">
<div class="number-band u-floatRight u-textRight">
<span class="meta">NUMBER</span>
<h2>4 / 11</h2>
<div>
Expand Down Expand Up @@ -79,13 +83,13 @@ <h4>GitHub & Git config usernames do not match</h4>


<div class="prenext">
<div class="pre lef meta">
<div class="pre u-floatLeft meta">
<a href="commit_to_it.html" class="u-inline-block">commit to it
<div></div>
</a>
</div>
<div class="next tar right meta">
<a href="remote_control.html" class="u-inline-block">remote control
<div class="next u-textRight u-floatRight meta">
<a href="remote_control.html" class="u-inlineBlock">remote control
<div></div>
</a>
</div>
Expand Down
20 changes: 12 additions & 8 deletions guide/challenges/its_a_small_world.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,22 @@
<![endif]-->

<header class="site-header">
<div class="nav">
<!-- <span class="left hand">☜</span> -->
<div class="u-textCenter">
<a href="branches_arent_just_for_birds.html"
<span class="u-floatLeft hand"></span>
</a>
<span class="filledblock"><a href="../index.html">Git-it</a></span>
<!-- <span class="right hand">☞</span> -->
<a href="pull_never_out_of_date.html"
<span class="u-floatRight hand"></span>
</a>
</div>

<div class="wrapper">
<div class="challenge-band left">
<div class="challenge-band u-floatLeft">
<span class="meta">CHALLENGE</span>
<h2>it&#x27;s a small world</h2>
</div>
<div class="number-band right tar">
<div class="number-band u-floatRight u-textRight">
<span class="meta">NUMBER</span>
<h2>8 / 11</h2>
<div>
Expand Down Expand Up @@ -67,13 +71,13 @@ <h3>Go to the next challenge </h3> <code>git-it</code>


<div class="prenext">
<div class="pre lef meta">
<div class="pre u-floatLeft meta">
<a href="branches_arent_just_for_birds.html" class="u-inline-block">branches aren&#x27;t just for birds
<div></div>
</a>
</div>
<div class="next tar right meta">
<a href="pull_never_out_of_date.html" class="u-inline-block">pull never out of date
<div class="next u-textRight u-floatRight meta">
<a href="pull_never_out_of_date.html" class="u-inlineBlock">pull never out of date
<div></div>
</a>
</div>
Expand Down
20 changes: 12 additions & 8 deletions guide/challenges/merge_tada.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,22 @@
<![endif]-->

<header class="site-header">
<div class="nav">
<!-- <span class="left hand">☜</span> -->
<div class="u-textCenter">
<a href="requesting_you_pull_please.html"
<span class="u-floatLeft hand"></span>
</a>
<span class="filledblock"><a href="../index.html">Git-it</a></span>
<!-- <span class="right hand">☞</span> -->
<a href="../index.html"
<span class="u-floatRight hand"></span>
</a>
</div>

<div class="wrapper">
<div class="challenge-band left">
<div class="challenge-band u-floatLeft">
<span class="meta">CHALLENGE</span>
<h2>merge tada</h2>
</div>
<div class="number-band right tar">
<div class="number-band u-floatRight u-textRight">
<span class="meta">NUMBER</span>
<h2>11 / 11</h2>
<div>
Expand Down Expand Up @@ -101,13 +105,13 @@ <h2>Tips</h2>


<div class="prenext">
<div class="pre lef meta">
<div class="pre u-floatLeft meta">
<a href="requesting_you_pull_please.html" class="u-inline-block">requesting you pull please
<div></div>
</a>
</div>
<div class="next tar right meta">
<a href="../index.html" class="u-inline-block">Done!
<div class="next u-textRight u-floatRight meta">
<a href="../index.html" class="u-inlineBlock">Done!
<div></div>
</a>
</div>
Expand Down
Loading

0 comments on commit 27d2bb4

Please sign in to comment.