Repository navigation
[6.x] Keep true and false strings in component attributes from Antlers - #15626
Open
jacksleight wants to merge 1 commit into
Open
jacksleight wants to merge 1 commit into
jacksleight wants to merge 1 commit into
Conversation
This branch has not been deployed
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.
This PR keeps
"true"and"false"as strings when they're passed as attributes to components from Antlers, the same as Blade.Tag parameters turn those strings into booleans, which is right for tags but not for HTML attributes, where the literal value matters:
aria-hidden="aria-hidden"isn't a valid ARIA value, andaria-expanded="false"is dropped completely. Blade passes both through as written.Notes:
<x-alert dismissible="false" />behaves as it does now."true"or"false"are kept too, real booleans are unchanged (:hidden="is_hidden"still rendershidden="hidden").ComponentProxylike [6.x] Escape bound attributes passed to components from Antlers #15624, so there may be a small conflict depending on which goes in first.