Reputation: 12431
I have been playing around with these CSS3 properties and I've been able to do some really cool things with them. I got the initial example from this website. I was wondering if any of these properties can be altered with the .css function available in jQuery. I can't seem to find any reference to this on Google. Here's what I have set to a div element on my page.
-moz-box-shadow:0 20px 40px #888;
-webkit-box-shadow:0 20px 40px #888;
-webkit-transform: translateZ(30px) rotateY(30deg);
-webkit-transition-property: transform, box-shadow, margin;
-webkit-transition-duration: 0.5s;
I know from my experience with the css function that it doesn't support hyphens in the property name such as "margin-left". So if there's currently no support, is jQuery going to add in support anytime in the future?
Thanks!
Upvotes: 0
Views: 1985
Reputation: 72405
jQuery supports hyphens, you just have to quote your css propierties, ex:
$(".whatever").css("margin-left", "-10px");
Here is a demo with css transforms:
Upvotes: 2