xonecas.io
2495
Xg

xonecas.github.com / commit fa397f9

poole and lanyon

rbdev2013-12-30 fa397f91ace91c13ffe416f6109b32f0d108d10a parent 36fcafc

9 files changed

_config.yml+5−5
@@ -6,10 +6,10 @@ pygments: true
66 permalink: pretty
77
88 # Setup
9-title: Poole
10-tagline: 'The Jekyll butler'
11-description: 'Base theme for Jekyll themes by @mdo.'
12-url: http://getpoole.com
9+title: "Sean Caetano Martin"
10+tagline: 'xonecas'
11+description: "I'm a software engineer who enjoys the ocasional blog post."
12+url: http://xonecas.github.com
1313
1414 author:
1515 name: 'Mark Otto'
@@ -21,4 +21,4 @@ paginate: 5
2121 version: 1.0.0
2222
2323 github:
24- repo: https://github.com/poole
24+ repo: https://github.com/xonecas
_includes/head.html+3−2
@@ -17,11 +17,12 @@
1717 <!-- CSS -->
1818 <link rel="stylesheet" href="/public/css/poole.css">
1919 <link rel="stylesheet" href="/public/css/syntax.css">
20- <link rel="stylesheet" href="http://fonts.googleapis.com/css?family=PT+Sans:400,400italic,700">
20+ <link rel="stylesheet" href="/public/css/lanyon.css">
21+ <link rel="stylesheet" href="http://fonts.googleapis.com/css?family=PT+Serif:400,400italic,700|PT+Sans:400">
2122
2223 <!-- Icons -->
2324 <link rel="apple-touch-icon-precomposed" sizes="144x144" href="/public/apple-touch-icon-144-precomposed.png">
24- <link rel="shortcut icon" href="/public/favicon.ico">
25+ <link rel="shortcut icon" href="/public/favicon.ico">
2526
2627 <!-- RSS -->
2728 <link rel="alternate" type="application/rss+xml" title="RSS" href="/atom.xml">
_includes/sidebar.html+38−0
@@ -0,0 +1,38 @@
1+<!-- Target for toggling the sidebar `.sidebar-checkbox` is for regular
2+ styles, `#sidebar-checkbox` for behavior. -->
3+<input type="checkbox" class="sidebar-checkbox" id="sidebar-checkbox">
4+
5+<!-- Toggleable sidebar -->
6+<div class="sidebar" id="sidebar">
7+ <div class="sidebar-item">
8+ <p>{{ site.description }}</p>
9+ </div>
10+
11+ <nav class="sidebar-nav">
12+ <a class="sidebar-nav-item{% if page.title == "Home" %} active{% endif %}" href="/">Home</a>
13+
14+ {% comment %}
15+ The code below dynamically generates a sidebar nav of pages with
16+ `layout: page` in the front-matter. See readme for usage.
17+ {% endcomment %}
18+
19+ {% assign pages_list = site.pages %}
20+ {% for node in pages_list %}
21+ {% if node.title != null %}
22+ {% if node.layout == "page" %}
23+ <a class="sidebar-nav-item{% if page.url == node.url %} active{% endif %}" href="{{ node.url }}">{{ node.title }}</a>
24+ {% endif %}
25+ {% endif %}
26+ {% endfor %}
27+
28+ <!--<a class="sidebar-nav-item" href="{{ site.github.repo }}/archive/v{{ site.version }}.zip">Download</a>-->
29+ <a class="sidebar-nav-item" href="{{ site.github.repo }}">GitHub</a>
30+ <!--<span class="sidebar-nav-item">Currently v{{ site.version }}</span>-->
31+ </nav>
32+
33+ <div class="sidebar-item">
34+ <p>
35+ &copy; {{ site.time | date: '%Y' }}. All rights reserved.
36+ </p>
37+ </div>
38+</div>
_layouts/default.html+17−14
@@ -3,22 +3,25 @@
33
44 {% include head.html %}
55
6- <body>
7-
8- <div class="container content">
9- <div class="masthead">
10- <h3 class="masthead-title">
11- <a href="/" title="Home">{{ site.title }}</a>
12- <small>{{ site.tagline }}</small>
13- </h3>
14- </div>
6+ <body class="theme-base-0d">
7+
8+ {% include sidebar.html %}
9+
10+ <!-- Wrap is the content to shift when toggling the sidebar. We wrap the
11+ content to avoid any CSS collisions with our real content. -->
12+ <div class="wrap">
13+
14+ <div class="container content">
15+ <div class="masthead">
16+ <label for="sidebar-checkbox" class="sidebar-toggle">☰</label>
1517
16- {{ content }}
18+ <h3 class="masthead-title">
19+ <a href="/" title="Home">{{ site.title }}</a>
20+ <small>{{ site.tagline }}</small>
21+ </h3>
22+ </div>
1723
18- <div class="footer">
19- <p>
20- &copy; {{ site.time | date: '%Y' }}. All rights reserved.
21- </p>
24+ {{ content }}
2225 </div>
2326 </div>
2427
_posts/2011-09-19-binary-search-twitter-size.markdown+1−1
@@ -16,7 +16,7 @@ Here's the **clean** implementation:
1616 var m;
1717 if (h < l) {
1818 return false;
19- }
19+ }
2020
2121 m = Math.floor(l + (h - l) / 2);
2222
_posts/2012-06-25-a-little-chrome-app.markdown+3−1
@@ -5,7 +5,7 @@ title: An example Chrome app
55
66 I've been using [Backbone.js](http://documentcloud.github.com/backbone/backbone.js) and after a few hours of reading the source in the browser my eyes demanded some syntax highlight. I assumed someone would've done this by now, but I could only find apps that provide much more than a nicer **reading** environment (I'm not looking to edit code on the browser). *Great!*, I tough to myself, *I get to roll my own*! Because I read mostly javascript source code, I focused on that, maybe if the need …
77
8-So to get started I looked around for highlighting libraries, and found a couple of heavyweights and then I saw [hijs.js by cloudhead](https://github.com/cloudhead/hijs) and I grabbed it!
8+So to get started I looked around for highlighting libraries, and found a couple of heavyweights and then I saw [hijs.js by cloudhead](https://github.com/cloudhead/hijs) and I grabbed it!
99
1010 After having a good grasp on what happens inside Hijs I was happy to see that it fits the bill perfectly because it will invoque itself when loaded. At that point all I needed was to actually create the app.
1111
@@ -13,6 +13,7 @@ I googled for some tutorials and ended up in the [official docs](http://code.goo
1313
1414 And... here it is:
1515
16+{% highlight javascript %}
1617 {
1718 "name": "Hijs",
1819 "version": "0.0.1",
@@ -29,6 +30,7 @@ And... here it is:
2930 }
3031 ]
3132 }
33+{% endhighlight %}
3234
3335 It is very simple, but i'm sure it can get much more complicated. Just read the docs!
3436
_posts/2013-12-31-whats-jekyll.md+0−8
@@ -1,8 +0,0 @@
1----
2-layout: post
3-title: CreativeJS - Three.js Tutorial
4----
5-
6-I completed [this](http://creativejs.com/tutorials/three-js-part-1-make-a-star-field/) tutorial. At the end of the tutorial Seb challenges everyone to do some exercises (homework): change the direction, shape, color and angle of the particles.
7-
8-For a deeper look on what is going on there, check out the [Github repo](https://github.com/xonecas/creativejs-threejs-part1). The evolution of the code is neatly organized with (git) tags.
about.md+1−25
@@ -3,28 +3,4 @@ layout: page
33 title: About
44 ---
55
6-<p class="message">
7- Hey there! This page is included as an example. Feel free to customize it for your own use upon downloading. Carry on!
8-</p>
9-
10-In the novel, *The Strange Case of Dr. Jeykll and Mr. Hyde*, Mr. Poole is Dr. Jekyll's virtuous and loyal butler. Similarly, Poole serves as an upstanding and effective foundation for Jekyll themes by [@mdo](https://twitter.com/mdo).
11-
12-There are currently two themes built on Poole:
13-
14-* [Hyde](http://hyde.getpoole.com)
15-* [Lanyon](http://lanyon.getpoole.com)
16-
17-Learn more and contribute on [GitHub](https://github.com/poole).
18-
19-## Setup
20-
21-Some fun facts about the setup of this project include:
22-
23-* Built for [Jekyll](http://jekyllrb.com)
24-* Developed on GitHub and hosted for free on [GitHub Pages](https://pages.github.com)
25-* Coded with [Sublime Text 2](http://sublimetext.org), an amazing code editor
26-* Designed and developed while listening to music like [Blood Bros Trilogy](https://soundcloud.com/maddecent/sets/blood-bros-series)
27-
28-Have questions or suggestions? Feel free to [open an issue on GitHub](https://github.com/poole/issues/new) or [ask me on Twitter](https://twitter.com/mdo).
29-
30-Thanks for reading!
6+Hi, I'm Sean. Most people know me as *xonecas*. I'm a engineer at [Redbeacon.com](//redbeacon.com) and I'm very happy here. I enjoy small projects and prototyping crazy ideas. My goal as an engineer is to help the web as a platform.
public/css/lanyon.css+491−0
@@ -0,0 +1,491 @@
1+/*
2+ * ___
3+ * /\_ \
4+ * \//\ \ __ ___ __ __ ___ ___
5+ * \ \ \ /'__`\ /' _ `\/\ \/\ \ / __`\ /' _ `\
6+ * \_\ \_/\ \_\.\_/\ \/\ \ \ \_\ \/\ \_\ \/\ \/\ \
7+ * /\____\ \__/.\_\ \_\ \_\/`____ \ \____/\ \_\ \_\
8+ * \/____/\/__/\/_/\/_/\/_/`/___/> \/___/ \/_/\/_/
9+ * /\___/
10+ * \/__/
11+ *
12+ * Lanyon is a responsive, mobile first Jekyll theme that features a toggleable
13+ * sidebar drawer for out of sight navigation. It's based on Poole, the Jekyll
14+ * butler. See the project readme for usage information.
15+ *
16+ * Designed, built, and released under MIT license by @mdo.
17+ *
18+ * Learn more at https://github.com/poole/lanyon.
19+ */
20+
21+
22+/*
23+ * Contents
24+ *
25+ * Global resets
26+ * Masthead
27+ * Sidebar
28+ * Posts and pages
29+ * Pagination
30+ * Reverse layout
31+ * Themes
32+ */
33+
34+
35+/*
36+ * Global resets
37+ *
38+ * Update the foundational and global aspects of the page.
39+ */
40+
41+/* Prevent scroll on narrow devices */
42+html,
43+body {
44+ overflow-x: hidden;
45+}
46+
47+html {
48+ font-family: "PT Serif", Georgia, "Times New Roman", serif;
49+}
50+
51+h1, h2, h3, h4, h5, h6 {
52+ font-family: "PT Sans", Helvetica, Arial, sans-serif;
53+ font-weight: 400;
54+ color: #313131;
55+ letter-spacing: -.025rem;
56+}
57+
58+
59+/*
60+ * Wrapper
61+ *
62+ * The wrapper is used to position site content when the sidebar is toggled. We
63+ * use an outter wrap to position the sidebar without interferring with the
64+ * regular page content.
65+ */
66+
67+.wrap {
68+ position: relative;
69+ width: 100%;
70+ -webkit-transition: -webkit-transform 0.3s ease-in-out;
71+ transition: transform 0.3s ease-in-out;
72+}
73+
74+
75+/*
76+ * Masthead
77+ *
78+ * Super small header above the content for site name and short description.
79+ */
80+
81+.masthead {
82+ text-align: center;
83+}
84+.masthead-title small {
85+ display: none;
86+}
87+@media (min-width: 48rem) {
88+ .masthead {
89+ text-align: left;
90+ }
91+ .masthead-title small {
92+ display: inline;
93+ }
94+}
95+
96+
97+/*
98+ * Sidebar
99+ *
100+ * The sidebar is the drawer, the item we are toggling with our handy hamburger
101+ * button in the corner of the page.
102+ *
103+ * This particular sidebar implementation was inspired by Chris Coyier's
104+ * "Offcanvas Menu with CSS Target" article, and the checkbox variation from the
105+ * comments by a reader. It modifies both implementations to continue using the
106+ * checkbox (no change in URL means no polluted browser history), but this uses
107+ * `position` for the menu to avoid some potential content reflow issues.
108+ *
109+ * Source: http://css-tricks.com/off-canvas-menu-with-css-target/#comment-207504
110+ */
111+
112+/* Style and "hide" the sidebar */
113+.sidebar {
114+ max-height: 0;
115+ font-family: "PT Sans", Helvetica, Arial, sans-serif;
116+ font-size: .875rem; /* 14px */
117+ color: rgba(255,255,255,.6);
118+ background-color: #202020;
119+ transition: max-height 0.3s ease-in-out;
120+}
121+
122+@media (min-width: 48rem) {
123+ .sidebar {
124+ position: fixed;
125+ top: 0;
126+ bottom: 0;
127+ left: 0;
128+ overflow-y: auto;
129+ width: 14rem;
130+ max-height: none;
131+ font-size: .75rem; /* 15px */
132+ -webkit-transition: -webkit-transform 0.3s ease-in-out;
133+ -moz-transition: -moz-transform 0.3s ease-in-out;
134+ -ms-transition: -ms-transform 0.3s ease-in-out;
135+ transition: transform 0.3s ease-in-out;
136+ -webkit-transform: translate3d(-100%, 0, 0);
137+ -moz-transform: translate3d(-100%, 0, 0);
138+ -ms-transform: translate3d(-100%, 0, 0);
139+ transform: translate3d(-100%, 0, 0);
140+ -webkit-backface-visibility: hidden;
141+ -moz-backface-visibility: hidden;
142+ -ms-backface-visibility: hidden;
143+ backface-visibility: hidden;
144+ }
145+}
146+
147+/* Sidebar content */
148+.sidebar a {
149+ font-weight: normal;
150+ color: #fff;
151+}
152+.sidebar-item {
153+ padding: 1rem;
154+}
155+.sidebar-item p:last-child {
156+ margin-bottom: 0;
157+}
158+
159+/* Sidebar nav */
160+.sidebar-nav {
161+ border-bottom: 1px solid rgba(255,255,255,.1);
162+}
163+.sidebar-nav-item {
164+ display: block;
165+ padding: .5rem 1rem;
166+ border-top: 1px solid rgba(255,255,255,.1);
167+}
168+.sidebar-nav-item.active,
169+a.sidebar-nav-item:hover,
170+a.sidebar-nav-item:focus {
171+ text-decoration: none;
172+ background-color: rgba(255,255,255,.1);
173+ border-color: transparent;
174+}
175+
176+@media (min-width: 48rem) {
177+ .sidebar-item {
178+ padding: 1.5rem;
179+ }
180+ .sidebar-nav-item {
181+ padding-left: 1.5rem;
182+ padding-right: 1.5rem;
183+ }
184+}
185+
186+/* Hide the sidebar checkbox that we toggle with `.sidebar-toggle` */
187+.sidebar-checkbox {
188+ display: none;
189+}
190+
191+/* Style the `label` that we use to target the `.sidebar-checkbox` */
192+.sidebar-toggle {
193+ position: absolute;
194+ top: .8rem;
195+ left: 1rem;
196+ padding: .4rem .65rem;
197+ font-family: Arial, sans-serif; /* Ensure vertical alignment */
198+ line-height: 1;
199+ color: #505050;
200+ background-color: #fff;
201+ border-radius: 4px;
202+ cursor: pointer;
203+ -webkit-transition: -webkit-transform 0.3s ease-in-out;
204+ -moz-transition: -moz-transform 0.3s ease-in-out;
205+ -ms-transition: -ms-transform 0.3s ease-in-out;
206+ transition: transform 0.3s ease-in-out;
207+}
208+.sidebar-toggle:active,
209+#sidebar-checkbox:checked ~ .wrap .sidebar-toggle {
210+ color: #fff;
211+ background-color: #505050;
212+}
213+
214+#sidebar-checkbox:checked + .sidebar {
215+ max-height: 1000px;
216+}
217+
218+@media (min-width: 48rem) {
219+ .sidebar-toggle {
220+ position: fixed;
221+ left: 1rem;
222+ }
223+ #sidebar-checkbox:checked + .sidebar {
224+ max-height: none;
225+ }
226+ #sidebar-checkbox:checked + .sidebar {
227+ -webkit-transform: translate3d(0, 0, 0);
228+ -moz-transform: translate3d(0, 0, 0);
229+ -ms-transform: translate3d(0, 0, 0);
230+ transform: translate3d(0, 0, 0);
231+ }
232+ #sidebar-checkbox:checked ~ .wrap {
233+ -webkit-transform: translate3d(14rem, 0, 0);
234+ -moz-transform: translate3d(14rem, 0, 0);
235+ -ms-transform: translate3d(14rem, 0, 0);
236+ transform: translate3d(14rem, 0, 0);
237+ }
238+}
239+
240+
241+/*
242+ * Posts and pages
243+ *
244+ * Each post is wrapped in `.post` and is used on default and post layouts. Each
245+ * page is wrapped in `.page` and is only used on the page layout.
246+ */
247+
248+.page,
249+.post {
250+ margin-bottom: 4em;
251+}
252+
253+/* Blog post or page title */
254+.page-title,
255+.post-title,
256+.post-title a {
257+ color: #303030;
258+}
259+.page-title,
260+.post-title {
261+ margin-top: 0;
262+}
263+
264+/* Meta data line below post title */
265+.post-date {
266+ display: block;
267+ margin-top: -.5rem;
268+ margin-bottom: 1rem;
269+ color: #9a9a9a;
270+}
271+
272+/* Related posts */
273+.related {
274+ padding-top: 2rem;
275+ padding-bottom: 2rem;
276+ border-top: 1px solid #eee;
277+}
278+.related-posts {
279+ padding-left: 0;
280+ list-style: none;
281+}
282+.related-posts h3 {
283+ margin-top: 0;
284+}
285+.related-posts li small {
286+ font-size: 75%;
287+ color: #999;
288+}
289+.related-posts li a:hover {
290+ color: #268bd2;
291+ text-decoration: none;
292+}
293+.related-posts li a:hover small {
294+ color: inherit;
295+}
296+
297+
298+/*
299+ * Pagination
300+ *
301+ * Super lightweight (HTML-wise) blog pagination. `span`s are provide for when
302+ * there are no more previous or next posts to show.
303+ */
304+
305+.pagination {
306+ overflow: hidden; /* clearfix */
307+ margin-left: -1rem;
308+ margin-right: -1rem;
309+ font-family: "PT Sans", Helvetica, Arial, sans-serif;
310+ color: #ccc;
311+ text-align: center;
312+}
313+
314+/* Pagination items can be `span`s or `a`s */
315+.pagination-item {
316+ display: block;
317+ padding: 1rem;
318+ border: 1px solid #eee;
319+}
320+.pagination-item:first-child {
321+ margin-bottom: -1px;
322+}
323+
324+/* Only provide a hover state for linked pagination items */
325+a.pagination-item:hover {
326+ background-color: #f5f5f5;
327+}
328+
329+@media (min-width: 30rem) {
330+ .pagination {
331+ margin: 3rem 0;
332+ }
333+ .pagination-item {
334+ float: left;
335+ width: 50%;
336+ }
337+ .pagination-item:first-child {
338+ margin-bottom: 0;
339+ border-top-left-radius: 4px;
340+ border-bottom-left-radius: 4px;
341+ }
342+ .pagination-item:last-child {
343+ margin-left: -1px;
344+ border-top-right-radius: 4px;
345+ border-bottom-right-radius: 4px;
346+ }
347+}
348+
349+
350+/*
351+ * Reverse layout
352+ *
353+ * Flip the orientation of the page by placing the `.sidebar` and sidebar toggle
354+ * on the right side.
355+ */
356+
357+.layout-reverse .sidebar-toggle {
358+ left: auto;
359+ right: 0;
360+}
361+
362+@media (min-width: 48rem) {
363+ .layout-reverse .sidebar {
364+ left: auto;
365+ right: -14rem;
366+ transition-property: right;
367+ }
368+ .layout-reverse .sidebar-toggle {
369+ left: auto;
370+ right: 1rem;
371+ }
372+ .layout-reverse .wrap {
373+ transition-property: right;
374+ }
375+ .layout-reverse #sidebar-checkbox:checked + .sidebar {
376+ left: auto;
377+ right: 0;
378+ }
379+ .layout-reverse #sidebar-checkbox:checked ~ .wrap {
380+ left: auto;
381+ right: 14rem;
382+ }
383+ .layout-reverse #sidebar-checkbox:checked ~ .wrap .sidebar-toggle {
384+ left: auto;
385+ right: 15rem;
386+ }
387+}
388+
389+
390+/*
391+ * Themes
392+ *
393+ * Apply custom color schemes by adding the appropriate class to the `body`.
394+ * Based on colors from Base16: http://chriskempson.github.io/base16/#default.
395+ */
396+
397+/* Red */
398+.theme-base-08 .sidebar,
399+.theme-base-08 .sidebar-toggle:active,
400+.theme-base-08 #sidebar-checkbox:checked ~ .wrap .sidebar-toggle {
401+ background-color: #ac4142;
402+}
403+.theme-base-08 .container a,
404+.theme-base-08 .sidebar-toggle,
405+.theme-base-08 .related-posts li a:hover {
406+ color: #ac4142;
407+}
408+
409+/* Orange */
410+.theme-base-09 .sidebar,
411+.theme-base-09 .sidebar-toggle:active,
412+.theme-base-09 #sidebar-checkbox:checked ~ .wrap .sidebar-toggle {
413+ background-color: #d28445;
414+}
415+.theme-base-09 .container a,
416+.theme-base-09 .sidebar-toggle,
417+.theme-base-09 .related-posts li a:hover {
418+ color: #d28445;
419+}
420+
421+/* Yellow */
422+.theme-base-0a .sidebar,
423+.theme-base-0a .sidebar-toggle:active,
424+.theme-base-0a #sidebar-checkbox:checked ~ .wrap .sidebar-toggle {
425+ background-color: #f4bf75;
426+}
427+.theme-base-0a .container a,
428+.theme-base-0a .sidebar-toggle,
429+.theme-base-0a .related-posts li a:hover {
430+ color: #f4bf75;
431+}
432+
433+/* Green */
434+.theme-base-0b .sidebar,
435+.theme-base-0b .sidebar-toggle:active,
436+.theme-base-0b #sidebar-checkbox:checked ~ .wrap .sidebar-toggle {
437+ background-color: #90a959;
438+}
439+.theme-base-0b .container a,
440+.theme-base-0b .sidebar-toggle,
441+.theme-base-0b .related-posts li a:hover {
442+ color: #90a959;
443+}
444+
445+/* Cyan */
446+.theme-base-0c .sidebar,
447+.theme-base-0c .sidebar-toggle:active,
448+.theme-base-0c #sidebar-checkbox:checked ~ .wrap .sidebar-toggle {
449+ background-color: #75b5aa;
450+}
451+.theme-base-0c .container a,
452+.theme-base-0c .sidebar-toggle,
453+.theme-base-0c .related-posts li a:hover {
454+ color: #75b5aa;
455+}
456+
457+/* Blue */
458+.theme-base-0d .sidebar,
459+.theme-base-0d .sidebar-toggle:active,
460+.theme-base-0d #sidebar-checkbox:checked ~ .wrap .sidebar-toggle {
461+ background-color: #6a9fb5;
462+}
463+.theme-base-0d .container a,
464+.theme-base-0d .sidebar-toggle,
465+.theme-base-0d .related-posts li a:hover {
466+ color: #6a9fb5;
467+}
468+
469+/* Magenta */
470+.theme-base-0e .sidebar,
471+.theme-base-0e .sidebar-toggle:active,
472+.theme-base-0e #sidebar-checkbox:checked ~ .wrap .sidebar-toggle {
473+ background-color: #aa759f;
474+}
475+.theme-base-0e .container a,
476+.theme-base-0e .sidebar-toggle,
477+.theme-base-0e .related-posts li a:hover {
478+ color: #aa759f;
479+}
480+
481+/* Brown */
482+.theme-base-0f .sidebar,
483+.theme-base-0f .sidebar-toggle:active,
484+.theme-base-0f #sidebar-checkbox:checked ~ .wrap .sidebar-toggle {
485+ background-color: #8f5536;
486+}
487+.theme-base-0f .container a,
488+.theme-base-0f .sidebar-toggle,
489+.theme-base-0f .related-posts li a:hover {
490+ color: #8f5536;
491+}