Skip to content

Review 5145

Cindy Zhang edited this page Aug 23, 2026 · 1 revision

#5145 — feat(DateRangeInput): add maxRangeSpan/minRangeSpan to constrain range size

freddymeta · merged · view on GitHub

Verdict: approve · 2 rounds

These records predate the Review Presentation format for the most part, so the problem/solution/API/theme-target/breaking slots are only filled where the review itself carried them. Reviews from 2026-08-23 on use the full template.

Round 1 — dismissed · 2026-08-17

Thanks for this — the grid work is solid, and I checked both maxRangeSpan boundaries in Chrome; the window is exactly right.

minRangeSpan isn't enforced yet: with minRangeSpan={2}, clicking Aug 10 twice commits a one-day range, which is the case the prop says it forbids. Once the anchor is placed the span is knowable, same as the max — so the days inside it should be disabled as end dates.

One catch to get right: with those days disabled you can't click Aug 11 to start over there. So clicking the anchor again should toggle it off and clear the selection, rather than restart — otherwise moving the start a day over is impossible.

Separately, a Last 30 days preset applies under maxRangeSpan={7}. Should a preset override the cap, or be disabled when it violates one?

[Reviewed by Robohands]

Round 2 — approve · 2026-08-19

Thanks, all three land. Walked it in Chrome: the forbidden band is right, the anchor clears, the 30-day preset is disabled.

[Reviewed by Robohands]

Clone this wiki locally