Ballmac UI home

Fleet 1: vehicle fleet

A fleet overview: each vehicle with where it is, status in words, fuel or charge, distance to the next service, and faults, filter by status, message the driver, book a service, all undone with the reason if it fails.

State

The normal view. Pick a state to see what the block shows while it loads, is empty or fails.

Open in v0 (opens in a new tab)

Installation

$ pnpm dlx shadcn@latest add @ballmac/fleet-1

Usage

Example: fleet-1-demo.tsx
"use client"

import { Fleet1 } from "@/components/ballmac/blocks/fleet-1/fleet-1"

export default function Fleet1Demo() {
  return <Fleet1 />
}

States

Pass state and the block does the rest: skeletons that match its layout, a clear empty message, an error you can retry, and announcements for screen readers.

  • Loading

    Skeleton cards under the real heading, announced as loading.

    state="loading"
  • No vehicles yet

    Says no vehicles yet; emptyState sets the copy. A filter with no match says so.

    state="empty"
  • Could not load

    An alert saying nothing was sent or booked, with Try again (onRetry). An action that fails says why.

    state="error"

Dependencies

Use with AI

Fleet overview. <Fleet1 vehicles={[{ id, name, plate, driver?, status: 'moving'|'idle'|'parked'|'service', where, speedKmh?, level, serviceInKm, alerts? }]} lowLevel={20} serviceSoonKm={500} onMessage={(vehicle, text) => Promise} onBookService={(vehicle) => Promise} />. Low level and service soon are called out in words. With the shadcn MCP server set up (guide), ask your agent:

Add the Ballmac UI Fleet 1: vehicle fleet (@ballmac/fleet-1) to this project with the shadcn MCP, then use it where it fits.

Use it for

  • A dispatcher or fleet manager overview
  • Any list of assets with location, level and upkeep

Not for

  • A live map; place this beside one
  • Driver payroll or trips history

Registry JSON: https://ui.ballmac.com/r/fleet-1.json

Free to use in personal and commercial projects.

Ballmac UI Pro

Need the whole screen, not one piece?

150 premium blocks (dashboards, settings, calendars, mail, shops, onboarding), a private shadcn registry and Figma tokens. Blocks that show data come with loading, empty and error states built in.

Not ready? Try three Pro blocks free

Leave your email and the blocks appear right here, ready to copy. Yours to use in any project.