-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Post Date block variation for Post Modified Date #49111
Conversation
Size Change: +115 B (0%) Total Size: 1.34 MB
ℹ️ View Unchanged
|
Flaky tests detected in 0f5307a. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/4429947556
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This works well for me in my test, thank you.
"Post Modified Date" reads a bit strange to me as a non-native English speaker but it doesn't need to be a blocker.
Seems useful enough. Not a strong opinion, but is |
I echo the sentiments around the name, and personally see the 'Post' prefix as the main culprit. Obviously it's a wider issue, but it's not very helpful to encounter blocks like "Post Title", "Post Content", "Post Author", when you're editing a page, or a product. Without those prefixes we might have things like:
But until we get there, "Post Modified Date" seems acceptable despite the quirks. |
yep, i agree (see my original issue) #49093 it is dedicated to core publication features (page, post) only. I proposed Dates as single block in my original issue. |
Yes, it works for any post type. It's essentially |
K.I.S.S :-) no prefix :-) |
Removing the prefix is definitely something to handle separately. I'd stick with the current convention for this PR. |
Hey Rich! @richtabor This is great! Thank you for creating this Post Modified Date block! Sometimes I want to add a prefix. For a date modified block I might want to add a this post was modified -date-. Comparing to Post Modified Date block. I miss being able to add Post was modified -date- to this Post Modified Date block. |
That's interesting, though you could wrap it in a Row block with a Paragraph block of that text. |
Yeah. I also thought about that. It does add a higher complexity to it. Anyhow. I am exiting out of this PR now. Thanks again for creating the Post Modified Date block Rich! |
@paaljoachim / @richtabor |
What?
Adds a block variation for the core/post-date block so that one can search for, and directly add, the modified date to a template. It's the same block—just easier to add. Closes #49093.
Why?
Makes it easier to discover and add the modified date, instead of adding a post date block, then opening the Block Inspector and toggling the displayType attribute.
How?
Testing Instructions
Screenshots or screencast