HTMLInputElement.idl 3.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. #import <HTML/HTMLElement.idl>
  2. #import <HTML/HTMLFormElement.idl>
  3. #import <HTML/ValidityState.idl>
  4. #import <FileAPI/FileList.idl>
  5. // https://html.spec.whatwg.org/multipage/input.html#htmlinputelement
  6. [Exposed=Window]
  7. interface HTMLInputElement : HTMLElement {
  8. [HTMLConstructor] constructor();
  9. [CEReactions, Reflect] attribute DOMString accept;
  10. [CEReactions, Reflect] attribute DOMString alt;
  11. [CEReactions, Enumerated=Autocomplete, Reflect] attribute DOMString autocomplete;
  12. [CEReactions, Reflect=checked] attribute boolean defaultChecked;
  13. [ImplementedAs=checked_binding] attribute boolean checked;
  14. [CEReactions, Reflect=dirname] attribute DOMString dirName;
  15. [CEReactions, Reflect] attribute boolean disabled;
  16. readonly attribute HTMLFormElement? form;
  17. attribute FileList? files;
  18. [CEReactions] attribute USVString formAction;
  19. [CEReactions, Reflect=formenctype, Enumerated=FormEnctypeAttribute] attribute DOMString formEnctype;
  20. [CEReactions, Reflect=formmethod, Enumerated=FormMethodAttribute] attribute DOMString formMethod;
  21. [CEReactions, Reflect=formnovalidate] attribute boolean formNoValidate;
  22. [CEReactions, Reflect=formtarget] attribute DOMString formTarget;
  23. [CEReactions] attribute unsigned long height;
  24. attribute boolean indeterminate;
  25. [FIXME] readonly attribute HTMLDataListElement? list;
  26. [CEReactions, Reflect] attribute DOMString max;
  27. [CEReactions] attribute long maxLength;
  28. [CEReactions, Reflect] attribute DOMString min;
  29. [CEReactions] attribute long minLength;
  30. [CEReactions, Reflect] attribute boolean multiple;
  31. [CEReactions, Reflect] attribute DOMString name;
  32. [FIXME, CEReactions] attribute DOMString pattern;
  33. [CEReactions, Reflect] attribute DOMString placeholder;
  34. [CEReactions, Reflect=readonly] attribute boolean readOnly;
  35. [CEReactions, Reflect] attribute boolean required;
  36. [CEReactions] attribute unsigned long size;
  37. [CEReactions, Reflect, URL] attribute USVString src;
  38. [CEReactions, Reflect] attribute DOMString step;
  39. // https://whatpr.org/html-attr-input-switch/9546/input.html#the-input-element:dom-input-switch
  40. [CEReactions, Reflect] attribute boolean switch;
  41. [CEReactions] attribute DOMString type;
  42. [CEReactions, Reflect=value] attribute DOMString defaultValue;
  43. [CEReactions, LegacyNullToEmptyString] attribute DOMString value;
  44. attribute object? valueAsDate;
  45. attribute unrestricted double valueAsNumber;
  46. [CEReactions] attribute unsigned long width;
  47. undefined stepUp(optional long n = 1);
  48. undefined stepDown(optional long n = 1);
  49. [FIXME] readonly attribute boolean willValidate;
  50. readonly attribute ValidityState validity;
  51. [FIXME] readonly attribute DOMString validationMessage;
  52. boolean checkValidity();
  53. boolean reportValidity();
  54. undefined setCustomValidity(DOMString error);
  55. readonly attribute NodeList? labels;
  56. undefined select();
  57. attribute unsigned long? selectionStart;
  58. attribute unsigned long? selectionEnd;
  59. [ImplementedAs=selection_direction_binding] attribute DOMString? selectionDirection;
  60. undefined setRangeText(DOMString replacement);
  61. undefined setRangeText(DOMString replacement, unsigned long start, unsigned long end, optional SelectionMode selectionMode = "preserve");
  62. undefined setSelectionRange(unsigned long start, unsigned long end, optional DOMString direction);
  63. undefined showPicker();
  64. // Obsolete
  65. [CEReactions, Reflect] attribute DOMString align;
  66. [CEReactions, Reflect=usemap] attribute DOMString useMap;
  67. };
  68. // FIXME: HTMLInputElement includes PopoverInvokerElement;