Earned-coins ticker
A ruled band of big italic lines, 'Name earned N coins', the numbers in pink and four-point stars between, rolling left without end.
Part of the style
Spinning Coin Night
7 parts that belong together, with their tokens, type and rules.
https://kitbash.me/components/spinning-coin-night/ticker/figma.html?palette=d2e0f716c6febc19
Use the Figma MCP server (https://mcp.figma.com/mcp). Download https://kitbash.me/components/spinning-coin-night/ticker/figma.html?palette=d2e0f716c6febc19 and pass that whole HTML document to the html_to_figma tool, so the part "Earned-coins ticker" lands as editable layers in my open Figma file. Fonts come from Google Fonts: if a face is missing in Figma, pick the closest one.
Code
<style>
/* Goes after the pack's base.css */
:root {
--night: #f15b29;
--ink: #1d0c0b;
--ink-dim: rgba(29, 12, 11, 0.5);
--paper: #1d0c0b;
--paper-ink: #f15b29;
--chip: #d7613d;
--chip-hover: #d36746;
--rule: rgba(29, 12, 11, 0.14);
--shade: rgba(241, 91, 41, 0.25);
--blush: #480402;
--blush-deep: #460301;
--gold: #4f090e;
--gold-deep: #ac7370;
--gold-light: #804c49;
--gold-glow: rgba(118, 45, 45, 0.35);
}
</style>
<section class="ticker" aria-label="Recent earnings">
<div class="ticker__track">
<span class="ticker__item">Mabel earned <b>1,000 coins</b></span>
<span class="ticker__item">Otis earned <b>240 coins</b></span>
<span class="ticker__item">June earned <b>399 coins</b></span>
<span class="ticker__item">Rafi earned <b>75 coins</b></span>
<span class="ticker__item">Noor earned <b>1,250 coins</b></span>
</div>
</section>
<style>
.ticker {
overflow: hidden;
padding: var(--space-l) 0;
border-block: var(--line) solid var(--rule);
background: var(--night);
color: var(--ink);
}
.ticker__track {
display: flex;
width: max-content;
animation: ticker-roll 32s linear infinite;
}
.ticker:hover .ticker__track { animation-play-state: paused; }
.ticker__item {
display: inline-flex;
align-items: center;
flex: none;
white-space: nowrap;
font-family: var(--font-display);
font-size: var(--display-m);
font-weight: 800;
font-style: italic;
font-variation-settings: "wdth" 112;
letter-spacing: var(--track-display);
line-height: 1.1;
}
.ticker__item b {
margin-left: 0.25em;
color: var(--blush);
font-weight: 900;
}
/* The four-point star between entries. */
.ticker__item::after {
content: "";
width: 0.62em;
height: 0.62em;
margin: 0 0.7em;
background: var(--ink);
clip-path: polygon(50% 0, 60% 40%, 100% 50%, 60% 60%, 50% 100%, 40% 60%, 0 50%, 40% 40%);
}
@keyframes ticker-roll { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker__track { animation: none; } }
</style>
<script>
(() => {
for (const track of document.querySelectorAll('.ticker__track')) {
for (const item of [...track.children]) {
const copy = item.cloneNode(true);
copy.setAttribute('aria-hidden', 'true');
track.append(copy);
}
}
})();
</script>