Upgrading to the Compass Antares Release (v0.11)
Many mixins and certain uses of mixins have been deprecated, but your
existing stylesheets should still work out of the box with one exception:
users who are using the css3/transform module should update their imports
to import css/transform-legacy when they upgrade. They should then upgrade
to the new css/transform module at their convenience.
You should read about what changed, update your stylesheets accordingly and then update your imports to the new version.
Box Shadow
You may get a deprecation warning using the box-shadow mixin.
You can resolve this in one of the following ways:
- Change your use of the
box-shadowand instead usesingle-box-shadow. This mixin has the same behavior and arguments as the oldbox-shadowmixin. - Keep using
box-shadow, change how you pass the arguments. The newbox-shadowtakes up to 10 comma-delimited shadows. Each shadow is how the values should appear in the CSS (space separated).
Text Shadow
You may get a deprecation warning using the text-shadow mixin.
You can resolve this in one of the following ways:
- Change your use of the
text-shadowand instead usesingle-text-shadow. This mixin has the same behavior and arguments as the oldtext-shadowmixin. - Keep using
text-shadow, change how you pass the arguments. The newtext-shadowtakes up to 10 comma-delimited shadows. Each shadow is how the values should appear in the CSS (space separated).
CSS Transforms
The transform module was largely re-written to support 3D transforms. If you are using it, it is suggested that you read the new module’s documentation and adjust your code appropriately. Many mixin names and constants have changed. For your convenience, the old CSS transform module can still be imported, but it is deprecated and will be removed in the next release.
Gradients
The Compass gradient support now more closely emulates the CSS3 specification of how gradients
are represented and passed around. The linear-gradient and radial-gradient mixins
have been deprecated and instead, you should use the linear-gradient() and radial-gradient()
functions in conjunction with mixins for the properties that support gradients like
background / background-image, border-image, list-style / list-style-image,
and content.
After upgrading, you’ll receive deprecation warnings for your usage of the old gradient mixins and a suggested replacement value for each. If you’d rather keep the old mixins in your project for convenience, just copy the following to your project after changing your imports:
@mixin radial-gradient($color-stops, $center-position: center center, $image: false) {
@include background-image($image, radial-gradient($center-position, $color-stops));
}
@mixin linear-gradient($color-stops, $start: top, $image: false) {
@include background-image($image, linear-gradient($start, $color-stops));
}
Or for sass files:
=radial-gradient($color-stops, $center-position: center center, $image: false)
+background-image($image, radial-gradient($center-position, $color-stops))
=linear-gradient($color-stops, $start: top, $image: false)
+background-image($image, linear-gradient($start, $color-stops))
Typography Module
With the addition of vertical-rhythms to the compass core, we have created a new typography module, and moved several items that were formerly listed as “utilities” into it. The moved modules are “links”, “lists” and “text”. These will all remain part of the basic compass include, but if you were including them individually in your stylesheets, you will need to adjust the include paths as follows:
- “compass/utilities/links” becomes “compass/typography/links”
- “compass/utilities/lists” becomes “compass/typography/lists”
- “compass/utilities/text” becomes “compass/typography/text”