diff --git a/baselines/dom.generated.d.ts b/baselines/dom.generated.d.ts index e6bcab554..d4a8c6bc2 100644 --- a/baselines/dom.generated.d.ts +++ b/baselines/dom.generated.d.ts @@ -1180,6 +1180,15 @@ interface OscillatorOptions extends AudioNodeOptions { type?: OscillatorType; } +interface PageRevealEventInit extends EventInit { + viewTransition?: ViewTransition | null; +} + +interface PageSwapEventInit extends EventInit { + activation?: NavigationActivation | null; + viewTransition?: ViewTransition | null; +} + interface PageTransitionEventInit extends EventInit { persisted?: boolean; } @@ -5029,6 +5038,7 @@ interface CSSStyleDeclaration { vectorEffect: string; /** [MDN Reference](https://developer.mozilla.org/docs/Web/CSS/vertical-align) */ verticalAlign: string; + viewTransitionClass: string; /** [MDN Reference](https://developer.mozilla.org/docs/Web/CSS/view-transition-name) */ viewTransitionName: string; /** [MDN Reference](https://developer.mozilla.org/docs/Web/CSS/visibility) */ @@ -5667,6 +5677,16 @@ declare var CSSVariableReferenceValue: { new(variable: string, fallback?: CSSUnparsedValue | null): CSSVariableReferenceValue; }; +interface CSSViewTransitionRule extends CSSRule { + readonly navigation: string; + readonly types: ReadonlyArray; +} + +declare var CSSViewTransitionRule: { + prototype: CSSViewTransitionRule; + new(): CSSViewTransitionRule; +}; + /** * Provides a storage mechanism for Request / Response object pairs that are cached, for example as part of the ServiceWorker life cycle. Note that the Cache interface is exposed to windowed scopes as well as workers. You don't have to use it in conjunction with service workers, even though it is defined in the service worker spec. * Available only in secure contexts. @@ -7638,6 +7658,8 @@ interface Document extends Node, DocumentOrShadowRoot, FontFaceSource, GlobalEve createEvent(eventInterface: "MouseEvent"): MouseEvent; createEvent(eventInterface: "MouseEvents"): MouseEvent; createEvent(eventInterface: "OfflineAudioCompletionEvent"): OfflineAudioCompletionEvent; + createEvent(eventInterface: "PageRevealEvent"): PageRevealEvent; + createEvent(eventInterface: "PageSwapEvent"): PageSwapEvent; createEvent(eventInterface: "PageTransitionEvent"): PageTransitionEvent; createEvent(eventInterface: "PaymentMethodChangeEvent"): PaymentMethodChangeEvent; createEvent(eventInterface: "PaymentRequestUpdateEvent"): PaymentRequestUpdateEvent; @@ -11812,6 +11834,9 @@ declare var HTMLLegendElement: { interface HTMLLinkElement extends HTMLElement, LinkStyle { /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLLinkElement/as) */ as: string; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLLinkElement/blocking) */ + get blocking(): DOMTokenList; + set blocking(value: string); /** * Sets or retrieves the character set used to encode the object. * @deprecated @@ -12827,6 +12852,9 @@ declare var HTMLQuoteElement: { interface HTMLScriptElement extends HTMLElement { /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLScriptElement/async) */ async: boolean; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLScriptElement/blocking) */ + get blocking(): DOMTokenList; + set blocking(value: string); /** * Sets or retrieves the character set used to encode the object. * @deprecated @@ -13114,6 +13142,9 @@ declare var HTMLSpanElement: { * [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLStyleElement) */ interface HTMLStyleElement extends HTMLElement, LinkStyle { + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLStyleElement/blocking) */ + get blocking(): DOMTokenList; + set blocking(value: string); /** * Enables or disables the style sheet. * @@ -16497,6 +16528,52 @@ declare var NamedNodeMap: { new(): NamedNodeMap; }; +/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationActivation) */ +interface NavigationActivation { + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationActivation/entry) */ + readonly entry: NavigationHistoryEntry; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationActivation/from) */ + readonly from: NavigationHistoryEntry | null; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationActivation/navigationType) */ + readonly navigationType: NavigationType; +} + +declare var NavigationActivation: { + prototype: NavigationActivation; + new(): NavigationActivation; +}; + +interface NavigationHistoryEntryEventMap { + "dispose": Event; +} + +/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry) */ +interface NavigationHistoryEntry extends EventTarget { + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/id) */ + readonly id: string; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/index) */ + readonly index: number; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/key) */ + readonly key: string; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/dispose_event) */ + ondispose: ((this: NavigationHistoryEntry, ev: Event) => any) | null; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/sameDocument) */ + readonly sameDocument: boolean; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/url) */ + readonly url: string | null; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/getState) */ + getState(): any; + addEventListener(type: K, listener: (this: NavigationHistoryEntry, ev: NavigationHistoryEntryEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; + addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; + removeEventListener(type: K, listener: (this: NavigationHistoryEntry, ev: NavigationHistoryEntryEventMap[K]) => any, options?: boolean | EventListenerOptions): void; + removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; +} + +declare var NavigationHistoryEntry: { + prototype: NavigationHistoryEntry; + new(): NavigationHistoryEntry; +}; + /** * Available only in secure contexts. * @@ -17354,6 +17431,30 @@ declare var OverconstrainedError: { new(constraint: string, message?: string): OverconstrainedError; }; +/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/PageRevealEvent) */ +interface PageRevealEvent extends Event { + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/PageRevealEvent/viewTransition) */ + readonly viewTransition: ViewTransition | null; +} + +declare var PageRevealEvent: { + prototype: PageRevealEvent; + new(type: string, eventInitDict?: PageRevealEventInit): PageRevealEvent; +}; + +/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/PageSwapEvent) */ +interface PageSwapEvent extends Event { + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/PageSwapEvent/activation) */ + readonly activation: NavigationActivation | null; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/PageSwapEvent/viewTransition) */ + readonly viewTransition: ViewTransition | null; +} + +declare var PageSwapEvent: { + prototype: PageSwapEvent; + new(type: string, eventInitDict?: PageSwapEventInit): PageSwapEvent; +}; + /** * The PageTransitionEvent is fired when a document is being loaded or unloaded. * @@ -23745,6 +23846,7 @@ interface ViewTransition { readonly finished: Promise; /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTransition/ready) */ readonly ready: Promise; + types: ViewTransitionTypeSet; /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTransition/updateCallbackDone) */ readonly updateCallbackDone: Promise; /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTransition/skipTransition) */ @@ -23756,6 +23858,15 @@ declare var ViewTransition: { new(): ViewTransition; }; +interface ViewTransitionTypeSet { + forEach(callbackfn: (value: string, key: string, parent: ViewTransitionTypeSet) => void, thisArg?: any): void; +} + +declare var ViewTransitionTypeSet: { + prototype: ViewTransitionTypeSet; + new(): ViewTransitionTypeSet; +}; + interface VisualViewportEventMap { "resize": Event; "scroll": Event; @@ -29045,6 +29156,7 @@ type MediaSessionAction = "nexttrack" | "pause" | "play" | "previoustrack" | "se type MediaSessionPlaybackState = "none" | "paused" | "playing"; type MediaStreamTrackState = "ended" | "live"; type NavigationTimingType = "back_forward" | "navigate" | "prerender" | "reload"; +type NavigationType = "push" | "reload" | "replace" | "traverse"; type NotificationDirection = "auto" | "ltr" | "rtl"; type NotificationPermission = "default" | "denied" | "granted"; type OffscreenRenderingContextId = "2d" | "bitmaprenderer" | "webgl" | "webgl2" | "webgpu"; diff --git a/baselines/dom.iterable.generated.d.ts b/baselines/dom.iterable.generated.d.ts index 5477bd6ab..d383e7690 100644 --- a/baselines/dom.iterable.generated.d.ts +++ b/baselines/dom.iterable.generated.d.ts @@ -349,6 +349,9 @@ interface URLSearchParams { values(): URLSearchParamsIterator; } +interface ViewTransitionTypeSet extends Set { +} + interface WEBGL_draw_buffers { /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/WEBGL_draw_buffers/drawBuffersWEBGL) */ drawBuffersWEBGL(buffers: Iterable): void; diff --git a/baselines/ts5.5/dom.generated.d.ts b/baselines/ts5.5/dom.generated.d.ts index a32b8e889..b2fd7763a 100644 --- a/baselines/ts5.5/dom.generated.d.ts +++ b/baselines/ts5.5/dom.generated.d.ts @@ -1180,6 +1180,15 @@ interface OscillatorOptions extends AudioNodeOptions { type?: OscillatorType; } +interface PageRevealEventInit extends EventInit { + viewTransition?: ViewTransition | null; +} + +interface PageSwapEventInit extends EventInit { + activation?: NavigationActivation | null; + viewTransition?: ViewTransition | null; +} + interface PageTransitionEventInit extends EventInit { persisted?: boolean; } @@ -5023,6 +5032,7 @@ interface CSSStyleDeclaration { vectorEffect: string; /** [MDN Reference](https://developer.mozilla.org/docs/Web/CSS/vertical-align) */ verticalAlign: string; + viewTransitionClass: string; /** [MDN Reference](https://developer.mozilla.org/docs/Web/CSS/view-transition-name) */ viewTransitionName: string; /** [MDN Reference](https://developer.mozilla.org/docs/Web/CSS/visibility) */ @@ -5660,6 +5670,16 @@ declare var CSSVariableReferenceValue: { new(variable: string, fallback?: CSSUnparsedValue | null): CSSVariableReferenceValue; }; +interface CSSViewTransitionRule extends CSSRule { + readonly navigation: string; + readonly types: ReadonlyArray; +} + +declare var CSSViewTransitionRule: { + prototype: CSSViewTransitionRule; + new(): CSSViewTransitionRule; +}; + /** * Provides a storage mechanism for Request / Response object pairs that are cached, for example as part of the ServiceWorker life cycle. Note that the Cache interface is exposed to windowed scopes as well as workers. You don't have to use it in conjunction with service workers, even though it is defined in the service worker spec. * Available only in secure contexts. @@ -7631,6 +7651,8 @@ interface Document extends Node, DocumentOrShadowRoot, FontFaceSource, GlobalEve createEvent(eventInterface: "MouseEvent"): MouseEvent; createEvent(eventInterface: "MouseEvents"): MouseEvent; createEvent(eventInterface: "OfflineAudioCompletionEvent"): OfflineAudioCompletionEvent; + createEvent(eventInterface: "PageRevealEvent"): PageRevealEvent; + createEvent(eventInterface: "PageSwapEvent"): PageSwapEvent; createEvent(eventInterface: "PageTransitionEvent"): PageTransitionEvent; createEvent(eventInterface: "PaymentMethodChangeEvent"): PaymentMethodChangeEvent; createEvent(eventInterface: "PaymentRequestUpdateEvent"): PaymentRequestUpdateEvent; @@ -11798,6 +11820,8 @@ declare var HTMLLegendElement: { interface HTMLLinkElement extends HTMLElement, LinkStyle { /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLLinkElement/as) */ as: string; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLLinkElement/blocking) */ + readonly blocking: DOMTokenList; /** * Sets or retrieves the character set used to encode the object. * @deprecated @@ -12810,6 +12834,8 @@ declare var HTMLQuoteElement: { interface HTMLScriptElement extends HTMLElement { /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLScriptElement/async) */ async: boolean; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLScriptElement/blocking) */ + readonly blocking: DOMTokenList; /** * Sets or retrieves the character set used to encode the object. * @deprecated @@ -13097,6 +13123,8 @@ declare var HTMLSpanElement: { * [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLStyleElement) */ interface HTMLStyleElement extends HTMLElement, LinkStyle { + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/HTMLStyleElement/blocking) */ + readonly blocking: DOMTokenList; /** * Enables or disables the style sheet. * @@ -16480,6 +16508,52 @@ declare var NamedNodeMap: { new(): NamedNodeMap; }; +/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationActivation) */ +interface NavigationActivation { + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationActivation/entry) */ + readonly entry: NavigationHistoryEntry; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationActivation/from) */ + readonly from: NavigationHistoryEntry | null; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationActivation/navigationType) */ + readonly navigationType: NavigationType; +} + +declare var NavigationActivation: { + prototype: NavigationActivation; + new(): NavigationActivation; +}; + +interface NavigationHistoryEntryEventMap { + "dispose": Event; +} + +/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry) */ +interface NavigationHistoryEntry extends EventTarget { + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/id) */ + readonly id: string; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/index) */ + readonly index: number; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/key) */ + readonly key: string; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/dispose_event) */ + ondispose: ((this: NavigationHistoryEntry, ev: Event) => any) | null; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/sameDocument) */ + readonly sameDocument: boolean; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/url) */ + readonly url: string | null; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/NavigationHistoryEntry/getState) */ + getState(): any; + addEventListener(type: K, listener: (this: NavigationHistoryEntry, ev: NavigationHistoryEntryEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; + addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; + removeEventListener(type: K, listener: (this: NavigationHistoryEntry, ev: NavigationHistoryEntryEventMap[K]) => any, options?: boolean | EventListenerOptions): void; + removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; +} + +declare var NavigationHistoryEntry: { + prototype: NavigationHistoryEntry; + new(): NavigationHistoryEntry; +}; + /** * Available only in secure contexts. * @@ -17337,6 +17411,30 @@ declare var OverconstrainedError: { new(constraint: string, message?: string): OverconstrainedError; }; +/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/PageRevealEvent) */ +interface PageRevealEvent extends Event { + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/PageRevealEvent/viewTransition) */ + readonly viewTransition: ViewTransition | null; +} + +declare var PageRevealEvent: { + prototype: PageRevealEvent; + new(type: string, eventInitDict?: PageRevealEventInit): PageRevealEvent; +}; + +/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/PageSwapEvent) */ +interface PageSwapEvent extends Event { + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/PageSwapEvent/activation) */ + readonly activation: NavigationActivation | null; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/PageSwapEvent/viewTransition) */ + readonly viewTransition: ViewTransition | null; +} + +declare var PageSwapEvent: { + prototype: PageSwapEvent; + new(type: string, eventInitDict?: PageSwapEventInit): PageSwapEvent; +}; + /** * The PageTransitionEvent is fired when a document is being loaded or unloaded. * @@ -23726,6 +23824,7 @@ interface ViewTransition { readonly finished: Promise; /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTransition/ready) */ readonly ready: Promise; + types: ViewTransitionTypeSet; /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTransition/updateCallbackDone) */ readonly updateCallbackDone: Promise; /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTransition/skipTransition) */ @@ -23737,6 +23836,15 @@ declare var ViewTransition: { new(): ViewTransition; }; +interface ViewTransitionTypeSet { + forEach(callbackfn: (value: string, key: string, parent: ViewTransitionTypeSet) => void, thisArg?: any): void; +} + +declare var ViewTransitionTypeSet: { + prototype: ViewTransitionTypeSet; + new(): ViewTransitionTypeSet; +}; + interface VisualViewportEventMap { "resize": Event; "scroll": Event; @@ -29026,6 +29134,7 @@ type MediaSessionAction = "nexttrack" | "pause" | "play" | "previoustrack" | "se type MediaSessionPlaybackState = "none" | "paused" | "playing"; type MediaStreamTrackState = "ended" | "live"; type NavigationTimingType = "back_forward" | "navigate" | "prerender" | "reload"; +type NavigationType = "push" | "reload" | "replace" | "traverse"; type NotificationDirection = "auto" | "ltr" | "rtl"; type NotificationPermission = "default" | "denied" | "granted"; type OffscreenRenderingContextId = "2d" | "bitmaprenderer" | "webgl" | "webgl2" | "webgpu"; diff --git a/baselines/ts5.5/dom.iterable.generated.d.ts b/baselines/ts5.5/dom.iterable.generated.d.ts index 92d2e11b2..2b82aa4f2 100644 --- a/baselines/ts5.5/dom.iterable.generated.d.ts +++ b/baselines/ts5.5/dom.iterable.generated.d.ts @@ -329,6 +329,9 @@ interface URLSearchParams { values(): IterableIterator; } +interface ViewTransitionTypeSet extends Set { +} + interface WEBGL_draw_buffers { /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/WEBGL_draw_buffers/drawBuffersWEBGL) */ drawBuffersWEBGL(buffers: Iterable): void; diff --git a/inputfiles/overridingTypes.jsonc b/inputfiles/overridingTypes.jsonc index 3a59532c6..ef0de2f43 100644 --- a/inputfiles/overridingTypes.jsonc +++ b/inputfiles/overridingTypes.jsonc @@ -844,6 +844,56 @@ } } }, + "NavigationActivation": { + // https://github.com/mdn/browser-compat-data/issues/24963 + "exposed": "Window", + "properties": { + "property": { + "entry": { + "exposed": "Window" + }, + "from": { + "exposed": "Window" + }, + "navigationType": { + "exposed": "Window" + } + } + } + }, + "NavigationHistoryEntry": { + // https://github.com/mdn/browser-compat-data/issues/24963 + "exposed": "Window", + "properties": { + "property": { + "url": { + "exposed": "Window" + }, + "key": { + "exposed": "Window" + }, + "id": { + "exposed": "Window" + }, + "index": { + "exposed": "Window" + }, + "sameDocument": { + "exposed": "Window" + }, + "ondispose": { + "exposed": "Window" + } + } + }, + "methods": { + "method": { + "getState": { + "exposed": "Window" + } + } + } + }, "Node": { "methods": { "method": { diff --git a/package-lock.json b/package-lock.json index 380ed9b7d..85f631824 100644 --- a/package-lock.json +++ b/package-lock.json @@ -349,9 +349,9 @@ } }, "node_modules/@mdn/browser-compat-data": { - "version": "5.6.12", - "resolved": "https://registry.npmjs.org/@mdn/browser-compat-data/-/browser-compat-data-5.6.12.tgz", - "integrity": "sha512-W/Km+GFczwpoimaXbtHYdjK26VHGszOEZ9EnIyLS2E65x6LEZs7r0FovR/XSkzgNau95sTxI3JfFKQFLIJE7EQ==", + "version": "5.6.13", + "resolved": "https://registry.npmjs.org/@mdn/browser-compat-data/-/browser-compat-data-5.6.13.tgz", + "integrity": "sha512-eZOraBiugKZewtS10c7M78OKwL6CBhVzqSQvb5j+WGw/7MdPRfHrP7LuiEoLCeHXfmE414geJjnHPGQ0iAnCyg==", "dev": true, "license": "CC0-1.0" },