[wp-trac] [WordPress Trac] #61829: Some layout styles have increased specificity in WordPress 6.6 within the non-iframed editor

WordPress Trac noreply at wordpress.org
Tue Aug 13 16:45:55 UTC 2024


#61829: Some layout styles have increased specificity in WordPress 6.6 within the
non-iframed editor
-------------------------------------------------+-------------------------
 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-unit-tests has-        |     Focuses:
  testing-info                                   |
-------------------------------------------------+-------------------------

Comment (by hellofromTonya):

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

 ✅ The patch generates the expected CSS (see the How section in the
 patch).

 == Generated CSS Test Results
 Here are my testing results from my [comment:3 previous test report]:

 === On the first child

 * With the custom field preference turned off:
 {{{
 :root :where(.is-layout-constrained) > :first-child {
   margin-block-start: 0;
 }

 :root :where(p) {
   margin-top: 4rem;
   margin-bottom: 4rem;
 }
 }}}

 * With the custom field preference turned on:

 {{{
 .editor-styles-wrapper :where(.is-layout-constrained) > :first-child {
   margin-block-start: 0;
 }

 .editor-styles-wrapper :where(p) {
   margin-top: 4rem;
   margin-bottom: 4rem;
 }
 }}}

 === On the middle children

 * With the custom field preference turned off:

 {{{
 :root :where(p) {
   margin-top: 4rem;
   margin-bottom: 4rem;
 }

 :root :where(.is-layout-constrained) > * {
   margin-block-start: 1.2rem;
   margin-block-end: 0;
 }
 }}}

 * With the custom field preference turned on:

 {{{
 .editor-styles-wrapper :where(p) {
   margin-top: 4rem;
   margin-bottom: 4rem;
 }

 .editor-styles-wrapper :where(.is-layout-constrained) > * {
   margin-block-start: 1.2rem;
   margin-block-end: 0;
 }
 }}}

 === On the last child

 * With the custom field preference turned off:

 {{{
 :root :where(.is-layout-constrained) > :last-child {
   margin-block-end: 0;
 }

 :root :where(p) {
   margin-top: 4rem;
   margin-bottom: 4rem;
 }

 :root :where(.is-layout-constrained) > * {
   margin-block-start: 1.2rem;
 }
 }}}

 * With the custom field preference turned on:

 {{{
 .editor-styles-wrapper :where(.is-layout-constrained) > :last-child {
   margin-block-end: 0;
 }

 .editor-styles-wrapper :where(p) {
   margin-top: 4rem;
   margin-bottom: 4rem;
 }

 .editor-styles-wrapper :where(.is-layout-constrained) > * {
   margin-block-start: 1.2rem;
 }
 }}}

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


More information about the wp-trac mailing list