Skip to content

Commit 67d11c5

Browse files
committed
Create template for icons
Also cleaned up more typos and such.
1 parent ec04430 commit 67d11c5

9 files changed

Lines changed: 67 additions & 51 deletions

File tree

_includes/icon.html

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{% comment %}
2+
3+
This template provides icons to match bootstrap alerts.
4+
5+
Parameters:
6+
7+
type: A name that matches an alert. Valid values are "success", info", "warning" and "danger".
8+
9+
{% endcomment %}{% assign name = include.type %}{% if name == "success" %}{% assign name = "ok" %}{% endif %}{% if name == "info" %}{% assign name = "info-sign" %}{% endif %}{% if name == "warning" %}{% assign name = "alert" %}{% endif %}{% if name == "danger" %}{% assign name = "exclamation-sign" %}{% endif %}<span class="glyphicon glyphicon-{{ name }}" aria-hidden="true"></span>

_layouts/docs.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
</div>
99
{% if page.kernel_version %}
1010
<div class="alert alert-info">
11-
<span class="glyphicon glyphicon-info-sign"></span>
11+
{% include icon.html type="info" %}
1212
This docs page is for kernel version <code>{{ page.kernel_version }}</code>
1313
</div>
1414
{% endif %}

docs/getting-started.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,12 @@ First, here are the things you need before starting:
3030
them on.
3131

3232

33-
<span class="glyphicon glyphicon-alert"></span>
33+
{% include icon.html type="warning" %}
3434
The instructions on this page only apply to releases dated December
3535
2015 or later. Older releases are no longer supported. There are many major changes
3636
in the December release, so if something seems broken or the documentation seems incorrect,
37-
please [open an issue on GitHub]({{ site.github.url }}/support).
38-
{:class="alert alert-warning"}
37+
please [open an issue on GitHub]({{ site.github.url }}/support){: .alert-link}.
38+
{: .alert .alert-warning}
3939

4040
## Step 1: Download the latest ev3dev image file
4141

@@ -52,7 +52,7 @@ decompress it (such as [7-Zip] on Windows).
5252
## Step 2: Copy the image on to the SD card
5353

5454
<div class="alert alert-danger">
55-
<span class="glyphicon glyphicon-exclamation-sign"></span>
55+
{% include icon.html type="danger" %}
5656
This will erase everything on your SD card! Backup your files
5757
If you do not want to lose them!
5858
</div>
@@ -72,7 +72,7 @@ sounds the easiest to you:
7272
<br/>
7373

7474
<div class="alert alert-info">
75-
<span class="glyphicon glyphicon-info-sign"></span>
75+
{% include icon.html type="info" %}
7676
For more detailed information and more alternatives, check out
7777
<a class="alert-link" href="http://elinux.org/RPi_Easy_SD_Card_Setup">this page for RaspberryPi</a>. Much
7878
of the information there is applicable to ev3dev.
@@ -106,7 +106,7 @@ data may be lost. Keep in mind, that is may take a much longer time from 8V to
106106

107107
<div class="panel panel-info">
108108
<div class="panel-heading">
109-
<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
109+
{% include icon.html type="info" %}
110110
Troubleshooting tips if your EV3 won't boot
111111
</div>
112112
<div class="panel-body" markdown="1">
@@ -134,7 +134,7 @@ you want to use and on the OS of your host computer, so pick the one that applie
134134
after you power on Bluetooth.
135135
* [Connecting to the Internet](../tutorials/connecting-to-the-internet-via-bluetooth) tutorial
136136

137-
<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
137+
{% include icon.html type="info" %}
138138
For Raspberry Pi with no display, you must use the wired Ethernet port
139139
to connect for the first time. You can setup additional connections using the
140140
`connmanctl` command.
@@ -161,7 +161,7 @@ The default password is `ev3dev`.
161161

162162
Then just follow the instructions on the screen.
163163

164-
<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
164+
{% include icon.html type="info" %}
165165
The EV3 and Raspberry Pi do not have a battery backup for the realtime clock.
166166
Whenever you remove the batteries, the clock will be reset. If the EV3 is
167167
connected to the Internet, the clock will be automatically set via NTP,

docs/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
<div class="panel panel-info">
77
<div class="panel-heading">
8-
<span class="glyphicon glyphicon-info-sign"></span>
8+
{% include icon.html type="info" %}
99
ev3dev is a community-maintained project that relies on people's contributions.
1010
</div>
1111
<div class="panel-body">

docs/tutorials/connecting-to-the-internet-via-bluetooth.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@ title: Connecting to the Internet via Bluetooth
33
subject: Networking
44
---
55

6-
<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
6+
{% include icon.html type="info" %}
77
If you do not need to access the Internet from the EV3 brick, consider
8-
using [tethering] instead.
8+
using [tethering]{: .alert-link} instead.
99
{: .alert .alert-info}
1010

1111
[tethering]: /docs/tutorials/using-bluetooth-tethering
1212

13-
<span class="glyphicon glyphicon-warning-sign" aria-hidden="true"></span>
14-
These instructions are for [brickman v0.7.0](http://www.ev3dev.org/news/2015/12/15/Package-Release/).
13+
{% include icon.html type="warning" %}
14+
These instructions are for [brickman v0.7.0](http://www.ev3dev.org/news/2015/12/15/Package-Release/){: .alert-link}.
1515
If you are using an older version, please upgrade.
1616
{: .alert .alert-warning}
1717

docs/tutorials/connecting-to-the-internet-via-usb.md

Lines changed: 36 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -3,26 +3,26 @@ title: Connecting to the Internet via USB
33
subject: Networking
44
---
55

6-
<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
6+
{% include icon.html type="info" %}
77
If you do not need to access the Internet from the EV3 brick, consider
8-
using [tethering] instead.
8+
using [tethering]{: .alert-link} instead.
99
{: class="alert alert-info"}
1010

1111
[tethering]: /docs/tutorials/using-usb-tethering
1212

13-
<span class="glyphicon glyphicon-warning-sign" aria-hidden="true"></span>
14-
These instructions are for [brickman v0.7.0](http://www.ev3dev.org/news/2015/12/15/Package-Release/).
13+
{% include icon.html type="warning" %}
14+
These instructions are for [brickman v0.7.0](http://www.ev3dev.org/news/2015/12/15/Package-Release/){: .alert-link}.
1515
If you are using an older version, please upgrade.
1616
{: .alert .alert-warning}
1717

18-
* {: tab="Mac OSX"}<span class="glyphicon glyphicon-warning-sign" aria-hidden="true"></span>
18+
* {: tab="Mac OSX"}{% include icon.html type="warning" %}
1919
If you are using OS X version 10.11, this won't work. Apple broke the USB/CDC
2020
gadget driver and has not fixed it yet (as of version 10.11.2). Please
21-
[file a bug with Apple](https://bugreport.apple.com/) and politely ask them
21+
[file a bug with Apple](https://bugreport.apple.com/){: .alert-link} and politely ask them
2222
to fix it.
2323
{: class="alert alert-warning"}
2424

25-
<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
25+
{% include icon.html type="info" %}
2626
These instructions were written using OS X version 10.9, but should work for
2727
other versions as well.
2828
{: class="alert alert-info"}
@@ -80,15 +80,20 @@ If you are using an older version, please upgrade.
8080

8181
ssh robot@ev3dev.local
8282

83-
<div class="alert alert-info" markdown="1">
84-
<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
85-
If you have never connected before, you will prompted to confirm the
83+
<div class="panel panel-info">
84+
<div class="panel-heading">
85+
{% include icon.html type="info" %}
86+
If you have never connected before, you will be prompted to confirm the
8687
authenticity of the host, so type `yes` when prompted.
87-
88+
</div>
89+
<div class="panel-body">
90+
<pre>
8891
The authenticity of host 'ev3dev.local (192.168.2.3)' can't be established.
8992
RSA key fingerprint is xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx.
9093
Are you sure you want to continue connecting (yes/no)? yes
9194
Warning: Permanently added 'ev3dev.local' (RSA) to the list of known hosts.
95+
</pre>
96+
</div>
9297
</div>
9398

9499
10. Enter your password when prompted. The default password is `ev3dev`.
@@ -110,9 +115,9 @@ If you are using an older version, please upgrade.
110115
permitted by applicable law.
111116
robot@ev3dev:~$
112117

113-
* {: tab="Ubuntu"}<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
114-
This instructions were written using Ubuntu 15.10 using the default desktop
115-
(aka Unity) however, they should be similar for other versions of Ubuntu
118+
* {: tab="Ubuntu"}{% include icon.html type="info" %}
119+
These instructions were written using Ubuntu 15.10 and the default desktop
120+
(aka Unity). However, the instructions should work for other versions of Ubuntu
116121
and its derivatives as well as other desktops like GNOME Shell, Cinnamon
117122
and MATE.
118123
{:class="alert alert-info"}
@@ -171,19 +176,24 @@ If you are using an older version, please upgrade.
171176

172177
ssh robot@ev3dev.local
173178

174-
<div class="alert alert-info" markdown="1">
175-
<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
176-
If you have never connected before, you will prompted to confirm the
179+
<div class="panel panel-info">
180+
<div class="panel-heading">
181+
{% include icon.html type="info" %}
182+
If you have never connected before, you will be prompted to confirm the
177183
authenticity of the host, so type `yes` when prompted.
178-
184+
</div>
185+
<div class="panel-body">
186+
<pre>
179187
The authenticity of host 'ev3dev.local (10.42.0.228)' can't be established.
180188
ECDSA key fingerprint is SHA256:LjEw+uEG5x7kl9LwVeynjeybuBHT3VQB5simpcVqmu8.
181189
Are you sure you want to continue connecting (yes/no)? yes
182190
Warning: Permanently added 'ev3dev.local,10.42.0.228' (ECDSA) to the list of known hosts.
183191
Warning: Permanently added '10.42.0.228' (ECDSA) to the list of known hosts.
192+
</pre>
193+
</div>
184194
</div>
185195

186-
11. Enter you password when prompted. The default password is `ev3dev`.
196+
11. Enter your password when prompted. The default password is `ev3dev`.
187197

188198
robot@ev3dev.local's password:
189199
_____ _
@@ -203,8 +213,8 @@ If you are using an older version, please upgrade.
203213
robot@ev3dev:~$
204214

205215

206-
* {: tab="Windows"}<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
207-
These instructions were written using Window 10, but should work Windows
216+
* {: tab="Windows"}{% include icon.html type="info" %}
217+
These instructions were written using Windows 10, but should work on Windows
208218
7 and 8 as well.
209219
{:class="alert alert-info"}
210220

@@ -224,9 +234,9 @@ If you are using an older version, please upgrade.
224234

225235
{% include screenshot.html source="/images/windows/10/devices-and-printers-rndis.png" %}
226236

227-
<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
237+
{% include icon.html type="info" %}
228238
PROTIP: You can get an icon that looks like an actual EV3 by installing
229-
[Programmable Brick Icons](https://github.com/ev3dev/PBrickIcons).
239+
[Programmable Brick Icons](https://github.com/ev3dev/PBrickIcons){: .alert-link}.
230240
Follow the link for more information.
231241
{% include screenshot.html source="https://raw.githubusercontent.com/ev3dev/PBrickIcons/master/demo1.png" %}
232242
{:class="alert alert-info"}
@@ -264,15 +274,15 @@ If you are using an older version, please upgrade.
264274

265275
{% include screenshot.html source="/images/windows/10/local-area-connection-properties-sharing.png" %}
266276

267-
<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
277+
{% include icon.html type="info" %}
268278
If you have more than two network connections, it will ask for a "Home
269279
networking connection". If you see this, select your EV3's network adapter
270280
from the list (this will be called *EV3* if you renamed it earlier in the
271281
guide).
272282
{% include screenshot.html source="/images/windows/8/local-area-connection-properties-sharing-with-extra-selection.png" %}
273283
{: class="alert alert-info"}
274284

275-
<span class="glyphicon glyphicon-warning-sign" aria-hidden="true"></span>
285+
{% include icon.html type="warning" %}
276286
Windows Internet Connection Sharing is temperamental. Sometimes it just
277287
stops working for no reason. If this happens, just turn it off (by unchecking
278288
*Allow other...* and clicking *OK*) and then turn it back on. It should
@@ -314,7 +324,7 @@ If you are using an older version, please upgrade.
314324

315325
{% include screenshot.html source="/images/windows/10/putty-configuration-ev3dev.png" %}
316326

317-
<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span>
327+
{% include icon.html type="info" %}
318328
The first time you connect, you'll get a warning about the new fingerprint.
319329
This is normal. Just click *Yes* to continue. You won't see this again
320330
unless you re-flash your SD card.

docs/tutorials/using-xv11-lidar.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,13 @@ XV11 LIDAR communicates using UART, 8N1 at 3.3V with baud rate 115200.
99

1010
EV3 has all the required hardware to communicate with the LIDAR and ev3dev has the software.
1111

12-
<div class="alert alert-warning">
13-
<span class="glyphicon glyphicon-alert"></span>
14-
The instructions on this page apply to EV3.
15-
You can also get it working with Raspberry PI and BrickPI but BrickPI doesn't support other-uart mode for sensor port and dedicated Raspberry Pi UART GPIO pins are already taken by BrickPI.
16-
You have to figure out some other way to get the UART. USB to UART bridge could be one option.
17-
</div>
12+
13+
{% include icon.html type="warning" %}
14+
The instructions on this page apply to EV3.
15+
You can also get it working with Raspberry PI and BrickPI but BrickPI doesn't support
16+
other-uart mode for sensor port and dedicated Raspberry Pi UART GPIO pins are already taken by BrickPI.
17+
You have to figure out some other way to get the UART. USB to UART bridge could be one option.
18+
{: .alert .alert-warning}
1819

1920
To interface the LIDAR one has to:
2021

projects/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
</p>
1010

1111
<div class="alert alert-info">
12-
<span class="glyphicon glyphicon-info-sign"></span>
12+
{% include icon.html type="info" %}
1313
Would you like your project added to the list? We would!
1414
<a class="alert-link" href="{{ site.github.url }}/docs/tutorials/adding-new-project/">Create a page and send us a pull request</a>.
1515
</div>

stylesheets/bootstrap-extensions.css

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,3 @@ dd ol, dd ul {
169169
ul + p, ol + p {
170170
margin-top: 10.5px;
171171
}
172-
173-
.alert > pre {
174-
margin-top: 10.5px;
175-
}

0 commit comments

Comments
 (0)