Skip to content
Navigation

SubwayLineNav

Your pages as stations on a transit map, with 45 degree bends and an interchange. A three-car train runs to the stop you press and lights the track behind it; hover a stop and the board says how many stops away.

Download
  • React
  • Tailwind CSS v4
  • motion

Props

NameTypeDefaultWhat it does
stops{ label, href, transfer? }[]—Pages along the line, 2 to 7. transfer = name of a crossing line.
startnumber0Index of the station you are at first.
linestring"Green Line"Name on the board.
colorstring"#16895b"Line colour.
transferColorstring"#d9722b"Colour of a crossing line.
minutesPerStopnumber2Minutes per stop shown on the board.
onSelect(stop, event) => void—Called on press. Call event.preventDefault() to stay on the page.
labelstring"Site map"Name read out by screen readers.
classNamestring""Size. Everything inside scales with the width.