WordPress.org

Make WordPress Core

Opened 5 weeks ago

Last modified 16 hours ago

#44100 reopened enhancement

GDPR Privacy Page setting allows for Draft Pages

Reported by: garrett-eclipse Owned by: azaozz
Milestone: 4.9.7 Priority: normal
Severity: normal Version: 4.9.6
Component: Privacy Keywords: gdpr has-patch fixed-major
Focuses: administration Cc:

Description

Hello,

Currently the Privacy Policy page select provides both published and draft pages. If a draft is selected it would be nice to indicate it's status to the user from this page. Was thinking possibly just by having (draft) appended to the select option for any pages in draft, or (private) for private pages to avoid users selecting non-published pages and overlooking.

For myself when I clicked 'Create New Page' it updated the setting pointing it to the new draft page which resulted in the Privacy Policy link no longer being present on the confirmation pages. Would be nice to either not allow drafts be selected or indicate they're draft so you're aware you have to finalize and publish.

Hope that makes sense, Thanks

Attachments (3)

44100.diff (3.8 KB) - added by allendav 2 weeks ago.
44100.2.diff (3.9 KB) - added by allendav 2 weeks ago.
Added is-dismissible
44100.3.diff (1.4 KB) - added by desrosj 32 hours ago.

Download all attachments as: .zip

Change History (18)

#1 @desrosj
5 weeks ago

  • Keywords gdpr added

#2 @desrosj
5 weeks ago

  • Component changed from General to Privacy

Moving to the new Privacy component.

#3 @desrosj
5 weeks ago

  • Version changed from trunk to 4.9.6

Marking Privacy change as introduced in 4.9.6.

#4 @desrosj
3 weeks ago

  • Milestone changed from Awaiting Review to 4.9.7
  • Type changed from defect (bug) to enhancement

I think this makes sense. I like including the status in parenthesis next to the page in the dropdown.

I am thinking a bit more about the second part, though. I think that a standard admin notice when editing the Privacy Policy page may be sufficient. We could consider a dismissible notice everywhere in the admin for users that are allowed to edit the Privacy Policy informing them the site's privacy policy is unpublished as well.

#5 @garrett-eclipse
3 weeks ago

Thanks @desrosj, I do like that idea of the global dismissable notice about the privacy policy being unpublished I think that'll help admins.

This ticket was mentioned in Slack in #core-privacy by allendav. View the logs.


2 weeks ago

@allendav
2 weeks ago

#7 @allendav
2 weeks ago

To test:

  • publish one or more pages and leave one or more pages as draft
  • ensure draft pages show "(Draft)" next to their titles in the dropdown on Settings > Privacy
  • select or create a draft privacy policy page
  • ensure you are prompted throughout wp-admin to publish that page or choose a different one
  • on the privacy page edit page itself, note the wording and links changes slightly
  • on the settings > privacy page, also note the wording and links change slightly

Are we really sure we want this throughout wp-admin? Seems excessive. May I recommend we consider limiting this a bit?

#8 @allendav
2 weeks ago

  • Keywords has-patch needs-testing ux-feedback added

@allendav
2 weeks ago

Added is-dismissible

#9 @desrosj
13 days ago

Thought about this more when addressing #44131 and opened #44320 to consider the various notifications related to privacy policy pages as a whole. I am not opposed to merging the notice in with this ticket, but we should at least get some UX feedback.

This ticket was mentioned in Slack in #core-privacy by desrosj. View the logs.


36 hours ago

#11 @azaozz
35 hours ago

As discussed in Slack: https://wordpress.slack.com/archives/C9695RJBW/p1529335496000432 perhaps better to only add the - (Draft) in this ticket, and move the new notification to a more general UI/UX ticket where all privacy notifications can be looked at as a whole.

#12 follow-up: @desrosj
32 hours ago

  • Keywords ux-feedback removed

44100.3.diff removes the notification and only adds '(Draft)` to the end of draft page titles in the dropdown. Adding a notification should be explored in #44320 so it can get proper UI/UX attention.

Other improvements:

  • Renamed _wp_privacy_settings_screen_filter_pages() to _wp_privacy_settings_filter_draft_page_titles() to better convey what the function does.
  • Adds @access, @param, and @return tags to the _wp_privacy_settings_filter_draft_page_titles() function.

One thing I am not sure of is adding a filter and then immediately removing it. I don't know if this is done anywhere else in core.

@desrosj
32 hours ago

#13 in reply to: ↑ 12 @azaozz
20 hours ago

Replying to desrosj:

One thing I am not sure of is adding a filter and then immediately removing it.

That's fine, it is a "contextual filtering" for wp_dropdown_pages() that is needed only when outputting the drop-down on the Privacy screen.

Edit: actually, maybe better to move that and use get_current_screen()->id. Cleaner to keep all add_filter() in admin-filters.php.

Last edited 16 hours ago by azaozz (previous) (diff)

#14 @azaozz
16 hours ago

  • Owner set to azaozz
  • Resolution set to fixed
  • Status changed from new to closed

In 43376:

Privacy: append (Draft) to draft page titles in the page drop-down on the Privacy Settings screen.

Props allendav, desrosj.
Fixes #44100.

#15 @azaozz
16 hours ago

  • Keywords fixed-major added; needs-testing removed
  • Resolution fixed deleted
  • Status changed from closed to reopened

Reopen for 4.9.7.

Note: See TracTickets for help on using tickets.