ETA Range

ETA Range is a copy-paste React component that stops delivery promised on an impossible day 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/eta-range
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

StopsDelivery promised on an impossible day

Was this component page useful?

How do I install ETA Range?

pnpm dlx shadcn@latest add @bollard/eta-range

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

How do I use ETA Range in React?

eta-range-usage.tsx
import { EtaRange } from "@/components/ui/eta-range"

<EtaRange
  now={TIMES[time]}
  timeZone="Asia/Kolkata"
  cutoff="16:00"
  transit={[0.05, 0.25, 0.5, 0.15, 0.05]}
  previous={{ earliest: "2026-10-15", latest: "2026-10-16" }}
  reason="Carrier backlog after the long weekend"
/>

What input mistakes does ETA Range catch?

  • False precision, by quoting a range instead of one date
  • Holidays and no-delivery days inside the range
  • The order cutoff, with the range you get after it
  • A range that widened since last shown, with the reason

What props does ETA Range accept?

EtaRange props
PropTypeDefault
now

Order time. Leave out to use the live clock (ticks every 30 s after mount).

Date | number—
previous

The range you quoted before, as "YYYY-MM-DD" days, to explain a change.

{ earliest: string; latest: string }—
reason

Why the estimate changed, e.g. "Carrier backlog after the long weekend".

string—
countdownWithin

Show the cutoff countdown when the cutoff is this close, in minutes.

number360
locale

Date and time formatting locale.

string"en-IN"
titleText

Templates: `{range}`, `{day}`, `{share}`, `{wait}`, `{cutoff}`, `{ship}`, `{after}`, `{days}`, `{previous}`.

string"Arrives {range}"
likelyText

Text naming the most likely day.

string"most likely {day} ({share} of orders)"
flatText

Text used when no day stands out.

string"any day in this range is about as likely"
countdownText

Countdown to the cutoff.

string"Order within {wait} to ship {ship} ({cutoff} cutoff). Af…
missedText

Shown after the cutoff has passed.

string"Today's {cutoff} cutoff has passed, so it ships {ship}."
shipsText

Text saying when the order ships.

string"Ships {ship}."
closedText

Text naming no-delivery days in the range.

string"No deliveries on {days}; it isn't counted."
widenedText

Explains why the range widened.

string"Widened from {previous}."
todayLabel

Word used for today.

string"today"

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

How is ETA Range accessible?

  • The distribution chart is aria-hidden, with a text version of each day's share
  • Countdown and changes are aria-live="polite"
  • aria-busy while the clock hasn't loaded

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

What are the limitations and server boundaries?

  • Accuracy depends on the delivery distribution and calendar you pass
  • The 90% range is a statistical estimate, not a carrier guarantee

What expensive mistakes does ETA Range stop?

Delivery promised on an impossible day

Also known as

delivery estimate · eta · shipping · order tracking · cutoff · business days · checkout · pincode

Field type

What dependencies does ETA Range require?

ETA Range facts & technical specifications

Technical specifications, licensing, and limitations
PropertySpecification
Component nameETA Range
Registry identifier@bollard/eta-range
Install commandnpx shadcn@latest add @bollard/eta-range
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 ETA Range

How does ETA Range prevent financial transaction errors?

ETA Range prevents delivery promised on an impossible day. Blocks False precision, by quoting a range instead of one date, Holidays and no-delivery days inside the range, The order cutoff, with the range you get after it, A range that widened since last shown, with the reason before processing. Limitation: apply idempotency keys for eta-range.

How do I install eta-range with shadcn?

Run `npx shadcn@latest add @bollard/eta-range`. Sources added: registry/default/eta-range/eta-range.tsx, registry/default/eta-range/eta.ts. Package requirements: lucide-react.

What props customize ETA Range?

ETA Range accepts `now`, `previous`, `reason`, `countdownWithin`, `locale`. Configures delivery estimate, eta, shipping behavior. Limitation: invalid prop values fallback to safe default options.

What are the limits of eta-range?

Accuracy depends on the delivery distribution and calendar you pass. The 90% range is a statistical estimate, not a carrier guarantee Server requirement: backend verification for eta-range.

How does ETA Range meet accessibility guidelines?

The distribution chart is aria-hidden, with a text version of each day's share. Countdown and changes are aria-live="polite". aria-busy while the clock hasn't loaded. Minimizes errors: delivery date wrong, eta too precise.

Which components pair with ETA Range?