-
Notifications
You must be signed in to change notification settings - Fork 32
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
Editor: No attachement upload to draft only #1052
Conversation
to determine if the record is draft only or not and disable the upload of attachments in that case
contacts form field
attachment upload to draft only
Affected libs:
|
📷 Screenshots are here! |
📷 Screenshots are here! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the warnings and disablings @Angi-Kinas! This will result in a much better user experience.
Don't forget to add a French translation before merging.
I noticed that the "distribution" toggle does not display a cursor-not-allowed
on hover when disabled, but this is just a detail and not blocking IMO.
translations/en.json
Outdated
@@ -216,6 +215,7 @@ | |||
"editor.record.form.field.constraintsShortcuts": "", | |||
"editor.record.form.field.contacts.noContact": "Please provide at least one point of contact.", | |||
"editor.record.form.field.contactsForResource.noContact": "Please provide at least one point of contact responsible for the data.", | |||
"editor.record.form.field.draft.only.disabled": "This field will be enabled once published", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe same wording as German translation ?
"editor.record.form.field.draft.only.disabled": "This field will be enabled once published", | |
"editor.record.form.field.draft.only.disabled": "This field will be enabled once the data has been published", |
translations/fr.json
Outdated
@@ -216,6 +215,7 @@ | |||
"editor.record.form.field.constraintsShortcuts": "", | |||
"editor.record.form.field.contacts.noContact": "Veuillez renseigner au moins un point de contact.", | |||
"editor.record.form.field.contactsForResource.noContact": "Veuillez renseigner au moins un point de contact responsable de la donnée.", | |||
"editor.record.form.field.draft.only.disabled": "", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
French translation is missing. Google and I propose:
"editor.record.form.field.draft.only.disabled": "", | |
"editor.record.form.field.draft.only.disabled": "Ce champ sera activé une fois les données publiées", |
Description
This PR introduces the ability to detect if a record is draft only (never has been published) and disabling the input fields for uploading attachments (since this is only possible for published records). Additionally it indicates visually with a banner how to change the disabled state of the fields.
These changes were applied to the following editor fields:
Screenshots
Quality Assurance Checklist
breaking change
labelbackport <release branch>
label