Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions packages/web/src/components/StopCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ function Row({

export function StopCard({
s,
max = 6,
max = 4,
filterable = true,
onClose,
}: {
Expand Down Expand Up @@ -155,7 +155,9 @@ export function StopCard({
// tram you can't make stays above a later one you can, and the board doesn't
// re-sort as walk-time / catch range drifts across refreshes.
const lead = list[0]
const rest = list.slice(1, max + 1)
// `max` caps the total departures shown (lead included), so this slice takes
// at most max-1 rows after the lead.
const rest = list.slice(1, max)
const sel = plats.find((p) => p.key === active)
const chipFor = (d: DepartureVM): ReactNode =>
hasFilter && isAll ? (
Expand Down