# FlightRoute

> One flight leg: the airline's mark, name and flight number, then departure and arrival either side of a track that carries the duration, a dot per stop and a plane glyph.

```ts
import { FlightRoute } from "@sdxc/ui/travel";
```

Renders the route on one line: departure at the start, arrival at the end, and between them
the duration over a drawn track with the stops label under it. It never wraps, so it doubles
as the compact summary of a whole journey in a results row.

## Examples

```tsx
<FlightRoute
	departure={{ time: "08:40", code: "MRW", city: "Merrow" }}
	arrival={{ time: "06:05", code: "OSK", city: "Oskarn" }}
	duration="19h 25m" stops={1} stopsLabel="1 stop · VLS" dayOffset="+1" dayOffsetLabel="next day"
/>
```

## Props

| Prop | Type | Description |
| --- | --- | --- |
| `departure` | `Endpoint` |  |
| `arrival` | `Endpoint` |  |
| `duration` | `RemixNode` | The time in the air or the whole journey, formatted, such as "2h 15m". |
| `stops?` | `number` | How many stops the track draws as dots; zero draws a clear line. |
| `stopsLabel?` | `RemixNode` | What the stops amount to, under the track, such as "Nonstop" or "1 stop · VLS". |
| `dayOffset?` | `string` | The badge after the arrival time when it lands on a later day, such as "+1". |
| `dayOffsetLabel?` | `string` | What the day badge means, read in its place, such as "arrives the next day". |
| `labels?` | `Labels` |  |

Also accepts everything in `Omit<TagProps<"div">, "children">`.


## Also exported

- `FlightSegment`
