Newsletter: Drop dead admin-ui build-style import; pin admin-ui 2.1.0#49007
Conversation
|
Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.
Interested in more tips and information?
|
|
Thank you for your PR! When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:
This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖 Follow this PR Review Process:
If you have questions about anything, reach out in #jetpack-developers for guidance! |
Code Coverage SummaryThis PR did not change code coverage! That could be good or bad, depending on the situation. Everything covered before, and still is? Great! Nothing was covered before? Not so great. 🤷 |
68c10f4 to
43000ac
Compare
The 2-line explanatory comment described a removed @include line; with that line gone there is nothing for the comment to clarify.
43000ac to
e01d7ff
Compare
Proposed changes
Consumer-side adaptation for
@wordpress/admin-ui2.x in the Newsletter package. The dashboard SCSS currently@includes a stylesheet that no longer exists in admin-ui 2.x:admin-ui 2.x ships its CSS via runtime DOM injection from the JS module — the
build-style/directory was removed from the package's exports. Once@wordpress/admin-uiis bumped, the SCSS pipeline 404s on that import and the dashboard build fails.Two changes:
meta.load-cssline inprojects/packages/newsletter/routes/dashboard/route.scssand leave a brief comment explaining why. The@wordpress/dataviews/build-style/style.cssimport next to it stays — dataviews still ships that file and the import is correct.@wordpress/admin-uiinprojects/packages/newsletter/package.jsonfrom1.12.0to2.1.0. The package's<AdminPage>use is through@automattic/jetpack-components, which already targets admin-ui 2.x — this is just the consumer-side declaration.This mirrors the precedent fix landed for
packages/scanin commit626cb33ea84(#48410). This is not the monorepo-wide bump — that's #48404's job.Related product discussion/links
visualprop for Jetpack logo #48410 (commit626cb33ea84, merged 2026-05-07)Does this pull request change what data or activity we track or use?
No.
Testing instructions
pnpm install.pnpm jetpack build packages/newsletter. Build completes successfully (SCSS@includeno longer 404s).build/newsletter.cssis non-empty and contains the dataviews styles (they're still loaded viameta.load-css)./wp-admin/admin.php?page=jetpack-newsletter-dashboard) and verify the Subscribers list and inspector panel still render with the expected admin-ui-driven layout. admin-ui 2.x injects its base styles at runtime — no static stylesheet to load.