Error state
Something didn't load, said calmly: what failed, what it means, and the way out. The pair to the empty state.
Loading, empty, failed
One frame for all three. The header and row grid never move; only what's laid over them changes.
Loading
Empty
No waypoints yet
Add the first one from the map.
Failed
Couldn't load the waypoints
Check your connection and try again.
Plain
On the page, centred in the region that failed. Try again spins until it settles.
Couldn't load the waypoints
The list didn't come back. Check your connection and try again.
<ErrorState
title="Couldn't load the waypoints"
description="The list didn't come back. Check your connection and try again."
onretry={() => waypoints.refresh()}
detail={error.message}
/> Beside the empty state
Same shape, same place: a region that's empty and one that failed only differ in what they say.
No missions yet
Plan the first one to book a vessel.
Couldn't load the missions
Check your connection and try again.
Inline
A status line, for a slot too small to centre in: a sheet section, a popover, the foot of a list. The same red mark, beside the title.
Uploads
Couldn't load the uploads
The server didn't answer.
<ErrorState
variant="inline"
title="Couldn't load the uploads"
onretry={refresh}
/> What failed
The kind sets the icon. The words are still yours: say what, and what to do.
Couldn't load the mission
It may have been deleted, or the connection dropped.
You're offline
The schedule will load when the connection is back.
This report no longer exists
It was deleted or moved. The project still has the others.
You don't have access to this project
Ask someone at Vestland Marin AS to invite you.
Rules
- Say what failed, by name: "Couldn’t load the waypoints", not "Something went wrong". The generic one is only for a page that crashed.
- Then what it means and what to do, in a sentence: check the connection, try again, ask someone.
- Red is the small solid mark only. The tile, icon and title are the empty state’s, so it’s read, not flinched at.
- Offer Try again whenever trying again could work. It spins while it runs, and the state stays in place, so a second failure doesn’t jump.
- The technical message goes behind Details, with a copy button, for support. Never in the title.
- Same shape and place as the empty state for the same region, so loading, empty and failed all sit in one spot.
- An action that failed (save, send) is a toast or a field error, not an error state. This is for content that didn’t arrive.