[英]animation in text, hide text right to left is mounted
I want to do a animation in text, hide text right to left, but the letters is mounted after animation... I know that I can use a white-space: nowrap
but I need it see as a paragraph 我想在文本中制作动画,从右到左隐藏文本,但是在动画之后会挂载字母...我知道我可以使用
white-space: nowrap
但我需要将其视为一个段落
how I can animated this text without mounted letters? 如何在不带字母的情况下对此文本进行动画处理?
setTimeout(function () { $("#title").animate({width: 'hide'}); $("#description").animate({width: 'hide'}); $("#text1").animate({width: 'hide'}); },2000);
.bold{ font-size: 48px; color: black; width: 400px; } .normal{ font-size: 48px; color: black; width: 400px; } #container{ width: 452px; height: 625px; } #description{ margin-top: 40px; margin-bottom: 50px; } #description,#text1{ margin-left: 25px; }
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> <div id="container" > <div id="title" class="bold"> 1231231231123 </div> <div id="description"class="normal">asd asd as da sd asdfsdfasdfasd asd fsadf asdf asdfasdf.</div> <div id="text1" class="bold"> aaaaaaaaaaaaaaaa aaaaaaaaaaaa </div> </div>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.