-
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
Pattern: unable to set name of pattern when creating a pattern from wp-admin/edit.php?post_type=wp_block #59511
Comments
@annezazu This issue should be fixed in WP6.5, right? It seems that it was added to the WP6.6 board, so I would like to move it to the WP6.5 board. |
Ah! Good catch. That was completely accidental (and likely due to me rushing to get this reported) :D |
Just noting that in the site editor (block themes), the title of the patterns is not available either. So this issue is the result of the unification of the editors. For me we should either:
This might require some design input. cc @jasmussen |
There's also one stop gap solution potentially. For classic theme, when opening the pattern for creating, we show a specific "sync status" modal. Ideally this modal should be removed at some point but for now, it can be used to set the title as well, similarly to how we set the sync status. For both of these in the site editor, the modal is shown before going to the editor when creating a pattern. |
Good one. It seems like the main place to set the pattern title is this one, from the site editor: There's also, in the site editor, the ellipsis option to rename: That does seem to be the main motivation for removing the title field in the editor. Though I'd agree with Riad, there needs to be a stop gap solution for other pathways. Is that primarily classic themes? And to Riad's suggestion, do we show that sync modal only for that flow? If yes, then that feels the obvious quick fix to this, since that modal will then conceptually be similar to the "New pattern" modal. That said, it does seem like an omission to not have an ability to edit the title of the pattern in the editor, so regardless it could be good to have something there. Whether it's an interface that's unified with what we're thinking about for titleless pages or not, something in the inspector yes perhaps. It can even be the same ellipsis menu as shown above, in an ellipsis here: After all, that inspector panel should eventually be able to absorb this details page: CC: @jameskoster for awareness. Speaking of stop-gaps, though, another option could just be to resurface the title field for patterns, always. Visually we could maybe style it a little bit. I'd be happy to collab in a PR with you @youknowriad, to address this? Let me know. Regardless, we need to fix this layout shift: (It's probably margin present on the appender that disappears when replaced with the paragraph.) |
cc @ntsekouras would you be able to help with this one? |
I noticed this as well when working with a customer today. They were used to manage patterns from /wp-admin/edit.php?post_type=wp_block (added #59545 based on the feedback) and they were creating patterns from there, but then they had to go back to the Site Editor to rename each pattern.
@youknowriad yes, but editing a Pattern from the Site Editor surfaces the Command Palette with the Pattern title and clicking on it will allow users to rename it: But when starting from wp-admin, the Command Palette doesn't show up: |
@liviopv Good point, currently the "Document Bar" is not shown in the post editor and it's one other thing we need to unify with the site editor. The command palette is loaded though and can be triggered using the shortcut. |
After reading the discussion, IMO we have to:
Regarding the renaming I observed one more difference in the inspector panel, when we have the @jasmussen should we show the summary in site editor too? I think we should probably show it in both editors and also add the pattern's name above with either an elipsis menu next to it with the rename action, or follow the same pattern with the Alternatively we could unify the |
I'd tend toward unification, and I'd be tempted to just visually polish these up in the canvas, have the features remain, and then look to potentially refactoring them into more permanent locations, such as a new and improved document inspector that would also be available in list views. |
@jasmussen sorry but it's not clear to me what is the suggestion for where to place the |
This rename dropdown, currently available in the site editor for each individual pattern: This could be available here: just like it is for navigation: However I could also see those detail drilldown pages being moved in the future, and be absorbed entirely into the fullscreen editor page inspector. So I could also see it being here: I.e. in that block description field it would be Let me know if that makes sense, I'm juggling a couple of other things otherwise I'd put together a better (than ASCII) mockup. |
Let's try to split the work needed to two things: 1- Mandatory things for 6.5: Solution could be to show the "title" within the pattern editor. |
I'm happy to collaborate on a branch that simply unhides the title field from the canvas again. I believe I can CSS that up to work well. |
I'll open a PR soon and let's continue there to test things out. |
Closing this one for now. Next step for 6.6 is to actually use the site editor page for patters for classic themes. |
When going through the pattern creation flow in wp-admin/edit.php?post_type=wp_block (not what's available in the site editor), there is no ability to set a title for the pattern. This is using WordPress 6.5 beta 3. If you use 6.4.3, a title field is available. Below is a video that walks (and talks) you through it:
pattern.title.missing.mp4
This is a regression and something that needs to be fixed for 6.5 so automatically adding to the to do column. Without a name, it becomes much harder to find the pattern you created!
The text was updated successfully, but these errors were encountered: