Files
zeekay 72b7ad6687 brand: refuse the upstream mark, not just its name
bin/debrand renames text. A brand is also geometry and a hex triple, and
neither is a name, so the rename walked straight past both: the upstream
wordmark sat on the OAuth consent screens, the toolbar error page and the
2FA template drawn as vector paths, and inside index.html as a data URI
that printed the logo into every visitor's browser console. `--check` was
green through all of it.

So the marks are now refused directly. check_marks() reads the three
upstream hues in every spelling they are written in here -- `#1d4aff`,
`%231D4AFF` inside a data URI, the 8-digit alpha form, and the decimal
`(245, 78, 0)` that a hex grep cannot see -- plus two path segments that
identify the wordmark even after its fills are recoloured, because
recolouring it does not debrand it. The hue match is bounded by non-hex on
both sides so the 64-char checksums in the lockfiles are not false
failures, with `%23` spelled out as the exception since it ends in a hex
digit. Exemptions go in CONTENT_ALLOWLIST with a reason, as they already
do for names; no second check script.

The decimal spelling immediately found four files no hex grep had
reported: two toolbar pills whose drop shadow was a fixed brand blue under
a var(--primary-3000) background, a clickmap overlay, and a
snapshot-history glow frozen at the old accent's value.

The tree it now refuses is clean. Decoration collapses to ink, reusing
what the fork already decided rather than inventing a hue: base.scss kept
the three brand slots and zeroed their saturation (#333 / #8f8f8f / #ccc),
and --data-color-1 is already #3d3d3d, so the quill token palette, the
charts fallback and the MCP palette converge on it instead of drifting
from it. Where the artwork itself was upstream's -- the 2FA template, the
MCP app logo, the OAuth region picker, the Stripe app icon and the five
billing plan badges -- it is replaced by the mark in
frontend/public/icons/safari-pinned-tab.svg.

Someone else's product mark keeps someone else's colours: the vendor logos
under frontend/public/services are untouched, the Hedgebox fixtures use
Hedgebox's own declared accent, and the livestream country palette stays
chromatic because it is data encoding, not decoration.

.stylelintignore gains the generated quill dist, which has never been
stylelint-clean and cannot be made so without editing generated output.
2026-08-08 16:13:57 -07:00

100 lines
2.8 KiB
Go

package ui
import "github.com/charmbracelet/lipgloss"
var (
// The mark is monochrome: accents are ink, and ink flips with the
// terminal background so it stays legible on light and dark alike.
ColorPrimary = lipgloss.AdaptiveColor{Light: "#333333", Dark: "#CCCCCC"} // Ink: titles, borders, selection
ColorSecondary = lipgloss.Color("#8F8F8F") // Mid grey, legible on either background
ColorSuccess = lipgloss.Color("#77B96C") // Green
ColorWarning = lipgloss.Color("#F1A82C") // Yellow/orange
ColorError = lipgloss.AdaptiveColor{Light: "#D32F2F", Dark: "#EF5350"} // Red, darker on light backgrounds
ColorMuted = lipgloss.Color("#6B7280") // Gray
ColorWhite = lipgloss.Color("#FFFFFF")
ColorBlack = lipgloss.Color("#000000")
// Adaptive color that works on both light and dark backgrounds
ColorText = lipgloss.AdaptiveColor{Light: "#1A1A1A", Dark: "#FFFFFF"}
// Base styles
TitleStyle = lipgloss.NewStyle().
Bold(true).
Foreground(ColorPrimary).
MarginBottom(1)
SubtitleStyle = lipgloss.NewStyle().
Foreground(ColorMuted).
MarginBottom(1)
// Box/container styles
BoxStyle = lipgloss.NewStyle().
Border(lipgloss.RoundedBorder()).
BorderForeground(ColorPrimary).
Padding(1, 2)
// Text styles
DefaultStyle = lipgloss.NewStyle().Foreground(ColorText)
BoldStyle = lipgloss.NewStyle().Bold(true)
MutedStyle = lipgloss.NewStyle().Foreground(ColorMuted)
SuccessStyle = lipgloss.NewStyle().Foreground(ColorSuccess)
ErrorStyle = lipgloss.NewStyle().Foreground(ColorError)
WarningStyle = lipgloss.NewStyle().Foreground(ColorWarning)
// Interactive elements
SelectedStyle = lipgloss.NewStyle().
Foreground(ColorPrimary).
Bold(true)
UnselectedStyle = lipgloss.NewStyle().
Foreground(ColorMuted)
// Input styles
InputPromptStyle = lipgloss.NewStyle().
Foreground(ColorPrimary).
Bold(true)
InputTextStyle = lipgloss.NewStyle().
Foreground(ColorText)
// Progress/status styles
SpinnerStyle = lipgloss.NewStyle().Foreground(ColorPrimary)
CheckmarkStyle = lipgloss.NewStyle().
Foreground(ColorSuccess).
SetString("✓")
CrossStyle = lipgloss.NewStyle().
Foreground(ColorError).
SetString("✗")
// Layout helpers
CenterStyle = lipgloss.NewStyle().
Align(lipgloss.Center)
// Help text
HelpStyle = lipgloss.NewStyle().
Foreground(ColorMuted).
MarginTop(1)
)
// Checkmark returns a styled checkmark
func Checkmark() string {
return SuccessStyle.Render("✓")
}
// Cross returns a styled cross/X
func Cross() string {
return ErrorStyle.Render("✗")
}
// Spinner returns a styled spinner character
func Spinner() string {
return SpinnerStyle.Render("◐")
}