[wp-trac] [WordPress Trac] #59694: Merge Gutenberg #55415 - Make duotone support compatible with enhanced pagination (was: Backport Gutenberg #55415 - Make duotone support compatible with enhanced pagination)

WordPress Trac noreply at wordpress.org
Mon Oct 23 12:53:28 UTC 2023


#59694: Merge Gutenberg #55415 - Make duotone support compatible with enhanced
pagination
-------------------------------------------------+-------------------------
 Reporter:  cbravobernal                         |       Owner:
                                                 |  hellofromTonya
     Type:  defect (bug)                         |      Status:  reviewing
 Priority:  normal                               |   Milestone:  6.4
Component:  Editor                               |     Version:
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch has-unit-tests gutenberg-  |     Focuses:
  merge commit                                   |
-------------------------------------------------+-------------------------
Changes (by hellofromTonya):

 * status:  new => reviewing
 * component:  General => Editor
 * owner:  (none) => hellofromTonya
 * keywords:  has-patch has-unit-tests => has-patch has-unit-tests
     gutenberg-merge commit


Old description:

> Backport of https://github.com/WordPress/gutenberg/pull/55415
>
> This fix makes the duotone compatible with the enhanced pagination by
> making sure that the CSS is always on the page, even when the posts have
> no featured image. It also prevents the duotone from interfering with
> other blocks using wp_unique_id.
>
> With the current implementation of enhanced pagination, we are still not
> detecting the CSS corresponding to each block. Therefore, for the
> enhanced pagination to work correctly, the CSS of the blocks present in
> the Post Template must be stable on all pages.
>
> The featured image block can contain a duotone, but the duotone CSS is
> only inlined when the block is not empty. As posts can have or not have a
> featured image, if all posts on one page do not have a featured image,
> the duotone CSS will not load, and when you paginate, the CSS will not be
> applied to the posts that do have a featured image.
>
> In addition, some duotone settings use the wp_unique_id, and as it is a
> conditional use, this can break the stability of the rest of the blocks
> that use wp_unique_id causing another series of problems like those
> described in https://github.com/WordPress/gutenberg/issues/55230)

New description:

 Reference: [https://github.com/WordPress/gutenberg/pull/55415 Gutenberg PR
 55415]

 This fix makes the duotone compatible with the enhanced pagination by
 making sure that the CSS is always on the page, even when the posts have
 no featured image. It also prevents the duotone from interfering with
 other blocks using `wp_unique_id`.

 With the current implementation of enhanced pagination, the CSS
 corresponding to each block is still not detected. Therefore, for the
 enhanced pagination to work correctly, the CSS of the blocks present in
 the Post Template must be stable on all pages.

 The featured image block can contain a duotone, but the duotone CSS is
 only inlined when the block is not empty. As posts can have or not have a
 featured image, if all posts on one page do not have a featured image, the
 duotone CSS will not load, and when you paginate, the CSS will not be
 applied to the posts that do have a featured image.

 In addition, some duotone settings use the `wp_unique_id`, and as it is a
 conditional use, this can break the stability of the rest of the blocks
 that use `wp_unique_id` causing another series of problems like those
 described in https://github.com/WordPress/gutenberg/issues/55230).

--

Comment:

 Thanks for opening the ticket to merge the changes from Gutenberg into
 Core.

 Marking it for `commit` to Core's `trunk`.

 **What about backporting the change to the 6.4 branch?**

 @mikachan @cbravobernal Is this bugfix resolving a regression or break /
 error introduced during the 6.4 cycle?

 [https://make.wordpress.org/core/2023/10/17/wordpress-6-4-release-
 candidate-phase/ See Make/Core post "WordPress 6.4 Release Candidate
 Phase"]:

 >**Regressions**: bugs that have been introduced during the WordPress 6.4
 development cycle, either to existing or new features.

 Exploring the fix:

 * The change removes a conditional introduced in [56226] / #58673, i.e.
 during 6.3 cycle.
 * [56101] first introduced the `WP_Duotone` class during the 6.3 cycle.
 * The [https://github.com/WordPress/gutenberg/issues/55230 issue in
 Gutenberg] seems to be a bugfix to further address issues introduced in
 6.3. It was opened 2 weeks ago and punted to 6.4.1.

 In reviewing, it does not seem to fit within the RC guidelines. Awaiting
 more information before punting from 6.4.0 milestone.

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


More information about the wp-trac mailing list