Solutions Architect at VML
Drupal developer since 2005
Kansas City Drupal Users Group
Setting Up The Tooling
Getting Started With The Theme Build
Alternatives
Mac or Linux - Already installed
Windows - http://rubyinstaller.org
Linux - Use the package manager
My favorite - RVM (https://rvm.io)
CSS extention language
CSS authoring framework
http://compass-style.org/
An event listener (file watcher) and task runner - runs stuff with things have changed
http://guardgem.org
Scout - http://mhs.github.io/scout-app - Mac and Windows
Compass.app - http://compass.kkbox.com - Mac, Windows, and Linux
See the list at http://sass-lang.com/install
Gemfile - Tells bundler what gems you want to use and which versions you need
source 'http://rubygems.org'
# Update compass so Sass 3.3 and Susy 2 can be used
gem "compass", ">= 1.0.0.alpha.19"
# Susy
gem "susy"
gem "breakpoint"
# Guard
gem "guard"
gem "guard-compass"
Run:
bundle install
config.rb -> Tells compass where to find and put everything.
require "susy"
require "breakpoint"
http_path = "/"
css_dir = "css"
sass_dir = "sass"
images_dir = "images"
javascripts_dir = "js"
output_style = :expanded
relative_assets = true
line_comments = true
Guardfile - Tells Guard what files to watch and what to do when they change
guard :compass do
watch(%r{sass/.+\.scss$})
end
Run:
bundle exec guard
.info file specifies css version of each sass file
By page/site structure - header, footer, content, etc.
By Drupal bits - nodes, views, blocks, etc.
By site features - pages, blog, image gallery, etc.
Don't forget your content authors
sass css
├── _content.scss ├── style.css
├── _footer.scss └── wysiwyg.css
├── _forms.scss
├── _global_and_wysiwyg.scss
├── _global.scss
├── _header.scss
├── _layout.scss
├── _nav.scss
├── style.scss
├── _variables.scss
└── wysiwyg.scss
style.scss
// Library imports
@import "compass/reset";
@import "compass/css3";
@import "compass/typography";
@import "susy";
@import "breakpoint";
// Project specific imports
@import "variables";
@import "layout";
@import "global_and_wysiwyg";
@import "global";
@import "header";
@import "footer";
@import "nav";
@import "content";
@import "forms";
@include establish-baseline;
wysiwyg.scss
// Library imports
@import "compass/css3";
@import "compass/typography";
@import "breakpoint";
// Project imports
@import "variables";
@import "global_and_wysiwyg";
@import "content";
@include establish-baseline;
_variables.scss
// Vertical rhythm
$base-font-size: 16px;
$base-line-height: 24px;
// Screen sizes
$medium-width: min-width 45em;
$large-width: min-width 60em;
// Global susy settings
$susy: (
gutters: 1/10
);
There isn't one (if you want to use Sass)
Less - http://lesscss.org
Burbon, Neat, and Bitters
Mixin replacement libraries (e.g. Burbon/Neat/Bitters)
Libraries/scripts used by build systems (e.g. guard, grunt, gulp)
Grunt - http://gruntjs.com
Gulp - http://gulpjs.com
Both are javascript/node applications
Each have extensive plugin libraries for all kinds of functionality
Bootstrap - http://getbootstrap.com
Foundation - http://foundation.zurb.com
My Github - https://github.com/karlkedrovsky
Sass - http://sass-lang.com
Compass - http://compass-style.org
Susy - http://susy.oddbird.net
Breakpoint - http://breakpoint-sass.com
Guard - http://guardgem.org
Omega 4 - https://www.drupal.org/project/omega
Level Up Tuts - http://leveluptuts.com/
Email - karl@kedrovsky.com or kkedrovsky@vml.com
Twitter - @karlkedrovsky
Drupal.org - https://www.drupal.org/u/karlkedrovsky