Skip to content

Commit

Permalink
Combine examples and simple layouts.
Browse files Browse the repository at this point in the history
  • Loading branch information
XhmikosR committed Oct 15, 2018
1 parent 7d6a0aa commit 43c20b9
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 49 deletions.
16 changes: 0 additions & 16 deletions site/_layouts/examples.html

This file was deleted.

15 changes: 14 additions & 1 deletion site/_layouts/simple.html
Expand Up @@ -2,4 +2,17 @@
layout: default
---

{{ content }}
<header class="d-flex flex-column flex-md-row align-items-md-center p-5 bg-light">
<div class="pt-md-3 pb-md-4">
<h1 class="bd-title mt-0">{{ page.title | smartify }}</h1>
<p class="bd-lead">{{ page.description | smartify }}</p>
{%- if page.title == "Examples" -%}
<a href="{{ site.download.source }}" class="btn btn-lg btn-bd-primary" onclick="ga('send', 'event', 'Examples', 'Hero', 'Download');">Download source code</a>
{%- endif -%}
</div>
{% include ads.html %}
</header>

<main class="bd-content p-5" id="content" role="main">
{{ content }}
</main>
2 changes: 1 addition & 1 deletion site/docs/4.1/examples/index.html
@@ -1,5 +1,5 @@
---
layout: examples
layout: simple
title: Examples
description: Quickly get a project started with any of our examples ranging from using parts of the framework to custom components and layouts.
redirect_from: "/examples/"
Expand Down
52 changes: 21 additions & 31 deletions site/docs/versions.html
Expand Up @@ -4,35 +4,25 @@
description: An appendix of hosted documentation for nearly every release of Bootstrap, from v1 through v4.
---

<header class="d-flex flex-column flex-md-row align-items-md-center p-5 bg-light">
<div class="pt-md-3 pb-md-4">
<h1 class="bd-title mt-0">{{ page.title | smartify }}</h1>
<p class="bd-lead">{{ page.description | smartify }}</p>
<div class="row">
{% for release in site.data.docs-versions %}
<div class="col-md">
<h2>{{ release.group }}</h2>
<p>{{ release.description }}</p>
{% for version in release.versions %}
{% if forloop.first %}<div class="list-group">{% endif %}
{% if version.v == site.docs_version %}
<a class="list-group-item list-group-item-action py-2 text-primary d-flex justify-content-between align-items-center" href="{{ release.baseurl }}/{{ version.v }}/">
{{ version.v }}
<span class="badge badge-primary">Latest</span>
</a>
{% else %}
<a class="list-group-item list-group-item-action py-2 text-primary" href="{{ release.baseurl }}/{{ version.v }}/">
{{ version.v }}
</a>
{% endif %}
{% if forloop.last %}</div>{% endif %}
{% endfor %}
</div>
{% include ads.html %}
</header>

<main class="bd-content p-5">
<div class="row">
{% for release in site.data.docs-versions %}
<div class="col-md">
<h2>{{ release.group }}</h2>
<p>{{ release.description }}</p>
{% for version in release.versions %}
{% if forloop.first %}<div class="list-group">{% endif %}
{% if version.v == site.docs_version %}
<a class="list-group-item list-group-item-action py-2 text-primary d-flex justify-content-between align-items-center" href="{{ release.baseurl }}/{{ version.v }}/">
{{ version.v }}
<span class="badge badge-primary">Latest</span>
</a>
{% else %}
<a class="list-group-item list-group-item-action py-2 text-primary" href="{{ release.baseurl }}/{{ version.v }}/">
{{ version.v }}
</a>
{% endif %}
{% if forloop.last %}</div>{% endif %}
{% endfor %}
</div>
{% endfor %}
</div>
</main>
{% endfor %}
</div>

0 comments on commit 43c20b9

Please sign in to comment.