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
/* With a CSS grid system */ | |
/* Using a Css system, you'll have in your mark-up something like that | |
* | |
* <div class="col span_1_of_2"></div> | |
* <div class="col span_1_of_2"></div> | |
* | |
* Then, for a simple rwd task, you'll have this in your CSS: | |
* (taken from http://www.responsivegridsystem.com/) | |
*/ |
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
/////////////////////////////////////////////////////////////////// | |
// Extending the standard compass CSS3 mixins with CSS3PIE | |
/////////////////////////////////////////////////////////////////// | |
$pie: url('/RELATIVE/PATH/TO/PIE.htc'); | |
$pie-approach: relative; | |
@import "compass/css3"; | |
@mixin pie-border-radius($radius, $position: $pie-approach) { |
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 triangle( | |
$dir: top, | |
$pos: 50%, | |
$color1: #fff, | |
$color2: darken($color1, 30%), | |
$size1: 6px, | |
$size2: $size1 | |
) { | |
$opos: map-get(( top: bottom, right: left, bottom: top, left: right ), $dir); | |
$transparent: if($dir == left or $dir == right, (top, bottom), (left, right)); |
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
function THEME_preprocess_html(&$vars) { | |
if ($vars['user']) { | |
foreach($vars['user']->roles as $key => $role){ | |
$vars['classes_array'][] = 'role-' . drupal_html_class($role); | |
} | |
} | |
} |
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
@import "compass/css3"; | |
@import "salsa/salsa"; | |
// container grids | |
.container { | |
text-align: center; | |
.element { | |
@include border-radius(12px); | |
@include box-shadow(0 0 40px rgba(0,0,0,.3) inset); | |
@include transition(margin .5s); |
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
/* | |
* ##### Sasson - advanced drupal theming. ##### | |
* | |
* SASS mixins | |
* http://sass-lang.com/docs/yardoc/file.SASS_REFERENCE.html#mixins | |
* | |
*/ | |
// Inline block with ie7 support | |
@mixin inline-block($alignment: false, $ie7-support: false) { |
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
/** | |
* CSS flipping inheritance | |
*/ | |
/* Original code */ | |
.class { | |
margin-left: 3em; /* Will be flipped */ | |
margin-right: 2em; /* Will be flipped */ | |
padding-left: 1em; /* Will be flipped and reseted */ | |
} |
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
/** | |
* CSS flipping tools | |
*/ | |
/* Original code */ | |
.class { | |
padding: 1px 2px 3px 4px; | |
margin-right: 3em; | |
background: url(image.gif) no-repeat right center; | |
margin-bottom: 20px; |
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
/** | |
* This script will watch files for changes and | |
* automatically refresh the browser when a file is modified. | |
* | |
* Usage: | |
* | |
* - Include it: | |
* <script src="/js/fileWatcher.js"></script> | |
* | |
* - Call it from your script (or un-comment the call below): |
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
/** | |
* Media queries and @import rules | |
*/ | |
@import "http://twitter.github.com/bootstrap/assets/css/bootstrap.css"; |