mirror of
https://github.com/RGBCube/serenity
synced 2025-05-28 21:45:09 +00:00
LibWeb: Introduce the concept of "Enumerated" values
This does _NOT_ correspond to anything in the IDL or ECMAScript spec, but is a custom extended attribute. We use it to define the "enumerated" values of an attribute
This commit is contained in:
parent
19bf42a7e6
commit
d767f14df8
5 changed files with 22 additions and 4 deletions
|
@ -1,6 +1,13 @@
|
|||
#import <HTML/HTMLElement.idl>
|
||||
#import <HTML/HTMLFormElement.idl>
|
||||
|
||||
[MissingValueDefault=submit, InvalidValueDefault=submit]
|
||||
enum ButtonTypeState {
|
||||
"submit",
|
||||
"reset",
|
||||
"button"
|
||||
};
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/semantics.html#htmlbuttonelement
|
||||
[Exposed=Window]
|
||||
interface HTMLButtonElement : HTMLElement {
|
||||
|
@ -14,7 +21,7 @@ interface HTMLButtonElement : HTMLElement {
|
|||
[CEReactions, Reflect=formnovalidate] attribute boolean formNoValidate;
|
||||
[CEReactions, Reflect=formtarget] attribute DOMString formTarget;
|
||||
[CEReactions, Reflect] attribute DOMString name;
|
||||
[CEReactions, Reflect] attribute DOMString type;
|
||||
[CEReactions, Reflect, Enumerated=ButtonTypeState] attribute DOMString type;
|
||||
[CEReactions, Reflect] attribute DOMString value;
|
||||
|
||||
// FIXME: readonly attribute boolean willValidate;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue