Skip to content

Commit 4091299

Browse files
committed
Build css
1 parent 28bf9b8 commit 4091299

11 files changed

Lines changed: 131 additions & 100 deletions

File tree

_includes/menu.html

Lines changed: 33 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -32,29 +32,6 @@
3232
<img class="menu-logo-type" src="{{site.url}}/images/css-reference-type.png" alt="CSS Reference type">
3333
</figure>
3434
</a>
35-
<p class="menu-title">
36-
{{site.description}}<br>
37-
<small>Created by <a href="https://twitter.com/jgthms">@jgthms</a></small>
38-
</p>
39-
<p class="menu-share">
40-
<strong class="menu-share-label">Share</strong>
41-
<a class="menu-share-button is-twitter"
42-
data-social-network="Twitter"
43-
data-social-action="tweet"
44-
data-social-target="{{site.url}}{{page.url}}"
45-
href="https://twitter.com/intent/tweet?url={{site.url | url_encode}}&text={{site.share | url_encode}}"
46-
rel="external nofollow"
47-
target="_blank">
48-
{% include svg/twitter.html %}
49-
</a>
50-
<a class="menu-share-button is-facebook"
51-
href="http://www.facebook.com/sharer.php?u={{site.url | url_encode}}"
52-
rel="external nofollow"
53-
target="_blank">
54-
{% include svg/facebook.html %}
55-
</a>
56-
<a id="menu-nav-open" class="menu-share-nav">Menu</a>
57-
</p>
5835
</header>
5936
<nav id="menu-nav" class="menu-nav">
6037
<div class="menu-search">
@@ -73,7 +50,7 @@
7350
<strong>Close</strong>
7451
</a>
7552
</nav>
76-
<footer id="menuHello" class="menu-hello">
53+
<!-- <footer id="menuHello" class="menu-hello">
7754
<div id="huggingFace">
7855
<p>
7956
CSS Reference is <strong>free</strong> and <br>
@@ -90,5 +67,36 @@
9067
<div id="carbon">
9168
<script async type="text/javascript" src="//cdn.carbonads.com/carbon.js?zoneid=1673&serve=C6AILKT&placement=cssreferenceio" id="_carbonads_js" onload ="window.helloCarbon()"></script>
9269
</div>
93-
</footer>
70+
</footer> -->
9471
</aside>
72+
73+
<footer class="footer">
74+
<p class="footer-title">
75+
<strong>{{site.description}}</strong> <small>Created by <a href="https://twitter.com/jgthms">@jgthms</a></small>
76+
</p>
77+
<p class="footer-share footer-share--contribute">
78+
<strong class="footer-share-label">Contribute</strong>
79+
<a class="footer-share-button is-github" href="https://github.com/jgthms/css-reference" target="_blank">
80+
{% include svg/github.html %}
81+
</a>
82+
</p>
83+
<p class="footer-share footer-share--social">
84+
<strong class="footer-share-label">Share</strong>
85+
<a class="footer-share-button is-twitter"
86+
data-social-network="Twitter"
87+
data-social-action="tweet"
88+
data-social-target="{{site.url}}{{page.url}}"
89+
href="https://twitter.com/intent/tweet?url={{site.url | url_encode}}&text={{site.share | url_encode}}"
90+
rel="external nofollow"
91+
target="_blank">
92+
{% include svg/twitter.html %}
93+
</a>
94+
<a class="footer-share-button is-facebook"
95+
href="http://www.facebook.com/sharer.php?u={{site.url | url_encode}}"
96+
rel="external nofollow"
97+
target="_blank">
98+
{% include svg/facebook.html %}
99+
</a>
100+
<a id="menu-nav-open" class="footer-share-nav">Menu</a>
101+
</p>
102+
</footer>

_includes/svg/facebook.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
1+
<svg class="svg svg--facebook" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
22
width="266.893px" height="266.895px" viewBox="0 0 266.893 266.895" enable-background="new 0 0 266.893 266.895"
33
xml:space="preserve">
44
<path fill="#3C5A99" d="M248.082,262.307c7.854,0,14.223-6.369,14.223-14.225V18.812

_includes/svg/github.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<svg class="svg svg--github" width="33" height="32" viewBox="0 0 33 32" xmlns="http://www.w3.org/2000/svg"><path d="M16.2885009,0 C7.2942243,0 0,7.293 0,16.29 C0,23.487 4.66714351,29.592 11.1403426,31.746 C11.9553676,31.896 12.2523768,31.393 12.2523768,30.961 C12.2523768,30.575 12.2383763,29.55 12.2303761,28.191 C7.69923675,29.175 6.74320735,26.007 6.74320735,26.007 C6.00218457,24.125 4.93415172,23.624 4.93415172,23.624 C3.45510624,22.614 5.04615517,22.634 5.04615517,22.634 C6.68120545,22.749 7.54123189,24.313 7.54123189,24.313 C8.99427657,26.802 11.3543491,26.083 12.2823777,25.666 C12.4303822,24.614 12.8513952,23.896 13.3164095,23.489 C9.69929825,23.078 5.89618131,21.68 5.89618131,15.438 C5.89618131,13.66 6.53120083,12.205 7.57323288,11.067 C7.40522771,10.655 6.84621052,8.998 7.7332378,6.756 C7.7332378,6.756 9.10027983,6.318 12.2123755,8.426 C13.5114155,8.064 14.9054583,7.884 16.2905009,7.877 C17.6745435,7.884 19.0675863,8.064 20.3686263,8.426 C23.478722,6.318 24.8437639,6.756 24.8437639,6.756 C25.7327913,8.998 25.1737741,10.655 25.006769,11.067 C26.0508011,12.205 26.6808204,13.66 26.6808204,15.438 C26.6808204,21.696 22.8717033,23.073 19.2435917,23.476 C19.8276097,23.979 20.3486257,24.973 20.3486257,26.493 C20.3486257,28.67 20.3286251,30.427 20.3286251,30.961 C20.3286251,31.397 20.6226341,31.904 21.4486595,31.745 C27.9168584,29.586 32.5800018,23.485 32.5800018,16.29 C32.5800018,7.293 25.2857775,0 16.2885009,0" id="Fill-3"></path></svg>

_includes/svg/twitter.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<svg xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 300.00006 244.18703" height="244.19" width="300" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/">
1+
<svg class="svg svg--twitter" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 300.00006 244.18703" height="244.19" width="300" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/">
22
<g transform="translate(-539.18 -568.86)">
33
<path d="m633.9 812.04c112.46 0 173.96-93.168 173.96-173.96 0-2.6463-0.0539-5.2806-0.1726-7.903 11.938-8.6302 22.314-19.4 30.498-31.66-10.955 4.8694-22.744 8.1474-35.111 9.6255 12.623-7.5693 22.314-19.543 26.886-33.817-11.813 7.0031-24.895 12.093-38.824 14.841-11.157-11.884-27.041-19.317-44.629-19.317-33.764 0-61.144 27.381-61.144 61.132 0 4.7978 0.5364 9.4646 1.5854 13.941-50.815-2.5569-95.874-26.886-126.03-63.88-5.2508 9.0354-8.2785 19.531-8.2785 30.73 0 21.212 10.794 39.938 27.208 50.893-10.031-0.30992-19.454-3.0635-27.69-7.6468-0.009 0.25652-0.009 0.50661-0.009 0.78077 0 29.61 21.075 54.332 49.051 59.934-5.1376 1.4006-10.543 2.1516-16.122 2.1516-3.9336 0-7.766-0.38716-11.491-1.1026 7.7838 24.293 30.355 41.971 57.115 42.465-20.926 16.402-47.287 26.171-75.937 26.171-4.929 0-9.7983-0.28036-14.584-0.84634 27.059 17.344 59.189 27.464 93.722 27.464" fill="#1da1f2"/>
44
</g>

css/website.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

css/website.sass

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
@import "../sass/controls"
1111
@import "../sass/menu"
1212
@import "../sass/header"
13+
@import "../sass/footer"
1314
@import "../sass/property"
1415
@import "../sass/example"
1516
@import "../sass/modal"
@@ -18,9 +19,12 @@
1819
@import "../sass/elements"
1920

2021
.modal
21-
z-index: 40
22+
z-index: 50
2223

2324
.menu
25+
z-index: 40
26+
27+
.footer
2428
z-index: 30
2529

2630
.list

index.html

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,7 @@ <h2 class="header-title">
4141
A free visual guide to CSS
4242
</h2>
4343
<p class="header-subtitle">
44-
<strong>Learn by example</strong>: <a href="{{site.url}}">cssreference.io</a> is a free visual guide to CSS. It features the most popular properties, and explains them with illustrated and animated examples.<br><br>
45-
<a href="https://github.com/jgthms/css-reference">Contribute on GitHub</a>
44+
<strong>Learn by example</strong>: <a href="{{site.url}}">cssreference.io</a> is a free visual guide to CSS. It features the most popular properties, and explains them with illustrated and animated examples.
4645
</p>
4746
</div>
4847
</header>

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"build-autoprefix": "postcss --use autoprefixer --output css/website.css css/website.css",
99
"build-clean": "rm css/website.css",
1010
"build-sass": "node-sass --output-style compressed css/website.sass css/website.css",
11-
"develop": "node-sass --output-style expanded css/website.sass css/website.css",
11+
"develop": "node-sass css/website.sass css/website.css",
1212
"start": "npm run develop -- --watch"
1313
},
1414
"keywords": [

sass/footer.sass

Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
.footer
2+
background: #fff
3+
bottom: 0
4+
box-shadow: 0 0 1rem rgba(#000, 0.2)
5+
left: 0
6+
position: fixed
7+
right: 0
8+
9+
.footer-title
10+
align-items: center
11+
color: $text-light
12+
display: none
13+
padding: 0 1rem
14+
small
15+
font-size: 0.8em
16+
margin-left: 0.5em
17+
a:hover
18+
background: $alpha
19+
color: $alpha-invert
20+
21+
.footer-share
22+
align-items: center
23+
display: flex
24+
position: relative
25+
26+
.footer-share--contribute
27+
display: none
28+
29+
.footer-share-label
30+
margin-right: 0.25rem
31+
32+
.footer-share-button
33+
align-items: center
34+
display: flex
35+
height: 2rem
36+
justify-content: center
37+
position: relative
38+
width: 2rem
39+
&:before
40+
+overlay
41+
background: $background
42+
border-radius: 5px
43+
content: ""
44+
display: block
45+
height: 100%
46+
opacity: 0
47+
transform: scale(1.2)
48+
transform-origin: center center
49+
transition-duration: $speed
50+
transition-property: opacity, transform
51+
width: 100%
52+
svg
53+
height: 1rem
54+
position: relative
55+
width: 1rem
56+
&:hover:before
57+
opacity: 1
58+
transform: scale(1)
59+
60+
.footer-share-nav
61+
font-weight: $weight-bold
62+
position: absolute
63+
right: 1rem
64+
top: 1rem
65+
66+
+mobile
67+
.footer-share--social
68+
padding: 0.5rem 1rem
69+
70+
+desktop
71+
.footer
72+
align-items: stretch
73+
display: flex
74+
font-size: 0.8rem
75+
left: $menu-width
76+
padding: 0.25rem
77+
.footer-title
78+
display: flex
79+
flex-grow: 1
80+
flex-shrink: 1
81+
.footer-share--contribute
82+
display: flex
83+
margin-right: 0.25rem
84+
.footer-share-nav
85+
display: none

sass/header.sass

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,5 +73,5 @@ $width: 486px
7373
.header
7474
justify-content: center
7575
min-height: 400px
76-
padding: 3rem
76+
padding: 4rem
7777
text-align: center

0 commit comments

Comments
 (0)