Skip to content

Commit

Permalink
[TwigBridge] Provide a default non-empty label on empty options to va…
Browse files Browse the repository at this point in the history
…lidate HTML5
  • Loading branch information
DocFX committed Nov 4, 2022
1 parent 08ecb2f commit 53d7b5d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -644,7 +644,7 @@ public function testSingleChoiceWithPreferredAndBlankSeparator()
[not(@required)]
[
./option[@value="&b"][not(@selected)][.="[trans]Choice&B[/trans]"]
/following-sibling::option[@disabled="disabled"][not(@selected)][.=""]
/following-sibling::option[@disabled="disabled"][not(@selected)][.="" or .="--"]
/following-sibling::option[@value="&a"][@selected="selected"][.="[trans]Choice&A[/trans]"]
/following-sibling::option[@value="&b"][.="[trans]Choice&B[/trans]"]
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -628,7 +628,7 @@ public function testSingleChoiceWithPreferredAndBlankSeparator()
[not(@required)]
[
./option[@value="&b"][not(@selected)][.="[trans]Choice&B[/trans]"]
/following-sibling::option[@disabled="disabled"][not(@selected)][.=""]
/following-sibling::option[@disabled="disabled"][not(@selected)][.="" or .="--"]
/following-sibling::option[@value="&a"][@selected="selected"][.="[trans]Choice&A[/trans]"]
/following-sibling::option[@value="&b"][.="[trans]Choice&B[/trans]"]
]
Expand Down
2 changes: 1 addition & 1 deletion src/Symfony/Component/Form/Tests/AbstractLayoutTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -802,7 +802,7 @@ public function testSingleChoiceWithPreferredAndBlankSeparator()
[not(@required)]
[
./option[@value="&b"][not(@selected)][.="[trans]Choice&B[/trans]"]
/following-sibling::option[@disabled="disabled"][not(@selected)][.=""]
/following-sibling::option[@disabled="disabled"][not(@selected)][.="" or .="--"]
/following-sibling::option[@value="&a"][@selected="selected"][.="[trans]Choice&A[/trans]"]
/following-sibling::option[@value="&b"][.="[trans]Choice&B[/trans]"]
]
Expand Down

0 comments on commit 53d7b5d

Please sign in to comment.