Rename the sprite-position mixin in compass/utilities/sprites/base to

sprite-background-position in order to avoid a naming conflict with the
older sprite-image module.
This commit is contained in:
Chris Eppstein 2011-01-17 11:54:58 -08:00
parent e384dee5da
commit bf52c76470
3 changed files with 6 additions and 3 deletions

View File

@ -20,6 +20,9 @@ The Documentation for the [latest preview release](http://beta.compass-style.org
subcommand. When provided, the default variables for overriding the sprite subcommand. When provided, the default variables for overriding the sprite
behavior are not created. Instead, you would change the call to behavior are not created. Instead, you would change the call to
`sprite-map()` to customize your sprite map. `sprite-map()` to customize your sprite map.
* Rename the `sprite-position` mixin in the new `sprite/base` module to
`sprite-background-position` in order avoid a naming conflict with the old
sprite module.
0.11.beta.0 (01/09/2011) 0.11.beta.0 (01/09/2011)
------------------------ ------------------------

View File

@ -8,7 +8,7 @@
// Set the background position of the given sprite `$map` to display the // Set the background position of the given sprite `$map` to display the
// sprite of the given `$sprite` name. You can move the image relative to its // sprite of the given `$sprite` name. You can move the image relative to its
// natural position by passing `$offset-x` and `$offset-y`. // natural position by passing `$offset-x` and `$offset-y`.
@mixin sprite-position($map, $sprite, $offset-x: 0, $offset-y: 0) { @mixin sprite-background-position($map, $sprite, $offset-x: 0, $offset-y: 0) {
background-position: sprite-position($map, $sprite, $offset-x, $offset-y); background-position: sprite-position($map, $sprite, $offset-x, $offset-y);
} }
@ -18,7 +18,7 @@
// //
// background: $map no-repeat; // background: $map no-repeat;
@mixin sprite($map, $sprite, $dimensions: false, $offset-x: 0, $offset-y: 0) { @mixin sprite($map, $sprite, $dimensions: false, $offset-x: 0, $offset-y: 0) {
@include sprite-position($map, $sprite, $offset-x, $offset-y); @include sprite-background-position($map, $sprite, $offset-x, $offset-y);
@if $dimensions { @if $dimensions {
@include sprite-dimensions($map, $sprite); @include sprite-dimensions($map, $sprite);
} }

View File

@ -63,7 +63,7 @@ $#{name}-repeat: no-repeat !default;
// Move the background position to display the sprite. // Move the background position to display the sprite.
@mixin #{name}-sprite-position($name, $offset-x: 0, $offset-y: 0) { @mixin #{name}-sprite-position($name, $offset-x: 0, $offset-y: 0) {
@include sprite-position($#{name}-sprites, $name, $offset-x, $offset-y) @include sprite-background-position($#{name}-sprites, $name, $offset-x, $offset-y)
} }
// Extends the sprite base class and set the background position for the desired sprite. // Extends the sprite base class and set the background position for the desired sprite.