# Trips

> Trips and orders an assistant gathered from mail, booking sites and delivery apps: deliveries on the way, a trip with flight, hotel, ride and tickets, and recent calls beside it.

Pattern · Pro kit · [Live page](https://ui.twentyfirst.media/pro/patterns/TripsScreen/)

Trips and orders an assistant gathered from mail, booking sites and delivery apps: deliveries on
the way, a trip with flight, hotel, ride and tickets, and recent calls beside it.

## Code

```tsx
import * as React from "react";
import {
  AppShell,
  Button,
  CallLog,
  PageHeader,
  Panel,
  ReservationCard,
  Stagger,
} from "@twentyfirstmedia/pro";
import "./_connectors";
import { LIFE_NAV } from "./_lifenav";

const now = new Date(2026, 10, 14, 9, 30);
const two = {
  "--cols": "repeat(2, minmax(0, 1fr))",
  "--cols-sm": "1fr",
  gap: 16,
} as React.CSSProperties;

/** Upcoming trips and open orders gathered from mail, booking sites and delivery apps, with recent calls. */
export default function Preview() {
  return (
    <AppShell
      navigation="sidebar"
      brand="Life"
      sidebarGroups={LIFE_NAV}
      active="trips"
      user={{ name: "Mara Ellis", email: "mara@halo.app" }}
      dock={false}
      side={
        <Panel side title="Calls" subtitle="Today and yesterday">
          <CallLog
            now={now}
            onCall={() => {}}
            calls={[
              {
                id: "1",
                name: "Rove Downtown",
                direction: "missed",
                at: new Date(2026, 10, 14, 8, 52),
              },
              {
                id: "2",
                name: "Emirates",
                direction: "outgoing",
                at: new Date(2026, 10, 13, 16, 10),
                duration: 640,
                summary: "Seat 32A confirmed; vegetarian meal added.",
              },
            ]}
          />
        </Panel>
      }
    >
      <div className="tf-in">
        <PageHeader
          title="Trips & orders"
          subtitle="Found in Gmail, Booking.com, Deutsche Bahn and Wolt"
          actions={[
            <Button key="add" variant="secondary" icon="plus">
              Add booking
            </Button>,
          ]}
        />
      </div>
      <Stagger className="tf-col" style={{ gap: 16 }}>
        <div className="tf-grid" style={two}>
          <ReservationCard
            kind="order"
            title="Wolt · Tokyo Ramen"
            subtitle="2 items · €31.40"
            start={new Date(2026, 10, 14, 19, 10)}
            status="onTheWay"
            statusText="Arrives 19:40"
            service={{ name: "Wolt", icon: "brandWolt" }}
          />
          <ReservationCard
            kind="order"
            title="Amazon · Running shoes"
            subtitle="1 item · €119.90"
            start={new Date(2026, 10, 15, 12, 0)}
            status="confirmed"
            statusText="Arrives tomorrow"
            service={{ name: "Amazon", icon: "brandAmazon" }}
          />
        </div>
        <Panel title="Dubai" subtitle="20–24 November">
          <div className="tf-grid" style={two}>
            <ReservationCard
              kind="flight"
              title="Hamburg → Dubai"
              subtitle="EK 60 · Seat 32A"
              start={new Date(2026, 10, 20, 14, 35)}
              end={new Date(2026, 10, 20, 23, 50)}
              place="HAM Terminal 1 → DXB Terminal 3"
              code="K7XQ2M"
              status="delayed"
              statusText="+25 min"
            />
            <ReservationCard
              kind="stay"
              title="Rove Downtown"
              subtitle="Double room · 4 nights"
              start={new Date(2026, 10, 20)}
              end={new Date(2026, 10, 24)}
              place="Al Mustaqbal St, Dubai"
              code="4419 2207 81"
              status="confirmed"
              service={{ name: "Booking.com", icon: "brandBooking" }}
            />
            <ReservationCard
              kind="ride"
              title="Careem · Airport to hotel"
              subtitle="Comfort · about AED 70"
              start={new Date(2026, 10, 21, 0, 30)}
              status="pending"
              statusText="Booked by the assistant once you land"
              service={{ name: "Careem", icon: "brandCareem" }}
            />
            <ReservationCard
              kind="event"
              title="Museum of the Future"
              subtitle="2 tickets"
              start={new Date(2026, 10, 22, 11, 0)}
              place="Sheikh Zayed Rd"
              code="MOTF-88213"
              status="confirmed"
            />
          </div>
        </Panel>
      </Stagger>
    </AppShell>
  );
}
```

## Props

### AppShell

| Prop | Type | Notes |
| --- | --- | --- |
| `active?` | `string` |  |
| `brand?` | `ReactNode` | The product name, or a node (a logo mark with the name; collapsed sidebars show it whole). |
| `brandDot?` | `boolean` | The status dot after the brand (default `true`); turn it off next to a logo of your own. |
| `tag?` | `string` |  |
| `nav?` | `NavItem[]` |  |
| `user?` | `{ name: string; email?: string }` |  |
| `onNavigate?` | `(label: string) => void` |  |
| `topExtra?` | `ReactNode` |  |
| `sheetStyle?` | `CSSProperties` |  |
| `contentKey?` | `string \| number` |  |
| `side?` | `ReactNode` |  |
| `dock?` | `boolean` |  |
| `dockItems?` | `DockProps["items"]` |  |
| `railTop?` | `RailItem[]` |  |
| `railBottom?` | `RailItem[]` |  |
| `fill?` | `boolean` | The shell is the whole page: at least the viewport's height (100dvh), no outer radius, the sheet fills the rest; on desktop the sidebar stays in view while the page scrolls, on phones the sheet starts right under the sidebar's bar. |
| `navigation?` | `"top" \| "sidebar"` |  |
| `sidebarGroups?` | `SidebarGroup[]` | With `navigation="sidebar"`: groups instead of the flat `nav` list. |
| `sidebar?` | `Partial<Omit<SidebarProps, "variant" \| "groups">>` | With `navigation="sidebar"`: more sidebar props (collapsed, storageKey, shortcut, linkAs …). |
| `workspaces?` | `WorkspaceSwitcherProps` | With `navigation="sidebar"`: the workspace switcher at the top instead of the brand. |
| `userMenu?` | `(MenuItem \| "-")[]` | The account menu's entries (with `navigation="sidebar"` at the foot of the sidebar). |
| `topbar?` | `boolean \| ReactNode` | With `navigation="sidebar"`: a bar across the top of the frame. The brand (or `workspaces`) moves into its start, as wide as the sidebar below it (expanded or collapsed); `topStart` follows it, `topEnd` sits at the end. Frame, bar and sidebar read as one L around the sheet. Content given here goes between `topStart` and `topEnd`. On phones the bar is the sidebar's bar (menu button and brand) with `topEnd` on the right and `topStart` behind an icon button. |
| `topStart?` | `ReactNode` | With `topbar`: right after the brand, e.g. a search field or a command palette trigger. |
| `topEnd?` | `ReactNode` | With `topbar`: at the end of the bar (buttons, menus); `topExtra` goes there too. |
| `topStartCompact?` | `ReactNode` | With `topbar` on phones: what stands in for `topStart` (default: an icon button that opens `topStart` over the bar). |
| `topStartIcon?` | `IconName` | The icon of that button (default `search`). |
| `topStartLabel?` | `string` | The accessible name of that button (default "Search"). |
| `children?` | `ReactNode` |  |
| `className?` | `string` | Extra class on the root element. |
| `style?` | `CSSProperties` | Inline style on the root element. |

### CallLog

| Prop | Type | Notes |
| --- | --- | --- |
| `calls` | `CallItem[]` | Required |
| `now?` | `Date \| string \| number` | "Now" for the day headings. |
| `onCall?` | `(id: string) => void` |  |
| `onOpen?` | `(id: string) => void` |  |
| `label?` | `string` | Accessible name (default "Calls"). |
| `className?` | `string` | Extra class on the root element. |
| `style?` | `CSSProperties` | Inline style on the root element. |

### PageHeader

| Prop | Type | Notes |
| --- | --- | --- |
| `crumbs?` | `(string \| Crumb)[]` | A breadcrumb above the title (see `Breadcrumb`): labels, or items with `href`/`onClick`. |
| `crumbLinkAs?` | `ElementType` | The element crumb links render as, e.g. Next.js `Link`. |
| `title` | `string` | Required |
| `subtitle?` | `string` |  |
| `actions?` | `ReactNode[]` |  |
| `className?` | `string` | Extra class on the root element. |
| `style?` | `CSSProperties` | Inline style on the root element. |

### Panel

| Prop | Type | Notes |
| --- | --- | --- |
| `side?` | `boolean` |  |
| `title?` | `string` |  |
| `subtitle?` | `string` |  |
| `action?` | `ReactNode` |  |
| `children?` | `ReactNode` |  |
| `surface?` | `Surface` | `"glass"`: translucent glass over what is behind (maps, 3D, video, photos); `"solid"` opts out inside a glass `UIProvider`. |
| `className?` | `string` | Extra class on the root element. |
| `style?` | `CSSProperties` | Inline style on the root element. |

### ReservationCard

| Prop | Type | Notes |
| --- | --- | --- |
| `kind` | `"stay" \| "flight" \| "train" \| "ride" \| "order" \| "event"` | Required |
| `title` | `string` | Required |
| `subtitle?` | `ReactNode` | "Hotel Atlantic · 2 nights", "LH 2024 · Seat 14A". |
| `start` | `Date \| string \| number` | Required |
| `end?` | `Date \| string \| number` |  |
| `place?` | `ReactNode` | Where: an address, airport codes, a restaurant. |
| `code?` | `string` | Booking or order number. |
| `status?` | `"confirmed" \| "pending" \| "cancelled" \| "delayed" \| "onTheWay" \| "delivered"` |  |
| `statusText?` | `string` | Extra words for the status: "+25 min", "Arrives 19:40". |
| `service?` | `ServiceRef` |  |
| `actions?` | `ReactNode` |  |
| `className?` | `string` | Extra class on the root element. |
| `style?` | `CSSProperties` | Inline style on the root element. |
