Chart

Win-Loss Row

A row of wins and losses: a bar up means it worked, down means it did not. The bars carry no height on purpose — the only question here is how often, and where in a streak.

React + Tailwind, shadcn-compatible: press “Copy for AI” and your Cursor or Claude Code agent installs it with the shadcn CLI.

What you can change

  • the row through outcomes: 1 for a win, −1 for a loss, 0 for a draw
  • the caption through label and the summary through summaryTemplate with {wins}, {losses} and {total}
  • the screen-reader label through ariaTemplate with the same placeholders

A link for your AI agent: preview, code and instructions.

Preview

1440pxHost theme
Win-Loss Row — A row of wins and losses: a bar up means it worked, down means it did not. The bars carry no height on purpose — the only question here is how often, and where in a streak.

Use it with AI

  1. 1. Copy the link.
  2. 2. Write to your agent in your own words and drop the link into the sentence.
  3. 3. The agent opens the link and installs the component from the registry.
AI
1Pick it here

put this on the home page as the hero:

https://vibeui.club/c/sparkline-004?lang=en&theme=dark

2Paste into the chat
3Get it in your project

Not sure where to paste it? Step-by-step guide

Show the full instructions

What the link says, spelled out. Use it when your agent cannot open links — paste this text instead.

Loading…

How to use

<Sparkline004
  label="Nightly builds"
  outcomes={[1, 1, -1, 1, 0, 1]}
/>

A sample call. The agent installs the component itself from the registry via the “Copy for AI” link.

Settings

Caption
label · default: Nightly builds
Win colour
accent · default: theme colour
Background
background · default: theme colour

FAQ

How do I add Win-Loss Row with Cursor or Claude Code?
Press “Copy for AI” on this page and paste it into your agent's chat. The instruction contains the shadcn CLI install command, the dependencies and what to keep, so the agent installs this exact component instead of recreating a lookalike.
What does Win-Loss Row depend on?
No npm packages beyond React and Tailwind CSS.
What can I change in Win-Loss Row?
Adapt: the row through outcomes: 1 for a win, −1 for a loss, 0 for a draw; the caption through label and the summary through summaryTemplate with {wins}, {losses} and {total}; the screen-reader label through ariaTemplate with the same placeholders. Keep as installed: the local --vibeui-sparkline-004-* palette: the component must look the same in any project; the equal bar heights: a difference in height would read as "it worked harder", which an outcome cannot mean; the zero line through the middle — without it the row is just dashes with no anchor.
Is Win-Loss Row free?
Yes. The preview is open without an account; with a free account you can copy up to 20 components a month.

For developers

npx shadcn@latest add https://vibeui.club/r/pro/sparkline-004.json

This command needs a signed link: sign in and open “Component source” below — it issues a working link valid for 30 minutes. All install options

Technical notes

One file, zero dependencies, the --vibeui-sparkline-004-* palette. A server component with no SVG. The row is a grid of two equal rows: a win takes the upper one, a loss the lower, so no offsets have to be computed. Each mark's column is set explicitly — with the row fixed, auto-placement would order the bars wrongly. A zero line runs through the middle and holds the row together. A draw is a short dash on that line: a gap would read as missing data, which means something else. The prop is called outcomes rather than results: results is a legacy HTML attribute and React's types would narrow it to a number.

Tags

  • sparkline
  • win-loss
  • status
  • compact
Component source

The same file your agent installs. Here in case you would rather copy it by hand.

Loading…