Skip to content
This repository has been archived by the owner. It is now read-only.

Bubble image not positioned correctly on rotation #18

Open
zmandel opened this issue Jun 25, 2014 · 0 comments
Open

Bubble image not positioned correctly on rotation #18

zmandel opened this issue Jun 25, 2014 · 0 comments

Comments

@zmandel
Copy link

@zmandel zmandel commented Jun 25, 2014

Hi, under certain situations, the rotation is not centered correctly, might be because Im using the library from a chrome extension.
My fix was to add -webkit-transform-origin on cssRotate:

cssRotate: function () {
this.bubble.css({
'-moz-transform': 'rotate(' + this.rotateDeg + 'deg)',
'-webkit-transform': 'rotate(' + this.rotateDeg + 'deg)',
'-o-transform': 'rotate(' + this.rotateDeg + 'deg)',
'transform': 'rotate(' + this.rotateDeg + 'deg)',
'-webkit-transform-origin-x': Math.floor(this.css.width/2)+ 'px',
'-webkit-transform-origin-y': Math.floor(this.css.height / 2) + 'px'
});
}

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant