Problem/Motivation
UX: Certain users understand the word "Draft" to mean "Unpublished" and are surprised that a node in "Draft" is published if a previous revision of the node is Published.
Steps to reproduce
- drush site:install -y
- drush en -y content_moderation
- drush uli
- /admin/config/workflow/workflows/manage/editorial
- This workflow applies to: Content Type node: select: Article
- Save dialog box, then save again
- /node/add/article
- Title: test
- Make sure Save as: says Draft
- Save
- In an incognito window, go to /node/1
- Confirm you see Access Denied
- /node/1/edit
- Change to: Published
- Save
- In an incognito window, go to /node/1
- Confirm you see the node
- /node/1/edit
- Change to: Draft
- Save
- In an incognito window, go to /node/1
- Confirm you see the node
Proposed resolution
Under "Draft", if a previous version of the node is published, add text that says: "A previous revision of this node is published. See all revisions" which will link to /node/1/revisions. If no version is previously published, then say: "This node has no published revision. See all revisions" which will link to /node/1/revisions.
Remaining tasks
User interface changes
See "Proposed resolution".
API changes
Data model changes
Release notes snippet
| Comment | File | Size | Author |
|---|---|---|---|
| #8 | Screenshot from 2024-07-15 17-45-52.png | 33.41 KB | nishtha.pradhan |
| #4 | screenshot_2024-06-28_at_14.10.53.jpg | 322.71 KB | alberto56 |
Issue fork drupal-3457914
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
alberto56 commentedComment #3
alberto56 commentedComment #4
alberto56 commentedComment #5
quietone commentedFixes are made on on 11.x (our main development branch) first, and are then back ported as needed according to our policies.
Comment #6
nishtha.pradhan commentedComment #8
nishtha.pradhan commentedAdded the necessary changes, please review.
Comment #9
catchComment #10
smustgrave commentedComment #11
nishtha.pradhan commentedComment #12
smustgrave commentedWas previously tagged for tests which are still needed
Thanks.
Comment #13
rkollerUsability review
We discussed this issue the last two weeks at #3460910: Drupal Usability Meeting 2024-07-19 and #3462675: Drupal Usability Meeting 2024-07-26. The link to the recording of last week’s meeting is: https://www.youtube.com/watch?v=P3FN7NuvxyU . For the record, the attendees were: @AaronMcHale, @benjifisher, @rkoller, @shaal, @simohell, @worldlinemine, and @zetagraph. The link to the recording of yesterday’s meeting is: https://www.youtube.com/watch?v=crtKx6T_-IM . For the record, the attendees were @AaronMcHale, @amazingrando, @benjifisher, @rkoller, and @shaal.
If you want more feedback from the usability team, a good way to reach out is in the #ux channel in Slack.
The group agreed that the problem outlined in the issue summary has to be solved. We have taken a look at the current state of the MR and made a few observations:
A previous revision of this node is published. See all revisions.is not controllable, since it is not a widget.A previous revision of this node is published. See all revisions..Current state:is sort of unclear, or at least might makes the user think for a second or two. What doescurrentrefers to? Whatstatestands for (which is a shorthand formoderation state)?PublishedorDraftin bold letters, standing alone without any context. It looks like the headline/title of the advanced column, plus it is not clear if that title refers to theStatusor the actualmoderation state, in case the currentmoderation stateis for examplePublished.In regards of consistency and clarity there are two more aspects we've stumbled across when we’ve visited
/admin/contentand the revisions pages during our discussions. But both aspects are completely out of the scope for this issue:/admin/contentpage as well. If you add themoderation statecolumn to thecontentview you getPublishedin thestatusas well as for themoderation statecolumn, while if you switch to themoderated contenttab the very same node has amoderation stateofDraft<code>. That is potentially confusing and a mixed messaging across pages. We’ve found the following #3082700: Content: Moderation state field in Views does not display proper value if change made after "Published" that might apply at least in part to this problem./admin/contentand the node edit page. We’ve found #2899719: Revision/version language on revision listing page is misleading with content moderation enabled tackling that.We had a lot of back and forth over the course of the last two meetings, but we’ve agreed on the following points:
Last savedandAuthorunderneath. So the first line changes (using the example “Draft”) fromDrafttoModeration state: Draft. The reason was to make the first line more clear and make the first section of the advanced column more easy scanable.A previous revision of this node is published. See all revisions.introduced with this MR from the main content area into the advanced column right underneathModeration state: Draft. As already mentioned, the note is meta information about the content and therefore more suitable within the advanced column than the main content area of the node edit form.A previous revision of this node is published. See all revisions.to eitherA previous revision is published. See all revisions.orA previous revision is published.. It has to be noted that we have not reached a clear consensus which of the two variants to pick. There is only a clear consensus about the first sentence, and removing the reference to the node, making the sentence more generic. We were only uncertain if we should keep the reference to the revisions page including the link, since the link is now, by moving the sentence into the advanced column, in even more close proximity to the revisions primary tab.Current state:on the moderation state form display widget toModeration state:. The reason was to remove the potentially confusing and probably obsolete wordcurrentand avoid the shorthand ofstateby making the label consistent with the one now used in the advanced column.