-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adds missing name/value of the submit button to the form data of a vi…
…ew transition (#9248) * Adds missing name/value of the submit button to the form data of a view transition * Update .changeset/ninety-weeks-juggle.md Co-authored-by: Sarah Rainsberger <[email protected]> --------- Co-authored-by: Sarah Rainsberger <[email protected]>
- Loading branch information
1 parent
3cbd8ea
commit 43ddb52
Showing
4 changed files
with
38 additions
and
2 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'astro': patch | ||
--- | ||
|
||
Adds properties of the submit button (name, value) to the form data of a view transition |
This file contains 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
20 changes: 20 additions & 0 deletions
20
packages/astro/e2e/fixtures/view-transitions/src/pages/form-four.astro
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
import { ViewTransitions } from 'astro:transitions'; | ||
--- | ||
|
||
<html> | ||
<head> | ||
<ViewTransitions handleForms/> | ||
<meta charset="UTF-8" /> | ||
</head> | ||
<body> | ||
<h2>Voting Form</h2> | ||
{Astro.url.search} | ||
<h3>This form does neither have a `method`, nor an `action`, nor an `input` defined</h3> | ||
<form> | ||
<button name="stars" value="1">⭐</button> | ||
<button id="three" name="stars" value="3">⭐⭐⭐</button> | ||
<button name="stars" value="5">⭐⭐⭐⭐⭐</button> | ||
</form> | ||
</body> | ||
</html> |
This file contains 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