Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 18 additions & 4 deletions baselines/dom.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2751,6 +2751,10 @@ interface SerialPortRequestOptions {
filters?: SerialPortFilter[];
}

interface SetHTMLOptions {
sanitizer?: Sanitizer | SanitizerConfig | SanitizerPresets;
}

interface ShadowRootInit {
clonable?: boolean;
customElementRegistry?: CustomElementRegistry | null;
Expand Down Expand Up @@ -14142,6 +14146,12 @@ interface Element extends Node, ARIAMixin, Animatable, ChildNode, NonDocumentTyp
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Element/setAttributeNodeNS)
*/
setAttributeNodeNS(attr: Attr): Attr | null;
/**
* The **`setHTML()`** method of the Element interface provides an XSS-safe method to parse and sanitize a string of HTML and insert it into the DOM as a subtree of the element.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Element/setHTML)
*/
setHTML(html: string, options?: SetHTMLOptions): void;
/**
* The **`setHTMLUnsafe()`** method of the Element interface is used to parse HTML input into a DocumentFragment, optionally filtering out unwanted elements and attributes, and those that don't belong in the context, and then using it to replace the element's subtree in the DOM.
*
Expand Down Expand Up @@ -17987,7 +17997,7 @@ interface HTMLElementEventMap extends ElementEventMap, GlobalEventHandlersEventM
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLElement)
*/
interface HTMLElement extends Element, ElementCSSInlineStyle, ElementContentEditable, GlobalEventHandlers, HTMLOrSVGElement {
interface HTMLElement extends Element, ElementCSSInlineStyle, ElementContentEditable, GlobalEventHandlers, HTMLOrSVGElement, HTMLOrSVGOrMathMLElement {
/**
* The **`HTMLElement.accessKey`** property sets the keystroke which a user can press to jump to a given element.
*
Expand Down Expand Up @@ -20312,7 +20322,10 @@ declare var HTMLOptionsCollection: {
new(): HTMLOptionsCollection;
};

interface HTMLOrSVGElement {
interface HTMLOrSVGElement extends HTMLOrSVGOrMathMLElement {
}

interface HTMLOrSVGOrMathMLElement {
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLElement/autofocus) */
autofocus: boolean;
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLElement/dataset) */
Expand Down Expand Up @@ -24036,7 +24049,7 @@ interface MathMLElementEventMap extends ElementEventMap, GlobalEventHandlersEven
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/MathMLElement)
*/
interface MathMLElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement {
interface MathMLElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGOrMathMLElement {
addEventListener<K extends keyof MathMLElementEventMap>(type: K, listener: (this: MathMLElement, ev: MathMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
removeEventListener<K extends keyof MathMLElementEventMap>(type: K, listener: (this: MathMLElement, ev: MathMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
Expand Down Expand Up @@ -26033,6 +26046,7 @@ declare var NavigationPreloadManager: {
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationTransition)
*/
interface NavigationTransition {
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationTransition/committed) */
readonly committed: Promise<void>;
/**
* The **`finished`** read-only property of the NavigationTransition interface returns a Promise that fulfills at the same time the navigatesuccess event fires, or rejects at the same time the navigateerror event fires.
Expand Down Expand Up @@ -31828,7 +31842,7 @@ interface SVGElementEventMap extends ElementEventMap, GlobalEventHandlersEventMa
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGElement)
*/
interface SVGElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement {
interface SVGElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement, HTMLOrSVGOrMathMLElement {
/** @deprecated */
readonly className: any;
/**
Expand Down
22 changes: 18 additions & 4 deletions baselines/ts5.5/dom.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2748,6 +2748,10 @@ interface SerialPortRequestOptions {
filters?: SerialPortFilter[];
}

interface SetHTMLOptions {
sanitizer?: Sanitizer | SanitizerConfig | SanitizerPresets;
}

interface ShadowRootInit {
clonable?: boolean;
customElementRegistry?: CustomElementRegistry | null;
Expand Down Expand Up @@ -14129,6 +14133,12 @@ interface Element extends Node, ARIAMixin, Animatable, ChildNode, NonDocumentTyp
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Element/setAttributeNodeNS)
*/
setAttributeNodeNS(attr: Attr): Attr | null;
/**
* The **`setHTML()`** method of the Element interface provides an XSS-safe method to parse and sanitize a string of HTML and insert it into the DOM as a subtree of the element.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Element/setHTML)
*/
setHTML(html: string, options?: SetHTMLOptions): void;
/**
* The **`setHTMLUnsafe()`** method of the Element interface is used to parse HTML input into a DocumentFragment, optionally filtering out unwanted elements and attributes, and those that don't belong in the context, and then using it to replace the element's subtree in the DOM.
*
Expand Down Expand Up @@ -17971,7 +17981,7 @@ interface HTMLElementEventMap extends ElementEventMap, GlobalEventHandlersEventM
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLElement)
*/
interface HTMLElement extends Element, ElementCSSInlineStyle, ElementContentEditable, GlobalEventHandlers, HTMLOrSVGElement {
interface HTMLElement extends Element, ElementCSSInlineStyle, ElementContentEditable, GlobalEventHandlers, HTMLOrSVGElement, HTMLOrSVGOrMathMLElement {
/**
* The **`HTMLElement.accessKey`** property sets the keystroke which a user can press to jump to a given element.
*
Expand Down Expand Up @@ -20291,7 +20301,10 @@ declare var HTMLOptionsCollection: {
new(): HTMLOptionsCollection;
};

interface HTMLOrSVGElement {
interface HTMLOrSVGElement extends HTMLOrSVGOrMathMLElement {
}

interface HTMLOrSVGOrMathMLElement {
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLElement/autofocus) */
autofocus: boolean;
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLElement/dataset) */
Expand Down Expand Up @@ -24012,7 +24025,7 @@ interface MathMLElementEventMap extends ElementEventMap, GlobalEventHandlersEven
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/MathMLElement)
*/
interface MathMLElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement {
interface MathMLElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGOrMathMLElement {
addEventListener<K extends keyof MathMLElementEventMap>(type: K, listener: (this: MathMLElement, ev: MathMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
removeEventListener<K extends keyof MathMLElementEventMap>(type: K, listener: (this: MathMLElement, ev: MathMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
Expand Down Expand Up @@ -26009,6 +26022,7 @@ declare var NavigationPreloadManager: {
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationTransition)
*/
interface NavigationTransition {
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationTransition/committed) */
readonly committed: Promise<void>;
/**
* The **`finished`** read-only property of the NavigationTransition interface returns a Promise that fulfills at the same time the navigatesuccess event fires, or rejects at the same time the navigateerror event fires.
Expand Down Expand Up @@ -31803,7 +31817,7 @@ interface SVGElementEventMap extends ElementEventMap, GlobalEventHandlersEventMa
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGElement)
*/
interface SVGElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement {
interface SVGElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement, HTMLOrSVGOrMathMLElement {
/** @deprecated */
readonly className: any;
/**
Expand Down
22 changes: 18 additions & 4 deletions baselines/ts5.6/dom.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2748,6 +2748,10 @@ interface SerialPortRequestOptions {
filters?: SerialPortFilter[];
}

interface SetHTMLOptions {
sanitizer?: Sanitizer | SanitizerConfig | SanitizerPresets;
}

interface ShadowRootInit {
clonable?: boolean;
customElementRegistry?: CustomElementRegistry | null;
Expand Down Expand Up @@ -14139,6 +14143,12 @@ interface Element extends Node, ARIAMixin, Animatable, ChildNode, NonDocumentTyp
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Element/setAttributeNodeNS)
*/
setAttributeNodeNS(attr: Attr): Attr | null;
/**
* The **`setHTML()`** method of the Element interface provides an XSS-safe method to parse and sanitize a string of HTML and insert it into the DOM as a subtree of the element.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Element/setHTML)
*/
setHTML(html: string, options?: SetHTMLOptions): void;
/**
* The **`setHTMLUnsafe()`** method of the Element interface is used to parse HTML input into a DocumentFragment, optionally filtering out unwanted elements and attributes, and those that don't belong in the context, and then using it to replace the element's subtree in the DOM.
*
Expand Down Expand Up @@ -17984,7 +17994,7 @@ interface HTMLElementEventMap extends ElementEventMap, GlobalEventHandlersEventM
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLElement)
*/
interface HTMLElement extends Element, ElementCSSInlineStyle, ElementContentEditable, GlobalEventHandlers, HTMLOrSVGElement {
interface HTMLElement extends Element, ElementCSSInlineStyle, ElementContentEditable, GlobalEventHandlers, HTMLOrSVGElement, HTMLOrSVGOrMathMLElement {
/**
* The **`HTMLElement.accessKey`** property sets the keystroke which a user can press to jump to a given element.
*
Expand Down Expand Up @@ -20309,7 +20319,10 @@ declare var HTMLOptionsCollection: {
new(): HTMLOptionsCollection;
};

interface HTMLOrSVGElement {
interface HTMLOrSVGElement extends HTMLOrSVGOrMathMLElement {
}

interface HTMLOrSVGOrMathMLElement {
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLElement/autofocus) */
autofocus: boolean;
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLElement/dataset) */
Expand Down Expand Up @@ -24033,7 +24046,7 @@ interface MathMLElementEventMap extends ElementEventMap, GlobalEventHandlersEven
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/MathMLElement)
*/
interface MathMLElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement {
interface MathMLElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGOrMathMLElement {
addEventListener<K extends keyof MathMLElementEventMap>(type: K, listener: (this: MathMLElement, ev: MathMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
removeEventListener<K extends keyof MathMLElementEventMap>(type: K, listener: (this: MathMLElement, ev: MathMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
Expand Down Expand Up @@ -26030,6 +26043,7 @@ declare var NavigationPreloadManager: {
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationTransition)
*/
interface NavigationTransition {
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationTransition/committed) */
readonly committed: Promise<void>;
/**
* The **`finished`** read-only property of the NavigationTransition interface returns a Promise that fulfills at the same time the navigatesuccess event fires, or rejects at the same time the navigateerror event fires.
Expand Down Expand Up @@ -31825,7 +31839,7 @@ interface SVGElementEventMap extends ElementEventMap, GlobalEventHandlersEventMa
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGElement)
*/
interface SVGElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement {
interface SVGElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement, HTMLOrSVGOrMathMLElement {
/** @deprecated */
readonly className: any;
/**
Expand Down
22 changes: 18 additions & 4 deletions baselines/ts5.9/dom.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2748,6 +2748,10 @@ interface SerialPortRequestOptions {
filters?: SerialPortFilter[];
}

interface SetHTMLOptions {
sanitizer?: Sanitizer | SanitizerConfig | SanitizerPresets;
}

interface ShadowRootInit {
clonable?: boolean;
customElementRegistry?: CustomElementRegistry | null;
Expand Down Expand Up @@ -14139,6 +14143,12 @@ interface Element extends Node, ARIAMixin, Animatable, ChildNode, NonDocumentTyp
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Element/setAttributeNodeNS)
*/
setAttributeNodeNS(attr: Attr): Attr | null;
/**
* The **`setHTML()`** method of the Element interface provides an XSS-safe method to parse and sanitize a string of HTML and insert it into the DOM as a subtree of the element.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Element/setHTML)
*/
setHTML(html: string, options?: SetHTMLOptions): void;
/**
* The **`setHTMLUnsafe()`** method of the Element interface is used to parse HTML input into a DocumentFragment, optionally filtering out unwanted elements and attributes, and those that don't belong in the context, and then using it to replace the element's subtree in the DOM.
*
Expand Down Expand Up @@ -17984,7 +17994,7 @@ interface HTMLElementEventMap extends ElementEventMap, GlobalEventHandlersEventM
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLElement)
*/
interface HTMLElement extends Element, ElementCSSInlineStyle, ElementContentEditable, GlobalEventHandlers, HTMLOrSVGElement {
interface HTMLElement extends Element, ElementCSSInlineStyle, ElementContentEditable, GlobalEventHandlers, HTMLOrSVGElement, HTMLOrSVGOrMathMLElement {
/**
* The **`HTMLElement.accessKey`** property sets the keystroke which a user can press to jump to a given element.
*
Expand Down Expand Up @@ -20309,7 +20319,10 @@ declare var HTMLOptionsCollection: {
new(): HTMLOptionsCollection;
};

interface HTMLOrSVGElement {
interface HTMLOrSVGElement extends HTMLOrSVGOrMathMLElement {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The old name should be preserved somehow, right?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have proof that this is actively extended out there, but maybe...

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am pretty sure that HTMLOrSVGElement is used in many code bases like protected __element: HTMLOrSVGElement or public addElement(element: HTMLOrSVGElement).
So this type should be kept valid

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pushed a fix, does it look good enough? 👀

}

interface HTMLOrSVGOrMathMLElement {
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLElement/autofocus) */
autofocus: boolean;
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLElement/dataset) */
Expand Down Expand Up @@ -24033,7 +24046,7 @@ interface MathMLElementEventMap extends ElementEventMap, GlobalEventHandlersEven
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/MathMLElement)
*/
interface MathMLElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement {
interface MathMLElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGOrMathMLElement {
addEventListener<K extends keyof MathMLElementEventMap>(type: K, listener: (this: MathMLElement, ev: MathMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
removeEventListener<K extends keyof MathMLElementEventMap>(type: K, listener: (this: MathMLElement, ev: MathMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
Expand Down Expand Up @@ -26030,6 +26043,7 @@ declare var NavigationPreloadManager: {
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationTransition)
*/
interface NavigationTransition {
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationTransition/committed) */
readonly committed: Promise<void>;
/**
* The **`finished`** read-only property of the NavigationTransition interface returns a Promise that fulfills at the same time the navigatesuccess event fires, or rejects at the same time the navigateerror event fires.
Expand Down Expand Up @@ -31825,7 +31839,7 @@ interface SVGElementEventMap extends ElementEventMap, GlobalEventHandlersEventMa
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGElement)
*/
interface SVGElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement {
interface SVGElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement, HTMLOrSVGOrMathMLElement {
/** @deprecated */
readonly className: any;
/**
Expand Down
9 changes: 9 additions & 0 deletions inputfiles/patches/html.kdl
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,15 @@ interface SharedWorker {
}
}

// Hack to avoid breakage due to the mixin renaming to HTMLOrSVGOrMathMLElement
interface-mixin HTMLOrSVGElement extends=HTMLOrSVGOrMathMLElement
interface HTMLElement {
includes HTMLOrSVGElement
}
interface SVGElement {
includes HTMLOrSVGElement
}

removals {
dictionary CanvasRenderingContext2DSettings {
member colorType // Blink-only as of 2025-12, being tested in WebKit
Expand Down
34 changes: 19 additions & 15 deletions inputfiles/patches/webauthn.kdl
Original file line number Diff line number Diff line change
Expand Up @@ -14,33 +14,41 @@ removals {
// https://searchfox.org/mozilla-central/source/dom/webidl/WebAuthentication.webidl
// https://searchfox.org/wubkat/source/Source/WebCore/Modules/webauthn/AuthenticationExtensionsClientInputs.idl
// https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/modules/credentialmanagement/authentication_extensions_client_inputs.idl
member appidExclude
member credBlob
member getCredBlob
member hmacGetSecret // No implementation as of 2025-05
member payment
member appidExclude // Blink only as of 2026-05
member credBlob // Blink only as of 2026-05
member getCredBlob // Blink only as of 2026-05
member hmacGetSecret // No implementation as of 2026-05
member payment // Blink test only as of 2026-05
member remoteClientDataJSON // No implementation as of 2026-05
}

dictionary AuthenticationExtensionsClientInputsJSON {
member appidExclude
member appidExclude // Blink only as of 2026-05
member remoteClientDataJSON // No implementation as of 2026-05
}

dictionary AuthenticationExtensionsClientOutputs {
// (same as *Inputs)
member appidExclude // No implementation as of 2025-05
member hmacGetSecret // No implementation as of 2025-05
member payment // Blink only as of 2025-06
member appidExclude // No implementation as of 2026-05
member hmacGetSecret // No implementation as of 2026-05
member payment // Blink only as of 2026-05
member remoteClientDataJson // No implementation as of 2026-05
}

dictionary AuthenticationExtensionsClientOutputsJSON {
member appidExclude // No implementation as of 2026-05
member remoteClientDataJson // No implementation as of 2026-05
}

dictionary PublicKeyCredentialCreationOptions {
member attestationFormats // Blink only as of 2024-08
member hints // Blink only as of 2024-08
}

dictionary PublicKeyCredentialCreationOptionsJSON {
member attestationFormats // Gecko only as of 2024-08
}

dictionary PublicKeyCredentialRequestOptions {
member hints // Blink only as of 2024-08
}
Expand All @@ -56,8 +64,4 @@ removals {
member otp
member password
}

dictionary AuthenticationExtensionsClientOutputsJSON {
member appidExclude // No implementation as of 2025-12
}
}
Loading
Loading