Skip to content

Instantly share code, notes, and snippets.

View kejun's full-sized avatar
💭
I may be slow to respond.

kejun kejun

💭
I may be slow to respond.
View GitHub Profile
@kejun
kejun / dabblet.css
Created November 21, 2013 01:36
Untitled
img {
position: absolute;
margin: auto;
top: -100em;
bottom: -100em;
left: -100em;
right: -100em;
}
@kejun
kejun / dabblet.css
Created November 27, 2013 06:17
Untitled
img {
position: absolute;
margin: auto;
top: -1000em;
bottom: -1000em;
left: -1000em;
right: -1000em;
}
@kejun
kejun / dabblet.css
Created November 27, 2013 08:53
Untitled
body {
padding: 2em 0;
font: 14px/1.5 sans-serif;
text-align: center;
}
section {
margin-bottom: 5em;
}
@kejun
kejun / dabblet.css
Created March 22, 2014 04:31
Untitled
html,body {
margin: 0;
min-height: 100%;
}
body:after {
content: "";
position: absolute;
z-index: 1;
left: 50%;
@kejun
kejun / gist:9908688
Created April 1, 2014 06:18
不可变数据更新
var DIRECTIVE_SET = '$set';
var DIRECTIVE_PUSH = '$push';
var DIRECTIVE_UNSHIFT = '$unshift';
var DIRECTIVE_SPLICE = '$splice';
var DIRECTIVE_MERGE = '$merge';
var ALL_DIRECTIVES_SET = {};
ALL_DIRECTIVES_SET[DIRECTIVE_SET] = true;
ALL_DIRECTIVES_SET[DIRECTIVE_PUSH] = true;
ALL_DIRECTIVES_SET[DIRECTIVE_UNSHIFT] = true;
@kejun
kejun / dabblet.css
Created April 10, 2014 04:02
Untitled
p:4px solid #fff}ul.block-grid[data-clearing]{overflow:visible}.clearing-blackout ul.block-grid[data-clearing].two-up>li:nth-of-type(2n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].three-up>li:nth-of-type(3n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].four-up>li:nth-of-type(4n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].five-up>li:nth-of-type(5n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].six-up>li:nth-of-type(6n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].seven-up>li:nth-of-type(7n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].eight-up>li:nth-of-type(8n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].nine-up>li:nth-of-type(9n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].ten-up>li:nth-of-type(10n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].eleven-up>li:nth-of-type(11n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].twelve-up>li:nth-of-type(12n+
@kejun
kejun / dabblet.css
Created April 10, 2014 04:02
Untitled
p:4px solid #fff}ul.block-grid[data-clearing]{overflow:visible}.clearing-blackout ul.block-grid[data-clearing].two-up>li:nth-of-type(2n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].three-up>li:nth-of-type(3n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].four-up>li:nth-of-type(4n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].five-up>li:nth-of-type(5n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].six-up>li:nth-of-type(6n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].seven-up>li:nth-of-type(7n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].eight-up>li:nth-of-type(8n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].nine-up>li:nth-of-type(9n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].ten-up>li:nth-of-type(10n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].eleven-up>li:nth-of-type(11n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].twelve-up>li:nth-of-type(12n+
@kejun
kejun / dabblet.css
Created April 10, 2014 04:02
Untitled
p:4px solid #fff}ul.block-grid[data-clearing]{overflow:visible}.clearing-blackout ul.block-grid[data-clearing].two-up>li:nth-of-type(2n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].three-up>li:nth-of-type(3n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].four-up>li:nth-of-type(4n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].five-up>li:nth-of-type(5n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].six-up>li:nth-of-type(6n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].seven-up>li:nth-of-type(7n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].eight-up>li:nth-of-type(8n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].nine-up>li:nth-of-type(9n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].ten-up>li:nth-of-type(10n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].eleven-up>li:nth-of-type(11n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].twelve-up>li:nth-of-type(12n+
@kejun
kejun / dabblet.css
Created April 10, 2014 04:02
Untitled
p:4px solid #fff}ul.block-grid[data-clearing]{overflow:visible}.clearing-blackout ul.block-grid[data-clearing].two-up>li:nth-of-type(2n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].three-up>li:nth-of-type(3n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].four-up>li:nth-of-type(4n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].five-up>li:nth-of-type(5n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].six-up>li:nth-of-type(6n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].seven-up>li:nth-of-type(7n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].eight-up>li:nth-of-type(8n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].nine-up>li:nth-of-type(9n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].ten-up>li:nth-of-type(10n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].eleven-up>li:nth-of-type(11n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].twelve-up>li:nth-of-type(12n+
@kejun
kejun / dabblet.css
Created April 10, 2014 04:02
Untitled
p:4px solid #fff}ul.block-grid[data-clearing]{overflow:visible}.clearing-blackout ul.block-grid[data-clearing].two-up>li:nth-of-type(2n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].three-up>li:nth-of-type(3n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].four-up>li:nth-of-type(4n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].five-up>li:nth-of-type(5n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].six-up>li:nth-of-type(6n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].seven-up>li:nth-of-type(7n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].eight-up>li:nth-of-type(8n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].nine-up>li:nth-of-type(9n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].ten-up>li:nth-of-type(10n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].eleven-up>li:nth-of-type(11n+1){clear:none}.clearing-blackout ul.block-grid[data-clearing].twelve-up>li:nth-of-type(12n+