design-tokens: Update dark theme background.default to pure black (#000000)#1045
design-tokens: Update dark theme background.default to pure black (#000000)#1045georgewrmarshall wants to merge 5 commits intomainfrom
Conversation
…nd sync CSS + Figma JSON; update CHANGELOG Co-authored-by: George Marshall <georgewrmarshall@users.noreply.github.com>
📖 Storybook Preview |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix prepared a fix for the issue found in the latest run.
- ✅ Fixed: Hardcoded hex breaks token reference pattern in CSS/Figma
- Replaced the hardcoded #000000 with token references: CSS now uses var(--brand-colors-black) and Figma JSON uses {black}.
Or push these changes by commenting:
@cursor push 55e000d072
Preview (55e000d072)
diff --git a/packages/design-tokens/src/css/dark-theme-colors.css b/packages/design-tokens/src/css/dark-theme-colors.css
--- a/packages/design-tokens/src/css/dark-theme-colors.css
+++ b/packages/design-tokens/src/css/dark-theme-colors.css
@@ -6,7 +6,7 @@
/* Background default should be the darkest shade, 0 elevation.
Section is +1 elevation, subsection is +2 elevation.
Alternative should be deprecated. */
- --color-background-default: #000000;
+ --color-background-default: var(--brand-colors-black);
--color-background-section: var(--brand-colors-grey-grey800);
--color-background-subsection: var(--brand-colors-grey-grey700);
--color-background-alternative: var(--brand-colors-grey-grey1000);
diff --git a/packages/design-tokens/src/figma/darkTheme.json b/packages/design-tokens/src/figma/darkTheme.json
--- a/packages/design-tokens/src/figma/darkTheme.json
+++ b/packages/design-tokens/src/figma/darkTheme.json
@@ -1,7 +1,7 @@
{
"background": {
"default": {
- "value": "#000000",
+ "value": "{black}",
"type": "color",
"parent": "Theme Colors/Dark mode",
"description": "For default neutral surface."You can send follow-ups to the cloud agent here.
Reviewed by Cursor Bugbot for commit bbc33d1. Configure here.
| Section is +1 elevation, subsection is +2 elevation. | ||
| Alternative should be deprecated. */ | ||
| --color-background-default: var(--brand-colors-grey-grey900); | ||
| --color-background-default: #000000; |
There was a problem hiding this comment.
Hardcoded hex breaks token reference pattern in CSS/Figma
Low Severity
The CSS --color-background-default is now hardcoded to #000000 instead of using var(--brand-colors-black), and the Figma JSON uses "#000000" instead of "{black}". Every other background token in both files references its brand color via the token system (var(--brand-colors-grey-grey800), {grey.800}, etc.), and the previous value itself was var(--brand-colors-grey-grey900). The JS file correctly uses brandColor.black. This inconsistency means a future change to --brand-colors-black would update JS tokens but leave CSS and Figma stale.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit bbc33d1. Configure here.
…t in CSS and Figma Applied via @cursor push command
📖 Storybook Preview |
…release PR) Co-authored-by: George Marshall <georgewrmarshall@users.noreply.github.com>
📖 Storybook Preview |
…tisfy tests; JS uses brandColor.black Co-authored-by: George Marshall <georgewrmarshall@users.noreply.github.com>
📖 Storybook Preview |
|
@metamaskbot publish-preview |
📖 Storybook Preview |
|
Preview builds have been published. See these instructions for more information about preview builds. Expand for full list of packages and versions. |



Description
Dark theme background/default has been updated from grey900 to pure black
#000000across the design tokens package:src/js/themes/darkTheme/colors.tsnow setsbackground.defaulttobrandColor.black.src/css/dark-theme-colors.cssmaps--color-background-defaultto#000000.src/figma/darkTheme.jsonbackground.default.valueupdated to#000000so tests and docs stay in sync.This change is intended to support A/B testing and preview builds for MetaMask with a pure black background and to facilitate producing an
@metamask-previewspackage for mobile and extension test builds.Manual testing steps
Screenshots
Before
After
Notes
Comment
@metamaskbot publish-previewto trigger the preview build workflow and publish the@metamask-previewspackage for review.Slack Thread