[wp-trac] [WordPress Trac] #60854: Block Hooks: Allow insertion as first or last child of Template Part block
WordPress Trac
noreply at wordpress.org
Tue Jul 2 10:01:33 UTC 2024
#60854: Block Hooks: Allow insertion as first or last child of Template Part block
-----------------------------+------------------------------
Reporter: Bernhard Reiter | Owner: Bernhard Reiter
Type: enhancement | Status: closed
Priority: normal | Milestone: 6.7
Component: General | Version:
Severity: normal | Resolution: fixed
Keywords: has-patch | Focuses:
-----------------------------+------------------------------
Changes (by Bernhard Reiter):
* owner: (none) => Bernhard Reiter
* status: new => closed
* resolution: => fixed
Comment:
In [changeset:"58614" 58614]:
{{{
#!CommitTicketReference repository="" revision="58614"
Block Hooks: Allow child insertion into Template Part block.
The Block Hooks mechanism was previously extended to allow insertion of a
block as a Navigation block's first or last child. This was implemented by
storing the `ignoredHookedBlocks` array in the corresponding
`wp_navigation` post's post meta (instead of a metadata attribute on the
anchor block).
This changeset extends that mechanism to Template Part blocks, by storing
said metadata in the corresponding `wp_template_part` post's post meta,
thus allowing extenders to use Block Hooks to insert a block as a Template
Part block's first or last child, respectively.
Props tomjcafferkey, bernhard-reiter.
Fixes #60854.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/60854#comment:8>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list