From 4a4a939f63e54cc72aebc928dd0ffebe2a34fe6f Mon Sep 17 00:00:00 2001 From: Roland Date: Sun, 2 Aug 2026 18:02:44 -0600 Subject: [PATCH] style: spell it "color" everywhere 283 occurrences across 23 files, all of them mine and all of them in the theme/UI work: comments, test names, and a handful of local identifiers (`colours`, `roleColours`, `awaitColoured`) plus one test fixture tag named 'Uncoloured'. Nothing was required to keep the other spelling. Checked before replacing: no CSS custom property or class name contains it, no library prop or API key does, and every string holding it is a test name or our own copy. The renamed identifiers were checked for collisions with an existing `color`/`colors` in the same file first -- there were none. Verified as a pure rename: 262 lines changed, and normalising the spelling on every removed line reproduces the added line exactly, for all 262. So the diff contains no other edit hiding in it. 1134 jest / 64 suites, 271 cypress component tests with the same 12 pre-existing Semantic-era failures in Tags/Channels/Download/Inventory, clean npm run build. --- app/cypress/support/component.js | 2 +- app/src/App.css | 6 +- app/src/Tags.js | 4 +- app/src/Tags.test.js | 28 ++-- app/src/components/Common.js | 14 +- app/src/components/Common.test.js | 32 ++--- app/src/components/Nav.js | 8 +- app/src/components/ThemeSamplePage.js | 40 +++--- app/src/components/ui/Inputs.tsx | 4 +- app/src/components/ui/Surfaces.tsx | 8 +- app/src/components/ui/toast.test.js | 8 +- app/src/components/ui/ui-layout.cy.js | 178 +++++++++++++------------- app/src/components/ui/ui.css | 42 +++--- app/src/components/ui/ui.test.js | 32 ++--- app/src/test-utils.js | 2 +- app/src/test-utils.test.js | 4 +- app/src/themes/contrast.ts | 20 +-- app/src/themes/mantine.ts | 2 +- app/src/themes/map-flavor.test.js | 2 +- app/src/themes/names.ts | 4 +- app/src/themes/navColors.test.js | 32 ++--- app/src/themes/navColors.ts | 40 +++--- app/src/themes/tokens.css | 12 +- 23 files changed, 262 insertions(+), 262 deletions(-) diff --git a/app/cypress/support/component.js b/app/cypress/support/component.js index 9cacf352..49cfd9b6 100644 --- a/app/cypress/support/component.js +++ b/app/cypress/support/component.js @@ -20,7 +20,7 @@ import '../../src/themes/fonts.css'; import '../../src/themes/tokens.css'; import '@mantine/core/styles.css'; // App.js loads this too. Without it a Notification renders unstyled here, so a toast had no -// surface and no title colour of Mantine's -- and its contrast test could not fail. +// surface and no title color of Mantine's -- and its contrast test could not fail. import '@mantine/notifications/styles.css'; /* * App.js loads this as well. Rules for things outside the component library live here -- diff --git a/app/src/App.css b/app/src/App.css index 52a95e5a..a93f819f 100644 --- a/app/src/App.css +++ b/app/src/App.css @@ -63,7 +63,7 @@ html .mantine-Notifications-root[data-position^='top'] { .wrolpi-navbar-link:hover, .wrolpi-navbar-link-button:hover { - /* A translucent black works on every navbar colour, light or dark. */ + /* A translucent black works on every navbar color, light or dark. */ background: rgba(0, 0, 0, 0.12); } @@ -76,7 +76,7 @@ html .mantine-Notifications-root[data-position^='top'] { * - An anchor takes `a {color: var(--blue)}` from tokens.css, which outranks an inherited * value however the bar sets it. The search glyph is an anchor, and so is every status * icon that links to /admin -- those only looked right because they carry an inline - * colour of their own, which still wins here and is meant to. + * color of their own, which still wins here and is meant to. * - A Mantine ActionIcon paints `--ai-color`, its own themed blue. The hamburger and the * theme toggle are ActionIcons. The variable is no use as a hook: Mantine writes it * INLINE on the element, so a stylesheet declaring it loses every time (the same trap @@ -200,7 +200,7 @@ pre.wrap-text { /* * A card's title and its author/channel/domain line are links, but they are the card's - * text -- they take the body colour rather than the link colour, so a grid of cards reads + * text -- they take the body color rather than the link color, so a grid of cards reads * as titles and not as a wall of blue. This was a literal `black` until the themes * arrived, which left every title at about 1.1:1 on the dark, night and amber panels. */ diff --git a/app/src/Tags.js b/app/src/Tags.js index 4bc2beec..7eadcff9 100644 --- a/app/src/Tags.js +++ b/app/src/Tags.js @@ -117,7 +117,7 @@ export function useTags() { {...props} // onClick passed here. className={className} /* - * The contrasting text colour goes in a custom property, not in `color`. As + * The contrasting text color goes in a custom property, not in `color`. As * `color` it was an inline declaration, which no stylesheet rule can outrank -- * so night, where a tag becomes an outline over a near-black page, still got * the black text calculated for a bright tag's fill. The tag was legible only @@ -340,7 +340,7 @@ function EditTagsModal() { * `--label-text`, not `color`, for the same reason as the chip itself: * inline `color` cannot be overridden, so in night this preview showed * black text on a transparent outline over a near-black page. It is the - * preview of the colour being chosen, so being honest about how the tag + * preview of the color being chosen, so being honest about how the tag * will actually look matters here more than anywhere. */} render( const tagOf = (name) => screen.getByText(name); /* - * Wait for the fetched colours to arrive. Before they do, `NameToTagLabel` falls back to a + * Wait for the fetched colors to arrive. Before they do, `NameToTagLabel` falls back to a * plain `