Skip to content

Commit 43c20b9

Browse files
committed
Combine examples and simple layouts.
1 parent 7d6a0aa commit 43c20b9

4 files changed

Lines changed: 36 additions & 49 deletions

File tree

site/_layouts/examples.html

Lines changed: 0 additions & 16 deletions
This file was deleted.

site/_layouts/simple.html

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,17 @@
22
layout: default
33
---
44

5-
{{ content }}
5+
<header class="d-flex flex-column flex-md-row align-items-md-center p-5 bg-light">
6+
<div class="pt-md-3 pb-md-4">
7+
<h1 class="bd-title mt-0">{{ page.title | smartify }}</h1>
8+
<p class="bd-lead">{{ page.description | smartify }}</p>
9+
{%- if page.title == "Examples" -%}
10+
<a href="{{ site.download.source }}" class="btn btn-lg btn-bd-primary" onclick="ga('send', 'event', 'Examples', 'Hero', 'Download');">Download source code</a>
11+
{%- endif -%}
12+
</div>
13+
{% include ads.html %}
14+
</header>
15+
16+
<main class="bd-content p-5" id="content" role="main">
17+
{{ content }}
18+
</main>

site/docs/4.1/examples/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
layout: examples
2+
layout: simple
33
title: Examples
44
description: Quickly get a project started with any of our examples ranging from using parts of the framework to custom components and layouts.
55
redirect_from: "/examples/"

site/docs/versions.html

Lines changed: 21 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -4,35 +4,25 @@
44
description: An appendix of hosted documentation for nearly every release of Bootstrap, from v1 through v4.
55
---
66

7-
<header class="d-flex flex-column flex-md-row align-items-md-center p-5 bg-light">
8-
<div class="pt-md-3 pb-md-4">
9-
<h1 class="bd-title mt-0">{{ page.title | smartify }}</h1>
10-
<p class="bd-lead">{{ page.description | smartify }}</p>
7+
<div class="row">
8+
{% for release in site.data.docs-versions %}
9+
<div class="col-md">
10+
<h2>{{ release.group }}</h2>
11+
<p>{{ release.description }}</p>
12+
{% for version in release.versions %}
13+
{% if forloop.first %}<div class="list-group">{% endif %}
14+
{% if version.v == site.docs_version %}
15+
<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 }}/">
16+
{{ version.v }}
17+
<span class="badge badge-primary">Latest</span>
18+
</a>
19+
{% else %}
20+
<a class="list-group-item list-group-item-action py-2 text-primary" href="{{ release.baseurl }}/{{ version.v }}/">
21+
{{ version.v }}
22+
</a>
23+
{% endif %}
24+
{% if forloop.last %}</div>{% endif %}
25+
{% endfor %}
1126
</div>
12-
{% include ads.html %}
13-
</header>
14-
15-
<main class="bd-content p-5">
16-
<div class="row">
17-
{% for release in site.data.docs-versions %}
18-
<div class="col-md">
19-
<h2>{{ release.group }}</h2>
20-
<p>{{ release.description }}</p>
21-
{% for version in release.versions %}
22-
{% if forloop.first %}<div class="list-group">{% endif %}
23-
{% if version.v == site.docs_version %}
24-
<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 }}/">
25-
{{ version.v }}
26-
<span class="badge badge-primary">Latest</span>
27-
</a>
28-
{% else %}
29-
<a class="list-group-item list-group-item-action py-2 text-primary" href="{{ release.baseurl }}/{{ version.v }}/">
30-
{{ version.v }}
31-
</a>
32-
{% endif %}
33-
{% if forloop.last %}</div>{% endif %}
34-
{% endfor %}
35-
</div>
36-
{% endfor %}
37-
</div>
38-
</main>
27+
{% endfor %}
28+
</div>

0 commit comments

Comments
 (0)