Umbraco.CMS.Backoffice
Umbraco.CMS.Backoffice copied to clipboard
Feature: Readonly mode for umb-collection element
Description
This PR adds readonly
mode to the umb-collection
element
General concept:
- The collection context includes a
ReadOnlyStateManager
that keeps track on read-only states. - A state is added to the manager when the
readonly
attribute gets set on the umb-collection element. - A new condition has to be added so extensions can check if a workspace is read-only. The condition is currently added to create actions so they only appear when a collection is writable.
Notice: I have added a new workspace view for a "Content collection". A collection based on a content type with a data type configuration and variable data. It is currently a duplication of the more generic named "workspace-view-collection".
How to test
- Add the
readonly
attribute to the element through developer tools
Types of changes
- [ ] Bug fix (non-breaking change which fixes an issue)
- [x] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
- [ ] Chore (minor updates related to the tooling or maintenance of the repository, does not impact compiled assets)