Cockpit-HQ / Cockpit

Cockpit Core - Content Platform
https://getcockpit.com
Other
338 stars 40 forks source link

[Feature] Lockable Components in Page Content #178

Open pozylon opened 1 month ago

pozylon commented 1 month ago

We'd like to allow customers to change the data of a custom component but at the same time restrict the customer deciding what components come after each other, for example:

A Main Page for an e-commerce site is designed like this and the initial page prepared by the designer looks like this:

The customer edits the testimonial component on the home page by clicking on the component and edit the text and some image of the client -> this is fine and encouraged

The customer edits the category grid component on the home page by clicking on the component and add a new category -> this is fine and encouraged

The customer adds a testimonial custom component to any content site he created himself -> this is fine and encouraged

The customer moves the testimonial component before the category grid on the home page -> this is not okay and against the design, it should not be possible.

So I suggest a "Lock" feature where a user with certain permissions can lock and unlock reordering, creation, or deletion of root components in a layout builder field on pages (he can still hide stuff with the "Hide Component" feature)

pozylon commented 1 month ago

Similarily, it would be awesome to extend that "locking" to pages in general, allowing the developers to lock a certain page so it cannot be removed by "marketing" people because they might think: "forgot-password" page is empty, I'm removing it.

All in all, the ACL for pages is too limited for many cases.