@@ -144,69 +144,14 @@ declare global {
144
144
usageDetails ?: { [ key : string ] : number } ;
145
145
}
146
146
147
- // https://developer.mozilla.org/en-US/docs/Web/API/OffscreenCanvas
148
- interface OffscreenCanvas {
149
- convertToBlob ( opts ?: { type ?: string ; quality ?: number } ) : Promise < Blob > ;
150
- }
151
-
152
- interface HTMLAudioElement {
153
- type ?: string ;
154
- }
155
-
156
- interface HTMLVideoElement {
157
- type ?: string ;
158
- }
159
-
160
- // Add Chrome-specific `instant` ScrollBehaviour
161
- type _ScrollBehavior = ScrollBehavior | "instant" ;
162
-
163
- interface _ScrollOptions {
164
- behavior ?: _ScrollBehavior ;
165
- }
166
-
167
- interface _ScrollIntoViewOptions extends _ScrollOptions {
168
- block ?: ScrollLogicalPosition ;
169
- inline ?: ScrollLogicalPosition ;
170
- }
171
-
172
147
interface Element {
173
148
// Safari & IE11 only have this prefixed: we used prefixed versions
174
149
// previously so let's continue to support them for now
175
150
webkitRequestFullScreen ( options ?: FullscreenOptions ) : Promise < void > ;
176
151
msRequestFullscreen ( options ?: FullscreenOptions ) : Promise < void > ;
177
- scrollIntoView ( arg ?: boolean | _ScrollIntoViewOptions ) : void ;
178
- }
179
-
180
- interface Error {
181
- // Standard
182
- // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error/cause
183
- cause ?: unknown ;
184
-
185
- // Non-standard
186
- // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error/fileName
187
- fileName ?: string ;
188
- // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error/lineNumber
189
- lineNumber ?: number ;
190
- // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error/columnNumber
191
- columnNumber ?: number ;
192
- }
193
-
194
- // We can remove these pieces if we ever update to `target: "es2022"` in our
195
- // TypeScript config which supports the new `cause` property, see
196
- // https://github.com/vector-im/element-web/issues/24913
197
- interface ErrorOptions {
198
- // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error/cause
199
- cause ?: unknown ;
200
- }
201
-
202
- interface ErrorConstructor {
203
- new ( message ?: string , options ?: ErrorOptions ) : Error ;
204
- ( message ?: string , options ?: ErrorOptions ) : Error ;
152
+ // scrollIntoView(arg?: boolean | _ScrollIntoViewOptions): void;
205
153
}
206
154
207
- // eslint-disable-next-line no-var
208
- var Error : ErrorConstructor ;
209
-
210
155
// https://github.com/microsoft/TypeScript/issues/28308#issuecomment-650802278
211
156
interface AudioWorkletProcessor {
212
157
readonly port : MessagePort ;
0 commit comments