Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Patterns API: Add 'inserter' to the schema #40416

Merged
merged 2 commits into from
Apr 18, 2022

Conversation

Mamaduka
Copy link
Member

What?

Fixes #40414.

PR adds the missing inserter field to the Patterns item schema.

Why?

Currently, this field is omitted from the response, and patterns that should be hidden in the inserter are visible.

Testing Instructions

  1. Activate the TT2 theme.
  2. Open a post editor.
  3. Open the Pattern Explorer.
  4. Confirm that the "Uncategorized" section isn't visible.

@Mamaduka Mamaduka self-assigned this Apr 18, 2022
@Mamaduka Mamaduka added [Type] Bug An existing feature does not function as intended Core REST API Task Task for Core REST API efforts [Feature] Patterns A collection of blocks that can be synced (previously reusable blocks) or unsynced labels Apr 18, 2022
@Mamaduka Mamaduka requested review from ndiego and jsnajdr April 18, 2022 13:14
@ndiego
Copy link
Member

ndiego commented Apr 18, 2022

Thanks for this @Mamaduka! This PR fixes the root issue, both for patterns registered via JS and PHP in the /patterns folder. I have approved assuming any relevant failed tests are resolved. The two that are currently failing appear unrelated.

@ndiego
Copy link
Member

ndiego commented Apr 18, 2022

@Mamaduka, once merged, let's add the backport tag. This should get in 6.0.

@Mamaduka
Copy link
Member Author

Thanks, @ndiego. I think those are flaky tests.

@Mamaduka Mamaduka force-pushed the fix/patterns-api-inserter-schema branch from 8db2271 to c3a085c Compare April 18, 2022 14:32
@Mamaduka Mamaduka merged commit fad579f into trunk Apr 18, 2022
@Mamaduka Mamaduka deleted the fix/patterns-api-inserter-schema branch April 18, 2022 15:28
@Mamaduka Mamaduka added the Backport to WP 6.6 Beta/RC Pull request that needs to be backported to the WordPress major release that's currently in beta label Apr 18, 2022
@github-actions github-actions bot added this to the Gutenberg 13.1 milestone Apr 18, 2022
@Mamaduka
Copy link
Member Author

@adamziel, @gziolo, here's WP core PR - WordPress/wordpress-develop#2600.

@gziolo gziolo removed the Backport to WP 6.6 Beta/RC Pull request that needs to be backported to the WordPress major release that's currently in beta label Apr 19, 2022
@gziolo
Copy link
Member

gziolo commented Apr 19, 2022

@adamziel, @gziolo, here's WP core PR - WordPress/wordpress-develop#2600.

Actually, there is nothing to do about this PR in the context of WordPress core. Let's add the linked PR in core to the project.

pento pushed a commit to WordPress/wordpress-develop that referenced this pull request Apr 19, 2022
Backports changes from WordPress/gutenberg#40416. Adds the missing `inserter` field to the Patterns item schema. This field was omitted from the response, and patterns that should be hidden in the inserter were visible.

Props mamaduka, ndiego.
See #55567.
Follow-up [53152].




git-svn-id: https://develop.svn.wordpress.org/trunk@53210 602fd350-edb4-49c9-b593-d223f7449a82
markjaquith pushed a commit to markjaquith/WordPress that referenced this pull request Apr 19, 2022
Backports changes from WordPress/gutenberg#40416. Adds the missing `inserter` field to the Patterns item schema. This field was omitted from the response, and patterns that should be hidden in the inserter were visible.

Props mamaduka, ndiego.
See #55567.
Follow-up [53152].



Built from https://develop.svn.wordpress.org/trunk@53210


git-svn-id: http://core.svn.wordpress.org/trunk@52799 1a063a9b-81f0-0310-95a4-ce76da25c4cd
github-actions bot pushed a commit to gilzow/wordpress-performance that referenced this pull request Apr 19, 2022
Backports changes from WordPress/gutenberg#40416. Adds the missing `inserter` field to the Patterns item schema. This field was omitted from the response, and patterns that should be hidden in the inserter were visible.

Props mamaduka, ndiego.
See #55567.
Follow-up [53152].



Built from https://develop.svn.wordpress.org/trunk@53210


git-svn-id: https://core.svn.wordpress.org/trunk@52799 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Core REST API Task Task for Core REST API efforts [Feature] Patterns A collection of blocks that can be synced (previously reusable blocks) or unsynced [Type] Bug An existing feature does not function as intended
Projects
No open projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Patterns with Inserter: false are visible in Inserter with Gutenberg 13.0
3 participants