A white page, and cards that still read on it

The canvas was #F1F0EC — a warm grey that made every screen look slightly
dull. It is white.

── You cannot have both ──

That canvas was not an accident: it was deepened from #F7F6F4 on 2026-09-23
precisely so a white card would sit *on* something and its 1px edge could go
quiet. A white card on a white page has nothing to sit on.

Measured rather than judged by eye: after the canvas change, a pixel scan
across a card boundary on the Orders golden read #FFFFFF from end to end. The
shadow contributed nothing findable. The cards had not become subtle, they had
disappeared.

So the edge comes back. `DmCard` drew its border only for tones that are not
white — the warm canvas was doing that job for the white ones — and now draws
it for every tone, with the lift still underneath. Border plus a soft shadow is
the iOS and Revolut shape rather than the borderless Airbnb one, and that is
the price of a white page. Paid deliberately.

── What moved with it ──

`surfaceAlt` lifts to #F4F2EF. With a white page it is the only token that
makes a surface read as recessed — filled inputs, tiles, skeletons, the sunken
card — so it can no longer sit within a point of the canvas.

`DmCardTone.sunken` filled itself with the canvas colour, which on a white page
is not sunken but invisible. It takes `surfaceAlt`.
This commit is contained in:
2026-09-30 11:35:30 +05:30
parent c7a74c57b8
commit e2fe1b1771
32 changed files with 47 additions and 19 deletions

View File

@@ -75,18 +75,34 @@ class DmColors {
static const ink4 = Color(0xFFB4AEAA);
// ── Surfaces ─────────────────────────────────────────────────────────────
/// The page canvas.
/// The page canvas. White.
///
/// Deepened on 2026-09-23. At `#F7F6F4` a white card on it was a 3% step,
/// so the 1px border was doing all the separating and every screen read as
/// a list of outlined boxes. A canvas the cards can sit *on* is what lets
/// the edge go quiet.
static const canvas = Color(0xFFF1F0EC);
/// ── This has been both, and the trade is real ──
///
/// It was `#F7F6F4`, then deepened to `#F1F0EC` on 2026-09-23 so a white
/// card would sit *on* something and the 1px edge could go quiet. That
/// worked, and it also made every screen read as slightly dull — which is
/// the note that brought it here.
///
/// You cannot have a white page and borderless cards: one of them has to do
/// the separating. On white, [DmCard] is held by its border and
/// [DmShadow.card] rather than by contrast, which is the iOS and Revolut
/// shape rather than the Airbnb one. That is the choice, made deliberately.
///
/// Everything that needs to read as *recessed* — filled inputs, the
/// segmented groove, a sunken card — moved to [surfaceAlt] and [groove],
/// which are the only tokens still darker than the page.
static const canvas = Color(0xFFFFFFFF);
static const surface = Color(0xFFFFFFFF);
/// Filled inputs, quiet chips, tiles, skeleton bases. Also the "sunken"
/// treatment for a disabled primary action.
static const surfaceAlt = Color(0xFFF1EFEC);
/// Filled inputs, quiet chips, tiles, skeleton bases, the "sunken" card and
/// the sunken treatment for a disabled primary action.
///
/// With a white canvas this is the *only* thing that makes a surface read as
/// recessed, so it carries more weight than it used to. It was within a
/// point of the old canvas, which is why the groove below had to exist at
/// all; on white it does its own job again.
static const surfaceAlt = Color(0xFFF4F2EF);
/// The bed a segmented control's chosen segment is raised out of.
///