Skip to content

View Config: Summarize the post form date panel with publish_date - #15517

Closed
oandregal wants to merge 2 commits into
WordPress:trunkfrom
oandregal:update/dataform-date-field-summary
Closed

oandregal wants to merge 2 commits into
WordPress:trunkfrom
oandregal:update/dataform-date-field-summary

Conversation

@oandregal

Copy link
Copy Markdown
Member

Trac ticket: https://core.trac.wordpress.org/ticket/65981

Summarizes the date panel of the default post type form with the publish_date field in view-config.php. The field reads "Immediately" while the post has no date of its own (a draft whose date floats, or a reset date), as the post summary did before it moved to the form. Otherwise it words the date as the post summary did, like "Today at 10:28 am" or "March 15, 2027 10:00 am".

Only the form changes: DataViews lists keep showing the date field. Post types providing their own form (attachment, wp_block, wp_template, wp_template_part) are unchanged.

The REST schema of the endpoint already allows a panel summary. The publish_date field itself ships with the @wordpress/core-fields package update and the server registration of the default fields.

Backports

Gutenberg PRs:

Use of AI Tools

AI assistance: Yes
Tool(s): Claude Code
Model(s): Opus 5.5
Used for: Porting the change and its tests from the Gutenberg PR. Reviewed and edited by me.

This Pull Request is for code review only. Please keep all other discussion in the Trac ticket. Do not merge this Pull Request. See GitHub Pull Requests for Code Review in the Core Handbook for more details.

The post form's `date` panel is now summarized by the `publish_date` field, which reads "Immediately" while the post has no date of its own, as the post summary did before it moved to the form. Post types providing their own form are unchanged.

See #65981.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Nov 5, 2026

Copy link
Copy Markdown

Test using WordPress Playground

The changes in this pull request can previewed and tested using a WordPress Playground instance.

WordPress Playground is an experimental project that creates a full WordPress instance entirely within the browser.

Some things to be aware of

  • All changes will be lost when closing a tab with a Playground instance.
  • All changes will be lost when refreshing the page.
  • A fresh instance is created each time the link below is clicked.
  • Every time this pull request is updated, a new ZIP file containing all changes is created. If changes are not reflected in the Playground instance,
    it's possible that the most recent build failed, or has not completed. Check the list of workflow runs to be sure.

For more details about these limitations and more, check out the Limitations page in the WordPress Playground documentation.

Test this pull request with WordPress Playground.

@oandregal
oandregal marked this pull request as ready for review November 5, 2026 16:19
Copilot AI balanced review requested due to automatic review settings November 5, 2026 16:19

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs.

Core Committers: Use this line as a base for the props when committing in SVN:

Props oandregal, jorgefilipecosta.

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.


Props Bot commands

You can trigger Props Bot actions by commenting on this PR:

  • @propsbot add <username> to give props to a GitHub user. Requires write access.
  • @propsbot remove <username> to leave a user out of the props. Requires write access.
  • @propsbot refresh to refresh this list. Adding the props-bot label works too.

Comment thread tests/phpunit/tests/view-config.php Resolved
Comment thread src/wp-includes/view-config.php Resolved

@jorgefilipecosta jorgefilipecosta left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍 The form change matches the Gutenberg shim, and the tests pass locally. The two nitpicks above are not blockers.

Combines the two `@since 7.2.0` entries of `_wp_get_default_posttype_form()`
and asserts the missing `date` summary with `assertFalse( isset() )` and a
failure message.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@oandregal

Copy link
Copy Markdown
Member Author

@oandregal oandregal closed this Nov 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants