design: convert Themes/Controls.xaml to tokens (surface 1 of the sweep)
The theme file that every control inherits is now token-driven: 73 hardcoded colours became Brush.* references, and the two role changes the standard requires landed here first. - Red leaves the chrome. The seven #e94560 sites (base button, focus borders, checked box and segment backgrounds, the selected-layer accent strip) were all interactive/selection roles, so they are blue now. Red stays for live/record only. - The slider was green: its fill and gloss knob are blue now, with the track on SurfaceContainerLowest. The old green fill predated the standard. - The pill toggle was ON = green, OFF = red — a settings control using the live colour. It is now OFF = neutral surface, ON = blue. - Added scrim-soft/scrim-strong tokens (#22FFFFFF/#26FFFFFF) for the existing white washes, and Color.* resources for the two gradients (a GradientStop needs a Color, not a Brush). Guard: DesignTokensTests gains Converted_surfaces_carry_no_raw_colour — a declared list of converted files, so each sweep commit is guarded as it lands instead of waiting for one global grep at the end. Pure white/black highlights are the only allowed literals. No layout, spacing or behaviour change: this unit is colour only.
This commit is contained in:
@@ -21,6 +21,8 @@
|
||||
<SolidColorBrush x:Key="Brush.SurfaceBright" Color="#31394d"/>
|
||||
<SolidColorBrush x:Key="Brush.Outline" Color="#334155"/>
|
||||
<SolidColorBrush x:Key="Brush.OutlineVariant" Color="#1e293b"/>
|
||||
<SolidColorBrush x:Key="Brush.ScrimSoft" Color="#22FFFFFF"/>
|
||||
<SolidColorBrush x:Key="Brush.ScrimStrong" Color="#26FFFFFF"/>
|
||||
|
||||
<!-- Text -->
|
||||
<SolidColorBrush x:Key="Brush.OnSurface" Color="#dae2fd"/>
|
||||
@@ -39,6 +41,11 @@
|
||||
<SolidColorBrush x:Key="Brush.ErrorContainer" Color="#93000a"/>
|
||||
<SolidColorBrush x:Key="Brush.OnError" Color="#ffdad6"/>
|
||||
|
||||
<!-- Colours (for gradients that cannot take a brush) -->
|
||||
<Color x:Key="Color.Background">#0b1326</Color>
|
||||
<Color x:Key="Color.Tertiary">#38bdf8</Color>
|
||||
<Color x:Key="Color.SurfaceContainerLowest">#060e20</Color>
|
||||
|
||||
<!-- Meter bands (measured levels, never gain settings) -->
|
||||
<SolidColorBrush x:Key="Brush.Meter.Nominal" Color="#38bdf8"/>
|
||||
<SolidColorBrush x:Key="Brush.Meter.Caution" Color="#ffb95f"/>
|
||||
|
||||
Reference in New Issue
Block a user