Skip to content

docs(brand): colour roles, the track hues, and the two restrictions that drifted - #407

Open
IanoNjuguna wants to merge 3 commits into
IntersectMBO:mainfrom
IanoNjuguna:docs/brand-colour-roles
Open

IanoNjuguna wants to merge 3 commits into
IntersectMBO:mainfrom
IanoNjuguna:docs/brand-colour-roles

Conversation

@IanoNjuguna

Copy link
Copy Markdown
Contributor

Description

Writes down what each brand colour is for, and resolves the two restrictions in the guide that no longer matched what the site ships.

brand-baseline listed the swatches by name and hex and never said what any of them was for. That knowledge existed only as comments inside website/src/css/custom.css, which is exactly where someone about to pick a colour is not looking, and where an agent reads nothing at all.

Three additions in ## Colour roles:

  • Roles table. One row per job (action, structure, live-now, careful, band surfaces, chrome), with the light and dark value and the contrast each clears. A component can now choose from the table instead of reverse-engineering the cascade.
  • Track hues. The five track accents are in custom.css and in no deck at all. Three are the languages' own colours (Go, Rust, Haskell), two are ours. Documented as marks and washes only, never body text, with the reason each hue carries a light and a dark value.
  • Dark theme tokens. Infima declares its dark tokens on html[data-theme='dark'] (specificity 0,1,1), so a bare [data-theme='dark'] block is 0,1,0 and loses every contested token silently. That failure shipped once, leaving the warning callouts on Infima mustard.

Two restrictions resolved:

Restriction State What changed
"No gradients." Already true custom.css has no linear-gradient since the footer went solid Shadow. The line now says so instead of reading as an unenforced rule.
"No transparency or blend modes. Solid fills only." False The stylesheet carries 53 rgba() declarations: white overlays, brand-tinted shadows, midnight shadows. Restated as what the site does: solid fills under any label, alpha for depth, rings and scrims only. No code rewrite needed for the rule to be honest.

A second commit aligns design-baseline, which said vanilla was for "highlights, callouts, badges" and blazing for "urgent CTAs". Both contradict the roles: vanilla is a fill for a live-now mark with midnight text, blazing means careful, and blue owns "you can act on this". Leaving that wording would have preserved the drift the parent change ends.

Fixes #376.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update

Testing

  • I have tested these changes locally
  • I have checked for broken links
  • Code examples have been tested

Checklist

  • My code follows the style guidelines
  • I have performed a self-review
  • I have made corresponding changes to documentation
  • My changes generate no new warnings

Verification

Every contrast figure in both tables is computed rather than copied, via scripts/contrast.py against the surface named in the column header:

#2353FF on #FFFFFF   5.60     #2353FF on #F5F3EB   5.04     #2353FF on #1D1D1B   3.02
#4D91FF on #1D1D1B   5.47     #FEC104 on #1D1D1B  10.33     #FEC104 on #FFFFFF   1.64
#FF4B11 on #FFFFFF   3.35     #F8908F on #FFFFFF   2.24     #F5F3EB on #FFFFFF   1.11
#2C2B2B on #1D1D1B   1.20     #00ADD8 on #FFFFFF   2.64     #5D4E8C on #1D1D1B   2.36
#C2185B on #FFFFFF   5.87     #F8908F on #1D1D1B   7.54     #5D4E8C on #FFFFFF   7.16
#A794DE on #1D1D1B   6.38     #CE422B on #FFFFFF   4.73     #F0764F on #1D1D1B   5.96
#0B87AD on #FFFFFF   4.13     #45C4E6 on #1D1D1B   8.27

Two figures moved from the issue body after measuring: Haskell purple on midnight is 2.36:1, not 1.97:1, and the dark track column is stated against #1D1D1B explicitly, because the same overlay measured against #2C2B2B reads lower (6.30 against 7.54 for Raspberry) and the column would otherwise be ambiguous.

The gradient claim was checked against the tree rather than assumed: grep -c linear-gradient website/src/css/custom.css returns 0.

Notes

  • This PR changes no stylesheet and no component. Nothing renders differently.
  • .agents/** is outside the PR build's path filter, so no workflow runs on this PR. The check that matters here is the arithmetic above, not a build.
  • The alpha restatement does not require touching the 53 declarations. It describes the use they are already put to, and the two solid-fill exceptions (warning panels) were already in place.

The guide listed the swatches by name and hex and never said what any of
them was for. That knowledge lived in comments inside custom.css, where
someone about to touch the stylesheet cannot see it, and where an agent
reads nothing.

Adds a Colour roles section: one row per job, light and dark value, and
the contrast each one clears, so a component can pick a colour from the
table instead of reverse-engineering the cascade.

Adds the five track hues, which exist in custom.css and in no deck at all.
Three of them are the languages' own colours; two are ours. Marked as
marks and washes only, never body text, with the reason each hue needs a
light and a dark value.

Adds the dark-theme selector note. Infima declares its dark tokens on
html[data-theme='dark'] (0,1,1), so a bare [data-theme='dark'] block is
0,1,0 and loses every contested token silently. That bug shipped once.

Resolves the two restrictions that no longer matched the build:

- Gradients: the restriction already holds. The footer is solid Shadow and
  custom.css contains no linear-gradient. The line now says so, instead of
  reading as an unenforced rule.
- Alpha: the old "no transparency, solid fills only" is false against the
  stylesheet, which carries 53 rgba() declarations, nearly all of them
  shadows, white overlays and midnight shadows. Restated as what the site
  actually does: solid fills under any label, alpha for depth, rings and
  scrims only. No code change is needed for the rule to be true.

Contrast figures are computed, not copied: every ratio in both tables was
read off scripts/contrast.py against the surface named in the column.

Fixes IntersectMBO#376
Two rows in the accent table contradicted the roles now documented in
brand-baseline: vanilla was "highlights, callouts, badges" and blazing was
"urgent CTAs, warnings".

Vanilla is a fill for a live-now mark with midnight text, and never text on
a light surface. Blazing means careful, and is never a CTA colour, because
blue owns "you can act on this". Leaving the old wording here would have
kept the drift the parent change is trying to end.

Also restates principle 5 to match the alpha rule.

Refs IntersectMBO#376
@IanoNjuguna IanoNjuguna added the documentation Improvements or additions to documentation label Nov 22, 2026
Two rows came from IntersectMBO#376's body, written on 6 November, and the landing page
moved underneath them since:

- "Live, now" is Blazing Amber, not Vanilla. The Next session chip is
  .sessionLabel filled with --color-accent-blazing and a midnight label
  (5.04:1); the stylesheet says so in as many words, "Blazing Amber, not
  Vanilla, because the badge is a now-state rather than a highlight".
  Vanilla Sunset now has no consumer on the site at all, and the table says
  reserved rather than pretending it is in use.
- The "careful" family is the darkened end of the same hue (#C13A0B label
  on #FCE9E1, #FF8F6B in dark), so blazing carries two jobs and cannot take
  a third. That is the table's own three-meaning limit, stated there.

Also corrects the gradient line: the footer is flat brand blue like the
navbar, not Shadow. `--color-brand-primary` is on .footer and the module's
own comment says the page opens and closes on that surface.

Re-verified against main at 973801b:
  grep -c linear-gradient website/src/css/custom.css  ->  0
  --color-accent-vanilla consumers in website/src     ->  none
  .sessionLabel background                            ->  --color-accent-blazing

Refs IntersectMBO#376

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Document colour roles in the brand baseline, and resolve the gradient and alpha restrictions it contradicts

1 participant