Skip to content

Commit 1c8d91b

Browse files
added HTMLOrSVGElement to HTMLElement and overrided focus()
1 parent 2a67253 commit 1c8d91b

File tree

2 files changed

+16
-3
lines changed

2 files changed

+16
-3
lines changed

baselines/dom.generated.d.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6065,7 +6065,7 @@ declare var HTMLDocument: {
60656065
new(): HTMLDocument;
60666066
};
60676067

6068-
interface HTMLElementEventMap extends ElementEventMap {
6068+
interface HTMLElementEventMap {
60696069
"abort": UIEvent;
60706070
"activate": Event;
60716071
"beforeactivate": Event;
@@ -6135,7 +6135,7 @@ interface HTMLElementEventMap extends ElementEventMap {
61356135
"waiting": Event;
61366136
}
61376137

6138-
interface HTMLElement extends Element, ElementCSSInlineStyle {
6138+
interface HTMLElement extends Element, HTMLOrSVGElement, ElementCSSInlineStyle {
61396139
accessKey: string;
61406140
contentEditable: string;
61416141
readonly dataset: DOMStringMap;
@@ -6225,7 +6225,7 @@ interface HTMLElement extends Element, ElementCSSInlineStyle {
62256225
blur(): void;
62266226
click(): void;
62276227
dragDrop(): boolean;
6228-
focus(): void;
6228+
focus(options?: FocusOptions): void;
62296229
msGetInputContext(): MSInputMethodContext;
62306230
addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
62316231
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;

inputfiles/overridingTypes.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -897,6 +897,19 @@
897897
}
898898
}
899899
},
900+
"HTMLElement": {
901+
"extends": "Element, HTMLOrSVGElement",
902+
"methods": {
903+
"method": {
904+
"focus": {
905+
"name": "focus",
906+
"override-signatures": [
907+
"focus(options?: FocusOptions): void"
908+
]
909+
}
910+
}
911+
}
912+
},
900913
"SVGElement": {
901914
"name": "SVGElement",
902915
"properties": {

0 commit comments

Comments
 (0)