[wp-trac] [WordPress Trac] #61704: global-styles-inline-css rule introduces breaking changes " :root :where(body)"

WordPress Trac noreply at wordpress.org
Wed Jul 24 18:03:17 UTC 2024


#61704: global-styles-inline-css rule introduces breaking changes " :root
:where(body)"
-------------------------------------------------+-------------------------
 Reporter:  talldanwp                            |       Owner:
                                                 |  hellofromTonya
     Type:  defect (bug)                         |      Status:  reviewing
 Priority:  normal                               |   Milestone:  6.6.2
Component:  Editor                               |     Version:  6.6
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch has-testing-info has-      |     Focuses:
  unit-tests                                     |
-------------------------------------------------+-------------------------
Changes (by hellofromTonya):

 * owner:  (none) => hellofromTonya
 * status:  new => reviewing


Comment:

 == Test Report

 Patch tested: https://github.com/WordPress/wordpress-develop/pull/7061

 === Steps to Reproduce or Test
 1. View the frontend of the test site.
 2. Open the browser's DevTools.
 3. In its Inspector, select the body element and view its styles. 🐞 Bug
 occurs here.

 === Environment
 * WordPress: `trunk` and 6.6.1
 * Browser: Firefox 128.0
 * PHP: 7.4
 * Theme: TT4
 * Plugins: none

 ==== Actual Results
 When reproducing a bug/defect:
 - ❌ Error condition occurs.

 {{{
 :root :where(body) {
   background-color: var(--wp--preset--color--base);
   color: var(--wp--preset--color--contrast);
   font-family: var(--wp--preset--font-family--body);
   font-size: var(--wp--preset--font-size--medium);
   font-style: normal;
   font-weight: 400;
   line-height: 1.55;
   --wp--style--root--padding-top: 0px;
   --wp--style--root--padding-right: var(--wp--preset--spacing--50);
   --wp--style--root--padding-bottom: 0px;
   --wp--style--root--padding-left: var(--wp--preset--spacing--50);
 }
 }}}

 When testing the bugfix patch:
 - ✅ Issue resolved with patch.

 {{{
 body {
   background-color: var(--wp--preset--color--base);
   color: var(--wp--preset--color--contrast);
   font-family: var(--wp--preset--font-family--body);
   font-size: var(--wp--preset--font-size--medium);
   font-style: normal;
   font-weight: 400;
   line-height: 1.55;
   --wp--style--root--padding-top: 0px;
   --wp--style--root--padding-right: var(--wp--preset--spacing--50);
   --wp--style--root--padding-bottom: 0px;
   --wp--style--root--padding-left: var(--wp--preset--spacing--50);
 }
 }}}

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/61704#comment:10>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list