Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

normalize transitionTimingFunction values #11

Open
burin opened this Issue · 3 comments

2 participants

@burin
Collaborator

When setting transitionTimingFunction as "linear":

Safari 5.0.1 Mac returns "cubic-bezier(0, 0, 1, 1)"

Chrome 8.0.552.23 dev Mac returns "linear"

Tests were written to expect "cubic-bezier(0, 0, 1, 1)", so they fail in Chrome

@burin
Collaborator

Firefox 4.0 beta Mac returns "border 1s cubic-bezier(0.000000, 0.000000, 1.000000, 1.000000)"

@burin
Collaborator

is it reasonable to expect "linear" back if you set it as "linear"?

@pdokas
Collaborator

I suggest normalizing on the cubic-bezier() functions. All the named shortcuts come with official definitions in the spec so we can easily map name --> function params. From there if we normalize the params by ramming them through Number() we will probably wind up with predictable values.

The one possible danger I see in doing so is possible floating point oddness. I'd be surprised frankly to see it come up, but it's something to watch out for.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.