Skip to content

Commit 293c0ef

Browse files
committed
enabled media query wrapper #29
1 parent 57f8e2a commit 293c0ef

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

jquery.keyframes.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,10 @@
5555

5656
css = PrefixFree.prefixCSS(css + "}");
5757

58+
if(frameData.media){
59+
css = "@media " + frameData.media + "{" + css + "}";
60+
}
61+
5862
var $frameStyle = $("style#" + frameData.name);
5963

6064
if ($frameStyle.length > 0) {
@@ -152,8 +156,8 @@
152156
}
153157
};
154158

155-
this.each(function(index, elem) {
156-
var $el = $(elem).addClass("boostKeyframe").css(vendorPrefix + animationPlayState, playStateRunning).css(animationkey, animationcss).data("keyframeOptions", frameOptions);
159+
this.each(function() {
160+
var $el = $(this).addClass("boostKeyframe").css(vendorPrefix + animationPlayState, playStateRunning).css(animationkey, animationcss).data("keyframeOptions", frameOptions);
157161

158162
if (callback) {
159163
_prefixEvent($el, 'AnimationIteration', callback);

0 commit comments

Comments
 (0)