Skip to content

Commit

Permalink
Add scrolling effect.
Browse files Browse the repository at this point in the history
Add 'About' section.
  • Loading branch information
maxep committed Apr 10, 2015
1 parent 91cefa2 commit 62e43ce
Show file tree
Hide file tree
Showing 8 changed files with 150 additions and 51 deletions.
12 changes: 12 additions & 0 deletions _includes/about.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<!-- About Section -->
<section id="about" class="container content-section text-center">
<div class="row">
<div class="col-lg-8 col-lg-offset-2">
<h2>About Landing-Page</h2>
<p>Landing-Page is a free Bootstrap 3 theme created by Start Bootstrap. It can be yours right now, simply download the template on <a href="http://startbootstrap.com/template-overviews/landing-page/">the preview page</a>. The theme is open source, and you can use it for any purpose, personal or commercial.</p>
<p>The Jekyll version is brought to you by <a href="https://github.com/swcool">Shane Weng</a></p>
<p>This theme features stock photos by <a href="http://join.deathtothestockphoto.com//">Death to the Stock Photo</a>.</p>
<p>Landing-Page includes full HTML, CSS, and custom JavaScript files along with LESS files for easy customization.</p>
</div>
</div>
</section>
41 changes: 21 additions & 20 deletions _includes/contact.html
Original file line number Diff line number Diff line change
@@ -1,24 +1,25 @@
<div class="banner">
<section id="contact">
<div class="banner">
<div class="container">

<div class="container">
<div class="row">
<div class="col-lg-6">
<h2>Keep in Touch:</h2>
</div>
<div class="col-lg-6">
<ul class="list-inline banner-social-buttons">
{% for social in site.social %}
<li>
<a href="{{ social.url }}" class="btn btn-default btn-lg"><i class="fa fa-{{ social.title }} fa-fw"></i> <span class="network-name">{{ social.title }}</span></a>
</li>
{% endfor %}
</ul>
</div>
</div>

<div class="row">
<div class="col-lg-6">
<h2>Connect to Start Bootstrap:</h2>
</div>
<div class="col-lg-6">
<ul class="list-inline banner-social-buttons">
{% for social in site.social %}
<li>
<a href="{{ social.url }}" class="btn btn-default btn-lg"><i class="fa fa-{{ social.title }} fa-fw"></i> <span class="network-name">{{ social.title }}</span></a>
</li>
{% endfor %}
</ul>
</div>
</div>
</div>
<!-- /.container -->

</div>
<!-- /.container -->

</div>
</div>
</section>
<!-- /.banner -->
62 changes: 32 additions & 30 deletions _includes/header.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,26 +2,26 @@
<nav class="navbar navbar-default navbar-fixed-top" role="navigation">
<div class="container">
<!-- Brand and toggle get grouped for better mobile display -->
<div class="navbar-header">
<div class="navbar-header page-scroll">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="#">{{ site.title }}</a>
<a class="navbar-brand page-scroll" href="#home">{{ site.title }}</a>
</div>
<!-- Collect the nav links, forms, and other content for toggling -->
<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
<ul class="nav navbar-nav navbar-right">
<ul class="nav navbar-nav navbar-right">
<li>
<a class="page-scroll" href="#about">About</a>
</li>
<li>
<a href="#">About</a>
<a class="page-scroll" href="#services">Services</a>
</li>
<li>
<a href="#">Services</a>
</li>
<li>
<a href="#">Contact</a>
<a class="page-scroll" href="#contact">Contact</a>
</li>
</ul>
</div>
Expand All @@ -30,30 +30,32 @@
<!-- /.container -->
</nav>

<section id="home">
<!-- Header -->
<div class="intro-header">
<div class="intro-header">

<div class="container">
<div class="container">

<div class="row">
<div class="col-lg-12">
<div class="intro-message">
<h1>{{ page.title }}</h1>
<h3>{{ page.subTitle }}</h3>
<hr class="intro-divider">
<ul class="list-inline intro-social-buttons">
{% for social in site.social %}
<li>
<a href="{{ social.url }}" class="btn btn-default btn-lg"><i class="fa fa-{{ social.title }} fa-fw"></i> <span class="network-name">{{ social.title }}</span></a>
</li>
{% endfor %}
</ul>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-12">
<div class="intro-message">
<h1>{{ page.title }}</h1>
<h3>{{ page.subTitle }}</h3>
<hr class="intro-divider">
<ul class="list-inline intro-social-buttons">
{% for social in site.social %}
<li>
<a href="{{ social.url }}" class="btn btn-default btn-lg"><i class="fa fa-{{ social.title }} fa-fw"></i> <span class="network-name">{{ social.title }}</span></a>
</li>
{% endfor %}
</ul>
</div>
</div>
</div>

</div>
<!-- /.container -->
</div>
<!-- /.container -->

</div>
<!-- /.intro-header -->
</div>
<!-- /.intro-header -->
</section>
6 changes: 6 additions & 0 deletions _includes/js.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
<!-- jQuery Version 1.11.0 -->
<script src="js/jquery-1.11.0.js"></script>

<!-- Plugin JavaScript -->
<script src="{{ "/js/jquery.easing.min.js" | prepend: site.baseurl }}"></script>

<!-- Bootstrap Core JavaScript -->
<script src="js/bootstrap.min.js"></script>

<!-- Custom Theme JavaScript -->
<script src="js/landing-page.js"></script>
2 changes: 2 additions & 0 deletions _includes/page_content.html → _includes/services.html
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
<section id="services">
<!-- Page Content -->
{% for post in site.posts reversed %}
{% capture thecycle %}{% cycle 'odd', 'even' %}{% endcapture %}
Expand Down Expand Up @@ -48,3 +49,4 @@ <h2 class="section-heading">{{ post.title }}</h2>
<!-- /.content-section-b -->
{% endif %}
{% endfor %}
</section>
3 changes: 2 additions & 1 deletion _layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@

<body>
{% include header.html %}
{% include page_content.html %}
{% include about.html %}
{% include services.html %}
{% include contact.html %}
{% include footer.html %}
{% include js.html %}
Expand Down
44 changes: 44 additions & 0 deletions js/jquery.easing.min.js

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

31 changes: 31 additions & 0 deletions js/landing-page.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
// jQuery for page scrolling feature - requires jQuery Easing plugin
$(function() {
$('a.page-scroll').bind('click', function(event) {
var $anchor = $(this);
$('html, body').stop().animate({
scrollTop: $($anchor.attr('href')).offset().top
}, 1500, 'easeInOutExpo');
event.preventDefault();
});
});

// Highlight the top nav as scrolling occurs
$('body').scrollspy({
target: '.navbar-fixed-top'
})

// Closes the Responsive Menu on Menu Item Click
$('.navbar-collapse ul li a').click(function() {
$('.navbar-toggle:visible').click();
});

$('div.modal').on('show.bs.modal', function() {
var modal = this;
var hash = modal.id;
window.location.hash = hash;
window.onhashchange = function() {
if (!location.hash){
$(modal).modal('hide');
}
}
});

0 comments on commit 62e43ce

Please sign in to comment.