-1
코덱에서 this pen이 발견되었습니다. 나는 그것을 사용하고 싶다 그러나 막대기는 위로보다는 오히려 아래로 간다 나는 그것을 어떻게 위로 만들 수 있는가?자바 스크립트 사운드 바가 올라갔습니다
var elem = $('div');
var count = elem.length;
var loop = function() {
setTimeout(function() {
elem.each(function() {
var $this = $(this);
var height = (Math.random() * 20) + 1;
$this.css({
'background': 'rgba(255, 255, 255,1)',
'top': height,
'height': height
});
});
loop();
}, 320);
}
loop();
section {
width: 100%;
display: inline-block;
margin: auto;
background: #222;
}
div {
background: #fff;
float: left;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
vertical-align: middle;
height: 1px;
transition: all linear 250ms;
width: 2px;
margin-left: 1px;
}
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<section>
<div></div>
<div></div>
<div></div>
<div></div>
<div></div>
</section>
이들은 ''배경 '필요하지 않다'RGBA (255, 255, 255,1) ' '상단 '높이 ' – mplungjan