Skip to content

Commit 1f4486c

Browse files
committed
Reduce liquid's whitespace for a few pages.
Also fix a couple of typos while at it and change header tags' order.
1 parent ac718c9 commit 1f4486c

6 files changed

+32
-32
lines changed
+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{% callout danger %}
22
#### Asynchronous methods and transitions
33

4-
All API methods are **asynchronous** and start a **transition**. They returns to the caller as soon as the transition is started but **before it ends**. In addition, a method call on a **transitioning component will be ignored**.
4+
All API methods are **asynchronous** and start a **transition**. They return to the caller as soon as the transition is started but **before it ends**. In addition, a method call on a **transitioning component will be ignored**.
55

66
[See our JavaScript documentation for more information.]({{ site.baseurl }}/docs/{{ site.docs_version }}/getting-started/javascript/)
77
{% endcallout %}

_includes/callout-warning-color-assistive-technologies.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
#### Conveying meaning to assistive technologies
33

44
Using color to add meaning only provides a visual indication, which will not be conveyed to users of assistive technologies – such as screen readers. Ensure that information denoted by the color is either obvious from the content itself (e.g. the visible text), or is included through alternative means, such as additional text hidden with the `.sr-only` class.
5-
{% endcallout %}
5+
{% endcallout %}

_includes/docs-sidebar.html

+20-20
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,37 @@
11
<form class="bd-search d-flex align-items-center">
22
<input type="search" class="form-control" id="search-input" placeholder="Search..." aria-label="Search for..." autocomplete="off">
3-
<button class="btn-link bd-search-docs-toggle d-md-none p-0 ml-3" type="button" data-toggle="collapse" data-target="#bd-docs-nav" aria-controls="bd-docs-nav" aria-expanded="false" aria-label="Toggle docs avigation">
3+
<button class="btn-link bd-search-docs-toggle d-md-none p-0 ml-3" type="button" data-toggle="collapse" data-target="#bd-docs-nav" aria-controls="bd-docs-nav" aria-expanded="false" aria-label="Toggle docs navigation">
44
{% include icons/menu.svg class="" width="30" height="30" %}
55
</button>
66
</form>
77

88
<nav class="collapse bd-links" id="bd-docs-nav">
9-
{% assign page_slug = page.url | split: '/' | last %}
10-
{% for group in site.data.nav %}
11-
{% assign link = group.pages | first %}
12-
{% assign link_slug = link.title | slugify %}
13-
{% assign group_slug = group.title | slugify %}
14-
{% assign active = nil %}
9+
{%- assign page_slug = page.url | split: '/' | last -%}
10+
{%- for group in site.data.nav -%}
11+
{%- assign link = group.pages | first -%}
12+
{%- assign link_slug = link.title | slugify -%}
13+
{%- assign group_slug = group.title | slugify -%}
14+
{%- assign active = nil -%}
1515

16-
{% if page.group == group_slug %}
17-
{% assign active = 'active' %}
18-
{% endif %}
16+
{%- if page.group == group_slug -%}
17+
{%- assign active = 'active' -%}
18+
{%- endif -%}
1919

20-
<div class="bd-toc-item {{ active }}">
20+
<div class="bd-toc-item{% unless active == nil %} {{ active }}{% endunless %}">
2121
<a class="bd-toc-link" href="{{ site.baseurl }}/docs/{{ site.docs_version }}/{{ group_slug }}/{{ link_slug }}{% if link_slug %}/{% endif %}">
2222
{{ group.title }}
2323
</a>
2424

2525
<ul class="nav bd-sidenav">
26-
{% for doc in group.pages %}
27-
{% assign doc_slug = doc.title | slugify %}
28-
{% assign active = nil %}
26+
{%- for doc in group.pages -%}
27+
{%- assign doc_slug = doc.title | slugify -%}
28+
{%- assign active = nil -%}
2929

30-
{% if page.group == group_slug and page_slug == doc_slug %}
31-
{% assign active = 'active bd-sidenav-active' %}
32-
{% endif %}
30+
{%- if page.group == group_slug and page_slug == doc_slug -%}
31+
{%- assign active = 'active bd-sidenav-active' -%}
32+
{%- endif -%}
3333

34-
<li class="{{ active }}">
34+
<li{% unless active == nil %} class="{{ active }}"{% endunless %}>
3535
<a href="{{ site.baseurl }}/docs/{{ site.docs_version }}/{{ group_slug }}/{{ doc_slug }}/">
3636
{{ doc.title }}
3737
</a>
@@ -50,8 +50,8 @@
5050
{% endunless %}
5151
{% endcomment %}
5252
</li>
53-
{% endfor %}
53+
{%- endfor -%}
5454
</ul>
5555
</div>
56-
{% endfor %}
56+
{%- endfor -%}
5757
</nav>

_includes/header.html

+5-5
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,13 @@
33
<meta name="generator" content="Jekyll v{{ jekyll.version }}">
44

55
<title>
6-
{% if page.title %}
6+
{%- if page.title -%}
77
{{ page.title }} &middot; {{ site.title }}
8-
{% else %}
8+
{%- else -%}
99
{{ site.title }} &middot; {{ site.description }}
10-
{% endif %}
10+
{%- endif -%}
1111
</title>
1212

13-
{% include social.html %}
14-
1513
<!-- Bootstrap core CSS -->
1614
{% if site.github %}
1715
<link href="{{ site.baseurl }}/dist/css/bootstrap.min.css" rel="stylesheet">
@@ -25,6 +23,8 @@
2523
{% endif %}
2624
<link href="{{ site.baseurl }}/assets/css/docs.min.css" rel="stylesheet">
2725

26+
{% include social.html %}
27+
2828
<script>
2929
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
3030
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),

_includes/scripts.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -51,5 +51,5 @@
5151
fg: 'rgba(255,255,255,.75)',
5252
font: 'Helvetica',
5353
fontweight: 'normal'
54-
})
54+
});
5555
</script>

_includes/social.html

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
<!-- Meta -->
2+
<meta name="description" content="{{ site.description }}">
3+
<meta name="author" content="{{ site.authors }}">
4+
15
<!-- Twitter -->
26
<meta name="twitter:site" content="@{{ site.twitter }}">
37
<meta name="twitter:creator" content="@{{ site.twitter }}">
@@ -30,7 +34,3 @@
3034
<meta property="og:image:type" content="image/png">
3135
<meta property="og:image:width" content="1200">
3236
<meta property="og:image:height" content="630">
33-
34-
<!-- Meta -->
35-
<meta name="description" content="{{ site.description }}">
36-
<meta name="author" content="{{ site.authors }}">

0 commit comments

Comments
 (0)