Follow the code below:
<marquee behavior="scroll" direction="left">Seu texto aqui</marquee>
How can I do this with label?
<label class="col-sm-2 col-form-label" for="Link">Seu texto aqui</label>
Follow the code below:
<marquee behavior="scroll" direction="left">Seu texto aqui</marquee>
How can I do this with label?
<label class="col-sm-2 col-form-label" for="Link">Seu texto aqui</label>
You can emulate the behavior of <marquee>
(which is currently indicated as deprecated), in CSS with animation
and translate()
.
.marquee {
width: 100%;
margin: 0 auto;
white-space: nowrap;
box-sizing: border-box;
overflow: hidden;
}
.marquee-scroll {
display: inline-block;
padding-left: 100%;
animation: scroll 10s linear infinite;
}
@keyframes scroll {
0% {
transform: translate(0, 0);
}
100% {
transform: translate(-100%, 0);
}
}
<div class="marquee">
<label for="Link" class="marquee-scroll">Seu texto aqui</label>
</div>