How to show text reveal with " linear wipe " effect using CSS and JavaScript. How to do that?
<p>Text linear wipe </p>
Check this snippet:
p{ white-space: nowrap; overflow: hidden; width: 30em; animation: linearwipe 6s steps(60, end); } @keyframes linearwipe{ from { width: 0; } }
<p>Text linear wipe </p>
This code is perfectly working:
CSS:
.linear-wipe{
white-space: nowrap;
overflow: hidden;
animation: linearwipe 1s steps(100, end);
opacity: 1;
width: 0%;
}
@keyframes linearwipe{
from { width: 0;opacity: 0 }
}
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.