Skip to content

Sprite Offset-y doesn't respond to percentage #1012

Open
@JaredSartin

Description

@JaredSartin

when you setup a sprite with +spritedir-sprite(icon-large, $offset-x: 100%, %offset-y: 50%) - the resulting sprite gets a background position of: 100% 50px.

Any number given to $offset-y is converted to px. This is all fine and dandy for vertical sprites, but horizontal ones need to do the 100% to the y offset.

Line 158 in compass / lib / compass / sass_extensions / functions / sprites.rb checks the x offset for percentage and uses it if there is, but nothing is done for the y offset - it just parses out the number and puts the px on there.

Fixes?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions