-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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]: Remove bundled patterns #46450
Conversation
@jasmussen I think the best way to check would be to just disable |
Rather than trying to use a specific Gutenberg plugin for this PR, I followed what you said above and just disabled Gutenberg on a 6.1.1 install. At first, everything was working as expected, except the Header category included some "banner" patterns. I also noticed the navigation block was acting strangely, requiring that a new menu be created. After I did that, the patterns entirely broke: strange.bug.movUsing 6.1.1, no Gutenberg, TT3. It broke other pattern categories too, like Gallery, but not Buttons. |
Thanks for testing Anne! Is this something known for Pattern Directory that can be fixed? I remember similar issues before and I had the impression they were fixed.. --cc @beafialho @ryelle |
Can you point out which patterns these are? Maybe the patterns in the pattern directory need to be recategorized? (note that we haven't implemented the new categories yet, so this might be expected)
Looks like the pattern from the directory includes a
I think you're still in the Navigation block, so you're restricted to what blocks you can insert. That's why you can insert the social links pattern but nothing else. |
This should be omitted in the pattern directory, right? If it's not omitted there, then it can not work in any site that doesn't have a menu with that ref(with the PD flow to copy the pattern).
What do you mean |
I believe the nav block is created with a ref by default, either that or they were created in the directory with a menu (maybe because @beafialho has higher permissions than a regular user). We don't do anything to override the way the block is saved. In any case, I've already created an issue to fix this in the directory. |
Here are the names:
|
12f7384
to
803f7c5
Compare
@annezazu I've updated those patterns in the pattern directory, so they've been removed from the Headers category and added to the Banners. |
Noting for clarity (mainly for my future self) that we're blocked right now due to this issue that remains to resolve in the pattern directory: WordPress/pattern-directory#545 |
I also just saw this and wanted to note the banner category being added previously: #44203 |
This has been fixed in the pattern directory, so it should be good to go 👍🏻 (there might still be old patterns in cache for a few hours, in case anyone jumps on this right away) |
Thank you @ryelle! I tested and this looks good! I'd need someone else to test too and 🟢 this PR to land. -- @annezazu @jasmussen |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It works as expected. I can see core patterns loaded with and without the Gutenberg plugin.
P.S. I noticed that some patterns like "Header with hero image" are rendered broken because the image fails to load.
It seems we have the same issue for Cover blocks, as it was for |
That issue was for the pattern creator, inserting images from the Openverse media flow, and was fixed (for all images in the openverse client). The issue you're seeing sounds like this one, which should have been fixed with this PR. In fact, if you copy the pattern content directly from wp.org, it works. So I think there's some extra encoding/sanitization on the core side that's converting the If there's anything that should change on the API side to fix this, add a new issue here. |
I'm going to merge this for now and handle separately the link issue for |
What?
Resolves: #46017
The GB bundled patterns have been added to Pattern Directory and tagged as
core
patterns with6.1
WP version. With that we don't need to bundle them anymore.Testing Instructions
6.1
installation. Since we tagged them ascore
patterns with6.1
version in Pattern directory, they should just show up even without Gutenberg being active.Notes
In my testing it seems I've encountered this issue that some images fail to load. If that's the case for others as well and not something with my environment maybe we need to update some urls, etc.. in the Pattern Directory patterns?