# Filterable data table

> A dark monospace accounts table: a search types itself, a filter chip lights up and non-matching rows fade away.

- Category: Developer tools
- Version: 1.0
- Source: https://ownlyplans.com/bhaskar/filterable-data-table/

## Overview

A data table with a lime-on-graphite terminal look. The search box types "enterprise", a Plan chip activates, the row counter flips from 8 of 8 to 3 of 8 and only the enterprise rows stay lit. Topic inspired by OpenDesign's public dashboard prompt list; this prompt and design are written from scratch.

## Tech stack

- CSS
- Dashboard
- HTML

## Build steps

### 1. Paste the prompt

The AI generates the table and the animation.

Prompt:

```text
Make a single-file HTML data table screen, 1280x720, graphite background #0e1014, text #e7e9ee, lime accent #c8f560, monospace font stack (ui-monospace, Menlo, Consolas). No libraries.
Header: H1 "Accounts" and subtitle "Filter, sort and review every customer in one place".
Toolbar: a 420px search input with lime text, a chip "Plan: Enterprise x" and a second chip "Status: Any", and a result counter on the right.
Table: columns Account, Plan, Status, ARR (right aligned, bold). Eight rows of realistic companies (Northwind Traders, Pixel Forge, Atlas Logistics, Moss & Wren, Helio Systems, Daybreak Cafe, Quill Studio, Brightpath Edu). Plan and Status are small tags; Enterprise tags are lime tinted, Trial and Renewing are amber tinted.
Motion (8 second loop): rows rise in one after another. The search box types "enterprise" using a steps() width animation and a blinking caret. The Plan chip lights up (lime border and tint). Rows that are not Enterprise fade to 8 percent opacity with a 2px blur, and Enterprise rows get a faint lime background. The counter cross-fades from "Showing 8 of 8" to "Showing 3 of 8". Then everything resets.
Respect prefers-reduced-motion. Return only the complete HTML.
```

### 2. Check the filtering

Only the three Enterprise rows should stay lit.

### 3. Check the counter

It should flip between 8 of 8 and 3 of 8.

**Done when:** You can see it working in the browser.

### 4. Make it real

Replace the animation with real JavaScript filtering over your data.

## Assets

### prompt.md — The full prompt.

~~~~
# Filterable data table

Copy this prompt into Claude, Cursor or Lovable.

```text
Make a single-file HTML data table screen, 1280x720, graphite background #0e1014, text #e7e9ee, lime accent #c8f560, monospace font stack (ui-monospace, Menlo, Consolas). No libraries.
Header: H1 "Accounts" and subtitle "Filter, sort and review every customer in one place".
Toolbar: a 420px search input with lime text, a chip "Plan: Enterprise x" and a second chip "Status: Any", and a result counter on the right.
Table: columns Account, Plan, Status, ARR (right aligned, bold). Eight rows of realistic companies (Northwind Traders, Pixel Forge, Atlas Logistics, Moss & Wren, Helio Systems, Daybreak Cafe, Quill Studio, Brightpath Edu). Plan and Status are small tags; Enterprise tags are lime tinted, Trial and Renewing are amber tinted.
Motion (8 second loop): rows rise in one after another. The search box types "enterprise" using a steps() width animation and a blinking caret. The Plan chip lights up (lime border and tint). Rows that are not Enterprise fade to 8 percent opacity with a 2px blur, and Enterprise rows get a faint lime background. The counter cross-fades from "Showing 8 of 8" to "Showing 3 of 8". Then everything resets.
Respect prefers-reduced-motion. Return only the complete HTML.
```
~~~~

### index.html.md — Complete code of the result in the video.

~~~~
# index.html

The finished result as one file. Save it as index.html and open it.

```html
<!doctype html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1"><title>Filterable data table dashboard</title><style>*{box-sizing:border-box;margin:0;padding:0}
html,body{width:1280px;height:720px;overflow:hidden}
body{font-family:ui-sans-serif,system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;-webkit-font-smoothing:antialiased}
@property --n{syntax:'<integer>';inherits:false;initial-value:0}
.stage{position:absolute;inset:0;animation:cyc 8s linear infinite both}
@keyframes cyc{0%{opacity:0}4%{opacity:1}94%{opacity:1}100%{opacity:0}}
body:not(.go) *,body:not(.go) *::before,body:not(.go) *::after{animation-play-state:paused!important}
.cnt::after{content:counter(n)}.cnt{counter-reset:n var(--n)}
@media (prefers-reduced-motion:reduce){*{animation:none!important}}


body{background:#0e1014;color:#e7e9ee;font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace}
.wrap{position:absolute;left:48px;right:48px;top:34px}
h1{font:800 26px ui-sans-serif,system-ui;letter-spacing:-.03em}.sub{color:#7d8597;font-size:13px;margin:6px 0 22px}
.bar{display:flex;gap:12px;align-items:center;margin-bottom:18px}
.srch{width:420px;height:46px;border:1.5px solid #2a2f3b;border-radius:12px;background:#151922;padding:13px 16px;font-size:15px;color:#c8f560;overflow:hidden;white-space:nowrap}
.srch span{display:inline-block;overflow:hidden;vertical-align:top;border-right:2px solid #c8f560;animation:ty 8s steps(10) infinite both}
@keyframes ty{0%,10%{width:0}28%,72%{width:10ch}80%,100%{width:0}}
.chip{padding:11px 16px;border-radius:99px;border:1.5px solid #2a2f3b;font-size:13px;color:#9aa3b6}
.chip.on{animation:ch 8s infinite both}
@keyframes ch{0%,34%{background:transparent;color:#9aa3b6;border-color:#2a2f3b}40%,72%{background:#c8f56022;color:#c8f560;border-color:#c8f560}80%,100%{background:transparent;color:#9aa3b6;border-color:#2a2f3b}}
.cnt2{margin-left:auto;color:#7d8597;font-size:13px;position:relative;width:150px;height:18px}.cnt2 i{font-style:normal;position:absolute;right:0}
.n1{animation:n1 8s infinite both}.n2{animation:n2 8s infinite both}
@keyframes n1{0%,24%{opacity:1}30%,74%{opacity:0}80%,100%{opacity:1}}@keyframes n2{0%,24%{opacity:0}30%,74%{opacity:1}80%,100%{opacity:0}}
table{width:100%;border-collapse:collapse}
th{font-size:11px;letter-spacing:.12em;text-transform:uppercase;color:#6d7587;text-align:left;padding:10px 14px;border-bottom:1.5px solid #232834}
td{padding:0 14px;font-size:14px;border-bottom:1px solid #1a1e27}
tr.r td{height:54px}
tr.x td{animation:x 8s infinite both}
@keyframes x{0%,28%{opacity:1}34%,72%{opacity:0.08;filter:blur(2px)}80%,100%{opacity:1;filter:none}}
tr.m td{animation:m 8s infinite both}
@keyframes m{0%,30%{background:transparent}38%,72%{background:#c8f5601a}80%,100%{background:transparent}}
.tag{padding:3px 9px;border-radius:7px;background:#1d2230;font-size:12px}.tag.e{background:#c8f56022;color:#c8f560}.tag.s{background:#f5a52422;color:#f5a524}
td:last-child{text-align:right;font-weight:700}
tr.in{opacity:0;animation:in 8s infinite both}
@keyframes in{0%,4%{opacity:0;transform:translateY(8px)}10%,100%{opacity:1;transform:none}}
</style></head><body><div class="stage"><div class="wrap"><h1>Accounts</h1><div class="sub">Filter, sort and review every customer in one place</div>
<div class="bar"><div class="srch"><span>enterprise</span></div><div class="chip on">Plan: Enterprise ✕</div><div class="chip">Status: Any</div><div class="cnt2"><i class="n1">Showing 8 of 8</i><i class="n2">Showing 3 of 8</i></div></div>
<table><thead><tr><th>Account</th><th>Plan</th><th>Status</th><th style="text-align:right">ARR</th></tr></thead><tbody><tr class="r in m" style="animation-delay:0.0s"><td>Northwind Traders</td><td><span class="tag e">Enterprise</span></td><td><span class="tag ">Active</span></td><td>$128,400</td></tr><tr class="r in x" style="animation-delay:0.07s"><td>Pixel Forge</td><td><span class="tag ">Starter</span></td><td><span class="tag s">Trial</span></td><td>$2,900</td></tr><tr class="r in m" style="animation-delay:0.14s"><td>Atlas Logistics</td><td><span class="tag e">Enterprise</span></td><td><span class="tag ">Active</span></td><td>$94,250</td></tr><tr class="r in x" style="animation-delay:0.21000000000000002s"><td>Moss &amp; Wren</td><td><span class="tag ">Pro</span></td><td><span class="tag ">Active</span></td><td>$18,600</td></tr><tr class="r in m" style="animation-delay:0.28s"><td>Helio Systems</td><td><span class="tag e">Enterprise</span></td><td><span class="tag s">Renewing</span></td><td>$211,000</td></tr><tr class="r in x" style="animation-delay:0.35000000000000003s"><td>Daybreak Café</td><td><span class="tag ">Starter</span></td><td><span class="tag ">Active</span></td><td>$1,450</td></tr><tr class="r in x" style="animation-delay:0.42000000000000004s"><td>Quill Studio</td><td><span class="tag ">Pro</span></td><td><span class="tag s">Trial</span></td><td>$7,320</td></tr><tr class="r in x" style="animation-delay:0.49000000000000005s"><td>Brightpath Edu</td><td><span class="tag ">Pro</span></td><td><span class="tag ">Active</span></td><td>$24,980</td></tr></tbody></table></div></div><script>window.start=function(){document.body.classList.add("go")};if(!/[?&]rec/.test(location.search))start();</script></body></html>
```
~~~~


## Build instructions by tool

### Claude Code

Open a terminal in an empty folder, run `claude`, then paste the prompt.

```text
Build the "Filterable data table" app from the OwnlyPlans blueprint at https://ownlyplans.com/bhaskar/filterable-data-table/.
Stack: CSS, Dashboard, HTML.
Follow the plan's steps in order: Paste the prompt → Check the filtering → Check the counter → Make it real.
Download the full plan (Markdown) from the link above and keep it in the project root as PLAN.md.
Ask me before adding anything not in the plan. (Prepared for Claude Code.)
```

### Cursor

Open an empty folder in Cursor, start an Agent chat, then paste the prompt.

```text
Build the "Filterable data table" app from the OwnlyPlans blueprint at https://ownlyplans.com/bhaskar/filterable-data-table/.
Stack: CSS, Dashboard, HTML.
Follow the plan's steps in order: Paste the prompt → Check the filtering → Check the counter → Make it real.
Download the full plan (Markdown) from the link above and keep it in the project root as PLAN.md.
Ask me before adding anything not in the plan. (Prepared for Cursor.)
```

### Lovable

Start a new Lovable project and paste the prompt as your first message.

```text
Build the "Filterable data table" app from the OwnlyPlans blueprint at https://ownlyplans.com/bhaskar/filterable-data-table/.
Stack: CSS, Dashboard, HTML.
Follow the plan's steps in order: Paste the prompt → Check the filtering → Check the counter → Make it real.
Download the full plan (Markdown) from the link above and keep it in the project root as PLAN.md.
Ask me before adding anything not in the plan. (Prepared for Lovable.)
```

## Definition of done

- Every build step is complete and the app runs locally.
- The main user flow works end to end.
- Share your build on OwnlyPlans with a demo link, build time and tool.
