cmarteepants opened a new pull request, #64232:
URL: https://github.com/apache/airflow/pull/64232

   Previously the `Theme` model only accepted `tokens.colors.brand`, forcing
   distributors to use fragile `globalCss` CSS-variable hacks to customize
   neutral surfaces, borders, and the gray palette.
   
   This PR introduces a `ThemeColors` sub-model accepting `brand`, `gray`,
   `black`, and `white` — all optional, with at least one required. Existing
   brand-only configs continue to work unchanged.
   
   ### Changes
   
   - `types.py`: Extract `ThemeColors` Pydantic sub-model with `brand` 
(11-shade scale), `gray` (11-shade scale), `black` (single shade), and `white` 
(single shade) — all optional. A `@model_validator` rejects an empty `colors: 
{}`. A `@model_serializer` excludes `None` fields from the serialized output 
for a clean JSON response.
   - `test_types.py`: Add `TestThemeColors` and `TestTheme` test classes 
covering valid/invalid inputs and serialization round-trips.
   - `test_config.py`: Add a test verifying gray/black/white tokens pass 
through the config endpoint.
   - `customize-ui.rst`: Document the new tokens and add example config.
   - Regenerate `_private_ui.yaml`, `schemas.gen.ts`, and `types.gen.ts`.
   
   ### Backwards compatibility
   
   Existing configs with only `brand` continue to work without any changes.
   
   ---
   
   ##### Was generative AI tooling used to co-author this PR?
   
   - [X] Yes — Claude Code (claude-sonnet-4-6)
   
   Generated-by: Claude Code (claude-sonnet-4-6) following [the 
guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#gen-ai-assisted-contributions)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to