aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/_includes
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2015-05-06 06:17:59 +0300
committerEgor Tensin <Egor.Tensin@gmail.com>2015-05-06 06:17:59 +0300
commit4e11e6d5364a12650b9a139495bd5a73943ae56a (patch)
tree061edcaa62c6b7f65f80109c42b2181840a89250 /_includes
downloadsorting-algorithms-4e11e6d5364a12650b9a139495bd5a73943ae56a.tar.gz
sorting-algorithms-4e11e6d5364a12650b9a139495bd5a73943ae56a.zip
initial commit
Diffstat (limited to '')
-rw-r--r--_includes/footer.html23
-rw-r--r--_includes/header.html28
-rw-r--r--_includes/links.html11
-rw-r--r--_includes/navbar.html20
-rw-r--r--_includes/pagination.html30
-rw-r--r--_includes/sidebar.html16
6 files changed, 128 insertions, 0 deletions
diff --git a/_includes/footer.html b/_includes/footer.html
new file mode 100644
index 0000000..3bfc5a2
--- /dev/null
+++ b/_includes/footer.html
@@ -0,0 +1,23 @@
+ </div>
+ </div>
+ <div class="block">
+ <footer class="navbar-default">
+ <div class="container">
+ <div style="display: table; width: 100%;">
+ <div style="display: table-row;">
+ <div style="display: table-cell;">
+ <div class="text-mutex"><small>This project is licensed under the terms of the MIT License. See <a href="https://github.com/egor-tensin/egor-tensin.github.io#licensing">Licensing</a> for details.</small></div>
+ </div>
+ <div style="display: table-cell;">
+ <div class="text-right text-muted"><small>This blog was last updated on: {{ site.time | date_to_long_string }}.</small></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </footer>
+ </div>
+ </div>
+ <script src="//code.jquery.com/jquery-1.11.0.js"></script>
+ <script src="//maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.js"></script>
+ </body>
+</html>
diff --git a/_includes/header.html b/_includes/header.html
new file mode 100644
index 0000000..67f0bb3
--- /dev/null
+++ b/_includes/header.html
@@ -0,0 +1,28 @@
+<!DOCTYPE html>
+<html lang="en">
+ <head>
+ <meta charset="utf-8">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
+ <title>{{ page.title }}</title>
+ <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.css">
+
+ <link rel="stylesheet" href="{{ site.baseurl }}/css/syntax.css">
+ <link rel="stylesheet" href="{{ site.baseurl }}/css/footer.css">
+ <link rel="stylesheet" href="{{ site.baseurl }}/css/plots.css">
+
+ <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
+ <!--[if lt IE 9]>
+ <script src="//oss.maxcdn.com/html5shiv/3.7.2/html5shiv.js"></script>
+ <script src="//oss.maxcdn.com/respond/1.4.2/respond.js"></script>
+ <![endif]-->
+ </head>
+ <body>
+ <script src="{{ site.baseurl }}/js/common.js"></script>
+
+ <div class="wrapper">
+ <div class="block">
+ {% include navbar.html %}
+ </div>
+ <div class="block push">
+ <div class="container">
diff --git a/_includes/links.html b/_includes/links.html
new file mode 100644
index 0000000..70e643b
--- /dev/null
+++ b/_includes/links.html
@@ -0,0 +1,11 @@
+{% for node in page_list %}
+ {% if group == null or group == node.group %}
+ {% if page.url == node.url %}
+ <li class="active"><a href="{{ site.baseurl }}{{ node.url }}" class="active">{{ node.title }}</a></li>
+ {% else %}
+ <li><a href="{{ site.baseurl }}{{ node.url }}">{{ node.title }}</a></li>
+ {% endif %}
+ {% endif %}
+{% endfor %}
+{% assign page_list = nil %}
+{% assign group = nil %}
diff --git a/_includes/navbar.html b/_includes/navbar.html
new file mode 100644
index 0000000..f052baa
--- /dev/null
+++ b/_includes/navbar.html
@@ -0,0 +1,20 @@
+<nav class="navbar navbar-default navbar-static-top" role="navigation">
+ <div class="container">
+ <div class="navbar-header">
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
+ <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="/">Egor Tensin</a>
+ </div>
+ <div class="navbar-collapse collapse">
+ <ul class="nav navbar-nav">
+ {% assign page_list = site.pages %}
+ {% assign group = 'navigation' %}
+ {% include links.html %}
+ </ul>
+ </div>
+ </div>
+</nav>
diff --git a/_includes/pagination.html b/_includes/pagination.html
new file mode 100644
index 0000000..aa2f034
--- /dev/null
+++ b/_includes/pagination.html
@@ -0,0 +1,30 @@
+{% if site.posts.size != 0 %}
+<ul class="pagination">
+ {% if paginator.previous_page %}
+ {% if paginator.previous_page == 1 %}
+ <li><a href="{{ site.baseurl }}/"><span class="glyphicon glyphicon-chevron-left"></span>&nbsp;Prev</a></li>
+ {% else %}
+ <li><a href="{{ site.baseurl }}/page{{ paginator.previous_page }}"><span class="glyphicon glyphicon-chevron-left"></span>&nbsp;Prev</a></li>
+ {% endif %}
+ {% else %}
+ <li class="disabled"><a href="#"><span class="glyphicon glyphicon-chevron-left"></span>&nbsp;Prev</a></li>
+ {% endif %}
+ {% if paginator.page == 1 %}
+ <li class="active"><a href="{{ site.baseurl }}/">1</a></li>
+ {% else %}
+ <li><a href="{{ site.baseurl }}/">1</a></li>
+ {% endif %}
+ {% for count in (2..paginator.total_pages) %}
+ {% if count == paginator.page %}
+ <li class="active"><a href="{{ site.baseurl }}/page{{ count }}">{{ count }}</a></li>
+ {% else %}
+ <li><a href="{{ site.baseurl }}/page{{ count }}">{{ count }}</a></li>
+ {% endif %}
+ {% endfor %}
+ {% if paginator.next_page %}
+ <li><a href="{{ site.baseurl }}/page{{ paginator.next_page }}">Next&nbsp;<span class="glyphicon glyphicon-chevron-right"></span></a></li>
+ {% else %}
+ <li class="disabled"><a href="#">Next&nbsp;<span class="glyphicon glyphicon-chevron-right"></span></a></li>
+ {% endif %}
+</ul>
+{% endif %}
diff --git a/_includes/sidebar.html b/_includes/sidebar.html
new file mode 100644
index 0000000..cb5b538
--- /dev/null
+++ b/_includes/sidebar.html
@@ -0,0 +1,16 @@
+<h4>About the project</h4>
+<p>Getting the hang out of the sorting algorithms. Feel free to contribute or contact me.</p>
+<div class="list-group" style="max-width: 400px;">
+ <a class="list-group-item" href="//github.com/egor-tensin/sorting_algorithms"><span class="glyphicon glyphicon-home"></span>&nbsp;GitHub repository</a>
+ <a class="list-group-item" href="mailto:Egor.Tensin@gmail.com"><span class="glyphicon glyphicon-envelope"></span>&nbsp;Egor.Tensin@gmail.com</a>
+</div>
+<h4>Latest posts</h4>
+{% if site.posts.size == 0 %}
+ <p>Sorry, there're no posts yet.</p>
+{% else %}
+ <div class="list-group">
+ {% for post in site.posts limit: 5 %}
+ <a class="list-group-item" href="{{ site.baseurl }}{{ post.url }}"><span class="badge"><span class="glyphicon glyphicon-time"></span>&nbsp;{{ post.date | date_to_string }}</span><span class="glyphicon glyphicon-file"></span>&nbsp;{{ post.title }}</a>
+ {% endfor %}
+ </div>
+{% endif %}