Repository navigation
Previous link was incorrect - #8710
Merged
Merged
Conversation
dereksmart
approved these changes
Feb 1, 2018
Member
|
cherry-picked to |
2 of 3 tasks
CGastrell
added a commit
that referenced
this pull request
May 13, 2026
…okens + hex fallback) The previous commit switched to --wpds-color-fg-content-success / -error / -warning / -info, but those are the "ink" tokens used as text on tinted backgrounds in alerts/badges — they resolve to near-black hexes (e.g. success = #2900) and are visually indistinguishable from `color: inherit` for a small dot + label. The Status indicator is a standalone color-coded element on a plain admin-page background, so it needs the recognizable shade family — the *-weak tokens: success-weak = #8030 ≈ --jp-green-50 (#8710) error-weak = #cc1818 ≈ --jp-red-50 (#d63638) warning-weak = #926300 ≈ --jp-yellow-* (warm amber) info-weak = #006bd7 ≈ --jp-blue-* (link blue) neutral-weak = #707070 ≈ --jp-gray-50 (#646970) In addition, the legacy Jetpack settings dashboard (which hosts the WAF standalone-mode indicator and the Pro Status panel) does NOT load `@wordpress/theme/design-tokens.css` at all — so any --wpds-* variable resolves to empty/initial there, and the indicator falls back to `color: inherit`. Add a hex fallback inside each var(--wpds-…, #rrggbb) so the legacy dashboard renders the right shade without depending on the design-tokens stylesheet being enqueued. Verified in DevTools on the live dev site: - /wp-admin/admin.php?page=jetpack-protect#/scan → indicator color now rgb(0, 128, 48) (was rgb(0, 41, 0) near-black). - /wp-admin/admin.php?page=jetpack-protect#/firewall → same. - /wp-admin/admin.php?page=jetpack (legacy dashboard) → WPDS token resolves empty but the #8030 fallback paints correctly. Also update the @deprecated JSDoc on the Status component to point at the *-weak tokens and to mention the hex-fallback requirement.
CGastrell
added a commit
that referenced
this pull request
May 18, 2026
…okens + hex fallback) The previous commit switched to --wpds-color-fg-content-success / -error / -warning / -info, but those are the "ink" tokens used as text on tinted backgrounds in alerts/badges — they resolve to near-black hexes (e.g. success = #2900) and are visually indistinguishable from `color: inherit` for a small dot + label. The Status indicator is a standalone color-coded element on a plain admin-page background, so it needs the recognizable shade family — the *-weak tokens: success-weak = #8030 ≈ --jp-green-50 (#8710) error-weak = #cc1818 ≈ --jp-red-50 (#d63638) warning-weak = #926300 ≈ --jp-yellow-* (warm amber) info-weak = #006bd7 ≈ --jp-blue-* (link blue) neutral-weak = #707070 ≈ --jp-gray-50 (#646970) In addition, the legacy Jetpack settings dashboard (which hosts the WAF standalone-mode indicator and the Pro Status panel) does NOT load `@wordpress/theme/design-tokens.css` at all — so any --wpds-* variable resolves to empty/initial there, and the indicator falls back to `color: inherit`. Add a hex fallback inside each var(--wpds-…, #rrggbb) so the legacy dashboard renders the right shade without depending on the design-tokens stylesheet being enqueued. Verified in DevTools on the live dev site: - /wp-admin/admin.php?page=jetpack-protect#/scan → indicator color now rgb(0, 128, 48) (was rgb(0, 41, 0) near-black). - /wp-admin/admin.php?page=jetpack-protect#/firewall → same. - /wp-admin/admin.php?page=jetpack (legacy dashboard) → WPDS token resolves empty but the #8030 fallback paints correctly. Also update the @deprecated JSDoc on the Status component to point at the *-weak tokens and to mention the hex-fallback requirement.
CGastrell
added a commit
that referenced
this pull request
May 18, 2026
…#48711) * Componentry: migrate Status to @wordpress/ui Text in plugin consumers Part of #48160. Replace the internal Jetpack Status component (from @automattic/jetpack-components) with inline JSX using Text from @wordpress/ui plus a small colour-coded indicator span in the six consumer sites in plugins/protect and plugins/jetpack: - protect: AdminSectionHero storybook, firewall hero, scan hero, scan history hero -- single Status sites, inline style blocks keep the same var(--jp-green-50|gray-50) colour vars, 0.666em indicator, font-weight 600, and line-height 1.666 as the wrapper SCSS. - jetpack: security/waf "Standalone mode" label -- inline style, preserves the waf__standalone__mode className. - jetpack: pro-status renders four different status states; co-locate a style.module.scss mirroring the wrapper's status colour map (is-active|inactive|error|action|initializing) so the four call sites stay terse. Also drop the dead text prop on the legacy rewind status site (the original wrapper only ever read "label") and fall back to the now-explicit default label per status. Annotate the Status source in js-packages/components with an @deprecated JSDoc block (mirroring the Chip -> Badge pattern from #48162) so external consumers see the guidance without breaking on upgrade. Implementation, styles, stories, and barrel export are otherwise unchanged. * Componentry: address review - design tokens + CSS classes (no inline styles) - Replace all --jp-* color vars with --wpds-color-fg-content-* design tokens (success/error/warning/info/neutral-weak) in pro-status and protect heroes. - waf.jsx: drop the inline style blocks; move styling under the existing .waf__standalone__mode class in _inc/client/security/style.scss. - Protect heroes: extract a small AdminSectionHero.StatusIndicator helper co-located with the existing admin-section-hero module so the four consumers (storybook, firewall, scan, scan history) share one CSS source instead of duplicating inline style blocks. - Update the @deprecated JSDoc on the Status component to point at the new WPDS tokens so future consumers do not reintroduce --jp-*. Addresses review comments r3228168471, r3228177952, r3228180635 on PR #48711. * Componentry: fix Status indicator color regression (use *-weak WPDS tokens + hex fallback) The previous commit switched to --wpds-color-fg-content-success / -error / -warning / -info, but those are the "ink" tokens used as text on tinted backgrounds in alerts/badges — they resolve to near-black hexes (e.g. success = #2900) and are visually indistinguishable from `color: inherit` for a small dot + label. The Status indicator is a standalone color-coded element on a plain admin-page background, so it needs the recognizable shade family — the *-weak tokens: success-weak = #8030 ≈ --jp-green-50 (#8710) error-weak = #cc1818 ≈ --jp-red-50 (#d63638) warning-weak = #926300 ≈ --jp-yellow-* (warm amber) info-weak = #006bd7 ≈ --jp-blue-* (link blue) neutral-weak = #707070 ≈ --jp-gray-50 (#646970) In addition, the legacy Jetpack settings dashboard (which hosts the WAF standalone-mode indicator and the Pro Status panel) does NOT load `@wordpress/theme/design-tokens.css` at all — so any --wpds-* variable resolves to empty/initial there, and the indicator falls back to `color: inherit`. Add a hex fallback inside each var(--wpds-…, #rrggbb) so the legacy dashboard renders the right shade without depending on the design-tokens stylesheet being enqueued. Verified in DevTools on the live dev site: - /wp-admin/admin.php?page=jetpack-protect#/scan → indicator color now rgb(0, 128, 48) (was rgb(0, 41, 0) near-black). - /wp-admin/admin.php?page=jetpack-protect#/firewall → same. - /wp-admin/admin.php?page=jetpack (legacy dashboard) → WPDS token resolves empty but the #8030 fallback paints correctly. Also update the @deprecated JSDoc on the Status component to point at the *-weak tokens and to mention the hex-fallback requirement.
DevinWalker
added a commit
that referenced
this pull request
Oct 20, 2026
… from the design system - Get started, Continue and Go to My Jetpack take their green from a ThemeProvider seeded #8710, the same seed the feature switches use, instead of overriding @wordpress/ui's internal --wp-ui-button-* colours. - The generated disabled pair comes from the background ramp, so the seed can't move it (2.7:1). Continue, the only one that shows a disabled state, keeps the 4.2:1 pair. - The finish summary is a Card.Root rendered as a list, with Stack rows.
DevinWalker
added a commit
that referenced
this pull request
Oct 20, 2026
… from the design system - Get started, Continue and Go to My Jetpack take their green from a ThemeProvider seeded #8710, the same seed the feature switches use, instead of overriding @wordpress/ui's internal --wp-ui-button-* colours. - The generated disabled pair comes from the background ramp, so the seed can't move it (2.7:1). Continue, the only one that shows a disabled state, keeps the 4.2:1 pair. - The finish summary is a Card.Root rendered as a list, with Stack rows.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix incorrect blog post link