Milestone Timeline Peek
Hovering over a milestone highlights the description for that year in a company timeline.
Hovering over a milestone highlights the description for that year in a company timeline.
Live Demo
Hover over the element or use Tab to focus.
Source Code
Copy the HTML, CSS or JavaScript you need for your project.
<ol class="tbx-1064" aria-label="Sample company history">
<li tabindex="0"><span class="tbx-1064__year">2016</span><div><b>Founded</b><small>Started as a small creative studio</small></div></li>
<li tabindex="0"><span class="tbx-1064__year">2020</span><div><b>Business expansion</b><small>Expanded web design services nationwide</small></div></li>
<li tabindex="0"><span class="tbx-1064__year">2026</span><div><b>New service launch</b><small>Launched the Web Tips library</small></div></li>
</ol>
.tbx-1064{list-style:none;margin:0;padding:3px 0 3px 18px;border-left:2px solid #d8e5e7;width:min(295px,100%);font:11px/1.5 system-ui,sans-serif;color:#32536b}
.tbx-1064 li{position:relative;display:flex;gap:13px;align-items:center;border-radius:8px;padding:9px 12px;transition:background .25s,transform .25s;cursor:default}
.tbx-1064 li:before{content:"";position:absolute;left:-23px;width:9px;height:9px;border-radius:50%;border:3px solid #fff;background:#b2cdd0;box-shadow:0 0 0 2px #d3e1e3;transition:background .25s,box-shadow .25s}
.tbx-1064__year{font-size:12px;font-weight:850;color:#638293;transition:color .25s}.tbx-1064 li div{display:grid;gap:2px}.tbx-1064 b{font-size:11px}.tbx-1064 small{font-size:9px;color:#8499a5}.tbx-1064 li:is(:hover,:focus-visible){background:#e4f3f2;transform:translateX(4px)}.tbx-1064 li:is(:hover,:focus-visible):before{background:#3a8d86;box-shadow:0 0 0 4px #c5e4e1}.tbx-1064 li:is(:hover,:focus-visible) .tbx-1064__year{color:#256e78}.tbx-1064 li:focus-visible{outline:2px solid #d4a06e;outline-offset:1px}
@media(prefers-reduced-motion:reduce){.tbx-1064 li,.tbx-1064 li:before,.tbx-1064__year{transition:none}}
How to Use
Insert the HTML and add the CSS to your stylesheet. Adjust colors and sizes and avoid class conflicts.
Use Case
Useful for company sections and history sections.
Technical Notes
Keep controls usable on touch devices. Test keyboard focus and reduced-motion preferences.
Mobile: Ensure the interactive content remains accessible without hover on touch devices.
Browser: Uses modern CSS. Check behavior in the browsers you support.
Reduced Motion: Check that prefers-reduced-motion is respected.