LibWeb: Implement HTMLInputElement.formAction

This commit is contained in:
Tim Ledbetter 2024-09-07 23:27:33 +01:00 committed by Andreas Kling
commit 33c62be7f9
Notes: github-actions[bot] 2024-09-08 07:48:46 +00:00
3 changed files with 7 additions and 2 deletions

View file

@ -1,3 +1,6 @@
button.formAction initial value: http://www.example.com/ button.formAction initial value: http://www.example.com/
Final segment of button.formAction after setting to the empty string: formAction-attribute.html Final segment of button.formAction after setting to the empty string: formAction-attribute.html
Final segment of button.formAction after setting to "../test.html": test.html Final segment of button.formAction after setting to "../test.html": test.html
input.formAction initial value: http://www.example.com/
Final segment of input.formAction after setting to the empty string: formAction-attribute.html
Final segment of input.formAction after setting to "../test.html": test.html

View file

@ -1,10 +1,12 @@
<!DOCTYPE html> <!DOCTYPE html>
<script src="../include.js"></script> <script src="../include.js"></script>
<button formaction="http://www.example.com/"></button> <button formaction="http://www.example.com/"></button>
<input formaction="http://www.example.com/">
<script> <script>
test(() => { test(() => {
const elementNames = [ const elementNames = [
"button", "button",
"input",
]; ];
for (const elementName of elementNames) { for (const elementName of elementNames) {
const element = document.querySelector(elementName); const element = document.querySelector(elementName);

View file

@ -17,7 +17,7 @@ interface HTMLInputElement : HTMLElement {
[CEReactions, Reflect] attribute boolean disabled; [CEReactions, Reflect] attribute boolean disabled;
readonly attribute HTMLFormElement? form; readonly attribute HTMLFormElement? form;
attribute FileList? files; attribute FileList? files;
[FIXME, CEReactions] attribute USVString formAction; [CEReactions] attribute USVString formAction;
[FIXME, CEReactions] attribute DOMString formEnctype; [FIXME, CEReactions] attribute DOMString formEnctype;
[FIXME, CEReactions] attribute DOMString formMethod; [FIXME, CEReactions] attribute DOMString formMethod;
[CEReactions, Reflect=formnovalidate] attribute boolean formNoValidate; [CEReactions, Reflect=formnovalidate] attribute boolean formNoValidate;