Skip to content

Restore ViewTimeline from BCD 6.0.24 #2066

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 14, 2025
Merged
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
68 changes: 68 additions & 0 deletions baselines/dom.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2110,6 +2110,11 @@ interface ScrollOptions {
behavior?: ScrollBehavior;
}

interface ScrollTimelineOptions {
axis?: ScrollAxis;
source?: Element | null;
}

interface ScrollToOptions extends ScrollOptions {
left?: number;
top?: number;
Expand Down Expand Up @@ -2489,6 +2494,12 @@ interface VideoFrameInit {
visibleRect?: DOMRectInit;
}

interface ViewTimelineOptions {
axis?: ScrollAxis;
inset?: string | (CSSNumericValue | CSSKeywordValue)[];
subject?: Element;
}

interface WaveShaperOptions extends AudioNodeOptions {
curve?: number[] | Float32Array;
oversample?: OverSampleType;
Expand Down Expand Up @@ -30550,6 +30561,31 @@ declare var ScriptProcessorNode: {
new(): ScriptProcessorNode;
};

/**
* The **`ScrollTimeline`** interface of the Web Animations API represents a scroll progress timeline (see CSS scroll-driven animations for more details).
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ScrollTimeline)
*/
interface ScrollTimeline extends AnimationTimeline {
/**
* The **`axis`** read-only property of the An enumerated value.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ScrollTimeline/axis)
*/
readonly axis: ScrollAxis;
/**
* The **`source`** read-only property of the An Element.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ScrollTimeline/source)
*/
readonly source: Element | null;
}

declare var ScrollTimeline: {
prototype: ScrollTimeline;
new(options?: ScrollTimelineOptions): ScrollTimeline;
};

/**
* The **`SecurityPolicyViolationEvent`** interface inherits from Event, and represents the event object of a `securitypolicyviolation` event sent on an Element/securitypolicyviolation_event, Document/securitypolicyviolation_event, or WorkerGlobalScope/securitypolicyviolation_event when its Content Security Policy (CSP) is violated.
*
Expand Down Expand Up @@ -33696,6 +33732,37 @@ declare var VideoPlaybackQuality: {
new(): VideoPlaybackQuality;
};

/**
* The **`ViewTimeline`** interface of the Web Animations API represents a view progress timeline (see CSS scroll-driven animations for more details).
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTimeline)
*/
interface ViewTimeline extends ScrollTimeline {
/**
* The **`endOffset`** read-only property of the ViewTimeline interface returns a CSSNumericValue representing the ending (100% progress) scroll position of the timeline as an offset from the start of the overflowing section of content in the scroller.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTimeline/endOffset)
*/
readonly endOffset: CSSNumericValue;
/**
* The **`startOffset`** read-only property of the ViewTimeline interface returns a CSSNumericValue representing the starting (0% progress) scroll position of the timeline as an offset from the start of the overflowing section of content in the scroller.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTimeline/startOffset)
*/
readonly startOffset: CSSNumericValue;
/**
* The **`subject`** read-only property of the ViewTimeline interface returns a reference to the subject element whose visibility within its nearest ancestor scrollable element (scroller) is driving the progress of the timeline.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTimeline/subject)
*/
readonly subject: Element;
}

declare var ViewTimeline: {
prototype: ViewTimeline;
new(options?: ViewTimelineOptions): ViewTimeline;
};

/**
* The **`ViewTransition`** interface of the View Transition API represents an active view transition, and provides functionality to react to the transition reaching different states (e.g., ready to run the animation, or animation finished) or skip the transition altogether.
*
Expand Down Expand Up @@ -39750,6 +39817,7 @@ type ResidentKeyRequirement = "discouraged" | "preferred" | "required";
type ResizeObserverBoxOptions = "border-box" | "content-box" | "device-pixel-content-box";
type ResizeQuality = "high" | "low" | "medium" | "pixelated";
type ResponseType = "basic" | "cors" | "default" | "error" | "opaque" | "opaqueredirect";
type ScrollAxis = "block" | "inline" | "x" | "y";
type ScrollBehavior = "auto" | "instant" | "smooth";
type ScrollLogicalPosition = "center" | "end" | "nearest" | "start";
type ScrollRestoration = "auto" | "manual";
Expand Down
68 changes: 68 additions & 0 deletions baselines/ts5.5/dom.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2110,6 +2110,11 @@ interface ScrollOptions {
behavior?: ScrollBehavior;
}

interface ScrollTimelineOptions {
axis?: ScrollAxis;
source?: Element | null;
}

interface ScrollToOptions extends ScrollOptions {
left?: number;
top?: number;
Expand Down Expand Up @@ -2489,6 +2494,12 @@ interface VideoFrameInit {
visibleRect?: DOMRectInit;
}

interface ViewTimelineOptions {
axis?: ScrollAxis;
inset?: string | (CSSNumericValue | CSSKeywordValue)[];
subject?: Element;
}

interface WaveShaperOptions extends AudioNodeOptions {
curve?: number[] | Float32Array;
oversample?: OverSampleType;
Expand Down Expand Up @@ -30528,6 +30539,31 @@ declare var ScriptProcessorNode: {
new(): ScriptProcessorNode;
};

/**
* The **`ScrollTimeline`** interface of the Web Animations API represents a scroll progress timeline (see CSS scroll-driven animations for more details).
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ScrollTimeline)
*/
interface ScrollTimeline extends AnimationTimeline {
/**
* The **`axis`** read-only property of the An enumerated value.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ScrollTimeline/axis)
*/
readonly axis: ScrollAxis;
/**
* The **`source`** read-only property of the An Element.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ScrollTimeline/source)
*/
readonly source: Element | null;
}

declare var ScrollTimeline: {
prototype: ScrollTimeline;
new(options?: ScrollTimelineOptions): ScrollTimeline;
};

/**
* The **`SecurityPolicyViolationEvent`** interface inherits from Event, and represents the event object of a `securitypolicyviolation` event sent on an Element/securitypolicyviolation_event, Document/securitypolicyviolation_event, or WorkerGlobalScope/securitypolicyviolation_event when its Content Security Policy (CSP) is violated.
*
Expand Down Expand Up @@ -33673,6 +33709,37 @@ declare var VideoPlaybackQuality: {
new(): VideoPlaybackQuality;
};

/**
* The **`ViewTimeline`** interface of the Web Animations API represents a view progress timeline (see CSS scroll-driven animations for more details).
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTimeline)
*/
interface ViewTimeline extends ScrollTimeline {
/**
* The **`endOffset`** read-only property of the ViewTimeline interface returns a CSSNumericValue representing the ending (100% progress) scroll position of the timeline as an offset from the start of the overflowing section of content in the scroller.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTimeline/endOffset)
*/
readonly endOffset: CSSNumericValue;
/**
* The **`startOffset`** read-only property of the ViewTimeline interface returns a CSSNumericValue representing the starting (0% progress) scroll position of the timeline as an offset from the start of the overflowing section of content in the scroller.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTimeline/startOffset)
*/
readonly startOffset: CSSNumericValue;
/**
* The **`subject`** read-only property of the ViewTimeline interface returns a reference to the subject element whose visibility within its nearest ancestor scrollable element (scroller) is driving the progress of the timeline.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTimeline/subject)
*/
readonly subject: Element;
}

declare var ViewTimeline: {
prototype: ViewTimeline;
new(options?: ViewTimelineOptions): ViewTimeline;
};

/**
* The **`ViewTransition`** interface of the View Transition API represents an active view transition, and provides functionality to react to the transition reaching different states (e.g., ready to run the animation, or animation finished) or skip the transition altogether.
*
Expand Down Expand Up @@ -39727,6 +39794,7 @@ type ResidentKeyRequirement = "discouraged" | "preferred" | "required";
type ResizeObserverBoxOptions = "border-box" | "content-box" | "device-pixel-content-box";
type ResizeQuality = "high" | "low" | "medium" | "pixelated";
type ResponseType = "basic" | "cors" | "default" | "error" | "opaque" | "opaqueredirect";
type ScrollAxis = "block" | "inline" | "x" | "y";
type ScrollBehavior = "auto" | "instant" | "smooth";
type ScrollLogicalPosition = "center" | "end" | "nearest" | "start";
type ScrollRestoration = "auto" | "manual";
Expand Down
68 changes: 68 additions & 0 deletions baselines/ts5.6/dom.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2110,6 +2110,11 @@ interface ScrollOptions {
behavior?: ScrollBehavior;
}

interface ScrollTimelineOptions {
axis?: ScrollAxis;
source?: Element | null;
}

interface ScrollToOptions extends ScrollOptions {
left?: number;
top?: number;
Expand Down Expand Up @@ -2489,6 +2494,12 @@ interface VideoFrameInit {
visibleRect?: DOMRectInit;
}

interface ViewTimelineOptions {
axis?: ScrollAxis;
inset?: string | (CSSNumericValue | CSSKeywordValue)[];
subject?: Element;
}

interface WaveShaperOptions extends AudioNodeOptions {
curve?: number[] | Float32Array;
oversample?: OverSampleType;
Expand Down Expand Up @@ -30550,6 +30561,31 @@ declare var ScriptProcessorNode: {
new(): ScriptProcessorNode;
};

/**
* The **`ScrollTimeline`** interface of the Web Animations API represents a scroll progress timeline (see CSS scroll-driven animations for more details).
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ScrollTimeline)
*/
interface ScrollTimeline extends AnimationTimeline {
/**
* The **`axis`** read-only property of the An enumerated value.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ScrollTimeline/axis)
*/
readonly axis: ScrollAxis;
/**
* The **`source`** read-only property of the An Element.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ScrollTimeline/source)
*/
readonly source: Element | null;
}

declare var ScrollTimeline: {
prototype: ScrollTimeline;
new(options?: ScrollTimelineOptions): ScrollTimeline;
};

/**
* The **`SecurityPolicyViolationEvent`** interface inherits from Event, and represents the event object of a `securitypolicyviolation` event sent on an Element/securitypolicyviolation_event, Document/securitypolicyviolation_event, or WorkerGlobalScope/securitypolicyviolation_event when its Content Security Policy (CSP) is violated.
*
Expand Down Expand Up @@ -33696,6 +33732,37 @@ declare var VideoPlaybackQuality: {
new(): VideoPlaybackQuality;
};

/**
* The **`ViewTimeline`** interface of the Web Animations API represents a view progress timeline (see CSS scroll-driven animations for more details).
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTimeline)
*/
interface ViewTimeline extends ScrollTimeline {
/**
* The **`endOffset`** read-only property of the ViewTimeline interface returns a CSSNumericValue representing the ending (100% progress) scroll position of the timeline as an offset from the start of the overflowing section of content in the scroller.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTimeline/endOffset)
*/
readonly endOffset: CSSNumericValue;
/**
* The **`startOffset`** read-only property of the ViewTimeline interface returns a CSSNumericValue representing the starting (0% progress) scroll position of the timeline as an offset from the start of the overflowing section of content in the scroller.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTimeline/startOffset)
*/
readonly startOffset: CSSNumericValue;
/**
* The **`subject`** read-only property of the ViewTimeline interface returns a reference to the subject element whose visibility within its nearest ancestor scrollable element (scroller) is driving the progress of the timeline.
*
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/ViewTimeline/subject)
*/
readonly subject: Element;
}

declare var ViewTimeline: {
prototype: ViewTimeline;
new(options?: ViewTimelineOptions): ViewTimeline;
};

/**
* The **`ViewTransition`** interface of the View Transition API represents an active view transition, and provides functionality to react to the transition reaching different states (e.g., ready to run the animation, or animation finished) or skip the transition altogether.
*
Expand Down Expand Up @@ -39750,6 +39817,7 @@ type ResidentKeyRequirement = "discouraged" | "preferred" | "required";
type ResizeObserverBoxOptions = "border-box" | "content-box" | "device-pixel-content-box";
type ResizeQuality = "high" | "low" | "medium" | "pixelated";
type ResponseType = "basic" | "cors" | "default" | "error" | "opaque" | "opaqueredirect";
type ScrollAxis = "block" | "inline" | "x" | "y";
type ScrollBehavior = "auto" | "instant" | "smooth";
type ScrollLogicalPosition = "center" | "end" | "nearest" | "start";
type ScrollRestoration = "auto" | "manual";
Expand Down
6 changes: 0 additions & 6 deletions inputfiles/overridingTypes.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -3810,9 +3810,6 @@
"GPUValidationError": {
"exposed": ""
},
"ScrollTimeline": {
"exposed": ""
},
"TrustedHTML": {
"exposed": ""
},
Expand All @@ -3828,9 +3825,6 @@
"TrustedTypePolicyFactory": {
"exposed": ""
},
"ViewTimeline": {
"exposed": ""
},
"WGSLLanguageFeatures": {
"exposed": ""
},
Expand Down