Skip to content

Prevent annotations from being deleted while some features remain editable #4002

@reckart

Description

Is your feature request related to a problem? Please describe.
If a project manager imports pre-annotated documents into a project, it may be desired that the annotators cannot modify (all of the) pre-annotated data. For example, the annotator maybe should not be allowed to delete annotations, to move them, or even to create new ones. But on the existing ones, there would be some features that the annotator should be able to change (which may be a subset of all the features on that layer, so there may be others which should be not-editable).

Describe the solution you'd like
Making a layer read-only prevents any changes to the layer: no annotations can be create or deleted. Also, no features can be edited. There is no way to make individual features editable.

Not exactly clear yet what to do - see deliberations below.

Describe alternatives you've considered
Maybe it would be useful to introduce a read-only flag on features and to de-couple that from the one on the layer. So if a layer is marked as read-only, it applies only to the layer (create, delete). And if a feature is marked as read-only, then it applies only to that feature.

However, in that case, having a read-only feature on a non-read-only layer would raise the problem that the feature cannot be protected if the annotator decides to delete the entire annotation. Likewise, the annotator would not be able to set this feature on new annotations.

Thus, it may be more sensibel to introduce a editable on read-only layer flag - which would only be considered for layers that are read-only. Thus, if a layer is read-only, the feature would still be editable.

However, this kind of "reverse logic flag" may be somewhat confusing to the user in the UI. So maybe in the UI it would need to be show as read-only (== !editableOnReadOnlyLayer). That option should be ticked in the UI by default if a layer is marked as read-only (also to be compatible with existing projects) and it should only be visible if the layer associated with the feature is actually read-only.

Additional context
Would be particularly useful for document-level annotations where singleton cannot be used because there are multiple pre-generated document-level annotations (which the user should not be able to delete).

Metadata

Assignees

No one assigned

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions