Add carbon

This commit is contained in:
Rico Sta. Cruz 2016-08-13 10:11:32 +08:00
parent cf9d5f8737
commit 8986e7d2f6
No known key found for this signature in database
GPG Key ID: CAAD38AE2962619A
23 changed files with 135 additions and 2 deletions

View File

@ -1,5 +1,5 @@
{% assign description = "The ultimate cheatsheet for " | append: include.page.title | append: "." %}
<ul class="social-list">
<ul class="social-list {{ include.class }}">
<li class="facebook hint--bottom" data-hint="Share on Facebook"><a href="https://www.facebook.com/sharer/sharer.php?u={{ site.url }}{{ include.page.url }}" target="share"><span class="text">Like</span></a></li>
<li class="twitter hint--bottom" data-hint="Share on Twitter"><a href="https://twitter.com/intent/tweet?text={{ description }} {{ site.url }}{{ include.page.url }}" target="share"><span class="text">Tweet</span></a></li>
<li class="googleplus hint--bottom" data-hint="Share on Google Plus"><a href="https://plus.google.com/share?url={{ site.url }}{{ include.page.url }}" target="share"><span class="text">+1</span></a></li>

28
_layouts/default-ad.html Normal file
View File

@ -0,0 +1,28 @@
---
type: article
---
{% include head.html %}
{% include site-header.html %}
<div class='post-list -single -cheatsheet'>
<div class='post-item'>
{% include social-list.html page=page class="-collapse" %}
<div class='post-headline -cheatsheet'>
<p class='prelude'><span></span></p>
<h1><span>{{ page.title }}</span></h1>
</div>
<div class='headline-ad'>
<script async src='//cdn.carbonads.com/carbon.js?zoneid=1673&serve=C6AILKT&placement=ricostacruzcom' id="_carbonads_js"></script>
</div>
<div class='post-content -cheatsheet'>
{{ content }}
</div>
{% include social-list.html page=page %}
</div>
</div>
{% include foot.html %}

View File

@ -20,4 +20,8 @@ html_class: home
</div>
{% endfor %}
<div class='side-ad'>
<script async src='//cdn.carbonads.com/carbon.js?zoneid=1673&serve=C6AILKT&placement=ricostacruzcom' id="_carbonads_js"></script>
</div>
{% include foot.html %}

View File

@ -61,7 +61,7 @@
}
.post-headline.-cheatsheet .prelude span:before {
content: 'The great cheatsheet for';
content: 'Cheatsheet for';
}
@media (min-width: 769px) {
@ -191,3 +191,85 @@
box-shadow: none;
margin: 0;
}
/*
* Carbon: side
*/
.side-ad {
position: absolute;
top: 80px;
right: 20px;
width: 130px;
display: block;
font-size: .8em;
}
.side-ad a {
text-decoration: none;
box-shadow: none;
}
.side-ad .carbon-text {
margin-top: 5px;
display: block;
}
.side-ad .carbon-poweredby {
display: block;
color: #aaa;
}
/*
* Cardbon: headline
*/
.headline-ad {
width: 300px;
min-height: 100px;
font-size: .8em;
margin: 0 auto 45px auto;
line-height: 1.5;
}
.headline-ad:after {
content: '';
display: table;
clear: both;
zoom: 1;
}
.headline-ad a {
text-decoration: none;
box-shadow: none;
}
.headline-ad img {
float: left;
margin-right: 15px;
background: #fafafa;
}
.headline-ad .carbon-text {
}
.headline-ad .carbon-poweredby {
display: block;
color: #aaa;
margin-top: 5px;
}
.social-list.-collapse {
margin-top: 0;
position: absolute;
top: 40vh;
left: 30px;
width: 32px;
}
@media (max-width: 480px) {
.social-list.-collapse {
display: none;
}
}

View File

@ -1,6 +1,7 @@
---
title: Awesome-redux
category: JavaScript libraries
layout: default-ad
---
### [redux-actions](https://www.npmjs.com/package/redux-actions)

View File

@ -1,6 +1,7 @@
---
title: bluebird.js
category: JavaScript libraries
layout: default-ad
---
Also see the [promise cheatsheet](promise.html) and [Bluebird.js API](https://github.com/petkaantonov/bluebird/blob/master/API.md) (github.com).

View File

@ -1,6 +1,7 @@
---
title: Chai.js
category: JavaScript libraries
layout: default-ad
---
### Assert

View File

@ -1,6 +1,7 @@
---
title: CSS antialiasing
category: CSS
layout: default-ad
---
* {

View File

@ -1,6 +1,7 @@
---
title: Docker CLI
category: Devops
layout: default-ad
---
Manage images

1
es6.md
View File

@ -1,6 +1,7 @@
---
title: ES2015
category: JavaScript
layout: default-ad
---
## Stable in io.js

View File

@ -1,6 +1,7 @@
---
title: FactoryGirl
category: Ruby libraries
layout: default-ad
---
### Paths

View File

@ -1,5 +1,6 @@
---
title: Homebrew
layout: default-ad
---
### Commands

View File

@ -1,6 +1,7 @@
---
title: httpie
category: CLI
layout: default-ad
---
$ http POST example.com/posts/3 \

View File

@ -1,6 +1,7 @@
---
title: Immutable.js
category: JavaScript libraries
layout: default-ad
---
```js

View File

@ -1,6 +1,7 @@
---
title: Jasmine
category: JavaScript libraries
layout: default-ad
---
describe("A suite", function() {

View File

@ -1,5 +1,6 @@
---
title: Parsley.js
layout: default-ad
---
### Enabling

View File

@ -1,6 +1,7 @@
---
title: React-router
category: React
layout: default-ad
---
### Basic

View File

@ -1,6 +1,7 @@
---
title: React.js
category: React
layout: default-ad
---
{%raw%}

View File

@ -1,6 +1,7 @@
---
title: Riot.js
category: JavaScript libraries
layout: default-ad
---
## Tags

View File

@ -1,6 +1,7 @@
---
title: Sinon-chai
category: JavaScript libraries
layout: default-ad
---
* [Sinon-chai](https://github.com/domenic/sinon-chai)

View File

@ -1,6 +1,7 @@
---
title: Sinon
category: JavaScript libraries
layout: default-ad
---
### Creating spies

View File

@ -2,6 +2,7 @@
title: Vim script
category: Vim
hljs_languages: [vim]
layout: default-ad
---
### Start hacking.

View File

@ -1,6 +1,7 @@
---
title: Xpath
category: HTML
layout: default-ad
---
### Descendant selectors