Repository navigation
Fix - Block editor never loads the theme fonts and ignores the primary color - #96
Conversation
…ds the theme fonts Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Unresolved moderate issues remain in dynamic color handling and regression-test coverage.
Review effort: Lite
Findings: 2
Open (2)
What changed in this PR
Fixes block-editor font, typography, and Customizer color parity with the front end.
Changes:
- Moves editor assets to
enqueue_block_assetswith versioned CSS. - Adds dynamic primary-color and page-title styles.
- Updates editor typography and form styling.
- Adds E2E coverage and QA mapping.
| File | Summary |
|---|---|
tests/e2e/utils/wp.ts |
Adds WordPress admin/API test helpers. |
tests/e2e/specs/block-editor/customizer-styles.spec.ts |
Adds editor/front-end style coverage; moderate gaps remain around custom colors, fonts, quotes, and submit controls. |
style-editor-block.css |
Aligns editor typography and form styling. |
inc/functions.php |
Enqueues editor assets and dynamic CSS; moderate issues remain for button colors and case-insensitive default-color handling. |
.themegrill-qa/suite.json |
Registers the block-editor QA area. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
|
Tested this on a local site: the editor now gets the Roboto fonts and the primary colour, nothing loads on other admin pages or the front end, nice. One thing in Also the spec never sets a non-default primary colour, so the colour rules aren't covered. Setting a colour in the spec and checking a link in the editor would cover it. |
…saved primary color on a post and a page in the editor spec Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
|
Thanks @deepench, both fixed.
|

Fixes the Free side of themegrill/accelerate-pro#47 (Pro fix: themegrill/accelerate-pro#131).
Reported by @iamprazol.
Cause: the editor's Roboto link was enqueued on a hook whose styles never reach the editor iframe, so no theme font loaded (a system font showed), and the Customizer primary color never reached the editor. The static title rule never matched (title showed 30px, front end 26px), lists/tables/buttons used weight 400 instead of 300, and form fields had no theme font/color.
Fix (same as the Pro PR and Spacious/Flash/Radiate):
enqueue_block_assets(admin only), so they reach the iframe without the "added to the iframe incorrectly" warning. Handles unchanged; the stylesheet is now versioned.accelerate_block_editor_dynamic_css(): the primary color for links, classic quotes and submit buttons (the Quote block keeps green, like the front end); a page title uses the H1 size like the front end. Nothing is output at defaults for posts.style-editor-block.css: title selector, text weight, form fields.Proof — yellow badges are live computed values (font · size · color), primary color #d63384:
develop)How to test: set Customize → primary color, publish, open a post with a paragraph link, a classic-block quote and a Search block. Editor now matches the front end and Roboto/Roboto Slab load; on
developthe link stays green and a system font shows.Testing done: editor vs front end on a post and a page, default and custom primary color: 0 mismatches except the Code block font (static, unrelated, same as
develop);develophad 7–8. Front end identical todevelop. New@freshspecblock-editor/customizer-stylesfails ondevelop, passes 2/2 here; full suite passes. It reusestests/e2e/utils/wp.tsbyte-identical to #95, so the two PRs merge cleanly. PHPCS:inc/functions.php142→141 errors, 62→61 warnings; PHPCompatibility 7.4+ clean.Changelog: Fix - Block editor now loads the theme fonts and shows the Customizer primary color.
🤖 Generated with Claude Code