microsoft/microsoft-ui-reactor/reactor-design

Claude Code and agent skill by microsoft/microsoft-ui-reactor

Trust tier 4
  • vendor
Source check pending

Checking that the SKILL.md file is still in the repository.

Windows 11 design rules for Reactor — theme tokens, High Contrast, typography (`Heading`/`SubHeading`/`Caption`), 4px grid, acrylic surfaces, accessibility, animation, and a code-review checklist. Use when authoring, reviewing, or fixing visual styling.

Install

npx vskill@latest install microsoft/microsoft-ui-reactor/reactor-design

SKILL.md

The same SKILL.md was published earlier as microsoft/microsoft-ui-reactor/reactor-design.

Windows 11 Design for Reactor

Author, review, and fix Reactor UI code following Windows 11 design system rules.

Reactor is a functional UI framework for WinUI 3 that builds UI entirely in C# — no XAML, no data binding, no ViewModels. UI is described with immutable Element records, composed via bare factory methods imported with using static Microsoft.UI.Reactor.Factories (TextBlock(...), VStack(...), etc.), and updated through a React-style reconciler with hooks (UseState, UseEffect, etc.).

Controlled prop note: when design examples use inputs such as
TextBox(value, setValue) or Slider(value, ...), the factory keeps the
simple call-site shape. Direct element-record reads of controlled props now
return Optional<T>; use .GetValueOrDefault(...) or .Value. See

This skill translates the Windows 11 design language into Reactor's C# projection so that apps built with Reactor look, feel, and behave like first-class Windows 11 applications.

Workflow

  1. Author new Reactor UI using the rules below.
  2. Review a PR using the checklist at the end of this file.
  3. Fix feedback by mapping issues to the specific rule and applying the correct pattern.
  4. Verify changes using the testing guidance.

Quick Scan Checklist

Check these areas early in every review:

  • Theme tokens used for all colors — no hardcoded hex strings for themed surfaces.
  • High Contrast works — no opacity, no accent colors, only system color brushes.
  • Typography uses Heading(), SubHeading(), Caption(), or WinUI style tokens — not raw FontSize/FontWeight.
  • Layout values use the 4px grid.
  • Text scaling and localization are safe — no fixed heights on text containers.
  • Shadows have elevation (Translation(0, 0, 32)).
  • Acrylic surfaces use correct background + border pairings.
  • AutomationName() set on icon-only controls.
  • Keys set on list items for stable reconciliation.

Core Rules (Always Apply)

1. Theming Is the Primary Lens

Use Theme.* tokens for all colors and brushes. Never hardcode hex colors for themed surfaces.

csharp
// Correct: theme tokens
TextBlock("Hello").Foreground(Theme.PrimaryText)
Border(child).Background(Theme.CardBackground)
Button("Action").Background(Theme.Accent)
// Wrong: hardcoded colors on themed surfaces
TextBlock("Hello").Foreground("#000000")
Border(child).Background("#FFFFFF")

Hardcoded colors are acceptable only for:

  • One-off decorative elements that intentionally ignore theming (e.g., brand logos)
  • Explicit hit-test targets (Background("#00000000") for transparent hit areas)
Theme Token Reference
⚠️ `Theme.Error`, `Theme.Success`, `Theme.Warning`, `Theme.ErrorText` do NOT exist.
Use Theme.SystemCritical (red/error), Theme.SystemSuccess (green), Theme.SystemCaution (yellow).

Text:

TokenWinUI ResourcePurpose
Theme.PrimaryTextTextFillColorPrimaryBrushPrimary body text, titles, and labels
Theme.SecondaryTextTextFillColorSecondaryBrushCaptions, subtitles, and supplementary info
Theme.TertiaryTextTextFillColorTertiaryBrushPlaceholder text and disabled secondary content
Theme.DisabledTextTextFillColorDisabledBrushText in disabled controls or inactive states
Theme.AccentTextAccentTextFillColorPrimaryBrushHyperlinks, accent-colored labels, and interactive text

Accent fill:

TokenWinUI ResourcePurpose
Theme.AccentAccentFillColorDefaultBrushPrimary accent buttons and controls at rest
Theme.AccentSecondaryAccentFillColorSecondaryBrushAccent button hover state
Theme.AccentTertiaryAccentFillColorTertiaryBrushAccent button pressed state
Theme.AccentDisabledAccentFillColorDisabledBrushDisabled accent controls

Control fill:

TokenWinUI ResourcePurpose
Theme.ControlFillControlFillColorDefaultBrushDefault rest state for standard controls
Theme.ControlFillSecondaryControlFillColorSecondaryBrushHover state of standard controls
Theme.ControlFillTertiaryControlFillColorTertiaryBrushPressed state of standard controls
Theme.ControlFillDisabledControlFillColorDisabledBrushDisabled state of standard controls
Theme.ControlFillInputActiveControlFillColorInputActiveBrushActive/focused text input field backgrounds

Surfaces & backgrounds:

TokenWinUI ResourcePurpose
Theme.SolidBackgroundSolidBackgroundFillColorBaseBrushApp and page-level background (base layer)
Theme.CardBackgroundCardBackgroundFillColorDefaultBrushCard and elevated surface backgrounds
Theme.LayerFillLayerFillColorDefaultBrushFlyout, dialog, and pane backgrounds
Theme.SubtleFillSubtleFillColorSecondaryBrushSubtle control highlights and section backgrounds
Theme.SmokeFillSmokeFillColorDefaultBrushSemi-transparent overlay behind modal dialogs

Stroke & border:

TokenWinUI ResourcePurpose
Theme.CardStrokeCardStrokeColorDefaultBrushBorders on cards and elevated containers
Theme.SurfaceStrokeSurfaceStrokeColorDefaultBrushBorders on flyouts, dialogs, and pane surfaces
Theme.DividerStrokeDividerStrokeColorDefaultBrushHorizontal or vertical dividers between content
Theme.ControlStrokeControlStrokeColorDefaultBrushBorders on interactive controls at rest
Theme.ControlStrokeSecondaryControlStrokeColorSecondaryBrushBottom edge of controls for depth effect

System signal:

TokenWinUI ResourcePurpose
Theme.SystemAttentionSystemFillColorAttentionBrushInformational indicators and badges
Theme.SystemSuccessSystemFillColorSuccessBrushSuccess states and confirmations
Theme.SystemCautionSystemFillColorCautionBrushWarning states and cautionary indicators
Theme.SystemCriticalSystemFillColorCriticalBrushError states and critical alerts
Theme.SystemNeutralSystemFillColorNeutralBrushNeutral status indicators
Theme.SystemSolidNeutralSystemFillColorSolidNeutralBrushSolid neutral fill for icons and non-text indicators

System signal backgrounds:

TokenWinUI ResourcePurpose
Theme.SystemAttentionBackgroundSystemFillColorAttentionBackgroundBrushBackground for attention/info banners
Theme.SystemSuccessBackgroundSystemFillColorSuccessBackgroundBrushBackground for success banners and info bars
Theme.SystemCautionBackgroundSystemFillColorCautionBackgroundBrushBackground for warning banners and info bars
Theme.SystemCriticalBackgroundSystemFillColorCriticalBackgroundBrushBackground for error banners and info bars
Theme.SystemNeutralBackgroundSystemFillColorNeutralBackgroundBrushBackground for neutral status banners
Theme.SystemSolidAttentionSystemFillColorSolidAttentionBackgroundBrushSolid background for high-contrast attention surfaces

For any WinUI resource not exposed as a named token, use Theme.Ref("ResourceKeyBrush").

Custom Theme Resource References
csharp
// Reference any WinUI resource by key
Border(child).Background(Theme.Ref("AcrylicBackgroundFillColorDefaultBrush"))
Border(child).WithBorder(Theme.Ref("SurfaceStrokeColorFlyoutBrush"), 1)

Theme.Ref resolutions are cached per (key, theme). If you replace or add a resource at runtime without a theme change (swap a brand dictionary, replace a brush), call Theme.NotifyResourcesChanged() afterwards so every host re-resolves it.

Per-Subtree Theme Override

Force a subtree to a specific theme variant:

csharp
// Sidebar always renders in dark theme
VStack(sidebarContent).RequestedTheme(ElementTheme.Dark)

See theme-aware-resources.md for full token list and pairing rules.

2. Lightweight Styling (Per-Control Resource Overrides)

Override control template resources using .Resources() to customize visual states without replacing the entire template:

csharp
// Correct: override button resources for a subtle button
Button("Action", onClick).Resources(r => r
.Set("ButtonBackground", Theme.SubtleFill)
.Set("ButtonBackgroundPointerOver", Theme.Ref("SubtleFillColorSecondaryBrush"))
.Set("ButtonBackgroundPressed", Theme.Ref("SubtleFillColorTertiaryBrush"))
.Set("ButtonBorderBrush", Theme.SubtleFill)
.Set("ButtonBorderBrushPointerOver", Theme.SubtleFill)
.Set("ButtonBorderBrushPressed", Theme.SubtleFill))
// Wrong: setting Background directly — loses hover/pressed/disabled states
Button("Action", onClick).Background(Theme.SubtleFill)

Resource keys target the SolidColorBrush resource (ending in Brush), not the Color.

csharp
// Correct
.Set("ButtonBackground", Theme.Ref("ControlFillColorDefaultBrush"))
// Wrong — Color, not Brush
.Set("ButtonBackground", Theme.Ref("ControlFillColorDefault"))
3. High Contrast Rules (Strict)

High Contrast users rely on a fixed set of 8 system color brushes. Your UI must work with these constraints.

Allowed HC system brushes:

BrushPurpose
SystemColorWindowTextColorBrushText on window background
SystemColorWindowColorBrushWindow/content background
SystemColorHighlightTextColorBrushSelected text foreground
SystemColorHighlightColorBrushSelection/hover background
SystemColorButtonTextColorBrushButton text
SystemColorButtonFaceColorBrushButton background
SystemColorGrayTextColorBrushDisabled/inactive text
SystemColorHotlightColorBrushHyperlinks

HC color pairings:

BackgroundForegroundUse Case
SystemColorWindowColorSystemColorWindowTextColorGeneral content
SystemColorHighlightColorSystemColorHighlightTextColorSelected/hover states
SystemColorButtonFaceColorSystemColorButtonTextColorButtons
SystemColorWindowColorSystemColorGrayTextColorDisabled content
SystemColorWindowColorSystemColorHotlightColorHyperlinks

Rules:

  • No hardcoded colors in HC mode.
  • No opacity on elements or brushes in HC — encode translucency in the alpha channel for Light/Dark only.
  • No accent colors or regular WinUI brushes in HC.
  • No gradient animations in HC — use a single system brush.
  • Use 2px border thickness for flyouts, dialogs, and cards in HC.
  • No partial theme updates — when changing Light/Dark visual resources via .Resources(), include matching HC-safe values in the same change. Don't leave HC untested.
  • Interactive containers in HC need a highlight border — for clickable cards or list items, add a SystemColorHighlightColor border in HC to indicate interactivity.
  • Empty HC dictionary is valid — when .Resources() overrides target only Light/Dark and WinUI defaults already satisfy accessibility, you don't need to add HC-specific overrides.
  • Set HighContrastAdjustment at app level to prevent system overrides:

``csharp Application.Current.HighContrastAdjustment = ApplicationHighContrastAdjustment.None; ``

Using Theme.* tokens correctly means HC usually "just works" because WinUI resolves them to appropriate system colors. Test to verify.

4. Typography Must Use Semantic Styles

Use the predefined text factories or WinUI style tokens. Never set FontSize and FontWeight directly for standard UI text.

Reactor text factories:

This is the start of the file. Read the full SKILL.md on GitHub.

Security

  • Security scanPassed, 100 of 100Pattern checks on the skill's files. Certified 25 Nov 2026.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

Repository stars
660
Repository forks
57
7-day trend score
37

Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill CERTIFIED badge
[![vskill CERTIFIED](https://verified-skill.com/api/v1/skills/microsoft/microsoft-ui-reactor/reactor-design/badge)](https://verified-skill.com/skills/microsoft/microsoft-ui-reactor/reactor-design)

Something wrong with this skill or its page? Tell us.