fix(post-date): use block bindings instead of deprecated displayType#430
Merged
rbcorrales merged 1 commit intotrunkfrom Apr 10, 2026
Merged
fix(post-date): use block bindings instead of deprecated displayType#430rbcorrales merged 1 commit intotrunkfrom
rbcorrales merged 1 commit intotrunkfrom
Conversation
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the theme’s post-meta block patterns to represent “Modified Date” using the WordPress Block Bindings API (instead of the deprecated displayType attribute), aligning the patterns with modern core block schema/UI behavior.
Changes:
- Replaces
core/post-date’s deprecateddisplayType:"modified"attribute withmetadata.bindingspointingdatetimetocore/post-datafieldmodified. - Adds
wp-block-post-date__modified-dateclass to the modified-datecore/post-dateblocks for styling/detection consistency. - Applies the update across all 5 post-meta patterns.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| patterns/post-meta/post-meta-single-line.php | Updates modified date block to use block bindings + adds modified-date class. |
| patterns/post-meta/post-meta-single-line-avatar.php | Same binding/class update for the single-line avatar variant. |
| patterns/post-meta/post-meta-multiple-lines.php | Same binding/class update for the multiple-lines variant (with date format preserved). |
| patterns/post-meta/post-meta-multiple-lines-avatar.php | Same binding/class update for the multiple-lines avatar variant (with date format preserved). |
| patterns/post-meta/post-meta-compact.php | Same binding/class update for the compact variant (with font size preserved). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
laurelfulford
approved these changes
Apr 8, 2026
Contributor
laurelfulford
left a comment
There was a problem hiding this comment.
Looks good, @rbcorrales! 🙌
matticbot
pushed a commit
that referenced
this pull request
Apr 16, 2026
# [1.28.0-alpha.1](v1.27.0...v1.28.0-alpha.1) (2026-04-16) ### Bug Fixes * improve pagination, linking directly to comments ([#431](#431)) ([461def0](461def0)) * **post-date:** use block bindings instead of deprecated displayType ([#430](#430)) ([b65b8c3](b65b8c3)) ### Features * add newsletters templates ([#437](#437)) ([cc8d244](cc8d244)) * copy newsletters compatibility ([#436](#436)) ([214f73a](214f73a)) * swap in Overlay Menu block to replace template parts ([30be676](30be676))
|
🎉 This PR is included in version 1.28.0-alpha.1 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
All Submissions:
Changes proposed in this Pull Request:
Follow-up to #428. Updates all 5 post-meta patterns to use the modern WordPress Block Bindings API for the modified date block instead of the deprecated
displayTypeattribute.Before:
<!-- wp:post-date {"displayType":"modified"} /-->After:
<!-- wp:post-date {"metadata":{"bindings":{"datetime":{"source":"core/post-data","args":{"field":"modified"}}}},"className":"wp-block-post-date__modified-date"} /-->The
displayTypeattribute was superseded by Block Bindings in WordPress/gutenberg#70585. WordPress still renders it via a legacy fallback, but the attribute is no longer in the block schema and the editor UI doesn't recognize it as the "Modified Date" variation.The
wp-block-post-date__modified-dateCSS class is included for styling and detection purposes.Closes NPPD-1278.
How to test the changes in this Pull Request:
wp-block-post-date__modified-dateclass on the modified date block.Other information: