如何使@keyframes⾥⾯的属性值为动态添加dule('altime')
.controller('userActionController', ['$rootScope','$scope', 'realtimeService', function($rootScope,$scope,realtimeService) {        var mpId = $rootScope.mpId;
var count = 1;
$scope.headerInfo = {
title: '实时⽤户⾏为',
tip: '上⼀个 5min 区间内, ⽤户访问⽹站不同的页⾯情况'
};
$scope.data = json;
html animation属性var jsonLength = json.length;
var topLength = -jsonLength*40+40;
var liLength=-jsonLength*40;
$Style={
'top':liLength+'px',
'font-size': '12px',
'font-family': '微软雅⿊',
'padding': '10px',
'position': 'relative',
'animation': 'slide 1000s linear infinite',
'height':'40px'
};
var style = ateElement('style');
var keyFrames = '\
@-webkit-keyframes slide{\
0% {\
top: '+topLength+'px;\
}\
100% {\
top: 40px;\
}\
}';
style.innerHTML = keyFrames;
});

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。