Card: Set default foreground color on root#77013
Conversation
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
|
Size Change: +11 B (0%) Total Size: 7.74 MB
ℹ️ View Unchanged
|
|
Flaky tests detected in 9adf9f3. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/23946674201
|
What?
Sets
color: var(--wpds-color-fg-content-neutral)onCard’s root element and removes the same declaration fromCard.Titleso everything contained inherits from the root.Why?
Only
Card.Titlehad an explicit content foreground token. Anything else in the card that relies oncurrentColor(for example the caret icon inCollapsibleCard’s header) inheritedcolorfrom ancestors outside the card, which often stayed light-theme in dark mode. The card already sets a theme-aware background on the root; pairing default text color there keeps header and body copy, and decorative icons, aligned with the design tokens.Testing Instructions
CollapsibleCard.