         x = _x unless x?
         y = _y unless y?
 
-        bg_position = "#{ x * 100 }% #{ y * 100}%"
+        bg_position = "#{ (x * 100).toFixed(0) }% #{ (y * 100).toFixed(0) }%"
 
         if image?.content?
             src_2560        = image.content['2560']?.url or undefined

React = require 'react'

{ Classes } = require 'shiny'

module.exports = React.createClass
    displayName: 'CoverImage'
    propTypes:
        align: React.PropTypes.oneOf(['center','top','right','bottom','left'])
    getDefaultProps: -> {
        align: 'center'
        size: null
        noscript: true
        intrinsic: true
    }
    render: ->
        cx = new Classes('CoverImage', @props.className)


        cx.add('intrinsic', @props.intrinsic)

        props =
            ref                     : 'el'
            className               : cx
            href                    : @props.link
            'data-is_empty'         : not main_image_url

        style =
            backgroundPosition: bg_position

        if @state.__live and image
            _size = selectImageSize(
                @state.width, @state.height, window?.devicePixelAspectRatio or 1
            )
            style.backgroundImage   = "url('#{ image.content[_size]?.url }')"
        else
            props[k] = v for k,v of (
                'data-src_640'          : src_640
                'data-src_1280'         : src_1280
                'data-src_2560'         : src_2560
                'data-aspect_ratio'     : aspect_ratio?.toFixed(3)
            )
        
        contents = <div className='_Image' style=style>
            { @props.children }
        </div>

        if @props.link
            cx.set('link')
