test(web): hold the palette against new raw colours - #90
Open
42-v wants to merge 1 commit into
Open
Conversation
The UI plan asked for a lint forbidding colour outside the palette and put the count at thirteen raw escapes across five files. Measured, it is six in two non-test files, and every one of them has to stay literal: four are the Google mark on the sign-in button, where re-hueing a trademark is not a theming decision, and two are the TOTP QR colours, which an encoder consumes directly and which have to decode off any background -- that being the defect that put them there in the first place. So a gate written to the plan's wording would have flagged six pieces of correct markup. This holds the useful half instead: no new raw colour. The six are listed with the reason each is exempt. The listing is checked in both directions. An entry that stops matching fails the gate, because an exemption that outlives the literal it excused is how a list like this quietly becomes permission to add anything. Both directions are mutation-verified. Test files are out of scope: a test asserting an exact rendered colour is supposed to name that colour, and palette.test.ts and TwoFactorView.test.ts do exactly that.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
UI plan item D1. The plan's premise was wrong, and following it would have shipped a gate that flags correct markup.
It asked for a lint forbidding "colour outside the palette" and put the count at thirteen raw escapes across five files. Measured: six, in two non-test files — and every one has to stay literal.
LoginView.vue:69-72#4285F4#34A853#FBBC05#EA4335TwoFactorView.vue:49#0a0a0f#ffffffSo this holds the useful half instead: no new raw colour. The six are listed with the reason each is exempt.
Checked in both directions. An entry that stops matching fails the gate — an exemption that outlives the literal it excused is how a list like this quietly becomes permission to add anything. Both mutation-verified:
Test files are out of scope: a test asserting an exact rendered colour is supposed to name that colour, and
palette.test.ts/TwoFactorView.test.tsdo exactly that. Pinning them here would fight the assertions.