@-webkit-keyframes swag{
0% {-webkit-transform:translateY(0px);}
50% {-webkit-transform:translateY(-400px);}
100% {-webkit-transform:translateY(0px);}
}
I want to change the "-400 px" in the 50% key-frame dynamically according to the height of an another div.So can we use javascript to achieve this here ? If so,how ?
asked Jan 9, 2015 at 17:49
Ajith
7912 gold badges6 silver badges12 bronze badges
2 Answers 2
Better use Less (http://lesscss.org/) or Sass (http://sass-lang.com/),which are CSS dynamic languages.
Ajith
7912 gold badges6 silver badges12 bronze badges
answered Jan 9, 2015 at 18:03
Mouhamad Kawas
3702 silver badges12 bronze badges
Sign up to request clarification or add additional context in comments.
Comments
I don't think SASS will solve the issue you're having.. (but it's still incredibly handy to use)
Could you explain what you're trying to achieve a little more? (eg positioning, what variables on sizing etc)
lang-js
.css(), I'll write an answer.