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

Template part transforms #29249

Closed
1 of 4 tasks
jameskoster opened this issue Feb 23, 2021 · 4 comments
Closed
1 of 4 tasks

Template part transforms #29249

jameskoster opened this issue Feb 23, 2021 · 4 comments
Labels
[Block] Template Part Affects the Template Parts Block Needs Design Feedback Needs general design feedback. [Type] Discussion For issues that are high-level and not yet ready to implement.

Comments

@jameskoster
Copy link
Contributor

jameskoster commented Feb 23, 2021

I think it may be worth discussing and exploring the transform options for template parts. Currently the transform menu includes options to transform template parts in to Columns or Group blocks:

Screenshot 2021-02-23 at 10 14 43

However, neither of this options work. Selecting one just kicks you back to the wp-admin Dashboard 🐛

Should it be possible to transform template parts into other, non-template-part blocks at all? This seems like a potentially dangerous operation that might be better left to the "Detach blocks from template part" option in the ellipsis menu:

Screenshot 2021-02-23 at 10 20 46


One transformation that should be possible in one way or another is switching template part variations. In previous issues the following design has been posited as an option to do this:


Closely related – in #28737 we are exploring how patterns that are contextually relevant to the selected template might be exposed via the transform menu.


Finally, in #27397 (comment) @mtias questioned whether it should be possible to quickly/easily wrap a template part inside another block. As @jasmussen mentioned, this could be useful for things like Sidebar template parts. My personal feeling is that this could possibly be better handled by the aforementioned patterns flow, as it is not a transform in the traditional sense, but it is worth discussing.

Tentative action plan

@jameskoster jameskoster added Needs Design Feedback Needs general design feedback. [Type] Discussion For issues that are high-level and not yet ready to implement. [Block] Template Part Affects the Template Parts Block labels Feb 23, 2021
@carolinan
Copy link
Contributor

Image 3:
Is it currently possible to create block variations of template parts in the editor/UI?

Or only by registering the block variations in the theme? Registering variations in a theme is more complex than creating a header in the editor and saving it.

Or are these separate template parts (as HTML files or created in the editor), not block variations ?

@jameskoster
Copy link
Contributor Author

Apologies, probably poor word choice there on my part. They are variations in spirit, but not technically block variations.

Is it currently possible to create block variations of template parts in the editor/UI?

Once #29159 lands, it will be possible to assign multiple template parts to a single area. These would consequently be switchable per template as described in the OP.

@overclokk
Copy link

Should it be possible to transform template parts into other, non-template-part blocks at all?

No, This should not do any transform, a template parts should only include a template and nothing more, "Detach blocks from template part" option in the ellipsis menu and a switch option I think they are more interesting in this kind of block.

@jameskoster
Copy link
Contributor Author

Closing this in favor of #31750

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Template Part Affects the Template Parts Block Needs Design Feedback Needs general design feedback. [Type] Discussion For issues that are high-level and not yet ready to implement.
Projects
None yet
Development

No branches or pull requests

3 participants