From 357a7841e4beec0766be7df69e3f2e1c8750c674 Mon Sep 17 00:00:00 2001 From: Ben Lancaster Date: Thu, 6 Sep 2012 09:34:12 +0100 Subject: [PATCH 1/2] Upgrading Susy to 1.0 --- SASS.lrplugin/lib/susy/CHANGELOG.mkdn | 100 ++++++++----- SASS.lrplugin/lib/susy/LICENSE.txt | 2 +- SASS.lrplugin/lib/susy/Manifest | 13 +- SASS.lrplugin/lib/susy/Rakefile | 2 +- SASS.lrplugin/lib/susy/VERSION | 2 +- .../lib/susy/sass/susy/_functions.scss | 56 +++++-- SASS.lrplugin/lib/susy/sass/susy/_grid.scss | 138 ++++++++++++++++-- SASS.lrplugin/lib/susy/sass/susy/_media.scss | 68 ++++++--- .../lib/susy/sass/susy/_settings.scss | 26 +++- SASS.lrplugin/lib/susy/susy.gemspec | 33 +++-- 10 files changed, 337 insertions(+), 103 deletions(-) diff --git a/SASS.lrplugin/lib/susy/CHANGELOG.mkdn b/SASS.lrplugin/lib/susy/CHANGELOG.mkdn index b8a4f7bf..e0f00b1a 100644 --- a/SASS.lrplugin/lib/susy/CHANGELOG.mkdn +++ b/SASS.lrplugin/lib/susy/CHANGELOG.mkdn @@ -1,64 +1,84 @@ Susy Changelog ============== -v1.0 [UNRELEASED] ------------------ +v1.0 [Aug 14, 2012] +------------------- This release is loaded with new features, but don't let that fool you. Susy just became shockingly simple to use. See the [website][site] for details. -Note that the gem name has changed from `compass-susy-plugin` to `susy`. +The gem name has changed from `compass-susy-plugin` to `susy`. +First uninstall the old gem, then install the new one. +If you have both gems installed, you will get errors. [site]: http://susy.oddbird.net/ -New Features: - -* `omega` can now be set directly through the `columns` mixin for much - more compact output. -* Create responsive grid break-points using `at-breakpoint` and `layout`. -* `container` mixin now accepts one or more grids/breakpoints as a shortcut. -* All mixins respect your `$legacy-support-for-ie` settings. -* The `space` function can be used anywhere you need column+gutter math. -* `push`, `pull`, `pre`, `post`, and `squish` add margin left/right shortcuts. +Semantics: -Changed API: +We re-arranged the code +in order to make the syntax simpler and more consistent: -* `$total-cols` => `$total-columns` -* `$col-width` => `$column-width` -* `$side-gutter-width` => `$grid-padding` -* `+un-column` & `+reset-column` => `+reset-columns` -* `+columns` => `+span-columns` - -Removed: +* `$total-cols` is now `$total-columns`. +* `$col-width` is now `$column-width`. +* `$side-gutter-width` is now `$grid-padding` + and gets applied directly to the grid container. +* `un-column` & `reset-column` mixins have merged into `reset-columns`. +* `columns` has been renamed `span-columns` to resolve the conflict with CSS3 columns. + See other improvements to span-columns below. -* `alpha` is no longer needed. -* `+omega` no longer accepts the `$context` argument. -* `full` can be replaced by a simple `clear: both;` when needed. -* `side-gutter()` is no longer needed. Use `$grid-padding` instead. +We also removed several bothersome requirements: -Other: +* The `alpha` mixin is no longer needed. Ever. +* The `omega` no longer takes a `$context` argument. +* `full` has been removed entirely. + Elements will be full-width by default. + You can add `clear: both;` back in as needed. +* `side-gutter()` is no longer needed. + You can use the `$grid-padding` setting directly. -* Fix bug in susy-background-grid for fluid sites. -* Fix minor bug with repeated 'display' properties. -* Lower Compass dependency to 0.12.2 -* Add Sass dependency at 3.2.0.alpha.247 +Upgrade: -### Upgrade: +That's all you need in order to upgrade from Susy 0.9. -1. Uninstall `compass-susy-plugin` and install `susy` in it's place. -2. Find and replace the 5 simple "Changed API's" listed above. -3. Remove the `$context` argument from all `omega` mixins. -4. Remove any mention of `alpha` and `full` in your code. - * Replace `full` with `clear: both;` where necessary. -5. Remove any mention of `side-gutter()`. - * This may require some refactoring, depending on your uses. -6. [Optional] Any time 'columns' and 'omega' are declared in the same block, - they can now be joined together. `@include columns(3); @include omega();` - can become `@include columns(3 omega)`. +1. Uninstall and re-install the gem. +2. Find and replace the semantic changes listed above. You're done! Stop worrying about all that "nested vs. root" bullshit, and start playing with the new toys! +If you use the `$from` directional arguments +directly in the `span-columns` mixin, +there may be one more change to make. +See below: + +New Features: + +* `span-columns` supports new features: + - "omega" can be applied directly through the `$columns` argument. + - Internal padding can be added through the `$padding` argument. + - This pushes the `$from` argument from third position into fourth. +* `at-breakpoint` allows you to change layouts at media breakpoints. +* `container` accepts multiple media-layout combinations as a shortcut. +* `layout` allows you to use a different layout at any time. +* `with-grid-settings` allows you to change any or all grid settings. +* `set-container-width` does what it says, without the other container code. +* `$breakpoint-media-output`, `$breakpoint-ie-output`, and `$breakpoint-raw-output` + settings help manage the different outputs from `at-breakpoint` + when you have IE-overrides living in a file of their own. +* `border-box-sizing` will apply the popular `* { box-sizing: border-box }` + universal box-model fix, as well as changing the Susy `$border-box-model` setting for you, + so Susy knows to adjust some math. +* The `space()` function can be used anywhere you need column+gutter math. +* `push`, `pull`, `pre`, `post`, and `squish` mixins help manage margins. +* use the `nth-omega` mixin to set omega on any nth-child, nth-of-type, + first, last, or only element. +* `remove-omega` and `remove-nth-omega` will remove + the omega-specific styles from an element. +* `$container-width` will override the width of your container + with any arbitrary length. +* `$container-style` will override the type of grid container + (magic, fluid, fixed, static, etc) to use. + v0.9 [Apr 25 2011] ------------------ diff --git a/SASS.lrplugin/lib/susy/LICENSE.txt b/SASS.lrplugin/lib/susy/LICENSE.txt index a71b22e8..6b0b7b19 100644 --- a/SASS.lrplugin/lib/susy/LICENSE.txt +++ b/SASS.lrplugin/lib/susy/LICENSE.txt @@ -1,4 +1,4 @@ -Copyright (c) 2011, Eric Meyer +Copyright (c) 2012, Eric Meyer All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/SASS.lrplugin/lib/susy/Manifest b/SASS.lrplugin/lib/susy/Manifest index 6b613094..1cf1ecde 100644 --- a/SASS.lrplugin/lib/susy/Manifest +++ b/SASS.lrplugin/lib/susy/Manifest @@ -1,7 +1,7 @@ CHANGELOG.mkdn LICENSE.txt Manifest -README.mkdn +README.md Rakefile VERSION lib/susy.rb @@ -17,3 +17,14 @@ susy.gemspec templates/project/_base.scss templates/project/manifest.rb templates/project/screen.scss +test/config.rb +test/css/background.css +test/css/grid.css +test/css/margin.css +test/css/media.css +test/css/padding.css +test/scss/background.scss +test/scss/grid.scss +test/scss/margin.scss +test/scss/media.scss +test/scss/padding.scss diff --git a/SASS.lrplugin/lib/susy/Rakefile b/SASS.lrplugin/lib/susy/Rakefile index 55b8d4f2..d4c360f0 100644 --- a/SASS.lrplugin/lib/susy/Rakefile +++ b/SASS.lrplugin/lib/susy/Rakefile @@ -10,7 +10,7 @@ begin p.url = "http://susy.oddbird.net/" p.author = "Eric Meyer" p.email = "eric@oddbird.net" - p.dependencies = ["compass >=0.12.2", "sass >=3.2.0.alpha.247"] + p.dependencies = ["compass >=0.12.2", "sass >=3.2.0"] end rescue LoadError => boom diff --git a/SASS.lrplugin/lib/susy/VERSION b/SASS.lrplugin/lib/susy/VERSION index 38ea0e26..d3827e75 100644 --- a/SASS.lrplugin/lib/susy/VERSION +++ b/SASS.lrplugin/lib/susy/VERSION @@ -1 +1 @@ -1.0.rc.2 +1.0 diff --git a/SASS.lrplugin/lib/susy/sass/susy/_functions.scss b/SASS.lrplugin/lib/susy/sass/susy/_functions.scss index 067c1e6b..f8e8044c 100644 --- a/SASS.lrplugin/lib/susy/sass/susy/_functions.scss +++ b/SASS.lrplugin/lib/susy/sass/susy/_functions.scss @@ -13,12 +13,16 @@ $browser-default-font-size-pt : 12pt; // Grid Functions // Returns the full width of a grid based on your grid settings. -// +// // $columns : The number of columns to get width for. @function columns-width( $columns : $total-columns ) { - @return ($columns * $column-width) + (ceil($columns - 1) * $gutter-width); + @if round($columns) != $columns { + @warn "Susy works best with integer column-spans. + For partial-columns, you may need to finesse the math by hand using functions directly."; + } + @return ($columns * $column-width) + (if($columns >= 1, ceil($columns - 1), 0) * $gutter-width); } // Return the full outer width of a Container element. @@ -36,39 +40,51 @@ $browser-default-font-size-pt : 12pt; @function column( $context : $total-columns ) { - @return percentage($column-width / columns-width($context)); + @return relative-width($column-width, $context); + } // Return the percentage width of multiple 'columns' in a given 'context'. -// +// // $columns : The number of columns to get relative width for. // $context : The grid context in columns, if nested. @function columns( $columns, $context : $total-columns ) { - @return percentage(columns-width($columns) / columns-width($context)); + @return relative-width(columns-width($columns), $context); } // Return the percentage width of a single gutter in a given 'context'. -// +// // $context : The grid context in columns, if nested. @function gutter( $context : $total-columns ) { - @return percentage($gutter-width / columns-width($context)); + @return relative-width($gutter-width, $context); +} + +// Return the percentage width of a given value in a given 'context'. +// +// $width : Any given width value. +// $context : The grid context in columns, if nested. +@function relative-width( + $width, + $context : $total-columns +) { + @return percentage($width / columns-width($context)); } // Return the total space occupied by multiple columns and associated gutters. // Useful for adding padding or margins (preifx, suffix, push, pull, etc.) -// +// // $columns : The number of columns to get relative space for. // $context : The grid context in columns, if nested. @function space( $columns, $context : $total-columns ) { - @return columns($columns, $context) + gutter($context); + @return columns($columns, $context) + if($columns >= 1, gutter($context), 0); } // Accept a list including column-count and (optional) position. @@ -92,7 +108,7 @@ $browser-default-font-size-pt : 12pt; } @else { @warn '"#{$var}" is not a valid part of "$columns: #{$columns}" in the columns() mixin.'; } - } + } } @if $request == 'columns' { @@ -106,6 +122,22 @@ $browser-default-font-size-pt : 12pt; } } +// Accept nth-selector variables, and format them as a valid CSS3 selector. +// +// $n : [first | only | last | ] +// $selector : [child | last-child | of-type | last-of-type ] +@function format-nth( + $n : last, + $selector : child +) { + @if ($n == 'last') or ($n =='first') or ($n =='only') { + $selector: '#{$n}-#{$selector}'; + } @else { + $selector: 'nth-#{$selector}(#{$n})'; + } + @return $selector; +} + // --------------------------------------------------------------------------- // Media Functions @@ -260,8 +292,8 @@ $browser-default-font-size-pt : 12pt; $layout-cols : nth($media-layout,2); $max : nth($media-layout,3); - @if $min or $max { - @return false; + @if $min or $max { + @return false; } @else { @return if($layout-cols == $total-columns,true,false); } diff --git a/SASS.lrplugin/lib/susy/sass/susy/_grid.scss b/SASS.lrplugin/lib/susy/sass/susy/_grid.scss index 6897387a..56b8b30e 100644 --- a/SASS.lrplugin/lib/susy/sass/susy/_grid.scss +++ b/SASS.lrplugin/lib/susy/sass/susy/_grid.scss @@ -2,6 +2,17 @@ // Imports @import "compass/utilities/general/clearfix"; +@import "compass/css3/box-sizing"; + +// --------------------------------------------------------------------------- +// Border-Box Sizing + +// Apply the border-box sizing model to all elements +// and adjust the grid math appropriately. +@mixin border-box-sizing { + $border-box-sizing: true; + * { @include box-sizing(border-box); } +} // --------------------------------------------------------------------------- // Container @@ -9,6 +20,13 @@ // Set the width of a container @mixin set-container-width(){ $width: if($container-width, $container-width, columns-width()); + @if $border-box-sizing { + @if comparable($width, $grid-padding) { + $width: $width + ($grid-padding*2); + } @else { + @warn "$grid-padding must be set in units comparable to column and gutter widths, in order for $border-box-sizing to work properly."; + } + } @if $container-style == 'static' { width: $width; @@ -77,23 +95,46 @@ // $context : [optional] The context (columns spanned by parent). // : Context is required on any nested elements. // : Context MUST NOT be declared on a root element. +// $padding : [optional] Padding applied to the inside of individual grid columns. +// : Padding is only output if one or two values are specified (e.g. 1em or 10px 20px) +// : Padding values are applied only on the horizontal axis in from-to order // $from : The start direction of your layout (e.g. 'left' for ltr languages) + @mixin span-columns( $columns, - $context : $total-columns, - $from : $from-direction + $context : $total-columns, + $padding : false, + $from : $from-direction ) { $to : opposite-position($from); $pos : split-columns-value($columns,position); $cols : split-columns-value($columns,columns); - - width: columns($cols, $context); + $pad-from : relative-width(0 * $gutter-width, $context); + $pad-to : relative-width(0 * $gutter-width, $context); + + @if $padding != false { + $pad-from : nth($padding, 1); + + @if length($padding) > 1 { + $pad-to: nth($padding, 2); + } @else { + $pad-to: $pad-from; + } + + $pad-from : relative-width($pad-from, $context); + $pad-to : relative-width($pad-to, $context); + + padding-#{$from}: $pad-from; + padding-#{$to}: $pad-to; + } + + width: columns($cols, $context) - if($border-box-sizing, 0, $pad-to + $pad-from); @if ($pos == 'omega') { @include omega($from); - } @else { + } @else { float: $from; - margin-#{$to}: gutter($context); + margin-#{$to}: gutter($context); @if $legacy-support-for-ie6 { display: inline; } @@ -109,7 +150,7 @@ ) { $to : opposite-position($from); $hack : opposite-position($omega-float); - + float: $omega-float; margin-#{$to}: 0; @@ -119,8 +160,21 @@ } } +// Shortcut to apply omega to a specific subset of elements. +// +// $n : [first | only | last | ] +// $selector : [child | last-child | of-type | last-of-type ] +// $from : The start-direction for your document. +@mixin nth-omega( + $n : last, + $selector : child, + $from : $from-direction +) { + &:#{format-nth($n,$selector)} { @include omega($from); } +} + // --------------------------------------------------------------------------- -// Reset Columns +// Resets // Reset a '+columns' grid element to default block behavior // @@ -134,9 +188,75 @@ float: none; width: auto; margin-#{$to}: auto; - + @if $legacy-support-for-ie6 or $legacy-support-for-ie7 { #margin-#{$hack}: auto; @if $legacy-support-for-ie6 { display: block; } } } + +// Apply to elements previously set as omega. +// This will return floats and margins back to non-omega settigns. +// +// $context : [optional] The context (columns spanned by parent). +// $from : The start-direction for your document. +@mixin remove-omega( + $context : $total-columns, + $from : $from-direction +) { + $to : opposite-position($from); + $hack : opposite-position($omega-float); + + float: $from; + margin-#{$to}: gutter($context); + + @if $legacy-support-for-ie6 or $legacy-support-for-ie7 { + #margin-#{$hack}: 0; + } +} + +// Shortcut to apply remove-omega to a specific subset of elements. +// +// $n : [first | only | last | ] +// $selector : [child | last-child | of-type | last-of-type ] +// $context : [optional] The context (columns spanned by parent). +// $from : The start-direction for your document. +@mixin remove-nth-omega( + $n : last, + $selector : child, + $context : $total-columns, + $from : $from-direction +) { + &:#{format-nth($n,$selector)} { @include remove-omega($context,$from); } +} + +// --------------------------------------------------------------------------- +// Change Settings + +@mixin with-grid-settings( + $columns: $total-columns, + $width: $column-width, + $gutter: $gutter-width, + $padding: $grid-padding +) { + // keep the defaults around + $default-columns: $total-columns; + $default-width: $column-width; + $default-gutter: $gutter-width; + $default-padding: $grid-padding; + + // use the new settings + $total-columns: $columns; + $column-width: $width; + $gutter-width: $gutter; + $grid-padding: $padding; + + // apply to contents + @content; + + // re-instate the defaults + $total-columns: $default-columns; + $column-width: $default-width; + $gutter-width: $default-gutter; + $grid-padding: $default-padding; +} diff --git a/SASS.lrplugin/lib/susy/sass/susy/_media.scss b/SASS.lrplugin/lib/susy/sass/susy/_media.scss index 2924d864..1c93e7e7 100644 --- a/SASS.lrplugin/lib/susy/sass/susy/_media.scss +++ b/SASS.lrplugin/lib/susy/sass/susy/_media.scss @@ -1,3 +1,14 @@ +// --------------------------------------------------------------------------- +// Imports + +// Change the legacy-support-for-ie* settings in specific contexts. +// Here temporarily, until it lands in compass. +@mixin set-legacy-ie-support($ie6: false, $ie7: false, $ie8: false) { + $legacy-support-for-ie6: $ie6; + $legacy-support-for-ie7: $ie7; + $legacy-support-for-ie8: $ie8; +} + // --------------------------------------------------------------------------- // Media Mixins @@ -36,6 +47,10 @@ $max : nth($media-layout,3); $ie : nth($media-layout,4); + @if (not $breakpoint-media-output) and (not $breakpoint-ie-output) and (not $breakpoint-raw-output) { + @warn "Either $breakpoint-media-output, $breakpoint-ie-output, or $breakpoint-raw-output must be true for at-breakpoint to work."; + } + // We need to have either a min-width breakpoint or a layout in order to proceed. @if $min or $layout or $max { @@ -48,31 +63,42 @@ @if $layout { // Set our new layout context. @include layout($layout) { - @if $min and $max { - // Both $min and $max - @media (min-width: $min) and (max-width: $max) { - @content; - } - } @else { - @if (not $min) and (not $max) { - // Neither $min nor $max: - // We can create a breakpoint based on the number of columns in the layout. - $min: fix-ems(container-outer-width()); - } - @if $min { - // Min only: - @media (min-width: $min) { + @if $breakpoint-media-output { + // dont need to support old IE inside media-queries + $initial-legacy-support-for-ie6: $legacy-support-for-ie6; + $initial-legacy-support-for-ie7: $legacy-support-for-ie7; + $initial-legacy-support-for-ie8: $legacy-support-for-ie8; + @include set-legacy-ie-support(false, false, false); + + @if $min and $max { + // Both $min and $max + @media (min-width: $min) and (max-width: $max) { @content; } } @else { - // Max only: - @media (max-width: $max) { - @content; - } + @if (not $min) and (not $max) { + // Neither $min nor $max: + // We can create a breakpoint based on the number of columns in the layout. + $min: fix-ems(container-outer-width()); + } + @if $min { + // Min only: + @media (min-width: $min) { + @content; + } + } @else { + // Max only: + @media (max-width: $max) { + @content; + } + } } + + // return IE support to its initial setting + @include set-legacy-ie-support($initial-legacy-support-for-ie6, $initial-legacy-support-for-ie7, $initial-legacy-support-for-ie8); } // Set an IE fallback - @if $ie { + @if $ie and $breakpoint-ie-output { @if (type-of($ie) == 'bool') { $ie: 'lt-ie9'; } @@ -80,6 +106,10 @@ @content; } } + + @if $breakpoint-raw-output { + @content; + } } } @else { @warn "Something went horribly wrong here. Try adjusting your variables."; diff --git a/SASS.lrplugin/lib/susy/sass/susy/_settings.scss b/SASS.lrplugin/lib/susy/sass/susy/_settings.scss index 140c1908..a7a2cea7 100644 --- a/SASS.lrplugin/lib/susy/sass/susy/_settings.scss +++ b/SASS.lrplugin/lib/susy/sass/susy/_settings.scss @@ -9,7 +9,7 @@ $total-columns : 12 !default; $column-width : 4em !default; $gutter-width : 1em !default; -// Add padding to your grid. +// Padding on the left and right of a Grid Container. $grid-padding : $gutter-width !default; // --------------------------------------------------------------------------- @@ -28,9 +28,29 @@ $omega-float : opposite-position($from-direction) !default; $container-width : false !default; // Container Style: -// 'magic' - Static (fixed or elastic) when there's enough space, +// 'magic' - Static (fixed or elastic) when there's enough space, // fluid when there isn't. This is the SUSY MAGIC SAUCE(TM). // 'static' - Forces the grid container to remain static at all times. // 'fluid' - Forces the grid to remain fluid at all times. // (this will overrule any static $container-width settings) -$container-style : mixed !default; +$container-style : magic !default; + +// Border-Box Sizing +// Adjust the grid math appropriately for box-sizing: border-box; +// Warning: This does not actually apply the new box model! +// In most cases you can ignore this setting, +// and simply apply the border-box-sizing mixin. +$border-box-sizing : false !default; + +// --------------------------------------------------------------------------- +// IE Settings + +// When you are using a seperate IE stylesheet, +// you can use these settings to control the output of at-breakpoint. +// By default, at-breakpoint will output media-queries as well as +// any defined ie-fallback classes. +$breakpoint-media-output : true; +$breakpoint-ie-output : true; + +// Danger Zone! Only set as 'true' in IE-specific style sheets. +$breakpoint-raw-output : false; diff --git a/SASS.lrplugin/lib/susy/susy.gemspec b/SASS.lrplugin/lib/susy/susy.gemspec index cf5b1e11..185862dc 100644 --- a/SASS.lrplugin/lib/susy/susy.gemspec +++ b/SASS.lrplugin/lib/susy/susy.gemspec @@ -1,35 +1,36 @@ # -*- encoding: utf-8 -*- Gem::Specification.new do |s| - s.name = "susy" - s.version = "1.0.rc.2" + s.name = %q{susy} + s.version = "1.0" s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version= s.authors = ["Eric Meyer"] - s.date = "2012-06-25" - s.description = "Susy grids are fluid on the inside, ready to respond at any moment, but contained in the candy shell of your choice, so they respond how and when and where you want them to. We don't design your site or dictate your markup, we just do the math and get out of your way." - s.email = "eric@oddbird.net" - s.extra_rdoc_files = ["CHANGELOG.mkdn", "LICENSE.txt", "README.mkdn", "lib/susy.rb"] - s.files = ["CHANGELOG.mkdn", "LICENSE.txt", "Manifest", "README.mkdn", "Rakefile", "VERSION", "lib/susy.rb", "sass/_susy.scss", "sass/susy/_background.scss", "sass/susy/_functions.scss", "sass/susy/_grid.scss", "sass/susy/_margin.scss", "sass/susy/_media.scss", "sass/susy/_padding.scss", "sass/susy/_settings.scss", "susy.gemspec", "templates/project/_base.scss", "templates/project/manifest.rb", "templates/project/screen.scss"] - s.homepage = "http://susy.oddbird.net/" - s.rdoc_options = ["--line-numbers", "--inline-source", "--title", "Susy", "--main", "README.mkdn"] + s.date = %q{2012-08-14} + s.description = %q{Susy grids are fluid on the inside, ready to respond at any moment, but contained in the candy shell of your choice, so they respond how and when and where you want them to. We don't design your site or dictate your markup, we just do the math and get out of your way.} + s.email = %q{eric@oddbird.net} + s.extra_rdoc_files = ["CHANGELOG.mkdn", "LICENSE.txt", "README.md", "lib/susy.rb"] + s.files = ["CHANGELOG.mkdn", "LICENSE.txt", "Manifest", "README.md", "Rakefile", "VERSION", "lib/susy.rb", "sass/_susy.scss", "sass/susy/_background.scss", "sass/susy/_functions.scss", "sass/susy/_grid.scss", "sass/susy/_margin.scss", "sass/susy/_media.scss", "sass/susy/_padding.scss", "sass/susy/_settings.scss", "susy.gemspec", "templates/project/_base.scss", "templates/project/manifest.rb", "templates/project/screen.scss", "test/config.rb", "test/css/background.css", "test/css/grid.css", "test/css/margin.css", "test/css/media.css", "test/css/padding.css", "test/scss/background.scss", "test/scss/grid.scss", "test/scss/margin.scss", "test/scss/media.scss", "test/scss/padding.scss"] + s.homepage = %q{http://susy.oddbird.net/} + s.rdoc_options = ["--line-numbers", "--inline-source", "--title", "Susy", "--main", "README.md"] s.require_paths = ["lib"] - s.rubyforge_project = "susy" - s.rubygems_version = "1.8.24" - s.summary = "Responsive grids for Compass." + s.rubyforge_project = %q{susy} + s.rubygems_version = %q{1.3.6} + s.summary = %q{Responsive grids for Compass.} if s.respond_to? :specification_version then + current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION s.specification_version = 3 - if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then + if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then s.add_runtime_dependency(%q, [">= 0.12.2"]) - s.add_runtime_dependency(%q, [">= 3.2.0.alpha.247"]) + s.add_runtime_dependency(%q, [">= 3.2.0"]) else s.add_dependency(%q, [">= 0.12.2"]) - s.add_dependency(%q, [">= 3.2.0.alpha.247"]) + s.add_dependency(%q, [">= 3.2.0"]) end else s.add_dependency(%q, [">= 0.12.2"]) - s.add_dependency(%q, [">= 3.2.0.alpha.247"]) + s.add_dependency(%q, [">= 3.2.0"]) end end From 3985fd1e354dd3b9f88a88ce24757ffb92719209 Mon Sep 17 00:00:00 2001 From: Ben Lancaster Date: Thu, 6 Sep 2012 10:04:59 +0100 Subject: [PATCH 2/2] Bumping Susy to 1.0 --- SASS.lrplugin/lib/susy/Manifest | 11 --- SASS.lrplugin/lib/susy/README.md | 121 +++++++++++++++++++++++++++++ SASS.lrplugin/lib/susy/README.mkdn | 37 --------- SASS.lrplugin/versions.json | 2 +- 4 files changed, 122 insertions(+), 49 deletions(-) create mode 100644 SASS.lrplugin/lib/susy/README.md delete mode 100644 SASS.lrplugin/lib/susy/README.mkdn diff --git a/SASS.lrplugin/lib/susy/Manifest b/SASS.lrplugin/lib/susy/Manifest index 1cf1ecde..c5438ef4 100644 --- a/SASS.lrplugin/lib/susy/Manifest +++ b/SASS.lrplugin/lib/susy/Manifest @@ -17,14 +17,3 @@ susy.gemspec templates/project/_base.scss templates/project/manifest.rb templates/project/screen.scss -test/config.rb -test/css/background.css -test/css/grid.css -test/css/margin.css -test/css/media.css -test/css/padding.css -test/scss/background.scss -test/scss/grid.scss -test/scss/margin.scss -test/scss/media.scss -test/scss/padding.scss diff --git a/SASS.lrplugin/lib/susy/README.md b/SASS.lrplugin/lib/susy/README.md new file mode 100644 index 00000000..9b1eab09 --- /dev/null +++ b/SASS.lrplugin/lib/susy/README.md @@ -0,0 +1,121 @@ +# Susy [a Compass plugin] + +Susy is a semantic CSS grid system with a responsive twist. + +The web is a responsive place, +from your lithe & lively development process +to your end user's super-tablet-multi-magic-lap-phone. +You need grids that are powerful, but custom; +reliable, but responsive. + +Susy grids are fluid on the inside, +ready to respond at any moment, +but contained in the candy shell of your choice, +so they respond how and when and where you want them to. + +This isn't another one-size-fits-all grid framework +that will make your sites look identical +and litter your markup with meaningless "col2of5" jargon. +We don't design your site or write your markup, +we just do the math and get out of your way. + +## Resources +- [Website](http://susy.oddbird.net) +- [Changelog](https://github.com/ericam/susy/blob/master/CHANGELOG.mkdn) +- [Tutorial](http://susy.oddbird.net/guides/getting-started/) +- [Reference](http://susy.oddbird.net/guides/reference/) +- [Sites using Susy](http://susy.oddbird.net/sites-using-susy/) +- [Twitter @CompassSusy](http://twitter.com/compasssusy/) + +## Contributing + +We love contributions, +both as ideas and pull requests. +The core of Susy is all in the `/sass/` directory. + +Once you make changes, +you can test them by building the gem +and installing it somewhere to test. +We also have unit tests that you can run. + +### Building the gem + +You'll need Rake and Echoe installed: + +```bash +# command line +gem install rake +gem install echoe +``` + +It might be helpful to bump the version number in `VERSION`, +but any changes you make there +should not be committed. + +Then you can build: + +```bash +# command line +rake build +``` + +Your new gem will appear in +a folder called `pkg`. +You can install it for testing +directly from there. + +```bash +# command line +gem install +``` + +### Building the docs + +If you are adding features +or changing how a current feature works, +your changes should be documented. +Or you might be helping us maintain the docs. +In either case, +you'll need to run the docs dev server +in order to see your changes. + +In the `docs` folder: + +```bash +# command line +gem install bundler +bundle install +``` + +The site is built with +[middleman](http://middlemanapp.com/). +To run the development server: + +```bash +# command line +middleman +``` + +The server should now be running at `localhost:4567`. + +Make any changes you need +under the `source` directory, +then commit your changes +and submit a pull request when you are done! + +### Tests + +The tests we have are very basic at this point. +Simply go into the `test` directory +(with the latest Sass and Compass gems installed) +and run `compass compile --force`. + +There should be no changes. +If there are changes, +go back and find what caused the change. +If the change was intentional, +simply commit the changed test files. +If it was not intentional, +go back and find what caused the problem. + +Use `git diff` to see the changes. diff --git a/SASS.lrplugin/lib/susy/README.mkdn b/SASS.lrplugin/lib/susy/README.mkdn deleted file mode 100644 index fce81d87..00000000 --- a/SASS.lrplugin/lib/susy/README.mkdn +++ /dev/null @@ -1,37 +0,0 @@ -# Susy [a Compass plugin] - -Susy is a semantic CSS grid system with a responsive twist. - -The web is a responsive place, -from your lithe & lively development process -to your end user's super-tablet-multi-magic-lap-phone. -You need grids that are powerful, but custom; -reliable, but responsive. - -Susy grids are fluid on the inside, -ready to respond at any moment, -but contained in the candy shell of your choice, -so they respond how and when and where you want them to. - -This isn't another one-size-fits-all grid framework -that will make your sites look identical -and litter your markup with meaningless "col2of5" jargon. -We don't design your site or write your markup, -we just do the math and get out of your way. - -## Resources -- [Website](http://susy.oddbird.net) -- [Changelog](https://github.com/ericam/susy/blob/master/CHANGELOG.mkdn) -- [Tutorial](http://susy.oddbird.net/guides/getting-started/) -- [Reference](http://susy.oddbird.net/guides/reference/) -- [Sites using Susy](http://susy.oddbird.net/sites-using-susy/) -- [Twitter @CompassSusy](http://twitter.com/compasssusy/) - -## Why is 1.0 a release candidate? - -Susy 1.0 is stable and tested, all the features are in, -and we're ready to launch. -But our 1.0 depends on unreleased Compass and Sass features. -We think those features are stable as well, -and we'll do what it takes to stay on top of any changes they make, -but we can't officially land until they do. \ No newline at end of file diff --git a/SASS.lrplugin/versions.json b/SASS.lrplugin/versions.json index 665876de..4f05fe68 100644 --- a/SASS.lrplugin/versions.json +++ b/SASS.lrplugin/versions.json @@ -20,7 +20,7 @@ "compass": "0.13.alpha.0", "html5-boilerplate": "2.1.0", "compass-slickmap": "0.5.1.1", - "susy": "1.0.rc.2", + "susy": "1.0", "fancy-buttons": "1.1.0.alpha.1", "compass-squaregrid-plugin": "0.0.3", "compass-less-plugin": "1.0.beta.0",