Skip to content

Commit 249be61

Browse files
committed
Improve menu spacing, Remove Google font loading
1 parent fe5b5cb commit 249be61

5 files changed

Lines changed: 1354 additions & 26 deletions

File tree

_includes/google-fonts.html

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,3 @@
1-
<script async type="text/javascript">
2-
WebFontConfig = {
3-
google: { families: [ 'Source+Sans+Pro:400,700,400italic,700italic:latin', 'Source+Code+Pro::latin' ] }
4-
};
5-
(function() {
6-
var wf = document.createElement('script');
7-
wf.src = ('https:' == document.location.protocol ? 'https' : 'http') +
8-
'://ajax.googleapis.com/ajax/libs/webfont/1/webfont.js';
9-
wf.type = 'text/javascript';
10-
wf.async = 'true';
11-
var s = document.getElementsByTagName('script')[0];
12-
s.parentNode.insertBefore(wf, s);
13-
})();
14-
</script>
15-
161
<script async type="text/javascript">
172
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
183
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),

_includes/menu.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@
3434
</a>
3535
</header>
3636
<nav class="menu-collections">
37-
<p><strong>Collections</strong></p>
3837
<ul>
38+
<li><a class="menu-collection-link{% if page.template == 'index' %} menu-collection-link--active{% endif %}" href="{{site.url}}/">All</a></li>
3939
<li><a class="menu-collection-link{% if page.collection_name == 'Animations' %} menu-collection-link--active{% endif %}" href="{{site.url}}/animations/">Animations</a></li>
4040
<li><a class="menu-collection-link{% if page.collection_name == 'Box model' %} menu-collection-link--active{% endif %}" href="{{site.url}}/box-model/">Box model</a></li>
4141
<li><a class="menu-collection-link{% if page.collection_name == 'Flexbox' %} menu-collection-link--active{% endif %}" href="{{site.url}}/flexbox/">Flexbox</a></li>

css/website.css

Lines changed: 1343 additions & 1 deletion
Large diffs are not rendered by default.

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
# this is an empty front matter
2+
template: index
33
---
44

55
<!DOCTYPE html>

sass/menu.sass

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
position: relative
44

55
.menu-header
6-
padding: 1.5rem
6+
padding: 1.5rem 1.5rem 0
77

88
.menu-logo
99
align-items: center
@@ -29,15 +29,16 @@
2929
width: 160px
3030

3131
.menu-collections
32-
border-top: 1px solid $border
3332
padding: 1rem
34-
li
35-
display: inline-block
36-
vertical-align: top
33+
ul
34+
align-items: flex-start
35+
display: flex
36+
flex-wrap: wrap
3737

3838
.menu-collection-link
3939
border-radius: 2px
40-
padding: 2px 4px
40+
display: block
41+
padding: 0 6px
4142
&:hover
4243
background: $alpha
4344
color: $alpha-invert
@@ -201,6 +202,7 @@
201202

202203
+mobile
203204
.menu-collections
205+
justify-content: center
204206
text-align: center
205207
li
206208
margin: 0.25rem
@@ -239,8 +241,7 @@
239241
flex-shrink: 0
240242
.menu-collections
241243
font-size: 0.8rem
242-
li
243-
margin-left: -2px
244+
padding-left: 1.5rem
244245
.menu-nav
245246
border-top: 1px solid $border
246247
display: flex

0 commit comments

Comments
 (0)