Make WordPress Core

Opened 9 hours ago

Last modified 9 hours ago

#65530 new enhancement

Improve classic editor Publish box visibility controls layout

Reported by: poligilad's profile poligilad Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version:
Component: Editor Keywords: has-patch has-unit-tests
Focuses: ui, accessibility Cc:

Description

The classic editor Publish box currently presents the Visibility controls as three radio options: Public, Password protected, and Private. When Password protected is selected, the password field appears inline within that group. The Sticky checkbox is also conditionally shown for public posts.

This works functionally, but the layout makes the visibility choices and their related secondary controls harder to scan. The password field is a conditional setting for the Password protected option, rather than a visibility option itself, and it can make the radio group feel visually uneven.

This ticket proposes a small markup/layout improvement for the classic editor Publish box:

  • Keep the existing Visibility radio choices:
    • Public
    • Password protected
    • Private
  • When Password protected is selected, show the password input below the radio group.
  • Keep “Stick this post to the front page” as a checkbox, shown only when Public is selected and sticky posts are supported.
  • Preserve the existing save contract using visibility=public|password|private.
  • Preserve existing OK/Cancel behavior:
    • OK updates the Visibility summary.
    • Cancel restores the previous visibility, password, and sticky state.
  • Avoid changing post status behavior or the underlying meaning of public/password/private/private visibility.

This is intended as a small, incremental improvement to the classic editor Publish box that makes related Visibility controls easier to scan, moves the UI slightly closer to the block editor’s explicit Visibility choices, and preserves the existing workflow and save behavior.

Related:

  • #7745 discusses long-standing Status/Visibility coupling and includes older publish box UI explorations, but this ticket is narrower and does not attempt to change private post status behavior.
  • #25459 addressed accessibility improvements in the Publish box.
  • #24792 touched the password-protected visibility password field.
  • #47153 provides broader admin form control accessibility context.

Attachments (1)

Visibility.png (771.4 KB) - added by poligilad 9 hours ago.

Download all attachments as: .zip

Change History (2)

@poligilad
9 hours ago

This ticket was mentioned in PR #12298 on WordPress/wordpress-develop by @poligilad.


9 hours ago
#1

  • Keywords has-patch has-unit-tests added

## Summary

  • Groups the classic editor Publish box Visibility radio options in a fieldset.
  • Moves the conditional password field below the radio group while preserving the existing visibility save values.
  • Keeps the Sticky checkbox as a conditional secondary control and adds focused layout coverage.

## Context
This is intended as a small, incremental improvement to the classic editor Publish box that makes related Visibility controls easier to scan, moves the UI slightly closer to the block editor's explicit Visibility choices, and preserves the existing workflow and save behavior.

This PR does not change post status behavior or the meaning of public, password protected, or private visibility. The save path continues to use the existing visibility=public|password|private values.

Related tickets:

  • #7745 discusses the longer-standing Status/Visibility coupling for private posts. This PR is narrower and does not attempt to change private post status behavior.
  • #25459 addressed accessibility improvements in the Publish box.
  • #24792 touched the password-protected visibility password field.
  • #47153 provides broader admin form control accessibility context.

## Testing

  • npm run test:php -- --filter Tests_Admin_IncludesMetaBoxes tests/phpunit/tests/admin/includesMetaBoxes.php
  • php -l src/wp-admin/includes/meta-boxes.php
  • php -l tests/phpunit/tests/admin/includesMetaBoxes.php
  • node --check src/js/_enqueues/admin/post.js
  • git diff --check
Note: See TracTickets for help on using tickets.