Make WordPress Core

Opened 7 weeks ago

Closed 6 weeks ago

Last modified 6 weeks ago

#65532 closed enhancement (fixed)

Editor: Improve Classic Editor status dropdown layout

Reported by: poligilad Owned by: joedolson
Priority: normal Milestone: 7.1
Component: Editor Version:
Severity: normal Keywords: has-patch has-screenshots commit
Cc: Focuses: ui, accessibility

Description

In the Classic Editor publish box, the Status control is currently rendered as a compact <select> inside the editable Status panel.

The available choices are mutually exclusive and small in number:

  • Published
  • Pending Review
  • Draft
  • Scheduled, when applicable

This ticket proposes replacing that dropdown with a radio button group while preserving the existing submitted post_status value and save behavior.

The goal is to make the Status control easier to scan and interact with, and to bring the Classic Editor publish box closer to the block editor’s “Status & visibility” experience, where these publishing choices are presented as explicit options rather than compact form controls.

This should be a UI-only change. The underlying save contract should remain unchanged:

  • The submitted field should continue to be post_status.
  • Existing values such as publish, pending, draft, future, and private-related behavior should continue to work as they do today.
  • OK should update the visible Status summary.
  • Cancel should restore the previous status.
  • Existing visibility behavior, including Private posts changing the visible status text to “Privately Published” and hiding the Status edit link, should be preserved.

The change should also keep the current progressive enhancement behavior in the publish box. The radio buttons would replace the select control inside the existing edit panel, rather than changing the overall publish box flow.

Related tickets I found, but which do not appear to be exact duplicates:

  • #7745 covers long-standing confusion around private posts and status behavior.
  • #37613 discusses publish box UI/spacing around Visibility controls.
  • #17906 is a broader ticket about refactoring the submit/publish box.
  • #12706 covers custom post status behavior and edge cases.
  • #64308 is related to broader wp-admin visual refresh work.

None of those appear to specifically propose replacing the Classic Editor publish box Status dropdown with radio buttons while preserving the existing post_status submission behavior.

Attachments (2)

Status.png (791.5 KB ) - added by poligilad 7 weeks ago.
Status - 2.png (221.4 KB ) - added by poligilad 7 weeks ago.

Download all attachments as: .zip

Change History (16)

@poligilad
7 weeks ago

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


7 weeks ago
#1

  • Keywords has-patch has-unit-tests added; needs-patch removed

## Summary

  • Replaces the Classic Editor publish box Status <select> with a radio group while preserving the submitted post_status values.
  • Updates the existing Status OK/Cancel and Private visibility behavior for the reorganized controls.
  • Adds focused regression coverage for the rendered Status markup.

This is scoped to the Status control only. Visibility UI changes are intentionally not included here.

## Testing

  • LOCAL_PORT=18089 npm run test:php -- --filter Tests_Admin_IncludesMetaBoxes
  • vendor/bin/phpcs --standard=phpcs.xml.dist src/wp-admin/includes/meta-boxes.php tests/phpunit/tests/admin/includesMetaBoxes.php
  • npx grunt jshint:core --file=js/_enqueues/admin/post.js
  • npx grunt postcss:core
  • npm run build:dev
  • git diff --check
  • curl -I --max-time 10 http://localhost:18089

@poligilad commented on PR #12304:


7 weeks ago
#2

I changed the direction of this PR after doing an extensibility audit of the Classic Editor Status control.

The original version replaced the legacy select#post_status with a radio group. That preserves the submitted post_status values for Core’s own statuses, but it does not preserve the practical DOM contract that Classic Editor integrations rely on.

The audit found real plugin code that depends on select#post_status as an implicit extension point:

  • GeoDirectory appends custom status <option> elements and reads the selected option to update the Save button text.
  • AnsPress appends moderate and private_post options to select#post_status.
  • WPAdverts appends/selects an expired option and changes submit behavior based on the selected option.
  • BEA Post Status Admin appends custom statuses to the dropdown.
  • PublishPress Statuses reads and manipulates #post_status as a select throughout its Classic Editor integration.
  • WordCamp CampTix Invoices appends refunded and cancelled options to select#post_status.

Core also still has assumptions around #post_status behaving like a select, for example in local autosave status handling.

Given that, this PR no longer changes the control type. It now keeps the existing dropdown and limits the change to safer layout improvements:

  • keep select name="post_status" id="post_status" intact;
  • make the dropdown full width in the publish box;
  • move OK/Cancel below the dropdown for spacing consistency;
  • add a regression test that protects the legacy select markup contract.

That makes this a smaller visual improvement while avoiding the compatibility break from removing select#post_status.

#3 @joedolson
7 weeks ago

  • Keywords needs-screenshots added
  • Milestone Awaiting Review7.1

Thanks for catching that the select usage isn't really readily changeable! I was coming in here to make a comment to that effect, and I was glad to see that you'd already caught that.

The test alone is potentially something that makes this worth adding, to protect that contract.

Can you add new screenshots to show the updated changes?

#4 @joedolson
7 weeks ago

  • Owner set to joedolson
  • Status newaccepted

@poligilad
7 weeks ago

#5 @poligilad
7 weeks ago

  • Summary Use radio buttons for the Classic Editor publish box Status controlEditor: Improve Classic Editor status dropdown layout

Thanks @joedolson!
And sure thing, just added. It'll end up being a much smaller change.

Also updated the Summary to better reflect the scope.

#6 @tyxla
6 weeks ago

With the reduction of scope, I agree with this change. Left a review on the PR - I think we can clean it up a bit before landing. Thanks @poligilad!

@poligilad commented on PR #12304:


6 weeks ago
#7

Thanks for the review @tyxla!

I updated the PR to keep this as a smaller compatibility-preserving layout change:

  • removed the added OK/Cancel wrapper markup,
  • deleted the markup regression test,
  • simplified the CSS by removing max-width,
  • kept the existing select#post_status contract intact.

The remaining change is CSS-only for the Status dropdown layout: the select is full width, and the OK/Cancel controls sit below it.

#8 @tyxla
6 weeks ago

@poligilad with the reduction/changes in scope, the description of the ticket is no longer relevant.

Should we update it to reflect what we're doing, or is it intended to stay as the longer-term goal even after landing https://github.com/WordPress/wordpress-develop/pull/12304?

@poligilad commented on PR #12304:


6 weeks ago
#9

Thanks again for the review @tyxla!

  • I pushed a small CSS-only follow-up that keeps the markup unchanged while tightening the responsive spacing.
  • I also checked the layout at 480px and 720px; Status and Visibility now have matching OK/Cancel spacing.

@fcoveram commented on PR #12304:


6 weeks ago
#10

I don't see any concern. Although the layout is complex, the change is consistent with the radio list in Visibility field.

https://github.com/user-attachments/assets/4acfdf81-a2c6-485e-ad30-fbf44be64ee6

This ticket was mentioned in Slack in #accessibility by joedolson. View the logs.


6 weeks ago

#12 @joedolson
6 weeks ago

  • Keywords has-screenshots commit added; has-unit-tests needs-screenshots removed

#13 @joedolson
6 weeks ago

  • Resolutionfixed
  • Status acceptedclosed

In 62606:

Editor: Improve spacing and alignment of post status controls.

Switch status select dropdown to full width and move OK and cancel buttons below, for consistency with other controls. This change improves internationalization support by not restricting the space available for controls as severely.

Props poligilad, tyxla, fcoveram, joedolson.
Fixes #65532.

#14 @tyxla
6 weeks ago

Thank you @joedolson!

Note: See TracTickets for help on using tickets.