-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Templates: fix bug with icon and outline on template replace modal #56538
Conversation
…template swap modal
@@ -82,7 +82,8 @@ function BlockPattern( { | |||
'block-editor-block-patterns-list__item', | |||
{ | |||
'block-editor-block-patterns-list__list-item-synced': | |||
pattern.id && ! pattern.syncStatus, |
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.
FYI, the fix in trunk uses a const here instead of string, but that const is part of a wider refactor that is not in 6.4 - so just using string here as a minimal targetted fix to minimise risk for minor release.
Size Change: +20 B (0%) Total Size: 1.63 MB
ℹ️ View Unchanged
|
Flaky tests detected in e76f7c6. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/7000267194
|
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.
Change LGTM and works as expected in testing!
@SiobhyB, @karmatosed this should be good for cherrypicking to 6.4.2 now, thanks. |
@glendaviesnz, I'm not on the 6.4.2 release team and am afraid I don't have the availability to help this week. I'm not sure if @karmatosed is on the team either. I'll ask about in Slack to try to find who's on the team and who can help 🙇♀️ |
Sorry @SiobhyB, I thought you were based on this comment. Thanks for pinging the release channel for me. |
What?
Fixes an issue with some templates displaying as synced patterns by mistake.
Why?
In the switch templates screen on the page editor the templates show the synced pattern icon and highlighting which is confusing to users.
This is a minimal implementation of the fix for #56380 from #56407 in order to backport to 6.4.2. The full fix included much wider changes and new constants that are not available in 6.4
How?
This screen was identifying user patterns by the presence of
pattern.id
but it turns out that some templates also have anid
field set. This PR adds atype=user
field to user patterns to more reliably identify them.Testing Instructions
User
still work as expectedScreenshots or screencast
Before:
pattern-icon-before.mp4
After:
pattern-icon-after.mp4