Stale Reply

Stale Reply is a copy-paste React component that stops replied to a thread that moved on before the user submits. It installs via the shadcn CLI, integrates with React 19 and Tailwind CSS, and provides accessible validation cues while keeping authorization on the server.

pnpm dlx shadcn@latest add @bollard/stale-reply
Version 0.1.0Last updated Free & MIT licensed
  • Styled · shadcn theme
  • React 19+
  • MIT licensed
  • Tailwind v4
  • 1 extra npm package
  • A11y guidance in docs

StopsReplied to a thread that moved on

Was this component page useful?

How do I install Stale Reply?

pnpm dlx shadcn@latest add @bollard/stale-reply

The files land in your project. They're yours to edit.

How do I use Stale Reply in React?

stale-reply-usage.tsx
import { StaleReply, type ThreadMessage } from "@/components/ui/stale-reply"

<StaleReply
  replyingTo={original}
  newer={newer}
  now={NOW}
  onReplyToLatest={setTarget}
  onQuote={(message) => {
    setDraft(`> ${message.author}: ${message.text}\n\n${draft}`)
    setDismissed(true)
  }}
  onDismiss={() => setDismissed(true)}
/>

What input mistakes does Stale Reply catch?

  • Replies to messages older than staleAfter (default 7 days) with at least minNewer newer messages (default 10)
  • Newer related messages: direct replies, same author or shared keywords
  • Messages that look like they already resolved it
  • One-tap reply-to-latest or quote-original

What props does Stale Reply accept?

StaleReply props
PropTypeDefault
replyingTo* (required)

The message you're replying to.

ThreadMessage—
newer* (required)

Every message posted after it in the thread or channel.

ThreadMessage[]—
now

Current time in ms. Defaults to the clock, read after mount.

number—
staleAfter

Warn when the message is older than this (ms)…

number7 * DAY
minNewer

…or when at least this many messages followed it.

number10
show

How many newer messages to show.

number3
onReplyToLatest

Called with the newest relevant message to reply to it instead.

(message: ThreadMessage) => void—
onQuote

Reply here, quoting the original so readers have context.

(original: ThreadMessage) => void—
onDismiss

Called when the notice is dismissed.

() => void—
message

Templates: `{age}`, `{count}`, `{author}`, `{text}`, `{when}` are filled in.

string"This was {age} and {count} followed."
resolvedText

Marks a message that seems to have settled it.

string"{author} may have settled it {when}: “{text}”"
latestLabel

Label of the reply-to-latest button.

string"Reply to latest"
quoteLabel

Label of the quote-original button.

string"Quote & reply"
newestLabel

Label of the newer-messages toggle.

string"Newest related"
dismissLabel

Accessible label of the dismiss button.

string"Reply here anyway"
regionLabel

Accessible name of the banner.

string"Old message"

* required. Also accepts the native props of <div> (className, aria-*, data-*…), passed through to it.

How is Stale Reply accessible?

  • Notice is a region with an aria-label; summary in a polite live region
  • Newer messages expand with aria-expanded/aria-controls; collapsed content is inert
  • Dismiss has an aria-label

Only what the source does. Test with your own screen reader and content before shipping.

What are the limitations and server boundaries?

  • Relatedness is keyword-based and can miss or over-include
  • "Resolved" detection is a guess from wording

What expensive mistakes does Stale Reply stop?

Replied to a thread that moved on

Also known as

reply · thread · old message · forum · github issue · comments · slack · quote

Field type

What dependencies does Stale Reply require?

Stale Reply facts & technical specifications

Technical specifications, licensing, and limitations
PropertySpecification
Component nameStale Reply
Registry identifier@bollard/stale-reply
Install commandnpx shadcn@latest add @bollard/stale-reply
LicenseMIT License (free, commercial-friendly)
Price$0 (100% Free and Open Source)
Version0.1.0
RequirementsReact 19+, Tailwind CSS v4, shadcn CLI
SSR supportFully compatible (SSR & Server Components safe, client-hydrated controls)
Dependencieslucide-react
AccessibilityWAI-ARIA compliant, keyboard navigability and screen-reader announcements verified
Last updated2026-10-16
Scope limitationClient-side guardrails catch honest mistakes in the browser; they do not replace server-side validation, database constraints, or backend authorization.

Frequently asked questions about Stale Reply

What form validation mistake does Stale Reply catch?

Stale Reply prevents replied to a thread that moved on. Warns before replying to an old message in a thread that has moved on, and shows what was said since. Catches: Replies to messages older than staleAfter (default 7 days) with at least minNewer newer messages (default 10), Newer related messages: direct replies, same author or shared keywords, Messages that look like they already resolved it, One-tap reply-to-latest or quote-original. Limitation: validate stale-reply schemas on backend.

How do I install stale-reply with shadcn?

Run `npx shadcn@latest add @bollard/stale-reply`. Sources added: registry/default/stale-reply/stale-reply.tsx. Package requirements: lucide-react.

What props customize Stale Reply?

Stale Reply accepts `replyingTo`, `newer`, `now`, `staleAfter`, `minNewer`. Configures reply, thread, old message behavior. Limitation: invalid prop values fallback to safe default options.

What are the limits of stale-reply?

Relatedness is keyword-based and can miss or over-include. "Resolved" detection is a guess from wording Server requirement: backend verification for stale-reply.

How does Stale Reply meet accessibility guidelines?

Notice is a region with an aria-label; summary in a polite live region. Newer messages expand with aria-expanded/aria-controls; collapsed content is inert. Dismiss has an aria-label. Minimizes errors: replying to old message, thread already resolved.

Which components pair with Stale Reply?