mirror of
https://github.com/WordPress/WordPress.git
synced 2024-11-10 21:00:59 +01:00
f2d2f9fee6
Make layout support compatible with enhanced pagination by ensuring that generated class names are stable across pagination, even when the number of rendered posts is different. With the previous implementation of enhanced pagination, the CSS corresponding to each block was not detected. Therefore, for enhanced pagination to work correctly, the CSS of the blocks present in the Post Template must be stable on all pages. The number of posts rendered by the Query block is always the same, except in the last page, where it can be only a fraction. If any of the blocks rendered by the Post Template used the `wp_unique_id` function, the ID (which is incremental) would have been different than in the previous pages and the class names would have varied. This is remediated by this changeset by replacing the usage of `wp_unique_id` in the layout support (which is used by the Query block) with an implementation that uses IDs that are incremental only for that block. That way, the generated class names are never affected by the number of times `wp_unique_id` runs. Props luisherranz, andrewserong, isabel_brison, costdev, mukesh27, cbravobernal, hellofromTonya, jorbin. Merges [56994] to the 6.4 branch. Fixes #59681. Built from https://develop.svn.wordpress.org/branches/6.4@56995 git-svn-id: http://core.svn.wordpress.org/branches/6.4@56506 1a063a9b-81f0-0310-95a4-ce76da25c4cd |
||
---|---|---|
.. | ||
align.php | ||
background.php | ||
border.php | ||
colors.php | ||
custom-classname.php | ||
dimensions.php | ||
duotone.php | ||
elements.php | ||
generated-classname.php | ||
layout.php | ||
position.php | ||
settings.php | ||
shadow.php | ||
spacing.php | ||
typography.php | ||
utils.php |