-
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
Block Bindings: Fix empty strings placeholders in post meta bindings #65089
Block Bindings: Fix empty strings placeholders in post meta bindings #65089
Conversation
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the Unlinked AccountsThe following contributors have not linked their GitHub and WordPress.org accounts: @zaguiini. Contributors, please read how to link your accounts to ensure your work is properly credited in WordPress releases. If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.
To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
Size Change: +11 B (0%) Total Size: 1.78 MB
ℹ️ View Unchanged
|
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.
I wasn't sure what the expected behavior was in that use case. I would prefer having a separate issue or PR to discuss the different solutions. |
I would respect the placeholder value provided on the server through filters and give it top |
@gziolo I'd appreciate some pointers here as I haven't worked much on the Bindings API. That is, of course, if @SantosGuillamot doesn't have the bandwidth to work on it. |
I'm gonna be away for a week, so if the plan is to include that for the next Gutenberg release, I won't have the bandwidth 😄 It could be even considered a bug though, so maybe it can get included during beta period. Regarding the code, placholder logic is happening here. |
What?
As reported here, the changes introduced to properly show placeholder in empty custom fields broke after that PR.
This PR addresses that and introduces an e2e test to avoid having the same issue in the future.
Why?
It is broken.
How?
I just changed the conditional where we change the value to consider an empty string as a valid value.
Testing Instructions
default
empty.