This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@mixin apply($placeholder: false) { | |
@if $placeholder { | |
@extend #{$placeholder}; | |
} | |
@else { | |
@content; | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@for $i from 1 through 12 { | |
@debug format( | |
('.on-', 2, '-columns-i-am-spanning-', 1), | |
(12, $i) | |
); | |
} | |
/* | |
DEBUG: .on-1-columns-i-am-spanning-12 | |
DEBUG: .on-2-columns-i-am-spanning-12 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// TODO: scope vars | |
@mixin script() { | |
@if $plasticss__helper__script--use_class { | |
#{$plasticss__helper__script--class} { | |
@content; | |
} | |
} | |
@else if $plasticss__helper__script { | |
@content; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@mixin split($selectors...) { | |
@each $selector in $selectors { | |
#{$selector} { | |
@content; | |
} | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function absolutize($html, $base) { | |
// href, src, background attributes | |
$html = preg_replace('#(<[^>]+(href|src|background)=(?:3D)?")(?![a-z]+:)/?([^"]+)"#is', '$1'.$base.'$3"', $html); | |
// style attributes url(), src() | |
$html = preg_replace('#(<[^>]+style=(?:3D)?"[^"]*(url|src)\([\s\']*)(?![a-z]+:)/?([^)]+)\)#is', '$1'.$base.'$3)', $html); | |
// style tag | |
preg_match_all('#<style[^>]*>([^<]+)#is', $html, $styles); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ---- | |
// Sass (v3.3.0.rc.5) | |
// Compass (v1.0.0.alpha.18) | |
// ---- | |
// https://docs.google.com/spreadsheet/ccc?key=0AgFzwMiAdIOfdDdkMVhPazVjMnI4eDdtM19VUzhOSVE&usp=sharing | |
@function nth-side($value, $n) { | |
@while length($value) < $n { | |
$value: append($value, nth($value, floor((length($value) + 1)/2))); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ---- | |
// Sass (v3.3.14) | |
// Compass (v1.0.0.rc.1) | |
// ---- | |
// attribute used instead of `class` | |
$class-attr: 'data-g'; | |
// return attribute selector | |
@function g($class) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="fr-FR" dir="ltr"> | |
<head> | |
<title>Untitled HTML5 document</title> | |
<meta charset="UTF-8" /> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |
<!--[if lt IE 9]><script src="assets/libs/html5shiv/html5shiv-prev3.7.2.js"></script><![endif]--> | |
<link rel="stylesheet" href="assets/main.css" /> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "{{name}}", | |
"version": "0.1.0", | |
"description": "", | |
"keywords": [], | |
"author": { | |
"name": "François Germain", | |
"email": "[email protected]" | |
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ---- | |
// Sass (v3.4.7) | |
// Compass (v1.0.1) | |
// ---- | |
@function map-set($map, $key, $value) { | |
@return map-merge($map, ($key: $value)); | |
} | |