Skip to content

Commit d6a1c82

Browse files
committed
Adds Skeleton vedor code back into main.rs. Adds custom CSS to correct issues with misaligned buttons in the get started with rust section. Adds several new Tachyons classes to fix alignment issues between links and labels in the Grow with Rust section.
1 parent 4af66f0 commit d6a1c82

File tree

3 files changed

+26
-22
lines changed

3 files changed

+26
-22
lines changed

src/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ fn concat_vendor_css(files: Vec<&str>) {
280280
fn main() {
281281
compile_sass("app");
282282
compile_sass("fonts");
283-
concat_vendor_css(vec!["tachyons"]);
283+
concat_vendor_css(vec!["skeleton", "tachyons"]);
284284

285285
rocket::ignite()
286286
.attach(Template::fairing())

src/styles/app.scss

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -572,6 +572,10 @@ blockquote::before {
572572
width: 1px;
573573
}
574574

575+
.flex-grow {
576+
flex-grow: 1;
577+
}
578+
575579
.flex {
576580
&.vertical {
577581
flex-direction: column;

templates/learn/index.hbs

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
<section class="flex flex-column flex-row-l pv0-l">
1616
<div class="flex flex-row flex-column-l justify-between-l mw8 measure-wide-l pb4 pb5-m pb6-ns ph4-l">
1717
<div class="v-top pl4 pl0-l pt3-l measure-wide-l flex-l flex-column-l flex-auto-l">
18-
<p>Affectionately nicknamed “the book,” <cite>The Rust Programming
18+
<p class="flex-grow">Affectionately nicknamed “the book,” <cite>The Rust Programming
1919
Language</cite> will give you an overview of the language from first
2020
principles. You’ll build a few projects along the way, and by the end,
2121
you’ll have a solid grasp of the language.</p>
@@ -24,15 +24,15 @@
2424
</div>
2525
<div class="flex flex-row flex-column-l justify-between-l mw8 measure-wide-l pb4 pb5-m pb6-ns ph4-l">
2626
<div class="v-top pl4 pl0-l pt3-l measure-wide-l flex-l flex-column-l flex-auto-l">
27-
<p>Alternatively, Rustlings guides you through downloading and setting up the
27+
<p class="flex-grow">Alternatively, Rustlings guides you through downloading and setting up the
2828
Rust toolchain, and teaches you the basics of reading and writing
2929
Rust syntax, on the command line. It's an alternative to Rust by Example that works with your own environment.</p>
3030
<a class="button button-secondary" href="https://github.com/rust-lang/rustlings/">Do the Rustlings course!</a>
3131
</div>
3232
</div>
3333
<div class="flex flex-row flex-column-l justify-between-l mw8 measure-wide-l pb4 pb5-m pb6-ns ph4-l">
3434
<div class="v-top pl4 pl0-l pt3-l measure-wide-l flex-l flex-column-l flex-auto-l">
35-
<p>If reading multiple hundreds of pages about a language isn’t your
35+
<p class="flex-grow">If reading multiple hundreds of pages about a language isn’t your
3636
style, then Rust By Example has you covered. While the book talks
3737
about code with a lot of words, RBE shows off a bunch of code, and
3838
keeps the talking to a minimum. It also includes exercises!</p>
@@ -58,50 +58,50 @@
5858
you in your browser without requiring a network connection!</p>
5959

6060
<section class="flex flex-column">
61-
<div class="pt3 flex flex-column flex-row-l">
61+
<div class="pt3 flex flex-column flex-row-l items-center-l mb2-l">
6262
<a href="https://doc.rust-lang.org/std/index.html"
6363
class="button button-secondary mw6-l w-100">The standard library</a>
64-
<p class="pl4-l">
64+
<p class="pl4-l ma0-l mt1 mb3">
6565
Comprehensive guide to the Rust standard library APIs.
6666
</p>
6767
</div>
6868

69-
<div class="pt4 pt3-l flex flex-column flex-row-l">
69+
<div class="pt4 pt3-l flex flex-column flex-row-l items-center-l mb2-l">
7070
<a href="https://doc.rust-lang.org/edition-guide/index.html"
7171
class="button button-secondary mw6-l w-100">Edition Guide</a>
72-
<p class="pl4-l">
72+
<p class="pl4-l ma0-l mt1 mb3">
7373
Guide to the Rust editions.
7474
</p>
7575
</div>
7676

77-
<div class="pt4 pt3-l flex flex-column flex-row-l">
77+
<div class="pt4 pt3-l flex flex-column flex-row-l items-center-l mb2-l">
7878
<a href="https://doc.rust-lang.org/cargo/index.html"
7979
class="button button-secondary mw6-l w-100">Cargo Book</a>
80-
<p class="pl4-l">
80+
<p class="pl4-l ma0-l mt1 mb3">
8181
A book on Rust’s package manager and build system.
8282
</p>
8383
</div>
8484

85-
<div class="pt4 pt3-l flex flex-column flex-row-l">
85+
<div class="pt4 pt3-l flex flex-column flex-row-l items-center-l mb2-l">
8686
<a href="https://doc.rust-lang.org/rustdoc/index.html"
8787
class="button button-secondary mw6-l w-100">rustdoc Book</a>
88-
<p class="pl4-l">
88+
<p class="pl4-l ma0-l mt1 mb3">
8989
Learn how to make awesome documentation for your crate.
9090
</p>
9191
</div>
9292

93-
<div class="pt4 pt3-l flex flex-column flex-row-l">
93+
<div class="pt4 pt3-l flex flex-column flex-row-l items-center-l mb2-l">
9494
<a href="https://doc.rust-lang.org/rustc/index.html"
9595
class="button button-secondary mw6-l w-100">rustc Book</a>
96-
<p class="pl4-l">
96+
<p class="pl4-l ma0-l mt1 mb3">
9797
Familiarize yourself with the knobs available in the Rust compiler.
9898
</p>
9999
</div>
100100

101-
<div class="pt4 pt3-l flex flex-column flex-row-l">
101+
<div class="pt4 pt3-l flex flex-column flex-row-l items-center-l mb2-l">
102102
<a href="https://doc.rust-lang.org/error-index.html"
103103
class="button button-secondary mw6-l w-100">Compiler Error Index</a>
104-
<p class="pl4-l">
104+
<p class="pl4-l mb0 mt1 ma0-l">
105105
In-depth explanations of the errors you may see from the Rust
106106
compiler.
107107
</p>
@@ -112,32 +112,32 @@
112112
<div class="row black">
113113
<h3>Build your skills in an application domain</h3>
114114
<section class="flex flex-column">
115-
<div class="pt3 flex flex-column flex-row-l">
115+
<div class="pt3 flex flex-column flex-row-l items-center-l mb2-l">
116116
<a href="https://rust-lang-nursery.github.io/cli-wg/"
117117
class="button button-secondary mw6-l w-100">
118118
Command Line Book
119119
</a>
120-
<p class="pl4-l">
120+
<p class="pl4-l ma0-l mt1 mb3">
121121
Learn how to build effective command line applications in Rust.
122122
</p>
123123
</div>
124124

125-
<div class="pt4 pt3-l flex flex-column flex-row-l">
125+
<div class="pt4 pt3-l flex flex-column flex-row-l items-center-l mb2-l">
126126
<a href="https://rustwasm.github.io/docs/book/"
127127
class="button button-secondary mw6-l w-100">
128128
WebAssembly Book
129129
</a>
130-
<p class="pl4-l">
130+
<p class="pl4-l ma0-l mt1 mb3">
131131
Use Rust to build browser-native libraries through WebAssembly.
132132
</p>
133133
</div>
134134

135-
<div class="pt4 pt3-l flex flex-column flex-row-l">
135+
<div class="pt4 pt3-l flex flex-column flex-row-l items-center-l mb2-l">
136136
<a href="https://rust-embedded.github.io/book/"
137137
class="button button-secondary mw6-l w-100">
138138
Embedded Book
139139
</a>
140-
<p class="pl4-l">
140+
<p class="pl4-l mb0 mt1 ma0-l">
141141
Become proficient with Rust for Microcontrollers and other
142142
embedded systems.
143143
</p>

0 commit comments

Comments
 (0)