Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixes issue #82 #85

Closed
wants to merge 1 commit into from
Closed

fixes issue #82 #85

wants to merge 1 commit into from

Conversation

zhenglong
Copy link
Contributor

FF16 starts to support the non-prefix version of transformation, so $(elem).css("transform") will return a matrix, I change the css hook for transform and let it override the default behavior.
And It works for me.
Seems that IE10 also has the same problem, but no chance to test against it.

index 3ebae61..830aeb2 100644
--- a/jquery.transit.js
+++ b/jquery.transit.js
@@ -106,7 +106,7 @@
$.cssHooks.transform = {
// The getter returns a Transform object.
get: function(elem) {

  •  return $(elem).data('transform');
    
  •  return $(elem).data('transform') || new Transform();
    

    },

    // The setter accepts a Transform object or a string.
    @@ -603,12 +603,12 @@

    $.cssHooks[prop] = {
    get: function(elem) {

  •    var t = $(elem).css('transform') || new Transform();
    
  •    var t = $(elem).css('transform');
     return t.get(prop);
    

    },

    set: function(elem, value) {

  •    var t = $(elem).css('transform') || new Transform();
    
  •    var t = $(elem).css('transform');
     t.setFromString(prop, value);
    
     $(elem).css({ transform: t });
    

@Grsmto
Copy link

Grsmto commented Oct 15, 2012

Confirmed ! It now works great on ff16. Thanks.
Tested on Jquery < 1.8.

@adamcrown
Copy link

+1
Fixed my Firefox 16 issue as well.

@rstacruz
Copy link
Owner

Hm, I like this actually.

@rstacruz rstacruz closed this Dec 13, 2012
rstacruz added a commit that referenced this pull request Dec 13, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants