Hello people. It’s been a while but here is another code goodie for you guys and gals. Enjoy the copy and past for some magic.
type: custom:html-card
content: |
<div class="ticker-wrap">
<div class="ticker">
<span class="item-list-1">
<span class="item">Home Assistant rocks because it's community ROCKS!</span>
<span class="item">Come get this AWESOME ticker!</span>
<span class="item">[[sun.sun.attributes.elevation]]</span>
</div>
<div>
style: |
ha-card {
background: none;
height: 10px;
color: white;
font-family: Zen Dots;
font-size: 30px;
}
body { margin: 0; }
.ticker-wrap {
width: 100%;
height: 80px;
margin: 0 auto;
overflow: hidden;
white-space: nowrap;
position: fixed;
bottom: 0;
height: 3.5rem;
}
.ticker {
display: inline-block;
margin-top: 5px;
animation: marquee 30s linear infinite;
}
.item-list {
position: relative;
left: 0%;
animation: swap 20s linear infinite;
}
.item {
display: inline-block;
padding: 0 1rem;
}
/* Transition */
@keyframes marquee {
0% {
transform: translateX(0)
}
100% {
transform: translateX(-100%)
}
}
@keyframes swap {
0%, 50% {
left: 0%;
}
50.01%,
100% {
left: 100%;
}
}
view_layout:
position: main