WordPress / gutenberg

The Block Editor project for WordPress and beyond. Plugin is available from the official repository.
https://wordpress.org/gutenberg/
Other
10.49k stars 4.18k forks source link

Lock entire FSE templates and template parts #36008

Open iandunn opened 3 years ago

iandunn commented 3 years ago

What problem does this address?

Theme authors will want to lock entire FSE templates and template parts in some situations.

There are some related issues, but I wasn't able to find any for that specific purpose:

What is your proposed solution?

Eventually, more granularity could be added, like "locked": [ "move", "delete" ], but true/false would be a good start.

aurooba commented 1 year ago

Popping in here merely to say that I am working on a theme and I really wish this capability existed already.

abhi3315 commented 1 year ago

Hey, @iandunn 👋🏻 I would like to contribute to this issue. Are there any latest updates so far?

iandunn commented 1 year ago

Not that I'm aware of. The Gutenberg team needs to decide if it's something they want to implement, and what the architecture should look like.

anarieldesign commented 1 year ago

As a theme author this would be a huge help as our users are mostly confused and frustrated with templates and would be great to be able to lock them in some situations

rielyncampbell commented 1 year ago

I would like to chime in that this would be extremely beneficial to me as well. Having the ability to lock these parts from being moved, removed, or edited in any way by anyone but a super admin would be perfect. I manage a multisite network of over a thousand sites with authors everywhere on the spectrum of skills. We have a standard banner and styles across all of the sites that we have to lock down given our self-publishing set up. I am currently developing a new theme to update our platform. Please take a serious look at this. Thank you.

hojtfredrik commented 10 months ago

+1! I am building a Saas based on themes and FSE and need to limit what can be customized by the client.

carolinan commented 6 months ago

template parts could have an inline attribute, so they can be locked in some cases and not in others.

This is already works <!-- wp:template-part {"slug":"header","area":"header","tagName":"header","lock":{"move":true,"remove":true}} /-->