From eff3dd58fe3a6b15944838842aaf734910baa1d4 Mon Sep 17 00:00:00 2001 From: Kitson Kelly Date: Fri, 7 Jul 2017 17:01:22 +0100 Subject: [PATCH] Update to TypeScript 2.4.1 --- lib/lib-es6-ts.js | 2 +- lib/lib-ts.js | 2 +- lib/typescriptServices.d.ts | 705 +- lib/typescriptServices.js | 13192 +++++++++++++++++++++------------- package.json | 2 +- src/mode.ts | 4 +- 6 files changed, 8668 insertions(+), 5239 deletions(-) diff --git a/lib/lib-es6-ts.js b/lib/lib-es6-ts.js index 8fdf3725..d6145a94 100644 --- a/lib/lib-es6-ts.js +++ b/lib/lib-es6-ts.js @@ -5,5 +5,5 @@ // This is a generated file from lib.es6.d.ts -define([], function() { return { contents: "/*! *****************************************************************************\nCopyright (c) Microsoft Corporation. All rights reserved. \nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\nthis file except in compliance with the License. You may obtain a copy of the\nLicense at http://www.apache.org/licenses/LICENSE-2.0 \n \nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, \nMERCHANTABLITY OR NON-INFRINGEMENT. \n \nSee the Apache Version 2.0 License for specific language governing permissions\nand limitations under the License.\n***************************************************************************** */\n\n\n\n/// \n\n\n/////////////////////////////\n/// ECMAScript APIs\n/////////////////////////////\n\ndeclare const NaN: number;\ndeclare const Infinity: number;\n\n/**\n * Evaluates JavaScript code and executes it.\n * @param x A String value that contains valid JavaScript code.\n */\ndeclare function eval(x: string): any;\n\n/**\n * Converts A string to an integer.\n * @param s A string to convert into a number.\n * @param radix A value between 2 and 36 that specifies the base of the number in numString.\n * If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\n * All other strings are considered decimal.\n */\ndeclare function parseInt(s: string, radix?: number): number;\n\n/**\n * Converts a string to a floating-point number.\n * @param string A string that contains a floating-point number.\n */\ndeclare function parseFloat(string: string): number;\n\n/**\n * Returns a Boolean value that indicates whether a value is the reserved value NaN (not a number).\n * @param number A numeric value.\n */\ndeclare function isNaN(number: number): boolean;\n\n/**\n * Determines whether a supplied number is finite.\n * @param number Any numeric value.\n */\ndeclare function isFinite(number: number): boolean;\n\n/**\n * Gets the unencoded version of an encoded Uniform Resource Identifier (URI).\n * @param encodedURI A value representing an encoded URI.\n */\ndeclare function decodeURI(encodedURI: string): string;\n\n/**\n * Gets the unencoded version of an encoded component of a Uniform Resource Identifier (URI).\n * @param encodedURIComponent A value representing an encoded URI component.\n */\ndeclare function decodeURIComponent(encodedURIComponent: string): string;\n\n/**\n * Encodes a text string as a valid Uniform Resource Identifier (URI)\n * @param uri A value representing an encoded URI.\n */\ndeclare function encodeURI(uri: string): string;\n\n/**\n * Encodes a text string as a valid component of a Uniform Resource Identifier (URI).\n * @param uriComponent A value representing an encoded URI component.\n */\ndeclare function encodeURIComponent(uriComponent: string): string;\n\ninterface PropertyDescriptor {\n configurable?: boolean;\n enumerable?: boolean;\n value?: any;\n writable?: boolean;\n get? (): any;\n set? (v: any): void;\n}\n\ninterface PropertyDescriptorMap {\n [s: string]: PropertyDescriptor;\n}\n\ninterface Object {\n /** The initial value of Object.prototype.constructor is the standard built-in Object constructor. */\n constructor: Function;\n\n /** Returns a string representation of an object. */\n toString(): string;\n\n /** Returns a date converted to a string using the current locale. */\n toLocaleString(): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): Object;\n\n /**\n * Determines whether an object has a property with the specified name.\n * @param v A property name.\n */\n hasOwnProperty(v: string): boolean;\n\n /**\n * Determines whether an object exists in another object's prototype chain.\n * @param v Another object whose prototype chain is to be checked.\n */\n isPrototypeOf(v: Object): boolean;\n\n /**\n * Determines whether a specified property is enumerable.\n * @param v A property name.\n */\n propertyIsEnumerable(v: string): boolean;\n}\n\ninterface ObjectConstructor {\n new (value?: any): Object;\n (): any;\n (value: any): any;\n\n /** A reference to the prototype for a class of objects. */\n readonly prototype: Object;\n\n /**\n * Returns the prototype of an object.\n * @param o The object that references the prototype.\n */\n getPrototypeOf(o: any): any;\n\n /**\n * Gets the own property descriptor of the specified object.\n * An own property descriptor is one that is defined directly on the object and is not inherited from the object's prototype.\n * @param o Object that contains the property.\n * @param p Name of the property.\n */\n getOwnPropertyDescriptor(o: any, p: string): PropertyDescriptor;\n\n /**\n * Returns the names of the own properties of an object. The own properties of an object are those that are defined directly\n * on that object, and are not inherited from the object's prototype. The properties of an object include both fields (objects) and functions.\n * @param o Object that contains the own properties.\n */\n getOwnPropertyNames(o: any): string[];\n\n /**\n * Creates an object that has the specified prototype or that has null prototype.\n * @param o Object to use as a prototype. May be null.\n */\n create(o: object | null): any;\n\n /**\n * Creates an object that has the specified prototype, and that optionally contains specified properties.\n * @param o Object to use as a prototype. May be null\n * @param properties JavaScript object that contains one or more property descriptors.\n */\n create(o: object | null, properties: PropertyDescriptorMap & ThisType): any;\n\n /**\n * Adds a property to an object, or modifies attributes of an existing property.\n * @param o Object on which to add or modify the property. This can be a native JavaScript object (that is, a user-defined object or a built in object) or a DOM object.\n * @param p The property name.\n * @param attributes Descriptor for the property. It can be for a data property or an accessor property.\n */\n defineProperty(o: any, p: string, attributes: PropertyDescriptor & ThisType): any;\n\n /**\n * Adds one or more properties to an object, and/or modifies attributes of existing properties.\n * @param o Object on which to add or modify the properties. This can be a native JavaScript object or a DOM object.\n * @param properties JavaScript object that contains one or more descriptor objects. Each descriptor object describes a data property or an accessor property.\n */\n defineProperties(o: any, properties: PropertyDescriptorMap & ThisType): any;\n\n /**\n * Prevents the modification of attributes of existing properties, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n seal(o: T): T;\n\n /**\n * Prevents the modification of existing property attributes and values, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n freeze(a: T[]): ReadonlyArray;\n\n /**\n * Prevents the modification of existing property attributes and values, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n freeze(f: T): T;\n\n /**\n * Prevents the modification of existing property attributes and values, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n freeze(o: T): Readonly;\n\n /**\n * Prevents the addition of new properties to an object.\n * @param o Object to make non-extensible.\n */\n preventExtensions(o: T): T;\n\n /**\n * Returns true if existing property attributes cannot be modified in an object and new properties cannot be added to the object.\n * @param o Object to test.\n */\n isSealed(o: any): boolean;\n\n /**\n * Returns true if existing property attributes and values cannot be modified in an object, and new properties cannot be added to the object.\n * @param o Object to test.\n */\n isFrozen(o: any): boolean;\n\n /**\n * Returns a value that indicates whether new properties can be added to an object.\n * @param o Object to test.\n */\n isExtensible(o: any): boolean;\n\n /**\n * Returns the names of the enumerable properties and methods of an object.\n * @param o Object that contains the properties and methods. This can be an object that you created or an existing Document Object Model (DOM) object.\n */\n keys(o: any): string[];\n}\n\n/**\n * Provides functionality common to all JavaScript objects.\n */\ndeclare const Object: ObjectConstructor;\n\n/**\n * Creates a new function.\n */\ninterface Function {\n /**\n * Calls the function, substituting the specified object for the this value of the function, and the specified array for the arguments of the function.\n * @param thisArg The object to be used as the this object.\n * @param argArray A set of arguments to be passed to the function.\n */\n apply(this: Function, thisArg: any, argArray?: any): any;\n\n /**\n * Calls a method of an object, substituting another object for the current object.\n * @param thisArg The object to be used as the current object.\n * @param argArray A list of arguments to be passed to the method.\n */\n call(this: Function, thisArg: any, ...argArray: any[]): any;\n\n /**\n * For a given function, creates a bound function that has the same body as the original function.\n * The this object of the bound function is associated with the specified object, and has the specified initial parameters.\n * @param thisArg An object to which the this keyword can refer inside the new function.\n * @param argArray A list of arguments to be passed to the new function.\n */\n bind(this: Function, thisArg: any, ...argArray: any[]): any;\n\n /** Returns a string representation of a function. */\n toString(): string;\n\n prototype: any;\n readonly length: number;\n\n // Non-standard extensions\n arguments: any;\n caller: Function;\n}\n\ninterface FunctionConstructor {\n /**\n * Creates a new function.\n * @param args A list of arguments the function accepts.\n */\n new (...args: string[]): Function;\n (...args: string[]): Function;\n readonly prototype: Function;\n}\n\ndeclare const Function: FunctionConstructor;\n\ninterface IArguments {\n [index: number]: any;\n length: number;\n callee: Function;\n}\n\ninterface String {\n /** Returns a string representation of a string. */\n toString(): string;\n\n /**\n * Returns the character at the specified index.\n * @param pos The zero-based index of the desired character.\n */\n charAt(pos: number): string;\n\n /**\n * Returns the Unicode value of the character at the specified location.\n * @param index The zero-based index of the desired character. If there is no character at the specified index, NaN is returned.\n */\n charCodeAt(index: number): number;\n\n /**\n * Returns a string that contains the concatenation of two or more strings.\n * @param strings The strings to append to the end of the string.\n */\n concat(...strings: string[]): string;\n\n /**\n * Returns the position of the first occurrence of a substring.\n * @param searchString The substring to search for in the string\n * @param position The index at which to begin searching the String object. If omitted, search starts at the beginning of the string.\n */\n indexOf(searchString: string, position?: number): number;\n\n /**\n * Returns the last occurrence of a substring in the string.\n * @param searchString The substring to search for.\n * @param position The index at which to begin searching. If omitted, the search begins at the end of the string.\n */\n lastIndexOf(searchString: string, position?: number): number;\n\n /**\n * Determines whether two strings are equivalent in the current locale.\n * @param that String to compare to target string\n */\n localeCompare(that: string): number;\n\n /**\n * Matches a string with a regular expression, and returns an array containing the results of that search.\n * @param regexp A variable name or string literal containing the regular expression pattern and flags.\n */\n match(regexp: string | RegExp): RegExpMatchArray | null;\n\n /**\n * Replaces text in a string, using a regular expression or search string.\n * @param searchValue A string to search for.\n * @param replaceValue A string containing the text to replace for every successful match of searchValue in this string.\n */\n replace(searchValue: string | RegExp, replaceValue: string): string;\n\n /**\n * Replaces text in a string, using a regular expression or search string.\n * @param searchValue A string to search for.\n * @param replacer A function that returns the replacement text.\n */\n replace(searchValue: string | RegExp, replacer: (substring: string, ...args: any[]) => string): string;\n\n /**\n * Finds the first substring match in a regular expression search.\n * @param regexp The regular expression pattern and applicable flags.\n */\n search(regexp: string | RegExp): number;\n\n /**\n * Returns a section of a string.\n * @param start The index to the beginning of the specified portion of stringObj.\n * @param end The index to the end of the specified portion of stringObj. The substring includes the characters up to, but not including, the character indicated by end.\n * If this value is not specified, the substring continues to the end of stringObj.\n */\n slice(start?: number, end?: number): string;\n\n /**\n * Split a string into substrings using the specified separator and return them as an array.\n * @param separator A string that identifies character or characters to use in separating the string. If omitted, a single-element array containing the entire string is returned.\n * @param limit A value used to limit the number of elements returned in the array.\n */\n split(separator: string | RegExp, limit?: number): string[];\n\n /**\n * Returns the substring at the specified location within a String object.\n * @param start The zero-based index number indicating the beginning of the substring.\n * @param end Zero-based index number indicating the end of the substring. The substring includes the characters up to, but not including, the character indicated by end.\n * If end is omitted, the characters from start through the end of the original string are returned.\n */\n substring(start: number, end?: number): string;\n\n /** Converts all the alphabetic characters in a string to lowercase. */\n toLowerCase(): string;\n\n /** Converts all alphabetic characters to lowercase, taking into account the host environment's current locale. */\n toLocaleLowerCase(): string;\n\n /** Converts all the alphabetic characters in a string to uppercase. */\n toUpperCase(): string;\n\n /** Returns a string where all alphabetic characters have been converted to uppercase, taking into account the host environment's current locale. */\n toLocaleUpperCase(): string;\n\n /** Removes the leading and trailing white space and line terminator characters from a string. */\n trim(): string;\n\n /** Returns the length of a String object. */\n readonly length: number;\n\n // IE extensions\n /**\n * Gets a substring beginning at the specified location and having the specified length.\n * @param from The starting position of the desired substring. The index of the first character in the string is zero.\n * @param length The number of characters to include in the returned substring.\n */\n substr(from: number, length?: number): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): string;\n\n readonly [index: number]: string;\n}\n\ninterface StringConstructor {\n new (value?: any): String;\n (value?: any): string;\n readonly prototype: String;\n fromCharCode(...codes: number[]): string;\n}\n\n/**\n * Allows manipulation and formatting of text strings and determination and location of substrings within strings.\n */\ndeclare const String: StringConstructor;\n\ninterface Boolean {\n /** Returns the primitive value of the specified object. */\n valueOf(): boolean;\n}\n\ninterface BooleanConstructor {\n new (value?: any): Boolean;\n (value?: any): boolean;\n readonly prototype: Boolean;\n}\n\ndeclare const Boolean: BooleanConstructor;\n\ninterface Number {\n /**\n * Returns a string representation of an object.\n * @param radix Specifies a radix for converting numeric values to strings. This value is only used for numbers.\n */\n toString(radix?: number): string;\n\n /**\n * Returns a string representing a number in fixed-point notation.\n * @param fractionDigits Number of digits after the decimal point. Must be in the range 0 - 20, inclusive.\n */\n toFixed(fractionDigits?: number): string;\n\n /**\n * Returns a string containing a number represented in exponential notation.\n * @param fractionDigits Number of digits after the decimal point. Must be in the range 0 - 20, inclusive.\n */\n toExponential(fractionDigits?: number): string;\n\n /**\n * Returns a string containing a number represented either in exponential or fixed-point notation with a specified number of digits.\n * @param precision Number of significant digits. Must be in the range 1 - 21, inclusive.\n */\n toPrecision(precision?: number): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): number;\n}\n\ninterface NumberConstructor {\n new (value?: any): Number;\n (value?: any): number;\n readonly prototype: Number;\n\n /** The largest number that can be represented in JavaScript. Equal to approximately 1.79E+308. */\n readonly MAX_VALUE: number;\n\n /** The closest number to zero that can be represented in JavaScript. Equal to approximately 5.00E-324. */\n readonly MIN_VALUE: number;\n\n /**\n * A value that is not a number.\n * In equality comparisons, NaN does not equal any value, including itself. To test whether a value is equivalent to NaN, use the isNaN function.\n */\n readonly NaN: number;\n\n /**\n * A value that is less than the largest negative number that can be represented in JavaScript.\n * JavaScript displays NEGATIVE_INFINITY values as -infinity.\n */\n readonly NEGATIVE_INFINITY: number;\n\n /**\n * A value greater than the largest number that can be represented in JavaScript.\n * JavaScript displays POSITIVE_INFINITY values as infinity.\n */\n readonly POSITIVE_INFINITY: number;\n}\n\n/** An object that represents a number of any kind. All JavaScript numbers are 64-bit floating-point numbers. */\ndeclare const Number: NumberConstructor;\n\ninterface TemplateStringsArray extends ReadonlyArray {\n readonly raw: ReadonlyArray;\n}\n\ninterface Math {\n /** The mathematical constant e. This is Euler's number, the base of natural logarithms. */\n readonly E: number;\n /** The natural logarithm of 10. */\n readonly LN10: number;\n /** The natural logarithm of 2. */\n readonly LN2: number;\n /** The base-2 logarithm of e. */\n readonly LOG2E: number;\n /** The base-10 logarithm of e. */\n readonly LOG10E: number;\n /** Pi. This is the ratio of the circumference of a circle to its diameter. */\n readonly PI: number;\n /** The square root of 0.5, or, equivalently, one divided by the square root of 2. */\n readonly SQRT1_2: number;\n /** The square root of 2. */\n readonly SQRT2: number;\n /**\n * Returns the absolute value of a number (the value without regard to whether it is positive or negative).\n * For example, the absolute value of -5 is the same as the absolute value of 5.\n * @param x A numeric expression for which the absolute value is needed.\n */\n abs(x: number): number;\n /**\n * Returns the arc cosine (or inverse cosine) of a number.\n * @param x A numeric expression.\n */\n acos(x: number): number;\n /**\n * Returns the arcsine of a number.\n * @param x A numeric expression.\n */\n asin(x: number): number;\n /**\n * Returns the arctangent of a number.\n * @param x A numeric expression for which the arctangent is needed.\n */\n atan(x: number): number;\n /**\n * Returns the angle (in radians) from the X axis to a point.\n * @param y A numeric expression representing the cartesian y-coordinate.\n * @param x A numeric expression representing the cartesian x-coordinate.\n */\n atan2(y: number, x: number): number;\n /**\n * Returns the smallest number greater than or equal to its numeric argument.\n * @param x A numeric expression.\n */\n ceil(x: number): number;\n /**\n * Returns the cosine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n cos(x: number): number;\n /**\n * Returns e (the base of natural logarithms) raised to a power.\n * @param x A numeric expression representing the power of e.\n */\n exp(x: number): number;\n /**\n * Returns the greatest number less than or equal to its numeric argument.\n * @param x A numeric expression.\n */\n floor(x: number): number;\n /**\n * Returns the natural logarithm (base e) of a number.\n * @param x A numeric expression.\n */\n log(x: number): number;\n /**\n * Returns the larger of a set of supplied numeric expressions.\n * @param values Numeric expressions to be evaluated.\n */\n max(...values: number[]): number;\n /**\n * Returns the smaller of a set of supplied numeric expressions.\n * @param values Numeric expressions to be evaluated.\n */\n min(...values: number[]): number;\n /**\n * Returns the value of a base expression taken to a specified power.\n * @param x The base value of the expression.\n * @param y The exponent value of the expression.\n */\n pow(x: number, y: number): number;\n /** Returns a pseudorandom number between 0 and 1. */\n random(): number;\n /**\n * Returns a supplied numeric expression rounded to the nearest number.\n * @param x The value to be rounded to the nearest number.\n */\n round(x: number): number;\n /**\n * Returns the sine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n sin(x: number): number;\n /**\n * Returns the square root of a number.\n * @param x A numeric expression.\n */\n sqrt(x: number): number;\n /**\n * Returns the tangent of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n tan(x: number): number;\n}\n/** An intrinsic object that provides basic mathematics functionality and constants. */\ndeclare const Math: Math;\n\n/** Enables basic storage and retrieval of dates and times. */\ninterface Date {\n /** Returns a string representation of a date. The format of the string depends on the locale. */\n toString(): string;\n /** Returns a date as a string value. */\n toDateString(): string;\n /** Returns a time as a string value. */\n toTimeString(): string;\n /** Returns a value as a string value appropriate to the host environment's current locale. */\n toLocaleString(): string;\n /** Returns a date as a string value appropriate to the host environment's current locale. */\n toLocaleDateString(): string;\n /** Returns a time as a string value appropriate to the host environment's current locale. */\n toLocaleTimeString(): string;\n /** Returns the stored time value in milliseconds since midnight, January 1, 1970 UTC. */\n valueOf(): number;\n /** Gets the time value in milliseconds. */\n getTime(): number;\n /** Gets the year, using local time. */\n getFullYear(): number;\n /** Gets the year using Universal Coordinated Time (UTC). */\n getUTCFullYear(): number;\n /** Gets the month, using local time. */\n getMonth(): number;\n /** Gets the month of a Date object using Universal Coordinated Time (UTC). */\n getUTCMonth(): number;\n /** Gets the day-of-the-month, using local time. */\n getDate(): number;\n /** Gets the day-of-the-month, using Universal Coordinated Time (UTC). */\n getUTCDate(): number;\n /** Gets the day of the week, using local time. */\n getDay(): number;\n /** Gets the day of the week using Universal Coordinated Time (UTC). */\n getUTCDay(): number;\n /** Gets the hours in a date, using local time. */\n getHours(): number;\n /** Gets the hours value in a Date object using Universal Coordinated Time (UTC). */\n getUTCHours(): number;\n /** Gets the minutes of a Date object, using local time. */\n getMinutes(): number;\n /** Gets the minutes of a Date object using Universal Coordinated Time (UTC). */\n getUTCMinutes(): number;\n /** Gets the seconds of a Date object, using local time. */\n getSeconds(): number;\n /** Gets the seconds of a Date object using Universal Coordinated Time (UTC). */\n getUTCSeconds(): number;\n /** Gets the milliseconds of a Date, using local time. */\n getMilliseconds(): number;\n /** Gets the milliseconds of a Date object using Universal Coordinated Time (UTC). */\n getUTCMilliseconds(): number;\n /** Gets the difference in minutes between the time on the local computer and Universal Coordinated Time (UTC). */\n getTimezoneOffset(): number;\n /**\n * Sets the date and time value in the Date object.\n * @param time A numeric value representing the number of elapsed milliseconds since midnight, January 1, 1970 GMT.\n */\n setTime(time: number): number;\n /**\n * Sets the milliseconds value in the Date object using local time.\n * @param ms A numeric value equal to the millisecond value.\n */\n setMilliseconds(ms: number): number;\n /**\n * Sets the milliseconds value in the Date object using Universal Coordinated Time (UTC).\n * @param ms A numeric value equal to the millisecond value.\n */\n setUTCMilliseconds(ms: number): number;\n\n /**\n * Sets the seconds value in the Date object using local time.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setSeconds(sec: number, ms?: number): number;\n /**\n * Sets the seconds value in the Date object using Universal Coordinated Time (UTC).\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setUTCSeconds(sec: number, ms?: number): number;\n /**\n * Sets the minutes value in the Date object using local time.\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setMinutes(min: number, sec?: number, ms?: number): number;\n /**\n * Sets the minutes value in the Date object using Universal Coordinated Time (UTC).\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setUTCMinutes(min: number, sec?: number, ms?: number): number;\n /**\n * Sets the hour value in the Date object using local time.\n * @param hours A numeric value equal to the hours value.\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setHours(hours: number, min?: number, sec?: number, ms?: number): number;\n /**\n * Sets the hours value in the Date object using Universal Coordinated Time (UTC).\n * @param hours A numeric value equal to the hours value.\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setUTCHours(hours: number, min?: number, sec?: number, ms?: number): number;\n /**\n * Sets the numeric day-of-the-month value of the Date object using local time.\n * @param date A numeric value equal to the day of the month.\n */\n setDate(date: number): number;\n /**\n * Sets the numeric day of the month in the Date object using Universal Coordinated Time (UTC).\n * @param date A numeric value equal to the day of the month.\n */\n setUTCDate(date: number): number;\n /**\n * Sets the month value in the Date object using local time.\n * @param month A numeric value equal to the month. The value for January is 0, and other month values follow consecutively.\n * @param date A numeric value representing the day of the month. If this value is not supplied, the value from a call to the getDate method is used.\n */\n setMonth(month: number, date?: number): number;\n /**\n * Sets the month value in the Date object using Universal Coordinated Time (UTC).\n * @param month A numeric value equal to the month. The value for January is 0, and other month values follow consecutively.\n * @param date A numeric value representing the day of the month. If it is not supplied, the value from a call to the getUTCDate method is used.\n */\n setUTCMonth(month: number, date?: number): number;\n /**\n * Sets the year of the Date object using local time.\n * @param year A numeric value for the year.\n * @param month A zero-based numeric value for the month (0 for January, 11 for December). Must be specified if numDate is specified.\n * @param date A numeric value equal for the day of the month.\n */\n setFullYear(year: number, month?: number, date?: number): number;\n /**\n * Sets the year value in the Date object using Universal Coordinated Time (UTC).\n * @param year A numeric value equal to the year.\n * @param month A numeric value equal to the month. The value for January is 0, and other month values follow consecutively. Must be supplied if numDate is supplied.\n * @param date A numeric value equal to the day of the month.\n */\n setUTCFullYear(year: number, month?: number, date?: number): number;\n /** Returns a date converted to a string using Universal Coordinated Time (UTC). */\n toUTCString(): string;\n /** Returns a date as a string value in ISO format. */\n toISOString(): string;\n /** Used by the JSON.stringify method to enable the transformation of an object's data for JavaScript Object Notation (JSON) serialization. */\n toJSON(key?: any): string;\n}\n\ninterface DateConstructor {\n new (): Date;\n new (value: number): Date;\n new (value: string): Date;\n new (year: number, month: number, date?: number, hours?: number, minutes?: number, seconds?: number, ms?: number): Date;\n (): string;\n readonly prototype: Date;\n /**\n * Parses a string containing a date, and returns the number of milliseconds between that date and midnight, January 1, 1970.\n * @param s A date string\n */\n parse(s: string): number;\n /**\n * Returns the number of milliseconds between midnight, January 1, 1970 Universal Coordinated Time (UTC) (or GMT) and the specified date.\n * @param year The full year designation is required for cross-century date accuracy. If year is between 0 and 99 is used, then year is assumed to be 1900 + year.\n * @param month The month as an number between 0 and 11 (January to December).\n * @param date The date as an number between 1 and 31.\n * @param hours Must be supplied if minutes is supplied. An number from 0 to 23 (midnight to 11pm) that specifies the hour.\n * @param minutes Must be supplied if seconds is supplied. An number from 0 to 59 that specifies the minutes.\n * @param seconds Must be supplied if milliseconds is supplied. An number from 0 to 59 that specifies the seconds.\n * @param ms An number from 0 to 999 that specifies the milliseconds.\n */\n UTC(year: number, month: number, date?: number, hours?: number, minutes?: number, seconds?: number, ms?: number): number;\n now(): number;\n}\n\ndeclare const Date: DateConstructor;\n\ninterface RegExpMatchArray extends Array {\n index?: number;\n input?: string;\n}\n\ninterface RegExpExecArray extends Array {\n index: number;\n input: string;\n}\n\ninterface RegExp {\n /**\n * Executes a search on a string using a regular expression pattern, and returns an array containing the results of that search.\n * @param string The String object or string literal on which to perform the search.\n */\n exec(string: string): RegExpExecArray | null;\n\n /**\n * Returns a Boolean value that indicates whether or not a pattern exists in a searched string.\n * @param string String on which to perform the search.\n */\n test(string: string): boolean;\n\n /** Returns a copy of the text of the regular expression pattern. Read-only. The regExp argument is a Regular expression object. It can be a variable name or a literal. */\n readonly source: string;\n\n /** Returns a Boolean value indicating the state of the global flag (g) used with a regular expression. Default is false. Read-only. */\n readonly global: boolean;\n\n /** Returns a Boolean value indicating the state of the ignoreCase flag (i) used with a regular expression. Default is false. Read-only. */\n readonly ignoreCase: boolean;\n\n /** Returns a Boolean value indicating the state of the multiline flag (m) used with a regular expression. Default is false. Read-only. */\n readonly multiline: boolean;\n\n lastIndex: number;\n\n // Non-standard extensions\n compile(): this;\n}\n\ninterface RegExpConstructor {\n new (pattern: RegExp | string): RegExp;\n new (pattern: string, flags?: string): RegExp;\n (pattern: RegExp | string): RegExp;\n (pattern: string, flags?: string): RegExp;\n readonly prototype: RegExp;\n\n // Non-standard extensions\n $1: string;\n $2: string;\n $3: string;\n $4: string;\n $5: string;\n $6: string;\n $7: string;\n $8: string;\n $9: string;\n lastMatch: string;\n}\n\ndeclare const RegExp: RegExpConstructor;\n\ninterface Error {\n name: string;\n message: string;\n stack?: string;\n}\n\ninterface ErrorConstructor {\n new (message?: string): Error;\n (message?: string): Error;\n readonly prototype: Error;\n}\n\ndeclare const Error: ErrorConstructor;\n\ninterface EvalError extends Error {\n}\n\ninterface EvalErrorConstructor {\n new (message?: string): EvalError;\n (message?: string): EvalError;\n readonly prototype: EvalError;\n}\n\ndeclare const EvalError: EvalErrorConstructor;\n\ninterface RangeError extends Error {\n}\n\ninterface RangeErrorConstructor {\n new (message?: string): RangeError;\n (message?: string): RangeError;\n readonly prototype: RangeError;\n}\n\ndeclare const RangeError: RangeErrorConstructor;\n\ninterface ReferenceError extends Error {\n}\n\ninterface ReferenceErrorConstructor {\n new (message?: string): ReferenceError;\n (message?: string): ReferenceError;\n readonly prototype: ReferenceError;\n}\n\ndeclare const ReferenceError: ReferenceErrorConstructor;\n\ninterface SyntaxError extends Error {\n}\n\ninterface SyntaxErrorConstructor {\n new (message?: string): SyntaxError;\n (message?: string): SyntaxError;\n readonly prototype: SyntaxError;\n}\n\ndeclare const SyntaxError: SyntaxErrorConstructor;\n\ninterface TypeError extends Error {\n}\n\ninterface TypeErrorConstructor {\n new (message?: string): TypeError;\n (message?: string): TypeError;\n readonly prototype: TypeError;\n}\n\ndeclare const TypeError: TypeErrorConstructor;\n\ninterface URIError extends Error {\n}\n\ninterface URIErrorConstructor {\n new (message?: string): URIError;\n (message?: string): URIError;\n readonly prototype: URIError;\n}\n\ndeclare const URIError: URIErrorConstructor;\n\ninterface JSON {\n /**\n * Converts a JavaScript Object Notation (JSON) string into an object.\n * @param text A valid JSON string.\n * @param reviver A function that transforms the results. This function is called for each member of the object.\n * If a member contains nested objects, the nested objects are transformed before the parent object is.\n */\n parse(text: string, reviver?: (key: any, value: any) => any): any;\n /**\n * Converts a JavaScript value to a JavaScript Object Notation (JSON) string.\n * @param value A JavaScript value, usually an object or array, to be converted.\n * @param replacer A function that transforms the results.\n * @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.\n */\n stringify(value: any, replacer?: (key: string, value: any) => any, space?: string | number): string;\n /**\n * Converts a JavaScript value to a JavaScript Object Notation (JSON) string.\n * @param value A JavaScript value, usually an object or array, to be converted.\n * @param replacer An array of strings and numbers that acts as a approved list for selecting the object properties that will be stringified.\n * @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.\n */\n stringify(value: any, replacer?: (number | string)[] | null, space?: string | number): string;\n}\n\n/**\n * An intrinsic object that provides functions to convert JavaScript values to and from the JavaScript Object Notation (JSON) format.\n */\ndeclare const JSON: JSON;\n\n\n/////////////////////////////\n/// ECMAScript Array API (specially handled by compiler)\n/////////////////////////////\n\ninterface ReadonlyArray {\n /**\n * Gets the length of the array. This is a number one higher than the highest element defined in an array.\n */\n readonly length: number;\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n toLocaleString(): string;\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat>(...items: U[]): T[];\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: T[][]): T[];\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: (T | T[])[]): T[];\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): T[];\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.\n */\n indexOf(searchElement: T, fromIndex?: number): number;\n\n /**\n * Returns the index of the last occurrence of a specified value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at the last index in the array.\n */\n lastIndexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls the callbackfn function for each element in array1 until the callbackfn returns false, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => boolean): boolean;\n every(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: T, index: number, array: ReadonlyArray) => boolean, thisArg: Z): boolean;\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the callbackfn function for each element in array1 until the callbackfn returns true, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => boolean): boolean;\n some(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: T, index: number, array: ReadonlyArray) => boolean, thisArg: Z): boolean;\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => void): void;\n forEach(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: T, index: number, array: ReadonlyArray) => void, thisArg: Z): void;\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => U): U[];\n map(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => U, thisArg: undefined): U[];\n map(callbackfn: (this: Z, value: T, index: number, array: ReadonlyArray) => U, thisArg: Z): U[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => value is S): S[];\n filter(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => value is S, thisArg: undefined): S[];\n filter(callbackfn: (this: Z, value: T, index: number, array: ReadonlyArray) => value is S, thisArg: Z): S[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => any): T[];\n filter(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => any, thisArg: undefined): T[];\n filter(callbackfn: (this: Z, value: T, index: number, array: ReadonlyArray) => any, thisArg: Z): T[];\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: ReadonlyArray) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: ReadonlyArray) => U, initialValue: U): U;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: ReadonlyArray) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: ReadonlyArray) => U, initialValue: U): U;\n\n readonly [n: number]: T;\n}\n\ninterface Array {\n /**\n * Gets or sets the length of the array. This is a number one higher than the highest element defined in an array.\n */\n length: number;\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n toLocaleString(): string;\n /**\n * Appends new elements to an array, and returns the new length of the array.\n * @param items New elements of the Array.\n */\n push(...items: T[]): number;\n /**\n * Removes the last element from an array and returns it.\n */\n pop(): T | undefined;\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: T[][]): T[];\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: (T | T[])[]): T[];\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n /**\n * Reverses the elements in an Array.\n */\n reverse(): T[];\n /**\n * Removes the first element from an array and returns it.\n */\n shift(): T | undefined;\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): T[];\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: T, b: T) => number): this;\n /**\n * Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.\n * @param start The zero-based location in the array from which to start removing elements.\n * @param deleteCount The number of elements to remove.\n */\n splice(start: number, deleteCount?: number): T[];\n /**\n * Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.\n * @param start The zero-based location in the array from which to start removing elements.\n * @param deleteCount The number of elements to remove.\n * @param items Elements to insert into the array in place of the deleted elements.\n */\n splice(start: number, deleteCount: number, ...items: T[]): T[];\n /**\n * Inserts new elements at the start of an array.\n * @param items Elements to insert at the start of the Array.\n */\n unshift(...items: T[]): number;\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.\n */\n indexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Returns the index of the last occurrence of a specified value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at the last index in the array.\n */\n lastIndexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls the callbackfn function for each element in array1 until the callbackfn returns false, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: T, index: number, array: T[]) => boolean): boolean;\n every(callbackfn: (this: void, value: T, index: number, array: T[]) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: T, index: number, array: T[]) => boolean, thisArg: Z): boolean;\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the callbackfn function for each element in array1 until the callbackfn returns true, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: T, index: number, array: T[]) => boolean): boolean;\n some(callbackfn: (this: void, value: T, index: number, array: T[]) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: T, index: number, array: T[]) => boolean, thisArg: Z): boolean;\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: T, index: number, array: T[]) => void): void;\n forEach(callbackfn: (this: void, value: T, index: number, array: T[]) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: T, index: number, array: T[]) => void, thisArg: Z): void;\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(this: [T, T, T, T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U): [U, U, U, U, U];\n map(this: [T, T, T, T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U, thisArg: undefined): [U, U, U, U, U];\n map(this: [T, T, T, T, T], callbackfn: (this: Z, value: T, index: number, array: T[]) => U, thisArg: Z): [U, U, U, U, U];\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(this: [T, T, T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U): [U, U, U, U];\n map(this: [T, T, T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U, thisArg: undefined): [U, U, U, U];\n map(this: [T, T, T, T], callbackfn: (this: Z, value: T, index: number, array: T[]) => U, thisArg: Z): [U, U, U, U];\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(this: [T, T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U): [U, U, U];\n map(this: [T, T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U, thisArg: undefined): [U, U, U];\n map(this: [T, T, T], callbackfn: (this: Z, value: T, index: number, array: T[]) => U, thisArg: Z): [U, U, U];\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(this: [T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U): [U, U];\n map(this: [T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U, thisArg: undefined): [U, U];\n map(this: [T, T], callbackfn: (this: Z, value: T, index: number, array: T[]) => U, thisArg: Z): [U, U];\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: T, index: number, array: T[]) => U): U[];\n map(callbackfn: (this: void, value: T, index: number, array: T[]) => U, thisArg: undefined): U[];\n map(callbackfn: (this: Z, value: T, index: number, array: T[]) => U, thisArg: Z): U[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: T, index: number, array: T[]) => any): T[];\n filter(callbackfn: (this: void, value: T, index: number, array: T[]) => any, thisArg: undefined): T[];\n filter(callbackfn: (this: Z, value: T, index: number, array: T[]) => any, thisArg: Z): T[];\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: T[]) => U, initialValue: U): U;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: T[]) => U, initialValue: U): U;\n\n [n: number]: T;\n}\n\ninterface ArrayConstructor {\n new (arrayLength?: number): any[];\n new (arrayLength: number): T[];\n new (...items: T[]): T[];\n (arrayLength?: number): any[];\n (arrayLength: number): T[];\n (...items: T[]): T[];\n isArray(arg: any): arg is Array;\n readonly prototype: Array;\n}\n\ndeclare const Array: ArrayConstructor;\n\ninterface TypedPropertyDescriptor {\n enumerable?: boolean;\n configurable?: boolean;\n writable?: boolean;\n value?: T;\n get?: () => T;\n set?: (value: T) => void;\n}\n\ndeclare type ClassDecorator = (target: TFunction) => TFunction | void;\ndeclare type PropertyDecorator = (target: Object, propertyKey: string | symbol) => void;\ndeclare type MethodDecorator = (target: Object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor) => TypedPropertyDescriptor | void;\ndeclare type ParameterDecorator = (target: Object, propertyKey: string | symbol, parameterIndex: number) => void;\n\ndeclare type PromiseConstructorLike = new (executor: (resolve: (value?: T | PromiseLike) => void, reject: (reason?: any) => void) => void) => PromiseLike;\n\ninterface PromiseLike {\n /**\n * Attaches callbacks for the resolution and/or rejection of the Promise.\n * @param onfulfilled The callback to execute when the Promise is resolved.\n * @param onrejected The callback to execute when the Promise is rejected.\n * @returns A Promise for the completion of which ever callback is executed.\n */\n then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): PromiseLike;\n}\n\n/**\n * Represents the completion of an asynchronous operation\n */\ninterface Promise {\n /**\n * Attaches callbacks for the resolution and/or rejection of the Promise.\n * @param onfulfilled The callback to execute when the Promise is resolved.\n * @param onrejected The callback to execute when the Promise is rejected.\n * @returns A Promise for the completion of which ever callback is executed.\n */\n then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): Promise;\n\n /**\n * Attaches a callback for only the rejection of the Promise.\n * @param onrejected The callback to execute when the Promise is rejected.\n * @returns A Promise for the completion of the callback.\n */\n catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): Promise;\n}\n\ninterface ArrayLike {\n readonly length: number;\n readonly [n: number]: T;\n}\n\n/**\n * Make all properties in T optional\n */\ntype Partial = {\n [P in keyof T]?: T[P];\n};\n\n/**\n * Make all properties in T readonly\n */\ntype Readonly = {\n readonly [P in keyof T]: T[P];\n};\n\n/**\n * From T pick a set of properties K\n */\ntype Pick = {\n [P in K]: T[P];\n};\n\n/**\n * Construct a type with a set of properties K of type T\n */\ntype Record = {\n [P in K]: T;\n};\n\n/**\n * Marker for contextual 'this' type\n */\ninterface ThisType { }\n\n/**\n * Represents a raw buffer of binary data, which is used to store data for the\n * different typed arrays. ArrayBuffers cannot be read from or written to directly,\n * but can be passed to a typed array or DataView Object to interpret the raw\n * buffer as needed.\n */\ninterface ArrayBuffer {\n /**\n * Read-only. The length of the ArrayBuffer (in bytes).\n */\n readonly byteLength: number;\n\n /**\n * Returns a section of an ArrayBuffer.\n */\n slice(begin: number, end?: number): ArrayBuffer;\n}\n\ninterface ArrayBufferConstructor {\n readonly prototype: ArrayBuffer;\n new (byteLength: number): ArrayBuffer;\n isView(arg: any): arg is ArrayBufferView;\n}\ndeclare const ArrayBuffer: ArrayBufferConstructor;\n\ninterface ArrayBufferView {\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n byteOffset: number;\n}\n\ninterface DataView {\n readonly buffer: ArrayBuffer;\n readonly byteLength: number;\n readonly byteOffset: number;\n /**\n * Gets the Float32 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getFloat32(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Float64 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getFloat64(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Int8 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getInt8(byteOffset: number): number;\n\n /**\n * Gets the Int16 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getInt16(byteOffset: number, littleEndian?: boolean): number;\n /**\n * Gets the Int32 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getInt32(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Uint8 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getUint8(byteOffset: number): number;\n\n /**\n * Gets the Uint16 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getUint16(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Uint32 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getUint32(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Stores an Float32 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setFloat32(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Float64 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setFloat64(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Int8 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n */\n setInt8(byteOffset: number, value: number): void;\n\n /**\n * Stores an Int16 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setInt16(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Int32 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setInt32(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Uint8 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n */\n setUint8(byteOffset: number, value: number): void;\n\n /**\n * Stores an Uint16 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setUint16(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Uint32 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setUint32(byteOffset: number, value: number, littleEndian?: boolean): void;\n}\n\ninterface DataViewConstructor {\n new (buffer: ArrayBuffer, byteOffset?: number, byteLength?: number): DataView;\n}\ndeclare const DataView: DataViewConstructor;\n\n/**\n * A typed array of 8-bit integer values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Int8Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Int8Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Int8Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Int8Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Int8Array) => any): Int8Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Int8Array) => any, thisArg: undefined): Int8Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Int8Array) => any, thisArg: Z): Int8Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Int8Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Int8Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Int8Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Int8Array) => number): Int8Array;\n map(callbackfn: (this: void, value: number, index: number, array: Int8Array) => number, thisArg: undefined): Int8Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Int8Array) => number, thisArg: Z): Int8Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int8Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int8Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Int8Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Int8Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Int8Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Int8Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Int8Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Int8Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Int8Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\ninterface Int8ArrayConstructor {\n readonly prototype: Int8Array;\n new (length: number): Int8Array;\n new (array: ArrayLike): Int8Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Int8Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Int8Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Int8Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Int8Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Int8Array;\n\n from(arrayLike: ArrayLike): Int8Array;\n\n}\ndeclare const Int8Array: Int8ArrayConstructor;\n\n/**\n * A typed array of 8-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Uint8Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => any): Uint8Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => any, thisArg: undefined): Uint8Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Uint8Array) => any, thisArg: Z): Uint8Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Uint8Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => number): Uint8Array;\n map(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => number, thisArg: undefined): Uint8Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Uint8Array) => number, thisArg: Z): Uint8Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint8Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint8Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Uint8Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint8Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint8Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint8ArrayConstructor {\n readonly prototype: Uint8Array;\n new (length: number): Uint8Array;\n new (array: ArrayLike): Uint8Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Uint8Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint8Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Uint8Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint8Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint8Array;\n\n from(arrayLike: ArrayLike): Uint8Array;\n\n}\ndeclare const Uint8Array: Uint8ArrayConstructor;\n\n/**\n * A typed array of 8-bit unsigned integer (clamped) values. The contents are initialized to 0.\n * If the requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8ClampedArray {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Uint8ClampedArray) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => any): Uint8ClampedArray;\n filter(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => any, thisArg: undefined): Uint8ClampedArray;\n filter(callbackfn: (this: Z, value: number, index: number, array: Uint8ClampedArray) => any, thisArg: Z): Uint8ClampedArray;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Uint8ClampedArray) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => number): Uint8ClampedArray;\n map(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => number, thisArg: undefined): Uint8ClampedArray;\n map(callbackfn: (this: Z, value: number, index: number, array: Uint8ClampedArray) => number, thisArg: Z): Uint8ClampedArray;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint8ClampedArray;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint8ClampedArray;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Uint8ClampedArray) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint8ClampedArray view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint8ClampedArray;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint8ClampedArrayConstructor {\n readonly prototype: Uint8ClampedArray;\n new (length: number): Uint8ClampedArray;\n new (array: ArrayLike): Uint8ClampedArray;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Uint8ClampedArray;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint8ClampedArray;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Uint8ClampedArray;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint8ClampedArray;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint8ClampedArray;\n\n from(arrayLike: ArrayLike): Uint8ClampedArray;\n}\ndeclare const Uint8ClampedArray: Uint8ClampedArrayConstructor;\n\n/**\n * A typed array of 16-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int16Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Int16Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Int16Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Int16Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Int16Array) => any): Int16Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Int16Array) => any, thisArg: undefined): Int16Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Int16Array) => any, thisArg: Z): Int16Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Int16Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Int16Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Int16Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Int16Array) => number): Int16Array;\n map(callbackfn: (this: void, value: number, index: number, array: Int16Array) => number, thisArg: undefined): Int16Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Int16Array) => number, thisArg: Z): Int16Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int16Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int16Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Int16Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Int16Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Int16Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Int16Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Int16Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Int16Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Int16Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Int16ArrayConstructor {\n readonly prototype: Int16Array;\n new (length: number): Int16Array;\n new (array: ArrayLike): Int16Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Int16Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Int16Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Int16Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Int16Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Int16Array;\n\n from(arrayLike: ArrayLike): Int16Array;\n\n}\ndeclare const Int16Array: Int16ArrayConstructor;\n\n/**\n * A typed array of 16-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint16Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Uint16Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => any): Uint16Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => any, thisArg: undefined): Uint16Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Uint16Array) => any, thisArg: Z): Uint16Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Uint16Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => number): Uint16Array;\n map(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => number, thisArg: undefined): Uint16Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Uint16Array) => number, thisArg: Z): Uint16Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint16Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint16Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint16Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint16Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Uint16Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint16Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint16Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint16ArrayConstructor {\n readonly prototype: Uint16Array;\n new (length: number): Uint16Array;\n new (array: ArrayLike): Uint16Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Uint16Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint16Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Uint16Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint16Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint16Array;\n\n from(arrayLike: ArrayLike): Uint16Array;\n\n}\ndeclare const Uint16Array: Uint16ArrayConstructor;\n/**\n * A typed array of 32-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int32Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Int32Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Int32Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Int32Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Int32Array) => any): Int32Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Int32Array) => any, thisArg: undefined): Int32Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Int32Array) => any, thisArg: Z): Int32Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Int32Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Int32Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Int32Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Int32Array) => number): Int32Array;\n map(callbackfn: (this: void, value: number, index: number, array: Int32Array) => number, thisArg: undefined): Int32Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Int32Array) => number, thisArg: Z): Int32Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int32Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int32Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Int32Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Int32Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Int32Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Int32Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Int32Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Int32Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Int32Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Int32ArrayConstructor {\n readonly prototype: Int32Array;\n new (length: number): Int32Array;\n new (array: ArrayLike): Int32Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Int32Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Int32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Int32Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Int32Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Int32Array;\n\n from(arrayLike: ArrayLike): Int32Array;\n}\ndeclare const Int32Array: Int32ArrayConstructor;\n\n/**\n * A typed array of 32-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint32Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Uint32Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => any): Uint32Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => any, thisArg: undefined): Uint32Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Uint32Array) => any, thisArg: Z): Uint32Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Uint32Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => number): Uint32Array;\n map(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => number, thisArg: undefined): Uint32Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Uint32Array) => number, thisArg: Z): Uint32Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint32Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint32Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint32Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint32Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Uint32Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint32Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint32Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint32ArrayConstructor {\n readonly prototype: Uint32Array;\n new (length: number): Uint32Array;\n new (array: ArrayLike): Uint32Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Uint32Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Uint32Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint32Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint32Array;\n\n from(arrayLike: ArrayLike): Uint32Array;\n}\ndeclare const Uint32Array: Uint32ArrayConstructor;\n\n/**\n * A typed array of 32-bit float values. The contents are initialized to 0. If the requested number\n * of bytes could not be allocated an exception is raised.\n */\ninterface Float32Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Float32Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Float32Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Float32Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Float32Array) => any): Float32Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Float32Array) => any, thisArg: undefined): Float32Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Float32Array) => any, thisArg: Z): Float32Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Float32Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Float32Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Float32Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Float32Array) => number): Float32Array;\n map(callbackfn: (this: void, value: number, index: number, array: Float32Array) => number, thisArg: undefined): Float32Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Float32Array) => number, thisArg: Z): Float32Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float32Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float32Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Float32Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Float32Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Float32Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Float32Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Float32Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Float32Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Float32Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Float32ArrayConstructor {\n readonly prototype: Float32Array;\n new (length: number): Float32Array;\n new (array: ArrayLike): Float32Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Float32Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Float32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Float32Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Float32Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Float32Array;\n\n from(arrayLike: ArrayLike): Float32Array;\n\n}\ndeclare const Float32Array: Float32ArrayConstructor;\n\n/**\n * A typed array of 64-bit float values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Float64Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Float64Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Float64Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Float64Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Float64Array) => any): Float64Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Float64Array) => any, thisArg: undefined): Float64Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Float64Array) => any, thisArg: Z): Float64Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Float64Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Float64Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Float64Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Float64Array) => number): Float64Array;\n map(callbackfn: (this: void, value: number, index: number, array: Float64Array) => number, thisArg: undefined): Float64Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Float64Array) => number, thisArg: Z): Float64Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float64Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float64Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float64Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float64Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Float64Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Float64Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Float64Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Float64Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Float64Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Float64Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Float64Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Float64ArrayConstructor {\n readonly prototype: Float64Array;\n new (length: number): Float64Array;\n new (array: ArrayLike): Float64Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Float64Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Float64Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Float64Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Float64Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Float64Array;\n\n from(arrayLike: ArrayLike): Float64Array;\n}\ndeclare const Float64Array: Float64ArrayConstructor;\n\n/////////////////////////////\n/// ECMAScript Internationalization API\n/////////////////////////////\n\ndeclare namespace Intl {\n interface CollatorOptions {\n usage?: string;\n localeMatcher?: string;\n numeric?: boolean;\n caseFirst?: string;\n sensitivity?: string;\n ignorePunctuation?: boolean;\n }\n\n interface ResolvedCollatorOptions {\n locale: string;\n usage: string;\n sensitivity: string;\n ignorePunctuation: boolean;\n collation: string;\n caseFirst: string;\n numeric: boolean;\n }\n\n interface Collator {\n compare(x: string, y: string): number;\n resolvedOptions(): ResolvedCollatorOptions;\n }\n var Collator: {\n new (locales?: string | string[], options?: CollatorOptions): Collator;\n (locales?: string | string[], options?: CollatorOptions): Collator;\n supportedLocalesOf(locales: string | string[], options?: CollatorOptions): string[];\n };\n\n interface NumberFormatOptions {\n localeMatcher?: string;\n style?: string;\n currency?: string;\n currencyDisplay?: string;\n useGrouping?: boolean;\n minimumIntegerDigits?: number;\n minimumFractionDigits?: number;\n maximumFractionDigits?: number;\n minimumSignificantDigits?: number;\n maximumSignificantDigits?: number;\n }\n\n interface ResolvedNumberFormatOptions {\n locale: string;\n numberingSystem: string;\n style: string;\n currency?: string;\n currencyDisplay?: string;\n minimumIntegerDigits: number;\n minimumFractionDigits: number;\n maximumFractionDigits: number;\n minimumSignificantDigits?: number;\n maximumSignificantDigits?: number;\n useGrouping: boolean;\n }\n\n interface NumberFormat {\n format(value: number): string;\n resolvedOptions(): ResolvedNumberFormatOptions;\n }\n var NumberFormat: {\n new (locales?: string | string[], options?: NumberFormatOptions): NumberFormat;\n (locales?: string | string[], options?: NumberFormatOptions): NumberFormat;\n supportedLocalesOf(locales: string | string[], options?: NumberFormatOptions): string[];\n };\n\n interface DateTimeFormatOptions {\n localeMatcher?: string;\n weekday?: string;\n era?: string;\n year?: string;\n month?: string;\n day?: string;\n hour?: string;\n minute?: string;\n second?: string;\n timeZoneName?: string;\n formatMatcher?: string;\n hour12?: boolean;\n timeZone?: string;\n }\n\n interface ResolvedDateTimeFormatOptions {\n locale: string;\n calendar: string;\n numberingSystem: string;\n timeZone: string;\n hour12?: boolean;\n weekday?: string;\n era?: string;\n year?: string;\n month?: string;\n day?: string;\n hour?: string;\n minute?: string;\n second?: string;\n timeZoneName?: string;\n }\n\n interface DateTimeFormat {\n format(date?: Date | number): string;\n resolvedOptions(): ResolvedDateTimeFormatOptions;\n }\n var DateTimeFormat: {\n new (locales?: string | string[], options?: DateTimeFormatOptions): DateTimeFormat;\n (locales?: string | string[], options?: DateTimeFormatOptions): DateTimeFormat;\n supportedLocalesOf(locales: string | string[], options?: DateTimeFormatOptions): string[];\n };\n}\n\ninterface String {\n /**\n * Determines whether two strings are equivalent in the current or specified locale.\n * @param that String to compare to target string\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used. This parameter must conform to BCP 47 standards; see the Intl.Collator object for details.\n * @param options An object that contains one or more properties that specify comparison options. see the Intl.Collator object for details.\n */\n localeCompare(that: string, locales?: string | string[], options?: Intl.CollatorOptions): number;\n}\n\ninterface Number {\n /**\n * Converts a number to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleString(locales?: string | string[], options?: Intl.NumberFormatOptions): string;\n}\n\ninterface Date {\n /**\n * Converts a date and time to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleString(locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;\n /**\n * Converts a date to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleDateString(locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;\n\n /**\n * Converts a time to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleTimeString(locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;\n}\n\n\ndeclare type PropertyKey = string | number | symbol;\n\ninterface Array {\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: T, index: number, obj: Array) => boolean): T | undefined;\n find(predicate: (this: void, value: T, index: number, obj: Array) => boolean, thisArg: undefined): T | undefined;\n find(predicate: (this: Z, value: T, index: number, obj: Array) => boolean, thisArg: Z): T | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: T, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: T, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: T, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: T, start?: number, end?: number): this;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n}\n\ninterface ArrayConstructor {\n /**\n * Creates an array from an array-like object.\n * @param arrayLike An array-like object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: T, k: number) => U): Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: T, k: number) => U, thisArg: undefined): Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: T, k: number) => U, thisArg: Z): Array;\n\n\n /**\n * Creates an array from an array-like object.\n * @param arrayLike An array-like object to convert to an array.\n */\n from(arrayLike: ArrayLike): Array;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: T[]): Array;\n}\n\ninterface DateConstructor {\n new (value: Date): Date;\n}\n\ninterface Function {\n /**\n * Returns the name of the function. Function names are read-only and can not be changed.\n */\n readonly name: string;\n}\n\ninterface Math {\n /**\n * Returns the number of leading zero bits in the 32-bit binary representation of a number.\n * @param x A numeric expression.\n */\n clz32(x: number): number;\n\n /**\n * Returns the result of 32-bit multiplication of two numbers.\n * @param x First number\n * @param y Second number\n */\n imul(x: number, y: number): number;\n\n /**\n * Returns the sign of the x, indicating whether x is positive, negative or zero.\n * @param x The numeric expression to test\n */\n sign(x: number): number;\n\n /**\n * Returns the base 10 logarithm of a number.\n * @param x A numeric expression.\n */\n log10(x: number): number;\n\n /**\n * Returns the base 2 logarithm of a number.\n * @param x A numeric expression.\n */\n log2(x: number): number;\n\n /**\n * Returns the natural logarithm of 1 + x.\n * @param x A numeric expression.\n */\n log1p(x: number): number;\n\n /**\n * Returns the result of (e^x - 1) of x (e raised to the power of x, where e is the base of\n * the natural logarithms).\n * @param x A numeric expression.\n */\n expm1(x: number): number;\n\n /**\n * Returns the hyperbolic cosine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n cosh(x: number): number;\n\n /**\n * Returns the hyperbolic sine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n sinh(x: number): number;\n\n /**\n * Returns the hyperbolic tangent of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n tanh(x: number): number;\n\n /**\n * Returns the inverse hyperbolic cosine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n acosh(x: number): number;\n\n /**\n * Returns the inverse hyperbolic sine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n asinh(x: number): number;\n\n /**\n * Returns the inverse hyperbolic tangent of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n atanh(x: number): number;\n\n /**\n * Returns the square root of the sum of squares of its arguments.\n * @param values Values to compute the square root for.\n * If no arguments are passed, the result is +0.\n * If there is only one argument, the result is the absolute value.\n * If any argument is +Infinity or -Infinity, the result is +Infinity.\n * If any argument is NaN, the result is NaN.\n * If all arguments are either +0 or −0, the result is +0.\n */\n hypot(...values: number[] ): number;\n\n /**\n * Returns the integral part of the a numeric expression, x, removing any fractional digits.\n * If x is already an integer, the result is x.\n * @param x A numeric expression.\n */\n trunc(x: number): number;\n\n /**\n * Returns the nearest single precision float representation of a number.\n * @param x A numeric expression.\n */\n fround(x: number): number;\n\n /**\n * Returns an implementation-dependent approximation to the cube root of number.\n * @param x A numeric expression.\n */\n cbrt(x: number): number;\n}\n\ninterface NumberConstructor {\n /**\n * The value of Number.EPSILON is the difference between 1 and the smallest value greater than 1\n * that is representable as a Number value, which is approximately:\n * 2.2204460492503130808472633361816 x 10‍−‍16.\n */\n readonly EPSILON: number;\n\n /**\n * Returns true if passed value is finite.\n * Unlike the global isFinite, Number.isFinite doesn't forcibly convert the parameter to a\n * number. Only finite values of the type number, result in true.\n * @param number A numeric value.\n */\n isFinite(number: number): boolean;\n\n /**\n * Returns true if the value passed is an integer, false otherwise.\n * @param number A numeric value.\n */\n isInteger(number: number): boolean;\n\n /**\n * Returns a Boolean value that indicates whether a value is the reserved value NaN (not a\n * number). Unlike the global isNaN(), Number.isNaN() doesn't forcefully convert the parameter\n * to a number. Only values of the type number, that are also NaN, result in true.\n * @param number A numeric value.\n */\n isNaN(number: number): boolean;\n\n /**\n * Returns true if the value passed is a safe integer.\n * @param number A numeric value.\n */\n isSafeInteger(number: number): boolean;\n\n /**\n * The value of the largest integer n such that n and n + 1 are both exactly representable as\n * a Number value.\n * The value of Number.MAX_SAFE_INTEGER is 9007199254740991 2^53 − 1.\n */\n readonly MAX_SAFE_INTEGER: number;\n\n /**\n * The value of the smallest integer n such that n and n − 1 are both exactly representable as\n * a Number value.\n * The value of Number.MIN_SAFE_INTEGER is −9007199254740991 (−(2^53 − 1)).\n */\n readonly MIN_SAFE_INTEGER: number;\n\n /**\n * Converts a string to a floating-point number.\n * @param string A string that contains a floating-point number.\n */\n parseFloat(string: string): number;\n\n /**\n * Converts A string to an integer.\n * @param s A string to convert into a number.\n * @param radix A value between 2 and 36 that specifies the base of the number in numString.\n * If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\n * All other strings are considered decimal.\n */\n parseInt(string: string, radix?: number): number;\n}\n\ninterface Object {\n /**\n * Determines whether an object has a property with the specified name.\n * @param v A property name.\n */\n hasOwnProperty(v: PropertyKey): boolean;\n\n /**\n * Determines whether a specified property is enumerable.\n * @param v A property name.\n */\n propertyIsEnumerable(v: PropertyKey): boolean;\n}\n\ninterface ObjectConstructor {\n /**\n * Copy the values of all of the enumerable own properties from one or more source objects to a\n * target object. Returns the target object.\n * @param target The target object to copy to.\n * @param source The source object from which to copy properties.\n */\n assign(target: T, source: U): T & U;\n\n /**\n * Copy the values of all of the enumerable own properties from one or more source objects to a\n * target object. Returns the target object.\n * @param target The target object to copy to.\n * @param source1 The first source object from which to copy properties.\n * @param source2 The second source object from which to copy properties.\n */\n assign(target: T, source1: U, source2: V): T & U & V;\n\n /**\n * Copy the values of all of the enumerable own properties from one or more source objects to a\n * target object. Returns the target object.\n * @param target The target object to copy to.\n * @param source1 The first source object from which to copy properties.\n * @param source2 The second source object from which to copy properties.\n * @param source3 The third source object from which to copy properties.\n */\n assign(target: T, source1: U, source2: V, source3: W): T & U & V & W;\n\n /**\n * Copy the values of all of the enumerable own properties from one or more source objects to a\n * target object. Returns the target object.\n * @param target The target object to copy to.\n * @param sources One or more source objects from which to copy properties\n */\n assign(target: object, ...sources: any[]): any;\n\n /**\n * Returns an array of all symbol properties found directly on object o.\n * @param o Object to retrieve the symbols from.\n */\n getOwnPropertySymbols(o: any): symbol[];\n\n /**\n * Returns true if the values are the same value, false otherwise.\n * @param value1 The first value.\n * @param value2 The second value.\n */\n is(value1: any, value2: any): boolean;\n\n /**\n * Sets the prototype of a specified object o to object proto or null. Returns the object o.\n * @param o The object to change its prototype.\n * @param proto The value of the new prototype or null.\n */\n setPrototypeOf(o: any, proto: object | null): any;\n\n /**\n * Gets the own property descriptor of the specified object.\n * An own property descriptor is one that is defined directly on the object and is not\n * inherited from the object's prototype.\n * @param o Object that contains the property.\n * @param p Name of the property.\n */\n getOwnPropertyDescriptor(o: any, propertyKey: PropertyKey): PropertyDescriptor;\n\n /**\n * Adds a property to an object, or modifies attributes of an existing property.\n * @param o Object on which to add or modify the property. This can be a native JavaScript\n * object (that is, a user-defined object or a built in object) or a DOM object.\n * @param p The property name.\n * @param attributes Descriptor for the property. It can be for a data property or an accessor\n * property.\n */\n defineProperty(o: any, propertyKey: PropertyKey, attributes: PropertyDescriptor): any;\n}\n\ninterface ReadonlyArray {\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: T, index: number, obj: ReadonlyArray) => boolean): T | undefined;\n find(predicate: (this: void, value: T, index: number, obj: ReadonlyArray) => boolean, thisArg: undefined): T | undefined;\n find(predicate: (this: Z, value: T, index: number, obj: ReadonlyArray) => boolean, thisArg: Z): T | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: T, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: T, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: T, index: number, obj: Array) => boolean, thisArg: Z): number;\n}\n\ninterface RegExp {\n /**\n * Returns a string indicating the flags of the regular expression in question. This field is read-only.\n * The characters in this string are sequenced and concatenated in the following order:\n *\n * - \"g\" for global\n * - \"i\" for ignoreCase\n * - \"m\" for multiline\n * - \"u\" for unicode\n * - \"y\" for sticky\n *\n * If no flags are set, the value is the empty string.\n */\n readonly flags: string;\n\n /**\n * Returns a Boolean value indicating the state of the sticky flag (y) used with a regular\n * expression. Default is false. Read-only.\n */\n readonly sticky: boolean;\n\n /**\n * Returns a Boolean value indicating the state of the Unicode flag (u) used with a regular\n * expression. Default is false. Read-only.\n */\n readonly unicode: boolean;\n}\n\ninterface RegExpConstructor {\n new (pattern: RegExp, flags?: string): RegExp;\n (pattern: RegExp, flags?: string): RegExp;\n}\n\ninterface String {\n /**\n * Returns a nonnegative integer Number less than 1114112 (0x110000) that is the code point\n * value of the UTF-16 encoded code point starting at the string element at position pos in\n * the String resulting from converting this object to a String.\n * If there is no element at that position, the result is undefined.\n * If a valid UTF-16 surrogate pair does not begin at pos, the result is the code unit at pos.\n */\n codePointAt(pos: number): number | undefined;\n\n /**\n * Returns true if searchString appears as a substring of the result of converting this\n * object to a String, at one or more positions that are\n * greater than or equal to position; otherwise, returns false.\n * @param searchString search string\n * @param position If position is undefined, 0 is assumed, so as to search all of the String.\n */\n includes(searchString: string, position?: number): boolean;\n\n /**\n * Returns true if the sequence of elements of searchString converted to a String is the\n * same as the corresponding elements of this object (converted to a String) starting at\n * endPosition – length(this). Otherwise returns false.\n */\n endsWith(searchString: string, endPosition?: number): boolean;\n\n /**\n * Returns the String value result of normalizing the string into the normalization form\n * named by form as specified in Unicode Standard Annex #15, Unicode Normalization Forms.\n * @param form Applicable values: \"NFC\", \"NFD\", \"NFKC\", or \"NFKD\", If not specified default\n * is \"NFC\"\n */\n normalize(form: \"NFC\" | \"NFD\" | \"NFKC\" | \"NFKD\"): string;\n\n /**\n * Returns the String value result of normalizing the string into the normalization form\n * named by form as specified in Unicode Standard Annex #15, Unicode Normalization Forms.\n * @param form Applicable values: \"NFC\", \"NFD\", \"NFKC\", or \"NFKD\", If not specified default\n * is \"NFC\"\n */\n normalize(form?: string): string;\n\n /**\n * Returns a String value that is made from count copies appended together. If count is 0,\n * T is the empty String is returned.\n * @param count number of copies to append\n */\n repeat(count: number): string;\n\n /**\n * Returns true if the sequence of elements of searchString converted to a String is the\n * same as the corresponding elements of this object (converted to a String) starting at\n * position. Otherwise returns false.\n */\n startsWith(searchString: string, position?: number): boolean;\n\n /**\n * Returns an HTML anchor element and sets the name attribute to the text value\n * @param name\n */\n anchor(name: string): string;\n\n /** Returns a HTML element */\n big(): string;\n\n /** Returns a HTML element */\n blink(): string;\n\n /** Returns a HTML element */\n bold(): string;\n\n /** Returns a HTML element */\n fixed(): string;\n\n /** Returns a HTML element and sets the color attribute value */\n fontcolor(color: string): string;\n\n /** Returns a HTML element and sets the size attribute value */\n fontsize(size: number): string;\n\n /** Returns a HTML element and sets the size attribute value */\n fontsize(size: string): string;\n\n /** Returns an HTML element */\n italics(): string;\n\n /** Returns an HTML element and sets the href attribute value */\n link(url: string): string;\n\n /** Returns a HTML element */\n small(): string;\n\n /** Returns a HTML element */\n strike(): string;\n\n /** Returns a HTML element */\n sub(): string;\n\n /** Returns a HTML element */\n sup(): string;\n}\n\ninterface StringConstructor {\n /**\n * Return the String value whose elements are, in order, the elements in the List elements.\n * If length is 0, the empty string is returned.\n */\n fromCodePoint(...codePoints: number[]): string;\n\n /**\n * String.raw is intended for use as a tag function of a Tagged Template String. When called\n * as such the first argument will be a well formed template call site object and the rest\n * parameter will contain the substitution values.\n * @param template A well-formed template string call site representation.\n * @param substitutions A set of substitution values.\n */\n raw(template: TemplateStringsArray, ...substitutions: any[]): string;\n}\n\n\ninterface Map {\n clear(): void;\n delete(key: K): boolean;\n forEach(callbackfn: (value: V, key: K, map: Map) => void, thisArg?: any): void;\n get(key: K): V | undefined;\n has(key: K): boolean;\n set(key: K, value: V): this;\n readonly size: number;\n}\n\ninterface MapConstructor {\n new (): Map;\n new (entries?: [K, V][]): Map;\n readonly prototype: Map;\n}\ndeclare var Map: MapConstructor;\n\ninterface ReadonlyMap {\n forEach(callbackfn: (value: V, key: K, map: ReadonlyMap) => void, thisArg?: any): void;\n get(key: K): V | undefined;\n has(key: K): boolean;\n readonly size: number;\n}\n\ninterface WeakMap {\n delete(key: K): boolean;\n get(key: K): V | undefined;\n has(key: K): boolean;\n set(key: K, value: V): this;\n}\n\ninterface WeakMapConstructor {\n new (): WeakMap;\n new (entries?: [K, V][]): WeakMap;\n readonly prototype: WeakMap;\n}\ndeclare var WeakMap: WeakMapConstructor;\n\ninterface Set {\n add(value: T): this;\n clear(): void;\n delete(value: T): boolean;\n forEach(callbackfn: (value: T, value2: T, set: Set) => void, thisArg?: any): void;\n has(value: T): boolean;\n readonly size: number;\n}\n\ninterface SetConstructor {\n new (): Set;\n new (values?: T[]): Set;\n readonly prototype: Set;\n}\ndeclare var Set: SetConstructor;\n\ninterface ReadonlySet {\n forEach(callbackfn: (value: T, value2: T, set: ReadonlySet) => void, thisArg?: any): void;\n has(value: T): boolean;\n readonly size: number;\n}\n\ninterface WeakSet {\n add(value: T): this;\n delete(value: T): boolean;\n has(value: T): boolean;\n}\n\ninterface WeakSetConstructor {\n new (): WeakSet;\n new (values?: T[]): WeakSet;\n readonly prototype: WeakSet;\n}\ndeclare var WeakSet: WeakSetConstructor;\n\n\ninterface Generator extends Iterator { }\n\ninterface GeneratorFunction {\n /**\n * Creates a new Generator object.\n * @param args A list of arguments the function accepts.\n */\n new (...args: any[]): Generator;\n /**\n * Creates a new Generator object.\n * @param args A list of arguments the function accepts.\n */\n (...args: any[]): Generator;\n /**\n * The length of the arguments.\n */\n readonly length: number;\n /**\n * Returns the name of the function.\n */\n readonly name: string;\n /**\n * A reference to the prototype.\n */\n readonly prototype: Generator;\n}\n\ninterface GeneratorFunctionConstructor {\n /**\n * Creates a new Generator function.\n * @param args A list of arguments the function accepts.\n */\n new (...args: string[]): GeneratorFunction;\n /**\n * Creates a new Generator function.\n * @param args A list of arguments the function accepts.\n */\n (...args: string[]): GeneratorFunction;\n /**\n * The length of the arguments.\n */\n readonly length: number;\n /**\n * Returns the name of the function.\n */\n readonly name: string;\n /**\n * A reference to the prototype.\n */\n readonly prototype: GeneratorFunction;\n}\ndeclare var GeneratorFunction: GeneratorFunctionConstructor;\n\n\n/// \n\ninterface SymbolConstructor {\n /**\n * A method that returns the default iterator for an object. Called by the semantics of the\n * for-of statement.\n */\n readonly iterator: symbol;\n}\n\ninterface IteratorResult {\n done: boolean;\n value: T;\n}\n\ninterface Iterator {\n next(value?: any): IteratorResult;\n return?(value?: any): IteratorResult;\n throw?(e?: any): IteratorResult;\n}\n\ninterface Iterable {\n [Symbol.iterator](): Iterator;\n}\n\ninterface IterableIterator extends Iterator {\n [Symbol.iterator](): IterableIterator;\n}\n\ninterface Array {\n /** Iterator */\n [Symbol.iterator](): IterableIterator;\n\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, T]>;\n\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface ArrayConstructor {\n /**\n * Creates an array from an iterable object.\n * @param iterable An iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(iterable: Iterable, mapfn: (this: void, v: T, k: number) => U): Array;\n from(iterable: Iterable, mapfn: (this: void, v: T, k: number) => U, thisArg: undefined): Array;\n from(iterable: Iterable, mapfn: (this: Z, v: T, k: number) => U, thisArg: Z): Array;\n\n /**\n * Creates an array from an iterable object.\n * @param iterable An iterable object to convert to an array.\n */\n from(iterable: Iterable): Array;\n}\n\ninterface ReadonlyArray {\n /** Iterator */\n [Symbol.iterator](): IterableIterator;\n\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, T]>;\n\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface IArguments {\n /** Iterator */\n [Symbol.iterator](): IterableIterator;\n}\n\ninterface Map {\n [Symbol.iterator](): IterableIterator<[K, V]>;\n entries(): IterableIterator<[K, V]>;\n keys(): IterableIterator;\n values(): IterableIterator;\n}\n\ninterface MapConstructor {\n new (iterable: Iterable<[K, V]>): Map;\n}\n\ninterface WeakMap { }\n\ninterface WeakMapConstructor {\n new (iterable: Iterable<[K, V]>): WeakMap;\n}\n\ninterface Set {\n [Symbol.iterator](): IterableIterator;\n entries(): IterableIterator<[T, T]>;\n keys(): IterableIterator;\n values(): IterableIterator;\n}\n\ninterface SetConstructor {\n new (iterable: Iterable): Set;\n}\n\ninterface WeakSet { }\n\ninterface WeakSetConstructor {\n new (iterable: Iterable): WeakSet;\n}\n\ninterface Promise { }\n\ninterface PromiseConstructor {\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: Iterable>): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: Iterable>): Promise;\n}\n\ndeclare namespace Reflect {\n function enumerate(target: object): IterableIterator;\n}\n\ninterface String {\n /** Iterator */\n [Symbol.iterator](): IterableIterator;\n}\n\n/**\n * A typed array of 8-bit integer values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Int8Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Int8ArrayConstructor {\n new (elements: Iterable): Int8Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Int8Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Int8Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Int8Array;\n\n from(arrayLike: Iterable): Int8Array;\n}\n\n/**\n * A typed array of 8-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Uint8ArrayConstructor {\n new (elements: Iterable): Uint8Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Uint8Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint8Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint8Array;\n\n from(arrayLike: Iterable): Uint8Array;\n}\n\n/**\n * A typed array of 8-bit unsigned integer (clamped) values. The contents are initialized to 0.\n * If the requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8ClampedArray {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Uint8ClampedArrayConstructor {\n new (elements: Iterable): Uint8ClampedArray;\n\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Uint8ClampedArray;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint8ClampedArray;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint8ClampedArray;\n\n from(arrayLike: Iterable): Uint8ClampedArray;\n}\n\n/**\n * A typed array of 16-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int16Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Int16ArrayConstructor {\n new (elements: Iterable): Int16Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Int16Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Int16Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Int16Array;\n\n from(arrayLike: Iterable): Int16Array;\n}\n\n/**\n * A typed array of 16-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint16Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Uint16ArrayConstructor {\n new (elements: Iterable): Uint16Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Uint16Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint16Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint16Array;\n\n from(arrayLike: Iterable): Uint16Array;\n}\n\n/**\n * A typed array of 32-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int32Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Int32ArrayConstructor {\n new (elements: Iterable): Int32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Int32Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Int32Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Int32Array;\n\n from(arrayLike: Iterable): Int32Array;\n}\n\n/**\n * A typed array of 32-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint32Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Uint32ArrayConstructor {\n new (elements: Iterable): Uint32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Uint32Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint32Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint32Array;\n\n from(arrayLike: Iterable): Uint32Array;\n}\n\n/**\n * A typed array of 32-bit float values. The contents are initialized to 0. If the requested number\n * of bytes could not be allocated an exception is raised.\n */\ninterface Float32Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Float32ArrayConstructor {\n new (elements: Iterable): Float32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Float32Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Float32Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Float32Array;\n\n from(arrayLike: Iterable): Float32Array;\n}\n\n/**\n * A typed array of 64-bit float values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Float64Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Float64ArrayConstructor {\n new (elements: Iterable): Float64Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Float64Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Float64Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Float64Array;\n\n from(arrayLike: Iterable): Float64Array;\n}\n\n\ninterface PromiseConstructor {\n /**\n * A reference to the prototype.\n */\n readonly prototype: Promise;\n\n /**\n * Creates a new Promise.\n * @param executor A callback used to initialize the promise. This callback is passed two arguments:\n * a resolve callback used resolve the promise with a value or the result of another promise,\n * and a reject callback used to reject the promise with a provided reason or error.\n */\n new (executor: (resolve: (value?: T | PromiseLike) => void, reject: (reason?: any) => void) => void): Promise;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike, T9 | PromiseLike, T10 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6, T7, T8, T9, T10]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike, T9 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6, T7, T8, T9]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6, T7, T8]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6, T7]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike]): Promise<[T1, T2, T3, T4, T5]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike ]): Promise<[T1, T2, T3, T4]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike]): Promise<[T1, T2, T3]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike]): Promise<[T1, T2]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: (T | PromiseLike)[]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike, T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike, T9 | PromiseLike, T10 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike, T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike, T9 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike, T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike, T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike, T5 | PromiseLike, T6 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike, T5 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: (T | PromiseLike)[]): Promise;\n\n /**\n * Creates a new rejected promise for the provided reason.\n * @param reason The reason the promise was rejected.\n * @returns A new rejected Promise.\n */\n reject(reason: any): Promise;\n\n /**\n * Creates a new rejected promise for the provided reason.\n * @param reason The reason the promise was rejected.\n * @returns A new rejected Promise.\n */\n reject(reason: any): Promise;\n\n /**\n * Creates a new resolved promise for the provided value.\n * @param value A promise.\n * @returns A promise whose internal state matches the provided promise.\n */\n resolve(value: T | PromiseLike): Promise;\n\n /**\n * Creates a new resolved promise .\n * @returns A resolved promise.\n */\n resolve(): Promise;\n}\n\ndeclare var Promise: PromiseConstructor;\n\ninterface ProxyHandler {\n getPrototypeOf? (target: T): object | null;\n setPrototypeOf? (target: T, v: any): boolean;\n isExtensible? (target: T): boolean;\n preventExtensions? (target: T): boolean;\n getOwnPropertyDescriptor? (target: T, p: PropertyKey): PropertyDescriptor;\n has? (target: T, p: PropertyKey): boolean;\n get? (target: T, p: PropertyKey, receiver: any): any;\n set? (target: T, p: PropertyKey, value: any, receiver: any): boolean;\n deleteProperty? (target: T, p: PropertyKey): boolean;\n defineProperty? (target: T, p: PropertyKey, attributes: PropertyDescriptor): boolean;\n enumerate? (target: T): PropertyKey[];\n ownKeys? (target: T): PropertyKey[];\n apply? (target: T, thisArg: any, argArray?: any): any;\n construct? (target: T, argArray: any, newTarget?: any): object;\n}\n\ninterface ProxyConstructor {\n revocable(target: T, handler: ProxyHandler): { proxy: T; revoke: () => void; };\n new (target: T, handler: ProxyHandler): T;\n}\ndeclare var Proxy: ProxyConstructor;\n\n\ndeclare namespace Reflect {\n function apply(target: Function, thisArgument: any, argumentsList: ArrayLike): any;\n function construct(target: Function, argumentsList: ArrayLike, newTarget?: any): any;\n function defineProperty(target: object, propertyKey: PropertyKey, attributes: PropertyDescriptor): boolean;\n function deleteProperty(target: object, propertyKey: PropertyKey): boolean;\n function get(target: object, propertyKey: PropertyKey, receiver?: any): any;\n function getOwnPropertyDescriptor(target: object, propertyKey: PropertyKey): PropertyDescriptor;\n function getPrototypeOf(target: object): object;\n function has(target: object, propertyKey: PropertyKey): boolean;\n function isExtensible(target: object): boolean;\n function ownKeys(target: object): Array;\n function preventExtensions(target: object): boolean;\n function set(target: object, propertyKey: PropertyKey, value: any, receiver?: any): boolean;\n function setPrototypeOf(target: object, proto: any): boolean;\n}\n\n\ninterface Symbol {\n /** Returns a string representation of an object. */\n toString(): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): symbol;\n}\n\ninterface SymbolConstructor {\n /**\n * A reference to the prototype.\n */\n readonly prototype: Symbol;\n\n /**\n * Returns a new unique Symbol value.\n * @param description Description of the new Symbol object.\n */\n (description?: string | number): symbol;\n\n /**\n * Returns a Symbol object from the global symbol registry matching the given key if found.\n * Otherwise, returns a new symbol with this key.\n * @param key key to search for.\n */\n for(key: string): symbol;\n\n /**\n * Returns a key from the global symbol registry matching the given Symbol if found.\n * Otherwise, returns a undefined.\n * @param sym Symbol to find the key for.\n */\n keyFor(sym: symbol): string | undefined;\n}\n\ndeclare var Symbol: SymbolConstructor;\n\n/// \n\ninterface SymbolConstructor {\n /**\n * A method that determines if a constructor object recognizes an object as one of the\n * constructor’s instances. Called by the semantics of the instanceof operator.\n */\n readonly hasInstance: symbol;\n\n /**\n * A Boolean value that if true indicates that an object should flatten to its array elements\n * by Array.prototype.concat.\n */\n readonly isConcatSpreadable: symbol;\n\n /**\n * A regular expression method that matches the regular expression against a string. Called\n * by the String.prototype.match method.\n */\n readonly match: symbol;\n\n /**\n * A regular expression method that replaces matched substrings of a string. Called by the\n * String.prototype.replace method.\n */\n readonly replace: symbol;\n\n /**\n * A regular expression method that returns the index within a string that matches the\n * regular expression. Called by the String.prototype.search method.\n */\n readonly search: symbol;\n\n /**\n * A function valued property that is the constructor function that is used to create\n * derived objects.\n */\n readonly species: symbol;\n\n /**\n * A regular expression method that splits a string at the indices that match the regular\n * expression. Called by the String.prototype.split method.\n */\n readonly split: symbol;\n\n /**\n * A method that converts an object to a corresponding primitive value.\n * Called by the ToPrimitive abstract operation.\n */\n readonly toPrimitive: symbol;\n\n /**\n * A String value that is used in the creation of the default string description of an object.\n * Called by the built-in method Object.prototype.toString.\n */\n readonly toStringTag: symbol;\n\n /**\n * An Object whose own property names are property names that are excluded from the 'with'\n * environment bindings of the associated objects.\n */\n readonly unscopables: symbol;\n}\n\ninterface Symbol {\n readonly [Symbol.toStringTag]: \"Symbol\";\n}\n\ninterface Array {\n /**\n * Returns an object whose properties have the value 'true'\n * when they will be absent when used in a 'with' statement.\n */\n [Symbol.unscopables](): {\n copyWithin: boolean;\n entries: boolean;\n fill: boolean;\n find: boolean;\n findIndex: boolean;\n keys: boolean;\n values: boolean;\n };\n}\n\ninterface Date {\n /**\n * Converts a Date object to a string.\n */\n [Symbol.toPrimitive](hint: \"default\"): string;\n /**\n * Converts a Date object to a string.\n */\n [Symbol.toPrimitive](hint: \"string\"): string;\n /**\n * Converts a Date object to a number.\n */\n [Symbol.toPrimitive](hint: \"number\"): number;\n /**\n * Converts a Date object to a string or number.\n *\n * @param hint The strings \"number\", \"string\", or \"default\" to specify what primitive to return.\n *\n * @throws {TypeError} If 'hint' was given something other than \"number\", \"string\", or \"default\".\n * @returns A number if 'hint' was \"number\", a string if 'hint' was \"string\" or \"default\".\n */\n [Symbol.toPrimitive](hint: string): string | number;\n}\n\ninterface Map {\n readonly [Symbol.toStringTag]: \"Map\";\n}\n\ninterface WeakMap{\n readonly [Symbol.toStringTag]: \"WeakMap\";\n}\n\ninterface Set {\n readonly [Symbol.toStringTag]: \"Set\";\n}\n\ninterface WeakSet {\n readonly [Symbol.toStringTag]: \"WeakSet\";\n}\n\ninterface JSON {\n readonly [Symbol.toStringTag]: \"JSON\";\n}\n\ninterface Function {\n /**\n * Determines whether the given value inherits from this function if this function was used\n * as a constructor function.\n *\n * A constructor function can control which objects are recognized as its instances by\n * 'instanceof' by overriding this method.\n */\n [Symbol.hasInstance](value: any): boolean;\n}\n\ninterface GeneratorFunction {\n readonly [Symbol.toStringTag]: \"GeneratorFunction\";\n}\n\ninterface Math {\n readonly [Symbol.toStringTag]: \"Math\";\n}\n\ninterface Promise {\n readonly [Symbol.toStringTag]: \"Promise\";\n}\n\ninterface PromiseConstructor {\n readonly [Symbol.species]: Function;\n}\n\ninterface RegExp {\n /**\n * Matches a string with this regular expression, and returns an array containing the results of\n * that search.\n * @param string A string to search within.\n */\n [Symbol.match](string: string): RegExpMatchArray | null;\n\n /**\n * Replaces text in a string, using this regular expression.\n * @param string A String object or string literal whose contents matching against\n * this regular expression will be replaced\n * @param replaceValue A String object or string literal containing the text to replace for every\n * successful match of this regular expression.\n */\n [Symbol.replace](string: string, replaceValue: string): string;\n\n /**\n * Replaces text in a string, using this regular expression.\n * @param string A String object or string literal whose contents matching against\n * this regular expression will be replaced\n * @param replacer A function that returns the replacement text.\n */\n [Symbol.replace](string: string, replacer: (substring: string, ...args: any[]) => string): string;\n\n /**\n * Finds the position beginning first substring match in a regular expression search\n * using this regular expression.\n *\n * @param string The string to search within.\n */\n [Symbol.search](string: string): number;\n\n /**\n * Returns an array of substrings that were delimited by strings in the original input that\n * match against this regular expression.\n *\n * If the regular expression contains capturing parentheses, then each time this\n * regular expression matches, the results (including any undefined results) of the\n * capturing parentheses are spliced.\n *\n * @param string string value to split\n * @param limit if not undefined, the output array is truncated so that it contains no more\n * than 'limit' elements.\n */\n [Symbol.split](string: string, limit?: number): string[];\n}\n\ninterface RegExpConstructor {\n [Symbol.species](): RegExpConstructor;\n}\n\ninterface String {\n /**\n * Matches a string an object that supports being matched against, and returns an array containing the results of that search.\n * @param matcher An object that supports being matched against.\n */\n match(matcher: { [Symbol.match](string: string): RegExpMatchArray | null; }): RegExpMatchArray | null;\n\n /**\n * Replaces text in a string, using an object that supports replacement within a string.\n * @param searchValue A object can search for and replace matches within a string.\n * @param replaceValue A string containing the text to replace for every successful match of searchValue in this string.\n */\n replace(searchValue: { [Symbol.replace](string: string, replaceValue: string): string; }, replaceValue: string): string;\n\n /**\n * Replaces text in a string, using an object that supports replacement within a string.\n * @param searchValue A object can search for and replace matches within a string.\n * @param replacer A function that returns the replacement text.\n */\n replace(searchValue: { [Symbol.replace](string: string, replacer: (substring: string, ...args: any[]) => string): string; }, replacer: (substring: string, ...args: any[]) => string): string;\n\n /**\n * Finds the first substring match in a regular expression search.\n * @param searcher An object which supports searching within a string.\n */\n search(searcher: { [Symbol.search](string: string): number; }): number;\n\n /**\n * Split a string into substrings using the specified separator and return them as an array.\n * @param splitter An object that can split a string.\n * @param limit A value used to limit the number of elements returned in the array.\n */\n split(splitter: { [Symbol.split](string: string, limit?: number): string[]; }, limit?: number): string[];\n}\n\n/**\n * Represents a raw buffer of binary data, which is used to store data for the\n * different typed arrays. ArrayBuffers cannot be read from or written to directly,\n * but can be passed to a typed array or DataView Object to interpret the raw\n * buffer as needed.\n */\ninterface ArrayBuffer {\n readonly [Symbol.toStringTag]: \"ArrayBuffer\";\n}\n\ninterface DataView {\n readonly [Symbol.toStringTag]: \"DataView\";\n}\n\n/**\n * A typed array of 8-bit integer values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Int8Array {\n readonly [Symbol.toStringTag]: \"Int8Array\";\n}\n\n/**\n * A typed array of 8-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8Array {\n readonly [Symbol.toStringTag]: \"UInt8Array\";\n}\n\n/**\n * A typed array of 8-bit unsigned integer (clamped) values. The contents are initialized to 0.\n * If the requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8ClampedArray {\n readonly [Symbol.toStringTag]: \"Uint8ClampedArray\";\n}\n\n/**\n * A typed array of 16-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int16Array {\n readonly [Symbol.toStringTag]: \"Int16Array\";\n}\n\n/**\n * A typed array of 16-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint16Array {\n readonly [Symbol.toStringTag]: \"Uint16Array\";\n}\n\n/**\n * A typed array of 32-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int32Array {\n readonly [Symbol.toStringTag]: \"Int32Array\";\n}\n\n/**\n * A typed array of 32-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint32Array {\n readonly [Symbol.toStringTag]: \"Uint32Array\";\n}\n\n/**\n * A typed array of 32-bit float values. The contents are initialized to 0. If the requested number\n * of bytes could not be allocated an exception is raised.\n */\ninterface Float32Array {\n readonly [Symbol.toStringTag]: \"Float32Array\";\n}\n\n/**\n * A typed array of 64-bit float values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Float64Array {\n readonly [Symbol.toStringTag]: \"Float64Array\";\n}\n\n\n\n/////////////////////////////\n/// IE DOM APIs\n/////////////////////////////\n\ninterface Account {\n rpDisplayName?: string;\n displayName?: string;\n id?: string;\n name?: string;\n imageURL?: string;\n}\n\ninterface Algorithm {\n name: string;\n}\n\ninterface AnimationEventInit extends EventInit {\n animationName?: string;\n elapsedTime?: number;\n}\n\ninterface AssertionOptions {\n timeoutSeconds?: number;\n rpId?: USVString;\n allowList?: ScopedCredentialDescriptor[];\n extensions?: WebAuthnExtensions;\n}\n\ninterface CacheQueryOptions {\n ignoreSearch?: boolean;\n ignoreMethod?: boolean;\n ignoreVary?: boolean;\n cacheName?: string;\n}\n\ninterface ClientData {\n challenge?: string;\n origin?: string;\n rpId?: string;\n hashAlg?: string | Algorithm;\n tokenBinding?: string;\n extensions?: WebAuthnExtensions;\n}\n\ninterface CloseEventInit extends EventInit {\n wasClean?: boolean;\n code?: number;\n reason?: string;\n}\n\ninterface CompositionEventInit extends UIEventInit {\n data?: string;\n}\n\ninterface ConfirmSiteSpecificExceptionsInformation extends ExceptionInformation {\n arrayOfDomainStrings?: string[];\n}\n\ninterface ConstrainBooleanParameters {\n exact?: boolean;\n ideal?: boolean;\n}\n\ninterface ConstrainDOMStringParameters {\n exact?: string | string[];\n ideal?: string | string[];\n}\n\ninterface ConstrainDoubleRange extends DoubleRange {\n exact?: number;\n ideal?: number;\n}\n\ninterface ConstrainLongRange extends LongRange {\n exact?: number;\n ideal?: number;\n}\n\ninterface ConstrainVideoFacingModeParameters {\n exact?: VideoFacingModeEnum | VideoFacingModeEnum[];\n ideal?: VideoFacingModeEnum | VideoFacingModeEnum[];\n}\n\ninterface CustomEventInit extends EventInit {\n detail?: any;\n}\n\ninterface DOMRectInit {\n x?: any;\n y?: any;\n width?: any;\n height?: any;\n}\n\ninterface DeviceAccelerationDict {\n x?: number;\n y?: number;\n z?: number;\n}\n\ninterface DeviceLightEventInit extends EventInit {\n value?: number;\n}\n\ninterface DeviceMotionEventInit extends EventInit {\n acceleration?: DeviceAccelerationDict;\n accelerationIncludingGravity?: DeviceAccelerationDict;\n rotationRate?: DeviceRotationRateDict;\n interval?: number;\n}\n\ninterface DeviceOrientationEventInit extends EventInit {\n alpha?: number;\n beta?: number;\n gamma?: number;\n absolute?: boolean;\n}\n\ninterface DeviceRotationRateDict {\n alpha?: number;\n beta?: number;\n gamma?: number;\n}\n\ninterface DoubleRange {\n max?: number;\n min?: number;\n}\n\ninterface ErrorEventInit extends EventInit {\n message?: string;\n filename?: string;\n lineno?: number;\n colno?: number;\n error?: any;\n}\n\ninterface EventInit {\n scoped?: boolean;\n bubbles?: boolean;\n cancelable?: boolean;\n}\n\ninterface EventModifierInit extends UIEventInit {\n ctrlKey?: boolean;\n shiftKey?: boolean;\n altKey?: boolean;\n metaKey?: boolean;\n modifierAltGraph?: boolean;\n modifierCapsLock?: boolean;\n modifierFn?: boolean;\n modifierFnLock?: boolean;\n modifierHyper?: boolean;\n modifierNumLock?: boolean;\n modifierOS?: boolean;\n modifierScrollLock?: boolean;\n modifierSuper?: boolean;\n modifierSymbol?: boolean;\n modifierSymbolLock?: boolean;\n}\n\ninterface ExceptionInformation {\n domain?: string;\n}\n\ninterface FocusEventInit extends UIEventInit {\n relatedTarget?: EventTarget;\n}\n\ninterface FocusNavigationEventInit extends EventInit {\n navigationReason?: string;\n originLeft?: number;\n originTop?: number;\n originWidth?: number;\n originHeight?: number;\n}\n\ninterface FocusNavigationOrigin {\n originLeft?: number;\n originTop?: number;\n originWidth?: number;\n originHeight?: number;\n}\n\ninterface GamepadEventInit extends EventInit {\n gamepad?: Gamepad;\n}\n\ninterface GetNotificationOptions {\n tag?: string;\n}\n\ninterface HashChangeEventInit extends EventInit {\n newURL?: string;\n oldURL?: string;\n}\n\ninterface IDBIndexParameters {\n multiEntry?: boolean;\n unique?: boolean;\n}\n\ninterface IDBObjectStoreParameters {\n autoIncrement?: boolean;\n keyPath?: IDBKeyPath;\n}\n\ninterface IntersectionObserverEntryInit {\n time?: number;\n rootBounds?: DOMRectInit;\n boundingClientRect?: DOMRectInit;\n intersectionRect?: DOMRectInit;\n target?: Element;\n}\n\ninterface IntersectionObserverInit {\n root?: Element;\n rootMargin?: string;\n threshold?: number | number[];\n}\n\ninterface KeyAlgorithm {\n name?: string;\n}\n\ninterface KeyboardEventInit extends EventModifierInit {\n code?: string;\n key?: string;\n location?: number;\n repeat?: boolean;\n}\n\ninterface LongRange {\n max?: number;\n min?: number;\n}\n\ninterface MSAccountInfo {\n rpDisplayName?: string;\n userDisplayName?: string;\n accountName?: string;\n userId?: string;\n accountImageUri?: string;\n}\n\ninterface MSAudioLocalClientEvent extends MSLocalClientEventBase {\n networkSendQualityEventRatio?: number;\n networkDelayEventRatio?: number;\n cpuInsufficientEventRatio?: number;\n deviceHalfDuplexAECEventRatio?: number;\n deviceRenderNotFunctioningEventRatio?: number;\n deviceCaptureNotFunctioningEventRatio?: number;\n deviceGlitchesEventRatio?: number;\n deviceLowSNREventRatio?: number;\n deviceLowSpeechLevelEventRatio?: number;\n deviceClippingEventRatio?: number;\n deviceEchoEventRatio?: number;\n deviceNearEndToEchoRatioEventRatio?: number;\n deviceRenderZeroVolumeEventRatio?: number;\n deviceRenderMuteEventRatio?: number;\n deviceMultipleEndpointsEventCount?: number;\n deviceHowlingEventCount?: number;\n}\n\ninterface MSAudioRecvPayload extends MSPayloadBase {\n samplingRate?: number;\n signal?: MSAudioRecvSignal;\n packetReorderRatio?: number;\n packetReorderDepthAvg?: number;\n packetReorderDepthMax?: number;\n burstLossLength1?: number;\n burstLossLength2?: number;\n burstLossLength3?: number;\n burstLossLength4?: number;\n burstLossLength5?: number;\n burstLossLength6?: number;\n burstLossLength7?: number;\n burstLossLength8OrHigher?: number;\n fecRecvDistance1?: number;\n fecRecvDistance2?: number;\n fecRecvDistance3?: number;\n ratioConcealedSamplesAvg?: number;\n ratioStretchedSamplesAvg?: number;\n ratioCompressedSamplesAvg?: number;\n}\n\ninterface MSAudioRecvSignal {\n initialSignalLevelRMS?: number;\n recvSignalLevelCh1?: number;\n recvNoiseLevelCh1?: number;\n renderSignalLevel?: number;\n renderNoiseLevel?: number;\n renderLoopbackSignalLevel?: number;\n}\n\ninterface MSAudioSendPayload extends MSPayloadBase {\n samplingRate?: number;\n signal?: MSAudioSendSignal;\n audioFECUsed?: boolean;\n sendMutePercent?: number;\n}\n\ninterface MSAudioSendSignal {\n noiseLevel?: number;\n sendSignalLevelCh1?: number;\n sendNoiseLevelCh1?: number;\n}\n\ninterface MSConnectivity {\n iceType?: MSIceType;\n iceWarningFlags?: MSIceWarningFlags;\n relayAddress?: MSRelayAddress;\n}\n\ninterface MSCredentialFilter {\n accept?: MSCredentialSpec[];\n}\n\ninterface MSCredentialParameters {\n type?: MSCredentialType;\n}\n\ninterface MSCredentialSpec {\n type?: MSCredentialType;\n id?: string;\n}\n\ninterface MSDelay {\n roundTrip?: number;\n roundTripMax?: number;\n}\n\ninterface MSDescription extends RTCStats {\n connectivity?: MSConnectivity;\n transport?: RTCIceProtocol;\n networkconnectivity?: MSNetworkConnectivityInfo;\n localAddr?: MSIPAddressInfo;\n remoteAddr?: MSIPAddressInfo;\n deviceDevName?: string;\n reflexiveLocalIPAddr?: MSIPAddressInfo;\n}\n\ninterface MSFIDOCredentialParameters extends MSCredentialParameters {\n algorithm?: string | Algorithm;\n authenticators?: AAGUID[];\n}\n\ninterface MSIPAddressInfo {\n ipAddr?: string;\n port?: number;\n manufacturerMacAddrMask?: string;\n}\n\ninterface MSIceWarningFlags {\n turnTcpTimedOut?: boolean;\n turnUdpAllocateFailed?: boolean;\n turnUdpSendFailed?: boolean;\n turnTcpAllocateFailed?: boolean;\n turnTcpSendFailed?: boolean;\n udpLocalConnectivityFailed?: boolean;\n udpNatConnectivityFailed?: boolean;\n udpRelayConnectivityFailed?: boolean;\n tcpNatConnectivityFailed?: boolean;\n tcpRelayConnectivityFailed?: boolean;\n connCheckMessageIntegrityFailed?: boolean;\n allocationMessageIntegrityFailed?: boolean;\n connCheckOtherError?: boolean;\n turnAuthUnknownUsernameError?: boolean;\n noRelayServersConfigured?: boolean;\n multipleRelayServersAttempted?: boolean;\n portRangeExhausted?: boolean;\n alternateServerReceived?: boolean;\n pseudoTLSFailure?: boolean;\n turnTurnTcpConnectivityFailed?: boolean;\n useCandidateChecksFailed?: boolean;\n fipsAllocationFailure?: boolean;\n}\n\ninterface MSJitter {\n interArrival?: number;\n interArrivalMax?: number;\n interArrivalSD?: number;\n}\n\ninterface MSLocalClientEventBase extends RTCStats {\n networkReceiveQualityEventRatio?: number;\n networkBandwidthLowEventRatio?: number;\n}\n\ninterface MSNetwork extends RTCStats {\n jitter?: MSJitter;\n delay?: MSDelay;\n packetLoss?: MSPacketLoss;\n utilization?: MSUtilization;\n}\n\ninterface MSNetworkConnectivityInfo {\n vpn?: boolean;\n linkspeed?: number;\n networkConnectionDetails?: string;\n}\n\ninterface MSNetworkInterfaceType {\n interfaceTypeEthernet?: boolean;\n interfaceTypeWireless?: boolean;\n interfaceTypePPP?: boolean;\n interfaceTypeTunnel?: boolean;\n interfaceTypeWWAN?: boolean;\n}\n\ninterface MSOutboundNetwork extends MSNetwork {\n appliedBandwidthLimit?: number;\n}\n\ninterface MSPacketLoss {\n lossRate?: number;\n lossRateMax?: number;\n}\n\ninterface MSPayloadBase extends RTCStats {\n payloadDescription?: string;\n}\n\ninterface MSPortRange {\n min?: number;\n max?: number;\n}\n\ninterface MSRelayAddress {\n relayAddress?: string;\n port?: number;\n}\n\ninterface MSSignatureParameters {\n userPrompt?: string;\n}\n\ninterface MSTransportDiagnosticsStats extends RTCStats {\n baseAddress?: string;\n localAddress?: string;\n localSite?: string;\n networkName?: string;\n remoteAddress?: string;\n remoteSite?: string;\n localMR?: string;\n remoteMR?: string;\n iceWarningFlags?: MSIceWarningFlags;\n portRangeMin?: number;\n portRangeMax?: number;\n localMRTCPPort?: number;\n remoteMRTCPPort?: number;\n stunVer?: number;\n numConsentReqSent?: number;\n numConsentReqReceived?: number;\n numConsentRespSent?: number;\n numConsentRespReceived?: number;\n interfaces?: MSNetworkInterfaceType;\n baseInterface?: MSNetworkInterfaceType;\n protocol?: RTCIceProtocol;\n localInterface?: MSNetworkInterfaceType;\n localAddrType?: MSIceAddrType;\n remoteAddrType?: MSIceAddrType;\n iceRole?: RTCIceRole;\n rtpRtcpMux?: boolean;\n allocationTimeInMs?: number;\n msRtcEngineVersion?: string;\n}\n\ninterface MSUtilization {\n packets?: number;\n bandwidthEstimation?: number;\n bandwidthEstimationMin?: number;\n bandwidthEstimationMax?: number;\n bandwidthEstimationStdDev?: number;\n bandwidthEstimationAvg?: number;\n}\n\ninterface MSVideoPayload extends MSPayloadBase {\n resolution?: string;\n videoBitRateAvg?: number;\n videoBitRateMax?: number;\n videoFrameRateAvg?: number;\n videoPacketLossRate?: number;\n durationSeconds?: number;\n}\n\ninterface MSVideoRecvPayload extends MSVideoPayload {\n videoFrameLossRate?: number;\n recvCodecType?: string;\n recvResolutionWidth?: number;\n recvResolutionHeight?: number;\n videoResolutions?: MSVideoResolutionDistribution;\n recvFrameRateAverage?: number;\n recvBitRateMaximum?: number;\n recvBitRateAverage?: number;\n recvVideoStreamsMax?: number;\n recvVideoStreamsMin?: number;\n recvVideoStreamsMode?: number;\n videoPostFECPLR?: number;\n lowBitRateCallPercent?: number;\n lowFrameRateCallPercent?: number;\n reorderBufferTotalPackets?: number;\n recvReorderBufferReorderedPackets?: number;\n recvReorderBufferPacketsDroppedDueToBufferExhaustion?: number;\n recvReorderBufferMaxSuccessfullyOrderedExtent?: number;\n recvReorderBufferMaxSuccessfullyOrderedLateTime?: number;\n recvReorderBufferPacketsDroppedDueToTimeout?: number;\n recvFpsHarmonicAverage?: number;\n recvNumResSwitches?: number;\n}\n\ninterface MSVideoResolutionDistribution {\n cifQuality?: number;\n vgaQuality?: number;\n h720Quality?: number;\n h1080Quality?: number;\n h1440Quality?: number;\n h2160Quality?: number;\n}\n\ninterface MSVideoSendPayload extends MSVideoPayload {\n sendFrameRateAverage?: number;\n sendBitRateMaximum?: number;\n sendBitRateAverage?: number;\n sendVideoStreamsMax?: number;\n sendResolutionWidth?: number;\n sendResolutionHeight?: number;\n}\n\ninterface MediaEncryptedEventInit extends EventInit {\n initDataType?: string;\n initData?: ArrayBuffer;\n}\n\ninterface MediaKeyMessageEventInit extends EventInit {\n messageType?: MediaKeyMessageType;\n message?: ArrayBuffer;\n}\n\ninterface MediaKeySystemConfiguration {\n initDataTypes?: string[];\n audioCapabilities?: MediaKeySystemMediaCapability[];\n videoCapabilities?: MediaKeySystemMediaCapability[];\n distinctiveIdentifier?: MediaKeysRequirement;\n persistentState?: MediaKeysRequirement;\n}\n\ninterface MediaKeySystemMediaCapability {\n contentType?: string;\n robustness?: string;\n}\n\ninterface MediaStreamConstraints {\n video?: boolean | MediaTrackConstraints;\n audio?: boolean | MediaTrackConstraints;\n}\n\ninterface MediaStreamErrorEventInit extends EventInit {\n error?: MediaStreamError;\n}\n\ninterface MediaStreamEventInit extends EventInit {\n stream?: MediaStream;\n}\n\ninterface MediaStreamTrackEventInit extends EventInit {\n track?: MediaStreamTrack;\n}\n\ninterface MediaTrackCapabilities {\n width?: number | LongRange;\n height?: number | LongRange;\n aspectRatio?: number | DoubleRange;\n frameRate?: number | DoubleRange;\n facingMode?: string;\n volume?: number | DoubleRange;\n sampleRate?: number | LongRange;\n sampleSize?: number | LongRange;\n echoCancellation?: boolean[];\n deviceId?: string;\n groupId?: string;\n}\n\ninterface MediaTrackConstraintSet {\n width?: number | ConstrainLongRange;\n height?: number | ConstrainLongRange;\n aspectRatio?: number | ConstrainDoubleRange;\n frameRate?: number | ConstrainDoubleRange;\n facingMode?: string | string[] | ConstrainDOMStringParameters;\n volume?: number | ConstrainDoubleRange;\n sampleRate?: number | ConstrainLongRange;\n sampleSize?: number | ConstrainLongRange;\n echoCancelation?: boolean | ConstrainBooleanParameters;\n deviceId?: string | string[] | ConstrainDOMStringParameters;\n groupId?: string | string[] | ConstrainDOMStringParameters;\n}\n\ninterface MediaTrackConstraints extends MediaTrackConstraintSet {\n advanced?: MediaTrackConstraintSet[];\n}\n\ninterface MediaTrackSettings {\n width?: number;\n height?: number;\n aspectRatio?: number;\n frameRate?: number;\n facingMode?: string;\n volume?: number;\n sampleRate?: number;\n sampleSize?: number;\n echoCancellation?: boolean;\n deviceId?: string;\n groupId?: string;\n}\n\ninterface MediaTrackSupportedConstraints {\n width?: boolean;\n height?: boolean;\n aspectRatio?: boolean;\n frameRate?: boolean;\n facingMode?: boolean;\n volume?: boolean;\n sampleRate?: boolean;\n sampleSize?: boolean;\n echoCancellation?: boolean;\n deviceId?: boolean;\n groupId?: boolean;\n}\n\ninterface MessageEventInit extends EventInit {\n lastEventId?: string;\n channel?: string;\n data?: any;\n origin?: string;\n source?: Window;\n ports?: MessagePort[];\n}\n\ninterface MouseEventInit extends EventModifierInit {\n screenX?: number;\n screenY?: number;\n clientX?: number;\n clientY?: number;\n button?: number;\n buttons?: number;\n relatedTarget?: EventTarget;\n}\n\ninterface MsZoomToOptions {\n contentX?: number;\n contentY?: number;\n viewportX?: string;\n viewportY?: string;\n scaleFactor?: number;\n animate?: string;\n}\n\ninterface MutationObserverInit {\n childList?: boolean;\n attributes?: boolean;\n characterData?: boolean;\n subtree?: boolean;\n attributeOldValue?: boolean;\n characterDataOldValue?: boolean;\n attributeFilter?: string[];\n}\n\ninterface NotificationOptions {\n dir?: NotificationDirection;\n lang?: string;\n body?: string;\n tag?: string;\n icon?: string;\n}\n\ninterface ObjectURLOptions {\n oneTimeOnly?: boolean;\n}\n\ninterface PaymentCurrencyAmount {\n currency?: string;\n value?: string;\n currencySystem?: string;\n}\n\ninterface PaymentDetails {\n total?: PaymentItem;\n displayItems?: PaymentItem[];\n shippingOptions?: PaymentShippingOption[];\n modifiers?: PaymentDetailsModifier[];\n error?: string;\n}\n\ninterface PaymentDetailsModifier {\n supportedMethods?: string[];\n total?: PaymentItem;\n additionalDisplayItems?: PaymentItem[];\n data?: any;\n}\n\ninterface PaymentItem {\n label?: string;\n amount?: PaymentCurrencyAmount;\n pending?: boolean;\n}\n\ninterface PaymentMethodData {\n supportedMethods?: string[];\n data?: any;\n}\n\ninterface PaymentOptions {\n requestPayerName?: boolean;\n requestPayerEmail?: boolean;\n requestPayerPhone?: boolean;\n requestShipping?: boolean;\n shippingType?: string;\n}\n\ninterface PaymentRequestUpdateEventInit extends EventInit {\n}\n\ninterface PaymentShippingOption {\n id?: string;\n label?: string;\n amount?: PaymentCurrencyAmount;\n selected?: boolean;\n}\n\ninterface PeriodicWaveConstraints {\n disableNormalization?: boolean;\n}\n\ninterface PointerEventInit extends MouseEventInit {\n pointerId?: number;\n width?: number;\n height?: number;\n pressure?: number;\n tiltX?: number;\n tiltY?: number;\n pointerType?: string;\n isPrimary?: boolean;\n}\n\ninterface PopStateEventInit extends EventInit {\n state?: any;\n}\n\ninterface PositionOptions {\n enableHighAccuracy?: boolean;\n timeout?: number;\n maximumAge?: number;\n}\n\ninterface ProgressEventInit extends EventInit {\n lengthComputable?: boolean;\n loaded?: number;\n total?: number;\n}\n\ninterface PushSubscriptionOptionsInit {\n userVisibleOnly?: boolean;\n applicationServerKey?: any;\n}\n\ninterface RTCConfiguration {\n iceServers?: RTCIceServer[];\n iceTransportPolicy?: RTCIceTransportPolicy;\n bundlePolicy?: RTCBundlePolicy;\n peerIdentity?: string;\n}\n\ninterface RTCDTMFToneChangeEventInit extends EventInit {\n tone?: string;\n}\n\ninterface RTCDtlsFingerprint {\n algorithm?: string;\n value?: string;\n}\n\ninterface RTCDtlsParameters {\n role?: RTCDtlsRole;\n fingerprints?: RTCDtlsFingerprint[];\n}\n\ninterface RTCIceCandidateAttributes extends RTCStats {\n ipAddress?: string;\n portNumber?: number;\n transport?: string;\n candidateType?: RTCStatsIceCandidateType;\n priority?: number;\n addressSourceUrl?: string;\n}\n\ninterface RTCIceCandidateComplete {\n}\n\ninterface RTCIceCandidateDictionary {\n foundation?: string;\n priority?: number;\n ip?: string;\n protocol?: RTCIceProtocol;\n port?: number;\n type?: RTCIceCandidateType;\n tcpType?: RTCIceTcpCandidateType;\n relatedAddress?: string;\n relatedPort?: number;\n msMTurnSessionId?: string;\n}\n\ninterface RTCIceCandidateInit {\n candidate?: string;\n sdpMid?: string;\n sdpMLineIndex?: number;\n}\n\ninterface RTCIceCandidatePair {\n local?: RTCIceCandidateDictionary;\n remote?: RTCIceCandidateDictionary;\n}\n\ninterface RTCIceCandidatePairStats extends RTCStats {\n transportId?: string;\n localCandidateId?: string;\n remoteCandidateId?: string;\n state?: RTCStatsIceCandidatePairState;\n priority?: number;\n nominated?: boolean;\n writable?: boolean;\n readable?: boolean;\n bytesSent?: number;\n bytesReceived?: number;\n roundTripTime?: number;\n availableOutgoingBitrate?: number;\n availableIncomingBitrate?: number;\n}\n\ninterface RTCIceGatherOptions {\n gatherPolicy?: RTCIceGatherPolicy;\n iceservers?: RTCIceServer[];\n portRange?: MSPortRange;\n}\n\ninterface RTCIceParameters {\n usernameFragment?: string;\n password?: string;\n iceLite?: boolean;\n}\n\ninterface RTCIceServer {\n urls?: any;\n username?: string;\n credential?: string;\n}\n\ninterface RTCInboundRTPStreamStats extends RTCRTPStreamStats {\n packetsReceived?: number;\n bytesReceived?: number;\n packetsLost?: number;\n jitter?: number;\n fractionLost?: number;\n}\n\ninterface RTCMediaStreamTrackStats extends RTCStats {\n trackIdentifier?: string;\n remoteSource?: boolean;\n ssrcIds?: string[];\n frameWidth?: number;\n frameHeight?: number;\n framesPerSecond?: number;\n framesSent?: number;\n framesReceived?: number;\n framesDecoded?: number;\n framesDropped?: number;\n framesCorrupted?: number;\n audioLevel?: number;\n echoReturnLoss?: number;\n echoReturnLossEnhancement?: number;\n}\n\ninterface RTCOfferOptions {\n offerToReceiveVideo?: number;\n offerToReceiveAudio?: number;\n voiceActivityDetection?: boolean;\n iceRestart?: boolean;\n}\n\ninterface RTCOutboundRTPStreamStats extends RTCRTPStreamStats {\n packetsSent?: number;\n bytesSent?: number;\n targetBitrate?: number;\n roundTripTime?: number;\n}\n\ninterface RTCPeerConnectionIceEventInit extends EventInit {\n candidate?: RTCIceCandidate;\n}\n\ninterface RTCRTPStreamStats extends RTCStats {\n ssrc?: string;\n associateStatsId?: string;\n isRemote?: boolean;\n mediaTrackId?: string;\n transportId?: string;\n codecId?: string;\n firCount?: number;\n pliCount?: number;\n nackCount?: number;\n sliCount?: number;\n}\n\ninterface RTCRtcpFeedback {\n type?: string;\n parameter?: string;\n}\n\ninterface RTCRtcpParameters {\n ssrc?: number;\n cname?: string;\n reducedSize?: boolean;\n mux?: boolean;\n}\n\ninterface RTCRtpCapabilities {\n codecs?: RTCRtpCodecCapability[];\n headerExtensions?: RTCRtpHeaderExtension[];\n fecMechanisms?: string[];\n}\n\ninterface RTCRtpCodecCapability {\n name?: string;\n kind?: string;\n clockRate?: number;\n preferredPayloadType?: number;\n maxptime?: number;\n ptime?: number;\n numChannels?: number;\n rtcpFeedback?: RTCRtcpFeedback[];\n parameters?: any;\n options?: any;\n maxTemporalLayers?: number;\n maxSpatialLayers?: number;\n svcMultiStreamSupport?: boolean;\n}\n\ninterface RTCRtpCodecParameters {\n name?: string;\n payloadType?: any;\n clockRate?: number;\n maxptime?: number;\n ptime?: number;\n numChannels?: number;\n rtcpFeedback?: RTCRtcpFeedback[];\n parameters?: any;\n}\n\ninterface RTCRtpContributingSource {\n timestamp?: number;\n csrc?: number;\n audioLevel?: number;\n}\n\ninterface RTCRtpEncodingParameters {\n ssrc?: number;\n codecPayloadType?: number;\n fec?: RTCRtpFecParameters;\n rtx?: RTCRtpRtxParameters;\n priority?: number;\n maxBitrate?: number;\n minQuality?: number;\n resolutionScale?: number;\n framerateScale?: number;\n maxFramerate?: number;\n active?: boolean;\n encodingId?: string;\n dependencyEncodingIds?: string[];\n ssrcRange?: RTCSsrcRange;\n}\n\ninterface RTCRtpFecParameters {\n ssrc?: number;\n mechanism?: string;\n}\n\ninterface RTCRtpHeaderExtension {\n kind?: string;\n uri?: string;\n preferredId?: number;\n preferredEncrypt?: boolean;\n}\n\ninterface RTCRtpHeaderExtensionParameters {\n uri?: string;\n id?: number;\n encrypt?: boolean;\n}\n\ninterface RTCRtpParameters {\n muxId?: string;\n codecs?: RTCRtpCodecParameters[];\n headerExtensions?: RTCRtpHeaderExtensionParameters[];\n encodings?: RTCRtpEncodingParameters[];\n rtcp?: RTCRtcpParameters;\n degradationPreference?: RTCDegradationPreference;\n}\n\ninterface RTCRtpRtxParameters {\n ssrc?: number;\n}\n\ninterface RTCRtpUnhandled {\n ssrc?: number;\n payloadType?: number;\n muxId?: string;\n}\n\ninterface RTCSessionDescriptionInit {\n type?: RTCSdpType;\n sdp?: string;\n}\n\ninterface RTCSrtpKeyParam {\n keyMethod?: string;\n keySalt?: string;\n lifetime?: string;\n mkiValue?: number;\n mkiLength?: number;\n}\n\ninterface RTCSrtpSdesParameters {\n tag?: number;\n cryptoSuite?: string;\n keyParams?: RTCSrtpKeyParam[];\n sessionParams?: string[];\n}\n\ninterface RTCSsrcRange {\n min?: number;\n max?: number;\n}\n\ninterface RTCStats {\n timestamp?: number;\n type?: RTCStatsType;\n id?: string;\n msType?: MSStatsType;\n}\n\ninterface RTCStatsReport {\n}\n\ninterface RTCTransportStats extends RTCStats {\n bytesSent?: number;\n bytesReceived?: number;\n rtcpTransportStatsId?: string;\n activeConnection?: boolean;\n selectedCandidatePairId?: string;\n localCertificateId?: string;\n remoteCertificateId?: string;\n}\n\ninterface RegistrationOptions {\n scope?: string;\n}\n\ninterface RequestInit {\n method?: string;\n headers?: any;\n body?: any;\n referrer?: string;\n referrerPolicy?: ReferrerPolicy;\n mode?: RequestMode;\n credentials?: RequestCredentials;\n cache?: RequestCache;\n redirect?: RequestRedirect;\n integrity?: string;\n keepalive?: boolean;\n window?: any;\n}\n\ninterface ResponseInit {\n status?: number;\n statusText?: string;\n headers?: any;\n}\n\ninterface ScopedCredentialDescriptor {\n type?: ScopedCredentialType;\n id?: any;\n transports?: Transport[];\n}\n\ninterface ScopedCredentialOptions {\n timeoutSeconds?: number;\n rpId?: USVString;\n excludeList?: ScopedCredentialDescriptor[];\n extensions?: WebAuthnExtensions;\n}\n\ninterface ScopedCredentialParameters {\n type?: ScopedCredentialType;\n algorithm?: string | Algorithm;\n}\n\ninterface ServiceWorkerMessageEventInit extends EventInit {\n data?: any;\n origin?: string;\n lastEventId?: string;\n source?: ServiceWorker | MessagePort;\n ports?: MessagePort[];\n}\n\ninterface SpeechSynthesisEventInit extends EventInit {\n utterance?: SpeechSynthesisUtterance;\n charIndex?: number;\n elapsedTime?: number;\n name?: string;\n}\n\ninterface StoreExceptionsInformation extends ExceptionInformation {\n siteName?: string;\n explanationString?: string;\n detailURI?: string;\n}\n\ninterface StoreSiteSpecificExceptionsInformation extends StoreExceptionsInformation {\n arrayOfDomainStrings?: string[];\n}\n\ninterface TrackEventInit extends EventInit {\n track?: VideoTrack | AudioTrack | TextTrack;\n}\n\ninterface TransitionEventInit extends EventInit {\n propertyName?: string;\n elapsedTime?: number;\n}\n\ninterface UIEventInit extends EventInit {\n view?: Window;\n detail?: number;\n}\n\ninterface WebAuthnExtensions {\n}\n\ninterface WebGLContextAttributes {\n failIfMajorPerformanceCaveat?: boolean;\n alpha?: boolean;\n depth?: boolean;\n stencil?: boolean;\n antialias?: boolean;\n premultipliedAlpha?: boolean;\n preserveDrawingBuffer?: boolean;\n}\n\ninterface WebGLContextEventInit extends EventInit {\n statusMessage?: string;\n}\n\ninterface WheelEventInit extends MouseEventInit {\n deltaX?: number;\n deltaY?: number;\n deltaZ?: number;\n deltaMode?: number;\n}\n\ninterface EventListener {\n (evt: Event): void;\n}\n\ninterface WebKitEntriesCallback {\n (evt: Event): void;\n}\n\ninterface WebKitErrorCallback {\n (evt: Event): void;\n}\n\ninterface WebKitFileCallback {\n (evt: Event): void;\n}\n\ninterface ANGLE_instanced_arrays {\n drawArraysInstancedANGLE(mode: number, first: number, count: number, primcount: number): void;\n drawElementsInstancedANGLE(mode: number, count: number, type: number, offset: number, primcount: number): void;\n vertexAttribDivisorANGLE(index: number, divisor: number): void;\n readonly VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE: number;\n}\n\ndeclare var ANGLE_instanced_arrays: {\n prototype: ANGLE_instanced_arrays;\n new(): ANGLE_instanced_arrays;\n readonly VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE: number;\n}\n\ninterface AnalyserNode extends AudioNode {\n fftSize: number;\n readonly frequencyBinCount: number;\n maxDecibels: number;\n minDecibels: number;\n smoothingTimeConstant: number;\n getByteFrequencyData(array: Uint8Array): void;\n getByteTimeDomainData(array: Uint8Array): void;\n getFloatFrequencyData(array: Float32Array): void;\n getFloatTimeDomainData(array: Float32Array): void;\n}\n\ndeclare var AnalyserNode: {\n prototype: AnalyserNode;\n new(): AnalyserNode;\n}\n\ninterface AnimationEvent extends Event {\n readonly animationName: string;\n readonly elapsedTime: number;\n initAnimationEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, animationNameArg: string, elapsedTimeArg: number): void;\n}\n\ndeclare var AnimationEvent: {\n prototype: AnimationEvent;\n new(typeArg: string, eventInitDict?: AnimationEventInit): AnimationEvent;\n}\n\ninterface ApplicationCacheEventMap {\n \"cached\": Event;\n \"checking\": Event;\n \"downloading\": Event;\n \"error\": Event;\n \"noupdate\": Event;\n \"obsolete\": Event;\n \"progress\": ProgressEvent;\n \"updateready\": Event;\n}\n\ninterface ApplicationCache extends EventTarget {\n oncached: (this: ApplicationCache, ev: Event) => any;\n onchecking: (this: ApplicationCache, ev: Event) => any;\n ondownloading: (this: ApplicationCache, ev: Event) => any;\n onerror: (this: ApplicationCache, ev: Event) => any;\n onnoupdate: (this: ApplicationCache, ev: Event) => any;\n onobsolete: (this: ApplicationCache, ev: Event) => any;\n onprogress: (this: ApplicationCache, ev: ProgressEvent) => any;\n onupdateready: (this: ApplicationCache, ev: Event) => any;\n readonly status: number;\n abort(): void;\n swapCache(): void;\n update(): void;\n readonly CHECKING: number;\n readonly DOWNLOADING: number;\n readonly IDLE: number;\n readonly OBSOLETE: number;\n readonly UNCACHED: number;\n readonly UPDATEREADY: number;\n addEventListener(type: K, listener: (this: ApplicationCache, ev: ApplicationCacheEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ApplicationCache: {\n prototype: ApplicationCache;\n new(): ApplicationCache;\n readonly CHECKING: number;\n readonly DOWNLOADING: number;\n readonly IDLE: number;\n readonly OBSOLETE: number;\n readonly UNCACHED: number;\n readonly UPDATEREADY: number;\n}\n\ninterface Attr extends Node {\n readonly name: string;\n readonly ownerElement: Element;\n readonly prefix: string | null;\n readonly specified: boolean;\n value: string;\n}\n\ndeclare var Attr: {\n prototype: Attr;\n new(): Attr;\n}\n\ninterface AudioBuffer {\n readonly duration: number;\n readonly length: number;\n readonly numberOfChannels: number;\n readonly sampleRate: number;\n copyFromChannel(destination: Float32Array, channelNumber: number, startInChannel?: number): void;\n copyToChannel(source: Float32Array, channelNumber: number, startInChannel?: number): void;\n getChannelData(channel: number): Float32Array;\n}\n\ndeclare var AudioBuffer: {\n prototype: AudioBuffer;\n new(): AudioBuffer;\n}\n\ninterface AudioBufferSourceNodeEventMap {\n \"ended\": MediaStreamErrorEvent;\n}\n\ninterface AudioBufferSourceNode extends AudioNode {\n buffer: AudioBuffer | null;\n readonly detune: AudioParam;\n loop: boolean;\n loopEnd: number;\n loopStart: number;\n onended: (this: AudioBufferSourceNode, ev: MediaStreamErrorEvent) => any;\n readonly playbackRate: AudioParam;\n start(when?: number, offset?: number, duration?: number): void;\n stop(when?: number): void;\n addEventListener(type: K, listener: (this: AudioBufferSourceNode, ev: AudioBufferSourceNodeEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var AudioBufferSourceNode: {\n prototype: AudioBufferSourceNode;\n new(): AudioBufferSourceNode;\n}\n\ninterface AudioContextEventMap {\n \"statechange\": Event;\n}\n\ninterface AudioContextBase extends EventTarget {\n readonly currentTime: number;\n readonly destination: AudioDestinationNode;\n readonly listener: AudioListener;\n onstatechange: (this: AudioContext, ev: Event) => any;\n readonly sampleRate: number;\n readonly state: AudioContextState;\n close(): Promise;\n createAnalyser(): AnalyserNode;\n createBiquadFilter(): BiquadFilterNode;\n createBuffer(numberOfChannels: number, length: number, sampleRate: number): AudioBuffer;\n createBufferSource(): AudioBufferSourceNode;\n createChannelMerger(numberOfInputs?: number): ChannelMergerNode;\n createChannelSplitter(numberOfOutputs?: number): ChannelSplitterNode;\n createConvolver(): ConvolverNode;\n createDelay(maxDelayTime?: number): DelayNode;\n createDynamicsCompressor(): DynamicsCompressorNode;\n createGain(): GainNode;\n createIIRFilter(feedforward: number[], feedback: number[]): IIRFilterNode;\n createMediaElementSource(mediaElement: HTMLMediaElement): MediaElementAudioSourceNode;\n createMediaStreamSource(mediaStream: MediaStream): MediaStreamAudioSourceNode;\n createOscillator(): OscillatorNode;\n createPanner(): PannerNode;\n createPeriodicWave(real: Float32Array, imag: Float32Array, constraints?: PeriodicWaveConstraints): PeriodicWave;\n createScriptProcessor(bufferSize?: number, numberOfInputChannels?: number, numberOfOutputChannels?: number): ScriptProcessorNode;\n createStereoPanner(): StereoPannerNode;\n createWaveShaper(): WaveShaperNode;\n decodeAudioData(audioData: ArrayBuffer, successCallback?: DecodeSuccessCallback, errorCallback?: DecodeErrorCallback): Promise;\n resume(): Promise;\n addEventListener(type: K, listener: (this: AudioContext, ev: AudioContextEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface AudioContext extends AudioContextBase {\n suspend(): Promise;\n}\n\ndeclare var AudioContext: {\n prototype: AudioContext;\n new(): AudioContext;\n}\n\ninterface AudioDestinationNode extends AudioNode {\n readonly maxChannelCount: number;\n}\n\ndeclare var AudioDestinationNode: {\n prototype: AudioDestinationNode;\n new(): AudioDestinationNode;\n}\n\ninterface AudioListener {\n dopplerFactor: number;\n speedOfSound: number;\n setOrientation(x: number, y: number, z: number, xUp: number, yUp: number, zUp: number): void;\n setPosition(x: number, y: number, z: number): void;\n setVelocity(x: number, y: number, z: number): void;\n}\n\ndeclare var AudioListener: {\n prototype: AudioListener;\n new(): AudioListener;\n}\n\ninterface AudioNode extends EventTarget {\n channelCount: number;\n channelCountMode: ChannelCountMode;\n channelInterpretation: ChannelInterpretation;\n readonly context: AudioContext;\n readonly numberOfInputs: number;\n readonly numberOfOutputs: number;\n connect(destination: AudioNode, output?: number, input?: number): AudioNode;\n connect(destination: AudioParam, output?: number): void;\n disconnect(output?: number): void;\n disconnect(destination: AudioNode, output?: number, input?: number): void;\n disconnect(destination: AudioParam, output?: number): void;\n}\n\ndeclare var AudioNode: {\n prototype: AudioNode;\n new(): AudioNode;\n}\n\ninterface AudioParam {\n readonly defaultValue: number;\n value: number;\n cancelScheduledValues(startTime: number): AudioParam;\n exponentialRampToValueAtTime(value: number, endTime: number): AudioParam;\n linearRampToValueAtTime(value: number, endTime: number): AudioParam;\n setTargetAtTime(target: number, startTime: number, timeConstant: number): AudioParam;\n setValueAtTime(value: number, startTime: number): AudioParam;\n setValueCurveAtTime(values: Float32Array, startTime: number, duration: number): AudioParam;\n}\n\ndeclare var AudioParam: {\n prototype: AudioParam;\n new(): AudioParam;\n}\n\ninterface AudioProcessingEvent extends Event {\n readonly inputBuffer: AudioBuffer;\n readonly outputBuffer: AudioBuffer;\n readonly playbackTime: number;\n}\n\ndeclare var AudioProcessingEvent: {\n prototype: AudioProcessingEvent;\n new(): AudioProcessingEvent;\n}\n\ninterface AudioTrack {\n enabled: boolean;\n readonly id: string;\n kind: string;\n readonly label: string;\n language: string;\n readonly sourceBuffer: SourceBuffer;\n}\n\ndeclare var AudioTrack: {\n prototype: AudioTrack;\n new(): AudioTrack;\n}\n\ninterface AudioTrackListEventMap {\n \"addtrack\": TrackEvent;\n \"change\": Event;\n \"removetrack\": TrackEvent;\n}\n\ninterface AudioTrackList extends EventTarget {\n readonly length: number;\n onaddtrack: (this: AudioTrackList, ev: TrackEvent) => any;\n onchange: (this: AudioTrackList, ev: Event) => any;\n onremovetrack: (this: AudioTrackList, ev: TrackEvent) => any;\n getTrackById(id: string): AudioTrack | null;\n item(index: number): AudioTrack;\n addEventListener(type: K, listener: (this: AudioTrackList, ev: AudioTrackListEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [index: number]: AudioTrack;\n}\n\ndeclare var AudioTrackList: {\n prototype: AudioTrackList;\n new(): AudioTrackList;\n}\n\ninterface BarProp {\n readonly visible: boolean;\n}\n\ndeclare var BarProp: {\n prototype: BarProp;\n new(): BarProp;\n}\n\ninterface BeforeUnloadEvent extends Event {\n returnValue: any;\n}\n\ndeclare var BeforeUnloadEvent: {\n prototype: BeforeUnloadEvent;\n new(): BeforeUnloadEvent;\n}\n\ninterface BiquadFilterNode extends AudioNode {\n readonly Q: AudioParam;\n readonly detune: AudioParam;\n readonly frequency: AudioParam;\n readonly gain: AudioParam;\n type: BiquadFilterType;\n getFrequencyResponse(frequencyHz: Float32Array, magResponse: Float32Array, phaseResponse: Float32Array): void;\n}\n\ndeclare var BiquadFilterNode: {\n prototype: BiquadFilterNode;\n new(): BiquadFilterNode;\n}\n\ninterface Blob {\n readonly size: number;\n readonly type: string;\n msClose(): void;\n msDetachStream(): any;\n slice(start?: number, end?: number, contentType?: string): Blob;\n}\n\ndeclare var Blob: {\n prototype: Blob;\n new (blobParts?: any[], options?: BlobPropertyBag): Blob;\n}\n\ninterface CDATASection extends Text {\n}\n\ndeclare var CDATASection: {\n prototype: CDATASection;\n new(): CDATASection;\n}\n\ninterface CSS {\n supports(property: string, value?: string): boolean;\n}\ndeclare var CSS: CSS;\n\ninterface CSSConditionRule extends CSSGroupingRule {\n conditionText: string;\n}\n\ndeclare var CSSConditionRule: {\n prototype: CSSConditionRule;\n new(): CSSConditionRule;\n}\n\ninterface CSSFontFaceRule extends CSSRule {\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSFontFaceRule: {\n prototype: CSSFontFaceRule;\n new(): CSSFontFaceRule;\n}\n\ninterface CSSGroupingRule extends CSSRule {\n readonly cssRules: CSSRuleList;\n deleteRule(index: number): void;\n insertRule(rule: string, index: number): number;\n}\n\ndeclare var CSSGroupingRule: {\n prototype: CSSGroupingRule;\n new(): CSSGroupingRule;\n}\n\ninterface CSSImportRule extends CSSRule {\n readonly href: string;\n readonly media: MediaList;\n readonly styleSheet: CSSStyleSheet;\n}\n\ndeclare var CSSImportRule: {\n prototype: CSSImportRule;\n new(): CSSImportRule;\n}\n\ninterface CSSKeyframeRule extends CSSRule {\n keyText: string;\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSKeyframeRule: {\n prototype: CSSKeyframeRule;\n new(): CSSKeyframeRule;\n}\n\ninterface CSSKeyframesRule extends CSSRule {\n readonly cssRules: CSSRuleList;\n name: string;\n appendRule(rule: string): void;\n deleteRule(rule: string): void;\n findRule(rule: string): CSSKeyframeRule;\n}\n\ndeclare var CSSKeyframesRule: {\n prototype: CSSKeyframesRule;\n new(): CSSKeyframesRule;\n}\n\ninterface CSSMediaRule extends CSSConditionRule {\n readonly media: MediaList;\n}\n\ndeclare var CSSMediaRule: {\n prototype: CSSMediaRule;\n new(): CSSMediaRule;\n}\n\ninterface CSSNamespaceRule extends CSSRule {\n readonly namespaceURI: string;\n readonly prefix: string;\n}\n\ndeclare var CSSNamespaceRule: {\n prototype: CSSNamespaceRule;\n new(): CSSNamespaceRule;\n}\n\ninterface CSSPageRule extends CSSRule {\n readonly pseudoClass: string;\n readonly selector: string;\n selectorText: string;\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSPageRule: {\n prototype: CSSPageRule;\n new(): CSSPageRule;\n}\n\ninterface CSSRule {\n cssText: string;\n readonly parentRule: CSSRule;\n readonly parentStyleSheet: CSSStyleSheet;\n readonly type: number;\n readonly CHARSET_RULE: number;\n readonly FONT_FACE_RULE: number;\n readonly IMPORT_RULE: number;\n readonly KEYFRAMES_RULE: number;\n readonly KEYFRAME_RULE: number;\n readonly MEDIA_RULE: number;\n readonly NAMESPACE_RULE: number;\n readonly PAGE_RULE: number;\n readonly STYLE_RULE: number;\n readonly SUPPORTS_RULE: number;\n readonly UNKNOWN_RULE: number;\n readonly VIEWPORT_RULE: number;\n}\n\ndeclare var CSSRule: {\n prototype: CSSRule;\n new(): CSSRule;\n readonly CHARSET_RULE: number;\n readonly FONT_FACE_RULE: number;\n readonly IMPORT_RULE: number;\n readonly KEYFRAMES_RULE: number;\n readonly KEYFRAME_RULE: number;\n readonly MEDIA_RULE: number;\n readonly NAMESPACE_RULE: number;\n readonly PAGE_RULE: number;\n readonly STYLE_RULE: number;\n readonly SUPPORTS_RULE: number;\n readonly UNKNOWN_RULE: number;\n readonly VIEWPORT_RULE: number;\n}\n\ninterface CSSRuleList {\n readonly length: number;\n item(index: number): CSSRule;\n [index: number]: CSSRule;\n}\n\ndeclare var CSSRuleList: {\n prototype: CSSRuleList;\n new(): CSSRuleList;\n}\n\ninterface CSSStyleDeclaration {\n alignContent: string | null;\n alignItems: string | null;\n alignSelf: string | null;\n alignmentBaseline: string | null;\n animation: string | null;\n animationDelay: string | null;\n animationDirection: string | null;\n animationDuration: string | null;\n animationFillMode: string | null;\n animationIterationCount: string | null;\n animationName: string | null;\n animationPlayState: string | null;\n animationTimingFunction: string | null;\n backfaceVisibility: string | null;\n background: string | null;\n backgroundAttachment: string | null;\n backgroundClip: string | null;\n backgroundColor: string | null;\n backgroundImage: string | null;\n backgroundOrigin: string | null;\n backgroundPosition: string | null;\n backgroundPositionX: string | null;\n backgroundPositionY: string | null;\n backgroundRepeat: string | null;\n backgroundSize: string | null;\n baselineShift: string | null;\n border: string | null;\n borderBottom: string | null;\n borderBottomColor: string | null;\n borderBottomLeftRadius: string | null;\n borderBottomRightRadius: string | null;\n borderBottomStyle: string | null;\n borderBottomWidth: string | null;\n borderCollapse: string | null;\n borderColor: string | null;\n borderImage: string | null;\n borderImageOutset: string | null;\n borderImageRepeat: string | null;\n borderImageSlice: string | null;\n borderImageSource: string | null;\n borderImageWidth: string | null;\n borderLeft: string | null;\n borderLeftColor: string | null;\n borderLeftStyle: string | null;\n borderLeftWidth: string | null;\n borderRadius: string | null;\n borderRight: string | null;\n borderRightColor: string | null;\n borderRightStyle: string | null;\n borderRightWidth: string | null;\n borderSpacing: string | null;\n borderStyle: string | null;\n borderTop: string | null;\n borderTopColor: string | null;\n borderTopLeftRadius: string | null;\n borderTopRightRadius: string | null;\n borderTopStyle: string | null;\n borderTopWidth: string | null;\n borderWidth: string | null;\n bottom: string | null;\n boxShadow: string | null;\n boxSizing: string | null;\n breakAfter: string | null;\n breakBefore: string | null;\n breakInside: string | null;\n captionSide: string | null;\n clear: string | null;\n clip: string | null;\n clipPath: string | null;\n clipRule: string | null;\n color: string | null;\n colorInterpolationFilters: string | null;\n columnCount: any;\n columnFill: string | null;\n columnGap: any;\n columnRule: string | null;\n columnRuleColor: any;\n columnRuleStyle: string | null;\n columnRuleWidth: any;\n columnSpan: string | null;\n columnWidth: any;\n columns: string | null;\n content: string | null;\n counterIncrement: string | null;\n counterReset: string | null;\n cssFloat: string | null;\n cssText: string;\n cursor: string | null;\n direction: string | null;\n display: string | null;\n dominantBaseline: string | null;\n emptyCells: string | null;\n enableBackground: string | null;\n fill: string | null;\n fillOpacity: string | null;\n fillRule: string | null;\n filter: string | null;\n flex: string | null;\n flexBasis: string | null;\n flexDirection: string | null;\n flexFlow: string | null;\n flexGrow: string | null;\n flexShrink: string | null;\n flexWrap: string | null;\n floodColor: string | null;\n floodOpacity: string | null;\n font: string | null;\n fontFamily: string | null;\n fontFeatureSettings: string | null;\n fontSize: string | null;\n fontSizeAdjust: string | null;\n fontStretch: string | null;\n fontStyle: string | null;\n fontVariant: string | null;\n fontWeight: string | null;\n glyphOrientationHorizontal: string | null;\n glyphOrientationVertical: string | null;\n height: string | null;\n imeMode: string | null;\n justifyContent: string | null;\n kerning: string | null;\n layoutGrid: string | null;\n layoutGridChar: string | null;\n layoutGridLine: string | null;\n layoutGridMode: string | null;\n layoutGridType: string | null;\n left: string | null;\n readonly length: number;\n letterSpacing: string | null;\n lightingColor: string | null;\n lineBreak: string | null;\n lineHeight: string | null;\n listStyle: string | null;\n listStyleImage: string | null;\n listStylePosition: string | null;\n listStyleType: string | null;\n margin: string | null;\n marginBottom: string | null;\n marginLeft: string | null;\n marginRight: string | null;\n marginTop: string | null;\n marker: string | null;\n markerEnd: string | null;\n markerMid: string | null;\n markerStart: string | null;\n mask: string | null;\n maxHeight: string | null;\n maxWidth: string | null;\n minHeight: string | null;\n minWidth: string | null;\n msContentZoomChaining: string | null;\n msContentZoomLimit: string | null;\n msContentZoomLimitMax: any;\n msContentZoomLimitMin: any;\n msContentZoomSnap: string | null;\n msContentZoomSnapPoints: string | null;\n msContentZoomSnapType: string | null;\n msContentZooming: string | null;\n msFlowFrom: string | null;\n msFlowInto: string | null;\n msFontFeatureSettings: string | null;\n msGridColumn: any;\n msGridColumnAlign: string | null;\n msGridColumnSpan: any;\n msGridColumns: string | null;\n msGridRow: any;\n msGridRowAlign: string | null;\n msGridRowSpan: any;\n msGridRows: string | null;\n msHighContrastAdjust: string | null;\n msHyphenateLimitChars: string | null;\n msHyphenateLimitLines: any;\n msHyphenateLimitZone: any;\n msHyphens: string | null;\n msImeAlign: string | null;\n msOverflowStyle: string | null;\n msScrollChaining: string | null;\n msScrollLimit: string | null;\n msScrollLimitXMax: any;\n msScrollLimitXMin: any;\n msScrollLimitYMax: any;\n msScrollLimitYMin: any;\n msScrollRails: string | null;\n msScrollSnapPointsX: string | null;\n msScrollSnapPointsY: string | null;\n msScrollSnapType: string | null;\n msScrollSnapX: string | null;\n msScrollSnapY: string | null;\n msScrollTranslation: string | null;\n msTextCombineHorizontal: string | null;\n msTextSizeAdjust: any;\n msTouchAction: string | null;\n msTouchSelect: string | null;\n msUserSelect: string | null;\n msWrapFlow: string;\n msWrapMargin: any;\n msWrapThrough: string;\n opacity: string | null;\n order: string | null;\n orphans: string | null;\n outline: string | null;\n outlineColor: string | null;\n outlineOffset: string | null;\n outlineStyle: string | null;\n outlineWidth: string | null;\n overflow: string | null;\n overflowX: string | null;\n overflowY: string | null;\n padding: string | null;\n paddingBottom: string | null;\n paddingLeft: string | null;\n paddingRight: string | null;\n paddingTop: string | null;\n pageBreakAfter: string | null;\n pageBreakBefore: string | null;\n pageBreakInside: string | null;\n readonly parentRule: CSSRule;\n perspective: string | null;\n perspectiveOrigin: string | null;\n pointerEvents: string | null;\n position: string | null;\n quotes: string | null;\n right: string | null;\n rotate: string | null;\n rubyAlign: string | null;\n rubyOverhang: string | null;\n rubyPosition: string | null;\n scale: string | null;\n stopColor: string | null;\n stopOpacity: string | null;\n stroke: string | null;\n strokeDasharray: string | null;\n strokeDashoffset: string | null;\n strokeLinecap: string | null;\n strokeLinejoin: string | null;\n strokeMiterlimit: string | null;\n strokeOpacity: string | null;\n strokeWidth: string | null;\n tableLayout: string | null;\n textAlign: string | null;\n textAlignLast: string | null;\n textAnchor: string | null;\n textDecoration: string | null;\n textIndent: string | null;\n textJustify: string | null;\n textKashida: string | null;\n textKashidaSpace: string | null;\n textOverflow: string | null;\n textShadow: string | null;\n textTransform: string | null;\n textUnderlinePosition: string | null;\n top: string | null;\n touchAction: string | null;\n transform: string | null;\n transformOrigin: string | null;\n transformStyle: string | null;\n transition: string | null;\n transitionDelay: string | null;\n transitionDuration: string | null;\n transitionProperty: string | null;\n transitionTimingFunction: string | null;\n translate: string | null;\n unicodeBidi: string | null;\n verticalAlign: string | null;\n visibility: string | null;\n webkitAlignContent: string | null;\n webkitAlignItems: string | null;\n webkitAlignSelf: string | null;\n webkitAnimation: string | null;\n webkitAnimationDelay: string | null;\n webkitAnimationDirection: string | null;\n webkitAnimationDuration: string | null;\n webkitAnimationFillMode: string | null;\n webkitAnimationIterationCount: string | null;\n webkitAnimationName: string | null;\n webkitAnimationPlayState: string | null;\n webkitAnimationTimingFunction: string | null;\n webkitAppearance: string | null;\n webkitBackfaceVisibility: string | null;\n webkitBackgroundClip: string | null;\n webkitBackgroundOrigin: string | null;\n webkitBackgroundSize: string | null;\n webkitBorderBottomLeftRadius: string | null;\n webkitBorderBottomRightRadius: string | null;\n webkitBorderImage: string | null;\n webkitBorderRadius: string | null;\n webkitBorderTopLeftRadius: string | null;\n webkitBorderTopRightRadius: string | null;\n webkitBoxAlign: string | null;\n webkitBoxDirection: string | null;\n webkitBoxFlex: string | null;\n webkitBoxOrdinalGroup: string | null;\n webkitBoxOrient: string | null;\n webkitBoxPack: string | null;\n webkitBoxSizing: string | null;\n webkitColumnBreakAfter: string | null;\n webkitColumnBreakBefore: string | null;\n webkitColumnBreakInside: string | null;\n webkitColumnCount: any;\n webkitColumnGap: any;\n webkitColumnRule: string | null;\n webkitColumnRuleColor: any;\n webkitColumnRuleStyle: string | null;\n webkitColumnRuleWidth: any;\n webkitColumnSpan: string | null;\n webkitColumnWidth: any;\n webkitColumns: string | null;\n webkitFilter: string | null;\n webkitFlex: string | null;\n webkitFlexBasis: string | null;\n webkitFlexDirection: string | null;\n webkitFlexFlow: string | null;\n webkitFlexGrow: string | null;\n webkitFlexShrink: string | null;\n webkitFlexWrap: string | null;\n webkitJustifyContent: string | null;\n webkitOrder: string | null;\n webkitPerspective: string | null;\n webkitPerspectiveOrigin: string | null;\n webkitTapHighlightColor: string | null;\n webkitTextFillColor: string | null;\n webkitTextSizeAdjust: any;\n webkitTextStroke: string | null;\n webkitTextStrokeColor: string | null;\n webkitTextStrokeWidth: string | null;\n webkitTransform: string | null;\n webkitTransformOrigin: string | null;\n webkitTransformStyle: string | null;\n webkitTransition: string | null;\n webkitTransitionDelay: string | null;\n webkitTransitionDuration: string | null;\n webkitTransitionProperty: string | null;\n webkitTransitionTimingFunction: string | null;\n webkitUserModify: string | null;\n webkitUserSelect: string | null;\n webkitWritingMode: string | null;\n whiteSpace: string | null;\n widows: string | null;\n width: string | null;\n wordBreak: string | null;\n wordSpacing: string | null;\n wordWrap: string | null;\n writingMode: string | null;\n zIndex: string | null;\n zoom: string | null;\n resize: string | null;\n userSelect: string | null;\n getPropertyPriority(propertyName: string): string;\n getPropertyValue(propertyName: string): string;\n item(index: number): string;\n removeProperty(propertyName: string): string;\n setProperty(propertyName: string, value: string | null, priority?: string): void;\n [index: number]: string;\n}\n\ndeclare var CSSStyleDeclaration: {\n prototype: CSSStyleDeclaration;\n new(): CSSStyleDeclaration;\n}\n\ninterface CSSStyleRule extends CSSRule {\n readonly readOnly: boolean;\n selectorText: string;\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSStyleRule: {\n prototype: CSSStyleRule;\n new(): CSSStyleRule;\n}\n\ninterface CSSStyleSheet extends StyleSheet {\n readonly cssRules: CSSRuleList;\n cssText: string;\n readonly id: string;\n readonly imports: StyleSheetList;\n readonly isAlternate: boolean;\n readonly isPrefAlternate: boolean;\n readonly ownerRule: CSSRule;\n readonly owningElement: Element;\n readonly pages: StyleSheetPageList;\n readonly readOnly: boolean;\n readonly rules: CSSRuleList;\n addImport(bstrURL: string, lIndex?: number): number;\n addPageRule(bstrSelector: string, bstrStyle: string, lIndex?: number): number;\n addRule(bstrSelector: string, bstrStyle?: string, lIndex?: number): number;\n deleteRule(index?: number): void;\n insertRule(rule: string, index?: number): number;\n removeImport(lIndex: number): void;\n removeRule(lIndex: number): void;\n}\n\ndeclare var CSSStyleSheet: {\n prototype: CSSStyleSheet;\n new(): CSSStyleSheet;\n}\n\ninterface CSSSupportsRule extends CSSConditionRule {\n}\n\ndeclare var CSSSupportsRule: {\n prototype: CSSSupportsRule;\n new(): CSSSupportsRule;\n}\n\ninterface Cache {\n add(request: RequestInfo): Promise;\n addAll(requests: RequestInfo[]): Promise;\n delete(request: RequestInfo, options?: CacheQueryOptions): Promise;\n keys(request?: RequestInfo, options?: CacheQueryOptions): any;\n match(request: RequestInfo, options?: CacheQueryOptions): Promise;\n matchAll(request?: RequestInfo, options?: CacheQueryOptions): any;\n put(request: RequestInfo, response: Response): Promise;\n}\n\ndeclare var Cache: {\n prototype: Cache;\n new(): Cache;\n}\n\ninterface CacheStorage {\n delete(cacheName: string): Promise;\n has(cacheName: string): Promise;\n keys(): any;\n match(request: RequestInfo, options?: CacheQueryOptions): Promise;\n open(cacheName: string): Promise;\n}\n\ndeclare var CacheStorage: {\n prototype: CacheStorage;\n new(): CacheStorage;\n}\n\ninterface CanvasGradient {\n addColorStop(offset: number, color: string): void;\n}\n\ndeclare var CanvasGradient: {\n prototype: CanvasGradient;\n new(): CanvasGradient;\n}\n\ninterface CanvasPattern {\n setTransform(matrix: SVGMatrix): void;\n}\n\ndeclare var CanvasPattern: {\n prototype: CanvasPattern;\n new(): CanvasPattern;\n}\n\ninterface CanvasRenderingContext2D extends Object, CanvasPathMethods {\n readonly canvas: HTMLCanvasElement;\n fillStyle: string | CanvasGradient | CanvasPattern;\n font: string;\n globalAlpha: number;\n globalCompositeOperation: string;\n imageSmoothingEnabled: boolean;\n lineCap: string;\n lineDashOffset: number;\n lineJoin: string;\n lineWidth: number;\n miterLimit: number;\n msFillRule: CanvasFillRule;\n shadowBlur: number;\n shadowColor: string;\n shadowOffsetX: number;\n shadowOffsetY: number;\n strokeStyle: string | CanvasGradient | CanvasPattern;\n textAlign: string;\n textBaseline: string;\n mozImageSmoothingEnabled: boolean;\n webkitImageSmoothingEnabled: boolean;\n oImageSmoothingEnabled: boolean;\n beginPath(): void;\n clearRect(x: number, y: number, w: number, h: number): void;\n clip(fillRule?: CanvasFillRule): void;\n createImageData(imageDataOrSw: number | ImageData, sh?: number): ImageData;\n createLinearGradient(x0: number, y0: number, x1: number, y1: number): CanvasGradient;\n createPattern(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement, repetition: string): CanvasPattern;\n createRadialGradient(x0: number, y0: number, r0: number, x1: number, y1: number, r1: number): CanvasGradient;\n drawFocusIfNeeded(element: Element): void;\n drawImage(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, dstX: number, dstY: number): void;\n drawImage(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, dstX: number, dstY: number, dstW: number, dstH: number): void;\n drawImage(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, srcX: number, srcY: number, srcW: number, srcH: number, dstX: number, dstY: number, dstW: number, dstH: number): void;\n fill(fillRule?: CanvasFillRule): void;\n fillRect(x: number, y: number, w: number, h: number): void;\n fillText(text: string, x: number, y: number, maxWidth?: number): void;\n getImageData(sx: number, sy: number, sw: number, sh: number): ImageData;\n getLineDash(): number[];\n isPointInPath(x: number, y: number, fillRule?: CanvasFillRule): boolean;\n measureText(text: string): TextMetrics;\n putImageData(imagedata: ImageData, dx: number, dy: number, dirtyX?: number, dirtyY?: number, dirtyWidth?: number, dirtyHeight?: number): void;\n restore(): void;\n rotate(angle: number): void;\n save(): void;\n scale(x: number, y: number): void;\n setLineDash(segments: number[]): void;\n setTransform(m11: number, m12: number, m21: number, m22: number, dx: number, dy: number): void;\n stroke(path?: Path2D): void;\n strokeRect(x: number, y: number, w: number, h: number): void;\n strokeText(text: string, x: number, y: number, maxWidth?: number): void;\n transform(m11: number, m12: number, m21: number, m22: number, dx: number, dy: number): void;\n translate(x: number, y: number): void;\n}\n\ndeclare var CanvasRenderingContext2D: {\n prototype: CanvasRenderingContext2D;\n new(): CanvasRenderingContext2D;\n}\n\ninterface ChannelMergerNode extends AudioNode {\n}\n\ndeclare var ChannelMergerNode: {\n prototype: ChannelMergerNode;\n new(): ChannelMergerNode;\n}\n\ninterface ChannelSplitterNode extends AudioNode {\n}\n\ndeclare var ChannelSplitterNode: {\n prototype: ChannelSplitterNode;\n new(): ChannelSplitterNode;\n}\n\ninterface CharacterData extends Node, ChildNode {\n data: string;\n readonly length: number;\n appendData(arg: string): void;\n deleteData(offset: number, count: number): void;\n insertData(offset: number, arg: string): void;\n replaceData(offset: number, count: number, arg: string): void;\n substringData(offset: number, count: number): string;\n}\n\ndeclare var CharacterData: {\n prototype: CharacterData;\n new(): CharacterData;\n}\n\ninterface ClientRect {\n bottom: number;\n readonly height: number;\n left: number;\n right: number;\n top: number;\n readonly width: number;\n}\n\ndeclare var ClientRect: {\n prototype: ClientRect;\n new(): ClientRect;\n}\n\ninterface ClientRectList {\n readonly length: number;\n item(index: number): ClientRect;\n [index: number]: ClientRect;\n}\n\ndeclare var ClientRectList: {\n prototype: ClientRectList;\n new(): ClientRectList;\n}\n\ninterface ClipboardEvent extends Event {\n readonly clipboardData: DataTransfer;\n}\n\ndeclare var ClipboardEvent: {\n prototype: ClipboardEvent;\n new(type: string, eventInitDict?: ClipboardEventInit): ClipboardEvent;\n}\n\ninterface CloseEvent extends Event {\n readonly code: number;\n readonly reason: string;\n readonly wasClean: boolean;\n initCloseEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, wasCleanArg: boolean, codeArg: number, reasonArg: string): void;\n}\n\ndeclare var CloseEvent: {\n prototype: CloseEvent;\n new(typeArg: string, eventInitDict?: CloseEventInit): CloseEvent;\n}\n\ninterface Comment extends CharacterData {\n text: string;\n}\n\ndeclare var Comment: {\n prototype: Comment;\n new(): Comment;\n}\n\ninterface CompositionEvent extends UIEvent {\n readonly data: string;\n readonly locale: string;\n initCompositionEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, dataArg: string, locale: string): void;\n}\n\ndeclare var CompositionEvent: {\n prototype: CompositionEvent;\n new(typeArg: string, eventInitDict?: CompositionEventInit): CompositionEvent;\n}\n\ninterface Console {\n assert(test?: boolean, message?: string, ...optionalParams: any[]): void;\n clear(): void;\n count(countTitle?: string): void;\n debug(message?: any, ...optionalParams: any[]): void;\n dir(value?: any, ...optionalParams: any[]): void;\n dirxml(value: any): void;\n error(message?: any, ...optionalParams: any[]): void;\n exception(message?: string, ...optionalParams: any[]): void;\n group(groupTitle?: string): void;\n groupCollapsed(groupTitle?: string): void;\n groupEnd(): void;\n info(message?: any, ...optionalParams: any[]): void;\n log(message?: any, ...optionalParams: any[]): void;\n msIsIndependentlyComposed(element: Element): boolean;\n profile(reportName?: string): void;\n profileEnd(): void;\n select(element: Element): void;\n table(...data: any[]): void;\n time(timerName?: string): void;\n timeEnd(timerName?: string): void;\n trace(message?: any, ...optionalParams: any[]): void;\n warn(message?: any, ...optionalParams: any[]): void;\n}\n\ndeclare var Console: {\n prototype: Console;\n new(): Console;\n}\n\ninterface ConvolverNode extends AudioNode {\n buffer: AudioBuffer | null;\n normalize: boolean;\n}\n\ndeclare var ConvolverNode: {\n prototype: ConvolverNode;\n new(): ConvolverNode;\n}\n\ninterface Coordinates {\n readonly accuracy: number;\n readonly altitude: number | null;\n readonly altitudeAccuracy: number | null;\n readonly heading: number | null;\n readonly latitude: number;\n readonly longitude: number;\n readonly speed: number | null;\n}\n\ndeclare var Coordinates: {\n prototype: Coordinates;\n new(): Coordinates;\n}\n\ninterface Crypto extends Object, RandomSource {\n readonly subtle: SubtleCrypto;\n}\n\ndeclare var Crypto: {\n prototype: Crypto;\n new(): Crypto;\n}\n\ninterface CryptoKey {\n readonly algorithm: KeyAlgorithm;\n readonly extractable: boolean;\n readonly type: string;\n readonly usages: string[];\n}\n\ndeclare var CryptoKey: {\n prototype: CryptoKey;\n new(): CryptoKey;\n}\n\ninterface CryptoKeyPair {\n privateKey: CryptoKey;\n publicKey: CryptoKey;\n}\n\ndeclare var CryptoKeyPair: {\n prototype: CryptoKeyPair;\n new(): CryptoKeyPair;\n}\n\ninterface CustomEvent extends Event {\n readonly detail: any;\n initCustomEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, detailArg: any): void;\n}\n\ndeclare var CustomEvent: {\n prototype: CustomEvent;\n new(typeArg: string, eventInitDict?: CustomEventInit): CustomEvent;\n}\n\ninterface DOMError {\n readonly name: string;\n toString(): string;\n}\n\ndeclare var DOMError: {\n prototype: DOMError;\n new(): DOMError;\n}\n\ninterface DOMException {\n readonly code: number;\n readonly message: string;\n readonly name: string;\n toString(): string;\n readonly ABORT_ERR: number;\n readonly DATA_CLONE_ERR: number;\n readonly DOMSTRING_SIZE_ERR: number;\n readonly HIERARCHY_REQUEST_ERR: number;\n readonly INDEX_SIZE_ERR: number;\n readonly INUSE_ATTRIBUTE_ERR: number;\n readonly INVALID_ACCESS_ERR: number;\n readonly INVALID_CHARACTER_ERR: number;\n readonly INVALID_MODIFICATION_ERR: number;\n readonly INVALID_NODE_TYPE_ERR: number;\n readonly INVALID_STATE_ERR: number;\n readonly NAMESPACE_ERR: number;\n readonly NETWORK_ERR: number;\n readonly NOT_FOUND_ERR: number;\n readonly NOT_SUPPORTED_ERR: number;\n readonly NO_DATA_ALLOWED_ERR: number;\n readonly NO_MODIFICATION_ALLOWED_ERR: number;\n readonly PARSE_ERR: number;\n readonly QUOTA_EXCEEDED_ERR: number;\n readonly SECURITY_ERR: number;\n readonly SERIALIZE_ERR: number;\n readonly SYNTAX_ERR: number;\n readonly TIMEOUT_ERR: number;\n readonly TYPE_MISMATCH_ERR: number;\n readonly URL_MISMATCH_ERR: number;\n readonly VALIDATION_ERR: number;\n readonly WRONG_DOCUMENT_ERR: number;\n}\n\ndeclare var DOMException: {\n prototype: DOMException;\n new(): DOMException;\n readonly ABORT_ERR: number;\n readonly DATA_CLONE_ERR: number;\n readonly DOMSTRING_SIZE_ERR: number;\n readonly HIERARCHY_REQUEST_ERR: number;\n readonly INDEX_SIZE_ERR: number;\n readonly INUSE_ATTRIBUTE_ERR: number;\n readonly INVALID_ACCESS_ERR: number;\n readonly INVALID_CHARACTER_ERR: number;\n readonly INVALID_MODIFICATION_ERR: number;\n readonly INVALID_NODE_TYPE_ERR: number;\n readonly INVALID_STATE_ERR: number;\n readonly NAMESPACE_ERR: number;\n readonly NETWORK_ERR: number;\n readonly NOT_FOUND_ERR: number;\n readonly NOT_SUPPORTED_ERR: number;\n readonly NO_DATA_ALLOWED_ERR: number;\n readonly NO_MODIFICATION_ALLOWED_ERR: number;\n readonly PARSE_ERR: number;\n readonly QUOTA_EXCEEDED_ERR: number;\n readonly SECURITY_ERR: number;\n readonly SERIALIZE_ERR: number;\n readonly SYNTAX_ERR: number;\n readonly TIMEOUT_ERR: number;\n readonly TYPE_MISMATCH_ERR: number;\n readonly URL_MISMATCH_ERR: number;\n readonly VALIDATION_ERR: number;\n readonly WRONG_DOCUMENT_ERR: number;\n}\n\ninterface DOMImplementation {\n createDocument(namespaceURI: string | null, qualifiedName: string | null, doctype: DocumentType | null): Document;\n createDocumentType(qualifiedName: string, publicId: string, systemId: string): DocumentType;\n createHTMLDocument(title: string): Document;\n hasFeature(feature: string | null, version: string | null): boolean;\n}\n\ndeclare var DOMImplementation: {\n prototype: DOMImplementation;\n new(): DOMImplementation;\n}\n\ninterface DOMParser {\n parseFromString(source: string, mimeType: string): Document;\n}\n\ndeclare var DOMParser: {\n prototype: DOMParser;\n new(): DOMParser;\n}\n\ninterface DOMSettableTokenList extends DOMTokenList {\n value: string;\n}\n\ndeclare var DOMSettableTokenList: {\n prototype: DOMSettableTokenList;\n new(): DOMSettableTokenList;\n}\n\ninterface DOMStringList {\n readonly length: number;\n contains(str: string): boolean;\n item(index: number): string | null;\n [index: number]: string;\n}\n\ndeclare var DOMStringList: {\n prototype: DOMStringList;\n new(): DOMStringList;\n}\n\ninterface DOMStringMap {\n [name: string]: string | undefined;\n}\n\ndeclare var DOMStringMap: {\n prototype: DOMStringMap;\n new(): DOMStringMap;\n}\n\ninterface DOMTokenList {\n readonly length: number;\n add(...token: string[]): void;\n contains(token: string): boolean;\n item(index: number): string;\n remove(...token: string[]): void;\n toString(): string;\n toggle(token: string, force?: boolean): boolean;\n [index: number]: string;\n}\n\ndeclare var DOMTokenList: {\n prototype: DOMTokenList;\n new(): DOMTokenList;\n}\n\ninterface DataCue extends TextTrackCue {\n data: ArrayBuffer;\n addEventListener(type: K, listener: (this: DataCue, ev: TextTrackCueEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var DataCue: {\n prototype: DataCue;\n new(): DataCue;\n}\n\ninterface DataTransfer {\n dropEffect: string;\n effectAllowed: string;\n readonly files: FileList;\n readonly items: DataTransferItemList;\n readonly types: string[];\n clearData(format?: string): boolean;\n getData(format: string): string;\n setData(format: string, data: string): boolean;\n setDragImage(image: Element, x: number, y: number): void;\n}\n\ndeclare var DataTransfer: {\n prototype: DataTransfer;\n new(): DataTransfer;\n}\n\ninterface DataTransferItem {\n readonly kind: string;\n readonly type: string;\n getAsFile(): File | null;\n getAsString(_callback: FunctionStringCallback | null): void;\n webkitGetAsEntry(): any;\n}\n\ndeclare var DataTransferItem: {\n prototype: DataTransferItem;\n new(): DataTransferItem;\n}\n\ninterface DataTransferItemList {\n readonly length: number;\n add(data: File): DataTransferItem | null;\n clear(): void;\n item(index: number): DataTransferItem;\n remove(index: number): void;\n [index: number]: DataTransferItem;\n}\n\ndeclare var DataTransferItemList: {\n prototype: DataTransferItemList;\n new(): DataTransferItemList;\n}\n\ninterface DeferredPermissionRequest {\n readonly id: number;\n readonly type: MSWebViewPermissionType;\n readonly uri: string;\n allow(): void;\n deny(): void;\n}\n\ndeclare var DeferredPermissionRequest: {\n prototype: DeferredPermissionRequest;\n new(): DeferredPermissionRequest;\n}\n\ninterface DelayNode extends AudioNode {\n readonly delayTime: AudioParam;\n}\n\ndeclare var DelayNode: {\n prototype: DelayNode;\n new(): DelayNode;\n}\n\ninterface DeviceAcceleration {\n readonly x: number | null;\n readonly y: number | null;\n readonly z: number | null;\n}\n\ndeclare var DeviceAcceleration: {\n prototype: DeviceAcceleration;\n new(): DeviceAcceleration;\n}\n\ninterface DeviceLightEvent extends Event {\n readonly value: number;\n}\n\ndeclare var DeviceLightEvent: {\n prototype: DeviceLightEvent;\n new(typeArg: string, eventInitDict?: DeviceLightEventInit): DeviceLightEvent;\n}\n\ninterface DeviceMotionEvent extends Event {\n readonly acceleration: DeviceAcceleration | null;\n readonly accelerationIncludingGravity: DeviceAcceleration | null;\n readonly interval: number | null;\n readonly rotationRate: DeviceRotationRate | null;\n initDeviceMotionEvent(type: string, bubbles: boolean, cancelable: boolean, acceleration: DeviceAccelerationDict | null, accelerationIncludingGravity: DeviceAccelerationDict | null, rotationRate: DeviceRotationRateDict | null, interval: number | null): void;\n}\n\ndeclare var DeviceMotionEvent: {\n prototype: DeviceMotionEvent;\n new(typeArg: string, eventInitDict?: DeviceMotionEventInit): DeviceMotionEvent;\n}\n\ninterface DeviceOrientationEvent extends Event {\n readonly absolute: boolean;\n readonly alpha: number | null;\n readonly beta: number | null;\n readonly gamma: number | null;\n initDeviceOrientationEvent(type: string, bubbles: boolean, cancelable: boolean, alpha: number | null, beta: number | null, gamma: number | null, absolute: boolean): void;\n}\n\ndeclare var DeviceOrientationEvent: {\n prototype: DeviceOrientationEvent;\n new(typeArg: string, eventInitDict?: DeviceOrientationEventInit): DeviceOrientationEvent;\n}\n\ninterface DeviceRotationRate {\n readonly alpha: number | null;\n readonly beta: number | null;\n readonly gamma: number | null;\n}\n\ndeclare var DeviceRotationRate: {\n prototype: DeviceRotationRate;\n new(): DeviceRotationRate;\n}\n\ninterface DocumentEventMap extends GlobalEventHandlersEventMap {\n \"abort\": UIEvent;\n \"activate\": UIEvent;\n \"beforeactivate\": UIEvent;\n \"beforedeactivate\": UIEvent;\n \"blur\": FocusEvent;\n \"canplay\": Event;\n \"canplaythrough\": Event;\n \"change\": Event;\n \"click\": MouseEvent;\n \"contextmenu\": PointerEvent;\n \"dblclick\": MouseEvent;\n \"deactivate\": UIEvent;\n \"drag\": DragEvent;\n \"dragend\": DragEvent;\n \"dragenter\": DragEvent;\n \"dragleave\": DragEvent;\n \"dragover\": DragEvent;\n \"dragstart\": DragEvent;\n \"drop\": DragEvent;\n \"durationchange\": Event;\n \"emptied\": Event;\n \"ended\": MediaStreamErrorEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"fullscreenchange\": Event;\n \"fullscreenerror\": Event;\n \"input\": Event;\n \"invalid\": Event;\n \"keydown\": KeyboardEvent;\n \"keypress\": KeyboardEvent;\n \"keyup\": KeyboardEvent;\n \"load\": Event;\n \"loadeddata\": Event;\n \"loadedmetadata\": Event;\n \"loadstart\": Event;\n \"mousedown\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n \"mousewheel\": WheelEvent;\n \"MSContentZoom\": UIEvent;\n \"MSGestureChange\": MSGestureEvent;\n \"MSGestureDoubleTap\": MSGestureEvent;\n \"MSGestureEnd\": MSGestureEvent;\n \"MSGestureHold\": MSGestureEvent;\n \"MSGestureStart\": MSGestureEvent;\n \"MSGestureTap\": MSGestureEvent;\n \"MSInertiaStart\": MSGestureEvent;\n \"MSManipulationStateChanged\": MSManipulationEvent;\n \"MSPointerCancel\": MSPointerEvent;\n \"MSPointerDown\": MSPointerEvent;\n \"MSPointerEnter\": MSPointerEvent;\n \"MSPointerLeave\": MSPointerEvent;\n \"MSPointerMove\": MSPointerEvent;\n \"MSPointerOut\": MSPointerEvent;\n \"MSPointerOver\": MSPointerEvent;\n \"MSPointerUp\": MSPointerEvent;\n \"mssitemodejumplistitemremoved\": MSSiteModeEvent;\n \"msthumbnailclick\": MSSiteModeEvent;\n \"pause\": Event;\n \"play\": Event;\n \"playing\": Event;\n \"pointerlockchange\": Event;\n \"pointerlockerror\": Event;\n \"progress\": ProgressEvent;\n \"ratechange\": Event;\n \"readystatechange\": Event;\n \"reset\": Event;\n \"scroll\": UIEvent;\n \"seeked\": Event;\n \"seeking\": Event;\n \"select\": UIEvent;\n \"selectionchange\": Event;\n \"selectstart\": Event;\n \"stalled\": Event;\n \"stop\": Event;\n \"submit\": Event;\n \"suspend\": Event;\n \"timeupdate\": Event;\n \"touchcancel\": TouchEvent;\n \"touchend\": TouchEvent;\n \"touchmove\": TouchEvent;\n \"touchstart\": TouchEvent;\n \"volumechange\": Event;\n \"waiting\": Event;\n \"webkitfullscreenchange\": Event;\n \"webkitfullscreenerror\": Event;\n}\n\ninterface Document extends Node, GlobalEventHandlers, NodeSelector, DocumentEvent, ParentNode, DocumentOrShadowRoot {\n /**\n * Sets or gets the URL for the current document. \n */\n readonly URL: string;\n /**\n * Gets the URL for the document, stripped of any character encoding.\n */\n readonly URLUnencoded: string;\n /**\n * Gets the object that has the focus when the parent document has focus.\n */\n readonly activeElement: Element;\n /**\n * Sets or gets the color of all active links in the document.\n */\n alinkColor: string;\n /**\n * Returns a reference to the collection of elements contained by the object.\n */\n readonly all: HTMLAllCollection;\n /**\n * Retrieves a collection of all a objects that have a name and/or id property. Objects in this collection are in HTML source order.\n */\n anchors: HTMLCollectionOf;\n /**\n * Retrieves a collection of all applet objects in the document.\n */\n applets: HTMLCollectionOf;\n /**\n * Deprecated. Sets or retrieves a value that indicates the background color behind the object. \n */\n bgColor: string;\n /**\n * Specifies the beginning and end of the document body.\n */\n body: HTMLElement;\n readonly characterSet: string;\n /**\n * Gets or sets the character set used to encode the object.\n */\n charset: string;\n /**\n * Gets a value that indicates whether standards-compliant mode is switched on for the object.\n */\n readonly compatMode: string;\n cookie: string;\n readonly currentScript: HTMLScriptElement | SVGScriptElement;\n readonly defaultView: Window;\n /**\n * Sets or gets a value that indicates whether the document can be edited.\n */\n designMode: string;\n /**\n * Sets or retrieves a value that indicates the reading order of the object. \n */\n dir: string;\n /**\n * Gets an object representing the document type declaration associated with the current document. \n */\n readonly doctype: DocumentType;\n /**\n * Gets a reference to the root node of the document. \n */\n documentElement: HTMLElement;\n /**\n * Sets or gets the security domain of the document. \n */\n domain: string;\n /**\n * Retrieves a collection of all embed objects in the document.\n */\n embeds: HTMLCollectionOf;\n /**\n * Sets or gets the foreground (text) color of the document.\n */\n fgColor: string;\n /**\n * Retrieves a collection, in source order, of all form objects in the document.\n */\n forms: HTMLCollectionOf;\n readonly fullscreenElement: Element | null;\n readonly fullscreenEnabled: boolean;\n readonly head: HTMLHeadElement;\n readonly hidden: boolean;\n /**\n * Retrieves a collection, in source order, of img objects in the document.\n */\n images: HTMLCollectionOf;\n /**\n * Gets the implementation object of the current document. \n */\n readonly implementation: DOMImplementation;\n /**\n * Returns the character encoding used to create the webpage that is loaded into the document object.\n */\n readonly inputEncoding: string | null;\n /**\n * Gets the date that the page was last modified, if the page supplies one. \n */\n readonly lastModified: string;\n /**\n * Sets or gets the color of the document links. \n */\n linkColor: string;\n /**\n * Retrieves a collection of all a objects that specify the href property and all area objects in the document.\n */\n links: HTMLCollectionOf;\n /**\n * Contains information about the current URL. \n */\n readonly location: Location;\n msCSSOMElementFloatMetrics: boolean;\n msCapsLockWarningOff: boolean;\n /**\n * Fires when the user aborts the download.\n * @param ev The event.\n */\n onabort: (this: Document, ev: UIEvent) => any;\n /**\n * Fires when the object is set as the active element.\n * @param ev The event.\n */\n onactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires immediately before the object is set as the active element.\n * @param ev The event.\n */\n onbeforeactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires immediately before the activeElement is changed from the current object to another object in the parent document.\n * @param ev The event.\n */\n onbeforedeactivate: (this: Document, ev: UIEvent) => any;\n /** \n * Fires when the object loses the input focus. \n * @param ev The focus event.\n */\n onblur: (this: Document, ev: FocusEvent) => any;\n /**\n * Occurs when playback is possible, but would require further buffering. \n * @param ev The event.\n */\n oncanplay: (this: Document, ev: Event) => any;\n oncanplaythrough: (this: Document, ev: Event) => any;\n /**\n * Fires when the contents of the object or selection have changed. \n * @param ev The event.\n */\n onchange: (this: Document, ev: Event) => any;\n /**\n * Fires when the user clicks the left mouse button on the object\n * @param ev The mouse event.\n */\n onclick: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user clicks the right mouse button in the client area, opening the context menu. \n * @param ev The mouse event.\n */\n oncontextmenu: (this: Document, ev: PointerEvent) => any;\n /**\n * Fires when the user double-clicks the object.\n * @param ev The mouse event.\n */\n ondblclick: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the activeElement is changed from the current object to another object in the parent document.\n * @param ev The UI Event\n */\n ondeactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires on the source object continuously during a drag operation.\n * @param ev The event.\n */\n ondrag: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the source object when the user releases the mouse at the close of a drag operation.\n * @param ev The event.\n */\n ondragend: (this: Document, ev: DragEvent) => any;\n /** \n * Fires on the target element when the user drags the object to a valid drop target.\n * @param ev The drag event.\n */\n ondragenter: (this: Document, ev: DragEvent) => any;\n /** \n * Fires on the target object when the user moves the mouse out of a valid drop target during a drag operation.\n * @param ev The drag event.\n */\n ondragleave: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the target element continuously while the user drags the object over a valid drop target.\n * @param ev The event.\n */\n ondragover: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the source object when the user starts to drag a text selection or selected object. \n * @param ev The event.\n */\n ondragstart: (this: Document, ev: DragEvent) => any;\n ondrop: (this: Document, ev: DragEvent) => any;\n /**\n * Occurs when the duration attribute is updated. \n * @param ev The event.\n */\n ondurationchange: (this: Document, ev: Event) => any;\n /**\n * Occurs when the media element is reset to its initial state. \n * @param ev The event.\n */\n onemptied: (this: Document, ev: Event) => any;\n /**\n * Occurs when the end of playback is reached. \n * @param ev The event\n */\n onended: (this: Document, ev: MediaStreamErrorEvent) => any;\n /**\n * Fires when an error occurs during object loading.\n * @param ev The event.\n */\n onerror: (this: Document, ev: ErrorEvent) => any;\n /**\n * Fires when the object receives focus. \n * @param ev The event.\n */\n onfocus: (this: Document, ev: FocusEvent) => any;\n onfullscreenchange: (this: Document, ev: Event) => any;\n onfullscreenerror: (this: Document, ev: Event) => any;\n oninput: (this: Document, ev: Event) => any;\n oninvalid: (this: Document, ev: Event) => any;\n /**\n * Fires when the user presses a key.\n * @param ev The keyboard event\n */\n onkeydown: (this: Document, ev: KeyboardEvent) => any;\n /**\n * Fires when the user presses an alphanumeric key.\n * @param ev The event.\n */\n onkeypress: (this: Document, ev: KeyboardEvent) => any;\n /**\n * Fires when the user releases a key.\n * @param ev The keyboard event\n */\n onkeyup: (this: Document, ev: KeyboardEvent) => any;\n /**\n * Fires immediately after the browser loads the object. \n * @param ev The event.\n */\n onload: (this: Document, ev: Event) => any;\n /**\n * Occurs when media data is loaded at the current playback position. \n * @param ev The event.\n */\n onloadeddata: (this: Document, ev: Event) => any;\n /**\n * Occurs when the duration and dimensions of the media have been determined.\n * @param ev The event.\n */\n onloadedmetadata: (this: Document, ev: Event) => any;\n /**\n * Occurs when Internet Explorer begins looking for media data. \n * @param ev The event.\n */\n onloadstart: (this: Document, ev: Event) => any;\n /**\n * Fires when the user clicks the object with either mouse button. \n * @param ev The mouse event.\n */\n onmousedown: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user moves the mouse over the object. \n * @param ev The mouse event.\n */\n onmousemove: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user moves the mouse pointer outside the boundaries of the object. \n * @param ev The mouse event.\n */\n onmouseout: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user moves the mouse pointer into the object.\n * @param ev The mouse event.\n */\n onmouseover: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user releases a mouse button while the mouse is over the object. \n * @param ev The mouse event.\n */\n onmouseup: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the wheel button is rotated. \n * @param ev The mouse event\n */\n onmousewheel: (this: Document, ev: WheelEvent) => any;\n onmscontentzoom: (this: Document, ev: UIEvent) => any;\n onmsgesturechange: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturedoubletap: (this: Document, ev: MSGestureEvent) => any;\n onmsgestureend: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturehold: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturestart: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturetap: (this: Document, ev: MSGestureEvent) => any;\n onmsinertiastart: (this: Document, ev: MSGestureEvent) => any;\n onmsmanipulationstatechanged: (this: Document, ev: MSManipulationEvent) => any;\n onmspointercancel: (this: Document, ev: MSPointerEvent) => any;\n onmspointerdown: (this: Document, ev: MSPointerEvent) => any;\n onmspointerenter: (this: Document, ev: MSPointerEvent) => any;\n onmspointerleave: (this: Document, ev: MSPointerEvent) => any;\n onmspointermove: (this: Document, ev: MSPointerEvent) => any;\n onmspointerout: (this: Document, ev: MSPointerEvent) => any;\n onmspointerover: (this: Document, ev: MSPointerEvent) => any;\n onmspointerup: (this: Document, ev: MSPointerEvent) => any;\n /**\n * Occurs when an item is removed from a Jump List of a webpage running in Site Mode. \n * @param ev The event.\n */\n onmssitemodejumplistitemremoved: (this: Document, ev: MSSiteModeEvent) => any;\n /**\n * Occurs when a user clicks a button in a Thumbnail Toolbar of a webpage running in Site Mode.\n * @param ev The event.\n */\n onmsthumbnailclick: (this: Document, ev: MSSiteModeEvent) => any;\n /**\n * Occurs when playback is paused.\n * @param ev The event.\n */\n onpause: (this: Document, ev: Event) => any;\n /**\n * Occurs when the play method is requested. \n * @param ev The event.\n */\n onplay: (this: Document, ev: Event) => any;\n /**\n * Occurs when the audio or video has started playing. \n * @param ev The event.\n */\n onplaying: (this: Document, ev: Event) => any;\n onpointerlockchange: (this: Document, ev: Event) => any;\n onpointerlockerror: (this: Document, ev: Event) => any;\n /**\n * Occurs to indicate progress while downloading media data. \n * @param ev The event.\n */\n onprogress: (this: Document, ev: ProgressEvent) => any;\n /**\n * Occurs when the playback rate is increased or decreased. \n * @param ev The event.\n */\n onratechange: (this: Document, ev: Event) => any;\n /**\n * Fires when the state of the object has changed.\n * @param ev The event\n */\n onreadystatechange: (this: Document, ev: Event) => any;\n /**\n * Fires when the user resets a form. \n * @param ev The event.\n */\n onreset: (this: Document, ev: Event) => any;\n /**\n * Fires when the user repositions the scroll box in the scroll bar on the object. \n * @param ev The event.\n */\n onscroll: (this: Document, ev: UIEvent) => any;\n /**\n * Occurs when the seek operation ends. \n * @param ev The event.\n */\n onseeked: (this: Document, ev: Event) => any;\n /**\n * Occurs when the current playback position is moved. \n * @param ev The event.\n */\n onseeking: (this: Document, ev: Event) => any;\n /**\n * Fires when the current selection changes.\n * @param ev The event.\n */\n onselect: (this: Document, ev: UIEvent) => any;\n /**\n * Fires when the selection state of a document changes.\n * @param ev The event.\n */\n onselectionchange: (this: Document, ev: Event) => any;\n onselectstart: (this: Document, ev: Event) => any;\n /**\n * Occurs when the download has stopped. \n * @param ev The event.\n */\n onstalled: (this: Document, ev: Event) => any;\n /**\n * Fires when the user clicks the Stop button or leaves the Web page.\n * @param ev The event.\n */\n onstop: (this: Document, ev: Event) => any;\n onsubmit: (this: Document, ev: Event) => any;\n /**\n * Occurs if the load operation has been intentionally halted. \n * @param ev The event.\n */\n onsuspend: (this: Document, ev: Event) => any;\n /**\n * Occurs to indicate the current playback position.\n * @param ev The event.\n */\n ontimeupdate: (this: Document, ev: Event) => any;\n ontouchcancel: (ev: TouchEvent) => any;\n ontouchend: (ev: TouchEvent) => any;\n ontouchmove: (ev: TouchEvent) => any;\n ontouchstart: (ev: TouchEvent) => any;\n /**\n * Occurs when the volume is changed, or playback is muted or unmuted.\n * @param ev The event.\n */\n onvolumechange: (this: Document, ev: Event) => any;\n /**\n * Occurs when playback stops because the next frame of a video resource is not available. \n * @param ev The event.\n */\n onwaiting: (this: Document, ev: Event) => any;\n onwebkitfullscreenchange: (this: Document, ev: Event) => any;\n onwebkitfullscreenerror: (this: Document, ev: Event) => any;\n plugins: HTMLCollectionOf;\n readonly pointerLockElement: Element;\n /**\n * Retrieves a value that indicates the current state of the object.\n */\n readonly readyState: string;\n /**\n * Gets the URL of the location that referred the user to the current page.\n */\n readonly referrer: string;\n /**\n * Gets the root svg element in the document hierarchy.\n */\n readonly rootElement: SVGSVGElement;\n /**\n * Retrieves a collection of all script objects in the document.\n */\n scripts: HTMLCollectionOf;\n readonly scrollingElement: Element | null;\n /**\n * Retrieves a collection of styleSheet objects representing the style sheets that correspond to each instance of a link or style object in the document.\n */\n readonly styleSheets: StyleSheetList;\n /**\n * Contains the title of the document.\n */\n title: string;\n readonly visibilityState: VisibilityState;\n /** \n * Sets or gets the color of the links that the user has visited.\n */\n vlinkColor: string;\n readonly webkitCurrentFullScreenElement: Element | null;\n readonly webkitFullscreenElement: Element | null;\n readonly webkitFullscreenEnabled: boolean;\n readonly webkitIsFullScreen: boolean;\n readonly xmlEncoding: string | null;\n xmlStandalone: boolean;\n /**\n * Gets or sets the version attribute specified in the declaration of an XML document.\n */\n xmlVersion: string | null;\n adoptNode(source: T): T;\n captureEvents(): void;\n caretRangeFromPoint(x: number, y: number): Range;\n clear(): void;\n /**\n * Closes an output stream and forces the sent data to display.\n */\n close(): void;\n /**\n * Creates an attribute object with a specified name.\n * @param name String that sets the attribute object's name.\n */\n createAttribute(name: string): Attr;\n createAttributeNS(namespaceURI: string | null, qualifiedName: string): Attr;\n createCDATASection(data: string): CDATASection;\n /**\n * Creates a comment object with the specified data.\n * @param data Sets the comment object's data.\n */\n createComment(data: string): Comment;\n /**\n * Creates a new document.\n */\n createDocumentFragment(): DocumentFragment;\n /**\n * Creates an instance of the element for the specified tag.\n * @param tagName The name of an element.\n */\n createElement(tagName: K): HTMLElementTagNameMap[K];\n createElement(tagName: string): HTMLElement;\n createElementNS(namespaceURI: \"http://www.w3.org/1999/xhtml\", qualifiedName: string): HTMLElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"a\"): SVGAElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"circle\"): SVGCircleElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"clipPath\"): SVGClipPathElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"componentTransferFunction\"): SVGComponentTransferFunctionElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"defs\"): SVGDefsElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"desc\"): SVGDescElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"ellipse\"): SVGEllipseElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feBlend\"): SVGFEBlendElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feColorMatrix\"): SVGFEColorMatrixElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feComponentTransfer\"): SVGFEComponentTransferElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feComposite\"): SVGFECompositeElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feConvolveMatrix\"): SVGFEConvolveMatrixElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feDiffuseLighting\"): SVGFEDiffuseLightingElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feDisplacementMap\"): SVGFEDisplacementMapElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feDistantLight\"): SVGFEDistantLightElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFlood\"): SVGFEFloodElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncA\"): SVGFEFuncAElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncB\"): SVGFEFuncBElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncG\"): SVGFEFuncGElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncR\"): SVGFEFuncRElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feGaussianBlur\"): SVGFEGaussianBlurElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feImage\"): SVGFEImageElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feMerge\"): SVGFEMergeElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feMergeNode\"): SVGFEMergeNodeElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feMorphology\"): SVGFEMorphologyElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feOffset\"): SVGFEOffsetElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"fePointLight\"): SVGFEPointLightElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feSpecularLighting\"): SVGFESpecularLightingElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feSpotLight\"): SVGFESpotLightElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feTile\"): SVGFETileElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feTurbulence\"): SVGFETurbulenceElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"filter\"): SVGFilterElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"foreignObject\"): SVGForeignObjectElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"g\"): SVGGElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"image\"): SVGImageElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"gradient\"): SVGGradientElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"line\"): SVGLineElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"linearGradient\"): SVGLinearGradientElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"marker\"): SVGMarkerElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"mask\"): SVGMaskElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"path\"): SVGPathElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"metadata\"): SVGMetadataElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"pattern\"): SVGPatternElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"polygon\"): SVGPolygonElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"polyline\"): SVGPolylineElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"radialGradient\"): SVGRadialGradientElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"rect\"): SVGRectElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"svg\"): SVGSVGElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"script\"): SVGScriptElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"stop\"): SVGStopElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"style\"): SVGStyleElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"switch\"): SVGSwitchElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"symbol\"): SVGSymbolElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"tspan\"): SVGTSpanElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"textContent\"): SVGTextContentElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"text\"): SVGTextElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"textPath\"): SVGTextPathElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"textPositioning\"): SVGTextPositioningElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"title\"): SVGTitleElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"use\"): SVGUseElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"view\"): SVGViewElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: string): SVGElement\n createElementNS(namespaceURI: string | null, qualifiedName: string): Element;\n createExpression(expression: string, resolver: XPathNSResolver): XPathExpression;\n createNSResolver(nodeResolver: Node): XPathNSResolver;\n /**\n * Creates a NodeIterator object that you can use to traverse filtered lists of nodes or elements in a document. \n * @param root The root element or node to start traversing on.\n * @param whatToShow The type of nodes or elements to appear in the node list\n * @param filter A custom NodeFilter function to use. For more information, see filter. Use null for no filter.\n * @param entityReferenceExpansion A flag that specifies whether entity reference nodes are expanded.\n */\n createNodeIterator(root: Node, whatToShow?: number, filter?: NodeFilter, entityReferenceExpansion?: boolean): NodeIterator;\n createProcessingInstruction(target: string, data: string): ProcessingInstruction;\n /**\n * Returns an empty range object that has both of its boundary points positioned at the beginning of the document. \n */\n createRange(): Range;\n /**\n * Creates a text string from the specified value. \n * @param data String that specifies the nodeValue property of the text node.\n */\n createTextNode(data: string): Text;\n createTouch(view: Window, target: EventTarget, identifier: number, pageX: number, pageY: number, screenX: number, screenY: number): Touch;\n createTouchList(...touches: Touch[]): TouchList;\n /**\n * Creates a TreeWalker object that you can use to traverse filtered lists of nodes or elements in a document.\n * @param root The root element or node to start traversing on.\n * @param whatToShow The type of nodes or elements to appear in the node list. For more information, see whatToShow.\n * @param filter A custom NodeFilter function to use.\n * @param entityReferenceExpansion A flag that specifies whether entity reference nodes are expanded.\n */\n createTreeWalker(root: Node, whatToShow?: number, filter?: NodeFilter, entityReferenceExpansion?: boolean): TreeWalker;\n /**\n * Returns the element for the specified x coordinate and the specified y coordinate. \n * @param x The x-offset\n * @param y The y-offset\n */\n elementFromPoint(x: number, y: number): Element;\n evaluate(expression: string, contextNode: Node, resolver: XPathNSResolver | null, type: number, result: XPathResult | null): XPathResult;\n /**\n * Executes a command on the current document, current selection, or the given range.\n * @param commandId String that specifies the command to execute. This command can be any of the command identifiers that can be executed in script.\n * @param showUI Display the user interface, defaults to false.\n * @param value Value to assign.\n */\n execCommand(commandId: string, showUI?: boolean, value?: any): boolean;\n /**\n * Displays help information for the given command identifier.\n * @param commandId Displays help information for the given command identifier.\n */\n execCommandShowHelp(commandId: string): boolean;\n exitFullscreen(): void;\n exitPointerLock(): void;\n /**\n * Causes the element to receive the focus and executes the code specified by the onfocus event.\n */\n focus(): void;\n /**\n * Returns a reference to the first object with the specified value of the ID or NAME attribute.\n * @param elementId String that specifies the ID value. Case-insensitive.\n */\n getElementById(elementId: string): HTMLElement | null;\n getElementsByClassName(classNames: string): HTMLCollectionOf;\n /**\n * Gets a collection of objects based on the value of the NAME or ID attribute.\n * @param elementName Gets a collection of objects based on the value of the NAME or ID attribute.\n */\n getElementsByName(elementName: string): NodeListOf;\n /**\n * Retrieves a collection of objects based on the specified element name.\n * @param name Specifies the name of an element.\n */\n getElementsByTagName(tagname: K): ElementListTagNameMap[K];\n getElementsByTagName(tagname: string): NodeListOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/1999/xhtml\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/2000/svg\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: string, localName: string): HTMLCollectionOf;\n /**\n * Returns an object representing the current selection of the document that is loaded into the object displaying a webpage.\n */\n getSelection(): Selection;\n /**\n * Gets a value indicating whether the object currently has focus.\n */\n hasFocus(): boolean;\n importNode(importedNode: T, deep: boolean): T;\n msElementsFromPoint(x: number, y: number): NodeListOf;\n msElementsFromRect(left: number, top: number, width: number, height: number): NodeListOf;\n /**\n * Opens a new window and loads a document specified by a given URL. Also, opens a new window that uses the url parameter and the name parameter to collect the output of the write method and the writeln method.\n * @param url Specifies a MIME type for the document.\n * @param name Specifies the name of the window. This name is used as the value for the TARGET attribute on a form or an anchor element.\n * @param features Contains a list of items separated by commas. Each item consists of an option and a value, separated by an equals sign (for example, \"fullscreen=yes, toolbar=yes\"). The following values are supported.\n * @param replace Specifies whether the existing entry for the document is replaced in the history list.\n */\n open(url?: string, name?: string, features?: string, replace?: boolean): Document;\n /** \n * Returns a Boolean value that indicates whether a specified command can be successfully executed using execCommand, given the current state of the document.\n * @param commandId Specifies a command identifier.\n */\n queryCommandEnabled(commandId: string): boolean;\n /**\n * Returns a Boolean value that indicates whether the specified command is in the indeterminate state.\n * @param commandId String that specifies a command identifier.\n */\n queryCommandIndeterm(commandId: string): boolean;\n /**\n * Returns a Boolean value that indicates the current state of the command.\n * @param commandId String that specifies a command identifier.\n */\n queryCommandState(commandId: string): boolean;\n /**\n * Returns a Boolean value that indicates whether the current command is supported on the current range.\n * @param commandId Specifies a command identifier.\n */\n queryCommandSupported(commandId: string): boolean;\n /**\n * Retrieves the string associated with a command.\n * @param commandId String that contains the identifier of a command. This can be any command identifier given in the list of Command Identifiers. \n */\n queryCommandText(commandId: string): string;\n /**\n * Returns the current value of the document, range, or current selection for the given command.\n * @param commandId String that specifies a command identifier.\n */\n queryCommandValue(commandId: string): string;\n releaseEvents(): void;\n /**\n * Allows updating the print settings for the page.\n */\n updateSettings(): void;\n webkitCancelFullScreen(): void;\n webkitExitFullscreen(): void;\n /**\n * Writes one or more HTML expressions to a document in the specified window. \n * @param content Specifies the text and HTML tags to write.\n */\n write(...content: string[]): void;\n /**\n * Writes one or more HTML expressions, followed by a carriage return, to a document in the specified window. \n * @param content The text and HTML tags to write.\n */\n writeln(...content: string[]): void;\n addEventListener(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Document: {\n prototype: Document;\n new(): Document;\n}\n\ninterface DocumentFragment extends Node, NodeSelector, ParentNode {\n getElementById(elementId: string): HTMLElement | null;\n}\n\ndeclare var DocumentFragment: {\n prototype: DocumentFragment;\n new(): DocumentFragment;\n}\n\ninterface DocumentType extends Node, ChildNode {\n readonly entities: NamedNodeMap;\n readonly internalSubset: string | null;\n readonly name: string;\n readonly notations: NamedNodeMap;\n readonly publicId: string;\n readonly systemId: string;\n}\n\ndeclare var DocumentType: {\n prototype: DocumentType;\n new(): DocumentType;\n}\n\ninterface DragEvent extends MouseEvent {\n readonly dataTransfer: DataTransfer;\n initDragEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget, dataTransferArg: DataTransfer): void;\n msConvertURL(file: File, targetType: string, targetURL?: string): void;\n}\n\ndeclare var DragEvent: {\n prototype: DragEvent;\n new(): DragEvent;\n}\n\ninterface DynamicsCompressorNode extends AudioNode {\n readonly attack: AudioParam;\n readonly knee: AudioParam;\n readonly ratio: AudioParam;\n readonly reduction: number;\n readonly release: AudioParam;\n readonly threshold: AudioParam;\n}\n\ndeclare var DynamicsCompressorNode: {\n prototype: DynamicsCompressorNode;\n new(): DynamicsCompressorNode;\n}\n\ninterface EXT_frag_depth {\n}\n\ndeclare var EXT_frag_depth: {\n prototype: EXT_frag_depth;\n new(): EXT_frag_depth;\n}\n\ninterface EXT_texture_filter_anisotropic {\n readonly MAX_TEXTURE_MAX_ANISOTROPY_EXT: number;\n readonly TEXTURE_MAX_ANISOTROPY_EXT: number;\n}\n\ndeclare var EXT_texture_filter_anisotropic: {\n prototype: EXT_texture_filter_anisotropic;\n new(): EXT_texture_filter_anisotropic;\n readonly MAX_TEXTURE_MAX_ANISOTROPY_EXT: number;\n readonly TEXTURE_MAX_ANISOTROPY_EXT: number;\n}\n\ninterface ElementEventMap extends GlobalEventHandlersEventMap {\n \"ariarequest\": Event;\n \"command\": Event;\n \"gotpointercapture\": PointerEvent;\n \"lostpointercapture\": PointerEvent;\n \"MSGestureChange\": MSGestureEvent;\n \"MSGestureDoubleTap\": MSGestureEvent;\n \"MSGestureEnd\": MSGestureEvent;\n \"MSGestureHold\": MSGestureEvent;\n \"MSGestureStart\": MSGestureEvent;\n \"MSGestureTap\": MSGestureEvent;\n \"MSGotPointerCapture\": MSPointerEvent;\n \"MSInertiaStart\": MSGestureEvent;\n \"MSLostPointerCapture\": MSPointerEvent;\n \"MSPointerCancel\": MSPointerEvent;\n \"MSPointerDown\": MSPointerEvent;\n \"MSPointerEnter\": MSPointerEvent;\n \"MSPointerLeave\": MSPointerEvent;\n \"MSPointerMove\": MSPointerEvent;\n \"MSPointerOut\": MSPointerEvent;\n \"MSPointerOver\": MSPointerEvent;\n \"MSPointerUp\": MSPointerEvent;\n \"touchcancel\": TouchEvent;\n \"touchend\": TouchEvent;\n \"touchmove\": TouchEvent;\n \"touchstart\": TouchEvent;\n \"webkitfullscreenchange\": Event;\n \"webkitfullscreenerror\": Event;\n}\n\ninterface Element extends Node, GlobalEventHandlers, ElementTraversal, NodeSelector, ChildNode, ParentNode {\n readonly classList: DOMTokenList;\n className: string;\n readonly clientHeight: number;\n readonly clientLeft: number;\n readonly clientTop: number;\n readonly clientWidth: number;\n id: string;\n innerHTML: string;\n msContentZoomFactor: number;\n readonly msRegionOverflow: string;\n onariarequest: (this: Element, ev: Event) => any;\n oncommand: (this: Element, ev: Event) => any;\n ongotpointercapture: (this: Element, ev: PointerEvent) => any;\n onlostpointercapture: (this: Element, ev: PointerEvent) => any;\n onmsgesturechange: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturedoubletap: (this: Element, ev: MSGestureEvent) => any;\n onmsgestureend: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturehold: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturestart: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturetap: (this: Element, ev: MSGestureEvent) => any;\n onmsgotpointercapture: (this: Element, ev: MSPointerEvent) => any;\n onmsinertiastart: (this: Element, ev: MSGestureEvent) => any;\n onmslostpointercapture: (this: Element, ev: MSPointerEvent) => any;\n onmspointercancel: (this: Element, ev: MSPointerEvent) => any;\n onmspointerdown: (this: Element, ev: MSPointerEvent) => any;\n onmspointerenter: (this: Element, ev: MSPointerEvent) => any;\n onmspointerleave: (this: Element, ev: MSPointerEvent) => any;\n onmspointermove: (this: Element, ev: MSPointerEvent) => any;\n onmspointerout: (this: Element, ev: MSPointerEvent) => any;\n onmspointerover: (this: Element, ev: MSPointerEvent) => any;\n onmspointerup: (this: Element, ev: MSPointerEvent) => any;\n ontouchcancel: (ev: TouchEvent) => any;\n ontouchend: (ev: TouchEvent) => any;\n ontouchmove: (ev: TouchEvent) => any;\n ontouchstart: (ev: TouchEvent) => any;\n onwebkitfullscreenchange: (this: Element, ev: Event) => any;\n onwebkitfullscreenerror: (this: Element, ev: Event) => any;\n outerHTML: string;\n readonly prefix: string | null;\n readonly scrollHeight: number;\n scrollLeft: number;\n scrollTop: number;\n readonly scrollWidth: number;\n readonly tagName: string;\n readonly assignedSlot: HTMLSlotElement | null;\n slot: string;\n readonly shadowRoot: ShadowRoot | null;\n getAttribute(name: string): string | null;\n getAttributeNS(namespaceURI: string, localName: string): string;\n getAttributeNode(name: string): Attr;\n getAttributeNodeNS(namespaceURI: string, localName: string): Attr;\n getBoundingClientRect(): ClientRect;\n getClientRects(): ClientRectList;\n getElementsByTagName(name: K): ElementListTagNameMap[K];\n getElementsByTagName(name: string): NodeListOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/1999/xhtml\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/2000/svg\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: string, localName: string): HTMLCollectionOf;\n hasAttribute(name: string): boolean;\n hasAttributeNS(namespaceURI: string, localName: string): boolean;\n msGetRegionContent(): MSRangeCollection;\n msGetUntransformedBounds(): ClientRect;\n msMatchesSelector(selectors: string): boolean;\n msReleasePointerCapture(pointerId: number): void;\n msSetPointerCapture(pointerId: number): void;\n msZoomTo(args: MsZoomToOptions): void;\n releasePointerCapture(pointerId: number): void;\n removeAttribute(qualifiedName: string): void;\n removeAttributeNS(namespaceURI: string, localName: string): void;\n removeAttributeNode(oldAttr: Attr): Attr;\n requestFullscreen(): void;\n requestPointerLock(): void;\n setAttribute(name: string, value: string): void;\n setAttributeNS(namespaceURI: string, qualifiedName: string, value: string): void;\n setAttributeNode(newAttr: Attr): Attr;\n setAttributeNodeNS(newAttr: Attr): Attr;\n setPointerCapture(pointerId: number): void;\n webkitMatchesSelector(selectors: string): boolean;\n webkitRequestFullScreen(): void;\n webkitRequestFullscreen(): void;\n getElementsByClassName(classNames: string): NodeListOf;\n matches(selector: string): boolean;\n closest(selector: string): Element | null;\n scrollIntoView(arg?: boolean | ScrollIntoViewOptions): void;\n scroll(options?: ScrollToOptions): void;\n scroll(x: number, y: number): void;\n scrollTo(options?: ScrollToOptions): void;\n scrollTo(x: number, y: number): void;\n scrollBy(options?: ScrollToOptions): void;\n scrollBy(x: number, y: number): void;\n insertAdjacentElement(position: string, insertedElement: Element): Element | null;\n insertAdjacentHTML(where: string, html: string): void;\n insertAdjacentText(where: string, text: string): void;\n attachShadow(shadowRootInitDict: ShadowRootInit): ShadowRoot;\n addEventListener(type: K, listener: (this: Element, ev: ElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Element: {\n prototype: Element;\n new(): Element;\n}\n\ninterface ErrorEvent extends Event {\n readonly colno: number;\n readonly error: any;\n readonly filename: string;\n readonly lineno: number;\n readonly message: string;\n initErrorEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, messageArg: string, filenameArg: string, linenoArg: number): void;\n}\n\ndeclare var ErrorEvent: {\n prototype: ErrorEvent;\n new(type: string, errorEventInitDict?: ErrorEventInit): ErrorEvent;\n}\n\ninterface Event {\n readonly bubbles: boolean;\n cancelBubble: boolean;\n readonly cancelable: boolean;\n readonly currentTarget: EventTarget;\n readonly defaultPrevented: boolean;\n readonly eventPhase: number;\n readonly isTrusted: boolean;\n returnValue: boolean;\n readonly srcElement: Element | null;\n readonly target: EventTarget;\n readonly timeStamp: number;\n readonly type: string;\n readonly scoped: boolean;\n initEvent(eventTypeArg: string, canBubbleArg: boolean, cancelableArg: boolean): void;\n preventDefault(): void;\n stopImmediatePropagation(): void;\n stopPropagation(): void;\n deepPath(): EventTarget[];\n readonly AT_TARGET: number;\n readonly BUBBLING_PHASE: number;\n readonly CAPTURING_PHASE: number;\n}\n\ndeclare var Event: {\n prototype: Event;\n new(typeArg: string, eventInitDict?: EventInit): Event;\n readonly AT_TARGET: number;\n readonly BUBBLING_PHASE: number;\n readonly CAPTURING_PHASE: number;\n}\n\ninterface EventTarget {\n addEventListener(type: string, listener?: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;\n dispatchEvent(evt: Event): boolean;\n removeEventListener(type: string, listener?: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;\n}\n\ndeclare var EventTarget: {\n prototype: EventTarget;\n new(): EventTarget;\n}\n\ninterface ExtensionScriptApis {\n extensionIdToShortId(extensionId: string): number;\n fireExtensionApiTelemetry(functionName: string, isSucceeded: boolean, isSupported: boolean): void;\n genericFunction(routerAddress: any, parameters?: string, callbackId?: number): void;\n genericSynchronousFunction(functionId: number, parameters?: string): string;\n getExtensionId(): string;\n registerGenericFunctionCallbackHandler(callbackHandler: any): void;\n registerGenericPersistentCallbackHandler(callbackHandler: any): void;\n}\n\ndeclare var ExtensionScriptApis: {\n prototype: ExtensionScriptApis;\n new(): ExtensionScriptApis;\n}\n\ninterface External {\n}\n\ndeclare var External: {\n prototype: External;\n new(): External;\n}\n\ninterface File extends Blob {\n readonly lastModifiedDate: any;\n readonly name: string;\n readonly webkitRelativePath: string;\n}\n\ndeclare var File: {\n prototype: File;\n new (parts: (ArrayBuffer | ArrayBufferView | Blob | string)[], filename: string, properties?: FilePropertyBag): File;\n}\n\ninterface FileList {\n readonly length: number;\n item(index: number): File;\n [index: number]: File;\n}\n\ndeclare var FileList: {\n prototype: FileList;\n new(): FileList;\n}\n\ninterface FileReader extends EventTarget, MSBaseReader {\n readonly error: DOMError;\n readAsArrayBuffer(blob: Blob): void;\n readAsBinaryString(blob: Blob): void;\n readAsDataURL(blob: Blob): void;\n readAsText(blob: Blob, encoding?: string): void;\n addEventListener(type: K, listener: (this: FileReader, ev: MSBaseReaderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var FileReader: {\n prototype: FileReader;\n new(): FileReader;\n}\n\ninterface FocusEvent extends UIEvent {\n readonly relatedTarget: EventTarget;\n initFocusEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, relatedTargetArg: EventTarget): void;\n}\n\ndeclare var FocusEvent: {\n prototype: FocusEvent;\n new(typeArg: string, eventInitDict?: FocusEventInit): FocusEvent;\n}\n\ninterface FocusNavigationEvent extends Event {\n readonly navigationReason: NavigationReason;\n readonly originHeight: number;\n readonly originLeft: number;\n readonly originTop: number;\n readonly originWidth: number;\n requestFocus(): void;\n}\n\ndeclare var FocusNavigationEvent: {\n prototype: FocusNavigationEvent;\n new(type: string, eventInitDict?: FocusNavigationEventInit): FocusNavigationEvent;\n}\n\ninterface FormData {\n append(name: string, value: string | Blob, fileName?: string): void;\n delete(name: string): void;\n get(name: string): FormDataEntryValue | null;\n getAll(name: string): FormDataEntryValue[];\n has(name: string): boolean;\n set(name: string, value: string | Blob, fileName?: string): void;\n}\n\ndeclare var FormData: {\n prototype: FormData;\n new (form?: HTMLFormElement): FormData;\n}\n\ninterface GainNode extends AudioNode {\n readonly gain: AudioParam;\n}\n\ndeclare var GainNode: {\n prototype: GainNode;\n new(): GainNode;\n}\n\ninterface Gamepad {\n readonly axes: number[];\n readonly buttons: GamepadButton[];\n readonly connected: boolean;\n readonly id: string;\n readonly index: number;\n readonly mapping: string;\n readonly timestamp: number;\n}\n\ndeclare var Gamepad: {\n prototype: Gamepad;\n new(): Gamepad;\n}\n\ninterface GamepadButton {\n readonly pressed: boolean;\n readonly value: number;\n}\n\ndeclare var GamepadButton: {\n prototype: GamepadButton;\n new(): GamepadButton;\n}\n\ninterface GamepadEvent extends Event {\n readonly gamepad: Gamepad;\n}\n\ndeclare var GamepadEvent: {\n prototype: GamepadEvent;\n new(typeArg: string, eventInitDict?: GamepadEventInit): GamepadEvent;\n}\n\ninterface Geolocation {\n clearWatch(watchId: number): void;\n getCurrentPosition(successCallback: PositionCallback, errorCallback?: PositionErrorCallback, options?: PositionOptions): void;\n watchPosition(successCallback: PositionCallback, errorCallback?: PositionErrorCallback, options?: PositionOptions): number;\n}\n\ndeclare var Geolocation: {\n prototype: Geolocation;\n new(): Geolocation;\n}\n\ninterface HTMLAllCollection {\n readonly length: number;\n item(nameOrIndex?: string): HTMLCollection | Element | null;\n namedItem(name: string): HTMLCollection | Element | null;\n [index: number]: Element;\n}\n\ndeclare var HTMLAllCollection: {\n prototype: HTMLAllCollection;\n new(): HTMLAllCollection;\n}\n\ninterface HTMLAnchorElement extends HTMLElement {\n Methods: string;\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n /**\n * Sets or retrieves the coordinates of the object.\n */\n coords: string;\n download: string;\n /**\n * Contains the anchor portion of the URL including the hash sign (#).\n */\n hash: string;\n /**\n * Contains the hostname and port values of the URL.\n */\n host: string;\n /**\n * Contains the hostname of a URL.\n */\n hostname: string;\n /**\n * Sets or retrieves a destination URL or an anchor point.\n */\n href: string;\n /**\n * Sets or retrieves the language code of the object.\n */\n hreflang: string;\n readonly mimeType: string;\n /**\n * Sets or retrieves the shape of the object.\n */\n name: string;\n readonly nameProp: string;\n /**\n * Contains the pathname of the URL.\n */\n pathname: string;\n /**\n * Sets or retrieves the port number associated with a URL.\n */\n port: string;\n /**\n * Contains the protocol of the URL.\n */\n protocol: string;\n readonly protocolLong: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rel: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rev: string;\n /**\n * Sets or retrieves the substring of the href property that follows the question mark.\n */\n search: string;\n /**\n * Sets or retrieves the shape of the object.\n */\n shape: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Retrieves or sets the text of the object as a string. \n */\n text: string;\n type: string;\n urn: string;\n /** \n * Returns a string representation of an object.\n */\n toString(): string;\n addEventListener(type: K, listener: (this: HTMLAnchorElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAnchorElement: {\n prototype: HTMLAnchorElement;\n new(): HTMLAnchorElement;\n}\n\ninterface HTMLAppletElement extends HTMLElement {\n /**\n * Retrieves a string of the URL where the object tag can be found. This is often the href of the document that the object is in, or the value set by a base element.\n */\n readonly BaseHref: string;\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Gets or sets the optional alternative HTML script to execute if the object fails to load.\n */\n altHtml: string;\n /**\n * Sets or retrieves a character string that can be used to implement your own archive functionality for the object.\n */\n archive: string;\n border: string;\n code: string;\n /**\n * Sets or retrieves the URL of the component.\n */\n codeBase: string;\n /**\n * Sets or retrieves the Internet media type for the code associated with the object.\n */\n codeType: string;\n /**\n * Address of a pointer to the document this page or frame contains. If there is no document, then null will be returned.\n */\n readonly contentDocument: Document;\n /**\n * Sets or retrieves the URL that references the data of the object.\n */\n data: string;\n /**\n * Sets or retrieves a character string that can be used to implement your own declare functionality for the object.\n */\n declare: boolean;\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n hspace: number;\n /**\n * Sets or retrieves the shape of the object.\n */\n name: string;\n object: string | null;\n /**\n * Sets or retrieves a message to be displayed while an object is loading.\n */\n standby: string;\n /**\n * Returns the content type of the object.\n */\n type: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n vspace: number;\n width: number;\n addEventListener(type: K, listener: (this: HTMLAppletElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAppletElement: {\n prototype: HTMLAppletElement;\n new(): HTMLAppletElement;\n}\n\ninterface HTMLAreaElement extends HTMLElement {\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Sets or retrieves the coordinates of the object.\n */\n coords: string;\n download: string;\n /**\n * Sets or retrieves the subsection of the href property that follows the number sign (#).\n */\n hash: string;\n /**\n * Sets or retrieves the hostname and port number of the location or URL.\n */\n host: string;\n /**\n * Sets or retrieves the host name part of the location or URL. \n */\n hostname: string;\n /**\n * Sets or retrieves a destination URL or an anchor point.\n */\n href: string;\n /**\n * Sets or gets whether clicks in this region cause action.\n */\n noHref: boolean;\n /**\n * Sets or retrieves the file name or path specified by the object.\n */\n pathname: string;\n /**\n * Sets or retrieves the port number associated with a URL.\n */\n port: string;\n /**\n * Sets or retrieves the protocol portion of a URL.\n */\n protocol: string;\n rel: string;\n /**\n * Sets or retrieves the substring of the href property that follows the question mark.\n */\n search: string;\n /**\n * Sets or retrieves the shape of the object.\n */\n shape: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /** \n * Returns a string representation of an object.\n */\n toString(): string;\n addEventListener(type: K, listener: (this: HTMLAreaElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAreaElement: {\n prototype: HTMLAreaElement;\n new(): HTMLAreaElement;\n}\n\ninterface HTMLAreasCollection extends HTMLCollectionBase {\n}\n\ndeclare var HTMLAreasCollection: {\n prototype: HTMLAreasCollection;\n new(): HTMLAreasCollection;\n}\n\ninterface HTMLAudioElement extends HTMLMediaElement {\n addEventListener(type: K, listener: (this: HTMLAudioElement, ev: HTMLMediaElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAudioElement: {\n prototype: HTMLAudioElement;\n new(): HTMLAudioElement;\n}\n\ninterface HTMLBRElement extends HTMLElement {\n /**\n * Sets or retrieves the side on which floating objects are not to be positioned when any IHTMLBlockElement is inserted into the document.\n */\n clear: string;\n addEventListener(type: K, listener: (this: HTMLBRElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBRElement: {\n prototype: HTMLBRElement;\n new(): HTMLBRElement;\n}\n\ninterface HTMLBaseElement extends HTMLElement {\n /**\n * Gets or sets the baseline URL on which relative links are based.\n */\n href: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n addEventListener(type: K, listener: (this: HTMLBaseElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBaseElement: {\n prototype: HTMLBaseElement;\n new(): HTMLBaseElement;\n}\n\ninterface HTMLBaseFontElement extends HTMLElement, DOML2DeprecatedColorProperty {\n /**\n * Sets or retrieves the current typeface family.\n */\n face: string;\n /**\n * Sets or retrieves the font size of the object.\n */\n size: number;\n addEventListener(type: K, listener: (this: HTMLBaseFontElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBaseFontElement: {\n prototype: HTMLBaseFontElement;\n new(): HTMLBaseFontElement;\n}\n\ninterface HTMLBodyElementEventMap extends HTMLElementEventMap {\n \"afterprint\": Event;\n \"beforeprint\": Event;\n \"beforeunload\": BeforeUnloadEvent;\n \"blur\": FocusEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"hashchange\": HashChangeEvent;\n \"load\": Event;\n \"message\": MessageEvent;\n \"offline\": Event;\n \"online\": Event;\n \"orientationchange\": Event;\n \"pagehide\": PageTransitionEvent;\n \"pageshow\": PageTransitionEvent;\n \"popstate\": PopStateEvent;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"storage\": StorageEvent;\n \"unload\": Event;\n}\n\ninterface HTMLBodyElement extends HTMLElement {\n aLink: any;\n background: string;\n bgColor: any;\n bgProperties: string;\n link: any;\n noWrap: boolean;\n onafterprint: (this: HTMLBodyElement, ev: Event) => any;\n onbeforeprint: (this: HTMLBodyElement, ev: Event) => any;\n onbeforeunload: (this: HTMLBodyElement, ev: BeforeUnloadEvent) => any;\n onblur: (this: HTMLBodyElement, ev: FocusEvent) => any;\n onerror: (this: HTMLBodyElement, ev: ErrorEvent) => any;\n onfocus: (this: HTMLBodyElement, ev: FocusEvent) => any;\n onhashchange: (this: HTMLBodyElement, ev: HashChangeEvent) => any;\n onload: (this: HTMLBodyElement, ev: Event) => any;\n onmessage: (this: HTMLBodyElement, ev: MessageEvent) => any;\n onoffline: (this: HTMLBodyElement, ev: Event) => any;\n ononline: (this: HTMLBodyElement, ev: Event) => any;\n onorientationchange: (this: HTMLBodyElement, ev: Event) => any;\n onpagehide: (this: HTMLBodyElement, ev: PageTransitionEvent) => any;\n onpageshow: (this: HTMLBodyElement, ev: PageTransitionEvent) => any;\n onpopstate: (this: HTMLBodyElement, ev: PopStateEvent) => any;\n onresize: (this: HTMLBodyElement, ev: UIEvent) => any;\n onscroll: (this: HTMLBodyElement, ev: UIEvent) => any;\n onstorage: (this: HTMLBodyElement, ev: StorageEvent) => any;\n onunload: (this: HTMLBodyElement, ev: Event) => any;\n text: any;\n vLink: any;\n addEventListener(type: K, listener: (this: HTMLBodyElement, ev: HTMLBodyElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBodyElement: {\n prototype: HTMLBodyElement;\n new(): HTMLBodyElement;\n}\n\ninterface HTMLButtonElement extends HTMLElement {\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Overrides the action attribute (where the data on a form is sent) on the parent form element.\n */\n formAction: string;\n /**\n * Used to override the encoding (formEnctype attribute) specified on the form element.\n */\n formEnctype: string;\n /**\n * Overrides the submit method attribute previously specified on a form element.\n */\n formMethod: string;\n /**\n * Overrides any validation or required attributes on a form or form elements to allow it to be submitted without validation. This can be used to create a \"save draft\"-type submit option.\n */\n formNoValidate: string;\n /**\n * Overrides the target attribute on a form element.\n */\n formTarget: string;\n /** \n * Sets or retrieves the name of the object.\n */\n name: string;\n status: any;\n /**\n * Gets the classification and default behavior of the button.\n */\n type: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /** \n * Sets or retrieves the default or selected value of the control.\n */\n value: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLButtonElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLButtonElement: {\n prototype: HTMLButtonElement;\n new(): HTMLButtonElement;\n}\n\ninterface HTMLCanvasElement extends HTMLElement {\n /**\n * Gets or sets the height of a canvas element on a document.\n */\n height: number;\n /**\n * Gets or sets the width of a canvas element on a document.\n */\n width: number;\n /**\n * Returns an object that provides methods and properties for drawing and manipulating images and graphics on a canvas element in a document. A context object includes information about colors, line widths, fonts, and other graphic parameters that can be drawn on a canvas.\n * @param contextId The identifier (ID) of the type of canvas to create. Internet Explorer 9 and Internet Explorer 10 support only a 2-D context using canvas.getContext(\"2d\"); IE11 Preview also supports 3-D or WebGL context using canvas.getContext(\"experimental-webgl\");\n */\n getContext(contextId: \"2d\", contextAttributes?: Canvas2DContextAttributes): CanvasRenderingContext2D | null;\n getContext(contextId: \"webgl\" | \"experimental-webgl\", contextAttributes?: WebGLContextAttributes): WebGLRenderingContext | null;\n getContext(contextId: string, contextAttributes?: {}): CanvasRenderingContext2D | WebGLRenderingContext | null;\n /**\n * Returns a blob object encoded as a Portable Network Graphics (PNG) format from a canvas image or drawing.\n */\n msToBlob(): Blob;\n /**\n * Returns the content of the current canvas as an image that you can use as a source for another canvas or an HTML element.\n * @param type The standard MIME type for the image format to return. If you do not specify this parameter, the default value is a PNG format image.\n */\n toDataURL(type?: string, ...args: any[]): string;\n toBlob(callback: (result: Blob | null) => void, type?: string, ...arguments: any[]): void;\n addEventListener(type: K, listener: (this: HTMLCanvasElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLCanvasElement: {\n prototype: HTMLCanvasElement;\n new(): HTMLCanvasElement;\n}\n\ninterface HTMLCollectionBase {\n /**\n * Sets or retrieves the number of objects in a collection.\n */\n readonly length: number;\n /**\n * Retrieves an object from various collections.\n */\n item(index: number): Element;\n [index: number]: Element;\n}\n\ninterface HTMLCollection extends HTMLCollectionBase {\n /**\n * Retrieves a select object or an object from an options collection.\n */\n namedItem(name: string): Element | null;\n}\n\ndeclare var HTMLCollection: {\n prototype: HTMLCollection;\n new(): HTMLCollection;\n}\n\ninterface HTMLDListElement extends HTMLElement {\n compact: boolean;\n addEventListener(type: K, listener: (this: HTMLDListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDListElement: {\n prototype: HTMLDListElement;\n new(): HTMLDListElement;\n}\n\ninterface HTMLDataElement extends HTMLElement {\n value: string;\n addEventListener(type: K, listener: (this: HTMLDataElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDataElement: {\n prototype: HTMLDataElement;\n new(): HTMLDataElement;\n}\n\ninterface HTMLDataListElement extends HTMLElement {\n options: HTMLCollectionOf;\n addEventListener(type: K, listener: (this: HTMLDataListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDataListElement: {\n prototype: HTMLDataListElement;\n new(): HTMLDataListElement;\n}\n\ninterface HTMLDirectoryElement extends HTMLElement {\n compact: boolean;\n addEventListener(type: K, listener: (this: HTMLDirectoryElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDirectoryElement: {\n prototype: HTMLDirectoryElement;\n new(): HTMLDirectoryElement;\n}\n\ninterface HTMLDivElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text. \n */\n align: string;\n /**\n * Sets or retrieves whether the browser automatically performs wordwrap.\n */\n noWrap: boolean;\n addEventListener(type: K, listener: (this: HTMLDivElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDivElement: {\n prototype: HTMLDivElement;\n new(): HTMLDivElement;\n}\n\ninterface HTMLDocument extends Document {\n addEventListener(type: K, listener: (this: HTMLDocument, ev: DocumentEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDocument: {\n prototype: HTMLDocument;\n new(): HTMLDocument;\n}\n\ninterface HTMLElementEventMap extends ElementEventMap {\n \"abort\": UIEvent;\n \"activate\": UIEvent;\n \"beforeactivate\": UIEvent;\n \"beforecopy\": ClipboardEvent;\n \"beforecut\": ClipboardEvent;\n \"beforedeactivate\": UIEvent;\n \"beforepaste\": ClipboardEvent;\n \"blur\": FocusEvent;\n \"canplay\": Event;\n \"canplaythrough\": Event;\n \"change\": Event;\n \"click\": MouseEvent;\n \"contextmenu\": PointerEvent;\n \"copy\": ClipboardEvent;\n \"cuechange\": Event;\n \"cut\": ClipboardEvent;\n \"dblclick\": MouseEvent;\n \"deactivate\": UIEvent;\n \"drag\": DragEvent;\n \"dragend\": DragEvent;\n \"dragenter\": DragEvent;\n \"dragleave\": DragEvent;\n \"dragover\": DragEvent;\n \"dragstart\": DragEvent;\n \"drop\": DragEvent;\n \"durationchange\": Event;\n \"emptied\": Event;\n \"ended\": MediaStreamErrorEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"input\": Event;\n \"invalid\": Event;\n \"keydown\": KeyboardEvent;\n \"keypress\": KeyboardEvent;\n \"keyup\": KeyboardEvent;\n \"load\": Event;\n \"loadeddata\": Event;\n \"loadedmetadata\": Event;\n \"loadstart\": Event;\n \"mousedown\": MouseEvent;\n \"mouseenter\": MouseEvent;\n \"mouseleave\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n \"mousewheel\": WheelEvent;\n \"MSContentZoom\": UIEvent;\n \"MSManipulationStateChanged\": MSManipulationEvent;\n \"paste\": ClipboardEvent;\n \"pause\": Event;\n \"play\": Event;\n \"playing\": Event;\n \"progress\": ProgressEvent;\n \"ratechange\": Event;\n \"reset\": Event;\n \"scroll\": UIEvent;\n \"seeked\": Event;\n \"seeking\": Event;\n \"select\": UIEvent;\n \"selectstart\": Event;\n \"stalled\": Event;\n \"submit\": Event;\n \"suspend\": Event;\n \"timeupdate\": Event;\n \"volumechange\": Event;\n \"waiting\": Event;\n}\n\ninterface HTMLElement extends Element {\n accessKey: string;\n readonly children: HTMLCollection;\n contentEditable: string;\n readonly dataset: DOMStringMap;\n dir: string;\n draggable: boolean;\n hidden: boolean;\n hideFocus: boolean;\n innerText: string;\n readonly isContentEditable: boolean;\n lang: string;\n readonly offsetHeight: number;\n readonly offsetLeft: number;\n readonly offsetParent: Element;\n readonly offsetTop: number;\n readonly offsetWidth: number;\n onabort: (this: HTMLElement, ev: UIEvent) => any;\n onactivate: (this: HTMLElement, ev: UIEvent) => any;\n onbeforeactivate: (this: HTMLElement, ev: UIEvent) => any;\n onbeforecopy: (this: HTMLElement, ev: ClipboardEvent) => any;\n onbeforecut: (this: HTMLElement, ev: ClipboardEvent) => any;\n onbeforedeactivate: (this: HTMLElement, ev: UIEvent) => any;\n onbeforepaste: (this: HTMLElement, ev: ClipboardEvent) => any;\n onblur: (this: HTMLElement, ev: FocusEvent) => any;\n oncanplay: (this: HTMLElement, ev: Event) => any;\n oncanplaythrough: (this: HTMLElement, ev: Event) => any;\n onchange: (this: HTMLElement, ev: Event) => any;\n onclick: (this: HTMLElement, ev: MouseEvent) => any;\n oncontextmenu: (this: HTMLElement, ev: PointerEvent) => any;\n oncopy: (this: HTMLElement, ev: ClipboardEvent) => any;\n oncuechange: (this: HTMLElement, ev: Event) => any;\n oncut: (this: HTMLElement, ev: ClipboardEvent) => any;\n ondblclick: (this: HTMLElement, ev: MouseEvent) => any;\n ondeactivate: (this: HTMLElement, ev: UIEvent) => any;\n ondrag: (this: HTMLElement, ev: DragEvent) => any;\n ondragend: (this: HTMLElement, ev: DragEvent) => any;\n ondragenter: (this: HTMLElement, ev: DragEvent) => any;\n ondragleave: (this: HTMLElement, ev: DragEvent) => any;\n ondragover: (this: HTMLElement, ev: DragEvent) => any;\n ondragstart: (this: HTMLElement, ev: DragEvent) => any;\n ondrop: (this: HTMLElement, ev: DragEvent) => any;\n ondurationchange: (this: HTMLElement, ev: Event) => any;\n onemptied: (this: HTMLElement, ev: Event) => any;\n onended: (this: HTMLElement, ev: MediaStreamErrorEvent) => any;\n onerror: (this: HTMLElement, ev: ErrorEvent) => any;\n onfocus: (this: HTMLElement, ev: FocusEvent) => any;\n oninput: (this: HTMLElement, ev: Event) => any;\n oninvalid: (this: HTMLElement, ev: Event) => any;\n onkeydown: (this: HTMLElement, ev: KeyboardEvent) => any;\n onkeypress: (this: HTMLElement, ev: KeyboardEvent) => any;\n onkeyup: (this: HTMLElement, ev: KeyboardEvent) => any;\n onload: (this: HTMLElement, ev: Event) => any;\n onloadeddata: (this: HTMLElement, ev: Event) => any;\n onloadedmetadata: (this: HTMLElement, ev: Event) => any;\n onloadstart: (this: HTMLElement, ev: Event) => any;\n onmousedown: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseenter: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseleave: (this: HTMLElement, ev: MouseEvent) => any;\n onmousemove: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseout: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseover: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseup: (this: HTMLElement, ev: MouseEvent) => any;\n onmousewheel: (this: HTMLElement, ev: WheelEvent) => any;\n onmscontentzoom: (this: HTMLElement, ev: UIEvent) => any;\n onmsmanipulationstatechanged: (this: HTMLElement, ev: MSManipulationEvent) => any;\n onpaste: (this: HTMLElement, ev: ClipboardEvent) => any;\n onpause: (this: HTMLElement, ev: Event) => any;\n onplay: (this: HTMLElement, ev: Event) => any;\n onplaying: (this: HTMLElement, ev: Event) => any;\n onprogress: (this: HTMLElement, ev: ProgressEvent) => any;\n onratechange: (this: HTMLElement, ev: Event) => any;\n onreset: (this: HTMLElement, ev: Event) => any;\n onscroll: (this: HTMLElement, ev: UIEvent) => any;\n onseeked: (this: HTMLElement, ev: Event) => any;\n onseeking: (this: HTMLElement, ev: Event) => any;\n onselect: (this: HTMLElement, ev: UIEvent) => any;\n onselectstart: (this: HTMLElement, ev: Event) => any;\n onstalled: (this: HTMLElement, ev: Event) => any;\n onsubmit: (this: HTMLElement, ev: Event) => any;\n onsuspend: (this: HTMLElement, ev: Event) => any;\n ontimeupdate: (this: HTMLElement, ev: Event) => any;\n onvolumechange: (this: HTMLElement, ev: Event) => any;\n onwaiting: (this: HTMLElement, ev: Event) => any;\n outerText: string;\n spellcheck: boolean;\n readonly style: CSSStyleDeclaration;\n tabIndex: number;\n title: string;\n blur(): void;\n click(): void;\n dragDrop(): boolean;\n focus(): void;\n msGetInputContext(): MSInputMethodContext;\n addEventListener(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLElement: {\n prototype: HTMLElement;\n new(): HTMLElement;\n}\n\ninterface HTMLEmbedElement extends HTMLElement, GetSVGDocument {\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n hidden: any;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n /**\n * Gets or sets the path to the preferred media source. This enables the Play To target device to stream the media content, which can be DRM protected, from a different location, such as a cloud media server.\n */\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Retrieves the palette used for the embedded document.\n */\n readonly palette: string;\n /**\n * Retrieves the URL of the plug-in used to view an embedded document.\n */\n readonly pluginspage: string;\n readonly readyState: string;\n /**\n * Sets or retrieves a URL to be loaded by the object.\n */\n src: string;\n /**\n * Sets or retrieves the height and width units of the embed object.\n */\n units: string;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n addEventListener(type: K, listener: (this: HTMLEmbedElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLEmbedElement: {\n prototype: HTMLEmbedElement;\n new(): HTMLEmbedElement;\n}\n\ninterface HTMLFieldSetElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n name: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLFieldSetElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFieldSetElement: {\n prototype: HTMLFieldSetElement;\n new(): HTMLFieldSetElement;\n}\n\ninterface HTMLFontElement extends HTMLElement, DOML2DeprecatedColorProperty, DOML2DeprecatedSizeProperty {\n /**\n * Sets or retrieves the current typeface family.\n */\n face: string;\n addEventListener(type: K, listener: (this: HTMLFontElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFontElement: {\n prototype: HTMLFontElement;\n new(): HTMLFontElement;\n}\n\ninterface HTMLFormControlsCollection extends HTMLCollectionBase {\n namedItem(name: string): HTMLCollection | Element | null;\n}\n\ndeclare var HTMLFormControlsCollection: {\n prototype: HTMLFormControlsCollection;\n new(): HTMLFormControlsCollection;\n}\n\ninterface HTMLFormElement extends HTMLElement {\n /**\n * Sets or retrieves a list of character encodings for input data that must be accepted by the server processing the form.\n */\n acceptCharset: string;\n /**\n * Sets or retrieves the URL to which the form content is sent for processing.\n */\n action: string;\n /**\n * Specifies whether autocomplete is applied to an editable text field.\n */\n autocomplete: string;\n /**\n * Retrieves a collection, in source order, of all controls in a given form.\n */\n readonly elements: HTMLFormControlsCollection;\n /**\n * Sets or retrieves the MIME encoding for the form.\n */\n encoding: string;\n /**\n * Sets or retrieves the encoding type for the form.\n */\n enctype: string;\n /**\n * Sets or retrieves the number of objects in a collection.\n */\n readonly length: number;\n /**\n * Sets or retrieves how to send the form data to the server.\n */\n method: string;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Designates a form that is not validated when submitted.\n */\n noValidate: boolean;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Retrieves a form object or an object from an elements collection.\n * @param name Variant of type Number or String that specifies the object or collection to retrieve. If this parameter is a Number, it is the zero-based index of the object. If this parameter is a string, all objects with matching name or id properties are retrieved, and a collection is returned if more than one match is made.\n * @param index Variant of type Number that specifies the zero-based index of the object to retrieve when a collection is returned.\n */\n item(name?: any, index?: any): any;\n /**\n * Retrieves a form object or an object from an elements collection.\n */\n namedItem(name: string): any;\n /**\n * Fires when the user resets a form.\n */\n reset(): void;\n /**\n * Fires when a FORM is about to be submitted.\n */\n submit(): void;\n addEventListener(type: K, listener: (this: HTMLFormElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [name: string]: any;\n}\n\ndeclare var HTMLFormElement: {\n prototype: HTMLFormElement;\n new(): HTMLFormElement;\n}\n\ninterface HTMLFrameElementEventMap extends HTMLElementEventMap {\n \"load\": Event;\n}\n\ninterface HTMLFrameElement extends HTMLElement, GetSVGDocument {\n /**\n * Specifies the properties of a border drawn around an object.\n */\n border: string;\n /**\n * Sets or retrieves the border color of the object.\n */\n borderColor: any;\n /**\n * Retrieves the document object of the page or frame.\n */\n readonly contentDocument: Document;\n /**\n * Retrieves the object of the specified.\n */\n readonly contentWindow: Window;\n /**\n * Sets or retrieves whether to display a border for the frame.\n */\n frameBorder: string;\n /**\n * Sets or retrieves the amount of additional space between the frames.\n */\n frameSpacing: any;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string | number;\n /**\n * Sets or retrieves a URI to a long description of the object.\n */\n longDesc: string;\n /**\n * Sets or retrieves the top and bottom margin heights before displaying the text in a frame.\n */\n marginHeight: string;\n /**\n * Sets or retrieves the left and right margin widths before displaying the text in a frame.\n */\n marginWidth: string;\n /**\n * Sets or retrieves the frame name.\n */\n name: string;\n /**\n * Sets or retrieves whether the user can resize the frame.\n */\n noResize: boolean;\n /**\n * Raised when the object has been completely received from the server.\n */\n onload: (this: HTMLFrameElement, ev: Event) => any;\n /**\n * Sets or retrieves whether the frame can be scrolled.\n */\n scrolling: string;\n /**\n * Sets or retrieves a URL to be loaded by the object.\n */\n src: string;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string | number;\n addEventListener(type: K, listener: (this: HTMLFrameElement, ev: HTMLFrameElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFrameElement: {\n prototype: HTMLFrameElement;\n new(): HTMLFrameElement;\n}\n\ninterface HTMLFrameSetElementEventMap extends HTMLElementEventMap {\n \"afterprint\": Event;\n \"beforeprint\": Event;\n \"beforeunload\": BeforeUnloadEvent;\n \"blur\": FocusEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"hashchange\": HashChangeEvent;\n \"load\": Event;\n \"message\": MessageEvent;\n \"offline\": Event;\n \"online\": Event;\n \"orientationchange\": Event;\n \"pagehide\": PageTransitionEvent;\n \"pageshow\": PageTransitionEvent;\n \"popstate\": PopStateEvent;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"storage\": StorageEvent;\n \"unload\": Event;\n}\n\ninterface HTMLFrameSetElement extends HTMLElement {\n border: string;\n /**\n * Sets or retrieves the border color of the object.\n */\n borderColor: any;\n /**\n * Sets or retrieves the frame widths of the object.\n */\n cols: string;\n /**\n * Sets or retrieves whether to display a border for the frame.\n */\n frameBorder: string;\n /**\n * Sets or retrieves the amount of additional space between the frames.\n */\n frameSpacing: any;\n name: string;\n onafterprint: (this: HTMLFrameSetElement, ev: Event) => any;\n onbeforeprint: (this: HTMLFrameSetElement, ev: Event) => any;\n onbeforeunload: (this: HTMLFrameSetElement, ev: BeforeUnloadEvent) => any;\n /**\n * Fires when the object loses the input focus.\n */\n onblur: (this: HTMLFrameSetElement, ev: FocusEvent) => any;\n onerror: (this: HTMLFrameSetElement, ev: ErrorEvent) => any;\n /**\n * Fires when the object receives focus.\n */\n onfocus: (this: HTMLFrameSetElement, ev: FocusEvent) => any;\n onhashchange: (this: HTMLFrameSetElement, ev: HashChangeEvent) => any;\n onload: (this: HTMLFrameSetElement, ev: Event) => any;\n onmessage: (this: HTMLFrameSetElement, ev: MessageEvent) => any;\n onoffline: (this: HTMLFrameSetElement, ev: Event) => any;\n ononline: (this: HTMLFrameSetElement, ev: Event) => any;\n onorientationchange: (this: HTMLFrameSetElement, ev: Event) => any;\n onpagehide: (this: HTMLFrameSetElement, ev: PageTransitionEvent) => any;\n onpageshow: (this: HTMLFrameSetElement, ev: PageTransitionEvent) => any;\n onpopstate: (this: HTMLFrameSetElement, ev: PopStateEvent) => any;\n onresize: (this: HTMLFrameSetElement, ev: UIEvent) => any;\n onscroll: (this: HTMLFrameSetElement, ev: UIEvent) => any;\n onstorage: (this: HTMLFrameSetElement, ev: StorageEvent) => any;\n onunload: (this: HTMLFrameSetElement, ev: Event) => any;\n /**\n * Sets or retrieves the frame heights of the object.\n */\n rows: string;\n addEventListener(type: K, listener: (this: HTMLFrameSetElement, ev: HTMLFrameSetElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFrameSetElement: {\n prototype: HTMLFrameSetElement;\n new(): HTMLFrameSetElement;\n}\n\ninterface HTMLHRElement extends HTMLElement, DOML2DeprecatedColorProperty, DOML2DeprecatedSizeProperty {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves whether the horizontal rule is drawn with 3-D shading.\n */\n noShade: boolean;\n /**\n * Sets or retrieves the width of the object.\n */\n width: number;\n addEventListener(type: K, listener: (this: HTMLHRElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHRElement: {\n prototype: HTMLHRElement;\n new(): HTMLHRElement;\n}\n\ninterface HTMLHeadElement extends HTMLElement {\n profile: string;\n addEventListener(type: K, listener: (this: HTMLHeadElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHeadElement: {\n prototype: HTMLHeadElement;\n new(): HTMLHeadElement;\n}\n\ninterface HTMLHeadingElement extends HTMLElement {\n /**\n * Sets or retrieves a value that indicates the table alignment.\n */\n align: string;\n addEventListener(type: K, listener: (this: HTMLHeadingElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHeadingElement: {\n prototype: HTMLHeadingElement;\n new(): HTMLHeadingElement;\n}\n\ninterface HTMLHtmlElement extends HTMLElement {\n /**\n * Sets or retrieves the DTD version that governs the current document.\n */\n version: string;\n addEventListener(type: K, listener: (this: HTMLHtmlElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHtmlElement: {\n prototype: HTMLHtmlElement;\n new(): HTMLHtmlElement;\n}\n\ninterface HTMLIFrameElementEventMap extends HTMLElementEventMap {\n \"load\": Event;\n}\n\ninterface HTMLIFrameElement extends HTMLElement, GetSVGDocument {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n allowFullscreen: boolean;\n allowPaymentRequest: boolean;\n /**\n * Specifies the properties of a border drawn around an object.\n */\n border: string;\n /**\n * Retrieves the document object of the page or frame.\n */\n readonly contentDocument: Document;\n /**\n * Retrieves the object of the specified.\n */\n readonly contentWindow: Window;\n /**\n * Sets or retrieves whether to display a border for the frame.\n */\n frameBorder: string;\n /**\n * Sets or retrieves the amount of additional space between the frames.\n */\n frameSpacing: any;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n /**\n * Sets or retrieves the horizontal margin for the object.\n */\n hspace: number;\n /**\n * Sets or retrieves a URI to a long description of the object.\n */\n longDesc: string;\n /**\n * Sets or retrieves the top and bottom margin heights before displaying the text in a frame.\n */\n marginHeight: string;\n /**\n * Sets or retrieves the left and right margin widths before displaying the text in a frame.\n */\n marginWidth: string;\n /**\n * Sets or retrieves the frame name.\n */\n name: string;\n /**\n * Sets or retrieves whether the user can resize the frame.\n */\n noResize: boolean;\n /**\n * Raised when the object has been completely received from the server.\n */\n onload: (this: HTMLIFrameElement, ev: Event) => any;\n readonly sandbox: DOMSettableTokenList;\n /**\n * Sets or retrieves whether the frame can be scrolled.\n */\n scrolling: string;\n /**\n * Sets or retrieves a URL to be loaded by the object.\n */\n src: string;\n /**\n * Sets or retrieves the vertical margin for the object.\n */\n vspace: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n addEventListener(type: K, listener: (this: HTMLIFrameElement, ev: HTMLIFrameElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLIFrameElement: {\n prototype: HTMLIFrameElement;\n new(): HTMLIFrameElement;\n}\n\ninterface HTMLImageElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Specifies the properties of a border drawn around an object.\n */\n border: string;\n /**\n * Retrieves whether the object is fully loaded.\n */\n readonly complete: boolean;\n crossOrigin: string | null;\n readonly currentSrc: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: number;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n hspace: number;\n /**\n * Sets or retrieves whether the image is a server-side image map.\n */\n isMap: boolean;\n /**\n * Sets or retrieves a Uniform Resource Identifier (URI) to a long description of the object.\n */\n longDesc: string;\n lowsrc: string;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * The original height of the image resource before sizing.\n */\n readonly naturalHeight: number;\n /**\n * The original width of the image resource before sizing.\n */\n readonly naturalWidth: number;\n sizes: string;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n srcset: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n /**\n * Sets or retrieves the vertical margin for the object.\n */\n vspace: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: number;\n readonly x: number;\n readonly y: number;\n msGetAsCastingSource(): any;\n addEventListener(type: K, listener: (this: HTMLImageElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLImageElement: {\n prototype: HTMLImageElement;\n new(): HTMLImageElement;\n}\n\ninterface HTMLInputElement extends HTMLElement {\n /**\n * Sets or retrieves a comma-separated list of content types.\n */\n accept: string;\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Specifies whether autocomplete is applied to an editable text field.\n */\n autocomplete: string;\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n border: string;\n /**\n * Sets or retrieves the state of the check box or radio button.\n */\n checked: boolean;\n /**\n * Retrieves whether the object is fully loaded.\n */\n readonly complete: boolean;\n /**\n * Sets or retrieves the state of the check box or radio button.\n */\n defaultChecked: boolean;\n /**\n * Sets or retrieves the initial contents of the object.\n */\n defaultValue: string;\n disabled: boolean;\n /**\n * Returns a FileList object on a file type input object.\n */\n readonly files: FileList | null;\n /**\n * Retrieves a reference to the form that the object is embedded in. \n */\n readonly form: HTMLFormElement;\n /**\n * Overrides the action attribute (where the data on a form is sent) on the parent form element.\n */\n formAction: string;\n /**\n * Used to override the encoding (formEnctype attribute) specified on the form element.\n */\n formEnctype: string;\n /**\n * Overrides the submit method attribute previously specified on a form element.\n */\n formMethod: string;\n /**\n * Overrides any validation or required attributes on a form or form elements to allow it to be submitted without validation. This can be used to create a \"save draft\"-type submit option.\n */\n formNoValidate: string;\n /**\n * Overrides the target attribute on a form element.\n */\n formTarget: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n hspace: number;\n indeterminate: boolean;\n /**\n * Specifies the ID of a pre-defined datalist of options for an input element.\n */\n readonly list: HTMLElement;\n /**\n * Defines the maximum acceptable value for an input element with type=\"number\".When used with the min and step attributes, lets you control the range and increment (such as only even numbers) that the user can enter into an input field.\n */\n max: string;\n /**\n * Sets or retrieves the maximum number of characters that the user can enter in a text control.\n */\n maxLength: number;\n /**\n * Defines the minimum acceptable value for an input element with type=\"number\". When used with the max and step attributes, lets you control the range and increment (such as even numbers only) that the user can enter into an input field.\n */\n min: string;\n /**\n * Sets or retrieves the Boolean value indicating whether multiple items can be selected from a list.\n */\n multiple: boolean;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Gets or sets a string containing a regular expression that the user's input must match.\n */\n pattern: string;\n /**\n * Gets or sets a text string that is displayed in an input field as a hint or prompt to users as the format or type of information they need to enter.The text appears in an input field until the user puts focus on the field.\n */\n placeholder: string;\n readOnly: boolean;\n /**\n * When present, marks an element that can't be submitted without a value.\n */\n required: boolean;\n selectionDirection: string;\n /**\n * Gets or sets the end position or offset of a text selection.\n */\n selectionEnd: number;\n /**\n * Gets or sets the starting position or offset of a text selection.\n */\n selectionStart: number;\n size: number;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n status: boolean;\n /**\n * Defines an increment or jump between values that you want to allow the user to enter. When used with the max and min attributes, lets you control the range and increment (for example, allow only even numbers) that the user can enter into an input field.\n */\n step: string;\n /**\n * Returns the content type of the object.\n */\n type: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Returns the value of the data at the cursor's current position.\n */\n value: string;\n valueAsDate: Date;\n /**\n * Returns the input field value as a number.\n */\n valueAsNumber: number;\n /**\n * Sets or retrieves the vertical margin for the object.\n */\n vspace: number;\n webkitdirectory: boolean;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n minLength: number;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Makes the selection equal to the current object.\n */\n select(): void;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n /**\n * Sets the start and end positions of a selection in a text field.\n * @param start The offset into the text field for the start of the selection.\n * @param end The offset into the text field for the end of the selection.\n */\n setSelectionRange(start?: number, end?: number, direction?: string): void;\n /**\n * Decrements a range input control's value by the value given by the Step attribute. If the optional parameter is used, it will decrement the input control's step value multiplied by the parameter's value.\n * @param n Value to decrement the value by.\n */\n stepDown(n?: number): void;\n /**\n * Increments a range input control's value by the value given by the Step attribute. If the optional parameter is used, will increment the input control's value by that value.\n * @param n Value to increment the value by.\n */\n stepUp(n?: number): void;\n addEventListener(type: K, listener: (this: HTMLInputElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLInputElement: {\n prototype: HTMLInputElement;\n new(): HTMLInputElement;\n}\n\ninterface HTMLLIElement extends HTMLElement {\n type: string;\n /**\n * Sets or retrieves the value of a list item.\n */\n value: number;\n addEventListener(type: K, listener: (this: HTMLLIElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLIElement: {\n prototype: HTMLLIElement;\n new(): HTMLLIElement;\n}\n\ninterface HTMLLabelElement extends HTMLElement {\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the object to which the given label object is assigned.\n */\n htmlFor: string;\n addEventListener(type: K, listener: (this: HTMLLabelElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLabelElement: {\n prototype: HTMLLabelElement;\n new(): HTMLLabelElement;\n}\n\ninterface HTMLLegendElement extends HTMLElement {\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n align: string;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n addEventListener(type: K, listener: (this: HTMLLegendElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLegendElement: {\n prototype: HTMLLegendElement;\n new(): HTMLLegendElement;\n}\n\ninterface HTMLLinkElement extends HTMLElement, LinkStyle {\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n disabled: boolean;\n /**\n * Sets or retrieves a destination URL or an anchor point.\n */\n href: string;\n /**\n * Sets or retrieves the language code of the object.\n */\n hreflang: string;\n /**\n * Sets or retrieves the media type.\n */\n media: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rel: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rev: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Sets or retrieves the MIME type of the object.\n */\n type: string;\n import?: Document;\n integrity: string;\n addEventListener(type: K, listener: (this: HTMLLinkElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLinkElement: {\n prototype: HTMLLinkElement;\n new(): HTMLLinkElement;\n}\n\ninterface HTMLMapElement extends HTMLElement {\n /**\n * Retrieves a collection of the area objects defined for the given map object.\n */\n readonly areas: HTMLAreasCollection;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n addEventListener(type: K, listener: (this: HTMLMapElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMapElement: {\n prototype: HTMLMapElement;\n new(): HTMLMapElement;\n}\n\ninterface HTMLMarqueeElementEventMap extends HTMLElementEventMap {\n \"bounce\": Event;\n \"finish\": Event;\n \"start\": Event;\n}\n\ninterface HTMLMarqueeElement extends HTMLElement {\n behavior: string;\n bgColor: any;\n direction: string;\n height: string;\n hspace: number;\n loop: number;\n onbounce: (this: HTMLMarqueeElement, ev: Event) => any;\n onfinish: (this: HTMLMarqueeElement, ev: Event) => any;\n onstart: (this: HTMLMarqueeElement, ev: Event) => any;\n scrollAmount: number;\n scrollDelay: number;\n trueSpeed: boolean;\n vspace: number;\n width: string;\n start(): void;\n stop(): void;\n addEventListener(type: K, listener: (this: HTMLMarqueeElement, ev: HTMLMarqueeElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMarqueeElement: {\n prototype: HTMLMarqueeElement;\n new(): HTMLMarqueeElement;\n}\n\ninterface HTMLMediaElementEventMap extends HTMLElementEventMap {\n \"encrypted\": MediaEncryptedEvent;\n \"msneedkey\": MSMediaKeyNeededEvent;\n}\n\ninterface HTMLMediaElement extends HTMLElement {\n /**\n * Returns an AudioTrackList object with the audio tracks for a given video element.\n */\n readonly audioTracks: AudioTrackList;\n /**\n * Gets or sets a value that indicates whether to start playing the media automatically.\n */\n autoplay: boolean;\n /**\n * Gets a collection of buffered time ranges.\n */\n readonly buffered: TimeRanges;\n /**\n * Gets or sets a flag that indicates whether the client provides a set of controls for the media (in case the developer does not include controls for the player).\n */\n controls: boolean;\n crossOrigin: string | null;\n /**\n * Gets the address or URL of the current media resource that is selected by IHTMLMediaElement.\n */\n readonly currentSrc: string;\n /**\n * Gets or sets the current playback position, in seconds.\n */\n currentTime: number;\n defaultMuted: boolean;\n /**\n * Gets or sets the default playback rate when the user is not using fast forward or reverse for a video or audio resource.\n */\n defaultPlaybackRate: number;\n /**\n * Returns the duration in seconds of the current media resource. A NaN value is returned if duration is not available, or Infinity if the media resource is streaming.\n */\n readonly duration: number;\n /**\n * Gets information about whether the playback has ended or not.\n */\n readonly ended: boolean;\n /**\n * Returns an object representing the current error state of the audio or video element.\n */\n readonly error: MediaError;\n /**\n * Gets or sets a flag to specify whether playback should restart after it completes.\n */\n loop: boolean;\n readonly mediaKeys: MediaKeys | null;\n /**\n * Specifies the purpose of the audio or video media, such as background audio or alerts.\n */\n msAudioCategory: string;\n /**\n * Specifies the output device id that the audio will be sent to.\n */\n msAudioDeviceType: string;\n readonly msGraphicsTrustStatus: MSGraphicsTrust;\n /**\n * Gets the MSMediaKeys object, which is used for decrypting media data, that is associated with this media element.\n */\n readonly msKeys: MSMediaKeys;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n /**\n * Gets or sets the path to the preferred media source. This enables the Play To target device to stream the media content, which can be DRM protected, from a different location, such as a cloud media server.\n */\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Specifies whether or not to enable low-latency playback on the media element.\n */\n msRealTime: boolean;\n /**\n * Gets or sets a flag that indicates whether the audio (either audio or the audio track on video media) is muted.\n */\n muted: boolean;\n /**\n * Gets the current network activity for the element.\n */\n readonly networkState: number;\n onencrypted: (this: HTMLMediaElement, ev: MediaEncryptedEvent) => any;\n onmsneedkey: (this: HTMLMediaElement, ev: MSMediaKeyNeededEvent) => any;\n /**\n * Gets a flag that specifies whether playback is paused.\n */\n readonly paused: boolean;\n /**\n * Gets or sets the current rate of speed for the media resource to play. This speed is expressed as a multiple of the normal speed of the media resource.\n */\n playbackRate: number;\n /**\n * Gets TimeRanges for the current media resource that has been played.\n */\n readonly played: TimeRanges;\n /**\n * Gets or sets the current playback position, in seconds.\n */\n preload: string;\n readyState: number;\n /**\n * Returns a TimeRanges object that represents the ranges of the current media resource that can be seeked.\n */\n readonly seekable: TimeRanges;\n /**\n * Gets a flag that indicates whether the the client is currently moving to a new playback position in the media resource.\n */\n readonly seeking: boolean;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n srcObject: MediaStream | null;\n readonly textTracks: TextTrackList;\n readonly videoTracks: VideoTrackList;\n /**\n * Gets or sets the volume level for audio portions of the media element.\n */\n volume: number;\n addTextTrack(kind: string, label?: string, language?: string): TextTrack;\n /**\n * Returns a string that specifies whether the client can play a given media resource type.\n */\n canPlayType(type: string): string;\n /**\n * Resets the audio or video object and loads a new media resource.\n */\n load(): void;\n /**\n * Clears all effects from the media pipeline.\n */\n msClearEffects(): void;\n msGetAsCastingSource(): any;\n /**\n * Inserts the specified audio effect into media pipeline.\n */\n msInsertAudioEffect(activatableClassId: string, effectRequired: boolean, config?: any): void;\n msSetMediaKeys(mediaKeys: MSMediaKeys): void;\n /**\n * Specifies the media protection manager for a given media pipeline.\n */\n msSetMediaProtectionManager(mediaProtectionManager?: any): void;\n /**\n * Pauses the current playback and sets paused to TRUE. This can be used to test whether the media is playing or paused. You can also use the pause or play events to tell whether the media is playing or not.\n */\n pause(): void;\n /**\n * Loads and starts playback of a media resource.\n */\n play(): void;\n setMediaKeys(mediaKeys: MediaKeys | null): Promise;\n readonly HAVE_CURRENT_DATA: number;\n readonly HAVE_ENOUGH_DATA: number;\n readonly HAVE_FUTURE_DATA: number;\n readonly HAVE_METADATA: number;\n readonly HAVE_NOTHING: number;\n readonly NETWORK_EMPTY: number;\n readonly NETWORK_IDLE: number;\n readonly NETWORK_LOADING: number;\n readonly NETWORK_NO_SOURCE: number;\n addEventListener(type: K, listener: (this: HTMLMediaElement, ev: HTMLMediaElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMediaElement: {\n prototype: HTMLMediaElement;\n new(): HTMLMediaElement;\n readonly HAVE_CURRENT_DATA: number;\n readonly HAVE_ENOUGH_DATA: number;\n readonly HAVE_FUTURE_DATA: number;\n readonly HAVE_METADATA: number;\n readonly HAVE_NOTHING: number;\n readonly NETWORK_EMPTY: number;\n readonly NETWORK_IDLE: number;\n readonly NETWORK_LOADING: number;\n readonly NETWORK_NO_SOURCE: number;\n}\n\ninterface HTMLMenuElement extends HTMLElement {\n compact: boolean;\n type: string;\n addEventListener(type: K, listener: (this: HTMLMenuElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMenuElement: {\n prototype: HTMLMenuElement;\n new(): HTMLMenuElement;\n}\n\ninterface HTMLMetaElement extends HTMLElement {\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n /**\n * Gets or sets meta-information to associate with httpEquiv or name.\n */\n content: string;\n /**\n * Gets or sets information used to bind the value of a content attribute of a meta element to an HTTP response header.\n */\n httpEquiv: string;\n /**\n * Sets or retrieves the value specified in the content attribute of the meta object.\n */\n name: string;\n /**\n * Sets or retrieves a scheme to be used in interpreting the value of a property specified for the object.\n */\n scheme: string;\n /**\n * Sets or retrieves the URL property that will be loaded after the specified time has elapsed. \n */\n url: string;\n addEventListener(type: K, listener: (this: HTMLMetaElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMetaElement: {\n prototype: HTMLMetaElement;\n new(): HTMLMetaElement;\n}\n\ninterface HTMLMeterElement extends HTMLElement {\n high: number;\n low: number;\n max: number;\n min: number;\n optimum: number;\n value: number;\n addEventListener(type: K, listener: (this: HTMLMeterElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMeterElement: {\n prototype: HTMLMeterElement;\n new(): HTMLMeterElement;\n}\n\ninterface HTMLModElement extends HTMLElement {\n /**\n * Sets or retrieves reference information about the object.\n */\n cite: string;\n /**\n * Sets or retrieves the date and time of a modification to the object.\n */\n dateTime: string;\n addEventListener(type: K, listener: (this: HTMLModElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLModElement: {\n prototype: HTMLModElement;\n new(): HTMLModElement;\n}\n\ninterface HTMLOListElement extends HTMLElement {\n compact: boolean;\n /**\n * The starting number.\n */\n start: number;\n type: string;\n addEventListener(type: K, listener: (this: HTMLOListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOListElement: {\n prototype: HTMLOListElement;\n new(): HTMLOListElement;\n}\n\ninterface HTMLObjectElement extends HTMLElement, GetSVGDocument {\n /**\n * Retrieves a string of the URL where the object tag can be found. This is often the href of the document that the object is in, or the value set by a base element.\n */\n readonly BaseHref: string;\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Gets or sets the optional alternative HTML script to execute if the object fails to load.\n */\n altHtml: string;\n /**\n * Sets or retrieves a character string that can be used to implement your own archive functionality for the object.\n */\n archive: string;\n border: string;\n /**\n * Sets or retrieves the URL of the file containing the compiled Java class.\n */\n code: string;\n /**\n * Sets or retrieves the URL of the component.\n */\n codeBase: string;\n /**\n * Sets or retrieves the Internet media type for the code associated with the object.\n */\n codeType: string;\n /**\n * Retrieves the document object of the page or frame.\n */\n readonly contentDocument: Document;\n /**\n * Sets or retrieves the URL that references the data of the object.\n */\n data: string;\n declare: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n hspace: number;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n /**\n * Gets or sets the path to the preferred media source. This enables the Play To target device to stream the media content, which can be DRM protected, from a different location, such as a cloud media server.\n */\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n readonly readyState: number;\n /**\n * Sets or retrieves a message to be displayed while an object is loading.\n */\n standby: string;\n /**\n * Sets or retrieves the MIME type of the object.\n */\n type: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n vspace: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLObjectElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLObjectElement: {\n prototype: HTMLObjectElement;\n new(): HTMLObjectElement;\n}\n\ninterface HTMLOptGroupElement extends HTMLElement {\n /**\n * Sets or retrieves the status of an option.\n */\n defaultSelected: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the ordinal position of an option in a list box.\n */\n readonly index: number;\n /**\n * Sets or retrieves a value that you can use to implement your own label functionality for the object.\n */\n label: string;\n /**\n * Sets or retrieves whether the option in the list box is the default item.\n */\n selected: boolean;\n /**\n * Sets or retrieves the text string specified by the option tag.\n */\n readonly text: string;\n /**\n * Sets or retrieves the value which is returned to the server when the form control is submitted.\n */\n value: string;\n addEventListener(type: K, listener: (this: HTMLOptGroupElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOptGroupElement: {\n prototype: HTMLOptGroupElement;\n new(): HTMLOptGroupElement;\n}\n\ninterface HTMLOptionElement extends HTMLElement {\n /**\n * Sets or retrieves the status of an option.\n */\n defaultSelected: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the ordinal position of an option in a list box.\n */\n readonly index: number;\n /**\n * Sets or retrieves a value that you can use to implement your own label functionality for the object.\n */\n label: string;\n /**\n * Sets or retrieves whether the option in the list box is the default item.\n */\n selected: boolean;\n /**\n * Sets or retrieves the text string specified by the option tag.\n */\n text: string;\n /**\n * Sets or retrieves the value which is returned to the server when the form control is submitted.\n */\n value: string;\n addEventListener(type: K, listener: (this: HTMLOptionElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOptionElement: {\n prototype: HTMLOptionElement;\n new(): HTMLOptionElement;\n}\n\ninterface HTMLOptionsCollection extends HTMLCollectionOf {\n length: number;\n selectedIndex: number;\n add(element: HTMLOptionElement | HTMLOptGroupElement, before?: HTMLElement | number): void;\n remove(index: number): void;\n}\n\ndeclare var HTMLOptionsCollection: {\n prototype: HTMLOptionsCollection;\n new(): HTMLOptionsCollection;\n}\n\ninterface HTMLOutputElement extends HTMLElement {\n defaultValue: string;\n readonly form: HTMLFormElement;\n readonly htmlFor: DOMSettableTokenList;\n name: string;\n readonly type: string;\n readonly validationMessage: string;\n readonly validity: ValidityState;\n value: string;\n readonly willValidate: boolean;\n checkValidity(): boolean;\n reportValidity(): boolean;\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLOutputElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOutputElement: {\n prototype: HTMLOutputElement;\n new(): HTMLOutputElement;\n}\n\ninterface HTMLParagraphElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text. \n */\n align: string;\n clear: string;\n addEventListener(type: K, listener: (this: HTMLParagraphElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLParagraphElement: {\n prototype: HTMLParagraphElement;\n new(): HTMLParagraphElement;\n}\n\ninterface HTMLParamElement extends HTMLElement {\n /**\n * Sets or retrieves the name of an input parameter for an element.\n */\n name: string;\n /**\n * Sets or retrieves the content type of the resource designated by the value attribute.\n */\n type: string;\n /**\n * Sets or retrieves the value of an input parameter for an element.\n */\n value: string;\n /**\n * Sets or retrieves the data type of the value attribute.\n */\n valueType: string;\n addEventListener(type: K, listener: (this: HTMLParamElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLParamElement: {\n prototype: HTMLParamElement;\n new(): HTMLParamElement;\n}\n\ninterface HTMLPictureElement extends HTMLElement {\n addEventListener(type: K, listener: (this: HTMLPictureElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLPictureElement: {\n prototype: HTMLPictureElement;\n new(): HTMLPictureElement;\n}\n\ninterface HTMLPreElement extends HTMLElement {\n /**\n * Sets or gets a value that you can use to implement your own width functionality for the object.\n */\n width: number;\n addEventListener(type: K, listener: (this: HTMLPreElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLPreElement: {\n prototype: HTMLPreElement;\n new(): HTMLPreElement;\n}\n\ninterface HTMLProgressElement extends HTMLElement {\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Defines the maximum, or \"done\" value for a progress element.\n */\n max: number;\n /**\n * Returns the quotient of value/max when the value attribute is set (determinate progress bar), or -1 when the value attribute is missing (indeterminate progress bar).\n */\n readonly position: number;\n /**\n * Sets or gets the current value of a progress element. The value must be a non-negative number between 0 and the max value.\n */\n value: number;\n addEventListener(type: K, listener: (this: HTMLProgressElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLProgressElement: {\n prototype: HTMLProgressElement;\n new(): HTMLProgressElement;\n}\n\ninterface HTMLQuoteElement extends HTMLElement {\n /**\n * Sets or retrieves reference information about the object.\n */\n cite: string;\n addEventListener(type: K, listener: (this: HTMLQuoteElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLQuoteElement: {\n prototype: HTMLQuoteElement;\n new(): HTMLQuoteElement;\n}\n\ninterface HTMLScriptElement extends HTMLElement {\n async: boolean;\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n crossOrigin: string | null;\n /**\n * Sets or retrieves the status of the script.\n */\n defer: boolean;\n /**\n * Sets or retrieves the event for which the script is written. \n */\n event: string;\n /** \n * Sets or retrieves the object that is bound to the event script.\n */\n htmlFor: string;\n /**\n * Retrieves the URL to an external file that contains the source code or data.\n */\n src: string;\n /**\n * Retrieves or sets the text of the object as a string. \n */\n text: string;\n /**\n * Sets or retrieves the MIME type for the associated scripting engine.\n */\n type: string;\n integrity: string;\n addEventListener(type: K, listener: (this: HTMLScriptElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLScriptElement: {\n prototype: HTMLScriptElement;\n new(): HTMLScriptElement;\n}\n\ninterface HTMLSelectElement extends HTMLElement {\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in. \n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the number of objects in a collection.\n */\n length: number;\n /**\n * Sets or retrieves the Boolean value indicating whether multiple items can be selected from a list.\n */\n multiple: boolean;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n readonly options: HTMLOptionsCollection;\n /**\n * When present, marks an element that can't be submitted without a value.\n */\n required: boolean;\n /**\n * Sets or retrieves the index of the selected option in a select object.\n */\n selectedIndex: number;\n selectedOptions: HTMLCollectionOf;\n /**\n * Sets or retrieves the number of rows in the list box. \n */\n size: number;\n /**\n * Retrieves the type of select control based on the value of the MULTIPLE attribute.\n */\n readonly type: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Sets or retrieves the value which is returned to the server when the form control is submitted.\n */\n value: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Adds an element to the areas, controlRange, or options collection.\n * @param element Variant of type Number that specifies the index position in the collection where the element is placed. If no value is given, the method places the element at the end of the collection.\n * @param before Variant of type Object that specifies an element to insert before, or null to append the object to the collection. \n */\n add(element: HTMLElement, before?: HTMLElement | number): void;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Retrieves a select object or an object from an options collection.\n * @param name Variant of type Number or String that specifies the object or collection to retrieve. If this parameter is an integer, it is the zero-based index of the object. If this parameter is a string, all objects with matching name or id properties are retrieved, and a collection is returned if more than one match is made.\n * @param index Variant of type Number that specifies the zero-based index of the object to retrieve when a collection is returned.\n */\n item(name?: any, index?: any): any;\n /**\n * Retrieves a select object or an object from an options collection.\n * @param namedItem A String that specifies the name or id property of the object to retrieve. A collection is returned if more than one match is made.\n */\n namedItem(name: string): any;\n /**\n * Removes an element from the collection.\n * @param index Number that specifies the zero-based index of the element to remove from the collection.\n */\n remove(index?: number): void;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLSelectElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [name: string]: any;\n}\n\ndeclare var HTMLSelectElement: {\n prototype: HTMLSelectElement;\n new(): HTMLSelectElement;\n}\n\ninterface HTMLSourceElement extends HTMLElement {\n /**\n * Gets or sets the intended media type of the media source.\n */\n media: string;\n msKeySystem: string;\n sizes: string;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n srcset: string;\n /**\n * Gets or sets the MIME type of a media resource.\n */\n type: string;\n addEventListener(type: K, listener: (this: HTMLSourceElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLSourceElement: {\n prototype: HTMLSourceElement;\n new(): HTMLSourceElement;\n}\n\ninterface HTMLSpanElement extends HTMLElement {\n addEventListener(type: K, listener: (this: HTMLSpanElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLSpanElement: {\n prototype: HTMLSpanElement;\n new(): HTMLSpanElement;\n}\n\ninterface HTMLStyleElement extends HTMLElement, LinkStyle {\n disabled: boolean;\n /**\n * Sets or retrieves the media type.\n */\n media: string;\n /**\n * Retrieves the CSS language in which the style sheet is written.\n */\n type: string;\n addEventListener(type: K, listener: (this: HTMLStyleElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLStyleElement: {\n prototype: HTMLStyleElement;\n new(): HTMLStyleElement;\n}\n\ninterface HTMLTableCaptionElement extends HTMLElement {\n /**\n * Sets or retrieves the alignment of the caption or legend.\n */\n align: string;\n /**\n * Sets or retrieves whether the caption appears at the top or bottom of the table.\n */\n vAlign: string;\n addEventListener(type: K, listener: (this: HTMLTableCaptionElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableCaptionElement: {\n prototype: HTMLTableCaptionElement;\n new(): HTMLTableCaptionElement;\n}\n\ninterface HTMLTableCellElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves abbreviated text for the object.\n */\n abbr: string;\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves a comma-delimited list of conceptual categories associated with the object.\n */\n axis: string;\n bgColor: any;\n /**\n * Retrieves the position of the object in the cells collection of a row.\n */\n readonly cellIndex: number;\n /**\n * Sets or retrieves the number columns in the table that the object should span.\n */\n colSpan: number;\n /**\n * Sets or retrieves a list of header cells that provide information for the object.\n */\n headers: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: any;\n /**\n * Sets or retrieves whether the browser automatically performs wordwrap.\n */\n noWrap: boolean;\n /**\n * Sets or retrieves how many rows in a table the cell should span.\n */\n rowSpan: number;\n /**\n * Sets or retrieves the group of cells in a table to which the object's information applies.\n */\n scope: string;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n addEventListener(type: K, listener: (this: HTMLTableCellElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableCellElement: {\n prototype: HTMLTableCellElement;\n new(): HTMLTableCellElement;\n}\n\ninterface HTMLTableColElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves the alignment of the object relative to the display or table.\n */\n align: string;\n /**\n * Sets or retrieves the number of columns in the group.\n */\n span: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: any;\n addEventListener(type: K, listener: (this: HTMLTableColElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableColElement: {\n prototype: HTMLTableColElement;\n new(): HTMLTableColElement;\n}\n\ninterface HTMLTableDataCellElement extends HTMLTableCellElement {\n addEventListener(type: K, listener: (this: HTMLTableDataCellElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableDataCellElement: {\n prototype: HTMLTableDataCellElement;\n new(): HTMLTableDataCellElement;\n}\n\ninterface HTMLTableElement extends HTMLElement {\n /**\n * Sets or retrieves a value that indicates the table alignment.\n */\n align: string;\n bgColor: any;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n border: string;\n /**\n * Sets or retrieves the border color of the object. \n */\n borderColor: any;\n /**\n * Retrieves the caption object of a table.\n */\n caption: HTMLTableCaptionElement;\n /**\n * Sets or retrieves the amount of space between the border of the cell and the content of the cell.\n */\n cellPadding: string;\n /**\n * Sets or retrieves the amount of space between cells in a table.\n */\n cellSpacing: string;\n /**\n * Sets or retrieves the number of columns in the table.\n */\n cols: number;\n /**\n * Sets or retrieves the way the border frame around the table is displayed.\n */\n frame: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: any;\n /**\n * Sets or retrieves the number of horizontal rows contained in the object.\n */\n rows: HTMLCollectionOf;\n /**\n * Sets or retrieves which dividing lines (inner borders) are displayed.\n */\n rules: string;\n /**\n * Sets or retrieves a description and/or structure of the object.\n */\n summary: string;\n /**\n * Retrieves a collection of all tBody objects in the table. Objects in this collection are in source order.\n */\n tBodies: HTMLCollectionOf;\n /**\n * Retrieves the tFoot object of the table.\n */\n tFoot: HTMLTableSectionElement;\n /**\n * Retrieves the tHead object of the table.\n */\n tHead: HTMLTableSectionElement;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n /**\n * Creates an empty caption element in the table.\n */\n createCaption(): HTMLTableCaptionElement;\n /**\n * Creates an empty tBody element in the table.\n */\n createTBody(): HTMLTableSectionElement;\n /**\n * Creates an empty tFoot element in the table.\n */\n createTFoot(): HTMLTableSectionElement;\n /**\n * Returns the tHead element object if successful, or null otherwise.\n */\n createTHead(): HTMLTableSectionElement;\n /**\n * Deletes the caption element and its contents from the table.\n */\n deleteCaption(): void;\n /**\n * Removes the specified row (tr) from the element and from the rows collection.\n * @param index Number that specifies the zero-based position in the rows collection of the row to remove.\n */\n deleteRow(index?: number): void;\n /**\n * Deletes the tFoot element and its contents from the table.\n */\n deleteTFoot(): void;\n /**\n * Deletes the tHead element and its contents from the table.\n */\n deleteTHead(): void;\n /**\n * Creates a new row (tr) in the table, and adds the row to the rows collection.\n * @param index Number that specifies where to insert the row in the rows collection. The default value is -1, which appends the new row to the end of the rows collection.\n */\n insertRow(index?: number): HTMLTableRowElement;\n addEventListener(type: K, listener: (this: HTMLTableElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableElement: {\n prototype: HTMLTableElement;\n new(): HTMLTableElement;\n}\n\ninterface HTMLTableHeaderCellElement extends HTMLTableCellElement {\n /**\n * Sets or retrieves the group of cells in a table to which the object's information applies.\n */\n scope: string;\n addEventListener(type: K, listener: (this: HTMLTableHeaderCellElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableHeaderCellElement: {\n prototype: HTMLTableHeaderCellElement;\n new(): HTMLTableHeaderCellElement;\n}\n\ninterface HTMLTableRowElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n bgColor: any;\n /**\n * Retrieves a collection of all cells in the table row.\n */\n cells: HTMLCollectionOf;\n /**\n * Sets or retrieves the height of the object.\n */\n height: any;\n /**\n * Retrieves the position of the object in the rows collection for the table.\n */\n readonly rowIndex: number;\n /**\n * Retrieves the position of the object in the collection.\n */\n readonly sectionRowIndex: number;\n /**\n * Removes the specified cell from the table row, as well as from the cells collection.\n * @param index Number that specifies the zero-based position of the cell to remove from the table row. If no value is provided, the last cell in the cells collection is deleted.\n */\n deleteCell(index?: number): void;\n /**\n * Creates a new cell in the table row, and adds the cell to the cells collection.\n * @param index Number that specifies where to insert the cell in the tr. The default value is -1, which appends the new cell to the end of the cells collection.\n */\n insertCell(index?: number): HTMLTableDataCellElement;\n addEventListener(type: K, listener: (this: HTMLTableRowElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableRowElement: {\n prototype: HTMLTableRowElement;\n new(): HTMLTableRowElement;\n}\n\ninterface HTMLTableSectionElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves a value that indicates the table alignment.\n */\n align: string;\n /**\n * Sets or retrieves the number of horizontal rows contained in the object.\n */\n rows: HTMLCollectionOf;\n /**\n * Removes the specified row (tr) from the element and from the rows collection.\n * @param index Number that specifies the zero-based position in the rows collection of the row to remove.\n */\n deleteRow(index?: number): void;\n /**\n * Creates a new row (tr) in the table, and adds the row to the rows collection.\n * @param index Number that specifies where to insert the row in the rows collection. The default value is -1, which appends the new row to the end of the rows collection.\n */\n insertRow(index?: number): HTMLTableRowElement;\n addEventListener(type: K, listener: (this: HTMLTableSectionElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableSectionElement: {\n prototype: HTMLTableSectionElement;\n new(): HTMLTableSectionElement;\n}\n\ninterface HTMLTemplateElement extends HTMLElement {\n readonly content: DocumentFragment;\n addEventListener(type: K, listener: (this: HTMLTemplateElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTemplateElement: {\n prototype: HTMLTemplateElement;\n new(): HTMLTemplateElement;\n}\n\ninterface HTMLTextAreaElement extends HTMLElement {\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n /**\n * Sets or retrieves the width of the object.\n */\n cols: number;\n /**\n * Sets or retrieves the initial contents of the object.\n */\n defaultValue: string;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the maximum number of characters that the user can enter in a text control.\n */\n maxLength: number;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Gets or sets a text string that is displayed in an input field as a hint or prompt to users as the format or type of information they need to enter.The text appears in an input field until the user puts focus on the field.\n */\n placeholder: string;\n /**\n * Sets or retrieves the value indicated whether the content of the object is read-only.\n */\n readOnly: boolean;\n /**\n * When present, marks an element that can't be submitted without a value.\n */\n required: boolean;\n /**\n * Sets or retrieves the number of horizontal rows contained in the object.\n */\n rows: number;\n /**\n * Gets or sets the end position or offset of a text selection.\n */\n selectionEnd: number;\n /**\n * Gets or sets the starting position or offset of a text selection.\n */\n selectionStart: number;\n /**\n * Sets or retrieves the value indicating whether the control is selected.\n */\n status: any;\n /**\n * Retrieves the type of control.\n */\n readonly type: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Retrieves or sets the text in the entry field of the textArea element.\n */\n value: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Sets or retrieves how to handle wordwrapping in the object.\n */\n wrap: string;\n minLength: number;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Highlights the input area of a form element.\n */\n select(): void;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n /**\n * Sets the start and end positions of a selection in a text field.\n * @param start The offset into the text field for the start of the selection.\n * @param end The offset into the text field for the end of the selection.\n */\n setSelectionRange(start: number, end: number): void;\n addEventListener(type: K, listener: (this: HTMLTextAreaElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTextAreaElement: {\n prototype: HTMLTextAreaElement;\n new(): HTMLTextAreaElement;\n}\n\ninterface HTMLTimeElement extends HTMLElement {\n dateTime: string;\n addEventListener(type: K, listener: (this: HTMLTimeElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTimeElement: {\n prototype: HTMLTimeElement;\n new(): HTMLTimeElement;\n}\n\ninterface HTMLTitleElement extends HTMLElement {\n /**\n * Retrieves or sets the text of the object as a string. \n */\n text: string;\n addEventListener(type: K, listener: (this: HTMLTitleElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTitleElement: {\n prototype: HTMLTitleElement;\n new(): HTMLTitleElement;\n}\n\ninterface HTMLTrackElement extends HTMLElement {\n default: boolean;\n kind: string;\n label: string;\n readonly readyState: number;\n src: string;\n srclang: string;\n readonly track: TextTrack;\n readonly ERROR: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n addEventListener(type: K, listener: (this: HTMLTrackElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTrackElement: {\n prototype: HTMLTrackElement;\n new(): HTMLTrackElement;\n readonly ERROR: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n}\n\ninterface HTMLUListElement extends HTMLElement {\n compact: boolean;\n type: string;\n addEventListener(type: K, listener: (this: HTMLUListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLUListElement: {\n prototype: HTMLUListElement;\n new(): HTMLUListElement;\n}\n\ninterface HTMLUnknownElement extends HTMLElement {\n addEventListener(type: K, listener: (this: HTMLUnknownElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLUnknownElement: {\n prototype: HTMLUnknownElement;\n new(): HTMLUnknownElement;\n}\n\ninterface HTMLVideoElementEventMap extends HTMLMediaElementEventMap {\n \"MSVideoFormatChanged\": Event;\n \"MSVideoFrameStepCompleted\": Event;\n \"MSVideoOptimalLayoutChanged\": Event;\n}\n\ninterface HTMLVideoElement extends HTMLMediaElement {\n /**\n * Gets or sets the height of the video element.\n */\n height: number;\n msHorizontalMirror: boolean;\n readonly msIsLayoutOptimalForPlayback: boolean;\n readonly msIsStereo3D: boolean;\n msStereo3DPackingMode: string;\n msStereo3DRenderMode: string;\n msZoom: boolean;\n onMSVideoFormatChanged: (this: HTMLVideoElement, ev: Event) => any;\n onMSVideoFrameStepCompleted: (this: HTMLVideoElement, ev: Event) => any;\n onMSVideoOptimalLayoutChanged: (this: HTMLVideoElement, ev: Event) => any;\n /**\n * Gets or sets a URL of an image to display, for example, like a movie poster. This can be a still frame from the video, or another image if no video data is available.\n */\n poster: string;\n /**\n * Gets the intrinsic height of a video in CSS pixels, or zero if the dimensions are not known.\n */\n readonly videoHeight: number;\n /**\n * Gets the intrinsic width of a video in CSS pixels, or zero if the dimensions are not known.\n */\n readonly videoWidth: number;\n readonly webkitDisplayingFullscreen: boolean;\n readonly webkitSupportsFullscreen: boolean;\n /**\n * Gets or sets the width of the video element.\n */\n width: number;\n getVideoPlaybackQuality(): VideoPlaybackQuality;\n msFrameStep(forward: boolean): void;\n msInsertVideoEffect(activatableClassId: string, effectRequired: boolean, config?: any): void;\n msSetVideoRectangle(left: number, top: number, right: number, bottom: number): void;\n webkitEnterFullScreen(): void;\n webkitEnterFullscreen(): void;\n webkitExitFullScreen(): void;\n webkitExitFullscreen(): void;\n addEventListener(type: K, listener: (this: HTMLVideoElement, ev: HTMLVideoElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLVideoElement: {\n prototype: HTMLVideoElement;\n new(): HTMLVideoElement;\n}\n\ninterface HashChangeEvent extends Event {\n readonly newURL: string | null;\n readonly oldURL: string | null;\n}\n\ndeclare var HashChangeEvent: {\n prototype: HashChangeEvent;\n new(typeArg: string, eventInitDict?: HashChangeEventInit): HashChangeEvent;\n}\n\ninterface Headers {\n append(name: string, value: string): void;\n delete(name: string): void;\n forEach(callback: ForEachCallback): void;\n get(name: string): string | null;\n has(name: string): boolean;\n set(name: string, value: string): void;\n}\n\ndeclare var Headers: {\n prototype: Headers;\n new(init?: any): Headers;\n}\n\ninterface History {\n readonly length: number;\n readonly state: any;\n scrollRestoration: ScrollRestoration;\n back(): void;\n forward(): void;\n go(delta?: number): void;\n pushState(data: any, title: string, url?: string | null): void;\n replaceState(data: any, title: string, url?: string | null): void;\n}\n\ndeclare var History: {\n prototype: History;\n new(): History;\n}\n\ninterface IDBCursor {\n readonly direction: IDBCursorDirection;\n key: IDBKeyRange | IDBValidKey;\n readonly primaryKey: any;\n source: IDBObjectStore | IDBIndex;\n advance(count: number): void;\n continue(key?: IDBKeyRange | IDBValidKey): void;\n delete(): IDBRequest;\n update(value: any): IDBRequest;\n readonly NEXT: string;\n readonly NEXT_NO_DUPLICATE: string;\n readonly PREV: string;\n readonly PREV_NO_DUPLICATE: string;\n}\n\ndeclare var IDBCursor: {\n prototype: IDBCursor;\n new(): IDBCursor;\n readonly NEXT: string;\n readonly NEXT_NO_DUPLICATE: string;\n readonly PREV: string;\n readonly PREV_NO_DUPLICATE: string;\n}\n\ninterface IDBCursorWithValue extends IDBCursor {\n readonly value: any;\n}\n\ndeclare var IDBCursorWithValue: {\n prototype: IDBCursorWithValue;\n new(): IDBCursorWithValue;\n}\n\ninterface IDBDatabaseEventMap {\n \"abort\": Event;\n \"error\": Event;\n}\n\ninterface IDBDatabase extends EventTarget {\n readonly name: string;\n readonly objectStoreNames: DOMStringList;\n onabort: (this: IDBDatabase, ev: Event) => any;\n onerror: (this: IDBDatabase, ev: Event) => any;\n version: number;\n onversionchange: (ev: IDBVersionChangeEvent) => any;\n close(): void;\n createObjectStore(name: string, optionalParameters?: IDBObjectStoreParameters): IDBObjectStore;\n deleteObjectStore(name: string): void;\n transaction(storeNames: string | string[], mode?: string): IDBTransaction;\n addEventListener(type: \"versionchange\", listener: (ev: IDBVersionChangeEvent) => any, useCapture?: boolean): void;\n addEventListener(type: K, listener: (this: IDBDatabase, ev: IDBDatabaseEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBDatabase: {\n prototype: IDBDatabase;\n new(): IDBDatabase;\n}\n\ninterface IDBFactory {\n cmp(first: any, second: any): number;\n deleteDatabase(name: string): IDBOpenDBRequest;\n open(name: string, version?: number): IDBOpenDBRequest;\n}\n\ndeclare var IDBFactory: {\n prototype: IDBFactory;\n new(): IDBFactory;\n}\n\ninterface IDBIndex {\n keyPath: string | string[];\n readonly name: string;\n readonly objectStore: IDBObjectStore;\n readonly unique: boolean;\n multiEntry: boolean;\n count(key?: IDBKeyRange | IDBValidKey): IDBRequest;\n get(key: IDBKeyRange | IDBValidKey): IDBRequest;\n getKey(key: IDBKeyRange | IDBValidKey): IDBRequest;\n openCursor(range?: IDBKeyRange | IDBValidKey, direction?: string): IDBRequest;\n openKeyCursor(range?: IDBKeyRange | IDBValidKey, direction?: string): IDBRequest;\n}\n\ndeclare var IDBIndex: {\n prototype: IDBIndex;\n new(): IDBIndex;\n}\n\ninterface IDBKeyRange {\n readonly lower: any;\n readonly lowerOpen: boolean;\n readonly upper: any;\n readonly upperOpen: boolean;\n}\n\ndeclare var IDBKeyRange: {\n prototype: IDBKeyRange;\n new(): IDBKeyRange;\n bound(lower: any, upper: any, lowerOpen?: boolean, upperOpen?: boolean): IDBKeyRange;\n lowerBound(lower: any, open?: boolean): IDBKeyRange;\n only(value: any): IDBKeyRange;\n upperBound(upper: any, open?: boolean): IDBKeyRange;\n}\n\ninterface IDBObjectStore {\n readonly indexNames: DOMStringList;\n keyPath: string | string[];\n readonly name: string;\n readonly transaction: IDBTransaction;\n autoIncrement: boolean;\n add(value: any, key?: IDBKeyRange | IDBValidKey): IDBRequest;\n clear(): IDBRequest;\n count(key?: IDBKeyRange | IDBValidKey): IDBRequest;\n createIndex(name: string, keyPath: string | string[], optionalParameters?: IDBIndexParameters): IDBIndex;\n delete(key: IDBKeyRange | IDBValidKey): IDBRequest;\n deleteIndex(indexName: string): void;\n get(key: any): IDBRequest;\n index(name: string): IDBIndex;\n openCursor(range?: IDBKeyRange | IDBValidKey, direction?: string): IDBRequest;\n put(value: any, key?: IDBKeyRange | IDBValidKey): IDBRequest;\n}\n\ndeclare var IDBObjectStore: {\n prototype: IDBObjectStore;\n new(): IDBObjectStore;\n}\n\ninterface IDBOpenDBRequestEventMap extends IDBRequestEventMap {\n \"blocked\": Event;\n \"upgradeneeded\": IDBVersionChangeEvent;\n}\n\ninterface IDBOpenDBRequest extends IDBRequest {\n onblocked: (this: IDBOpenDBRequest, ev: Event) => any;\n onupgradeneeded: (this: IDBOpenDBRequest, ev: IDBVersionChangeEvent) => any;\n addEventListener(type: K, listener: (this: IDBOpenDBRequest, ev: IDBOpenDBRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBOpenDBRequest: {\n prototype: IDBOpenDBRequest;\n new(): IDBOpenDBRequest;\n}\n\ninterface IDBRequestEventMap {\n \"error\": Event;\n \"success\": Event;\n}\n\ninterface IDBRequest extends EventTarget {\n readonly error: DOMError;\n onerror: (this: IDBRequest, ev: Event) => any;\n onsuccess: (this: IDBRequest, ev: Event) => any;\n readonly readyState: IDBRequestReadyState;\n readonly result: any;\n source: IDBObjectStore | IDBIndex | IDBCursor;\n readonly transaction: IDBTransaction;\n addEventListener(type: K, listener: (this: IDBRequest, ev: IDBRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBRequest: {\n prototype: IDBRequest;\n new(): IDBRequest;\n}\n\ninterface IDBTransactionEventMap {\n \"abort\": Event;\n \"complete\": Event;\n \"error\": Event;\n}\n\ninterface IDBTransaction extends EventTarget {\n readonly db: IDBDatabase;\n readonly error: DOMError;\n readonly mode: IDBTransactionMode;\n onabort: (this: IDBTransaction, ev: Event) => any;\n oncomplete: (this: IDBTransaction, ev: Event) => any;\n onerror: (this: IDBTransaction, ev: Event) => any;\n abort(): void;\n objectStore(name: string): IDBObjectStore;\n readonly READ_ONLY: string;\n readonly READ_WRITE: string;\n readonly VERSION_CHANGE: string;\n addEventListener(type: K, listener: (this: IDBTransaction, ev: IDBTransactionEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBTransaction: {\n prototype: IDBTransaction;\n new(): IDBTransaction;\n readonly READ_ONLY: string;\n readonly READ_WRITE: string;\n readonly VERSION_CHANGE: string;\n}\n\ninterface IDBVersionChangeEvent extends Event {\n readonly newVersion: number | null;\n readonly oldVersion: number;\n}\n\ndeclare var IDBVersionChangeEvent: {\n prototype: IDBVersionChangeEvent;\n new(): IDBVersionChangeEvent;\n}\n\ninterface IIRFilterNode extends AudioNode {\n getFrequencyResponse(frequencyHz: Float32Array, magResponse: Float32Array, phaseResponse: Float32Array): void;\n}\n\ndeclare var IIRFilterNode: {\n prototype: IIRFilterNode;\n new(): IIRFilterNode;\n}\n\ninterface ImageData {\n data: Uint8ClampedArray;\n readonly height: number;\n readonly width: number;\n}\n\ndeclare var ImageData: {\n prototype: ImageData;\n new(width: number, height: number): ImageData;\n new(array: Uint8ClampedArray, width: number, height: number): ImageData;\n}\n\ninterface IntersectionObserver {\n readonly root: Element | null;\n readonly rootMargin: string;\n readonly thresholds: number[];\n disconnect(): void;\n observe(target: Element): void;\n takeRecords(): IntersectionObserverEntry[];\n unobserve(target: Element): void;\n}\n\ndeclare var IntersectionObserver: {\n prototype: IntersectionObserver;\n new(callback: IntersectionObserverCallback, options?: IntersectionObserverInit): IntersectionObserver;\n}\n\ninterface IntersectionObserverEntry {\n readonly boundingClientRect: ClientRect;\n readonly intersectionRatio: number;\n readonly intersectionRect: ClientRect;\n readonly rootBounds: ClientRect;\n readonly target: Element;\n readonly time: number;\n}\n\ndeclare var IntersectionObserverEntry: {\n prototype: IntersectionObserverEntry;\n new(intersectionObserverEntryInit: IntersectionObserverEntryInit): IntersectionObserverEntry;\n}\n\ninterface KeyboardEvent extends UIEvent {\n readonly altKey: boolean;\n readonly char: string | null;\n readonly charCode: number;\n readonly ctrlKey: boolean;\n readonly key: string;\n readonly keyCode: number;\n readonly locale: string;\n readonly location: number;\n readonly metaKey: boolean;\n readonly repeat: boolean;\n readonly shiftKey: boolean;\n readonly which: number;\n readonly code: string;\n getModifierState(keyArg: string): boolean;\n initKeyboardEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, keyArg: string, locationArg: number, modifiersListArg: string, repeat: boolean, locale: string): void;\n readonly DOM_KEY_LOCATION_JOYSTICK: number;\n readonly DOM_KEY_LOCATION_LEFT: number;\n readonly DOM_KEY_LOCATION_MOBILE: number;\n readonly DOM_KEY_LOCATION_NUMPAD: number;\n readonly DOM_KEY_LOCATION_RIGHT: number;\n readonly DOM_KEY_LOCATION_STANDARD: number;\n}\n\ndeclare var KeyboardEvent: {\n prototype: KeyboardEvent;\n new(typeArg: string, eventInitDict?: KeyboardEventInit): KeyboardEvent;\n readonly DOM_KEY_LOCATION_JOYSTICK: number;\n readonly DOM_KEY_LOCATION_LEFT: number;\n readonly DOM_KEY_LOCATION_MOBILE: number;\n readonly DOM_KEY_LOCATION_NUMPAD: number;\n readonly DOM_KEY_LOCATION_RIGHT: number;\n readonly DOM_KEY_LOCATION_STANDARD: number;\n}\n\ninterface ListeningStateChangedEvent extends Event {\n readonly label: string;\n readonly state: ListeningState;\n}\n\ndeclare var ListeningStateChangedEvent: {\n prototype: ListeningStateChangedEvent;\n new(): ListeningStateChangedEvent;\n}\n\ninterface Location {\n hash: string;\n host: string;\n hostname: string;\n href: string;\n readonly origin: string;\n pathname: string;\n port: string;\n protocol: string;\n search: string;\n assign(url: string): void;\n reload(forcedReload?: boolean): void;\n replace(url: string): void;\n toString(): string;\n}\n\ndeclare var Location: {\n prototype: Location;\n new(): Location;\n}\n\ninterface LongRunningScriptDetectedEvent extends Event {\n readonly executionTime: number;\n stopPageScriptExecution: boolean;\n}\n\ndeclare var LongRunningScriptDetectedEvent: {\n prototype: LongRunningScriptDetectedEvent;\n new(): LongRunningScriptDetectedEvent;\n}\n\ninterface MSApp {\n clearTemporaryWebDataAsync(): MSAppAsyncOperation;\n createBlobFromRandomAccessStream(type: string, seeker: any): Blob;\n createDataPackage(object: any): any;\n createDataPackageFromSelection(): any;\n createFileFromStorageFile(storageFile: any): File;\n createStreamFromInputStream(type: string, inputStream: any): MSStream;\n execAsyncAtPriority(asynchronousCallback: MSExecAtPriorityFunctionCallback, priority: string, ...args: any[]): void;\n execAtPriority(synchronousCallback: MSExecAtPriorityFunctionCallback, priority: string, ...args: any[]): any;\n getCurrentPriority(): string;\n getHtmlPrintDocumentSourceAsync(htmlDoc: any): Promise;\n getViewId(view: any): any;\n isTaskScheduledAtPriorityOrHigher(priority: string): boolean;\n pageHandlesAllApplicationActivations(enabled: boolean): void;\n suppressSubdownloadCredentialPrompts(suppress: boolean): void;\n terminateApp(exceptionObject: any): void;\n readonly CURRENT: string;\n readonly HIGH: string;\n readonly IDLE: string;\n readonly NORMAL: string;\n}\ndeclare var MSApp: MSApp;\n\ninterface MSAppAsyncOperationEventMap {\n \"complete\": Event;\n \"error\": Event;\n}\n\ninterface MSAppAsyncOperation extends EventTarget {\n readonly error: DOMError;\n oncomplete: (this: MSAppAsyncOperation, ev: Event) => any;\n onerror: (this: MSAppAsyncOperation, ev: Event) => any;\n readonly readyState: number;\n readonly result: any;\n start(): void;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n addEventListener(type: K, listener: (this: MSAppAsyncOperation, ev: MSAppAsyncOperationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSAppAsyncOperation: {\n prototype: MSAppAsyncOperation;\n new(): MSAppAsyncOperation;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n}\n\ninterface MSAssertion {\n readonly id: string;\n readonly type: MSCredentialType;\n}\n\ndeclare var MSAssertion: {\n prototype: MSAssertion;\n new(): MSAssertion;\n}\n\ninterface MSBlobBuilder {\n append(data: any, endings?: string): void;\n getBlob(contentType?: string): Blob;\n}\n\ndeclare var MSBlobBuilder: {\n prototype: MSBlobBuilder;\n new(): MSBlobBuilder;\n}\n\ninterface MSCredentials {\n getAssertion(challenge: string, filter?: MSCredentialFilter, params?: MSSignatureParameters): Promise;\n makeCredential(accountInfo: MSAccountInfo, params: MSCredentialParameters[], challenge?: string): Promise;\n}\n\ndeclare var MSCredentials: {\n prototype: MSCredentials;\n new(): MSCredentials;\n}\n\ninterface MSFIDOCredentialAssertion extends MSAssertion {\n readonly algorithm: string | Algorithm;\n readonly attestation: any;\n readonly publicKey: string;\n readonly transportHints: MSTransportType[];\n}\n\ndeclare var MSFIDOCredentialAssertion: {\n prototype: MSFIDOCredentialAssertion;\n new(): MSFIDOCredentialAssertion;\n}\n\ninterface MSFIDOSignature {\n readonly authnrData: string;\n readonly clientData: string;\n readonly signature: string;\n}\n\ndeclare var MSFIDOSignature: {\n prototype: MSFIDOSignature;\n new(): MSFIDOSignature;\n}\n\ninterface MSFIDOSignatureAssertion extends MSAssertion {\n readonly signature: MSFIDOSignature;\n}\n\ndeclare var MSFIDOSignatureAssertion: {\n prototype: MSFIDOSignatureAssertion;\n new(): MSFIDOSignatureAssertion;\n}\n\ninterface MSGesture {\n target: Element;\n addPointer(pointerId: number): void;\n stop(): void;\n}\n\ndeclare var MSGesture: {\n prototype: MSGesture;\n new(): MSGesture;\n}\n\ninterface MSGestureEvent extends UIEvent {\n readonly clientX: number;\n readonly clientY: number;\n readonly expansion: number;\n readonly gestureObject: any;\n readonly hwTimestamp: number;\n readonly offsetX: number;\n readonly offsetY: number;\n readonly rotation: number;\n readonly scale: number;\n readonly screenX: number;\n readonly screenY: number;\n readonly translationX: number;\n readonly translationY: number;\n readonly velocityAngular: number;\n readonly velocityExpansion: number;\n readonly velocityX: number;\n readonly velocityY: number;\n initGestureEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, offsetXArg: number, offsetYArg: number, translationXArg: number, translationYArg: number, scaleArg: number, expansionArg: number, rotationArg: number, velocityXArg: number, velocityYArg: number, velocityExpansionArg: number, velocityAngularArg: number, hwTimestampArg: number): void;\n readonly MSGESTURE_FLAG_BEGIN: number;\n readonly MSGESTURE_FLAG_CANCEL: number;\n readonly MSGESTURE_FLAG_END: number;\n readonly MSGESTURE_FLAG_INERTIA: number;\n readonly MSGESTURE_FLAG_NONE: number;\n}\n\ndeclare var MSGestureEvent: {\n prototype: MSGestureEvent;\n new(): MSGestureEvent;\n readonly MSGESTURE_FLAG_BEGIN: number;\n readonly MSGESTURE_FLAG_CANCEL: number;\n readonly MSGESTURE_FLAG_END: number;\n readonly MSGESTURE_FLAG_INERTIA: number;\n readonly MSGESTURE_FLAG_NONE: number;\n}\n\ninterface MSGraphicsTrust {\n readonly constrictionActive: boolean;\n readonly status: string;\n}\n\ndeclare var MSGraphicsTrust: {\n prototype: MSGraphicsTrust;\n new(): MSGraphicsTrust;\n}\n\ninterface MSHTMLWebViewElement extends HTMLElement {\n readonly canGoBack: boolean;\n readonly canGoForward: boolean;\n readonly containsFullScreenElement: boolean;\n readonly documentTitle: string;\n height: number;\n readonly settings: MSWebViewSettings;\n src: string;\n width: number;\n addWebAllowedObject(name: string, applicationObject: any): void;\n buildLocalStreamUri(contentIdentifier: string, relativePath: string): string;\n capturePreviewToBlobAsync(): MSWebViewAsyncOperation;\n captureSelectedContentToDataPackageAsync(): MSWebViewAsyncOperation;\n getDeferredPermissionRequestById(id: number): DeferredPermissionRequest;\n getDeferredPermissionRequests(): DeferredPermissionRequest[];\n goBack(): void;\n goForward(): void;\n invokeScriptAsync(scriptName: string, ...args: any[]): MSWebViewAsyncOperation;\n navigate(uri: string): void;\n navigateFocus(navigationReason: NavigationReason, origin: FocusNavigationOrigin): void;\n navigateToLocalStreamUri(source: string, streamResolver: any): void;\n navigateToString(contents: string): void;\n navigateWithHttpRequestMessage(requestMessage: any): void;\n refresh(): void;\n stop(): void;\n addEventListener(type: K, listener: (this: MSHTMLWebViewElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSHTMLWebViewElement: {\n prototype: MSHTMLWebViewElement;\n new(): MSHTMLWebViewElement;\n}\n\ninterface MSInputMethodContextEventMap {\n \"MSCandidateWindowHide\": Event;\n \"MSCandidateWindowShow\": Event;\n \"MSCandidateWindowUpdate\": Event;\n}\n\ninterface MSInputMethodContext extends EventTarget {\n readonly compositionEndOffset: number;\n readonly compositionStartOffset: number;\n oncandidatewindowhide: (this: MSInputMethodContext, ev: Event) => any;\n oncandidatewindowshow: (this: MSInputMethodContext, ev: Event) => any;\n oncandidatewindowupdate: (this: MSInputMethodContext, ev: Event) => any;\n readonly target: HTMLElement;\n getCandidateWindowClientRect(): ClientRect;\n getCompositionAlternatives(): string[];\n hasComposition(): boolean;\n isCandidateWindowVisible(): boolean;\n addEventListener(type: K, listener: (this: MSInputMethodContext, ev: MSInputMethodContextEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSInputMethodContext: {\n prototype: MSInputMethodContext;\n new(): MSInputMethodContext;\n}\n\ninterface MSManipulationEvent extends UIEvent {\n readonly currentState: number;\n readonly inertiaDestinationX: number;\n readonly inertiaDestinationY: number;\n readonly lastState: number;\n initMSManipulationEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, lastState: number, currentState: number): void;\n readonly MS_MANIPULATION_STATE_ACTIVE: number;\n readonly MS_MANIPULATION_STATE_CANCELLED: number;\n readonly MS_MANIPULATION_STATE_COMMITTED: number;\n readonly MS_MANIPULATION_STATE_DRAGGING: number;\n readonly MS_MANIPULATION_STATE_INERTIA: number;\n readonly MS_MANIPULATION_STATE_PRESELECT: number;\n readonly MS_MANIPULATION_STATE_SELECTING: number;\n readonly MS_MANIPULATION_STATE_STOPPED: number;\n}\n\ndeclare var MSManipulationEvent: {\n prototype: MSManipulationEvent;\n new(): MSManipulationEvent;\n readonly MS_MANIPULATION_STATE_ACTIVE: number;\n readonly MS_MANIPULATION_STATE_CANCELLED: number;\n readonly MS_MANIPULATION_STATE_COMMITTED: number;\n readonly MS_MANIPULATION_STATE_DRAGGING: number;\n readonly MS_MANIPULATION_STATE_INERTIA: number;\n readonly MS_MANIPULATION_STATE_PRESELECT: number;\n readonly MS_MANIPULATION_STATE_SELECTING: number;\n readonly MS_MANIPULATION_STATE_STOPPED: number;\n}\n\ninterface MSMediaKeyError {\n readonly code: number;\n readonly systemCode: number;\n readonly MS_MEDIA_KEYERR_CLIENT: number;\n readonly MS_MEDIA_KEYERR_DOMAIN: number;\n readonly MS_MEDIA_KEYERR_HARDWARECHANGE: number;\n readonly MS_MEDIA_KEYERR_OUTPUT: number;\n readonly MS_MEDIA_KEYERR_SERVICE: number;\n readonly MS_MEDIA_KEYERR_UNKNOWN: number;\n}\n\ndeclare var MSMediaKeyError: {\n prototype: MSMediaKeyError;\n new(): MSMediaKeyError;\n readonly MS_MEDIA_KEYERR_CLIENT: number;\n readonly MS_MEDIA_KEYERR_DOMAIN: number;\n readonly MS_MEDIA_KEYERR_HARDWARECHANGE: number;\n readonly MS_MEDIA_KEYERR_OUTPUT: number;\n readonly MS_MEDIA_KEYERR_SERVICE: number;\n readonly MS_MEDIA_KEYERR_UNKNOWN: number;\n}\n\ninterface MSMediaKeyMessageEvent extends Event {\n readonly destinationURL: string | null;\n readonly message: Uint8Array;\n}\n\ndeclare var MSMediaKeyMessageEvent: {\n prototype: MSMediaKeyMessageEvent;\n new(): MSMediaKeyMessageEvent;\n}\n\ninterface MSMediaKeyNeededEvent extends Event {\n readonly initData: Uint8Array | null;\n}\n\ndeclare var MSMediaKeyNeededEvent: {\n prototype: MSMediaKeyNeededEvent;\n new(): MSMediaKeyNeededEvent;\n}\n\ninterface MSMediaKeySession extends EventTarget {\n readonly error: MSMediaKeyError | null;\n readonly keySystem: string;\n readonly sessionId: string;\n close(): void;\n update(key: Uint8Array): void;\n}\n\ndeclare var MSMediaKeySession: {\n prototype: MSMediaKeySession;\n new(): MSMediaKeySession;\n}\n\ninterface MSMediaKeys {\n readonly keySystem: string;\n createSession(type: string, initData: Uint8Array, cdmData?: Uint8Array): MSMediaKeySession;\n}\n\ndeclare var MSMediaKeys: {\n prototype: MSMediaKeys;\n new(keySystem: string): MSMediaKeys;\n isTypeSupported(keySystem: string, type?: string): boolean;\n isTypeSupportedWithFeatures(keySystem: string, type?: string): string;\n}\n\ninterface MSPointerEvent extends MouseEvent {\n readonly currentPoint: any;\n readonly height: number;\n readonly hwTimestamp: number;\n readonly intermediatePoints: any;\n readonly isPrimary: boolean;\n readonly pointerId: number;\n readonly pointerType: any;\n readonly pressure: number;\n readonly rotation: number;\n readonly tiltX: number;\n readonly tiltY: number;\n readonly width: number;\n getCurrentPoint(element: Element): void;\n getIntermediatePoints(element: Element): void;\n initPointerEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget, offsetXArg: number, offsetYArg: number, widthArg: number, heightArg: number, pressure: number, rotation: number, tiltX: number, tiltY: number, pointerIdArg: number, pointerType: any, hwTimestampArg: number, isPrimary: boolean): void;\n}\n\ndeclare var MSPointerEvent: {\n prototype: MSPointerEvent;\n new(typeArg: string, eventInitDict?: PointerEventInit): MSPointerEvent;\n}\n\ninterface MSRangeCollection {\n readonly length: number;\n item(index: number): Range;\n [index: number]: Range;\n}\n\ndeclare var MSRangeCollection: {\n prototype: MSRangeCollection;\n new(): MSRangeCollection;\n}\n\ninterface MSSiteModeEvent extends Event {\n readonly actionURL: string;\n readonly buttonID: number;\n}\n\ndeclare var MSSiteModeEvent: {\n prototype: MSSiteModeEvent;\n new(): MSSiteModeEvent;\n}\n\ninterface MSStream {\n readonly type: string;\n msClose(): void;\n msDetachStream(): any;\n}\n\ndeclare var MSStream: {\n prototype: MSStream;\n new(): MSStream;\n}\n\ninterface MSStreamReader extends EventTarget, MSBaseReader {\n readonly error: DOMError;\n readAsArrayBuffer(stream: MSStream, size?: number): void;\n readAsBinaryString(stream: MSStream, size?: number): void;\n readAsBlob(stream: MSStream, size?: number): void;\n readAsDataURL(stream: MSStream, size?: number): void;\n readAsText(stream: MSStream, encoding?: string, size?: number): void;\n addEventListener(type: K, listener: (this: MSStreamReader, ev: MSBaseReaderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSStreamReader: {\n prototype: MSStreamReader;\n new(): MSStreamReader;\n}\n\ninterface MSWebViewAsyncOperationEventMap {\n \"complete\": Event;\n \"error\": Event;\n}\n\ninterface MSWebViewAsyncOperation extends EventTarget {\n readonly error: DOMError;\n oncomplete: (this: MSWebViewAsyncOperation, ev: Event) => any;\n onerror: (this: MSWebViewAsyncOperation, ev: Event) => any;\n readonly readyState: number;\n readonly result: any;\n readonly target: MSHTMLWebViewElement;\n readonly type: number;\n start(): void;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n readonly TYPE_CAPTURE_PREVIEW_TO_RANDOM_ACCESS_STREAM: number;\n readonly TYPE_CREATE_DATA_PACKAGE_FROM_SELECTION: number;\n readonly TYPE_INVOKE_SCRIPT: number;\n addEventListener(type: K, listener: (this: MSWebViewAsyncOperation, ev: MSWebViewAsyncOperationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSWebViewAsyncOperation: {\n prototype: MSWebViewAsyncOperation;\n new(): MSWebViewAsyncOperation;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n readonly TYPE_CAPTURE_PREVIEW_TO_RANDOM_ACCESS_STREAM: number;\n readonly TYPE_CREATE_DATA_PACKAGE_FROM_SELECTION: number;\n readonly TYPE_INVOKE_SCRIPT: number;\n}\n\ninterface MSWebViewSettings {\n isIndexedDBEnabled: boolean;\n isJavaScriptEnabled: boolean;\n}\n\ndeclare var MSWebViewSettings: {\n prototype: MSWebViewSettings;\n new(): MSWebViewSettings;\n}\n\ninterface MediaDeviceInfo {\n readonly deviceId: string;\n readonly groupId: string;\n readonly kind: MediaDeviceKind;\n readonly label: string;\n}\n\ndeclare var MediaDeviceInfo: {\n prototype: MediaDeviceInfo;\n new(): MediaDeviceInfo;\n}\n\ninterface MediaDevicesEventMap {\n \"devicechange\": Event;\n}\n\ninterface MediaDevices extends EventTarget {\n ondevicechange: (this: MediaDevices, ev: Event) => any;\n enumerateDevices(): any;\n getSupportedConstraints(): MediaTrackSupportedConstraints;\n getUserMedia(constraints: MediaStreamConstraints): Promise;\n addEventListener(type: K, listener: (this: MediaDevices, ev: MediaDevicesEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MediaDevices: {\n prototype: MediaDevices;\n new(): MediaDevices;\n}\n\ninterface MediaElementAudioSourceNode extends AudioNode {\n}\n\ndeclare var MediaElementAudioSourceNode: {\n prototype: MediaElementAudioSourceNode;\n new(): MediaElementAudioSourceNode;\n}\n\ninterface MediaEncryptedEvent extends Event {\n readonly initData: ArrayBuffer | null;\n readonly initDataType: string;\n}\n\ndeclare var MediaEncryptedEvent: {\n prototype: MediaEncryptedEvent;\n new(type: string, eventInitDict?: MediaEncryptedEventInit): MediaEncryptedEvent;\n}\n\ninterface MediaError {\n readonly code: number;\n readonly msExtendedCode: number;\n readonly MEDIA_ERR_ABORTED: number;\n readonly MEDIA_ERR_DECODE: number;\n readonly MEDIA_ERR_NETWORK: number;\n readonly MEDIA_ERR_SRC_NOT_SUPPORTED: number;\n readonly MS_MEDIA_ERR_ENCRYPTED: number;\n}\n\ndeclare var MediaError: {\n prototype: MediaError;\n new(): MediaError;\n readonly MEDIA_ERR_ABORTED: number;\n readonly MEDIA_ERR_DECODE: number;\n readonly MEDIA_ERR_NETWORK: number;\n readonly MEDIA_ERR_SRC_NOT_SUPPORTED: number;\n readonly MS_MEDIA_ERR_ENCRYPTED: number;\n}\n\ninterface MediaKeyMessageEvent extends Event {\n readonly message: ArrayBuffer;\n readonly messageType: MediaKeyMessageType;\n}\n\ndeclare var MediaKeyMessageEvent: {\n prototype: MediaKeyMessageEvent;\n new(type: string, eventInitDict?: MediaKeyMessageEventInit): MediaKeyMessageEvent;\n}\n\ninterface MediaKeySession extends EventTarget {\n readonly closed: Promise;\n readonly expiration: number;\n readonly keyStatuses: MediaKeyStatusMap;\n readonly sessionId: string;\n close(): Promise;\n generateRequest(initDataType: string, initData: any): Promise;\n load(sessionId: string): Promise;\n remove(): Promise;\n update(response: any): Promise;\n}\n\ndeclare var MediaKeySession: {\n prototype: MediaKeySession;\n new(): MediaKeySession;\n}\n\ninterface MediaKeyStatusMap {\n readonly size: number;\n forEach(callback: ForEachCallback): void;\n get(keyId: any): MediaKeyStatus;\n has(keyId: any): boolean;\n}\n\ndeclare var MediaKeyStatusMap: {\n prototype: MediaKeyStatusMap;\n new(): MediaKeyStatusMap;\n}\n\ninterface MediaKeySystemAccess {\n readonly keySystem: string;\n createMediaKeys(): Promise;\n getConfiguration(): MediaKeySystemConfiguration;\n}\n\ndeclare var MediaKeySystemAccess: {\n prototype: MediaKeySystemAccess;\n new(): MediaKeySystemAccess;\n}\n\ninterface MediaKeys {\n createSession(sessionType?: MediaKeySessionType): MediaKeySession;\n setServerCertificate(serverCertificate: any): Promise;\n}\n\ndeclare var MediaKeys: {\n prototype: MediaKeys;\n new(): MediaKeys;\n}\n\ninterface MediaList {\n readonly length: number;\n mediaText: string;\n appendMedium(newMedium: string): void;\n deleteMedium(oldMedium: string): void;\n item(index: number): string;\n toString(): string;\n [index: number]: string;\n}\n\ndeclare var MediaList: {\n prototype: MediaList;\n new(): MediaList;\n}\n\ninterface MediaQueryList {\n readonly matches: boolean;\n readonly media: string;\n addListener(listener: MediaQueryListListener): void;\n removeListener(listener: MediaQueryListListener): void;\n}\n\ndeclare var MediaQueryList: {\n prototype: MediaQueryList;\n new(): MediaQueryList;\n}\n\ninterface MediaSource extends EventTarget {\n readonly activeSourceBuffers: SourceBufferList;\n duration: number;\n readonly readyState: string;\n readonly sourceBuffers: SourceBufferList;\n addSourceBuffer(type: string): SourceBuffer;\n endOfStream(error?: number): void;\n removeSourceBuffer(sourceBuffer: SourceBuffer): void;\n}\n\ndeclare var MediaSource: {\n prototype: MediaSource;\n new(): MediaSource;\n isTypeSupported(type: string): boolean;\n}\n\ninterface MediaStreamEventMap {\n \"active\": Event;\n \"addtrack\": MediaStreamTrackEvent;\n \"inactive\": Event;\n \"removetrack\": MediaStreamTrackEvent;\n}\n\ninterface MediaStream extends EventTarget {\n readonly active: boolean;\n readonly id: string;\n onactive: (this: MediaStream, ev: Event) => any;\n onaddtrack: (this: MediaStream, ev: MediaStreamTrackEvent) => any;\n oninactive: (this: MediaStream, ev: Event) => any;\n onremovetrack: (this: MediaStream, ev: MediaStreamTrackEvent) => any;\n addTrack(track: MediaStreamTrack): void;\n clone(): MediaStream;\n getAudioTracks(): MediaStreamTrack[];\n getTrackById(trackId: string): MediaStreamTrack | null;\n getTracks(): MediaStreamTrack[];\n getVideoTracks(): MediaStreamTrack[];\n removeTrack(track: MediaStreamTrack): void;\n stop(): void;\n addEventListener(type: K, listener: (this: MediaStream, ev: MediaStreamEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MediaStream: {\n prototype: MediaStream;\n new(streamOrTracks?: MediaStream | MediaStreamTrack[]): MediaStream;\n}\n\ninterface MediaStreamAudioSourceNode extends AudioNode {\n}\n\ndeclare var MediaStreamAudioSourceNode: {\n prototype: MediaStreamAudioSourceNode;\n new(): MediaStreamAudioSourceNode;\n}\n\ninterface MediaStreamError {\n readonly constraintName: string | null;\n readonly message: string | null;\n readonly name: string;\n}\n\ndeclare var MediaStreamError: {\n prototype: MediaStreamError;\n new(): MediaStreamError;\n}\n\ninterface MediaStreamErrorEvent extends Event {\n readonly error: MediaStreamError | null;\n}\n\ndeclare var MediaStreamErrorEvent: {\n prototype: MediaStreamErrorEvent;\n new(typeArg: string, eventInitDict?: MediaStreamErrorEventInit): MediaStreamErrorEvent;\n}\n\ninterface MediaStreamEvent extends Event {\n readonly stream: MediaStream | null;\n}\n\ndeclare var MediaStreamEvent: {\n prototype: MediaStreamEvent;\n new(type: string, eventInitDict: MediaStreamEventInit): MediaStreamEvent;\n}\n\ninterface MediaStreamTrackEventMap {\n \"ended\": MediaStreamErrorEvent;\n \"mute\": Event;\n \"overconstrained\": MediaStreamErrorEvent;\n \"unmute\": Event;\n}\n\ninterface MediaStreamTrack extends EventTarget {\n enabled: boolean;\n readonly id: string;\n readonly kind: string;\n readonly label: string;\n readonly muted: boolean;\n onended: (this: MediaStreamTrack, ev: MediaStreamErrorEvent) => any;\n onmute: (this: MediaStreamTrack, ev: Event) => any;\n onoverconstrained: (this: MediaStreamTrack, ev: MediaStreamErrorEvent) => any;\n onunmute: (this: MediaStreamTrack, ev: Event) => any;\n readonly readonly: boolean;\n readonly readyState: MediaStreamTrackState;\n readonly remote: boolean;\n applyConstraints(constraints: MediaTrackConstraints): Promise;\n clone(): MediaStreamTrack;\n getCapabilities(): MediaTrackCapabilities;\n getConstraints(): MediaTrackConstraints;\n getSettings(): MediaTrackSettings;\n stop(): void;\n addEventListener(type: K, listener: (this: MediaStreamTrack, ev: MediaStreamTrackEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MediaStreamTrack: {\n prototype: MediaStreamTrack;\n new(): MediaStreamTrack;\n}\n\ninterface MediaStreamTrackEvent extends Event {\n readonly track: MediaStreamTrack;\n}\n\ndeclare var MediaStreamTrackEvent: {\n prototype: MediaStreamTrackEvent;\n new(typeArg: string, eventInitDict?: MediaStreamTrackEventInit): MediaStreamTrackEvent;\n}\n\ninterface MessageChannel {\n readonly port1: MessagePort;\n readonly port2: MessagePort;\n}\n\ndeclare var MessageChannel: {\n prototype: MessageChannel;\n new(): MessageChannel;\n}\n\ninterface MessageEvent extends Event {\n readonly data: any;\n readonly origin: string;\n readonly ports: any;\n readonly source: Window;\n initMessageEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, dataArg: any, originArg: string, lastEventIdArg: string, sourceArg: Window): void;\n}\n\ndeclare var MessageEvent: {\n prototype: MessageEvent;\n new(type: string, eventInitDict?: MessageEventInit): MessageEvent;\n}\n\ninterface MessagePortEventMap {\n \"message\": MessageEvent;\n}\n\ninterface MessagePort extends EventTarget {\n onmessage: (this: MessagePort, ev: MessageEvent) => any;\n close(): void;\n postMessage(message?: any, transfer?: any[]): void;\n start(): void;\n addEventListener(type: K, listener: (this: MessagePort, ev: MessagePortEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MessagePort: {\n prototype: MessagePort;\n new(): MessagePort;\n}\n\ninterface MimeType {\n readonly description: string;\n readonly enabledPlugin: Plugin;\n readonly suffixes: string;\n readonly type: string;\n}\n\ndeclare var MimeType: {\n prototype: MimeType;\n new(): MimeType;\n}\n\ninterface MimeTypeArray {\n readonly length: number;\n item(index: number): Plugin;\n namedItem(type: string): Plugin;\n [index: number]: Plugin;\n}\n\ndeclare var MimeTypeArray: {\n prototype: MimeTypeArray;\n new(): MimeTypeArray;\n}\n\ninterface MouseEvent extends UIEvent {\n readonly altKey: boolean;\n readonly button: number;\n readonly buttons: number;\n readonly clientX: number;\n readonly clientY: number;\n readonly ctrlKey: boolean;\n readonly fromElement: Element;\n readonly layerX: number;\n readonly layerY: number;\n readonly metaKey: boolean;\n readonly movementX: number;\n readonly movementY: number;\n readonly offsetX: number;\n readonly offsetY: number;\n readonly pageX: number;\n readonly pageY: number;\n readonly relatedTarget: EventTarget;\n readonly screenX: number;\n readonly screenY: number;\n readonly shiftKey: boolean;\n readonly toElement: Element;\n readonly which: number;\n readonly x: number;\n readonly y: number;\n getModifierState(keyArg: string): boolean;\n initMouseEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget | null): void;\n}\n\ndeclare var MouseEvent: {\n prototype: MouseEvent;\n new(typeArg: string, eventInitDict?: MouseEventInit): MouseEvent;\n}\n\ninterface MutationEvent extends Event {\n readonly attrChange: number;\n readonly attrName: string;\n readonly newValue: string;\n readonly prevValue: string;\n readonly relatedNode: Node;\n initMutationEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, relatedNodeArg: Node, prevValueArg: string, newValueArg: string, attrNameArg: string, attrChangeArg: number): void;\n readonly ADDITION: number;\n readonly MODIFICATION: number;\n readonly REMOVAL: number;\n}\n\ndeclare var MutationEvent: {\n prototype: MutationEvent;\n new(): MutationEvent;\n readonly ADDITION: number;\n readonly MODIFICATION: number;\n readonly REMOVAL: number;\n}\n\ninterface MutationObserver {\n disconnect(): void;\n observe(target: Node, options: MutationObserverInit): void;\n takeRecords(): MutationRecord[];\n}\n\ndeclare var MutationObserver: {\n prototype: MutationObserver;\n new(callback: MutationCallback): MutationObserver;\n}\n\ninterface MutationRecord {\n readonly addedNodes: NodeList;\n readonly attributeName: string | null;\n readonly attributeNamespace: string | null;\n readonly nextSibling: Node | null;\n readonly oldValue: string | null;\n readonly previousSibling: Node | null;\n readonly removedNodes: NodeList;\n readonly target: Node;\n readonly type: string;\n}\n\ndeclare var MutationRecord: {\n prototype: MutationRecord;\n new(): MutationRecord;\n}\n\ninterface NamedNodeMap {\n readonly length: number;\n getNamedItem(name: string): Attr;\n getNamedItemNS(namespaceURI: string | null, localName: string | null): Attr;\n item(index: number): Attr;\n removeNamedItem(name: string): Attr;\n removeNamedItemNS(namespaceURI: string | null, localName: string | null): Attr;\n setNamedItem(arg: Attr): Attr;\n setNamedItemNS(arg: Attr): Attr;\n [index: number]: Attr;\n}\n\ndeclare var NamedNodeMap: {\n prototype: NamedNodeMap;\n new(): NamedNodeMap;\n}\n\ninterface NavigationCompletedEvent extends NavigationEvent {\n readonly isSuccess: boolean;\n readonly webErrorStatus: number;\n}\n\ndeclare var NavigationCompletedEvent: {\n prototype: NavigationCompletedEvent;\n new(): NavigationCompletedEvent;\n}\n\ninterface NavigationEvent extends Event {\n readonly uri: string;\n}\n\ndeclare var NavigationEvent: {\n prototype: NavigationEvent;\n new(): NavigationEvent;\n}\n\ninterface NavigationEventWithReferrer extends NavigationEvent {\n readonly referer: string;\n}\n\ndeclare var NavigationEventWithReferrer: {\n prototype: NavigationEventWithReferrer;\n new(): NavigationEventWithReferrer;\n}\n\ninterface Navigator extends Object, NavigatorID, NavigatorOnLine, NavigatorContentUtils, NavigatorStorageUtils, NavigatorGeolocation, MSNavigatorDoNotTrack, MSFileSaver, NavigatorBeacon, NavigatorConcurrentHardware, NavigatorUserMedia {\n readonly authentication: WebAuthentication;\n readonly cookieEnabled: boolean;\n gamepadInputEmulation: GamepadInputEmulationType;\n readonly language: string;\n readonly maxTouchPoints: number;\n readonly mimeTypes: MimeTypeArray;\n readonly msManipulationViewsEnabled: boolean;\n readonly msMaxTouchPoints: number;\n readonly msPointerEnabled: boolean;\n readonly plugins: PluginArray;\n readonly pointerEnabled: boolean;\n readonly serviceWorker: ServiceWorkerContainer;\n readonly webdriver: boolean;\n readonly hardwareConcurrency: number;\n getGamepads(): Gamepad[];\n javaEnabled(): boolean;\n msLaunchUri(uri: string, successCallback?: MSLaunchUriCallback, noHandlerCallback?: MSLaunchUriCallback): void;\n requestMediaKeySystemAccess(keySystem: string, supportedConfigurations: MediaKeySystemConfiguration[]): Promise;\n vibrate(pattern: number | number[]): boolean;\n}\n\ndeclare var Navigator: {\n prototype: Navigator;\n new(): Navigator;\n}\n\ninterface Node extends EventTarget {\n readonly attributes: NamedNodeMap;\n readonly baseURI: string | null;\n readonly childNodes: NodeList;\n readonly firstChild: Node | null;\n readonly lastChild: Node | null;\n readonly localName: string | null;\n readonly namespaceURI: string | null;\n readonly nextSibling: Node | null;\n readonly nodeName: string;\n readonly nodeType: number;\n nodeValue: string | null;\n readonly ownerDocument: Document;\n readonly parentElement: HTMLElement | null;\n readonly parentNode: Node | null;\n readonly previousSibling: Node | null;\n textContent: string | null;\n appendChild(newChild: T): T;\n cloneNode(deep?: boolean): Node;\n compareDocumentPosition(other: Node): number;\n contains(child: Node): boolean;\n hasAttributes(): boolean;\n hasChildNodes(): boolean;\n insertBefore(newChild: T, refChild: Node | null): T;\n isDefaultNamespace(namespaceURI: string | null): boolean;\n isEqualNode(arg: Node): boolean;\n isSameNode(other: Node): boolean;\n lookupNamespaceURI(prefix: string | null): string | null;\n lookupPrefix(namespaceURI: string | null): string | null;\n normalize(): void;\n removeChild(oldChild: T): T;\n replaceChild(newChild: Node, oldChild: T): T;\n readonly ATTRIBUTE_NODE: number;\n readonly CDATA_SECTION_NODE: number;\n readonly COMMENT_NODE: number;\n readonly DOCUMENT_FRAGMENT_NODE: number;\n readonly DOCUMENT_NODE: number;\n readonly DOCUMENT_POSITION_CONTAINED_BY: number;\n readonly DOCUMENT_POSITION_CONTAINS: number;\n readonly DOCUMENT_POSITION_DISCONNECTED: number;\n readonly DOCUMENT_POSITION_FOLLOWING: number;\n readonly DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: number;\n readonly DOCUMENT_POSITION_PRECEDING: number;\n readonly DOCUMENT_TYPE_NODE: number;\n readonly ELEMENT_NODE: number;\n readonly ENTITY_NODE: number;\n readonly ENTITY_REFERENCE_NODE: number;\n readonly NOTATION_NODE: number;\n readonly PROCESSING_INSTRUCTION_NODE: number;\n readonly TEXT_NODE: number;\n}\n\ndeclare var Node: {\n prototype: Node;\n new(): Node;\n readonly ATTRIBUTE_NODE: number;\n readonly CDATA_SECTION_NODE: number;\n readonly COMMENT_NODE: number;\n readonly DOCUMENT_FRAGMENT_NODE: number;\n readonly DOCUMENT_NODE: number;\n readonly DOCUMENT_POSITION_CONTAINED_BY: number;\n readonly DOCUMENT_POSITION_CONTAINS: number;\n readonly DOCUMENT_POSITION_DISCONNECTED: number;\n readonly DOCUMENT_POSITION_FOLLOWING: number;\n readonly DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: number;\n readonly DOCUMENT_POSITION_PRECEDING: number;\n readonly DOCUMENT_TYPE_NODE: number;\n readonly ELEMENT_NODE: number;\n readonly ENTITY_NODE: number;\n readonly ENTITY_REFERENCE_NODE: number;\n readonly NOTATION_NODE: number;\n readonly PROCESSING_INSTRUCTION_NODE: number;\n readonly TEXT_NODE: number;\n}\n\ninterface NodeFilter {\n acceptNode(n: Node): number;\n}\n\ndeclare var NodeFilter: {\n readonly FILTER_ACCEPT: number;\n readonly FILTER_REJECT: number;\n readonly FILTER_SKIP: number;\n readonly SHOW_ALL: number;\n readonly SHOW_ATTRIBUTE: number;\n readonly SHOW_CDATA_SECTION: number;\n readonly SHOW_COMMENT: number;\n readonly SHOW_DOCUMENT: number;\n readonly SHOW_DOCUMENT_FRAGMENT: number;\n readonly SHOW_DOCUMENT_TYPE: number;\n readonly SHOW_ELEMENT: number;\n readonly SHOW_ENTITY: number;\n readonly SHOW_ENTITY_REFERENCE: number;\n readonly SHOW_NOTATION: number;\n readonly SHOW_PROCESSING_INSTRUCTION: number;\n readonly SHOW_TEXT: number;\n}\n\ninterface NodeIterator {\n readonly expandEntityReferences: boolean;\n readonly filter: NodeFilter;\n readonly root: Node;\n readonly whatToShow: number;\n detach(): void;\n nextNode(): Node;\n previousNode(): Node;\n}\n\ndeclare var NodeIterator: {\n prototype: NodeIterator;\n new(): NodeIterator;\n}\n\ninterface NodeList {\n readonly length: number;\n item(index: number): Node;\n [index: number]: Node;\n}\n\ndeclare var NodeList: {\n prototype: NodeList;\n new(): NodeList;\n}\n\ninterface NotificationEventMap {\n \"click\": Event;\n \"close\": Event;\n \"error\": Event;\n \"show\": Event;\n}\n\ninterface Notification extends EventTarget {\n readonly body: string;\n readonly dir: NotificationDirection;\n readonly icon: string;\n readonly lang: string;\n onclick: (this: Notification, ev: Event) => any;\n onclose: (this: Notification, ev: Event) => any;\n onerror: (this: Notification, ev: Event) => any;\n onshow: (this: Notification, ev: Event) => any;\n readonly permission: NotificationPermission;\n readonly tag: string;\n readonly title: string;\n close(): void;\n addEventListener(type: K, listener: (this: Notification, ev: NotificationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Notification: {\n prototype: Notification;\n new(title: string, options?: NotificationOptions): Notification;\n requestPermission(callback?: NotificationPermissionCallback): Promise;\n}\n\ninterface OES_element_index_uint {\n}\n\ndeclare var OES_element_index_uint: {\n prototype: OES_element_index_uint;\n new(): OES_element_index_uint;\n}\n\ninterface OES_standard_derivatives {\n readonly FRAGMENT_SHADER_DERIVATIVE_HINT_OES: number;\n}\n\ndeclare var OES_standard_derivatives: {\n prototype: OES_standard_derivatives;\n new(): OES_standard_derivatives;\n readonly FRAGMENT_SHADER_DERIVATIVE_HINT_OES: number;\n}\n\ninterface OES_texture_float {\n}\n\ndeclare var OES_texture_float: {\n prototype: OES_texture_float;\n new(): OES_texture_float;\n}\n\ninterface OES_texture_float_linear {\n}\n\ndeclare var OES_texture_float_linear: {\n prototype: OES_texture_float_linear;\n new(): OES_texture_float_linear;\n}\n\ninterface OES_texture_half_float {\n readonly HALF_FLOAT_OES: number;\n}\n\ndeclare var OES_texture_half_float: {\n prototype: OES_texture_half_float;\n new(): OES_texture_half_float;\n readonly HALF_FLOAT_OES: number;\n}\n\ninterface OES_texture_half_float_linear {\n}\n\ndeclare var OES_texture_half_float_linear: {\n prototype: OES_texture_half_float_linear;\n new(): OES_texture_half_float_linear;\n}\n\ninterface OfflineAudioCompletionEvent extends Event {\n readonly renderedBuffer: AudioBuffer;\n}\n\ndeclare var OfflineAudioCompletionEvent: {\n prototype: OfflineAudioCompletionEvent;\n new(): OfflineAudioCompletionEvent;\n}\n\ninterface OfflineAudioContextEventMap extends AudioContextEventMap {\n \"complete\": OfflineAudioCompletionEvent;\n}\n\ninterface OfflineAudioContext extends AudioContextBase {\n readonly length: number;\n oncomplete: (this: OfflineAudioContext, ev: OfflineAudioCompletionEvent) => any;\n startRendering(): Promise;\n suspend(suspendTime: number): Promise;\n addEventListener(type: K, listener: (this: OfflineAudioContext, ev: OfflineAudioContextEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var OfflineAudioContext: {\n prototype: OfflineAudioContext;\n new(numberOfChannels: number, length: number, sampleRate: number): OfflineAudioContext;\n}\n\ninterface OscillatorNodeEventMap {\n \"ended\": MediaStreamErrorEvent;\n}\n\ninterface OscillatorNode extends AudioNode {\n readonly detune: AudioParam;\n readonly frequency: AudioParam;\n onended: (this: OscillatorNode, ev: MediaStreamErrorEvent) => any;\n type: OscillatorType;\n setPeriodicWave(periodicWave: PeriodicWave): void;\n start(when?: number): void;\n stop(when?: number): void;\n addEventListener(type: K, listener: (this: OscillatorNode, ev: OscillatorNodeEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var OscillatorNode: {\n prototype: OscillatorNode;\n new(): OscillatorNode;\n}\n\ninterface OverflowEvent extends UIEvent {\n readonly horizontalOverflow: boolean;\n readonly orient: number;\n readonly verticalOverflow: boolean;\n readonly BOTH: number;\n readonly HORIZONTAL: number;\n readonly VERTICAL: number;\n}\n\ndeclare var OverflowEvent: {\n prototype: OverflowEvent;\n new(): OverflowEvent;\n readonly BOTH: number;\n readonly HORIZONTAL: number;\n readonly VERTICAL: number;\n}\n\ninterface PageTransitionEvent extends Event {\n readonly persisted: boolean;\n}\n\ndeclare var PageTransitionEvent: {\n prototype: PageTransitionEvent;\n new(): PageTransitionEvent;\n}\n\ninterface PannerNode extends AudioNode {\n coneInnerAngle: number;\n coneOuterAngle: number;\n coneOuterGain: number;\n distanceModel: DistanceModelType;\n maxDistance: number;\n panningModel: PanningModelType;\n refDistance: number;\n rolloffFactor: number;\n setOrientation(x: number, y: number, z: number): void;\n setPosition(x: number, y: number, z: number): void;\n setVelocity(x: number, y: number, z: number): void;\n}\n\ndeclare var PannerNode: {\n prototype: PannerNode;\n new(): PannerNode;\n}\n\ninterface Path2D extends Object, CanvasPathMethods {\n}\n\ndeclare var Path2D: {\n prototype: Path2D;\n new(path?: Path2D): Path2D;\n}\n\ninterface PaymentAddress {\n readonly addressLine: string[];\n readonly city: string;\n readonly country: string;\n readonly dependentLocality: string;\n readonly languageCode: string;\n readonly organization: string;\n readonly phone: string;\n readonly postalCode: string;\n readonly recipient: string;\n readonly region: string;\n readonly sortingCode: string;\n toJSON(): any;\n}\n\ndeclare var PaymentAddress: {\n prototype: PaymentAddress;\n new(): PaymentAddress;\n}\n\ninterface PaymentRequestEventMap {\n \"shippingaddresschange\": Event;\n \"shippingoptionchange\": Event;\n}\n\ninterface PaymentRequest extends EventTarget {\n onshippingaddresschange: (this: PaymentRequest, ev: Event) => any;\n onshippingoptionchange: (this: PaymentRequest, ev: Event) => any;\n readonly shippingAddress: PaymentAddress | null;\n readonly shippingOption: string | null;\n readonly shippingType: PaymentShippingType | null;\n abort(): Promise;\n show(): Promise;\n addEventListener(type: K, listener: (this: PaymentRequest, ev: PaymentRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var PaymentRequest: {\n prototype: PaymentRequest;\n new(methodData: PaymentMethodData[], details: PaymentDetails, options?: PaymentOptions): PaymentRequest;\n}\n\ninterface PaymentRequestUpdateEvent extends Event {\n updateWith(d: Promise): void;\n}\n\ndeclare var PaymentRequestUpdateEvent: {\n prototype: PaymentRequestUpdateEvent;\n new(type: string, eventInitDict?: PaymentRequestUpdateEventInit): PaymentRequestUpdateEvent;\n}\n\ninterface PaymentResponse {\n readonly details: any;\n readonly methodName: string;\n readonly payerEmail: string | null;\n readonly payerName: string | null;\n readonly payerPhone: string | null;\n readonly shippingAddress: PaymentAddress | null;\n readonly shippingOption: string | null;\n complete(result?: PaymentComplete): Promise;\n toJSON(): any;\n}\n\ndeclare var PaymentResponse: {\n prototype: PaymentResponse;\n new(): PaymentResponse;\n}\n\ninterface PerfWidgetExternal {\n readonly activeNetworkRequestCount: number;\n readonly averageFrameTime: number;\n readonly averagePaintTime: number;\n readonly extraInformationEnabled: boolean;\n readonly independentRenderingEnabled: boolean;\n readonly irDisablingContentString: string;\n readonly irStatusAvailable: boolean;\n readonly maxCpuSpeed: number;\n readonly paintRequestsPerSecond: number;\n readonly performanceCounter: number;\n readonly performanceCounterFrequency: number;\n addEventListener(eventType: string, callback: Function): void;\n getMemoryUsage(): number;\n getProcessCpuUsage(): number;\n getRecentCpuUsage(last: number | null): any;\n getRecentFrames(last: number | null): any;\n getRecentMemoryUsage(last: number | null): any;\n getRecentPaintRequests(last: number | null): any;\n removeEventListener(eventType: string, callback: Function): void;\n repositionWindow(x: number, y: number): void;\n resizeWindow(width: number, height: number): void;\n}\n\ndeclare var PerfWidgetExternal: {\n prototype: PerfWidgetExternal;\n new(): PerfWidgetExternal;\n}\n\ninterface Performance {\n readonly navigation: PerformanceNavigation;\n readonly timing: PerformanceTiming;\n clearMarks(markName?: string): void;\n clearMeasures(measureName?: string): void;\n clearResourceTimings(): void;\n getEntries(): any;\n getEntriesByName(name: string, entryType?: string): any;\n getEntriesByType(entryType: string): any;\n getMarks(markName?: string): any;\n getMeasures(measureName?: string): any;\n mark(markName: string): void;\n measure(measureName: string, startMarkName?: string, endMarkName?: string): void;\n now(): number;\n setResourceTimingBufferSize(maxSize: number): void;\n toJSON(): any;\n}\n\ndeclare var Performance: {\n prototype: Performance;\n new(): Performance;\n}\n\ninterface PerformanceEntry {\n readonly duration: number;\n readonly entryType: string;\n readonly name: string;\n readonly startTime: number;\n}\n\ndeclare var PerformanceEntry: {\n prototype: PerformanceEntry;\n new(): PerformanceEntry;\n}\n\ninterface PerformanceMark extends PerformanceEntry {\n}\n\ndeclare var PerformanceMark: {\n prototype: PerformanceMark;\n new(): PerformanceMark;\n}\n\ninterface PerformanceMeasure extends PerformanceEntry {\n}\n\ndeclare var PerformanceMeasure: {\n prototype: PerformanceMeasure;\n new(): PerformanceMeasure;\n}\n\ninterface PerformanceNavigation {\n readonly redirectCount: number;\n readonly type: number;\n toJSON(): any;\n readonly TYPE_BACK_FORWARD: number;\n readonly TYPE_NAVIGATE: number;\n readonly TYPE_RELOAD: number;\n readonly TYPE_RESERVED: number;\n}\n\ndeclare var PerformanceNavigation: {\n prototype: PerformanceNavigation;\n new(): PerformanceNavigation;\n readonly TYPE_BACK_FORWARD: number;\n readonly TYPE_NAVIGATE: number;\n readonly TYPE_RELOAD: number;\n readonly TYPE_RESERVED: number;\n}\n\ninterface PerformanceNavigationTiming extends PerformanceEntry {\n readonly connectEnd: number;\n readonly connectStart: number;\n readonly domComplete: number;\n readonly domContentLoadedEventEnd: number;\n readonly domContentLoadedEventStart: number;\n readonly domInteractive: number;\n readonly domLoading: number;\n readonly domainLookupEnd: number;\n readonly domainLookupStart: number;\n readonly fetchStart: number;\n readonly loadEventEnd: number;\n readonly loadEventStart: number;\n readonly navigationStart: number;\n readonly redirectCount: number;\n readonly redirectEnd: number;\n readonly redirectStart: number;\n readonly requestStart: number;\n readonly responseEnd: number;\n readonly responseStart: number;\n readonly type: NavigationType;\n readonly unloadEventEnd: number;\n readonly unloadEventStart: number;\n}\n\ndeclare var PerformanceNavigationTiming: {\n prototype: PerformanceNavigationTiming;\n new(): PerformanceNavigationTiming;\n}\n\ninterface PerformanceResourceTiming extends PerformanceEntry {\n readonly connectEnd: number;\n readonly connectStart: number;\n readonly domainLookupEnd: number;\n readonly domainLookupStart: number;\n readonly fetchStart: number;\n readonly initiatorType: string;\n readonly redirectEnd: number;\n readonly redirectStart: number;\n readonly requestStart: number;\n readonly responseEnd: number;\n readonly responseStart: number;\n}\n\ndeclare var PerformanceResourceTiming: {\n prototype: PerformanceResourceTiming;\n new(): PerformanceResourceTiming;\n}\n\ninterface PerformanceTiming {\n readonly connectEnd: number;\n readonly connectStart: number;\n readonly domComplete: number;\n readonly domContentLoadedEventEnd: number;\n readonly domContentLoadedEventStart: number;\n readonly domInteractive: number;\n readonly domLoading: number;\n readonly domainLookupEnd: number;\n readonly domainLookupStart: number;\n readonly fetchStart: number;\n readonly loadEventEnd: number;\n readonly loadEventStart: number;\n readonly msFirstPaint: number;\n readonly navigationStart: number;\n readonly redirectEnd: number;\n readonly redirectStart: number;\n readonly requestStart: number;\n readonly responseEnd: number;\n readonly responseStart: number;\n readonly unloadEventEnd: number;\n readonly unloadEventStart: number;\n readonly secureConnectionStart: number;\n toJSON(): any;\n}\n\ndeclare var PerformanceTiming: {\n prototype: PerformanceTiming;\n new(): PerformanceTiming;\n}\n\ninterface PeriodicWave {\n}\n\ndeclare var PeriodicWave: {\n prototype: PeriodicWave;\n new(): PeriodicWave;\n}\n\ninterface PermissionRequest extends DeferredPermissionRequest {\n readonly state: MSWebViewPermissionState;\n defer(): void;\n}\n\ndeclare var PermissionRequest: {\n prototype: PermissionRequest;\n new(): PermissionRequest;\n}\n\ninterface PermissionRequestedEvent extends Event {\n readonly permissionRequest: PermissionRequest;\n}\n\ndeclare var PermissionRequestedEvent: {\n prototype: PermissionRequestedEvent;\n new(): PermissionRequestedEvent;\n}\n\ninterface Plugin {\n readonly description: string;\n readonly filename: string;\n readonly length: number;\n readonly name: string;\n readonly version: string;\n item(index: number): MimeType;\n namedItem(type: string): MimeType;\n [index: number]: MimeType;\n}\n\ndeclare var Plugin: {\n prototype: Plugin;\n new(): Plugin;\n}\n\ninterface PluginArray {\n readonly length: number;\n item(index: number): Plugin;\n namedItem(name: string): Plugin;\n refresh(reload?: boolean): void;\n [index: number]: Plugin;\n}\n\ndeclare var PluginArray: {\n prototype: PluginArray;\n new(): PluginArray;\n}\n\ninterface PointerEvent extends MouseEvent {\n readonly currentPoint: any;\n readonly height: number;\n readonly hwTimestamp: number;\n readonly intermediatePoints: any;\n readonly isPrimary: boolean;\n readonly pointerId: number;\n readonly pointerType: any;\n readonly pressure: number;\n readonly rotation: number;\n readonly tiltX: number;\n readonly tiltY: number;\n readonly width: number;\n getCurrentPoint(element: Element): void;\n getIntermediatePoints(element: Element): void;\n initPointerEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget, offsetXArg: number, offsetYArg: number, widthArg: number, heightArg: number, pressure: number, rotation: number, tiltX: number, tiltY: number, pointerIdArg: number, pointerType: any, hwTimestampArg: number, isPrimary: boolean): void;\n}\n\ndeclare var PointerEvent: {\n prototype: PointerEvent;\n new(typeArg: string, eventInitDict?: PointerEventInit): PointerEvent;\n}\n\ninterface PopStateEvent extends Event {\n readonly state: any;\n initPopStateEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, stateArg: any): void;\n}\n\ndeclare var PopStateEvent: {\n prototype: PopStateEvent;\n new(typeArg: string, eventInitDict?: PopStateEventInit): PopStateEvent;\n}\n\ninterface Position {\n readonly coords: Coordinates;\n readonly timestamp: number;\n}\n\ndeclare var Position: {\n prototype: Position;\n new(): Position;\n}\n\ninterface PositionError {\n readonly code: number;\n readonly message: string;\n toString(): string;\n readonly PERMISSION_DENIED: number;\n readonly POSITION_UNAVAILABLE: number;\n readonly TIMEOUT: number;\n}\n\ndeclare var PositionError: {\n prototype: PositionError;\n new(): PositionError;\n readonly PERMISSION_DENIED: number;\n readonly POSITION_UNAVAILABLE: number;\n readonly TIMEOUT: number;\n}\n\ninterface ProcessingInstruction extends CharacterData {\n readonly target: string;\n}\n\ndeclare var ProcessingInstruction: {\n prototype: ProcessingInstruction;\n new(): ProcessingInstruction;\n}\n\ninterface ProgressEvent extends Event {\n readonly lengthComputable: boolean;\n readonly loaded: number;\n readonly total: number;\n initProgressEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, lengthComputableArg: boolean, loadedArg: number, totalArg: number): void;\n}\n\ndeclare var ProgressEvent: {\n prototype: ProgressEvent;\n new(type: string, eventInitDict?: ProgressEventInit): ProgressEvent;\n}\n\ninterface PushManager {\n getSubscription(): Promise;\n permissionState(options?: PushSubscriptionOptionsInit): Promise;\n subscribe(options?: PushSubscriptionOptionsInit): Promise;\n}\n\ndeclare var PushManager: {\n prototype: PushManager;\n new(): PushManager;\n}\n\ninterface PushSubscription {\n readonly endpoint: USVString;\n readonly options: PushSubscriptionOptions;\n getKey(name: PushEncryptionKeyName): ArrayBuffer | null;\n toJSON(): any;\n unsubscribe(): Promise;\n}\n\ndeclare var PushSubscription: {\n prototype: PushSubscription;\n new(): PushSubscription;\n}\n\ninterface PushSubscriptionOptions {\n readonly applicationServerKey: ArrayBuffer | null;\n readonly userVisibleOnly: boolean;\n}\n\ndeclare var PushSubscriptionOptions: {\n prototype: PushSubscriptionOptions;\n new(): PushSubscriptionOptions;\n}\n\ninterface RTCDTMFToneChangeEvent extends Event {\n readonly tone: string;\n}\n\ndeclare var RTCDTMFToneChangeEvent: {\n prototype: RTCDTMFToneChangeEvent;\n new(typeArg: string, eventInitDict: RTCDTMFToneChangeEventInit): RTCDTMFToneChangeEvent;\n}\n\ninterface RTCDtlsTransportEventMap {\n \"dtlsstatechange\": RTCDtlsTransportStateChangedEvent;\n \"error\": Event;\n}\n\ninterface RTCDtlsTransport extends RTCStatsProvider {\n ondtlsstatechange: ((this: RTCDtlsTransport, ev: RTCDtlsTransportStateChangedEvent) => any) | null;\n onerror: ((this: RTCDtlsTransport, ev: Event) => any) | null;\n readonly state: RTCDtlsTransportState;\n readonly transport: RTCIceTransport;\n getLocalParameters(): RTCDtlsParameters;\n getRemoteCertificates(): ArrayBuffer[];\n getRemoteParameters(): RTCDtlsParameters | null;\n start(remoteParameters: RTCDtlsParameters): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCDtlsTransport, ev: RTCDtlsTransportEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCDtlsTransport: {\n prototype: RTCDtlsTransport;\n new(transport: RTCIceTransport): RTCDtlsTransport;\n}\n\ninterface RTCDtlsTransportStateChangedEvent extends Event {\n readonly state: RTCDtlsTransportState;\n}\n\ndeclare var RTCDtlsTransportStateChangedEvent: {\n prototype: RTCDtlsTransportStateChangedEvent;\n new(): RTCDtlsTransportStateChangedEvent;\n}\n\ninterface RTCDtmfSenderEventMap {\n \"tonechange\": RTCDTMFToneChangeEvent;\n}\n\ninterface RTCDtmfSender extends EventTarget {\n readonly canInsertDTMF: boolean;\n readonly duration: number;\n readonly interToneGap: number;\n ontonechange: (this: RTCDtmfSender, ev: RTCDTMFToneChangeEvent) => any;\n readonly sender: RTCRtpSender;\n readonly toneBuffer: string;\n insertDTMF(tones: string, duration?: number, interToneGap?: number): void;\n addEventListener(type: K, listener: (this: RTCDtmfSender, ev: RTCDtmfSenderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCDtmfSender: {\n prototype: RTCDtmfSender;\n new(sender: RTCRtpSender): RTCDtmfSender;\n}\n\ninterface RTCIceCandidate {\n candidate: string | null;\n sdpMLineIndex: number | null;\n sdpMid: string | null;\n toJSON(): any;\n}\n\ndeclare var RTCIceCandidate: {\n prototype: RTCIceCandidate;\n new(candidateInitDict?: RTCIceCandidateInit): RTCIceCandidate;\n}\n\ninterface RTCIceCandidatePairChangedEvent extends Event {\n readonly pair: RTCIceCandidatePair;\n}\n\ndeclare var RTCIceCandidatePairChangedEvent: {\n prototype: RTCIceCandidatePairChangedEvent;\n new(): RTCIceCandidatePairChangedEvent;\n}\n\ninterface RTCIceGathererEventMap {\n \"error\": Event;\n \"localcandidate\": RTCIceGathererEvent;\n}\n\ninterface RTCIceGatherer extends RTCStatsProvider {\n readonly component: RTCIceComponent;\n onerror: ((this: RTCIceGatherer, ev: Event) => any) | null;\n onlocalcandidate: ((this: RTCIceGatherer, ev: RTCIceGathererEvent) => any) | null;\n createAssociatedGatherer(): RTCIceGatherer;\n getLocalCandidates(): RTCIceCandidateDictionary[];\n getLocalParameters(): RTCIceParameters;\n addEventListener(type: K, listener: (this: RTCIceGatherer, ev: RTCIceGathererEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCIceGatherer: {\n prototype: RTCIceGatherer;\n new(options: RTCIceGatherOptions): RTCIceGatherer;\n}\n\ninterface RTCIceGathererEvent extends Event {\n readonly candidate: RTCIceCandidateDictionary | RTCIceCandidateComplete;\n}\n\ndeclare var RTCIceGathererEvent: {\n prototype: RTCIceGathererEvent;\n new(): RTCIceGathererEvent;\n}\n\ninterface RTCIceTransportEventMap {\n \"candidatepairchange\": RTCIceCandidatePairChangedEvent;\n \"icestatechange\": RTCIceTransportStateChangedEvent;\n}\n\ninterface RTCIceTransport extends RTCStatsProvider {\n readonly component: RTCIceComponent;\n readonly iceGatherer: RTCIceGatherer | null;\n oncandidatepairchange: ((this: RTCIceTransport, ev: RTCIceCandidatePairChangedEvent) => any) | null;\n onicestatechange: ((this: RTCIceTransport, ev: RTCIceTransportStateChangedEvent) => any) | null;\n readonly role: RTCIceRole;\n readonly state: RTCIceTransportState;\n addRemoteCandidate(remoteCandidate: RTCIceCandidateDictionary | RTCIceCandidateComplete): void;\n createAssociatedTransport(): RTCIceTransport;\n getNominatedCandidatePair(): RTCIceCandidatePair | null;\n getRemoteCandidates(): RTCIceCandidateDictionary[];\n getRemoteParameters(): RTCIceParameters | null;\n setRemoteCandidates(remoteCandidates: RTCIceCandidateDictionary[]): void;\n start(gatherer: RTCIceGatherer, remoteParameters: RTCIceParameters, role?: RTCIceRole): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCIceTransport, ev: RTCIceTransportEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCIceTransport: {\n prototype: RTCIceTransport;\n new(): RTCIceTransport;\n}\n\ninterface RTCIceTransportStateChangedEvent extends Event {\n readonly state: RTCIceTransportState;\n}\n\ndeclare var RTCIceTransportStateChangedEvent: {\n prototype: RTCIceTransportStateChangedEvent;\n new(): RTCIceTransportStateChangedEvent;\n}\n\ninterface RTCPeerConnectionEventMap {\n \"addstream\": MediaStreamEvent;\n \"icecandidate\": RTCPeerConnectionIceEvent;\n \"iceconnectionstatechange\": Event;\n \"icegatheringstatechange\": Event;\n \"negotiationneeded\": Event;\n \"removestream\": MediaStreamEvent;\n \"signalingstatechange\": Event;\n}\n\ninterface RTCPeerConnection extends EventTarget {\n readonly canTrickleIceCandidates: boolean | null;\n readonly iceConnectionState: RTCIceConnectionState;\n readonly iceGatheringState: RTCIceGatheringState;\n readonly localDescription: RTCSessionDescription | null;\n onaddstream: (this: RTCPeerConnection, ev: MediaStreamEvent) => any;\n onicecandidate: (this: RTCPeerConnection, ev: RTCPeerConnectionIceEvent) => any;\n oniceconnectionstatechange: (this: RTCPeerConnection, ev: Event) => any;\n onicegatheringstatechange: (this: RTCPeerConnection, ev: Event) => any;\n onnegotiationneeded: (this: RTCPeerConnection, ev: Event) => any;\n onremovestream: (this: RTCPeerConnection, ev: MediaStreamEvent) => any;\n onsignalingstatechange: (this: RTCPeerConnection, ev: Event) => any;\n readonly remoteDescription: RTCSessionDescription | null;\n readonly signalingState: RTCSignalingState;\n addIceCandidate(candidate: RTCIceCandidate, successCallback?: VoidFunction, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n addStream(stream: MediaStream): void;\n close(): void;\n createAnswer(successCallback?: RTCSessionDescriptionCallback, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n createOffer(successCallback?: RTCSessionDescriptionCallback, failureCallback?: RTCPeerConnectionErrorCallback, options?: RTCOfferOptions): Promise;\n getConfiguration(): RTCConfiguration;\n getLocalStreams(): MediaStream[];\n getRemoteStreams(): MediaStream[];\n getStats(selector: MediaStreamTrack | null, successCallback?: RTCStatsCallback, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n getStreamById(streamId: string): MediaStream | null;\n removeStream(stream: MediaStream): void;\n setLocalDescription(description: RTCSessionDescription, successCallback?: VoidFunction, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n setRemoteDescription(description: RTCSessionDescription, successCallback?: VoidFunction, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n addEventListener(type: K, listener: (this: RTCPeerConnection, ev: RTCPeerConnectionEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCPeerConnection: {\n prototype: RTCPeerConnection;\n new(configuration: RTCConfiguration): RTCPeerConnection;\n}\n\ninterface RTCPeerConnectionIceEvent extends Event {\n readonly candidate: RTCIceCandidate;\n}\n\ndeclare var RTCPeerConnectionIceEvent: {\n prototype: RTCPeerConnectionIceEvent;\n new(type: string, eventInitDict: RTCPeerConnectionIceEventInit): RTCPeerConnectionIceEvent;\n}\n\ninterface RTCRtpReceiverEventMap {\n \"error\": Event;\n}\n\ninterface RTCRtpReceiver extends RTCStatsProvider {\n onerror: ((this: RTCRtpReceiver, ev: Event) => any) | null;\n readonly rtcpTransport: RTCDtlsTransport;\n readonly track: MediaStreamTrack | null;\n readonly transport: RTCDtlsTransport | RTCSrtpSdesTransport;\n getContributingSources(): RTCRtpContributingSource[];\n receive(parameters: RTCRtpParameters): void;\n requestSendCSRC(csrc: number): void;\n setTransport(transport: RTCDtlsTransport | RTCSrtpSdesTransport, rtcpTransport?: RTCDtlsTransport): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCRtpReceiver, ev: RTCRtpReceiverEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCRtpReceiver: {\n prototype: RTCRtpReceiver;\n new(transport: RTCDtlsTransport | RTCSrtpSdesTransport, kind: string, rtcpTransport?: RTCDtlsTransport): RTCRtpReceiver;\n getCapabilities(kind?: string): RTCRtpCapabilities;\n}\n\ninterface RTCRtpSenderEventMap {\n \"error\": Event;\n \"ssrcconflict\": RTCSsrcConflictEvent;\n}\n\ninterface RTCRtpSender extends RTCStatsProvider {\n onerror: ((this: RTCRtpSender, ev: Event) => any) | null;\n onssrcconflict: ((this: RTCRtpSender, ev: RTCSsrcConflictEvent) => any) | null;\n readonly rtcpTransport: RTCDtlsTransport;\n readonly track: MediaStreamTrack;\n readonly transport: RTCDtlsTransport | RTCSrtpSdesTransport;\n send(parameters: RTCRtpParameters): void;\n setTrack(track: MediaStreamTrack): void;\n setTransport(transport: RTCDtlsTransport | RTCSrtpSdesTransport, rtcpTransport?: RTCDtlsTransport): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCRtpSender, ev: RTCRtpSenderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCRtpSender: {\n prototype: RTCRtpSender;\n new(track: MediaStreamTrack, transport: RTCDtlsTransport | RTCSrtpSdesTransport, rtcpTransport?: RTCDtlsTransport): RTCRtpSender;\n getCapabilities(kind?: string): RTCRtpCapabilities;\n}\n\ninterface RTCSessionDescription {\n sdp: string | null;\n type: RTCSdpType | null;\n toJSON(): any;\n}\n\ndeclare var RTCSessionDescription: {\n prototype: RTCSessionDescription;\n new(descriptionInitDict?: RTCSessionDescriptionInit): RTCSessionDescription;\n}\n\ninterface RTCSrtpSdesTransportEventMap {\n \"error\": Event;\n}\n\ninterface RTCSrtpSdesTransport extends EventTarget {\n onerror: ((this: RTCSrtpSdesTransport, ev: Event) => any) | null;\n readonly transport: RTCIceTransport;\n addEventListener(type: K, listener: (this: RTCSrtpSdesTransport, ev: RTCSrtpSdesTransportEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCSrtpSdesTransport: {\n prototype: RTCSrtpSdesTransport;\n new(transport: RTCIceTransport, encryptParameters: RTCSrtpSdesParameters, decryptParameters: RTCSrtpSdesParameters): RTCSrtpSdesTransport;\n getLocalParameters(): RTCSrtpSdesParameters[];\n}\n\ninterface RTCSsrcConflictEvent extends Event {\n readonly ssrc: number;\n}\n\ndeclare var RTCSsrcConflictEvent: {\n prototype: RTCSsrcConflictEvent;\n new(): RTCSsrcConflictEvent;\n}\n\ninterface RTCStatsProvider extends EventTarget {\n getStats(): Promise;\n msGetStats(): Promise;\n}\n\ndeclare var RTCStatsProvider: {\n prototype: RTCStatsProvider;\n new(): RTCStatsProvider;\n}\n\ninterface Range {\n readonly collapsed: boolean;\n readonly commonAncestorContainer: Node;\n readonly endContainer: Node;\n readonly endOffset: number;\n readonly startContainer: Node;\n readonly startOffset: number;\n cloneContents(): DocumentFragment;\n cloneRange(): Range;\n collapse(toStart: boolean): void;\n compareBoundaryPoints(how: number, sourceRange: Range): number;\n createContextualFragment(fragment: string): DocumentFragment;\n deleteContents(): void;\n detach(): void;\n expand(Unit: ExpandGranularity): boolean;\n extractContents(): DocumentFragment;\n getBoundingClientRect(): ClientRect;\n getClientRects(): ClientRectList;\n insertNode(newNode: Node): void;\n selectNode(refNode: Node): void;\n selectNodeContents(refNode: Node): void;\n setEnd(refNode: Node, offset: number): void;\n setEndAfter(refNode: Node): void;\n setEndBefore(refNode: Node): void;\n setStart(refNode: Node, offset: number): void;\n setStartAfter(refNode: Node): void;\n setStartBefore(refNode: Node): void;\n surroundContents(newParent: Node): void;\n toString(): string;\n readonly END_TO_END: number;\n readonly END_TO_START: number;\n readonly START_TO_END: number;\n readonly START_TO_START: number;\n}\n\ndeclare var Range: {\n prototype: Range;\n new(): Range;\n readonly END_TO_END: number;\n readonly END_TO_START: number;\n readonly START_TO_END: number;\n readonly START_TO_START: number;\n}\n\ninterface ReadableStream {\n readonly locked: boolean;\n cancel(): Promise;\n getReader(): ReadableStreamReader;\n}\n\ndeclare var ReadableStream: {\n prototype: ReadableStream;\n new(): ReadableStream;\n}\n\ninterface ReadableStreamReader {\n cancel(): Promise;\n read(): Promise;\n releaseLock(): void;\n}\n\ndeclare var ReadableStreamReader: {\n prototype: ReadableStreamReader;\n new(): ReadableStreamReader;\n}\n\ninterface Request extends Object, Body {\n readonly cache: RequestCache;\n readonly credentials: RequestCredentials;\n readonly destination: RequestDestination;\n readonly headers: Headers;\n readonly integrity: string;\n readonly keepalive: boolean;\n readonly method: string;\n readonly mode: RequestMode;\n readonly redirect: RequestRedirect;\n readonly referrer: string;\n readonly referrerPolicy: ReferrerPolicy;\n readonly type: RequestType;\n readonly url: string;\n clone(): Request;\n}\n\ndeclare var Request: {\n prototype: Request;\n new(input: Request | string, init?: RequestInit): Request;\n}\n\ninterface Response extends Object, Body {\n readonly body: ReadableStream | null;\n readonly headers: Headers;\n readonly ok: boolean;\n readonly status: number;\n readonly statusText: string;\n readonly type: ResponseType;\n readonly url: string;\n clone(): Response;\n}\n\ndeclare var Response: {\n prototype: Response;\n new(body?: any, init?: ResponseInit): Response;\n}\n\ninterface SVGAElement extends SVGGraphicsElement, SVGURIReference {\n readonly target: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGAElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGAElement: {\n prototype: SVGAElement;\n new(): SVGAElement;\n}\n\ninterface SVGAngle {\n readonly unitType: number;\n value: number;\n valueAsString: string;\n valueInSpecifiedUnits: number;\n convertToSpecifiedUnits(unitType: number): void;\n newValueSpecifiedUnits(unitType: number, valueInSpecifiedUnits: number): void;\n readonly SVG_ANGLETYPE_DEG: number;\n readonly SVG_ANGLETYPE_GRAD: number;\n readonly SVG_ANGLETYPE_RAD: number;\n readonly SVG_ANGLETYPE_UNKNOWN: number;\n readonly SVG_ANGLETYPE_UNSPECIFIED: number;\n}\n\ndeclare var SVGAngle: {\n prototype: SVGAngle;\n new(): SVGAngle;\n readonly SVG_ANGLETYPE_DEG: number;\n readonly SVG_ANGLETYPE_GRAD: number;\n readonly SVG_ANGLETYPE_RAD: number;\n readonly SVG_ANGLETYPE_UNKNOWN: number;\n readonly SVG_ANGLETYPE_UNSPECIFIED: number;\n}\n\ninterface SVGAnimatedAngle {\n readonly animVal: SVGAngle;\n readonly baseVal: SVGAngle;\n}\n\ndeclare var SVGAnimatedAngle: {\n prototype: SVGAnimatedAngle;\n new(): SVGAnimatedAngle;\n}\n\ninterface SVGAnimatedBoolean {\n readonly animVal: boolean;\n baseVal: boolean;\n}\n\ndeclare var SVGAnimatedBoolean: {\n prototype: SVGAnimatedBoolean;\n new(): SVGAnimatedBoolean;\n}\n\ninterface SVGAnimatedEnumeration {\n readonly animVal: number;\n baseVal: number;\n}\n\ndeclare var SVGAnimatedEnumeration: {\n prototype: SVGAnimatedEnumeration;\n new(): SVGAnimatedEnumeration;\n}\n\ninterface SVGAnimatedInteger {\n readonly animVal: number;\n baseVal: number;\n}\n\ndeclare var SVGAnimatedInteger: {\n prototype: SVGAnimatedInteger;\n new(): SVGAnimatedInteger;\n}\n\ninterface SVGAnimatedLength {\n readonly animVal: SVGLength;\n readonly baseVal: SVGLength;\n}\n\ndeclare var SVGAnimatedLength: {\n prototype: SVGAnimatedLength;\n new(): SVGAnimatedLength;\n}\n\ninterface SVGAnimatedLengthList {\n readonly animVal: SVGLengthList;\n readonly baseVal: SVGLengthList;\n}\n\ndeclare var SVGAnimatedLengthList: {\n prototype: SVGAnimatedLengthList;\n new(): SVGAnimatedLengthList;\n}\n\ninterface SVGAnimatedNumber {\n readonly animVal: number;\n baseVal: number;\n}\n\ndeclare var SVGAnimatedNumber: {\n prototype: SVGAnimatedNumber;\n new(): SVGAnimatedNumber;\n}\n\ninterface SVGAnimatedNumberList {\n readonly animVal: SVGNumberList;\n readonly baseVal: SVGNumberList;\n}\n\ndeclare var SVGAnimatedNumberList: {\n prototype: SVGAnimatedNumberList;\n new(): SVGAnimatedNumberList;\n}\n\ninterface SVGAnimatedPreserveAspectRatio {\n readonly animVal: SVGPreserveAspectRatio;\n readonly baseVal: SVGPreserveAspectRatio;\n}\n\ndeclare var SVGAnimatedPreserveAspectRatio: {\n prototype: SVGAnimatedPreserveAspectRatio;\n new(): SVGAnimatedPreserveAspectRatio;\n}\n\ninterface SVGAnimatedRect {\n readonly animVal: SVGRect;\n readonly baseVal: SVGRect;\n}\n\ndeclare var SVGAnimatedRect: {\n prototype: SVGAnimatedRect;\n new(): SVGAnimatedRect;\n}\n\ninterface SVGAnimatedString {\n readonly animVal: string;\n baseVal: string;\n}\n\ndeclare var SVGAnimatedString: {\n prototype: SVGAnimatedString;\n new(): SVGAnimatedString;\n}\n\ninterface SVGAnimatedTransformList {\n readonly animVal: SVGTransformList;\n readonly baseVal: SVGTransformList;\n}\n\ndeclare var SVGAnimatedTransformList: {\n prototype: SVGAnimatedTransformList;\n new(): SVGAnimatedTransformList;\n}\n\ninterface SVGCircleElement extends SVGGraphicsElement {\n readonly cx: SVGAnimatedLength;\n readonly cy: SVGAnimatedLength;\n readonly r: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGCircleElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGCircleElement: {\n prototype: SVGCircleElement;\n new(): SVGCircleElement;\n}\n\ninterface SVGClipPathElement extends SVGGraphicsElement, SVGUnitTypes {\n readonly clipPathUnits: SVGAnimatedEnumeration;\n addEventListener(type: K, listener: (this: SVGClipPathElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGClipPathElement: {\n prototype: SVGClipPathElement;\n new(): SVGClipPathElement;\n}\n\ninterface SVGComponentTransferFunctionElement extends SVGElement {\n readonly amplitude: SVGAnimatedNumber;\n readonly exponent: SVGAnimatedNumber;\n readonly intercept: SVGAnimatedNumber;\n readonly offset: SVGAnimatedNumber;\n readonly slope: SVGAnimatedNumber;\n readonly tableValues: SVGAnimatedNumberList;\n readonly type: SVGAnimatedEnumeration;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_DISCRETE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_GAMMA: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_IDENTITY: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_LINEAR: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_TABLE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGComponentTransferFunctionElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGComponentTransferFunctionElement: {\n prototype: SVGComponentTransferFunctionElement;\n new(): SVGComponentTransferFunctionElement;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_DISCRETE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_GAMMA: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_IDENTITY: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_LINEAR: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_TABLE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_UNKNOWN: number;\n}\n\ninterface SVGDefsElement extends SVGGraphicsElement {\n addEventListener(type: K, listener: (this: SVGDefsElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGDefsElement: {\n prototype: SVGDefsElement;\n new(): SVGDefsElement;\n}\n\ninterface SVGDescElement extends SVGElement {\n addEventListener(type: K, listener: (this: SVGDescElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGDescElement: {\n prototype: SVGDescElement;\n new(): SVGDescElement;\n}\n\ninterface SVGElementEventMap extends ElementEventMap {\n \"click\": MouseEvent;\n \"dblclick\": MouseEvent;\n \"focusin\": FocusEvent;\n \"focusout\": FocusEvent;\n \"load\": Event;\n \"mousedown\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n}\n\ninterface SVGElement extends Element {\n className: any;\n onclick: (this: SVGElement, ev: MouseEvent) => any;\n ondblclick: (this: SVGElement, ev: MouseEvent) => any;\n onfocusin: (this: SVGElement, ev: FocusEvent) => any;\n onfocusout: (this: SVGElement, ev: FocusEvent) => any;\n onload: (this: SVGElement, ev: Event) => any;\n onmousedown: (this: SVGElement, ev: MouseEvent) => any;\n onmousemove: (this: SVGElement, ev: MouseEvent) => any;\n onmouseout: (this: SVGElement, ev: MouseEvent) => any;\n onmouseover: (this: SVGElement, ev: MouseEvent) => any;\n onmouseup: (this: SVGElement, ev: MouseEvent) => any;\n readonly ownerSVGElement: SVGSVGElement;\n readonly style: CSSStyleDeclaration;\n readonly viewportElement: SVGElement;\n xmlbase: string;\n addEventListener(type: K, listener: (this: SVGElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGElement: {\n prototype: SVGElement;\n new(): SVGElement;\n}\n\ninterface SVGElementInstance extends EventTarget {\n readonly childNodes: SVGElementInstanceList;\n readonly correspondingElement: SVGElement;\n readonly correspondingUseElement: SVGUseElement;\n readonly firstChild: SVGElementInstance;\n readonly lastChild: SVGElementInstance;\n readonly nextSibling: SVGElementInstance;\n readonly parentNode: SVGElementInstance;\n readonly previousSibling: SVGElementInstance;\n}\n\ndeclare var SVGElementInstance: {\n prototype: SVGElementInstance;\n new(): SVGElementInstance;\n}\n\ninterface SVGElementInstanceList {\n readonly length: number;\n item(index: number): SVGElementInstance;\n}\n\ndeclare var SVGElementInstanceList: {\n prototype: SVGElementInstanceList;\n new(): SVGElementInstanceList;\n}\n\ninterface SVGEllipseElement extends SVGGraphicsElement {\n readonly cx: SVGAnimatedLength;\n readonly cy: SVGAnimatedLength;\n readonly rx: SVGAnimatedLength;\n readonly ry: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGEllipseElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGEllipseElement: {\n prototype: SVGEllipseElement;\n new(): SVGEllipseElement;\n}\n\ninterface SVGFEBlendElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly in2: SVGAnimatedString;\n readonly mode: SVGAnimatedEnumeration;\n readonly SVG_FEBLEND_MODE_COLOR: number;\n readonly SVG_FEBLEND_MODE_COLOR_BURN: number;\n readonly SVG_FEBLEND_MODE_COLOR_DODGE: number;\n readonly SVG_FEBLEND_MODE_DARKEN: number;\n readonly SVG_FEBLEND_MODE_DIFFERENCE: number;\n readonly SVG_FEBLEND_MODE_EXCLUSION: number;\n readonly SVG_FEBLEND_MODE_HARD_LIGHT: number;\n readonly SVG_FEBLEND_MODE_HUE: number;\n readonly SVG_FEBLEND_MODE_LIGHTEN: number;\n readonly SVG_FEBLEND_MODE_LUMINOSITY: number;\n readonly SVG_FEBLEND_MODE_MULTIPLY: number;\n readonly SVG_FEBLEND_MODE_NORMAL: number;\n readonly SVG_FEBLEND_MODE_OVERLAY: number;\n readonly SVG_FEBLEND_MODE_SATURATION: number;\n readonly SVG_FEBLEND_MODE_SCREEN: number;\n readonly SVG_FEBLEND_MODE_SOFT_LIGHT: number;\n readonly SVG_FEBLEND_MODE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEBlendElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEBlendElement: {\n prototype: SVGFEBlendElement;\n new(): SVGFEBlendElement;\n readonly SVG_FEBLEND_MODE_COLOR: number;\n readonly SVG_FEBLEND_MODE_COLOR_BURN: number;\n readonly SVG_FEBLEND_MODE_COLOR_DODGE: number;\n readonly SVG_FEBLEND_MODE_DARKEN: number;\n readonly SVG_FEBLEND_MODE_DIFFERENCE: number;\n readonly SVG_FEBLEND_MODE_EXCLUSION: number;\n readonly SVG_FEBLEND_MODE_HARD_LIGHT: number;\n readonly SVG_FEBLEND_MODE_HUE: number;\n readonly SVG_FEBLEND_MODE_LIGHTEN: number;\n readonly SVG_FEBLEND_MODE_LUMINOSITY: number;\n readonly SVG_FEBLEND_MODE_MULTIPLY: number;\n readonly SVG_FEBLEND_MODE_NORMAL: number;\n readonly SVG_FEBLEND_MODE_OVERLAY: number;\n readonly SVG_FEBLEND_MODE_SATURATION: number;\n readonly SVG_FEBLEND_MODE_SCREEN: number;\n readonly SVG_FEBLEND_MODE_SOFT_LIGHT: number;\n readonly SVG_FEBLEND_MODE_UNKNOWN: number;\n}\n\ninterface SVGFEColorMatrixElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly type: SVGAnimatedEnumeration;\n readonly values: SVGAnimatedNumberList;\n readonly SVG_FECOLORMATRIX_TYPE_HUEROTATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_LUMINANCETOALPHA: number;\n readonly SVG_FECOLORMATRIX_TYPE_MATRIX: number;\n readonly SVG_FECOLORMATRIX_TYPE_SATURATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEColorMatrixElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEColorMatrixElement: {\n prototype: SVGFEColorMatrixElement;\n new(): SVGFEColorMatrixElement;\n readonly SVG_FECOLORMATRIX_TYPE_HUEROTATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_LUMINANCETOALPHA: number;\n readonly SVG_FECOLORMATRIX_TYPE_MATRIX: number;\n readonly SVG_FECOLORMATRIX_TYPE_SATURATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_UNKNOWN: number;\n}\n\ninterface SVGFEComponentTransferElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFEComponentTransferElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEComponentTransferElement: {\n prototype: SVGFEComponentTransferElement;\n new(): SVGFEComponentTransferElement;\n}\n\ninterface SVGFECompositeElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly in2: SVGAnimatedString;\n readonly k1: SVGAnimatedNumber;\n readonly k2: SVGAnimatedNumber;\n readonly k3: SVGAnimatedNumber;\n readonly k4: SVGAnimatedNumber;\n readonly operator: SVGAnimatedEnumeration;\n readonly SVG_FECOMPOSITE_OPERATOR_ARITHMETIC: number;\n readonly SVG_FECOMPOSITE_OPERATOR_ATOP: number;\n readonly SVG_FECOMPOSITE_OPERATOR_IN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OUT: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OVER: number;\n readonly SVG_FECOMPOSITE_OPERATOR_UNKNOWN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_XOR: number;\n addEventListener(type: K, listener: (this: SVGFECompositeElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFECompositeElement: {\n prototype: SVGFECompositeElement;\n new(): SVGFECompositeElement;\n readonly SVG_FECOMPOSITE_OPERATOR_ARITHMETIC: number;\n readonly SVG_FECOMPOSITE_OPERATOR_ATOP: number;\n readonly SVG_FECOMPOSITE_OPERATOR_IN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OUT: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OVER: number;\n readonly SVG_FECOMPOSITE_OPERATOR_UNKNOWN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_XOR: number;\n}\n\ninterface SVGFEConvolveMatrixElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly bias: SVGAnimatedNumber;\n readonly divisor: SVGAnimatedNumber;\n readonly edgeMode: SVGAnimatedEnumeration;\n readonly in1: SVGAnimatedString;\n readonly kernelMatrix: SVGAnimatedNumberList;\n readonly kernelUnitLengthX: SVGAnimatedNumber;\n readonly kernelUnitLengthY: SVGAnimatedNumber;\n readonly orderX: SVGAnimatedInteger;\n readonly orderY: SVGAnimatedInteger;\n readonly preserveAlpha: SVGAnimatedBoolean;\n readonly targetX: SVGAnimatedInteger;\n readonly targetY: SVGAnimatedInteger;\n readonly SVG_EDGEMODE_DUPLICATE: number;\n readonly SVG_EDGEMODE_NONE: number;\n readonly SVG_EDGEMODE_UNKNOWN: number;\n readonly SVG_EDGEMODE_WRAP: number;\n addEventListener(type: K, listener: (this: SVGFEConvolveMatrixElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEConvolveMatrixElement: {\n prototype: SVGFEConvolveMatrixElement;\n new(): SVGFEConvolveMatrixElement;\n readonly SVG_EDGEMODE_DUPLICATE: number;\n readonly SVG_EDGEMODE_NONE: number;\n readonly SVG_EDGEMODE_UNKNOWN: number;\n readonly SVG_EDGEMODE_WRAP: number;\n}\n\ninterface SVGFEDiffuseLightingElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly diffuseConstant: SVGAnimatedNumber;\n readonly in1: SVGAnimatedString;\n readonly kernelUnitLengthX: SVGAnimatedNumber;\n readonly kernelUnitLengthY: SVGAnimatedNumber;\n readonly surfaceScale: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFEDiffuseLightingElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEDiffuseLightingElement: {\n prototype: SVGFEDiffuseLightingElement;\n new(): SVGFEDiffuseLightingElement;\n}\n\ninterface SVGFEDisplacementMapElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly in2: SVGAnimatedString;\n readonly scale: SVGAnimatedNumber;\n readonly xChannelSelector: SVGAnimatedEnumeration;\n readonly yChannelSelector: SVGAnimatedEnumeration;\n readonly SVG_CHANNEL_A: number;\n readonly SVG_CHANNEL_B: number;\n readonly SVG_CHANNEL_G: number;\n readonly SVG_CHANNEL_R: number;\n readonly SVG_CHANNEL_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEDisplacementMapElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEDisplacementMapElement: {\n prototype: SVGFEDisplacementMapElement;\n new(): SVGFEDisplacementMapElement;\n readonly SVG_CHANNEL_A: number;\n readonly SVG_CHANNEL_B: number;\n readonly SVG_CHANNEL_G: number;\n readonly SVG_CHANNEL_R: number;\n readonly SVG_CHANNEL_UNKNOWN: number;\n}\n\ninterface SVGFEDistantLightElement extends SVGElement {\n readonly azimuth: SVGAnimatedNumber;\n readonly elevation: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFEDistantLightElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEDistantLightElement: {\n prototype: SVGFEDistantLightElement;\n new(): SVGFEDistantLightElement;\n}\n\ninterface SVGFEFloodElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n addEventListener(type: K, listener: (this: SVGFEFloodElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFloodElement: {\n prototype: SVGFEFloodElement;\n new(): SVGFEFloodElement;\n}\n\ninterface SVGFEFuncAElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncAElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncAElement: {\n prototype: SVGFEFuncAElement;\n new(): SVGFEFuncAElement;\n}\n\ninterface SVGFEFuncBElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncBElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncBElement: {\n prototype: SVGFEFuncBElement;\n new(): SVGFEFuncBElement;\n}\n\ninterface SVGFEFuncGElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncGElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncGElement: {\n prototype: SVGFEFuncGElement;\n new(): SVGFEFuncGElement;\n}\n\ninterface SVGFEFuncRElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncRElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncRElement: {\n prototype: SVGFEFuncRElement;\n new(): SVGFEFuncRElement;\n}\n\ninterface SVGFEGaussianBlurElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly stdDeviationX: SVGAnimatedNumber;\n readonly stdDeviationY: SVGAnimatedNumber;\n setStdDeviation(stdDeviationX: number, stdDeviationY: number): void;\n addEventListener(type: K, listener: (this: SVGFEGaussianBlurElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEGaussianBlurElement: {\n prototype: SVGFEGaussianBlurElement;\n new(): SVGFEGaussianBlurElement;\n}\n\ninterface SVGFEImageElement extends SVGElement, SVGFilterPrimitiveStandardAttributes, SVGURIReference {\n readonly preserveAspectRatio: SVGAnimatedPreserveAspectRatio;\n addEventListener(type: K, listener: (this: SVGFEImageElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEImageElement: {\n prototype: SVGFEImageElement;\n new(): SVGFEImageElement;\n}\n\ninterface SVGFEMergeElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n addEventListener(type: K, listener: (this: SVGFEMergeElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEMergeElement: {\n prototype: SVGFEMergeElement;\n new(): SVGFEMergeElement;\n}\n\ninterface SVGFEMergeNodeElement extends SVGElement {\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFEMergeNodeElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEMergeNodeElement: {\n prototype: SVGFEMergeNodeElement;\n new(): SVGFEMergeNodeElement;\n}\n\ninterface SVGFEMorphologyElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly operator: SVGAnimatedEnumeration;\n readonly radiusX: SVGAnimatedNumber;\n readonly radiusY: SVGAnimatedNumber;\n readonly SVG_MORPHOLOGY_OPERATOR_DILATE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_ERODE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEMorphologyElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEMorphologyElement: {\n prototype: SVGFEMorphologyElement;\n new(): SVGFEMorphologyElement;\n readonly SVG_MORPHOLOGY_OPERATOR_DILATE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_ERODE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_UNKNOWN: number;\n}\n\ninterface SVGFEOffsetElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly dx: SVGAnimatedNumber;\n readonly dy: SVGAnimatedNumber;\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFEOffsetElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEOffsetElement: {\n prototype: SVGFEOffsetElement;\n new(): SVGFEOffsetElement;\n}\n\ninterface SVGFEPointLightElement extends SVGElement {\n readonly x: SVGAnimatedNumber;\n readonly y: SVGAnimatedNumber;\n readonly z: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFEPointLightElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEPointLightElement: {\n prototype: SVGFEPointLightElement;\n new(): SVGFEPointLightElement;\n}\n\ninterface SVGFESpecularLightingElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly kernelUnitLengthX: SVGAnimatedNumber;\n readonly kernelUnitLengthY: SVGAnimatedNumber;\n readonly specularConstant: SVGAnimatedNumber;\n readonly specularExponent: SVGAnimatedNumber;\n readonly surfaceScale: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFESpecularLightingElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFESpecularLightingElement: {\n prototype: SVGFESpecularLightingElement;\n new(): SVGFESpecularLightingElement;\n}\n\ninterface SVGFESpotLightElement extends SVGElement {\n readonly limitingConeAngle: SVGAnimatedNumber;\n readonly pointsAtX: SVGAnimatedNumber;\n readonly pointsAtY: SVGAnimatedNumber;\n readonly pointsAtZ: SVGAnimatedNumber;\n readonly specularExponent: SVGAnimatedNumber;\n readonly x: SVGAnimatedNumber;\n readonly y: SVGAnimatedNumber;\n readonly z: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFESpotLightElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFESpotLightElement: {\n prototype: SVGFESpotLightElement;\n new(): SVGFESpotLightElement;\n}\n\ninterface SVGFETileElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFETileElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFETileElement: {\n prototype: SVGFETileElement;\n new(): SVGFETileElement;\n}\n\ninterface SVGFETurbulenceElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly baseFrequencyX: SVGAnimatedNumber;\n readonly baseFrequencyY: SVGAnimatedNumber;\n readonly numOctaves: SVGAnimatedInteger;\n readonly seed: SVGAnimatedNumber;\n readonly stitchTiles: SVGAnimatedEnumeration;\n readonly type: SVGAnimatedEnumeration;\n readonly SVG_STITCHTYPE_NOSTITCH: number;\n readonly SVG_STITCHTYPE_STITCH: number;\n readonly SVG_STITCHTYPE_UNKNOWN: number;\n readonly SVG_TURBULENCE_TYPE_FRACTALNOISE: number;\n readonly SVG_TURBULENCE_TYPE_TURBULENCE: number;\n readonly SVG_TURBULENCE_TYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFETurbulenceElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFETurbulenceElement: {\n prototype: SVGFETurbulenceElement;\n new(): SVGFETurbulenceElement;\n readonly SVG_STITCHTYPE_NOSTITCH: number;\n readonly SVG_STITCHTYPE_STITCH: number;\n readonly SVG_STITCHTYPE_UNKNOWN: number;\n readonly SVG_TURBULENCE_TYPE_FRACTALNOISE: number;\n readonly SVG_TURBULENCE_TYPE_TURBULENCE: number;\n readonly SVG_TURBULENCE_TYPE_UNKNOWN: number;\n}\n\ninterface SVGFilterElement extends SVGElement, SVGUnitTypes, SVGURIReference {\n readonly filterResX: SVGAnimatedInteger;\n readonly filterResY: SVGAnimatedInteger;\n readonly filterUnits: SVGAnimatedEnumeration;\n readonly height: SVGAnimatedLength;\n readonly primitiveUnits: SVGAnimatedEnumeration;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n setFilterRes(filterResX: number, filterResY: number): void;\n addEventListener(type: K, listener: (this: SVGFilterElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFilterElement: {\n prototype: SVGFilterElement;\n new(): SVGFilterElement;\n}\n\ninterface SVGForeignObjectElement extends SVGGraphicsElement {\n readonly height: SVGAnimatedLength;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGForeignObjectElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGForeignObjectElement: {\n prototype: SVGForeignObjectElement;\n new(): SVGForeignObjectElement;\n}\n\ninterface SVGGElement extends SVGGraphicsElement {\n addEventListener(type: K, listener: (this: SVGGElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGGElement: {\n prototype: SVGGElement;\n new(): SVGGElement;\n}\n\ninterface SVGGradientElement extends SVGElement, SVGUnitTypes, SVGURIReference {\n readonly gradientTransform: SVGAnimatedTransformList;\n readonly gradientUnits: SVGAnimatedEnumeration;\n readonly spreadMethod: SVGAnimatedEnumeration;\n readonly SVG_SPREADMETHOD_PAD: number;\n readonly SVG_SPREADMETHOD_REFLECT: number;\n readonly SVG_SPREADMETHOD_REPEAT: number;\n readonly SVG_SPREADMETHOD_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGGradientElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGGradientElement: {\n prototype: SVGGradientElement;\n new(): SVGGradientElement;\n readonly SVG_SPREADMETHOD_PAD: number;\n readonly SVG_SPREADMETHOD_REFLECT: number;\n readonly SVG_SPREADMETHOD_REPEAT: number;\n readonly SVG_SPREADMETHOD_UNKNOWN: number;\n}\n\ninterface SVGGraphicsElement extends SVGElement, SVGTests {\n readonly farthestViewportElement: SVGElement;\n readonly nearestViewportElement: SVGElement;\n readonly transform: SVGAnimatedTransformList;\n getBBox(): SVGRect;\n getCTM(): SVGMatrix;\n getScreenCTM(): SVGMatrix;\n getTransformToElement(element: SVGElement): SVGMatrix;\n addEventListener(type: K, listener: (this: SVGGraphicsElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGGraphicsElement: {\n prototype: SVGGraphicsElement;\n new(): SVGGraphicsElement;\n}\n\ninterface SVGImageElement extends SVGGraphicsElement, SVGURIReference {\n readonly height: SVGAnimatedLength;\n readonly preserveAspectRatio: SVGAnimatedPreserveAspectRatio;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGImageElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGImageElement: {\n prototype: SVGImageElement;\n new(): SVGImageElement;\n}\n\ninterface SVGLength {\n readonly unitType: number;\n value: number;\n valueAsString: string;\n valueInSpecifiedUnits: number;\n convertToSpecifiedUnits(unitType: number): void;\n newValueSpecifiedUnits(unitType: number, valueInSpecifiedUnits: number): void;\n readonly SVG_LENGTHTYPE_CM: number;\n readonly SVG_LENGTHTYPE_EMS: number;\n readonly SVG_LENGTHTYPE_EXS: number;\n readonly SVG_LENGTHTYPE_IN: number;\n readonly SVG_LENGTHTYPE_MM: number;\n readonly SVG_LENGTHTYPE_NUMBER: number;\n readonly SVG_LENGTHTYPE_PC: number;\n readonly SVG_LENGTHTYPE_PERCENTAGE: number;\n readonly SVG_LENGTHTYPE_PT: number;\n readonly SVG_LENGTHTYPE_PX: number;\n readonly SVG_LENGTHTYPE_UNKNOWN: number;\n}\n\ndeclare var SVGLength: {\n prototype: SVGLength;\n new(): SVGLength;\n readonly SVG_LENGTHTYPE_CM: number;\n readonly SVG_LENGTHTYPE_EMS: number;\n readonly SVG_LENGTHTYPE_EXS: number;\n readonly SVG_LENGTHTYPE_IN: number;\n readonly SVG_LENGTHTYPE_MM: number;\n readonly SVG_LENGTHTYPE_NUMBER: number;\n readonly SVG_LENGTHTYPE_PC: number;\n readonly SVG_LENGTHTYPE_PERCENTAGE: number;\n readonly SVG_LENGTHTYPE_PT: number;\n readonly SVG_LENGTHTYPE_PX: number;\n readonly SVG_LENGTHTYPE_UNKNOWN: number;\n}\n\ninterface SVGLengthList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGLength): SVGLength;\n clear(): void;\n getItem(index: number): SVGLength;\n initialize(newItem: SVGLength): SVGLength;\n insertItemBefore(newItem: SVGLength, index: number): SVGLength;\n removeItem(index: number): SVGLength;\n replaceItem(newItem: SVGLength, index: number): SVGLength;\n}\n\ndeclare var SVGLengthList: {\n prototype: SVGLengthList;\n new(): SVGLengthList;\n}\n\ninterface SVGLineElement extends SVGGraphicsElement {\n readonly x1: SVGAnimatedLength;\n readonly x2: SVGAnimatedLength;\n readonly y1: SVGAnimatedLength;\n readonly y2: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGLineElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGLineElement: {\n prototype: SVGLineElement;\n new(): SVGLineElement;\n}\n\ninterface SVGLinearGradientElement extends SVGGradientElement {\n readonly x1: SVGAnimatedLength;\n readonly x2: SVGAnimatedLength;\n readonly y1: SVGAnimatedLength;\n readonly y2: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGLinearGradientElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGLinearGradientElement: {\n prototype: SVGLinearGradientElement;\n new(): SVGLinearGradientElement;\n}\n\ninterface SVGMarkerElement extends SVGElement, SVGFitToViewBox {\n readonly markerHeight: SVGAnimatedLength;\n readonly markerUnits: SVGAnimatedEnumeration;\n readonly markerWidth: SVGAnimatedLength;\n readonly orientAngle: SVGAnimatedAngle;\n readonly orientType: SVGAnimatedEnumeration;\n readonly refX: SVGAnimatedLength;\n readonly refY: SVGAnimatedLength;\n setOrientToAngle(angle: SVGAngle): void;\n setOrientToAuto(): void;\n readonly SVG_MARKERUNITS_STROKEWIDTH: number;\n readonly SVG_MARKERUNITS_UNKNOWN: number;\n readonly SVG_MARKERUNITS_USERSPACEONUSE: number;\n readonly SVG_MARKER_ORIENT_ANGLE: number;\n readonly SVG_MARKER_ORIENT_AUTO: number;\n readonly SVG_MARKER_ORIENT_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGMarkerElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGMarkerElement: {\n prototype: SVGMarkerElement;\n new(): SVGMarkerElement;\n readonly SVG_MARKERUNITS_STROKEWIDTH: number;\n readonly SVG_MARKERUNITS_UNKNOWN: number;\n readonly SVG_MARKERUNITS_USERSPACEONUSE: number;\n readonly SVG_MARKER_ORIENT_ANGLE: number;\n readonly SVG_MARKER_ORIENT_AUTO: number;\n readonly SVG_MARKER_ORIENT_UNKNOWN: number;\n}\n\ninterface SVGMaskElement extends SVGElement, SVGTests, SVGUnitTypes {\n readonly height: SVGAnimatedLength;\n readonly maskContentUnits: SVGAnimatedEnumeration;\n readonly maskUnits: SVGAnimatedEnumeration;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGMaskElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGMaskElement: {\n prototype: SVGMaskElement;\n new(): SVGMaskElement;\n}\n\ninterface SVGMatrix {\n a: number;\n b: number;\n c: number;\n d: number;\n e: number;\n f: number;\n flipX(): SVGMatrix;\n flipY(): SVGMatrix;\n inverse(): SVGMatrix;\n multiply(secondMatrix: SVGMatrix): SVGMatrix;\n rotate(angle: number): SVGMatrix;\n rotateFromVector(x: number, y: number): SVGMatrix;\n scale(scaleFactor: number): SVGMatrix;\n scaleNonUniform(scaleFactorX: number, scaleFactorY: number): SVGMatrix;\n skewX(angle: number): SVGMatrix;\n skewY(angle: number): SVGMatrix;\n translate(x: number, y: number): SVGMatrix;\n}\n\ndeclare var SVGMatrix: {\n prototype: SVGMatrix;\n new(): SVGMatrix;\n}\n\ninterface SVGMetadataElement extends SVGElement {\n addEventListener(type: K, listener: (this: SVGMetadataElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGMetadataElement: {\n prototype: SVGMetadataElement;\n new(): SVGMetadataElement;\n}\n\ninterface SVGNumber {\n value: number;\n}\n\ndeclare var SVGNumber: {\n prototype: SVGNumber;\n new(): SVGNumber;\n}\n\ninterface SVGNumberList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGNumber): SVGNumber;\n clear(): void;\n getItem(index: number): SVGNumber;\n initialize(newItem: SVGNumber): SVGNumber;\n insertItemBefore(newItem: SVGNumber, index: number): SVGNumber;\n removeItem(index: number): SVGNumber;\n replaceItem(newItem: SVGNumber, index: number): SVGNumber;\n}\n\ndeclare var SVGNumberList: {\n prototype: SVGNumberList;\n new(): SVGNumberList;\n}\n\ninterface SVGPathElement extends SVGGraphicsElement {\n readonly pathSegList: SVGPathSegList;\n createSVGPathSegArcAbs(x: number, y: number, r1: number, r2: number, angle: number, largeArcFlag: boolean, sweepFlag: boolean): SVGPathSegArcAbs;\n createSVGPathSegArcRel(x: number, y: number, r1: number, r2: number, angle: number, largeArcFlag: boolean, sweepFlag: boolean): SVGPathSegArcRel;\n createSVGPathSegClosePath(): SVGPathSegClosePath;\n createSVGPathSegCurvetoCubicAbs(x: number, y: number, x1: number, y1: number, x2: number, y2: number): SVGPathSegCurvetoCubicAbs;\n createSVGPathSegCurvetoCubicRel(x: number, y: number, x1: number, y1: number, x2: number, y2: number): SVGPathSegCurvetoCubicRel;\n createSVGPathSegCurvetoCubicSmoothAbs(x: number, y: number, x2: number, y2: number): SVGPathSegCurvetoCubicSmoothAbs;\n createSVGPathSegCurvetoCubicSmoothRel(x: number, y: number, x2: number, y2: number): SVGPathSegCurvetoCubicSmoothRel;\n createSVGPathSegCurvetoQuadraticAbs(x: number, y: number, x1: number, y1: number): SVGPathSegCurvetoQuadraticAbs;\n createSVGPathSegCurvetoQuadraticRel(x: number, y: number, x1: number, y1: number): SVGPathSegCurvetoQuadraticRel;\n createSVGPathSegCurvetoQuadraticSmoothAbs(x: number, y: number): SVGPathSegCurvetoQuadraticSmoothAbs;\n createSVGPathSegCurvetoQuadraticSmoothRel(x: number, y: number): SVGPathSegCurvetoQuadraticSmoothRel;\n createSVGPathSegLinetoAbs(x: number, y: number): SVGPathSegLinetoAbs;\n createSVGPathSegLinetoHorizontalAbs(x: number): SVGPathSegLinetoHorizontalAbs;\n createSVGPathSegLinetoHorizontalRel(x: number): SVGPathSegLinetoHorizontalRel;\n createSVGPathSegLinetoRel(x: number, y: number): SVGPathSegLinetoRel;\n createSVGPathSegLinetoVerticalAbs(y: number): SVGPathSegLinetoVerticalAbs;\n createSVGPathSegLinetoVerticalRel(y: number): SVGPathSegLinetoVerticalRel;\n createSVGPathSegMovetoAbs(x: number, y: number): SVGPathSegMovetoAbs;\n createSVGPathSegMovetoRel(x: number, y: number): SVGPathSegMovetoRel;\n getPathSegAtLength(distance: number): number;\n getPointAtLength(distance: number): SVGPoint;\n getTotalLength(): number;\n addEventListener(type: K, listener: (this: SVGPathElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPathElement: {\n prototype: SVGPathElement;\n new(): SVGPathElement;\n}\n\ninterface SVGPathSeg {\n readonly pathSegType: number;\n readonly pathSegTypeAsLetter: string;\n readonly PATHSEG_ARC_ABS: number;\n readonly PATHSEG_ARC_REL: number;\n readonly PATHSEG_CLOSEPATH: number;\n readonly PATHSEG_CURVETO_CUBIC_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_REL: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL: number;\n readonly PATHSEG_LINETO_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_REL: number;\n readonly PATHSEG_LINETO_REL: number;\n readonly PATHSEG_LINETO_VERTICAL_ABS: number;\n readonly PATHSEG_LINETO_VERTICAL_REL: number;\n readonly PATHSEG_MOVETO_ABS: number;\n readonly PATHSEG_MOVETO_REL: number;\n readonly PATHSEG_UNKNOWN: number;\n}\n\ndeclare var SVGPathSeg: {\n prototype: SVGPathSeg;\n new(): SVGPathSeg;\n readonly PATHSEG_ARC_ABS: number;\n readonly PATHSEG_ARC_REL: number;\n readonly PATHSEG_CLOSEPATH: number;\n readonly PATHSEG_CURVETO_CUBIC_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_REL: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL: number;\n readonly PATHSEG_LINETO_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_REL: number;\n readonly PATHSEG_LINETO_REL: number;\n readonly PATHSEG_LINETO_VERTICAL_ABS: number;\n readonly PATHSEG_LINETO_VERTICAL_REL: number;\n readonly PATHSEG_MOVETO_ABS: number;\n readonly PATHSEG_MOVETO_REL: number;\n readonly PATHSEG_UNKNOWN: number;\n}\n\ninterface SVGPathSegArcAbs extends SVGPathSeg {\n angle: number;\n largeArcFlag: boolean;\n r1: number;\n r2: number;\n sweepFlag: boolean;\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegArcAbs: {\n prototype: SVGPathSegArcAbs;\n new(): SVGPathSegArcAbs;\n}\n\ninterface SVGPathSegArcRel extends SVGPathSeg {\n angle: number;\n largeArcFlag: boolean;\n r1: number;\n r2: number;\n sweepFlag: boolean;\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegArcRel: {\n prototype: SVGPathSegArcRel;\n new(): SVGPathSegArcRel;\n}\n\ninterface SVGPathSegClosePath extends SVGPathSeg {\n}\n\ndeclare var SVGPathSegClosePath: {\n prototype: SVGPathSegClosePath;\n new(): SVGPathSegClosePath;\n}\n\ninterface SVGPathSegCurvetoCubicAbs extends SVGPathSeg {\n x: number;\n x1: number;\n x2: number;\n y: number;\n y1: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicAbs: {\n prototype: SVGPathSegCurvetoCubicAbs;\n new(): SVGPathSegCurvetoCubicAbs;\n}\n\ninterface SVGPathSegCurvetoCubicRel extends SVGPathSeg {\n x: number;\n x1: number;\n x2: number;\n y: number;\n y1: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicRel: {\n prototype: SVGPathSegCurvetoCubicRel;\n new(): SVGPathSegCurvetoCubicRel;\n}\n\ninterface SVGPathSegCurvetoCubicSmoothAbs extends SVGPathSeg {\n x: number;\n x2: number;\n y: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicSmoothAbs: {\n prototype: SVGPathSegCurvetoCubicSmoothAbs;\n new(): SVGPathSegCurvetoCubicSmoothAbs;\n}\n\ninterface SVGPathSegCurvetoCubicSmoothRel extends SVGPathSeg {\n x: number;\n x2: number;\n y: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicSmoothRel: {\n prototype: SVGPathSegCurvetoCubicSmoothRel;\n new(): SVGPathSegCurvetoCubicSmoothRel;\n}\n\ninterface SVGPathSegCurvetoQuadraticAbs extends SVGPathSeg {\n x: number;\n x1: number;\n y: number;\n y1: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticAbs: {\n prototype: SVGPathSegCurvetoQuadraticAbs;\n new(): SVGPathSegCurvetoQuadraticAbs;\n}\n\ninterface SVGPathSegCurvetoQuadraticRel extends SVGPathSeg {\n x: number;\n x1: number;\n y: number;\n y1: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticRel: {\n prototype: SVGPathSegCurvetoQuadraticRel;\n new(): SVGPathSegCurvetoQuadraticRel;\n}\n\ninterface SVGPathSegCurvetoQuadraticSmoothAbs extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticSmoothAbs: {\n prototype: SVGPathSegCurvetoQuadraticSmoothAbs;\n new(): SVGPathSegCurvetoQuadraticSmoothAbs;\n}\n\ninterface SVGPathSegCurvetoQuadraticSmoothRel extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticSmoothRel: {\n prototype: SVGPathSegCurvetoQuadraticSmoothRel;\n new(): SVGPathSegCurvetoQuadraticSmoothRel;\n}\n\ninterface SVGPathSegLinetoAbs extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegLinetoAbs: {\n prototype: SVGPathSegLinetoAbs;\n new(): SVGPathSegLinetoAbs;\n}\n\ninterface SVGPathSegLinetoHorizontalAbs extends SVGPathSeg {\n x: number;\n}\n\ndeclare var SVGPathSegLinetoHorizontalAbs: {\n prototype: SVGPathSegLinetoHorizontalAbs;\n new(): SVGPathSegLinetoHorizontalAbs;\n}\n\ninterface SVGPathSegLinetoHorizontalRel extends SVGPathSeg {\n x: number;\n}\n\ndeclare var SVGPathSegLinetoHorizontalRel: {\n prototype: SVGPathSegLinetoHorizontalRel;\n new(): SVGPathSegLinetoHorizontalRel;\n}\n\ninterface SVGPathSegLinetoRel extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegLinetoRel: {\n prototype: SVGPathSegLinetoRel;\n new(): SVGPathSegLinetoRel;\n}\n\ninterface SVGPathSegLinetoVerticalAbs extends SVGPathSeg {\n y: number;\n}\n\ndeclare var SVGPathSegLinetoVerticalAbs: {\n prototype: SVGPathSegLinetoVerticalAbs;\n new(): SVGPathSegLinetoVerticalAbs;\n}\n\ninterface SVGPathSegLinetoVerticalRel extends SVGPathSeg {\n y: number;\n}\n\ndeclare var SVGPathSegLinetoVerticalRel: {\n prototype: SVGPathSegLinetoVerticalRel;\n new(): SVGPathSegLinetoVerticalRel;\n}\n\ninterface SVGPathSegList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGPathSeg): SVGPathSeg;\n clear(): void;\n getItem(index: number): SVGPathSeg;\n initialize(newItem: SVGPathSeg): SVGPathSeg;\n insertItemBefore(newItem: SVGPathSeg, index: number): SVGPathSeg;\n removeItem(index: number): SVGPathSeg;\n replaceItem(newItem: SVGPathSeg, index: number): SVGPathSeg;\n}\n\ndeclare var SVGPathSegList: {\n prototype: SVGPathSegList;\n new(): SVGPathSegList;\n}\n\ninterface SVGPathSegMovetoAbs extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegMovetoAbs: {\n prototype: SVGPathSegMovetoAbs;\n new(): SVGPathSegMovetoAbs;\n}\n\ninterface SVGPathSegMovetoRel extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegMovetoRel: {\n prototype: SVGPathSegMovetoRel;\n new(): SVGPathSegMovetoRel;\n}\n\ninterface SVGPatternElement extends SVGElement, SVGTests, SVGUnitTypes, SVGFitToViewBox, SVGURIReference {\n readonly height: SVGAnimatedLength;\n readonly patternContentUnits: SVGAnimatedEnumeration;\n readonly patternTransform: SVGAnimatedTransformList;\n readonly patternUnits: SVGAnimatedEnumeration;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGPatternElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPatternElement: {\n prototype: SVGPatternElement;\n new(): SVGPatternElement;\n}\n\ninterface SVGPoint {\n x: number;\n y: number;\n matrixTransform(matrix: SVGMatrix): SVGPoint;\n}\n\ndeclare var SVGPoint: {\n prototype: SVGPoint;\n new(): SVGPoint;\n}\n\ninterface SVGPointList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGPoint): SVGPoint;\n clear(): void;\n getItem(index: number): SVGPoint;\n initialize(newItem: SVGPoint): SVGPoint;\n insertItemBefore(newItem: SVGPoint, index: number): SVGPoint;\n removeItem(index: number): SVGPoint;\n replaceItem(newItem: SVGPoint, index: number): SVGPoint;\n}\n\ndeclare var SVGPointList: {\n prototype: SVGPointList;\n new(): SVGPointList;\n}\n\ninterface SVGPolygonElement extends SVGGraphicsElement, SVGAnimatedPoints {\n addEventListener(type: K, listener: (this: SVGPolygonElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPolygonElement: {\n prototype: SVGPolygonElement;\n new(): SVGPolygonElement;\n}\n\ninterface SVGPolylineElement extends SVGGraphicsElement, SVGAnimatedPoints {\n addEventListener(type: K, listener: (this: SVGPolylineElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPolylineElement: {\n prototype: SVGPolylineElement;\n new(): SVGPolylineElement;\n}\n\ninterface SVGPreserveAspectRatio {\n align: number;\n meetOrSlice: number;\n readonly SVG_MEETORSLICE_MEET: number;\n readonly SVG_MEETORSLICE_SLICE: number;\n readonly SVG_MEETORSLICE_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_NONE: number;\n readonly SVG_PRESERVEASPECTRATIO_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMIN: number;\n}\n\ndeclare var SVGPreserveAspectRatio: {\n prototype: SVGPreserveAspectRatio;\n new(): SVGPreserveAspectRatio;\n readonly SVG_MEETORSLICE_MEET: number;\n readonly SVG_MEETORSLICE_SLICE: number;\n readonly SVG_MEETORSLICE_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_NONE: number;\n readonly SVG_PRESERVEASPECTRATIO_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMIN: number;\n}\n\ninterface SVGRadialGradientElement extends SVGGradientElement {\n readonly cx: SVGAnimatedLength;\n readonly cy: SVGAnimatedLength;\n readonly fx: SVGAnimatedLength;\n readonly fy: SVGAnimatedLength;\n readonly r: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGRadialGradientElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGRadialGradientElement: {\n prototype: SVGRadialGradientElement;\n new(): SVGRadialGradientElement;\n}\n\ninterface SVGRect {\n height: number;\n width: number;\n x: number;\n y: number;\n}\n\ndeclare var SVGRect: {\n prototype: SVGRect;\n new(): SVGRect;\n}\n\ninterface SVGRectElement extends SVGGraphicsElement {\n readonly height: SVGAnimatedLength;\n readonly rx: SVGAnimatedLength;\n readonly ry: SVGAnimatedLength;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGRectElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGRectElement: {\n prototype: SVGRectElement;\n new(): SVGRectElement;\n}\n\ninterface SVGSVGElementEventMap extends SVGElementEventMap {\n \"SVGAbort\": Event;\n \"SVGError\": Event;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"SVGUnload\": Event;\n \"SVGZoom\": SVGZoomEvent;\n}\n\ninterface SVGSVGElement extends SVGGraphicsElement, DocumentEvent, SVGFitToViewBox, SVGZoomAndPan {\n contentScriptType: string;\n contentStyleType: string;\n currentScale: number;\n readonly currentTranslate: SVGPoint;\n readonly height: SVGAnimatedLength;\n onabort: (this: SVGSVGElement, ev: Event) => any;\n onerror: (this: SVGSVGElement, ev: Event) => any;\n onresize: (this: SVGSVGElement, ev: UIEvent) => any;\n onscroll: (this: SVGSVGElement, ev: UIEvent) => any;\n onunload: (this: SVGSVGElement, ev: Event) => any;\n onzoom: (this: SVGSVGElement, ev: SVGZoomEvent) => any;\n readonly pixelUnitToMillimeterX: number;\n readonly pixelUnitToMillimeterY: number;\n readonly screenPixelToMillimeterX: number;\n readonly screenPixelToMillimeterY: number;\n readonly viewport: SVGRect;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n checkEnclosure(element: SVGElement, rect: SVGRect): boolean;\n checkIntersection(element: SVGElement, rect: SVGRect): boolean;\n createSVGAngle(): SVGAngle;\n createSVGLength(): SVGLength;\n createSVGMatrix(): SVGMatrix;\n createSVGNumber(): SVGNumber;\n createSVGPoint(): SVGPoint;\n createSVGRect(): SVGRect;\n createSVGTransform(): SVGTransform;\n createSVGTransformFromMatrix(matrix: SVGMatrix): SVGTransform;\n deselectAll(): void;\n forceRedraw(): void;\n getComputedStyle(elt: Element, pseudoElt?: string): CSSStyleDeclaration;\n getCurrentTime(): number;\n getElementById(elementId: string): Element;\n getEnclosureList(rect: SVGRect, referenceElement: SVGElement): NodeListOf;\n getIntersectionList(rect: SVGRect, referenceElement: SVGElement): NodeListOf;\n pauseAnimations(): void;\n setCurrentTime(seconds: number): void;\n suspendRedraw(maxWaitMilliseconds: number): number;\n unpauseAnimations(): void;\n unsuspendRedraw(suspendHandleID: number): void;\n unsuspendRedrawAll(): void;\n addEventListener(type: K, listener: (this: SVGSVGElement, ev: SVGSVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGSVGElement: {\n prototype: SVGSVGElement;\n new(): SVGSVGElement;\n}\n\ninterface SVGScriptElement extends SVGElement, SVGURIReference {\n type: string;\n addEventListener(type: K, listener: (this: SVGScriptElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGScriptElement: {\n prototype: SVGScriptElement;\n new(): SVGScriptElement;\n}\n\ninterface SVGStopElement extends SVGElement {\n readonly offset: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGStopElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGStopElement: {\n prototype: SVGStopElement;\n new(): SVGStopElement;\n}\n\ninterface SVGStringList {\n readonly numberOfItems: number;\n appendItem(newItem: string): string;\n clear(): void;\n getItem(index: number): string;\n initialize(newItem: string): string;\n insertItemBefore(newItem: string, index: number): string;\n removeItem(index: number): string;\n replaceItem(newItem: string, index: number): string;\n}\n\ndeclare var SVGStringList: {\n prototype: SVGStringList;\n new(): SVGStringList;\n}\n\ninterface SVGStyleElement extends SVGElement {\n disabled: boolean;\n media: string;\n title: string;\n type: string;\n addEventListener(type: K, listener: (this: SVGStyleElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGStyleElement: {\n prototype: SVGStyleElement;\n new(): SVGStyleElement;\n}\n\ninterface SVGSwitchElement extends SVGGraphicsElement {\n addEventListener(type: K, listener: (this: SVGSwitchElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGSwitchElement: {\n prototype: SVGSwitchElement;\n new(): SVGSwitchElement;\n}\n\ninterface SVGSymbolElement extends SVGElement, SVGFitToViewBox {\n addEventListener(type: K, listener: (this: SVGSymbolElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGSymbolElement: {\n prototype: SVGSymbolElement;\n new(): SVGSymbolElement;\n}\n\ninterface SVGTSpanElement extends SVGTextPositioningElement {\n addEventListener(type: K, listener: (this: SVGTSpanElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTSpanElement: {\n prototype: SVGTSpanElement;\n new(): SVGTSpanElement;\n}\n\ninterface SVGTextContentElement extends SVGGraphicsElement {\n readonly lengthAdjust: SVGAnimatedEnumeration;\n readonly textLength: SVGAnimatedLength;\n getCharNumAtPosition(point: SVGPoint): number;\n getComputedTextLength(): number;\n getEndPositionOfChar(charnum: number): SVGPoint;\n getExtentOfChar(charnum: number): SVGRect;\n getNumberOfChars(): number;\n getRotationOfChar(charnum: number): number;\n getStartPositionOfChar(charnum: number): SVGPoint;\n getSubStringLength(charnum: number, nchars: number): number;\n selectSubString(charnum: number, nchars: number): void;\n readonly LENGTHADJUST_SPACING: number;\n readonly LENGTHADJUST_SPACINGANDGLYPHS: number;\n readonly LENGTHADJUST_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGTextContentElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextContentElement: {\n prototype: SVGTextContentElement;\n new(): SVGTextContentElement;\n readonly LENGTHADJUST_SPACING: number;\n readonly LENGTHADJUST_SPACINGANDGLYPHS: number;\n readonly LENGTHADJUST_UNKNOWN: number;\n}\n\ninterface SVGTextElement extends SVGTextPositioningElement {\n addEventListener(type: K, listener: (this: SVGTextElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextElement: {\n prototype: SVGTextElement;\n new(): SVGTextElement;\n}\n\ninterface SVGTextPathElement extends SVGTextContentElement, SVGURIReference {\n readonly method: SVGAnimatedEnumeration;\n readonly spacing: SVGAnimatedEnumeration;\n readonly startOffset: SVGAnimatedLength;\n readonly TEXTPATH_METHODTYPE_ALIGN: number;\n readonly TEXTPATH_METHODTYPE_STRETCH: number;\n readonly TEXTPATH_METHODTYPE_UNKNOWN: number;\n readonly TEXTPATH_SPACINGTYPE_AUTO: number;\n readonly TEXTPATH_SPACINGTYPE_EXACT: number;\n readonly TEXTPATH_SPACINGTYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGTextPathElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextPathElement: {\n prototype: SVGTextPathElement;\n new(): SVGTextPathElement;\n readonly TEXTPATH_METHODTYPE_ALIGN: number;\n readonly TEXTPATH_METHODTYPE_STRETCH: number;\n readonly TEXTPATH_METHODTYPE_UNKNOWN: number;\n readonly TEXTPATH_SPACINGTYPE_AUTO: number;\n readonly TEXTPATH_SPACINGTYPE_EXACT: number;\n readonly TEXTPATH_SPACINGTYPE_UNKNOWN: number;\n}\n\ninterface SVGTextPositioningElement extends SVGTextContentElement {\n readonly dx: SVGAnimatedLengthList;\n readonly dy: SVGAnimatedLengthList;\n readonly rotate: SVGAnimatedNumberList;\n readonly x: SVGAnimatedLengthList;\n readonly y: SVGAnimatedLengthList;\n addEventListener(type: K, listener: (this: SVGTextPositioningElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextPositioningElement: {\n prototype: SVGTextPositioningElement;\n new(): SVGTextPositioningElement;\n}\n\ninterface SVGTitleElement extends SVGElement {\n addEventListener(type: K, listener: (this: SVGTitleElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTitleElement: {\n prototype: SVGTitleElement;\n new(): SVGTitleElement;\n}\n\ninterface SVGTransform {\n readonly angle: number;\n readonly matrix: SVGMatrix;\n readonly type: number;\n setMatrix(matrix: SVGMatrix): void;\n setRotate(angle: number, cx: number, cy: number): void;\n setScale(sx: number, sy: number): void;\n setSkewX(angle: number): void;\n setSkewY(angle: number): void;\n setTranslate(tx: number, ty: number): void;\n readonly SVG_TRANSFORM_MATRIX: number;\n readonly SVG_TRANSFORM_ROTATE: number;\n readonly SVG_TRANSFORM_SCALE: number;\n readonly SVG_TRANSFORM_SKEWX: number;\n readonly SVG_TRANSFORM_SKEWY: number;\n readonly SVG_TRANSFORM_TRANSLATE: number;\n readonly SVG_TRANSFORM_UNKNOWN: number;\n}\n\ndeclare var SVGTransform: {\n prototype: SVGTransform;\n new(): SVGTransform;\n readonly SVG_TRANSFORM_MATRIX: number;\n readonly SVG_TRANSFORM_ROTATE: number;\n readonly SVG_TRANSFORM_SCALE: number;\n readonly SVG_TRANSFORM_SKEWX: number;\n readonly SVG_TRANSFORM_SKEWY: number;\n readonly SVG_TRANSFORM_TRANSLATE: number;\n readonly SVG_TRANSFORM_UNKNOWN: number;\n}\n\ninterface SVGTransformList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGTransform): SVGTransform;\n clear(): void;\n consolidate(): SVGTransform;\n createSVGTransformFromMatrix(matrix: SVGMatrix): SVGTransform;\n getItem(index: number): SVGTransform;\n initialize(newItem: SVGTransform): SVGTransform;\n insertItemBefore(newItem: SVGTransform, index: number): SVGTransform;\n removeItem(index: number): SVGTransform;\n replaceItem(newItem: SVGTransform, index: number): SVGTransform;\n}\n\ndeclare var SVGTransformList: {\n prototype: SVGTransformList;\n new(): SVGTransformList;\n}\n\ninterface SVGUnitTypes {\n readonly SVG_UNIT_TYPE_OBJECTBOUNDINGBOX: number;\n readonly SVG_UNIT_TYPE_UNKNOWN: number;\n readonly SVG_UNIT_TYPE_USERSPACEONUSE: number;\n}\ndeclare var SVGUnitTypes: SVGUnitTypes;\n\ninterface SVGUseElement extends SVGGraphicsElement, SVGURIReference {\n readonly animatedInstanceRoot: SVGElementInstance;\n readonly height: SVGAnimatedLength;\n readonly instanceRoot: SVGElementInstance;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGUseElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGUseElement: {\n prototype: SVGUseElement;\n new(): SVGUseElement;\n}\n\ninterface SVGViewElement extends SVGElement, SVGZoomAndPan, SVGFitToViewBox {\n readonly viewTarget: SVGStringList;\n addEventListener(type: K, listener: (this: SVGViewElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGViewElement: {\n prototype: SVGViewElement;\n new(): SVGViewElement;\n}\n\ninterface SVGZoomAndPan {\n readonly zoomAndPan: number;\n}\n\ndeclare var SVGZoomAndPan: {\n readonly SVG_ZOOMANDPAN_DISABLE: number;\n readonly SVG_ZOOMANDPAN_MAGNIFY: number;\n readonly SVG_ZOOMANDPAN_UNKNOWN: number;\n}\n\ninterface SVGZoomEvent extends UIEvent {\n readonly newScale: number;\n readonly newTranslate: SVGPoint;\n readonly previousScale: number;\n readonly previousTranslate: SVGPoint;\n readonly zoomRectScreen: SVGRect;\n}\n\ndeclare var SVGZoomEvent: {\n prototype: SVGZoomEvent;\n new(): SVGZoomEvent;\n}\n\ninterface ScopedCredential {\n readonly id: ArrayBuffer;\n readonly type: ScopedCredentialType;\n}\n\ndeclare var ScopedCredential: {\n prototype: ScopedCredential;\n new(): ScopedCredential;\n}\n\ninterface ScopedCredentialInfo {\n readonly credential: ScopedCredential;\n readonly publicKey: CryptoKey;\n}\n\ndeclare var ScopedCredentialInfo: {\n prototype: ScopedCredentialInfo;\n new(): ScopedCredentialInfo;\n}\n\ninterface ScreenEventMap {\n \"MSOrientationChange\": Event;\n}\n\ninterface Screen extends EventTarget {\n readonly availHeight: number;\n readonly availWidth: number;\n bufferDepth: number;\n readonly colorDepth: number;\n readonly deviceXDPI: number;\n readonly deviceYDPI: number;\n readonly fontSmoothingEnabled: boolean;\n readonly height: number;\n readonly logicalXDPI: number;\n readonly logicalYDPI: number;\n readonly msOrientation: string;\n onmsorientationchange: (this: Screen, ev: Event) => any;\n readonly pixelDepth: number;\n readonly systemXDPI: number;\n readonly systemYDPI: number;\n readonly width: number;\n msLockOrientation(orientations: string | string[]): boolean;\n msUnlockOrientation(): void;\n addEventListener(type: K, listener: (this: Screen, ev: ScreenEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Screen: {\n prototype: Screen;\n new(): Screen;\n}\n\ninterface ScriptNotifyEvent extends Event {\n readonly callingUri: string;\n readonly value: string;\n}\n\ndeclare var ScriptNotifyEvent: {\n prototype: ScriptNotifyEvent;\n new(): ScriptNotifyEvent;\n}\n\ninterface ScriptProcessorNodeEventMap {\n \"audioprocess\": AudioProcessingEvent;\n}\n\ninterface ScriptProcessorNode extends AudioNode {\n readonly bufferSize: number;\n onaudioprocess: (this: ScriptProcessorNode, ev: AudioProcessingEvent) => any;\n addEventListener(type: K, listener: (this: ScriptProcessorNode, ev: ScriptProcessorNodeEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ScriptProcessorNode: {\n prototype: ScriptProcessorNode;\n new(): ScriptProcessorNode;\n}\n\ninterface Selection {\n readonly anchorNode: Node;\n readonly anchorOffset: number;\n readonly baseNode: Node;\n readonly baseOffset: number;\n readonly extentNode: Node;\n readonly extentOffset: number;\n readonly focusNode: Node;\n readonly focusOffset: number;\n readonly isCollapsed: boolean;\n readonly rangeCount: number;\n readonly type: string;\n addRange(range: Range): void;\n collapse(parentNode: Node, offset: number): void;\n collapseToEnd(): void;\n collapseToStart(): void;\n containsNode(node: Node, partlyContained: boolean): boolean;\n deleteFromDocument(): void;\n empty(): void;\n extend(newNode: Node, offset: number): void;\n getRangeAt(index: number): Range;\n removeAllRanges(): void;\n removeRange(range: Range): void;\n selectAllChildren(parentNode: Node): void;\n setBaseAndExtent(baseNode: Node, baseOffset: number, extentNode: Node, extentOffset: number): void;\n setPosition(parentNode: Node, offset: number): void;\n toString(): string;\n}\n\ndeclare var Selection: {\n prototype: Selection;\n new(): Selection;\n}\n\ninterface ServiceWorkerEventMap extends AbstractWorkerEventMap {\n \"statechange\": Event;\n}\n\ninterface ServiceWorker extends EventTarget, AbstractWorker {\n onstatechange: (this: ServiceWorker, ev: Event) => any;\n readonly scriptURL: USVString;\n readonly state: ServiceWorkerState;\n postMessage(message: any, transfer?: any[]): void;\n addEventListener(type: K, listener: (this: ServiceWorker, ev: ServiceWorkerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ServiceWorker: {\n prototype: ServiceWorker;\n new(): ServiceWorker;\n}\n\ninterface ServiceWorkerContainerEventMap {\n \"controllerchange\": Event;\n \"message\": ServiceWorkerMessageEvent;\n}\n\ninterface ServiceWorkerContainer extends EventTarget {\n readonly controller: ServiceWorker | null;\n oncontrollerchange: (this: ServiceWorkerContainer, ev: Event) => any;\n onmessage: (this: ServiceWorkerContainer, ev: ServiceWorkerMessageEvent) => any;\n readonly ready: Promise;\n getRegistration(clientURL?: USVString): Promise;\n getRegistrations(): any;\n register(scriptURL: USVString, options?: RegistrationOptions): Promise;\n addEventListener(type: K, listener: (this: ServiceWorkerContainer, ev: ServiceWorkerContainerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ServiceWorkerContainer: {\n prototype: ServiceWorkerContainer;\n new(): ServiceWorkerContainer;\n}\n\ninterface ServiceWorkerMessageEvent extends Event {\n readonly data: any;\n readonly lastEventId: string;\n readonly origin: string;\n readonly ports: MessagePort[] | null;\n readonly source: ServiceWorker | MessagePort | null;\n}\n\ndeclare var ServiceWorkerMessageEvent: {\n prototype: ServiceWorkerMessageEvent;\n new(type: string, eventInitDict?: ServiceWorkerMessageEventInit): ServiceWorkerMessageEvent;\n}\n\ninterface ServiceWorkerRegistrationEventMap {\n \"updatefound\": Event;\n}\n\ninterface ServiceWorkerRegistration extends EventTarget {\n readonly active: ServiceWorker | null;\n readonly installing: ServiceWorker | null;\n onupdatefound: (this: ServiceWorkerRegistration, ev: Event) => any;\n readonly pushManager: PushManager;\n readonly scope: USVString;\n readonly sync: SyncManager;\n readonly waiting: ServiceWorker | null;\n getNotifications(filter?: GetNotificationOptions): any;\n showNotification(title: string, options?: NotificationOptions): Promise;\n unregister(): Promise;\n update(): Promise;\n addEventListener(type: K, listener: (this: ServiceWorkerRegistration, ev: ServiceWorkerRegistrationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ServiceWorkerRegistration: {\n prototype: ServiceWorkerRegistration;\n new(): ServiceWorkerRegistration;\n}\n\ninterface SourceBuffer extends EventTarget {\n appendWindowEnd: number;\n appendWindowStart: number;\n readonly audioTracks: AudioTrackList;\n readonly buffered: TimeRanges;\n mode: AppendMode;\n timestampOffset: number;\n readonly updating: boolean;\n readonly videoTracks: VideoTrackList;\n abort(): void;\n appendBuffer(data: ArrayBuffer | ArrayBufferView): void;\n appendStream(stream: MSStream, maxSize?: number): void;\n remove(start: number, end: number): void;\n}\n\ndeclare var SourceBuffer: {\n prototype: SourceBuffer;\n new(): SourceBuffer;\n}\n\ninterface SourceBufferList extends EventTarget {\n readonly length: number;\n item(index: number): SourceBuffer;\n [index: number]: SourceBuffer;\n}\n\ndeclare var SourceBufferList: {\n prototype: SourceBufferList;\n new(): SourceBufferList;\n}\n\ninterface SpeechSynthesisEventMap {\n \"voiceschanged\": Event;\n}\n\ninterface SpeechSynthesis extends EventTarget {\n onvoiceschanged: (this: SpeechSynthesis, ev: Event) => any;\n readonly paused: boolean;\n readonly pending: boolean;\n readonly speaking: boolean;\n cancel(): void;\n getVoices(): SpeechSynthesisVoice[];\n pause(): void;\n resume(): void;\n speak(utterance: SpeechSynthesisUtterance): void;\n addEventListener(type: K, listener: (this: SpeechSynthesis, ev: SpeechSynthesisEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SpeechSynthesis: {\n prototype: SpeechSynthesis;\n new(): SpeechSynthesis;\n}\n\ninterface SpeechSynthesisEvent extends Event {\n readonly charIndex: number;\n readonly elapsedTime: number;\n readonly name: string;\n readonly utterance: SpeechSynthesisUtterance | null;\n}\n\ndeclare var SpeechSynthesisEvent: {\n prototype: SpeechSynthesisEvent;\n new(type: string, eventInitDict?: SpeechSynthesisEventInit): SpeechSynthesisEvent;\n}\n\ninterface SpeechSynthesisUtteranceEventMap {\n \"boundary\": Event;\n \"end\": Event;\n \"error\": Event;\n \"mark\": Event;\n \"pause\": Event;\n \"resume\": Event;\n \"start\": Event;\n}\n\ninterface SpeechSynthesisUtterance extends EventTarget {\n lang: string;\n onboundary: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onend: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onerror: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onmark: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onpause: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onresume: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onstart: (this: SpeechSynthesisUtterance, ev: Event) => any;\n pitch: number;\n rate: number;\n text: string;\n voice: SpeechSynthesisVoice;\n volume: number;\n addEventListener(type: K, listener: (this: SpeechSynthesisUtterance, ev: SpeechSynthesisUtteranceEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SpeechSynthesisUtterance: {\n prototype: SpeechSynthesisUtterance;\n new(text?: string): SpeechSynthesisUtterance;\n}\n\ninterface SpeechSynthesisVoice {\n readonly default: boolean;\n readonly lang: string;\n readonly localService: boolean;\n readonly name: string;\n readonly voiceURI: string;\n}\n\ndeclare var SpeechSynthesisVoice: {\n prototype: SpeechSynthesisVoice;\n new(): SpeechSynthesisVoice;\n}\n\ninterface StereoPannerNode extends AudioNode {\n readonly pan: AudioParam;\n}\n\ndeclare var StereoPannerNode: {\n prototype: StereoPannerNode;\n new(): StereoPannerNode;\n}\n\ninterface Storage {\n readonly length: number;\n clear(): void;\n getItem(key: string): string | null;\n key(index: number): string | null;\n removeItem(key: string): void;\n setItem(key: string, data: string): void;\n [key: string]: any;\n [index: number]: string;\n}\n\ndeclare var Storage: {\n prototype: Storage;\n new(): Storage;\n}\n\ninterface StorageEvent extends Event {\n readonly url: string;\n key?: string;\n oldValue?: string;\n newValue?: string;\n storageArea?: Storage;\n}\n\ndeclare var StorageEvent: {\n prototype: StorageEvent;\n new (type: string, eventInitDict?: StorageEventInit): StorageEvent;\n}\n\ninterface StyleMedia {\n readonly type: string;\n matchMedium(mediaquery: string): boolean;\n}\n\ndeclare var StyleMedia: {\n prototype: StyleMedia;\n new(): StyleMedia;\n}\n\ninterface StyleSheet {\n disabled: boolean;\n readonly href: string;\n readonly media: MediaList;\n readonly ownerNode: Node;\n readonly parentStyleSheet: StyleSheet;\n readonly title: string;\n readonly type: string;\n}\n\ndeclare var StyleSheet: {\n prototype: StyleSheet;\n new(): StyleSheet;\n}\n\ninterface StyleSheetList {\n readonly length: number;\n item(index?: number): StyleSheet;\n [index: number]: StyleSheet;\n}\n\ndeclare var StyleSheetList: {\n prototype: StyleSheetList;\n new(): StyleSheetList;\n}\n\ninterface StyleSheetPageList {\n readonly length: number;\n item(index: number): CSSPageRule;\n [index: number]: CSSPageRule;\n}\n\ndeclare var StyleSheetPageList: {\n prototype: StyleSheetPageList;\n new(): StyleSheetPageList;\n}\n\ninterface SubtleCrypto {\n decrypt(algorithm: string | RsaOaepParams | AesCtrParams | AesCbcParams | AesCmacParams | AesGcmParams | AesCfbParams, key: CryptoKey, data: BufferSource): PromiseLike;\n deriveBits(algorithm: string | EcdhKeyDeriveParams | DhKeyDeriveParams | ConcatParams | HkdfCtrParams | Pbkdf2Params, baseKey: CryptoKey, length: number): PromiseLike;\n deriveKey(algorithm: string | EcdhKeyDeriveParams | DhKeyDeriveParams | ConcatParams | HkdfCtrParams | Pbkdf2Params, baseKey: CryptoKey, derivedKeyType: string | AesDerivedKeyParams | HmacImportParams | ConcatParams | HkdfCtrParams | Pbkdf2Params, extractable: boolean, keyUsages: string[]): PromiseLike;\n digest(algorithm: AlgorithmIdentifier, data: BufferSource): PromiseLike;\n encrypt(algorithm: string | RsaOaepParams | AesCtrParams | AesCbcParams | AesCmacParams | AesGcmParams | AesCfbParams, key: CryptoKey, data: BufferSource): PromiseLike;\n exportKey(format: \"jwk\", key: CryptoKey): PromiseLike;\n exportKey(format: \"raw\" | \"pkcs8\" | \"spki\", key: CryptoKey): PromiseLike;\n exportKey(format: string, key: CryptoKey): PromiseLike;\n generateKey(algorithm: string, extractable: boolean, keyUsages: string[]): PromiseLike;\n generateKey(algorithm: RsaHashedKeyGenParams | EcKeyGenParams | DhKeyGenParams, extractable: boolean, keyUsages: string[]): PromiseLike;\n generateKey(algorithm: AesKeyGenParams | HmacKeyGenParams | Pbkdf2Params, extractable: boolean, keyUsages: string[]): PromiseLike;\n importKey(format: \"jwk\", keyData: JsonWebKey, algorithm: string | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | DhImportKeyParams, extractable:boolean, keyUsages: string[]): PromiseLike;\n importKey(format: \"raw\" | \"pkcs8\" | \"spki\", keyData: BufferSource, algorithm: string | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | DhImportKeyParams, extractable:boolean, keyUsages: string[]): PromiseLike;\n importKey(format: string, keyData: JsonWebKey | BufferSource, algorithm: string | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | DhImportKeyParams, extractable:boolean, keyUsages: string[]): PromiseLike;\n sign(algorithm: string | RsaPssParams | EcdsaParams | AesCmacParams, key: CryptoKey, data: BufferSource): PromiseLike;\n unwrapKey(format: string, wrappedKey: BufferSource, unwrappingKey: CryptoKey, unwrapAlgorithm: AlgorithmIdentifier, unwrappedKeyAlgorithm: AlgorithmIdentifier, extractable: boolean, keyUsages: string[]): PromiseLike;\n verify(algorithm: string | RsaPssParams | EcdsaParams | AesCmacParams, key: CryptoKey, signature: BufferSource, data: BufferSource): PromiseLike;\n wrapKey(format: string, key: CryptoKey, wrappingKey: CryptoKey, wrapAlgorithm: AlgorithmIdentifier): PromiseLike;\n}\n\ndeclare var SubtleCrypto: {\n prototype: SubtleCrypto;\n new(): SubtleCrypto;\n}\n\ninterface SyncManager {\n getTags(): any;\n register(tag: string): Promise;\n}\n\ndeclare var SyncManager: {\n prototype: SyncManager;\n new(): SyncManager;\n}\n\ninterface Text extends CharacterData {\n readonly wholeText: string;\n readonly assignedSlot: HTMLSlotElement | null;\n splitText(offset: number): Text;\n}\n\ndeclare var Text: {\n prototype: Text;\n new(data?: string): Text;\n}\n\ninterface TextEvent extends UIEvent {\n readonly data: string;\n readonly inputMethod: number;\n readonly locale: string;\n initTextEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, dataArg: string, inputMethod: number, locale: string): void;\n readonly DOM_INPUT_METHOD_DROP: number;\n readonly DOM_INPUT_METHOD_HANDWRITING: number;\n readonly DOM_INPUT_METHOD_IME: number;\n readonly DOM_INPUT_METHOD_KEYBOARD: number;\n readonly DOM_INPUT_METHOD_MULTIMODAL: number;\n readonly DOM_INPUT_METHOD_OPTION: number;\n readonly DOM_INPUT_METHOD_PASTE: number;\n readonly DOM_INPUT_METHOD_SCRIPT: number;\n readonly DOM_INPUT_METHOD_UNKNOWN: number;\n readonly DOM_INPUT_METHOD_VOICE: number;\n}\n\ndeclare var TextEvent: {\n prototype: TextEvent;\n new(): TextEvent;\n readonly DOM_INPUT_METHOD_DROP: number;\n readonly DOM_INPUT_METHOD_HANDWRITING: number;\n readonly DOM_INPUT_METHOD_IME: number;\n readonly DOM_INPUT_METHOD_KEYBOARD: number;\n readonly DOM_INPUT_METHOD_MULTIMODAL: number;\n readonly DOM_INPUT_METHOD_OPTION: number;\n readonly DOM_INPUT_METHOD_PASTE: number;\n readonly DOM_INPUT_METHOD_SCRIPT: number;\n readonly DOM_INPUT_METHOD_UNKNOWN: number;\n readonly DOM_INPUT_METHOD_VOICE: number;\n}\n\ninterface TextMetrics {\n readonly width: number;\n}\n\ndeclare var TextMetrics: {\n prototype: TextMetrics;\n new(): TextMetrics;\n}\n\ninterface TextTrackEventMap {\n \"cuechange\": Event;\n \"error\": Event;\n \"load\": Event;\n}\n\ninterface TextTrack extends EventTarget {\n readonly activeCues: TextTrackCueList;\n readonly cues: TextTrackCueList;\n readonly inBandMetadataTrackDispatchType: string;\n readonly kind: string;\n readonly label: string;\n readonly language: string;\n mode: any;\n oncuechange: (this: TextTrack, ev: Event) => any;\n onerror: (this: TextTrack, ev: Event) => any;\n onload: (this: TextTrack, ev: Event) => any;\n readonly readyState: number;\n addCue(cue: TextTrackCue): void;\n removeCue(cue: TextTrackCue): void;\n readonly DISABLED: number;\n readonly ERROR: number;\n readonly HIDDEN: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n readonly SHOWING: number;\n addEventListener(type: K, listener: (this: TextTrack, ev: TextTrackEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var TextTrack: {\n prototype: TextTrack;\n new(): TextTrack;\n readonly DISABLED: number;\n readonly ERROR: number;\n readonly HIDDEN: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n readonly SHOWING: number;\n}\n\ninterface TextTrackCueEventMap {\n \"enter\": Event;\n \"exit\": Event;\n}\n\ninterface TextTrackCue extends EventTarget {\n endTime: number;\n id: string;\n onenter: (this: TextTrackCue, ev: Event) => any;\n onexit: (this: TextTrackCue, ev: Event) => any;\n pauseOnExit: boolean;\n startTime: number;\n text: string;\n readonly track: TextTrack;\n getCueAsHTML(): DocumentFragment;\n addEventListener(type: K, listener: (this: TextTrackCue, ev: TextTrackCueEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var TextTrackCue: {\n prototype: TextTrackCue;\n new(startTime: number, endTime: number, text: string): TextTrackCue;\n}\n\ninterface TextTrackCueList {\n readonly length: number;\n getCueById(id: string): TextTrackCue;\n item(index: number): TextTrackCue;\n [index: number]: TextTrackCue;\n}\n\ndeclare var TextTrackCueList: {\n prototype: TextTrackCueList;\n new(): TextTrackCueList;\n}\n\ninterface TextTrackListEventMap {\n \"addtrack\": TrackEvent;\n}\n\ninterface TextTrackList extends EventTarget {\n readonly length: number;\n onaddtrack: ((this: TextTrackList, ev: TrackEvent) => any) | null;\n item(index: number): TextTrack;\n addEventListener(type: K, listener: (this: TextTrackList, ev: TextTrackListEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [index: number]: TextTrack;\n}\n\ndeclare var TextTrackList: {\n prototype: TextTrackList;\n new(): TextTrackList;\n}\n\ninterface TimeRanges {\n readonly length: number;\n end(index: number): number;\n start(index: number): number;\n}\n\ndeclare var TimeRanges: {\n prototype: TimeRanges;\n new(): TimeRanges;\n}\n\ninterface Touch {\n readonly clientX: number;\n readonly clientY: number;\n readonly identifier: number;\n readonly pageX: number;\n readonly pageY: number;\n readonly screenX: number;\n readonly screenY: number;\n readonly target: EventTarget;\n}\n\ndeclare var Touch: {\n prototype: Touch;\n new(): Touch;\n}\n\ninterface TouchEvent extends UIEvent {\n readonly altKey: boolean;\n readonly changedTouches: TouchList;\n readonly charCode: number;\n readonly ctrlKey: boolean;\n readonly keyCode: number;\n readonly metaKey: boolean;\n readonly shiftKey: boolean;\n readonly targetTouches: TouchList;\n readonly touches: TouchList;\n readonly which: number;\n}\n\ndeclare var TouchEvent: {\n prototype: TouchEvent;\n new(type: string, touchEventInit?: TouchEventInit): TouchEvent;\n}\n\ninterface TouchList {\n readonly length: number;\n item(index: number): Touch | null;\n [index: number]: Touch;\n}\n\ndeclare var TouchList: {\n prototype: TouchList;\n new(): TouchList;\n}\n\ninterface TrackEvent extends Event {\n readonly track: VideoTrack | AudioTrack | TextTrack | null;\n}\n\ndeclare var TrackEvent: {\n prototype: TrackEvent;\n new(typeArg: string, eventInitDict?: TrackEventInit): TrackEvent;\n}\n\ninterface TransitionEvent extends Event {\n readonly elapsedTime: number;\n readonly propertyName: string;\n initTransitionEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, propertyNameArg: string, elapsedTimeArg: number): void;\n}\n\ndeclare var TransitionEvent: {\n prototype: TransitionEvent;\n new(typeArg: string, eventInitDict?: TransitionEventInit): TransitionEvent;\n}\n\ninterface TreeWalker {\n currentNode: Node;\n readonly expandEntityReferences: boolean;\n readonly filter: NodeFilter;\n readonly root: Node;\n readonly whatToShow: number;\n firstChild(): Node;\n lastChild(): Node;\n nextNode(): Node;\n nextSibling(): Node;\n parentNode(): Node;\n previousNode(): Node;\n previousSibling(): Node;\n}\n\ndeclare var TreeWalker: {\n prototype: TreeWalker;\n new(): TreeWalker;\n}\n\ninterface UIEvent extends Event {\n readonly detail: number;\n readonly view: Window;\n initUIEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number): void;\n}\n\ndeclare var UIEvent: {\n prototype: UIEvent;\n new(typeArg: string, eventInitDict?: UIEventInit): UIEvent;\n}\n\ninterface URL {\n hash: string;\n host: string;\n hostname: string;\n href: string;\n readonly origin: string;\n password: string;\n pathname: string;\n port: string;\n protocol: string;\n search: string;\n username: string;\n readonly searchParams: URLSearchParams;\n toString(): string;\n}\n\ndeclare var URL: {\n prototype: URL;\n new(url: string, base?: string): URL;\n createObjectURL(object: any, options?: ObjectURLOptions): string;\n revokeObjectURL(url: string): void;\n}\n\ninterface UnviewableContentIdentifiedEvent extends NavigationEventWithReferrer {\n readonly mediaType: string;\n}\n\ndeclare var UnviewableContentIdentifiedEvent: {\n prototype: UnviewableContentIdentifiedEvent;\n new(): UnviewableContentIdentifiedEvent;\n}\n\ninterface ValidityState {\n readonly badInput: boolean;\n readonly customError: boolean;\n readonly patternMismatch: boolean;\n readonly rangeOverflow: boolean;\n readonly rangeUnderflow: boolean;\n readonly stepMismatch: boolean;\n readonly tooLong: boolean;\n readonly typeMismatch: boolean;\n readonly valid: boolean;\n readonly valueMissing: boolean;\n}\n\ndeclare var ValidityState: {\n prototype: ValidityState;\n new(): ValidityState;\n}\n\ninterface VideoPlaybackQuality {\n readonly corruptedVideoFrames: number;\n readonly creationTime: number;\n readonly droppedVideoFrames: number;\n readonly totalFrameDelay: number;\n readonly totalVideoFrames: number;\n}\n\ndeclare var VideoPlaybackQuality: {\n prototype: VideoPlaybackQuality;\n new(): VideoPlaybackQuality;\n}\n\ninterface VideoTrack {\n readonly id: string;\n kind: string;\n readonly label: string;\n language: string;\n selected: boolean;\n readonly sourceBuffer: SourceBuffer;\n}\n\ndeclare var VideoTrack: {\n prototype: VideoTrack;\n new(): VideoTrack;\n}\n\ninterface VideoTrackListEventMap {\n \"addtrack\": TrackEvent;\n \"change\": Event;\n \"removetrack\": TrackEvent;\n}\n\ninterface VideoTrackList extends EventTarget {\n readonly length: number;\n onaddtrack: (this: VideoTrackList, ev: TrackEvent) => any;\n onchange: (this: VideoTrackList, ev: Event) => any;\n onremovetrack: (this: VideoTrackList, ev: TrackEvent) => any;\n readonly selectedIndex: number;\n getTrackById(id: string): VideoTrack | null;\n item(index: number): VideoTrack;\n addEventListener(type: K, listener: (this: VideoTrackList, ev: VideoTrackListEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [index: number]: VideoTrack;\n}\n\ndeclare var VideoTrackList: {\n prototype: VideoTrackList;\n new(): VideoTrackList;\n}\n\ninterface WEBGL_compressed_texture_s3tc {\n readonly COMPRESSED_RGBA_S3TC_DXT1_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT3_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT5_EXT: number;\n readonly COMPRESSED_RGB_S3TC_DXT1_EXT: number;\n}\n\ndeclare var WEBGL_compressed_texture_s3tc: {\n prototype: WEBGL_compressed_texture_s3tc;\n new(): WEBGL_compressed_texture_s3tc;\n readonly COMPRESSED_RGBA_S3TC_DXT1_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT3_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT5_EXT: number;\n readonly COMPRESSED_RGB_S3TC_DXT1_EXT: number;\n}\n\ninterface WEBGL_debug_renderer_info {\n readonly UNMASKED_RENDERER_WEBGL: number;\n readonly UNMASKED_VENDOR_WEBGL: number;\n}\n\ndeclare var WEBGL_debug_renderer_info: {\n prototype: WEBGL_debug_renderer_info;\n new(): WEBGL_debug_renderer_info;\n readonly UNMASKED_RENDERER_WEBGL: number;\n readonly UNMASKED_VENDOR_WEBGL: number;\n}\n\ninterface WEBGL_depth_texture {\n readonly UNSIGNED_INT_24_8_WEBGL: number;\n}\n\ndeclare var WEBGL_depth_texture: {\n prototype: WEBGL_depth_texture;\n new(): WEBGL_depth_texture;\n readonly UNSIGNED_INT_24_8_WEBGL: number;\n}\n\ninterface WaveShaperNode extends AudioNode {\n curve: Float32Array | null;\n oversample: OverSampleType;\n}\n\ndeclare var WaveShaperNode: {\n prototype: WaveShaperNode;\n new(): WaveShaperNode;\n}\n\ninterface WebAuthentication {\n getAssertion(assertionChallenge: any, options?: AssertionOptions): Promise;\n makeCredential(accountInformation: Account, cryptoParameters: ScopedCredentialParameters[], attestationChallenge: any, options?: ScopedCredentialOptions): Promise;\n}\n\ndeclare var WebAuthentication: {\n prototype: WebAuthentication;\n new(): WebAuthentication;\n}\n\ninterface WebAuthnAssertion {\n readonly authenticatorData: ArrayBuffer;\n readonly clientData: ArrayBuffer;\n readonly credential: ScopedCredential;\n readonly signature: ArrayBuffer;\n}\n\ndeclare var WebAuthnAssertion: {\n prototype: WebAuthnAssertion;\n new(): WebAuthnAssertion;\n}\n\ninterface WebGLActiveInfo {\n readonly name: string;\n readonly size: number;\n readonly type: number;\n}\n\ndeclare var WebGLActiveInfo: {\n prototype: WebGLActiveInfo;\n new(): WebGLActiveInfo;\n}\n\ninterface WebGLBuffer extends WebGLObject {\n}\n\ndeclare var WebGLBuffer: {\n prototype: WebGLBuffer;\n new(): WebGLBuffer;\n}\n\ninterface WebGLContextEvent extends Event {\n readonly statusMessage: string;\n}\n\ndeclare var WebGLContextEvent: {\n prototype: WebGLContextEvent;\n new(typeArg: string, eventInitDict?: WebGLContextEventInit): WebGLContextEvent;\n}\n\ninterface WebGLFramebuffer extends WebGLObject {\n}\n\ndeclare var WebGLFramebuffer: {\n prototype: WebGLFramebuffer;\n new(): WebGLFramebuffer;\n}\n\ninterface WebGLObject {\n}\n\ndeclare var WebGLObject: {\n prototype: WebGLObject;\n new(): WebGLObject;\n}\n\ninterface WebGLProgram extends WebGLObject {\n}\n\ndeclare var WebGLProgram: {\n prototype: WebGLProgram;\n new(): WebGLProgram;\n}\n\ninterface WebGLRenderbuffer extends WebGLObject {\n}\n\ndeclare var WebGLRenderbuffer: {\n prototype: WebGLRenderbuffer;\n new(): WebGLRenderbuffer;\n}\n\ninterface WebGLRenderingContext {\n readonly canvas: HTMLCanvasElement;\n readonly drawingBufferHeight: number;\n readonly drawingBufferWidth: number;\n activeTexture(texture: number): void;\n attachShader(program: WebGLProgram | null, shader: WebGLShader | null): void;\n bindAttribLocation(program: WebGLProgram | null, index: number, name: string): void;\n bindBuffer(target: number, buffer: WebGLBuffer | null): void;\n bindFramebuffer(target: number, framebuffer: WebGLFramebuffer | null): void;\n bindRenderbuffer(target: number, renderbuffer: WebGLRenderbuffer | null): void;\n bindTexture(target: number, texture: WebGLTexture | null): void;\n blendColor(red: number, green: number, blue: number, alpha: number): void;\n blendEquation(mode: number): void;\n blendEquationSeparate(modeRGB: number, modeAlpha: number): void;\n blendFunc(sfactor: number, dfactor: number): void;\n blendFuncSeparate(srcRGB: number, dstRGB: number, srcAlpha: number, dstAlpha: number): void;\n bufferData(target: number, size: number | ArrayBufferView | ArrayBuffer, usage: number): void;\n bufferSubData(target: number, offset: number, data: ArrayBufferView | ArrayBuffer): void;\n checkFramebufferStatus(target: number): number;\n clear(mask: number): void;\n clearColor(red: number, green: number, blue: number, alpha: number): void;\n clearDepth(depth: number): void;\n clearStencil(s: number): void;\n colorMask(red: boolean, green: boolean, blue: boolean, alpha: boolean): void;\n compileShader(shader: WebGLShader | null): void;\n compressedTexImage2D(target: number, level: number, internalformat: number, width: number, height: number, border: number, data: ArrayBufferView): void;\n compressedTexSubImage2D(target: number, level: number, xoffset: number, yoffset: number, width: number, height: number, format: number, data: ArrayBufferView): void;\n copyTexImage2D(target: number, level: number, internalformat: number, x: number, y: number, width: number, height: number, border: number): void;\n copyTexSubImage2D(target: number, level: number, xoffset: number, yoffset: number, x: number, y: number, width: number, height: number): void;\n createBuffer(): WebGLBuffer | null;\n createFramebuffer(): WebGLFramebuffer | null;\n createProgram(): WebGLProgram | null;\n createRenderbuffer(): WebGLRenderbuffer | null;\n createShader(type: number): WebGLShader | null;\n createTexture(): WebGLTexture | null;\n cullFace(mode: number): void;\n deleteBuffer(buffer: WebGLBuffer | null): void;\n deleteFramebuffer(framebuffer: WebGLFramebuffer | null): void;\n deleteProgram(program: WebGLProgram | null): void;\n deleteRenderbuffer(renderbuffer: WebGLRenderbuffer | null): void;\n deleteShader(shader: WebGLShader | null): void;\n deleteTexture(texture: WebGLTexture | null): void;\n depthFunc(func: number): void;\n depthMask(flag: boolean): void;\n depthRange(zNear: number, zFar: number): void;\n detachShader(program: WebGLProgram | null, shader: WebGLShader | null): void;\n disable(cap: number): void;\n disableVertexAttribArray(index: number): void;\n drawArrays(mode: number, first: number, count: number): void;\n drawElements(mode: number, count: number, type: number, offset: number): void;\n enable(cap: number): void;\n enableVertexAttribArray(index: number): void;\n finish(): void;\n flush(): void;\n framebufferRenderbuffer(target: number, attachment: number, renderbuffertarget: number, renderbuffer: WebGLRenderbuffer | null): void;\n framebufferTexture2D(target: number, attachment: number, textarget: number, texture: WebGLTexture | null, level: number): void;\n frontFace(mode: number): void;\n generateMipmap(target: number): void;\n getActiveAttrib(program: WebGLProgram | null, index: number): WebGLActiveInfo | null;\n getActiveUniform(program: WebGLProgram | null, index: number): WebGLActiveInfo | null;\n getAttachedShaders(program: WebGLProgram | null): WebGLShader[] | null;\n getAttribLocation(program: WebGLProgram | null, name: string): number;\n getBufferParameter(target: number, pname: number): any;\n getContextAttributes(): WebGLContextAttributes;\n getError(): number;\n getExtension(name: string): any;\n getFramebufferAttachmentParameter(target: number, attachment: number, pname: number): any;\n getParameter(pname: number): any;\n getProgramInfoLog(program: WebGLProgram | null): string | null;\n getProgramParameter(program: WebGLProgram | null, pname: number): any;\n getRenderbufferParameter(target: number, pname: number): any;\n getShaderInfoLog(shader: WebGLShader | null): string | null;\n getShaderParameter(shader: WebGLShader | null, pname: number): any;\n getShaderPrecisionFormat(shadertype: number, precisiontype: number): WebGLShaderPrecisionFormat | null;\n getShaderSource(shader: WebGLShader | null): string | null;\n getSupportedExtensions(): string[] | null;\n getTexParameter(target: number, pname: number): any;\n getUniform(program: WebGLProgram | null, location: WebGLUniformLocation | null): any;\n getUniformLocation(program: WebGLProgram | null, name: string): WebGLUniformLocation | null;\n getVertexAttrib(index: number, pname: number): any;\n getVertexAttribOffset(index: number, pname: number): number;\n hint(target: number, mode: number): void;\n isBuffer(buffer: WebGLBuffer | null): boolean;\n isContextLost(): boolean;\n isEnabled(cap: number): boolean;\n isFramebuffer(framebuffer: WebGLFramebuffer | null): boolean;\n isProgram(program: WebGLProgram | null): boolean;\n isRenderbuffer(renderbuffer: WebGLRenderbuffer | null): boolean;\n isShader(shader: WebGLShader | null): boolean;\n isTexture(texture: WebGLTexture | null): boolean;\n lineWidth(width: number): void;\n linkProgram(program: WebGLProgram | null): void;\n pixelStorei(pname: number, param: number | boolean): void;\n polygonOffset(factor: number, units: number): void;\n readPixels(x: number, y: number, width: number, height: number, format: number, type: number, pixels: ArrayBufferView | null): void;\n renderbufferStorage(target: number, internalformat: number, width: number, height: number): void;\n sampleCoverage(value: number, invert: boolean): void;\n scissor(x: number, y: number, width: number, height: number): void;\n shaderSource(shader: WebGLShader | null, source: string): void;\n stencilFunc(func: number, ref: number, mask: number): void;\n stencilFuncSeparate(face: number, func: number, ref: number, mask: number): void;\n stencilMask(mask: number): void;\n stencilMaskSeparate(face: number, mask: number): void;\n stencilOp(fail: number, zfail: number, zpass: number): void;\n stencilOpSeparate(face: number, fail: number, zfail: number, zpass: number): void;\n texImage2D(target: number, level: number, internalformat: number, width: number, height: number, border: number, format: number, type: number, pixels: ArrayBufferView | null): void;\n texImage2D(target: number, level: number, internalformat: number, format: number, type: number, pixels: ImageBitmap | ImageData | HTMLVideoElement | HTMLImageElement | HTMLCanvasElement): void;\n texParameterf(target: number, pname: number, param: number): void;\n texParameteri(target: number, pname: number, param: number): void;\n texSubImage2D(target: number, level: number, xoffset: number, yoffset: number, width: number, height: number, format: number, type: number, pixels: ArrayBufferView | null): void;\n texSubImage2D(target: number, level: number, xoffset: number, yoffset: number, format: number, type: number, pixels: ImageBitmap | ImageData | HTMLVideoElement | HTMLImageElement | HTMLCanvasElement): void;\n uniform1f(location: WebGLUniformLocation | null, x: number): void;\n uniform1fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform1i(location: WebGLUniformLocation | null, x: number): void;\n uniform1iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniform2f(location: WebGLUniformLocation | null, x: number, y: number): void;\n uniform2fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform2i(location: WebGLUniformLocation | null, x: number, y: number): void;\n uniform2iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniform3f(location: WebGLUniformLocation | null, x: number, y: number, z: number): void;\n uniform3fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform3i(location: WebGLUniformLocation | null, x: number, y: number, z: number): void;\n uniform3iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniform4f(location: WebGLUniformLocation | null, x: number, y: number, z: number, w: number): void;\n uniform4fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform4i(location: WebGLUniformLocation | null, x: number, y: number, z: number, w: number): void;\n uniform4iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniformMatrix2fv(location: WebGLUniformLocation, transpose: boolean, value: Float32Array | number[]): void;\n uniformMatrix3fv(location: WebGLUniformLocation, transpose: boolean, value: Float32Array | number[]): void;\n uniformMatrix4fv(location: WebGLUniformLocation, transpose: boolean, value: Float32Array | number[]): void;\n useProgram(program: WebGLProgram | null): void;\n validateProgram(program: WebGLProgram | null): void;\n vertexAttrib1f(indx: number, x: number): void;\n vertexAttrib1fv(indx: number, values: Float32Array | number[]): void;\n vertexAttrib2f(indx: number, x: number, y: number): void;\n vertexAttrib2fv(indx: number, values: Float32Array | number[]): void;\n vertexAttrib3f(indx: number, x: number, y: number, z: number): void;\n vertexAttrib3fv(indx: number, values: Float32Array | number[]): void;\n vertexAttrib4f(indx: number, x: number, y: number, z: number, w: number): void;\n vertexAttrib4fv(indx: number, values: Float32Array | number[]): void;\n vertexAttribPointer(indx: number, size: number, type: number, normalized: boolean, stride: number, offset: number): void;\n viewport(x: number, y: number, width: number, height: number): void;\n readonly ACTIVE_ATTRIBUTES: number;\n readonly ACTIVE_TEXTURE: number;\n readonly ACTIVE_UNIFORMS: number;\n readonly ALIASED_LINE_WIDTH_RANGE: number;\n readonly ALIASED_POINT_SIZE_RANGE: number;\n readonly ALPHA: number;\n readonly ALPHA_BITS: number;\n readonly ALWAYS: number;\n readonly ARRAY_BUFFER: number;\n readonly ARRAY_BUFFER_BINDING: number;\n readonly ATTACHED_SHADERS: number;\n readonly BACK: number;\n readonly BLEND: number;\n readonly BLEND_COLOR: number;\n readonly BLEND_DST_ALPHA: number;\n readonly BLEND_DST_RGB: number;\n readonly BLEND_EQUATION: number;\n readonly BLEND_EQUATION_ALPHA: number;\n readonly BLEND_EQUATION_RGB: number;\n readonly BLEND_SRC_ALPHA: number;\n readonly BLEND_SRC_RGB: number;\n readonly BLUE_BITS: number;\n readonly BOOL: number;\n readonly BOOL_VEC2: number;\n readonly BOOL_VEC3: number;\n readonly BOOL_VEC4: number;\n readonly BROWSER_DEFAULT_WEBGL: number;\n readonly BUFFER_SIZE: number;\n readonly BUFFER_USAGE: number;\n readonly BYTE: number;\n readonly CCW: number;\n readonly CLAMP_TO_EDGE: number;\n readonly COLOR_ATTACHMENT0: number;\n readonly COLOR_BUFFER_BIT: number;\n readonly COLOR_CLEAR_VALUE: number;\n readonly COLOR_WRITEMASK: number;\n readonly COMPILE_STATUS: number;\n readonly COMPRESSED_TEXTURE_FORMATS: number;\n readonly CONSTANT_ALPHA: number;\n readonly CONSTANT_COLOR: number;\n readonly CONTEXT_LOST_WEBGL: number;\n readonly CULL_FACE: number;\n readonly CULL_FACE_MODE: number;\n readonly CURRENT_PROGRAM: number;\n readonly CURRENT_VERTEX_ATTRIB: number;\n readonly CW: number;\n readonly DECR: number;\n readonly DECR_WRAP: number;\n readonly DELETE_STATUS: number;\n readonly DEPTH_ATTACHMENT: number;\n readonly DEPTH_BITS: number;\n readonly DEPTH_BUFFER_BIT: number;\n readonly DEPTH_CLEAR_VALUE: number;\n readonly DEPTH_COMPONENT: number;\n readonly DEPTH_COMPONENT16: number;\n readonly DEPTH_FUNC: number;\n readonly DEPTH_RANGE: number;\n readonly DEPTH_STENCIL: number;\n readonly DEPTH_STENCIL_ATTACHMENT: number;\n readonly DEPTH_TEST: number;\n readonly DEPTH_WRITEMASK: number;\n readonly DITHER: number;\n readonly DONT_CARE: number;\n readonly DST_ALPHA: number;\n readonly DST_COLOR: number;\n readonly DYNAMIC_DRAW: number;\n readonly ELEMENT_ARRAY_BUFFER: number;\n readonly ELEMENT_ARRAY_BUFFER_BINDING: number;\n readonly EQUAL: number;\n readonly FASTEST: number;\n readonly FLOAT: number;\n readonly FLOAT_MAT2: number;\n readonly FLOAT_MAT3: number;\n readonly FLOAT_MAT4: number;\n readonly FLOAT_VEC2: number;\n readonly FLOAT_VEC3: number;\n readonly FLOAT_VEC4: number;\n readonly FRAGMENT_SHADER: number;\n readonly FRAMEBUFFER: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_NAME: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL: number;\n readonly FRAMEBUFFER_BINDING: number;\n readonly FRAMEBUFFER_COMPLETE: number;\n readonly FRAMEBUFFER_INCOMPLETE_ATTACHMENT: number;\n readonly FRAMEBUFFER_INCOMPLETE_DIMENSIONS: number;\n readonly FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT: number;\n readonly FRAMEBUFFER_UNSUPPORTED: number;\n readonly FRONT: number;\n readonly FRONT_AND_BACK: number;\n readonly FRONT_FACE: number;\n readonly FUNC_ADD: number;\n readonly FUNC_REVERSE_SUBTRACT: number;\n readonly FUNC_SUBTRACT: number;\n readonly GENERATE_MIPMAP_HINT: number;\n readonly GEQUAL: number;\n readonly GREATER: number;\n readonly GREEN_BITS: number;\n readonly HIGH_FLOAT: number;\n readonly HIGH_INT: number;\n readonly IMPLEMENTATION_COLOR_READ_FORMAT: number;\n readonly IMPLEMENTATION_COLOR_READ_TYPE: number;\n readonly INCR: number;\n readonly INCR_WRAP: number;\n readonly INT: number;\n readonly INT_VEC2: number;\n readonly INT_VEC3: number;\n readonly INT_VEC4: number;\n readonly INVALID_ENUM: number;\n readonly INVALID_FRAMEBUFFER_OPERATION: number;\n readonly INVALID_OPERATION: number;\n readonly INVALID_VALUE: number;\n readonly INVERT: number;\n readonly KEEP: number;\n readonly LEQUAL: number;\n readonly LESS: number;\n readonly LINEAR: number;\n readonly LINEAR_MIPMAP_LINEAR: number;\n readonly LINEAR_MIPMAP_NEAREST: number;\n readonly LINES: number;\n readonly LINE_LOOP: number;\n readonly LINE_STRIP: number;\n readonly LINE_WIDTH: number;\n readonly LINK_STATUS: number;\n readonly LOW_FLOAT: number;\n readonly LOW_INT: number;\n readonly LUMINANCE: number;\n readonly LUMINANCE_ALPHA: number;\n readonly MAX_COMBINED_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_CUBE_MAP_TEXTURE_SIZE: number;\n readonly MAX_FRAGMENT_UNIFORM_VECTORS: number;\n readonly MAX_RENDERBUFFER_SIZE: number;\n readonly MAX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_TEXTURE_SIZE: number;\n readonly MAX_VARYING_VECTORS: number;\n readonly MAX_VERTEX_ATTRIBS: number;\n readonly MAX_VERTEX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_VERTEX_UNIFORM_VECTORS: number;\n readonly MAX_VIEWPORT_DIMS: number;\n readonly MEDIUM_FLOAT: number;\n readonly MEDIUM_INT: number;\n readonly MIRRORED_REPEAT: number;\n readonly NEAREST: number;\n readonly NEAREST_MIPMAP_LINEAR: number;\n readonly NEAREST_MIPMAP_NEAREST: number;\n readonly NEVER: number;\n readonly NICEST: number;\n readonly NONE: number;\n readonly NOTEQUAL: number;\n readonly NO_ERROR: number;\n readonly ONE: number;\n readonly ONE_MINUS_CONSTANT_ALPHA: number;\n readonly ONE_MINUS_CONSTANT_COLOR: number;\n readonly ONE_MINUS_DST_ALPHA: number;\n readonly ONE_MINUS_DST_COLOR: number;\n readonly ONE_MINUS_SRC_ALPHA: number;\n readonly ONE_MINUS_SRC_COLOR: number;\n readonly OUT_OF_MEMORY: number;\n readonly PACK_ALIGNMENT: number;\n readonly POINTS: number;\n readonly POLYGON_OFFSET_FACTOR: number;\n readonly POLYGON_OFFSET_FILL: number;\n readonly POLYGON_OFFSET_UNITS: number;\n readonly RED_BITS: number;\n readonly RENDERBUFFER: number;\n readonly RENDERBUFFER_ALPHA_SIZE: number;\n readonly RENDERBUFFER_BINDING: number;\n readonly RENDERBUFFER_BLUE_SIZE: number;\n readonly RENDERBUFFER_DEPTH_SIZE: number;\n readonly RENDERBUFFER_GREEN_SIZE: number;\n readonly RENDERBUFFER_HEIGHT: number;\n readonly RENDERBUFFER_INTERNAL_FORMAT: number;\n readonly RENDERBUFFER_RED_SIZE: number;\n readonly RENDERBUFFER_STENCIL_SIZE: number;\n readonly RENDERBUFFER_WIDTH: number;\n readonly RENDERER: number;\n readonly REPEAT: number;\n readonly REPLACE: number;\n readonly RGB: number;\n readonly RGB565: number;\n readonly RGB5_A1: number;\n readonly RGBA: number;\n readonly RGBA4: number;\n readonly SAMPLER_2D: number;\n readonly SAMPLER_CUBE: number;\n readonly SAMPLES: number;\n readonly SAMPLE_ALPHA_TO_COVERAGE: number;\n readonly SAMPLE_BUFFERS: number;\n readonly SAMPLE_COVERAGE: number;\n readonly SAMPLE_COVERAGE_INVERT: number;\n readonly SAMPLE_COVERAGE_VALUE: number;\n readonly SCISSOR_BOX: number;\n readonly SCISSOR_TEST: number;\n readonly SHADER_TYPE: number;\n readonly SHADING_LANGUAGE_VERSION: number;\n readonly SHORT: number;\n readonly SRC_ALPHA: number;\n readonly SRC_ALPHA_SATURATE: number;\n readonly SRC_COLOR: number;\n readonly STATIC_DRAW: number;\n readonly STENCIL_ATTACHMENT: number;\n readonly STENCIL_BACK_FAIL: number;\n readonly STENCIL_BACK_FUNC: number;\n readonly STENCIL_BACK_PASS_DEPTH_FAIL: number;\n readonly STENCIL_BACK_PASS_DEPTH_PASS: number;\n readonly STENCIL_BACK_REF: number;\n readonly STENCIL_BACK_VALUE_MASK: number;\n readonly STENCIL_BACK_WRITEMASK: number;\n readonly STENCIL_BITS: number;\n readonly STENCIL_BUFFER_BIT: number;\n readonly STENCIL_CLEAR_VALUE: number;\n readonly STENCIL_FAIL: number;\n readonly STENCIL_FUNC: number;\n readonly STENCIL_INDEX: number;\n readonly STENCIL_INDEX8: number;\n readonly STENCIL_PASS_DEPTH_FAIL: number;\n readonly STENCIL_PASS_DEPTH_PASS: number;\n readonly STENCIL_REF: number;\n readonly STENCIL_TEST: number;\n readonly STENCIL_VALUE_MASK: number;\n readonly STENCIL_WRITEMASK: number;\n readonly STREAM_DRAW: number;\n readonly SUBPIXEL_BITS: number;\n readonly TEXTURE: number;\n readonly TEXTURE0: number;\n readonly TEXTURE1: number;\n readonly TEXTURE10: number;\n readonly TEXTURE11: number;\n readonly TEXTURE12: number;\n readonly TEXTURE13: number;\n readonly TEXTURE14: number;\n readonly TEXTURE15: number;\n readonly TEXTURE16: number;\n readonly TEXTURE17: number;\n readonly TEXTURE18: number;\n readonly TEXTURE19: number;\n readonly TEXTURE2: number;\n readonly TEXTURE20: number;\n readonly TEXTURE21: number;\n readonly TEXTURE22: number;\n readonly TEXTURE23: number;\n readonly TEXTURE24: number;\n readonly TEXTURE25: number;\n readonly TEXTURE26: number;\n readonly TEXTURE27: number;\n readonly TEXTURE28: number;\n readonly TEXTURE29: number;\n readonly TEXTURE3: number;\n readonly TEXTURE30: number;\n readonly TEXTURE31: number;\n readonly TEXTURE4: number;\n readonly TEXTURE5: number;\n readonly TEXTURE6: number;\n readonly TEXTURE7: number;\n readonly TEXTURE8: number;\n readonly TEXTURE9: number;\n readonly TEXTURE_2D: number;\n readonly TEXTURE_BINDING_2D: number;\n readonly TEXTURE_BINDING_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_X: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Z: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_X: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Z: number;\n readonly TEXTURE_MAG_FILTER: number;\n readonly TEXTURE_MIN_FILTER: number;\n readonly TEXTURE_WRAP_S: number;\n readonly TEXTURE_WRAP_T: number;\n readonly TRIANGLES: number;\n readonly TRIANGLE_FAN: number;\n readonly TRIANGLE_STRIP: number;\n readonly UNPACK_ALIGNMENT: number;\n readonly UNPACK_COLORSPACE_CONVERSION_WEBGL: number;\n readonly UNPACK_FLIP_Y_WEBGL: number;\n readonly UNPACK_PREMULTIPLY_ALPHA_WEBGL: number;\n readonly UNSIGNED_BYTE: number;\n readonly UNSIGNED_INT: number;\n readonly UNSIGNED_SHORT: number;\n readonly UNSIGNED_SHORT_4_4_4_4: number;\n readonly UNSIGNED_SHORT_5_5_5_1: number;\n readonly UNSIGNED_SHORT_5_6_5: number;\n readonly VALIDATE_STATUS: number;\n readonly VENDOR: number;\n readonly VERSION: number;\n readonly VERTEX_ATTRIB_ARRAY_BUFFER_BINDING: number;\n readonly VERTEX_ATTRIB_ARRAY_ENABLED: number;\n readonly VERTEX_ATTRIB_ARRAY_NORMALIZED: number;\n readonly VERTEX_ATTRIB_ARRAY_POINTER: number;\n readonly VERTEX_ATTRIB_ARRAY_SIZE: number;\n readonly VERTEX_ATTRIB_ARRAY_STRIDE: number;\n readonly VERTEX_ATTRIB_ARRAY_TYPE: number;\n readonly VERTEX_SHADER: number;\n readonly VIEWPORT: number;\n readonly ZERO: number;\n}\n\ndeclare var WebGLRenderingContext: {\n prototype: WebGLRenderingContext;\n new(): WebGLRenderingContext;\n readonly ACTIVE_ATTRIBUTES: number;\n readonly ACTIVE_TEXTURE: number;\n readonly ACTIVE_UNIFORMS: number;\n readonly ALIASED_LINE_WIDTH_RANGE: number;\n readonly ALIASED_POINT_SIZE_RANGE: number;\n readonly ALPHA: number;\n readonly ALPHA_BITS: number;\n readonly ALWAYS: number;\n readonly ARRAY_BUFFER: number;\n readonly ARRAY_BUFFER_BINDING: number;\n readonly ATTACHED_SHADERS: number;\n readonly BACK: number;\n readonly BLEND: number;\n readonly BLEND_COLOR: number;\n readonly BLEND_DST_ALPHA: number;\n readonly BLEND_DST_RGB: number;\n readonly BLEND_EQUATION: number;\n readonly BLEND_EQUATION_ALPHA: number;\n readonly BLEND_EQUATION_RGB: number;\n readonly BLEND_SRC_ALPHA: number;\n readonly BLEND_SRC_RGB: number;\n readonly BLUE_BITS: number;\n readonly BOOL: number;\n readonly BOOL_VEC2: number;\n readonly BOOL_VEC3: number;\n readonly BOOL_VEC4: number;\n readonly BROWSER_DEFAULT_WEBGL: number;\n readonly BUFFER_SIZE: number;\n readonly BUFFER_USAGE: number;\n readonly BYTE: number;\n readonly CCW: number;\n readonly CLAMP_TO_EDGE: number;\n readonly COLOR_ATTACHMENT0: number;\n readonly COLOR_BUFFER_BIT: number;\n readonly COLOR_CLEAR_VALUE: number;\n readonly COLOR_WRITEMASK: number;\n readonly COMPILE_STATUS: number;\n readonly COMPRESSED_TEXTURE_FORMATS: number;\n readonly CONSTANT_ALPHA: number;\n readonly CONSTANT_COLOR: number;\n readonly CONTEXT_LOST_WEBGL: number;\n readonly CULL_FACE: number;\n readonly CULL_FACE_MODE: number;\n readonly CURRENT_PROGRAM: number;\n readonly CURRENT_VERTEX_ATTRIB: number;\n readonly CW: number;\n readonly DECR: number;\n readonly DECR_WRAP: number;\n readonly DELETE_STATUS: number;\n readonly DEPTH_ATTACHMENT: number;\n readonly DEPTH_BITS: number;\n readonly DEPTH_BUFFER_BIT: number;\n readonly DEPTH_CLEAR_VALUE: number;\n readonly DEPTH_COMPONENT: number;\n readonly DEPTH_COMPONENT16: number;\n readonly DEPTH_FUNC: number;\n readonly DEPTH_RANGE: number;\n readonly DEPTH_STENCIL: number;\n readonly DEPTH_STENCIL_ATTACHMENT: number;\n readonly DEPTH_TEST: number;\n readonly DEPTH_WRITEMASK: number;\n readonly DITHER: number;\n readonly DONT_CARE: number;\n readonly DST_ALPHA: number;\n readonly DST_COLOR: number;\n readonly DYNAMIC_DRAW: number;\n readonly ELEMENT_ARRAY_BUFFER: number;\n readonly ELEMENT_ARRAY_BUFFER_BINDING: number;\n readonly EQUAL: number;\n readonly FASTEST: number;\n readonly FLOAT: number;\n readonly FLOAT_MAT2: number;\n readonly FLOAT_MAT3: number;\n readonly FLOAT_MAT4: number;\n readonly FLOAT_VEC2: number;\n readonly FLOAT_VEC3: number;\n readonly FLOAT_VEC4: number;\n readonly FRAGMENT_SHADER: number;\n readonly FRAMEBUFFER: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_NAME: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL: number;\n readonly FRAMEBUFFER_BINDING: number;\n readonly FRAMEBUFFER_COMPLETE: number;\n readonly FRAMEBUFFER_INCOMPLETE_ATTACHMENT: number;\n readonly FRAMEBUFFER_INCOMPLETE_DIMENSIONS: number;\n readonly FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT: number;\n readonly FRAMEBUFFER_UNSUPPORTED: number;\n readonly FRONT: number;\n readonly FRONT_AND_BACK: number;\n readonly FRONT_FACE: number;\n readonly FUNC_ADD: number;\n readonly FUNC_REVERSE_SUBTRACT: number;\n readonly FUNC_SUBTRACT: number;\n readonly GENERATE_MIPMAP_HINT: number;\n readonly GEQUAL: number;\n readonly GREATER: number;\n readonly GREEN_BITS: number;\n readonly HIGH_FLOAT: number;\n readonly HIGH_INT: number;\n readonly IMPLEMENTATION_COLOR_READ_FORMAT: number;\n readonly IMPLEMENTATION_COLOR_READ_TYPE: number;\n readonly INCR: number;\n readonly INCR_WRAP: number;\n readonly INT: number;\n readonly INT_VEC2: number;\n readonly INT_VEC3: number;\n readonly INT_VEC4: number;\n readonly INVALID_ENUM: number;\n readonly INVALID_FRAMEBUFFER_OPERATION: number;\n readonly INVALID_OPERATION: number;\n readonly INVALID_VALUE: number;\n readonly INVERT: number;\n readonly KEEP: number;\n readonly LEQUAL: number;\n readonly LESS: number;\n readonly LINEAR: number;\n readonly LINEAR_MIPMAP_LINEAR: number;\n readonly LINEAR_MIPMAP_NEAREST: number;\n readonly LINES: number;\n readonly LINE_LOOP: number;\n readonly LINE_STRIP: number;\n readonly LINE_WIDTH: number;\n readonly LINK_STATUS: number;\n readonly LOW_FLOAT: number;\n readonly LOW_INT: number;\n readonly LUMINANCE: number;\n readonly LUMINANCE_ALPHA: number;\n readonly MAX_COMBINED_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_CUBE_MAP_TEXTURE_SIZE: number;\n readonly MAX_FRAGMENT_UNIFORM_VECTORS: number;\n readonly MAX_RENDERBUFFER_SIZE: number;\n readonly MAX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_TEXTURE_SIZE: number;\n readonly MAX_VARYING_VECTORS: number;\n readonly MAX_VERTEX_ATTRIBS: number;\n readonly MAX_VERTEX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_VERTEX_UNIFORM_VECTORS: number;\n readonly MAX_VIEWPORT_DIMS: number;\n readonly MEDIUM_FLOAT: number;\n readonly MEDIUM_INT: number;\n readonly MIRRORED_REPEAT: number;\n readonly NEAREST: number;\n readonly NEAREST_MIPMAP_LINEAR: number;\n readonly NEAREST_MIPMAP_NEAREST: number;\n readonly NEVER: number;\n readonly NICEST: number;\n readonly NONE: number;\n readonly NOTEQUAL: number;\n readonly NO_ERROR: number;\n readonly ONE: number;\n readonly ONE_MINUS_CONSTANT_ALPHA: number;\n readonly ONE_MINUS_CONSTANT_COLOR: number;\n readonly ONE_MINUS_DST_ALPHA: number;\n readonly ONE_MINUS_DST_COLOR: number;\n readonly ONE_MINUS_SRC_ALPHA: number;\n readonly ONE_MINUS_SRC_COLOR: number;\n readonly OUT_OF_MEMORY: number;\n readonly PACK_ALIGNMENT: number;\n readonly POINTS: number;\n readonly POLYGON_OFFSET_FACTOR: number;\n readonly POLYGON_OFFSET_FILL: number;\n readonly POLYGON_OFFSET_UNITS: number;\n readonly RED_BITS: number;\n readonly RENDERBUFFER: number;\n readonly RENDERBUFFER_ALPHA_SIZE: number;\n readonly RENDERBUFFER_BINDING: number;\n readonly RENDERBUFFER_BLUE_SIZE: number;\n readonly RENDERBUFFER_DEPTH_SIZE: number;\n readonly RENDERBUFFER_GREEN_SIZE: number;\n readonly RENDERBUFFER_HEIGHT: number;\n readonly RENDERBUFFER_INTERNAL_FORMAT: number;\n readonly RENDERBUFFER_RED_SIZE: number;\n readonly RENDERBUFFER_STENCIL_SIZE: number;\n readonly RENDERBUFFER_WIDTH: number;\n readonly RENDERER: number;\n readonly REPEAT: number;\n readonly REPLACE: number;\n readonly RGB: number;\n readonly RGB565: number;\n readonly RGB5_A1: number;\n readonly RGBA: number;\n readonly RGBA4: number;\n readonly SAMPLER_2D: number;\n readonly SAMPLER_CUBE: number;\n readonly SAMPLES: number;\n readonly SAMPLE_ALPHA_TO_COVERAGE: number;\n readonly SAMPLE_BUFFERS: number;\n readonly SAMPLE_COVERAGE: number;\n readonly SAMPLE_COVERAGE_INVERT: number;\n readonly SAMPLE_COVERAGE_VALUE: number;\n readonly SCISSOR_BOX: number;\n readonly SCISSOR_TEST: number;\n readonly SHADER_TYPE: number;\n readonly SHADING_LANGUAGE_VERSION: number;\n readonly SHORT: number;\n readonly SRC_ALPHA: number;\n readonly SRC_ALPHA_SATURATE: number;\n readonly SRC_COLOR: number;\n readonly STATIC_DRAW: number;\n readonly STENCIL_ATTACHMENT: number;\n readonly STENCIL_BACK_FAIL: number;\n readonly STENCIL_BACK_FUNC: number;\n readonly STENCIL_BACK_PASS_DEPTH_FAIL: number;\n readonly STENCIL_BACK_PASS_DEPTH_PASS: number;\n readonly STENCIL_BACK_REF: number;\n readonly STENCIL_BACK_VALUE_MASK: number;\n readonly STENCIL_BACK_WRITEMASK: number;\n readonly STENCIL_BITS: number;\n readonly STENCIL_BUFFER_BIT: number;\n readonly STENCIL_CLEAR_VALUE: number;\n readonly STENCIL_FAIL: number;\n readonly STENCIL_FUNC: number;\n readonly STENCIL_INDEX: number;\n readonly STENCIL_INDEX8: number;\n readonly STENCIL_PASS_DEPTH_FAIL: number;\n readonly STENCIL_PASS_DEPTH_PASS: number;\n readonly STENCIL_REF: number;\n readonly STENCIL_TEST: number;\n readonly STENCIL_VALUE_MASK: number;\n readonly STENCIL_WRITEMASK: number;\n readonly STREAM_DRAW: number;\n readonly SUBPIXEL_BITS: number;\n readonly TEXTURE: number;\n readonly TEXTURE0: number;\n readonly TEXTURE1: number;\n readonly TEXTURE10: number;\n readonly TEXTURE11: number;\n readonly TEXTURE12: number;\n readonly TEXTURE13: number;\n readonly TEXTURE14: number;\n readonly TEXTURE15: number;\n readonly TEXTURE16: number;\n readonly TEXTURE17: number;\n readonly TEXTURE18: number;\n readonly TEXTURE19: number;\n readonly TEXTURE2: number;\n readonly TEXTURE20: number;\n readonly TEXTURE21: number;\n readonly TEXTURE22: number;\n readonly TEXTURE23: number;\n readonly TEXTURE24: number;\n readonly TEXTURE25: number;\n readonly TEXTURE26: number;\n readonly TEXTURE27: number;\n readonly TEXTURE28: number;\n readonly TEXTURE29: number;\n readonly TEXTURE3: number;\n readonly TEXTURE30: number;\n readonly TEXTURE31: number;\n readonly TEXTURE4: number;\n readonly TEXTURE5: number;\n readonly TEXTURE6: number;\n readonly TEXTURE7: number;\n readonly TEXTURE8: number;\n readonly TEXTURE9: number;\n readonly TEXTURE_2D: number;\n readonly TEXTURE_BINDING_2D: number;\n readonly TEXTURE_BINDING_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_X: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Z: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_X: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Z: number;\n readonly TEXTURE_MAG_FILTER: number;\n readonly TEXTURE_MIN_FILTER: number;\n readonly TEXTURE_WRAP_S: number;\n readonly TEXTURE_WRAP_T: number;\n readonly TRIANGLES: number;\n readonly TRIANGLE_FAN: number;\n readonly TRIANGLE_STRIP: number;\n readonly UNPACK_ALIGNMENT: number;\n readonly UNPACK_COLORSPACE_CONVERSION_WEBGL: number;\n readonly UNPACK_FLIP_Y_WEBGL: number;\n readonly UNPACK_PREMULTIPLY_ALPHA_WEBGL: number;\n readonly UNSIGNED_BYTE: number;\n readonly UNSIGNED_INT: number;\n readonly UNSIGNED_SHORT: number;\n readonly UNSIGNED_SHORT_4_4_4_4: number;\n readonly UNSIGNED_SHORT_5_5_5_1: number;\n readonly UNSIGNED_SHORT_5_6_5: number;\n readonly VALIDATE_STATUS: number;\n readonly VENDOR: number;\n readonly VERSION: number;\n readonly VERTEX_ATTRIB_ARRAY_BUFFER_BINDING: number;\n readonly VERTEX_ATTRIB_ARRAY_ENABLED: number;\n readonly VERTEX_ATTRIB_ARRAY_NORMALIZED: number;\n readonly VERTEX_ATTRIB_ARRAY_POINTER: number;\n readonly VERTEX_ATTRIB_ARRAY_SIZE: number;\n readonly VERTEX_ATTRIB_ARRAY_STRIDE: number;\n readonly VERTEX_ATTRIB_ARRAY_TYPE: number;\n readonly VERTEX_SHADER: number;\n readonly VIEWPORT: number;\n readonly ZERO: number;\n}\n\ninterface WebGLShader extends WebGLObject {\n}\n\ndeclare var WebGLShader: {\n prototype: WebGLShader;\n new(): WebGLShader;\n}\n\ninterface WebGLShaderPrecisionFormat {\n readonly precision: number;\n readonly rangeMax: number;\n readonly rangeMin: number;\n}\n\ndeclare var WebGLShaderPrecisionFormat: {\n prototype: WebGLShaderPrecisionFormat;\n new(): WebGLShaderPrecisionFormat;\n}\n\ninterface WebGLTexture extends WebGLObject {\n}\n\ndeclare var WebGLTexture: {\n prototype: WebGLTexture;\n new(): WebGLTexture;\n}\n\ninterface WebGLUniformLocation {\n}\n\ndeclare var WebGLUniformLocation: {\n prototype: WebGLUniformLocation;\n new(): WebGLUniformLocation;\n}\n\ninterface WebKitCSSMatrix {\n a: number;\n b: number;\n c: number;\n d: number;\n e: number;\n f: number;\n m11: number;\n m12: number;\n m13: number;\n m14: number;\n m21: number;\n m22: number;\n m23: number;\n m24: number;\n m31: number;\n m32: number;\n m33: number;\n m34: number;\n m41: number;\n m42: number;\n m43: number;\n m44: number;\n inverse(): WebKitCSSMatrix;\n multiply(secondMatrix: WebKitCSSMatrix): WebKitCSSMatrix;\n rotate(angleX: number, angleY?: number, angleZ?: number): WebKitCSSMatrix;\n rotateAxisAngle(x: number, y: number, z: number, angle: number): WebKitCSSMatrix;\n scale(scaleX: number, scaleY?: number, scaleZ?: number): WebKitCSSMatrix;\n setMatrixValue(value: string): void;\n skewX(angle: number): WebKitCSSMatrix;\n skewY(angle: number): WebKitCSSMatrix;\n toString(): string;\n translate(x: number, y: number, z?: number): WebKitCSSMatrix;\n}\n\ndeclare var WebKitCSSMatrix: {\n prototype: WebKitCSSMatrix;\n new(text?: string): WebKitCSSMatrix;\n}\n\ninterface WebKitDirectoryEntry extends WebKitEntry {\n createReader(): WebKitDirectoryReader;\n}\n\ndeclare var WebKitDirectoryEntry: {\n prototype: WebKitDirectoryEntry;\n new(): WebKitDirectoryEntry;\n}\n\ninterface WebKitDirectoryReader {\n readEntries(successCallback: WebKitEntriesCallback, errorCallback?: WebKitErrorCallback): void;\n}\n\ndeclare var WebKitDirectoryReader: {\n prototype: WebKitDirectoryReader;\n new(): WebKitDirectoryReader;\n}\n\ninterface WebKitEntry {\n readonly filesystem: WebKitFileSystem;\n readonly fullPath: string;\n readonly isDirectory: boolean;\n readonly isFile: boolean;\n readonly name: string;\n}\n\ndeclare var WebKitEntry: {\n prototype: WebKitEntry;\n new(): WebKitEntry;\n}\n\ninterface WebKitFileEntry extends WebKitEntry {\n file(successCallback: WebKitFileCallback, errorCallback?: WebKitErrorCallback): void;\n}\n\ndeclare var WebKitFileEntry: {\n prototype: WebKitFileEntry;\n new(): WebKitFileEntry;\n}\n\ninterface WebKitFileSystem {\n readonly name: string;\n readonly root: WebKitDirectoryEntry;\n}\n\ndeclare var WebKitFileSystem: {\n prototype: WebKitFileSystem;\n new(): WebKitFileSystem;\n}\n\ninterface WebKitPoint {\n x: number;\n y: number;\n}\n\ndeclare var WebKitPoint: {\n prototype: WebKitPoint;\n new(x?: number, y?: number): WebKitPoint;\n}\n\ninterface WebSocketEventMap {\n \"close\": CloseEvent;\n \"error\": Event;\n \"message\": MessageEvent;\n \"open\": Event;\n}\n\ninterface WebSocket extends EventTarget {\n binaryType: string;\n readonly bufferedAmount: number;\n readonly extensions: string;\n onclose: (this: WebSocket, ev: CloseEvent) => any;\n onerror: (this: WebSocket, ev: Event) => any;\n onmessage: (this: WebSocket, ev: MessageEvent) => any;\n onopen: (this: WebSocket, ev: Event) => any;\n readonly protocol: string;\n readonly readyState: number;\n readonly url: string;\n close(code?: number, reason?: string): void;\n send(data: any): void;\n readonly CLOSED: number;\n readonly CLOSING: number;\n readonly CONNECTING: number;\n readonly OPEN: number;\n addEventListener(type: K, listener: (this: WebSocket, ev: WebSocketEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var WebSocket: {\n prototype: WebSocket;\n new(url: string, protocols?: string | string[]): WebSocket;\n readonly CLOSED: number;\n readonly CLOSING: number;\n readonly CONNECTING: number;\n readonly OPEN: number;\n}\n\ninterface WheelEvent extends MouseEvent {\n readonly deltaMode: number;\n readonly deltaX: number;\n readonly deltaY: number;\n readonly deltaZ: number;\n readonly wheelDelta: number;\n readonly wheelDeltaX: number;\n readonly wheelDeltaY: number;\n getCurrentPoint(element: Element): void;\n initWheelEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, buttonArg: number, relatedTargetArg: EventTarget, modifiersListArg: string, deltaXArg: number, deltaYArg: number, deltaZArg: number, deltaMode: number): void;\n readonly DOM_DELTA_LINE: number;\n readonly DOM_DELTA_PAGE: number;\n readonly DOM_DELTA_PIXEL: number;\n}\n\ndeclare var WheelEvent: {\n prototype: WheelEvent;\n new(typeArg: string, eventInitDict?: WheelEventInit): WheelEvent;\n readonly DOM_DELTA_LINE: number;\n readonly DOM_DELTA_PAGE: number;\n readonly DOM_DELTA_PIXEL: number;\n}\n\ninterface WindowEventMap extends GlobalEventHandlersEventMap {\n \"abort\": UIEvent;\n \"afterprint\": Event;\n \"beforeprint\": Event;\n \"beforeunload\": BeforeUnloadEvent;\n \"blur\": FocusEvent;\n \"canplay\": Event;\n \"canplaythrough\": Event;\n \"change\": Event;\n \"click\": MouseEvent;\n \"compassneedscalibration\": Event;\n \"contextmenu\": PointerEvent;\n \"dblclick\": MouseEvent;\n \"devicelight\": DeviceLightEvent;\n \"devicemotion\": DeviceMotionEvent;\n \"deviceorientation\": DeviceOrientationEvent;\n \"drag\": DragEvent;\n \"dragend\": DragEvent;\n \"dragenter\": DragEvent;\n \"dragleave\": DragEvent;\n \"dragover\": DragEvent;\n \"dragstart\": DragEvent;\n \"drop\": DragEvent;\n \"durationchange\": Event;\n \"emptied\": Event;\n \"ended\": MediaStreamErrorEvent;\n \"focus\": FocusEvent;\n \"hashchange\": HashChangeEvent;\n \"input\": Event;\n \"invalid\": Event;\n \"keydown\": KeyboardEvent;\n \"keypress\": KeyboardEvent;\n \"keyup\": KeyboardEvent;\n \"load\": Event;\n \"loadeddata\": Event;\n \"loadedmetadata\": Event;\n \"loadstart\": Event;\n \"message\": MessageEvent;\n \"mousedown\": MouseEvent;\n \"mouseenter\": MouseEvent;\n \"mouseleave\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n \"mousewheel\": WheelEvent;\n \"MSGestureChange\": MSGestureEvent;\n \"MSGestureDoubleTap\": MSGestureEvent;\n \"MSGestureEnd\": MSGestureEvent;\n \"MSGestureHold\": MSGestureEvent;\n \"MSGestureStart\": MSGestureEvent;\n \"MSGestureTap\": MSGestureEvent;\n \"MSInertiaStart\": MSGestureEvent;\n \"MSPointerCancel\": MSPointerEvent;\n \"MSPointerDown\": MSPointerEvent;\n \"MSPointerEnter\": MSPointerEvent;\n \"MSPointerLeave\": MSPointerEvent;\n \"MSPointerMove\": MSPointerEvent;\n \"MSPointerOut\": MSPointerEvent;\n \"MSPointerOver\": MSPointerEvent;\n \"MSPointerUp\": MSPointerEvent;\n \"offline\": Event;\n \"online\": Event;\n \"orientationchange\": Event;\n \"pagehide\": PageTransitionEvent;\n \"pageshow\": PageTransitionEvent;\n \"pause\": Event;\n \"play\": Event;\n \"playing\": Event;\n \"popstate\": PopStateEvent;\n \"progress\": ProgressEvent;\n \"ratechange\": Event;\n \"readystatechange\": ProgressEvent;\n \"reset\": Event;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"seeked\": Event;\n \"seeking\": Event;\n \"select\": UIEvent;\n \"stalled\": Event;\n \"storage\": StorageEvent;\n \"submit\": Event;\n \"suspend\": Event;\n \"timeupdate\": Event;\n \"unload\": Event;\n \"volumechange\": Event;\n \"waiting\": Event;\n}\n\ninterface Window extends EventTarget, WindowTimers, WindowSessionStorage, WindowLocalStorage, WindowConsole, GlobalEventHandlers, IDBEnvironment, WindowBase64, GlobalFetch {\n readonly applicationCache: ApplicationCache;\n readonly caches: CacheStorage;\n readonly clientInformation: Navigator;\n readonly closed: boolean;\n readonly crypto: Crypto;\n defaultStatus: string;\n readonly devicePixelRatio: number;\n readonly doNotTrack: string;\n readonly document: Document;\n event: Event | undefined;\n readonly external: External;\n readonly frameElement: Element;\n readonly frames: Window;\n readonly history: History;\n readonly innerHeight: number;\n readonly innerWidth: number;\n readonly isSecureContext: boolean;\n readonly length: number;\n readonly location: Location;\n readonly locationbar: BarProp;\n readonly menubar: BarProp;\n readonly msContentScript: ExtensionScriptApis;\n readonly msCredentials: MSCredentials;\n name: string;\n readonly navigator: Navigator;\n offscreenBuffering: string | boolean;\n onabort: (this: Window, ev: UIEvent) => any;\n onafterprint: (this: Window, ev: Event) => any;\n onbeforeprint: (this: Window, ev: Event) => any;\n onbeforeunload: (this: Window, ev: BeforeUnloadEvent) => any;\n onblur: (this: Window, ev: FocusEvent) => any;\n oncanplay: (this: Window, ev: Event) => any;\n oncanplaythrough: (this: Window, ev: Event) => any;\n onchange: (this: Window, ev: Event) => any;\n onclick: (this: Window, ev: MouseEvent) => any;\n oncompassneedscalibration: (this: Window, ev: Event) => any;\n oncontextmenu: (this: Window, ev: PointerEvent) => any;\n ondblclick: (this: Window, ev: MouseEvent) => any;\n ondevicelight: (this: Window, ev: DeviceLightEvent) => any;\n ondevicemotion: (this: Window, ev: DeviceMotionEvent) => any;\n ondeviceorientation: (this: Window, ev: DeviceOrientationEvent) => any;\n ondrag: (this: Window, ev: DragEvent) => any;\n ondragend: (this: Window, ev: DragEvent) => any;\n ondragenter: (this: Window, ev: DragEvent) => any;\n ondragleave: (this: Window, ev: DragEvent) => any;\n ondragover: (this: Window, ev: DragEvent) => any;\n ondragstart: (this: Window, ev: DragEvent) => any;\n ondrop: (this: Window, ev: DragEvent) => any;\n ondurationchange: (this: Window, ev: Event) => any;\n onemptied: (this: Window, ev: Event) => any;\n onended: (this: Window, ev: MediaStreamErrorEvent) => any;\n onerror: ErrorEventHandler;\n onfocus: (this: Window, ev: FocusEvent) => any;\n onhashchange: (this: Window, ev: HashChangeEvent) => any;\n oninput: (this: Window, ev: Event) => any;\n oninvalid: (this: Window, ev: Event) => any;\n onkeydown: (this: Window, ev: KeyboardEvent) => any;\n onkeypress: (this: Window, ev: KeyboardEvent) => any;\n onkeyup: (this: Window, ev: KeyboardEvent) => any;\n onload: (this: Window, ev: Event) => any;\n onloadeddata: (this: Window, ev: Event) => any;\n onloadedmetadata: (this: Window, ev: Event) => any;\n onloadstart: (this: Window, ev: Event) => any;\n onmessage: (this: Window, ev: MessageEvent) => any;\n onmousedown: (this: Window, ev: MouseEvent) => any;\n onmouseenter: (this: Window, ev: MouseEvent) => any;\n onmouseleave: (this: Window, ev: MouseEvent) => any;\n onmousemove: (this: Window, ev: MouseEvent) => any;\n onmouseout: (this: Window, ev: MouseEvent) => any;\n onmouseover: (this: Window, ev: MouseEvent) => any;\n onmouseup: (this: Window, ev: MouseEvent) => any;\n onmousewheel: (this: Window, ev: WheelEvent) => any;\n onmsgesturechange: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturedoubletap: (this: Window, ev: MSGestureEvent) => any;\n onmsgestureend: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturehold: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturestart: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturetap: (this: Window, ev: MSGestureEvent) => any;\n onmsinertiastart: (this: Window, ev: MSGestureEvent) => any;\n onmspointercancel: (this: Window, ev: MSPointerEvent) => any;\n onmspointerdown: (this: Window, ev: MSPointerEvent) => any;\n onmspointerenter: (this: Window, ev: MSPointerEvent) => any;\n onmspointerleave: (this: Window, ev: MSPointerEvent) => any;\n onmspointermove: (this: Window, ev: MSPointerEvent) => any;\n onmspointerout: (this: Window, ev: MSPointerEvent) => any;\n onmspointerover: (this: Window, ev: MSPointerEvent) => any;\n onmspointerup: (this: Window, ev: MSPointerEvent) => any;\n onoffline: (this: Window, ev: Event) => any;\n ononline: (this: Window, ev: Event) => any;\n onorientationchange: (this: Window, ev: Event) => any;\n onpagehide: (this: Window, ev: PageTransitionEvent) => any;\n onpageshow: (this: Window, ev: PageTransitionEvent) => any;\n onpause: (this: Window, ev: Event) => any;\n onplay: (this: Window, ev: Event) => any;\n onplaying: (this: Window, ev: Event) => any;\n onpopstate: (this: Window, ev: PopStateEvent) => any;\n onprogress: (this: Window, ev: ProgressEvent) => any;\n onratechange: (this: Window, ev: Event) => any;\n onreadystatechange: (this: Window, ev: ProgressEvent) => any;\n onreset: (this: Window, ev: Event) => any;\n onresize: (this: Window, ev: UIEvent) => any;\n onscroll: (this: Window, ev: UIEvent) => any;\n onseeked: (this: Window, ev: Event) => any;\n onseeking: (this: Window, ev: Event) => any;\n onselect: (this: Window, ev: UIEvent) => any;\n onstalled: (this: Window, ev: Event) => any;\n onstorage: (this: Window, ev: StorageEvent) => any;\n onsubmit: (this: Window, ev: Event) => any;\n onsuspend: (this: Window, ev: Event) => any;\n ontimeupdate: (this: Window, ev: Event) => any;\n ontouchcancel: (ev: TouchEvent) => any;\n ontouchend: (ev: TouchEvent) => any;\n ontouchmove: (ev: TouchEvent) => any;\n ontouchstart: (ev: TouchEvent) => any;\n onunload: (this: Window, ev: Event) => any;\n onvolumechange: (this: Window, ev: Event) => any;\n onwaiting: (this: Window, ev: Event) => any;\n opener: any;\n orientation: string | number;\n readonly outerHeight: number;\n readonly outerWidth: number;\n readonly pageXOffset: number;\n readonly pageYOffset: number;\n readonly parent: Window;\n readonly performance: Performance;\n readonly personalbar: BarProp;\n readonly screen: Screen;\n readonly screenLeft: number;\n readonly screenTop: number;\n readonly screenX: number;\n readonly screenY: number;\n readonly scrollX: number;\n readonly scrollY: number;\n readonly scrollbars: BarProp;\n readonly self: Window;\n readonly speechSynthesis: SpeechSynthesis;\n status: string;\n readonly statusbar: BarProp;\n readonly styleMedia: StyleMedia;\n readonly toolbar: BarProp;\n readonly top: Window;\n readonly window: Window;\n URL: typeof URL;\n URLSearchParams: typeof URLSearchParams;\n Blob: typeof Blob;\n customElements: CustomElementRegistry;\n alert(message?: any): void;\n blur(): void;\n cancelAnimationFrame(handle: number): void;\n captureEvents(): void;\n close(): void;\n confirm(message?: string): boolean;\n departFocus(navigationReason: NavigationReason, origin: FocusNavigationOrigin): void;\n focus(): void;\n getComputedStyle(elt: Element, pseudoElt?: string): CSSStyleDeclaration;\n getMatchedCSSRules(elt: Element, pseudoElt?: string): CSSRuleList;\n getSelection(): Selection;\n matchMedia(mediaQuery: string): MediaQueryList;\n moveBy(x?: number, y?: number): void;\n moveTo(x?: number, y?: number): void;\n msWriteProfilerMark(profilerMarkName: string): void;\n open(url?: string, target?: string, features?: string, replace?: boolean): Window;\n postMessage(message: any, targetOrigin: string, transfer?: any[]): void;\n print(): void;\n prompt(message?: string, _default?: string): string | null;\n releaseEvents(): void;\n requestAnimationFrame(callback: FrameRequestCallback): number;\n resizeBy(x?: number, y?: number): void;\n resizeTo(x?: number, y?: number): void;\n scroll(x?: number, y?: number): void;\n scrollBy(x?: number, y?: number): void;\n scrollTo(x?: number, y?: number): void;\n stop(): void;\n webkitCancelAnimationFrame(handle: number): void;\n webkitConvertPointFromNodeToPage(node: Node, pt: WebKitPoint): WebKitPoint;\n webkitConvertPointFromPageToNode(node: Node, pt: WebKitPoint): WebKitPoint;\n webkitRequestAnimationFrame(callback: FrameRequestCallback): number;\n createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, options?: ImageBitmapOptions): Promise;\n createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, sx: number, sy: number, sw: number, sh: number, options?: ImageBitmapOptions): Promise;\n scroll(options?: ScrollToOptions): void;\n scrollTo(options?: ScrollToOptions): void;\n scrollBy(options?: ScrollToOptions): void;\n addEventListener(type: K, listener: (this: Window, ev: WindowEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Window: {\n prototype: Window;\n new(): Window;\n}\n\ninterface WorkerEventMap extends AbstractWorkerEventMap {\n \"message\": MessageEvent;\n}\n\ninterface Worker extends EventTarget, AbstractWorker {\n onmessage: (this: Worker, ev: MessageEvent) => any;\n postMessage(message: any, transfer?: any[]): void;\n terminate(): void;\n addEventListener(type: K, listener: (this: Worker, ev: WorkerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Worker: {\n prototype: Worker;\n new(stringUrl: string): Worker;\n}\n\ninterface XMLDocument extends Document {\n addEventListener(type: K, listener: (this: XMLDocument, ev: DocumentEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var XMLDocument: {\n prototype: XMLDocument;\n new(): XMLDocument;\n}\n\ninterface XMLHttpRequestEventMap extends XMLHttpRequestEventTargetEventMap {\n \"readystatechange\": Event;\n}\n\ninterface XMLHttpRequest extends EventTarget, XMLHttpRequestEventTarget {\n onreadystatechange: (this: XMLHttpRequest, ev: Event) => any;\n readonly readyState: number;\n readonly response: any;\n readonly responseText: string;\n responseType: XMLHttpRequestResponseType;\n readonly responseURL: string;\n readonly responseXML: Document | null;\n readonly status: number;\n readonly statusText: string;\n timeout: number;\n readonly upload: XMLHttpRequestUpload;\n withCredentials: boolean;\n msCaching?: string;\n abort(): void;\n getAllResponseHeaders(): string;\n getResponseHeader(header: string): string | null;\n msCachingEnabled(): boolean;\n open(method: string, url: string, async?: boolean, user?: string, password?: string): void;\n overrideMimeType(mime: string): void;\n send(data?: Document): void;\n send(data?: string): void;\n send(data?: any): void;\n setRequestHeader(header: string, value: string): void;\n readonly DONE: number;\n readonly HEADERS_RECEIVED: number;\n readonly LOADING: number;\n readonly OPENED: number;\n readonly UNSENT: number;\n addEventListener(type: K, listener: (this: XMLHttpRequest, ev: XMLHttpRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var XMLHttpRequest: {\n prototype: XMLHttpRequest;\n new(): XMLHttpRequest;\n readonly DONE: number;\n readonly HEADERS_RECEIVED: number;\n readonly LOADING: number;\n readonly OPENED: number;\n readonly UNSENT: number;\n}\n\ninterface XMLHttpRequestUpload extends EventTarget, XMLHttpRequestEventTarget {\n addEventListener(type: K, listener: (this: XMLHttpRequestUpload, ev: XMLHttpRequestEventTargetEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var XMLHttpRequestUpload: {\n prototype: XMLHttpRequestUpload;\n new(): XMLHttpRequestUpload;\n}\n\ninterface XMLSerializer {\n serializeToString(target: Node): string;\n}\n\ndeclare var XMLSerializer: {\n prototype: XMLSerializer;\n new(): XMLSerializer;\n}\n\ninterface XPathEvaluator {\n createExpression(expression: string, resolver: XPathNSResolver): XPathExpression;\n createNSResolver(nodeResolver?: Node): XPathNSResolver;\n evaluate(expression: string, contextNode: Node, resolver: XPathNSResolver | null, type: number, result: XPathResult | null): XPathResult;\n}\n\ndeclare var XPathEvaluator: {\n prototype: XPathEvaluator;\n new(): XPathEvaluator;\n}\n\ninterface XPathExpression {\n evaluate(contextNode: Node, type: number, result: XPathResult | null): XPathResult;\n}\n\ndeclare var XPathExpression: {\n prototype: XPathExpression;\n new(): XPathExpression;\n}\n\ninterface XPathNSResolver {\n lookupNamespaceURI(prefix: string): string;\n}\n\ndeclare var XPathNSResolver: {\n prototype: XPathNSResolver;\n new(): XPathNSResolver;\n}\n\ninterface XPathResult {\n readonly booleanValue: boolean;\n readonly invalidIteratorState: boolean;\n readonly numberValue: number;\n readonly resultType: number;\n readonly singleNodeValue: Node;\n readonly snapshotLength: number;\n readonly stringValue: string;\n iterateNext(): Node;\n snapshotItem(index: number): Node;\n readonly ANY_TYPE: number;\n readonly ANY_UNORDERED_NODE_TYPE: number;\n readonly BOOLEAN_TYPE: number;\n readonly FIRST_ORDERED_NODE_TYPE: number;\n readonly NUMBER_TYPE: number;\n readonly ORDERED_NODE_ITERATOR_TYPE: number;\n readonly ORDERED_NODE_SNAPSHOT_TYPE: number;\n readonly STRING_TYPE: number;\n readonly UNORDERED_NODE_ITERATOR_TYPE: number;\n readonly UNORDERED_NODE_SNAPSHOT_TYPE: number;\n}\n\ndeclare var XPathResult: {\n prototype: XPathResult;\n new(): XPathResult;\n readonly ANY_TYPE: number;\n readonly ANY_UNORDERED_NODE_TYPE: number;\n readonly BOOLEAN_TYPE: number;\n readonly FIRST_ORDERED_NODE_TYPE: number;\n readonly NUMBER_TYPE: number;\n readonly ORDERED_NODE_ITERATOR_TYPE: number;\n readonly ORDERED_NODE_SNAPSHOT_TYPE: number;\n readonly STRING_TYPE: number;\n readonly UNORDERED_NODE_ITERATOR_TYPE: number;\n readonly UNORDERED_NODE_SNAPSHOT_TYPE: number;\n}\n\ninterface XSLTProcessor {\n clearParameters(): void;\n getParameter(namespaceURI: string, localName: string): any;\n importStylesheet(style: Node): void;\n removeParameter(namespaceURI: string, localName: string): void;\n reset(): void;\n setParameter(namespaceURI: string, localName: string, value: any): void;\n transformToDocument(source: Node): Document;\n transformToFragment(source: Node, document: Document): DocumentFragment;\n}\n\ndeclare var XSLTProcessor: {\n prototype: XSLTProcessor;\n new(): XSLTProcessor;\n}\n\ninterface webkitRTCPeerConnection extends RTCPeerConnection {\n addEventListener(type: K, listener: (this: webkitRTCPeerConnection, ev: RTCPeerConnectionEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var webkitRTCPeerConnection: {\n prototype: webkitRTCPeerConnection;\n new(configuration: RTCConfiguration): webkitRTCPeerConnection;\n}\n\ninterface AbstractWorkerEventMap {\n \"error\": ErrorEvent;\n}\n\ninterface AbstractWorker {\n onerror: (this: AbstractWorker, ev: ErrorEvent) => any;\n addEventListener(type: K, listener: (this: AbstractWorker, ev: AbstractWorkerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface Body {\n readonly bodyUsed: boolean;\n arrayBuffer(): Promise;\n blob(): Promise;\n json(): Promise;\n text(): Promise;\n formData(): Promise;\n}\n\ninterface CanvasPathMethods {\n arc(x: number, y: number, radius: number, startAngle: number, endAngle: number, anticlockwise?: boolean): void;\n arcTo(x1: number, y1: number, x2: number, y2: number, radius: number): void;\n bezierCurveTo(cp1x: number, cp1y: number, cp2x: number, cp2y: number, x: number, y: number): void;\n closePath(): void;\n ellipse(x: number, y: number, radiusX: number, radiusY: number, rotation: number, startAngle: number, endAngle: number, anticlockwise?: boolean): void;\n lineTo(x: number, y: number): void;\n moveTo(x: number, y: number): void;\n quadraticCurveTo(cpx: number, cpy: number, x: number, y: number): void;\n rect(x: number, y: number, w: number, h: number): void;\n}\n\ninterface ChildNode {\n remove(): void;\n}\n\ninterface DOML2DeprecatedColorProperty {\n color: string;\n}\n\ninterface DOML2DeprecatedSizeProperty {\n size: number;\n}\n\ninterface DocumentEvent {\n createEvent(eventInterface:\"AnimationEvent\"): AnimationEvent;\n createEvent(eventInterface:\"AudioProcessingEvent\"): AudioProcessingEvent;\n createEvent(eventInterface:\"BeforeUnloadEvent\"): BeforeUnloadEvent;\n createEvent(eventInterface:\"ClipboardEvent\"): ClipboardEvent;\n createEvent(eventInterface:\"CloseEvent\"): CloseEvent;\n createEvent(eventInterface:\"CompositionEvent\"): CompositionEvent;\n createEvent(eventInterface:\"CustomEvent\"): CustomEvent;\n createEvent(eventInterface:\"DeviceLightEvent\"): DeviceLightEvent;\n createEvent(eventInterface:\"DeviceMotionEvent\"): DeviceMotionEvent;\n createEvent(eventInterface:\"DeviceOrientationEvent\"): DeviceOrientationEvent;\n createEvent(eventInterface:\"DragEvent\"): DragEvent;\n createEvent(eventInterface:\"ErrorEvent\"): ErrorEvent;\n createEvent(eventInterface:\"Event\"): Event;\n createEvent(eventInterface:\"Events\"): Event;\n createEvent(eventInterface:\"FocusEvent\"): FocusEvent;\n createEvent(eventInterface:\"FocusNavigationEvent\"): FocusNavigationEvent;\n createEvent(eventInterface:\"GamepadEvent\"): GamepadEvent;\n createEvent(eventInterface:\"HashChangeEvent\"): HashChangeEvent;\n createEvent(eventInterface:\"IDBVersionChangeEvent\"): IDBVersionChangeEvent;\n createEvent(eventInterface:\"KeyboardEvent\"): KeyboardEvent;\n createEvent(eventInterface:\"ListeningStateChangedEvent\"): ListeningStateChangedEvent;\n createEvent(eventInterface:\"LongRunningScriptDetectedEvent\"): LongRunningScriptDetectedEvent;\n createEvent(eventInterface:\"MSGestureEvent\"): MSGestureEvent;\n createEvent(eventInterface:\"MSManipulationEvent\"): MSManipulationEvent;\n createEvent(eventInterface:\"MSMediaKeyMessageEvent\"): MSMediaKeyMessageEvent;\n createEvent(eventInterface:\"MSMediaKeyNeededEvent\"): MSMediaKeyNeededEvent;\n createEvent(eventInterface:\"MSPointerEvent\"): MSPointerEvent;\n createEvent(eventInterface:\"MSSiteModeEvent\"): MSSiteModeEvent;\n createEvent(eventInterface:\"MediaEncryptedEvent\"): MediaEncryptedEvent;\n createEvent(eventInterface:\"MediaKeyMessageEvent\"): MediaKeyMessageEvent;\n createEvent(eventInterface:\"MediaStreamErrorEvent\"): MediaStreamErrorEvent;\n createEvent(eventInterface:\"MediaStreamEvent\"): MediaStreamEvent;\n createEvent(eventInterface:\"MediaStreamTrackEvent\"): MediaStreamTrackEvent;\n createEvent(eventInterface:\"MessageEvent\"): MessageEvent;\n createEvent(eventInterface:\"MouseEvent\"): MouseEvent;\n createEvent(eventInterface:\"MouseEvents\"): MouseEvent;\n createEvent(eventInterface:\"MutationEvent\"): MutationEvent;\n createEvent(eventInterface:\"MutationEvents\"): MutationEvent;\n createEvent(eventInterface:\"NavigationCompletedEvent\"): NavigationCompletedEvent;\n createEvent(eventInterface:\"NavigationEvent\"): NavigationEvent;\n createEvent(eventInterface:\"NavigationEventWithReferrer\"): NavigationEventWithReferrer;\n createEvent(eventInterface:\"OfflineAudioCompletionEvent\"): OfflineAudioCompletionEvent;\n createEvent(eventInterface:\"OverflowEvent\"): OverflowEvent;\n createEvent(eventInterface:\"PageTransitionEvent\"): PageTransitionEvent;\n createEvent(eventInterface:\"PaymentRequestUpdateEvent\"): PaymentRequestUpdateEvent;\n createEvent(eventInterface:\"PermissionRequestedEvent\"): PermissionRequestedEvent;\n createEvent(eventInterface:\"PointerEvent\"): PointerEvent;\n createEvent(eventInterface:\"PopStateEvent\"): PopStateEvent;\n createEvent(eventInterface:\"ProgressEvent\"): ProgressEvent;\n createEvent(eventInterface:\"RTCDTMFToneChangeEvent\"): RTCDTMFToneChangeEvent;\n createEvent(eventInterface:\"RTCDtlsTransportStateChangedEvent\"): RTCDtlsTransportStateChangedEvent;\n createEvent(eventInterface:\"RTCIceCandidatePairChangedEvent\"): RTCIceCandidatePairChangedEvent;\n createEvent(eventInterface:\"RTCIceGathererEvent\"): RTCIceGathererEvent;\n createEvent(eventInterface:\"RTCIceTransportStateChangedEvent\"): RTCIceTransportStateChangedEvent;\n createEvent(eventInterface:\"RTCPeerConnectionIceEvent\"): RTCPeerConnectionIceEvent;\n createEvent(eventInterface:\"RTCSsrcConflictEvent\"): RTCSsrcConflictEvent;\n createEvent(eventInterface:\"SVGZoomEvent\"): SVGZoomEvent;\n createEvent(eventInterface:\"SVGZoomEvents\"): SVGZoomEvent;\n createEvent(eventInterface:\"ScriptNotifyEvent\"): ScriptNotifyEvent;\n createEvent(eventInterface:\"ServiceWorkerMessageEvent\"): ServiceWorkerMessageEvent;\n createEvent(eventInterface:\"SpeechSynthesisEvent\"): SpeechSynthesisEvent;\n createEvent(eventInterface:\"StorageEvent\"): StorageEvent;\n createEvent(eventInterface:\"TextEvent\"): TextEvent;\n createEvent(eventInterface:\"TouchEvent\"): TouchEvent;\n createEvent(eventInterface:\"TrackEvent\"): TrackEvent;\n createEvent(eventInterface:\"TransitionEvent\"): TransitionEvent;\n createEvent(eventInterface:\"UIEvent\"): UIEvent;\n createEvent(eventInterface:\"UIEvents\"): UIEvent;\n createEvent(eventInterface:\"UnviewableContentIdentifiedEvent\"): UnviewableContentIdentifiedEvent;\n createEvent(eventInterface:\"WebGLContextEvent\"): WebGLContextEvent;\n createEvent(eventInterface:\"WheelEvent\"): WheelEvent;\n createEvent(eventInterface: string): Event;\n}\n\ninterface ElementTraversal {\n readonly childElementCount: number;\n readonly firstElementChild: Element | null;\n readonly lastElementChild: Element | null;\n readonly nextElementSibling: Element | null;\n readonly previousElementSibling: Element | null;\n}\n\ninterface GetSVGDocument {\n getSVGDocument(): Document;\n}\n\ninterface GlobalEventHandlersEventMap {\n \"pointercancel\": PointerEvent;\n \"pointerdown\": PointerEvent;\n \"pointerenter\": PointerEvent;\n \"pointerleave\": PointerEvent;\n \"pointermove\": PointerEvent;\n \"pointerout\": PointerEvent;\n \"pointerover\": PointerEvent;\n \"pointerup\": PointerEvent;\n \"wheel\": WheelEvent;\n}\n\ninterface GlobalEventHandlers {\n onpointercancel: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerdown: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerenter: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerleave: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointermove: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerout: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerover: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerup: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onwheel: (this: GlobalEventHandlers, ev: WheelEvent) => any;\n addEventListener(type: K, listener: (this: GlobalEventHandlers, ev: GlobalEventHandlersEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface GlobalFetch {\n fetch(input: RequestInfo, init?: RequestInit): Promise;\n}\n\ninterface HTMLTableAlignment {\n /**\n * Sets or retrieves a value that you can use to implement your own ch functionality for the object.\n */\n ch: string;\n /**\n * Sets or retrieves a value that you can use to implement your own chOff functionality for the object.\n */\n chOff: string;\n /**\n * Sets or retrieves how text and other content are vertically aligned within the object that contains them.\n */\n vAlign: string;\n}\n\ninterface IDBEnvironment {\n readonly indexedDB: IDBFactory;\n}\n\ninterface LinkStyle {\n readonly sheet: StyleSheet;\n}\n\ninterface MSBaseReaderEventMap {\n \"abort\": Event;\n \"error\": ErrorEvent;\n \"load\": Event;\n \"loadend\": ProgressEvent;\n \"loadstart\": Event;\n \"progress\": ProgressEvent;\n}\n\ninterface MSBaseReader {\n onabort: (this: MSBaseReader, ev: Event) => any;\n onerror: (this: MSBaseReader, ev: ErrorEvent) => any;\n onload: (this: MSBaseReader, ev: Event) => any;\n onloadend: (this: MSBaseReader, ev: ProgressEvent) => any;\n onloadstart: (this: MSBaseReader, ev: Event) => any;\n onprogress: (this: MSBaseReader, ev: ProgressEvent) => any;\n readonly readyState: number;\n readonly result: any;\n abort(): void;\n readonly DONE: number;\n readonly EMPTY: number;\n readonly LOADING: number;\n addEventListener(type: K, listener: (this: MSBaseReader, ev: MSBaseReaderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface MSFileSaver {\n msSaveBlob(blob: any, defaultName?: string): boolean;\n msSaveOrOpenBlob(blob: any, defaultName?: string): boolean;\n}\n\ninterface MSNavigatorDoNotTrack {\n confirmSiteSpecificTrackingException(args: ConfirmSiteSpecificExceptionsInformation): boolean;\n confirmWebWideTrackingException(args: ExceptionInformation): boolean;\n removeSiteSpecificTrackingException(args: ExceptionInformation): void;\n removeWebWideTrackingException(args: ExceptionInformation): void;\n storeSiteSpecificTrackingException(args: StoreSiteSpecificExceptionsInformation): void;\n storeWebWideTrackingException(args: StoreExceptionsInformation): void;\n}\n\ninterface NavigatorBeacon {\n sendBeacon(url: USVString, data?: BodyInit): boolean;\n}\n\ninterface NavigatorConcurrentHardware {\n readonly hardwareConcurrency: number;\n}\n\ninterface NavigatorContentUtils {\n}\n\ninterface NavigatorGeolocation {\n readonly geolocation: Geolocation;\n}\n\ninterface NavigatorID {\n readonly appCodeName: string;\n readonly appName: string;\n readonly appVersion: string;\n readonly platform: string;\n readonly product: string;\n readonly productSub: string;\n readonly userAgent: string;\n readonly vendor: string;\n readonly vendorSub: string;\n}\n\ninterface NavigatorOnLine {\n readonly onLine: boolean;\n}\n\ninterface NavigatorStorageUtils {\n}\n\ninterface NavigatorUserMedia {\n readonly mediaDevices: MediaDevices;\n getUserMedia(constraints: MediaStreamConstraints, successCallback: NavigatorUserMediaSuccessCallback, errorCallback: NavigatorUserMediaErrorCallback): void;\n}\n\ninterface NodeSelector {\n querySelector(selectors: K): ElementTagNameMap[K] | null;\n querySelector(selectors: string): Element | null;\n querySelectorAll(selectors: K): ElementListTagNameMap[K];\n querySelectorAll(selectors: string): NodeListOf;\n}\n\ninterface RandomSource {\n getRandomValues(array: ArrayBufferView): ArrayBufferView;\n}\n\ninterface SVGAnimatedPoints {\n readonly animatedPoints: SVGPointList;\n readonly points: SVGPointList;\n}\n\ninterface SVGFilterPrimitiveStandardAttributes {\n readonly height: SVGAnimatedLength;\n readonly result: SVGAnimatedString;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n}\n\ninterface SVGFitToViewBox {\n readonly preserveAspectRatio: SVGAnimatedPreserveAspectRatio;\n readonly viewBox: SVGAnimatedRect;\n}\n\ninterface SVGTests {\n readonly requiredExtensions: SVGStringList;\n readonly requiredFeatures: SVGStringList;\n readonly systemLanguage: SVGStringList;\n hasExtension(extension: string): boolean;\n}\n\ninterface SVGURIReference {\n readonly href: SVGAnimatedString;\n}\n\ninterface WindowBase64 {\n atob(encodedString: string): string;\n btoa(rawString: string): string;\n}\n\ninterface WindowConsole {\n readonly console: Console;\n}\n\ninterface WindowLocalStorage {\n readonly localStorage: Storage;\n}\n\ninterface WindowSessionStorage {\n readonly sessionStorage: Storage;\n}\n\ninterface WindowTimers extends Object, WindowTimersExtension {\n clearInterval(handle: number): void;\n clearTimeout(handle: number): void;\n setInterval(handler: (...args: any[]) => void, timeout: number): number;\n setInterval(handler: any, timeout?: any, ...args: any[]): number;\n setTimeout(handler: (...args: any[]) => void, timeout: number): number;\n setTimeout(handler: any, timeout?: any, ...args: any[]): number;\n}\n\ninterface WindowTimersExtension {\n clearImmediate(handle: number): void;\n setImmediate(handler: (...args: any[]) => void): number;\n setImmediate(handler: any, ...args: any[]): number;\n}\n\ninterface XMLHttpRequestEventTargetEventMap {\n \"abort\": Event;\n \"error\": ErrorEvent;\n \"load\": Event;\n \"loadend\": ProgressEvent;\n \"loadstart\": Event;\n \"progress\": ProgressEvent;\n \"timeout\": ProgressEvent;\n}\n\ninterface XMLHttpRequestEventTarget {\n onabort: (this: XMLHttpRequestEventTarget, ev: Event) => any;\n onerror: (this: XMLHttpRequestEventTarget, ev: ErrorEvent) => any;\n onload: (this: XMLHttpRequestEventTarget, ev: Event) => any;\n onloadend: (this: XMLHttpRequestEventTarget, ev: ProgressEvent) => any;\n onloadstart: (this: XMLHttpRequestEventTarget, ev: Event) => any;\n onprogress: (this: XMLHttpRequestEventTarget, ev: ProgressEvent) => any;\n ontimeout: (this: XMLHttpRequestEventTarget, ev: ProgressEvent) => any;\n addEventListener(type: K, listener: (this: XMLHttpRequestEventTarget, ev: XMLHttpRequestEventTargetEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface ErrorEventInit {\n message?: string;\n filename?: string;\n lineno?: number;\n conlno?: number;\n error?: any;\n}\n\ninterface StorageEventInit extends EventInit {\n key?: string;\n oldValue?: string;\n newValue?: string;\n url: string;\n storageArea?: Storage;\n}\n\ninterface Canvas2DContextAttributes {\n alpha?: boolean;\n willReadFrequently?: boolean;\n storage?: boolean;\n [attribute: string]: boolean | string | undefined;\n}\n\ninterface ImageBitmapOptions {\n imageOrientation?: \"none\" | \"flipY\";\n premultiplyAlpha?: \"none\" | \"premultiply\" | \"default\";\n colorSpaceConversion?: \"none\" | \"default\";\n resizeWidth?: number;\n resizeHeight?: number;\n resizeQuality?: \"pixelated\" | \"low\" | \"medium\" | \"high\";\n}\n\ninterface ImageBitmap {\n readonly width: number;\n readonly height: number;\n close(): void;\n}\n\ninterface URLSearchParams {\n /**\n * Appends a specified key/value pair as a new search parameter.\n */\n append(name: string, value: string): void;\n /**\n * Deletes the given search parameter, and its associated value, from the list of all search parameters.\n */\n delete(name: string): void;\n /**\n * Returns the first value associated to the given search parameter.\n */\n get(name: string): string | null;\n /**\n * Returns all the values association with a given search parameter.\n */\n getAll(name: string): string[];\n /**\n * Returns a Boolean indicating if such a search parameter exists.\n */\n has(name: string): boolean;\n /**\n * Sets the value associated to a given search parameter to the given value. If there were several values, delete the others.\n */\n set(name: string, value: string): void;\n}\n\ndeclare var URLSearchParams: {\n prototype: URLSearchParams;\n /**\n * Constructor returning a URLSearchParams object.\n */\n new (init?: string | URLSearchParams): URLSearchParams;\n}\n\ninterface NodeListOf extends NodeList {\n length: number;\n item(index: number): TNode;\n [index: number]: TNode;\n}\n\ninterface HTMLCollectionOf extends HTMLCollection {\n item(index: number): T;\n namedItem(name: string): T;\n [index: number]: T;\n}\n\ninterface BlobPropertyBag {\n type?: string;\n endings?: string;\n}\n\ninterface FilePropertyBag {\n type?: string;\n lastModified?: number;\n}\n\ninterface EventListenerObject {\n handleEvent(evt: Event): void;\n}\n\ninterface ProgressEventInit extends EventInit {\n lengthComputable?: boolean;\n loaded?: number;\n total?: number;\n}\n\ninterface ScrollOptions {\n behavior?: ScrollBehavior;\n}\n\ninterface ScrollToOptions extends ScrollOptions {\n left?: number;\n top?: number;\n}\n\ninterface ScrollIntoViewOptions extends ScrollOptions {\n block?: ScrollLogicalPosition;\n inline?: ScrollLogicalPosition;\n}\n\ninterface ClipboardEventInit extends EventInit {\n data?: string;\n dataType?: string;\n}\n\ninterface IDBArrayKey extends Array {\n}\n\ninterface RsaKeyGenParams extends Algorithm {\n modulusLength: number;\n publicExponent: Uint8Array;\n}\n\ninterface RsaHashedKeyGenParams extends RsaKeyGenParams {\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaKeyAlgorithm extends KeyAlgorithm {\n modulusLength: number;\n publicExponent: Uint8Array;\n}\n\ninterface RsaHashedKeyAlgorithm extends RsaKeyAlgorithm {\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaHashedImportParams {\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaPssParams {\n saltLength: number;\n}\n\ninterface RsaOaepParams extends Algorithm {\n label?: BufferSource;\n}\n\ninterface EcdsaParams extends Algorithm {\n hash: AlgorithmIdentifier;\n}\n\ninterface EcKeyGenParams extends Algorithm {\n namedCurve: string;\n}\n\ninterface EcKeyAlgorithm extends KeyAlgorithm {\n typedCurve: string;\n}\n\ninterface EcKeyImportParams {\n namedCurve: string;\n}\n\ninterface EcdhKeyDeriveParams extends Algorithm {\n public: CryptoKey;\n}\n\ninterface AesCtrParams extends Algorithm {\n counter: BufferSource;\n length: number;\n}\n\ninterface AesKeyAlgorithm extends KeyAlgorithm {\n length: number;\n}\n\ninterface AesKeyGenParams extends Algorithm {\n length: number;\n}\n\ninterface AesDerivedKeyParams extends Algorithm {\n length: number;\n}\n\ninterface AesCbcParams extends Algorithm {\n iv: BufferSource;\n}\n\ninterface AesCmacParams extends Algorithm {\n length: number;\n}\n\ninterface AesGcmParams extends Algorithm {\n iv: BufferSource;\n additionalData?: BufferSource;\n tagLength?: number;\n}\n\ninterface AesCfbParams extends Algorithm {\n iv: BufferSource;\n}\n\ninterface HmacImportParams extends Algorithm {\n hash?: AlgorithmIdentifier;\n length?: number;\n}\n\ninterface HmacKeyAlgorithm extends KeyAlgorithm {\n hash: AlgorithmIdentifier;\n length: number;\n}\n\ninterface HmacKeyGenParams extends Algorithm {\n hash: AlgorithmIdentifier;\n length?: number;\n}\n\ninterface DhKeyGenParams extends Algorithm {\n prime: Uint8Array;\n generator: Uint8Array;\n}\n\ninterface DhKeyAlgorithm extends KeyAlgorithm {\n prime: Uint8Array;\n generator: Uint8Array;\n}\n\ninterface DhKeyDeriveParams extends Algorithm {\n public: CryptoKey;\n}\n\ninterface DhImportKeyParams extends Algorithm {\n prime: Uint8Array;\n generator: Uint8Array;\n}\n\ninterface ConcatParams extends Algorithm {\n hash?: AlgorithmIdentifier;\n algorithmId: Uint8Array;\n partyUInfo: Uint8Array;\n partyVInfo: Uint8Array;\n publicInfo?: Uint8Array;\n privateInfo?: Uint8Array;\n}\n\ninterface HkdfCtrParams extends Algorithm {\n hash: AlgorithmIdentifier;\n label: BufferSource;\n context: BufferSource;\n}\n\ninterface Pbkdf2Params extends Algorithm {\n salt: BufferSource;\n iterations: number;\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaOtherPrimesInfo {\n r: string;\n d: string;\n t: string;\n}\n\ninterface JsonWebKey {\n kty: string;\n use?: string;\n key_ops?: string[];\n alg?: string;\n kid?: string;\n x5u?: string;\n x5c?: string;\n x5t?: string;\n ext?: boolean;\n crv?: string;\n x?: string;\n y?: string;\n d?: string;\n n?: string;\n e?: string;\n p?: string;\n q?: string;\n dp?: string;\n dq?: string;\n qi?: string;\n oth?: RsaOtherPrimesInfo[];\n k?: string;\n}\n\ninterface ParentNode {\n readonly children: HTMLCollection;\n readonly firstElementChild: Element | null;\n readonly lastElementChild: Element | null;\n readonly childElementCount: number;\n}\n\ninterface DocumentOrShadowRoot {\n readonly activeElement: Element | null;\n readonly stylesheets: StyleSheetList;\n getSelection(): Selection | null;\n elementFromPoint(x: number, y: number): Element | null;\n elementsFromPoint(x: number, y: number): Element[];\n}\n\ninterface ShadowRoot extends DocumentOrShadowRoot, DocumentFragment {\n readonly host: Element;\n innerHTML: string;\n}\n\ninterface ShadowRootInit {\n mode: 'open'|'closed';\n delegatesFocus?: boolean;\n}\n\ninterface HTMLSlotElement extends HTMLElement {\n name: string;\n assignedNodes(options?: AssignedNodesOptions): Node[];\n}\n\ninterface AssignedNodesOptions {\n flatten?: boolean;\n}\n\ninterface ElementDefinitionOptions {\n extends: string;\n}\n\ninterface CustomElementRegistry {\n define(name: string, constructor: Function, options?: ElementDefinitionOptions): void;\n get(name: string): any;\n whenDefined(name: string): PromiseLike;\n}\n\ninterface PromiseRejectionEvent extends Event {\n readonly promise: PromiseLike;\n readonly reason: any;\n}\n\ninterface PromiseRejectionEventInit extends EventInit {\n promise: PromiseLike;\n reason?: any;\n}\n\ninterface EventListenerOptions {\n capture?: boolean;\n}\n\ninterface AddEventListenerOptions extends EventListenerOptions {\n passive?: boolean;\n once?: boolean;\n}\n\ninterface TouchEventInit extends EventModifierInit {\n touches?: Touch[];\n targetTouches?: Touch[];\n changedTouches?: Touch[];\n}\n\ndeclare type EventListenerOrEventListenerObject = EventListener | EventListenerObject;\n\ninterface ErrorEventHandler {\n (message: string, filename?: string, lineno?: number, colno?: number, error?:Error): void;\n}\ninterface PositionCallback {\n (position: Position): void;\n}\ninterface PositionErrorCallback {\n (error: PositionError): void;\n}\ninterface MediaQueryListListener {\n (mql: MediaQueryList): void;\n}\ninterface MSLaunchUriCallback {\n (): void;\n}\ninterface FrameRequestCallback {\n (time: number): void;\n}\ninterface MSUnsafeFunctionCallback {\n (): any;\n}\ninterface MSExecAtPriorityFunctionCallback {\n (...args: any[]): any;\n}\ninterface MutationCallback {\n (mutations: MutationRecord[], observer: MutationObserver): void;\n}\ninterface DecodeSuccessCallback {\n (decodedData: AudioBuffer): void;\n}\ninterface DecodeErrorCallback {\n (error: DOMException): void;\n}\ninterface VoidFunction {\n (): void;\n}\ninterface RTCSessionDescriptionCallback {\n (sdp: RTCSessionDescription): void;\n}\ninterface RTCPeerConnectionErrorCallback {\n (error: DOMError): void;\n}\ninterface RTCStatsCallback {\n (report: RTCStatsReport): void;\n}\ninterface FunctionStringCallback {\n (data: string): void;\n}\ninterface NavigatorUserMediaSuccessCallback {\n (stream: MediaStream): void;\n}\ninterface NavigatorUserMediaErrorCallback {\n (error: MediaStreamError): void;\n}\ninterface ForEachCallback {\n (keyId: any, status: MediaKeyStatus): void;\n}\ninterface NotificationPermissionCallback {\n (permission: NotificationPermission): void;\n}\ninterface IntersectionObserverCallback {\n (entries: IntersectionObserverEntry[], observer: IntersectionObserver): void;\n}\ninterface HTMLElementTagNameMap {\n \"a\": HTMLAnchorElement;\n \"applet\": HTMLAppletElement;\n \"area\": HTMLAreaElement;\n \"audio\": HTMLAudioElement;\n \"base\": HTMLBaseElement;\n \"basefont\": HTMLBaseFontElement;\n \"blockquote\": HTMLQuoteElement;\n \"body\": HTMLBodyElement;\n \"br\": HTMLBRElement;\n \"button\": HTMLButtonElement;\n \"canvas\": HTMLCanvasElement;\n \"caption\": HTMLTableCaptionElement;\n \"col\": HTMLTableColElement;\n \"colgroup\": HTMLTableColElement;\n \"data\": HTMLDataElement;\n \"datalist\": HTMLDataListElement;\n \"del\": HTMLModElement;\n \"dir\": HTMLDirectoryElement;\n \"div\": HTMLDivElement;\n \"dl\": HTMLDListElement;\n \"embed\": HTMLEmbedElement;\n \"fieldset\": HTMLFieldSetElement;\n \"font\": HTMLFontElement;\n \"form\": HTMLFormElement;\n \"frame\": HTMLFrameElement;\n \"frameset\": HTMLFrameSetElement;\n \"h1\": HTMLHeadingElement;\n \"h2\": HTMLHeadingElement;\n \"h3\": HTMLHeadingElement;\n \"h4\": HTMLHeadingElement;\n \"h5\": HTMLHeadingElement;\n \"h6\": HTMLHeadingElement;\n \"head\": HTMLHeadElement;\n \"hr\": HTMLHRElement;\n \"html\": HTMLHtmlElement;\n \"iframe\": HTMLIFrameElement;\n \"img\": HTMLImageElement;\n \"input\": HTMLInputElement;\n \"ins\": HTMLModElement;\n \"isindex\": HTMLUnknownElement;\n \"label\": HTMLLabelElement;\n \"legend\": HTMLLegendElement;\n \"li\": HTMLLIElement;\n \"link\": HTMLLinkElement;\n \"listing\": HTMLPreElement;\n \"map\": HTMLMapElement;\n \"marquee\": HTMLMarqueeElement;\n \"menu\": HTMLMenuElement;\n \"meta\": HTMLMetaElement;\n \"meter\": HTMLMeterElement;\n \"nextid\": HTMLUnknownElement;\n \"object\": HTMLObjectElement;\n \"ol\": HTMLOListElement;\n \"optgroup\": HTMLOptGroupElement;\n \"option\": HTMLOptionElement;\n \"output\": HTMLOutputElement;\n \"p\": HTMLParagraphElement;\n \"param\": HTMLParamElement;\n \"picture\": HTMLPictureElement;\n \"pre\": HTMLPreElement;\n \"progress\": HTMLProgressElement;\n \"q\": HTMLQuoteElement;\n \"script\": HTMLScriptElement;\n \"select\": HTMLSelectElement;\n \"source\": HTMLSourceElement;\n \"span\": HTMLSpanElement;\n \"style\": HTMLStyleElement;\n \"table\": HTMLTableElement;\n \"tbody\": HTMLTableSectionElement;\n \"td\": HTMLTableDataCellElement;\n \"template\": HTMLTemplateElement;\n \"textarea\": HTMLTextAreaElement;\n \"tfoot\": HTMLTableSectionElement;\n \"th\": HTMLTableHeaderCellElement;\n \"thead\": HTMLTableSectionElement;\n \"time\": HTMLTimeElement;\n \"title\": HTMLTitleElement;\n \"tr\": HTMLTableRowElement;\n \"track\": HTMLTrackElement;\n \"ul\": HTMLUListElement;\n \"video\": HTMLVideoElement;\n \"x-ms-webview\": MSHTMLWebViewElement;\n \"xmp\": HTMLPreElement;\n}\n\ninterface ElementTagNameMap {\n \"a\": HTMLAnchorElement;\n \"abbr\": HTMLElement;\n \"acronym\": HTMLElement;\n \"address\": HTMLElement;\n \"applet\": HTMLAppletElement;\n \"area\": HTMLAreaElement;\n \"article\": HTMLElement;\n \"aside\": HTMLElement;\n \"audio\": HTMLAudioElement;\n \"b\": HTMLElement;\n \"base\": HTMLBaseElement;\n \"basefont\": HTMLBaseFontElement;\n \"bdo\": HTMLElement;\n \"big\": HTMLElement;\n \"blockquote\": HTMLQuoteElement;\n \"body\": HTMLBodyElement;\n \"br\": HTMLBRElement;\n \"button\": HTMLButtonElement;\n \"canvas\": HTMLCanvasElement;\n \"caption\": HTMLTableCaptionElement;\n \"center\": HTMLElement;\n \"circle\": SVGCircleElement;\n \"cite\": HTMLElement;\n \"clippath\": SVGClipPathElement;\n \"code\": HTMLElement;\n \"col\": HTMLTableColElement;\n \"colgroup\": HTMLTableColElement;\n \"data\": HTMLDataElement;\n \"datalist\": HTMLDataListElement;\n \"dd\": HTMLElement;\n \"defs\": SVGDefsElement;\n \"del\": HTMLModElement;\n \"desc\": SVGDescElement;\n \"dfn\": HTMLElement;\n \"dir\": HTMLDirectoryElement;\n \"div\": HTMLDivElement;\n \"dl\": HTMLDListElement;\n \"dt\": HTMLElement;\n \"ellipse\": SVGEllipseElement;\n \"em\": HTMLElement;\n \"embed\": HTMLEmbedElement;\n \"feblend\": SVGFEBlendElement;\n \"fecolormatrix\": SVGFEColorMatrixElement;\n \"fecomponenttransfer\": SVGFEComponentTransferElement;\n \"fecomposite\": SVGFECompositeElement;\n \"feconvolvematrix\": SVGFEConvolveMatrixElement;\n \"fediffuselighting\": SVGFEDiffuseLightingElement;\n \"fedisplacementmap\": SVGFEDisplacementMapElement;\n \"fedistantlight\": SVGFEDistantLightElement;\n \"feflood\": SVGFEFloodElement;\n \"fefunca\": SVGFEFuncAElement;\n \"fefuncb\": SVGFEFuncBElement;\n \"fefuncg\": SVGFEFuncGElement;\n \"fefuncr\": SVGFEFuncRElement;\n \"fegaussianblur\": SVGFEGaussianBlurElement;\n \"feimage\": SVGFEImageElement;\n \"femerge\": SVGFEMergeElement;\n \"femergenode\": SVGFEMergeNodeElement;\n \"femorphology\": SVGFEMorphologyElement;\n \"feoffset\": SVGFEOffsetElement;\n \"fepointlight\": SVGFEPointLightElement;\n \"fespecularlighting\": SVGFESpecularLightingElement;\n \"fespotlight\": SVGFESpotLightElement;\n \"fetile\": SVGFETileElement;\n \"feturbulence\": SVGFETurbulenceElement;\n \"fieldset\": HTMLFieldSetElement;\n \"figcaption\": HTMLElement;\n \"figure\": HTMLElement;\n \"filter\": SVGFilterElement;\n \"font\": HTMLFontElement;\n \"footer\": HTMLElement;\n \"foreignobject\": SVGForeignObjectElement;\n \"form\": HTMLFormElement;\n \"frame\": HTMLFrameElement;\n \"frameset\": HTMLFrameSetElement;\n \"g\": SVGGElement;\n \"h1\": HTMLHeadingElement;\n \"h2\": HTMLHeadingElement;\n \"h3\": HTMLHeadingElement;\n \"h4\": HTMLHeadingElement;\n \"h5\": HTMLHeadingElement;\n \"h6\": HTMLHeadingElement;\n \"head\": HTMLHeadElement;\n \"header\": HTMLElement;\n \"hgroup\": HTMLElement;\n \"hr\": HTMLHRElement;\n \"html\": HTMLHtmlElement;\n \"i\": HTMLElement;\n \"iframe\": HTMLIFrameElement;\n \"image\": SVGImageElement;\n \"img\": HTMLImageElement;\n \"input\": HTMLInputElement;\n \"ins\": HTMLModElement;\n \"isindex\": HTMLUnknownElement;\n \"kbd\": HTMLElement;\n \"keygen\": HTMLElement;\n \"label\": HTMLLabelElement;\n \"legend\": HTMLLegendElement;\n \"li\": HTMLLIElement;\n \"line\": SVGLineElement;\n \"lineargradient\": SVGLinearGradientElement;\n \"link\": HTMLLinkElement;\n \"listing\": HTMLPreElement;\n \"map\": HTMLMapElement;\n \"mark\": HTMLElement;\n \"marker\": SVGMarkerElement;\n \"marquee\": HTMLMarqueeElement;\n \"mask\": SVGMaskElement;\n \"menu\": HTMLMenuElement;\n \"meta\": HTMLMetaElement;\n \"metadata\": SVGMetadataElement;\n \"meter\": HTMLMeterElement;\n \"nav\": HTMLElement;\n \"nextid\": HTMLUnknownElement;\n \"nobr\": HTMLElement;\n \"noframes\": HTMLElement;\n \"noscript\": HTMLElement;\n \"object\": HTMLObjectElement;\n \"ol\": HTMLOListElement;\n \"optgroup\": HTMLOptGroupElement;\n \"option\": HTMLOptionElement;\n \"output\": HTMLOutputElement;\n \"p\": HTMLParagraphElement;\n \"param\": HTMLParamElement;\n \"path\": SVGPathElement;\n \"pattern\": SVGPatternElement;\n \"picture\": HTMLPictureElement;\n \"plaintext\": HTMLElement;\n \"polygon\": SVGPolygonElement;\n \"polyline\": SVGPolylineElement;\n \"pre\": HTMLPreElement;\n \"progress\": HTMLProgressElement;\n \"q\": HTMLQuoteElement;\n \"radialgradient\": SVGRadialGradientElement;\n \"rect\": SVGRectElement;\n \"rt\": HTMLElement;\n \"ruby\": HTMLElement;\n \"s\": HTMLElement;\n \"samp\": HTMLElement;\n \"script\": HTMLScriptElement;\n \"section\": HTMLElement;\n \"select\": HTMLSelectElement;\n \"small\": HTMLElement;\n \"source\": HTMLSourceElement;\n \"span\": HTMLSpanElement;\n \"stop\": SVGStopElement;\n \"strike\": HTMLElement;\n \"strong\": HTMLElement;\n \"style\": HTMLStyleElement;\n \"sub\": HTMLElement;\n \"sup\": HTMLElement;\n \"svg\": SVGSVGElement;\n \"switch\": SVGSwitchElement;\n \"symbol\": SVGSymbolElement;\n \"table\": HTMLTableElement;\n \"tbody\": HTMLTableSectionElement;\n \"td\": HTMLTableDataCellElement;\n \"template\": HTMLTemplateElement;\n \"text\": SVGTextElement;\n \"textpath\": SVGTextPathElement;\n \"textarea\": HTMLTextAreaElement;\n \"tfoot\": HTMLTableSectionElement;\n \"th\": HTMLTableHeaderCellElement;\n \"thead\": HTMLTableSectionElement;\n \"time\": HTMLTimeElement;\n \"title\": HTMLTitleElement;\n \"tr\": HTMLTableRowElement;\n \"track\": HTMLTrackElement;\n \"tspan\": SVGTSpanElement;\n \"tt\": HTMLElement;\n \"u\": HTMLElement;\n \"ul\": HTMLUListElement;\n \"use\": SVGUseElement;\n \"var\": HTMLElement;\n \"video\": HTMLVideoElement;\n \"view\": SVGViewElement;\n \"wbr\": HTMLElement;\n \"x-ms-webview\": MSHTMLWebViewElement;\n \"xmp\": HTMLPreElement;\n}\n\ninterface ElementListTagNameMap {\n \"a\": NodeListOf;\n \"abbr\": NodeListOf;\n \"acronym\": NodeListOf;\n \"address\": NodeListOf;\n \"applet\": NodeListOf;\n \"area\": NodeListOf;\n \"article\": NodeListOf;\n \"aside\": NodeListOf;\n \"audio\": NodeListOf;\n \"b\": NodeListOf;\n \"base\": NodeListOf;\n \"basefont\": NodeListOf;\n \"bdo\": NodeListOf;\n \"big\": NodeListOf;\n \"blockquote\": NodeListOf;\n \"body\": NodeListOf;\n \"br\": NodeListOf;\n \"button\": NodeListOf;\n \"canvas\": NodeListOf;\n \"caption\": NodeListOf;\n \"center\": NodeListOf;\n \"circle\": NodeListOf;\n \"cite\": NodeListOf;\n \"clippath\": NodeListOf;\n \"code\": NodeListOf;\n \"col\": NodeListOf;\n \"colgroup\": NodeListOf;\n \"data\": NodeListOf;\n \"datalist\": NodeListOf;\n \"dd\": NodeListOf;\n \"defs\": NodeListOf;\n \"del\": NodeListOf;\n \"desc\": NodeListOf;\n \"dfn\": NodeListOf;\n \"dir\": NodeListOf;\n \"div\": NodeListOf;\n \"dl\": NodeListOf;\n \"dt\": NodeListOf;\n \"ellipse\": NodeListOf;\n \"em\": NodeListOf;\n \"embed\": NodeListOf;\n \"feblend\": NodeListOf;\n \"fecolormatrix\": NodeListOf;\n \"fecomponenttransfer\": NodeListOf;\n \"fecomposite\": NodeListOf;\n \"feconvolvematrix\": NodeListOf;\n \"fediffuselighting\": NodeListOf;\n \"fedisplacementmap\": NodeListOf;\n \"fedistantlight\": NodeListOf;\n \"feflood\": NodeListOf;\n \"fefunca\": NodeListOf;\n \"fefuncb\": NodeListOf;\n \"fefuncg\": NodeListOf;\n \"fefuncr\": NodeListOf;\n \"fegaussianblur\": NodeListOf;\n \"feimage\": NodeListOf;\n \"femerge\": NodeListOf;\n \"femergenode\": NodeListOf;\n \"femorphology\": NodeListOf;\n \"feoffset\": NodeListOf;\n \"fepointlight\": NodeListOf;\n \"fespecularlighting\": NodeListOf;\n \"fespotlight\": NodeListOf;\n \"fetile\": NodeListOf;\n \"feturbulence\": NodeListOf;\n \"fieldset\": NodeListOf;\n \"figcaption\": NodeListOf;\n \"figure\": NodeListOf;\n \"filter\": NodeListOf;\n \"font\": NodeListOf;\n \"footer\": NodeListOf;\n \"foreignobject\": NodeListOf;\n \"form\": NodeListOf;\n \"frame\": NodeListOf;\n \"frameset\": NodeListOf;\n \"g\": NodeListOf;\n \"h1\": NodeListOf;\n \"h2\": NodeListOf;\n \"h3\": NodeListOf;\n \"h4\": NodeListOf;\n \"h5\": NodeListOf;\n \"h6\": NodeListOf;\n \"head\": NodeListOf;\n \"header\": NodeListOf;\n \"hgroup\": NodeListOf;\n \"hr\": NodeListOf;\n \"html\": NodeListOf;\n \"i\": NodeListOf;\n \"iframe\": NodeListOf;\n \"image\": NodeListOf;\n \"img\": NodeListOf;\n \"input\": NodeListOf;\n \"ins\": NodeListOf;\n \"isindex\": NodeListOf;\n \"kbd\": NodeListOf;\n \"keygen\": NodeListOf;\n \"label\": NodeListOf;\n \"legend\": NodeListOf;\n \"li\": NodeListOf;\n \"line\": NodeListOf;\n \"lineargradient\": NodeListOf;\n \"link\": NodeListOf;\n \"listing\": NodeListOf;\n \"map\": NodeListOf;\n \"mark\": NodeListOf;\n \"marker\": NodeListOf;\n \"marquee\": NodeListOf;\n \"mask\": NodeListOf;\n \"menu\": NodeListOf;\n \"meta\": NodeListOf;\n \"metadata\": NodeListOf;\n \"meter\": NodeListOf;\n \"nav\": NodeListOf;\n \"nextid\": NodeListOf;\n \"nobr\": NodeListOf;\n \"noframes\": NodeListOf;\n \"noscript\": NodeListOf;\n \"object\": NodeListOf;\n \"ol\": NodeListOf;\n \"optgroup\": NodeListOf;\n \"option\": NodeListOf;\n \"output\": NodeListOf;\n \"p\": NodeListOf;\n \"param\": NodeListOf;\n \"path\": NodeListOf;\n \"pattern\": NodeListOf;\n \"picture\": NodeListOf;\n \"plaintext\": NodeListOf;\n \"polygon\": NodeListOf;\n \"polyline\": NodeListOf;\n \"pre\": NodeListOf;\n \"progress\": NodeListOf;\n \"q\": NodeListOf;\n \"radialgradient\": NodeListOf;\n \"rect\": NodeListOf;\n \"rt\": NodeListOf;\n \"ruby\": NodeListOf;\n \"s\": NodeListOf;\n \"samp\": NodeListOf;\n \"script\": NodeListOf;\n \"section\": NodeListOf;\n \"select\": NodeListOf;\n \"small\": NodeListOf;\n \"source\": NodeListOf;\n \"span\": NodeListOf;\n \"stop\": NodeListOf;\n \"strike\": NodeListOf;\n \"strong\": NodeListOf;\n \"style\": NodeListOf;\n \"sub\": NodeListOf;\n \"sup\": NodeListOf;\n \"svg\": NodeListOf;\n \"switch\": NodeListOf;\n \"symbol\": NodeListOf;\n \"table\": NodeListOf;\n \"tbody\": NodeListOf;\n \"td\": NodeListOf;\n \"template\": NodeListOf;\n \"text\": NodeListOf;\n \"textpath\": NodeListOf;\n \"textarea\": NodeListOf;\n \"tfoot\": NodeListOf;\n \"th\": NodeListOf;\n \"thead\": NodeListOf;\n \"time\": NodeListOf;\n \"title\": NodeListOf;\n \"tr\": NodeListOf;\n \"track\": NodeListOf;\n \"tspan\": NodeListOf;\n \"tt\": NodeListOf;\n \"u\": NodeListOf;\n \"ul\": NodeListOf;\n \"use\": NodeListOf;\n \"var\": NodeListOf;\n \"video\": NodeListOf;\n \"view\": NodeListOf;\n \"wbr\": NodeListOf;\n \"x-ms-webview\": NodeListOf;\n \"xmp\": NodeListOf;\n}\n\ndeclare var Audio: {new(src?: string): HTMLAudioElement; };\ndeclare var Image: {new(width?: number, height?: number): HTMLImageElement; };\ndeclare var Option: {new(text?: string, value?: string, defaultSelected?: boolean, selected?: boolean): HTMLOptionElement; };\ndeclare var applicationCache: ApplicationCache;\ndeclare var caches: CacheStorage;\ndeclare var clientInformation: Navigator;\ndeclare var closed: boolean;\ndeclare var crypto: Crypto;\ndeclare var defaultStatus: string;\ndeclare var devicePixelRatio: number;\ndeclare var doNotTrack: string;\ndeclare var document: Document;\ndeclare var event: Event | undefined;\ndeclare var external: External;\ndeclare var frameElement: Element;\ndeclare var frames: Window;\ndeclare var history: History;\ndeclare var innerHeight: number;\ndeclare var innerWidth: number;\ndeclare var isSecureContext: boolean;\ndeclare var length: number;\ndeclare var location: Location;\ndeclare var locationbar: BarProp;\ndeclare var menubar: BarProp;\ndeclare var msContentScript: ExtensionScriptApis;\ndeclare var msCredentials: MSCredentials;\ndeclare const name: never;\ndeclare var navigator: Navigator;\ndeclare var offscreenBuffering: string | boolean;\ndeclare var onabort: (this: Window, ev: UIEvent) => any;\ndeclare var onafterprint: (this: Window, ev: Event) => any;\ndeclare var onbeforeprint: (this: Window, ev: Event) => any;\ndeclare var onbeforeunload: (this: Window, ev: BeforeUnloadEvent) => any;\ndeclare var onblur: (this: Window, ev: FocusEvent) => any;\ndeclare var oncanplay: (this: Window, ev: Event) => any;\ndeclare var oncanplaythrough: (this: Window, ev: Event) => any;\ndeclare var onchange: (this: Window, ev: Event) => any;\ndeclare var onclick: (this: Window, ev: MouseEvent) => any;\ndeclare var oncompassneedscalibration: (this: Window, ev: Event) => any;\ndeclare var oncontextmenu: (this: Window, ev: PointerEvent) => any;\ndeclare var ondblclick: (this: Window, ev: MouseEvent) => any;\ndeclare var ondevicelight: (this: Window, ev: DeviceLightEvent) => any;\ndeclare var ondevicemotion: (this: Window, ev: DeviceMotionEvent) => any;\ndeclare var ondeviceorientation: (this: Window, ev: DeviceOrientationEvent) => any;\ndeclare var ondrag: (this: Window, ev: DragEvent) => any;\ndeclare var ondragend: (this: Window, ev: DragEvent) => any;\ndeclare var ondragenter: (this: Window, ev: DragEvent) => any;\ndeclare var ondragleave: (this: Window, ev: DragEvent) => any;\ndeclare var ondragover: (this: Window, ev: DragEvent) => any;\ndeclare var ondragstart: (this: Window, ev: DragEvent) => any;\ndeclare var ondrop: (this: Window, ev: DragEvent) => any;\ndeclare var ondurationchange: (this: Window, ev: Event) => any;\ndeclare var onemptied: (this: Window, ev: Event) => any;\ndeclare var onended: (this: Window, ev: MediaStreamErrorEvent) => any;\ndeclare var onerror: ErrorEventHandler;\ndeclare var onfocus: (this: Window, ev: FocusEvent) => any;\ndeclare var onhashchange: (this: Window, ev: HashChangeEvent) => any;\ndeclare var oninput: (this: Window, ev: Event) => any;\ndeclare var oninvalid: (this: Window, ev: Event) => any;\ndeclare var onkeydown: (this: Window, ev: KeyboardEvent) => any;\ndeclare var onkeypress: (this: Window, ev: KeyboardEvent) => any;\ndeclare var onkeyup: (this: Window, ev: KeyboardEvent) => any;\ndeclare var onload: (this: Window, ev: Event) => any;\ndeclare var onloadeddata: (this: Window, ev: Event) => any;\ndeclare var onloadedmetadata: (this: Window, ev: Event) => any;\ndeclare var onloadstart: (this: Window, ev: Event) => any;\ndeclare var onmessage: (this: Window, ev: MessageEvent) => any;\ndeclare var onmousedown: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseenter: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseleave: (this: Window, ev: MouseEvent) => any;\ndeclare var onmousemove: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseout: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseover: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseup: (this: Window, ev: MouseEvent) => any;\ndeclare var onmousewheel: (this: Window, ev: WheelEvent) => any;\ndeclare var onmsgesturechange: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturedoubletap: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgestureend: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturehold: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturestart: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturetap: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsinertiastart: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmspointercancel: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerdown: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerenter: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerleave: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointermove: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerout: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerover: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerup: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onoffline: (this: Window, ev: Event) => any;\ndeclare var ononline: (this: Window, ev: Event) => any;\ndeclare var onorientationchange: (this: Window, ev: Event) => any;\ndeclare var onpagehide: (this: Window, ev: PageTransitionEvent) => any;\ndeclare var onpageshow: (this: Window, ev: PageTransitionEvent) => any;\ndeclare var onpause: (this: Window, ev: Event) => any;\ndeclare var onplay: (this: Window, ev: Event) => any;\ndeclare var onplaying: (this: Window, ev: Event) => any;\ndeclare var onpopstate: (this: Window, ev: PopStateEvent) => any;\ndeclare var onprogress: (this: Window, ev: ProgressEvent) => any;\ndeclare var onratechange: (this: Window, ev: Event) => any;\ndeclare var onreadystatechange: (this: Window, ev: ProgressEvent) => any;\ndeclare var onreset: (this: Window, ev: Event) => any;\ndeclare var onresize: (this: Window, ev: UIEvent) => any;\ndeclare var onscroll: (this: Window, ev: UIEvent) => any;\ndeclare var onseeked: (this: Window, ev: Event) => any;\ndeclare var onseeking: (this: Window, ev: Event) => any;\ndeclare var onselect: (this: Window, ev: UIEvent) => any;\ndeclare var onstalled: (this: Window, ev: Event) => any;\ndeclare var onstorage: (this: Window, ev: StorageEvent) => any;\ndeclare var onsubmit: (this: Window, ev: Event) => any;\ndeclare var onsuspend: (this: Window, ev: Event) => any;\ndeclare var ontimeupdate: (this: Window, ev: Event) => any;\ndeclare var ontouchcancel: (ev: TouchEvent) => any;\ndeclare var ontouchend: (ev: TouchEvent) => any;\ndeclare var ontouchmove: (ev: TouchEvent) => any;\ndeclare var ontouchstart: (ev: TouchEvent) => any;\ndeclare var onunload: (this: Window, ev: Event) => any;\ndeclare var onvolumechange: (this: Window, ev: Event) => any;\ndeclare var onwaiting: (this: Window, ev: Event) => any;\ndeclare var opener: any;\ndeclare var orientation: string | number;\ndeclare var outerHeight: number;\ndeclare var outerWidth: number;\ndeclare var pageXOffset: number;\ndeclare var pageYOffset: number;\ndeclare var parent: Window;\ndeclare var performance: Performance;\ndeclare var personalbar: BarProp;\ndeclare var screen: Screen;\ndeclare var screenLeft: number;\ndeclare var screenTop: number;\ndeclare var screenX: number;\ndeclare var screenY: number;\ndeclare var scrollX: number;\ndeclare var scrollY: number;\ndeclare var scrollbars: BarProp;\ndeclare var self: Window;\ndeclare var speechSynthesis: SpeechSynthesis;\ndeclare var status: string;\ndeclare var statusbar: BarProp;\ndeclare var styleMedia: StyleMedia;\ndeclare var toolbar: BarProp;\ndeclare var top: Window;\ndeclare var window: Window;\ndeclare var customElements: CustomElementRegistry;\ndeclare function alert(message?: any): void;\ndeclare function blur(): void;\ndeclare function cancelAnimationFrame(handle: number): void;\ndeclare function captureEvents(): void;\ndeclare function close(): void;\ndeclare function confirm(message?: string): boolean;\ndeclare function departFocus(navigationReason: NavigationReason, origin: FocusNavigationOrigin): void;\ndeclare function focus(): void;\ndeclare function getComputedStyle(elt: Element, pseudoElt?: string): CSSStyleDeclaration;\ndeclare function getMatchedCSSRules(elt: Element, pseudoElt?: string): CSSRuleList;\ndeclare function getSelection(): Selection;\ndeclare function matchMedia(mediaQuery: string): MediaQueryList;\ndeclare function moveBy(x?: number, y?: number): void;\ndeclare function moveTo(x?: number, y?: number): void;\ndeclare function msWriteProfilerMark(profilerMarkName: string): void;\ndeclare function open(url?: string, target?: string, features?: string, replace?: boolean): Window;\ndeclare function postMessage(message: any, targetOrigin: string, transfer?: any[]): void;\ndeclare function print(): void;\ndeclare function prompt(message?: string, _default?: string): string | null;\ndeclare function releaseEvents(): void;\ndeclare function requestAnimationFrame(callback: FrameRequestCallback): number;\ndeclare function resizeBy(x?: number, y?: number): void;\ndeclare function resizeTo(x?: number, y?: number): void;\ndeclare function scroll(x?: number, y?: number): void;\ndeclare function scrollBy(x?: number, y?: number): void;\ndeclare function scrollTo(x?: number, y?: number): void;\ndeclare function stop(): void;\ndeclare function webkitCancelAnimationFrame(handle: number): void;\ndeclare function webkitConvertPointFromNodeToPage(node: Node, pt: WebKitPoint): WebKitPoint;\ndeclare function webkitConvertPointFromPageToNode(node: Node, pt: WebKitPoint): WebKitPoint;\ndeclare function webkitRequestAnimationFrame(callback: FrameRequestCallback): number;\ndeclare function createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, options?: ImageBitmapOptions): Promise;\ndeclare function createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, sx: number, sy: number, sw: number, sh: number, options?: ImageBitmapOptions): Promise;\ndeclare function scroll(options?: ScrollToOptions): void;\ndeclare function scrollTo(options?: ScrollToOptions): void;\ndeclare function scrollBy(options?: ScrollToOptions): void;\ndeclare function toString(): string;\ndeclare function dispatchEvent(evt: Event): boolean;\ndeclare function removeEventListener(type: string, listener?: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;\ndeclare function clearInterval(handle: number): void;\ndeclare function clearTimeout(handle: number): void;\ndeclare function setInterval(handler: (...args: any[]) => void, timeout: number): number;\ndeclare function setInterval(handler: any, timeout?: any, ...args: any[]): number;\ndeclare function setTimeout(handler: (...args: any[]) => void, timeout: number): number;\ndeclare function setTimeout(handler: any, timeout?: any, ...args: any[]): number;\ndeclare function clearImmediate(handle: number): void;\ndeclare function setImmediate(handler: (...args: any[]) => void): number;\ndeclare function setImmediate(handler: any, ...args: any[]): number;\ndeclare var sessionStorage: Storage;\ndeclare var localStorage: Storage;\ndeclare var console: Console;\ndeclare var onpointercancel: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerdown: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerenter: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerleave: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointermove: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerout: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerover: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerup: (this: Window, ev: PointerEvent) => any;\ndeclare var onwheel: (this: Window, ev: WheelEvent) => any;\ndeclare var indexedDB: IDBFactory;\ndeclare function atob(encodedString: string): string;\ndeclare function btoa(rawString: string): string;\ndeclare function fetch(input: RequestInfo, init?: RequestInit): Promise;\ndeclare function addEventListener(type: K, listener: (this: Window, ev: WindowEventMap[K]) => any, useCapture?: boolean): void;\ndeclare function addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\ntype AAGUID = string;\ntype AlgorithmIdentifier = string | Algorithm;\ntype BodyInit = any;\ntype ByteString = string;\ntype ConstrainBoolean = boolean | ConstrainBooleanParameters;\ntype ConstrainDOMString = string | string[] | ConstrainDOMStringParameters;\ntype ConstrainDouble = number | ConstrainDoubleRange;\ntype ConstrainLong = number | ConstrainLongRange;\ntype CryptoOperationData = ArrayBufferView;\ntype GLbitfield = number;\ntype GLboolean = boolean;\ntype GLbyte = number;\ntype GLclampf = number;\ntype GLenum = number;\ntype GLfloat = number;\ntype GLint = number;\ntype GLintptr = number;\ntype GLshort = number;\ntype GLsizei = number;\ntype GLsizeiptr = number;\ntype GLubyte = number;\ntype GLuint = number;\ntype GLushort = number;\ntype HeadersInit = any;\ntype IDBKeyPath = string;\ntype KeyFormat = string;\ntype KeyType = string;\ntype KeyUsage = string;\ntype MSInboundPayload = MSVideoRecvPayload | MSAudioRecvPayload;\ntype MSLocalClientEvent = MSLocalClientEventBase | MSAudioLocalClientEvent;\ntype MSOutboundPayload = MSVideoSendPayload | MSAudioSendPayload;\ntype RTCIceGatherCandidate = RTCIceCandidateDictionary | RTCIceCandidateComplete;\ntype RTCTransport = RTCDtlsTransport | RTCSrtpSdesTransport;\ntype RequestInfo = Request | string;\ntype USVString = string;\ntype payloadtype = number;\ntype ScrollBehavior = \"auto\" | \"instant\" | \"smooth\";\ntype ScrollLogicalPosition = \"start\" | \"center\" | \"end\" | \"nearest\";\ntype IDBValidKey = number | string | Date | IDBArrayKey;\ntype BufferSource = ArrayBuffer | ArrayBufferView;\ntype MouseWheelEvent = WheelEvent;\ntype ScrollRestoration = \"auto\" | \"manual\";\ntype FormDataEntryValue = string | File;\ntype AppendMode = \"segments\" | \"sequence\";\ntype AudioContextState = \"suspended\" | \"running\" | \"closed\";\ntype BiquadFilterType = \"lowpass\" | \"highpass\" | \"bandpass\" | \"lowshelf\" | \"highshelf\" | \"peaking\" | \"notch\" | \"allpass\";\ntype CanvasFillRule = \"nonzero\" | \"evenodd\";\ntype ChannelCountMode = \"max\" | \"clamped-max\" | \"explicit\";\ntype ChannelInterpretation = \"speakers\" | \"discrete\";\ntype DistanceModelType = \"linear\" | \"inverse\" | \"exponential\";\ntype ExpandGranularity = \"character\" | \"word\" | \"sentence\" | \"textedit\";\ntype GamepadInputEmulationType = \"mouse\" | \"keyboard\" | \"gamepad\";\ntype IDBCursorDirection = \"next\" | \"nextunique\" | \"prev\" | \"prevunique\";\ntype IDBRequestReadyState = \"pending\" | \"done\";\ntype IDBTransactionMode = \"readonly\" | \"readwrite\" | \"versionchange\";\ntype ListeningState = \"inactive\" | \"active\" | \"disambiguation\";\ntype MSCredentialType = \"FIDO_2_0\";\ntype MSIceAddrType = \"os\" | \"stun\" | \"turn\" | \"peer-derived\";\ntype MSIceType = \"failed\" | \"direct\" | \"relay\";\ntype MSStatsType = \"description\" | \"localclientevent\" | \"inbound-network\" | \"outbound-network\" | \"inbound-payload\" | \"outbound-payload\" | \"transportdiagnostics\";\ntype MSTransportType = \"Embedded\" | \"USB\" | \"NFC\" | \"BT\";\ntype MSWebViewPermissionState = \"unknown\" | \"defer\" | \"allow\" | \"deny\";\ntype MSWebViewPermissionType = \"geolocation\" | \"unlimitedIndexedDBQuota\" | \"media\" | \"pointerlock\" | \"webnotifications\";\ntype MediaDeviceKind = \"audioinput\" | \"audiooutput\" | \"videoinput\";\ntype MediaKeyMessageType = \"license-request\" | \"license-renewal\" | \"license-release\" | \"individualization-request\";\ntype MediaKeySessionType = \"temporary\" | \"persistent-license\" | \"persistent-release-message\";\ntype MediaKeyStatus = \"usable\" | \"expired\" | \"output-downscaled\" | \"output-not-allowed\" | \"status-pending\" | \"internal-error\";\ntype MediaKeysRequirement = \"required\" | \"optional\" | \"not-allowed\";\ntype MediaStreamTrackState = \"live\" | \"ended\";\ntype NavigationReason = \"up\" | \"down\" | \"left\" | \"right\";\ntype NavigationType = \"navigate\" | \"reload\" | \"back_forward\" | \"prerender\";\ntype NotificationDirection = \"auto\" | \"ltr\" | \"rtl\";\ntype NotificationPermission = \"default\" | \"denied\" | \"granted\";\ntype OscillatorType = \"sine\" | \"square\" | \"sawtooth\" | \"triangle\" | \"custom\";\ntype OverSampleType = \"none\" | \"2x\" | \"4x\";\ntype PanningModelType = \"equalpower\";\ntype PaymentComplete = \"success\" | \"fail\" | \"\";\ntype PaymentShippingType = \"shipping\" | \"delivery\" | \"pickup\";\ntype PushEncryptionKeyName = \"p256dh\" | \"auth\";\ntype PushPermissionState = \"granted\" | \"denied\" | \"prompt\";\ntype RTCBundlePolicy = \"balanced\" | \"max-compat\" | \"max-bundle\";\ntype RTCDegradationPreference = \"maintain-framerate\" | \"maintain-resolution\" | \"balanced\";\ntype RTCDtlsRole = \"auto\" | \"client\" | \"server\";\ntype RTCDtlsTransportState = \"new\" | \"connecting\" | \"connected\" | \"closed\";\ntype RTCIceCandidateType = \"host\" | \"srflx\" | \"prflx\" | \"relay\";\ntype RTCIceComponent = \"RTP\" | \"RTCP\";\ntype RTCIceConnectionState = \"new\" | \"checking\" | \"connected\" | \"completed\" | \"failed\" | \"disconnected\" | \"closed\";\ntype RTCIceGatherPolicy = \"all\" | \"nohost\" | \"relay\";\ntype RTCIceGathererState = \"new\" | \"gathering\" | \"complete\";\ntype RTCIceGatheringState = \"new\" | \"gathering\" | \"complete\";\ntype RTCIceProtocol = \"udp\" | \"tcp\";\ntype RTCIceRole = \"controlling\" | \"controlled\";\ntype RTCIceTcpCandidateType = \"active\" | \"passive\" | \"so\";\ntype RTCIceTransportPolicy = \"none\" | \"relay\" | \"all\";\ntype RTCIceTransportState = \"new\" | \"checking\" | \"connected\" | \"completed\" | \"disconnected\" | \"closed\";\ntype RTCSdpType = \"offer\" | \"pranswer\" | \"answer\";\ntype RTCSignalingState = \"stable\" | \"have-local-offer\" | \"have-remote-offer\" | \"have-local-pranswer\" | \"have-remote-pranswer\" | \"closed\";\ntype RTCStatsIceCandidatePairState = \"frozen\" | \"waiting\" | \"inprogress\" | \"failed\" | \"succeeded\" | \"cancelled\";\ntype RTCStatsIceCandidateType = \"host\" | \"serverreflexive\" | \"peerreflexive\" | \"relayed\";\ntype RTCStatsType = \"inboundrtp\" | \"outboundrtp\" | \"session\" | \"datachannel\" | \"track\" | \"transport\" | \"candidatepair\" | \"localcandidate\" | \"remotecandidate\";\ntype ReferrerPolicy = \"\" | \"no-referrer\" | \"no-referrer-when-downgrade\" | \"origin-only\" | \"origin-when-cross-origin\" | \"unsafe-url\";\ntype RequestCache = \"default\" | \"no-store\" | \"reload\" | \"no-cache\" | \"force-cache\";\ntype RequestCredentials = \"omit\" | \"same-origin\" | \"include\";\ntype RequestDestination = \"\" | \"document\" | \"sharedworker\" | \"subresource\" | \"unknown\" | \"worker\";\ntype RequestMode = \"navigate\" | \"same-origin\" | \"no-cors\" | \"cors\";\ntype RequestRedirect = \"follow\" | \"error\" | \"manual\";\ntype RequestType = \"\" | \"audio\" | \"font\" | \"image\" | \"script\" | \"style\" | \"track\" | \"video\";\ntype ResponseType = \"basic\" | \"cors\" | \"default\" | \"error\" | \"opaque\" | \"opaqueredirect\";\ntype ScopedCredentialType = \"ScopedCred\";\ntype ServiceWorkerState = \"installing\" | \"installed\" | \"activating\" | \"activated\" | \"redundant\";\ntype Transport = \"usb\" | \"nfc\" | \"ble\";\ntype VideoFacingModeEnum = \"user\" | \"environment\" | \"left\" | \"right\";\ntype VisibilityState = \"hidden\" | \"visible\" | \"prerender\" | \"unloaded\";\ntype XMLHttpRequestResponseType = \"\" | \"arraybuffer\" | \"blob\" | \"document\" | \"json\" | \"text\";\n\n\n/////////////////////////////\n/// WorkerGlobalScope APIs\n/////////////////////////////\n// These are only available in a Web Worker\ndeclare function importScripts(...urls: string[]): void;\n\n\n\n\n/////////////////////////////\n/// Windows Script Host APIS\n/////////////////////////////\n\n\ninterface ActiveXObject {\n new (s: string): any;\n}\ndeclare var ActiveXObject: ActiveXObject;\n\ninterface ITextWriter {\n Write(s: string): void;\n WriteLine(s: string): void;\n Close(): void;\n}\n\ninterface TextStreamBase {\n /**\n * The column number of the current character position in an input stream.\n */\n Column: number;\n\n /**\n * The current line number in an input stream.\n */\n Line: number;\n\n /**\n * Closes a text stream.\n * It is not necessary to close standard streams; they close automatically when the process ends. If\n * you close a standard stream, be aware that any other pointers to that standard stream become invalid.\n */\n Close(): void;\n}\n\ninterface TextStreamWriter extends TextStreamBase {\n /**\n * Sends a string to an output stream.\n */\n Write(s: string): void;\n\n /**\n * Sends a specified number of blank lines (newline characters) to an output stream.\n */\n WriteBlankLines(intLines: number): void;\n\n /**\n * Sends a string followed by a newline character to an output stream.\n */\n WriteLine(s: string): void;\n}\n\ninterface TextStreamReader extends TextStreamBase {\n /**\n * Returns a specified number of characters from an input stream, starting at the current pointer position.\n * Does not return until the ENTER key is pressed.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n */\n Read(characters: number): string;\n\n /**\n * Returns all characters from an input stream.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n */\n ReadAll(): string;\n\n /**\n * Returns an entire line from an input stream.\n * Although this method extracts the newline character, it does not add it to the returned string.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n */\n ReadLine(): string;\n\n /**\n * Skips a specified number of characters when reading from an input text stream.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n * @param characters Positive number of characters to skip forward. (Backward skipping is not supported.)\n */\n Skip(characters: number): void;\n\n /**\n * Skips the next line when reading from an input text stream.\n * Can only be used on a stream in reading mode, not writing or appending mode.\n */\n SkipLine(): void;\n\n /**\n * Indicates whether the stream pointer position is at the end of a line.\n */\n AtEndOfLine: boolean;\n\n /**\n * Indicates whether the stream pointer position is at the end of a stream.\n */\n AtEndOfStream: boolean;\n}\n\ndeclare var WScript: {\n /**\n * Outputs text to either a message box (under WScript.exe) or the command console window followed by\n * a newline (under CScript.exe).\n */\n Echo(s: any): void;\n\n /**\n * Exposes the write-only error output stream for the current script.\n * Can be accessed only while using CScript.exe.\n */\n StdErr: TextStreamWriter;\n\n /**\n * Exposes the write-only output stream for the current script.\n * Can be accessed only while using CScript.exe.\n */\n StdOut: TextStreamWriter;\n Arguments: { length: number; Item(n: number): string; };\n\n /**\n * The full path of the currently running script.\n */\n ScriptFullName: string;\n\n /**\n * Forces the script to stop immediately, with an optional exit code.\n */\n Quit(exitCode?: number): number;\n\n /**\n * The Windows Script Host build version number.\n */\n BuildVersion: number;\n\n /**\n * Fully qualified path of the host executable.\n */\n FullName: string;\n\n /**\n * Gets/sets the script mode - interactive(true) or batch(false).\n */\n Interactive: boolean;\n\n /**\n * The name of the host executable (WScript.exe or CScript.exe).\n */\n Name: string;\n\n /**\n * Path of the directory containing the host executable.\n */\n Path: string;\n\n /**\n * The filename of the currently running script.\n */\n ScriptName: string;\n\n /**\n * Exposes the read-only input stream for the current script.\n * Can be accessed only while using CScript.exe.\n */\n StdIn: TextStreamReader;\n\n /**\n * Windows Script Host version\n */\n Version: string;\n\n /**\n * Connects a COM object's event sources to functions named with a given prefix, in the form prefix_event.\n */\n ConnectObject(objEventSource: any, strPrefix: string): void;\n\n /**\n * Creates a COM object.\n * @param strProgiID\n * @param strPrefix Function names in the form prefix_event will be bound to this object's COM events.\n */\n CreateObject(strProgID: string, strPrefix?: string): any;\n\n /**\n * Disconnects a COM object from its event sources.\n */\n DisconnectObject(obj: any): void;\n\n /**\n * Retrieves an existing object with the specified ProgID from memory, or creates a new one from a file.\n * @param strPathname Fully qualified path to the file containing the object persisted to disk.\n * For objects in memory, pass a zero-length string.\n * @param strProgID\n * @param strPrefix Function names in the form prefix_event will be bound to this object's COM events.\n */\n GetObject(strPathname: string, strProgID?: string, strPrefix?: string): any;\n\n /**\n * Suspends script execution for a specified length of time, then continues execution.\n * @param intTime Interval (in milliseconds) to suspend script execution.\n */\n Sleep(intTime: number): void;\n};\n\n/**\n * Allows enumerating over a COM collection, which may not have indexed item access.\n */\ninterface Enumerator {\n /**\n * Returns true if the current item is the last one in the collection, or the collection is empty,\n * or the current item is undefined.\n */\n atEnd(): boolean;\n\n /**\n * Returns the current item in the collection\n */\n item(): T;\n\n /**\n * Resets the current item in the collection to the first item. If there are no items in the collection,\n * the current item is set to undefined.\n */\n moveFirst(): void;\n\n /**\n * Moves the current item to the next item in the collection. If the enumerator is at the end of\n * the collection or the collection is empty, the current item is set to undefined.\n */\n moveNext(): void;\n}\n\ninterface EnumeratorConstructor {\n new (collection: any): Enumerator;\n new (collection: any): Enumerator;\n}\n\ndeclare var Enumerator: EnumeratorConstructor;\n\n/**\n * Enables reading from a COM safe array, which might have an alternate lower bound, or multiple dimensions.\n */\ninterface VBArray {\n /**\n * Returns the number of dimensions (1-based).\n */\n dimensions(): number;\n\n /**\n * Takes an index for each dimension in the array, and returns the item at the corresponding location.\n */\n getItem(dimension1Index: number, ...dimensionNIndexes: number[]): T;\n\n /**\n * Returns the smallest available index for a given dimension.\n * @param dimension 1-based dimension (defaults to 1)\n */\n lbound(dimension?: number): number;\n\n /**\n * Returns the largest available index for a given dimension.\n * @param dimension 1-based dimension (defaults to 1)\n */\n ubound(dimension?: number): number;\n\n /**\n * Returns a Javascript array with all the elements in the VBArray. If there are multiple dimensions,\n * each successive dimension is appended to the end of the array.\n * Example: [[1,2,3],[4,5,6]] becomes [1,2,3,4,5,6]\n */\n toArray(): T[];\n}\n\ninterface VBArrayConstructor {\n new (safeArray: any): VBArray;\n new (safeArray: any): VBArray;\n}\n\ndeclare var VBArray: VBArrayConstructor;\n\n/**\n * Automation date (VT_DATE)\n */\ninterface VarDate { }\n\ninterface DateConstructor {\n new (vd: VarDate): Date;\n}\n\ninterface Date {\n getVarDate: () => VarDate;\n}\n\n\n/// \n\ninterface DOMTokenList {\n [Symbol.iterator](): IterableIterator;\n}\n\ninterface FormData {\n /**\n * Returns an array of key, value pairs for every entry in the list\n */\n entries(): IterableIterator<[string, string | File]>;\n /**\n * Returns a list of keys in the list\n */\n keys(): IterableIterator;\n /**\n * Returns a list of values in the list\n */\n values(): IterableIterator;\n\n [Symbol.iterator](): IterableIterator;\n}\n\ninterface Headers {\n [Symbol.iterator](): IterableIterator<[string, string]>;\n /**\n * Returns an iterator allowing to go through all key/value pairs contained in this object.\n */\n entries(): IterableIterator<[string, string]>;\n /**\n * Returns an iterator allowing to go through all keys f the key/value pairs contained in this object.\n */\n keys(): IterableIterator;\n /**\n * Returns an iterator allowing to go through all values of the key/value pairs contained in this object.\n */\n values(): IterableIterator;\n}\n\ninterface NodeList {\n /**\n * Returns an array of key, value pairs for every entry in the list\n */\n entries(): IterableIterator<[number, Node]>;\n /**\n * Performs the specified action for each node in an list.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the list.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: Node, index: number, listObj: NodeList) => void, thisArg?: any): void;\n /**\n * Returns an list of keys in the list\n */\n keys(): IterableIterator;\n\n /**\n * Returns an list of values in the list\n */\n values(): IterableIterator;\n\n\n [Symbol.iterator](): IterableIterator;\n}\n\ninterface NodeListOf {\n\n /**\n * Returns an array of key, value pairs for every entry in the list\n */\n entries(): IterableIterator<[number, TNode]>;\n\n /**\n * Performs the specified action for each node in an list.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the list.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: TNode, index: number, listObj: NodeListOf) => void, thisArg?: any): void;\n /**\n * Returns an list of keys in the list\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the list\n */\n values(): IterableIterator;\n\n [Symbol.iterator](): IterableIterator;\n}\n\ninterface URLSearchParams {\n /**\n * Returns an array of key, value pairs for every entry in the search params\n */\n entries(): IterableIterator<[string, string]>;\n /**\n * Returns a list of keys in the search params\n */\n keys(): IterableIterator;\n /**\n * Returns a list of values in the search params\n */\n values(): IterableIterator;\n /**\n * iterate over key/value pairs\n */\n [Symbol.iterator](): IterableIterator<[string, string]>;\n}\n"}; }); +define([], function() { return { contents: "/*! *****************************************************************************\nCopyright (c) Microsoft Corporation. All rights reserved. \nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\nthis file except in compliance with the License. You may obtain a copy of the\nLicense at http://www.apache.org/licenses/LICENSE-2.0 \n \nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, \nMERCHANTABLITY OR NON-INFRINGEMENT. \n \nSee the Apache Version 2.0 License for specific language governing permissions\nand limitations under the License.\n***************************************************************************** */\n\n\n\n/// \n\n\n/////////////////////////////\n/// ECMAScript APIs\n/////////////////////////////\n\ndeclare const NaN: number;\ndeclare const Infinity: number;\n\n/**\n * Evaluates JavaScript code and executes it.\n * @param x A String value that contains valid JavaScript code.\n */\ndeclare function eval(x: string): any;\n\n/**\n * Converts A string to an integer.\n * @param s A string to convert into a number.\n * @param radix A value between 2 and 36 that specifies the base of the number in numString.\n * If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\n * All other strings are considered decimal.\n */\ndeclare function parseInt(s: string, radix?: number): number;\n\n/**\n * Converts a string to a floating-point number.\n * @param string A string that contains a floating-point number.\n */\ndeclare function parseFloat(string: string): number;\n\n/**\n * Returns a Boolean value that indicates whether a value is the reserved value NaN (not a number).\n * @param number A numeric value.\n */\ndeclare function isNaN(number: number): boolean;\n\n/**\n * Determines whether a supplied number is finite.\n * @param number Any numeric value.\n */\ndeclare function isFinite(number: number): boolean;\n\n/**\n * Gets the unencoded version of an encoded Uniform Resource Identifier (URI).\n * @param encodedURI A value representing an encoded URI.\n */\ndeclare function decodeURI(encodedURI: string): string;\n\n/**\n * Gets the unencoded version of an encoded component of a Uniform Resource Identifier (URI).\n * @param encodedURIComponent A value representing an encoded URI component.\n */\ndeclare function decodeURIComponent(encodedURIComponent: string): string;\n\n/**\n * Encodes a text string as a valid Uniform Resource Identifier (URI)\n * @param uri A value representing an encoded URI.\n */\ndeclare function encodeURI(uri: string): string;\n\n/**\n * Encodes a text string as a valid component of a Uniform Resource Identifier (URI).\n * @param uriComponent A value representing an encoded URI component.\n */\ndeclare function encodeURIComponent(uriComponent: string): string;\n\ninterface PropertyDescriptor {\n configurable?: boolean;\n enumerable?: boolean;\n value?: any;\n writable?: boolean;\n get?(): any;\n set?(v: any): void;\n}\n\ninterface PropertyDescriptorMap {\n [s: string]: PropertyDescriptor;\n}\n\ninterface Object {\n /** The initial value of Object.prototype.constructor is the standard built-in Object constructor. */\n constructor: Function;\n\n /** Returns a string representation of an object. */\n toString(): string;\n\n /** Returns a date converted to a string using the current locale. */\n toLocaleString(): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): Object;\n\n /**\n * Determines whether an object has a property with the specified name.\n * @param v A property name.\n */\n hasOwnProperty(v: string): boolean;\n\n /**\n * Determines whether an object exists in another object's prototype chain.\n * @param v Another object whose prototype chain is to be checked.\n */\n isPrototypeOf(v: Object): boolean;\n\n /**\n * Determines whether a specified property is enumerable.\n * @param v A property name.\n */\n propertyIsEnumerable(v: string): boolean;\n}\n\ninterface ObjectConstructor {\n new(value?: any): Object;\n (): any;\n (value: any): any;\n\n /** A reference to the prototype for a class of objects. */\n readonly prototype: Object;\n\n /**\n * Returns the prototype of an object.\n * @param o The object that references the prototype.\n */\n getPrototypeOf(o: any): any;\n\n /**\n * Gets the own property descriptor of the specified object.\n * An own property descriptor is one that is defined directly on the object and is not inherited from the object's prototype.\n * @param o Object that contains the property.\n * @param p Name of the property.\n */\n getOwnPropertyDescriptor(o: any, p: string): PropertyDescriptor;\n\n /**\n * Returns the names of the own properties of an object. The own properties of an object are those that are defined directly\n * on that object, and are not inherited from the object's prototype. The properties of an object include both fields (objects) and functions.\n * @param o Object that contains the own properties.\n */\n getOwnPropertyNames(o: any): string[];\n\n /**\n * Creates an object that has the specified prototype or that has null prototype.\n * @param o Object to use as a prototype. May be null.\n */\n create(o: object | null): any;\n\n /**\n * Creates an object that has the specified prototype, and that optionally contains specified properties.\n * @param o Object to use as a prototype. May be null\n * @param properties JavaScript object that contains one or more property descriptors.\n */\n create(o: object | null, properties: PropertyDescriptorMap & ThisType): any;\n\n /**\n * Adds a property to an object, or modifies attributes of an existing property.\n * @param o Object on which to add or modify the property. This can be a native JavaScript object (that is, a user-defined object or a built in object) or a DOM object.\n * @param p The property name.\n * @param attributes Descriptor for the property. It can be for a data property or an accessor property.\n */\n defineProperty(o: any, p: string, attributes: PropertyDescriptor & ThisType): any;\n\n /**\n * Adds one or more properties to an object, and/or modifies attributes of existing properties.\n * @param o Object on which to add or modify the properties. This can be a native JavaScript object or a DOM object.\n * @param properties JavaScript object that contains one or more descriptor objects. Each descriptor object describes a data property or an accessor property.\n */\n defineProperties(o: any, properties: PropertyDescriptorMap & ThisType): any;\n\n /**\n * Prevents the modification of attributes of existing properties, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n seal(o: T): T;\n\n /**\n * Prevents the modification of existing property attributes and values, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n freeze(a: T[]): ReadonlyArray;\n\n /**\n * Prevents the modification of existing property attributes and values, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n freeze(f: T): T;\n\n /**\n * Prevents the modification of existing property attributes and values, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n freeze(o: T): Readonly;\n\n /**\n * Prevents the addition of new properties to an object.\n * @param o Object to make non-extensible.\n */\n preventExtensions(o: T): T;\n\n /**\n * Returns true if existing property attributes cannot be modified in an object and new properties cannot be added to the object.\n * @param o Object to test.\n */\n isSealed(o: any): boolean;\n\n /**\n * Returns true if existing property attributes and values cannot be modified in an object, and new properties cannot be added to the object.\n * @param o Object to test.\n */\n isFrozen(o: any): boolean;\n\n /**\n * Returns a value that indicates whether new properties can be added to an object.\n * @param o Object to test.\n */\n isExtensible(o: any): boolean;\n\n /**\n * Returns the names of the enumerable properties and methods of an object.\n * @param o Object that contains the properties and methods. This can be an object that you created or an existing Document Object Model (DOM) object.\n */\n keys(o: any): string[];\n}\n\n/**\n * Provides functionality common to all JavaScript objects.\n */\ndeclare const Object: ObjectConstructor;\n\n/**\n * Creates a new function.\n */\ninterface Function {\n /**\n * Calls the function, substituting the specified object for the this value of the function, and the specified array for the arguments of the function.\n * @param thisArg The object to be used as the this object.\n * @param argArray A set of arguments to be passed to the function.\n */\n apply(this: Function, thisArg: any, argArray?: any): any;\n\n /**\n * Calls a method of an object, substituting another object for the current object.\n * @param thisArg The object to be used as the current object.\n * @param argArray A list of arguments to be passed to the method.\n */\n call(this: Function, thisArg: any, ...argArray: any[]): any;\n\n /**\n * For a given function, creates a bound function that has the same body as the original function.\n * The this object of the bound function is associated with the specified object, and has the specified initial parameters.\n * @param thisArg An object to which the this keyword can refer inside the new function.\n * @param argArray A list of arguments to be passed to the new function.\n */\n bind(this: Function, thisArg: any, ...argArray: any[]): any;\n\n /** Returns a string representation of a function. */\n toString(): string;\n\n prototype: any;\n readonly length: number;\n\n // Non-standard extensions\n arguments: any;\n caller: Function;\n}\n\ninterface FunctionConstructor {\n /**\n * Creates a new function.\n * @param args A list of arguments the function accepts.\n */\n new(...args: string[]): Function;\n (...args: string[]): Function;\n readonly prototype: Function;\n}\n\ndeclare const Function: FunctionConstructor;\n\ninterface IArguments {\n [index: number]: any;\n length: number;\n callee: Function;\n}\n\ninterface String {\n /** Returns a string representation of a string. */\n toString(): string;\n\n /**\n * Returns the character at the specified index.\n * @param pos The zero-based index of the desired character.\n */\n charAt(pos: number): string;\n\n /**\n * Returns the Unicode value of the character at the specified location.\n * @param index The zero-based index of the desired character. If there is no character at the specified index, NaN is returned.\n */\n charCodeAt(index: number): number;\n\n /**\n * Returns a string that contains the concatenation of two or more strings.\n * @param strings The strings to append to the end of the string.\n */\n concat(...strings: string[]): string;\n\n /**\n * Returns the position of the first occurrence of a substring.\n * @param searchString The substring to search for in the string\n * @param position The index at which to begin searching the String object. If omitted, search starts at the beginning of the string.\n */\n indexOf(searchString: string, position?: number): number;\n\n /**\n * Returns the last occurrence of a substring in the string.\n * @param searchString The substring to search for.\n * @param position The index at which to begin searching. If omitted, the search begins at the end of the string.\n */\n lastIndexOf(searchString: string, position?: number): number;\n\n /**\n * Determines whether two strings are equivalent in the current locale.\n * @param that String to compare to target string\n */\n localeCompare(that: string): number;\n\n /**\n * Matches a string with a regular expression, and returns an array containing the results of that search.\n * @param regexp A variable name or string literal containing the regular expression pattern and flags.\n */\n match(regexp: string | RegExp): RegExpMatchArray | null;\n\n /**\n * Replaces text in a string, using a regular expression or search string.\n * @param searchValue A string to search for.\n * @param replaceValue A string containing the text to replace for every successful match of searchValue in this string.\n */\n replace(searchValue: string | RegExp, replaceValue: string): string;\n\n /**\n * Replaces text in a string, using a regular expression or search string.\n * @param searchValue A string to search for.\n * @param replacer A function that returns the replacement text.\n */\n replace(searchValue: string | RegExp, replacer: (substring: string, ...args: any[]) => string): string;\n\n /**\n * Finds the first substring match in a regular expression search.\n * @param regexp The regular expression pattern and applicable flags.\n */\n search(regexp: string | RegExp): number;\n\n /**\n * Returns a section of a string.\n * @param start The index to the beginning of the specified portion of stringObj.\n * @param end The index to the end of the specified portion of stringObj. The substring includes the characters up to, but not including, the character indicated by end.\n * If this value is not specified, the substring continues to the end of stringObj.\n */\n slice(start?: number, end?: number): string;\n\n /**\n * Split a string into substrings using the specified separator and return them as an array.\n * @param separator A string that identifies character or characters to use in separating the string. If omitted, a single-element array containing the entire string is returned.\n * @param limit A value used to limit the number of elements returned in the array.\n */\n split(separator: string | RegExp, limit?: number): string[];\n\n /**\n * Returns the substring at the specified location within a String object.\n * @param start The zero-based index number indicating the beginning of the substring.\n * @param end Zero-based index number indicating the end of the substring. The substring includes the characters up to, but not including, the character indicated by end.\n * If end is omitted, the characters from start through the end of the original string are returned.\n */\n substring(start: number, end?: number): string;\n\n /** Converts all the alphabetic characters in a string to lowercase. */\n toLowerCase(): string;\n\n /** Converts all alphabetic characters to lowercase, taking into account the host environment's current locale. */\n toLocaleLowerCase(): string;\n\n /** Converts all the alphabetic characters in a string to uppercase. */\n toUpperCase(): string;\n\n /** Returns a string where all alphabetic characters have been converted to uppercase, taking into account the host environment's current locale. */\n toLocaleUpperCase(): string;\n\n /** Removes the leading and trailing white space and line terminator characters from a string. */\n trim(): string;\n\n /** Returns the length of a String object. */\n readonly length: number;\n\n // IE extensions\n /**\n * Gets a substring beginning at the specified location and having the specified length.\n * @param from The starting position of the desired substring. The index of the first character in the string is zero.\n * @param length The number of characters to include in the returned substring.\n */\n substr(from: number, length?: number): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): string;\n\n readonly [index: number]: string;\n}\n\ninterface StringConstructor {\n new(value?: any): String;\n (value?: any): string;\n readonly prototype: String;\n fromCharCode(...codes: number[]): string;\n}\n\n/**\n * Allows manipulation and formatting of text strings and determination and location of substrings within strings.\n */\ndeclare const String: StringConstructor;\n\ninterface Boolean {\n /** Returns the primitive value of the specified object. */\n valueOf(): boolean;\n}\n\ninterface BooleanConstructor {\n new(value?: any): Boolean;\n (value?: any): boolean;\n readonly prototype: Boolean;\n}\n\ndeclare const Boolean: BooleanConstructor;\n\ninterface Number {\n /**\n * Returns a string representation of an object.\n * @param radix Specifies a radix for converting numeric values to strings. This value is only used for numbers.\n */\n toString(radix?: number): string;\n\n /**\n * Returns a string representing a number in fixed-point notation.\n * @param fractionDigits Number of digits after the decimal point. Must be in the range 0 - 20, inclusive.\n */\n toFixed(fractionDigits?: number): string;\n\n /**\n * Returns a string containing a number represented in exponential notation.\n * @param fractionDigits Number of digits after the decimal point. Must be in the range 0 - 20, inclusive.\n */\n toExponential(fractionDigits?: number): string;\n\n /**\n * Returns a string containing a number represented either in exponential or fixed-point notation with a specified number of digits.\n * @param precision Number of significant digits. Must be in the range 1 - 21, inclusive.\n */\n toPrecision(precision?: number): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): number;\n}\n\ninterface NumberConstructor {\n new(value?: any): Number;\n (value?: any): number;\n readonly prototype: Number;\n\n /** The largest number that can be represented in JavaScript. Equal to approximately 1.79E+308. */\n readonly MAX_VALUE: number;\n\n /** The closest number to zero that can be represented in JavaScript. Equal to approximately 5.00E-324. */\n readonly MIN_VALUE: number;\n\n /**\n * A value that is not a number.\n * In equality comparisons, NaN does not equal any value, including itself. To test whether a value is equivalent to NaN, use the isNaN function.\n */\n readonly NaN: number;\n\n /**\n * A value that is less than the largest negative number that can be represented in JavaScript.\n * JavaScript displays NEGATIVE_INFINITY values as -infinity.\n */\n readonly NEGATIVE_INFINITY: number;\n\n /**\n * A value greater than the largest number that can be represented in JavaScript.\n * JavaScript displays POSITIVE_INFINITY values as infinity.\n */\n readonly POSITIVE_INFINITY: number;\n}\n\n/** An object that represents a number of any kind. All JavaScript numbers are 64-bit floating-point numbers. */\ndeclare const Number: NumberConstructor;\n\ninterface TemplateStringsArray extends ReadonlyArray {\n readonly raw: ReadonlyArray;\n}\n\ninterface Math {\n /** The mathematical constant e. This is Euler's number, the base of natural logarithms. */\n readonly E: number;\n /** The natural logarithm of 10. */\n readonly LN10: number;\n /** The natural logarithm of 2. */\n readonly LN2: number;\n /** The base-2 logarithm of e. */\n readonly LOG2E: number;\n /** The base-10 logarithm of e. */\n readonly LOG10E: number;\n /** Pi. This is the ratio of the circumference of a circle to its diameter. */\n readonly PI: number;\n /** The square root of 0.5, or, equivalently, one divided by the square root of 2. */\n readonly SQRT1_2: number;\n /** The square root of 2. */\n readonly SQRT2: number;\n /**\n * Returns the absolute value of a number (the value without regard to whether it is positive or negative).\n * For example, the absolute value of -5 is the same as the absolute value of 5.\n * @param x A numeric expression for which the absolute value is needed.\n */\n abs(x: number): number;\n /**\n * Returns the arc cosine (or inverse cosine) of a number.\n * @param x A numeric expression.\n */\n acos(x: number): number;\n /**\n * Returns the arcsine of a number.\n * @param x A numeric expression.\n */\n asin(x: number): number;\n /**\n * Returns the arctangent of a number.\n * @param x A numeric expression for which the arctangent is needed.\n */\n atan(x: number): number;\n /**\n * Returns the angle (in radians) from the X axis to a point.\n * @param y A numeric expression representing the cartesian y-coordinate.\n * @param x A numeric expression representing the cartesian x-coordinate.\n */\n atan2(y: number, x: number): number;\n /**\n * Returns the smallest number greater than or equal to its numeric argument.\n * @param x A numeric expression.\n */\n ceil(x: number): number;\n /**\n * Returns the cosine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n cos(x: number): number;\n /**\n * Returns e (the base of natural logarithms) raised to a power.\n * @param x A numeric expression representing the power of e.\n */\n exp(x: number): number;\n /**\n * Returns the greatest number less than or equal to its numeric argument.\n * @param x A numeric expression.\n */\n floor(x: number): number;\n /**\n * Returns the natural logarithm (base e) of a number.\n * @param x A numeric expression.\n */\n log(x: number): number;\n /**\n * Returns the larger of a set of supplied numeric expressions.\n * @param values Numeric expressions to be evaluated.\n */\n max(...values: number[]): number;\n /**\n * Returns the smaller of a set of supplied numeric expressions.\n * @param values Numeric expressions to be evaluated.\n */\n min(...values: number[]): number;\n /**\n * Returns the value of a base expression taken to a specified power.\n * @param x The base value of the expression.\n * @param y The exponent value of the expression.\n */\n pow(x: number, y: number): number;\n /** Returns a pseudorandom number between 0 and 1. */\n random(): number;\n /**\n * Returns a supplied numeric expression rounded to the nearest number.\n * @param x The value to be rounded to the nearest number.\n */\n round(x: number): number;\n /**\n * Returns the sine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n sin(x: number): number;\n /**\n * Returns the square root of a number.\n * @param x A numeric expression.\n */\n sqrt(x: number): number;\n /**\n * Returns the tangent of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n tan(x: number): number;\n}\n/** An intrinsic object that provides basic mathematics functionality and constants. */\ndeclare const Math: Math;\n\n/** Enables basic storage and retrieval of dates and times. */\ninterface Date {\n /** Returns a string representation of a date. The format of the string depends on the locale. */\n toString(): string;\n /** Returns a date as a string value. */\n toDateString(): string;\n /** Returns a time as a string value. */\n toTimeString(): string;\n /** Returns a value as a string value appropriate to the host environment's current locale. */\n toLocaleString(): string;\n /** Returns a date as a string value appropriate to the host environment's current locale. */\n toLocaleDateString(): string;\n /** Returns a time as a string value appropriate to the host environment's current locale. */\n toLocaleTimeString(): string;\n /** Returns the stored time value in milliseconds since midnight, January 1, 1970 UTC. */\n valueOf(): number;\n /** Gets the time value in milliseconds. */\n getTime(): number;\n /** Gets the year, using local time. */\n getFullYear(): number;\n /** Gets the year using Universal Coordinated Time (UTC). */\n getUTCFullYear(): number;\n /** Gets the month, using local time. */\n getMonth(): number;\n /** Gets the month of a Date object using Universal Coordinated Time (UTC). */\n getUTCMonth(): number;\n /** Gets the day-of-the-month, using local time. */\n getDate(): number;\n /** Gets the day-of-the-month, using Universal Coordinated Time (UTC). */\n getUTCDate(): number;\n /** Gets the day of the week, using local time. */\n getDay(): number;\n /** Gets the day of the week using Universal Coordinated Time (UTC). */\n getUTCDay(): number;\n /** Gets the hours in a date, using local time. */\n getHours(): number;\n /** Gets the hours value in a Date object using Universal Coordinated Time (UTC). */\n getUTCHours(): number;\n /** Gets the minutes of a Date object, using local time. */\n getMinutes(): number;\n /** Gets the minutes of a Date object using Universal Coordinated Time (UTC). */\n getUTCMinutes(): number;\n /** Gets the seconds of a Date object, using local time. */\n getSeconds(): number;\n /** Gets the seconds of a Date object using Universal Coordinated Time (UTC). */\n getUTCSeconds(): number;\n /** Gets the milliseconds of a Date, using local time. */\n getMilliseconds(): number;\n /** Gets the milliseconds of a Date object using Universal Coordinated Time (UTC). */\n getUTCMilliseconds(): number;\n /** Gets the difference in minutes between the time on the local computer and Universal Coordinated Time (UTC). */\n getTimezoneOffset(): number;\n /**\n * Sets the date and time value in the Date object.\n * @param time A numeric value representing the number of elapsed milliseconds since midnight, January 1, 1970 GMT.\n */\n setTime(time: number): number;\n /**\n * Sets the milliseconds value in the Date object using local time.\n * @param ms A numeric value equal to the millisecond value.\n */\n setMilliseconds(ms: number): number;\n /**\n * Sets the milliseconds value in the Date object using Universal Coordinated Time (UTC).\n * @param ms A numeric value equal to the millisecond value.\n */\n setUTCMilliseconds(ms: number): number;\n\n /**\n * Sets the seconds value in the Date object using local time.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setSeconds(sec: number, ms?: number): number;\n /**\n * Sets the seconds value in the Date object using Universal Coordinated Time (UTC).\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setUTCSeconds(sec: number, ms?: number): number;\n /**\n * Sets the minutes value in the Date object using local time.\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setMinutes(min: number, sec?: number, ms?: number): number;\n /**\n * Sets the minutes value in the Date object using Universal Coordinated Time (UTC).\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setUTCMinutes(min: number, sec?: number, ms?: number): number;\n /**\n * Sets the hour value in the Date object using local time.\n * @param hours A numeric value equal to the hours value.\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setHours(hours: number, min?: number, sec?: number, ms?: number): number;\n /**\n * Sets the hours value in the Date object using Universal Coordinated Time (UTC).\n * @param hours A numeric value equal to the hours value.\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setUTCHours(hours: number, min?: number, sec?: number, ms?: number): number;\n /**\n * Sets the numeric day-of-the-month value of the Date object using local time.\n * @param date A numeric value equal to the day of the month.\n */\n setDate(date: number): number;\n /**\n * Sets the numeric day of the month in the Date object using Universal Coordinated Time (UTC).\n * @param date A numeric value equal to the day of the month.\n */\n setUTCDate(date: number): number;\n /**\n * Sets the month value in the Date object using local time.\n * @param month A numeric value equal to the month. The value for January is 0, and other month values follow consecutively.\n * @param date A numeric value representing the day of the month. If this value is not supplied, the value from a call to the getDate method is used.\n */\n setMonth(month: number, date?: number): number;\n /**\n * Sets the month value in the Date object using Universal Coordinated Time (UTC).\n * @param month A numeric value equal to the month. The value for January is 0, and other month values follow consecutively.\n * @param date A numeric value representing the day of the month. If it is not supplied, the value from a call to the getUTCDate method is used.\n */\n setUTCMonth(month: number, date?: number): number;\n /**\n * Sets the year of the Date object using local time.\n * @param year A numeric value for the year.\n * @param month A zero-based numeric value for the month (0 for January, 11 for December). Must be specified if numDate is specified.\n * @param date A numeric value equal for the day of the month.\n */\n setFullYear(year: number, month?: number, date?: number): number;\n /**\n * Sets the year value in the Date object using Universal Coordinated Time (UTC).\n * @param year A numeric value equal to the year.\n * @param month A numeric value equal to the month. The value for January is 0, and other month values follow consecutively. Must be supplied if numDate is supplied.\n * @param date A numeric value equal to the day of the month.\n */\n setUTCFullYear(year: number, month?: number, date?: number): number;\n /** Returns a date converted to a string using Universal Coordinated Time (UTC). */\n toUTCString(): string;\n /** Returns a date as a string value in ISO format. */\n toISOString(): string;\n /** Used by the JSON.stringify method to enable the transformation of an object's data for JavaScript Object Notation (JSON) serialization. */\n toJSON(key?: any): string;\n}\n\ninterface DateConstructor {\n new(): Date;\n new(value: number): Date;\n new(value: string): Date;\n new(year: number, month: number, date?: number, hours?: number, minutes?: number, seconds?: number, ms?: number): Date;\n (): string;\n readonly prototype: Date;\n /**\n * Parses a string containing a date, and returns the number of milliseconds between that date and midnight, January 1, 1970.\n * @param s A date string\n */\n parse(s: string): number;\n /**\n * Returns the number of milliseconds between midnight, January 1, 1970 Universal Coordinated Time (UTC) (or GMT) and the specified date.\n * @param year The full year designation is required for cross-century date accuracy. If year is between 0 and 99 is used, then year is assumed to be 1900 + year.\n * @param month The month as an number between 0 and 11 (January to December).\n * @param date The date as an number between 1 and 31.\n * @param hours Must be supplied if minutes is supplied. An number from 0 to 23 (midnight to 11pm) that specifies the hour.\n * @param minutes Must be supplied if seconds is supplied. An number from 0 to 59 that specifies the minutes.\n * @param seconds Must be supplied if milliseconds is supplied. An number from 0 to 59 that specifies the seconds.\n * @param ms An number from 0 to 999 that specifies the milliseconds.\n */\n UTC(year: number, month: number, date?: number, hours?: number, minutes?: number, seconds?: number, ms?: number): number;\n now(): number;\n}\n\ndeclare const Date: DateConstructor;\n\ninterface RegExpMatchArray extends Array {\n index?: number;\n input?: string;\n}\n\ninterface RegExpExecArray extends Array {\n index: number;\n input: string;\n}\n\ninterface RegExp {\n /**\n * Executes a search on a string using a regular expression pattern, and returns an array containing the results of that search.\n * @param string The String object or string literal on which to perform the search.\n */\n exec(string: string): RegExpExecArray | null;\n\n /**\n * Returns a Boolean value that indicates whether or not a pattern exists in a searched string.\n * @param string String on which to perform the search.\n */\n test(string: string): boolean;\n\n /** Returns a copy of the text of the regular expression pattern. Read-only. The regExp argument is a Regular expression object. It can be a variable name or a literal. */\n readonly source: string;\n\n /** Returns a Boolean value indicating the state of the global flag (g) used with a regular expression. Default is false. Read-only. */\n readonly global: boolean;\n\n /** Returns a Boolean value indicating the state of the ignoreCase flag (i) used with a regular expression. Default is false. Read-only. */\n readonly ignoreCase: boolean;\n\n /** Returns a Boolean value indicating the state of the multiline flag (m) used with a regular expression. Default is false. Read-only. */\n readonly multiline: boolean;\n\n lastIndex: number;\n\n // Non-standard extensions\n compile(): this;\n}\n\ninterface RegExpConstructor {\n new(pattern: RegExp | string): RegExp;\n new(pattern: string, flags?: string): RegExp;\n (pattern: RegExp | string): RegExp;\n (pattern: string, flags?: string): RegExp;\n readonly prototype: RegExp;\n\n // Non-standard extensions\n $1: string;\n $2: string;\n $3: string;\n $4: string;\n $5: string;\n $6: string;\n $7: string;\n $8: string;\n $9: string;\n lastMatch: string;\n}\n\ndeclare const RegExp: RegExpConstructor;\n\ninterface Error {\n name: string;\n message: string;\n stack?: string;\n}\n\ninterface ErrorConstructor {\n new(message?: string): Error;\n (message?: string): Error;\n readonly prototype: Error;\n}\n\ndeclare const Error: ErrorConstructor;\n\ninterface EvalError extends Error {\n}\n\ninterface EvalErrorConstructor {\n new(message?: string): EvalError;\n (message?: string): EvalError;\n readonly prototype: EvalError;\n}\n\ndeclare const EvalError: EvalErrorConstructor;\n\ninterface RangeError extends Error {\n}\n\ninterface RangeErrorConstructor {\n new(message?: string): RangeError;\n (message?: string): RangeError;\n readonly prototype: RangeError;\n}\n\ndeclare const RangeError: RangeErrorConstructor;\n\ninterface ReferenceError extends Error {\n}\n\ninterface ReferenceErrorConstructor {\n new(message?: string): ReferenceError;\n (message?: string): ReferenceError;\n readonly prototype: ReferenceError;\n}\n\ndeclare const ReferenceError: ReferenceErrorConstructor;\n\ninterface SyntaxError extends Error {\n}\n\ninterface SyntaxErrorConstructor {\n new(message?: string): SyntaxError;\n (message?: string): SyntaxError;\n readonly prototype: SyntaxError;\n}\n\ndeclare const SyntaxError: SyntaxErrorConstructor;\n\ninterface TypeError extends Error {\n}\n\ninterface TypeErrorConstructor {\n new(message?: string): TypeError;\n (message?: string): TypeError;\n readonly prototype: TypeError;\n}\n\ndeclare const TypeError: TypeErrorConstructor;\n\ninterface URIError extends Error {\n}\n\ninterface URIErrorConstructor {\n new(message?: string): URIError;\n (message?: string): URIError;\n readonly prototype: URIError;\n}\n\ndeclare const URIError: URIErrorConstructor;\n\ninterface JSON {\n /**\n * Converts a JavaScript Object Notation (JSON) string into an object.\n * @param text A valid JSON string.\n * @param reviver A function that transforms the results. This function is called for each member of the object.\n * If a member contains nested objects, the nested objects are transformed before the parent object is.\n */\n parse(text: string, reviver?: (key: any, value: any) => any): any;\n /**\n * Converts a JavaScript value to a JavaScript Object Notation (JSON) string.\n * @param value A JavaScript value, usually an object or array, to be converted.\n * @param replacer A function that transforms the results.\n * @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.\n */\n stringify(value: any, replacer?: (key: string, value: any) => any, space?: string | number): string;\n /**\n * Converts a JavaScript value to a JavaScript Object Notation (JSON) string.\n * @param value A JavaScript value, usually an object or array, to be converted.\n * @param replacer An array of strings and numbers that acts as a approved list for selecting the object properties that will be stringified.\n * @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.\n */\n stringify(value: any, replacer?: (number | string)[] | null, space?: string | number): string;\n}\n\n/**\n * An intrinsic object that provides functions to convert JavaScript values to and from the JavaScript Object Notation (JSON) format.\n */\ndeclare const JSON: JSON;\n\n\n/////////////////////////////\n/// ECMAScript Array API (specially handled by compiler)\n/////////////////////////////\n\ninterface ReadonlyArray {\n /**\n * Gets the length of the array. This is a number one higher than the highest element defined in an array.\n */\n readonly length: number;\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n /**\n * Returns a string representation of an array. The elements are converted to string using thier toLocalString methods.\n */\n toLocaleString(): string;\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: T[][]): T[];\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: (T | T[])[]): T[];\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): T[];\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.\n */\n indexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Returns the index of the last occurrence of a specified value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at the last index in the array.\n */\n lastIndexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls the callbackfn function for each element in array1 until the callbackfn returns false, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: T, index: number, array: ReadonlyArray) => boolean, thisArg?: any): boolean;\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the callbackfn function for each element in array1 until the callbackfn returns true, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: T, index: number, array: ReadonlyArray) => boolean, thisArg?: any): boolean;\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: T, index: number, array: ReadonlyArray) => void, thisArg?: any): void;\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (value: T, index: number, array: ReadonlyArray) => U, thisArg?: any): U[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: T, index: number, array: ReadonlyArray) => value is S, thisArg?: any): S[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: T, index: number, array: ReadonlyArray) => any, thisArg?: any): T[];\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: ReadonlyArray) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: ReadonlyArray) => U, initialValue: U): U;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: ReadonlyArray) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: ReadonlyArray) => U, initialValue: U): U;\n\n readonly [n: number]: T;\n}\n\ninterface Array {\n /**\n * Gets or sets the length of the array. This is a number one higher than the highest element defined in an array.\n */\n length: number;\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n /**\n * Returns a string representation of an array. The elements are converted to string using thier toLocalString methods.\n */\n toLocaleString(): string;\n /**\n * Appends new elements to an array, and returns the new length of the array.\n * @param items New elements of the Array.\n */\n push(...items: T[]): number;\n /**\n * Removes the last element from an array and returns it.\n */\n pop(): T | undefined;\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: T[][]): T[];\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: (T | T[])[]): T[];\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n /**\n * Reverses the elements in an Array.\n */\n reverse(): T[];\n /**\n * Removes the first element from an array and returns it.\n */\n shift(): T | undefined;\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): T[];\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: T, b: T) => number): this;\n /**\n * Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.\n * @param start The zero-based location in the array from which to start removing elements.\n * @param deleteCount The number of elements to remove.\n */\n splice(start: number, deleteCount?: number): T[];\n /**\n * Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.\n * @param start The zero-based location in the array from which to start removing elements.\n * @param deleteCount The number of elements to remove.\n * @param items Elements to insert into the array in place of the deleted elements.\n */\n splice(start: number, deleteCount: number, ...items: T[]): T[];\n /**\n * Inserts new elements at the start of an array.\n * @param items Elements to insert at the start of the Array.\n */\n unshift(...items: T[]): number;\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.\n */\n indexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Returns the index of the last occurrence of a specified value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at the last index in the array.\n */\n lastIndexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls the callbackfn function for each element in array1 until the callbackfn returns false, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: T, index: number, array: T[]) => boolean, thisArg?: any): boolean;\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the callbackfn function for each element in array1 until the callbackfn returns true, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: T, index: number, array: T[]) => boolean, thisArg?: any): boolean;\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: T, index: number, array: T[]) => void, thisArg?: any): void;\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (value: T, index: number, array: T[]) => U, thisArg?: any): U[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: T, index: number, array: T[]) => value is S, thisArg?: any): S[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: T, index: number, array: T[]) => any, thisArg?: any): T[];\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: T[]) => U, initialValue: U): U;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: T[]) => U, initialValue: U): U;\n\n [n: number]: T;\n}\n\ninterface ArrayConstructor {\n new(arrayLength?: number): any[];\n new (arrayLength: number): T[];\n new (...items: T[]): T[];\n (arrayLength?: number): any[];\n (arrayLength: number): T[];\n (...items: T[]): T[];\n isArray(arg: any): arg is Array;\n readonly prototype: Array;\n}\n\ndeclare const Array: ArrayConstructor;\n\ninterface TypedPropertyDescriptor {\n enumerable?: boolean;\n configurable?: boolean;\n writable?: boolean;\n value?: T;\n get?: () => T;\n set?: (value: T) => void;\n}\n\ndeclare type ClassDecorator = (target: TFunction) => TFunction | void;\ndeclare type PropertyDecorator = (target: Object, propertyKey: string | symbol) => void;\ndeclare type MethodDecorator = (target: Object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor) => TypedPropertyDescriptor | void;\ndeclare type ParameterDecorator = (target: Object, propertyKey: string | symbol, parameterIndex: number) => void;\n\ndeclare type PromiseConstructorLike = new (executor: (resolve: (value?: T | PromiseLike) => void, reject: (reason?: any) => void) => void) => PromiseLike;\n\ninterface PromiseLike {\n /**\n * Attaches callbacks for the resolution and/or rejection of the Promise.\n * @param onfulfilled The callback to execute when the Promise is resolved.\n * @param onrejected The callback to execute when the Promise is rejected.\n * @returns A Promise for the completion of which ever callback is executed.\n */\n then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): PromiseLike;\n}\n\n/**\n * Represents the completion of an asynchronous operation\n */\ninterface Promise {\n /**\n * Attaches callbacks for the resolution and/or rejection of the Promise.\n * @param onfulfilled The callback to execute when the Promise is resolved.\n * @param onrejected The callback to execute when the Promise is rejected.\n * @returns A Promise for the completion of which ever callback is executed.\n */\n then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): Promise;\n\n /**\n * Attaches a callback for only the rejection of the Promise.\n * @param onrejected The callback to execute when the Promise is rejected.\n * @returns A Promise for the completion of the callback.\n */\n catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): Promise;\n}\n\ninterface ArrayLike {\n readonly length: number;\n readonly [n: number]: T;\n}\n\n/**\n * Make all properties in T optional\n */\ntype Partial = {\n [P in keyof T]?: T[P];\n};\n\n/**\n * Make all properties in T readonly\n */\ntype Readonly = {\n readonly [P in keyof T]: T[P];\n};\n\n/**\n * From T pick a set of properties K\n */\ntype Pick = {\n [P in K]: T[P];\n};\n\n/**\n * Construct a type with a set of properties K of type T\n */\ntype Record = {\n [P in K]: T;\n};\n\n/**\n * Marker for contextual 'this' type\n */\ninterface ThisType { }\n\n/**\n * Represents a raw buffer of binary data, which is used to store data for the\n * different typed arrays. ArrayBuffers cannot be read from or written to directly,\n * but can be passed to a typed array or DataView Object to interpret the raw\n * buffer as needed.\n */\ninterface ArrayBuffer {\n /**\n * Read-only. The length of the ArrayBuffer (in bytes).\n */\n readonly byteLength: number;\n\n /**\n * Returns a section of an ArrayBuffer.\n */\n slice(begin: number, end?: number): ArrayBuffer;\n}\n\n/**\n * Allowed ArrayBuffer types for the buffer of an ArrayBufferView and related Typed Arrays.\n */\ninterface ArrayBufferTypes {\n ArrayBuffer: ArrayBuffer;\n}\ntype ArrayBufferLike = ArrayBufferTypes[keyof ArrayBufferTypes];\n\ninterface ArrayBufferConstructor {\n readonly prototype: ArrayBuffer;\n new(byteLength: number): ArrayBuffer;\n isView(arg: any): arg is ArrayBufferView;\n}\ndeclare const ArrayBuffer: ArrayBufferConstructor;\n\ninterface ArrayBufferView {\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n byteOffset: number;\n}\n\ninterface DataView {\n readonly buffer: ArrayBuffer;\n readonly byteLength: number;\n readonly byteOffset: number;\n /**\n * Gets the Float32 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getFloat32(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Float64 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getFloat64(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Int8 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getInt8(byteOffset: number): number;\n\n /**\n * Gets the Int16 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getInt16(byteOffset: number, littleEndian?: boolean): number;\n /**\n * Gets the Int32 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getInt32(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Uint8 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getUint8(byteOffset: number): number;\n\n /**\n * Gets the Uint16 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getUint16(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Uint32 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getUint32(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Stores an Float32 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setFloat32(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Float64 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setFloat64(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Int8 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n */\n setInt8(byteOffset: number, value: number): void;\n\n /**\n * Stores an Int16 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setInt16(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Int32 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setInt32(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Uint8 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n */\n setUint8(byteOffset: number, value: number): void;\n\n /**\n * Stores an Uint16 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setUint16(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Uint32 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setUint32(byteOffset: number, value: number, littleEndian?: boolean): void;\n}\n\ninterface DataViewConstructor {\n new(buffer: ArrayBufferLike, byteOffset?: number, byteLength?: number): DataView;\n}\ndeclare const DataView: DataViewConstructor;\n\n/**\n * A typed array of 8-bit integer values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Int8Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Int8Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Int8Array) => any, thisArg?: any): Int8Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Int8Array) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Int8Array) => number, thisArg?: any): Int8Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int8Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int8Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Int8Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Int8Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Int8Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Int8Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Int8Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\ninterface Int8ArrayConstructor {\n readonly prototype: Int8Array;\n new(length: number): Int8Array;\n new(array: ArrayLike): Int8Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Int8Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Int8Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Int8Array;\n\n\n}\ndeclare const Int8Array: Int8ArrayConstructor;\n\n/**\n * A typed array of 8-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Uint8Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Uint8Array) => any, thisArg?: any): Uint8Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Uint8Array) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => number, thisArg?: any): Uint8Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint8Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint8Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Uint8Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint8Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint8Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint8ArrayConstructor {\n readonly prototype: Uint8Array;\n new(length: number): Uint8Array;\n new(array: ArrayLike): Uint8Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Uint8Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint8Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Uint8Array;\n\n}\ndeclare const Uint8Array: Uint8ArrayConstructor;\n\n/**\n * A typed array of 8-bit unsigned integer (clamped) values. The contents are initialized to 0.\n * If the requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8ClampedArray {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Uint8ClampedArray) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Uint8ClampedArray) => any, thisArg?: any): Uint8ClampedArray;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Uint8ClampedArray) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => number, thisArg?: any): Uint8ClampedArray;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint8ClampedArray;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint8ClampedArray;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Uint8ClampedArray) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint8ClampedArray view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint8ClampedArray;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint8ClampedArrayConstructor {\n readonly prototype: Uint8ClampedArray;\n new(length: number): Uint8ClampedArray;\n new(array: ArrayLike): Uint8ClampedArray;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Uint8ClampedArray;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint8ClampedArray;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Uint8ClampedArray;\n}\ndeclare const Uint8ClampedArray: Uint8ClampedArrayConstructor;\n\n/**\n * A typed array of 16-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int16Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Int16Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Int16Array) => any, thisArg?: any): Int16Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Int16Array) => void, thisArg?: any): void;\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Int16Array) => number, thisArg?: any): Int16Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int16Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int16Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Int16Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Int16Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Int16Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Int16Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Int16Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Int16ArrayConstructor {\n readonly prototype: Int16Array;\n new(length: number): Int16Array;\n new(array: ArrayLike): Int16Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Int16Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Int16Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Int16Array;\n\n\n}\ndeclare const Int16Array: Int16ArrayConstructor;\n\n/**\n * A typed array of 16-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint16Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Uint16Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Uint16Array) => any, thisArg?: any): Uint16Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Uint16Array) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => number, thisArg?: any): Uint16Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint16Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint16Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint16Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint16Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Uint16Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint16Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint16Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint16ArrayConstructor {\n readonly prototype: Uint16Array;\n new(length: number): Uint16Array;\n new(array: ArrayLike): Uint16Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Uint16Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint16Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Uint16Array;\n\n\n}\ndeclare const Uint16Array: Uint16ArrayConstructor;\n/**\n * A typed array of 32-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int32Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Int32Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Int32Array) => any, thisArg?: any): Int32Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Int32Array) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (value: number, index: number, array: Int32Array) => number, thisArg?: any): Int32Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int32Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int32Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Int32Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Int32Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Int32Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Int32Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Int32Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Int32ArrayConstructor {\n readonly prototype: Int32Array;\n new(length: number): Int32Array;\n new(array: ArrayLike): Int32Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Int32Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Int32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Int32Array;\n\n}\ndeclare const Int32Array: Int32ArrayConstructor;\n\n/**\n * A typed array of 32-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint32Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Uint32Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Uint32Array) => any, thisArg?: any): Uint32Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Uint32Array) => void, thisArg?: any): void;\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => number, thisArg?: any): Uint32Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint32Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint32Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint32Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint32Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Uint32Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint32Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint32Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint32ArrayConstructor {\n readonly prototype: Uint32Array;\n new(length: number): Uint32Array;\n new(array: ArrayLike): Uint32Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Uint32Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Uint32Array;\n\n}\ndeclare const Uint32Array: Uint32ArrayConstructor;\n\n/**\n * A typed array of 32-bit float values. The contents are initialized to 0. If the requested number\n * of bytes could not be allocated an exception is raised.\n */\ninterface Float32Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Float32Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Float32Array) => any, thisArg?: any): Float32Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Float32Array) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Float32Array) => number, thisArg?: any): Float32Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float32Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float32Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Float32Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Float32Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Float32Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Float32Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Float32Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Float32ArrayConstructor {\n readonly prototype: Float32Array;\n new(length: number): Float32Array;\n new(array: ArrayLike): Float32Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Float32Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Float32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Float32Array;\n\n\n}\ndeclare const Float32Array: Float32ArrayConstructor;\n\n/**\n * A typed array of 64-bit float values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Float64Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Float64Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Float64Array) => any, thisArg?: any): Float64Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Float64Array) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Float64Array) => number, thisArg?: any): Float64Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float64Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float64Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float64Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float64Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Float64Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Float64Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Float64Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Float64Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Float64Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Float64ArrayConstructor {\n readonly prototype: Float64Array;\n new(length: number): Float64Array;\n new(array: ArrayLike): Float64Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Float64Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Float64Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Float64Array;\n\n}\ndeclare const Float64Array: Float64ArrayConstructor;\n\n/////////////////////////////\n/// ECMAScript Internationalization API\n/////////////////////////////\n\ndeclare namespace Intl {\n interface CollatorOptions {\n usage?: string;\n localeMatcher?: string;\n numeric?: boolean;\n caseFirst?: string;\n sensitivity?: string;\n ignorePunctuation?: boolean;\n }\n\n interface ResolvedCollatorOptions {\n locale: string;\n usage: string;\n sensitivity: string;\n ignorePunctuation: boolean;\n collation: string;\n caseFirst: string;\n numeric: boolean;\n }\n\n interface Collator {\n compare(x: string, y: string): number;\n resolvedOptions(): ResolvedCollatorOptions;\n }\n var Collator: {\n new(locales?: string | string[], options?: CollatorOptions): Collator;\n (locales?: string | string[], options?: CollatorOptions): Collator;\n supportedLocalesOf(locales: string | string[], options?: CollatorOptions): string[];\n };\n\n interface NumberFormatOptions {\n localeMatcher?: string;\n style?: string;\n currency?: string;\n currencyDisplay?: string;\n useGrouping?: boolean;\n minimumIntegerDigits?: number;\n minimumFractionDigits?: number;\n maximumFractionDigits?: number;\n minimumSignificantDigits?: number;\n maximumSignificantDigits?: number;\n }\n\n interface ResolvedNumberFormatOptions {\n locale: string;\n numberingSystem: string;\n style: string;\n currency?: string;\n currencyDisplay?: string;\n minimumIntegerDigits: number;\n minimumFractionDigits: number;\n maximumFractionDigits: number;\n minimumSignificantDigits?: number;\n maximumSignificantDigits?: number;\n useGrouping: boolean;\n }\n\n interface NumberFormat {\n format(value: number): string;\n resolvedOptions(): ResolvedNumberFormatOptions;\n }\n var NumberFormat: {\n new(locales?: string | string[], options?: NumberFormatOptions): NumberFormat;\n (locales?: string | string[], options?: NumberFormatOptions): NumberFormat;\n supportedLocalesOf(locales: string | string[], options?: NumberFormatOptions): string[];\n };\n\n interface DateTimeFormatOptions {\n localeMatcher?: string;\n weekday?: string;\n era?: string;\n year?: string;\n month?: string;\n day?: string;\n hour?: string;\n minute?: string;\n second?: string;\n timeZoneName?: string;\n formatMatcher?: string;\n hour12?: boolean;\n timeZone?: string;\n }\n\n interface ResolvedDateTimeFormatOptions {\n locale: string;\n calendar: string;\n numberingSystem: string;\n timeZone: string;\n hour12?: boolean;\n weekday?: string;\n era?: string;\n year?: string;\n month?: string;\n day?: string;\n hour?: string;\n minute?: string;\n second?: string;\n timeZoneName?: string;\n }\n\n interface DateTimeFormat {\n format(date?: Date | number): string;\n resolvedOptions(): ResolvedDateTimeFormatOptions;\n }\n var DateTimeFormat: {\n new(locales?: string | string[], options?: DateTimeFormatOptions): DateTimeFormat;\n (locales?: string | string[], options?: DateTimeFormatOptions): DateTimeFormat;\n supportedLocalesOf(locales: string | string[], options?: DateTimeFormatOptions): string[];\n };\n}\n\ninterface String {\n /**\n * Determines whether two strings are equivalent in the current or specified locale.\n * @param that String to compare to target string\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used. This parameter must conform to BCP 47 standards; see the Intl.Collator object for details.\n * @param options An object that contains one or more properties that specify comparison options. see the Intl.Collator object for details.\n */\n localeCompare(that: string, locales?: string | string[], options?: Intl.CollatorOptions): number;\n}\n\ninterface Number {\n /**\n * Converts a number to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleString(locales?: string | string[], options?: Intl.NumberFormatOptions): string;\n}\n\ninterface Date {\n /**\n * Converts a date and time to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleString(locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;\n /**\n * Converts a date to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleDateString(locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;\n\n /**\n * Converts a time to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleTimeString(locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;\n}\n\n\ndeclare type PropertyKey = string | number | symbol;\n\ninterface Array {\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: T, index: number, obj: Array) => boolean): T | undefined;\n find(predicate: (this: void, value: T, index: number, obj: Array) => boolean, thisArg: undefined): T | undefined;\n find(predicate: (this: Z, value: T, index: number, obj: Array) => boolean, thisArg: Z): T | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: T, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: T, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: T, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: T, start?: number, end?: number): this;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n}\n\ninterface ArrayConstructor {\n /**\n * Creates an array from an array-like object.\n * @param arrayLike An array-like object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: T, k: number) => U): Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: T, k: number) => U, thisArg: undefined): Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: T, k: number) => U, thisArg: Z): Array;\n\n\n /**\n * Creates an array from an array-like object.\n * @param arrayLike An array-like object to convert to an array.\n */\n from(arrayLike: ArrayLike): Array;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: T[]): Array;\n}\n\ninterface DateConstructor {\n new (value: Date): Date;\n}\n\ninterface Function {\n /**\n * Returns the name of the function. Function names are read-only and can not be changed.\n */\n readonly name: string;\n}\n\ninterface Math {\n /**\n * Returns the number of leading zero bits in the 32-bit binary representation of a number.\n * @param x A numeric expression.\n */\n clz32(x: number): number;\n\n /**\n * Returns the result of 32-bit multiplication of two numbers.\n * @param x First number\n * @param y Second number\n */\n imul(x: number, y: number): number;\n\n /**\n * Returns the sign of the x, indicating whether x is positive, negative or zero.\n * @param x The numeric expression to test\n */\n sign(x: number): number;\n\n /**\n * Returns the base 10 logarithm of a number.\n * @param x A numeric expression.\n */\n log10(x: number): number;\n\n /**\n * Returns the base 2 logarithm of a number.\n * @param x A numeric expression.\n */\n log2(x: number): number;\n\n /**\n * Returns the natural logarithm of 1 + x.\n * @param x A numeric expression.\n */\n log1p(x: number): number;\n\n /**\n * Returns the result of (e^x - 1) of x (e raised to the power of x, where e is the base of\n * the natural logarithms).\n * @param x A numeric expression.\n */\n expm1(x: number): number;\n\n /**\n * Returns the hyperbolic cosine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n cosh(x: number): number;\n\n /**\n * Returns the hyperbolic sine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n sinh(x: number): number;\n\n /**\n * Returns the hyperbolic tangent of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n tanh(x: number): number;\n\n /**\n * Returns the inverse hyperbolic cosine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n acosh(x: number): number;\n\n /**\n * Returns the inverse hyperbolic sine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n asinh(x: number): number;\n\n /**\n * Returns the inverse hyperbolic tangent of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n atanh(x: number): number;\n\n /**\n * Returns the square root of the sum of squares of its arguments.\n * @param values Values to compute the square root for.\n * If no arguments are passed, the result is +0.\n * If there is only one argument, the result is the absolute value.\n * If any argument is +Infinity or -Infinity, the result is +Infinity.\n * If any argument is NaN, the result is NaN.\n * If all arguments are either +0 or −0, the result is +0.\n */\n hypot(...values: number[] ): number;\n\n /**\n * Returns the integral part of the a numeric expression, x, removing any fractional digits.\n * If x is already an integer, the result is x.\n * @param x A numeric expression.\n */\n trunc(x: number): number;\n\n /**\n * Returns the nearest single precision float representation of a number.\n * @param x A numeric expression.\n */\n fround(x: number): number;\n\n /**\n * Returns an implementation-dependent approximation to the cube root of number.\n * @param x A numeric expression.\n */\n cbrt(x: number): number;\n}\n\ninterface NumberConstructor {\n /**\n * The value of Number.EPSILON is the difference between 1 and the smallest value greater than 1\n * that is representable as a Number value, which is approximately:\n * 2.2204460492503130808472633361816 x 10‍−‍16.\n */\n readonly EPSILON: number;\n\n /**\n * Returns true if passed value is finite.\n * Unlike the global isFinite, Number.isFinite doesn't forcibly convert the parameter to a\n * number. Only finite values of the type number, result in true.\n * @param number A numeric value.\n */\n isFinite(number: number): boolean;\n\n /**\n * Returns true if the value passed is an integer, false otherwise.\n * @param number A numeric value.\n */\n isInteger(number: number): boolean;\n\n /**\n * Returns a Boolean value that indicates whether a value is the reserved value NaN (not a\n * number). Unlike the global isNaN(), Number.isNaN() doesn't forcefully convert the parameter\n * to a number. Only values of the type number, that are also NaN, result in true.\n * @param number A numeric value.\n */\n isNaN(number: number): boolean;\n\n /**\n * Returns true if the value passed is a safe integer.\n * @param number A numeric value.\n */\n isSafeInteger(number: number): boolean;\n\n /**\n * The value of the largest integer n such that n and n + 1 are both exactly representable as\n * a Number value.\n * The value of Number.MAX_SAFE_INTEGER is 9007199254740991 2^53 − 1.\n */\n readonly MAX_SAFE_INTEGER: number;\n\n /**\n * The value of the smallest integer n such that n and n − 1 are both exactly representable as\n * a Number value.\n * The value of Number.MIN_SAFE_INTEGER is −9007199254740991 (−(2^53 − 1)).\n */\n readonly MIN_SAFE_INTEGER: number;\n\n /**\n * Converts a string to a floating-point number.\n * @param string A string that contains a floating-point number.\n */\n parseFloat(string: string): number;\n\n /**\n * Converts A string to an integer.\n * @param s A string to convert into a number.\n * @param radix A value between 2 and 36 that specifies the base of the number in numString.\n * If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\n * All other strings are considered decimal.\n */\n parseInt(string: string, radix?: number): number;\n}\n\ninterface Object {\n /**\n * Determines whether an object has a property with the specified name.\n * @param v A property name.\n */\n hasOwnProperty(v: PropertyKey): boolean;\n\n /**\n * Determines whether a specified property is enumerable.\n * @param v A property name.\n */\n propertyIsEnumerable(v: PropertyKey): boolean;\n}\n\ninterface ObjectConstructor {\n /**\n * Copy the values of all of the enumerable own properties from one or more source objects to a\n * target object. Returns the target object.\n * @param target The target object to copy to.\n * @param source The source object from which to copy properties.\n */\n assign(target: T, source: U): T & U;\n\n /**\n * Copy the values of all of the enumerable own properties from one or more source objects to a\n * target object. Returns the target object.\n * @param target The target object to copy to.\n * @param source1 The first source object from which to copy properties.\n * @param source2 The second source object from which to copy properties.\n */\n assign(target: T, source1: U, source2: V): T & U & V;\n\n /**\n * Copy the values of all of the enumerable own properties from one or more source objects to a\n * target object. Returns the target object.\n * @param target The target object to copy to.\n * @param source1 The first source object from which to copy properties.\n * @param source2 The second source object from which to copy properties.\n * @param source3 The third source object from which to copy properties.\n */\n assign(target: T, source1: U, source2: V, source3: W): T & U & V & W;\n\n /**\n * Copy the values of all of the enumerable own properties from one or more source objects to a\n * target object. Returns the target object.\n * @param target The target object to copy to.\n * @param sources One or more source objects from which to copy properties\n */\n assign(target: object, ...sources: any[]): any;\n\n /**\n * Returns an array of all symbol properties found directly on object o.\n * @param o Object to retrieve the symbols from.\n */\n getOwnPropertySymbols(o: any): symbol[];\n\n /**\n * Returns true if the values are the same value, false otherwise.\n * @param value1 The first value.\n * @param value2 The second value.\n */\n is(value1: any, value2: any): boolean;\n\n /**\n * Sets the prototype of a specified object o to object proto or null. Returns the object o.\n * @param o The object to change its prototype.\n * @param proto The value of the new prototype or null.\n */\n setPrototypeOf(o: any, proto: object | null): any;\n\n /**\n * Gets the own property descriptor of the specified object.\n * An own property descriptor is one that is defined directly on the object and is not\n * inherited from the object's prototype.\n * @param o Object that contains the property.\n * @param p Name of the property.\n */\n getOwnPropertyDescriptor(o: any, propertyKey: PropertyKey): PropertyDescriptor;\n\n /**\n * Adds a property to an object, or modifies attributes of an existing property.\n * @param o Object on which to add or modify the property. This can be a native JavaScript\n * object (that is, a user-defined object or a built in object) or a DOM object.\n * @param p The property name.\n * @param attributes Descriptor for the property. It can be for a data property or an accessor\n * property.\n */\n defineProperty(o: any, propertyKey: PropertyKey, attributes: PropertyDescriptor): any;\n}\n\ninterface ReadonlyArray {\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: T, index: number, obj: ReadonlyArray) => boolean): T | undefined;\n find(predicate: (this: void, value: T, index: number, obj: ReadonlyArray) => boolean, thisArg: undefined): T | undefined;\n find(predicate: (this: Z, value: T, index: number, obj: ReadonlyArray) => boolean, thisArg: Z): T | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: T, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: T, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: T, index: number, obj: Array) => boolean, thisArg: Z): number;\n}\n\ninterface RegExp {\n /**\n * Returns a string indicating the flags of the regular expression in question. This field is read-only.\n * The characters in this string are sequenced and concatenated in the following order:\n *\n * - \"g\" for global\n * - \"i\" for ignoreCase\n * - \"m\" for multiline\n * - \"u\" for unicode\n * - \"y\" for sticky\n *\n * If no flags are set, the value is the empty string.\n */\n readonly flags: string;\n\n /**\n * Returns a Boolean value indicating the state of the sticky flag (y) used with a regular\n * expression. Default is false. Read-only.\n */\n readonly sticky: boolean;\n\n /**\n * Returns a Boolean value indicating the state of the Unicode flag (u) used with a regular\n * expression. Default is false. Read-only.\n */\n readonly unicode: boolean;\n}\n\ninterface RegExpConstructor {\n new (pattern: RegExp, flags?: string): RegExp;\n (pattern: RegExp, flags?: string): RegExp;\n}\n\ninterface String {\n /**\n * Returns a nonnegative integer Number less than 1114112 (0x110000) that is the code point\n * value of the UTF-16 encoded code point starting at the string element at position pos in\n * the String resulting from converting this object to a String.\n * If there is no element at that position, the result is undefined.\n * If a valid UTF-16 surrogate pair does not begin at pos, the result is the code unit at pos.\n */\n codePointAt(pos: number): number | undefined;\n\n /**\n * Returns true if searchString appears as a substring of the result of converting this\n * object to a String, at one or more positions that are\n * greater than or equal to position; otherwise, returns false.\n * @param searchString search string\n * @param position If position is undefined, 0 is assumed, so as to search all of the String.\n */\n includes(searchString: string, position?: number): boolean;\n\n /**\n * Returns true if the sequence of elements of searchString converted to a String is the\n * same as the corresponding elements of this object (converted to a String) starting at\n * endPosition – length(this). Otherwise returns false.\n */\n endsWith(searchString: string, endPosition?: number): boolean;\n\n /**\n * Returns the String value result of normalizing the string into the normalization form\n * named by form as specified in Unicode Standard Annex #15, Unicode Normalization Forms.\n * @param form Applicable values: \"NFC\", \"NFD\", \"NFKC\", or \"NFKD\", If not specified default\n * is \"NFC\"\n */\n normalize(form: \"NFC\" | \"NFD\" | \"NFKC\" | \"NFKD\"): string;\n\n /**\n * Returns the String value result of normalizing the string into the normalization form\n * named by form as specified in Unicode Standard Annex #15, Unicode Normalization Forms.\n * @param form Applicable values: \"NFC\", \"NFD\", \"NFKC\", or \"NFKD\", If not specified default\n * is \"NFC\"\n */\n normalize(form?: string): string;\n\n /**\n * Returns a String value that is made from count copies appended together. If count is 0,\n * T is the empty String is returned.\n * @param count number of copies to append\n */\n repeat(count: number): string;\n\n /**\n * Returns true if the sequence of elements of searchString converted to a String is the\n * same as the corresponding elements of this object (converted to a String) starting at\n * position. Otherwise returns false.\n */\n startsWith(searchString: string, position?: number): boolean;\n\n /**\n * Returns an HTML anchor element and sets the name attribute to the text value\n * @param name\n */\n anchor(name: string): string;\n\n /** Returns a HTML element */\n big(): string;\n\n /** Returns a HTML element */\n blink(): string;\n\n /** Returns a HTML element */\n bold(): string;\n\n /** Returns a HTML element */\n fixed(): string;\n\n /** Returns a HTML element and sets the color attribute value */\n fontcolor(color: string): string;\n\n /** Returns a HTML element and sets the size attribute value */\n fontsize(size: number): string;\n\n /** Returns a HTML element and sets the size attribute value */\n fontsize(size: string): string;\n\n /** Returns an HTML element */\n italics(): string;\n\n /** Returns an HTML element and sets the href attribute value */\n link(url: string): string;\n\n /** Returns a HTML element */\n small(): string;\n\n /** Returns a HTML element */\n strike(): string;\n\n /** Returns a HTML element */\n sub(): string;\n\n /** Returns a HTML element */\n sup(): string;\n}\n\ninterface StringConstructor {\n /**\n * Return the String value whose elements are, in order, the elements in the List elements.\n * If length is 0, the empty string is returned.\n */\n fromCodePoint(...codePoints: number[]): string;\n\n /**\n * String.raw is intended for use as a tag function of a Tagged Template String. When called\n * as such the first argument will be a well formed template call site object and the rest\n * parameter will contain the substitution values.\n * @param template A well-formed template string call site representation.\n * @param substitutions A set of substitution values.\n */\n raw(template: TemplateStringsArray, ...substitutions: any[]): string;\n}\n\n\ninterface Map {\n clear(): void;\n delete(key: K): boolean;\n forEach(callbackfn: (value: V, key: K, map: Map) => void, thisArg?: any): void;\n get(key: K): V | undefined;\n has(key: K): boolean;\n set(key: K, value: V): this;\n readonly size: number;\n}\n\ninterface MapConstructor {\n new (): Map;\n new (entries?: [K, V][]): Map;\n readonly prototype: Map;\n}\ndeclare var Map: MapConstructor;\n\ninterface ReadonlyMap {\n forEach(callbackfn: (value: V, key: K, map: ReadonlyMap) => void, thisArg?: any): void;\n get(key: K): V | undefined;\n has(key: K): boolean;\n readonly size: number;\n}\n\ninterface WeakMap {\n delete(key: K): boolean;\n get(key: K): V | undefined;\n has(key: K): boolean;\n set(key: K, value: V): this;\n}\n\ninterface WeakMapConstructor {\n new (): WeakMap;\n new (entries?: [K, V][]): WeakMap;\n readonly prototype: WeakMap;\n}\ndeclare var WeakMap: WeakMapConstructor;\n\ninterface Set {\n add(value: T): this;\n clear(): void;\n delete(value: T): boolean;\n forEach(callbackfn: (value: T, value2: T, set: Set) => void, thisArg?: any): void;\n has(value: T): boolean;\n readonly size: number;\n}\n\ninterface SetConstructor {\n new (): Set;\n new (values?: T[]): Set;\n readonly prototype: Set;\n}\ndeclare var Set: SetConstructor;\n\ninterface ReadonlySet {\n forEach(callbackfn: (value: T, value2: T, set: ReadonlySet) => void, thisArg?: any): void;\n has(value: T): boolean;\n readonly size: number;\n}\n\ninterface WeakSet {\n add(value: T): this;\n delete(value: T): boolean;\n has(value: T): boolean;\n}\n\ninterface WeakSetConstructor {\n new (): WeakSet;\n new (values?: T[]): WeakSet;\n readonly prototype: WeakSet;\n}\ndeclare var WeakSet: WeakSetConstructor;\n\n\ninterface Generator extends Iterator { }\n\ninterface GeneratorFunction {\n /**\n * Creates a new Generator object.\n * @param args A list of arguments the function accepts.\n */\n new (...args: any[]): Generator;\n /**\n * Creates a new Generator object.\n * @param args A list of arguments the function accepts.\n */\n (...args: any[]): Generator;\n /**\n * The length of the arguments.\n */\n readonly length: number;\n /**\n * Returns the name of the function.\n */\n readonly name: string;\n /**\n * A reference to the prototype.\n */\n readonly prototype: Generator;\n}\n\ninterface GeneratorFunctionConstructor {\n /**\n * Creates a new Generator function.\n * @param args A list of arguments the function accepts.\n */\n new (...args: string[]): GeneratorFunction;\n /**\n * Creates a new Generator function.\n * @param args A list of arguments the function accepts.\n */\n (...args: string[]): GeneratorFunction;\n /**\n * The length of the arguments.\n */\n readonly length: number;\n /**\n * Returns the name of the function.\n */\n readonly name: string;\n /**\n * A reference to the prototype.\n */\n readonly prototype: GeneratorFunction;\n}\ndeclare var GeneratorFunction: GeneratorFunctionConstructor;\n\n\n/// \n\ninterface SymbolConstructor {\n /**\n * A method that returns the default iterator for an object. Called by the semantics of the\n * for-of statement.\n */\n readonly iterator: symbol;\n}\n\ninterface IteratorResult {\n done: boolean;\n value: T;\n}\n\ninterface Iterator {\n next(value?: any): IteratorResult;\n return?(value?: any): IteratorResult;\n throw?(e?: any): IteratorResult;\n}\n\ninterface Iterable {\n [Symbol.iterator](): Iterator;\n}\n\ninterface IterableIterator extends Iterator {\n [Symbol.iterator](): IterableIterator;\n}\n\ninterface Array {\n /** Iterator */\n [Symbol.iterator](): IterableIterator;\n\n /**\n * Returns an iterable of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, T]>;\n\n /**\n * Returns an iterable of keys in the array\n */\n keys(): IterableIterator;\n\n /**\n * Returns an iterable of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface ArrayConstructor {\n /**\n * Creates an array from an iterable object.\n * @param iterable An iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(iterable: Iterable, mapfn: (this: void, v: T, k: number) => U): Array;\n from(iterable: Iterable, mapfn: (this: void, v: T, k: number) => U, thisArg: undefined): Array;\n from(iterable: Iterable, mapfn: (this: Z, v: T, k: number) => U, thisArg: Z): Array;\n\n /**\n * Creates an array from an iterable object.\n * @param iterable An iterable object to convert to an array.\n */\n from(iterable: Iterable): Array;\n}\n\ninterface ReadonlyArray {\n /** Iterator of values in the array. */\n [Symbol.iterator](): IterableIterator;\n\n /**\n * Returns an iterable of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, T]>;\n\n /**\n * Returns an iterable of keys in the array\n */\n keys(): IterableIterator;\n\n /**\n * Returns an iterable of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface IArguments {\n /** Iterator */\n [Symbol.iterator](): IterableIterator;\n}\n\ninterface Map {\n /** Returns an iterable of entries in the map. */\n [Symbol.iterator](): IterableIterator<[K, V]>;\n\n /**\n * Returns an iterable of key, value pairs for every entry in the map.\n */\n entries(): IterableIterator<[K, V]>;\n\n /**\n * Returns an iterable of keys in the map\n */\n keys(): IterableIterator;\n\n /**\n * Returns an iterable of values in the map\n */\n values(): IterableIterator;\n}\n\ninterface ReadonlyMap {\n /** Returns an iterable of entries in the map. */\n [Symbol.iterator](): IterableIterator<[K, V]>;\n\n /**\n * Returns an iterable of key, value pairs for every entry in the map.\n */\n entries(): IterableIterator<[K, V]>;\n\n /**\n * Returns an iterable of keys in the map\n */\n keys(): IterableIterator;\n\n /**\n * Returns an iterable of values in the map\n */\n values(): IterableIterator;\n}\n\ninterface MapConstructor {\n new (iterable: Iterable<[K, V]>): Map;\n}\n\ninterface WeakMap { }\n\ninterface WeakMapConstructor {\n new (iterable: Iterable<[K, V]>): WeakMap;\n}\n\ninterface Set {\n /** Iterates over values in the set. */\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an iterable of [v,v] pairs for every value `v` in the set.\n */\n entries(): IterableIterator<[T, T]>;\n /**\n * Despite its name, returns an iterable of the values in the set,\n */\n keys(): IterableIterator;\n\n /**\n * Returns an iterable of values in the set.\n */\n values(): IterableIterator;\n}\n\ninterface ReadonlySet {\n /** Iterates over values in the set. */\n [Symbol.iterator](): IterableIterator;\n\n /**\n * Returns an iterable of [v,v] pairs for every value `v` in the set.\n */\n entries(): IterableIterator<[T, T]>;\n\n /**\n * Despite its name, returns an iterable of the values in the set,\n */\n keys(): IterableIterator;\n\n /**\n * Returns an iterable of values in the set.\n */\n values(): IterableIterator;\n}\n\ninterface SetConstructor {\n new (iterable: Iterable): Set;\n}\n\ninterface WeakSet { }\n\ninterface WeakSetConstructor {\n new (iterable: Iterable): WeakSet;\n}\n\ninterface Promise { }\n\ninterface PromiseConstructor {\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: Iterable>): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: Iterable>): Promise;\n}\n\ndeclare namespace Reflect {\n function enumerate(target: object): IterableIterator;\n}\n\ninterface String {\n /** Iterator */\n [Symbol.iterator](): IterableIterator;\n}\n\n/**\n * A typed array of 8-bit integer values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Int8Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Int8ArrayConstructor {\n new (elements: Iterable): Int8Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Int8Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Int8Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Int8Array;\n\n from(arrayLike: Iterable): Int8Array;\n}\n\n/**\n * A typed array of 8-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Uint8ArrayConstructor {\n new (elements: Iterable): Uint8Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Uint8Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint8Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint8Array;\n\n from(arrayLike: Iterable): Uint8Array;\n}\n\n/**\n * A typed array of 8-bit unsigned integer (clamped) values. The contents are initialized to 0.\n * If the requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8ClampedArray {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Uint8ClampedArrayConstructor {\n new (elements: Iterable): Uint8ClampedArray;\n\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Uint8ClampedArray;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint8ClampedArray;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint8ClampedArray;\n\n from(arrayLike: Iterable): Uint8ClampedArray;\n}\n\n/**\n * A typed array of 16-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int16Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Int16ArrayConstructor {\n new (elements: Iterable): Int16Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Int16Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Int16Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Int16Array;\n\n from(arrayLike: Iterable): Int16Array;\n}\n\n/**\n * A typed array of 16-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint16Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Uint16ArrayConstructor {\n new (elements: Iterable): Uint16Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Uint16Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint16Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint16Array;\n\n from(arrayLike: Iterable): Uint16Array;\n}\n\n/**\n * A typed array of 32-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int32Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Int32ArrayConstructor {\n new (elements: Iterable): Int32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Int32Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Int32Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Int32Array;\n\n from(arrayLike: Iterable): Int32Array;\n}\n\n/**\n * A typed array of 32-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint32Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Uint32ArrayConstructor {\n new (elements: Iterable): Uint32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Uint32Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint32Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint32Array;\n\n from(arrayLike: Iterable): Uint32Array;\n}\n\n/**\n * A typed array of 32-bit float values. The contents are initialized to 0. If the requested number\n * of bytes could not be allocated an exception is raised.\n */\ninterface Float32Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Float32ArrayConstructor {\n new (elements: Iterable): Float32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Float32Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Float32Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Float32Array;\n\n from(arrayLike: Iterable): Float32Array;\n}\n\n/**\n * A typed array of 64-bit float values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Float64Array {\n [Symbol.iterator](): IterableIterator;\n /**\n * Returns an array of key, value pairs for every entry in the array\n */\n entries(): IterableIterator<[number, number]>;\n /**\n * Returns an list of keys in the array\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the array\n */\n values(): IterableIterator;\n}\n\ninterface Float64ArrayConstructor {\n new (elements: Iterable): Float64Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number): Float64Array;\n from(arrayLike: Iterable, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Float64Array;\n from(arrayLike: Iterable, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Float64Array;\n\n from(arrayLike: Iterable): Float64Array;\n}\n\n\ninterface PromiseConstructor {\n /**\n * A reference to the prototype.\n */\n readonly prototype: Promise;\n\n /**\n * Creates a new Promise.\n * @param executor A callback used to initialize the promise. This callback is passed two arguments:\n * a resolve callback used resolve the promise with a value or the result of another promise,\n * and a reject callback used to reject the promise with a provided reason or error.\n */\n new (executor: (resolve: (value?: T | PromiseLike) => void, reject: (reason?: any) => void) => void): Promise;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike, T9 | PromiseLike, T10 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6, T7, T8, T9, T10]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike, T9 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6, T7, T8, T9]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6, T7, T8]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6, T7]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike, T6 | PromiseLike]): Promise<[T1, T2, T3, T4, T5, T6]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike , T5 | PromiseLike]): Promise<[T1, T2, T3, T4, T5]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike ]): Promise<[T1, T2, T3, T4]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike]): Promise<[T1, T2, T3]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: [T1 | PromiseLike, T2 | PromiseLike]): Promise<[T1, T2]>;\n\n /**\n * Creates a Promise that is resolved with an array of results when all of the provided Promises\n * resolve, or rejected when any Promise is rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n all(values: (T | PromiseLike)[]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike, T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike, T9 | PromiseLike, T10 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike, T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike, T9 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike, T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike, T8 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike, T5 | PromiseLike, T6 | PromiseLike, T7 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike, T5 | PromiseLike, T6 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike, T5 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike, T4 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike, T3 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: [T1 | PromiseLike, T2 | PromiseLike]): Promise;\n\n /**\n * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved\n * or rejected.\n * @param values An array of Promises.\n * @returns A new Promise.\n */\n race(values: (T | PromiseLike)[]): Promise;\n\n /**\n * Creates a new rejected promise for the provided reason.\n * @param reason The reason the promise was rejected.\n * @returns A new rejected Promise.\n */\n reject(reason: any): Promise;\n\n /**\n * Creates a new rejected promise for the provided reason.\n * @param reason The reason the promise was rejected.\n * @returns A new rejected Promise.\n */\n reject(reason: any): Promise;\n\n /**\n * Creates a new resolved promise for the provided value.\n * @param value A promise.\n * @returns A promise whose internal state matches the provided promise.\n */\n resolve(value: T | PromiseLike): Promise;\n\n /**\n * Creates a new resolved promise .\n * @returns A resolved promise.\n */\n resolve(): Promise;\n}\n\ndeclare var Promise: PromiseConstructor;\n\ninterface ProxyHandler {\n getPrototypeOf? (target: T): object | null;\n setPrototypeOf? (target: T, v: any): boolean;\n isExtensible? (target: T): boolean;\n preventExtensions? (target: T): boolean;\n getOwnPropertyDescriptor? (target: T, p: PropertyKey): PropertyDescriptor | undefined;\n has? (target: T, p: PropertyKey): boolean;\n get? (target: T, p: PropertyKey, receiver: any): any;\n set? (target: T, p: PropertyKey, value: any, receiver: any): boolean;\n deleteProperty? (target: T, p: PropertyKey): boolean;\n defineProperty? (target: T, p: PropertyKey, attributes: PropertyDescriptor): boolean;\n enumerate? (target: T): PropertyKey[];\n ownKeys? (target: T): PropertyKey[];\n apply? (target: T, thisArg: any, argArray?: any): any;\n construct? (target: T, argArray: any, newTarget?: any): object;\n}\n\ninterface ProxyConstructor {\n revocable(target: T, handler: ProxyHandler): { proxy: T; revoke: () => void; };\n new (target: T, handler: ProxyHandler): T;\n}\ndeclare var Proxy: ProxyConstructor;\n\n\ndeclare namespace Reflect {\n function apply(target: Function, thisArgument: any, argumentsList: ArrayLike): any;\n function construct(target: Function, argumentsList: ArrayLike, newTarget?: any): any;\n function defineProperty(target: object, propertyKey: PropertyKey, attributes: PropertyDescriptor): boolean;\n function deleteProperty(target: object, propertyKey: PropertyKey): boolean;\n function get(target: object, propertyKey: PropertyKey, receiver?: any): any;\n function getOwnPropertyDescriptor(target: object, propertyKey: PropertyKey): PropertyDescriptor;\n function getPrototypeOf(target: object): object;\n function has(target: object, propertyKey: PropertyKey): boolean;\n function isExtensible(target: object): boolean;\n function ownKeys(target: object): Array;\n function preventExtensions(target: object): boolean;\n function set(target: object, propertyKey: PropertyKey, value: any, receiver?: any): boolean;\n function setPrototypeOf(target: object, proto: any): boolean;\n}\n\n\ninterface Symbol {\n /** Returns a string representation of an object. */\n toString(): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): symbol;\n}\n\ninterface SymbolConstructor {\n /**\n * A reference to the prototype.\n */\n readonly prototype: Symbol;\n\n /**\n * Returns a new unique Symbol value.\n * @param description Description of the new Symbol object.\n */\n (description?: string | number): symbol;\n\n /**\n * Returns a Symbol object from the global symbol registry matching the given key if found.\n * Otherwise, returns a new symbol with this key.\n * @param key key to search for.\n */\n for(key: string): symbol;\n\n /**\n * Returns a key from the global symbol registry matching the given Symbol if found.\n * Otherwise, returns a undefined.\n * @param sym Symbol to find the key for.\n */\n keyFor(sym: symbol): string | undefined;\n}\n\ndeclare var Symbol: SymbolConstructor;\n\n/// \n\ninterface SymbolConstructor {\n /**\n * A method that determines if a constructor object recognizes an object as one of the\n * constructor’s instances. Called by the semantics of the instanceof operator.\n */\n readonly hasInstance: symbol;\n\n /**\n * A Boolean value that if true indicates that an object should flatten to its array elements\n * by Array.prototype.concat.\n */\n readonly isConcatSpreadable: symbol;\n\n /**\n * A regular expression method that matches the regular expression against a string. Called\n * by the String.prototype.match method.\n */\n readonly match: symbol;\n\n /**\n * A regular expression method that replaces matched substrings of a string. Called by the\n * String.prototype.replace method.\n */\n readonly replace: symbol;\n\n /**\n * A regular expression method that returns the index within a string that matches the\n * regular expression. Called by the String.prototype.search method.\n */\n readonly search: symbol;\n\n /**\n * A function valued property that is the constructor function that is used to create\n * derived objects.\n */\n readonly species: symbol;\n\n /**\n * A regular expression method that splits a string at the indices that match the regular\n * expression. Called by the String.prototype.split method.\n */\n readonly split: symbol;\n\n /**\n * A method that converts an object to a corresponding primitive value.\n * Called by the ToPrimitive abstract operation.\n */\n readonly toPrimitive: symbol;\n\n /**\n * A String value that is used in the creation of the default string description of an object.\n * Called by the built-in method Object.prototype.toString.\n */\n readonly toStringTag: symbol;\n\n /**\n * An Object whose own property names are property names that are excluded from the 'with'\n * environment bindings of the associated objects.\n */\n readonly unscopables: symbol;\n}\n\ninterface Symbol {\n readonly [Symbol.toStringTag]: \"Symbol\";\n}\n\ninterface Array {\n /**\n * Returns an object whose properties have the value 'true'\n * when they will be absent when used in a 'with' statement.\n */\n [Symbol.unscopables](): {\n copyWithin: boolean;\n entries: boolean;\n fill: boolean;\n find: boolean;\n findIndex: boolean;\n keys: boolean;\n values: boolean;\n };\n}\n\ninterface Date {\n /**\n * Converts a Date object to a string.\n */\n [Symbol.toPrimitive](hint: \"default\"): string;\n /**\n * Converts a Date object to a string.\n */\n [Symbol.toPrimitive](hint: \"string\"): string;\n /**\n * Converts a Date object to a number.\n */\n [Symbol.toPrimitive](hint: \"number\"): number;\n /**\n * Converts a Date object to a string or number.\n *\n * @param hint The strings \"number\", \"string\", or \"default\" to specify what primitive to return.\n *\n * @throws {TypeError} If 'hint' was given something other than \"number\", \"string\", or \"default\".\n * @returns A number if 'hint' was \"number\", a string if 'hint' was \"string\" or \"default\".\n */\n [Symbol.toPrimitive](hint: string): string | number;\n}\n\ninterface Map {\n readonly [Symbol.toStringTag]: \"Map\";\n}\n\ninterface WeakMap{\n readonly [Symbol.toStringTag]: \"WeakMap\";\n}\n\ninterface Set {\n readonly [Symbol.toStringTag]: \"Set\";\n}\n\ninterface WeakSet {\n readonly [Symbol.toStringTag]: \"WeakSet\";\n}\n\ninterface JSON {\n readonly [Symbol.toStringTag]: \"JSON\";\n}\n\ninterface Function {\n /**\n * Determines whether the given value inherits from this function if this function was used\n * as a constructor function.\n *\n * A constructor function can control which objects are recognized as its instances by\n * 'instanceof' by overriding this method.\n */\n [Symbol.hasInstance](value: any): boolean;\n}\n\ninterface GeneratorFunction {\n readonly [Symbol.toStringTag]: \"GeneratorFunction\";\n}\n\ninterface Math {\n readonly [Symbol.toStringTag]: \"Math\";\n}\n\ninterface Promise {\n readonly [Symbol.toStringTag]: \"Promise\";\n}\n\ninterface PromiseConstructor {\n readonly [Symbol.species]: Function;\n}\n\ninterface RegExp {\n /**\n * Matches a string with this regular expression, and returns an array containing the results of\n * that search.\n * @param string A string to search within.\n */\n [Symbol.match](string: string): RegExpMatchArray | null;\n\n /**\n * Replaces text in a string, using this regular expression.\n * @param string A String object or string literal whose contents matching against\n * this regular expression will be replaced\n * @param replaceValue A String object or string literal containing the text to replace for every\n * successful match of this regular expression.\n */\n [Symbol.replace](string: string, replaceValue: string): string;\n\n /**\n * Replaces text in a string, using this regular expression.\n * @param string A String object or string literal whose contents matching against\n * this regular expression will be replaced\n * @param replacer A function that returns the replacement text.\n */\n [Symbol.replace](string: string, replacer: (substring: string, ...args: any[]) => string): string;\n\n /**\n * Finds the position beginning first substring match in a regular expression search\n * using this regular expression.\n *\n * @param string The string to search within.\n */\n [Symbol.search](string: string): number;\n\n /**\n * Returns an array of substrings that were delimited by strings in the original input that\n * match against this regular expression.\n *\n * If the regular expression contains capturing parentheses, then each time this\n * regular expression matches, the results (including any undefined results) of the\n * capturing parentheses are spliced.\n *\n * @param string string value to split\n * @param limit if not undefined, the output array is truncated so that it contains no more\n * than 'limit' elements.\n */\n [Symbol.split](string: string, limit?: number): string[];\n}\n\ninterface RegExpConstructor {\n [Symbol.species](): RegExpConstructor;\n}\n\ninterface String {\n /**\n * Matches a string an object that supports being matched against, and returns an array containing the results of that search.\n * @param matcher An object that supports being matched against.\n */\n match(matcher: { [Symbol.match](string: string): RegExpMatchArray | null; }): RegExpMatchArray | null;\n\n /**\n * Replaces text in a string, using an object that supports replacement within a string.\n * @param searchValue A object can search for and replace matches within a string.\n * @param replaceValue A string containing the text to replace for every successful match of searchValue in this string.\n */\n replace(searchValue: { [Symbol.replace](string: string, replaceValue: string): string; }, replaceValue: string): string;\n\n /**\n * Replaces text in a string, using an object that supports replacement within a string.\n * @param searchValue A object can search for and replace matches within a string.\n * @param replacer A function that returns the replacement text.\n */\n replace(searchValue: { [Symbol.replace](string: string, replacer: (substring: string, ...args: any[]) => string): string; }, replacer: (substring: string, ...args: any[]) => string): string;\n\n /**\n * Finds the first substring match in a regular expression search.\n * @param searcher An object which supports searching within a string.\n */\n search(searcher: { [Symbol.search](string: string): number; }): number;\n\n /**\n * Split a string into substrings using the specified separator and return them as an array.\n * @param splitter An object that can split a string.\n * @param limit A value used to limit the number of elements returned in the array.\n */\n split(splitter: { [Symbol.split](string: string, limit?: number): string[]; }, limit?: number): string[];\n}\n\n/**\n * Represents a raw buffer of binary data, which is used to store data for the\n * different typed arrays. ArrayBuffers cannot be read from or written to directly,\n * but can be passed to a typed array or DataView Object to interpret the raw\n * buffer as needed.\n */\ninterface ArrayBuffer {\n readonly [Symbol.toStringTag]: \"ArrayBuffer\";\n}\n\ninterface DataView {\n readonly [Symbol.toStringTag]: \"DataView\";\n}\n\n/**\n * A typed array of 8-bit integer values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Int8Array {\n readonly [Symbol.toStringTag]: \"Int8Array\";\n}\n\n/**\n * A typed array of 8-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8Array {\n readonly [Symbol.toStringTag]: \"UInt8Array\";\n}\n\n/**\n * A typed array of 8-bit unsigned integer (clamped) values. The contents are initialized to 0.\n * If the requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8ClampedArray {\n readonly [Symbol.toStringTag]: \"Uint8ClampedArray\";\n}\n\n/**\n * A typed array of 16-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int16Array {\n readonly [Symbol.toStringTag]: \"Int16Array\";\n}\n\n/**\n * A typed array of 16-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint16Array {\n readonly [Symbol.toStringTag]: \"Uint16Array\";\n}\n\n/**\n * A typed array of 32-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int32Array {\n readonly [Symbol.toStringTag]: \"Int32Array\";\n}\n\n/**\n * A typed array of 32-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint32Array {\n readonly [Symbol.toStringTag]: \"Uint32Array\";\n}\n\n/**\n * A typed array of 32-bit float values. The contents are initialized to 0. If the requested number\n * of bytes could not be allocated an exception is raised.\n */\ninterface Float32Array {\n readonly [Symbol.toStringTag]: \"Float32Array\";\n}\n\n/**\n * A typed array of 64-bit float values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Float64Array {\n readonly [Symbol.toStringTag]: \"Float64Array\";\n}\n\n\n\n/////////////////////////////\n/// DOM APIs\n/////////////////////////////\n\ninterface Account {\n displayName?: string;\n id?: string;\n imageURL?: string;\n name?: string;\n rpDisplayName?: string;\n}\n\ninterface Algorithm {\n name: string;\n}\n\ninterface AnimationEventInit extends EventInit {\n animationName?: string;\n elapsedTime?: number;\n}\n\ninterface AssertionOptions {\n allowList?: ScopedCredentialDescriptor[];\n extensions?: WebAuthnExtensions;\n rpId?: USVString;\n timeoutSeconds?: number;\n}\n\ninterface CacheQueryOptions {\n cacheName?: string;\n ignoreMethod?: boolean;\n ignoreSearch?: boolean;\n ignoreVary?: boolean;\n}\n\ninterface ClientData {\n challenge?: string;\n extensions?: WebAuthnExtensions;\n hashAlg?: string | Algorithm;\n origin?: string;\n rpId?: string;\n tokenBinding?: string;\n}\n\ninterface CloseEventInit extends EventInit {\n code?: number;\n reason?: string;\n wasClean?: boolean;\n}\n\ninterface CompositionEventInit extends UIEventInit {\n data?: string;\n}\n\ninterface ConfirmSiteSpecificExceptionsInformation extends ExceptionInformation {\n arrayOfDomainStrings?: string[];\n}\n\ninterface ConstrainBooleanParameters {\n exact?: boolean;\n ideal?: boolean;\n}\n\ninterface ConstrainDOMStringParameters {\n exact?: string | string[];\n ideal?: string | string[];\n}\n\ninterface ConstrainDoubleRange extends DoubleRange {\n exact?: number;\n ideal?: number;\n}\n\ninterface ConstrainLongRange extends LongRange {\n exact?: number;\n ideal?: number;\n}\n\ninterface ConstrainVideoFacingModeParameters {\n exact?: VideoFacingModeEnum | VideoFacingModeEnum[];\n ideal?: VideoFacingModeEnum | VideoFacingModeEnum[];\n}\n\ninterface CustomEventInit extends EventInit {\n detail?: any;\n}\n\ninterface DeviceAccelerationDict {\n x?: number;\n y?: number;\n z?: number;\n}\n\ninterface DeviceLightEventInit extends EventInit {\n value?: number;\n}\n\ninterface DeviceMotionEventInit extends EventInit {\n acceleration?: DeviceAccelerationDict;\n accelerationIncludingGravity?: DeviceAccelerationDict;\n interval?: number;\n rotationRate?: DeviceRotationRateDict;\n}\n\ninterface DeviceOrientationEventInit extends EventInit {\n absolute?: boolean;\n alpha?: number;\n beta?: number;\n gamma?: number;\n}\n\ninterface DeviceRotationRateDict {\n alpha?: number;\n beta?: number;\n gamma?: number;\n}\n\ninterface DOMRectInit {\n height?: any;\n width?: any;\n x?: any;\n y?: any;\n}\n\ninterface DoubleRange {\n max?: number;\n min?: number;\n}\n\ninterface ErrorEventInit extends EventInit {\n colno?: number;\n error?: any;\n filename?: string;\n lineno?: number;\n message?: string;\n}\n\ninterface EventInit {\n scoped?: boolean;\n bubbles?: boolean;\n cancelable?: boolean;\n}\n\ninterface EventModifierInit extends UIEventInit {\n altKey?: boolean;\n ctrlKey?: boolean;\n metaKey?: boolean;\n modifierAltGraph?: boolean;\n modifierCapsLock?: boolean;\n modifierFn?: boolean;\n modifierFnLock?: boolean;\n modifierHyper?: boolean;\n modifierNumLock?: boolean;\n modifierOS?: boolean;\n modifierScrollLock?: boolean;\n modifierSuper?: boolean;\n modifierSymbol?: boolean;\n modifierSymbolLock?: boolean;\n shiftKey?: boolean;\n}\n\ninterface ExceptionInformation {\n domain?: string;\n}\n\ninterface FocusEventInit extends UIEventInit {\n relatedTarget?: EventTarget;\n}\n\ninterface FocusNavigationEventInit extends EventInit {\n navigationReason?: string;\n originHeight?: number;\n originLeft?: number;\n originTop?: number;\n originWidth?: number;\n}\n\ninterface FocusNavigationOrigin {\n originHeight?: number;\n originLeft?: number;\n originTop?: number;\n originWidth?: number;\n}\n\ninterface GamepadEventInit extends EventInit {\n gamepad?: Gamepad;\n}\n\ninterface GetNotificationOptions {\n tag?: string;\n}\n\ninterface HashChangeEventInit extends EventInit {\n newURL?: string;\n oldURL?: string;\n}\n\ninterface IDBIndexParameters {\n multiEntry?: boolean;\n unique?: boolean;\n}\n\ninterface IDBObjectStoreParameters {\n autoIncrement?: boolean;\n keyPath?: IDBKeyPath;\n}\n\ninterface IntersectionObserverEntryInit {\n boundingClientRect?: DOMRectInit;\n intersectionRect?: DOMRectInit;\n rootBounds?: DOMRectInit;\n target?: Element;\n time?: number;\n}\n\ninterface IntersectionObserverInit {\n root?: Element;\n rootMargin?: string;\n threshold?: number | number[];\n}\n\ninterface KeyAlgorithm {\n name?: string;\n}\n\ninterface KeyboardEventInit extends EventModifierInit {\n code?: string;\n key?: string;\n location?: number;\n repeat?: boolean;\n}\n\ninterface LongRange {\n max?: number;\n min?: number;\n}\n\ninterface MediaEncryptedEventInit extends EventInit {\n initData?: ArrayBuffer;\n initDataType?: string;\n}\n\ninterface MediaKeyMessageEventInit extends EventInit {\n message?: ArrayBuffer;\n messageType?: MediaKeyMessageType;\n}\n\ninterface MediaKeySystemConfiguration {\n audioCapabilities?: MediaKeySystemMediaCapability[];\n distinctiveIdentifier?: MediaKeysRequirement;\n initDataTypes?: string[];\n persistentState?: MediaKeysRequirement;\n videoCapabilities?: MediaKeySystemMediaCapability[];\n}\n\ninterface MediaKeySystemMediaCapability {\n contentType?: string;\n robustness?: string;\n}\n\ninterface MediaStreamConstraints {\n audio?: boolean | MediaTrackConstraints;\n video?: boolean | MediaTrackConstraints;\n}\n\ninterface MediaStreamErrorEventInit extends EventInit {\n error?: MediaStreamError;\n}\n\ninterface MediaStreamEventInit extends EventInit {\n stream?: MediaStream;\n}\n\ninterface MediaStreamTrackEventInit extends EventInit {\n track?: MediaStreamTrack;\n}\n\ninterface MediaTrackCapabilities {\n aspectRatio?: number | DoubleRange;\n deviceId?: string;\n echoCancellation?: boolean[];\n facingMode?: string;\n frameRate?: number | DoubleRange;\n groupId?: string;\n height?: number | LongRange;\n sampleRate?: number | LongRange;\n sampleSize?: number | LongRange;\n volume?: number | DoubleRange;\n width?: number | LongRange;\n}\n\ninterface MediaTrackConstraints extends MediaTrackConstraintSet {\n advanced?: MediaTrackConstraintSet[];\n}\n\ninterface MediaTrackConstraintSet {\n aspectRatio?: number | ConstrainDoubleRange;\n deviceId?: string | string[] | ConstrainDOMStringParameters;\n echoCancelation?: boolean | ConstrainBooleanParameters;\n facingMode?: string | string[] | ConstrainDOMStringParameters;\n frameRate?: number | ConstrainDoubleRange;\n groupId?: string | string[] | ConstrainDOMStringParameters;\n height?: number | ConstrainLongRange;\n sampleRate?: number | ConstrainLongRange;\n sampleSize?: number | ConstrainLongRange;\n volume?: number | ConstrainDoubleRange;\n width?: number | ConstrainLongRange;\n}\n\ninterface MediaTrackSettings {\n aspectRatio?: number;\n deviceId?: string;\n echoCancellation?: boolean;\n facingMode?: string;\n frameRate?: number;\n groupId?: string;\n height?: number;\n sampleRate?: number;\n sampleSize?: number;\n volume?: number;\n width?: number;\n}\n\ninterface MediaTrackSupportedConstraints {\n aspectRatio?: boolean;\n deviceId?: boolean;\n echoCancellation?: boolean;\n facingMode?: boolean;\n frameRate?: boolean;\n groupId?: boolean;\n height?: boolean;\n sampleRate?: boolean;\n sampleSize?: boolean;\n volume?: boolean;\n width?: boolean;\n}\n\ninterface MessageEventInit extends EventInit {\n lastEventId?: string;\n channel?: string;\n data?: any;\n origin?: string;\n ports?: MessagePort[];\n source?: Window;\n}\n\ninterface MouseEventInit extends EventModifierInit {\n button?: number;\n buttons?: number;\n clientX?: number;\n clientY?: number;\n relatedTarget?: EventTarget;\n screenX?: number;\n screenY?: number;\n}\n\ninterface MSAccountInfo {\n accountImageUri?: string;\n accountName?: string;\n rpDisplayName?: string;\n userDisplayName?: string;\n userId?: string;\n}\n\ninterface MSAudioLocalClientEvent extends MSLocalClientEventBase {\n cpuInsufficientEventRatio?: number;\n deviceCaptureNotFunctioningEventRatio?: number;\n deviceClippingEventRatio?: number;\n deviceEchoEventRatio?: number;\n deviceGlitchesEventRatio?: number;\n deviceHalfDuplexAECEventRatio?: number;\n deviceHowlingEventCount?: number;\n deviceLowSNREventRatio?: number;\n deviceLowSpeechLevelEventRatio?: number;\n deviceMultipleEndpointsEventCount?: number;\n deviceNearEndToEchoRatioEventRatio?: number;\n deviceRenderMuteEventRatio?: number;\n deviceRenderNotFunctioningEventRatio?: number;\n deviceRenderZeroVolumeEventRatio?: number;\n networkDelayEventRatio?: number;\n networkSendQualityEventRatio?: number;\n}\n\ninterface MSAudioRecvPayload extends MSPayloadBase {\n burstLossLength1?: number;\n burstLossLength2?: number;\n burstLossLength3?: number;\n burstLossLength4?: number;\n burstLossLength5?: number;\n burstLossLength6?: number;\n burstLossLength7?: number;\n burstLossLength8OrHigher?: number;\n fecRecvDistance1?: number;\n fecRecvDistance2?: number;\n fecRecvDistance3?: number;\n packetReorderDepthAvg?: number;\n packetReorderDepthMax?: number;\n packetReorderRatio?: number;\n ratioCompressedSamplesAvg?: number;\n ratioConcealedSamplesAvg?: number;\n ratioStretchedSamplesAvg?: number;\n samplingRate?: number;\n signal?: MSAudioRecvSignal;\n}\n\ninterface MSAudioRecvSignal {\n initialSignalLevelRMS?: number;\n recvNoiseLevelCh1?: number;\n recvSignalLevelCh1?: number;\n renderLoopbackSignalLevel?: number;\n renderNoiseLevel?: number;\n renderSignalLevel?: number;\n}\n\ninterface MSAudioSendPayload extends MSPayloadBase {\n audioFECUsed?: boolean;\n samplingRate?: number;\n sendMutePercent?: number;\n signal?: MSAudioSendSignal;\n}\n\ninterface MSAudioSendSignal {\n noiseLevel?: number;\n sendNoiseLevelCh1?: number;\n sendSignalLevelCh1?: number;\n}\n\ninterface MSConnectivity {\n iceType?: MSIceType;\n iceWarningFlags?: MSIceWarningFlags;\n relayAddress?: MSRelayAddress;\n}\n\ninterface MSCredentialFilter {\n accept?: MSCredentialSpec[];\n}\n\ninterface MSCredentialParameters {\n type?: MSCredentialType;\n}\n\ninterface MSCredentialSpec {\n id?: string;\n type?: MSCredentialType;\n}\n\ninterface MSDelay {\n roundTrip?: number;\n roundTripMax?: number;\n}\n\ninterface MSDescription extends RTCStats {\n connectivity?: MSConnectivity;\n deviceDevName?: string;\n localAddr?: MSIPAddressInfo;\n networkconnectivity?: MSNetworkConnectivityInfo;\n reflexiveLocalIPAddr?: MSIPAddressInfo;\n remoteAddr?: MSIPAddressInfo;\n transport?: RTCIceProtocol;\n}\n\ninterface MSFIDOCredentialParameters extends MSCredentialParameters {\n algorithm?: string | Algorithm;\n authenticators?: AAGUID[];\n}\n\ninterface MSIceWarningFlags {\n allocationMessageIntegrityFailed?: boolean;\n alternateServerReceived?: boolean;\n connCheckMessageIntegrityFailed?: boolean;\n connCheckOtherError?: boolean;\n fipsAllocationFailure?: boolean;\n multipleRelayServersAttempted?: boolean;\n noRelayServersConfigured?: boolean;\n portRangeExhausted?: boolean;\n pseudoTLSFailure?: boolean;\n tcpNatConnectivityFailed?: boolean;\n tcpRelayConnectivityFailed?: boolean;\n turnAuthUnknownUsernameError?: boolean;\n turnTcpAllocateFailed?: boolean;\n turnTcpSendFailed?: boolean;\n turnTcpTimedOut?: boolean;\n turnTurnTcpConnectivityFailed?: boolean;\n turnUdpAllocateFailed?: boolean;\n turnUdpSendFailed?: boolean;\n udpLocalConnectivityFailed?: boolean;\n udpNatConnectivityFailed?: boolean;\n udpRelayConnectivityFailed?: boolean;\n useCandidateChecksFailed?: boolean;\n}\n\ninterface MSIPAddressInfo {\n ipAddr?: string;\n manufacturerMacAddrMask?: string;\n port?: number;\n}\n\ninterface MSJitter {\n interArrival?: number;\n interArrivalMax?: number;\n interArrivalSD?: number;\n}\n\ninterface MSLocalClientEventBase extends RTCStats {\n networkBandwidthLowEventRatio?: number;\n networkReceiveQualityEventRatio?: number;\n}\n\ninterface MSNetwork extends RTCStats {\n delay?: MSDelay;\n jitter?: MSJitter;\n packetLoss?: MSPacketLoss;\n utilization?: MSUtilization;\n}\n\ninterface MSNetworkConnectivityInfo {\n linkspeed?: number;\n networkConnectionDetails?: string;\n vpn?: boolean;\n}\n\ninterface MSNetworkInterfaceType {\n interfaceTypeEthernet?: boolean;\n interfaceTypePPP?: boolean;\n interfaceTypeTunnel?: boolean;\n interfaceTypeWireless?: boolean;\n interfaceTypeWWAN?: boolean;\n}\n\ninterface MSOutboundNetwork extends MSNetwork {\n appliedBandwidthLimit?: number;\n}\n\ninterface MSPacketLoss {\n lossRate?: number;\n lossRateMax?: number;\n}\n\ninterface MSPayloadBase extends RTCStats {\n payloadDescription?: string;\n}\n\ninterface MSPortRange {\n max?: number;\n min?: number;\n}\n\ninterface MSRelayAddress {\n port?: number;\n relayAddress?: string;\n}\n\ninterface MSSignatureParameters {\n userPrompt?: string;\n}\n\ninterface MSTransportDiagnosticsStats extends RTCStats {\n allocationTimeInMs?: number;\n baseAddress?: string;\n baseInterface?: MSNetworkInterfaceType;\n iceRole?: RTCIceRole;\n iceWarningFlags?: MSIceWarningFlags;\n interfaces?: MSNetworkInterfaceType;\n localAddress?: string;\n localAddrType?: MSIceAddrType;\n localInterface?: MSNetworkInterfaceType;\n localMR?: string;\n localMRTCPPort?: number;\n localSite?: string;\n msRtcEngineVersion?: string;\n networkName?: string;\n numConsentReqReceived?: number;\n numConsentReqSent?: number;\n numConsentRespReceived?: number;\n numConsentRespSent?: number;\n portRangeMax?: number;\n portRangeMin?: number;\n protocol?: RTCIceProtocol;\n remoteAddress?: string;\n remoteAddrType?: MSIceAddrType;\n remoteMR?: string;\n remoteMRTCPPort?: number;\n remoteSite?: string;\n rtpRtcpMux?: boolean;\n stunVer?: number;\n}\n\ninterface MSUtilization {\n bandwidthEstimation?: number;\n bandwidthEstimationAvg?: number;\n bandwidthEstimationMax?: number;\n bandwidthEstimationMin?: number;\n bandwidthEstimationStdDev?: number;\n packets?: number;\n}\n\ninterface MSVideoPayload extends MSPayloadBase {\n durationSeconds?: number;\n resolution?: string;\n videoBitRateAvg?: number;\n videoBitRateMax?: number;\n videoFrameRateAvg?: number;\n videoPacketLossRate?: number;\n}\n\ninterface MSVideoRecvPayload extends MSVideoPayload {\n lowBitRateCallPercent?: number;\n lowFrameRateCallPercent?: number;\n recvBitRateAverage?: number;\n recvBitRateMaximum?: number;\n recvCodecType?: string;\n recvFpsHarmonicAverage?: number;\n recvFrameRateAverage?: number;\n recvNumResSwitches?: number;\n recvReorderBufferMaxSuccessfullyOrderedExtent?: number;\n recvReorderBufferMaxSuccessfullyOrderedLateTime?: number;\n recvReorderBufferPacketsDroppedDueToBufferExhaustion?: number;\n recvReorderBufferPacketsDroppedDueToTimeout?: number;\n recvReorderBufferReorderedPackets?: number;\n recvResolutionHeight?: number;\n recvResolutionWidth?: number;\n recvVideoStreamsMax?: number;\n recvVideoStreamsMin?: number;\n recvVideoStreamsMode?: number;\n reorderBufferTotalPackets?: number;\n videoFrameLossRate?: number;\n videoPostFECPLR?: number;\n videoResolutions?: MSVideoResolutionDistribution;\n}\n\ninterface MSVideoResolutionDistribution {\n cifQuality?: number;\n h1080Quality?: number;\n h1440Quality?: number;\n h2160Quality?: number;\n h720Quality?: number;\n vgaQuality?: number;\n}\n\ninterface MSVideoSendPayload extends MSVideoPayload {\n sendBitRateAverage?: number;\n sendBitRateMaximum?: number;\n sendFrameRateAverage?: number;\n sendResolutionHeight?: number;\n sendResolutionWidth?: number;\n sendVideoStreamsMax?: number;\n}\n\ninterface MsZoomToOptions {\n animate?: string;\n contentX?: number;\n contentY?: number;\n scaleFactor?: number;\n viewportX?: string;\n viewportY?: string;\n}\n\ninterface MutationObserverInit {\n attributeFilter?: string[];\n attributeOldValue?: boolean;\n attributes?: boolean;\n characterData?: boolean;\n characterDataOldValue?: boolean;\n childList?: boolean;\n subtree?: boolean;\n}\n\ninterface NotificationOptions {\n body?: string;\n dir?: NotificationDirection;\n icon?: string;\n lang?: string;\n tag?: string;\n}\n\ninterface ObjectURLOptions {\n oneTimeOnly?: boolean;\n}\n\ninterface PaymentCurrencyAmount {\n currency?: string;\n currencySystem?: string;\n value?: string;\n}\n\ninterface PaymentDetails {\n displayItems?: PaymentItem[];\n error?: string;\n modifiers?: PaymentDetailsModifier[];\n shippingOptions?: PaymentShippingOption[];\n total?: PaymentItem;\n}\n\ninterface PaymentDetailsModifier {\n additionalDisplayItems?: PaymentItem[];\n data?: any;\n supportedMethods?: string[];\n total?: PaymentItem;\n}\n\ninterface PaymentItem {\n amount?: PaymentCurrencyAmount;\n label?: string;\n pending?: boolean;\n}\n\ninterface PaymentMethodData {\n data?: any;\n supportedMethods?: string[];\n}\n\ninterface PaymentOptions {\n requestPayerEmail?: boolean;\n requestPayerName?: boolean;\n requestPayerPhone?: boolean;\n requestShipping?: boolean;\n shippingType?: string;\n}\n\ninterface PaymentRequestUpdateEventInit extends EventInit {\n}\n\ninterface PaymentShippingOption {\n amount?: PaymentCurrencyAmount;\n id?: string;\n label?: string;\n selected?: boolean;\n}\n\ninterface PeriodicWaveConstraints {\n disableNormalization?: boolean;\n}\n\ninterface PointerEventInit extends MouseEventInit {\n height?: number;\n isPrimary?: boolean;\n pointerId?: number;\n pointerType?: string;\n pressure?: number;\n tiltX?: number;\n tiltY?: number;\n width?: number;\n}\n\ninterface PopStateEventInit extends EventInit {\n state?: any;\n}\n\ninterface PositionOptions {\n enableHighAccuracy?: boolean;\n maximumAge?: number;\n timeout?: number;\n}\n\ninterface ProgressEventInit extends EventInit {\n lengthComputable?: boolean;\n loaded?: number;\n total?: number;\n}\n\ninterface PushSubscriptionOptionsInit {\n applicationServerKey?: any;\n userVisibleOnly?: boolean;\n}\n\ninterface RegistrationOptions {\n scope?: string;\n}\n\ninterface RequestInit {\n body?: any;\n cache?: RequestCache;\n credentials?: RequestCredentials;\n headers?: any;\n integrity?: string;\n keepalive?: boolean;\n method?: string;\n mode?: RequestMode;\n redirect?: RequestRedirect;\n referrer?: string;\n referrerPolicy?: ReferrerPolicy;\n window?: any;\n}\n\ninterface ResponseInit {\n headers?: any;\n status?: number;\n statusText?: string;\n}\n\ninterface RTCConfiguration {\n bundlePolicy?: RTCBundlePolicy;\n iceServers?: RTCIceServer[];\n iceTransportPolicy?: RTCIceTransportPolicy;\n peerIdentity?: string;\n}\n\ninterface RTCDtlsFingerprint {\n algorithm?: string;\n value?: string;\n}\n\ninterface RTCDtlsParameters {\n fingerprints?: RTCDtlsFingerprint[];\n role?: RTCDtlsRole;\n}\n\ninterface RTCDTMFToneChangeEventInit extends EventInit {\n tone?: string;\n}\n\ninterface RTCIceCandidateAttributes extends RTCStats {\n addressSourceUrl?: string;\n candidateType?: RTCStatsIceCandidateType;\n ipAddress?: string;\n portNumber?: number;\n priority?: number;\n transport?: string;\n}\n\ninterface RTCIceCandidateComplete {\n}\n\ninterface RTCIceCandidateDictionary {\n foundation?: string;\n ip?: string;\n msMTurnSessionId?: string;\n port?: number;\n priority?: number;\n protocol?: RTCIceProtocol;\n relatedAddress?: string;\n relatedPort?: number;\n tcpType?: RTCIceTcpCandidateType;\n type?: RTCIceCandidateType;\n}\n\ninterface RTCIceCandidateInit {\n candidate?: string;\n sdpMid?: string;\n sdpMLineIndex?: number;\n}\n\ninterface RTCIceCandidatePair {\n local?: RTCIceCandidateDictionary;\n remote?: RTCIceCandidateDictionary;\n}\n\ninterface RTCIceCandidatePairStats extends RTCStats {\n availableIncomingBitrate?: number;\n availableOutgoingBitrate?: number;\n bytesReceived?: number;\n bytesSent?: number;\n localCandidateId?: string;\n nominated?: boolean;\n priority?: number;\n readable?: boolean;\n remoteCandidateId?: string;\n roundTripTime?: number;\n state?: RTCStatsIceCandidatePairState;\n transportId?: string;\n writable?: boolean;\n}\n\ninterface RTCIceGatherOptions {\n gatherPolicy?: RTCIceGatherPolicy;\n iceservers?: RTCIceServer[];\n portRange?: MSPortRange;\n}\n\ninterface RTCIceParameters {\n iceLite?: boolean;\n password?: string;\n usernameFragment?: string;\n}\n\ninterface RTCIceServer {\n credential?: string;\n urls?: any;\n username?: string;\n}\n\ninterface RTCInboundRTPStreamStats extends RTCRTPStreamStats {\n bytesReceived?: number;\n fractionLost?: number;\n jitter?: number;\n packetsLost?: number;\n packetsReceived?: number;\n}\n\ninterface RTCMediaStreamTrackStats extends RTCStats {\n audioLevel?: number;\n echoReturnLoss?: number;\n echoReturnLossEnhancement?: number;\n frameHeight?: number;\n framesCorrupted?: number;\n framesDecoded?: number;\n framesDropped?: number;\n framesPerSecond?: number;\n framesReceived?: number;\n framesSent?: number;\n frameWidth?: number;\n remoteSource?: boolean;\n ssrcIds?: string[];\n trackIdentifier?: string;\n}\n\ninterface RTCOfferOptions {\n iceRestart?: boolean;\n offerToReceiveAudio?: number;\n offerToReceiveVideo?: number;\n voiceActivityDetection?: boolean;\n}\n\ninterface RTCOutboundRTPStreamStats extends RTCRTPStreamStats {\n bytesSent?: number;\n packetsSent?: number;\n roundTripTime?: number;\n targetBitrate?: number;\n}\n\ninterface RTCPeerConnectionIceEventInit extends EventInit {\n candidate?: RTCIceCandidate;\n}\n\ninterface RTCRtcpFeedback {\n parameter?: string;\n type?: string;\n}\n\ninterface RTCRtcpParameters {\n cname?: string;\n mux?: boolean;\n reducedSize?: boolean;\n ssrc?: number;\n}\n\ninterface RTCRtpCapabilities {\n codecs?: RTCRtpCodecCapability[];\n fecMechanisms?: string[];\n headerExtensions?: RTCRtpHeaderExtension[];\n}\n\ninterface RTCRtpCodecCapability {\n clockRate?: number;\n kind?: string;\n maxptime?: number;\n maxSpatialLayers?: number;\n maxTemporalLayers?: number;\n name?: string;\n numChannels?: number;\n options?: any;\n parameters?: any;\n preferredPayloadType?: number;\n ptime?: number;\n rtcpFeedback?: RTCRtcpFeedback[];\n svcMultiStreamSupport?: boolean;\n}\n\ninterface RTCRtpCodecParameters {\n clockRate?: number;\n maxptime?: number;\n name?: string;\n numChannels?: number;\n parameters?: any;\n payloadType?: any;\n ptime?: number;\n rtcpFeedback?: RTCRtcpFeedback[];\n}\n\ninterface RTCRtpContributingSource {\n audioLevel?: number;\n csrc?: number;\n timestamp?: number;\n}\n\ninterface RTCRtpEncodingParameters {\n active?: boolean;\n codecPayloadType?: number;\n dependencyEncodingIds?: string[];\n encodingId?: string;\n fec?: RTCRtpFecParameters;\n framerateScale?: number;\n maxBitrate?: number;\n maxFramerate?: number;\n minQuality?: number;\n priority?: number;\n resolutionScale?: number;\n rtx?: RTCRtpRtxParameters;\n ssrc?: number;\n ssrcRange?: RTCSsrcRange;\n}\n\ninterface RTCRtpFecParameters {\n mechanism?: string;\n ssrc?: number;\n}\n\ninterface RTCRtpHeaderExtension {\n kind?: string;\n preferredEncrypt?: boolean;\n preferredId?: number;\n uri?: string;\n}\n\ninterface RTCRtpHeaderExtensionParameters {\n encrypt?: boolean;\n id?: number;\n uri?: string;\n}\n\ninterface RTCRtpParameters {\n codecs?: RTCRtpCodecParameters[];\n degradationPreference?: RTCDegradationPreference;\n encodings?: RTCRtpEncodingParameters[];\n headerExtensions?: RTCRtpHeaderExtensionParameters[];\n muxId?: string;\n rtcp?: RTCRtcpParameters;\n}\n\ninterface RTCRtpRtxParameters {\n ssrc?: number;\n}\n\ninterface RTCRTPStreamStats extends RTCStats {\n associateStatsId?: string;\n codecId?: string;\n firCount?: number;\n isRemote?: boolean;\n mediaTrackId?: string;\n nackCount?: number;\n pliCount?: number;\n sliCount?: number;\n ssrc?: string;\n transportId?: string;\n}\n\ninterface RTCRtpUnhandled {\n muxId?: string;\n payloadType?: number;\n ssrc?: number;\n}\n\ninterface RTCSessionDescriptionInit {\n sdp?: string;\n type?: RTCSdpType;\n}\n\ninterface RTCSrtpKeyParam {\n keyMethod?: string;\n keySalt?: string;\n lifetime?: string;\n mkiLength?: number;\n mkiValue?: number;\n}\n\ninterface RTCSrtpSdesParameters {\n cryptoSuite?: string;\n keyParams?: RTCSrtpKeyParam[];\n sessionParams?: string[];\n tag?: number;\n}\n\ninterface RTCSsrcRange {\n max?: number;\n min?: number;\n}\n\ninterface RTCStats {\n id?: string;\n msType?: MSStatsType;\n timestamp?: number;\n type?: RTCStatsType;\n}\n\ninterface RTCStatsReport {\n}\n\ninterface RTCTransportStats extends RTCStats {\n activeConnection?: boolean;\n bytesReceived?: number;\n bytesSent?: number;\n localCertificateId?: string;\n remoteCertificateId?: string;\n rtcpTransportStatsId?: string;\n selectedCandidatePairId?: string;\n}\n\ninterface ScopedCredentialDescriptor {\n id?: any;\n transports?: Transport[];\n type?: ScopedCredentialType;\n}\n\ninterface ScopedCredentialOptions {\n excludeList?: ScopedCredentialDescriptor[];\n extensions?: WebAuthnExtensions;\n rpId?: USVString;\n timeoutSeconds?: number;\n}\n\ninterface ScopedCredentialParameters {\n algorithm?: string | Algorithm;\n type?: ScopedCredentialType;\n}\n\ninterface ServiceWorkerMessageEventInit extends EventInit {\n data?: any;\n lastEventId?: string;\n origin?: string;\n ports?: MessagePort[];\n source?: ServiceWorker | MessagePort;\n}\n\ninterface SpeechSynthesisEventInit extends EventInit {\n charIndex?: number;\n elapsedTime?: number;\n name?: string;\n utterance?: SpeechSynthesisUtterance;\n}\n\ninterface StoreExceptionsInformation extends ExceptionInformation {\n detailURI?: string;\n explanationString?: string;\n siteName?: string;\n}\n\ninterface StoreSiteSpecificExceptionsInformation extends StoreExceptionsInformation {\n arrayOfDomainStrings?: string[];\n}\n\ninterface TrackEventInit extends EventInit {\n track?: VideoTrack | AudioTrack | TextTrack;\n}\n\ninterface TransitionEventInit extends EventInit {\n elapsedTime?: number;\n propertyName?: string;\n}\n\ninterface UIEventInit extends EventInit {\n detail?: number;\n view?: Window;\n}\n\ninterface WebAuthnExtensions {\n}\n\ninterface WebGLContextAttributes {\n failIfMajorPerformanceCaveat?: boolean;\n alpha?: boolean;\n antialias?: boolean;\n depth?: boolean;\n premultipliedAlpha?: boolean;\n preserveDrawingBuffer?: boolean;\n stencil?: boolean;\n}\n\ninterface WebGLContextEventInit extends EventInit {\n statusMessage?: string;\n}\n\ninterface WheelEventInit extends MouseEventInit {\n deltaMode?: number;\n deltaX?: number;\n deltaY?: number;\n deltaZ?: number;\n}\n\ninterface EventListener {\n (evt: Event): void;\n}\n\ninterface WebKitEntriesCallback {\n (evt: Event): void;\n}\n\ninterface WebKitErrorCallback {\n (evt: Event): void;\n}\n\ninterface WebKitFileCallback {\n (evt: Event): void;\n}\n\ninterface AnalyserNode extends AudioNode {\n fftSize: number;\n readonly frequencyBinCount: number;\n maxDecibels: number;\n minDecibels: number;\n smoothingTimeConstant: number;\n getByteFrequencyData(array: Uint8Array): void;\n getByteTimeDomainData(array: Uint8Array): void;\n getFloatFrequencyData(array: Float32Array): void;\n getFloatTimeDomainData(array: Float32Array): void;\n}\n\ndeclare var AnalyserNode: {\n prototype: AnalyserNode;\n new(): AnalyserNode;\n};\n\ninterface ANGLE_instanced_arrays {\n drawArraysInstancedANGLE(mode: number, first: number, count: number, primcount: number): void;\n drawElementsInstancedANGLE(mode: number, count: number, type: number, offset: number, primcount: number): void;\n vertexAttribDivisorANGLE(index: number, divisor: number): void;\n readonly VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE: number;\n}\n\ndeclare var ANGLE_instanced_arrays: {\n prototype: ANGLE_instanced_arrays;\n new(): ANGLE_instanced_arrays;\n readonly VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE: number;\n};\n\ninterface AnimationEvent extends Event {\n readonly animationName: string;\n readonly elapsedTime: number;\n initAnimationEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, animationNameArg: string, elapsedTimeArg: number): void;\n}\n\ndeclare var AnimationEvent: {\n prototype: AnimationEvent;\n new(typeArg: string, eventInitDict?: AnimationEventInit): AnimationEvent;\n};\n\ninterface ApplicationCacheEventMap {\n \"cached\": Event;\n \"checking\": Event;\n \"downloading\": Event;\n \"error\": Event;\n \"noupdate\": Event;\n \"obsolete\": Event;\n \"progress\": ProgressEvent;\n \"updateready\": Event;\n}\n\ninterface ApplicationCache extends EventTarget {\n oncached: (this: ApplicationCache, ev: Event) => any;\n onchecking: (this: ApplicationCache, ev: Event) => any;\n ondownloading: (this: ApplicationCache, ev: Event) => any;\n onerror: (this: ApplicationCache, ev: Event) => any;\n onnoupdate: (this: ApplicationCache, ev: Event) => any;\n onobsolete: (this: ApplicationCache, ev: Event) => any;\n onprogress: (this: ApplicationCache, ev: ProgressEvent) => any;\n onupdateready: (this: ApplicationCache, ev: Event) => any;\n readonly status: number;\n abort(): void;\n swapCache(): void;\n update(): void;\n readonly CHECKING: number;\n readonly DOWNLOADING: number;\n readonly IDLE: number;\n readonly OBSOLETE: number;\n readonly UNCACHED: number;\n readonly UPDATEREADY: number;\n addEventListener(type: K, listener: (this: ApplicationCache, ev: ApplicationCacheEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ApplicationCache: {\n prototype: ApplicationCache;\n new(): ApplicationCache;\n readonly CHECKING: number;\n readonly DOWNLOADING: number;\n readonly IDLE: number;\n readonly OBSOLETE: number;\n readonly UNCACHED: number;\n readonly UPDATEREADY: number;\n};\n\ninterface Attr extends Node {\n readonly name: string;\n readonly ownerElement: Element;\n readonly prefix: string | null;\n readonly specified: boolean;\n value: string;\n}\n\ndeclare var Attr: {\n prototype: Attr;\n new(): Attr;\n};\n\ninterface AudioBuffer {\n readonly duration: number;\n readonly length: number;\n readonly numberOfChannels: number;\n readonly sampleRate: number;\n copyFromChannel(destination: Float32Array, channelNumber: number, startInChannel?: number): void;\n copyToChannel(source: Float32Array, channelNumber: number, startInChannel?: number): void;\n getChannelData(channel: number): Float32Array;\n}\n\ndeclare var AudioBuffer: {\n prototype: AudioBuffer;\n new(): AudioBuffer;\n};\n\ninterface AudioBufferSourceNodeEventMap {\n \"ended\": MediaStreamErrorEvent;\n}\n\ninterface AudioBufferSourceNode extends AudioNode {\n buffer: AudioBuffer | null;\n readonly detune: AudioParam;\n loop: boolean;\n loopEnd: number;\n loopStart: number;\n onended: (this: AudioBufferSourceNode, ev: MediaStreamErrorEvent) => any;\n readonly playbackRate: AudioParam;\n start(when?: number, offset?: number, duration?: number): void;\n stop(when?: number): void;\n addEventListener(type: K, listener: (this: AudioBufferSourceNode, ev: AudioBufferSourceNodeEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var AudioBufferSourceNode: {\n prototype: AudioBufferSourceNode;\n new(): AudioBufferSourceNode;\n};\n\ninterface AudioContextEventMap {\n \"statechange\": Event;\n}\n\ninterface AudioContextBase extends EventTarget {\n readonly currentTime: number;\n readonly destination: AudioDestinationNode;\n readonly listener: AudioListener;\n onstatechange: (this: AudioContext, ev: Event) => any;\n readonly sampleRate: number;\n readonly state: AudioContextState;\n close(): Promise;\n createAnalyser(): AnalyserNode;\n createBiquadFilter(): BiquadFilterNode;\n createBuffer(numberOfChannels: number, length: number, sampleRate: number): AudioBuffer;\n createBufferSource(): AudioBufferSourceNode;\n createChannelMerger(numberOfInputs?: number): ChannelMergerNode;\n createChannelSplitter(numberOfOutputs?: number): ChannelSplitterNode;\n createConvolver(): ConvolverNode;\n createDelay(maxDelayTime?: number): DelayNode;\n createDynamicsCompressor(): DynamicsCompressorNode;\n createGain(): GainNode;\n createIIRFilter(feedforward: number[], feedback: number[]): IIRFilterNode;\n createMediaElementSource(mediaElement: HTMLMediaElement): MediaElementAudioSourceNode;\n createMediaStreamSource(mediaStream: MediaStream): MediaStreamAudioSourceNode;\n createOscillator(): OscillatorNode;\n createPanner(): PannerNode;\n createPeriodicWave(real: Float32Array, imag: Float32Array, constraints?: PeriodicWaveConstraints): PeriodicWave;\n createScriptProcessor(bufferSize?: number, numberOfInputChannels?: number, numberOfOutputChannels?: number): ScriptProcessorNode;\n createStereoPanner(): StereoPannerNode;\n createWaveShaper(): WaveShaperNode;\n decodeAudioData(audioData: ArrayBuffer, successCallback?: DecodeSuccessCallback, errorCallback?: DecodeErrorCallback): Promise;\n resume(): Promise;\n addEventListener(type: K, listener: (this: AudioContext, ev: AudioContextEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface AudioContext extends AudioContextBase {\n suspend(): Promise;\n}\n\ndeclare var AudioContext: {\n prototype: AudioContext;\n new(): AudioContext;\n};\n\ninterface AudioDestinationNode extends AudioNode {\n readonly maxChannelCount: number;\n}\n\ndeclare var AudioDestinationNode: {\n prototype: AudioDestinationNode;\n new(): AudioDestinationNode;\n};\n\ninterface AudioListener {\n dopplerFactor: number;\n speedOfSound: number;\n setOrientation(x: number, y: number, z: number, xUp: number, yUp: number, zUp: number): void;\n setPosition(x: number, y: number, z: number): void;\n setVelocity(x: number, y: number, z: number): void;\n}\n\ndeclare var AudioListener: {\n prototype: AudioListener;\n new(): AudioListener;\n};\n\ninterface AudioNode extends EventTarget {\n channelCount: number;\n channelCountMode: ChannelCountMode;\n channelInterpretation: ChannelInterpretation;\n readonly context: AudioContext;\n readonly numberOfInputs: number;\n readonly numberOfOutputs: number;\n connect(destination: AudioNode, output?: number, input?: number): AudioNode;\n connect(destination: AudioParam, output?: number): void;\n disconnect(output?: number): void;\n disconnect(destination: AudioNode, output?: number, input?: number): void;\n disconnect(destination: AudioParam, output?: number): void;\n}\n\ndeclare var AudioNode: {\n prototype: AudioNode;\n new(): AudioNode;\n};\n\ninterface AudioParam {\n readonly defaultValue: number;\n value: number;\n cancelScheduledValues(startTime: number): AudioParam;\n exponentialRampToValueAtTime(value: number, endTime: number): AudioParam;\n linearRampToValueAtTime(value: number, endTime: number): AudioParam;\n setTargetAtTime(target: number, startTime: number, timeConstant: number): AudioParam;\n setValueAtTime(value: number, startTime: number): AudioParam;\n setValueCurveAtTime(values: Float32Array, startTime: number, duration: number): AudioParam;\n}\n\ndeclare var AudioParam: {\n prototype: AudioParam;\n new(): AudioParam;\n};\n\ninterface AudioProcessingEvent extends Event {\n readonly inputBuffer: AudioBuffer;\n readonly outputBuffer: AudioBuffer;\n readonly playbackTime: number;\n}\n\ndeclare var AudioProcessingEvent: {\n prototype: AudioProcessingEvent;\n new(): AudioProcessingEvent;\n};\n\ninterface AudioTrack {\n enabled: boolean;\n readonly id: string;\n kind: string;\n readonly label: string;\n language: string;\n readonly sourceBuffer: SourceBuffer;\n}\n\ndeclare var AudioTrack: {\n prototype: AudioTrack;\n new(): AudioTrack;\n};\n\ninterface AudioTrackListEventMap {\n \"addtrack\": TrackEvent;\n \"change\": Event;\n \"removetrack\": TrackEvent;\n}\n\ninterface AudioTrackList extends EventTarget {\n readonly length: number;\n onaddtrack: (this: AudioTrackList, ev: TrackEvent) => any;\n onchange: (this: AudioTrackList, ev: Event) => any;\n onremovetrack: (this: AudioTrackList, ev: TrackEvent) => any;\n getTrackById(id: string): AudioTrack | null;\n item(index: number): AudioTrack;\n addEventListener(type: K, listener: (this: AudioTrackList, ev: AudioTrackListEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [index: number]: AudioTrack;\n}\n\ndeclare var AudioTrackList: {\n prototype: AudioTrackList;\n new(): AudioTrackList;\n};\n\ninterface BarProp {\n readonly visible: boolean;\n}\n\ndeclare var BarProp: {\n prototype: BarProp;\n new(): BarProp;\n};\n\ninterface BeforeUnloadEvent extends Event {\n returnValue: any;\n}\n\ndeclare var BeforeUnloadEvent: {\n prototype: BeforeUnloadEvent;\n new(): BeforeUnloadEvent;\n};\n\ninterface BiquadFilterNode extends AudioNode {\n readonly detune: AudioParam;\n readonly frequency: AudioParam;\n readonly gain: AudioParam;\n readonly Q: AudioParam;\n type: BiquadFilterType;\n getFrequencyResponse(frequencyHz: Float32Array, magResponse: Float32Array, phaseResponse: Float32Array): void;\n}\n\ndeclare var BiquadFilterNode: {\n prototype: BiquadFilterNode;\n new(): BiquadFilterNode;\n};\n\ninterface Blob {\n readonly size: number;\n readonly type: string;\n msClose(): void;\n msDetachStream(): any;\n slice(start?: number, end?: number, contentType?: string): Blob;\n}\n\ndeclare var Blob: {\n prototype: Blob;\n new (blobParts?: any[], options?: BlobPropertyBag): Blob;\n};\n\ninterface Cache {\n add(request: RequestInfo): Promise;\n addAll(requests: RequestInfo[]): Promise;\n delete(request: RequestInfo, options?: CacheQueryOptions): Promise;\n keys(request?: RequestInfo, options?: CacheQueryOptions): any;\n match(request: RequestInfo, options?: CacheQueryOptions): Promise;\n matchAll(request?: RequestInfo, options?: CacheQueryOptions): any;\n put(request: RequestInfo, response: Response): Promise;\n}\n\ndeclare var Cache: {\n prototype: Cache;\n new(): Cache;\n};\n\ninterface CacheStorage {\n delete(cacheName: string): Promise;\n has(cacheName: string): Promise;\n keys(): any;\n match(request: RequestInfo, options?: CacheQueryOptions): Promise;\n open(cacheName: string): Promise;\n}\n\ndeclare var CacheStorage: {\n prototype: CacheStorage;\n new(): CacheStorage;\n};\n\ninterface CanvasGradient {\n addColorStop(offset: number, color: string): void;\n}\n\ndeclare var CanvasGradient: {\n prototype: CanvasGradient;\n new(): CanvasGradient;\n};\n\ninterface CanvasPattern {\n setTransform(matrix: SVGMatrix): void;\n}\n\ndeclare var CanvasPattern: {\n prototype: CanvasPattern;\n new(): CanvasPattern;\n};\n\ninterface CanvasRenderingContext2D extends Object, CanvasPathMethods {\n readonly canvas: HTMLCanvasElement;\n fillStyle: string | CanvasGradient | CanvasPattern;\n font: string;\n globalAlpha: number;\n globalCompositeOperation: string;\n imageSmoothingEnabled: boolean;\n lineCap: string;\n lineDashOffset: number;\n lineJoin: string;\n lineWidth: number;\n miterLimit: number;\n msFillRule: CanvasFillRule;\n shadowBlur: number;\n shadowColor: string;\n shadowOffsetX: number;\n shadowOffsetY: number;\n strokeStyle: string | CanvasGradient | CanvasPattern;\n textAlign: string;\n textBaseline: string;\n mozImageSmoothingEnabled: boolean;\n webkitImageSmoothingEnabled: boolean;\n oImageSmoothingEnabled: boolean;\n beginPath(): void;\n clearRect(x: number, y: number, w: number, h: number): void;\n clip(fillRule?: CanvasFillRule): void;\n createImageData(imageDataOrSw: number | ImageData, sh?: number): ImageData;\n createLinearGradient(x0: number, y0: number, x1: number, y1: number): CanvasGradient;\n createPattern(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement, repetition: string): CanvasPattern;\n createRadialGradient(x0: number, y0: number, r0: number, x1: number, y1: number, r1: number): CanvasGradient;\n drawFocusIfNeeded(element: Element): void;\n drawImage(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, dstX: number, dstY: number): void;\n drawImage(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, dstX: number, dstY: number, dstW: number, dstH: number): void;\n drawImage(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, srcX: number, srcY: number, srcW: number, srcH: number, dstX: number, dstY: number, dstW: number, dstH: number): void;\n fill(fillRule?: CanvasFillRule): void;\n fillRect(x: number, y: number, w: number, h: number): void;\n fillText(text: string, x: number, y: number, maxWidth?: number): void;\n getImageData(sx: number, sy: number, sw: number, sh: number): ImageData;\n getLineDash(): number[];\n isPointInPath(x: number, y: number, fillRule?: CanvasFillRule): boolean;\n measureText(text: string): TextMetrics;\n putImageData(imagedata: ImageData, dx: number, dy: number, dirtyX?: number, dirtyY?: number, dirtyWidth?: number, dirtyHeight?: number): void;\n restore(): void;\n rotate(angle: number): void;\n save(): void;\n scale(x: number, y: number): void;\n setLineDash(segments: number[]): void;\n setTransform(m11: number, m12: number, m21: number, m22: number, dx: number, dy: number): void;\n stroke(path?: Path2D): void;\n strokeRect(x: number, y: number, w: number, h: number): void;\n strokeText(text: string, x: number, y: number, maxWidth?: number): void;\n transform(m11: number, m12: number, m21: number, m22: number, dx: number, dy: number): void;\n translate(x: number, y: number): void;\n}\n\ndeclare var CanvasRenderingContext2D: {\n prototype: CanvasRenderingContext2D;\n new(): CanvasRenderingContext2D;\n};\n\ninterface CDATASection extends Text {\n}\n\ndeclare var CDATASection: {\n prototype: CDATASection;\n new(): CDATASection;\n};\n\ninterface ChannelMergerNode extends AudioNode {\n}\n\ndeclare var ChannelMergerNode: {\n prototype: ChannelMergerNode;\n new(): ChannelMergerNode;\n};\n\ninterface ChannelSplitterNode extends AudioNode {\n}\n\ndeclare var ChannelSplitterNode: {\n prototype: ChannelSplitterNode;\n new(): ChannelSplitterNode;\n};\n\ninterface CharacterData extends Node, ChildNode {\n data: string;\n readonly length: number;\n appendData(arg: string): void;\n deleteData(offset: number, count: number): void;\n insertData(offset: number, arg: string): void;\n replaceData(offset: number, count: number, arg: string): void;\n substringData(offset: number, count: number): string;\n}\n\ndeclare var CharacterData: {\n prototype: CharacterData;\n new(): CharacterData;\n};\n\ninterface ClientRect {\n bottom: number;\n readonly height: number;\n left: number;\n right: number;\n top: number;\n readonly width: number;\n}\n\ndeclare var ClientRect: {\n prototype: ClientRect;\n new(): ClientRect;\n};\n\ninterface ClientRectList {\n readonly length: number;\n item(index: number): ClientRect;\n [index: number]: ClientRect;\n}\n\ndeclare var ClientRectList: {\n prototype: ClientRectList;\n new(): ClientRectList;\n};\n\ninterface ClipboardEvent extends Event {\n readonly clipboardData: DataTransfer;\n}\n\ndeclare var ClipboardEvent: {\n prototype: ClipboardEvent;\n new(type: string, eventInitDict?: ClipboardEventInit): ClipboardEvent;\n};\n\ninterface CloseEvent extends Event {\n readonly code: number;\n readonly reason: string;\n readonly wasClean: boolean;\n initCloseEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, wasCleanArg: boolean, codeArg: number, reasonArg: string): void;\n}\n\ndeclare var CloseEvent: {\n prototype: CloseEvent;\n new(typeArg: string, eventInitDict?: CloseEventInit): CloseEvent;\n};\n\ninterface Comment extends CharacterData {\n text: string;\n}\n\ndeclare var Comment: {\n prototype: Comment;\n new(): Comment;\n};\n\ninterface CompositionEvent extends UIEvent {\n readonly data: string;\n readonly locale: string;\n initCompositionEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, dataArg: string, locale: string): void;\n}\n\ndeclare var CompositionEvent: {\n prototype: CompositionEvent;\n new(typeArg: string, eventInitDict?: CompositionEventInit): CompositionEvent;\n};\n\ninterface Console {\n assert(test?: boolean, message?: string, ...optionalParams: any[]): void;\n clear(): void;\n count(countTitle?: string): void;\n debug(message?: any, ...optionalParams: any[]): void;\n dir(value?: any, ...optionalParams: any[]): void;\n dirxml(value: any): void;\n error(message?: any, ...optionalParams: any[]): void;\n exception(message?: string, ...optionalParams: any[]): void;\n group(groupTitle?: string, ...optionalParams: any[]): void;\n groupCollapsed(groupTitle?: string, ...optionalParams: any[]): void;\n groupEnd(): void;\n info(message?: any, ...optionalParams: any[]): void;\n log(message?: any, ...optionalParams: any[]): void;\n msIsIndependentlyComposed(element: Element): boolean;\n profile(reportName?: string): void;\n profileEnd(): void;\n select(element: Element): void;\n table(...data: any[]): void;\n time(timerName?: string): void;\n timeEnd(timerName?: string): void;\n trace(message?: any, ...optionalParams: any[]): void;\n warn(message?: any, ...optionalParams: any[]): void;\n}\n\ndeclare var Console: {\n prototype: Console;\n new(): Console;\n};\n\ninterface ConvolverNode extends AudioNode {\n buffer: AudioBuffer | null;\n normalize: boolean;\n}\n\ndeclare var ConvolverNode: {\n prototype: ConvolverNode;\n new(): ConvolverNode;\n};\n\ninterface Coordinates {\n readonly accuracy: number;\n readonly altitude: number | null;\n readonly altitudeAccuracy: number | null;\n readonly heading: number | null;\n readonly latitude: number;\n readonly longitude: number;\n readonly speed: number | null;\n}\n\ndeclare var Coordinates: {\n prototype: Coordinates;\n new(): Coordinates;\n};\n\ninterface Crypto extends Object, RandomSource {\n readonly subtle: SubtleCrypto;\n}\n\ndeclare var Crypto: {\n prototype: Crypto;\n new(): Crypto;\n};\n\ninterface CryptoKey {\n readonly algorithm: KeyAlgorithm;\n readonly extractable: boolean;\n readonly type: string;\n readonly usages: string[];\n}\n\ndeclare var CryptoKey: {\n prototype: CryptoKey;\n new(): CryptoKey;\n};\n\ninterface CryptoKeyPair {\n privateKey: CryptoKey;\n publicKey: CryptoKey;\n}\n\ndeclare var CryptoKeyPair: {\n prototype: CryptoKeyPair;\n new(): CryptoKeyPair;\n};\n\ninterface CSS {\n supports(property: string, value?: string): boolean;\n}\ndeclare var CSS: CSS;\n\ninterface CSSConditionRule extends CSSGroupingRule {\n conditionText: string;\n}\n\ndeclare var CSSConditionRule: {\n prototype: CSSConditionRule;\n new(): CSSConditionRule;\n};\n\ninterface CSSFontFaceRule extends CSSRule {\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSFontFaceRule: {\n prototype: CSSFontFaceRule;\n new(): CSSFontFaceRule;\n};\n\ninterface CSSGroupingRule extends CSSRule {\n readonly cssRules: CSSRuleList;\n deleteRule(index: number): void;\n insertRule(rule: string, index: number): number;\n}\n\ndeclare var CSSGroupingRule: {\n prototype: CSSGroupingRule;\n new(): CSSGroupingRule;\n};\n\ninterface CSSImportRule extends CSSRule {\n readonly href: string;\n readonly media: MediaList;\n readonly styleSheet: CSSStyleSheet;\n}\n\ndeclare var CSSImportRule: {\n prototype: CSSImportRule;\n new(): CSSImportRule;\n};\n\ninterface CSSKeyframeRule extends CSSRule {\n keyText: string;\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSKeyframeRule: {\n prototype: CSSKeyframeRule;\n new(): CSSKeyframeRule;\n};\n\ninterface CSSKeyframesRule extends CSSRule {\n readonly cssRules: CSSRuleList;\n name: string;\n appendRule(rule: string): void;\n deleteRule(rule: string): void;\n findRule(rule: string): CSSKeyframeRule;\n}\n\ndeclare var CSSKeyframesRule: {\n prototype: CSSKeyframesRule;\n new(): CSSKeyframesRule;\n};\n\ninterface CSSMediaRule extends CSSConditionRule {\n readonly media: MediaList;\n}\n\ndeclare var CSSMediaRule: {\n prototype: CSSMediaRule;\n new(): CSSMediaRule;\n};\n\ninterface CSSNamespaceRule extends CSSRule {\n readonly namespaceURI: string;\n readonly prefix: string;\n}\n\ndeclare var CSSNamespaceRule: {\n prototype: CSSNamespaceRule;\n new(): CSSNamespaceRule;\n};\n\ninterface CSSPageRule extends CSSRule {\n readonly pseudoClass: string;\n readonly selector: string;\n selectorText: string;\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSPageRule: {\n prototype: CSSPageRule;\n new(): CSSPageRule;\n};\n\ninterface CSSRule {\n cssText: string;\n readonly parentRule: CSSRule;\n readonly parentStyleSheet: CSSStyleSheet;\n readonly type: number;\n readonly CHARSET_RULE: number;\n readonly FONT_FACE_RULE: number;\n readonly IMPORT_RULE: number;\n readonly KEYFRAME_RULE: number;\n readonly KEYFRAMES_RULE: number;\n readonly MEDIA_RULE: number;\n readonly NAMESPACE_RULE: number;\n readonly PAGE_RULE: number;\n readonly STYLE_RULE: number;\n readonly SUPPORTS_RULE: number;\n readonly UNKNOWN_RULE: number;\n readonly VIEWPORT_RULE: number;\n}\n\ndeclare var CSSRule: {\n prototype: CSSRule;\n new(): CSSRule;\n readonly CHARSET_RULE: number;\n readonly FONT_FACE_RULE: number;\n readonly IMPORT_RULE: number;\n readonly KEYFRAME_RULE: number;\n readonly KEYFRAMES_RULE: number;\n readonly MEDIA_RULE: number;\n readonly NAMESPACE_RULE: number;\n readonly PAGE_RULE: number;\n readonly STYLE_RULE: number;\n readonly SUPPORTS_RULE: number;\n readonly UNKNOWN_RULE: number;\n readonly VIEWPORT_RULE: number;\n};\n\ninterface CSSRuleList {\n readonly length: number;\n item(index: number): CSSRule;\n [index: number]: CSSRule;\n}\n\ndeclare var CSSRuleList: {\n prototype: CSSRuleList;\n new(): CSSRuleList;\n};\n\ninterface CSSStyleDeclaration {\n alignContent: string | null;\n alignItems: string | null;\n alignmentBaseline: string | null;\n alignSelf: string | null;\n animation: string | null;\n animationDelay: string | null;\n animationDirection: string | null;\n animationDuration: string | null;\n animationFillMode: string | null;\n animationIterationCount: string | null;\n animationName: string | null;\n animationPlayState: string | null;\n animationTimingFunction: string | null;\n backfaceVisibility: string | null;\n background: string | null;\n backgroundAttachment: string | null;\n backgroundClip: string | null;\n backgroundColor: string | null;\n backgroundImage: string | null;\n backgroundOrigin: string | null;\n backgroundPosition: string | null;\n backgroundPositionX: string | null;\n backgroundPositionY: string | null;\n backgroundRepeat: string | null;\n backgroundSize: string | null;\n baselineShift: string | null;\n border: string | null;\n borderBottom: string | null;\n borderBottomColor: string | null;\n borderBottomLeftRadius: string | null;\n borderBottomRightRadius: string | null;\n borderBottomStyle: string | null;\n borderBottomWidth: string | null;\n borderCollapse: string | null;\n borderColor: string | null;\n borderImage: string | null;\n borderImageOutset: string | null;\n borderImageRepeat: string | null;\n borderImageSlice: string | null;\n borderImageSource: string | null;\n borderImageWidth: string | null;\n borderLeft: string | null;\n borderLeftColor: string | null;\n borderLeftStyle: string | null;\n borderLeftWidth: string | null;\n borderRadius: string | null;\n borderRight: string | null;\n borderRightColor: string | null;\n borderRightStyle: string | null;\n borderRightWidth: string | null;\n borderSpacing: string | null;\n borderStyle: string | null;\n borderTop: string | null;\n borderTopColor: string | null;\n borderTopLeftRadius: string | null;\n borderTopRightRadius: string | null;\n borderTopStyle: string | null;\n borderTopWidth: string | null;\n borderWidth: string | null;\n bottom: string | null;\n boxShadow: string | null;\n boxSizing: string | null;\n breakAfter: string | null;\n breakBefore: string | null;\n breakInside: string | null;\n captionSide: string | null;\n clear: string | null;\n clip: string | null;\n clipPath: string | null;\n clipRule: string | null;\n color: string | null;\n colorInterpolationFilters: string | null;\n columnCount: any;\n columnFill: string | null;\n columnGap: any;\n columnRule: string | null;\n columnRuleColor: any;\n columnRuleStyle: string | null;\n columnRuleWidth: any;\n columns: string | null;\n columnSpan: string | null;\n columnWidth: any;\n content: string | null;\n counterIncrement: string | null;\n counterReset: string | null;\n cssFloat: string | null;\n cssText: string;\n cursor: string | null;\n direction: string | null;\n display: string | null;\n dominantBaseline: string | null;\n emptyCells: string | null;\n enableBackground: string | null;\n fill: string | null;\n fillOpacity: string | null;\n fillRule: string | null;\n filter: string | null;\n flex: string | null;\n flexBasis: string | null;\n flexDirection: string | null;\n flexFlow: string | null;\n flexGrow: string | null;\n flexShrink: string | null;\n flexWrap: string | null;\n floodColor: string | null;\n floodOpacity: string | null;\n font: string | null;\n fontFamily: string | null;\n fontFeatureSettings: string | null;\n fontSize: string | null;\n fontSizeAdjust: string | null;\n fontStretch: string | null;\n fontStyle: string | null;\n fontVariant: string | null;\n fontWeight: string | null;\n glyphOrientationHorizontal: string | null;\n glyphOrientationVertical: string | null;\n height: string | null;\n imeMode: string | null;\n justifyContent: string | null;\n kerning: string | null;\n layoutGrid: string | null;\n layoutGridChar: string | null;\n layoutGridLine: string | null;\n layoutGridMode: string | null;\n layoutGridType: string | null;\n left: string | null;\n readonly length: number;\n letterSpacing: string | null;\n lightingColor: string | null;\n lineBreak: string | null;\n lineHeight: string | null;\n listStyle: string | null;\n listStyleImage: string | null;\n listStylePosition: string | null;\n listStyleType: string | null;\n margin: string | null;\n marginBottom: string | null;\n marginLeft: string | null;\n marginRight: string | null;\n marginTop: string | null;\n marker: string | null;\n markerEnd: string | null;\n markerMid: string | null;\n markerStart: string | null;\n mask: string | null;\n maxHeight: string | null;\n maxWidth: string | null;\n minHeight: string | null;\n minWidth: string | null;\n msContentZoomChaining: string | null;\n msContentZooming: string | null;\n msContentZoomLimit: string | null;\n msContentZoomLimitMax: any;\n msContentZoomLimitMin: any;\n msContentZoomSnap: string | null;\n msContentZoomSnapPoints: string | null;\n msContentZoomSnapType: string | null;\n msFlowFrom: string | null;\n msFlowInto: string | null;\n msFontFeatureSettings: string | null;\n msGridColumn: any;\n msGridColumnAlign: string | null;\n msGridColumns: string | null;\n msGridColumnSpan: any;\n msGridRow: any;\n msGridRowAlign: string | null;\n msGridRows: string | null;\n msGridRowSpan: any;\n msHighContrastAdjust: string | null;\n msHyphenateLimitChars: string | null;\n msHyphenateLimitLines: any;\n msHyphenateLimitZone: any;\n msHyphens: string | null;\n msImeAlign: string | null;\n msOverflowStyle: string | null;\n msScrollChaining: string | null;\n msScrollLimit: string | null;\n msScrollLimitXMax: any;\n msScrollLimitXMin: any;\n msScrollLimitYMax: any;\n msScrollLimitYMin: any;\n msScrollRails: string | null;\n msScrollSnapPointsX: string | null;\n msScrollSnapPointsY: string | null;\n msScrollSnapType: string | null;\n msScrollSnapX: string | null;\n msScrollSnapY: string | null;\n msScrollTranslation: string | null;\n msTextCombineHorizontal: string | null;\n msTextSizeAdjust: any;\n msTouchAction: string | null;\n msTouchSelect: string | null;\n msUserSelect: string | null;\n msWrapFlow: string;\n msWrapMargin: any;\n msWrapThrough: string;\n opacity: string | null;\n order: string | null;\n orphans: string | null;\n outline: string | null;\n outlineColor: string | null;\n outlineOffset: string | null;\n outlineStyle: string | null;\n outlineWidth: string | null;\n overflow: string | null;\n overflowX: string | null;\n overflowY: string | null;\n padding: string | null;\n paddingBottom: string | null;\n paddingLeft: string | null;\n paddingRight: string | null;\n paddingTop: string | null;\n pageBreakAfter: string | null;\n pageBreakBefore: string | null;\n pageBreakInside: string | null;\n readonly parentRule: CSSRule;\n perspective: string | null;\n perspectiveOrigin: string | null;\n pointerEvents: string | null;\n position: string | null;\n quotes: string | null;\n right: string | null;\n rotate: string | null;\n rubyAlign: string | null;\n rubyOverhang: string | null;\n rubyPosition: string | null;\n scale: string | null;\n stopColor: string | null;\n stopOpacity: string | null;\n stroke: string | null;\n strokeDasharray: string | null;\n strokeDashoffset: string | null;\n strokeLinecap: string | null;\n strokeLinejoin: string | null;\n strokeMiterlimit: string | null;\n strokeOpacity: string | null;\n strokeWidth: string | null;\n tableLayout: string | null;\n textAlign: string | null;\n textAlignLast: string | null;\n textAnchor: string | null;\n textDecoration: string | null;\n textIndent: string | null;\n textJustify: string | null;\n textKashida: string | null;\n textKashidaSpace: string | null;\n textOverflow: string | null;\n textShadow: string | null;\n textTransform: string | null;\n textUnderlinePosition: string | null;\n top: string | null;\n touchAction: string | null;\n transform: string | null;\n transformOrigin: string | null;\n transformStyle: string | null;\n transition: string | null;\n transitionDelay: string | null;\n transitionDuration: string | null;\n transitionProperty: string | null;\n transitionTimingFunction: string | null;\n translate: string | null;\n unicodeBidi: string | null;\n verticalAlign: string | null;\n visibility: string | null;\n webkitAlignContent: string | null;\n webkitAlignItems: string | null;\n webkitAlignSelf: string | null;\n webkitAnimation: string | null;\n webkitAnimationDelay: string | null;\n webkitAnimationDirection: string | null;\n webkitAnimationDuration: string | null;\n webkitAnimationFillMode: string | null;\n webkitAnimationIterationCount: string | null;\n webkitAnimationName: string | null;\n webkitAnimationPlayState: string | null;\n webkitAnimationTimingFunction: string | null;\n webkitAppearance: string | null;\n webkitBackfaceVisibility: string | null;\n webkitBackgroundClip: string | null;\n webkitBackgroundOrigin: string | null;\n webkitBackgroundSize: string | null;\n webkitBorderBottomLeftRadius: string | null;\n webkitBorderBottomRightRadius: string | null;\n webkitBorderImage: string | null;\n webkitBorderRadius: string | null;\n webkitBorderTopLeftRadius: string | null;\n webkitBorderTopRightRadius: string | null;\n webkitBoxAlign: string | null;\n webkitBoxDirection: string | null;\n webkitBoxFlex: string | null;\n webkitBoxOrdinalGroup: string | null;\n webkitBoxOrient: string | null;\n webkitBoxPack: string | null;\n webkitBoxSizing: string | null;\n webkitColumnBreakAfter: string | null;\n webkitColumnBreakBefore: string | null;\n webkitColumnBreakInside: string | null;\n webkitColumnCount: any;\n webkitColumnGap: any;\n webkitColumnRule: string | null;\n webkitColumnRuleColor: any;\n webkitColumnRuleStyle: string | null;\n webkitColumnRuleWidth: any;\n webkitColumns: string | null;\n webkitColumnSpan: string | null;\n webkitColumnWidth: any;\n webkitFilter: string | null;\n webkitFlex: string | null;\n webkitFlexBasis: string | null;\n webkitFlexDirection: string | null;\n webkitFlexFlow: string | null;\n webkitFlexGrow: string | null;\n webkitFlexShrink: string | null;\n webkitFlexWrap: string | null;\n webkitJustifyContent: string | null;\n webkitOrder: string | null;\n webkitPerspective: string | null;\n webkitPerspectiveOrigin: string | null;\n webkitTapHighlightColor: string | null;\n webkitTextFillColor: string | null;\n webkitTextSizeAdjust: any;\n webkitTextStroke: string | null;\n webkitTextStrokeColor: string | null;\n webkitTextStrokeWidth: string | null;\n webkitTransform: string | null;\n webkitTransformOrigin: string | null;\n webkitTransformStyle: string | null;\n webkitTransition: string | null;\n webkitTransitionDelay: string | null;\n webkitTransitionDuration: string | null;\n webkitTransitionProperty: string | null;\n webkitTransitionTimingFunction: string | null;\n webkitUserModify: string | null;\n webkitUserSelect: string | null;\n webkitWritingMode: string | null;\n whiteSpace: string | null;\n widows: string | null;\n width: string | null;\n wordBreak: string | null;\n wordSpacing: string | null;\n wordWrap: string | null;\n writingMode: string | null;\n zIndex: string | null;\n zoom: string | null;\n resize: string | null;\n userSelect: string | null;\n getPropertyPriority(propertyName: string): string;\n getPropertyValue(propertyName: string): string;\n item(index: number): string;\n removeProperty(propertyName: string): string;\n setProperty(propertyName: string, value: string | null, priority?: string): void;\n [index: number]: string;\n}\n\ndeclare var CSSStyleDeclaration: {\n prototype: CSSStyleDeclaration;\n new(): CSSStyleDeclaration;\n};\n\ninterface CSSStyleRule extends CSSRule {\n readonly readOnly: boolean;\n selectorText: string;\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSStyleRule: {\n prototype: CSSStyleRule;\n new(): CSSStyleRule;\n};\n\ninterface CSSStyleSheet extends StyleSheet {\n readonly cssRules: CSSRuleList;\n cssText: string;\n readonly id: string;\n readonly imports: StyleSheetList;\n readonly isAlternate: boolean;\n readonly isPrefAlternate: boolean;\n readonly ownerRule: CSSRule;\n readonly owningElement: Element;\n readonly pages: StyleSheetPageList;\n readonly readOnly: boolean;\n readonly rules: CSSRuleList;\n addImport(bstrURL: string, lIndex?: number): number;\n addPageRule(bstrSelector: string, bstrStyle: string, lIndex?: number): number;\n addRule(bstrSelector: string, bstrStyle?: string, lIndex?: number): number;\n deleteRule(index?: number): void;\n insertRule(rule: string, index?: number): number;\n removeImport(lIndex: number): void;\n removeRule(lIndex: number): void;\n}\n\ndeclare var CSSStyleSheet: {\n prototype: CSSStyleSheet;\n new(): CSSStyleSheet;\n};\n\ninterface CSSSupportsRule extends CSSConditionRule {\n}\n\ndeclare var CSSSupportsRule: {\n prototype: CSSSupportsRule;\n new(): CSSSupportsRule;\n};\n\ninterface CustomEvent extends Event {\n readonly detail: any;\n initCustomEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, detailArg: any): void;\n}\n\ndeclare var CustomEvent: {\n prototype: CustomEvent;\n new(typeArg: string, eventInitDict?: CustomEventInit): CustomEvent;\n};\n\ninterface DataCue extends TextTrackCue {\n data: ArrayBuffer;\n addEventListener(type: K, listener: (this: DataCue, ev: TextTrackCueEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var DataCue: {\n prototype: DataCue;\n new(): DataCue;\n};\n\ninterface DataTransfer {\n dropEffect: string;\n effectAllowed: string;\n readonly files: FileList;\n readonly items: DataTransferItemList;\n readonly types: string[];\n clearData(format?: string): boolean;\n getData(format: string): string;\n setData(format: string, data: string): boolean;\n setDragImage(image: Element, x: number, y: number): void;\n}\n\ndeclare var DataTransfer: {\n prototype: DataTransfer;\n new(): DataTransfer;\n};\n\ninterface DataTransferItem {\n readonly kind: string;\n readonly type: string;\n getAsFile(): File | null;\n getAsString(_callback: FunctionStringCallback | null): void;\n webkitGetAsEntry(): any;\n}\n\ndeclare var DataTransferItem: {\n prototype: DataTransferItem;\n new(): DataTransferItem;\n};\n\ninterface DataTransferItemList {\n readonly length: number;\n add(data: File): DataTransferItem | null;\n clear(): void;\n item(index: number): DataTransferItem;\n remove(index: number): void;\n [index: number]: DataTransferItem;\n}\n\ndeclare var DataTransferItemList: {\n prototype: DataTransferItemList;\n new(): DataTransferItemList;\n};\n\ninterface DeferredPermissionRequest {\n readonly id: number;\n readonly type: MSWebViewPermissionType;\n readonly uri: string;\n allow(): void;\n deny(): void;\n}\n\ndeclare var DeferredPermissionRequest: {\n prototype: DeferredPermissionRequest;\n new(): DeferredPermissionRequest;\n};\n\ninterface DelayNode extends AudioNode {\n readonly delayTime: AudioParam;\n}\n\ndeclare var DelayNode: {\n prototype: DelayNode;\n new(): DelayNode;\n};\n\ninterface DeviceAcceleration {\n readonly x: number | null;\n readonly y: number | null;\n readonly z: number | null;\n}\n\ndeclare var DeviceAcceleration: {\n prototype: DeviceAcceleration;\n new(): DeviceAcceleration;\n};\n\ninterface DeviceLightEvent extends Event {\n readonly value: number;\n}\n\ndeclare var DeviceLightEvent: {\n prototype: DeviceLightEvent;\n new(typeArg: string, eventInitDict?: DeviceLightEventInit): DeviceLightEvent;\n};\n\ninterface DeviceMotionEvent extends Event {\n readonly acceleration: DeviceAcceleration | null;\n readonly accelerationIncludingGravity: DeviceAcceleration | null;\n readonly interval: number | null;\n readonly rotationRate: DeviceRotationRate | null;\n initDeviceMotionEvent(type: string, bubbles: boolean, cancelable: boolean, acceleration: DeviceAccelerationDict | null, accelerationIncludingGravity: DeviceAccelerationDict | null, rotationRate: DeviceRotationRateDict | null, interval: number | null): void;\n}\n\ndeclare var DeviceMotionEvent: {\n prototype: DeviceMotionEvent;\n new(typeArg: string, eventInitDict?: DeviceMotionEventInit): DeviceMotionEvent;\n};\n\ninterface DeviceOrientationEvent extends Event {\n readonly absolute: boolean;\n readonly alpha: number | null;\n readonly beta: number | null;\n readonly gamma: number | null;\n initDeviceOrientationEvent(type: string, bubbles: boolean, cancelable: boolean, alpha: number | null, beta: number | null, gamma: number | null, absolute: boolean): void;\n}\n\ndeclare var DeviceOrientationEvent: {\n prototype: DeviceOrientationEvent;\n new(typeArg: string, eventInitDict?: DeviceOrientationEventInit): DeviceOrientationEvent;\n};\n\ninterface DeviceRotationRate {\n readonly alpha: number | null;\n readonly beta: number | null;\n readonly gamma: number | null;\n}\n\ndeclare var DeviceRotationRate: {\n prototype: DeviceRotationRate;\n new(): DeviceRotationRate;\n};\n\ninterface DocumentEventMap extends GlobalEventHandlersEventMap {\n \"abort\": UIEvent;\n \"activate\": UIEvent;\n \"beforeactivate\": UIEvent;\n \"beforedeactivate\": UIEvent;\n \"blur\": FocusEvent;\n \"canplay\": Event;\n \"canplaythrough\": Event;\n \"change\": Event;\n \"click\": MouseEvent;\n \"contextmenu\": PointerEvent;\n \"dblclick\": MouseEvent;\n \"deactivate\": UIEvent;\n \"drag\": DragEvent;\n \"dragend\": DragEvent;\n \"dragenter\": DragEvent;\n \"dragleave\": DragEvent;\n \"dragover\": DragEvent;\n \"dragstart\": DragEvent;\n \"drop\": DragEvent;\n \"durationchange\": Event;\n \"emptied\": Event;\n \"ended\": MediaStreamErrorEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"fullscreenchange\": Event;\n \"fullscreenerror\": Event;\n \"input\": Event;\n \"invalid\": Event;\n \"keydown\": KeyboardEvent;\n \"keypress\": KeyboardEvent;\n \"keyup\": KeyboardEvent;\n \"load\": Event;\n \"loadeddata\": Event;\n \"loadedmetadata\": Event;\n \"loadstart\": Event;\n \"mousedown\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n \"mousewheel\": WheelEvent;\n \"MSContentZoom\": UIEvent;\n \"MSGestureChange\": MSGestureEvent;\n \"MSGestureDoubleTap\": MSGestureEvent;\n \"MSGestureEnd\": MSGestureEvent;\n \"MSGestureHold\": MSGestureEvent;\n \"MSGestureStart\": MSGestureEvent;\n \"MSGestureTap\": MSGestureEvent;\n \"MSInertiaStart\": MSGestureEvent;\n \"MSManipulationStateChanged\": MSManipulationEvent;\n \"MSPointerCancel\": MSPointerEvent;\n \"MSPointerDown\": MSPointerEvent;\n \"MSPointerEnter\": MSPointerEvent;\n \"MSPointerLeave\": MSPointerEvent;\n \"MSPointerMove\": MSPointerEvent;\n \"MSPointerOut\": MSPointerEvent;\n \"MSPointerOver\": MSPointerEvent;\n \"MSPointerUp\": MSPointerEvent;\n \"mssitemodejumplistitemremoved\": MSSiteModeEvent;\n \"msthumbnailclick\": MSSiteModeEvent;\n \"pause\": Event;\n \"play\": Event;\n \"playing\": Event;\n \"pointerlockchange\": Event;\n \"pointerlockerror\": Event;\n \"progress\": ProgressEvent;\n \"ratechange\": Event;\n \"readystatechange\": Event;\n \"reset\": Event;\n \"scroll\": UIEvent;\n \"seeked\": Event;\n \"seeking\": Event;\n \"select\": UIEvent;\n \"selectionchange\": Event;\n \"selectstart\": Event;\n \"stalled\": Event;\n \"stop\": Event;\n \"submit\": Event;\n \"suspend\": Event;\n \"timeupdate\": Event;\n \"touchcancel\": TouchEvent;\n \"touchend\": TouchEvent;\n \"touchmove\": TouchEvent;\n \"touchstart\": TouchEvent;\n \"volumechange\": Event;\n \"waiting\": Event;\n \"webkitfullscreenchange\": Event;\n \"webkitfullscreenerror\": Event;\n}\n\ninterface Document extends Node, GlobalEventHandlers, NodeSelector, DocumentEvent, ParentNode, DocumentOrShadowRoot {\n /**\n * Gets the object that has the focus when the parent document has focus.\n */\n readonly activeElement: Element;\n /**\n * Sets or gets the color of all active links in the document.\n */\n alinkColor: string;\n /**\n * Returns a reference to the collection of elements contained by the object.\n */\n readonly all: HTMLAllCollection;\n /**\n * Retrieves a collection of all a objects that have a name and/or id property. Objects in this collection are in HTML source order.\n */\n anchors: HTMLCollectionOf;\n /**\n * Retrieves a collection of all applet objects in the document.\n */\n applets: HTMLCollectionOf;\n /**\n * Deprecated. Sets or retrieves a value that indicates the background color behind the object.\n */\n bgColor: string;\n /**\n * Specifies the beginning and end of the document body.\n */\n body: HTMLElement;\n readonly characterSet: string;\n /**\n * Gets or sets the character set used to encode the object.\n */\n charset: string;\n /**\n * Gets a value that indicates whether standards-compliant mode is switched on for the object.\n */\n readonly compatMode: string;\n cookie: string;\n readonly currentScript: HTMLScriptElement | SVGScriptElement;\n readonly defaultView: Window;\n /**\n * Sets or gets a value that indicates whether the document can be edited.\n */\n designMode: string;\n /**\n * Sets or retrieves a value that indicates the reading order of the object.\n */\n dir: string;\n /**\n * Gets an object representing the document type declaration associated with the current document.\n */\n readonly doctype: DocumentType;\n /**\n * Gets a reference to the root node of the document.\n */\n documentElement: HTMLElement;\n /**\n * Sets or gets the security domain of the document.\n */\n domain: string;\n /**\n * Retrieves a collection of all embed objects in the document.\n */\n embeds: HTMLCollectionOf;\n /**\n * Sets or gets the foreground (text) color of the document.\n */\n fgColor: string;\n /**\n * Retrieves a collection, in source order, of all form objects in the document.\n */\n forms: HTMLCollectionOf;\n readonly fullscreenElement: Element | null;\n readonly fullscreenEnabled: boolean;\n readonly head: HTMLHeadElement;\n readonly hidden: boolean;\n /**\n * Retrieves a collection, in source order, of img objects in the document.\n */\n images: HTMLCollectionOf;\n /**\n * Gets the implementation object of the current document.\n */\n readonly implementation: DOMImplementation;\n /**\n * Returns the character encoding used to create the webpage that is loaded into the document object.\n */\n readonly inputEncoding: string | null;\n /**\n * Gets the date that the page was last modified, if the page supplies one.\n */\n readonly lastModified: string;\n /**\n * Sets or gets the color of the document links.\n */\n linkColor: string;\n /**\n * Retrieves a collection of all a objects that specify the href property and all area objects in the document.\n */\n links: HTMLCollectionOf;\n /**\n * Contains information about the current URL.\n */\n readonly location: Location;\n msCapsLockWarningOff: boolean;\n msCSSOMElementFloatMetrics: boolean;\n /**\n * Fires when the user aborts the download.\n * @param ev The event.\n */\n onabort: (this: Document, ev: UIEvent) => any;\n /**\n * Fires when the object is set as the active element.\n * @param ev The event.\n */\n onactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires immediately before the object is set as the active element.\n * @param ev The event.\n */\n onbeforeactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires immediately before the activeElement is changed from the current object to another object in the parent document.\n * @param ev The event.\n */\n onbeforedeactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires when the object loses the input focus.\n * @param ev The focus event.\n */\n onblur: (this: Document, ev: FocusEvent) => any;\n /**\n * Occurs when playback is possible, but would require further buffering.\n * @param ev The event.\n */\n oncanplay: (this: Document, ev: Event) => any;\n oncanplaythrough: (this: Document, ev: Event) => any;\n /**\n * Fires when the contents of the object or selection have changed.\n * @param ev The event.\n */\n onchange: (this: Document, ev: Event) => any;\n /**\n * Fires when the user clicks the left mouse button on the object\n * @param ev The mouse event.\n */\n onclick: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user clicks the right mouse button in the client area, opening the context menu.\n * @param ev The mouse event.\n */\n oncontextmenu: (this: Document, ev: PointerEvent) => any;\n /**\n * Fires when the user double-clicks the object.\n * @param ev The mouse event.\n */\n ondblclick: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the activeElement is changed from the current object to another object in the parent document.\n * @param ev The UI Event\n */\n ondeactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires on the source object continuously during a drag operation.\n * @param ev The event.\n */\n ondrag: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the source object when the user releases the mouse at the close of a drag operation.\n * @param ev The event.\n */\n ondragend: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the target element when the user drags the object to a valid drop target.\n * @param ev The drag event.\n */\n ondragenter: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the target object when the user moves the mouse out of a valid drop target during a drag operation.\n * @param ev The drag event.\n */\n ondragleave: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the target element continuously while the user drags the object over a valid drop target.\n * @param ev The event.\n */\n ondragover: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the source object when the user starts to drag a text selection or selected object.\n * @param ev The event.\n */\n ondragstart: (this: Document, ev: DragEvent) => any;\n ondrop: (this: Document, ev: DragEvent) => any;\n /**\n * Occurs when the duration attribute is updated.\n * @param ev The event.\n */\n ondurationchange: (this: Document, ev: Event) => any;\n /**\n * Occurs when the media element is reset to its initial state.\n * @param ev The event.\n */\n onemptied: (this: Document, ev: Event) => any;\n /**\n * Occurs when the end of playback is reached.\n * @param ev The event\n */\n onended: (this: Document, ev: MediaStreamErrorEvent) => any;\n /**\n * Fires when an error occurs during object loading.\n * @param ev The event.\n */\n onerror: (this: Document, ev: ErrorEvent) => any;\n /**\n * Fires when the object receives focus.\n * @param ev The event.\n */\n onfocus: (this: Document, ev: FocusEvent) => any;\n onfullscreenchange: (this: Document, ev: Event) => any;\n onfullscreenerror: (this: Document, ev: Event) => any;\n oninput: (this: Document, ev: Event) => any;\n oninvalid: (this: Document, ev: Event) => any;\n /**\n * Fires when the user presses a key.\n * @param ev The keyboard event\n */\n onkeydown: (this: Document, ev: KeyboardEvent) => any;\n /**\n * Fires when the user presses an alphanumeric key.\n * @param ev The event.\n */\n onkeypress: (this: Document, ev: KeyboardEvent) => any;\n /**\n * Fires when the user releases a key.\n * @param ev The keyboard event\n */\n onkeyup: (this: Document, ev: KeyboardEvent) => any;\n /**\n * Fires immediately after the browser loads the object.\n * @param ev The event.\n */\n onload: (this: Document, ev: Event) => any;\n /**\n * Occurs when media data is loaded at the current playback position.\n * @param ev The event.\n */\n onloadeddata: (this: Document, ev: Event) => any;\n /**\n * Occurs when the duration and dimensions of the media have been determined.\n * @param ev The event.\n */\n onloadedmetadata: (this: Document, ev: Event) => any;\n /**\n * Occurs when Internet Explorer begins looking for media data.\n * @param ev The event.\n */\n onloadstart: (this: Document, ev: Event) => any;\n /**\n * Fires when the user clicks the object with either mouse button.\n * @param ev The mouse event.\n */\n onmousedown: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user moves the mouse over the object.\n * @param ev The mouse event.\n */\n onmousemove: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user moves the mouse pointer outside the boundaries of the object.\n * @param ev The mouse event.\n */\n onmouseout: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user moves the mouse pointer into the object.\n * @param ev The mouse event.\n */\n onmouseover: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user releases a mouse button while the mouse is over the object.\n * @param ev The mouse event.\n */\n onmouseup: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the wheel button is rotated.\n * @param ev The mouse event\n */\n onmousewheel: (this: Document, ev: WheelEvent) => any;\n onmscontentzoom: (this: Document, ev: UIEvent) => any;\n onmsgesturechange: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturedoubletap: (this: Document, ev: MSGestureEvent) => any;\n onmsgestureend: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturehold: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturestart: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturetap: (this: Document, ev: MSGestureEvent) => any;\n onmsinertiastart: (this: Document, ev: MSGestureEvent) => any;\n onmsmanipulationstatechanged: (this: Document, ev: MSManipulationEvent) => any;\n onmspointercancel: (this: Document, ev: MSPointerEvent) => any;\n onmspointerdown: (this: Document, ev: MSPointerEvent) => any;\n onmspointerenter: (this: Document, ev: MSPointerEvent) => any;\n onmspointerleave: (this: Document, ev: MSPointerEvent) => any;\n onmspointermove: (this: Document, ev: MSPointerEvent) => any;\n onmspointerout: (this: Document, ev: MSPointerEvent) => any;\n onmspointerover: (this: Document, ev: MSPointerEvent) => any;\n onmspointerup: (this: Document, ev: MSPointerEvent) => any;\n /**\n * Occurs when an item is removed from a Jump List of a webpage running in Site Mode.\n * @param ev The event.\n */\n onmssitemodejumplistitemremoved: (this: Document, ev: MSSiteModeEvent) => any;\n /**\n * Occurs when a user clicks a button in a Thumbnail Toolbar of a webpage running in Site Mode.\n * @param ev The event.\n */\n onmsthumbnailclick: (this: Document, ev: MSSiteModeEvent) => any;\n /**\n * Occurs when playback is paused.\n * @param ev The event.\n */\n onpause: (this: Document, ev: Event) => any;\n /**\n * Occurs when the play method is requested.\n * @param ev The event.\n */\n onplay: (this: Document, ev: Event) => any;\n /**\n * Occurs when the audio or video has started playing.\n * @param ev The event.\n */\n onplaying: (this: Document, ev: Event) => any;\n onpointerlockchange: (this: Document, ev: Event) => any;\n onpointerlockerror: (this: Document, ev: Event) => any;\n /**\n * Occurs to indicate progress while downloading media data.\n * @param ev The event.\n */\n onprogress: (this: Document, ev: ProgressEvent) => any;\n /**\n * Occurs when the playback rate is increased or decreased.\n * @param ev The event.\n */\n onratechange: (this: Document, ev: Event) => any;\n /**\n * Fires when the state of the object has changed.\n * @param ev The event\n */\n onreadystatechange: (this: Document, ev: Event) => any;\n /**\n * Fires when the user resets a form.\n * @param ev The event.\n */\n onreset: (this: Document, ev: Event) => any;\n /**\n * Fires when the user repositions the scroll box in the scroll bar on the object.\n * @param ev The event.\n */\n onscroll: (this: Document, ev: UIEvent) => any;\n /**\n * Occurs when the seek operation ends.\n * @param ev The event.\n */\n onseeked: (this: Document, ev: Event) => any;\n /**\n * Occurs when the current playback position is moved.\n * @param ev The event.\n */\n onseeking: (this: Document, ev: Event) => any;\n /**\n * Fires when the current selection changes.\n * @param ev The event.\n */\n onselect: (this: Document, ev: UIEvent) => any;\n /**\n * Fires when the selection state of a document changes.\n * @param ev The event.\n */\n onselectionchange: (this: Document, ev: Event) => any;\n onselectstart: (this: Document, ev: Event) => any;\n /**\n * Occurs when the download has stopped.\n * @param ev The event.\n */\n onstalled: (this: Document, ev: Event) => any;\n /**\n * Fires when the user clicks the Stop button or leaves the Web page.\n * @param ev The event.\n */\n onstop: (this: Document, ev: Event) => any;\n onsubmit: (this: Document, ev: Event) => any;\n /**\n * Occurs if the load operation has been intentionally halted.\n * @param ev The event.\n */\n onsuspend: (this: Document, ev: Event) => any;\n /**\n * Occurs to indicate the current playback position.\n * @param ev The event.\n */\n ontimeupdate: (this: Document, ev: Event) => any;\n ontouchcancel: (ev: TouchEvent) => any;\n ontouchend: (ev: TouchEvent) => any;\n ontouchmove: (ev: TouchEvent) => any;\n ontouchstart: (ev: TouchEvent) => any;\n /**\n * Occurs when the volume is changed, or playback is muted or unmuted.\n * @param ev The event.\n */\n onvolumechange: (this: Document, ev: Event) => any;\n /**\n * Occurs when playback stops because the next frame of a video resource is not available.\n * @param ev The event.\n */\n onwaiting: (this: Document, ev: Event) => any;\n onwebkitfullscreenchange: (this: Document, ev: Event) => any;\n onwebkitfullscreenerror: (this: Document, ev: Event) => any;\n plugins: HTMLCollectionOf;\n readonly pointerLockElement: Element;\n /**\n * Retrieves a value that indicates the current state of the object.\n */\n readonly readyState: string;\n /**\n * Gets the URL of the location that referred the user to the current page.\n */\n readonly referrer: string;\n /**\n * Gets the root svg element in the document hierarchy.\n */\n readonly rootElement: SVGSVGElement;\n /**\n * Retrieves a collection of all script objects in the document.\n */\n scripts: HTMLCollectionOf;\n readonly scrollingElement: Element | null;\n /**\n * Retrieves a collection of styleSheet objects representing the style sheets that correspond to each instance of a link or style object in the document.\n */\n readonly styleSheets: StyleSheetList;\n /**\n * Contains the title of the document.\n */\n title: string;\n /**\n * Sets or gets the URL for the current document.\n */\n readonly URL: string;\n /**\n * Gets the URL for the document, stripped of any character encoding.\n */\n readonly URLUnencoded: string;\n readonly visibilityState: VisibilityState;\n /**\n * Sets or gets the color of the links that the user has visited.\n */\n vlinkColor: string;\n readonly webkitCurrentFullScreenElement: Element | null;\n readonly webkitFullscreenElement: Element | null;\n readonly webkitFullscreenEnabled: boolean;\n readonly webkitIsFullScreen: boolean;\n readonly xmlEncoding: string | null;\n xmlStandalone: boolean;\n /**\n * Gets or sets the version attribute specified in the declaration of an XML document.\n */\n xmlVersion: string | null;\n adoptNode(source: T): T;\n captureEvents(): void;\n caretRangeFromPoint(x: number, y: number): Range;\n clear(): void;\n /**\n * Closes an output stream and forces the sent data to display.\n */\n close(): void;\n /**\n * Creates an attribute object with a specified name.\n * @param name String that sets the attribute object's name.\n */\n createAttribute(name: string): Attr;\n createAttributeNS(namespaceURI: string | null, qualifiedName: string): Attr;\n createCDATASection(data: string): CDATASection;\n /**\n * Creates a comment object with the specified data.\n * @param data Sets the comment object's data.\n */\n createComment(data: string): Comment;\n /**\n * Creates a new document.\n */\n createDocumentFragment(): DocumentFragment;\n /**\n * Creates an instance of the element for the specified tag.\n * @param tagName The name of an element.\n */\n createElement(tagName: K): HTMLElementTagNameMap[K];\n createElement(tagName: string): HTMLElement;\n createElementNS(namespaceURI: \"http://www.w3.org/1999/xhtml\", qualifiedName: string): HTMLElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"a\"): SVGAElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"circle\"): SVGCircleElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"clipPath\"): SVGClipPathElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"componentTransferFunction\"): SVGComponentTransferFunctionElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"defs\"): SVGDefsElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"desc\"): SVGDescElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"ellipse\"): SVGEllipseElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feBlend\"): SVGFEBlendElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feColorMatrix\"): SVGFEColorMatrixElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feComponentTransfer\"): SVGFEComponentTransferElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feComposite\"): SVGFECompositeElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feConvolveMatrix\"): SVGFEConvolveMatrixElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feDiffuseLighting\"): SVGFEDiffuseLightingElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feDisplacementMap\"): SVGFEDisplacementMapElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feDistantLight\"): SVGFEDistantLightElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFlood\"): SVGFEFloodElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncA\"): SVGFEFuncAElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncB\"): SVGFEFuncBElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncG\"): SVGFEFuncGElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncR\"): SVGFEFuncRElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feGaussianBlur\"): SVGFEGaussianBlurElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feImage\"): SVGFEImageElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feMerge\"): SVGFEMergeElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feMergeNode\"): SVGFEMergeNodeElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feMorphology\"): SVGFEMorphologyElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feOffset\"): SVGFEOffsetElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"fePointLight\"): SVGFEPointLightElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feSpecularLighting\"): SVGFESpecularLightingElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feSpotLight\"): SVGFESpotLightElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feTile\"): SVGFETileElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feTurbulence\"): SVGFETurbulenceElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"filter\"): SVGFilterElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"foreignObject\"): SVGForeignObjectElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"g\"): SVGGElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"image\"): SVGImageElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"gradient\"): SVGGradientElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"line\"): SVGLineElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"linearGradient\"): SVGLinearGradientElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"marker\"): SVGMarkerElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"mask\"): SVGMaskElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"path\"): SVGPathElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"metadata\"): SVGMetadataElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"pattern\"): SVGPatternElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"polygon\"): SVGPolygonElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"polyline\"): SVGPolylineElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"radialGradient\"): SVGRadialGradientElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"rect\"): SVGRectElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"svg\"): SVGSVGElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"script\"): SVGScriptElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"stop\"): SVGStopElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"style\"): SVGStyleElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"switch\"): SVGSwitchElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"symbol\"): SVGSymbolElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"tspan\"): SVGTSpanElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"textContent\"): SVGTextContentElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"text\"): SVGTextElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"textPath\"): SVGTextPathElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"textPositioning\"): SVGTextPositioningElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"title\"): SVGTitleElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"use\"): SVGUseElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"view\"): SVGViewElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: string): SVGElement;\n createElementNS(namespaceURI: string | null, qualifiedName: string): Element;\n createExpression(expression: string, resolver: XPathNSResolver): XPathExpression;\n /**\n * Creates a NodeIterator object that you can use to traverse filtered lists of nodes or elements in a document.\n * @param root The root element or node to start traversing on.\n * @param whatToShow The type of nodes or elements to appear in the node list\n * @param filter A custom NodeFilter function to use. For more information, see filter. Use null for no filter.\n * @param entityReferenceExpansion A flag that specifies whether entity reference nodes are expanded.\n */\n createNodeIterator(root: Node, whatToShow?: number, filter?: NodeFilter, entityReferenceExpansion?: boolean): NodeIterator;\n createNSResolver(nodeResolver: Node): XPathNSResolver;\n createProcessingInstruction(target: string, data: string): ProcessingInstruction;\n /**\n * Returns an empty range object that has both of its boundary points positioned at the beginning of the document.\n */\n createRange(): Range;\n /**\n * Creates a text string from the specified value.\n * @param data String that specifies the nodeValue property of the text node.\n */\n createTextNode(data: string): Text;\n createTouch(view: Window, target: EventTarget, identifier: number, pageX: number, pageY: number, screenX: number, screenY: number): Touch;\n createTouchList(...touches: Touch[]): TouchList;\n /**\n * Creates a TreeWalker object that you can use to traverse filtered lists of nodes or elements in a document.\n * @param root The root element or node to start traversing on.\n * @param whatToShow The type of nodes or elements to appear in the node list. For more information, see whatToShow.\n * @param filter A custom NodeFilter function to use.\n * @param entityReferenceExpansion A flag that specifies whether entity reference nodes are expanded.\n */\n createTreeWalker(root: Node, whatToShow?: number, filter?: NodeFilter, entityReferenceExpansion?: boolean): TreeWalker;\n /**\n * Returns the element for the specified x coordinate and the specified y coordinate.\n * @param x The x-offset\n * @param y The y-offset\n */\n elementFromPoint(x: number, y: number): Element;\n evaluate(expression: string, contextNode: Node, resolver: XPathNSResolver | null, type: number, result: XPathResult | null): XPathResult;\n /**\n * Executes a command on the current document, current selection, or the given range.\n * @param commandId String that specifies the command to execute. This command can be any of the command identifiers that can be executed in script.\n * @param showUI Display the user interface, defaults to false.\n * @param value Value to assign.\n */\n execCommand(commandId: string, showUI?: boolean, value?: any): boolean;\n /**\n * Displays help information for the given command identifier.\n * @param commandId Displays help information for the given command identifier.\n */\n execCommandShowHelp(commandId: string): boolean;\n exitFullscreen(): void;\n exitPointerLock(): void;\n /**\n * Causes the element to receive the focus and executes the code specified by the onfocus event.\n */\n focus(): void;\n /**\n * Returns a reference to the first object with the specified value of the ID or NAME attribute.\n * @param elementId String that specifies the ID value. Case-insensitive.\n */\n getElementById(elementId: string): HTMLElement | null;\n getElementsByClassName(classNames: string): HTMLCollectionOf;\n /**\n * Gets a collection of objects based on the value of the NAME or ID attribute.\n * @param elementName Gets a collection of objects based on the value of the NAME or ID attribute.\n */\n getElementsByName(elementName: string): NodeListOf;\n /**\n * Retrieves a collection of objects based on the specified element name.\n * @param name Specifies the name of an element.\n */\n getElementsByTagName(tagname: K): ElementListTagNameMap[K];\n getElementsByTagName(tagname: string): NodeListOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/1999/xhtml\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/2000/svg\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: string, localName: string): HTMLCollectionOf;\n /**\n * Returns an object representing the current selection of the document that is loaded into the object displaying a webpage.\n */\n getSelection(): Selection;\n /**\n * Gets a value indicating whether the object currently has focus.\n */\n hasFocus(): boolean;\n importNode(importedNode: T, deep: boolean): T;\n msElementsFromPoint(x: number, y: number): NodeListOf;\n msElementsFromRect(left: number, top: number, width: number, height: number): NodeListOf;\n /**\n * Opens a new window and loads a document specified by a given URL. Also, opens a new window that uses the url parameter and the name parameter to collect the output of the write method and the writeln method.\n * @param url Specifies a MIME type for the document.\n * @param name Specifies the name of the window. This name is used as the value for the TARGET attribute on a form or an anchor element.\n * @param features Contains a list of items separated by commas. Each item consists of an option and a value, separated by an equals sign (for example, \"fullscreen=yes, toolbar=yes\"). The following values are supported.\n * @param replace Specifies whether the existing entry for the document is replaced in the history list.\n */\n open(url?: string, name?: string, features?: string, replace?: boolean): Document;\n /**\n * Returns a Boolean value that indicates whether a specified command can be successfully executed using execCommand, given the current state of the document.\n * @param commandId Specifies a command identifier.\n */\n queryCommandEnabled(commandId: string): boolean;\n /**\n * Returns a Boolean value that indicates whether the specified command is in the indeterminate state.\n * @param commandId String that specifies a command identifier.\n */\n queryCommandIndeterm(commandId: string): boolean;\n /**\n * Returns a Boolean value that indicates the current state of the command.\n * @param commandId String that specifies a command identifier.\n */\n queryCommandState(commandId: string): boolean;\n /**\n * Returns a Boolean value that indicates whether the current command is supported on the current range.\n * @param commandId Specifies a command identifier.\n */\n queryCommandSupported(commandId: string): boolean;\n /**\n * Retrieves the string associated with a command.\n * @param commandId String that contains the identifier of a command. This can be any command identifier given in the list of Command Identifiers.\n */\n queryCommandText(commandId: string): string;\n /**\n * Returns the current value of the document, range, or current selection for the given command.\n * @param commandId String that specifies a command identifier.\n */\n queryCommandValue(commandId: string): string;\n releaseEvents(): void;\n /**\n * Allows updating the print settings for the page.\n */\n updateSettings(): void;\n webkitCancelFullScreen(): void;\n webkitExitFullscreen(): void;\n /**\n * Writes one or more HTML expressions to a document in the specified window.\n * @param content Specifies the text and HTML tags to write.\n */\n write(...content: string[]): void;\n /**\n * Writes one or more HTML expressions, followed by a carriage return, to a document in the specified window.\n * @param content The text and HTML tags to write.\n */\n writeln(...content: string[]): void;\n addEventListener(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Document: {\n prototype: Document;\n new(): Document;\n};\n\ninterface DocumentFragment extends Node, NodeSelector, ParentNode {\n getElementById(elementId: string): HTMLElement | null;\n}\n\ndeclare var DocumentFragment: {\n prototype: DocumentFragment;\n new(): DocumentFragment;\n};\n\ninterface DocumentType extends Node, ChildNode {\n readonly entities: NamedNodeMap;\n readonly internalSubset: string | null;\n readonly name: string;\n readonly notations: NamedNodeMap;\n readonly publicId: string;\n readonly systemId: string;\n}\n\ndeclare var DocumentType: {\n prototype: DocumentType;\n new(): DocumentType;\n};\n\ninterface DOMError {\n readonly name: string;\n toString(): string;\n}\n\ndeclare var DOMError: {\n prototype: DOMError;\n new(): DOMError;\n};\n\ninterface DOMException {\n readonly code: number;\n readonly message: string;\n readonly name: string;\n toString(): string;\n readonly ABORT_ERR: number;\n readonly DATA_CLONE_ERR: number;\n readonly DOMSTRING_SIZE_ERR: number;\n readonly HIERARCHY_REQUEST_ERR: number;\n readonly INDEX_SIZE_ERR: number;\n readonly INUSE_ATTRIBUTE_ERR: number;\n readonly INVALID_ACCESS_ERR: number;\n readonly INVALID_CHARACTER_ERR: number;\n readonly INVALID_MODIFICATION_ERR: number;\n readonly INVALID_NODE_TYPE_ERR: number;\n readonly INVALID_STATE_ERR: number;\n readonly NAMESPACE_ERR: number;\n readonly NETWORK_ERR: number;\n readonly NO_DATA_ALLOWED_ERR: number;\n readonly NO_MODIFICATION_ALLOWED_ERR: number;\n readonly NOT_FOUND_ERR: number;\n readonly NOT_SUPPORTED_ERR: number;\n readonly PARSE_ERR: number;\n readonly QUOTA_EXCEEDED_ERR: number;\n readonly SECURITY_ERR: number;\n readonly SERIALIZE_ERR: number;\n readonly SYNTAX_ERR: number;\n readonly TIMEOUT_ERR: number;\n readonly TYPE_MISMATCH_ERR: number;\n readonly URL_MISMATCH_ERR: number;\n readonly VALIDATION_ERR: number;\n readonly WRONG_DOCUMENT_ERR: number;\n}\n\ndeclare var DOMException: {\n prototype: DOMException;\n new(): DOMException;\n readonly ABORT_ERR: number;\n readonly DATA_CLONE_ERR: number;\n readonly DOMSTRING_SIZE_ERR: number;\n readonly HIERARCHY_REQUEST_ERR: number;\n readonly INDEX_SIZE_ERR: number;\n readonly INUSE_ATTRIBUTE_ERR: number;\n readonly INVALID_ACCESS_ERR: number;\n readonly INVALID_CHARACTER_ERR: number;\n readonly INVALID_MODIFICATION_ERR: number;\n readonly INVALID_NODE_TYPE_ERR: number;\n readonly INVALID_STATE_ERR: number;\n readonly NAMESPACE_ERR: number;\n readonly NETWORK_ERR: number;\n readonly NO_DATA_ALLOWED_ERR: number;\n readonly NO_MODIFICATION_ALLOWED_ERR: number;\n readonly NOT_FOUND_ERR: number;\n readonly NOT_SUPPORTED_ERR: number;\n readonly PARSE_ERR: number;\n readonly QUOTA_EXCEEDED_ERR: number;\n readonly SECURITY_ERR: number;\n readonly SERIALIZE_ERR: number;\n readonly SYNTAX_ERR: number;\n readonly TIMEOUT_ERR: number;\n readonly TYPE_MISMATCH_ERR: number;\n readonly URL_MISMATCH_ERR: number;\n readonly VALIDATION_ERR: number;\n readonly WRONG_DOCUMENT_ERR: number;\n};\n\ninterface DOMImplementation {\n createDocument(namespaceURI: string | null, qualifiedName: string | null, doctype: DocumentType | null): Document;\n createDocumentType(qualifiedName: string, publicId: string, systemId: string): DocumentType;\n createHTMLDocument(title: string): Document;\n hasFeature(feature: string | null, version: string | null): boolean;\n}\n\ndeclare var DOMImplementation: {\n prototype: DOMImplementation;\n new(): DOMImplementation;\n};\n\ninterface DOMParser {\n parseFromString(source: string, mimeType: string): Document;\n}\n\ndeclare var DOMParser: {\n prototype: DOMParser;\n new(): DOMParser;\n};\n\ninterface DOMSettableTokenList extends DOMTokenList {\n value: string;\n}\n\ndeclare var DOMSettableTokenList: {\n prototype: DOMSettableTokenList;\n new(): DOMSettableTokenList;\n};\n\ninterface DOMStringList {\n readonly length: number;\n contains(str: string): boolean;\n item(index: number): string | null;\n [index: number]: string;\n}\n\ndeclare var DOMStringList: {\n prototype: DOMStringList;\n new(): DOMStringList;\n};\n\ninterface DOMStringMap {\n [name: string]: string | undefined;\n}\n\ndeclare var DOMStringMap: {\n prototype: DOMStringMap;\n new(): DOMStringMap;\n};\n\ninterface DOMTokenList {\n readonly length: number;\n add(...token: string[]): void;\n contains(token: string): boolean;\n item(index: number): string;\n remove(...token: string[]): void;\n toggle(token: string, force?: boolean): boolean;\n toString(): string;\n [index: number]: string;\n}\n\ndeclare var DOMTokenList: {\n prototype: DOMTokenList;\n new(): DOMTokenList;\n};\n\ninterface DragEvent extends MouseEvent {\n readonly dataTransfer: DataTransfer;\n initDragEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget, dataTransferArg: DataTransfer): void;\n msConvertURL(file: File, targetType: string, targetURL?: string): void;\n}\n\ndeclare var DragEvent: {\n prototype: DragEvent;\n new(type: \"drag\" | \"dragend\" | \"dragenter\" | \"dragexit\" | \"dragleave\" | \"dragover\" | \"dragstart\" | \"drop\", dragEventInit?: { dataTransfer?: DataTransfer }): DragEvent;\n};\n\ninterface DynamicsCompressorNode extends AudioNode {\n readonly attack: AudioParam;\n readonly knee: AudioParam;\n readonly ratio: AudioParam;\n readonly reduction: number;\n readonly release: AudioParam;\n readonly threshold: AudioParam;\n}\n\ndeclare var DynamicsCompressorNode: {\n prototype: DynamicsCompressorNode;\n new(): DynamicsCompressorNode;\n};\n\ninterface ElementEventMap extends GlobalEventHandlersEventMap {\n \"ariarequest\": Event;\n \"command\": Event;\n \"gotpointercapture\": PointerEvent;\n \"lostpointercapture\": PointerEvent;\n \"MSGestureChange\": MSGestureEvent;\n \"MSGestureDoubleTap\": MSGestureEvent;\n \"MSGestureEnd\": MSGestureEvent;\n \"MSGestureHold\": MSGestureEvent;\n \"MSGestureStart\": MSGestureEvent;\n \"MSGestureTap\": MSGestureEvent;\n \"MSGotPointerCapture\": MSPointerEvent;\n \"MSInertiaStart\": MSGestureEvent;\n \"MSLostPointerCapture\": MSPointerEvent;\n \"MSPointerCancel\": MSPointerEvent;\n \"MSPointerDown\": MSPointerEvent;\n \"MSPointerEnter\": MSPointerEvent;\n \"MSPointerLeave\": MSPointerEvent;\n \"MSPointerMove\": MSPointerEvent;\n \"MSPointerOut\": MSPointerEvent;\n \"MSPointerOver\": MSPointerEvent;\n \"MSPointerUp\": MSPointerEvent;\n \"touchcancel\": TouchEvent;\n \"touchend\": TouchEvent;\n \"touchmove\": TouchEvent;\n \"touchstart\": TouchEvent;\n \"webkitfullscreenchange\": Event;\n \"webkitfullscreenerror\": Event;\n}\n\ninterface Element extends Node, GlobalEventHandlers, ElementTraversal, NodeSelector, ChildNode, ParentNode {\n readonly classList: DOMTokenList;\n className: string;\n readonly clientHeight: number;\n readonly clientLeft: number;\n readonly clientTop: number;\n readonly clientWidth: number;\n id: string;\n innerHTML: string;\n msContentZoomFactor: number;\n readonly msRegionOverflow: string;\n onariarequest: (this: Element, ev: Event) => any;\n oncommand: (this: Element, ev: Event) => any;\n ongotpointercapture: (this: Element, ev: PointerEvent) => any;\n onlostpointercapture: (this: Element, ev: PointerEvent) => any;\n onmsgesturechange: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturedoubletap: (this: Element, ev: MSGestureEvent) => any;\n onmsgestureend: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturehold: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturestart: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturetap: (this: Element, ev: MSGestureEvent) => any;\n onmsgotpointercapture: (this: Element, ev: MSPointerEvent) => any;\n onmsinertiastart: (this: Element, ev: MSGestureEvent) => any;\n onmslostpointercapture: (this: Element, ev: MSPointerEvent) => any;\n onmspointercancel: (this: Element, ev: MSPointerEvent) => any;\n onmspointerdown: (this: Element, ev: MSPointerEvent) => any;\n onmspointerenter: (this: Element, ev: MSPointerEvent) => any;\n onmspointerleave: (this: Element, ev: MSPointerEvent) => any;\n onmspointermove: (this: Element, ev: MSPointerEvent) => any;\n onmspointerout: (this: Element, ev: MSPointerEvent) => any;\n onmspointerover: (this: Element, ev: MSPointerEvent) => any;\n onmspointerup: (this: Element, ev: MSPointerEvent) => any;\n ontouchcancel: (ev: TouchEvent) => any;\n ontouchend: (ev: TouchEvent) => any;\n ontouchmove: (ev: TouchEvent) => any;\n ontouchstart: (ev: TouchEvent) => any;\n onwebkitfullscreenchange: (this: Element, ev: Event) => any;\n onwebkitfullscreenerror: (this: Element, ev: Event) => any;\n outerHTML: string;\n readonly prefix: string | null;\n readonly scrollHeight: number;\n scrollLeft: number;\n scrollTop: number;\n readonly scrollWidth: number;\n readonly tagName: string;\n readonly assignedSlot: HTMLSlotElement | null;\n slot: string;\n readonly shadowRoot: ShadowRoot | null;\n getAttribute(name: string): string | null;\n getAttributeNode(name: string): Attr;\n getAttributeNodeNS(namespaceURI: string, localName: string): Attr;\n getAttributeNS(namespaceURI: string, localName: string): string;\n getBoundingClientRect(): ClientRect;\n getClientRects(): ClientRectList;\n getElementsByTagName(name: K): ElementListTagNameMap[K];\n getElementsByTagName(name: string): NodeListOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/1999/xhtml\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/2000/svg\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: string, localName: string): HTMLCollectionOf;\n hasAttribute(name: string): boolean;\n hasAttributeNS(namespaceURI: string, localName: string): boolean;\n msGetRegionContent(): MSRangeCollection;\n msGetUntransformedBounds(): ClientRect;\n msMatchesSelector(selectors: string): boolean;\n msReleasePointerCapture(pointerId: number): void;\n msSetPointerCapture(pointerId: number): void;\n msZoomTo(args: MsZoomToOptions): void;\n releasePointerCapture(pointerId: number): void;\n removeAttribute(qualifiedName: string): void;\n removeAttributeNode(oldAttr: Attr): Attr;\n removeAttributeNS(namespaceURI: string, localName: string): void;\n requestFullscreen(): void;\n requestPointerLock(): void;\n setAttribute(name: string, value: string): void;\n setAttributeNode(newAttr: Attr): Attr;\n setAttributeNodeNS(newAttr: Attr): Attr;\n setAttributeNS(namespaceURI: string, qualifiedName: string, value: string): void;\n setPointerCapture(pointerId: number): void;\n webkitMatchesSelector(selectors: string): boolean;\n webkitRequestFullscreen(): void;\n webkitRequestFullScreen(): void;\n getElementsByClassName(classNames: string): NodeListOf;\n matches(selector: string): boolean;\n closest(selector: string): Element | null;\n scrollIntoView(arg?: boolean | ScrollIntoViewOptions): void;\n scroll(options?: ScrollToOptions): void;\n scroll(x: number, y: number): void;\n scrollTo(options?: ScrollToOptions): void;\n scrollTo(x: number, y: number): void;\n scrollBy(options?: ScrollToOptions): void;\n scrollBy(x: number, y: number): void;\n insertAdjacentElement(position: InsertPosition, insertedElement: Element): Element | null;\n insertAdjacentHTML(where: InsertPosition, html: string): void;\n insertAdjacentText(where: InsertPosition, text: string): void;\n attachShadow(shadowRootInitDict: ShadowRootInit): ShadowRoot;\n addEventListener(type: K, listener: (this: Element, ev: ElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Element: {\n prototype: Element;\n new(): Element;\n};\n\ninterface ErrorEvent extends Event {\n readonly colno: number;\n readonly error: any;\n readonly filename: string;\n readonly lineno: number;\n readonly message: string;\n initErrorEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, messageArg: string, filenameArg: string, linenoArg: number): void;\n}\n\ndeclare var ErrorEvent: {\n prototype: ErrorEvent;\n new(type: string, errorEventInitDict?: ErrorEventInit): ErrorEvent;\n};\n\ninterface Event {\n readonly bubbles: boolean;\n readonly cancelable: boolean;\n cancelBubble: boolean;\n readonly currentTarget: EventTarget;\n readonly defaultPrevented: boolean;\n readonly eventPhase: number;\n readonly isTrusted: boolean;\n returnValue: boolean;\n readonly srcElement: Element | null;\n readonly target: EventTarget;\n readonly timeStamp: number;\n readonly type: string;\n readonly scoped: boolean;\n initEvent(eventTypeArg: string, canBubbleArg: boolean, cancelableArg: boolean): void;\n preventDefault(): void;\n stopImmediatePropagation(): void;\n stopPropagation(): void;\n deepPath(): EventTarget[];\n readonly AT_TARGET: number;\n readonly BUBBLING_PHASE: number;\n readonly CAPTURING_PHASE: number;\n}\n\ndeclare var Event: {\n prototype: Event;\n new(typeArg: string, eventInitDict?: EventInit): Event;\n readonly AT_TARGET: number;\n readonly BUBBLING_PHASE: number;\n readonly CAPTURING_PHASE: number;\n};\n\ninterface EventTarget {\n addEventListener(type: string, listener?: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;\n dispatchEvent(evt: Event): boolean;\n removeEventListener(type: string, listener?: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;\n}\n\ndeclare var EventTarget: {\n prototype: EventTarget;\n new(): EventTarget;\n};\n\ninterface EXT_frag_depth {\n}\n\ndeclare var EXT_frag_depth: {\n prototype: EXT_frag_depth;\n new(): EXT_frag_depth;\n};\n\ninterface EXT_texture_filter_anisotropic {\n readonly MAX_TEXTURE_MAX_ANISOTROPY_EXT: number;\n readonly TEXTURE_MAX_ANISOTROPY_EXT: number;\n}\n\ndeclare var EXT_texture_filter_anisotropic: {\n prototype: EXT_texture_filter_anisotropic;\n new(): EXT_texture_filter_anisotropic;\n readonly MAX_TEXTURE_MAX_ANISOTROPY_EXT: number;\n readonly TEXTURE_MAX_ANISOTROPY_EXT: number;\n};\n\ninterface ExtensionScriptApis {\n extensionIdToShortId(extensionId: string): number;\n fireExtensionApiTelemetry(functionName: string, isSucceeded: boolean, isSupported: boolean): void;\n genericFunction(routerAddress: any, parameters?: string, callbackId?: number): void;\n genericSynchronousFunction(functionId: number, parameters?: string): string;\n getExtensionId(): string;\n registerGenericFunctionCallbackHandler(callbackHandler: any): void;\n registerGenericPersistentCallbackHandler(callbackHandler: any): void;\n}\n\ndeclare var ExtensionScriptApis: {\n prototype: ExtensionScriptApis;\n new(): ExtensionScriptApis;\n};\n\ninterface External {\n}\n\ndeclare var External: {\n prototype: External;\n new(): External;\n};\n\ninterface File extends Blob {\n readonly lastModifiedDate: any;\n readonly name: string;\n readonly webkitRelativePath: string;\n}\n\ndeclare var File: {\n prototype: File;\n new (parts: (ArrayBuffer | ArrayBufferView | Blob | string)[], filename: string, properties?: FilePropertyBag): File;\n};\n\ninterface FileList {\n readonly length: number;\n item(index: number): File;\n [index: number]: File;\n}\n\ndeclare var FileList: {\n prototype: FileList;\n new(): FileList;\n};\n\ninterface FileReader extends EventTarget, MSBaseReader {\n readonly error: DOMError;\n readAsArrayBuffer(blob: Blob): void;\n readAsBinaryString(blob: Blob): void;\n readAsDataURL(blob: Blob): void;\n readAsText(blob: Blob, encoding?: string): void;\n addEventListener(type: K, listener: (this: FileReader, ev: MSBaseReaderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var FileReader: {\n prototype: FileReader;\n new(): FileReader;\n};\n\ninterface FocusEvent extends UIEvent {\n readonly relatedTarget: EventTarget;\n initFocusEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, relatedTargetArg: EventTarget): void;\n}\n\ndeclare var FocusEvent: {\n prototype: FocusEvent;\n new(typeArg: string, eventInitDict?: FocusEventInit): FocusEvent;\n};\n\ninterface FocusNavigationEvent extends Event {\n readonly navigationReason: NavigationReason;\n readonly originHeight: number;\n readonly originLeft: number;\n readonly originTop: number;\n readonly originWidth: number;\n requestFocus(): void;\n}\n\ndeclare var FocusNavigationEvent: {\n prototype: FocusNavigationEvent;\n new(type: string, eventInitDict?: FocusNavigationEventInit): FocusNavigationEvent;\n};\n\ninterface FormData {\n append(name: string, value: string | Blob, fileName?: string): void;\n delete(name: string): void;\n get(name: string): FormDataEntryValue | null;\n getAll(name: string): FormDataEntryValue[];\n has(name: string): boolean;\n set(name: string, value: string | Blob, fileName?: string): void;\n}\n\ndeclare var FormData: {\n prototype: FormData;\n new (form?: HTMLFormElement): FormData;\n};\n\ninterface GainNode extends AudioNode {\n readonly gain: AudioParam;\n}\n\ndeclare var GainNode: {\n prototype: GainNode;\n new(): GainNode;\n};\n\ninterface Gamepad {\n readonly axes: number[];\n readonly buttons: GamepadButton[];\n readonly connected: boolean;\n readonly id: string;\n readonly index: number;\n readonly mapping: string;\n readonly timestamp: number;\n}\n\ndeclare var Gamepad: {\n prototype: Gamepad;\n new(): Gamepad;\n};\n\ninterface GamepadButton {\n readonly pressed: boolean;\n readonly value: number;\n}\n\ndeclare var GamepadButton: {\n prototype: GamepadButton;\n new(): GamepadButton;\n};\n\ninterface GamepadEvent extends Event {\n readonly gamepad: Gamepad;\n}\n\ndeclare var GamepadEvent: {\n prototype: GamepadEvent;\n new(typeArg: string, eventInitDict?: GamepadEventInit): GamepadEvent;\n};\n\ninterface Geolocation {\n clearWatch(watchId: number): void;\n getCurrentPosition(successCallback: PositionCallback, errorCallback?: PositionErrorCallback, options?: PositionOptions): void;\n watchPosition(successCallback: PositionCallback, errorCallback?: PositionErrorCallback, options?: PositionOptions): number;\n}\n\ndeclare var Geolocation: {\n prototype: Geolocation;\n new(): Geolocation;\n};\n\ninterface HashChangeEvent extends Event {\n readonly newURL: string | null;\n readonly oldURL: string | null;\n}\n\ndeclare var HashChangeEvent: {\n prototype: HashChangeEvent;\n new(typeArg: string, eventInitDict?: HashChangeEventInit): HashChangeEvent;\n};\n\ninterface Headers {\n append(name: string, value: string): void;\n delete(name: string): void;\n forEach(callback: ForEachCallback): void;\n get(name: string): string | null;\n has(name: string): boolean;\n set(name: string, value: string): void;\n}\n\ndeclare var Headers: {\n prototype: Headers;\n new(init?: any): Headers;\n};\n\ninterface History {\n readonly length: number;\n readonly state: any;\n scrollRestoration: ScrollRestoration;\n back(): void;\n forward(): void;\n go(delta?: number): void;\n pushState(data: any, title: string, url?: string | null): void;\n replaceState(data: any, title: string, url?: string | null): void;\n}\n\ndeclare var History: {\n prototype: History;\n new(): History;\n};\n\ninterface HTMLAllCollection {\n readonly length: number;\n item(nameOrIndex?: string): HTMLCollection | Element | null;\n namedItem(name: string): HTMLCollection | Element | null;\n [index: number]: Element;\n}\n\ndeclare var HTMLAllCollection: {\n prototype: HTMLAllCollection;\n new(): HTMLAllCollection;\n};\n\ninterface HTMLAnchorElement extends HTMLElement {\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n /**\n * Sets or retrieves the coordinates of the object.\n */\n coords: string;\n download: string;\n /**\n * Contains the anchor portion of the URL including the hash sign (#).\n */\n hash: string;\n /**\n * Contains the hostname and port values of the URL.\n */\n host: string;\n /**\n * Contains the hostname of a URL.\n */\n hostname: string;\n /**\n * Sets or retrieves a destination URL or an anchor point.\n */\n href: string;\n /**\n * Sets or retrieves the language code of the object.\n */\n hreflang: string;\n Methods: string;\n readonly mimeType: string;\n /**\n * Sets or retrieves the shape of the object.\n */\n name: string;\n readonly nameProp: string;\n /**\n * Contains the pathname of the URL.\n */\n pathname: string;\n /**\n * Sets or retrieves the port number associated with a URL.\n */\n port: string;\n /**\n * Contains the protocol of the URL.\n */\n protocol: string;\n readonly protocolLong: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rel: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rev: string;\n /**\n * Sets or retrieves the substring of the href property that follows the question mark.\n */\n search: string;\n /**\n * Sets or retrieves the shape of the object.\n */\n shape: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Retrieves or sets the text of the object as a string.\n */\n text: string;\n type: string;\n urn: string;\n /**\n * Returns a string representation of an object.\n */\n toString(): string;\n addEventListener(type: K, listener: (this: HTMLAnchorElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAnchorElement: {\n prototype: HTMLAnchorElement;\n new(): HTMLAnchorElement;\n};\n\ninterface HTMLAppletElement extends HTMLElement {\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Gets or sets the optional alternative HTML script to execute if the object fails to load.\n */\n altHtml: string;\n /**\n * Sets or retrieves a character string that can be used to implement your own archive functionality for the object.\n */\n archive: string;\n /**\n * Retrieves a string of the URL where the object tag can be found. This is often the href of the document that the object is in, or the value set by a base element.\n */\n readonly BaseHref: string;\n border: string;\n code: string;\n /**\n * Sets or retrieves the URL of the component.\n */\n codeBase: string;\n /**\n * Sets or retrieves the Internet media type for the code associated with the object.\n */\n codeType: string;\n /**\n * Address of a pointer to the document this page or frame contains. If there is no document, then null will be returned.\n */\n readonly contentDocument: Document;\n /**\n * Sets or retrieves the URL that references the data of the object.\n */\n data: string;\n /**\n * Sets or retrieves a character string that can be used to implement your own declare functionality for the object.\n */\n declare: boolean;\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n hspace: number;\n /**\n * Sets or retrieves the shape of the object.\n */\n name: string;\n object: string | null;\n /**\n * Sets or retrieves a message to be displayed while an object is loading.\n */\n standby: string;\n /**\n * Returns the content type of the object.\n */\n type: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n vspace: number;\n width: number;\n addEventListener(type: K, listener: (this: HTMLAppletElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAppletElement: {\n prototype: HTMLAppletElement;\n new(): HTMLAppletElement;\n};\n\ninterface HTMLAreaElement extends HTMLElement {\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Sets or retrieves the coordinates of the object.\n */\n coords: string;\n download: string;\n /**\n * Sets or retrieves the subsection of the href property that follows the number sign (#).\n */\n hash: string;\n /**\n * Sets or retrieves the hostname and port number of the location or URL.\n */\n host: string;\n /**\n * Sets or retrieves the host name part of the location or URL.\n */\n hostname: string;\n /**\n * Sets or retrieves a destination URL or an anchor point.\n */\n href: string;\n /**\n * Sets or gets whether clicks in this region cause action.\n */\n noHref: boolean;\n /**\n * Sets or retrieves the file name or path specified by the object.\n */\n pathname: string;\n /**\n * Sets or retrieves the port number associated with a URL.\n */\n port: string;\n /**\n * Sets or retrieves the protocol portion of a URL.\n */\n protocol: string;\n rel: string;\n /**\n * Sets or retrieves the substring of the href property that follows the question mark.\n */\n search: string;\n /**\n * Sets or retrieves the shape of the object.\n */\n shape: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Returns a string representation of an object.\n */\n toString(): string;\n addEventListener(type: K, listener: (this: HTMLAreaElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAreaElement: {\n prototype: HTMLAreaElement;\n new(): HTMLAreaElement;\n};\n\ninterface HTMLAreasCollection extends HTMLCollectionBase {\n}\n\ndeclare var HTMLAreasCollection: {\n prototype: HTMLAreasCollection;\n new(): HTMLAreasCollection;\n};\n\ninterface HTMLAudioElement extends HTMLMediaElement {\n addEventListener(type: K, listener: (this: HTMLAudioElement, ev: HTMLMediaElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAudioElement: {\n prototype: HTMLAudioElement;\n new(): HTMLAudioElement;\n};\n\ninterface HTMLBaseElement extends HTMLElement {\n /**\n * Gets or sets the baseline URL on which relative links are based.\n */\n href: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n addEventListener(type: K, listener: (this: HTMLBaseElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBaseElement: {\n prototype: HTMLBaseElement;\n new(): HTMLBaseElement;\n};\n\ninterface HTMLBaseFontElement extends HTMLElement, DOML2DeprecatedColorProperty {\n /**\n * Sets or retrieves the current typeface family.\n */\n face: string;\n /**\n * Sets or retrieves the font size of the object.\n */\n size: number;\n addEventListener(type: K, listener: (this: HTMLBaseFontElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBaseFontElement: {\n prototype: HTMLBaseFontElement;\n new(): HTMLBaseFontElement;\n};\n\ninterface HTMLBodyElementEventMap extends HTMLElementEventMap {\n \"afterprint\": Event;\n \"beforeprint\": Event;\n \"beforeunload\": BeforeUnloadEvent;\n \"blur\": FocusEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"hashchange\": HashChangeEvent;\n \"load\": Event;\n \"message\": MessageEvent;\n \"offline\": Event;\n \"online\": Event;\n \"orientationchange\": Event;\n \"pagehide\": PageTransitionEvent;\n \"pageshow\": PageTransitionEvent;\n \"popstate\": PopStateEvent;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"storage\": StorageEvent;\n \"unload\": Event;\n}\n\ninterface HTMLBodyElement extends HTMLElement {\n aLink: any;\n background: string;\n bgColor: any;\n bgProperties: string;\n link: any;\n noWrap: boolean;\n onafterprint: (this: HTMLBodyElement, ev: Event) => any;\n onbeforeprint: (this: HTMLBodyElement, ev: Event) => any;\n onbeforeunload: (this: HTMLBodyElement, ev: BeforeUnloadEvent) => any;\n onblur: (this: HTMLBodyElement, ev: FocusEvent) => any;\n onerror: (this: HTMLBodyElement, ev: ErrorEvent) => any;\n onfocus: (this: HTMLBodyElement, ev: FocusEvent) => any;\n onhashchange: (this: HTMLBodyElement, ev: HashChangeEvent) => any;\n onload: (this: HTMLBodyElement, ev: Event) => any;\n onmessage: (this: HTMLBodyElement, ev: MessageEvent) => any;\n onoffline: (this: HTMLBodyElement, ev: Event) => any;\n ononline: (this: HTMLBodyElement, ev: Event) => any;\n onorientationchange: (this: HTMLBodyElement, ev: Event) => any;\n onpagehide: (this: HTMLBodyElement, ev: PageTransitionEvent) => any;\n onpageshow: (this: HTMLBodyElement, ev: PageTransitionEvent) => any;\n onpopstate: (this: HTMLBodyElement, ev: PopStateEvent) => any;\n onresize: (this: HTMLBodyElement, ev: UIEvent) => any;\n onscroll: (this: HTMLBodyElement, ev: UIEvent) => any;\n onstorage: (this: HTMLBodyElement, ev: StorageEvent) => any;\n onunload: (this: HTMLBodyElement, ev: Event) => any;\n text: any;\n vLink: any;\n addEventListener(type: K, listener: (this: HTMLBodyElement, ev: HTMLBodyElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBodyElement: {\n prototype: HTMLBodyElement;\n new(): HTMLBodyElement;\n};\n\ninterface HTMLBRElement extends HTMLElement {\n /**\n * Sets or retrieves the side on which floating objects are not to be positioned when any IHTMLBlockElement is inserted into the document.\n */\n clear: string;\n addEventListener(type: K, listener: (this: HTMLBRElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBRElement: {\n prototype: HTMLBRElement;\n new(): HTMLBRElement;\n};\n\ninterface HTMLButtonElement extends HTMLElement {\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Overrides the action attribute (where the data on a form is sent) on the parent form element.\n */\n formAction: string;\n /**\n * Used to override the encoding (formEnctype attribute) specified on the form element.\n */\n formEnctype: string;\n /**\n * Overrides the submit method attribute previously specified on a form element.\n */\n formMethod: string;\n /**\n * Overrides any validation or required attributes on a form or form elements to allow it to be submitted without validation. This can be used to create a \"save draft\"-type submit option.\n */\n formNoValidate: string;\n /**\n * Overrides the target attribute on a form element.\n */\n formTarget: string;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n status: any;\n /**\n * Gets the classification and default behavior of the button.\n */\n type: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Sets or retrieves the default or selected value of the control.\n */\n value: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLButtonElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLButtonElement: {\n prototype: HTMLButtonElement;\n new(): HTMLButtonElement;\n};\n\ninterface HTMLCanvasElement extends HTMLElement {\n /**\n * Gets or sets the height of a canvas element on a document.\n */\n height: number;\n /**\n * Gets or sets the width of a canvas element on a document.\n */\n width: number;\n /**\n * Returns an object that provides methods and properties for drawing and manipulating images and graphics on a canvas element in a document. A context object includes information about colors, line widths, fonts, and other graphic parameters that can be drawn on a canvas.\n * @param contextId The identifier (ID) of the type of canvas to create. Internet Explorer 9 and Internet Explorer 10 support only a 2-D context using canvas.getContext(\"2d\"); IE11 Preview also supports 3-D or WebGL context using canvas.getContext(\"experimental-webgl\");\n */\n getContext(contextId: \"2d\", contextAttributes?: Canvas2DContextAttributes): CanvasRenderingContext2D | null;\n getContext(contextId: \"webgl\" | \"experimental-webgl\", contextAttributes?: WebGLContextAttributes): WebGLRenderingContext | null;\n getContext(contextId: string, contextAttributes?: {}): CanvasRenderingContext2D | WebGLRenderingContext | null;\n /**\n * Returns a blob object encoded as a Portable Network Graphics (PNG) format from a canvas image or drawing.\n */\n msToBlob(): Blob;\n /**\n * Returns the content of the current canvas as an image that you can use as a source for another canvas or an HTML element.\n * @param type The standard MIME type for the image format to return. If you do not specify this parameter, the default value is a PNG format image.\n */\n toDataURL(type?: string, ...args: any[]): string;\n toBlob(callback: (result: Blob | null) => void, type?: string, ...arguments: any[]): void;\n addEventListener(type: K, listener: (this: HTMLCanvasElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLCanvasElement: {\n prototype: HTMLCanvasElement;\n new(): HTMLCanvasElement;\n};\n\ninterface HTMLCollectionBase {\n /**\n * Sets or retrieves the number of objects in a collection.\n */\n readonly length: number;\n /**\n * Retrieves an object from various collections.\n */\n item(index: number): Element;\n [index: number]: Element;\n}\n\ninterface HTMLCollection extends HTMLCollectionBase {\n /**\n * Retrieves a select object or an object from an options collection.\n */\n namedItem(name: string): Element | null;\n}\n\ndeclare var HTMLCollection: {\n prototype: HTMLCollection;\n new(): HTMLCollection;\n};\n\ninterface HTMLDataElement extends HTMLElement {\n value: string;\n addEventListener(type: K, listener: (this: HTMLDataElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDataElement: {\n prototype: HTMLDataElement;\n new(): HTMLDataElement;\n};\n\ninterface HTMLDataListElement extends HTMLElement {\n options: HTMLCollectionOf;\n addEventListener(type: K, listener: (this: HTMLDataListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDataListElement: {\n prototype: HTMLDataListElement;\n new(): HTMLDataListElement;\n};\n\ninterface HTMLDirectoryElement extends HTMLElement {\n compact: boolean;\n addEventListener(type: K, listener: (this: HTMLDirectoryElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDirectoryElement: {\n prototype: HTMLDirectoryElement;\n new(): HTMLDirectoryElement;\n};\n\ninterface HTMLDivElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves whether the browser automatically performs wordwrap.\n */\n noWrap: boolean;\n addEventListener(type: K, listener: (this: HTMLDivElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDivElement: {\n prototype: HTMLDivElement;\n new(): HTMLDivElement;\n};\n\ninterface HTMLDListElement extends HTMLElement {\n compact: boolean;\n addEventListener(type: K, listener: (this: HTMLDListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDListElement: {\n prototype: HTMLDListElement;\n new(): HTMLDListElement;\n};\n\ninterface HTMLDocument extends Document {\n addEventListener(type: K, listener: (this: HTMLDocument, ev: DocumentEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDocument: {\n prototype: HTMLDocument;\n new(): HTMLDocument;\n};\n\ninterface HTMLElementEventMap extends ElementEventMap {\n \"abort\": UIEvent;\n \"activate\": UIEvent;\n \"beforeactivate\": UIEvent;\n \"beforecopy\": ClipboardEvent;\n \"beforecut\": ClipboardEvent;\n \"beforedeactivate\": UIEvent;\n \"beforepaste\": ClipboardEvent;\n \"blur\": FocusEvent;\n \"canplay\": Event;\n \"canplaythrough\": Event;\n \"change\": Event;\n \"click\": MouseEvent;\n \"contextmenu\": PointerEvent;\n \"copy\": ClipboardEvent;\n \"cuechange\": Event;\n \"cut\": ClipboardEvent;\n \"dblclick\": MouseEvent;\n \"deactivate\": UIEvent;\n \"drag\": DragEvent;\n \"dragend\": DragEvent;\n \"dragenter\": DragEvent;\n \"dragleave\": DragEvent;\n \"dragover\": DragEvent;\n \"dragstart\": DragEvent;\n \"drop\": DragEvent;\n \"durationchange\": Event;\n \"emptied\": Event;\n \"ended\": MediaStreamErrorEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"input\": Event;\n \"invalid\": Event;\n \"keydown\": KeyboardEvent;\n \"keypress\": KeyboardEvent;\n \"keyup\": KeyboardEvent;\n \"load\": Event;\n \"loadeddata\": Event;\n \"loadedmetadata\": Event;\n \"loadstart\": Event;\n \"mousedown\": MouseEvent;\n \"mouseenter\": MouseEvent;\n \"mouseleave\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n \"mousewheel\": WheelEvent;\n \"MSContentZoom\": UIEvent;\n \"MSManipulationStateChanged\": MSManipulationEvent;\n \"paste\": ClipboardEvent;\n \"pause\": Event;\n \"play\": Event;\n \"playing\": Event;\n \"progress\": ProgressEvent;\n \"ratechange\": Event;\n \"reset\": Event;\n \"scroll\": UIEvent;\n \"seeked\": Event;\n \"seeking\": Event;\n \"select\": UIEvent;\n \"selectstart\": Event;\n \"stalled\": Event;\n \"submit\": Event;\n \"suspend\": Event;\n \"timeupdate\": Event;\n \"volumechange\": Event;\n \"waiting\": Event;\n}\n\ninterface HTMLElement extends Element {\n accessKey: string;\n readonly children: HTMLCollection;\n contentEditable: string;\n readonly dataset: DOMStringMap;\n dir: string;\n draggable: boolean;\n hidden: boolean;\n hideFocus: boolean;\n innerText: string;\n readonly isContentEditable: boolean;\n lang: string;\n readonly offsetHeight: number;\n readonly offsetLeft: number;\n readonly offsetParent: Element;\n readonly offsetTop: number;\n readonly offsetWidth: number;\n onabort: (this: HTMLElement, ev: UIEvent) => any;\n onactivate: (this: HTMLElement, ev: UIEvent) => any;\n onbeforeactivate: (this: HTMLElement, ev: UIEvent) => any;\n onbeforecopy: (this: HTMLElement, ev: ClipboardEvent) => any;\n onbeforecut: (this: HTMLElement, ev: ClipboardEvent) => any;\n onbeforedeactivate: (this: HTMLElement, ev: UIEvent) => any;\n onbeforepaste: (this: HTMLElement, ev: ClipboardEvent) => any;\n onblur: (this: HTMLElement, ev: FocusEvent) => any;\n oncanplay: (this: HTMLElement, ev: Event) => any;\n oncanplaythrough: (this: HTMLElement, ev: Event) => any;\n onchange: (this: HTMLElement, ev: Event) => any;\n onclick: (this: HTMLElement, ev: MouseEvent) => any;\n oncontextmenu: (this: HTMLElement, ev: PointerEvent) => any;\n oncopy: (this: HTMLElement, ev: ClipboardEvent) => any;\n oncuechange: (this: HTMLElement, ev: Event) => any;\n oncut: (this: HTMLElement, ev: ClipboardEvent) => any;\n ondblclick: (this: HTMLElement, ev: MouseEvent) => any;\n ondeactivate: (this: HTMLElement, ev: UIEvent) => any;\n ondrag: (this: HTMLElement, ev: DragEvent) => any;\n ondragend: (this: HTMLElement, ev: DragEvent) => any;\n ondragenter: (this: HTMLElement, ev: DragEvent) => any;\n ondragleave: (this: HTMLElement, ev: DragEvent) => any;\n ondragover: (this: HTMLElement, ev: DragEvent) => any;\n ondragstart: (this: HTMLElement, ev: DragEvent) => any;\n ondrop: (this: HTMLElement, ev: DragEvent) => any;\n ondurationchange: (this: HTMLElement, ev: Event) => any;\n onemptied: (this: HTMLElement, ev: Event) => any;\n onended: (this: HTMLElement, ev: MediaStreamErrorEvent) => any;\n onerror: (this: HTMLElement, ev: ErrorEvent) => any;\n onfocus: (this: HTMLElement, ev: FocusEvent) => any;\n oninput: (this: HTMLElement, ev: Event) => any;\n oninvalid: (this: HTMLElement, ev: Event) => any;\n onkeydown: (this: HTMLElement, ev: KeyboardEvent) => any;\n onkeypress: (this: HTMLElement, ev: KeyboardEvent) => any;\n onkeyup: (this: HTMLElement, ev: KeyboardEvent) => any;\n onload: (this: HTMLElement, ev: Event) => any;\n onloadeddata: (this: HTMLElement, ev: Event) => any;\n onloadedmetadata: (this: HTMLElement, ev: Event) => any;\n onloadstart: (this: HTMLElement, ev: Event) => any;\n onmousedown: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseenter: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseleave: (this: HTMLElement, ev: MouseEvent) => any;\n onmousemove: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseout: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseover: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseup: (this: HTMLElement, ev: MouseEvent) => any;\n onmousewheel: (this: HTMLElement, ev: WheelEvent) => any;\n onmscontentzoom: (this: HTMLElement, ev: UIEvent) => any;\n onmsmanipulationstatechanged: (this: HTMLElement, ev: MSManipulationEvent) => any;\n onpaste: (this: HTMLElement, ev: ClipboardEvent) => any;\n onpause: (this: HTMLElement, ev: Event) => any;\n onplay: (this: HTMLElement, ev: Event) => any;\n onplaying: (this: HTMLElement, ev: Event) => any;\n onprogress: (this: HTMLElement, ev: ProgressEvent) => any;\n onratechange: (this: HTMLElement, ev: Event) => any;\n onreset: (this: HTMLElement, ev: Event) => any;\n onscroll: (this: HTMLElement, ev: UIEvent) => any;\n onseeked: (this: HTMLElement, ev: Event) => any;\n onseeking: (this: HTMLElement, ev: Event) => any;\n onselect: (this: HTMLElement, ev: UIEvent) => any;\n onselectstart: (this: HTMLElement, ev: Event) => any;\n onstalled: (this: HTMLElement, ev: Event) => any;\n onsubmit: (this: HTMLElement, ev: Event) => any;\n onsuspend: (this: HTMLElement, ev: Event) => any;\n ontimeupdate: (this: HTMLElement, ev: Event) => any;\n onvolumechange: (this: HTMLElement, ev: Event) => any;\n onwaiting: (this: HTMLElement, ev: Event) => any;\n outerText: string;\n spellcheck: boolean;\n readonly style: CSSStyleDeclaration;\n tabIndex: number;\n title: string;\n blur(): void;\n click(): void;\n dragDrop(): boolean;\n focus(): void;\n msGetInputContext(): MSInputMethodContext;\n addEventListener(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLElement: {\n prototype: HTMLElement;\n new(): HTMLElement;\n};\n\ninterface HTMLEmbedElement extends HTMLElement, GetSVGDocument {\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n hidden: any;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n /**\n * Gets or sets the path to the preferred media source. This enables the Play To target device to stream the media content, which can be DRM protected, from a different location, such as a cloud media server.\n */\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Retrieves the palette used for the embedded document.\n */\n readonly palette: string;\n /**\n * Retrieves the URL of the plug-in used to view an embedded document.\n */\n readonly pluginspage: string;\n readonly readyState: string;\n /**\n * Sets or retrieves a URL to be loaded by the object.\n */\n src: string;\n /**\n * Sets or retrieves the height and width units of the embed object.\n */\n units: string;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n addEventListener(type: K, listener: (this: HTMLEmbedElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLEmbedElement: {\n prototype: HTMLEmbedElement;\n new(): HTMLEmbedElement;\n};\n\ninterface HTMLFieldSetElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n name: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLFieldSetElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFieldSetElement: {\n prototype: HTMLFieldSetElement;\n new(): HTMLFieldSetElement;\n};\n\ninterface HTMLFontElement extends HTMLElement, DOML2DeprecatedColorProperty, DOML2DeprecatedSizeProperty {\n /**\n * Sets or retrieves the current typeface family.\n */\n face: string;\n addEventListener(type: K, listener: (this: HTMLFontElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFontElement: {\n prototype: HTMLFontElement;\n new(): HTMLFontElement;\n};\n\ninterface HTMLFormControlsCollection extends HTMLCollectionBase {\n namedItem(name: string): HTMLCollection | Element | null;\n}\n\ndeclare var HTMLFormControlsCollection: {\n prototype: HTMLFormControlsCollection;\n new(): HTMLFormControlsCollection;\n};\n\ninterface HTMLFormElement extends HTMLElement {\n /**\n * Sets or retrieves a list of character encodings for input data that must be accepted by the server processing the form.\n */\n acceptCharset: string;\n /**\n * Sets or retrieves the URL to which the form content is sent for processing.\n */\n action: string;\n /**\n * Specifies whether autocomplete is applied to an editable text field.\n */\n autocomplete: string;\n /**\n * Retrieves a collection, in source order, of all controls in a given form.\n */\n readonly elements: HTMLFormControlsCollection;\n /**\n * Sets or retrieves the MIME encoding for the form.\n */\n encoding: string;\n /**\n * Sets or retrieves the encoding type for the form.\n */\n enctype: string;\n /**\n * Sets or retrieves the number of objects in a collection.\n */\n readonly length: number;\n /**\n * Sets or retrieves how to send the form data to the server.\n */\n method: string;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Designates a form that is not validated when submitted.\n */\n noValidate: boolean;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Retrieves a form object or an object from an elements collection.\n * @param name Variant of type Number or String that specifies the object or collection to retrieve. If this parameter is a Number, it is the zero-based index of the object. If this parameter is a string, all objects with matching name or id properties are retrieved, and a collection is returned if more than one match is made.\n * @param index Variant of type Number that specifies the zero-based index of the object to retrieve when a collection is returned.\n */\n item(name?: any, index?: any): any;\n /**\n * Retrieves a form object or an object from an elements collection.\n */\n namedItem(name: string): any;\n /**\n * Fires when the user resets a form.\n */\n reset(): void;\n /**\n * Fires when a FORM is about to be submitted.\n */\n submit(): void;\n addEventListener(type: K, listener: (this: HTMLFormElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [name: string]: any;\n}\n\ndeclare var HTMLFormElement: {\n prototype: HTMLFormElement;\n new(): HTMLFormElement;\n};\n\ninterface HTMLFrameElementEventMap extends HTMLElementEventMap {\n \"load\": Event;\n}\n\ninterface HTMLFrameElement extends HTMLElement, GetSVGDocument {\n /**\n * Specifies the properties of a border drawn around an object.\n */\n border: string;\n /**\n * Sets or retrieves the border color of the object.\n */\n borderColor: any;\n /**\n * Retrieves the document object of the page or frame.\n */\n readonly contentDocument: Document;\n /**\n * Retrieves the object of the specified.\n */\n readonly contentWindow: Window;\n /**\n * Sets or retrieves whether to display a border for the frame.\n */\n frameBorder: string;\n /**\n * Sets or retrieves the amount of additional space between the frames.\n */\n frameSpacing: any;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string | number;\n /**\n * Sets or retrieves a URI to a long description of the object.\n */\n longDesc: string;\n /**\n * Sets or retrieves the top and bottom margin heights before displaying the text in a frame.\n */\n marginHeight: string;\n /**\n * Sets or retrieves the left and right margin widths before displaying the text in a frame.\n */\n marginWidth: string;\n /**\n * Sets or retrieves the frame name.\n */\n name: string;\n /**\n * Sets or retrieves whether the user can resize the frame.\n */\n noResize: boolean;\n /**\n * Raised when the object has been completely received from the server.\n */\n onload: (this: HTMLFrameElement, ev: Event) => any;\n /**\n * Sets or retrieves whether the frame can be scrolled.\n */\n scrolling: string;\n /**\n * Sets or retrieves a URL to be loaded by the object.\n */\n src: string;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string | number;\n addEventListener(type: K, listener: (this: HTMLFrameElement, ev: HTMLFrameElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFrameElement: {\n prototype: HTMLFrameElement;\n new(): HTMLFrameElement;\n};\n\ninterface HTMLFrameSetElementEventMap extends HTMLElementEventMap {\n \"afterprint\": Event;\n \"beforeprint\": Event;\n \"beforeunload\": BeforeUnloadEvent;\n \"blur\": FocusEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"hashchange\": HashChangeEvent;\n \"load\": Event;\n \"message\": MessageEvent;\n \"offline\": Event;\n \"online\": Event;\n \"orientationchange\": Event;\n \"pagehide\": PageTransitionEvent;\n \"pageshow\": PageTransitionEvent;\n \"popstate\": PopStateEvent;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"storage\": StorageEvent;\n \"unload\": Event;\n}\n\ninterface HTMLFrameSetElement extends HTMLElement {\n border: string;\n /**\n * Sets or retrieves the border color of the object.\n */\n borderColor: any;\n /**\n * Sets or retrieves the frame widths of the object.\n */\n cols: string;\n /**\n * Sets or retrieves whether to display a border for the frame.\n */\n frameBorder: string;\n /**\n * Sets or retrieves the amount of additional space between the frames.\n */\n frameSpacing: any;\n name: string;\n onafterprint: (this: HTMLFrameSetElement, ev: Event) => any;\n onbeforeprint: (this: HTMLFrameSetElement, ev: Event) => any;\n onbeforeunload: (this: HTMLFrameSetElement, ev: BeforeUnloadEvent) => any;\n /**\n * Fires when the object loses the input focus.\n */\n onblur: (this: HTMLFrameSetElement, ev: FocusEvent) => any;\n onerror: (this: HTMLFrameSetElement, ev: ErrorEvent) => any;\n /**\n * Fires when the object receives focus.\n */\n onfocus: (this: HTMLFrameSetElement, ev: FocusEvent) => any;\n onhashchange: (this: HTMLFrameSetElement, ev: HashChangeEvent) => any;\n onload: (this: HTMLFrameSetElement, ev: Event) => any;\n onmessage: (this: HTMLFrameSetElement, ev: MessageEvent) => any;\n onoffline: (this: HTMLFrameSetElement, ev: Event) => any;\n ononline: (this: HTMLFrameSetElement, ev: Event) => any;\n onorientationchange: (this: HTMLFrameSetElement, ev: Event) => any;\n onpagehide: (this: HTMLFrameSetElement, ev: PageTransitionEvent) => any;\n onpageshow: (this: HTMLFrameSetElement, ev: PageTransitionEvent) => any;\n onpopstate: (this: HTMLFrameSetElement, ev: PopStateEvent) => any;\n onresize: (this: HTMLFrameSetElement, ev: UIEvent) => any;\n onscroll: (this: HTMLFrameSetElement, ev: UIEvent) => any;\n onstorage: (this: HTMLFrameSetElement, ev: StorageEvent) => any;\n onunload: (this: HTMLFrameSetElement, ev: Event) => any;\n /**\n * Sets or retrieves the frame heights of the object.\n */\n rows: string;\n addEventListener(type: K, listener: (this: HTMLFrameSetElement, ev: HTMLFrameSetElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFrameSetElement: {\n prototype: HTMLFrameSetElement;\n new(): HTMLFrameSetElement;\n};\n\ninterface HTMLHeadElement extends HTMLElement {\n profile: string;\n addEventListener(type: K, listener: (this: HTMLHeadElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHeadElement: {\n prototype: HTMLHeadElement;\n new(): HTMLHeadElement;\n};\n\ninterface HTMLHeadingElement extends HTMLElement {\n /**\n * Sets or retrieves a value that indicates the table alignment.\n */\n align: string;\n addEventListener(type: K, listener: (this: HTMLHeadingElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHeadingElement: {\n prototype: HTMLHeadingElement;\n new(): HTMLHeadingElement;\n};\n\ninterface HTMLHRElement extends HTMLElement, DOML2DeprecatedColorProperty, DOML2DeprecatedSizeProperty {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves whether the horizontal rule is drawn with 3-D shading.\n */\n noShade: boolean;\n /**\n * Sets or retrieves the width of the object.\n */\n width: number;\n addEventListener(type: K, listener: (this: HTMLHRElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHRElement: {\n prototype: HTMLHRElement;\n new(): HTMLHRElement;\n};\n\ninterface HTMLHtmlElement extends HTMLElement {\n /**\n * Sets or retrieves the DTD version that governs the current document.\n */\n version: string;\n addEventListener(type: K, listener: (this: HTMLHtmlElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHtmlElement: {\n prototype: HTMLHtmlElement;\n new(): HTMLHtmlElement;\n};\n\ninterface HTMLIFrameElementEventMap extends HTMLElementEventMap {\n \"load\": Event;\n}\n\ninterface HTMLIFrameElement extends HTMLElement, GetSVGDocument {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n allowFullscreen: boolean;\n allowPaymentRequest: boolean;\n /**\n * Specifies the properties of a border drawn around an object.\n */\n border: string;\n /**\n * Retrieves the document object of the page or frame.\n */\n readonly contentDocument: Document;\n /**\n * Retrieves the object of the specified.\n */\n readonly contentWindow: Window;\n /**\n * Sets or retrieves whether to display a border for the frame.\n */\n frameBorder: string;\n /**\n * Sets or retrieves the amount of additional space between the frames.\n */\n frameSpacing: any;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n /**\n * Sets or retrieves the horizontal margin for the object.\n */\n hspace: number;\n /**\n * Sets or retrieves a URI to a long description of the object.\n */\n longDesc: string;\n /**\n * Sets or retrieves the top and bottom margin heights before displaying the text in a frame.\n */\n marginHeight: string;\n /**\n * Sets or retrieves the left and right margin widths before displaying the text in a frame.\n */\n marginWidth: string;\n /**\n * Sets or retrieves the frame name.\n */\n name: string;\n /**\n * Sets or retrieves whether the user can resize the frame.\n */\n noResize: boolean;\n /**\n * Raised when the object has been completely received from the server.\n */\n onload: (this: HTMLIFrameElement, ev: Event) => any;\n readonly sandbox: DOMSettableTokenList;\n /**\n * Sets or retrieves whether the frame can be scrolled.\n */\n scrolling: string;\n /**\n * Sets or retrieves a URL to be loaded by the object.\n */\n src: string;\n /**\n * Sets or retrieves the vertical margin for the object.\n */\n vspace: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n addEventListener(type: K, listener: (this: HTMLIFrameElement, ev: HTMLIFrameElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLIFrameElement: {\n prototype: HTMLIFrameElement;\n new(): HTMLIFrameElement;\n};\n\ninterface HTMLImageElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Specifies the properties of a border drawn around an object.\n */\n border: string;\n /**\n * Retrieves whether the object is fully loaded.\n */\n readonly complete: boolean;\n crossOrigin: string | null;\n readonly currentSrc: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: number;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n hspace: number;\n /**\n * Sets or retrieves whether the image is a server-side image map.\n */\n isMap: boolean;\n /**\n * Sets or retrieves a Uniform Resource Identifier (URI) to a long description of the object.\n */\n longDesc: string;\n lowsrc: string;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * The original height of the image resource before sizing.\n */\n readonly naturalHeight: number;\n /**\n * The original width of the image resource before sizing.\n */\n readonly naturalWidth: number;\n sizes: string;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n srcset: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n /**\n * Sets or retrieves the vertical margin for the object.\n */\n vspace: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: number;\n readonly x: number;\n readonly y: number;\n msGetAsCastingSource(): any;\n addEventListener(type: K, listener: (this: HTMLImageElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLImageElement: {\n prototype: HTMLImageElement;\n new(): HTMLImageElement;\n};\n\ninterface HTMLInputElement extends HTMLElement {\n /**\n * Sets or retrieves a comma-separated list of content types.\n */\n accept: string;\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Specifies whether autocomplete is applied to an editable text field.\n */\n autocomplete: string;\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n border: string;\n /**\n * Sets or retrieves the state of the check box or radio button.\n */\n checked: boolean;\n /**\n * Retrieves whether the object is fully loaded.\n */\n readonly complete: boolean;\n /**\n * Sets or retrieves the state of the check box or radio button.\n */\n defaultChecked: boolean;\n /**\n * Sets or retrieves the initial contents of the object.\n */\n defaultValue: string;\n disabled: boolean;\n /**\n * Returns a FileList object on a file type input object.\n */\n readonly files: FileList | null;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Overrides the action attribute (where the data on a form is sent) on the parent form element.\n */\n formAction: string;\n /**\n * Used to override the encoding (formEnctype attribute) specified on the form element.\n */\n formEnctype: string;\n /**\n * Overrides the submit method attribute previously specified on a form element.\n */\n formMethod: string;\n /**\n * Overrides any validation or required attributes on a form or form elements to allow it to be submitted without validation. This can be used to create a \"save draft\"-type submit option.\n */\n formNoValidate: string;\n /**\n * Overrides the target attribute on a form element.\n */\n formTarget: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n hspace: number;\n indeterminate: boolean;\n /**\n * Specifies the ID of a pre-defined datalist of options for an input element.\n */\n readonly list: HTMLElement;\n /**\n * Defines the maximum acceptable value for an input element with type=\"number\".When used with the min and step attributes, lets you control the range and increment (such as only even numbers) that the user can enter into an input field.\n */\n max: string;\n /**\n * Sets or retrieves the maximum number of characters that the user can enter in a text control.\n */\n maxLength: number;\n /**\n * Defines the minimum acceptable value for an input element with type=\"number\". When used with the max and step attributes, lets you control the range and increment (such as even numbers only) that the user can enter into an input field.\n */\n min: string;\n /**\n * Sets or retrieves the Boolean value indicating whether multiple items can be selected from a list.\n */\n multiple: boolean;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Gets or sets a string containing a regular expression that the user's input must match.\n */\n pattern: string;\n /**\n * Gets or sets a text string that is displayed in an input field as a hint or prompt to users as the format or type of information they need to enter.The text appears in an input field until the user puts focus on the field.\n */\n placeholder: string;\n readOnly: boolean;\n /**\n * When present, marks an element that can't be submitted without a value.\n */\n required: boolean;\n selectionDirection: string;\n /**\n * Gets or sets the end position or offset of a text selection.\n */\n selectionEnd: number;\n /**\n * Gets or sets the starting position or offset of a text selection.\n */\n selectionStart: number;\n size: number;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n status: boolean;\n /**\n * Defines an increment or jump between values that you want to allow the user to enter. When used with the max and min attributes, lets you control the range and increment (for example, allow only even numbers) that the user can enter into an input field.\n */\n step: string;\n /**\n * Returns the content type of the object.\n */\n type: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Returns the value of the data at the cursor's current position.\n */\n value: string;\n valueAsDate: Date;\n /**\n * Returns the input field value as a number.\n */\n valueAsNumber: number;\n /**\n * Sets or retrieves the vertical margin for the object.\n */\n vspace: number;\n webkitdirectory: boolean;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n minLength: number;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Makes the selection equal to the current object.\n */\n select(): void;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n /**\n * Sets the start and end positions of a selection in a text field.\n * @param start The offset into the text field for the start of the selection.\n * @param end The offset into the text field for the end of the selection.\n */\n setSelectionRange(start?: number, end?: number, direction?: string): void;\n /**\n * Decrements a range input control's value by the value given by the Step attribute. If the optional parameter is used, it will decrement the input control's step value multiplied by the parameter's value.\n * @param n Value to decrement the value by.\n */\n stepDown(n?: number): void;\n /**\n * Increments a range input control's value by the value given by the Step attribute. If the optional parameter is used, will increment the input control's value by that value.\n * @param n Value to increment the value by.\n */\n stepUp(n?: number): void;\n addEventListener(type: K, listener: (this: HTMLInputElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLInputElement: {\n prototype: HTMLInputElement;\n new(): HTMLInputElement;\n};\n\ninterface HTMLLabelElement extends HTMLElement {\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the object to which the given label object is assigned.\n */\n htmlFor: string;\n addEventListener(type: K, listener: (this: HTMLLabelElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLabelElement: {\n prototype: HTMLLabelElement;\n new(): HTMLLabelElement;\n};\n\ninterface HTMLLegendElement extends HTMLElement {\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n align: string;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n addEventListener(type: K, listener: (this: HTMLLegendElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLegendElement: {\n prototype: HTMLLegendElement;\n new(): HTMLLegendElement;\n};\n\ninterface HTMLLIElement extends HTMLElement {\n type: string;\n /**\n * Sets or retrieves the value of a list item.\n */\n value: number;\n addEventListener(type: K, listener: (this: HTMLLIElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLIElement: {\n prototype: HTMLLIElement;\n new(): HTMLLIElement;\n};\n\ninterface HTMLLinkElement extends HTMLElement, LinkStyle {\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n disabled: boolean;\n /**\n * Sets or retrieves a destination URL or an anchor point.\n */\n href: string;\n /**\n * Sets or retrieves the language code of the object.\n */\n hreflang: string;\n /**\n * Sets or retrieves the media type.\n */\n media: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rel: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rev: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Sets or retrieves the MIME type of the object.\n */\n type: string;\n import?: Document;\n integrity: string;\n addEventListener(type: K, listener: (this: HTMLLinkElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLinkElement: {\n prototype: HTMLLinkElement;\n new(): HTMLLinkElement;\n};\n\ninterface HTMLMapElement extends HTMLElement {\n /**\n * Retrieves a collection of the area objects defined for the given map object.\n */\n readonly areas: HTMLAreasCollection;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n addEventListener(type: K, listener: (this: HTMLMapElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMapElement: {\n prototype: HTMLMapElement;\n new(): HTMLMapElement;\n};\n\ninterface HTMLMarqueeElementEventMap extends HTMLElementEventMap {\n \"bounce\": Event;\n \"finish\": Event;\n \"start\": Event;\n}\n\ninterface HTMLMarqueeElement extends HTMLElement {\n behavior: string;\n bgColor: any;\n direction: string;\n height: string;\n hspace: number;\n loop: number;\n onbounce: (this: HTMLMarqueeElement, ev: Event) => any;\n onfinish: (this: HTMLMarqueeElement, ev: Event) => any;\n onstart: (this: HTMLMarqueeElement, ev: Event) => any;\n scrollAmount: number;\n scrollDelay: number;\n trueSpeed: boolean;\n vspace: number;\n width: string;\n start(): void;\n stop(): void;\n addEventListener(type: K, listener: (this: HTMLMarqueeElement, ev: HTMLMarqueeElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMarqueeElement: {\n prototype: HTMLMarqueeElement;\n new(): HTMLMarqueeElement;\n};\n\ninterface HTMLMediaElementEventMap extends HTMLElementEventMap {\n \"encrypted\": MediaEncryptedEvent;\n \"msneedkey\": MSMediaKeyNeededEvent;\n}\n\ninterface HTMLMediaElement extends HTMLElement {\n /**\n * Returns an AudioTrackList object with the audio tracks for a given video element.\n */\n readonly audioTracks: AudioTrackList;\n /**\n * Gets or sets a value that indicates whether to start playing the media automatically.\n */\n autoplay: boolean;\n /**\n * Gets a collection of buffered time ranges.\n */\n readonly buffered: TimeRanges;\n /**\n * Gets or sets a flag that indicates whether the client provides a set of controls for the media (in case the developer does not include controls for the player).\n */\n controls: boolean;\n crossOrigin: string | null;\n /**\n * Gets the address or URL of the current media resource that is selected by IHTMLMediaElement.\n */\n readonly currentSrc: string;\n /**\n * Gets or sets the current playback position, in seconds.\n */\n currentTime: number;\n defaultMuted: boolean;\n /**\n * Gets or sets the default playback rate when the user is not using fast forward or reverse for a video or audio resource.\n */\n defaultPlaybackRate: number;\n /**\n * Returns the duration in seconds of the current media resource. A NaN value is returned if duration is not available, or Infinity if the media resource is streaming.\n */\n readonly duration: number;\n /**\n * Gets information about whether the playback has ended or not.\n */\n readonly ended: boolean;\n /**\n * Returns an object representing the current error state of the audio or video element.\n */\n readonly error: MediaError;\n /**\n * Gets or sets a flag to specify whether playback should restart after it completes.\n */\n loop: boolean;\n readonly mediaKeys: MediaKeys | null;\n /**\n * Specifies the purpose of the audio or video media, such as background audio or alerts.\n */\n msAudioCategory: string;\n /**\n * Specifies the output device id that the audio will be sent to.\n */\n msAudioDeviceType: string;\n readonly msGraphicsTrustStatus: MSGraphicsTrust;\n /**\n * Gets the MSMediaKeys object, which is used for decrypting media data, that is associated with this media element.\n */\n readonly msKeys: MSMediaKeys;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n /**\n * Gets or sets the path to the preferred media source. This enables the Play To target device to stream the media content, which can be DRM protected, from a different location, such as a cloud media server.\n */\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Specifies whether or not to enable low-latency playback on the media element.\n */\n msRealTime: boolean;\n /**\n * Gets or sets a flag that indicates whether the audio (either audio or the audio track on video media) is muted.\n */\n muted: boolean;\n /**\n * Gets the current network activity for the element.\n */\n readonly networkState: number;\n onencrypted: (this: HTMLMediaElement, ev: MediaEncryptedEvent) => any;\n onmsneedkey: (this: HTMLMediaElement, ev: MSMediaKeyNeededEvent) => any;\n /**\n * Gets a flag that specifies whether playback is paused.\n */\n readonly paused: boolean;\n /**\n * Gets or sets the current rate of speed for the media resource to play. This speed is expressed as a multiple of the normal speed of the media resource.\n */\n playbackRate: number;\n /**\n * Gets TimeRanges for the current media resource that has been played.\n */\n readonly played: TimeRanges;\n /**\n * Gets or sets the current playback position, in seconds.\n */\n preload: string;\n readyState: number;\n /**\n * Returns a TimeRanges object that represents the ranges of the current media resource that can be seeked.\n */\n readonly seekable: TimeRanges;\n /**\n * Gets a flag that indicates whether the the client is currently moving to a new playback position in the media resource.\n */\n readonly seeking: boolean;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n srcObject: MediaStream | null;\n readonly textTracks: TextTrackList;\n readonly videoTracks: VideoTrackList;\n /**\n * Gets or sets the volume level for audio portions of the media element.\n */\n volume: number;\n addTextTrack(kind: string, label?: string, language?: string): TextTrack;\n /**\n * Returns a string that specifies whether the client can play a given media resource type.\n */\n canPlayType(type: string): string;\n /**\n * Resets the audio or video object and loads a new media resource.\n */\n load(): void;\n /**\n * Clears all effects from the media pipeline.\n */\n msClearEffects(): void;\n msGetAsCastingSource(): any;\n /**\n * Inserts the specified audio effect into media pipeline.\n */\n msInsertAudioEffect(activatableClassId: string, effectRequired: boolean, config?: any): void;\n msSetMediaKeys(mediaKeys: MSMediaKeys): void;\n /**\n * Specifies the media protection manager for a given media pipeline.\n */\n msSetMediaProtectionManager(mediaProtectionManager?: any): void;\n /**\n * Pauses the current playback and sets paused to TRUE. This can be used to test whether the media is playing or paused. You can also use the pause or play events to tell whether the media is playing or not.\n */\n pause(): void;\n /**\n * Loads and starts playback of a media resource.\n */\n play(): Promise;\n setMediaKeys(mediaKeys: MediaKeys | null): Promise;\n readonly HAVE_CURRENT_DATA: number;\n readonly HAVE_ENOUGH_DATA: number;\n readonly HAVE_FUTURE_DATA: number;\n readonly HAVE_METADATA: number;\n readonly HAVE_NOTHING: number;\n readonly NETWORK_EMPTY: number;\n readonly NETWORK_IDLE: number;\n readonly NETWORK_LOADING: number;\n readonly NETWORK_NO_SOURCE: number;\n addEventListener(type: K, listener: (this: HTMLMediaElement, ev: HTMLMediaElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMediaElement: {\n prototype: HTMLMediaElement;\n new(): HTMLMediaElement;\n readonly HAVE_CURRENT_DATA: number;\n readonly HAVE_ENOUGH_DATA: number;\n readonly HAVE_FUTURE_DATA: number;\n readonly HAVE_METADATA: number;\n readonly HAVE_NOTHING: number;\n readonly NETWORK_EMPTY: number;\n readonly NETWORK_IDLE: number;\n readonly NETWORK_LOADING: number;\n readonly NETWORK_NO_SOURCE: number;\n};\n\ninterface HTMLMenuElement extends HTMLElement {\n compact: boolean;\n type: string;\n addEventListener(type: K, listener: (this: HTMLMenuElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMenuElement: {\n prototype: HTMLMenuElement;\n new(): HTMLMenuElement;\n};\n\ninterface HTMLMetaElement extends HTMLElement {\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n /**\n * Gets or sets meta-information to associate with httpEquiv or name.\n */\n content: string;\n /**\n * Gets or sets information used to bind the value of a content attribute of a meta element to an HTTP response header.\n */\n httpEquiv: string;\n /**\n * Sets or retrieves the value specified in the content attribute of the meta object.\n */\n name: string;\n /**\n * Sets or retrieves a scheme to be used in interpreting the value of a property specified for the object.\n */\n scheme: string;\n /**\n * Sets or retrieves the URL property that will be loaded after the specified time has elapsed.\n */\n url: string;\n addEventListener(type: K, listener: (this: HTMLMetaElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMetaElement: {\n prototype: HTMLMetaElement;\n new(): HTMLMetaElement;\n};\n\ninterface HTMLMeterElement extends HTMLElement {\n high: number;\n low: number;\n max: number;\n min: number;\n optimum: number;\n value: number;\n addEventListener(type: K, listener: (this: HTMLMeterElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMeterElement: {\n prototype: HTMLMeterElement;\n new(): HTMLMeterElement;\n};\n\ninterface HTMLModElement extends HTMLElement {\n /**\n * Sets or retrieves reference information about the object.\n */\n cite: string;\n /**\n * Sets or retrieves the date and time of a modification to the object.\n */\n dateTime: string;\n addEventListener(type: K, listener: (this: HTMLModElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLModElement: {\n prototype: HTMLModElement;\n new(): HTMLModElement;\n};\n\ninterface HTMLObjectElement extends HTMLElement, GetSVGDocument {\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Gets or sets the optional alternative HTML script to execute if the object fails to load.\n */\n altHtml: string;\n /**\n * Sets or retrieves a character string that can be used to implement your own archive functionality for the object.\n */\n archive: string;\n /**\n * Retrieves a string of the URL where the object tag can be found. This is often the href of the document that the object is in, or the value set by a base element.\n */\n readonly BaseHref: string;\n border: string;\n /**\n * Sets or retrieves the URL of the file containing the compiled Java class.\n */\n code: string;\n /**\n * Sets or retrieves the URL of the component.\n */\n codeBase: string;\n /**\n * Sets or retrieves the Internet media type for the code associated with the object.\n */\n codeType: string;\n /**\n * Retrieves the document object of the page or frame.\n */\n readonly contentDocument: Document;\n /**\n * Sets or retrieves the URL that references the data of the object.\n */\n data: string;\n declare: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n hspace: number;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n /**\n * Gets or sets the path to the preferred media source. This enables the Play To target device to stream the media content, which can be DRM protected, from a different location, such as a cloud media server.\n */\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n readonly readyState: number;\n /**\n * Sets or retrieves a message to be displayed while an object is loading.\n */\n standby: string;\n /**\n * Sets or retrieves the MIME type of the object.\n */\n type: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n vspace: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLObjectElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLObjectElement: {\n prototype: HTMLObjectElement;\n new(): HTMLObjectElement;\n};\n\ninterface HTMLOListElement extends HTMLElement {\n compact: boolean;\n /**\n * The starting number.\n */\n start: number;\n type: string;\n addEventListener(type: K, listener: (this: HTMLOListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOListElement: {\n prototype: HTMLOListElement;\n new(): HTMLOListElement;\n};\n\ninterface HTMLOptGroupElement extends HTMLElement {\n /**\n * Sets or retrieves the status of an option.\n */\n defaultSelected: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the ordinal position of an option in a list box.\n */\n readonly index: number;\n /**\n * Sets or retrieves a value that you can use to implement your own label functionality for the object.\n */\n label: string;\n /**\n * Sets or retrieves whether the option in the list box is the default item.\n */\n selected: boolean;\n /**\n * Sets or retrieves the text string specified by the option tag.\n */\n readonly text: string;\n /**\n * Sets or retrieves the value which is returned to the server when the form control is submitted.\n */\n value: string;\n addEventListener(type: K, listener: (this: HTMLOptGroupElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOptGroupElement: {\n prototype: HTMLOptGroupElement;\n new(): HTMLOptGroupElement;\n};\n\ninterface HTMLOptionElement extends HTMLElement {\n /**\n * Sets or retrieves the status of an option.\n */\n defaultSelected: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the ordinal position of an option in a list box.\n */\n readonly index: number;\n /**\n * Sets or retrieves a value that you can use to implement your own label functionality for the object.\n */\n label: string;\n /**\n * Sets or retrieves whether the option in the list box is the default item.\n */\n selected: boolean;\n /**\n * Sets or retrieves the text string specified by the option tag.\n */\n text: string;\n /**\n * Sets or retrieves the value which is returned to the server when the form control is submitted.\n */\n value: string;\n addEventListener(type: K, listener: (this: HTMLOptionElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOptionElement: {\n prototype: HTMLOptionElement;\n new(): HTMLOptionElement;\n};\n\ninterface HTMLOptionsCollection extends HTMLCollectionOf {\n length: number;\n selectedIndex: number;\n add(element: HTMLOptionElement | HTMLOptGroupElement, before?: HTMLElement | number): void;\n remove(index: number): void;\n}\n\ndeclare var HTMLOptionsCollection: {\n prototype: HTMLOptionsCollection;\n new(): HTMLOptionsCollection;\n};\n\ninterface HTMLOutputElement extends HTMLElement {\n defaultValue: string;\n readonly form: HTMLFormElement;\n readonly htmlFor: DOMSettableTokenList;\n name: string;\n readonly type: string;\n readonly validationMessage: string;\n readonly validity: ValidityState;\n value: string;\n readonly willValidate: boolean;\n checkValidity(): boolean;\n reportValidity(): boolean;\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLOutputElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOutputElement: {\n prototype: HTMLOutputElement;\n new(): HTMLOutputElement;\n};\n\ninterface HTMLParagraphElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n clear: string;\n addEventListener(type: K, listener: (this: HTMLParagraphElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLParagraphElement: {\n prototype: HTMLParagraphElement;\n new(): HTMLParagraphElement;\n};\n\ninterface HTMLParamElement extends HTMLElement {\n /**\n * Sets or retrieves the name of an input parameter for an element.\n */\n name: string;\n /**\n * Sets or retrieves the content type of the resource designated by the value attribute.\n */\n type: string;\n /**\n * Sets or retrieves the value of an input parameter for an element.\n */\n value: string;\n /**\n * Sets or retrieves the data type of the value attribute.\n */\n valueType: string;\n addEventListener(type: K, listener: (this: HTMLParamElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLParamElement: {\n prototype: HTMLParamElement;\n new(): HTMLParamElement;\n};\n\ninterface HTMLPictureElement extends HTMLElement {\n addEventListener(type: K, listener: (this: HTMLPictureElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLPictureElement: {\n prototype: HTMLPictureElement;\n new(): HTMLPictureElement;\n};\n\ninterface HTMLPreElement extends HTMLElement {\n /**\n * Sets or gets a value that you can use to implement your own width functionality for the object.\n */\n width: number;\n addEventListener(type: K, listener: (this: HTMLPreElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLPreElement: {\n prototype: HTMLPreElement;\n new(): HTMLPreElement;\n};\n\ninterface HTMLProgressElement extends HTMLElement {\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Defines the maximum, or \"done\" value for a progress element.\n */\n max: number;\n /**\n * Returns the quotient of value/max when the value attribute is set (determinate progress bar), or -1 when the value attribute is missing (indeterminate progress bar).\n */\n readonly position: number;\n /**\n * Sets or gets the current value of a progress element. The value must be a non-negative number between 0 and the max value.\n */\n value: number;\n addEventListener(type: K, listener: (this: HTMLProgressElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLProgressElement: {\n prototype: HTMLProgressElement;\n new(): HTMLProgressElement;\n};\n\ninterface HTMLQuoteElement extends HTMLElement {\n /**\n * Sets or retrieves reference information about the object.\n */\n cite: string;\n addEventListener(type: K, listener: (this: HTMLQuoteElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLQuoteElement: {\n prototype: HTMLQuoteElement;\n new(): HTMLQuoteElement;\n};\n\ninterface HTMLScriptElement extends HTMLElement {\n async: boolean;\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n crossOrigin: string | null;\n /**\n * Sets or retrieves the status of the script.\n */\n defer: boolean;\n /**\n * Sets or retrieves the event for which the script is written.\n */\n event: string;\n /**\n * Sets or retrieves the object that is bound to the event script.\n */\n htmlFor: string;\n /**\n * Retrieves the URL to an external file that contains the source code or data.\n */\n src: string;\n /**\n * Retrieves or sets the text of the object as a string.\n */\n text: string;\n /**\n * Sets or retrieves the MIME type for the associated scripting engine.\n */\n type: string;\n integrity: string;\n addEventListener(type: K, listener: (this: HTMLScriptElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLScriptElement: {\n prototype: HTMLScriptElement;\n new(): HTMLScriptElement;\n};\n\ninterface HTMLSelectElement extends HTMLElement {\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the number of objects in a collection.\n */\n length: number;\n /**\n * Sets or retrieves the Boolean value indicating whether multiple items can be selected from a list.\n */\n multiple: boolean;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n readonly options: HTMLOptionsCollection;\n /**\n * When present, marks an element that can't be submitted without a value.\n */\n required: boolean;\n /**\n * Sets or retrieves the index of the selected option in a select object.\n */\n selectedIndex: number;\n selectedOptions: HTMLCollectionOf;\n /**\n * Sets or retrieves the number of rows in the list box.\n */\n size: number;\n /**\n * Retrieves the type of select control based on the value of the MULTIPLE attribute.\n */\n readonly type: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Sets or retrieves the value which is returned to the server when the form control is submitted.\n */\n value: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Adds an element to the areas, controlRange, or options collection.\n * @param element Variant of type Number that specifies the index position in the collection where the element is placed. If no value is given, the method places the element at the end of the collection.\n * @param before Variant of type Object that specifies an element to insert before, or null to append the object to the collection.\n */\n add(element: HTMLElement, before?: HTMLElement | number): void;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Retrieves a select object or an object from an options collection.\n * @param name Variant of type Number or String that specifies the object or collection to retrieve. If this parameter is an integer, it is the zero-based index of the object. If this parameter is a string, all objects with matching name or id properties are retrieved, and a collection is returned if more than one match is made.\n * @param index Variant of type Number that specifies the zero-based index of the object to retrieve when a collection is returned.\n */\n item(name?: any, index?: any): any;\n /**\n * Retrieves a select object or an object from an options collection.\n * @param namedItem A String that specifies the name or id property of the object to retrieve. A collection is returned if more than one match is made.\n */\n namedItem(name: string): any;\n /**\n * Removes an element from the collection.\n * @param index Number that specifies the zero-based index of the element to remove from the collection.\n */\n remove(index?: number): void;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLSelectElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [name: string]: any;\n}\n\ndeclare var HTMLSelectElement: {\n prototype: HTMLSelectElement;\n new(): HTMLSelectElement;\n};\n\ninterface HTMLSourceElement extends HTMLElement {\n /**\n * Gets or sets the intended media type of the media source.\n */\n media: string;\n msKeySystem: string;\n sizes: string;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n srcset: string;\n /**\n * Gets or sets the MIME type of a media resource.\n */\n type: string;\n addEventListener(type: K, listener: (this: HTMLSourceElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLSourceElement: {\n prototype: HTMLSourceElement;\n new(): HTMLSourceElement;\n};\n\ninterface HTMLSpanElement extends HTMLElement {\n addEventListener(type: K, listener: (this: HTMLSpanElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLSpanElement: {\n prototype: HTMLSpanElement;\n new(): HTMLSpanElement;\n};\n\ninterface HTMLStyleElement extends HTMLElement, LinkStyle {\n disabled: boolean;\n /**\n * Sets or retrieves the media type.\n */\n media: string;\n /**\n * Retrieves the CSS language in which the style sheet is written.\n */\n type: string;\n addEventListener(type: K, listener: (this: HTMLStyleElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLStyleElement: {\n prototype: HTMLStyleElement;\n new(): HTMLStyleElement;\n};\n\ninterface HTMLTableCaptionElement extends HTMLElement {\n /**\n * Sets or retrieves the alignment of the caption or legend.\n */\n align: string;\n /**\n * Sets or retrieves whether the caption appears at the top or bottom of the table.\n */\n vAlign: string;\n addEventListener(type: K, listener: (this: HTMLTableCaptionElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableCaptionElement: {\n prototype: HTMLTableCaptionElement;\n new(): HTMLTableCaptionElement;\n};\n\ninterface HTMLTableCellElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves abbreviated text for the object.\n */\n abbr: string;\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves a comma-delimited list of conceptual categories associated with the object.\n */\n axis: string;\n bgColor: any;\n /**\n * Retrieves the position of the object in the cells collection of a row.\n */\n readonly cellIndex: number;\n /**\n * Sets or retrieves the number columns in the table that the object should span.\n */\n colSpan: number;\n /**\n * Sets or retrieves a list of header cells that provide information for the object.\n */\n headers: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: any;\n /**\n * Sets or retrieves whether the browser automatically performs wordwrap.\n */\n noWrap: boolean;\n /**\n * Sets or retrieves how many rows in a table the cell should span.\n */\n rowSpan: number;\n /**\n * Sets or retrieves the group of cells in a table to which the object's information applies.\n */\n scope: string;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n addEventListener(type: K, listener: (this: HTMLTableCellElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableCellElement: {\n prototype: HTMLTableCellElement;\n new(): HTMLTableCellElement;\n};\n\ninterface HTMLTableColElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves the alignment of the object relative to the display or table.\n */\n align: string;\n /**\n * Sets or retrieves the number of columns in the group.\n */\n span: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: any;\n addEventListener(type: K, listener: (this: HTMLTableColElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableColElement: {\n prototype: HTMLTableColElement;\n new(): HTMLTableColElement;\n};\n\ninterface HTMLTableDataCellElement extends HTMLTableCellElement {\n addEventListener(type: K, listener: (this: HTMLTableDataCellElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableDataCellElement: {\n prototype: HTMLTableDataCellElement;\n new(): HTMLTableDataCellElement;\n};\n\ninterface HTMLTableElement extends HTMLElement {\n /**\n * Sets or retrieves a value that indicates the table alignment.\n */\n align: string;\n bgColor: any;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n border: string;\n /**\n * Sets or retrieves the border color of the object.\n */\n borderColor: any;\n /**\n * Retrieves the caption object of a table.\n */\n caption: HTMLTableCaptionElement;\n /**\n * Sets or retrieves the amount of space between the border of the cell and the content of the cell.\n */\n cellPadding: string;\n /**\n * Sets or retrieves the amount of space between cells in a table.\n */\n cellSpacing: string;\n /**\n * Sets or retrieves the number of columns in the table.\n */\n cols: number;\n /**\n * Sets or retrieves the way the border frame around the table is displayed.\n */\n frame: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: any;\n /**\n * Sets or retrieves the number of horizontal rows contained in the object.\n */\n rows: HTMLCollectionOf;\n /**\n * Sets or retrieves which dividing lines (inner borders) are displayed.\n */\n rules: string;\n /**\n * Sets or retrieves a description and/or structure of the object.\n */\n summary: string;\n /**\n * Retrieves a collection of all tBody objects in the table. Objects in this collection are in source order.\n */\n tBodies: HTMLCollectionOf;\n /**\n * Retrieves the tFoot object of the table.\n */\n tFoot: HTMLTableSectionElement;\n /**\n * Retrieves the tHead object of the table.\n */\n tHead: HTMLTableSectionElement;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n /**\n * Creates an empty caption element in the table.\n */\n createCaption(): HTMLTableCaptionElement;\n /**\n * Creates an empty tBody element in the table.\n */\n createTBody(): HTMLTableSectionElement;\n /**\n * Creates an empty tFoot element in the table.\n */\n createTFoot(): HTMLTableSectionElement;\n /**\n * Returns the tHead element object if successful, or null otherwise.\n */\n createTHead(): HTMLTableSectionElement;\n /**\n * Deletes the caption element and its contents from the table.\n */\n deleteCaption(): void;\n /**\n * Removes the specified row (tr) from the element and from the rows collection.\n * @param index Number that specifies the zero-based position in the rows collection of the row to remove.\n */\n deleteRow(index?: number): void;\n /**\n * Deletes the tFoot element and its contents from the table.\n */\n deleteTFoot(): void;\n /**\n * Deletes the tHead element and its contents from the table.\n */\n deleteTHead(): void;\n /**\n * Creates a new row (tr) in the table, and adds the row to the rows collection.\n * @param index Number that specifies where to insert the row in the rows collection. The default value is -1, which appends the new row to the end of the rows collection.\n */\n insertRow(index?: number): HTMLTableRowElement;\n addEventListener(type: K, listener: (this: HTMLTableElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableElement: {\n prototype: HTMLTableElement;\n new(): HTMLTableElement;\n};\n\ninterface HTMLTableHeaderCellElement extends HTMLTableCellElement {\n /**\n * Sets or retrieves the group of cells in a table to which the object's information applies.\n */\n scope: string;\n addEventListener(type: K, listener: (this: HTMLTableHeaderCellElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableHeaderCellElement: {\n prototype: HTMLTableHeaderCellElement;\n new(): HTMLTableHeaderCellElement;\n};\n\ninterface HTMLTableRowElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n bgColor: any;\n /**\n * Retrieves a collection of all cells in the table row.\n */\n cells: HTMLCollectionOf;\n /**\n * Sets or retrieves the height of the object.\n */\n height: any;\n /**\n * Retrieves the position of the object in the rows collection for the table.\n */\n readonly rowIndex: number;\n /**\n * Retrieves the position of the object in the collection.\n */\n readonly sectionRowIndex: number;\n /**\n * Removes the specified cell from the table row, as well as from the cells collection.\n * @param index Number that specifies the zero-based position of the cell to remove from the table row. If no value is provided, the last cell in the cells collection is deleted.\n */\n deleteCell(index?: number): void;\n /**\n * Creates a new cell in the table row, and adds the cell to the cells collection.\n * @param index Number that specifies where to insert the cell in the tr. The default value is -1, which appends the new cell to the end of the cells collection.\n */\n insertCell(index?: number): HTMLTableDataCellElement;\n addEventListener(type: K, listener: (this: HTMLTableRowElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableRowElement: {\n prototype: HTMLTableRowElement;\n new(): HTMLTableRowElement;\n};\n\ninterface HTMLTableSectionElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves a value that indicates the table alignment.\n */\n align: string;\n /**\n * Sets or retrieves the number of horizontal rows contained in the object.\n */\n rows: HTMLCollectionOf;\n /**\n * Removes the specified row (tr) from the element and from the rows collection.\n * @param index Number that specifies the zero-based position in the rows collection of the row to remove.\n */\n deleteRow(index?: number): void;\n /**\n * Creates a new row (tr) in the table, and adds the row to the rows collection.\n * @param index Number that specifies where to insert the row in the rows collection. The default value is -1, which appends the new row to the end of the rows collection.\n */\n insertRow(index?: number): HTMLTableRowElement;\n addEventListener(type: K, listener: (this: HTMLTableSectionElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableSectionElement: {\n prototype: HTMLTableSectionElement;\n new(): HTMLTableSectionElement;\n};\n\ninterface HTMLTemplateElement extends HTMLElement {\n readonly content: DocumentFragment;\n addEventListener(type: K, listener: (this: HTMLTemplateElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTemplateElement: {\n prototype: HTMLTemplateElement;\n new(): HTMLTemplateElement;\n};\n\ninterface HTMLTextAreaElement extends HTMLElement {\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n /**\n * Sets or retrieves the width of the object.\n */\n cols: number;\n /**\n * Sets or retrieves the initial contents of the object.\n */\n defaultValue: string;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the maximum number of characters that the user can enter in a text control.\n */\n maxLength: number;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Gets or sets a text string that is displayed in an input field as a hint or prompt to users as the format or type of information they need to enter.The text appears in an input field until the user puts focus on the field.\n */\n placeholder: string;\n /**\n * Sets or retrieves the value indicated whether the content of the object is read-only.\n */\n readOnly: boolean;\n /**\n * When present, marks an element that can't be submitted without a value.\n */\n required: boolean;\n /**\n * Sets or retrieves the number of horizontal rows contained in the object.\n */\n rows: number;\n /**\n * Gets or sets the end position or offset of a text selection.\n */\n selectionEnd: number;\n /**\n * Gets or sets the starting position or offset of a text selection.\n */\n selectionStart: number;\n /**\n * Sets or retrieves the value indicating whether the control is selected.\n */\n status: any;\n /**\n * Retrieves the type of control.\n */\n readonly type: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Retrieves or sets the text in the entry field of the textArea element.\n */\n value: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Sets or retrieves how to handle wordwrapping in the object.\n */\n wrap: string;\n minLength: number;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Highlights the input area of a form element.\n */\n select(): void;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n /**\n * Sets the start and end positions of a selection in a text field.\n * @param start The offset into the text field for the start of the selection.\n * @param end The offset into the text field for the end of the selection.\n */\n setSelectionRange(start: number, end: number): void;\n addEventListener(type: K, listener: (this: HTMLTextAreaElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTextAreaElement: {\n prototype: HTMLTextAreaElement;\n new(): HTMLTextAreaElement;\n};\n\ninterface HTMLTimeElement extends HTMLElement {\n dateTime: string;\n addEventListener(type: K, listener: (this: HTMLTimeElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTimeElement: {\n prototype: HTMLTimeElement;\n new(): HTMLTimeElement;\n};\n\ninterface HTMLTitleElement extends HTMLElement {\n /**\n * Retrieves or sets the text of the object as a string.\n */\n text: string;\n addEventListener(type: K, listener: (this: HTMLTitleElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTitleElement: {\n prototype: HTMLTitleElement;\n new(): HTMLTitleElement;\n};\n\ninterface HTMLTrackElement extends HTMLElement {\n default: boolean;\n kind: string;\n label: string;\n readonly readyState: number;\n src: string;\n srclang: string;\n readonly track: TextTrack;\n readonly ERROR: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n addEventListener(type: K, listener: (this: HTMLTrackElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTrackElement: {\n prototype: HTMLTrackElement;\n new(): HTMLTrackElement;\n readonly ERROR: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n};\n\ninterface HTMLUListElement extends HTMLElement {\n compact: boolean;\n type: string;\n addEventListener(type: K, listener: (this: HTMLUListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLUListElement: {\n prototype: HTMLUListElement;\n new(): HTMLUListElement;\n};\n\ninterface HTMLUnknownElement extends HTMLElement {\n addEventListener(type: K, listener: (this: HTMLUnknownElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLUnknownElement: {\n prototype: HTMLUnknownElement;\n new(): HTMLUnknownElement;\n};\n\ninterface HTMLVideoElementEventMap extends HTMLMediaElementEventMap {\n \"MSVideoFormatChanged\": Event;\n \"MSVideoFrameStepCompleted\": Event;\n \"MSVideoOptimalLayoutChanged\": Event;\n}\n\ninterface HTMLVideoElement extends HTMLMediaElement {\n /**\n * Gets or sets the height of the video element.\n */\n height: number;\n msHorizontalMirror: boolean;\n readonly msIsLayoutOptimalForPlayback: boolean;\n readonly msIsStereo3D: boolean;\n msStereo3DPackingMode: string;\n msStereo3DRenderMode: string;\n msZoom: boolean;\n onMSVideoFormatChanged: (this: HTMLVideoElement, ev: Event) => any;\n onMSVideoFrameStepCompleted: (this: HTMLVideoElement, ev: Event) => any;\n onMSVideoOptimalLayoutChanged: (this: HTMLVideoElement, ev: Event) => any;\n /**\n * Gets or sets a URL of an image to display, for example, like a movie poster. This can be a still frame from the video, or another image if no video data is available.\n */\n poster: string;\n /**\n * Gets the intrinsic height of a video in CSS pixels, or zero if the dimensions are not known.\n */\n readonly videoHeight: number;\n /**\n * Gets the intrinsic width of a video in CSS pixels, or zero if the dimensions are not known.\n */\n readonly videoWidth: number;\n readonly webkitDisplayingFullscreen: boolean;\n readonly webkitSupportsFullscreen: boolean;\n /**\n * Gets or sets the width of the video element.\n */\n width: number;\n getVideoPlaybackQuality(): VideoPlaybackQuality;\n msFrameStep(forward: boolean): void;\n msInsertVideoEffect(activatableClassId: string, effectRequired: boolean, config?: any): void;\n msSetVideoRectangle(left: number, top: number, right: number, bottom: number): void;\n webkitEnterFullscreen(): void;\n webkitEnterFullScreen(): void;\n webkitExitFullscreen(): void;\n webkitExitFullScreen(): void;\n addEventListener(type: K, listener: (this: HTMLVideoElement, ev: HTMLVideoElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLVideoElement: {\n prototype: HTMLVideoElement;\n new(): HTMLVideoElement;\n};\n\ninterface IDBCursor {\n readonly direction: IDBCursorDirection;\n key: IDBKeyRange | IDBValidKey;\n readonly primaryKey: any;\n source: IDBObjectStore | IDBIndex;\n advance(count: number): void;\n continue(key?: IDBKeyRange | IDBValidKey): void;\n delete(): IDBRequest;\n update(value: any): IDBRequest;\n readonly NEXT: string;\n readonly NEXT_NO_DUPLICATE: string;\n readonly PREV: string;\n readonly PREV_NO_DUPLICATE: string;\n}\n\ndeclare var IDBCursor: {\n prototype: IDBCursor;\n new(): IDBCursor;\n readonly NEXT: string;\n readonly NEXT_NO_DUPLICATE: string;\n readonly PREV: string;\n readonly PREV_NO_DUPLICATE: string;\n};\n\ninterface IDBCursorWithValue extends IDBCursor {\n readonly value: any;\n}\n\ndeclare var IDBCursorWithValue: {\n prototype: IDBCursorWithValue;\n new(): IDBCursorWithValue;\n};\n\ninterface IDBDatabaseEventMap {\n \"abort\": Event;\n \"error\": Event;\n}\n\ninterface IDBDatabase extends EventTarget {\n readonly name: string;\n readonly objectStoreNames: DOMStringList;\n onabort: (this: IDBDatabase, ev: Event) => any;\n onerror: (this: IDBDatabase, ev: Event) => any;\n version: number;\n onversionchange: (ev: IDBVersionChangeEvent) => any;\n close(): void;\n createObjectStore(name: string, optionalParameters?: IDBObjectStoreParameters): IDBObjectStore;\n deleteObjectStore(name: string): void;\n transaction(storeNames: string | string[], mode?: IDBTransactionMode): IDBTransaction;\n addEventListener(type: \"versionchange\", listener: (ev: IDBVersionChangeEvent) => any, useCapture?: boolean): void;\n addEventListener(type: K, listener: (this: IDBDatabase, ev: IDBDatabaseEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBDatabase: {\n prototype: IDBDatabase;\n new(): IDBDatabase;\n};\n\ninterface IDBFactory {\n cmp(first: any, second: any): number;\n deleteDatabase(name: string): IDBOpenDBRequest;\n open(name: string, version?: number): IDBOpenDBRequest;\n}\n\ndeclare var IDBFactory: {\n prototype: IDBFactory;\n new(): IDBFactory;\n};\n\ninterface IDBIndex {\n keyPath: string | string[];\n readonly name: string;\n readonly objectStore: IDBObjectStore;\n readonly unique: boolean;\n multiEntry: boolean;\n count(key?: IDBKeyRange | IDBValidKey): IDBRequest;\n get(key: IDBKeyRange | IDBValidKey): IDBRequest;\n getKey(key: IDBKeyRange | IDBValidKey): IDBRequest;\n openCursor(range?: IDBKeyRange | IDBValidKey, direction?: IDBCursorDirection): IDBRequest;\n openKeyCursor(range?: IDBKeyRange | IDBValidKey, direction?: IDBCursorDirection): IDBRequest;\n}\n\ndeclare var IDBIndex: {\n prototype: IDBIndex;\n new(): IDBIndex;\n};\n\ninterface IDBKeyRange {\n readonly lower: any;\n readonly lowerOpen: boolean;\n readonly upper: any;\n readonly upperOpen: boolean;\n}\n\ndeclare var IDBKeyRange: {\n prototype: IDBKeyRange;\n new(): IDBKeyRange;\n bound(lower: any, upper: any, lowerOpen?: boolean, upperOpen?: boolean): IDBKeyRange;\n lowerBound(lower: any, open?: boolean): IDBKeyRange;\n only(value: any): IDBKeyRange;\n upperBound(upper: any, open?: boolean): IDBKeyRange;\n};\n\ninterface IDBObjectStore {\n readonly indexNames: DOMStringList;\n keyPath: string | string[];\n readonly name: string;\n readonly transaction: IDBTransaction;\n autoIncrement: boolean;\n add(value: any, key?: IDBKeyRange | IDBValidKey): IDBRequest;\n clear(): IDBRequest;\n count(key?: IDBKeyRange | IDBValidKey): IDBRequest;\n createIndex(name: string, keyPath: string | string[], optionalParameters?: IDBIndexParameters): IDBIndex;\n delete(key: IDBKeyRange | IDBValidKey): IDBRequest;\n deleteIndex(indexName: string): void;\n get(key: any): IDBRequest;\n index(name: string): IDBIndex;\n openCursor(range?: IDBKeyRange | IDBValidKey, direction?: IDBCursorDirection): IDBRequest;\n put(value: any, key?: IDBKeyRange | IDBValidKey): IDBRequest;\n}\n\ndeclare var IDBObjectStore: {\n prototype: IDBObjectStore;\n new(): IDBObjectStore;\n};\n\ninterface IDBOpenDBRequestEventMap extends IDBRequestEventMap {\n \"blocked\": Event;\n \"upgradeneeded\": IDBVersionChangeEvent;\n}\n\ninterface IDBOpenDBRequest extends IDBRequest {\n onblocked: (this: IDBOpenDBRequest, ev: Event) => any;\n onupgradeneeded: (this: IDBOpenDBRequest, ev: IDBVersionChangeEvent) => any;\n addEventListener(type: K, listener: (this: IDBOpenDBRequest, ev: IDBOpenDBRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBOpenDBRequest: {\n prototype: IDBOpenDBRequest;\n new(): IDBOpenDBRequest;\n};\n\ninterface IDBRequestEventMap {\n \"error\": Event;\n \"success\": Event;\n}\n\ninterface IDBRequest extends EventTarget {\n readonly error: DOMException;\n onerror: (this: IDBRequest, ev: Event) => any;\n onsuccess: (this: IDBRequest, ev: Event) => any;\n readonly readyState: IDBRequestReadyState;\n readonly result: any;\n source: IDBObjectStore | IDBIndex | IDBCursor;\n readonly transaction: IDBTransaction;\n addEventListener(type: K, listener: (this: IDBRequest, ev: IDBRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBRequest: {\n prototype: IDBRequest;\n new(): IDBRequest;\n};\n\ninterface IDBTransactionEventMap {\n \"abort\": Event;\n \"complete\": Event;\n \"error\": Event;\n}\n\ninterface IDBTransaction extends EventTarget {\n readonly db: IDBDatabase;\n readonly error: DOMException;\n readonly mode: IDBTransactionMode;\n onabort: (this: IDBTransaction, ev: Event) => any;\n oncomplete: (this: IDBTransaction, ev: Event) => any;\n onerror: (this: IDBTransaction, ev: Event) => any;\n abort(): void;\n objectStore(name: string): IDBObjectStore;\n readonly READ_ONLY: string;\n readonly READ_WRITE: string;\n readonly VERSION_CHANGE: string;\n addEventListener(type: K, listener: (this: IDBTransaction, ev: IDBTransactionEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBTransaction: {\n prototype: IDBTransaction;\n new(): IDBTransaction;\n readonly READ_ONLY: string;\n readonly READ_WRITE: string;\n readonly VERSION_CHANGE: string;\n};\n\ninterface IDBVersionChangeEvent extends Event {\n readonly newVersion: number | null;\n readonly oldVersion: number;\n}\n\ndeclare var IDBVersionChangeEvent: {\n prototype: IDBVersionChangeEvent;\n new(): IDBVersionChangeEvent;\n};\n\ninterface IIRFilterNode extends AudioNode {\n getFrequencyResponse(frequencyHz: Float32Array, magResponse: Float32Array, phaseResponse: Float32Array): void;\n}\n\ndeclare var IIRFilterNode: {\n prototype: IIRFilterNode;\n new(): IIRFilterNode;\n};\n\ninterface ImageData {\n data: Uint8ClampedArray;\n readonly height: number;\n readonly width: number;\n}\n\ndeclare var ImageData: {\n prototype: ImageData;\n new(width: number, height: number): ImageData;\n new(array: Uint8ClampedArray, width: number, height: number): ImageData;\n};\n\ninterface IntersectionObserver {\n readonly root: Element | null;\n readonly rootMargin: string;\n readonly thresholds: number[];\n disconnect(): void;\n observe(target: Element): void;\n takeRecords(): IntersectionObserverEntry[];\n unobserve(target: Element): void;\n}\n\ndeclare var IntersectionObserver: {\n prototype: IntersectionObserver;\n new(callback: IntersectionObserverCallback, options?: IntersectionObserverInit): IntersectionObserver;\n};\n\ninterface IntersectionObserverEntry {\n readonly boundingClientRect: ClientRect;\n readonly intersectionRatio: number;\n readonly intersectionRect: ClientRect;\n readonly rootBounds: ClientRect;\n readonly target: Element;\n readonly time: number;\n}\n\ndeclare var IntersectionObserverEntry: {\n prototype: IntersectionObserverEntry;\n new(intersectionObserverEntryInit: IntersectionObserverEntryInit): IntersectionObserverEntry;\n};\n\ninterface KeyboardEvent extends UIEvent {\n readonly altKey: boolean;\n readonly char: string | null;\n readonly charCode: number;\n readonly ctrlKey: boolean;\n readonly key: string;\n readonly keyCode: number;\n readonly locale: string;\n readonly location: number;\n readonly metaKey: boolean;\n readonly repeat: boolean;\n readonly shiftKey: boolean;\n readonly which: number;\n readonly code: string;\n getModifierState(keyArg: string): boolean;\n initKeyboardEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, keyArg: string, locationArg: number, modifiersListArg: string, repeat: boolean, locale: string): void;\n readonly DOM_KEY_LOCATION_JOYSTICK: number;\n readonly DOM_KEY_LOCATION_LEFT: number;\n readonly DOM_KEY_LOCATION_MOBILE: number;\n readonly DOM_KEY_LOCATION_NUMPAD: number;\n readonly DOM_KEY_LOCATION_RIGHT: number;\n readonly DOM_KEY_LOCATION_STANDARD: number;\n}\n\ndeclare var KeyboardEvent: {\n prototype: KeyboardEvent;\n new(typeArg: string, eventInitDict?: KeyboardEventInit): KeyboardEvent;\n readonly DOM_KEY_LOCATION_JOYSTICK: number;\n readonly DOM_KEY_LOCATION_LEFT: number;\n readonly DOM_KEY_LOCATION_MOBILE: number;\n readonly DOM_KEY_LOCATION_NUMPAD: number;\n readonly DOM_KEY_LOCATION_RIGHT: number;\n readonly DOM_KEY_LOCATION_STANDARD: number;\n};\n\ninterface ListeningStateChangedEvent extends Event {\n readonly label: string;\n readonly state: ListeningState;\n}\n\ndeclare var ListeningStateChangedEvent: {\n prototype: ListeningStateChangedEvent;\n new(): ListeningStateChangedEvent;\n};\n\ninterface Location {\n hash: string;\n host: string;\n hostname: string;\n href: string;\n readonly origin: string;\n pathname: string;\n port: string;\n protocol: string;\n search: string;\n assign(url: string): void;\n reload(forcedReload?: boolean): void;\n replace(url: string): void;\n toString(): string;\n}\n\ndeclare var Location: {\n prototype: Location;\n new(): Location;\n};\n\ninterface LongRunningScriptDetectedEvent extends Event {\n readonly executionTime: number;\n stopPageScriptExecution: boolean;\n}\n\ndeclare var LongRunningScriptDetectedEvent: {\n prototype: LongRunningScriptDetectedEvent;\n new(): LongRunningScriptDetectedEvent;\n};\n\ninterface MediaDeviceInfo {\n readonly deviceId: string;\n readonly groupId: string;\n readonly kind: MediaDeviceKind;\n readonly label: string;\n}\n\ndeclare var MediaDeviceInfo: {\n prototype: MediaDeviceInfo;\n new(): MediaDeviceInfo;\n};\n\ninterface MediaDevicesEventMap {\n \"devicechange\": Event;\n}\n\ninterface MediaDevices extends EventTarget {\n ondevicechange: (this: MediaDevices, ev: Event) => any;\n enumerateDevices(): any;\n getSupportedConstraints(): MediaTrackSupportedConstraints;\n getUserMedia(constraints: MediaStreamConstraints): Promise;\n addEventListener(type: K, listener: (this: MediaDevices, ev: MediaDevicesEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MediaDevices: {\n prototype: MediaDevices;\n new(): MediaDevices;\n};\n\ninterface MediaElementAudioSourceNode extends AudioNode {\n}\n\ndeclare var MediaElementAudioSourceNode: {\n prototype: MediaElementAudioSourceNode;\n new(): MediaElementAudioSourceNode;\n};\n\ninterface MediaEncryptedEvent extends Event {\n readonly initData: ArrayBuffer | null;\n readonly initDataType: string;\n}\n\ndeclare var MediaEncryptedEvent: {\n prototype: MediaEncryptedEvent;\n new(type: string, eventInitDict?: MediaEncryptedEventInit): MediaEncryptedEvent;\n};\n\ninterface MediaError {\n readonly code: number;\n readonly msExtendedCode: number;\n readonly MEDIA_ERR_ABORTED: number;\n readonly MEDIA_ERR_DECODE: number;\n readonly MEDIA_ERR_NETWORK: number;\n readonly MEDIA_ERR_SRC_NOT_SUPPORTED: number;\n readonly MS_MEDIA_ERR_ENCRYPTED: number;\n}\n\ndeclare var MediaError: {\n prototype: MediaError;\n new(): MediaError;\n readonly MEDIA_ERR_ABORTED: number;\n readonly MEDIA_ERR_DECODE: number;\n readonly MEDIA_ERR_NETWORK: number;\n readonly MEDIA_ERR_SRC_NOT_SUPPORTED: number;\n readonly MS_MEDIA_ERR_ENCRYPTED: number;\n};\n\ninterface MediaKeyMessageEvent extends Event {\n readonly message: ArrayBuffer;\n readonly messageType: MediaKeyMessageType;\n}\n\ndeclare var MediaKeyMessageEvent: {\n prototype: MediaKeyMessageEvent;\n new(type: string, eventInitDict?: MediaKeyMessageEventInit): MediaKeyMessageEvent;\n};\n\ninterface MediaKeys {\n createSession(sessionType?: MediaKeySessionType): MediaKeySession;\n setServerCertificate(serverCertificate: any): Promise;\n}\n\ndeclare var MediaKeys: {\n prototype: MediaKeys;\n new(): MediaKeys;\n};\n\ninterface MediaKeySession extends EventTarget {\n readonly closed: Promise;\n readonly expiration: number;\n readonly keyStatuses: MediaKeyStatusMap;\n readonly sessionId: string;\n close(): Promise;\n generateRequest(initDataType: string, initData: any): Promise;\n load(sessionId: string): Promise;\n remove(): Promise;\n update(response: any): Promise;\n}\n\ndeclare var MediaKeySession: {\n prototype: MediaKeySession;\n new(): MediaKeySession;\n};\n\ninterface MediaKeyStatusMap {\n readonly size: number;\n forEach(callback: ForEachCallback): void;\n get(keyId: any): MediaKeyStatus;\n has(keyId: any): boolean;\n}\n\ndeclare var MediaKeyStatusMap: {\n prototype: MediaKeyStatusMap;\n new(): MediaKeyStatusMap;\n};\n\ninterface MediaKeySystemAccess {\n readonly keySystem: string;\n createMediaKeys(): Promise;\n getConfiguration(): MediaKeySystemConfiguration;\n}\n\ndeclare var MediaKeySystemAccess: {\n prototype: MediaKeySystemAccess;\n new(): MediaKeySystemAccess;\n};\n\ninterface MediaList {\n readonly length: number;\n mediaText: string;\n appendMedium(newMedium: string): void;\n deleteMedium(oldMedium: string): void;\n item(index: number): string;\n toString(): string;\n [index: number]: string;\n}\n\ndeclare var MediaList: {\n prototype: MediaList;\n new(): MediaList;\n};\n\ninterface MediaQueryList {\n readonly matches: boolean;\n readonly media: string;\n addListener(listener: MediaQueryListListener): void;\n removeListener(listener: MediaQueryListListener): void;\n}\n\ndeclare var MediaQueryList: {\n prototype: MediaQueryList;\n new(): MediaQueryList;\n};\n\ninterface MediaSource extends EventTarget {\n readonly activeSourceBuffers: SourceBufferList;\n duration: number;\n readonly readyState: string;\n readonly sourceBuffers: SourceBufferList;\n addSourceBuffer(type: string): SourceBuffer;\n endOfStream(error?: number): void;\n removeSourceBuffer(sourceBuffer: SourceBuffer): void;\n}\n\ndeclare var MediaSource: {\n prototype: MediaSource;\n new(): MediaSource;\n isTypeSupported(type: string): boolean;\n};\n\ninterface MediaStreamEventMap {\n \"active\": Event;\n \"addtrack\": MediaStreamTrackEvent;\n \"inactive\": Event;\n \"removetrack\": MediaStreamTrackEvent;\n}\n\ninterface MediaStream extends EventTarget {\n readonly active: boolean;\n readonly id: string;\n onactive: (this: MediaStream, ev: Event) => any;\n onaddtrack: (this: MediaStream, ev: MediaStreamTrackEvent) => any;\n oninactive: (this: MediaStream, ev: Event) => any;\n onremovetrack: (this: MediaStream, ev: MediaStreamTrackEvent) => any;\n addTrack(track: MediaStreamTrack): void;\n clone(): MediaStream;\n getAudioTracks(): MediaStreamTrack[];\n getTrackById(trackId: string): MediaStreamTrack | null;\n getTracks(): MediaStreamTrack[];\n getVideoTracks(): MediaStreamTrack[];\n removeTrack(track: MediaStreamTrack): void;\n stop(): void;\n addEventListener(type: K, listener: (this: MediaStream, ev: MediaStreamEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MediaStream: {\n prototype: MediaStream;\n new(streamOrTracks?: MediaStream | MediaStreamTrack[]): MediaStream;\n};\n\ninterface MediaStreamAudioSourceNode extends AudioNode {\n}\n\ndeclare var MediaStreamAudioSourceNode: {\n prototype: MediaStreamAudioSourceNode;\n new(): MediaStreamAudioSourceNode;\n};\n\ninterface MediaStreamError {\n readonly constraintName: string | null;\n readonly message: string | null;\n readonly name: string;\n}\n\ndeclare var MediaStreamError: {\n prototype: MediaStreamError;\n new(): MediaStreamError;\n};\n\ninterface MediaStreamErrorEvent extends Event {\n readonly error: MediaStreamError | null;\n}\n\ndeclare var MediaStreamErrorEvent: {\n prototype: MediaStreamErrorEvent;\n new(typeArg: string, eventInitDict?: MediaStreamErrorEventInit): MediaStreamErrorEvent;\n};\n\ninterface MediaStreamEvent extends Event {\n readonly stream: MediaStream | null;\n}\n\ndeclare var MediaStreamEvent: {\n prototype: MediaStreamEvent;\n new(type: string, eventInitDict: MediaStreamEventInit): MediaStreamEvent;\n};\n\ninterface MediaStreamTrackEventMap {\n \"ended\": MediaStreamErrorEvent;\n \"mute\": Event;\n \"overconstrained\": MediaStreamErrorEvent;\n \"unmute\": Event;\n}\n\ninterface MediaStreamTrack extends EventTarget {\n enabled: boolean;\n readonly id: string;\n readonly kind: string;\n readonly label: string;\n readonly muted: boolean;\n onended: (this: MediaStreamTrack, ev: MediaStreamErrorEvent) => any;\n onmute: (this: MediaStreamTrack, ev: Event) => any;\n onoverconstrained: (this: MediaStreamTrack, ev: MediaStreamErrorEvent) => any;\n onunmute: (this: MediaStreamTrack, ev: Event) => any;\n readonly readonly: boolean;\n readonly readyState: MediaStreamTrackState;\n readonly remote: boolean;\n applyConstraints(constraints: MediaTrackConstraints): Promise;\n clone(): MediaStreamTrack;\n getCapabilities(): MediaTrackCapabilities;\n getConstraints(): MediaTrackConstraints;\n getSettings(): MediaTrackSettings;\n stop(): void;\n addEventListener(type: K, listener: (this: MediaStreamTrack, ev: MediaStreamTrackEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MediaStreamTrack: {\n prototype: MediaStreamTrack;\n new(): MediaStreamTrack;\n};\n\ninterface MediaStreamTrackEvent extends Event {\n readonly track: MediaStreamTrack;\n}\n\ndeclare var MediaStreamTrackEvent: {\n prototype: MediaStreamTrackEvent;\n new(typeArg: string, eventInitDict?: MediaStreamTrackEventInit): MediaStreamTrackEvent;\n};\n\ninterface MessageChannel {\n readonly port1: MessagePort;\n readonly port2: MessagePort;\n}\n\ndeclare var MessageChannel: {\n prototype: MessageChannel;\n new(): MessageChannel;\n};\n\ninterface MessageEvent extends Event {\n readonly data: any;\n readonly origin: string;\n readonly ports: any;\n readonly source: Window;\n initMessageEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, dataArg: any, originArg: string, lastEventIdArg: string, sourceArg: Window): void;\n}\n\ndeclare var MessageEvent: {\n prototype: MessageEvent;\n new(type: string, eventInitDict?: MessageEventInit): MessageEvent;\n};\n\ninterface MessagePortEventMap {\n \"message\": MessageEvent;\n}\n\ninterface MessagePort extends EventTarget {\n onmessage: (this: MessagePort, ev: MessageEvent) => any;\n close(): void;\n postMessage(message?: any, transfer?: any[]): void;\n start(): void;\n addEventListener(type: K, listener: (this: MessagePort, ev: MessagePortEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MessagePort: {\n prototype: MessagePort;\n new(): MessagePort;\n};\n\ninterface MimeType {\n readonly description: string;\n readonly enabledPlugin: Plugin;\n readonly suffixes: string;\n readonly type: string;\n}\n\ndeclare var MimeType: {\n prototype: MimeType;\n new(): MimeType;\n};\n\ninterface MimeTypeArray {\n readonly length: number;\n item(index: number): Plugin;\n namedItem(type: string): Plugin;\n [index: number]: Plugin;\n}\n\ndeclare var MimeTypeArray: {\n prototype: MimeTypeArray;\n new(): MimeTypeArray;\n};\n\ninterface MouseEvent extends UIEvent {\n readonly altKey: boolean;\n readonly button: number;\n readonly buttons: number;\n readonly clientX: number;\n readonly clientY: number;\n readonly ctrlKey: boolean;\n readonly fromElement: Element;\n readonly layerX: number;\n readonly layerY: number;\n readonly metaKey: boolean;\n readonly movementX: number;\n readonly movementY: number;\n readonly offsetX: number;\n readonly offsetY: number;\n readonly pageX: number;\n readonly pageY: number;\n readonly relatedTarget: EventTarget;\n readonly screenX: number;\n readonly screenY: number;\n readonly shiftKey: boolean;\n readonly toElement: Element;\n readonly which: number;\n readonly x: number;\n readonly y: number;\n getModifierState(keyArg: string): boolean;\n initMouseEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget | null): void;\n}\n\ndeclare var MouseEvent: {\n prototype: MouseEvent;\n new(typeArg: string, eventInitDict?: MouseEventInit): MouseEvent;\n};\n\ninterface MSApp {\n clearTemporaryWebDataAsync(): MSAppAsyncOperation;\n createBlobFromRandomAccessStream(type: string, seeker: any): Blob;\n createDataPackage(object: any): any;\n createDataPackageFromSelection(): any;\n createFileFromStorageFile(storageFile: any): File;\n createStreamFromInputStream(type: string, inputStream: any): MSStream;\n execAsyncAtPriority(asynchronousCallback: MSExecAtPriorityFunctionCallback, priority: string, ...args: any[]): void;\n execAtPriority(synchronousCallback: MSExecAtPriorityFunctionCallback, priority: string, ...args: any[]): any;\n getCurrentPriority(): string;\n getHtmlPrintDocumentSourceAsync(htmlDoc: any): Promise;\n getViewId(view: any): any;\n isTaskScheduledAtPriorityOrHigher(priority: string): boolean;\n pageHandlesAllApplicationActivations(enabled: boolean): void;\n suppressSubdownloadCredentialPrompts(suppress: boolean): void;\n terminateApp(exceptionObject: any): void;\n readonly CURRENT: string;\n readonly HIGH: string;\n readonly IDLE: string;\n readonly NORMAL: string;\n}\ndeclare var MSApp: MSApp;\n\ninterface MSAppAsyncOperationEventMap {\n \"complete\": Event;\n \"error\": Event;\n}\n\ninterface MSAppAsyncOperation extends EventTarget {\n readonly error: DOMError;\n oncomplete: (this: MSAppAsyncOperation, ev: Event) => any;\n onerror: (this: MSAppAsyncOperation, ev: Event) => any;\n readonly readyState: number;\n readonly result: any;\n start(): void;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n addEventListener(type: K, listener: (this: MSAppAsyncOperation, ev: MSAppAsyncOperationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSAppAsyncOperation: {\n prototype: MSAppAsyncOperation;\n new(): MSAppAsyncOperation;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n};\n\ninterface MSAssertion {\n readonly id: string;\n readonly type: MSCredentialType;\n}\n\ndeclare var MSAssertion: {\n prototype: MSAssertion;\n new(): MSAssertion;\n};\n\ninterface MSBlobBuilder {\n append(data: any, endings?: string): void;\n getBlob(contentType?: string): Blob;\n}\n\ndeclare var MSBlobBuilder: {\n prototype: MSBlobBuilder;\n new(): MSBlobBuilder;\n};\n\ninterface MSCredentials {\n getAssertion(challenge: string, filter?: MSCredentialFilter, params?: MSSignatureParameters): Promise;\n makeCredential(accountInfo: MSAccountInfo, params: MSCredentialParameters[], challenge?: string): Promise;\n}\n\ndeclare var MSCredentials: {\n prototype: MSCredentials;\n new(): MSCredentials;\n};\n\ninterface MSFIDOCredentialAssertion extends MSAssertion {\n readonly algorithm: string | Algorithm;\n readonly attestation: any;\n readonly publicKey: string;\n readonly transportHints: MSTransportType[];\n}\n\ndeclare var MSFIDOCredentialAssertion: {\n prototype: MSFIDOCredentialAssertion;\n new(): MSFIDOCredentialAssertion;\n};\n\ninterface MSFIDOSignature {\n readonly authnrData: string;\n readonly clientData: string;\n readonly signature: string;\n}\n\ndeclare var MSFIDOSignature: {\n prototype: MSFIDOSignature;\n new(): MSFIDOSignature;\n};\n\ninterface MSFIDOSignatureAssertion extends MSAssertion {\n readonly signature: MSFIDOSignature;\n}\n\ndeclare var MSFIDOSignatureAssertion: {\n prototype: MSFIDOSignatureAssertion;\n new(): MSFIDOSignatureAssertion;\n};\n\ninterface MSGesture {\n target: Element;\n addPointer(pointerId: number): void;\n stop(): void;\n}\n\ndeclare var MSGesture: {\n prototype: MSGesture;\n new(): MSGesture;\n};\n\ninterface MSGestureEvent extends UIEvent {\n readonly clientX: number;\n readonly clientY: number;\n readonly expansion: number;\n readonly gestureObject: any;\n readonly hwTimestamp: number;\n readonly offsetX: number;\n readonly offsetY: number;\n readonly rotation: number;\n readonly scale: number;\n readonly screenX: number;\n readonly screenY: number;\n readonly translationX: number;\n readonly translationY: number;\n readonly velocityAngular: number;\n readonly velocityExpansion: number;\n readonly velocityX: number;\n readonly velocityY: number;\n initGestureEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, offsetXArg: number, offsetYArg: number, translationXArg: number, translationYArg: number, scaleArg: number, expansionArg: number, rotationArg: number, velocityXArg: number, velocityYArg: number, velocityExpansionArg: number, velocityAngularArg: number, hwTimestampArg: number): void;\n readonly MSGESTURE_FLAG_BEGIN: number;\n readonly MSGESTURE_FLAG_CANCEL: number;\n readonly MSGESTURE_FLAG_END: number;\n readonly MSGESTURE_FLAG_INERTIA: number;\n readonly MSGESTURE_FLAG_NONE: number;\n}\n\ndeclare var MSGestureEvent: {\n prototype: MSGestureEvent;\n new(): MSGestureEvent;\n readonly MSGESTURE_FLAG_BEGIN: number;\n readonly MSGESTURE_FLAG_CANCEL: number;\n readonly MSGESTURE_FLAG_END: number;\n readonly MSGESTURE_FLAG_INERTIA: number;\n readonly MSGESTURE_FLAG_NONE: number;\n};\n\ninterface MSGraphicsTrust {\n readonly constrictionActive: boolean;\n readonly status: string;\n}\n\ndeclare var MSGraphicsTrust: {\n prototype: MSGraphicsTrust;\n new(): MSGraphicsTrust;\n};\n\ninterface MSHTMLWebViewElement extends HTMLElement {\n readonly canGoBack: boolean;\n readonly canGoForward: boolean;\n readonly containsFullScreenElement: boolean;\n readonly documentTitle: string;\n height: number;\n readonly settings: MSWebViewSettings;\n src: string;\n width: number;\n addWebAllowedObject(name: string, applicationObject: any): void;\n buildLocalStreamUri(contentIdentifier: string, relativePath: string): string;\n capturePreviewToBlobAsync(): MSWebViewAsyncOperation;\n captureSelectedContentToDataPackageAsync(): MSWebViewAsyncOperation;\n getDeferredPermissionRequestById(id: number): DeferredPermissionRequest;\n getDeferredPermissionRequests(): DeferredPermissionRequest[];\n goBack(): void;\n goForward(): void;\n invokeScriptAsync(scriptName: string, ...args: any[]): MSWebViewAsyncOperation;\n navigate(uri: string): void;\n navigateFocus(navigationReason: NavigationReason, origin: FocusNavigationOrigin): void;\n navigateToLocalStreamUri(source: string, streamResolver: any): void;\n navigateToString(contents: string): void;\n navigateWithHttpRequestMessage(requestMessage: any): void;\n refresh(): void;\n stop(): void;\n addEventListener(type: K, listener: (this: MSHTMLWebViewElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSHTMLWebViewElement: {\n prototype: MSHTMLWebViewElement;\n new(): MSHTMLWebViewElement;\n};\n\ninterface MSInputMethodContextEventMap {\n \"MSCandidateWindowHide\": Event;\n \"MSCandidateWindowShow\": Event;\n \"MSCandidateWindowUpdate\": Event;\n}\n\ninterface MSInputMethodContext extends EventTarget {\n readonly compositionEndOffset: number;\n readonly compositionStartOffset: number;\n oncandidatewindowhide: (this: MSInputMethodContext, ev: Event) => any;\n oncandidatewindowshow: (this: MSInputMethodContext, ev: Event) => any;\n oncandidatewindowupdate: (this: MSInputMethodContext, ev: Event) => any;\n readonly target: HTMLElement;\n getCandidateWindowClientRect(): ClientRect;\n getCompositionAlternatives(): string[];\n hasComposition(): boolean;\n isCandidateWindowVisible(): boolean;\n addEventListener(type: K, listener: (this: MSInputMethodContext, ev: MSInputMethodContextEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSInputMethodContext: {\n prototype: MSInputMethodContext;\n new(): MSInputMethodContext;\n};\n\ninterface MSManipulationEvent extends UIEvent {\n readonly currentState: number;\n readonly inertiaDestinationX: number;\n readonly inertiaDestinationY: number;\n readonly lastState: number;\n initMSManipulationEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, lastState: number, currentState: number): void;\n readonly MS_MANIPULATION_STATE_ACTIVE: number;\n readonly MS_MANIPULATION_STATE_CANCELLED: number;\n readonly MS_MANIPULATION_STATE_COMMITTED: number;\n readonly MS_MANIPULATION_STATE_DRAGGING: number;\n readonly MS_MANIPULATION_STATE_INERTIA: number;\n readonly MS_MANIPULATION_STATE_PRESELECT: number;\n readonly MS_MANIPULATION_STATE_SELECTING: number;\n readonly MS_MANIPULATION_STATE_STOPPED: number;\n}\n\ndeclare var MSManipulationEvent: {\n prototype: MSManipulationEvent;\n new(): MSManipulationEvent;\n readonly MS_MANIPULATION_STATE_ACTIVE: number;\n readonly MS_MANIPULATION_STATE_CANCELLED: number;\n readonly MS_MANIPULATION_STATE_COMMITTED: number;\n readonly MS_MANIPULATION_STATE_DRAGGING: number;\n readonly MS_MANIPULATION_STATE_INERTIA: number;\n readonly MS_MANIPULATION_STATE_PRESELECT: number;\n readonly MS_MANIPULATION_STATE_SELECTING: number;\n readonly MS_MANIPULATION_STATE_STOPPED: number;\n};\n\ninterface MSMediaKeyError {\n readonly code: number;\n readonly systemCode: number;\n readonly MS_MEDIA_KEYERR_CLIENT: number;\n readonly MS_MEDIA_KEYERR_DOMAIN: number;\n readonly MS_MEDIA_KEYERR_HARDWARECHANGE: number;\n readonly MS_MEDIA_KEYERR_OUTPUT: number;\n readonly MS_MEDIA_KEYERR_SERVICE: number;\n readonly MS_MEDIA_KEYERR_UNKNOWN: number;\n}\n\ndeclare var MSMediaKeyError: {\n prototype: MSMediaKeyError;\n new(): MSMediaKeyError;\n readonly MS_MEDIA_KEYERR_CLIENT: number;\n readonly MS_MEDIA_KEYERR_DOMAIN: number;\n readonly MS_MEDIA_KEYERR_HARDWARECHANGE: number;\n readonly MS_MEDIA_KEYERR_OUTPUT: number;\n readonly MS_MEDIA_KEYERR_SERVICE: number;\n readonly MS_MEDIA_KEYERR_UNKNOWN: number;\n};\n\ninterface MSMediaKeyMessageEvent extends Event {\n readonly destinationURL: string | null;\n readonly message: Uint8Array;\n}\n\ndeclare var MSMediaKeyMessageEvent: {\n prototype: MSMediaKeyMessageEvent;\n new(): MSMediaKeyMessageEvent;\n};\n\ninterface MSMediaKeyNeededEvent extends Event {\n readonly initData: Uint8Array | null;\n}\n\ndeclare var MSMediaKeyNeededEvent: {\n prototype: MSMediaKeyNeededEvent;\n new(): MSMediaKeyNeededEvent;\n};\n\ninterface MSMediaKeys {\n readonly keySystem: string;\n createSession(type: string, initData: Uint8Array, cdmData?: Uint8Array): MSMediaKeySession;\n}\n\ndeclare var MSMediaKeys: {\n prototype: MSMediaKeys;\n new(keySystem: string): MSMediaKeys;\n isTypeSupported(keySystem: string, type?: string): boolean;\n isTypeSupportedWithFeatures(keySystem: string, type?: string): string;\n};\n\ninterface MSMediaKeySession extends EventTarget {\n readonly error: MSMediaKeyError | null;\n readonly keySystem: string;\n readonly sessionId: string;\n close(): void;\n update(key: Uint8Array): void;\n}\n\ndeclare var MSMediaKeySession: {\n prototype: MSMediaKeySession;\n new(): MSMediaKeySession;\n};\n\ninterface MSPointerEvent extends MouseEvent {\n readonly currentPoint: any;\n readonly height: number;\n readonly hwTimestamp: number;\n readonly intermediatePoints: any;\n readonly isPrimary: boolean;\n readonly pointerId: number;\n readonly pointerType: any;\n readonly pressure: number;\n readonly rotation: number;\n readonly tiltX: number;\n readonly tiltY: number;\n readonly width: number;\n getCurrentPoint(element: Element): void;\n getIntermediatePoints(element: Element): void;\n initPointerEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget, offsetXArg: number, offsetYArg: number, widthArg: number, heightArg: number, pressure: number, rotation: number, tiltX: number, tiltY: number, pointerIdArg: number, pointerType: any, hwTimestampArg: number, isPrimary: boolean): void;\n}\n\ndeclare var MSPointerEvent: {\n prototype: MSPointerEvent;\n new(typeArg: string, eventInitDict?: PointerEventInit): MSPointerEvent;\n};\n\ninterface MSRangeCollection {\n readonly length: number;\n item(index: number): Range;\n [index: number]: Range;\n}\n\ndeclare var MSRangeCollection: {\n prototype: MSRangeCollection;\n new(): MSRangeCollection;\n};\n\ninterface MSSiteModeEvent extends Event {\n readonly actionURL: string;\n readonly buttonID: number;\n}\n\ndeclare var MSSiteModeEvent: {\n prototype: MSSiteModeEvent;\n new(): MSSiteModeEvent;\n};\n\ninterface MSStream {\n readonly type: string;\n msClose(): void;\n msDetachStream(): any;\n}\n\ndeclare var MSStream: {\n prototype: MSStream;\n new(): MSStream;\n};\n\ninterface MSStreamReader extends EventTarget, MSBaseReader {\n readonly error: DOMError;\n readAsArrayBuffer(stream: MSStream, size?: number): void;\n readAsBinaryString(stream: MSStream, size?: number): void;\n readAsBlob(stream: MSStream, size?: number): void;\n readAsDataURL(stream: MSStream, size?: number): void;\n readAsText(stream: MSStream, encoding?: string, size?: number): void;\n addEventListener(type: K, listener: (this: MSStreamReader, ev: MSBaseReaderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSStreamReader: {\n prototype: MSStreamReader;\n new(): MSStreamReader;\n};\n\ninterface MSWebViewAsyncOperationEventMap {\n \"complete\": Event;\n \"error\": Event;\n}\n\ninterface MSWebViewAsyncOperation extends EventTarget {\n readonly error: DOMError;\n oncomplete: (this: MSWebViewAsyncOperation, ev: Event) => any;\n onerror: (this: MSWebViewAsyncOperation, ev: Event) => any;\n readonly readyState: number;\n readonly result: any;\n readonly target: MSHTMLWebViewElement;\n readonly type: number;\n start(): void;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n readonly TYPE_CAPTURE_PREVIEW_TO_RANDOM_ACCESS_STREAM: number;\n readonly TYPE_CREATE_DATA_PACKAGE_FROM_SELECTION: number;\n readonly TYPE_INVOKE_SCRIPT: number;\n addEventListener(type: K, listener: (this: MSWebViewAsyncOperation, ev: MSWebViewAsyncOperationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSWebViewAsyncOperation: {\n prototype: MSWebViewAsyncOperation;\n new(): MSWebViewAsyncOperation;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n readonly TYPE_CAPTURE_PREVIEW_TO_RANDOM_ACCESS_STREAM: number;\n readonly TYPE_CREATE_DATA_PACKAGE_FROM_SELECTION: number;\n readonly TYPE_INVOKE_SCRIPT: number;\n};\n\ninterface MSWebViewSettings {\n isIndexedDBEnabled: boolean;\n isJavaScriptEnabled: boolean;\n}\n\ndeclare var MSWebViewSettings: {\n prototype: MSWebViewSettings;\n new(): MSWebViewSettings;\n};\n\ninterface MutationEvent extends Event {\n readonly attrChange: number;\n readonly attrName: string;\n readonly newValue: string;\n readonly prevValue: string;\n readonly relatedNode: Node;\n initMutationEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, relatedNodeArg: Node, prevValueArg: string, newValueArg: string, attrNameArg: string, attrChangeArg: number): void;\n readonly ADDITION: number;\n readonly MODIFICATION: number;\n readonly REMOVAL: number;\n}\n\ndeclare var MutationEvent: {\n prototype: MutationEvent;\n new(): MutationEvent;\n readonly ADDITION: number;\n readonly MODIFICATION: number;\n readonly REMOVAL: number;\n};\n\ninterface MutationObserver {\n disconnect(): void;\n observe(target: Node, options: MutationObserverInit): void;\n takeRecords(): MutationRecord[];\n}\n\ndeclare var MutationObserver: {\n prototype: MutationObserver;\n new(callback: MutationCallback): MutationObserver;\n};\n\ninterface MutationRecord {\n readonly addedNodes: NodeList;\n readonly attributeName: string | null;\n readonly attributeNamespace: string | null;\n readonly nextSibling: Node | null;\n readonly oldValue: string | null;\n readonly previousSibling: Node | null;\n readonly removedNodes: NodeList;\n readonly target: Node;\n readonly type: string;\n}\n\ndeclare var MutationRecord: {\n prototype: MutationRecord;\n new(): MutationRecord;\n};\n\ninterface NamedNodeMap {\n readonly length: number;\n getNamedItem(name: string): Attr;\n getNamedItemNS(namespaceURI: string | null, localName: string | null): Attr;\n item(index: number): Attr;\n removeNamedItem(name: string): Attr;\n removeNamedItemNS(namespaceURI: string | null, localName: string | null): Attr;\n setNamedItem(arg: Attr): Attr;\n setNamedItemNS(arg: Attr): Attr;\n [index: number]: Attr;\n}\n\ndeclare var NamedNodeMap: {\n prototype: NamedNodeMap;\n new(): NamedNodeMap;\n};\n\ninterface NavigationCompletedEvent extends NavigationEvent {\n readonly isSuccess: boolean;\n readonly webErrorStatus: number;\n}\n\ndeclare var NavigationCompletedEvent: {\n prototype: NavigationCompletedEvent;\n new(): NavigationCompletedEvent;\n};\n\ninterface NavigationEvent extends Event {\n readonly uri: string;\n}\n\ndeclare var NavigationEvent: {\n prototype: NavigationEvent;\n new(): NavigationEvent;\n};\n\ninterface NavigationEventWithReferrer extends NavigationEvent {\n readonly referer: string;\n}\n\ndeclare var NavigationEventWithReferrer: {\n prototype: NavigationEventWithReferrer;\n new(): NavigationEventWithReferrer;\n};\n\ninterface Navigator extends Object, NavigatorID, NavigatorOnLine, NavigatorContentUtils, NavigatorStorageUtils, NavigatorGeolocation, MSNavigatorDoNotTrack, MSFileSaver, NavigatorBeacon, NavigatorConcurrentHardware, NavigatorUserMedia {\n readonly authentication: WebAuthentication;\n readonly cookieEnabled: boolean;\n gamepadInputEmulation: GamepadInputEmulationType;\n readonly language: string;\n readonly maxTouchPoints: number;\n readonly mimeTypes: MimeTypeArray;\n readonly msManipulationViewsEnabled: boolean;\n readonly msMaxTouchPoints: number;\n readonly msPointerEnabled: boolean;\n readonly plugins: PluginArray;\n readonly pointerEnabled: boolean;\n readonly serviceWorker: ServiceWorkerContainer;\n readonly webdriver: boolean;\n readonly hardwareConcurrency: number;\n readonly languages: string[];\n getGamepads(): Gamepad[];\n javaEnabled(): boolean;\n msLaunchUri(uri: string, successCallback?: MSLaunchUriCallback, noHandlerCallback?: MSLaunchUriCallback): void;\n requestMediaKeySystemAccess(keySystem: string, supportedConfigurations: MediaKeySystemConfiguration[]): Promise;\n vibrate(pattern: number | number[]): boolean;\n}\n\ndeclare var Navigator: {\n prototype: Navigator;\n new(): Navigator;\n};\n\ninterface Node extends EventTarget {\n readonly attributes: NamedNodeMap;\n readonly baseURI: string | null;\n readonly childNodes: NodeList;\n readonly firstChild: Node | null;\n readonly lastChild: Node | null;\n readonly localName: string | null;\n readonly namespaceURI: string | null;\n readonly nextSibling: Node | null;\n readonly nodeName: string;\n readonly nodeType: number;\n nodeValue: string | null;\n readonly ownerDocument: Document;\n readonly parentElement: HTMLElement | null;\n readonly parentNode: Node | null;\n readonly previousSibling: Node | null;\n textContent: string | null;\n appendChild(newChild: T): T;\n cloneNode(deep?: boolean): Node;\n compareDocumentPosition(other: Node): number;\n contains(child: Node): boolean;\n hasAttributes(): boolean;\n hasChildNodes(): boolean;\n insertBefore(newChild: T, refChild: Node | null): T;\n isDefaultNamespace(namespaceURI: string | null): boolean;\n isEqualNode(arg: Node): boolean;\n isSameNode(other: Node): boolean;\n lookupNamespaceURI(prefix: string | null): string | null;\n lookupPrefix(namespaceURI: string | null): string | null;\n normalize(): void;\n removeChild(oldChild: T): T;\n replaceChild(newChild: Node, oldChild: T): T;\n readonly ATTRIBUTE_NODE: number;\n readonly CDATA_SECTION_NODE: number;\n readonly COMMENT_NODE: number;\n readonly DOCUMENT_FRAGMENT_NODE: number;\n readonly DOCUMENT_NODE: number;\n readonly DOCUMENT_POSITION_CONTAINED_BY: number;\n readonly DOCUMENT_POSITION_CONTAINS: number;\n readonly DOCUMENT_POSITION_DISCONNECTED: number;\n readonly DOCUMENT_POSITION_FOLLOWING: number;\n readonly DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: number;\n readonly DOCUMENT_POSITION_PRECEDING: number;\n readonly DOCUMENT_TYPE_NODE: number;\n readonly ELEMENT_NODE: number;\n readonly ENTITY_NODE: number;\n readonly ENTITY_REFERENCE_NODE: number;\n readonly NOTATION_NODE: number;\n readonly PROCESSING_INSTRUCTION_NODE: number;\n readonly TEXT_NODE: number;\n}\n\ndeclare var Node: {\n prototype: Node;\n new(): Node;\n readonly ATTRIBUTE_NODE: number;\n readonly CDATA_SECTION_NODE: number;\n readonly COMMENT_NODE: number;\n readonly DOCUMENT_FRAGMENT_NODE: number;\n readonly DOCUMENT_NODE: number;\n readonly DOCUMENT_POSITION_CONTAINED_BY: number;\n readonly DOCUMENT_POSITION_CONTAINS: number;\n readonly DOCUMENT_POSITION_DISCONNECTED: number;\n readonly DOCUMENT_POSITION_FOLLOWING: number;\n readonly DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: number;\n readonly DOCUMENT_POSITION_PRECEDING: number;\n readonly DOCUMENT_TYPE_NODE: number;\n readonly ELEMENT_NODE: number;\n readonly ENTITY_NODE: number;\n readonly ENTITY_REFERENCE_NODE: number;\n readonly NOTATION_NODE: number;\n readonly PROCESSING_INSTRUCTION_NODE: number;\n readonly TEXT_NODE: number;\n};\n\ninterface NodeFilter {\n acceptNode(n: Node): number;\n}\n\ndeclare var NodeFilter: {\n readonly FILTER_ACCEPT: number;\n readonly FILTER_REJECT: number;\n readonly FILTER_SKIP: number;\n readonly SHOW_ALL: number;\n readonly SHOW_ATTRIBUTE: number;\n readonly SHOW_CDATA_SECTION: number;\n readonly SHOW_COMMENT: number;\n readonly SHOW_DOCUMENT: number;\n readonly SHOW_DOCUMENT_FRAGMENT: number;\n readonly SHOW_DOCUMENT_TYPE: number;\n readonly SHOW_ELEMENT: number;\n readonly SHOW_ENTITY: number;\n readonly SHOW_ENTITY_REFERENCE: number;\n readonly SHOW_NOTATION: number;\n readonly SHOW_PROCESSING_INSTRUCTION: number;\n readonly SHOW_TEXT: number;\n};\n\ninterface NodeIterator {\n readonly expandEntityReferences: boolean;\n readonly filter: NodeFilter;\n readonly root: Node;\n readonly whatToShow: number;\n detach(): void;\n nextNode(): Node;\n previousNode(): Node;\n}\n\ndeclare var NodeIterator: {\n prototype: NodeIterator;\n new(): NodeIterator;\n};\n\ninterface NodeList {\n readonly length: number;\n item(index: number): Node;\n [index: number]: Node;\n}\n\ndeclare var NodeList: {\n prototype: NodeList;\n new(): NodeList;\n};\n\ninterface NotificationEventMap {\n \"click\": Event;\n \"close\": Event;\n \"error\": Event;\n \"show\": Event;\n}\n\ninterface Notification extends EventTarget {\n readonly body: string;\n readonly dir: NotificationDirection;\n readonly icon: string;\n readonly lang: string;\n onclick: (this: Notification, ev: Event) => any;\n onclose: (this: Notification, ev: Event) => any;\n onerror: (this: Notification, ev: Event) => any;\n onshow: (this: Notification, ev: Event) => any;\n readonly permission: NotificationPermission;\n readonly tag: string;\n readonly title: string;\n close(): void;\n addEventListener(type: K, listener: (this: Notification, ev: NotificationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Notification: {\n prototype: Notification;\n new(title: string, options?: NotificationOptions): Notification;\n requestPermission(callback?: NotificationPermissionCallback): Promise;\n};\n\ninterface OES_element_index_uint {\n}\n\ndeclare var OES_element_index_uint: {\n prototype: OES_element_index_uint;\n new(): OES_element_index_uint;\n};\n\ninterface OES_standard_derivatives {\n readonly FRAGMENT_SHADER_DERIVATIVE_HINT_OES: number;\n}\n\ndeclare var OES_standard_derivatives: {\n prototype: OES_standard_derivatives;\n new(): OES_standard_derivatives;\n readonly FRAGMENT_SHADER_DERIVATIVE_HINT_OES: number;\n};\n\ninterface OES_texture_float {\n}\n\ndeclare var OES_texture_float: {\n prototype: OES_texture_float;\n new(): OES_texture_float;\n};\n\ninterface OES_texture_float_linear {\n}\n\ndeclare var OES_texture_float_linear: {\n prototype: OES_texture_float_linear;\n new(): OES_texture_float_linear;\n};\n\ninterface OES_texture_half_float {\n readonly HALF_FLOAT_OES: number;\n}\n\ndeclare var OES_texture_half_float: {\n prototype: OES_texture_half_float;\n new(): OES_texture_half_float;\n readonly HALF_FLOAT_OES: number;\n};\n\ninterface OES_texture_half_float_linear {\n}\n\ndeclare var OES_texture_half_float_linear: {\n prototype: OES_texture_half_float_linear;\n new(): OES_texture_half_float_linear;\n};\n\ninterface OfflineAudioCompletionEvent extends Event {\n readonly renderedBuffer: AudioBuffer;\n}\n\ndeclare var OfflineAudioCompletionEvent: {\n prototype: OfflineAudioCompletionEvent;\n new(): OfflineAudioCompletionEvent;\n};\n\ninterface OfflineAudioContextEventMap extends AudioContextEventMap {\n \"complete\": OfflineAudioCompletionEvent;\n}\n\ninterface OfflineAudioContext extends AudioContextBase {\n readonly length: number;\n oncomplete: (this: OfflineAudioContext, ev: OfflineAudioCompletionEvent) => any;\n startRendering(): Promise;\n suspend(suspendTime: number): Promise;\n addEventListener(type: K, listener: (this: OfflineAudioContext, ev: OfflineAudioContextEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var OfflineAudioContext: {\n prototype: OfflineAudioContext;\n new(numberOfChannels: number, length: number, sampleRate: number): OfflineAudioContext;\n};\n\ninterface OscillatorNodeEventMap {\n \"ended\": MediaStreamErrorEvent;\n}\n\ninterface OscillatorNode extends AudioNode {\n readonly detune: AudioParam;\n readonly frequency: AudioParam;\n onended: (this: OscillatorNode, ev: MediaStreamErrorEvent) => any;\n type: OscillatorType;\n setPeriodicWave(periodicWave: PeriodicWave): void;\n start(when?: number): void;\n stop(when?: number): void;\n addEventListener(type: K, listener: (this: OscillatorNode, ev: OscillatorNodeEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var OscillatorNode: {\n prototype: OscillatorNode;\n new(): OscillatorNode;\n};\n\ninterface OverflowEvent extends UIEvent {\n readonly horizontalOverflow: boolean;\n readonly orient: number;\n readonly verticalOverflow: boolean;\n readonly BOTH: number;\n readonly HORIZONTAL: number;\n readonly VERTICAL: number;\n}\n\ndeclare var OverflowEvent: {\n prototype: OverflowEvent;\n new(): OverflowEvent;\n readonly BOTH: number;\n readonly HORIZONTAL: number;\n readonly VERTICAL: number;\n};\n\ninterface PageTransitionEvent extends Event {\n readonly persisted: boolean;\n}\n\ndeclare var PageTransitionEvent: {\n prototype: PageTransitionEvent;\n new(): PageTransitionEvent;\n};\n\ninterface PannerNode extends AudioNode {\n coneInnerAngle: number;\n coneOuterAngle: number;\n coneOuterGain: number;\n distanceModel: DistanceModelType;\n maxDistance: number;\n panningModel: PanningModelType;\n refDistance: number;\n rolloffFactor: number;\n setOrientation(x: number, y: number, z: number): void;\n setPosition(x: number, y: number, z: number): void;\n setVelocity(x: number, y: number, z: number): void;\n}\n\ndeclare var PannerNode: {\n prototype: PannerNode;\n new(): PannerNode;\n};\n\ninterface Path2D extends Object, CanvasPathMethods {\n}\n\ndeclare var Path2D: {\n prototype: Path2D;\n new(path?: Path2D): Path2D;\n};\n\ninterface PaymentAddress {\n readonly addressLine: string[];\n readonly city: string;\n readonly country: string;\n readonly dependentLocality: string;\n readonly languageCode: string;\n readonly organization: string;\n readonly phone: string;\n readonly postalCode: string;\n readonly recipient: string;\n readonly region: string;\n readonly sortingCode: string;\n toJSON(): any;\n}\n\ndeclare var PaymentAddress: {\n prototype: PaymentAddress;\n new(): PaymentAddress;\n};\n\ninterface PaymentRequestEventMap {\n \"shippingaddresschange\": Event;\n \"shippingoptionchange\": Event;\n}\n\ninterface PaymentRequest extends EventTarget {\n onshippingaddresschange: (this: PaymentRequest, ev: Event) => any;\n onshippingoptionchange: (this: PaymentRequest, ev: Event) => any;\n readonly shippingAddress: PaymentAddress | null;\n readonly shippingOption: string | null;\n readonly shippingType: PaymentShippingType | null;\n abort(): Promise;\n show(): Promise;\n addEventListener(type: K, listener: (this: PaymentRequest, ev: PaymentRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var PaymentRequest: {\n prototype: PaymentRequest;\n new(methodData: PaymentMethodData[], details: PaymentDetails, options?: PaymentOptions): PaymentRequest;\n};\n\ninterface PaymentRequestUpdateEvent extends Event {\n updateWith(d: Promise): void;\n}\n\ndeclare var PaymentRequestUpdateEvent: {\n prototype: PaymentRequestUpdateEvent;\n new(type: string, eventInitDict?: PaymentRequestUpdateEventInit): PaymentRequestUpdateEvent;\n};\n\ninterface PaymentResponse {\n readonly details: any;\n readonly methodName: string;\n readonly payerEmail: string | null;\n readonly payerName: string | null;\n readonly payerPhone: string | null;\n readonly shippingAddress: PaymentAddress | null;\n readonly shippingOption: string | null;\n complete(result?: PaymentComplete): Promise;\n toJSON(): any;\n}\n\ndeclare var PaymentResponse: {\n prototype: PaymentResponse;\n new(): PaymentResponse;\n};\n\ninterface Performance {\n readonly navigation: PerformanceNavigation;\n readonly timing: PerformanceTiming;\n clearMarks(markName?: string): void;\n clearMeasures(measureName?: string): void;\n clearResourceTimings(): void;\n getEntries(): any;\n getEntriesByName(name: string, entryType?: string): any;\n getEntriesByType(entryType: string): any;\n getMarks(markName?: string): any;\n getMeasures(measureName?: string): any;\n mark(markName: string): void;\n measure(measureName: string, startMarkName?: string, endMarkName?: string): void;\n now(): number;\n setResourceTimingBufferSize(maxSize: number): void;\n toJSON(): any;\n}\n\ndeclare var Performance: {\n prototype: Performance;\n new(): Performance;\n};\n\ninterface PerformanceEntry {\n readonly duration: number;\n readonly entryType: string;\n readonly name: string;\n readonly startTime: number;\n}\n\ndeclare var PerformanceEntry: {\n prototype: PerformanceEntry;\n new(): PerformanceEntry;\n};\n\ninterface PerformanceMark extends PerformanceEntry {\n}\n\ndeclare var PerformanceMark: {\n prototype: PerformanceMark;\n new(): PerformanceMark;\n};\n\ninterface PerformanceMeasure extends PerformanceEntry {\n}\n\ndeclare var PerformanceMeasure: {\n prototype: PerformanceMeasure;\n new(): PerformanceMeasure;\n};\n\ninterface PerformanceNavigation {\n readonly redirectCount: number;\n readonly type: number;\n toJSON(): any;\n readonly TYPE_BACK_FORWARD: number;\n readonly TYPE_NAVIGATE: number;\n readonly TYPE_RELOAD: number;\n readonly TYPE_RESERVED: number;\n}\n\ndeclare var PerformanceNavigation: {\n prototype: PerformanceNavigation;\n new(): PerformanceNavigation;\n readonly TYPE_BACK_FORWARD: number;\n readonly TYPE_NAVIGATE: number;\n readonly TYPE_RELOAD: number;\n readonly TYPE_RESERVED: number;\n};\n\ninterface PerformanceNavigationTiming extends PerformanceEntry {\n readonly connectEnd: number;\n readonly connectStart: number;\n readonly domainLookupEnd: number;\n readonly domainLookupStart: number;\n readonly domComplete: number;\n readonly domContentLoadedEventEnd: number;\n readonly domContentLoadedEventStart: number;\n readonly domInteractive: number;\n readonly domLoading: number;\n readonly fetchStart: number;\n readonly loadEventEnd: number;\n readonly loadEventStart: number;\n readonly navigationStart: number;\n readonly redirectCount: number;\n readonly redirectEnd: number;\n readonly redirectStart: number;\n readonly requestStart: number;\n readonly responseEnd: number;\n readonly responseStart: number;\n readonly type: NavigationType;\n readonly unloadEventEnd: number;\n readonly unloadEventStart: number;\n}\n\ndeclare var PerformanceNavigationTiming: {\n prototype: PerformanceNavigationTiming;\n new(): PerformanceNavigationTiming;\n};\n\ninterface PerformanceResourceTiming extends PerformanceEntry {\n readonly connectEnd: number;\n readonly connectStart: number;\n readonly domainLookupEnd: number;\n readonly domainLookupStart: number;\n readonly fetchStart: number;\n readonly initiatorType: string;\n readonly redirectEnd: number;\n readonly redirectStart: number;\n readonly requestStart: number;\n readonly responseEnd: number;\n readonly responseStart: number;\n}\n\ndeclare var PerformanceResourceTiming: {\n prototype: PerformanceResourceTiming;\n new(): PerformanceResourceTiming;\n};\n\ninterface PerformanceTiming {\n readonly connectEnd: number;\n readonly connectStart: number;\n readonly domainLookupEnd: number;\n readonly domainLookupStart: number;\n readonly domComplete: number;\n readonly domContentLoadedEventEnd: number;\n readonly domContentLoadedEventStart: number;\n readonly domInteractive: number;\n readonly domLoading: number;\n readonly fetchStart: number;\n readonly loadEventEnd: number;\n readonly loadEventStart: number;\n readonly msFirstPaint: number;\n readonly navigationStart: number;\n readonly redirectEnd: number;\n readonly redirectStart: number;\n readonly requestStart: number;\n readonly responseEnd: number;\n readonly responseStart: number;\n readonly unloadEventEnd: number;\n readonly unloadEventStart: number;\n readonly secureConnectionStart: number;\n toJSON(): any;\n}\n\ndeclare var PerformanceTiming: {\n prototype: PerformanceTiming;\n new(): PerformanceTiming;\n};\n\ninterface PerfWidgetExternal {\n readonly activeNetworkRequestCount: number;\n readonly averageFrameTime: number;\n readonly averagePaintTime: number;\n readonly extraInformationEnabled: boolean;\n readonly independentRenderingEnabled: boolean;\n readonly irDisablingContentString: string;\n readonly irStatusAvailable: boolean;\n readonly maxCpuSpeed: number;\n readonly paintRequestsPerSecond: number;\n readonly performanceCounter: number;\n readonly performanceCounterFrequency: number;\n addEventListener(eventType: string, callback: Function): void;\n getMemoryUsage(): number;\n getProcessCpuUsage(): number;\n getRecentCpuUsage(last: number | null): any;\n getRecentFrames(last: number | null): any;\n getRecentMemoryUsage(last: number | null): any;\n getRecentPaintRequests(last: number | null): any;\n removeEventListener(eventType: string, callback: Function): void;\n repositionWindow(x: number, y: number): void;\n resizeWindow(width: number, height: number): void;\n}\n\ndeclare var PerfWidgetExternal: {\n prototype: PerfWidgetExternal;\n new(): PerfWidgetExternal;\n};\n\ninterface PeriodicWave {\n}\n\ndeclare var PeriodicWave: {\n prototype: PeriodicWave;\n new(): PeriodicWave;\n};\n\ninterface PermissionRequest extends DeferredPermissionRequest {\n readonly state: MSWebViewPermissionState;\n defer(): void;\n}\n\ndeclare var PermissionRequest: {\n prototype: PermissionRequest;\n new(): PermissionRequest;\n};\n\ninterface PermissionRequestedEvent extends Event {\n readonly permissionRequest: PermissionRequest;\n}\n\ndeclare var PermissionRequestedEvent: {\n prototype: PermissionRequestedEvent;\n new(): PermissionRequestedEvent;\n};\n\ninterface Plugin {\n readonly description: string;\n readonly filename: string;\n readonly length: number;\n readonly name: string;\n readonly version: string;\n item(index: number): MimeType;\n namedItem(type: string): MimeType;\n [index: number]: MimeType;\n}\n\ndeclare var Plugin: {\n prototype: Plugin;\n new(): Plugin;\n};\n\ninterface PluginArray {\n readonly length: number;\n item(index: number): Plugin;\n namedItem(name: string): Plugin;\n refresh(reload?: boolean): void;\n [index: number]: Plugin;\n}\n\ndeclare var PluginArray: {\n prototype: PluginArray;\n new(): PluginArray;\n};\n\ninterface PointerEvent extends MouseEvent {\n readonly currentPoint: any;\n readonly height: number;\n readonly hwTimestamp: number;\n readonly intermediatePoints: any;\n readonly isPrimary: boolean;\n readonly pointerId: number;\n readonly pointerType: any;\n readonly pressure: number;\n readonly rotation: number;\n readonly tiltX: number;\n readonly tiltY: number;\n readonly width: number;\n getCurrentPoint(element: Element): void;\n getIntermediatePoints(element: Element): void;\n initPointerEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget, offsetXArg: number, offsetYArg: number, widthArg: number, heightArg: number, pressure: number, rotation: number, tiltX: number, tiltY: number, pointerIdArg: number, pointerType: any, hwTimestampArg: number, isPrimary: boolean): void;\n}\n\ndeclare var PointerEvent: {\n prototype: PointerEvent;\n new(typeArg: string, eventInitDict?: PointerEventInit): PointerEvent;\n};\n\ninterface PopStateEvent extends Event {\n readonly state: any;\n initPopStateEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, stateArg: any): void;\n}\n\ndeclare var PopStateEvent: {\n prototype: PopStateEvent;\n new(typeArg: string, eventInitDict?: PopStateEventInit): PopStateEvent;\n};\n\ninterface Position {\n readonly coords: Coordinates;\n readonly timestamp: number;\n}\n\ndeclare var Position: {\n prototype: Position;\n new(): Position;\n};\n\ninterface PositionError {\n readonly code: number;\n readonly message: string;\n toString(): string;\n readonly PERMISSION_DENIED: number;\n readonly POSITION_UNAVAILABLE: number;\n readonly TIMEOUT: number;\n}\n\ndeclare var PositionError: {\n prototype: PositionError;\n new(): PositionError;\n readonly PERMISSION_DENIED: number;\n readonly POSITION_UNAVAILABLE: number;\n readonly TIMEOUT: number;\n};\n\ninterface ProcessingInstruction extends CharacterData {\n readonly target: string;\n}\n\ndeclare var ProcessingInstruction: {\n prototype: ProcessingInstruction;\n new(): ProcessingInstruction;\n};\n\ninterface ProgressEvent extends Event {\n readonly lengthComputable: boolean;\n readonly loaded: number;\n readonly total: number;\n initProgressEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, lengthComputableArg: boolean, loadedArg: number, totalArg: number): void;\n}\n\ndeclare var ProgressEvent: {\n prototype: ProgressEvent;\n new(type: string, eventInitDict?: ProgressEventInit): ProgressEvent;\n};\n\ninterface PushManager {\n getSubscription(): Promise;\n permissionState(options?: PushSubscriptionOptionsInit): Promise;\n subscribe(options?: PushSubscriptionOptionsInit): Promise;\n}\n\ndeclare var PushManager: {\n prototype: PushManager;\n new(): PushManager;\n};\n\ninterface PushSubscription {\n readonly endpoint: USVString;\n readonly options: PushSubscriptionOptions;\n getKey(name: PushEncryptionKeyName): ArrayBuffer | null;\n toJSON(): any;\n unsubscribe(): Promise;\n}\n\ndeclare var PushSubscription: {\n prototype: PushSubscription;\n new(): PushSubscription;\n};\n\ninterface PushSubscriptionOptions {\n readonly applicationServerKey: ArrayBuffer | null;\n readonly userVisibleOnly: boolean;\n}\n\ndeclare var PushSubscriptionOptions: {\n prototype: PushSubscriptionOptions;\n new(): PushSubscriptionOptions;\n};\n\ninterface Range {\n readonly collapsed: boolean;\n readonly commonAncestorContainer: Node;\n readonly endContainer: Node;\n readonly endOffset: number;\n readonly startContainer: Node;\n readonly startOffset: number;\n cloneContents(): DocumentFragment;\n cloneRange(): Range;\n collapse(toStart: boolean): void;\n compareBoundaryPoints(how: number, sourceRange: Range): number;\n createContextualFragment(fragment: string): DocumentFragment;\n deleteContents(): void;\n detach(): void;\n expand(Unit: ExpandGranularity): boolean;\n extractContents(): DocumentFragment;\n getBoundingClientRect(): ClientRect;\n getClientRects(): ClientRectList;\n insertNode(newNode: Node): void;\n selectNode(refNode: Node): void;\n selectNodeContents(refNode: Node): void;\n setEnd(refNode: Node, offset: number): void;\n setEndAfter(refNode: Node): void;\n setEndBefore(refNode: Node): void;\n setStart(refNode: Node, offset: number): void;\n setStartAfter(refNode: Node): void;\n setStartBefore(refNode: Node): void;\n surroundContents(newParent: Node): void;\n toString(): string;\n readonly END_TO_END: number;\n readonly END_TO_START: number;\n readonly START_TO_END: number;\n readonly START_TO_START: number;\n}\n\ndeclare var Range: {\n prototype: Range;\n new(): Range;\n readonly END_TO_END: number;\n readonly END_TO_START: number;\n readonly START_TO_END: number;\n readonly START_TO_START: number;\n};\n\ninterface ReadableStream {\n readonly locked: boolean;\n cancel(): Promise;\n getReader(): ReadableStreamReader;\n}\n\ndeclare var ReadableStream: {\n prototype: ReadableStream;\n new(): ReadableStream;\n};\n\ninterface ReadableStreamReader {\n cancel(): Promise;\n read(): Promise;\n releaseLock(): void;\n}\n\ndeclare var ReadableStreamReader: {\n prototype: ReadableStreamReader;\n new(): ReadableStreamReader;\n};\n\ninterface Request extends Object, Body {\n readonly cache: RequestCache;\n readonly credentials: RequestCredentials;\n readonly destination: RequestDestination;\n readonly headers: Headers;\n readonly integrity: string;\n readonly keepalive: boolean;\n readonly method: string;\n readonly mode: RequestMode;\n readonly redirect: RequestRedirect;\n readonly referrer: string;\n readonly referrerPolicy: ReferrerPolicy;\n readonly type: RequestType;\n readonly url: string;\n clone(): Request;\n}\n\ndeclare var Request: {\n prototype: Request;\n new(input: Request | string, init?: RequestInit): Request;\n};\n\ninterface Response extends Object, Body {\n readonly body: ReadableStream | null;\n readonly headers: Headers;\n readonly ok: boolean;\n readonly status: number;\n readonly statusText: string;\n readonly type: ResponseType;\n readonly url: string;\n clone(): Response;\n}\n\ndeclare var Response: {\n prototype: Response;\n new(body?: any, init?: ResponseInit): Response;\n error: () => Response;\n redirect: (url: string, status?: number) => Response;\n};\n\ninterface RTCDtlsTransportEventMap {\n \"dtlsstatechange\": RTCDtlsTransportStateChangedEvent;\n \"error\": Event;\n}\n\ninterface RTCDtlsTransport extends RTCStatsProvider {\n ondtlsstatechange: ((this: RTCDtlsTransport, ev: RTCDtlsTransportStateChangedEvent) => any) | null;\n onerror: ((this: RTCDtlsTransport, ev: Event) => any) | null;\n readonly state: RTCDtlsTransportState;\n readonly transport: RTCIceTransport;\n getLocalParameters(): RTCDtlsParameters;\n getRemoteCertificates(): ArrayBuffer[];\n getRemoteParameters(): RTCDtlsParameters | null;\n start(remoteParameters: RTCDtlsParameters): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCDtlsTransport, ev: RTCDtlsTransportEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCDtlsTransport: {\n prototype: RTCDtlsTransport;\n new(transport: RTCIceTransport): RTCDtlsTransport;\n};\n\ninterface RTCDtlsTransportStateChangedEvent extends Event {\n readonly state: RTCDtlsTransportState;\n}\n\ndeclare var RTCDtlsTransportStateChangedEvent: {\n prototype: RTCDtlsTransportStateChangedEvent;\n new(): RTCDtlsTransportStateChangedEvent;\n};\n\ninterface RTCDtmfSenderEventMap {\n \"tonechange\": RTCDTMFToneChangeEvent;\n}\n\ninterface RTCDtmfSender extends EventTarget {\n readonly canInsertDTMF: boolean;\n readonly duration: number;\n readonly interToneGap: number;\n ontonechange: (this: RTCDtmfSender, ev: RTCDTMFToneChangeEvent) => any;\n readonly sender: RTCRtpSender;\n readonly toneBuffer: string;\n insertDTMF(tones: string, duration?: number, interToneGap?: number): void;\n addEventListener(type: K, listener: (this: RTCDtmfSender, ev: RTCDtmfSenderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCDtmfSender: {\n prototype: RTCDtmfSender;\n new(sender: RTCRtpSender): RTCDtmfSender;\n};\n\ninterface RTCDTMFToneChangeEvent extends Event {\n readonly tone: string;\n}\n\ndeclare var RTCDTMFToneChangeEvent: {\n prototype: RTCDTMFToneChangeEvent;\n new(typeArg: string, eventInitDict: RTCDTMFToneChangeEventInit): RTCDTMFToneChangeEvent;\n};\n\ninterface RTCIceCandidate {\n candidate: string | null;\n sdpMid: string | null;\n sdpMLineIndex: number | null;\n toJSON(): any;\n}\n\ndeclare var RTCIceCandidate: {\n prototype: RTCIceCandidate;\n new(candidateInitDict?: RTCIceCandidateInit): RTCIceCandidate;\n};\n\ninterface RTCIceCandidatePairChangedEvent extends Event {\n readonly pair: RTCIceCandidatePair;\n}\n\ndeclare var RTCIceCandidatePairChangedEvent: {\n prototype: RTCIceCandidatePairChangedEvent;\n new(): RTCIceCandidatePairChangedEvent;\n};\n\ninterface RTCIceGathererEventMap {\n \"error\": Event;\n \"localcandidate\": RTCIceGathererEvent;\n}\n\ninterface RTCIceGatherer extends RTCStatsProvider {\n readonly component: RTCIceComponent;\n onerror: ((this: RTCIceGatherer, ev: Event) => any) | null;\n onlocalcandidate: ((this: RTCIceGatherer, ev: RTCIceGathererEvent) => any) | null;\n createAssociatedGatherer(): RTCIceGatherer;\n getLocalCandidates(): RTCIceCandidateDictionary[];\n getLocalParameters(): RTCIceParameters;\n addEventListener(type: K, listener: (this: RTCIceGatherer, ev: RTCIceGathererEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCIceGatherer: {\n prototype: RTCIceGatherer;\n new(options: RTCIceGatherOptions): RTCIceGatherer;\n};\n\ninterface RTCIceGathererEvent extends Event {\n readonly candidate: RTCIceCandidateDictionary | RTCIceCandidateComplete;\n}\n\ndeclare var RTCIceGathererEvent: {\n prototype: RTCIceGathererEvent;\n new(): RTCIceGathererEvent;\n};\n\ninterface RTCIceTransportEventMap {\n \"candidatepairchange\": RTCIceCandidatePairChangedEvent;\n \"icestatechange\": RTCIceTransportStateChangedEvent;\n}\n\ninterface RTCIceTransport extends RTCStatsProvider {\n readonly component: RTCIceComponent;\n readonly iceGatherer: RTCIceGatherer | null;\n oncandidatepairchange: ((this: RTCIceTransport, ev: RTCIceCandidatePairChangedEvent) => any) | null;\n onicestatechange: ((this: RTCIceTransport, ev: RTCIceTransportStateChangedEvent) => any) | null;\n readonly role: RTCIceRole;\n readonly state: RTCIceTransportState;\n addRemoteCandidate(remoteCandidate: RTCIceCandidateDictionary | RTCIceCandidateComplete): void;\n createAssociatedTransport(): RTCIceTransport;\n getNominatedCandidatePair(): RTCIceCandidatePair | null;\n getRemoteCandidates(): RTCIceCandidateDictionary[];\n getRemoteParameters(): RTCIceParameters | null;\n setRemoteCandidates(remoteCandidates: RTCIceCandidateDictionary[]): void;\n start(gatherer: RTCIceGatherer, remoteParameters: RTCIceParameters, role?: RTCIceRole): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCIceTransport, ev: RTCIceTransportEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCIceTransport: {\n prototype: RTCIceTransport;\n new(): RTCIceTransport;\n};\n\ninterface RTCIceTransportStateChangedEvent extends Event {\n readonly state: RTCIceTransportState;\n}\n\ndeclare var RTCIceTransportStateChangedEvent: {\n prototype: RTCIceTransportStateChangedEvent;\n new(): RTCIceTransportStateChangedEvent;\n};\n\ninterface RTCPeerConnectionEventMap {\n \"addstream\": MediaStreamEvent;\n \"icecandidate\": RTCPeerConnectionIceEvent;\n \"iceconnectionstatechange\": Event;\n \"icegatheringstatechange\": Event;\n \"negotiationneeded\": Event;\n \"removestream\": MediaStreamEvent;\n \"signalingstatechange\": Event;\n}\n\ninterface RTCPeerConnection extends EventTarget {\n readonly canTrickleIceCandidates: boolean | null;\n readonly iceConnectionState: RTCIceConnectionState;\n readonly iceGatheringState: RTCIceGatheringState;\n readonly localDescription: RTCSessionDescription | null;\n onaddstream: (this: RTCPeerConnection, ev: MediaStreamEvent) => any;\n onicecandidate: (this: RTCPeerConnection, ev: RTCPeerConnectionIceEvent) => any;\n oniceconnectionstatechange: (this: RTCPeerConnection, ev: Event) => any;\n onicegatheringstatechange: (this: RTCPeerConnection, ev: Event) => any;\n onnegotiationneeded: (this: RTCPeerConnection, ev: Event) => any;\n onremovestream: (this: RTCPeerConnection, ev: MediaStreamEvent) => any;\n onsignalingstatechange: (this: RTCPeerConnection, ev: Event) => any;\n readonly remoteDescription: RTCSessionDescription | null;\n readonly signalingState: RTCSignalingState;\n addIceCandidate(candidate: RTCIceCandidate, successCallback?: VoidFunction, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n addStream(stream: MediaStream): void;\n close(): void;\n createAnswer(successCallback?: RTCSessionDescriptionCallback, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n createOffer(successCallback?: RTCSessionDescriptionCallback, failureCallback?: RTCPeerConnectionErrorCallback, options?: RTCOfferOptions): Promise;\n getConfiguration(): RTCConfiguration;\n getLocalStreams(): MediaStream[];\n getRemoteStreams(): MediaStream[];\n getStats(selector: MediaStreamTrack | null, successCallback?: RTCStatsCallback, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n getStreamById(streamId: string): MediaStream | null;\n removeStream(stream: MediaStream): void;\n setLocalDescription(description: RTCSessionDescription, successCallback?: VoidFunction, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n setRemoteDescription(description: RTCSessionDescription, successCallback?: VoidFunction, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n addEventListener(type: K, listener: (this: RTCPeerConnection, ev: RTCPeerConnectionEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCPeerConnection: {\n prototype: RTCPeerConnection;\n new(configuration: RTCConfiguration): RTCPeerConnection;\n};\n\ninterface RTCPeerConnectionIceEvent extends Event {\n readonly candidate: RTCIceCandidate;\n}\n\ndeclare var RTCPeerConnectionIceEvent: {\n prototype: RTCPeerConnectionIceEvent;\n new(type: string, eventInitDict: RTCPeerConnectionIceEventInit): RTCPeerConnectionIceEvent;\n};\n\ninterface RTCRtpReceiverEventMap {\n \"error\": Event;\n}\n\ninterface RTCRtpReceiver extends RTCStatsProvider {\n onerror: ((this: RTCRtpReceiver, ev: Event) => any) | null;\n readonly rtcpTransport: RTCDtlsTransport;\n readonly track: MediaStreamTrack | null;\n readonly transport: RTCDtlsTransport | RTCSrtpSdesTransport;\n getContributingSources(): RTCRtpContributingSource[];\n receive(parameters: RTCRtpParameters): void;\n requestSendCSRC(csrc: number): void;\n setTransport(transport: RTCDtlsTransport | RTCSrtpSdesTransport, rtcpTransport?: RTCDtlsTransport): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCRtpReceiver, ev: RTCRtpReceiverEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCRtpReceiver: {\n prototype: RTCRtpReceiver;\n new(transport: RTCDtlsTransport | RTCSrtpSdesTransport, kind: string, rtcpTransport?: RTCDtlsTransport): RTCRtpReceiver;\n getCapabilities(kind?: string): RTCRtpCapabilities;\n};\n\ninterface RTCRtpSenderEventMap {\n \"error\": Event;\n \"ssrcconflict\": RTCSsrcConflictEvent;\n}\n\ninterface RTCRtpSender extends RTCStatsProvider {\n onerror: ((this: RTCRtpSender, ev: Event) => any) | null;\n onssrcconflict: ((this: RTCRtpSender, ev: RTCSsrcConflictEvent) => any) | null;\n readonly rtcpTransport: RTCDtlsTransport;\n readonly track: MediaStreamTrack;\n readonly transport: RTCDtlsTransport | RTCSrtpSdesTransport;\n send(parameters: RTCRtpParameters): void;\n setTrack(track: MediaStreamTrack): void;\n setTransport(transport: RTCDtlsTransport | RTCSrtpSdesTransport, rtcpTransport?: RTCDtlsTransport): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCRtpSender, ev: RTCRtpSenderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCRtpSender: {\n prototype: RTCRtpSender;\n new(track: MediaStreamTrack, transport: RTCDtlsTransport | RTCSrtpSdesTransport, rtcpTransport?: RTCDtlsTransport): RTCRtpSender;\n getCapabilities(kind?: string): RTCRtpCapabilities;\n};\n\ninterface RTCSessionDescription {\n sdp: string | null;\n type: RTCSdpType | null;\n toJSON(): any;\n}\n\ndeclare var RTCSessionDescription: {\n prototype: RTCSessionDescription;\n new(descriptionInitDict?: RTCSessionDescriptionInit): RTCSessionDescription;\n};\n\ninterface RTCSrtpSdesTransportEventMap {\n \"error\": Event;\n}\n\ninterface RTCSrtpSdesTransport extends EventTarget {\n onerror: ((this: RTCSrtpSdesTransport, ev: Event) => any) | null;\n readonly transport: RTCIceTransport;\n addEventListener(type: K, listener: (this: RTCSrtpSdesTransport, ev: RTCSrtpSdesTransportEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCSrtpSdesTransport: {\n prototype: RTCSrtpSdesTransport;\n new(transport: RTCIceTransport, encryptParameters: RTCSrtpSdesParameters, decryptParameters: RTCSrtpSdesParameters): RTCSrtpSdesTransport;\n getLocalParameters(): RTCSrtpSdesParameters[];\n};\n\ninterface RTCSsrcConflictEvent extends Event {\n readonly ssrc: number;\n}\n\ndeclare var RTCSsrcConflictEvent: {\n prototype: RTCSsrcConflictEvent;\n new(): RTCSsrcConflictEvent;\n};\n\ninterface RTCStatsProvider extends EventTarget {\n getStats(): Promise;\n msGetStats(): Promise;\n}\n\ndeclare var RTCStatsProvider: {\n prototype: RTCStatsProvider;\n new(): RTCStatsProvider;\n};\n\ninterface ScopedCredential {\n readonly id: ArrayBuffer;\n readonly type: ScopedCredentialType;\n}\n\ndeclare var ScopedCredential: {\n prototype: ScopedCredential;\n new(): ScopedCredential;\n};\n\ninterface ScopedCredentialInfo {\n readonly credential: ScopedCredential;\n readonly publicKey: CryptoKey;\n}\n\ndeclare var ScopedCredentialInfo: {\n prototype: ScopedCredentialInfo;\n new(): ScopedCredentialInfo;\n};\n\ninterface ScreenEventMap {\n \"MSOrientationChange\": Event;\n}\n\ninterface Screen extends EventTarget {\n readonly availHeight: number;\n readonly availWidth: number;\n bufferDepth: number;\n readonly colorDepth: number;\n readonly deviceXDPI: number;\n readonly deviceYDPI: number;\n readonly fontSmoothingEnabled: boolean;\n readonly height: number;\n readonly logicalXDPI: number;\n readonly logicalYDPI: number;\n readonly msOrientation: string;\n onmsorientationchange: (this: Screen, ev: Event) => any;\n readonly pixelDepth: number;\n readonly systemXDPI: number;\n readonly systemYDPI: number;\n readonly width: number;\n msLockOrientation(orientations: string | string[]): boolean;\n msUnlockOrientation(): void;\n addEventListener(type: K, listener: (this: Screen, ev: ScreenEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Screen: {\n prototype: Screen;\n new(): Screen;\n};\n\ninterface ScriptNotifyEvent extends Event {\n readonly callingUri: string;\n readonly value: string;\n}\n\ndeclare var ScriptNotifyEvent: {\n prototype: ScriptNotifyEvent;\n new(): ScriptNotifyEvent;\n};\n\ninterface ScriptProcessorNodeEventMap {\n \"audioprocess\": AudioProcessingEvent;\n}\n\ninterface ScriptProcessorNode extends AudioNode {\n readonly bufferSize: number;\n onaudioprocess: (this: ScriptProcessorNode, ev: AudioProcessingEvent) => any;\n addEventListener(type: K, listener: (this: ScriptProcessorNode, ev: ScriptProcessorNodeEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ScriptProcessorNode: {\n prototype: ScriptProcessorNode;\n new(): ScriptProcessorNode;\n};\n\ninterface Selection {\n readonly anchorNode: Node;\n readonly anchorOffset: number;\n readonly baseNode: Node;\n readonly baseOffset: number;\n readonly extentNode: Node;\n readonly extentOffset: number;\n readonly focusNode: Node;\n readonly focusOffset: number;\n readonly isCollapsed: boolean;\n readonly rangeCount: number;\n readonly type: string;\n addRange(range: Range): void;\n collapse(parentNode: Node, offset: number): void;\n collapseToEnd(): void;\n collapseToStart(): void;\n containsNode(node: Node, partlyContained: boolean): boolean;\n deleteFromDocument(): void;\n empty(): void;\n extend(newNode: Node, offset: number): void;\n getRangeAt(index: number): Range;\n removeAllRanges(): void;\n removeRange(range: Range): void;\n selectAllChildren(parentNode: Node): void;\n setBaseAndExtent(baseNode: Node, baseOffset: number, extentNode: Node, extentOffset: number): void;\n setPosition(parentNode: Node, offset: number): void;\n toString(): string;\n}\n\ndeclare var Selection: {\n prototype: Selection;\n new(): Selection;\n};\n\ninterface ServiceWorkerEventMap extends AbstractWorkerEventMap {\n \"statechange\": Event;\n}\n\ninterface ServiceWorker extends EventTarget, AbstractWorker {\n onstatechange: (this: ServiceWorker, ev: Event) => any;\n readonly scriptURL: USVString;\n readonly state: ServiceWorkerState;\n postMessage(message: any, transfer?: any[]): void;\n addEventListener(type: K, listener: (this: ServiceWorker, ev: ServiceWorkerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ServiceWorker: {\n prototype: ServiceWorker;\n new(): ServiceWorker;\n};\n\ninterface ServiceWorkerContainerEventMap {\n \"controllerchange\": Event;\n \"message\": ServiceWorkerMessageEvent;\n}\n\ninterface ServiceWorkerContainer extends EventTarget {\n readonly controller: ServiceWorker | null;\n oncontrollerchange: (this: ServiceWorkerContainer, ev: Event) => any;\n onmessage: (this: ServiceWorkerContainer, ev: ServiceWorkerMessageEvent) => any;\n readonly ready: Promise;\n getRegistration(clientURL?: USVString): Promise;\n getRegistrations(): any;\n register(scriptURL: USVString, options?: RegistrationOptions): Promise;\n addEventListener(type: K, listener: (this: ServiceWorkerContainer, ev: ServiceWorkerContainerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ServiceWorkerContainer: {\n prototype: ServiceWorkerContainer;\n new(): ServiceWorkerContainer;\n};\n\ninterface ServiceWorkerMessageEvent extends Event {\n readonly data: any;\n readonly lastEventId: string;\n readonly origin: string;\n readonly ports: MessagePort[] | null;\n readonly source: ServiceWorker | MessagePort | null;\n}\n\ndeclare var ServiceWorkerMessageEvent: {\n prototype: ServiceWorkerMessageEvent;\n new(type: string, eventInitDict?: ServiceWorkerMessageEventInit): ServiceWorkerMessageEvent;\n};\n\ninterface ServiceWorkerRegistrationEventMap {\n \"updatefound\": Event;\n}\n\ninterface ServiceWorkerRegistration extends EventTarget {\n readonly active: ServiceWorker | null;\n readonly installing: ServiceWorker | null;\n onupdatefound: (this: ServiceWorkerRegistration, ev: Event) => any;\n readonly pushManager: PushManager;\n readonly scope: USVString;\n readonly sync: SyncManager;\n readonly waiting: ServiceWorker | null;\n getNotifications(filter?: GetNotificationOptions): any;\n showNotification(title: string, options?: NotificationOptions): Promise;\n unregister(): Promise;\n update(): Promise;\n addEventListener(type: K, listener: (this: ServiceWorkerRegistration, ev: ServiceWorkerRegistrationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ServiceWorkerRegistration: {\n prototype: ServiceWorkerRegistration;\n new(): ServiceWorkerRegistration;\n};\n\ninterface SourceBuffer extends EventTarget {\n appendWindowEnd: number;\n appendWindowStart: number;\n readonly audioTracks: AudioTrackList;\n readonly buffered: TimeRanges;\n mode: AppendMode;\n timestampOffset: number;\n readonly updating: boolean;\n readonly videoTracks: VideoTrackList;\n abort(): void;\n appendBuffer(data: ArrayBuffer | ArrayBufferView): void;\n appendStream(stream: MSStream, maxSize?: number): void;\n remove(start: number, end: number): void;\n}\n\ndeclare var SourceBuffer: {\n prototype: SourceBuffer;\n new(): SourceBuffer;\n};\n\ninterface SourceBufferList extends EventTarget {\n readonly length: number;\n item(index: number): SourceBuffer;\n [index: number]: SourceBuffer;\n}\n\ndeclare var SourceBufferList: {\n prototype: SourceBufferList;\n new(): SourceBufferList;\n};\n\ninterface SpeechSynthesisEventMap {\n \"voiceschanged\": Event;\n}\n\ninterface SpeechSynthesis extends EventTarget {\n onvoiceschanged: (this: SpeechSynthesis, ev: Event) => any;\n readonly paused: boolean;\n readonly pending: boolean;\n readonly speaking: boolean;\n cancel(): void;\n getVoices(): SpeechSynthesisVoice[];\n pause(): void;\n resume(): void;\n speak(utterance: SpeechSynthesisUtterance): void;\n addEventListener(type: K, listener: (this: SpeechSynthesis, ev: SpeechSynthesisEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SpeechSynthesis: {\n prototype: SpeechSynthesis;\n new(): SpeechSynthesis;\n};\n\ninterface SpeechSynthesisEvent extends Event {\n readonly charIndex: number;\n readonly elapsedTime: number;\n readonly name: string;\n readonly utterance: SpeechSynthesisUtterance | null;\n}\n\ndeclare var SpeechSynthesisEvent: {\n prototype: SpeechSynthesisEvent;\n new(type: string, eventInitDict?: SpeechSynthesisEventInit): SpeechSynthesisEvent;\n};\n\ninterface SpeechSynthesisUtteranceEventMap {\n \"boundary\": Event;\n \"end\": Event;\n \"error\": Event;\n \"mark\": Event;\n \"pause\": Event;\n \"resume\": Event;\n \"start\": Event;\n}\n\ninterface SpeechSynthesisUtterance extends EventTarget {\n lang: string;\n onboundary: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onend: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onerror: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onmark: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onpause: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onresume: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onstart: (this: SpeechSynthesisUtterance, ev: Event) => any;\n pitch: number;\n rate: number;\n text: string;\n voice: SpeechSynthesisVoice;\n volume: number;\n addEventListener(type: K, listener: (this: SpeechSynthesisUtterance, ev: SpeechSynthesisUtteranceEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SpeechSynthesisUtterance: {\n prototype: SpeechSynthesisUtterance;\n new(text?: string): SpeechSynthesisUtterance;\n};\n\ninterface SpeechSynthesisVoice {\n readonly default: boolean;\n readonly lang: string;\n readonly localService: boolean;\n readonly name: string;\n readonly voiceURI: string;\n}\n\ndeclare var SpeechSynthesisVoice: {\n prototype: SpeechSynthesisVoice;\n new(): SpeechSynthesisVoice;\n};\n\ninterface StereoPannerNode extends AudioNode {\n readonly pan: AudioParam;\n}\n\ndeclare var StereoPannerNode: {\n prototype: StereoPannerNode;\n new(): StereoPannerNode;\n};\n\ninterface Storage {\n readonly length: number;\n clear(): void;\n getItem(key: string): string | null;\n key(index: number): string | null;\n removeItem(key: string): void;\n setItem(key: string, data: string): void;\n [key: string]: any;\n [index: number]: string;\n}\n\ndeclare var Storage: {\n prototype: Storage;\n new(): Storage;\n};\n\ninterface StorageEvent extends Event {\n readonly url: string;\n key?: string;\n oldValue?: string;\n newValue?: string;\n storageArea?: Storage;\n}\n\ndeclare var StorageEvent: {\n prototype: StorageEvent;\n new (type: string, eventInitDict?: StorageEventInit): StorageEvent;\n};\n\ninterface StyleMedia {\n readonly type: string;\n matchMedium(mediaquery: string): boolean;\n}\n\ndeclare var StyleMedia: {\n prototype: StyleMedia;\n new(): StyleMedia;\n};\n\ninterface StyleSheet {\n disabled: boolean;\n readonly href: string;\n readonly media: MediaList;\n readonly ownerNode: Node;\n readonly parentStyleSheet: StyleSheet;\n readonly title: string;\n readonly type: string;\n}\n\ndeclare var StyleSheet: {\n prototype: StyleSheet;\n new(): StyleSheet;\n};\n\ninterface StyleSheetList {\n readonly length: number;\n item(index?: number): StyleSheet;\n [index: number]: StyleSheet;\n}\n\ndeclare var StyleSheetList: {\n prototype: StyleSheetList;\n new(): StyleSheetList;\n};\n\ninterface StyleSheetPageList {\n readonly length: number;\n item(index: number): CSSPageRule;\n [index: number]: CSSPageRule;\n}\n\ndeclare var StyleSheetPageList: {\n prototype: StyleSheetPageList;\n new(): StyleSheetPageList;\n};\n\ninterface SubtleCrypto {\n decrypt(algorithm: string | RsaOaepParams | AesCtrParams | AesCbcParams | AesCmacParams | AesGcmParams | AesCfbParams, key: CryptoKey, data: BufferSource): PromiseLike;\n deriveBits(algorithm: string | EcdhKeyDeriveParams | DhKeyDeriveParams | ConcatParams | HkdfCtrParams | Pbkdf2Params, baseKey: CryptoKey, length: number): PromiseLike;\n deriveKey(algorithm: string | EcdhKeyDeriveParams | DhKeyDeriveParams | ConcatParams | HkdfCtrParams | Pbkdf2Params, baseKey: CryptoKey, derivedKeyType: string | AesDerivedKeyParams | HmacImportParams | ConcatParams | HkdfCtrParams | Pbkdf2Params, extractable: boolean, keyUsages: string[]): PromiseLike;\n digest(algorithm: AlgorithmIdentifier, data: BufferSource): PromiseLike;\n encrypt(algorithm: string | RsaOaepParams | AesCtrParams | AesCbcParams | AesCmacParams | AesGcmParams | AesCfbParams, key: CryptoKey, data: BufferSource): PromiseLike;\n exportKey(format: \"jwk\", key: CryptoKey): PromiseLike;\n exportKey(format: \"raw\" | \"pkcs8\" | \"spki\", key: CryptoKey): PromiseLike;\n exportKey(format: string, key: CryptoKey): PromiseLike;\n generateKey(algorithm: string, extractable: boolean, keyUsages: string[]): PromiseLike;\n generateKey(algorithm: RsaHashedKeyGenParams | EcKeyGenParams | DhKeyGenParams, extractable: boolean, keyUsages: string[]): PromiseLike;\n generateKey(algorithm: AesKeyGenParams | HmacKeyGenParams | Pbkdf2Params, extractable: boolean, keyUsages: string[]): PromiseLike;\n importKey(format: \"jwk\", keyData: JsonWebKey, algorithm: string | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | DhImportKeyParams, extractable: boolean, keyUsages: string[]): PromiseLike;\n importKey(format: \"raw\" | \"pkcs8\" | \"spki\", keyData: BufferSource, algorithm: string | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | DhImportKeyParams, extractable: boolean, keyUsages: string[]): PromiseLike;\n importKey(format: string, keyData: JsonWebKey | BufferSource, algorithm: string | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | DhImportKeyParams, extractable: boolean, keyUsages: string[]): PromiseLike;\n sign(algorithm: string | RsaPssParams | EcdsaParams | AesCmacParams, key: CryptoKey, data: BufferSource): PromiseLike;\n unwrapKey(format: string, wrappedKey: BufferSource, unwrappingKey: CryptoKey, unwrapAlgorithm: AlgorithmIdentifier, unwrappedKeyAlgorithm: AlgorithmIdentifier, extractable: boolean, keyUsages: string[]): PromiseLike;\n verify(algorithm: string | RsaPssParams | EcdsaParams | AesCmacParams, key: CryptoKey, signature: BufferSource, data: BufferSource): PromiseLike;\n wrapKey(format: string, key: CryptoKey, wrappingKey: CryptoKey, wrapAlgorithm: AlgorithmIdentifier): PromiseLike;\n}\n\ndeclare var SubtleCrypto: {\n prototype: SubtleCrypto;\n new(): SubtleCrypto;\n};\n\ninterface SVGAElement extends SVGGraphicsElement, SVGURIReference {\n readonly target: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGAElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGAElement: {\n prototype: SVGAElement;\n new(): SVGAElement;\n};\n\ninterface SVGAngle {\n readonly unitType: number;\n value: number;\n valueAsString: string;\n valueInSpecifiedUnits: number;\n convertToSpecifiedUnits(unitType: number): void;\n newValueSpecifiedUnits(unitType: number, valueInSpecifiedUnits: number): void;\n readonly SVG_ANGLETYPE_DEG: number;\n readonly SVG_ANGLETYPE_GRAD: number;\n readonly SVG_ANGLETYPE_RAD: number;\n readonly SVG_ANGLETYPE_UNKNOWN: number;\n readonly SVG_ANGLETYPE_UNSPECIFIED: number;\n}\n\ndeclare var SVGAngle: {\n prototype: SVGAngle;\n new(): SVGAngle;\n readonly SVG_ANGLETYPE_DEG: number;\n readonly SVG_ANGLETYPE_GRAD: number;\n readonly SVG_ANGLETYPE_RAD: number;\n readonly SVG_ANGLETYPE_UNKNOWN: number;\n readonly SVG_ANGLETYPE_UNSPECIFIED: number;\n};\n\ninterface SVGAnimatedAngle {\n readonly animVal: SVGAngle;\n readonly baseVal: SVGAngle;\n}\n\ndeclare var SVGAnimatedAngle: {\n prototype: SVGAnimatedAngle;\n new(): SVGAnimatedAngle;\n};\n\ninterface SVGAnimatedBoolean {\n readonly animVal: boolean;\n baseVal: boolean;\n}\n\ndeclare var SVGAnimatedBoolean: {\n prototype: SVGAnimatedBoolean;\n new(): SVGAnimatedBoolean;\n};\n\ninterface SVGAnimatedEnumeration {\n readonly animVal: number;\n baseVal: number;\n}\n\ndeclare var SVGAnimatedEnumeration: {\n prototype: SVGAnimatedEnumeration;\n new(): SVGAnimatedEnumeration;\n};\n\ninterface SVGAnimatedInteger {\n readonly animVal: number;\n baseVal: number;\n}\n\ndeclare var SVGAnimatedInteger: {\n prototype: SVGAnimatedInteger;\n new(): SVGAnimatedInteger;\n};\n\ninterface SVGAnimatedLength {\n readonly animVal: SVGLength;\n readonly baseVal: SVGLength;\n}\n\ndeclare var SVGAnimatedLength: {\n prototype: SVGAnimatedLength;\n new(): SVGAnimatedLength;\n};\n\ninterface SVGAnimatedLengthList {\n readonly animVal: SVGLengthList;\n readonly baseVal: SVGLengthList;\n}\n\ndeclare var SVGAnimatedLengthList: {\n prototype: SVGAnimatedLengthList;\n new(): SVGAnimatedLengthList;\n};\n\ninterface SVGAnimatedNumber {\n readonly animVal: number;\n baseVal: number;\n}\n\ndeclare var SVGAnimatedNumber: {\n prototype: SVGAnimatedNumber;\n new(): SVGAnimatedNumber;\n};\n\ninterface SVGAnimatedNumberList {\n readonly animVal: SVGNumberList;\n readonly baseVal: SVGNumberList;\n}\n\ndeclare var SVGAnimatedNumberList: {\n prototype: SVGAnimatedNumberList;\n new(): SVGAnimatedNumberList;\n};\n\ninterface SVGAnimatedPreserveAspectRatio {\n readonly animVal: SVGPreserveAspectRatio;\n readonly baseVal: SVGPreserveAspectRatio;\n}\n\ndeclare var SVGAnimatedPreserveAspectRatio: {\n prototype: SVGAnimatedPreserveAspectRatio;\n new(): SVGAnimatedPreserveAspectRatio;\n};\n\ninterface SVGAnimatedRect {\n readonly animVal: SVGRect;\n readonly baseVal: SVGRect;\n}\n\ndeclare var SVGAnimatedRect: {\n prototype: SVGAnimatedRect;\n new(): SVGAnimatedRect;\n};\n\ninterface SVGAnimatedString {\n readonly animVal: string;\n baseVal: string;\n}\n\ndeclare var SVGAnimatedString: {\n prototype: SVGAnimatedString;\n new(): SVGAnimatedString;\n};\n\ninterface SVGAnimatedTransformList {\n readonly animVal: SVGTransformList;\n readonly baseVal: SVGTransformList;\n}\n\ndeclare var SVGAnimatedTransformList: {\n prototype: SVGAnimatedTransformList;\n new(): SVGAnimatedTransformList;\n};\n\ninterface SVGCircleElement extends SVGGraphicsElement {\n readonly cx: SVGAnimatedLength;\n readonly cy: SVGAnimatedLength;\n readonly r: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGCircleElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGCircleElement: {\n prototype: SVGCircleElement;\n new(): SVGCircleElement;\n};\n\ninterface SVGClipPathElement extends SVGGraphicsElement, SVGUnitTypes {\n readonly clipPathUnits: SVGAnimatedEnumeration;\n addEventListener(type: K, listener: (this: SVGClipPathElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGClipPathElement: {\n prototype: SVGClipPathElement;\n new(): SVGClipPathElement;\n};\n\ninterface SVGComponentTransferFunctionElement extends SVGElement {\n readonly amplitude: SVGAnimatedNumber;\n readonly exponent: SVGAnimatedNumber;\n readonly intercept: SVGAnimatedNumber;\n readonly offset: SVGAnimatedNumber;\n readonly slope: SVGAnimatedNumber;\n readonly tableValues: SVGAnimatedNumberList;\n readonly type: SVGAnimatedEnumeration;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_DISCRETE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_GAMMA: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_IDENTITY: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_LINEAR: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_TABLE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGComponentTransferFunctionElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGComponentTransferFunctionElement: {\n prototype: SVGComponentTransferFunctionElement;\n new(): SVGComponentTransferFunctionElement;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_DISCRETE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_GAMMA: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_IDENTITY: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_LINEAR: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_TABLE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_UNKNOWN: number;\n};\n\ninterface SVGDefsElement extends SVGGraphicsElement {\n addEventListener(type: K, listener: (this: SVGDefsElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGDefsElement: {\n prototype: SVGDefsElement;\n new(): SVGDefsElement;\n};\n\ninterface SVGDescElement extends SVGElement {\n addEventListener(type: K, listener: (this: SVGDescElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGDescElement: {\n prototype: SVGDescElement;\n new(): SVGDescElement;\n};\n\ninterface SVGElementEventMap extends ElementEventMap {\n \"click\": MouseEvent;\n \"dblclick\": MouseEvent;\n \"focusin\": FocusEvent;\n \"focusout\": FocusEvent;\n \"load\": Event;\n \"mousedown\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n}\n\ninterface SVGElement extends Element {\n className: any;\n onclick: (this: SVGElement, ev: MouseEvent) => any;\n ondblclick: (this: SVGElement, ev: MouseEvent) => any;\n onfocusin: (this: SVGElement, ev: FocusEvent) => any;\n onfocusout: (this: SVGElement, ev: FocusEvent) => any;\n onload: (this: SVGElement, ev: Event) => any;\n onmousedown: (this: SVGElement, ev: MouseEvent) => any;\n onmousemove: (this: SVGElement, ev: MouseEvent) => any;\n onmouseout: (this: SVGElement, ev: MouseEvent) => any;\n onmouseover: (this: SVGElement, ev: MouseEvent) => any;\n onmouseup: (this: SVGElement, ev: MouseEvent) => any;\n readonly ownerSVGElement: SVGSVGElement;\n readonly style: CSSStyleDeclaration;\n readonly viewportElement: SVGElement;\n xmlbase: string;\n addEventListener(type: K, listener: (this: SVGElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGElement: {\n prototype: SVGElement;\n new(): SVGElement;\n};\n\ninterface SVGElementInstance extends EventTarget {\n readonly childNodes: SVGElementInstanceList;\n readonly correspondingElement: SVGElement;\n readonly correspondingUseElement: SVGUseElement;\n readonly firstChild: SVGElementInstance;\n readonly lastChild: SVGElementInstance;\n readonly nextSibling: SVGElementInstance;\n readonly parentNode: SVGElementInstance;\n readonly previousSibling: SVGElementInstance;\n}\n\ndeclare var SVGElementInstance: {\n prototype: SVGElementInstance;\n new(): SVGElementInstance;\n};\n\ninterface SVGElementInstanceList {\n readonly length: number;\n item(index: number): SVGElementInstance;\n}\n\ndeclare var SVGElementInstanceList: {\n prototype: SVGElementInstanceList;\n new(): SVGElementInstanceList;\n};\n\ninterface SVGEllipseElement extends SVGGraphicsElement {\n readonly cx: SVGAnimatedLength;\n readonly cy: SVGAnimatedLength;\n readonly rx: SVGAnimatedLength;\n readonly ry: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGEllipseElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGEllipseElement: {\n prototype: SVGEllipseElement;\n new(): SVGEllipseElement;\n};\n\ninterface SVGFEBlendElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly in2: SVGAnimatedString;\n readonly mode: SVGAnimatedEnumeration;\n readonly SVG_FEBLEND_MODE_COLOR: number;\n readonly SVG_FEBLEND_MODE_COLOR_BURN: number;\n readonly SVG_FEBLEND_MODE_COLOR_DODGE: number;\n readonly SVG_FEBLEND_MODE_DARKEN: number;\n readonly SVG_FEBLEND_MODE_DIFFERENCE: number;\n readonly SVG_FEBLEND_MODE_EXCLUSION: number;\n readonly SVG_FEBLEND_MODE_HARD_LIGHT: number;\n readonly SVG_FEBLEND_MODE_HUE: number;\n readonly SVG_FEBLEND_MODE_LIGHTEN: number;\n readonly SVG_FEBLEND_MODE_LUMINOSITY: number;\n readonly SVG_FEBLEND_MODE_MULTIPLY: number;\n readonly SVG_FEBLEND_MODE_NORMAL: number;\n readonly SVG_FEBLEND_MODE_OVERLAY: number;\n readonly SVG_FEBLEND_MODE_SATURATION: number;\n readonly SVG_FEBLEND_MODE_SCREEN: number;\n readonly SVG_FEBLEND_MODE_SOFT_LIGHT: number;\n readonly SVG_FEBLEND_MODE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEBlendElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEBlendElement: {\n prototype: SVGFEBlendElement;\n new(): SVGFEBlendElement;\n readonly SVG_FEBLEND_MODE_COLOR: number;\n readonly SVG_FEBLEND_MODE_COLOR_BURN: number;\n readonly SVG_FEBLEND_MODE_COLOR_DODGE: number;\n readonly SVG_FEBLEND_MODE_DARKEN: number;\n readonly SVG_FEBLEND_MODE_DIFFERENCE: number;\n readonly SVG_FEBLEND_MODE_EXCLUSION: number;\n readonly SVG_FEBLEND_MODE_HARD_LIGHT: number;\n readonly SVG_FEBLEND_MODE_HUE: number;\n readonly SVG_FEBLEND_MODE_LIGHTEN: number;\n readonly SVG_FEBLEND_MODE_LUMINOSITY: number;\n readonly SVG_FEBLEND_MODE_MULTIPLY: number;\n readonly SVG_FEBLEND_MODE_NORMAL: number;\n readonly SVG_FEBLEND_MODE_OVERLAY: number;\n readonly SVG_FEBLEND_MODE_SATURATION: number;\n readonly SVG_FEBLEND_MODE_SCREEN: number;\n readonly SVG_FEBLEND_MODE_SOFT_LIGHT: number;\n readonly SVG_FEBLEND_MODE_UNKNOWN: number;\n};\n\ninterface SVGFEColorMatrixElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly type: SVGAnimatedEnumeration;\n readonly values: SVGAnimatedNumberList;\n readonly SVG_FECOLORMATRIX_TYPE_HUEROTATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_LUMINANCETOALPHA: number;\n readonly SVG_FECOLORMATRIX_TYPE_MATRIX: number;\n readonly SVG_FECOLORMATRIX_TYPE_SATURATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEColorMatrixElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEColorMatrixElement: {\n prototype: SVGFEColorMatrixElement;\n new(): SVGFEColorMatrixElement;\n readonly SVG_FECOLORMATRIX_TYPE_HUEROTATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_LUMINANCETOALPHA: number;\n readonly SVG_FECOLORMATRIX_TYPE_MATRIX: number;\n readonly SVG_FECOLORMATRIX_TYPE_SATURATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_UNKNOWN: number;\n};\n\ninterface SVGFEComponentTransferElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFEComponentTransferElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEComponentTransferElement: {\n prototype: SVGFEComponentTransferElement;\n new(): SVGFEComponentTransferElement;\n};\n\ninterface SVGFECompositeElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly in2: SVGAnimatedString;\n readonly k1: SVGAnimatedNumber;\n readonly k2: SVGAnimatedNumber;\n readonly k3: SVGAnimatedNumber;\n readonly k4: SVGAnimatedNumber;\n readonly operator: SVGAnimatedEnumeration;\n readonly SVG_FECOMPOSITE_OPERATOR_ARITHMETIC: number;\n readonly SVG_FECOMPOSITE_OPERATOR_ATOP: number;\n readonly SVG_FECOMPOSITE_OPERATOR_IN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OUT: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OVER: number;\n readonly SVG_FECOMPOSITE_OPERATOR_UNKNOWN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_XOR: number;\n addEventListener(type: K, listener: (this: SVGFECompositeElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFECompositeElement: {\n prototype: SVGFECompositeElement;\n new(): SVGFECompositeElement;\n readonly SVG_FECOMPOSITE_OPERATOR_ARITHMETIC: number;\n readonly SVG_FECOMPOSITE_OPERATOR_ATOP: number;\n readonly SVG_FECOMPOSITE_OPERATOR_IN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OUT: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OVER: number;\n readonly SVG_FECOMPOSITE_OPERATOR_UNKNOWN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_XOR: number;\n};\n\ninterface SVGFEConvolveMatrixElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly bias: SVGAnimatedNumber;\n readonly divisor: SVGAnimatedNumber;\n readonly edgeMode: SVGAnimatedEnumeration;\n readonly in1: SVGAnimatedString;\n readonly kernelMatrix: SVGAnimatedNumberList;\n readonly kernelUnitLengthX: SVGAnimatedNumber;\n readonly kernelUnitLengthY: SVGAnimatedNumber;\n readonly orderX: SVGAnimatedInteger;\n readonly orderY: SVGAnimatedInteger;\n readonly preserveAlpha: SVGAnimatedBoolean;\n readonly targetX: SVGAnimatedInteger;\n readonly targetY: SVGAnimatedInteger;\n readonly SVG_EDGEMODE_DUPLICATE: number;\n readonly SVG_EDGEMODE_NONE: number;\n readonly SVG_EDGEMODE_UNKNOWN: number;\n readonly SVG_EDGEMODE_WRAP: number;\n addEventListener(type: K, listener: (this: SVGFEConvolveMatrixElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEConvolveMatrixElement: {\n prototype: SVGFEConvolveMatrixElement;\n new(): SVGFEConvolveMatrixElement;\n readonly SVG_EDGEMODE_DUPLICATE: number;\n readonly SVG_EDGEMODE_NONE: number;\n readonly SVG_EDGEMODE_UNKNOWN: number;\n readonly SVG_EDGEMODE_WRAP: number;\n};\n\ninterface SVGFEDiffuseLightingElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly diffuseConstant: SVGAnimatedNumber;\n readonly in1: SVGAnimatedString;\n readonly kernelUnitLengthX: SVGAnimatedNumber;\n readonly kernelUnitLengthY: SVGAnimatedNumber;\n readonly surfaceScale: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFEDiffuseLightingElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEDiffuseLightingElement: {\n prototype: SVGFEDiffuseLightingElement;\n new(): SVGFEDiffuseLightingElement;\n};\n\ninterface SVGFEDisplacementMapElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly in2: SVGAnimatedString;\n readonly scale: SVGAnimatedNumber;\n readonly xChannelSelector: SVGAnimatedEnumeration;\n readonly yChannelSelector: SVGAnimatedEnumeration;\n readonly SVG_CHANNEL_A: number;\n readonly SVG_CHANNEL_B: number;\n readonly SVG_CHANNEL_G: number;\n readonly SVG_CHANNEL_R: number;\n readonly SVG_CHANNEL_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEDisplacementMapElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEDisplacementMapElement: {\n prototype: SVGFEDisplacementMapElement;\n new(): SVGFEDisplacementMapElement;\n readonly SVG_CHANNEL_A: number;\n readonly SVG_CHANNEL_B: number;\n readonly SVG_CHANNEL_G: number;\n readonly SVG_CHANNEL_R: number;\n readonly SVG_CHANNEL_UNKNOWN: number;\n};\n\ninterface SVGFEDistantLightElement extends SVGElement {\n readonly azimuth: SVGAnimatedNumber;\n readonly elevation: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFEDistantLightElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEDistantLightElement: {\n prototype: SVGFEDistantLightElement;\n new(): SVGFEDistantLightElement;\n};\n\ninterface SVGFEFloodElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n addEventListener(type: K, listener: (this: SVGFEFloodElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFloodElement: {\n prototype: SVGFEFloodElement;\n new(): SVGFEFloodElement;\n};\n\ninterface SVGFEFuncAElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncAElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncAElement: {\n prototype: SVGFEFuncAElement;\n new(): SVGFEFuncAElement;\n};\n\ninterface SVGFEFuncBElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncBElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncBElement: {\n prototype: SVGFEFuncBElement;\n new(): SVGFEFuncBElement;\n};\n\ninterface SVGFEFuncGElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncGElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncGElement: {\n prototype: SVGFEFuncGElement;\n new(): SVGFEFuncGElement;\n};\n\ninterface SVGFEFuncRElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncRElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncRElement: {\n prototype: SVGFEFuncRElement;\n new(): SVGFEFuncRElement;\n};\n\ninterface SVGFEGaussianBlurElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly stdDeviationX: SVGAnimatedNumber;\n readonly stdDeviationY: SVGAnimatedNumber;\n setStdDeviation(stdDeviationX: number, stdDeviationY: number): void;\n addEventListener(type: K, listener: (this: SVGFEGaussianBlurElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEGaussianBlurElement: {\n prototype: SVGFEGaussianBlurElement;\n new(): SVGFEGaussianBlurElement;\n};\n\ninterface SVGFEImageElement extends SVGElement, SVGFilterPrimitiveStandardAttributes, SVGURIReference {\n readonly preserveAspectRatio: SVGAnimatedPreserveAspectRatio;\n addEventListener(type: K, listener: (this: SVGFEImageElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEImageElement: {\n prototype: SVGFEImageElement;\n new(): SVGFEImageElement;\n};\n\ninterface SVGFEMergeElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n addEventListener(type: K, listener: (this: SVGFEMergeElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEMergeElement: {\n prototype: SVGFEMergeElement;\n new(): SVGFEMergeElement;\n};\n\ninterface SVGFEMergeNodeElement extends SVGElement {\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFEMergeNodeElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEMergeNodeElement: {\n prototype: SVGFEMergeNodeElement;\n new(): SVGFEMergeNodeElement;\n};\n\ninterface SVGFEMorphologyElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly operator: SVGAnimatedEnumeration;\n readonly radiusX: SVGAnimatedNumber;\n readonly radiusY: SVGAnimatedNumber;\n readonly SVG_MORPHOLOGY_OPERATOR_DILATE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_ERODE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEMorphologyElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEMorphologyElement: {\n prototype: SVGFEMorphologyElement;\n new(): SVGFEMorphologyElement;\n readonly SVG_MORPHOLOGY_OPERATOR_DILATE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_ERODE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_UNKNOWN: number;\n};\n\ninterface SVGFEOffsetElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly dx: SVGAnimatedNumber;\n readonly dy: SVGAnimatedNumber;\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFEOffsetElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEOffsetElement: {\n prototype: SVGFEOffsetElement;\n new(): SVGFEOffsetElement;\n};\n\ninterface SVGFEPointLightElement extends SVGElement {\n readonly x: SVGAnimatedNumber;\n readonly y: SVGAnimatedNumber;\n readonly z: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFEPointLightElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEPointLightElement: {\n prototype: SVGFEPointLightElement;\n new(): SVGFEPointLightElement;\n};\n\ninterface SVGFESpecularLightingElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly kernelUnitLengthX: SVGAnimatedNumber;\n readonly kernelUnitLengthY: SVGAnimatedNumber;\n readonly specularConstant: SVGAnimatedNumber;\n readonly specularExponent: SVGAnimatedNumber;\n readonly surfaceScale: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFESpecularLightingElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFESpecularLightingElement: {\n prototype: SVGFESpecularLightingElement;\n new(): SVGFESpecularLightingElement;\n};\n\ninterface SVGFESpotLightElement extends SVGElement {\n readonly limitingConeAngle: SVGAnimatedNumber;\n readonly pointsAtX: SVGAnimatedNumber;\n readonly pointsAtY: SVGAnimatedNumber;\n readonly pointsAtZ: SVGAnimatedNumber;\n readonly specularExponent: SVGAnimatedNumber;\n readonly x: SVGAnimatedNumber;\n readonly y: SVGAnimatedNumber;\n readonly z: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFESpotLightElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFESpotLightElement: {\n prototype: SVGFESpotLightElement;\n new(): SVGFESpotLightElement;\n};\n\ninterface SVGFETileElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFETileElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFETileElement: {\n prototype: SVGFETileElement;\n new(): SVGFETileElement;\n};\n\ninterface SVGFETurbulenceElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly baseFrequencyX: SVGAnimatedNumber;\n readonly baseFrequencyY: SVGAnimatedNumber;\n readonly numOctaves: SVGAnimatedInteger;\n readonly seed: SVGAnimatedNumber;\n readonly stitchTiles: SVGAnimatedEnumeration;\n readonly type: SVGAnimatedEnumeration;\n readonly SVG_STITCHTYPE_NOSTITCH: number;\n readonly SVG_STITCHTYPE_STITCH: number;\n readonly SVG_STITCHTYPE_UNKNOWN: number;\n readonly SVG_TURBULENCE_TYPE_FRACTALNOISE: number;\n readonly SVG_TURBULENCE_TYPE_TURBULENCE: number;\n readonly SVG_TURBULENCE_TYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFETurbulenceElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFETurbulenceElement: {\n prototype: SVGFETurbulenceElement;\n new(): SVGFETurbulenceElement;\n readonly SVG_STITCHTYPE_NOSTITCH: number;\n readonly SVG_STITCHTYPE_STITCH: number;\n readonly SVG_STITCHTYPE_UNKNOWN: number;\n readonly SVG_TURBULENCE_TYPE_FRACTALNOISE: number;\n readonly SVG_TURBULENCE_TYPE_TURBULENCE: number;\n readonly SVG_TURBULENCE_TYPE_UNKNOWN: number;\n};\n\ninterface SVGFilterElement extends SVGElement, SVGUnitTypes, SVGURIReference {\n readonly filterResX: SVGAnimatedInteger;\n readonly filterResY: SVGAnimatedInteger;\n readonly filterUnits: SVGAnimatedEnumeration;\n readonly height: SVGAnimatedLength;\n readonly primitiveUnits: SVGAnimatedEnumeration;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n setFilterRes(filterResX: number, filterResY: number): void;\n addEventListener(type: K, listener: (this: SVGFilterElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFilterElement: {\n prototype: SVGFilterElement;\n new(): SVGFilterElement;\n};\n\ninterface SVGForeignObjectElement extends SVGGraphicsElement {\n readonly height: SVGAnimatedLength;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGForeignObjectElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGForeignObjectElement: {\n prototype: SVGForeignObjectElement;\n new(): SVGForeignObjectElement;\n};\n\ninterface SVGGElement extends SVGGraphicsElement {\n addEventListener(type: K, listener: (this: SVGGElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGGElement: {\n prototype: SVGGElement;\n new(): SVGGElement;\n};\n\ninterface SVGGradientElement extends SVGElement, SVGUnitTypes, SVGURIReference {\n readonly gradientTransform: SVGAnimatedTransformList;\n readonly gradientUnits: SVGAnimatedEnumeration;\n readonly spreadMethod: SVGAnimatedEnumeration;\n readonly SVG_SPREADMETHOD_PAD: number;\n readonly SVG_SPREADMETHOD_REFLECT: number;\n readonly SVG_SPREADMETHOD_REPEAT: number;\n readonly SVG_SPREADMETHOD_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGGradientElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGGradientElement: {\n prototype: SVGGradientElement;\n new(): SVGGradientElement;\n readonly SVG_SPREADMETHOD_PAD: number;\n readonly SVG_SPREADMETHOD_REFLECT: number;\n readonly SVG_SPREADMETHOD_REPEAT: number;\n readonly SVG_SPREADMETHOD_UNKNOWN: number;\n};\n\ninterface SVGGraphicsElement extends SVGElement, SVGTests {\n readonly farthestViewportElement: SVGElement;\n readonly nearestViewportElement: SVGElement;\n readonly transform: SVGAnimatedTransformList;\n getBBox(): SVGRect;\n getCTM(): SVGMatrix;\n getScreenCTM(): SVGMatrix;\n getTransformToElement(element: SVGElement): SVGMatrix;\n addEventListener(type: K, listener: (this: SVGGraphicsElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGGraphicsElement: {\n prototype: SVGGraphicsElement;\n new(): SVGGraphicsElement;\n};\n\ninterface SVGImageElement extends SVGGraphicsElement, SVGURIReference {\n readonly height: SVGAnimatedLength;\n readonly preserveAspectRatio: SVGAnimatedPreserveAspectRatio;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGImageElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGImageElement: {\n prototype: SVGImageElement;\n new(): SVGImageElement;\n};\n\ninterface SVGLength {\n readonly unitType: number;\n value: number;\n valueAsString: string;\n valueInSpecifiedUnits: number;\n convertToSpecifiedUnits(unitType: number): void;\n newValueSpecifiedUnits(unitType: number, valueInSpecifiedUnits: number): void;\n readonly SVG_LENGTHTYPE_CM: number;\n readonly SVG_LENGTHTYPE_EMS: number;\n readonly SVG_LENGTHTYPE_EXS: number;\n readonly SVG_LENGTHTYPE_IN: number;\n readonly SVG_LENGTHTYPE_MM: number;\n readonly SVG_LENGTHTYPE_NUMBER: number;\n readonly SVG_LENGTHTYPE_PC: number;\n readonly SVG_LENGTHTYPE_PERCENTAGE: number;\n readonly SVG_LENGTHTYPE_PT: number;\n readonly SVG_LENGTHTYPE_PX: number;\n readonly SVG_LENGTHTYPE_UNKNOWN: number;\n}\n\ndeclare var SVGLength: {\n prototype: SVGLength;\n new(): SVGLength;\n readonly SVG_LENGTHTYPE_CM: number;\n readonly SVG_LENGTHTYPE_EMS: number;\n readonly SVG_LENGTHTYPE_EXS: number;\n readonly SVG_LENGTHTYPE_IN: number;\n readonly SVG_LENGTHTYPE_MM: number;\n readonly SVG_LENGTHTYPE_NUMBER: number;\n readonly SVG_LENGTHTYPE_PC: number;\n readonly SVG_LENGTHTYPE_PERCENTAGE: number;\n readonly SVG_LENGTHTYPE_PT: number;\n readonly SVG_LENGTHTYPE_PX: number;\n readonly SVG_LENGTHTYPE_UNKNOWN: number;\n};\n\ninterface SVGLengthList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGLength): SVGLength;\n clear(): void;\n getItem(index: number): SVGLength;\n initialize(newItem: SVGLength): SVGLength;\n insertItemBefore(newItem: SVGLength, index: number): SVGLength;\n removeItem(index: number): SVGLength;\n replaceItem(newItem: SVGLength, index: number): SVGLength;\n}\n\ndeclare var SVGLengthList: {\n prototype: SVGLengthList;\n new(): SVGLengthList;\n};\n\ninterface SVGLinearGradientElement extends SVGGradientElement {\n readonly x1: SVGAnimatedLength;\n readonly x2: SVGAnimatedLength;\n readonly y1: SVGAnimatedLength;\n readonly y2: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGLinearGradientElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGLinearGradientElement: {\n prototype: SVGLinearGradientElement;\n new(): SVGLinearGradientElement;\n};\n\ninterface SVGLineElement extends SVGGraphicsElement {\n readonly x1: SVGAnimatedLength;\n readonly x2: SVGAnimatedLength;\n readonly y1: SVGAnimatedLength;\n readonly y2: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGLineElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGLineElement: {\n prototype: SVGLineElement;\n new(): SVGLineElement;\n};\n\ninterface SVGMarkerElement extends SVGElement, SVGFitToViewBox {\n readonly markerHeight: SVGAnimatedLength;\n readonly markerUnits: SVGAnimatedEnumeration;\n readonly markerWidth: SVGAnimatedLength;\n readonly orientAngle: SVGAnimatedAngle;\n readonly orientType: SVGAnimatedEnumeration;\n readonly refX: SVGAnimatedLength;\n readonly refY: SVGAnimatedLength;\n setOrientToAngle(angle: SVGAngle): void;\n setOrientToAuto(): void;\n readonly SVG_MARKER_ORIENT_ANGLE: number;\n readonly SVG_MARKER_ORIENT_AUTO: number;\n readonly SVG_MARKER_ORIENT_UNKNOWN: number;\n readonly SVG_MARKERUNITS_STROKEWIDTH: number;\n readonly SVG_MARKERUNITS_UNKNOWN: number;\n readonly SVG_MARKERUNITS_USERSPACEONUSE: number;\n addEventListener(type: K, listener: (this: SVGMarkerElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGMarkerElement: {\n prototype: SVGMarkerElement;\n new(): SVGMarkerElement;\n readonly SVG_MARKER_ORIENT_ANGLE: number;\n readonly SVG_MARKER_ORIENT_AUTO: number;\n readonly SVG_MARKER_ORIENT_UNKNOWN: number;\n readonly SVG_MARKERUNITS_STROKEWIDTH: number;\n readonly SVG_MARKERUNITS_UNKNOWN: number;\n readonly SVG_MARKERUNITS_USERSPACEONUSE: number;\n};\n\ninterface SVGMaskElement extends SVGElement, SVGTests, SVGUnitTypes {\n readonly height: SVGAnimatedLength;\n readonly maskContentUnits: SVGAnimatedEnumeration;\n readonly maskUnits: SVGAnimatedEnumeration;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGMaskElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGMaskElement: {\n prototype: SVGMaskElement;\n new(): SVGMaskElement;\n};\n\ninterface SVGMatrix {\n a: number;\n b: number;\n c: number;\n d: number;\n e: number;\n f: number;\n flipX(): SVGMatrix;\n flipY(): SVGMatrix;\n inverse(): SVGMatrix;\n multiply(secondMatrix: SVGMatrix): SVGMatrix;\n rotate(angle: number): SVGMatrix;\n rotateFromVector(x: number, y: number): SVGMatrix;\n scale(scaleFactor: number): SVGMatrix;\n scaleNonUniform(scaleFactorX: number, scaleFactorY: number): SVGMatrix;\n skewX(angle: number): SVGMatrix;\n skewY(angle: number): SVGMatrix;\n translate(x: number, y: number): SVGMatrix;\n}\n\ndeclare var SVGMatrix: {\n prototype: SVGMatrix;\n new(): SVGMatrix;\n};\n\ninterface SVGMetadataElement extends SVGElement {\n addEventListener(type: K, listener: (this: SVGMetadataElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGMetadataElement: {\n prototype: SVGMetadataElement;\n new(): SVGMetadataElement;\n};\n\ninterface SVGNumber {\n value: number;\n}\n\ndeclare var SVGNumber: {\n prototype: SVGNumber;\n new(): SVGNumber;\n};\n\ninterface SVGNumberList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGNumber): SVGNumber;\n clear(): void;\n getItem(index: number): SVGNumber;\n initialize(newItem: SVGNumber): SVGNumber;\n insertItemBefore(newItem: SVGNumber, index: number): SVGNumber;\n removeItem(index: number): SVGNumber;\n replaceItem(newItem: SVGNumber, index: number): SVGNumber;\n}\n\ndeclare var SVGNumberList: {\n prototype: SVGNumberList;\n new(): SVGNumberList;\n};\n\ninterface SVGPathElement extends SVGGraphicsElement {\n readonly pathSegList: SVGPathSegList;\n createSVGPathSegArcAbs(x: number, y: number, r1: number, r2: number, angle: number, largeArcFlag: boolean, sweepFlag: boolean): SVGPathSegArcAbs;\n createSVGPathSegArcRel(x: number, y: number, r1: number, r2: number, angle: number, largeArcFlag: boolean, sweepFlag: boolean): SVGPathSegArcRel;\n createSVGPathSegClosePath(): SVGPathSegClosePath;\n createSVGPathSegCurvetoCubicAbs(x: number, y: number, x1: number, y1: number, x2: number, y2: number): SVGPathSegCurvetoCubicAbs;\n createSVGPathSegCurvetoCubicRel(x: number, y: number, x1: number, y1: number, x2: number, y2: number): SVGPathSegCurvetoCubicRel;\n createSVGPathSegCurvetoCubicSmoothAbs(x: number, y: number, x2: number, y2: number): SVGPathSegCurvetoCubicSmoothAbs;\n createSVGPathSegCurvetoCubicSmoothRel(x: number, y: number, x2: number, y2: number): SVGPathSegCurvetoCubicSmoothRel;\n createSVGPathSegCurvetoQuadraticAbs(x: number, y: number, x1: number, y1: number): SVGPathSegCurvetoQuadraticAbs;\n createSVGPathSegCurvetoQuadraticRel(x: number, y: number, x1: number, y1: number): SVGPathSegCurvetoQuadraticRel;\n createSVGPathSegCurvetoQuadraticSmoothAbs(x: number, y: number): SVGPathSegCurvetoQuadraticSmoothAbs;\n createSVGPathSegCurvetoQuadraticSmoothRel(x: number, y: number): SVGPathSegCurvetoQuadraticSmoothRel;\n createSVGPathSegLinetoAbs(x: number, y: number): SVGPathSegLinetoAbs;\n createSVGPathSegLinetoHorizontalAbs(x: number): SVGPathSegLinetoHorizontalAbs;\n createSVGPathSegLinetoHorizontalRel(x: number): SVGPathSegLinetoHorizontalRel;\n createSVGPathSegLinetoRel(x: number, y: number): SVGPathSegLinetoRel;\n createSVGPathSegLinetoVerticalAbs(y: number): SVGPathSegLinetoVerticalAbs;\n createSVGPathSegLinetoVerticalRel(y: number): SVGPathSegLinetoVerticalRel;\n createSVGPathSegMovetoAbs(x: number, y: number): SVGPathSegMovetoAbs;\n createSVGPathSegMovetoRel(x: number, y: number): SVGPathSegMovetoRel;\n getPathSegAtLength(distance: number): number;\n getPointAtLength(distance: number): SVGPoint;\n getTotalLength(): number;\n addEventListener(type: K, listener: (this: SVGPathElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPathElement: {\n prototype: SVGPathElement;\n new(): SVGPathElement;\n};\n\ninterface SVGPathSeg {\n readonly pathSegType: number;\n readonly pathSegTypeAsLetter: string;\n readonly PATHSEG_ARC_ABS: number;\n readonly PATHSEG_ARC_REL: number;\n readonly PATHSEG_CLOSEPATH: number;\n readonly PATHSEG_CURVETO_CUBIC_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_REL: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL: number;\n readonly PATHSEG_LINETO_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_REL: number;\n readonly PATHSEG_LINETO_REL: number;\n readonly PATHSEG_LINETO_VERTICAL_ABS: number;\n readonly PATHSEG_LINETO_VERTICAL_REL: number;\n readonly PATHSEG_MOVETO_ABS: number;\n readonly PATHSEG_MOVETO_REL: number;\n readonly PATHSEG_UNKNOWN: number;\n}\n\ndeclare var SVGPathSeg: {\n prototype: SVGPathSeg;\n new(): SVGPathSeg;\n readonly PATHSEG_ARC_ABS: number;\n readonly PATHSEG_ARC_REL: number;\n readonly PATHSEG_CLOSEPATH: number;\n readonly PATHSEG_CURVETO_CUBIC_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_REL: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL: number;\n readonly PATHSEG_LINETO_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_REL: number;\n readonly PATHSEG_LINETO_REL: number;\n readonly PATHSEG_LINETO_VERTICAL_ABS: number;\n readonly PATHSEG_LINETO_VERTICAL_REL: number;\n readonly PATHSEG_MOVETO_ABS: number;\n readonly PATHSEG_MOVETO_REL: number;\n readonly PATHSEG_UNKNOWN: number;\n};\n\ninterface SVGPathSegArcAbs extends SVGPathSeg {\n angle: number;\n largeArcFlag: boolean;\n r1: number;\n r2: number;\n sweepFlag: boolean;\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegArcAbs: {\n prototype: SVGPathSegArcAbs;\n new(): SVGPathSegArcAbs;\n};\n\ninterface SVGPathSegArcRel extends SVGPathSeg {\n angle: number;\n largeArcFlag: boolean;\n r1: number;\n r2: number;\n sweepFlag: boolean;\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegArcRel: {\n prototype: SVGPathSegArcRel;\n new(): SVGPathSegArcRel;\n};\n\ninterface SVGPathSegClosePath extends SVGPathSeg {\n}\n\ndeclare var SVGPathSegClosePath: {\n prototype: SVGPathSegClosePath;\n new(): SVGPathSegClosePath;\n};\n\ninterface SVGPathSegCurvetoCubicAbs extends SVGPathSeg {\n x: number;\n x1: number;\n x2: number;\n y: number;\n y1: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicAbs: {\n prototype: SVGPathSegCurvetoCubicAbs;\n new(): SVGPathSegCurvetoCubicAbs;\n};\n\ninterface SVGPathSegCurvetoCubicRel extends SVGPathSeg {\n x: number;\n x1: number;\n x2: number;\n y: number;\n y1: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicRel: {\n prototype: SVGPathSegCurvetoCubicRel;\n new(): SVGPathSegCurvetoCubicRel;\n};\n\ninterface SVGPathSegCurvetoCubicSmoothAbs extends SVGPathSeg {\n x: number;\n x2: number;\n y: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicSmoothAbs: {\n prototype: SVGPathSegCurvetoCubicSmoothAbs;\n new(): SVGPathSegCurvetoCubicSmoothAbs;\n};\n\ninterface SVGPathSegCurvetoCubicSmoothRel extends SVGPathSeg {\n x: number;\n x2: number;\n y: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicSmoothRel: {\n prototype: SVGPathSegCurvetoCubicSmoothRel;\n new(): SVGPathSegCurvetoCubicSmoothRel;\n};\n\ninterface SVGPathSegCurvetoQuadraticAbs extends SVGPathSeg {\n x: number;\n x1: number;\n y: number;\n y1: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticAbs: {\n prototype: SVGPathSegCurvetoQuadraticAbs;\n new(): SVGPathSegCurvetoQuadraticAbs;\n};\n\ninterface SVGPathSegCurvetoQuadraticRel extends SVGPathSeg {\n x: number;\n x1: number;\n y: number;\n y1: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticRel: {\n prototype: SVGPathSegCurvetoQuadraticRel;\n new(): SVGPathSegCurvetoQuadraticRel;\n};\n\ninterface SVGPathSegCurvetoQuadraticSmoothAbs extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticSmoothAbs: {\n prototype: SVGPathSegCurvetoQuadraticSmoothAbs;\n new(): SVGPathSegCurvetoQuadraticSmoothAbs;\n};\n\ninterface SVGPathSegCurvetoQuadraticSmoothRel extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticSmoothRel: {\n prototype: SVGPathSegCurvetoQuadraticSmoothRel;\n new(): SVGPathSegCurvetoQuadraticSmoothRel;\n};\n\ninterface SVGPathSegLinetoAbs extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegLinetoAbs: {\n prototype: SVGPathSegLinetoAbs;\n new(): SVGPathSegLinetoAbs;\n};\n\ninterface SVGPathSegLinetoHorizontalAbs extends SVGPathSeg {\n x: number;\n}\n\ndeclare var SVGPathSegLinetoHorizontalAbs: {\n prototype: SVGPathSegLinetoHorizontalAbs;\n new(): SVGPathSegLinetoHorizontalAbs;\n};\n\ninterface SVGPathSegLinetoHorizontalRel extends SVGPathSeg {\n x: number;\n}\n\ndeclare var SVGPathSegLinetoHorizontalRel: {\n prototype: SVGPathSegLinetoHorizontalRel;\n new(): SVGPathSegLinetoHorizontalRel;\n};\n\ninterface SVGPathSegLinetoRel extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegLinetoRel: {\n prototype: SVGPathSegLinetoRel;\n new(): SVGPathSegLinetoRel;\n};\n\ninterface SVGPathSegLinetoVerticalAbs extends SVGPathSeg {\n y: number;\n}\n\ndeclare var SVGPathSegLinetoVerticalAbs: {\n prototype: SVGPathSegLinetoVerticalAbs;\n new(): SVGPathSegLinetoVerticalAbs;\n};\n\ninterface SVGPathSegLinetoVerticalRel extends SVGPathSeg {\n y: number;\n}\n\ndeclare var SVGPathSegLinetoVerticalRel: {\n prototype: SVGPathSegLinetoVerticalRel;\n new(): SVGPathSegLinetoVerticalRel;\n};\n\ninterface SVGPathSegList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGPathSeg): SVGPathSeg;\n clear(): void;\n getItem(index: number): SVGPathSeg;\n initialize(newItem: SVGPathSeg): SVGPathSeg;\n insertItemBefore(newItem: SVGPathSeg, index: number): SVGPathSeg;\n removeItem(index: number): SVGPathSeg;\n replaceItem(newItem: SVGPathSeg, index: number): SVGPathSeg;\n}\n\ndeclare var SVGPathSegList: {\n prototype: SVGPathSegList;\n new(): SVGPathSegList;\n};\n\ninterface SVGPathSegMovetoAbs extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegMovetoAbs: {\n prototype: SVGPathSegMovetoAbs;\n new(): SVGPathSegMovetoAbs;\n};\n\ninterface SVGPathSegMovetoRel extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegMovetoRel: {\n prototype: SVGPathSegMovetoRel;\n new(): SVGPathSegMovetoRel;\n};\n\ninterface SVGPatternElement extends SVGElement, SVGTests, SVGUnitTypes, SVGFitToViewBox, SVGURIReference {\n readonly height: SVGAnimatedLength;\n readonly patternContentUnits: SVGAnimatedEnumeration;\n readonly patternTransform: SVGAnimatedTransformList;\n readonly patternUnits: SVGAnimatedEnumeration;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGPatternElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPatternElement: {\n prototype: SVGPatternElement;\n new(): SVGPatternElement;\n};\n\ninterface SVGPoint {\n x: number;\n y: number;\n matrixTransform(matrix: SVGMatrix): SVGPoint;\n}\n\ndeclare var SVGPoint: {\n prototype: SVGPoint;\n new(): SVGPoint;\n};\n\ninterface SVGPointList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGPoint): SVGPoint;\n clear(): void;\n getItem(index: number): SVGPoint;\n initialize(newItem: SVGPoint): SVGPoint;\n insertItemBefore(newItem: SVGPoint, index: number): SVGPoint;\n removeItem(index: number): SVGPoint;\n replaceItem(newItem: SVGPoint, index: number): SVGPoint;\n}\n\ndeclare var SVGPointList: {\n prototype: SVGPointList;\n new(): SVGPointList;\n};\n\ninterface SVGPolygonElement extends SVGGraphicsElement, SVGAnimatedPoints {\n addEventListener(type: K, listener: (this: SVGPolygonElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPolygonElement: {\n prototype: SVGPolygonElement;\n new(): SVGPolygonElement;\n};\n\ninterface SVGPolylineElement extends SVGGraphicsElement, SVGAnimatedPoints {\n addEventListener(type: K, listener: (this: SVGPolylineElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPolylineElement: {\n prototype: SVGPolylineElement;\n new(): SVGPolylineElement;\n};\n\ninterface SVGPreserveAspectRatio {\n align: number;\n meetOrSlice: number;\n readonly SVG_MEETORSLICE_MEET: number;\n readonly SVG_MEETORSLICE_SLICE: number;\n readonly SVG_MEETORSLICE_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_NONE: number;\n readonly SVG_PRESERVEASPECTRATIO_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMIN: number;\n}\n\ndeclare var SVGPreserveAspectRatio: {\n prototype: SVGPreserveAspectRatio;\n new(): SVGPreserveAspectRatio;\n readonly SVG_MEETORSLICE_MEET: number;\n readonly SVG_MEETORSLICE_SLICE: number;\n readonly SVG_MEETORSLICE_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_NONE: number;\n readonly SVG_PRESERVEASPECTRATIO_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMIN: number;\n};\n\ninterface SVGRadialGradientElement extends SVGGradientElement {\n readonly cx: SVGAnimatedLength;\n readonly cy: SVGAnimatedLength;\n readonly fx: SVGAnimatedLength;\n readonly fy: SVGAnimatedLength;\n readonly r: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGRadialGradientElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGRadialGradientElement: {\n prototype: SVGRadialGradientElement;\n new(): SVGRadialGradientElement;\n};\n\ninterface SVGRect {\n height: number;\n width: number;\n x: number;\n y: number;\n}\n\ndeclare var SVGRect: {\n prototype: SVGRect;\n new(): SVGRect;\n};\n\ninterface SVGRectElement extends SVGGraphicsElement {\n readonly height: SVGAnimatedLength;\n readonly rx: SVGAnimatedLength;\n readonly ry: SVGAnimatedLength;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGRectElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGRectElement: {\n prototype: SVGRectElement;\n new(): SVGRectElement;\n};\n\ninterface SVGScriptElement extends SVGElement, SVGURIReference {\n type: string;\n addEventListener(type: K, listener: (this: SVGScriptElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGScriptElement: {\n prototype: SVGScriptElement;\n new(): SVGScriptElement;\n};\n\ninterface SVGStopElement extends SVGElement {\n readonly offset: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGStopElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGStopElement: {\n prototype: SVGStopElement;\n new(): SVGStopElement;\n};\n\ninterface SVGStringList {\n readonly numberOfItems: number;\n appendItem(newItem: string): string;\n clear(): void;\n getItem(index: number): string;\n initialize(newItem: string): string;\n insertItemBefore(newItem: string, index: number): string;\n removeItem(index: number): string;\n replaceItem(newItem: string, index: number): string;\n}\n\ndeclare var SVGStringList: {\n prototype: SVGStringList;\n new(): SVGStringList;\n};\n\ninterface SVGStyleElement extends SVGElement {\n disabled: boolean;\n media: string;\n title: string;\n type: string;\n addEventListener(type: K, listener: (this: SVGStyleElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGStyleElement: {\n prototype: SVGStyleElement;\n new(): SVGStyleElement;\n};\n\ninterface SVGSVGElementEventMap extends SVGElementEventMap {\n \"SVGAbort\": Event;\n \"SVGError\": Event;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"SVGUnload\": Event;\n \"SVGZoom\": SVGZoomEvent;\n}\n\ninterface SVGSVGElement extends SVGGraphicsElement, DocumentEvent, SVGFitToViewBox, SVGZoomAndPan {\n contentScriptType: string;\n contentStyleType: string;\n currentScale: number;\n readonly currentTranslate: SVGPoint;\n readonly height: SVGAnimatedLength;\n onabort: (this: SVGSVGElement, ev: Event) => any;\n onerror: (this: SVGSVGElement, ev: Event) => any;\n onresize: (this: SVGSVGElement, ev: UIEvent) => any;\n onscroll: (this: SVGSVGElement, ev: UIEvent) => any;\n onunload: (this: SVGSVGElement, ev: Event) => any;\n onzoom: (this: SVGSVGElement, ev: SVGZoomEvent) => any;\n readonly pixelUnitToMillimeterX: number;\n readonly pixelUnitToMillimeterY: number;\n readonly screenPixelToMillimeterX: number;\n readonly screenPixelToMillimeterY: number;\n readonly viewport: SVGRect;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n checkEnclosure(element: SVGElement, rect: SVGRect): boolean;\n checkIntersection(element: SVGElement, rect: SVGRect): boolean;\n createSVGAngle(): SVGAngle;\n createSVGLength(): SVGLength;\n createSVGMatrix(): SVGMatrix;\n createSVGNumber(): SVGNumber;\n createSVGPoint(): SVGPoint;\n createSVGRect(): SVGRect;\n createSVGTransform(): SVGTransform;\n createSVGTransformFromMatrix(matrix: SVGMatrix): SVGTransform;\n deselectAll(): void;\n forceRedraw(): void;\n getComputedStyle(elt: Element, pseudoElt?: string): CSSStyleDeclaration;\n getCurrentTime(): number;\n getElementById(elementId: string): Element;\n getEnclosureList(rect: SVGRect, referenceElement: SVGElement): NodeListOf;\n getIntersectionList(rect: SVGRect, referenceElement: SVGElement): NodeListOf;\n pauseAnimations(): void;\n setCurrentTime(seconds: number): void;\n suspendRedraw(maxWaitMilliseconds: number): number;\n unpauseAnimations(): void;\n unsuspendRedraw(suspendHandleID: number): void;\n unsuspendRedrawAll(): void;\n addEventListener(type: K, listener: (this: SVGSVGElement, ev: SVGSVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGSVGElement: {\n prototype: SVGSVGElement;\n new(): SVGSVGElement;\n};\n\ninterface SVGSwitchElement extends SVGGraphicsElement {\n addEventListener(type: K, listener: (this: SVGSwitchElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGSwitchElement: {\n prototype: SVGSwitchElement;\n new(): SVGSwitchElement;\n};\n\ninterface SVGSymbolElement extends SVGElement, SVGFitToViewBox {\n addEventListener(type: K, listener: (this: SVGSymbolElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGSymbolElement: {\n prototype: SVGSymbolElement;\n new(): SVGSymbolElement;\n};\n\ninterface SVGTextContentElement extends SVGGraphicsElement {\n readonly lengthAdjust: SVGAnimatedEnumeration;\n readonly textLength: SVGAnimatedLength;\n getCharNumAtPosition(point: SVGPoint): number;\n getComputedTextLength(): number;\n getEndPositionOfChar(charnum: number): SVGPoint;\n getExtentOfChar(charnum: number): SVGRect;\n getNumberOfChars(): number;\n getRotationOfChar(charnum: number): number;\n getStartPositionOfChar(charnum: number): SVGPoint;\n getSubStringLength(charnum: number, nchars: number): number;\n selectSubString(charnum: number, nchars: number): void;\n readonly LENGTHADJUST_SPACING: number;\n readonly LENGTHADJUST_SPACINGANDGLYPHS: number;\n readonly LENGTHADJUST_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGTextContentElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextContentElement: {\n prototype: SVGTextContentElement;\n new(): SVGTextContentElement;\n readonly LENGTHADJUST_SPACING: number;\n readonly LENGTHADJUST_SPACINGANDGLYPHS: number;\n readonly LENGTHADJUST_UNKNOWN: number;\n};\n\ninterface SVGTextElement extends SVGTextPositioningElement {\n addEventListener(type: K, listener: (this: SVGTextElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextElement: {\n prototype: SVGTextElement;\n new(): SVGTextElement;\n};\n\ninterface SVGTextPathElement extends SVGTextContentElement, SVGURIReference {\n readonly method: SVGAnimatedEnumeration;\n readonly spacing: SVGAnimatedEnumeration;\n readonly startOffset: SVGAnimatedLength;\n readonly TEXTPATH_METHODTYPE_ALIGN: number;\n readonly TEXTPATH_METHODTYPE_STRETCH: number;\n readonly TEXTPATH_METHODTYPE_UNKNOWN: number;\n readonly TEXTPATH_SPACINGTYPE_AUTO: number;\n readonly TEXTPATH_SPACINGTYPE_EXACT: number;\n readonly TEXTPATH_SPACINGTYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGTextPathElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextPathElement: {\n prototype: SVGTextPathElement;\n new(): SVGTextPathElement;\n readonly TEXTPATH_METHODTYPE_ALIGN: number;\n readonly TEXTPATH_METHODTYPE_STRETCH: number;\n readonly TEXTPATH_METHODTYPE_UNKNOWN: number;\n readonly TEXTPATH_SPACINGTYPE_AUTO: number;\n readonly TEXTPATH_SPACINGTYPE_EXACT: number;\n readonly TEXTPATH_SPACINGTYPE_UNKNOWN: number;\n};\n\ninterface SVGTextPositioningElement extends SVGTextContentElement {\n readonly dx: SVGAnimatedLengthList;\n readonly dy: SVGAnimatedLengthList;\n readonly rotate: SVGAnimatedNumberList;\n readonly x: SVGAnimatedLengthList;\n readonly y: SVGAnimatedLengthList;\n addEventListener(type: K, listener: (this: SVGTextPositioningElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextPositioningElement: {\n prototype: SVGTextPositioningElement;\n new(): SVGTextPositioningElement;\n};\n\ninterface SVGTitleElement extends SVGElement {\n addEventListener(type: K, listener: (this: SVGTitleElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTitleElement: {\n prototype: SVGTitleElement;\n new(): SVGTitleElement;\n};\n\ninterface SVGTransform {\n readonly angle: number;\n readonly matrix: SVGMatrix;\n readonly type: number;\n setMatrix(matrix: SVGMatrix): void;\n setRotate(angle: number, cx: number, cy: number): void;\n setScale(sx: number, sy: number): void;\n setSkewX(angle: number): void;\n setSkewY(angle: number): void;\n setTranslate(tx: number, ty: number): void;\n readonly SVG_TRANSFORM_MATRIX: number;\n readonly SVG_TRANSFORM_ROTATE: number;\n readonly SVG_TRANSFORM_SCALE: number;\n readonly SVG_TRANSFORM_SKEWX: number;\n readonly SVG_TRANSFORM_SKEWY: number;\n readonly SVG_TRANSFORM_TRANSLATE: number;\n readonly SVG_TRANSFORM_UNKNOWN: number;\n}\n\ndeclare var SVGTransform: {\n prototype: SVGTransform;\n new(): SVGTransform;\n readonly SVG_TRANSFORM_MATRIX: number;\n readonly SVG_TRANSFORM_ROTATE: number;\n readonly SVG_TRANSFORM_SCALE: number;\n readonly SVG_TRANSFORM_SKEWX: number;\n readonly SVG_TRANSFORM_SKEWY: number;\n readonly SVG_TRANSFORM_TRANSLATE: number;\n readonly SVG_TRANSFORM_UNKNOWN: number;\n};\n\ninterface SVGTransformList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGTransform): SVGTransform;\n clear(): void;\n consolidate(): SVGTransform;\n createSVGTransformFromMatrix(matrix: SVGMatrix): SVGTransform;\n getItem(index: number): SVGTransform;\n initialize(newItem: SVGTransform): SVGTransform;\n insertItemBefore(newItem: SVGTransform, index: number): SVGTransform;\n removeItem(index: number): SVGTransform;\n replaceItem(newItem: SVGTransform, index: number): SVGTransform;\n}\n\ndeclare var SVGTransformList: {\n prototype: SVGTransformList;\n new(): SVGTransformList;\n};\n\ninterface SVGTSpanElement extends SVGTextPositioningElement {\n addEventListener(type: K, listener: (this: SVGTSpanElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTSpanElement: {\n prototype: SVGTSpanElement;\n new(): SVGTSpanElement;\n};\n\ninterface SVGUnitTypes {\n readonly SVG_UNIT_TYPE_OBJECTBOUNDINGBOX: number;\n readonly SVG_UNIT_TYPE_UNKNOWN: number;\n readonly SVG_UNIT_TYPE_USERSPACEONUSE: number;\n}\ndeclare var SVGUnitTypes: SVGUnitTypes;\n\ninterface SVGUseElement extends SVGGraphicsElement, SVGURIReference {\n readonly animatedInstanceRoot: SVGElementInstance;\n readonly height: SVGAnimatedLength;\n readonly instanceRoot: SVGElementInstance;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGUseElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGUseElement: {\n prototype: SVGUseElement;\n new(): SVGUseElement;\n};\n\ninterface SVGViewElement extends SVGElement, SVGZoomAndPan, SVGFitToViewBox {\n readonly viewTarget: SVGStringList;\n addEventListener(type: K, listener: (this: SVGViewElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGViewElement: {\n prototype: SVGViewElement;\n new(): SVGViewElement;\n};\n\ninterface SVGZoomAndPan {\n readonly zoomAndPan: number;\n}\n\ndeclare var SVGZoomAndPan: {\n readonly SVG_ZOOMANDPAN_DISABLE: number;\n readonly SVG_ZOOMANDPAN_MAGNIFY: number;\n readonly SVG_ZOOMANDPAN_UNKNOWN: number;\n};\n\ninterface SVGZoomEvent extends UIEvent {\n readonly newScale: number;\n readonly newTranslate: SVGPoint;\n readonly previousScale: number;\n readonly previousTranslate: SVGPoint;\n readonly zoomRectScreen: SVGRect;\n}\n\ndeclare var SVGZoomEvent: {\n prototype: SVGZoomEvent;\n new(): SVGZoomEvent;\n};\n\ninterface SyncManager {\n getTags(): any;\n register(tag: string): Promise;\n}\n\ndeclare var SyncManager: {\n prototype: SyncManager;\n new(): SyncManager;\n};\n\ninterface Text extends CharacterData {\n readonly wholeText: string;\n readonly assignedSlot: HTMLSlotElement | null;\n splitText(offset: number): Text;\n}\n\ndeclare var Text: {\n prototype: Text;\n new(data?: string): Text;\n};\n\ninterface TextEvent extends UIEvent {\n readonly data: string;\n readonly inputMethod: number;\n readonly locale: string;\n initTextEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, dataArg: string, inputMethod: number, locale: string): void;\n readonly DOM_INPUT_METHOD_DROP: number;\n readonly DOM_INPUT_METHOD_HANDWRITING: number;\n readonly DOM_INPUT_METHOD_IME: number;\n readonly DOM_INPUT_METHOD_KEYBOARD: number;\n readonly DOM_INPUT_METHOD_MULTIMODAL: number;\n readonly DOM_INPUT_METHOD_OPTION: number;\n readonly DOM_INPUT_METHOD_PASTE: number;\n readonly DOM_INPUT_METHOD_SCRIPT: number;\n readonly DOM_INPUT_METHOD_UNKNOWN: number;\n readonly DOM_INPUT_METHOD_VOICE: number;\n}\n\ndeclare var TextEvent: {\n prototype: TextEvent;\n new(): TextEvent;\n readonly DOM_INPUT_METHOD_DROP: number;\n readonly DOM_INPUT_METHOD_HANDWRITING: number;\n readonly DOM_INPUT_METHOD_IME: number;\n readonly DOM_INPUT_METHOD_KEYBOARD: number;\n readonly DOM_INPUT_METHOD_MULTIMODAL: number;\n readonly DOM_INPUT_METHOD_OPTION: number;\n readonly DOM_INPUT_METHOD_PASTE: number;\n readonly DOM_INPUT_METHOD_SCRIPT: number;\n readonly DOM_INPUT_METHOD_UNKNOWN: number;\n readonly DOM_INPUT_METHOD_VOICE: number;\n};\n\ninterface TextMetrics {\n readonly width: number;\n}\n\ndeclare var TextMetrics: {\n prototype: TextMetrics;\n new(): TextMetrics;\n};\n\ninterface TextTrackEventMap {\n \"cuechange\": Event;\n \"error\": Event;\n \"load\": Event;\n}\n\ninterface TextTrack extends EventTarget {\n readonly activeCues: TextTrackCueList;\n readonly cues: TextTrackCueList;\n readonly inBandMetadataTrackDispatchType: string;\n readonly kind: string;\n readonly label: string;\n readonly language: string;\n mode: any;\n oncuechange: (this: TextTrack, ev: Event) => any;\n onerror: (this: TextTrack, ev: Event) => any;\n onload: (this: TextTrack, ev: Event) => any;\n readonly readyState: number;\n addCue(cue: TextTrackCue): void;\n removeCue(cue: TextTrackCue): void;\n readonly DISABLED: number;\n readonly ERROR: number;\n readonly HIDDEN: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n readonly SHOWING: number;\n addEventListener(type: K, listener: (this: TextTrack, ev: TextTrackEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var TextTrack: {\n prototype: TextTrack;\n new(): TextTrack;\n readonly DISABLED: number;\n readonly ERROR: number;\n readonly HIDDEN: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n readonly SHOWING: number;\n};\n\ninterface TextTrackCueEventMap {\n \"enter\": Event;\n \"exit\": Event;\n}\n\ninterface TextTrackCue extends EventTarget {\n endTime: number;\n id: string;\n onenter: (this: TextTrackCue, ev: Event) => any;\n onexit: (this: TextTrackCue, ev: Event) => any;\n pauseOnExit: boolean;\n startTime: number;\n text: string;\n readonly track: TextTrack;\n getCueAsHTML(): DocumentFragment;\n addEventListener(type: K, listener: (this: TextTrackCue, ev: TextTrackCueEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var TextTrackCue: {\n prototype: TextTrackCue;\n new(startTime: number, endTime: number, text: string): TextTrackCue;\n};\n\ninterface TextTrackCueList {\n readonly length: number;\n getCueById(id: string): TextTrackCue;\n item(index: number): TextTrackCue;\n [index: number]: TextTrackCue;\n}\n\ndeclare var TextTrackCueList: {\n prototype: TextTrackCueList;\n new(): TextTrackCueList;\n};\n\ninterface TextTrackListEventMap {\n \"addtrack\": TrackEvent;\n}\n\ninterface TextTrackList extends EventTarget {\n readonly length: number;\n onaddtrack: ((this: TextTrackList, ev: TrackEvent) => any) | null;\n item(index: number): TextTrack;\n addEventListener(type: K, listener: (this: TextTrackList, ev: TextTrackListEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [index: number]: TextTrack;\n}\n\ndeclare var TextTrackList: {\n prototype: TextTrackList;\n new(): TextTrackList;\n};\n\ninterface TimeRanges {\n readonly length: number;\n end(index: number): number;\n start(index: number): number;\n}\n\ndeclare var TimeRanges: {\n prototype: TimeRanges;\n new(): TimeRanges;\n};\n\ninterface Touch {\n readonly clientX: number;\n readonly clientY: number;\n readonly identifier: number;\n readonly pageX: number;\n readonly pageY: number;\n readonly screenX: number;\n readonly screenY: number;\n readonly target: EventTarget;\n}\n\ndeclare var Touch: {\n prototype: Touch;\n new(): Touch;\n};\n\ninterface TouchEvent extends UIEvent {\n readonly altKey: boolean;\n readonly changedTouches: TouchList;\n readonly charCode: number;\n readonly ctrlKey: boolean;\n readonly keyCode: number;\n readonly metaKey: boolean;\n readonly shiftKey: boolean;\n readonly targetTouches: TouchList;\n readonly touches: TouchList;\n readonly which: number;\n}\n\ndeclare var TouchEvent: {\n prototype: TouchEvent;\n new(type: string, touchEventInit?: TouchEventInit): TouchEvent;\n};\n\ninterface TouchList {\n readonly length: number;\n item(index: number): Touch | null;\n [index: number]: Touch;\n}\n\ndeclare var TouchList: {\n prototype: TouchList;\n new(): TouchList;\n};\n\ninterface TrackEvent extends Event {\n readonly track: VideoTrack | AudioTrack | TextTrack | null;\n}\n\ndeclare var TrackEvent: {\n prototype: TrackEvent;\n new(typeArg: string, eventInitDict?: TrackEventInit): TrackEvent;\n};\n\ninterface TransitionEvent extends Event {\n readonly elapsedTime: number;\n readonly propertyName: string;\n initTransitionEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, propertyNameArg: string, elapsedTimeArg: number): void;\n}\n\ndeclare var TransitionEvent: {\n prototype: TransitionEvent;\n new(typeArg: string, eventInitDict?: TransitionEventInit): TransitionEvent;\n};\n\ninterface TreeWalker {\n currentNode: Node;\n readonly expandEntityReferences: boolean;\n readonly filter: NodeFilter;\n readonly root: Node;\n readonly whatToShow: number;\n firstChild(): Node;\n lastChild(): Node;\n nextNode(): Node;\n nextSibling(): Node;\n parentNode(): Node;\n previousNode(): Node;\n previousSibling(): Node;\n}\n\ndeclare var TreeWalker: {\n prototype: TreeWalker;\n new(): TreeWalker;\n};\n\ninterface UIEvent extends Event {\n readonly detail: number;\n readonly view: Window;\n initUIEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number): void;\n}\n\ndeclare var UIEvent: {\n prototype: UIEvent;\n new(typeArg: string, eventInitDict?: UIEventInit): UIEvent;\n};\n\ninterface UnviewableContentIdentifiedEvent extends NavigationEventWithReferrer {\n readonly mediaType: string;\n}\n\ndeclare var UnviewableContentIdentifiedEvent: {\n prototype: UnviewableContentIdentifiedEvent;\n new(): UnviewableContentIdentifiedEvent;\n};\n\ninterface URL {\n hash: string;\n host: string;\n hostname: string;\n href: string;\n readonly origin: string;\n password: string;\n pathname: string;\n port: string;\n protocol: string;\n search: string;\n username: string;\n readonly searchParams: URLSearchParams;\n toString(): string;\n}\n\ndeclare var URL: {\n prototype: URL;\n new(url: string, base?: string): URL;\n createObjectURL(object: any, options?: ObjectURLOptions): string;\n revokeObjectURL(url: string): void;\n};\n\ninterface ValidityState {\n readonly badInput: boolean;\n readonly customError: boolean;\n readonly patternMismatch: boolean;\n readonly rangeOverflow: boolean;\n readonly rangeUnderflow: boolean;\n readonly stepMismatch: boolean;\n readonly tooLong: boolean;\n readonly typeMismatch: boolean;\n readonly valid: boolean;\n readonly valueMissing: boolean;\n}\n\ndeclare var ValidityState: {\n prototype: ValidityState;\n new(): ValidityState;\n};\n\ninterface VideoPlaybackQuality {\n readonly corruptedVideoFrames: number;\n readonly creationTime: number;\n readonly droppedVideoFrames: number;\n readonly totalFrameDelay: number;\n readonly totalVideoFrames: number;\n}\n\ndeclare var VideoPlaybackQuality: {\n prototype: VideoPlaybackQuality;\n new(): VideoPlaybackQuality;\n};\n\ninterface VideoTrack {\n readonly id: string;\n kind: string;\n readonly label: string;\n language: string;\n selected: boolean;\n readonly sourceBuffer: SourceBuffer;\n}\n\ndeclare var VideoTrack: {\n prototype: VideoTrack;\n new(): VideoTrack;\n};\n\ninterface VideoTrackListEventMap {\n \"addtrack\": TrackEvent;\n \"change\": Event;\n \"removetrack\": TrackEvent;\n}\n\ninterface VideoTrackList extends EventTarget {\n readonly length: number;\n onaddtrack: (this: VideoTrackList, ev: TrackEvent) => any;\n onchange: (this: VideoTrackList, ev: Event) => any;\n onremovetrack: (this: VideoTrackList, ev: TrackEvent) => any;\n readonly selectedIndex: number;\n getTrackById(id: string): VideoTrack | null;\n item(index: number): VideoTrack;\n addEventListener(type: K, listener: (this: VideoTrackList, ev: VideoTrackListEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [index: number]: VideoTrack;\n}\n\ndeclare var VideoTrackList: {\n prototype: VideoTrackList;\n new(): VideoTrackList;\n};\n\ninterface WaveShaperNode extends AudioNode {\n curve: Float32Array | null;\n oversample: OverSampleType;\n}\n\ndeclare var WaveShaperNode: {\n prototype: WaveShaperNode;\n new(): WaveShaperNode;\n};\n\ninterface WebAuthentication {\n getAssertion(assertionChallenge: any, options?: AssertionOptions): Promise;\n makeCredential(accountInformation: Account, cryptoParameters: ScopedCredentialParameters[], attestationChallenge: any, options?: ScopedCredentialOptions): Promise;\n}\n\ndeclare var WebAuthentication: {\n prototype: WebAuthentication;\n new(): WebAuthentication;\n};\n\ninterface WebAuthnAssertion {\n readonly authenticatorData: ArrayBuffer;\n readonly clientData: ArrayBuffer;\n readonly credential: ScopedCredential;\n readonly signature: ArrayBuffer;\n}\n\ndeclare var WebAuthnAssertion: {\n prototype: WebAuthnAssertion;\n new(): WebAuthnAssertion;\n};\n\ninterface WEBGL_compressed_texture_s3tc {\n readonly COMPRESSED_RGB_S3TC_DXT1_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT1_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT3_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT5_EXT: number;\n}\n\ndeclare var WEBGL_compressed_texture_s3tc: {\n prototype: WEBGL_compressed_texture_s3tc;\n new(): WEBGL_compressed_texture_s3tc;\n readonly COMPRESSED_RGB_S3TC_DXT1_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT1_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT3_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT5_EXT: number;\n};\n\ninterface WEBGL_debug_renderer_info {\n readonly UNMASKED_RENDERER_WEBGL: number;\n readonly UNMASKED_VENDOR_WEBGL: number;\n}\n\ndeclare var WEBGL_debug_renderer_info: {\n prototype: WEBGL_debug_renderer_info;\n new(): WEBGL_debug_renderer_info;\n readonly UNMASKED_RENDERER_WEBGL: number;\n readonly UNMASKED_VENDOR_WEBGL: number;\n};\n\ninterface WEBGL_depth_texture {\n readonly UNSIGNED_INT_24_8_WEBGL: number;\n}\n\ndeclare var WEBGL_depth_texture: {\n prototype: WEBGL_depth_texture;\n new(): WEBGL_depth_texture;\n readonly UNSIGNED_INT_24_8_WEBGL: number;\n};\n\ninterface WebGLActiveInfo {\n readonly name: string;\n readonly size: number;\n readonly type: number;\n}\n\ndeclare var WebGLActiveInfo: {\n prototype: WebGLActiveInfo;\n new(): WebGLActiveInfo;\n};\n\ninterface WebGLBuffer extends WebGLObject {\n}\n\ndeclare var WebGLBuffer: {\n prototype: WebGLBuffer;\n new(): WebGLBuffer;\n};\n\ninterface WebGLContextEvent extends Event {\n readonly statusMessage: string;\n}\n\ndeclare var WebGLContextEvent: {\n prototype: WebGLContextEvent;\n new(typeArg: string, eventInitDict?: WebGLContextEventInit): WebGLContextEvent;\n};\n\ninterface WebGLFramebuffer extends WebGLObject {\n}\n\ndeclare var WebGLFramebuffer: {\n prototype: WebGLFramebuffer;\n new(): WebGLFramebuffer;\n};\n\ninterface WebGLObject {\n}\n\ndeclare var WebGLObject: {\n prototype: WebGLObject;\n new(): WebGLObject;\n};\n\ninterface WebGLProgram extends WebGLObject {\n}\n\ndeclare var WebGLProgram: {\n prototype: WebGLProgram;\n new(): WebGLProgram;\n};\n\ninterface WebGLRenderbuffer extends WebGLObject {\n}\n\ndeclare var WebGLRenderbuffer: {\n prototype: WebGLRenderbuffer;\n new(): WebGLRenderbuffer;\n};\n\ninterface WebGLRenderingContext {\n readonly canvas: HTMLCanvasElement;\n readonly drawingBufferHeight: number;\n readonly drawingBufferWidth: number;\n activeTexture(texture: number): void;\n attachShader(program: WebGLProgram | null, shader: WebGLShader | null): void;\n bindAttribLocation(program: WebGLProgram | null, index: number, name: string): void;\n bindBuffer(target: number, buffer: WebGLBuffer | null): void;\n bindFramebuffer(target: number, framebuffer: WebGLFramebuffer | null): void;\n bindRenderbuffer(target: number, renderbuffer: WebGLRenderbuffer | null): void;\n bindTexture(target: number, texture: WebGLTexture | null): void;\n blendColor(red: number, green: number, blue: number, alpha: number): void;\n blendEquation(mode: number): void;\n blendEquationSeparate(modeRGB: number, modeAlpha: number): void;\n blendFunc(sfactor: number, dfactor: number): void;\n blendFuncSeparate(srcRGB: number, dstRGB: number, srcAlpha: number, dstAlpha: number): void;\n bufferData(target: number, size: number | ArrayBufferView | ArrayBuffer, usage: number): void;\n bufferSubData(target: number, offset: number, data: ArrayBufferView | ArrayBuffer): void;\n checkFramebufferStatus(target: number): number;\n clear(mask: number): void;\n clearColor(red: number, green: number, blue: number, alpha: number): void;\n clearDepth(depth: number): void;\n clearStencil(s: number): void;\n colorMask(red: boolean, green: boolean, blue: boolean, alpha: boolean): void;\n compileShader(shader: WebGLShader | null): void;\n compressedTexImage2D(target: number, level: number, internalformat: number, width: number, height: number, border: number, data: ArrayBufferView): void;\n compressedTexSubImage2D(target: number, level: number, xoffset: number, yoffset: number, width: number, height: number, format: number, data: ArrayBufferView): void;\n copyTexImage2D(target: number, level: number, internalformat: number, x: number, y: number, width: number, height: number, border: number): void;\n copyTexSubImage2D(target: number, level: number, xoffset: number, yoffset: number, x: number, y: number, width: number, height: number): void;\n createBuffer(): WebGLBuffer | null;\n createFramebuffer(): WebGLFramebuffer | null;\n createProgram(): WebGLProgram | null;\n createRenderbuffer(): WebGLRenderbuffer | null;\n createShader(type: number): WebGLShader | null;\n createTexture(): WebGLTexture | null;\n cullFace(mode: number): void;\n deleteBuffer(buffer: WebGLBuffer | null): void;\n deleteFramebuffer(framebuffer: WebGLFramebuffer | null): void;\n deleteProgram(program: WebGLProgram | null): void;\n deleteRenderbuffer(renderbuffer: WebGLRenderbuffer | null): void;\n deleteShader(shader: WebGLShader | null): void;\n deleteTexture(texture: WebGLTexture | null): void;\n depthFunc(func: number): void;\n depthMask(flag: boolean): void;\n depthRange(zNear: number, zFar: number): void;\n detachShader(program: WebGLProgram | null, shader: WebGLShader | null): void;\n disable(cap: number): void;\n disableVertexAttribArray(index: number): void;\n drawArrays(mode: number, first: number, count: number): void;\n drawElements(mode: number, count: number, type: number, offset: number): void;\n enable(cap: number): void;\n enableVertexAttribArray(index: number): void;\n finish(): void;\n flush(): void;\n framebufferRenderbuffer(target: number, attachment: number, renderbuffertarget: number, renderbuffer: WebGLRenderbuffer | null): void;\n framebufferTexture2D(target: number, attachment: number, textarget: number, texture: WebGLTexture | null, level: number): void;\n frontFace(mode: number): void;\n generateMipmap(target: number): void;\n getActiveAttrib(program: WebGLProgram | null, index: number): WebGLActiveInfo | null;\n getActiveUniform(program: WebGLProgram | null, index: number): WebGLActiveInfo | null;\n getAttachedShaders(program: WebGLProgram | null): WebGLShader[] | null;\n getAttribLocation(program: WebGLProgram | null, name: string): number;\n getBufferParameter(target: number, pname: number): any;\n getContextAttributes(): WebGLContextAttributes;\n getError(): number;\n getExtension(name: string): any;\n getFramebufferAttachmentParameter(target: number, attachment: number, pname: number): any;\n getParameter(pname: number): any;\n getProgramInfoLog(program: WebGLProgram | null): string | null;\n getProgramParameter(program: WebGLProgram | null, pname: number): any;\n getRenderbufferParameter(target: number, pname: number): any;\n getShaderInfoLog(shader: WebGLShader | null): string | null;\n getShaderParameter(shader: WebGLShader | null, pname: number): any;\n getShaderPrecisionFormat(shadertype: number, precisiontype: number): WebGLShaderPrecisionFormat | null;\n getShaderSource(shader: WebGLShader | null): string | null;\n getSupportedExtensions(): string[] | null;\n getTexParameter(target: number, pname: number): any;\n getUniform(program: WebGLProgram | null, location: WebGLUniformLocation | null): any;\n getUniformLocation(program: WebGLProgram | null, name: string): WebGLUniformLocation | null;\n getVertexAttrib(index: number, pname: number): any;\n getVertexAttribOffset(index: number, pname: number): number;\n hint(target: number, mode: number): void;\n isBuffer(buffer: WebGLBuffer | null): boolean;\n isContextLost(): boolean;\n isEnabled(cap: number): boolean;\n isFramebuffer(framebuffer: WebGLFramebuffer | null): boolean;\n isProgram(program: WebGLProgram | null): boolean;\n isRenderbuffer(renderbuffer: WebGLRenderbuffer | null): boolean;\n isShader(shader: WebGLShader | null): boolean;\n isTexture(texture: WebGLTexture | null): boolean;\n lineWidth(width: number): void;\n linkProgram(program: WebGLProgram | null): void;\n pixelStorei(pname: number, param: number | boolean): void;\n polygonOffset(factor: number, units: number): void;\n readPixels(x: number, y: number, width: number, height: number, format: number, type: number, pixels: ArrayBufferView | null): void;\n renderbufferStorage(target: number, internalformat: number, width: number, height: number): void;\n sampleCoverage(value: number, invert: boolean): void;\n scissor(x: number, y: number, width: number, height: number): void;\n shaderSource(shader: WebGLShader | null, source: string): void;\n stencilFunc(func: number, ref: number, mask: number): void;\n stencilFuncSeparate(face: number, func: number, ref: number, mask: number): void;\n stencilMask(mask: number): void;\n stencilMaskSeparate(face: number, mask: number): void;\n stencilOp(fail: number, zfail: number, zpass: number): void;\n stencilOpSeparate(face: number, fail: number, zfail: number, zpass: number): void;\n texImage2D(target: number, level: number, internalformat: number, width: number, height: number, border: number, format: number, type: number, pixels: ArrayBufferView | null): void;\n texImage2D(target: number, level: number, internalformat: number, format: number, type: number, pixels: ImageBitmap | ImageData | HTMLVideoElement | HTMLImageElement | HTMLCanvasElement): void;\n texParameterf(target: number, pname: number, param: number): void;\n texParameteri(target: number, pname: number, param: number): void;\n texSubImage2D(target: number, level: number, xoffset: number, yoffset: number, width: number, height: number, format: number, type: number, pixels: ArrayBufferView | null): void;\n texSubImage2D(target: number, level: number, xoffset: number, yoffset: number, format: number, type: number, pixels: ImageBitmap | ImageData | HTMLVideoElement | HTMLImageElement | HTMLCanvasElement): void;\n uniform1f(location: WebGLUniformLocation | null, x: number): void;\n uniform1fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform1i(location: WebGLUniformLocation | null, x: number): void;\n uniform1iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniform2f(location: WebGLUniformLocation | null, x: number, y: number): void;\n uniform2fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform2i(location: WebGLUniformLocation | null, x: number, y: number): void;\n uniform2iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniform3f(location: WebGLUniformLocation | null, x: number, y: number, z: number): void;\n uniform3fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform3i(location: WebGLUniformLocation | null, x: number, y: number, z: number): void;\n uniform3iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniform4f(location: WebGLUniformLocation | null, x: number, y: number, z: number, w: number): void;\n uniform4fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform4i(location: WebGLUniformLocation | null, x: number, y: number, z: number, w: number): void;\n uniform4iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniformMatrix2fv(location: WebGLUniformLocation, transpose: boolean, value: Float32Array | number[]): void;\n uniformMatrix3fv(location: WebGLUniformLocation, transpose: boolean, value: Float32Array | number[]): void;\n uniformMatrix4fv(location: WebGLUniformLocation, transpose: boolean, value: Float32Array | number[]): void;\n useProgram(program: WebGLProgram | null): void;\n validateProgram(program: WebGLProgram | null): void;\n vertexAttrib1f(indx: number, x: number): void;\n vertexAttrib1fv(indx: number, values: Float32Array | number[]): void;\n vertexAttrib2f(indx: number, x: number, y: number): void;\n vertexAttrib2fv(indx: number, values: Float32Array | number[]): void;\n vertexAttrib3f(indx: number, x: number, y: number, z: number): void;\n vertexAttrib3fv(indx: number, values: Float32Array | number[]): void;\n vertexAttrib4f(indx: number, x: number, y: number, z: number, w: number): void;\n vertexAttrib4fv(indx: number, values: Float32Array | number[]): void;\n vertexAttribPointer(indx: number, size: number, type: number, normalized: boolean, stride: number, offset: number): void;\n viewport(x: number, y: number, width: number, height: number): void;\n readonly ACTIVE_ATTRIBUTES: number;\n readonly ACTIVE_TEXTURE: number;\n readonly ACTIVE_UNIFORMS: number;\n readonly ALIASED_LINE_WIDTH_RANGE: number;\n readonly ALIASED_POINT_SIZE_RANGE: number;\n readonly ALPHA: number;\n readonly ALPHA_BITS: number;\n readonly ALWAYS: number;\n readonly ARRAY_BUFFER: number;\n readonly ARRAY_BUFFER_BINDING: number;\n readonly ATTACHED_SHADERS: number;\n readonly BACK: number;\n readonly BLEND: number;\n readonly BLEND_COLOR: number;\n readonly BLEND_DST_ALPHA: number;\n readonly BLEND_DST_RGB: number;\n readonly BLEND_EQUATION: number;\n readonly BLEND_EQUATION_ALPHA: number;\n readonly BLEND_EQUATION_RGB: number;\n readonly BLEND_SRC_ALPHA: number;\n readonly BLEND_SRC_RGB: number;\n readonly BLUE_BITS: number;\n readonly BOOL: number;\n readonly BOOL_VEC2: number;\n readonly BOOL_VEC3: number;\n readonly BOOL_VEC4: number;\n readonly BROWSER_DEFAULT_WEBGL: number;\n readonly BUFFER_SIZE: number;\n readonly BUFFER_USAGE: number;\n readonly BYTE: number;\n readonly CCW: number;\n readonly CLAMP_TO_EDGE: number;\n readonly COLOR_ATTACHMENT0: number;\n readonly COLOR_BUFFER_BIT: number;\n readonly COLOR_CLEAR_VALUE: number;\n readonly COLOR_WRITEMASK: number;\n readonly COMPILE_STATUS: number;\n readonly COMPRESSED_TEXTURE_FORMATS: number;\n readonly CONSTANT_ALPHA: number;\n readonly CONSTANT_COLOR: number;\n readonly CONTEXT_LOST_WEBGL: number;\n readonly CULL_FACE: number;\n readonly CULL_FACE_MODE: number;\n readonly CURRENT_PROGRAM: number;\n readonly CURRENT_VERTEX_ATTRIB: number;\n readonly CW: number;\n readonly DECR: number;\n readonly DECR_WRAP: number;\n readonly DELETE_STATUS: number;\n readonly DEPTH_ATTACHMENT: number;\n readonly DEPTH_BITS: number;\n readonly DEPTH_BUFFER_BIT: number;\n readonly DEPTH_CLEAR_VALUE: number;\n readonly DEPTH_COMPONENT: number;\n readonly DEPTH_COMPONENT16: number;\n readonly DEPTH_FUNC: number;\n readonly DEPTH_RANGE: number;\n readonly DEPTH_STENCIL: number;\n readonly DEPTH_STENCIL_ATTACHMENT: number;\n readonly DEPTH_TEST: number;\n readonly DEPTH_WRITEMASK: number;\n readonly DITHER: number;\n readonly DONT_CARE: number;\n readonly DST_ALPHA: number;\n readonly DST_COLOR: number;\n readonly DYNAMIC_DRAW: number;\n readonly ELEMENT_ARRAY_BUFFER: number;\n readonly ELEMENT_ARRAY_BUFFER_BINDING: number;\n readonly EQUAL: number;\n readonly FASTEST: number;\n readonly FLOAT: number;\n readonly FLOAT_MAT2: number;\n readonly FLOAT_MAT3: number;\n readonly FLOAT_MAT4: number;\n readonly FLOAT_VEC2: number;\n readonly FLOAT_VEC3: number;\n readonly FLOAT_VEC4: number;\n readonly FRAGMENT_SHADER: number;\n readonly FRAMEBUFFER: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_NAME: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL: number;\n readonly FRAMEBUFFER_BINDING: number;\n readonly FRAMEBUFFER_COMPLETE: number;\n readonly FRAMEBUFFER_INCOMPLETE_ATTACHMENT: number;\n readonly FRAMEBUFFER_INCOMPLETE_DIMENSIONS: number;\n readonly FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT: number;\n readonly FRAMEBUFFER_UNSUPPORTED: number;\n readonly FRONT: number;\n readonly FRONT_AND_BACK: number;\n readonly FRONT_FACE: number;\n readonly FUNC_ADD: number;\n readonly FUNC_REVERSE_SUBTRACT: number;\n readonly FUNC_SUBTRACT: number;\n readonly GENERATE_MIPMAP_HINT: number;\n readonly GEQUAL: number;\n readonly GREATER: number;\n readonly GREEN_BITS: number;\n readonly HIGH_FLOAT: number;\n readonly HIGH_INT: number;\n readonly IMPLEMENTATION_COLOR_READ_FORMAT: number;\n readonly IMPLEMENTATION_COLOR_READ_TYPE: number;\n readonly INCR: number;\n readonly INCR_WRAP: number;\n readonly INT: number;\n readonly INT_VEC2: number;\n readonly INT_VEC3: number;\n readonly INT_VEC4: number;\n readonly INVALID_ENUM: number;\n readonly INVALID_FRAMEBUFFER_OPERATION: number;\n readonly INVALID_OPERATION: number;\n readonly INVALID_VALUE: number;\n readonly INVERT: number;\n readonly KEEP: number;\n readonly LEQUAL: number;\n readonly LESS: number;\n readonly LINE_LOOP: number;\n readonly LINE_STRIP: number;\n readonly LINE_WIDTH: number;\n readonly LINEAR: number;\n readonly LINEAR_MIPMAP_LINEAR: number;\n readonly LINEAR_MIPMAP_NEAREST: number;\n readonly LINES: number;\n readonly LINK_STATUS: number;\n readonly LOW_FLOAT: number;\n readonly LOW_INT: number;\n readonly LUMINANCE: number;\n readonly LUMINANCE_ALPHA: number;\n readonly MAX_COMBINED_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_CUBE_MAP_TEXTURE_SIZE: number;\n readonly MAX_FRAGMENT_UNIFORM_VECTORS: number;\n readonly MAX_RENDERBUFFER_SIZE: number;\n readonly MAX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_TEXTURE_SIZE: number;\n readonly MAX_VARYING_VECTORS: number;\n readonly MAX_VERTEX_ATTRIBS: number;\n readonly MAX_VERTEX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_VERTEX_UNIFORM_VECTORS: number;\n readonly MAX_VIEWPORT_DIMS: number;\n readonly MEDIUM_FLOAT: number;\n readonly MEDIUM_INT: number;\n readonly MIRRORED_REPEAT: number;\n readonly NEAREST: number;\n readonly NEAREST_MIPMAP_LINEAR: number;\n readonly NEAREST_MIPMAP_NEAREST: number;\n readonly NEVER: number;\n readonly NICEST: number;\n readonly NO_ERROR: number;\n readonly NONE: number;\n readonly NOTEQUAL: number;\n readonly ONE: number;\n readonly ONE_MINUS_CONSTANT_ALPHA: number;\n readonly ONE_MINUS_CONSTANT_COLOR: number;\n readonly ONE_MINUS_DST_ALPHA: number;\n readonly ONE_MINUS_DST_COLOR: number;\n readonly ONE_MINUS_SRC_ALPHA: number;\n readonly ONE_MINUS_SRC_COLOR: number;\n readonly OUT_OF_MEMORY: number;\n readonly PACK_ALIGNMENT: number;\n readonly POINTS: number;\n readonly POLYGON_OFFSET_FACTOR: number;\n readonly POLYGON_OFFSET_FILL: number;\n readonly POLYGON_OFFSET_UNITS: number;\n readonly RED_BITS: number;\n readonly RENDERBUFFER: number;\n readonly RENDERBUFFER_ALPHA_SIZE: number;\n readonly RENDERBUFFER_BINDING: number;\n readonly RENDERBUFFER_BLUE_SIZE: number;\n readonly RENDERBUFFER_DEPTH_SIZE: number;\n readonly RENDERBUFFER_GREEN_SIZE: number;\n readonly RENDERBUFFER_HEIGHT: number;\n readonly RENDERBUFFER_INTERNAL_FORMAT: number;\n readonly RENDERBUFFER_RED_SIZE: number;\n readonly RENDERBUFFER_STENCIL_SIZE: number;\n readonly RENDERBUFFER_WIDTH: number;\n readonly RENDERER: number;\n readonly REPEAT: number;\n readonly REPLACE: number;\n readonly RGB: number;\n readonly RGB5_A1: number;\n readonly RGB565: number;\n readonly RGBA: number;\n readonly RGBA4: number;\n readonly SAMPLE_ALPHA_TO_COVERAGE: number;\n readonly SAMPLE_BUFFERS: number;\n readonly SAMPLE_COVERAGE: number;\n readonly SAMPLE_COVERAGE_INVERT: number;\n readonly SAMPLE_COVERAGE_VALUE: number;\n readonly SAMPLER_2D: number;\n readonly SAMPLER_CUBE: number;\n readonly SAMPLES: number;\n readonly SCISSOR_BOX: number;\n readonly SCISSOR_TEST: number;\n readonly SHADER_TYPE: number;\n readonly SHADING_LANGUAGE_VERSION: number;\n readonly SHORT: number;\n readonly SRC_ALPHA: number;\n readonly SRC_ALPHA_SATURATE: number;\n readonly SRC_COLOR: number;\n readonly STATIC_DRAW: number;\n readonly STENCIL_ATTACHMENT: number;\n readonly STENCIL_BACK_FAIL: number;\n readonly STENCIL_BACK_FUNC: number;\n readonly STENCIL_BACK_PASS_DEPTH_FAIL: number;\n readonly STENCIL_BACK_PASS_DEPTH_PASS: number;\n readonly STENCIL_BACK_REF: number;\n readonly STENCIL_BACK_VALUE_MASK: number;\n readonly STENCIL_BACK_WRITEMASK: number;\n readonly STENCIL_BITS: number;\n readonly STENCIL_BUFFER_BIT: number;\n readonly STENCIL_CLEAR_VALUE: number;\n readonly STENCIL_FAIL: number;\n readonly STENCIL_FUNC: number;\n readonly STENCIL_INDEX: number;\n readonly STENCIL_INDEX8: number;\n readonly STENCIL_PASS_DEPTH_FAIL: number;\n readonly STENCIL_PASS_DEPTH_PASS: number;\n readonly STENCIL_REF: number;\n readonly STENCIL_TEST: number;\n readonly STENCIL_VALUE_MASK: number;\n readonly STENCIL_WRITEMASK: number;\n readonly STREAM_DRAW: number;\n readonly SUBPIXEL_BITS: number;\n readonly TEXTURE: number;\n readonly TEXTURE_2D: number;\n readonly TEXTURE_BINDING_2D: number;\n readonly TEXTURE_BINDING_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_X: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Z: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_X: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Z: number;\n readonly TEXTURE_MAG_FILTER: number;\n readonly TEXTURE_MIN_FILTER: number;\n readonly TEXTURE_WRAP_S: number;\n readonly TEXTURE_WRAP_T: number;\n readonly TEXTURE0: number;\n readonly TEXTURE1: number;\n readonly TEXTURE10: number;\n readonly TEXTURE11: number;\n readonly TEXTURE12: number;\n readonly TEXTURE13: number;\n readonly TEXTURE14: number;\n readonly TEXTURE15: number;\n readonly TEXTURE16: number;\n readonly TEXTURE17: number;\n readonly TEXTURE18: number;\n readonly TEXTURE19: number;\n readonly TEXTURE2: number;\n readonly TEXTURE20: number;\n readonly TEXTURE21: number;\n readonly TEXTURE22: number;\n readonly TEXTURE23: number;\n readonly TEXTURE24: number;\n readonly TEXTURE25: number;\n readonly TEXTURE26: number;\n readonly TEXTURE27: number;\n readonly TEXTURE28: number;\n readonly TEXTURE29: number;\n readonly TEXTURE3: number;\n readonly TEXTURE30: number;\n readonly TEXTURE31: number;\n readonly TEXTURE4: number;\n readonly TEXTURE5: number;\n readonly TEXTURE6: number;\n readonly TEXTURE7: number;\n readonly TEXTURE8: number;\n readonly TEXTURE9: number;\n readonly TRIANGLE_FAN: number;\n readonly TRIANGLE_STRIP: number;\n readonly TRIANGLES: number;\n readonly UNPACK_ALIGNMENT: number;\n readonly UNPACK_COLORSPACE_CONVERSION_WEBGL: number;\n readonly UNPACK_FLIP_Y_WEBGL: number;\n readonly UNPACK_PREMULTIPLY_ALPHA_WEBGL: number;\n readonly UNSIGNED_BYTE: number;\n readonly UNSIGNED_INT: number;\n readonly UNSIGNED_SHORT: number;\n readonly UNSIGNED_SHORT_4_4_4_4: number;\n readonly UNSIGNED_SHORT_5_5_5_1: number;\n readonly UNSIGNED_SHORT_5_6_5: number;\n readonly VALIDATE_STATUS: number;\n readonly VENDOR: number;\n readonly VERSION: number;\n readonly VERTEX_ATTRIB_ARRAY_BUFFER_BINDING: number;\n readonly VERTEX_ATTRIB_ARRAY_ENABLED: number;\n readonly VERTEX_ATTRIB_ARRAY_NORMALIZED: number;\n readonly VERTEX_ATTRIB_ARRAY_POINTER: number;\n readonly VERTEX_ATTRIB_ARRAY_SIZE: number;\n readonly VERTEX_ATTRIB_ARRAY_STRIDE: number;\n readonly VERTEX_ATTRIB_ARRAY_TYPE: number;\n readonly VERTEX_SHADER: number;\n readonly VIEWPORT: number;\n readonly ZERO: number;\n}\n\ndeclare var WebGLRenderingContext: {\n prototype: WebGLRenderingContext;\n new(): WebGLRenderingContext;\n readonly ACTIVE_ATTRIBUTES: number;\n readonly ACTIVE_TEXTURE: number;\n readonly ACTIVE_UNIFORMS: number;\n readonly ALIASED_LINE_WIDTH_RANGE: number;\n readonly ALIASED_POINT_SIZE_RANGE: number;\n readonly ALPHA: number;\n readonly ALPHA_BITS: number;\n readonly ALWAYS: number;\n readonly ARRAY_BUFFER: number;\n readonly ARRAY_BUFFER_BINDING: number;\n readonly ATTACHED_SHADERS: number;\n readonly BACK: number;\n readonly BLEND: number;\n readonly BLEND_COLOR: number;\n readonly BLEND_DST_ALPHA: number;\n readonly BLEND_DST_RGB: number;\n readonly BLEND_EQUATION: number;\n readonly BLEND_EQUATION_ALPHA: number;\n readonly BLEND_EQUATION_RGB: number;\n readonly BLEND_SRC_ALPHA: number;\n readonly BLEND_SRC_RGB: number;\n readonly BLUE_BITS: number;\n readonly BOOL: number;\n readonly BOOL_VEC2: number;\n readonly BOOL_VEC3: number;\n readonly BOOL_VEC4: number;\n readonly BROWSER_DEFAULT_WEBGL: number;\n readonly BUFFER_SIZE: number;\n readonly BUFFER_USAGE: number;\n readonly BYTE: number;\n readonly CCW: number;\n readonly CLAMP_TO_EDGE: number;\n readonly COLOR_ATTACHMENT0: number;\n readonly COLOR_BUFFER_BIT: number;\n readonly COLOR_CLEAR_VALUE: number;\n readonly COLOR_WRITEMASK: number;\n readonly COMPILE_STATUS: number;\n readonly COMPRESSED_TEXTURE_FORMATS: number;\n readonly CONSTANT_ALPHA: number;\n readonly CONSTANT_COLOR: number;\n readonly CONTEXT_LOST_WEBGL: number;\n readonly CULL_FACE: number;\n readonly CULL_FACE_MODE: number;\n readonly CURRENT_PROGRAM: number;\n readonly CURRENT_VERTEX_ATTRIB: number;\n readonly CW: number;\n readonly DECR: number;\n readonly DECR_WRAP: number;\n readonly DELETE_STATUS: number;\n readonly DEPTH_ATTACHMENT: number;\n readonly DEPTH_BITS: number;\n readonly DEPTH_BUFFER_BIT: number;\n readonly DEPTH_CLEAR_VALUE: number;\n readonly DEPTH_COMPONENT: number;\n readonly DEPTH_COMPONENT16: number;\n readonly DEPTH_FUNC: number;\n readonly DEPTH_RANGE: number;\n readonly DEPTH_STENCIL: number;\n readonly DEPTH_STENCIL_ATTACHMENT: number;\n readonly DEPTH_TEST: number;\n readonly DEPTH_WRITEMASK: number;\n readonly DITHER: number;\n readonly DONT_CARE: number;\n readonly DST_ALPHA: number;\n readonly DST_COLOR: number;\n readonly DYNAMIC_DRAW: number;\n readonly ELEMENT_ARRAY_BUFFER: number;\n readonly ELEMENT_ARRAY_BUFFER_BINDING: number;\n readonly EQUAL: number;\n readonly FASTEST: number;\n readonly FLOAT: number;\n readonly FLOAT_MAT2: number;\n readonly FLOAT_MAT3: number;\n readonly FLOAT_MAT4: number;\n readonly FLOAT_VEC2: number;\n readonly FLOAT_VEC3: number;\n readonly FLOAT_VEC4: number;\n readonly FRAGMENT_SHADER: number;\n readonly FRAMEBUFFER: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_NAME: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL: number;\n readonly FRAMEBUFFER_BINDING: number;\n readonly FRAMEBUFFER_COMPLETE: number;\n readonly FRAMEBUFFER_INCOMPLETE_ATTACHMENT: number;\n readonly FRAMEBUFFER_INCOMPLETE_DIMENSIONS: number;\n readonly FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT: number;\n readonly FRAMEBUFFER_UNSUPPORTED: number;\n readonly FRONT: number;\n readonly FRONT_AND_BACK: number;\n readonly FRONT_FACE: number;\n readonly FUNC_ADD: number;\n readonly FUNC_REVERSE_SUBTRACT: number;\n readonly FUNC_SUBTRACT: number;\n readonly GENERATE_MIPMAP_HINT: number;\n readonly GEQUAL: number;\n readonly GREATER: number;\n readonly GREEN_BITS: number;\n readonly HIGH_FLOAT: number;\n readonly HIGH_INT: number;\n readonly IMPLEMENTATION_COLOR_READ_FORMAT: number;\n readonly IMPLEMENTATION_COLOR_READ_TYPE: number;\n readonly INCR: number;\n readonly INCR_WRAP: number;\n readonly INT: number;\n readonly INT_VEC2: number;\n readonly INT_VEC3: number;\n readonly INT_VEC4: number;\n readonly INVALID_ENUM: number;\n readonly INVALID_FRAMEBUFFER_OPERATION: number;\n readonly INVALID_OPERATION: number;\n readonly INVALID_VALUE: number;\n readonly INVERT: number;\n readonly KEEP: number;\n readonly LEQUAL: number;\n readonly LESS: number;\n readonly LINE_LOOP: number;\n readonly LINE_STRIP: number;\n readonly LINE_WIDTH: number;\n readonly LINEAR: number;\n readonly LINEAR_MIPMAP_LINEAR: number;\n readonly LINEAR_MIPMAP_NEAREST: number;\n readonly LINES: number;\n readonly LINK_STATUS: number;\n readonly LOW_FLOAT: number;\n readonly LOW_INT: number;\n readonly LUMINANCE: number;\n readonly LUMINANCE_ALPHA: number;\n readonly MAX_COMBINED_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_CUBE_MAP_TEXTURE_SIZE: number;\n readonly MAX_FRAGMENT_UNIFORM_VECTORS: number;\n readonly MAX_RENDERBUFFER_SIZE: number;\n readonly MAX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_TEXTURE_SIZE: number;\n readonly MAX_VARYING_VECTORS: number;\n readonly MAX_VERTEX_ATTRIBS: number;\n readonly MAX_VERTEX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_VERTEX_UNIFORM_VECTORS: number;\n readonly MAX_VIEWPORT_DIMS: number;\n readonly MEDIUM_FLOAT: number;\n readonly MEDIUM_INT: number;\n readonly MIRRORED_REPEAT: number;\n readonly NEAREST: number;\n readonly NEAREST_MIPMAP_LINEAR: number;\n readonly NEAREST_MIPMAP_NEAREST: number;\n readonly NEVER: number;\n readonly NICEST: number;\n readonly NO_ERROR: number;\n readonly NONE: number;\n readonly NOTEQUAL: number;\n readonly ONE: number;\n readonly ONE_MINUS_CONSTANT_ALPHA: number;\n readonly ONE_MINUS_CONSTANT_COLOR: number;\n readonly ONE_MINUS_DST_ALPHA: number;\n readonly ONE_MINUS_DST_COLOR: number;\n readonly ONE_MINUS_SRC_ALPHA: number;\n readonly ONE_MINUS_SRC_COLOR: number;\n readonly OUT_OF_MEMORY: number;\n readonly PACK_ALIGNMENT: number;\n readonly POINTS: number;\n readonly POLYGON_OFFSET_FACTOR: number;\n readonly POLYGON_OFFSET_FILL: number;\n readonly POLYGON_OFFSET_UNITS: number;\n readonly RED_BITS: number;\n readonly RENDERBUFFER: number;\n readonly RENDERBUFFER_ALPHA_SIZE: number;\n readonly RENDERBUFFER_BINDING: number;\n readonly RENDERBUFFER_BLUE_SIZE: number;\n readonly RENDERBUFFER_DEPTH_SIZE: number;\n readonly RENDERBUFFER_GREEN_SIZE: number;\n readonly RENDERBUFFER_HEIGHT: number;\n readonly RENDERBUFFER_INTERNAL_FORMAT: number;\n readonly RENDERBUFFER_RED_SIZE: number;\n readonly RENDERBUFFER_STENCIL_SIZE: number;\n readonly RENDERBUFFER_WIDTH: number;\n readonly RENDERER: number;\n readonly REPEAT: number;\n readonly REPLACE: number;\n readonly RGB: number;\n readonly RGB5_A1: number;\n readonly RGB565: number;\n readonly RGBA: number;\n readonly RGBA4: number;\n readonly SAMPLE_ALPHA_TO_COVERAGE: number;\n readonly SAMPLE_BUFFERS: number;\n readonly SAMPLE_COVERAGE: number;\n readonly SAMPLE_COVERAGE_INVERT: number;\n readonly SAMPLE_COVERAGE_VALUE: number;\n readonly SAMPLER_2D: number;\n readonly SAMPLER_CUBE: number;\n readonly SAMPLES: number;\n readonly SCISSOR_BOX: number;\n readonly SCISSOR_TEST: number;\n readonly SHADER_TYPE: number;\n readonly SHADING_LANGUAGE_VERSION: number;\n readonly SHORT: number;\n readonly SRC_ALPHA: number;\n readonly SRC_ALPHA_SATURATE: number;\n readonly SRC_COLOR: number;\n readonly STATIC_DRAW: number;\n readonly STENCIL_ATTACHMENT: number;\n readonly STENCIL_BACK_FAIL: number;\n readonly STENCIL_BACK_FUNC: number;\n readonly STENCIL_BACK_PASS_DEPTH_FAIL: number;\n readonly STENCIL_BACK_PASS_DEPTH_PASS: number;\n readonly STENCIL_BACK_REF: number;\n readonly STENCIL_BACK_VALUE_MASK: number;\n readonly STENCIL_BACK_WRITEMASK: number;\n readonly STENCIL_BITS: number;\n readonly STENCIL_BUFFER_BIT: number;\n readonly STENCIL_CLEAR_VALUE: number;\n readonly STENCIL_FAIL: number;\n readonly STENCIL_FUNC: number;\n readonly STENCIL_INDEX: number;\n readonly STENCIL_INDEX8: number;\n readonly STENCIL_PASS_DEPTH_FAIL: number;\n readonly STENCIL_PASS_DEPTH_PASS: number;\n readonly STENCIL_REF: number;\n readonly STENCIL_TEST: number;\n readonly STENCIL_VALUE_MASK: number;\n readonly STENCIL_WRITEMASK: number;\n readonly STREAM_DRAW: number;\n readonly SUBPIXEL_BITS: number;\n readonly TEXTURE: number;\n readonly TEXTURE_2D: number;\n readonly TEXTURE_BINDING_2D: number;\n readonly TEXTURE_BINDING_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_X: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Z: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_X: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Z: number;\n readonly TEXTURE_MAG_FILTER: number;\n readonly TEXTURE_MIN_FILTER: number;\n readonly TEXTURE_WRAP_S: number;\n readonly TEXTURE_WRAP_T: number;\n readonly TEXTURE0: number;\n readonly TEXTURE1: number;\n readonly TEXTURE10: number;\n readonly TEXTURE11: number;\n readonly TEXTURE12: number;\n readonly TEXTURE13: number;\n readonly TEXTURE14: number;\n readonly TEXTURE15: number;\n readonly TEXTURE16: number;\n readonly TEXTURE17: number;\n readonly TEXTURE18: number;\n readonly TEXTURE19: number;\n readonly TEXTURE2: number;\n readonly TEXTURE20: number;\n readonly TEXTURE21: number;\n readonly TEXTURE22: number;\n readonly TEXTURE23: number;\n readonly TEXTURE24: number;\n readonly TEXTURE25: number;\n readonly TEXTURE26: number;\n readonly TEXTURE27: number;\n readonly TEXTURE28: number;\n readonly TEXTURE29: number;\n readonly TEXTURE3: number;\n readonly TEXTURE30: number;\n readonly TEXTURE31: number;\n readonly TEXTURE4: number;\n readonly TEXTURE5: number;\n readonly TEXTURE6: number;\n readonly TEXTURE7: number;\n readonly TEXTURE8: number;\n readonly TEXTURE9: number;\n readonly TRIANGLE_FAN: number;\n readonly TRIANGLE_STRIP: number;\n readonly TRIANGLES: number;\n readonly UNPACK_ALIGNMENT: number;\n readonly UNPACK_COLORSPACE_CONVERSION_WEBGL: number;\n readonly UNPACK_FLIP_Y_WEBGL: number;\n readonly UNPACK_PREMULTIPLY_ALPHA_WEBGL: number;\n readonly UNSIGNED_BYTE: number;\n readonly UNSIGNED_INT: number;\n readonly UNSIGNED_SHORT: number;\n readonly UNSIGNED_SHORT_4_4_4_4: number;\n readonly UNSIGNED_SHORT_5_5_5_1: number;\n readonly UNSIGNED_SHORT_5_6_5: number;\n readonly VALIDATE_STATUS: number;\n readonly VENDOR: number;\n readonly VERSION: number;\n readonly VERTEX_ATTRIB_ARRAY_BUFFER_BINDING: number;\n readonly VERTEX_ATTRIB_ARRAY_ENABLED: number;\n readonly VERTEX_ATTRIB_ARRAY_NORMALIZED: number;\n readonly VERTEX_ATTRIB_ARRAY_POINTER: number;\n readonly VERTEX_ATTRIB_ARRAY_SIZE: number;\n readonly VERTEX_ATTRIB_ARRAY_STRIDE: number;\n readonly VERTEX_ATTRIB_ARRAY_TYPE: number;\n readonly VERTEX_SHADER: number;\n readonly VIEWPORT: number;\n readonly ZERO: number;\n};\n\ninterface WebGLShader extends WebGLObject {\n}\n\ndeclare var WebGLShader: {\n prototype: WebGLShader;\n new(): WebGLShader;\n};\n\ninterface WebGLShaderPrecisionFormat {\n readonly precision: number;\n readonly rangeMax: number;\n readonly rangeMin: number;\n}\n\ndeclare var WebGLShaderPrecisionFormat: {\n prototype: WebGLShaderPrecisionFormat;\n new(): WebGLShaderPrecisionFormat;\n};\n\ninterface WebGLTexture extends WebGLObject {\n}\n\ndeclare var WebGLTexture: {\n prototype: WebGLTexture;\n new(): WebGLTexture;\n};\n\ninterface WebGLUniformLocation {\n}\n\ndeclare var WebGLUniformLocation: {\n prototype: WebGLUniformLocation;\n new(): WebGLUniformLocation;\n};\n\ninterface WebKitCSSMatrix {\n a: number;\n b: number;\n c: number;\n d: number;\n e: number;\n f: number;\n m11: number;\n m12: number;\n m13: number;\n m14: number;\n m21: number;\n m22: number;\n m23: number;\n m24: number;\n m31: number;\n m32: number;\n m33: number;\n m34: number;\n m41: number;\n m42: number;\n m43: number;\n m44: number;\n inverse(): WebKitCSSMatrix;\n multiply(secondMatrix: WebKitCSSMatrix): WebKitCSSMatrix;\n rotate(angleX: number, angleY?: number, angleZ?: number): WebKitCSSMatrix;\n rotateAxisAngle(x: number, y: number, z: number, angle: number): WebKitCSSMatrix;\n scale(scaleX: number, scaleY?: number, scaleZ?: number): WebKitCSSMatrix;\n setMatrixValue(value: string): void;\n skewX(angle: number): WebKitCSSMatrix;\n skewY(angle: number): WebKitCSSMatrix;\n toString(): string;\n translate(x: number, y: number, z?: number): WebKitCSSMatrix;\n}\n\ndeclare var WebKitCSSMatrix: {\n prototype: WebKitCSSMatrix;\n new(text?: string): WebKitCSSMatrix;\n};\n\ninterface WebKitDirectoryEntry extends WebKitEntry {\n createReader(): WebKitDirectoryReader;\n}\n\ndeclare var WebKitDirectoryEntry: {\n prototype: WebKitDirectoryEntry;\n new(): WebKitDirectoryEntry;\n};\n\ninterface WebKitDirectoryReader {\n readEntries(successCallback: WebKitEntriesCallback, errorCallback?: WebKitErrorCallback): void;\n}\n\ndeclare var WebKitDirectoryReader: {\n prototype: WebKitDirectoryReader;\n new(): WebKitDirectoryReader;\n};\n\ninterface WebKitEntry {\n readonly filesystem: WebKitFileSystem;\n readonly fullPath: string;\n readonly isDirectory: boolean;\n readonly isFile: boolean;\n readonly name: string;\n}\n\ndeclare var WebKitEntry: {\n prototype: WebKitEntry;\n new(): WebKitEntry;\n};\n\ninterface WebKitFileEntry extends WebKitEntry {\n file(successCallback: WebKitFileCallback, errorCallback?: WebKitErrorCallback): void;\n}\n\ndeclare var WebKitFileEntry: {\n prototype: WebKitFileEntry;\n new(): WebKitFileEntry;\n};\n\ninterface WebKitFileSystem {\n readonly name: string;\n readonly root: WebKitDirectoryEntry;\n}\n\ndeclare var WebKitFileSystem: {\n prototype: WebKitFileSystem;\n new(): WebKitFileSystem;\n};\n\ninterface WebKitPoint {\n x: number;\n y: number;\n}\n\ndeclare var WebKitPoint: {\n prototype: WebKitPoint;\n new(x?: number, y?: number): WebKitPoint;\n};\n\ninterface webkitRTCPeerConnection extends RTCPeerConnection {\n addEventListener(type: K, listener: (this: webkitRTCPeerConnection, ev: RTCPeerConnectionEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var webkitRTCPeerConnection: {\n prototype: webkitRTCPeerConnection;\n new(configuration: RTCConfiguration): webkitRTCPeerConnection;\n};\n\ninterface WebSocketEventMap {\n \"close\": CloseEvent;\n \"error\": Event;\n \"message\": MessageEvent;\n \"open\": Event;\n}\n\ninterface WebSocket extends EventTarget {\n binaryType: string;\n readonly bufferedAmount: number;\n readonly extensions: string;\n onclose: (this: WebSocket, ev: CloseEvent) => any;\n onerror: (this: WebSocket, ev: Event) => any;\n onmessage: (this: WebSocket, ev: MessageEvent) => any;\n onopen: (this: WebSocket, ev: Event) => any;\n readonly protocol: string;\n readonly readyState: number;\n readonly url: string;\n close(code?: number, reason?: string): void;\n send(data: any): void;\n readonly CLOSED: number;\n readonly CLOSING: number;\n readonly CONNECTING: number;\n readonly OPEN: number;\n addEventListener(type: K, listener: (this: WebSocket, ev: WebSocketEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var WebSocket: {\n prototype: WebSocket;\n new(url: string, protocols?: string | string[]): WebSocket;\n readonly CLOSED: number;\n readonly CLOSING: number;\n readonly CONNECTING: number;\n readonly OPEN: number;\n};\n\ninterface WheelEvent extends MouseEvent {\n readonly deltaMode: number;\n readonly deltaX: number;\n readonly deltaY: number;\n readonly deltaZ: number;\n readonly wheelDelta: number;\n readonly wheelDeltaX: number;\n readonly wheelDeltaY: number;\n getCurrentPoint(element: Element): void;\n initWheelEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, buttonArg: number, relatedTargetArg: EventTarget, modifiersListArg: string, deltaXArg: number, deltaYArg: number, deltaZArg: number, deltaMode: number): void;\n readonly DOM_DELTA_LINE: number;\n readonly DOM_DELTA_PAGE: number;\n readonly DOM_DELTA_PIXEL: number;\n}\n\ndeclare var WheelEvent: {\n prototype: WheelEvent;\n new(typeArg: string, eventInitDict?: WheelEventInit): WheelEvent;\n readonly DOM_DELTA_LINE: number;\n readonly DOM_DELTA_PAGE: number;\n readonly DOM_DELTA_PIXEL: number;\n};\n\ninterface WindowEventMap extends GlobalEventHandlersEventMap {\n \"abort\": UIEvent;\n \"afterprint\": Event;\n \"beforeprint\": Event;\n \"beforeunload\": BeforeUnloadEvent;\n \"blur\": FocusEvent;\n \"canplay\": Event;\n \"canplaythrough\": Event;\n \"change\": Event;\n \"click\": MouseEvent;\n \"compassneedscalibration\": Event;\n \"contextmenu\": PointerEvent;\n \"dblclick\": MouseEvent;\n \"devicelight\": DeviceLightEvent;\n \"devicemotion\": DeviceMotionEvent;\n \"deviceorientation\": DeviceOrientationEvent;\n \"drag\": DragEvent;\n \"dragend\": DragEvent;\n \"dragenter\": DragEvent;\n \"dragleave\": DragEvent;\n \"dragover\": DragEvent;\n \"dragstart\": DragEvent;\n \"drop\": DragEvent;\n \"durationchange\": Event;\n \"emptied\": Event;\n \"ended\": MediaStreamErrorEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"hashchange\": HashChangeEvent;\n \"input\": Event;\n \"invalid\": Event;\n \"keydown\": KeyboardEvent;\n \"keypress\": KeyboardEvent;\n \"keyup\": KeyboardEvent;\n \"load\": Event;\n \"loadeddata\": Event;\n \"loadedmetadata\": Event;\n \"loadstart\": Event;\n \"message\": MessageEvent;\n \"mousedown\": MouseEvent;\n \"mouseenter\": MouseEvent;\n \"mouseleave\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n \"mousewheel\": WheelEvent;\n \"MSGestureChange\": MSGestureEvent;\n \"MSGestureDoubleTap\": MSGestureEvent;\n \"MSGestureEnd\": MSGestureEvent;\n \"MSGestureHold\": MSGestureEvent;\n \"MSGestureStart\": MSGestureEvent;\n \"MSGestureTap\": MSGestureEvent;\n \"MSInertiaStart\": MSGestureEvent;\n \"MSPointerCancel\": MSPointerEvent;\n \"MSPointerDown\": MSPointerEvent;\n \"MSPointerEnter\": MSPointerEvent;\n \"MSPointerLeave\": MSPointerEvent;\n \"MSPointerMove\": MSPointerEvent;\n \"MSPointerOut\": MSPointerEvent;\n \"MSPointerOver\": MSPointerEvent;\n \"MSPointerUp\": MSPointerEvent;\n \"offline\": Event;\n \"online\": Event;\n \"orientationchange\": Event;\n \"pagehide\": PageTransitionEvent;\n \"pageshow\": PageTransitionEvent;\n \"pause\": Event;\n \"play\": Event;\n \"playing\": Event;\n \"popstate\": PopStateEvent;\n \"progress\": ProgressEvent;\n \"ratechange\": Event;\n \"readystatechange\": ProgressEvent;\n \"reset\": Event;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"seeked\": Event;\n \"seeking\": Event;\n \"select\": UIEvent;\n \"stalled\": Event;\n \"storage\": StorageEvent;\n \"submit\": Event;\n \"suspend\": Event;\n \"timeupdate\": Event;\n \"touchcancel\": TouchEvent;\n \"touchend\": TouchEvent;\n \"touchmove\": TouchEvent;\n \"touchstart\": TouchEvent;\n \"unload\": Event;\n \"volumechange\": Event;\n \"waiting\": Event;\n}\n\ninterface Window extends EventTarget, WindowTimers, WindowSessionStorage, WindowLocalStorage, WindowConsole, GlobalEventHandlers, IDBEnvironment, WindowBase64, GlobalFetch {\n readonly applicationCache: ApplicationCache;\n readonly caches: CacheStorage;\n readonly clientInformation: Navigator;\n readonly closed: boolean;\n readonly crypto: Crypto;\n defaultStatus: string;\n readonly devicePixelRatio: number;\n readonly document: Document;\n readonly doNotTrack: string;\n event: Event | undefined;\n readonly external: External;\n readonly frameElement: Element;\n readonly frames: Window;\n readonly history: History;\n readonly innerHeight: number;\n readonly innerWidth: number;\n readonly isSecureContext: boolean;\n readonly length: number;\n readonly location: Location;\n readonly locationbar: BarProp;\n readonly menubar: BarProp;\n readonly msContentScript: ExtensionScriptApis;\n readonly msCredentials: MSCredentials;\n name: string;\n readonly navigator: Navigator;\n offscreenBuffering: string | boolean;\n onabort: (this: Window, ev: UIEvent) => any;\n onafterprint: (this: Window, ev: Event) => any;\n onbeforeprint: (this: Window, ev: Event) => any;\n onbeforeunload: (this: Window, ev: BeforeUnloadEvent) => any;\n onblur: (this: Window, ev: FocusEvent) => any;\n oncanplay: (this: Window, ev: Event) => any;\n oncanplaythrough: (this: Window, ev: Event) => any;\n onchange: (this: Window, ev: Event) => any;\n onclick: (this: Window, ev: MouseEvent) => any;\n oncompassneedscalibration: (this: Window, ev: Event) => any;\n oncontextmenu: (this: Window, ev: PointerEvent) => any;\n ondblclick: (this: Window, ev: MouseEvent) => any;\n ondevicelight: (this: Window, ev: DeviceLightEvent) => any;\n ondevicemotion: (this: Window, ev: DeviceMotionEvent) => any;\n ondeviceorientation: (this: Window, ev: DeviceOrientationEvent) => any;\n ondrag: (this: Window, ev: DragEvent) => any;\n ondragend: (this: Window, ev: DragEvent) => any;\n ondragenter: (this: Window, ev: DragEvent) => any;\n ondragleave: (this: Window, ev: DragEvent) => any;\n ondragover: (this: Window, ev: DragEvent) => any;\n ondragstart: (this: Window, ev: DragEvent) => any;\n ondrop: (this: Window, ev: DragEvent) => any;\n ondurationchange: (this: Window, ev: Event) => any;\n onemptied: (this: Window, ev: Event) => any;\n onended: (this: Window, ev: MediaStreamErrorEvent) => any;\n onerror: ErrorEventHandler;\n onfocus: (this: Window, ev: FocusEvent) => any;\n onhashchange: (this: Window, ev: HashChangeEvent) => any;\n oninput: (this: Window, ev: Event) => any;\n oninvalid: (this: Window, ev: Event) => any;\n onkeydown: (this: Window, ev: KeyboardEvent) => any;\n onkeypress: (this: Window, ev: KeyboardEvent) => any;\n onkeyup: (this: Window, ev: KeyboardEvent) => any;\n onload: (this: Window, ev: Event) => any;\n onloadeddata: (this: Window, ev: Event) => any;\n onloadedmetadata: (this: Window, ev: Event) => any;\n onloadstart: (this: Window, ev: Event) => any;\n onmessage: (this: Window, ev: MessageEvent) => any;\n onmousedown: (this: Window, ev: MouseEvent) => any;\n onmouseenter: (this: Window, ev: MouseEvent) => any;\n onmouseleave: (this: Window, ev: MouseEvent) => any;\n onmousemove: (this: Window, ev: MouseEvent) => any;\n onmouseout: (this: Window, ev: MouseEvent) => any;\n onmouseover: (this: Window, ev: MouseEvent) => any;\n onmouseup: (this: Window, ev: MouseEvent) => any;\n onmousewheel: (this: Window, ev: WheelEvent) => any;\n onmsgesturechange: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturedoubletap: (this: Window, ev: MSGestureEvent) => any;\n onmsgestureend: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturehold: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturestart: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturetap: (this: Window, ev: MSGestureEvent) => any;\n onmsinertiastart: (this: Window, ev: MSGestureEvent) => any;\n onmspointercancel: (this: Window, ev: MSPointerEvent) => any;\n onmspointerdown: (this: Window, ev: MSPointerEvent) => any;\n onmspointerenter: (this: Window, ev: MSPointerEvent) => any;\n onmspointerleave: (this: Window, ev: MSPointerEvent) => any;\n onmspointermove: (this: Window, ev: MSPointerEvent) => any;\n onmspointerout: (this: Window, ev: MSPointerEvent) => any;\n onmspointerover: (this: Window, ev: MSPointerEvent) => any;\n onmspointerup: (this: Window, ev: MSPointerEvent) => any;\n onoffline: (this: Window, ev: Event) => any;\n ononline: (this: Window, ev: Event) => any;\n onorientationchange: (this: Window, ev: Event) => any;\n onpagehide: (this: Window, ev: PageTransitionEvent) => any;\n onpageshow: (this: Window, ev: PageTransitionEvent) => any;\n onpause: (this: Window, ev: Event) => any;\n onplay: (this: Window, ev: Event) => any;\n onplaying: (this: Window, ev: Event) => any;\n onpopstate: (this: Window, ev: PopStateEvent) => any;\n onprogress: (this: Window, ev: ProgressEvent) => any;\n onratechange: (this: Window, ev: Event) => any;\n onreadystatechange: (this: Window, ev: ProgressEvent) => any;\n onreset: (this: Window, ev: Event) => any;\n onresize: (this: Window, ev: UIEvent) => any;\n onscroll: (this: Window, ev: UIEvent) => any;\n onseeked: (this: Window, ev: Event) => any;\n onseeking: (this: Window, ev: Event) => any;\n onselect: (this: Window, ev: UIEvent) => any;\n onstalled: (this: Window, ev: Event) => any;\n onstorage: (this: Window, ev: StorageEvent) => any;\n onsubmit: (this: Window, ev: Event) => any;\n onsuspend: (this: Window, ev: Event) => any;\n ontimeupdate: (this: Window, ev: Event) => any;\n ontouchcancel: (ev: TouchEvent) => any;\n ontouchend: (ev: TouchEvent) => any;\n ontouchmove: (ev: TouchEvent) => any;\n ontouchstart: (ev: TouchEvent) => any;\n onunload: (this: Window, ev: Event) => any;\n onvolumechange: (this: Window, ev: Event) => any;\n onwaiting: (this: Window, ev: Event) => any;\n opener: any;\n orientation: string | number;\n readonly outerHeight: number;\n readonly outerWidth: number;\n readonly pageXOffset: number;\n readonly pageYOffset: number;\n readonly parent: Window;\n readonly performance: Performance;\n readonly personalbar: BarProp;\n readonly screen: Screen;\n readonly screenLeft: number;\n readonly screenTop: number;\n readonly screenX: number;\n readonly screenY: number;\n readonly scrollbars: BarProp;\n readonly scrollX: number;\n readonly scrollY: number;\n readonly self: Window;\n readonly speechSynthesis: SpeechSynthesis;\n status: string;\n readonly statusbar: BarProp;\n readonly styleMedia: StyleMedia;\n readonly toolbar: BarProp;\n readonly top: Window;\n readonly window: Window;\n URL: typeof URL;\n URLSearchParams: typeof URLSearchParams;\n Blob: typeof Blob;\n customElements: CustomElementRegistry;\n alert(message?: any): void;\n blur(): void;\n cancelAnimationFrame(handle: number): void;\n captureEvents(): void;\n close(): void;\n confirm(message?: string): boolean;\n departFocus(navigationReason: NavigationReason, origin: FocusNavigationOrigin): void;\n focus(): void;\n getComputedStyle(elt: Element, pseudoElt?: string): CSSStyleDeclaration;\n getMatchedCSSRules(elt: Element, pseudoElt?: string): CSSRuleList;\n getSelection(): Selection;\n matchMedia(mediaQuery: string): MediaQueryList;\n moveBy(x?: number, y?: number): void;\n moveTo(x?: number, y?: number): void;\n msWriteProfilerMark(profilerMarkName: string): void;\n open(url?: string, target?: string, features?: string, replace?: boolean): Window;\n postMessage(message: any, targetOrigin: string, transfer?: any[]): void;\n print(): void;\n prompt(message?: string, _default?: string): string | null;\n releaseEvents(): void;\n requestAnimationFrame(callback: FrameRequestCallback): number;\n resizeBy(x?: number, y?: number): void;\n resizeTo(x?: number, y?: number): void;\n scroll(x?: number, y?: number): void;\n scrollBy(x?: number, y?: number): void;\n scrollTo(x?: number, y?: number): void;\n stop(): void;\n webkitCancelAnimationFrame(handle: number): void;\n webkitConvertPointFromNodeToPage(node: Node, pt: WebKitPoint): WebKitPoint;\n webkitConvertPointFromPageToNode(node: Node, pt: WebKitPoint): WebKitPoint;\n webkitRequestAnimationFrame(callback: FrameRequestCallback): number;\n createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, options?: ImageBitmapOptions): Promise;\n createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, sx: number, sy: number, sw: number, sh: number, options?: ImageBitmapOptions): Promise;\n scroll(options?: ScrollToOptions): void;\n scrollTo(options?: ScrollToOptions): void;\n scrollBy(options?: ScrollToOptions): void;\n addEventListener(type: K, listener: (this: Window, ev: WindowEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Window: {\n prototype: Window;\n new(): Window;\n};\n\ninterface WorkerEventMap extends AbstractWorkerEventMap {\n \"message\": MessageEvent;\n}\n\ninterface Worker extends EventTarget, AbstractWorker {\n onmessage: (this: Worker, ev: MessageEvent) => any;\n postMessage(message: any, transfer?: any[]): void;\n terminate(): void;\n addEventListener(type: K, listener: (this: Worker, ev: WorkerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Worker: {\n prototype: Worker;\n new(stringUrl: string): Worker;\n};\n\ninterface XMLDocument extends Document {\n addEventListener(type: K, listener: (this: XMLDocument, ev: DocumentEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var XMLDocument: {\n prototype: XMLDocument;\n new(): XMLDocument;\n};\n\ninterface XMLHttpRequestEventMap extends XMLHttpRequestEventTargetEventMap {\n \"readystatechange\": Event;\n}\n\ninterface XMLHttpRequest extends EventTarget, XMLHttpRequestEventTarget {\n onreadystatechange: (this: XMLHttpRequest, ev: Event) => any;\n readonly readyState: number;\n readonly response: any;\n readonly responseText: string;\n responseType: XMLHttpRequestResponseType;\n readonly responseURL: string;\n readonly responseXML: Document | null;\n readonly status: number;\n readonly statusText: string;\n timeout: number;\n readonly upload: XMLHttpRequestUpload;\n withCredentials: boolean;\n msCaching?: string;\n abort(): void;\n getAllResponseHeaders(): string;\n getResponseHeader(header: string): string | null;\n msCachingEnabled(): boolean;\n open(method: string, url: string, async?: boolean, user?: string, password?: string): void;\n overrideMimeType(mime: string): void;\n send(data?: Document): void;\n send(data?: string): void;\n send(data?: any): void;\n setRequestHeader(header: string, value: string): void;\n readonly DONE: number;\n readonly HEADERS_RECEIVED: number;\n readonly LOADING: number;\n readonly OPENED: number;\n readonly UNSENT: number;\n addEventListener(type: K, listener: (this: XMLHttpRequest, ev: XMLHttpRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var XMLHttpRequest: {\n prototype: XMLHttpRequest;\n new(): XMLHttpRequest;\n readonly DONE: number;\n readonly HEADERS_RECEIVED: number;\n readonly LOADING: number;\n readonly OPENED: number;\n readonly UNSENT: number;\n};\n\ninterface XMLHttpRequestUpload extends EventTarget, XMLHttpRequestEventTarget {\n addEventListener(type: K, listener: (this: XMLHttpRequestUpload, ev: XMLHttpRequestEventTargetEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var XMLHttpRequestUpload: {\n prototype: XMLHttpRequestUpload;\n new(): XMLHttpRequestUpload;\n};\n\ninterface XMLSerializer {\n serializeToString(target: Node): string;\n}\n\ndeclare var XMLSerializer: {\n prototype: XMLSerializer;\n new(): XMLSerializer;\n};\n\ninterface XPathEvaluator {\n createExpression(expression: string, resolver: XPathNSResolver): XPathExpression;\n createNSResolver(nodeResolver?: Node): XPathNSResolver;\n evaluate(expression: string, contextNode: Node, resolver: XPathNSResolver | null, type: number, result: XPathResult | null): XPathResult;\n}\n\ndeclare var XPathEvaluator: {\n prototype: XPathEvaluator;\n new(): XPathEvaluator;\n};\n\ninterface XPathExpression {\n evaluate(contextNode: Node, type: number, result: XPathResult | null): XPathResult;\n}\n\ndeclare var XPathExpression: {\n prototype: XPathExpression;\n new(): XPathExpression;\n};\n\ninterface XPathNSResolver {\n lookupNamespaceURI(prefix: string): string;\n}\n\ndeclare var XPathNSResolver: {\n prototype: XPathNSResolver;\n new(): XPathNSResolver;\n};\n\ninterface XPathResult {\n readonly booleanValue: boolean;\n readonly invalidIteratorState: boolean;\n readonly numberValue: number;\n readonly resultType: number;\n readonly singleNodeValue: Node;\n readonly snapshotLength: number;\n readonly stringValue: string;\n iterateNext(): Node;\n snapshotItem(index: number): Node;\n readonly ANY_TYPE: number;\n readonly ANY_UNORDERED_NODE_TYPE: number;\n readonly BOOLEAN_TYPE: number;\n readonly FIRST_ORDERED_NODE_TYPE: number;\n readonly NUMBER_TYPE: number;\n readonly ORDERED_NODE_ITERATOR_TYPE: number;\n readonly ORDERED_NODE_SNAPSHOT_TYPE: number;\n readonly STRING_TYPE: number;\n readonly UNORDERED_NODE_ITERATOR_TYPE: number;\n readonly UNORDERED_NODE_SNAPSHOT_TYPE: number;\n}\n\ndeclare var XPathResult: {\n prototype: XPathResult;\n new(): XPathResult;\n readonly ANY_TYPE: number;\n readonly ANY_UNORDERED_NODE_TYPE: number;\n readonly BOOLEAN_TYPE: number;\n readonly FIRST_ORDERED_NODE_TYPE: number;\n readonly NUMBER_TYPE: number;\n readonly ORDERED_NODE_ITERATOR_TYPE: number;\n readonly ORDERED_NODE_SNAPSHOT_TYPE: number;\n readonly STRING_TYPE: number;\n readonly UNORDERED_NODE_ITERATOR_TYPE: number;\n readonly UNORDERED_NODE_SNAPSHOT_TYPE: number;\n};\n\ninterface XSLTProcessor {\n clearParameters(): void;\n getParameter(namespaceURI: string, localName: string): any;\n importStylesheet(style: Node): void;\n removeParameter(namespaceURI: string, localName: string): void;\n reset(): void;\n setParameter(namespaceURI: string, localName: string, value: any): void;\n transformToDocument(source: Node): Document;\n transformToFragment(source: Node, document: Document): DocumentFragment;\n}\n\ndeclare var XSLTProcessor: {\n prototype: XSLTProcessor;\n new(): XSLTProcessor;\n};\n\ninterface AbstractWorkerEventMap {\n \"error\": ErrorEvent;\n}\n\ninterface AbstractWorker {\n onerror: (this: AbstractWorker, ev: ErrorEvent) => any;\n addEventListener(type: K, listener: (this: AbstractWorker, ev: AbstractWorkerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface Body {\n readonly bodyUsed: boolean;\n arrayBuffer(): Promise;\n blob(): Promise;\n json(): Promise;\n text(): Promise;\n formData(): Promise;\n}\n\ninterface CanvasPathMethods {\n arc(x: number, y: number, radius: number, startAngle: number, endAngle: number, anticlockwise?: boolean): void;\n arcTo(x1: number, y1: number, x2: number, y2: number, radius: number): void;\n bezierCurveTo(cp1x: number, cp1y: number, cp2x: number, cp2y: number, x: number, y: number): void;\n closePath(): void;\n ellipse(x: number, y: number, radiusX: number, radiusY: number, rotation: number, startAngle: number, endAngle: number, anticlockwise?: boolean): void;\n lineTo(x: number, y: number): void;\n moveTo(x: number, y: number): void;\n quadraticCurveTo(cpx: number, cpy: number, x: number, y: number): void;\n rect(x: number, y: number, w: number, h: number): void;\n}\n\ninterface ChildNode {\n remove(): void;\n}\n\ninterface DocumentEvent {\n createEvent(eventInterface: \"AnimationEvent\"): AnimationEvent;\n createEvent(eventInterface: \"AudioProcessingEvent\"): AudioProcessingEvent;\n createEvent(eventInterface: \"BeforeUnloadEvent\"): BeforeUnloadEvent;\n createEvent(eventInterface: \"ClipboardEvent\"): ClipboardEvent;\n createEvent(eventInterface: \"CloseEvent\"): CloseEvent;\n createEvent(eventInterface: \"CompositionEvent\"): CompositionEvent;\n createEvent(eventInterface: \"CustomEvent\"): CustomEvent;\n createEvent(eventInterface: \"DeviceLightEvent\"): DeviceLightEvent;\n createEvent(eventInterface: \"DeviceMotionEvent\"): DeviceMotionEvent;\n createEvent(eventInterface: \"DeviceOrientationEvent\"): DeviceOrientationEvent;\n createEvent(eventInterface: \"DragEvent\"): DragEvent;\n createEvent(eventInterface: \"ErrorEvent\"): ErrorEvent;\n createEvent(eventInterface: \"Event\"): Event;\n createEvent(eventInterface: \"Events\"): Event;\n createEvent(eventInterface: \"FocusEvent\"): FocusEvent;\n createEvent(eventInterface: \"FocusNavigationEvent\"): FocusNavigationEvent;\n createEvent(eventInterface: \"GamepadEvent\"): GamepadEvent;\n createEvent(eventInterface: \"HashChangeEvent\"): HashChangeEvent;\n createEvent(eventInterface: \"IDBVersionChangeEvent\"): IDBVersionChangeEvent;\n createEvent(eventInterface: \"KeyboardEvent\"): KeyboardEvent;\n createEvent(eventInterface: \"ListeningStateChangedEvent\"): ListeningStateChangedEvent;\n createEvent(eventInterface: \"LongRunningScriptDetectedEvent\"): LongRunningScriptDetectedEvent;\n createEvent(eventInterface: \"MSGestureEvent\"): MSGestureEvent;\n createEvent(eventInterface: \"MSManipulationEvent\"): MSManipulationEvent;\n createEvent(eventInterface: \"MSMediaKeyMessageEvent\"): MSMediaKeyMessageEvent;\n createEvent(eventInterface: \"MSMediaKeyNeededEvent\"): MSMediaKeyNeededEvent;\n createEvent(eventInterface: \"MSPointerEvent\"): MSPointerEvent;\n createEvent(eventInterface: \"MSSiteModeEvent\"): MSSiteModeEvent;\n createEvent(eventInterface: \"MediaEncryptedEvent\"): MediaEncryptedEvent;\n createEvent(eventInterface: \"MediaKeyMessageEvent\"): MediaKeyMessageEvent;\n createEvent(eventInterface: \"MediaStreamErrorEvent\"): MediaStreamErrorEvent;\n createEvent(eventInterface: \"MediaStreamEvent\"): MediaStreamEvent;\n createEvent(eventInterface: \"MediaStreamTrackEvent\"): MediaStreamTrackEvent;\n createEvent(eventInterface: \"MessageEvent\"): MessageEvent;\n createEvent(eventInterface: \"MouseEvent\"): MouseEvent;\n createEvent(eventInterface: \"MouseEvents\"): MouseEvent;\n createEvent(eventInterface: \"MutationEvent\"): MutationEvent;\n createEvent(eventInterface: \"MutationEvents\"): MutationEvent;\n createEvent(eventInterface: \"NavigationCompletedEvent\"): NavigationCompletedEvent;\n createEvent(eventInterface: \"NavigationEvent\"): NavigationEvent;\n createEvent(eventInterface: \"NavigationEventWithReferrer\"): NavigationEventWithReferrer;\n createEvent(eventInterface: \"OfflineAudioCompletionEvent\"): OfflineAudioCompletionEvent;\n createEvent(eventInterface: \"OverflowEvent\"): OverflowEvent;\n createEvent(eventInterface: \"PageTransitionEvent\"): PageTransitionEvent;\n createEvent(eventInterface: \"PaymentRequestUpdateEvent\"): PaymentRequestUpdateEvent;\n createEvent(eventInterface: \"PermissionRequestedEvent\"): PermissionRequestedEvent;\n createEvent(eventInterface: \"PointerEvent\"): PointerEvent;\n createEvent(eventInterface: \"PopStateEvent\"): PopStateEvent;\n createEvent(eventInterface: \"ProgressEvent\"): ProgressEvent;\n createEvent(eventInterface: \"RTCDTMFToneChangeEvent\"): RTCDTMFToneChangeEvent;\n createEvent(eventInterface: \"RTCDtlsTransportStateChangedEvent\"): RTCDtlsTransportStateChangedEvent;\n createEvent(eventInterface: \"RTCIceCandidatePairChangedEvent\"): RTCIceCandidatePairChangedEvent;\n createEvent(eventInterface: \"RTCIceGathererEvent\"): RTCIceGathererEvent;\n createEvent(eventInterface: \"RTCIceTransportStateChangedEvent\"): RTCIceTransportStateChangedEvent;\n createEvent(eventInterface: \"RTCPeerConnectionIceEvent\"): RTCPeerConnectionIceEvent;\n createEvent(eventInterface: \"RTCSsrcConflictEvent\"): RTCSsrcConflictEvent;\n createEvent(eventInterface: \"SVGZoomEvent\"): SVGZoomEvent;\n createEvent(eventInterface: \"SVGZoomEvents\"): SVGZoomEvent;\n createEvent(eventInterface: \"ScriptNotifyEvent\"): ScriptNotifyEvent;\n createEvent(eventInterface: \"ServiceWorkerMessageEvent\"): ServiceWorkerMessageEvent;\n createEvent(eventInterface: \"SpeechSynthesisEvent\"): SpeechSynthesisEvent;\n createEvent(eventInterface: \"StorageEvent\"): StorageEvent;\n createEvent(eventInterface: \"TextEvent\"): TextEvent;\n createEvent(eventInterface: \"TouchEvent\"): TouchEvent;\n createEvent(eventInterface: \"TrackEvent\"): TrackEvent;\n createEvent(eventInterface: \"TransitionEvent\"): TransitionEvent;\n createEvent(eventInterface: \"UIEvent\"): UIEvent;\n createEvent(eventInterface: \"UIEvents\"): UIEvent;\n createEvent(eventInterface: \"UnviewableContentIdentifiedEvent\"): UnviewableContentIdentifiedEvent;\n createEvent(eventInterface: \"WebGLContextEvent\"): WebGLContextEvent;\n createEvent(eventInterface: \"WheelEvent\"): WheelEvent;\n createEvent(eventInterface: string): Event;\n}\n\ninterface DOML2DeprecatedColorProperty {\n color: string;\n}\n\ninterface DOML2DeprecatedSizeProperty {\n size: number;\n}\n\ninterface ElementTraversal {\n readonly childElementCount: number;\n readonly firstElementChild: Element | null;\n readonly lastElementChild: Element | null;\n readonly nextElementSibling: Element | null;\n readonly previousElementSibling: Element | null;\n}\n\ninterface GetSVGDocument {\n getSVGDocument(): Document;\n}\n\ninterface GlobalEventHandlersEventMap {\n \"pointercancel\": PointerEvent;\n \"pointerdown\": PointerEvent;\n \"pointerenter\": PointerEvent;\n \"pointerleave\": PointerEvent;\n \"pointermove\": PointerEvent;\n \"pointerout\": PointerEvent;\n \"pointerover\": PointerEvent;\n \"pointerup\": PointerEvent;\n \"wheel\": WheelEvent;\n}\n\ninterface GlobalEventHandlers {\n onpointercancel: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerdown: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerenter: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerleave: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointermove: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerout: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerover: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerup: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onwheel: (this: GlobalEventHandlers, ev: WheelEvent) => any;\n addEventListener(type: K, listener: (this: GlobalEventHandlers, ev: GlobalEventHandlersEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface GlobalFetch {\n fetch(input: RequestInfo, init?: RequestInit): Promise;\n}\n\ninterface HTMLTableAlignment {\n /**\n * Sets or retrieves a value that you can use to implement your own ch functionality for the object.\n */\n ch: string;\n /**\n * Sets or retrieves a value that you can use to implement your own chOff functionality for the object.\n */\n chOff: string;\n /**\n * Sets or retrieves how text and other content are vertically aligned within the object that contains them.\n */\n vAlign: string;\n}\n\ninterface IDBEnvironment {\n readonly indexedDB: IDBFactory;\n}\n\ninterface LinkStyle {\n readonly sheet: StyleSheet;\n}\n\ninterface MSBaseReaderEventMap {\n \"abort\": Event;\n \"error\": ErrorEvent;\n \"load\": Event;\n \"loadend\": ProgressEvent;\n \"loadstart\": Event;\n \"progress\": ProgressEvent;\n}\n\ninterface MSBaseReader {\n onabort: (this: MSBaseReader, ev: Event) => any;\n onerror: (this: MSBaseReader, ev: ErrorEvent) => any;\n onload: (this: MSBaseReader, ev: Event) => any;\n onloadend: (this: MSBaseReader, ev: ProgressEvent) => any;\n onloadstart: (this: MSBaseReader, ev: Event) => any;\n onprogress: (this: MSBaseReader, ev: ProgressEvent) => any;\n readonly readyState: number;\n readonly result: any;\n abort(): void;\n readonly DONE: number;\n readonly EMPTY: number;\n readonly LOADING: number;\n addEventListener(type: K, listener: (this: MSBaseReader, ev: MSBaseReaderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface MSFileSaver {\n msSaveBlob(blob: any, defaultName?: string): boolean;\n msSaveOrOpenBlob(blob: any, defaultName?: string): boolean;\n}\n\ninterface MSNavigatorDoNotTrack {\n confirmSiteSpecificTrackingException(args: ConfirmSiteSpecificExceptionsInformation): boolean;\n confirmWebWideTrackingException(args: ExceptionInformation): boolean;\n removeSiteSpecificTrackingException(args: ExceptionInformation): void;\n removeWebWideTrackingException(args: ExceptionInformation): void;\n storeSiteSpecificTrackingException(args: StoreSiteSpecificExceptionsInformation): void;\n storeWebWideTrackingException(args: StoreExceptionsInformation): void;\n}\n\ninterface NavigatorBeacon {\n sendBeacon(url: USVString, data?: BodyInit): boolean;\n}\n\ninterface NavigatorConcurrentHardware {\n readonly hardwareConcurrency: number;\n}\n\ninterface NavigatorContentUtils {\n}\n\ninterface NavigatorGeolocation {\n readonly geolocation: Geolocation;\n}\n\ninterface NavigatorID {\n readonly appCodeName: string;\n readonly appName: string;\n readonly appVersion: string;\n readonly platform: string;\n readonly product: string;\n readonly productSub: string;\n readonly userAgent: string;\n readonly vendor: string;\n readonly vendorSub: string;\n}\n\ninterface NavigatorOnLine {\n readonly onLine: boolean;\n}\n\ninterface NavigatorStorageUtils {\n}\n\ninterface NavigatorUserMedia {\n readonly mediaDevices: MediaDevices;\n getUserMedia(constraints: MediaStreamConstraints, successCallback: NavigatorUserMediaSuccessCallback, errorCallback: NavigatorUserMediaErrorCallback): void;\n}\n\ninterface NodeSelector {\n querySelector(selectors: K): ElementTagNameMap[K] | null;\n querySelector(selectors: string): Element | null;\n querySelectorAll(selectors: K): ElementListTagNameMap[K];\n querySelectorAll(selectors: string): NodeListOf;\n}\n\ninterface RandomSource {\n getRandomValues(array: ArrayBufferView): ArrayBufferView;\n}\n\ninterface SVGAnimatedPoints {\n readonly animatedPoints: SVGPointList;\n readonly points: SVGPointList;\n}\n\ninterface SVGFilterPrimitiveStandardAttributes {\n readonly height: SVGAnimatedLength;\n readonly result: SVGAnimatedString;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n}\n\ninterface SVGFitToViewBox {\n readonly preserveAspectRatio: SVGAnimatedPreserveAspectRatio;\n readonly viewBox: SVGAnimatedRect;\n}\n\ninterface SVGTests {\n readonly requiredExtensions: SVGStringList;\n readonly requiredFeatures: SVGStringList;\n readonly systemLanguage: SVGStringList;\n hasExtension(extension: string): boolean;\n}\n\ninterface SVGURIReference {\n readonly href: SVGAnimatedString;\n}\n\ninterface WindowBase64 {\n atob(encodedString: string): string;\n btoa(rawString: string): string;\n}\n\ninterface WindowConsole {\n readonly console: Console;\n}\n\ninterface WindowLocalStorage {\n readonly localStorage: Storage;\n}\n\ninterface WindowSessionStorage {\n readonly sessionStorage: Storage;\n}\n\ninterface WindowTimers extends Object, WindowTimersExtension {\n clearInterval(handle: number): void;\n clearTimeout(handle: number): void;\n setInterval(handler: (...args: any[]) => void, timeout: number): number;\n setInterval(handler: any, timeout?: any, ...args: any[]): number;\n setTimeout(handler: (...args: any[]) => void, timeout: number): number;\n setTimeout(handler: any, timeout?: any, ...args: any[]): number;\n}\n\ninterface WindowTimersExtension {\n clearImmediate(handle: number): void;\n setImmediate(handler: (...args: any[]) => void): number;\n setImmediate(handler: any, ...args: any[]): number;\n}\n\ninterface XMLHttpRequestEventTargetEventMap {\n \"abort\": Event;\n \"error\": ErrorEvent;\n \"load\": Event;\n \"loadend\": ProgressEvent;\n \"loadstart\": Event;\n \"progress\": ProgressEvent;\n \"timeout\": ProgressEvent;\n}\n\ninterface XMLHttpRequestEventTarget {\n onabort: (this: XMLHttpRequestEventTarget, ev: Event) => any;\n onerror: (this: XMLHttpRequestEventTarget, ev: ErrorEvent) => any;\n onload: (this: XMLHttpRequestEventTarget, ev: Event) => any;\n onloadend: (this: XMLHttpRequestEventTarget, ev: ProgressEvent) => any;\n onloadstart: (this: XMLHttpRequestEventTarget, ev: Event) => any;\n onprogress: (this: XMLHttpRequestEventTarget, ev: ProgressEvent) => any;\n ontimeout: (this: XMLHttpRequestEventTarget, ev: ProgressEvent) => any;\n addEventListener(type: K, listener: (this: XMLHttpRequestEventTarget, ev: XMLHttpRequestEventTargetEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface ErrorEventInit {\n message?: string;\n filename?: string;\n lineno?: number;\n conlno?: number;\n error?: any;\n}\n\ninterface StorageEventInit extends EventInit {\n key?: string;\n oldValue?: string;\n newValue?: string;\n url: string;\n storageArea?: Storage;\n}\n\ninterface Canvas2DContextAttributes {\n alpha?: boolean;\n willReadFrequently?: boolean;\n storage?: boolean;\n [attribute: string]: boolean | string | undefined;\n}\n\ninterface ImageBitmapOptions {\n imageOrientation?: \"none\" | \"flipY\";\n premultiplyAlpha?: \"none\" | \"premultiply\" | \"default\";\n colorSpaceConversion?: \"none\" | \"default\";\n resizeWidth?: number;\n resizeHeight?: number;\n resizeQuality?: \"pixelated\" | \"low\" | \"medium\" | \"high\";\n}\n\ninterface ImageBitmap {\n readonly width: number;\n readonly height: number;\n close(): void;\n}\n\ninterface URLSearchParams {\n /**\n * Appends a specified key/value pair as a new search parameter.\n */\n append(name: string, value: string): void;\n /**\n * Deletes the given search parameter, and its associated value, from the list of all search parameters.\n */\n delete(name: string): void;\n /**\n * Returns the first value associated to the given search parameter.\n */\n get(name: string): string | null;\n /**\n * Returns all the values association with a given search parameter.\n */\n getAll(name: string): string[];\n /**\n * Returns a Boolean indicating if such a search parameter exists.\n */\n has(name: string): boolean;\n /**\n * Sets the value associated to a given search parameter to the given value. If there were several values, delete the others.\n */\n set(name: string, value: string): void;\n}\n\ndeclare var URLSearchParams: {\n prototype: URLSearchParams;\n /**\n * Constructor returning a URLSearchParams object.\n */\n new (init?: string | URLSearchParams): URLSearchParams;\n};\n\ninterface NodeListOf extends NodeList {\n length: number;\n item(index: number): TNode;\n [index: number]: TNode;\n}\n\ninterface HTMLCollectionOf extends HTMLCollection {\n item(index: number): T;\n namedItem(name: string): T;\n [index: number]: T;\n}\n\ninterface BlobPropertyBag {\n type?: string;\n endings?: string;\n}\n\ninterface FilePropertyBag {\n type?: string;\n lastModified?: number;\n}\n\ninterface EventListenerObject {\n handleEvent(evt: Event): void;\n}\n\ninterface ProgressEventInit extends EventInit {\n lengthComputable?: boolean;\n loaded?: number;\n total?: number;\n}\n\ninterface ScrollOptions {\n behavior?: ScrollBehavior;\n}\n\ninterface ScrollToOptions extends ScrollOptions {\n left?: number;\n top?: number;\n}\n\ninterface ScrollIntoViewOptions extends ScrollOptions {\n block?: ScrollLogicalPosition;\n inline?: ScrollLogicalPosition;\n}\n\ninterface ClipboardEventInit extends EventInit {\n data?: string;\n dataType?: string;\n}\n\ninterface IDBArrayKey extends Array {\n}\n\ninterface RsaKeyGenParams extends Algorithm {\n modulusLength: number;\n publicExponent: Uint8Array;\n}\n\ninterface RsaHashedKeyGenParams extends RsaKeyGenParams {\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaKeyAlgorithm extends KeyAlgorithm {\n modulusLength: number;\n publicExponent: Uint8Array;\n}\n\ninterface RsaHashedKeyAlgorithm extends RsaKeyAlgorithm {\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaHashedImportParams {\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaPssParams {\n saltLength: number;\n}\n\ninterface RsaOaepParams extends Algorithm {\n label?: BufferSource;\n}\n\ninterface EcdsaParams extends Algorithm {\n hash: AlgorithmIdentifier;\n}\n\ninterface EcKeyGenParams extends Algorithm {\n namedCurve: string;\n}\n\ninterface EcKeyAlgorithm extends KeyAlgorithm {\n typedCurve: string;\n}\n\ninterface EcKeyImportParams {\n namedCurve: string;\n}\n\ninterface EcdhKeyDeriveParams extends Algorithm {\n public: CryptoKey;\n}\n\ninterface AesCtrParams extends Algorithm {\n counter: BufferSource;\n length: number;\n}\n\ninterface AesKeyAlgorithm extends KeyAlgorithm {\n length: number;\n}\n\ninterface AesKeyGenParams extends Algorithm {\n length: number;\n}\n\ninterface AesDerivedKeyParams extends Algorithm {\n length: number;\n}\n\ninterface AesCbcParams extends Algorithm {\n iv: BufferSource;\n}\n\ninterface AesCmacParams extends Algorithm {\n length: number;\n}\n\ninterface AesGcmParams extends Algorithm {\n iv: BufferSource;\n additionalData?: BufferSource;\n tagLength?: number;\n}\n\ninterface AesCfbParams extends Algorithm {\n iv: BufferSource;\n}\n\ninterface HmacImportParams extends Algorithm {\n hash?: AlgorithmIdentifier;\n length?: number;\n}\n\ninterface HmacKeyAlgorithm extends KeyAlgorithm {\n hash: AlgorithmIdentifier;\n length: number;\n}\n\ninterface HmacKeyGenParams extends Algorithm {\n hash: AlgorithmIdentifier;\n length?: number;\n}\n\ninterface DhKeyGenParams extends Algorithm {\n prime: Uint8Array;\n generator: Uint8Array;\n}\n\ninterface DhKeyAlgorithm extends KeyAlgorithm {\n prime: Uint8Array;\n generator: Uint8Array;\n}\n\ninterface DhKeyDeriveParams extends Algorithm {\n public: CryptoKey;\n}\n\ninterface DhImportKeyParams extends Algorithm {\n prime: Uint8Array;\n generator: Uint8Array;\n}\n\ninterface ConcatParams extends Algorithm {\n hash?: AlgorithmIdentifier;\n algorithmId: Uint8Array;\n partyUInfo: Uint8Array;\n partyVInfo: Uint8Array;\n publicInfo?: Uint8Array;\n privateInfo?: Uint8Array;\n}\n\ninterface HkdfCtrParams extends Algorithm {\n hash: AlgorithmIdentifier;\n label: BufferSource;\n context: BufferSource;\n}\n\ninterface Pbkdf2Params extends Algorithm {\n salt: BufferSource;\n iterations: number;\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaOtherPrimesInfo {\n r: string;\n d: string;\n t: string;\n}\n\ninterface JsonWebKey {\n kty: string;\n use?: string;\n key_ops?: string[];\n alg?: string;\n kid?: string;\n x5u?: string;\n x5c?: string;\n x5t?: string;\n ext?: boolean;\n crv?: string;\n x?: string;\n y?: string;\n d?: string;\n n?: string;\n e?: string;\n p?: string;\n q?: string;\n dp?: string;\n dq?: string;\n qi?: string;\n oth?: RsaOtherPrimesInfo[];\n k?: string;\n}\n\ninterface ParentNode {\n readonly children: HTMLCollection;\n readonly firstElementChild: Element | null;\n readonly lastElementChild: Element | null;\n readonly childElementCount: number;\n}\n\ninterface DocumentOrShadowRoot {\n readonly activeElement: Element | null;\n readonly stylesheets: StyleSheetList;\n getSelection(): Selection | null;\n elementFromPoint(x: number, y: number): Element | null;\n elementsFromPoint(x: number, y: number): Element[];\n}\n\ninterface ShadowRoot extends DocumentOrShadowRoot, DocumentFragment {\n readonly host: Element;\n innerHTML: string;\n}\n\ninterface ShadowRootInit {\n mode: \"open\" | \"closed\";\n delegatesFocus?: boolean;\n}\n\ninterface HTMLSlotElement extends HTMLElement {\n name: string;\n assignedNodes(options?: AssignedNodesOptions): Node[];\n}\n\ninterface AssignedNodesOptions {\n flatten?: boolean;\n}\n\ninterface ElementDefinitionOptions {\n extends: string;\n}\n\ninterface CustomElementRegistry {\n define(name: string, constructor: Function, options?: ElementDefinitionOptions): void;\n get(name: string): any;\n whenDefined(name: string): PromiseLike;\n}\n\ninterface PromiseRejectionEvent extends Event {\n readonly promise: PromiseLike;\n readonly reason: any;\n}\n\ninterface PromiseRejectionEventInit extends EventInit {\n promise: PromiseLike;\n reason?: any;\n}\n\ninterface EventListenerOptions {\n capture?: boolean;\n}\n\ninterface AddEventListenerOptions extends EventListenerOptions {\n passive?: boolean;\n once?: boolean;\n}\n\ninterface TouchEventInit extends EventModifierInit {\n touches?: Touch[];\n targetTouches?: Touch[];\n changedTouches?: Touch[];\n}\n\ndeclare type EventListenerOrEventListenerObject = EventListener | EventListenerObject;\n\ninterface DecodeErrorCallback {\n (error: DOMException): void;\n}\ninterface DecodeSuccessCallback {\n (decodedData: AudioBuffer): void;\n}\ninterface ErrorEventHandler {\n (message: string, filename?: string, lineno?: number, colno?: number, error?: Error): void;\n}\ninterface ForEachCallback {\n (keyId: any, status: MediaKeyStatus): void;\n}\ninterface FrameRequestCallback {\n (time: number): void;\n}\ninterface FunctionStringCallback {\n (data: string): void;\n}\ninterface IntersectionObserverCallback {\n (entries: IntersectionObserverEntry[], observer: IntersectionObserver): void;\n}\ninterface MediaQueryListListener {\n (mql: MediaQueryList): void;\n}\ninterface MSExecAtPriorityFunctionCallback {\n (...args: any[]): any;\n}\ninterface MSLaunchUriCallback {\n (): void;\n}\ninterface MSUnsafeFunctionCallback {\n (): any;\n}\ninterface MutationCallback {\n (mutations: MutationRecord[], observer: MutationObserver): void;\n}\ninterface NavigatorUserMediaErrorCallback {\n (error: MediaStreamError): void;\n}\ninterface NavigatorUserMediaSuccessCallback {\n (stream: MediaStream): void;\n}\ninterface NotificationPermissionCallback {\n (permission: NotificationPermission): void;\n}\ninterface PositionCallback {\n (position: Position): void;\n}\ninterface PositionErrorCallback {\n (error: PositionError): void;\n}\ninterface RTCPeerConnectionErrorCallback {\n (error: DOMError): void;\n}\ninterface RTCSessionDescriptionCallback {\n (sdp: RTCSessionDescription): void;\n}\ninterface RTCStatsCallback {\n (report: RTCStatsReport): void;\n}\ninterface VoidFunction {\n (): void;\n}\ninterface HTMLElementTagNameMap {\n \"a\": HTMLAnchorElement;\n \"applet\": HTMLAppletElement;\n \"area\": HTMLAreaElement;\n \"audio\": HTMLAudioElement;\n \"base\": HTMLBaseElement;\n \"basefont\": HTMLBaseFontElement;\n \"blockquote\": HTMLQuoteElement;\n \"body\": HTMLBodyElement;\n \"br\": HTMLBRElement;\n \"button\": HTMLButtonElement;\n \"canvas\": HTMLCanvasElement;\n \"caption\": HTMLTableCaptionElement;\n \"col\": HTMLTableColElement;\n \"colgroup\": HTMLTableColElement;\n \"data\": HTMLDataElement;\n \"datalist\": HTMLDataListElement;\n \"del\": HTMLModElement;\n \"dir\": HTMLDirectoryElement;\n \"div\": HTMLDivElement;\n \"dl\": HTMLDListElement;\n \"embed\": HTMLEmbedElement;\n \"fieldset\": HTMLFieldSetElement;\n \"font\": HTMLFontElement;\n \"form\": HTMLFormElement;\n \"frame\": HTMLFrameElement;\n \"frameset\": HTMLFrameSetElement;\n \"h1\": HTMLHeadingElement;\n \"h2\": HTMLHeadingElement;\n \"h3\": HTMLHeadingElement;\n \"h4\": HTMLHeadingElement;\n \"h5\": HTMLHeadingElement;\n \"h6\": HTMLHeadingElement;\n \"head\": HTMLHeadElement;\n \"hr\": HTMLHRElement;\n \"html\": HTMLHtmlElement;\n \"iframe\": HTMLIFrameElement;\n \"img\": HTMLImageElement;\n \"input\": HTMLInputElement;\n \"ins\": HTMLModElement;\n \"isindex\": HTMLUnknownElement;\n \"label\": HTMLLabelElement;\n \"legend\": HTMLLegendElement;\n \"li\": HTMLLIElement;\n \"link\": HTMLLinkElement;\n \"listing\": HTMLPreElement;\n \"map\": HTMLMapElement;\n \"marquee\": HTMLMarqueeElement;\n \"menu\": HTMLMenuElement;\n \"meta\": HTMLMetaElement;\n \"meter\": HTMLMeterElement;\n \"nextid\": HTMLUnknownElement;\n \"object\": HTMLObjectElement;\n \"ol\": HTMLOListElement;\n \"optgroup\": HTMLOptGroupElement;\n \"option\": HTMLOptionElement;\n \"output\": HTMLOutputElement;\n \"p\": HTMLParagraphElement;\n \"param\": HTMLParamElement;\n \"picture\": HTMLPictureElement;\n \"pre\": HTMLPreElement;\n \"progress\": HTMLProgressElement;\n \"q\": HTMLQuoteElement;\n \"script\": HTMLScriptElement;\n \"select\": HTMLSelectElement;\n \"source\": HTMLSourceElement;\n \"span\": HTMLSpanElement;\n \"style\": HTMLStyleElement;\n \"table\": HTMLTableElement;\n \"tbody\": HTMLTableSectionElement;\n \"td\": HTMLTableDataCellElement;\n \"template\": HTMLTemplateElement;\n \"textarea\": HTMLTextAreaElement;\n \"tfoot\": HTMLTableSectionElement;\n \"th\": HTMLTableHeaderCellElement;\n \"thead\": HTMLTableSectionElement;\n \"time\": HTMLTimeElement;\n \"title\": HTMLTitleElement;\n \"tr\": HTMLTableRowElement;\n \"track\": HTMLTrackElement;\n \"ul\": HTMLUListElement;\n \"video\": HTMLVideoElement;\n \"x-ms-webview\": MSHTMLWebViewElement;\n \"xmp\": HTMLPreElement;\n}\n\ninterface ElementTagNameMap extends HTMLElementTagNameMap {\n \"abbr\": HTMLElement;\n \"acronym\": HTMLElement;\n \"address\": HTMLElement;\n \"article\": HTMLElement;\n \"aside\": HTMLElement;\n \"b\": HTMLElement;\n \"bdo\": HTMLElement;\n \"big\": HTMLElement;\n \"center\": HTMLElement;\n \"circle\": SVGCircleElement;\n \"cite\": HTMLElement;\n \"clippath\": SVGClipPathElement;\n \"code\": HTMLElement;\n \"dd\": HTMLElement;\n \"defs\": SVGDefsElement;\n \"desc\": SVGDescElement;\n \"dfn\": HTMLElement;\n \"dt\": HTMLElement;\n \"ellipse\": SVGEllipseElement;\n \"em\": HTMLElement;\n \"feblend\": SVGFEBlendElement;\n \"fecolormatrix\": SVGFEColorMatrixElement;\n \"fecomponenttransfer\": SVGFEComponentTransferElement;\n \"fecomposite\": SVGFECompositeElement;\n \"feconvolvematrix\": SVGFEConvolveMatrixElement;\n \"fediffuselighting\": SVGFEDiffuseLightingElement;\n \"fedisplacementmap\": SVGFEDisplacementMapElement;\n \"fedistantlight\": SVGFEDistantLightElement;\n \"feflood\": SVGFEFloodElement;\n \"fefunca\": SVGFEFuncAElement;\n \"fefuncb\": SVGFEFuncBElement;\n \"fefuncg\": SVGFEFuncGElement;\n \"fefuncr\": SVGFEFuncRElement;\n \"fegaussianblur\": SVGFEGaussianBlurElement;\n \"feimage\": SVGFEImageElement;\n \"femerge\": SVGFEMergeElement;\n \"femergenode\": SVGFEMergeNodeElement;\n \"femorphology\": SVGFEMorphologyElement;\n \"feoffset\": SVGFEOffsetElement;\n \"fepointlight\": SVGFEPointLightElement;\n \"fespecularlighting\": SVGFESpecularLightingElement;\n \"fespotlight\": SVGFESpotLightElement;\n \"fetile\": SVGFETileElement;\n \"feturbulence\": SVGFETurbulenceElement;\n \"figcaption\": HTMLElement;\n \"figure\": HTMLElement;\n \"filter\": SVGFilterElement;\n \"footer\": HTMLElement;\n \"foreignobject\": SVGForeignObjectElement;\n \"g\": SVGGElement;\n \"header\": HTMLElement;\n \"hgroup\": HTMLElement;\n \"i\": HTMLElement;\n \"image\": SVGImageElement;\n \"kbd\": HTMLElement;\n \"keygen\": HTMLElement;\n \"line\": SVGLineElement;\n \"lineargradient\": SVGLinearGradientElement;\n \"mark\": HTMLElement;\n \"marker\": SVGMarkerElement;\n \"mask\": SVGMaskElement;\n \"metadata\": SVGMetadataElement;\n \"nav\": HTMLElement;\n \"nobr\": HTMLElement;\n \"noframes\": HTMLElement;\n \"noscript\": HTMLElement;\n \"path\": SVGPathElement;\n \"pattern\": SVGPatternElement;\n \"plaintext\": HTMLElement;\n \"polygon\": SVGPolygonElement;\n \"polyline\": SVGPolylineElement;\n \"radialgradient\": SVGRadialGradientElement;\n \"rect\": SVGRectElement;\n \"rt\": HTMLElement;\n \"ruby\": HTMLElement;\n \"s\": HTMLElement;\n \"samp\": HTMLElement;\n \"section\": HTMLElement;\n \"small\": HTMLElement;\n \"stop\": SVGStopElement;\n \"strike\": HTMLElement;\n \"strong\": HTMLElement;\n \"sub\": HTMLElement;\n \"sup\": HTMLElement;\n \"svg\": SVGSVGElement;\n \"switch\": SVGSwitchElement;\n \"symbol\": SVGSymbolElement;\n \"text\": SVGTextElement;\n \"textpath\": SVGTextPathElement;\n \"tspan\": SVGTSpanElement;\n \"tt\": HTMLElement;\n \"u\": HTMLElement;\n \"use\": SVGUseElement;\n \"var\": HTMLElement;\n \"view\": SVGViewElement;\n \"wbr\": HTMLElement;\n}\n\ntype ElementListTagNameMap = {\n [key in keyof ElementTagNameMap]: NodeListOf\n};\n\ndeclare var Audio: { new(src?: string): HTMLAudioElement; };\ndeclare var Image: { new(width?: number, height?: number): HTMLImageElement; };\ndeclare var Option: { new(text?: string, value?: string, defaultSelected?: boolean, selected?: boolean): HTMLOptionElement; };\ndeclare var applicationCache: ApplicationCache;\ndeclare var caches: CacheStorage;\ndeclare var clientInformation: Navigator;\ndeclare var closed: boolean;\ndeclare var crypto: Crypto;\ndeclare var defaultStatus: string;\ndeclare var devicePixelRatio: number;\ndeclare var document: Document;\ndeclare var doNotTrack: string;\ndeclare var event: Event | undefined;\ndeclare var external: External;\ndeclare var frameElement: Element;\ndeclare var frames: Window;\ndeclare var history: History;\ndeclare var innerHeight: number;\ndeclare var innerWidth: number;\ndeclare var isSecureContext: boolean;\ndeclare var length: number;\ndeclare var location: Location;\ndeclare var locationbar: BarProp;\ndeclare var menubar: BarProp;\ndeclare var msContentScript: ExtensionScriptApis;\ndeclare var msCredentials: MSCredentials;\ndeclare const name: never;\ndeclare var navigator: Navigator;\ndeclare var offscreenBuffering: string | boolean;\ndeclare var onabort: (this: Window, ev: UIEvent) => any;\ndeclare var onafterprint: (this: Window, ev: Event) => any;\ndeclare var onbeforeprint: (this: Window, ev: Event) => any;\ndeclare var onbeforeunload: (this: Window, ev: BeforeUnloadEvent) => any;\ndeclare var onblur: (this: Window, ev: FocusEvent) => any;\ndeclare var oncanplay: (this: Window, ev: Event) => any;\ndeclare var oncanplaythrough: (this: Window, ev: Event) => any;\ndeclare var onchange: (this: Window, ev: Event) => any;\ndeclare var onclick: (this: Window, ev: MouseEvent) => any;\ndeclare var oncompassneedscalibration: (this: Window, ev: Event) => any;\ndeclare var oncontextmenu: (this: Window, ev: PointerEvent) => any;\ndeclare var ondblclick: (this: Window, ev: MouseEvent) => any;\ndeclare var ondevicelight: (this: Window, ev: DeviceLightEvent) => any;\ndeclare var ondevicemotion: (this: Window, ev: DeviceMotionEvent) => any;\ndeclare var ondeviceorientation: (this: Window, ev: DeviceOrientationEvent) => any;\ndeclare var ondrag: (this: Window, ev: DragEvent) => any;\ndeclare var ondragend: (this: Window, ev: DragEvent) => any;\ndeclare var ondragenter: (this: Window, ev: DragEvent) => any;\ndeclare var ondragleave: (this: Window, ev: DragEvent) => any;\ndeclare var ondragover: (this: Window, ev: DragEvent) => any;\ndeclare var ondragstart: (this: Window, ev: DragEvent) => any;\ndeclare var ondrop: (this: Window, ev: DragEvent) => any;\ndeclare var ondurationchange: (this: Window, ev: Event) => any;\ndeclare var onemptied: (this: Window, ev: Event) => any;\ndeclare var onended: (this: Window, ev: MediaStreamErrorEvent) => any;\ndeclare var onerror: ErrorEventHandler;\ndeclare var onfocus: (this: Window, ev: FocusEvent) => any;\ndeclare var onhashchange: (this: Window, ev: HashChangeEvent) => any;\ndeclare var oninput: (this: Window, ev: Event) => any;\ndeclare var oninvalid: (this: Window, ev: Event) => any;\ndeclare var onkeydown: (this: Window, ev: KeyboardEvent) => any;\ndeclare var onkeypress: (this: Window, ev: KeyboardEvent) => any;\ndeclare var onkeyup: (this: Window, ev: KeyboardEvent) => any;\ndeclare var onload: (this: Window, ev: Event) => any;\ndeclare var onloadeddata: (this: Window, ev: Event) => any;\ndeclare var onloadedmetadata: (this: Window, ev: Event) => any;\ndeclare var onloadstart: (this: Window, ev: Event) => any;\ndeclare var onmessage: (this: Window, ev: MessageEvent) => any;\ndeclare var onmousedown: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseenter: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseleave: (this: Window, ev: MouseEvent) => any;\ndeclare var onmousemove: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseout: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseover: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseup: (this: Window, ev: MouseEvent) => any;\ndeclare var onmousewheel: (this: Window, ev: WheelEvent) => any;\ndeclare var onmsgesturechange: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturedoubletap: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgestureend: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturehold: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturestart: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturetap: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsinertiastart: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmspointercancel: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerdown: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerenter: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerleave: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointermove: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerout: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerover: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerup: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onoffline: (this: Window, ev: Event) => any;\ndeclare var ononline: (this: Window, ev: Event) => any;\ndeclare var onorientationchange: (this: Window, ev: Event) => any;\ndeclare var onpagehide: (this: Window, ev: PageTransitionEvent) => any;\ndeclare var onpageshow: (this: Window, ev: PageTransitionEvent) => any;\ndeclare var onpause: (this: Window, ev: Event) => any;\ndeclare var onplay: (this: Window, ev: Event) => any;\ndeclare var onplaying: (this: Window, ev: Event) => any;\ndeclare var onpopstate: (this: Window, ev: PopStateEvent) => any;\ndeclare var onprogress: (this: Window, ev: ProgressEvent) => any;\ndeclare var onratechange: (this: Window, ev: Event) => any;\ndeclare var onreadystatechange: (this: Window, ev: ProgressEvent) => any;\ndeclare var onreset: (this: Window, ev: Event) => any;\ndeclare var onresize: (this: Window, ev: UIEvent) => any;\ndeclare var onscroll: (this: Window, ev: UIEvent) => any;\ndeclare var onseeked: (this: Window, ev: Event) => any;\ndeclare var onseeking: (this: Window, ev: Event) => any;\ndeclare var onselect: (this: Window, ev: UIEvent) => any;\ndeclare var onstalled: (this: Window, ev: Event) => any;\ndeclare var onstorage: (this: Window, ev: StorageEvent) => any;\ndeclare var onsubmit: (this: Window, ev: Event) => any;\ndeclare var onsuspend: (this: Window, ev: Event) => any;\ndeclare var ontimeupdate: (this: Window, ev: Event) => any;\ndeclare var ontouchcancel: (ev: TouchEvent) => any;\ndeclare var ontouchend: (ev: TouchEvent) => any;\ndeclare var ontouchmove: (ev: TouchEvent) => any;\ndeclare var ontouchstart: (ev: TouchEvent) => any;\ndeclare var onunload: (this: Window, ev: Event) => any;\ndeclare var onvolumechange: (this: Window, ev: Event) => any;\ndeclare var onwaiting: (this: Window, ev: Event) => any;\ndeclare var opener: any;\ndeclare var orientation: string | number;\ndeclare var outerHeight: number;\ndeclare var outerWidth: number;\ndeclare var pageXOffset: number;\ndeclare var pageYOffset: number;\ndeclare var parent: Window;\ndeclare var performance: Performance;\ndeclare var personalbar: BarProp;\ndeclare var screen: Screen;\ndeclare var screenLeft: number;\ndeclare var screenTop: number;\ndeclare var screenX: number;\ndeclare var screenY: number;\ndeclare var scrollbars: BarProp;\ndeclare var scrollX: number;\ndeclare var scrollY: number;\ndeclare var self: Window;\ndeclare var speechSynthesis: SpeechSynthesis;\ndeclare var status: string;\ndeclare var statusbar: BarProp;\ndeclare var styleMedia: StyleMedia;\ndeclare var toolbar: BarProp;\ndeclare var top: Window;\ndeclare var window: Window;\ndeclare var customElements: CustomElementRegistry;\ndeclare function alert(message?: any): void;\ndeclare function blur(): void;\ndeclare function cancelAnimationFrame(handle: number): void;\ndeclare function captureEvents(): void;\ndeclare function close(): void;\ndeclare function confirm(message?: string): boolean;\ndeclare function departFocus(navigationReason: NavigationReason, origin: FocusNavigationOrigin): void;\ndeclare function focus(): void;\ndeclare function getComputedStyle(elt: Element, pseudoElt?: string): CSSStyleDeclaration;\ndeclare function getMatchedCSSRules(elt: Element, pseudoElt?: string): CSSRuleList;\ndeclare function getSelection(): Selection;\ndeclare function matchMedia(mediaQuery: string): MediaQueryList;\ndeclare function moveBy(x?: number, y?: number): void;\ndeclare function moveTo(x?: number, y?: number): void;\ndeclare function msWriteProfilerMark(profilerMarkName: string): void;\ndeclare function open(url?: string, target?: string, features?: string, replace?: boolean): Window;\ndeclare function postMessage(message: any, targetOrigin: string, transfer?: any[]): void;\ndeclare function print(): void;\ndeclare function prompt(message?: string, _default?: string): string | null;\ndeclare function releaseEvents(): void;\ndeclare function requestAnimationFrame(callback: FrameRequestCallback): number;\ndeclare function resizeBy(x?: number, y?: number): void;\ndeclare function resizeTo(x?: number, y?: number): void;\ndeclare function scroll(x?: number, y?: number): void;\ndeclare function scrollBy(x?: number, y?: number): void;\ndeclare function scrollTo(x?: number, y?: number): void;\ndeclare function stop(): void;\ndeclare function webkitCancelAnimationFrame(handle: number): void;\ndeclare function webkitConvertPointFromNodeToPage(node: Node, pt: WebKitPoint): WebKitPoint;\ndeclare function webkitConvertPointFromPageToNode(node: Node, pt: WebKitPoint): WebKitPoint;\ndeclare function webkitRequestAnimationFrame(callback: FrameRequestCallback): number;\ndeclare function createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, options?: ImageBitmapOptions): Promise;\ndeclare function createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, sx: number, sy: number, sw: number, sh: number, options?: ImageBitmapOptions): Promise;\ndeclare function scroll(options?: ScrollToOptions): void;\ndeclare function scrollTo(options?: ScrollToOptions): void;\ndeclare function scrollBy(options?: ScrollToOptions): void;\ndeclare function toString(): string;\ndeclare function dispatchEvent(evt: Event): boolean;\ndeclare function removeEventListener(type: string, listener?: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;\ndeclare function clearInterval(handle: number): void;\ndeclare function clearTimeout(handle: number): void;\ndeclare function setInterval(handler: (...args: any[]) => void, timeout: number): number;\ndeclare function setInterval(handler: any, timeout?: any, ...args: any[]): number;\ndeclare function setTimeout(handler: (...args: any[]) => void, timeout: number): number;\ndeclare function setTimeout(handler: any, timeout?: any, ...args: any[]): number;\ndeclare function clearImmediate(handle: number): void;\ndeclare function setImmediate(handler: (...args: any[]) => void): number;\ndeclare function setImmediate(handler: any, ...args: any[]): number;\ndeclare var sessionStorage: Storage;\ndeclare var localStorage: Storage;\ndeclare var console: Console;\ndeclare var onpointercancel: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerdown: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerenter: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerleave: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointermove: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerout: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerover: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerup: (this: Window, ev: PointerEvent) => any;\ndeclare var onwheel: (this: Window, ev: WheelEvent) => any;\ndeclare var indexedDB: IDBFactory;\ndeclare function atob(encodedString: string): string;\ndeclare function btoa(rawString: string): string;\ndeclare function fetch(input: RequestInfo, init?: RequestInit): Promise;\ndeclare function addEventListener(type: K, listener: (this: Window, ev: WindowEventMap[K]) => any, useCapture?: boolean): void;\ndeclare function addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\ntype AAGUID = string;\ntype AlgorithmIdentifier = string | Algorithm;\ntype BodyInit = any;\ntype ByteString = string;\ntype ConstrainBoolean = boolean | ConstrainBooleanParameters;\ntype ConstrainDOMString = string | string[] | ConstrainDOMStringParameters;\ntype ConstrainDouble = number | ConstrainDoubleRange;\ntype ConstrainLong = number | ConstrainLongRange;\ntype CryptoOperationData = ArrayBufferView;\ntype GLbitfield = number;\ntype GLboolean = boolean;\ntype GLbyte = number;\ntype GLclampf = number;\ntype GLenum = number;\ntype GLfloat = number;\ntype GLint = number;\ntype GLintptr = number;\ntype GLshort = number;\ntype GLsizei = number;\ntype GLsizeiptr = number;\ntype GLubyte = number;\ntype GLuint = number;\ntype GLushort = number;\ntype HeadersInit = any;\ntype IDBKeyPath = string;\ntype KeyFormat = string;\ntype KeyType = string;\ntype KeyUsage = string;\ntype MSInboundPayload = MSVideoRecvPayload | MSAudioRecvPayload;\ntype MSLocalClientEvent = MSLocalClientEventBase | MSAudioLocalClientEvent;\ntype MSOutboundPayload = MSVideoSendPayload | MSAudioSendPayload;\ntype RTCIceGatherCandidate = RTCIceCandidateDictionary | RTCIceCandidateComplete;\ntype RTCTransport = RTCDtlsTransport | RTCSrtpSdesTransport;\ntype RequestInfo = Request | string;\ntype USVString = string;\ntype payloadtype = number;\ntype ScrollBehavior = \"auto\" | \"instant\" | \"smooth\";\ntype ScrollLogicalPosition = \"start\" | \"center\" | \"end\" | \"nearest\";\ntype IDBValidKey = number | string | Date | IDBArrayKey;\ntype BufferSource = ArrayBuffer | ArrayBufferView;\ntype MouseWheelEvent = WheelEvent;\ntype ScrollRestoration = \"auto\" | \"manual\";\ntype FormDataEntryValue = string | File;\ntype InsertPosition = \"beforebegin\" | \"afterbegin\" | \"beforeend\" | \"afterend\";\ntype AppendMode = \"segments\" | \"sequence\";\ntype AudioContextState = \"suspended\" | \"running\" | \"closed\";\ntype BiquadFilterType = \"lowpass\" | \"highpass\" | \"bandpass\" | \"lowshelf\" | \"highshelf\" | \"peaking\" | \"notch\" | \"allpass\";\ntype CanvasFillRule = \"nonzero\" | \"evenodd\";\ntype ChannelCountMode = \"max\" | \"clamped-max\" | \"explicit\";\ntype ChannelInterpretation = \"speakers\" | \"discrete\";\ntype DistanceModelType = \"linear\" | \"inverse\" | \"exponential\";\ntype ExpandGranularity = \"character\" | \"word\" | \"sentence\" | \"textedit\";\ntype GamepadInputEmulationType = \"mouse\" | \"keyboard\" | \"gamepad\";\ntype IDBCursorDirection = \"next\" | \"nextunique\" | \"prev\" | \"prevunique\";\ntype IDBRequestReadyState = \"pending\" | \"done\";\ntype IDBTransactionMode = \"readonly\" | \"readwrite\" | \"versionchange\";\ntype ListeningState = \"inactive\" | \"active\" | \"disambiguation\";\ntype MediaDeviceKind = \"audioinput\" | \"audiooutput\" | \"videoinput\";\ntype MediaKeyMessageType = \"license-request\" | \"license-renewal\" | \"license-release\" | \"individualization-request\";\ntype MediaKeySessionType = \"temporary\" | \"persistent-license\" | \"persistent-release-message\";\ntype MediaKeysRequirement = \"required\" | \"optional\" | \"not-allowed\";\ntype MediaKeyStatus = \"usable\" | \"expired\" | \"output-downscaled\" | \"output-not-allowed\" | \"status-pending\" | \"internal-error\";\ntype MediaStreamTrackState = \"live\" | \"ended\";\ntype MSCredentialType = \"FIDO_2_0\";\ntype MSIceAddrType = \"os\" | \"stun\" | \"turn\" | \"peer-derived\";\ntype MSIceType = \"failed\" | \"direct\" | \"relay\";\ntype MSStatsType = \"description\" | \"localclientevent\" | \"inbound-network\" | \"outbound-network\" | \"inbound-payload\" | \"outbound-payload\" | \"transportdiagnostics\";\ntype MSTransportType = \"Embedded\" | \"USB\" | \"NFC\" | \"BT\";\ntype MSWebViewPermissionState = \"unknown\" | \"defer\" | \"allow\" | \"deny\";\ntype MSWebViewPermissionType = \"geolocation\" | \"unlimitedIndexedDBQuota\" | \"media\" | \"pointerlock\" | \"webnotifications\";\ntype NavigationReason = \"up\" | \"down\" | \"left\" | \"right\";\ntype NavigationType = \"navigate\" | \"reload\" | \"back_forward\" | \"prerender\";\ntype NotificationDirection = \"auto\" | \"ltr\" | \"rtl\";\ntype NotificationPermission = \"default\" | \"denied\" | \"granted\";\ntype OscillatorType = \"sine\" | \"square\" | \"sawtooth\" | \"triangle\" | \"custom\";\ntype OverSampleType = \"none\" | \"2x\" | \"4x\";\ntype PanningModelType = \"equalpower\";\ntype PaymentComplete = \"success\" | \"fail\" | \"\";\ntype PaymentShippingType = \"shipping\" | \"delivery\" | \"pickup\";\ntype PushEncryptionKeyName = \"p256dh\" | \"auth\";\ntype PushPermissionState = \"granted\" | \"denied\" | \"prompt\";\ntype ReferrerPolicy = \"\" | \"no-referrer\" | \"no-referrer-when-downgrade\" | \"origin-only\" | \"origin-when-cross-origin\" | \"unsafe-url\";\ntype RequestCache = \"default\" | \"no-store\" | \"reload\" | \"no-cache\" | \"force-cache\";\ntype RequestCredentials = \"omit\" | \"same-origin\" | \"include\";\ntype RequestDestination = \"\" | \"document\" | \"sharedworker\" | \"subresource\" | \"unknown\" | \"worker\";\ntype RequestMode = \"navigate\" | \"same-origin\" | \"no-cors\" | \"cors\";\ntype RequestRedirect = \"follow\" | \"error\" | \"manual\";\ntype RequestType = \"\" | \"audio\" | \"font\" | \"image\" | \"script\" | \"style\" | \"track\" | \"video\";\ntype ResponseType = \"basic\" | \"cors\" | \"default\" | \"error\" | \"opaque\" | \"opaqueredirect\";\ntype RTCBundlePolicy = \"balanced\" | \"max-compat\" | \"max-bundle\";\ntype RTCDegradationPreference = \"maintain-framerate\" | \"maintain-resolution\" | \"balanced\";\ntype RTCDtlsRole = \"auto\" | \"client\" | \"server\";\ntype RTCDtlsTransportState = \"new\" | \"connecting\" | \"connected\" | \"closed\";\ntype RTCIceCandidateType = \"host\" | \"srflx\" | \"prflx\" | \"relay\";\ntype RTCIceComponent = \"RTP\" | \"RTCP\";\ntype RTCIceConnectionState = \"new\" | \"checking\" | \"connected\" | \"completed\" | \"failed\" | \"disconnected\" | \"closed\";\ntype RTCIceGathererState = \"new\" | \"gathering\" | \"complete\";\ntype RTCIceGatheringState = \"new\" | \"gathering\" | \"complete\";\ntype RTCIceGatherPolicy = \"all\" | \"nohost\" | \"relay\";\ntype RTCIceProtocol = \"udp\" | \"tcp\";\ntype RTCIceRole = \"controlling\" | \"controlled\";\ntype RTCIceTcpCandidateType = \"active\" | \"passive\" | \"so\";\ntype RTCIceTransportPolicy = \"none\" | \"relay\" | \"all\";\ntype RTCIceTransportState = \"new\" | \"checking\" | \"connected\" | \"completed\" | \"disconnected\" | \"closed\";\ntype RTCSdpType = \"offer\" | \"pranswer\" | \"answer\";\ntype RTCSignalingState = \"stable\" | \"have-local-offer\" | \"have-remote-offer\" | \"have-local-pranswer\" | \"have-remote-pranswer\" | \"closed\";\ntype RTCStatsIceCandidatePairState = \"frozen\" | \"waiting\" | \"inprogress\" | \"failed\" | \"succeeded\" | \"cancelled\";\ntype RTCStatsIceCandidateType = \"host\" | \"serverreflexive\" | \"peerreflexive\" | \"relayed\";\ntype RTCStatsType = \"inboundrtp\" | \"outboundrtp\" | \"session\" | \"datachannel\" | \"track\" | \"transport\" | \"candidatepair\" | \"localcandidate\" | \"remotecandidate\";\ntype ScopedCredentialType = \"ScopedCred\";\ntype ServiceWorkerState = \"installing\" | \"installed\" | \"activating\" | \"activated\" | \"redundant\";\ntype Transport = \"usb\" | \"nfc\" | \"ble\";\ntype VideoFacingModeEnum = \"user\" | \"environment\" | \"left\" | \"right\";\ntype VisibilityState = \"hidden\" | \"visible\" | \"prerender\" | \"unloaded\";\ntype XMLHttpRequestResponseType = \"\" | \"arraybuffer\" | \"blob\" | \"document\" | \"json\" | \"text\";\n\n\n/////////////////////////////\n/// WorkerGlobalScope APIs\n/////////////////////////////\n// These are only available in a Web Worker\ndeclare function importScripts(...urls: string[]): void;\n\n\n\n\n/////////////////////////////\n/// Windows Script Host APIS\n/////////////////////////////\n\n\ninterface ActiveXObject {\n new (s: string): any;\n}\ndeclare var ActiveXObject: ActiveXObject;\n\ninterface ITextWriter {\n Write(s: string): void;\n WriteLine(s: string): void;\n Close(): void;\n}\n\ninterface TextStreamBase {\n /**\n * The column number of the current character position in an input stream.\n */\n Column: number;\n\n /**\n * The current line number in an input stream.\n */\n Line: number;\n\n /**\n * Closes a text stream.\n * It is not necessary to close standard streams; they close automatically when the process ends. If\n * you close a standard stream, be aware that any other pointers to that standard stream become invalid.\n */\n Close(): void;\n}\n\ninterface TextStreamWriter extends TextStreamBase {\n /**\n * Sends a string to an output stream.\n */\n Write(s: string): void;\n\n /**\n * Sends a specified number of blank lines (newline characters) to an output stream.\n */\n WriteBlankLines(intLines: number): void;\n\n /**\n * Sends a string followed by a newline character to an output stream.\n */\n WriteLine(s: string): void;\n}\n\ninterface TextStreamReader extends TextStreamBase {\n /**\n * Returns a specified number of characters from an input stream, starting at the current pointer position.\n * Does not return until the ENTER key is pressed.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n */\n Read(characters: number): string;\n\n /**\n * Returns all characters from an input stream.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n */\n ReadAll(): string;\n\n /**\n * Returns an entire line from an input stream.\n * Although this method extracts the newline character, it does not add it to the returned string.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n */\n ReadLine(): string;\n\n /**\n * Skips a specified number of characters when reading from an input text stream.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n * @param characters Positive number of characters to skip forward. (Backward skipping is not supported.)\n */\n Skip(characters: number): void;\n\n /**\n * Skips the next line when reading from an input text stream.\n * Can only be used on a stream in reading mode, not writing or appending mode.\n */\n SkipLine(): void;\n\n /**\n * Indicates whether the stream pointer position is at the end of a line.\n */\n AtEndOfLine: boolean;\n\n /**\n * Indicates whether the stream pointer position is at the end of a stream.\n */\n AtEndOfStream: boolean;\n}\n\ndeclare var WScript: {\n /**\n * Outputs text to either a message box (under WScript.exe) or the command console window followed by\n * a newline (under CScript.exe).\n */\n Echo(s: any): void;\n\n /**\n * Exposes the write-only error output stream for the current script.\n * Can be accessed only while using CScript.exe.\n */\n StdErr: TextStreamWriter;\n\n /**\n * Exposes the write-only output stream for the current script.\n * Can be accessed only while using CScript.exe.\n */\n StdOut: TextStreamWriter;\n Arguments: { length: number; Item(n: number): string; };\n\n /**\n * The full path of the currently running script.\n */\n ScriptFullName: string;\n\n /**\n * Forces the script to stop immediately, with an optional exit code.\n */\n Quit(exitCode?: number): number;\n\n /**\n * The Windows Script Host build version number.\n */\n BuildVersion: number;\n\n /**\n * Fully qualified path of the host executable.\n */\n FullName: string;\n\n /**\n * Gets/sets the script mode - interactive(true) or batch(false).\n */\n Interactive: boolean;\n\n /**\n * The name of the host executable (WScript.exe or CScript.exe).\n */\n Name: string;\n\n /**\n * Path of the directory containing the host executable.\n */\n Path: string;\n\n /**\n * The filename of the currently running script.\n */\n ScriptName: string;\n\n /**\n * Exposes the read-only input stream for the current script.\n * Can be accessed only while using CScript.exe.\n */\n StdIn: TextStreamReader;\n\n /**\n * Windows Script Host version\n */\n Version: string;\n\n /**\n * Connects a COM object's event sources to functions named with a given prefix, in the form prefix_event.\n */\n ConnectObject(objEventSource: any, strPrefix: string): void;\n\n /**\n * Creates a COM object.\n * @param strProgiID\n * @param strPrefix Function names in the form prefix_event will be bound to this object's COM events.\n */\n CreateObject(strProgID: string, strPrefix?: string): any;\n\n /**\n * Disconnects a COM object from its event sources.\n */\n DisconnectObject(obj: any): void;\n\n /**\n * Retrieves an existing object with the specified ProgID from memory, or creates a new one from a file.\n * @param strPathname Fully qualified path to the file containing the object persisted to disk.\n * For objects in memory, pass a zero-length string.\n * @param strProgID\n * @param strPrefix Function names in the form prefix_event will be bound to this object's COM events.\n */\n GetObject(strPathname: string, strProgID?: string, strPrefix?: string): any;\n\n /**\n * Suspends script execution for a specified length of time, then continues execution.\n * @param intTime Interval (in milliseconds) to suspend script execution.\n */\n Sleep(intTime: number): void;\n};\n\n/**\n * Allows enumerating over a COM collection, which may not have indexed item access.\n */\ninterface Enumerator {\n /**\n * Returns true if the current item is the last one in the collection, or the collection is empty,\n * or the current item is undefined.\n */\n atEnd(): boolean;\n\n /**\n * Returns the current item in the collection\n */\n item(): T;\n\n /**\n * Resets the current item in the collection to the first item. If there are no items in the collection,\n * the current item is set to undefined.\n */\n moveFirst(): void;\n\n /**\n * Moves the current item to the next item in the collection. If the enumerator is at the end of\n * the collection or the collection is empty, the current item is set to undefined.\n */\n moveNext(): void;\n}\n\ninterface EnumeratorConstructor {\n new (collection: any): Enumerator;\n new (collection: any): Enumerator;\n}\n\ndeclare var Enumerator: EnumeratorConstructor;\n\n/**\n * Enables reading from a COM safe array, which might have an alternate lower bound, or multiple dimensions.\n */\ninterface VBArray {\n /**\n * Returns the number of dimensions (1-based).\n */\n dimensions(): number;\n\n /**\n * Takes an index for each dimension in the array, and returns the item at the corresponding location.\n */\n getItem(dimension1Index: number, ...dimensionNIndexes: number[]): T;\n\n /**\n * Returns the smallest available index for a given dimension.\n * @param dimension 1-based dimension (defaults to 1)\n */\n lbound(dimension?: number): number;\n\n /**\n * Returns the largest available index for a given dimension.\n * @param dimension 1-based dimension (defaults to 1)\n */\n ubound(dimension?: number): number;\n\n /**\n * Returns a Javascript array with all the elements in the VBArray. If there are multiple dimensions,\n * each successive dimension is appended to the end of the array.\n * Example: [[1,2,3],[4,5,6]] becomes [1,2,3,4,5,6]\n */\n toArray(): T[];\n}\n\ninterface VBArrayConstructor {\n new (safeArray: any): VBArray;\n new (safeArray: any): VBArray;\n}\n\ndeclare var VBArray: VBArrayConstructor;\n\n/**\n * Automation date (VT_DATE)\n */\ninterface VarDate { }\n\ninterface DateConstructor {\n new (vd: VarDate): Date;\n}\n\ninterface Date {\n getVarDate: () => VarDate;\n}\n\n\n/// \n\ninterface DOMTokenList {\n [Symbol.iterator](): IterableIterator;\n}\n\ninterface FormData {\n /**\n * Returns an array of key, value pairs for every entry in the list\n */\n entries(): IterableIterator<[string, string | File]>;\n /**\n * Returns a list of keys in the list\n */\n keys(): IterableIterator;\n /**\n * Returns a list of values in the list\n */\n values(): IterableIterator;\n\n [Symbol.iterator](): IterableIterator;\n}\n\ninterface Headers {\n [Symbol.iterator](): IterableIterator<[string, string]>;\n /**\n * Returns an iterator allowing to go through all key/value pairs contained in this object.\n */\n entries(): IterableIterator<[string, string]>;\n /**\n * Returns an iterator allowing to go through all keys f the key/value pairs contained in this object.\n */\n keys(): IterableIterator;\n /**\n * Returns an iterator allowing to go through all values of the key/value pairs contained in this object.\n */\n values(): IterableIterator;\n}\n\ninterface NodeList {\n /**\n * Returns an array of key, value pairs for every entry in the list\n */\n entries(): IterableIterator<[number, Node]>;\n /**\n * Performs the specified action for each node in an list.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the list.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: Node, index: number, listObj: NodeList) => void, thisArg?: any): void;\n /**\n * Returns an list of keys in the list\n */\n keys(): IterableIterator;\n\n /**\n * Returns an list of values in the list\n */\n values(): IterableIterator;\n\n\n [Symbol.iterator](): IterableIterator;\n}\n\ninterface NodeListOf {\n\n /**\n * Returns an array of key, value pairs for every entry in the list\n */\n entries(): IterableIterator<[number, TNode]>;\n\n /**\n * Performs the specified action for each node in an list.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the list.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: TNode, index: number, listObj: NodeListOf) => void, thisArg?: any): void;\n /**\n * Returns an list of keys in the list\n */\n keys(): IterableIterator;\n /**\n * Returns an list of values in the list\n */\n values(): IterableIterator;\n\n [Symbol.iterator](): IterableIterator;\n}\n\ninterface URLSearchParams {\n /**\n * Returns an array of key, value pairs for every entry in the search params\n */\n entries(): IterableIterator<[string, string]>;\n /**\n * Returns a list of keys in the search params\n */\n keys(): IterableIterator;\n /**\n * Returns a list of values in the search params\n */\n values(): IterableIterator;\n /**\n * iterate over key/value pairs\n */\n [Symbol.iterator](): IterableIterator<[string, string]>;\n}\n"}; }); diff --git a/lib/lib-ts.js b/lib/lib-ts.js index 96b25caf..8e8d31da 100644 --- a/lib/lib-ts.js +++ b/lib/lib-ts.js @@ -5,5 +5,5 @@ // This is a generated file from lib.d.ts -define([], function() { return { contents: "/*! *****************************************************************************\nCopyright (c) Microsoft Corporation. All rights reserved. \nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\nthis file except in compliance with the License. You may obtain a copy of the\nLicense at http://www.apache.org/licenses/LICENSE-2.0 \n \nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, \nMERCHANTABLITY OR NON-INFRINGEMENT. \n \nSee the Apache Version 2.0 License for specific language governing permissions\nand limitations under the License.\n***************************************************************************** */\n\n\n\n/// \n\n\n/////////////////////////////\n/// ECMAScript APIs\n/////////////////////////////\n\ndeclare const NaN: number;\ndeclare const Infinity: number;\n\n/**\n * Evaluates JavaScript code and executes it.\n * @param x A String value that contains valid JavaScript code.\n */\ndeclare function eval(x: string): any;\n\n/**\n * Converts A string to an integer.\n * @param s A string to convert into a number.\n * @param radix A value between 2 and 36 that specifies the base of the number in numString.\n * If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\n * All other strings are considered decimal.\n */\ndeclare function parseInt(s: string, radix?: number): number;\n\n/**\n * Converts a string to a floating-point number.\n * @param string A string that contains a floating-point number.\n */\ndeclare function parseFloat(string: string): number;\n\n/**\n * Returns a Boolean value that indicates whether a value is the reserved value NaN (not a number).\n * @param number A numeric value.\n */\ndeclare function isNaN(number: number): boolean;\n\n/**\n * Determines whether a supplied number is finite.\n * @param number Any numeric value.\n */\ndeclare function isFinite(number: number): boolean;\n\n/**\n * Gets the unencoded version of an encoded Uniform Resource Identifier (URI).\n * @param encodedURI A value representing an encoded URI.\n */\ndeclare function decodeURI(encodedURI: string): string;\n\n/**\n * Gets the unencoded version of an encoded component of a Uniform Resource Identifier (URI).\n * @param encodedURIComponent A value representing an encoded URI component.\n */\ndeclare function decodeURIComponent(encodedURIComponent: string): string;\n\n/**\n * Encodes a text string as a valid Uniform Resource Identifier (URI)\n * @param uri A value representing an encoded URI.\n */\ndeclare function encodeURI(uri: string): string;\n\n/**\n * Encodes a text string as a valid component of a Uniform Resource Identifier (URI).\n * @param uriComponent A value representing an encoded URI component.\n */\ndeclare function encodeURIComponent(uriComponent: string): string;\n\ninterface PropertyDescriptor {\n configurable?: boolean;\n enumerable?: boolean;\n value?: any;\n writable?: boolean;\n get? (): any;\n set? (v: any): void;\n}\n\ninterface PropertyDescriptorMap {\n [s: string]: PropertyDescriptor;\n}\n\ninterface Object {\n /** The initial value of Object.prototype.constructor is the standard built-in Object constructor. */\n constructor: Function;\n\n /** Returns a string representation of an object. */\n toString(): string;\n\n /** Returns a date converted to a string using the current locale. */\n toLocaleString(): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): Object;\n\n /**\n * Determines whether an object has a property with the specified name.\n * @param v A property name.\n */\n hasOwnProperty(v: string): boolean;\n\n /**\n * Determines whether an object exists in another object's prototype chain.\n * @param v Another object whose prototype chain is to be checked.\n */\n isPrototypeOf(v: Object): boolean;\n\n /**\n * Determines whether a specified property is enumerable.\n * @param v A property name.\n */\n propertyIsEnumerable(v: string): boolean;\n}\n\ninterface ObjectConstructor {\n new (value?: any): Object;\n (): any;\n (value: any): any;\n\n /** A reference to the prototype for a class of objects. */\n readonly prototype: Object;\n\n /**\n * Returns the prototype of an object.\n * @param o The object that references the prototype.\n */\n getPrototypeOf(o: any): any;\n\n /**\n * Gets the own property descriptor of the specified object.\n * An own property descriptor is one that is defined directly on the object and is not inherited from the object's prototype.\n * @param o Object that contains the property.\n * @param p Name of the property.\n */\n getOwnPropertyDescriptor(o: any, p: string): PropertyDescriptor;\n\n /**\n * Returns the names of the own properties of an object. The own properties of an object are those that are defined directly\n * on that object, and are not inherited from the object's prototype. The properties of an object include both fields (objects) and functions.\n * @param o Object that contains the own properties.\n */\n getOwnPropertyNames(o: any): string[];\n\n /**\n * Creates an object that has the specified prototype or that has null prototype.\n * @param o Object to use as a prototype. May be null.\n */\n create(o: object | null): any;\n\n /**\n * Creates an object that has the specified prototype, and that optionally contains specified properties.\n * @param o Object to use as a prototype. May be null\n * @param properties JavaScript object that contains one or more property descriptors.\n */\n create(o: object | null, properties: PropertyDescriptorMap & ThisType): any;\n\n /**\n * Adds a property to an object, or modifies attributes of an existing property.\n * @param o Object on which to add or modify the property. This can be a native JavaScript object (that is, a user-defined object or a built in object) or a DOM object.\n * @param p The property name.\n * @param attributes Descriptor for the property. It can be for a data property or an accessor property.\n */\n defineProperty(o: any, p: string, attributes: PropertyDescriptor & ThisType): any;\n\n /**\n * Adds one or more properties to an object, and/or modifies attributes of existing properties.\n * @param o Object on which to add or modify the properties. This can be a native JavaScript object or a DOM object.\n * @param properties JavaScript object that contains one or more descriptor objects. Each descriptor object describes a data property or an accessor property.\n */\n defineProperties(o: any, properties: PropertyDescriptorMap & ThisType): any;\n\n /**\n * Prevents the modification of attributes of existing properties, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n seal(o: T): T;\n\n /**\n * Prevents the modification of existing property attributes and values, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n freeze(a: T[]): ReadonlyArray;\n\n /**\n * Prevents the modification of existing property attributes and values, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n freeze(f: T): T;\n\n /**\n * Prevents the modification of existing property attributes and values, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n freeze(o: T): Readonly;\n\n /**\n * Prevents the addition of new properties to an object.\n * @param o Object to make non-extensible.\n */\n preventExtensions(o: T): T;\n\n /**\n * Returns true if existing property attributes cannot be modified in an object and new properties cannot be added to the object.\n * @param o Object to test.\n */\n isSealed(o: any): boolean;\n\n /**\n * Returns true if existing property attributes and values cannot be modified in an object, and new properties cannot be added to the object.\n * @param o Object to test.\n */\n isFrozen(o: any): boolean;\n\n /**\n * Returns a value that indicates whether new properties can be added to an object.\n * @param o Object to test.\n */\n isExtensible(o: any): boolean;\n\n /**\n * Returns the names of the enumerable properties and methods of an object.\n * @param o Object that contains the properties and methods. This can be an object that you created or an existing Document Object Model (DOM) object.\n */\n keys(o: any): string[];\n}\n\n/**\n * Provides functionality common to all JavaScript objects.\n */\ndeclare const Object: ObjectConstructor;\n\n/**\n * Creates a new function.\n */\ninterface Function {\n /**\n * Calls the function, substituting the specified object for the this value of the function, and the specified array for the arguments of the function.\n * @param thisArg The object to be used as the this object.\n * @param argArray A set of arguments to be passed to the function.\n */\n apply(this: Function, thisArg: any, argArray?: any): any;\n\n /**\n * Calls a method of an object, substituting another object for the current object.\n * @param thisArg The object to be used as the current object.\n * @param argArray A list of arguments to be passed to the method.\n */\n call(this: Function, thisArg: any, ...argArray: any[]): any;\n\n /**\n * For a given function, creates a bound function that has the same body as the original function.\n * The this object of the bound function is associated with the specified object, and has the specified initial parameters.\n * @param thisArg An object to which the this keyword can refer inside the new function.\n * @param argArray A list of arguments to be passed to the new function.\n */\n bind(this: Function, thisArg: any, ...argArray: any[]): any;\n\n /** Returns a string representation of a function. */\n toString(): string;\n\n prototype: any;\n readonly length: number;\n\n // Non-standard extensions\n arguments: any;\n caller: Function;\n}\n\ninterface FunctionConstructor {\n /**\n * Creates a new function.\n * @param args A list of arguments the function accepts.\n */\n new (...args: string[]): Function;\n (...args: string[]): Function;\n readonly prototype: Function;\n}\n\ndeclare const Function: FunctionConstructor;\n\ninterface IArguments {\n [index: number]: any;\n length: number;\n callee: Function;\n}\n\ninterface String {\n /** Returns a string representation of a string. */\n toString(): string;\n\n /**\n * Returns the character at the specified index.\n * @param pos The zero-based index of the desired character.\n */\n charAt(pos: number): string;\n\n /**\n * Returns the Unicode value of the character at the specified location.\n * @param index The zero-based index of the desired character. If there is no character at the specified index, NaN is returned.\n */\n charCodeAt(index: number): number;\n\n /**\n * Returns a string that contains the concatenation of two or more strings.\n * @param strings The strings to append to the end of the string.\n */\n concat(...strings: string[]): string;\n\n /**\n * Returns the position of the first occurrence of a substring.\n * @param searchString The substring to search for in the string\n * @param position The index at which to begin searching the String object. If omitted, search starts at the beginning of the string.\n */\n indexOf(searchString: string, position?: number): number;\n\n /**\n * Returns the last occurrence of a substring in the string.\n * @param searchString The substring to search for.\n * @param position The index at which to begin searching. If omitted, the search begins at the end of the string.\n */\n lastIndexOf(searchString: string, position?: number): number;\n\n /**\n * Determines whether two strings are equivalent in the current locale.\n * @param that String to compare to target string\n */\n localeCompare(that: string): number;\n\n /**\n * Matches a string with a regular expression, and returns an array containing the results of that search.\n * @param regexp A variable name or string literal containing the regular expression pattern and flags.\n */\n match(regexp: string | RegExp): RegExpMatchArray | null;\n\n /**\n * Replaces text in a string, using a regular expression or search string.\n * @param searchValue A string to search for.\n * @param replaceValue A string containing the text to replace for every successful match of searchValue in this string.\n */\n replace(searchValue: string | RegExp, replaceValue: string): string;\n\n /**\n * Replaces text in a string, using a regular expression or search string.\n * @param searchValue A string to search for.\n * @param replacer A function that returns the replacement text.\n */\n replace(searchValue: string | RegExp, replacer: (substring: string, ...args: any[]) => string): string;\n\n /**\n * Finds the first substring match in a regular expression search.\n * @param regexp The regular expression pattern and applicable flags.\n */\n search(regexp: string | RegExp): number;\n\n /**\n * Returns a section of a string.\n * @param start The index to the beginning of the specified portion of stringObj.\n * @param end The index to the end of the specified portion of stringObj. The substring includes the characters up to, but not including, the character indicated by end.\n * If this value is not specified, the substring continues to the end of stringObj.\n */\n slice(start?: number, end?: number): string;\n\n /**\n * Split a string into substrings using the specified separator and return them as an array.\n * @param separator A string that identifies character or characters to use in separating the string. If omitted, a single-element array containing the entire string is returned.\n * @param limit A value used to limit the number of elements returned in the array.\n */\n split(separator: string | RegExp, limit?: number): string[];\n\n /**\n * Returns the substring at the specified location within a String object.\n * @param start The zero-based index number indicating the beginning of the substring.\n * @param end Zero-based index number indicating the end of the substring. The substring includes the characters up to, but not including, the character indicated by end.\n * If end is omitted, the characters from start through the end of the original string are returned.\n */\n substring(start: number, end?: number): string;\n\n /** Converts all the alphabetic characters in a string to lowercase. */\n toLowerCase(): string;\n\n /** Converts all alphabetic characters to lowercase, taking into account the host environment's current locale. */\n toLocaleLowerCase(): string;\n\n /** Converts all the alphabetic characters in a string to uppercase. */\n toUpperCase(): string;\n\n /** Returns a string where all alphabetic characters have been converted to uppercase, taking into account the host environment's current locale. */\n toLocaleUpperCase(): string;\n\n /** Removes the leading and trailing white space and line terminator characters from a string. */\n trim(): string;\n\n /** Returns the length of a String object. */\n readonly length: number;\n\n // IE extensions\n /**\n * Gets a substring beginning at the specified location and having the specified length.\n * @param from The starting position of the desired substring. The index of the first character in the string is zero.\n * @param length The number of characters to include in the returned substring.\n */\n substr(from: number, length?: number): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): string;\n\n readonly [index: number]: string;\n}\n\ninterface StringConstructor {\n new (value?: any): String;\n (value?: any): string;\n readonly prototype: String;\n fromCharCode(...codes: number[]): string;\n}\n\n/**\n * Allows manipulation and formatting of text strings and determination and location of substrings within strings.\n */\ndeclare const String: StringConstructor;\n\ninterface Boolean {\n /** Returns the primitive value of the specified object. */\n valueOf(): boolean;\n}\n\ninterface BooleanConstructor {\n new (value?: any): Boolean;\n (value?: any): boolean;\n readonly prototype: Boolean;\n}\n\ndeclare const Boolean: BooleanConstructor;\n\ninterface Number {\n /**\n * Returns a string representation of an object.\n * @param radix Specifies a radix for converting numeric values to strings. This value is only used for numbers.\n */\n toString(radix?: number): string;\n\n /**\n * Returns a string representing a number in fixed-point notation.\n * @param fractionDigits Number of digits after the decimal point. Must be in the range 0 - 20, inclusive.\n */\n toFixed(fractionDigits?: number): string;\n\n /**\n * Returns a string containing a number represented in exponential notation.\n * @param fractionDigits Number of digits after the decimal point. Must be in the range 0 - 20, inclusive.\n */\n toExponential(fractionDigits?: number): string;\n\n /**\n * Returns a string containing a number represented either in exponential or fixed-point notation with a specified number of digits.\n * @param precision Number of significant digits. Must be in the range 1 - 21, inclusive.\n */\n toPrecision(precision?: number): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): number;\n}\n\ninterface NumberConstructor {\n new (value?: any): Number;\n (value?: any): number;\n readonly prototype: Number;\n\n /** The largest number that can be represented in JavaScript. Equal to approximately 1.79E+308. */\n readonly MAX_VALUE: number;\n\n /** The closest number to zero that can be represented in JavaScript. Equal to approximately 5.00E-324. */\n readonly MIN_VALUE: number;\n\n /**\n * A value that is not a number.\n * In equality comparisons, NaN does not equal any value, including itself. To test whether a value is equivalent to NaN, use the isNaN function.\n */\n readonly NaN: number;\n\n /**\n * A value that is less than the largest negative number that can be represented in JavaScript.\n * JavaScript displays NEGATIVE_INFINITY values as -infinity.\n */\n readonly NEGATIVE_INFINITY: number;\n\n /**\n * A value greater than the largest number that can be represented in JavaScript.\n * JavaScript displays POSITIVE_INFINITY values as infinity.\n */\n readonly POSITIVE_INFINITY: number;\n}\n\n/** An object that represents a number of any kind. All JavaScript numbers are 64-bit floating-point numbers. */\ndeclare const Number: NumberConstructor;\n\ninterface TemplateStringsArray extends ReadonlyArray {\n readonly raw: ReadonlyArray;\n}\n\ninterface Math {\n /** The mathematical constant e. This is Euler's number, the base of natural logarithms. */\n readonly E: number;\n /** The natural logarithm of 10. */\n readonly LN10: number;\n /** The natural logarithm of 2. */\n readonly LN2: number;\n /** The base-2 logarithm of e. */\n readonly LOG2E: number;\n /** The base-10 logarithm of e. */\n readonly LOG10E: number;\n /** Pi. This is the ratio of the circumference of a circle to its diameter. */\n readonly PI: number;\n /** The square root of 0.5, or, equivalently, one divided by the square root of 2. */\n readonly SQRT1_2: number;\n /** The square root of 2. */\n readonly SQRT2: number;\n /**\n * Returns the absolute value of a number (the value without regard to whether it is positive or negative).\n * For example, the absolute value of -5 is the same as the absolute value of 5.\n * @param x A numeric expression for which the absolute value is needed.\n */\n abs(x: number): number;\n /**\n * Returns the arc cosine (or inverse cosine) of a number.\n * @param x A numeric expression.\n */\n acos(x: number): number;\n /**\n * Returns the arcsine of a number.\n * @param x A numeric expression.\n */\n asin(x: number): number;\n /**\n * Returns the arctangent of a number.\n * @param x A numeric expression for which the arctangent is needed.\n */\n atan(x: number): number;\n /**\n * Returns the angle (in radians) from the X axis to a point.\n * @param y A numeric expression representing the cartesian y-coordinate.\n * @param x A numeric expression representing the cartesian x-coordinate.\n */\n atan2(y: number, x: number): number;\n /**\n * Returns the smallest number greater than or equal to its numeric argument.\n * @param x A numeric expression.\n */\n ceil(x: number): number;\n /**\n * Returns the cosine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n cos(x: number): number;\n /**\n * Returns e (the base of natural logarithms) raised to a power.\n * @param x A numeric expression representing the power of e.\n */\n exp(x: number): number;\n /**\n * Returns the greatest number less than or equal to its numeric argument.\n * @param x A numeric expression.\n */\n floor(x: number): number;\n /**\n * Returns the natural logarithm (base e) of a number.\n * @param x A numeric expression.\n */\n log(x: number): number;\n /**\n * Returns the larger of a set of supplied numeric expressions.\n * @param values Numeric expressions to be evaluated.\n */\n max(...values: number[]): number;\n /**\n * Returns the smaller of a set of supplied numeric expressions.\n * @param values Numeric expressions to be evaluated.\n */\n min(...values: number[]): number;\n /**\n * Returns the value of a base expression taken to a specified power.\n * @param x The base value of the expression.\n * @param y The exponent value of the expression.\n */\n pow(x: number, y: number): number;\n /** Returns a pseudorandom number between 0 and 1. */\n random(): number;\n /**\n * Returns a supplied numeric expression rounded to the nearest number.\n * @param x The value to be rounded to the nearest number.\n */\n round(x: number): number;\n /**\n * Returns the sine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n sin(x: number): number;\n /**\n * Returns the square root of a number.\n * @param x A numeric expression.\n */\n sqrt(x: number): number;\n /**\n * Returns the tangent of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n tan(x: number): number;\n}\n/** An intrinsic object that provides basic mathematics functionality and constants. */\ndeclare const Math: Math;\n\n/** Enables basic storage and retrieval of dates and times. */\ninterface Date {\n /** Returns a string representation of a date. The format of the string depends on the locale. */\n toString(): string;\n /** Returns a date as a string value. */\n toDateString(): string;\n /** Returns a time as a string value. */\n toTimeString(): string;\n /** Returns a value as a string value appropriate to the host environment's current locale. */\n toLocaleString(): string;\n /** Returns a date as a string value appropriate to the host environment's current locale. */\n toLocaleDateString(): string;\n /** Returns a time as a string value appropriate to the host environment's current locale. */\n toLocaleTimeString(): string;\n /** Returns the stored time value in milliseconds since midnight, January 1, 1970 UTC. */\n valueOf(): number;\n /** Gets the time value in milliseconds. */\n getTime(): number;\n /** Gets the year, using local time. */\n getFullYear(): number;\n /** Gets the year using Universal Coordinated Time (UTC). */\n getUTCFullYear(): number;\n /** Gets the month, using local time. */\n getMonth(): number;\n /** Gets the month of a Date object using Universal Coordinated Time (UTC). */\n getUTCMonth(): number;\n /** Gets the day-of-the-month, using local time. */\n getDate(): number;\n /** Gets the day-of-the-month, using Universal Coordinated Time (UTC). */\n getUTCDate(): number;\n /** Gets the day of the week, using local time. */\n getDay(): number;\n /** Gets the day of the week using Universal Coordinated Time (UTC). */\n getUTCDay(): number;\n /** Gets the hours in a date, using local time. */\n getHours(): number;\n /** Gets the hours value in a Date object using Universal Coordinated Time (UTC). */\n getUTCHours(): number;\n /** Gets the minutes of a Date object, using local time. */\n getMinutes(): number;\n /** Gets the minutes of a Date object using Universal Coordinated Time (UTC). */\n getUTCMinutes(): number;\n /** Gets the seconds of a Date object, using local time. */\n getSeconds(): number;\n /** Gets the seconds of a Date object using Universal Coordinated Time (UTC). */\n getUTCSeconds(): number;\n /** Gets the milliseconds of a Date, using local time. */\n getMilliseconds(): number;\n /** Gets the milliseconds of a Date object using Universal Coordinated Time (UTC). */\n getUTCMilliseconds(): number;\n /** Gets the difference in minutes between the time on the local computer and Universal Coordinated Time (UTC). */\n getTimezoneOffset(): number;\n /**\n * Sets the date and time value in the Date object.\n * @param time A numeric value representing the number of elapsed milliseconds since midnight, January 1, 1970 GMT.\n */\n setTime(time: number): number;\n /**\n * Sets the milliseconds value in the Date object using local time.\n * @param ms A numeric value equal to the millisecond value.\n */\n setMilliseconds(ms: number): number;\n /**\n * Sets the milliseconds value in the Date object using Universal Coordinated Time (UTC).\n * @param ms A numeric value equal to the millisecond value.\n */\n setUTCMilliseconds(ms: number): number;\n\n /**\n * Sets the seconds value in the Date object using local time.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setSeconds(sec: number, ms?: number): number;\n /**\n * Sets the seconds value in the Date object using Universal Coordinated Time (UTC).\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setUTCSeconds(sec: number, ms?: number): number;\n /**\n * Sets the minutes value in the Date object using local time.\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setMinutes(min: number, sec?: number, ms?: number): number;\n /**\n * Sets the minutes value in the Date object using Universal Coordinated Time (UTC).\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setUTCMinutes(min: number, sec?: number, ms?: number): number;\n /**\n * Sets the hour value in the Date object using local time.\n * @param hours A numeric value equal to the hours value.\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setHours(hours: number, min?: number, sec?: number, ms?: number): number;\n /**\n * Sets the hours value in the Date object using Universal Coordinated Time (UTC).\n * @param hours A numeric value equal to the hours value.\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setUTCHours(hours: number, min?: number, sec?: number, ms?: number): number;\n /**\n * Sets the numeric day-of-the-month value of the Date object using local time.\n * @param date A numeric value equal to the day of the month.\n */\n setDate(date: number): number;\n /**\n * Sets the numeric day of the month in the Date object using Universal Coordinated Time (UTC).\n * @param date A numeric value equal to the day of the month.\n */\n setUTCDate(date: number): number;\n /**\n * Sets the month value in the Date object using local time.\n * @param month A numeric value equal to the month. The value for January is 0, and other month values follow consecutively.\n * @param date A numeric value representing the day of the month. If this value is not supplied, the value from a call to the getDate method is used.\n */\n setMonth(month: number, date?: number): number;\n /**\n * Sets the month value in the Date object using Universal Coordinated Time (UTC).\n * @param month A numeric value equal to the month. The value for January is 0, and other month values follow consecutively.\n * @param date A numeric value representing the day of the month. If it is not supplied, the value from a call to the getUTCDate method is used.\n */\n setUTCMonth(month: number, date?: number): number;\n /**\n * Sets the year of the Date object using local time.\n * @param year A numeric value for the year.\n * @param month A zero-based numeric value for the month (0 for January, 11 for December). Must be specified if numDate is specified.\n * @param date A numeric value equal for the day of the month.\n */\n setFullYear(year: number, month?: number, date?: number): number;\n /**\n * Sets the year value in the Date object using Universal Coordinated Time (UTC).\n * @param year A numeric value equal to the year.\n * @param month A numeric value equal to the month. The value for January is 0, and other month values follow consecutively. Must be supplied if numDate is supplied.\n * @param date A numeric value equal to the day of the month.\n */\n setUTCFullYear(year: number, month?: number, date?: number): number;\n /** Returns a date converted to a string using Universal Coordinated Time (UTC). */\n toUTCString(): string;\n /** Returns a date as a string value in ISO format. */\n toISOString(): string;\n /** Used by the JSON.stringify method to enable the transformation of an object's data for JavaScript Object Notation (JSON) serialization. */\n toJSON(key?: any): string;\n}\n\ninterface DateConstructor {\n new (): Date;\n new (value: number): Date;\n new (value: string): Date;\n new (year: number, month: number, date?: number, hours?: number, minutes?: number, seconds?: number, ms?: number): Date;\n (): string;\n readonly prototype: Date;\n /**\n * Parses a string containing a date, and returns the number of milliseconds between that date and midnight, January 1, 1970.\n * @param s A date string\n */\n parse(s: string): number;\n /**\n * Returns the number of milliseconds between midnight, January 1, 1970 Universal Coordinated Time (UTC) (or GMT) and the specified date.\n * @param year The full year designation is required for cross-century date accuracy. If year is between 0 and 99 is used, then year is assumed to be 1900 + year.\n * @param month The month as an number between 0 and 11 (January to December).\n * @param date The date as an number between 1 and 31.\n * @param hours Must be supplied if minutes is supplied. An number from 0 to 23 (midnight to 11pm) that specifies the hour.\n * @param minutes Must be supplied if seconds is supplied. An number from 0 to 59 that specifies the minutes.\n * @param seconds Must be supplied if milliseconds is supplied. An number from 0 to 59 that specifies the seconds.\n * @param ms An number from 0 to 999 that specifies the milliseconds.\n */\n UTC(year: number, month: number, date?: number, hours?: number, minutes?: number, seconds?: number, ms?: number): number;\n now(): number;\n}\n\ndeclare const Date: DateConstructor;\n\ninterface RegExpMatchArray extends Array {\n index?: number;\n input?: string;\n}\n\ninterface RegExpExecArray extends Array {\n index: number;\n input: string;\n}\n\ninterface RegExp {\n /**\n * Executes a search on a string using a regular expression pattern, and returns an array containing the results of that search.\n * @param string The String object or string literal on which to perform the search.\n */\n exec(string: string): RegExpExecArray | null;\n\n /**\n * Returns a Boolean value that indicates whether or not a pattern exists in a searched string.\n * @param string String on which to perform the search.\n */\n test(string: string): boolean;\n\n /** Returns a copy of the text of the regular expression pattern. Read-only. The regExp argument is a Regular expression object. It can be a variable name or a literal. */\n readonly source: string;\n\n /** Returns a Boolean value indicating the state of the global flag (g) used with a regular expression. Default is false. Read-only. */\n readonly global: boolean;\n\n /** Returns a Boolean value indicating the state of the ignoreCase flag (i) used with a regular expression. Default is false. Read-only. */\n readonly ignoreCase: boolean;\n\n /** Returns a Boolean value indicating the state of the multiline flag (m) used with a regular expression. Default is false. Read-only. */\n readonly multiline: boolean;\n\n lastIndex: number;\n\n // Non-standard extensions\n compile(): this;\n}\n\ninterface RegExpConstructor {\n new (pattern: RegExp | string): RegExp;\n new (pattern: string, flags?: string): RegExp;\n (pattern: RegExp | string): RegExp;\n (pattern: string, flags?: string): RegExp;\n readonly prototype: RegExp;\n\n // Non-standard extensions\n $1: string;\n $2: string;\n $3: string;\n $4: string;\n $5: string;\n $6: string;\n $7: string;\n $8: string;\n $9: string;\n lastMatch: string;\n}\n\ndeclare const RegExp: RegExpConstructor;\n\ninterface Error {\n name: string;\n message: string;\n stack?: string;\n}\n\ninterface ErrorConstructor {\n new (message?: string): Error;\n (message?: string): Error;\n readonly prototype: Error;\n}\n\ndeclare const Error: ErrorConstructor;\n\ninterface EvalError extends Error {\n}\n\ninterface EvalErrorConstructor {\n new (message?: string): EvalError;\n (message?: string): EvalError;\n readonly prototype: EvalError;\n}\n\ndeclare const EvalError: EvalErrorConstructor;\n\ninterface RangeError extends Error {\n}\n\ninterface RangeErrorConstructor {\n new (message?: string): RangeError;\n (message?: string): RangeError;\n readonly prototype: RangeError;\n}\n\ndeclare const RangeError: RangeErrorConstructor;\n\ninterface ReferenceError extends Error {\n}\n\ninterface ReferenceErrorConstructor {\n new (message?: string): ReferenceError;\n (message?: string): ReferenceError;\n readonly prototype: ReferenceError;\n}\n\ndeclare const ReferenceError: ReferenceErrorConstructor;\n\ninterface SyntaxError extends Error {\n}\n\ninterface SyntaxErrorConstructor {\n new (message?: string): SyntaxError;\n (message?: string): SyntaxError;\n readonly prototype: SyntaxError;\n}\n\ndeclare const SyntaxError: SyntaxErrorConstructor;\n\ninterface TypeError extends Error {\n}\n\ninterface TypeErrorConstructor {\n new (message?: string): TypeError;\n (message?: string): TypeError;\n readonly prototype: TypeError;\n}\n\ndeclare const TypeError: TypeErrorConstructor;\n\ninterface URIError extends Error {\n}\n\ninterface URIErrorConstructor {\n new (message?: string): URIError;\n (message?: string): URIError;\n readonly prototype: URIError;\n}\n\ndeclare const URIError: URIErrorConstructor;\n\ninterface JSON {\n /**\n * Converts a JavaScript Object Notation (JSON) string into an object.\n * @param text A valid JSON string.\n * @param reviver A function that transforms the results. This function is called for each member of the object.\n * If a member contains nested objects, the nested objects are transformed before the parent object is.\n */\n parse(text: string, reviver?: (key: any, value: any) => any): any;\n /**\n * Converts a JavaScript value to a JavaScript Object Notation (JSON) string.\n * @param value A JavaScript value, usually an object or array, to be converted.\n * @param replacer A function that transforms the results.\n * @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.\n */\n stringify(value: any, replacer?: (key: string, value: any) => any, space?: string | number): string;\n /**\n * Converts a JavaScript value to a JavaScript Object Notation (JSON) string.\n * @param value A JavaScript value, usually an object or array, to be converted.\n * @param replacer An array of strings and numbers that acts as a approved list for selecting the object properties that will be stringified.\n * @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.\n */\n stringify(value: any, replacer?: (number | string)[] | null, space?: string | number): string;\n}\n\n/**\n * An intrinsic object that provides functions to convert JavaScript values to and from the JavaScript Object Notation (JSON) format.\n */\ndeclare const JSON: JSON;\n\n\n/////////////////////////////\n/// ECMAScript Array API (specially handled by compiler)\n/////////////////////////////\n\ninterface ReadonlyArray {\n /**\n * Gets the length of the array. This is a number one higher than the highest element defined in an array.\n */\n readonly length: number;\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n toLocaleString(): string;\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat>(...items: U[]): T[];\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: T[][]): T[];\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: (T | T[])[]): T[];\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): T[];\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.\n */\n indexOf(searchElement: T, fromIndex?: number): number;\n\n /**\n * Returns the index of the last occurrence of a specified value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at the last index in the array.\n */\n lastIndexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls the callbackfn function for each element in array1 until the callbackfn returns false, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => boolean): boolean;\n every(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: T, index: number, array: ReadonlyArray) => boolean, thisArg: Z): boolean;\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the callbackfn function for each element in array1 until the callbackfn returns true, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => boolean): boolean;\n some(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: T, index: number, array: ReadonlyArray) => boolean, thisArg: Z): boolean;\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => void): void;\n forEach(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: T, index: number, array: ReadonlyArray) => void, thisArg: Z): void;\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => U): U[];\n map(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => U, thisArg: undefined): U[];\n map(callbackfn: (this: Z, value: T, index: number, array: ReadonlyArray) => U, thisArg: Z): U[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => value is S): S[];\n filter(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => value is S, thisArg: undefined): S[];\n filter(callbackfn: (this: Z, value: T, index: number, array: ReadonlyArray) => value is S, thisArg: Z): S[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => any): T[];\n filter(callbackfn: (this: void, value: T, index: number, array: ReadonlyArray) => any, thisArg: undefined): T[];\n filter(callbackfn: (this: Z, value: T, index: number, array: ReadonlyArray) => any, thisArg: Z): T[];\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: ReadonlyArray) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: ReadonlyArray) => U, initialValue: U): U;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: ReadonlyArray) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: ReadonlyArray) => U, initialValue: U): U;\n\n readonly [n: number]: T;\n}\n\ninterface Array {\n /**\n * Gets or sets the length of the array. This is a number one higher than the highest element defined in an array.\n */\n length: number;\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n toLocaleString(): string;\n /**\n * Appends new elements to an array, and returns the new length of the array.\n * @param items New elements of the Array.\n */\n push(...items: T[]): number;\n /**\n * Removes the last element from an array and returns it.\n */\n pop(): T | undefined;\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: T[][]): T[];\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: (T | T[])[]): T[];\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n /**\n * Reverses the elements in an Array.\n */\n reverse(): T[];\n /**\n * Removes the first element from an array and returns it.\n */\n shift(): T | undefined;\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): T[];\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: T, b: T) => number): this;\n /**\n * Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.\n * @param start The zero-based location in the array from which to start removing elements.\n * @param deleteCount The number of elements to remove.\n */\n splice(start: number, deleteCount?: number): T[];\n /**\n * Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.\n * @param start The zero-based location in the array from which to start removing elements.\n * @param deleteCount The number of elements to remove.\n * @param items Elements to insert into the array in place of the deleted elements.\n */\n splice(start: number, deleteCount: number, ...items: T[]): T[];\n /**\n * Inserts new elements at the start of an array.\n * @param items Elements to insert at the start of the Array.\n */\n unshift(...items: T[]): number;\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.\n */\n indexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Returns the index of the last occurrence of a specified value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at the last index in the array.\n */\n lastIndexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls the callbackfn function for each element in array1 until the callbackfn returns false, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: T, index: number, array: T[]) => boolean): boolean;\n every(callbackfn: (this: void, value: T, index: number, array: T[]) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: T, index: number, array: T[]) => boolean, thisArg: Z): boolean;\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the callbackfn function for each element in array1 until the callbackfn returns true, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: T, index: number, array: T[]) => boolean): boolean;\n some(callbackfn: (this: void, value: T, index: number, array: T[]) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: T, index: number, array: T[]) => boolean, thisArg: Z): boolean;\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: T, index: number, array: T[]) => void): void;\n forEach(callbackfn: (this: void, value: T, index: number, array: T[]) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: T, index: number, array: T[]) => void, thisArg: Z): void;\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(this: [T, T, T, T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U): [U, U, U, U, U];\n map(this: [T, T, T, T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U, thisArg: undefined): [U, U, U, U, U];\n map(this: [T, T, T, T, T], callbackfn: (this: Z, value: T, index: number, array: T[]) => U, thisArg: Z): [U, U, U, U, U];\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(this: [T, T, T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U): [U, U, U, U];\n map(this: [T, T, T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U, thisArg: undefined): [U, U, U, U];\n map(this: [T, T, T, T], callbackfn: (this: Z, value: T, index: number, array: T[]) => U, thisArg: Z): [U, U, U, U];\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(this: [T, T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U): [U, U, U];\n map(this: [T, T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U, thisArg: undefined): [U, U, U];\n map(this: [T, T, T], callbackfn: (this: Z, value: T, index: number, array: T[]) => U, thisArg: Z): [U, U, U];\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(this: [T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U): [U, U];\n map(this: [T, T], callbackfn: (this: void, value: T, index: number, array: T[]) => U, thisArg: undefined): [U, U];\n map(this: [T, T], callbackfn: (this: Z, value: T, index: number, array: T[]) => U, thisArg: Z): [U, U];\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: T, index: number, array: T[]) => U): U[];\n map(callbackfn: (this: void, value: T, index: number, array: T[]) => U, thisArg: undefined): U[];\n map(callbackfn: (this: Z, value: T, index: number, array: T[]) => U, thisArg: Z): U[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: T, index: number, array: T[]) => any): T[];\n filter(callbackfn: (this: void, value: T, index: number, array: T[]) => any, thisArg: undefined): T[];\n filter(callbackfn: (this: Z, value: T, index: number, array: T[]) => any, thisArg: Z): T[];\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: T[]) => U, initialValue: U): U;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: T[]) => U, initialValue: U): U;\n\n [n: number]: T;\n}\n\ninterface ArrayConstructor {\n new (arrayLength?: number): any[];\n new (arrayLength: number): T[];\n new (...items: T[]): T[];\n (arrayLength?: number): any[];\n (arrayLength: number): T[];\n (...items: T[]): T[];\n isArray(arg: any): arg is Array;\n readonly prototype: Array;\n}\n\ndeclare const Array: ArrayConstructor;\n\ninterface TypedPropertyDescriptor {\n enumerable?: boolean;\n configurable?: boolean;\n writable?: boolean;\n value?: T;\n get?: () => T;\n set?: (value: T) => void;\n}\n\ndeclare type ClassDecorator = (target: TFunction) => TFunction | void;\ndeclare type PropertyDecorator = (target: Object, propertyKey: string | symbol) => void;\ndeclare type MethodDecorator = (target: Object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor) => TypedPropertyDescriptor | void;\ndeclare type ParameterDecorator = (target: Object, propertyKey: string | symbol, parameterIndex: number) => void;\n\ndeclare type PromiseConstructorLike = new (executor: (resolve: (value?: T | PromiseLike) => void, reject: (reason?: any) => void) => void) => PromiseLike;\n\ninterface PromiseLike {\n /**\n * Attaches callbacks for the resolution and/or rejection of the Promise.\n * @param onfulfilled The callback to execute when the Promise is resolved.\n * @param onrejected The callback to execute when the Promise is rejected.\n * @returns A Promise for the completion of which ever callback is executed.\n */\n then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): PromiseLike;\n}\n\n/**\n * Represents the completion of an asynchronous operation\n */\ninterface Promise {\n /**\n * Attaches callbacks for the resolution and/or rejection of the Promise.\n * @param onfulfilled The callback to execute when the Promise is resolved.\n * @param onrejected The callback to execute when the Promise is rejected.\n * @returns A Promise for the completion of which ever callback is executed.\n */\n then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): Promise;\n\n /**\n * Attaches a callback for only the rejection of the Promise.\n * @param onrejected The callback to execute when the Promise is rejected.\n * @returns A Promise for the completion of the callback.\n */\n catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): Promise;\n}\n\ninterface ArrayLike {\n readonly length: number;\n readonly [n: number]: T;\n}\n\n/**\n * Make all properties in T optional\n */\ntype Partial = {\n [P in keyof T]?: T[P];\n};\n\n/**\n * Make all properties in T readonly\n */\ntype Readonly = {\n readonly [P in keyof T]: T[P];\n};\n\n/**\n * From T pick a set of properties K\n */\ntype Pick = {\n [P in K]: T[P];\n};\n\n/**\n * Construct a type with a set of properties K of type T\n */\ntype Record = {\n [P in K]: T;\n};\n\n/**\n * Marker for contextual 'this' type\n */\ninterface ThisType { }\n\n/**\n * Represents a raw buffer of binary data, which is used to store data for the\n * different typed arrays. ArrayBuffers cannot be read from or written to directly,\n * but can be passed to a typed array or DataView Object to interpret the raw\n * buffer as needed.\n */\ninterface ArrayBuffer {\n /**\n * Read-only. The length of the ArrayBuffer (in bytes).\n */\n readonly byteLength: number;\n\n /**\n * Returns a section of an ArrayBuffer.\n */\n slice(begin: number, end?: number): ArrayBuffer;\n}\n\ninterface ArrayBufferConstructor {\n readonly prototype: ArrayBuffer;\n new (byteLength: number): ArrayBuffer;\n isView(arg: any): arg is ArrayBufferView;\n}\ndeclare const ArrayBuffer: ArrayBufferConstructor;\n\ninterface ArrayBufferView {\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n byteOffset: number;\n}\n\ninterface DataView {\n readonly buffer: ArrayBuffer;\n readonly byteLength: number;\n readonly byteOffset: number;\n /**\n * Gets the Float32 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getFloat32(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Float64 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getFloat64(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Int8 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getInt8(byteOffset: number): number;\n\n /**\n * Gets the Int16 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getInt16(byteOffset: number, littleEndian?: boolean): number;\n /**\n * Gets the Int32 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getInt32(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Uint8 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getUint8(byteOffset: number): number;\n\n /**\n * Gets the Uint16 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getUint16(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Uint32 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getUint32(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Stores an Float32 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setFloat32(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Float64 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setFloat64(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Int8 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n */\n setInt8(byteOffset: number, value: number): void;\n\n /**\n * Stores an Int16 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setInt16(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Int32 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setInt32(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Uint8 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n */\n setUint8(byteOffset: number, value: number): void;\n\n /**\n * Stores an Uint16 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setUint16(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Uint32 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setUint32(byteOffset: number, value: number, littleEndian?: boolean): void;\n}\n\ninterface DataViewConstructor {\n new (buffer: ArrayBuffer, byteOffset?: number, byteLength?: number): DataView;\n}\ndeclare const DataView: DataViewConstructor;\n\n/**\n * A typed array of 8-bit integer values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Int8Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Int8Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Int8Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Int8Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Int8Array) => any): Int8Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Int8Array) => any, thisArg: undefined): Int8Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Int8Array) => any, thisArg: Z): Int8Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Int8Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Int8Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Int8Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Int8Array) => number): Int8Array;\n map(callbackfn: (this: void, value: number, index: number, array: Int8Array) => number, thisArg: undefined): Int8Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Int8Array) => number, thisArg: Z): Int8Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int8Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int8Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Int8Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Int8Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Int8Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Int8Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Int8Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Int8Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Int8Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\ninterface Int8ArrayConstructor {\n readonly prototype: Int8Array;\n new (length: number): Int8Array;\n new (array: ArrayLike): Int8Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Int8Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Int8Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Int8Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Int8Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Int8Array;\n\n from(arrayLike: ArrayLike): Int8Array;\n\n}\ndeclare const Int8Array: Int8ArrayConstructor;\n\n/**\n * A typed array of 8-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Uint8Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => any): Uint8Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => any, thisArg: undefined): Uint8Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Uint8Array) => any, thisArg: Z): Uint8Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Uint8Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => number): Uint8Array;\n map(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => number, thisArg: undefined): Uint8Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Uint8Array) => number, thisArg: Z): Uint8Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint8Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint8Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Uint8Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint8Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint8Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint8ArrayConstructor {\n readonly prototype: Uint8Array;\n new (length: number): Uint8Array;\n new (array: ArrayLike): Uint8Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Uint8Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint8Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Uint8Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint8Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint8Array;\n\n from(arrayLike: ArrayLike): Uint8Array;\n\n}\ndeclare const Uint8Array: Uint8ArrayConstructor;\n\n/**\n * A typed array of 8-bit unsigned integer (clamped) values. The contents are initialized to 0.\n * If the requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8ClampedArray {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Uint8ClampedArray) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => any): Uint8ClampedArray;\n filter(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => any, thisArg: undefined): Uint8ClampedArray;\n filter(callbackfn: (this: Z, value: number, index: number, array: Uint8ClampedArray) => any, thisArg: Z): Uint8ClampedArray;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Uint8ClampedArray) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => number): Uint8ClampedArray;\n map(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => number, thisArg: undefined): Uint8ClampedArray;\n map(callbackfn: (this: Z, value: number, index: number, array: Uint8ClampedArray) => number, thisArg: Z): Uint8ClampedArray;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint8ClampedArray;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint8ClampedArray;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Uint8ClampedArray) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint8ClampedArray view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint8ClampedArray;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint8ClampedArrayConstructor {\n readonly prototype: Uint8ClampedArray;\n new (length: number): Uint8ClampedArray;\n new (array: ArrayLike): Uint8ClampedArray;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Uint8ClampedArray;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint8ClampedArray;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Uint8ClampedArray;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint8ClampedArray;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint8ClampedArray;\n\n from(arrayLike: ArrayLike): Uint8ClampedArray;\n}\ndeclare const Uint8ClampedArray: Uint8ClampedArrayConstructor;\n\n/**\n * A typed array of 16-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int16Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Int16Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Int16Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Int16Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Int16Array) => any): Int16Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Int16Array) => any, thisArg: undefined): Int16Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Int16Array) => any, thisArg: Z): Int16Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Int16Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Int16Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Int16Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Int16Array) => number): Int16Array;\n map(callbackfn: (this: void, value: number, index: number, array: Int16Array) => number, thisArg: undefined): Int16Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Int16Array) => number, thisArg: Z): Int16Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int16Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int16Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Int16Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Int16Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Int16Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Int16Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Int16Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Int16Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Int16Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Int16ArrayConstructor {\n readonly prototype: Int16Array;\n new (length: number): Int16Array;\n new (array: ArrayLike): Int16Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Int16Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Int16Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Int16Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Int16Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Int16Array;\n\n from(arrayLike: ArrayLike): Int16Array;\n\n}\ndeclare const Int16Array: Int16ArrayConstructor;\n\n/**\n * A typed array of 16-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint16Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Uint16Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => any): Uint16Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => any, thisArg: undefined): Uint16Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Uint16Array) => any, thisArg: Z): Uint16Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Uint16Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => number): Uint16Array;\n map(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => number, thisArg: undefined): Uint16Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Uint16Array) => number, thisArg: Z): Uint16Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint16Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint16Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint16Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint16Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Uint16Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint16Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint16Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint16ArrayConstructor {\n readonly prototype: Uint16Array;\n new (length: number): Uint16Array;\n new (array: ArrayLike): Uint16Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Uint16Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint16Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Uint16Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint16Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint16Array;\n\n from(arrayLike: ArrayLike): Uint16Array;\n\n}\ndeclare const Uint16Array: Uint16ArrayConstructor;\n/**\n * A typed array of 32-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int32Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Int32Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Int32Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Int32Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Int32Array) => any): Int32Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Int32Array) => any, thisArg: undefined): Int32Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Int32Array) => any, thisArg: Z): Int32Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Int32Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Int32Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Int32Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Int32Array) => number): Int32Array;\n map(callbackfn: (this: void, value: number, index: number, array: Int32Array) => number, thisArg: undefined): Int32Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Int32Array) => number, thisArg: Z): Int32Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int32Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int32Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Int32Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Int32Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Int32Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Int32Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Int32Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Int32Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Int32Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Int32ArrayConstructor {\n readonly prototype: Int32Array;\n new (length: number): Int32Array;\n new (array: ArrayLike): Int32Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Int32Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Int32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Int32Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Int32Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Int32Array;\n\n from(arrayLike: ArrayLike): Int32Array;\n}\ndeclare const Int32Array: Int32ArrayConstructor;\n\n/**\n * A typed array of 32-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint32Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Uint32Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => any): Uint32Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => any, thisArg: undefined): Uint32Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Uint32Array) => any, thisArg: Z): Uint32Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Uint32Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => number): Uint32Array;\n map(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => number, thisArg: undefined): Uint32Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Uint32Array) => number, thisArg: Z): Uint32Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint32Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint32Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint32Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint32Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Uint32Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint32Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint32Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint32ArrayConstructor {\n readonly prototype: Uint32Array;\n new (length: number): Uint32Array;\n new (array: ArrayLike): Uint32Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Uint32Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Uint32Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Uint32Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Uint32Array;\n\n from(arrayLike: ArrayLike): Uint32Array;\n}\ndeclare const Uint32Array: Uint32ArrayConstructor;\n\n/**\n * A typed array of 32-bit float values. The contents are initialized to 0. If the requested number\n * of bytes could not be allocated an exception is raised.\n */\ninterface Float32Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Float32Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Float32Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Float32Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Float32Array) => any): Float32Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Float32Array) => any, thisArg: undefined): Float32Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Float32Array) => any, thisArg: Z): Float32Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Float32Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Float32Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Float32Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Float32Array) => number): Float32Array;\n map(callbackfn: (this: void, value: number, index: number, array: Float32Array) => number, thisArg: undefined): Float32Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Float32Array) => number, thisArg: Z): Float32Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float32Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float32Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Float32Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Float32Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Float32Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Float32Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Float32Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Float32Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Float32Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Float32ArrayConstructor {\n readonly prototype: Float32Array;\n new (length: number): Float32Array;\n new (array: ArrayLike): Float32Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Float32Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Float32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Float32Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Float32Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Float32Array;\n\n from(arrayLike: ArrayLike): Float32Array;\n\n}\ndeclare const Float32Array: Float32ArrayConstructor;\n\n/**\n * A typed array of 64-bit float values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Float64Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBuffer;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (this: void, value: number, index: number, array: Float64Array) => boolean): boolean;\n every(callbackfn: (this: void, value: number, index: number, array: Float64Array) => boolean, thisArg: undefined): boolean;\n every(callbackfn: (this: Z, value: number, index: number, array: Float64Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Float64Array) => any): Float64Array;\n filter(callbackfn: (this: void, value: number, index: number, array: Float64Array) => any, thisArg: undefined): Float64Array;\n filter(callbackfn: (this: Z, value: number, index: number, array: Float64Array) => any, thisArg: Z): Float64Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number | undefined;\n find(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number | undefined;\n find(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean): number;\n findIndex(predicate: (this: void, value: number, index: number, obj: Array) => boolean, thisArg: undefined): number;\n findIndex(predicate: (this: Z, value: number, index: number, obj: Array) => boolean, thisArg: Z): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (this: void, value: number, index: number, array: Float64Array) => void): void;\n forEach(callbackfn: (this: void, value: number, index: number, array: Float64Array) => void, thisArg: undefined): void;\n forEach(callbackfn: (this: Z, value: number, index: number, array: Float64Array) => void, thisArg: Z): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Float64Array) => number): Float64Array;\n map(callbackfn: (this: void, value: number, index: number, array: Float64Array) => number, thisArg: undefined): Float64Array;\n map(callbackfn: (this: Z, value: number, index: number, array: Float64Array) => number, thisArg: Z): Float64Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float64Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float64Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float64Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float64Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Float64Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Float64Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (this: void, value: number, index: number, array: Float64Array) => boolean): boolean;\n some(callbackfn: (this: void, value: number, index: number, array: Float64Array) => boolean, thisArg: undefined): boolean;\n some(callbackfn: (this: Z, value: number, index: number, array: Float64Array) => boolean, thisArg: Z): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Float64Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Float64Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Float64ArrayConstructor {\n readonly prototype: Float64Array;\n new (length: number): Float64Array;\n new (array: ArrayLike): Float64Array;\n new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Float64Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Float64Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number): Float64Array;\n from(arrayLike: ArrayLike, mapfn: (this: void, v: number, k: number) => number, thisArg: undefined): Float64Array;\n from(arrayLike: ArrayLike, mapfn: (this: Z, v: number, k: number) => number, thisArg: Z): Float64Array;\n\n from(arrayLike: ArrayLike): Float64Array;\n}\ndeclare const Float64Array: Float64ArrayConstructor;\n\n/////////////////////////////\n/// ECMAScript Internationalization API\n/////////////////////////////\n\ndeclare namespace Intl {\n interface CollatorOptions {\n usage?: string;\n localeMatcher?: string;\n numeric?: boolean;\n caseFirst?: string;\n sensitivity?: string;\n ignorePunctuation?: boolean;\n }\n\n interface ResolvedCollatorOptions {\n locale: string;\n usage: string;\n sensitivity: string;\n ignorePunctuation: boolean;\n collation: string;\n caseFirst: string;\n numeric: boolean;\n }\n\n interface Collator {\n compare(x: string, y: string): number;\n resolvedOptions(): ResolvedCollatorOptions;\n }\n var Collator: {\n new (locales?: string | string[], options?: CollatorOptions): Collator;\n (locales?: string | string[], options?: CollatorOptions): Collator;\n supportedLocalesOf(locales: string | string[], options?: CollatorOptions): string[];\n };\n\n interface NumberFormatOptions {\n localeMatcher?: string;\n style?: string;\n currency?: string;\n currencyDisplay?: string;\n useGrouping?: boolean;\n minimumIntegerDigits?: number;\n minimumFractionDigits?: number;\n maximumFractionDigits?: number;\n minimumSignificantDigits?: number;\n maximumSignificantDigits?: number;\n }\n\n interface ResolvedNumberFormatOptions {\n locale: string;\n numberingSystem: string;\n style: string;\n currency?: string;\n currencyDisplay?: string;\n minimumIntegerDigits: number;\n minimumFractionDigits: number;\n maximumFractionDigits: number;\n minimumSignificantDigits?: number;\n maximumSignificantDigits?: number;\n useGrouping: boolean;\n }\n\n interface NumberFormat {\n format(value: number): string;\n resolvedOptions(): ResolvedNumberFormatOptions;\n }\n var NumberFormat: {\n new (locales?: string | string[], options?: NumberFormatOptions): NumberFormat;\n (locales?: string | string[], options?: NumberFormatOptions): NumberFormat;\n supportedLocalesOf(locales: string | string[], options?: NumberFormatOptions): string[];\n };\n\n interface DateTimeFormatOptions {\n localeMatcher?: string;\n weekday?: string;\n era?: string;\n year?: string;\n month?: string;\n day?: string;\n hour?: string;\n minute?: string;\n second?: string;\n timeZoneName?: string;\n formatMatcher?: string;\n hour12?: boolean;\n timeZone?: string;\n }\n\n interface ResolvedDateTimeFormatOptions {\n locale: string;\n calendar: string;\n numberingSystem: string;\n timeZone: string;\n hour12?: boolean;\n weekday?: string;\n era?: string;\n year?: string;\n month?: string;\n day?: string;\n hour?: string;\n minute?: string;\n second?: string;\n timeZoneName?: string;\n }\n\n interface DateTimeFormat {\n format(date?: Date | number): string;\n resolvedOptions(): ResolvedDateTimeFormatOptions;\n }\n var DateTimeFormat: {\n new (locales?: string | string[], options?: DateTimeFormatOptions): DateTimeFormat;\n (locales?: string | string[], options?: DateTimeFormatOptions): DateTimeFormat;\n supportedLocalesOf(locales: string | string[], options?: DateTimeFormatOptions): string[];\n };\n}\n\ninterface String {\n /**\n * Determines whether two strings are equivalent in the current or specified locale.\n * @param that String to compare to target string\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used. This parameter must conform to BCP 47 standards; see the Intl.Collator object for details.\n * @param options An object that contains one or more properties that specify comparison options. see the Intl.Collator object for details.\n */\n localeCompare(that: string, locales?: string | string[], options?: Intl.CollatorOptions): number;\n}\n\ninterface Number {\n /**\n * Converts a number to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleString(locales?: string | string[], options?: Intl.NumberFormatOptions): string;\n}\n\ninterface Date {\n /**\n * Converts a date and time to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleString(locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;\n /**\n * Converts a date to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleDateString(locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;\n\n /**\n * Converts a time to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleTimeString(locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;\n}\n\n\n\n/////////////////////////////\n/// IE DOM APIs\n/////////////////////////////\n\ninterface Account {\n rpDisplayName?: string;\n displayName?: string;\n id?: string;\n name?: string;\n imageURL?: string;\n}\n\ninterface Algorithm {\n name: string;\n}\n\ninterface AnimationEventInit extends EventInit {\n animationName?: string;\n elapsedTime?: number;\n}\n\ninterface AssertionOptions {\n timeoutSeconds?: number;\n rpId?: USVString;\n allowList?: ScopedCredentialDescriptor[];\n extensions?: WebAuthnExtensions;\n}\n\ninterface CacheQueryOptions {\n ignoreSearch?: boolean;\n ignoreMethod?: boolean;\n ignoreVary?: boolean;\n cacheName?: string;\n}\n\ninterface ClientData {\n challenge?: string;\n origin?: string;\n rpId?: string;\n hashAlg?: string | Algorithm;\n tokenBinding?: string;\n extensions?: WebAuthnExtensions;\n}\n\ninterface CloseEventInit extends EventInit {\n wasClean?: boolean;\n code?: number;\n reason?: string;\n}\n\ninterface CompositionEventInit extends UIEventInit {\n data?: string;\n}\n\ninterface ConfirmSiteSpecificExceptionsInformation extends ExceptionInformation {\n arrayOfDomainStrings?: string[];\n}\n\ninterface ConstrainBooleanParameters {\n exact?: boolean;\n ideal?: boolean;\n}\n\ninterface ConstrainDOMStringParameters {\n exact?: string | string[];\n ideal?: string | string[];\n}\n\ninterface ConstrainDoubleRange extends DoubleRange {\n exact?: number;\n ideal?: number;\n}\n\ninterface ConstrainLongRange extends LongRange {\n exact?: number;\n ideal?: number;\n}\n\ninterface ConstrainVideoFacingModeParameters {\n exact?: VideoFacingModeEnum | VideoFacingModeEnum[];\n ideal?: VideoFacingModeEnum | VideoFacingModeEnum[];\n}\n\ninterface CustomEventInit extends EventInit {\n detail?: any;\n}\n\ninterface DOMRectInit {\n x?: any;\n y?: any;\n width?: any;\n height?: any;\n}\n\ninterface DeviceAccelerationDict {\n x?: number;\n y?: number;\n z?: number;\n}\n\ninterface DeviceLightEventInit extends EventInit {\n value?: number;\n}\n\ninterface DeviceMotionEventInit extends EventInit {\n acceleration?: DeviceAccelerationDict;\n accelerationIncludingGravity?: DeviceAccelerationDict;\n rotationRate?: DeviceRotationRateDict;\n interval?: number;\n}\n\ninterface DeviceOrientationEventInit extends EventInit {\n alpha?: number;\n beta?: number;\n gamma?: number;\n absolute?: boolean;\n}\n\ninterface DeviceRotationRateDict {\n alpha?: number;\n beta?: number;\n gamma?: number;\n}\n\ninterface DoubleRange {\n max?: number;\n min?: number;\n}\n\ninterface ErrorEventInit extends EventInit {\n message?: string;\n filename?: string;\n lineno?: number;\n colno?: number;\n error?: any;\n}\n\ninterface EventInit {\n scoped?: boolean;\n bubbles?: boolean;\n cancelable?: boolean;\n}\n\ninterface EventModifierInit extends UIEventInit {\n ctrlKey?: boolean;\n shiftKey?: boolean;\n altKey?: boolean;\n metaKey?: boolean;\n modifierAltGraph?: boolean;\n modifierCapsLock?: boolean;\n modifierFn?: boolean;\n modifierFnLock?: boolean;\n modifierHyper?: boolean;\n modifierNumLock?: boolean;\n modifierOS?: boolean;\n modifierScrollLock?: boolean;\n modifierSuper?: boolean;\n modifierSymbol?: boolean;\n modifierSymbolLock?: boolean;\n}\n\ninterface ExceptionInformation {\n domain?: string;\n}\n\ninterface FocusEventInit extends UIEventInit {\n relatedTarget?: EventTarget;\n}\n\ninterface FocusNavigationEventInit extends EventInit {\n navigationReason?: string;\n originLeft?: number;\n originTop?: number;\n originWidth?: number;\n originHeight?: number;\n}\n\ninterface FocusNavigationOrigin {\n originLeft?: number;\n originTop?: number;\n originWidth?: number;\n originHeight?: number;\n}\n\ninterface GamepadEventInit extends EventInit {\n gamepad?: Gamepad;\n}\n\ninterface GetNotificationOptions {\n tag?: string;\n}\n\ninterface HashChangeEventInit extends EventInit {\n newURL?: string;\n oldURL?: string;\n}\n\ninterface IDBIndexParameters {\n multiEntry?: boolean;\n unique?: boolean;\n}\n\ninterface IDBObjectStoreParameters {\n autoIncrement?: boolean;\n keyPath?: IDBKeyPath;\n}\n\ninterface IntersectionObserverEntryInit {\n time?: number;\n rootBounds?: DOMRectInit;\n boundingClientRect?: DOMRectInit;\n intersectionRect?: DOMRectInit;\n target?: Element;\n}\n\ninterface IntersectionObserverInit {\n root?: Element;\n rootMargin?: string;\n threshold?: number | number[];\n}\n\ninterface KeyAlgorithm {\n name?: string;\n}\n\ninterface KeyboardEventInit extends EventModifierInit {\n code?: string;\n key?: string;\n location?: number;\n repeat?: boolean;\n}\n\ninterface LongRange {\n max?: number;\n min?: number;\n}\n\ninterface MSAccountInfo {\n rpDisplayName?: string;\n userDisplayName?: string;\n accountName?: string;\n userId?: string;\n accountImageUri?: string;\n}\n\ninterface MSAudioLocalClientEvent extends MSLocalClientEventBase {\n networkSendQualityEventRatio?: number;\n networkDelayEventRatio?: number;\n cpuInsufficientEventRatio?: number;\n deviceHalfDuplexAECEventRatio?: number;\n deviceRenderNotFunctioningEventRatio?: number;\n deviceCaptureNotFunctioningEventRatio?: number;\n deviceGlitchesEventRatio?: number;\n deviceLowSNREventRatio?: number;\n deviceLowSpeechLevelEventRatio?: number;\n deviceClippingEventRatio?: number;\n deviceEchoEventRatio?: number;\n deviceNearEndToEchoRatioEventRatio?: number;\n deviceRenderZeroVolumeEventRatio?: number;\n deviceRenderMuteEventRatio?: number;\n deviceMultipleEndpointsEventCount?: number;\n deviceHowlingEventCount?: number;\n}\n\ninterface MSAudioRecvPayload extends MSPayloadBase {\n samplingRate?: number;\n signal?: MSAudioRecvSignal;\n packetReorderRatio?: number;\n packetReorderDepthAvg?: number;\n packetReorderDepthMax?: number;\n burstLossLength1?: number;\n burstLossLength2?: number;\n burstLossLength3?: number;\n burstLossLength4?: number;\n burstLossLength5?: number;\n burstLossLength6?: number;\n burstLossLength7?: number;\n burstLossLength8OrHigher?: number;\n fecRecvDistance1?: number;\n fecRecvDistance2?: number;\n fecRecvDistance3?: number;\n ratioConcealedSamplesAvg?: number;\n ratioStretchedSamplesAvg?: number;\n ratioCompressedSamplesAvg?: number;\n}\n\ninterface MSAudioRecvSignal {\n initialSignalLevelRMS?: number;\n recvSignalLevelCh1?: number;\n recvNoiseLevelCh1?: number;\n renderSignalLevel?: number;\n renderNoiseLevel?: number;\n renderLoopbackSignalLevel?: number;\n}\n\ninterface MSAudioSendPayload extends MSPayloadBase {\n samplingRate?: number;\n signal?: MSAudioSendSignal;\n audioFECUsed?: boolean;\n sendMutePercent?: number;\n}\n\ninterface MSAudioSendSignal {\n noiseLevel?: number;\n sendSignalLevelCh1?: number;\n sendNoiseLevelCh1?: number;\n}\n\ninterface MSConnectivity {\n iceType?: MSIceType;\n iceWarningFlags?: MSIceWarningFlags;\n relayAddress?: MSRelayAddress;\n}\n\ninterface MSCredentialFilter {\n accept?: MSCredentialSpec[];\n}\n\ninterface MSCredentialParameters {\n type?: MSCredentialType;\n}\n\ninterface MSCredentialSpec {\n type?: MSCredentialType;\n id?: string;\n}\n\ninterface MSDelay {\n roundTrip?: number;\n roundTripMax?: number;\n}\n\ninterface MSDescription extends RTCStats {\n connectivity?: MSConnectivity;\n transport?: RTCIceProtocol;\n networkconnectivity?: MSNetworkConnectivityInfo;\n localAddr?: MSIPAddressInfo;\n remoteAddr?: MSIPAddressInfo;\n deviceDevName?: string;\n reflexiveLocalIPAddr?: MSIPAddressInfo;\n}\n\ninterface MSFIDOCredentialParameters extends MSCredentialParameters {\n algorithm?: string | Algorithm;\n authenticators?: AAGUID[];\n}\n\ninterface MSIPAddressInfo {\n ipAddr?: string;\n port?: number;\n manufacturerMacAddrMask?: string;\n}\n\ninterface MSIceWarningFlags {\n turnTcpTimedOut?: boolean;\n turnUdpAllocateFailed?: boolean;\n turnUdpSendFailed?: boolean;\n turnTcpAllocateFailed?: boolean;\n turnTcpSendFailed?: boolean;\n udpLocalConnectivityFailed?: boolean;\n udpNatConnectivityFailed?: boolean;\n udpRelayConnectivityFailed?: boolean;\n tcpNatConnectivityFailed?: boolean;\n tcpRelayConnectivityFailed?: boolean;\n connCheckMessageIntegrityFailed?: boolean;\n allocationMessageIntegrityFailed?: boolean;\n connCheckOtherError?: boolean;\n turnAuthUnknownUsernameError?: boolean;\n noRelayServersConfigured?: boolean;\n multipleRelayServersAttempted?: boolean;\n portRangeExhausted?: boolean;\n alternateServerReceived?: boolean;\n pseudoTLSFailure?: boolean;\n turnTurnTcpConnectivityFailed?: boolean;\n useCandidateChecksFailed?: boolean;\n fipsAllocationFailure?: boolean;\n}\n\ninterface MSJitter {\n interArrival?: number;\n interArrivalMax?: number;\n interArrivalSD?: number;\n}\n\ninterface MSLocalClientEventBase extends RTCStats {\n networkReceiveQualityEventRatio?: number;\n networkBandwidthLowEventRatio?: number;\n}\n\ninterface MSNetwork extends RTCStats {\n jitter?: MSJitter;\n delay?: MSDelay;\n packetLoss?: MSPacketLoss;\n utilization?: MSUtilization;\n}\n\ninterface MSNetworkConnectivityInfo {\n vpn?: boolean;\n linkspeed?: number;\n networkConnectionDetails?: string;\n}\n\ninterface MSNetworkInterfaceType {\n interfaceTypeEthernet?: boolean;\n interfaceTypeWireless?: boolean;\n interfaceTypePPP?: boolean;\n interfaceTypeTunnel?: boolean;\n interfaceTypeWWAN?: boolean;\n}\n\ninterface MSOutboundNetwork extends MSNetwork {\n appliedBandwidthLimit?: number;\n}\n\ninterface MSPacketLoss {\n lossRate?: number;\n lossRateMax?: number;\n}\n\ninterface MSPayloadBase extends RTCStats {\n payloadDescription?: string;\n}\n\ninterface MSPortRange {\n min?: number;\n max?: number;\n}\n\ninterface MSRelayAddress {\n relayAddress?: string;\n port?: number;\n}\n\ninterface MSSignatureParameters {\n userPrompt?: string;\n}\n\ninterface MSTransportDiagnosticsStats extends RTCStats {\n baseAddress?: string;\n localAddress?: string;\n localSite?: string;\n networkName?: string;\n remoteAddress?: string;\n remoteSite?: string;\n localMR?: string;\n remoteMR?: string;\n iceWarningFlags?: MSIceWarningFlags;\n portRangeMin?: number;\n portRangeMax?: number;\n localMRTCPPort?: number;\n remoteMRTCPPort?: number;\n stunVer?: number;\n numConsentReqSent?: number;\n numConsentReqReceived?: number;\n numConsentRespSent?: number;\n numConsentRespReceived?: number;\n interfaces?: MSNetworkInterfaceType;\n baseInterface?: MSNetworkInterfaceType;\n protocol?: RTCIceProtocol;\n localInterface?: MSNetworkInterfaceType;\n localAddrType?: MSIceAddrType;\n remoteAddrType?: MSIceAddrType;\n iceRole?: RTCIceRole;\n rtpRtcpMux?: boolean;\n allocationTimeInMs?: number;\n msRtcEngineVersion?: string;\n}\n\ninterface MSUtilization {\n packets?: number;\n bandwidthEstimation?: number;\n bandwidthEstimationMin?: number;\n bandwidthEstimationMax?: number;\n bandwidthEstimationStdDev?: number;\n bandwidthEstimationAvg?: number;\n}\n\ninterface MSVideoPayload extends MSPayloadBase {\n resolution?: string;\n videoBitRateAvg?: number;\n videoBitRateMax?: number;\n videoFrameRateAvg?: number;\n videoPacketLossRate?: number;\n durationSeconds?: number;\n}\n\ninterface MSVideoRecvPayload extends MSVideoPayload {\n videoFrameLossRate?: number;\n recvCodecType?: string;\n recvResolutionWidth?: number;\n recvResolutionHeight?: number;\n videoResolutions?: MSVideoResolutionDistribution;\n recvFrameRateAverage?: number;\n recvBitRateMaximum?: number;\n recvBitRateAverage?: number;\n recvVideoStreamsMax?: number;\n recvVideoStreamsMin?: number;\n recvVideoStreamsMode?: number;\n videoPostFECPLR?: number;\n lowBitRateCallPercent?: number;\n lowFrameRateCallPercent?: number;\n reorderBufferTotalPackets?: number;\n recvReorderBufferReorderedPackets?: number;\n recvReorderBufferPacketsDroppedDueToBufferExhaustion?: number;\n recvReorderBufferMaxSuccessfullyOrderedExtent?: number;\n recvReorderBufferMaxSuccessfullyOrderedLateTime?: number;\n recvReorderBufferPacketsDroppedDueToTimeout?: number;\n recvFpsHarmonicAverage?: number;\n recvNumResSwitches?: number;\n}\n\ninterface MSVideoResolutionDistribution {\n cifQuality?: number;\n vgaQuality?: number;\n h720Quality?: number;\n h1080Quality?: number;\n h1440Quality?: number;\n h2160Quality?: number;\n}\n\ninterface MSVideoSendPayload extends MSVideoPayload {\n sendFrameRateAverage?: number;\n sendBitRateMaximum?: number;\n sendBitRateAverage?: number;\n sendVideoStreamsMax?: number;\n sendResolutionWidth?: number;\n sendResolutionHeight?: number;\n}\n\ninterface MediaEncryptedEventInit extends EventInit {\n initDataType?: string;\n initData?: ArrayBuffer;\n}\n\ninterface MediaKeyMessageEventInit extends EventInit {\n messageType?: MediaKeyMessageType;\n message?: ArrayBuffer;\n}\n\ninterface MediaKeySystemConfiguration {\n initDataTypes?: string[];\n audioCapabilities?: MediaKeySystemMediaCapability[];\n videoCapabilities?: MediaKeySystemMediaCapability[];\n distinctiveIdentifier?: MediaKeysRequirement;\n persistentState?: MediaKeysRequirement;\n}\n\ninterface MediaKeySystemMediaCapability {\n contentType?: string;\n robustness?: string;\n}\n\ninterface MediaStreamConstraints {\n video?: boolean | MediaTrackConstraints;\n audio?: boolean | MediaTrackConstraints;\n}\n\ninterface MediaStreamErrorEventInit extends EventInit {\n error?: MediaStreamError;\n}\n\ninterface MediaStreamEventInit extends EventInit {\n stream?: MediaStream;\n}\n\ninterface MediaStreamTrackEventInit extends EventInit {\n track?: MediaStreamTrack;\n}\n\ninterface MediaTrackCapabilities {\n width?: number | LongRange;\n height?: number | LongRange;\n aspectRatio?: number | DoubleRange;\n frameRate?: number | DoubleRange;\n facingMode?: string;\n volume?: number | DoubleRange;\n sampleRate?: number | LongRange;\n sampleSize?: number | LongRange;\n echoCancellation?: boolean[];\n deviceId?: string;\n groupId?: string;\n}\n\ninterface MediaTrackConstraintSet {\n width?: number | ConstrainLongRange;\n height?: number | ConstrainLongRange;\n aspectRatio?: number | ConstrainDoubleRange;\n frameRate?: number | ConstrainDoubleRange;\n facingMode?: string | string[] | ConstrainDOMStringParameters;\n volume?: number | ConstrainDoubleRange;\n sampleRate?: number | ConstrainLongRange;\n sampleSize?: number | ConstrainLongRange;\n echoCancelation?: boolean | ConstrainBooleanParameters;\n deviceId?: string | string[] | ConstrainDOMStringParameters;\n groupId?: string | string[] | ConstrainDOMStringParameters;\n}\n\ninterface MediaTrackConstraints extends MediaTrackConstraintSet {\n advanced?: MediaTrackConstraintSet[];\n}\n\ninterface MediaTrackSettings {\n width?: number;\n height?: number;\n aspectRatio?: number;\n frameRate?: number;\n facingMode?: string;\n volume?: number;\n sampleRate?: number;\n sampleSize?: number;\n echoCancellation?: boolean;\n deviceId?: string;\n groupId?: string;\n}\n\ninterface MediaTrackSupportedConstraints {\n width?: boolean;\n height?: boolean;\n aspectRatio?: boolean;\n frameRate?: boolean;\n facingMode?: boolean;\n volume?: boolean;\n sampleRate?: boolean;\n sampleSize?: boolean;\n echoCancellation?: boolean;\n deviceId?: boolean;\n groupId?: boolean;\n}\n\ninterface MessageEventInit extends EventInit {\n lastEventId?: string;\n channel?: string;\n data?: any;\n origin?: string;\n source?: Window;\n ports?: MessagePort[];\n}\n\ninterface MouseEventInit extends EventModifierInit {\n screenX?: number;\n screenY?: number;\n clientX?: number;\n clientY?: number;\n button?: number;\n buttons?: number;\n relatedTarget?: EventTarget;\n}\n\ninterface MsZoomToOptions {\n contentX?: number;\n contentY?: number;\n viewportX?: string;\n viewportY?: string;\n scaleFactor?: number;\n animate?: string;\n}\n\ninterface MutationObserverInit {\n childList?: boolean;\n attributes?: boolean;\n characterData?: boolean;\n subtree?: boolean;\n attributeOldValue?: boolean;\n characterDataOldValue?: boolean;\n attributeFilter?: string[];\n}\n\ninterface NotificationOptions {\n dir?: NotificationDirection;\n lang?: string;\n body?: string;\n tag?: string;\n icon?: string;\n}\n\ninterface ObjectURLOptions {\n oneTimeOnly?: boolean;\n}\n\ninterface PaymentCurrencyAmount {\n currency?: string;\n value?: string;\n currencySystem?: string;\n}\n\ninterface PaymentDetails {\n total?: PaymentItem;\n displayItems?: PaymentItem[];\n shippingOptions?: PaymentShippingOption[];\n modifiers?: PaymentDetailsModifier[];\n error?: string;\n}\n\ninterface PaymentDetailsModifier {\n supportedMethods?: string[];\n total?: PaymentItem;\n additionalDisplayItems?: PaymentItem[];\n data?: any;\n}\n\ninterface PaymentItem {\n label?: string;\n amount?: PaymentCurrencyAmount;\n pending?: boolean;\n}\n\ninterface PaymentMethodData {\n supportedMethods?: string[];\n data?: any;\n}\n\ninterface PaymentOptions {\n requestPayerName?: boolean;\n requestPayerEmail?: boolean;\n requestPayerPhone?: boolean;\n requestShipping?: boolean;\n shippingType?: string;\n}\n\ninterface PaymentRequestUpdateEventInit extends EventInit {\n}\n\ninterface PaymentShippingOption {\n id?: string;\n label?: string;\n amount?: PaymentCurrencyAmount;\n selected?: boolean;\n}\n\ninterface PeriodicWaveConstraints {\n disableNormalization?: boolean;\n}\n\ninterface PointerEventInit extends MouseEventInit {\n pointerId?: number;\n width?: number;\n height?: number;\n pressure?: number;\n tiltX?: number;\n tiltY?: number;\n pointerType?: string;\n isPrimary?: boolean;\n}\n\ninterface PopStateEventInit extends EventInit {\n state?: any;\n}\n\ninterface PositionOptions {\n enableHighAccuracy?: boolean;\n timeout?: number;\n maximumAge?: number;\n}\n\ninterface ProgressEventInit extends EventInit {\n lengthComputable?: boolean;\n loaded?: number;\n total?: number;\n}\n\ninterface PushSubscriptionOptionsInit {\n userVisibleOnly?: boolean;\n applicationServerKey?: any;\n}\n\ninterface RTCConfiguration {\n iceServers?: RTCIceServer[];\n iceTransportPolicy?: RTCIceTransportPolicy;\n bundlePolicy?: RTCBundlePolicy;\n peerIdentity?: string;\n}\n\ninterface RTCDTMFToneChangeEventInit extends EventInit {\n tone?: string;\n}\n\ninterface RTCDtlsFingerprint {\n algorithm?: string;\n value?: string;\n}\n\ninterface RTCDtlsParameters {\n role?: RTCDtlsRole;\n fingerprints?: RTCDtlsFingerprint[];\n}\n\ninterface RTCIceCandidateAttributes extends RTCStats {\n ipAddress?: string;\n portNumber?: number;\n transport?: string;\n candidateType?: RTCStatsIceCandidateType;\n priority?: number;\n addressSourceUrl?: string;\n}\n\ninterface RTCIceCandidateComplete {\n}\n\ninterface RTCIceCandidateDictionary {\n foundation?: string;\n priority?: number;\n ip?: string;\n protocol?: RTCIceProtocol;\n port?: number;\n type?: RTCIceCandidateType;\n tcpType?: RTCIceTcpCandidateType;\n relatedAddress?: string;\n relatedPort?: number;\n msMTurnSessionId?: string;\n}\n\ninterface RTCIceCandidateInit {\n candidate?: string;\n sdpMid?: string;\n sdpMLineIndex?: number;\n}\n\ninterface RTCIceCandidatePair {\n local?: RTCIceCandidateDictionary;\n remote?: RTCIceCandidateDictionary;\n}\n\ninterface RTCIceCandidatePairStats extends RTCStats {\n transportId?: string;\n localCandidateId?: string;\n remoteCandidateId?: string;\n state?: RTCStatsIceCandidatePairState;\n priority?: number;\n nominated?: boolean;\n writable?: boolean;\n readable?: boolean;\n bytesSent?: number;\n bytesReceived?: number;\n roundTripTime?: number;\n availableOutgoingBitrate?: number;\n availableIncomingBitrate?: number;\n}\n\ninterface RTCIceGatherOptions {\n gatherPolicy?: RTCIceGatherPolicy;\n iceservers?: RTCIceServer[];\n portRange?: MSPortRange;\n}\n\ninterface RTCIceParameters {\n usernameFragment?: string;\n password?: string;\n iceLite?: boolean;\n}\n\ninterface RTCIceServer {\n urls?: any;\n username?: string;\n credential?: string;\n}\n\ninterface RTCInboundRTPStreamStats extends RTCRTPStreamStats {\n packetsReceived?: number;\n bytesReceived?: number;\n packetsLost?: number;\n jitter?: number;\n fractionLost?: number;\n}\n\ninterface RTCMediaStreamTrackStats extends RTCStats {\n trackIdentifier?: string;\n remoteSource?: boolean;\n ssrcIds?: string[];\n frameWidth?: number;\n frameHeight?: number;\n framesPerSecond?: number;\n framesSent?: number;\n framesReceived?: number;\n framesDecoded?: number;\n framesDropped?: number;\n framesCorrupted?: number;\n audioLevel?: number;\n echoReturnLoss?: number;\n echoReturnLossEnhancement?: number;\n}\n\ninterface RTCOfferOptions {\n offerToReceiveVideo?: number;\n offerToReceiveAudio?: number;\n voiceActivityDetection?: boolean;\n iceRestart?: boolean;\n}\n\ninterface RTCOutboundRTPStreamStats extends RTCRTPStreamStats {\n packetsSent?: number;\n bytesSent?: number;\n targetBitrate?: number;\n roundTripTime?: number;\n}\n\ninterface RTCPeerConnectionIceEventInit extends EventInit {\n candidate?: RTCIceCandidate;\n}\n\ninterface RTCRTPStreamStats extends RTCStats {\n ssrc?: string;\n associateStatsId?: string;\n isRemote?: boolean;\n mediaTrackId?: string;\n transportId?: string;\n codecId?: string;\n firCount?: number;\n pliCount?: number;\n nackCount?: number;\n sliCount?: number;\n}\n\ninterface RTCRtcpFeedback {\n type?: string;\n parameter?: string;\n}\n\ninterface RTCRtcpParameters {\n ssrc?: number;\n cname?: string;\n reducedSize?: boolean;\n mux?: boolean;\n}\n\ninterface RTCRtpCapabilities {\n codecs?: RTCRtpCodecCapability[];\n headerExtensions?: RTCRtpHeaderExtension[];\n fecMechanisms?: string[];\n}\n\ninterface RTCRtpCodecCapability {\n name?: string;\n kind?: string;\n clockRate?: number;\n preferredPayloadType?: number;\n maxptime?: number;\n ptime?: number;\n numChannels?: number;\n rtcpFeedback?: RTCRtcpFeedback[];\n parameters?: any;\n options?: any;\n maxTemporalLayers?: number;\n maxSpatialLayers?: number;\n svcMultiStreamSupport?: boolean;\n}\n\ninterface RTCRtpCodecParameters {\n name?: string;\n payloadType?: any;\n clockRate?: number;\n maxptime?: number;\n ptime?: number;\n numChannels?: number;\n rtcpFeedback?: RTCRtcpFeedback[];\n parameters?: any;\n}\n\ninterface RTCRtpContributingSource {\n timestamp?: number;\n csrc?: number;\n audioLevel?: number;\n}\n\ninterface RTCRtpEncodingParameters {\n ssrc?: number;\n codecPayloadType?: number;\n fec?: RTCRtpFecParameters;\n rtx?: RTCRtpRtxParameters;\n priority?: number;\n maxBitrate?: number;\n minQuality?: number;\n resolutionScale?: number;\n framerateScale?: number;\n maxFramerate?: number;\n active?: boolean;\n encodingId?: string;\n dependencyEncodingIds?: string[];\n ssrcRange?: RTCSsrcRange;\n}\n\ninterface RTCRtpFecParameters {\n ssrc?: number;\n mechanism?: string;\n}\n\ninterface RTCRtpHeaderExtension {\n kind?: string;\n uri?: string;\n preferredId?: number;\n preferredEncrypt?: boolean;\n}\n\ninterface RTCRtpHeaderExtensionParameters {\n uri?: string;\n id?: number;\n encrypt?: boolean;\n}\n\ninterface RTCRtpParameters {\n muxId?: string;\n codecs?: RTCRtpCodecParameters[];\n headerExtensions?: RTCRtpHeaderExtensionParameters[];\n encodings?: RTCRtpEncodingParameters[];\n rtcp?: RTCRtcpParameters;\n degradationPreference?: RTCDegradationPreference;\n}\n\ninterface RTCRtpRtxParameters {\n ssrc?: number;\n}\n\ninterface RTCRtpUnhandled {\n ssrc?: number;\n payloadType?: number;\n muxId?: string;\n}\n\ninterface RTCSessionDescriptionInit {\n type?: RTCSdpType;\n sdp?: string;\n}\n\ninterface RTCSrtpKeyParam {\n keyMethod?: string;\n keySalt?: string;\n lifetime?: string;\n mkiValue?: number;\n mkiLength?: number;\n}\n\ninterface RTCSrtpSdesParameters {\n tag?: number;\n cryptoSuite?: string;\n keyParams?: RTCSrtpKeyParam[];\n sessionParams?: string[];\n}\n\ninterface RTCSsrcRange {\n min?: number;\n max?: number;\n}\n\ninterface RTCStats {\n timestamp?: number;\n type?: RTCStatsType;\n id?: string;\n msType?: MSStatsType;\n}\n\ninterface RTCStatsReport {\n}\n\ninterface RTCTransportStats extends RTCStats {\n bytesSent?: number;\n bytesReceived?: number;\n rtcpTransportStatsId?: string;\n activeConnection?: boolean;\n selectedCandidatePairId?: string;\n localCertificateId?: string;\n remoteCertificateId?: string;\n}\n\ninterface RegistrationOptions {\n scope?: string;\n}\n\ninterface RequestInit {\n method?: string;\n headers?: any;\n body?: any;\n referrer?: string;\n referrerPolicy?: ReferrerPolicy;\n mode?: RequestMode;\n credentials?: RequestCredentials;\n cache?: RequestCache;\n redirect?: RequestRedirect;\n integrity?: string;\n keepalive?: boolean;\n window?: any;\n}\n\ninterface ResponseInit {\n status?: number;\n statusText?: string;\n headers?: any;\n}\n\ninterface ScopedCredentialDescriptor {\n type?: ScopedCredentialType;\n id?: any;\n transports?: Transport[];\n}\n\ninterface ScopedCredentialOptions {\n timeoutSeconds?: number;\n rpId?: USVString;\n excludeList?: ScopedCredentialDescriptor[];\n extensions?: WebAuthnExtensions;\n}\n\ninterface ScopedCredentialParameters {\n type?: ScopedCredentialType;\n algorithm?: string | Algorithm;\n}\n\ninterface ServiceWorkerMessageEventInit extends EventInit {\n data?: any;\n origin?: string;\n lastEventId?: string;\n source?: ServiceWorker | MessagePort;\n ports?: MessagePort[];\n}\n\ninterface SpeechSynthesisEventInit extends EventInit {\n utterance?: SpeechSynthesisUtterance;\n charIndex?: number;\n elapsedTime?: number;\n name?: string;\n}\n\ninterface StoreExceptionsInformation extends ExceptionInformation {\n siteName?: string;\n explanationString?: string;\n detailURI?: string;\n}\n\ninterface StoreSiteSpecificExceptionsInformation extends StoreExceptionsInformation {\n arrayOfDomainStrings?: string[];\n}\n\ninterface TrackEventInit extends EventInit {\n track?: VideoTrack | AudioTrack | TextTrack;\n}\n\ninterface TransitionEventInit extends EventInit {\n propertyName?: string;\n elapsedTime?: number;\n}\n\ninterface UIEventInit extends EventInit {\n view?: Window;\n detail?: number;\n}\n\ninterface WebAuthnExtensions {\n}\n\ninterface WebGLContextAttributes {\n failIfMajorPerformanceCaveat?: boolean;\n alpha?: boolean;\n depth?: boolean;\n stencil?: boolean;\n antialias?: boolean;\n premultipliedAlpha?: boolean;\n preserveDrawingBuffer?: boolean;\n}\n\ninterface WebGLContextEventInit extends EventInit {\n statusMessage?: string;\n}\n\ninterface WheelEventInit extends MouseEventInit {\n deltaX?: number;\n deltaY?: number;\n deltaZ?: number;\n deltaMode?: number;\n}\n\ninterface EventListener {\n (evt: Event): void;\n}\n\ninterface WebKitEntriesCallback {\n (evt: Event): void;\n}\n\ninterface WebKitErrorCallback {\n (evt: Event): void;\n}\n\ninterface WebKitFileCallback {\n (evt: Event): void;\n}\n\ninterface ANGLE_instanced_arrays {\n drawArraysInstancedANGLE(mode: number, first: number, count: number, primcount: number): void;\n drawElementsInstancedANGLE(mode: number, count: number, type: number, offset: number, primcount: number): void;\n vertexAttribDivisorANGLE(index: number, divisor: number): void;\n readonly VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE: number;\n}\n\ndeclare var ANGLE_instanced_arrays: {\n prototype: ANGLE_instanced_arrays;\n new(): ANGLE_instanced_arrays;\n readonly VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE: number;\n}\n\ninterface AnalyserNode extends AudioNode {\n fftSize: number;\n readonly frequencyBinCount: number;\n maxDecibels: number;\n minDecibels: number;\n smoothingTimeConstant: number;\n getByteFrequencyData(array: Uint8Array): void;\n getByteTimeDomainData(array: Uint8Array): void;\n getFloatFrequencyData(array: Float32Array): void;\n getFloatTimeDomainData(array: Float32Array): void;\n}\n\ndeclare var AnalyserNode: {\n prototype: AnalyserNode;\n new(): AnalyserNode;\n}\n\ninterface AnimationEvent extends Event {\n readonly animationName: string;\n readonly elapsedTime: number;\n initAnimationEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, animationNameArg: string, elapsedTimeArg: number): void;\n}\n\ndeclare var AnimationEvent: {\n prototype: AnimationEvent;\n new(typeArg: string, eventInitDict?: AnimationEventInit): AnimationEvent;\n}\n\ninterface ApplicationCacheEventMap {\n \"cached\": Event;\n \"checking\": Event;\n \"downloading\": Event;\n \"error\": Event;\n \"noupdate\": Event;\n \"obsolete\": Event;\n \"progress\": ProgressEvent;\n \"updateready\": Event;\n}\n\ninterface ApplicationCache extends EventTarget {\n oncached: (this: ApplicationCache, ev: Event) => any;\n onchecking: (this: ApplicationCache, ev: Event) => any;\n ondownloading: (this: ApplicationCache, ev: Event) => any;\n onerror: (this: ApplicationCache, ev: Event) => any;\n onnoupdate: (this: ApplicationCache, ev: Event) => any;\n onobsolete: (this: ApplicationCache, ev: Event) => any;\n onprogress: (this: ApplicationCache, ev: ProgressEvent) => any;\n onupdateready: (this: ApplicationCache, ev: Event) => any;\n readonly status: number;\n abort(): void;\n swapCache(): void;\n update(): void;\n readonly CHECKING: number;\n readonly DOWNLOADING: number;\n readonly IDLE: number;\n readonly OBSOLETE: number;\n readonly UNCACHED: number;\n readonly UPDATEREADY: number;\n addEventListener(type: K, listener: (this: ApplicationCache, ev: ApplicationCacheEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ApplicationCache: {\n prototype: ApplicationCache;\n new(): ApplicationCache;\n readonly CHECKING: number;\n readonly DOWNLOADING: number;\n readonly IDLE: number;\n readonly OBSOLETE: number;\n readonly UNCACHED: number;\n readonly UPDATEREADY: number;\n}\n\ninterface Attr extends Node {\n readonly name: string;\n readonly ownerElement: Element;\n readonly prefix: string | null;\n readonly specified: boolean;\n value: string;\n}\n\ndeclare var Attr: {\n prototype: Attr;\n new(): Attr;\n}\n\ninterface AudioBuffer {\n readonly duration: number;\n readonly length: number;\n readonly numberOfChannels: number;\n readonly sampleRate: number;\n copyFromChannel(destination: Float32Array, channelNumber: number, startInChannel?: number): void;\n copyToChannel(source: Float32Array, channelNumber: number, startInChannel?: number): void;\n getChannelData(channel: number): Float32Array;\n}\n\ndeclare var AudioBuffer: {\n prototype: AudioBuffer;\n new(): AudioBuffer;\n}\n\ninterface AudioBufferSourceNodeEventMap {\n \"ended\": MediaStreamErrorEvent;\n}\n\ninterface AudioBufferSourceNode extends AudioNode {\n buffer: AudioBuffer | null;\n readonly detune: AudioParam;\n loop: boolean;\n loopEnd: number;\n loopStart: number;\n onended: (this: AudioBufferSourceNode, ev: MediaStreamErrorEvent) => any;\n readonly playbackRate: AudioParam;\n start(when?: number, offset?: number, duration?: number): void;\n stop(when?: number): void;\n addEventListener(type: K, listener: (this: AudioBufferSourceNode, ev: AudioBufferSourceNodeEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var AudioBufferSourceNode: {\n prototype: AudioBufferSourceNode;\n new(): AudioBufferSourceNode;\n}\n\ninterface AudioContextEventMap {\n \"statechange\": Event;\n}\n\ninterface AudioContextBase extends EventTarget {\n readonly currentTime: number;\n readonly destination: AudioDestinationNode;\n readonly listener: AudioListener;\n onstatechange: (this: AudioContext, ev: Event) => any;\n readonly sampleRate: number;\n readonly state: AudioContextState;\n close(): Promise;\n createAnalyser(): AnalyserNode;\n createBiquadFilter(): BiquadFilterNode;\n createBuffer(numberOfChannels: number, length: number, sampleRate: number): AudioBuffer;\n createBufferSource(): AudioBufferSourceNode;\n createChannelMerger(numberOfInputs?: number): ChannelMergerNode;\n createChannelSplitter(numberOfOutputs?: number): ChannelSplitterNode;\n createConvolver(): ConvolverNode;\n createDelay(maxDelayTime?: number): DelayNode;\n createDynamicsCompressor(): DynamicsCompressorNode;\n createGain(): GainNode;\n createIIRFilter(feedforward: number[], feedback: number[]): IIRFilterNode;\n createMediaElementSource(mediaElement: HTMLMediaElement): MediaElementAudioSourceNode;\n createMediaStreamSource(mediaStream: MediaStream): MediaStreamAudioSourceNode;\n createOscillator(): OscillatorNode;\n createPanner(): PannerNode;\n createPeriodicWave(real: Float32Array, imag: Float32Array, constraints?: PeriodicWaveConstraints): PeriodicWave;\n createScriptProcessor(bufferSize?: number, numberOfInputChannels?: number, numberOfOutputChannels?: number): ScriptProcessorNode;\n createStereoPanner(): StereoPannerNode;\n createWaveShaper(): WaveShaperNode;\n decodeAudioData(audioData: ArrayBuffer, successCallback?: DecodeSuccessCallback, errorCallback?: DecodeErrorCallback): Promise;\n resume(): Promise;\n addEventListener(type: K, listener: (this: AudioContext, ev: AudioContextEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface AudioContext extends AudioContextBase {\n suspend(): Promise;\n}\n\ndeclare var AudioContext: {\n prototype: AudioContext;\n new(): AudioContext;\n}\n\ninterface AudioDestinationNode extends AudioNode {\n readonly maxChannelCount: number;\n}\n\ndeclare var AudioDestinationNode: {\n prototype: AudioDestinationNode;\n new(): AudioDestinationNode;\n}\n\ninterface AudioListener {\n dopplerFactor: number;\n speedOfSound: number;\n setOrientation(x: number, y: number, z: number, xUp: number, yUp: number, zUp: number): void;\n setPosition(x: number, y: number, z: number): void;\n setVelocity(x: number, y: number, z: number): void;\n}\n\ndeclare var AudioListener: {\n prototype: AudioListener;\n new(): AudioListener;\n}\n\ninterface AudioNode extends EventTarget {\n channelCount: number;\n channelCountMode: ChannelCountMode;\n channelInterpretation: ChannelInterpretation;\n readonly context: AudioContext;\n readonly numberOfInputs: number;\n readonly numberOfOutputs: number;\n connect(destination: AudioNode, output?: number, input?: number): AudioNode;\n connect(destination: AudioParam, output?: number): void;\n disconnect(output?: number): void;\n disconnect(destination: AudioNode, output?: number, input?: number): void;\n disconnect(destination: AudioParam, output?: number): void;\n}\n\ndeclare var AudioNode: {\n prototype: AudioNode;\n new(): AudioNode;\n}\n\ninterface AudioParam {\n readonly defaultValue: number;\n value: number;\n cancelScheduledValues(startTime: number): AudioParam;\n exponentialRampToValueAtTime(value: number, endTime: number): AudioParam;\n linearRampToValueAtTime(value: number, endTime: number): AudioParam;\n setTargetAtTime(target: number, startTime: number, timeConstant: number): AudioParam;\n setValueAtTime(value: number, startTime: number): AudioParam;\n setValueCurveAtTime(values: Float32Array, startTime: number, duration: number): AudioParam;\n}\n\ndeclare var AudioParam: {\n prototype: AudioParam;\n new(): AudioParam;\n}\n\ninterface AudioProcessingEvent extends Event {\n readonly inputBuffer: AudioBuffer;\n readonly outputBuffer: AudioBuffer;\n readonly playbackTime: number;\n}\n\ndeclare var AudioProcessingEvent: {\n prototype: AudioProcessingEvent;\n new(): AudioProcessingEvent;\n}\n\ninterface AudioTrack {\n enabled: boolean;\n readonly id: string;\n kind: string;\n readonly label: string;\n language: string;\n readonly sourceBuffer: SourceBuffer;\n}\n\ndeclare var AudioTrack: {\n prototype: AudioTrack;\n new(): AudioTrack;\n}\n\ninterface AudioTrackListEventMap {\n \"addtrack\": TrackEvent;\n \"change\": Event;\n \"removetrack\": TrackEvent;\n}\n\ninterface AudioTrackList extends EventTarget {\n readonly length: number;\n onaddtrack: (this: AudioTrackList, ev: TrackEvent) => any;\n onchange: (this: AudioTrackList, ev: Event) => any;\n onremovetrack: (this: AudioTrackList, ev: TrackEvent) => any;\n getTrackById(id: string): AudioTrack | null;\n item(index: number): AudioTrack;\n addEventListener(type: K, listener: (this: AudioTrackList, ev: AudioTrackListEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [index: number]: AudioTrack;\n}\n\ndeclare var AudioTrackList: {\n prototype: AudioTrackList;\n new(): AudioTrackList;\n}\n\ninterface BarProp {\n readonly visible: boolean;\n}\n\ndeclare var BarProp: {\n prototype: BarProp;\n new(): BarProp;\n}\n\ninterface BeforeUnloadEvent extends Event {\n returnValue: any;\n}\n\ndeclare var BeforeUnloadEvent: {\n prototype: BeforeUnloadEvent;\n new(): BeforeUnloadEvent;\n}\n\ninterface BiquadFilterNode extends AudioNode {\n readonly Q: AudioParam;\n readonly detune: AudioParam;\n readonly frequency: AudioParam;\n readonly gain: AudioParam;\n type: BiquadFilterType;\n getFrequencyResponse(frequencyHz: Float32Array, magResponse: Float32Array, phaseResponse: Float32Array): void;\n}\n\ndeclare var BiquadFilterNode: {\n prototype: BiquadFilterNode;\n new(): BiquadFilterNode;\n}\n\ninterface Blob {\n readonly size: number;\n readonly type: string;\n msClose(): void;\n msDetachStream(): any;\n slice(start?: number, end?: number, contentType?: string): Blob;\n}\n\ndeclare var Blob: {\n prototype: Blob;\n new (blobParts?: any[], options?: BlobPropertyBag): Blob;\n}\n\ninterface CDATASection extends Text {\n}\n\ndeclare var CDATASection: {\n prototype: CDATASection;\n new(): CDATASection;\n}\n\ninterface CSS {\n supports(property: string, value?: string): boolean;\n}\ndeclare var CSS: CSS;\n\ninterface CSSConditionRule extends CSSGroupingRule {\n conditionText: string;\n}\n\ndeclare var CSSConditionRule: {\n prototype: CSSConditionRule;\n new(): CSSConditionRule;\n}\n\ninterface CSSFontFaceRule extends CSSRule {\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSFontFaceRule: {\n prototype: CSSFontFaceRule;\n new(): CSSFontFaceRule;\n}\n\ninterface CSSGroupingRule extends CSSRule {\n readonly cssRules: CSSRuleList;\n deleteRule(index: number): void;\n insertRule(rule: string, index: number): number;\n}\n\ndeclare var CSSGroupingRule: {\n prototype: CSSGroupingRule;\n new(): CSSGroupingRule;\n}\n\ninterface CSSImportRule extends CSSRule {\n readonly href: string;\n readonly media: MediaList;\n readonly styleSheet: CSSStyleSheet;\n}\n\ndeclare var CSSImportRule: {\n prototype: CSSImportRule;\n new(): CSSImportRule;\n}\n\ninterface CSSKeyframeRule extends CSSRule {\n keyText: string;\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSKeyframeRule: {\n prototype: CSSKeyframeRule;\n new(): CSSKeyframeRule;\n}\n\ninterface CSSKeyframesRule extends CSSRule {\n readonly cssRules: CSSRuleList;\n name: string;\n appendRule(rule: string): void;\n deleteRule(rule: string): void;\n findRule(rule: string): CSSKeyframeRule;\n}\n\ndeclare var CSSKeyframesRule: {\n prototype: CSSKeyframesRule;\n new(): CSSKeyframesRule;\n}\n\ninterface CSSMediaRule extends CSSConditionRule {\n readonly media: MediaList;\n}\n\ndeclare var CSSMediaRule: {\n prototype: CSSMediaRule;\n new(): CSSMediaRule;\n}\n\ninterface CSSNamespaceRule extends CSSRule {\n readonly namespaceURI: string;\n readonly prefix: string;\n}\n\ndeclare var CSSNamespaceRule: {\n prototype: CSSNamespaceRule;\n new(): CSSNamespaceRule;\n}\n\ninterface CSSPageRule extends CSSRule {\n readonly pseudoClass: string;\n readonly selector: string;\n selectorText: string;\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSPageRule: {\n prototype: CSSPageRule;\n new(): CSSPageRule;\n}\n\ninterface CSSRule {\n cssText: string;\n readonly parentRule: CSSRule;\n readonly parentStyleSheet: CSSStyleSheet;\n readonly type: number;\n readonly CHARSET_RULE: number;\n readonly FONT_FACE_RULE: number;\n readonly IMPORT_RULE: number;\n readonly KEYFRAMES_RULE: number;\n readonly KEYFRAME_RULE: number;\n readonly MEDIA_RULE: number;\n readonly NAMESPACE_RULE: number;\n readonly PAGE_RULE: number;\n readonly STYLE_RULE: number;\n readonly SUPPORTS_RULE: number;\n readonly UNKNOWN_RULE: number;\n readonly VIEWPORT_RULE: number;\n}\n\ndeclare var CSSRule: {\n prototype: CSSRule;\n new(): CSSRule;\n readonly CHARSET_RULE: number;\n readonly FONT_FACE_RULE: number;\n readonly IMPORT_RULE: number;\n readonly KEYFRAMES_RULE: number;\n readonly KEYFRAME_RULE: number;\n readonly MEDIA_RULE: number;\n readonly NAMESPACE_RULE: number;\n readonly PAGE_RULE: number;\n readonly STYLE_RULE: number;\n readonly SUPPORTS_RULE: number;\n readonly UNKNOWN_RULE: number;\n readonly VIEWPORT_RULE: number;\n}\n\ninterface CSSRuleList {\n readonly length: number;\n item(index: number): CSSRule;\n [index: number]: CSSRule;\n}\n\ndeclare var CSSRuleList: {\n prototype: CSSRuleList;\n new(): CSSRuleList;\n}\n\ninterface CSSStyleDeclaration {\n alignContent: string | null;\n alignItems: string | null;\n alignSelf: string | null;\n alignmentBaseline: string | null;\n animation: string | null;\n animationDelay: string | null;\n animationDirection: string | null;\n animationDuration: string | null;\n animationFillMode: string | null;\n animationIterationCount: string | null;\n animationName: string | null;\n animationPlayState: string | null;\n animationTimingFunction: string | null;\n backfaceVisibility: string | null;\n background: string | null;\n backgroundAttachment: string | null;\n backgroundClip: string | null;\n backgroundColor: string | null;\n backgroundImage: string | null;\n backgroundOrigin: string | null;\n backgroundPosition: string | null;\n backgroundPositionX: string | null;\n backgroundPositionY: string | null;\n backgroundRepeat: string | null;\n backgroundSize: string | null;\n baselineShift: string | null;\n border: string | null;\n borderBottom: string | null;\n borderBottomColor: string | null;\n borderBottomLeftRadius: string | null;\n borderBottomRightRadius: string | null;\n borderBottomStyle: string | null;\n borderBottomWidth: string | null;\n borderCollapse: string | null;\n borderColor: string | null;\n borderImage: string | null;\n borderImageOutset: string | null;\n borderImageRepeat: string | null;\n borderImageSlice: string | null;\n borderImageSource: string | null;\n borderImageWidth: string | null;\n borderLeft: string | null;\n borderLeftColor: string | null;\n borderLeftStyle: string | null;\n borderLeftWidth: string | null;\n borderRadius: string | null;\n borderRight: string | null;\n borderRightColor: string | null;\n borderRightStyle: string | null;\n borderRightWidth: string | null;\n borderSpacing: string | null;\n borderStyle: string | null;\n borderTop: string | null;\n borderTopColor: string | null;\n borderTopLeftRadius: string | null;\n borderTopRightRadius: string | null;\n borderTopStyle: string | null;\n borderTopWidth: string | null;\n borderWidth: string | null;\n bottom: string | null;\n boxShadow: string | null;\n boxSizing: string | null;\n breakAfter: string | null;\n breakBefore: string | null;\n breakInside: string | null;\n captionSide: string | null;\n clear: string | null;\n clip: string | null;\n clipPath: string | null;\n clipRule: string | null;\n color: string | null;\n colorInterpolationFilters: string | null;\n columnCount: any;\n columnFill: string | null;\n columnGap: any;\n columnRule: string | null;\n columnRuleColor: any;\n columnRuleStyle: string | null;\n columnRuleWidth: any;\n columnSpan: string | null;\n columnWidth: any;\n columns: string | null;\n content: string | null;\n counterIncrement: string | null;\n counterReset: string | null;\n cssFloat: string | null;\n cssText: string;\n cursor: string | null;\n direction: string | null;\n display: string | null;\n dominantBaseline: string | null;\n emptyCells: string | null;\n enableBackground: string | null;\n fill: string | null;\n fillOpacity: string | null;\n fillRule: string | null;\n filter: string | null;\n flex: string | null;\n flexBasis: string | null;\n flexDirection: string | null;\n flexFlow: string | null;\n flexGrow: string | null;\n flexShrink: string | null;\n flexWrap: string | null;\n floodColor: string | null;\n floodOpacity: string | null;\n font: string | null;\n fontFamily: string | null;\n fontFeatureSettings: string | null;\n fontSize: string | null;\n fontSizeAdjust: string | null;\n fontStretch: string | null;\n fontStyle: string | null;\n fontVariant: string | null;\n fontWeight: string | null;\n glyphOrientationHorizontal: string | null;\n glyphOrientationVertical: string | null;\n height: string | null;\n imeMode: string | null;\n justifyContent: string | null;\n kerning: string | null;\n layoutGrid: string | null;\n layoutGridChar: string | null;\n layoutGridLine: string | null;\n layoutGridMode: string | null;\n layoutGridType: string | null;\n left: string | null;\n readonly length: number;\n letterSpacing: string | null;\n lightingColor: string | null;\n lineBreak: string | null;\n lineHeight: string | null;\n listStyle: string | null;\n listStyleImage: string | null;\n listStylePosition: string | null;\n listStyleType: string | null;\n margin: string | null;\n marginBottom: string | null;\n marginLeft: string | null;\n marginRight: string | null;\n marginTop: string | null;\n marker: string | null;\n markerEnd: string | null;\n markerMid: string | null;\n markerStart: string | null;\n mask: string | null;\n maxHeight: string | null;\n maxWidth: string | null;\n minHeight: string | null;\n minWidth: string | null;\n msContentZoomChaining: string | null;\n msContentZoomLimit: string | null;\n msContentZoomLimitMax: any;\n msContentZoomLimitMin: any;\n msContentZoomSnap: string | null;\n msContentZoomSnapPoints: string | null;\n msContentZoomSnapType: string | null;\n msContentZooming: string | null;\n msFlowFrom: string | null;\n msFlowInto: string | null;\n msFontFeatureSettings: string | null;\n msGridColumn: any;\n msGridColumnAlign: string | null;\n msGridColumnSpan: any;\n msGridColumns: string | null;\n msGridRow: any;\n msGridRowAlign: string | null;\n msGridRowSpan: any;\n msGridRows: string | null;\n msHighContrastAdjust: string | null;\n msHyphenateLimitChars: string | null;\n msHyphenateLimitLines: any;\n msHyphenateLimitZone: any;\n msHyphens: string | null;\n msImeAlign: string | null;\n msOverflowStyle: string | null;\n msScrollChaining: string | null;\n msScrollLimit: string | null;\n msScrollLimitXMax: any;\n msScrollLimitXMin: any;\n msScrollLimitYMax: any;\n msScrollLimitYMin: any;\n msScrollRails: string | null;\n msScrollSnapPointsX: string | null;\n msScrollSnapPointsY: string | null;\n msScrollSnapType: string | null;\n msScrollSnapX: string | null;\n msScrollSnapY: string | null;\n msScrollTranslation: string | null;\n msTextCombineHorizontal: string | null;\n msTextSizeAdjust: any;\n msTouchAction: string | null;\n msTouchSelect: string | null;\n msUserSelect: string | null;\n msWrapFlow: string;\n msWrapMargin: any;\n msWrapThrough: string;\n opacity: string | null;\n order: string | null;\n orphans: string | null;\n outline: string | null;\n outlineColor: string | null;\n outlineOffset: string | null;\n outlineStyle: string | null;\n outlineWidth: string | null;\n overflow: string | null;\n overflowX: string | null;\n overflowY: string | null;\n padding: string | null;\n paddingBottom: string | null;\n paddingLeft: string | null;\n paddingRight: string | null;\n paddingTop: string | null;\n pageBreakAfter: string | null;\n pageBreakBefore: string | null;\n pageBreakInside: string | null;\n readonly parentRule: CSSRule;\n perspective: string | null;\n perspectiveOrigin: string | null;\n pointerEvents: string | null;\n position: string | null;\n quotes: string | null;\n right: string | null;\n rotate: string | null;\n rubyAlign: string | null;\n rubyOverhang: string | null;\n rubyPosition: string | null;\n scale: string | null;\n stopColor: string | null;\n stopOpacity: string | null;\n stroke: string | null;\n strokeDasharray: string | null;\n strokeDashoffset: string | null;\n strokeLinecap: string | null;\n strokeLinejoin: string | null;\n strokeMiterlimit: string | null;\n strokeOpacity: string | null;\n strokeWidth: string | null;\n tableLayout: string | null;\n textAlign: string | null;\n textAlignLast: string | null;\n textAnchor: string | null;\n textDecoration: string | null;\n textIndent: string | null;\n textJustify: string | null;\n textKashida: string | null;\n textKashidaSpace: string | null;\n textOverflow: string | null;\n textShadow: string | null;\n textTransform: string | null;\n textUnderlinePosition: string | null;\n top: string | null;\n touchAction: string | null;\n transform: string | null;\n transformOrigin: string | null;\n transformStyle: string | null;\n transition: string | null;\n transitionDelay: string | null;\n transitionDuration: string | null;\n transitionProperty: string | null;\n transitionTimingFunction: string | null;\n translate: string | null;\n unicodeBidi: string | null;\n verticalAlign: string | null;\n visibility: string | null;\n webkitAlignContent: string | null;\n webkitAlignItems: string | null;\n webkitAlignSelf: string | null;\n webkitAnimation: string | null;\n webkitAnimationDelay: string | null;\n webkitAnimationDirection: string | null;\n webkitAnimationDuration: string | null;\n webkitAnimationFillMode: string | null;\n webkitAnimationIterationCount: string | null;\n webkitAnimationName: string | null;\n webkitAnimationPlayState: string | null;\n webkitAnimationTimingFunction: string | null;\n webkitAppearance: string | null;\n webkitBackfaceVisibility: string | null;\n webkitBackgroundClip: string | null;\n webkitBackgroundOrigin: string | null;\n webkitBackgroundSize: string | null;\n webkitBorderBottomLeftRadius: string | null;\n webkitBorderBottomRightRadius: string | null;\n webkitBorderImage: string | null;\n webkitBorderRadius: string | null;\n webkitBorderTopLeftRadius: string | null;\n webkitBorderTopRightRadius: string | null;\n webkitBoxAlign: string | null;\n webkitBoxDirection: string | null;\n webkitBoxFlex: string | null;\n webkitBoxOrdinalGroup: string | null;\n webkitBoxOrient: string | null;\n webkitBoxPack: string | null;\n webkitBoxSizing: string | null;\n webkitColumnBreakAfter: string | null;\n webkitColumnBreakBefore: string | null;\n webkitColumnBreakInside: string | null;\n webkitColumnCount: any;\n webkitColumnGap: any;\n webkitColumnRule: string | null;\n webkitColumnRuleColor: any;\n webkitColumnRuleStyle: string | null;\n webkitColumnRuleWidth: any;\n webkitColumnSpan: string | null;\n webkitColumnWidth: any;\n webkitColumns: string | null;\n webkitFilter: string | null;\n webkitFlex: string | null;\n webkitFlexBasis: string | null;\n webkitFlexDirection: string | null;\n webkitFlexFlow: string | null;\n webkitFlexGrow: string | null;\n webkitFlexShrink: string | null;\n webkitFlexWrap: string | null;\n webkitJustifyContent: string | null;\n webkitOrder: string | null;\n webkitPerspective: string | null;\n webkitPerspectiveOrigin: string | null;\n webkitTapHighlightColor: string | null;\n webkitTextFillColor: string | null;\n webkitTextSizeAdjust: any;\n webkitTextStroke: string | null;\n webkitTextStrokeColor: string | null;\n webkitTextStrokeWidth: string | null;\n webkitTransform: string | null;\n webkitTransformOrigin: string | null;\n webkitTransformStyle: string | null;\n webkitTransition: string | null;\n webkitTransitionDelay: string | null;\n webkitTransitionDuration: string | null;\n webkitTransitionProperty: string | null;\n webkitTransitionTimingFunction: string | null;\n webkitUserModify: string | null;\n webkitUserSelect: string | null;\n webkitWritingMode: string | null;\n whiteSpace: string | null;\n widows: string | null;\n width: string | null;\n wordBreak: string | null;\n wordSpacing: string | null;\n wordWrap: string | null;\n writingMode: string | null;\n zIndex: string | null;\n zoom: string | null;\n resize: string | null;\n userSelect: string | null;\n getPropertyPriority(propertyName: string): string;\n getPropertyValue(propertyName: string): string;\n item(index: number): string;\n removeProperty(propertyName: string): string;\n setProperty(propertyName: string, value: string | null, priority?: string): void;\n [index: number]: string;\n}\n\ndeclare var CSSStyleDeclaration: {\n prototype: CSSStyleDeclaration;\n new(): CSSStyleDeclaration;\n}\n\ninterface CSSStyleRule extends CSSRule {\n readonly readOnly: boolean;\n selectorText: string;\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSStyleRule: {\n prototype: CSSStyleRule;\n new(): CSSStyleRule;\n}\n\ninterface CSSStyleSheet extends StyleSheet {\n readonly cssRules: CSSRuleList;\n cssText: string;\n readonly id: string;\n readonly imports: StyleSheetList;\n readonly isAlternate: boolean;\n readonly isPrefAlternate: boolean;\n readonly ownerRule: CSSRule;\n readonly owningElement: Element;\n readonly pages: StyleSheetPageList;\n readonly readOnly: boolean;\n readonly rules: CSSRuleList;\n addImport(bstrURL: string, lIndex?: number): number;\n addPageRule(bstrSelector: string, bstrStyle: string, lIndex?: number): number;\n addRule(bstrSelector: string, bstrStyle?: string, lIndex?: number): number;\n deleteRule(index?: number): void;\n insertRule(rule: string, index?: number): number;\n removeImport(lIndex: number): void;\n removeRule(lIndex: number): void;\n}\n\ndeclare var CSSStyleSheet: {\n prototype: CSSStyleSheet;\n new(): CSSStyleSheet;\n}\n\ninterface CSSSupportsRule extends CSSConditionRule {\n}\n\ndeclare var CSSSupportsRule: {\n prototype: CSSSupportsRule;\n new(): CSSSupportsRule;\n}\n\ninterface Cache {\n add(request: RequestInfo): Promise;\n addAll(requests: RequestInfo[]): Promise;\n delete(request: RequestInfo, options?: CacheQueryOptions): Promise;\n keys(request?: RequestInfo, options?: CacheQueryOptions): any;\n match(request: RequestInfo, options?: CacheQueryOptions): Promise;\n matchAll(request?: RequestInfo, options?: CacheQueryOptions): any;\n put(request: RequestInfo, response: Response): Promise;\n}\n\ndeclare var Cache: {\n prototype: Cache;\n new(): Cache;\n}\n\ninterface CacheStorage {\n delete(cacheName: string): Promise;\n has(cacheName: string): Promise;\n keys(): any;\n match(request: RequestInfo, options?: CacheQueryOptions): Promise;\n open(cacheName: string): Promise;\n}\n\ndeclare var CacheStorage: {\n prototype: CacheStorage;\n new(): CacheStorage;\n}\n\ninterface CanvasGradient {\n addColorStop(offset: number, color: string): void;\n}\n\ndeclare var CanvasGradient: {\n prototype: CanvasGradient;\n new(): CanvasGradient;\n}\n\ninterface CanvasPattern {\n setTransform(matrix: SVGMatrix): void;\n}\n\ndeclare var CanvasPattern: {\n prototype: CanvasPattern;\n new(): CanvasPattern;\n}\n\ninterface CanvasRenderingContext2D extends Object, CanvasPathMethods {\n readonly canvas: HTMLCanvasElement;\n fillStyle: string | CanvasGradient | CanvasPattern;\n font: string;\n globalAlpha: number;\n globalCompositeOperation: string;\n imageSmoothingEnabled: boolean;\n lineCap: string;\n lineDashOffset: number;\n lineJoin: string;\n lineWidth: number;\n miterLimit: number;\n msFillRule: CanvasFillRule;\n shadowBlur: number;\n shadowColor: string;\n shadowOffsetX: number;\n shadowOffsetY: number;\n strokeStyle: string | CanvasGradient | CanvasPattern;\n textAlign: string;\n textBaseline: string;\n mozImageSmoothingEnabled: boolean;\n webkitImageSmoothingEnabled: boolean;\n oImageSmoothingEnabled: boolean;\n beginPath(): void;\n clearRect(x: number, y: number, w: number, h: number): void;\n clip(fillRule?: CanvasFillRule): void;\n createImageData(imageDataOrSw: number | ImageData, sh?: number): ImageData;\n createLinearGradient(x0: number, y0: number, x1: number, y1: number): CanvasGradient;\n createPattern(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement, repetition: string): CanvasPattern;\n createRadialGradient(x0: number, y0: number, r0: number, x1: number, y1: number, r1: number): CanvasGradient;\n drawFocusIfNeeded(element: Element): void;\n drawImage(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, dstX: number, dstY: number): void;\n drawImage(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, dstX: number, dstY: number, dstW: number, dstH: number): void;\n drawImage(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, srcX: number, srcY: number, srcW: number, srcH: number, dstX: number, dstY: number, dstW: number, dstH: number): void;\n fill(fillRule?: CanvasFillRule): void;\n fillRect(x: number, y: number, w: number, h: number): void;\n fillText(text: string, x: number, y: number, maxWidth?: number): void;\n getImageData(sx: number, sy: number, sw: number, sh: number): ImageData;\n getLineDash(): number[];\n isPointInPath(x: number, y: number, fillRule?: CanvasFillRule): boolean;\n measureText(text: string): TextMetrics;\n putImageData(imagedata: ImageData, dx: number, dy: number, dirtyX?: number, dirtyY?: number, dirtyWidth?: number, dirtyHeight?: number): void;\n restore(): void;\n rotate(angle: number): void;\n save(): void;\n scale(x: number, y: number): void;\n setLineDash(segments: number[]): void;\n setTransform(m11: number, m12: number, m21: number, m22: number, dx: number, dy: number): void;\n stroke(path?: Path2D): void;\n strokeRect(x: number, y: number, w: number, h: number): void;\n strokeText(text: string, x: number, y: number, maxWidth?: number): void;\n transform(m11: number, m12: number, m21: number, m22: number, dx: number, dy: number): void;\n translate(x: number, y: number): void;\n}\n\ndeclare var CanvasRenderingContext2D: {\n prototype: CanvasRenderingContext2D;\n new(): CanvasRenderingContext2D;\n}\n\ninterface ChannelMergerNode extends AudioNode {\n}\n\ndeclare var ChannelMergerNode: {\n prototype: ChannelMergerNode;\n new(): ChannelMergerNode;\n}\n\ninterface ChannelSplitterNode extends AudioNode {\n}\n\ndeclare var ChannelSplitterNode: {\n prototype: ChannelSplitterNode;\n new(): ChannelSplitterNode;\n}\n\ninterface CharacterData extends Node, ChildNode {\n data: string;\n readonly length: number;\n appendData(arg: string): void;\n deleteData(offset: number, count: number): void;\n insertData(offset: number, arg: string): void;\n replaceData(offset: number, count: number, arg: string): void;\n substringData(offset: number, count: number): string;\n}\n\ndeclare var CharacterData: {\n prototype: CharacterData;\n new(): CharacterData;\n}\n\ninterface ClientRect {\n bottom: number;\n readonly height: number;\n left: number;\n right: number;\n top: number;\n readonly width: number;\n}\n\ndeclare var ClientRect: {\n prototype: ClientRect;\n new(): ClientRect;\n}\n\ninterface ClientRectList {\n readonly length: number;\n item(index: number): ClientRect;\n [index: number]: ClientRect;\n}\n\ndeclare var ClientRectList: {\n prototype: ClientRectList;\n new(): ClientRectList;\n}\n\ninterface ClipboardEvent extends Event {\n readonly clipboardData: DataTransfer;\n}\n\ndeclare var ClipboardEvent: {\n prototype: ClipboardEvent;\n new(type: string, eventInitDict?: ClipboardEventInit): ClipboardEvent;\n}\n\ninterface CloseEvent extends Event {\n readonly code: number;\n readonly reason: string;\n readonly wasClean: boolean;\n initCloseEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, wasCleanArg: boolean, codeArg: number, reasonArg: string): void;\n}\n\ndeclare var CloseEvent: {\n prototype: CloseEvent;\n new(typeArg: string, eventInitDict?: CloseEventInit): CloseEvent;\n}\n\ninterface Comment extends CharacterData {\n text: string;\n}\n\ndeclare var Comment: {\n prototype: Comment;\n new(): Comment;\n}\n\ninterface CompositionEvent extends UIEvent {\n readonly data: string;\n readonly locale: string;\n initCompositionEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, dataArg: string, locale: string): void;\n}\n\ndeclare var CompositionEvent: {\n prototype: CompositionEvent;\n new(typeArg: string, eventInitDict?: CompositionEventInit): CompositionEvent;\n}\n\ninterface Console {\n assert(test?: boolean, message?: string, ...optionalParams: any[]): void;\n clear(): void;\n count(countTitle?: string): void;\n debug(message?: any, ...optionalParams: any[]): void;\n dir(value?: any, ...optionalParams: any[]): void;\n dirxml(value: any): void;\n error(message?: any, ...optionalParams: any[]): void;\n exception(message?: string, ...optionalParams: any[]): void;\n group(groupTitle?: string): void;\n groupCollapsed(groupTitle?: string): void;\n groupEnd(): void;\n info(message?: any, ...optionalParams: any[]): void;\n log(message?: any, ...optionalParams: any[]): void;\n msIsIndependentlyComposed(element: Element): boolean;\n profile(reportName?: string): void;\n profileEnd(): void;\n select(element: Element): void;\n table(...data: any[]): void;\n time(timerName?: string): void;\n timeEnd(timerName?: string): void;\n trace(message?: any, ...optionalParams: any[]): void;\n warn(message?: any, ...optionalParams: any[]): void;\n}\n\ndeclare var Console: {\n prototype: Console;\n new(): Console;\n}\n\ninterface ConvolverNode extends AudioNode {\n buffer: AudioBuffer | null;\n normalize: boolean;\n}\n\ndeclare var ConvolverNode: {\n prototype: ConvolverNode;\n new(): ConvolverNode;\n}\n\ninterface Coordinates {\n readonly accuracy: number;\n readonly altitude: number | null;\n readonly altitudeAccuracy: number | null;\n readonly heading: number | null;\n readonly latitude: number;\n readonly longitude: number;\n readonly speed: number | null;\n}\n\ndeclare var Coordinates: {\n prototype: Coordinates;\n new(): Coordinates;\n}\n\ninterface Crypto extends Object, RandomSource {\n readonly subtle: SubtleCrypto;\n}\n\ndeclare var Crypto: {\n prototype: Crypto;\n new(): Crypto;\n}\n\ninterface CryptoKey {\n readonly algorithm: KeyAlgorithm;\n readonly extractable: boolean;\n readonly type: string;\n readonly usages: string[];\n}\n\ndeclare var CryptoKey: {\n prototype: CryptoKey;\n new(): CryptoKey;\n}\n\ninterface CryptoKeyPair {\n privateKey: CryptoKey;\n publicKey: CryptoKey;\n}\n\ndeclare var CryptoKeyPair: {\n prototype: CryptoKeyPair;\n new(): CryptoKeyPair;\n}\n\ninterface CustomEvent extends Event {\n readonly detail: any;\n initCustomEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, detailArg: any): void;\n}\n\ndeclare var CustomEvent: {\n prototype: CustomEvent;\n new(typeArg: string, eventInitDict?: CustomEventInit): CustomEvent;\n}\n\ninterface DOMError {\n readonly name: string;\n toString(): string;\n}\n\ndeclare var DOMError: {\n prototype: DOMError;\n new(): DOMError;\n}\n\ninterface DOMException {\n readonly code: number;\n readonly message: string;\n readonly name: string;\n toString(): string;\n readonly ABORT_ERR: number;\n readonly DATA_CLONE_ERR: number;\n readonly DOMSTRING_SIZE_ERR: number;\n readonly HIERARCHY_REQUEST_ERR: number;\n readonly INDEX_SIZE_ERR: number;\n readonly INUSE_ATTRIBUTE_ERR: number;\n readonly INVALID_ACCESS_ERR: number;\n readonly INVALID_CHARACTER_ERR: number;\n readonly INVALID_MODIFICATION_ERR: number;\n readonly INVALID_NODE_TYPE_ERR: number;\n readonly INVALID_STATE_ERR: number;\n readonly NAMESPACE_ERR: number;\n readonly NETWORK_ERR: number;\n readonly NOT_FOUND_ERR: number;\n readonly NOT_SUPPORTED_ERR: number;\n readonly NO_DATA_ALLOWED_ERR: number;\n readonly NO_MODIFICATION_ALLOWED_ERR: number;\n readonly PARSE_ERR: number;\n readonly QUOTA_EXCEEDED_ERR: number;\n readonly SECURITY_ERR: number;\n readonly SERIALIZE_ERR: number;\n readonly SYNTAX_ERR: number;\n readonly TIMEOUT_ERR: number;\n readonly TYPE_MISMATCH_ERR: number;\n readonly URL_MISMATCH_ERR: number;\n readonly VALIDATION_ERR: number;\n readonly WRONG_DOCUMENT_ERR: number;\n}\n\ndeclare var DOMException: {\n prototype: DOMException;\n new(): DOMException;\n readonly ABORT_ERR: number;\n readonly DATA_CLONE_ERR: number;\n readonly DOMSTRING_SIZE_ERR: number;\n readonly HIERARCHY_REQUEST_ERR: number;\n readonly INDEX_SIZE_ERR: number;\n readonly INUSE_ATTRIBUTE_ERR: number;\n readonly INVALID_ACCESS_ERR: number;\n readonly INVALID_CHARACTER_ERR: number;\n readonly INVALID_MODIFICATION_ERR: number;\n readonly INVALID_NODE_TYPE_ERR: number;\n readonly INVALID_STATE_ERR: number;\n readonly NAMESPACE_ERR: number;\n readonly NETWORK_ERR: number;\n readonly NOT_FOUND_ERR: number;\n readonly NOT_SUPPORTED_ERR: number;\n readonly NO_DATA_ALLOWED_ERR: number;\n readonly NO_MODIFICATION_ALLOWED_ERR: number;\n readonly PARSE_ERR: number;\n readonly QUOTA_EXCEEDED_ERR: number;\n readonly SECURITY_ERR: number;\n readonly SERIALIZE_ERR: number;\n readonly SYNTAX_ERR: number;\n readonly TIMEOUT_ERR: number;\n readonly TYPE_MISMATCH_ERR: number;\n readonly URL_MISMATCH_ERR: number;\n readonly VALIDATION_ERR: number;\n readonly WRONG_DOCUMENT_ERR: number;\n}\n\ninterface DOMImplementation {\n createDocument(namespaceURI: string | null, qualifiedName: string | null, doctype: DocumentType | null): Document;\n createDocumentType(qualifiedName: string, publicId: string, systemId: string): DocumentType;\n createHTMLDocument(title: string): Document;\n hasFeature(feature: string | null, version: string | null): boolean;\n}\n\ndeclare var DOMImplementation: {\n prototype: DOMImplementation;\n new(): DOMImplementation;\n}\n\ninterface DOMParser {\n parseFromString(source: string, mimeType: string): Document;\n}\n\ndeclare var DOMParser: {\n prototype: DOMParser;\n new(): DOMParser;\n}\n\ninterface DOMSettableTokenList extends DOMTokenList {\n value: string;\n}\n\ndeclare var DOMSettableTokenList: {\n prototype: DOMSettableTokenList;\n new(): DOMSettableTokenList;\n}\n\ninterface DOMStringList {\n readonly length: number;\n contains(str: string): boolean;\n item(index: number): string | null;\n [index: number]: string;\n}\n\ndeclare var DOMStringList: {\n prototype: DOMStringList;\n new(): DOMStringList;\n}\n\ninterface DOMStringMap {\n [name: string]: string | undefined;\n}\n\ndeclare var DOMStringMap: {\n prototype: DOMStringMap;\n new(): DOMStringMap;\n}\n\ninterface DOMTokenList {\n readonly length: number;\n add(...token: string[]): void;\n contains(token: string): boolean;\n item(index: number): string;\n remove(...token: string[]): void;\n toString(): string;\n toggle(token: string, force?: boolean): boolean;\n [index: number]: string;\n}\n\ndeclare var DOMTokenList: {\n prototype: DOMTokenList;\n new(): DOMTokenList;\n}\n\ninterface DataCue extends TextTrackCue {\n data: ArrayBuffer;\n addEventListener(type: K, listener: (this: DataCue, ev: TextTrackCueEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var DataCue: {\n prototype: DataCue;\n new(): DataCue;\n}\n\ninterface DataTransfer {\n dropEffect: string;\n effectAllowed: string;\n readonly files: FileList;\n readonly items: DataTransferItemList;\n readonly types: string[];\n clearData(format?: string): boolean;\n getData(format: string): string;\n setData(format: string, data: string): boolean;\n setDragImage(image: Element, x: number, y: number): void;\n}\n\ndeclare var DataTransfer: {\n prototype: DataTransfer;\n new(): DataTransfer;\n}\n\ninterface DataTransferItem {\n readonly kind: string;\n readonly type: string;\n getAsFile(): File | null;\n getAsString(_callback: FunctionStringCallback | null): void;\n webkitGetAsEntry(): any;\n}\n\ndeclare var DataTransferItem: {\n prototype: DataTransferItem;\n new(): DataTransferItem;\n}\n\ninterface DataTransferItemList {\n readonly length: number;\n add(data: File): DataTransferItem | null;\n clear(): void;\n item(index: number): DataTransferItem;\n remove(index: number): void;\n [index: number]: DataTransferItem;\n}\n\ndeclare var DataTransferItemList: {\n prototype: DataTransferItemList;\n new(): DataTransferItemList;\n}\n\ninterface DeferredPermissionRequest {\n readonly id: number;\n readonly type: MSWebViewPermissionType;\n readonly uri: string;\n allow(): void;\n deny(): void;\n}\n\ndeclare var DeferredPermissionRequest: {\n prototype: DeferredPermissionRequest;\n new(): DeferredPermissionRequest;\n}\n\ninterface DelayNode extends AudioNode {\n readonly delayTime: AudioParam;\n}\n\ndeclare var DelayNode: {\n prototype: DelayNode;\n new(): DelayNode;\n}\n\ninterface DeviceAcceleration {\n readonly x: number | null;\n readonly y: number | null;\n readonly z: number | null;\n}\n\ndeclare var DeviceAcceleration: {\n prototype: DeviceAcceleration;\n new(): DeviceAcceleration;\n}\n\ninterface DeviceLightEvent extends Event {\n readonly value: number;\n}\n\ndeclare var DeviceLightEvent: {\n prototype: DeviceLightEvent;\n new(typeArg: string, eventInitDict?: DeviceLightEventInit): DeviceLightEvent;\n}\n\ninterface DeviceMotionEvent extends Event {\n readonly acceleration: DeviceAcceleration | null;\n readonly accelerationIncludingGravity: DeviceAcceleration | null;\n readonly interval: number | null;\n readonly rotationRate: DeviceRotationRate | null;\n initDeviceMotionEvent(type: string, bubbles: boolean, cancelable: boolean, acceleration: DeviceAccelerationDict | null, accelerationIncludingGravity: DeviceAccelerationDict | null, rotationRate: DeviceRotationRateDict | null, interval: number | null): void;\n}\n\ndeclare var DeviceMotionEvent: {\n prototype: DeviceMotionEvent;\n new(typeArg: string, eventInitDict?: DeviceMotionEventInit): DeviceMotionEvent;\n}\n\ninterface DeviceOrientationEvent extends Event {\n readonly absolute: boolean;\n readonly alpha: number | null;\n readonly beta: number | null;\n readonly gamma: number | null;\n initDeviceOrientationEvent(type: string, bubbles: boolean, cancelable: boolean, alpha: number | null, beta: number | null, gamma: number | null, absolute: boolean): void;\n}\n\ndeclare var DeviceOrientationEvent: {\n prototype: DeviceOrientationEvent;\n new(typeArg: string, eventInitDict?: DeviceOrientationEventInit): DeviceOrientationEvent;\n}\n\ninterface DeviceRotationRate {\n readonly alpha: number | null;\n readonly beta: number | null;\n readonly gamma: number | null;\n}\n\ndeclare var DeviceRotationRate: {\n prototype: DeviceRotationRate;\n new(): DeviceRotationRate;\n}\n\ninterface DocumentEventMap extends GlobalEventHandlersEventMap {\n \"abort\": UIEvent;\n \"activate\": UIEvent;\n \"beforeactivate\": UIEvent;\n \"beforedeactivate\": UIEvent;\n \"blur\": FocusEvent;\n \"canplay\": Event;\n \"canplaythrough\": Event;\n \"change\": Event;\n \"click\": MouseEvent;\n \"contextmenu\": PointerEvent;\n \"dblclick\": MouseEvent;\n \"deactivate\": UIEvent;\n \"drag\": DragEvent;\n \"dragend\": DragEvent;\n \"dragenter\": DragEvent;\n \"dragleave\": DragEvent;\n \"dragover\": DragEvent;\n \"dragstart\": DragEvent;\n \"drop\": DragEvent;\n \"durationchange\": Event;\n \"emptied\": Event;\n \"ended\": MediaStreamErrorEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"fullscreenchange\": Event;\n \"fullscreenerror\": Event;\n \"input\": Event;\n \"invalid\": Event;\n \"keydown\": KeyboardEvent;\n \"keypress\": KeyboardEvent;\n \"keyup\": KeyboardEvent;\n \"load\": Event;\n \"loadeddata\": Event;\n \"loadedmetadata\": Event;\n \"loadstart\": Event;\n \"mousedown\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n \"mousewheel\": WheelEvent;\n \"MSContentZoom\": UIEvent;\n \"MSGestureChange\": MSGestureEvent;\n \"MSGestureDoubleTap\": MSGestureEvent;\n \"MSGestureEnd\": MSGestureEvent;\n \"MSGestureHold\": MSGestureEvent;\n \"MSGestureStart\": MSGestureEvent;\n \"MSGestureTap\": MSGestureEvent;\n \"MSInertiaStart\": MSGestureEvent;\n \"MSManipulationStateChanged\": MSManipulationEvent;\n \"MSPointerCancel\": MSPointerEvent;\n \"MSPointerDown\": MSPointerEvent;\n \"MSPointerEnter\": MSPointerEvent;\n \"MSPointerLeave\": MSPointerEvent;\n \"MSPointerMove\": MSPointerEvent;\n \"MSPointerOut\": MSPointerEvent;\n \"MSPointerOver\": MSPointerEvent;\n \"MSPointerUp\": MSPointerEvent;\n \"mssitemodejumplistitemremoved\": MSSiteModeEvent;\n \"msthumbnailclick\": MSSiteModeEvent;\n \"pause\": Event;\n \"play\": Event;\n \"playing\": Event;\n \"pointerlockchange\": Event;\n \"pointerlockerror\": Event;\n \"progress\": ProgressEvent;\n \"ratechange\": Event;\n \"readystatechange\": Event;\n \"reset\": Event;\n \"scroll\": UIEvent;\n \"seeked\": Event;\n \"seeking\": Event;\n \"select\": UIEvent;\n \"selectionchange\": Event;\n \"selectstart\": Event;\n \"stalled\": Event;\n \"stop\": Event;\n \"submit\": Event;\n \"suspend\": Event;\n \"timeupdate\": Event;\n \"touchcancel\": TouchEvent;\n \"touchend\": TouchEvent;\n \"touchmove\": TouchEvent;\n \"touchstart\": TouchEvent;\n \"volumechange\": Event;\n \"waiting\": Event;\n \"webkitfullscreenchange\": Event;\n \"webkitfullscreenerror\": Event;\n}\n\ninterface Document extends Node, GlobalEventHandlers, NodeSelector, DocumentEvent, ParentNode, DocumentOrShadowRoot {\n /**\n * Sets or gets the URL for the current document. \n */\n readonly URL: string;\n /**\n * Gets the URL for the document, stripped of any character encoding.\n */\n readonly URLUnencoded: string;\n /**\n * Gets the object that has the focus when the parent document has focus.\n */\n readonly activeElement: Element;\n /**\n * Sets or gets the color of all active links in the document.\n */\n alinkColor: string;\n /**\n * Returns a reference to the collection of elements contained by the object.\n */\n readonly all: HTMLAllCollection;\n /**\n * Retrieves a collection of all a objects that have a name and/or id property. Objects in this collection are in HTML source order.\n */\n anchors: HTMLCollectionOf;\n /**\n * Retrieves a collection of all applet objects in the document.\n */\n applets: HTMLCollectionOf;\n /**\n * Deprecated. Sets or retrieves a value that indicates the background color behind the object. \n */\n bgColor: string;\n /**\n * Specifies the beginning and end of the document body.\n */\n body: HTMLElement;\n readonly characterSet: string;\n /**\n * Gets or sets the character set used to encode the object.\n */\n charset: string;\n /**\n * Gets a value that indicates whether standards-compliant mode is switched on for the object.\n */\n readonly compatMode: string;\n cookie: string;\n readonly currentScript: HTMLScriptElement | SVGScriptElement;\n readonly defaultView: Window;\n /**\n * Sets or gets a value that indicates whether the document can be edited.\n */\n designMode: string;\n /**\n * Sets or retrieves a value that indicates the reading order of the object. \n */\n dir: string;\n /**\n * Gets an object representing the document type declaration associated with the current document. \n */\n readonly doctype: DocumentType;\n /**\n * Gets a reference to the root node of the document. \n */\n documentElement: HTMLElement;\n /**\n * Sets or gets the security domain of the document. \n */\n domain: string;\n /**\n * Retrieves a collection of all embed objects in the document.\n */\n embeds: HTMLCollectionOf;\n /**\n * Sets or gets the foreground (text) color of the document.\n */\n fgColor: string;\n /**\n * Retrieves a collection, in source order, of all form objects in the document.\n */\n forms: HTMLCollectionOf;\n readonly fullscreenElement: Element | null;\n readonly fullscreenEnabled: boolean;\n readonly head: HTMLHeadElement;\n readonly hidden: boolean;\n /**\n * Retrieves a collection, in source order, of img objects in the document.\n */\n images: HTMLCollectionOf;\n /**\n * Gets the implementation object of the current document. \n */\n readonly implementation: DOMImplementation;\n /**\n * Returns the character encoding used to create the webpage that is loaded into the document object.\n */\n readonly inputEncoding: string | null;\n /**\n * Gets the date that the page was last modified, if the page supplies one. \n */\n readonly lastModified: string;\n /**\n * Sets or gets the color of the document links. \n */\n linkColor: string;\n /**\n * Retrieves a collection of all a objects that specify the href property and all area objects in the document.\n */\n links: HTMLCollectionOf;\n /**\n * Contains information about the current URL. \n */\n readonly location: Location;\n msCSSOMElementFloatMetrics: boolean;\n msCapsLockWarningOff: boolean;\n /**\n * Fires when the user aborts the download.\n * @param ev The event.\n */\n onabort: (this: Document, ev: UIEvent) => any;\n /**\n * Fires when the object is set as the active element.\n * @param ev The event.\n */\n onactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires immediately before the object is set as the active element.\n * @param ev The event.\n */\n onbeforeactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires immediately before the activeElement is changed from the current object to another object in the parent document.\n * @param ev The event.\n */\n onbeforedeactivate: (this: Document, ev: UIEvent) => any;\n /** \n * Fires when the object loses the input focus. \n * @param ev The focus event.\n */\n onblur: (this: Document, ev: FocusEvent) => any;\n /**\n * Occurs when playback is possible, but would require further buffering. \n * @param ev The event.\n */\n oncanplay: (this: Document, ev: Event) => any;\n oncanplaythrough: (this: Document, ev: Event) => any;\n /**\n * Fires when the contents of the object or selection have changed. \n * @param ev The event.\n */\n onchange: (this: Document, ev: Event) => any;\n /**\n * Fires when the user clicks the left mouse button on the object\n * @param ev The mouse event.\n */\n onclick: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user clicks the right mouse button in the client area, opening the context menu. \n * @param ev The mouse event.\n */\n oncontextmenu: (this: Document, ev: PointerEvent) => any;\n /**\n * Fires when the user double-clicks the object.\n * @param ev The mouse event.\n */\n ondblclick: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the activeElement is changed from the current object to another object in the parent document.\n * @param ev The UI Event\n */\n ondeactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires on the source object continuously during a drag operation.\n * @param ev The event.\n */\n ondrag: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the source object when the user releases the mouse at the close of a drag operation.\n * @param ev The event.\n */\n ondragend: (this: Document, ev: DragEvent) => any;\n /** \n * Fires on the target element when the user drags the object to a valid drop target.\n * @param ev The drag event.\n */\n ondragenter: (this: Document, ev: DragEvent) => any;\n /** \n * Fires on the target object when the user moves the mouse out of a valid drop target during a drag operation.\n * @param ev The drag event.\n */\n ondragleave: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the target element continuously while the user drags the object over a valid drop target.\n * @param ev The event.\n */\n ondragover: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the source object when the user starts to drag a text selection or selected object. \n * @param ev The event.\n */\n ondragstart: (this: Document, ev: DragEvent) => any;\n ondrop: (this: Document, ev: DragEvent) => any;\n /**\n * Occurs when the duration attribute is updated. \n * @param ev The event.\n */\n ondurationchange: (this: Document, ev: Event) => any;\n /**\n * Occurs when the media element is reset to its initial state. \n * @param ev The event.\n */\n onemptied: (this: Document, ev: Event) => any;\n /**\n * Occurs when the end of playback is reached. \n * @param ev The event\n */\n onended: (this: Document, ev: MediaStreamErrorEvent) => any;\n /**\n * Fires when an error occurs during object loading.\n * @param ev The event.\n */\n onerror: (this: Document, ev: ErrorEvent) => any;\n /**\n * Fires when the object receives focus. \n * @param ev The event.\n */\n onfocus: (this: Document, ev: FocusEvent) => any;\n onfullscreenchange: (this: Document, ev: Event) => any;\n onfullscreenerror: (this: Document, ev: Event) => any;\n oninput: (this: Document, ev: Event) => any;\n oninvalid: (this: Document, ev: Event) => any;\n /**\n * Fires when the user presses a key.\n * @param ev The keyboard event\n */\n onkeydown: (this: Document, ev: KeyboardEvent) => any;\n /**\n * Fires when the user presses an alphanumeric key.\n * @param ev The event.\n */\n onkeypress: (this: Document, ev: KeyboardEvent) => any;\n /**\n * Fires when the user releases a key.\n * @param ev The keyboard event\n */\n onkeyup: (this: Document, ev: KeyboardEvent) => any;\n /**\n * Fires immediately after the browser loads the object. \n * @param ev The event.\n */\n onload: (this: Document, ev: Event) => any;\n /**\n * Occurs when media data is loaded at the current playback position. \n * @param ev The event.\n */\n onloadeddata: (this: Document, ev: Event) => any;\n /**\n * Occurs when the duration and dimensions of the media have been determined.\n * @param ev The event.\n */\n onloadedmetadata: (this: Document, ev: Event) => any;\n /**\n * Occurs when Internet Explorer begins looking for media data. \n * @param ev The event.\n */\n onloadstart: (this: Document, ev: Event) => any;\n /**\n * Fires when the user clicks the object with either mouse button. \n * @param ev The mouse event.\n */\n onmousedown: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user moves the mouse over the object. \n * @param ev The mouse event.\n */\n onmousemove: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user moves the mouse pointer outside the boundaries of the object. \n * @param ev The mouse event.\n */\n onmouseout: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user moves the mouse pointer into the object.\n * @param ev The mouse event.\n */\n onmouseover: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user releases a mouse button while the mouse is over the object. \n * @param ev The mouse event.\n */\n onmouseup: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the wheel button is rotated. \n * @param ev The mouse event\n */\n onmousewheel: (this: Document, ev: WheelEvent) => any;\n onmscontentzoom: (this: Document, ev: UIEvent) => any;\n onmsgesturechange: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturedoubletap: (this: Document, ev: MSGestureEvent) => any;\n onmsgestureend: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturehold: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturestart: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturetap: (this: Document, ev: MSGestureEvent) => any;\n onmsinertiastart: (this: Document, ev: MSGestureEvent) => any;\n onmsmanipulationstatechanged: (this: Document, ev: MSManipulationEvent) => any;\n onmspointercancel: (this: Document, ev: MSPointerEvent) => any;\n onmspointerdown: (this: Document, ev: MSPointerEvent) => any;\n onmspointerenter: (this: Document, ev: MSPointerEvent) => any;\n onmspointerleave: (this: Document, ev: MSPointerEvent) => any;\n onmspointermove: (this: Document, ev: MSPointerEvent) => any;\n onmspointerout: (this: Document, ev: MSPointerEvent) => any;\n onmspointerover: (this: Document, ev: MSPointerEvent) => any;\n onmspointerup: (this: Document, ev: MSPointerEvent) => any;\n /**\n * Occurs when an item is removed from a Jump List of a webpage running in Site Mode. \n * @param ev The event.\n */\n onmssitemodejumplistitemremoved: (this: Document, ev: MSSiteModeEvent) => any;\n /**\n * Occurs when a user clicks a button in a Thumbnail Toolbar of a webpage running in Site Mode.\n * @param ev The event.\n */\n onmsthumbnailclick: (this: Document, ev: MSSiteModeEvent) => any;\n /**\n * Occurs when playback is paused.\n * @param ev The event.\n */\n onpause: (this: Document, ev: Event) => any;\n /**\n * Occurs when the play method is requested. \n * @param ev The event.\n */\n onplay: (this: Document, ev: Event) => any;\n /**\n * Occurs when the audio or video has started playing. \n * @param ev The event.\n */\n onplaying: (this: Document, ev: Event) => any;\n onpointerlockchange: (this: Document, ev: Event) => any;\n onpointerlockerror: (this: Document, ev: Event) => any;\n /**\n * Occurs to indicate progress while downloading media data. \n * @param ev The event.\n */\n onprogress: (this: Document, ev: ProgressEvent) => any;\n /**\n * Occurs when the playback rate is increased or decreased. \n * @param ev The event.\n */\n onratechange: (this: Document, ev: Event) => any;\n /**\n * Fires when the state of the object has changed.\n * @param ev The event\n */\n onreadystatechange: (this: Document, ev: Event) => any;\n /**\n * Fires when the user resets a form. \n * @param ev The event.\n */\n onreset: (this: Document, ev: Event) => any;\n /**\n * Fires when the user repositions the scroll box in the scroll bar on the object. \n * @param ev The event.\n */\n onscroll: (this: Document, ev: UIEvent) => any;\n /**\n * Occurs when the seek operation ends. \n * @param ev The event.\n */\n onseeked: (this: Document, ev: Event) => any;\n /**\n * Occurs when the current playback position is moved. \n * @param ev The event.\n */\n onseeking: (this: Document, ev: Event) => any;\n /**\n * Fires when the current selection changes.\n * @param ev The event.\n */\n onselect: (this: Document, ev: UIEvent) => any;\n /**\n * Fires when the selection state of a document changes.\n * @param ev The event.\n */\n onselectionchange: (this: Document, ev: Event) => any;\n onselectstart: (this: Document, ev: Event) => any;\n /**\n * Occurs when the download has stopped. \n * @param ev The event.\n */\n onstalled: (this: Document, ev: Event) => any;\n /**\n * Fires when the user clicks the Stop button or leaves the Web page.\n * @param ev The event.\n */\n onstop: (this: Document, ev: Event) => any;\n onsubmit: (this: Document, ev: Event) => any;\n /**\n * Occurs if the load operation has been intentionally halted. \n * @param ev The event.\n */\n onsuspend: (this: Document, ev: Event) => any;\n /**\n * Occurs to indicate the current playback position.\n * @param ev The event.\n */\n ontimeupdate: (this: Document, ev: Event) => any;\n ontouchcancel: (ev: TouchEvent) => any;\n ontouchend: (ev: TouchEvent) => any;\n ontouchmove: (ev: TouchEvent) => any;\n ontouchstart: (ev: TouchEvent) => any;\n /**\n * Occurs when the volume is changed, or playback is muted or unmuted.\n * @param ev The event.\n */\n onvolumechange: (this: Document, ev: Event) => any;\n /**\n * Occurs when playback stops because the next frame of a video resource is not available. \n * @param ev The event.\n */\n onwaiting: (this: Document, ev: Event) => any;\n onwebkitfullscreenchange: (this: Document, ev: Event) => any;\n onwebkitfullscreenerror: (this: Document, ev: Event) => any;\n plugins: HTMLCollectionOf;\n readonly pointerLockElement: Element;\n /**\n * Retrieves a value that indicates the current state of the object.\n */\n readonly readyState: string;\n /**\n * Gets the URL of the location that referred the user to the current page.\n */\n readonly referrer: string;\n /**\n * Gets the root svg element in the document hierarchy.\n */\n readonly rootElement: SVGSVGElement;\n /**\n * Retrieves a collection of all script objects in the document.\n */\n scripts: HTMLCollectionOf;\n readonly scrollingElement: Element | null;\n /**\n * Retrieves a collection of styleSheet objects representing the style sheets that correspond to each instance of a link or style object in the document.\n */\n readonly styleSheets: StyleSheetList;\n /**\n * Contains the title of the document.\n */\n title: string;\n readonly visibilityState: VisibilityState;\n /** \n * Sets or gets the color of the links that the user has visited.\n */\n vlinkColor: string;\n readonly webkitCurrentFullScreenElement: Element | null;\n readonly webkitFullscreenElement: Element | null;\n readonly webkitFullscreenEnabled: boolean;\n readonly webkitIsFullScreen: boolean;\n readonly xmlEncoding: string | null;\n xmlStandalone: boolean;\n /**\n * Gets or sets the version attribute specified in the declaration of an XML document.\n */\n xmlVersion: string | null;\n adoptNode(source: T): T;\n captureEvents(): void;\n caretRangeFromPoint(x: number, y: number): Range;\n clear(): void;\n /**\n * Closes an output stream and forces the sent data to display.\n */\n close(): void;\n /**\n * Creates an attribute object with a specified name.\n * @param name String that sets the attribute object's name.\n */\n createAttribute(name: string): Attr;\n createAttributeNS(namespaceURI: string | null, qualifiedName: string): Attr;\n createCDATASection(data: string): CDATASection;\n /**\n * Creates a comment object with the specified data.\n * @param data Sets the comment object's data.\n */\n createComment(data: string): Comment;\n /**\n * Creates a new document.\n */\n createDocumentFragment(): DocumentFragment;\n /**\n * Creates an instance of the element for the specified tag.\n * @param tagName The name of an element.\n */\n createElement(tagName: K): HTMLElementTagNameMap[K];\n createElement(tagName: string): HTMLElement;\n createElementNS(namespaceURI: \"http://www.w3.org/1999/xhtml\", qualifiedName: string): HTMLElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"a\"): SVGAElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"circle\"): SVGCircleElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"clipPath\"): SVGClipPathElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"componentTransferFunction\"): SVGComponentTransferFunctionElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"defs\"): SVGDefsElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"desc\"): SVGDescElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"ellipse\"): SVGEllipseElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feBlend\"): SVGFEBlendElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feColorMatrix\"): SVGFEColorMatrixElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feComponentTransfer\"): SVGFEComponentTransferElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feComposite\"): SVGFECompositeElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feConvolveMatrix\"): SVGFEConvolveMatrixElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feDiffuseLighting\"): SVGFEDiffuseLightingElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feDisplacementMap\"): SVGFEDisplacementMapElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feDistantLight\"): SVGFEDistantLightElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFlood\"): SVGFEFloodElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncA\"): SVGFEFuncAElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncB\"): SVGFEFuncBElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncG\"): SVGFEFuncGElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncR\"): SVGFEFuncRElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feGaussianBlur\"): SVGFEGaussianBlurElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feImage\"): SVGFEImageElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feMerge\"): SVGFEMergeElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feMergeNode\"): SVGFEMergeNodeElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feMorphology\"): SVGFEMorphologyElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feOffset\"): SVGFEOffsetElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"fePointLight\"): SVGFEPointLightElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feSpecularLighting\"): SVGFESpecularLightingElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feSpotLight\"): SVGFESpotLightElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feTile\"): SVGFETileElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feTurbulence\"): SVGFETurbulenceElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"filter\"): SVGFilterElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"foreignObject\"): SVGForeignObjectElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"g\"): SVGGElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"image\"): SVGImageElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"gradient\"): SVGGradientElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"line\"): SVGLineElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"linearGradient\"): SVGLinearGradientElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"marker\"): SVGMarkerElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"mask\"): SVGMaskElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"path\"): SVGPathElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"metadata\"): SVGMetadataElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"pattern\"): SVGPatternElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"polygon\"): SVGPolygonElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"polyline\"): SVGPolylineElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"radialGradient\"): SVGRadialGradientElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"rect\"): SVGRectElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"svg\"): SVGSVGElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"script\"): SVGScriptElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"stop\"): SVGStopElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"style\"): SVGStyleElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"switch\"): SVGSwitchElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"symbol\"): SVGSymbolElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"tspan\"): SVGTSpanElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"textContent\"): SVGTextContentElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"text\"): SVGTextElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"textPath\"): SVGTextPathElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"textPositioning\"): SVGTextPositioningElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"title\"): SVGTitleElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"use\"): SVGUseElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"view\"): SVGViewElement\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: string): SVGElement\n createElementNS(namespaceURI: string | null, qualifiedName: string): Element;\n createExpression(expression: string, resolver: XPathNSResolver): XPathExpression;\n createNSResolver(nodeResolver: Node): XPathNSResolver;\n /**\n * Creates a NodeIterator object that you can use to traverse filtered lists of nodes or elements in a document. \n * @param root The root element or node to start traversing on.\n * @param whatToShow The type of nodes or elements to appear in the node list\n * @param filter A custom NodeFilter function to use. For more information, see filter. Use null for no filter.\n * @param entityReferenceExpansion A flag that specifies whether entity reference nodes are expanded.\n */\n createNodeIterator(root: Node, whatToShow?: number, filter?: NodeFilter, entityReferenceExpansion?: boolean): NodeIterator;\n createProcessingInstruction(target: string, data: string): ProcessingInstruction;\n /**\n * Returns an empty range object that has both of its boundary points positioned at the beginning of the document. \n */\n createRange(): Range;\n /**\n * Creates a text string from the specified value. \n * @param data String that specifies the nodeValue property of the text node.\n */\n createTextNode(data: string): Text;\n createTouch(view: Window, target: EventTarget, identifier: number, pageX: number, pageY: number, screenX: number, screenY: number): Touch;\n createTouchList(...touches: Touch[]): TouchList;\n /**\n * Creates a TreeWalker object that you can use to traverse filtered lists of nodes or elements in a document.\n * @param root The root element or node to start traversing on.\n * @param whatToShow The type of nodes or elements to appear in the node list. For more information, see whatToShow.\n * @param filter A custom NodeFilter function to use.\n * @param entityReferenceExpansion A flag that specifies whether entity reference nodes are expanded.\n */\n createTreeWalker(root: Node, whatToShow?: number, filter?: NodeFilter, entityReferenceExpansion?: boolean): TreeWalker;\n /**\n * Returns the element for the specified x coordinate and the specified y coordinate. \n * @param x The x-offset\n * @param y The y-offset\n */\n elementFromPoint(x: number, y: number): Element;\n evaluate(expression: string, contextNode: Node, resolver: XPathNSResolver | null, type: number, result: XPathResult | null): XPathResult;\n /**\n * Executes a command on the current document, current selection, or the given range.\n * @param commandId String that specifies the command to execute. This command can be any of the command identifiers that can be executed in script.\n * @param showUI Display the user interface, defaults to false.\n * @param value Value to assign.\n */\n execCommand(commandId: string, showUI?: boolean, value?: any): boolean;\n /**\n * Displays help information for the given command identifier.\n * @param commandId Displays help information for the given command identifier.\n */\n execCommandShowHelp(commandId: string): boolean;\n exitFullscreen(): void;\n exitPointerLock(): void;\n /**\n * Causes the element to receive the focus and executes the code specified by the onfocus event.\n */\n focus(): void;\n /**\n * Returns a reference to the first object with the specified value of the ID or NAME attribute.\n * @param elementId String that specifies the ID value. Case-insensitive.\n */\n getElementById(elementId: string): HTMLElement | null;\n getElementsByClassName(classNames: string): HTMLCollectionOf;\n /**\n * Gets a collection of objects based on the value of the NAME or ID attribute.\n * @param elementName Gets a collection of objects based on the value of the NAME or ID attribute.\n */\n getElementsByName(elementName: string): NodeListOf;\n /**\n * Retrieves a collection of objects based on the specified element name.\n * @param name Specifies the name of an element.\n */\n getElementsByTagName(tagname: K): ElementListTagNameMap[K];\n getElementsByTagName(tagname: string): NodeListOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/1999/xhtml\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/2000/svg\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: string, localName: string): HTMLCollectionOf;\n /**\n * Returns an object representing the current selection of the document that is loaded into the object displaying a webpage.\n */\n getSelection(): Selection;\n /**\n * Gets a value indicating whether the object currently has focus.\n */\n hasFocus(): boolean;\n importNode(importedNode: T, deep: boolean): T;\n msElementsFromPoint(x: number, y: number): NodeListOf;\n msElementsFromRect(left: number, top: number, width: number, height: number): NodeListOf;\n /**\n * Opens a new window and loads a document specified by a given URL. Also, opens a new window that uses the url parameter and the name parameter to collect the output of the write method and the writeln method.\n * @param url Specifies a MIME type for the document.\n * @param name Specifies the name of the window. This name is used as the value for the TARGET attribute on a form or an anchor element.\n * @param features Contains a list of items separated by commas. Each item consists of an option and a value, separated by an equals sign (for example, \"fullscreen=yes, toolbar=yes\"). The following values are supported.\n * @param replace Specifies whether the existing entry for the document is replaced in the history list.\n */\n open(url?: string, name?: string, features?: string, replace?: boolean): Document;\n /** \n * Returns a Boolean value that indicates whether a specified command can be successfully executed using execCommand, given the current state of the document.\n * @param commandId Specifies a command identifier.\n */\n queryCommandEnabled(commandId: string): boolean;\n /**\n * Returns a Boolean value that indicates whether the specified command is in the indeterminate state.\n * @param commandId String that specifies a command identifier.\n */\n queryCommandIndeterm(commandId: string): boolean;\n /**\n * Returns a Boolean value that indicates the current state of the command.\n * @param commandId String that specifies a command identifier.\n */\n queryCommandState(commandId: string): boolean;\n /**\n * Returns a Boolean value that indicates whether the current command is supported on the current range.\n * @param commandId Specifies a command identifier.\n */\n queryCommandSupported(commandId: string): boolean;\n /**\n * Retrieves the string associated with a command.\n * @param commandId String that contains the identifier of a command. This can be any command identifier given in the list of Command Identifiers. \n */\n queryCommandText(commandId: string): string;\n /**\n * Returns the current value of the document, range, or current selection for the given command.\n * @param commandId String that specifies a command identifier.\n */\n queryCommandValue(commandId: string): string;\n releaseEvents(): void;\n /**\n * Allows updating the print settings for the page.\n */\n updateSettings(): void;\n webkitCancelFullScreen(): void;\n webkitExitFullscreen(): void;\n /**\n * Writes one or more HTML expressions to a document in the specified window. \n * @param content Specifies the text and HTML tags to write.\n */\n write(...content: string[]): void;\n /**\n * Writes one or more HTML expressions, followed by a carriage return, to a document in the specified window. \n * @param content The text and HTML tags to write.\n */\n writeln(...content: string[]): void;\n addEventListener(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Document: {\n prototype: Document;\n new(): Document;\n}\n\ninterface DocumentFragment extends Node, NodeSelector, ParentNode {\n getElementById(elementId: string): HTMLElement | null;\n}\n\ndeclare var DocumentFragment: {\n prototype: DocumentFragment;\n new(): DocumentFragment;\n}\n\ninterface DocumentType extends Node, ChildNode {\n readonly entities: NamedNodeMap;\n readonly internalSubset: string | null;\n readonly name: string;\n readonly notations: NamedNodeMap;\n readonly publicId: string;\n readonly systemId: string;\n}\n\ndeclare var DocumentType: {\n prototype: DocumentType;\n new(): DocumentType;\n}\n\ninterface DragEvent extends MouseEvent {\n readonly dataTransfer: DataTransfer;\n initDragEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget, dataTransferArg: DataTransfer): void;\n msConvertURL(file: File, targetType: string, targetURL?: string): void;\n}\n\ndeclare var DragEvent: {\n prototype: DragEvent;\n new(): DragEvent;\n}\n\ninterface DynamicsCompressorNode extends AudioNode {\n readonly attack: AudioParam;\n readonly knee: AudioParam;\n readonly ratio: AudioParam;\n readonly reduction: number;\n readonly release: AudioParam;\n readonly threshold: AudioParam;\n}\n\ndeclare var DynamicsCompressorNode: {\n prototype: DynamicsCompressorNode;\n new(): DynamicsCompressorNode;\n}\n\ninterface EXT_frag_depth {\n}\n\ndeclare var EXT_frag_depth: {\n prototype: EXT_frag_depth;\n new(): EXT_frag_depth;\n}\n\ninterface EXT_texture_filter_anisotropic {\n readonly MAX_TEXTURE_MAX_ANISOTROPY_EXT: number;\n readonly TEXTURE_MAX_ANISOTROPY_EXT: number;\n}\n\ndeclare var EXT_texture_filter_anisotropic: {\n prototype: EXT_texture_filter_anisotropic;\n new(): EXT_texture_filter_anisotropic;\n readonly MAX_TEXTURE_MAX_ANISOTROPY_EXT: number;\n readonly TEXTURE_MAX_ANISOTROPY_EXT: number;\n}\n\ninterface ElementEventMap extends GlobalEventHandlersEventMap {\n \"ariarequest\": Event;\n \"command\": Event;\n \"gotpointercapture\": PointerEvent;\n \"lostpointercapture\": PointerEvent;\n \"MSGestureChange\": MSGestureEvent;\n \"MSGestureDoubleTap\": MSGestureEvent;\n \"MSGestureEnd\": MSGestureEvent;\n \"MSGestureHold\": MSGestureEvent;\n \"MSGestureStart\": MSGestureEvent;\n \"MSGestureTap\": MSGestureEvent;\n \"MSGotPointerCapture\": MSPointerEvent;\n \"MSInertiaStart\": MSGestureEvent;\n \"MSLostPointerCapture\": MSPointerEvent;\n \"MSPointerCancel\": MSPointerEvent;\n \"MSPointerDown\": MSPointerEvent;\n \"MSPointerEnter\": MSPointerEvent;\n \"MSPointerLeave\": MSPointerEvent;\n \"MSPointerMove\": MSPointerEvent;\n \"MSPointerOut\": MSPointerEvent;\n \"MSPointerOver\": MSPointerEvent;\n \"MSPointerUp\": MSPointerEvent;\n \"touchcancel\": TouchEvent;\n \"touchend\": TouchEvent;\n \"touchmove\": TouchEvent;\n \"touchstart\": TouchEvent;\n \"webkitfullscreenchange\": Event;\n \"webkitfullscreenerror\": Event;\n}\n\ninterface Element extends Node, GlobalEventHandlers, ElementTraversal, NodeSelector, ChildNode, ParentNode {\n readonly classList: DOMTokenList;\n className: string;\n readonly clientHeight: number;\n readonly clientLeft: number;\n readonly clientTop: number;\n readonly clientWidth: number;\n id: string;\n innerHTML: string;\n msContentZoomFactor: number;\n readonly msRegionOverflow: string;\n onariarequest: (this: Element, ev: Event) => any;\n oncommand: (this: Element, ev: Event) => any;\n ongotpointercapture: (this: Element, ev: PointerEvent) => any;\n onlostpointercapture: (this: Element, ev: PointerEvent) => any;\n onmsgesturechange: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturedoubletap: (this: Element, ev: MSGestureEvent) => any;\n onmsgestureend: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturehold: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturestart: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturetap: (this: Element, ev: MSGestureEvent) => any;\n onmsgotpointercapture: (this: Element, ev: MSPointerEvent) => any;\n onmsinertiastart: (this: Element, ev: MSGestureEvent) => any;\n onmslostpointercapture: (this: Element, ev: MSPointerEvent) => any;\n onmspointercancel: (this: Element, ev: MSPointerEvent) => any;\n onmspointerdown: (this: Element, ev: MSPointerEvent) => any;\n onmspointerenter: (this: Element, ev: MSPointerEvent) => any;\n onmspointerleave: (this: Element, ev: MSPointerEvent) => any;\n onmspointermove: (this: Element, ev: MSPointerEvent) => any;\n onmspointerout: (this: Element, ev: MSPointerEvent) => any;\n onmspointerover: (this: Element, ev: MSPointerEvent) => any;\n onmspointerup: (this: Element, ev: MSPointerEvent) => any;\n ontouchcancel: (ev: TouchEvent) => any;\n ontouchend: (ev: TouchEvent) => any;\n ontouchmove: (ev: TouchEvent) => any;\n ontouchstart: (ev: TouchEvent) => any;\n onwebkitfullscreenchange: (this: Element, ev: Event) => any;\n onwebkitfullscreenerror: (this: Element, ev: Event) => any;\n outerHTML: string;\n readonly prefix: string | null;\n readonly scrollHeight: number;\n scrollLeft: number;\n scrollTop: number;\n readonly scrollWidth: number;\n readonly tagName: string;\n readonly assignedSlot: HTMLSlotElement | null;\n slot: string;\n readonly shadowRoot: ShadowRoot | null;\n getAttribute(name: string): string | null;\n getAttributeNS(namespaceURI: string, localName: string): string;\n getAttributeNode(name: string): Attr;\n getAttributeNodeNS(namespaceURI: string, localName: string): Attr;\n getBoundingClientRect(): ClientRect;\n getClientRects(): ClientRectList;\n getElementsByTagName(name: K): ElementListTagNameMap[K];\n getElementsByTagName(name: string): NodeListOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/1999/xhtml\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/2000/svg\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: string, localName: string): HTMLCollectionOf;\n hasAttribute(name: string): boolean;\n hasAttributeNS(namespaceURI: string, localName: string): boolean;\n msGetRegionContent(): MSRangeCollection;\n msGetUntransformedBounds(): ClientRect;\n msMatchesSelector(selectors: string): boolean;\n msReleasePointerCapture(pointerId: number): void;\n msSetPointerCapture(pointerId: number): void;\n msZoomTo(args: MsZoomToOptions): void;\n releasePointerCapture(pointerId: number): void;\n removeAttribute(qualifiedName: string): void;\n removeAttributeNS(namespaceURI: string, localName: string): void;\n removeAttributeNode(oldAttr: Attr): Attr;\n requestFullscreen(): void;\n requestPointerLock(): void;\n setAttribute(name: string, value: string): void;\n setAttributeNS(namespaceURI: string, qualifiedName: string, value: string): void;\n setAttributeNode(newAttr: Attr): Attr;\n setAttributeNodeNS(newAttr: Attr): Attr;\n setPointerCapture(pointerId: number): void;\n webkitMatchesSelector(selectors: string): boolean;\n webkitRequestFullScreen(): void;\n webkitRequestFullscreen(): void;\n getElementsByClassName(classNames: string): NodeListOf;\n matches(selector: string): boolean;\n closest(selector: string): Element | null;\n scrollIntoView(arg?: boolean | ScrollIntoViewOptions): void;\n scroll(options?: ScrollToOptions): void;\n scroll(x: number, y: number): void;\n scrollTo(options?: ScrollToOptions): void;\n scrollTo(x: number, y: number): void;\n scrollBy(options?: ScrollToOptions): void;\n scrollBy(x: number, y: number): void;\n insertAdjacentElement(position: string, insertedElement: Element): Element | null;\n insertAdjacentHTML(where: string, html: string): void;\n insertAdjacentText(where: string, text: string): void;\n attachShadow(shadowRootInitDict: ShadowRootInit): ShadowRoot;\n addEventListener(type: K, listener: (this: Element, ev: ElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Element: {\n prototype: Element;\n new(): Element;\n}\n\ninterface ErrorEvent extends Event {\n readonly colno: number;\n readonly error: any;\n readonly filename: string;\n readonly lineno: number;\n readonly message: string;\n initErrorEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, messageArg: string, filenameArg: string, linenoArg: number): void;\n}\n\ndeclare var ErrorEvent: {\n prototype: ErrorEvent;\n new(type: string, errorEventInitDict?: ErrorEventInit): ErrorEvent;\n}\n\ninterface Event {\n readonly bubbles: boolean;\n cancelBubble: boolean;\n readonly cancelable: boolean;\n readonly currentTarget: EventTarget;\n readonly defaultPrevented: boolean;\n readonly eventPhase: number;\n readonly isTrusted: boolean;\n returnValue: boolean;\n readonly srcElement: Element | null;\n readonly target: EventTarget;\n readonly timeStamp: number;\n readonly type: string;\n readonly scoped: boolean;\n initEvent(eventTypeArg: string, canBubbleArg: boolean, cancelableArg: boolean): void;\n preventDefault(): void;\n stopImmediatePropagation(): void;\n stopPropagation(): void;\n deepPath(): EventTarget[];\n readonly AT_TARGET: number;\n readonly BUBBLING_PHASE: number;\n readonly CAPTURING_PHASE: number;\n}\n\ndeclare var Event: {\n prototype: Event;\n new(typeArg: string, eventInitDict?: EventInit): Event;\n readonly AT_TARGET: number;\n readonly BUBBLING_PHASE: number;\n readonly CAPTURING_PHASE: number;\n}\n\ninterface EventTarget {\n addEventListener(type: string, listener?: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;\n dispatchEvent(evt: Event): boolean;\n removeEventListener(type: string, listener?: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;\n}\n\ndeclare var EventTarget: {\n prototype: EventTarget;\n new(): EventTarget;\n}\n\ninterface ExtensionScriptApis {\n extensionIdToShortId(extensionId: string): number;\n fireExtensionApiTelemetry(functionName: string, isSucceeded: boolean, isSupported: boolean): void;\n genericFunction(routerAddress: any, parameters?: string, callbackId?: number): void;\n genericSynchronousFunction(functionId: number, parameters?: string): string;\n getExtensionId(): string;\n registerGenericFunctionCallbackHandler(callbackHandler: any): void;\n registerGenericPersistentCallbackHandler(callbackHandler: any): void;\n}\n\ndeclare var ExtensionScriptApis: {\n prototype: ExtensionScriptApis;\n new(): ExtensionScriptApis;\n}\n\ninterface External {\n}\n\ndeclare var External: {\n prototype: External;\n new(): External;\n}\n\ninterface File extends Blob {\n readonly lastModifiedDate: any;\n readonly name: string;\n readonly webkitRelativePath: string;\n}\n\ndeclare var File: {\n prototype: File;\n new (parts: (ArrayBuffer | ArrayBufferView | Blob | string)[], filename: string, properties?: FilePropertyBag): File;\n}\n\ninterface FileList {\n readonly length: number;\n item(index: number): File;\n [index: number]: File;\n}\n\ndeclare var FileList: {\n prototype: FileList;\n new(): FileList;\n}\n\ninterface FileReader extends EventTarget, MSBaseReader {\n readonly error: DOMError;\n readAsArrayBuffer(blob: Blob): void;\n readAsBinaryString(blob: Blob): void;\n readAsDataURL(blob: Blob): void;\n readAsText(blob: Blob, encoding?: string): void;\n addEventListener(type: K, listener: (this: FileReader, ev: MSBaseReaderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var FileReader: {\n prototype: FileReader;\n new(): FileReader;\n}\n\ninterface FocusEvent extends UIEvent {\n readonly relatedTarget: EventTarget;\n initFocusEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, relatedTargetArg: EventTarget): void;\n}\n\ndeclare var FocusEvent: {\n prototype: FocusEvent;\n new(typeArg: string, eventInitDict?: FocusEventInit): FocusEvent;\n}\n\ninterface FocusNavigationEvent extends Event {\n readonly navigationReason: NavigationReason;\n readonly originHeight: number;\n readonly originLeft: number;\n readonly originTop: number;\n readonly originWidth: number;\n requestFocus(): void;\n}\n\ndeclare var FocusNavigationEvent: {\n prototype: FocusNavigationEvent;\n new(type: string, eventInitDict?: FocusNavigationEventInit): FocusNavigationEvent;\n}\n\ninterface FormData {\n append(name: string, value: string | Blob, fileName?: string): void;\n delete(name: string): void;\n get(name: string): FormDataEntryValue | null;\n getAll(name: string): FormDataEntryValue[];\n has(name: string): boolean;\n set(name: string, value: string | Blob, fileName?: string): void;\n}\n\ndeclare var FormData: {\n prototype: FormData;\n new (form?: HTMLFormElement): FormData;\n}\n\ninterface GainNode extends AudioNode {\n readonly gain: AudioParam;\n}\n\ndeclare var GainNode: {\n prototype: GainNode;\n new(): GainNode;\n}\n\ninterface Gamepad {\n readonly axes: number[];\n readonly buttons: GamepadButton[];\n readonly connected: boolean;\n readonly id: string;\n readonly index: number;\n readonly mapping: string;\n readonly timestamp: number;\n}\n\ndeclare var Gamepad: {\n prototype: Gamepad;\n new(): Gamepad;\n}\n\ninterface GamepadButton {\n readonly pressed: boolean;\n readonly value: number;\n}\n\ndeclare var GamepadButton: {\n prototype: GamepadButton;\n new(): GamepadButton;\n}\n\ninterface GamepadEvent extends Event {\n readonly gamepad: Gamepad;\n}\n\ndeclare var GamepadEvent: {\n prototype: GamepadEvent;\n new(typeArg: string, eventInitDict?: GamepadEventInit): GamepadEvent;\n}\n\ninterface Geolocation {\n clearWatch(watchId: number): void;\n getCurrentPosition(successCallback: PositionCallback, errorCallback?: PositionErrorCallback, options?: PositionOptions): void;\n watchPosition(successCallback: PositionCallback, errorCallback?: PositionErrorCallback, options?: PositionOptions): number;\n}\n\ndeclare var Geolocation: {\n prototype: Geolocation;\n new(): Geolocation;\n}\n\ninterface HTMLAllCollection {\n readonly length: number;\n item(nameOrIndex?: string): HTMLCollection | Element | null;\n namedItem(name: string): HTMLCollection | Element | null;\n [index: number]: Element;\n}\n\ndeclare var HTMLAllCollection: {\n prototype: HTMLAllCollection;\n new(): HTMLAllCollection;\n}\n\ninterface HTMLAnchorElement extends HTMLElement {\n Methods: string;\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n /**\n * Sets or retrieves the coordinates of the object.\n */\n coords: string;\n download: string;\n /**\n * Contains the anchor portion of the URL including the hash sign (#).\n */\n hash: string;\n /**\n * Contains the hostname and port values of the URL.\n */\n host: string;\n /**\n * Contains the hostname of a URL.\n */\n hostname: string;\n /**\n * Sets or retrieves a destination URL or an anchor point.\n */\n href: string;\n /**\n * Sets or retrieves the language code of the object.\n */\n hreflang: string;\n readonly mimeType: string;\n /**\n * Sets or retrieves the shape of the object.\n */\n name: string;\n readonly nameProp: string;\n /**\n * Contains the pathname of the URL.\n */\n pathname: string;\n /**\n * Sets or retrieves the port number associated with a URL.\n */\n port: string;\n /**\n * Contains the protocol of the URL.\n */\n protocol: string;\n readonly protocolLong: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rel: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rev: string;\n /**\n * Sets or retrieves the substring of the href property that follows the question mark.\n */\n search: string;\n /**\n * Sets or retrieves the shape of the object.\n */\n shape: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Retrieves or sets the text of the object as a string. \n */\n text: string;\n type: string;\n urn: string;\n /** \n * Returns a string representation of an object.\n */\n toString(): string;\n addEventListener(type: K, listener: (this: HTMLAnchorElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAnchorElement: {\n prototype: HTMLAnchorElement;\n new(): HTMLAnchorElement;\n}\n\ninterface HTMLAppletElement extends HTMLElement {\n /**\n * Retrieves a string of the URL where the object tag can be found. This is often the href of the document that the object is in, or the value set by a base element.\n */\n readonly BaseHref: string;\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Gets or sets the optional alternative HTML script to execute if the object fails to load.\n */\n altHtml: string;\n /**\n * Sets or retrieves a character string that can be used to implement your own archive functionality for the object.\n */\n archive: string;\n border: string;\n code: string;\n /**\n * Sets or retrieves the URL of the component.\n */\n codeBase: string;\n /**\n * Sets or retrieves the Internet media type for the code associated with the object.\n */\n codeType: string;\n /**\n * Address of a pointer to the document this page or frame contains. If there is no document, then null will be returned.\n */\n readonly contentDocument: Document;\n /**\n * Sets or retrieves the URL that references the data of the object.\n */\n data: string;\n /**\n * Sets or retrieves a character string that can be used to implement your own declare functionality for the object.\n */\n declare: boolean;\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n hspace: number;\n /**\n * Sets or retrieves the shape of the object.\n */\n name: string;\n object: string | null;\n /**\n * Sets or retrieves a message to be displayed while an object is loading.\n */\n standby: string;\n /**\n * Returns the content type of the object.\n */\n type: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n vspace: number;\n width: number;\n addEventListener(type: K, listener: (this: HTMLAppletElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAppletElement: {\n prototype: HTMLAppletElement;\n new(): HTMLAppletElement;\n}\n\ninterface HTMLAreaElement extends HTMLElement {\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Sets or retrieves the coordinates of the object.\n */\n coords: string;\n download: string;\n /**\n * Sets or retrieves the subsection of the href property that follows the number sign (#).\n */\n hash: string;\n /**\n * Sets or retrieves the hostname and port number of the location or URL.\n */\n host: string;\n /**\n * Sets or retrieves the host name part of the location or URL. \n */\n hostname: string;\n /**\n * Sets or retrieves a destination URL or an anchor point.\n */\n href: string;\n /**\n * Sets or gets whether clicks in this region cause action.\n */\n noHref: boolean;\n /**\n * Sets or retrieves the file name or path specified by the object.\n */\n pathname: string;\n /**\n * Sets or retrieves the port number associated with a URL.\n */\n port: string;\n /**\n * Sets or retrieves the protocol portion of a URL.\n */\n protocol: string;\n rel: string;\n /**\n * Sets or retrieves the substring of the href property that follows the question mark.\n */\n search: string;\n /**\n * Sets or retrieves the shape of the object.\n */\n shape: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /** \n * Returns a string representation of an object.\n */\n toString(): string;\n addEventListener(type: K, listener: (this: HTMLAreaElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAreaElement: {\n prototype: HTMLAreaElement;\n new(): HTMLAreaElement;\n}\n\ninterface HTMLAreasCollection extends HTMLCollectionBase {\n}\n\ndeclare var HTMLAreasCollection: {\n prototype: HTMLAreasCollection;\n new(): HTMLAreasCollection;\n}\n\ninterface HTMLAudioElement extends HTMLMediaElement {\n addEventListener(type: K, listener: (this: HTMLAudioElement, ev: HTMLMediaElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAudioElement: {\n prototype: HTMLAudioElement;\n new(): HTMLAudioElement;\n}\n\ninterface HTMLBRElement extends HTMLElement {\n /**\n * Sets or retrieves the side on which floating objects are not to be positioned when any IHTMLBlockElement is inserted into the document.\n */\n clear: string;\n addEventListener(type: K, listener: (this: HTMLBRElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBRElement: {\n prototype: HTMLBRElement;\n new(): HTMLBRElement;\n}\n\ninterface HTMLBaseElement extends HTMLElement {\n /**\n * Gets or sets the baseline URL on which relative links are based.\n */\n href: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n addEventListener(type: K, listener: (this: HTMLBaseElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBaseElement: {\n prototype: HTMLBaseElement;\n new(): HTMLBaseElement;\n}\n\ninterface HTMLBaseFontElement extends HTMLElement, DOML2DeprecatedColorProperty {\n /**\n * Sets or retrieves the current typeface family.\n */\n face: string;\n /**\n * Sets or retrieves the font size of the object.\n */\n size: number;\n addEventListener(type: K, listener: (this: HTMLBaseFontElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBaseFontElement: {\n prototype: HTMLBaseFontElement;\n new(): HTMLBaseFontElement;\n}\n\ninterface HTMLBodyElementEventMap extends HTMLElementEventMap {\n \"afterprint\": Event;\n \"beforeprint\": Event;\n \"beforeunload\": BeforeUnloadEvent;\n \"blur\": FocusEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"hashchange\": HashChangeEvent;\n \"load\": Event;\n \"message\": MessageEvent;\n \"offline\": Event;\n \"online\": Event;\n \"orientationchange\": Event;\n \"pagehide\": PageTransitionEvent;\n \"pageshow\": PageTransitionEvent;\n \"popstate\": PopStateEvent;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"storage\": StorageEvent;\n \"unload\": Event;\n}\n\ninterface HTMLBodyElement extends HTMLElement {\n aLink: any;\n background: string;\n bgColor: any;\n bgProperties: string;\n link: any;\n noWrap: boolean;\n onafterprint: (this: HTMLBodyElement, ev: Event) => any;\n onbeforeprint: (this: HTMLBodyElement, ev: Event) => any;\n onbeforeunload: (this: HTMLBodyElement, ev: BeforeUnloadEvent) => any;\n onblur: (this: HTMLBodyElement, ev: FocusEvent) => any;\n onerror: (this: HTMLBodyElement, ev: ErrorEvent) => any;\n onfocus: (this: HTMLBodyElement, ev: FocusEvent) => any;\n onhashchange: (this: HTMLBodyElement, ev: HashChangeEvent) => any;\n onload: (this: HTMLBodyElement, ev: Event) => any;\n onmessage: (this: HTMLBodyElement, ev: MessageEvent) => any;\n onoffline: (this: HTMLBodyElement, ev: Event) => any;\n ononline: (this: HTMLBodyElement, ev: Event) => any;\n onorientationchange: (this: HTMLBodyElement, ev: Event) => any;\n onpagehide: (this: HTMLBodyElement, ev: PageTransitionEvent) => any;\n onpageshow: (this: HTMLBodyElement, ev: PageTransitionEvent) => any;\n onpopstate: (this: HTMLBodyElement, ev: PopStateEvent) => any;\n onresize: (this: HTMLBodyElement, ev: UIEvent) => any;\n onscroll: (this: HTMLBodyElement, ev: UIEvent) => any;\n onstorage: (this: HTMLBodyElement, ev: StorageEvent) => any;\n onunload: (this: HTMLBodyElement, ev: Event) => any;\n text: any;\n vLink: any;\n addEventListener(type: K, listener: (this: HTMLBodyElement, ev: HTMLBodyElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBodyElement: {\n prototype: HTMLBodyElement;\n new(): HTMLBodyElement;\n}\n\ninterface HTMLButtonElement extends HTMLElement {\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Overrides the action attribute (where the data on a form is sent) on the parent form element.\n */\n formAction: string;\n /**\n * Used to override the encoding (formEnctype attribute) specified on the form element.\n */\n formEnctype: string;\n /**\n * Overrides the submit method attribute previously specified on a form element.\n */\n formMethod: string;\n /**\n * Overrides any validation or required attributes on a form or form elements to allow it to be submitted without validation. This can be used to create a \"save draft\"-type submit option.\n */\n formNoValidate: string;\n /**\n * Overrides the target attribute on a form element.\n */\n formTarget: string;\n /** \n * Sets or retrieves the name of the object.\n */\n name: string;\n status: any;\n /**\n * Gets the classification and default behavior of the button.\n */\n type: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /** \n * Sets or retrieves the default or selected value of the control.\n */\n value: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLButtonElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLButtonElement: {\n prototype: HTMLButtonElement;\n new(): HTMLButtonElement;\n}\n\ninterface HTMLCanvasElement extends HTMLElement {\n /**\n * Gets or sets the height of a canvas element on a document.\n */\n height: number;\n /**\n * Gets or sets the width of a canvas element on a document.\n */\n width: number;\n /**\n * Returns an object that provides methods and properties for drawing and manipulating images and graphics on a canvas element in a document. A context object includes information about colors, line widths, fonts, and other graphic parameters that can be drawn on a canvas.\n * @param contextId The identifier (ID) of the type of canvas to create. Internet Explorer 9 and Internet Explorer 10 support only a 2-D context using canvas.getContext(\"2d\"); IE11 Preview also supports 3-D or WebGL context using canvas.getContext(\"experimental-webgl\");\n */\n getContext(contextId: \"2d\", contextAttributes?: Canvas2DContextAttributes): CanvasRenderingContext2D | null;\n getContext(contextId: \"webgl\" | \"experimental-webgl\", contextAttributes?: WebGLContextAttributes): WebGLRenderingContext | null;\n getContext(contextId: string, contextAttributes?: {}): CanvasRenderingContext2D | WebGLRenderingContext | null;\n /**\n * Returns a blob object encoded as a Portable Network Graphics (PNG) format from a canvas image or drawing.\n */\n msToBlob(): Blob;\n /**\n * Returns the content of the current canvas as an image that you can use as a source for another canvas or an HTML element.\n * @param type The standard MIME type for the image format to return. If you do not specify this parameter, the default value is a PNG format image.\n */\n toDataURL(type?: string, ...args: any[]): string;\n toBlob(callback: (result: Blob | null) => void, type?: string, ...arguments: any[]): void;\n addEventListener(type: K, listener: (this: HTMLCanvasElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLCanvasElement: {\n prototype: HTMLCanvasElement;\n new(): HTMLCanvasElement;\n}\n\ninterface HTMLCollectionBase {\n /**\n * Sets or retrieves the number of objects in a collection.\n */\n readonly length: number;\n /**\n * Retrieves an object from various collections.\n */\n item(index: number): Element;\n [index: number]: Element;\n}\n\ninterface HTMLCollection extends HTMLCollectionBase {\n /**\n * Retrieves a select object or an object from an options collection.\n */\n namedItem(name: string): Element | null;\n}\n\ndeclare var HTMLCollection: {\n prototype: HTMLCollection;\n new(): HTMLCollection;\n}\n\ninterface HTMLDListElement extends HTMLElement {\n compact: boolean;\n addEventListener(type: K, listener: (this: HTMLDListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDListElement: {\n prototype: HTMLDListElement;\n new(): HTMLDListElement;\n}\n\ninterface HTMLDataElement extends HTMLElement {\n value: string;\n addEventListener(type: K, listener: (this: HTMLDataElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDataElement: {\n prototype: HTMLDataElement;\n new(): HTMLDataElement;\n}\n\ninterface HTMLDataListElement extends HTMLElement {\n options: HTMLCollectionOf;\n addEventListener(type: K, listener: (this: HTMLDataListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDataListElement: {\n prototype: HTMLDataListElement;\n new(): HTMLDataListElement;\n}\n\ninterface HTMLDirectoryElement extends HTMLElement {\n compact: boolean;\n addEventListener(type: K, listener: (this: HTMLDirectoryElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDirectoryElement: {\n prototype: HTMLDirectoryElement;\n new(): HTMLDirectoryElement;\n}\n\ninterface HTMLDivElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text. \n */\n align: string;\n /**\n * Sets or retrieves whether the browser automatically performs wordwrap.\n */\n noWrap: boolean;\n addEventListener(type: K, listener: (this: HTMLDivElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDivElement: {\n prototype: HTMLDivElement;\n new(): HTMLDivElement;\n}\n\ninterface HTMLDocument extends Document {\n addEventListener(type: K, listener: (this: HTMLDocument, ev: DocumentEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDocument: {\n prototype: HTMLDocument;\n new(): HTMLDocument;\n}\n\ninterface HTMLElementEventMap extends ElementEventMap {\n \"abort\": UIEvent;\n \"activate\": UIEvent;\n \"beforeactivate\": UIEvent;\n \"beforecopy\": ClipboardEvent;\n \"beforecut\": ClipboardEvent;\n \"beforedeactivate\": UIEvent;\n \"beforepaste\": ClipboardEvent;\n \"blur\": FocusEvent;\n \"canplay\": Event;\n \"canplaythrough\": Event;\n \"change\": Event;\n \"click\": MouseEvent;\n \"contextmenu\": PointerEvent;\n \"copy\": ClipboardEvent;\n \"cuechange\": Event;\n \"cut\": ClipboardEvent;\n \"dblclick\": MouseEvent;\n \"deactivate\": UIEvent;\n \"drag\": DragEvent;\n \"dragend\": DragEvent;\n \"dragenter\": DragEvent;\n \"dragleave\": DragEvent;\n \"dragover\": DragEvent;\n \"dragstart\": DragEvent;\n \"drop\": DragEvent;\n \"durationchange\": Event;\n \"emptied\": Event;\n \"ended\": MediaStreamErrorEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"input\": Event;\n \"invalid\": Event;\n \"keydown\": KeyboardEvent;\n \"keypress\": KeyboardEvent;\n \"keyup\": KeyboardEvent;\n \"load\": Event;\n \"loadeddata\": Event;\n \"loadedmetadata\": Event;\n \"loadstart\": Event;\n \"mousedown\": MouseEvent;\n \"mouseenter\": MouseEvent;\n \"mouseleave\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n \"mousewheel\": WheelEvent;\n \"MSContentZoom\": UIEvent;\n \"MSManipulationStateChanged\": MSManipulationEvent;\n \"paste\": ClipboardEvent;\n \"pause\": Event;\n \"play\": Event;\n \"playing\": Event;\n \"progress\": ProgressEvent;\n \"ratechange\": Event;\n \"reset\": Event;\n \"scroll\": UIEvent;\n \"seeked\": Event;\n \"seeking\": Event;\n \"select\": UIEvent;\n \"selectstart\": Event;\n \"stalled\": Event;\n \"submit\": Event;\n \"suspend\": Event;\n \"timeupdate\": Event;\n \"volumechange\": Event;\n \"waiting\": Event;\n}\n\ninterface HTMLElement extends Element {\n accessKey: string;\n readonly children: HTMLCollection;\n contentEditable: string;\n readonly dataset: DOMStringMap;\n dir: string;\n draggable: boolean;\n hidden: boolean;\n hideFocus: boolean;\n innerText: string;\n readonly isContentEditable: boolean;\n lang: string;\n readonly offsetHeight: number;\n readonly offsetLeft: number;\n readonly offsetParent: Element;\n readonly offsetTop: number;\n readonly offsetWidth: number;\n onabort: (this: HTMLElement, ev: UIEvent) => any;\n onactivate: (this: HTMLElement, ev: UIEvent) => any;\n onbeforeactivate: (this: HTMLElement, ev: UIEvent) => any;\n onbeforecopy: (this: HTMLElement, ev: ClipboardEvent) => any;\n onbeforecut: (this: HTMLElement, ev: ClipboardEvent) => any;\n onbeforedeactivate: (this: HTMLElement, ev: UIEvent) => any;\n onbeforepaste: (this: HTMLElement, ev: ClipboardEvent) => any;\n onblur: (this: HTMLElement, ev: FocusEvent) => any;\n oncanplay: (this: HTMLElement, ev: Event) => any;\n oncanplaythrough: (this: HTMLElement, ev: Event) => any;\n onchange: (this: HTMLElement, ev: Event) => any;\n onclick: (this: HTMLElement, ev: MouseEvent) => any;\n oncontextmenu: (this: HTMLElement, ev: PointerEvent) => any;\n oncopy: (this: HTMLElement, ev: ClipboardEvent) => any;\n oncuechange: (this: HTMLElement, ev: Event) => any;\n oncut: (this: HTMLElement, ev: ClipboardEvent) => any;\n ondblclick: (this: HTMLElement, ev: MouseEvent) => any;\n ondeactivate: (this: HTMLElement, ev: UIEvent) => any;\n ondrag: (this: HTMLElement, ev: DragEvent) => any;\n ondragend: (this: HTMLElement, ev: DragEvent) => any;\n ondragenter: (this: HTMLElement, ev: DragEvent) => any;\n ondragleave: (this: HTMLElement, ev: DragEvent) => any;\n ondragover: (this: HTMLElement, ev: DragEvent) => any;\n ondragstart: (this: HTMLElement, ev: DragEvent) => any;\n ondrop: (this: HTMLElement, ev: DragEvent) => any;\n ondurationchange: (this: HTMLElement, ev: Event) => any;\n onemptied: (this: HTMLElement, ev: Event) => any;\n onended: (this: HTMLElement, ev: MediaStreamErrorEvent) => any;\n onerror: (this: HTMLElement, ev: ErrorEvent) => any;\n onfocus: (this: HTMLElement, ev: FocusEvent) => any;\n oninput: (this: HTMLElement, ev: Event) => any;\n oninvalid: (this: HTMLElement, ev: Event) => any;\n onkeydown: (this: HTMLElement, ev: KeyboardEvent) => any;\n onkeypress: (this: HTMLElement, ev: KeyboardEvent) => any;\n onkeyup: (this: HTMLElement, ev: KeyboardEvent) => any;\n onload: (this: HTMLElement, ev: Event) => any;\n onloadeddata: (this: HTMLElement, ev: Event) => any;\n onloadedmetadata: (this: HTMLElement, ev: Event) => any;\n onloadstart: (this: HTMLElement, ev: Event) => any;\n onmousedown: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseenter: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseleave: (this: HTMLElement, ev: MouseEvent) => any;\n onmousemove: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseout: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseover: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseup: (this: HTMLElement, ev: MouseEvent) => any;\n onmousewheel: (this: HTMLElement, ev: WheelEvent) => any;\n onmscontentzoom: (this: HTMLElement, ev: UIEvent) => any;\n onmsmanipulationstatechanged: (this: HTMLElement, ev: MSManipulationEvent) => any;\n onpaste: (this: HTMLElement, ev: ClipboardEvent) => any;\n onpause: (this: HTMLElement, ev: Event) => any;\n onplay: (this: HTMLElement, ev: Event) => any;\n onplaying: (this: HTMLElement, ev: Event) => any;\n onprogress: (this: HTMLElement, ev: ProgressEvent) => any;\n onratechange: (this: HTMLElement, ev: Event) => any;\n onreset: (this: HTMLElement, ev: Event) => any;\n onscroll: (this: HTMLElement, ev: UIEvent) => any;\n onseeked: (this: HTMLElement, ev: Event) => any;\n onseeking: (this: HTMLElement, ev: Event) => any;\n onselect: (this: HTMLElement, ev: UIEvent) => any;\n onselectstart: (this: HTMLElement, ev: Event) => any;\n onstalled: (this: HTMLElement, ev: Event) => any;\n onsubmit: (this: HTMLElement, ev: Event) => any;\n onsuspend: (this: HTMLElement, ev: Event) => any;\n ontimeupdate: (this: HTMLElement, ev: Event) => any;\n onvolumechange: (this: HTMLElement, ev: Event) => any;\n onwaiting: (this: HTMLElement, ev: Event) => any;\n outerText: string;\n spellcheck: boolean;\n readonly style: CSSStyleDeclaration;\n tabIndex: number;\n title: string;\n blur(): void;\n click(): void;\n dragDrop(): boolean;\n focus(): void;\n msGetInputContext(): MSInputMethodContext;\n addEventListener(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLElement: {\n prototype: HTMLElement;\n new(): HTMLElement;\n}\n\ninterface HTMLEmbedElement extends HTMLElement, GetSVGDocument {\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n hidden: any;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n /**\n * Gets or sets the path to the preferred media source. This enables the Play To target device to stream the media content, which can be DRM protected, from a different location, such as a cloud media server.\n */\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Retrieves the palette used for the embedded document.\n */\n readonly palette: string;\n /**\n * Retrieves the URL of the plug-in used to view an embedded document.\n */\n readonly pluginspage: string;\n readonly readyState: string;\n /**\n * Sets or retrieves a URL to be loaded by the object.\n */\n src: string;\n /**\n * Sets or retrieves the height and width units of the embed object.\n */\n units: string;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n addEventListener(type: K, listener: (this: HTMLEmbedElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLEmbedElement: {\n prototype: HTMLEmbedElement;\n new(): HTMLEmbedElement;\n}\n\ninterface HTMLFieldSetElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n name: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLFieldSetElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFieldSetElement: {\n prototype: HTMLFieldSetElement;\n new(): HTMLFieldSetElement;\n}\n\ninterface HTMLFontElement extends HTMLElement, DOML2DeprecatedColorProperty, DOML2DeprecatedSizeProperty {\n /**\n * Sets or retrieves the current typeface family.\n */\n face: string;\n addEventListener(type: K, listener: (this: HTMLFontElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFontElement: {\n prototype: HTMLFontElement;\n new(): HTMLFontElement;\n}\n\ninterface HTMLFormControlsCollection extends HTMLCollectionBase {\n namedItem(name: string): HTMLCollection | Element | null;\n}\n\ndeclare var HTMLFormControlsCollection: {\n prototype: HTMLFormControlsCollection;\n new(): HTMLFormControlsCollection;\n}\n\ninterface HTMLFormElement extends HTMLElement {\n /**\n * Sets or retrieves a list of character encodings for input data that must be accepted by the server processing the form.\n */\n acceptCharset: string;\n /**\n * Sets or retrieves the URL to which the form content is sent for processing.\n */\n action: string;\n /**\n * Specifies whether autocomplete is applied to an editable text field.\n */\n autocomplete: string;\n /**\n * Retrieves a collection, in source order, of all controls in a given form.\n */\n readonly elements: HTMLFormControlsCollection;\n /**\n * Sets or retrieves the MIME encoding for the form.\n */\n encoding: string;\n /**\n * Sets or retrieves the encoding type for the form.\n */\n enctype: string;\n /**\n * Sets or retrieves the number of objects in a collection.\n */\n readonly length: number;\n /**\n * Sets or retrieves how to send the form data to the server.\n */\n method: string;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Designates a form that is not validated when submitted.\n */\n noValidate: boolean;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Retrieves a form object or an object from an elements collection.\n * @param name Variant of type Number or String that specifies the object or collection to retrieve. If this parameter is a Number, it is the zero-based index of the object. If this parameter is a string, all objects with matching name or id properties are retrieved, and a collection is returned if more than one match is made.\n * @param index Variant of type Number that specifies the zero-based index of the object to retrieve when a collection is returned.\n */\n item(name?: any, index?: any): any;\n /**\n * Retrieves a form object or an object from an elements collection.\n */\n namedItem(name: string): any;\n /**\n * Fires when the user resets a form.\n */\n reset(): void;\n /**\n * Fires when a FORM is about to be submitted.\n */\n submit(): void;\n addEventListener(type: K, listener: (this: HTMLFormElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [name: string]: any;\n}\n\ndeclare var HTMLFormElement: {\n prototype: HTMLFormElement;\n new(): HTMLFormElement;\n}\n\ninterface HTMLFrameElementEventMap extends HTMLElementEventMap {\n \"load\": Event;\n}\n\ninterface HTMLFrameElement extends HTMLElement, GetSVGDocument {\n /**\n * Specifies the properties of a border drawn around an object.\n */\n border: string;\n /**\n * Sets or retrieves the border color of the object.\n */\n borderColor: any;\n /**\n * Retrieves the document object of the page or frame.\n */\n readonly contentDocument: Document;\n /**\n * Retrieves the object of the specified.\n */\n readonly contentWindow: Window;\n /**\n * Sets or retrieves whether to display a border for the frame.\n */\n frameBorder: string;\n /**\n * Sets or retrieves the amount of additional space between the frames.\n */\n frameSpacing: any;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string | number;\n /**\n * Sets or retrieves a URI to a long description of the object.\n */\n longDesc: string;\n /**\n * Sets or retrieves the top and bottom margin heights before displaying the text in a frame.\n */\n marginHeight: string;\n /**\n * Sets or retrieves the left and right margin widths before displaying the text in a frame.\n */\n marginWidth: string;\n /**\n * Sets or retrieves the frame name.\n */\n name: string;\n /**\n * Sets or retrieves whether the user can resize the frame.\n */\n noResize: boolean;\n /**\n * Raised when the object has been completely received from the server.\n */\n onload: (this: HTMLFrameElement, ev: Event) => any;\n /**\n * Sets or retrieves whether the frame can be scrolled.\n */\n scrolling: string;\n /**\n * Sets or retrieves a URL to be loaded by the object.\n */\n src: string;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string | number;\n addEventListener(type: K, listener: (this: HTMLFrameElement, ev: HTMLFrameElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFrameElement: {\n prototype: HTMLFrameElement;\n new(): HTMLFrameElement;\n}\n\ninterface HTMLFrameSetElementEventMap extends HTMLElementEventMap {\n \"afterprint\": Event;\n \"beforeprint\": Event;\n \"beforeunload\": BeforeUnloadEvent;\n \"blur\": FocusEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"hashchange\": HashChangeEvent;\n \"load\": Event;\n \"message\": MessageEvent;\n \"offline\": Event;\n \"online\": Event;\n \"orientationchange\": Event;\n \"pagehide\": PageTransitionEvent;\n \"pageshow\": PageTransitionEvent;\n \"popstate\": PopStateEvent;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"storage\": StorageEvent;\n \"unload\": Event;\n}\n\ninterface HTMLFrameSetElement extends HTMLElement {\n border: string;\n /**\n * Sets or retrieves the border color of the object.\n */\n borderColor: any;\n /**\n * Sets or retrieves the frame widths of the object.\n */\n cols: string;\n /**\n * Sets or retrieves whether to display a border for the frame.\n */\n frameBorder: string;\n /**\n * Sets or retrieves the amount of additional space between the frames.\n */\n frameSpacing: any;\n name: string;\n onafterprint: (this: HTMLFrameSetElement, ev: Event) => any;\n onbeforeprint: (this: HTMLFrameSetElement, ev: Event) => any;\n onbeforeunload: (this: HTMLFrameSetElement, ev: BeforeUnloadEvent) => any;\n /**\n * Fires when the object loses the input focus.\n */\n onblur: (this: HTMLFrameSetElement, ev: FocusEvent) => any;\n onerror: (this: HTMLFrameSetElement, ev: ErrorEvent) => any;\n /**\n * Fires when the object receives focus.\n */\n onfocus: (this: HTMLFrameSetElement, ev: FocusEvent) => any;\n onhashchange: (this: HTMLFrameSetElement, ev: HashChangeEvent) => any;\n onload: (this: HTMLFrameSetElement, ev: Event) => any;\n onmessage: (this: HTMLFrameSetElement, ev: MessageEvent) => any;\n onoffline: (this: HTMLFrameSetElement, ev: Event) => any;\n ononline: (this: HTMLFrameSetElement, ev: Event) => any;\n onorientationchange: (this: HTMLFrameSetElement, ev: Event) => any;\n onpagehide: (this: HTMLFrameSetElement, ev: PageTransitionEvent) => any;\n onpageshow: (this: HTMLFrameSetElement, ev: PageTransitionEvent) => any;\n onpopstate: (this: HTMLFrameSetElement, ev: PopStateEvent) => any;\n onresize: (this: HTMLFrameSetElement, ev: UIEvent) => any;\n onscroll: (this: HTMLFrameSetElement, ev: UIEvent) => any;\n onstorage: (this: HTMLFrameSetElement, ev: StorageEvent) => any;\n onunload: (this: HTMLFrameSetElement, ev: Event) => any;\n /**\n * Sets or retrieves the frame heights of the object.\n */\n rows: string;\n addEventListener(type: K, listener: (this: HTMLFrameSetElement, ev: HTMLFrameSetElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFrameSetElement: {\n prototype: HTMLFrameSetElement;\n new(): HTMLFrameSetElement;\n}\n\ninterface HTMLHRElement extends HTMLElement, DOML2DeprecatedColorProperty, DOML2DeprecatedSizeProperty {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves whether the horizontal rule is drawn with 3-D shading.\n */\n noShade: boolean;\n /**\n * Sets or retrieves the width of the object.\n */\n width: number;\n addEventListener(type: K, listener: (this: HTMLHRElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHRElement: {\n prototype: HTMLHRElement;\n new(): HTMLHRElement;\n}\n\ninterface HTMLHeadElement extends HTMLElement {\n profile: string;\n addEventListener(type: K, listener: (this: HTMLHeadElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHeadElement: {\n prototype: HTMLHeadElement;\n new(): HTMLHeadElement;\n}\n\ninterface HTMLHeadingElement extends HTMLElement {\n /**\n * Sets or retrieves a value that indicates the table alignment.\n */\n align: string;\n addEventListener(type: K, listener: (this: HTMLHeadingElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHeadingElement: {\n prototype: HTMLHeadingElement;\n new(): HTMLHeadingElement;\n}\n\ninterface HTMLHtmlElement extends HTMLElement {\n /**\n * Sets or retrieves the DTD version that governs the current document.\n */\n version: string;\n addEventListener(type: K, listener: (this: HTMLHtmlElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHtmlElement: {\n prototype: HTMLHtmlElement;\n new(): HTMLHtmlElement;\n}\n\ninterface HTMLIFrameElementEventMap extends HTMLElementEventMap {\n \"load\": Event;\n}\n\ninterface HTMLIFrameElement extends HTMLElement, GetSVGDocument {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n allowFullscreen: boolean;\n allowPaymentRequest: boolean;\n /**\n * Specifies the properties of a border drawn around an object.\n */\n border: string;\n /**\n * Retrieves the document object of the page or frame.\n */\n readonly contentDocument: Document;\n /**\n * Retrieves the object of the specified.\n */\n readonly contentWindow: Window;\n /**\n * Sets or retrieves whether to display a border for the frame.\n */\n frameBorder: string;\n /**\n * Sets or retrieves the amount of additional space between the frames.\n */\n frameSpacing: any;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n /**\n * Sets or retrieves the horizontal margin for the object.\n */\n hspace: number;\n /**\n * Sets or retrieves a URI to a long description of the object.\n */\n longDesc: string;\n /**\n * Sets or retrieves the top and bottom margin heights before displaying the text in a frame.\n */\n marginHeight: string;\n /**\n * Sets or retrieves the left and right margin widths before displaying the text in a frame.\n */\n marginWidth: string;\n /**\n * Sets or retrieves the frame name.\n */\n name: string;\n /**\n * Sets or retrieves whether the user can resize the frame.\n */\n noResize: boolean;\n /**\n * Raised when the object has been completely received from the server.\n */\n onload: (this: HTMLIFrameElement, ev: Event) => any;\n readonly sandbox: DOMSettableTokenList;\n /**\n * Sets or retrieves whether the frame can be scrolled.\n */\n scrolling: string;\n /**\n * Sets or retrieves a URL to be loaded by the object.\n */\n src: string;\n /**\n * Sets or retrieves the vertical margin for the object.\n */\n vspace: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n addEventListener(type: K, listener: (this: HTMLIFrameElement, ev: HTMLIFrameElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLIFrameElement: {\n prototype: HTMLIFrameElement;\n new(): HTMLIFrameElement;\n}\n\ninterface HTMLImageElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Specifies the properties of a border drawn around an object.\n */\n border: string;\n /**\n * Retrieves whether the object is fully loaded.\n */\n readonly complete: boolean;\n crossOrigin: string | null;\n readonly currentSrc: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: number;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n hspace: number;\n /**\n * Sets or retrieves whether the image is a server-side image map.\n */\n isMap: boolean;\n /**\n * Sets or retrieves a Uniform Resource Identifier (URI) to a long description of the object.\n */\n longDesc: string;\n lowsrc: string;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * The original height of the image resource before sizing.\n */\n readonly naturalHeight: number;\n /**\n * The original width of the image resource before sizing.\n */\n readonly naturalWidth: number;\n sizes: string;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n srcset: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n /**\n * Sets or retrieves the vertical margin for the object.\n */\n vspace: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: number;\n readonly x: number;\n readonly y: number;\n msGetAsCastingSource(): any;\n addEventListener(type: K, listener: (this: HTMLImageElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLImageElement: {\n prototype: HTMLImageElement;\n new(): HTMLImageElement;\n}\n\ninterface HTMLInputElement extends HTMLElement {\n /**\n * Sets or retrieves a comma-separated list of content types.\n */\n accept: string;\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Specifies whether autocomplete is applied to an editable text field.\n */\n autocomplete: string;\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n border: string;\n /**\n * Sets or retrieves the state of the check box or radio button.\n */\n checked: boolean;\n /**\n * Retrieves whether the object is fully loaded.\n */\n readonly complete: boolean;\n /**\n * Sets or retrieves the state of the check box or radio button.\n */\n defaultChecked: boolean;\n /**\n * Sets or retrieves the initial contents of the object.\n */\n defaultValue: string;\n disabled: boolean;\n /**\n * Returns a FileList object on a file type input object.\n */\n readonly files: FileList | null;\n /**\n * Retrieves a reference to the form that the object is embedded in. \n */\n readonly form: HTMLFormElement;\n /**\n * Overrides the action attribute (where the data on a form is sent) on the parent form element.\n */\n formAction: string;\n /**\n * Used to override the encoding (formEnctype attribute) specified on the form element.\n */\n formEnctype: string;\n /**\n * Overrides the submit method attribute previously specified on a form element.\n */\n formMethod: string;\n /**\n * Overrides any validation or required attributes on a form or form elements to allow it to be submitted without validation. This can be used to create a \"save draft\"-type submit option.\n */\n formNoValidate: string;\n /**\n * Overrides the target attribute on a form element.\n */\n formTarget: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n hspace: number;\n indeterminate: boolean;\n /**\n * Specifies the ID of a pre-defined datalist of options for an input element.\n */\n readonly list: HTMLElement;\n /**\n * Defines the maximum acceptable value for an input element with type=\"number\".When used with the min and step attributes, lets you control the range and increment (such as only even numbers) that the user can enter into an input field.\n */\n max: string;\n /**\n * Sets or retrieves the maximum number of characters that the user can enter in a text control.\n */\n maxLength: number;\n /**\n * Defines the minimum acceptable value for an input element with type=\"number\". When used with the max and step attributes, lets you control the range and increment (such as even numbers only) that the user can enter into an input field.\n */\n min: string;\n /**\n * Sets or retrieves the Boolean value indicating whether multiple items can be selected from a list.\n */\n multiple: boolean;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Gets or sets a string containing a regular expression that the user's input must match.\n */\n pattern: string;\n /**\n * Gets or sets a text string that is displayed in an input field as a hint or prompt to users as the format or type of information they need to enter.The text appears in an input field until the user puts focus on the field.\n */\n placeholder: string;\n readOnly: boolean;\n /**\n * When present, marks an element that can't be submitted without a value.\n */\n required: boolean;\n selectionDirection: string;\n /**\n * Gets or sets the end position or offset of a text selection.\n */\n selectionEnd: number;\n /**\n * Gets or sets the starting position or offset of a text selection.\n */\n selectionStart: number;\n size: number;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n status: boolean;\n /**\n * Defines an increment or jump between values that you want to allow the user to enter. When used with the max and min attributes, lets you control the range and increment (for example, allow only even numbers) that the user can enter into an input field.\n */\n step: string;\n /**\n * Returns the content type of the object.\n */\n type: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Returns the value of the data at the cursor's current position.\n */\n value: string;\n valueAsDate: Date;\n /**\n * Returns the input field value as a number.\n */\n valueAsNumber: number;\n /**\n * Sets or retrieves the vertical margin for the object.\n */\n vspace: number;\n webkitdirectory: boolean;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n minLength: number;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Makes the selection equal to the current object.\n */\n select(): void;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n /**\n * Sets the start and end positions of a selection in a text field.\n * @param start The offset into the text field for the start of the selection.\n * @param end The offset into the text field for the end of the selection.\n */\n setSelectionRange(start?: number, end?: number, direction?: string): void;\n /**\n * Decrements a range input control's value by the value given by the Step attribute. If the optional parameter is used, it will decrement the input control's step value multiplied by the parameter's value.\n * @param n Value to decrement the value by.\n */\n stepDown(n?: number): void;\n /**\n * Increments a range input control's value by the value given by the Step attribute. If the optional parameter is used, will increment the input control's value by that value.\n * @param n Value to increment the value by.\n */\n stepUp(n?: number): void;\n addEventListener(type: K, listener: (this: HTMLInputElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLInputElement: {\n prototype: HTMLInputElement;\n new(): HTMLInputElement;\n}\n\ninterface HTMLLIElement extends HTMLElement {\n type: string;\n /**\n * Sets or retrieves the value of a list item.\n */\n value: number;\n addEventListener(type: K, listener: (this: HTMLLIElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLIElement: {\n prototype: HTMLLIElement;\n new(): HTMLLIElement;\n}\n\ninterface HTMLLabelElement extends HTMLElement {\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the object to which the given label object is assigned.\n */\n htmlFor: string;\n addEventListener(type: K, listener: (this: HTMLLabelElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLabelElement: {\n prototype: HTMLLabelElement;\n new(): HTMLLabelElement;\n}\n\ninterface HTMLLegendElement extends HTMLElement {\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n align: string;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n addEventListener(type: K, listener: (this: HTMLLegendElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLegendElement: {\n prototype: HTMLLegendElement;\n new(): HTMLLegendElement;\n}\n\ninterface HTMLLinkElement extends HTMLElement, LinkStyle {\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n disabled: boolean;\n /**\n * Sets or retrieves a destination URL or an anchor point.\n */\n href: string;\n /**\n * Sets or retrieves the language code of the object.\n */\n hreflang: string;\n /**\n * Sets or retrieves the media type.\n */\n media: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rel: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rev: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Sets or retrieves the MIME type of the object.\n */\n type: string;\n import?: Document;\n integrity: string;\n addEventListener(type: K, listener: (this: HTMLLinkElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLinkElement: {\n prototype: HTMLLinkElement;\n new(): HTMLLinkElement;\n}\n\ninterface HTMLMapElement extends HTMLElement {\n /**\n * Retrieves a collection of the area objects defined for the given map object.\n */\n readonly areas: HTMLAreasCollection;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n addEventListener(type: K, listener: (this: HTMLMapElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMapElement: {\n prototype: HTMLMapElement;\n new(): HTMLMapElement;\n}\n\ninterface HTMLMarqueeElementEventMap extends HTMLElementEventMap {\n \"bounce\": Event;\n \"finish\": Event;\n \"start\": Event;\n}\n\ninterface HTMLMarqueeElement extends HTMLElement {\n behavior: string;\n bgColor: any;\n direction: string;\n height: string;\n hspace: number;\n loop: number;\n onbounce: (this: HTMLMarqueeElement, ev: Event) => any;\n onfinish: (this: HTMLMarqueeElement, ev: Event) => any;\n onstart: (this: HTMLMarqueeElement, ev: Event) => any;\n scrollAmount: number;\n scrollDelay: number;\n trueSpeed: boolean;\n vspace: number;\n width: string;\n start(): void;\n stop(): void;\n addEventListener(type: K, listener: (this: HTMLMarqueeElement, ev: HTMLMarqueeElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMarqueeElement: {\n prototype: HTMLMarqueeElement;\n new(): HTMLMarqueeElement;\n}\n\ninterface HTMLMediaElementEventMap extends HTMLElementEventMap {\n \"encrypted\": MediaEncryptedEvent;\n \"msneedkey\": MSMediaKeyNeededEvent;\n}\n\ninterface HTMLMediaElement extends HTMLElement {\n /**\n * Returns an AudioTrackList object with the audio tracks for a given video element.\n */\n readonly audioTracks: AudioTrackList;\n /**\n * Gets or sets a value that indicates whether to start playing the media automatically.\n */\n autoplay: boolean;\n /**\n * Gets a collection of buffered time ranges.\n */\n readonly buffered: TimeRanges;\n /**\n * Gets or sets a flag that indicates whether the client provides a set of controls for the media (in case the developer does not include controls for the player).\n */\n controls: boolean;\n crossOrigin: string | null;\n /**\n * Gets the address or URL of the current media resource that is selected by IHTMLMediaElement.\n */\n readonly currentSrc: string;\n /**\n * Gets or sets the current playback position, in seconds.\n */\n currentTime: number;\n defaultMuted: boolean;\n /**\n * Gets or sets the default playback rate when the user is not using fast forward or reverse for a video or audio resource.\n */\n defaultPlaybackRate: number;\n /**\n * Returns the duration in seconds of the current media resource. A NaN value is returned if duration is not available, or Infinity if the media resource is streaming.\n */\n readonly duration: number;\n /**\n * Gets information about whether the playback has ended or not.\n */\n readonly ended: boolean;\n /**\n * Returns an object representing the current error state of the audio or video element.\n */\n readonly error: MediaError;\n /**\n * Gets or sets a flag to specify whether playback should restart after it completes.\n */\n loop: boolean;\n readonly mediaKeys: MediaKeys | null;\n /**\n * Specifies the purpose of the audio or video media, such as background audio or alerts.\n */\n msAudioCategory: string;\n /**\n * Specifies the output device id that the audio will be sent to.\n */\n msAudioDeviceType: string;\n readonly msGraphicsTrustStatus: MSGraphicsTrust;\n /**\n * Gets the MSMediaKeys object, which is used for decrypting media data, that is associated with this media element.\n */\n readonly msKeys: MSMediaKeys;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n /**\n * Gets or sets the path to the preferred media source. This enables the Play To target device to stream the media content, which can be DRM protected, from a different location, such as a cloud media server.\n */\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Specifies whether or not to enable low-latency playback on the media element.\n */\n msRealTime: boolean;\n /**\n * Gets or sets a flag that indicates whether the audio (either audio or the audio track on video media) is muted.\n */\n muted: boolean;\n /**\n * Gets the current network activity for the element.\n */\n readonly networkState: number;\n onencrypted: (this: HTMLMediaElement, ev: MediaEncryptedEvent) => any;\n onmsneedkey: (this: HTMLMediaElement, ev: MSMediaKeyNeededEvent) => any;\n /**\n * Gets a flag that specifies whether playback is paused.\n */\n readonly paused: boolean;\n /**\n * Gets or sets the current rate of speed for the media resource to play. This speed is expressed as a multiple of the normal speed of the media resource.\n */\n playbackRate: number;\n /**\n * Gets TimeRanges for the current media resource that has been played.\n */\n readonly played: TimeRanges;\n /**\n * Gets or sets the current playback position, in seconds.\n */\n preload: string;\n readyState: number;\n /**\n * Returns a TimeRanges object that represents the ranges of the current media resource that can be seeked.\n */\n readonly seekable: TimeRanges;\n /**\n * Gets a flag that indicates whether the the client is currently moving to a new playback position in the media resource.\n */\n readonly seeking: boolean;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n srcObject: MediaStream | null;\n readonly textTracks: TextTrackList;\n readonly videoTracks: VideoTrackList;\n /**\n * Gets or sets the volume level for audio portions of the media element.\n */\n volume: number;\n addTextTrack(kind: string, label?: string, language?: string): TextTrack;\n /**\n * Returns a string that specifies whether the client can play a given media resource type.\n */\n canPlayType(type: string): string;\n /**\n * Resets the audio or video object and loads a new media resource.\n */\n load(): void;\n /**\n * Clears all effects from the media pipeline.\n */\n msClearEffects(): void;\n msGetAsCastingSource(): any;\n /**\n * Inserts the specified audio effect into media pipeline.\n */\n msInsertAudioEffect(activatableClassId: string, effectRequired: boolean, config?: any): void;\n msSetMediaKeys(mediaKeys: MSMediaKeys): void;\n /**\n * Specifies the media protection manager for a given media pipeline.\n */\n msSetMediaProtectionManager(mediaProtectionManager?: any): void;\n /**\n * Pauses the current playback and sets paused to TRUE. This can be used to test whether the media is playing or paused. You can also use the pause or play events to tell whether the media is playing or not.\n */\n pause(): void;\n /**\n * Loads and starts playback of a media resource.\n */\n play(): void;\n setMediaKeys(mediaKeys: MediaKeys | null): Promise;\n readonly HAVE_CURRENT_DATA: number;\n readonly HAVE_ENOUGH_DATA: number;\n readonly HAVE_FUTURE_DATA: number;\n readonly HAVE_METADATA: number;\n readonly HAVE_NOTHING: number;\n readonly NETWORK_EMPTY: number;\n readonly NETWORK_IDLE: number;\n readonly NETWORK_LOADING: number;\n readonly NETWORK_NO_SOURCE: number;\n addEventListener(type: K, listener: (this: HTMLMediaElement, ev: HTMLMediaElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMediaElement: {\n prototype: HTMLMediaElement;\n new(): HTMLMediaElement;\n readonly HAVE_CURRENT_DATA: number;\n readonly HAVE_ENOUGH_DATA: number;\n readonly HAVE_FUTURE_DATA: number;\n readonly HAVE_METADATA: number;\n readonly HAVE_NOTHING: number;\n readonly NETWORK_EMPTY: number;\n readonly NETWORK_IDLE: number;\n readonly NETWORK_LOADING: number;\n readonly NETWORK_NO_SOURCE: number;\n}\n\ninterface HTMLMenuElement extends HTMLElement {\n compact: boolean;\n type: string;\n addEventListener(type: K, listener: (this: HTMLMenuElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMenuElement: {\n prototype: HTMLMenuElement;\n new(): HTMLMenuElement;\n}\n\ninterface HTMLMetaElement extends HTMLElement {\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n /**\n * Gets or sets meta-information to associate with httpEquiv or name.\n */\n content: string;\n /**\n * Gets or sets information used to bind the value of a content attribute of a meta element to an HTTP response header.\n */\n httpEquiv: string;\n /**\n * Sets or retrieves the value specified in the content attribute of the meta object.\n */\n name: string;\n /**\n * Sets or retrieves a scheme to be used in interpreting the value of a property specified for the object.\n */\n scheme: string;\n /**\n * Sets or retrieves the URL property that will be loaded after the specified time has elapsed. \n */\n url: string;\n addEventListener(type: K, listener: (this: HTMLMetaElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMetaElement: {\n prototype: HTMLMetaElement;\n new(): HTMLMetaElement;\n}\n\ninterface HTMLMeterElement extends HTMLElement {\n high: number;\n low: number;\n max: number;\n min: number;\n optimum: number;\n value: number;\n addEventListener(type: K, listener: (this: HTMLMeterElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMeterElement: {\n prototype: HTMLMeterElement;\n new(): HTMLMeterElement;\n}\n\ninterface HTMLModElement extends HTMLElement {\n /**\n * Sets or retrieves reference information about the object.\n */\n cite: string;\n /**\n * Sets or retrieves the date and time of a modification to the object.\n */\n dateTime: string;\n addEventListener(type: K, listener: (this: HTMLModElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLModElement: {\n prototype: HTMLModElement;\n new(): HTMLModElement;\n}\n\ninterface HTMLOListElement extends HTMLElement {\n compact: boolean;\n /**\n * The starting number.\n */\n start: number;\n type: string;\n addEventListener(type: K, listener: (this: HTMLOListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOListElement: {\n prototype: HTMLOListElement;\n new(): HTMLOListElement;\n}\n\ninterface HTMLObjectElement extends HTMLElement, GetSVGDocument {\n /**\n * Retrieves a string of the URL where the object tag can be found. This is often the href of the document that the object is in, or the value set by a base element.\n */\n readonly BaseHref: string;\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Gets or sets the optional alternative HTML script to execute if the object fails to load.\n */\n altHtml: string;\n /**\n * Sets or retrieves a character string that can be used to implement your own archive functionality for the object.\n */\n archive: string;\n border: string;\n /**\n * Sets or retrieves the URL of the file containing the compiled Java class.\n */\n code: string;\n /**\n * Sets or retrieves the URL of the component.\n */\n codeBase: string;\n /**\n * Sets or retrieves the Internet media type for the code associated with the object.\n */\n codeType: string;\n /**\n * Retrieves the document object of the page or frame.\n */\n readonly contentDocument: Document;\n /**\n * Sets or retrieves the URL that references the data of the object.\n */\n data: string;\n declare: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n hspace: number;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n /**\n * Gets or sets the path to the preferred media source. This enables the Play To target device to stream the media content, which can be DRM protected, from a different location, such as a cloud media server.\n */\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n readonly readyState: number;\n /**\n * Sets or retrieves a message to be displayed while an object is loading.\n */\n standby: string;\n /**\n * Sets or retrieves the MIME type of the object.\n */\n type: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n vspace: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLObjectElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLObjectElement: {\n prototype: HTMLObjectElement;\n new(): HTMLObjectElement;\n}\n\ninterface HTMLOptGroupElement extends HTMLElement {\n /**\n * Sets or retrieves the status of an option.\n */\n defaultSelected: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the ordinal position of an option in a list box.\n */\n readonly index: number;\n /**\n * Sets or retrieves a value that you can use to implement your own label functionality for the object.\n */\n label: string;\n /**\n * Sets or retrieves whether the option in the list box is the default item.\n */\n selected: boolean;\n /**\n * Sets or retrieves the text string specified by the option tag.\n */\n readonly text: string;\n /**\n * Sets or retrieves the value which is returned to the server when the form control is submitted.\n */\n value: string;\n addEventListener(type: K, listener: (this: HTMLOptGroupElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOptGroupElement: {\n prototype: HTMLOptGroupElement;\n new(): HTMLOptGroupElement;\n}\n\ninterface HTMLOptionElement extends HTMLElement {\n /**\n * Sets or retrieves the status of an option.\n */\n defaultSelected: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the ordinal position of an option in a list box.\n */\n readonly index: number;\n /**\n * Sets or retrieves a value that you can use to implement your own label functionality for the object.\n */\n label: string;\n /**\n * Sets or retrieves whether the option in the list box is the default item.\n */\n selected: boolean;\n /**\n * Sets or retrieves the text string specified by the option tag.\n */\n text: string;\n /**\n * Sets or retrieves the value which is returned to the server when the form control is submitted.\n */\n value: string;\n addEventListener(type: K, listener: (this: HTMLOptionElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOptionElement: {\n prototype: HTMLOptionElement;\n new(): HTMLOptionElement;\n}\n\ninterface HTMLOptionsCollection extends HTMLCollectionOf {\n length: number;\n selectedIndex: number;\n add(element: HTMLOptionElement | HTMLOptGroupElement, before?: HTMLElement | number): void;\n remove(index: number): void;\n}\n\ndeclare var HTMLOptionsCollection: {\n prototype: HTMLOptionsCollection;\n new(): HTMLOptionsCollection;\n}\n\ninterface HTMLOutputElement extends HTMLElement {\n defaultValue: string;\n readonly form: HTMLFormElement;\n readonly htmlFor: DOMSettableTokenList;\n name: string;\n readonly type: string;\n readonly validationMessage: string;\n readonly validity: ValidityState;\n value: string;\n readonly willValidate: boolean;\n checkValidity(): boolean;\n reportValidity(): boolean;\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLOutputElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOutputElement: {\n prototype: HTMLOutputElement;\n new(): HTMLOutputElement;\n}\n\ninterface HTMLParagraphElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text. \n */\n align: string;\n clear: string;\n addEventListener(type: K, listener: (this: HTMLParagraphElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLParagraphElement: {\n prototype: HTMLParagraphElement;\n new(): HTMLParagraphElement;\n}\n\ninterface HTMLParamElement extends HTMLElement {\n /**\n * Sets or retrieves the name of an input parameter for an element.\n */\n name: string;\n /**\n * Sets or retrieves the content type of the resource designated by the value attribute.\n */\n type: string;\n /**\n * Sets or retrieves the value of an input parameter for an element.\n */\n value: string;\n /**\n * Sets or retrieves the data type of the value attribute.\n */\n valueType: string;\n addEventListener(type: K, listener: (this: HTMLParamElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLParamElement: {\n prototype: HTMLParamElement;\n new(): HTMLParamElement;\n}\n\ninterface HTMLPictureElement extends HTMLElement {\n addEventListener(type: K, listener: (this: HTMLPictureElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLPictureElement: {\n prototype: HTMLPictureElement;\n new(): HTMLPictureElement;\n}\n\ninterface HTMLPreElement extends HTMLElement {\n /**\n * Sets or gets a value that you can use to implement your own width functionality for the object.\n */\n width: number;\n addEventListener(type: K, listener: (this: HTMLPreElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLPreElement: {\n prototype: HTMLPreElement;\n new(): HTMLPreElement;\n}\n\ninterface HTMLProgressElement extends HTMLElement {\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Defines the maximum, or \"done\" value for a progress element.\n */\n max: number;\n /**\n * Returns the quotient of value/max when the value attribute is set (determinate progress bar), or -1 when the value attribute is missing (indeterminate progress bar).\n */\n readonly position: number;\n /**\n * Sets or gets the current value of a progress element. The value must be a non-negative number between 0 and the max value.\n */\n value: number;\n addEventListener(type: K, listener: (this: HTMLProgressElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLProgressElement: {\n prototype: HTMLProgressElement;\n new(): HTMLProgressElement;\n}\n\ninterface HTMLQuoteElement extends HTMLElement {\n /**\n * Sets or retrieves reference information about the object.\n */\n cite: string;\n addEventListener(type: K, listener: (this: HTMLQuoteElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLQuoteElement: {\n prototype: HTMLQuoteElement;\n new(): HTMLQuoteElement;\n}\n\ninterface HTMLScriptElement extends HTMLElement {\n async: boolean;\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n crossOrigin: string | null;\n /**\n * Sets or retrieves the status of the script.\n */\n defer: boolean;\n /**\n * Sets or retrieves the event for which the script is written. \n */\n event: string;\n /** \n * Sets or retrieves the object that is bound to the event script.\n */\n htmlFor: string;\n /**\n * Retrieves the URL to an external file that contains the source code or data.\n */\n src: string;\n /**\n * Retrieves or sets the text of the object as a string. \n */\n text: string;\n /**\n * Sets or retrieves the MIME type for the associated scripting engine.\n */\n type: string;\n integrity: string;\n addEventListener(type: K, listener: (this: HTMLScriptElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLScriptElement: {\n prototype: HTMLScriptElement;\n new(): HTMLScriptElement;\n}\n\ninterface HTMLSelectElement extends HTMLElement {\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in. \n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the number of objects in a collection.\n */\n length: number;\n /**\n * Sets or retrieves the Boolean value indicating whether multiple items can be selected from a list.\n */\n multiple: boolean;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n readonly options: HTMLOptionsCollection;\n /**\n * When present, marks an element that can't be submitted without a value.\n */\n required: boolean;\n /**\n * Sets or retrieves the index of the selected option in a select object.\n */\n selectedIndex: number;\n selectedOptions: HTMLCollectionOf;\n /**\n * Sets or retrieves the number of rows in the list box. \n */\n size: number;\n /**\n * Retrieves the type of select control based on the value of the MULTIPLE attribute.\n */\n readonly type: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Sets or retrieves the value which is returned to the server when the form control is submitted.\n */\n value: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Adds an element to the areas, controlRange, or options collection.\n * @param element Variant of type Number that specifies the index position in the collection where the element is placed. If no value is given, the method places the element at the end of the collection.\n * @param before Variant of type Object that specifies an element to insert before, or null to append the object to the collection. \n */\n add(element: HTMLElement, before?: HTMLElement | number): void;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Retrieves a select object or an object from an options collection.\n * @param name Variant of type Number or String that specifies the object or collection to retrieve. If this parameter is an integer, it is the zero-based index of the object. If this parameter is a string, all objects with matching name or id properties are retrieved, and a collection is returned if more than one match is made.\n * @param index Variant of type Number that specifies the zero-based index of the object to retrieve when a collection is returned.\n */\n item(name?: any, index?: any): any;\n /**\n * Retrieves a select object or an object from an options collection.\n * @param namedItem A String that specifies the name or id property of the object to retrieve. A collection is returned if more than one match is made.\n */\n namedItem(name: string): any;\n /**\n * Removes an element from the collection.\n * @param index Number that specifies the zero-based index of the element to remove from the collection.\n */\n remove(index?: number): void;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLSelectElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [name: string]: any;\n}\n\ndeclare var HTMLSelectElement: {\n prototype: HTMLSelectElement;\n new(): HTMLSelectElement;\n}\n\ninterface HTMLSourceElement extends HTMLElement {\n /**\n * Gets or sets the intended media type of the media source.\n */\n media: string;\n msKeySystem: string;\n sizes: string;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n srcset: string;\n /**\n * Gets or sets the MIME type of a media resource.\n */\n type: string;\n addEventListener(type: K, listener: (this: HTMLSourceElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLSourceElement: {\n prototype: HTMLSourceElement;\n new(): HTMLSourceElement;\n}\n\ninterface HTMLSpanElement extends HTMLElement {\n addEventListener(type: K, listener: (this: HTMLSpanElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLSpanElement: {\n prototype: HTMLSpanElement;\n new(): HTMLSpanElement;\n}\n\ninterface HTMLStyleElement extends HTMLElement, LinkStyle {\n disabled: boolean;\n /**\n * Sets or retrieves the media type.\n */\n media: string;\n /**\n * Retrieves the CSS language in which the style sheet is written.\n */\n type: string;\n addEventListener(type: K, listener: (this: HTMLStyleElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLStyleElement: {\n prototype: HTMLStyleElement;\n new(): HTMLStyleElement;\n}\n\ninterface HTMLTableCaptionElement extends HTMLElement {\n /**\n * Sets or retrieves the alignment of the caption or legend.\n */\n align: string;\n /**\n * Sets or retrieves whether the caption appears at the top or bottom of the table.\n */\n vAlign: string;\n addEventListener(type: K, listener: (this: HTMLTableCaptionElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableCaptionElement: {\n prototype: HTMLTableCaptionElement;\n new(): HTMLTableCaptionElement;\n}\n\ninterface HTMLTableCellElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves abbreviated text for the object.\n */\n abbr: string;\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves a comma-delimited list of conceptual categories associated with the object.\n */\n axis: string;\n bgColor: any;\n /**\n * Retrieves the position of the object in the cells collection of a row.\n */\n readonly cellIndex: number;\n /**\n * Sets or retrieves the number columns in the table that the object should span.\n */\n colSpan: number;\n /**\n * Sets or retrieves a list of header cells that provide information for the object.\n */\n headers: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: any;\n /**\n * Sets or retrieves whether the browser automatically performs wordwrap.\n */\n noWrap: boolean;\n /**\n * Sets or retrieves how many rows in a table the cell should span.\n */\n rowSpan: number;\n /**\n * Sets or retrieves the group of cells in a table to which the object's information applies.\n */\n scope: string;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n addEventListener(type: K, listener: (this: HTMLTableCellElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableCellElement: {\n prototype: HTMLTableCellElement;\n new(): HTMLTableCellElement;\n}\n\ninterface HTMLTableColElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves the alignment of the object relative to the display or table.\n */\n align: string;\n /**\n * Sets or retrieves the number of columns in the group.\n */\n span: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: any;\n addEventListener(type: K, listener: (this: HTMLTableColElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableColElement: {\n prototype: HTMLTableColElement;\n new(): HTMLTableColElement;\n}\n\ninterface HTMLTableDataCellElement extends HTMLTableCellElement {\n addEventListener(type: K, listener: (this: HTMLTableDataCellElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableDataCellElement: {\n prototype: HTMLTableDataCellElement;\n new(): HTMLTableDataCellElement;\n}\n\ninterface HTMLTableElement extends HTMLElement {\n /**\n * Sets or retrieves a value that indicates the table alignment.\n */\n align: string;\n bgColor: any;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n border: string;\n /**\n * Sets or retrieves the border color of the object. \n */\n borderColor: any;\n /**\n * Retrieves the caption object of a table.\n */\n caption: HTMLTableCaptionElement;\n /**\n * Sets or retrieves the amount of space between the border of the cell and the content of the cell.\n */\n cellPadding: string;\n /**\n * Sets or retrieves the amount of space between cells in a table.\n */\n cellSpacing: string;\n /**\n * Sets or retrieves the number of columns in the table.\n */\n cols: number;\n /**\n * Sets or retrieves the way the border frame around the table is displayed.\n */\n frame: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: any;\n /**\n * Sets or retrieves the number of horizontal rows contained in the object.\n */\n rows: HTMLCollectionOf;\n /**\n * Sets or retrieves which dividing lines (inner borders) are displayed.\n */\n rules: string;\n /**\n * Sets or retrieves a description and/or structure of the object.\n */\n summary: string;\n /**\n * Retrieves a collection of all tBody objects in the table. Objects in this collection are in source order.\n */\n tBodies: HTMLCollectionOf;\n /**\n * Retrieves the tFoot object of the table.\n */\n tFoot: HTMLTableSectionElement;\n /**\n * Retrieves the tHead object of the table.\n */\n tHead: HTMLTableSectionElement;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n /**\n * Creates an empty caption element in the table.\n */\n createCaption(): HTMLTableCaptionElement;\n /**\n * Creates an empty tBody element in the table.\n */\n createTBody(): HTMLTableSectionElement;\n /**\n * Creates an empty tFoot element in the table.\n */\n createTFoot(): HTMLTableSectionElement;\n /**\n * Returns the tHead element object if successful, or null otherwise.\n */\n createTHead(): HTMLTableSectionElement;\n /**\n * Deletes the caption element and its contents from the table.\n */\n deleteCaption(): void;\n /**\n * Removes the specified row (tr) from the element and from the rows collection.\n * @param index Number that specifies the zero-based position in the rows collection of the row to remove.\n */\n deleteRow(index?: number): void;\n /**\n * Deletes the tFoot element and its contents from the table.\n */\n deleteTFoot(): void;\n /**\n * Deletes the tHead element and its contents from the table.\n */\n deleteTHead(): void;\n /**\n * Creates a new row (tr) in the table, and adds the row to the rows collection.\n * @param index Number that specifies where to insert the row in the rows collection. The default value is -1, which appends the new row to the end of the rows collection.\n */\n insertRow(index?: number): HTMLTableRowElement;\n addEventListener(type: K, listener: (this: HTMLTableElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableElement: {\n prototype: HTMLTableElement;\n new(): HTMLTableElement;\n}\n\ninterface HTMLTableHeaderCellElement extends HTMLTableCellElement {\n /**\n * Sets or retrieves the group of cells in a table to which the object's information applies.\n */\n scope: string;\n addEventListener(type: K, listener: (this: HTMLTableHeaderCellElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableHeaderCellElement: {\n prototype: HTMLTableHeaderCellElement;\n new(): HTMLTableHeaderCellElement;\n}\n\ninterface HTMLTableRowElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n bgColor: any;\n /**\n * Retrieves a collection of all cells in the table row.\n */\n cells: HTMLCollectionOf;\n /**\n * Sets or retrieves the height of the object.\n */\n height: any;\n /**\n * Retrieves the position of the object in the rows collection for the table.\n */\n readonly rowIndex: number;\n /**\n * Retrieves the position of the object in the collection.\n */\n readonly sectionRowIndex: number;\n /**\n * Removes the specified cell from the table row, as well as from the cells collection.\n * @param index Number that specifies the zero-based position of the cell to remove from the table row. If no value is provided, the last cell in the cells collection is deleted.\n */\n deleteCell(index?: number): void;\n /**\n * Creates a new cell in the table row, and adds the cell to the cells collection.\n * @param index Number that specifies where to insert the cell in the tr. The default value is -1, which appends the new cell to the end of the cells collection.\n */\n insertCell(index?: number): HTMLTableDataCellElement;\n addEventListener(type: K, listener: (this: HTMLTableRowElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableRowElement: {\n prototype: HTMLTableRowElement;\n new(): HTMLTableRowElement;\n}\n\ninterface HTMLTableSectionElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves a value that indicates the table alignment.\n */\n align: string;\n /**\n * Sets or retrieves the number of horizontal rows contained in the object.\n */\n rows: HTMLCollectionOf;\n /**\n * Removes the specified row (tr) from the element and from the rows collection.\n * @param index Number that specifies the zero-based position in the rows collection of the row to remove.\n */\n deleteRow(index?: number): void;\n /**\n * Creates a new row (tr) in the table, and adds the row to the rows collection.\n * @param index Number that specifies where to insert the row in the rows collection. The default value is -1, which appends the new row to the end of the rows collection.\n */\n insertRow(index?: number): HTMLTableRowElement;\n addEventListener(type: K, listener: (this: HTMLTableSectionElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableSectionElement: {\n prototype: HTMLTableSectionElement;\n new(): HTMLTableSectionElement;\n}\n\ninterface HTMLTemplateElement extends HTMLElement {\n readonly content: DocumentFragment;\n addEventListener(type: K, listener: (this: HTMLTemplateElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTemplateElement: {\n prototype: HTMLTemplateElement;\n new(): HTMLTemplateElement;\n}\n\ninterface HTMLTextAreaElement extends HTMLElement {\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n /**\n * Sets or retrieves the width of the object.\n */\n cols: number;\n /**\n * Sets or retrieves the initial contents of the object.\n */\n defaultValue: string;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the maximum number of characters that the user can enter in a text control.\n */\n maxLength: number;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Gets or sets a text string that is displayed in an input field as a hint or prompt to users as the format or type of information they need to enter.The text appears in an input field until the user puts focus on the field.\n */\n placeholder: string;\n /**\n * Sets or retrieves the value indicated whether the content of the object is read-only.\n */\n readOnly: boolean;\n /**\n * When present, marks an element that can't be submitted without a value.\n */\n required: boolean;\n /**\n * Sets or retrieves the number of horizontal rows contained in the object.\n */\n rows: number;\n /**\n * Gets or sets the end position or offset of a text selection.\n */\n selectionEnd: number;\n /**\n * Gets or sets the starting position or offset of a text selection.\n */\n selectionStart: number;\n /**\n * Sets or retrieves the value indicating whether the control is selected.\n */\n status: any;\n /**\n * Retrieves the type of control.\n */\n readonly type: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Retrieves or sets the text in the entry field of the textArea element.\n */\n value: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Sets or retrieves how to handle wordwrapping in the object.\n */\n wrap: string;\n minLength: number;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Highlights the input area of a form element.\n */\n select(): void;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n /**\n * Sets the start and end positions of a selection in a text field.\n * @param start The offset into the text field for the start of the selection.\n * @param end The offset into the text field for the end of the selection.\n */\n setSelectionRange(start: number, end: number): void;\n addEventListener(type: K, listener: (this: HTMLTextAreaElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTextAreaElement: {\n prototype: HTMLTextAreaElement;\n new(): HTMLTextAreaElement;\n}\n\ninterface HTMLTimeElement extends HTMLElement {\n dateTime: string;\n addEventListener(type: K, listener: (this: HTMLTimeElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTimeElement: {\n prototype: HTMLTimeElement;\n new(): HTMLTimeElement;\n}\n\ninterface HTMLTitleElement extends HTMLElement {\n /**\n * Retrieves or sets the text of the object as a string. \n */\n text: string;\n addEventListener(type: K, listener: (this: HTMLTitleElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTitleElement: {\n prototype: HTMLTitleElement;\n new(): HTMLTitleElement;\n}\n\ninterface HTMLTrackElement extends HTMLElement {\n default: boolean;\n kind: string;\n label: string;\n readonly readyState: number;\n src: string;\n srclang: string;\n readonly track: TextTrack;\n readonly ERROR: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n addEventListener(type: K, listener: (this: HTMLTrackElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTrackElement: {\n prototype: HTMLTrackElement;\n new(): HTMLTrackElement;\n readonly ERROR: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n}\n\ninterface HTMLUListElement extends HTMLElement {\n compact: boolean;\n type: string;\n addEventListener(type: K, listener: (this: HTMLUListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLUListElement: {\n prototype: HTMLUListElement;\n new(): HTMLUListElement;\n}\n\ninterface HTMLUnknownElement extends HTMLElement {\n addEventListener(type: K, listener: (this: HTMLUnknownElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLUnknownElement: {\n prototype: HTMLUnknownElement;\n new(): HTMLUnknownElement;\n}\n\ninterface HTMLVideoElementEventMap extends HTMLMediaElementEventMap {\n \"MSVideoFormatChanged\": Event;\n \"MSVideoFrameStepCompleted\": Event;\n \"MSVideoOptimalLayoutChanged\": Event;\n}\n\ninterface HTMLVideoElement extends HTMLMediaElement {\n /**\n * Gets or sets the height of the video element.\n */\n height: number;\n msHorizontalMirror: boolean;\n readonly msIsLayoutOptimalForPlayback: boolean;\n readonly msIsStereo3D: boolean;\n msStereo3DPackingMode: string;\n msStereo3DRenderMode: string;\n msZoom: boolean;\n onMSVideoFormatChanged: (this: HTMLVideoElement, ev: Event) => any;\n onMSVideoFrameStepCompleted: (this: HTMLVideoElement, ev: Event) => any;\n onMSVideoOptimalLayoutChanged: (this: HTMLVideoElement, ev: Event) => any;\n /**\n * Gets or sets a URL of an image to display, for example, like a movie poster. This can be a still frame from the video, or another image if no video data is available.\n */\n poster: string;\n /**\n * Gets the intrinsic height of a video in CSS pixels, or zero if the dimensions are not known.\n */\n readonly videoHeight: number;\n /**\n * Gets the intrinsic width of a video in CSS pixels, or zero if the dimensions are not known.\n */\n readonly videoWidth: number;\n readonly webkitDisplayingFullscreen: boolean;\n readonly webkitSupportsFullscreen: boolean;\n /**\n * Gets or sets the width of the video element.\n */\n width: number;\n getVideoPlaybackQuality(): VideoPlaybackQuality;\n msFrameStep(forward: boolean): void;\n msInsertVideoEffect(activatableClassId: string, effectRequired: boolean, config?: any): void;\n msSetVideoRectangle(left: number, top: number, right: number, bottom: number): void;\n webkitEnterFullScreen(): void;\n webkitEnterFullscreen(): void;\n webkitExitFullScreen(): void;\n webkitExitFullscreen(): void;\n addEventListener(type: K, listener: (this: HTMLVideoElement, ev: HTMLVideoElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLVideoElement: {\n prototype: HTMLVideoElement;\n new(): HTMLVideoElement;\n}\n\ninterface HashChangeEvent extends Event {\n readonly newURL: string | null;\n readonly oldURL: string | null;\n}\n\ndeclare var HashChangeEvent: {\n prototype: HashChangeEvent;\n new(typeArg: string, eventInitDict?: HashChangeEventInit): HashChangeEvent;\n}\n\ninterface Headers {\n append(name: string, value: string): void;\n delete(name: string): void;\n forEach(callback: ForEachCallback): void;\n get(name: string): string | null;\n has(name: string): boolean;\n set(name: string, value: string): void;\n}\n\ndeclare var Headers: {\n prototype: Headers;\n new(init?: any): Headers;\n}\n\ninterface History {\n readonly length: number;\n readonly state: any;\n scrollRestoration: ScrollRestoration;\n back(): void;\n forward(): void;\n go(delta?: number): void;\n pushState(data: any, title: string, url?: string | null): void;\n replaceState(data: any, title: string, url?: string | null): void;\n}\n\ndeclare var History: {\n prototype: History;\n new(): History;\n}\n\ninterface IDBCursor {\n readonly direction: IDBCursorDirection;\n key: IDBKeyRange | IDBValidKey;\n readonly primaryKey: any;\n source: IDBObjectStore | IDBIndex;\n advance(count: number): void;\n continue(key?: IDBKeyRange | IDBValidKey): void;\n delete(): IDBRequest;\n update(value: any): IDBRequest;\n readonly NEXT: string;\n readonly NEXT_NO_DUPLICATE: string;\n readonly PREV: string;\n readonly PREV_NO_DUPLICATE: string;\n}\n\ndeclare var IDBCursor: {\n prototype: IDBCursor;\n new(): IDBCursor;\n readonly NEXT: string;\n readonly NEXT_NO_DUPLICATE: string;\n readonly PREV: string;\n readonly PREV_NO_DUPLICATE: string;\n}\n\ninterface IDBCursorWithValue extends IDBCursor {\n readonly value: any;\n}\n\ndeclare var IDBCursorWithValue: {\n prototype: IDBCursorWithValue;\n new(): IDBCursorWithValue;\n}\n\ninterface IDBDatabaseEventMap {\n \"abort\": Event;\n \"error\": Event;\n}\n\ninterface IDBDatabase extends EventTarget {\n readonly name: string;\n readonly objectStoreNames: DOMStringList;\n onabort: (this: IDBDatabase, ev: Event) => any;\n onerror: (this: IDBDatabase, ev: Event) => any;\n version: number;\n onversionchange: (ev: IDBVersionChangeEvent) => any;\n close(): void;\n createObjectStore(name: string, optionalParameters?: IDBObjectStoreParameters): IDBObjectStore;\n deleteObjectStore(name: string): void;\n transaction(storeNames: string | string[], mode?: string): IDBTransaction;\n addEventListener(type: \"versionchange\", listener: (ev: IDBVersionChangeEvent) => any, useCapture?: boolean): void;\n addEventListener(type: K, listener: (this: IDBDatabase, ev: IDBDatabaseEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBDatabase: {\n prototype: IDBDatabase;\n new(): IDBDatabase;\n}\n\ninterface IDBFactory {\n cmp(first: any, second: any): number;\n deleteDatabase(name: string): IDBOpenDBRequest;\n open(name: string, version?: number): IDBOpenDBRequest;\n}\n\ndeclare var IDBFactory: {\n prototype: IDBFactory;\n new(): IDBFactory;\n}\n\ninterface IDBIndex {\n keyPath: string | string[];\n readonly name: string;\n readonly objectStore: IDBObjectStore;\n readonly unique: boolean;\n multiEntry: boolean;\n count(key?: IDBKeyRange | IDBValidKey): IDBRequest;\n get(key: IDBKeyRange | IDBValidKey): IDBRequest;\n getKey(key: IDBKeyRange | IDBValidKey): IDBRequest;\n openCursor(range?: IDBKeyRange | IDBValidKey, direction?: string): IDBRequest;\n openKeyCursor(range?: IDBKeyRange | IDBValidKey, direction?: string): IDBRequest;\n}\n\ndeclare var IDBIndex: {\n prototype: IDBIndex;\n new(): IDBIndex;\n}\n\ninterface IDBKeyRange {\n readonly lower: any;\n readonly lowerOpen: boolean;\n readonly upper: any;\n readonly upperOpen: boolean;\n}\n\ndeclare var IDBKeyRange: {\n prototype: IDBKeyRange;\n new(): IDBKeyRange;\n bound(lower: any, upper: any, lowerOpen?: boolean, upperOpen?: boolean): IDBKeyRange;\n lowerBound(lower: any, open?: boolean): IDBKeyRange;\n only(value: any): IDBKeyRange;\n upperBound(upper: any, open?: boolean): IDBKeyRange;\n}\n\ninterface IDBObjectStore {\n readonly indexNames: DOMStringList;\n keyPath: string | string[];\n readonly name: string;\n readonly transaction: IDBTransaction;\n autoIncrement: boolean;\n add(value: any, key?: IDBKeyRange | IDBValidKey): IDBRequest;\n clear(): IDBRequest;\n count(key?: IDBKeyRange | IDBValidKey): IDBRequest;\n createIndex(name: string, keyPath: string | string[], optionalParameters?: IDBIndexParameters): IDBIndex;\n delete(key: IDBKeyRange | IDBValidKey): IDBRequest;\n deleteIndex(indexName: string): void;\n get(key: any): IDBRequest;\n index(name: string): IDBIndex;\n openCursor(range?: IDBKeyRange | IDBValidKey, direction?: string): IDBRequest;\n put(value: any, key?: IDBKeyRange | IDBValidKey): IDBRequest;\n}\n\ndeclare var IDBObjectStore: {\n prototype: IDBObjectStore;\n new(): IDBObjectStore;\n}\n\ninterface IDBOpenDBRequestEventMap extends IDBRequestEventMap {\n \"blocked\": Event;\n \"upgradeneeded\": IDBVersionChangeEvent;\n}\n\ninterface IDBOpenDBRequest extends IDBRequest {\n onblocked: (this: IDBOpenDBRequest, ev: Event) => any;\n onupgradeneeded: (this: IDBOpenDBRequest, ev: IDBVersionChangeEvent) => any;\n addEventListener(type: K, listener: (this: IDBOpenDBRequest, ev: IDBOpenDBRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBOpenDBRequest: {\n prototype: IDBOpenDBRequest;\n new(): IDBOpenDBRequest;\n}\n\ninterface IDBRequestEventMap {\n \"error\": Event;\n \"success\": Event;\n}\n\ninterface IDBRequest extends EventTarget {\n readonly error: DOMError;\n onerror: (this: IDBRequest, ev: Event) => any;\n onsuccess: (this: IDBRequest, ev: Event) => any;\n readonly readyState: IDBRequestReadyState;\n readonly result: any;\n source: IDBObjectStore | IDBIndex | IDBCursor;\n readonly transaction: IDBTransaction;\n addEventListener(type: K, listener: (this: IDBRequest, ev: IDBRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBRequest: {\n prototype: IDBRequest;\n new(): IDBRequest;\n}\n\ninterface IDBTransactionEventMap {\n \"abort\": Event;\n \"complete\": Event;\n \"error\": Event;\n}\n\ninterface IDBTransaction extends EventTarget {\n readonly db: IDBDatabase;\n readonly error: DOMError;\n readonly mode: IDBTransactionMode;\n onabort: (this: IDBTransaction, ev: Event) => any;\n oncomplete: (this: IDBTransaction, ev: Event) => any;\n onerror: (this: IDBTransaction, ev: Event) => any;\n abort(): void;\n objectStore(name: string): IDBObjectStore;\n readonly READ_ONLY: string;\n readonly READ_WRITE: string;\n readonly VERSION_CHANGE: string;\n addEventListener(type: K, listener: (this: IDBTransaction, ev: IDBTransactionEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBTransaction: {\n prototype: IDBTransaction;\n new(): IDBTransaction;\n readonly READ_ONLY: string;\n readonly READ_WRITE: string;\n readonly VERSION_CHANGE: string;\n}\n\ninterface IDBVersionChangeEvent extends Event {\n readonly newVersion: number | null;\n readonly oldVersion: number;\n}\n\ndeclare var IDBVersionChangeEvent: {\n prototype: IDBVersionChangeEvent;\n new(): IDBVersionChangeEvent;\n}\n\ninterface IIRFilterNode extends AudioNode {\n getFrequencyResponse(frequencyHz: Float32Array, magResponse: Float32Array, phaseResponse: Float32Array): void;\n}\n\ndeclare var IIRFilterNode: {\n prototype: IIRFilterNode;\n new(): IIRFilterNode;\n}\n\ninterface ImageData {\n data: Uint8ClampedArray;\n readonly height: number;\n readonly width: number;\n}\n\ndeclare var ImageData: {\n prototype: ImageData;\n new(width: number, height: number): ImageData;\n new(array: Uint8ClampedArray, width: number, height: number): ImageData;\n}\n\ninterface IntersectionObserver {\n readonly root: Element | null;\n readonly rootMargin: string;\n readonly thresholds: number[];\n disconnect(): void;\n observe(target: Element): void;\n takeRecords(): IntersectionObserverEntry[];\n unobserve(target: Element): void;\n}\n\ndeclare var IntersectionObserver: {\n prototype: IntersectionObserver;\n new(callback: IntersectionObserverCallback, options?: IntersectionObserverInit): IntersectionObserver;\n}\n\ninterface IntersectionObserverEntry {\n readonly boundingClientRect: ClientRect;\n readonly intersectionRatio: number;\n readonly intersectionRect: ClientRect;\n readonly rootBounds: ClientRect;\n readonly target: Element;\n readonly time: number;\n}\n\ndeclare var IntersectionObserverEntry: {\n prototype: IntersectionObserverEntry;\n new(intersectionObserverEntryInit: IntersectionObserverEntryInit): IntersectionObserverEntry;\n}\n\ninterface KeyboardEvent extends UIEvent {\n readonly altKey: boolean;\n readonly char: string | null;\n readonly charCode: number;\n readonly ctrlKey: boolean;\n readonly key: string;\n readonly keyCode: number;\n readonly locale: string;\n readonly location: number;\n readonly metaKey: boolean;\n readonly repeat: boolean;\n readonly shiftKey: boolean;\n readonly which: number;\n readonly code: string;\n getModifierState(keyArg: string): boolean;\n initKeyboardEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, keyArg: string, locationArg: number, modifiersListArg: string, repeat: boolean, locale: string): void;\n readonly DOM_KEY_LOCATION_JOYSTICK: number;\n readonly DOM_KEY_LOCATION_LEFT: number;\n readonly DOM_KEY_LOCATION_MOBILE: number;\n readonly DOM_KEY_LOCATION_NUMPAD: number;\n readonly DOM_KEY_LOCATION_RIGHT: number;\n readonly DOM_KEY_LOCATION_STANDARD: number;\n}\n\ndeclare var KeyboardEvent: {\n prototype: KeyboardEvent;\n new(typeArg: string, eventInitDict?: KeyboardEventInit): KeyboardEvent;\n readonly DOM_KEY_LOCATION_JOYSTICK: number;\n readonly DOM_KEY_LOCATION_LEFT: number;\n readonly DOM_KEY_LOCATION_MOBILE: number;\n readonly DOM_KEY_LOCATION_NUMPAD: number;\n readonly DOM_KEY_LOCATION_RIGHT: number;\n readonly DOM_KEY_LOCATION_STANDARD: number;\n}\n\ninterface ListeningStateChangedEvent extends Event {\n readonly label: string;\n readonly state: ListeningState;\n}\n\ndeclare var ListeningStateChangedEvent: {\n prototype: ListeningStateChangedEvent;\n new(): ListeningStateChangedEvent;\n}\n\ninterface Location {\n hash: string;\n host: string;\n hostname: string;\n href: string;\n readonly origin: string;\n pathname: string;\n port: string;\n protocol: string;\n search: string;\n assign(url: string): void;\n reload(forcedReload?: boolean): void;\n replace(url: string): void;\n toString(): string;\n}\n\ndeclare var Location: {\n prototype: Location;\n new(): Location;\n}\n\ninterface LongRunningScriptDetectedEvent extends Event {\n readonly executionTime: number;\n stopPageScriptExecution: boolean;\n}\n\ndeclare var LongRunningScriptDetectedEvent: {\n prototype: LongRunningScriptDetectedEvent;\n new(): LongRunningScriptDetectedEvent;\n}\n\ninterface MSApp {\n clearTemporaryWebDataAsync(): MSAppAsyncOperation;\n createBlobFromRandomAccessStream(type: string, seeker: any): Blob;\n createDataPackage(object: any): any;\n createDataPackageFromSelection(): any;\n createFileFromStorageFile(storageFile: any): File;\n createStreamFromInputStream(type: string, inputStream: any): MSStream;\n execAsyncAtPriority(asynchronousCallback: MSExecAtPriorityFunctionCallback, priority: string, ...args: any[]): void;\n execAtPriority(synchronousCallback: MSExecAtPriorityFunctionCallback, priority: string, ...args: any[]): any;\n getCurrentPriority(): string;\n getHtmlPrintDocumentSourceAsync(htmlDoc: any): Promise;\n getViewId(view: any): any;\n isTaskScheduledAtPriorityOrHigher(priority: string): boolean;\n pageHandlesAllApplicationActivations(enabled: boolean): void;\n suppressSubdownloadCredentialPrompts(suppress: boolean): void;\n terminateApp(exceptionObject: any): void;\n readonly CURRENT: string;\n readonly HIGH: string;\n readonly IDLE: string;\n readonly NORMAL: string;\n}\ndeclare var MSApp: MSApp;\n\ninterface MSAppAsyncOperationEventMap {\n \"complete\": Event;\n \"error\": Event;\n}\n\ninterface MSAppAsyncOperation extends EventTarget {\n readonly error: DOMError;\n oncomplete: (this: MSAppAsyncOperation, ev: Event) => any;\n onerror: (this: MSAppAsyncOperation, ev: Event) => any;\n readonly readyState: number;\n readonly result: any;\n start(): void;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n addEventListener(type: K, listener: (this: MSAppAsyncOperation, ev: MSAppAsyncOperationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSAppAsyncOperation: {\n prototype: MSAppAsyncOperation;\n new(): MSAppAsyncOperation;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n}\n\ninterface MSAssertion {\n readonly id: string;\n readonly type: MSCredentialType;\n}\n\ndeclare var MSAssertion: {\n prototype: MSAssertion;\n new(): MSAssertion;\n}\n\ninterface MSBlobBuilder {\n append(data: any, endings?: string): void;\n getBlob(contentType?: string): Blob;\n}\n\ndeclare var MSBlobBuilder: {\n prototype: MSBlobBuilder;\n new(): MSBlobBuilder;\n}\n\ninterface MSCredentials {\n getAssertion(challenge: string, filter?: MSCredentialFilter, params?: MSSignatureParameters): Promise;\n makeCredential(accountInfo: MSAccountInfo, params: MSCredentialParameters[], challenge?: string): Promise;\n}\n\ndeclare var MSCredentials: {\n prototype: MSCredentials;\n new(): MSCredentials;\n}\n\ninterface MSFIDOCredentialAssertion extends MSAssertion {\n readonly algorithm: string | Algorithm;\n readonly attestation: any;\n readonly publicKey: string;\n readonly transportHints: MSTransportType[];\n}\n\ndeclare var MSFIDOCredentialAssertion: {\n prototype: MSFIDOCredentialAssertion;\n new(): MSFIDOCredentialAssertion;\n}\n\ninterface MSFIDOSignature {\n readonly authnrData: string;\n readonly clientData: string;\n readonly signature: string;\n}\n\ndeclare var MSFIDOSignature: {\n prototype: MSFIDOSignature;\n new(): MSFIDOSignature;\n}\n\ninterface MSFIDOSignatureAssertion extends MSAssertion {\n readonly signature: MSFIDOSignature;\n}\n\ndeclare var MSFIDOSignatureAssertion: {\n prototype: MSFIDOSignatureAssertion;\n new(): MSFIDOSignatureAssertion;\n}\n\ninterface MSGesture {\n target: Element;\n addPointer(pointerId: number): void;\n stop(): void;\n}\n\ndeclare var MSGesture: {\n prototype: MSGesture;\n new(): MSGesture;\n}\n\ninterface MSGestureEvent extends UIEvent {\n readonly clientX: number;\n readonly clientY: number;\n readonly expansion: number;\n readonly gestureObject: any;\n readonly hwTimestamp: number;\n readonly offsetX: number;\n readonly offsetY: number;\n readonly rotation: number;\n readonly scale: number;\n readonly screenX: number;\n readonly screenY: number;\n readonly translationX: number;\n readonly translationY: number;\n readonly velocityAngular: number;\n readonly velocityExpansion: number;\n readonly velocityX: number;\n readonly velocityY: number;\n initGestureEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, offsetXArg: number, offsetYArg: number, translationXArg: number, translationYArg: number, scaleArg: number, expansionArg: number, rotationArg: number, velocityXArg: number, velocityYArg: number, velocityExpansionArg: number, velocityAngularArg: number, hwTimestampArg: number): void;\n readonly MSGESTURE_FLAG_BEGIN: number;\n readonly MSGESTURE_FLAG_CANCEL: number;\n readonly MSGESTURE_FLAG_END: number;\n readonly MSGESTURE_FLAG_INERTIA: number;\n readonly MSGESTURE_FLAG_NONE: number;\n}\n\ndeclare var MSGestureEvent: {\n prototype: MSGestureEvent;\n new(): MSGestureEvent;\n readonly MSGESTURE_FLAG_BEGIN: number;\n readonly MSGESTURE_FLAG_CANCEL: number;\n readonly MSGESTURE_FLAG_END: number;\n readonly MSGESTURE_FLAG_INERTIA: number;\n readonly MSGESTURE_FLAG_NONE: number;\n}\n\ninterface MSGraphicsTrust {\n readonly constrictionActive: boolean;\n readonly status: string;\n}\n\ndeclare var MSGraphicsTrust: {\n prototype: MSGraphicsTrust;\n new(): MSGraphicsTrust;\n}\n\ninterface MSHTMLWebViewElement extends HTMLElement {\n readonly canGoBack: boolean;\n readonly canGoForward: boolean;\n readonly containsFullScreenElement: boolean;\n readonly documentTitle: string;\n height: number;\n readonly settings: MSWebViewSettings;\n src: string;\n width: number;\n addWebAllowedObject(name: string, applicationObject: any): void;\n buildLocalStreamUri(contentIdentifier: string, relativePath: string): string;\n capturePreviewToBlobAsync(): MSWebViewAsyncOperation;\n captureSelectedContentToDataPackageAsync(): MSWebViewAsyncOperation;\n getDeferredPermissionRequestById(id: number): DeferredPermissionRequest;\n getDeferredPermissionRequests(): DeferredPermissionRequest[];\n goBack(): void;\n goForward(): void;\n invokeScriptAsync(scriptName: string, ...args: any[]): MSWebViewAsyncOperation;\n navigate(uri: string): void;\n navigateFocus(navigationReason: NavigationReason, origin: FocusNavigationOrigin): void;\n navigateToLocalStreamUri(source: string, streamResolver: any): void;\n navigateToString(contents: string): void;\n navigateWithHttpRequestMessage(requestMessage: any): void;\n refresh(): void;\n stop(): void;\n addEventListener(type: K, listener: (this: MSHTMLWebViewElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSHTMLWebViewElement: {\n prototype: MSHTMLWebViewElement;\n new(): MSHTMLWebViewElement;\n}\n\ninterface MSInputMethodContextEventMap {\n \"MSCandidateWindowHide\": Event;\n \"MSCandidateWindowShow\": Event;\n \"MSCandidateWindowUpdate\": Event;\n}\n\ninterface MSInputMethodContext extends EventTarget {\n readonly compositionEndOffset: number;\n readonly compositionStartOffset: number;\n oncandidatewindowhide: (this: MSInputMethodContext, ev: Event) => any;\n oncandidatewindowshow: (this: MSInputMethodContext, ev: Event) => any;\n oncandidatewindowupdate: (this: MSInputMethodContext, ev: Event) => any;\n readonly target: HTMLElement;\n getCandidateWindowClientRect(): ClientRect;\n getCompositionAlternatives(): string[];\n hasComposition(): boolean;\n isCandidateWindowVisible(): boolean;\n addEventListener(type: K, listener: (this: MSInputMethodContext, ev: MSInputMethodContextEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSInputMethodContext: {\n prototype: MSInputMethodContext;\n new(): MSInputMethodContext;\n}\n\ninterface MSManipulationEvent extends UIEvent {\n readonly currentState: number;\n readonly inertiaDestinationX: number;\n readonly inertiaDestinationY: number;\n readonly lastState: number;\n initMSManipulationEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, lastState: number, currentState: number): void;\n readonly MS_MANIPULATION_STATE_ACTIVE: number;\n readonly MS_MANIPULATION_STATE_CANCELLED: number;\n readonly MS_MANIPULATION_STATE_COMMITTED: number;\n readonly MS_MANIPULATION_STATE_DRAGGING: number;\n readonly MS_MANIPULATION_STATE_INERTIA: number;\n readonly MS_MANIPULATION_STATE_PRESELECT: number;\n readonly MS_MANIPULATION_STATE_SELECTING: number;\n readonly MS_MANIPULATION_STATE_STOPPED: number;\n}\n\ndeclare var MSManipulationEvent: {\n prototype: MSManipulationEvent;\n new(): MSManipulationEvent;\n readonly MS_MANIPULATION_STATE_ACTIVE: number;\n readonly MS_MANIPULATION_STATE_CANCELLED: number;\n readonly MS_MANIPULATION_STATE_COMMITTED: number;\n readonly MS_MANIPULATION_STATE_DRAGGING: number;\n readonly MS_MANIPULATION_STATE_INERTIA: number;\n readonly MS_MANIPULATION_STATE_PRESELECT: number;\n readonly MS_MANIPULATION_STATE_SELECTING: number;\n readonly MS_MANIPULATION_STATE_STOPPED: number;\n}\n\ninterface MSMediaKeyError {\n readonly code: number;\n readonly systemCode: number;\n readonly MS_MEDIA_KEYERR_CLIENT: number;\n readonly MS_MEDIA_KEYERR_DOMAIN: number;\n readonly MS_MEDIA_KEYERR_HARDWARECHANGE: number;\n readonly MS_MEDIA_KEYERR_OUTPUT: number;\n readonly MS_MEDIA_KEYERR_SERVICE: number;\n readonly MS_MEDIA_KEYERR_UNKNOWN: number;\n}\n\ndeclare var MSMediaKeyError: {\n prototype: MSMediaKeyError;\n new(): MSMediaKeyError;\n readonly MS_MEDIA_KEYERR_CLIENT: number;\n readonly MS_MEDIA_KEYERR_DOMAIN: number;\n readonly MS_MEDIA_KEYERR_HARDWARECHANGE: number;\n readonly MS_MEDIA_KEYERR_OUTPUT: number;\n readonly MS_MEDIA_KEYERR_SERVICE: number;\n readonly MS_MEDIA_KEYERR_UNKNOWN: number;\n}\n\ninterface MSMediaKeyMessageEvent extends Event {\n readonly destinationURL: string | null;\n readonly message: Uint8Array;\n}\n\ndeclare var MSMediaKeyMessageEvent: {\n prototype: MSMediaKeyMessageEvent;\n new(): MSMediaKeyMessageEvent;\n}\n\ninterface MSMediaKeyNeededEvent extends Event {\n readonly initData: Uint8Array | null;\n}\n\ndeclare var MSMediaKeyNeededEvent: {\n prototype: MSMediaKeyNeededEvent;\n new(): MSMediaKeyNeededEvent;\n}\n\ninterface MSMediaKeySession extends EventTarget {\n readonly error: MSMediaKeyError | null;\n readonly keySystem: string;\n readonly sessionId: string;\n close(): void;\n update(key: Uint8Array): void;\n}\n\ndeclare var MSMediaKeySession: {\n prototype: MSMediaKeySession;\n new(): MSMediaKeySession;\n}\n\ninterface MSMediaKeys {\n readonly keySystem: string;\n createSession(type: string, initData: Uint8Array, cdmData?: Uint8Array): MSMediaKeySession;\n}\n\ndeclare var MSMediaKeys: {\n prototype: MSMediaKeys;\n new(keySystem: string): MSMediaKeys;\n isTypeSupported(keySystem: string, type?: string): boolean;\n isTypeSupportedWithFeatures(keySystem: string, type?: string): string;\n}\n\ninterface MSPointerEvent extends MouseEvent {\n readonly currentPoint: any;\n readonly height: number;\n readonly hwTimestamp: number;\n readonly intermediatePoints: any;\n readonly isPrimary: boolean;\n readonly pointerId: number;\n readonly pointerType: any;\n readonly pressure: number;\n readonly rotation: number;\n readonly tiltX: number;\n readonly tiltY: number;\n readonly width: number;\n getCurrentPoint(element: Element): void;\n getIntermediatePoints(element: Element): void;\n initPointerEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget, offsetXArg: number, offsetYArg: number, widthArg: number, heightArg: number, pressure: number, rotation: number, tiltX: number, tiltY: number, pointerIdArg: number, pointerType: any, hwTimestampArg: number, isPrimary: boolean): void;\n}\n\ndeclare var MSPointerEvent: {\n prototype: MSPointerEvent;\n new(typeArg: string, eventInitDict?: PointerEventInit): MSPointerEvent;\n}\n\ninterface MSRangeCollection {\n readonly length: number;\n item(index: number): Range;\n [index: number]: Range;\n}\n\ndeclare var MSRangeCollection: {\n prototype: MSRangeCollection;\n new(): MSRangeCollection;\n}\n\ninterface MSSiteModeEvent extends Event {\n readonly actionURL: string;\n readonly buttonID: number;\n}\n\ndeclare var MSSiteModeEvent: {\n prototype: MSSiteModeEvent;\n new(): MSSiteModeEvent;\n}\n\ninterface MSStream {\n readonly type: string;\n msClose(): void;\n msDetachStream(): any;\n}\n\ndeclare var MSStream: {\n prototype: MSStream;\n new(): MSStream;\n}\n\ninterface MSStreamReader extends EventTarget, MSBaseReader {\n readonly error: DOMError;\n readAsArrayBuffer(stream: MSStream, size?: number): void;\n readAsBinaryString(stream: MSStream, size?: number): void;\n readAsBlob(stream: MSStream, size?: number): void;\n readAsDataURL(stream: MSStream, size?: number): void;\n readAsText(stream: MSStream, encoding?: string, size?: number): void;\n addEventListener(type: K, listener: (this: MSStreamReader, ev: MSBaseReaderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSStreamReader: {\n prototype: MSStreamReader;\n new(): MSStreamReader;\n}\n\ninterface MSWebViewAsyncOperationEventMap {\n \"complete\": Event;\n \"error\": Event;\n}\n\ninterface MSWebViewAsyncOperation extends EventTarget {\n readonly error: DOMError;\n oncomplete: (this: MSWebViewAsyncOperation, ev: Event) => any;\n onerror: (this: MSWebViewAsyncOperation, ev: Event) => any;\n readonly readyState: number;\n readonly result: any;\n readonly target: MSHTMLWebViewElement;\n readonly type: number;\n start(): void;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n readonly TYPE_CAPTURE_PREVIEW_TO_RANDOM_ACCESS_STREAM: number;\n readonly TYPE_CREATE_DATA_PACKAGE_FROM_SELECTION: number;\n readonly TYPE_INVOKE_SCRIPT: number;\n addEventListener(type: K, listener: (this: MSWebViewAsyncOperation, ev: MSWebViewAsyncOperationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSWebViewAsyncOperation: {\n prototype: MSWebViewAsyncOperation;\n new(): MSWebViewAsyncOperation;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n readonly TYPE_CAPTURE_PREVIEW_TO_RANDOM_ACCESS_STREAM: number;\n readonly TYPE_CREATE_DATA_PACKAGE_FROM_SELECTION: number;\n readonly TYPE_INVOKE_SCRIPT: number;\n}\n\ninterface MSWebViewSettings {\n isIndexedDBEnabled: boolean;\n isJavaScriptEnabled: boolean;\n}\n\ndeclare var MSWebViewSettings: {\n prototype: MSWebViewSettings;\n new(): MSWebViewSettings;\n}\n\ninterface MediaDeviceInfo {\n readonly deviceId: string;\n readonly groupId: string;\n readonly kind: MediaDeviceKind;\n readonly label: string;\n}\n\ndeclare var MediaDeviceInfo: {\n prototype: MediaDeviceInfo;\n new(): MediaDeviceInfo;\n}\n\ninterface MediaDevicesEventMap {\n \"devicechange\": Event;\n}\n\ninterface MediaDevices extends EventTarget {\n ondevicechange: (this: MediaDevices, ev: Event) => any;\n enumerateDevices(): any;\n getSupportedConstraints(): MediaTrackSupportedConstraints;\n getUserMedia(constraints: MediaStreamConstraints): Promise;\n addEventListener(type: K, listener: (this: MediaDevices, ev: MediaDevicesEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MediaDevices: {\n prototype: MediaDevices;\n new(): MediaDevices;\n}\n\ninterface MediaElementAudioSourceNode extends AudioNode {\n}\n\ndeclare var MediaElementAudioSourceNode: {\n prototype: MediaElementAudioSourceNode;\n new(): MediaElementAudioSourceNode;\n}\n\ninterface MediaEncryptedEvent extends Event {\n readonly initData: ArrayBuffer | null;\n readonly initDataType: string;\n}\n\ndeclare var MediaEncryptedEvent: {\n prototype: MediaEncryptedEvent;\n new(type: string, eventInitDict?: MediaEncryptedEventInit): MediaEncryptedEvent;\n}\n\ninterface MediaError {\n readonly code: number;\n readonly msExtendedCode: number;\n readonly MEDIA_ERR_ABORTED: number;\n readonly MEDIA_ERR_DECODE: number;\n readonly MEDIA_ERR_NETWORK: number;\n readonly MEDIA_ERR_SRC_NOT_SUPPORTED: number;\n readonly MS_MEDIA_ERR_ENCRYPTED: number;\n}\n\ndeclare var MediaError: {\n prototype: MediaError;\n new(): MediaError;\n readonly MEDIA_ERR_ABORTED: number;\n readonly MEDIA_ERR_DECODE: number;\n readonly MEDIA_ERR_NETWORK: number;\n readonly MEDIA_ERR_SRC_NOT_SUPPORTED: number;\n readonly MS_MEDIA_ERR_ENCRYPTED: number;\n}\n\ninterface MediaKeyMessageEvent extends Event {\n readonly message: ArrayBuffer;\n readonly messageType: MediaKeyMessageType;\n}\n\ndeclare var MediaKeyMessageEvent: {\n prototype: MediaKeyMessageEvent;\n new(type: string, eventInitDict?: MediaKeyMessageEventInit): MediaKeyMessageEvent;\n}\n\ninterface MediaKeySession extends EventTarget {\n readonly closed: Promise;\n readonly expiration: number;\n readonly keyStatuses: MediaKeyStatusMap;\n readonly sessionId: string;\n close(): Promise;\n generateRequest(initDataType: string, initData: any): Promise;\n load(sessionId: string): Promise;\n remove(): Promise;\n update(response: any): Promise;\n}\n\ndeclare var MediaKeySession: {\n prototype: MediaKeySession;\n new(): MediaKeySession;\n}\n\ninterface MediaKeyStatusMap {\n readonly size: number;\n forEach(callback: ForEachCallback): void;\n get(keyId: any): MediaKeyStatus;\n has(keyId: any): boolean;\n}\n\ndeclare var MediaKeyStatusMap: {\n prototype: MediaKeyStatusMap;\n new(): MediaKeyStatusMap;\n}\n\ninterface MediaKeySystemAccess {\n readonly keySystem: string;\n createMediaKeys(): Promise;\n getConfiguration(): MediaKeySystemConfiguration;\n}\n\ndeclare var MediaKeySystemAccess: {\n prototype: MediaKeySystemAccess;\n new(): MediaKeySystemAccess;\n}\n\ninterface MediaKeys {\n createSession(sessionType?: MediaKeySessionType): MediaKeySession;\n setServerCertificate(serverCertificate: any): Promise;\n}\n\ndeclare var MediaKeys: {\n prototype: MediaKeys;\n new(): MediaKeys;\n}\n\ninterface MediaList {\n readonly length: number;\n mediaText: string;\n appendMedium(newMedium: string): void;\n deleteMedium(oldMedium: string): void;\n item(index: number): string;\n toString(): string;\n [index: number]: string;\n}\n\ndeclare var MediaList: {\n prototype: MediaList;\n new(): MediaList;\n}\n\ninterface MediaQueryList {\n readonly matches: boolean;\n readonly media: string;\n addListener(listener: MediaQueryListListener): void;\n removeListener(listener: MediaQueryListListener): void;\n}\n\ndeclare var MediaQueryList: {\n prototype: MediaQueryList;\n new(): MediaQueryList;\n}\n\ninterface MediaSource extends EventTarget {\n readonly activeSourceBuffers: SourceBufferList;\n duration: number;\n readonly readyState: string;\n readonly sourceBuffers: SourceBufferList;\n addSourceBuffer(type: string): SourceBuffer;\n endOfStream(error?: number): void;\n removeSourceBuffer(sourceBuffer: SourceBuffer): void;\n}\n\ndeclare var MediaSource: {\n prototype: MediaSource;\n new(): MediaSource;\n isTypeSupported(type: string): boolean;\n}\n\ninterface MediaStreamEventMap {\n \"active\": Event;\n \"addtrack\": MediaStreamTrackEvent;\n \"inactive\": Event;\n \"removetrack\": MediaStreamTrackEvent;\n}\n\ninterface MediaStream extends EventTarget {\n readonly active: boolean;\n readonly id: string;\n onactive: (this: MediaStream, ev: Event) => any;\n onaddtrack: (this: MediaStream, ev: MediaStreamTrackEvent) => any;\n oninactive: (this: MediaStream, ev: Event) => any;\n onremovetrack: (this: MediaStream, ev: MediaStreamTrackEvent) => any;\n addTrack(track: MediaStreamTrack): void;\n clone(): MediaStream;\n getAudioTracks(): MediaStreamTrack[];\n getTrackById(trackId: string): MediaStreamTrack | null;\n getTracks(): MediaStreamTrack[];\n getVideoTracks(): MediaStreamTrack[];\n removeTrack(track: MediaStreamTrack): void;\n stop(): void;\n addEventListener(type: K, listener: (this: MediaStream, ev: MediaStreamEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MediaStream: {\n prototype: MediaStream;\n new(streamOrTracks?: MediaStream | MediaStreamTrack[]): MediaStream;\n}\n\ninterface MediaStreamAudioSourceNode extends AudioNode {\n}\n\ndeclare var MediaStreamAudioSourceNode: {\n prototype: MediaStreamAudioSourceNode;\n new(): MediaStreamAudioSourceNode;\n}\n\ninterface MediaStreamError {\n readonly constraintName: string | null;\n readonly message: string | null;\n readonly name: string;\n}\n\ndeclare var MediaStreamError: {\n prototype: MediaStreamError;\n new(): MediaStreamError;\n}\n\ninterface MediaStreamErrorEvent extends Event {\n readonly error: MediaStreamError | null;\n}\n\ndeclare var MediaStreamErrorEvent: {\n prototype: MediaStreamErrorEvent;\n new(typeArg: string, eventInitDict?: MediaStreamErrorEventInit): MediaStreamErrorEvent;\n}\n\ninterface MediaStreamEvent extends Event {\n readonly stream: MediaStream | null;\n}\n\ndeclare var MediaStreamEvent: {\n prototype: MediaStreamEvent;\n new(type: string, eventInitDict: MediaStreamEventInit): MediaStreamEvent;\n}\n\ninterface MediaStreamTrackEventMap {\n \"ended\": MediaStreamErrorEvent;\n \"mute\": Event;\n \"overconstrained\": MediaStreamErrorEvent;\n \"unmute\": Event;\n}\n\ninterface MediaStreamTrack extends EventTarget {\n enabled: boolean;\n readonly id: string;\n readonly kind: string;\n readonly label: string;\n readonly muted: boolean;\n onended: (this: MediaStreamTrack, ev: MediaStreamErrorEvent) => any;\n onmute: (this: MediaStreamTrack, ev: Event) => any;\n onoverconstrained: (this: MediaStreamTrack, ev: MediaStreamErrorEvent) => any;\n onunmute: (this: MediaStreamTrack, ev: Event) => any;\n readonly readonly: boolean;\n readonly readyState: MediaStreamTrackState;\n readonly remote: boolean;\n applyConstraints(constraints: MediaTrackConstraints): Promise;\n clone(): MediaStreamTrack;\n getCapabilities(): MediaTrackCapabilities;\n getConstraints(): MediaTrackConstraints;\n getSettings(): MediaTrackSettings;\n stop(): void;\n addEventListener(type: K, listener: (this: MediaStreamTrack, ev: MediaStreamTrackEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MediaStreamTrack: {\n prototype: MediaStreamTrack;\n new(): MediaStreamTrack;\n}\n\ninterface MediaStreamTrackEvent extends Event {\n readonly track: MediaStreamTrack;\n}\n\ndeclare var MediaStreamTrackEvent: {\n prototype: MediaStreamTrackEvent;\n new(typeArg: string, eventInitDict?: MediaStreamTrackEventInit): MediaStreamTrackEvent;\n}\n\ninterface MessageChannel {\n readonly port1: MessagePort;\n readonly port2: MessagePort;\n}\n\ndeclare var MessageChannel: {\n prototype: MessageChannel;\n new(): MessageChannel;\n}\n\ninterface MessageEvent extends Event {\n readonly data: any;\n readonly origin: string;\n readonly ports: any;\n readonly source: Window;\n initMessageEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, dataArg: any, originArg: string, lastEventIdArg: string, sourceArg: Window): void;\n}\n\ndeclare var MessageEvent: {\n prototype: MessageEvent;\n new(type: string, eventInitDict?: MessageEventInit): MessageEvent;\n}\n\ninterface MessagePortEventMap {\n \"message\": MessageEvent;\n}\n\ninterface MessagePort extends EventTarget {\n onmessage: (this: MessagePort, ev: MessageEvent) => any;\n close(): void;\n postMessage(message?: any, transfer?: any[]): void;\n start(): void;\n addEventListener(type: K, listener: (this: MessagePort, ev: MessagePortEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MessagePort: {\n prototype: MessagePort;\n new(): MessagePort;\n}\n\ninterface MimeType {\n readonly description: string;\n readonly enabledPlugin: Plugin;\n readonly suffixes: string;\n readonly type: string;\n}\n\ndeclare var MimeType: {\n prototype: MimeType;\n new(): MimeType;\n}\n\ninterface MimeTypeArray {\n readonly length: number;\n item(index: number): Plugin;\n namedItem(type: string): Plugin;\n [index: number]: Plugin;\n}\n\ndeclare var MimeTypeArray: {\n prototype: MimeTypeArray;\n new(): MimeTypeArray;\n}\n\ninterface MouseEvent extends UIEvent {\n readonly altKey: boolean;\n readonly button: number;\n readonly buttons: number;\n readonly clientX: number;\n readonly clientY: number;\n readonly ctrlKey: boolean;\n readonly fromElement: Element;\n readonly layerX: number;\n readonly layerY: number;\n readonly metaKey: boolean;\n readonly movementX: number;\n readonly movementY: number;\n readonly offsetX: number;\n readonly offsetY: number;\n readonly pageX: number;\n readonly pageY: number;\n readonly relatedTarget: EventTarget;\n readonly screenX: number;\n readonly screenY: number;\n readonly shiftKey: boolean;\n readonly toElement: Element;\n readonly which: number;\n readonly x: number;\n readonly y: number;\n getModifierState(keyArg: string): boolean;\n initMouseEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget | null): void;\n}\n\ndeclare var MouseEvent: {\n prototype: MouseEvent;\n new(typeArg: string, eventInitDict?: MouseEventInit): MouseEvent;\n}\n\ninterface MutationEvent extends Event {\n readonly attrChange: number;\n readonly attrName: string;\n readonly newValue: string;\n readonly prevValue: string;\n readonly relatedNode: Node;\n initMutationEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, relatedNodeArg: Node, prevValueArg: string, newValueArg: string, attrNameArg: string, attrChangeArg: number): void;\n readonly ADDITION: number;\n readonly MODIFICATION: number;\n readonly REMOVAL: number;\n}\n\ndeclare var MutationEvent: {\n prototype: MutationEvent;\n new(): MutationEvent;\n readonly ADDITION: number;\n readonly MODIFICATION: number;\n readonly REMOVAL: number;\n}\n\ninterface MutationObserver {\n disconnect(): void;\n observe(target: Node, options: MutationObserverInit): void;\n takeRecords(): MutationRecord[];\n}\n\ndeclare var MutationObserver: {\n prototype: MutationObserver;\n new(callback: MutationCallback): MutationObserver;\n}\n\ninterface MutationRecord {\n readonly addedNodes: NodeList;\n readonly attributeName: string | null;\n readonly attributeNamespace: string | null;\n readonly nextSibling: Node | null;\n readonly oldValue: string | null;\n readonly previousSibling: Node | null;\n readonly removedNodes: NodeList;\n readonly target: Node;\n readonly type: string;\n}\n\ndeclare var MutationRecord: {\n prototype: MutationRecord;\n new(): MutationRecord;\n}\n\ninterface NamedNodeMap {\n readonly length: number;\n getNamedItem(name: string): Attr;\n getNamedItemNS(namespaceURI: string | null, localName: string | null): Attr;\n item(index: number): Attr;\n removeNamedItem(name: string): Attr;\n removeNamedItemNS(namespaceURI: string | null, localName: string | null): Attr;\n setNamedItem(arg: Attr): Attr;\n setNamedItemNS(arg: Attr): Attr;\n [index: number]: Attr;\n}\n\ndeclare var NamedNodeMap: {\n prototype: NamedNodeMap;\n new(): NamedNodeMap;\n}\n\ninterface NavigationCompletedEvent extends NavigationEvent {\n readonly isSuccess: boolean;\n readonly webErrorStatus: number;\n}\n\ndeclare var NavigationCompletedEvent: {\n prototype: NavigationCompletedEvent;\n new(): NavigationCompletedEvent;\n}\n\ninterface NavigationEvent extends Event {\n readonly uri: string;\n}\n\ndeclare var NavigationEvent: {\n prototype: NavigationEvent;\n new(): NavigationEvent;\n}\n\ninterface NavigationEventWithReferrer extends NavigationEvent {\n readonly referer: string;\n}\n\ndeclare var NavigationEventWithReferrer: {\n prototype: NavigationEventWithReferrer;\n new(): NavigationEventWithReferrer;\n}\n\ninterface Navigator extends Object, NavigatorID, NavigatorOnLine, NavigatorContentUtils, NavigatorStorageUtils, NavigatorGeolocation, MSNavigatorDoNotTrack, MSFileSaver, NavigatorBeacon, NavigatorConcurrentHardware, NavigatorUserMedia {\n readonly authentication: WebAuthentication;\n readonly cookieEnabled: boolean;\n gamepadInputEmulation: GamepadInputEmulationType;\n readonly language: string;\n readonly maxTouchPoints: number;\n readonly mimeTypes: MimeTypeArray;\n readonly msManipulationViewsEnabled: boolean;\n readonly msMaxTouchPoints: number;\n readonly msPointerEnabled: boolean;\n readonly plugins: PluginArray;\n readonly pointerEnabled: boolean;\n readonly serviceWorker: ServiceWorkerContainer;\n readonly webdriver: boolean;\n readonly hardwareConcurrency: number;\n getGamepads(): Gamepad[];\n javaEnabled(): boolean;\n msLaunchUri(uri: string, successCallback?: MSLaunchUriCallback, noHandlerCallback?: MSLaunchUriCallback): void;\n requestMediaKeySystemAccess(keySystem: string, supportedConfigurations: MediaKeySystemConfiguration[]): Promise;\n vibrate(pattern: number | number[]): boolean;\n}\n\ndeclare var Navigator: {\n prototype: Navigator;\n new(): Navigator;\n}\n\ninterface Node extends EventTarget {\n readonly attributes: NamedNodeMap;\n readonly baseURI: string | null;\n readonly childNodes: NodeList;\n readonly firstChild: Node | null;\n readonly lastChild: Node | null;\n readonly localName: string | null;\n readonly namespaceURI: string | null;\n readonly nextSibling: Node | null;\n readonly nodeName: string;\n readonly nodeType: number;\n nodeValue: string | null;\n readonly ownerDocument: Document;\n readonly parentElement: HTMLElement | null;\n readonly parentNode: Node | null;\n readonly previousSibling: Node | null;\n textContent: string | null;\n appendChild(newChild: T): T;\n cloneNode(deep?: boolean): Node;\n compareDocumentPosition(other: Node): number;\n contains(child: Node): boolean;\n hasAttributes(): boolean;\n hasChildNodes(): boolean;\n insertBefore(newChild: T, refChild: Node | null): T;\n isDefaultNamespace(namespaceURI: string | null): boolean;\n isEqualNode(arg: Node): boolean;\n isSameNode(other: Node): boolean;\n lookupNamespaceURI(prefix: string | null): string | null;\n lookupPrefix(namespaceURI: string | null): string | null;\n normalize(): void;\n removeChild(oldChild: T): T;\n replaceChild(newChild: Node, oldChild: T): T;\n readonly ATTRIBUTE_NODE: number;\n readonly CDATA_SECTION_NODE: number;\n readonly COMMENT_NODE: number;\n readonly DOCUMENT_FRAGMENT_NODE: number;\n readonly DOCUMENT_NODE: number;\n readonly DOCUMENT_POSITION_CONTAINED_BY: number;\n readonly DOCUMENT_POSITION_CONTAINS: number;\n readonly DOCUMENT_POSITION_DISCONNECTED: number;\n readonly DOCUMENT_POSITION_FOLLOWING: number;\n readonly DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: number;\n readonly DOCUMENT_POSITION_PRECEDING: number;\n readonly DOCUMENT_TYPE_NODE: number;\n readonly ELEMENT_NODE: number;\n readonly ENTITY_NODE: number;\n readonly ENTITY_REFERENCE_NODE: number;\n readonly NOTATION_NODE: number;\n readonly PROCESSING_INSTRUCTION_NODE: number;\n readonly TEXT_NODE: number;\n}\n\ndeclare var Node: {\n prototype: Node;\n new(): Node;\n readonly ATTRIBUTE_NODE: number;\n readonly CDATA_SECTION_NODE: number;\n readonly COMMENT_NODE: number;\n readonly DOCUMENT_FRAGMENT_NODE: number;\n readonly DOCUMENT_NODE: number;\n readonly DOCUMENT_POSITION_CONTAINED_BY: number;\n readonly DOCUMENT_POSITION_CONTAINS: number;\n readonly DOCUMENT_POSITION_DISCONNECTED: number;\n readonly DOCUMENT_POSITION_FOLLOWING: number;\n readonly DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: number;\n readonly DOCUMENT_POSITION_PRECEDING: number;\n readonly DOCUMENT_TYPE_NODE: number;\n readonly ELEMENT_NODE: number;\n readonly ENTITY_NODE: number;\n readonly ENTITY_REFERENCE_NODE: number;\n readonly NOTATION_NODE: number;\n readonly PROCESSING_INSTRUCTION_NODE: number;\n readonly TEXT_NODE: number;\n}\n\ninterface NodeFilter {\n acceptNode(n: Node): number;\n}\n\ndeclare var NodeFilter: {\n readonly FILTER_ACCEPT: number;\n readonly FILTER_REJECT: number;\n readonly FILTER_SKIP: number;\n readonly SHOW_ALL: number;\n readonly SHOW_ATTRIBUTE: number;\n readonly SHOW_CDATA_SECTION: number;\n readonly SHOW_COMMENT: number;\n readonly SHOW_DOCUMENT: number;\n readonly SHOW_DOCUMENT_FRAGMENT: number;\n readonly SHOW_DOCUMENT_TYPE: number;\n readonly SHOW_ELEMENT: number;\n readonly SHOW_ENTITY: number;\n readonly SHOW_ENTITY_REFERENCE: number;\n readonly SHOW_NOTATION: number;\n readonly SHOW_PROCESSING_INSTRUCTION: number;\n readonly SHOW_TEXT: number;\n}\n\ninterface NodeIterator {\n readonly expandEntityReferences: boolean;\n readonly filter: NodeFilter;\n readonly root: Node;\n readonly whatToShow: number;\n detach(): void;\n nextNode(): Node;\n previousNode(): Node;\n}\n\ndeclare var NodeIterator: {\n prototype: NodeIterator;\n new(): NodeIterator;\n}\n\ninterface NodeList {\n readonly length: number;\n item(index: number): Node;\n [index: number]: Node;\n}\n\ndeclare var NodeList: {\n prototype: NodeList;\n new(): NodeList;\n}\n\ninterface NotificationEventMap {\n \"click\": Event;\n \"close\": Event;\n \"error\": Event;\n \"show\": Event;\n}\n\ninterface Notification extends EventTarget {\n readonly body: string;\n readonly dir: NotificationDirection;\n readonly icon: string;\n readonly lang: string;\n onclick: (this: Notification, ev: Event) => any;\n onclose: (this: Notification, ev: Event) => any;\n onerror: (this: Notification, ev: Event) => any;\n onshow: (this: Notification, ev: Event) => any;\n readonly permission: NotificationPermission;\n readonly tag: string;\n readonly title: string;\n close(): void;\n addEventListener(type: K, listener: (this: Notification, ev: NotificationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Notification: {\n prototype: Notification;\n new(title: string, options?: NotificationOptions): Notification;\n requestPermission(callback?: NotificationPermissionCallback): Promise;\n}\n\ninterface OES_element_index_uint {\n}\n\ndeclare var OES_element_index_uint: {\n prototype: OES_element_index_uint;\n new(): OES_element_index_uint;\n}\n\ninterface OES_standard_derivatives {\n readonly FRAGMENT_SHADER_DERIVATIVE_HINT_OES: number;\n}\n\ndeclare var OES_standard_derivatives: {\n prototype: OES_standard_derivatives;\n new(): OES_standard_derivatives;\n readonly FRAGMENT_SHADER_DERIVATIVE_HINT_OES: number;\n}\n\ninterface OES_texture_float {\n}\n\ndeclare var OES_texture_float: {\n prototype: OES_texture_float;\n new(): OES_texture_float;\n}\n\ninterface OES_texture_float_linear {\n}\n\ndeclare var OES_texture_float_linear: {\n prototype: OES_texture_float_linear;\n new(): OES_texture_float_linear;\n}\n\ninterface OES_texture_half_float {\n readonly HALF_FLOAT_OES: number;\n}\n\ndeclare var OES_texture_half_float: {\n prototype: OES_texture_half_float;\n new(): OES_texture_half_float;\n readonly HALF_FLOAT_OES: number;\n}\n\ninterface OES_texture_half_float_linear {\n}\n\ndeclare var OES_texture_half_float_linear: {\n prototype: OES_texture_half_float_linear;\n new(): OES_texture_half_float_linear;\n}\n\ninterface OfflineAudioCompletionEvent extends Event {\n readonly renderedBuffer: AudioBuffer;\n}\n\ndeclare var OfflineAudioCompletionEvent: {\n prototype: OfflineAudioCompletionEvent;\n new(): OfflineAudioCompletionEvent;\n}\n\ninterface OfflineAudioContextEventMap extends AudioContextEventMap {\n \"complete\": OfflineAudioCompletionEvent;\n}\n\ninterface OfflineAudioContext extends AudioContextBase {\n readonly length: number;\n oncomplete: (this: OfflineAudioContext, ev: OfflineAudioCompletionEvent) => any;\n startRendering(): Promise;\n suspend(suspendTime: number): Promise;\n addEventListener(type: K, listener: (this: OfflineAudioContext, ev: OfflineAudioContextEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var OfflineAudioContext: {\n prototype: OfflineAudioContext;\n new(numberOfChannels: number, length: number, sampleRate: number): OfflineAudioContext;\n}\n\ninterface OscillatorNodeEventMap {\n \"ended\": MediaStreamErrorEvent;\n}\n\ninterface OscillatorNode extends AudioNode {\n readonly detune: AudioParam;\n readonly frequency: AudioParam;\n onended: (this: OscillatorNode, ev: MediaStreamErrorEvent) => any;\n type: OscillatorType;\n setPeriodicWave(periodicWave: PeriodicWave): void;\n start(when?: number): void;\n stop(when?: number): void;\n addEventListener(type: K, listener: (this: OscillatorNode, ev: OscillatorNodeEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var OscillatorNode: {\n prototype: OscillatorNode;\n new(): OscillatorNode;\n}\n\ninterface OverflowEvent extends UIEvent {\n readonly horizontalOverflow: boolean;\n readonly orient: number;\n readonly verticalOverflow: boolean;\n readonly BOTH: number;\n readonly HORIZONTAL: number;\n readonly VERTICAL: number;\n}\n\ndeclare var OverflowEvent: {\n prototype: OverflowEvent;\n new(): OverflowEvent;\n readonly BOTH: number;\n readonly HORIZONTAL: number;\n readonly VERTICAL: number;\n}\n\ninterface PageTransitionEvent extends Event {\n readonly persisted: boolean;\n}\n\ndeclare var PageTransitionEvent: {\n prototype: PageTransitionEvent;\n new(): PageTransitionEvent;\n}\n\ninterface PannerNode extends AudioNode {\n coneInnerAngle: number;\n coneOuterAngle: number;\n coneOuterGain: number;\n distanceModel: DistanceModelType;\n maxDistance: number;\n panningModel: PanningModelType;\n refDistance: number;\n rolloffFactor: number;\n setOrientation(x: number, y: number, z: number): void;\n setPosition(x: number, y: number, z: number): void;\n setVelocity(x: number, y: number, z: number): void;\n}\n\ndeclare var PannerNode: {\n prototype: PannerNode;\n new(): PannerNode;\n}\n\ninterface Path2D extends Object, CanvasPathMethods {\n}\n\ndeclare var Path2D: {\n prototype: Path2D;\n new(path?: Path2D): Path2D;\n}\n\ninterface PaymentAddress {\n readonly addressLine: string[];\n readonly city: string;\n readonly country: string;\n readonly dependentLocality: string;\n readonly languageCode: string;\n readonly organization: string;\n readonly phone: string;\n readonly postalCode: string;\n readonly recipient: string;\n readonly region: string;\n readonly sortingCode: string;\n toJSON(): any;\n}\n\ndeclare var PaymentAddress: {\n prototype: PaymentAddress;\n new(): PaymentAddress;\n}\n\ninterface PaymentRequestEventMap {\n \"shippingaddresschange\": Event;\n \"shippingoptionchange\": Event;\n}\n\ninterface PaymentRequest extends EventTarget {\n onshippingaddresschange: (this: PaymentRequest, ev: Event) => any;\n onshippingoptionchange: (this: PaymentRequest, ev: Event) => any;\n readonly shippingAddress: PaymentAddress | null;\n readonly shippingOption: string | null;\n readonly shippingType: PaymentShippingType | null;\n abort(): Promise;\n show(): Promise;\n addEventListener(type: K, listener: (this: PaymentRequest, ev: PaymentRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var PaymentRequest: {\n prototype: PaymentRequest;\n new(methodData: PaymentMethodData[], details: PaymentDetails, options?: PaymentOptions): PaymentRequest;\n}\n\ninterface PaymentRequestUpdateEvent extends Event {\n updateWith(d: Promise): void;\n}\n\ndeclare var PaymentRequestUpdateEvent: {\n prototype: PaymentRequestUpdateEvent;\n new(type: string, eventInitDict?: PaymentRequestUpdateEventInit): PaymentRequestUpdateEvent;\n}\n\ninterface PaymentResponse {\n readonly details: any;\n readonly methodName: string;\n readonly payerEmail: string | null;\n readonly payerName: string | null;\n readonly payerPhone: string | null;\n readonly shippingAddress: PaymentAddress | null;\n readonly shippingOption: string | null;\n complete(result?: PaymentComplete): Promise;\n toJSON(): any;\n}\n\ndeclare var PaymentResponse: {\n prototype: PaymentResponse;\n new(): PaymentResponse;\n}\n\ninterface PerfWidgetExternal {\n readonly activeNetworkRequestCount: number;\n readonly averageFrameTime: number;\n readonly averagePaintTime: number;\n readonly extraInformationEnabled: boolean;\n readonly independentRenderingEnabled: boolean;\n readonly irDisablingContentString: string;\n readonly irStatusAvailable: boolean;\n readonly maxCpuSpeed: number;\n readonly paintRequestsPerSecond: number;\n readonly performanceCounter: number;\n readonly performanceCounterFrequency: number;\n addEventListener(eventType: string, callback: Function): void;\n getMemoryUsage(): number;\n getProcessCpuUsage(): number;\n getRecentCpuUsage(last: number | null): any;\n getRecentFrames(last: number | null): any;\n getRecentMemoryUsage(last: number | null): any;\n getRecentPaintRequests(last: number | null): any;\n removeEventListener(eventType: string, callback: Function): void;\n repositionWindow(x: number, y: number): void;\n resizeWindow(width: number, height: number): void;\n}\n\ndeclare var PerfWidgetExternal: {\n prototype: PerfWidgetExternal;\n new(): PerfWidgetExternal;\n}\n\ninterface Performance {\n readonly navigation: PerformanceNavigation;\n readonly timing: PerformanceTiming;\n clearMarks(markName?: string): void;\n clearMeasures(measureName?: string): void;\n clearResourceTimings(): void;\n getEntries(): any;\n getEntriesByName(name: string, entryType?: string): any;\n getEntriesByType(entryType: string): any;\n getMarks(markName?: string): any;\n getMeasures(measureName?: string): any;\n mark(markName: string): void;\n measure(measureName: string, startMarkName?: string, endMarkName?: string): void;\n now(): number;\n setResourceTimingBufferSize(maxSize: number): void;\n toJSON(): any;\n}\n\ndeclare var Performance: {\n prototype: Performance;\n new(): Performance;\n}\n\ninterface PerformanceEntry {\n readonly duration: number;\n readonly entryType: string;\n readonly name: string;\n readonly startTime: number;\n}\n\ndeclare var PerformanceEntry: {\n prototype: PerformanceEntry;\n new(): PerformanceEntry;\n}\n\ninterface PerformanceMark extends PerformanceEntry {\n}\n\ndeclare var PerformanceMark: {\n prototype: PerformanceMark;\n new(): PerformanceMark;\n}\n\ninterface PerformanceMeasure extends PerformanceEntry {\n}\n\ndeclare var PerformanceMeasure: {\n prototype: PerformanceMeasure;\n new(): PerformanceMeasure;\n}\n\ninterface PerformanceNavigation {\n readonly redirectCount: number;\n readonly type: number;\n toJSON(): any;\n readonly TYPE_BACK_FORWARD: number;\n readonly TYPE_NAVIGATE: number;\n readonly TYPE_RELOAD: number;\n readonly TYPE_RESERVED: number;\n}\n\ndeclare var PerformanceNavigation: {\n prototype: PerformanceNavigation;\n new(): PerformanceNavigation;\n readonly TYPE_BACK_FORWARD: number;\n readonly TYPE_NAVIGATE: number;\n readonly TYPE_RELOAD: number;\n readonly TYPE_RESERVED: number;\n}\n\ninterface PerformanceNavigationTiming extends PerformanceEntry {\n readonly connectEnd: number;\n readonly connectStart: number;\n readonly domComplete: number;\n readonly domContentLoadedEventEnd: number;\n readonly domContentLoadedEventStart: number;\n readonly domInteractive: number;\n readonly domLoading: number;\n readonly domainLookupEnd: number;\n readonly domainLookupStart: number;\n readonly fetchStart: number;\n readonly loadEventEnd: number;\n readonly loadEventStart: number;\n readonly navigationStart: number;\n readonly redirectCount: number;\n readonly redirectEnd: number;\n readonly redirectStart: number;\n readonly requestStart: number;\n readonly responseEnd: number;\n readonly responseStart: number;\n readonly type: NavigationType;\n readonly unloadEventEnd: number;\n readonly unloadEventStart: number;\n}\n\ndeclare var PerformanceNavigationTiming: {\n prototype: PerformanceNavigationTiming;\n new(): PerformanceNavigationTiming;\n}\n\ninterface PerformanceResourceTiming extends PerformanceEntry {\n readonly connectEnd: number;\n readonly connectStart: number;\n readonly domainLookupEnd: number;\n readonly domainLookupStart: number;\n readonly fetchStart: number;\n readonly initiatorType: string;\n readonly redirectEnd: number;\n readonly redirectStart: number;\n readonly requestStart: number;\n readonly responseEnd: number;\n readonly responseStart: number;\n}\n\ndeclare var PerformanceResourceTiming: {\n prototype: PerformanceResourceTiming;\n new(): PerformanceResourceTiming;\n}\n\ninterface PerformanceTiming {\n readonly connectEnd: number;\n readonly connectStart: number;\n readonly domComplete: number;\n readonly domContentLoadedEventEnd: number;\n readonly domContentLoadedEventStart: number;\n readonly domInteractive: number;\n readonly domLoading: number;\n readonly domainLookupEnd: number;\n readonly domainLookupStart: number;\n readonly fetchStart: number;\n readonly loadEventEnd: number;\n readonly loadEventStart: number;\n readonly msFirstPaint: number;\n readonly navigationStart: number;\n readonly redirectEnd: number;\n readonly redirectStart: number;\n readonly requestStart: number;\n readonly responseEnd: number;\n readonly responseStart: number;\n readonly unloadEventEnd: number;\n readonly unloadEventStart: number;\n readonly secureConnectionStart: number;\n toJSON(): any;\n}\n\ndeclare var PerformanceTiming: {\n prototype: PerformanceTiming;\n new(): PerformanceTiming;\n}\n\ninterface PeriodicWave {\n}\n\ndeclare var PeriodicWave: {\n prototype: PeriodicWave;\n new(): PeriodicWave;\n}\n\ninterface PermissionRequest extends DeferredPermissionRequest {\n readonly state: MSWebViewPermissionState;\n defer(): void;\n}\n\ndeclare var PermissionRequest: {\n prototype: PermissionRequest;\n new(): PermissionRequest;\n}\n\ninterface PermissionRequestedEvent extends Event {\n readonly permissionRequest: PermissionRequest;\n}\n\ndeclare var PermissionRequestedEvent: {\n prototype: PermissionRequestedEvent;\n new(): PermissionRequestedEvent;\n}\n\ninterface Plugin {\n readonly description: string;\n readonly filename: string;\n readonly length: number;\n readonly name: string;\n readonly version: string;\n item(index: number): MimeType;\n namedItem(type: string): MimeType;\n [index: number]: MimeType;\n}\n\ndeclare var Plugin: {\n prototype: Plugin;\n new(): Plugin;\n}\n\ninterface PluginArray {\n readonly length: number;\n item(index: number): Plugin;\n namedItem(name: string): Plugin;\n refresh(reload?: boolean): void;\n [index: number]: Plugin;\n}\n\ndeclare var PluginArray: {\n prototype: PluginArray;\n new(): PluginArray;\n}\n\ninterface PointerEvent extends MouseEvent {\n readonly currentPoint: any;\n readonly height: number;\n readonly hwTimestamp: number;\n readonly intermediatePoints: any;\n readonly isPrimary: boolean;\n readonly pointerId: number;\n readonly pointerType: any;\n readonly pressure: number;\n readonly rotation: number;\n readonly tiltX: number;\n readonly tiltY: number;\n readonly width: number;\n getCurrentPoint(element: Element): void;\n getIntermediatePoints(element: Element): void;\n initPointerEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget, offsetXArg: number, offsetYArg: number, widthArg: number, heightArg: number, pressure: number, rotation: number, tiltX: number, tiltY: number, pointerIdArg: number, pointerType: any, hwTimestampArg: number, isPrimary: boolean): void;\n}\n\ndeclare var PointerEvent: {\n prototype: PointerEvent;\n new(typeArg: string, eventInitDict?: PointerEventInit): PointerEvent;\n}\n\ninterface PopStateEvent extends Event {\n readonly state: any;\n initPopStateEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, stateArg: any): void;\n}\n\ndeclare var PopStateEvent: {\n prototype: PopStateEvent;\n new(typeArg: string, eventInitDict?: PopStateEventInit): PopStateEvent;\n}\n\ninterface Position {\n readonly coords: Coordinates;\n readonly timestamp: number;\n}\n\ndeclare var Position: {\n prototype: Position;\n new(): Position;\n}\n\ninterface PositionError {\n readonly code: number;\n readonly message: string;\n toString(): string;\n readonly PERMISSION_DENIED: number;\n readonly POSITION_UNAVAILABLE: number;\n readonly TIMEOUT: number;\n}\n\ndeclare var PositionError: {\n prototype: PositionError;\n new(): PositionError;\n readonly PERMISSION_DENIED: number;\n readonly POSITION_UNAVAILABLE: number;\n readonly TIMEOUT: number;\n}\n\ninterface ProcessingInstruction extends CharacterData {\n readonly target: string;\n}\n\ndeclare var ProcessingInstruction: {\n prototype: ProcessingInstruction;\n new(): ProcessingInstruction;\n}\n\ninterface ProgressEvent extends Event {\n readonly lengthComputable: boolean;\n readonly loaded: number;\n readonly total: number;\n initProgressEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, lengthComputableArg: boolean, loadedArg: number, totalArg: number): void;\n}\n\ndeclare var ProgressEvent: {\n prototype: ProgressEvent;\n new(type: string, eventInitDict?: ProgressEventInit): ProgressEvent;\n}\n\ninterface PushManager {\n getSubscription(): Promise;\n permissionState(options?: PushSubscriptionOptionsInit): Promise;\n subscribe(options?: PushSubscriptionOptionsInit): Promise;\n}\n\ndeclare var PushManager: {\n prototype: PushManager;\n new(): PushManager;\n}\n\ninterface PushSubscription {\n readonly endpoint: USVString;\n readonly options: PushSubscriptionOptions;\n getKey(name: PushEncryptionKeyName): ArrayBuffer | null;\n toJSON(): any;\n unsubscribe(): Promise;\n}\n\ndeclare var PushSubscription: {\n prototype: PushSubscription;\n new(): PushSubscription;\n}\n\ninterface PushSubscriptionOptions {\n readonly applicationServerKey: ArrayBuffer | null;\n readonly userVisibleOnly: boolean;\n}\n\ndeclare var PushSubscriptionOptions: {\n prototype: PushSubscriptionOptions;\n new(): PushSubscriptionOptions;\n}\n\ninterface RTCDTMFToneChangeEvent extends Event {\n readonly tone: string;\n}\n\ndeclare var RTCDTMFToneChangeEvent: {\n prototype: RTCDTMFToneChangeEvent;\n new(typeArg: string, eventInitDict: RTCDTMFToneChangeEventInit): RTCDTMFToneChangeEvent;\n}\n\ninterface RTCDtlsTransportEventMap {\n \"dtlsstatechange\": RTCDtlsTransportStateChangedEvent;\n \"error\": Event;\n}\n\ninterface RTCDtlsTransport extends RTCStatsProvider {\n ondtlsstatechange: ((this: RTCDtlsTransport, ev: RTCDtlsTransportStateChangedEvent) => any) | null;\n onerror: ((this: RTCDtlsTransport, ev: Event) => any) | null;\n readonly state: RTCDtlsTransportState;\n readonly transport: RTCIceTransport;\n getLocalParameters(): RTCDtlsParameters;\n getRemoteCertificates(): ArrayBuffer[];\n getRemoteParameters(): RTCDtlsParameters | null;\n start(remoteParameters: RTCDtlsParameters): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCDtlsTransport, ev: RTCDtlsTransportEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCDtlsTransport: {\n prototype: RTCDtlsTransport;\n new(transport: RTCIceTransport): RTCDtlsTransport;\n}\n\ninterface RTCDtlsTransportStateChangedEvent extends Event {\n readonly state: RTCDtlsTransportState;\n}\n\ndeclare var RTCDtlsTransportStateChangedEvent: {\n prototype: RTCDtlsTransportStateChangedEvent;\n new(): RTCDtlsTransportStateChangedEvent;\n}\n\ninterface RTCDtmfSenderEventMap {\n \"tonechange\": RTCDTMFToneChangeEvent;\n}\n\ninterface RTCDtmfSender extends EventTarget {\n readonly canInsertDTMF: boolean;\n readonly duration: number;\n readonly interToneGap: number;\n ontonechange: (this: RTCDtmfSender, ev: RTCDTMFToneChangeEvent) => any;\n readonly sender: RTCRtpSender;\n readonly toneBuffer: string;\n insertDTMF(tones: string, duration?: number, interToneGap?: number): void;\n addEventListener(type: K, listener: (this: RTCDtmfSender, ev: RTCDtmfSenderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCDtmfSender: {\n prototype: RTCDtmfSender;\n new(sender: RTCRtpSender): RTCDtmfSender;\n}\n\ninterface RTCIceCandidate {\n candidate: string | null;\n sdpMLineIndex: number | null;\n sdpMid: string | null;\n toJSON(): any;\n}\n\ndeclare var RTCIceCandidate: {\n prototype: RTCIceCandidate;\n new(candidateInitDict?: RTCIceCandidateInit): RTCIceCandidate;\n}\n\ninterface RTCIceCandidatePairChangedEvent extends Event {\n readonly pair: RTCIceCandidatePair;\n}\n\ndeclare var RTCIceCandidatePairChangedEvent: {\n prototype: RTCIceCandidatePairChangedEvent;\n new(): RTCIceCandidatePairChangedEvent;\n}\n\ninterface RTCIceGathererEventMap {\n \"error\": Event;\n \"localcandidate\": RTCIceGathererEvent;\n}\n\ninterface RTCIceGatherer extends RTCStatsProvider {\n readonly component: RTCIceComponent;\n onerror: ((this: RTCIceGatherer, ev: Event) => any) | null;\n onlocalcandidate: ((this: RTCIceGatherer, ev: RTCIceGathererEvent) => any) | null;\n createAssociatedGatherer(): RTCIceGatherer;\n getLocalCandidates(): RTCIceCandidateDictionary[];\n getLocalParameters(): RTCIceParameters;\n addEventListener(type: K, listener: (this: RTCIceGatherer, ev: RTCIceGathererEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCIceGatherer: {\n prototype: RTCIceGatherer;\n new(options: RTCIceGatherOptions): RTCIceGatherer;\n}\n\ninterface RTCIceGathererEvent extends Event {\n readonly candidate: RTCIceCandidateDictionary | RTCIceCandidateComplete;\n}\n\ndeclare var RTCIceGathererEvent: {\n prototype: RTCIceGathererEvent;\n new(): RTCIceGathererEvent;\n}\n\ninterface RTCIceTransportEventMap {\n \"candidatepairchange\": RTCIceCandidatePairChangedEvent;\n \"icestatechange\": RTCIceTransportStateChangedEvent;\n}\n\ninterface RTCIceTransport extends RTCStatsProvider {\n readonly component: RTCIceComponent;\n readonly iceGatherer: RTCIceGatherer | null;\n oncandidatepairchange: ((this: RTCIceTransport, ev: RTCIceCandidatePairChangedEvent) => any) | null;\n onicestatechange: ((this: RTCIceTransport, ev: RTCIceTransportStateChangedEvent) => any) | null;\n readonly role: RTCIceRole;\n readonly state: RTCIceTransportState;\n addRemoteCandidate(remoteCandidate: RTCIceCandidateDictionary | RTCIceCandidateComplete): void;\n createAssociatedTransport(): RTCIceTransport;\n getNominatedCandidatePair(): RTCIceCandidatePair | null;\n getRemoteCandidates(): RTCIceCandidateDictionary[];\n getRemoteParameters(): RTCIceParameters | null;\n setRemoteCandidates(remoteCandidates: RTCIceCandidateDictionary[]): void;\n start(gatherer: RTCIceGatherer, remoteParameters: RTCIceParameters, role?: RTCIceRole): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCIceTransport, ev: RTCIceTransportEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCIceTransport: {\n prototype: RTCIceTransport;\n new(): RTCIceTransport;\n}\n\ninterface RTCIceTransportStateChangedEvent extends Event {\n readonly state: RTCIceTransportState;\n}\n\ndeclare var RTCIceTransportStateChangedEvent: {\n prototype: RTCIceTransportStateChangedEvent;\n new(): RTCIceTransportStateChangedEvent;\n}\n\ninterface RTCPeerConnectionEventMap {\n \"addstream\": MediaStreamEvent;\n \"icecandidate\": RTCPeerConnectionIceEvent;\n \"iceconnectionstatechange\": Event;\n \"icegatheringstatechange\": Event;\n \"negotiationneeded\": Event;\n \"removestream\": MediaStreamEvent;\n \"signalingstatechange\": Event;\n}\n\ninterface RTCPeerConnection extends EventTarget {\n readonly canTrickleIceCandidates: boolean | null;\n readonly iceConnectionState: RTCIceConnectionState;\n readonly iceGatheringState: RTCIceGatheringState;\n readonly localDescription: RTCSessionDescription | null;\n onaddstream: (this: RTCPeerConnection, ev: MediaStreamEvent) => any;\n onicecandidate: (this: RTCPeerConnection, ev: RTCPeerConnectionIceEvent) => any;\n oniceconnectionstatechange: (this: RTCPeerConnection, ev: Event) => any;\n onicegatheringstatechange: (this: RTCPeerConnection, ev: Event) => any;\n onnegotiationneeded: (this: RTCPeerConnection, ev: Event) => any;\n onremovestream: (this: RTCPeerConnection, ev: MediaStreamEvent) => any;\n onsignalingstatechange: (this: RTCPeerConnection, ev: Event) => any;\n readonly remoteDescription: RTCSessionDescription | null;\n readonly signalingState: RTCSignalingState;\n addIceCandidate(candidate: RTCIceCandidate, successCallback?: VoidFunction, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n addStream(stream: MediaStream): void;\n close(): void;\n createAnswer(successCallback?: RTCSessionDescriptionCallback, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n createOffer(successCallback?: RTCSessionDescriptionCallback, failureCallback?: RTCPeerConnectionErrorCallback, options?: RTCOfferOptions): Promise;\n getConfiguration(): RTCConfiguration;\n getLocalStreams(): MediaStream[];\n getRemoteStreams(): MediaStream[];\n getStats(selector: MediaStreamTrack | null, successCallback?: RTCStatsCallback, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n getStreamById(streamId: string): MediaStream | null;\n removeStream(stream: MediaStream): void;\n setLocalDescription(description: RTCSessionDescription, successCallback?: VoidFunction, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n setRemoteDescription(description: RTCSessionDescription, successCallback?: VoidFunction, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n addEventListener(type: K, listener: (this: RTCPeerConnection, ev: RTCPeerConnectionEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCPeerConnection: {\n prototype: RTCPeerConnection;\n new(configuration: RTCConfiguration): RTCPeerConnection;\n}\n\ninterface RTCPeerConnectionIceEvent extends Event {\n readonly candidate: RTCIceCandidate;\n}\n\ndeclare var RTCPeerConnectionIceEvent: {\n prototype: RTCPeerConnectionIceEvent;\n new(type: string, eventInitDict: RTCPeerConnectionIceEventInit): RTCPeerConnectionIceEvent;\n}\n\ninterface RTCRtpReceiverEventMap {\n \"error\": Event;\n}\n\ninterface RTCRtpReceiver extends RTCStatsProvider {\n onerror: ((this: RTCRtpReceiver, ev: Event) => any) | null;\n readonly rtcpTransport: RTCDtlsTransport;\n readonly track: MediaStreamTrack | null;\n readonly transport: RTCDtlsTransport | RTCSrtpSdesTransport;\n getContributingSources(): RTCRtpContributingSource[];\n receive(parameters: RTCRtpParameters): void;\n requestSendCSRC(csrc: number): void;\n setTransport(transport: RTCDtlsTransport | RTCSrtpSdesTransport, rtcpTransport?: RTCDtlsTransport): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCRtpReceiver, ev: RTCRtpReceiverEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCRtpReceiver: {\n prototype: RTCRtpReceiver;\n new(transport: RTCDtlsTransport | RTCSrtpSdesTransport, kind: string, rtcpTransport?: RTCDtlsTransport): RTCRtpReceiver;\n getCapabilities(kind?: string): RTCRtpCapabilities;\n}\n\ninterface RTCRtpSenderEventMap {\n \"error\": Event;\n \"ssrcconflict\": RTCSsrcConflictEvent;\n}\n\ninterface RTCRtpSender extends RTCStatsProvider {\n onerror: ((this: RTCRtpSender, ev: Event) => any) | null;\n onssrcconflict: ((this: RTCRtpSender, ev: RTCSsrcConflictEvent) => any) | null;\n readonly rtcpTransport: RTCDtlsTransport;\n readonly track: MediaStreamTrack;\n readonly transport: RTCDtlsTransport | RTCSrtpSdesTransport;\n send(parameters: RTCRtpParameters): void;\n setTrack(track: MediaStreamTrack): void;\n setTransport(transport: RTCDtlsTransport | RTCSrtpSdesTransport, rtcpTransport?: RTCDtlsTransport): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCRtpSender, ev: RTCRtpSenderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCRtpSender: {\n prototype: RTCRtpSender;\n new(track: MediaStreamTrack, transport: RTCDtlsTransport | RTCSrtpSdesTransport, rtcpTransport?: RTCDtlsTransport): RTCRtpSender;\n getCapabilities(kind?: string): RTCRtpCapabilities;\n}\n\ninterface RTCSessionDescription {\n sdp: string | null;\n type: RTCSdpType | null;\n toJSON(): any;\n}\n\ndeclare var RTCSessionDescription: {\n prototype: RTCSessionDescription;\n new(descriptionInitDict?: RTCSessionDescriptionInit): RTCSessionDescription;\n}\n\ninterface RTCSrtpSdesTransportEventMap {\n \"error\": Event;\n}\n\ninterface RTCSrtpSdesTransport extends EventTarget {\n onerror: ((this: RTCSrtpSdesTransport, ev: Event) => any) | null;\n readonly transport: RTCIceTransport;\n addEventListener(type: K, listener: (this: RTCSrtpSdesTransport, ev: RTCSrtpSdesTransportEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCSrtpSdesTransport: {\n prototype: RTCSrtpSdesTransport;\n new(transport: RTCIceTransport, encryptParameters: RTCSrtpSdesParameters, decryptParameters: RTCSrtpSdesParameters): RTCSrtpSdesTransport;\n getLocalParameters(): RTCSrtpSdesParameters[];\n}\n\ninterface RTCSsrcConflictEvent extends Event {\n readonly ssrc: number;\n}\n\ndeclare var RTCSsrcConflictEvent: {\n prototype: RTCSsrcConflictEvent;\n new(): RTCSsrcConflictEvent;\n}\n\ninterface RTCStatsProvider extends EventTarget {\n getStats(): Promise;\n msGetStats(): Promise;\n}\n\ndeclare var RTCStatsProvider: {\n prototype: RTCStatsProvider;\n new(): RTCStatsProvider;\n}\n\ninterface Range {\n readonly collapsed: boolean;\n readonly commonAncestorContainer: Node;\n readonly endContainer: Node;\n readonly endOffset: number;\n readonly startContainer: Node;\n readonly startOffset: number;\n cloneContents(): DocumentFragment;\n cloneRange(): Range;\n collapse(toStart: boolean): void;\n compareBoundaryPoints(how: number, sourceRange: Range): number;\n createContextualFragment(fragment: string): DocumentFragment;\n deleteContents(): void;\n detach(): void;\n expand(Unit: ExpandGranularity): boolean;\n extractContents(): DocumentFragment;\n getBoundingClientRect(): ClientRect;\n getClientRects(): ClientRectList;\n insertNode(newNode: Node): void;\n selectNode(refNode: Node): void;\n selectNodeContents(refNode: Node): void;\n setEnd(refNode: Node, offset: number): void;\n setEndAfter(refNode: Node): void;\n setEndBefore(refNode: Node): void;\n setStart(refNode: Node, offset: number): void;\n setStartAfter(refNode: Node): void;\n setStartBefore(refNode: Node): void;\n surroundContents(newParent: Node): void;\n toString(): string;\n readonly END_TO_END: number;\n readonly END_TO_START: number;\n readonly START_TO_END: number;\n readonly START_TO_START: number;\n}\n\ndeclare var Range: {\n prototype: Range;\n new(): Range;\n readonly END_TO_END: number;\n readonly END_TO_START: number;\n readonly START_TO_END: number;\n readonly START_TO_START: number;\n}\n\ninterface ReadableStream {\n readonly locked: boolean;\n cancel(): Promise;\n getReader(): ReadableStreamReader;\n}\n\ndeclare var ReadableStream: {\n prototype: ReadableStream;\n new(): ReadableStream;\n}\n\ninterface ReadableStreamReader {\n cancel(): Promise;\n read(): Promise;\n releaseLock(): void;\n}\n\ndeclare var ReadableStreamReader: {\n prototype: ReadableStreamReader;\n new(): ReadableStreamReader;\n}\n\ninterface Request extends Object, Body {\n readonly cache: RequestCache;\n readonly credentials: RequestCredentials;\n readonly destination: RequestDestination;\n readonly headers: Headers;\n readonly integrity: string;\n readonly keepalive: boolean;\n readonly method: string;\n readonly mode: RequestMode;\n readonly redirect: RequestRedirect;\n readonly referrer: string;\n readonly referrerPolicy: ReferrerPolicy;\n readonly type: RequestType;\n readonly url: string;\n clone(): Request;\n}\n\ndeclare var Request: {\n prototype: Request;\n new(input: Request | string, init?: RequestInit): Request;\n}\n\ninterface Response extends Object, Body {\n readonly body: ReadableStream | null;\n readonly headers: Headers;\n readonly ok: boolean;\n readonly status: number;\n readonly statusText: string;\n readonly type: ResponseType;\n readonly url: string;\n clone(): Response;\n}\n\ndeclare var Response: {\n prototype: Response;\n new(body?: any, init?: ResponseInit): Response;\n}\n\ninterface SVGAElement extends SVGGraphicsElement, SVGURIReference {\n readonly target: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGAElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGAElement: {\n prototype: SVGAElement;\n new(): SVGAElement;\n}\n\ninterface SVGAngle {\n readonly unitType: number;\n value: number;\n valueAsString: string;\n valueInSpecifiedUnits: number;\n convertToSpecifiedUnits(unitType: number): void;\n newValueSpecifiedUnits(unitType: number, valueInSpecifiedUnits: number): void;\n readonly SVG_ANGLETYPE_DEG: number;\n readonly SVG_ANGLETYPE_GRAD: number;\n readonly SVG_ANGLETYPE_RAD: number;\n readonly SVG_ANGLETYPE_UNKNOWN: number;\n readonly SVG_ANGLETYPE_UNSPECIFIED: number;\n}\n\ndeclare var SVGAngle: {\n prototype: SVGAngle;\n new(): SVGAngle;\n readonly SVG_ANGLETYPE_DEG: number;\n readonly SVG_ANGLETYPE_GRAD: number;\n readonly SVG_ANGLETYPE_RAD: number;\n readonly SVG_ANGLETYPE_UNKNOWN: number;\n readonly SVG_ANGLETYPE_UNSPECIFIED: number;\n}\n\ninterface SVGAnimatedAngle {\n readonly animVal: SVGAngle;\n readonly baseVal: SVGAngle;\n}\n\ndeclare var SVGAnimatedAngle: {\n prototype: SVGAnimatedAngle;\n new(): SVGAnimatedAngle;\n}\n\ninterface SVGAnimatedBoolean {\n readonly animVal: boolean;\n baseVal: boolean;\n}\n\ndeclare var SVGAnimatedBoolean: {\n prototype: SVGAnimatedBoolean;\n new(): SVGAnimatedBoolean;\n}\n\ninterface SVGAnimatedEnumeration {\n readonly animVal: number;\n baseVal: number;\n}\n\ndeclare var SVGAnimatedEnumeration: {\n prototype: SVGAnimatedEnumeration;\n new(): SVGAnimatedEnumeration;\n}\n\ninterface SVGAnimatedInteger {\n readonly animVal: number;\n baseVal: number;\n}\n\ndeclare var SVGAnimatedInteger: {\n prototype: SVGAnimatedInteger;\n new(): SVGAnimatedInteger;\n}\n\ninterface SVGAnimatedLength {\n readonly animVal: SVGLength;\n readonly baseVal: SVGLength;\n}\n\ndeclare var SVGAnimatedLength: {\n prototype: SVGAnimatedLength;\n new(): SVGAnimatedLength;\n}\n\ninterface SVGAnimatedLengthList {\n readonly animVal: SVGLengthList;\n readonly baseVal: SVGLengthList;\n}\n\ndeclare var SVGAnimatedLengthList: {\n prototype: SVGAnimatedLengthList;\n new(): SVGAnimatedLengthList;\n}\n\ninterface SVGAnimatedNumber {\n readonly animVal: number;\n baseVal: number;\n}\n\ndeclare var SVGAnimatedNumber: {\n prototype: SVGAnimatedNumber;\n new(): SVGAnimatedNumber;\n}\n\ninterface SVGAnimatedNumberList {\n readonly animVal: SVGNumberList;\n readonly baseVal: SVGNumberList;\n}\n\ndeclare var SVGAnimatedNumberList: {\n prototype: SVGAnimatedNumberList;\n new(): SVGAnimatedNumberList;\n}\n\ninterface SVGAnimatedPreserveAspectRatio {\n readonly animVal: SVGPreserveAspectRatio;\n readonly baseVal: SVGPreserveAspectRatio;\n}\n\ndeclare var SVGAnimatedPreserveAspectRatio: {\n prototype: SVGAnimatedPreserveAspectRatio;\n new(): SVGAnimatedPreserveAspectRatio;\n}\n\ninterface SVGAnimatedRect {\n readonly animVal: SVGRect;\n readonly baseVal: SVGRect;\n}\n\ndeclare var SVGAnimatedRect: {\n prototype: SVGAnimatedRect;\n new(): SVGAnimatedRect;\n}\n\ninterface SVGAnimatedString {\n readonly animVal: string;\n baseVal: string;\n}\n\ndeclare var SVGAnimatedString: {\n prototype: SVGAnimatedString;\n new(): SVGAnimatedString;\n}\n\ninterface SVGAnimatedTransformList {\n readonly animVal: SVGTransformList;\n readonly baseVal: SVGTransformList;\n}\n\ndeclare var SVGAnimatedTransformList: {\n prototype: SVGAnimatedTransformList;\n new(): SVGAnimatedTransformList;\n}\n\ninterface SVGCircleElement extends SVGGraphicsElement {\n readonly cx: SVGAnimatedLength;\n readonly cy: SVGAnimatedLength;\n readonly r: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGCircleElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGCircleElement: {\n prototype: SVGCircleElement;\n new(): SVGCircleElement;\n}\n\ninterface SVGClipPathElement extends SVGGraphicsElement, SVGUnitTypes {\n readonly clipPathUnits: SVGAnimatedEnumeration;\n addEventListener(type: K, listener: (this: SVGClipPathElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGClipPathElement: {\n prototype: SVGClipPathElement;\n new(): SVGClipPathElement;\n}\n\ninterface SVGComponentTransferFunctionElement extends SVGElement {\n readonly amplitude: SVGAnimatedNumber;\n readonly exponent: SVGAnimatedNumber;\n readonly intercept: SVGAnimatedNumber;\n readonly offset: SVGAnimatedNumber;\n readonly slope: SVGAnimatedNumber;\n readonly tableValues: SVGAnimatedNumberList;\n readonly type: SVGAnimatedEnumeration;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_DISCRETE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_GAMMA: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_IDENTITY: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_LINEAR: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_TABLE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGComponentTransferFunctionElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGComponentTransferFunctionElement: {\n prototype: SVGComponentTransferFunctionElement;\n new(): SVGComponentTransferFunctionElement;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_DISCRETE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_GAMMA: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_IDENTITY: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_LINEAR: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_TABLE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_UNKNOWN: number;\n}\n\ninterface SVGDefsElement extends SVGGraphicsElement {\n addEventListener(type: K, listener: (this: SVGDefsElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGDefsElement: {\n prototype: SVGDefsElement;\n new(): SVGDefsElement;\n}\n\ninterface SVGDescElement extends SVGElement {\n addEventListener(type: K, listener: (this: SVGDescElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGDescElement: {\n prototype: SVGDescElement;\n new(): SVGDescElement;\n}\n\ninterface SVGElementEventMap extends ElementEventMap {\n \"click\": MouseEvent;\n \"dblclick\": MouseEvent;\n \"focusin\": FocusEvent;\n \"focusout\": FocusEvent;\n \"load\": Event;\n \"mousedown\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n}\n\ninterface SVGElement extends Element {\n className: any;\n onclick: (this: SVGElement, ev: MouseEvent) => any;\n ondblclick: (this: SVGElement, ev: MouseEvent) => any;\n onfocusin: (this: SVGElement, ev: FocusEvent) => any;\n onfocusout: (this: SVGElement, ev: FocusEvent) => any;\n onload: (this: SVGElement, ev: Event) => any;\n onmousedown: (this: SVGElement, ev: MouseEvent) => any;\n onmousemove: (this: SVGElement, ev: MouseEvent) => any;\n onmouseout: (this: SVGElement, ev: MouseEvent) => any;\n onmouseover: (this: SVGElement, ev: MouseEvent) => any;\n onmouseup: (this: SVGElement, ev: MouseEvent) => any;\n readonly ownerSVGElement: SVGSVGElement;\n readonly style: CSSStyleDeclaration;\n readonly viewportElement: SVGElement;\n xmlbase: string;\n addEventListener(type: K, listener: (this: SVGElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGElement: {\n prototype: SVGElement;\n new(): SVGElement;\n}\n\ninterface SVGElementInstance extends EventTarget {\n readonly childNodes: SVGElementInstanceList;\n readonly correspondingElement: SVGElement;\n readonly correspondingUseElement: SVGUseElement;\n readonly firstChild: SVGElementInstance;\n readonly lastChild: SVGElementInstance;\n readonly nextSibling: SVGElementInstance;\n readonly parentNode: SVGElementInstance;\n readonly previousSibling: SVGElementInstance;\n}\n\ndeclare var SVGElementInstance: {\n prototype: SVGElementInstance;\n new(): SVGElementInstance;\n}\n\ninterface SVGElementInstanceList {\n readonly length: number;\n item(index: number): SVGElementInstance;\n}\n\ndeclare var SVGElementInstanceList: {\n prototype: SVGElementInstanceList;\n new(): SVGElementInstanceList;\n}\n\ninterface SVGEllipseElement extends SVGGraphicsElement {\n readonly cx: SVGAnimatedLength;\n readonly cy: SVGAnimatedLength;\n readonly rx: SVGAnimatedLength;\n readonly ry: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGEllipseElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGEllipseElement: {\n prototype: SVGEllipseElement;\n new(): SVGEllipseElement;\n}\n\ninterface SVGFEBlendElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly in2: SVGAnimatedString;\n readonly mode: SVGAnimatedEnumeration;\n readonly SVG_FEBLEND_MODE_COLOR: number;\n readonly SVG_FEBLEND_MODE_COLOR_BURN: number;\n readonly SVG_FEBLEND_MODE_COLOR_DODGE: number;\n readonly SVG_FEBLEND_MODE_DARKEN: number;\n readonly SVG_FEBLEND_MODE_DIFFERENCE: number;\n readonly SVG_FEBLEND_MODE_EXCLUSION: number;\n readonly SVG_FEBLEND_MODE_HARD_LIGHT: number;\n readonly SVG_FEBLEND_MODE_HUE: number;\n readonly SVG_FEBLEND_MODE_LIGHTEN: number;\n readonly SVG_FEBLEND_MODE_LUMINOSITY: number;\n readonly SVG_FEBLEND_MODE_MULTIPLY: number;\n readonly SVG_FEBLEND_MODE_NORMAL: number;\n readonly SVG_FEBLEND_MODE_OVERLAY: number;\n readonly SVG_FEBLEND_MODE_SATURATION: number;\n readonly SVG_FEBLEND_MODE_SCREEN: number;\n readonly SVG_FEBLEND_MODE_SOFT_LIGHT: number;\n readonly SVG_FEBLEND_MODE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEBlendElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEBlendElement: {\n prototype: SVGFEBlendElement;\n new(): SVGFEBlendElement;\n readonly SVG_FEBLEND_MODE_COLOR: number;\n readonly SVG_FEBLEND_MODE_COLOR_BURN: number;\n readonly SVG_FEBLEND_MODE_COLOR_DODGE: number;\n readonly SVG_FEBLEND_MODE_DARKEN: number;\n readonly SVG_FEBLEND_MODE_DIFFERENCE: number;\n readonly SVG_FEBLEND_MODE_EXCLUSION: number;\n readonly SVG_FEBLEND_MODE_HARD_LIGHT: number;\n readonly SVG_FEBLEND_MODE_HUE: number;\n readonly SVG_FEBLEND_MODE_LIGHTEN: number;\n readonly SVG_FEBLEND_MODE_LUMINOSITY: number;\n readonly SVG_FEBLEND_MODE_MULTIPLY: number;\n readonly SVG_FEBLEND_MODE_NORMAL: number;\n readonly SVG_FEBLEND_MODE_OVERLAY: number;\n readonly SVG_FEBLEND_MODE_SATURATION: number;\n readonly SVG_FEBLEND_MODE_SCREEN: number;\n readonly SVG_FEBLEND_MODE_SOFT_LIGHT: number;\n readonly SVG_FEBLEND_MODE_UNKNOWN: number;\n}\n\ninterface SVGFEColorMatrixElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly type: SVGAnimatedEnumeration;\n readonly values: SVGAnimatedNumberList;\n readonly SVG_FECOLORMATRIX_TYPE_HUEROTATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_LUMINANCETOALPHA: number;\n readonly SVG_FECOLORMATRIX_TYPE_MATRIX: number;\n readonly SVG_FECOLORMATRIX_TYPE_SATURATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEColorMatrixElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEColorMatrixElement: {\n prototype: SVGFEColorMatrixElement;\n new(): SVGFEColorMatrixElement;\n readonly SVG_FECOLORMATRIX_TYPE_HUEROTATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_LUMINANCETOALPHA: number;\n readonly SVG_FECOLORMATRIX_TYPE_MATRIX: number;\n readonly SVG_FECOLORMATRIX_TYPE_SATURATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_UNKNOWN: number;\n}\n\ninterface SVGFEComponentTransferElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFEComponentTransferElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEComponentTransferElement: {\n prototype: SVGFEComponentTransferElement;\n new(): SVGFEComponentTransferElement;\n}\n\ninterface SVGFECompositeElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly in2: SVGAnimatedString;\n readonly k1: SVGAnimatedNumber;\n readonly k2: SVGAnimatedNumber;\n readonly k3: SVGAnimatedNumber;\n readonly k4: SVGAnimatedNumber;\n readonly operator: SVGAnimatedEnumeration;\n readonly SVG_FECOMPOSITE_OPERATOR_ARITHMETIC: number;\n readonly SVG_FECOMPOSITE_OPERATOR_ATOP: number;\n readonly SVG_FECOMPOSITE_OPERATOR_IN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OUT: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OVER: number;\n readonly SVG_FECOMPOSITE_OPERATOR_UNKNOWN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_XOR: number;\n addEventListener(type: K, listener: (this: SVGFECompositeElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFECompositeElement: {\n prototype: SVGFECompositeElement;\n new(): SVGFECompositeElement;\n readonly SVG_FECOMPOSITE_OPERATOR_ARITHMETIC: number;\n readonly SVG_FECOMPOSITE_OPERATOR_ATOP: number;\n readonly SVG_FECOMPOSITE_OPERATOR_IN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OUT: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OVER: number;\n readonly SVG_FECOMPOSITE_OPERATOR_UNKNOWN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_XOR: number;\n}\n\ninterface SVGFEConvolveMatrixElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly bias: SVGAnimatedNumber;\n readonly divisor: SVGAnimatedNumber;\n readonly edgeMode: SVGAnimatedEnumeration;\n readonly in1: SVGAnimatedString;\n readonly kernelMatrix: SVGAnimatedNumberList;\n readonly kernelUnitLengthX: SVGAnimatedNumber;\n readonly kernelUnitLengthY: SVGAnimatedNumber;\n readonly orderX: SVGAnimatedInteger;\n readonly orderY: SVGAnimatedInteger;\n readonly preserveAlpha: SVGAnimatedBoolean;\n readonly targetX: SVGAnimatedInteger;\n readonly targetY: SVGAnimatedInteger;\n readonly SVG_EDGEMODE_DUPLICATE: number;\n readonly SVG_EDGEMODE_NONE: number;\n readonly SVG_EDGEMODE_UNKNOWN: number;\n readonly SVG_EDGEMODE_WRAP: number;\n addEventListener(type: K, listener: (this: SVGFEConvolveMatrixElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEConvolveMatrixElement: {\n prototype: SVGFEConvolveMatrixElement;\n new(): SVGFEConvolveMatrixElement;\n readonly SVG_EDGEMODE_DUPLICATE: number;\n readonly SVG_EDGEMODE_NONE: number;\n readonly SVG_EDGEMODE_UNKNOWN: number;\n readonly SVG_EDGEMODE_WRAP: number;\n}\n\ninterface SVGFEDiffuseLightingElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly diffuseConstant: SVGAnimatedNumber;\n readonly in1: SVGAnimatedString;\n readonly kernelUnitLengthX: SVGAnimatedNumber;\n readonly kernelUnitLengthY: SVGAnimatedNumber;\n readonly surfaceScale: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFEDiffuseLightingElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEDiffuseLightingElement: {\n prototype: SVGFEDiffuseLightingElement;\n new(): SVGFEDiffuseLightingElement;\n}\n\ninterface SVGFEDisplacementMapElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly in2: SVGAnimatedString;\n readonly scale: SVGAnimatedNumber;\n readonly xChannelSelector: SVGAnimatedEnumeration;\n readonly yChannelSelector: SVGAnimatedEnumeration;\n readonly SVG_CHANNEL_A: number;\n readonly SVG_CHANNEL_B: number;\n readonly SVG_CHANNEL_G: number;\n readonly SVG_CHANNEL_R: number;\n readonly SVG_CHANNEL_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEDisplacementMapElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEDisplacementMapElement: {\n prototype: SVGFEDisplacementMapElement;\n new(): SVGFEDisplacementMapElement;\n readonly SVG_CHANNEL_A: number;\n readonly SVG_CHANNEL_B: number;\n readonly SVG_CHANNEL_G: number;\n readonly SVG_CHANNEL_R: number;\n readonly SVG_CHANNEL_UNKNOWN: number;\n}\n\ninterface SVGFEDistantLightElement extends SVGElement {\n readonly azimuth: SVGAnimatedNumber;\n readonly elevation: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFEDistantLightElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEDistantLightElement: {\n prototype: SVGFEDistantLightElement;\n new(): SVGFEDistantLightElement;\n}\n\ninterface SVGFEFloodElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n addEventListener(type: K, listener: (this: SVGFEFloodElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFloodElement: {\n prototype: SVGFEFloodElement;\n new(): SVGFEFloodElement;\n}\n\ninterface SVGFEFuncAElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncAElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncAElement: {\n prototype: SVGFEFuncAElement;\n new(): SVGFEFuncAElement;\n}\n\ninterface SVGFEFuncBElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncBElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncBElement: {\n prototype: SVGFEFuncBElement;\n new(): SVGFEFuncBElement;\n}\n\ninterface SVGFEFuncGElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncGElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncGElement: {\n prototype: SVGFEFuncGElement;\n new(): SVGFEFuncGElement;\n}\n\ninterface SVGFEFuncRElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncRElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncRElement: {\n prototype: SVGFEFuncRElement;\n new(): SVGFEFuncRElement;\n}\n\ninterface SVGFEGaussianBlurElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly stdDeviationX: SVGAnimatedNumber;\n readonly stdDeviationY: SVGAnimatedNumber;\n setStdDeviation(stdDeviationX: number, stdDeviationY: number): void;\n addEventListener(type: K, listener: (this: SVGFEGaussianBlurElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEGaussianBlurElement: {\n prototype: SVGFEGaussianBlurElement;\n new(): SVGFEGaussianBlurElement;\n}\n\ninterface SVGFEImageElement extends SVGElement, SVGFilterPrimitiveStandardAttributes, SVGURIReference {\n readonly preserveAspectRatio: SVGAnimatedPreserveAspectRatio;\n addEventListener(type: K, listener: (this: SVGFEImageElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEImageElement: {\n prototype: SVGFEImageElement;\n new(): SVGFEImageElement;\n}\n\ninterface SVGFEMergeElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n addEventListener(type: K, listener: (this: SVGFEMergeElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEMergeElement: {\n prototype: SVGFEMergeElement;\n new(): SVGFEMergeElement;\n}\n\ninterface SVGFEMergeNodeElement extends SVGElement {\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFEMergeNodeElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEMergeNodeElement: {\n prototype: SVGFEMergeNodeElement;\n new(): SVGFEMergeNodeElement;\n}\n\ninterface SVGFEMorphologyElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly operator: SVGAnimatedEnumeration;\n readonly radiusX: SVGAnimatedNumber;\n readonly radiusY: SVGAnimatedNumber;\n readonly SVG_MORPHOLOGY_OPERATOR_DILATE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_ERODE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEMorphologyElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEMorphologyElement: {\n prototype: SVGFEMorphologyElement;\n new(): SVGFEMorphologyElement;\n readonly SVG_MORPHOLOGY_OPERATOR_DILATE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_ERODE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_UNKNOWN: number;\n}\n\ninterface SVGFEOffsetElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly dx: SVGAnimatedNumber;\n readonly dy: SVGAnimatedNumber;\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFEOffsetElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEOffsetElement: {\n prototype: SVGFEOffsetElement;\n new(): SVGFEOffsetElement;\n}\n\ninterface SVGFEPointLightElement extends SVGElement {\n readonly x: SVGAnimatedNumber;\n readonly y: SVGAnimatedNumber;\n readonly z: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFEPointLightElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEPointLightElement: {\n prototype: SVGFEPointLightElement;\n new(): SVGFEPointLightElement;\n}\n\ninterface SVGFESpecularLightingElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly kernelUnitLengthX: SVGAnimatedNumber;\n readonly kernelUnitLengthY: SVGAnimatedNumber;\n readonly specularConstant: SVGAnimatedNumber;\n readonly specularExponent: SVGAnimatedNumber;\n readonly surfaceScale: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFESpecularLightingElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFESpecularLightingElement: {\n prototype: SVGFESpecularLightingElement;\n new(): SVGFESpecularLightingElement;\n}\n\ninterface SVGFESpotLightElement extends SVGElement {\n readonly limitingConeAngle: SVGAnimatedNumber;\n readonly pointsAtX: SVGAnimatedNumber;\n readonly pointsAtY: SVGAnimatedNumber;\n readonly pointsAtZ: SVGAnimatedNumber;\n readonly specularExponent: SVGAnimatedNumber;\n readonly x: SVGAnimatedNumber;\n readonly y: SVGAnimatedNumber;\n readonly z: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFESpotLightElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFESpotLightElement: {\n prototype: SVGFESpotLightElement;\n new(): SVGFESpotLightElement;\n}\n\ninterface SVGFETileElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFETileElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFETileElement: {\n prototype: SVGFETileElement;\n new(): SVGFETileElement;\n}\n\ninterface SVGFETurbulenceElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly baseFrequencyX: SVGAnimatedNumber;\n readonly baseFrequencyY: SVGAnimatedNumber;\n readonly numOctaves: SVGAnimatedInteger;\n readonly seed: SVGAnimatedNumber;\n readonly stitchTiles: SVGAnimatedEnumeration;\n readonly type: SVGAnimatedEnumeration;\n readonly SVG_STITCHTYPE_NOSTITCH: number;\n readonly SVG_STITCHTYPE_STITCH: number;\n readonly SVG_STITCHTYPE_UNKNOWN: number;\n readonly SVG_TURBULENCE_TYPE_FRACTALNOISE: number;\n readonly SVG_TURBULENCE_TYPE_TURBULENCE: number;\n readonly SVG_TURBULENCE_TYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFETurbulenceElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFETurbulenceElement: {\n prototype: SVGFETurbulenceElement;\n new(): SVGFETurbulenceElement;\n readonly SVG_STITCHTYPE_NOSTITCH: number;\n readonly SVG_STITCHTYPE_STITCH: number;\n readonly SVG_STITCHTYPE_UNKNOWN: number;\n readonly SVG_TURBULENCE_TYPE_FRACTALNOISE: number;\n readonly SVG_TURBULENCE_TYPE_TURBULENCE: number;\n readonly SVG_TURBULENCE_TYPE_UNKNOWN: number;\n}\n\ninterface SVGFilterElement extends SVGElement, SVGUnitTypes, SVGURIReference {\n readonly filterResX: SVGAnimatedInteger;\n readonly filterResY: SVGAnimatedInteger;\n readonly filterUnits: SVGAnimatedEnumeration;\n readonly height: SVGAnimatedLength;\n readonly primitiveUnits: SVGAnimatedEnumeration;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n setFilterRes(filterResX: number, filterResY: number): void;\n addEventListener(type: K, listener: (this: SVGFilterElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFilterElement: {\n prototype: SVGFilterElement;\n new(): SVGFilterElement;\n}\n\ninterface SVGForeignObjectElement extends SVGGraphicsElement {\n readonly height: SVGAnimatedLength;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGForeignObjectElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGForeignObjectElement: {\n prototype: SVGForeignObjectElement;\n new(): SVGForeignObjectElement;\n}\n\ninterface SVGGElement extends SVGGraphicsElement {\n addEventListener(type: K, listener: (this: SVGGElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGGElement: {\n prototype: SVGGElement;\n new(): SVGGElement;\n}\n\ninterface SVGGradientElement extends SVGElement, SVGUnitTypes, SVGURIReference {\n readonly gradientTransform: SVGAnimatedTransformList;\n readonly gradientUnits: SVGAnimatedEnumeration;\n readonly spreadMethod: SVGAnimatedEnumeration;\n readonly SVG_SPREADMETHOD_PAD: number;\n readonly SVG_SPREADMETHOD_REFLECT: number;\n readonly SVG_SPREADMETHOD_REPEAT: number;\n readonly SVG_SPREADMETHOD_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGGradientElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGGradientElement: {\n prototype: SVGGradientElement;\n new(): SVGGradientElement;\n readonly SVG_SPREADMETHOD_PAD: number;\n readonly SVG_SPREADMETHOD_REFLECT: number;\n readonly SVG_SPREADMETHOD_REPEAT: number;\n readonly SVG_SPREADMETHOD_UNKNOWN: number;\n}\n\ninterface SVGGraphicsElement extends SVGElement, SVGTests {\n readonly farthestViewportElement: SVGElement;\n readonly nearestViewportElement: SVGElement;\n readonly transform: SVGAnimatedTransformList;\n getBBox(): SVGRect;\n getCTM(): SVGMatrix;\n getScreenCTM(): SVGMatrix;\n getTransformToElement(element: SVGElement): SVGMatrix;\n addEventListener(type: K, listener: (this: SVGGraphicsElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGGraphicsElement: {\n prototype: SVGGraphicsElement;\n new(): SVGGraphicsElement;\n}\n\ninterface SVGImageElement extends SVGGraphicsElement, SVGURIReference {\n readonly height: SVGAnimatedLength;\n readonly preserveAspectRatio: SVGAnimatedPreserveAspectRatio;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGImageElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGImageElement: {\n prototype: SVGImageElement;\n new(): SVGImageElement;\n}\n\ninterface SVGLength {\n readonly unitType: number;\n value: number;\n valueAsString: string;\n valueInSpecifiedUnits: number;\n convertToSpecifiedUnits(unitType: number): void;\n newValueSpecifiedUnits(unitType: number, valueInSpecifiedUnits: number): void;\n readonly SVG_LENGTHTYPE_CM: number;\n readonly SVG_LENGTHTYPE_EMS: number;\n readonly SVG_LENGTHTYPE_EXS: number;\n readonly SVG_LENGTHTYPE_IN: number;\n readonly SVG_LENGTHTYPE_MM: number;\n readonly SVG_LENGTHTYPE_NUMBER: number;\n readonly SVG_LENGTHTYPE_PC: number;\n readonly SVG_LENGTHTYPE_PERCENTAGE: number;\n readonly SVG_LENGTHTYPE_PT: number;\n readonly SVG_LENGTHTYPE_PX: number;\n readonly SVG_LENGTHTYPE_UNKNOWN: number;\n}\n\ndeclare var SVGLength: {\n prototype: SVGLength;\n new(): SVGLength;\n readonly SVG_LENGTHTYPE_CM: number;\n readonly SVG_LENGTHTYPE_EMS: number;\n readonly SVG_LENGTHTYPE_EXS: number;\n readonly SVG_LENGTHTYPE_IN: number;\n readonly SVG_LENGTHTYPE_MM: number;\n readonly SVG_LENGTHTYPE_NUMBER: number;\n readonly SVG_LENGTHTYPE_PC: number;\n readonly SVG_LENGTHTYPE_PERCENTAGE: number;\n readonly SVG_LENGTHTYPE_PT: number;\n readonly SVG_LENGTHTYPE_PX: number;\n readonly SVG_LENGTHTYPE_UNKNOWN: number;\n}\n\ninterface SVGLengthList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGLength): SVGLength;\n clear(): void;\n getItem(index: number): SVGLength;\n initialize(newItem: SVGLength): SVGLength;\n insertItemBefore(newItem: SVGLength, index: number): SVGLength;\n removeItem(index: number): SVGLength;\n replaceItem(newItem: SVGLength, index: number): SVGLength;\n}\n\ndeclare var SVGLengthList: {\n prototype: SVGLengthList;\n new(): SVGLengthList;\n}\n\ninterface SVGLineElement extends SVGGraphicsElement {\n readonly x1: SVGAnimatedLength;\n readonly x2: SVGAnimatedLength;\n readonly y1: SVGAnimatedLength;\n readonly y2: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGLineElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGLineElement: {\n prototype: SVGLineElement;\n new(): SVGLineElement;\n}\n\ninterface SVGLinearGradientElement extends SVGGradientElement {\n readonly x1: SVGAnimatedLength;\n readonly x2: SVGAnimatedLength;\n readonly y1: SVGAnimatedLength;\n readonly y2: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGLinearGradientElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGLinearGradientElement: {\n prototype: SVGLinearGradientElement;\n new(): SVGLinearGradientElement;\n}\n\ninterface SVGMarkerElement extends SVGElement, SVGFitToViewBox {\n readonly markerHeight: SVGAnimatedLength;\n readonly markerUnits: SVGAnimatedEnumeration;\n readonly markerWidth: SVGAnimatedLength;\n readonly orientAngle: SVGAnimatedAngle;\n readonly orientType: SVGAnimatedEnumeration;\n readonly refX: SVGAnimatedLength;\n readonly refY: SVGAnimatedLength;\n setOrientToAngle(angle: SVGAngle): void;\n setOrientToAuto(): void;\n readonly SVG_MARKERUNITS_STROKEWIDTH: number;\n readonly SVG_MARKERUNITS_UNKNOWN: number;\n readonly SVG_MARKERUNITS_USERSPACEONUSE: number;\n readonly SVG_MARKER_ORIENT_ANGLE: number;\n readonly SVG_MARKER_ORIENT_AUTO: number;\n readonly SVG_MARKER_ORIENT_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGMarkerElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGMarkerElement: {\n prototype: SVGMarkerElement;\n new(): SVGMarkerElement;\n readonly SVG_MARKERUNITS_STROKEWIDTH: number;\n readonly SVG_MARKERUNITS_UNKNOWN: number;\n readonly SVG_MARKERUNITS_USERSPACEONUSE: number;\n readonly SVG_MARKER_ORIENT_ANGLE: number;\n readonly SVG_MARKER_ORIENT_AUTO: number;\n readonly SVG_MARKER_ORIENT_UNKNOWN: number;\n}\n\ninterface SVGMaskElement extends SVGElement, SVGTests, SVGUnitTypes {\n readonly height: SVGAnimatedLength;\n readonly maskContentUnits: SVGAnimatedEnumeration;\n readonly maskUnits: SVGAnimatedEnumeration;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGMaskElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGMaskElement: {\n prototype: SVGMaskElement;\n new(): SVGMaskElement;\n}\n\ninterface SVGMatrix {\n a: number;\n b: number;\n c: number;\n d: number;\n e: number;\n f: number;\n flipX(): SVGMatrix;\n flipY(): SVGMatrix;\n inverse(): SVGMatrix;\n multiply(secondMatrix: SVGMatrix): SVGMatrix;\n rotate(angle: number): SVGMatrix;\n rotateFromVector(x: number, y: number): SVGMatrix;\n scale(scaleFactor: number): SVGMatrix;\n scaleNonUniform(scaleFactorX: number, scaleFactorY: number): SVGMatrix;\n skewX(angle: number): SVGMatrix;\n skewY(angle: number): SVGMatrix;\n translate(x: number, y: number): SVGMatrix;\n}\n\ndeclare var SVGMatrix: {\n prototype: SVGMatrix;\n new(): SVGMatrix;\n}\n\ninterface SVGMetadataElement extends SVGElement {\n addEventListener(type: K, listener: (this: SVGMetadataElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGMetadataElement: {\n prototype: SVGMetadataElement;\n new(): SVGMetadataElement;\n}\n\ninterface SVGNumber {\n value: number;\n}\n\ndeclare var SVGNumber: {\n prototype: SVGNumber;\n new(): SVGNumber;\n}\n\ninterface SVGNumberList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGNumber): SVGNumber;\n clear(): void;\n getItem(index: number): SVGNumber;\n initialize(newItem: SVGNumber): SVGNumber;\n insertItemBefore(newItem: SVGNumber, index: number): SVGNumber;\n removeItem(index: number): SVGNumber;\n replaceItem(newItem: SVGNumber, index: number): SVGNumber;\n}\n\ndeclare var SVGNumberList: {\n prototype: SVGNumberList;\n new(): SVGNumberList;\n}\n\ninterface SVGPathElement extends SVGGraphicsElement {\n readonly pathSegList: SVGPathSegList;\n createSVGPathSegArcAbs(x: number, y: number, r1: number, r2: number, angle: number, largeArcFlag: boolean, sweepFlag: boolean): SVGPathSegArcAbs;\n createSVGPathSegArcRel(x: number, y: number, r1: number, r2: number, angle: number, largeArcFlag: boolean, sweepFlag: boolean): SVGPathSegArcRel;\n createSVGPathSegClosePath(): SVGPathSegClosePath;\n createSVGPathSegCurvetoCubicAbs(x: number, y: number, x1: number, y1: number, x2: number, y2: number): SVGPathSegCurvetoCubicAbs;\n createSVGPathSegCurvetoCubicRel(x: number, y: number, x1: number, y1: number, x2: number, y2: number): SVGPathSegCurvetoCubicRel;\n createSVGPathSegCurvetoCubicSmoothAbs(x: number, y: number, x2: number, y2: number): SVGPathSegCurvetoCubicSmoothAbs;\n createSVGPathSegCurvetoCubicSmoothRel(x: number, y: number, x2: number, y2: number): SVGPathSegCurvetoCubicSmoothRel;\n createSVGPathSegCurvetoQuadraticAbs(x: number, y: number, x1: number, y1: number): SVGPathSegCurvetoQuadraticAbs;\n createSVGPathSegCurvetoQuadraticRel(x: number, y: number, x1: number, y1: number): SVGPathSegCurvetoQuadraticRel;\n createSVGPathSegCurvetoQuadraticSmoothAbs(x: number, y: number): SVGPathSegCurvetoQuadraticSmoothAbs;\n createSVGPathSegCurvetoQuadraticSmoothRel(x: number, y: number): SVGPathSegCurvetoQuadraticSmoothRel;\n createSVGPathSegLinetoAbs(x: number, y: number): SVGPathSegLinetoAbs;\n createSVGPathSegLinetoHorizontalAbs(x: number): SVGPathSegLinetoHorizontalAbs;\n createSVGPathSegLinetoHorizontalRel(x: number): SVGPathSegLinetoHorizontalRel;\n createSVGPathSegLinetoRel(x: number, y: number): SVGPathSegLinetoRel;\n createSVGPathSegLinetoVerticalAbs(y: number): SVGPathSegLinetoVerticalAbs;\n createSVGPathSegLinetoVerticalRel(y: number): SVGPathSegLinetoVerticalRel;\n createSVGPathSegMovetoAbs(x: number, y: number): SVGPathSegMovetoAbs;\n createSVGPathSegMovetoRel(x: number, y: number): SVGPathSegMovetoRel;\n getPathSegAtLength(distance: number): number;\n getPointAtLength(distance: number): SVGPoint;\n getTotalLength(): number;\n addEventListener(type: K, listener: (this: SVGPathElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPathElement: {\n prototype: SVGPathElement;\n new(): SVGPathElement;\n}\n\ninterface SVGPathSeg {\n readonly pathSegType: number;\n readonly pathSegTypeAsLetter: string;\n readonly PATHSEG_ARC_ABS: number;\n readonly PATHSEG_ARC_REL: number;\n readonly PATHSEG_CLOSEPATH: number;\n readonly PATHSEG_CURVETO_CUBIC_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_REL: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL: number;\n readonly PATHSEG_LINETO_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_REL: number;\n readonly PATHSEG_LINETO_REL: number;\n readonly PATHSEG_LINETO_VERTICAL_ABS: number;\n readonly PATHSEG_LINETO_VERTICAL_REL: number;\n readonly PATHSEG_MOVETO_ABS: number;\n readonly PATHSEG_MOVETO_REL: number;\n readonly PATHSEG_UNKNOWN: number;\n}\n\ndeclare var SVGPathSeg: {\n prototype: SVGPathSeg;\n new(): SVGPathSeg;\n readonly PATHSEG_ARC_ABS: number;\n readonly PATHSEG_ARC_REL: number;\n readonly PATHSEG_CLOSEPATH: number;\n readonly PATHSEG_CURVETO_CUBIC_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_REL: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL: number;\n readonly PATHSEG_LINETO_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_REL: number;\n readonly PATHSEG_LINETO_REL: number;\n readonly PATHSEG_LINETO_VERTICAL_ABS: number;\n readonly PATHSEG_LINETO_VERTICAL_REL: number;\n readonly PATHSEG_MOVETO_ABS: number;\n readonly PATHSEG_MOVETO_REL: number;\n readonly PATHSEG_UNKNOWN: number;\n}\n\ninterface SVGPathSegArcAbs extends SVGPathSeg {\n angle: number;\n largeArcFlag: boolean;\n r1: number;\n r2: number;\n sweepFlag: boolean;\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegArcAbs: {\n prototype: SVGPathSegArcAbs;\n new(): SVGPathSegArcAbs;\n}\n\ninterface SVGPathSegArcRel extends SVGPathSeg {\n angle: number;\n largeArcFlag: boolean;\n r1: number;\n r2: number;\n sweepFlag: boolean;\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegArcRel: {\n prototype: SVGPathSegArcRel;\n new(): SVGPathSegArcRel;\n}\n\ninterface SVGPathSegClosePath extends SVGPathSeg {\n}\n\ndeclare var SVGPathSegClosePath: {\n prototype: SVGPathSegClosePath;\n new(): SVGPathSegClosePath;\n}\n\ninterface SVGPathSegCurvetoCubicAbs extends SVGPathSeg {\n x: number;\n x1: number;\n x2: number;\n y: number;\n y1: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicAbs: {\n prototype: SVGPathSegCurvetoCubicAbs;\n new(): SVGPathSegCurvetoCubicAbs;\n}\n\ninterface SVGPathSegCurvetoCubicRel extends SVGPathSeg {\n x: number;\n x1: number;\n x2: number;\n y: number;\n y1: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicRel: {\n prototype: SVGPathSegCurvetoCubicRel;\n new(): SVGPathSegCurvetoCubicRel;\n}\n\ninterface SVGPathSegCurvetoCubicSmoothAbs extends SVGPathSeg {\n x: number;\n x2: number;\n y: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicSmoothAbs: {\n prototype: SVGPathSegCurvetoCubicSmoothAbs;\n new(): SVGPathSegCurvetoCubicSmoothAbs;\n}\n\ninterface SVGPathSegCurvetoCubicSmoothRel extends SVGPathSeg {\n x: number;\n x2: number;\n y: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicSmoothRel: {\n prototype: SVGPathSegCurvetoCubicSmoothRel;\n new(): SVGPathSegCurvetoCubicSmoothRel;\n}\n\ninterface SVGPathSegCurvetoQuadraticAbs extends SVGPathSeg {\n x: number;\n x1: number;\n y: number;\n y1: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticAbs: {\n prototype: SVGPathSegCurvetoQuadraticAbs;\n new(): SVGPathSegCurvetoQuadraticAbs;\n}\n\ninterface SVGPathSegCurvetoQuadraticRel extends SVGPathSeg {\n x: number;\n x1: number;\n y: number;\n y1: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticRel: {\n prototype: SVGPathSegCurvetoQuadraticRel;\n new(): SVGPathSegCurvetoQuadraticRel;\n}\n\ninterface SVGPathSegCurvetoQuadraticSmoothAbs extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticSmoothAbs: {\n prototype: SVGPathSegCurvetoQuadraticSmoothAbs;\n new(): SVGPathSegCurvetoQuadraticSmoothAbs;\n}\n\ninterface SVGPathSegCurvetoQuadraticSmoothRel extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticSmoothRel: {\n prototype: SVGPathSegCurvetoQuadraticSmoothRel;\n new(): SVGPathSegCurvetoQuadraticSmoothRel;\n}\n\ninterface SVGPathSegLinetoAbs extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegLinetoAbs: {\n prototype: SVGPathSegLinetoAbs;\n new(): SVGPathSegLinetoAbs;\n}\n\ninterface SVGPathSegLinetoHorizontalAbs extends SVGPathSeg {\n x: number;\n}\n\ndeclare var SVGPathSegLinetoHorizontalAbs: {\n prototype: SVGPathSegLinetoHorizontalAbs;\n new(): SVGPathSegLinetoHorizontalAbs;\n}\n\ninterface SVGPathSegLinetoHorizontalRel extends SVGPathSeg {\n x: number;\n}\n\ndeclare var SVGPathSegLinetoHorizontalRel: {\n prototype: SVGPathSegLinetoHorizontalRel;\n new(): SVGPathSegLinetoHorizontalRel;\n}\n\ninterface SVGPathSegLinetoRel extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegLinetoRel: {\n prototype: SVGPathSegLinetoRel;\n new(): SVGPathSegLinetoRel;\n}\n\ninterface SVGPathSegLinetoVerticalAbs extends SVGPathSeg {\n y: number;\n}\n\ndeclare var SVGPathSegLinetoVerticalAbs: {\n prototype: SVGPathSegLinetoVerticalAbs;\n new(): SVGPathSegLinetoVerticalAbs;\n}\n\ninterface SVGPathSegLinetoVerticalRel extends SVGPathSeg {\n y: number;\n}\n\ndeclare var SVGPathSegLinetoVerticalRel: {\n prototype: SVGPathSegLinetoVerticalRel;\n new(): SVGPathSegLinetoVerticalRel;\n}\n\ninterface SVGPathSegList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGPathSeg): SVGPathSeg;\n clear(): void;\n getItem(index: number): SVGPathSeg;\n initialize(newItem: SVGPathSeg): SVGPathSeg;\n insertItemBefore(newItem: SVGPathSeg, index: number): SVGPathSeg;\n removeItem(index: number): SVGPathSeg;\n replaceItem(newItem: SVGPathSeg, index: number): SVGPathSeg;\n}\n\ndeclare var SVGPathSegList: {\n prototype: SVGPathSegList;\n new(): SVGPathSegList;\n}\n\ninterface SVGPathSegMovetoAbs extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegMovetoAbs: {\n prototype: SVGPathSegMovetoAbs;\n new(): SVGPathSegMovetoAbs;\n}\n\ninterface SVGPathSegMovetoRel extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegMovetoRel: {\n prototype: SVGPathSegMovetoRel;\n new(): SVGPathSegMovetoRel;\n}\n\ninterface SVGPatternElement extends SVGElement, SVGTests, SVGUnitTypes, SVGFitToViewBox, SVGURIReference {\n readonly height: SVGAnimatedLength;\n readonly patternContentUnits: SVGAnimatedEnumeration;\n readonly patternTransform: SVGAnimatedTransformList;\n readonly patternUnits: SVGAnimatedEnumeration;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGPatternElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPatternElement: {\n prototype: SVGPatternElement;\n new(): SVGPatternElement;\n}\n\ninterface SVGPoint {\n x: number;\n y: number;\n matrixTransform(matrix: SVGMatrix): SVGPoint;\n}\n\ndeclare var SVGPoint: {\n prototype: SVGPoint;\n new(): SVGPoint;\n}\n\ninterface SVGPointList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGPoint): SVGPoint;\n clear(): void;\n getItem(index: number): SVGPoint;\n initialize(newItem: SVGPoint): SVGPoint;\n insertItemBefore(newItem: SVGPoint, index: number): SVGPoint;\n removeItem(index: number): SVGPoint;\n replaceItem(newItem: SVGPoint, index: number): SVGPoint;\n}\n\ndeclare var SVGPointList: {\n prototype: SVGPointList;\n new(): SVGPointList;\n}\n\ninterface SVGPolygonElement extends SVGGraphicsElement, SVGAnimatedPoints {\n addEventListener(type: K, listener: (this: SVGPolygonElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPolygonElement: {\n prototype: SVGPolygonElement;\n new(): SVGPolygonElement;\n}\n\ninterface SVGPolylineElement extends SVGGraphicsElement, SVGAnimatedPoints {\n addEventListener(type: K, listener: (this: SVGPolylineElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPolylineElement: {\n prototype: SVGPolylineElement;\n new(): SVGPolylineElement;\n}\n\ninterface SVGPreserveAspectRatio {\n align: number;\n meetOrSlice: number;\n readonly SVG_MEETORSLICE_MEET: number;\n readonly SVG_MEETORSLICE_SLICE: number;\n readonly SVG_MEETORSLICE_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_NONE: number;\n readonly SVG_PRESERVEASPECTRATIO_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMIN: number;\n}\n\ndeclare var SVGPreserveAspectRatio: {\n prototype: SVGPreserveAspectRatio;\n new(): SVGPreserveAspectRatio;\n readonly SVG_MEETORSLICE_MEET: number;\n readonly SVG_MEETORSLICE_SLICE: number;\n readonly SVG_MEETORSLICE_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_NONE: number;\n readonly SVG_PRESERVEASPECTRATIO_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMIN: number;\n}\n\ninterface SVGRadialGradientElement extends SVGGradientElement {\n readonly cx: SVGAnimatedLength;\n readonly cy: SVGAnimatedLength;\n readonly fx: SVGAnimatedLength;\n readonly fy: SVGAnimatedLength;\n readonly r: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGRadialGradientElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGRadialGradientElement: {\n prototype: SVGRadialGradientElement;\n new(): SVGRadialGradientElement;\n}\n\ninterface SVGRect {\n height: number;\n width: number;\n x: number;\n y: number;\n}\n\ndeclare var SVGRect: {\n prototype: SVGRect;\n new(): SVGRect;\n}\n\ninterface SVGRectElement extends SVGGraphicsElement {\n readonly height: SVGAnimatedLength;\n readonly rx: SVGAnimatedLength;\n readonly ry: SVGAnimatedLength;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGRectElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGRectElement: {\n prototype: SVGRectElement;\n new(): SVGRectElement;\n}\n\ninterface SVGSVGElementEventMap extends SVGElementEventMap {\n \"SVGAbort\": Event;\n \"SVGError\": Event;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"SVGUnload\": Event;\n \"SVGZoom\": SVGZoomEvent;\n}\n\ninterface SVGSVGElement extends SVGGraphicsElement, DocumentEvent, SVGFitToViewBox, SVGZoomAndPan {\n contentScriptType: string;\n contentStyleType: string;\n currentScale: number;\n readonly currentTranslate: SVGPoint;\n readonly height: SVGAnimatedLength;\n onabort: (this: SVGSVGElement, ev: Event) => any;\n onerror: (this: SVGSVGElement, ev: Event) => any;\n onresize: (this: SVGSVGElement, ev: UIEvent) => any;\n onscroll: (this: SVGSVGElement, ev: UIEvent) => any;\n onunload: (this: SVGSVGElement, ev: Event) => any;\n onzoom: (this: SVGSVGElement, ev: SVGZoomEvent) => any;\n readonly pixelUnitToMillimeterX: number;\n readonly pixelUnitToMillimeterY: number;\n readonly screenPixelToMillimeterX: number;\n readonly screenPixelToMillimeterY: number;\n readonly viewport: SVGRect;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n checkEnclosure(element: SVGElement, rect: SVGRect): boolean;\n checkIntersection(element: SVGElement, rect: SVGRect): boolean;\n createSVGAngle(): SVGAngle;\n createSVGLength(): SVGLength;\n createSVGMatrix(): SVGMatrix;\n createSVGNumber(): SVGNumber;\n createSVGPoint(): SVGPoint;\n createSVGRect(): SVGRect;\n createSVGTransform(): SVGTransform;\n createSVGTransformFromMatrix(matrix: SVGMatrix): SVGTransform;\n deselectAll(): void;\n forceRedraw(): void;\n getComputedStyle(elt: Element, pseudoElt?: string): CSSStyleDeclaration;\n getCurrentTime(): number;\n getElementById(elementId: string): Element;\n getEnclosureList(rect: SVGRect, referenceElement: SVGElement): NodeListOf;\n getIntersectionList(rect: SVGRect, referenceElement: SVGElement): NodeListOf;\n pauseAnimations(): void;\n setCurrentTime(seconds: number): void;\n suspendRedraw(maxWaitMilliseconds: number): number;\n unpauseAnimations(): void;\n unsuspendRedraw(suspendHandleID: number): void;\n unsuspendRedrawAll(): void;\n addEventListener(type: K, listener: (this: SVGSVGElement, ev: SVGSVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGSVGElement: {\n prototype: SVGSVGElement;\n new(): SVGSVGElement;\n}\n\ninterface SVGScriptElement extends SVGElement, SVGURIReference {\n type: string;\n addEventListener(type: K, listener: (this: SVGScriptElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGScriptElement: {\n prototype: SVGScriptElement;\n new(): SVGScriptElement;\n}\n\ninterface SVGStopElement extends SVGElement {\n readonly offset: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGStopElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGStopElement: {\n prototype: SVGStopElement;\n new(): SVGStopElement;\n}\n\ninterface SVGStringList {\n readonly numberOfItems: number;\n appendItem(newItem: string): string;\n clear(): void;\n getItem(index: number): string;\n initialize(newItem: string): string;\n insertItemBefore(newItem: string, index: number): string;\n removeItem(index: number): string;\n replaceItem(newItem: string, index: number): string;\n}\n\ndeclare var SVGStringList: {\n prototype: SVGStringList;\n new(): SVGStringList;\n}\n\ninterface SVGStyleElement extends SVGElement {\n disabled: boolean;\n media: string;\n title: string;\n type: string;\n addEventListener(type: K, listener: (this: SVGStyleElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGStyleElement: {\n prototype: SVGStyleElement;\n new(): SVGStyleElement;\n}\n\ninterface SVGSwitchElement extends SVGGraphicsElement {\n addEventListener(type: K, listener: (this: SVGSwitchElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGSwitchElement: {\n prototype: SVGSwitchElement;\n new(): SVGSwitchElement;\n}\n\ninterface SVGSymbolElement extends SVGElement, SVGFitToViewBox {\n addEventListener(type: K, listener: (this: SVGSymbolElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGSymbolElement: {\n prototype: SVGSymbolElement;\n new(): SVGSymbolElement;\n}\n\ninterface SVGTSpanElement extends SVGTextPositioningElement {\n addEventListener(type: K, listener: (this: SVGTSpanElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTSpanElement: {\n prototype: SVGTSpanElement;\n new(): SVGTSpanElement;\n}\n\ninterface SVGTextContentElement extends SVGGraphicsElement {\n readonly lengthAdjust: SVGAnimatedEnumeration;\n readonly textLength: SVGAnimatedLength;\n getCharNumAtPosition(point: SVGPoint): number;\n getComputedTextLength(): number;\n getEndPositionOfChar(charnum: number): SVGPoint;\n getExtentOfChar(charnum: number): SVGRect;\n getNumberOfChars(): number;\n getRotationOfChar(charnum: number): number;\n getStartPositionOfChar(charnum: number): SVGPoint;\n getSubStringLength(charnum: number, nchars: number): number;\n selectSubString(charnum: number, nchars: number): void;\n readonly LENGTHADJUST_SPACING: number;\n readonly LENGTHADJUST_SPACINGANDGLYPHS: number;\n readonly LENGTHADJUST_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGTextContentElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextContentElement: {\n prototype: SVGTextContentElement;\n new(): SVGTextContentElement;\n readonly LENGTHADJUST_SPACING: number;\n readonly LENGTHADJUST_SPACINGANDGLYPHS: number;\n readonly LENGTHADJUST_UNKNOWN: number;\n}\n\ninterface SVGTextElement extends SVGTextPositioningElement {\n addEventListener(type: K, listener: (this: SVGTextElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextElement: {\n prototype: SVGTextElement;\n new(): SVGTextElement;\n}\n\ninterface SVGTextPathElement extends SVGTextContentElement, SVGURIReference {\n readonly method: SVGAnimatedEnumeration;\n readonly spacing: SVGAnimatedEnumeration;\n readonly startOffset: SVGAnimatedLength;\n readonly TEXTPATH_METHODTYPE_ALIGN: number;\n readonly TEXTPATH_METHODTYPE_STRETCH: number;\n readonly TEXTPATH_METHODTYPE_UNKNOWN: number;\n readonly TEXTPATH_SPACINGTYPE_AUTO: number;\n readonly TEXTPATH_SPACINGTYPE_EXACT: number;\n readonly TEXTPATH_SPACINGTYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGTextPathElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextPathElement: {\n prototype: SVGTextPathElement;\n new(): SVGTextPathElement;\n readonly TEXTPATH_METHODTYPE_ALIGN: number;\n readonly TEXTPATH_METHODTYPE_STRETCH: number;\n readonly TEXTPATH_METHODTYPE_UNKNOWN: number;\n readonly TEXTPATH_SPACINGTYPE_AUTO: number;\n readonly TEXTPATH_SPACINGTYPE_EXACT: number;\n readonly TEXTPATH_SPACINGTYPE_UNKNOWN: number;\n}\n\ninterface SVGTextPositioningElement extends SVGTextContentElement {\n readonly dx: SVGAnimatedLengthList;\n readonly dy: SVGAnimatedLengthList;\n readonly rotate: SVGAnimatedNumberList;\n readonly x: SVGAnimatedLengthList;\n readonly y: SVGAnimatedLengthList;\n addEventListener(type: K, listener: (this: SVGTextPositioningElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextPositioningElement: {\n prototype: SVGTextPositioningElement;\n new(): SVGTextPositioningElement;\n}\n\ninterface SVGTitleElement extends SVGElement {\n addEventListener(type: K, listener: (this: SVGTitleElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTitleElement: {\n prototype: SVGTitleElement;\n new(): SVGTitleElement;\n}\n\ninterface SVGTransform {\n readonly angle: number;\n readonly matrix: SVGMatrix;\n readonly type: number;\n setMatrix(matrix: SVGMatrix): void;\n setRotate(angle: number, cx: number, cy: number): void;\n setScale(sx: number, sy: number): void;\n setSkewX(angle: number): void;\n setSkewY(angle: number): void;\n setTranslate(tx: number, ty: number): void;\n readonly SVG_TRANSFORM_MATRIX: number;\n readonly SVG_TRANSFORM_ROTATE: number;\n readonly SVG_TRANSFORM_SCALE: number;\n readonly SVG_TRANSFORM_SKEWX: number;\n readonly SVG_TRANSFORM_SKEWY: number;\n readonly SVG_TRANSFORM_TRANSLATE: number;\n readonly SVG_TRANSFORM_UNKNOWN: number;\n}\n\ndeclare var SVGTransform: {\n prototype: SVGTransform;\n new(): SVGTransform;\n readonly SVG_TRANSFORM_MATRIX: number;\n readonly SVG_TRANSFORM_ROTATE: number;\n readonly SVG_TRANSFORM_SCALE: number;\n readonly SVG_TRANSFORM_SKEWX: number;\n readonly SVG_TRANSFORM_SKEWY: number;\n readonly SVG_TRANSFORM_TRANSLATE: number;\n readonly SVG_TRANSFORM_UNKNOWN: number;\n}\n\ninterface SVGTransformList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGTransform): SVGTransform;\n clear(): void;\n consolidate(): SVGTransform;\n createSVGTransformFromMatrix(matrix: SVGMatrix): SVGTransform;\n getItem(index: number): SVGTransform;\n initialize(newItem: SVGTransform): SVGTransform;\n insertItemBefore(newItem: SVGTransform, index: number): SVGTransform;\n removeItem(index: number): SVGTransform;\n replaceItem(newItem: SVGTransform, index: number): SVGTransform;\n}\n\ndeclare var SVGTransformList: {\n prototype: SVGTransformList;\n new(): SVGTransformList;\n}\n\ninterface SVGUnitTypes {\n readonly SVG_UNIT_TYPE_OBJECTBOUNDINGBOX: number;\n readonly SVG_UNIT_TYPE_UNKNOWN: number;\n readonly SVG_UNIT_TYPE_USERSPACEONUSE: number;\n}\ndeclare var SVGUnitTypes: SVGUnitTypes;\n\ninterface SVGUseElement extends SVGGraphicsElement, SVGURIReference {\n readonly animatedInstanceRoot: SVGElementInstance;\n readonly height: SVGAnimatedLength;\n readonly instanceRoot: SVGElementInstance;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGUseElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGUseElement: {\n prototype: SVGUseElement;\n new(): SVGUseElement;\n}\n\ninterface SVGViewElement extends SVGElement, SVGZoomAndPan, SVGFitToViewBox {\n readonly viewTarget: SVGStringList;\n addEventListener(type: K, listener: (this: SVGViewElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGViewElement: {\n prototype: SVGViewElement;\n new(): SVGViewElement;\n}\n\ninterface SVGZoomAndPan {\n readonly zoomAndPan: number;\n}\n\ndeclare var SVGZoomAndPan: {\n readonly SVG_ZOOMANDPAN_DISABLE: number;\n readonly SVG_ZOOMANDPAN_MAGNIFY: number;\n readonly SVG_ZOOMANDPAN_UNKNOWN: number;\n}\n\ninterface SVGZoomEvent extends UIEvent {\n readonly newScale: number;\n readonly newTranslate: SVGPoint;\n readonly previousScale: number;\n readonly previousTranslate: SVGPoint;\n readonly zoomRectScreen: SVGRect;\n}\n\ndeclare var SVGZoomEvent: {\n prototype: SVGZoomEvent;\n new(): SVGZoomEvent;\n}\n\ninterface ScopedCredential {\n readonly id: ArrayBuffer;\n readonly type: ScopedCredentialType;\n}\n\ndeclare var ScopedCredential: {\n prototype: ScopedCredential;\n new(): ScopedCredential;\n}\n\ninterface ScopedCredentialInfo {\n readonly credential: ScopedCredential;\n readonly publicKey: CryptoKey;\n}\n\ndeclare var ScopedCredentialInfo: {\n prototype: ScopedCredentialInfo;\n new(): ScopedCredentialInfo;\n}\n\ninterface ScreenEventMap {\n \"MSOrientationChange\": Event;\n}\n\ninterface Screen extends EventTarget {\n readonly availHeight: number;\n readonly availWidth: number;\n bufferDepth: number;\n readonly colorDepth: number;\n readonly deviceXDPI: number;\n readonly deviceYDPI: number;\n readonly fontSmoothingEnabled: boolean;\n readonly height: number;\n readonly logicalXDPI: number;\n readonly logicalYDPI: number;\n readonly msOrientation: string;\n onmsorientationchange: (this: Screen, ev: Event) => any;\n readonly pixelDepth: number;\n readonly systemXDPI: number;\n readonly systemYDPI: number;\n readonly width: number;\n msLockOrientation(orientations: string | string[]): boolean;\n msUnlockOrientation(): void;\n addEventListener(type: K, listener: (this: Screen, ev: ScreenEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Screen: {\n prototype: Screen;\n new(): Screen;\n}\n\ninterface ScriptNotifyEvent extends Event {\n readonly callingUri: string;\n readonly value: string;\n}\n\ndeclare var ScriptNotifyEvent: {\n prototype: ScriptNotifyEvent;\n new(): ScriptNotifyEvent;\n}\n\ninterface ScriptProcessorNodeEventMap {\n \"audioprocess\": AudioProcessingEvent;\n}\n\ninterface ScriptProcessorNode extends AudioNode {\n readonly bufferSize: number;\n onaudioprocess: (this: ScriptProcessorNode, ev: AudioProcessingEvent) => any;\n addEventListener(type: K, listener: (this: ScriptProcessorNode, ev: ScriptProcessorNodeEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ScriptProcessorNode: {\n prototype: ScriptProcessorNode;\n new(): ScriptProcessorNode;\n}\n\ninterface Selection {\n readonly anchorNode: Node;\n readonly anchorOffset: number;\n readonly baseNode: Node;\n readonly baseOffset: number;\n readonly extentNode: Node;\n readonly extentOffset: number;\n readonly focusNode: Node;\n readonly focusOffset: number;\n readonly isCollapsed: boolean;\n readonly rangeCount: number;\n readonly type: string;\n addRange(range: Range): void;\n collapse(parentNode: Node, offset: number): void;\n collapseToEnd(): void;\n collapseToStart(): void;\n containsNode(node: Node, partlyContained: boolean): boolean;\n deleteFromDocument(): void;\n empty(): void;\n extend(newNode: Node, offset: number): void;\n getRangeAt(index: number): Range;\n removeAllRanges(): void;\n removeRange(range: Range): void;\n selectAllChildren(parentNode: Node): void;\n setBaseAndExtent(baseNode: Node, baseOffset: number, extentNode: Node, extentOffset: number): void;\n setPosition(parentNode: Node, offset: number): void;\n toString(): string;\n}\n\ndeclare var Selection: {\n prototype: Selection;\n new(): Selection;\n}\n\ninterface ServiceWorkerEventMap extends AbstractWorkerEventMap {\n \"statechange\": Event;\n}\n\ninterface ServiceWorker extends EventTarget, AbstractWorker {\n onstatechange: (this: ServiceWorker, ev: Event) => any;\n readonly scriptURL: USVString;\n readonly state: ServiceWorkerState;\n postMessage(message: any, transfer?: any[]): void;\n addEventListener(type: K, listener: (this: ServiceWorker, ev: ServiceWorkerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ServiceWorker: {\n prototype: ServiceWorker;\n new(): ServiceWorker;\n}\n\ninterface ServiceWorkerContainerEventMap {\n \"controllerchange\": Event;\n \"message\": ServiceWorkerMessageEvent;\n}\n\ninterface ServiceWorkerContainer extends EventTarget {\n readonly controller: ServiceWorker | null;\n oncontrollerchange: (this: ServiceWorkerContainer, ev: Event) => any;\n onmessage: (this: ServiceWorkerContainer, ev: ServiceWorkerMessageEvent) => any;\n readonly ready: Promise;\n getRegistration(clientURL?: USVString): Promise;\n getRegistrations(): any;\n register(scriptURL: USVString, options?: RegistrationOptions): Promise;\n addEventListener(type: K, listener: (this: ServiceWorkerContainer, ev: ServiceWorkerContainerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ServiceWorkerContainer: {\n prototype: ServiceWorkerContainer;\n new(): ServiceWorkerContainer;\n}\n\ninterface ServiceWorkerMessageEvent extends Event {\n readonly data: any;\n readonly lastEventId: string;\n readonly origin: string;\n readonly ports: MessagePort[] | null;\n readonly source: ServiceWorker | MessagePort | null;\n}\n\ndeclare var ServiceWorkerMessageEvent: {\n prototype: ServiceWorkerMessageEvent;\n new(type: string, eventInitDict?: ServiceWorkerMessageEventInit): ServiceWorkerMessageEvent;\n}\n\ninterface ServiceWorkerRegistrationEventMap {\n \"updatefound\": Event;\n}\n\ninterface ServiceWorkerRegistration extends EventTarget {\n readonly active: ServiceWorker | null;\n readonly installing: ServiceWorker | null;\n onupdatefound: (this: ServiceWorkerRegistration, ev: Event) => any;\n readonly pushManager: PushManager;\n readonly scope: USVString;\n readonly sync: SyncManager;\n readonly waiting: ServiceWorker | null;\n getNotifications(filter?: GetNotificationOptions): any;\n showNotification(title: string, options?: NotificationOptions): Promise;\n unregister(): Promise;\n update(): Promise;\n addEventListener(type: K, listener: (this: ServiceWorkerRegistration, ev: ServiceWorkerRegistrationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ServiceWorkerRegistration: {\n prototype: ServiceWorkerRegistration;\n new(): ServiceWorkerRegistration;\n}\n\ninterface SourceBuffer extends EventTarget {\n appendWindowEnd: number;\n appendWindowStart: number;\n readonly audioTracks: AudioTrackList;\n readonly buffered: TimeRanges;\n mode: AppendMode;\n timestampOffset: number;\n readonly updating: boolean;\n readonly videoTracks: VideoTrackList;\n abort(): void;\n appendBuffer(data: ArrayBuffer | ArrayBufferView): void;\n appendStream(stream: MSStream, maxSize?: number): void;\n remove(start: number, end: number): void;\n}\n\ndeclare var SourceBuffer: {\n prototype: SourceBuffer;\n new(): SourceBuffer;\n}\n\ninterface SourceBufferList extends EventTarget {\n readonly length: number;\n item(index: number): SourceBuffer;\n [index: number]: SourceBuffer;\n}\n\ndeclare var SourceBufferList: {\n prototype: SourceBufferList;\n new(): SourceBufferList;\n}\n\ninterface SpeechSynthesisEventMap {\n \"voiceschanged\": Event;\n}\n\ninterface SpeechSynthesis extends EventTarget {\n onvoiceschanged: (this: SpeechSynthesis, ev: Event) => any;\n readonly paused: boolean;\n readonly pending: boolean;\n readonly speaking: boolean;\n cancel(): void;\n getVoices(): SpeechSynthesisVoice[];\n pause(): void;\n resume(): void;\n speak(utterance: SpeechSynthesisUtterance): void;\n addEventListener(type: K, listener: (this: SpeechSynthesis, ev: SpeechSynthesisEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SpeechSynthesis: {\n prototype: SpeechSynthesis;\n new(): SpeechSynthesis;\n}\n\ninterface SpeechSynthesisEvent extends Event {\n readonly charIndex: number;\n readonly elapsedTime: number;\n readonly name: string;\n readonly utterance: SpeechSynthesisUtterance | null;\n}\n\ndeclare var SpeechSynthesisEvent: {\n prototype: SpeechSynthesisEvent;\n new(type: string, eventInitDict?: SpeechSynthesisEventInit): SpeechSynthesisEvent;\n}\n\ninterface SpeechSynthesisUtteranceEventMap {\n \"boundary\": Event;\n \"end\": Event;\n \"error\": Event;\n \"mark\": Event;\n \"pause\": Event;\n \"resume\": Event;\n \"start\": Event;\n}\n\ninterface SpeechSynthesisUtterance extends EventTarget {\n lang: string;\n onboundary: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onend: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onerror: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onmark: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onpause: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onresume: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onstart: (this: SpeechSynthesisUtterance, ev: Event) => any;\n pitch: number;\n rate: number;\n text: string;\n voice: SpeechSynthesisVoice;\n volume: number;\n addEventListener(type: K, listener: (this: SpeechSynthesisUtterance, ev: SpeechSynthesisUtteranceEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SpeechSynthesisUtterance: {\n prototype: SpeechSynthesisUtterance;\n new(text?: string): SpeechSynthesisUtterance;\n}\n\ninterface SpeechSynthesisVoice {\n readonly default: boolean;\n readonly lang: string;\n readonly localService: boolean;\n readonly name: string;\n readonly voiceURI: string;\n}\n\ndeclare var SpeechSynthesisVoice: {\n prototype: SpeechSynthesisVoice;\n new(): SpeechSynthesisVoice;\n}\n\ninterface StereoPannerNode extends AudioNode {\n readonly pan: AudioParam;\n}\n\ndeclare var StereoPannerNode: {\n prototype: StereoPannerNode;\n new(): StereoPannerNode;\n}\n\ninterface Storage {\n readonly length: number;\n clear(): void;\n getItem(key: string): string | null;\n key(index: number): string | null;\n removeItem(key: string): void;\n setItem(key: string, data: string): void;\n [key: string]: any;\n [index: number]: string;\n}\n\ndeclare var Storage: {\n prototype: Storage;\n new(): Storage;\n}\n\ninterface StorageEvent extends Event {\n readonly url: string;\n key?: string;\n oldValue?: string;\n newValue?: string;\n storageArea?: Storage;\n}\n\ndeclare var StorageEvent: {\n prototype: StorageEvent;\n new (type: string, eventInitDict?: StorageEventInit): StorageEvent;\n}\n\ninterface StyleMedia {\n readonly type: string;\n matchMedium(mediaquery: string): boolean;\n}\n\ndeclare var StyleMedia: {\n prototype: StyleMedia;\n new(): StyleMedia;\n}\n\ninterface StyleSheet {\n disabled: boolean;\n readonly href: string;\n readonly media: MediaList;\n readonly ownerNode: Node;\n readonly parentStyleSheet: StyleSheet;\n readonly title: string;\n readonly type: string;\n}\n\ndeclare var StyleSheet: {\n prototype: StyleSheet;\n new(): StyleSheet;\n}\n\ninterface StyleSheetList {\n readonly length: number;\n item(index?: number): StyleSheet;\n [index: number]: StyleSheet;\n}\n\ndeclare var StyleSheetList: {\n prototype: StyleSheetList;\n new(): StyleSheetList;\n}\n\ninterface StyleSheetPageList {\n readonly length: number;\n item(index: number): CSSPageRule;\n [index: number]: CSSPageRule;\n}\n\ndeclare var StyleSheetPageList: {\n prototype: StyleSheetPageList;\n new(): StyleSheetPageList;\n}\n\ninterface SubtleCrypto {\n decrypt(algorithm: string | RsaOaepParams | AesCtrParams | AesCbcParams | AesCmacParams | AesGcmParams | AesCfbParams, key: CryptoKey, data: BufferSource): PromiseLike;\n deriveBits(algorithm: string | EcdhKeyDeriveParams | DhKeyDeriveParams | ConcatParams | HkdfCtrParams | Pbkdf2Params, baseKey: CryptoKey, length: number): PromiseLike;\n deriveKey(algorithm: string | EcdhKeyDeriveParams | DhKeyDeriveParams | ConcatParams | HkdfCtrParams | Pbkdf2Params, baseKey: CryptoKey, derivedKeyType: string | AesDerivedKeyParams | HmacImportParams | ConcatParams | HkdfCtrParams | Pbkdf2Params, extractable: boolean, keyUsages: string[]): PromiseLike;\n digest(algorithm: AlgorithmIdentifier, data: BufferSource): PromiseLike;\n encrypt(algorithm: string | RsaOaepParams | AesCtrParams | AesCbcParams | AesCmacParams | AesGcmParams | AesCfbParams, key: CryptoKey, data: BufferSource): PromiseLike;\n exportKey(format: \"jwk\", key: CryptoKey): PromiseLike;\n exportKey(format: \"raw\" | \"pkcs8\" | \"spki\", key: CryptoKey): PromiseLike;\n exportKey(format: string, key: CryptoKey): PromiseLike;\n generateKey(algorithm: string, extractable: boolean, keyUsages: string[]): PromiseLike;\n generateKey(algorithm: RsaHashedKeyGenParams | EcKeyGenParams | DhKeyGenParams, extractable: boolean, keyUsages: string[]): PromiseLike;\n generateKey(algorithm: AesKeyGenParams | HmacKeyGenParams | Pbkdf2Params, extractable: boolean, keyUsages: string[]): PromiseLike;\n importKey(format: \"jwk\", keyData: JsonWebKey, algorithm: string | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | DhImportKeyParams, extractable:boolean, keyUsages: string[]): PromiseLike;\n importKey(format: \"raw\" | \"pkcs8\" | \"spki\", keyData: BufferSource, algorithm: string | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | DhImportKeyParams, extractable:boolean, keyUsages: string[]): PromiseLike;\n importKey(format: string, keyData: JsonWebKey | BufferSource, algorithm: string | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | DhImportKeyParams, extractable:boolean, keyUsages: string[]): PromiseLike;\n sign(algorithm: string | RsaPssParams | EcdsaParams | AesCmacParams, key: CryptoKey, data: BufferSource): PromiseLike;\n unwrapKey(format: string, wrappedKey: BufferSource, unwrappingKey: CryptoKey, unwrapAlgorithm: AlgorithmIdentifier, unwrappedKeyAlgorithm: AlgorithmIdentifier, extractable: boolean, keyUsages: string[]): PromiseLike;\n verify(algorithm: string | RsaPssParams | EcdsaParams | AesCmacParams, key: CryptoKey, signature: BufferSource, data: BufferSource): PromiseLike;\n wrapKey(format: string, key: CryptoKey, wrappingKey: CryptoKey, wrapAlgorithm: AlgorithmIdentifier): PromiseLike;\n}\n\ndeclare var SubtleCrypto: {\n prototype: SubtleCrypto;\n new(): SubtleCrypto;\n}\n\ninterface SyncManager {\n getTags(): any;\n register(tag: string): Promise;\n}\n\ndeclare var SyncManager: {\n prototype: SyncManager;\n new(): SyncManager;\n}\n\ninterface Text extends CharacterData {\n readonly wholeText: string;\n readonly assignedSlot: HTMLSlotElement | null;\n splitText(offset: number): Text;\n}\n\ndeclare var Text: {\n prototype: Text;\n new(data?: string): Text;\n}\n\ninterface TextEvent extends UIEvent {\n readonly data: string;\n readonly inputMethod: number;\n readonly locale: string;\n initTextEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, dataArg: string, inputMethod: number, locale: string): void;\n readonly DOM_INPUT_METHOD_DROP: number;\n readonly DOM_INPUT_METHOD_HANDWRITING: number;\n readonly DOM_INPUT_METHOD_IME: number;\n readonly DOM_INPUT_METHOD_KEYBOARD: number;\n readonly DOM_INPUT_METHOD_MULTIMODAL: number;\n readonly DOM_INPUT_METHOD_OPTION: number;\n readonly DOM_INPUT_METHOD_PASTE: number;\n readonly DOM_INPUT_METHOD_SCRIPT: number;\n readonly DOM_INPUT_METHOD_UNKNOWN: number;\n readonly DOM_INPUT_METHOD_VOICE: number;\n}\n\ndeclare var TextEvent: {\n prototype: TextEvent;\n new(): TextEvent;\n readonly DOM_INPUT_METHOD_DROP: number;\n readonly DOM_INPUT_METHOD_HANDWRITING: number;\n readonly DOM_INPUT_METHOD_IME: number;\n readonly DOM_INPUT_METHOD_KEYBOARD: number;\n readonly DOM_INPUT_METHOD_MULTIMODAL: number;\n readonly DOM_INPUT_METHOD_OPTION: number;\n readonly DOM_INPUT_METHOD_PASTE: number;\n readonly DOM_INPUT_METHOD_SCRIPT: number;\n readonly DOM_INPUT_METHOD_UNKNOWN: number;\n readonly DOM_INPUT_METHOD_VOICE: number;\n}\n\ninterface TextMetrics {\n readonly width: number;\n}\n\ndeclare var TextMetrics: {\n prototype: TextMetrics;\n new(): TextMetrics;\n}\n\ninterface TextTrackEventMap {\n \"cuechange\": Event;\n \"error\": Event;\n \"load\": Event;\n}\n\ninterface TextTrack extends EventTarget {\n readonly activeCues: TextTrackCueList;\n readonly cues: TextTrackCueList;\n readonly inBandMetadataTrackDispatchType: string;\n readonly kind: string;\n readonly label: string;\n readonly language: string;\n mode: any;\n oncuechange: (this: TextTrack, ev: Event) => any;\n onerror: (this: TextTrack, ev: Event) => any;\n onload: (this: TextTrack, ev: Event) => any;\n readonly readyState: number;\n addCue(cue: TextTrackCue): void;\n removeCue(cue: TextTrackCue): void;\n readonly DISABLED: number;\n readonly ERROR: number;\n readonly HIDDEN: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n readonly SHOWING: number;\n addEventListener(type: K, listener: (this: TextTrack, ev: TextTrackEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var TextTrack: {\n prototype: TextTrack;\n new(): TextTrack;\n readonly DISABLED: number;\n readonly ERROR: number;\n readonly HIDDEN: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n readonly SHOWING: number;\n}\n\ninterface TextTrackCueEventMap {\n \"enter\": Event;\n \"exit\": Event;\n}\n\ninterface TextTrackCue extends EventTarget {\n endTime: number;\n id: string;\n onenter: (this: TextTrackCue, ev: Event) => any;\n onexit: (this: TextTrackCue, ev: Event) => any;\n pauseOnExit: boolean;\n startTime: number;\n text: string;\n readonly track: TextTrack;\n getCueAsHTML(): DocumentFragment;\n addEventListener(type: K, listener: (this: TextTrackCue, ev: TextTrackCueEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var TextTrackCue: {\n prototype: TextTrackCue;\n new(startTime: number, endTime: number, text: string): TextTrackCue;\n}\n\ninterface TextTrackCueList {\n readonly length: number;\n getCueById(id: string): TextTrackCue;\n item(index: number): TextTrackCue;\n [index: number]: TextTrackCue;\n}\n\ndeclare var TextTrackCueList: {\n prototype: TextTrackCueList;\n new(): TextTrackCueList;\n}\n\ninterface TextTrackListEventMap {\n \"addtrack\": TrackEvent;\n}\n\ninterface TextTrackList extends EventTarget {\n readonly length: number;\n onaddtrack: ((this: TextTrackList, ev: TrackEvent) => any) | null;\n item(index: number): TextTrack;\n addEventListener(type: K, listener: (this: TextTrackList, ev: TextTrackListEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [index: number]: TextTrack;\n}\n\ndeclare var TextTrackList: {\n prototype: TextTrackList;\n new(): TextTrackList;\n}\n\ninterface TimeRanges {\n readonly length: number;\n end(index: number): number;\n start(index: number): number;\n}\n\ndeclare var TimeRanges: {\n prototype: TimeRanges;\n new(): TimeRanges;\n}\n\ninterface Touch {\n readonly clientX: number;\n readonly clientY: number;\n readonly identifier: number;\n readonly pageX: number;\n readonly pageY: number;\n readonly screenX: number;\n readonly screenY: number;\n readonly target: EventTarget;\n}\n\ndeclare var Touch: {\n prototype: Touch;\n new(): Touch;\n}\n\ninterface TouchEvent extends UIEvent {\n readonly altKey: boolean;\n readonly changedTouches: TouchList;\n readonly charCode: number;\n readonly ctrlKey: boolean;\n readonly keyCode: number;\n readonly metaKey: boolean;\n readonly shiftKey: boolean;\n readonly targetTouches: TouchList;\n readonly touches: TouchList;\n readonly which: number;\n}\n\ndeclare var TouchEvent: {\n prototype: TouchEvent;\n new(type: string, touchEventInit?: TouchEventInit): TouchEvent;\n}\n\ninterface TouchList {\n readonly length: number;\n item(index: number): Touch | null;\n [index: number]: Touch;\n}\n\ndeclare var TouchList: {\n prototype: TouchList;\n new(): TouchList;\n}\n\ninterface TrackEvent extends Event {\n readonly track: VideoTrack | AudioTrack | TextTrack | null;\n}\n\ndeclare var TrackEvent: {\n prototype: TrackEvent;\n new(typeArg: string, eventInitDict?: TrackEventInit): TrackEvent;\n}\n\ninterface TransitionEvent extends Event {\n readonly elapsedTime: number;\n readonly propertyName: string;\n initTransitionEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, propertyNameArg: string, elapsedTimeArg: number): void;\n}\n\ndeclare var TransitionEvent: {\n prototype: TransitionEvent;\n new(typeArg: string, eventInitDict?: TransitionEventInit): TransitionEvent;\n}\n\ninterface TreeWalker {\n currentNode: Node;\n readonly expandEntityReferences: boolean;\n readonly filter: NodeFilter;\n readonly root: Node;\n readonly whatToShow: number;\n firstChild(): Node;\n lastChild(): Node;\n nextNode(): Node;\n nextSibling(): Node;\n parentNode(): Node;\n previousNode(): Node;\n previousSibling(): Node;\n}\n\ndeclare var TreeWalker: {\n prototype: TreeWalker;\n new(): TreeWalker;\n}\n\ninterface UIEvent extends Event {\n readonly detail: number;\n readonly view: Window;\n initUIEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number): void;\n}\n\ndeclare var UIEvent: {\n prototype: UIEvent;\n new(typeArg: string, eventInitDict?: UIEventInit): UIEvent;\n}\n\ninterface URL {\n hash: string;\n host: string;\n hostname: string;\n href: string;\n readonly origin: string;\n password: string;\n pathname: string;\n port: string;\n protocol: string;\n search: string;\n username: string;\n readonly searchParams: URLSearchParams;\n toString(): string;\n}\n\ndeclare var URL: {\n prototype: URL;\n new(url: string, base?: string): URL;\n createObjectURL(object: any, options?: ObjectURLOptions): string;\n revokeObjectURL(url: string): void;\n}\n\ninterface UnviewableContentIdentifiedEvent extends NavigationEventWithReferrer {\n readonly mediaType: string;\n}\n\ndeclare var UnviewableContentIdentifiedEvent: {\n prototype: UnviewableContentIdentifiedEvent;\n new(): UnviewableContentIdentifiedEvent;\n}\n\ninterface ValidityState {\n readonly badInput: boolean;\n readonly customError: boolean;\n readonly patternMismatch: boolean;\n readonly rangeOverflow: boolean;\n readonly rangeUnderflow: boolean;\n readonly stepMismatch: boolean;\n readonly tooLong: boolean;\n readonly typeMismatch: boolean;\n readonly valid: boolean;\n readonly valueMissing: boolean;\n}\n\ndeclare var ValidityState: {\n prototype: ValidityState;\n new(): ValidityState;\n}\n\ninterface VideoPlaybackQuality {\n readonly corruptedVideoFrames: number;\n readonly creationTime: number;\n readonly droppedVideoFrames: number;\n readonly totalFrameDelay: number;\n readonly totalVideoFrames: number;\n}\n\ndeclare var VideoPlaybackQuality: {\n prototype: VideoPlaybackQuality;\n new(): VideoPlaybackQuality;\n}\n\ninterface VideoTrack {\n readonly id: string;\n kind: string;\n readonly label: string;\n language: string;\n selected: boolean;\n readonly sourceBuffer: SourceBuffer;\n}\n\ndeclare var VideoTrack: {\n prototype: VideoTrack;\n new(): VideoTrack;\n}\n\ninterface VideoTrackListEventMap {\n \"addtrack\": TrackEvent;\n \"change\": Event;\n \"removetrack\": TrackEvent;\n}\n\ninterface VideoTrackList extends EventTarget {\n readonly length: number;\n onaddtrack: (this: VideoTrackList, ev: TrackEvent) => any;\n onchange: (this: VideoTrackList, ev: Event) => any;\n onremovetrack: (this: VideoTrackList, ev: TrackEvent) => any;\n readonly selectedIndex: number;\n getTrackById(id: string): VideoTrack | null;\n item(index: number): VideoTrack;\n addEventListener(type: K, listener: (this: VideoTrackList, ev: VideoTrackListEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [index: number]: VideoTrack;\n}\n\ndeclare var VideoTrackList: {\n prototype: VideoTrackList;\n new(): VideoTrackList;\n}\n\ninterface WEBGL_compressed_texture_s3tc {\n readonly COMPRESSED_RGBA_S3TC_DXT1_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT3_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT5_EXT: number;\n readonly COMPRESSED_RGB_S3TC_DXT1_EXT: number;\n}\n\ndeclare var WEBGL_compressed_texture_s3tc: {\n prototype: WEBGL_compressed_texture_s3tc;\n new(): WEBGL_compressed_texture_s3tc;\n readonly COMPRESSED_RGBA_S3TC_DXT1_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT3_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT5_EXT: number;\n readonly COMPRESSED_RGB_S3TC_DXT1_EXT: number;\n}\n\ninterface WEBGL_debug_renderer_info {\n readonly UNMASKED_RENDERER_WEBGL: number;\n readonly UNMASKED_VENDOR_WEBGL: number;\n}\n\ndeclare var WEBGL_debug_renderer_info: {\n prototype: WEBGL_debug_renderer_info;\n new(): WEBGL_debug_renderer_info;\n readonly UNMASKED_RENDERER_WEBGL: number;\n readonly UNMASKED_VENDOR_WEBGL: number;\n}\n\ninterface WEBGL_depth_texture {\n readonly UNSIGNED_INT_24_8_WEBGL: number;\n}\n\ndeclare var WEBGL_depth_texture: {\n prototype: WEBGL_depth_texture;\n new(): WEBGL_depth_texture;\n readonly UNSIGNED_INT_24_8_WEBGL: number;\n}\n\ninterface WaveShaperNode extends AudioNode {\n curve: Float32Array | null;\n oversample: OverSampleType;\n}\n\ndeclare var WaveShaperNode: {\n prototype: WaveShaperNode;\n new(): WaveShaperNode;\n}\n\ninterface WebAuthentication {\n getAssertion(assertionChallenge: any, options?: AssertionOptions): Promise;\n makeCredential(accountInformation: Account, cryptoParameters: ScopedCredentialParameters[], attestationChallenge: any, options?: ScopedCredentialOptions): Promise;\n}\n\ndeclare var WebAuthentication: {\n prototype: WebAuthentication;\n new(): WebAuthentication;\n}\n\ninterface WebAuthnAssertion {\n readonly authenticatorData: ArrayBuffer;\n readonly clientData: ArrayBuffer;\n readonly credential: ScopedCredential;\n readonly signature: ArrayBuffer;\n}\n\ndeclare var WebAuthnAssertion: {\n prototype: WebAuthnAssertion;\n new(): WebAuthnAssertion;\n}\n\ninterface WebGLActiveInfo {\n readonly name: string;\n readonly size: number;\n readonly type: number;\n}\n\ndeclare var WebGLActiveInfo: {\n prototype: WebGLActiveInfo;\n new(): WebGLActiveInfo;\n}\n\ninterface WebGLBuffer extends WebGLObject {\n}\n\ndeclare var WebGLBuffer: {\n prototype: WebGLBuffer;\n new(): WebGLBuffer;\n}\n\ninterface WebGLContextEvent extends Event {\n readonly statusMessage: string;\n}\n\ndeclare var WebGLContextEvent: {\n prototype: WebGLContextEvent;\n new(typeArg: string, eventInitDict?: WebGLContextEventInit): WebGLContextEvent;\n}\n\ninterface WebGLFramebuffer extends WebGLObject {\n}\n\ndeclare var WebGLFramebuffer: {\n prototype: WebGLFramebuffer;\n new(): WebGLFramebuffer;\n}\n\ninterface WebGLObject {\n}\n\ndeclare var WebGLObject: {\n prototype: WebGLObject;\n new(): WebGLObject;\n}\n\ninterface WebGLProgram extends WebGLObject {\n}\n\ndeclare var WebGLProgram: {\n prototype: WebGLProgram;\n new(): WebGLProgram;\n}\n\ninterface WebGLRenderbuffer extends WebGLObject {\n}\n\ndeclare var WebGLRenderbuffer: {\n prototype: WebGLRenderbuffer;\n new(): WebGLRenderbuffer;\n}\n\ninterface WebGLRenderingContext {\n readonly canvas: HTMLCanvasElement;\n readonly drawingBufferHeight: number;\n readonly drawingBufferWidth: number;\n activeTexture(texture: number): void;\n attachShader(program: WebGLProgram | null, shader: WebGLShader | null): void;\n bindAttribLocation(program: WebGLProgram | null, index: number, name: string): void;\n bindBuffer(target: number, buffer: WebGLBuffer | null): void;\n bindFramebuffer(target: number, framebuffer: WebGLFramebuffer | null): void;\n bindRenderbuffer(target: number, renderbuffer: WebGLRenderbuffer | null): void;\n bindTexture(target: number, texture: WebGLTexture | null): void;\n blendColor(red: number, green: number, blue: number, alpha: number): void;\n blendEquation(mode: number): void;\n blendEquationSeparate(modeRGB: number, modeAlpha: number): void;\n blendFunc(sfactor: number, dfactor: number): void;\n blendFuncSeparate(srcRGB: number, dstRGB: number, srcAlpha: number, dstAlpha: number): void;\n bufferData(target: number, size: number | ArrayBufferView | ArrayBuffer, usage: number): void;\n bufferSubData(target: number, offset: number, data: ArrayBufferView | ArrayBuffer): void;\n checkFramebufferStatus(target: number): number;\n clear(mask: number): void;\n clearColor(red: number, green: number, blue: number, alpha: number): void;\n clearDepth(depth: number): void;\n clearStencil(s: number): void;\n colorMask(red: boolean, green: boolean, blue: boolean, alpha: boolean): void;\n compileShader(shader: WebGLShader | null): void;\n compressedTexImage2D(target: number, level: number, internalformat: number, width: number, height: number, border: number, data: ArrayBufferView): void;\n compressedTexSubImage2D(target: number, level: number, xoffset: number, yoffset: number, width: number, height: number, format: number, data: ArrayBufferView): void;\n copyTexImage2D(target: number, level: number, internalformat: number, x: number, y: number, width: number, height: number, border: number): void;\n copyTexSubImage2D(target: number, level: number, xoffset: number, yoffset: number, x: number, y: number, width: number, height: number): void;\n createBuffer(): WebGLBuffer | null;\n createFramebuffer(): WebGLFramebuffer | null;\n createProgram(): WebGLProgram | null;\n createRenderbuffer(): WebGLRenderbuffer | null;\n createShader(type: number): WebGLShader | null;\n createTexture(): WebGLTexture | null;\n cullFace(mode: number): void;\n deleteBuffer(buffer: WebGLBuffer | null): void;\n deleteFramebuffer(framebuffer: WebGLFramebuffer | null): void;\n deleteProgram(program: WebGLProgram | null): void;\n deleteRenderbuffer(renderbuffer: WebGLRenderbuffer | null): void;\n deleteShader(shader: WebGLShader | null): void;\n deleteTexture(texture: WebGLTexture | null): void;\n depthFunc(func: number): void;\n depthMask(flag: boolean): void;\n depthRange(zNear: number, zFar: number): void;\n detachShader(program: WebGLProgram | null, shader: WebGLShader | null): void;\n disable(cap: number): void;\n disableVertexAttribArray(index: number): void;\n drawArrays(mode: number, first: number, count: number): void;\n drawElements(mode: number, count: number, type: number, offset: number): void;\n enable(cap: number): void;\n enableVertexAttribArray(index: number): void;\n finish(): void;\n flush(): void;\n framebufferRenderbuffer(target: number, attachment: number, renderbuffertarget: number, renderbuffer: WebGLRenderbuffer | null): void;\n framebufferTexture2D(target: number, attachment: number, textarget: number, texture: WebGLTexture | null, level: number): void;\n frontFace(mode: number): void;\n generateMipmap(target: number): void;\n getActiveAttrib(program: WebGLProgram | null, index: number): WebGLActiveInfo | null;\n getActiveUniform(program: WebGLProgram | null, index: number): WebGLActiveInfo | null;\n getAttachedShaders(program: WebGLProgram | null): WebGLShader[] | null;\n getAttribLocation(program: WebGLProgram | null, name: string): number;\n getBufferParameter(target: number, pname: number): any;\n getContextAttributes(): WebGLContextAttributes;\n getError(): number;\n getExtension(name: string): any;\n getFramebufferAttachmentParameter(target: number, attachment: number, pname: number): any;\n getParameter(pname: number): any;\n getProgramInfoLog(program: WebGLProgram | null): string | null;\n getProgramParameter(program: WebGLProgram | null, pname: number): any;\n getRenderbufferParameter(target: number, pname: number): any;\n getShaderInfoLog(shader: WebGLShader | null): string | null;\n getShaderParameter(shader: WebGLShader | null, pname: number): any;\n getShaderPrecisionFormat(shadertype: number, precisiontype: number): WebGLShaderPrecisionFormat | null;\n getShaderSource(shader: WebGLShader | null): string | null;\n getSupportedExtensions(): string[] | null;\n getTexParameter(target: number, pname: number): any;\n getUniform(program: WebGLProgram | null, location: WebGLUniformLocation | null): any;\n getUniformLocation(program: WebGLProgram | null, name: string): WebGLUniformLocation | null;\n getVertexAttrib(index: number, pname: number): any;\n getVertexAttribOffset(index: number, pname: number): number;\n hint(target: number, mode: number): void;\n isBuffer(buffer: WebGLBuffer | null): boolean;\n isContextLost(): boolean;\n isEnabled(cap: number): boolean;\n isFramebuffer(framebuffer: WebGLFramebuffer | null): boolean;\n isProgram(program: WebGLProgram | null): boolean;\n isRenderbuffer(renderbuffer: WebGLRenderbuffer | null): boolean;\n isShader(shader: WebGLShader | null): boolean;\n isTexture(texture: WebGLTexture | null): boolean;\n lineWidth(width: number): void;\n linkProgram(program: WebGLProgram | null): void;\n pixelStorei(pname: number, param: number | boolean): void;\n polygonOffset(factor: number, units: number): void;\n readPixels(x: number, y: number, width: number, height: number, format: number, type: number, pixels: ArrayBufferView | null): void;\n renderbufferStorage(target: number, internalformat: number, width: number, height: number): void;\n sampleCoverage(value: number, invert: boolean): void;\n scissor(x: number, y: number, width: number, height: number): void;\n shaderSource(shader: WebGLShader | null, source: string): void;\n stencilFunc(func: number, ref: number, mask: number): void;\n stencilFuncSeparate(face: number, func: number, ref: number, mask: number): void;\n stencilMask(mask: number): void;\n stencilMaskSeparate(face: number, mask: number): void;\n stencilOp(fail: number, zfail: number, zpass: number): void;\n stencilOpSeparate(face: number, fail: number, zfail: number, zpass: number): void;\n texImage2D(target: number, level: number, internalformat: number, width: number, height: number, border: number, format: number, type: number, pixels: ArrayBufferView | null): void;\n texImage2D(target: number, level: number, internalformat: number, format: number, type: number, pixels: ImageBitmap | ImageData | HTMLVideoElement | HTMLImageElement | HTMLCanvasElement): void;\n texParameterf(target: number, pname: number, param: number): void;\n texParameteri(target: number, pname: number, param: number): void;\n texSubImage2D(target: number, level: number, xoffset: number, yoffset: number, width: number, height: number, format: number, type: number, pixels: ArrayBufferView | null): void;\n texSubImage2D(target: number, level: number, xoffset: number, yoffset: number, format: number, type: number, pixels: ImageBitmap | ImageData | HTMLVideoElement | HTMLImageElement | HTMLCanvasElement): void;\n uniform1f(location: WebGLUniformLocation | null, x: number): void;\n uniform1fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform1i(location: WebGLUniformLocation | null, x: number): void;\n uniform1iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniform2f(location: WebGLUniformLocation | null, x: number, y: number): void;\n uniform2fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform2i(location: WebGLUniformLocation | null, x: number, y: number): void;\n uniform2iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniform3f(location: WebGLUniformLocation | null, x: number, y: number, z: number): void;\n uniform3fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform3i(location: WebGLUniformLocation | null, x: number, y: number, z: number): void;\n uniform3iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniform4f(location: WebGLUniformLocation | null, x: number, y: number, z: number, w: number): void;\n uniform4fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform4i(location: WebGLUniformLocation | null, x: number, y: number, z: number, w: number): void;\n uniform4iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniformMatrix2fv(location: WebGLUniformLocation, transpose: boolean, value: Float32Array | number[]): void;\n uniformMatrix3fv(location: WebGLUniformLocation, transpose: boolean, value: Float32Array | number[]): void;\n uniformMatrix4fv(location: WebGLUniformLocation, transpose: boolean, value: Float32Array | number[]): void;\n useProgram(program: WebGLProgram | null): void;\n validateProgram(program: WebGLProgram | null): void;\n vertexAttrib1f(indx: number, x: number): void;\n vertexAttrib1fv(indx: number, values: Float32Array | number[]): void;\n vertexAttrib2f(indx: number, x: number, y: number): void;\n vertexAttrib2fv(indx: number, values: Float32Array | number[]): void;\n vertexAttrib3f(indx: number, x: number, y: number, z: number): void;\n vertexAttrib3fv(indx: number, values: Float32Array | number[]): void;\n vertexAttrib4f(indx: number, x: number, y: number, z: number, w: number): void;\n vertexAttrib4fv(indx: number, values: Float32Array | number[]): void;\n vertexAttribPointer(indx: number, size: number, type: number, normalized: boolean, stride: number, offset: number): void;\n viewport(x: number, y: number, width: number, height: number): void;\n readonly ACTIVE_ATTRIBUTES: number;\n readonly ACTIVE_TEXTURE: number;\n readonly ACTIVE_UNIFORMS: number;\n readonly ALIASED_LINE_WIDTH_RANGE: number;\n readonly ALIASED_POINT_SIZE_RANGE: number;\n readonly ALPHA: number;\n readonly ALPHA_BITS: number;\n readonly ALWAYS: number;\n readonly ARRAY_BUFFER: number;\n readonly ARRAY_BUFFER_BINDING: number;\n readonly ATTACHED_SHADERS: number;\n readonly BACK: number;\n readonly BLEND: number;\n readonly BLEND_COLOR: number;\n readonly BLEND_DST_ALPHA: number;\n readonly BLEND_DST_RGB: number;\n readonly BLEND_EQUATION: number;\n readonly BLEND_EQUATION_ALPHA: number;\n readonly BLEND_EQUATION_RGB: number;\n readonly BLEND_SRC_ALPHA: number;\n readonly BLEND_SRC_RGB: number;\n readonly BLUE_BITS: number;\n readonly BOOL: number;\n readonly BOOL_VEC2: number;\n readonly BOOL_VEC3: number;\n readonly BOOL_VEC4: number;\n readonly BROWSER_DEFAULT_WEBGL: number;\n readonly BUFFER_SIZE: number;\n readonly BUFFER_USAGE: number;\n readonly BYTE: number;\n readonly CCW: number;\n readonly CLAMP_TO_EDGE: number;\n readonly COLOR_ATTACHMENT0: number;\n readonly COLOR_BUFFER_BIT: number;\n readonly COLOR_CLEAR_VALUE: number;\n readonly COLOR_WRITEMASK: number;\n readonly COMPILE_STATUS: number;\n readonly COMPRESSED_TEXTURE_FORMATS: number;\n readonly CONSTANT_ALPHA: number;\n readonly CONSTANT_COLOR: number;\n readonly CONTEXT_LOST_WEBGL: number;\n readonly CULL_FACE: number;\n readonly CULL_FACE_MODE: number;\n readonly CURRENT_PROGRAM: number;\n readonly CURRENT_VERTEX_ATTRIB: number;\n readonly CW: number;\n readonly DECR: number;\n readonly DECR_WRAP: number;\n readonly DELETE_STATUS: number;\n readonly DEPTH_ATTACHMENT: number;\n readonly DEPTH_BITS: number;\n readonly DEPTH_BUFFER_BIT: number;\n readonly DEPTH_CLEAR_VALUE: number;\n readonly DEPTH_COMPONENT: number;\n readonly DEPTH_COMPONENT16: number;\n readonly DEPTH_FUNC: number;\n readonly DEPTH_RANGE: number;\n readonly DEPTH_STENCIL: number;\n readonly DEPTH_STENCIL_ATTACHMENT: number;\n readonly DEPTH_TEST: number;\n readonly DEPTH_WRITEMASK: number;\n readonly DITHER: number;\n readonly DONT_CARE: number;\n readonly DST_ALPHA: number;\n readonly DST_COLOR: number;\n readonly DYNAMIC_DRAW: number;\n readonly ELEMENT_ARRAY_BUFFER: number;\n readonly ELEMENT_ARRAY_BUFFER_BINDING: number;\n readonly EQUAL: number;\n readonly FASTEST: number;\n readonly FLOAT: number;\n readonly FLOAT_MAT2: number;\n readonly FLOAT_MAT3: number;\n readonly FLOAT_MAT4: number;\n readonly FLOAT_VEC2: number;\n readonly FLOAT_VEC3: number;\n readonly FLOAT_VEC4: number;\n readonly FRAGMENT_SHADER: number;\n readonly FRAMEBUFFER: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_NAME: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL: number;\n readonly FRAMEBUFFER_BINDING: number;\n readonly FRAMEBUFFER_COMPLETE: number;\n readonly FRAMEBUFFER_INCOMPLETE_ATTACHMENT: number;\n readonly FRAMEBUFFER_INCOMPLETE_DIMENSIONS: number;\n readonly FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT: number;\n readonly FRAMEBUFFER_UNSUPPORTED: number;\n readonly FRONT: number;\n readonly FRONT_AND_BACK: number;\n readonly FRONT_FACE: number;\n readonly FUNC_ADD: number;\n readonly FUNC_REVERSE_SUBTRACT: number;\n readonly FUNC_SUBTRACT: number;\n readonly GENERATE_MIPMAP_HINT: number;\n readonly GEQUAL: number;\n readonly GREATER: number;\n readonly GREEN_BITS: number;\n readonly HIGH_FLOAT: number;\n readonly HIGH_INT: number;\n readonly IMPLEMENTATION_COLOR_READ_FORMAT: number;\n readonly IMPLEMENTATION_COLOR_READ_TYPE: number;\n readonly INCR: number;\n readonly INCR_WRAP: number;\n readonly INT: number;\n readonly INT_VEC2: number;\n readonly INT_VEC3: number;\n readonly INT_VEC4: number;\n readonly INVALID_ENUM: number;\n readonly INVALID_FRAMEBUFFER_OPERATION: number;\n readonly INVALID_OPERATION: number;\n readonly INVALID_VALUE: number;\n readonly INVERT: number;\n readonly KEEP: number;\n readonly LEQUAL: number;\n readonly LESS: number;\n readonly LINEAR: number;\n readonly LINEAR_MIPMAP_LINEAR: number;\n readonly LINEAR_MIPMAP_NEAREST: number;\n readonly LINES: number;\n readonly LINE_LOOP: number;\n readonly LINE_STRIP: number;\n readonly LINE_WIDTH: number;\n readonly LINK_STATUS: number;\n readonly LOW_FLOAT: number;\n readonly LOW_INT: number;\n readonly LUMINANCE: number;\n readonly LUMINANCE_ALPHA: number;\n readonly MAX_COMBINED_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_CUBE_MAP_TEXTURE_SIZE: number;\n readonly MAX_FRAGMENT_UNIFORM_VECTORS: number;\n readonly MAX_RENDERBUFFER_SIZE: number;\n readonly MAX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_TEXTURE_SIZE: number;\n readonly MAX_VARYING_VECTORS: number;\n readonly MAX_VERTEX_ATTRIBS: number;\n readonly MAX_VERTEX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_VERTEX_UNIFORM_VECTORS: number;\n readonly MAX_VIEWPORT_DIMS: number;\n readonly MEDIUM_FLOAT: number;\n readonly MEDIUM_INT: number;\n readonly MIRRORED_REPEAT: number;\n readonly NEAREST: number;\n readonly NEAREST_MIPMAP_LINEAR: number;\n readonly NEAREST_MIPMAP_NEAREST: number;\n readonly NEVER: number;\n readonly NICEST: number;\n readonly NONE: number;\n readonly NOTEQUAL: number;\n readonly NO_ERROR: number;\n readonly ONE: number;\n readonly ONE_MINUS_CONSTANT_ALPHA: number;\n readonly ONE_MINUS_CONSTANT_COLOR: number;\n readonly ONE_MINUS_DST_ALPHA: number;\n readonly ONE_MINUS_DST_COLOR: number;\n readonly ONE_MINUS_SRC_ALPHA: number;\n readonly ONE_MINUS_SRC_COLOR: number;\n readonly OUT_OF_MEMORY: number;\n readonly PACK_ALIGNMENT: number;\n readonly POINTS: number;\n readonly POLYGON_OFFSET_FACTOR: number;\n readonly POLYGON_OFFSET_FILL: number;\n readonly POLYGON_OFFSET_UNITS: number;\n readonly RED_BITS: number;\n readonly RENDERBUFFER: number;\n readonly RENDERBUFFER_ALPHA_SIZE: number;\n readonly RENDERBUFFER_BINDING: number;\n readonly RENDERBUFFER_BLUE_SIZE: number;\n readonly RENDERBUFFER_DEPTH_SIZE: number;\n readonly RENDERBUFFER_GREEN_SIZE: number;\n readonly RENDERBUFFER_HEIGHT: number;\n readonly RENDERBUFFER_INTERNAL_FORMAT: number;\n readonly RENDERBUFFER_RED_SIZE: number;\n readonly RENDERBUFFER_STENCIL_SIZE: number;\n readonly RENDERBUFFER_WIDTH: number;\n readonly RENDERER: number;\n readonly REPEAT: number;\n readonly REPLACE: number;\n readonly RGB: number;\n readonly RGB565: number;\n readonly RGB5_A1: number;\n readonly RGBA: number;\n readonly RGBA4: number;\n readonly SAMPLER_2D: number;\n readonly SAMPLER_CUBE: number;\n readonly SAMPLES: number;\n readonly SAMPLE_ALPHA_TO_COVERAGE: number;\n readonly SAMPLE_BUFFERS: number;\n readonly SAMPLE_COVERAGE: number;\n readonly SAMPLE_COVERAGE_INVERT: number;\n readonly SAMPLE_COVERAGE_VALUE: number;\n readonly SCISSOR_BOX: number;\n readonly SCISSOR_TEST: number;\n readonly SHADER_TYPE: number;\n readonly SHADING_LANGUAGE_VERSION: number;\n readonly SHORT: number;\n readonly SRC_ALPHA: number;\n readonly SRC_ALPHA_SATURATE: number;\n readonly SRC_COLOR: number;\n readonly STATIC_DRAW: number;\n readonly STENCIL_ATTACHMENT: number;\n readonly STENCIL_BACK_FAIL: number;\n readonly STENCIL_BACK_FUNC: number;\n readonly STENCIL_BACK_PASS_DEPTH_FAIL: number;\n readonly STENCIL_BACK_PASS_DEPTH_PASS: number;\n readonly STENCIL_BACK_REF: number;\n readonly STENCIL_BACK_VALUE_MASK: number;\n readonly STENCIL_BACK_WRITEMASK: number;\n readonly STENCIL_BITS: number;\n readonly STENCIL_BUFFER_BIT: number;\n readonly STENCIL_CLEAR_VALUE: number;\n readonly STENCIL_FAIL: number;\n readonly STENCIL_FUNC: number;\n readonly STENCIL_INDEX: number;\n readonly STENCIL_INDEX8: number;\n readonly STENCIL_PASS_DEPTH_FAIL: number;\n readonly STENCIL_PASS_DEPTH_PASS: number;\n readonly STENCIL_REF: number;\n readonly STENCIL_TEST: number;\n readonly STENCIL_VALUE_MASK: number;\n readonly STENCIL_WRITEMASK: number;\n readonly STREAM_DRAW: number;\n readonly SUBPIXEL_BITS: number;\n readonly TEXTURE: number;\n readonly TEXTURE0: number;\n readonly TEXTURE1: number;\n readonly TEXTURE10: number;\n readonly TEXTURE11: number;\n readonly TEXTURE12: number;\n readonly TEXTURE13: number;\n readonly TEXTURE14: number;\n readonly TEXTURE15: number;\n readonly TEXTURE16: number;\n readonly TEXTURE17: number;\n readonly TEXTURE18: number;\n readonly TEXTURE19: number;\n readonly TEXTURE2: number;\n readonly TEXTURE20: number;\n readonly TEXTURE21: number;\n readonly TEXTURE22: number;\n readonly TEXTURE23: number;\n readonly TEXTURE24: number;\n readonly TEXTURE25: number;\n readonly TEXTURE26: number;\n readonly TEXTURE27: number;\n readonly TEXTURE28: number;\n readonly TEXTURE29: number;\n readonly TEXTURE3: number;\n readonly TEXTURE30: number;\n readonly TEXTURE31: number;\n readonly TEXTURE4: number;\n readonly TEXTURE5: number;\n readonly TEXTURE6: number;\n readonly TEXTURE7: number;\n readonly TEXTURE8: number;\n readonly TEXTURE9: number;\n readonly TEXTURE_2D: number;\n readonly TEXTURE_BINDING_2D: number;\n readonly TEXTURE_BINDING_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_X: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Z: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_X: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Z: number;\n readonly TEXTURE_MAG_FILTER: number;\n readonly TEXTURE_MIN_FILTER: number;\n readonly TEXTURE_WRAP_S: number;\n readonly TEXTURE_WRAP_T: number;\n readonly TRIANGLES: number;\n readonly TRIANGLE_FAN: number;\n readonly TRIANGLE_STRIP: number;\n readonly UNPACK_ALIGNMENT: number;\n readonly UNPACK_COLORSPACE_CONVERSION_WEBGL: number;\n readonly UNPACK_FLIP_Y_WEBGL: number;\n readonly UNPACK_PREMULTIPLY_ALPHA_WEBGL: number;\n readonly UNSIGNED_BYTE: number;\n readonly UNSIGNED_INT: number;\n readonly UNSIGNED_SHORT: number;\n readonly UNSIGNED_SHORT_4_4_4_4: number;\n readonly UNSIGNED_SHORT_5_5_5_1: number;\n readonly UNSIGNED_SHORT_5_6_5: number;\n readonly VALIDATE_STATUS: number;\n readonly VENDOR: number;\n readonly VERSION: number;\n readonly VERTEX_ATTRIB_ARRAY_BUFFER_BINDING: number;\n readonly VERTEX_ATTRIB_ARRAY_ENABLED: number;\n readonly VERTEX_ATTRIB_ARRAY_NORMALIZED: number;\n readonly VERTEX_ATTRIB_ARRAY_POINTER: number;\n readonly VERTEX_ATTRIB_ARRAY_SIZE: number;\n readonly VERTEX_ATTRIB_ARRAY_STRIDE: number;\n readonly VERTEX_ATTRIB_ARRAY_TYPE: number;\n readonly VERTEX_SHADER: number;\n readonly VIEWPORT: number;\n readonly ZERO: number;\n}\n\ndeclare var WebGLRenderingContext: {\n prototype: WebGLRenderingContext;\n new(): WebGLRenderingContext;\n readonly ACTIVE_ATTRIBUTES: number;\n readonly ACTIVE_TEXTURE: number;\n readonly ACTIVE_UNIFORMS: number;\n readonly ALIASED_LINE_WIDTH_RANGE: number;\n readonly ALIASED_POINT_SIZE_RANGE: number;\n readonly ALPHA: number;\n readonly ALPHA_BITS: number;\n readonly ALWAYS: number;\n readonly ARRAY_BUFFER: number;\n readonly ARRAY_BUFFER_BINDING: number;\n readonly ATTACHED_SHADERS: number;\n readonly BACK: number;\n readonly BLEND: number;\n readonly BLEND_COLOR: number;\n readonly BLEND_DST_ALPHA: number;\n readonly BLEND_DST_RGB: number;\n readonly BLEND_EQUATION: number;\n readonly BLEND_EQUATION_ALPHA: number;\n readonly BLEND_EQUATION_RGB: number;\n readonly BLEND_SRC_ALPHA: number;\n readonly BLEND_SRC_RGB: number;\n readonly BLUE_BITS: number;\n readonly BOOL: number;\n readonly BOOL_VEC2: number;\n readonly BOOL_VEC3: number;\n readonly BOOL_VEC4: number;\n readonly BROWSER_DEFAULT_WEBGL: number;\n readonly BUFFER_SIZE: number;\n readonly BUFFER_USAGE: number;\n readonly BYTE: number;\n readonly CCW: number;\n readonly CLAMP_TO_EDGE: number;\n readonly COLOR_ATTACHMENT0: number;\n readonly COLOR_BUFFER_BIT: number;\n readonly COLOR_CLEAR_VALUE: number;\n readonly COLOR_WRITEMASK: number;\n readonly COMPILE_STATUS: number;\n readonly COMPRESSED_TEXTURE_FORMATS: number;\n readonly CONSTANT_ALPHA: number;\n readonly CONSTANT_COLOR: number;\n readonly CONTEXT_LOST_WEBGL: number;\n readonly CULL_FACE: number;\n readonly CULL_FACE_MODE: number;\n readonly CURRENT_PROGRAM: number;\n readonly CURRENT_VERTEX_ATTRIB: number;\n readonly CW: number;\n readonly DECR: number;\n readonly DECR_WRAP: number;\n readonly DELETE_STATUS: number;\n readonly DEPTH_ATTACHMENT: number;\n readonly DEPTH_BITS: number;\n readonly DEPTH_BUFFER_BIT: number;\n readonly DEPTH_CLEAR_VALUE: number;\n readonly DEPTH_COMPONENT: number;\n readonly DEPTH_COMPONENT16: number;\n readonly DEPTH_FUNC: number;\n readonly DEPTH_RANGE: number;\n readonly DEPTH_STENCIL: number;\n readonly DEPTH_STENCIL_ATTACHMENT: number;\n readonly DEPTH_TEST: number;\n readonly DEPTH_WRITEMASK: number;\n readonly DITHER: number;\n readonly DONT_CARE: number;\n readonly DST_ALPHA: number;\n readonly DST_COLOR: number;\n readonly DYNAMIC_DRAW: number;\n readonly ELEMENT_ARRAY_BUFFER: number;\n readonly ELEMENT_ARRAY_BUFFER_BINDING: number;\n readonly EQUAL: number;\n readonly FASTEST: number;\n readonly FLOAT: number;\n readonly FLOAT_MAT2: number;\n readonly FLOAT_MAT3: number;\n readonly FLOAT_MAT4: number;\n readonly FLOAT_VEC2: number;\n readonly FLOAT_VEC3: number;\n readonly FLOAT_VEC4: number;\n readonly FRAGMENT_SHADER: number;\n readonly FRAMEBUFFER: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_NAME: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL: number;\n readonly FRAMEBUFFER_BINDING: number;\n readonly FRAMEBUFFER_COMPLETE: number;\n readonly FRAMEBUFFER_INCOMPLETE_ATTACHMENT: number;\n readonly FRAMEBUFFER_INCOMPLETE_DIMENSIONS: number;\n readonly FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT: number;\n readonly FRAMEBUFFER_UNSUPPORTED: number;\n readonly FRONT: number;\n readonly FRONT_AND_BACK: number;\n readonly FRONT_FACE: number;\n readonly FUNC_ADD: number;\n readonly FUNC_REVERSE_SUBTRACT: number;\n readonly FUNC_SUBTRACT: number;\n readonly GENERATE_MIPMAP_HINT: number;\n readonly GEQUAL: number;\n readonly GREATER: number;\n readonly GREEN_BITS: number;\n readonly HIGH_FLOAT: number;\n readonly HIGH_INT: number;\n readonly IMPLEMENTATION_COLOR_READ_FORMAT: number;\n readonly IMPLEMENTATION_COLOR_READ_TYPE: number;\n readonly INCR: number;\n readonly INCR_WRAP: number;\n readonly INT: number;\n readonly INT_VEC2: number;\n readonly INT_VEC3: number;\n readonly INT_VEC4: number;\n readonly INVALID_ENUM: number;\n readonly INVALID_FRAMEBUFFER_OPERATION: number;\n readonly INVALID_OPERATION: number;\n readonly INVALID_VALUE: number;\n readonly INVERT: number;\n readonly KEEP: number;\n readonly LEQUAL: number;\n readonly LESS: number;\n readonly LINEAR: number;\n readonly LINEAR_MIPMAP_LINEAR: number;\n readonly LINEAR_MIPMAP_NEAREST: number;\n readonly LINES: number;\n readonly LINE_LOOP: number;\n readonly LINE_STRIP: number;\n readonly LINE_WIDTH: number;\n readonly LINK_STATUS: number;\n readonly LOW_FLOAT: number;\n readonly LOW_INT: number;\n readonly LUMINANCE: number;\n readonly LUMINANCE_ALPHA: number;\n readonly MAX_COMBINED_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_CUBE_MAP_TEXTURE_SIZE: number;\n readonly MAX_FRAGMENT_UNIFORM_VECTORS: number;\n readonly MAX_RENDERBUFFER_SIZE: number;\n readonly MAX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_TEXTURE_SIZE: number;\n readonly MAX_VARYING_VECTORS: number;\n readonly MAX_VERTEX_ATTRIBS: number;\n readonly MAX_VERTEX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_VERTEX_UNIFORM_VECTORS: number;\n readonly MAX_VIEWPORT_DIMS: number;\n readonly MEDIUM_FLOAT: number;\n readonly MEDIUM_INT: number;\n readonly MIRRORED_REPEAT: number;\n readonly NEAREST: number;\n readonly NEAREST_MIPMAP_LINEAR: number;\n readonly NEAREST_MIPMAP_NEAREST: number;\n readonly NEVER: number;\n readonly NICEST: number;\n readonly NONE: number;\n readonly NOTEQUAL: number;\n readonly NO_ERROR: number;\n readonly ONE: number;\n readonly ONE_MINUS_CONSTANT_ALPHA: number;\n readonly ONE_MINUS_CONSTANT_COLOR: number;\n readonly ONE_MINUS_DST_ALPHA: number;\n readonly ONE_MINUS_DST_COLOR: number;\n readonly ONE_MINUS_SRC_ALPHA: number;\n readonly ONE_MINUS_SRC_COLOR: number;\n readonly OUT_OF_MEMORY: number;\n readonly PACK_ALIGNMENT: number;\n readonly POINTS: number;\n readonly POLYGON_OFFSET_FACTOR: number;\n readonly POLYGON_OFFSET_FILL: number;\n readonly POLYGON_OFFSET_UNITS: number;\n readonly RED_BITS: number;\n readonly RENDERBUFFER: number;\n readonly RENDERBUFFER_ALPHA_SIZE: number;\n readonly RENDERBUFFER_BINDING: number;\n readonly RENDERBUFFER_BLUE_SIZE: number;\n readonly RENDERBUFFER_DEPTH_SIZE: number;\n readonly RENDERBUFFER_GREEN_SIZE: number;\n readonly RENDERBUFFER_HEIGHT: number;\n readonly RENDERBUFFER_INTERNAL_FORMAT: number;\n readonly RENDERBUFFER_RED_SIZE: number;\n readonly RENDERBUFFER_STENCIL_SIZE: number;\n readonly RENDERBUFFER_WIDTH: number;\n readonly RENDERER: number;\n readonly REPEAT: number;\n readonly REPLACE: number;\n readonly RGB: number;\n readonly RGB565: number;\n readonly RGB5_A1: number;\n readonly RGBA: number;\n readonly RGBA4: number;\n readonly SAMPLER_2D: number;\n readonly SAMPLER_CUBE: number;\n readonly SAMPLES: number;\n readonly SAMPLE_ALPHA_TO_COVERAGE: number;\n readonly SAMPLE_BUFFERS: number;\n readonly SAMPLE_COVERAGE: number;\n readonly SAMPLE_COVERAGE_INVERT: number;\n readonly SAMPLE_COVERAGE_VALUE: number;\n readonly SCISSOR_BOX: number;\n readonly SCISSOR_TEST: number;\n readonly SHADER_TYPE: number;\n readonly SHADING_LANGUAGE_VERSION: number;\n readonly SHORT: number;\n readonly SRC_ALPHA: number;\n readonly SRC_ALPHA_SATURATE: number;\n readonly SRC_COLOR: number;\n readonly STATIC_DRAW: number;\n readonly STENCIL_ATTACHMENT: number;\n readonly STENCIL_BACK_FAIL: number;\n readonly STENCIL_BACK_FUNC: number;\n readonly STENCIL_BACK_PASS_DEPTH_FAIL: number;\n readonly STENCIL_BACK_PASS_DEPTH_PASS: number;\n readonly STENCIL_BACK_REF: number;\n readonly STENCIL_BACK_VALUE_MASK: number;\n readonly STENCIL_BACK_WRITEMASK: number;\n readonly STENCIL_BITS: number;\n readonly STENCIL_BUFFER_BIT: number;\n readonly STENCIL_CLEAR_VALUE: number;\n readonly STENCIL_FAIL: number;\n readonly STENCIL_FUNC: number;\n readonly STENCIL_INDEX: number;\n readonly STENCIL_INDEX8: number;\n readonly STENCIL_PASS_DEPTH_FAIL: number;\n readonly STENCIL_PASS_DEPTH_PASS: number;\n readonly STENCIL_REF: number;\n readonly STENCIL_TEST: number;\n readonly STENCIL_VALUE_MASK: number;\n readonly STENCIL_WRITEMASK: number;\n readonly STREAM_DRAW: number;\n readonly SUBPIXEL_BITS: number;\n readonly TEXTURE: number;\n readonly TEXTURE0: number;\n readonly TEXTURE1: number;\n readonly TEXTURE10: number;\n readonly TEXTURE11: number;\n readonly TEXTURE12: number;\n readonly TEXTURE13: number;\n readonly TEXTURE14: number;\n readonly TEXTURE15: number;\n readonly TEXTURE16: number;\n readonly TEXTURE17: number;\n readonly TEXTURE18: number;\n readonly TEXTURE19: number;\n readonly TEXTURE2: number;\n readonly TEXTURE20: number;\n readonly TEXTURE21: number;\n readonly TEXTURE22: number;\n readonly TEXTURE23: number;\n readonly TEXTURE24: number;\n readonly TEXTURE25: number;\n readonly TEXTURE26: number;\n readonly TEXTURE27: number;\n readonly TEXTURE28: number;\n readonly TEXTURE29: number;\n readonly TEXTURE3: number;\n readonly TEXTURE30: number;\n readonly TEXTURE31: number;\n readonly TEXTURE4: number;\n readonly TEXTURE5: number;\n readonly TEXTURE6: number;\n readonly TEXTURE7: number;\n readonly TEXTURE8: number;\n readonly TEXTURE9: number;\n readonly TEXTURE_2D: number;\n readonly TEXTURE_BINDING_2D: number;\n readonly TEXTURE_BINDING_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_X: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Z: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_X: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Z: number;\n readonly TEXTURE_MAG_FILTER: number;\n readonly TEXTURE_MIN_FILTER: number;\n readonly TEXTURE_WRAP_S: number;\n readonly TEXTURE_WRAP_T: number;\n readonly TRIANGLES: number;\n readonly TRIANGLE_FAN: number;\n readonly TRIANGLE_STRIP: number;\n readonly UNPACK_ALIGNMENT: number;\n readonly UNPACK_COLORSPACE_CONVERSION_WEBGL: number;\n readonly UNPACK_FLIP_Y_WEBGL: number;\n readonly UNPACK_PREMULTIPLY_ALPHA_WEBGL: number;\n readonly UNSIGNED_BYTE: number;\n readonly UNSIGNED_INT: number;\n readonly UNSIGNED_SHORT: number;\n readonly UNSIGNED_SHORT_4_4_4_4: number;\n readonly UNSIGNED_SHORT_5_5_5_1: number;\n readonly UNSIGNED_SHORT_5_6_5: number;\n readonly VALIDATE_STATUS: number;\n readonly VENDOR: number;\n readonly VERSION: number;\n readonly VERTEX_ATTRIB_ARRAY_BUFFER_BINDING: number;\n readonly VERTEX_ATTRIB_ARRAY_ENABLED: number;\n readonly VERTEX_ATTRIB_ARRAY_NORMALIZED: number;\n readonly VERTEX_ATTRIB_ARRAY_POINTER: number;\n readonly VERTEX_ATTRIB_ARRAY_SIZE: number;\n readonly VERTEX_ATTRIB_ARRAY_STRIDE: number;\n readonly VERTEX_ATTRIB_ARRAY_TYPE: number;\n readonly VERTEX_SHADER: number;\n readonly VIEWPORT: number;\n readonly ZERO: number;\n}\n\ninterface WebGLShader extends WebGLObject {\n}\n\ndeclare var WebGLShader: {\n prototype: WebGLShader;\n new(): WebGLShader;\n}\n\ninterface WebGLShaderPrecisionFormat {\n readonly precision: number;\n readonly rangeMax: number;\n readonly rangeMin: number;\n}\n\ndeclare var WebGLShaderPrecisionFormat: {\n prototype: WebGLShaderPrecisionFormat;\n new(): WebGLShaderPrecisionFormat;\n}\n\ninterface WebGLTexture extends WebGLObject {\n}\n\ndeclare var WebGLTexture: {\n prototype: WebGLTexture;\n new(): WebGLTexture;\n}\n\ninterface WebGLUniformLocation {\n}\n\ndeclare var WebGLUniformLocation: {\n prototype: WebGLUniformLocation;\n new(): WebGLUniformLocation;\n}\n\ninterface WebKitCSSMatrix {\n a: number;\n b: number;\n c: number;\n d: number;\n e: number;\n f: number;\n m11: number;\n m12: number;\n m13: number;\n m14: number;\n m21: number;\n m22: number;\n m23: number;\n m24: number;\n m31: number;\n m32: number;\n m33: number;\n m34: number;\n m41: number;\n m42: number;\n m43: number;\n m44: number;\n inverse(): WebKitCSSMatrix;\n multiply(secondMatrix: WebKitCSSMatrix): WebKitCSSMatrix;\n rotate(angleX: number, angleY?: number, angleZ?: number): WebKitCSSMatrix;\n rotateAxisAngle(x: number, y: number, z: number, angle: number): WebKitCSSMatrix;\n scale(scaleX: number, scaleY?: number, scaleZ?: number): WebKitCSSMatrix;\n setMatrixValue(value: string): void;\n skewX(angle: number): WebKitCSSMatrix;\n skewY(angle: number): WebKitCSSMatrix;\n toString(): string;\n translate(x: number, y: number, z?: number): WebKitCSSMatrix;\n}\n\ndeclare var WebKitCSSMatrix: {\n prototype: WebKitCSSMatrix;\n new(text?: string): WebKitCSSMatrix;\n}\n\ninterface WebKitDirectoryEntry extends WebKitEntry {\n createReader(): WebKitDirectoryReader;\n}\n\ndeclare var WebKitDirectoryEntry: {\n prototype: WebKitDirectoryEntry;\n new(): WebKitDirectoryEntry;\n}\n\ninterface WebKitDirectoryReader {\n readEntries(successCallback: WebKitEntriesCallback, errorCallback?: WebKitErrorCallback): void;\n}\n\ndeclare var WebKitDirectoryReader: {\n prototype: WebKitDirectoryReader;\n new(): WebKitDirectoryReader;\n}\n\ninterface WebKitEntry {\n readonly filesystem: WebKitFileSystem;\n readonly fullPath: string;\n readonly isDirectory: boolean;\n readonly isFile: boolean;\n readonly name: string;\n}\n\ndeclare var WebKitEntry: {\n prototype: WebKitEntry;\n new(): WebKitEntry;\n}\n\ninterface WebKitFileEntry extends WebKitEntry {\n file(successCallback: WebKitFileCallback, errorCallback?: WebKitErrorCallback): void;\n}\n\ndeclare var WebKitFileEntry: {\n prototype: WebKitFileEntry;\n new(): WebKitFileEntry;\n}\n\ninterface WebKitFileSystem {\n readonly name: string;\n readonly root: WebKitDirectoryEntry;\n}\n\ndeclare var WebKitFileSystem: {\n prototype: WebKitFileSystem;\n new(): WebKitFileSystem;\n}\n\ninterface WebKitPoint {\n x: number;\n y: number;\n}\n\ndeclare var WebKitPoint: {\n prototype: WebKitPoint;\n new(x?: number, y?: number): WebKitPoint;\n}\n\ninterface WebSocketEventMap {\n \"close\": CloseEvent;\n \"error\": Event;\n \"message\": MessageEvent;\n \"open\": Event;\n}\n\ninterface WebSocket extends EventTarget {\n binaryType: string;\n readonly bufferedAmount: number;\n readonly extensions: string;\n onclose: (this: WebSocket, ev: CloseEvent) => any;\n onerror: (this: WebSocket, ev: Event) => any;\n onmessage: (this: WebSocket, ev: MessageEvent) => any;\n onopen: (this: WebSocket, ev: Event) => any;\n readonly protocol: string;\n readonly readyState: number;\n readonly url: string;\n close(code?: number, reason?: string): void;\n send(data: any): void;\n readonly CLOSED: number;\n readonly CLOSING: number;\n readonly CONNECTING: number;\n readonly OPEN: number;\n addEventListener(type: K, listener: (this: WebSocket, ev: WebSocketEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var WebSocket: {\n prototype: WebSocket;\n new(url: string, protocols?: string | string[]): WebSocket;\n readonly CLOSED: number;\n readonly CLOSING: number;\n readonly CONNECTING: number;\n readonly OPEN: number;\n}\n\ninterface WheelEvent extends MouseEvent {\n readonly deltaMode: number;\n readonly deltaX: number;\n readonly deltaY: number;\n readonly deltaZ: number;\n readonly wheelDelta: number;\n readonly wheelDeltaX: number;\n readonly wheelDeltaY: number;\n getCurrentPoint(element: Element): void;\n initWheelEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, buttonArg: number, relatedTargetArg: EventTarget, modifiersListArg: string, deltaXArg: number, deltaYArg: number, deltaZArg: number, deltaMode: number): void;\n readonly DOM_DELTA_LINE: number;\n readonly DOM_DELTA_PAGE: number;\n readonly DOM_DELTA_PIXEL: number;\n}\n\ndeclare var WheelEvent: {\n prototype: WheelEvent;\n new(typeArg: string, eventInitDict?: WheelEventInit): WheelEvent;\n readonly DOM_DELTA_LINE: number;\n readonly DOM_DELTA_PAGE: number;\n readonly DOM_DELTA_PIXEL: number;\n}\n\ninterface WindowEventMap extends GlobalEventHandlersEventMap {\n \"abort\": UIEvent;\n \"afterprint\": Event;\n \"beforeprint\": Event;\n \"beforeunload\": BeforeUnloadEvent;\n \"blur\": FocusEvent;\n \"canplay\": Event;\n \"canplaythrough\": Event;\n \"change\": Event;\n \"click\": MouseEvent;\n \"compassneedscalibration\": Event;\n \"contextmenu\": PointerEvent;\n \"dblclick\": MouseEvent;\n \"devicelight\": DeviceLightEvent;\n \"devicemotion\": DeviceMotionEvent;\n \"deviceorientation\": DeviceOrientationEvent;\n \"drag\": DragEvent;\n \"dragend\": DragEvent;\n \"dragenter\": DragEvent;\n \"dragleave\": DragEvent;\n \"dragover\": DragEvent;\n \"dragstart\": DragEvent;\n \"drop\": DragEvent;\n \"durationchange\": Event;\n \"emptied\": Event;\n \"ended\": MediaStreamErrorEvent;\n \"focus\": FocusEvent;\n \"hashchange\": HashChangeEvent;\n \"input\": Event;\n \"invalid\": Event;\n \"keydown\": KeyboardEvent;\n \"keypress\": KeyboardEvent;\n \"keyup\": KeyboardEvent;\n \"load\": Event;\n \"loadeddata\": Event;\n \"loadedmetadata\": Event;\n \"loadstart\": Event;\n \"message\": MessageEvent;\n \"mousedown\": MouseEvent;\n \"mouseenter\": MouseEvent;\n \"mouseleave\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n \"mousewheel\": WheelEvent;\n \"MSGestureChange\": MSGestureEvent;\n \"MSGestureDoubleTap\": MSGestureEvent;\n \"MSGestureEnd\": MSGestureEvent;\n \"MSGestureHold\": MSGestureEvent;\n \"MSGestureStart\": MSGestureEvent;\n \"MSGestureTap\": MSGestureEvent;\n \"MSInertiaStart\": MSGestureEvent;\n \"MSPointerCancel\": MSPointerEvent;\n \"MSPointerDown\": MSPointerEvent;\n \"MSPointerEnter\": MSPointerEvent;\n \"MSPointerLeave\": MSPointerEvent;\n \"MSPointerMove\": MSPointerEvent;\n \"MSPointerOut\": MSPointerEvent;\n \"MSPointerOver\": MSPointerEvent;\n \"MSPointerUp\": MSPointerEvent;\n \"offline\": Event;\n \"online\": Event;\n \"orientationchange\": Event;\n \"pagehide\": PageTransitionEvent;\n \"pageshow\": PageTransitionEvent;\n \"pause\": Event;\n \"play\": Event;\n \"playing\": Event;\n \"popstate\": PopStateEvent;\n \"progress\": ProgressEvent;\n \"ratechange\": Event;\n \"readystatechange\": ProgressEvent;\n \"reset\": Event;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"seeked\": Event;\n \"seeking\": Event;\n \"select\": UIEvent;\n \"stalled\": Event;\n \"storage\": StorageEvent;\n \"submit\": Event;\n \"suspend\": Event;\n \"timeupdate\": Event;\n \"unload\": Event;\n \"volumechange\": Event;\n \"waiting\": Event;\n}\n\ninterface Window extends EventTarget, WindowTimers, WindowSessionStorage, WindowLocalStorage, WindowConsole, GlobalEventHandlers, IDBEnvironment, WindowBase64, GlobalFetch {\n readonly applicationCache: ApplicationCache;\n readonly caches: CacheStorage;\n readonly clientInformation: Navigator;\n readonly closed: boolean;\n readonly crypto: Crypto;\n defaultStatus: string;\n readonly devicePixelRatio: number;\n readonly doNotTrack: string;\n readonly document: Document;\n event: Event | undefined;\n readonly external: External;\n readonly frameElement: Element;\n readonly frames: Window;\n readonly history: History;\n readonly innerHeight: number;\n readonly innerWidth: number;\n readonly isSecureContext: boolean;\n readonly length: number;\n readonly location: Location;\n readonly locationbar: BarProp;\n readonly menubar: BarProp;\n readonly msContentScript: ExtensionScriptApis;\n readonly msCredentials: MSCredentials;\n name: string;\n readonly navigator: Navigator;\n offscreenBuffering: string | boolean;\n onabort: (this: Window, ev: UIEvent) => any;\n onafterprint: (this: Window, ev: Event) => any;\n onbeforeprint: (this: Window, ev: Event) => any;\n onbeforeunload: (this: Window, ev: BeforeUnloadEvent) => any;\n onblur: (this: Window, ev: FocusEvent) => any;\n oncanplay: (this: Window, ev: Event) => any;\n oncanplaythrough: (this: Window, ev: Event) => any;\n onchange: (this: Window, ev: Event) => any;\n onclick: (this: Window, ev: MouseEvent) => any;\n oncompassneedscalibration: (this: Window, ev: Event) => any;\n oncontextmenu: (this: Window, ev: PointerEvent) => any;\n ondblclick: (this: Window, ev: MouseEvent) => any;\n ondevicelight: (this: Window, ev: DeviceLightEvent) => any;\n ondevicemotion: (this: Window, ev: DeviceMotionEvent) => any;\n ondeviceorientation: (this: Window, ev: DeviceOrientationEvent) => any;\n ondrag: (this: Window, ev: DragEvent) => any;\n ondragend: (this: Window, ev: DragEvent) => any;\n ondragenter: (this: Window, ev: DragEvent) => any;\n ondragleave: (this: Window, ev: DragEvent) => any;\n ondragover: (this: Window, ev: DragEvent) => any;\n ondragstart: (this: Window, ev: DragEvent) => any;\n ondrop: (this: Window, ev: DragEvent) => any;\n ondurationchange: (this: Window, ev: Event) => any;\n onemptied: (this: Window, ev: Event) => any;\n onended: (this: Window, ev: MediaStreamErrorEvent) => any;\n onerror: ErrorEventHandler;\n onfocus: (this: Window, ev: FocusEvent) => any;\n onhashchange: (this: Window, ev: HashChangeEvent) => any;\n oninput: (this: Window, ev: Event) => any;\n oninvalid: (this: Window, ev: Event) => any;\n onkeydown: (this: Window, ev: KeyboardEvent) => any;\n onkeypress: (this: Window, ev: KeyboardEvent) => any;\n onkeyup: (this: Window, ev: KeyboardEvent) => any;\n onload: (this: Window, ev: Event) => any;\n onloadeddata: (this: Window, ev: Event) => any;\n onloadedmetadata: (this: Window, ev: Event) => any;\n onloadstart: (this: Window, ev: Event) => any;\n onmessage: (this: Window, ev: MessageEvent) => any;\n onmousedown: (this: Window, ev: MouseEvent) => any;\n onmouseenter: (this: Window, ev: MouseEvent) => any;\n onmouseleave: (this: Window, ev: MouseEvent) => any;\n onmousemove: (this: Window, ev: MouseEvent) => any;\n onmouseout: (this: Window, ev: MouseEvent) => any;\n onmouseover: (this: Window, ev: MouseEvent) => any;\n onmouseup: (this: Window, ev: MouseEvent) => any;\n onmousewheel: (this: Window, ev: WheelEvent) => any;\n onmsgesturechange: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturedoubletap: (this: Window, ev: MSGestureEvent) => any;\n onmsgestureend: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturehold: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturestart: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturetap: (this: Window, ev: MSGestureEvent) => any;\n onmsinertiastart: (this: Window, ev: MSGestureEvent) => any;\n onmspointercancel: (this: Window, ev: MSPointerEvent) => any;\n onmspointerdown: (this: Window, ev: MSPointerEvent) => any;\n onmspointerenter: (this: Window, ev: MSPointerEvent) => any;\n onmspointerleave: (this: Window, ev: MSPointerEvent) => any;\n onmspointermove: (this: Window, ev: MSPointerEvent) => any;\n onmspointerout: (this: Window, ev: MSPointerEvent) => any;\n onmspointerover: (this: Window, ev: MSPointerEvent) => any;\n onmspointerup: (this: Window, ev: MSPointerEvent) => any;\n onoffline: (this: Window, ev: Event) => any;\n ononline: (this: Window, ev: Event) => any;\n onorientationchange: (this: Window, ev: Event) => any;\n onpagehide: (this: Window, ev: PageTransitionEvent) => any;\n onpageshow: (this: Window, ev: PageTransitionEvent) => any;\n onpause: (this: Window, ev: Event) => any;\n onplay: (this: Window, ev: Event) => any;\n onplaying: (this: Window, ev: Event) => any;\n onpopstate: (this: Window, ev: PopStateEvent) => any;\n onprogress: (this: Window, ev: ProgressEvent) => any;\n onratechange: (this: Window, ev: Event) => any;\n onreadystatechange: (this: Window, ev: ProgressEvent) => any;\n onreset: (this: Window, ev: Event) => any;\n onresize: (this: Window, ev: UIEvent) => any;\n onscroll: (this: Window, ev: UIEvent) => any;\n onseeked: (this: Window, ev: Event) => any;\n onseeking: (this: Window, ev: Event) => any;\n onselect: (this: Window, ev: UIEvent) => any;\n onstalled: (this: Window, ev: Event) => any;\n onstorage: (this: Window, ev: StorageEvent) => any;\n onsubmit: (this: Window, ev: Event) => any;\n onsuspend: (this: Window, ev: Event) => any;\n ontimeupdate: (this: Window, ev: Event) => any;\n ontouchcancel: (ev: TouchEvent) => any;\n ontouchend: (ev: TouchEvent) => any;\n ontouchmove: (ev: TouchEvent) => any;\n ontouchstart: (ev: TouchEvent) => any;\n onunload: (this: Window, ev: Event) => any;\n onvolumechange: (this: Window, ev: Event) => any;\n onwaiting: (this: Window, ev: Event) => any;\n opener: any;\n orientation: string | number;\n readonly outerHeight: number;\n readonly outerWidth: number;\n readonly pageXOffset: number;\n readonly pageYOffset: number;\n readonly parent: Window;\n readonly performance: Performance;\n readonly personalbar: BarProp;\n readonly screen: Screen;\n readonly screenLeft: number;\n readonly screenTop: number;\n readonly screenX: number;\n readonly screenY: number;\n readonly scrollX: number;\n readonly scrollY: number;\n readonly scrollbars: BarProp;\n readonly self: Window;\n readonly speechSynthesis: SpeechSynthesis;\n status: string;\n readonly statusbar: BarProp;\n readonly styleMedia: StyleMedia;\n readonly toolbar: BarProp;\n readonly top: Window;\n readonly window: Window;\n URL: typeof URL;\n URLSearchParams: typeof URLSearchParams;\n Blob: typeof Blob;\n customElements: CustomElementRegistry;\n alert(message?: any): void;\n blur(): void;\n cancelAnimationFrame(handle: number): void;\n captureEvents(): void;\n close(): void;\n confirm(message?: string): boolean;\n departFocus(navigationReason: NavigationReason, origin: FocusNavigationOrigin): void;\n focus(): void;\n getComputedStyle(elt: Element, pseudoElt?: string): CSSStyleDeclaration;\n getMatchedCSSRules(elt: Element, pseudoElt?: string): CSSRuleList;\n getSelection(): Selection;\n matchMedia(mediaQuery: string): MediaQueryList;\n moveBy(x?: number, y?: number): void;\n moveTo(x?: number, y?: number): void;\n msWriteProfilerMark(profilerMarkName: string): void;\n open(url?: string, target?: string, features?: string, replace?: boolean): Window;\n postMessage(message: any, targetOrigin: string, transfer?: any[]): void;\n print(): void;\n prompt(message?: string, _default?: string): string | null;\n releaseEvents(): void;\n requestAnimationFrame(callback: FrameRequestCallback): number;\n resizeBy(x?: number, y?: number): void;\n resizeTo(x?: number, y?: number): void;\n scroll(x?: number, y?: number): void;\n scrollBy(x?: number, y?: number): void;\n scrollTo(x?: number, y?: number): void;\n stop(): void;\n webkitCancelAnimationFrame(handle: number): void;\n webkitConvertPointFromNodeToPage(node: Node, pt: WebKitPoint): WebKitPoint;\n webkitConvertPointFromPageToNode(node: Node, pt: WebKitPoint): WebKitPoint;\n webkitRequestAnimationFrame(callback: FrameRequestCallback): number;\n createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, options?: ImageBitmapOptions): Promise;\n createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, sx: number, sy: number, sw: number, sh: number, options?: ImageBitmapOptions): Promise;\n scroll(options?: ScrollToOptions): void;\n scrollTo(options?: ScrollToOptions): void;\n scrollBy(options?: ScrollToOptions): void;\n addEventListener(type: K, listener: (this: Window, ev: WindowEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Window: {\n prototype: Window;\n new(): Window;\n}\n\ninterface WorkerEventMap extends AbstractWorkerEventMap {\n \"message\": MessageEvent;\n}\n\ninterface Worker extends EventTarget, AbstractWorker {\n onmessage: (this: Worker, ev: MessageEvent) => any;\n postMessage(message: any, transfer?: any[]): void;\n terminate(): void;\n addEventListener(type: K, listener: (this: Worker, ev: WorkerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Worker: {\n prototype: Worker;\n new(stringUrl: string): Worker;\n}\n\ninterface XMLDocument extends Document {\n addEventListener(type: K, listener: (this: XMLDocument, ev: DocumentEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var XMLDocument: {\n prototype: XMLDocument;\n new(): XMLDocument;\n}\n\ninterface XMLHttpRequestEventMap extends XMLHttpRequestEventTargetEventMap {\n \"readystatechange\": Event;\n}\n\ninterface XMLHttpRequest extends EventTarget, XMLHttpRequestEventTarget {\n onreadystatechange: (this: XMLHttpRequest, ev: Event) => any;\n readonly readyState: number;\n readonly response: any;\n readonly responseText: string;\n responseType: XMLHttpRequestResponseType;\n readonly responseURL: string;\n readonly responseXML: Document | null;\n readonly status: number;\n readonly statusText: string;\n timeout: number;\n readonly upload: XMLHttpRequestUpload;\n withCredentials: boolean;\n msCaching?: string;\n abort(): void;\n getAllResponseHeaders(): string;\n getResponseHeader(header: string): string | null;\n msCachingEnabled(): boolean;\n open(method: string, url: string, async?: boolean, user?: string, password?: string): void;\n overrideMimeType(mime: string): void;\n send(data?: Document): void;\n send(data?: string): void;\n send(data?: any): void;\n setRequestHeader(header: string, value: string): void;\n readonly DONE: number;\n readonly HEADERS_RECEIVED: number;\n readonly LOADING: number;\n readonly OPENED: number;\n readonly UNSENT: number;\n addEventListener(type: K, listener: (this: XMLHttpRequest, ev: XMLHttpRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var XMLHttpRequest: {\n prototype: XMLHttpRequest;\n new(): XMLHttpRequest;\n readonly DONE: number;\n readonly HEADERS_RECEIVED: number;\n readonly LOADING: number;\n readonly OPENED: number;\n readonly UNSENT: number;\n}\n\ninterface XMLHttpRequestUpload extends EventTarget, XMLHttpRequestEventTarget {\n addEventListener(type: K, listener: (this: XMLHttpRequestUpload, ev: XMLHttpRequestEventTargetEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var XMLHttpRequestUpload: {\n prototype: XMLHttpRequestUpload;\n new(): XMLHttpRequestUpload;\n}\n\ninterface XMLSerializer {\n serializeToString(target: Node): string;\n}\n\ndeclare var XMLSerializer: {\n prototype: XMLSerializer;\n new(): XMLSerializer;\n}\n\ninterface XPathEvaluator {\n createExpression(expression: string, resolver: XPathNSResolver): XPathExpression;\n createNSResolver(nodeResolver?: Node): XPathNSResolver;\n evaluate(expression: string, contextNode: Node, resolver: XPathNSResolver | null, type: number, result: XPathResult | null): XPathResult;\n}\n\ndeclare var XPathEvaluator: {\n prototype: XPathEvaluator;\n new(): XPathEvaluator;\n}\n\ninterface XPathExpression {\n evaluate(contextNode: Node, type: number, result: XPathResult | null): XPathResult;\n}\n\ndeclare var XPathExpression: {\n prototype: XPathExpression;\n new(): XPathExpression;\n}\n\ninterface XPathNSResolver {\n lookupNamespaceURI(prefix: string): string;\n}\n\ndeclare var XPathNSResolver: {\n prototype: XPathNSResolver;\n new(): XPathNSResolver;\n}\n\ninterface XPathResult {\n readonly booleanValue: boolean;\n readonly invalidIteratorState: boolean;\n readonly numberValue: number;\n readonly resultType: number;\n readonly singleNodeValue: Node;\n readonly snapshotLength: number;\n readonly stringValue: string;\n iterateNext(): Node;\n snapshotItem(index: number): Node;\n readonly ANY_TYPE: number;\n readonly ANY_UNORDERED_NODE_TYPE: number;\n readonly BOOLEAN_TYPE: number;\n readonly FIRST_ORDERED_NODE_TYPE: number;\n readonly NUMBER_TYPE: number;\n readonly ORDERED_NODE_ITERATOR_TYPE: number;\n readonly ORDERED_NODE_SNAPSHOT_TYPE: number;\n readonly STRING_TYPE: number;\n readonly UNORDERED_NODE_ITERATOR_TYPE: number;\n readonly UNORDERED_NODE_SNAPSHOT_TYPE: number;\n}\n\ndeclare var XPathResult: {\n prototype: XPathResult;\n new(): XPathResult;\n readonly ANY_TYPE: number;\n readonly ANY_UNORDERED_NODE_TYPE: number;\n readonly BOOLEAN_TYPE: number;\n readonly FIRST_ORDERED_NODE_TYPE: number;\n readonly NUMBER_TYPE: number;\n readonly ORDERED_NODE_ITERATOR_TYPE: number;\n readonly ORDERED_NODE_SNAPSHOT_TYPE: number;\n readonly STRING_TYPE: number;\n readonly UNORDERED_NODE_ITERATOR_TYPE: number;\n readonly UNORDERED_NODE_SNAPSHOT_TYPE: number;\n}\n\ninterface XSLTProcessor {\n clearParameters(): void;\n getParameter(namespaceURI: string, localName: string): any;\n importStylesheet(style: Node): void;\n removeParameter(namespaceURI: string, localName: string): void;\n reset(): void;\n setParameter(namespaceURI: string, localName: string, value: any): void;\n transformToDocument(source: Node): Document;\n transformToFragment(source: Node, document: Document): DocumentFragment;\n}\n\ndeclare var XSLTProcessor: {\n prototype: XSLTProcessor;\n new(): XSLTProcessor;\n}\n\ninterface webkitRTCPeerConnection extends RTCPeerConnection {\n addEventListener(type: K, listener: (this: webkitRTCPeerConnection, ev: RTCPeerConnectionEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var webkitRTCPeerConnection: {\n prototype: webkitRTCPeerConnection;\n new(configuration: RTCConfiguration): webkitRTCPeerConnection;\n}\n\ninterface AbstractWorkerEventMap {\n \"error\": ErrorEvent;\n}\n\ninterface AbstractWorker {\n onerror: (this: AbstractWorker, ev: ErrorEvent) => any;\n addEventListener(type: K, listener: (this: AbstractWorker, ev: AbstractWorkerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface Body {\n readonly bodyUsed: boolean;\n arrayBuffer(): Promise;\n blob(): Promise;\n json(): Promise;\n text(): Promise;\n formData(): Promise;\n}\n\ninterface CanvasPathMethods {\n arc(x: number, y: number, radius: number, startAngle: number, endAngle: number, anticlockwise?: boolean): void;\n arcTo(x1: number, y1: number, x2: number, y2: number, radius: number): void;\n bezierCurveTo(cp1x: number, cp1y: number, cp2x: number, cp2y: number, x: number, y: number): void;\n closePath(): void;\n ellipse(x: number, y: number, radiusX: number, radiusY: number, rotation: number, startAngle: number, endAngle: number, anticlockwise?: boolean): void;\n lineTo(x: number, y: number): void;\n moveTo(x: number, y: number): void;\n quadraticCurveTo(cpx: number, cpy: number, x: number, y: number): void;\n rect(x: number, y: number, w: number, h: number): void;\n}\n\ninterface ChildNode {\n remove(): void;\n}\n\ninterface DOML2DeprecatedColorProperty {\n color: string;\n}\n\ninterface DOML2DeprecatedSizeProperty {\n size: number;\n}\n\ninterface DocumentEvent {\n createEvent(eventInterface:\"AnimationEvent\"): AnimationEvent;\n createEvent(eventInterface:\"AudioProcessingEvent\"): AudioProcessingEvent;\n createEvent(eventInterface:\"BeforeUnloadEvent\"): BeforeUnloadEvent;\n createEvent(eventInterface:\"ClipboardEvent\"): ClipboardEvent;\n createEvent(eventInterface:\"CloseEvent\"): CloseEvent;\n createEvent(eventInterface:\"CompositionEvent\"): CompositionEvent;\n createEvent(eventInterface:\"CustomEvent\"): CustomEvent;\n createEvent(eventInterface:\"DeviceLightEvent\"): DeviceLightEvent;\n createEvent(eventInterface:\"DeviceMotionEvent\"): DeviceMotionEvent;\n createEvent(eventInterface:\"DeviceOrientationEvent\"): DeviceOrientationEvent;\n createEvent(eventInterface:\"DragEvent\"): DragEvent;\n createEvent(eventInterface:\"ErrorEvent\"): ErrorEvent;\n createEvent(eventInterface:\"Event\"): Event;\n createEvent(eventInterface:\"Events\"): Event;\n createEvent(eventInterface:\"FocusEvent\"): FocusEvent;\n createEvent(eventInterface:\"FocusNavigationEvent\"): FocusNavigationEvent;\n createEvent(eventInterface:\"GamepadEvent\"): GamepadEvent;\n createEvent(eventInterface:\"HashChangeEvent\"): HashChangeEvent;\n createEvent(eventInterface:\"IDBVersionChangeEvent\"): IDBVersionChangeEvent;\n createEvent(eventInterface:\"KeyboardEvent\"): KeyboardEvent;\n createEvent(eventInterface:\"ListeningStateChangedEvent\"): ListeningStateChangedEvent;\n createEvent(eventInterface:\"LongRunningScriptDetectedEvent\"): LongRunningScriptDetectedEvent;\n createEvent(eventInterface:\"MSGestureEvent\"): MSGestureEvent;\n createEvent(eventInterface:\"MSManipulationEvent\"): MSManipulationEvent;\n createEvent(eventInterface:\"MSMediaKeyMessageEvent\"): MSMediaKeyMessageEvent;\n createEvent(eventInterface:\"MSMediaKeyNeededEvent\"): MSMediaKeyNeededEvent;\n createEvent(eventInterface:\"MSPointerEvent\"): MSPointerEvent;\n createEvent(eventInterface:\"MSSiteModeEvent\"): MSSiteModeEvent;\n createEvent(eventInterface:\"MediaEncryptedEvent\"): MediaEncryptedEvent;\n createEvent(eventInterface:\"MediaKeyMessageEvent\"): MediaKeyMessageEvent;\n createEvent(eventInterface:\"MediaStreamErrorEvent\"): MediaStreamErrorEvent;\n createEvent(eventInterface:\"MediaStreamEvent\"): MediaStreamEvent;\n createEvent(eventInterface:\"MediaStreamTrackEvent\"): MediaStreamTrackEvent;\n createEvent(eventInterface:\"MessageEvent\"): MessageEvent;\n createEvent(eventInterface:\"MouseEvent\"): MouseEvent;\n createEvent(eventInterface:\"MouseEvents\"): MouseEvent;\n createEvent(eventInterface:\"MutationEvent\"): MutationEvent;\n createEvent(eventInterface:\"MutationEvents\"): MutationEvent;\n createEvent(eventInterface:\"NavigationCompletedEvent\"): NavigationCompletedEvent;\n createEvent(eventInterface:\"NavigationEvent\"): NavigationEvent;\n createEvent(eventInterface:\"NavigationEventWithReferrer\"): NavigationEventWithReferrer;\n createEvent(eventInterface:\"OfflineAudioCompletionEvent\"): OfflineAudioCompletionEvent;\n createEvent(eventInterface:\"OverflowEvent\"): OverflowEvent;\n createEvent(eventInterface:\"PageTransitionEvent\"): PageTransitionEvent;\n createEvent(eventInterface:\"PaymentRequestUpdateEvent\"): PaymentRequestUpdateEvent;\n createEvent(eventInterface:\"PermissionRequestedEvent\"): PermissionRequestedEvent;\n createEvent(eventInterface:\"PointerEvent\"): PointerEvent;\n createEvent(eventInterface:\"PopStateEvent\"): PopStateEvent;\n createEvent(eventInterface:\"ProgressEvent\"): ProgressEvent;\n createEvent(eventInterface:\"RTCDTMFToneChangeEvent\"): RTCDTMFToneChangeEvent;\n createEvent(eventInterface:\"RTCDtlsTransportStateChangedEvent\"): RTCDtlsTransportStateChangedEvent;\n createEvent(eventInterface:\"RTCIceCandidatePairChangedEvent\"): RTCIceCandidatePairChangedEvent;\n createEvent(eventInterface:\"RTCIceGathererEvent\"): RTCIceGathererEvent;\n createEvent(eventInterface:\"RTCIceTransportStateChangedEvent\"): RTCIceTransportStateChangedEvent;\n createEvent(eventInterface:\"RTCPeerConnectionIceEvent\"): RTCPeerConnectionIceEvent;\n createEvent(eventInterface:\"RTCSsrcConflictEvent\"): RTCSsrcConflictEvent;\n createEvent(eventInterface:\"SVGZoomEvent\"): SVGZoomEvent;\n createEvent(eventInterface:\"SVGZoomEvents\"): SVGZoomEvent;\n createEvent(eventInterface:\"ScriptNotifyEvent\"): ScriptNotifyEvent;\n createEvent(eventInterface:\"ServiceWorkerMessageEvent\"): ServiceWorkerMessageEvent;\n createEvent(eventInterface:\"SpeechSynthesisEvent\"): SpeechSynthesisEvent;\n createEvent(eventInterface:\"StorageEvent\"): StorageEvent;\n createEvent(eventInterface:\"TextEvent\"): TextEvent;\n createEvent(eventInterface:\"TouchEvent\"): TouchEvent;\n createEvent(eventInterface:\"TrackEvent\"): TrackEvent;\n createEvent(eventInterface:\"TransitionEvent\"): TransitionEvent;\n createEvent(eventInterface:\"UIEvent\"): UIEvent;\n createEvent(eventInterface:\"UIEvents\"): UIEvent;\n createEvent(eventInterface:\"UnviewableContentIdentifiedEvent\"): UnviewableContentIdentifiedEvent;\n createEvent(eventInterface:\"WebGLContextEvent\"): WebGLContextEvent;\n createEvent(eventInterface:\"WheelEvent\"): WheelEvent;\n createEvent(eventInterface: string): Event;\n}\n\ninterface ElementTraversal {\n readonly childElementCount: number;\n readonly firstElementChild: Element | null;\n readonly lastElementChild: Element | null;\n readonly nextElementSibling: Element | null;\n readonly previousElementSibling: Element | null;\n}\n\ninterface GetSVGDocument {\n getSVGDocument(): Document;\n}\n\ninterface GlobalEventHandlersEventMap {\n \"pointercancel\": PointerEvent;\n \"pointerdown\": PointerEvent;\n \"pointerenter\": PointerEvent;\n \"pointerleave\": PointerEvent;\n \"pointermove\": PointerEvent;\n \"pointerout\": PointerEvent;\n \"pointerover\": PointerEvent;\n \"pointerup\": PointerEvent;\n \"wheel\": WheelEvent;\n}\n\ninterface GlobalEventHandlers {\n onpointercancel: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerdown: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerenter: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerleave: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointermove: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerout: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerover: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerup: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onwheel: (this: GlobalEventHandlers, ev: WheelEvent) => any;\n addEventListener(type: K, listener: (this: GlobalEventHandlers, ev: GlobalEventHandlersEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface GlobalFetch {\n fetch(input: RequestInfo, init?: RequestInit): Promise;\n}\n\ninterface HTMLTableAlignment {\n /**\n * Sets or retrieves a value that you can use to implement your own ch functionality for the object.\n */\n ch: string;\n /**\n * Sets or retrieves a value that you can use to implement your own chOff functionality for the object.\n */\n chOff: string;\n /**\n * Sets or retrieves how text and other content are vertically aligned within the object that contains them.\n */\n vAlign: string;\n}\n\ninterface IDBEnvironment {\n readonly indexedDB: IDBFactory;\n}\n\ninterface LinkStyle {\n readonly sheet: StyleSheet;\n}\n\ninterface MSBaseReaderEventMap {\n \"abort\": Event;\n \"error\": ErrorEvent;\n \"load\": Event;\n \"loadend\": ProgressEvent;\n \"loadstart\": Event;\n \"progress\": ProgressEvent;\n}\n\ninterface MSBaseReader {\n onabort: (this: MSBaseReader, ev: Event) => any;\n onerror: (this: MSBaseReader, ev: ErrorEvent) => any;\n onload: (this: MSBaseReader, ev: Event) => any;\n onloadend: (this: MSBaseReader, ev: ProgressEvent) => any;\n onloadstart: (this: MSBaseReader, ev: Event) => any;\n onprogress: (this: MSBaseReader, ev: ProgressEvent) => any;\n readonly readyState: number;\n readonly result: any;\n abort(): void;\n readonly DONE: number;\n readonly EMPTY: number;\n readonly LOADING: number;\n addEventListener(type: K, listener: (this: MSBaseReader, ev: MSBaseReaderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface MSFileSaver {\n msSaveBlob(blob: any, defaultName?: string): boolean;\n msSaveOrOpenBlob(blob: any, defaultName?: string): boolean;\n}\n\ninterface MSNavigatorDoNotTrack {\n confirmSiteSpecificTrackingException(args: ConfirmSiteSpecificExceptionsInformation): boolean;\n confirmWebWideTrackingException(args: ExceptionInformation): boolean;\n removeSiteSpecificTrackingException(args: ExceptionInformation): void;\n removeWebWideTrackingException(args: ExceptionInformation): void;\n storeSiteSpecificTrackingException(args: StoreSiteSpecificExceptionsInformation): void;\n storeWebWideTrackingException(args: StoreExceptionsInformation): void;\n}\n\ninterface NavigatorBeacon {\n sendBeacon(url: USVString, data?: BodyInit): boolean;\n}\n\ninterface NavigatorConcurrentHardware {\n readonly hardwareConcurrency: number;\n}\n\ninterface NavigatorContentUtils {\n}\n\ninterface NavigatorGeolocation {\n readonly geolocation: Geolocation;\n}\n\ninterface NavigatorID {\n readonly appCodeName: string;\n readonly appName: string;\n readonly appVersion: string;\n readonly platform: string;\n readonly product: string;\n readonly productSub: string;\n readonly userAgent: string;\n readonly vendor: string;\n readonly vendorSub: string;\n}\n\ninterface NavigatorOnLine {\n readonly onLine: boolean;\n}\n\ninterface NavigatorStorageUtils {\n}\n\ninterface NavigatorUserMedia {\n readonly mediaDevices: MediaDevices;\n getUserMedia(constraints: MediaStreamConstraints, successCallback: NavigatorUserMediaSuccessCallback, errorCallback: NavigatorUserMediaErrorCallback): void;\n}\n\ninterface NodeSelector {\n querySelector(selectors: K): ElementTagNameMap[K] | null;\n querySelector(selectors: string): Element | null;\n querySelectorAll(selectors: K): ElementListTagNameMap[K];\n querySelectorAll(selectors: string): NodeListOf;\n}\n\ninterface RandomSource {\n getRandomValues(array: ArrayBufferView): ArrayBufferView;\n}\n\ninterface SVGAnimatedPoints {\n readonly animatedPoints: SVGPointList;\n readonly points: SVGPointList;\n}\n\ninterface SVGFilterPrimitiveStandardAttributes {\n readonly height: SVGAnimatedLength;\n readonly result: SVGAnimatedString;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n}\n\ninterface SVGFitToViewBox {\n readonly preserveAspectRatio: SVGAnimatedPreserveAspectRatio;\n readonly viewBox: SVGAnimatedRect;\n}\n\ninterface SVGTests {\n readonly requiredExtensions: SVGStringList;\n readonly requiredFeatures: SVGStringList;\n readonly systemLanguage: SVGStringList;\n hasExtension(extension: string): boolean;\n}\n\ninterface SVGURIReference {\n readonly href: SVGAnimatedString;\n}\n\ninterface WindowBase64 {\n atob(encodedString: string): string;\n btoa(rawString: string): string;\n}\n\ninterface WindowConsole {\n readonly console: Console;\n}\n\ninterface WindowLocalStorage {\n readonly localStorage: Storage;\n}\n\ninterface WindowSessionStorage {\n readonly sessionStorage: Storage;\n}\n\ninterface WindowTimers extends Object, WindowTimersExtension {\n clearInterval(handle: number): void;\n clearTimeout(handle: number): void;\n setInterval(handler: (...args: any[]) => void, timeout: number): number;\n setInterval(handler: any, timeout?: any, ...args: any[]): number;\n setTimeout(handler: (...args: any[]) => void, timeout: number): number;\n setTimeout(handler: any, timeout?: any, ...args: any[]): number;\n}\n\ninterface WindowTimersExtension {\n clearImmediate(handle: number): void;\n setImmediate(handler: (...args: any[]) => void): number;\n setImmediate(handler: any, ...args: any[]): number;\n}\n\ninterface XMLHttpRequestEventTargetEventMap {\n \"abort\": Event;\n \"error\": ErrorEvent;\n \"load\": Event;\n \"loadend\": ProgressEvent;\n \"loadstart\": Event;\n \"progress\": ProgressEvent;\n \"timeout\": ProgressEvent;\n}\n\ninterface XMLHttpRequestEventTarget {\n onabort: (this: XMLHttpRequestEventTarget, ev: Event) => any;\n onerror: (this: XMLHttpRequestEventTarget, ev: ErrorEvent) => any;\n onload: (this: XMLHttpRequestEventTarget, ev: Event) => any;\n onloadend: (this: XMLHttpRequestEventTarget, ev: ProgressEvent) => any;\n onloadstart: (this: XMLHttpRequestEventTarget, ev: Event) => any;\n onprogress: (this: XMLHttpRequestEventTarget, ev: ProgressEvent) => any;\n ontimeout: (this: XMLHttpRequestEventTarget, ev: ProgressEvent) => any;\n addEventListener(type: K, listener: (this: XMLHttpRequestEventTarget, ev: XMLHttpRequestEventTargetEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface ErrorEventInit {\n message?: string;\n filename?: string;\n lineno?: number;\n conlno?: number;\n error?: any;\n}\n\ninterface StorageEventInit extends EventInit {\n key?: string;\n oldValue?: string;\n newValue?: string;\n url: string;\n storageArea?: Storage;\n}\n\ninterface Canvas2DContextAttributes {\n alpha?: boolean;\n willReadFrequently?: boolean;\n storage?: boolean;\n [attribute: string]: boolean | string | undefined;\n}\n\ninterface ImageBitmapOptions {\n imageOrientation?: \"none\" | \"flipY\";\n premultiplyAlpha?: \"none\" | \"premultiply\" | \"default\";\n colorSpaceConversion?: \"none\" | \"default\";\n resizeWidth?: number;\n resizeHeight?: number;\n resizeQuality?: \"pixelated\" | \"low\" | \"medium\" | \"high\";\n}\n\ninterface ImageBitmap {\n readonly width: number;\n readonly height: number;\n close(): void;\n}\n\ninterface URLSearchParams {\n /**\n * Appends a specified key/value pair as a new search parameter.\n */\n append(name: string, value: string): void;\n /**\n * Deletes the given search parameter, and its associated value, from the list of all search parameters.\n */\n delete(name: string): void;\n /**\n * Returns the first value associated to the given search parameter.\n */\n get(name: string): string | null;\n /**\n * Returns all the values association with a given search parameter.\n */\n getAll(name: string): string[];\n /**\n * Returns a Boolean indicating if such a search parameter exists.\n */\n has(name: string): boolean;\n /**\n * Sets the value associated to a given search parameter to the given value. If there were several values, delete the others.\n */\n set(name: string, value: string): void;\n}\n\ndeclare var URLSearchParams: {\n prototype: URLSearchParams;\n /**\n * Constructor returning a URLSearchParams object.\n */\n new (init?: string | URLSearchParams): URLSearchParams;\n}\n\ninterface NodeListOf extends NodeList {\n length: number;\n item(index: number): TNode;\n [index: number]: TNode;\n}\n\ninterface HTMLCollectionOf extends HTMLCollection {\n item(index: number): T;\n namedItem(name: string): T;\n [index: number]: T;\n}\n\ninterface BlobPropertyBag {\n type?: string;\n endings?: string;\n}\n\ninterface FilePropertyBag {\n type?: string;\n lastModified?: number;\n}\n\ninterface EventListenerObject {\n handleEvent(evt: Event): void;\n}\n\ninterface ProgressEventInit extends EventInit {\n lengthComputable?: boolean;\n loaded?: number;\n total?: number;\n}\n\ninterface ScrollOptions {\n behavior?: ScrollBehavior;\n}\n\ninterface ScrollToOptions extends ScrollOptions {\n left?: number;\n top?: number;\n}\n\ninterface ScrollIntoViewOptions extends ScrollOptions {\n block?: ScrollLogicalPosition;\n inline?: ScrollLogicalPosition;\n}\n\ninterface ClipboardEventInit extends EventInit {\n data?: string;\n dataType?: string;\n}\n\ninterface IDBArrayKey extends Array {\n}\n\ninterface RsaKeyGenParams extends Algorithm {\n modulusLength: number;\n publicExponent: Uint8Array;\n}\n\ninterface RsaHashedKeyGenParams extends RsaKeyGenParams {\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaKeyAlgorithm extends KeyAlgorithm {\n modulusLength: number;\n publicExponent: Uint8Array;\n}\n\ninterface RsaHashedKeyAlgorithm extends RsaKeyAlgorithm {\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaHashedImportParams {\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaPssParams {\n saltLength: number;\n}\n\ninterface RsaOaepParams extends Algorithm {\n label?: BufferSource;\n}\n\ninterface EcdsaParams extends Algorithm {\n hash: AlgorithmIdentifier;\n}\n\ninterface EcKeyGenParams extends Algorithm {\n namedCurve: string;\n}\n\ninterface EcKeyAlgorithm extends KeyAlgorithm {\n typedCurve: string;\n}\n\ninterface EcKeyImportParams {\n namedCurve: string;\n}\n\ninterface EcdhKeyDeriveParams extends Algorithm {\n public: CryptoKey;\n}\n\ninterface AesCtrParams extends Algorithm {\n counter: BufferSource;\n length: number;\n}\n\ninterface AesKeyAlgorithm extends KeyAlgorithm {\n length: number;\n}\n\ninterface AesKeyGenParams extends Algorithm {\n length: number;\n}\n\ninterface AesDerivedKeyParams extends Algorithm {\n length: number;\n}\n\ninterface AesCbcParams extends Algorithm {\n iv: BufferSource;\n}\n\ninterface AesCmacParams extends Algorithm {\n length: number;\n}\n\ninterface AesGcmParams extends Algorithm {\n iv: BufferSource;\n additionalData?: BufferSource;\n tagLength?: number;\n}\n\ninterface AesCfbParams extends Algorithm {\n iv: BufferSource;\n}\n\ninterface HmacImportParams extends Algorithm {\n hash?: AlgorithmIdentifier;\n length?: number;\n}\n\ninterface HmacKeyAlgorithm extends KeyAlgorithm {\n hash: AlgorithmIdentifier;\n length: number;\n}\n\ninterface HmacKeyGenParams extends Algorithm {\n hash: AlgorithmIdentifier;\n length?: number;\n}\n\ninterface DhKeyGenParams extends Algorithm {\n prime: Uint8Array;\n generator: Uint8Array;\n}\n\ninterface DhKeyAlgorithm extends KeyAlgorithm {\n prime: Uint8Array;\n generator: Uint8Array;\n}\n\ninterface DhKeyDeriveParams extends Algorithm {\n public: CryptoKey;\n}\n\ninterface DhImportKeyParams extends Algorithm {\n prime: Uint8Array;\n generator: Uint8Array;\n}\n\ninterface ConcatParams extends Algorithm {\n hash?: AlgorithmIdentifier;\n algorithmId: Uint8Array;\n partyUInfo: Uint8Array;\n partyVInfo: Uint8Array;\n publicInfo?: Uint8Array;\n privateInfo?: Uint8Array;\n}\n\ninterface HkdfCtrParams extends Algorithm {\n hash: AlgorithmIdentifier;\n label: BufferSource;\n context: BufferSource;\n}\n\ninterface Pbkdf2Params extends Algorithm {\n salt: BufferSource;\n iterations: number;\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaOtherPrimesInfo {\n r: string;\n d: string;\n t: string;\n}\n\ninterface JsonWebKey {\n kty: string;\n use?: string;\n key_ops?: string[];\n alg?: string;\n kid?: string;\n x5u?: string;\n x5c?: string;\n x5t?: string;\n ext?: boolean;\n crv?: string;\n x?: string;\n y?: string;\n d?: string;\n n?: string;\n e?: string;\n p?: string;\n q?: string;\n dp?: string;\n dq?: string;\n qi?: string;\n oth?: RsaOtherPrimesInfo[];\n k?: string;\n}\n\ninterface ParentNode {\n readonly children: HTMLCollection;\n readonly firstElementChild: Element | null;\n readonly lastElementChild: Element | null;\n readonly childElementCount: number;\n}\n\ninterface DocumentOrShadowRoot {\n readonly activeElement: Element | null;\n readonly stylesheets: StyleSheetList;\n getSelection(): Selection | null;\n elementFromPoint(x: number, y: number): Element | null;\n elementsFromPoint(x: number, y: number): Element[];\n}\n\ninterface ShadowRoot extends DocumentOrShadowRoot, DocumentFragment {\n readonly host: Element;\n innerHTML: string;\n}\n\ninterface ShadowRootInit {\n mode: 'open'|'closed';\n delegatesFocus?: boolean;\n}\n\ninterface HTMLSlotElement extends HTMLElement {\n name: string;\n assignedNodes(options?: AssignedNodesOptions): Node[];\n}\n\ninterface AssignedNodesOptions {\n flatten?: boolean;\n}\n\ninterface ElementDefinitionOptions {\n extends: string;\n}\n\ninterface CustomElementRegistry {\n define(name: string, constructor: Function, options?: ElementDefinitionOptions): void;\n get(name: string): any;\n whenDefined(name: string): PromiseLike;\n}\n\ninterface PromiseRejectionEvent extends Event {\n readonly promise: PromiseLike;\n readonly reason: any;\n}\n\ninterface PromiseRejectionEventInit extends EventInit {\n promise: PromiseLike;\n reason?: any;\n}\n\ninterface EventListenerOptions {\n capture?: boolean;\n}\n\ninterface AddEventListenerOptions extends EventListenerOptions {\n passive?: boolean;\n once?: boolean;\n}\n\ninterface TouchEventInit extends EventModifierInit {\n touches?: Touch[];\n targetTouches?: Touch[];\n changedTouches?: Touch[];\n}\n\ndeclare type EventListenerOrEventListenerObject = EventListener | EventListenerObject;\n\ninterface ErrorEventHandler {\n (message: string, filename?: string, lineno?: number, colno?: number, error?:Error): void;\n}\ninterface PositionCallback {\n (position: Position): void;\n}\ninterface PositionErrorCallback {\n (error: PositionError): void;\n}\ninterface MediaQueryListListener {\n (mql: MediaQueryList): void;\n}\ninterface MSLaunchUriCallback {\n (): void;\n}\ninterface FrameRequestCallback {\n (time: number): void;\n}\ninterface MSUnsafeFunctionCallback {\n (): any;\n}\ninterface MSExecAtPriorityFunctionCallback {\n (...args: any[]): any;\n}\ninterface MutationCallback {\n (mutations: MutationRecord[], observer: MutationObserver): void;\n}\ninterface DecodeSuccessCallback {\n (decodedData: AudioBuffer): void;\n}\ninterface DecodeErrorCallback {\n (error: DOMException): void;\n}\ninterface VoidFunction {\n (): void;\n}\ninterface RTCSessionDescriptionCallback {\n (sdp: RTCSessionDescription): void;\n}\ninterface RTCPeerConnectionErrorCallback {\n (error: DOMError): void;\n}\ninterface RTCStatsCallback {\n (report: RTCStatsReport): void;\n}\ninterface FunctionStringCallback {\n (data: string): void;\n}\ninterface NavigatorUserMediaSuccessCallback {\n (stream: MediaStream): void;\n}\ninterface NavigatorUserMediaErrorCallback {\n (error: MediaStreamError): void;\n}\ninterface ForEachCallback {\n (keyId: any, status: MediaKeyStatus): void;\n}\ninterface NotificationPermissionCallback {\n (permission: NotificationPermission): void;\n}\ninterface IntersectionObserverCallback {\n (entries: IntersectionObserverEntry[], observer: IntersectionObserver): void;\n}\ninterface HTMLElementTagNameMap {\n \"a\": HTMLAnchorElement;\n \"applet\": HTMLAppletElement;\n \"area\": HTMLAreaElement;\n \"audio\": HTMLAudioElement;\n \"base\": HTMLBaseElement;\n \"basefont\": HTMLBaseFontElement;\n \"blockquote\": HTMLQuoteElement;\n \"body\": HTMLBodyElement;\n \"br\": HTMLBRElement;\n \"button\": HTMLButtonElement;\n \"canvas\": HTMLCanvasElement;\n \"caption\": HTMLTableCaptionElement;\n \"col\": HTMLTableColElement;\n \"colgroup\": HTMLTableColElement;\n \"data\": HTMLDataElement;\n \"datalist\": HTMLDataListElement;\n \"del\": HTMLModElement;\n \"dir\": HTMLDirectoryElement;\n \"div\": HTMLDivElement;\n \"dl\": HTMLDListElement;\n \"embed\": HTMLEmbedElement;\n \"fieldset\": HTMLFieldSetElement;\n \"font\": HTMLFontElement;\n \"form\": HTMLFormElement;\n \"frame\": HTMLFrameElement;\n \"frameset\": HTMLFrameSetElement;\n \"h1\": HTMLHeadingElement;\n \"h2\": HTMLHeadingElement;\n \"h3\": HTMLHeadingElement;\n \"h4\": HTMLHeadingElement;\n \"h5\": HTMLHeadingElement;\n \"h6\": HTMLHeadingElement;\n \"head\": HTMLHeadElement;\n \"hr\": HTMLHRElement;\n \"html\": HTMLHtmlElement;\n \"iframe\": HTMLIFrameElement;\n \"img\": HTMLImageElement;\n \"input\": HTMLInputElement;\n \"ins\": HTMLModElement;\n \"isindex\": HTMLUnknownElement;\n \"label\": HTMLLabelElement;\n \"legend\": HTMLLegendElement;\n \"li\": HTMLLIElement;\n \"link\": HTMLLinkElement;\n \"listing\": HTMLPreElement;\n \"map\": HTMLMapElement;\n \"marquee\": HTMLMarqueeElement;\n \"menu\": HTMLMenuElement;\n \"meta\": HTMLMetaElement;\n \"meter\": HTMLMeterElement;\n \"nextid\": HTMLUnknownElement;\n \"object\": HTMLObjectElement;\n \"ol\": HTMLOListElement;\n \"optgroup\": HTMLOptGroupElement;\n \"option\": HTMLOptionElement;\n \"output\": HTMLOutputElement;\n \"p\": HTMLParagraphElement;\n \"param\": HTMLParamElement;\n \"picture\": HTMLPictureElement;\n \"pre\": HTMLPreElement;\n \"progress\": HTMLProgressElement;\n \"q\": HTMLQuoteElement;\n \"script\": HTMLScriptElement;\n \"select\": HTMLSelectElement;\n \"source\": HTMLSourceElement;\n \"span\": HTMLSpanElement;\n \"style\": HTMLStyleElement;\n \"table\": HTMLTableElement;\n \"tbody\": HTMLTableSectionElement;\n \"td\": HTMLTableDataCellElement;\n \"template\": HTMLTemplateElement;\n \"textarea\": HTMLTextAreaElement;\n \"tfoot\": HTMLTableSectionElement;\n \"th\": HTMLTableHeaderCellElement;\n \"thead\": HTMLTableSectionElement;\n \"time\": HTMLTimeElement;\n \"title\": HTMLTitleElement;\n \"tr\": HTMLTableRowElement;\n \"track\": HTMLTrackElement;\n \"ul\": HTMLUListElement;\n \"video\": HTMLVideoElement;\n \"x-ms-webview\": MSHTMLWebViewElement;\n \"xmp\": HTMLPreElement;\n}\n\ninterface ElementTagNameMap {\n \"a\": HTMLAnchorElement;\n \"abbr\": HTMLElement;\n \"acronym\": HTMLElement;\n \"address\": HTMLElement;\n \"applet\": HTMLAppletElement;\n \"area\": HTMLAreaElement;\n \"article\": HTMLElement;\n \"aside\": HTMLElement;\n \"audio\": HTMLAudioElement;\n \"b\": HTMLElement;\n \"base\": HTMLBaseElement;\n \"basefont\": HTMLBaseFontElement;\n \"bdo\": HTMLElement;\n \"big\": HTMLElement;\n \"blockquote\": HTMLQuoteElement;\n \"body\": HTMLBodyElement;\n \"br\": HTMLBRElement;\n \"button\": HTMLButtonElement;\n \"canvas\": HTMLCanvasElement;\n \"caption\": HTMLTableCaptionElement;\n \"center\": HTMLElement;\n \"circle\": SVGCircleElement;\n \"cite\": HTMLElement;\n \"clippath\": SVGClipPathElement;\n \"code\": HTMLElement;\n \"col\": HTMLTableColElement;\n \"colgroup\": HTMLTableColElement;\n \"data\": HTMLDataElement;\n \"datalist\": HTMLDataListElement;\n \"dd\": HTMLElement;\n \"defs\": SVGDefsElement;\n \"del\": HTMLModElement;\n \"desc\": SVGDescElement;\n \"dfn\": HTMLElement;\n \"dir\": HTMLDirectoryElement;\n \"div\": HTMLDivElement;\n \"dl\": HTMLDListElement;\n \"dt\": HTMLElement;\n \"ellipse\": SVGEllipseElement;\n \"em\": HTMLElement;\n \"embed\": HTMLEmbedElement;\n \"feblend\": SVGFEBlendElement;\n \"fecolormatrix\": SVGFEColorMatrixElement;\n \"fecomponenttransfer\": SVGFEComponentTransferElement;\n \"fecomposite\": SVGFECompositeElement;\n \"feconvolvematrix\": SVGFEConvolveMatrixElement;\n \"fediffuselighting\": SVGFEDiffuseLightingElement;\n \"fedisplacementmap\": SVGFEDisplacementMapElement;\n \"fedistantlight\": SVGFEDistantLightElement;\n \"feflood\": SVGFEFloodElement;\n \"fefunca\": SVGFEFuncAElement;\n \"fefuncb\": SVGFEFuncBElement;\n \"fefuncg\": SVGFEFuncGElement;\n \"fefuncr\": SVGFEFuncRElement;\n \"fegaussianblur\": SVGFEGaussianBlurElement;\n \"feimage\": SVGFEImageElement;\n \"femerge\": SVGFEMergeElement;\n \"femergenode\": SVGFEMergeNodeElement;\n \"femorphology\": SVGFEMorphologyElement;\n \"feoffset\": SVGFEOffsetElement;\n \"fepointlight\": SVGFEPointLightElement;\n \"fespecularlighting\": SVGFESpecularLightingElement;\n \"fespotlight\": SVGFESpotLightElement;\n \"fetile\": SVGFETileElement;\n \"feturbulence\": SVGFETurbulenceElement;\n \"fieldset\": HTMLFieldSetElement;\n \"figcaption\": HTMLElement;\n \"figure\": HTMLElement;\n \"filter\": SVGFilterElement;\n \"font\": HTMLFontElement;\n \"footer\": HTMLElement;\n \"foreignobject\": SVGForeignObjectElement;\n \"form\": HTMLFormElement;\n \"frame\": HTMLFrameElement;\n \"frameset\": HTMLFrameSetElement;\n \"g\": SVGGElement;\n \"h1\": HTMLHeadingElement;\n \"h2\": HTMLHeadingElement;\n \"h3\": HTMLHeadingElement;\n \"h4\": HTMLHeadingElement;\n \"h5\": HTMLHeadingElement;\n \"h6\": HTMLHeadingElement;\n \"head\": HTMLHeadElement;\n \"header\": HTMLElement;\n \"hgroup\": HTMLElement;\n \"hr\": HTMLHRElement;\n \"html\": HTMLHtmlElement;\n \"i\": HTMLElement;\n \"iframe\": HTMLIFrameElement;\n \"image\": SVGImageElement;\n \"img\": HTMLImageElement;\n \"input\": HTMLInputElement;\n \"ins\": HTMLModElement;\n \"isindex\": HTMLUnknownElement;\n \"kbd\": HTMLElement;\n \"keygen\": HTMLElement;\n \"label\": HTMLLabelElement;\n \"legend\": HTMLLegendElement;\n \"li\": HTMLLIElement;\n \"line\": SVGLineElement;\n \"lineargradient\": SVGLinearGradientElement;\n \"link\": HTMLLinkElement;\n \"listing\": HTMLPreElement;\n \"map\": HTMLMapElement;\n \"mark\": HTMLElement;\n \"marker\": SVGMarkerElement;\n \"marquee\": HTMLMarqueeElement;\n \"mask\": SVGMaskElement;\n \"menu\": HTMLMenuElement;\n \"meta\": HTMLMetaElement;\n \"metadata\": SVGMetadataElement;\n \"meter\": HTMLMeterElement;\n \"nav\": HTMLElement;\n \"nextid\": HTMLUnknownElement;\n \"nobr\": HTMLElement;\n \"noframes\": HTMLElement;\n \"noscript\": HTMLElement;\n \"object\": HTMLObjectElement;\n \"ol\": HTMLOListElement;\n \"optgroup\": HTMLOptGroupElement;\n \"option\": HTMLOptionElement;\n \"output\": HTMLOutputElement;\n \"p\": HTMLParagraphElement;\n \"param\": HTMLParamElement;\n \"path\": SVGPathElement;\n \"pattern\": SVGPatternElement;\n \"picture\": HTMLPictureElement;\n \"plaintext\": HTMLElement;\n \"polygon\": SVGPolygonElement;\n \"polyline\": SVGPolylineElement;\n \"pre\": HTMLPreElement;\n \"progress\": HTMLProgressElement;\n \"q\": HTMLQuoteElement;\n \"radialgradient\": SVGRadialGradientElement;\n \"rect\": SVGRectElement;\n \"rt\": HTMLElement;\n \"ruby\": HTMLElement;\n \"s\": HTMLElement;\n \"samp\": HTMLElement;\n \"script\": HTMLScriptElement;\n \"section\": HTMLElement;\n \"select\": HTMLSelectElement;\n \"small\": HTMLElement;\n \"source\": HTMLSourceElement;\n \"span\": HTMLSpanElement;\n \"stop\": SVGStopElement;\n \"strike\": HTMLElement;\n \"strong\": HTMLElement;\n \"style\": HTMLStyleElement;\n \"sub\": HTMLElement;\n \"sup\": HTMLElement;\n \"svg\": SVGSVGElement;\n \"switch\": SVGSwitchElement;\n \"symbol\": SVGSymbolElement;\n \"table\": HTMLTableElement;\n \"tbody\": HTMLTableSectionElement;\n \"td\": HTMLTableDataCellElement;\n \"template\": HTMLTemplateElement;\n \"text\": SVGTextElement;\n \"textpath\": SVGTextPathElement;\n \"textarea\": HTMLTextAreaElement;\n \"tfoot\": HTMLTableSectionElement;\n \"th\": HTMLTableHeaderCellElement;\n \"thead\": HTMLTableSectionElement;\n \"time\": HTMLTimeElement;\n \"title\": HTMLTitleElement;\n \"tr\": HTMLTableRowElement;\n \"track\": HTMLTrackElement;\n \"tspan\": SVGTSpanElement;\n \"tt\": HTMLElement;\n \"u\": HTMLElement;\n \"ul\": HTMLUListElement;\n \"use\": SVGUseElement;\n \"var\": HTMLElement;\n \"video\": HTMLVideoElement;\n \"view\": SVGViewElement;\n \"wbr\": HTMLElement;\n \"x-ms-webview\": MSHTMLWebViewElement;\n \"xmp\": HTMLPreElement;\n}\n\ninterface ElementListTagNameMap {\n \"a\": NodeListOf;\n \"abbr\": NodeListOf;\n \"acronym\": NodeListOf;\n \"address\": NodeListOf;\n \"applet\": NodeListOf;\n \"area\": NodeListOf;\n \"article\": NodeListOf;\n \"aside\": NodeListOf;\n \"audio\": NodeListOf;\n \"b\": NodeListOf;\n \"base\": NodeListOf;\n \"basefont\": NodeListOf;\n \"bdo\": NodeListOf;\n \"big\": NodeListOf;\n \"blockquote\": NodeListOf;\n \"body\": NodeListOf;\n \"br\": NodeListOf;\n \"button\": NodeListOf;\n \"canvas\": NodeListOf;\n \"caption\": NodeListOf;\n \"center\": NodeListOf;\n \"circle\": NodeListOf;\n \"cite\": NodeListOf;\n \"clippath\": NodeListOf;\n \"code\": NodeListOf;\n \"col\": NodeListOf;\n \"colgroup\": NodeListOf;\n \"data\": NodeListOf;\n \"datalist\": NodeListOf;\n \"dd\": NodeListOf;\n \"defs\": NodeListOf;\n \"del\": NodeListOf;\n \"desc\": NodeListOf;\n \"dfn\": NodeListOf;\n \"dir\": NodeListOf;\n \"div\": NodeListOf;\n \"dl\": NodeListOf;\n \"dt\": NodeListOf;\n \"ellipse\": NodeListOf;\n \"em\": NodeListOf;\n \"embed\": NodeListOf;\n \"feblend\": NodeListOf;\n \"fecolormatrix\": NodeListOf;\n \"fecomponenttransfer\": NodeListOf;\n \"fecomposite\": NodeListOf;\n \"feconvolvematrix\": NodeListOf;\n \"fediffuselighting\": NodeListOf;\n \"fedisplacementmap\": NodeListOf;\n \"fedistantlight\": NodeListOf;\n \"feflood\": NodeListOf;\n \"fefunca\": NodeListOf;\n \"fefuncb\": NodeListOf;\n \"fefuncg\": NodeListOf;\n \"fefuncr\": NodeListOf;\n \"fegaussianblur\": NodeListOf;\n \"feimage\": NodeListOf;\n \"femerge\": NodeListOf;\n \"femergenode\": NodeListOf;\n \"femorphology\": NodeListOf;\n \"feoffset\": NodeListOf;\n \"fepointlight\": NodeListOf;\n \"fespecularlighting\": NodeListOf;\n \"fespotlight\": NodeListOf;\n \"fetile\": NodeListOf;\n \"feturbulence\": NodeListOf;\n \"fieldset\": NodeListOf;\n \"figcaption\": NodeListOf;\n \"figure\": NodeListOf;\n \"filter\": NodeListOf;\n \"font\": NodeListOf;\n \"footer\": NodeListOf;\n \"foreignobject\": NodeListOf;\n \"form\": NodeListOf;\n \"frame\": NodeListOf;\n \"frameset\": NodeListOf;\n \"g\": NodeListOf;\n \"h1\": NodeListOf;\n \"h2\": NodeListOf;\n \"h3\": NodeListOf;\n \"h4\": NodeListOf;\n \"h5\": NodeListOf;\n \"h6\": NodeListOf;\n \"head\": NodeListOf;\n \"header\": NodeListOf;\n \"hgroup\": NodeListOf;\n \"hr\": NodeListOf;\n \"html\": NodeListOf;\n \"i\": NodeListOf;\n \"iframe\": NodeListOf;\n \"image\": NodeListOf;\n \"img\": NodeListOf;\n \"input\": NodeListOf;\n \"ins\": NodeListOf;\n \"isindex\": NodeListOf;\n \"kbd\": NodeListOf;\n \"keygen\": NodeListOf;\n \"label\": NodeListOf;\n \"legend\": NodeListOf;\n \"li\": NodeListOf;\n \"line\": NodeListOf;\n \"lineargradient\": NodeListOf;\n \"link\": NodeListOf;\n \"listing\": NodeListOf;\n \"map\": NodeListOf;\n \"mark\": NodeListOf;\n \"marker\": NodeListOf;\n \"marquee\": NodeListOf;\n \"mask\": NodeListOf;\n \"menu\": NodeListOf;\n \"meta\": NodeListOf;\n \"metadata\": NodeListOf;\n \"meter\": NodeListOf;\n \"nav\": NodeListOf;\n \"nextid\": NodeListOf;\n \"nobr\": NodeListOf;\n \"noframes\": NodeListOf;\n \"noscript\": NodeListOf;\n \"object\": NodeListOf;\n \"ol\": NodeListOf;\n \"optgroup\": NodeListOf;\n \"option\": NodeListOf;\n \"output\": NodeListOf;\n \"p\": NodeListOf;\n \"param\": NodeListOf;\n \"path\": NodeListOf;\n \"pattern\": NodeListOf;\n \"picture\": NodeListOf;\n \"plaintext\": NodeListOf;\n \"polygon\": NodeListOf;\n \"polyline\": NodeListOf;\n \"pre\": NodeListOf;\n \"progress\": NodeListOf;\n \"q\": NodeListOf;\n \"radialgradient\": NodeListOf;\n \"rect\": NodeListOf;\n \"rt\": NodeListOf;\n \"ruby\": NodeListOf;\n \"s\": NodeListOf;\n \"samp\": NodeListOf;\n \"script\": NodeListOf;\n \"section\": NodeListOf;\n \"select\": NodeListOf;\n \"small\": NodeListOf;\n \"source\": NodeListOf;\n \"span\": NodeListOf;\n \"stop\": NodeListOf;\n \"strike\": NodeListOf;\n \"strong\": NodeListOf;\n \"style\": NodeListOf;\n \"sub\": NodeListOf;\n \"sup\": NodeListOf;\n \"svg\": NodeListOf;\n \"switch\": NodeListOf;\n \"symbol\": NodeListOf;\n \"table\": NodeListOf;\n \"tbody\": NodeListOf;\n \"td\": NodeListOf;\n \"template\": NodeListOf;\n \"text\": NodeListOf;\n \"textpath\": NodeListOf;\n \"textarea\": NodeListOf;\n \"tfoot\": NodeListOf;\n \"th\": NodeListOf;\n \"thead\": NodeListOf;\n \"time\": NodeListOf;\n \"title\": NodeListOf;\n \"tr\": NodeListOf;\n \"track\": NodeListOf;\n \"tspan\": NodeListOf;\n \"tt\": NodeListOf;\n \"u\": NodeListOf;\n \"ul\": NodeListOf;\n \"use\": NodeListOf;\n \"var\": NodeListOf;\n \"video\": NodeListOf;\n \"view\": NodeListOf;\n \"wbr\": NodeListOf;\n \"x-ms-webview\": NodeListOf;\n \"xmp\": NodeListOf;\n}\n\ndeclare var Audio: {new(src?: string): HTMLAudioElement; };\ndeclare var Image: {new(width?: number, height?: number): HTMLImageElement; };\ndeclare var Option: {new(text?: string, value?: string, defaultSelected?: boolean, selected?: boolean): HTMLOptionElement; };\ndeclare var applicationCache: ApplicationCache;\ndeclare var caches: CacheStorage;\ndeclare var clientInformation: Navigator;\ndeclare var closed: boolean;\ndeclare var crypto: Crypto;\ndeclare var defaultStatus: string;\ndeclare var devicePixelRatio: number;\ndeclare var doNotTrack: string;\ndeclare var document: Document;\ndeclare var event: Event | undefined;\ndeclare var external: External;\ndeclare var frameElement: Element;\ndeclare var frames: Window;\ndeclare var history: History;\ndeclare var innerHeight: number;\ndeclare var innerWidth: number;\ndeclare var isSecureContext: boolean;\ndeclare var length: number;\ndeclare var location: Location;\ndeclare var locationbar: BarProp;\ndeclare var menubar: BarProp;\ndeclare var msContentScript: ExtensionScriptApis;\ndeclare var msCredentials: MSCredentials;\ndeclare const name: never;\ndeclare var navigator: Navigator;\ndeclare var offscreenBuffering: string | boolean;\ndeclare var onabort: (this: Window, ev: UIEvent) => any;\ndeclare var onafterprint: (this: Window, ev: Event) => any;\ndeclare var onbeforeprint: (this: Window, ev: Event) => any;\ndeclare var onbeforeunload: (this: Window, ev: BeforeUnloadEvent) => any;\ndeclare var onblur: (this: Window, ev: FocusEvent) => any;\ndeclare var oncanplay: (this: Window, ev: Event) => any;\ndeclare var oncanplaythrough: (this: Window, ev: Event) => any;\ndeclare var onchange: (this: Window, ev: Event) => any;\ndeclare var onclick: (this: Window, ev: MouseEvent) => any;\ndeclare var oncompassneedscalibration: (this: Window, ev: Event) => any;\ndeclare var oncontextmenu: (this: Window, ev: PointerEvent) => any;\ndeclare var ondblclick: (this: Window, ev: MouseEvent) => any;\ndeclare var ondevicelight: (this: Window, ev: DeviceLightEvent) => any;\ndeclare var ondevicemotion: (this: Window, ev: DeviceMotionEvent) => any;\ndeclare var ondeviceorientation: (this: Window, ev: DeviceOrientationEvent) => any;\ndeclare var ondrag: (this: Window, ev: DragEvent) => any;\ndeclare var ondragend: (this: Window, ev: DragEvent) => any;\ndeclare var ondragenter: (this: Window, ev: DragEvent) => any;\ndeclare var ondragleave: (this: Window, ev: DragEvent) => any;\ndeclare var ondragover: (this: Window, ev: DragEvent) => any;\ndeclare var ondragstart: (this: Window, ev: DragEvent) => any;\ndeclare var ondrop: (this: Window, ev: DragEvent) => any;\ndeclare var ondurationchange: (this: Window, ev: Event) => any;\ndeclare var onemptied: (this: Window, ev: Event) => any;\ndeclare var onended: (this: Window, ev: MediaStreamErrorEvent) => any;\ndeclare var onerror: ErrorEventHandler;\ndeclare var onfocus: (this: Window, ev: FocusEvent) => any;\ndeclare var onhashchange: (this: Window, ev: HashChangeEvent) => any;\ndeclare var oninput: (this: Window, ev: Event) => any;\ndeclare var oninvalid: (this: Window, ev: Event) => any;\ndeclare var onkeydown: (this: Window, ev: KeyboardEvent) => any;\ndeclare var onkeypress: (this: Window, ev: KeyboardEvent) => any;\ndeclare var onkeyup: (this: Window, ev: KeyboardEvent) => any;\ndeclare var onload: (this: Window, ev: Event) => any;\ndeclare var onloadeddata: (this: Window, ev: Event) => any;\ndeclare var onloadedmetadata: (this: Window, ev: Event) => any;\ndeclare var onloadstart: (this: Window, ev: Event) => any;\ndeclare var onmessage: (this: Window, ev: MessageEvent) => any;\ndeclare var onmousedown: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseenter: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseleave: (this: Window, ev: MouseEvent) => any;\ndeclare var onmousemove: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseout: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseover: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseup: (this: Window, ev: MouseEvent) => any;\ndeclare var onmousewheel: (this: Window, ev: WheelEvent) => any;\ndeclare var onmsgesturechange: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturedoubletap: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgestureend: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturehold: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturestart: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturetap: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsinertiastart: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmspointercancel: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerdown: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerenter: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerleave: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointermove: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerout: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerover: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerup: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onoffline: (this: Window, ev: Event) => any;\ndeclare var ononline: (this: Window, ev: Event) => any;\ndeclare var onorientationchange: (this: Window, ev: Event) => any;\ndeclare var onpagehide: (this: Window, ev: PageTransitionEvent) => any;\ndeclare var onpageshow: (this: Window, ev: PageTransitionEvent) => any;\ndeclare var onpause: (this: Window, ev: Event) => any;\ndeclare var onplay: (this: Window, ev: Event) => any;\ndeclare var onplaying: (this: Window, ev: Event) => any;\ndeclare var onpopstate: (this: Window, ev: PopStateEvent) => any;\ndeclare var onprogress: (this: Window, ev: ProgressEvent) => any;\ndeclare var onratechange: (this: Window, ev: Event) => any;\ndeclare var onreadystatechange: (this: Window, ev: ProgressEvent) => any;\ndeclare var onreset: (this: Window, ev: Event) => any;\ndeclare var onresize: (this: Window, ev: UIEvent) => any;\ndeclare var onscroll: (this: Window, ev: UIEvent) => any;\ndeclare var onseeked: (this: Window, ev: Event) => any;\ndeclare var onseeking: (this: Window, ev: Event) => any;\ndeclare var onselect: (this: Window, ev: UIEvent) => any;\ndeclare var onstalled: (this: Window, ev: Event) => any;\ndeclare var onstorage: (this: Window, ev: StorageEvent) => any;\ndeclare var onsubmit: (this: Window, ev: Event) => any;\ndeclare var onsuspend: (this: Window, ev: Event) => any;\ndeclare var ontimeupdate: (this: Window, ev: Event) => any;\ndeclare var ontouchcancel: (ev: TouchEvent) => any;\ndeclare var ontouchend: (ev: TouchEvent) => any;\ndeclare var ontouchmove: (ev: TouchEvent) => any;\ndeclare var ontouchstart: (ev: TouchEvent) => any;\ndeclare var onunload: (this: Window, ev: Event) => any;\ndeclare var onvolumechange: (this: Window, ev: Event) => any;\ndeclare var onwaiting: (this: Window, ev: Event) => any;\ndeclare var opener: any;\ndeclare var orientation: string | number;\ndeclare var outerHeight: number;\ndeclare var outerWidth: number;\ndeclare var pageXOffset: number;\ndeclare var pageYOffset: number;\ndeclare var parent: Window;\ndeclare var performance: Performance;\ndeclare var personalbar: BarProp;\ndeclare var screen: Screen;\ndeclare var screenLeft: number;\ndeclare var screenTop: number;\ndeclare var screenX: number;\ndeclare var screenY: number;\ndeclare var scrollX: number;\ndeclare var scrollY: number;\ndeclare var scrollbars: BarProp;\ndeclare var self: Window;\ndeclare var speechSynthesis: SpeechSynthesis;\ndeclare var status: string;\ndeclare var statusbar: BarProp;\ndeclare var styleMedia: StyleMedia;\ndeclare var toolbar: BarProp;\ndeclare var top: Window;\ndeclare var window: Window;\ndeclare var customElements: CustomElementRegistry;\ndeclare function alert(message?: any): void;\ndeclare function blur(): void;\ndeclare function cancelAnimationFrame(handle: number): void;\ndeclare function captureEvents(): void;\ndeclare function close(): void;\ndeclare function confirm(message?: string): boolean;\ndeclare function departFocus(navigationReason: NavigationReason, origin: FocusNavigationOrigin): void;\ndeclare function focus(): void;\ndeclare function getComputedStyle(elt: Element, pseudoElt?: string): CSSStyleDeclaration;\ndeclare function getMatchedCSSRules(elt: Element, pseudoElt?: string): CSSRuleList;\ndeclare function getSelection(): Selection;\ndeclare function matchMedia(mediaQuery: string): MediaQueryList;\ndeclare function moveBy(x?: number, y?: number): void;\ndeclare function moveTo(x?: number, y?: number): void;\ndeclare function msWriteProfilerMark(profilerMarkName: string): void;\ndeclare function open(url?: string, target?: string, features?: string, replace?: boolean): Window;\ndeclare function postMessage(message: any, targetOrigin: string, transfer?: any[]): void;\ndeclare function print(): void;\ndeclare function prompt(message?: string, _default?: string): string | null;\ndeclare function releaseEvents(): void;\ndeclare function requestAnimationFrame(callback: FrameRequestCallback): number;\ndeclare function resizeBy(x?: number, y?: number): void;\ndeclare function resizeTo(x?: number, y?: number): void;\ndeclare function scroll(x?: number, y?: number): void;\ndeclare function scrollBy(x?: number, y?: number): void;\ndeclare function scrollTo(x?: number, y?: number): void;\ndeclare function stop(): void;\ndeclare function webkitCancelAnimationFrame(handle: number): void;\ndeclare function webkitConvertPointFromNodeToPage(node: Node, pt: WebKitPoint): WebKitPoint;\ndeclare function webkitConvertPointFromPageToNode(node: Node, pt: WebKitPoint): WebKitPoint;\ndeclare function webkitRequestAnimationFrame(callback: FrameRequestCallback): number;\ndeclare function createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, options?: ImageBitmapOptions): Promise;\ndeclare function createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, sx: number, sy: number, sw: number, sh: number, options?: ImageBitmapOptions): Promise;\ndeclare function scroll(options?: ScrollToOptions): void;\ndeclare function scrollTo(options?: ScrollToOptions): void;\ndeclare function scrollBy(options?: ScrollToOptions): void;\ndeclare function toString(): string;\ndeclare function dispatchEvent(evt: Event): boolean;\ndeclare function removeEventListener(type: string, listener?: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;\ndeclare function clearInterval(handle: number): void;\ndeclare function clearTimeout(handle: number): void;\ndeclare function setInterval(handler: (...args: any[]) => void, timeout: number): number;\ndeclare function setInterval(handler: any, timeout?: any, ...args: any[]): number;\ndeclare function setTimeout(handler: (...args: any[]) => void, timeout: number): number;\ndeclare function setTimeout(handler: any, timeout?: any, ...args: any[]): number;\ndeclare function clearImmediate(handle: number): void;\ndeclare function setImmediate(handler: (...args: any[]) => void): number;\ndeclare function setImmediate(handler: any, ...args: any[]): number;\ndeclare var sessionStorage: Storage;\ndeclare var localStorage: Storage;\ndeclare var console: Console;\ndeclare var onpointercancel: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerdown: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerenter: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerleave: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointermove: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerout: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerover: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerup: (this: Window, ev: PointerEvent) => any;\ndeclare var onwheel: (this: Window, ev: WheelEvent) => any;\ndeclare var indexedDB: IDBFactory;\ndeclare function atob(encodedString: string): string;\ndeclare function btoa(rawString: string): string;\ndeclare function fetch(input: RequestInfo, init?: RequestInit): Promise;\ndeclare function addEventListener(type: K, listener: (this: Window, ev: WindowEventMap[K]) => any, useCapture?: boolean): void;\ndeclare function addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\ntype AAGUID = string;\ntype AlgorithmIdentifier = string | Algorithm;\ntype BodyInit = any;\ntype ByteString = string;\ntype ConstrainBoolean = boolean | ConstrainBooleanParameters;\ntype ConstrainDOMString = string | string[] | ConstrainDOMStringParameters;\ntype ConstrainDouble = number | ConstrainDoubleRange;\ntype ConstrainLong = number | ConstrainLongRange;\ntype CryptoOperationData = ArrayBufferView;\ntype GLbitfield = number;\ntype GLboolean = boolean;\ntype GLbyte = number;\ntype GLclampf = number;\ntype GLenum = number;\ntype GLfloat = number;\ntype GLint = number;\ntype GLintptr = number;\ntype GLshort = number;\ntype GLsizei = number;\ntype GLsizeiptr = number;\ntype GLubyte = number;\ntype GLuint = number;\ntype GLushort = number;\ntype HeadersInit = any;\ntype IDBKeyPath = string;\ntype KeyFormat = string;\ntype KeyType = string;\ntype KeyUsage = string;\ntype MSInboundPayload = MSVideoRecvPayload | MSAudioRecvPayload;\ntype MSLocalClientEvent = MSLocalClientEventBase | MSAudioLocalClientEvent;\ntype MSOutboundPayload = MSVideoSendPayload | MSAudioSendPayload;\ntype RTCIceGatherCandidate = RTCIceCandidateDictionary | RTCIceCandidateComplete;\ntype RTCTransport = RTCDtlsTransport | RTCSrtpSdesTransport;\ntype RequestInfo = Request | string;\ntype USVString = string;\ntype payloadtype = number;\ntype ScrollBehavior = \"auto\" | \"instant\" | \"smooth\";\ntype ScrollLogicalPosition = \"start\" | \"center\" | \"end\" | \"nearest\";\ntype IDBValidKey = number | string | Date | IDBArrayKey;\ntype BufferSource = ArrayBuffer | ArrayBufferView;\ntype MouseWheelEvent = WheelEvent;\ntype ScrollRestoration = \"auto\" | \"manual\";\ntype FormDataEntryValue = string | File;\ntype AppendMode = \"segments\" | \"sequence\";\ntype AudioContextState = \"suspended\" | \"running\" | \"closed\";\ntype BiquadFilterType = \"lowpass\" | \"highpass\" | \"bandpass\" | \"lowshelf\" | \"highshelf\" | \"peaking\" | \"notch\" | \"allpass\";\ntype CanvasFillRule = \"nonzero\" | \"evenodd\";\ntype ChannelCountMode = \"max\" | \"clamped-max\" | \"explicit\";\ntype ChannelInterpretation = \"speakers\" | \"discrete\";\ntype DistanceModelType = \"linear\" | \"inverse\" | \"exponential\";\ntype ExpandGranularity = \"character\" | \"word\" | \"sentence\" | \"textedit\";\ntype GamepadInputEmulationType = \"mouse\" | \"keyboard\" | \"gamepad\";\ntype IDBCursorDirection = \"next\" | \"nextunique\" | \"prev\" | \"prevunique\";\ntype IDBRequestReadyState = \"pending\" | \"done\";\ntype IDBTransactionMode = \"readonly\" | \"readwrite\" | \"versionchange\";\ntype ListeningState = \"inactive\" | \"active\" | \"disambiguation\";\ntype MSCredentialType = \"FIDO_2_0\";\ntype MSIceAddrType = \"os\" | \"stun\" | \"turn\" | \"peer-derived\";\ntype MSIceType = \"failed\" | \"direct\" | \"relay\";\ntype MSStatsType = \"description\" | \"localclientevent\" | \"inbound-network\" | \"outbound-network\" | \"inbound-payload\" | \"outbound-payload\" | \"transportdiagnostics\";\ntype MSTransportType = \"Embedded\" | \"USB\" | \"NFC\" | \"BT\";\ntype MSWebViewPermissionState = \"unknown\" | \"defer\" | \"allow\" | \"deny\";\ntype MSWebViewPermissionType = \"geolocation\" | \"unlimitedIndexedDBQuota\" | \"media\" | \"pointerlock\" | \"webnotifications\";\ntype MediaDeviceKind = \"audioinput\" | \"audiooutput\" | \"videoinput\";\ntype MediaKeyMessageType = \"license-request\" | \"license-renewal\" | \"license-release\" | \"individualization-request\";\ntype MediaKeySessionType = \"temporary\" | \"persistent-license\" | \"persistent-release-message\";\ntype MediaKeyStatus = \"usable\" | \"expired\" | \"output-downscaled\" | \"output-not-allowed\" | \"status-pending\" | \"internal-error\";\ntype MediaKeysRequirement = \"required\" | \"optional\" | \"not-allowed\";\ntype MediaStreamTrackState = \"live\" | \"ended\";\ntype NavigationReason = \"up\" | \"down\" | \"left\" | \"right\";\ntype NavigationType = \"navigate\" | \"reload\" | \"back_forward\" | \"prerender\";\ntype NotificationDirection = \"auto\" | \"ltr\" | \"rtl\";\ntype NotificationPermission = \"default\" | \"denied\" | \"granted\";\ntype OscillatorType = \"sine\" | \"square\" | \"sawtooth\" | \"triangle\" | \"custom\";\ntype OverSampleType = \"none\" | \"2x\" | \"4x\";\ntype PanningModelType = \"equalpower\";\ntype PaymentComplete = \"success\" | \"fail\" | \"\";\ntype PaymentShippingType = \"shipping\" | \"delivery\" | \"pickup\";\ntype PushEncryptionKeyName = \"p256dh\" | \"auth\";\ntype PushPermissionState = \"granted\" | \"denied\" | \"prompt\";\ntype RTCBundlePolicy = \"balanced\" | \"max-compat\" | \"max-bundle\";\ntype RTCDegradationPreference = \"maintain-framerate\" | \"maintain-resolution\" | \"balanced\";\ntype RTCDtlsRole = \"auto\" | \"client\" | \"server\";\ntype RTCDtlsTransportState = \"new\" | \"connecting\" | \"connected\" | \"closed\";\ntype RTCIceCandidateType = \"host\" | \"srflx\" | \"prflx\" | \"relay\";\ntype RTCIceComponent = \"RTP\" | \"RTCP\";\ntype RTCIceConnectionState = \"new\" | \"checking\" | \"connected\" | \"completed\" | \"failed\" | \"disconnected\" | \"closed\";\ntype RTCIceGatherPolicy = \"all\" | \"nohost\" | \"relay\";\ntype RTCIceGathererState = \"new\" | \"gathering\" | \"complete\";\ntype RTCIceGatheringState = \"new\" | \"gathering\" | \"complete\";\ntype RTCIceProtocol = \"udp\" | \"tcp\";\ntype RTCIceRole = \"controlling\" | \"controlled\";\ntype RTCIceTcpCandidateType = \"active\" | \"passive\" | \"so\";\ntype RTCIceTransportPolicy = \"none\" | \"relay\" | \"all\";\ntype RTCIceTransportState = \"new\" | \"checking\" | \"connected\" | \"completed\" | \"disconnected\" | \"closed\";\ntype RTCSdpType = \"offer\" | \"pranswer\" | \"answer\";\ntype RTCSignalingState = \"stable\" | \"have-local-offer\" | \"have-remote-offer\" | \"have-local-pranswer\" | \"have-remote-pranswer\" | \"closed\";\ntype RTCStatsIceCandidatePairState = \"frozen\" | \"waiting\" | \"inprogress\" | \"failed\" | \"succeeded\" | \"cancelled\";\ntype RTCStatsIceCandidateType = \"host\" | \"serverreflexive\" | \"peerreflexive\" | \"relayed\";\ntype RTCStatsType = \"inboundrtp\" | \"outboundrtp\" | \"session\" | \"datachannel\" | \"track\" | \"transport\" | \"candidatepair\" | \"localcandidate\" | \"remotecandidate\";\ntype ReferrerPolicy = \"\" | \"no-referrer\" | \"no-referrer-when-downgrade\" | \"origin-only\" | \"origin-when-cross-origin\" | \"unsafe-url\";\ntype RequestCache = \"default\" | \"no-store\" | \"reload\" | \"no-cache\" | \"force-cache\";\ntype RequestCredentials = \"omit\" | \"same-origin\" | \"include\";\ntype RequestDestination = \"\" | \"document\" | \"sharedworker\" | \"subresource\" | \"unknown\" | \"worker\";\ntype RequestMode = \"navigate\" | \"same-origin\" | \"no-cors\" | \"cors\";\ntype RequestRedirect = \"follow\" | \"error\" | \"manual\";\ntype RequestType = \"\" | \"audio\" | \"font\" | \"image\" | \"script\" | \"style\" | \"track\" | \"video\";\ntype ResponseType = \"basic\" | \"cors\" | \"default\" | \"error\" | \"opaque\" | \"opaqueredirect\";\ntype ScopedCredentialType = \"ScopedCred\";\ntype ServiceWorkerState = \"installing\" | \"installed\" | \"activating\" | \"activated\" | \"redundant\";\ntype Transport = \"usb\" | \"nfc\" | \"ble\";\ntype VideoFacingModeEnum = \"user\" | \"environment\" | \"left\" | \"right\";\ntype VisibilityState = \"hidden\" | \"visible\" | \"prerender\" | \"unloaded\";\ntype XMLHttpRequestResponseType = \"\" | \"arraybuffer\" | \"blob\" | \"document\" | \"json\" | \"text\";\n\n\n/////////////////////////////\n/// WorkerGlobalScope APIs\n/////////////////////////////\n// These are only available in a Web Worker\ndeclare function importScripts(...urls: string[]): void;\n\n\n\n\n/////////////////////////////\n/// Windows Script Host APIS\n/////////////////////////////\n\n\ninterface ActiveXObject {\n new (s: string): any;\n}\ndeclare var ActiveXObject: ActiveXObject;\n\ninterface ITextWriter {\n Write(s: string): void;\n WriteLine(s: string): void;\n Close(): void;\n}\n\ninterface TextStreamBase {\n /**\n * The column number of the current character position in an input stream.\n */\n Column: number;\n\n /**\n * The current line number in an input stream.\n */\n Line: number;\n\n /**\n * Closes a text stream.\n * It is not necessary to close standard streams; they close automatically when the process ends. If\n * you close a standard stream, be aware that any other pointers to that standard stream become invalid.\n */\n Close(): void;\n}\n\ninterface TextStreamWriter extends TextStreamBase {\n /**\n * Sends a string to an output stream.\n */\n Write(s: string): void;\n\n /**\n * Sends a specified number of blank lines (newline characters) to an output stream.\n */\n WriteBlankLines(intLines: number): void;\n\n /**\n * Sends a string followed by a newline character to an output stream.\n */\n WriteLine(s: string): void;\n}\n\ninterface TextStreamReader extends TextStreamBase {\n /**\n * Returns a specified number of characters from an input stream, starting at the current pointer position.\n * Does not return until the ENTER key is pressed.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n */\n Read(characters: number): string;\n\n /**\n * Returns all characters from an input stream.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n */\n ReadAll(): string;\n\n /**\n * Returns an entire line from an input stream.\n * Although this method extracts the newline character, it does not add it to the returned string.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n */\n ReadLine(): string;\n\n /**\n * Skips a specified number of characters when reading from an input text stream.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n * @param characters Positive number of characters to skip forward. (Backward skipping is not supported.)\n */\n Skip(characters: number): void;\n\n /**\n * Skips the next line when reading from an input text stream.\n * Can only be used on a stream in reading mode, not writing or appending mode.\n */\n SkipLine(): void;\n\n /**\n * Indicates whether the stream pointer position is at the end of a line.\n */\n AtEndOfLine: boolean;\n\n /**\n * Indicates whether the stream pointer position is at the end of a stream.\n */\n AtEndOfStream: boolean;\n}\n\ndeclare var WScript: {\n /**\n * Outputs text to either a message box (under WScript.exe) or the command console window followed by\n * a newline (under CScript.exe).\n */\n Echo(s: any): void;\n\n /**\n * Exposes the write-only error output stream for the current script.\n * Can be accessed only while using CScript.exe.\n */\n StdErr: TextStreamWriter;\n\n /**\n * Exposes the write-only output stream for the current script.\n * Can be accessed only while using CScript.exe.\n */\n StdOut: TextStreamWriter;\n Arguments: { length: number; Item(n: number): string; };\n\n /**\n * The full path of the currently running script.\n */\n ScriptFullName: string;\n\n /**\n * Forces the script to stop immediately, with an optional exit code.\n */\n Quit(exitCode?: number): number;\n\n /**\n * The Windows Script Host build version number.\n */\n BuildVersion: number;\n\n /**\n * Fully qualified path of the host executable.\n */\n FullName: string;\n\n /**\n * Gets/sets the script mode - interactive(true) or batch(false).\n */\n Interactive: boolean;\n\n /**\n * The name of the host executable (WScript.exe or CScript.exe).\n */\n Name: string;\n\n /**\n * Path of the directory containing the host executable.\n */\n Path: string;\n\n /**\n * The filename of the currently running script.\n */\n ScriptName: string;\n\n /**\n * Exposes the read-only input stream for the current script.\n * Can be accessed only while using CScript.exe.\n */\n StdIn: TextStreamReader;\n\n /**\n * Windows Script Host version\n */\n Version: string;\n\n /**\n * Connects a COM object's event sources to functions named with a given prefix, in the form prefix_event.\n */\n ConnectObject(objEventSource: any, strPrefix: string): void;\n\n /**\n * Creates a COM object.\n * @param strProgiID\n * @param strPrefix Function names in the form prefix_event will be bound to this object's COM events.\n */\n CreateObject(strProgID: string, strPrefix?: string): any;\n\n /**\n * Disconnects a COM object from its event sources.\n */\n DisconnectObject(obj: any): void;\n\n /**\n * Retrieves an existing object with the specified ProgID from memory, or creates a new one from a file.\n * @param strPathname Fully qualified path to the file containing the object persisted to disk.\n * For objects in memory, pass a zero-length string.\n * @param strProgID\n * @param strPrefix Function names in the form prefix_event will be bound to this object's COM events.\n */\n GetObject(strPathname: string, strProgID?: string, strPrefix?: string): any;\n\n /**\n * Suspends script execution for a specified length of time, then continues execution.\n * @param intTime Interval (in milliseconds) to suspend script execution.\n */\n Sleep(intTime: number): void;\n};\n\n/**\n * Allows enumerating over a COM collection, which may not have indexed item access.\n */\ninterface Enumerator {\n /**\n * Returns true if the current item is the last one in the collection, or the collection is empty,\n * or the current item is undefined.\n */\n atEnd(): boolean;\n\n /**\n * Returns the current item in the collection\n */\n item(): T;\n\n /**\n * Resets the current item in the collection to the first item. If there are no items in the collection,\n * the current item is set to undefined.\n */\n moveFirst(): void;\n\n /**\n * Moves the current item to the next item in the collection. If the enumerator is at the end of\n * the collection or the collection is empty, the current item is set to undefined.\n */\n moveNext(): void;\n}\n\ninterface EnumeratorConstructor {\n new (collection: any): Enumerator;\n new (collection: any): Enumerator;\n}\n\ndeclare var Enumerator: EnumeratorConstructor;\n\n/**\n * Enables reading from a COM safe array, which might have an alternate lower bound, or multiple dimensions.\n */\ninterface VBArray {\n /**\n * Returns the number of dimensions (1-based).\n */\n dimensions(): number;\n\n /**\n * Takes an index for each dimension in the array, and returns the item at the corresponding location.\n */\n getItem(dimension1Index: number, ...dimensionNIndexes: number[]): T;\n\n /**\n * Returns the smallest available index for a given dimension.\n * @param dimension 1-based dimension (defaults to 1)\n */\n lbound(dimension?: number): number;\n\n /**\n * Returns the largest available index for a given dimension.\n * @param dimension 1-based dimension (defaults to 1)\n */\n ubound(dimension?: number): number;\n\n /**\n * Returns a Javascript array with all the elements in the VBArray. If there are multiple dimensions,\n * each successive dimension is appended to the end of the array.\n * Example: [[1,2,3],[4,5,6]] becomes [1,2,3,4,5,6]\n */\n toArray(): T[];\n}\n\ninterface VBArrayConstructor {\n new (safeArray: any): VBArray;\n new (safeArray: any): VBArray;\n}\n\ndeclare var VBArray: VBArrayConstructor;\n\n/**\n * Automation date (VT_DATE)\n */\ninterface VarDate { }\n\ninterface DateConstructor {\n new (vd: VarDate): Date;\n}\n\ninterface Date {\n getVarDate: () => VarDate;\n}\n"}; }); +define([], function() { return { contents: "/*! *****************************************************************************\nCopyright (c) Microsoft Corporation. All rights reserved. \nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\nthis file except in compliance with the License. You may obtain a copy of the\nLicense at http://www.apache.org/licenses/LICENSE-2.0 \n \nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, \nMERCHANTABLITY OR NON-INFRINGEMENT. \n \nSee the Apache Version 2.0 License for specific language governing permissions\nand limitations under the License.\n***************************************************************************** */\n\n\n\n/// \n\n\n/////////////////////////////\n/// ECMAScript APIs\n/////////////////////////////\n\ndeclare const NaN: number;\ndeclare const Infinity: number;\n\n/**\n * Evaluates JavaScript code and executes it.\n * @param x A String value that contains valid JavaScript code.\n */\ndeclare function eval(x: string): any;\n\n/**\n * Converts A string to an integer.\n * @param s A string to convert into a number.\n * @param radix A value between 2 and 36 that specifies the base of the number in numString.\n * If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\n * All other strings are considered decimal.\n */\ndeclare function parseInt(s: string, radix?: number): number;\n\n/**\n * Converts a string to a floating-point number.\n * @param string A string that contains a floating-point number.\n */\ndeclare function parseFloat(string: string): number;\n\n/**\n * Returns a Boolean value that indicates whether a value is the reserved value NaN (not a number).\n * @param number A numeric value.\n */\ndeclare function isNaN(number: number): boolean;\n\n/**\n * Determines whether a supplied number is finite.\n * @param number Any numeric value.\n */\ndeclare function isFinite(number: number): boolean;\n\n/**\n * Gets the unencoded version of an encoded Uniform Resource Identifier (URI).\n * @param encodedURI A value representing an encoded URI.\n */\ndeclare function decodeURI(encodedURI: string): string;\n\n/**\n * Gets the unencoded version of an encoded component of a Uniform Resource Identifier (URI).\n * @param encodedURIComponent A value representing an encoded URI component.\n */\ndeclare function decodeURIComponent(encodedURIComponent: string): string;\n\n/**\n * Encodes a text string as a valid Uniform Resource Identifier (URI)\n * @param uri A value representing an encoded URI.\n */\ndeclare function encodeURI(uri: string): string;\n\n/**\n * Encodes a text string as a valid component of a Uniform Resource Identifier (URI).\n * @param uriComponent A value representing an encoded URI component.\n */\ndeclare function encodeURIComponent(uriComponent: string): string;\n\ninterface PropertyDescriptor {\n configurable?: boolean;\n enumerable?: boolean;\n value?: any;\n writable?: boolean;\n get?(): any;\n set?(v: any): void;\n}\n\ninterface PropertyDescriptorMap {\n [s: string]: PropertyDescriptor;\n}\n\ninterface Object {\n /** The initial value of Object.prototype.constructor is the standard built-in Object constructor. */\n constructor: Function;\n\n /** Returns a string representation of an object. */\n toString(): string;\n\n /** Returns a date converted to a string using the current locale. */\n toLocaleString(): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): Object;\n\n /**\n * Determines whether an object has a property with the specified name.\n * @param v A property name.\n */\n hasOwnProperty(v: string): boolean;\n\n /**\n * Determines whether an object exists in another object's prototype chain.\n * @param v Another object whose prototype chain is to be checked.\n */\n isPrototypeOf(v: Object): boolean;\n\n /**\n * Determines whether a specified property is enumerable.\n * @param v A property name.\n */\n propertyIsEnumerable(v: string): boolean;\n}\n\ninterface ObjectConstructor {\n new(value?: any): Object;\n (): any;\n (value: any): any;\n\n /** A reference to the prototype for a class of objects. */\n readonly prototype: Object;\n\n /**\n * Returns the prototype of an object.\n * @param o The object that references the prototype.\n */\n getPrototypeOf(o: any): any;\n\n /**\n * Gets the own property descriptor of the specified object.\n * An own property descriptor is one that is defined directly on the object and is not inherited from the object's prototype.\n * @param o Object that contains the property.\n * @param p Name of the property.\n */\n getOwnPropertyDescriptor(o: any, p: string): PropertyDescriptor;\n\n /**\n * Returns the names of the own properties of an object. The own properties of an object are those that are defined directly\n * on that object, and are not inherited from the object's prototype. The properties of an object include both fields (objects) and functions.\n * @param o Object that contains the own properties.\n */\n getOwnPropertyNames(o: any): string[];\n\n /**\n * Creates an object that has the specified prototype or that has null prototype.\n * @param o Object to use as a prototype. May be null.\n */\n create(o: object | null): any;\n\n /**\n * Creates an object that has the specified prototype, and that optionally contains specified properties.\n * @param o Object to use as a prototype. May be null\n * @param properties JavaScript object that contains one or more property descriptors.\n */\n create(o: object | null, properties: PropertyDescriptorMap & ThisType): any;\n\n /**\n * Adds a property to an object, or modifies attributes of an existing property.\n * @param o Object on which to add or modify the property. This can be a native JavaScript object (that is, a user-defined object or a built in object) or a DOM object.\n * @param p The property name.\n * @param attributes Descriptor for the property. It can be for a data property or an accessor property.\n */\n defineProperty(o: any, p: string, attributes: PropertyDescriptor & ThisType): any;\n\n /**\n * Adds one or more properties to an object, and/or modifies attributes of existing properties.\n * @param o Object on which to add or modify the properties. This can be a native JavaScript object or a DOM object.\n * @param properties JavaScript object that contains one or more descriptor objects. Each descriptor object describes a data property or an accessor property.\n */\n defineProperties(o: any, properties: PropertyDescriptorMap & ThisType): any;\n\n /**\n * Prevents the modification of attributes of existing properties, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n seal(o: T): T;\n\n /**\n * Prevents the modification of existing property attributes and values, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n freeze(a: T[]): ReadonlyArray;\n\n /**\n * Prevents the modification of existing property attributes and values, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n freeze(f: T): T;\n\n /**\n * Prevents the modification of existing property attributes and values, and prevents the addition of new properties.\n * @param o Object on which to lock the attributes.\n */\n freeze(o: T): Readonly;\n\n /**\n * Prevents the addition of new properties to an object.\n * @param o Object to make non-extensible.\n */\n preventExtensions(o: T): T;\n\n /**\n * Returns true if existing property attributes cannot be modified in an object and new properties cannot be added to the object.\n * @param o Object to test.\n */\n isSealed(o: any): boolean;\n\n /**\n * Returns true if existing property attributes and values cannot be modified in an object, and new properties cannot be added to the object.\n * @param o Object to test.\n */\n isFrozen(o: any): boolean;\n\n /**\n * Returns a value that indicates whether new properties can be added to an object.\n * @param o Object to test.\n */\n isExtensible(o: any): boolean;\n\n /**\n * Returns the names of the enumerable properties and methods of an object.\n * @param o Object that contains the properties and methods. This can be an object that you created or an existing Document Object Model (DOM) object.\n */\n keys(o: any): string[];\n}\n\n/**\n * Provides functionality common to all JavaScript objects.\n */\ndeclare const Object: ObjectConstructor;\n\n/**\n * Creates a new function.\n */\ninterface Function {\n /**\n * Calls the function, substituting the specified object for the this value of the function, and the specified array for the arguments of the function.\n * @param thisArg The object to be used as the this object.\n * @param argArray A set of arguments to be passed to the function.\n */\n apply(this: Function, thisArg: any, argArray?: any): any;\n\n /**\n * Calls a method of an object, substituting another object for the current object.\n * @param thisArg The object to be used as the current object.\n * @param argArray A list of arguments to be passed to the method.\n */\n call(this: Function, thisArg: any, ...argArray: any[]): any;\n\n /**\n * For a given function, creates a bound function that has the same body as the original function.\n * The this object of the bound function is associated with the specified object, and has the specified initial parameters.\n * @param thisArg An object to which the this keyword can refer inside the new function.\n * @param argArray A list of arguments to be passed to the new function.\n */\n bind(this: Function, thisArg: any, ...argArray: any[]): any;\n\n /** Returns a string representation of a function. */\n toString(): string;\n\n prototype: any;\n readonly length: number;\n\n // Non-standard extensions\n arguments: any;\n caller: Function;\n}\n\ninterface FunctionConstructor {\n /**\n * Creates a new function.\n * @param args A list of arguments the function accepts.\n */\n new(...args: string[]): Function;\n (...args: string[]): Function;\n readonly prototype: Function;\n}\n\ndeclare const Function: FunctionConstructor;\n\ninterface IArguments {\n [index: number]: any;\n length: number;\n callee: Function;\n}\n\ninterface String {\n /** Returns a string representation of a string. */\n toString(): string;\n\n /**\n * Returns the character at the specified index.\n * @param pos The zero-based index of the desired character.\n */\n charAt(pos: number): string;\n\n /**\n * Returns the Unicode value of the character at the specified location.\n * @param index The zero-based index of the desired character. If there is no character at the specified index, NaN is returned.\n */\n charCodeAt(index: number): number;\n\n /**\n * Returns a string that contains the concatenation of two or more strings.\n * @param strings The strings to append to the end of the string.\n */\n concat(...strings: string[]): string;\n\n /**\n * Returns the position of the first occurrence of a substring.\n * @param searchString The substring to search for in the string\n * @param position The index at which to begin searching the String object. If omitted, search starts at the beginning of the string.\n */\n indexOf(searchString: string, position?: number): number;\n\n /**\n * Returns the last occurrence of a substring in the string.\n * @param searchString The substring to search for.\n * @param position The index at which to begin searching. If omitted, the search begins at the end of the string.\n */\n lastIndexOf(searchString: string, position?: number): number;\n\n /**\n * Determines whether two strings are equivalent in the current locale.\n * @param that String to compare to target string\n */\n localeCompare(that: string): number;\n\n /**\n * Matches a string with a regular expression, and returns an array containing the results of that search.\n * @param regexp A variable name or string literal containing the regular expression pattern and flags.\n */\n match(regexp: string | RegExp): RegExpMatchArray | null;\n\n /**\n * Replaces text in a string, using a regular expression or search string.\n * @param searchValue A string to search for.\n * @param replaceValue A string containing the text to replace for every successful match of searchValue in this string.\n */\n replace(searchValue: string | RegExp, replaceValue: string): string;\n\n /**\n * Replaces text in a string, using a regular expression or search string.\n * @param searchValue A string to search for.\n * @param replacer A function that returns the replacement text.\n */\n replace(searchValue: string | RegExp, replacer: (substring: string, ...args: any[]) => string): string;\n\n /**\n * Finds the first substring match in a regular expression search.\n * @param regexp The regular expression pattern and applicable flags.\n */\n search(regexp: string | RegExp): number;\n\n /**\n * Returns a section of a string.\n * @param start The index to the beginning of the specified portion of stringObj.\n * @param end The index to the end of the specified portion of stringObj. The substring includes the characters up to, but not including, the character indicated by end.\n * If this value is not specified, the substring continues to the end of stringObj.\n */\n slice(start?: number, end?: number): string;\n\n /**\n * Split a string into substrings using the specified separator and return them as an array.\n * @param separator A string that identifies character or characters to use in separating the string. If omitted, a single-element array containing the entire string is returned.\n * @param limit A value used to limit the number of elements returned in the array.\n */\n split(separator: string | RegExp, limit?: number): string[];\n\n /**\n * Returns the substring at the specified location within a String object.\n * @param start The zero-based index number indicating the beginning of the substring.\n * @param end Zero-based index number indicating the end of the substring. The substring includes the characters up to, but not including, the character indicated by end.\n * If end is omitted, the characters from start through the end of the original string are returned.\n */\n substring(start: number, end?: number): string;\n\n /** Converts all the alphabetic characters in a string to lowercase. */\n toLowerCase(): string;\n\n /** Converts all alphabetic characters to lowercase, taking into account the host environment's current locale. */\n toLocaleLowerCase(): string;\n\n /** Converts all the alphabetic characters in a string to uppercase. */\n toUpperCase(): string;\n\n /** Returns a string where all alphabetic characters have been converted to uppercase, taking into account the host environment's current locale. */\n toLocaleUpperCase(): string;\n\n /** Removes the leading and trailing white space and line terminator characters from a string. */\n trim(): string;\n\n /** Returns the length of a String object. */\n readonly length: number;\n\n // IE extensions\n /**\n * Gets a substring beginning at the specified location and having the specified length.\n * @param from The starting position of the desired substring. The index of the first character in the string is zero.\n * @param length The number of characters to include in the returned substring.\n */\n substr(from: number, length?: number): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): string;\n\n readonly [index: number]: string;\n}\n\ninterface StringConstructor {\n new(value?: any): String;\n (value?: any): string;\n readonly prototype: String;\n fromCharCode(...codes: number[]): string;\n}\n\n/**\n * Allows manipulation and formatting of text strings and determination and location of substrings within strings.\n */\ndeclare const String: StringConstructor;\n\ninterface Boolean {\n /** Returns the primitive value of the specified object. */\n valueOf(): boolean;\n}\n\ninterface BooleanConstructor {\n new(value?: any): Boolean;\n (value?: any): boolean;\n readonly prototype: Boolean;\n}\n\ndeclare const Boolean: BooleanConstructor;\n\ninterface Number {\n /**\n * Returns a string representation of an object.\n * @param radix Specifies a radix for converting numeric values to strings. This value is only used for numbers.\n */\n toString(radix?: number): string;\n\n /**\n * Returns a string representing a number in fixed-point notation.\n * @param fractionDigits Number of digits after the decimal point. Must be in the range 0 - 20, inclusive.\n */\n toFixed(fractionDigits?: number): string;\n\n /**\n * Returns a string containing a number represented in exponential notation.\n * @param fractionDigits Number of digits after the decimal point. Must be in the range 0 - 20, inclusive.\n */\n toExponential(fractionDigits?: number): string;\n\n /**\n * Returns a string containing a number represented either in exponential or fixed-point notation with a specified number of digits.\n * @param precision Number of significant digits. Must be in the range 1 - 21, inclusive.\n */\n toPrecision(precision?: number): string;\n\n /** Returns the primitive value of the specified object. */\n valueOf(): number;\n}\n\ninterface NumberConstructor {\n new(value?: any): Number;\n (value?: any): number;\n readonly prototype: Number;\n\n /** The largest number that can be represented in JavaScript. Equal to approximately 1.79E+308. */\n readonly MAX_VALUE: number;\n\n /** The closest number to zero that can be represented in JavaScript. Equal to approximately 5.00E-324. */\n readonly MIN_VALUE: number;\n\n /**\n * A value that is not a number.\n * In equality comparisons, NaN does not equal any value, including itself. To test whether a value is equivalent to NaN, use the isNaN function.\n */\n readonly NaN: number;\n\n /**\n * A value that is less than the largest negative number that can be represented in JavaScript.\n * JavaScript displays NEGATIVE_INFINITY values as -infinity.\n */\n readonly NEGATIVE_INFINITY: number;\n\n /**\n * A value greater than the largest number that can be represented in JavaScript.\n * JavaScript displays POSITIVE_INFINITY values as infinity.\n */\n readonly POSITIVE_INFINITY: number;\n}\n\n/** An object that represents a number of any kind. All JavaScript numbers are 64-bit floating-point numbers. */\ndeclare const Number: NumberConstructor;\n\ninterface TemplateStringsArray extends ReadonlyArray {\n readonly raw: ReadonlyArray;\n}\n\ninterface Math {\n /** The mathematical constant e. This is Euler's number, the base of natural logarithms. */\n readonly E: number;\n /** The natural logarithm of 10. */\n readonly LN10: number;\n /** The natural logarithm of 2. */\n readonly LN2: number;\n /** The base-2 logarithm of e. */\n readonly LOG2E: number;\n /** The base-10 logarithm of e. */\n readonly LOG10E: number;\n /** Pi. This is the ratio of the circumference of a circle to its diameter. */\n readonly PI: number;\n /** The square root of 0.5, or, equivalently, one divided by the square root of 2. */\n readonly SQRT1_2: number;\n /** The square root of 2. */\n readonly SQRT2: number;\n /**\n * Returns the absolute value of a number (the value without regard to whether it is positive or negative).\n * For example, the absolute value of -5 is the same as the absolute value of 5.\n * @param x A numeric expression for which the absolute value is needed.\n */\n abs(x: number): number;\n /**\n * Returns the arc cosine (or inverse cosine) of a number.\n * @param x A numeric expression.\n */\n acos(x: number): number;\n /**\n * Returns the arcsine of a number.\n * @param x A numeric expression.\n */\n asin(x: number): number;\n /**\n * Returns the arctangent of a number.\n * @param x A numeric expression for which the arctangent is needed.\n */\n atan(x: number): number;\n /**\n * Returns the angle (in radians) from the X axis to a point.\n * @param y A numeric expression representing the cartesian y-coordinate.\n * @param x A numeric expression representing the cartesian x-coordinate.\n */\n atan2(y: number, x: number): number;\n /**\n * Returns the smallest number greater than or equal to its numeric argument.\n * @param x A numeric expression.\n */\n ceil(x: number): number;\n /**\n * Returns the cosine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n cos(x: number): number;\n /**\n * Returns e (the base of natural logarithms) raised to a power.\n * @param x A numeric expression representing the power of e.\n */\n exp(x: number): number;\n /**\n * Returns the greatest number less than or equal to its numeric argument.\n * @param x A numeric expression.\n */\n floor(x: number): number;\n /**\n * Returns the natural logarithm (base e) of a number.\n * @param x A numeric expression.\n */\n log(x: number): number;\n /**\n * Returns the larger of a set of supplied numeric expressions.\n * @param values Numeric expressions to be evaluated.\n */\n max(...values: number[]): number;\n /**\n * Returns the smaller of a set of supplied numeric expressions.\n * @param values Numeric expressions to be evaluated.\n */\n min(...values: number[]): number;\n /**\n * Returns the value of a base expression taken to a specified power.\n * @param x The base value of the expression.\n * @param y The exponent value of the expression.\n */\n pow(x: number, y: number): number;\n /** Returns a pseudorandom number between 0 and 1. */\n random(): number;\n /**\n * Returns a supplied numeric expression rounded to the nearest number.\n * @param x The value to be rounded to the nearest number.\n */\n round(x: number): number;\n /**\n * Returns the sine of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n sin(x: number): number;\n /**\n * Returns the square root of a number.\n * @param x A numeric expression.\n */\n sqrt(x: number): number;\n /**\n * Returns the tangent of a number.\n * @param x A numeric expression that contains an angle measured in radians.\n */\n tan(x: number): number;\n}\n/** An intrinsic object that provides basic mathematics functionality and constants. */\ndeclare const Math: Math;\n\n/** Enables basic storage and retrieval of dates and times. */\ninterface Date {\n /** Returns a string representation of a date. The format of the string depends on the locale. */\n toString(): string;\n /** Returns a date as a string value. */\n toDateString(): string;\n /** Returns a time as a string value. */\n toTimeString(): string;\n /** Returns a value as a string value appropriate to the host environment's current locale. */\n toLocaleString(): string;\n /** Returns a date as a string value appropriate to the host environment's current locale. */\n toLocaleDateString(): string;\n /** Returns a time as a string value appropriate to the host environment's current locale. */\n toLocaleTimeString(): string;\n /** Returns the stored time value in milliseconds since midnight, January 1, 1970 UTC. */\n valueOf(): number;\n /** Gets the time value in milliseconds. */\n getTime(): number;\n /** Gets the year, using local time. */\n getFullYear(): number;\n /** Gets the year using Universal Coordinated Time (UTC). */\n getUTCFullYear(): number;\n /** Gets the month, using local time. */\n getMonth(): number;\n /** Gets the month of a Date object using Universal Coordinated Time (UTC). */\n getUTCMonth(): number;\n /** Gets the day-of-the-month, using local time. */\n getDate(): number;\n /** Gets the day-of-the-month, using Universal Coordinated Time (UTC). */\n getUTCDate(): number;\n /** Gets the day of the week, using local time. */\n getDay(): number;\n /** Gets the day of the week using Universal Coordinated Time (UTC). */\n getUTCDay(): number;\n /** Gets the hours in a date, using local time. */\n getHours(): number;\n /** Gets the hours value in a Date object using Universal Coordinated Time (UTC). */\n getUTCHours(): number;\n /** Gets the minutes of a Date object, using local time. */\n getMinutes(): number;\n /** Gets the minutes of a Date object using Universal Coordinated Time (UTC). */\n getUTCMinutes(): number;\n /** Gets the seconds of a Date object, using local time. */\n getSeconds(): number;\n /** Gets the seconds of a Date object using Universal Coordinated Time (UTC). */\n getUTCSeconds(): number;\n /** Gets the milliseconds of a Date, using local time. */\n getMilliseconds(): number;\n /** Gets the milliseconds of a Date object using Universal Coordinated Time (UTC). */\n getUTCMilliseconds(): number;\n /** Gets the difference in minutes between the time on the local computer and Universal Coordinated Time (UTC). */\n getTimezoneOffset(): number;\n /**\n * Sets the date and time value in the Date object.\n * @param time A numeric value representing the number of elapsed milliseconds since midnight, January 1, 1970 GMT.\n */\n setTime(time: number): number;\n /**\n * Sets the milliseconds value in the Date object using local time.\n * @param ms A numeric value equal to the millisecond value.\n */\n setMilliseconds(ms: number): number;\n /**\n * Sets the milliseconds value in the Date object using Universal Coordinated Time (UTC).\n * @param ms A numeric value equal to the millisecond value.\n */\n setUTCMilliseconds(ms: number): number;\n\n /**\n * Sets the seconds value in the Date object using local time.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setSeconds(sec: number, ms?: number): number;\n /**\n * Sets the seconds value in the Date object using Universal Coordinated Time (UTC).\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setUTCSeconds(sec: number, ms?: number): number;\n /**\n * Sets the minutes value in the Date object using local time.\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setMinutes(min: number, sec?: number, ms?: number): number;\n /**\n * Sets the minutes value in the Date object using Universal Coordinated Time (UTC).\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setUTCMinutes(min: number, sec?: number, ms?: number): number;\n /**\n * Sets the hour value in the Date object using local time.\n * @param hours A numeric value equal to the hours value.\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setHours(hours: number, min?: number, sec?: number, ms?: number): number;\n /**\n * Sets the hours value in the Date object using Universal Coordinated Time (UTC).\n * @param hours A numeric value equal to the hours value.\n * @param min A numeric value equal to the minutes value.\n * @param sec A numeric value equal to the seconds value.\n * @param ms A numeric value equal to the milliseconds value.\n */\n setUTCHours(hours: number, min?: number, sec?: number, ms?: number): number;\n /**\n * Sets the numeric day-of-the-month value of the Date object using local time.\n * @param date A numeric value equal to the day of the month.\n */\n setDate(date: number): number;\n /**\n * Sets the numeric day of the month in the Date object using Universal Coordinated Time (UTC).\n * @param date A numeric value equal to the day of the month.\n */\n setUTCDate(date: number): number;\n /**\n * Sets the month value in the Date object using local time.\n * @param month A numeric value equal to the month. The value for January is 0, and other month values follow consecutively.\n * @param date A numeric value representing the day of the month. If this value is not supplied, the value from a call to the getDate method is used.\n */\n setMonth(month: number, date?: number): number;\n /**\n * Sets the month value in the Date object using Universal Coordinated Time (UTC).\n * @param month A numeric value equal to the month. The value for January is 0, and other month values follow consecutively.\n * @param date A numeric value representing the day of the month. If it is not supplied, the value from a call to the getUTCDate method is used.\n */\n setUTCMonth(month: number, date?: number): number;\n /**\n * Sets the year of the Date object using local time.\n * @param year A numeric value for the year.\n * @param month A zero-based numeric value for the month (0 for January, 11 for December). Must be specified if numDate is specified.\n * @param date A numeric value equal for the day of the month.\n */\n setFullYear(year: number, month?: number, date?: number): number;\n /**\n * Sets the year value in the Date object using Universal Coordinated Time (UTC).\n * @param year A numeric value equal to the year.\n * @param month A numeric value equal to the month. The value for January is 0, and other month values follow consecutively. Must be supplied if numDate is supplied.\n * @param date A numeric value equal to the day of the month.\n */\n setUTCFullYear(year: number, month?: number, date?: number): number;\n /** Returns a date converted to a string using Universal Coordinated Time (UTC). */\n toUTCString(): string;\n /** Returns a date as a string value in ISO format. */\n toISOString(): string;\n /** Used by the JSON.stringify method to enable the transformation of an object's data for JavaScript Object Notation (JSON) serialization. */\n toJSON(key?: any): string;\n}\n\ninterface DateConstructor {\n new(): Date;\n new(value: number): Date;\n new(value: string): Date;\n new(year: number, month: number, date?: number, hours?: number, minutes?: number, seconds?: number, ms?: number): Date;\n (): string;\n readonly prototype: Date;\n /**\n * Parses a string containing a date, and returns the number of milliseconds between that date and midnight, January 1, 1970.\n * @param s A date string\n */\n parse(s: string): number;\n /**\n * Returns the number of milliseconds between midnight, January 1, 1970 Universal Coordinated Time (UTC) (or GMT) and the specified date.\n * @param year The full year designation is required for cross-century date accuracy. If year is between 0 and 99 is used, then year is assumed to be 1900 + year.\n * @param month The month as an number between 0 and 11 (January to December).\n * @param date The date as an number between 1 and 31.\n * @param hours Must be supplied if minutes is supplied. An number from 0 to 23 (midnight to 11pm) that specifies the hour.\n * @param minutes Must be supplied if seconds is supplied. An number from 0 to 59 that specifies the minutes.\n * @param seconds Must be supplied if milliseconds is supplied. An number from 0 to 59 that specifies the seconds.\n * @param ms An number from 0 to 999 that specifies the milliseconds.\n */\n UTC(year: number, month: number, date?: number, hours?: number, minutes?: number, seconds?: number, ms?: number): number;\n now(): number;\n}\n\ndeclare const Date: DateConstructor;\n\ninterface RegExpMatchArray extends Array {\n index?: number;\n input?: string;\n}\n\ninterface RegExpExecArray extends Array {\n index: number;\n input: string;\n}\n\ninterface RegExp {\n /**\n * Executes a search on a string using a regular expression pattern, and returns an array containing the results of that search.\n * @param string The String object or string literal on which to perform the search.\n */\n exec(string: string): RegExpExecArray | null;\n\n /**\n * Returns a Boolean value that indicates whether or not a pattern exists in a searched string.\n * @param string String on which to perform the search.\n */\n test(string: string): boolean;\n\n /** Returns a copy of the text of the regular expression pattern. Read-only. The regExp argument is a Regular expression object. It can be a variable name or a literal. */\n readonly source: string;\n\n /** Returns a Boolean value indicating the state of the global flag (g) used with a regular expression. Default is false. Read-only. */\n readonly global: boolean;\n\n /** Returns a Boolean value indicating the state of the ignoreCase flag (i) used with a regular expression. Default is false. Read-only. */\n readonly ignoreCase: boolean;\n\n /** Returns a Boolean value indicating the state of the multiline flag (m) used with a regular expression. Default is false. Read-only. */\n readonly multiline: boolean;\n\n lastIndex: number;\n\n // Non-standard extensions\n compile(): this;\n}\n\ninterface RegExpConstructor {\n new(pattern: RegExp | string): RegExp;\n new(pattern: string, flags?: string): RegExp;\n (pattern: RegExp | string): RegExp;\n (pattern: string, flags?: string): RegExp;\n readonly prototype: RegExp;\n\n // Non-standard extensions\n $1: string;\n $2: string;\n $3: string;\n $4: string;\n $5: string;\n $6: string;\n $7: string;\n $8: string;\n $9: string;\n lastMatch: string;\n}\n\ndeclare const RegExp: RegExpConstructor;\n\ninterface Error {\n name: string;\n message: string;\n stack?: string;\n}\n\ninterface ErrorConstructor {\n new(message?: string): Error;\n (message?: string): Error;\n readonly prototype: Error;\n}\n\ndeclare const Error: ErrorConstructor;\n\ninterface EvalError extends Error {\n}\n\ninterface EvalErrorConstructor {\n new(message?: string): EvalError;\n (message?: string): EvalError;\n readonly prototype: EvalError;\n}\n\ndeclare const EvalError: EvalErrorConstructor;\n\ninterface RangeError extends Error {\n}\n\ninterface RangeErrorConstructor {\n new(message?: string): RangeError;\n (message?: string): RangeError;\n readonly prototype: RangeError;\n}\n\ndeclare const RangeError: RangeErrorConstructor;\n\ninterface ReferenceError extends Error {\n}\n\ninterface ReferenceErrorConstructor {\n new(message?: string): ReferenceError;\n (message?: string): ReferenceError;\n readonly prototype: ReferenceError;\n}\n\ndeclare const ReferenceError: ReferenceErrorConstructor;\n\ninterface SyntaxError extends Error {\n}\n\ninterface SyntaxErrorConstructor {\n new(message?: string): SyntaxError;\n (message?: string): SyntaxError;\n readonly prototype: SyntaxError;\n}\n\ndeclare const SyntaxError: SyntaxErrorConstructor;\n\ninterface TypeError extends Error {\n}\n\ninterface TypeErrorConstructor {\n new(message?: string): TypeError;\n (message?: string): TypeError;\n readonly prototype: TypeError;\n}\n\ndeclare const TypeError: TypeErrorConstructor;\n\ninterface URIError extends Error {\n}\n\ninterface URIErrorConstructor {\n new(message?: string): URIError;\n (message?: string): URIError;\n readonly prototype: URIError;\n}\n\ndeclare const URIError: URIErrorConstructor;\n\ninterface JSON {\n /**\n * Converts a JavaScript Object Notation (JSON) string into an object.\n * @param text A valid JSON string.\n * @param reviver A function that transforms the results. This function is called for each member of the object.\n * If a member contains nested objects, the nested objects are transformed before the parent object is.\n */\n parse(text: string, reviver?: (key: any, value: any) => any): any;\n /**\n * Converts a JavaScript value to a JavaScript Object Notation (JSON) string.\n * @param value A JavaScript value, usually an object or array, to be converted.\n * @param replacer A function that transforms the results.\n * @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.\n */\n stringify(value: any, replacer?: (key: string, value: any) => any, space?: string | number): string;\n /**\n * Converts a JavaScript value to a JavaScript Object Notation (JSON) string.\n * @param value A JavaScript value, usually an object or array, to be converted.\n * @param replacer An array of strings and numbers that acts as a approved list for selecting the object properties that will be stringified.\n * @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.\n */\n stringify(value: any, replacer?: (number | string)[] | null, space?: string | number): string;\n}\n\n/**\n * An intrinsic object that provides functions to convert JavaScript values to and from the JavaScript Object Notation (JSON) format.\n */\ndeclare const JSON: JSON;\n\n\n/////////////////////////////\n/// ECMAScript Array API (specially handled by compiler)\n/////////////////////////////\n\ninterface ReadonlyArray {\n /**\n * Gets the length of the array. This is a number one higher than the highest element defined in an array.\n */\n readonly length: number;\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n /**\n * Returns a string representation of an array. The elements are converted to string using thier toLocalString methods.\n */\n toLocaleString(): string;\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: T[][]): T[];\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: (T | T[])[]): T[];\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): T[];\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.\n */\n indexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Returns the index of the last occurrence of a specified value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at the last index in the array.\n */\n lastIndexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls the callbackfn function for each element in array1 until the callbackfn returns false, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: T, index: number, array: ReadonlyArray) => boolean, thisArg?: any): boolean;\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the callbackfn function for each element in array1 until the callbackfn returns true, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: T, index: number, array: ReadonlyArray) => boolean, thisArg?: any): boolean;\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: T, index: number, array: ReadonlyArray) => void, thisArg?: any): void;\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (value: T, index: number, array: ReadonlyArray) => U, thisArg?: any): U[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: T, index: number, array: ReadonlyArray) => value is S, thisArg?: any): S[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: T, index: number, array: ReadonlyArray) => any, thisArg?: any): T[];\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: ReadonlyArray) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: ReadonlyArray) => U, initialValue: U): U;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: ReadonlyArray) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: ReadonlyArray) => U, initialValue: U): U;\n\n readonly [n: number]: T;\n}\n\ninterface Array {\n /**\n * Gets or sets the length of the array. This is a number one higher than the highest element defined in an array.\n */\n length: number;\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n /**\n * Returns a string representation of an array. The elements are converted to string using thier toLocalString methods.\n */\n toLocaleString(): string;\n /**\n * Appends new elements to an array, and returns the new length of the array.\n * @param items New elements of the Array.\n */\n push(...items: T[]): number;\n /**\n * Removes the last element from an array and returns it.\n */\n pop(): T | undefined;\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: T[][]): T[];\n /**\n * Combines two or more arrays.\n * @param items Additional items to add to the end of array1.\n */\n concat(...items: (T | T[])[]): T[];\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n /**\n * Reverses the elements in an Array.\n */\n reverse(): T[];\n /**\n * Removes the first element from an array and returns it.\n */\n shift(): T | undefined;\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): T[];\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: T, b: T) => number): this;\n /**\n * Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.\n * @param start The zero-based location in the array from which to start removing elements.\n * @param deleteCount The number of elements to remove.\n */\n splice(start: number, deleteCount?: number): T[];\n /**\n * Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.\n * @param start The zero-based location in the array from which to start removing elements.\n * @param deleteCount The number of elements to remove.\n * @param items Elements to insert into the array in place of the deleted elements.\n */\n splice(start: number, deleteCount: number, ...items: T[]): T[];\n /**\n * Inserts new elements at the start of an array.\n * @param items Elements to insert at the start of the Array.\n */\n unshift(...items: T[]): number;\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.\n */\n indexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Returns the index of the last occurrence of a specified value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at the last index in the array.\n */\n lastIndexOf(searchElement: T, fromIndex?: number): number;\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls the callbackfn function for each element in array1 until the callbackfn returns false, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: T, index: number, array: T[]) => boolean, thisArg?: any): boolean;\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the callbackfn function for each element in array1 until the callbackfn returns true, or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: T, index: number, array: T[]) => boolean, thisArg?: any): boolean;\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: T, index: number, array: T[]) => void, thisArg?: any): void;\n /**\n * Calls a defined callback function on each element of an array, and returns an array that contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (value: T, index: number, array: T[]) => U, thisArg?: any): U[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: T, index: number, array: T[]) => value is S, thisArg?: any): S[];\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: T, index: number, array: T[]) => any, thisArg?: any): T[];\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: T[]) => U, initialValue: U): U;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue?: T): T;\n /**\n * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: T, currentIndex: number, array: T[]) => U, initialValue: U): U;\n\n [n: number]: T;\n}\n\ninterface ArrayConstructor {\n new(arrayLength?: number): any[];\n new (arrayLength: number): T[];\n new (...items: T[]): T[];\n (arrayLength?: number): any[];\n (arrayLength: number): T[];\n (...items: T[]): T[];\n isArray(arg: any): arg is Array;\n readonly prototype: Array;\n}\n\ndeclare const Array: ArrayConstructor;\n\ninterface TypedPropertyDescriptor {\n enumerable?: boolean;\n configurable?: boolean;\n writable?: boolean;\n value?: T;\n get?: () => T;\n set?: (value: T) => void;\n}\n\ndeclare type ClassDecorator = (target: TFunction) => TFunction | void;\ndeclare type PropertyDecorator = (target: Object, propertyKey: string | symbol) => void;\ndeclare type MethodDecorator = (target: Object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor) => TypedPropertyDescriptor | void;\ndeclare type ParameterDecorator = (target: Object, propertyKey: string | symbol, parameterIndex: number) => void;\n\ndeclare type PromiseConstructorLike = new (executor: (resolve: (value?: T | PromiseLike) => void, reject: (reason?: any) => void) => void) => PromiseLike;\n\ninterface PromiseLike {\n /**\n * Attaches callbacks for the resolution and/or rejection of the Promise.\n * @param onfulfilled The callback to execute when the Promise is resolved.\n * @param onrejected The callback to execute when the Promise is rejected.\n * @returns A Promise for the completion of which ever callback is executed.\n */\n then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): PromiseLike;\n}\n\n/**\n * Represents the completion of an asynchronous operation\n */\ninterface Promise {\n /**\n * Attaches callbacks for the resolution and/or rejection of the Promise.\n * @param onfulfilled The callback to execute when the Promise is resolved.\n * @param onrejected The callback to execute when the Promise is rejected.\n * @returns A Promise for the completion of which ever callback is executed.\n */\n then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): Promise;\n\n /**\n * Attaches a callback for only the rejection of the Promise.\n * @param onrejected The callback to execute when the Promise is rejected.\n * @returns A Promise for the completion of the callback.\n */\n catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): Promise;\n}\n\ninterface ArrayLike {\n readonly length: number;\n readonly [n: number]: T;\n}\n\n/**\n * Make all properties in T optional\n */\ntype Partial = {\n [P in keyof T]?: T[P];\n};\n\n/**\n * Make all properties in T readonly\n */\ntype Readonly = {\n readonly [P in keyof T]: T[P];\n};\n\n/**\n * From T pick a set of properties K\n */\ntype Pick = {\n [P in K]: T[P];\n};\n\n/**\n * Construct a type with a set of properties K of type T\n */\ntype Record = {\n [P in K]: T;\n};\n\n/**\n * Marker for contextual 'this' type\n */\ninterface ThisType { }\n\n/**\n * Represents a raw buffer of binary data, which is used to store data for the\n * different typed arrays. ArrayBuffers cannot be read from or written to directly,\n * but can be passed to a typed array or DataView Object to interpret the raw\n * buffer as needed.\n */\ninterface ArrayBuffer {\n /**\n * Read-only. The length of the ArrayBuffer (in bytes).\n */\n readonly byteLength: number;\n\n /**\n * Returns a section of an ArrayBuffer.\n */\n slice(begin: number, end?: number): ArrayBuffer;\n}\n\n/**\n * Allowed ArrayBuffer types for the buffer of an ArrayBufferView and related Typed Arrays.\n */\ninterface ArrayBufferTypes {\n ArrayBuffer: ArrayBuffer;\n}\ntype ArrayBufferLike = ArrayBufferTypes[keyof ArrayBufferTypes];\n\ninterface ArrayBufferConstructor {\n readonly prototype: ArrayBuffer;\n new(byteLength: number): ArrayBuffer;\n isView(arg: any): arg is ArrayBufferView;\n}\ndeclare const ArrayBuffer: ArrayBufferConstructor;\n\ninterface ArrayBufferView {\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n byteOffset: number;\n}\n\ninterface DataView {\n readonly buffer: ArrayBuffer;\n readonly byteLength: number;\n readonly byteOffset: number;\n /**\n * Gets the Float32 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getFloat32(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Float64 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getFloat64(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Int8 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getInt8(byteOffset: number): number;\n\n /**\n * Gets the Int16 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getInt16(byteOffset: number, littleEndian?: boolean): number;\n /**\n * Gets the Int32 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getInt32(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Uint8 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getUint8(byteOffset: number): number;\n\n /**\n * Gets the Uint16 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getUint16(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Gets the Uint32 value at the specified byte offset from the start of the view. There is\n * no alignment constraint; multi-byte values may be fetched from any offset.\n * @param byteOffset The place in the buffer at which the value should be retrieved.\n */\n getUint32(byteOffset: number, littleEndian?: boolean): number;\n\n /**\n * Stores an Float32 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setFloat32(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Float64 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setFloat64(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Int8 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n */\n setInt8(byteOffset: number, value: number): void;\n\n /**\n * Stores an Int16 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setInt16(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Int32 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setInt32(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Uint8 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n */\n setUint8(byteOffset: number, value: number): void;\n\n /**\n * Stores an Uint16 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setUint16(byteOffset: number, value: number, littleEndian?: boolean): void;\n\n /**\n * Stores an Uint32 value at the specified byte offset from the start of the view.\n * @param byteOffset The place in the buffer at which the value should be set.\n * @param value The value to set.\n * @param littleEndian If false or undefined, a big-endian value should be written,\n * otherwise a little-endian value should be written.\n */\n setUint32(byteOffset: number, value: number, littleEndian?: boolean): void;\n}\n\ninterface DataViewConstructor {\n new(buffer: ArrayBufferLike, byteOffset?: number, byteLength?: number): DataView;\n}\ndeclare const DataView: DataViewConstructor;\n\n/**\n * A typed array of 8-bit integer values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Int8Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Int8Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Int8Array) => any, thisArg?: any): Int8Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Int8Array) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Int8Array) => number, thisArg?: any): Int8Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int8Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int8Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Int8Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Int8Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Int8Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Int8Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Int8Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\ninterface Int8ArrayConstructor {\n readonly prototype: Int8Array;\n new(length: number): Int8Array;\n new(array: ArrayLike): Int8Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Int8Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Int8Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Int8Array;\n\n\n}\ndeclare const Int8Array: Int8ArrayConstructor;\n\n/**\n * A typed array of 8-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Uint8Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Uint8Array) => any, thisArg?: any): Uint8Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Uint8Array) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint8Array) => number, thisArg?: any): Uint8Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint8Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint8Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Uint8Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint8Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint8Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint8ArrayConstructor {\n readonly prototype: Uint8Array;\n new(length: number): Uint8Array;\n new(array: ArrayLike): Uint8Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Uint8Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint8Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Uint8Array;\n\n}\ndeclare const Uint8Array: Uint8ArrayConstructor;\n\n/**\n * A typed array of 8-bit unsigned integer (clamped) values. The contents are initialized to 0.\n * If the requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint8ClampedArray {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Uint8ClampedArray) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Uint8ClampedArray) => any, thisArg?: any): Uint8ClampedArray;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Uint8ClampedArray) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint8ClampedArray) => number, thisArg?: any): Uint8ClampedArray;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint8ClampedArray) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint8ClampedArray;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint8ClampedArray;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Uint8ClampedArray) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint8ClampedArray view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint8ClampedArray;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint8ClampedArrayConstructor {\n readonly prototype: Uint8ClampedArray;\n new(length: number): Uint8ClampedArray;\n new(array: ArrayLike): Uint8ClampedArray;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Uint8ClampedArray;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint8ClampedArray;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Uint8ClampedArray;\n}\ndeclare const Uint8ClampedArray: Uint8ClampedArrayConstructor;\n\n/**\n * A typed array of 16-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int16Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Int16Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (this: void, value: number, index: number, array: Int16Array) => any, thisArg?: any): Int16Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Int16Array) => void, thisArg?: any): void;\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Int16Array) => number, thisArg?: any): Int16Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int16Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int16Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Int16Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Int16Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Int16Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Int16Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Int16Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Int16ArrayConstructor {\n readonly prototype: Int16Array;\n new(length: number): Int16Array;\n new(array: ArrayLike): Int16Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Int16Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Int16Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Int16Array;\n\n\n}\ndeclare const Int16Array: Int16ArrayConstructor;\n\n/**\n * A typed array of 16-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint16Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Uint16Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Uint16Array) => any, thisArg?: any): Uint16Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Uint16Array) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint16Array) => number, thisArg?: any): Uint16Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint16Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint16Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint16Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint16Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint16Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Uint16Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint16Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint16Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint16ArrayConstructor {\n readonly prototype: Uint16Array;\n new(length: number): Uint16Array;\n new(array: ArrayLike): Uint16Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Uint16Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint16Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Uint16Array;\n\n\n}\ndeclare const Uint16Array: Uint16ArrayConstructor;\n/**\n * A typed array of 32-bit signed integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Int32Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Int32Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Int32Array) => any, thisArg?: any): Int32Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Int32Array) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (value: number, index: number, array: Int32Array) => number, thisArg?: any): Int32Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int32Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Int32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Int32Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Int32Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Int32Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Int32Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Int32Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Int32Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Int32ArrayConstructor {\n readonly prototype: Int32Array;\n new(length: number): Int32Array;\n new(array: ArrayLike): Int32Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Int32Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Int32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Int32Array;\n\n}\ndeclare const Int32Array: Int32ArrayConstructor;\n\n/**\n * A typed array of 32-bit unsigned integer values. The contents are initialized to 0. If the\n * requested number of bytes could not be allocated an exception is raised.\n */\ninterface Uint32Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Uint32Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Uint32Array) => any, thisArg?: any): Uint32Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Uint32Array) => void, thisArg?: any): void;\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Uint32Array) => number, thisArg?: any): Uint32Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint32Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Uint32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Uint32Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Uint32Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Uint32Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Uint32Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Uint32Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Uint32Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Uint32ArrayConstructor {\n readonly prototype: Uint32Array;\n new(length: number): Uint32Array;\n new(array: ArrayLike): Uint32Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Uint32Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Uint32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Uint32Array;\n\n}\ndeclare const Uint32Array: Uint32ArrayConstructor;\n\n/**\n * A typed array of 32-bit float values. The contents are initialized to 0. If the requested number\n * of bytes could not be allocated an exception is raised.\n */\ninterface Float32Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Float32Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Float32Array) => any, thisArg?: any): Float32Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Float32Array) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Float32Array) => number, thisArg?: any): Float32Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float32Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float32Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float32Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Float32Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Float32Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Float32Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Float32Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Float32Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Float32ArrayConstructor {\n readonly prototype: Float32Array;\n new(length: number): Float32Array;\n new(array: ArrayLike): Float32Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Float32Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Float32Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Float32Array;\n\n\n}\ndeclare const Float32Array: Float32ArrayConstructor;\n\n/**\n * A typed array of 64-bit float values. The contents are initialized to 0. If the requested\n * number of bytes could not be allocated an exception is raised.\n */\ninterface Float64Array {\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * The ArrayBuffer instance referenced by the array.\n */\n readonly buffer: ArrayBufferLike;\n\n /**\n * The length in bytes of the array.\n */\n readonly byteLength: number;\n\n /**\n * The offset in bytes of the array.\n */\n readonly byteOffset: number;\n\n /**\n * Returns the this object after copying a section of the array identified by start and end\n * to the same array starting at position target\n * @param target If target is negative, it is treated as length+target where length is the\n * length of the array.\n * @param start If start is negative, it is treated as length+start. If end is negative, it\n * is treated as length+end.\n * @param end If not specified, length of the this object is used as its default value.\n */\n copyWithin(target: number, start: number, end?: number): this;\n\n /**\n * Determines whether all the members of an array satisfy the specified test.\n * @param callbackfn A function that accepts up to three arguments. The every method calls\n * the callbackfn function for each element in array1 until the callbackfn returns false,\n * or until the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n every(callbackfn: (value: number, index: number, array: Float64Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Returns the this object after filling the section identified by start and end with value\n * @param value value to fill array section with\n * @param start index to start filling the array at. If start is negative, it is treated as\n * length+start where length is the length of the array.\n * @param end index to stop filling the array at. If end is negative, it is treated as\n * length+end.\n */\n fill(value: number, start?: number, end?: number): this;\n\n /**\n * Returns the elements of an array that meet the condition specified in a callback function.\n * @param callbackfn A function that accepts up to three arguments. The filter method calls\n * the callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n filter(callbackfn: (value: number, index: number, array: Float64Array) => any, thisArg?: any): Float64Array;\n\n /**\n * Returns the value of the first element in the array where predicate is true, and undefined\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found, find\n * immediately returns that element value. Otherwise, find returns undefined.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n find(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number | undefined;\n\n /**\n * Returns the index of the first element in the array where predicate is true, and -1\n * otherwise.\n * @param predicate find calls predicate once for each element of the array, in ascending\n * order, until it finds one where predicate returns true. If such an element is found,\n * findIndex immediately returns that element index. Otherwise, findIndex returns -1.\n * @param thisArg If provided, it will be used as the this value for each invocation of\n * predicate. If it is not provided, undefined is used instead.\n */\n findIndex(predicate: (value: number, index: number, obj: Array) => boolean, thisArg?: any): number;\n\n /**\n * Performs the specified action for each element in an array.\n * @param callbackfn A function that accepts up to three arguments. forEach calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n forEach(callbackfn: (value: number, index: number, array: Float64Array) => void, thisArg?: any): void;\n\n /**\n * Returns the index of the first occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n indexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * Adds all the elements of an array separated by the specified separator string.\n * @param separator A string used to separate one element of an array from the next in the\n * resulting String. If omitted, the array elements are separated with a comma.\n */\n join(separator?: string): string;\n\n /**\n * Returns the index of the last occurrence of a value in an array.\n * @param searchElement The value to locate in the array.\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the\n * search starts at index 0.\n */\n lastIndexOf(searchElement: number, fromIndex?: number): number;\n\n /**\n * The length of the array.\n */\n readonly length: number;\n\n /**\n * Calls a defined callback function on each element of an array, and returns an array that\n * contains the results.\n * @param callbackfn A function that accepts up to three arguments. The map method calls the\n * callbackfn function one time for each element in the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n map(callbackfn: (this: void, value: number, index: number, array: Float64Array) => number, thisArg?: any): Float64Array;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float64Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array. The return value of\n * the callback function is the accumulated result, and is provided as an argument in the next\n * call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduce method calls the\n * callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduce(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float64Array) => U, initialValue: U): U;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an\n * argument instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: Float64Array) => number, initialValue?: number): number;\n\n /**\n * Calls the specified callback function for all the elements in an array, in descending order.\n * The return value of the callback function is the accumulated result, and is provided as an\n * argument in the next call to the callback function.\n * @param callbackfn A function that accepts up to four arguments. The reduceRight method calls\n * the callbackfn function one time for each element in the array.\n * @param initialValue If initialValue is specified, it is used as the initial value to start\n * the accumulation. The first call to the callbackfn function provides this value as an argument\n * instead of an array value.\n */\n reduceRight(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: Float64Array) => U, initialValue: U): U;\n\n /**\n * Reverses the elements in an Array.\n */\n reverse(): Float64Array;\n\n /**\n * Sets a value or an array of values.\n * @param array A typed or untyped array of values to set.\n * @param offset The index in the current array at which the values are to be written.\n */\n set(array: ArrayLike, offset?: number): void;\n\n /**\n * Returns a section of an array.\n * @param start The beginning of the specified portion of the array.\n * @param end The end of the specified portion of the array.\n */\n slice(start?: number, end?: number): Float64Array;\n\n /**\n * Determines whether the specified callback function returns true for any element of an array.\n * @param callbackfn A function that accepts up to three arguments. The some method calls the\n * callbackfn function for each element in array1 until the callbackfn returns true, or until\n * the end of the array.\n * @param thisArg An object to which the this keyword can refer in the callbackfn function.\n * If thisArg is omitted, undefined is used as the this value.\n */\n some(callbackfn: (value: number, index: number, array: Float64Array) => boolean, thisArg?: any): boolean;\n\n /**\n * Sorts an array.\n * @param compareFn The name of the function used to determine the order of the elements. If\n * omitted, the elements are sorted in ascending, ASCII character order.\n */\n sort(compareFn?: (a: number, b: number) => number): this;\n\n /**\n * Gets a new Float64Array view of the ArrayBuffer store for this array, referencing the elements\n * at begin, inclusive, up to end, exclusive.\n * @param begin The index of the beginning of the array.\n * @param end The index of the end of the array.\n */\n subarray(begin: number, end?: number): Float64Array;\n\n /**\n * Converts a number to a string by using the current locale.\n */\n toLocaleString(): string;\n\n /**\n * Returns a string representation of an array.\n */\n toString(): string;\n\n [index: number]: number;\n}\n\ninterface Float64ArrayConstructor {\n readonly prototype: Float64Array;\n new(length: number): Float64Array;\n new(array: ArrayLike): Float64Array;\n new(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Float64Array;\n\n /**\n * The size in bytes of each element in the array.\n */\n readonly BYTES_PER_ELEMENT: number;\n\n /**\n * Returns a new array from a set of elements.\n * @param items A set of elements to include in the new array object.\n */\n of(...items: number[]): Float64Array;\n\n /**\n * Creates an array from an array-like or iterable object.\n * @param arrayLike An array-like or iterable object to convert to an array.\n * @param mapfn A mapping function to call on every element of the array.\n * @param thisArg Value of 'this' used to invoke the mapfn.\n */\n from(arrayLike: ArrayLike, mapfn?: (v: number, k: number) => number, thisArg?: any): Float64Array;\n\n}\ndeclare const Float64Array: Float64ArrayConstructor;\n\n/////////////////////////////\n/// ECMAScript Internationalization API\n/////////////////////////////\n\ndeclare namespace Intl {\n interface CollatorOptions {\n usage?: string;\n localeMatcher?: string;\n numeric?: boolean;\n caseFirst?: string;\n sensitivity?: string;\n ignorePunctuation?: boolean;\n }\n\n interface ResolvedCollatorOptions {\n locale: string;\n usage: string;\n sensitivity: string;\n ignorePunctuation: boolean;\n collation: string;\n caseFirst: string;\n numeric: boolean;\n }\n\n interface Collator {\n compare(x: string, y: string): number;\n resolvedOptions(): ResolvedCollatorOptions;\n }\n var Collator: {\n new(locales?: string | string[], options?: CollatorOptions): Collator;\n (locales?: string | string[], options?: CollatorOptions): Collator;\n supportedLocalesOf(locales: string | string[], options?: CollatorOptions): string[];\n };\n\n interface NumberFormatOptions {\n localeMatcher?: string;\n style?: string;\n currency?: string;\n currencyDisplay?: string;\n useGrouping?: boolean;\n minimumIntegerDigits?: number;\n minimumFractionDigits?: number;\n maximumFractionDigits?: number;\n minimumSignificantDigits?: number;\n maximumSignificantDigits?: number;\n }\n\n interface ResolvedNumberFormatOptions {\n locale: string;\n numberingSystem: string;\n style: string;\n currency?: string;\n currencyDisplay?: string;\n minimumIntegerDigits: number;\n minimumFractionDigits: number;\n maximumFractionDigits: number;\n minimumSignificantDigits?: number;\n maximumSignificantDigits?: number;\n useGrouping: boolean;\n }\n\n interface NumberFormat {\n format(value: number): string;\n resolvedOptions(): ResolvedNumberFormatOptions;\n }\n var NumberFormat: {\n new(locales?: string | string[], options?: NumberFormatOptions): NumberFormat;\n (locales?: string | string[], options?: NumberFormatOptions): NumberFormat;\n supportedLocalesOf(locales: string | string[], options?: NumberFormatOptions): string[];\n };\n\n interface DateTimeFormatOptions {\n localeMatcher?: string;\n weekday?: string;\n era?: string;\n year?: string;\n month?: string;\n day?: string;\n hour?: string;\n minute?: string;\n second?: string;\n timeZoneName?: string;\n formatMatcher?: string;\n hour12?: boolean;\n timeZone?: string;\n }\n\n interface ResolvedDateTimeFormatOptions {\n locale: string;\n calendar: string;\n numberingSystem: string;\n timeZone: string;\n hour12?: boolean;\n weekday?: string;\n era?: string;\n year?: string;\n month?: string;\n day?: string;\n hour?: string;\n minute?: string;\n second?: string;\n timeZoneName?: string;\n }\n\n interface DateTimeFormat {\n format(date?: Date | number): string;\n resolvedOptions(): ResolvedDateTimeFormatOptions;\n }\n var DateTimeFormat: {\n new(locales?: string | string[], options?: DateTimeFormatOptions): DateTimeFormat;\n (locales?: string | string[], options?: DateTimeFormatOptions): DateTimeFormat;\n supportedLocalesOf(locales: string | string[], options?: DateTimeFormatOptions): string[];\n };\n}\n\ninterface String {\n /**\n * Determines whether two strings are equivalent in the current or specified locale.\n * @param that String to compare to target string\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used. This parameter must conform to BCP 47 standards; see the Intl.Collator object for details.\n * @param options An object that contains one or more properties that specify comparison options. see the Intl.Collator object for details.\n */\n localeCompare(that: string, locales?: string | string[], options?: Intl.CollatorOptions): number;\n}\n\ninterface Number {\n /**\n * Converts a number to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleString(locales?: string | string[], options?: Intl.NumberFormatOptions): string;\n}\n\ninterface Date {\n /**\n * Converts a date and time to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleString(locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;\n /**\n * Converts a date to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleDateString(locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;\n\n /**\n * Converts a time to a string by using the current or specified locale.\n * @param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used.\n * @param options An object that contains one or more properties that specify comparison options.\n */\n toLocaleTimeString(locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;\n}\n\n\n\n/////////////////////////////\n/// DOM APIs\n/////////////////////////////\n\ninterface Account {\n displayName?: string;\n id?: string;\n imageURL?: string;\n name?: string;\n rpDisplayName?: string;\n}\n\ninterface Algorithm {\n name: string;\n}\n\ninterface AnimationEventInit extends EventInit {\n animationName?: string;\n elapsedTime?: number;\n}\n\ninterface AssertionOptions {\n allowList?: ScopedCredentialDescriptor[];\n extensions?: WebAuthnExtensions;\n rpId?: USVString;\n timeoutSeconds?: number;\n}\n\ninterface CacheQueryOptions {\n cacheName?: string;\n ignoreMethod?: boolean;\n ignoreSearch?: boolean;\n ignoreVary?: boolean;\n}\n\ninterface ClientData {\n challenge?: string;\n extensions?: WebAuthnExtensions;\n hashAlg?: string | Algorithm;\n origin?: string;\n rpId?: string;\n tokenBinding?: string;\n}\n\ninterface CloseEventInit extends EventInit {\n code?: number;\n reason?: string;\n wasClean?: boolean;\n}\n\ninterface CompositionEventInit extends UIEventInit {\n data?: string;\n}\n\ninterface ConfirmSiteSpecificExceptionsInformation extends ExceptionInformation {\n arrayOfDomainStrings?: string[];\n}\n\ninterface ConstrainBooleanParameters {\n exact?: boolean;\n ideal?: boolean;\n}\n\ninterface ConstrainDOMStringParameters {\n exact?: string | string[];\n ideal?: string | string[];\n}\n\ninterface ConstrainDoubleRange extends DoubleRange {\n exact?: number;\n ideal?: number;\n}\n\ninterface ConstrainLongRange extends LongRange {\n exact?: number;\n ideal?: number;\n}\n\ninterface ConstrainVideoFacingModeParameters {\n exact?: VideoFacingModeEnum | VideoFacingModeEnum[];\n ideal?: VideoFacingModeEnum | VideoFacingModeEnum[];\n}\n\ninterface CustomEventInit extends EventInit {\n detail?: any;\n}\n\ninterface DeviceAccelerationDict {\n x?: number;\n y?: number;\n z?: number;\n}\n\ninterface DeviceLightEventInit extends EventInit {\n value?: number;\n}\n\ninterface DeviceMotionEventInit extends EventInit {\n acceleration?: DeviceAccelerationDict;\n accelerationIncludingGravity?: DeviceAccelerationDict;\n interval?: number;\n rotationRate?: DeviceRotationRateDict;\n}\n\ninterface DeviceOrientationEventInit extends EventInit {\n absolute?: boolean;\n alpha?: number;\n beta?: number;\n gamma?: number;\n}\n\ninterface DeviceRotationRateDict {\n alpha?: number;\n beta?: number;\n gamma?: number;\n}\n\ninterface DOMRectInit {\n height?: any;\n width?: any;\n x?: any;\n y?: any;\n}\n\ninterface DoubleRange {\n max?: number;\n min?: number;\n}\n\ninterface ErrorEventInit extends EventInit {\n colno?: number;\n error?: any;\n filename?: string;\n lineno?: number;\n message?: string;\n}\n\ninterface EventInit {\n scoped?: boolean;\n bubbles?: boolean;\n cancelable?: boolean;\n}\n\ninterface EventModifierInit extends UIEventInit {\n altKey?: boolean;\n ctrlKey?: boolean;\n metaKey?: boolean;\n modifierAltGraph?: boolean;\n modifierCapsLock?: boolean;\n modifierFn?: boolean;\n modifierFnLock?: boolean;\n modifierHyper?: boolean;\n modifierNumLock?: boolean;\n modifierOS?: boolean;\n modifierScrollLock?: boolean;\n modifierSuper?: boolean;\n modifierSymbol?: boolean;\n modifierSymbolLock?: boolean;\n shiftKey?: boolean;\n}\n\ninterface ExceptionInformation {\n domain?: string;\n}\n\ninterface FocusEventInit extends UIEventInit {\n relatedTarget?: EventTarget;\n}\n\ninterface FocusNavigationEventInit extends EventInit {\n navigationReason?: string;\n originHeight?: number;\n originLeft?: number;\n originTop?: number;\n originWidth?: number;\n}\n\ninterface FocusNavigationOrigin {\n originHeight?: number;\n originLeft?: number;\n originTop?: number;\n originWidth?: number;\n}\n\ninterface GamepadEventInit extends EventInit {\n gamepad?: Gamepad;\n}\n\ninterface GetNotificationOptions {\n tag?: string;\n}\n\ninterface HashChangeEventInit extends EventInit {\n newURL?: string;\n oldURL?: string;\n}\n\ninterface IDBIndexParameters {\n multiEntry?: boolean;\n unique?: boolean;\n}\n\ninterface IDBObjectStoreParameters {\n autoIncrement?: boolean;\n keyPath?: IDBKeyPath;\n}\n\ninterface IntersectionObserverEntryInit {\n boundingClientRect?: DOMRectInit;\n intersectionRect?: DOMRectInit;\n rootBounds?: DOMRectInit;\n target?: Element;\n time?: number;\n}\n\ninterface IntersectionObserverInit {\n root?: Element;\n rootMargin?: string;\n threshold?: number | number[];\n}\n\ninterface KeyAlgorithm {\n name?: string;\n}\n\ninterface KeyboardEventInit extends EventModifierInit {\n code?: string;\n key?: string;\n location?: number;\n repeat?: boolean;\n}\n\ninterface LongRange {\n max?: number;\n min?: number;\n}\n\ninterface MediaEncryptedEventInit extends EventInit {\n initData?: ArrayBuffer;\n initDataType?: string;\n}\n\ninterface MediaKeyMessageEventInit extends EventInit {\n message?: ArrayBuffer;\n messageType?: MediaKeyMessageType;\n}\n\ninterface MediaKeySystemConfiguration {\n audioCapabilities?: MediaKeySystemMediaCapability[];\n distinctiveIdentifier?: MediaKeysRequirement;\n initDataTypes?: string[];\n persistentState?: MediaKeysRequirement;\n videoCapabilities?: MediaKeySystemMediaCapability[];\n}\n\ninterface MediaKeySystemMediaCapability {\n contentType?: string;\n robustness?: string;\n}\n\ninterface MediaStreamConstraints {\n audio?: boolean | MediaTrackConstraints;\n video?: boolean | MediaTrackConstraints;\n}\n\ninterface MediaStreamErrorEventInit extends EventInit {\n error?: MediaStreamError;\n}\n\ninterface MediaStreamEventInit extends EventInit {\n stream?: MediaStream;\n}\n\ninterface MediaStreamTrackEventInit extends EventInit {\n track?: MediaStreamTrack;\n}\n\ninterface MediaTrackCapabilities {\n aspectRatio?: number | DoubleRange;\n deviceId?: string;\n echoCancellation?: boolean[];\n facingMode?: string;\n frameRate?: number | DoubleRange;\n groupId?: string;\n height?: number | LongRange;\n sampleRate?: number | LongRange;\n sampleSize?: number | LongRange;\n volume?: number | DoubleRange;\n width?: number | LongRange;\n}\n\ninterface MediaTrackConstraints extends MediaTrackConstraintSet {\n advanced?: MediaTrackConstraintSet[];\n}\n\ninterface MediaTrackConstraintSet {\n aspectRatio?: number | ConstrainDoubleRange;\n deviceId?: string | string[] | ConstrainDOMStringParameters;\n echoCancelation?: boolean | ConstrainBooleanParameters;\n facingMode?: string | string[] | ConstrainDOMStringParameters;\n frameRate?: number | ConstrainDoubleRange;\n groupId?: string | string[] | ConstrainDOMStringParameters;\n height?: number | ConstrainLongRange;\n sampleRate?: number | ConstrainLongRange;\n sampleSize?: number | ConstrainLongRange;\n volume?: number | ConstrainDoubleRange;\n width?: number | ConstrainLongRange;\n}\n\ninterface MediaTrackSettings {\n aspectRatio?: number;\n deviceId?: string;\n echoCancellation?: boolean;\n facingMode?: string;\n frameRate?: number;\n groupId?: string;\n height?: number;\n sampleRate?: number;\n sampleSize?: number;\n volume?: number;\n width?: number;\n}\n\ninterface MediaTrackSupportedConstraints {\n aspectRatio?: boolean;\n deviceId?: boolean;\n echoCancellation?: boolean;\n facingMode?: boolean;\n frameRate?: boolean;\n groupId?: boolean;\n height?: boolean;\n sampleRate?: boolean;\n sampleSize?: boolean;\n volume?: boolean;\n width?: boolean;\n}\n\ninterface MessageEventInit extends EventInit {\n lastEventId?: string;\n channel?: string;\n data?: any;\n origin?: string;\n ports?: MessagePort[];\n source?: Window;\n}\n\ninterface MouseEventInit extends EventModifierInit {\n button?: number;\n buttons?: number;\n clientX?: number;\n clientY?: number;\n relatedTarget?: EventTarget;\n screenX?: number;\n screenY?: number;\n}\n\ninterface MSAccountInfo {\n accountImageUri?: string;\n accountName?: string;\n rpDisplayName?: string;\n userDisplayName?: string;\n userId?: string;\n}\n\ninterface MSAudioLocalClientEvent extends MSLocalClientEventBase {\n cpuInsufficientEventRatio?: number;\n deviceCaptureNotFunctioningEventRatio?: number;\n deviceClippingEventRatio?: number;\n deviceEchoEventRatio?: number;\n deviceGlitchesEventRatio?: number;\n deviceHalfDuplexAECEventRatio?: number;\n deviceHowlingEventCount?: number;\n deviceLowSNREventRatio?: number;\n deviceLowSpeechLevelEventRatio?: number;\n deviceMultipleEndpointsEventCount?: number;\n deviceNearEndToEchoRatioEventRatio?: number;\n deviceRenderMuteEventRatio?: number;\n deviceRenderNotFunctioningEventRatio?: number;\n deviceRenderZeroVolumeEventRatio?: number;\n networkDelayEventRatio?: number;\n networkSendQualityEventRatio?: number;\n}\n\ninterface MSAudioRecvPayload extends MSPayloadBase {\n burstLossLength1?: number;\n burstLossLength2?: number;\n burstLossLength3?: number;\n burstLossLength4?: number;\n burstLossLength5?: number;\n burstLossLength6?: number;\n burstLossLength7?: number;\n burstLossLength8OrHigher?: number;\n fecRecvDistance1?: number;\n fecRecvDistance2?: number;\n fecRecvDistance3?: number;\n packetReorderDepthAvg?: number;\n packetReorderDepthMax?: number;\n packetReorderRatio?: number;\n ratioCompressedSamplesAvg?: number;\n ratioConcealedSamplesAvg?: number;\n ratioStretchedSamplesAvg?: number;\n samplingRate?: number;\n signal?: MSAudioRecvSignal;\n}\n\ninterface MSAudioRecvSignal {\n initialSignalLevelRMS?: number;\n recvNoiseLevelCh1?: number;\n recvSignalLevelCh1?: number;\n renderLoopbackSignalLevel?: number;\n renderNoiseLevel?: number;\n renderSignalLevel?: number;\n}\n\ninterface MSAudioSendPayload extends MSPayloadBase {\n audioFECUsed?: boolean;\n samplingRate?: number;\n sendMutePercent?: number;\n signal?: MSAudioSendSignal;\n}\n\ninterface MSAudioSendSignal {\n noiseLevel?: number;\n sendNoiseLevelCh1?: number;\n sendSignalLevelCh1?: number;\n}\n\ninterface MSConnectivity {\n iceType?: MSIceType;\n iceWarningFlags?: MSIceWarningFlags;\n relayAddress?: MSRelayAddress;\n}\n\ninterface MSCredentialFilter {\n accept?: MSCredentialSpec[];\n}\n\ninterface MSCredentialParameters {\n type?: MSCredentialType;\n}\n\ninterface MSCredentialSpec {\n id?: string;\n type?: MSCredentialType;\n}\n\ninterface MSDelay {\n roundTrip?: number;\n roundTripMax?: number;\n}\n\ninterface MSDescription extends RTCStats {\n connectivity?: MSConnectivity;\n deviceDevName?: string;\n localAddr?: MSIPAddressInfo;\n networkconnectivity?: MSNetworkConnectivityInfo;\n reflexiveLocalIPAddr?: MSIPAddressInfo;\n remoteAddr?: MSIPAddressInfo;\n transport?: RTCIceProtocol;\n}\n\ninterface MSFIDOCredentialParameters extends MSCredentialParameters {\n algorithm?: string | Algorithm;\n authenticators?: AAGUID[];\n}\n\ninterface MSIceWarningFlags {\n allocationMessageIntegrityFailed?: boolean;\n alternateServerReceived?: boolean;\n connCheckMessageIntegrityFailed?: boolean;\n connCheckOtherError?: boolean;\n fipsAllocationFailure?: boolean;\n multipleRelayServersAttempted?: boolean;\n noRelayServersConfigured?: boolean;\n portRangeExhausted?: boolean;\n pseudoTLSFailure?: boolean;\n tcpNatConnectivityFailed?: boolean;\n tcpRelayConnectivityFailed?: boolean;\n turnAuthUnknownUsernameError?: boolean;\n turnTcpAllocateFailed?: boolean;\n turnTcpSendFailed?: boolean;\n turnTcpTimedOut?: boolean;\n turnTurnTcpConnectivityFailed?: boolean;\n turnUdpAllocateFailed?: boolean;\n turnUdpSendFailed?: boolean;\n udpLocalConnectivityFailed?: boolean;\n udpNatConnectivityFailed?: boolean;\n udpRelayConnectivityFailed?: boolean;\n useCandidateChecksFailed?: boolean;\n}\n\ninterface MSIPAddressInfo {\n ipAddr?: string;\n manufacturerMacAddrMask?: string;\n port?: number;\n}\n\ninterface MSJitter {\n interArrival?: number;\n interArrivalMax?: number;\n interArrivalSD?: number;\n}\n\ninterface MSLocalClientEventBase extends RTCStats {\n networkBandwidthLowEventRatio?: number;\n networkReceiveQualityEventRatio?: number;\n}\n\ninterface MSNetwork extends RTCStats {\n delay?: MSDelay;\n jitter?: MSJitter;\n packetLoss?: MSPacketLoss;\n utilization?: MSUtilization;\n}\n\ninterface MSNetworkConnectivityInfo {\n linkspeed?: number;\n networkConnectionDetails?: string;\n vpn?: boolean;\n}\n\ninterface MSNetworkInterfaceType {\n interfaceTypeEthernet?: boolean;\n interfaceTypePPP?: boolean;\n interfaceTypeTunnel?: boolean;\n interfaceTypeWireless?: boolean;\n interfaceTypeWWAN?: boolean;\n}\n\ninterface MSOutboundNetwork extends MSNetwork {\n appliedBandwidthLimit?: number;\n}\n\ninterface MSPacketLoss {\n lossRate?: number;\n lossRateMax?: number;\n}\n\ninterface MSPayloadBase extends RTCStats {\n payloadDescription?: string;\n}\n\ninterface MSPortRange {\n max?: number;\n min?: number;\n}\n\ninterface MSRelayAddress {\n port?: number;\n relayAddress?: string;\n}\n\ninterface MSSignatureParameters {\n userPrompt?: string;\n}\n\ninterface MSTransportDiagnosticsStats extends RTCStats {\n allocationTimeInMs?: number;\n baseAddress?: string;\n baseInterface?: MSNetworkInterfaceType;\n iceRole?: RTCIceRole;\n iceWarningFlags?: MSIceWarningFlags;\n interfaces?: MSNetworkInterfaceType;\n localAddress?: string;\n localAddrType?: MSIceAddrType;\n localInterface?: MSNetworkInterfaceType;\n localMR?: string;\n localMRTCPPort?: number;\n localSite?: string;\n msRtcEngineVersion?: string;\n networkName?: string;\n numConsentReqReceived?: number;\n numConsentReqSent?: number;\n numConsentRespReceived?: number;\n numConsentRespSent?: number;\n portRangeMax?: number;\n portRangeMin?: number;\n protocol?: RTCIceProtocol;\n remoteAddress?: string;\n remoteAddrType?: MSIceAddrType;\n remoteMR?: string;\n remoteMRTCPPort?: number;\n remoteSite?: string;\n rtpRtcpMux?: boolean;\n stunVer?: number;\n}\n\ninterface MSUtilization {\n bandwidthEstimation?: number;\n bandwidthEstimationAvg?: number;\n bandwidthEstimationMax?: number;\n bandwidthEstimationMin?: number;\n bandwidthEstimationStdDev?: number;\n packets?: number;\n}\n\ninterface MSVideoPayload extends MSPayloadBase {\n durationSeconds?: number;\n resolution?: string;\n videoBitRateAvg?: number;\n videoBitRateMax?: number;\n videoFrameRateAvg?: number;\n videoPacketLossRate?: number;\n}\n\ninterface MSVideoRecvPayload extends MSVideoPayload {\n lowBitRateCallPercent?: number;\n lowFrameRateCallPercent?: number;\n recvBitRateAverage?: number;\n recvBitRateMaximum?: number;\n recvCodecType?: string;\n recvFpsHarmonicAverage?: number;\n recvFrameRateAverage?: number;\n recvNumResSwitches?: number;\n recvReorderBufferMaxSuccessfullyOrderedExtent?: number;\n recvReorderBufferMaxSuccessfullyOrderedLateTime?: number;\n recvReorderBufferPacketsDroppedDueToBufferExhaustion?: number;\n recvReorderBufferPacketsDroppedDueToTimeout?: number;\n recvReorderBufferReorderedPackets?: number;\n recvResolutionHeight?: number;\n recvResolutionWidth?: number;\n recvVideoStreamsMax?: number;\n recvVideoStreamsMin?: number;\n recvVideoStreamsMode?: number;\n reorderBufferTotalPackets?: number;\n videoFrameLossRate?: number;\n videoPostFECPLR?: number;\n videoResolutions?: MSVideoResolutionDistribution;\n}\n\ninterface MSVideoResolutionDistribution {\n cifQuality?: number;\n h1080Quality?: number;\n h1440Quality?: number;\n h2160Quality?: number;\n h720Quality?: number;\n vgaQuality?: number;\n}\n\ninterface MSVideoSendPayload extends MSVideoPayload {\n sendBitRateAverage?: number;\n sendBitRateMaximum?: number;\n sendFrameRateAverage?: number;\n sendResolutionHeight?: number;\n sendResolutionWidth?: number;\n sendVideoStreamsMax?: number;\n}\n\ninterface MsZoomToOptions {\n animate?: string;\n contentX?: number;\n contentY?: number;\n scaleFactor?: number;\n viewportX?: string;\n viewportY?: string;\n}\n\ninterface MutationObserverInit {\n attributeFilter?: string[];\n attributeOldValue?: boolean;\n attributes?: boolean;\n characterData?: boolean;\n characterDataOldValue?: boolean;\n childList?: boolean;\n subtree?: boolean;\n}\n\ninterface NotificationOptions {\n body?: string;\n dir?: NotificationDirection;\n icon?: string;\n lang?: string;\n tag?: string;\n}\n\ninterface ObjectURLOptions {\n oneTimeOnly?: boolean;\n}\n\ninterface PaymentCurrencyAmount {\n currency?: string;\n currencySystem?: string;\n value?: string;\n}\n\ninterface PaymentDetails {\n displayItems?: PaymentItem[];\n error?: string;\n modifiers?: PaymentDetailsModifier[];\n shippingOptions?: PaymentShippingOption[];\n total?: PaymentItem;\n}\n\ninterface PaymentDetailsModifier {\n additionalDisplayItems?: PaymentItem[];\n data?: any;\n supportedMethods?: string[];\n total?: PaymentItem;\n}\n\ninterface PaymentItem {\n amount?: PaymentCurrencyAmount;\n label?: string;\n pending?: boolean;\n}\n\ninterface PaymentMethodData {\n data?: any;\n supportedMethods?: string[];\n}\n\ninterface PaymentOptions {\n requestPayerEmail?: boolean;\n requestPayerName?: boolean;\n requestPayerPhone?: boolean;\n requestShipping?: boolean;\n shippingType?: string;\n}\n\ninterface PaymentRequestUpdateEventInit extends EventInit {\n}\n\ninterface PaymentShippingOption {\n amount?: PaymentCurrencyAmount;\n id?: string;\n label?: string;\n selected?: boolean;\n}\n\ninterface PeriodicWaveConstraints {\n disableNormalization?: boolean;\n}\n\ninterface PointerEventInit extends MouseEventInit {\n height?: number;\n isPrimary?: boolean;\n pointerId?: number;\n pointerType?: string;\n pressure?: number;\n tiltX?: number;\n tiltY?: number;\n width?: number;\n}\n\ninterface PopStateEventInit extends EventInit {\n state?: any;\n}\n\ninterface PositionOptions {\n enableHighAccuracy?: boolean;\n maximumAge?: number;\n timeout?: number;\n}\n\ninterface ProgressEventInit extends EventInit {\n lengthComputable?: boolean;\n loaded?: number;\n total?: number;\n}\n\ninterface PushSubscriptionOptionsInit {\n applicationServerKey?: any;\n userVisibleOnly?: boolean;\n}\n\ninterface RegistrationOptions {\n scope?: string;\n}\n\ninterface RequestInit {\n body?: any;\n cache?: RequestCache;\n credentials?: RequestCredentials;\n headers?: any;\n integrity?: string;\n keepalive?: boolean;\n method?: string;\n mode?: RequestMode;\n redirect?: RequestRedirect;\n referrer?: string;\n referrerPolicy?: ReferrerPolicy;\n window?: any;\n}\n\ninterface ResponseInit {\n headers?: any;\n status?: number;\n statusText?: string;\n}\n\ninterface RTCConfiguration {\n bundlePolicy?: RTCBundlePolicy;\n iceServers?: RTCIceServer[];\n iceTransportPolicy?: RTCIceTransportPolicy;\n peerIdentity?: string;\n}\n\ninterface RTCDtlsFingerprint {\n algorithm?: string;\n value?: string;\n}\n\ninterface RTCDtlsParameters {\n fingerprints?: RTCDtlsFingerprint[];\n role?: RTCDtlsRole;\n}\n\ninterface RTCDTMFToneChangeEventInit extends EventInit {\n tone?: string;\n}\n\ninterface RTCIceCandidateAttributes extends RTCStats {\n addressSourceUrl?: string;\n candidateType?: RTCStatsIceCandidateType;\n ipAddress?: string;\n portNumber?: number;\n priority?: number;\n transport?: string;\n}\n\ninterface RTCIceCandidateComplete {\n}\n\ninterface RTCIceCandidateDictionary {\n foundation?: string;\n ip?: string;\n msMTurnSessionId?: string;\n port?: number;\n priority?: number;\n protocol?: RTCIceProtocol;\n relatedAddress?: string;\n relatedPort?: number;\n tcpType?: RTCIceTcpCandidateType;\n type?: RTCIceCandidateType;\n}\n\ninterface RTCIceCandidateInit {\n candidate?: string;\n sdpMid?: string;\n sdpMLineIndex?: number;\n}\n\ninterface RTCIceCandidatePair {\n local?: RTCIceCandidateDictionary;\n remote?: RTCIceCandidateDictionary;\n}\n\ninterface RTCIceCandidatePairStats extends RTCStats {\n availableIncomingBitrate?: number;\n availableOutgoingBitrate?: number;\n bytesReceived?: number;\n bytesSent?: number;\n localCandidateId?: string;\n nominated?: boolean;\n priority?: number;\n readable?: boolean;\n remoteCandidateId?: string;\n roundTripTime?: number;\n state?: RTCStatsIceCandidatePairState;\n transportId?: string;\n writable?: boolean;\n}\n\ninterface RTCIceGatherOptions {\n gatherPolicy?: RTCIceGatherPolicy;\n iceservers?: RTCIceServer[];\n portRange?: MSPortRange;\n}\n\ninterface RTCIceParameters {\n iceLite?: boolean;\n password?: string;\n usernameFragment?: string;\n}\n\ninterface RTCIceServer {\n credential?: string;\n urls?: any;\n username?: string;\n}\n\ninterface RTCInboundRTPStreamStats extends RTCRTPStreamStats {\n bytesReceived?: number;\n fractionLost?: number;\n jitter?: number;\n packetsLost?: number;\n packetsReceived?: number;\n}\n\ninterface RTCMediaStreamTrackStats extends RTCStats {\n audioLevel?: number;\n echoReturnLoss?: number;\n echoReturnLossEnhancement?: number;\n frameHeight?: number;\n framesCorrupted?: number;\n framesDecoded?: number;\n framesDropped?: number;\n framesPerSecond?: number;\n framesReceived?: number;\n framesSent?: number;\n frameWidth?: number;\n remoteSource?: boolean;\n ssrcIds?: string[];\n trackIdentifier?: string;\n}\n\ninterface RTCOfferOptions {\n iceRestart?: boolean;\n offerToReceiveAudio?: number;\n offerToReceiveVideo?: number;\n voiceActivityDetection?: boolean;\n}\n\ninterface RTCOutboundRTPStreamStats extends RTCRTPStreamStats {\n bytesSent?: number;\n packetsSent?: number;\n roundTripTime?: number;\n targetBitrate?: number;\n}\n\ninterface RTCPeerConnectionIceEventInit extends EventInit {\n candidate?: RTCIceCandidate;\n}\n\ninterface RTCRtcpFeedback {\n parameter?: string;\n type?: string;\n}\n\ninterface RTCRtcpParameters {\n cname?: string;\n mux?: boolean;\n reducedSize?: boolean;\n ssrc?: number;\n}\n\ninterface RTCRtpCapabilities {\n codecs?: RTCRtpCodecCapability[];\n fecMechanisms?: string[];\n headerExtensions?: RTCRtpHeaderExtension[];\n}\n\ninterface RTCRtpCodecCapability {\n clockRate?: number;\n kind?: string;\n maxptime?: number;\n maxSpatialLayers?: number;\n maxTemporalLayers?: number;\n name?: string;\n numChannels?: number;\n options?: any;\n parameters?: any;\n preferredPayloadType?: number;\n ptime?: number;\n rtcpFeedback?: RTCRtcpFeedback[];\n svcMultiStreamSupport?: boolean;\n}\n\ninterface RTCRtpCodecParameters {\n clockRate?: number;\n maxptime?: number;\n name?: string;\n numChannels?: number;\n parameters?: any;\n payloadType?: any;\n ptime?: number;\n rtcpFeedback?: RTCRtcpFeedback[];\n}\n\ninterface RTCRtpContributingSource {\n audioLevel?: number;\n csrc?: number;\n timestamp?: number;\n}\n\ninterface RTCRtpEncodingParameters {\n active?: boolean;\n codecPayloadType?: number;\n dependencyEncodingIds?: string[];\n encodingId?: string;\n fec?: RTCRtpFecParameters;\n framerateScale?: number;\n maxBitrate?: number;\n maxFramerate?: number;\n minQuality?: number;\n priority?: number;\n resolutionScale?: number;\n rtx?: RTCRtpRtxParameters;\n ssrc?: number;\n ssrcRange?: RTCSsrcRange;\n}\n\ninterface RTCRtpFecParameters {\n mechanism?: string;\n ssrc?: number;\n}\n\ninterface RTCRtpHeaderExtension {\n kind?: string;\n preferredEncrypt?: boolean;\n preferredId?: number;\n uri?: string;\n}\n\ninterface RTCRtpHeaderExtensionParameters {\n encrypt?: boolean;\n id?: number;\n uri?: string;\n}\n\ninterface RTCRtpParameters {\n codecs?: RTCRtpCodecParameters[];\n degradationPreference?: RTCDegradationPreference;\n encodings?: RTCRtpEncodingParameters[];\n headerExtensions?: RTCRtpHeaderExtensionParameters[];\n muxId?: string;\n rtcp?: RTCRtcpParameters;\n}\n\ninterface RTCRtpRtxParameters {\n ssrc?: number;\n}\n\ninterface RTCRTPStreamStats extends RTCStats {\n associateStatsId?: string;\n codecId?: string;\n firCount?: number;\n isRemote?: boolean;\n mediaTrackId?: string;\n nackCount?: number;\n pliCount?: number;\n sliCount?: number;\n ssrc?: string;\n transportId?: string;\n}\n\ninterface RTCRtpUnhandled {\n muxId?: string;\n payloadType?: number;\n ssrc?: number;\n}\n\ninterface RTCSessionDescriptionInit {\n sdp?: string;\n type?: RTCSdpType;\n}\n\ninterface RTCSrtpKeyParam {\n keyMethod?: string;\n keySalt?: string;\n lifetime?: string;\n mkiLength?: number;\n mkiValue?: number;\n}\n\ninterface RTCSrtpSdesParameters {\n cryptoSuite?: string;\n keyParams?: RTCSrtpKeyParam[];\n sessionParams?: string[];\n tag?: number;\n}\n\ninterface RTCSsrcRange {\n max?: number;\n min?: number;\n}\n\ninterface RTCStats {\n id?: string;\n msType?: MSStatsType;\n timestamp?: number;\n type?: RTCStatsType;\n}\n\ninterface RTCStatsReport {\n}\n\ninterface RTCTransportStats extends RTCStats {\n activeConnection?: boolean;\n bytesReceived?: number;\n bytesSent?: number;\n localCertificateId?: string;\n remoteCertificateId?: string;\n rtcpTransportStatsId?: string;\n selectedCandidatePairId?: string;\n}\n\ninterface ScopedCredentialDescriptor {\n id?: any;\n transports?: Transport[];\n type?: ScopedCredentialType;\n}\n\ninterface ScopedCredentialOptions {\n excludeList?: ScopedCredentialDescriptor[];\n extensions?: WebAuthnExtensions;\n rpId?: USVString;\n timeoutSeconds?: number;\n}\n\ninterface ScopedCredentialParameters {\n algorithm?: string | Algorithm;\n type?: ScopedCredentialType;\n}\n\ninterface ServiceWorkerMessageEventInit extends EventInit {\n data?: any;\n lastEventId?: string;\n origin?: string;\n ports?: MessagePort[];\n source?: ServiceWorker | MessagePort;\n}\n\ninterface SpeechSynthesisEventInit extends EventInit {\n charIndex?: number;\n elapsedTime?: number;\n name?: string;\n utterance?: SpeechSynthesisUtterance;\n}\n\ninterface StoreExceptionsInformation extends ExceptionInformation {\n detailURI?: string;\n explanationString?: string;\n siteName?: string;\n}\n\ninterface StoreSiteSpecificExceptionsInformation extends StoreExceptionsInformation {\n arrayOfDomainStrings?: string[];\n}\n\ninterface TrackEventInit extends EventInit {\n track?: VideoTrack | AudioTrack | TextTrack;\n}\n\ninterface TransitionEventInit extends EventInit {\n elapsedTime?: number;\n propertyName?: string;\n}\n\ninterface UIEventInit extends EventInit {\n detail?: number;\n view?: Window;\n}\n\ninterface WebAuthnExtensions {\n}\n\ninterface WebGLContextAttributes {\n failIfMajorPerformanceCaveat?: boolean;\n alpha?: boolean;\n antialias?: boolean;\n depth?: boolean;\n premultipliedAlpha?: boolean;\n preserveDrawingBuffer?: boolean;\n stencil?: boolean;\n}\n\ninterface WebGLContextEventInit extends EventInit {\n statusMessage?: string;\n}\n\ninterface WheelEventInit extends MouseEventInit {\n deltaMode?: number;\n deltaX?: number;\n deltaY?: number;\n deltaZ?: number;\n}\n\ninterface EventListener {\n (evt: Event): void;\n}\n\ninterface WebKitEntriesCallback {\n (evt: Event): void;\n}\n\ninterface WebKitErrorCallback {\n (evt: Event): void;\n}\n\ninterface WebKitFileCallback {\n (evt: Event): void;\n}\n\ninterface AnalyserNode extends AudioNode {\n fftSize: number;\n readonly frequencyBinCount: number;\n maxDecibels: number;\n minDecibels: number;\n smoothingTimeConstant: number;\n getByteFrequencyData(array: Uint8Array): void;\n getByteTimeDomainData(array: Uint8Array): void;\n getFloatFrequencyData(array: Float32Array): void;\n getFloatTimeDomainData(array: Float32Array): void;\n}\n\ndeclare var AnalyserNode: {\n prototype: AnalyserNode;\n new(): AnalyserNode;\n};\n\ninterface ANGLE_instanced_arrays {\n drawArraysInstancedANGLE(mode: number, first: number, count: number, primcount: number): void;\n drawElementsInstancedANGLE(mode: number, count: number, type: number, offset: number, primcount: number): void;\n vertexAttribDivisorANGLE(index: number, divisor: number): void;\n readonly VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE: number;\n}\n\ndeclare var ANGLE_instanced_arrays: {\n prototype: ANGLE_instanced_arrays;\n new(): ANGLE_instanced_arrays;\n readonly VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE: number;\n};\n\ninterface AnimationEvent extends Event {\n readonly animationName: string;\n readonly elapsedTime: number;\n initAnimationEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, animationNameArg: string, elapsedTimeArg: number): void;\n}\n\ndeclare var AnimationEvent: {\n prototype: AnimationEvent;\n new(typeArg: string, eventInitDict?: AnimationEventInit): AnimationEvent;\n};\n\ninterface ApplicationCacheEventMap {\n \"cached\": Event;\n \"checking\": Event;\n \"downloading\": Event;\n \"error\": Event;\n \"noupdate\": Event;\n \"obsolete\": Event;\n \"progress\": ProgressEvent;\n \"updateready\": Event;\n}\n\ninterface ApplicationCache extends EventTarget {\n oncached: (this: ApplicationCache, ev: Event) => any;\n onchecking: (this: ApplicationCache, ev: Event) => any;\n ondownloading: (this: ApplicationCache, ev: Event) => any;\n onerror: (this: ApplicationCache, ev: Event) => any;\n onnoupdate: (this: ApplicationCache, ev: Event) => any;\n onobsolete: (this: ApplicationCache, ev: Event) => any;\n onprogress: (this: ApplicationCache, ev: ProgressEvent) => any;\n onupdateready: (this: ApplicationCache, ev: Event) => any;\n readonly status: number;\n abort(): void;\n swapCache(): void;\n update(): void;\n readonly CHECKING: number;\n readonly DOWNLOADING: number;\n readonly IDLE: number;\n readonly OBSOLETE: number;\n readonly UNCACHED: number;\n readonly UPDATEREADY: number;\n addEventListener(type: K, listener: (this: ApplicationCache, ev: ApplicationCacheEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ApplicationCache: {\n prototype: ApplicationCache;\n new(): ApplicationCache;\n readonly CHECKING: number;\n readonly DOWNLOADING: number;\n readonly IDLE: number;\n readonly OBSOLETE: number;\n readonly UNCACHED: number;\n readonly UPDATEREADY: number;\n};\n\ninterface Attr extends Node {\n readonly name: string;\n readonly ownerElement: Element;\n readonly prefix: string | null;\n readonly specified: boolean;\n value: string;\n}\n\ndeclare var Attr: {\n prototype: Attr;\n new(): Attr;\n};\n\ninterface AudioBuffer {\n readonly duration: number;\n readonly length: number;\n readonly numberOfChannels: number;\n readonly sampleRate: number;\n copyFromChannel(destination: Float32Array, channelNumber: number, startInChannel?: number): void;\n copyToChannel(source: Float32Array, channelNumber: number, startInChannel?: number): void;\n getChannelData(channel: number): Float32Array;\n}\n\ndeclare var AudioBuffer: {\n prototype: AudioBuffer;\n new(): AudioBuffer;\n};\n\ninterface AudioBufferSourceNodeEventMap {\n \"ended\": MediaStreamErrorEvent;\n}\n\ninterface AudioBufferSourceNode extends AudioNode {\n buffer: AudioBuffer | null;\n readonly detune: AudioParam;\n loop: boolean;\n loopEnd: number;\n loopStart: number;\n onended: (this: AudioBufferSourceNode, ev: MediaStreamErrorEvent) => any;\n readonly playbackRate: AudioParam;\n start(when?: number, offset?: number, duration?: number): void;\n stop(when?: number): void;\n addEventListener(type: K, listener: (this: AudioBufferSourceNode, ev: AudioBufferSourceNodeEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var AudioBufferSourceNode: {\n prototype: AudioBufferSourceNode;\n new(): AudioBufferSourceNode;\n};\n\ninterface AudioContextEventMap {\n \"statechange\": Event;\n}\n\ninterface AudioContextBase extends EventTarget {\n readonly currentTime: number;\n readonly destination: AudioDestinationNode;\n readonly listener: AudioListener;\n onstatechange: (this: AudioContext, ev: Event) => any;\n readonly sampleRate: number;\n readonly state: AudioContextState;\n close(): Promise;\n createAnalyser(): AnalyserNode;\n createBiquadFilter(): BiquadFilterNode;\n createBuffer(numberOfChannels: number, length: number, sampleRate: number): AudioBuffer;\n createBufferSource(): AudioBufferSourceNode;\n createChannelMerger(numberOfInputs?: number): ChannelMergerNode;\n createChannelSplitter(numberOfOutputs?: number): ChannelSplitterNode;\n createConvolver(): ConvolverNode;\n createDelay(maxDelayTime?: number): DelayNode;\n createDynamicsCompressor(): DynamicsCompressorNode;\n createGain(): GainNode;\n createIIRFilter(feedforward: number[], feedback: number[]): IIRFilterNode;\n createMediaElementSource(mediaElement: HTMLMediaElement): MediaElementAudioSourceNode;\n createMediaStreamSource(mediaStream: MediaStream): MediaStreamAudioSourceNode;\n createOscillator(): OscillatorNode;\n createPanner(): PannerNode;\n createPeriodicWave(real: Float32Array, imag: Float32Array, constraints?: PeriodicWaveConstraints): PeriodicWave;\n createScriptProcessor(bufferSize?: number, numberOfInputChannels?: number, numberOfOutputChannels?: number): ScriptProcessorNode;\n createStereoPanner(): StereoPannerNode;\n createWaveShaper(): WaveShaperNode;\n decodeAudioData(audioData: ArrayBuffer, successCallback?: DecodeSuccessCallback, errorCallback?: DecodeErrorCallback): Promise;\n resume(): Promise;\n addEventListener(type: K, listener: (this: AudioContext, ev: AudioContextEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface AudioContext extends AudioContextBase {\n suspend(): Promise;\n}\n\ndeclare var AudioContext: {\n prototype: AudioContext;\n new(): AudioContext;\n};\n\ninterface AudioDestinationNode extends AudioNode {\n readonly maxChannelCount: number;\n}\n\ndeclare var AudioDestinationNode: {\n prototype: AudioDestinationNode;\n new(): AudioDestinationNode;\n};\n\ninterface AudioListener {\n dopplerFactor: number;\n speedOfSound: number;\n setOrientation(x: number, y: number, z: number, xUp: number, yUp: number, zUp: number): void;\n setPosition(x: number, y: number, z: number): void;\n setVelocity(x: number, y: number, z: number): void;\n}\n\ndeclare var AudioListener: {\n prototype: AudioListener;\n new(): AudioListener;\n};\n\ninterface AudioNode extends EventTarget {\n channelCount: number;\n channelCountMode: ChannelCountMode;\n channelInterpretation: ChannelInterpretation;\n readonly context: AudioContext;\n readonly numberOfInputs: number;\n readonly numberOfOutputs: number;\n connect(destination: AudioNode, output?: number, input?: number): AudioNode;\n connect(destination: AudioParam, output?: number): void;\n disconnect(output?: number): void;\n disconnect(destination: AudioNode, output?: number, input?: number): void;\n disconnect(destination: AudioParam, output?: number): void;\n}\n\ndeclare var AudioNode: {\n prototype: AudioNode;\n new(): AudioNode;\n};\n\ninterface AudioParam {\n readonly defaultValue: number;\n value: number;\n cancelScheduledValues(startTime: number): AudioParam;\n exponentialRampToValueAtTime(value: number, endTime: number): AudioParam;\n linearRampToValueAtTime(value: number, endTime: number): AudioParam;\n setTargetAtTime(target: number, startTime: number, timeConstant: number): AudioParam;\n setValueAtTime(value: number, startTime: number): AudioParam;\n setValueCurveAtTime(values: Float32Array, startTime: number, duration: number): AudioParam;\n}\n\ndeclare var AudioParam: {\n prototype: AudioParam;\n new(): AudioParam;\n};\n\ninterface AudioProcessingEvent extends Event {\n readonly inputBuffer: AudioBuffer;\n readonly outputBuffer: AudioBuffer;\n readonly playbackTime: number;\n}\n\ndeclare var AudioProcessingEvent: {\n prototype: AudioProcessingEvent;\n new(): AudioProcessingEvent;\n};\n\ninterface AudioTrack {\n enabled: boolean;\n readonly id: string;\n kind: string;\n readonly label: string;\n language: string;\n readonly sourceBuffer: SourceBuffer;\n}\n\ndeclare var AudioTrack: {\n prototype: AudioTrack;\n new(): AudioTrack;\n};\n\ninterface AudioTrackListEventMap {\n \"addtrack\": TrackEvent;\n \"change\": Event;\n \"removetrack\": TrackEvent;\n}\n\ninterface AudioTrackList extends EventTarget {\n readonly length: number;\n onaddtrack: (this: AudioTrackList, ev: TrackEvent) => any;\n onchange: (this: AudioTrackList, ev: Event) => any;\n onremovetrack: (this: AudioTrackList, ev: TrackEvent) => any;\n getTrackById(id: string): AudioTrack | null;\n item(index: number): AudioTrack;\n addEventListener(type: K, listener: (this: AudioTrackList, ev: AudioTrackListEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [index: number]: AudioTrack;\n}\n\ndeclare var AudioTrackList: {\n prototype: AudioTrackList;\n new(): AudioTrackList;\n};\n\ninterface BarProp {\n readonly visible: boolean;\n}\n\ndeclare var BarProp: {\n prototype: BarProp;\n new(): BarProp;\n};\n\ninterface BeforeUnloadEvent extends Event {\n returnValue: any;\n}\n\ndeclare var BeforeUnloadEvent: {\n prototype: BeforeUnloadEvent;\n new(): BeforeUnloadEvent;\n};\n\ninterface BiquadFilterNode extends AudioNode {\n readonly detune: AudioParam;\n readonly frequency: AudioParam;\n readonly gain: AudioParam;\n readonly Q: AudioParam;\n type: BiquadFilterType;\n getFrequencyResponse(frequencyHz: Float32Array, magResponse: Float32Array, phaseResponse: Float32Array): void;\n}\n\ndeclare var BiquadFilterNode: {\n prototype: BiquadFilterNode;\n new(): BiquadFilterNode;\n};\n\ninterface Blob {\n readonly size: number;\n readonly type: string;\n msClose(): void;\n msDetachStream(): any;\n slice(start?: number, end?: number, contentType?: string): Blob;\n}\n\ndeclare var Blob: {\n prototype: Blob;\n new (blobParts?: any[], options?: BlobPropertyBag): Blob;\n};\n\ninterface Cache {\n add(request: RequestInfo): Promise;\n addAll(requests: RequestInfo[]): Promise;\n delete(request: RequestInfo, options?: CacheQueryOptions): Promise;\n keys(request?: RequestInfo, options?: CacheQueryOptions): any;\n match(request: RequestInfo, options?: CacheQueryOptions): Promise;\n matchAll(request?: RequestInfo, options?: CacheQueryOptions): any;\n put(request: RequestInfo, response: Response): Promise;\n}\n\ndeclare var Cache: {\n prototype: Cache;\n new(): Cache;\n};\n\ninterface CacheStorage {\n delete(cacheName: string): Promise;\n has(cacheName: string): Promise;\n keys(): any;\n match(request: RequestInfo, options?: CacheQueryOptions): Promise;\n open(cacheName: string): Promise;\n}\n\ndeclare var CacheStorage: {\n prototype: CacheStorage;\n new(): CacheStorage;\n};\n\ninterface CanvasGradient {\n addColorStop(offset: number, color: string): void;\n}\n\ndeclare var CanvasGradient: {\n prototype: CanvasGradient;\n new(): CanvasGradient;\n};\n\ninterface CanvasPattern {\n setTransform(matrix: SVGMatrix): void;\n}\n\ndeclare var CanvasPattern: {\n prototype: CanvasPattern;\n new(): CanvasPattern;\n};\n\ninterface CanvasRenderingContext2D extends Object, CanvasPathMethods {\n readonly canvas: HTMLCanvasElement;\n fillStyle: string | CanvasGradient | CanvasPattern;\n font: string;\n globalAlpha: number;\n globalCompositeOperation: string;\n imageSmoothingEnabled: boolean;\n lineCap: string;\n lineDashOffset: number;\n lineJoin: string;\n lineWidth: number;\n miterLimit: number;\n msFillRule: CanvasFillRule;\n shadowBlur: number;\n shadowColor: string;\n shadowOffsetX: number;\n shadowOffsetY: number;\n strokeStyle: string | CanvasGradient | CanvasPattern;\n textAlign: string;\n textBaseline: string;\n mozImageSmoothingEnabled: boolean;\n webkitImageSmoothingEnabled: boolean;\n oImageSmoothingEnabled: boolean;\n beginPath(): void;\n clearRect(x: number, y: number, w: number, h: number): void;\n clip(fillRule?: CanvasFillRule): void;\n createImageData(imageDataOrSw: number | ImageData, sh?: number): ImageData;\n createLinearGradient(x0: number, y0: number, x1: number, y1: number): CanvasGradient;\n createPattern(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement, repetition: string): CanvasPattern;\n createRadialGradient(x0: number, y0: number, r0: number, x1: number, y1: number, r1: number): CanvasGradient;\n drawFocusIfNeeded(element: Element): void;\n drawImage(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, dstX: number, dstY: number): void;\n drawImage(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, dstX: number, dstY: number, dstW: number, dstH: number): void;\n drawImage(image: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, srcX: number, srcY: number, srcW: number, srcH: number, dstX: number, dstY: number, dstW: number, dstH: number): void;\n fill(fillRule?: CanvasFillRule): void;\n fillRect(x: number, y: number, w: number, h: number): void;\n fillText(text: string, x: number, y: number, maxWidth?: number): void;\n getImageData(sx: number, sy: number, sw: number, sh: number): ImageData;\n getLineDash(): number[];\n isPointInPath(x: number, y: number, fillRule?: CanvasFillRule): boolean;\n measureText(text: string): TextMetrics;\n putImageData(imagedata: ImageData, dx: number, dy: number, dirtyX?: number, dirtyY?: number, dirtyWidth?: number, dirtyHeight?: number): void;\n restore(): void;\n rotate(angle: number): void;\n save(): void;\n scale(x: number, y: number): void;\n setLineDash(segments: number[]): void;\n setTransform(m11: number, m12: number, m21: number, m22: number, dx: number, dy: number): void;\n stroke(path?: Path2D): void;\n strokeRect(x: number, y: number, w: number, h: number): void;\n strokeText(text: string, x: number, y: number, maxWidth?: number): void;\n transform(m11: number, m12: number, m21: number, m22: number, dx: number, dy: number): void;\n translate(x: number, y: number): void;\n}\n\ndeclare var CanvasRenderingContext2D: {\n prototype: CanvasRenderingContext2D;\n new(): CanvasRenderingContext2D;\n};\n\ninterface CDATASection extends Text {\n}\n\ndeclare var CDATASection: {\n prototype: CDATASection;\n new(): CDATASection;\n};\n\ninterface ChannelMergerNode extends AudioNode {\n}\n\ndeclare var ChannelMergerNode: {\n prototype: ChannelMergerNode;\n new(): ChannelMergerNode;\n};\n\ninterface ChannelSplitterNode extends AudioNode {\n}\n\ndeclare var ChannelSplitterNode: {\n prototype: ChannelSplitterNode;\n new(): ChannelSplitterNode;\n};\n\ninterface CharacterData extends Node, ChildNode {\n data: string;\n readonly length: number;\n appendData(arg: string): void;\n deleteData(offset: number, count: number): void;\n insertData(offset: number, arg: string): void;\n replaceData(offset: number, count: number, arg: string): void;\n substringData(offset: number, count: number): string;\n}\n\ndeclare var CharacterData: {\n prototype: CharacterData;\n new(): CharacterData;\n};\n\ninterface ClientRect {\n bottom: number;\n readonly height: number;\n left: number;\n right: number;\n top: number;\n readonly width: number;\n}\n\ndeclare var ClientRect: {\n prototype: ClientRect;\n new(): ClientRect;\n};\n\ninterface ClientRectList {\n readonly length: number;\n item(index: number): ClientRect;\n [index: number]: ClientRect;\n}\n\ndeclare var ClientRectList: {\n prototype: ClientRectList;\n new(): ClientRectList;\n};\n\ninterface ClipboardEvent extends Event {\n readonly clipboardData: DataTransfer;\n}\n\ndeclare var ClipboardEvent: {\n prototype: ClipboardEvent;\n new(type: string, eventInitDict?: ClipboardEventInit): ClipboardEvent;\n};\n\ninterface CloseEvent extends Event {\n readonly code: number;\n readonly reason: string;\n readonly wasClean: boolean;\n initCloseEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, wasCleanArg: boolean, codeArg: number, reasonArg: string): void;\n}\n\ndeclare var CloseEvent: {\n prototype: CloseEvent;\n new(typeArg: string, eventInitDict?: CloseEventInit): CloseEvent;\n};\n\ninterface Comment extends CharacterData {\n text: string;\n}\n\ndeclare var Comment: {\n prototype: Comment;\n new(): Comment;\n};\n\ninterface CompositionEvent extends UIEvent {\n readonly data: string;\n readonly locale: string;\n initCompositionEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, dataArg: string, locale: string): void;\n}\n\ndeclare var CompositionEvent: {\n prototype: CompositionEvent;\n new(typeArg: string, eventInitDict?: CompositionEventInit): CompositionEvent;\n};\n\ninterface Console {\n assert(test?: boolean, message?: string, ...optionalParams: any[]): void;\n clear(): void;\n count(countTitle?: string): void;\n debug(message?: any, ...optionalParams: any[]): void;\n dir(value?: any, ...optionalParams: any[]): void;\n dirxml(value: any): void;\n error(message?: any, ...optionalParams: any[]): void;\n exception(message?: string, ...optionalParams: any[]): void;\n group(groupTitle?: string, ...optionalParams: any[]): void;\n groupCollapsed(groupTitle?: string, ...optionalParams: any[]): void;\n groupEnd(): void;\n info(message?: any, ...optionalParams: any[]): void;\n log(message?: any, ...optionalParams: any[]): void;\n msIsIndependentlyComposed(element: Element): boolean;\n profile(reportName?: string): void;\n profileEnd(): void;\n select(element: Element): void;\n table(...data: any[]): void;\n time(timerName?: string): void;\n timeEnd(timerName?: string): void;\n trace(message?: any, ...optionalParams: any[]): void;\n warn(message?: any, ...optionalParams: any[]): void;\n}\n\ndeclare var Console: {\n prototype: Console;\n new(): Console;\n};\n\ninterface ConvolverNode extends AudioNode {\n buffer: AudioBuffer | null;\n normalize: boolean;\n}\n\ndeclare var ConvolverNode: {\n prototype: ConvolverNode;\n new(): ConvolverNode;\n};\n\ninterface Coordinates {\n readonly accuracy: number;\n readonly altitude: number | null;\n readonly altitudeAccuracy: number | null;\n readonly heading: number | null;\n readonly latitude: number;\n readonly longitude: number;\n readonly speed: number | null;\n}\n\ndeclare var Coordinates: {\n prototype: Coordinates;\n new(): Coordinates;\n};\n\ninterface Crypto extends Object, RandomSource {\n readonly subtle: SubtleCrypto;\n}\n\ndeclare var Crypto: {\n prototype: Crypto;\n new(): Crypto;\n};\n\ninterface CryptoKey {\n readonly algorithm: KeyAlgorithm;\n readonly extractable: boolean;\n readonly type: string;\n readonly usages: string[];\n}\n\ndeclare var CryptoKey: {\n prototype: CryptoKey;\n new(): CryptoKey;\n};\n\ninterface CryptoKeyPair {\n privateKey: CryptoKey;\n publicKey: CryptoKey;\n}\n\ndeclare var CryptoKeyPair: {\n prototype: CryptoKeyPair;\n new(): CryptoKeyPair;\n};\n\ninterface CSS {\n supports(property: string, value?: string): boolean;\n}\ndeclare var CSS: CSS;\n\ninterface CSSConditionRule extends CSSGroupingRule {\n conditionText: string;\n}\n\ndeclare var CSSConditionRule: {\n prototype: CSSConditionRule;\n new(): CSSConditionRule;\n};\n\ninterface CSSFontFaceRule extends CSSRule {\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSFontFaceRule: {\n prototype: CSSFontFaceRule;\n new(): CSSFontFaceRule;\n};\n\ninterface CSSGroupingRule extends CSSRule {\n readonly cssRules: CSSRuleList;\n deleteRule(index: number): void;\n insertRule(rule: string, index: number): number;\n}\n\ndeclare var CSSGroupingRule: {\n prototype: CSSGroupingRule;\n new(): CSSGroupingRule;\n};\n\ninterface CSSImportRule extends CSSRule {\n readonly href: string;\n readonly media: MediaList;\n readonly styleSheet: CSSStyleSheet;\n}\n\ndeclare var CSSImportRule: {\n prototype: CSSImportRule;\n new(): CSSImportRule;\n};\n\ninterface CSSKeyframeRule extends CSSRule {\n keyText: string;\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSKeyframeRule: {\n prototype: CSSKeyframeRule;\n new(): CSSKeyframeRule;\n};\n\ninterface CSSKeyframesRule extends CSSRule {\n readonly cssRules: CSSRuleList;\n name: string;\n appendRule(rule: string): void;\n deleteRule(rule: string): void;\n findRule(rule: string): CSSKeyframeRule;\n}\n\ndeclare var CSSKeyframesRule: {\n prototype: CSSKeyframesRule;\n new(): CSSKeyframesRule;\n};\n\ninterface CSSMediaRule extends CSSConditionRule {\n readonly media: MediaList;\n}\n\ndeclare var CSSMediaRule: {\n prototype: CSSMediaRule;\n new(): CSSMediaRule;\n};\n\ninterface CSSNamespaceRule extends CSSRule {\n readonly namespaceURI: string;\n readonly prefix: string;\n}\n\ndeclare var CSSNamespaceRule: {\n prototype: CSSNamespaceRule;\n new(): CSSNamespaceRule;\n};\n\ninterface CSSPageRule extends CSSRule {\n readonly pseudoClass: string;\n readonly selector: string;\n selectorText: string;\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSPageRule: {\n prototype: CSSPageRule;\n new(): CSSPageRule;\n};\n\ninterface CSSRule {\n cssText: string;\n readonly parentRule: CSSRule;\n readonly parentStyleSheet: CSSStyleSheet;\n readonly type: number;\n readonly CHARSET_RULE: number;\n readonly FONT_FACE_RULE: number;\n readonly IMPORT_RULE: number;\n readonly KEYFRAME_RULE: number;\n readonly KEYFRAMES_RULE: number;\n readonly MEDIA_RULE: number;\n readonly NAMESPACE_RULE: number;\n readonly PAGE_RULE: number;\n readonly STYLE_RULE: number;\n readonly SUPPORTS_RULE: number;\n readonly UNKNOWN_RULE: number;\n readonly VIEWPORT_RULE: number;\n}\n\ndeclare var CSSRule: {\n prototype: CSSRule;\n new(): CSSRule;\n readonly CHARSET_RULE: number;\n readonly FONT_FACE_RULE: number;\n readonly IMPORT_RULE: number;\n readonly KEYFRAME_RULE: number;\n readonly KEYFRAMES_RULE: number;\n readonly MEDIA_RULE: number;\n readonly NAMESPACE_RULE: number;\n readonly PAGE_RULE: number;\n readonly STYLE_RULE: number;\n readonly SUPPORTS_RULE: number;\n readonly UNKNOWN_RULE: number;\n readonly VIEWPORT_RULE: number;\n};\n\ninterface CSSRuleList {\n readonly length: number;\n item(index: number): CSSRule;\n [index: number]: CSSRule;\n}\n\ndeclare var CSSRuleList: {\n prototype: CSSRuleList;\n new(): CSSRuleList;\n};\n\ninterface CSSStyleDeclaration {\n alignContent: string | null;\n alignItems: string | null;\n alignmentBaseline: string | null;\n alignSelf: string | null;\n animation: string | null;\n animationDelay: string | null;\n animationDirection: string | null;\n animationDuration: string | null;\n animationFillMode: string | null;\n animationIterationCount: string | null;\n animationName: string | null;\n animationPlayState: string | null;\n animationTimingFunction: string | null;\n backfaceVisibility: string | null;\n background: string | null;\n backgroundAttachment: string | null;\n backgroundClip: string | null;\n backgroundColor: string | null;\n backgroundImage: string | null;\n backgroundOrigin: string | null;\n backgroundPosition: string | null;\n backgroundPositionX: string | null;\n backgroundPositionY: string | null;\n backgroundRepeat: string | null;\n backgroundSize: string | null;\n baselineShift: string | null;\n border: string | null;\n borderBottom: string | null;\n borderBottomColor: string | null;\n borderBottomLeftRadius: string | null;\n borderBottomRightRadius: string | null;\n borderBottomStyle: string | null;\n borderBottomWidth: string | null;\n borderCollapse: string | null;\n borderColor: string | null;\n borderImage: string | null;\n borderImageOutset: string | null;\n borderImageRepeat: string | null;\n borderImageSlice: string | null;\n borderImageSource: string | null;\n borderImageWidth: string | null;\n borderLeft: string | null;\n borderLeftColor: string | null;\n borderLeftStyle: string | null;\n borderLeftWidth: string | null;\n borderRadius: string | null;\n borderRight: string | null;\n borderRightColor: string | null;\n borderRightStyle: string | null;\n borderRightWidth: string | null;\n borderSpacing: string | null;\n borderStyle: string | null;\n borderTop: string | null;\n borderTopColor: string | null;\n borderTopLeftRadius: string | null;\n borderTopRightRadius: string | null;\n borderTopStyle: string | null;\n borderTopWidth: string | null;\n borderWidth: string | null;\n bottom: string | null;\n boxShadow: string | null;\n boxSizing: string | null;\n breakAfter: string | null;\n breakBefore: string | null;\n breakInside: string | null;\n captionSide: string | null;\n clear: string | null;\n clip: string | null;\n clipPath: string | null;\n clipRule: string | null;\n color: string | null;\n colorInterpolationFilters: string | null;\n columnCount: any;\n columnFill: string | null;\n columnGap: any;\n columnRule: string | null;\n columnRuleColor: any;\n columnRuleStyle: string | null;\n columnRuleWidth: any;\n columns: string | null;\n columnSpan: string | null;\n columnWidth: any;\n content: string | null;\n counterIncrement: string | null;\n counterReset: string | null;\n cssFloat: string | null;\n cssText: string;\n cursor: string | null;\n direction: string | null;\n display: string | null;\n dominantBaseline: string | null;\n emptyCells: string | null;\n enableBackground: string | null;\n fill: string | null;\n fillOpacity: string | null;\n fillRule: string | null;\n filter: string | null;\n flex: string | null;\n flexBasis: string | null;\n flexDirection: string | null;\n flexFlow: string | null;\n flexGrow: string | null;\n flexShrink: string | null;\n flexWrap: string | null;\n floodColor: string | null;\n floodOpacity: string | null;\n font: string | null;\n fontFamily: string | null;\n fontFeatureSettings: string | null;\n fontSize: string | null;\n fontSizeAdjust: string | null;\n fontStretch: string | null;\n fontStyle: string | null;\n fontVariant: string | null;\n fontWeight: string | null;\n glyphOrientationHorizontal: string | null;\n glyphOrientationVertical: string | null;\n height: string | null;\n imeMode: string | null;\n justifyContent: string | null;\n kerning: string | null;\n layoutGrid: string | null;\n layoutGridChar: string | null;\n layoutGridLine: string | null;\n layoutGridMode: string | null;\n layoutGridType: string | null;\n left: string | null;\n readonly length: number;\n letterSpacing: string | null;\n lightingColor: string | null;\n lineBreak: string | null;\n lineHeight: string | null;\n listStyle: string | null;\n listStyleImage: string | null;\n listStylePosition: string | null;\n listStyleType: string | null;\n margin: string | null;\n marginBottom: string | null;\n marginLeft: string | null;\n marginRight: string | null;\n marginTop: string | null;\n marker: string | null;\n markerEnd: string | null;\n markerMid: string | null;\n markerStart: string | null;\n mask: string | null;\n maxHeight: string | null;\n maxWidth: string | null;\n minHeight: string | null;\n minWidth: string | null;\n msContentZoomChaining: string | null;\n msContentZooming: string | null;\n msContentZoomLimit: string | null;\n msContentZoomLimitMax: any;\n msContentZoomLimitMin: any;\n msContentZoomSnap: string | null;\n msContentZoomSnapPoints: string | null;\n msContentZoomSnapType: string | null;\n msFlowFrom: string | null;\n msFlowInto: string | null;\n msFontFeatureSettings: string | null;\n msGridColumn: any;\n msGridColumnAlign: string | null;\n msGridColumns: string | null;\n msGridColumnSpan: any;\n msGridRow: any;\n msGridRowAlign: string | null;\n msGridRows: string | null;\n msGridRowSpan: any;\n msHighContrastAdjust: string | null;\n msHyphenateLimitChars: string | null;\n msHyphenateLimitLines: any;\n msHyphenateLimitZone: any;\n msHyphens: string | null;\n msImeAlign: string | null;\n msOverflowStyle: string | null;\n msScrollChaining: string | null;\n msScrollLimit: string | null;\n msScrollLimitXMax: any;\n msScrollLimitXMin: any;\n msScrollLimitYMax: any;\n msScrollLimitYMin: any;\n msScrollRails: string | null;\n msScrollSnapPointsX: string | null;\n msScrollSnapPointsY: string | null;\n msScrollSnapType: string | null;\n msScrollSnapX: string | null;\n msScrollSnapY: string | null;\n msScrollTranslation: string | null;\n msTextCombineHorizontal: string | null;\n msTextSizeAdjust: any;\n msTouchAction: string | null;\n msTouchSelect: string | null;\n msUserSelect: string | null;\n msWrapFlow: string;\n msWrapMargin: any;\n msWrapThrough: string;\n opacity: string | null;\n order: string | null;\n orphans: string | null;\n outline: string | null;\n outlineColor: string | null;\n outlineOffset: string | null;\n outlineStyle: string | null;\n outlineWidth: string | null;\n overflow: string | null;\n overflowX: string | null;\n overflowY: string | null;\n padding: string | null;\n paddingBottom: string | null;\n paddingLeft: string | null;\n paddingRight: string | null;\n paddingTop: string | null;\n pageBreakAfter: string | null;\n pageBreakBefore: string | null;\n pageBreakInside: string | null;\n readonly parentRule: CSSRule;\n perspective: string | null;\n perspectiveOrigin: string | null;\n pointerEvents: string | null;\n position: string | null;\n quotes: string | null;\n right: string | null;\n rotate: string | null;\n rubyAlign: string | null;\n rubyOverhang: string | null;\n rubyPosition: string | null;\n scale: string | null;\n stopColor: string | null;\n stopOpacity: string | null;\n stroke: string | null;\n strokeDasharray: string | null;\n strokeDashoffset: string | null;\n strokeLinecap: string | null;\n strokeLinejoin: string | null;\n strokeMiterlimit: string | null;\n strokeOpacity: string | null;\n strokeWidth: string | null;\n tableLayout: string | null;\n textAlign: string | null;\n textAlignLast: string | null;\n textAnchor: string | null;\n textDecoration: string | null;\n textIndent: string | null;\n textJustify: string | null;\n textKashida: string | null;\n textKashidaSpace: string | null;\n textOverflow: string | null;\n textShadow: string | null;\n textTransform: string | null;\n textUnderlinePosition: string | null;\n top: string | null;\n touchAction: string | null;\n transform: string | null;\n transformOrigin: string | null;\n transformStyle: string | null;\n transition: string | null;\n transitionDelay: string | null;\n transitionDuration: string | null;\n transitionProperty: string | null;\n transitionTimingFunction: string | null;\n translate: string | null;\n unicodeBidi: string | null;\n verticalAlign: string | null;\n visibility: string | null;\n webkitAlignContent: string | null;\n webkitAlignItems: string | null;\n webkitAlignSelf: string | null;\n webkitAnimation: string | null;\n webkitAnimationDelay: string | null;\n webkitAnimationDirection: string | null;\n webkitAnimationDuration: string | null;\n webkitAnimationFillMode: string | null;\n webkitAnimationIterationCount: string | null;\n webkitAnimationName: string | null;\n webkitAnimationPlayState: string | null;\n webkitAnimationTimingFunction: string | null;\n webkitAppearance: string | null;\n webkitBackfaceVisibility: string | null;\n webkitBackgroundClip: string | null;\n webkitBackgroundOrigin: string | null;\n webkitBackgroundSize: string | null;\n webkitBorderBottomLeftRadius: string | null;\n webkitBorderBottomRightRadius: string | null;\n webkitBorderImage: string | null;\n webkitBorderRadius: string | null;\n webkitBorderTopLeftRadius: string | null;\n webkitBorderTopRightRadius: string | null;\n webkitBoxAlign: string | null;\n webkitBoxDirection: string | null;\n webkitBoxFlex: string | null;\n webkitBoxOrdinalGroup: string | null;\n webkitBoxOrient: string | null;\n webkitBoxPack: string | null;\n webkitBoxSizing: string | null;\n webkitColumnBreakAfter: string | null;\n webkitColumnBreakBefore: string | null;\n webkitColumnBreakInside: string | null;\n webkitColumnCount: any;\n webkitColumnGap: any;\n webkitColumnRule: string | null;\n webkitColumnRuleColor: any;\n webkitColumnRuleStyle: string | null;\n webkitColumnRuleWidth: any;\n webkitColumns: string | null;\n webkitColumnSpan: string | null;\n webkitColumnWidth: any;\n webkitFilter: string | null;\n webkitFlex: string | null;\n webkitFlexBasis: string | null;\n webkitFlexDirection: string | null;\n webkitFlexFlow: string | null;\n webkitFlexGrow: string | null;\n webkitFlexShrink: string | null;\n webkitFlexWrap: string | null;\n webkitJustifyContent: string | null;\n webkitOrder: string | null;\n webkitPerspective: string | null;\n webkitPerspectiveOrigin: string | null;\n webkitTapHighlightColor: string | null;\n webkitTextFillColor: string | null;\n webkitTextSizeAdjust: any;\n webkitTextStroke: string | null;\n webkitTextStrokeColor: string | null;\n webkitTextStrokeWidth: string | null;\n webkitTransform: string | null;\n webkitTransformOrigin: string | null;\n webkitTransformStyle: string | null;\n webkitTransition: string | null;\n webkitTransitionDelay: string | null;\n webkitTransitionDuration: string | null;\n webkitTransitionProperty: string | null;\n webkitTransitionTimingFunction: string | null;\n webkitUserModify: string | null;\n webkitUserSelect: string | null;\n webkitWritingMode: string | null;\n whiteSpace: string | null;\n widows: string | null;\n width: string | null;\n wordBreak: string | null;\n wordSpacing: string | null;\n wordWrap: string | null;\n writingMode: string | null;\n zIndex: string | null;\n zoom: string | null;\n resize: string | null;\n userSelect: string | null;\n getPropertyPriority(propertyName: string): string;\n getPropertyValue(propertyName: string): string;\n item(index: number): string;\n removeProperty(propertyName: string): string;\n setProperty(propertyName: string, value: string | null, priority?: string): void;\n [index: number]: string;\n}\n\ndeclare var CSSStyleDeclaration: {\n prototype: CSSStyleDeclaration;\n new(): CSSStyleDeclaration;\n};\n\ninterface CSSStyleRule extends CSSRule {\n readonly readOnly: boolean;\n selectorText: string;\n readonly style: CSSStyleDeclaration;\n}\n\ndeclare var CSSStyleRule: {\n prototype: CSSStyleRule;\n new(): CSSStyleRule;\n};\n\ninterface CSSStyleSheet extends StyleSheet {\n readonly cssRules: CSSRuleList;\n cssText: string;\n readonly id: string;\n readonly imports: StyleSheetList;\n readonly isAlternate: boolean;\n readonly isPrefAlternate: boolean;\n readonly ownerRule: CSSRule;\n readonly owningElement: Element;\n readonly pages: StyleSheetPageList;\n readonly readOnly: boolean;\n readonly rules: CSSRuleList;\n addImport(bstrURL: string, lIndex?: number): number;\n addPageRule(bstrSelector: string, bstrStyle: string, lIndex?: number): number;\n addRule(bstrSelector: string, bstrStyle?: string, lIndex?: number): number;\n deleteRule(index?: number): void;\n insertRule(rule: string, index?: number): number;\n removeImport(lIndex: number): void;\n removeRule(lIndex: number): void;\n}\n\ndeclare var CSSStyleSheet: {\n prototype: CSSStyleSheet;\n new(): CSSStyleSheet;\n};\n\ninterface CSSSupportsRule extends CSSConditionRule {\n}\n\ndeclare var CSSSupportsRule: {\n prototype: CSSSupportsRule;\n new(): CSSSupportsRule;\n};\n\ninterface CustomEvent extends Event {\n readonly detail: any;\n initCustomEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, detailArg: any): void;\n}\n\ndeclare var CustomEvent: {\n prototype: CustomEvent;\n new(typeArg: string, eventInitDict?: CustomEventInit): CustomEvent;\n};\n\ninterface DataCue extends TextTrackCue {\n data: ArrayBuffer;\n addEventListener(type: K, listener: (this: DataCue, ev: TextTrackCueEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var DataCue: {\n prototype: DataCue;\n new(): DataCue;\n};\n\ninterface DataTransfer {\n dropEffect: string;\n effectAllowed: string;\n readonly files: FileList;\n readonly items: DataTransferItemList;\n readonly types: string[];\n clearData(format?: string): boolean;\n getData(format: string): string;\n setData(format: string, data: string): boolean;\n setDragImage(image: Element, x: number, y: number): void;\n}\n\ndeclare var DataTransfer: {\n prototype: DataTransfer;\n new(): DataTransfer;\n};\n\ninterface DataTransferItem {\n readonly kind: string;\n readonly type: string;\n getAsFile(): File | null;\n getAsString(_callback: FunctionStringCallback | null): void;\n webkitGetAsEntry(): any;\n}\n\ndeclare var DataTransferItem: {\n prototype: DataTransferItem;\n new(): DataTransferItem;\n};\n\ninterface DataTransferItemList {\n readonly length: number;\n add(data: File): DataTransferItem | null;\n clear(): void;\n item(index: number): DataTransferItem;\n remove(index: number): void;\n [index: number]: DataTransferItem;\n}\n\ndeclare var DataTransferItemList: {\n prototype: DataTransferItemList;\n new(): DataTransferItemList;\n};\n\ninterface DeferredPermissionRequest {\n readonly id: number;\n readonly type: MSWebViewPermissionType;\n readonly uri: string;\n allow(): void;\n deny(): void;\n}\n\ndeclare var DeferredPermissionRequest: {\n prototype: DeferredPermissionRequest;\n new(): DeferredPermissionRequest;\n};\n\ninterface DelayNode extends AudioNode {\n readonly delayTime: AudioParam;\n}\n\ndeclare var DelayNode: {\n prototype: DelayNode;\n new(): DelayNode;\n};\n\ninterface DeviceAcceleration {\n readonly x: number | null;\n readonly y: number | null;\n readonly z: number | null;\n}\n\ndeclare var DeviceAcceleration: {\n prototype: DeviceAcceleration;\n new(): DeviceAcceleration;\n};\n\ninterface DeviceLightEvent extends Event {\n readonly value: number;\n}\n\ndeclare var DeviceLightEvent: {\n prototype: DeviceLightEvent;\n new(typeArg: string, eventInitDict?: DeviceLightEventInit): DeviceLightEvent;\n};\n\ninterface DeviceMotionEvent extends Event {\n readonly acceleration: DeviceAcceleration | null;\n readonly accelerationIncludingGravity: DeviceAcceleration | null;\n readonly interval: number | null;\n readonly rotationRate: DeviceRotationRate | null;\n initDeviceMotionEvent(type: string, bubbles: boolean, cancelable: boolean, acceleration: DeviceAccelerationDict | null, accelerationIncludingGravity: DeviceAccelerationDict | null, rotationRate: DeviceRotationRateDict | null, interval: number | null): void;\n}\n\ndeclare var DeviceMotionEvent: {\n prototype: DeviceMotionEvent;\n new(typeArg: string, eventInitDict?: DeviceMotionEventInit): DeviceMotionEvent;\n};\n\ninterface DeviceOrientationEvent extends Event {\n readonly absolute: boolean;\n readonly alpha: number | null;\n readonly beta: number | null;\n readonly gamma: number | null;\n initDeviceOrientationEvent(type: string, bubbles: boolean, cancelable: boolean, alpha: number | null, beta: number | null, gamma: number | null, absolute: boolean): void;\n}\n\ndeclare var DeviceOrientationEvent: {\n prototype: DeviceOrientationEvent;\n new(typeArg: string, eventInitDict?: DeviceOrientationEventInit): DeviceOrientationEvent;\n};\n\ninterface DeviceRotationRate {\n readonly alpha: number | null;\n readonly beta: number | null;\n readonly gamma: number | null;\n}\n\ndeclare var DeviceRotationRate: {\n prototype: DeviceRotationRate;\n new(): DeviceRotationRate;\n};\n\ninterface DocumentEventMap extends GlobalEventHandlersEventMap {\n \"abort\": UIEvent;\n \"activate\": UIEvent;\n \"beforeactivate\": UIEvent;\n \"beforedeactivate\": UIEvent;\n \"blur\": FocusEvent;\n \"canplay\": Event;\n \"canplaythrough\": Event;\n \"change\": Event;\n \"click\": MouseEvent;\n \"contextmenu\": PointerEvent;\n \"dblclick\": MouseEvent;\n \"deactivate\": UIEvent;\n \"drag\": DragEvent;\n \"dragend\": DragEvent;\n \"dragenter\": DragEvent;\n \"dragleave\": DragEvent;\n \"dragover\": DragEvent;\n \"dragstart\": DragEvent;\n \"drop\": DragEvent;\n \"durationchange\": Event;\n \"emptied\": Event;\n \"ended\": MediaStreamErrorEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"fullscreenchange\": Event;\n \"fullscreenerror\": Event;\n \"input\": Event;\n \"invalid\": Event;\n \"keydown\": KeyboardEvent;\n \"keypress\": KeyboardEvent;\n \"keyup\": KeyboardEvent;\n \"load\": Event;\n \"loadeddata\": Event;\n \"loadedmetadata\": Event;\n \"loadstart\": Event;\n \"mousedown\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n \"mousewheel\": WheelEvent;\n \"MSContentZoom\": UIEvent;\n \"MSGestureChange\": MSGestureEvent;\n \"MSGestureDoubleTap\": MSGestureEvent;\n \"MSGestureEnd\": MSGestureEvent;\n \"MSGestureHold\": MSGestureEvent;\n \"MSGestureStart\": MSGestureEvent;\n \"MSGestureTap\": MSGestureEvent;\n \"MSInertiaStart\": MSGestureEvent;\n \"MSManipulationStateChanged\": MSManipulationEvent;\n \"MSPointerCancel\": MSPointerEvent;\n \"MSPointerDown\": MSPointerEvent;\n \"MSPointerEnter\": MSPointerEvent;\n \"MSPointerLeave\": MSPointerEvent;\n \"MSPointerMove\": MSPointerEvent;\n \"MSPointerOut\": MSPointerEvent;\n \"MSPointerOver\": MSPointerEvent;\n \"MSPointerUp\": MSPointerEvent;\n \"mssitemodejumplistitemremoved\": MSSiteModeEvent;\n \"msthumbnailclick\": MSSiteModeEvent;\n \"pause\": Event;\n \"play\": Event;\n \"playing\": Event;\n \"pointerlockchange\": Event;\n \"pointerlockerror\": Event;\n \"progress\": ProgressEvent;\n \"ratechange\": Event;\n \"readystatechange\": Event;\n \"reset\": Event;\n \"scroll\": UIEvent;\n \"seeked\": Event;\n \"seeking\": Event;\n \"select\": UIEvent;\n \"selectionchange\": Event;\n \"selectstart\": Event;\n \"stalled\": Event;\n \"stop\": Event;\n \"submit\": Event;\n \"suspend\": Event;\n \"timeupdate\": Event;\n \"touchcancel\": TouchEvent;\n \"touchend\": TouchEvent;\n \"touchmove\": TouchEvent;\n \"touchstart\": TouchEvent;\n \"volumechange\": Event;\n \"waiting\": Event;\n \"webkitfullscreenchange\": Event;\n \"webkitfullscreenerror\": Event;\n}\n\ninterface Document extends Node, GlobalEventHandlers, NodeSelector, DocumentEvent, ParentNode, DocumentOrShadowRoot {\n /**\n * Gets the object that has the focus when the parent document has focus.\n */\n readonly activeElement: Element;\n /**\n * Sets or gets the color of all active links in the document.\n */\n alinkColor: string;\n /**\n * Returns a reference to the collection of elements contained by the object.\n */\n readonly all: HTMLAllCollection;\n /**\n * Retrieves a collection of all a objects that have a name and/or id property. Objects in this collection are in HTML source order.\n */\n anchors: HTMLCollectionOf;\n /**\n * Retrieves a collection of all applet objects in the document.\n */\n applets: HTMLCollectionOf;\n /**\n * Deprecated. Sets or retrieves a value that indicates the background color behind the object.\n */\n bgColor: string;\n /**\n * Specifies the beginning and end of the document body.\n */\n body: HTMLElement;\n readonly characterSet: string;\n /**\n * Gets or sets the character set used to encode the object.\n */\n charset: string;\n /**\n * Gets a value that indicates whether standards-compliant mode is switched on for the object.\n */\n readonly compatMode: string;\n cookie: string;\n readonly currentScript: HTMLScriptElement | SVGScriptElement;\n readonly defaultView: Window;\n /**\n * Sets or gets a value that indicates whether the document can be edited.\n */\n designMode: string;\n /**\n * Sets or retrieves a value that indicates the reading order of the object.\n */\n dir: string;\n /**\n * Gets an object representing the document type declaration associated with the current document.\n */\n readonly doctype: DocumentType;\n /**\n * Gets a reference to the root node of the document.\n */\n documentElement: HTMLElement;\n /**\n * Sets or gets the security domain of the document.\n */\n domain: string;\n /**\n * Retrieves a collection of all embed objects in the document.\n */\n embeds: HTMLCollectionOf;\n /**\n * Sets or gets the foreground (text) color of the document.\n */\n fgColor: string;\n /**\n * Retrieves a collection, in source order, of all form objects in the document.\n */\n forms: HTMLCollectionOf;\n readonly fullscreenElement: Element | null;\n readonly fullscreenEnabled: boolean;\n readonly head: HTMLHeadElement;\n readonly hidden: boolean;\n /**\n * Retrieves a collection, in source order, of img objects in the document.\n */\n images: HTMLCollectionOf;\n /**\n * Gets the implementation object of the current document.\n */\n readonly implementation: DOMImplementation;\n /**\n * Returns the character encoding used to create the webpage that is loaded into the document object.\n */\n readonly inputEncoding: string | null;\n /**\n * Gets the date that the page was last modified, if the page supplies one.\n */\n readonly lastModified: string;\n /**\n * Sets or gets the color of the document links.\n */\n linkColor: string;\n /**\n * Retrieves a collection of all a objects that specify the href property and all area objects in the document.\n */\n links: HTMLCollectionOf;\n /**\n * Contains information about the current URL.\n */\n readonly location: Location;\n msCapsLockWarningOff: boolean;\n msCSSOMElementFloatMetrics: boolean;\n /**\n * Fires when the user aborts the download.\n * @param ev The event.\n */\n onabort: (this: Document, ev: UIEvent) => any;\n /**\n * Fires when the object is set as the active element.\n * @param ev The event.\n */\n onactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires immediately before the object is set as the active element.\n * @param ev The event.\n */\n onbeforeactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires immediately before the activeElement is changed from the current object to another object in the parent document.\n * @param ev The event.\n */\n onbeforedeactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires when the object loses the input focus.\n * @param ev The focus event.\n */\n onblur: (this: Document, ev: FocusEvent) => any;\n /**\n * Occurs when playback is possible, but would require further buffering.\n * @param ev The event.\n */\n oncanplay: (this: Document, ev: Event) => any;\n oncanplaythrough: (this: Document, ev: Event) => any;\n /**\n * Fires when the contents of the object or selection have changed.\n * @param ev The event.\n */\n onchange: (this: Document, ev: Event) => any;\n /**\n * Fires when the user clicks the left mouse button on the object\n * @param ev The mouse event.\n */\n onclick: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user clicks the right mouse button in the client area, opening the context menu.\n * @param ev The mouse event.\n */\n oncontextmenu: (this: Document, ev: PointerEvent) => any;\n /**\n * Fires when the user double-clicks the object.\n * @param ev The mouse event.\n */\n ondblclick: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the activeElement is changed from the current object to another object in the parent document.\n * @param ev The UI Event\n */\n ondeactivate: (this: Document, ev: UIEvent) => any;\n /**\n * Fires on the source object continuously during a drag operation.\n * @param ev The event.\n */\n ondrag: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the source object when the user releases the mouse at the close of a drag operation.\n * @param ev The event.\n */\n ondragend: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the target element when the user drags the object to a valid drop target.\n * @param ev The drag event.\n */\n ondragenter: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the target object when the user moves the mouse out of a valid drop target during a drag operation.\n * @param ev The drag event.\n */\n ondragleave: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the target element continuously while the user drags the object over a valid drop target.\n * @param ev The event.\n */\n ondragover: (this: Document, ev: DragEvent) => any;\n /**\n * Fires on the source object when the user starts to drag a text selection or selected object.\n * @param ev The event.\n */\n ondragstart: (this: Document, ev: DragEvent) => any;\n ondrop: (this: Document, ev: DragEvent) => any;\n /**\n * Occurs when the duration attribute is updated.\n * @param ev The event.\n */\n ondurationchange: (this: Document, ev: Event) => any;\n /**\n * Occurs when the media element is reset to its initial state.\n * @param ev The event.\n */\n onemptied: (this: Document, ev: Event) => any;\n /**\n * Occurs when the end of playback is reached.\n * @param ev The event\n */\n onended: (this: Document, ev: MediaStreamErrorEvent) => any;\n /**\n * Fires when an error occurs during object loading.\n * @param ev The event.\n */\n onerror: (this: Document, ev: ErrorEvent) => any;\n /**\n * Fires when the object receives focus.\n * @param ev The event.\n */\n onfocus: (this: Document, ev: FocusEvent) => any;\n onfullscreenchange: (this: Document, ev: Event) => any;\n onfullscreenerror: (this: Document, ev: Event) => any;\n oninput: (this: Document, ev: Event) => any;\n oninvalid: (this: Document, ev: Event) => any;\n /**\n * Fires when the user presses a key.\n * @param ev The keyboard event\n */\n onkeydown: (this: Document, ev: KeyboardEvent) => any;\n /**\n * Fires when the user presses an alphanumeric key.\n * @param ev The event.\n */\n onkeypress: (this: Document, ev: KeyboardEvent) => any;\n /**\n * Fires when the user releases a key.\n * @param ev The keyboard event\n */\n onkeyup: (this: Document, ev: KeyboardEvent) => any;\n /**\n * Fires immediately after the browser loads the object.\n * @param ev The event.\n */\n onload: (this: Document, ev: Event) => any;\n /**\n * Occurs when media data is loaded at the current playback position.\n * @param ev The event.\n */\n onloadeddata: (this: Document, ev: Event) => any;\n /**\n * Occurs when the duration and dimensions of the media have been determined.\n * @param ev The event.\n */\n onloadedmetadata: (this: Document, ev: Event) => any;\n /**\n * Occurs when Internet Explorer begins looking for media data.\n * @param ev The event.\n */\n onloadstart: (this: Document, ev: Event) => any;\n /**\n * Fires when the user clicks the object with either mouse button.\n * @param ev The mouse event.\n */\n onmousedown: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user moves the mouse over the object.\n * @param ev The mouse event.\n */\n onmousemove: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user moves the mouse pointer outside the boundaries of the object.\n * @param ev The mouse event.\n */\n onmouseout: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user moves the mouse pointer into the object.\n * @param ev The mouse event.\n */\n onmouseover: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the user releases a mouse button while the mouse is over the object.\n * @param ev The mouse event.\n */\n onmouseup: (this: Document, ev: MouseEvent) => any;\n /**\n * Fires when the wheel button is rotated.\n * @param ev The mouse event\n */\n onmousewheel: (this: Document, ev: WheelEvent) => any;\n onmscontentzoom: (this: Document, ev: UIEvent) => any;\n onmsgesturechange: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturedoubletap: (this: Document, ev: MSGestureEvent) => any;\n onmsgestureend: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturehold: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturestart: (this: Document, ev: MSGestureEvent) => any;\n onmsgesturetap: (this: Document, ev: MSGestureEvent) => any;\n onmsinertiastart: (this: Document, ev: MSGestureEvent) => any;\n onmsmanipulationstatechanged: (this: Document, ev: MSManipulationEvent) => any;\n onmspointercancel: (this: Document, ev: MSPointerEvent) => any;\n onmspointerdown: (this: Document, ev: MSPointerEvent) => any;\n onmspointerenter: (this: Document, ev: MSPointerEvent) => any;\n onmspointerleave: (this: Document, ev: MSPointerEvent) => any;\n onmspointermove: (this: Document, ev: MSPointerEvent) => any;\n onmspointerout: (this: Document, ev: MSPointerEvent) => any;\n onmspointerover: (this: Document, ev: MSPointerEvent) => any;\n onmspointerup: (this: Document, ev: MSPointerEvent) => any;\n /**\n * Occurs when an item is removed from a Jump List of a webpage running in Site Mode.\n * @param ev The event.\n */\n onmssitemodejumplistitemremoved: (this: Document, ev: MSSiteModeEvent) => any;\n /**\n * Occurs when a user clicks a button in a Thumbnail Toolbar of a webpage running in Site Mode.\n * @param ev The event.\n */\n onmsthumbnailclick: (this: Document, ev: MSSiteModeEvent) => any;\n /**\n * Occurs when playback is paused.\n * @param ev The event.\n */\n onpause: (this: Document, ev: Event) => any;\n /**\n * Occurs when the play method is requested.\n * @param ev The event.\n */\n onplay: (this: Document, ev: Event) => any;\n /**\n * Occurs when the audio or video has started playing.\n * @param ev The event.\n */\n onplaying: (this: Document, ev: Event) => any;\n onpointerlockchange: (this: Document, ev: Event) => any;\n onpointerlockerror: (this: Document, ev: Event) => any;\n /**\n * Occurs to indicate progress while downloading media data.\n * @param ev The event.\n */\n onprogress: (this: Document, ev: ProgressEvent) => any;\n /**\n * Occurs when the playback rate is increased or decreased.\n * @param ev The event.\n */\n onratechange: (this: Document, ev: Event) => any;\n /**\n * Fires when the state of the object has changed.\n * @param ev The event\n */\n onreadystatechange: (this: Document, ev: Event) => any;\n /**\n * Fires when the user resets a form.\n * @param ev The event.\n */\n onreset: (this: Document, ev: Event) => any;\n /**\n * Fires when the user repositions the scroll box in the scroll bar on the object.\n * @param ev The event.\n */\n onscroll: (this: Document, ev: UIEvent) => any;\n /**\n * Occurs when the seek operation ends.\n * @param ev The event.\n */\n onseeked: (this: Document, ev: Event) => any;\n /**\n * Occurs when the current playback position is moved.\n * @param ev The event.\n */\n onseeking: (this: Document, ev: Event) => any;\n /**\n * Fires when the current selection changes.\n * @param ev The event.\n */\n onselect: (this: Document, ev: UIEvent) => any;\n /**\n * Fires when the selection state of a document changes.\n * @param ev The event.\n */\n onselectionchange: (this: Document, ev: Event) => any;\n onselectstart: (this: Document, ev: Event) => any;\n /**\n * Occurs when the download has stopped.\n * @param ev The event.\n */\n onstalled: (this: Document, ev: Event) => any;\n /**\n * Fires when the user clicks the Stop button or leaves the Web page.\n * @param ev The event.\n */\n onstop: (this: Document, ev: Event) => any;\n onsubmit: (this: Document, ev: Event) => any;\n /**\n * Occurs if the load operation has been intentionally halted.\n * @param ev The event.\n */\n onsuspend: (this: Document, ev: Event) => any;\n /**\n * Occurs to indicate the current playback position.\n * @param ev The event.\n */\n ontimeupdate: (this: Document, ev: Event) => any;\n ontouchcancel: (ev: TouchEvent) => any;\n ontouchend: (ev: TouchEvent) => any;\n ontouchmove: (ev: TouchEvent) => any;\n ontouchstart: (ev: TouchEvent) => any;\n /**\n * Occurs when the volume is changed, or playback is muted or unmuted.\n * @param ev The event.\n */\n onvolumechange: (this: Document, ev: Event) => any;\n /**\n * Occurs when playback stops because the next frame of a video resource is not available.\n * @param ev The event.\n */\n onwaiting: (this: Document, ev: Event) => any;\n onwebkitfullscreenchange: (this: Document, ev: Event) => any;\n onwebkitfullscreenerror: (this: Document, ev: Event) => any;\n plugins: HTMLCollectionOf;\n readonly pointerLockElement: Element;\n /**\n * Retrieves a value that indicates the current state of the object.\n */\n readonly readyState: string;\n /**\n * Gets the URL of the location that referred the user to the current page.\n */\n readonly referrer: string;\n /**\n * Gets the root svg element in the document hierarchy.\n */\n readonly rootElement: SVGSVGElement;\n /**\n * Retrieves a collection of all script objects in the document.\n */\n scripts: HTMLCollectionOf;\n readonly scrollingElement: Element | null;\n /**\n * Retrieves a collection of styleSheet objects representing the style sheets that correspond to each instance of a link or style object in the document.\n */\n readonly styleSheets: StyleSheetList;\n /**\n * Contains the title of the document.\n */\n title: string;\n /**\n * Sets or gets the URL for the current document.\n */\n readonly URL: string;\n /**\n * Gets the URL for the document, stripped of any character encoding.\n */\n readonly URLUnencoded: string;\n readonly visibilityState: VisibilityState;\n /**\n * Sets or gets the color of the links that the user has visited.\n */\n vlinkColor: string;\n readonly webkitCurrentFullScreenElement: Element | null;\n readonly webkitFullscreenElement: Element | null;\n readonly webkitFullscreenEnabled: boolean;\n readonly webkitIsFullScreen: boolean;\n readonly xmlEncoding: string | null;\n xmlStandalone: boolean;\n /**\n * Gets or sets the version attribute specified in the declaration of an XML document.\n */\n xmlVersion: string | null;\n adoptNode(source: T): T;\n captureEvents(): void;\n caretRangeFromPoint(x: number, y: number): Range;\n clear(): void;\n /**\n * Closes an output stream and forces the sent data to display.\n */\n close(): void;\n /**\n * Creates an attribute object with a specified name.\n * @param name String that sets the attribute object's name.\n */\n createAttribute(name: string): Attr;\n createAttributeNS(namespaceURI: string | null, qualifiedName: string): Attr;\n createCDATASection(data: string): CDATASection;\n /**\n * Creates a comment object with the specified data.\n * @param data Sets the comment object's data.\n */\n createComment(data: string): Comment;\n /**\n * Creates a new document.\n */\n createDocumentFragment(): DocumentFragment;\n /**\n * Creates an instance of the element for the specified tag.\n * @param tagName The name of an element.\n */\n createElement(tagName: K): HTMLElementTagNameMap[K];\n createElement(tagName: string): HTMLElement;\n createElementNS(namespaceURI: \"http://www.w3.org/1999/xhtml\", qualifiedName: string): HTMLElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"a\"): SVGAElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"circle\"): SVGCircleElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"clipPath\"): SVGClipPathElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"componentTransferFunction\"): SVGComponentTransferFunctionElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"defs\"): SVGDefsElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"desc\"): SVGDescElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"ellipse\"): SVGEllipseElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feBlend\"): SVGFEBlendElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feColorMatrix\"): SVGFEColorMatrixElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feComponentTransfer\"): SVGFEComponentTransferElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feComposite\"): SVGFECompositeElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feConvolveMatrix\"): SVGFEConvolveMatrixElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feDiffuseLighting\"): SVGFEDiffuseLightingElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feDisplacementMap\"): SVGFEDisplacementMapElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feDistantLight\"): SVGFEDistantLightElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFlood\"): SVGFEFloodElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncA\"): SVGFEFuncAElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncB\"): SVGFEFuncBElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncG\"): SVGFEFuncGElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feFuncR\"): SVGFEFuncRElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feGaussianBlur\"): SVGFEGaussianBlurElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feImage\"): SVGFEImageElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feMerge\"): SVGFEMergeElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feMergeNode\"): SVGFEMergeNodeElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feMorphology\"): SVGFEMorphologyElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feOffset\"): SVGFEOffsetElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"fePointLight\"): SVGFEPointLightElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feSpecularLighting\"): SVGFESpecularLightingElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feSpotLight\"): SVGFESpotLightElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feTile\"): SVGFETileElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"feTurbulence\"): SVGFETurbulenceElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"filter\"): SVGFilterElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"foreignObject\"): SVGForeignObjectElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"g\"): SVGGElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"image\"): SVGImageElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"gradient\"): SVGGradientElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"line\"): SVGLineElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"linearGradient\"): SVGLinearGradientElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"marker\"): SVGMarkerElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"mask\"): SVGMaskElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"path\"): SVGPathElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"metadata\"): SVGMetadataElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"pattern\"): SVGPatternElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"polygon\"): SVGPolygonElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"polyline\"): SVGPolylineElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"radialGradient\"): SVGRadialGradientElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"rect\"): SVGRectElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"svg\"): SVGSVGElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"script\"): SVGScriptElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"stop\"): SVGStopElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"style\"): SVGStyleElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"switch\"): SVGSwitchElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"symbol\"): SVGSymbolElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"tspan\"): SVGTSpanElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"textContent\"): SVGTextContentElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"text\"): SVGTextElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"textPath\"): SVGTextPathElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"textPositioning\"): SVGTextPositioningElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"title\"): SVGTitleElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"use\"): SVGUseElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: \"view\"): SVGViewElement;\n createElementNS(namespaceURI: \"http://www.w3.org/2000/svg\", qualifiedName: string): SVGElement;\n createElementNS(namespaceURI: string | null, qualifiedName: string): Element;\n createExpression(expression: string, resolver: XPathNSResolver): XPathExpression;\n /**\n * Creates a NodeIterator object that you can use to traverse filtered lists of nodes or elements in a document.\n * @param root The root element or node to start traversing on.\n * @param whatToShow The type of nodes or elements to appear in the node list\n * @param filter A custom NodeFilter function to use. For more information, see filter. Use null for no filter.\n * @param entityReferenceExpansion A flag that specifies whether entity reference nodes are expanded.\n */\n createNodeIterator(root: Node, whatToShow?: number, filter?: NodeFilter, entityReferenceExpansion?: boolean): NodeIterator;\n createNSResolver(nodeResolver: Node): XPathNSResolver;\n createProcessingInstruction(target: string, data: string): ProcessingInstruction;\n /**\n * Returns an empty range object that has both of its boundary points positioned at the beginning of the document.\n */\n createRange(): Range;\n /**\n * Creates a text string from the specified value.\n * @param data String that specifies the nodeValue property of the text node.\n */\n createTextNode(data: string): Text;\n createTouch(view: Window, target: EventTarget, identifier: number, pageX: number, pageY: number, screenX: number, screenY: number): Touch;\n createTouchList(...touches: Touch[]): TouchList;\n /**\n * Creates a TreeWalker object that you can use to traverse filtered lists of nodes or elements in a document.\n * @param root The root element or node to start traversing on.\n * @param whatToShow The type of nodes or elements to appear in the node list. For more information, see whatToShow.\n * @param filter A custom NodeFilter function to use.\n * @param entityReferenceExpansion A flag that specifies whether entity reference nodes are expanded.\n */\n createTreeWalker(root: Node, whatToShow?: number, filter?: NodeFilter, entityReferenceExpansion?: boolean): TreeWalker;\n /**\n * Returns the element for the specified x coordinate and the specified y coordinate.\n * @param x The x-offset\n * @param y The y-offset\n */\n elementFromPoint(x: number, y: number): Element;\n evaluate(expression: string, contextNode: Node, resolver: XPathNSResolver | null, type: number, result: XPathResult | null): XPathResult;\n /**\n * Executes a command on the current document, current selection, or the given range.\n * @param commandId String that specifies the command to execute. This command can be any of the command identifiers that can be executed in script.\n * @param showUI Display the user interface, defaults to false.\n * @param value Value to assign.\n */\n execCommand(commandId: string, showUI?: boolean, value?: any): boolean;\n /**\n * Displays help information for the given command identifier.\n * @param commandId Displays help information for the given command identifier.\n */\n execCommandShowHelp(commandId: string): boolean;\n exitFullscreen(): void;\n exitPointerLock(): void;\n /**\n * Causes the element to receive the focus and executes the code specified by the onfocus event.\n */\n focus(): void;\n /**\n * Returns a reference to the first object with the specified value of the ID or NAME attribute.\n * @param elementId String that specifies the ID value. Case-insensitive.\n */\n getElementById(elementId: string): HTMLElement | null;\n getElementsByClassName(classNames: string): HTMLCollectionOf;\n /**\n * Gets a collection of objects based on the value of the NAME or ID attribute.\n * @param elementName Gets a collection of objects based on the value of the NAME or ID attribute.\n */\n getElementsByName(elementName: string): NodeListOf;\n /**\n * Retrieves a collection of objects based on the specified element name.\n * @param name Specifies the name of an element.\n */\n getElementsByTagName(tagname: K): ElementListTagNameMap[K];\n getElementsByTagName(tagname: string): NodeListOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/1999/xhtml\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/2000/svg\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: string, localName: string): HTMLCollectionOf;\n /**\n * Returns an object representing the current selection of the document that is loaded into the object displaying a webpage.\n */\n getSelection(): Selection;\n /**\n * Gets a value indicating whether the object currently has focus.\n */\n hasFocus(): boolean;\n importNode(importedNode: T, deep: boolean): T;\n msElementsFromPoint(x: number, y: number): NodeListOf;\n msElementsFromRect(left: number, top: number, width: number, height: number): NodeListOf;\n /**\n * Opens a new window and loads a document specified by a given URL. Also, opens a new window that uses the url parameter and the name parameter to collect the output of the write method and the writeln method.\n * @param url Specifies a MIME type for the document.\n * @param name Specifies the name of the window. This name is used as the value for the TARGET attribute on a form or an anchor element.\n * @param features Contains a list of items separated by commas. Each item consists of an option and a value, separated by an equals sign (for example, \"fullscreen=yes, toolbar=yes\"). The following values are supported.\n * @param replace Specifies whether the existing entry for the document is replaced in the history list.\n */\n open(url?: string, name?: string, features?: string, replace?: boolean): Document;\n /**\n * Returns a Boolean value that indicates whether a specified command can be successfully executed using execCommand, given the current state of the document.\n * @param commandId Specifies a command identifier.\n */\n queryCommandEnabled(commandId: string): boolean;\n /**\n * Returns a Boolean value that indicates whether the specified command is in the indeterminate state.\n * @param commandId String that specifies a command identifier.\n */\n queryCommandIndeterm(commandId: string): boolean;\n /**\n * Returns a Boolean value that indicates the current state of the command.\n * @param commandId String that specifies a command identifier.\n */\n queryCommandState(commandId: string): boolean;\n /**\n * Returns a Boolean value that indicates whether the current command is supported on the current range.\n * @param commandId Specifies a command identifier.\n */\n queryCommandSupported(commandId: string): boolean;\n /**\n * Retrieves the string associated with a command.\n * @param commandId String that contains the identifier of a command. This can be any command identifier given in the list of Command Identifiers.\n */\n queryCommandText(commandId: string): string;\n /**\n * Returns the current value of the document, range, or current selection for the given command.\n * @param commandId String that specifies a command identifier.\n */\n queryCommandValue(commandId: string): string;\n releaseEvents(): void;\n /**\n * Allows updating the print settings for the page.\n */\n updateSettings(): void;\n webkitCancelFullScreen(): void;\n webkitExitFullscreen(): void;\n /**\n * Writes one or more HTML expressions to a document in the specified window.\n * @param content Specifies the text and HTML tags to write.\n */\n write(...content: string[]): void;\n /**\n * Writes one or more HTML expressions, followed by a carriage return, to a document in the specified window.\n * @param content The text and HTML tags to write.\n */\n writeln(...content: string[]): void;\n addEventListener(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Document: {\n prototype: Document;\n new(): Document;\n};\n\ninterface DocumentFragment extends Node, NodeSelector, ParentNode {\n getElementById(elementId: string): HTMLElement | null;\n}\n\ndeclare var DocumentFragment: {\n prototype: DocumentFragment;\n new(): DocumentFragment;\n};\n\ninterface DocumentType extends Node, ChildNode {\n readonly entities: NamedNodeMap;\n readonly internalSubset: string | null;\n readonly name: string;\n readonly notations: NamedNodeMap;\n readonly publicId: string;\n readonly systemId: string;\n}\n\ndeclare var DocumentType: {\n prototype: DocumentType;\n new(): DocumentType;\n};\n\ninterface DOMError {\n readonly name: string;\n toString(): string;\n}\n\ndeclare var DOMError: {\n prototype: DOMError;\n new(): DOMError;\n};\n\ninterface DOMException {\n readonly code: number;\n readonly message: string;\n readonly name: string;\n toString(): string;\n readonly ABORT_ERR: number;\n readonly DATA_CLONE_ERR: number;\n readonly DOMSTRING_SIZE_ERR: number;\n readonly HIERARCHY_REQUEST_ERR: number;\n readonly INDEX_SIZE_ERR: number;\n readonly INUSE_ATTRIBUTE_ERR: number;\n readonly INVALID_ACCESS_ERR: number;\n readonly INVALID_CHARACTER_ERR: number;\n readonly INVALID_MODIFICATION_ERR: number;\n readonly INVALID_NODE_TYPE_ERR: number;\n readonly INVALID_STATE_ERR: number;\n readonly NAMESPACE_ERR: number;\n readonly NETWORK_ERR: number;\n readonly NO_DATA_ALLOWED_ERR: number;\n readonly NO_MODIFICATION_ALLOWED_ERR: number;\n readonly NOT_FOUND_ERR: number;\n readonly NOT_SUPPORTED_ERR: number;\n readonly PARSE_ERR: number;\n readonly QUOTA_EXCEEDED_ERR: number;\n readonly SECURITY_ERR: number;\n readonly SERIALIZE_ERR: number;\n readonly SYNTAX_ERR: number;\n readonly TIMEOUT_ERR: number;\n readonly TYPE_MISMATCH_ERR: number;\n readonly URL_MISMATCH_ERR: number;\n readonly VALIDATION_ERR: number;\n readonly WRONG_DOCUMENT_ERR: number;\n}\n\ndeclare var DOMException: {\n prototype: DOMException;\n new(): DOMException;\n readonly ABORT_ERR: number;\n readonly DATA_CLONE_ERR: number;\n readonly DOMSTRING_SIZE_ERR: number;\n readonly HIERARCHY_REQUEST_ERR: number;\n readonly INDEX_SIZE_ERR: number;\n readonly INUSE_ATTRIBUTE_ERR: number;\n readonly INVALID_ACCESS_ERR: number;\n readonly INVALID_CHARACTER_ERR: number;\n readonly INVALID_MODIFICATION_ERR: number;\n readonly INVALID_NODE_TYPE_ERR: number;\n readonly INVALID_STATE_ERR: number;\n readonly NAMESPACE_ERR: number;\n readonly NETWORK_ERR: number;\n readonly NO_DATA_ALLOWED_ERR: number;\n readonly NO_MODIFICATION_ALLOWED_ERR: number;\n readonly NOT_FOUND_ERR: number;\n readonly NOT_SUPPORTED_ERR: number;\n readonly PARSE_ERR: number;\n readonly QUOTA_EXCEEDED_ERR: number;\n readonly SECURITY_ERR: number;\n readonly SERIALIZE_ERR: number;\n readonly SYNTAX_ERR: number;\n readonly TIMEOUT_ERR: number;\n readonly TYPE_MISMATCH_ERR: number;\n readonly URL_MISMATCH_ERR: number;\n readonly VALIDATION_ERR: number;\n readonly WRONG_DOCUMENT_ERR: number;\n};\n\ninterface DOMImplementation {\n createDocument(namespaceURI: string | null, qualifiedName: string | null, doctype: DocumentType | null): Document;\n createDocumentType(qualifiedName: string, publicId: string, systemId: string): DocumentType;\n createHTMLDocument(title: string): Document;\n hasFeature(feature: string | null, version: string | null): boolean;\n}\n\ndeclare var DOMImplementation: {\n prototype: DOMImplementation;\n new(): DOMImplementation;\n};\n\ninterface DOMParser {\n parseFromString(source: string, mimeType: string): Document;\n}\n\ndeclare var DOMParser: {\n prototype: DOMParser;\n new(): DOMParser;\n};\n\ninterface DOMSettableTokenList extends DOMTokenList {\n value: string;\n}\n\ndeclare var DOMSettableTokenList: {\n prototype: DOMSettableTokenList;\n new(): DOMSettableTokenList;\n};\n\ninterface DOMStringList {\n readonly length: number;\n contains(str: string): boolean;\n item(index: number): string | null;\n [index: number]: string;\n}\n\ndeclare var DOMStringList: {\n prototype: DOMStringList;\n new(): DOMStringList;\n};\n\ninterface DOMStringMap {\n [name: string]: string | undefined;\n}\n\ndeclare var DOMStringMap: {\n prototype: DOMStringMap;\n new(): DOMStringMap;\n};\n\ninterface DOMTokenList {\n readonly length: number;\n add(...token: string[]): void;\n contains(token: string): boolean;\n item(index: number): string;\n remove(...token: string[]): void;\n toggle(token: string, force?: boolean): boolean;\n toString(): string;\n [index: number]: string;\n}\n\ndeclare var DOMTokenList: {\n prototype: DOMTokenList;\n new(): DOMTokenList;\n};\n\ninterface DragEvent extends MouseEvent {\n readonly dataTransfer: DataTransfer;\n initDragEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget, dataTransferArg: DataTransfer): void;\n msConvertURL(file: File, targetType: string, targetURL?: string): void;\n}\n\ndeclare var DragEvent: {\n prototype: DragEvent;\n new(type: \"drag\" | \"dragend\" | \"dragenter\" | \"dragexit\" | \"dragleave\" | \"dragover\" | \"dragstart\" | \"drop\", dragEventInit?: { dataTransfer?: DataTransfer }): DragEvent;\n};\n\ninterface DynamicsCompressorNode extends AudioNode {\n readonly attack: AudioParam;\n readonly knee: AudioParam;\n readonly ratio: AudioParam;\n readonly reduction: number;\n readonly release: AudioParam;\n readonly threshold: AudioParam;\n}\n\ndeclare var DynamicsCompressorNode: {\n prototype: DynamicsCompressorNode;\n new(): DynamicsCompressorNode;\n};\n\ninterface ElementEventMap extends GlobalEventHandlersEventMap {\n \"ariarequest\": Event;\n \"command\": Event;\n \"gotpointercapture\": PointerEvent;\n \"lostpointercapture\": PointerEvent;\n \"MSGestureChange\": MSGestureEvent;\n \"MSGestureDoubleTap\": MSGestureEvent;\n \"MSGestureEnd\": MSGestureEvent;\n \"MSGestureHold\": MSGestureEvent;\n \"MSGestureStart\": MSGestureEvent;\n \"MSGestureTap\": MSGestureEvent;\n \"MSGotPointerCapture\": MSPointerEvent;\n \"MSInertiaStart\": MSGestureEvent;\n \"MSLostPointerCapture\": MSPointerEvent;\n \"MSPointerCancel\": MSPointerEvent;\n \"MSPointerDown\": MSPointerEvent;\n \"MSPointerEnter\": MSPointerEvent;\n \"MSPointerLeave\": MSPointerEvent;\n \"MSPointerMove\": MSPointerEvent;\n \"MSPointerOut\": MSPointerEvent;\n \"MSPointerOver\": MSPointerEvent;\n \"MSPointerUp\": MSPointerEvent;\n \"touchcancel\": TouchEvent;\n \"touchend\": TouchEvent;\n \"touchmove\": TouchEvent;\n \"touchstart\": TouchEvent;\n \"webkitfullscreenchange\": Event;\n \"webkitfullscreenerror\": Event;\n}\n\ninterface Element extends Node, GlobalEventHandlers, ElementTraversal, NodeSelector, ChildNode, ParentNode {\n readonly classList: DOMTokenList;\n className: string;\n readonly clientHeight: number;\n readonly clientLeft: number;\n readonly clientTop: number;\n readonly clientWidth: number;\n id: string;\n innerHTML: string;\n msContentZoomFactor: number;\n readonly msRegionOverflow: string;\n onariarequest: (this: Element, ev: Event) => any;\n oncommand: (this: Element, ev: Event) => any;\n ongotpointercapture: (this: Element, ev: PointerEvent) => any;\n onlostpointercapture: (this: Element, ev: PointerEvent) => any;\n onmsgesturechange: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturedoubletap: (this: Element, ev: MSGestureEvent) => any;\n onmsgestureend: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturehold: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturestart: (this: Element, ev: MSGestureEvent) => any;\n onmsgesturetap: (this: Element, ev: MSGestureEvent) => any;\n onmsgotpointercapture: (this: Element, ev: MSPointerEvent) => any;\n onmsinertiastart: (this: Element, ev: MSGestureEvent) => any;\n onmslostpointercapture: (this: Element, ev: MSPointerEvent) => any;\n onmspointercancel: (this: Element, ev: MSPointerEvent) => any;\n onmspointerdown: (this: Element, ev: MSPointerEvent) => any;\n onmspointerenter: (this: Element, ev: MSPointerEvent) => any;\n onmspointerleave: (this: Element, ev: MSPointerEvent) => any;\n onmspointermove: (this: Element, ev: MSPointerEvent) => any;\n onmspointerout: (this: Element, ev: MSPointerEvent) => any;\n onmspointerover: (this: Element, ev: MSPointerEvent) => any;\n onmspointerup: (this: Element, ev: MSPointerEvent) => any;\n ontouchcancel: (ev: TouchEvent) => any;\n ontouchend: (ev: TouchEvent) => any;\n ontouchmove: (ev: TouchEvent) => any;\n ontouchstart: (ev: TouchEvent) => any;\n onwebkitfullscreenchange: (this: Element, ev: Event) => any;\n onwebkitfullscreenerror: (this: Element, ev: Event) => any;\n outerHTML: string;\n readonly prefix: string | null;\n readonly scrollHeight: number;\n scrollLeft: number;\n scrollTop: number;\n readonly scrollWidth: number;\n readonly tagName: string;\n readonly assignedSlot: HTMLSlotElement | null;\n slot: string;\n readonly shadowRoot: ShadowRoot | null;\n getAttribute(name: string): string | null;\n getAttributeNode(name: string): Attr;\n getAttributeNodeNS(namespaceURI: string, localName: string): Attr;\n getAttributeNS(namespaceURI: string, localName: string): string;\n getBoundingClientRect(): ClientRect;\n getClientRects(): ClientRectList;\n getElementsByTagName(name: K): ElementListTagNameMap[K];\n getElementsByTagName(name: string): NodeListOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/1999/xhtml\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: \"http://www.w3.org/2000/svg\", localName: string): HTMLCollectionOf;\n getElementsByTagNameNS(namespaceURI: string, localName: string): HTMLCollectionOf;\n hasAttribute(name: string): boolean;\n hasAttributeNS(namespaceURI: string, localName: string): boolean;\n msGetRegionContent(): MSRangeCollection;\n msGetUntransformedBounds(): ClientRect;\n msMatchesSelector(selectors: string): boolean;\n msReleasePointerCapture(pointerId: number): void;\n msSetPointerCapture(pointerId: number): void;\n msZoomTo(args: MsZoomToOptions): void;\n releasePointerCapture(pointerId: number): void;\n removeAttribute(qualifiedName: string): void;\n removeAttributeNode(oldAttr: Attr): Attr;\n removeAttributeNS(namespaceURI: string, localName: string): void;\n requestFullscreen(): void;\n requestPointerLock(): void;\n setAttribute(name: string, value: string): void;\n setAttributeNode(newAttr: Attr): Attr;\n setAttributeNodeNS(newAttr: Attr): Attr;\n setAttributeNS(namespaceURI: string, qualifiedName: string, value: string): void;\n setPointerCapture(pointerId: number): void;\n webkitMatchesSelector(selectors: string): boolean;\n webkitRequestFullscreen(): void;\n webkitRequestFullScreen(): void;\n getElementsByClassName(classNames: string): NodeListOf;\n matches(selector: string): boolean;\n closest(selector: string): Element | null;\n scrollIntoView(arg?: boolean | ScrollIntoViewOptions): void;\n scroll(options?: ScrollToOptions): void;\n scroll(x: number, y: number): void;\n scrollTo(options?: ScrollToOptions): void;\n scrollTo(x: number, y: number): void;\n scrollBy(options?: ScrollToOptions): void;\n scrollBy(x: number, y: number): void;\n insertAdjacentElement(position: InsertPosition, insertedElement: Element): Element | null;\n insertAdjacentHTML(where: InsertPosition, html: string): void;\n insertAdjacentText(where: InsertPosition, text: string): void;\n attachShadow(shadowRootInitDict: ShadowRootInit): ShadowRoot;\n addEventListener(type: K, listener: (this: Element, ev: ElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Element: {\n prototype: Element;\n new(): Element;\n};\n\ninterface ErrorEvent extends Event {\n readonly colno: number;\n readonly error: any;\n readonly filename: string;\n readonly lineno: number;\n readonly message: string;\n initErrorEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, messageArg: string, filenameArg: string, linenoArg: number): void;\n}\n\ndeclare var ErrorEvent: {\n prototype: ErrorEvent;\n new(type: string, errorEventInitDict?: ErrorEventInit): ErrorEvent;\n};\n\ninterface Event {\n readonly bubbles: boolean;\n readonly cancelable: boolean;\n cancelBubble: boolean;\n readonly currentTarget: EventTarget;\n readonly defaultPrevented: boolean;\n readonly eventPhase: number;\n readonly isTrusted: boolean;\n returnValue: boolean;\n readonly srcElement: Element | null;\n readonly target: EventTarget;\n readonly timeStamp: number;\n readonly type: string;\n readonly scoped: boolean;\n initEvent(eventTypeArg: string, canBubbleArg: boolean, cancelableArg: boolean): void;\n preventDefault(): void;\n stopImmediatePropagation(): void;\n stopPropagation(): void;\n deepPath(): EventTarget[];\n readonly AT_TARGET: number;\n readonly BUBBLING_PHASE: number;\n readonly CAPTURING_PHASE: number;\n}\n\ndeclare var Event: {\n prototype: Event;\n new(typeArg: string, eventInitDict?: EventInit): Event;\n readonly AT_TARGET: number;\n readonly BUBBLING_PHASE: number;\n readonly CAPTURING_PHASE: number;\n};\n\ninterface EventTarget {\n addEventListener(type: string, listener?: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;\n dispatchEvent(evt: Event): boolean;\n removeEventListener(type: string, listener?: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;\n}\n\ndeclare var EventTarget: {\n prototype: EventTarget;\n new(): EventTarget;\n};\n\ninterface EXT_frag_depth {\n}\n\ndeclare var EXT_frag_depth: {\n prototype: EXT_frag_depth;\n new(): EXT_frag_depth;\n};\n\ninterface EXT_texture_filter_anisotropic {\n readonly MAX_TEXTURE_MAX_ANISOTROPY_EXT: number;\n readonly TEXTURE_MAX_ANISOTROPY_EXT: number;\n}\n\ndeclare var EXT_texture_filter_anisotropic: {\n prototype: EXT_texture_filter_anisotropic;\n new(): EXT_texture_filter_anisotropic;\n readonly MAX_TEXTURE_MAX_ANISOTROPY_EXT: number;\n readonly TEXTURE_MAX_ANISOTROPY_EXT: number;\n};\n\ninterface ExtensionScriptApis {\n extensionIdToShortId(extensionId: string): number;\n fireExtensionApiTelemetry(functionName: string, isSucceeded: boolean, isSupported: boolean): void;\n genericFunction(routerAddress: any, parameters?: string, callbackId?: number): void;\n genericSynchronousFunction(functionId: number, parameters?: string): string;\n getExtensionId(): string;\n registerGenericFunctionCallbackHandler(callbackHandler: any): void;\n registerGenericPersistentCallbackHandler(callbackHandler: any): void;\n}\n\ndeclare var ExtensionScriptApis: {\n prototype: ExtensionScriptApis;\n new(): ExtensionScriptApis;\n};\n\ninterface External {\n}\n\ndeclare var External: {\n prototype: External;\n new(): External;\n};\n\ninterface File extends Blob {\n readonly lastModifiedDate: any;\n readonly name: string;\n readonly webkitRelativePath: string;\n}\n\ndeclare var File: {\n prototype: File;\n new (parts: (ArrayBuffer | ArrayBufferView | Blob | string)[], filename: string, properties?: FilePropertyBag): File;\n};\n\ninterface FileList {\n readonly length: number;\n item(index: number): File;\n [index: number]: File;\n}\n\ndeclare var FileList: {\n prototype: FileList;\n new(): FileList;\n};\n\ninterface FileReader extends EventTarget, MSBaseReader {\n readonly error: DOMError;\n readAsArrayBuffer(blob: Blob): void;\n readAsBinaryString(blob: Blob): void;\n readAsDataURL(blob: Blob): void;\n readAsText(blob: Blob, encoding?: string): void;\n addEventListener(type: K, listener: (this: FileReader, ev: MSBaseReaderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var FileReader: {\n prototype: FileReader;\n new(): FileReader;\n};\n\ninterface FocusEvent extends UIEvent {\n readonly relatedTarget: EventTarget;\n initFocusEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, relatedTargetArg: EventTarget): void;\n}\n\ndeclare var FocusEvent: {\n prototype: FocusEvent;\n new(typeArg: string, eventInitDict?: FocusEventInit): FocusEvent;\n};\n\ninterface FocusNavigationEvent extends Event {\n readonly navigationReason: NavigationReason;\n readonly originHeight: number;\n readonly originLeft: number;\n readonly originTop: number;\n readonly originWidth: number;\n requestFocus(): void;\n}\n\ndeclare var FocusNavigationEvent: {\n prototype: FocusNavigationEvent;\n new(type: string, eventInitDict?: FocusNavigationEventInit): FocusNavigationEvent;\n};\n\ninterface FormData {\n append(name: string, value: string | Blob, fileName?: string): void;\n delete(name: string): void;\n get(name: string): FormDataEntryValue | null;\n getAll(name: string): FormDataEntryValue[];\n has(name: string): boolean;\n set(name: string, value: string | Blob, fileName?: string): void;\n}\n\ndeclare var FormData: {\n prototype: FormData;\n new (form?: HTMLFormElement): FormData;\n};\n\ninterface GainNode extends AudioNode {\n readonly gain: AudioParam;\n}\n\ndeclare var GainNode: {\n prototype: GainNode;\n new(): GainNode;\n};\n\ninterface Gamepad {\n readonly axes: number[];\n readonly buttons: GamepadButton[];\n readonly connected: boolean;\n readonly id: string;\n readonly index: number;\n readonly mapping: string;\n readonly timestamp: number;\n}\n\ndeclare var Gamepad: {\n prototype: Gamepad;\n new(): Gamepad;\n};\n\ninterface GamepadButton {\n readonly pressed: boolean;\n readonly value: number;\n}\n\ndeclare var GamepadButton: {\n prototype: GamepadButton;\n new(): GamepadButton;\n};\n\ninterface GamepadEvent extends Event {\n readonly gamepad: Gamepad;\n}\n\ndeclare var GamepadEvent: {\n prototype: GamepadEvent;\n new(typeArg: string, eventInitDict?: GamepadEventInit): GamepadEvent;\n};\n\ninterface Geolocation {\n clearWatch(watchId: number): void;\n getCurrentPosition(successCallback: PositionCallback, errorCallback?: PositionErrorCallback, options?: PositionOptions): void;\n watchPosition(successCallback: PositionCallback, errorCallback?: PositionErrorCallback, options?: PositionOptions): number;\n}\n\ndeclare var Geolocation: {\n prototype: Geolocation;\n new(): Geolocation;\n};\n\ninterface HashChangeEvent extends Event {\n readonly newURL: string | null;\n readonly oldURL: string | null;\n}\n\ndeclare var HashChangeEvent: {\n prototype: HashChangeEvent;\n new(typeArg: string, eventInitDict?: HashChangeEventInit): HashChangeEvent;\n};\n\ninterface Headers {\n append(name: string, value: string): void;\n delete(name: string): void;\n forEach(callback: ForEachCallback): void;\n get(name: string): string | null;\n has(name: string): boolean;\n set(name: string, value: string): void;\n}\n\ndeclare var Headers: {\n prototype: Headers;\n new(init?: any): Headers;\n};\n\ninterface History {\n readonly length: number;\n readonly state: any;\n scrollRestoration: ScrollRestoration;\n back(): void;\n forward(): void;\n go(delta?: number): void;\n pushState(data: any, title: string, url?: string | null): void;\n replaceState(data: any, title: string, url?: string | null): void;\n}\n\ndeclare var History: {\n prototype: History;\n new(): History;\n};\n\ninterface HTMLAllCollection {\n readonly length: number;\n item(nameOrIndex?: string): HTMLCollection | Element | null;\n namedItem(name: string): HTMLCollection | Element | null;\n [index: number]: Element;\n}\n\ndeclare var HTMLAllCollection: {\n prototype: HTMLAllCollection;\n new(): HTMLAllCollection;\n};\n\ninterface HTMLAnchorElement extends HTMLElement {\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n /**\n * Sets or retrieves the coordinates of the object.\n */\n coords: string;\n download: string;\n /**\n * Contains the anchor portion of the URL including the hash sign (#).\n */\n hash: string;\n /**\n * Contains the hostname and port values of the URL.\n */\n host: string;\n /**\n * Contains the hostname of a URL.\n */\n hostname: string;\n /**\n * Sets or retrieves a destination URL or an anchor point.\n */\n href: string;\n /**\n * Sets or retrieves the language code of the object.\n */\n hreflang: string;\n Methods: string;\n readonly mimeType: string;\n /**\n * Sets or retrieves the shape of the object.\n */\n name: string;\n readonly nameProp: string;\n /**\n * Contains the pathname of the URL.\n */\n pathname: string;\n /**\n * Sets or retrieves the port number associated with a URL.\n */\n port: string;\n /**\n * Contains the protocol of the URL.\n */\n protocol: string;\n readonly protocolLong: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rel: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rev: string;\n /**\n * Sets or retrieves the substring of the href property that follows the question mark.\n */\n search: string;\n /**\n * Sets or retrieves the shape of the object.\n */\n shape: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Retrieves or sets the text of the object as a string.\n */\n text: string;\n type: string;\n urn: string;\n /**\n * Returns a string representation of an object.\n */\n toString(): string;\n addEventListener(type: K, listener: (this: HTMLAnchorElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAnchorElement: {\n prototype: HTMLAnchorElement;\n new(): HTMLAnchorElement;\n};\n\ninterface HTMLAppletElement extends HTMLElement {\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Gets or sets the optional alternative HTML script to execute if the object fails to load.\n */\n altHtml: string;\n /**\n * Sets or retrieves a character string that can be used to implement your own archive functionality for the object.\n */\n archive: string;\n /**\n * Retrieves a string of the URL where the object tag can be found. This is often the href of the document that the object is in, or the value set by a base element.\n */\n readonly BaseHref: string;\n border: string;\n code: string;\n /**\n * Sets or retrieves the URL of the component.\n */\n codeBase: string;\n /**\n * Sets or retrieves the Internet media type for the code associated with the object.\n */\n codeType: string;\n /**\n * Address of a pointer to the document this page or frame contains. If there is no document, then null will be returned.\n */\n readonly contentDocument: Document;\n /**\n * Sets or retrieves the URL that references the data of the object.\n */\n data: string;\n /**\n * Sets or retrieves a character string that can be used to implement your own declare functionality for the object.\n */\n declare: boolean;\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n hspace: number;\n /**\n * Sets or retrieves the shape of the object.\n */\n name: string;\n object: string | null;\n /**\n * Sets or retrieves a message to be displayed while an object is loading.\n */\n standby: string;\n /**\n * Returns the content type of the object.\n */\n type: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n vspace: number;\n width: number;\n addEventListener(type: K, listener: (this: HTMLAppletElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAppletElement: {\n prototype: HTMLAppletElement;\n new(): HTMLAppletElement;\n};\n\ninterface HTMLAreaElement extends HTMLElement {\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Sets or retrieves the coordinates of the object.\n */\n coords: string;\n download: string;\n /**\n * Sets or retrieves the subsection of the href property that follows the number sign (#).\n */\n hash: string;\n /**\n * Sets or retrieves the hostname and port number of the location or URL.\n */\n host: string;\n /**\n * Sets or retrieves the host name part of the location or URL.\n */\n hostname: string;\n /**\n * Sets or retrieves a destination URL or an anchor point.\n */\n href: string;\n /**\n * Sets or gets whether clicks in this region cause action.\n */\n noHref: boolean;\n /**\n * Sets or retrieves the file name or path specified by the object.\n */\n pathname: string;\n /**\n * Sets or retrieves the port number associated with a URL.\n */\n port: string;\n /**\n * Sets or retrieves the protocol portion of a URL.\n */\n protocol: string;\n rel: string;\n /**\n * Sets or retrieves the substring of the href property that follows the question mark.\n */\n search: string;\n /**\n * Sets or retrieves the shape of the object.\n */\n shape: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Returns a string representation of an object.\n */\n toString(): string;\n addEventListener(type: K, listener: (this: HTMLAreaElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAreaElement: {\n prototype: HTMLAreaElement;\n new(): HTMLAreaElement;\n};\n\ninterface HTMLAreasCollection extends HTMLCollectionBase {\n}\n\ndeclare var HTMLAreasCollection: {\n prototype: HTMLAreasCollection;\n new(): HTMLAreasCollection;\n};\n\ninterface HTMLAudioElement extends HTMLMediaElement {\n addEventListener(type: K, listener: (this: HTMLAudioElement, ev: HTMLMediaElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLAudioElement: {\n prototype: HTMLAudioElement;\n new(): HTMLAudioElement;\n};\n\ninterface HTMLBaseElement extends HTMLElement {\n /**\n * Gets or sets the baseline URL on which relative links are based.\n */\n href: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n addEventListener(type: K, listener: (this: HTMLBaseElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBaseElement: {\n prototype: HTMLBaseElement;\n new(): HTMLBaseElement;\n};\n\ninterface HTMLBaseFontElement extends HTMLElement, DOML2DeprecatedColorProperty {\n /**\n * Sets or retrieves the current typeface family.\n */\n face: string;\n /**\n * Sets or retrieves the font size of the object.\n */\n size: number;\n addEventListener(type: K, listener: (this: HTMLBaseFontElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBaseFontElement: {\n prototype: HTMLBaseFontElement;\n new(): HTMLBaseFontElement;\n};\n\ninterface HTMLBodyElementEventMap extends HTMLElementEventMap {\n \"afterprint\": Event;\n \"beforeprint\": Event;\n \"beforeunload\": BeforeUnloadEvent;\n \"blur\": FocusEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"hashchange\": HashChangeEvent;\n \"load\": Event;\n \"message\": MessageEvent;\n \"offline\": Event;\n \"online\": Event;\n \"orientationchange\": Event;\n \"pagehide\": PageTransitionEvent;\n \"pageshow\": PageTransitionEvent;\n \"popstate\": PopStateEvent;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"storage\": StorageEvent;\n \"unload\": Event;\n}\n\ninterface HTMLBodyElement extends HTMLElement {\n aLink: any;\n background: string;\n bgColor: any;\n bgProperties: string;\n link: any;\n noWrap: boolean;\n onafterprint: (this: HTMLBodyElement, ev: Event) => any;\n onbeforeprint: (this: HTMLBodyElement, ev: Event) => any;\n onbeforeunload: (this: HTMLBodyElement, ev: BeforeUnloadEvent) => any;\n onblur: (this: HTMLBodyElement, ev: FocusEvent) => any;\n onerror: (this: HTMLBodyElement, ev: ErrorEvent) => any;\n onfocus: (this: HTMLBodyElement, ev: FocusEvent) => any;\n onhashchange: (this: HTMLBodyElement, ev: HashChangeEvent) => any;\n onload: (this: HTMLBodyElement, ev: Event) => any;\n onmessage: (this: HTMLBodyElement, ev: MessageEvent) => any;\n onoffline: (this: HTMLBodyElement, ev: Event) => any;\n ononline: (this: HTMLBodyElement, ev: Event) => any;\n onorientationchange: (this: HTMLBodyElement, ev: Event) => any;\n onpagehide: (this: HTMLBodyElement, ev: PageTransitionEvent) => any;\n onpageshow: (this: HTMLBodyElement, ev: PageTransitionEvent) => any;\n onpopstate: (this: HTMLBodyElement, ev: PopStateEvent) => any;\n onresize: (this: HTMLBodyElement, ev: UIEvent) => any;\n onscroll: (this: HTMLBodyElement, ev: UIEvent) => any;\n onstorage: (this: HTMLBodyElement, ev: StorageEvent) => any;\n onunload: (this: HTMLBodyElement, ev: Event) => any;\n text: any;\n vLink: any;\n addEventListener(type: K, listener: (this: HTMLBodyElement, ev: HTMLBodyElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBodyElement: {\n prototype: HTMLBodyElement;\n new(): HTMLBodyElement;\n};\n\ninterface HTMLBRElement extends HTMLElement {\n /**\n * Sets or retrieves the side on which floating objects are not to be positioned when any IHTMLBlockElement is inserted into the document.\n */\n clear: string;\n addEventListener(type: K, listener: (this: HTMLBRElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLBRElement: {\n prototype: HTMLBRElement;\n new(): HTMLBRElement;\n};\n\ninterface HTMLButtonElement extends HTMLElement {\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Overrides the action attribute (where the data on a form is sent) on the parent form element.\n */\n formAction: string;\n /**\n * Used to override the encoding (formEnctype attribute) specified on the form element.\n */\n formEnctype: string;\n /**\n * Overrides the submit method attribute previously specified on a form element.\n */\n formMethod: string;\n /**\n * Overrides any validation or required attributes on a form or form elements to allow it to be submitted without validation. This can be used to create a \"save draft\"-type submit option.\n */\n formNoValidate: string;\n /**\n * Overrides the target attribute on a form element.\n */\n formTarget: string;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n status: any;\n /**\n * Gets the classification and default behavior of the button.\n */\n type: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Sets or retrieves the default or selected value of the control.\n */\n value: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLButtonElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLButtonElement: {\n prototype: HTMLButtonElement;\n new(): HTMLButtonElement;\n};\n\ninterface HTMLCanvasElement extends HTMLElement {\n /**\n * Gets or sets the height of a canvas element on a document.\n */\n height: number;\n /**\n * Gets or sets the width of a canvas element on a document.\n */\n width: number;\n /**\n * Returns an object that provides methods and properties for drawing and manipulating images and graphics on a canvas element in a document. A context object includes information about colors, line widths, fonts, and other graphic parameters that can be drawn on a canvas.\n * @param contextId The identifier (ID) of the type of canvas to create. Internet Explorer 9 and Internet Explorer 10 support only a 2-D context using canvas.getContext(\"2d\"); IE11 Preview also supports 3-D or WebGL context using canvas.getContext(\"experimental-webgl\");\n */\n getContext(contextId: \"2d\", contextAttributes?: Canvas2DContextAttributes): CanvasRenderingContext2D | null;\n getContext(contextId: \"webgl\" | \"experimental-webgl\", contextAttributes?: WebGLContextAttributes): WebGLRenderingContext | null;\n getContext(contextId: string, contextAttributes?: {}): CanvasRenderingContext2D | WebGLRenderingContext | null;\n /**\n * Returns a blob object encoded as a Portable Network Graphics (PNG) format from a canvas image or drawing.\n */\n msToBlob(): Blob;\n /**\n * Returns the content of the current canvas as an image that you can use as a source for another canvas or an HTML element.\n * @param type The standard MIME type for the image format to return. If you do not specify this parameter, the default value is a PNG format image.\n */\n toDataURL(type?: string, ...args: any[]): string;\n toBlob(callback: (result: Blob | null) => void, type?: string, ...arguments: any[]): void;\n addEventListener(type: K, listener: (this: HTMLCanvasElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLCanvasElement: {\n prototype: HTMLCanvasElement;\n new(): HTMLCanvasElement;\n};\n\ninterface HTMLCollectionBase {\n /**\n * Sets or retrieves the number of objects in a collection.\n */\n readonly length: number;\n /**\n * Retrieves an object from various collections.\n */\n item(index: number): Element;\n [index: number]: Element;\n}\n\ninterface HTMLCollection extends HTMLCollectionBase {\n /**\n * Retrieves a select object or an object from an options collection.\n */\n namedItem(name: string): Element | null;\n}\n\ndeclare var HTMLCollection: {\n prototype: HTMLCollection;\n new(): HTMLCollection;\n};\n\ninterface HTMLDataElement extends HTMLElement {\n value: string;\n addEventListener(type: K, listener: (this: HTMLDataElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDataElement: {\n prototype: HTMLDataElement;\n new(): HTMLDataElement;\n};\n\ninterface HTMLDataListElement extends HTMLElement {\n options: HTMLCollectionOf;\n addEventListener(type: K, listener: (this: HTMLDataListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDataListElement: {\n prototype: HTMLDataListElement;\n new(): HTMLDataListElement;\n};\n\ninterface HTMLDirectoryElement extends HTMLElement {\n compact: boolean;\n addEventListener(type: K, listener: (this: HTMLDirectoryElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDirectoryElement: {\n prototype: HTMLDirectoryElement;\n new(): HTMLDirectoryElement;\n};\n\ninterface HTMLDivElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves whether the browser automatically performs wordwrap.\n */\n noWrap: boolean;\n addEventListener(type: K, listener: (this: HTMLDivElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDivElement: {\n prototype: HTMLDivElement;\n new(): HTMLDivElement;\n};\n\ninterface HTMLDListElement extends HTMLElement {\n compact: boolean;\n addEventListener(type: K, listener: (this: HTMLDListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDListElement: {\n prototype: HTMLDListElement;\n new(): HTMLDListElement;\n};\n\ninterface HTMLDocument extends Document {\n addEventListener(type: K, listener: (this: HTMLDocument, ev: DocumentEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLDocument: {\n prototype: HTMLDocument;\n new(): HTMLDocument;\n};\n\ninterface HTMLElementEventMap extends ElementEventMap {\n \"abort\": UIEvent;\n \"activate\": UIEvent;\n \"beforeactivate\": UIEvent;\n \"beforecopy\": ClipboardEvent;\n \"beforecut\": ClipboardEvent;\n \"beforedeactivate\": UIEvent;\n \"beforepaste\": ClipboardEvent;\n \"blur\": FocusEvent;\n \"canplay\": Event;\n \"canplaythrough\": Event;\n \"change\": Event;\n \"click\": MouseEvent;\n \"contextmenu\": PointerEvent;\n \"copy\": ClipboardEvent;\n \"cuechange\": Event;\n \"cut\": ClipboardEvent;\n \"dblclick\": MouseEvent;\n \"deactivate\": UIEvent;\n \"drag\": DragEvent;\n \"dragend\": DragEvent;\n \"dragenter\": DragEvent;\n \"dragleave\": DragEvent;\n \"dragover\": DragEvent;\n \"dragstart\": DragEvent;\n \"drop\": DragEvent;\n \"durationchange\": Event;\n \"emptied\": Event;\n \"ended\": MediaStreamErrorEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"input\": Event;\n \"invalid\": Event;\n \"keydown\": KeyboardEvent;\n \"keypress\": KeyboardEvent;\n \"keyup\": KeyboardEvent;\n \"load\": Event;\n \"loadeddata\": Event;\n \"loadedmetadata\": Event;\n \"loadstart\": Event;\n \"mousedown\": MouseEvent;\n \"mouseenter\": MouseEvent;\n \"mouseleave\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n \"mousewheel\": WheelEvent;\n \"MSContentZoom\": UIEvent;\n \"MSManipulationStateChanged\": MSManipulationEvent;\n \"paste\": ClipboardEvent;\n \"pause\": Event;\n \"play\": Event;\n \"playing\": Event;\n \"progress\": ProgressEvent;\n \"ratechange\": Event;\n \"reset\": Event;\n \"scroll\": UIEvent;\n \"seeked\": Event;\n \"seeking\": Event;\n \"select\": UIEvent;\n \"selectstart\": Event;\n \"stalled\": Event;\n \"submit\": Event;\n \"suspend\": Event;\n \"timeupdate\": Event;\n \"volumechange\": Event;\n \"waiting\": Event;\n}\n\ninterface HTMLElement extends Element {\n accessKey: string;\n readonly children: HTMLCollection;\n contentEditable: string;\n readonly dataset: DOMStringMap;\n dir: string;\n draggable: boolean;\n hidden: boolean;\n hideFocus: boolean;\n innerText: string;\n readonly isContentEditable: boolean;\n lang: string;\n readonly offsetHeight: number;\n readonly offsetLeft: number;\n readonly offsetParent: Element;\n readonly offsetTop: number;\n readonly offsetWidth: number;\n onabort: (this: HTMLElement, ev: UIEvent) => any;\n onactivate: (this: HTMLElement, ev: UIEvent) => any;\n onbeforeactivate: (this: HTMLElement, ev: UIEvent) => any;\n onbeforecopy: (this: HTMLElement, ev: ClipboardEvent) => any;\n onbeforecut: (this: HTMLElement, ev: ClipboardEvent) => any;\n onbeforedeactivate: (this: HTMLElement, ev: UIEvent) => any;\n onbeforepaste: (this: HTMLElement, ev: ClipboardEvent) => any;\n onblur: (this: HTMLElement, ev: FocusEvent) => any;\n oncanplay: (this: HTMLElement, ev: Event) => any;\n oncanplaythrough: (this: HTMLElement, ev: Event) => any;\n onchange: (this: HTMLElement, ev: Event) => any;\n onclick: (this: HTMLElement, ev: MouseEvent) => any;\n oncontextmenu: (this: HTMLElement, ev: PointerEvent) => any;\n oncopy: (this: HTMLElement, ev: ClipboardEvent) => any;\n oncuechange: (this: HTMLElement, ev: Event) => any;\n oncut: (this: HTMLElement, ev: ClipboardEvent) => any;\n ondblclick: (this: HTMLElement, ev: MouseEvent) => any;\n ondeactivate: (this: HTMLElement, ev: UIEvent) => any;\n ondrag: (this: HTMLElement, ev: DragEvent) => any;\n ondragend: (this: HTMLElement, ev: DragEvent) => any;\n ondragenter: (this: HTMLElement, ev: DragEvent) => any;\n ondragleave: (this: HTMLElement, ev: DragEvent) => any;\n ondragover: (this: HTMLElement, ev: DragEvent) => any;\n ondragstart: (this: HTMLElement, ev: DragEvent) => any;\n ondrop: (this: HTMLElement, ev: DragEvent) => any;\n ondurationchange: (this: HTMLElement, ev: Event) => any;\n onemptied: (this: HTMLElement, ev: Event) => any;\n onended: (this: HTMLElement, ev: MediaStreamErrorEvent) => any;\n onerror: (this: HTMLElement, ev: ErrorEvent) => any;\n onfocus: (this: HTMLElement, ev: FocusEvent) => any;\n oninput: (this: HTMLElement, ev: Event) => any;\n oninvalid: (this: HTMLElement, ev: Event) => any;\n onkeydown: (this: HTMLElement, ev: KeyboardEvent) => any;\n onkeypress: (this: HTMLElement, ev: KeyboardEvent) => any;\n onkeyup: (this: HTMLElement, ev: KeyboardEvent) => any;\n onload: (this: HTMLElement, ev: Event) => any;\n onloadeddata: (this: HTMLElement, ev: Event) => any;\n onloadedmetadata: (this: HTMLElement, ev: Event) => any;\n onloadstart: (this: HTMLElement, ev: Event) => any;\n onmousedown: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseenter: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseleave: (this: HTMLElement, ev: MouseEvent) => any;\n onmousemove: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseout: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseover: (this: HTMLElement, ev: MouseEvent) => any;\n onmouseup: (this: HTMLElement, ev: MouseEvent) => any;\n onmousewheel: (this: HTMLElement, ev: WheelEvent) => any;\n onmscontentzoom: (this: HTMLElement, ev: UIEvent) => any;\n onmsmanipulationstatechanged: (this: HTMLElement, ev: MSManipulationEvent) => any;\n onpaste: (this: HTMLElement, ev: ClipboardEvent) => any;\n onpause: (this: HTMLElement, ev: Event) => any;\n onplay: (this: HTMLElement, ev: Event) => any;\n onplaying: (this: HTMLElement, ev: Event) => any;\n onprogress: (this: HTMLElement, ev: ProgressEvent) => any;\n onratechange: (this: HTMLElement, ev: Event) => any;\n onreset: (this: HTMLElement, ev: Event) => any;\n onscroll: (this: HTMLElement, ev: UIEvent) => any;\n onseeked: (this: HTMLElement, ev: Event) => any;\n onseeking: (this: HTMLElement, ev: Event) => any;\n onselect: (this: HTMLElement, ev: UIEvent) => any;\n onselectstart: (this: HTMLElement, ev: Event) => any;\n onstalled: (this: HTMLElement, ev: Event) => any;\n onsubmit: (this: HTMLElement, ev: Event) => any;\n onsuspend: (this: HTMLElement, ev: Event) => any;\n ontimeupdate: (this: HTMLElement, ev: Event) => any;\n onvolumechange: (this: HTMLElement, ev: Event) => any;\n onwaiting: (this: HTMLElement, ev: Event) => any;\n outerText: string;\n spellcheck: boolean;\n readonly style: CSSStyleDeclaration;\n tabIndex: number;\n title: string;\n blur(): void;\n click(): void;\n dragDrop(): boolean;\n focus(): void;\n msGetInputContext(): MSInputMethodContext;\n addEventListener(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLElement: {\n prototype: HTMLElement;\n new(): HTMLElement;\n};\n\ninterface HTMLEmbedElement extends HTMLElement, GetSVGDocument {\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n hidden: any;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n /**\n * Gets or sets the path to the preferred media source. This enables the Play To target device to stream the media content, which can be DRM protected, from a different location, such as a cloud media server.\n */\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Retrieves the palette used for the embedded document.\n */\n readonly palette: string;\n /**\n * Retrieves the URL of the plug-in used to view an embedded document.\n */\n readonly pluginspage: string;\n readonly readyState: string;\n /**\n * Sets or retrieves a URL to be loaded by the object.\n */\n src: string;\n /**\n * Sets or retrieves the height and width units of the embed object.\n */\n units: string;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n addEventListener(type: K, listener: (this: HTMLEmbedElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLEmbedElement: {\n prototype: HTMLEmbedElement;\n new(): HTMLEmbedElement;\n};\n\ninterface HTMLFieldSetElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n name: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLFieldSetElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFieldSetElement: {\n prototype: HTMLFieldSetElement;\n new(): HTMLFieldSetElement;\n};\n\ninterface HTMLFontElement extends HTMLElement, DOML2DeprecatedColorProperty, DOML2DeprecatedSizeProperty {\n /**\n * Sets or retrieves the current typeface family.\n */\n face: string;\n addEventListener(type: K, listener: (this: HTMLFontElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFontElement: {\n prototype: HTMLFontElement;\n new(): HTMLFontElement;\n};\n\ninterface HTMLFormControlsCollection extends HTMLCollectionBase {\n namedItem(name: string): HTMLCollection | Element | null;\n}\n\ndeclare var HTMLFormControlsCollection: {\n prototype: HTMLFormControlsCollection;\n new(): HTMLFormControlsCollection;\n};\n\ninterface HTMLFormElement extends HTMLElement {\n /**\n * Sets or retrieves a list of character encodings for input data that must be accepted by the server processing the form.\n */\n acceptCharset: string;\n /**\n * Sets or retrieves the URL to which the form content is sent for processing.\n */\n action: string;\n /**\n * Specifies whether autocomplete is applied to an editable text field.\n */\n autocomplete: string;\n /**\n * Retrieves a collection, in source order, of all controls in a given form.\n */\n readonly elements: HTMLFormControlsCollection;\n /**\n * Sets or retrieves the MIME encoding for the form.\n */\n encoding: string;\n /**\n * Sets or retrieves the encoding type for the form.\n */\n enctype: string;\n /**\n * Sets or retrieves the number of objects in a collection.\n */\n readonly length: number;\n /**\n * Sets or retrieves how to send the form data to the server.\n */\n method: string;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Designates a form that is not validated when submitted.\n */\n noValidate: boolean;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Retrieves a form object or an object from an elements collection.\n * @param name Variant of type Number or String that specifies the object or collection to retrieve. If this parameter is a Number, it is the zero-based index of the object. If this parameter is a string, all objects with matching name or id properties are retrieved, and a collection is returned if more than one match is made.\n * @param index Variant of type Number that specifies the zero-based index of the object to retrieve when a collection is returned.\n */\n item(name?: any, index?: any): any;\n /**\n * Retrieves a form object or an object from an elements collection.\n */\n namedItem(name: string): any;\n /**\n * Fires when the user resets a form.\n */\n reset(): void;\n /**\n * Fires when a FORM is about to be submitted.\n */\n submit(): void;\n addEventListener(type: K, listener: (this: HTMLFormElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [name: string]: any;\n}\n\ndeclare var HTMLFormElement: {\n prototype: HTMLFormElement;\n new(): HTMLFormElement;\n};\n\ninterface HTMLFrameElementEventMap extends HTMLElementEventMap {\n \"load\": Event;\n}\n\ninterface HTMLFrameElement extends HTMLElement, GetSVGDocument {\n /**\n * Specifies the properties of a border drawn around an object.\n */\n border: string;\n /**\n * Sets or retrieves the border color of the object.\n */\n borderColor: any;\n /**\n * Retrieves the document object of the page or frame.\n */\n readonly contentDocument: Document;\n /**\n * Retrieves the object of the specified.\n */\n readonly contentWindow: Window;\n /**\n * Sets or retrieves whether to display a border for the frame.\n */\n frameBorder: string;\n /**\n * Sets or retrieves the amount of additional space between the frames.\n */\n frameSpacing: any;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string | number;\n /**\n * Sets or retrieves a URI to a long description of the object.\n */\n longDesc: string;\n /**\n * Sets or retrieves the top and bottom margin heights before displaying the text in a frame.\n */\n marginHeight: string;\n /**\n * Sets or retrieves the left and right margin widths before displaying the text in a frame.\n */\n marginWidth: string;\n /**\n * Sets or retrieves the frame name.\n */\n name: string;\n /**\n * Sets or retrieves whether the user can resize the frame.\n */\n noResize: boolean;\n /**\n * Raised when the object has been completely received from the server.\n */\n onload: (this: HTMLFrameElement, ev: Event) => any;\n /**\n * Sets or retrieves whether the frame can be scrolled.\n */\n scrolling: string;\n /**\n * Sets or retrieves a URL to be loaded by the object.\n */\n src: string;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string | number;\n addEventListener(type: K, listener: (this: HTMLFrameElement, ev: HTMLFrameElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFrameElement: {\n prototype: HTMLFrameElement;\n new(): HTMLFrameElement;\n};\n\ninterface HTMLFrameSetElementEventMap extends HTMLElementEventMap {\n \"afterprint\": Event;\n \"beforeprint\": Event;\n \"beforeunload\": BeforeUnloadEvent;\n \"blur\": FocusEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"hashchange\": HashChangeEvent;\n \"load\": Event;\n \"message\": MessageEvent;\n \"offline\": Event;\n \"online\": Event;\n \"orientationchange\": Event;\n \"pagehide\": PageTransitionEvent;\n \"pageshow\": PageTransitionEvent;\n \"popstate\": PopStateEvent;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"storage\": StorageEvent;\n \"unload\": Event;\n}\n\ninterface HTMLFrameSetElement extends HTMLElement {\n border: string;\n /**\n * Sets or retrieves the border color of the object.\n */\n borderColor: any;\n /**\n * Sets or retrieves the frame widths of the object.\n */\n cols: string;\n /**\n * Sets or retrieves whether to display a border for the frame.\n */\n frameBorder: string;\n /**\n * Sets or retrieves the amount of additional space between the frames.\n */\n frameSpacing: any;\n name: string;\n onafterprint: (this: HTMLFrameSetElement, ev: Event) => any;\n onbeforeprint: (this: HTMLFrameSetElement, ev: Event) => any;\n onbeforeunload: (this: HTMLFrameSetElement, ev: BeforeUnloadEvent) => any;\n /**\n * Fires when the object loses the input focus.\n */\n onblur: (this: HTMLFrameSetElement, ev: FocusEvent) => any;\n onerror: (this: HTMLFrameSetElement, ev: ErrorEvent) => any;\n /**\n * Fires when the object receives focus.\n */\n onfocus: (this: HTMLFrameSetElement, ev: FocusEvent) => any;\n onhashchange: (this: HTMLFrameSetElement, ev: HashChangeEvent) => any;\n onload: (this: HTMLFrameSetElement, ev: Event) => any;\n onmessage: (this: HTMLFrameSetElement, ev: MessageEvent) => any;\n onoffline: (this: HTMLFrameSetElement, ev: Event) => any;\n ononline: (this: HTMLFrameSetElement, ev: Event) => any;\n onorientationchange: (this: HTMLFrameSetElement, ev: Event) => any;\n onpagehide: (this: HTMLFrameSetElement, ev: PageTransitionEvent) => any;\n onpageshow: (this: HTMLFrameSetElement, ev: PageTransitionEvent) => any;\n onpopstate: (this: HTMLFrameSetElement, ev: PopStateEvent) => any;\n onresize: (this: HTMLFrameSetElement, ev: UIEvent) => any;\n onscroll: (this: HTMLFrameSetElement, ev: UIEvent) => any;\n onstorage: (this: HTMLFrameSetElement, ev: StorageEvent) => any;\n onunload: (this: HTMLFrameSetElement, ev: Event) => any;\n /**\n * Sets or retrieves the frame heights of the object.\n */\n rows: string;\n addEventListener(type: K, listener: (this: HTMLFrameSetElement, ev: HTMLFrameSetElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLFrameSetElement: {\n prototype: HTMLFrameSetElement;\n new(): HTMLFrameSetElement;\n};\n\ninterface HTMLHeadElement extends HTMLElement {\n profile: string;\n addEventListener(type: K, listener: (this: HTMLHeadElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHeadElement: {\n prototype: HTMLHeadElement;\n new(): HTMLHeadElement;\n};\n\ninterface HTMLHeadingElement extends HTMLElement {\n /**\n * Sets or retrieves a value that indicates the table alignment.\n */\n align: string;\n addEventListener(type: K, listener: (this: HTMLHeadingElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHeadingElement: {\n prototype: HTMLHeadingElement;\n new(): HTMLHeadingElement;\n};\n\ninterface HTMLHRElement extends HTMLElement, DOML2DeprecatedColorProperty, DOML2DeprecatedSizeProperty {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves whether the horizontal rule is drawn with 3-D shading.\n */\n noShade: boolean;\n /**\n * Sets or retrieves the width of the object.\n */\n width: number;\n addEventListener(type: K, listener: (this: HTMLHRElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHRElement: {\n prototype: HTMLHRElement;\n new(): HTMLHRElement;\n};\n\ninterface HTMLHtmlElement extends HTMLElement {\n /**\n * Sets or retrieves the DTD version that governs the current document.\n */\n version: string;\n addEventListener(type: K, listener: (this: HTMLHtmlElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLHtmlElement: {\n prototype: HTMLHtmlElement;\n new(): HTMLHtmlElement;\n};\n\ninterface HTMLIFrameElementEventMap extends HTMLElementEventMap {\n \"load\": Event;\n}\n\ninterface HTMLIFrameElement extends HTMLElement, GetSVGDocument {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n allowFullscreen: boolean;\n allowPaymentRequest: boolean;\n /**\n * Specifies the properties of a border drawn around an object.\n */\n border: string;\n /**\n * Retrieves the document object of the page or frame.\n */\n readonly contentDocument: Document;\n /**\n * Retrieves the object of the specified.\n */\n readonly contentWindow: Window;\n /**\n * Sets or retrieves whether to display a border for the frame.\n */\n frameBorder: string;\n /**\n * Sets or retrieves the amount of additional space between the frames.\n */\n frameSpacing: any;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n /**\n * Sets or retrieves the horizontal margin for the object.\n */\n hspace: number;\n /**\n * Sets or retrieves a URI to a long description of the object.\n */\n longDesc: string;\n /**\n * Sets or retrieves the top and bottom margin heights before displaying the text in a frame.\n */\n marginHeight: string;\n /**\n * Sets or retrieves the left and right margin widths before displaying the text in a frame.\n */\n marginWidth: string;\n /**\n * Sets or retrieves the frame name.\n */\n name: string;\n /**\n * Sets or retrieves whether the user can resize the frame.\n */\n noResize: boolean;\n /**\n * Raised when the object has been completely received from the server.\n */\n onload: (this: HTMLIFrameElement, ev: Event) => any;\n readonly sandbox: DOMSettableTokenList;\n /**\n * Sets or retrieves whether the frame can be scrolled.\n */\n scrolling: string;\n /**\n * Sets or retrieves a URL to be loaded by the object.\n */\n src: string;\n /**\n * Sets or retrieves the vertical margin for the object.\n */\n vspace: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n addEventListener(type: K, listener: (this: HTMLIFrameElement, ev: HTMLIFrameElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLIFrameElement: {\n prototype: HTMLIFrameElement;\n new(): HTMLIFrameElement;\n};\n\ninterface HTMLImageElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Specifies the properties of a border drawn around an object.\n */\n border: string;\n /**\n * Retrieves whether the object is fully loaded.\n */\n readonly complete: boolean;\n crossOrigin: string | null;\n readonly currentSrc: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: number;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n hspace: number;\n /**\n * Sets or retrieves whether the image is a server-side image map.\n */\n isMap: boolean;\n /**\n * Sets or retrieves a Uniform Resource Identifier (URI) to a long description of the object.\n */\n longDesc: string;\n lowsrc: string;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * The original height of the image resource before sizing.\n */\n readonly naturalHeight: number;\n /**\n * The original width of the image resource before sizing.\n */\n readonly naturalWidth: number;\n sizes: string;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n srcset: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n /**\n * Sets or retrieves the vertical margin for the object.\n */\n vspace: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: number;\n readonly x: number;\n readonly y: number;\n msGetAsCastingSource(): any;\n addEventListener(type: K, listener: (this: HTMLImageElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLImageElement: {\n prototype: HTMLImageElement;\n new(): HTMLImageElement;\n};\n\ninterface HTMLInputElement extends HTMLElement {\n /**\n * Sets or retrieves a comma-separated list of content types.\n */\n accept: string;\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Specifies whether autocomplete is applied to an editable text field.\n */\n autocomplete: string;\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n border: string;\n /**\n * Sets or retrieves the state of the check box or radio button.\n */\n checked: boolean;\n /**\n * Retrieves whether the object is fully loaded.\n */\n readonly complete: boolean;\n /**\n * Sets or retrieves the state of the check box or radio button.\n */\n defaultChecked: boolean;\n /**\n * Sets or retrieves the initial contents of the object.\n */\n defaultValue: string;\n disabled: boolean;\n /**\n * Returns a FileList object on a file type input object.\n */\n readonly files: FileList | null;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Overrides the action attribute (where the data on a form is sent) on the parent form element.\n */\n formAction: string;\n /**\n * Used to override the encoding (formEnctype attribute) specified on the form element.\n */\n formEnctype: string;\n /**\n * Overrides the submit method attribute previously specified on a form element.\n */\n formMethod: string;\n /**\n * Overrides any validation or required attributes on a form or form elements to allow it to be submitted without validation. This can be used to create a \"save draft\"-type submit option.\n */\n formNoValidate: string;\n /**\n * Overrides the target attribute on a form element.\n */\n formTarget: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n hspace: number;\n indeterminate: boolean;\n /**\n * Specifies the ID of a pre-defined datalist of options for an input element.\n */\n readonly list: HTMLElement;\n /**\n * Defines the maximum acceptable value for an input element with type=\"number\".When used with the min and step attributes, lets you control the range and increment (such as only even numbers) that the user can enter into an input field.\n */\n max: string;\n /**\n * Sets or retrieves the maximum number of characters that the user can enter in a text control.\n */\n maxLength: number;\n /**\n * Defines the minimum acceptable value for an input element with type=\"number\". When used with the max and step attributes, lets you control the range and increment (such as even numbers only) that the user can enter into an input field.\n */\n min: string;\n /**\n * Sets or retrieves the Boolean value indicating whether multiple items can be selected from a list.\n */\n multiple: boolean;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Gets or sets a string containing a regular expression that the user's input must match.\n */\n pattern: string;\n /**\n * Gets or sets a text string that is displayed in an input field as a hint or prompt to users as the format or type of information they need to enter.The text appears in an input field until the user puts focus on the field.\n */\n placeholder: string;\n readOnly: boolean;\n /**\n * When present, marks an element that can't be submitted without a value.\n */\n required: boolean;\n selectionDirection: string;\n /**\n * Gets or sets the end position or offset of a text selection.\n */\n selectionEnd: number;\n /**\n * Gets or sets the starting position or offset of a text selection.\n */\n selectionStart: number;\n size: number;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n status: boolean;\n /**\n * Defines an increment or jump between values that you want to allow the user to enter. When used with the max and min attributes, lets you control the range and increment (for example, allow only even numbers) that the user can enter into an input field.\n */\n step: string;\n /**\n * Returns the content type of the object.\n */\n type: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Returns the value of the data at the cursor's current position.\n */\n value: string;\n valueAsDate: Date;\n /**\n * Returns the input field value as a number.\n */\n valueAsNumber: number;\n /**\n * Sets or retrieves the vertical margin for the object.\n */\n vspace: number;\n webkitdirectory: boolean;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n minLength: number;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Makes the selection equal to the current object.\n */\n select(): void;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n /**\n * Sets the start and end positions of a selection in a text field.\n * @param start The offset into the text field for the start of the selection.\n * @param end The offset into the text field for the end of the selection.\n */\n setSelectionRange(start?: number, end?: number, direction?: string): void;\n /**\n * Decrements a range input control's value by the value given by the Step attribute. If the optional parameter is used, it will decrement the input control's step value multiplied by the parameter's value.\n * @param n Value to decrement the value by.\n */\n stepDown(n?: number): void;\n /**\n * Increments a range input control's value by the value given by the Step attribute. If the optional parameter is used, will increment the input control's value by that value.\n * @param n Value to increment the value by.\n */\n stepUp(n?: number): void;\n addEventListener(type: K, listener: (this: HTMLInputElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLInputElement: {\n prototype: HTMLInputElement;\n new(): HTMLInputElement;\n};\n\ninterface HTMLLabelElement extends HTMLElement {\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the object to which the given label object is assigned.\n */\n htmlFor: string;\n addEventListener(type: K, listener: (this: HTMLLabelElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLabelElement: {\n prototype: HTMLLabelElement;\n new(): HTMLLabelElement;\n};\n\ninterface HTMLLegendElement extends HTMLElement {\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n align: string;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n addEventListener(type: K, listener: (this: HTMLLegendElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLegendElement: {\n prototype: HTMLLegendElement;\n new(): HTMLLegendElement;\n};\n\ninterface HTMLLIElement extends HTMLElement {\n type: string;\n /**\n * Sets or retrieves the value of a list item.\n */\n value: number;\n addEventListener(type: K, listener: (this: HTMLLIElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLIElement: {\n prototype: HTMLLIElement;\n new(): HTMLLIElement;\n};\n\ninterface HTMLLinkElement extends HTMLElement, LinkStyle {\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n disabled: boolean;\n /**\n * Sets or retrieves a destination URL or an anchor point.\n */\n href: string;\n /**\n * Sets or retrieves the language code of the object.\n */\n hreflang: string;\n /**\n * Sets or retrieves the media type.\n */\n media: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rel: string;\n /**\n * Sets or retrieves the relationship between the object and the destination of the link.\n */\n rev: string;\n /**\n * Sets or retrieves the window or frame at which to target content.\n */\n target: string;\n /**\n * Sets or retrieves the MIME type of the object.\n */\n type: string;\n import?: Document;\n integrity: string;\n addEventListener(type: K, listener: (this: HTMLLinkElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLLinkElement: {\n prototype: HTMLLinkElement;\n new(): HTMLLinkElement;\n};\n\ninterface HTMLMapElement extends HTMLElement {\n /**\n * Retrieves a collection of the area objects defined for the given map object.\n */\n readonly areas: HTMLAreasCollection;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n addEventListener(type: K, listener: (this: HTMLMapElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMapElement: {\n prototype: HTMLMapElement;\n new(): HTMLMapElement;\n};\n\ninterface HTMLMarqueeElementEventMap extends HTMLElementEventMap {\n \"bounce\": Event;\n \"finish\": Event;\n \"start\": Event;\n}\n\ninterface HTMLMarqueeElement extends HTMLElement {\n behavior: string;\n bgColor: any;\n direction: string;\n height: string;\n hspace: number;\n loop: number;\n onbounce: (this: HTMLMarqueeElement, ev: Event) => any;\n onfinish: (this: HTMLMarqueeElement, ev: Event) => any;\n onstart: (this: HTMLMarqueeElement, ev: Event) => any;\n scrollAmount: number;\n scrollDelay: number;\n trueSpeed: boolean;\n vspace: number;\n width: string;\n start(): void;\n stop(): void;\n addEventListener(type: K, listener: (this: HTMLMarqueeElement, ev: HTMLMarqueeElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMarqueeElement: {\n prototype: HTMLMarqueeElement;\n new(): HTMLMarqueeElement;\n};\n\ninterface HTMLMediaElementEventMap extends HTMLElementEventMap {\n \"encrypted\": MediaEncryptedEvent;\n \"msneedkey\": MSMediaKeyNeededEvent;\n}\n\ninterface HTMLMediaElement extends HTMLElement {\n /**\n * Returns an AudioTrackList object with the audio tracks for a given video element.\n */\n readonly audioTracks: AudioTrackList;\n /**\n * Gets or sets a value that indicates whether to start playing the media automatically.\n */\n autoplay: boolean;\n /**\n * Gets a collection of buffered time ranges.\n */\n readonly buffered: TimeRanges;\n /**\n * Gets or sets a flag that indicates whether the client provides a set of controls for the media (in case the developer does not include controls for the player).\n */\n controls: boolean;\n crossOrigin: string | null;\n /**\n * Gets the address or URL of the current media resource that is selected by IHTMLMediaElement.\n */\n readonly currentSrc: string;\n /**\n * Gets or sets the current playback position, in seconds.\n */\n currentTime: number;\n defaultMuted: boolean;\n /**\n * Gets or sets the default playback rate when the user is not using fast forward or reverse for a video or audio resource.\n */\n defaultPlaybackRate: number;\n /**\n * Returns the duration in seconds of the current media resource. A NaN value is returned if duration is not available, or Infinity if the media resource is streaming.\n */\n readonly duration: number;\n /**\n * Gets information about whether the playback has ended or not.\n */\n readonly ended: boolean;\n /**\n * Returns an object representing the current error state of the audio or video element.\n */\n readonly error: MediaError;\n /**\n * Gets or sets a flag to specify whether playback should restart after it completes.\n */\n loop: boolean;\n readonly mediaKeys: MediaKeys | null;\n /**\n * Specifies the purpose of the audio or video media, such as background audio or alerts.\n */\n msAudioCategory: string;\n /**\n * Specifies the output device id that the audio will be sent to.\n */\n msAudioDeviceType: string;\n readonly msGraphicsTrustStatus: MSGraphicsTrust;\n /**\n * Gets the MSMediaKeys object, which is used for decrypting media data, that is associated with this media element.\n */\n readonly msKeys: MSMediaKeys;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n /**\n * Gets or sets the path to the preferred media source. This enables the Play To target device to stream the media content, which can be DRM protected, from a different location, such as a cloud media server.\n */\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Specifies whether or not to enable low-latency playback on the media element.\n */\n msRealTime: boolean;\n /**\n * Gets or sets a flag that indicates whether the audio (either audio or the audio track on video media) is muted.\n */\n muted: boolean;\n /**\n * Gets the current network activity for the element.\n */\n readonly networkState: number;\n onencrypted: (this: HTMLMediaElement, ev: MediaEncryptedEvent) => any;\n onmsneedkey: (this: HTMLMediaElement, ev: MSMediaKeyNeededEvent) => any;\n /**\n * Gets a flag that specifies whether playback is paused.\n */\n readonly paused: boolean;\n /**\n * Gets or sets the current rate of speed for the media resource to play. This speed is expressed as a multiple of the normal speed of the media resource.\n */\n playbackRate: number;\n /**\n * Gets TimeRanges for the current media resource that has been played.\n */\n readonly played: TimeRanges;\n /**\n * Gets or sets the current playback position, in seconds.\n */\n preload: string;\n readyState: number;\n /**\n * Returns a TimeRanges object that represents the ranges of the current media resource that can be seeked.\n */\n readonly seekable: TimeRanges;\n /**\n * Gets a flag that indicates whether the the client is currently moving to a new playback position in the media resource.\n */\n readonly seeking: boolean;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n srcObject: MediaStream | null;\n readonly textTracks: TextTrackList;\n readonly videoTracks: VideoTrackList;\n /**\n * Gets or sets the volume level for audio portions of the media element.\n */\n volume: number;\n addTextTrack(kind: string, label?: string, language?: string): TextTrack;\n /**\n * Returns a string that specifies whether the client can play a given media resource type.\n */\n canPlayType(type: string): string;\n /**\n * Resets the audio or video object and loads a new media resource.\n */\n load(): void;\n /**\n * Clears all effects from the media pipeline.\n */\n msClearEffects(): void;\n msGetAsCastingSource(): any;\n /**\n * Inserts the specified audio effect into media pipeline.\n */\n msInsertAudioEffect(activatableClassId: string, effectRequired: boolean, config?: any): void;\n msSetMediaKeys(mediaKeys: MSMediaKeys): void;\n /**\n * Specifies the media protection manager for a given media pipeline.\n */\n msSetMediaProtectionManager(mediaProtectionManager?: any): void;\n /**\n * Pauses the current playback and sets paused to TRUE. This can be used to test whether the media is playing or paused. You can also use the pause or play events to tell whether the media is playing or not.\n */\n pause(): void;\n /**\n * Loads and starts playback of a media resource.\n */\n play(): Promise;\n setMediaKeys(mediaKeys: MediaKeys | null): Promise;\n readonly HAVE_CURRENT_DATA: number;\n readonly HAVE_ENOUGH_DATA: number;\n readonly HAVE_FUTURE_DATA: number;\n readonly HAVE_METADATA: number;\n readonly HAVE_NOTHING: number;\n readonly NETWORK_EMPTY: number;\n readonly NETWORK_IDLE: number;\n readonly NETWORK_LOADING: number;\n readonly NETWORK_NO_SOURCE: number;\n addEventListener(type: K, listener: (this: HTMLMediaElement, ev: HTMLMediaElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMediaElement: {\n prototype: HTMLMediaElement;\n new(): HTMLMediaElement;\n readonly HAVE_CURRENT_DATA: number;\n readonly HAVE_ENOUGH_DATA: number;\n readonly HAVE_FUTURE_DATA: number;\n readonly HAVE_METADATA: number;\n readonly HAVE_NOTHING: number;\n readonly NETWORK_EMPTY: number;\n readonly NETWORK_IDLE: number;\n readonly NETWORK_LOADING: number;\n readonly NETWORK_NO_SOURCE: number;\n};\n\ninterface HTMLMenuElement extends HTMLElement {\n compact: boolean;\n type: string;\n addEventListener(type: K, listener: (this: HTMLMenuElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMenuElement: {\n prototype: HTMLMenuElement;\n new(): HTMLMenuElement;\n};\n\ninterface HTMLMetaElement extends HTMLElement {\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n /**\n * Gets or sets meta-information to associate with httpEquiv or name.\n */\n content: string;\n /**\n * Gets or sets information used to bind the value of a content attribute of a meta element to an HTTP response header.\n */\n httpEquiv: string;\n /**\n * Sets or retrieves the value specified in the content attribute of the meta object.\n */\n name: string;\n /**\n * Sets or retrieves a scheme to be used in interpreting the value of a property specified for the object.\n */\n scheme: string;\n /**\n * Sets or retrieves the URL property that will be loaded after the specified time has elapsed.\n */\n url: string;\n addEventListener(type: K, listener: (this: HTMLMetaElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMetaElement: {\n prototype: HTMLMetaElement;\n new(): HTMLMetaElement;\n};\n\ninterface HTMLMeterElement extends HTMLElement {\n high: number;\n low: number;\n max: number;\n min: number;\n optimum: number;\n value: number;\n addEventListener(type: K, listener: (this: HTMLMeterElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLMeterElement: {\n prototype: HTMLMeterElement;\n new(): HTMLMeterElement;\n};\n\ninterface HTMLModElement extends HTMLElement {\n /**\n * Sets or retrieves reference information about the object.\n */\n cite: string;\n /**\n * Sets or retrieves the date and time of a modification to the object.\n */\n dateTime: string;\n addEventListener(type: K, listener: (this: HTMLModElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLModElement: {\n prototype: HTMLModElement;\n new(): HTMLModElement;\n};\n\ninterface HTMLObjectElement extends HTMLElement, GetSVGDocument {\n align: string;\n /**\n * Sets or retrieves a text alternative to the graphic.\n */\n alt: string;\n /**\n * Gets or sets the optional alternative HTML script to execute if the object fails to load.\n */\n altHtml: string;\n /**\n * Sets or retrieves a character string that can be used to implement your own archive functionality for the object.\n */\n archive: string;\n /**\n * Retrieves a string of the URL where the object tag can be found. This is often the href of the document that the object is in, or the value set by a base element.\n */\n readonly BaseHref: string;\n border: string;\n /**\n * Sets or retrieves the URL of the file containing the compiled Java class.\n */\n code: string;\n /**\n * Sets or retrieves the URL of the component.\n */\n codeBase: string;\n /**\n * Sets or retrieves the Internet media type for the code associated with the object.\n */\n codeType: string;\n /**\n * Retrieves the document object of the page or frame.\n */\n readonly contentDocument: Document;\n /**\n * Sets or retrieves the URL that references the data of the object.\n */\n data: string;\n declare: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the height of the object.\n */\n height: string;\n hspace: number;\n /**\n * Gets or sets whether the DLNA PlayTo device is available.\n */\n msPlayToDisabled: boolean;\n /**\n * Gets or sets the path to the preferred media source. This enables the Play To target device to stream the media content, which can be DRM protected, from a different location, such as a cloud media server.\n */\n msPlayToPreferredSourceUri: string;\n /**\n * Gets or sets the primary DLNA PlayTo device.\n */\n msPlayToPrimary: boolean;\n /**\n * Gets the source associated with the media element for use by the PlayToManager.\n */\n readonly msPlayToSource: any;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n readonly readyState: number;\n /**\n * Sets or retrieves a message to be displayed while an object is loading.\n */\n standby: string;\n /**\n * Sets or retrieves the MIME type of the object.\n */\n type: string;\n /**\n * Sets or retrieves the URL, often with a bookmark extension (#name), to use as a client-side image map.\n */\n useMap: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n vspace: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLObjectElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLObjectElement: {\n prototype: HTMLObjectElement;\n new(): HTMLObjectElement;\n};\n\ninterface HTMLOListElement extends HTMLElement {\n compact: boolean;\n /**\n * The starting number.\n */\n start: number;\n type: string;\n addEventListener(type: K, listener: (this: HTMLOListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOListElement: {\n prototype: HTMLOListElement;\n new(): HTMLOListElement;\n};\n\ninterface HTMLOptGroupElement extends HTMLElement {\n /**\n * Sets or retrieves the status of an option.\n */\n defaultSelected: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the ordinal position of an option in a list box.\n */\n readonly index: number;\n /**\n * Sets or retrieves a value that you can use to implement your own label functionality for the object.\n */\n label: string;\n /**\n * Sets or retrieves whether the option in the list box is the default item.\n */\n selected: boolean;\n /**\n * Sets or retrieves the text string specified by the option tag.\n */\n readonly text: string;\n /**\n * Sets or retrieves the value which is returned to the server when the form control is submitted.\n */\n value: string;\n addEventListener(type: K, listener: (this: HTMLOptGroupElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOptGroupElement: {\n prototype: HTMLOptGroupElement;\n new(): HTMLOptGroupElement;\n};\n\ninterface HTMLOptionElement extends HTMLElement {\n /**\n * Sets or retrieves the status of an option.\n */\n defaultSelected: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the ordinal position of an option in a list box.\n */\n readonly index: number;\n /**\n * Sets or retrieves a value that you can use to implement your own label functionality for the object.\n */\n label: string;\n /**\n * Sets or retrieves whether the option in the list box is the default item.\n */\n selected: boolean;\n /**\n * Sets or retrieves the text string specified by the option tag.\n */\n text: string;\n /**\n * Sets or retrieves the value which is returned to the server when the form control is submitted.\n */\n value: string;\n addEventListener(type: K, listener: (this: HTMLOptionElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOptionElement: {\n prototype: HTMLOptionElement;\n new(): HTMLOptionElement;\n};\n\ninterface HTMLOptionsCollection extends HTMLCollectionOf {\n length: number;\n selectedIndex: number;\n add(element: HTMLOptionElement | HTMLOptGroupElement, before?: HTMLElement | number): void;\n remove(index: number): void;\n}\n\ndeclare var HTMLOptionsCollection: {\n prototype: HTMLOptionsCollection;\n new(): HTMLOptionsCollection;\n};\n\ninterface HTMLOutputElement extends HTMLElement {\n defaultValue: string;\n readonly form: HTMLFormElement;\n readonly htmlFor: DOMSettableTokenList;\n name: string;\n readonly type: string;\n readonly validationMessage: string;\n readonly validity: ValidityState;\n value: string;\n readonly willValidate: boolean;\n checkValidity(): boolean;\n reportValidity(): boolean;\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLOutputElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLOutputElement: {\n prototype: HTMLOutputElement;\n new(): HTMLOutputElement;\n};\n\ninterface HTMLParagraphElement extends HTMLElement {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n clear: string;\n addEventListener(type: K, listener: (this: HTMLParagraphElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLParagraphElement: {\n prototype: HTMLParagraphElement;\n new(): HTMLParagraphElement;\n};\n\ninterface HTMLParamElement extends HTMLElement {\n /**\n * Sets or retrieves the name of an input parameter for an element.\n */\n name: string;\n /**\n * Sets or retrieves the content type of the resource designated by the value attribute.\n */\n type: string;\n /**\n * Sets or retrieves the value of an input parameter for an element.\n */\n value: string;\n /**\n * Sets or retrieves the data type of the value attribute.\n */\n valueType: string;\n addEventListener(type: K, listener: (this: HTMLParamElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLParamElement: {\n prototype: HTMLParamElement;\n new(): HTMLParamElement;\n};\n\ninterface HTMLPictureElement extends HTMLElement {\n addEventListener(type: K, listener: (this: HTMLPictureElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLPictureElement: {\n prototype: HTMLPictureElement;\n new(): HTMLPictureElement;\n};\n\ninterface HTMLPreElement extends HTMLElement {\n /**\n * Sets or gets a value that you can use to implement your own width functionality for the object.\n */\n width: number;\n addEventListener(type: K, listener: (this: HTMLPreElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLPreElement: {\n prototype: HTMLPreElement;\n new(): HTMLPreElement;\n};\n\ninterface HTMLProgressElement extends HTMLElement {\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Defines the maximum, or \"done\" value for a progress element.\n */\n max: number;\n /**\n * Returns the quotient of value/max when the value attribute is set (determinate progress bar), or -1 when the value attribute is missing (indeterminate progress bar).\n */\n readonly position: number;\n /**\n * Sets or gets the current value of a progress element. The value must be a non-negative number between 0 and the max value.\n */\n value: number;\n addEventListener(type: K, listener: (this: HTMLProgressElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLProgressElement: {\n prototype: HTMLProgressElement;\n new(): HTMLProgressElement;\n};\n\ninterface HTMLQuoteElement extends HTMLElement {\n /**\n * Sets or retrieves reference information about the object.\n */\n cite: string;\n addEventListener(type: K, listener: (this: HTMLQuoteElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLQuoteElement: {\n prototype: HTMLQuoteElement;\n new(): HTMLQuoteElement;\n};\n\ninterface HTMLScriptElement extends HTMLElement {\n async: boolean;\n /**\n * Sets or retrieves the character set used to encode the object.\n */\n charset: string;\n crossOrigin: string | null;\n /**\n * Sets or retrieves the status of the script.\n */\n defer: boolean;\n /**\n * Sets or retrieves the event for which the script is written.\n */\n event: string;\n /**\n * Sets or retrieves the object that is bound to the event script.\n */\n htmlFor: string;\n /**\n * Retrieves the URL to an external file that contains the source code or data.\n */\n src: string;\n /**\n * Retrieves or sets the text of the object as a string.\n */\n text: string;\n /**\n * Sets or retrieves the MIME type for the associated scripting engine.\n */\n type: string;\n integrity: string;\n addEventListener(type: K, listener: (this: HTMLScriptElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLScriptElement: {\n prototype: HTMLScriptElement;\n new(): HTMLScriptElement;\n};\n\ninterface HTMLSelectElement extends HTMLElement {\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the number of objects in a collection.\n */\n length: number;\n /**\n * Sets or retrieves the Boolean value indicating whether multiple items can be selected from a list.\n */\n multiple: boolean;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n readonly options: HTMLOptionsCollection;\n /**\n * When present, marks an element that can't be submitted without a value.\n */\n required: boolean;\n /**\n * Sets or retrieves the index of the selected option in a select object.\n */\n selectedIndex: number;\n selectedOptions: HTMLCollectionOf;\n /**\n * Sets or retrieves the number of rows in the list box.\n */\n size: number;\n /**\n * Retrieves the type of select control based on the value of the MULTIPLE attribute.\n */\n readonly type: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Sets or retrieves the value which is returned to the server when the form control is submitted.\n */\n value: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Adds an element to the areas, controlRange, or options collection.\n * @param element Variant of type Number that specifies the index position in the collection where the element is placed. If no value is given, the method places the element at the end of the collection.\n * @param before Variant of type Object that specifies an element to insert before, or null to append the object to the collection.\n */\n add(element: HTMLElement, before?: HTMLElement | number): void;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Retrieves a select object or an object from an options collection.\n * @param name Variant of type Number or String that specifies the object or collection to retrieve. If this parameter is an integer, it is the zero-based index of the object. If this parameter is a string, all objects with matching name or id properties are retrieved, and a collection is returned if more than one match is made.\n * @param index Variant of type Number that specifies the zero-based index of the object to retrieve when a collection is returned.\n */\n item(name?: any, index?: any): any;\n /**\n * Retrieves a select object or an object from an options collection.\n * @param namedItem A String that specifies the name or id property of the object to retrieve. A collection is returned if more than one match is made.\n */\n namedItem(name: string): any;\n /**\n * Removes an element from the collection.\n * @param index Number that specifies the zero-based index of the element to remove from the collection.\n */\n remove(index?: number): void;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n addEventListener(type: K, listener: (this: HTMLSelectElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [name: string]: any;\n}\n\ndeclare var HTMLSelectElement: {\n prototype: HTMLSelectElement;\n new(): HTMLSelectElement;\n};\n\ninterface HTMLSourceElement extends HTMLElement {\n /**\n * Gets or sets the intended media type of the media source.\n */\n media: string;\n msKeySystem: string;\n sizes: string;\n /**\n * The address or URL of the a media resource that is to be considered.\n */\n src: string;\n srcset: string;\n /**\n * Gets or sets the MIME type of a media resource.\n */\n type: string;\n addEventListener(type: K, listener: (this: HTMLSourceElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLSourceElement: {\n prototype: HTMLSourceElement;\n new(): HTMLSourceElement;\n};\n\ninterface HTMLSpanElement extends HTMLElement {\n addEventListener(type: K, listener: (this: HTMLSpanElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLSpanElement: {\n prototype: HTMLSpanElement;\n new(): HTMLSpanElement;\n};\n\ninterface HTMLStyleElement extends HTMLElement, LinkStyle {\n disabled: boolean;\n /**\n * Sets or retrieves the media type.\n */\n media: string;\n /**\n * Retrieves the CSS language in which the style sheet is written.\n */\n type: string;\n addEventListener(type: K, listener: (this: HTMLStyleElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLStyleElement: {\n prototype: HTMLStyleElement;\n new(): HTMLStyleElement;\n};\n\ninterface HTMLTableCaptionElement extends HTMLElement {\n /**\n * Sets or retrieves the alignment of the caption or legend.\n */\n align: string;\n /**\n * Sets or retrieves whether the caption appears at the top or bottom of the table.\n */\n vAlign: string;\n addEventListener(type: K, listener: (this: HTMLTableCaptionElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableCaptionElement: {\n prototype: HTMLTableCaptionElement;\n new(): HTMLTableCaptionElement;\n};\n\ninterface HTMLTableCellElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves abbreviated text for the object.\n */\n abbr: string;\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n /**\n * Sets or retrieves a comma-delimited list of conceptual categories associated with the object.\n */\n axis: string;\n bgColor: any;\n /**\n * Retrieves the position of the object in the cells collection of a row.\n */\n readonly cellIndex: number;\n /**\n * Sets or retrieves the number columns in the table that the object should span.\n */\n colSpan: number;\n /**\n * Sets or retrieves a list of header cells that provide information for the object.\n */\n headers: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: any;\n /**\n * Sets or retrieves whether the browser automatically performs wordwrap.\n */\n noWrap: boolean;\n /**\n * Sets or retrieves how many rows in a table the cell should span.\n */\n rowSpan: number;\n /**\n * Sets or retrieves the group of cells in a table to which the object's information applies.\n */\n scope: string;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n addEventListener(type: K, listener: (this: HTMLTableCellElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableCellElement: {\n prototype: HTMLTableCellElement;\n new(): HTMLTableCellElement;\n};\n\ninterface HTMLTableColElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves the alignment of the object relative to the display or table.\n */\n align: string;\n /**\n * Sets or retrieves the number of columns in the group.\n */\n span: number;\n /**\n * Sets or retrieves the width of the object.\n */\n width: any;\n addEventListener(type: K, listener: (this: HTMLTableColElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableColElement: {\n prototype: HTMLTableColElement;\n new(): HTMLTableColElement;\n};\n\ninterface HTMLTableDataCellElement extends HTMLTableCellElement {\n addEventListener(type: K, listener: (this: HTMLTableDataCellElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableDataCellElement: {\n prototype: HTMLTableDataCellElement;\n new(): HTMLTableDataCellElement;\n};\n\ninterface HTMLTableElement extends HTMLElement {\n /**\n * Sets or retrieves a value that indicates the table alignment.\n */\n align: string;\n bgColor: any;\n /**\n * Sets or retrieves the width of the border to draw around the object.\n */\n border: string;\n /**\n * Sets or retrieves the border color of the object.\n */\n borderColor: any;\n /**\n * Retrieves the caption object of a table.\n */\n caption: HTMLTableCaptionElement;\n /**\n * Sets or retrieves the amount of space between the border of the cell and the content of the cell.\n */\n cellPadding: string;\n /**\n * Sets or retrieves the amount of space between cells in a table.\n */\n cellSpacing: string;\n /**\n * Sets or retrieves the number of columns in the table.\n */\n cols: number;\n /**\n * Sets or retrieves the way the border frame around the table is displayed.\n */\n frame: string;\n /**\n * Sets or retrieves the height of the object.\n */\n height: any;\n /**\n * Sets or retrieves the number of horizontal rows contained in the object.\n */\n rows: HTMLCollectionOf;\n /**\n * Sets or retrieves which dividing lines (inner borders) are displayed.\n */\n rules: string;\n /**\n * Sets or retrieves a description and/or structure of the object.\n */\n summary: string;\n /**\n * Retrieves a collection of all tBody objects in the table. Objects in this collection are in source order.\n */\n tBodies: HTMLCollectionOf;\n /**\n * Retrieves the tFoot object of the table.\n */\n tFoot: HTMLTableSectionElement;\n /**\n * Retrieves the tHead object of the table.\n */\n tHead: HTMLTableSectionElement;\n /**\n * Sets or retrieves the width of the object.\n */\n width: string;\n /**\n * Creates an empty caption element in the table.\n */\n createCaption(): HTMLTableCaptionElement;\n /**\n * Creates an empty tBody element in the table.\n */\n createTBody(): HTMLTableSectionElement;\n /**\n * Creates an empty tFoot element in the table.\n */\n createTFoot(): HTMLTableSectionElement;\n /**\n * Returns the tHead element object if successful, or null otherwise.\n */\n createTHead(): HTMLTableSectionElement;\n /**\n * Deletes the caption element and its contents from the table.\n */\n deleteCaption(): void;\n /**\n * Removes the specified row (tr) from the element and from the rows collection.\n * @param index Number that specifies the zero-based position in the rows collection of the row to remove.\n */\n deleteRow(index?: number): void;\n /**\n * Deletes the tFoot element and its contents from the table.\n */\n deleteTFoot(): void;\n /**\n * Deletes the tHead element and its contents from the table.\n */\n deleteTHead(): void;\n /**\n * Creates a new row (tr) in the table, and adds the row to the rows collection.\n * @param index Number that specifies where to insert the row in the rows collection. The default value is -1, which appends the new row to the end of the rows collection.\n */\n insertRow(index?: number): HTMLTableRowElement;\n addEventListener(type: K, listener: (this: HTMLTableElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableElement: {\n prototype: HTMLTableElement;\n new(): HTMLTableElement;\n};\n\ninterface HTMLTableHeaderCellElement extends HTMLTableCellElement {\n /**\n * Sets or retrieves the group of cells in a table to which the object's information applies.\n */\n scope: string;\n addEventListener(type: K, listener: (this: HTMLTableHeaderCellElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableHeaderCellElement: {\n prototype: HTMLTableHeaderCellElement;\n new(): HTMLTableHeaderCellElement;\n};\n\ninterface HTMLTableRowElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves how the object is aligned with adjacent text.\n */\n align: string;\n bgColor: any;\n /**\n * Retrieves a collection of all cells in the table row.\n */\n cells: HTMLCollectionOf;\n /**\n * Sets or retrieves the height of the object.\n */\n height: any;\n /**\n * Retrieves the position of the object in the rows collection for the table.\n */\n readonly rowIndex: number;\n /**\n * Retrieves the position of the object in the collection.\n */\n readonly sectionRowIndex: number;\n /**\n * Removes the specified cell from the table row, as well as from the cells collection.\n * @param index Number that specifies the zero-based position of the cell to remove from the table row. If no value is provided, the last cell in the cells collection is deleted.\n */\n deleteCell(index?: number): void;\n /**\n * Creates a new cell in the table row, and adds the cell to the cells collection.\n * @param index Number that specifies where to insert the cell in the tr. The default value is -1, which appends the new cell to the end of the cells collection.\n */\n insertCell(index?: number): HTMLTableDataCellElement;\n addEventListener(type: K, listener: (this: HTMLTableRowElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableRowElement: {\n prototype: HTMLTableRowElement;\n new(): HTMLTableRowElement;\n};\n\ninterface HTMLTableSectionElement extends HTMLElement, HTMLTableAlignment {\n /**\n * Sets or retrieves a value that indicates the table alignment.\n */\n align: string;\n /**\n * Sets or retrieves the number of horizontal rows contained in the object.\n */\n rows: HTMLCollectionOf;\n /**\n * Removes the specified row (tr) from the element and from the rows collection.\n * @param index Number that specifies the zero-based position in the rows collection of the row to remove.\n */\n deleteRow(index?: number): void;\n /**\n * Creates a new row (tr) in the table, and adds the row to the rows collection.\n * @param index Number that specifies where to insert the row in the rows collection. The default value is -1, which appends the new row to the end of the rows collection.\n */\n insertRow(index?: number): HTMLTableRowElement;\n addEventListener(type: K, listener: (this: HTMLTableSectionElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTableSectionElement: {\n prototype: HTMLTableSectionElement;\n new(): HTMLTableSectionElement;\n};\n\ninterface HTMLTemplateElement extends HTMLElement {\n readonly content: DocumentFragment;\n addEventListener(type: K, listener: (this: HTMLTemplateElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTemplateElement: {\n prototype: HTMLTemplateElement;\n new(): HTMLTemplateElement;\n};\n\ninterface HTMLTextAreaElement extends HTMLElement {\n /**\n * Provides a way to direct a user to a specific field when a document loads. This can provide both direction and convenience for a user, reducing the need to click or tab to a field when a page opens. This attribute is true when present on an element, and false when missing.\n */\n autofocus: boolean;\n /**\n * Sets or retrieves the width of the object.\n */\n cols: number;\n /**\n * Sets or retrieves the initial contents of the object.\n */\n defaultValue: string;\n disabled: boolean;\n /**\n * Retrieves a reference to the form that the object is embedded in.\n */\n readonly form: HTMLFormElement;\n /**\n * Sets or retrieves the maximum number of characters that the user can enter in a text control.\n */\n maxLength: number;\n /**\n * Sets or retrieves the name of the object.\n */\n name: string;\n /**\n * Gets or sets a text string that is displayed in an input field as a hint or prompt to users as the format or type of information they need to enter.The text appears in an input field until the user puts focus on the field.\n */\n placeholder: string;\n /**\n * Sets or retrieves the value indicated whether the content of the object is read-only.\n */\n readOnly: boolean;\n /**\n * When present, marks an element that can't be submitted without a value.\n */\n required: boolean;\n /**\n * Sets or retrieves the number of horizontal rows contained in the object.\n */\n rows: number;\n /**\n * Gets or sets the end position or offset of a text selection.\n */\n selectionEnd: number;\n /**\n * Gets or sets the starting position or offset of a text selection.\n */\n selectionStart: number;\n /**\n * Sets or retrieves the value indicating whether the control is selected.\n */\n status: any;\n /**\n * Retrieves the type of control.\n */\n readonly type: string;\n /**\n * Returns the error message that would be displayed if the user submits the form, or an empty string if no error message. It also triggers the standard error message, such as \"this is a required field\". The result is that the user sees validation messages without actually submitting.\n */\n readonly validationMessage: string;\n /**\n * Returns a ValidityState object that represents the validity states of an element.\n */\n readonly validity: ValidityState;\n /**\n * Retrieves or sets the text in the entry field of the textArea element.\n */\n value: string;\n /**\n * Returns whether an element will successfully validate based on forms validation rules and constraints.\n */\n readonly willValidate: boolean;\n /**\n * Sets or retrieves how to handle wordwrapping in the object.\n */\n wrap: string;\n minLength: number;\n /**\n * Returns whether a form will validate when it is submitted, without having to submit it.\n */\n checkValidity(): boolean;\n /**\n * Highlights the input area of a form element.\n */\n select(): void;\n /**\n * Sets a custom error message that is displayed when a form is submitted.\n * @param error Sets a custom error message that is displayed when a form is submitted.\n */\n setCustomValidity(error: string): void;\n /**\n * Sets the start and end positions of a selection in a text field.\n * @param start The offset into the text field for the start of the selection.\n * @param end The offset into the text field for the end of the selection.\n */\n setSelectionRange(start: number, end: number): void;\n addEventListener(type: K, listener: (this: HTMLTextAreaElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTextAreaElement: {\n prototype: HTMLTextAreaElement;\n new(): HTMLTextAreaElement;\n};\n\ninterface HTMLTimeElement extends HTMLElement {\n dateTime: string;\n addEventListener(type: K, listener: (this: HTMLTimeElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTimeElement: {\n prototype: HTMLTimeElement;\n new(): HTMLTimeElement;\n};\n\ninterface HTMLTitleElement extends HTMLElement {\n /**\n * Retrieves or sets the text of the object as a string.\n */\n text: string;\n addEventListener(type: K, listener: (this: HTMLTitleElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTitleElement: {\n prototype: HTMLTitleElement;\n new(): HTMLTitleElement;\n};\n\ninterface HTMLTrackElement extends HTMLElement {\n default: boolean;\n kind: string;\n label: string;\n readonly readyState: number;\n src: string;\n srclang: string;\n readonly track: TextTrack;\n readonly ERROR: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n addEventListener(type: K, listener: (this: HTMLTrackElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLTrackElement: {\n prototype: HTMLTrackElement;\n new(): HTMLTrackElement;\n readonly ERROR: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n};\n\ninterface HTMLUListElement extends HTMLElement {\n compact: boolean;\n type: string;\n addEventListener(type: K, listener: (this: HTMLUListElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLUListElement: {\n prototype: HTMLUListElement;\n new(): HTMLUListElement;\n};\n\ninterface HTMLUnknownElement extends HTMLElement {\n addEventListener(type: K, listener: (this: HTMLUnknownElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLUnknownElement: {\n prototype: HTMLUnknownElement;\n new(): HTMLUnknownElement;\n};\n\ninterface HTMLVideoElementEventMap extends HTMLMediaElementEventMap {\n \"MSVideoFormatChanged\": Event;\n \"MSVideoFrameStepCompleted\": Event;\n \"MSVideoOptimalLayoutChanged\": Event;\n}\n\ninterface HTMLVideoElement extends HTMLMediaElement {\n /**\n * Gets or sets the height of the video element.\n */\n height: number;\n msHorizontalMirror: boolean;\n readonly msIsLayoutOptimalForPlayback: boolean;\n readonly msIsStereo3D: boolean;\n msStereo3DPackingMode: string;\n msStereo3DRenderMode: string;\n msZoom: boolean;\n onMSVideoFormatChanged: (this: HTMLVideoElement, ev: Event) => any;\n onMSVideoFrameStepCompleted: (this: HTMLVideoElement, ev: Event) => any;\n onMSVideoOptimalLayoutChanged: (this: HTMLVideoElement, ev: Event) => any;\n /**\n * Gets or sets a URL of an image to display, for example, like a movie poster. This can be a still frame from the video, or another image if no video data is available.\n */\n poster: string;\n /**\n * Gets the intrinsic height of a video in CSS pixels, or zero if the dimensions are not known.\n */\n readonly videoHeight: number;\n /**\n * Gets the intrinsic width of a video in CSS pixels, or zero if the dimensions are not known.\n */\n readonly videoWidth: number;\n readonly webkitDisplayingFullscreen: boolean;\n readonly webkitSupportsFullscreen: boolean;\n /**\n * Gets or sets the width of the video element.\n */\n width: number;\n getVideoPlaybackQuality(): VideoPlaybackQuality;\n msFrameStep(forward: boolean): void;\n msInsertVideoEffect(activatableClassId: string, effectRequired: boolean, config?: any): void;\n msSetVideoRectangle(left: number, top: number, right: number, bottom: number): void;\n webkitEnterFullscreen(): void;\n webkitEnterFullScreen(): void;\n webkitExitFullscreen(): void;\n webkitExitFullScreen(): void;\n addEventListener(type: K, listener: (this: HTMLVideoElement, ev: HTMLVideoElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var HTMLVideoElement: {\n prototype: HTMLVideoElement;\n new(): HTMLVideoElement;\n};\n\ninterface IDBCursor {\n readonly direction: IDBCursorDirection;\n key: IDBKeyRange | IDBValidKey;\n readonly primaryKey: any;\n source: IDBObjectStore | IDBIndex;\n advance(count: number): void;\n continue(key?: IDBKeyRange | IDBValidKey): void;\n delete(): IDBRequest;\n update(value: any): IDBRequest;\n readonly NEXT: string;\n readonly NEXT_NO_DUPLICATE: string;\n readonly PREV: string;\n readonly PREV_NO_DUPLICATE: string;\n}\n\ndeclare var IDBCursor: {\n prototype: IDBCursor;\n new(): IDBCursor;\n readonly NEXT: string;\n readonly NEXT_NO_DUPLICATE: string;\n readonly PREV: string;\n readonly PREV_NO_DUPLICATE: string;\n};\n\ninterface IDBCursorWithValue extends IDBCursor {\n readonly value: any;\n}\n\ndeclare var IDBCursorWithValue: {\n prototype: IDBCursorWithValue;\n new(): IDBCursorWithValue;\n};\n\ninterface IDBDatabaseEventMap {\n \"abort\": Event;\n \"error\": Event;\n}\n\ninterface IDBDatabase extends EventTarget {\n readonly name: string;\n readonly objectStoreNames: DOMStringList;\n onabort: (this: IDBDatabase, ev: Event) => any;\n onerror: (this: IDBDatabase, ev: Event) => any;\n version: number;\n onversionchange: (ev: IDBVersionChangeEvent) => any;\n close(): void;\n createObjectStore(name: string, optionalParameters?: IDBObjectStoreParameters): IDBObjectStore;\n deleteObjectStore(name: string): void;\n transaction(storeNames: string | string[], mode?: IDBTransactionMode): IDBTransaction;\n addEventListener(type: \"versionchange\", listener: (ev: IDBVersionChangeEvent) => any, useCapture?: boolean): void;\n addEventListener(type: K, listener: (this: IDBDatabase, ev: IDBDatabaseEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBDatabase: {\n prototype: IDBDatabase;\n new(): IDBDatabase;\n};\n\ninterface IDBFactory {\n cmp(first: any, second: any): number;\n deleteDatabase(name: string): IDBOpenDBRequest;\n open(name: string, version?: number): IDBOpenDBRequest;\n}\n\ndeclare var IDBFactory: {\n prototype: IDBFactory;\n new(): IDBFactory;\n};\n\ninterface IDBIndex {\n keyPath: string | string[];\n readonly name: string;\n readonly objectStore: IDBObjectStore;\n readonly unique: boolean;\n multiEntry: boolean;\n count(key?: IDBKeyRange | IDBValidKey): IDBRequest;\n get(key: IDBKeyRange | IDBValidKey): IDBRequest;\n getKey(key: IDBKeyRange | IDBValidKey): IDBRequest;\n openCursor(range?: IDBKeyRange | IDBValidKey, direction?: IDBCursorDirection): IDBRequest;\n openKeyCursor(range?: IDBKeyRange | IDBValidKey, direction?: IDBCursorDirection): IDBRequest;\n}\n\ndeclare var IDBIndex: {\n prototype: IDBIndex;\n new(): IDBIndex;\n};\n\ninterface IDBKeyRange {\n readonly lower: any;\n readonly lowerOpen: boolean;\n readonly upper: any;\n readonly upperOpen: boolean;\n}\n\ndeclare var IDBKeyRange: {\n prototype: IDBKeyRange;\n new(): IDBKeyRange;\n bound(lower: any, upper: any, lowerOpen?: boolean, upperOpen?: boolean): IDBKeyRange;\n lowerBound(lower: any, open?: boolean): IDBKeyRange;\n only(value: any): IDBKeyRange;\n upperBound(upper: any, open?: boolean): IDBKeyRange;\n};\n\ninterface IDBObjectStore {\n readonly indexNames: DOMStringList;\n keyPath: string | string[];\n readonly name: string;\n readonly transaction: IDBTransaction;\n autoIncrement: boolean;\n add(value: any, key?: IDBKeyRange | IDBValidKey): IDBRequest;\n clear(): IDBRequest;\n count(key?: IDBKeyRange | IDBValidKey): IDBRequest;\n createIndex(name: string, keyPath: string | string[], optionalParameters?: IDBIndexParameters): IDBIndex;\n delete(key: IDBKeyRange | IDBValidKey): IDBRequest;\n deleteIndex(indexName: string): void;\n get(key: any): IDBRequest;\n index(name: string): IDBIndex;\n openCursor(range?: IDBKeyRange | IDBValidKey, direction?: IDBCursorDirection): IDBRequest;\n put(value: any, key?: IDBKeyRange | IDBValidKey): IDBRequest;\n}\n\ndeclare var IDBObjectStore: {\n prototype: IDBObjectStore;\n new(): IDBObjectStore;\n};\n\ninterface IDBOpenDBRequestEventMap extends IDBRequestEventMap {\n \"blocked\": Event;\n \"upgradeneeded\": IDBVersionChangeEvent;\n}\n\ninterface IDBOpenDBRequest extends IDBRequest {\n onblocked: (this: IDBOpenDBRequest, ev: Event) => any;\n onupgradeneeded: (this: IDBOpenDBRequest, ev: IDBVersionChangeEvent) => any;\n addEventListener(type: K, listener: (this: IDBOpenDBRequest, ev: IDBOpenDBRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBOpenDBRequest: {\n prototype: IDBOpenDBRequest;\n new(): IDBOpenDBRequest;\n};\n\ninterface IDBRequestEventMap {\n \"error\": Event;\n \"success\": Event;\n}\n\ninterface IDBRequest extends EventTarget {\n readonly error: DOMException;\n onerror: (this: IDBRequest, ev: Event) => any;\n onsuccess: (this: IDBRequest, ev: Event) => any;\n readonly readyState: IDBRequestReadyState;\n readonly result: any;\n source: IDBObjectStore | IDBIndex | IDBCursor;\n readonly transaction: IDBTransaction;\n addEventListener(type: K, listener: (this: IDBRequest, ev: IDBRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBRequest: {\n prototype: IDBRequest;\n new(): IDBRequest;\n};\n\ninterface IDBTransactionEventMap {\n \"abort\": Event;\n \"complete\": Event;\n \"error\": Event;\n}\n\ninterface IDBTransaction extends EventTarget {\n readonly db: IDBDatabase;\n readonly error: DOMException;\n readonly mode: IDBTransactionMode;\n onabort: (this: IDBTransaction, ev: Event) => any;\n oncomplete: (this: IDBTransaction, ev: Event) => any;\n onerror: (this: IDBTransaction, ev: Event) => any;\n abort(): void;\n objectStore(name: string): IDBObjectStore;\n readonly READ_ONLY: string;\n readonly READ_WRITE: string;\n readonly VERSION_CHANGE: string;\n addEventListener(type: K, listener: (this: IDBTransaction, ev: IDBTransactionEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var IDBTransaction: {\n prototype: IDBTransaction;\n new(): IDBTransaction;\n readonly READ_ONLY: string;\n readonly READ_WRITE: string;\n readonly VERSION_CHANGE: string;\n};\n\ninterface IDBVersionChangeEvent extends Event {\n readonly newVersion: number | null;\n readonly oldVersion: number;\n}\n\ndeclare var IDBVersionChangeEvent: {\n prototype: IDBVersionChangeEvent;\n new(): IDBVersionChangeEvent;\n};\n\ninterface IIRFilterNode extends AudioNode {\n getFrequencyResponse(frequencyHz: Float32Array, magResponse: Float32Array, phaseResponse: Float32Array): void;\n}\n\ndeclare var IIRFilterNode: {\n prototype: IIRFilterNode;\n new(): IIRFilterNode;\n};\n\ninterface ImageData {\n data: Uint8ClampedArray;\n readonly height: number;\n readonly width: number;\n}\n\ndeclare var ImageData: {\n prototype: ImageData;\n new(width: number, height: number): ImageData;\n new(array: Uint8ClampedArray, width: number, height: number): ImageData;\n};\n\ninterface IntersectionObserver {\n readonly root: Element | null;\n readonly rootMargin: string;\n readonly thresholds: number[];\n disconnect(): void;\n observe(target: Element): void;\n takeRecords(): IntersectionObserverEntry[];\n unobserve(target: Element): void;\n}\n\ndeclare var IntersectionObserver: {\n prototype: IntersectionObserver;\n new(callback: IntersectionObserverCallback, options?: IntersectionObserverInit): IntersectionObserver;\n};\n\ninterface IntersectionObserverEntry {\n readonly boundingClientRect: ClientRect;\n readonly intersectionRatio: number;\n readonly intersectionRect: ClientRect;\n readonly rootBounds: ClientRect;\n readonly target: Element;\n readonly time: number;\n}\n\ndeclare var IntersectionObserverEntry: {\n prototype: IntersectionObserverEntry;\n new(intersectionObserverEntryInit: IntersectionObserverEntryInit): IntersectionObserverEntry;\n};\n\ninterface KeyboardEvent extends UIEvent {\n readonly altKey: boolean;\n readonly char: string | null;\n readonly charCode: number;\n readonly ctrlKey: boolean;\n readonly key: string;\n readonly keyCode: number;\n readonly locale: string;\n readonly location: number;\n readonly metaKey: boolean;\n readonly repeat: boolean;\n readonly shiftKey: boolean;\n readonly which: number;\n readonly code: string;\n getModifierState(keyArg: string): boolean;\n initKeyboardEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, keyArg: string, locationArg: number, modifiersListArg: string, repeat: boolean, locale: string): void;\n readonly DOM_KEY_LOCATION_JOYSTICK: number;\n readonly DOM_KEY_LOCATION_LEFT: number;\n readonly DOM_KEY_LOCATION_MOBILE: number;\n readonly DOM_KEY_LOCATION_NUMPAD: number;\n readonly DOM_KEY_LOCATION_RIGHT: number;\n readonly DOM_KEY_LOCATION_STANDARD: number;\n}\n\ndeclare var KeyboardEvent: {\n prototype: KeyboardEvent;\n new(typeArg: string, eventInitDict?: KeyboardEventInit): KeyboardEvent;\n readonly DOM_KEY_LOCATION_JOYSTICK: number;\n readonly DOM_KEY_LOCATION_LEFT: number;\n readonly DOM_KEY_LOCATION_MOBILE: number;\n readonly DOM_KEY_LOCATION_NUMPAD: number;\n readonly DOM_KEY_LOCATION_RIGHT: number;\n readonly DOM_KEY_LOCATION_STANDARD: number;\n};\n\ninterface ListeningStateChangedEvent extends Event {\n readonly label: string;\n readonly state: ListeningState;\n}\n\ndeclare var ListeningStateChangedEvent: {\n prototype: ListeningStateChangedEvent;\n new(): ListeningStateChangedEvent;\n};\n\ninterface Location {\n hash: string;\n host: string;\n hostname: string;\n href: string;\n readonly origin: string;\n pathname: string;\n port: string;\n protocol: string;\n search: string;\n assign(url: string): void;\n reload(forcedReload?: boolean): void;\n replace(url: string): void;\n toString(): string;\n}\n\ndeclare var Location: {\n prototype: Location;\n new(): Location;\n};\n\ninterface LongRunningScriptDetectedEvent extends Event {\n readonly executionTime: number;\n stopPageScriptExecution: boolean;\n}\n\ndeclare var LongRunningScriptDetectedEvent: {\n prototype: LongRunningScriptDetectedEvent;\n new(): LongRunningScriptDetectedEvent;\n};\n\ninterface MediaDeviceInfo {\n readonly deviceId: string;\n readonly groupId: string;\n readonly kind: MediaDeviceKind;\n readonly label: string;\n}\n\ndeclare var MediaDeviceInfo: {\n prototype: MediaDeviceInfo;\n new(): MediaDeviceInfo;\n};\n\ninterface MediaDevicesEventMap {\n \"devicechange\": Event;\n}\n\ninterface MediaDevices extends EventTarget {\n ondevicechange: (this: MediaDevices, ev: Event) => any;\n enumerateDevices(): any;\n getSupportedConstraints(): MediaTrackSupportedConstraints;\n getUserMedia(constraints: MediaStreamConstraints): Promise;\n addEventListener(type: K, listener: (this: MediaDevices, ev: MediaDevicesEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MediaDevices: {\n prototype: MediaDevices;\n new(): MediaDevices;\n};\n\ninterface MediaElementAudioSourceNode extends AudioNode {\n}\n\ndeclare var MediaElementAudioSourceNode: {\n prototype: MediaElementAudioSourceNode;\n new(): MediaElementAudioSourceNode;\n};\n\ninterface MediaEncryptedEvent extends Event {\n readonly initData: ArrayBuffer | null;\n readonly initDataType: string;\n}\n\ndeclare var MediaEncryptedEvent: {\n prototype: MediaEncryptedEvent;\n new(type: string, eventInitDict?: MediaEncryptedEventInit): MediaEncryptedEvent;\n};\n\ninterface MediaError {\n readonly code: number;\n readonly msExtendedCode: number;\n readonly MEDIA_ERR_ABORTED: number;\n readonly MEDIA_ERR_DECODE: number;\n readonly MEDIA_ERR_NETWORK: number;\n readonly MEDIA_ERR_SRC_NOT_SUPPORTED: number;\n readonly MS_MEDIA_ERR_ENCRYPTED: number;\n}\n\ndeclare var MediaError: {\n prototype: MediaError;\n new(): MediaError;\n readonly MEDIA_ERR_ABORTED: number;\n readonly MEDIA_ERR_DECODE: number;\n readonly MEDIA_ERR_NETWORK: number;\n readonly MEDIA_ERR_SRC_NOT_SUPPORTED: number;\n readonly MS_MEDIA_ERR_ENCRYPTED: number;\n};\n\ninterface MediaKeyMessageEvent extends Event {\n readonly message: ArrayBuffer;\n readonly messageType: MediaKeyMessageType;\n}\n\ndeclare var MediaKeyMessageEvent: {\n prototype: MediaKeyMessageEvent;\n new(type: string, eventInitDict?: MediaKeyMessageEventInit): MediaKeyMessageEvent;\n};\n\ninterface MediaKeys {\n createSession(sessionType?: MediaKeySessionType): MediaKeySession;\n setServerCertificate(serverCertificate: any): Promise;\n}\n\ndeclare var MediaKeys: {\n prototype: MediaKeys;\n new(): MediaKeys;\n};\n\ninterface MediaKeySession extends EventTarget {\n readonly closed: Promise;\n readonly expiration: number;\n readonly keyStatuses: MediaKeyStatusMap;\n readonly sessionId: string;\n close(): Promise;\n generateRequest(initDataType: string, initData: any): Promise;\n load(sessionId: string): Promise;\n remove(): Promise;\n update(response: any): Promise;\n}\n\ndeclare var MediaKeySession: {\n prototype: MediaKeySession;\n new(): MediaKeySession;\n};\n\ninterface MediaKeyStatusMap {\n readonly size: number;\n forEach(callback: ForEachCallback): void;\n get(keyId: any): MediaKeyStatus;\n has(keyId: any): boolean;\n}\n\ndeclare var MediaKeyStatusMap: {\n prototype: MediaKeyStatusMap;\n new(): MediaKeyStatusMap;\n};\n\ninterface MediaKeySystemAccess {\n readonly keySystem: string;\n createMediaKeys(): Promise;\n getConfiguration(): MediaKeySystemConfiguration;\n}\n\ndeclare var MediaKeySystemAccess: {\n prototype: MediaKeySystemAccess;\n new(): MediaKeySystemAccess;\n};\n\ninterface MediaList {\n readonly length: number;\n mediaText: string;\n appendMedium(newMedium: string): void;\n deleteMedium(oldMedium: string): void;\n item(index: number): string;\n toString(): string;\n [index: number]: string;\n}\n\ndeclare var MediaList: {\n prototype: MediaList;\n new(): MediaList;\n};\n\ninterface MediaQueryList {\n readonly matches: boolean;\n readonly media: string;\n addListener(listener: MediaQueryListListener): void;\n removeListener(listener: MediaQueryListListener): void;\n}\n\ndeclare var MediaQueryList: {\n prototype: MediaQueryList;\n new(): MediaQueryList;\n};\n\ninterface MediaSource extends EventTarget {\n readonly activeSourceBuffers: SourceBufferList;\n duration: number;\n readonly readyState: string;\n readonly sourceBuffers: SourceBufferList;\n addSourceBuffer(type: string): SourceBuffer;\n endOfStream(error?: number): void;\n removeSourceBuffer(sourceBuffer: SourceBuffer): void;\n}\n\ndeclare var MediaSource: {\n prototype: MediaSource;\n new(): MediaSource;\n isTypeSupported(type: string): boolean;\n};\n\ninterface MediaStreamEventMap {\n \"active\": Event;\n \"addtrack\": MediaStreamTrackEvent;\n \"inactive\": Event;\n \"removetrack\": MediaStreamTrackEvent;\n}\n\ninterface MediaStream extends EventTarget {\n readonly active: boolean;\n readonly id: string;\n onactive: (this: MediaStream, ev: Event) => any;\n onaddtrack: (this: MediaStream, ev: MediaStreamTrackEvent) => any;\n oninactive: (this: MediaStream, ev: Event) => any;\n onremovetrack: (this: MediaStream, ev: MediaStreamTrackEvent) => any;\n addTrack(track: MediaStreamTrack): void;\n clone(): MediaStream;\n getAudioTracks(): MediaStreamTrack[];\n getTrackById(trackId: string): MediaStreamTrack | null;\n getTracks(): MediaStreamTrack[];\n getVideoTracks(): MediaStreamTrack[];\n removeTrack(track: MediaStreamTrack): void;\n stop(): void;\n addEventListener(type: K, listener: (this: MediaStream, ev: MediaStreamEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MediaStream: {\n prototype: MediaStream;\n new(streamOrTracks?: MediaStream | MediaStreamTrack[]): MediaStream;\n};\n\ninterface MediaStreamAudioSourceNode extends AudioNode {\n}\n\ndeclare var MediaStreamAudioSourceNode: {\n prototype: MediaStreamAudioSourceNode;\n new(): MediaStreamAudioSourceNode;\n};\n\ninterface MediaStreamError {\n readonly constraintName: string | null;\n readonly message: string | null;\n readonly name: string;\n}\n\ndeclare var MediaStreamError: {\n prototype: MediaStreamError;\n new(): MediaStreamError;\n};\n\ninterface MediaStreamErrorEvent extends Event {\n readonly error: MediaStreamError | null;\n}\n\ndeclare var MediaStreamErrorEvent: {\n prototype: MediaStreamErrorEvent;\n new(typeArg: string, eventInitDict?: MediaStreamErrorEventInit): MediaStreamErrorEvent;\n};\n\ninterface MediaStreamEvent extends Event {\n readonly stream: MediaStream | null;\n}\n\ndeclare var MediaStreamEvent: {\n prototype: MediaStreamEvent;\n new(type: string, eventInitDict: MediaStreamEventInit): MediaStreamEvent;\n};\n\ninterface MediaStreamTrackEventMap {\n \"ended\": MediaStreamErrorEvent;\n \"mute\": Event;\n \"overconstrained\": MediaStreamErrorEvent;\n \"unmute\": Event;\n}\n\ninterface MediaStreamTrack extends EventTarget {\n enabled: boolean;\n readonly id: string;\n readonly kind: string;\n readonly label: string;\n readonly muted: boolean;\n onended: (this: MediaStreamTrack, ev: MediaStreamErrorEvent) => any;\n onmute: (this: MediaStreamTrack, ev: Event) => any;\n onoverconstrained: (this: MediaStreamTrack, ev: MediaStreamErrorEvent) => any;\n onunmute: (this: MediaStreamTrack, ev: Event) => any;\n readonly readonly: boolean;\n readonly readyState: MediaStreamTrackState;\n readonly remote: boolean;\n applyConstraints(constraints: MediaTrackConstraints): Promise;\n clone(): MediaStreamTrack;\n getCapabilities(): MediaTrackCapabilities;\n getConstraints(): MediaTrackConstraints;\n getSettings(): MediaTrackSettings;\n stop(): void;\n addEventListener(type: K, listener: (this: MediaStreamTrack, ev: MediaStreamTrackEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MediaStreamTrack: {\n prototype: MediaStreamTrack;\n new(): MediaStreamTrack;\n};\n\ninterface MediaStreamTrackEvent extends Event {\n readonly track: MediaStreamTrack;\n}\n\ndeclare var MediaStreamTrackEvent: {\n prototype: MediaStreamTrackEvent;\n new(typeArg: string, eventInitDict?: MediaStreamTrackEventInit): MediaStreamTrackEvent;\n};\n\ninterface MessageChannel {\n readonly port1: MessagePort;\n readonly port2: MessagePort;\n}\n\ndeclare var MessageChannel: {\n prototype: MessageChannel;\n new(): MessageChannel;\n};\n\ninterface MessageEvent extends Event {\n readonly data: any;\n readonly origin: string;\n readonly ports: any;\n readonly source: Window;\n initMessageEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, dataArg: any, originArg: string, lastEventIdArg: string, sourceArg: Window): void;\n}\n\ndeclare var MessageEvent: {\n prototype: MessageEvent;\n new(type: string, eventInitDict?: MessageEventInit): MessageEvent;\n};\n\ninterface MessagePortEventMap {\n \"message\": MessageEvent;\n}\n\ninterface MessagePort extends EventTarget {\n onmessage: (this: MessagePort, ev: MessageEvent) => any;\n close(): void;\n postMessage(message?: any, transfer?: any[]): void;\n start(): void;\n addEventListener(type: K, listener: (this: MessagePort, ev: MessagePortEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MessagePort: {\n prototype: MessagePort;\n new(): MessagePort;\n};\n\ninterface MimeType {\n readonly description: string;\n readonly enabledPlugin: Plugin;\n readonly suffixes: string;\n readonly type: string;\n}\n\ndeclare var MimeType: {\n prototype: MimeType;\n new(): MimeType;\n};\n\ninterface MimeTypeArray {\n readonly length: number;\n item(index: number): Plugin;\n namedItem(type: string): Plugin;\n [index: number]: Plugin;\n}\n\ndeclare var MimeTypeArray: {\n prototype: MimeTypeArray;\n new(): MimeTypeArray;\n};\n\ninterface MouseEvent extends UIEvent {\n readonly altKey: boolean;\n readonly button: number;\n readonly buttons: number;\n readonly clientX: number;\n readonly clientY: number;\n readonly ctrlKey: boolean;\n readonly fromElement: Element;\n readonly layerX: number;\n readonly layerY: number;\n readonly metaKey: boolean;\n readonly movementX: number;\n readonly movementY: number;\n readonly offsetX: number;\n readonly offsetY: number;\n readonly pageX: number;\n readonly pageY: number;\n readonly relatedTarget: EventTarget;\n readonly screenX: number;\n readonly screenY: number;\n readonly shiftKey: boolean;\n readonly toElement: Element;\n readonly which: number;\n readonly x: number;\n readonly y: number;\n getModifierState(keyArg: string): boolean;\n initMouseEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget | null): void;\n}\n\ndeclare var MouseEvent: {\n prototype: MouseEvent;\n new(typeArg: string, eventInitDict?: MouseEventInit): MouseEvent;\n};\n\ninterface MSApp {\n clearTemporaryWebDataAsync(): MSAppAsyncOperation;\n createBlobFromRandomAccessStream(type: string, seeker: any): Blob;\n createDataPackage(object: any): any;\n createDataPackageFromSelection(): any;\n createFileFromStorageFile(storageFile: any): File;\n createStreamFromInputStream(type: string, inputStream: any): MSStream;\n execAsyncAtPriority(asynchronousCallback: MSExecAtPriorityFunctionCallback, priority: string, ...args: any[]): void;\n execAtPriority(synchronousCallback: MSExecAtPriorityFunctionCallback, priority: string, ...args: any[]): any;\n getCurrentPriority(): string;\n getHtmlPrintDocumentSourceAsync(htmlDoc: any): Promise;\n getViewId(view: any): any;\n isTaskScheduledAtPriorityOrHigher(priority: string): boolean;\n pageHandlesAllApplicationActivations(enabled: boolean): void;\n suppressSubdownloadCredentialPrompts(suppress: boolean): void;\n terminateApp(exceptionObject: any): void;\n readonly CURRENT: string;\n readonly HIGH: string;\n readonly IDLE: string;\n readonly NORMAL: string;\n}\ndeclare var MSApp: MSApp;\n\ninterface MSAppAsyncOperationEventMap {\n \"complete\": Event;\n \"error\": Event;\n}\n\ninterface MSAppAsyncOperation extends EventTarget {\n readonly error: DOMError;\n oncomplete: (this: MSAppAsyncOperation, ev: Event) => any;\n onerror: (this: MSAppAsyncOperation, ev: Event) => any;\n readonly readyState: number;\n readonly result: any;\n start(): void;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n addEventListener(type: K, listener: (this: MSAppAsyncOperation, ev: MSAppAsyncOperationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSAppAsyncOperation: {\n prototype: MSAppAsyncOperation;\n new(): MSAppAsyncOperation;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n};\n\ninterface MSAssertion {\n readonly id: string;\n readonly type: MSCredentialType;\n}\n\ndeclare var MSAssertion: {\n prototype: MSAssertion;\n new(): MSAssertion;\n};\n\ninterface MSBlobBuilder {\n append(data: any, endings?: string): void;\n getBlob(contentType?: string): Blob;\n}\n\ndeclare var MSBlobBuilder: {\n prototype: MSBlobBuilder;\n new(): MSBlobBuilder;\n};\n\ninterface MSCredentials {\n getAssertion(challenge: string, filter?: MSCredentialFilter, params?: MSSignatureParameters): Promise;\n makeCredential(accountInfo: MSAccountInfo, params: MSCredentialParameters[], challenge?: string): Promise;\n}\n\ndeclare var MSCredentials: {\n prototype: MSCredentials;\n new(): MSCredentials;\n};\n\ninterface MSFIDOCredentialAssertion extends MSAssertion {\n readonly algorithm: string | Algorithm;\n readonly attestation: any;\n readonly publicKey: string;\n readonly transportHints: MSTransportType[];\n}\n\ndeclare var MSFIDOCredentialAssertion: {\n prototype: MSFIDOCredentialAssertion;\n new(): MSFIDOCredentialAssertion;\n};\n\ninterface MSFIDOSignature {\n readonly authnrData: string;\n readonly clientData: string;\n readonly signature: string;\n}\n\ndeclare var MSFIDOSignature: {\n prototype: MSFIDOSignature;\n new(): MSFIDOSignature;\n};\n\ninterface MSFIDOSignatureAssertion extends MSAssertion {\n readonly signature: MSFIDOSignature;\n}\n\ndeclare var MSFIDOSignatureAssertion: {\n prototype: MSFIDOSignatureAssertion;\n new(): MSFIDOSignatureAssertion;\n};\n\ninterface MSGesture {\n target: Element;\n addPointer(pointerId: number): void;\n stop(): void;\n}\n\ndeclare var MSGesture: {\n prototype: MSGesture;\n new(): MSGesture;\n};\n\ninterface MSGestureEvent extends UIEvent {\n readonly clientX: number;\n readonly clientY: number;\n readonly expansion: number;\n readonly gestureObject: any;\n readonly hwTimestamp: number;\n readonly offsetX: number;\n readonly offsetY: number;\n readonly rotation: number;\n readonly scale: number;\n readonly screenX: number;\n readonly screenY: number;\n readonly translationX: number;\n readonly translationY: number;\n readonly velocityAngular: number;\n readonly velocityExpansion: number;\n readonly velocityX: number;\n readonly velocityY: number;\n initGestureEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, offsetXArg: number, offsetYArg: number, translationXArg: number, translationYArg: number, scaleArg: number, expansionArg: number, rotationArg: number, velocityXArg: number, velocityYArg: number, velocityExpansionArg: number, velocityAngularArg: number, hwTimestampArg: number): void;\n readonly MSGESTURE_FLAG_BEGIN: number;\n readonly MSGESTURE_FLAG_CANCEL: number;\n readonly MSGESTURE_FLAG_END: number;\n readonly MSGESTURE_FLAG_INERTIA: number;\n readonly MSGESTURE_FLAG_NONE: number;\n}\n\ndeclare var MSGestureEvent: {\n prototype: MSGestureEvent;\n new(): MSGestureEvent;\n readonly MSGESTURE_FLAG_BEGIN: number;\n readonly MSGESTURE_FLAG_CANCEL: number;\n readonly MSGESTURE_FLAG_END: number;\n readonly MSGESTURE_FLAG_INERTIA: number;\n readonly MSGESTURE_FLAG_NONE: number;\n};\n\ninterface MSGraphicsTrust {\n readonly constrictionActive: boolean;\n readonly status: string;\n}\n\ndeclare var MSGraphicsTrust: {\n prototype: MSGraphicsTrust;\n new(): MSGraphicsTrust;\n};\n\ninterface MSHTMLWebViewElement extends HTMLElement {\n readonly canGoBack: boolean;\n readonly canGoForward: boolean;\n readonly containsFullScreenElement: boolean;\n readonly documentTitle: string;\n height: number;\n readonly settings: MSWebViewSettings;\n src: string;\n width: number;\n addWebAllowedObject(name: string, applicationObject: any): void;\n buildLocalStreamUri(contentIdentifier: string, relativePath: string): string;\n capturePreviewToBlobAsync(): MSWebViewAsyncOperation;\n captureSelectedContentToDataPackageAsync(): MSWebViewAsyncOperation;\n getDeferredPermissionRequestById(id: number): DeferredPermissionRequest;\n getDeferredPermissionRequests(): DeferredPermissionRequest[];\n goBack(): void;\n goForward(): void;\n invokeScriptAsync(scriptName: string, ...args: any[]): MSWebViewAsyncOperation;\n navigate(uri: string): void;\n navigateFocus(navigationReason: NavigationReason, origin: FocusNavigationOrigin): void;\n navigateToLocalStreamUri(source: string, streamResolver: any): void;\n navigateToString(contents: string): void;\n navigateWithHttpRequestMessage(requestMessage: any): void;\n refresh(): void;\n stop(): void;\n addEventListener(type: K, listener: (this: MSHTMLWebViewElement, ev: HTMLElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSHTMLWebViewElement: {\n prototype: MSHTMLWebViewElement;\n new(): MSHTMLWebViewElement;\n};\n\ninterface MSInputMethodContextEventMap {\n \"MSCandidateWindowHide\": Event;\n \"MSCandidateWindowShow\": Event;\n \"MSCandidateWindowUpdate\": Event;\n}\n\ninterface MSInputMethodContext extends EventTarget {\n readonly compositionEndOffset: number;\n readonly compositionStartOffset: number;\n oncandidatewindowhide: (this: MSInputMethodContext, ev: Event) => any;\n oncandidatewindowshow: (this: MSInputMethodContext, ev: Event) => any;\n oncandidatewindowupdate: (this: MSInputMethodContext, ev: Event) => any;\n readonly target: HTMLElement;\n getCandidateWindowClientRect(): ClientRect;\n getCompositionAlternatives(): string[];\n hasComposition(): boolean;\n isCandidateWindowVisible(): boolean;\n addEventListener(type: K, listener: (this: MSInputMethodContext, ev: MSInputMethodContextEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSInputMethodContext: {\n prototype: MSInputMethodContext;\n new(): MSInputMethodContext;\n};\n\ninterface MSManipulationEvent extends UIEvent {\n readonly currentState: number;\n readonly inertiaDestinationX: number;\n readonly inertiaDestinationY: number;\n readonly lastState: number;\n initMSManipulationEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, lastState: number, currentState: number): void;\n readonly MS_MANIPULATION_STATE_ACTIVE: number;\n readonly MS_MANIPULATION_STATE_CANCELLED: number;\n readonly MS_MANIPULATION_STATE_COMMITTED: number;\n readonly MS_MANIPULATION_STATE_DRAGGING: number;\n readonly MS_MANIPULATION_STATE_INERTIA: number;\n readonly MS_MANIPULATION_STATE_PRESELECT: number;\n readonly MS_MANIPULATION_STATE_SELECTING: number;\n readonly MS_MANIPULATION_STATE_STOPPED: number;\n}\n\ndeclare var MSManipulationEvent: {\n prototype: MSManipulationEvent;\n new(): MSManipulationEvent;\n readonly MS_MANIPULATION_STATE_ACTIVE: number;\n readonly MS_MANIPULATION_STATE_CANCELLED: number;\n readonly MS_MANIPULATION_STATE_COMMITTED: number;\n readonly MS_MANIPULATION_STATE_DRAGGING: number;\n readonly MS_MANIPULATION_STATE_INERTIA: number;\n readonly MS_MANIPULATION_STATE_PRESELECT: number;\n readonly MS_MANIPULATION_STATE_SELECTING: number;\n readonly MS_MANIPULATION_STATE_STOPPED: number;\n};\n\ninterface MSMediaKeyError {\n readonly code: number;\n readonly systemCode: number;\n readonly MS_MEDIA_KEYERR_CLIENT: number;\n readonly MS_MEDIA_KEYERR_DOMAIN: number;\n readonly MS_MEDIA_KEYERR_HARDWARECHANGE: number;\n readonly MS_MEDIA_KEYERR_OUTPUT: number;\n readonly MS_MEDIA_KEYERR_SERVICE: number;\n readonly MS_MEDIA_KEYERR_UNKNOWN: number;\n}\n\ndeclare var MSMediaKeyError: {\n prototype: MSMediaKeyError;\n new(): MSMediaKeyError;\n readonly MS_MEDIA_KEYERR_CLIENT: number;\n readonly MS_MEDIA_KEYERR_DOMAIN: number;\n readonly MS_MEDIA_KEYERR_HARDWARECHANGE: number;\n readonly MS_MEDIA_KEYERR_OUTPUT: number;\n readonly MS_MEDIA_KEYERR_SERVICE: number;\n readonly MS_MEDIA_KEYERR_UNKNOWN: number;\n};\n\ninterface MSMediaKeyMessageEvent extends Event {\n readonly destinationURL: string | null;\n readonly message: Uint8Array;\n}\n\ndeclare var MSMediaKeyMessageEvent: {\n prototype: MSMediaKeyMessageEvent;\n new(): MSMediaKeyMessageEvent;\n};\n\ninterface MSMediaKeyNeededEvent extends Event {\n readonly initData: Uint8Array | null;\n}\n\ndeclare var MSMediaKeyNeededEvent: {\n prototype: MSMediaKeyNeededEvent;\n new(): MSMediaKeyNeededEvent;\n};\n\ninterface MSMediaKeys {\n readonly keySystem: string;\n createSession(type: string, initData: Uint8Array, cdmData?: Uint8Array): MSMediaKeySession;\n}\n\ndeclare var MSMediaKeys: {\n prototype: MSMediaKeys;\n new(keySystem: string): MSMediaKeys;\n isTypeSupported(keySystem: string, type?: string): boolean;\n isTypeSupportedWithFeatures(keySystem: string, type?: string): string;\n};\n\ninterface MSMediaKeySession extends EventTarget {\n readonly error: MSMediaKeyError | null;\n readonly keySystem: string;\n readonly sessionId: string;\n close(): void;\n update(key: Uint8Array): void;\n}\n\ndeclare var MSMediaKeySession: {\n prototype: MSMediaKeySession;\n new(): MSMediaKeySession;\n};\n\ninterface MSPointerEvent extends MouseEvent {\n readonly currentPoint: any;\n readonly height: number;\n readonly hwTimestamp: number;\n readonly intermediatePoints: any;\n readonly isPrimary: boolean;\n readonly pointerId: number;\n readonly pointerType: any;\n readonly pressure: number;\n readonly rotation: number;\n readonly tiltX: number;\n readonly tiltY: number;\n readonly width: number;\n getCurrentPoint(element: Element): void;\n getIntermediatePoints(element: Element): void;\n initPointerEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget, offsetXArg: number, offsetYArg: number, widthArg: number, heightArg: number, pressure: number, rotation: number, tiltX: number, tiltY: number, pointerIdArg: number, pointerType: any, hwTimestampArg: number, isPrimary: boolean): void;\n}\n\ndeclare var MSPointerEvent: {\n prototype: MSPointerEvent;\n new(typeArg: string, eventInitDict?: PointerEventInit): MSPointerEvent;\n};\n\ninterface MSRangeCollection {\n readonly length: number;\n item(index: number): Range;\n [index: number]: Range;\n}\n\ndeclare var MSRangeCollection: {\n prototype: MSRangeCollection;\n new(): MSRangeCollection;\n};\n\ninterface MSSiteModeEvent extends Event {\n readonly actionURL: string;\n readonly buttonID: number;\n}\n\ndeclare var MSSiteModeEvent: {\n prototype: MSSiteModeEvent;\n new(): MSSiteModeEvent;\n};\n\ninterface MSStream {\n readonly type: string;\n msClose(): void;\n msDetachStream(): any;\n}\n\ndeclare var MSStream: {\n prototype: MSStream;\n new(): MSStream;\n};\n\ninterface MSStreamReader extends EventTarget, MSBaseReader {\n readonly error: DOMError;\n readAsArrayBuffer(stream: MSStream, size?: number): void;\n readAsBinaryString(stream: MSStream, size?: number): void;\n readAsBlob(stream: MSStream, size?: number): void;\n readAsDataURL(stream: MSStream, size?: number): void;\n readAsText(stream: MSStream, encoding?: string, size?: number): void;\n addEventListener(type: K, listener: (this: MSStreamReader, ev: MSBaseReaderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSStreamReader: {\n prototype: MSStreamReader;\n new(): MSStreamReader;\n};\n\ninterface MSWebViewAsyncOperationEventMap {\n \"complete\": Event;\n \"error\": Event;\n}\n\ninterface MSWebViewAsyncOperation extends EventTarget {\n readonly error: DOMError;\n oncomplete: (this: MSWebViewAsyncOperation, ev: Event) => any;\n onerror: (this: MSWebViewAsyncOperation, ev: Event) => any;\n readonly readyState: number;\n readonly result: any;\n readonly target: MSHTMLWebViewElement;\n readonly type: number;\n start(): void;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n readonly TYPE_CAPTURE_PREVIEW_TO_RANDOM_ACCESS_STREAM: number;\n readonly TYPE_CREATE_DATA_PACKAGE_FROM_SELECTION: number;\n readonly TYPE_INVOKE_SCRIPT: number;\n addEventListener(type: K, listener: (this: MSWebViewAsyncOperation, ev: MSWebViewAsyncOperationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var MSWebViewAsyncOperation: {\n prototype: MSWebViewAsyncOperation;\n new(): MSWebViewAsyncOperation;\n readonly COMPLETED: number;\n readonly ERROR: number;\n readonly STARTED: number;\n readonly TYPE_CAPTURE_PREVIEW_TO_RANDOM_ACCESS_STREAM: number;\n readonly TYPE_CREATE_DATA_PACKAGE_FROM_SELECTION: number;\n readonly TYPE_INVOKE_SCRIPT: number;\n};\n\ninterface MSWebViewSettings {\n isIndexedDBEnabled: boolean;\n isJavaScriptEnabled: boolean;\n}\n\ndeclare var MSWebViewSettings: {\n prototype: MSWebViewSettings;\n new(): MSWebViewSettings;\n};\n\ninterface MutationEvent extends Event {\n readonly attrChange: number;\n readonly attrName: string;\n readonly newValue: string;\n readonly prevValue: string;\n readonly relatedNode: Node;\n initMutationEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, relatedNodeArg: Node, prevValueArg: string, newValueArg: string, attrNameArg: string, attrChangeArg: number): void;\n readonly ADDITION: number;\n readonly MODIFICATION: number;\n readonly REMOVAL: number;\n}\n\ndeclare var MutationEvent: {\n prototype: MutationEvent;\n new(): MutationEvent;\n readonly ADDITION: number;\n readonly MODIFICATION: number;\n readonly REMOVAL: number;\n};\n\ninterface MutationObserver {\n disconnect(): void;\n observe(target: Node, options: MutationObserverInit): void;\n takeRecords(): MutationRecord[];\n}\n\ndeclare var MutationObserver: {\n prototype: MutationObserver;\n new(callback: MutationCallback): MutationObserver;\n};\n\ninterface MutationRecord {\n readonly addedNodes: NodeList;\n readonly attributeName: string | null;\n readonly attributeNamespace: string | null;\n readonly nextSibling: Node | null;\n readonly oldValue: string | null;\n readonly previousSibling: Node | null;\n readonly removedNodes: NodeList;\n readonly target: Node;\n readonly type: string;\n}\n\ndeclare var MutationRecord: {\n prototype: MutationRecord;\n new(): MutationRecord;\n};\n\ninterface NamedNodeMap {\n readonly length: number;\n getNamedItem(name: string): Attr;\n getNamedItemNS(namespaceURI: string | null, localName: string | null): Attr;\n item(index: number): Attr;\n removeNamedItem(name: string): Attr;\n removeNamedItemNS(namespaceURI: string | null, localName: string | null): Attr;\n setNamedItem(arg: Attr): Attr;\n setNamedItemNS(arg: Attr): Attr;\n [index: number]: Attr;\n}\n\ndeclare var NamedNodeMap: {\n prototype: NamedNodeMap;\n new(): NamedNodeMap;\n};\n\ninterface NavigationCompletedEvent extends NavigationEvent {\n readonly isSuccess: boolean;\n readonly webErrorStatus: number;\n}\n\ndeclare var NavigationCompletedEvent: {\n prototype: NavigationCompletedEvent;\n new(): NavigationCompletedEvent;\n};\n\ninterface NavigationEvent extends Event {\n readonly uri: string;\n}\n\ndeclare var NavigationEvent: {\n prototype: NavigationEvent;\n new(): NavigationEvent;\n};\n\ninterface NavigationEventWithReferrer extends NavigationEvent {\n readonly referer: string;\n}\n\ndeclare var NavigationEventWithReferrer: {\n prototype: NavigationEventWithReferrer;\n new(): NavigationEventWithReferrer;\n};\n\ninterface Navigator extends Object, NavigatorID, NavigatorOnLine, NavigatorContentUtils, NavigatorStorageUtils, NavigatorGeolocation, MSNavigatorDoNotTrack, MSFileSaver, NavigatorBeacon, NavigatorConcurrentHardware, NavigatorUserMedia {\n readonly authentication: WebAuthentication;\n readonly cookieEnabled: boolean;\n gamepadInputEmulation: GamepadInputEmulationType;\n readonly language: string;\n readonly maxTouchPoints: number;\n readonly mimeTypes: MimeTypeArray;\n readonly msManipulationViewsEnabled: boolean;\n readonly msMaxTouchPoints: number;\n readonly msPointerEnabled: boolean;\n readonly plugins: PluginArray;\n readonly pointerEnabled: boolean;\n readonly serviceWorker: ServiceWorkerContainer;\n readonly webdriver: boolean;\n readonly hardwareConcurrency: number;\n readonly languages: string[];\n getGamepads(): Gamepad[];\n javaEnabled(): boolean;\n msLaunchUri(uri: string, successCallback?: MSLaunchUriCallback, noHandlerCallback?: MSLaunchUriCallback): void;\n requestMediaKeySystemAccess(keySystem: string, supportedConfigurations: MediaKeySystemConfiguration[]): Promise;\n vibrate(pattern: number | number[]): boolean;\n}\n\ndeclare var Navigator: {\n prototype: Navigator;\n new(): Navigator;\n};\n\ninterface Node extends EventTarget {\n readonly attributes: NamedNodeMap;\n readonly baseURI: string | null;\n readonly childNodes: NodeList;\n readonly firstChild: Node | null;\n readonly lastChild: Node | null;\n readonly localName: string | null;\n readonly namespaceURI: string | null;\n readonly nextSibling: Node | null;\n readonly nodeName: string;\n readonly nodeType: number;\n nodeValue: string | null;\n readonly ownerDocument: Document;\n readonly parentElement: HTMLElement | null;\n readonly parentNode: Node | null;\n readonly previousSibling: Node | null;\n textContent: string | null;\n appendChild(newChild: T): T;\n cloneNode(deep?: boolean): Node;\n compareDocumentPosition(other: Node): number;\n contains(child: Node): boolean;\n hasAttributes(): boolean;\n hasChildNodes(): boolean;\n insertBefore(newChild: T, refChild: Node | null): T;\n isDefaultNamespace(namespaceURI: string | null): boolean;\n isEqualNode(arg: Node): boolean;\n isSameNode(other: Node): boolean;\n lookupNamespaceURI(prefix: string | null): string | null;\n lookupPrefix(namespaceURI: string | null): string | null;\n normalize(): void;\n removeChild(oldChild: T): T;\n replaceChild(newChild: Node, oldChild: T): T;\n readonly ATTRIBUTE_NODE: number;\n readonly CDATA_SECTION_NODE: number;\n readonly COMMENT_NODE: number;\n readonly DOCUMENT_FRAGMENT_NODE: number;\n readonly DOCUMENT_NODE: number;\n readonly DOCUMENT_POSITION_CONTAINED_BY: number;\n readonly DOCUMENT_POSITION_CONTAINS: number;\n readonly DOCUMENT_POSITION_DISCONNECTED: number;\n readonly DOCUMENT_POSITION_FOLLOWING: number;\n readonly DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: number;\n readonly DOCUMENT_POSITION_PRECEDING: number;\n readonly DOCUMENT_TYPE_NODE: number;\n readonly ELEMENT_NODE: number;\n readonly ENTITY_NODE: number;\n readonly ENTITY_REFERENCE_NODE: number;\n readonly NOTATION_NODE: number;\n readonly PROCESSING_INSTRUCTION_NODE: number;\n readonly TEXT_NODE: number;\n}\n\ndeclare var Node: {\n prototype: Node;\n new(): Node;\n readonly ATTRIBUTE_NODE: number;\n readonly CDATA_SECTION_NODE: number;\n readonly COMMENT_NODE: number;\n readonly DOCUMENT_FRAGMENT_NODE: number;\n readonly DOCUMENT_NODE: number;\n readonly DOCUMENT_POSITION_CONTAINED_BY: number;\n readonly DOCUMENT_POSITION_CONTAINS: number;\n readonly DOCUMENT_POSITION_DISCONNECTED: number;\n readonly DOCUMENT_POSITION_FOLLOWING: number;\n readonly DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: number;\n readonly DOCUMENT_POSITION_PRECEDING: number;\n readonly DOCUMENT_TYPE_NODE: number;\n readonly ELEMENT_NODE: number;\n readonly ENTITY_NODE: number;\n readonly ENTITY_REFERENCE_NODE: number;\n readonly NOTATION_NODE: number;\n readonly PROCESSING_INSTRUCTION_NODE: number;\n readonly TEXT_NODE: number;\n};\n\ninterface NodeFilter {\n acceptNode(n: Node): number;\n}\n\ndeclare var NodeFilter: {\n readonly FILTER_ACCEPT: number;\n readonly FILTER_REJECT: number;\n readonly FILTER_SKIP: number;\n readonly SHOW_ALL: number;\n readonly SHOW_ATTRIBUTE: number;\n readonly SHOW_CDATA_SECTION: number;\n readonly SHOW_COMMENT: number;\n readonly SHOW_DOCUMENT: number;\n readonly SHOW_DOCUMENT_FRAGMENT: number;\n readonly SHOW_DOCUMENT_TYPE: number;\n readonly SHOW_ELEMENT: number;\n readonly SHOW_ENTITY: number;\n readonly SHOW_ENTITY_REFERENCE: number;\n readonly SHOW_NOTATION: number;\n readonly SHOW_PROCESSING_INSTRUCTION: number;\n readonly SHOW_TEXT: number;\n};\n\ninterface NodeIterator {\n readonly expandEntityReferences: boolean;\n readonly filter: NodeFilter;\n readonly root: Node;\n readonly whatToShow: number;\n detach(): void;\n nextNode(): Node;\n previousNode(): Node;\n}\n\ndeclare var NodeIterator: {\n prototype: NodeIterator;\n new(): NodeIterator;\n};\n\ninterface NodeList {\n readonly length: number;\n item(index: number): Node;\n [index: number]: Node;\n}\n\ndeclare var NodeList: {\n prototype: NodeList;\n new(): NodeList;\n};\n\ninterface NotificationEventMap {\n \"click\": Event;\n \"close\": Event;\n \"error\": Event;\n \"show\": Event;\n}\n\ninterface Notification extends EventTarget {\n readonly body: string;\n readonly dir: NotificationDirection;\n readonly icon: string;\n readonly lang: string;\n onclick: (this: Notification, ev: Event) => any;\n onclose: (this: Notification, ev: Event) => any;\n onerror: (this: Notification, ev: Event) => any;\n onshow: (this: Notification, ev: Event) => any;\n readonly permission: NotificationPermission;\n readonly tag: string;\n readonly title: string;\n close(): void;\n addEventListener(type: K, listener: (this: Notification, ev: NotificationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Notification: {\n prototype: Notification;\n new(title: string, options?: NotificationOptions): Notification;\n requestPermission(callback?: NotificationPermissionCallback): Promise;\n};\n\ninterface OES_element_index_uint {\n}\n\ndeclare var OES_element_index_uint: {\n prototype: OES_element_index_uint;\n new(): OES_element_index_uint;\n};\n\ninterface OES_standard_derivatives {\n readonly FRAGMENT_SHADER_DERIVATIVE_HINT_OES: number;\n}\n\ndeclare var OES_standard_derivatives: {\n prototype: OES_standard_derivatives;\n new(): OES_standard_derivatives;\n readonly FRAGMENT_SHADER_DERIVATIVE_HINT_OES: number;\n};\n\ninterface OES_texture_float {\n}\n\ndeclare var OES_texture_float: {\n prototype: OES_texture_float;\n new(): OES_texture_float;\n};\n\ninterface OES_texture_float_linear {\n}\n\ndeclare var OES_texture_float_linear: {\n prototype: OES_texture_float_linear;\n new(): OES_texture_float_linear;\n};\n\ninterface OES_texture_half_float {\n readonly HALF_FLOAT_OES: number;\n}\n\ndeclare var OES_texture_half_float: {\n prototype: OES_texture_half_float;\n new(): OES_texture_half_float;\n readonly HALF_FLOAT_OES: number;\n};\n\ninterface OES_texture_half_float_linear {\n}\n\ndeclare var OES_texture_half_float_linear: {\n prototype: OES_texture_half_float_linear;\n new(): OES_texture_half_float_linear;\n};\n\ninterface OfflineAudioCompletionEvent extends Event {\n readonly renderedBuffer: AudioBuffer;\n}\n\ndeclare var OfflineAudioCompletionEvent: {\n prototype: OfflineAudioCompletionEvent;\n new(): OfflineAudioCompletionEvent;\n};\n\ninterface OfflineAudioContextEventMap extends AudioContextEventMap {\n \"complete\": OfflineAudioCompletionEvent;\n}\n\ninterface OfflineAudioContext extends AudioContextBase {\n readonly length: number;\n oncomplete: (this: OfflineAudioContext, ev: OfflineAudioCompletionEvent) => any;\n startRendering(): Promise;\n suspend(suspendTime: number): Promise;\n addEventListener(type: K, listener: (this: OfflineAudioContext, ev: OfflineAudioContextEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var OfflineAudioContext: {\n prototype: OfflineAudioContext;\n new(numberOfChannels: number, length: number, sampleRate: number): OfflineAudioContext;\n};\n\ninterface OscillatorNodeEventMap {\n \"ended\": MediaStreamErrorEvent;\n}\n\ninterface OscillatorNode extends AudioNode {\n readonly detune: AudioParam;\n readonly frequency: AudioParam;\n onended: (this: OscillatorNode, ev: MediaStreamErrorEvent) => any;\n type: OscillatorType;\n setPeriodicWave(periodicWave: PeriodicWave): void;\n start(when?: number): void;\n stop(when?: number): void;\n addEventListener(type: K, listener: (this: OscillatorNode, ev: OscillatorNodeEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var OscillatorNode: {\n prototype: OscillatorNode;\n new(): OscillatorNode;\n};\n\ninterface OverflowEvent extends UIEvent {\n readonly horizontalOverflow: boolean;\n readonly orient: number;\n readonly verticalOverflow: boolean;\n readonly BOTH: number;\n readonly HORIZONTAL: number;\n readonly VERTICAL: number;\n}\n\ndeclare var OverflowEvent: {\n prototype: OverflowEvent;\n new(): OverflowEvent;\n readonly BOTH: number;\n readonly HORIZONTAL: number;\n readonly VERTICAL: number;\n};\n\ninterface PageTransitionEvent extends Event {\n readonly persisted: boolean;\n}\n\ndeclare var PageTransitionEvent: {\n prototype: PageTransitionEvent;\n new(): PageTransitionEvent;\n};\n\ninterface PannerNode extends AudioNode {\n coneInnerAngle: number;\n coneOuterAngle: number;\n coneOuterGain: number;\n distanceModel: DistanceModelType;\n maxDistance: number;\n panningModel: PanningModelType;\n refDistance: number;\n rolloffFactor: number;\n setOrientation(x: number, y: number, z: number): void;\n setPosition(x: number, y: number, z: number): void;\n setVelocity(x: number, y: number, z: number): void;\n}\n\ndeclare var PannerNode: {\n prototype: PannerNode;\n new(): PannerNode;\n};\n\ninterface Path2D extends Object, CanvasPathMethods {\n}\n\ndeclare var Path2D: {\n prototype: Path2D;\n new(path?: Path2D): Path2D;\n};\n\ninterface PaymentAddress {\n readonly addressLine: string[];\n readonly city: string;\n readonly country: string;\n readonly dependentLocality: string;\n readonly languageCode: string;\n readonly organization: string;\n readonly phone: string;\n readonly postalCode: string;\n readonly recipient: string;\n readonly region: string;\n readonly sortingCode: string;\n toJSON(): any;\n}\n\ndeclare var PaymentAddress: {\n prototype: PaymentAddress;\n new(): PaymentAddress;\n};\n\ninterface PaymentRequestEventMap {\n \"shippingaddresschange\": Event;\n \"shippingoptionchange\": Event;\n}\n\ninterface PaymentRequest extends EventTarget {\n onshippingaddresschange: (this: PaymentRequest, ev: Event) => any;\n onshippingoptionchange: (this: PaymentRequest, ev: Event) => any;\n readonly shippingAddress: PaymentAddress | null;\n readonly shippingOption: string | null;\n readonly shippingType: PaymentShippingType | null;\n abort(): Promise;\n show(): Promise;\n addEventListener(type: K, listener: (this: PaymentRequest, ev: PaymentRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var PaymentRequest: {\n prototype: PaymentRequest;\n new(methodData: PaymentMethodData[], details: PaymentDetails, options?: PaymentOptions): PaymentRequest;\n};\n\ninterface PaymentRequestUpdateEvent extends Event {\n updateWith(d: Promise): void;\n}\n\ndeclare var PaymentRequestUpdateEvent: {\n prototype: PaymentRequestUpdateEvent;\n new(type: string, eventInitDict?: PaymentRequestUpdateEventInit): PaymentRequestUpdateEvent;\n};\n\ninterface PaymentResponse {\n readonly details: any;\n readonly methodName: string;\n readonly payerEmail: string | null;\n readonly payerName: string | null;\n readonly payerPhone: string | null;\n readonly shippingAddress: PaymentAddress | null;\n readonly shippingOption: string | null;\n complete(result?: PaymentComplete): Promise;\n toJSON(): any;\n}\n\ndeclare var PaymentResponse: {\n prototype: PaymentResponse;\n new(): PaymentResponse;\n};\n\ninterface Performance {\n readonly navigation: PerformanceNavigation;\n readonly timing: PerformanceTiming;\n clearMarks(markName?: string): void;\n clearMeasures(measureName?: string): void;\n clearResourceTimings(): void;\n getEntries(): any;\n getEntriesByName(name: string, entryType?: string): any;\n getEntriesByType(entryType: string): any;\n getMarks(markName?: string): any;\n getMeasures(measureName?: string): any;\n mark(markName: string): void;\n measure(measureName: string, startMarkName?: string, endMarkName?: string): void;\n now(): number;\n setResourceTimingBufferSize(maxSize: number): void;\n toJSON(): any;\n}\n\ndeclare var Performance: {\n prototype: Performance;\n new(): Performance;\n};\n\ninterface PerformanceEntry {\n readonly duration: number;\n readonly entryType: string;\n readonly name: string;\n readonly startTime: number;\n}\n\ndeclare var PerformanceEntry: {\n prototype: PerformanceEntry;\n new(): PerformanceEntry;\n};\n\ninterface PerformanceMark extends PerformanceEntry {\n}\n\ndeclare var PerformanceMark: {\n prototype: PerformanceMark;\n new(): PerformanceMark;\n};\n\ninterface PerformanceMeasure extends PerformanceEntry {\n}\n\ndeclare var PerformanceMeasure: {\n prototype: PerformanceMeasure;\n new(): PerformanceMeasure;\n};\n\ninterface PerformanceNavigation {\n readonly redirectCount: number;\n readonly type: number;\n toJSON(): any;\n readonly TYPE_BACK_FORWARD: number;\n readonly TYPE_NAVIGATE: number;\n readonly TYPE_RELOAD: number;\n readonly TYPE_RESERVED: number;\n}\n\ndeclare var PerformanceNavigation: {\n prototype: PerformanceNavigation;\n new(): PerformanceNavigation;\n readonly TYPE_BACK_FORWARD: number;\n readonly TYPE_NAVIGATE: number;\n readonly TYPE_RELOAD: number;\n readonly TYPE_RESERVED: number;\n};\n\ninterface PerformanceNavigationTiming extends PerformanceEntry {\n readonly connectEnd: number;\n readonly connectStart: number;\n readonly domainLookupEnd: number;\n readonly domainLookupStart: number;\n readonly domComplete: number;\n readonly domContentLoadedEventEnd: number;\n readonly domContentLoadedEventStart: number;\n readonly domInteractive: number;\n readonly domLoading: number;\n readonly fetchStart: number;\n readonly loadEventEnd: number;\n readonly loadEventStart: number;\n readonly navigationStart: number;\n readonly redirectCount: number;\n readonly redirectEnd: number;\n readonly redirectStart: number;\n readonly requestStart: number;\n readonly responseEnd: number;\n readonly responseStart: number;\n readonly type: NavigationType;\n readonly unloadEventEnd: number;\n readonly unloadEventStart: number;\n}\n\ndeclare var PerformanceNavigationTiming: {\n prototype: PerformanceNavigationTiming;\n new(): PerformanceNavigationTiming;\n};\n\ninterface PerformanceResourceTiming extends PerformanceEntry {\n readonly connectEnd: number;\n readonly connectStart: number;\n readonly domainLookupEnd: number;\n readonly domainLookupStart: number;\n readonly fetchStart: number;\n readonly initiatorType: string;\n readonly redirectEnd: number;\n readonly redirectStart: number;\n readonly requestStart: number;\n readonly responseEnd: number;\n readonly responseStart: number;\n}\n\ndeclare var PerformanceResourceTiming: {\n prototype: PerformanceResourceTiming;\n new(): PerformanceResourceTiming;\n};\n\ninterface PerformanceTiming {\n readonly connectEnd: number;\n readonly connectStart: number;\n readonly domainLookupEnd: number;\n readonly domainLookupStart: number;\n readonly domComplete: number;\n readonly domContentLoadedEventEnd: number;\n readonly domContentLoadedEventStart: number;\n readonly domInteractive: number;\n readonly domLoading: number;\n readonly fetchStart: number;\n readonly loadEventEnd: number;\n readonly loadEventStart: number;\n readonly msFirstPaint: number;\n readonly navigationStart: number;\n readonly redirectEnd: number;\n readonly redirectStart: number;\n readonly requestStart: number;\n readonly responseEnd: number;\n readonly responseStart: number;\n readonly unloadEventEnd: number;\n readonly unloadEventStart: number;\n readonly secureConnectionStart: number;\n toJSON(): any;\n}\n\ndeclare var PerformanceTiming: {\n prototype: PerformanceTiming;\n new(): PerformanceTiming;\n};\n\ninterface PerfWidgetExternal {\n readonly activeNetworkRequestCount: number;\n readonly averageFrameTime: number;\n readonly averagePaintTime: number;\n readonly extraInformationEnabled: boolean;\n readonly independentRenderingEnabled: boolean;\n readonly irDisablingContentString: string;\n readonly irStatusAvailable: boolean;\n readonly maxCpuSpeed: number;\n readonly paintRequestsPerSecond: number;\n readonly performanceCounter: number;\n readonly performanceCounterFrequency: number;\n addEventListener(eventType: string, callback: Function): void;\n getMemoryUsage(): number;\n getProcessCpuUsage(): number;\n getRecentCpuUsage(last: number | null): any;\n getRecentFrames(last: number | null): any;\n getRecentMemoryUsage(last: number | null): any;\n getRecentPaintRequests(last: number | null): any;\n removeEventListener(eventType: string, callback: Function): void;\n repositionWindow(x: number, y: number): void;\n resizeWindow(width: number, height: number): void;\n}\n\ndeclare var PerfWidgetExternal: {\n prototype: PerfWidgetExternal;\n new(): PerfWidgetExternal;\n};\n\ninterface PeriodicWave {\n}\n\ndeclare var PeriodicWave: {\n prototype: PeriodicWave;\n new(): PeriodicWave;\n};\n\ninterface PermissionRequest extends DeferredPermissionRequest {\n readonly state: MSWebViewPermissionState;\n defer(): void;\n}\n\ndeclare var PermissionRequest: {\n prototype: PermissionRequest;\n new(): PermissionRequest;\n};\n\ninterface PermissionRequestedEvent extends Event {\n readonly permissionRequest: PermissionRequest;\n}\n\ndeclare var PermissionRequestedEvent: {\n prototype: PermissionRequestedEvent;\n new(): PermissionRequestedEvent;\n};\n\ninterface Plugin {\n readonly description: string;\n readonly filename: string;\n readonly length: number;\n readonly name: string;\n readonly version: string;\n item(index: number): MimeType;\n namedItem(type: string): MimeType;\n [index: number]: MimeType;\n}\n\ndeclare var Plugin: {\n prototype: Plugin;\n new(): Plugin;\n};\n\ninterface PluginArray {\n readonly length: number;\n item(index: number): Plugin;\n namedItem(name: string): Plugin;\n refresh(reload?: boolean): void;\n [index: number]: Plugin;\n}\n\ndeclare var PluginArray: {\n prototype: PluginArray;\n new(): PluginArray;\n};\n\ninterface PointerEvent extends MouseEvent {\n readonly currentPoint: any;\n readonly height: number;\n readonly hwTimestamp: number;\n readonly intermediatePoints: any;\n readonly isPrimary: boolean;\n readonly pointerId: number;\n readonly pointerType: any;\n readonly pressure: number;\n readonly rotation: number;\n readonly tiltX: number;\n readonly tiltY: number;\n readonly width: number;\n getCurrentPoint(element: Element): void;\n getIntermediatePoints(element: Element): void;\n initPointerEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, ctrlKeyArg: boolean, altKeyArg: boolean, shiftKeyArg: boolean, metaKeyArg: boolean, buttonArg: number, relatedTargetArg: EventTarget, offsetXArg: number, offsetYArg: number, widthArg: number, heightArg: number, pressure: number, rotation: number, tiltX: number, tiltY: number, pointerIdArg: number, pointerType: any, hwTimestampArg: number, isPrimary: boolean): void;\n}\n\ndeclare var PointerEvent: {\n prototype: PointerEvent;\n new(typeArg: string, eventInitDict?: PointerEventInit): PointerEvent;\n};\n\ninterface PopStateEvent extends Event {\n readonly state: any;\n initPopStateEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, stateArg: any): void;\n}\n\ndeclare var PopStateEvent: {\n prototype: PopStateEvent;\n new(typeArg: string, eventInitDict?: PopStateEventInit): PopStateEvent;\n};\n\ninterface Position {\n readonly coords: Coordinates;\n readonly timestamp: number;\n}\n\ndeclare var Position: {\n prototype: Position;\n new(): Position;\n};\n\ninterface PositionError {\n readonly code: number;\n readonly message: string;\n toString(): string;\n readonly PERMISSION_DENIED: number;\n readonly POSITION_UNAVAILABLE: number;\n readonly TIMEOUT: number;\n}\n\ndeclare var PositionError: {\n prototype: PositionError;\n new(): PositionError;\n readonly PERMISSION_DENIED: number;\n readonly POSITION_UNAVAILABLE: number;\n readonly TIMEOUT: number;\n};\n\ninterface ProcessingInstruction extends CharacterData {\n readonly target: string;\n}\n\ndeclare var ProcessingInstruction: {\n prototype: ProcessingInstruction;\n new(): ProcessingInstruction;\n};\n\ninterface ProgressEvent extends Event {\n readonly lengthComputable: boolean;\n readonly loaded: number;\n readonly total: number;\n initProgressEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, lengthComputableArg: boolean, loadedArg: number, totalArg: number): void;\n}\n\ndeclare var ProgressEvent: {\n prototype: ProgressEvent;\n new(type: string, eventInitDict?: ProgressEventInit): ProgressEvent;\n};\n\ninterface PushManager {\n getSubscription(): Promise;\n permissionState(options?: PushSubscriptionOptionsInit): Promise;\n subscribe(options?: PushSubscriptionOptionsInit): Promise;\n}\n\ndeclare var PushManager: {\n prototype: PushManager;\n new(): PushManager;\n};\n\ninterface PushSubscription {\n readonly endpoint: USVString;\n readonly options: PushSubscriptionOptions;\n getKey(name: PushEncryptionKeyName): ArrayBuffer | null;\n toJSON(): any;\n unsubscribe(): Promise;\n}\n\ndeclare var PushSubscription: {\n prototype: PushSubscription;\n new(): PushSubscription;\n};\n\ninterface PushSubscriptionOptions {\n readonly applicationServerKey: ArrayBuffer | null;\n readonly userVisibleOnly: boolean;\n}\n\ndeclare var PushSubscriptionOptions: {\n prototype: PushSubscriptionOptions;\n new(): PushSubscriptionOptions;\n};\n\ninterface Range {\n readonly collapsed: boolean;\n readonly commonAncestorContainer: Node;\n readonly endContainer: Node;\n readonly endOffset: number;\n readonly startContainer: Node;\n readonly startOffset: number;\n cloneContents(): DocumentFragment;\n cloneRange(): Range;\n collapse(toStart: boolean): void;\n compareBoundaryPoints(how: number, sourceRange: Range): number;\n createContextualFragment(fragment: string): DocumentFragment;\n deleteContents(): void;\n detach(): void;\n expand(Unit: ExpandGranularity): boolean;\n extractContents(): DocumentFragment;\n getBoundingClientRect(): ClientRect;\n getClientRects(): ClientRectList;\n insertNode(newNode: Node): void;\n selectNode(refNode: Node): void;\n selectNodeContents(refNode: Node): void;\n setEnd(refNode: Node, offset: number): void;\n setEndAfter(refNode: Node): void;\n setEndBefore(refNode: Node): void;\n setStart(refNode: Node, offset: number): void;\n setStartAfter(refNode: Node): void;\n setStartBefore(refNode: Node): void;\n surroundContents(newParent: Node): void;\n toString(): string;\n readonly END_TO_END: number;\n readonly END_TO_START: number;\n readonly START_TO_END: number;\n readonly START_TO_START: number;\n}\n\ndeclare var Range: {\n prototype: Range;\n new(): Range;\n readonly END_TO_END: number;\n readonly END_TO_START: number;\n readonly START_TO_END: number;\n readonly START_TO_START: number;\n};\n\ninterface ReadableStream {\n readonly locked: boolean;\n cancel(): Promise;\n getReader(): ReadableStreamReader;\n}\n\ndeclare var ReadableStream: {\n prototype: ReadableStream;\n new(): ReadableStream;\n};\n\ninterface ReadableStreamReader {\n cancel(): Promise;\n read(): Promise;\n releaseLock(): void;\n}\n\ndeclare var ReadableStreamReader: {\n prototype: ReadableStreamReader;\n new(): ReadableStreamReader;\n};\n\ninterface Request extends Object, Body {\n readonly cache: RequestCache;\n readonly credentials: RequestCredentials;\n readonly destination: RequestDestination;\n readonly headers: Headers;\n readonly integrity: string;\n readonly keepalive: boolean;\n readonly method: string;\n readonly mode: RequestMode;\n readonly redirect: RequestRedirect;\n readonly referrer: string;\n readonly referrerPolicy: ReferrerPolicy;\n readonly type: RequestType;\n readonly url: string;\n clone(): Request;\n}\n\ndeclare var Request: {\n prototype: Request;\n new(input: Request | string, init?: RequestInit): Request;\n};\n\ninterface Response extends Object, Body {\n readonly body: ReadableStream | null;\n readonly headers: Headers;\n readonly ok: boolean;\n readonly status: number;\n readonly statusText: string;\n readonly type: ResponseType;\n readonly url: string;\n clone(): Response;\n}\n\ndeclare var Response: {\n prototype: Response;\n new(body?: any, init?: ResponseInit): Response;\n error: () => Response;\n redirect: (url: string, status?: number) => Response;\n};\n\ninterface RTCDtlsTransportEventMap {\n \"dtlsstatechange\": RTCDtlsTransportStateChangedEvent;\n \"error\": Event;\n}\n\ninterface RTCDtlsTransport extends RTCStatsProvider {\n ondtlsstatechange: ((this: RTCDtlsTransport, ev: RTCDtlsTransportStateChangedEvent) => any) | null;\n onerror: ((this: RTCDtlsTransport, ev: Event) => any) | null;\n readonly state: RTCDtlsTransportState;\n readonly transport: RTCIceTransport;\n getLocalParameters(): RTCDtlsParameters;\n getRemoteCertificates(): ArrayBuffer[];\n getRemoteParameters(): RTCDtlsParameters | null;\n start(remoteParameters: RTCDtlsParameters): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCDtlsTransport, ev: RTCDtlsTransportEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCDtlsTransport: {\n prototype: RTCDtlsTransport;\n new(transport: RTCIceTransport): RTCDtlsTransport;\n};\n\ninterface RTCDtlsTransportStateChangedEvent extends Event {\n readonly state: RTCDtlsTransportState;\n}\n\ndeclare var RTCDtlsTransportStateChangedEvent: {\n prototype: RTCDtlsTransportStateChangedEvent;\n new(): RTCDtlsTransportStateChangedEvent;\n};\n\ninterface RTCDtmfSenderEventMap {\n \"tonechange\": RTCDTMFToneChangeEvent;\n}\n\ninterface RTCDtmfSender extends EventTarget {\n readonly canInsertDTMF: boolean;\n readonly duration: number;\n readonly interToneGap: number;\n ontonechange: (this: RTCDtmfSender, ev: RTCDTMFToneChangeEvent) => any;\n readonly sender: RTCRtpSender;\n readonly toneBuffer: string;\n insertDTMF(tones: string, duration?: number, interToneGap?: number): void;\n addEventListener(type: K, listener: (this: RTCDtmfSender, ev: RTCDtmfSenderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCDtmfSender: {\n prototype: RTCDtmfSender;\n new(sender: RTCRtpSender): RTCDtmfSender;\n};\n\ninterface RTCDTMFToneChangeEvent extends Event {\n readonly tone: string;\n}\n\ndeclare var RTCDTMFToneChangeEvent: {\n prototype: RTCDTMFToneChangeEvent;\n new(typeArg: string, eventInitDict: RTCDTMFToneChangeEventInit): RTCDTMFToneChangeEvent;\n};\n\ninterface RTCIceCandidate {\n candidate: string | null;\n sdpMid: string | null;\n sdpMLineIndex: number | null;\n toJSON(): any;\n}\n\ndeclare var RTCIceCandidate: {\n prototype: RTCIceCandidate;\n new(candidateInitDict?: RTCIceCandidateInit): RTCIceCandidate;\n};\n\ninterface RTCIceCandidatePairChangedEvent extends Event {\n readonly pair: RTCIceCandidatePair;\n}\n\ndeclare var RTCIceCandidatePairChangedEvent: {\n prototype: RTCIceCandidatePairChangedEvent;\n new(): RTCIceCandidatePairChangedEvent;\n};\n\ninterface RTCIceGathererEventMap {\n \"error\": Event;\n \"localcandidate\": RTCIceGathererEvent;\n}\n\ninterface RTCIceGatherer extends RTCStatsProvider {\n readonly component: RTCIceComponent;\n onerror: ((this: RTCIceGatherer, ev: Event) => any) | null;\n onlocalcandidate: ((this: RTCIceGatherer, ev: RTCIceGathererEvent) => any) | null;\n createAssociatedGatherer(): RTCIceGatherer;\n getLocalCandidates(): RTCIceCandidateDictionary[];\n getLocalParameters(): RTCIceParameters;\n addEventListener(type: K, listener: (this: RTCIceGatherer, ev: RTCIceGathererEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCIceGatherer: {\n prototype: RTCIceGatherer;\n new(options: RTCIceGatherOptions): RTCIceGatherer;\n};\n\ninterface RTCIceGathererEvent extends Event {\n readonly candidate: RTCIceCandidateDictionary | RTCIceCandidateComplete;\n}\n\ndeclare var RTCIceGathererEvent: {\n prototype: RTCIceGathererEvent;\n new(): RTCIceGathererEvent;\n};\n\ninterface RTCIceTransportEventMap {\n \"candidatepairchange\": RTCIceCandidatePairChangedEvent;\n \"icestatechange\": RTCIceTransportStateChangedEvent;\n}\n\ninterface RTCIceTransport extends RTCStatsProvider {\n readonly component: RTCIceComponent;\n readonly iceGatherer: RTCIceGatherer | null;\n oncandidatepairchange: ((this: RTCIceTransport, ev: RTCIceCandidatePairChangedEvent) => any) | null;\n onicestatechange: ((this: RTCIceTransport, ev: RTCIceTransportStateChangedEvent) => any) | null;\n readonly role: RTCIceRole;\n readonly state: RTCIceTransportState;\n addRemoteCandidate(remoteCandidate: RTCIceCandidateDictionary | RTCIceCandidateComplete): void;\n createAssociatedTransport(): RTCIceTransport;\n getNominatedCandidatePair(): RTCIceCandidatePair | null;\n getRemoteCandidates(): RTCIceCandidateDictionary[];\n getRemoteParameters(): RTCIceParameters | null;\n setRemoteCandidates(remoteCandidates: RTCIceCandidateDictionary[]): void;\n start(gatherer: RTCIceGatherer, remoteParameters: RTCIceParameters, role?: RTCIceRole): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCIceTransport, ev: RTCIceTransportEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCIceTransport: {\n prototype: RTCIceTransport;\n new(): RTCIceTransport;\n};\n\ninterface RTCIceTransportStateChangedEvent extends Event {\n readonly state: RTCIceTransportState;\n}\n\ndeclare var RTCIceTransportStateChangedEvent: {\n prototype: RTCIceTransportStateChangedEvent;\n new(): RTCIceTransportStateChangedEvent;\n};\n\ninterface RTCPeerConnectionEventMap {\n \"addstream\": MediaStreamEvent;\n \"icecandidate\": RTCPeerConnectionIceEvent;\n \"iceconnectionstatechange\": Event;\n \"icegatheringstatechange\": Event;\n \"negotiationneeded\": Event;\n \"removestream\": MediaStreamEvent;\n \"signalingstatechange\": Event;\n}\n\ninterface RTCPeerConnection extends EventTarget {\n readonly canTrickleIceCandidates: boolean | null;\n readonly iceConnectionState: RTCIceConnectionState;\n readonly iceGatheringState: RTCIceGatheringState;\n readonly localDescription: RTCSessionDescription | null;\n onaddstream: (this: RTCPeerConnection, ev: MediaStreamEvent) => any;\n onicecandidate: (this: RTCPeerConnection, ev: RTCPeerConnectionIceEvent) => any;\n oniceconnectionstatechange: (this: RTCPeerConnection, ev: Event) => any;\n onicegatheringstatechange: (this: RTCPeerConnection, ev: Event) => any;\n onnegotiationneeded: (this: RTCPeerConnection, ev: Event) => any;\n onremovestream: (this: RTCPeerConnection, ev: MediaStreamEvent) => any;\n onsignalingstatechange: (this: RTCPeerConnection, ev: Event) => any;\n readonly remoteDescription: RTCSessionDescription | null;\n readonly signalingState: RTCSignalingState;\n addIceCandidate(candidate: RTCIceCandidate, successCallback?: VoidFunction, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n addStream(stream: MediaStream): void;\n close(): void;\n createAnswer(successCallback?: RTCSessionDescriptionCallback, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n createOffer(successCallback?: RTCSessionDescriptionCallback, failureCallback?: RTCPeerConnectionErrorCallback, options?: RTCOfferOptions): Promise;\n getConfiguration(): RTCConfiguration;\n getLocalStreams(): MediaStream[];\n getRemoteStreams(): MediaStream[];\n getStats(selector: MediaStreamTrack | null, successCallback?: RTCStatsCallback, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n getStreamById(streamId: string): MediaStream | null;\n removeStream(stream: MediaStream): void;\n setLocalDescription(description: RTCSessionDescription, successCallback?: VoidFunction, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n setRemoteDescription(description: RTCSessionDescription, successCallback?: VoidFunction, failureCallback?: RTCPeerConnectionErrorCallback): Promise;\n addEventListener(type: K, listener: (this: RTCPeerConnection, ev: RTCPeerConnectionEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCPeerConnection: {\n prototype: RTCPeerConnection;\n new(configuration: RTCConfiguration): RTCPeerConnection;\n};\n\ninterface RTCPeerConnectionIceEvent extends Event {\n readonly candidate: RTCIceCandidate;\n}\n\ndeclare var RTCPeerConnectionIceEvent: {\n prototype: RTCPeerConnectionIceEvent;\n new(type: string, eventInitDict: RTCPeerConnectionIceEventInit): RTCPeerConnectionIceEvent;\n};\n\ninterface RTCRtpReceiverEventMap {\n \"error\": Event;\n}\n\ninterface RTCRtpReceiver extends RTCStatsProvider {\n onerror: ((this: RTCRtpReceiver, ev: Event) => any) | null;\n readonly rtcpTransport: RTCDtlsTransport;\n readonly track: MediaStreamTrack | null;\n readonly transport: RTCDtlsTransport | RTCSrtpSdesTransport;\n getContributingSources(): RTCRtpContributingSource[];\n receive(parameters: RTCRtpParameters): void;\n requestSendCSRC(csrc: number): void;\n setTransport(transport: RTCDtlsTransport | RTCSrtpSdesTransport, rtcpTransport?: RTCDtlsTransport): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCRtpReceiver, ev: RTCRtpReceiverEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCRtpReceiver: {\n prototype: RTCRtpReceiver;\n new(transport: RTCDtlsTransport | RTCSrtpSdesTransport, kind: string, rtcpTransport?: RTCDtlsTransport): RTCRtpReceiver;\n getCapabilities(kind?: string): RTCRtpCapabilities;\n};\n\ninterface RTCRtpSenderEventMap {\n \"error\": Event;\n \"ssrcconflict\": RTCSsrcConflictEvent;\n}\n\ninterface RTCRtpSender extends RTCStatsProvider {\n onerror: ((this: RTCRtpSender, ev: Event) => any) | null;\n onssrcconflict: ((this: RTCRtpSender, ev: RTCSsrcConflictEvent) => any) | null;\n readonly rtcpTransport: RTCDtlsTransport;\n readonly track: MediaStreamTrack;\n readonly transport: RTCDtlsTransport | RTCSrtpSdesTransport;\n send(parameters: RTCRtpParameters): void;\n setTrack(track: MediaStreamTrack): void;\n setTransport(transport: RTCDtlsTransport | RTCSrtpSdesTransport, rtcpTransport?: RTCDtlsTransport): void;\n stop(): void;\n addEventListener(type: K, listener: (this: RTCRtpSender, ev: RTCRtpSenderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCRtpSender: {\n prototype: RTCRtpSender;\n new(track: MediaStreamTrack, transport: RTCDtlsTransport | RTCSrtpSdesTransport, rtcpTransport?: RTCDtlsTransport): RTCRtpSender;\n getCapabilities(kind?: string): RTCRtpCapabilities;\n};\n\ninterface RTCSessionDescription {\n sdp: string | null;\n type: RTCSdpType | null;\n toJSON(): any;\n}\n\ndeclare var RTCSessionDescription: {\n prototype: RTCSessionDescription;\n new(descriptionInitDict?: RTCSessionDescriptionInit): RTCSessionDescription;\n};\n\ninterface RTCSrtpSdesTransportEventMap {\n \"error\": Event;\n}\n\ninterface RTCSrtpSdesTransport extends EventTarget {\n onerror: ((this: RTCSrtpSdesTransport, ev: Event) => any) | null;\n readonly transport: RTCIceTransport;\n addEventListener(type: K, listener: (this: RTCSrtpSdesTransport, ev: RTCSrtpSdesTransportEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var RTCSrtpSdesTransport: {\n prototype: RTCSrtpSdesTransport;\n new(transport: RTCIceTransport, encryptParameters: RTCSrtpSdesParameters, decryptParameters: RTCSrtpSdesParameters): RTCSrtpSdesTransport;\n getLocalParameters(): RTCSrtpSdesParameters[];\n};\n\ninterface RTCSsrcConflictEvent extends Event {\n readonly ssrc: number;\n}\n\ndeclare var RTCSsrcConflictEvent: {\n prototype: RTCSsrcConflictEvent;\n new(): RTCSsrcConflictEvent;\n};\n\ninterface RTCStatsProvider extends EventTarget {\n getStats(): Promise;\n msGetStats(): Promise;\n}\n\ndeclare var RTCStatsProvider: {\n prototype: RTCStatsProvider;\n new(): RTCStatsProvider;\n};\n\ninterface ScopedCredential {\n readonly id: ArrayBuffer;\n readonly type: ScopedCredentialType;\n}\n\ndeclare var ScopedCredential: {\n prototype: ScopedCredential;\n new(): ScopedCredential;\n};\n\ninterface ScopedCredentialInfo {\n readonly credential: ScopedCredential;\n readonly publicKey: CryptoKey;\n}\n\ndeclare var ScopedCredentialInfo: {\n prototype: ScopedCredentialInfo;\n new(): ScopedCredentialInfo;\n};\n\ninterface ScreenEventMap {\n \"MSOrientationChange\": Event;\n}\n\ninterface Screen extends EventTarget {\n readonly availHeight: number;\n readonly availWidth: number;\n bufferDepth: number;\n readonly colorDepth: number;\n readonly deviceXDPI: number;\n readonly deviceYDPI: number;\n readonly fontSmoothingEnabled: boolean;\n readonly height: number;\n readonly logicalXDPI: number;\n readonly logicalYDPI: number;\n readonly msOrientation: string;\n onmsorientationchange: (this: Screen, ev: Event) => any;\n readonly pixelDepth: number;\n readonly systemXDPI: number;\n readonly systemYDPI: number;\n readonly width: number;\n msLockOrientation(orientations: string | string[]): boolean;\n msUnlockOrientation(): void;\n addEventListener(type: K, listener: (this: Screen, ev: ScreenEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Screen: {\n prototype: Screen;\n new(): Screen;\n};\n\ninterface ScriptNotifyEvent extends Event {\n readonly callingUri: string;\n readonly value: string;\n}\n\ndeclare var ScriptNotifyEvent: {\n prototype: ScriptNotifyEvent;\n new(): ScriptNotifyEvent;\n};\n\ninterface ScriptProcessorNodeEventMap {\n \"audioprocess\": AudioProcessingEvent;\n}\n\ninterface ScriptProcessorNode extends AudioNode {\n readonly bufferSize: number;\n onaudioprocess: (this: ScriptProcessorNode, ev: AudioProcessingEvent) => any;\n addEventListener(type: K, listener: (this: ScriptProcessorNode, ev: ScriptProcessorNodeEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ScriptProcessorNode: {\n prototype: ScriptProcessorNode;\n new(): ScriptProcessorNode;\n};\n\ninterface Selection {\n readonly anchorNode: Node;\n readonly anchorOffset: number;\n readonly baseNode: Node;\n readonly baseOffset: number;\n readonly extentNode: Node;\n readonly extentOffset: number;\n readonly focusNode: Node;\n readonly focusOffset: number;\n readonly isCollapsed: boolean;\n readonly rangeCount: number;\n readonly type: string;\n addRange(range: Range): void;\n collapse(parentNode: Node, offset: number): void;\n collapseToEnd(): void;\n collapseToStart(): void;\n containsNode(node: Node, partlyContained: boolean): boolean;\n deleteFromDocument(): void;\n empty(): void;\n extend(newNode: Node, offset: number): void;\n getRangeAt(index: number): Range;\n removeAllRanges(): void;\n removeRange(range: Range): void;\n selectAllChildren(parentNode: Node): void;\n setBaseAndExtent(baseNode: Node, baseOffset: number, extentNode: Node, extentOffset: number): void;\n setPosition(parentNode: Node, offset: number): void;\n toString(): string;\n}\n\ndeclare var Selection: {\n prototype: Selection;\n new(): Selection;\n};\n\ninterface ServiceWorkerEventMap extends AbstractWorkerEventMap {\n \"statechange\": Event;\n}\n\ninterface ServiceWorker extends EventTarget, AbstractWorker {\n onstatechange: (this: ServiceWorker, ev: Event) => any;\n readonly scriptURL: USVString;\n readonly state: ServiceWorkerState;\n postMessage(message: any, transfer?: any[]): void;\n addEventListener(type: K, listener: (this: ServiceWorker, ev: ServiceWorkerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ServiceWorker: {\n prototype: ServiceWorker;\n new(): ServiceWorker;\n};\n\ninterface ServiceWorkerContainerEventMap {\n \"controllerchange\": Event;\n \"message\": ServiceWorkerMessageEvent;\n}\n\ninterface ServiceWorkerContainer extends EventTarget {\n readonly controller: ServiceWorker | null;\n oncontrollerchange: (this: ServiceWorkerContainer, ev: Event) => any;\n onmessage: (this: ServiceWorkerContainer, ev: ServiceWorkerMessageEvent) => any;\n readonly ready: Promise;\n getRegistration(clientURL?: USVString): Promise;\n getRegistrations(): any;\n register(scriptURL: USVString, options?: RegistrationOptions): Promise;\n addEventListener(type: K, listener: (this: ServiceWorkerContainer, ev: ServiceWorkerContainerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ServiceWorkerContainer: {\n prototype: ServiceWorkerContainer;\n new(): ServiceWorkerContainer;\n};\n\ninterface ServiceWorkerMessageEvent extends Event {\n readonly data: any;\n readonly lastEventId: string;\n readonly origin: string;\n readonly ports: MessagePort[] | null;\n readonly source: ServiceWorker | MessagePort | null;\n}\n\ndeclare var ServiceWorkerMessageEvent: {\n prototype: ServiceWorkerMessageEvent;\n new(type: string, eventInitDict?: ServiceWorkerMessageEventInit): ServiceWorkerMessageEvent;\n};\n\ninterface ServiceWorkerRegistrationEventMap {\n \"updatefound\": Event;\n}\n\ninterface ServiceWorkerRegistration extends EventTarget {\n readonly active: ServiceWorker | null;\n readonly installing: ServiceWorker | null;\n onupdatefound: (this: ServiceWorkerRegistration, ev: Event) => any;\n readonly pushManager: PushManager;\n readonly scope: USVString;\n readonly sync: SyncManager;\n readonly waiting: ServiceWorker | null;\n getNotifications(filter?: GetNotificationOptions): any;\n showNotification(title: string, options?: NotificationOptions): Promise;\n unregister(): Promise;\n update(): Promise;\n addEventListener(type: K, listener: (this: ServiceWorkerRegistration, ev: ServiceWorkerRegistrationEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var ServiceWorkerRegistration: {\n prototype: ServiceWorkerRegistration;\n new(): ServiceWorkerRegistration;\n};\n\ninterface SourceBuffer extends EventTarget {\n appendWindowEnd: number;\n appendWindowStart: number;\n readonly audioTracks: AudioTrackList;\n readonly buffered: TimeRanges;\n mode: AppendMode;\n timestampOffset: number;\n readonly updating: boolean;\n readonly videoTracks: VideoTrackList;\n abort(): void;\n appendBuffer(data: ArrayBuffer | ArrayBufferView): void;\n appendStream(stream: MSStream, maxSize?: number): void;\n remove(start: number, end: number): void;\n}\n\ndeclare var SourceBuffer: {\n prototype: SourceBuffer;\n new(): SourceBuffer;\n};\n\ninterface SourceBufferList extends EventTarget {\n readonly length: number;\n item(index: number): SourceBuffer;\n [index: number]: SourceBuffer;\n}\n\ndeclare var SourceBufferList: {\n prototype: SourceBufferList;\n new(): SourceBufferList;\n};\n\ninterface SpeechSynthesisEventMap {\n \"voiceschanged\": Event;\n}\n\ninterface SpeechSynthesis extends EventTarget {\n onvoiceschanged: (this: SpeechSynthesis, ev: Event) => any;\n readonly paused: boolean;\n readonly pending: boolean;\n readonly speaking: boolean;\n cancel(): void;\n getVoices(): SpeechSynthesisVoice[];\n pause(): void;\n resume(): void;\n speak(utterance: SpeechSynthesisUtterance): void;\n addEventListener(type: K, listener: (this: SpeechSynthesis, ev: SpeechSynthesisEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SpeechSynthesis: {\n prototype: SpeechSynthesis;\n new(): SpeechSynthesis;\n};\n\ninterface SpeechSynthesisEvent extends Event {\n readonly charIndex: number;\n readonly elapsedTime: number;\n readonly name: string;\n readonly utterance: SpeechSynthesisUtterance | null;\n}\n\ndeclare var SpeechSynthesisEvent: {\n prototype: SpeechSynthesisEvent;\n new(type: string, eventInitDict?: SpeechSynthesisEventInit): SpeechSynthesisEvent;\n};\n\ninterface SpeechSynthesisUtteranceEventMap {\n \"boundary\": Event;\n \"end\": Event;\n \"error\": Event;\n \"mark\": Event;\n \"pause\": Event;\n \"resume\": Event;\n \"start\": Event;\n}\n\ninterface SpeechSynthesisUtterance extends EventTarget {\n lang: string;\n onboundary: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onend: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onerror: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onmark: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onpause: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onresume: (this: SpeechSynthesisUtterance, ev: Event) => any;\n onstart: (this: SpeechSynthesisUtterance, ev: Event) => any;\n pitch: number;\n rate: number;\n text: string;\n voice: SpeechSynthesisVoice;\n volume: number;\n addEventListener(type: K, listener: (this: SpeechSynthesisUtterance, ev: SpeechSynthesisUtteranceEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SpeechSynthesisUtterance: {\n prototype: SpeechSynthesisUtterance;\n new(text?: string): SpeechSynthesisUtterance;\n};\n\ninterface SpeechSynthesisVoice {\n readonly default: boolean;\n readonly lang: string;\n readonly localService: boolean;\n readonly name: string;\n readonly voiceURI: string;\n}\n\ndeclare var SpeechSynthesisVoice: {\n prototype: SpeechSynthesisVoice;\n new(): SpeechSynthesisVoice;\n};\n\ninterface StereoPannerNode extends AudioNode {\n readonly pan: AudioParam;\n}\n\ndeclare var StereoPannerNode: {\n prototype: StereoPannerNode;\n new(): StereoPannerNode;\n};\n\ninterface Storage {\n readonly length: number;\n clear(): void;\n getItem(key: string): string | null;\n key(index: number): string | null;\n removeItem(key: string): void;\n setItem(key: string, data: string): void;\n [key: string]: any;\n [index: number]: string;\n}\n\ndeclare var Storage: {\n prototype: Storage;\n new(): Storage;\n};\n\ninterface StorageEvent extends Event {\n readonly url: string;\n key?: string;\n oldValue?: string;\n newValue?: string;\n storageArea?: Storage;\n}\n\ndeclare var StorageEvent: {\n prototype: StorageEvent;\n new (type: string, eventInitDict?: StorageEventInit): StorageEvent;\n};\n\ninterface StyleMedia {\n readonly type: string;\n matchMedium(mediaquery: string): boolean;\n}\n\ndeclare var StyleMedia: {\n prototype: StyleMedia;\n new(): StyleMedia;\n};\n\ninterface StyleSheet {\n disabled: boolean;\n readonly href: string;\n readonly media: MediaList;\n readonly ownerNode: Node;\n readonly parentStyleSheet: StyleSheet;\n readonly title: string;\n readonly type: string;\n}\n\ndeclare var StyleSheet: {\n prototype: StyleSheet;\n new(): StyleSheet;\n};\n\ninterface StyleSheetList {\n readonly length: number;\n item(index?: number): StyleSheet;\n [index: number]: StyleSheet;\n}\n\ndeclare var StyleSheetList: {\n prototype: StyleSheetList;\n new(): StyleSheetList;\n};\n\ninterface StyleSheetPageList {\n readonly length: number;\n item(index: number): CSSPageRule;\n [index: number]: CSSPageRule;\n}\n\ndeclare var StyleSheetPageList: {\n prototype: StyleSheetPageList;\n new(): StyleSheetPageList;\n};\n\ninterface SubtleCrypto {\n decrypt(algorithm: string | RsaOaepParams | AesCtrParams | AesCbcParams | AesCmacParams | AesGcmParams | AesCfbParams, key: CryptoKey, data: BufferSource): PromiseLike;\n deriveBits(algorithm: string | EcdhKeyDeriveParams | DhKeyDeriveParams | ConcatParams | HkdfCtrParams | Pbkdf2Params, baseKey: CryptoKey, length: number): PromiseLike;\n deriveKey(algorithm: string | EcdhKeyDeriveParams | DhKeyDeriveParams | ConcatParams | HkdfCtrParams | Pbkdf2Params, baseKey: CryptoKey, derivedKeyType: string | AesDerivedKeyParams | HmacImportParams | ConcatParams | HkdfCtrParams | Pbkdf2Params, extractable: boolean, keyUsages: string[]): PromiseLike;\n digest(algorithm: AlgorithmIdentifier, data: BufferSource): PromiseLike;\n encrypt(algorithm: string | RsaOaepParams | AesCtrParams | AesCbcParams | AesCmacParams | AesGcmParams | AesCfbParams, key: CryptoKey, data: BufferSource): PromiseLike;\n exportKey(format: \"jwk\", key: CryptoKey): PromiseLike;\n exportKey(format: \"raw\" | \"pkcs8\" | \"spki\", key: CryptoKey): PromiseLike;\n exportKey(format: string, key: CryptoKey): PromiseLike;\n generateKey(algorithm: string, extractable: boolean, keyUsages: string[]): PromiseLike;\n generateKey(algorithm: RsaHashedKeyGenParams | EcKeyGenParams | DhKeyGenParams, extractable: boolean, keyUsages: string[]): PromiseLike;\n generateKey(algorithm: AesKeyGenParams | HmacKeyGenParams | Pbkdf2Params, extractable: boolean, keyUsages: string[]): PromiseLike;\n importKey(format: \"jwk\", keyData: JsonWebKey, algorithm: string | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | DhImportKeyParams, extractable: boolean, keyUsages: string[]): PromiseLike;\n importKey(format: \"raw\" | \"pkcs8\" | \"spki\", keyData: BufferSource, algorithm: string | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | DhImportKeyParams, extractable: boolean, keyUsages: string[]): PromiseLike;\n importKey(format: string, keyData: JsonWebKey | BufferSource, algorithm: string | RsaHashedImportParams | EcKeyImportParams | HmacImportParams | DhImportKeyParams, extractable: boolean, keyUsages: string[]): PromiseLike;\n sign(algorithm: string | RsaPssParams | EcdsaParams | AesCmacParams, key: CryptoKey, data: BufferSource): PromiseLike;\n unwrapKey(format: string, wrappedKey: BufferSource, unwrappingKey: CryptoKey, unwrapAlgorithm: AlgorithmIdentifier, unwrappedKeyAlgorithm: AlgorithmIdentifier, extractable: boolean, keyUsages: string[]): PromiseLike;\n verify(algorithm: string | RsaPssParams | EcdsaParams | AesCmacParams, key: CryptoKey, signature: BufferSource, data: BufferSource): PromiseLike;\n wrapKey(format: string, key: CryptoKey, wrappingKey: CryptoKey, wrapAlgorithm: AlgorithmIdentifier): PromiseLike;\n}\n\ndeclare var SubtleCrypto: {\n prototype: SubtleCrypto;\n new(): SubtleCrypto;\n};\n\ninterface SVGAElement extends SVGGraphicsElement, SVGURIReference {\n readonly target: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGAElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGAElement: {\n prototype: SVGAElement;\n new(): SVGAElement;\n};\n\ninterface SVGAngle {\n readonly unitType: number;\n value: number;\n valueAsString: string;\n valueInSpecifiedUnits: number;\n convertToSpecifiedUnits(unitType: number): void;\n newValueSpecifiedUnits(unitType: number, valueInSpecifiedUnits: number): void;\n readonly SVG_ANGLETYPE_DEG: number;\n readonly SVG_ANGLETYPE_GRAD: number;\n readonly SVG_ANGLETYPE_RAD: number;\n readonly SVG_ANGLETYPE_UNKNOWN: number;\n readonly SVG_ANGLETYPE_UNSPECIFIED: number;\n}\n\ndeclare var SVGAngle: {\n prototype: SVGAngle;\n new(): SVGAngle;\n readonly SVG_ANGLETYPE_DEG: number;\n readonly SVG_ANGLETYPE_GRAD: number;\n readonly SVG_ANGLETYPE_RAD: number;\n readonly SVG_ANGLETYPE_UNKNOWN: number;\n readonly SVG_ANGLETYPE_UNSPECIFIED: number;\n};\n\ninterface SVGAnimatedAngle {\n readonly animVal: SVGAngle;\n readonly baseVal: SVGAngle;\n}\n\ndeclare var SVGAnimatedAngle: {\n prototype: SVGAnimatedAngle;\n new(): SVGAnimatedAngle;\n};\n\ninterface SVGAnimatedBoolean {\n readonly animVal: boolean;\n baseVal: boolean;\n}\n\ndeclare var SVGAnimatedBoolean: {\n prototype: SVGAnimatedBoolean;\n new(): SVGAnimatedBoolean;\n};\n\ninterface SVGAnimatedEnumeration {\n readonly animVal: number;\n baseVal: number;\n}\n\ndeclare var SVGAnimatedEnumeration: {\n prototype: SVGAnimatedEnumeration;\n new(): SVGAnimatedEnumeration;\n};\n\ninterface SVGAnimatedInteger {\n readonly animVal: number;\n baseVal: number;\n}\n\ndeclare var SVGAnimatedInteger: {\n prototype: SVGAnimatedInteger;\n new(): SVGAnimatedInteger;\n};\n\ninterface SVGAnimatedLength {\n readonly animVal: SVGLength;\n readonly baseVal: SVGLength;\n}\n\ndeclare var SVGAnimatedLength: {\n prototype: SVGAnimatedLength;\n new(): SVGAnimatedLength;\n};\n\ninterface SVGAnimatedLengthList {\n readonly animVal: SVGLengthList;\n readonly baseVal: SVGLengthList;\n}\n\ndeclare var SVGAnimatedLengthList: {\n prototype: SVGAnimatedLengthList;\n new(): SVGAnimatedLengthList;\n};\n\ninterface SVGAnimatedNumber {\n readonly animVal: number;\n baseVal: number;\n}\n\ndeclare var SVGAnimatedNumber: {\n prototype: SVGAnimatedNumber;\n new(): SVGAnimatedNumber;\n};\n\ninterface SVGAnimatedNumberList {\n readonly animVal: SVGNumberList;\n readonly baseVal: SVGNumberList;\n}\n\ndeclare var SVGAnimatedNumberList: {\n prototype: SVGAnimatedNumberList;\n new(): SVGAnimatedNumberList;\n};\n\ninterface SVGAnimatedPreserveAspectRatio {\n readonly animVal: SVGPreserveAspectRatio;\n readonly baseVal: SVGPreserveAspectRatio;\n}\n\ndeclare var SVGAnimatedPreserveAspectRatio: {\n prototype: SVGAnimatedPreserveAspectRatio;\n new(): SVGAnimatedPreserveAspectRatio;\n};\n\ninterface SVGAnimatedRect {\n readonly animVal: SVGRect;\n readonly baseVal: SVGRect;\n}\n\ndeclare var SVGAnimatedRect: {\n prototype: SVGAnimatedRect;\n new(): SVGAnimatedRect;\n};\n\ninterface SVGAnimatedString {\n readonly animVal: string;\n baseVal: string;\n}\n\ndeclare var SVGAnimatedString: {\n prototype: SVGAnimatedString;\n new(): SVGAnimatedString;\n};\n\ninterface SVGAnimatedTransformList {\n readonly animVal: SVGTransformList;\n readonly baseVal: SVGTransformList;\n}\n\ndeclare var SVGAnimatedTransformList: {\n prototype: SVGAnimatedTransformList;\n new(): SVGAnimatedTransformList;\n};\n\ninterface SVGCircleElement extends SVGGraphicsElement {\n readonly cx: SVGAnimatedLength;\n readonly cy: SVGAnimatedLength;\n readonly r: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGCircleElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGCircleElement: {\n prototype: SVGCircleElement;\n new(): SVGCircleElement;\n};\n\ninterface SVGClipPathElement extends SVGGraphicsElement, SVGUnitTypes {\n readonly clipPathUnits: SVGAnimatedEnumeration;\n addEventListener(type: K, listener: (this: SVGClipPathElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGClipPathElement: {\n prototype: SVGClipPathElement;\n new(): SVGClipPathElement;\n};\n\ninterface SVGComponentTransferFunctionElement extends SVGElement {\n readonly amplitude: SVGAnimatedNumber;\n readonly exponent: SVGAnimatedNumber;\n readonly intercept: SVGAnimatedNumber;\n readonly offset: SVGAnimatedNumber;\n readonly slope: SVGAnimatedNumber;\n readonly tableValues: SVGAnimatedNumberList;\n readonly type: SVGAnimatedEnumeration;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_DISCRETE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_GAMMA: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_IDENTITY: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_LINEAR: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_TABLE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGComponentTransferFunctionElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGComponentTransferFunctionElement: {\n prototype: SVGComponentTransferFunctionElement;\n new(): SVGComponentTransferFunctionElement;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_DISCRETE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_GAMMA: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_IDENTITY: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_LINEAR: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_TABLE: number;\n readonly SVG_FECOMPONENTTRANSFER_TYPE_UNKNOWN: number;\n};\n\ninterface SVGDefsElement extends SVGGraphicsElement {\n addEventListener(type: K, listener: (this: SVGDefsElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGDefsElement: {\n prototype: SVGDefsElement;\n new(): SVGDefsElement;\n};\n\ninterface SVGDescElement extends SVGElement {\n addEventListener(type: K, listener: (this: SVGDescElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGDescElement: {\n prototype: SVGDescElement;\n new(): SVGDescElement;\n};\n\ninterface SVGElementEventMap extends ElementEventMap {\n \"click\": MouseEvent;\n \"dblclick\": MouseEvent;\n \"focusin\": FocusEvent;\n \"focusout\": FocusEvent;\n \"load\": Event;\n \"mousedown\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n}\n\ninterface SVGElement extends Element {\n className: any;\n onclick: (this: SVGElement, ev: MouseEvent) => any;\n ondblclick: (this: SVGElement, ev: MouseEvent) => any;\n onfocusin: (this: SVGElement, ev: FocusEvent) => any;\n onfocusout: (this: SVGElement, ev: FocusEvent) => any;\n onload: (this: SVGElement, ev: Event) => any;\n onmousedown: (this: SVGElement, ev: MouseEvent) => any;\n onmousemove: (this: SVGElement, ev: MouseEvent) => any;\n onmouseout: (this: SVGElement, ev: MouseEvent) => any;\n onmouseover: (this: SVGElement, ev: MouseEvent) => any;\n onmouseup: (this: SVGElement, ev: MouseEvent) => any;\n readonly ownerSVGElement: SVGSVGElement;\n readonly style: CSSStyleDeclaration;\n readonly viewportElement: SVGElement;\n xmlbase: string;\n addEventListener(type: K, listener: (this: SVGElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGElement: {\n prototype: SVGElement;\n new(): SVGElement;\n};\n\ninterface SVGElementInstance extends EventTarget {\n readonly childNodes: SVGElementInstanceList;\n readonly correspondingElement: SVGElement;\n readonly correspondingUseElement: SVGUseElement;\n readonly firstChild: SVGElementInstance;\n readonly lastChild: SVGElementInstance;\n readonly nextSibling: SVGElementInstance;\n readonly parentNode: SVGElementInstance;\n readonly previousSibling: SVGElementInstance;\n}\n\ndeclare var SVGElementInstance: {\n prototype: SVGElementInstance;\n new(): SVGElementInstance;\n};\n\ninterface SVGElementInstanceList {\n readonly length: number;\n item(index: number): SVGElementInstance;\n}\n\ndeclare var SVGElementInstanceList: {\n prototype: SVGElementInstanceList;\n new(): SVGElementInstanceList;\n};\n\ninterface SVGEllipseElement extends SVGGraphicsElement {\n readonly cx: SVGAnimatedLength;\n readonly cy: SVGAnimatedLength;\n readonly rx: SVGAnimatedLength;\n readonly ry: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGEllipseElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGEllipseElement: {\n prototype: SVGEllipseElement;\n new(): SVGEllipseElement;\n};\n\ninterface SVGFEBlendElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly in2: SVGAnimatedString;\n readonly mode: SVGAnimatedEnumeration;\n readonly SVG_FEBLEND_MODE_COLOR: number;\n readonly SVG_FEBLEND_MODE_COLOR_BURN: number;\n readonly SVG_FEBLEND_MODE_COLOR_DODGE: number;\n readonly SVG_FEBLEND_MODE_DARKEN: number;\n readonly SVG_FEBLEND_MODE_DIFFERENCE: number;\n readonly SVG_FEBLEND_MODE_EXCLUSION: number;\n readonly SVG_FEBLEND_MODE_HARD_LIGHT: number;\n readonly SVG_FEBLEND_MODE_HUE: number;\n readonly SVG_FEBLEND_MODE_LIGHTEN: number;\n readonly SVG_FEBLEND_MODE_LUMINOSITY: number;\n readonly SVG_FEBLEND_MODE_MULTIPLY: number;\n readonly SVG_FEBLEND_MODE_NORMAL: number;\n readonly SVG_FEBLEND_MODE_OVERLAY: number;\n readonly SVG_FEBLEND_MODE_SATURATION: number;\n readonly SVG_FEBLEND_MODE_SCREEN: number;\n readonly SVG_FEBLEND_MODE_SOFT_LIGHT: number;\n readonly SVG_FEBLEND_MODE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEBlendElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEBlendElement: {\n prototype: SVGFEBlendElement;\n new(): SVGFEBlendElement;\n readonly SVG_FEBLEND_MODE_COLOR: number;\n readonly SVG_FEBLEND_MODE_COLOR_BURN: number;\n readonly SVG_FEBLEND_MODE_COLOR_DODGE: number;\n readonly SVG_FEBLEND_MODE_DARKEN: number;\n readonly SVG_FEBLEND_MODE_DIFFERENCE: number;\n readonly SVG_FEBLEND_MODE_EXCLUSION: number;\n readonly SVG_FEBLEND_MODE_HARD_LIGHT: number;\n readonly SVG_FEBLEND_MODE_HUE: number;\n readonly SVG_FEBLEND_MODE_LIGHTEN: number;\n readonly SVG_FEBLEND_MODE_LUMINOSITY: number;\n readonly SVG_FEBLEND_MODE_MULTIPLY: number;\n readonly SVG_FEBLEND_MODE_NORMAL: number;\n readonly SVG_FEBLEND_MODE_OVERLAY: number;\n readonly SVG_FEBLEND_MODE_SATURATION: number;\n readonly SVG_FEBLEND_MODE_SCREEN: number;\n readonly SVG_FEBLEND_MODE_SOFT_LIGHT: number;\n readonly SVG_FEBLEND_MODE_UNKNOWN: number;\n};\n\ninterface SVGFEColorMatrixElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly type: SVGAnimatedEnumeration;\n readonly values: SVGAnimatedNumberList;\n readonly SVG_FECOLORMATRIX_TYPE_HUEROTATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_LUMINANCETOALPHA: number;\n readonly SVG_FECOLORMATRIX_TYPE_MATRIX: number;\n readonly SVG_FECOLORMATRIX_TYPE_SATURATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEColorMatrixElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEColorMatrixElement: {\n prototype: SVGFEColorMatrixElement;\n new(): SVGFEColorMatrixElement;\n readonly SVG_FECOLORMATRIX_TYPE_HUEROTATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_LUMINANCETOALPHA: number;\n readonly SVG_FECOLORMATRIX_TYPE_MATRIX: number;\n readonly SVG_FECOLORMATRIX_TYPE_SATURATE: number;\n readonly SVG_FECOLORMATRIX_TYPE_UNKNOWN: number;\n};\n\ninterface SVGFEComponentTransferElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFEComponentTransferElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEComponentTransferElement: {\n prototype: SVGFEComponentTransferElement;\n new(): SVGFEComponentTransferElement;\n};\n\ninterface SVGFECompositeElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly in2: SVGAnimatedString;\n readonly k1: SVGAnimatedNumber;\n readonly k2: SVGAnimatedNumber;\n readonly k3: SVGAnimatedNumber;\n readonly k4: SVGAnimatedNumber;\n readonly operator: SVGAnimatedEnumeration;\n readonly SVG_FECOMPOSITE_OPERATOR_ARITHMETIC: number;\n readonly SVG_FECOMPOSITE_OPERATOR_ATOP: number;\n readonly SVG_FECOMPOSITE_OPERATOR_IN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OUT: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OVER: number;\n readonly SVG_FECOMPOSITE_OPERATOR_UNKNOWN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_XOR: number;\n addEventListener(type: K, listener: (this: SVGFECompositeElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFECompositeElement: {\n prototype: SVGFECompositeElement;\n new(): SVGFECompositeElement;\n readonly SVG_FECOMPOSITE_OPERATOR_ARITHMETIC: number;\n readonly SVG_FECOMPOSITE_OPERATOR_ATOP: number;\n readonly SVG_FECOMPOSITE_OPERATOR_IN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OUT: number;\n readonly SVG_FECOMPOSITE_OPERATOR_OVER: number;\n readonly SVG_FECOMPOSITE_OPERATOR_UNKNOWN: number;\n readonly SVG_FECOMPOSITE_OPERATOR_XOR: number;\n};\n\ninterface SVGFEConvolveMatrixElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly bias: SVGAnimatedNumber;\n readonly divisor: SVGAnimatedNumber;\n readonly edgeMode: SVGAnimatedEnumeration;\n readonly in1: SVGAnimatedString;\n readonly kernelMatrix: SVGAnimatedNumberList;\n readonly kernelUnitLengthX: SVGAnimatedNumber;\n readonly kernelUnitLengthY: SVGAnimatedNumber;\n readonly orderX: SVGAnimatedInteger;\n readonly orderY: SVGAnimatedInteger;\n readonly preserveAlpha: SVGAnimatedBoolean;\n readonly targetX: SVGAnimatedInteger;\n readonly targetY: SVGAnimatedInteger;\n readonly SVG_EDGEMODE_DUPLICATE: number;\n readonly SVG_EDGEMODE_NONE: number;\n readonly SVG_EDGEMODE_UNKNOWN: number;\n readonly SVG_EDGEMODE_WRAP: number;\n addEventListener(type: K, listener: (this: SVGFEConvolveMatrixElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEConvolveMatrixElement: {\n prototype: SVGFEConvolveMatrixElement;\n new(): SVGFEConvolveMatrixElement;\n readonly SVG_EDGEMODE_DUPLICATE: number;\n readonly SVG_EDGEMODE_NONE: number;\n readonly SVG_EDGEMODE_UNKNOWN: number;\n readonly SVG_EDGEMODE_WRAP: number;\n};\n\ninterface SVGFEDiffuseLightingElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly diffuseConstant: SVGAnimatedNumber;\n readonly in1: SVGAnimatedString;\n readonly kernelUnitLengthX: SVGAnimatedNumber;\n readonly kernelUnitLengthY: SVGAnimatedNumber;\n readonly surfaceScale: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFEDiffuseLightingElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEDiffuseLightingElement: {\n prototype: SVGFEDiffuseLightingElement;\n new(): SVGFEDiffuseLightingElement;\n};\n\ninterface SVGFEDisplacementMapElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly in2: SVGAnimatedString;\n readonly scale: SVGAnimatedNumber;\n readonly xChannelSelector: SVGAnimatedEnumeration;\n readonly yChannelSelector: SVGAnimatedEnumeration;\n readonly SVG_CHANNEL_A: number;\n readonly SVG_CHANNEL_B: number;\n readonly SVG_CHANNEL_G: number;\n readonly SVG_CHANNEL_R: number;\n readonly SVG_CHANNEL_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEDisplacementMapElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEDisplacementMapElement: {\n prototype: SVGFEDisplacementMapElement;\n new(): SVGFEDisplacementMapElement;\n readonly SVG_CHANNEL_A: number;\n readonly SVG_CHANNEL_B: number;\n readonly SVG_CHANNEL_G: number;\n readonly SVG_CHANNEL_R: number;\n readonly SVG_CHANNEL_UNKNOWN: number;\n};\n\ninterface SVGFEDistantLightElement extends SVGElement {\n readonly azimuth: SVGAnimatedNumber;\n readonly elevation: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFEDistantLightElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEDistantLightElement: {\n prototype: SVGFEDistantLightElement;\n new(): SVGFEDistantLightElement;\n};\n\ninterface SVGFEFloodElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n addEventListener(type: K, listener: (this: SVGFEFloodElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFloodElement: {\n prototype: SVGFEFloodElement;\n new(): SVGFEFloodElement;\n};\n\ninterface SVGFEFuncAElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncAElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncAElement: {\n prototype: SVGFEFuncAElement;\n new(): SVGFEFuncAElement;\n};\n\ninterface SVGFEFuncBElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncBElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncBElement: {\n prototype: SVGFEFuncBElement;\n new(): SVGFEFuncBElement;\n};\n\ninterface SVGFEFuncGElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncGElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncGElement: {\n prototype: SVGFEFuncGElement;\n new(): SVGFEFuncGElement;\n};\n\ninterface SVGFEFuncRElement extends SVGComponentTransferFunctionElement {\n addEventListener(type: K, listener: (this: SVGFEFuncRElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEFuncRElement: {\n prototype: SVGFEFuncRElement;\n new(): SVGFEFuncRElement;\n};\n\ninterface SVGFEGaussianBlurElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly stdDeviationX: SVGAnimatedNumber;\n readonly stdDeviationY: SVGAnimatedNumber;\n setStdDeviation(stdDeviationX: number, stdDeviationY: number): void;\n addEventListener(type: K, listener: (this: SVGFEGaussianBlurElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEGaussianBlurElement: {\n prototype: SVGFEGaussianBlurElement;\n new(): SVGFEGaussianBlurElement;\n};\n\ninterface SVGFEImageElement extends SVGElement, SVGFilterPrimitiveStandardAttributes, SVGURIReference {\n readonly preserveAspectRatio: SVGAnimatedPreserveAspectRatio;\n addEventListener(type: K, listener: (this: SVGFEImageElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEImageElement: {\n prototype: SVGFEImageElement;\n new(): SVGFEImageElement;\n};\n\ninterface SVGFEMergeElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n addEventListener(type: K, listener: (this: SVGFEMergeElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEMergeElement: {\n prototype: SVGFEMergeElement;\n new(): SVGFEMergeElement;\n};\n\ninterface SVGFEMergeNodeElement extends SVGElement {\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFEMergeNodeElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEMergeNodeElement: {\n prototype: SVGFEMergeNodeElement;\n new(): SVGFEMergeNodeElement;\n};\n\ninterface SVGFEMorphologyElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly operator: SVGAnimatedEnumeration;\n readonly radiusX: SVGAnimatedNumber;\n readonly radiusY: SVGAnimatedNumber;\n readonly SVG_MORPHOLOGY_OPERATOR_DILATE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_ERODE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFEMorphologyElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEMorphologyElement: {\n prototype: SVGFEMorphologyElement;\n new(): SVGFEMorphologyElement;\n readonly SVG_MORPHOLOGY_OPERATOR_DILATE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_ERODE: number;\n readonly SVG_MORPHOLOGY_OPERATOR_UNKNOWN: number;\n};\n\ninterface SVGFEOffsetElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly dx: SVGAnimatedNumber;\n readonly dy: SVGAnimatedNumber;\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFEOffsetElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEOffsetElement: {\n prototype: SVGFEOffsetElement;\n new(): SVGFEOffsetElement;\n};\n\ninterface SVGFEPointLightElement extends SVGElement {\n readonly x: SVGAnimatedNumber;\n readonly y: SVGAnimatedNumber;\n readonly z: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFEPointLightElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFEPointLightElement: {\n prototype: SVGFEPointLightElement;\n new(): SVGFEPointLightElement;\n};\n\ninterface SVGFESpecularLightingElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n readonly kernelUnitLengthX: SVGAnimatedNumber;\n readonly kernelUnitLengthY: SVGAnimatedNumber;\n readonly specularConstant: SVGAnimatedNumber;\n readonly specularExponent: SVGAnimatedNumber;\n readonly surfaceScale: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFESpecularLightingElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFESpecularLightingElement: {\n prototype: SVGFESpecularLightingElement;\n new(): SVGFESpecularLightingElement;\n};\n\ninterface SVGFESpotLightElement extends SVGElement {\n readonly limitingConeAngle: SVGAnimatedNumber;\n readonly pointsAtX: SVGAnimatedNumber;\n readonly pointsAtY: SVGAnimatedNumber;\n readonly pointsAtZ: SVGAnimatedNumber;\n readonly specularExponent: SVGAnimatedNumber;\n readonly x: SVGAnimatedNumber;\n readonly y: SVGAnimatedNumber;\n readonly z: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGFESpotLightElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFESpotLightElement: {\n prototype: SVGFESpotLightElement;\n new(): SVGFESpotLightElement;\n};\n\ninterface SVGFETileElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly in1: SVGAnimatedString;\n addEventListener(type: K, listener: (this: SVGFETileElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFETileElement: {\n prototype: SVGFETileElement;\n new(): SVGFETileElement;\n};\n\ninterface SVGFETurbulenceElement extends SVGElement, SVGFilterPrimitiveStandardAttributes {\n readonly baseFrequencyX: SVGAnimatedNumber;\n readonly baseFrequencyY: SVGAnimatedNumber;\n readonly numOctaves: SVGAnimatedInteger;\n readonly seed: SVGAnimatedNumber;\n readonly stitchTiles: SVGAnimatedEnumeration;\n readonly type: SVGAnimatedEnumeration;\n readonly SVG_STITCHTYPE_NOSTITCH: number;\n readonly SVG_STITCHTYPE_STITCH: number;\n readonly SVG_STITCHTYPE_UNKNOWN: number;\n readonly SVG_TURBULENCE_TYPE_FRACTALNOISE: number;\n readonly SVG_TURBULENCE_TYPE_TURBULENCE: number;\n readonly SVG_TURBULENCE_TYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGFETurbulenceElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFETurbulenceElement: {\n prototype: SVGFETurbulenceElement;\n new(): SVGFETurbulenceElement;\n readonly SVG_STITCHTYPE_NOSTITCH: number;\n readonly SVG_STITCHTYPE_STITCH: number;\n readonly SVG_STITCHTYPE_UNKNOWN: number;\n readonly SVG_TURBULENCE_TYPE_FRACTALNOISE: number;\n readonly SVG_TURBULENCE_TYPE_TURBULENCE: number;\n readonly SVG_TURBULENCE_TYPE_UNKNOWN: number;\n};\n\ninterface SVGFilterElement extends SVGElement, SVGUnitTypes, SVGURIReference {\n readonly filterResX: SVGAnimatedInteger;\n readonly filterResY: SVGAnimatedInteger;\n readonly filterUnits: SVGAnimatedEnumeration;\n readonly height: SVGAnimatedLength;\n readonly primitiveUnits: SVGAnimatedEnumeration;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n setFilterRes(filterResX: number, filterResY: number): void;\n addEventListener(type: K, listener: (this: SVGFilterElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGFilterElement: {\n prototype: SVGFilterElement;\n new(): SVGFilterElement;\n};\n\ninterface SVGForeignObjectElement extends SVGGraphicsElement {\n readonly height: SVGAnimatedLength;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGForeignObjectElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGForeignObjectElement: {\n prototype: SVGForeignObjectElement;\n new(): SVGForeignObjectElement;\n};\n\ninterface SVGGElement extends SVGGraphicsElement {\n addEventListener(type: K, listener: (this: SVGGElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGGElement: {\n prototype: SVGGElement;\n new(): SVGGElement;\n};\n\ninterface SVGGradientElement extends SVGElement, SVGUnitTypes, SVGURIReference {\n readonly gradientTransform: SVGAnimatedTransformList;\n readonly gradientUnits: SVGAnimatedEnumeration;\n readonly spreadMethod: SVGAnimatedEnumeration;\n readonly SVG_SPREADMETHOD_PAD: number;\n readonly SVG_SPREADMETHOD_REFLECT: number;\n readonly SVG_SPREADMETHOD_REPEAT: number;\n readonly SVG_SPREADMETHOD_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGGradientElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGGradientElement: {\n prototype: SVGGradientElement;\n new(): SVGGradientElement;\n readonly SVG_SPREADMETHOD_PAD: number;\n readonly SVG_SPREADMETHOD_REFLECT: number;\n readonly SVG_SPREADMETHOD_REPEAT: number;\n readonly SVG_SPREADMETHOD_UNKNOWN: number;\n};\n\ninterface SVGGraphicsElement extends SVGElement, SVGTests {\n readonly farthestViewportElement: SVGElement;\n readonly nearestViewportElement: SVGElement;\n readonly transform: SVGAnimatedTransformList;\n getBBox(): SVGRect;\n getCTM(): SVGMatrix;\n getScreenCTM(): SVGMatrix;\n getTransformToElement(element: SVGElement): SVGMatrix;\n addEventListener(type: K, listener: (this: SVGGraphicsElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGGraphicsElement: {\n prototype: SVGGraphicsElement;\n new(): SVGGraphicsElement;\n};\n\ninterface SVGImageElement extends SVGGraphicsElement, SVGURIReference {\n readonly height: SVGAnimatedLength;\n readonly preserveAspectRatio: SVGAnimatedPreserveAspectRatio;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGImageElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGImageElement: {\n prototype: SVGImageElement;\n new(): SVGImageElement;\n};\n\ninterface SVGLength {\n readonly unitType: number;\n value: number;\n valueAsString: string;\n valueInSpecifiedUnits: number;\n convertToSpecifiedUnits(unitType: number): void;\n newValueSpecifiedUnits(unitType: number, valueInSpecifiedUnits: number): void;\n readonly SVG_LENGTHTYPE_CM: number;\n readonly SVG_LENGTHTYPE_EMS: number;\n readonly SVG_LENGTHTYPE_EXS: number;\n readonly SVG_LENGTHTYPE_IN: number;\n readonly SVG_LENGTHTYPE_MM: number;\n readonly SVG_LENGTHTYPE_NUMBER: number;\n readonly SVG_LENGTHTYPE_PC: number;\n readonly SVG_LENGTHTYPE_PERCENTAGE: number;\n readonly SVG_LENGTHTYPE_PT: number;\n readonly SVG_LENGTHTYPE_PX: number;\n readonly SVG_LENGTHTYPE_UNKNOWN: number;\n}\n\ndeclare var SVGLength: {\n prototype: SVGLength;\n new(): SVGLength;\n readonly SVG_LENGTHTYPE_CM: number;\n readonly SVG_LENGTHTYPE_EMS: number;\n readonly SVG_LENGTHTYPE_EXS: number;\n readonly SVG_LENGTHTYPE_IN: number;\n readonly SVG_LENGTHTYPE_MM: number;\n readonly SVG_LENGTHTYPE_NUMBER: number;\n readonly SVG_LENGTHTYPE_PC: number;\n readonly SVG_LENGTHTYPE_PERCENTAGE: number;\n readonly SVG_LENGTHTYPE_PT: number;\n readonly SVG_LENGTHTYPE_PX: number;\n readonly SVG_LENGTHTYPE_UNKNOWN: number;\n};\n\ninterface SVGLengthList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGLength): SVGLength;\n clear(): void;\n getItem(index: number): SVGLength;\n initialize(newItem: SVGLength): SVGLength;\n insertItemBefore(newItem: SVGLength, index: number): SVGLength;\n removeItem(index: number): SVGLength;\n replaceItem(newItem: SVGLength, index: number): SVGLength;\n}\n\ndeclare var SVGLengthList: {\n prototype: SVGLengthList;\n new(): SVGLengthList;\n};\n\ninterface SVGLinearGradientElement extends SVGGradientElement {\n readonly x1: SVGAnimatedLength;\n readonly x2: SVGAnimatedLength;\n readonly y1: SVGAnimatedLength;\n readonly y2: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGLinearGradientElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGLinearGradientElement: {\n prototype: SVGLinearGradientElement;\n new(): SVGLinearGradientElement;\n};\n\ninterface SVGLineElement extends SVGGraphicsElement {\n readonly x1: SVGAnimatedLength;\n readonly x2: SVGAnimatedLength;\n readonly y1: SVGAnimatedLength;\n readonly y2: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGLineElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGLineElement: {\n prototype: SVGLineElement;\n new(): SVGLineElement;\n};\n\ninterface SVGMarkerElement extends SVGElement, SVGFitToViewBox {\n readonly markerHeight: SVGAnimatedLength;\n readonly markerUnits: SVGAnimatedEnumeration;\n readonly markerWidth: SVGAnimatedLength;\n readonly orientAngle: SVGAnimatedAngle;\n readonly orientType: SVGAnimatedEnumeration;\n readonly refX: SVGAnimatedLength;\n readonly refY: SVGAnimatedLength;\n setOrientToAngle(angle: SVGAngle): void;\n setOrientToAuto(): void;\n readonly SVG_MARKER_ORIENT_ANGLE: number;\n readonly SVG_MARKER_ORIENT_AUTO: number;\n readonly SVG_MARKER_ORIENT_UNKNOWN: number;\n readonly SVG_MARKERUNITS_STROKEWIDTH: number;\n readonly SVG_MARKERUNITS_UNKNOWN: number;\n readonly SVG_MARKERUNITS_USERSPACEONUSE: number;\n addEventListener(type: K, listener: (this: SVGMarkerElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGMarkerElement: {\n prototype: SVGMarkerElement;\n new(): SVGMarkerElement;\n readonly SVG_MARKER_ORIENT_ANGLE: number;\n readonly SVG_MARKER_ORIENT_AUTO: number;\n readonly SVG_MARKER_ORIENT_UNKNOWN: number;\n readonly SVG_MARKERUNITS_STROKEWIDTH: number;\n readonly SVG_MARKERUNITS_UNKNOWN: number;\n readonly SVG_MARKERUNITS_USERSPACEONUSE: number;\n};\n\ninterface SVGMaskElement extends SVGElement, SVGTests, SVGUnitTypes {\n readonly height: SVGAnimatedLength;\n readonly maskContentUnits: SVGAnimatedEnumeration;\n readonly maskUnits: SVGAnimatedEnumeration;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGMaskElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGMaskElement: {\n prototype: SVGMaskElement;\n new(): SVGMaskElement;\n};\n\ninterface SVGMatrix {\n a: number;\n b: number;\n c: number;\n d: number;\n e: number;\n f: number;\n flipX(): SVGMatrix;\n flipY(): SVGMatrix;\n inverse(): SVGMatrix;\n multiply(secondMatrix: SVGMatrix): SVGMatrix;\n rotate(angle: number): SVGMatrix;\n rotateFromVector(x: number, y: number): SVGMatrix;\n scale(scaleFactor: number): SVGMatrix;\n scaleNonUniform(scaleFactorX: number, scaleFactorY: number): SVGMatrix;\n skewX(angle: number): SVGMatrix;\n skewY(angle: number): SVGMatrix;\n translate(x: number, y: number): SVGMatrix;\n}\n\ndeclare var SVGMatrix: {\n prototype: SVGMatrix;\n new(): SVGMatrix;\n};\n\ninterface SVGMetadataElement extends SVGElement {\n addEventListener(type: K, listener: (this: SVGMetadataElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGMetadataElement: {\n prototype: SVGMetadataElement;\n new(): SVGMetadataElement;\n};\n\ninterface SVGNumber {\n value: number;\n}\n\ndeclare var SVGNumber: {\n prototype: SVGNumber;\n new(): SVGNumber;\n};\n\ninterface SVGNumberList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGNumber): SVGNumber;\n clear(): void;\n getItem(index: number): SVGNumber;\n initialize(newItem: SVGNumber): SVGNumber;\n insertItemBefore(newItem: SVGNumber, index: number): SVGNumber;\n removeItem(index: number): SVGNumber;\n replaceItem(newItem: SVGNumber, index: number): SVGNumber;\n}\n\ndeclare var SVGNumberList: {\n prototype: SVGNumberList;\n new(): SVGNumberList;\n};\n\ninterface SVGPathElement extends SVGGraphicsElement {\n readonly pathSegList: SVGPathSegList;\n createSVGPathSegArcAbs(x: number, y: number, r1: number, r2: number, angle: number, largeArcFlag: boolean, sweepFlag: boolean): SVGPathSegArcAbs;\n createSVGPathSegArcRel(x: number, y: number, r1: number, r2: number, angle: number, largeArcFlag: boolean, sweepFlag: boolean): SVGPathSegArcRel;\n createSVGPathSegClosePath(): SVGPathSegClosePath;\n createSVGPathSegCurvetoCubicAbs(x: number, y: number, x1: number, y1: number, x2: number, y2: number): SVGPathSegCurvetoCubicAbs;\n createSVGPathSegCurvetoCubicRel(x: number, y: number, x1: number, y1: number, x2: number, y2: number): SVGPathSegCurvetoCubicRel;\n createSVGPathSegCurvetoCubicSmoothAbs(x: number, y: number, x2: number, y2: number): SVGPathSegCurvetoCubicSmoothAbs;\n createSVGPathSegCurvetoCubicSmoothRel(x: number, y: number, x2: number, y2: number): SVGPathSegCurvetoCubicSmoothRel;\n createSVGPathSegCurvetoQuadraticAbs(x: number, y: number, x1: number, y1: number): SVGPathSegCurvetoQuadraticAbs;\n createSVGPathSegCurvetoQuadraticRel(x: number, y: number, x1: number, y1: number): SVGPathSegCurvetoQuadraticRel;\n createSVGPathSegCurvetoQuadraticSmoothAbs(x: number, y: number): SVGPathSegCurvetoQuadraticSmoothAbs;\n createSVGPathSegCurvetoQuadraticSmoothRel(x: number, y: number): SVGPathSegCurvetoQuadraticSmoothRel;\n createSVGPathSegLinetoAbs(x: number, y: number): SVGPathSegLinetoAbs;\n createSVGPathSegLinetoHorizontalAbs(x: number): SVGPathSegLinetoHorizontalAbs;\n createSVGPathSegLinetoHorizontalRel(x: number): SVGPathSegLinetoHorizontalRel;\n createSVGPathSegLinetoRel(x: number, y: number): SVGPathSegLinetoRel;\n createSVGPathSegLinetoVerticalAbs(y: number): SVGPathSegLinetoVerticalAbs;\n createSVGPathSegLinetoVerticalRel(y: number): SVGPathSegLinetoVerticalRel;\n createSVGPathSegMovetoAbs(x: number, y: number): SVGPathSegMovetoAbs;\n createSVGPathSegMovetoRel(x: number, y: number): SVGPathSegMovetoRel;\n getPathSegAtLength(distance: number): number;\n getPointAtLength(distance: number): SVGPoint;\n getTotalLength(): number;\n addEventListener(type: K, listener: (this: SVGPathElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPathElement: {\n prototype: SVGPathElement;\n new(): SVGPathElement;\n};\n\ninterface SVGPathSeg {\n readonly pathSegType: number;\n readonly pathSegTypeAsLetter: string;\n readonly PATHSEG_ARC_ABS: number;\n readonly PATHSEG_ARC_REL: number;\n readonly PATHSEG_CLOSEPATH: number;\n readonly PATHSEG_CURVETO_CUBIC_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_REL: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL: number;\n readonly PATHSEG_LINETO_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_REL: number;\n readonly PATHSEG_LINETO_REL: number;\n readonly PATHSEG_LINETO_VERTICAL_ABS: number;\n readonly PATHSEG_LINETO_VERTICAL_REL: number;\n readonly PATHSEG_MOVETO_ABS: number;\n readonly PATHSEG_MOVETO_REL: number;\n readonly PATHSEG_UNKNOWN: number;\n}\n\ndeclare var SVGPathSeg: {\n prototype: SVGPathSeg;\n new(): SVGPathSeg;\n readonly PATHSEG_ARC_ABS: number;\n readonly PATHSEG_ARC_REL: number;\n readonly PATHSEG_CLOSEPATH: number;\n readonly PATHSEG_CURVETO_CUBIC_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_REL: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_CUBIC_SMOOTH_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_REL: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS: number;\n readonly PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL: number;\n readonly PATHSEG_LINETO_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_ABS: number;\n readonly PATHSEG_LINETO_HORIZONTAL_REL: number;\n readonly PATHSEG_LINETO_REL: number;\n readonly PATHSEG_LINETO_VERTICAL_ABS: number;\n readonly PATHSEG_LINETO_VERTICAL_REL: number;\n readonly PATHSEG_MOVETO_ABS: number;\n readonly PATHSEG_MOVETO_REL: number;\n readonly PATHSEG_UNKNOWN: number;\n};\n\ninterface SVGPathSegArcAbs extends SVGPathSeg {\n angle: number;\n largeArcFlag: boolean;\n r1: number;\n r2: number;\n sweepFlag: boolean;\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegArcAbs: {\n prototype: SVGPathSegArcAbs;\n new(): SVGPathSegArcAbs;\n};\n\ninterface SVGPathSegArcRel extends SVGPathSeg {\n angle: number;\n largeArcFlag: boolean;\n r1: number;\n r2: number;\n sweepFlag: boolean;\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegArcRel: {\n prototype: SVGPathSegArcRel;\n new(): SVGPathSegArcRel;\n};\n\ninterface SVGPathSegClosePath extends SVGPathSeg {\n}\n\ndeclare var SVGPathSegClosePath: {\n prototype: SVGPathSegClosePath;\n new(): SVGPathSegClosePath;\n};\n\ninterface SVGPathSegCurvetoCubicAbs extends SVGPathSeg {\n x: number;\n x1: number;\n x2: number;\n y: number;\n y1: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicAbs: {\n prototype: SVGPathSegCurvetoCubicAbs;\n new(): SVGPathSegCurvetoCubicAbs;\n};\n\ninterface SVGPathSegCurvetoCubicRel extends SVGPathSeg {\n x: number;\n x1: number;\n x2: number;\n y: number;\n y1: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicRel: {\n prototype: SVGPathSegCurvetoCubicRel;\n new(): SVGPathSegCurvetoCubicRel;\n};\n\ninterface SVGPathSegCurvetoCubicSmoothAbs extends SVGPathSeg {\n x: number;\n x2: number;\n y: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicSmoothAbs: {\n prototype: SVGPathSegCurvetoCubicSmoothAbs;\n new(): SVGPathSegCurvetoCubicSmoothAbs;\n};\n\ninterface SVGPathSegCurvetoCubicSmoothRel extends SVGPathSeg {\n x: number;\n x2: number;\n y: number;\n y2: number;\n}\n\ndeclare var SVGPathSegCurvetoCubicSmoothRel: {\n prototype: SVGPathSegCurvetoCubicSmoothRel;\n new(): SVGPathSegCurvetoCubicSmoothRel;\n};\n\ninterface SVGPathSegCurvetoQuadraticAbs extends SVGPathSeg {\n x: number;\n x1: number;\n y: number;\n y1: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticAbs: {\n prototype: SVGPathSegCurvetoQuadraticAbs;\n new(): SVGPathSegCurvetoQuadraticAbs;\n};\n\ninterface SVGPathSegCurvetoQuadraticRel extends SVGPathSeg {\n x: number;\n x1: number;\n y: number;\n y1: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticRel: {\n prototype: SVGPathSegCurvetoQuadraticRel;\n new(): SVGPathSegCurvetoQuadraticRel;\n};\n\ninterface SVGPathSegCurvetoQuadraticSmoothAbs extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticSmoothAbs: {\n prototype: SVGPathSegCurvetoQuadraticSmoothAbs;\n new(): SVGPathSegCurvetoQuadraticSmoothAbs;\n};\n\ninterface SVGPathSegCurvetoQuadraticSmoothRel extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegCurvetoQuadraticSmoothRel: {\n prototype: SVGPathSegCurvetoQuadraticSmoothRel;\n new(): SVGPathSegCurvetoQuadraticSmoothRel;\n};\n\ninterface SVGPathSegLinetoAbs extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegLinetoAbs: {\n prototype: SVGPathSegLinetoAbs;\n new(): SVGPathSegLinetoAbs;\n};\n\ninterface SVGPathSegLinetoHorizontalAbs extends SVGPathSeg {\n x: number;\n}\n\ndeclare var SVGPathSegLinetoHorizontalAbs: {\n prototype: SVGPathSegLinetoHorizontalAbs;\n new(): SVGPathSegLinetoHorizontalAbs;\n};\n\ninterface SVGPathSegLinetoHorizontalRel extends SVGPathSeg {\n x: number;\n}\n\ndeclare var SVGPathSegLinetoHorizontalRel: {\n prototype: SVGPathSegLinetoHorizontalRel;\n new(): SVGPathSegLinetoHorizontalRel;\n};\n\ninterface SVGPathSegLinetoRel extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegLinetoRel: {\n prototype: SVGPathSegLinetoRel;\n new(): SVGPathSegLinetoRel;\n};\n\ninterface SVGPathSegLinetoVerticalAbs extends SVGPathSeg {\n y: number;\n}\n\ndeclare var SVGPathSegLinetoVerticalAbs: {\n prototype: SVGPathSegLinetoVerticalAbs;\n new(): SVGPathSegLinetoVerticalAbs;\n};\n\ninterface SVGPathSegLinetoVerticalRel extends SVGPathSeg {\n y: number;\n}\n\ndeclare var SVGPathSegLinetoVerticalRel: {\n prototype: SVGPathSegLinetoVerticalRel;\n new(): SVGPathSegLinetoVerticalRel;\n};\n\ninterface SVGPathSegList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGPathSeg): SVGPathSeg;\n clear(): void;\n getItem(index: number): SVGPathSeg;\n initialize(newItem: SVGPathSeg): SVGPathSeg;\n insertItemBefore(newItem: SVGPathSeg, index: number): SVGPathSeg;\n removeItem(index: number): SVGPathSeg;\n replaceItem(newItem: SVGPathSeg, index: number): SVGPathSeg;\n}\n\ndeclare var SVGPathSegList: {\n prototype: SVGPathSegList;\n new(): SVGPathSegList;\n};\n\ninterface SVGPathSegMovetoAbs extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegMovetoAbs: {\n prototype: SVGPathSegMovetoAbs;\n new(): SVGPathSegMovetoAbs;\n};\n\ninterface SVGPathSegMovetoRel extends SVGPathSeg {\n x: number;\n y: number;\n}\n\ndeclare var SVGPathSegMovetoRel: {\n prototype: SVGPathSegMovetoRel;\n new(): SVGPathSegMovetoRel;\n};\n\ninterface SVGPatternElement extends SVGElement, SVGTests, SVGUnitTypes, SVGFitToViewBox, SVGURIReference {\n readonly height: SVGAnimatedLength;\n readonly patternContentUnits: SVGAnimatedEnumeration;\n readonly patternTransform: SVGAnimatedTransformList;\n readonly patternUnits: SVGAnimatedEnumeration;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGPatternElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPatternElement: {\n prototype: SVGPatternElement;\n new(): SVGPatternElement;\n};\n\ninterface SVGPoint {\n x: number;\n y: number;\n matrixTransform(matrix: SVGMatrix): SVGPoint;\n}\n\ndeclare var SVGPoint: {\n prototype: SVGPoint;\n new(): SVGPoint;\n};\n\ninterface SVGPointList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGPoint): SVGPoint;\n clear(): void;\n getItem(index: number): SVGPoint;\n initialize(newItem: SVGPoint): SVGPoint;\n insertItemBefore(newItem: SVGPoint, index: number): SVGPoint;\n removeItem(index: number): SVGPoint;\n replaceItem(newItem: SVGPoint, index: number): SVGPoint;\n}\n\ndeclare var SVGPointList: {\n prototype: SVGPointList;\n new(): SVGPointList;\n};\n\ninterface SVGPolygonElement extends SVGGraphicsElement, SVGAnimatedPoints {\n addEventListener(type: K, listener: (this: SVGPolygonElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPolygonElement: {\n prototype: SVGPolygonElement;\n new(): SVGPolygonElement;\n};\n\ninterface SVGPolylineElement extends SVGGraphicsElement, SVGAnimatedPoints {\n addEventListener(type: K, listener: (this: SVGPolylineElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGPolylineElement: {\n prototype: SVGPolylineElement;\n new(): SVGPolylineElement;\n};\n\ninterface SVGPreserveAspectRatio {\n align: number;\n meetOrSlice: number;\n readonly SVG_MEETORSLICE_MEET: number;\n readonly SVG_MEETORSLICE_SLICE: number;\n readonly SVG_MEETORSLICE_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_NONE: number;\n readonly SVG_PRESERVEASPECTRATIO_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMIN: number;\n}\n\ndeclare var SVGPreserveAspectRatio: {\n prototype: SVGPreserveAspectRatio;\n new(): SVGPreserveAspectRatio;\n readonly SVG_MEETORSLICE_MEET: number;\n readonly SVG_MEETORSLICE_SLICE: number;\n readonly SVG_MEETORSLICE_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_NONE: number;\n readonly SVG_PRESERVEASPECTRATIO_UNKNOWN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMAXYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMIDYMIN: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMAX: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMID: number;\n readonly SVG_PRESERVEASPECTRATIO_XMINYMIN: number;\n};\n\ninterface SVGRadialGradientElement extends SVGGradientElement {\n readonly cx: SVGAnimatedLength;\n readonly cy: SVGAnimatedLength;\n readonly fx: SVGAnimatedLength;\n readonly fy: SVGAnimatedLength;\n readonly r: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGRadialGradientElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGRadialGradientElement: {\n prototype: SVGRadialGradientElement;\n new(): SVGRadialGradientElement;\n};\n\ninterface SVGRect {\n height: number;\n width: number;\n x: number;\n y: number;\n}\n\ndeclare var SVGRect: {\n prototype: SVGRect;\n new(): SVGRect;\n};\n\ninterface SVGRectElement extends SVGGraphicsElement {\n readonly height: SVGAnimatedLength;\n readonly rx: SVGAnimatedLength;\n readonly ry: SVGAnimatedLength;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGRectElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGRectElement: {\n prototype: SVGRectElement;\n new(): SVGRectElement;\n};\n\ninterface SVGScriptElement extends SVGElement, SVGURIReference {\n type: string;\n addEventListener(type: K, listener: (this: SVGScriptElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGScriptElement: {\n prototype: SVGScriptElement;\n new(): SVGScriptElement;\n};\n\ninterface SVGStopElement extends SVGElement {\n readonly offset: SVGAnimatedNumber;\n addEventListener(type: K, listener: (this: SVGStopElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGStopElement: {\n prototype: SVGStopElement;\n new(): SVGStopElement;\n};\n\ninterface SVGStringList {\n readonly numberOfItems: number;\n appendItem(newItem: string): string;\n clear(): void;\n getItem(index: number): string;\n initialize(newItem: string): string;\n insertItemBefore(newItem: string, index: number): string;\n removeItem(index: number): string;\n replaceItem(newItem: string, index: number): string;\n}\n\ndeclare var SVGStringList: {\n prototype: SVGStringList;\n new(): SVGStringList;\n};\n\ninterface SVGStyleElement extends SVGElement {\n disabled: boolean;\n media: string;\n title: string;\n type: string;\n addEventListener(type: K, listener: (this: SVGStyleElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGStyleElement: {\n prototype: SVGStyleElement;\n new(): SVGStyleElement;\n};\n\ninterface SVGSVGElementEventMap extends SVGElementEventMap {\n \"SVGAbort\": Event;\n \"SVGError\": Event;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"SVGUnload\": Event;\n \"SVGZoom\": SVGZoomEvent;\n}\n\ninterface SVGSVGElement extends SVGGraphicsElement, DocumentEvent, SVGFitToViewBox, SVGZoomAndPan {\n contentScriptType: string;\n contentStyleType: string;\n currentScale: number;\n readonly currentTranslate: SVGPoint;\n readonly height: SVGAnimatedLength;\n onabort: (this: SVGSVGElement, ev: Event) => any;\n onerror: (this: SVGSVGElement, ev: Event) => any;\n onresize: (this: SVGSVGElement, ev: UIEvent) => any;\n onscroll: (this: SVGSVGElement, ev: UIEvent) => any;\n onunload: (this: SVGSVGElement, ev: Event) => any;\n onzoom: (this: SVGSVGElement, ev: SVGZoomEvent) => any;\n readonly pixelUnitToMillimeterX: number;\n readonly pixelUnitToMillimeterY: number;\n readonly screenPixelToMillimeterX: number;\n readonly screenPixelToMillimeterY: number;\n readonly viewport: SVGRect;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n checkEnclosure(element: SVGElement, rect: SVGRect): boolean;\n checkIntersection(element: SVGElement, rect: SVGRect): boolean;\n createSVGAngle(): SVGAngle;\n createSVGLength(): SVGLength;\n createSVGMatrix(): SVGMatrix;\n createSVGNumber(): SVGNumber;\n createSVGPoint(): SVGPoint;\n createSVGRect(): SVGRect;\n createSVGTransform(): SVGTransform;\n createSVGTransformFromMatrix(matrix: SVGMatrix): SVGTransform;\n deselectAll(): void;\n forceRedraw(): void;\n getComputedStyle(elt: Element, pseudoElt?: string): CSSStyleDeclaration;\n getCurrentTime(): number;\n getElementById(elementId: string): Element;\n getEnclosureList(rect: SVGRect, referenceElement: SVGElement): NodeListOf;\n getIntersectionList(rect: SVGRect, referenceElement: SVGElement): NodeListOf;\n pauseAnimations(): void;\n setCurrentTime(seconds: number): void;\n suspendRedraw(maxWaitMilliseconds: number): number;\n unpauseAnimations(): void;\n unsuspendRedraw(suspendHandleID: number): void;\n unsuspendRedrawAll(): void;\n addEventListener(type: K, listener: (this: SVGSVGElement, ev: SVGSVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGSVGElement: {\n prototype: SVGSVGElement;\n new(): SVGSVGElement;\n};\n\ninterface SVGSwitchElement extends SVGGraphicsElement {\n addEventListener(type: K, listener: (this: SVGSwitchElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGSwitchElement: {\n prototype: SVGSwitchElement;\n new(): SVGSwitchElement;\n};\n\ninterface SVGSymbolElement extends SVGElement, SVGFitToViewBox {\n addEventListener(type: K, listener: (this: SVGSymbolElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGSymbolElement: {\n prototype: SVGSymbolElement;\n new(): SVGSymbolElement;\n};\n\ninterface SVGTextContentElement extends SVGGraphicsElement {\n readonly lengthAdjust: SVGAnimatedEnumeration;\n readonly textLength: SVGAnimatedLength;\n getCharNumAtPosition(point: SVGPoint): number;\n getComputedTextLength(): number;\n getEndPositionOfChar(charnum: number): SVGPoint;\n getExtentOfChar(charnum: number): SVGRect;\n getNumberOfChars(): number;\n getRotationOfChar(charnum: number): number;\n getStartPositionOfChar(charnum: number): SVGPoint;\n getSubStringLength(charnum: number, nchars: number): number;\n selectSubString(charnum: number, nchars: number): void;\n readonly LENGTHADJUST_SPACING: number;\n readonly LENGTHADJUST_SPACINGANDGLYPHS: number;\n readonly LENGTHADJUST_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGTextContentElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextContentElement: {\n prototype: SVGTextContentElement;\n new(): SVGTextContentElement;\n readonly LENGTHADJUST_SPACING: number;\n readonly LENGTHADJUST_SPACINGANDGLYPHS: number;\n readonly LENGTHADJUST_UNKNOWN: number;\n};\n\ninterface SVGTextElement extends SVGTextPositioningElement {\n addEventListener(type: K, listener: (this: SVGTextElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextElement: {\n prototype: SVGTextElement;\n new(): SVGTextElement;\n};\n\ninterface SVGTextPathElement extends SVGTextContentElement, SVGURIReference {\n readonly method: SVGAnimatedEnumeration;\n readonly spacing: SVGAnimatedEnumeration;\n readonly startOffset: SVGAnimatedLength;\n readonly TEXTPATH_METHODTYPE_ALIGN: number;\n readonly TEXTPATH_METHODTYPE_STRETCH: number;\n readonly TEXTPATH_METHODTYPE_UNKNOWN: number;\n readonly TEXTPATH_SPACINGTYPE_AUTO: number;\n readonly TEXTPATH_SPACINGTYPE_EXACT: number;\n readonly TEXTPATH_SPACINGTYPE_UNKNOWN: number;\n addEventListener(type: K, listener: (this: SVGTextPathElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextPathElement: {\n prototype: SVGTextPathElement;\n new(): SVGTextPathElement;\n readonly TEXTPATH_METHODTYPE_ALIGN: number;\n readonly TEXTPATH_METHODTYPE_STRETCH: number;\n readonly TEXTPATH_METHODTYPE_UNKNOWN: number;\n readonly TEXTPATH_SPACINGTYPE_AUTO: number;\n readonly TEXTPATH_SPACINGTYPE_EXACT: number;\n readonly TEXTPATH_SPACINGTYPE_UNKNOWN: number;\n};\n\ninterface SVGTextPositioningElement extends SVGTextContentElement {\n readonly dx: SVGAnimatedLengthList;\n readonly dy: SVGAnimatedLengthList;\n readonly rotate: SVGAnimatedNumberList;\n readonly x: SVGAnimatedLengthList;\n readonly y: SVGAnimatedLengthList;\n addEventListener(type: K, listener: (this: SVGTextPositioningElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTextPositioningElement: {\n prototype: SVGTextPositioningElement;\n new(): SVGTextPositioningElement;\n};\n\ninterface SVGTitleElement extends SVGElement {\n addEventListener(type: K, listener: (this: SVGTitleElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTitleElement: {\n prototype: SVGTitleElement;\n new(): SVGTitleElement;\n};\n\ninterface SVGTransform {\n readonly angle: number;\n readonly matrix: SVGMatrix;\n readonly type: number;\n setMatrix(matrix: SVGMatrix): void;\n setRotate(angle: number, cx: number, cy: number): void;\n setScale(sx: number, sy: number): void;\n setSkewX(angle: number): void;\n setSkewY(angle: number): void;\n setTranslate(tx: number, ty: number): void;\n readonly SVG_TRANSFORM_MATRIX: number;\n readonly SVG_TRANSFORM_ROTATE: number;\n readonly SVG_TRANSFORM_SCALE: number;\n readonly SVG_TRANSFORM_SKEWX: number;\n readonly SVG_TRANSFORM_SKEWY: number;\n readonly SVG_TRANSFORM_TRANSLATE: number;\n readonly SVG_TRANSFORM_UNKNOWN: number;\n}\n\ndeclare var SVGTransform: {\n prototype: SVGTransform;\n new(): SVGTransform;\n readonly SVG_TRANSFORM_MATRIX: number;\n readonly SVG_TRANSFORM_ROTATE: number;\n readonly SVG_TRANSFORM_SCALE: number;\n readonly SVG_TRANSFORM_SKEWX: number;\n readonly SVG_TRANSFORM_SKEWY: number;\n readonly SVG_TRANSFORM_TRANSLATE: number;\n readonly SVG_TRANSFORM_UNKNOWN: number;\n};\n\ninterface SVGTransformList {\n readonly numberOfItems: number;\n appendItem(newItem: SVGTransform): SVGTransform;\n clear(): void;\n consolidate(): SVGTransform;\n createSVGTransformFromMatrix(matrix: SVGMatrix): SVGTransform;\n getItem(index: number): SVGTransform;\n initialize(newItem: SVGTransform): SVGTransform;\n insertItemBefore(newItem: SVGTransform, index: number): SVGTransform;\n removeItem(index: number): SVGTransform;\n replaceItem(newItem: SVGTransform, index: number): SVGTransform;\n}\n\ndeclare var SVGTransformList: {\n prototype: SVGTransformList;\n new(): SVGTransformList;\n};\n\ninterface SVGTSpanElement extends SVGTextPositioningElement {\n addEventListener(type: K, listener: (this: SVGTSpanElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGTSpanElement: {\n prototype: SVGTSpanElement;\n new(): SVGTSpanElement;\n};\n\ninterface SVGUnitTypes {\n readonly SVG_UNIT_TYPE_OBJECTBOUNDINGBOX: number;\n readonly SVG_UNIT_TYPE_UNKNOWN: number;\n readonly SVG_UNIT_TYPE_USERSPACEONUSE: number;\n}\ndeclare var SVGUnitTypes: SVGUnitTypes;\n\ninterface SVGUseElement extends SVGGraphicsElement, SVGURIReference {\n readonly animatedInstanceRoot: SVGElementInstance;\n readonly height: SVGAnimatedLength;\n readonly instanceRoot: SVGElementInstance;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n addEventListener(type: K, listener: (this: SVGUseElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGUseElement: {\n prototype: SVGUseElement;\n new(): SVGUseElement;\n};\n\ninterface SVGViewElement extends SVGElement, SVGZoomAndPan, SVGFitToViewBox {\n readonly viewTarget: SVGStringList;\n addEventListener(type: K, listener: (this: SVGViewElement, ev: SVGElementEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var SVGViewElement: {\n prototype: SVGViewElement;\n new(): SVGViewElement;\n};\n\ninterface SVGZoomAndPan {\n readonly zoomAndPan: number;\n}\n\ndeclare var SVGZoomAndPan: {\n readonly SVG_ZOOMANDPAN_DISABLE: number;\n readonly SVG_ZOOMANDPAN_MAGNIFY: number;\n readonly SVG_ZOOMANDPAN_UNKNOWN: number;\n};\n\ninterface SVGZoomEvent extends UIEvent {\n readonly newScale: number;\n readonly newTranslate: SVGPoint;\n readonly previousScale: number;\n readonly previousTranslate: SVGPoint;\n readonly zoomRectScreen: SVGRect;\n}\n\ndeclare var SVGZoomEvent: {\n prototype: SVGZoomEvent;\n new(): SVGZoomEvent;\n};\n\ninterface SyncManager {\n getTags(): any;\n register(tag: string): Promise;\n}\n\ndeclare var SyncManager: {\n prototype: SyncManager;\n new(): SyncManager;\n};\n\ninterface Text extends CharacterData {\n readonly wholeText: string;\n readonly assignedSlot: HTMLSlotElement | null;\n splitText(offset: number): Text;\n}\n\ndeclare var Text: {\n prototype: Text;\n new(data?: string): Text;\n};\n\ninterface TextEvent extends UIEvent {\n readonly data: string;\n readonly inputMethod: number;\n readonly locale: string;\n initTextEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, dataArg: string, inputMethod: number, locale: string): void;\n readonly DOM_INPUT_METHOD_DROP: number;\n readonly DOM_INPUT_METHOD_HANDWRITING: number;\n readonly DOM_INPUT_METHOD_IME: number;\n readonly DOM_INPUT_METHOD_KEYBOARD: number;\n readonly DOM_INPUT_METHOD_MULTIMODAL: number;\n readonly DOM_INPUT_METHOD_OPTION: number;\n readonly DOM_INPUT_METHOD_PASTE: number;\n readonly DOM_INPUT_METHOD_SCRIPT: number;\n readonly DOM_INPUT_METHOD_UNKNOWN: number;\n readonly DOM_INPUT_METHOD_VOICE: number;\n}\n\ndeclare var TextEvent: {\n prototype: TextEvent;\n new(): TextEvent;\n readonly DOM_INPUT_METHOD_DROP: number;\n readonly DOM_INPUT_METHOD_HANDWRITING: number;\n readonly DOM_INPUT_METHOD_IME: number;\n readonly DOM_INPUT_METHOD_KEYBOARD: number;\n readonly DOM_INPUT_METHOD_MULTIMODAL: number;\n readonly DOM_INPUT_METHOD_OPTION: number;\n readonly DOM_INPUT_METHOD_PASTE: number;\n readonly DOM_INPUT_METHOD_SCRIPT: number;\n readonly DOM_INPUT_METHOD_UNKNOWN: number;\n readonly DOM_INPUT_METHOD_VOICE: number;\n};\n\ninterface TextMetrics {\n readonly width: number;\n}\n\ndeclare var TextMetrics: {\n prototype: TextMetrics;\n new(): TextMetrics;\n};\n\ninterface TextTrackEventMap {\n \"cuechange\": Event;\n \"error\": Event;\n \"load\": Event;\n}\n\ninterface TextTrack extends EventTarget {\n readonly activeCues: TextTrackCueList;\n readonly cues: TextTrackCueList;\n readonly inBandMetadataTrackDispatchType: string;\n readonly kind: string;\n readonly label: string;\n readonly language: string;\n mode: any;\n oncuechange: (this: TextTrack, ev: Event) => any;\n onerror: (this: TextTrack, ev: Event) => any;\n onload: (this: TextTrack, ev: Event) => any;\n readonly readyState: number;\n addCue(cue: TextTrackCue): void;\n removeCue(cue: TextTrackCue): void;\n readonly DISABLED: number;\n readonly ERROR: number;\n readonly HIDDEN: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n readonly SHOWING: number;\n addEventListener(type: K, listener: (this: TextTrack, ev: TextTrackEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var TextTrack: {\n prototype: TextTrack;\n new(): TextTrack;\n readonly DISABLED: number;\n readonly ERROR: number;\n readonly HIDDEN: number;\n readonly LOADED: number;\n readonly LOADING: number;\n readonly NONE: number;\n readonly SHOWING: number;\n};\n\ninterface TextTrackCueEventMap {\n \"enter\": Event;\n \"exit\": Event;\n}\n\ninterface TextTrackCue extends EventTarget {\n endTime: number;\n id: string;\n onenter: (this: TextTrackCue, ev: Event) => any;\n onexit: (this: TextTrackCue, ev: Event) => any;\n pauseOnExit: boolean;\n startTime: number;\n text: string;\n readonly track: TextTrack;\n getCueAsHTML(): DocumentFragment;\n addEventListener(type: K, listener: (this: TextTrackCue, ev: TextTrackCueEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var TextTrackCue: {\n prototype: TextTrackCue;\n new(startTime: number, endTime: number, text: string): TextTrackCue;\n};\n\ninterface TextTrackCueList {\n readonly length: number;\n getCueById(id: string): TextTrackCue;\n item(index: number): TextTrackCue;\n [index: number]: TextTrackCue;\n}\n\ndeclare var TextTrackCueList: {\n prototype: TextTrackCueList;\n new(): TextTrackCueList;\n};\n\ninterface TextTrackListEventMap {\n \"addtrack\": TrackEvent;\n}\n\ninterface TextTrackList extends EventTarget {\n readonly length: number;\n onaddtrack: ((this: TextTrackList, ev: TrackEvent) => any) | null;\n item(index: number): TextTrack;\n addEventListener(type: K, listener: (this: TextTrackList, ev: TextTrackListEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [index: number]: TextTrack;\n}\n\ndeclare var TextTrackList: {\n prototype: TextTrackList;\n new(): TextTrackList;\n};\n\ninterface TimeRanges {\n readonly length: number;\n end(index: number): number;\n start(index: number): number;\n}\n\ndeclare var TimeRanges: {\n prototype: TimeRanges;\n new(): TimeRanges;\n};\n\ninterface Touch {\n readonly clientX: number;\n readonly clientY: number;\n readonly identifier: number;\n readonly pageX: number;\n readonly pageY: number;\n readonly screenX: number;\n readonly screenY: number;\n readonly target: EventTarget;\n}\n\ndeclare var Touch: {\n prototype: Touch;\n new(): Touch;\n};\n\ninterface TouchEvent extends UIEvent {\n readonly altKey: boolean;\n readonly changedTouches: TouchList;\n readonly charCode: number;\n readonly ctrlKey: boolean;\n readonly keyCode: number;\n readonly metaKey: boolean;\n readonly shiftKey: boolean;\n readonly targetTouches: TouchList;\n readonly touches: TouchList;\n readonly which: number;\n}\n\ndeclare var TouchEvent: {\n prototype: TouchEvent;\n new(type: string, touchEventInit?: TouchEventInit): TouchEvent;\n};\n\ninterface TouchList {\n readonly length: number;\n item(index: number): Touch | null;\n [index: number]: Touch;\n}\n\ndeclare var TouchList: {\n prototype: TouchList;\n new(): TouchList;\n};\n\ninterface TrackEvent extends Event {\n readonly track: VideoTrack | AudioTrack | TextTrack | null;\n}\n\ndeclare var TrackEvent: {\n prototype: TrackEvent;\n new(typeArg: string, eventInitDict?: TrackEventInit): TrackEvent;\n};\n\ninterface TransitionEvent extends Event {\n readonly elapsedTime: number;\n readonly propertyName: string;\n initTransitionEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, propertyNameArg: string, elapsedTimeArg: number): void;\n}\n\ndeclare var TransitionEvent: {\n prototype: TransitionEvent;\n new(typeArg: string, eventInitDict?: TransitionEventInit): TransitionEvent;\n};\n\ninterface TreeWalker {\n currentNode: Node;\n readonly expandEntityReferences: boolean;\n readonly filter: NodeFilter;\n readonly root: Node;\n readonly whatToShow: number;\n firstChild(): Node;\n lastChild(): Node;\n nextNode(): Node;\n nextSibling(): Node;\n parentNode(): Node;\n previousNode(): Node;\n previousSibling(): Node;\n}\n\ndeclare var TreeWalker: {\n prototype: TreeWalker;\n new(): TreeWalker;\n};\n\ninterface UIEvent extends Event {\n readonly detail: number;\n readonly view: Window;\n initUIEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number): void;\n}\n\ndeclare var UIEvent: {\n prototype: UIEvent;\n new(typeArg: string, eventInitDict?: UIEventInit): UIEvent;\n};\n\ninterface UnviewableContentIdentifiedEvent extends NavigationEventWithReferrer {\n readonly mediaType: string;\n}\n\ndeclare var UnviewableContentIdentifiedEvent: {\n prototype: UnviewableContentIdentifiedEvent;\n new(): UnviewableContentIdentifiedEvent;\n};\n\ninterface URL {\n hash: string;\n host: string;\n hostname: string;\n href: string;\n readonly origin: string;\n password: string;\n pathname: string;\n port: string;\n protocol: string;\n search: string;\n username: string;\n readonly searchParams: URLSearchParams;\n toString(): string;\n}\n\ndeclare var URL: {\n prototype: URL;\n new(url: string, base?: string): URL;\n createObjectURL(object: any, options?: ObjectURLOptions): string;\n revokeObjectURL(url: string): void;\n};\n\ninterface ValidityState {\n readonly badInput: boolean;\n readonly customError: boolean;\n readonly patternMismatch: boolean;\n readonly rangeOverflow: boolean;\n readonly rangeUnderflow: boolean;\n readonly stepMismatch: boolean;\n readonly tooLong: boolean;\n readonly typeMismatch: boolean;\n readonly valid: boolean;\n readonly valueMissing: boolean;\n}\n\ndeclare var ValidityState: {\n prototype: ValidityState;\n new(): ValidityState;\n};\n\ninterface VideoPlaybackQuality {\n readonly corruptedVideoFrames: number;\n readonly creationTime: number;\n readonly droppedVideoFrames: number;\n readonly totalFrameDelay: number;\n readonly totalVideoFrames: number;\n}\n\ndeclare var VideoPlaybackQuality: {\n prototype: VideoPlaybackQuality;\n new(): VideoPlaybackQuality;\n};\n\ninterface VideoTrack {\n readonly id: string;\n kind: string;\n readonly label: string;\n language: string;\n selected: boolean;\n readonly sourceBuffer: SourceBuffer;\n}\n\ndeclare var VideoTrack: {\n prototype: VideoTrack;\n new(): VideoTrack;\n};\n\ninterface VideoTrackListEventMap {\n \"addtrack\": TrackEvent;\n \"change\": Event;\n \"removetrack\": TrackEvent;\n}\n\ninterface VideoTrackList extends EventTarget {\n readonly length: number;\n onaddtrack: (this: VideoTrackList, ev: TrackEvent) => any;\n onchange: (this: VideoTrackList, ev: Event) => any;\n onremovetrack: (this: VideoTrackList, ev: TrackEvent) => any;\n readonly selectedIndex: number;\n getTrackById(id: string): VideoTrack | null;\n item(index: number): VideoTrack;\n addEventListener(type: K, listener: (this: VideoTrackList, ev: VideoTrackListEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n [index: number]: VideoTrack;\n}\n\ndeclare var VideoTrackList: {\n prototype: VideoTrackList;\n new(): VideoTrackList;\n};\n\ninterface WaveShaperNode extends AudioNode {\n curve: Float32Array | null;\n oversample: OverSampleType;\n}\n\ndeclare var WaveShaperNode: {\n prototype: WaveShaperNode;\n new(): WaveShaperNode;\n};\n\ninterface WebAuthentication {\n getAssertion(assertionChallenge: any, options?: AssertionOptions): Promise;\n makeCredential(accountInformation: Account, cryptoParameters: ScopedCredentialParameters[], attestationChallenge: any, options?: ScopedCredentialOptions): Promise;\n}\n\ndeclare var WebAuthentication: {\n prototype: WebAuthentication;\n new(): WebAuthentication;\n};\n\ninterface WebAuthnAssertion {\n readonly authenticatorData: ArrayBuffer;\n readonly clientData: ArrayBuffer;\n readonly credential: ScopedCredential;\n readonly signature: ArrayBuffer;\n}\n\ndeclare var WebAuthnAssertion: {\n prototype: WebAuthnAssertion;\n new(): WebAuthnAssertion;\n};\n\ninterface WEBGL_compressed_texture_s3tc {\n readonly COMPRESSED_RGB_S3TC_DXT1_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT1_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT3_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT5_EXT: number;\n}\n\ndeclare var WEBGL_compressed_texture_s3tc: {\n prototype: WEBGL_compressed_texture_s3tc;\n new(): WEBGL_compressed_texture_s3tc;\n readonly COMPRESSED_RGB_S3TC_DXT1_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT1_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT3_EXT: number;\n readonly COMPRESSED_RGBA_S3TC_DXT5_EXT: number;\n};\n\ninterface WEBGL_debug_renderer_info {\n readonly UNMASKED_RENDERER_WEBGL: number;\n readonly UNMASKED_VENDOR_WEBGL: number;\n}\n\ndeclare var WEBGL_debug_renderer_info: {\n prototype: WEBGL_debug_renderer_info;\n new(): WEBGL_debug_renderer_info;\n readonly UNMASKED_RENDERER_WEBGL: number;\n readonly UNMASKED_VENDOR_WEBGL: number;\n};\n\ninterface WEBGL_depth_texture {\n readonly UNSIGNED_INT_24_8_WEBGL: number;\n}\n\ndeclare var WEBGL_depth_texture: {\n prototype: WEBGL_depth_texture;\n new(): WEBGL_depth_texture;\n readonly UNSIGNED_INT_24_8_WEBGL: number;\n};\n\ninterface WebGLActiveInfo {\n readonly name: string;\n readonly size: number;\n readonly type: number;\n}\n\ndeclare var WebGLActiveInfo: {\n prototype: WebGLActiveInfo;\n new(): WebGLActiveInfo;\n};\n\ninterface WebGLBuffer extends WebGLObject {\n}\n\ndeclare var WebGLBuffer: {\n prototype: WebGLBuffer;\n new(): WebGLBuffer;\n};\n\ninterface WebGLContextEvent extends Event {\n readonly statusMessage: string;\n}\n\ndeclare var WebGLContextEvent: {\n prototype: WebGLContextEvent;\n new(typeArg: string, eventInitDict?: WebGLContextEventInit): WebGLContextEvent;\n};\n\ninterface WebGLFramebuffer extends WebGLObject {\n}\n\ndeclare var WebGLFramebuffer: {\n prototype: WebGLFramebuffer;\n new(): WebGLFramebuffer;\n};\n\ninterface WebGLObject {\n}\n\ndeclare var WebGLObject: {\n prototype: WebGLObject;\n new(): WebGLObject;\n};\n\ninterface WebGLProgram extends WebGLObject {\n}\n\ndeclare var WebGLProgram: {\n prototype: WebGLProgram;\n new(): WebGLProgram;\n};\n\ninterface WebGLRenderbuffer extends WebGLObject {\n}\n\ndeclare var WebGLRenderbuffer: {\n prototype: WebGLRenderbuffer;\n new(): WebGLRenderbuffer;\n};\n\ninterface WebGLRenderingContext {\n readonly canvas: HTMLCanvasElement;\n readonly drawingBufferHeight: number;\n readonly drawingBufferWidth: number;\n activeTexture(texture: number): void;\n attachShader(program: WebGLProgram | null, shader: WebGLShader | null): void;\n bindAttribLocation(program: WebGLProgram | null, index: number, name: string): void;\n bindBuffer(target: number, buffer: WebGLBuffer | null): void;\n bindFramebuffer(target: number, framebuffer: WebGLFramebuffer | null): void;\n bindRenderbuffer(target: number, renderbuffer: WebGLRenderbuffer | null): void;\n bindTexture(target: number, texture: WebGLTexture | null): void;\n blendColor(red: number, green: number, blue: number, alpha: number): void;\n blendEquation(mode: number): void;\n blendEquationSeparate(modeRGB: number, modeAlpha: number): void;\n blendFunc(sfactor: number, dfactor: number): void;\n blendFuncSeparate(srcRGB: number, dstRGB: number, srcAlpha: number, dstAlpha: number): void;\n bufferData(target: number, size: number | ArrayBufferView | ArrayBuffer, usage: number): void;\n bufferSubData(target: number, offset: number, data: ArrayBufferView | ArrayBuffer): void;\n checkFramebufferStatus(target: number): number;\n clear(mask: number): void;\n clearColor(red: number, green: number, blue: number, alpha: number): void;\n clearDepth(depth: number): void;\n clearStencil(s: number): void;\n colorMask(red: boolean, green: boolean, blue: boolean, alpha: boolean): void;\n compileShader(shader: WebGLShader | null): void;\n compressedTexImage2D(target: number, level: number, internalformat: number, width: number, height: number, border: number, data: ArrayBufferView): void;\n compressedTexSubImage2D(target: number, level: number, xoffset: number, yoffset: number, width: number, height: number, format: number, data: ArrayBufferView): void;\n copyTexImage2D(target: number, level: number, internalformat: number, x: number, y: number, width: number, height: number, border: number): void;\n copyTexSubImage2D(target: number, level: number, xoffset: number, yoffset: number, x: number, y: number, width: number, height: number): void;\n createBuffer(): WebGLBuffer | null;\n createFramebuffer(): WebGLFramebuffer | null;\n createProgram(): WebGLProgram | null;\n createRenderbuffer(): WebGLRenderbuffer | null;\n createShader(type: number): WebGLShader | null;\n createTexture(): WebGLTexture | null;\n cullFace(mode: number): void;\n deleteBuffer(buffer: WebGLBuffer | null): void;\n deleteFramebuffer(framebuffer: WebGLFramebuffer | null): void;\n deleteProgram(program: WebGLProgram | null): void;\n deleteRenderbuffer(renderbuffer: WebGLRenderbuffer | null): void;\n deleteShader(shader: WebGLShader | null): void;\n deleteTexture(texture: WebGLTexture | null): void;\n depthFunc(func: number): void;\n depthMask(flag: boolean): void;\n depthRange(zNear: number, zFar: number): void;\n detachShader(program: WebGLProgram | null, shader: WebGLShader | null): void;\n disable(cap: number): void;\n disableVertexAttribArray(index: number): void;\n drawArrays(mode: number, first: number, count: number): void;\n drawElements(mode: number, count: number, type: number, offset: number): void;\n enable(cap: number): void;\n enableVertexAttribArray(index: number): void;\n finish(): void;\n flush(): void;\n framebufferRenderbuffer(target: number, attachment: number, renderbuffertarget: number, renderbuffer: WebGLRenderbuffer | null): void;\n framebufferTexture2D(target: number, attachment: number, textarget: number, texture: WebGLTexture | null, level: number): void;\n frontFace(mode: number): void;\n generateMipmap(target: number): void;\n getActiveAttrib(program: WebGLProgram | null, index: number): WebGLActiveInfo | null;\n getActiveUniform(program: WebGLProgram | null, index: number): WebGLActiveInfo | null;\n getAttachedShaders(program: WebGLProgram | null): WebGLShader[] | null;\n getAttribLocation(program: WebGLProgram | null, name: string): number;\n getBufferParameter(target: number, pname: number): any;\n getContextAttributes(): WebGLContextAttributes;\n getError(): number;\n getExtension(name: string): any;\n getFramebufferAttachmentParameter(target: number, attachment: number, pname: number): any;\n getParameter(pname: number): any;\n getProgramInfoLog(program: WebGLProgram | null): string | null;\n getProgramParameter(program: WebGLProgram | null, pname: number): any;\n getRenderbufferParameter(target: number, pname: number): any;\n getShaderInfoLog(shader: WebGLShader | null): string | null;\n getShaderParameter(shader: WebGLShader | null, pname: number): any;\n getShaderPrecisionFormat(shadertype: number, precisiontype: number): WebGLShaderPrecisionFormat | null;\n getShaderSource(shader: WebGLShader | null): string | null;\n getSupportedExtensions(): string[] | null;\n getTexParameter(target: number, pname: number): any;\n getUniform(program: WebGLProgram | null, location: WebGLUniformLocation | null): any;\n getUniformLocation(program: WebGLProgram | null, name: string): WebGLUniformLocation | null;\n getVertexAttrib(index: number, pname: number): any;\n getVertexAttribOffset(index: number, pname: number): number;\n hint(target: number, mode: number): void;\n isBuffer(buffer: WebGLBuffer | null): boolean;\n isContextLost(): boolean;\n isEnabled(cap: number): boolean;\n isFramebuffer(framebuffer: WebGLFramebuffer | null): boolean;\n isProgram(program: WebGLProgram | null): boolean;\n isRenderbuffer(renderbuffer: WebGLRenderbuffer | null): boolean;\n isShader(shader: WebGLShader | null): boolean;\n isTexture(texture: WebGLTexture | null): boolean;\n lineWidth(width: number): void;\n linkProgram(program: WebGLProgram | null): void;\n pixelStorei(pname: number, param: number | boolean): void;\n polygonOffset(factor: number, units: number): void;\n readPixels(x: number, y: number, width: number, height: number, format: number, type: number, pixels: ArrayBufferView | null): void;\n renderbufferStorage(target: number, internalformat: number, width: number, height: number): void;\n sampleCoverage(value: number, invert: boolean): void;\n scissor(x: number, y: number, width: number, height: number): void;\n shaderSource(shader: WebGLShader | null, source: string): void;\n stencilFunc(func: number, ref: number, mask: number): void;\n stencilFuncSeparate(face: number, func: number, ref: number, mask: number): void;\n stencilMask(mask: number): void;\n stencilMaskSeparate(face: number, mask: number): void;\n stencilOp(fail: number, zfail: number, zpass: number): void;\n stencilOpSeparate(face: number, fail: number, zfail: number, zpass: number): void;\n texImage2D(target: number, level: number, internalformat: number, width: number, height: number, border: number, format: number, type: number, pixels: ArrayBufferView | null): void;\n texImage2D(target: number, level: number, internalformat: number, format: number, type: number, pixels: ImageBitmap | ImageData | HTMLVideoElement | HTMLImageElement | HTMLCanvasElement): void;\n texParameterf(target: number, pname: number, param: number): void;\n texParameteri(target: number, pname: number, param: number): void;\n texSubImage2D(target: number, level: number, xoffset: number, yoffset: number, width: number, height: number, format: number, type: number, pixels: ArrayBufferView | null): void;\n texSubImage2D(target: number, level: number, xoffset: number, yoffset: number, format: number, type: number, pixels: ImageBitmap | ImageData | HTMLVideoElement | HTMLImageElement | HTMLCanvasElement): void;\n uniform1f(location: WebGLUniformLocation | null, x: number): void;\n uniform1fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform1i(location: WebGLUniformLocation | null, x: number): void;\n uniform1iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniform2f(location: WebGLUniformLocation | null, x: number, y: number): void;\n uniform2fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform2i(location: WebGLUniformLocation | null, x: number, y: number): void;\n uniform2iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniform3f(location: WebGLUniformLocation | null, x: number, y: number, z: number): void;\n uniform3fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform3i(location: WebGLUniformLocation | null, x: number, y: number, z: number): void;\n uniform3iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniform4f(location: WebGLUniformLocation | null, x: number, y: number, z: number, w: number): void;\n uniform4fv(location: WebGLUniformLocation, v: Float32Array | number[]): void;\n uniform4i(location: WebGLUniformLocation | null, x: number, y: number, z: number, w: number): void;\n uniform4iv(location: WebGLUniformLocation, v: Int32Array | number[]): void;\n uniformMatrix2fv(location: WebGLUniformLocation, transpose: boolean, value: Float32Array | number[]): void;\n uniformMatrix3fv(location: WebGLUniformLocation, transpose: boolean, value: Float32Array | number[]): void;\n uniformMatrix4fv(location: WebGLUniformLocation, transpose: boolean, value: Float32Array | number[]): void;\n useProgram(program: WebGLProgram | null): void;\n validateProgram(program: WebGLProgram | null): void;\n vertexAttrib1f(indx: number, x: number): void;\n vertexAttrib1fv(indx: number, values: Float32Array | number[]): void;\n vertexAttrib2f(indx: number, x: number, y: number): void;\n vertexAttrib2fv(indx: number, values: Float32Array | number[]): void;\n vertexAttrib3f(indx: number, x: number, y: number, z: number): void;\n vertexAttrib3fv(indx: number, values: Float32Array | number[]): void;\n vertexAttrib4f(indx: number, x: number, y: number, z: number, w: number): void;\n vertexAttrib4fv(indx: number, values: Float32Array | number[]): void;\n vertexAttribPointer(indx: number, size: number, type: number, normalized: boolean, stride: number, offset: number): void;\n viewport(x: number, y: number, width: number, height: number): void;\n readonly ACTIVE_ATTRIBUTES: number;\n readonly ACTIVE_TEXTURE: number;\n readonly ACTIVE_UNIFORMS: number;\n readonly ALIASED_LINE_WIDTH_RANGE: number;\n readonly ALIASED_POINT_SIZE_RANGE: number;\n readonly ALPHA: number;\n readonly ALPHA_BITS: number;\n readonly ALWAYS: number;\n readonly ARRAY_BUFFER: number;\n readonly ARRAY_BUFFER_BINDING: number;\n readonly ATTACHED_SHADERS: number;\n readonly BACK: number;\n readonly BLEND: number;\n readonly BLEND_COLOR: number;\n readonly BLEND_DST_ALPHA: number;\n readonly BLEND_DST_RGB: number;\n readonly BLEND_EQUATION: number;\n readonly BLEND_EQUATION_ALPHA: number;\n readonly BLEND_EQUATION_RGB: number;\n readonly BLEND_SRC_ALPHA: number;\n readonly BLEND_SRC_RGB: number;\n readonly BLUE_BITS: number;\n readonly BOOL: number;\n readonly BOOL_VEC2: number;\n readonly BOOL_VEC3: number;\n readonly BOOL_VEC4: number;\n readonly BROWSER_DEFAULT_WEBGL: number;\n readonly BUFFER_SIZE: number;\n readonly BUFFER_USAGE: number;\n readonly BYTE: number;\n readonly CCW: number;\n readonly CLAMP_TO_EDGE: number;\n readonly COLOR_ATTACHMENT0: number;\n readonly COLOR_BUFFER_BIT: number;\n readonly COLOR_CLEAR_VALUE: number;\n readonly COLOR_WRITEMASK: number;\n readonly COMPILE_STATUS: number;\n readonly COMPRESSED_TEXTURE_FORMATS: number;\n readonly CONSTANT_ALPHA: number;\n readonly CONSTANT_COLOR: number;\n readonly CONTEXT_LOST_WEBGL: number;\n readonly CULL_FACE: number;\n readonly CULL_FACE_MODE: number;\n readonly CURRENT_PROGRAM: number;\n readonly CURRENT_VERTEX_ATTRIB: number;\n readonly CW: number;\n readonly DECR: number;\n readonly DECR_WRAP: number;\n readonly DELETE_STATUS: number;\n readonly DEPTH_ATTACHMENT: number;\n readonly DEPTH_BITS: number;\n readonly DEPTH_BUFFER_BIT: number;\n readonly DEPTH_CLEAR_VALUE: number;\n readonly DEPTH_COMPONENT: number;\n readonly DEPTH_COMPONENT16: number;\n readonly DEPTH_FUNC: number;\n readonly DEPTH_RANGE: number;\n readonly DEPTH_STENCIL: number;\n readonly DEPTH_STENCIL_ATTACHMENT: number;\n readonly DEPTH_TEST: number;\n readonly DEPTH_WRITEMASK: number;\n readonly DITHER: number;\n readonly DONT_CARE: number;\n readonly DST_ALPHA: number;\n readonly DST_COLOR: number;\n readonly DYNAMIC_DRAW: number;\n readonly ELEMENT_ARRAY_BUFFER: number;\n readonly ELEMENT_ARRAY_BUFFER_BINDING: number;\n readonly EQUAL: number;\n readonly FASTEST: number;\n readonly FLOAT: number;\n readonly FLOAT_MAT2: number;\n readonly FLOAT_MAT3: number;\n readonly FLOAT_MAT4: number;\n readonly FLOAT_VEC2: number;\n readonly FLOAT_VEC3: number;\n readonly FLOAT_VEC4: number;\n readonly FRAGMENT_SHADER: number;\n readonly FRAMEBUFFER: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_NAME: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL: number;\n readonly FRAMEBUFFER_BINDING: number;\n readonly FRAMEBUFFER_COMPLETE: number;\n readonly FRAMEBUFFER_INCOMPLETE_ATTACHMENT: number;\n readonly FRAMEBUFFER_INCOMPLETE_DIMENSIONS: number;\n readonly FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT: number;\n readonly FRAMEBUFFER_UNSUPPORTED: number;\n readonly FRONT: number;\n readonly FRONT_AND_BACK: number;\n readonly FRONT_FACE: number;\n readonly FUNC_ADD: number;\n readonly FUNC_REVERSE_SUBTRACT: number;\n readonly FUNC_SUBTRACT: number;\n readonly GENERATE_MIPMAP_HINT: number;\n readonly GEQUAL: number;\n readonly GREATER: number;\n readonly GREEN_BITS: number;\n readonly HIGH_FLOAT: number;\n readonly HIGH_INT: number;\n readonly IMPLEMENTATION_COLOR_READ_FORMAT: number;\n readonly IMPLEMENTATION_COLOR_READ_TYPE: number;\n readonly INCR: number;\n readonly INCR_WRAP: number;\n readonly INT: number;\n readonly INT_VEC2: number;\n readonly INT_VEC3: number;\n readonly INT_VEC4: number;\n readonly INVALID_ENUM: number;\n readonly INVALID_FRAMEBUFFER_OPERATION: number;\n readonly INVALID_OPERATION: number;\n readonly INVALID_VALUE: number;\n readonly INVERT: number;\n readonly KEEP: number;\n readonly LEQUAL: number;\n readonly LESS: number;\n readonly LINE_LOOP: number;\n readonly LINE_STRIP: number;\n readonly LINE_WIDTH: number;\n readonly LINEAR: number;\n readonly LINEAR_MIPMAP_LINEAR: number;\n readonly LINEAR_MIPMAP_NEAREST: number;\n readonly LINES: number;\n readonly LINK_STATUS: number;\n readonly LOW_FLOAT: number;\n readonly LOW_INT: number;\n readonly LUMINANCE: number;\n readonly LUMINANCE_ALPHA: number;\n readonly MAX_COMBINED_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_CUBE_MAP_TEXTURE_SIZE: number;\n readonly MAX_FRAGMENT_UNIFORM_VECTORS: number;\n readonly MAX_RENDERBUFFER_SIZE: number;\n readonly MAX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_TEXTURE_SIZE: number;\n readonly MAX_VARYING_VECTORS: number;\n readonly MAX_VERTEX_ATTRIBS: number;\n readonly MAX_VERTEX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_VERTEX_UNIFORM_VECTORS: number;\n readonly MAX_VIEWPORT_DIMS: number;\n readonly MEDIUM_FLOAT: number;\n readonly MEDIUM_INT: number;\n readonly MIRRORED_REPEAT: number;\n readonly NEAREST: number;\n readonly NEAREST_MIPMAP_LINEAR: number;\n readonly NEAREST_MIPMAP_NEAREST: number;\n readonly NEVER: number;\n readonly NICEST: number;\n readonly NO_ERROR: number;\n readonly NONE: number;\n readonly NOTEQUAL: number;\n readonly ONE: number;\n readonly ONE_MINUS_CONSTANT_ALPHA: number;\n readonly ONE_MINUS_CONSTANT_COLOR: number;\n readonly ONE_MINUS_DST_ALPHA: number;\n readonly ONE_MINUS_DST_COLOR: number;\n readonly ONE_MINUS_SRC_ALPHA: number;\n readonly ONE_MINUS_SRC_COLOR: number;\n readonly OUT_OF_MEMORY: number;\n readonly PACK_ALIGNMENT: number;\n readonly POINTS: number;\n readonly POLYGON_OFFSET_FACTOR: number;\n readonly POLYGON_OFFSET_FILL: number;\n readonly POLYGON_OFFSET_UNITS: number;\n readonly RED_BITS: number;\n readonly RENDERBUFFER: number;\n readonly RENDERBUFFER_ALPHA_SIZE: number;\n readonly RENDERBUFFER_BINDING: number;\n readonly RENDERBUFFER_BLUE_SIZE: number;\n readonly RENDERBUFFER_DEPTH_SIZE: number;\n readonly RENDERBUFFER_GREEN_SIZE: number;\n readonly RENDERBUFFER_HEIGHT: number;\n readonly RENDERBUFFER_INTERNAL_FORMAT: number;\n readonly RENDERBUFFER_RED_SIZE: number;\n readonly RENDERBUFFER_STENCIL_SIZE: number;\n readonly RENDERBUFFER_WIDTH: number;\n readonly RENDERER: number;\n readonly REPEAT: number;\n readonly REPLACE: number;\n readonly RGB: number;\n readonly RGB5_A1: number;\n readonly RGB565: number;\n readonly RGBA: number;\n readonly RGBA4: number;\n readonly SAMPLE_ALPHA_TO_COVERAGE: number;\n readonly SAMPLE_BUFFERS: number;\n readonly SAMPLE_COVERAGE: number;\n readonly SAMPLE_COVERAGE_INVERT: number;\n readonly SAMPLE_COVERAGE_VALUE: number;\n readonly SAMPLER_2D: number;\n readonly SAMPLER_CUBE: number;\n readonly SAMPLES: number;\n readonly SCISSOR_BOX: number;\n readonly SCISSOR_TEST: number;\n readonly SHADER_TYPE: number;\n readonly SHADING_LANGUAGE_VERSION: number;\n readonly SHORT: number;\n readonly SRC_ALPHA: number;\n readonly SRC_ALPHA_SATURATE: number;\n readonly SRC_COLOR: number;\n readonly STATIC_DRAW: number;\n readonly STENCIL_ATTACHMENT: number;\n readonly STENCIL_BACK_FAIL: number;\n readonly STENCIL_BACK_FUNC: number;\n readonly STENCIL_BACK_PASS_DEPTH_FAIL: number;\n readonly STENCIL_BACK_PASS_DEPTH_PASS: number;\n readonly STENCIL_BACK_REF: number;\n readonly STENCIL_BACK_VALUE_MASK: number;\n readonly STENCIL_BACK_WRITEMASK: number;\n readonly STENCIL_BITS: number;\n readonly STENCIL_BUFFER_BIT: number;\n readonly STENCIL_CLEAR_VALUE: number;\n readonly STENCIL_FAIL: number;\n readonly STENCIL_FUNC: number;\n readonly STENCIL_INDEX: number;\n readonly STENCIL_INDEX8: number;\n readonly STENCIL_PASS_DEPTH_FAIL: number;\n readonly STENCIL_PASS_DEPTH_PASS: number;\n readonly STENCIL_REF: number;\n readonly STENCIL_TEST: number;\n readonly STENCIL_VALUE_MASK: number;\n readonly STENCIL_WRITEMASK: number;\n readonly STREAM_DRAW: number;\n readonly SUBPIXEL_BITS: number;\n readonly TEXTURE: number;\n readonly TEXTURE_2D: number;\n readonly TEXTURE_BINDING_2D: number;\n readonly TEXTURE_BINDING_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_X: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Z: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_X: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Z: number;\n readonly TEXTURE_MAG_FILTER: number;\n readonly TEXTURE_MIN_FILTER: number;\n readonly TEXTURE_WRAP_S: number;\n readonly TEXTURE_WRAP_T: number;\n readonly TEXTURE0: number;\n readonly TEXTURE1: number;\n readonly TEXTURE10: number;\n readonly TEXTURE11: number;\n readonly TEXTURE12: number;\n readonly TEXTURE13: number;\n readonly TEXTURE14: number;\n readonly TEXTURE15: number;\n readonly TEXTURE16: number;\n readonly TEXTURE17: number;\n readonly TEXTURE18: number;\n readonly TEXTURE19: number;\n readonly TEXTURE2: number;\n readonly TEXTURE20: number;\n readonly TEXTURE21: number;\n readonly TEXTURE22: number;\n readonly TEXTURE23: number;\n readonly TEXTURE24: number;\n readonly TEXTURE25: number;\n readonly TEXTURE26: number;\n readonly TEXTURE27: number;\n readonly TEXTURE28: number;\n readonly TEXTURE29: number;\n readonly TEXTURE3: number;\n readonly TEXTURE30: number;\n readonly TEXTURE31: number;\n readonly TEXTURE4: number;\n readonly TEXTURE5: number;\n readonly TEXTURE6: number;\n readonly TEXTURE7: number;\n readonly TEXTURE8: number;\n readonly TEXTURE9: number;\n readonly TRIANGLE_FAN: number;\n readonly TRIANGLE_STRIP: number;\n readonly TRIANGLES: number;\n readonly UNPACK_ALIGNMENT: number;\n readonly UNPACK_COLORSPACE_CONVERSION_WEBGL: number;\n readonly UNPACK_FLIP_Y_WEBGL: number;\n readonly UNPACK_PREMULTIPLY_ALPHA_WEBGL: number;\n readonly UNSIGNED_BYTE: number;\n readonly UNSIGNED_INT: number;\n readonly UNSIGNED_SHORT: number;\n readonly UNSIGNED_SHORT_4_4_4_4: number;\n readonly UNSIGNED_SHORT_5_5_5_1: number;\n readonly UNSIGNED_SHORT_5_6_5: number;\n readonly VALIDATE_STATUS: number;\n readonly VENDOR: number;\n readonly VERSION: number;\n readonly VERTEX_ATTRIB_ARRAY_BUFFER_BINDING: number;\n readonly VERTEX_ATTRIB_ARRAY_ENABLED: number;\n readonly VERTEX_ATTRIB_ARRAY_NORMALIZED: number;\n readonly VERTEX_ATTRIB_ARRAY_POINTER: number;\n readonly VERTEX_ATTRIB_ARRAY_SIZE: number;\n readonly VERTEX_ATTRIB_ARRAY_STRIDE: number;\n readonly VERTEX_ATTRIB_ARRAY_TYPE: number;\n readonly VERTEX_SHADER: number;\n readonly VIEWPORT: number;\n readonly ZERO: number;\n}\n\ndeclare var WebGLRenderingContext: {\n prototype: WebGLRenderingContext;\n new(): WebGLRenderingContext;\n readonly ACTIVE_ATTRIBUTES: number;\n readonly ACTIVE_TEXTURE: number;\n readonly ACTIVE_UNIFORMS: number;\n readonly ALIASED_LINE_WIDTH_RANGE: number;\n readonly ALIASED_POINT_SIZE_RANGE: number;\n readonly ALPHA: number;\n readonly ALPHA_BITS: number;\n readonly ALWAYS: number;\n readonly ARRAY_BUFFER: number;\n readonly ARRAY_BUFFER_BINDING: number;\n readonly ATTACHED_SHADERS: number;\n readonly BACK: number;\n readonly BLEND: number;\n readonly BLEND_COLOR: number;\n readonly BLEND_DST_ALPHA: number;\n readonly BLEND_DST_RGB: number;\n readonly BLEND_EQUATION: number;\n readonly BLEND_EQUATION_ALPHA: number;\n readonly BLEND_EQUATION_RGB: number;\n readonly BLEND_SRC_ALPHA: number;\n readonly BLEND_SRC_RGB: number;\n readonly BLUE_BITS: number;\n readonly BOOL: number;\n readonly BOOL_VEC2: number;\n readonly BOOL_VEC3: number;\n readonly BOOL_VEC4: number;\n readonly BROWSER_DEFAULT_WEBGL: number;\n readonly BUFFER_SIZE: number;\n readonly BUFFER_USAGE: number;\n readonly BYTE: number;\n readonly CCW: number;\n readonly CLAMP_TO_EDGE: number;\n readonly COLOR_ATTACHMENT0: number;\n readonly COLOR_BUFFER_BIT: number;\n readonly COLOR_CLEAR_VALUE: number;\n readonly COLOR_WRITEMASK: number;\n readonly COMPILE_STATUS: number;\n readonly COMPRESSED_TEXTURE_FORMATS: number;\n readonly CONSTANT_ALPHA: number;\n readonly CONSTANT_COLOR: number;\n readonly CONTEXT_LOST_WEBGL: number;\n readonly CULL_FACE: number;\n readonly CULL_FACE_MODE: number;\n readonly CURRENT_PROGRAM: number;\n readonly CURRENT_VERTEX_ATTRIB: number;\n readonly CW: number;\n readonly DECR: number;\n readonly DECR_WRAP: number;\n readonly DELETE_STATUS: number;\n readonly DEPTH_ATTACHMENT: number;\n readonly DEPTH_BITS: number;\n readonly DEPTH_BUFFER_BIT: number;\n readonly DEPTH_CLEAR_VALUE: number;\n readonly DEPTH_COMPONENT: number;\n readonly DEPTH_COMPONENT16: number;\n readonly DEPTH_FUNC: number;\n readonly DEPTH_RANGE: number;\n readonly DEPTH_STENCIL: number;\n readonly DEPTH_STENCIL_ATTACHMENT: number;\n readonly DEPTH_TEST: number;\n readonly DEPTH_WRITEMASK: number;\n readonly DITHER: number;\n readonly DONT_CARE: number;\n readonly DST_ALPHA: number;\n readonly DST_COLOR: number;\n readonly DYNAMIC_DRAW: number;\n readonly ELEMENT_ARRAY_BUFFER: number;\n readonly ELEMENT_ARRAY_BUFFER_BINDING: number;\n readonly EQUAL: number;\n readonly FASTEST: number;\n readonly FLOAT: number;\n readonly FLOAT_MAT2: number;\n readonly FLOAT_MAT3: number;\n readonly FLOAT_MAT4: number;\n readonly FLOAT_VEC2: number;\n readonly FLOAT_VEC3: number;\n readonly FLOAT_VEC4: number;\n readonly FRAGMENT_SHADER: number;\n readonly FRAMEBUFFER: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_NAME: number;\n readonly FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE: number;\n readonly FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL: number;\n readonly FRAMEBUFFER_BINDING: number;\n readonly FRAMEBUFFER_COMPLETE: number;\n readonly FRAMEBUFFER_INCOMPLETE_ATTACHMENT: number;\n readonly FRAMEBUFFER_INCOMPLETE_DIMENSIONS: number;\n readonly FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT: number;\n readonly FRAMEBUFFER_UNSUPPORTED: number;\n readonly FRONT: number;\n readonly FRONT_AND_BACK: number;\n readonly FRONT_FACE: number;\n readonly FUNC_ADD: number;\n readonly FUNC_REVERSE_SUBTRACT: number;\n readonly FUNC_SUBTRACT: number;\n readonly GENERATE_MIPMAP_HINT: number;\n readonly GEQUAL: number;\n readonly GREATER: number;\n readonly GREEN_BITS: number;\n readonly HIGH_FLOAT: number;\n readonly HIGH_INT: number;\n readonly IMPLEMENTATION_COLOR_READ_FORMAT: number;\n readonly IMPLEMENTATION_COLOR_READ_TYPE: number;\n readonly INCR: number;\n readonly INCR_WRAP: number;\n readonly INT: number;\n readonly INT_VEC2: number;\n readonly INT_VEC3: number;\n readonly INT_VEC4: number;\n readonly INVALID_ENUM: number;\n readonly INVALID_FRAMEBUFFER_OPERATION: number;\n readonly INVALID_OPERATION: number;\n readonly INVALID_VALUE: number;\n readonly INVERT: number;\n readonly KEEP: number;\n readonly LEQUAL: number;\n readonly LESS: number;\n readonly LINE_LOOP: number;\n readonly LINE_STRIP: number;\n readonly LINE_WIDTH: number;\n readonly LINEAR: number;\n readonly LINEAR_MIPMAP_LINEAR: number;\n readonly LINEAR_MIPMAP_NEAREST: number;\n readonly LINES: number;\n readonly LINK_STATUS: number;\n readonly LOW_FLOAT: number;\n readonly LOW_INT: number;\n readonly LUMINANCE: number;\n readonly LUMINANCE_ALPHA: number;\n readonly MAX_COMBINED_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_CUBE_MAP_TEXTURE_SIZE: number;\n readonly MAX_FRAGMENT_UNIFORM_VECTORS: number;\n readonly MAX_RENDERBUFFER_SIZE: number;\n readonly MAX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_TEXTURE_SIZE: number;\n readonly MAX_VARYING_VECTORS: number;\n readonly MAX_VERTEX_ATTRIBS: number;\n readonly MAX_VERTEX_TEXTURE_IMAGE_UNITS: number;\n readonly MAX_VERTEX_UNIFORM_VECTORS: number;\n readonly MAX_VIEWPORT_DIMS: number;\n readonly MEDIUM_FLOAT: number;\n readonly MEDIUM_INT: number;\n readonly MIRRORED_REPEAT: number;\n readonly NEAREST: number;\n readonly NEAREST_MIPMAP_LINEAR: number;\n readonly NEAREST_MIPMAP_NEAREST: number;\n readonly NEVER: number;\n readonly NICEST: number;\n readonly NO_ERROR: number;\n readonly NONE: number;\n readonly NOTEQUAL: number;\n readonly ONE: number;\n readonly ONE_MINUS_CONSTANT_ALPHA: number;\n readonly ONE_MINUS_CONSTANT_COLOR: number;\n readonly ONE_MINUS_DST_ALPHA: number;\n readonly ONE_MINUS_DST_COLOR: number;\n readonly ONE_MINUS_SRC_ALPHA: number;\n readonly ONE_MINUS_SRC_COLOR: number;\n readonly OUT_OF_MEMORY: number;\n readonly PACK_ALIGNMENT: number;\n readonly POINTS: number;\n readonly POLYGON_OFFSET_FACTOR: number;\n readonly POLYGON_OFFSET_FILL: number;\n readonly POLYGON_OFFSET_UNITS: number;\n readonly RED_BITS: number;\n readonly RENDERBUFFER: number;\n readonly RENDERBUFFER_ALPHA_SIZE: number;\n readonly RENDERBUFFER_BINDING: number;\n readonly RENDERBUFFER_BLUE_SIZE: number;\n readonly RENDERBUFFER_DEPTH_SIZE: number;\n readonly RENDERBUFFER_GREEN_SIZE: number;\n readonly RENDERBUFFER_HEIGHT: number;\n readonly RENDERBUFFER_INTERNAL_FORMAT: number;\n readonly RENDERBUFFER_RED_SIZE: number;\n readonly RENDERBUFFER_STENCIL_SIZE: number;\n readonly RENDERBUFFER_WIDTH: number;\n readonly RENDERER: number;\n readonly REPEAT: number;\n readonly REPLACE: number;\n readonly RGB: number;\n readonly RGB5_A1: number;\n readonly RGB565: number;\n readonly RGBA: number;\n readonly RGBA4: number;\n readonly SAMPLE_ALPHA_TO_COVERAGE: number;\n readonly SAMPLE_BUFFERS: number;\n readonly SAMPLE_COVERAGE: number;\n readonly SAMPLE_COVERAGE_INVERT: number;\n readonly SAMPLE_COVERAGE_VALUE: number;\n readonly SAMPLER_2D: number;\n readonly SAMPLER_CUBE: number;\n readonly SAMPLES: number;\n readonly SCISSOR_BOX: number;\n readonly SCISSOR_TEST: number;\n readonly SHADER_TYPE: number;\n readonly SHADING_LANGUAGE_VERSION: number;\n readonly SHORT: number;\n readonly SRC_ALPHA: number;\n readonly SRC_ALPHA_SATURATE: number;\n readonly SRC_COLOR: number;\n readonly STATIC_DRAW: number;\n readonly STENCIL_ATTACHMENT: number;\n readonly STENCIL_BACK_FAIL: number;\n readonly STENCIL_BACK_FUNC: number;\n readonly STENCIL_BACK_PASS_DEPTH_FAIL: number;\n readonly STENCIL_BACK_PASS_DEPTH_PASS: number;\n readonly STENCIL_BACK_REF: number;\n readonly STENCIL_BACK_VALUE_MASK: number;\n readonly STENCIL_BACK_WRITEMASK: number;\n readonly STENCIL_BITS: number;\n readonly STENCIL_BUFFER_BIT: number;\n readonly STENCIL_CLEAR_VALUE: number;\n readonly STENCIL_FAIL: number;\n readonly STENCIL_FUNC: number;\n readonly STENCIL_INDEX: number;\n readonly STENCIL_INDEX8: number;\n readonly STENCIL_PASS_DEPTH_FAIL: number;\n readonly STENCIL_PASS_DEPTH_PASS: number;\n readonly STENCIL_REF: number;\n readonly STENCIL_TEST: number;\n readonly STENCIL_VALUE_MASK: number;\n readonly STENCIL_WRITEMASK: number;\n readonly STREAM_DRAW: number;\n readonly SUBPIXEL_BITS: number;\n readonly TEXTURE: number;\n readonly TEXTURE_2D: number;\n readonly TEXTURE_BINDING_2D: number;\n readonly TEXTURE_BINDING_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_X: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_NEGATIVE_Z: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_X: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Y: number;\n readonly TEXTURE_CUBE_MAP_POSITIVE_Z: number;\n readonly TEXTURE_MAG_FILTER: number;\n readonly TEXTURE_MIN_FILTER: number;\n readonly TEXTURE_WRAP_S: number;\n readonly TEXTURE_WRAP_T: number;\n readonly TEXTURE0: number;\n readonly TEXTURE1: number;\n readonly TEXTURE10: number;\n readonly TEXTURE11: number;\n readonly TEXTURE12: number;\n readonly TEXTURE13: number;\n readonly TEXTURE14: number;\n readonly TEXTURE15: number;\n readonly TEXTURE16: number;\n readonly TEXTURE17: number;\n readonly TEXTURE18: number;\n readonly TEXTURE19: number;\n readonly TEXTURE2: number;\n readonly TEXTURE20: number;\n readonly TEXTURE21: number;\n readonly TEXTURE22: number;\n readonly TEXTURE23: number;\n readonly TEXTURE24: number;\n readonly TEXTURE25: number;\n readonly TEXTURE26: number;\n readonly TEXTURE27: number;\n readonly TEXTURE28: number;\n readonly TEXTURE29: number;\n readonly TEXTURE3: number;\n readonly TEXTURE30: number;\n readonly TEXTURE31: number;\n readonly TEXTURE4: number;\n readonly TEXTURE5: number;\n readonly TEXTURE6: number;\n readonly TEXTURE7: number;\n readonly TEXTURE8: number;\n readonly TEXTURE9: number;\n readonly TRIANGLE_FAN: number;\n readonly TRIANGLE_STRIP: number;\n readonly TRIANGLES: number;\n readonly UNPACK_ALIGNMENT: number;\n readonly UNPACK_COLORSPACE_CONVERSION_WEBGL: number;\n readonly UNPACK_FLIP_Y_WEBGL: number;\n readonly UNPACK_PREMULTIPLY_ALPHA_WEBGL: number;\n readonly UNSIGNED_BYTE: number;\n readonly UNSIGNED_INT: number;\n readonly UNSIGNED_SHORT: number;\n readonly UNSIGNED_SHORT_4_4_4_4: number;\n readonly UNSIGNED_SHORT_5_5_5_1: number;\n readonly UNSIGNED_SHORT_5_6_5: number;\n readonly VALIDATE_STATUS: number;\n readonly VENDOR: number;\n readonly VERSION: number;\n readonly VERTEX_ATTRIB_ARRAY_BUFFER_BINDING: number;\n readonly VERTEX_ATTRIB_ARRAY_ENABLED: number;\n readonly VERTEX_ATTRIB_ARRAY_NORMALIZED: number;\n readonly VERTEX_ATTRIB_ARRAY_POINTER: number;\n readonly VERTEX_ATTRIB_ARRAY_SIZE: number;\n readonly VERTEX_ATTRIB_ARRAY_STRIDE: number;\n readonly VERTEX_ATTRIB_ARRAY_TYPE: number;\n readonly VERTEX_SHADER: number;\n readonly VIEWPORT: number;\n readonly ZERO: number;\n};\n\ninterface WebGLShader extends WebGLObject {\n}\n\ndeclare var WebGLShader: {\n prototype: WebGLShader;\n new(): WebGLShader;\n};\n\ninterface WebGLShaderPrecisionFormat {\n readonly precision: number;\n readonly rangeMax: number;\n readonly rangeMin: number;\n}\n\ndeclare var WebGLShaderPrecisionFormat: {\n prototype: WebGLShaderPrecisionFormat;\n new(): WebGLShaderPrecisionFormat;\n};\n\ninterface WebGLTexture extends WebGLObject {\n}\n\ndeclare var WebGLTexture: {\n prototype: WebGLTexture;\n new(): WebGLTexture;\n};\n\ninterface WebGLUniformLocation {\n}\n\ndeclare var WebGLUniformLocation: {\n prototype: WebGLUniformLocation;\n new(): WebGLUniformLocation;\n};\n\ninterface WebKitCSSMatrix {\n a: number;\n b: number;\n c: number;\n d: number;\n e: number;\n f: number;\n m11: number;\n m12: number;\n m13: number;\n m14: number;\n m21: number;\n m22: number;\n m23: number;\n m24: number;\n m31: number;\n m32: number;\n m33: number;\n m34: number;\n m41: number;\n m42: number;\n m43: number;\n m44: number;\n inverse(): WebKitCSSMatrix;\n multiply(secondMatrix: WebKitCSSMatrix): WebKitCSSMatrix;\n rotate(angleX: number, angleY?: number, angleZ?: number): WebKitCSSMatrix;\n rotateAxisAngle(x: number, y: number, z: number, angle: number): WebKitCSSMatrix;\n scale(scaleX: number, scaleY?: number, scaleZ?: number): WebKitCSSMatrix;\n setMatrixValue(value: string): void;\n skewX(angle: number): WebKitCSSMatrix;\n skewY(angle: number): WebKitCSSMatrix;\n toString(): string;\n translate(x: number, y: number, z?: number): WebKitCSSMatrix;\n}\n\ndeclare var WebKitCSSMatrix: {\n prototype: WebKitCSSMatrix;\n new(text?: string): WebKitCSSMatrix;\n};\n\ninterface WebKitDirectoryEntry extends WebKitEntry {\n createReader(): WebKitDirectoryReader;\n}\n\ndeclare var WebKitDirectoryEntry: {\n prototype: WebKitDirectoryEntry;\n new(): WebKitDirectoryEntry;\n};\n\ninterface WebKitDirectoryReader {\n readEntries(successCallback: WebKitEntriesCallback, errorCallback?: WebKitErrorCallback): void;\n}\n\ndeclare var WebKitDirectoryReader: {\n prototype: WebKitDirectoryReader;\n new(): WebKitDirectoryReader;\n};\n\ninterface WebKitEntry {\n readonly filesystem: WebKitFileSystem;\n readonly fullPath: string;\n readonly isDirectory: boolean;\n readonly isFile: boolean;\n readonly name: string;\n}\n\ndeclare var WebKitEntry: {\n prototype: WebKitEntry;\n new(): WebKitEntry;\n};\n\ninterface WebKitFileEntry extends WebKitEntry {\n file(successCallback: WebKitFileCallback, errorCallback?: WebKitErrorCallback): void;\n}\n\ndeclare var WebKitFileEntry: {\n prototype: WebKitFileEntry;\n new(): WebKitFileEntry;\n};\n\ninterface WebKitFileSystem {\n readonly name: string;\n readonly root: WebKitDirectoryEntry;\n}\n\ndeclare var WebKitFileSystem: {\n prototype: WebKitFileSystem;\n new(): WebKitFileSystem;\n};\n\ninterface WebKitPoint {\n x: number;\n y: number;\n}\n\ndeclare var WebKitPoint: {\n prototype: WebKitPoint;\n new(x?: number, y?: number): WebKitPoint;\n};\n\ninterface webkitRTCPeerConnection extends RTCPeerConnection {\n addEventListener(type: K, listener: (this: webkitRTCPeerConnection, ev: RTCPeerConnectionEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var webkitRTCPeerConnection: {\n prototype: webkitRTCPeerConnection;\n new(configuration: RTCConfiguration): webkitRTCPeerConnection;\n};\n\ninterface WebSocketEventMap {\n \"close\": CloseEvent;\n \"error\": Event;\n \"message\": MessageEvent;\n \"open\": Event;\n}\n\ninterface WebSocket extends EventTarget {\n binaryType: string;\n readonly bufferedAmount: number;\n readonly extensions: string;\n onclose: (this: WebSocket, ev: CloseEvent) => any;\n onerror: (this: WebSocket, ev: Event) => any;\n onmessage: (this: WebSocket, ev: MessageEvent) => any;\n onopen: (this: WebSocket, ev: Event) => any;\n readonly protocol: string;\n readonly readyState: number;\n readonly url: string;\n close(code?: number, reason?: string): void;\n send(data: any): void;\n readonly CLOSED: number;\n readonly CLOSING: number;\n readonly CONNECTING: number;\n readonly OPEN: number;\n addEventListener(type: K, listener: (this: WebSocket, ev: WebSocketEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var WebSocket: {\n prototype: WebSocket;\n new(url: string, protocols?: string | string[]): WebSocket;\n readonly CLOSED: number;\n readonly CLOSING: number;\n readonly CONNECTING: number;\n readonly OPEN: number;\n};\n\ninterface WheelEvent extends MouseEvent {\n readonly deltaMode: number;\n readonly deltaX: number;\n readonly deltaY: number;\n readonly deltaZ: number;\n readonly wheelDelta: number;\n readonly wheelDeltaX: number;\n readonly wheelDeltaY: number;\n getCurrentPoint(element: Element): void;\n initWheelEvent(typeArg: string, canBubbleArg: boolean, cancelableArg: boolean, viewArg: Window, detailArg: number, screenXArg: number, screenYArg: number, clientXArg: number, clientYArg: number, buttonArg: number, relatedTargetArg: EventTarget, modifiersListArg: string, deltaXArg: number, deltaYArg: number, deltaZArg: number, deltaMode: number): void;\n readonly DOM_DELTA_LINE: number;\n readonly DOM_DELTA_PAGE: number;\n readonly DOM_DELTA_PIXEL: number;\n}\n\ndeclare var WheelEvent: {\n prototype: WheelEvent;\n new(typeArg: string, eventInitDict?: WheelEventInit): WheelEvent;\n readonly DOM_DELTA_LINE: number;\n readonly DOM_DELTA_PAGE: number;\n readonly DOM_DELTA_PIXEL: number;\n};\n\ninterface WindowEventMap extends GlobalEventHandlersEventMap {\n \"abort\": UIEvent;\n \"afterprint\": Event;\n \"beforeprint\": Event;\n \"beforeunload\": BeforeUnloadEvent;\n \"blur\": FocusEvent;\n \"canplay\": Event;\n \"canplaythrough\": Event;\n \"change\": Event;\n \"click\": MouseEvent;\n \"compassneedscalibration\": Event;\n \"contextmenu\": PointerEvent;\n \"dblclick\": MouseEvent;\n \"devicelight\": DeviceLightEvent;\n \"devicemotion\": DeviceMotionEvent;\n \"deviceorientation\": DeviceOrientationEvent;\n \"drag\": DragEvent;\n \"dragend\": DragEvent;\n \"dragenter\": DragEvent;\n \"dragleave\": DragEvent;\n \"dragover\": DragEvent;\n \"dragstart\": DragEvent;\n \"drop\": DragEvent;\n \"durationchange\": Event;\n \"emptied\": Event;\n \"ended\": MediaStreamErrorEvent;\n \"error\": ErrorEvent;\n \"focus\": FocusEvent;\n \"hashchange\": HashChangeEvent;\n \"input\": Event;\n \"invalid\": Event;\n \"keydown\": KeyboardEvent;\n \"keypress\": KeyboardEvent;\n \"keyup\": KeyboardEvent;\n \"load\": Event;\n \"loadeddata\": Event;\n \"loadedmetadata\": Event;\n \"loadstart\": Event;\n \"message\": MessageEvent;\n \"mousedown\": MouseEvent;\n \"mouseenter\": MouseEvent;\n \"mouseleave\": MouseEvent;\n \"mousemove\": MouseEvent;\n \"mouseout\": MouseEvent;\n \"mouseover\": MouseEvent;\n \"mouseup\": MouseEvent;\n \"mousewheel\": WheelEvent;\n \"MSGestureChange\": MSGestureEvent;\n \"MSGestureDoubleTap\": MSGestureEvent;\n \"MSGestureEnd\": MSGestureEvent;\n \"MSGestureHold\": MSGestureEvent;\n \"MSGestureStart\": MSGestureEvent;\n \"MSGestureTap\": MSGestureEvent;\n \"MSInertiaStart\": MSGestureEvent;\n \"MSPointerCancel\": MSPointerEvent;\n \"MSPointerDown\": MSPointerEvent;\n \"MSPointerEnter\": MSPointerEvent;\n \"MSPointerLeave\": MSPointerEvent;\n \"MSPointerMove\": MSPointerEvent;\n \"MSPointerOut\": MSPointerEvent;\n \"MSPointerOver\": MSPointerEvent;\n \"MSPointerUp\": MSPointerEvent;\n \"offline\": Event;\n \"online\": Event;\n \"orientationchange\": Event;\n \"pagehide\": PageTransitionEvent;\n \"pageshow\": PageTransitionEvent;\n \"pause\": Event;\n \"play\": Event;\n \"playing\": Event;\n \"popstate\": PopStateEvent;\n \"progress\": ProgressEvent;\n \"ratechange\": Event;\n \"readystatechange\": ProgressEvent;\n \"reset\": Event;\n \"resize\": UIEvent;\n \"scroll\": UIEvent;\n \"seeked\": Event;\n \"seeking\": Event;\n \"select\": UIEvent;\n \"stalled\": Event;\n \"storage\": StorageEvent;\n \"submit\": Event;\n \"suspend\": Event;\n \"timeupdate\": Event;\n \"touchcancel\": TouchEvent;\n \"touchend\": TouchEvent;\n \"touchmove\": TouchEvent;\n \"touchstart\": TouchEvent;\n \"unload\": Event;\n \"volumechange\": Event;\n \"waiting\": Event;\n}\n\ninterface Window extends EventTarget, WindowTimers, WindowSessionStorage, WindowLocalStorage, WindowConsole, GlobalEventHandlers, IDBEnvironment, WindowBase64, GlobalFetch {\n readonly applicationCache: ApplicationCache;\n readonly caches: CacheStorage;\n readonly clientInformation: Navigator;\n readonly closed: boolean;\n readonly crypto: Crypto;\n defaultStatus: string;\n readonly devicePixelRatio: number;\n readonly document: Document;\n readonly doNotTrack: string;\n event: Event | undefined;\n readonly external: External;\n readonly frameElement: Element;\n readonly frames: Window;\n readonly history: History;\n readonly innerHeight: number;\n readonly innerWidth: number;\n readonly isSecureContext: boolean;\n readonly length: number;\n readonly location: Location;\n readonly locationbar: BarProp;\n readonly menubar: BarProp;\n readonly msContentScript: ExtensionScriptApis;\n readonly msCredentials: MSCredentials;\n name: string;\n readonly navigator: Navigator;\n offscreenBuffering: string | boolean;\n onabort: (this: Window, ev: UIEvent) => any;\n onafterprint: (this: Window, ev: Event) => any;\n onbeforeprint: (this: Window, ev: Event) => any;\n onbeforeunload: (this: Window, ev: BeforeUnloadEvent) => any;\n onblur: (this: Window, ev: FocusEvent) => any;\n oncanplay: (this: Window, ev: Event) => any;\n oncanplaythrough: (this: Window, ev: Event) => any;\n onchange: (this: Window, ev: Event) => any;\n onclick: (this: Window, ev: MouseEvent) => any;\n oncompassneedscalibration: (this: Window, ev: Event) => any;\n oncontextmenu: (this: Window, ev: PointerEvent) => any;\n ondblclick: (this: Window, ev: MouseEvent) => any;\n ondevicelight: (this: Window, ev: DeviceLightEvent) => any;\n ondevicemotion: (this: Window, ev: DeviceMotionEvent) => any;\n ondeviceorientation: (this: Window, ev: DeviceOrientationEvent) => any;\n ondrag: (this: Window, ev: DragEvent) => any;\n ondragend: (this: Window, ev: DragEvent) => any;\n ondragenter: (this: Window, ev: DragEvent) => any;\n ondragleave: (this: Window, ev: DragEvent) => any;\n ondragover: (this: Window, ev: DragEvent) => any;\n ondragstart: (this: Window, ev: DragEvent) => any;\n ondrop: (this: Window, ev: DragEvent) => any;\n ondurationchange: (this: Window, ev: Event) => any;\n onemptied: (this: Window, ev: Event) => any;\n onended: (this: Window, ev: MediaStreamErrorEvent) => any;\n onerror: ErrorEventHandler;\n onfocus: (this: Window, ev: FocusEvent) => any;\n onhashchange: (this: Window, ev: HashChangeEvent) => any;\n oninput: (this: Window, ev: Event) => any;\n oninvalid: (this: Window, ev: Event) => any;\n onkeydown: (this: Window, ev: KeyboardEvent) => any;\n onkeypress: (this: Window, ev: KeyboardEvent) => any;\n onkeyup: (this: Window, ev: KeyboardEvent) => any;\n onload: (this: Window, ev: Event) => any;\n onloadeddata: (this: Window, ev: Event) => any;\n onloadedmetadata: (this: Window, ev: Event) => any;\n onloadstart: (this: Window, ev: Event) => any;\n onmessage: (this: Window, ev: MessageEvent) => any;\n onmousedown: (this: Window, ev: MouseEvent) => any;\n onmouseenter: (this: Window, ev: MouseEvent) => any;\n onmouseleave: (this: Window, ev: MouseEvent) => any;\n onmousemove: (this: Window, ev: MouseEvent) => any;\n onmouseout: (this: Window, ev: MouseEvent) => any;\n onmouseover: (this: Window, ev: MouseEvent) => any;\n onmouseup: (this: Window, ev: MouseEvent) => any;\n onmousewheel: (this: Window, ev: WheelEvent) => any;\n onmsgesturechange: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturedoubletap: (this: Window, ev: MSGestureEvent) => any;\n onmsgestureend: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturehold: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturestart: (this: Window, ev: MSGestureEvent) => any;\n onmsgesturetap: (this: Window, ev: MSGestureEvent) => any;\n onmsinertiastart: (this: Window, ev: MSGestureEvent) => any;\n onmspointercancel: (this: Window, ev: MSPointerEvent) => any;\n onmspointerdown: (this: Window, ev: MSPointerEvent) => any;\n onmspointerenter: (this: Window, ev: MSPointerEvent) => any;\n onmspointerleave: (this: Window, ev: MSPointerEvent) => any;\n onmspointermove: (this: Window, ev: MSPointerEvent) => any;\n onmspointerout: (this: Window, ev: MSPointerEvent) => any;\n onmspointerover: (this: Window, ev: MSPointerEvent) => any;\n onmspointerup: (this: Window, ev: MSPointerEvent) => any;\n onoffline: (this: Window, ev: Event) => any;\n ononline: (this: Window, ev: Event) => any;\n onorientationchange: (this: Window, ev: Event) => any;\n onpagehide: (this: Window, ev: PageTransitionEvent) => any;\n onpageshow: (this: Window, ev: PageTransitionEvent) => any;\n onpause: (this: Window, ev: Event) => any;\n onplay: (this: Window, ev: Event) => any;\n onplaying: (this: Window, ev: Event) => any;\n onpopstate: (this: Window, ev: PopStateEvent) => any;\n onprogress: (this: Window, ev: ProgressEvent) => any;\n onratechange: (this: Window, ev: Event) => any;\n onreadystatechange: (this: Window, ev: ProgressEvent) => any;\n onreset: (this: Window, ev: Event) => any;\n onresize: (this: Window, ev: UIEvent) => any;\n onscroll: (this: Window, ev: UIEvent) => any;\n onseeked: (this: Window, ev: Event) => any;\n onseeking: (this: Window, ev: Event) => any;\n onselect: (this: Window, ev: UIEvent) => any;\n onstalled: (this: Window, ev: Event) => any;\n onstorage: (this: Window, ev: StorageEvent) => any;\n onsubmit: (this: Window, ev: Event) => any;\n onsuspend: (this: Window, ev: Event) => any;\n ontimeupdate: (this: Window, ev: Event) => any;\n ontouchcancel: (ev: TouchEvent) => any;\n ontouchend: (ev: TouchEvent) => any;\n ontouchmove: (ev: TouchEvent) => any;\n ontouchstart: (ev: TouchEvent) => any;\n onunload: (this: Window, ev: Event) => any;\n onvolumechange: (this: Window, ev: Event) => any;\n onwaiting: (this: Window, ev: Event) => any;\n opener: any;\n orientation: string | number;\n readonly outerHeight: number;\n readonly outerWidth: number;\n readonly pageXOffset: number;\n readonly pageYOffset: number;\n readonly parent: Window;\n readonly performance: Performance;\n readonly personalbar: BarProp;\n readonly screen: Screen;\n readonly screenLeft: number;\n readonly screenTop: number;\n readonly screenX: number;\n readonly screenY: number;\n readonly scrollbars: BarProp;\n readonly scrollX: number;\n readonly scrollY: number;\n readonly self: Window;\n readonly speechSynthesis: SpeechSynthesis;\n status: string;\n readonly statusbar: BarProp;\n readonly styleMedia: StyleMedia;\n readonly toolbar: BarProp;\n readonly top: Window;\n readonly window: Window;\n URL: typeof URL;\n URLSearchParams: typeof URLSearchParams;\n Blob: typeof Blob;\n customElements: CustomElementRegistry;\n alert(message?: any): void;\n blur(): void;\n cancelAnimationFrame(handle: number): void;\n captureEvents(): void;\n close(): void;\n confirm(message?: string): boolean;\n departFocus(navigationReason: NavigationReason, origin: FocusNavigationOrigin): void;\n focus(): void;\n getComputedStyle(elt: Element, pseudoElt?: string): CSSStyleDeclaration;\n getMatchedCSSRules(elt: Element, pseudoElt?: string): CSSRuleList;\n getSelection(): Selection;\n matchMedia(mediaQuery: string): MediaQueryList;\n moveBy(x?: number, y?: number): void;\n moveTo(x?: number, y?: number): void;\n msWriteProfilerMark(profilerMarkName: string): void;\n open(url?: string, target?: string, features?: string, replace?: boolean): Window;\n postMessage(message: any, targetOrigin: string, transfer?: any[]): void;\n print(): void;\n prompt(message?: string, _default?: string): string | null;\n releaseEvents(): void;\n requestAnimationFrame(callback: FrameRequestCallback): number;\n resizeBy(x?: number, y?: number): void;\n resizeTo(x?: number, y?: number): void;\n scroll(x?: number, y?: number): void;\n scrollBy(x?: number, y?: number): void;\n scrollTo(x?: number, y?: number): void;\n stop(): void;\n webkitCancelAnimationFrame(handle: number): void;\n webkitConvertPointFromNodeToPage(node: Node, pt: WebKitPoint): WebKitPoint;\n webkitConvertPointFromPageToNode(node: Node, pt: WebKitPoint): WebKitPoint;\n webkitRequestAnimationFrame(callback: FrameRequestCallback): number;\n createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, options?: ImageBitmapOptions): Promise;\n createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, sx: number, sy: number, sw: number, sh: number, options?: ImageBitmapOptions): Promise;\n scroll(options?: ScrollToOptions): void;\n scrollTo(options?: ScrollToOptions): void;\n scrollBy(options?: ScrollToOptions): void;\n addEventListener(type: K, listener: (this: Window, ev: WindowEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Window: {\n prototype: Window;\n new(): Window;\n};\n\ninterface WorkerEventMap extends AbstractWorkerEventMap {\n \"message\": MessageEvent;\n}\n\ninterface Worker extends EventTarget, AbstractWorker {\n onmessage: (this: Worker, ev: MessageEvent) => any;\n postMessage(message: any, transfer?: any[]): void;\n terminate(): void;\n addEventListener(type: K, listener: (this: Worker, ev: WorkerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var Worker: {\n prototype: Worker;\n new(stringUrl: string): Worker;\n};\n\ninterface XMLDocument extends Document {\n addEventListener(type: K, listener: (this: XMLDocument, ev: DocumentEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var XMLDocument: {\n prototype: XMLDocument;\n new(): XMLDocument;\n};\n\ninterface XMLHttpRequestEventMap extends XMLHttpRequestEventTargetEventMap {\n \"readystatechange\": Event;\n}\n\ninterface XMLHttpRequest extends EventTarget, XMLHttpRequestEventTarget {\n onreadystatechange: (this: XMLHttpRequest, ev: Event) => any;\n readonly readyState: number;\n readonly response: any;\n readonly responseText: string;\n responseType: XMLHttpRequestResponseType;\n readonly responseURL: string;\n readonly responseXML: Document | null;\n readonly status: number;\n readonly statusText: string;\n timeout: number;\n readonly upload: XMLHttpRequestUpload;\n withCredentials: boolean;\n msCaching?: string;\n abort(): void;\n getAllResponseHeaders(): string;\n getResponseHeader(header: string): string | null;\n msCachingEnabled(): boolean;\n open(method: string, url: string, async?: boolean, user?: string, password?: string): void;\n overrideMimeType(mime: string): void;\n send(data?: Document): void;\n send(data?: string): void;\n send(data?: any): void;\n setRequestHeader(header: string, value: string): void;\n readonly DONE: number;\n readonly HEADERS_RECEIVED: number;\n readonly LOADING: number;\n readonly OPENED: number;\n readonly UNSENT: number;\n addEventListener(type: K, listener: (this: XMLHttpRequest, ev: XMLHttpRequestEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var XMLHttpRequest: {\n prototype: XMLHttpRequest;\n new(): XMLHttpRequest;\n readonly DONE: number;\n readonly HEADERS_RECEIVED: number;\n readonly LOADING: number;\n readonly OPENED: number;\n readonly UNSENT: number;\n};\n\ninterface XMLHttpRequestUpload extends EventTarget, XMLHttpRequestEventTarget {\n addEventListener(type: K, listener: (this: XMLHttpRequestUpload, ev: XMLHttpRequestEventTargetEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ndeclare var XMLHttpRequestUpload: {\n prototype: XMLHttpRequestUpload;\n new(): XMLHttpRequestUpload;\n};\n\ninterface XMLSerializer {\n serializeToString(target: Node): string;\n}\n\ndeclare var XMLSerializer: {\n prototype: XMLSerializer;\n new(): XMLSerializer;\n};\n\ninterface XPathEvaluator {\n createExpression(expression: string, resolver: XPathNSResolver): XPathExpression;\n createNSResolver(nodeResolver?: Node): XPathNSResolver;\n evaluate(expression: string, contextNode: Node, resolver: XPathNSResolver | null, type: number, result: XPathResult | null): XPathResult;\n}\n\ndeclare var XPathEvaluator: {\n prototype: XPathEvaluator;\n new(): XPathEvaluator;\n};\n\ninterface XPathExpression {\n evaluate(contextNode: Node, type: number, result: XPathResult | null): XPathResult;\n}\n\ndeclare var XPathExpression: {\n prototype: XPathExpression;\n new(): XPathExpression;\n};\n\ninterface XPathNSResolver {\n lookupNamespaceURI(prefix: string): string;\n}\n\ndeclare var XPathNSResolver: {\n prototype: XPathNSResolver;\n new(): XPathNSResolver;\n};\n\ninterface XPathResult {\n readonly booleanValue: boolean;\n readonly invalidIteratorState: boolean;\n readonly numberValue: number;\n readonly resultType: number;\n readonly singleNodeValue: Node;\n readonly snapshotLength: number;\n readonly stringValue: string;\n iterateNext(): Node;\n snapshotItem(index: number): Node;\n readonly ANY_TYPE: number;\n readonly ANY_UNORDERED_NODE_TYPE: number;\n readonly BOOLEAN_TYPE: number;\n readonly FIRST_ORDERED_NODE_TYPE: number;\n readonly NUMBER_TYPE: number;\n readonly ORDERED_NODE_ITERATOR_TYPE: number;\n readonly ORDERED_NODE_SNAPSHOT_TYPE: number;\n readonly STRING_TYPE: number;\n readonly UNORDERED_NODE_ITERATOR_TYPE: number;\n readonly UNORDERED_NODE_SNAPSHOT_TYPE: number;\n}\n\ndeclare var XPathResult: {\n prototype: XPathResult;\n new(): XPathResult;\n readonly ANY_TYPE: number;\n readonly ANY_UNORDERED_NODE_TYPE: number;\n readonly BOOLEAN_TYPE: number;\n readonly FIRST_ORDERED_NODE_TYPE: number;\n readonly NUMBER_TYPE: number;\n readonly ORDERED_NODE_ITERATOR_TYPE: number;\n readonly ORDERED_NODE_SNAPSHOT_TYPE: number;\n readonly STRING_TYPE: number;\n readonly UNORDERED_NODE_ITERATOR_TYPE: number;\n readonly UNORDERED_NODE_SNAPSHOT_TYPE: number;\n};\n\ninterface XSLTProcessor {\n clearParameters(): void;\n getParameter(namespaceURI: string, localName: string): any;\n importStylesheet(style: Node): void;\n removeParameter(namespaceURI: string, localName: string): void;\n reset(): void;\n setParameter(namespaceURI: string, localName: string, value: any): void;\n transformToDocument(source: Node): Document;\n transformToFragment(source: Node, document: Document): DocumentFragment;\n}\n\ndeclare var XSLTProcessor: {\n prototype: XSLTProcessor;\n new(): XSLTProcessor;\n};\n\ninterface AbstractWorkerEventMap {\n \"error\": ErrorEvent;\n}\n\ninterface AbstractWorker {\n onerror: (this: AbstractWorker, ev: ErrorEvent) => any;\n addEventListener(type: K, listener: (this: AbstractWorker, ev: AbstractWorkerEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface Body {\n readonly bodyUsed: boolean;\n arrayBuffer(): Promise;\n blob(): Promise;\n json(): Promise;\n text(): Promise;\n formData(): Promise;\n}\n\ninterface CanvasPathMethods {\n arc(x: number, y: number, radius: number, startAngle: number, endAngle: number, anticlockwise?: boolean): void;\n arcTo(x1: number, y1: number, x2: number, y2: number, radius: number): void;\n bezierCurveTo(cp1x: number, cp1y: number, cp2x: number, cp2y: number, x: number, y: number): void;\n closePath(): void;\n ellipse(x: number, y: number, radiusX: number, radiusY: number, rotation: number, startAngle: number, endAngle: number, anticlockwise?: boolean): void;\n lineTo(x: number, y: number): void;\n moveTo(x: number, y: number): void;\n quadraticCurveTo(cpx: number, cpy: number, x: number, y: number): void;\n rect(x: number, y: number, w: number, h: number): void;\n}\n\ninterface ChildNode {\n remove(): void;\n}\n\ninterface DocumentEvent {\n createEvent(eventInterface: \"AnimationEvent\"): AnimationEvent;\n createEvent(eventInterface: \"AudioProcessingEvent\"): AudioProcessingEvent;\n createEvent(eventInterface: \"BeforeUnloadEvent\"): BeforeUnloadEvent;\n createEvent(eventInterface: \"ClipboardEvent\"): ClipboardEvent;\n createEvent(eventInterface: \"CloseEvent\"): CloseEvent;\n createEvent(eventInterface: \"CompositionEvent\"): CompositionEvent;\n createEvent(eventInterface: \"CustomEvent\"): CustomEvent;\n createEvent(eventInterface: \"DeviceLightEvent\"): DeviceLightEvent;\n createEvent(eventInterface: \"DeviceMotionEvent\"): DeviceMotionEvent;\n createEvent(eventInterface: \"DeviceOrientationEvent\"): DeviceOrientationEvent;\n createEvent(eventInterface: \"DragEvent\"): DragEvent;\n createEvent(eventInterface: \"ErrorEvent\"): ErrorEvent;\n createEvent(eventInterface: \"Event\"): Event;\n createEvent(eventInterface: \"Events\"): Event;\n createEvent(eventInterface: \"FocusEvent\"): FocusEvent;\n createEvent(eventInterface: \"FocusNavigationEvent\"): FocusNavigationEvent;\n createEvent(eventInterface: \"GamepadEvent\"): GamepadEvent;\n createEvent(eventInterface: \"HashChangeEvent\"): HashChangeEvent;\n createEvent(eventInterface: \"IDBVersionChangeEvent\"): IDBVersionChangeEvent;\n createEvent(eventInterface: \"KeyboardEvent\"): KeyboardEvent;\n createEvent(eventInterface: \"ListeningStateChangedEvent\"): ListeningStateChangedEvent;\n createEvent(eventInterface: \"LongRunningScriptDetectedEvent\"): LongRunningScriptDetectedEvent;\n createEvent(eventInterface: \"MSGestureEvent\"): MSGestureEvent;\n createEvent(eventInterface: \"MSManipulationEvent\"): MSManipulationEvent;\n createEvent(eventInterface: \"MSMediaKeyMessageEvent\"): MSMediaKeyMessageEvent;\n createEvent(eventInterface: \"MSMediaKeyNeededEvent\"): MSMediaKeyNeededEvent;\n createEvent(eventInterface: \"MSPointerEvent\"): MSPointerEvent;\n createEvent(eventInterface: \"MSSiteModeEvent\"): MSSiteModeEvent;\n createEvent(eventInterface: \"MediaEncryptedEvent\"): MediaEncryptedEvent;\n createEvent(eventInterface: \"MediaKeyMessageEvent\"): MediaKeyMessageEvent;\n createEvent(eventInterface: \"MediaStreamErrorEvent\"): MediaStreamErrorEvent;\n createEvent(eventInterface: \"MediaStreamEvent\"): MediaStreamEvent;\n createEvent(eventInterface: \"MediaStreamTrackEvent\"): MediaStreamTrackEvent;\n createEvent(eventInterface: \"MessageEvent\"): MessageEvent;\n createEvent(eventInterface: \"MouseEvent\"): MouseEvent;\n createEvent(eventInterface: \"MouseEvents\"): MouseEvent;\n createEvent(eventInterface: \"MutationEvent\"): MutationEvent;\n createEvent(eventInterface: \"MutationEvents\"): MutationEvent;\n createEvent(eventInterface: \"NavigationCompletedEvent\"): NavigationCompletedEvent;\n createEvent(eventInterface: \"NavigationEvent\"): NavigationEvent;\n createEvent(eventInterface: \"NavigationEventWithReferrer\"): NavigationEventWithReferrer;\n createEvent(eventInterface: \"OfflineAudioCompletionEvent\"): OfflineAudioCompletionEvent;\n createEvent(eventInterface: \"OverflowEvent\"): OverflowEvent;\n createEvent(eventInterface: \"PageTransitionEvent\"): PageTransitionEvent;\n createEvent(eventInterface: \"PaymentRequestUpdateEvent\"): PaymentRequestUpdateEvent;\n createEvent(eventInterface: \"PermissionRequestedEvent\"): PermissionRequestedEvent;\n createEvent(eventInterface: \"PointerEvent\"): PointerEvent;\n createEvent(eventInterface: \"PopStateEvent\"): PopStateEvent;\n createEvent(eventInterface: \"ProgressEvent\"): ProgressEvent;\n createEvent(eventInterface: \"RTCDTMFToneChangeEvent\"): RTCDTMFToneChangeEvent;\n createEvent(eventInterface: \"RTCDtlsTransportStateChangedEvent\"): RTCDtlsTransportStateChangedEvent;\n createEvent(eventInterface: \"RTCIceCandidatePairChangedEvent\"): RTCIceCandidatePairChangedEvent;\n createEvent(eventInterface: \"RTCIceGathererEvent\"): RTCIceGathererEvent;\n createEvent(eventInterface: \"RTCIceTransportStateChangedEvent\"): RTCIceTransportStateChangedEvent;\n createEvent(eventInterface: \"RTCPeerConnectionIceEvent\"): RTCPeerConnectionIceEvent;\n createEvent(eventInterface: \"RTCSsrcConflictEvent\"): RTCSsrcConflictEvent;\n createEvent(eventInterface: \"SVGZoomEvent\"): SVGZoomEvent;\n createEvent(eventInterface: \"SVGZoomEvents\"): SVGZoomEvent;\n createEvent(eventInterface: \"ScriptNotifyEvent\"): ScriptNotifyEvent;\n createEvent(eventInterface: \"ServiceWorkerMessageEvent\"): ServiceWorkerMessageEvent;\n createEvent(eventInterface: \"SpeechSynthesisEvent\"): SpeechSynthesisEvent;\n createEvent(eventInterface: \"StorageEvent\"): StorageEvent;\n createEvent(eventInterface: \"TextEvent\"): TextEvent;\n createEvent(eventInterface: \"TouchEvent\"): TouchEvent;\n createEvent(eventInterface: \"TrackEvent\"): TrackEvent;\n createEvent(eventInterface: \"TransitionEvent\"): TransitionEvent;\n createEvent(eventInterface: \"UIEvent\"): UIEvent;\n createEvent(eventInterface: \"UIEvents\"): UIEvent;\n createEvent(eventInterface: \"UnviewableContentIdentifiedEvent\"): UnviewableContentIdentifiedEvent;\n createEvent(eventInterface: \"WebGLContextEvent\"): WebGLContextEvent;\n createEvent(eventInterface: \"WheelEvent\"): WheelEvent;\n createEvent(eventInterface: string): Event;\n}\n\ninterface DOML2DeprecatedColorProperty {\n color: string;\n}\n\ninterface DOML2DeprecatedSizeProperty {\n size: number;\n}\n\ninterface ElementTraversal {\n readonly childElementCount: number;\n readonly firstElementChild: Element | null;\n readonly lastElementChild: Element | null;\n readonly nextElementSibling: Element | null;\n readonly previousElementSibling: Element | null;\n}\n\ninterface GetSVGDocument {\n getSVGDocument(): Document;\n}\n\ninterface GlobalEventHandlersEventMap {\n \"pointercancel\": PointerEvent;\n \"pointerdown\": PointerEvent;\n \"pointerenter\": PointerEvent;\n \"pointerleave\": PointerEvent;\n \"pointermove\": PointerEvent;\n \"pointerout\": PointerEvent;\n \"pointerover\": PointerEvent;\n \"pointerup\": PointerEvent;\n \"wheel\": WheelEvent;\n}\n\ninterface GlobalEventHandlers {\n onpointercancel: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerdown: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerenter: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerleave: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointermove: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerout: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerover: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onpointerup: (this: GlobalEventHandlers, ev: PointerEvent) => any;\n onwheel: (this: GlobalEventHandlers, ev: WheelEvent) => any;\n addEventListener(type: K, listener: (this: GlobalEventHandlers, ev: GlobalEventHandlersEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface GlobalFetch {\n fetch(input: RequestInfo, init?: RequestInit): Promise;\n}\n\ninterface HTMLTableAlignment {\n /**\n * Sets or retrieves a value that you can use to implement your own ch functionality for the object.\n */\n ch: string;\n /**\n * Sets or retrieves a value that you can use to implement your own chOff functionality for the object.\n */\n chOff: string;\n /**\n * Sets or retrieves how text and other content are vertically aligned within the object that contains them.\n */\n vAlign: string;\n}\n\ninterface IDBEnvironment {\n readonly indexedDB: IDBFactory;\n}\n\ninterface LinkStyle {\n readonly sheet: StyleSheet;\n}\n\ninterface MSBaseReaderEventMap {\n \"abort\": Event;\n \"error\": ErrorEvent;\n \"load\": Event;\n \"loadend\": ProgressEvent;\n \"loadstart\": Event;\n \"progress\": ProgressEvent;\n}\n\ninterface MSBaseReader {\n onabort: (this: MSBaseReader, ev: Event) => any;\n onerror: (this: MSBaseReader, ev: ErrorEvent) => any;\n onload: (this: MSBaseReader, ev: Event) => any;\n onloadend: (this: MSBaseReader, ev: ProgressEvent) => any;\n onloadstart: (this: MSBaseReader, ev: Event) => any;\n onprogress: (this: MSBaseReader, ev: ProgressEvent) => any;\n readonly readyState: number;\n readonly result: any;\n abort(): void;\n readonly DONE: number;\n readonly EMPTY: number;\n readonly LOADING: number;\n addEventListener(type: K, listener: (this: MSBaseReader, ev: MSBaseReaderEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface MSFileSaver {\n msSaveBlob(blob: any, defaultName?: string): boolean;\n msSaveOrOpenBlob(blob: any, defaultName?: string): boolean;\n}\n\ninterface MSNavigatorDoNotTrack {\n confirmSiteSpecificTrackingException(args: ConfirmSiteSpecificExceptionsInformation): boolean;\n confirmWebWideTrackingException(args: ExceptionInformation): boolean;\n removeSiteSpecificTrackingException(args: ExceptionInformation): void;\n removeWebWideTrackingException(args: ExceptionInformation): void;\n storeSiteSpecificTrackingException(args: StoreSiteSpecificExceptionsInformation): void;\n storeWebWideTrackingException(args: StoreExceptionsInformation): void;\n}\n\ninterface NavigatorBeacon {\n sendBeacon(url: USVString, data?: BodyInit): boolean;\n}\n\ninterface NavigatorConcurrentHardware {\n readonly hardwareConcurrency: number;\n}\n\ninterface NavigatorContentUtils {\n}\n\ninterface NavigatorGeolocation {\n readonly geolocation: Geolocation;\n}\n\ninterface NavigatorID {\n readonly appCodeName: string;\n readonly appName: string;\n readonly appVersion: string;\n readonly platform: string;\n readonly product: string;\n readonly productSub: string;\n readonly userAgent: string;\n readonly vendor: string;\n readonly vendorSub: string;\n}\n\ninterface NavigatorOnLine {\n readonly onLine: boolean;\n}\n\ninterface NavigatorStorageUtils {\n}\n\ninterface NavigatorUserMedia {\n readonly mediaDevices: MediaDevices;\n getUserMedia(constraints: MediaStreamConstraints, successCallback: NavigatorUserMediaSuccessCallback, errorCallback: NavigatorUserMediaErrorCallback): void;\n}\n\ninterface NodeSelector {\n querySelector(selectors: K): ElementTagNameMap[K] | null;\n querySelector(selectors: string): Element | null;\n querySelectorAll(selectors: K): ElementListTagNameMap[K];\n querySelectorAll(selectors: string): NodeListOf;\n}\n\ninterface RandomSource {\n getRandomValues(array: ArrayBufferView): ArrayBufferView;\n}\n\ninterface SVGAnimatedPoints {\n readonly animatedPoints: SVGPointList;\n readonly points: SVGPointList;\n}\n\ninterface SVGFilterPrimitiveStandardAttributes {\n readonly height: SVGAnimatedLength;\n readonly result: SVGAnimatedString;\n readonly width: SVGAnimatedLength;\n readonly x: SVGAnimatedLength;\n readonly y: SVGAnimatedLength;\n}\n\ninterface SVGFitToViewBox {\n readonly preserveAspectRatio: SVGAnimatedPreserveAspectRatio;\n readonly viewBox: SVGAnimatedRect;\n}\n\ninterface SVGTests {\n readonly requiredExtensions: SVGStringList;\n readonly requiredFeatures: SVGStringList;\n readonly systemLanguage: SVGStringList;\n hasExtension(extension: string): boolean;\n}\n\ninterface SVGURIReference {\n readonly href: SVGAnimatedString;\n}\n\ninterface WindowBase64 {\n atob(encodedString: string): string;\n btoa(rawString: string): string;\n}\n\ninterface WindowConsole {\n readonly console: Console;\n}\n\ninterface WindowLocalStorage {\n readonly localStorage: Storage;\n}\n\ninterface WindowSessionStorage {\n readonly sessionStorage: Storage;\n}\n\ninterface WindowTimers extends Object, WindowTimersExtension {\n clearInterval(handle: number): void;\n clearTimeout(handle: number): void;\n setInterval(handler: (...args: any[]) => void, timeout: number): number;\n setInterval(handler: any, timeout?: any, ...args: any[]): number;\n setTimeout(handler: (...args: any[]) => void, timeout: number): number;\n setTimeout(handler: any, timeout?: any, ...args: any[]): number;\n}\n\ninterface WindowTimersExtension {\n clearImmediate(handle: number): void;\n setImmediate(handler: (...args: any[]) => void): number;\n setImmediate(handler: any, ...args: any[]): number;\n}\n\ninterface XMLHttpRequestEventTargetEventMap {\n \"abort\": Event;\n \"error\": ErrorEvent;\n \"load\": Event;\n \"loadend\": ProgressEvent;\n \"loadstart\": Event;\n \"progress\": ProgressEvent;\n \"timeout\": ProgressEvent;\n}\n\ninterface XMLHttpRequestEventTarget {\n onabort: (this: XMLHttpRequestEventTarget, ev: Event) => any;\n onerror: (this: XMLHttpRequestEventTarget, ev: ErrorEvent) => any;\n onload: (this: XMLHttpRequestEventTarget, ev: Event) => any;\n onloadend: (this: XMLHttpRequestEventTarget, ev: ProgressEvent) => any;\n onloadstart: (this: XMLHttpRequestEventTarget, ev: Event) => any;\n onprogress: (this: XMLHttpRequestEventTarget, ev: ProgressEvent) => any;\n ontimeout: (this: XMLHttpRequestEventTarget, ev: ProgressEvent) => any;\n addEventListener(type: K, listener: (this: XMLHttpRequestEventTarget, ev: XMLHttpRequestEventTargetEventMap[K]) => any, useCapture?: boolean): void;\n addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\n}\n\ninterface ErrorEventInit {\n message?: string;\n filename?: string;\n lineno?: number;\n conlno?: number;\n error?: any;\n}\n\ninterface StorageEventInit extends EventInit {\n key?: string;\n oldValue?: string;\n newValue?: string;\n url: string;\n storageArea?: Storage;\n}\n\ninterface Canvas2DContextAttributes {\n alpha?: boolean;\n willReadFrequently?: boolean;\n storage?: boolean;\n [attribute: string]: boolean | string | undefined;\n}\n\ninterface ImageBitmapOptions {\n imageOrientation?: \"none\" | \"flipY\";\n premultiplyAlpha?: \"none\" | \"premultiply\" | \"default\";\n colorSpaceConversion?: \"none\" | \"default\";\n resizeWidth?: number;\n resizeHeight?: number;\n resizeQuality?: \"pixelated\" | \"low\" | \"medium\" | \"high\";\n}\n\ninterface ImageBitmap {\n readonly width: number;\n readonly height: number;\n close(): void;\n}\n\ninterface URLSearchParams {\n /**\n * Appends a specified key/value pair as a new search parameter.\n */\n append(name: string, value: string): void;\n /**\n * Deletes the given search parameter, and its associated value, from the list of all search parameters.\n */\n delete(name: string): void;\n /**\n * Returns the first value associated to the given search parameter.\n */\n get(name: string): string | null;\n /**\n * Returns all the values association with a given search parameter.\n */\n getAll(name: string): string[];\n /**\n * Returns a Boolean indicating if such a search parameter exists.\n */\n has(name: string): boolean;\n /**\n * Sets the value associated to a given search parameter to the given value. If there were several values, delete the others.\n */\n set(name: string, value: string): void;\n}\n\ndeclare var URLSearchParams: {\n prototype: URLSearchParams;\n /**\n * Constructor returning a URLSearchParams object.\n */\n new (init?: string | URLSearchParams): URLSearchParams;\n};\n\ninterface NodeListOf extends NodeList {\n length: number;\n item(index: number): TNode;\n [index: number]: TNode;\n}\n\ninterface HTMLCollectionOf extends HTMLCollection {\n item(index: number): T;\n namedItem(name: string): T;\n [index: number]: T;\n}\n\ninterface BlobPropertyBag {\n type?: string;\n endings?: string;\n}\n\ninterface FilePropertyBag {\n type?: string;\n lastModified?: number;\n}\n\ninterface EventListenerObject {\n handleEvent(evt: Event): void;\n}\n\ninterface ProgressEventInit extends EventInit {\n lengthComputable?: boolean;\n loaded?: number;\n total?: number;\n}\n\ninterface ScrollOptions {\n behavior?: ScrollBehavior;\n}\n\ninterface ScrollToOptions extends ScrollOptions {\n left?: number;\n top?: number;\n}\n\ninterface ScrollIntoViewOptions extends ScrollOptions {\n block?: ScrollLogicalPosition;\n inline?: ScrollLogicalPosition;\n}\n\ninterface ClipboardEventInit extends EventInit {\n data?: string;\n dataType?: string;\n}\n\ninterface IDBArrayKey extends Array {\n}\n\ninterface RsaKeyGenParams extends Algorithm {\n modulusLength: number;\n publicExponent: Uint8Array;\n}\n\ninterface RsaHashedKeyGenParams extends RsaKeyGenParams {\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaKeyAlgorithm extends KeyAlgorithm {\n modulusLength: number;\n publicExponent: Uint8Array;\n}\n\ninterface RsaHashedKeyAlgorithm extends RsaKeyAlgorithm {\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaHashedImportParams {\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaPssParams {\n saltLength: number;\n}\n\ninterface RsaOaepParams extends Algorithm {\n label?: BufferSource;\n}\n\ninterface EcdsaParams extends Algorithm {\n hash: AlgorithmIdentifier;\n}\n\ninterface EcKeyGenParams extends Algorithm {\n namedCurve: string;\n}\n\ninterface EcKeyAlgorithm extends KeyAlgorithm {\n typedCurve: string;\n}\n\ninterface EcKeyImportParams {\n namedCurve: string;\n}\n\ninterface EcdhKeyDeriveParams extends Algorithm {\n public: CryptoKey;\n}\n\ninterface AesCtrParams extends Algorithm {\n counter: BufferSource;\n length: number;\n}\n\ninterface AesKeyAlgorithm extends KeyAlgorithm {\n length: number;\n}\n\ninterface AesKeyGenParams extends Algorithm {\n length: number;\n}\n\ninterface AesDerivedKeyParams extends Algorithm {\n length: number;\n}\n\ninterface AesCbcParams extends Algorithm {\n iv: BufferSource;\n}\n\ninterface AesCmacParams extends Algorithm {\n length: number;\n}\n\ninterface AesGcmParams extends Algorithm {\n iv: BufferSource;\n additionalData?: BufferSource;\n tagLength?: number;\n}\n\ninterface AesCfbParams extends Algorithm {\n iv: BufferSource;\n}\n\ninterface HmacImportParams extends Algorithm {\n hash?: AlgorithmIdentifier;\n length?: number;\n}\n\ninterface HmacKeyAlgorithm extends KeyAlgorithm {\n hash: AlgorithmIdentifier;\n length: number;\n}\n\ninterface HmacKeyGenParams extends Algorithm {\n hash: AlgorithmIdentifier;\n length?: number;\n}\n\ninterface DhKeyGenParams extends Algorithm {\n prime: Uint8Array;\n generator: Uint8Array;\n}\n\ninterface DhKeyAlgorithm extends KeyAlgorithm {\n prime: Uint8Array;\n generator: Uint8Array;\n}\n\ninterface DhKeyDeriveParams extends Algorithm {\n public: CryptoKey;\n}\n\ninterface DhImportKeyParams extends Algorithm {\n prime: Uint8Array;\n generator: Uint8Array;\n}\n\ninterface ConcatParams extends Algorithm {\n hash?: AlgorithmIdentifier;\n algorithmId: Uint8Array;\n partyUInfo: Uint8Array;\n partyVInfo: Uint8Array;\n publicInfo?: Uint8Array;\n privateInfo?: Uint8Array;\n}\n\ninterface HkdfCtrParams extends Algorithm {\n hash: AlgorithmIdentifier;\n label: BufferSource;\n context: BufferSource;\n}\n\ninterface Pbkdf2Params extends Algorithm {\n salt: BufferSource;\n iterations: number;\n hash: AlgorithmIdentifier;\n}\n\ninterface RsaOtherPrimesInfo {\n r: string;\n d: string;\n t: string;\n}\n\ninterface JsonWebKey {\n kty: string;\n use?: string;\n key_ops?: string[];\n alg?: string;\n kid?: string;\n x5u?: string;\n x5c?: string;\n x5t?: string;\n ext?: boolean;\n crv?: string;\n x?: string;\n y?: string;\n d?: string;\n n?: string;\n e?: string;\n p?: string;\n q?: string;\n dp?: string;\n dq?: string;\n qi?: string;\n oth?: RsaOtherPrimesInfo[];\n k?: string;\n}\n\ninterface ParentNode {\n readonly children: HTMLCollection;\n readonly firstElementChild: Element | null;\n readonly lastElementChild: Element | null;\n readonly childElementCount: number;\n}\n\ninterface DocumentOrShadowRoot {\n readonly activeElement: Element | null;\n readonly stylesheets: StyleSheetList;\n getSelection(): Selection | null;\n elementFromPoint(x: number, y: number): Element | null;\n elementsFromPoint(x: number, y: number): Element[];\n}\n\ninterface ShadowRoot extends DocumentOrShadowRoot, DocumentFragment {\n readonly host: Element;\n innerHTML: string;\n}\n\ninterface ShadowRootInit {\n mode: \"open\" | \"closed\";\n delegatesFocus?: boolean;\n}\n\ninterface HTMLSlotElement extends HTMLElement {\n name: string;\n assignedNodes(options?: AssignedNodesOptions): Node[];\n}\n\ninterface AssignedNodesOptions {\n flatten?: boolean;\n}\n\ninterface ElementDefinitionOptions {\n extends: string;\n}\n\ninterface CustomElementRegistry {\n define(name: string, constructor: Function, options?: ElementDefinitionOptions): void;\n get(name: string): any;\n whenDefined(name: string): PromiseLike;\n}\n\ninterface PromiseRejectionEvent extends Event {\n readonly promise: PromiseLike;\n readonly reason: any;\n}\n\ninterface PromiseRejectionEventInit extends EventInit {\n promise: PromiseLike;\n reason?: any;\n}\n\ninterface EventListenerOptions {\n capture?: boolean;\n}\n\ninterface AddEventListenerOptions extends EventListenerOptions {\n passive?: boolean;\n once?: boolean;\n}\n\ninterface TouchEventInit extends EventModifierInit {\n touches?: Touch[];\n targetTouches?: Touch[];\n changedTouches?: Touch[];\n}\n\ndeclare type EventListenerOrEventListenerObject = EventListener | EventListenerObject;\n\ninterface DecodeErrorCallback {\n (error: DOMException): void;\n}\ninterface DecodeSuccessCallback {\n (decodedData: AudioBuffer): void;\n}\ninterface ErrorEventHandler {\n (message: string, filename?: string, lineno?: number, colno?: number, error?: Error): void;\n}\ninterface ForEachCallback {\n (keyId: any, status: MediaKeyStatus): void;\n}\ninterface FrameRequestCallback {\n (time: number): void;\n}\ninterface FunctionStringCallback {\n (data: string): void;\n}\ninterface IntersectionObserverCallback {\n (entries: IntersectionObserverEntry[], observer: IntersectionObserver): void;\n}\ninterface MediaQueryListListener {\n (mql: MediaQueryList): void;\n}\ninterface MSExecAtPriorityFunctionCallback {\n (...args: any[]): any;\n}\ninterface MSLaunchUriCallback {\n (): void;\n}\ninterface MSUnsafeFunctionCallback {\n (): any;\n}\ninterface MutationCallback {\n (mutations: MutationRecord[], observer: MutationObserver): void;\n}\ninterface NavigatorUserMediaErrorCallback {\n (error: MediaStreamError): void;\n}\ninterface NavigatorUserMediaSuccessCallback {\n (stream: MediaStream): void;\n}\ninterface NotificationPermissionCallback {\n (permission: NotificationPermission): void;\n}\ninterface PositionCallback {\n (position: Position): void;\n}\ninterface PositionErrorCallback {\n (error: PositionError): void;\n}\ninterface RTCPeerConnectionErrorCallback {\n (error: DOMError): void;\n}\ninterface RTCSessionDescriptionCallback {\n (sdp: RTCSessionDescription): void;\n}\ninterface RTCStatsCallback {\n (report: RTCStatsReport): void;\n}\ninterface VoidFunction {\n (): void;\n}\ninterface HTMLElementTagNameMap {\n \"a\": HTMLAnchorElement;\n \"applet\": HTMLAppletElement;\n \"area\": HTMLAreaElement;\n \"audio\": HTMLAudioElement;\n \"base\": HTMLBaseElement;\n \"basefont\": HTMLBaseFontElement;\n \"blockquote\": HTMLQuoteElement;\n \"body\": HTMLBodyElement;\n \"br\": HTMLBRElement;\n \"button\": HTMLButtonElement;\n \"canvas\": HTMLCanvasElement;\n \"caption\": HTMLTableCaptionElement;\n \"col\": HTMLTableColElement;\n \"colgroup\": HTMLTableColElement;\n \"data\": HTMLDataElement;\n \"datalist\": HTMLDataListElement;\n \"del\": HTMLModElement;\n \"dir\": HTMLDirectoryElement;\n \"div\": HTMLDivElement;\n \"dl\": HTMLDListElement;\n \"embed\": HTMLEmbedElement;\n \"fieldset\": HTMLFieldSetElement;\n \"font\": HTMLFontElement;\n \"form\": HTMLFormElement;\n \"frame\": HTMLFrameElement;\n \"frameset\": HTMLFrameSetElement;\n \"h1\": HTMLHeadingElement;\n \"h2\": HTMLHeadingElement;\n \"h3\": HTMLHeadingElement;\n \"h4\": HTMLHeadingElement;\n \"h5\": HTMLHeadingElement;\n \"h6\": HTMLHeadingElement;\n \"head\": HTMLHeadElement;\n \"hr\": HTMLHRElement;\n \"html\": HTMLHtmlElement;\n \"iframe\": HTMLIFrameElement;\n \"img\": HTMLImageElement;\n \"input\": HTMLInputElement;\n \"ins\": HTMLModElement;\n \"isindex\": HTMLUnknownElement;\n \"label\": HTMLLabelElement;\n \"legend\": HTMLLegendElement;\n \"li\": HTMLLIElement;\n \"link\": HTMLLinkElement;\n \"listing\": HTMLPreElement;\n \"map\": HTMLMapElement;\n \"marquee\": HTMLMarqueeElement;\n \"menu\": HTMLMenuElement;\n \"meta\": HTMLMetaElement;\n \"meter\": HTMLMeterElement;\n \"nextid\": HTMLUnknownElement;\n \"object\": HTMLObjectElement;\n \"ol\": HTMLOListElement;\n \"optgroup\": HTMLOptGroupElement;\n \"option\": HTMLOptionElement;\n \"output\": HTMLOutputElement;\n \"p\": HTMLParagraphElement;\n \"param\": HTMLParamElement;\n \"picture\": HTMLPictureElement;\n \"pre\": HTMLPreElement;\n \"progress\": HTMLProgressElement;\n \"q\": HTMLQuoteElement;\n \"script\": HTMLScriptElement;\n \"select\": HTMLSelectElement;\n \"source\": HTMLSourceElement;\n \"span\": HTMLSpanElement;\n \"style\": HTMLStyleElement;\n \"table\": HTMLTableElement;\n \"tbody\": HTMLTableSectionElement;\n \"td\": HTMLTableDataCellElement;\n \"template\": HTMLTemplateElement;\n \"textarea\": HTMLTextAreaElement;\n \"tfoot\": HTMLTableSectionElement;\n \"th\": HTMLTableHeaderCellElement;\n \"thead\": HTMLTableSectionElement;\n \"time\": HTMLTimeElement;\n \"title\": HTMLTitleElement;\n \"tr\": HTMLTableRowElement;\n \"track\": HTMLTrackElement;\n \"ul\": HTMLUListElement;\n \"video\": HTMLVideoElement;\n \"x-ms-webview\": MSHTMLWebViewElement;\n \"xmp\": HTMLPreElement;\n}\n\ninterface ElementTagNameMap extends HTMLElementTagNameMap {\n \"abbr\": HTMLElement;\n \"acronym\": HTMLElement;\n \"address\": HTMLElement;\n \"article\": HTMLElement;\n \"aside\": HTMLElement;\n \"b\": HTMLElement;\n \"bdo\": HTMLElement;\n \"big\": HTMLElement;\n \"center\": HTMLElement;\n \"circle\": SVGCircleElement;\n \"cite\": HTMLElement;\n \"clippath\": SVGClipPathElement;\n \"code\": HTMLElement;\n \"dd\": HTMLElement;\n \"defs\": SVGDefsElement;\n \"desc\": SVGDescElement;\n \"dfn\": HTMLElement;\n \"dt\": HTMLElement;\n \"ellipse\": SVGEllipseElement;\n \"em\": HTMLElement;\n \"feblend\": SVGFEBlendElement;\n \"fecolormatrix\": SVGFEColorMatrixElement;\n \"fecomponenttransfer\": SVGFEComponentTransferElement;\n \"fecomposite\": SVGFECompositeElement;\n \"feconvolvematrix\": SVGFEConvolveMatrixElement;\n \"fediffuselighting\": SVGFEDiffuseLightingElement;\n \"fedisplacementmap\": SVGFEDisplacementMapElement;\n \"fedistantlight\": SVGFEDistantLightElement;\n \"feflood\": SVGFEFloodElement;\n \"fefunca\": SVGFEFuncAElement;\n \"fefuncb\": SVGFEFuncBElement;\n \"fefuncg\": SVGFEFuncGElement;\n \"fefuncr\": SVGFEFuncRElement;\n \"fegaussianblur\": SVGFEGaussianBlurElement;\n \"feimage\": SVGFEImageElement;\n \"femerge\": SVGFEMergeElement;\n \"femergenode\": SVGFEMergeNodeElement;\n \"femorphology\": SVGFEMorphologyElement;\n \"feoffset\": SVGFEOffsetElement;\n \"fepointlight\": SVGFEPointLightElement;\n \"fespecularlighting\": SVGFESpecularLightingElement;\n \"fespotlight\": SVGFESpotLightElement;\n \"fetile\": SVGFETileElement;\n \"feturbulence\": SVGFETurbulenceElement;\n \"figcaption\": HTMLElement;\n \"figure\": HTMLElement;\n \"filter\": SVGFilterElement;\n \"footer\": HTMLElement;\n \"foreignobject\": SVGForeignObjectElement;\n \"g\": SVGGElement;\n \"header\": HTMLElement;\n \"hgroup\": HTMLElement;\n \"i\": HTMLElement;\n \"image\": SVGImageElement;\n \"kbd\": HTMLElement;\n \"keygen\": HTMLElement;\n \"line\": SVGLineElement;\n \"lineargradient\": SVGLinearGradientElement;\n \"mark\": HTMLElement;\n \"marker\": SVGMarkerElement;\n \"mask\": SVGMaskElement;\n \"metadata\": SVGMetadataElement;\n \"nav\": HTMLElement;\n \"nobr\": HTMLElement;\n \"noframes\": HTMLElement;\n \"noscript\": HTMLElement;\n \"path\": SVGPathElement;\n \"pattern\": SVGPatternElement;\n \"plaintext\": HTMLElement;\n \"polygon\": SVGPolygonElement;\n \"polyline\": SVGPolylineElement;\n \"radialgradient\": SVGRadialGradientElement;\n \"rect\": SVGRectElement;\n \"rt\": HTMLElement;\n \"ruby\": HTMLElement;\n \"s\": HTMLElement;\n \"samp\": HTMLElement;\n \"section\": HTMLElement;\n \"small\": HTMLElement;\n \"stop\": SVGStopElement;\n \"strike\": HTMLElement;\n \"strong\": HTMLElement;\n \"sub\": HTMLElement;\n \"sup\": HTMLElement;\n \"svg\": SVGSVGElement;\n \"switch\": SVGSwitchElement;\n \"symbol\": SVGSymbolElement;\n \"text\": SVGTextElement;\n \"textpath\": SVGTextPathElement;\n \"tspan\": SVGTSpanElement;\n \"tt\": HTMLElement;\n \"u\": HTMLElement;\n \"use\": SVGUseElement;\n \"var\": HTMLElement;\n \"view\": SVGViewElement;\n \"wbr\": HTMLElement;\n}\n\ntype ElementListTagNameMap = {\n [key in keyof ElementTagNameMap]: NodeListOf\n};\n\ndeclare var Audio: { new(src?: string): HTMLAudioElement; };\ndeclare var Image: { new(width?: number, height?: number): HTMLImageElement; };\ndeclare var Option: { new(text?: string, value?: string, defaultSelected?: boolean, selected?: boolean): HTMLOptionElement; };\ndeclare var applicationCache: ApplicationCache;\ndeclare var caches: CacheStorage;\ndeclare var clientInformation: Navigator;\ndeclare var closed: boolean;\ndeclare var crypto: Crypto;\ndeclare var defaultStatus: string;\ndeclare var devicePixelRatio: number;\ndeclare var document: Document;\ndeclare var doNotTrack: string;\ndeclare var event: Event | undefined;\ndeclare var external: External;\ndeclare var frameElement: Element;\ndeclare var frames: Window;\ndeclare var history: History;\ndeclare var innerHeight: number;\ndeclare var innerWidth: number;\ndeclare var isSecureContext: boolean;\ndeclare var length: number;\ndeclare var location: Location;\ndeclare var locationbar: BarProp;\ndeclare var menubar: BarProp;\ndeclare var msContentScript: ExtensionScriptApis;\ndeclare var msCredentials: MSCredentials;\ndeclare const name: never;\ndeclare var navigator: Navigator;\ndeclare var offscreenBuffering: string | boolean;\ndeclare var onabort: (this: Window, ev: UIEvent) => any;\ndeclare var onafterprint: (this: Window, ev: Event) => any;\ndeclare var onbeforeprint: (this: Window, ev: Event) => any;\ndeclare var onbeforeunload: (this: Window, ev: BeforeUnloadEvent) => any;\ndeclare var onblur: (this: Window, ev: FocusEvent) => any;\ndeclare var oncanplay: (this: Window, ev: Event) => any;\ndeclare var oncanplaythrough: (this: Window, ev: Event) => any;\ndeclare var onchange: (this: Window, ev: Event) => any;\ndeclare var onclick: (this: Window, ev: MouseEvent) => any;\ndeclare var oncompassneedscalibration: (this: Window, ev: Event) => any;\ndeclare var oncontextmenu: (this: Window, ev: PointerEvent) => any;\ndeclare var ondblclick: (this: Window, ev: MouseEvent) => any;\ndeclare var ondevicelight: (this: Window, ev: DeviceLightEvent) => any;\ndeclare var ondevicemotion: (this: Window, ev: DeviceMotionEvent) => any;\ndeclare var ondeviceorientation: (this: Window, ev: DeviceOrientationEvent) => any;\ndeclare var ondrag: (this: Window, ev: DragEvent) => any;\ndeclare var ondragend: (this: Window, ev: DragEvent) => any;\ndeclare var ondragenter: (this: Window, ev: DragEvent) => any;\ndeclare var ondragleave: (this: Window, ev: DragEvent) => any;\ndeclare var ondragover: (this: Window, ev: DragEvent) => any;\ndeclare var ondragstart: (this: Window, ev: DragEvent) => any;\ndeclare var ondrop: (this: Window, ev: DragEvent) => any;\ndeclare var ondurationchange: (this: Window, ev: Event) => any;\ndeclare var onemptied: (this: Window, ev: Event) => any;\ndeclare var onended: (this: Window, ev: MediaStreamErrorEvent) => any;\ndeclare var onerror: ErrorEventHandler;\ndeclare var onfocus: (this: Window, ev: FocusEvent) => any;\ndeclare var onhashchange: (this: Window, ev: HashChangeEvent) => any;\ndeclare var oninput: (this: Window, ev: Event) => any;\ndeclare var oninvalid: (this: Window, ev: Event) => any;\ndeclare var onkeydown: (this: Window, ev: KeyboardEvent) => any;\ndeclare var onkeypress: (this: Window, ev: KeyboardEvent) => any;\ndeclare var onkeyup: (this: Window, ev: KeyboardEvent) => any;\ndeclare var onload: (this: Window, ev: Event) => any;\ndeclare var onloadeddata: (this: Window, ev: Event) => any;\ndeclare var onloadedmetadata: (this: Window, ev: Event) => any;\ndeclare var onloadstart: (this: Window, ev: Event) => any;\ndeclare var onmessage: (this: Window, ev: MessageEvent) => any;\ndeclare var onmousedown: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseenter: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseleave: (this: Window, ev: MouseEvent) => any;\ndeclare var onmousemove: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseout: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseover: (this: Window, ev: MouseEvent) => any;\ndeclare var onmouseup: (this: Window, ev: MouseEvent) => any;\ndeclare var onmousewheel: (this: Window, ev: WheelEvent) => any;\ndeclare var onmsgesturechange: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturedoubletap: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgestureend: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturehold: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturestart: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsgesturetap: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmsinertiastart: (this: Window, ev: MSGestureEvent) => any;\ndeclare var onmspointercancel: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerdown: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerenter: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerleave: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointermove: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerout: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerover: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onmspointerup: (this: Window, ev: MSPointerEvent) => any;\ndeclare var onoffline: (this: Window, ev: Event) => any;\ndeclare var ononline: (this: Window, ev: Event) => any;\ndeclare var onorientationchange: (this: Window, ev: Event) => any;\ndeclare var onpagehide: (this: Window, ev: PageTransitionEvent) => any;\ndeclare var onpageshow: (this: Window, ev: PageTransitionEvent) => any;\ndeclare var onpause: (this: Window, ev: Event) => any;\ndeclare var onplay: (this: Window, ev: Event) => any;\ndeclare var onplaying: (this: Window, ev: Event) => any;\ndeclare var onpopstate: (this: Window, ev: PopStateEvent) => any;\ndeclare var onprogress: (this: Window, ev: ProgressEvent) => any;\ndeclare var onratechange: (this: Window, ev: Event) => any;\ndeclare var onreadystatechange: (this: Window, ev: ProgressEvent) => any;\ndeclare var onreset: (this: Window, ev: Event) => any;\ndeclare var onresize: (this: Window, ev: UIEvent) => any;\ndeclare var onscroll: (this: Window, ev: UIEvent) => any;\ndeclare var onseeked: (this: Window, ev: Event) => any;\ndeclare var onseeking: (this: Window, ev: Event) => any;\ndeclare var onselect: (this: Window, ev: UIEvent) => any;\ndeclare var onstalled: (this: Window, ev: Event) => any;\ndeclare var onstorage: (this: Window, ev: StorageEvent) => any;\ndeclare var onsubmit: (this: Window, ev: Event) => any;\ndeclare var onsuspend: (this: Window, ev: Event) => any;\ndeclare var ontimeupdate: (this: Window, ev: Event) => any;\ndeclare var ontouchcancel: (ev: TouchEvent) => any;\ndeclare var ontouchend: (ev: TouchEvent) => any;\ndeclare var ontouchmove: (ev: TouchEvent) => any;\ndeclare var ontouchstart: (ev: TouchEvent) => any;\ndeclare var onunload: (this: Window, ev: Event) => any;\ndeclare var onvolumechange: (this: Window, ev: Event) => any;\ndeclare var onwaiting: (this: Window, ev: Event) => any;\ndeclare var opener: any;\ndeclare var orientation: string | number;\ndeclare var outerHeight: number;\ndeclare var outerWidth: number;\ndeclare var pageXOffset: number;\ndeclare var pageYOffset: number;\ndeclare var parent: Window;\ndeclare var performance: Performance;\ndeclare var personalbar: BarProp;\ndeclare var screen: Screen;\ndeclare var screenLeft: number;\ndeclare var screenTop: number;\ndeclare var screenX: number;\ndeclare var screenY: number;\ndeclare var scrollbars: BarProp;\ndeclare var scrollX: number;\ndeclare var scrollY: number;\ndeclare var self: Window;\ndeclare var speechSynthesis: SpeechSynthesis;\ndeclare var status: string;\ndeclare var statusbar: BarProp;\ndeclare var styleMedia: StyleMedia;\ndeclare var toolbar: BarProp;\ndeclare var top: Window;\ndeclare var window: Window;\ndeclare var customElements: CustomElementRegistry;\ndeclare function alert(message?: any): void;\ndeclare function blur(): void;\ndeclare function cancelAnimationFrame(handle: number): void;\ndeclare function captureEvents(): void;\ndeclare function close(): void;\ndeclare function confirm(message?: string): boolean;\ndeclare function departFocus(navigationReason: NavigationReason, origin: FocusNavigationOrigin): void;\ndeclare function focus(): void;\ndeclare function getComputedStyle(elt: Element, pseudoElt?: string): CSSStyleDeclaration;\ndeclare function getMatchedCSSRules(elt: Element, pseudoElt?: string): CSSRuleList;\ndeclare function getSelection(): Selection;\ndeclare function matchMedia(mediaQuery: string): MediaQueryList;\ndeclare function moveBy(x?: number, y?: number): void;\ndeclare function moveTo(x?: number, y?: number): void;\ndeclare function msWriteProfilerMark(profilerMarkName: string): void;\ndeclare function open(url?: string, target?: string, features?: string, replace?: boolean): Window;\ndeclare function postMessage(message: any, targetOrigin: string, transfer?: any[]): void;\ndeclare function print(): void;\ndeclare function prompt(message?: string, _default?: string): string | null;\ndeclare function releaseEvents(): void;\ndeclare function requestAnimationFrame(callback: FrameRequestCallback): number;\ndeclare function resizeBy(x?: number, y?: number): void;\ndeclare function resizeTo(x?: number, y?: number): void;\ndeclare function scroll(x?: number, y?: number): void;\ndeclare function scrollBy(x?: number, y?: number): void;\ndeclare function scrollTo(x?: number, y?: number): void;\ndeclare function stop(): void;\ndeclare function webkitCancelAnimationFrame(handle: number): void;\ndeclare function webkitConvertPointFromNodeToPage(node: Node, pt: WebKitPoint): WebKitPoint;\ndeclare function webkitConvertPointFromPageToNode(node: Node, pt: WebKitPoint): WebKitPoint;\ndeclare function webkitRequestAnimationFrame(callback: FrameRequestCallback): number;\ndeclare function createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, options?: ImageBitmapOptions): Promise;\ndeclare function createImageBitmap(image: HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap | ImageData | Blob, sx: number, sy: number, sw: number, sh: number, options?: ImageBitmapOptions): Promise;\ndeclare function scroll(options?: ScrollToOptions): void;\ndeclare function scrollTo(options?: ScrollToOptions): void;\ndeclare function scrollBy(options?: ScrollToOptions): void;\ndeclare function toString(): string;\ndeclare function dispatchEvent(evt: Event): boolean;\ndeclare function removeEventListener(type: string, listener?: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;\ndeclare function clearInterval(handle: number): void;\ndeclare function clearTimeout(handle: number): void;\ndeclare function setInterval(handler: (...args: any[]) => void, timeout: number): number;\ndeclare function setInterval(handler: any, timeout?: any, ...args: any[]): number;\ndeclare function setTimeout(handler: (...args: any[]) => void, timeout: number): number;\ndeclare function setTimeout(handler: any, timeout?: any, ...args: any[]): number;\ndeclare function clearImmediate(handle: number): void;\ndeclare function setImmediate(handler: (...args: any[]) => void): number;\ndeclare function setImmediate(handler: any, ...args: any[]): number;\ndeclare var sessionStorage: Storage;\ndeclare var localStorage: Storage;\ndeclare var console: Console;\ndeclare var onpointercancel: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerdown: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerenter: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerleave: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointermove: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerout: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerover: (this: Window, ev: PointerEvent) => any;\ndeclare var onpointerup: (this: Window, ev: PointerEvent) => any;\ndeclare var onwheel: (this: Window, ev: WheelEvent) => any;\ndeclare var indexedDB: IDBFactory;\ndeclare function atob(encodedString: string): string;\ndeclare function btoa(rawString: string): string;\ndeclare function fetch(input: RequestInfo, init?: RequestInit): Promise;\ndeclare function addEventListener(type: K, listener: (this: Window, ev: WindowEventMap[K]) => any, useCapture?: boolean): void;\ndeclare function addEventListener(type: string, listener: EventListenerOrEventListenerObject, useCapture?: boolean): void;\ntype AAGUID = string;\ntype AlgorithmIdentifier = string | Algorithm;\ntype BodyInit = any;\ntype ByteString = string;\ntype ConstrainBoolean = boolean | ConstrainBooleanParameters;\ntype ConstrainDOMString = string | string[] | ConstrainDOMStringParameters;\ntype ConstrainDouble = number | ConstrainDoubleRange;\ntype ConstrainLong = number | ConstrainLongRange;\ntype CryptoOperationData = ArrayBufferView;\ntype GLbitfield = number;\ntype GLboolean = boolean;\ntype GLbyte = number;\ntype GLclampf = number;\ntype GLenum = number;\ntype GLfloat = number;\ntype GLint = number;\ntype GLintptr = number;\ntype GLshort = number;\ntype GLsizei = number;\ntype GLsizeiptr = number;\ntype GLubyte = number;\ntype GLuint = number;\ntype GLushort = number;\ntype HeadersInit = any;\ntype IDBKeyPath = string;\ntype KeyFormat = string;\ntype KeyType = string;\ntype KeyUsage = string;\ntype MSInboundPayload = MSVideoRecvPayload | MSAudioRecvPayload;\ntype MSLocalClientEvent = MSLocalClientEventBase | MSAudioLocalClientEvent;\ntype MSOutboundPayload = MSVideoSendPayload | MSAudioSendPayload;\ntype RTCIceGatherCandidate = RTCIceCandidateDictionary | RTCIceCandidateComplete;\ntype RTCTransport = RTCDtlsTransport | RTCSrtpSdesTransport;\ntype RequestInfo = Request | string;\ntype USVString = string;\ntype payloadtype = number;\ntype ScrollBehavior = \"auto\" | \"instant\" | \"smooth\";\ntype ScrollLogicalPosition = \"start\" | \"center\" | \"end\" | \"nearest\";\ntype IDBValidKey = number | string | Date | IDBArrayKey;\ntype BufferSource = ArrayBuffer | ArrayBufferView;\ntype MouseWheelEvent = WheelEvent;\ntype ScrollRestoration = \"auto\" | \"manual\";\ntype FormDataEntryValue = string | File;\ntype InsertPosition = \"beforebegin\" | \"afterbegin\" | \"beforeend\" | \"afterend\";\ntype AppendMode = \"segments\" | \"sequence\";\ntype AudioContextState = \"suspended\" | \"running\" | \"closed\";\ntype BiquadFilterType = \"lowpass\" | \"highpass\" | \"bandpass\" | \"lowshelf\" | \"highshelf\" | \"peaking\" | \"notch\" | \"allpass\";\ntype CanvasFillRule = \"nonzero\" | \"evenodd\";\ntype ChannelCountMode = \"max\" | \"clamped-max\" | \"explicit\";\ntype ChannelInterpretation = \"speakers\" | \"discrete\";\ntype DistanceModelType = \"linear\" | \"inverse\" | \"exponential\";\ntype ExpandGranularity = \"character\" | \"word\" | \"sentence\" | \"textedit\";\ntype GamepadInputEmulationType = \"mouse\" | \"keyboard\" | \"gamepad\";\ntype IDBCursorDirection = \"next\" | \"nextunique\" | \"prev\" | \"prevunique\";\ntype IDBRequestReadyState = \"pending\" | \"done\";\ntype IDBTransactionMode = \"readonly\" | \"readwrite\" | \"versionchange\";\ntype ListeningState = \"inactive\" | \"active\" | \"disambiguation\";\ntype MediaDeviceKind = \"audioinput\" | \"audiooutput\" | \"videoinput\";\ntype MediaKeyMessageType = \"license-request\" | \"license-renewal\" | \"license-release\" | \"individualization-request\";\ntype MediaKeySessionType = \"temporary\" | \"persistent-license\" | \"persistent-release-message\";\ntype MediaKeysRequirement = \"required\" | \"optional\" | \"not-allowed\";\ntype MediaKeyStatus = \"usable\" | \"expired\" | \"output-downscaled\" | \"output-not-allowed\" | \"status-pending\" | \"internal-error\";\ntype MediaStreamTrackState = \"live\" | \"ended\";\ntype MSCredentialType = \"FIDO_2_0\";\ntype MSIceAddrType = \"os\" | \"stun\" | \"turn\" | \"peer-derived\";\ntype MSIceType = \"failed\" | \"direct\" | \"relay\";\ntype MSStatsType = \"description\" | \"localclientevent\" | \"inbound-network\" | \"outbound-network\" | \"inbound-payload\" | \"outbound-payload\" | \"transportdiagnostics\";\ntype MSTransportType = \"Embedded\" | \"USB\" | \"NFC\" | \"BT\";\ntype MSWebViewPermissionState = \"unknown\" | \"defer\" | \"allow\" | \"deny\";\ntype MSWebViewPermissionType = \"geolocation\" | \"unlimitedIndexedDBQuota\" | \"media\" | \"pointerlock\" | \"webnotifications\";\ntype NavigationReason = \"up\" | \"down\" | \"left\" | \"right\";\ntype NavigationType = \"navigate\" | \"reload\" | \"back_forward\" | \"prerender\";\ntype NotificationDirection = \"auto\" | \"ltr\" | \"rtl\";\ntype NotificationPermission = \"default\" | \"denied\" | \"granted\";\ntype OscillatorType = \"sine\" | \"square\" | \"sawtooth\" | \"triangle\" | \"custom\";\ntype OverSampleType = \"none\" | \"2x\" | \"4x\";\ntype PanningModelType = \"equalpower\";\ntype PaymentComplete = \"success\" | \"fail\" | \"\";\ntype PaymentShippingType = \"shipping\" | \"delivery\" | \"pickup\";\ntype PushEncryptionKeyName = \"p256dh\" | \"auth\";\ntype PushPermissionState = \"granted\" | \"denied\" | \"prompt\";\ntype ReferrerPolicy = \"\" | \"no-referrer\" | \"no-referrer-when-downgrade\" | \"origin-only\" | \"origin-when-cross-origin\" | \"unsafe-url\";\ntype RequestCache = \"default\" | \"no-store\" | \"reload\" | \"no-cache\" | \"force-cache\";\ntype RequestCredentials = \"omit\" | \"same-origin\" | \"include\";\ntype RequestDestination = \"\" | \"document\" | \"sharedworker\" | \"subresource\" | \"unknown\" | \"worker\";\ntype RequestMode = \"navigate\" | \"same-origin\" | \"no-cors\" | \"cors\";\ntype RequestRedirect = \"follow\" | \"error\" | \"manual\";\ntype RequestType = \"\" | \"audio\" | \"font\" | \"image\" | \"script\" | \"style\" | \"track\" | \"video\";\ntype ResponseType = \"basic\" | \"cors\" | \"default\" | \"error\" | \"opaque\" | \"opaqueredirect\";\ntype RTCBundlePolicy = \"balanced\" | \"max-compat\" | \"max-bundle\";\ntype RTCDegradationPreference = \"maintain-framerate\" | \"maintain-resolution\" | \"balanced\";\ntype RTCDtlsRole = \"auto\" | \"client\" | \"server\";\ntype RTCDtlsTransportState = \"new\" | \"connecting\" | \"connected\" | \"closed\";\ntype RTCIceCandidateType = \"host\" | \"srflx\" | \"prflx\" | \"relay\";\ntype RTCIceComponent = \"RTP\" | \"RTCP\";\ntype RTCIceConnectionState = \"new\" | \"checking\" | \"connected\" | \"completed\" | \"failed\" | \"disconnected\" | \"closed\";\ntype RTCIceGathererState = \"new\" | \"gathering\" | \"complete\";\ntype RTCIceGatheringState = \"new\" | \"gathering\" | \"complete\";\ntype RTCIceGatherPolicy = \"all\" | \"nohost\" | \"relay\";\ntype RTCIceProtocol = \"udp\" | \"tcp\";\ntype RTCIceRole = \"controlling\" | \"controlled\";\ntype RTCIceTcpCandidateType = \"active\" | \"passive\" | \"so\";\ntype RTCIceTransportPolicy = \"none\" | \"relay\" | \"all\";\ntype RTCIceTransportState = \"new\" | \"checking\" | \"connected\" | \"completed\" | \"disconnected\" | \"closed\";\ntype RTCSdpType = \"offer\" | \"pranswer\" | \"answer\";\ntype RTCSignalingState = \"stable\" | \"have-local-offer\" | \"have-remote-offer\" | \"have-local-pranswer\" | \"have-remote-pranswer\" | \"closed\";\ntype RTCStatsIceCandidatePairState = \"frozen\" | \"waiting\" | \"inprogress\" | \"failed\" | \"succeeded\" | \"cancelled\";\ntype RTCStatsIceCandidateType = \"host\" | \"serverreflexive\" | \"peerreflexive\" | \"relayed\";\ntype RTCStatsType = \"inboundrtp\" | \"outboundrtp\" | \"session\" | \"datachannel\" | \"track\" | \"transport\" | \"candidatepair\" | \"localcandidate\" | \"remotecandidate\";\ntype ScopedCredentialType = \"ScopedCred\";\ntype ServiceWorkerState = \"installing\" | \"installed\" | \"activating\" | \"activated\" | \"redundant\";\ntype Transport = \"usb\" | \"nfc\" | \"ble\";\ntype VideoFacingModeEnum = \"user\" | \"environment\" | \"left\" | \"right\";\ntype VisibilityState = \"hidden\" | \"visible\" | \"prerender\" | \"unloaded\";\ntype XMLHttpRequestResponseType = \"\" | \"arraybuffer\" | \"blob\" | \"document\" | \"json\" | \"text\";\n\n\n/////////////////////////////\n/// WorkerGlobalScope APIs\n/////////////////////////////\n// These are only available in a Web Worker\ndeclare function importScripts(...urls: string[]): void;\n\n\n\n\n/////////////////////////////\n/// Windows Script Host APIS\n/////////////////////////////\n\n\ninterface ActiveXObject {\n new (s: string): any;\n}\ndeclare var ActiveXObject: ActiveXObject;\n\ninterface ITextWriter {\n Write(s: string): void;\n WriteLine(s: string): void;\n Close(): void;\n}\n\ninterface TextStreamBase {\n /**\n * The column number of the current character position in an input stream.\n */\n Column: number;\n\n /**\n * The current line number in an input stream.\n */\n Line: number;\n\n /**\n * Closes a text stream.\n * It is not necessary to close standard streams; they close automatically when the process ends. If\n * you close a standard stream, be aware that any other pointers to that standard stream become invalid.\n */\n Close(): void;\n}\n\ninterface TextStreamWriter extends TextStreamBase {\n /**\n * Sends a string to an output stream.\n */\n Write(s: string): void;\n\n /**\n * Sends a specified number of blank lines (newline characters) to an output stream.\n */\n WriteBlankLines(intLines: number): void;\n\n /**\n * Sends a string followed by a newline character to an output stream.\n */\n WriteLine(s: string): void;\n}\n\ninterface TextStreamReader extends TextStreamBase {\n /**\n * Returns a specified number of characters from an input stream, starting at the current pointer position.\n * Does not return until the ENTER key is pressed.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n */\n Read(characters: number): string;\n\n /**\n * Returns all characters from an input stream.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n */\n ReadAll(): string;\n\n /**\n * Returns an entire line from an input stream.\n * Although this method extracts the newline character, it does not add it to the returned string.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n */\n ReadLine(): string;\n\n /**\n * Skips a specified number of characters when reading from an input text stream.\n * Can only be used on a stream in reading mode; causes an error in writing or appending mode.\n * @param characters Positive number of characters to skip forward. (Backward skipping is not supported.)\n */\n Skip(characters: number): void;\n\n /**\n * Skips the next line when reading from an input text stream.\n * Can only be used on a stream in reading mode, not writing or appending mode.\n */\n SkipLine(): void;\n\n /**\n * Indicates whether the stream pointer position is at the end of a line.\n */\n AtEndOfLine: boolean;\n\n /**\n * Indicates whether the stream pointer position is at the end of a stream.\n */\n AtEndOfStream: boolean;\n}\n\ndeclare var WScript: {\n /**\n * Outputs text to either a message box (under WScript.exe) or the command console window followed by\n * a newline (under CScript.exe).\n */\n Echo(s: any): void;\n\n /**\n * Exposes the write-only error output stream for the current script.\n * Can be accessed only while using CScript.exe.\n */\n StdErr: TextStreamWriter;\n\n /**\n * Exposes the write-only output stream for the current script.\n * Can be accessed only while using CScript.exe.\n */\n StdOut: TextStreamWriter;\n Arguments: { length: number; Item(n: number): string; };\n\n /**\n * The full path of the currently running script.\n */\n ScriptFullName: string;\n\n /**\n * Forces the script to stop immediately, with an optional exit code.\n */\n Quit(exitCode?: number): number;\n\n /**\n * The Windows Script Host build version number.\n */\n BuildVersion: number;\n\n /**\n * Fully qualified path of the host executable.\n */\n FullName: string;\n\n /**\n * Gets/sets the script mode - interactive(true) or batch(false).\n */\n Interactive: boolean;\n\n /**\n * The name of the host executable (WScript.exe or CScript.exe).\n */\n Name: string;\n\n /**\n * Path of the directory containing the host executable.\n */\n Path: string;\n\n /**\n * The filename of the currently running script.\n */\n ScriptName: string;\n\n /**\n * Exposes the read-only input stream for the current script.\n * Can be accessed only while using CScript.exe.\n */\n StdIn: TextStreamReader;\n\n /**\n * Windows Script Host version\n */\n Version: string;\n\n /**\n * Connects a COM object's event sources to functions named with a given prefix, in the form prefix_event.\n */\n ConnectObject(objEventSource: any, strPrefix: string): void;\n\n /**\n * Creates a COM object.\n * @param strProgiID\n * @param strPrefix Function names in the form prefix_event will be bound to this object's COM events.\n */\n CreateObject(strProgID: string, strPrefix?: string): any;\n\n /**\n * Disconnects a COM object from its event sources.\n */\n DisconnectObject(obj: any): void;\n\n /**\n * Retrieves an existing object with the specified ProgID from memory, or creates a new one from a file.\n * @param strPathname Fully qualified path to the file containing the object persisted to disk.\n * For objects in memory, pass a zero-length string.\n * @param strProgID\n * @param strPrefix Function names in the form prefix_event will be bound to this object's COM events.\n */\n GetObject(strPathname: string, strProgID?: string, strPrefix?: string): any;\n\n /**\n * Suspends script execution for a specified length of time, then continues execution.\n * @param intTime Interval (in milliseconds) to suspend script execution.\n */\n Sleep(intTime: number): void;\n};\n\n/**\n * Allows enumerating over a COM collection, which may not have indexed item access.\n */\ninterface Enumerator {\n /**\n * Returns true if the current item is the last one in the collection, or the collection is empty,\n * or the current item is undefined.\n */\n atEnd(): boolean;\n\n /**\n * Returns the current item in the collection\n */\n item(): T;\n\n /**\n * Resets the current item in the collection to the first item. If there are no items in the collection,\n * the current item is set to undefined.\n */\n moveFirst(): void;\n\n /**\n * Moves the current item to the next item in the collection. If the enumerator is at the end of\n * the collection or the collection is empty, the current item is set to undefined.\n */\n moveNext(): void;\n}\n\ninterface EnumeratorConstructor {\n new (collection: any): Enumerator;\n new (collection: any): Enumerator;\n}\n\ndeclare var Enumerator: EnumeratorConstructor;\n\n/**\n * Enables reading from a COM safe array, which might have an alternate lower bound, or multiple dimensions.\n */\ninterface VBArray {\n /**\n * Returns the number of dimensions (1-based).\n */\n dimensions(): number;\n\n /**\n * Takes an index for each dimension in the array, and returns the item at the corresponding location.\n */\n getItem(dimension1Index: number, ...dimensionNIndexes: number[]): T;\n\n /**\n * Returns the smallest available index for a given dimension.\n * @param dimension 1-based dimension (defaults to 1)\n */\n lbound(dimension?: number): number;\n\n /**\n * Returns the largest available index for a given dimension.\n * @param dimension 1-based dimension (defaults to 1)\n */\n ubound(dimension?: number): number;\n\n /**\n * Returns a Javascript array with all the elements in the VBArray. If there are multiple dimensions,\n * each successive dimension is appended to the end of the array.\n * Example: [[1,2,3],[4,5,6]] becomes [1,2,3,4,5,6]\n */\n toArray(): T[];\n}\n\ninterface VBArrayConstructor {\n new (safeArray: any): VBArray;\n new (safeArray: any): VBArray;\n}\n\ndeclare var VBArray: VBArrayConstructor;\n\n/**\n * Automation date (VT_DATE)\n */\ninterface VarDate { }\n\ninterface DateConstructor {\n new (vd: VarDate): Date;\n}\n\ninterface Date {\n getVarDate: () => VarDate;\n}\n"}; }); diff --git a/lib/typescriptServices.d.ts b/lib/typescriptServices.d.ts index aae14b4c..60a3cf23 100644 --- a/lib/typescriptServices.d.ts +++ b/lib/typescriptServices.d.ts @@ -1,18 +1,18 @@ -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */ - +/*! ***************************************************************************** +Copyright (c) Microsoft Corporation. All rights reserved. +Licensed under the Apache License, Version 2.0 (the "License"); you may not use +this file except in compliance with the License. You may obtain a copy of the +License at http://www.apache.org/licenses/LICENSE-2.0 + +THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED +WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, +MERCHANTABLITY OR NON-INFRINGEMENT. + +See the Apache Version 2.0 License for specific language governing permissions +and limitations under the License. +***************************************************************************** */ + declare namespace ts { /** * Type of objects whose values are all of the same type. @@ -348,20 +348,22 @@ declare namespace ts { JSDocComment = 283, JSDocTag = 284, JSDocAugmentsTag = 285, - JSDocParameterTag = 286, - JSDocReturnTag = 287, - JSDocTypeTag = 288, - JSDocTemplateTag = 289, - JSDocTypedefTag = 290, - JSDocPropertyTag = 291, - JSDocTypeLiteral = 292, - JSDocLiteralType = 293, - SyntaxList = 294, - NotEmittedStatement = 295, - PartiallyEmittedExpression = 296, - MergeDeclarationMarker = 297, - EndOfDeclarationMarker = 298, - Count = 299, + JSDocClassTag = 286, + JSDocParameterTag = 287, + JSDocReturnTag = 288, + JSDocTypeTag = 289, + JSDocTemplateTag = 290, + JSDocTypedefTag = 291, + JSDocPropertyTag = 292, + JSDocTypeLiteral = 293, + JSDocLiteralType = 294, + SyntaxList = 295, + NotEmittedStatement = 296, + PartiallyEmittedExpression = 297, + CommaListExpression = 298, + MergeDeclarationMarker = 299, + EndOfDeclarationMarker = 300, + Count = 301, FirstAssignment = 58, LastAssignment = 70, FirstCompoundAssignment = 59, @@ -388,9 +390,9 @@ declare namespace ts { LastBinaryOperator = 70, FirstNode = 143, FirstJSDocNode = 267, - LastJSDocNode = 293, - FirstJSDocTagNode = 283, - LastJSDocTagNode = 293, + LastJSDocNode = 294, + FirstJSDocTagNode = 284, + LastJSDocTagNode = 294, } enum NodeFlags { None = 0, @@ -474,6 +476,10 @@ declare namespace ts { type ModifiersArray = NodeArray; interface Identifier extends PrimaryExpression { kind: SyntaxKind.Identifier; + /** + * Text of identifier (with escapes converted to characters). + * If the identifier begins with two underscores, this will begin with three. + */ text: string; originalKeywordKind?: SyntaxKind; isInJSDocNamespace?: boolean; @@ -491,7 +497,6 @@ declare namespace ts { type DeclarationName = Identifier | StringLiteral | NumericLiteral | ComputedPropertyName | BindingPattern; interface Declaration extends Node { _declarationBrand: any; - name?: DeclarationName; } interface NamedDeclaration extends Declaration { name?: DeclarationName; @@ -687,6 +692,7 @@ declare namespace ts { interface ConstructorTypeNode extends TypeNode, SignatureDeclaration { kind: SyntaxKind.ConstructorType; } + type TypeReferenceType = TypeReferenceNode | ExpressionWithTypeArguments | JSDocTypeReference; interface TypeReferenceNode extends TypeNode { kind: SyntaxKind.TypeReference; typeName: EntityName; @@ -764,22 +770,24 @@ declare namespace ts { interface UnaryExpression extends Expression { _unaryExpressionBrand: any; } - interface IncrementExpression extends UnaryExpression { - _incrementExpressionBrand: any; + /** Deprecated, please use UpdateExpression */ + type IncrementExpression = UpdateExpression; + interface UpdateExpression extends UnaryExpression { + _updateExpressionBrand: any; } type PrefixUnaryOperator = SyntaxKind.PlusPlusToken | SyntaxKind.MinusMinusToken | SyntaxKind.PlusToken | SyntaxKind.MinusToken | SyntaxKind.TildeToken | SyntaxKind.ExclamationToken; - interface PrefixUnaryExpression extends IncrementExpression { + interface PrefixUnaryExpression extends UpdateExpression { kind: SyntaxKind.PrefixUnaryExpression; operator: PrefixUnaryOperator; operand: UnaryExpression; } type PostfixUnaryOperator = SyntaxKind.PlusPlusToken | SyntaxKind.MinusMinusToken; - interface PostfixUnaryExpression extends IncrementExpression { + interface PostfixUnaryExpression extends UpdateExpression { kind: SyntaxKind.PostfixUnaryExpression; operand: LeftHandSideExpression; operator: PostfixUnaryOperator; } - interface LeftHandSideExpression extends IncrementExpression { + interface LeftHandSideExpression extends UpdateExpression { _leftHandSideExpressionBrand: any; } interface MemberExpression extends LeftHandSideExpression { @@ -800,6 +808,9 @@ declare namespace ts { interface SuperExpression extends PrimaryExpression { kind: SyntaxKind.SuperKeyword; } + interface ImportExpression extends PrimaryExpression { + kind: SyntaxKind.ImportKeyword; + } interface DeleteExpression extends UnaryExpression { kind: SyntaxKind.DeleteExpression; expression: UnaryExpression; @@ -984,6 +995,9 @@ declare namespace ts { interface SuperCall extends CallExpression { expression: SuperExpression; } + interface ImportCall extends CallExpression { + expression: ImportExpression; + } interface ExpressionWithTypeArguments extends TypeNode { kind: SyntaxKind.ExpressionWithTypeArguments; parent?: HeritageClause; @@ -1019,7 +1033,7 @@ declare namespace ts { } interface MetaProperty extends PrimaryExpression { kind: SyntaxKind.MetaProperty; - keywordToken: SyntaxKind; + keywordToken: SyntaxKind.NewKeyword; name: Identifier; } interface JsxElement extends PrimaryExpression { @@ -1079,6 +1093,13 @@ declare namespace ts { interface NotEmittedStatement extends Statement { kind: SyntaxKind.NotEmittedStatement; } + /** + * A list of comma-seperated expressions. This node is only created by transformations. + */ + interface CommaListExpression extends Expression { + kind: SyntaxKind.CommaListExpression; + elements: NodeArray; + } interface EmptyStatement extends Statement { kind: SyntaxKind.EmptyStatement; } @@ -1126,6 +1147,7 @@ declare namespace ts { condition?: Expression; incrementor?: Expression; } + type ForInOrOfStatement = ForInStatement | ForOfStatement; interface ForInStatement extends IterationStatement { kind: SyntaxKind.ForInStatement; initializer: ForInitializer; @@ -1199,7 +1221,7 @@ declare namespace ts { variableDeclaration: VariableDeclaration; block: Block; } - type DeclarationWithTypeParameters = SignatureDeclaration | ClassLikeDeclaration | InterfaceDeclaration | TypeAliasDeclaration; + type DeclarationWithTypeParameters = SignatureDeclaration | ClassLikeDeclaration | InterfaceDeclaration | TypeAliasDeclaration | JSDocTemplateTag; interface ClassLikeDeclaration extends NamedDeclaration { name?: Identifier; typeParameters?: NodeArray; @@ -1447,6 +1469,7 @@ declare namespace ts { comment: string | undefined; } interface JSDocTag extends Node { + parent: JSDoc; atToken: AtToken; tagName: Identifier; comment: string | undefined; @@ -1458,6 +1481,9 @@ declare namespace ts { kind: SyntaxKind.JSDocAugmentsTag; typeExpression: JSDocTypeExpression; } + interface JSDocClassTag extends JSDocTag { + kind: SyntaxKind.JSDocClassTag; + } interface JSDocTemplateTag extends JSDocTag { kind: SyntaxKind.JSDocTemplateTag; typeParameters: NodeArray; @@ -1471,6 +1497,7 @@ declare namespace ts { typeExpression: JSDocTypeExpression; } interface JSDocTypedefTag extends JSDocTag, NamedDeclaration { + parent: JSDoc; kind: SyntaxKind.JSDocTypedefTag; fullName?: JSDocNamespaceDeclaration | Identifier; name?: Identifier; @@ -1478,9 +1505,15 @@ declare namespace ts { jsDocTypeLiteral?: JSDocTypeLiteral; } interface JSDocPropertyTag extends JSDocTag, TypeElement { + parent: JSDoc; kind: SyntaxKind.JSDocPropertyTag; name: Identifier; + /** the parameter name, if provided *before* the type (TypeScript-style) */ + preParameterName?: Identifier; + /** the parameter name, if provided *after* the type (JSDoc-standard) */ + postParameterName?: Identifier; typeExpression: JSDocTypeExpression; + isBracketed: boolean; } interface JSDocTypeLiteral extends JSDocType { kind: SyntaxKind.JSDocTypeLiteral; @@ -1495,7 +1528,7 @@ declare namespace ts { /** the parameter name, if provided *after* the type (JSDoc-standard) */ postParameterName?: Identifier; /** the parameter name, regardless of the location it was provided */ - parameterName: Identifier; + name: Identifier; isBracketed: boolean; } enum FlowFlags { @@ -1693,10 +1726,10 @@ declare namespace ts { getTypeOfSymbolAtLocation(symbol: Symbol, node: Node): Type; getDeclaredTypeOfSymbol(symbol: Symbol): Type; getPropertiesOfType(type: Type): Symbol[]; - getPropertyOfType(type: Type, propertyName: string): Symbol; - getIndexInfoOfType(type: Type, kind: IndexKind): IndexInfo; + getPropertyOfType(type: Type, propertyName: string): Symbol | undefined; + getIndexInfoOfType(type: Type, kind: IndexKind): IndexInfo | undefined; getSignaturesOfType(type: Type, kind: SignatureKind): Signature[]; - getIndexTypeOfType(type: Type, kind: IndexKind): Type; + getIndexTypeOfType(type: Type, kind: IndexKind): Type | undefined; getBaseTypes(type: InterfaceType): BaseType[]; getBaseTypeOfLiteralType(type: Type): Type; getWidenedType(type: Type): Type; @@ -1709,11 +1742,11 @@ declare namespace ts { /** Note that the resulting nodes cannot be checked. */ indexInfoToIndexSignatureDeclaration(indexInfo: IndexInfo, kind: IndexKind, enclosingDeclaration?: Node, flags?: NodeBuilderFlags): IndexSignatureDeclaration; getSymbolsInScope(location: Node, meaning: SymbolFlags): Symbol[]; - getSymbolAtLocation(node: Node): Symbol; + getSymbolAtLocation(node: Node): Symbol | undefined; getSymbolsOfParameterPropertyDeclaration(parameter: ParameterDeclaration, parameterName: string): Symbol[]; - getShorthandAssignmentValueSymbol(location: Node): Symbol; - getExportSpecifierLocalTargetSymbol(location: ExportSpecifier): Symbol; - getPropertySymbolOfDestructuringAssignment(location: Identifier): Symbol; + getShorthandAssignmentValueSymbol(location: Node): Symbol | undefined; + getExportSpecifierLocalTargetSymbol(location: ExportSpecifier): Symbol | undefined; + getPropertySymbolOfDestructuringAssignment(location: Identifier): Symbol | undefined; getTypeAtLocation(node: Node): Type; getTypeFromTypeNode(node: TypeNode): Type; signatureToString(signature: Signature, enclosingDeclaration?: Node, flags?: TypeFormatFlags, kind?: SignatureKind): string; @@ -1723,38 +1756,48 @@ declare namespace ts { getFullyQualifiedName(symbol: Symbol): string; getAugmentedPropertiesOfType(type: Type): Symbol[]; getRootSymbols(symbol: Symbol): Symbol[]; - getContextualType(node: Expression): Type; - getResolvedSignature(node: CallLikeExpression, candidatesOutArray?: Signature[]): Signature; - getSignatureFromDeclaration(declaration: SignatureDeclaration): Signature; - isImplementationOfOverload(node: FunctionLikeDeclaration): boolean; + getContextualType(node: Expression): Type | undefined; + getResolvedSignature(node: CallLikeExpression, candidatesOutArray?: Signature[]): Signature | undefined; + getSignatureFromDeclaration(declaration: SignatureDeclaration): Signature | undefined; + isImplementationOfOverload(node: FunctionLikeDeclaration): boolean | undefined; isUndefinedSymbol(symbol: Symbol): boolean; isArgumentsSymbol(symbol: Symbol): boolean; isUnknownSymbol(symbol: Symbol): boolean; - getConstantValue(node: EnumMember | PropertyAccessExpression | ElementAccessExpression): number; + getConstantValue(node: EnumMember | PropertyAccessExpression | ElementAccessExpression): string | number | undefined; isValidPropertyAccess(node: PropertyAccessExpression | QualifiedName, propertyName: string): boolean; /** Follow all aliases to get the original symbol. */ getAliasedSymbol(symbol: Symbol): Symbol; getExportsOfModule(moduleSymbol: Symbol): Symbol[]; - getAllAttributesTypeFromJsxOpeningLikeElement(elementNode: JsxOpeningLikeElement): Type; + getAllAttributesTypeFromJsxOpeningLikeElement(elementNode: JsxOpeningLikeElement): Type | undefined; getJsxIntrinsicTagNames(): Symbol[]; isOptionalParameter(node: ParameterDeclaration): boolean; getAmbientModules(): Symbol[]; tryGetMemberInModuleExports(memberName: string, moduleSymbol: Symbol): Symbol | undefined; getApparentType(type: Type): Type; + getSuggestionForNonexistentProperty(node: Identifier, containingType: Type): string | undefined; + getSuggestionForNonexistentSymbol(location: Node, name: string, meaning: SymbolFlags): string | undefined; } enum NodeBuilderFlags { None = 0, - allowThisInObjectLiteral = 1, - allowQualifedNameInPlaceOfIdentifier = 2, - allowTypeParameterInQualifiedName = 4, - allowAnonymousIdentifier = 8, - allowEmptyUnionOrIntersection = 16, - allowEmptyTuple = 32, + NoTruncation = 1, + WriteArrayAsGenericType = 2, + WriteTypeArgumentsOfSignature = 32, + UseFullyQualifiedType = 64, + SuppressAnyReturnType = 256, + WriteTypeParametersInQualifiedName = 512, + AllowThisInObjectLiteral = 1024, + AllowQualifedNameInPlaceOfIdentifier = 2048, + AllowAnonymousIdentifier = 8192, + AllowEmptyUnionOrIntersection = 16384, + AllowEmptyTuple = 32768, + IgnoreErrors = 60416, + InObjectTypeLiteral = 1048576, + InTypeAlias = 8388608, } interface SymbolDisplayBuilder { buildTypeDisplay(type: Type, writer: SymbolWriter, enclosingDeclaration?: Node, flags?: TypeFormatFlags): void; buildSymbolDisplay(symbol: Symbol, writer: SymbolWriter, enclosingDeclaration?: Node, meaning?: SymbolFlags, flags?: SymbolFormatFlags): void; - buildSignatureDisplay(signatures: Signature, writer: SymbolWriter, enclosingDeclaration?: Node, flags?: TypeFormatFlags, kind?: SignatureKind): void; + buildSignatureDisplay(signature: Signature, writer: SymbolWriter, enclosingDeclaration?: Node, flags?: TypeFormatFlags, kind?: SignatureKind): void; buildIndexSignatureDisplay(info: IndexInfo, writer: SymbolWriter, kind: IndexKind, enclosingDeclaration?: Node, globalFlags?: TypeFormatFlags, symbolStack?: Symbol[]): void; buildParameterDisplay(parameter: Symbol, writer: SymbolWriter, enclosingDeclaration?: Node, flags?: TypeFormatFlags): void; buildTypeParameterDisplay(tp: TypeParameter, writer: SymbolWriter, enclosingDeclaration?: Node, flags?: TypeFormatFlags): void; @@ -1779,23 +1822,24 @@ declare namespace ts { clear(): void; trackSymbol(symbol: Symbol, enclosingDeclaration?: Node, meaning?: SymbolFlags): void; reportInaccessibleThisError(): void; - reportIllegalExtends(): void; + reportPrivateInBaseOfClassExpression(propertyName: string): void; } enum TypeFormatFlags { None = 0, WriteArrayAsGenericType = 1, - UseTypeOfFunction = 2, - NoTruncation = 4, - WriteArrowStyleSignature = 8, - WriteOwnNameForAnyLike = 16, - WriteTypeArgumentsOfSignature = 32, - InElementType = 64, - UseFullyQualifiedType = 128, - InFirstTypeArgument = 256, - InTypeAlias = 512, - UseTypeAliasValue = 1024, - SuppressAnyReturnType = 2048, - AddUndefined = 4096, + UseTypeOfFunction = 4, + NoTruncation = 8, + WriteArrowStyleSignature = 16, + WriteOwnNameForAnyLike = 32, + WriteTypeArgumentsOfSignature = 64, + InElementType = 128, + UseFullyQualifiedType = 256, + InFirstTypeArgument = 512, + InTypeAlias = 1024, + UseTypeAliasValue = 2048, + SuppressAnyReturnType = 4096, + AddUndefined = 8192, + WriteClassExpressionAsTypeLiteral = 16384, } enum SymbolFormatFlags { None = 0, @@ -1915,18 +1959,18 @@ declare namespace ts { Index = 262144, IndexedAccess = 524288, NonPrimitive = 16777216, - Literal = 480, + Literal = 224, StringOrNumberLiteral = 96, PossiblyFalsy = 7406, StringLike = 262178, - NumberLike = 340, + NumberLike = 84, BooleanLike = 136, EnumLike = 272, UnionOrIntersection = 196608, StructuredType = 229376, StructuredOrTypeVariable = 1032192, TypeVariable = 540672, - Narrowable = 17810431, + Narrowable = 17810175, NotUnionOrUnit = 16810497, } type DestructuringPattern = BindingPattern | ObjectLiteralExpression | ArrayLiteralExpression; @@ -1938,15 +1982,17 @@ declare namespace ts { aliasTypeArguments?: Type[]; } interface LiteralType extends Type { - text: string; + value: string | number; freshType?: LiteralType; regularType?: LiteralType; } - interface EnumType extends Type { - memberTypes: EnumLiteralType[]; + interface StringLiteralType extends LiteralType { + value: string; } - interface EnumLiteralType extends LiteralType { - baseType: EnumType & UnionType; + interface NumberLiteralType extends LiteralType { + value: number; + } + interface EnumType extends Type { } enum ObjectFlags { Class = 1, @@ -1991,7 +2037,7 @@ declare namespace ts { */ interface TypeReference extends ObjectType { target: GenericType; - typeArguments: Type[]; + typeArguments?: Type[]; } interface GenericType extends InterfaceType, TypeReference { } @@ -2027,7 +2073,7 @@ declare namespace ts { } interface Signature { declaration: SignatureDeclaration; - typeParameters: TypeParameter[]; + typeParameters?: TypeParameter[]; parameters: Symbol[]; } enum IndexKind { @@ -2039,6 +2085,24 @@ declare namespace ts { isReadonly: boolean; declaration?: SignatureDeclaration; } + enum InferencePriority { + NakedTypeVariable = 1, + MappedType = 2, + ReturnType = 4, + } + interface InferenceInfo { + typeParameter: TypeParameter; + candidates: Type[]; + inferredType: Type; + priority: InferencePriority; + topLevel: boolean; + isFixed: boolean; + } + enum InferenceFlags { + InferUnionTypes = 1, + NoDefault = 2, + AnyDefault = 4, + } interface JsFileExtensionInfo { extension: string; isMixedContent: boolean; @@ -2062,9 +2126,9 @@ declare namespace ts { next?: DiagnosticMessageChain; } interface Diagnostic { - file: SourceFile; - start: number; - length: number; + file: SourceFile | undefined; + start: number | undefined; + length: number | undefined; messageText: string | DiagnosticMessageChain; category: DiagnosticCategory; code: number; @@ -2120,6 +2184,7 @@ declare namespace ts { noImplicitAny?: boolean; noImplicitReturns?: boolean; noImplicitThis?: boolean; + noStrictGenericChecks?: boolean; noUnusedLocals?: boolean; noUnusedParameters?: boolean; noImplicitUseStrict?: boolean; @@ -2174,6 +2239,7 @@ declare namespace ts { UMD = 3, System = 4, ES2015 = 5, + ESNext = 6, } enum JsxEmit { None = 0, @@ -2304,6 +2370,14 @@ declare namespace ts { resolveTypeReferenceDirectives?(typeReferenceDirectiveNames: string[], containingFile: string): ResolvedTypeReferenceDirective[]; getEnvironmentVariable?(name: string): string; } + interface SourceMapRange extends TextRange { + source?: SourceMapSource; + } + interface SourceMapSource { + fileName: string; + text: string; + skipTrivia?: (pos: number) => number; + } enum EmitFlags { SingleLine = 1, AdviseOnEmitNode = 2, @@ -2332,6 +2406,7 @@ declare namespace ts { NoHoisting = 2097152, HasEndOfDeclarationMarker = 4194304, Iterator = 8388608, + NoAsciiEscaping = 16777216, } interface EmitHelper { readonly name: string; @@ -2519,7 +2594,7 @@ declare namespace ts { } declare namespace ts { /** The version of the TypeScript compiler release */ - const version = "2.3.4"; + const version = "2.4.1"; } declare function setTimeout(handler: (...args: any[]) => void, timeout: number): any; declare function clearTimeout(handle: any): void; @@ -2554,6 +2629,10 @@ declare namespace ts { getDirectories(path: string): string[]; readDirectory(path: string, extensions?: string[], exclude?: string[], include?: string[]): string[]; getModifiedTime?(path: string): Date; + /** + * This should be cryptographically secure. + * A good implementation is node.js' `crypto.createHash`. (https://nodejs.org/api/crypto.html#crypto_crypto_createhash_algorithm) + */ createHash?(data: string): string; getMemoryUsage?(): number; exit(exitCode?: number): void; @@ -2606,22 +2685,22 @@ declare namespace ts { scanRange(start: number, length: number, callback: () => T): T; tryScan(callback: () => T): T; } - function tokenToString(t: SyntaxKind): string; + function tokenToString(t: SyntaxKind): string | undefined; function getPositionOfLineAndCharacter(sourceFile: SourceFile, line: number, character: number): number; - function getLineAndCharacterOfPosition(sourceFile: SourceFile, position: number): LineAndCharacter; + function getLineAndCharacterOfPosition(sourceFile: SourceFileLike, position: number): LineAndCharacter; function isWhiteSpaceLike(ch: number): boolean; /** Does not include line breaks. For that, see isWhiteSpaceLike. */ function isWhiteSpaceSingleLine(ch: number): boolean; function isLineBreak(ch: number): boolean; function couldStartTrivia(text: string, pos: number): boolean; - function forEachLeadingCommentRange(text: string, pos: number, cb: (pos: number, end: number, kind: CommentKind, hasTrailingNewLine: boolean, state: T) => U, state?: T): U; - function forEachTrailingCommentRange(text: string, pos: number, cb: (pos: number, end: number, kind: CommentKind, hasTrailingNewLine: boolean, state: T) => U, state?: T): U; + function forEachLeadingCommentRange(text: string, pos: number, cb: (pos: number, end: number, kind: CommentKind, hasTrailingNewLine: boolean, state: T) => U, state?: T): U | undefined; + function forEachTrailingCommentRange(text: string, pos: number, cb: (pos: number, end: number, kind: CommentKind, hasTrailingNewLine: boolean, state: T) => U, state?: T): U | undefined; function reduceEachLeadingCommentRange(text: string, pos: number, cb: (pos: number, end: number, kind: CommentKind, hasTrailingNewLine: boolean, state: T, memo: U) => U, state: T, initial: U): U; function reduceEachTrailingCommentRange(text: string, pos: number, cb: (pos: number, end: number, kind: CommentKind, hasTrailingNewLine: boolean, state: T, memo: U) => U, state: T, initial: U): U; function getLeadingCommentRanges(text: string, pos: number): CommentRange[] | undefined; function getTrailingCommentRanges(text: string, pos: number): CommentRange[] | undefined; /** Optionally, get the shebang */ - function getShebang(text: string): string; + function getShebang(text: string): string | undefined; function isIdentifierStart(ch: number, languageVersion: ScriptTarget): boolean; function isIdentifierPart(ch: number, languageVersion: ScriptTarget): boolean; function createScanner(languageVersion: ScriptTarget, skipTrivia: boolean, languageVariant?: LanguageVariant, text?: string, onError?: ErrorCallback, start?: number, length?: number): Scanner; @@ -2698,6 +2777,204 @@ declare namespace ts { * @returns The unescaped identifier text. */ function unescapeIdentifier(identifier: string): string; + function getNameOfDeclaration(declaration: Declaration): DeclarationName | undefined; +} +declare namespace ts { + function isNumericLiteral(node: Node): node is NumericLiteral; + function isStringLiteral(node: Node): node is StringLiteral; + function isJsxText(node: Node): node is JsxText; + function isRegularExpressionLiteral(node: Node): node is RegularExpressionLiteral; + function isNoSubstitutionTemplateLiteral(node: Node): node is LiteralExpression; + function isTemplateHead(node: Node): node is TemplateHead; + function isTemplateMiddle(node: Node): node is TemplateMiddle; + function isTemplateTail(node: Node): node is TemplateTail; + function isIdentifier(node: Node): node is Identifier; + function isQualifiedName(node: Node): node is QualifiedName; + function isComputedPropertyName(node: Node): node is ComputedPropertyName; + function isTypeParameterDeclaration(node: Node): node is TypeParameterDeclaration; + function isParameter(node: Node): node is ParameterDeclaration; + function isDecorator(node: Node): node is Decorator; + function isPropertySignature(node: Node): node is PropertySignature; + function isPropertyDeclaration(node: Node): node is PropertyDeclaration; + function isMethodSignature(node: Node): node is MethodSignature; + function isMethodDeclaration(node: Node): node is MethodDeclaration; + function isConstructorDeclaration(node: Node): node is ConstructorDeclaration; + function isGetAccessorDeclaration(node: Node): node is GetAccessorDeclaration; + function isSetAccessorDeclaration(node: Node): node is SetAccessorDeclaration; + function isCallSignatureDeclaration(node: Node): node is CallSignatureDeclaration; + function isConstructSignatureDeclaration(node: Node): node is ConstructSignatureDeclaration; + function isIndexSignatureDeclaration(node: Node): node is IndexSignatureDeclaration; + function isTypePredicateNode(node: Node): node is TypePredicateNode; + function isTypeReferenceNode(node: Node): node is TypeReferenceNode; + function isFunctionTypeNode(node: Node): node is FunctionTypeNode; + function isConstructorTypeNode(node: Node): node is ConstructorTypeNode; + function isTypeQueryNode(node: Node): node is TypeQueryNode; + function isTypeLiteralNode(node: Node): node is TypeLiteralNode; + function isArrayTypeNode(node: Node): node is ArrayTypeNode; + function isTupleTypeNode(node: Node): node is TupleTypeNode; + function isUnionTypeNode(node: Node): node is UnionTypeNode; + function isIntersectionTypeNode(node: Node): node is IntersectionTypeNode; + function isParenthesizedTypeNode(node: Node): node is ParenthesizedTypeNode; + function isThisTypeNode(node: Node): node is ThisTypeNode; + function isTypeOperatorNode(node: Node): node is TypeOperatorNode; + function isIndexedAccessTypeNode(node: Node): node is IndexedAccessTypeNode; + function isMappedTypeNode(node: Node): node is MappedTypeNode; + function isLiteralTypeNode(node: Node): node is LiteralTypeNode; + function isObjectBindingPattern(node: Node): node is ObjectBindingPattern; + function isArrayBindingPattern(node: Node): node is ArrayBindingPattern; + function isBindingElement(node: Node): node is BindingElement; + function isArrayLiteralExpression(node: Node): node is ArrayLiteralExpression; + function isObjectLiteralExpression(node: Node): node is ObjectLiteralExpression; + function isPropertyAccessExpression(node: Node): node is PropertyAccessExpression; + function isElementAccessExpression(node: Node): node is ElementAccessExpression; + function isCallExpression(node: Node): node is CallExpression; + function isNewExpression(node: Node): node is NewExpression; + function isTaggedTemplateExpression(node: Node): node is TaggedTemplateExpression; + function isTypeAssertion(node: Node): node is TypeAssertion; + function isParenthesizedExpression(node: Node): node is ParenthesizedExpression; + function isFunctionExpression(node: Node): node is FunctionExpression; + function isArrowFunction(node: Node): node is ArrowFunction; + function isDeleteExpression(node: Node): node is DeleteExpression; + function isTypeOfExpression(node: Node): node is TypeOfExpression; + function isVoidExpression(node: Node): node is VoidExpression; + function isAwaitExpression(node: Node): node is AwaitExpression; + function isPrefixUnaryExpression(node: Node): node is PrefixUnaryExpression; + function isPostfixUnaryExpression(node: Node): node is PostfixUnaryExpression; + function isBinaryExpression(node: Node): node is BinaryExpression; + function isConditionalExpression(node: Node): node is ConditionalExpression; + function isTemplateExpression(node: Node): node is TemplateExpression; + function isYieldExpression(node: Node): node is YieldExpression; + function isSpreadElement(node: Node): node is SpreadElement; + function isClassExpression(node: Node): node is ClassExpression; + function isOmittedExpression(node: Node): node is OmittedExpression; + function isExpressionWithTypeArguments(node: Node): node is ExpressionWithTypeArguments; + function isAsExpression(node: Node): node is AsExpression; + function isNonNullExpression(node: Node): node is NonNullExpression; + function isMetaProperty(node: Node): node is MetaProperty; + function isTemplateSpan(node: Node): node is TemplateSpan; + function isSemicolonClassElement(node: Node): node is SemicolonClassElement; + function isBlock(node: Node): node is Block; + function isVariableStatement(node: Node): node is VariableStatement; + function isEmptyStatement(node: Node): node is EmptyStatement; + function isExpressionStatement(node: Node): node is ExpressionStatement; + function isIfStatement(node: Node): node is IfStatement; + function isDoStatement(node: Node): node is DoStatement; + function isWhileStatement(node: Node): node is WhileStatement; + function isForStatement(node: Node): node is ForStatement; + function isForInStatement(node: Node): node is ForInStatement; + function isForOfStatement(node: Node): node is ForOfStatement; + function isContinueStatement(node: Node): node is ContinueStatement; + function isBreakStatement(node: Node): node is BreakStatement; + function isReturnStatement(node: Node): node is ReturnStatement; + function isWithStatement(node: Node): node is WithStatement; + function isSwitchStatement(node: Node): node is SwitchStatement; + function isLabeledStatement(node: Node): node is LabeledStatement; + function isThrowStatement(node: Node): node is ThrowStatement; + function isTryStatement(node: Node): node is TryStatement; + function isDebuggerStatement(node: Node): node is DebuggerStatement; + function isVariableDeclaration(node: Node): node is VariableDeclaration; + function isVariableDeclarationList(node: Node): node is VariableDeclarationList; + function isFunctionDeclaration(node: Node): node is FunctionDeclaration; + function isClassDeclaration(node: Node): node is ClassDeclaration; + function isInterfaceDeclaration(node: Node): node is InterfaceDeclaration; + function isTypeAliasDeclaration(node: Node): node is TypeAliasDeclaration; + function isEnumDeclaration(node: Node): node is EnumDeclaration; + function isModuleDeclaration(node: Node): node is ModuleDeclaration; + function isModuleBlock(node: Node): node is ModuleBlock; + function isCaseBlock(node: Node): node is CaseBlock; + function isNamespaceExportDeclaration(node: Node): node is NamespaceExportDeclaration; + function isImportEqualsDeclaration(node: Node): node is ImportEqualsDeclaration; + function isImportDeclaration(node: Node): node is ImportDeclaration; + function isImportClause(node: Node): node is ImportClause; + function isNamespaceImport(node: Node): node is NamespaceImport; + function isNamedImports(node: Node): node is NamedImports; + function isImportSpecifier(node: Node): node is ImportSpecifier; + function isExportAssignment(node: Node): node is ExportAssignment; + function isExportDeclaration(node: Node): node is ExportDeclaration; + function isNamedExports(node: Node): node is NamedExports; + function isExportSpecifier(node: Node): node is ExportSpecifier; + function isMissingDeclaration(node: Node): node is MissingDeclaration; + function isExternalModuleReference(node: Node): node is ExternalModuleReference; + function isJsxElement(node: Node): node is JsxElement; + function isJsxSelfClosingElement(node: Node): node is JsxSelfClosingElement; + function isJsxOpeningElement(node: Node): node is JsxOpeningElement; + function isJsxClosingElement(node: Node): node is JsxClosingElement; + function isJsxAttribute(node: Node): node is JsxAttribute; + function isJsxAttributes(node: Node): node is JsxAttributes; + function isJsxSpreadAttribute(node: Node): node is JsxSpreadAttribute; + function isJsxExpression(node: Node): node is JsxExpression; + function isCaseClause(node: Node): node is CaseClause; + function isDefaultClause(node: Node): node is DefaultClause; + function isHeritageClause(node: Node): node is HeritageClause; + function isCatchClause(node: Node): node is CatchClause; + function isPropertyAssignment(node: Node): node is PropertyAssignment; + function isShorthandPropertyAssignment(node: Node): node is ShorthandPropertyAssignment; + function isSpreadAssignment(node: Node): node is SpreadAssignment; + function isEnumMember(node: Node): node is EnumMember; + function isSourceFile(node: Node): node is SourceFile; + function isBundle(node: Node): node is Bundle; + function isJSDocTypeExpression(node: Node): node is JSDocTypeExpression; + function isJSDocAllType(node: JSDocAllType): node is JSDocAllType; + function isJSDocUnknownType(node: Node): node is JSDocUnknownType; + function isJSDocArrayType(node: Node): node is JSDocArrayType; + function isJSDocUnionType(node: Node): node is JSDocUnionType; + function isJSDocTupleType(node: Node): node is JSDocTupleType; + function isJSDocNullableType(node: Node): node is JSDocNullableType; + function isJSDocNonNullableType(node: Node): node is JSDocNonNullableType; + function isJSDocRecordType(node: Node): node is JSDocRecordType; + function isJSDocRecordMember(node: Node): node is JSDocRecordMember; + function isJSDocTypeReference(node: Node): node is JSDocTypeReference; + function isJSDocOptionalType(node: Node): node is JSDocOptionalType; + function isJSDocFunctionType(node: Node): node is JSDocFunctionType; + function isJSDocVariadicType(node: Node): node is JSDocVariadicType; + function isJSDocConstructorType(node: Node): node is JSDocConstructorType; + function isJSDocThisType(node: Node): node is JSDocThisType; + function isJSDoc(node: Node): node is JSDoc; + function isJSDocAugmentsTag(node: Node): node is JSDocAugmentsTag; + function isJSDocParameterTag(node: Node): node is JSDocParameterTag; + function isJSDocReturnTag(node: Node): node is JSDocReturnTag; + function isJSDocTypeTag(node: Node): node is JSDocTypeTag; + function isJSDocTemplateTag(node: Node): node is JSDocTemplateTag; + function isJSDocTypedefTag(node: Node): node is JSDocTypedefTag; + function isJSDocPropertyTag(node: Node): node is JSDocPropertyTag; + function isJSDocTypeLiteral(node: Node): node is JSDocTypeLiteral; + function isJSDocLiteralType(node: Node): node is JSDocLiteralType; +} +declare namespace ts { + /** + * True if node is of some token syntax kind. + * For example, this is true for an IfKeyword but not for an IfStatement. + */ + function isToken(n: Node): boolean; + function isLiteralExpression(node: Node): node is LiteralExpression; + function isTemplateMiddleOrTemplateTail(node: Node): node is TemplateMiddle | TemplateTail; + function isModifier(node: Node): node is Modifier; + function isEntityName(node: Node): node is EntityName; + function isPropertyName(node: Node): node is PropertyName; + function isBindingName(node: Node): node is BindingName; + function isFunctionLike(node: Node): node is FunctionLikeDeclaration; + function isClassElement(node: Node): node is ClassElement; + function isClassLike(node: Node): node is ClassLikeDeclaration; + function isAccessor(node: Node): node is AccessorDeclaration; + function isTypeElement(node: Node): node is TypeElement; + function isObjectLiteralElementLike(node: Node): node is ObjectLiteralElementLike; + /** + * Node test that determines whether a node is a valid type node. + * This differs from the `isPartOfTypeNode` function which determines whether a node is *part* + * of a TypeNode. + */ + function isTypeNode(node: Node): node is TypeNode; + function isFunctionOrConstructorTypeNode(node: Node): node is FunctionTypeNode | ConstructorTypeNode; + function isPropertyAccessOrQualifiedName(node: Node): node is PropertyAccessExpression | QualifiedName; + function isCallLikeExpression(node: Node): node is CallLikeExpression; + function isCallOrNewExpression(node: Node): node is CallExpression | NewExpression; + function isTemplateLiteral(node: Node): node is TemplateLiteral; + function isAssertionExpression(node: Node): node is AssertionExpression; + function isIterationStatement(node: Node, lookInLabeledStatements: boolean): node is IterationStatement; + function isJsxOpeningLikeElement(node: Node): node is JsxOpeningLikeElement; + function isCaseOrDefaultClause(node: Node): node is CaseOrDefaultClause; + /** True if node is of a kind that may contain comment text. */ + function isJSDocCommentContainingNode(node: Node): boolean; } declare namespace ts { /** @@ -2712,6 +2989,7 @@ declare namespace ts { function createLiteral(value: string | number | boolean): PrimaryExpression; function createNumericLiteral(value: string): NumericLiteral; function createIdentifier(text: string): Identifier; + function updateIdentifier(node: Identifier, typeArguments: NodeArray | undefined): Identifier; /** Create a unique temporary variable. */ function createTempVariable(recordTempVariable: ((node: Identifier) => void) | undefined): Identifier; /** Create a unique temporary variable for use in a loop. */ @@ -2730,63 +3008,65 @@ declare namespace ts { function updateQualifiedName(node: QualifiedName, left: EntityName, right: Identifier): QualifiedName; function createComputedPropertyName(expression: Expression): ComputedPropertyName; function updateComputedPropertyName(node: ComputedPropertyName, expression: Expression): ComputedPropertyName; - function createSignatureDeclaration(kind: SyntaxKind, typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined): SignatureDeclaration; - function createFunctionTypeNode(typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined): FunctionTypeNode; - function updateFunctionTypeNode(node: FunctionTypeNode, typeParameters: NodeArray | undefined, parameters: NodeArray, type: TypeNode | undefined): FunctionTypeNode; - function createConstructorTypeNode(typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined): ConstructorTypeNode; - function updateConstructorTypeNode(node: ConstructorTypeNode, typeParameters: NodeArray | undefined, parameters: NodeArray, type: TypeNode | undefined): ConstructorTypeNode; - function createCallSignatureDeclaration(typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined): CallSignatureDeclaration; - function updateCallSignatureDeclaration(node: CallSignatureDeclaration, typeParameters: NodeArray | undefined, parameters: NodeArray, type: TypeNode | undefined): CallSignatureDeclaration; - function createConstructSignatureDeclaration(typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined): ConstructSignatureDeclaration; - function updateConstructSignatureDeclaration(node: ConstructSignatureDeclaration, typeParameters: NodeArray | undefined, parameters: NodeArray, type: TypeNode | undefined): ConstructSignatureDeclaration; + function createTypeParameterDeclaration(name: string | Identifier, constraint?: TypeNode, defaultType?: TypeNode): TypeParameterDeclaration; + function updateTypeParameterDeclaration(node: TypeParameterDeclaration, name: Identifier, constraint: TypeNode | undefined, defaultType: TypeNode | undefined): TypeParameterDeclaration; + function createParameter(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, dotDotDotToken: DotDotDotToken | undefined, name: string | BindingName, questionToken?: QuestionToken, type?: TypeNode, initializer?: Expression): ParameterDeclaration; + function updateParameter(node: ParameterDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, dotDotDotToken: DotDotDotToken | undefined, name: string | BindingName, questionToken: QuestionToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): ParameterDeclaration; + function createDecorator(expression: Expression): Decorator; + function updateDecorator(node: Decorator, expression: Expression): Decorator; + function createPropertySignature(modifiers: Modifier[] | undefined, name: PropertyName | string, questionToken: QuestionToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): PropertySignature; + function updatePropertySignature(node: PropertySignature, modifiers: Modifier[] | undefined, name: PropertyName, questionToken: QuestionToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): PropertySignature; + function createProperty(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: string | PropertyName, questionToken: QuestionToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): PropertyDeclaration; + function updateProperty(node: PropertyDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: PropertyName, type: TypeNode | undefined, initializer: Expression | undefined): PropertyDeclaration; function createMethodSignature(typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined, name: string | PropertyName, questionToken: QuestionToken | undefined): MethodSignature; function updateMethodSignature(node: MethodSignature, typeParameters: NodeArray | undefined, parameters: NodeArray, type: TypeNode | undefined, name: PropertyName, questionToken: QuestionToken | undefined): MethodSignature; + function createMethod(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, asteriskToken: AsteriskToken | undefined, name: string | PropertyName, questionToken: QuestionToken | undefined, typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): MethodDeclaration; + function updateMethod(node: MethodDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, asteriskToken: AsteriskToken | undefined, name: PropertyName, questionToken: QuestionToken | undefined, typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): MethodDeclaration; + function createConstructor(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, parameters: ParameterDeclaration[], body: Block | undefined): ConstructorDeclaration; + function updateConstructor(node: ConstructorDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, parameters: ParameterDeclaration[], body: Block | undefined): ConstructorDeclaration; + function createGetAccessor(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: string | PropertyName, parameters: ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): GetAccessorDeclaration; + function updateGetAccessor(node: GetAccessorDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: PropertyName, parameters: ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): GetAccessorDeclaration; + function createSetAccessor(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: string | PropertyName, parameters: ParameterDeclaration[], body: Block | undefined): SetAccessorDeclaration; + function updateSetAccessor(node: SetAccessorDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: PropertyName, parameters: ParameterDeclaration[], body: Block | undefined): SetAccessorDeclaration; + function createCallSignature(typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined): CallSignatureDeclaration; + function updateCallSignature(node: CallSignatureDeclaration, typeParameters: NodeArray | undefined, parameters: NodeArray, type: TypeNode | undefined): CallSignatureDeclaration; + function createConstructSignature(typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined): ConstructSignatureDeclaration; + function updateConstructSignature(node: ConstructSignatureDeclaration, typeParameters: NodeArray | undefined, parameters: NodeArray, type: TypeNode | undefined): ConstructSignatureDeclaration; + function createIndexSignature(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, parameters: ParameterDeclaration[], type: TypeNode): IndexSignatureDeclaration; + function updateIndexSignature(node: IndexSignatureDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, parameters: ParameterDeclaration[], type: TypeNode): IndexSignatureDeclaration; function createKeywordTypeNode(kind: KeywordTypeNode["kind"]): KeywordTypeNode; - function createThisTypeNode(): ThisTypeNode; - function createLiteralTypeNode(literal: Expression): LiteralTypeNode; - function updateLiteralTypeNode(node: LiteralTypeNode, literal: Expression): LiteralTypeNode; - function createTypeReferenceNode(typeName: string | EntityName, typeArguments: TypeNode[] | undefined): TypeReferenceNode; - function updateTypeReferenceNode(node: TypeReferenceNode, typeName: EntityName, typeArguments: NodeArray | undefined): TypeReferenceNode; function createTypePredicateNode(parameterName: Identifier | ThisTypeNode | string, type: TypeNode): TypePredicateNode; function updateTypePredicateNode(node: TypePredicateNode, parameterName: Identifier | ThisTypeNode, type: TypeNode): TypePredicateNode; + function createTypeReferenceNode(typeName: string | EntityName, typeArguments: TypeNode[] | undefined): TypeReferenceNode; + function updateTypeReferenceNode(node: TypeReferenceNode, typeName: EntityName, typeArguments: NodeArray | undefined): TypeReferenceNode; + function createFunctionTypeNode(typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined): FunctionTypeNode; + function updateFunctionTypeNode(node: FunctionTypeNode, typeParameters: NodeArray | undefined, parameters: NodeArray, type: TypeNode | undefined): FunctionTypeNode; + function createConstructorTypeNode(typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined): ConstructorTypeNode; + function updateConstructorTypeNode(node: ConstructorTypeNode, typeParameters: NodeArray | undefined, parameters: NodeArray, type: TypeNode | undefined): ConstructorTypeNode; function createTypeQueryNode(exprName: EntityName): TypeQueryNode; function updateTypeQueryNode(node: TypeQueryNode, exprName: EntityName): TypeQueryNode; - function createArrayTypeNode(elementType: TypeNode): ArrayTypeNode; - function updateArrayTypeNode(node: ArrayTypeNode, elementType: TypeNode): ArrayTypeNode; - function createUnionOrIntersectionTypeNode(kind: SyntaxKind.UnionType, types: TypeNode[]): UnionTypeNode; - function createUnionOrIntersectionTypeNode(kind: SyntaxKind.IntersectionType, types: TypeNode[]): IntersectionTypeNode; - function createUnionOrIntersectionTypeNode(kind: SyntaxKind.UnionType | SyntaxKind.IntersectionType, types: TypeNode[]): UnionOrIntersectionTypeNode; - function updateUnionOrIntersectionTypeNode(node: UnionOrIntersectionTypeNode, types: NodeArray): UnionOrIntersectionTypeNode; function createTypeLiteralNode(members: TypeElement[]): TypeLiteralNode; function updateTypeLiteralNode(node: TypeLiteralNode, members: NodeArray): TypeLiteralNode; + function createArrayTypeNode(elementType: TypeNode): ArrayTypeNode; + function updateArrayTypeNode(node: ArrayTypeNode, elementType: TypeNode): ArrayTypeNode; function createTupleTypeNode(elementTypes: TypeNode[]): TupleTypeNode; function updateTypleTypeNode(node: TupleTypeNode, elementTypes: TypeNode[]): TupleTypeNode; - function createMappedTypeNode(readonlyToken: ReadonlyToken | undefined, typeParameter: TypeParameterDeclaration, questionToken: QuestionToken | undefined, type: TypeNode | undefined): MappedTypeNode; - function updateMappedTypeNode(node: MappedTypeNode, readonlyToken: ReadonlyToken | undefined, typeParameter: TypeParameterDeclaration, questionToken: QuestionToken | undefined, type: TypeNode | undefined): MappedTypeNode; + function createUnionTypeNode(types: TypeNode[]): UnionTypeNode; + function updateUnionTypeNode(node: UnionTypeNode, types: NodeArray): UnionTypeNode; + function createIntersectionTypeNode(types: TypeNode[]): IntersectionTypeNode; + function updateIntersectionTypeNode(node: IntersectionTypeNode, types: NodeArray): IntersectionTypeNode; + function createUnionOrIntersectionTypeNode(kind: SyntaxKind.UnionType | SyntaxKind.IntersectionType, types: TypeNode[]): UnionTypeNode | IntersectionTypeNode; + function createParenthesizedType(type: TypeNode): ParenthesizedTypeNode; + function updateParenthesizedType(node: ParenthesizedTypeNode, type: TypeNode): ParenthesizedTypeNode; + function createThisTypeNode(): ThisTypeNode; function createTypeOperatorNode(type: TypeNode): TypeOperatorNode; function updateTypeOperatorNode(node: TypeOperatorNode, type: TypeNode): TypeOperatorNode; function createIndexedAccessTypeNode(objectType: TypeNode, indexType: TypeNode): IndexedAccessTypeNode; function updateIndexedAccessTypeNode(node: IndexedAccessTypeNode, objectType: TypeNode, indexType: TypeNode): IndexedAccessTypeNode; - function createTypeParameterDeclaration(name: string | Identifier, constraint: TypeNode | undefined, defaultType: TypeNode | undefined): TypeParameterDeclaration; - function updateTypeParameterDeclaration(node: TypeParameterDeclaration, name: Identifier, constraint: TypeNode | undefined, defaultType: TypeNode | undefined): TypeParameterDeclaration; - function createPropertySignature(name: PropertyName | string, questionToken: QuestionToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): PropertySignature; - function updatePropertySignature(node: PropertySignature, name: PropertyName, questionToken: QuestionToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): PropertySignature; - function createIndexSignatureDeclaration(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, parameters: ParameterDeclaration[], type: TypeNode): IndexSignatureDeclaration; - function updateIndexSignatureDeclaration(node: IndexSignatureDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, parameters: ParameterDeclaration[], type: TypeNode): IndexSignatureDeclaration; - function createParameter(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, dotDotDotToken: DotDotDotToken | undefined, name: string | BindingName, questionToken?: QuestionToken, type?: TypeNode, initializer?: Expression): ParameterDeclaration; - function updateParameter(node: ParameterDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, dotDotDotToken: DotDotDotToken | undefined, name: string | BindingName, questionToken: QuestionToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): ParameterDeclaration; - function createDecorator(expression: Expression): Decorator; - function updateDecorator(node: Decorator, expression: Expression): Decorator; - function createProperty(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: string | PropertyName, questionToken: QuestionToken | undefined, type: TypeNode | undefined, initializer: Expression): PropertyDeclaration; - function updateProperty(node: PropertyDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: PropertyName, type: TypeNode | undefined, initializer: Expression): PropertyDeclaration; - function createMethodDeclaration(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, asteriskToken: AsteriskToken | undefined, name: string | PropertyName, questionToken: QuestionToken | undefined, typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): MethodDeclaration; - function updateMethod(node: MethodDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, asteriskToken: AsteriskToken | undefined, name: PropertyName, questionToken: QuestionToken | undefined, typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): MethodDeclaration; - function createConstructor(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, parameters: ParameterDeclaration[], body: Block | undefined): ConstructorDeclaration; - function updateConstructor(node: ConstructorDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, parameters: ParameterDeclaration[], body: Block | undefined): ConstructorDeclaration; - function createGetAccessor(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: string | PropertyName, parameters: ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): GetAccessorDeclaration; - function updateGetAccessor(node: GetAccessorDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: PropertyName, parameters: ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): GetAccessorDeclaration; - function createSetAccessor(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: string | PropertyName, parameters: ParameterDeclaration[], body: Block | undefined): SetAccessorDeclaration; - function updateSetAccessor(node: SetAccessorDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: PropertyName, parameters: ParameterDeclaration[], body: Block | undefined): SetAccessorDeclaration; + function createMappedTypeNode(readonlyToken: ReadonlyToken | undefined, typeParameter: TypeParameterDeclaration, questionToken: QuestionToken | undefined, type: TypeNode | undefined): MappedTypeNode; + function updateMappedTypeNode(node: MappedTypeNode, readonlyToken: ReadonlyToken | undefined, typeParameter: TypeParameterDeclaration, questionToken: QuestionToken | undefined, type: TypeNode | undefined): MappedTypeNode; + function createLiteralTypeNode(literal: Expression): LiteralTypeNode; + function updateLiteralTypeNode(node: LiteralTypeNode, literal: Expression): LiteralTypeNode; function createObjectBindingPattern(elements: BindingElement[]): ObjectBindingPattern; function updateObjectBindingPattern(node: ObjectBindingPattern, elements: BindingElement[]): ObjectBindingPattern; function createArrayBindingPattern(elements: ArrayBindingElement[]): ArrayBindingPattern; @@ -2828,7 +3108,7 @@ declare namespace ts { function createPostfix(operand: Expression, operator: PostfixUnaryOperator): PostfixUnaryExpression; function updatePostfix(node: PostfixUnaryExpression, operand: Expression): PostfixUnaryExpression; function createBinary(left: Expression, operator: BinaryOperator | BinaryOperatorToken, right: Expression): BinaryExpression; - function updateBinary(node: BinaryExpression, left: Expression, right: Expression): BinaryExpression; + function updateBinary(node: BinaryExpression, left: Expression, right: Expression, operator?: BinaryOperator | BinaryOperatorToken): BinaryExpression; function createConditional(condition: Expression, whenTrue: Expression, whenFalse: Expression): ConditionalExpression; function createConditional(condition: Expression, questionToken: QuestionToken, whenTrue: Expression, colonToken: ColonToken, whenFalse: Expression): ConditionalExpression; function updateConditional(node: ConditionalExpression, condition: Expression, whenTrue: Expression, whenFalse: Expression): ConditionalExpression; @@ -2848,16 +3128,15 @@ declare namespace ts { function updateAsExpression(node: AsExpression, expression: Expression, type: TypeNode): AsExpression; function createNonNullExpression(expression: Expression): NonNullExpression; function updateNonNullExpression(node: NonNullExpression, expression: Expression): NonNullExpression; + function createMetaProperty(keywordToken: MetaProperty["keywordToken"], name: Identifier): MetaProperty; + function updateMetaProperty(node: MetaProperty, name: Identifier): MetaProperty; function createTemplateSpan(expression: Expression, literal: TemplateMiddle | TemplateTail): TemplateSpan; function updateTemplateSpan(node: TemplateSpan, expression: Expression, literal: TemplateMiddle | TemplateTail): TemplateSpan; + function createSemicolonClassElement(): SemicolonClassElement; function createBlock(statements: Statement[], multiLine?: boolean): Block; function updateBlock(node: Block, statements: Statement[]): Block; function createVariableStatement(modifiers: Modifier[] | undefined, declarationList: VariableDeclarationList | VariableDeclaration[]): VariableStatement; function updateVariableStatement(node: VariableStatement, modifiers: Modifier[] | undefined, declarationList: VariableDeclarationList): VariableStatement; - function createVariableDeclarationList(declarations: VariableDeclaration[], flags?: NodeFlags): VariableDeclarationList; - function updateVariableDeclarationList(node: VariableDeclarationList, declarations: VariableDeclaration[]): VariableDeclarationList; - function createVariableDeclaration(name: string | BindingName, type?: TypeNode, initializer?: Expression): VariableDeclaration; - function updateVariableDeclaration(node: VariableDeclaration, name: BindingName, type: TypeNode | undefined, initializer: Expression | undefined): VariableDeclaration; function createEmptyStatement(): EmptyStatement; function createStatement(expression: Expression): ExpressionStatement; function updateStatement(node: ExpressionStatement, expression: Expression): ExpressionStatement; @@ -2889,10 +3168,19 @@ declare namespace ts { function updateThrow(node: ThrowStatement, expression: Expression): ThrowStatement; function createTry(tryBlock: Block, catchClause: CatchClause | undefined, finallyBlock: Block | undefined): TryStatement; function updateTry(node: TryStatement, tryBlock: Block, catchClause: CatchClause | undefined, finallyBlock: Block | undefined): TryStatement; + function createDebuggerStatement(): DebuggerStatement; + function createVariableDeclaration(name: string | BindingName, type?: TypeNode, initializer?: Expression): VariableDeclaration; + function updateVariableDeclaration(node: VariableDeclaration, name: BindingName, type: TypeNode | undefined, initializer: Expression | undefined): VariableDeclaration; + function createVariableDeclarationList(declarations: VariableDeclaration[], flags?: NodeFlags): VariableDeclarationList; + function updateVariableDeclarationList(node: VariableDeclarationList, declarations: VariableDeclaration[]): VariableDeclarationList; function createFunctionDeclaration(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, asteriskToken: AsteriskToken | undefined, name: string | Identifier | undefined, typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): FunctionDeclaration; function updateFunctionDeclaration(node: FunctionDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, asteriskToken: AsteriskToken | undefined, name: Identifier | undefined, typeParameters: TypeParameterDeclaration[] | undefined, parameters: ParameterDeclaration[], type: TypeNode | undefined, body: Block | undefined): FunctionDeclaration; function createClassDeclaration(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: string | Identifier | undefined, typeParameters: TypeParameterDeclaration[] | undefined, heritageClauses: HeritageClause[], members: ClassElement[]): ClassDeclaration; function updateClassDeclaration(node: ClassDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: Identifier | undefined, typeParameters: TypeParameterDeclaration[] | undefined, heritageClauses: HeritageClause[], members: ClassElement[]): ClassDeclaration; + function createInterfaceDeclaration(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: string | Identifier, typeParameters: TypeParameterDeclaration[] | undefined, heritageClauses: HeritageClause[] | undefined, members: TypeElement[]): InterfaceDeclaration; + function updateInterfaceDeclaration(node: InterfaceDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: Identifier, typeParameters: TypeParameterDeclaration[] | undefined, heritageClauses: HeritageClause[] | undefined, members: TypeElement[]): InterfaceDeclaration; + function createTypeAliasDeclaration(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: string | Identifier, typeParameters: TypeParameterDeclaration[] | undefined, type: TypeNode): TypeAliasDeclaration; + function updateTypeAliasDeclaration(node: TypeAliasDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: Identifier, typeParameters: TypeParameterDeclaration[] | undefined, type: TypeNode): TypeAliasDeclaration; function createEnumDeclaration(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: string | Identifier, members: EnumMember[]): EnumDeclaration; function updateEnumDeclaration(node: EnumDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: Identifier, members: EnumMember[]): EnumDeclaration; function createModuleDeclaration(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: ModuleName, body: ModuleBody | undefined, flags?: NodeFlags): ModuleDeclaration; @@ -2901,12 +3189,14 @@ declare namespace ts { function updateModuleBlock(node: ModuleBlock, statements: Statement[]): ModuleBlock; function createCaseBlock(clauses: CaseOrDefaultClause[]): CaseBlock; function updateCaseBlock(node: CaseBlock, clauses: CaseOrDefaultClause[]): CaseBlock; + function createNamespaceExportDeclaration(name: string | Identifier): NamespaceExportDeclaration; + function updateNamespaceExportDeclaration(node: NamespaceExportDeclaration, name: Identifier): NamespaceExportDeclaration; function createImportEqualsDeclaration(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: string | Identifier, moduleReference: ModuleReference): ImportEqualsDeclaration; function updateImportEqualsDeclaration(node: ImportEqualsDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, name: Identifier, moduleReference: ModuleReference): ImportEqualsDeclaration; function createImportDeclaration(decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, importClause: ImportClause | undefined, moduleSpecifier?: Expression): ImportDeclaration; function updateImportDeclaration(node: ImportDeclaration, decorators: Decorator[] | undefined, modifiers: Modifier[] | undefined, importClause: ImportClause | undefined, moduleSpecifier: Expression | undefined): ImportDeclaration; - function createImportClause(name: Identifier, namedBindings: NamedImportBindings): ImportClause; - function updateImportClause(node: ImportClause, name: Identifier, namedBindings: NamedImportBindings): ImportClause; + function createImportClause(name: Identifier | undefined, namedBindings: NamedImportBindings | undefined): ImportClause; + function updateImportClause(node: ImportClause, name: Identifier | undefined, namedBindings: NamedImportBindings | undefined): ImportClause; function createNamespaceImport(name: Identifier): NamespaceImport; function updateNamespaceImport(node: NamespaceImport, name: Identifier): NamespaceImport; function createNamedImports(elements: ImportSpecifier[]): NamedImports; @@ -2931,20 +3221,20 @@ declare namespace ts { function updateJsxOpeningElement(node: JsxOpeningElement, tagName: JsxTagNameExpression, attributes: JsxAttributes): JsxOpeningElement; function createJsxClosingElement(tagName: JsxTagNameExpression): JsxClosingElement; function updateJsxClosingElement(node: JsxClosingElement, tagName: JsxTagNameExpression): JsxClosingElement; - function createJsxAttributes(properties: JsxAttributeLike[]): JsxAttributes; - function updateJsxAttributes(jsxAttributes: JsxAttributes, properties: JsxAttributeLike[]): JsxAttributes; function createJsxAttribute(name: Identifier, initializer: StringLiteral | JsxExpression): JsxAttribute; function updateJsxAttribute(node: JsxAttribute, name: Identifier, initializer: StringLiteral | JsxExpression): JsxAttribute; + function createJsxAttributes(properties: JsxAttributeLike[]): JsxAttributes; + function updateJsxAttributes(node: JsxAttributes, properties: JsxAttributeLike[]): JsxAttributes; function createJsxSpreadAttribute(expression: Expression): JsxSpreadAttribute; function updateJsxSpreadAttribute(node: JsxSpreadAttribute, expression: Expression): JsxSpreadAttribute; function createJsxExpression(dotDotDotToken: DotDotDotToken | undefined, expression: Expression | undefined): JsxExpression; function updateJsxExpression(node: JsxExpression, expression: Expression | undefined): JsxExpression; - function createHeritageClause(token: HeritageClause["token"], types: ExpressionWithTypeArguments[]): HeritageClause; - function updateHeritageClause(node: HeritageClause, types: ExpressionWithTypeArguments[]): HeritageClause; function createCaseClause(expression: Expression, statements: Statement[]): CaseClause; function updateCaseClause(node: CaseClause, expression: Expression, statements: Statement[]): CaseClause; function createDefaultClause(statements: Statement[]): DefaultClause; function updateDefaultClause(node: DefaultClause, statements: Statement[]): DefaultClause; + function createHeritageClause(token: HeritageClause["token"], types: ExpressionWithTypeArguments[]): HeritageClause; + function updateHeritageClause(node: HeritageClause, types: ExpressionWithTypeArguments[]): HeritageClause; function createCatchClause(variableDeclaration: string | VariableDeclaration, block: Block): CatchClause; function updateCatchClause(node: CatchClause, variableDeclaration: VariableDeclaration, block: Block): CatchClause; function createPropertyAssignment(name: string | PropertyName, initializer: Expression): PropertyAssignment; @@ -2977,8 +3267,12 @@ declare namespace ts { */ function createPartiallyEmittedExpression(expression: Expression, original?: Node): PartiallyEmittedExpression; function updatePartiallyEmittedExpression(node: PartiallyEmittedExpression, expression: Expression): PartiallyEmittedExpression; + function createCommaList(elements: Expression[]): CommaListExpression; + function updateCommaList(node: CommaListExpression, elements: Expression[]): CommaListExpression; function createBundle(sourceFiles: SourceFile[]): Bundle; function updateBundle(node: Bundle, sourceFiles: SourceFile[]): Bundle; + function createImmediatelyInvokedFunctionExpression(statements: Statement[]): CallExpression; + function createImmediatelyInvokedFunctionExpression(statements: Statement[], param: ParameterDeclaration, paramValue: Expression): CallExpression; function createComma(left: Expression, right: Expression): Expression; function createLessThan(left: Expression, right: Expression): Expression; function createAssignment(left: ObjectLiteralExpression | ArrayLiteralExpression, right: Expression): DestructuringAssignment; @@ -3011,19 +3305,23 @@ declare namespace ts { /** * Gets a custom text range to use when emitting source maps. */ - function getSourceMapRange(node: Node): TextRange; + function getSourceMapRange(node: Node): SourceMapRange; /** * Sets a custom text range to use when emitting source maps. */ - function setSourceMapRange(node: T, range: TextRange | undefined): T; + function setSourceMapRange(node: T, range: SourceMapRange | undefined): T; + /** + * Create an external source map source file reference + */ + function createSourceMapSource(fileName: string, text: string, skipTrivia?: (pos: number) => number): SourceMapSource; /** * Gets the TextRange to use for source maps for a token of a node. */ - function getTokenSourceMapRange(node: Node, token: SyntaxKind): TextRange | undefined; + function getTokenSourceMapRange(node: Node, token: SyntaxKind): SourceMapRange | undefined; /** * Sets the TextRange to use for source maps for a token of a node. */ - function setTokenSourceMapRange(node: T, token: SyntaxKind, range: TextRange | undefined): T; + function setTokenSourceMapRange(node: T, token: SyntaxKind, range: SourceMapRange | undefined): T; /** * Gets a custom text range to use when emitting comments. */ @@ -3041,11 +3339,11 @@ declare namespace ts { /** * Gets the constant value to emit for an expression. */ - function getConstantValue(node: PropertyAccessExpression | ElementAccessExpression): number; + function getConstantValue(node: PropertyAccessExpression | ElementAccessExpression): string | number; /** * Sets the constant value to emit for an expression. */ - function setConstantValue(node: PropertyAccessExpression | ElementAccessExpression, value: number): PropertyAccessExpression | ElementAccessExpression; + function setConstantValue(node: PropertyAccessExpression | ElementAccessExpression, value: string | number): PropertyAccessExpression | ElementAccessExpression; /** * Adds an EmitHelper to a node. */ @@ -3070,17 +3368,23 @@ declare namespace ts { } declare namespace ts { function createNode(kind: SyntaxKind, pos?: number, end?: number): Node; - function forEachChild(node: Node, cbNode: (node: Node) => T, cbNodeArray?: (nodes: Node[]) => T): T; + /** + * Invokes a callback for each child of the given node. The 'cbNode' callback is invoked for all child nodes + * stored in properties. If a 'cbNodes' callback is specified, it is invoked for embedded arrays; otherwise, + * embedded arrays are flattened and the 'cbNode' callback is invoked for each element. If a callback returns + * a truthy value, iteration stops and that value is returned. Otherwise, undefined is returned. + * + * @param node a given node to visit its children + * @param cbNode a callback to be invoked for all child nodes + * @param cbNodeArray a callback to be invoked for embedded array + */ + function forEachChild(node: Node, cbNode: (node: Node) => T | undefined, cbNodeArray?: (nodes: NodeArray) => T | undefined): T | undefined; function createSourceFile(fileName: string, sourceText: string, languageVersion: ScriptTarget, setParentNodes?: boolean, scriptKind?: ScriptKind): SourceFile; function parseIsolatedEntityName(text: string, languageVersion: ScriptTarget): EntityName; function isExternalModule(file: SourceFile): boolean; function updateSourceFile(sourceFile: SourceFile, newText: string, textChangeRange: TextChangeRange, aggressiveChecks?: boolean): SourceFile; } declare namespace ts { - /** Array that is only intended to be pushed to, never read. */ - interface Push { - push(value: T): void; - } function moduleHasNonRelativeName(moduleName: string): boolean; function getEffectiveTypeRoots(options: CompilerOptions, host: { directoryExists?: (directoryName: string) => boolean; @@ -3219,7 +3523,21 @@ declare namespace ts { getNewLine(): string; } function formatDiagnostics(diagnostics: Diagnostic[], host: FormatDiagnosticsHost): string; + function formatDiagnosticsWithColorAndContext(diagnostics: Diagnostic[], host: FormatDiagnosticsHost): string; function flattenDiagnosticMessageText(messageText: string | DiagnosticMessageChain, newLine: string): string; + /** + * Create a new 'Program' instance. A Program is an immutable collection of 'SourceFile's and a 'CompilerOptions' + * that represent a compilation unit. + * + * Creating a program proceeds from a set of root files, expanding the set of inputs by following imports and + * triple-slash-reference-path directives transitively. '@types' and triple-slash-reference-types are also pulled in. + * + * @param rootNames - A set of root files. + * @param options - The compiler options which should be used. + * @param host - The host interacts with the underlying file system. + * @param oldProgram - Reuses an old program structure. + * @returns A 'Program' object. + */ function createProgram(rootNames: string[], options: CompilerOptions, host?: CompilerHost, oldProgram?: Program): Program; } declare namespace ts { @@ -3247,9 +3565,10 @@ declare namespace ts { * @param host Instance of ParseConfigHost used to enumerate files in folder. * @param basePath A root directory to resolve relative path entries in the config * file to. e.g. outDir + * @param resolutionStack Only present for backwards-compatibility. Should be empty. */ function parseJsonConfigFileContent(json: any, host: ParseConfigHost, basePath: string, existingOptions?: CompilerOptions, configFileName?: string, resolutionStack?: Path[], extraFileExtensions?: JsFileExtensionInfo[]): ParsedCommandLine; - function convertCompileOnSaveOptionFromJson(jsonOption: any, basePath: string, errors: Diagnostic[]): boolean | undefined; + function convertCompileOnSaveOptionFromJson(jsonOption: any, basePath: string, errors: Diagnostic[]): boolean; function convertCompilerOptionsFromJson(jsonOptions: any, basePath: string, configFileName?: string): { options: CompilerOptions; errors: Diagnostic[]; @@ -3275,31 +3594,31 @@ declare namespace ts { getText(sourceFile?: SourceFile): string; getFirstToken(sourceFile?: SourceFile): Node; getLastToken(sourceFile?: SourceFile): Node; - forEachChild(cbNode: (node: Node) => T, cbNodeArray?: (nodes: Node[]) => T): T; + forEachChild(cbNode: (node: Node) => T | undefined, cbNodeArray?: (nodes: NodeArray) => T | undefined): T | undefined; } interface Symbol { getFlags(): SymbolFlags; getName(): string; - getDeclarations(): Declaration[]; + getDeclarations(): Declaration[] | undefined; getDocumentationComment(): SymbolDisplayPart[]; getJsDocTags(): JSDocTagInfo[]; } interface Type { getFlags(): TypeFlags; - getSymbol(): Symbol; + getSymbol(): Symbol | undefined; getProperties(): Symbol[]; - getProperty(propertyName: string): Symbol; + getProperty(propertyName: string): Symbol | undefined; getApparentProperties(): Symbol[]; getCallSignatures(): Signature[]; getConstructSignatures(): Signature[]; - getStringIndexType(): Type; - getNumberIndexType(): Type; - getBaseTypes(): BaseType[]; + getStringIndexType(): Type | undefined; + getNumberIndexType(): Type | undefined; + getBaseTypes(): BaseType[] | undefined; getNonNullableType(): Type; } interface Signature { getDeclaration(): SignatureDeclaration; - getTypeParameters(): TypeParameter[]; + getTypeParameters(): TypeParameter[] | undefined; getParameters(): Symbol[]; getReturnType(): Type; getDocumentationComment(): SymbolDisplayPart[]; @@ -3315,6 +3634,9 @@ declare namespace ts { interface SourceFileLike { getLineAndCharacterOfPosition(pos: number): LineAndCharacter; } + interface SourceMapSource { + getLineAndCharacterOfPosition(pos: number): LineAndCharacter; + } /** * Represents an immutable snapshot of a script at a specified time.Once acquired, the * snapshot is observably immutable. i.e. the same calls with the same parameters will return @@ -3423,6 +3745,8 @@ declare namespace ts { getDocCommentTemplateAtPosition(fileName: string, position: number): TextInsertion; isValidBraceCompletionAtPosition(fileName: string, position: number, openingBrace: number): boolean; getCodeFixesAtPosition(fileName: string, start: number, end: number, errorCodes: number[], formatOptions: FormatCodeSettings): CodeAction[]; + getApplicableRefactors(fileName: string, positionOrRaneg: number | TextRange): ApplicableRefactorInfo[]; + getEditsForRefactor(fileName: string, formatOptions: FormatCodeSettings, positionOrRange: number | TextRange, refactorName: string, actionName: string): RefactorEditInfo | undefined; getEmitOutput(fileName: string, emitOnlyDtsFiles?: boolean): EmitOutput; getProgram(): Program; dispose(): void; @@ -3493,6 +3817,54 @@ declare namespace ts { /** Text changes to apply to each file as part of the code action */ changes: FileTextChanges[]; } + /** + * A set of one or more available refactoring actions, grouped under a parent refactoring. + */ + interface ApplicableRefactorInfo { + /** + * The programmatic name of the refactoring + */ + name: string; + /** + * A description of this refactoring category to show to the user. + * If the refactoring gets inlined (see below), this text will not be visible. + */ + description: string; + /** + * Inlineable refactorings can have their actions hoisted out to the top level + * of a context menu. Non-inlineanable refactorings should always be shown inside + * their parent grouping. + * + * If not specified, this value is assumed to be 'true' + */ + inlineable?: boolean; + actions: RefactorActionInfo[]; + } + /** + * Represents a single refactoring action - for example, the "Extract Method..." refactor might + * offer several actions, each corresponding to a surround class or closure to extract into. + */ + type RefactorActionInfo = { + /** + * The programmatic name of the refactoring action + */ + name: string; + /** + * A description of this refactoring action to show to the user. + * If the parent refactoring is inlined away, this will be the only text shown, + * so this description should make sense by itself if the parent is inlineable=true + */ + description: string; + }; + /** + * A set of edits to make in response to a refactor action, plus an optional + * location where renaming should be invoked from + */ + type RefactorEditInfo = { + edits: FileTextChanges[]; + renameFilename?: string; + renameLocation?: number; + }; interface TextInsertion { newText: string; /** The position in newText the caret should point to after the insertion. */ @@ -4007,6 +4379,7 @@ declare namespace ts { reportDiagnostics?: boolean; moduleName?: string; renamedDependencies?: MapLike; + transformers?: CustomTransformers; } interface TranspileOutput { outputText: string; diff --git a/lib/typescriptServices.js b/lib/typescriptServices.js index f6c9bb9d..7d2e6e11 100644 --- a/lib/typescriptServices.js +++ b/lib/typescriptServices.js @@ -1,18 +1,18 @@ -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */ - +/*! ***************************************************************************** +Copyright (c) Microsoft Corporation. All rights reserved. +Licensed under the Apache License, Version 2.0 (the "License"); you may not use +this file except in compliance with the License. You may obtain a copy of the +License at http://www.apache.org/licenses/LICENSE-2.0 + +THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED +WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, +MERCHANTABLITY OR NON-INFRINGEMENT. + +See the Apache Version 2.0 License for specific language governing permissions +and limitations under the License. +***************************************************************************** */ + var __assign = (this && this.__assign) || Object.assign || function(t) { for (var s, i = 1, n = arguments.length; i < n; i++) { s = arguments[i]; @@ -352,23 +352,25 @@ var ts; SyntaxKind[SyntaxKind["JSDocComment"] = 283] = "JSDocComment"; SyntaxKind[SyntaxKind["JSDocTag"] = 284] = "JSDocTag"; SyntaxKind[SyntaxKind["JSDocAugmentsTag"] = 285] = "JSDocAugmentsTag"; - SyntaxKind[SyntaxKind["JSDocParameterTag"] = 286] = "JSDocParameterTag"; - SyntaxKind[SyntaxKind["JSDocReturnTag"] = 287] = "JSDocReturnTag"; - SyntaxKind[SyntaxKind["JSDocTypeTag"] = 288] = "JSDocTypeTag"; - SyntaxKind[SyntaxKind["JSDocTemplateTag"] = 289] = "JSDocTemplateTag"; - SyntaxKind[SyntaxKind["JSDocTypedefTag"] = 290] = "JSDocTypedefTag"; - SyntaxKind[SyntaxKind["JSDocPropertyTag"] = 291] = "JSDocPropertyTag"; - SyntaxKind[SyntaxKind["JSDocTypeLiteral"] = 292] = "JSDocTypeLiteral"; - SyntaxKind[SyntaxKind["JSDocLiteralType"] = 293] = "JSDocLiteralType"; + SyntaxKind[SyntaxKind["JSDocClassTag"] = 286] = "JSDocClassTag"; + SyntaxKind[SyntaxKind["JSDocParameterTag"] = 287] = "JSDocParameterTag"; + SyntaxKind[SyntaxKind["JSDocReturnTag"] = 288] = "JSDocReturnTag"; + SyntaxKind[SyntaxKind["JSDocTypeTag"] = 289] = "JSDocTypeTag"; + SyntaxKind[SyntaxKind["JSDocTemplateTag"] = 290] = "JSDocTemplateTag"; + SyntaxKind[SyntaxKind["JSDocTypedefTag"] = 291] = "JSDocTypedefTag"; + SyntaxKind[SyntaxKind["JSDocPropertyTag"] = 292] = "JSDocPropertyTag"; + SyntaxKind[SyntaxKind["JSDocTypeLiteral"] = 293] = "JSDocTypeLiteral"; + SyntaxKind[SyntaxKind["JSDocLiteralType"] = 294] = "JSDocLiteralType"; // Synthesized list - SyntaxKind[SyntaxKind["SyntaxList"] = 294] = "SyntaxList"; + SyntaxKind[SyntaxKind["SyntaxList"] = 295] = "SyntaxList"; // Transformation nodes - SyntaxKind[SyntaxKind["NotEmittedStatement"] = 295] = "NotEmittedStatement"; - SyntaxKind[SyntaxKind["PartiallyEmittedExpression"] = 296] = "PartiallyEmittedExpression"; - SyntaxKind[SyntaxKind["MergeDeclarationMarker"] = 297] = "MergeDeclarationMarker"; - SyntaxKind[SyntaxKind["EndOfDeclarationMarker"] = 298] = "EndOfDeclarationMarker"; + SyntaxKind[SyntaxKind["NotEmittedStatement"] = 296] = "NotEmittedStatement"; + SyntaxKind[SyntaxKind["PartiallyEmittedExpression"] = 297] = "PartiallyEmittedExpression"; + SyntaxKind[SyntaxKind["CommaListExpression"] = 298] = "CommaListExpression"; + SyntaxKind[SyntaxKind["MergeDeclarationMarker"] = 299] = "MergeDeclarationMarker"; + SyntaxKind[SyntaxKind["EndOfDeclarationMarker"] = 300] = "EndOfDeclarationMarker"; // Enum value count - SyntaxKind[SyntaxKind["Count"] = 299] = "Count"; + SyntaxKind[SyntaxKind["Count"] = 301] = "Count"; // Markers SyntaxKind[SyntaxKind["FirstAssignment"] = 58] = "FirstAssignment"; SyntaxKind[SyntaxKind["LastAssignment"] = 70] = "LastAssignment"; @@ -396,9 +398,9 @@ var ts; SyntaxKind[SyntaxKind["LastBinaryOperator"] = 70] = "LastBinaryOperator"; SyntaxKind[SyntaxKind["FirstNode"] = 143] = "FirstNode"; SyntaxKind[SyntaxKind["FirstJSDocNode"] = 267] = "FirstJSDocNode"; - SyntaxKind[SyntaxKind["LastJSDocNode"] = 293] = "LastJSDocNode"; - SyntaxKind[SyntaxKind["FirstJSDocTagNode"] = 283] = "FirstJSDocTagNode"; - SyntaxKind[SyntaxKind["LastJSDocTagNode"] = 293] = "LastJSDocTagNode"; + SyntaxKind[SyntaxKind["LastJSDocNode"] = 294] = "LastJSDocNode"; + SyntaxKind[SyntaxKind["FirstJSDocTagNode"] = 284] = "FirstJSDocTagNode"; + SyntaxKind[SyntaxKind["LastJSDocTagNode"] = 294] = "LastJSDocTagNode"; })(SyntaxKind = ts.SyntaxKind || (ts.SyntaxKind = {})); var NodeFlags; (function (NodeFlags) { @@ -422,6 +424,16 @@ var ts; NodeFlags[NodeFlags["JavaScriptFile"] = 65536] = "JavaScriptFile"; NodeFlags[NodeFlags["ThisNodeOrAnySubNodesHasError"] = 131072] = "ThisNodeOrAnySubNodesHasError"; NodeFlags[NodeFlags["HasAggregatedChildData"] = 262144] = "HasAggregatedChildData"; + // This flag will be set when the parser encounters a dynamic import expression so that module resolution + // will not have to walk the tree if the flag is not set. However, this flag is just a approximation because + // once it is set, the flag never gets cleared (hence why it's named "PossiblyContainsDynamicImport"). + // During editing, if dynamic import is removed, incremental parsing will *NOT* update this flag. This means that the tree will always be traversed + // during module resolution. However, the removal operation should not occur often and in the case of the + // removal, it is likely that users will add the import anyway. + // The advantage of this approach is its simplicity. For the case of batch compilation, + // we guarantee that users won't have to pay the price of walking the tree if a dynamic import isn't used. + /* @internal */ + NodeFlags[NodeFlags["PossiblyContainsDynamicImport"] = 524288] = "PossiblyContainsDynamicImport"; NodeFlags[NodeFlags["BlockScoped"] = 3] = "BlockScoped"; NodeFlags[NodeFlags["ReachabilityCheckFlags"] = 384] = "ReachabilityCheckFlags"; NodeFlags[NodeFlags["ReachabilityAndEmitFlags"] = 1408] = "ReachabilityAndEmitFlags"; @@ -512,6 +524,13 @@ var ts; return OperationCanceledException; }()); ts.OperationCanceledException = OperationCanceledException; + /* @internal */ + var StructureIsReused; + (function (StructureIsReused) { + StructureIsReused[StructureIsReused["Not"] = 0] = "Not"; + StructureIsReused[StructureIsReused["SafeModules"] = 1] = "SafeModules"; + StructureIsReused[StructureIsReused["Completely"] = 2] = "Completely"; + })(StructureIsReused = ts.StructureIsReused || (ts.StructureIsReused = {})); /** Return code used by getEmitOutput function to indicate status of the function */ var ExitStatus; (function (ExitStatus) { @@ -527,29 +546,41 @@ var ts; var NodeBuilderFlags; (function (NodeBuilderFlags) { NodeBuilderFlags[NodeBuilderFlags["None"] = 0] = "None"; - NodeBuilderFlags[NodeBuilderFlags["allowThisInObjectLiteral"] = 1] = "allowThisInObjectLiteral"; - NodeBuilderFlags[NodeBuilderFlags["allowQualifedNameInPlaceOfIdentifier"] = 2] = "allowQualifedNameInPlaceOfIdentifier"; - NodeBuilderFlags[NodeBuilderFlags["allowTypeParameterInQualifiedName"] = 4] = "allowTypeParameterInQualifiedName"; - NodeBuilderFlags[NodeBuilderFlags["allowAnonymousIdentifier"] = 8] = "allowAnonymousIdentifier"; - NodeBuilderFlags[NodeBuilderFlags["allowEmptyUnionOrIntersection"] = 16] = "allowEmptyUnionOrIntersection"; - NodeBuilderFlags[NodeBuilderFlags["allowEmptyTuple"] = 32] = "allowEmptyTuple"; + // Options + NodeBuilderFlags[NodeBuilderFlags["NoTruncation"] = 1] = "NoTruncation"; + NodeBuilderFlags[NodeBuilderFlags["WriteArrayAsGenericType"] = 2] = "WriteArrayAsGenericType"; + NodeBuilderFlags[NodeBuilderFlags["WriteTypeArgumentsOfSignature"] = 32] = "WriteTypeArgumentsOfSignature"; + NodeBuilderFlags[NodeBuilderFlags["UseFullyQualifiedType"] = 64] = "UseFullyQualifiedType"; + NodeBuilderFlags[NodeBuilderFlags["SuppressAnyReturnType"] = 256] = "SuppressAnyReturnType"; + NodeBuilderFlags[NodeBuilderFlags["WriteTypeParametersInQualifiedName"] = 512] = "WriteTypeParametersInQualifiedName"; + // Error handling + NodeBuilderFlags[NodeBuilderFlags["AllowThisInObjectLiteral"] = 1024] = "AllowThisInObjectLiteral"; + NodeBuilderFlags[NodeBuilderFlags["AllowQualifedNameInPlaceOfIdentifier"] = 2048] = "AllowQualifedNameInPlaceOfIdentifier"; + NodeBuilderFlags[NodeBuilderFlags["AllowAnonymousIdentifier"] = 8192] = "AllowAnonymousIdentifier"; + NodeBuilderFlags[NodeBuilderFlags["AllowEmptyUnionOrIntersection"] = 16384] = "AllowEmptyUnionOrIntersection"; + NodeBuilderFlags[NodeBuilderFlags["AllowEmptyTuple"] = 32768] = "AllowEmptyTuple"; + NodeBuilderFlags[NodeBuilderFlags["IgnoreErrors"] = 60416] = "IgnoreErrors"; + // State + NodeBuilderFlags[NodeBuilderFlags["InObjectTypeLiteral"] = 1048576] = "InObjectTypeLiteral"; + NodeBuilderFlags[NodeBuilderFlags["InTypeAlias"] = 8388608] = "InTypeAlias"; })(NodeBuilderFlags = ts.NodeBuilderFlags || (ts.NodeBuilderFlags = {})); var TypeFormatFlags; (function (TypeFormatFlags) { TypeFormatFlags[TypeFormatFlags["None"] = 0] = "None"; TypeFormatFlags[TypeFormatFlags["WriteArrayAsGenericType"] = 1] = "WriteArrayAsGenericType"; - TypeFormatFlags[TypeFormatFlags["UseTypeOfFunction"] = 2] = "UseTypeOfFunction"; - TypeFormatFlags[TypeFormatFlags["NoTruncation"] = 4] = "NoTruncation"; - TypeFormatFlags[TypeFormatFlags["WriteArrowStyleSignature"] = 8] = "WriteArrowStyleSignature"; - TypeFormatFlags[TypeFormatFlags["WriteOwnNameForAnyLike"] = 16] = "WriteOwnNameForAnyLike"; - TypeFormatFlags[TypeFormatFlags["WriteTypeArgumentsOfSignature"] = 32] = "WriteTypeArgumentsOfSignature"; - TypeFormatFlags[TypeFormatFlags["InElementType"] = 64] = "InElementType"; - TypeFormatFlags[TypeFormatFlags["UseFullyQualifiedType"] = 128] = "UseFullyQualifiedType"; - TypeFormatFlags[TypeFormatFlags["InFirstTypeArgument"] = 256] = "InFirstTypeArgument"; - TypeFormatFlags[TypeFormatFlags["InTypeAlias"] = 512] = "InTypeAlias"; - TypeFormatFlags[TypeFormatFlags["UseTypeAliasValue"] = 1024] = "UseTypeAliasValue"; - TypeFormatFlags[TypeFormatFlags["SuppressAnyReturnType"] = 2048] = "SuppressAnyReturnType"; - TypeFormatFlags[TypeFormatFlags["AddUndefined"] = 4096] = "AddUndefined"; + TypeFormatFlags[TypeFormatFlags["UseTypeOfFunction"] = 4] = "UseTypeOfFunction"; + TypeFormatFlags[TypeFormatFlags["NoTruncation"] = 8] = "NoTruncation"; + TypeFormatFlags[TypeFormatFlags["WriteArrowStyleSignature"] = 16] = "WriteArrowStyleSignature"; + TypeFormatFlags[TypeFormatFlags["WriteOwnNameForAnyLike"] = 32] = "WriteOwnNameForAnyLike"; + TypeFormatFlags[TypeFormatFlags["WriteTypeArgumentsOfSignature"] = 64] = "WriteTypeArgumentsOfSignature"; + TypeFormatFlags[TypeFormatFlags["InElementType"] = 128] = "InElementType"; + TypeFormatFlags[TypeFormatFlags["UseFullyQualifiedType"] = 256] = "UseFullyQualifiedType"; + TypeFormatFlags[TypeFormatFlags["InFirstTypeArgument"] = 512] = "InFirstTypeArgument"; + TypeFormatFlags[TypeFormatFlags["InTypeAlias"] = 1024] = "InTypeAlias"; + TypeFormatFlags[TypeFormatFlags["UseTypeAliasValue"] = 2048] = "UseTypeAliasValue"; + TypeFormatFlags[TypeFormatFlags["SuppressAnyReturnType"] = 4096] = "SuppressAnyReturnType"; + TypeFormatFlags[TypeFormatFlags["AddUndefined"] = 8192] = "AddUndefined"; + TypeFormatFlags[TypeFormatFlags["WriteClassExpressionAsTypeLiteral"] = 16384] = "WriteClassExpressionAsTypeLiteral"; })(TypeFormatFlags = ts.TypeFormatFlags || (ts.TypeFormatFlags = {})); var SymbolFormatFlags; (function (SymbolFormatFlags) { @@ -677,6 +708,12 @@ var ts; SymbolFlags[SymbolFlags["Classifiable"] = 788448] = "Classifiable"; })(SymbolFlags = ts.SymbolFlags || (ts.SymbolFlags = {})); /* @internal */ + var EnumKind; + (function (EnumKind) { + EnumKind[EnumKind["Numeric"] = 0] = "Numeric"; + EnumKind[EnumKind["Literal"] = 1] = "Literal"; // Literal enum (each member has a TypeFlags.EnumLiteral type) + })(EnumKind = ts.EnumKind || (ts.EnumKind = {})); + /* @internal */ var CheckFlags; (function (CheckFlags) { CheckFlags[CheckFlags["Instantiated"] = 1] = "Instantiated"; @@ -751,7 +788,7 @@ var ts; TypeFlags[TypeFlags["JsxAttributes"] = 33554432] = "JsxAttributes"; /* @internal */ TypeFlags[TypeFlags["Nullable"] = 6144] = "Nullable"; - TypeFlags[TypeFlags["Literal"] = 480] = "Literal"; + TypeFlags[TypeFlags["Literal"] = 224] = "Literal"; TypeFlags[TypeFlags["StringOrNumberLiteral"] = 96] = "StringOrNumberLiteral"; /* @internal */ TypeFlags[TypeFlags["DefinitelyFalsy"] = 7392] = "DefinitelyFalsy"; @@ -761,7 +798,7 @@ var ts; /* @internal */ TypeFlags[TypeFlags["Primitive"] = 8190] = "Primitive"; TypeFlags[TypeFlags["StringLike"] = 262178] = "StringLike"; - TypeFlags[TypeFlags["NumberLike"] = 340] = "NumberLike"; + TypeFlags[TypeFlags["NumberLike"] = 84] = "NumberLike"; TypeFlags[TypeFlags["BooleanLike"] = 136] = "BooleanLike"; TypeFlags[TypeFlags["EnumLike"] = 272] = "EnumLike"; TypeFlags[TypeFlags["UnionOrIntersection"] = 196608] = "UnionOrIntersection"; @@ -770,7 +807,7 @@ var ts; TypeFlags[TypeFlags["TypeVariable"] = 540672] = "TypeVariable"; // 'Narrowable' types are types where narrowing actually narrows. // This *should* be every type other than null, undefined, void, and never - TypeFlags[TypeFlags["Narrowable"] = 17810431] = "Narrowable"; + TypeFlags[TypeFlags["Narrowable"] = 17810175] = "Narrowable"; TypeFlags[TypeFlags["NotUnionOrUnit"] = 16810497] = "NotUnionOrUnit"; /* @internal */ TypeFlags[TypeFlags["RequiresWidening"] = 6291456] = "RequiresWidening"; @@ -801,6 +838,18 @@ var ts; IndexKind[IndexKind["String"] = 0] = "String"; IndexKind[IndexKind["Number"] = 1] = "Number"; })(IndexKind = ts.IndexKind || (ts.IndexKind = {})); + var InferencePriority; + (function (InferencePriority) { + InferencePriority[InferencePriority["NakedTypeVariable"] = 1] = "NakedTypeVariable"; + InferencePriority[InferencePriority["MappedType"] = 2] = "MappedType"; + InferencePriority[InferencePriority["ReturnType"] = 4] = "ReturnType"; + })(InferencePriority = ts.InferencePriority || (ts.InferencePriority = {})); + var InferenceFlags; + (function (InferenceFlags) { + InferenceFlags[InferenceFlags["InferUnionTypes"] = 1] = "InferUnionTypes"; + InferenceFlags[InferenceFlags["NoDefault"] = 2] = "NoDefault"; + InferenceFlags[InferenceFlags["AnyDefault"] = 4] = "AnyDefault"; + })(InferenceFlags = ts.InferenceFlags || (ts.InferenceFlags = {})); /* @internal */ var SpecialPropertyAssignmentKind; (function (SpecialPropertyAssignmentKind) { @@ -835,6 +884,7 @@ var ts; ModuleKind[ModuleKind["UMD"] = 3] = "UMD"; ModuleKind[ModuleKind["System"] = 4] = "System"; ModuleKind[ModuleKind["ES2015"] = 5] = "ES2015"; + ModuleKind[ModuleKind["ESNext"] = 6] = "ESNext"; })(ModuleKind = ts.ModuleKind || (ts.ModuleKind = {})); var JsxEmit; (function (JsxEmit) { @@ -1057,6 +1107,10 @@ var ts; TransformFlags[TransformFlags["ContainsBindingPattern"] = 8388608] = "ContainsBindingPattern"; TransformFlags[TransformFlags["ContainsYield"] = 16777216] = "ContainsYield"; TransformFlags[TransformFlags["ContainsHoistedDeclarationOrCompletion"] = 33554432] = "ContainsHoistedDeclarationOrCompletion"; + TransformFlags[TransformFlags["ContainsDynamicImport"] = 67108864] = "ContainsDynamicImport"; + // Please leave this as 1 << 29. + // It is the maximum bit we can set before we outgrow the size of a v8 small integer (SMI) on an x86 system. + // It is a good reminder of how much room we have left TransformFlags[TransformFlags["HasComputedFlags"] = 536870912] = "HasComputedFlags"; // Assertions // - Bitmasks that are used to assert facts about the syntax of a node and its subtree. @@ -1119,6 +1173,7 @@ var ts; EmitFlags[EmitFlags["NoHoisting"] = 2097152] = "NoHoisting"; EmitFlags[EmitFlags["HasEndOfDeclarationMarker"] = 4194304] = "HasEndOfDeclarationMarker"; EmitFlags[EmitFlags["Iterator"] = 8388608] = "Iterator"; + EmitFlags[EmitFlags["NoAsciiEscaping"] = 16777216] = "NoAsciiEscaping"; })(EmitFlags = ts.EmitFlags || (ts.EmitFlags = {})); /** * Used by the checker, this enum keeps track of external emit helpers that should be type @@ -1142,6 +1197,7 @@ var ts; ExternalEmitHelpers[ExternalEmitHelpers["AsyncGenerator"] = 4096] = "AsyncGenerator"; ExternalEmitHelpers[ExternalEmitHelpers["AsyncDelegator"] = 8192] = "AsyncDelegator"; ExternalEmitHelpers[ExternalEmitHelpers["AsyncValues"] = 16384] = "AsyncValues"; + ExternalEmitHelpers[ExternalEmitHelpers["ExportStar"] = 32768] = "ExportStar"; // Helpers included by ES2015 for..of ExternalEmitHelpers[ExternalEmitHelpers["ForOfIncludes"] = 256] = "ForOfIncludes"; // Helpers included by ES2017 for..await..of @@ -1153,7 +1209,7 @@ var ts; // Helpers included by ES2015 spread ExternalEmitHelpers[ExternalEmitHelpers["SpreadIncludes"] = 1536] = "SpreadIncludes"; ExternalEmitHelpers[ExternalEmitHelpers["FirstEmitHelper"] = 1] = "FirstEmitHelper"; - ExternalEmitHelpers[ExternalEmitHelpers["LastEmitHelper"] = 16384] = "LastEmitHelper"; + ExternalEmitHelpers[ExternalEmitHelpers["LastEmitHelper"] = 32768] = "LastEmitHelper"; })(ExternalEmitHelpers = ts.ExternalEmitHelpers || (ts.ExternalEmitHelpers = {})); var EmitHint; (function (EmitHint) { @@ -1262,7 +1318,7 @@ var ts; var ts; (function (ts) { /** The version of the TypeScript compiler release */ - ts.version = "2.3.4"; + ts.version = "2.4.1"; })(ts || (ts = {})); /* @internal */ (function (ts) { @@ -1304,10 +1360,11 @@ var ts; var map = new MapCtr(); // Copies keys/values from template. Note that for..in will not throw if // template is undefined, and instead will just exit the loop. - for (var key in template) + for (var key in template) { if (hasOwnProperty.call(template, key)) { map.set(key, template[key]); } + } return map; } ts.createMapFromTemplate = createMapFromTemplate; @@ -1455,12 +1512,6 @@ var ts; return undefined; } ts.forEach = forEach; - /** - * Iterates through the parent chain of a node and performs the callback on each parent until the callback - * returns a truthy value, then returns that value. - * If no such value is found, it applies the callback until the parent pointer is undefined or the callback returns "quit" - * At that point findAncestor returns undefined. - */ function findAncestor(node, callback) { while (node) { var result = callback(node); @@ -1482,6 +1533,15 @@ var ts; } } ts.zipWith = zipWith; + function zipToMap(keys, values) { + Debug.assert(keys.length === values.length); + var map = createMap(); + for (var i = 0; i < keys.length; ++i) { + map.set(keys[i], values[i]); + } + return map; + } + ts.zipToMap = zipToMap; /** * Iterates through `array` by index and performs the callback on each element of array until the callback * returns a falsey value, then returns false. @@ -1709,6 +1769,47 @@ var ts; return result; } ts.flatMap = flatMap; + /** + * Maps an array. If the mapped value is an array, it is spread into the result. + * Avoids allocation if all elements map to themselves. + * + * @param array The array to map. + * @param mapfn The callback used to map the result into one or more values. + */ + function sameFlatMap(array, mapfn) { + var result; + if (array) { + for (var i = 0; i < array.length; i++) { + var item = array[i]; + var mapped = mapfn(item, i); + if (result || item !== mapped || isArray(mapped)) { + if (!result) { + result = array.slice(0, i); + } + if (isArray(mapped)) { + addRange(result, mapped); + } + else { + result.push(mapped); + } + } + } + } + return result || array; + } + ts.sameFlatMap = sameFlatMap; + function mapDefined(array, mapFn) { + var result = []; + for (var i = 0; i < array.length; i++) { + var item = array[i]; + var mapped = mapFn(item, i); + if (mapped !== undefined) { + result.push(mapped); + } + } + return result; + } + ts.mapDefined = mapDefined; /** * Computes the first matching span of elements and returns a tuple of the first span * and the remaining elements. @@ -1930,6 +2031,13 @@ var ts; return to; } ts.append = append; + /** + * Gets the actual offset into an array for a relative offset. Negative offsets indicate a + * position offset from the end of the array. + */ + function toOffset(array, offset) { + return offset < 0 ? array.length + offset : offset; + } /** * Appends a range of value to an array, returning the array. * @@ -1937,13 +2045,21 @@ var ts; * is created if `value` was appended. * @param from The values to append to the array. If `from` is `undefined`, nothing is * appended. If an element of `from` is `undefined`, that element is not appended. + * @param start The offset in `from` at which to start copying values. + * @param end The offset in `from` at which to stop copying values (non-inclusive). */ - function addRange(to, from) { + function addRange(to, from, start, end) { if (from === undefined) return to; - for (var _i = 0, from_1 = from; _i < from_1.length; _i++) { - var v = from_1[_i]; - to = append(to, v); + if (to === undefined) + return from.slice(start, end); + start = start === undefined ? 0 : toOffset(from, start); + end = end === undefined ? from.length : toOffset(from, end); + for (var i = start; i < end && i < from.length; i++) { + var v = from[i]; + if (v !== undefined) { + to.push(from[i]); + } } return to; } @@ -1969,22 +2085,32 @@ var ts; return true; } ts.rangeEquals = rangeEquals; + /** + * Returns the element at a specific offset in an array if non-empty, `undefined` otherwise. + * A negative offset indicates the element should be retrieved from the end of the array. + */ + function elementAt(array, offset) { + if (array) { + offset = toOffset(array, offset); + if (offset < array.length) { + return array[offset]; + } + } + return undefined; + } + ts.elementAt = elementAt; /** * Returns the first element of an array if non-empty, `undefined` otherwise. */ function firstOrUndefined(array) { - return array && array.length > 0 - ? array[0] - : undefined; + return elementAt(array, 0); } ts.firstOrUndefined = firstOrUndefined; /** * Returns the last element of an array if non-empty, `undefined` otherwise. */ function lastOrUndefined(array) { - return array && array.length > 0 - ? array[array.length - 1] - : undefined; + return elementAt(array, -1); } ts.lastOrUndefined = lastOrUndefined; /** @@ -2123,10 +2249,11 @@ var ts; */ function getOwnKeys(map) { var keys = []; - for (var key in map) + for (var key in map) { if (hasOwnProperty.call(map, key)) { keys.push(key); } + } return keys; } ts.getOwnKeys = getOwnKeys; @@ -2192,10 +2319,11 @@ var ts; } for (var _a = 0, args_1 = args; _a < args_1.length; _a++) { var arg = args_1[_a]; - for (var p in arg) + for (var p in arg) { if (hasProperty(arg, p)) { t[p] = arg[p]; } + } } return t; } @@ -2211,18 +2339,20 @@ var ts; return true; if (!left || !right) return false; - for (var key in left) + for (var key in left) { if (hasOwnProperty.call(left, key)) { if (!hasOwnProperty.call(right, key) === undefined) return false; if (equalityComparer ? !equalityComparer(left[key], right[key]) : left[key] !== right[key]) return false; } - for (var key in right) + } + for (var key in right) { if (hasOwnProperty.call(right, key)) { if (!hasOwnProperty.call(left, key)) return false; } + } return true; } ts.equalOwnProperties = equalOwnProperties; @@ -2253,14 +2383,16 @@ var ts; ts.clone = clone; function extend(first, second) { var result = {}; - for (var id in second) + for (var id in second) { if (hasOwnProperty.call(second, id)) { result[id] = second[id]; } - for (var id in first) + } + for (var id in first) { if (hasOwnProperty.call(first, id)) { result[id] = first[id]; } + } return result; } ts.extend = extend; @@ -2297,6 +2429,16 @@ var ts; return Array.isArray ? Array.isArray(value) : value instanceof Array; } ts.isArray = isArray; + function tryCast(value, test) { + return value !== undefined && test(value) ? value : undefined; + } + ts.tryCast = tryCast; + function cast(value, test) { + if (value !== undefined && test(value)) + return value; + Debug.fail("Invalid cast. The supplied value did not pass the test '" + Debug.getFunctionName(test) + "'."); + } + ts.cast = cast; /** Does nothing. */ function noop() { } ts.noop = noop; @@ -2886,6 +3028,11 @@ var ts; } ts.startsWith = startsWith; /* @internal */ + function removePrefix(str, prefix) { + return startsWith(str, prefix) ? str.substr(prefix.length) : str; + } + ts.removePrefix = removePrefix; + /* @internal */ function endsWith(str, suffix) { var expectedPos = str.length - suffix.length; return expectedPos >= 0 && str.indexOf(suffix, expectedPos) === expectedPos; @@ -2899,7 +3046,8 @@ var ts; return path.length > extension.length && endsWith(path, extension); } ts.fileExtensionIs = fileExtensionIs; - function fileExtensionIsAny(path, extensions) { + /* @internal */ + function fileExtensionIsOneOf(path, extensions) { for (var _i = 0, extensions_1 = extensions; _i < extensions_1.length; _i++) { var extension = extensions_1[_i]; if (fileExtensionIs(path, extension)) { @@ -2908,7 +3056,7 @@ var ts; } return false; } - ts.fileExtensionIsAny = fileExtensionIsAny; + ts.fileExtensionIsOneOf = fileExtensionIsOneOf; // Reserved characters, forces escaping of any non-word (or digit), non-whitespace character. // It may be inefficient (we could just match (/[-[\]{}()*+?.,\\^$|#\s]/g), but this is future // proof. @@ -3058,7 +3206,7 @@ var ts; var _loop_1 = function (current) { var name = combinePaths(path, current); var absoluteName = combinePaths(absolutePath, current); - if (extensions && !fileExtensionIsAny(name, extensions)) + if (extensions && !fileExtensionIsOneOf(name, extensions)) return "continue"; if (excludeRegex && excludeRegex.test(absoluteName)) return "continue"; @@ -3280,8 +3428,11 @@ var ts; this.name = name; this.declarations = undefined; } - function Type(_checker, flags) { + function Type(checker, flags) { this.flags = flags; + if (Debug.isDebugging) { + this.checker = checker; + } } function Signature() { } @@ -3296,6 +3447,11 @@ var ts; this.parent = undefined; this.original = undefined; } + function SourceMapSource(fileName, text, skipTrivia) { + this.fileName = fileName; + this.text = text; + this.skipTrivia = skipTrivia || (function (pos) { return pos; }); + } ts.objectAllocator = { getNodeConstructor: function () { return Node; }, getTokenConstructor: function () { return Node; }, @@ -3303,7 +3459,8 @@ var ts; getSourceFileConstructor: function () { return Node; }, getSymbolConstructor: function () { return Symbol; }, getTypeConstructor: function () { return Type; }, - getSignatureConstructor: function () { return Signature; } + getSignatureConstructor: function () { return Signature; }, + getSourceMapSourceConstructor: function () { return SourceMapSource; }, }; var AssertionLevel; (function (AssertionLevel) { @@ -3315,25 +3472,43 @@ var ts; var Debug; (function (Debug) { Debug.currentAssertionLevel = 0 /* None */; + Debug.isDebugging = false; function shouldAssert(level) { return Debug.currentAssertionLevel >= level; } Debug.shouldAssert = shouldAssert; - function assert(expression, message, verboseDebugInfo) { + function assert(expression, message, verboseDebugInfo, stackCrawlMark) { if (!expression) { - var verboseDebugString = ""; if (verboseDebugInfo) { - verboseDebugString = "\r\nVerbose Debug Information: " + verboseDebugInfo(); + message += "\r\nVerbose Debug Information: " + verboseDebugInfo(); } - debugger; - throw new Error("Debug Failure. False expression: " + (message || "") + verboseDebugString); + fail(message ? "False expression: " + message : "False expression.", stackCrawlMark || assert); } } Debug.assert = assert; - function fail(message) { - Debug.assert(/*expression*/ false, message); + function fail(message, stackCrawlMark) { + debugger; + var e = new Error(message ? "Debug Failure. " : "Debug Failure."); + if (Error.captureStackTrace) { + Error.captureStackTrace(e, stackCrawlMark || fail); + } + throw e; } Debug.fail = fail; + function getFunctionName(func) { + if (typeof func !== "function") { + return ""; + } + else if (func.hasOwnProperty("name")) { + return func.name; + } + else { + var text = Function.prototype.toString.call(func); + var match = /^function\s+([\w\$]+)\s*\(/.exec(text); + return match ? match[1] : ""; + } + } + Debug.getFunctionName = getFunctionName; })(Debug = ts.Debug || (ts.Debug = {})); /** Remove an item from an array, moving everything to its right one space left. */ function orderedRemoveItem(array, item) { @@ -3813,6 +3988,7 @@ var ts; realpath: function (path) { return _fs.realpathSync(path); }, + debugMode: ts.some(process.execArgv, function (arg) { return /^--(inspect|debug)(-brk)?(=\d+)?$/i.test(arg); }), tryEnableSourceMapsForHost: function () { try { require("source-map-support").install(); @@ -3897,6 +4073,9 @@ var ts; ? 1 /* Normal */ : 0 /* None */; } + if (ts.sys && ts.sys.debugMode) { + ts.Debug.isDebugging = true; + } })(ts || (ts = {})); // /// @@ -4063,6 +4242,7 @@ var ts; Line_terminator_not_permitted_before_arrow: { code: 1200, category: ts.DiagnosticCategory.Error, key: "Line_terminator_not_permitted_before_arrow_1200", message: "Line terminator not permitted before arrow." }, Import_assignment_cannot_be_used_when_targeting_ECMAScript_2015_modules_Consider_using_import_Asterisk_as_ns_from_mod_import_a_from_mod_import_d_from_mod_or_another_module_format_instead: { code: 1202, category: ts.DiagnosticCategory.Error, key: "Import_assignment_cannot_be_used_when_targeting_ECMAScript_2015_modules_Consider_using_import_Asteri_1202", message: "Import assignment cannot be used when targeting ECMAScript 2015 modules. Consider using 'import * as ns from \"mod\"', 'import {a} from \"mod\"', 'import d from \"mod\"', or another module format instead." }, Export_assignment_cannot_be_used_when_targeting_ECMAScript_2015_modules_Consider_using_export_default_or_another_module_format_instead: { code: 1203, category: ts.DiagnosticCategory.Error, key: "Export_assignment_cannot_be_used_when_targeting_ECMAScript_2015_modules_Consider_using_export_defaul_1203", message: "Export assignment cannot be used when targeting ECMAScript 2015 modules. Consider using 'export default' or another module format instead." }, + Cannot_re_export_a_type_when_the_isolatedModules_flag_is_provided: { code: 1205, category: ts.DiagnosticCategory.Error, key: "Cannot_re_export_a_type_when_the_isolatedModules_flag_is_provided_1205", message: "Cannot re-export a type when the '--isolatedModules' flag is provided." }, Decorators_are_not_valid_here: { code: 1206, category: ts.DiagnosticCategory.Error, key: "Decorators_are_not_valid_here_1206", message: "Decorators are not valid here." }, Decorators_cannot_be_applied_to_multiple_get_Slashset_accessors_of_the_same_name: { code: 1207, category: ts.DiagnosticCategory.Error, key: "Decorators_cannot_be_applied_to_multiple_get_Slashset_accessors_of_the_same_name_1207", message: "Decorators cannot be applied to multiple get/set accessors of the same name." }, Cannot_compile_namespaces_when_the_isolatedModules_flag_is_provided: { code: 1208, category: ts.DiagnosticCategory.Error, key: "Cannot_compile_namespaces_when_the_isolatedModules_flag_is_provided_1208", message: "Cannot compile namespaces when the '--isolatedModules' flag is provided." }, @@ -4124,6 +4304,10 @@ var ts; Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member: { code: 1320, category: ts.DiagnosticCategory.Error, key: "Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320", message: "Type of 'await' operand must either be a valid promise or must not contain a callable 'then' member." }, Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member: { code: 1321, category: ts.DiagnosticCategory.Error, key: "Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321", message: "Type of 'yield' operand in an async generator must either be a valid promise or must not contain a callable 'then' member." }, Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member: { code: 1322, category: ts.DiagnosticCategory.Error, key: "Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322", message: "Type of iterated elements of a 'yield*' operand must either be a valid promise or must not contain a callable 'then' member." }, + Dynamic_import_cannot_be_used_when_targeting_ECMAScript_2015_modules: { code: 1323, category: ts.DiagnosticCategory.Error, key: "Dynamic_import_cannot_be_used_when_targeting_ECMAScript_2015_modules_1323", message: "Dynamic import cannot be used when targeting ECMAScript 2015 modules." }, + Dynamic_import_must_have_one_specifier_as_an_argument: { code: 1324, category: ts.DiagnosticCategory.Error, key: "Dynamic_import_must_have_one_specifier_as_an_argument_1324", message: "Dynamic import must have one specifier as an argument." }, + Specifier_of_dynamic_import_cannot_be_spread_element: { code: 1325, category: ts.DiagnosticCategory.Error, key: "Specifier_of_dynamic_import_cannot_be_spread_element_1325", message: "Specifier of dynamic import cannot be spread element." }, + Dynamic_import_cannot_have_type_arguments: { code: 1326, category: ts.DiagnosticCategory.Error, key: "Dynamic_import_cannot_have_type_arguments_1326", message: "Dynamic import cannot have type arguments" }, Duplicate_identifier_0: { code: 2300, category: ts.DiagnosticCategory.Error, key: "Duplicate_identifier_0_2300", message: "Duplicate identifier '{0}'." }, Initializer_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor: { code: 2301, category: ts.DiagnosticCategory.Error, key: "Initializer_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2301", message: "Initializer of instance member variable '{0}' cannot reference identifier '{1}' declared in the constructor." }, Static_members_cannot_reference_class_type_parameters: { code: 2302, category: ts.DiagnosticCategory.Error, key: "Static_members_cannot_reference_class_type_parameters_2302", message: "Static members cannot reference class type parameters." }, @@ -4170,7 +4354,7 @@ var ts; This_syntax_requires_an_imported_helper_named_1_but_module_0_has_no_exported_member_1: { code: 2343, category: ts.DiagnosticCategory.Error, key: "This_syntax_requires_an_imported_helper_named_1_but_module_0_has_no_exported_member_1_2343", message: "This syntax requires an imported helper named '{1}', but module '{0}' has no exported member '{1}'." }, Type_0_does_not_satisfy_the_constraint_1: { code: 2344, category: ts.DiagnosticCategory.Error, key: "Type_0_does_not_satisfy_the_constraint_1_2344", message: "Type '{0}' does not satisfy the constraint '{1}'." }, Argument_of_type_0_is_not_assignable_to_parameter_of_type_1: { code: 2345, category: ts.DiagnosticCategory.Error, key: "Argument_of_type_0_is_not_assignable_to_parameter_of_type_1_2345", message: "Argument of type '{0}' is not assignable to parameter of type '{1}'." }, - Supplied_parameters_do_not_match_any_signature_of_call_target: { code: 2346, category: ts.DiagnosticCategory.Error, key: "Supplied_parameters_do_not_match_any_signature_of_call_target_2346", message: "Supplied parameters do not match any signature of call target." }, + Call_target_does_not_contain_any_signatures: { code: 2346, category: ts.DiagnosticCategory.Error, key: "Call_target_does_not_contain_any_signatures_2346", message: "Call target does not contain any signatures." }, Untyped_function_calls_may_not_accept_type_arguments: { code: 2347, category: ts.DiagnosticCategory.Error, key: "Untyped_function_calls_may_not_accept_type_arguments_2347", message: "Untyped function calls may not accept type arguments." }, Value_of_type_0_is_not_callable_Did_you_mean_to_include_new: { code: 2348, category: ts.DiagnosticCategory.Error, key: "Value_of_type_0_is_not_callable_Did_you_mean_to_include_new_2348", message: "Value of type '{0}' is not callable. Did you mean to include 'new'?" }, Cannot_invoke_an_expression_whose_type_lacks_a_call_signature_Type_0_has_no_compatible_call_signatures: { code: 2349, category: ts.DiagnosticCategory.Error, key: "Cannot_invoke_an_expression_whose_type_lacks_a_call_signature_Type_0_has_no_compatible_call_signatur_2349", message: "Cannot invoke an expression whose type lacks a call signature. Type '{0}' has no compatible call signatures." }, @@ -4365,6 +4549,15 @@ var ts; Type_0_is_not_an_array_type_or_does_not_have_a_Symbol_iterator_method_that_returns_an_iterator: { code: 2548, category: ts.DiagnosticCategory.Error, key: "Type_0_is_not_an_array_type_or_does_not_have_a_Symbol_iterator_method_that_returns_an_iterator_2548", message: "Type '{0}' is not an array type or does not have a '[Symbol.iterator]()' method that returns an iterator." }, Type_0_is_not_an_array_type_or_a_string_type_or_does_not_have_a_Symbol_iterator_method_that_returns_an_iterator: { code: 2549, category: ts.DiagnosticCategory.Error, key: "Type_0_is_not_an_array_type_or_a_string_type_or_does_not_have_a_Symbol_iterator_method_that_returns__2549", message: "Type '{0}' is not an array type or a string type or does not have a '[Symbol.iterator]()' method that returns an iterator." }, Generic_type_instantiation_is_excessively_deep_and_possibly_infinite: { code: 2550, category: ts.DiagnosticCategory.Error, key: "Generic_type_instantiation_is_excessively_deep_and_possibly_infinite_2550", message: "Generic type instantiation is excessively deep and possibly infinite." }, + Property_0_does_not_exist_on_type_1_Did_you_mean_2: { code: 2551, category: ts.DiagnosticCategory.Error, key: "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", message: "Property '{0}' does not exist on type '{1}'. Did you mean '{2}'?" }, + Cannot_find_name_0_Did_you_mean_1: { code: 2552, category: ts.DiagnosticCategory.Error, key: "Cannot_find_name_0_Did_you_mean_1_2552", message: "Cannot find name '{0}'. Did you mean '{1}'?" }, + Computed_values_are_not_permitted_in_an_enum_with_string_valued_members: { code: 2553, category: ts.DiagnosticCategory.Error, key: "Computed_values_are_not_permitted_in_an_enum_with_string_valued_members_2553", message: "Computed values are not permitted in an enum with string valued members." }, + Expected_0_arguments_but_got_1: { code: 2554, category: ts.DiagnosticCategory.Error, key: "Expected_0_arguments_but_got_1_2554", message: "Expected {0} arguments, but got {1}." }, + Expected_at_least_0_arguments_but_got_1: { code: 2555, category: ts.DiagnosticCategory.Error, key: "Expected_at_least_0_arguments_but_got_1_2555", message: "Expected at least {0} arguments, but got {1}." }, + Expected_0_arguments_but_got_a_minimum_of_1: { code: 2556, category: ts.DiagnosticCategory.Error, key: "Expected_0_arguments_but_got_a_minimum_of_1_2556", message: "Expected {0} arguments, but got a minimum of {1}." }, + Expected_at_least_0_arguments_but_got_a_minimum_of_1: { code: 2557, category: ts.DiagnosticCategory.Error, key: "Expected_at_least_0_arguments_but_got_a_minimum_of_1_2557", message: "Expected at least {0} arguments, but got a minimum of {1}." }, + Expected_0_type_arguments_but_got_1: { code: 2558, category: ts.DiagnosticCategory.Error, key: "Expected_0_type_arguments_but_got_1_2558", message: "Expected {0} type arguments, but got {1}." }, + Type_0_has_no_properties_in_common_with_type_1: { code: 2559, category: ts.DiagnosticCategory.Error, key: "Type_0_has_no_properties_in_common_with_type_1_2559", message: "Type '{0}' has no properties in common with type '{1}'." }, JSX_element_attributes_type_0_may_not_be_a_union_type: { code: 2600, category: ts.DiagnosticCategory.Error, key: "JSX_element_attributes_type_0_may_not_be_a_union_type_2600", message: "JSX element attributes type '{0}' may not be a union type." }, The_return_type_of_a_JSX_element_constructor_must_return_an_object_type: { code: 2601, category: ts.DiagnosticCategory.Error, key: "The_return_type_of_a_JSX_element_constructor_must_return_an_object_type_2601", message: "The return type of a JSX element constructor must return an object type." }, JSX_element_implicitly_has_type_any_because_the_global_type_JSX_Element_does_not_exist: { code: 2602, category: ts.DiagnosticCategory.Error, key: "JSX_element_implicitly_has_type_any_because_the_global_type_JSX_Element_does_not_exist_2602", message: "JSX element implicitly has type 'any' because the global type 'JSX.Element' does not exist." }, @@ -4376,7 +4569,6 @@ var ts; The_global_type_JSX_0_may_not_have_more_than_one_property: { code: 2608, category: ts.DiagnosticCategory.Error, key: "The_global_type_JSX_0_may_not_have_more_than_one_property_2608", message: "The global type 'JSX.{0}' may not have more than one property." }, JSX_spread_child_must_be_an_array_type: { code: 2609, category: ts.DiagnosticCategory.Error, key: "JSX_spread_child_must_be_an_array_type_2609", message: "JSX spread child must be an array type." }, Cannot_augment_module_0_with_value_exports_because_it_resolves_to_a_non_module_entity: { code: 2649, category: ts.DiagnosticCategory.Error, key: "Cannot_augment_module_0_with_value_exports_because_it_resolves_to_a_non_module_entity_2649", message: "Cannot augment module '{0}' with value exports because it resolves to a non-module entity." }, - Cannot_emit_namespaced_JSX_elements_in_React: { code: 2650, category: ts.DiagnosticCategory.Error, key: "Cannot_emit_namespaced_JSX_elements_in_React_2650", message: "Cannot emit namespaced JSX elements in React." }, A_member_initializer_in_a_enum_declaration_cannot_reference_members_declared_after_it_including_members_defined_in_other_enums: { code: 2651, category: ts.DiagnosticCategory.Error, key: "A_member_initializer_in_a_enum_declaration_cannot_reference_members_declared_after_it_including_memb_2651", message: "A member initializer in a enum declaration cannot reference members declared after it, including members defined in other enums." }, Merged_declaration_0_cannot_include_a_default_export_declaration_Consider_adding_a_separate_export_default_0_declaration_instead: { code: 2652, category: ts.DiagnosticCategory.Error, key: "Merged_declaration_0_cannot_include_a_default_export_declaration_Consider_adding_a_separate_export_d_2652", message: "Merged declaration '{0}' cannot include a default export declaration. Consider adding a separate 'export default {0}' declaration instead." }, Non_abstract_class_expression_does_not_implement_inherited_abstract_member_0_from_class_1: { code: 2653, category: ts.DiagnosticCategory.Error, key: "Non_abstract_class_expression_does_not_implement_inherited_abstract_member_0_from_class_1_2653", message: "Non-abstract class expression does not implement inherited abstract member '{0}' from class '{1}'." }, @@ -4435,6 +4627,8 @@ var ts; Cannot_use_namespace_0_as_a_value: { code: 2708, category: ts.DiagnosticCategory.Error, key: "Cannot_use_namespace_0_as_a_value_2708", message: "Cannot use namespace '{0}' as a value." }, Cannot_use_namespace_0_as_a_type: { code: 2709, category: ts.DiagnosticCategory.Error, key: "Cannot_use_namespace_0_as_a_type_2709", message: "Cannot use namespace '{0}' as a type." }, _0_are_specified_twice_The_attribute_named_0_will_be_overwritten: { code: 2710, category: ts.DiagnosticCategory.Error, key: "_0_are_specified_twice_The_attribute_named_0_will_be_overwritten_2710", message: "'{0}' are specified twice. The attribute named '{0}' will be overwritten." }, + A_dynamic_import_call_returns_a_Promise_Make_sure_you_have_a_declaration_for_Promise_or_include_ES2015_in_your_lib_option: { code: 2711, category: ts.DiagnosticCategory.Error, key: "A_dynamic_import_call_returns_a_Promise_Make_sure_you_have_a_declaration_for_Promise_or_include_ES20_2711", message: "A dynamic import call returns a 'Promise'. Make sure you have a declaration for 'Promise' or include 'ES2015' in your `--lib` option." }, + A_dynamic_import_call_in_ES5_SlashES3_requires_the_Promise_constructor_Make_sure_you_have_a_declaration_for_the_Promise_constructor_or_include_ES2015_in_your_lib_option: { code: 2712, category: ts.DiagnosticCategory.Error, key: "A_dynamic_import_call_in_ES5_SlashES3_requires_the_Promise_constructor_Make_sure_you_have_a_declarat_2712", message: "A dynamic import call in ES5/ES3 requires the 'Promise' constructor. Make sure you have a declaration for the 'Promise' constructor or include 'ES2015' in your `--lib` option." }, Import_declaration_0_is_using_private_name_1: { code: 4000, category: ts.DiagnosticCategory.Error, key: "Import_declaration_0_is_using_private_name_1_4000", message: "Import declaration '{0}' is using private name '{1}'." }, Type_parameter_0_of_exported_class_has_or_is_using_private_name_1: { code: 4002, category: ts.DiagnosticCategory.Error, key: "Type_parameter_0_of_exported_class_has_or_is_using_private_name_1_4002", message: "Type parameter '{0}' of exported class has or is using private name '{1}'." }, Type_parameter_0_of_exported_interface_has_or_is_using_private_name_1: { code: 4004, category: ts.DiagnosticCategory.Error, key: "Type_parameter_0_of_exported_interface_has_or_is_using_private_name_1_4004", message: "Type parameter '{0}' of exported interface has or is using private name '{1}'." }, @@ -4509,7 +4703,7 @@ var ts; Conflicting_definitions_for_0_found_at_1_and_2_Consider_installing_a_specific_version_of_this_library_to_resolve_the_conflict: { code: 4090, category: ts.DiagnosticCategory.Message, key: "Conflicting_definitions_for_0_found_at_1_and_2_Consider_installing_a_specific_version_of_this_librar_4090", message: "Conflicting definitions for '{0}' found at '{1}' and '{2}'. Consider installing a specific version of this library to resolve the conflict." }, Parameter_0_of_index_signature_from_exported_interface_has_or_is_using_name_1_from_private_module_2: { code: 4091, category: ts.DiagnosticCategory.Error, key: "Parameter_0_of_index_signature_from_exported_interface_has_or_is_using_name_1_from_private_module_2_4091", message: "Parameter '{0}' of index signature from exported interface has or is using name '{1}' from private module '{2}'." }, Parameter_0_of_index_signature_from_exported_interface_has_or_is_using_private_name_1: { code: 4092, category: ts.DiagnosticCategory.Error, key: "Parameter_0_of_index_signature_from_exported_interface_has_or_is_using_private_name_1_4092", message: "Parameter '{0}' of index signature from exported interface has or is using private name '{1}'." }, - extends_clause_of_exported_class_0_refers_to_a_type_whose_name_cannot_be_referenced: { code: 4093, category: ts.DiagnosticCategory.Error, key: "extends_clause_of_exported_class_0_refers_to_a_type_whose_name_cannot_be_referenced_4093", message: "'extends' clause of exported class '{0}' refers to a type whose name cannot be referenced." }, + Property_0_of_exported_class_expression_may_not_be_private_or_protected: { code: 4094, category: ts.DiagnosticCategory.Error, key: "Property_0_of_exported_class_expression_may_not_be_private_or_protected_4094", message: "Property '{0}' of exported class expression may not be private or protected." }, The_current_host_does_not_support_the_0_option: { code: 5001, category: ts.DiagnosticCategory.Error, key: "The_current_host_does_not_support_the_0_option_5001", message: "The current host does not support the '{0}' option." }, Cannot_find_the_common_subdirectory_path_for_the_input_files: { code: 5009, category: ts.DiagnosticCategory.Error, key: "Cannot_find_the_common_subdirectory_path_for_the_input_files_5009", message: "Cannot find the common subdirectory path for the input files." }, File_specification_cannot_end_in_a_recursive_directory_wildcard_Asterisk_Asterisk_Colon_0: { code: 5010, category: ts.DiagnosticCategory.Error, key: "File_specification_cannot_end_in_a_recursive_directory_wildcard_Asterisk_Asterisk_Colon_0_5010", message: "File specification cannot end in a recursive directory wildcard ('**'): '{0}'." }, @@ -4551,7 +4745,7 @@ var ts; Allow_default_imports_from_modules_with_no_default_export_This_does_not_affect_code_emit_just_typechecking: { code: 6011, category: ts.DiagnosticCategory.Message, key: "Allow_default_imports_from_modules_with_no_default_export_This_does_not_affect_code_emit_just_typech_6011", message: "Allow default imports from modules with no default export. This does not affect code emit, just typechecking." }, Skip_type_checking_of_declaration_files: { code: 6012, category: ts.DiagnosticCategory.Message, key: "Skip_type_checking_of_declaration_files_6012", message: "Skip type checking of declaration files." }, Specify_ECMAScript_target_version_Colon_ES3_default_ES5_ES2015_ES2016_ES2017_or_ESNEXT: { code: 6015, category: ts.DiagnosticCategory.Message, key: "Specify_ECMAScript_target_version_Colon_ES3_default_ES5_ES2015_ES2016_ES2017_or_ESNEXT_6015", message: "Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', or 'ESNEXT'." }, - Specify_module_code_generation_Colon_commonjs_amd_system_umd_or_es2015: { code: 6016, category: ts.DiagnosticCategory.Message, key: "Specify_module_code_generation_Colon_commonjs_amd_system_umd_or_es2015_6016", message: "Specify module code generation: 'commonjs', 'amd', 'system', 'umd' or 'es2015'." }, + Specify_module_code_generation_Colon_commonjs_amd_system_umd_es2015_or_ESNext: { code: 6016, category: ts.DiagnosticCategory.Message, key: "Specify_module_code_generation_Colon_commonjs_amd_system_umd_es2015_or_ESNext_6016", message: "Specify module code generation: 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'." }, Print_this_message: { code: 6017, category: ts.DiagnosticCategory.Message, key: "Print_this_message_6017", message: "Print this message." }, Print_the_compiler_s_version: { code: 6019, category: ts.DiagnosticCategory.Message, key: "Print_the_compiler_s_version_6019", message: "Print the compiler's version." }, Compile_the_project_given_the_path_to_its_configuration_file_or_to_a_folder_with_a_tsconfig_json: { code: 6020, category: ts.DiagnosticCategory.Message, key: "Compile_the_project_given_the_path_to_its_configuration_file_or_to_a_folder_with_a_tsconfig_json_6020", message: "Compile the project given the path to its configuration file, or to a folder with a 'tsconfig.json'." }, @@ -4660,6 +4854,7 @@ var ts; Report_errors_on_unused_locals: { code: 6134, category: ts.DiagnosticCategory.Message, key: "Report_errors_on_unused_locals_6134", message: "Report errors on unused locals." }, Report_errors_on_unused_parameters: { code: 6135, category: ts.DiagnosticCategory.Message, key: "Report_errors_on_unused_parameters_6135", message: "Report errors on unused parameters." }, The_maximum_dependency_depth_to_search_under_node_modules_and_load_JavaScript_files: { code: 6136, category: ts.DiagnosticCategory.Message, key: "The_maximum_dependency_depth_to_search_under_node_modules_and_load_JavaScript_files_6136", message: "The maximum dependency depth to search under node_modules and load JavaScript files." }, + Cannot_import_type_declaration_files_Consider_importing_0_instead_of_1: { code: 6137, category: ts.DiagnosticCategory.Error, key: "Cannot_import_type_declaration_files_Consider_importing_0_instead_of_1_6137", message: "Cannot import type declaration files. Consider importing '{0}' instead of '{1}'." }, Property_0_is_declared_but_never_used: { code: 6138, category: ts.DiagnosticCategory.Error, key: "Property_0_is_declared_but_never_used_6138", message: "Property '{0}' is declared but never used." }, Import_emit_helpers_from_tslib: { code: 6139, category: ts.DiagnosticCategory.Message, key: "Import_emit_helpers_from_tslib_6139", message: "Import emit helpers from 'tslib'." }, Auto_discovery_for_typings_is_enabled_in_project_0_Running_extra_resolution_pass_for_module_1_using_cache_location_2: { code: 6140, category: ts.DiagnosticCategory.Error, key: "Auto_discovery_for_typings_is_enabled_in_project_0_Running_extra_resolution_pass_for_module_1_using__6140", message: "Auto discovery for typings is enabled in project '{0}'. Running extra resolution pass for module '{1}' using cache location '{2}'." }, @@ -4705,6 +4900,9 @@ var ts; Enable_all_strict_type_checking_options: { code: 6180, category: ts.DiagnosticCategory.Message, key: "Enable_all_strict_type_checking_options_6180", message: "Enable all strict type-checking options." }, List_of_language_service_plugins: { code: 6181, category: ts.DiagnosticCategory.Message, key: "List_of_language_service_plugins_6181", message: "List of language service plugins." }, Scoped_package_detected_looking_in_0: { code: 6182, category: ts.DiagnosticCategory.Message, key: "Scoped_package_detected_looking_in_0_6182", message: "Scoped package detected, looking in '{0}'" }, + Reusing_resolution_of_module_0_to_file_1_from_old_program: { code: 6183, category: ts.DiagnosticCategory.Message, key: "Reusing_resolution_of_module_0_to_file_1_from_old_program_6183", message: "Reusing resolution of module '{0}' to file '{1}' from old program." }, + Reusing_module_resolutions_originating_in_0_since_resolutions_are_unchanged_from_old_program: { code: 6184, category: ts.DiagnosticCategory.Message, key: "Reusing_module_resolutions_originating_in_0_since_resolutions_are_unchanged_from_old_program_6184", message: "Reusing module resolutions originating in '{0}' since resolutions are unchanged from old program." }, + Disable_strict_checking_of_generic_signatures_in_function_types: { code: 6185, category: ts.DiagnosticCategory.Message, key: "Disable_strict_checking_of_generic_signatures_in_function_types_6185", message: "Disable strict checking of generic signatures in function types." }, Variable_0_implicitly_has_an_1_type: { code: 7005, category: ts.DiagnosticCategory.Error, key: "Variable_0_implicitly_has_an_1_type_7005", message: "Variable '{0}' implicitly has an '{1}' type." }, Parameter_0_implicitly_has_an_1_type: { code: 7006, category: ts.DiagnosticCategory.Error, key: "Parameter_0_implicitly_has_an_1_type_7006", message: "Parameter '{0}' implicitly has an '{1}' type." }, Member_0_implicitly_has_an_1_type: { code: 7008, category: ts.DiagnosticCategory.Error, key: "Member_0_implicitly_has_an_1_type_7008", message: "Member '{0}' implicitly has an '{1}' type." }, @@ -4731,6 +4929,8 @@ var ts; Property_0_implicitly_has_type_any_because_its_set_accessor_lacks_a_parameter_type_annotation: { code: 7032, category: ts.DiagnosticCategory.Error, key: "Property_0_implicitly_has_type_any_because_its_set_accessor_lacks_a_parameter_type_annotation_7032", message: "Property '{0}' implicitly has type 'any', because its set accessor lacks a parameter type annotation." }, Property_0_implicitly_has_type_any_because_its_get_accessor_lacks_a_return_type_annotation: { code: 7033, category: ts.DiagnosticCategory.Error, key: "Property_0_implicitly_has_type_any_because_its_get_accessor_lacks_a_return_type_annotation_7033", message: "Property '{0}' implicitly has type 'any', because its get accessor lacks a return type annotation." }, Variable_0_implicitly_has_type_1_in_some_locations_where_its_type_cannot_be_determined: { code: 7034, category: ts.DiagnosticCategory.Error, key: "Variable_0_implicitly_has_type_1_in_some_locations_where_its_type_cannot_be_determined_7034", message: "Variable '{0}' implicitly has type '{1}' in some locations where its type cannot be determined." }, + Try_npm_install_types_Slash_0_if_it_exists_or_add_a_new_declaration_d_ts_file_containing_declare_module_0: { code: 7035, category: ts.DiagnosticCategory.Error, key: "Try_npm_install_types_Slash_0_if_it_exists_or_add_a_new_declaration_d_ts_file_containing_declare_mod_7035", message: "Try `npm install @types/{0}` if it exists or add a new declaration (.d.ts) file containing `declare module '{0}';`" }, + Dynamic_import_s_specifier_must_be_of_type_string_but_here_has_type_0: { code: 7036, category: ts.DiagnosticCategory.Error, key: "Dynamic_import_s_specifier_must_be_of_type_string_but_here_has_type_0_7036", message: "Dynamic import's specifier must be of type 'string', but here has type '{0}'." }, You_cannot_rename_this_element: { code: 8000, category: ts.DiagnosticCategory.Error, key: "You_cannot_rename_this_element_8000", message: "You cannot rename this element." }, You_cannot_rename_elements_that_are_defined_in_the_standard_TypeScript_library: { code: 8001, category: ts.DiagnosticCategory.Error, key: "You_cannot_rename_elements_that_are_defined_in_the_standard_TypeScript_library_8001", message: "You cannot rename elements that are defined in the standard TypeScript library." }, import_can_only_be_used_in_a_ts_file: { code: 8002, category: ts.DiagnosticCategory.Error, key: "import_can_only_be_used_in_a_ts_file_8002", message: "'import ... =' can only be used in a .ts file." }, @@ -4779,12 +4979,18 @@ var ts; Import_0_from_1: { code: 90013, category: ts.DiagnosticCategory.Message, key: "Import_0_from_1_90013", message: "Import {0} from {1}." }, Change_0_to_1: { code: 90014, category: ts.DiagnosticCategory.Message, key: "Change_0_to_1_90014", message: "Change {0} to {1}." }, Add_0_to_existing_import_declaration_from_1: { code: 90015, category: ts.DiagnosticCategory.Message, key: "Add_0_to_existing_import_declaration_from_1_90015", message: "Add {0} to existing import declaration from {1}." }, - Add_declaration_for_missing_property_0: { code: 90016, category: ts.DiagnosticCategory.Message, key: "Add_declaration_for_missing_property_0_90016", message: "Add declaration for missing property '{0}'." }, - Add_index_signature_for_missing_property_0: { code: 90017, category: ts.DiagnosticCategory.Message, key: "Add_index_signature_for_missing_property_0_90017", message: "Add index signature for missing property '{0}'." }, + Declare_property_0: { code: 90016, category: ts.DiagnosticCategory.Message, key: "Declare_property_0_90016", message: "Declare property '{0}'." }, + Add_index_signature_for_property_0: { code: 90017, category: ts.DiagnosticCategory.Message, key: "Add_index_signature_for_property_0_90017", message: "Add index signature for property '{0}'." }, Disable_checking_for_this_file: { code: 90018, category: ts.DiagnosticCategory.Message, key: "Disable_checking_for_this_file_90018", message: "Disable checking for this file." }, Ignore_this_error_message: { code: 90019, category: ts.DiagnosticCategory.Message, key: "Ignore_this_error_message_90019", message: "Ignore this error message." }, Initialize_property_0_in_the_constructor: { code: 90020, category: ts.DiagnosticCategory.Message, key: "Initialize_property_0_in_the_constructor_90020", message: "Initialize property '{0}' in the constructor." }, Initialize_static_property_0: { code: 90021, category: ts.DiagnosticCategory.Message, key: "Initialize_static_property_0_90021", message: "Initialize static property '{0}'." }, + Change_spelling_to_0: { code: 90022, category: ts.DiagnosticCategory.Message, key: "Change_spelling_to_0_90022", message: "Change spelling to '{0}'." }, + Declare_method_0: { code: 90023, category: ts.DiagnosticCategory.Message, key: "Declare_method_0_90023", message: "Declare method '{0}'." }, + Declare_static_method_0: { code: 90024, category: ts.DiagnosticCategory.Message, key: "Declare_static_method_0_90024", message: "Declare static method '{0}'." }, + Prefix_0_with_an_underscore: { code: 90025, category: ts.DiagnosticCategory.Message, key: "Prefix_0_with_an_underscore_90025", message: "Prefix '{0}' with an underscore." }, + Convert_function_to_an_ES2015_class: { code: 95001, category: ts.DiagnosticCategory.Message, key: "Convert_function_to_an_ES2015_class_95001", message: "Convert function to an ES2015 class" }, + Convert_function_0_to_class: { code: 95002, category: ts.DiagnosticCategory.Message, key: "Convert_function_0_to_class_95002", message: "Convert function '{0}' to class" }, Octal_literal_types_must_use_ES2015_syntax_Use_the_syntax_0: { code: 8017, category: ts.DiagnosticCategory.Error, key: "Octal_literal_types_must_use_ES2015_syntax_Use_the_syntax_0_8017", message: "Octal literal types must use ES2015 syntax. Use the syntax '{0}'." }, Octal_literals_are_not_allowed_in_enums_members_initializer_Use_the_syntax_0: { code: 8018, category: ts.DiagnosticCategory.Error, key: "Octal_literals_are_not_allowed_in_enums_members_initializer_Use_the_syntax_0_8018", message: "Octal literals are not allowed in enums members initializer. Use the syntax '{0}'." }, Report_errors_in_js_files: { code: 8019, category: ts.DiagnosticCategory.Message, key: "Report_errors_in_js_files_8019", message: "Report errors in .js files." }, @@ -5157,6 +5363,7 @@ var ts; case 47 /* slash */: // starts of normal trivia case 60 /* lessThan */: + case 124 /* bar */: case 61 /* equals */: case 62 /* greaterThan */: // Starts of conflict marker trivia @@ -5223,6 +5430,7 @@ var ts; } break; case 60 /* lessThan */: + case 124 /* bar */: case 61 /* equals */: case 62 /* greaterThan */: if (isConflictMarkerTrivia(text, pos)) { @@ -5279,12 +5487,12 @@ var ts; } } else { - ts.Debug.assert(ch === 61 /* equals */); - // Consume everything from the start of the mid-conflict marker to the start of the next - // end-conflict marker. + ts.Debug.assert(ch === 124 /* bar */ || ch === 61 /* equals */); + // Consume everything from the start of a ||||||| or ======= marker to the start + // of the next ======= or >>>>>>> marker. while (pos < len) { - var ch_1 = text.charCodeAt(pos); - if (ch_1 === 62 /* greaterThan */ && isConflictMarkerTrivia(text, pos)) { + var currentChar = text.charCodeAt(pos); + if ((currentChar === 61 /* equals */ || currentChar === 62 /* greaterThan */) && currentChar !== ch && isConflictMarkerTrivia(text, pos)) { break; } pos++; @@ -5447,9 +5655,10 @@ var ts; ts.getTrailingCommentRanges = getTrailingCommentRanges; /** Optionally, get the shebang */ function getShebang(text) { - return shebangTriviaRegex.test(text) - ? shebangTriviaRegex.exec(text)[0] - : undefined; + var match = shebangTriviaRegex.exec(text); + if (match) { + return match[0]; + } } ts.getShebang = getShebang; function isIdentifierStart(ch, languageVersion) { @@ -6030,13 +6239,13 @@ var ts; pos += 2; var commentClosed = false; while (pos < end) { - var ch_2 = text.charCodeAt(pos); - if (ch_2 === 42 /* asterisk */ && text.charCodeAt(pos + 1) === 47 /* slash */) { + var ch_1 = text.charCodeAt(pos); + if (ch_1 === 42 /* asterisk */ && text.charCodeAt(pos + 1) === 47 /* slash */) { pos += 2; commentClosed = true; break; } - if (isLineBreak(ch_2)) { + if (isLineBreak(ch_1)) { precedingLineBreak = true; } pos++; @@ -6196,6 +6405,15 @@ var ts; pos++; return token = 17 /* OpenBraceToken */; case 124 /* bar */: + if (isConflictMarkerTrivia(text, pos)) { + pos = scanConflictMarkerTrivia(text, pos, error); + if (skipTrivia) { + continue; + } + else { + return token = 7 /* ConflictMarkerTrivia */; + } + } if (text.charCodeAt(pos + 1) === 124 /* bar */) { return pos += 2, token = 54 /* BarBarToken */; } @@ -6607,7 +6825,7 @@ var ts; clear: function () { return str_1 = ""; }, trackSymbol: ts.noop, reportInaccessibleThisError: ts.noop, - reportIllegalExtends: ts.noop + reportPrivateInBaseOfClassExpression: ts.noop, }; } return stringWriters.pop(); @@ -6658,9 +6876,7 @@ var ts; ts.typeDirectiveIsEqualTo = typeDirectiveIsEqualTo; /* @internal */ function hasChangesInResolutions(names, newResolutions, oldResolutions, comparer) { - if (names.length !== newResolutions.length) { - return false; - } + ts.Debug.assert(names.length === newResolutions.length); for (var i = 0; i < names.length; i++) { var newResolution = newResolutions[i]; var oldResolution = oldResolutions && oldResolutions.get(names[i]); @@ -6785,17 +7001,13 @@ var ts; return !nodeIsMissing(node); } ts.nodeIsPresent = nodeIsPresent; - function isToken(n) { - return n.kind >= 0 /* FirstToken */ && n.kind <= 142 /* LastToken */; - } - ts.isToken = isToken; function getTokenPosOfNode(node, sourceFile, includeJsDoc) { // With nodes that have no width (i.e. 'Missing' nodes), we actually *don't* // want to skip trivia because this will launch us forward to the next token. if (nodeIsMissing(node)) { return node.pos; } - if (isJSDocNode(node)) { + if (ts.isJSDocNode(node)) { return ts.skipTrivia((sourceFile || getSourceFileOfNode(node)).text, node.pos, /*stopAfterLineBreak*/ false, /*stopAtComments*/ true); } if (includeJsDoc && node.jsDoc && node.jsDoc.length > 0) { @@ -6805,20 +7017,12 @@ var ts; // the syntax list itself considers them as normal trivia. Therefore if we simply skip // trivia for the list, we may have skipped the JSDocComment as well. So we should process its // first child to determine the actual position of its first token. - if (node.kind === 294 /* SyntaxList */ && node._children.length > 0) { + if (node.kind === 295 /* SyntaxList */ && node._children.length > 0) { return getTokenPosOfNode(node._children[0], sourceFile, includeJsDoc); } return ts.skipTrivia((sourceFile || getSourceFileOfNode(node)).text, node.pos); } ts.getTokenPosOfNode = getTokenPosOfNode; - function isJSDocNode(node) { - return node.kind >= 267 /* FirstJSDocNode */ && node.kind <= 293 /* LastJSDocNode */; - } - ts.isJSDocNode = isJSDocNode; - function isJSDocTag(node) { - return node.kind >= 283 /* FirstJSDocTagNode */ && node.kind <= 293 /* LastJSDocTagNode */; - } - ts.isJSDocTag = isJSDocTag; function getNonDecoratorTokenPosOfNode(node, sourceFile) { if (nodeIsMissing(node) || !node.decorators) { return getTokenPosOfNode(node, sourceFile); @@ -6853,28 +7057,30 @@ var ts; if (!nodeIsSynthesized(node) && node.parent) { return getSourceTextOfNodeFromSourceFile(sourceFile, node); } + var escapeText = ts.getEmitFlags(node) & 16777216 /* NoAsciiEscaping */ ? escapeString : escapeNonAsciiString; // If we can't reach the original source text, use the canonical form if it's a number, - // or an escaped quoted form of the original text if it's string-like. + // or a (possibly escaped) quoted form of the original text if it's string-like. switch (node.kind) { case 9 /* StringLiteral */: - return getQuotedEscapedLiteralText('"', node.text, '"'); + return '"' + escapeText(node.text) + '"'; case 13 /* NoSubstitutionTemplateLiteral */: - return getQuotedEscapedLiteralText("`", node.text, "`"); + return "`" + escapeText(node.text) + "`"; case 14 /* TemplateHead */: - return getQuotedEscapedLiteralText("`", node.text, "${"); + return "`" + escapeText(node.text) + "${"; case 15 /* TemplateMiddle */: - return getQuotedEscapedLiteralText("}", node.text, "${"); + return "}" + escapeText(node.text) + "${"; case 16 /* TemplateTail */: - return getQuotedEscapedLiteralText("}", node.text, "`"); + return "}" + escapeText(node.text) + "`"; case 8 /* NumericLiteral */: return node.text; } ts.Debug.fail("Literal kind '" + node.kind + "' not accounted for."); } ts.getLiteralText = getLiteralText; - function getQuotedEscapedLiteralText(leftQuote, text, rightQuote) { - return leftQuote + escapeNonAsciiCharacters(escapeString(text)) + rightQuote; + function getTextOfConstantValue(value) { + return typeof value === "string" ? '"' + escapeNonAsciiString(value) + '"' : "" + value; } + ts.getTextOfConstantValue = getTextOfConstantValue; // Add an extra underscore to identifiers that start with two underscores to avoid issues with magic names like '__proto__' function escapeIdentifier(identifier) { return identifier.length >= 2 && identifier.charCodeAt(0) === 95 /* _ */ && identifier.charCodeAt(1) === 95 /* _ */ ? "_" + identifier : identifier; @@ -6913,7 +7119,7 @@ var ts; function isBlockScopedContainerTopLevel(node) { return node.kind === 265 /* SourceFile */ || node.kind === 233 /* ModuleDeclaration */ || - isFunctionLike(node); + ts.isFunctionLike(node); } ts.isBlockScopedContainerTopLevel = isBlockScopedContainerTopLevel; function isGlobalScopeAugmentation(module) { @@ -6960,7 +7166,7 @@ var ts; case 207 /* Block */: // function block is not considered block-scope container // see comment in binder.ts: bind(...), case for SyntaxKind.Block - return parentNode && !isFunctionLike(parentNode); + return parentNode && !ts.isFunctionLike(parentNode); } return false; } @@ -7103,10 +7309,6 @@ var ts; return (file.externalModuleIndicator || file.commonJsModuleIndicator) !== undefined; } ts.isExternalOrCommonJsModule = isExternalOrCommonJsModule; - function isDeclarationFile(file) { - return file.isDeclarationFile; - } - ts.isDeclarationFile = isDeclarationFile; function isConstEnumDeclaration(node) { return node.kind === 232 /* EnumDeclaration */ && isConst(node); } @@ -7124,6 +7326,10 @@ var ts; return n.kind === 181 /* CallExpression */ && n.expression.kind === 97 /* SuperKeyword */; } ts.isSuperCall = isSuperCall; + function isImportCall(n) { + return n.kind === 181 /* CallExpression */ && n.expression.kind === 91 /* ImportKeyword */; + } + ts.isImportCall = isImportCall; function isPrologueDirective(node) { return node.kind === 210 /* ExpressionStatement */ && node.expression.kind === 9 /* StringLiteral */; @@ -7247,10 +7453,6 @@ var ts; return false; } ts.isChildOfNodeWithKind = isChildOfNodeWithKind; - function isPrefixUnaryExpression(node) { - return node.kind === 192 /* PrefixUnaryExpression */; - } - ts.isPrefixUnaryExpression = isPrefixUnaryExpression; // Warning: This has the same semantics as the forEach family of functions, // in that traversal terminates in the event that 'visitor' supplies a truthy value. function forEachReturnStatement(body, visitor) { @@ -7301,7 +7503,7 @@ var ts; // skipped in this traversal. return; default: - if (isFunctionLike(node)) { + if (ts.isFunctionLike(node)) { var name = node.name; if (name && name.kind === 144 /* ComputedPropertyName */) { // Note that we will not include methods/accessors of a class because they would require @@ -7354,38 +7556,6 @@ var ts; return false; } ts.isVariableLike = isVariableLike; - function isAccessor(node) { - return node && (node.kind === 153 /* GetAccessor */ || node.kind === 154 /* SetAccessor */); - } - ts.isAccessor = isAccessor; - function isClassLike(node) { - return node && (node.kind === 229 /* ClassDeclaration */ || node.kind === 199 /* ClassExpression */); - } - ts.isClassLike = isClassLike; - function isFunctionLike(node) { - return node && isFunctionLikeKind(node.kind); - } - ts.isFunctionLike = isFunctionLike; - function isFunctionLikeKind(kind) { - switch (kind) { - case 152 /* Constructor */: - case 186 /* FunctionExpression */: - case 228 /* FunctionDeclaration */: - case 187 /* ArrowFunction */: - case 151 /* MethodDeclaration */: - case 150 /* MethodSignature */: - case 153 /* GetAccessor */: - case 154 /* SetAccessor */: - case 155 /* CallSignature */: - case 156 /* ConstructSignature */: - case 157 /* IndexSignature */: - case 160 /* FunctionType */: - case 161 /* ConstructorType */: - return true; - } - return false; - } - ts.isFunctionLikeKind = isFunctionLikeKind; function introducesArgumentsExoticObject(node) { switch (node.kind) { case 151 /* MethodDeclaration */: @@ -7400,20 +7570,6 @@ var ts; return false; } ts.introducesArgumentsExoticObject = introducesArgumentsExoticObject; - function isIterationStatement(node, lookInLabeledStatements) { - switch (node.kind) { - case 214 /* ForStatement */: - case 215 /* ForInStatement */: - case 216 /* ForOfStatement */: - case 212 /* DoStatement */: - case 213 /* WhileStatement */: - return true; - case 222 /* LabeledStatement */: - return lookInLabeledStatements && isIterationStatement(node.statement, lookInLabeledStatements); - } - return false; - } - ts.isIterationStatement = isIterationStatement; function unwrapInnermostStatementOfLabel(node, beforeUnwrapLabelCallback) { while (true) { if (beforeUnwrapLabelCallback) { @@ -7427,7 +7583,7 @@ var ts; } ts.unwrapInnermostStatementOfLabel = unwrapInnermostStatementOfLabel; function isFunctionBlock(node) { - return node && node.kind === 207 /* Block */ && isFunctionLike(node.parent); + return node && node.kind === 207 /* Block */ && ts.isFunctionLike(node.parent); } ts.isFunctionBlock = isFunctionBlock; function isObjectLiteralMethod(node) { @@ -7451,7 +7607,7 @@ var ts; function getContainingFunction(node) { while (true) { node = node.parent; - if (!node || isFunctionLike(node)) { + if (!node || ts.isFunctionLike(node)) { return node; } } @@ -7460,7 +7616,7 @@ var ts; function getContainingClass(node) { while (true) { node = node.parent; - if (!node || isClassLike(node)) { + if (!node || ts.isClassLike(node)) { return node; } } @@ -7478,7 +7634,7 @@ var ts; // then the computed property is not a 'this' container. // A computed property name in a class needs to be a this container // so that we can error on it. - if (isClassLike(node.parent.parent)) { + if (ts.isClassLike(node.parent.parent)) { return node; } // If this is a computed property, then the parent should not @@ -7490,12 +7646,12 @@ var ts; break; case 147 /* Decorator */: // Decorators are always applied outside of the body of a class or method. - if (node.parent.kind === 146 /* Parameter */ && isClassElement(node.parent.parent)) { + if (node.parent.kind === 146 /* Parameter */ && ts.isClassElement(node.parent.parent)) { // If the decorator's parent is a Parameter, we resolve the this container from // the grandparent class declaration. node = node.parent.parent; } - else if (isClassElement(node.parent)) { + else if (ts.isClassElement(node.parent)) { // If the decorator's parent is a class element, we resolve the 'this' container // from the parent class declaration. node = node.parent; @@ -7574,12 +7730,12 @@ var ts; return node; case 147 /* Decorator */: // Decorators are always applied outside of the body of a class or method. - if (node.parent.kind === 146 /* Parameter */ && isClassElement(node.parent.parent)) { + if (node.parent.kind === 146 /* Parameter */ && ts.isClassElement(node.parent.parent)) { // If the decorator's parent is a Parameter, we resolve the this container from // the grandparent class declaration. node = node.parent.parent; } - else if (isClassElement(node.parent)) { + else if (ts.isClassElement(node.parent)) { // If the decorator's parent is a class element, we resolve the 'this' container // from the parent class declaration. node = node.parent; @@ -7628,25 +7784,11 @@ var ts; return undefined; } ts.getEntityNameFromTypeNode = getEntityNameFromTypeNode; - function isCallLikeExpression(node) { - switch (node.kind) { - case 251 /* JsxOpeningElement */: - case 250 /* JsxSelfClosingElement */: - case 181 /* CallExpression */: - case 182 /* NewExpression */: - case 183 /* TaggedTemplateExpression */: - case 147 /* Decorator */: - return true; - default: - return false; - } - } - ts.isCallLikeExpression = isCallLikeExpression; function getInvokedExpression(node) { if (node.kind === 183 /* TaggedTemplateExpression */) { return node.tag; } - else if (isJsxOpeningLikeElement(node)) { + else if (ts.isJsxOpeningLikeElement(node)) { return node.tagName; } // Will either be a CallExpression, NewExpression, or Decorator. @@ -7884,11 +8026,11 @@ var ts; } ts.getRightMostAssignedExpression = getRightMostAssignedExpression; function isExportsIdentifier(node) { - return isIdentifier(node) && node.text === "exports"; + return ts.isIdentifier(node) && node.text === "exports"; } ts.isExportsIdentifier = isExportsIdentifier; function isModuleExportsPropertyAccessExpression(node) { - return isPropertyAccessExpression(node) && isIdentifier(node.expression) && node.expression.text === "module" && node.name.text === "exports"; + return ts.isPropertyAccessExpression(node) && ts.isIdentifier(node.expression) && node.expression.text === "module" && node.name.text === "exports"; } ts.isModuleExportsPropertyAccessExpression = isModuleExportsPropertyAccessExpression; /// Given a BinaryExpression, returns SpecialPropertyAssignmentKind for the various kinds of property @@ -7998,35 +8140,24 @@ var ts; } ts.getCommentsFromJSDoc = getCommentsFromJSDoc; function hasJSDocParameterTags(node) { - var parameterTags = getJSDocTags(node, 286 /* JSDocParameterTag */); + var parameterTags = getJSDocTags(node, 287 /* JSDocParameterTag */); return parameterTags && parameterTags.length > 0; } ts.hasJSDocParameterTags = hasJSDocParameterTags; function getJSDocTags(node, kind) { - var docs = getJSDocs(node); - if (docs) { - var result = []; - for (var _i = 0, docs_1 = docs; _i < docs_1.length; _i++) { - var doc = docs_1[_i]; - if (doc.kind === 286 /* JSDocParameterTag */) { - if (doc.kind === kind) { - result.push(doc); - } - } - else { - var tags = doc.tags; - if (tags) { - result.push.apply(result, ts.filter(tags, function (tag) { return tag.kind === kind; })); - } - } - } - return result; - } + return ts.flatMap(getJSDocs(node), function (doc) { + return doc.kind === 283 /* JSDocComment */ + ? ts.filter(doc.tags, function (tag) { return tag.kind === kind; }) + : doc.kind === kind && doc; + }); } function getFirstJSDocTag(node, kind) { return node && ts.firstOrUndefined(getJSDocTags(node, kind)); } function getJSDocs(node) { + if (ts.isJSDocTypedefTag(node)) { + return [node.parent]; + } var cache = node.jsDocCache; if (!cache) { getJSDocsWorker(node); @@ -8078,22 +8209,19 @@ var ts; } ts.getJSDocs = getJSDocs; function getJSDocParameterTags(param) { - if (!isParameter(param)) { - return undefined; - } var func = param.parent; - var tags = getJSDocTags(func, 286 /* JSDocParameterTag */); + var tags = getJSDocTags(func, 287 /* JSDocParameterTag */); if (!param.name) { // this is an anonymous jsdoc param from a `function(type1, type2): type3` specification var i = func.parameters.indexOf(param); - var paramTags = ts.filter(tags, function (tag) { return tag.kind === 286 /* JSDocParameterTag */; }); + var paramTags = ts.filter(tags, function (tag) { return tag.kind === 287 /* JSDocParameterTag */; }); if (paramTags && 0 <= i && i < paramTags.length) { return [paramTags[i]]; } } else if (param.name.kind === 71 /* Identifier */) { var name_1 = param.name.text; - return ts.filter(tags, function (tag) { return tag.kind === 286 /* JSDocParameterTag */ && tag.parameterName.text === name_1; }); + return ts.filter(tags, function (tag) { return tag.kind === 287 /* JSDocParameterTag */ && tag.name.text === name_1; }); } else { // TODO: it's a destructured parameter, so it should look up an "object type" series of multiple lines @@ -8102,8 +8230,27 @@ var ts; } } ts.getJSDocParameterTags = getJSDocParameterTags; + /** Does the opposite of `getJSDocParameterTags`: given a JSDoc parameter, finds the parameter corresponding to it. */ + function getParameterFromJSDoc(node) { + var name = node.name.text; + var grandParent = node.parent.parent; + ts.Debug.assert(node.parent.kind === 283 /* JSDocComment */); + if (!ts.isFunctionLike(grandParent)) { + return undefined; + } + return ts.find(grandParent.parameters, function (p) { + return p.name.kind === 71 /* Identifier */ && p.name.text === name; + }); + } + ts.getParameterFromJSDoc = getParameterFromJSDoc; + function getTypeParameterFromJsDoc(node) { + var name = node.name.text; + var typeParameters = node.parent.parent.parent.typeParameters; + return ts.find(typeParameters, function (p) { return p.name.text === name; }); + } + ts.getTypeParameterFromJsDoc = getTypeParameterFromJsDoc; function getJSDocType(node) { - var tag = getFirstJSDocTag(node, 288 /* JSDocTypeTag */); + var tag = getFirstJSDocTag(node, 289 /* JSDocTypeTag */); if (!tag && node.kind === 146 /* Parameter */) { var paramTags = getJSDocParameterTags(node); if (paramTags) { @@ -8117,12 +8264,21 @@ var ts; return getFirstJSDocTag(node, 285 /* JSDocAugmentsTag */); } ts.getJSDocAugmentsTag = getJSDocAugmentsTag; + function getJSDocClassTag(node) { + return getFirstJSDocTag(node, 286 /* JSDocClassTag */); + } + ts.getJSDocClassTag = getJSDocClassTag; function getJSDocReturnTag(node) { - return getFirstJSDocTag(node, 287 /* JSDocReturnTag */); + return getFirstJSDocTag(node, 288 /* JSDocReturnTag */); } ts.getJSDocReturnTag = getJSDocReturnTag; + function getJSDocReturnType(node) { + var returnTag = getJSDocReturnTag(node); + return returnTag && returnTag.typeExpression && returnTag.typeExpression.type; + } + ts.getJSDocReturnType = getJSDocReturnType; function getJSDocTemplateTag(node) { - return getFirstJSDocTag(node, 289 /* JSDocTemplateTag */); + return getFirstJSDocTag(node, 290 /* JSDocTemplateTag */); } ts.getJSDocTemplateTag = getJSDocTemplateTag; function hasRestParameter(s) { @@ -8234,55 +8390,37 @@ var ts; ts.isInAmbientContext = isInAmbientContext; // True if the given identifier, string literal, or number literal is the name of a declaration node function isDeclarationName(name) { - if (name.kind !== 71 /* Identifier */ && name.kind !== 9 /* StringLiteral */ && name.kind !== 8 /* NumericLiteral */) { - return false; - } - var parent = name.parent; - if (parent.kind === 242 /* ImportSpecifier */ || parent.kind === 246 /* ExportSpecifier */) { - if (parent.propertyName) { - return true; - } - } - if (isDeclaration(parent)) { - return parent.name === name; + switch (name.kind) { + case 71 /* Identifier */: + case 9 /* StringLiteral */: + case 8 /* NumericLiteral */: + return ts.isDeclaration(name.parent) && name.parent.name === name; + default: + return false; } - return false; } ts.isDeclarationName = isDeclarationName; - function getNameOfDeclaration(declaration) { - if (!declaration) { - return undefined; - } - if (declaration.kind === 194 /* BinaryExpression */) { - var kind = getSpecialPropertyAssignmentKind(declaration); - var lhs = declaration.left; - switch (kind) { - case 0 /* None */: - case 2 /* ModuleExports */: - return undefined; - case 1 /* ExportsProperty */: - if (lhs.kind === 71 /* Identifier */) { - return lhs.name; - } - else { - return lhs.expression.name; - } - case 4 /* ThisProperty */: - case 5 /* Property */: - return lhs.name; - case 3 /* PrototypeProperty */: - return lhs.expression.name; - } - } - else { - return declaration.name; + /* @internal */ + // See GH#16030 + function isAnyDeclarationName(name) { + switch (name.kind) { + case 71 /* Identifier */: + case 9 /* StringLiteral */: + case 8 /* NumericLiteral */: + if (ts.isDeclaration(name.parent)) { + return name.parent.name === name; + } + var binExp = name.parent.parent; + return ts.isBinaryExpression(binExp) && getSpecialPropertyAssignmentKind(binExp) !== 0 /* None */ && ts.getNameOfDeclaration(binExp) === name; + default: + return false; } } - ts.getNameOfDeclaration = getNameOfDeclaration; + ts.isAnyDeclarationName = isAnyDeclarationName; function isLiteralComputedPropertyDeclarationName(node) { return (node.kind === 9 /* StringLiteral */ || node.kind === 8 /* NumericLiteral */) && node.parent.kind === 144 /* ComputedPropertyName */ && - isDeclaration(node.parent.parent); + ts.isDeclaration(node.parent.parent); } ts.isLiteralComputedPropertyDeclarationName = isLiteralComputedPropertyDeclarationName; // Return true if the given identifier is classified as an IdentifierName @@ -8391,21 +8529,19 @@ var ts; var isNoDefaultLibRegEx = /^(\/\/\/\s*/gim; if (simpleReferenceRegEx.test(comment)) { if (isNoDefaultLibRegEx.test(comment)) { - return { - isNoDefaultLib: true - }; + return { isNoDefaultLib: true }; } else { var refMatchResult = ts.fullTripleSlashReferencePathRegEx.exec(comment); var refLibResult = !refMatchResult && ts.fullTripleSlashReferenceTypeReferenceDirectiveRegEx.exec(comment); - if (refMatchResult || refLibResult) { - var start = commentRange.pos; - var end = commentRange.end; + var match = refMatchResult || refLibResult; + if (match) { + var pos = commentRange.pos + match[1].length + match[2].length; return { fileReference: { - pos: start, - end: end, - fileName: (refMatchResult || refLibResult)[3] + pos: pos, + end: pos + match[3].length, + fileName: match[3] }, isNoDefaultLib: false, isTypeReferenceDirective: !!refLibResult @@ -8474,10 +8610,6 @@ var ts; return false; } ts.isAsyncFunction = isAsyncFunction; - function isNumericLiteral(node) { - return node.kind === 8 /* NumericLiteral */; - } - ts.isNumericLiteral = isNumericLiteral; function isStringOrNumericLiteral(node) { var kind = node.kind; return kind === 9 /* StringLiteral */ @@ -8492,7 +8624,7 @@ var ts; * Symbol. */ function hasDynamicName(declaration) { - var name = getNameOfDeclaration(declaration); + var name = ts.getNameOfDeclaration(declaration); return name && isDynamicName(name); } ts.hasDynamicName = hasDynamicName; @@ -8508,7 +8640,7 @@ var ts; * where Symbol is literally the word "Symbol", and name is any identifierName */ function isWellKnownSymbolSyntactically(node) { - return isPropertyAccessExpression(node) && isESSymbolIdentifier(node.expression); + return ts.isPropertyAccessExpression(node) && isESSymbolIdentifier(node.expression); } ts.isWellKnownSymbolSyntactically = isWellKnownSymbolSyntactically; function getPropertyNameForPropertyNameNode(name) { @@ -8543,24 +8675,6 @@ var ts; return node.text === "push" || node.text === "unshift"; } ts.isPushOrUnshiftIdentifier = isPushOrUnshiftIdentifier; - function isModifierKind(token) { - switch (token) { - case 117 /* AbstractKeyword */: - case 120 /* AsyncKeyword */: - case 76 /* ConstKeyword */: - case 124 /* DeclareKeyword */: - case 79 /* DefaultKeyword */: - case 84 /* ExportKeyword */: - case 114 /* PublicKeyword */: - case 112 /* PrivateKeyword */: - case 113 /* ProtectedKeyword */: - case 131 /* ReadonlyKeyword */: - case 115 /* StaticKeyword */: - return true; - } - return false; - } - ts.isModifierKind = isModifierKind; function isParameterDeclaration(node) { var root = getRootDeclaration(node); return root.kind === 146 /* Parameter */; @@ -8599,7 +8713,7 @@ var ts; } ts.getOriginalSourceFileOrBundle = getOriginalSourceFileOrBundle; function getOriginalSourceFile(sourceFile) { - return ts.getParseTreeNode(sourceFile, isSourceFile) || sourceFile; + return ts.getParseTreeNode(sourceFile, ts.isSourceFile) || sourceFile; } function getOriginalSourceFiles(sourceFiles) { return ts.sameMap(sourceFiles, getOriginalSourceFile); @@ -8776,6 +8890,8 @@ var ts; return 2; case 198 /* SpreadElement */: return 1; + case 298 /* CommaListExpression */: + return 0; default: return -1; } @@ -8889,14 +9005,15 @@ var ts; return "\\u" + paddedHexCode; } var nonAsciiCharacters = /[^\u0000-\u007F]/g; - function escapeNonAsciiCharacters(s) { + function escapeNonAsciiString(s) { + s = escapeString(s); // Replace non-ASCII characters with '\uNNNN' escapes if any exist. // Otherwise just return the original string. return nonAsciiCharacters.test(s) ? s.replace(nonAsciiCharacters, function (c) { return get16BitUnicodeEscapeSequence(c.charCodeAt(0)); }) : s; } - ts.escapeNonAsciiCharacters = escapeNonAsciiCharacters; + ts.escapeNonAsciiString = escapeNonAsciiString; var indentStrings = ["", " "]; function getIndentString(level) { if (indentStrings[level] === undefined) { @@ -8985,7 +9102,7 @@ var ts; ts.getResolvedExternalModuleName = getResolvedExternalModuleName; function getExternalModuleNameFromDeclaration(host, resolver, declaration) { var file = resolver.getExternalModuleFileFromDeclaration(declaration); - if (!file || isDeclarationFile(file)) { + if (!file || file.isDeclarationFile) { return undefined; } return getResolvedExternalModuleName(host, file); @@ -9051,7 +9168,7 @@ var ts; ts.getSourceFilesToEmit = getSourceFilesToEmit; /** Don't call this for `--outFile`, just for `--outDir` or plain emit. `--outFile` needs additional checks. */ function sourceFileMayBeEmitted(sourceFile, options, isSourceFileFromExternalLibrary) { - return !(options.noEmitForJsFiles && isSourceFileJavaScript(sourceFile)) && !isDeclarationFile(sourceFile) && !isSourceFileFromExternalLibrary(sourceFile); + return !(options.noEmitForJsFiles && isSourceFileJavaScript(sourceFile)) && !sourceFile.isDeclarationFile && !isSourceFileFromExternalLibrary(sourceFile); } ts.sourceFileMayBeEmitted = sourceFileMayBeEmitted; /** @@ -9135,13 +9252,17 @@ var ts; }); } ts.getFirstConstructorWithBody = getFirstConstructorWithBody; - /** Get the type annotaion for the value parameter. */ - function getSetAccessorTypeAnnotationNode(accessor) { + function getSetAccessorValueParameter(accessor) { if (accessor && accessor.parameters.length > 0) { var hasThis = accessor.parameters.length === 2 && parameterIsThisKeyword(accessor.parameters[0]); - return accessor.parameters[hasThis ? 1 : 0].type; + return accessor.parameters[hasThis ? 1 : 0]; } } + /** Get the type annotation for the value parameter. */ + function getSetAccessorTypeAnnotationNode(accessor) { + var parameter = getSetAccessorValueParameter(accessor); + return parameter && parameter.type; + } ts.getSetAccessorTypeAnnotationNode = getSetAccessorTypeAnnotationNode; function getThisParameter(signature) { if (signature.parameters.length) { @@ -9212,6 +9333,55 @@ var ts; }; } ts.getAllAccessorDeclarations = getAllAccessorDeclarations; + /** + * Gets the effective type annotation of a variable, parameter, or property. If the node was + * parsed in a JavaScript file, gets the type annotation from JSDoc. + */ + function getEffectiveTypeAnnotationNode(node) { + if (node.type) { + return node.type; + } + if (node.flags & 65536 /* JavaScriptFile */) { + return getJSDocType(node); + } + } + ts.getEffectiveTypeAnnotationNode = getEffectiveTypeAnnotationNode; + /** + * Gets the effective return type annotation of a signature. If the node was parsed in a + * JavaScript file, gets the return type annotation from JSDoc. + */ + function getEffectiveReturnTypeNode(node) { + if (node.type) { + return node.type; + } + if (node.flags & 65536 /* JavaScriptFile */) { + return getJSDocReturnType(node); + } + } + ts.getEffectiveReturnTypeNode = getEffectiveReturnTypeNode; + /** + * Gets the effective type parameters. If the node was parsed in a + * JavaScript file, gets the type parameters from the `@template` tag from JSDoc. + */ + function getEffectiveTypeParameterDeclarations(node) { + if (node.typeParameters) { + return node.typeParameters; + } + if (node.flags & 65536 /* JavaScriptFile */) { + var templateTag = getJSDocTemplateTag(node); + return templateTag && templateTag.typeParameters; + } + } + ts.getEffectiveTypeParameterDeclarations = getEffectiveTypeParameterDeclarations; + /** + * Gets the effective type annotation of the value parameter of a set accessor. If the node + * was parsed in a JavaScript file, gets the type annotation from JSDoc. + */ + function getEffectiveSetAccessorTypeAnnotationNode(node) { + var parameter = getSetAccessorValueParameter(node); + return parameter && getEffectiveTypeAnnotationNode(parameter); + } + ts.getEffectiveSetAccessorTypeAnnotationNode = getEffectiveSetAccessorTypeAnnotationNode; function emitNewLineBeforeLeadingComments(lineMap, writer, node, leadingComments) { emitNewLineBeforeLeadingCommentsOfPosition(lineMap, writer, node.pos, leadingComments); } @@ -9417,6 +9587,13 @@ var ts; if (node.modifierFlagsCache & 536870912 /* HasComputedFlags */) { return node.modifierFlagsCache & ~536870912 /* HasComputedFlags */; } + var flags = getModifierFlagsNoCache(node); + node.modifierFlagsCache = flags | 536870912 /* HasComputedFlags */; + return flags; + } + ts.getModifierFlags = getModifierFlags; + /* @internal */ + function getModifierFlagsNoCache(node) { var flags = 0 /* None */; if (node.modifiers) { for (var _i = 0, _a = node.modifiers; _i < _a.length; _i++) { @@ -9427,10 +9604,9 @@ var ts; if (node.flags & 4 /* NestedNamespace */ || (node.kind === 71 /* Identifier */ && node.isInJSDocNamespace)) { flags |= 1 /* Export */; } - node.modifierFlagsCache = flags | 536870912 /* HasComputedFlags */; return flags; } - ts.getModifierFlags = getModifierFlags; + ts.getModifierFlagsNoCache = getModifierFlagsNoCache; function modifierToFlag(token) { switch (token) { case 115 /* StaticKeyword */: return 32 /* Static */; @@ -9462,17 +9638,17 @@ var ts; function tryGetClassExtendingExpressionWithTypeArguments(node) { if (node.kind === 201 /* ExpressionWithTypeArguments */ && node.parent.token === 85 /* ExtendsKeyword */ && - isClassLike(node.parent.parent)) { + ts.isClassLike(node.parent.parent)) { return node.parent.parent; } } ts.tryGetClassExtendingExpressionWithTypeArguments = tryGetClassExtendingExpressionWithTypeArguments; function isAssignmentExpression(node, excludeCompoundAssignment) { - return isBinaryExpression(node) + return ts.isBinaryExpression(node) && (excludeCompoundAssignment ? node.operatorToken.kind === 58 /* EqualsToken */ : isAssignmentOperator(node.operatorToken.kind)) - && isLeftHandSideExpression(node.left); + && ts.isLeftHandSideExpression(node.left); } ts.isAssignmentExpression = isAssignmentExpression; function isDestructuringAssignment(node) { @@ -9494,7 +9670,7 @@ var ts; if (node.kind === 71 /* Identifier */) { return true; } - else if (isPropertyAccessExpression(node)) { + else if (ts.isPropertyAccessExpression(node)) { return isSupportedExpressionWithTypeArgumentsRest(node.expression); } else { @@ -9511,7 +9687,7 @@ var ts; && node.parent && node.parent.token === 108 /* ImplementsKeyword */ && node.parent.parent - && isClassLike(node.parent.parent); + && ts.isClassLike(node.parent.parent); } ts.isExpressionWithTypeArgumentsInClassImplementsClause = isExpressionWithTypeArgumentsInClassImplementsClause; function isEntityNameExpression(node) { @@ -9535,11 +9711,11 @@ var ts; } ts.isEmptyArrayLiteral = isEmptyArrayLiteral; function getLocalSymbolForExportDefault(symbol) { - return isExportDefaultSymbol(symbol) ? symbol.valueDeclaration.localSymbol : undefined; + return isExportDefaultSymbol(symbol) ? symbol.declarations[0].localSymbol : undefined; } ts.getLocalSymbolForExportDefault = getLocalSymbolForExportDefault; function isExportDefaultSymbol(symbol) { - return symbol && symbol.valueDeclaration && hasModifier(symbol.valueDeclaration, 512 /* Default */); + return symbol && ts.length(symbol.declarations) > 0 && hasModifier(symbol.declarations[0], 512 /* Default */); } /** Return ".ts", ".d.ts", or ".tsx", if that is the extension. */ function tryExtractTypeScriptExtension(fileName) { @@ -9615,13 +9791,13 @@ var ts; var carriageReturnLineFeed = "\r\n"; var lineFeed = "\n"; function getNewLineCharacter(options) { - if (options.newLine === 0 /* CarriageReturnLineFeed */) { - return carriageReturnLineFeed; + switch (options.newLine) { + case 0 /* CarriageReturnLineFeed */: + return carriageReturnLineFeed; + case 1 /* LineFeed */: + return lineFeed; } - else if (options.newLine === 1 /* LineFeed */) { - return lineFeed; - } - else if (ts.sys) { + if (ts.sys) { return ts.sys.newLine; } return carriageReturnLineFeed; @@ -9699,27 +9875,77 @@ var ts; } return false; } - var syntaxKindCache = []; - function formatSyntaxKind(kind) { - var syntaxKindEnum = ts.SyntaxKind; - if (syntaxKindEnum) { - var cached = syntaxKindCache[kind]; - if (cached !== undefined) { - return cached; - } - for (var name in syntaxKindEnum) { - if (syntaxKindEnum[name] === kind) { - var result = kind + " (" + name + ")"; - syntaxKindCache[kind] = result; - return result; + /** + * Formats an enum value as a string for debugging and debug assertions. + */ + function formatEnum(value, enumObject, isFlags) { + if (value === void 0) { value = 0; } + var members = getEnumMembers(enumObject); + if (value === 0) { + return members.length > 0 && members[0][0] === 0 ? members[0][1] : "0"; + } + if (isFlags) { + var result = ""; + var remainingFlags = value; + for (var i = members.length - 1; i >= 0 && remainingFlags !== 0; i--) { + var _a = members[i], enumValue = _a[0], enumName = _a[1]; + if (enumValue !== 0 && (remainingFlags & enumValue) === enumValue) { + remainingFlags &= ~enumValue; + result = "" + enumName + (result ? ", " : "") + result; } } + if (remainingFlags === 0) { + return result; + } } else { - return kind.toString(); + for (var _i = 0, members_1 = members; _i < members_1.length; _i++) { + var _b = members_1[_i], enumValue = _b[0], enumName = _b[1]; + if (enumValue === value) { + return enumName; + } + } + } + return value.toString(); + } + function getEnumMembers(enumObject) { + var result = []; + for (var name in enumObject) { + var value = enumObject[name]; + if (typeof value === "number") { + result.push([value, name]); + } } + return ts.stableSort(result, function (x, y) { return ts.compareValues(x[0], y[0]); }); + } + function formatSyntaxKind(kind) { + return formatEnum(kind, ts.SyntaxKind, /*isFlags*/ false); } ts.formatSyntaxKind = formatSyntaxKind; + function formatModifierFlags(flags) { + return formatEnum(flags, ts.ModifierFlags, /*isFlags*/ true); + } + ts.formatModifierFlags = formatModifierFlags; + function formatTransformFlags(flags) { + return formatEnum(flags, ts.TransformFlags, /*isFlags*/ true); + } + ts.formatTransformFlags = formatTransformFlags; + function formatEmitFlags(flags) { + return formatEnum(flags, ts.EmitFlags, /*isFlags*/ true); + } + ts.formatEmitFlags = formatEmitFlags; + function formatSymbolFlags(flags) { + return formatEnum(flags, ts.SymbolFlags, /*isFlags*/ true); + } + ts.formatSymbolFlags = formatSymbolFlags; + function formatTypeFlags(flags) { + return formatEnum(flags, ts.TypeFlags, /*isFlags*/ true); + } + ts.formatTypeFlags = formatTypeFlags; + function formatObjectFlags(flags) { + return formatEnum(flags, ts.ObjectFlags, /*isFlags*/ true); + } + ts.formatObjectFlags = formatObjectFlags; function getRangePos(range) { return range ? range.pos : -1; } @@ -9902,247 +10128,631 @@ var ts; return node.symbol && getDeclarationOfKind(node.symbol, kind) === node; } ts.isFirstDeclarationOfKind = isFirstDeclarationOfKind; - // Node tests - // - // All node tests in the following list should *not* reference parent pointers so that - // they may be used with transformations. - // Node Arrays - function isNodeArray(array) { - return array.hasOwnProperty("pos") - && array.hasOwnProperty("end"); - } - ts.isNodeArray = isNodeArray; - // Literals - function isNoSubstitutionTemplateLiteral(node) { - return node.kind === 13 /* NoSubstitutionTemplateLiteral */; - } - ts.isNoSubstitutionTemplateLiteral = isNoSubstitutionTemplateLiteral; - function isLiteralKind(kind) { - return 8 /* FirstLiteralToken */ <= kind && kind <= 13 /* LastLiteralToken */; - } - ts.isLiteralKind = isLiteralKind; - function isTextualLiteralKind(kind) { - return kind === 9 /* StringLiteral */ || kind === 13 /* NoSubstitutionTemplateLiteral */; - } - ts.isTextualLiteralKind = isTextualLiteralKind; - function isLiteralExpression(node) { - return isLiteralKind(node.kind); - } - ts.isLiteralExpression = isLiteralExpression; - // Pseudo-literals - function isTemplateLiteralKind(kind) { - return 13 /* FirstTemplateToken */ <= kind && kind <= 16 /* LastTemplateToken */; + function isWatchSet(options) { + // Firefox has Object.prototype.watch + return options.watch && options.hasOwnProperty("watch"); } - ts.isTemplateLiteralKind = isTemplateLiteralKind; - function isTemplateHead(node) { - return node.kind === 14 /* TemplateHead */; + ts.isWatchSet = isWatchSet; + function getCheckFlags(symbol) { + return symbol.flags & 134217728 /* Transient */ ? symbol.checkFlags : 0; + } + ts.getCheckFlags = getCheckFlags; + function getDeclarationModifierFlagsFromSymbol(s) { + if (s.valueDeclaration) { + var flags = ts.getCombinedModifierFlags(s.valueDeclaration); + return s.parent && s.parent.flags & 32 /* Class */ ? flags : flags & ~28 /* AccessibilityModifier */; + } + if (getCheckFlags(s) & 6 /* Synthetic */) { + var checkFlags = s.checkFlags; + var accessModifier = checkFlags & 256 /* ContainsPrivate */ ? 8 /* Private */ : + checkFlags & 64 /* ContainsPublic */ ? 4 /* Public */ : + 16 /* Protected */; + var staticModifier = checkFlags & 512 /* ContainsStatic */ ? 32 /* Static */ : 0; + return accessModifier | staticModifier; + } + if (s.flags & 16777216 /* Prototype */) { + return 4 /* Public */ | 32 /* Static */; + } + return 0; } - ts.isTemplateHead = isTemplateHead; - function isTemplateMiddleOrTemplateTail(node) { - var kind = node.kind; - return kind === 15 /* TemplateMiddle */ - || kind === 16 /* TemplateTail */; + ts.getDeclarationModifierFlagsFromSymbol = getDeclarationModifierFlagsFromSymbol; + function levenshtein(s1, s2) { + var previous = new Array(s2.length + 1); + var current = new Array(s2.length + 1); + for (var i = 0; i < s2.length + 1; i++) { + previous[i] = i; + current[i] = -1; + } + for (var i = 1; i < s1.length + 1; i++) { + current[0] = i; + for (var j = 1; j < s2.length + 1; j++) { + current[j] = Math.min(previous[j] + 1, current[j - 1] + 1, previous[j - 1] + (s1[i - 1] === s2[j - 1] ? 0 : 2)); + } + // shift current back to previous, and then reuse previous' array + var tmp = previous; + previous = current; + current = tmp; + } + return previous[previous.length - 1]; } - ts.isTemplateMiddleOrTemplateTail = isTemplateMiddleOrTemplateTail; - // Identifiers - function isIdentifier(node) { - return node.kind === 71 /* Identifier */; + ts.levenshtein = levenshtein; +})(ts || (ts = {})); +(function (ts) { + function getDefaultLibFileName(options) { + switch (options.target) { + case 5 /* ESNext */: + return "lib.esnext.full.d.ts"; + case 4 /* ES2017 */: + return "lib.es2017.full.d.ts"; + case 3 /* ES2016 */: + return "lib.es2016.full.d.ts"; + case 2 /* ES2015 */: + return "lib.es6.d.ts"; // We don't use lib.es2015.full.d.ts due to breaking change. + default: + return "lib.d.ts"; + } } - ts.isIdentifier = isIdentifier; - function isVoidExpression(node) { - return node.kind === 190 /* VoidExpression */; + ts.getDefaultLibFileName = getDefaultLibFileName; + function textSpanEnd(span) { + return span.start + span.length; } - ts.isVoidExpression = isVoidExpression; - function isGeneratedIdentifier(node) { - // Using `>` here catches both `GeneratedIdentifierKind.None` and `undefined`. - return isIdentifier(node) && node.autoGenerateKind > 0 /* None */; + ts.textSpanEnd = textSpanEnd; + function textSpanIsEmpty(span) { + return span.length === 0; } - ts.isGeneratedIdentifier = isGeneratedIdentifier; - // Keywords - function isModifier(node) { - return isModifierKind(node.kind); + ts.textSpanIsEmpty = textSpanIsEmpty; + function textSpanContainsPosition(span, position) { + return position >= span.start && position < textSpanEnd(span); } - ts.isModifier = isModifier; - // Names - function isQualifiedName(node) { - return node.kind === 143 /* QualifiedName */; + ts.textSpanContainsPosition = textSpanContainsPosition; + // Returns true if 'span' contains 'other'. + function textSpanContainsTextSpan(span, other) { + return other.start >= span.start && textSpanEnd(other) <= textSpanEnd(span); } - ts.isQualifiedName = isQualifiedName; - function isComputedPropertyName(node) { - return node.kind === 144 /* ComputedPropertyName */; + ts.textSpanContainsTextSpan = textSpanContainsTextSpan; + function textSpanOverlapsWith(span, other) { + var overlapStart = Math.max(span.start, other.start); + var overlapEnd = Math.min(textSpanEnd(span), textSpanEnd(other)); + return overlapStart < overlapEnd; } - ts.isComputedPropertyName = isComputedPropertyName; - function isEntityName(node) { - var kind = node.kind; - return kind === 143 /* QualifiedName */ - || kind === 71 /* Identifier */; + ts.textSpanOverlapsWith = textSpanOverlapsWith; + function textSpanOverlap(span1, span2) { + var overlapStart = Math.max(span1.start, span2.start); + var overlapEnd = Math.min(textSpanEnd(span1), textSpanEnd(span2)); + if (overlapStart < overlapEnd) { + return createTextSpanFromBounds(overlapStart, overlapEnd); + } + return undefined; } - ts.isEntityName = isEntityName; - function isPropertyName(node) { - var kind = node.kind; - return kind === 71 /* Identifier */ - || kind === 9 /* StringLiteral */ - || kind === 8 /* NumericLiteral */ - || kind === 144 /* ComputedPropertyName */; + ts.textSpanOverlap = textSpanOverlap; + function textSpanIntersectsWithTextSpan(span, other) { + return other.start <= textSpanEnd(span) && textSpanEnd(other) >= span.start; } - ts.isPropertyName = isPropertyName; - function isModuleName(node) { - var kind = node.kind; - return kind === 71 /* Identifier */ - || kind === 9 /* StringLiteral */; + ts.textSpanIntersectsWithTextSpan = textSpanIntersectsWithTextSpan; + function textSpanIntersectsWith(span, start, length) { + var end = start + length; + return start <= textSpanEnd(span) && end >= span.start; } - ts.isModuleName = isModuleName; - function isBindingName(node) { - var kind = node.kind; - return kind === 71 /* Identifier */ - || kind === 174 /* ObjectBindingPattern */ - || kind === 175 /* ArrayBindingPattern */; + ts.textSpanIntersectsWith = textSpanIntersectsWith; + function decodedTextSpanIntersectsWith(start1, length1, start2, length2) { + var end1 = start1 + length1; + var end2 = start2 + length2; + return start2 <= end1 && end2 >= start1; } - ts.isBindingName = isBindingName; - // Signature elements - function isTypeParameter(node) { - return node.kind === 145 /* TypeParameter */; + ts.decodedTextSpanIntersectsWith = decodedTextSpanIntersectsWith; + function textSpanIntersectsWithPosition(span, position) { + return position <= textSpanEnd(span) && position >= span.start; } - ts.isTypeParameter = isTypeParameter; - function isParameter(node) { - return node.kind === 146 /* Parameter */; + ts.textSpanIntersectsWithPosition = textSpanIntersectsWithPosition; + function textSpanIntersection(span1, span2) { + var intersectStart = Math.max(span1.start, span2.start); + var intersectEnd = Math.min(textSpanEnd(span1), textSpanEnd(span2)); + if (intersectStart <= intersectEnd) { + return createTextSpanFromBounds(intersectStart, intersectEnd); + } + return undefined; } - ts.isParameter = isParameter; - function isDecorator(node) { - return node.kind === 147 /* Decorator */; + ts.textSpanIntersection = textSpanIntersection; + function createTextSpan(start, length) { + if (start < 0) { + throw new Error("start < 0"); + } + if (length < 0) { + throw new Error("length < 0"); + } + return { start: start, length: length }; } - ts.isDecorator = isDecorator; - // Type members - function isMethodDeclaration(node) { - return node.kind === 151 /* MethodDeclaration */; + ts.createTextSpan = createTextSpan; + function createTextSpanFromBounds(start, end) { + return createTextSpan(start, end - start); } - ts.isMethodDeclaration = isMethodDeclaration; - function isClassElement(node) { - var kind = node.kind; - return kind === 152 /* Constructor */ - || kind === 149 /* PropertyDeclaration */ - || kind === 151 /* MethodDeclaration */ - || kind === 153 /* GetAccessor */ - || kind === 154 /* SetAccessor */ - || kind === 157 /* IndexSignature */ - || kind === 206 /* SemicolonClassElement */; + ts.createTextSpanFromBounds = createTextSpanFromBounds; + function textChangeRangeNewSpan(range) { + return createTextSpan(range.span.start, range.newLength); } - ts.isClassElement = isClassElement; - function isObjectLiteralElementLike(node) { - var kind = node.kind; - return kind === 261 /* PropertyAssignment */ - || kind === 262 /* ShorthandPropertyAssignment */ - || kind === 263 /* SpreadAssignment */ - || kind === 151 /* MethodDeclaration */ - || kind === 153 /* GetAccessor */ - || kind === 154 /* SetAccessor */ - || kind === 247 /* MissingDeclaration */; + ts.textChangeRangeNewSpan = textChangeRangeNewSpan; + function textChangeRangeIsUnchanged(range) { + return textSpanIsEmpty(range.span) && range.newLength === 0; } - ts.isObjectLiteralElementLike = isObjectLiteralElementLike; - // Type - function isTypeNodeKind(kind) { - return (kind >= 158 /* FirstTypeNode */ && kind <= 173 /* LastTypeNode */) - || kind === 119 /* AnyKeyword */ - || kind === 133 /* NumberKeyword */ - || kind === 134 /* ObjectKeyword */ - || kind === 122 /* BooleanKeyword */ - || kind === 136 /* StringKeyword */ - || kind === 137 /* SymbolKeyword */ - || kind === 99 /* ThisKeyword */ - || kind === 105 /* VoidKeyword */ - || kind === 139 /* UndefinedKeyword */ - || kind === 95 /* NullKeyword */ - || kind === 130 /* NeverKeyword */ - || kind === 201 /* ExpressionWithTypeArguments */; + ts.textChangeRangeIsUnchanged = textChangeRangeIsUnchanged; + function createTextChangeRange(span, newLength) { + if (newLength < 0) { + throw new Error("newLength < 0"); + } + return { span: span, newLength: newLength }; } + ts.createTextChangeRange = createTextChangeRange; + ts.unchangedTextChangeRange = createTextChangeRange(createTextSpan(0, 0), 0); /** - * Node test that determines whether a node is a valid type node. - * This differs from the `isPartOfTypeNode` function which determines whether a node is *part* - * of a TypeNode. + * Called to merge all the changes that occurred across several versions of a script snapshot + * into a single change. i.e. if a user keeps making successive edits to a script we will + * have a text change from V1 to V2, V2 to V3, ..., Vn. + * + * This function will then merge those changes into a single change range valid between V1 and + * Vn. */ - function isTypeNode(node) { - return isTypeNodeKind(node.kind); - } - ts.isTypeNode = isTypeNode; - // Binding patterns - function isArrayBindingPattern(node) { - return node.kind === 175 /* ArrayBindingPattern */; - } - ts.isArrayBindingPattern = isArrayBindingPattern; - function isObjectBindingPattern(node) { - return node.kind === 174 /* ObjectBindingPattern */; - } - ts.isObjectBindingPattern = isObjectBindingPattern; - function isBindingPattern(node) { - if (node) { - var kind = node.kind; - return kind === 175 /* ArrayBindingPattern */ - || kind === 174 /* ObjectBindingPattern */; + function collapseTextChangeRangesAcrossMultipleVersions(changes) { + if (changes.length === 0) { + return ts.unchangedTextChangeRange; } - return false; - } - ts.isBindingPattern = isBindingPattern; - function isAssignmentPattern(node) { - var kind = node.kind; - return kind === 177 /* ArrayLiteralExpression */ - || kind === 178 /* ObjectLiteralExpression */; + if (changes.length === 1) { + return changes[0]; + } + // We change from talking about { { oldStart, oldLength }, newLength } to { oldStart, oldEnd, newEnd } + // as it makes things much easier to reason about. + var change0 = changes[0]; + var oldStartN = change0.span.start; + var oldEndN = textSpanEnd(change0.span); + var newEndN = oldStartN + change0.newLength; + for (var i = 1; i < changes.length; i++) { + var nextChange = changes[i]; + // Consider the following case: + // i.e. two edits. The first represents the text change range { { 10, 50 }, 30 }. i.e. The span starting + // at 10, with length 50 is reduced to length 30. The second represents the text change range { { 30, 30 }, 40 }. + // i.e. the span starting at 30 with length 30 is increased to length 40. + // + // 0 10 20 30 40 50 60 70 80 90 100 + // ------------------------------------------------------------------------------------------------------- + // | / + // | /---- + // T1 | /---- + // | /---- + // | /---- + // ------------------------------------------------------------------------------------------------------- + // | \ + // | \ + // T2 | \ + // | \ + // | \ + // ------------------------------------------------------------------------------------------------------- + // + // Merging these turns out to not be too difficult. First, determining the new start of the change is trivial + // it's just the min of the old and new starts. i.e.: + // + // 0 10 20 30 40 50 60 70 80 90 100 + // ------------------------------------------------------------*------------------------------------------ + // | / + // | /---- + // T1 | /---- + // | /---- + // | /---- + // ----------------------------------------$-------------------$------------------------------------------ + // . | \ + // . | \ + // T2 . | \ + // . | \ + // . | \ + // ----------------------------------------------------------------------*-------------------------------- + // + // (Note the dots represent the newly inferred start. + // Determining the new and old end is also pretty simple. Basically it boils down to paying attention to the + // absolute positions at the asterisks, and the relative change between the dollar signs. Basically, we see + // which if the two $'s precedes the other, and we move that one forward until they line up. in this case that + // means: + // + // 0 10 20 30 40 50 60 70 80 90 100 + // --------------------------------------------------------------------------------*---------------------- + // | / + // | /---- + // T1 | /---- + // | /---- + // | /---- + // ------------------------------------------------------------$------------------------------------------ + // . | \ + // . | \ + // T2 . | \ + // . | \ + // . | \ + // ----------------------------------------------------------------------*-------------------------------- + // + // In other words (in this case), we're recognizing that the second edit happened after where the first edit + // ended with a delta of 20 characters (60 - 40). Thus, if we go back in time to where the first edit started + // that's the same as if we started at char 80 instead of 60. + // + // As it so happens, the same logic applies if the second edit precedes the first edit. In that case rather + // than pushing the first edit forward to match the second, we'll push the second edit forward to match the + // first. + // + // In this case that means we have { oldStart: 10, oldEnd: 80, newEnd: 70 } or, in TextChangeRange + // semantics: { { start: 10, length: 70 }, newLength: 60 } + // + // The math then works out as follows. + // If we have { oldStart1, oldEnd1, newEnd1 } and { oldStart2, oldEnd2, newEnd2 } then we can compute the + // final result like so: + // + // { + // oldStart3: Min(oldStart1, oldStart2), + // oldEnd3 : Max(oldEnd1, oldEnd1 + (oldEnd2 - newEnd1)), + // newEnd3 : Max(newEnd2, newEnd2 + (newEnd1 - oldEnd2)) + // } + var oldStart1 = oldStartN; + var oldEnd1 = oldEndN; + var newEnd1 = newEndN; + var oldStart2 = nextChange.span.start; + var oldEnd2 = textSpanEnd(nextChange.span); + var newEnd2 = oldStart2 + nextChange.newLength; + oldStartN = Math.min(oldStart1, oldStart2); + oldEndN = Math.max(oldEnd1, oldEnd1 + (oldEnd2 - newEnd1)); + newEndN = Math.max(newEnd2, newEnd2 + (newEnd1 - oldEnd2)); + } + return createTextChangeRange(createTextSpanFromBounds(oldStartN, oldEndN), /*newLength*/ newEndN - oldStartN); } - ts.isAssignmentPattern = isAssignmentPattern; - function isBindingElement(node) { - return node.kind === 176 /* BindingElement */; + ts.collapseTextChangeRangesAcrossMultipleVersions = collapseTextChangeRangesAcrossMultipleVersions; + function getTypeParameterOwner(d) { + if (d && d.kind === 145 /* TypeParameter */) { + for (var current = d; current; current = current.parent) { + if (ts.isFunctionLike(current) || ts.isClassLike(current) || current.kind === 230 /* InterfaceDeclaration */) { + return current; + } + } + } } - ts.isBindingElement = isBindingElement; - function isArrayBindingElement(node) { - var kind = node.kind; - return kind === 176 /* BindingElement */ - || kind === 200 /* OmittedExpression */; + ts.getTypeParameterOwner = getTypeParameterOwner; + function isParameterPropertyDeclaration(node) { + return ts.hasModifier(node, 92 /* ParameterPropertyModifier */) && node.parent.kind === 152 /* Constructor */ && ts.isClassLike(node.parent.parent); } - ts.isArrayBindingElement = isArrayBindingElement; - /** - * Determines whether the BindingOrAssignmentElement is a BindingElement-like declaration - */ - function isDeclarationBindingElement(bindingElement) { - switch (bindingElement.kind) { - case 226 /* VariableDeclaration */: - case 146 /* Parameter */: - case 176 /* BindingElement */: - return true; + ts.isParameterPropertyDeclaration = isParameterPropertyDeclaration; + function walkUpBindingElementsAndPatterns(node) { + while (node && (node.kind === 176 /* BindingElement */ || ts.isBindingPattern(node))) { + node = node.parent; } - return false; + return node; } - ts.isDeclarationBindingElement = isDeclarationBindingElement; - /** - * Determines whether a node is a BindingOrAssignmentPattern - */ - function isBindingOrAssignmentPattern(node) { - return isObjectBindingOrAssignmentPattern(node) - || isArrayBindingOrAssignmentPattern(node); + function getCombinedModifierFlags(node) { + node = walkUpBindingElementsAndPatterns(node); + var flags = ts.getModifierFlags(node); + if (node.kind === 226 /* VariableDeclaration */) { + node = node.parent; + } + if (node && node.kind === 227 /* VariableDeclarationList */) { + flags |= ts.getModifierFlags(node); + node = node.parent; + } + if (node && node.kind === 208 /* VariableStatement */) { + flags |= ts.getModifierFlags(node); + } + return flags; } - ts.isBindingOrAssignmentPattern = isBindingOrAssignmentPattern; - /** - * Determines whether a node is an ObjectBindingOrAssignmentPattern - */ - function isObjectBindingOrAssignmentPattern(node) { - switch (node.kind) { - case 174 /* ObjectBindingPattern */: - case 178 /* ObjectLiteralExpression */: - return true; + ts.getCombinedModifierFlags = getCombinedModifierFlags; + // Returns the node flags for this node and all relevant parent nodes. This is done so that + // nodes like variable declarations and binding elements can returned a view of their flags + // that includes the modifiers from their container. i.e. flags like export/declare aren't + // stored on the variable declaration directly, but on the containing variable statement + // (if it has one). Similarly, flags for let/const are store on the variable declaration + // list. By calling this function, all those flags are combined so that the client can treat + // the node as if it actually had those flags. + function getCombinedNodeFlags(node) { + node = walkUpBindingElementsAndPatterns(node); + var flags = node.flags; + if (node.kind === 226 /* VariableDeclaration */) { + node = node.parent; } - return false; + if (node && node.kind === 227 /* VariableDeclarationList */) { + flags |= node.flags; + node = node.parent; + } + if (node && node.kind === 208 /* VariableStatement */) { + flags |= node.flags; + } + return flags; } - ts.isObjectBindingOrAssignmentPattern = isObjectBindingOrAssignmentPattern; + ts.getCombinedNodeFlags = getCombinedNodeFlags; /** - * Determines whether a node is an ArrayBindingOrAssignmentPattern + * Checks to see if the locale is in the appropriate format, + * and if it is, attempts to set the appropriate language. */ - function isArrayBindingOrAssignmentPattern(node) { - switch (node.kind) { - case 175 /* ArrayBindingPattern */: - case 177 /* ArrayLiteralExpression */: - return true; + function validateLocaleAndSetLanguage(locale, sys, errors) { + var matchResult = /^([a-z]+)([_\-]([a-z]+))?$/.exec(locale.toLowerCase()); + if (!matchResult) { + if (errors) { + errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Locale_must_be_of_the_form_language_or_language_territory_For_example_0_or_1, "en", "ja-jp")); + } + return; + } + var language = matchResult[1]; + var territory = matchResult[3]; + // First try the entire locale, then fall back to just language if that's all we have. + // Either ways do not fail, and fallback to the English diagnostic strings. + if (!trySetLanguageAndTerritory(language, territory, errors)) { + trySetLanguageAndTerritory(language, /*territory*/ undefined, errors); + } + function trySetLanguageAndTerritory(language, territory, errors) { + var compilerFilePath = ts.normalizePath(sys.getExecutingFilePath()); + var containingDirectoryPath = ts.getDirectoryPath(compilerFilePath); + var filePath = ts.combinePaths(containingDirectoryPath, language); + if (territory) { + filePath = filePath + "-" + territory; + } + filePath = sys.resolvePath(ts.combinePaths(filePath, "diagnosticMessages.generated.json")); + if (!sys.fileExists(filePath)) { + return false; + } + // TODO: Add codePage support for readFile? + var fileContents = ""; + try { + fileContents = sys.readFile(filePath); + } + catch (e) { + if (errors) { + errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Unable_to_open_file_0, filePath)); + } + return false; + } + try { + ts.localizedDiagnosticMessages = JSON.parse(fileContents); + } + catch (e) { + if (errors) { + errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Corrupted_locale_file_0, filePath)); + } + return false; + } + return true; } - return false; } - ts.isArrayBindingOrAssignmentPattern = isArrayBindingOrAssignmentPattern; + ts.validateLocaleAndSetLanguage = validateLocaleAndSetLanguage; + function getOriginalNode(node, nodeTest) { + if (node) { + while (node.original !== undefined) { + node = node.original; + } + } + return !nodeTest || nodeTest(node) ? node : undefined; + } + ts.getOriginalNode = getOriginalNode; + /** + * Gets a value indicating whether a node originated in the parse tree. + * + * @param node The node to test. + */ + function isParseTreeNode(node) { + return (node.flags & 8 /* Synthesized */) === 0; + } + ts.isParseTreeNode = isParseTreeNode; + function getParseTreeNode(node, nodeTest) { + if (node === undefined || isParseTreeNode(node)) { + return node; + } + node = getOriginalNode(node); + if (isParseTreeNode(node) && (!nodeTest || nodeTest(node))) { + return node; + } + return undefined; + } + ts.getParseTreeNode = getParseTreeNode; + /** + * Remove extra underscore from escaped identifier text content. + * + * @param identifier The escaped identifier text. + * @returns The unescaped identifier text. + */ + function unescapeIdentifier(identifier) { + return identifier.length >= 3 && identifier.charCodeAt(0) === 95 /* _ */ && identifier.charCodeAt(1) === 95 /* _ */ && identifier.charCodeAt(2) === 95 /* _ */ ? identifier.substr(1) : identifier; + } + ts.unescapeIdentifier = unescapeIdentifier; + function getNameOfDeclaration(declaration) { + if (!declaration) { + return undefined; + } + if (declaration.kind === 194 /* BinaryExpression */) { + var expr = declaration; + switch (ts.getSpecialPropertyAssignmentKind(expr)) { + case 1 /* ExportsProperty */: + case 4 /* ThisProperty */: + case 5 /* Property */: + case 3 /* PrototypeProperty */: + return expr.left.name; + default: + return undefined; + } + } + else { + return declaration.name; + } + } + ts.getNameOfDeclaration = getNameOfDeclaration; +})(ts || (ts = {})); +// Simple node tests of the form `node.kind === SyntaxKind.Foo`. +(function (ts) { + // Literals + function isNumericLiteral(node) { + return node.kind === 8 /* NumericLiteral */; + } + ts.isNumericLiteral = isNumericLiteral; + function isStringLiteral(node) { + return node.kind === 9 /* StringLiteral */; + } + ts.isStringLiteral = isStringLiteral; + function isJsxText(node) { + return node.kind === 10 /* JsxText */; + } + ts.isJsxText = isJsxText; + function isRegularExpressionLiteral(node) { + return node.kind === 12 /* RegularExpressionLiteral */; + } + ts.isRegularExpressionLiteral = isRegularExpressionLiteral; + function isNoSubstitutionTemplateLiteral(node) { + return node.kind === 13 /* NoSubstitutionTemplateLiteral */; + } + ts.isNoSubstitutionTemplateLiteral = isNoSubstitutionTemplateLiteral; + // Pseudo-literals + function isTemplateHead(node) { + return node.kind === 14 /* TemplateHead */; + } + ts.isTemplateHead = isTemplateHead; + function isTemplateMiddle(node) { + return node.kind === 15 /* TemplateMiddle */; + } + ts.isTemplateMiddle = isTemplateMiddle; + function isTemplateTail(node) { + return node.kind === 16 /* TemplateTail */; + } + ts.isTemplateTail = isTemplateTail; + function isIdentifier(node) { + return node.kind === 71 /* Identifier */; + } + ts.isIdentifier = isIdentifier; + // Names + function isQualifiedName(node) { + return node.kind === 143 /* QualifiedName */; + } + ts.isQualifiedName = isQualifiedName; + function isComputedPropertyName(node) { + return node.kind === 144 /* ComputedPropertyName */; + } + ts.isComputedPropertyName = isComputedPropertyName; + // Signature elements + function isTypeParameterDeclaration(node) { + return node.kind === 145 /* TypeParameter */; + } + ts.isTypeParameterDeclaration = isTypeParameterDeclaration; + function isParameter(node) { + return node.kind === 146 /* Parameter */; + } + ts.isParameter = isParameter; + function isDecorator(node) { + return node.kind === 147 /* Decorator */; + } + ts.isDecorator = isDecorator; + // TypeMember + function isPropertySignature(node) { + return node.kind === 148 /* PropertySignature */; + } + ts.isPropertySignature = isPropertySignature; + function isPropertyDeclaration(node) { + return node.kind === 149 /* PropertyDeclaration */; + } + ts.isPropertyDeclaration = isPropertyDeclaration; + function isMethodSignature(node) { + return node.kind === 150 /* MethodSignature */; + } + ts.isMethodSignature = isMethodSignature; + function isMethodDeclaration(node) { + return node.kind === 151 /* MethodDeclaration */; + } + ts.isMethodDeclaration = isMethodDeclaration; + function isConstructorDeclaration(node) { + return node.kind === 152 /* Constructor */; + } + ts.isConstructorDeclaration = isConstructorDeclaration; + function isGetAccessorDeclaration(node) { + return node.kind === 153 /* GetAccessor */; + } + ts.isGetAccessorDeclaration = isGetAccessorDeclaration; + function isSetAccessorDeclaration(node) { + return node.kind === 154 /* SetAccessor */; + } + ts.isSetAccessorDeclaration = isSetAccessorDeclaration; + function isCallSignatureDeclaration(node) { + return node.kind === 155 /* CallSignature */; + } + ts.isCallSignatureDeclaration = isCallSignatureDeclaration; + function isConstructSignatureDeclaration(node) { + return node.kind === 156 /* ConstructSignature */; + } + ts.isConstructSignatureDeclaration = isConstructSignatureDeclaration; + function isIndexSignatureDeclaration(node) { + return node.kind === 157 /* IndexSignature */; + } + ts.isIndexSignatureDeclaration = isIndexSignatureDeclaration; + // Type + function isTypePredicateNode(node) { + return node.kind === 158 /* TypePredicate */; + } + ts.isTypePredicateNode = isTypePredicateNode; + function isTypeReferenceNode(node) { + return node.kind === 159 /* TypeReference */; + } + ts.isTypeReferenceNode = isTypeReferenceNode; + function isFunctionTypeNode(node) { + return node.kind === 160 /* FunctionType */; + } + ts.isFunctionTypeNode = isFunctionTypeNode; + function isConstructorTypeNode(node) { + return node.kind === 161 /* ConstructorType */; + } + ts.isConstructorTypeNode = isConstructorTypeNode; + function isTypeQueryNode(node) { + return node.kind === 162 /* TypeQuery */; + } + ts.isTypeQueryNode = isTypeQueryNode; + function isTypeLiteralNode(node) { + return node.kind === 163 /* TypeLiteral */; + } + ts.isTypeLiteralNode = isTypeLiteralNode; + function isArrayTypeNode(node) { + return node.kind === 164 /* ArrayType */; + } + ts.isArrayTypeNode = isArrayTypeNode; + function isTupleTypeNode(node) { + return node.kind === 165 /* TupleType */; + } + ts.isTupleTypeNode = isTupleTypeNode; + function isUnionTypeNode(node) { + return node.kind === 166 /* UnionType */; + } + ts.isUnionTypeNode = isUnionTypeNode; + function isIntersectionTypeNode(node) { + return node.kind === 167 /* IntersectionType */; + } + ts.isIntersectionTypeNode = isIntersectionTypeNode; + function isParenthesizedTypeNode(node) { + return node.kind === 168 /* ParenthesizedType */; + } + ts.isParenthesizedTypeNode = isParenthesizedTypeNode; + function isThisTypeNode(node) { + return node.kind === 169 /* ThisType */; + } + ts.isThisTypeNode = isThisTypeNode; + function isTypeOperatorNode(node) { + return node.kind === 170 /* TypeOperator */; + } + ts.isTypeOperatorNode = isTypeOperatorNode; + function isIndexedAccessTypeNode(node) { + return node.kind === 171 /* IndexedAccessType */; + } + ts.isIndexedAccessTypeNode = isIndexedAccessTypeNode; + function isMappedTypeNode(node) { + return node.kind === 172 /* MappedType */; + } + ts.isMappedTypeNode = isMappedTypeNode; + function isLiteralTypeNode(node) { + return node.kind === 173 /* LiteralType */; + } + ts.isLiteralTypeNode = isLiteralTypeNode; + // Binding patterns + function isObjectBindingPattern(node) { + return node.kind === 174 /* ObjectBindingPattern */; + } + ts.isObjectBindingPattern = isObjectBindingPattern; + function isArrayBindingPattern(node) { + return node.kind === 175 /* ArrayBindingPattern */; + } + ts.isArrayBindingPattern = isArrayBindingPattern; + function isBindingElement(node) { + return node.kind === 176 /* BindingElement */; + } + ts.isBindingElement = isBindingElement; // Expression function isArrayLiteralExpression(node) { return node.kind === 177 /* ArrayLiteralExpression */; @@ -10156,16 +10766,62 @@ var ts; return node.kind === 179 /* PropertyAccessExpression */; } ts.isPropertyAccessExpression = isPropertyAccessExpression; - function isPropertyAccessOrQualifiedName(node) { - var kind = node.kind; - return kind === 179 /* PropertyAccessExpression */ - || kind === 143 /* QualifiedName */; - } - ts.isPropertyAccessOrQualifiedName = isPropertyAccessOrQualifiedName; function isElementAccessExpression(node) { return node.kind === 180 /* ElementAccessExpression */; } ts.isElementAccessExpression = isElementAccessExpression; + function isCallExpression(node) { + return node.kind === 181 /* CallExpression */; + } + ts.isCallExpression = isCallExpression; + function isNewExpression(node) { + return node.kind === 182 /* NewExpression */; + } + ts.isNewExpression = isNewExpression; + function isTaggedTemplateExpression(node) { + return node.kind === 183 /* TaggedTemplateExpression */; + } + ts.isTaggedTemplateExpression = isTaggedTemplateExpression; + function isTypeAssertion(node) { + return node.kind === 184 /* TypeAssertionExpression */; + } + ts.isTypeAssertion = isTypeAssertion; + function isParenthesizedExpression(node) { + return node.kind === 185 /* ParenthesizedExpression */; + } + ts.isParenthesizedExpression = isParenthesizedExpression; + function isFunctionExpression(node) { + return node.kind === 186 /* FunctionExpression */; + } + ts.isFunctionExpression = isFunctionExpression; + function isArrowFunction(node) { + return node.kind === 187 /* ArrowFunction */; + } + ts.isArrowFunction = isArrowFunction; + function isDeleteExpression(node) { + return node.kind === 188 /* DeleteExpression */; + } + ts.isDeleteExpression = isDeleteExpression; + function isTypeOfExpression(node) { + return node.kind === 191 /* AwaitExpression */; + } + ts.isTypeOfExpression = isTypeOfExpression; + function isVoidExpression(node) { + return node.kind === 190 /* VoidExpression */; + } + ts.isVoidExpression = isVoidExpression; + function isAwaitExpression(node) { + return node.kind === 191 /* AwaitExpression */; + } + ts.isAwaitExpression = isAwaitExpression; + function isPrefixUnaryExpression(node) { + return node.kind === 192 /* PrefixUnaryExpression */; + } + ts.isPrefixUnaryExpression = isPrefixUnaryExpression; + function isPostfixUnaryExpression(node) { + return node.kind === 193 /* PostfixUnaryExpression */; + } + ts.isPostfixUnaryExpression = isPostfixUnaryExpression; function isBinaryExpression(node) { return node.kind === 194 /* BinaryExpression */; } @@ -10174,24 +10830,716 @@ var ts; return node.kind === 195 /* ConditionalExpression */; } ts.isConditionalExpression = isConditionalExpression; - function isCallExpression(node) { - return node.kind === 181 /* CallExpression */; + function isTemplateExpression(node) { + return node.kind === 196 /* TemplateExpression */; } - ts.isCallExpression = isCallExpression; - function isTemplateLiteral(node) { - var kind = node.kind; - return kind === 196 /* TemplateExpression */ - || kind === 13 /* NoSubstitutionTemplateLiteral */; + ts.isTemplateExpression = isTemplateExpression; + function isYieldExpression(node) { + return node.kind === 197 /* YieldExpression */; } - ts.isTemplateLiteral = isTemplateLiteral; - function isSpreadExpression(node) { + ts.isYieldExpression = isYieldExpression; + function isSpreadElement(node) { return node.kind === 198 /* SpreadElement */; } - ts.isSpreadExpression = isSpreadExpression; + ts.isSpreadElement = isSpreadElement; + function isClassExpression(node) { + return node.kind === 199 /* ClassExpression */; + } + ts.isClassExpression = isClassExpression; + function isOmittedExpression(node) { + return node.kind === 200 /* OmittedExpression */; + } + ts.isOmittedExpression = isOmittedExpression; function isExpressionWithTypeArguments(node) { return node.kind === 201 /* ExpressionWithTypeArguments */; } ts.isExpressionWithTypeArguments = isExpressionWithTypeArguments; + function isAsExpression(node) { + return node.kind === 202 /* AsExpression */; + } + ts.isAsExpression = isAsExpression; + function isNonNullExpression(node) { + return node.kind === 203 /* NonNullExpression */; + } + ts.isNonNullExpression = isNonNullExpression; + function isMetaProperty(node) { + return node.kind === 204 /* MetaProperty */; + } + ts.isMetaProperty = isMetaProperty; + // Misc + function isTemplateSpan(node) { + return node.kind === 205 /* TemplateSpan */; + } + ts.isTemplateSpan = isTemplateSpan; + function isSemicolonClassElement(node) { + return node.kind === 206 /* SemicolonClassElement */; + } + ts.isSemicolonClassElement = isSemicolonClassElement; + // Block + function isBlock(node) { + return node.kind === 207 /* Block */; + } + ts.isBlock = isBlock; + function isVariableStatement(node) { + return node.kind === 208 /* VariableStatement */; + } + ts.isVariableStatement = isVariableStatement; + function isEmptyStatement(node) { + return node.kind === 209 /* EmptyStatement */; + } + ts.isEmptyStatement = isEmptyStatement; + function isExpressionStatement(node) { + return node.kind === 210 /* ExpressionStatement */; + } + ts.isExpressionStatement = isExpressionStatement; + function isIfStatement(node) { + return node.kind === 211 /* IfStatement */; + } + ts.isIfStatement = isIfStatement; + function isDoStatement(node) { + return node.kind === 212 /* DoStatement */; + } + ts.isDoStatement = isDoStatement; + function isWhileStatement(node) { + return node.kind === 213 /* WhileStatement */; + } + ts.isWhileStatement = isWhileStatement; + function isForStatement(node) { + return node.kind === 214 /* ForStatement */; + } + ts.isForStatement = isForStatement; + function isForInStatement(node) { + return node.kind === 215 /* ForInStatement */; + } + ts.isForInStatement = isForInStatement; + function isForOfStatement(node) { + return node.kind === 216 /* ForOfStatement */; + } + ts.isForOfStatement = isForOfStatement; + function isContinueStatement(node) { + return node.kind === 217 /* ContinueStatement */; + } + ts.isContinueStatement = isContinueStatement; + function isBreakStatement(node) { + return node.kind === 218 /* BreakStatement */; + } + ts.isBreakStatement = isBreakStatement; + function isReturnStatement(node) { + return node.kind === 219 /* ReturnStatement */; + } + ts.isReturnStatement = isReturnStatement; + function isWithStatement(node) { + return node.kind === 220 /* WithStatement */; + } + ts.isWithStatement = isWithStatement; + function isSwitchStatement(node) { + return node.kind === 221 /* SwitchStatement */; + } + ts.isSwitchStatement = isSwitchStatement; + function isLabeledStatement(node) { + return node.kind === 222 /* LabeledStatement */; + } + ts.isLabeledStatement = isLabeledStatement; + function isThrowStatement(node) { + return node.kind === 223 /* ThrowStatement */; + } + ts.isThrowStatement = isThrowStatement; + function isTryStatement(node) { + return node.kind === 224 /* TryStatement */; + } + ts.isTryStatement = isTryStatement; + function isDebuggerStatement(node) { + return node.kind === 225 /* DebuggerStatement */; + } + ts.isDebuggerStatement = isDebuggerStatement; + function isVariableDeclaration(node) { + return node.kind === 226 /* VariableDeclaration */; + } + ts.isVariableDeclaration = isVariableDeclaration; + function isVariableDeclarationList(node) { + return node.kind === 227 /* VariableDeclarationList */; + } + ts.isVariableDeclarationList = isVariableDeclarationList; + function isFunctionDeclaration(node) { + return node.kind === 228 /* FunctionDeclaration */; + } + ts.isFunctionDeclaration = isFunctionDeclaration; + function isClassDeclaration(node) { + return node.kind === 229 /* ClassDeclaration */; + } + ts.isClassDeclaration = isClassDeclaration; + function isInterfaceDeclaration(node) { + return node.kind === 230 /* InterfaceDeclaration */; + } + ts.isInterfaceDeclaration = isInterfaceDeclaration; + function isTypeAliasDeclaration(node) { + return node.kind === 231 /* TypeAliasDeclaration */; + } + ts.isTypeAliasDeclaration = isTypeAliasDeclaration; + function isEnumDeclaration(node) { + return node.kind === 232 /* EnumDeclaration */; + } + ts.isEnumDeclaration = isEnumDeclaration; + function isModuleDeclaration(node) { + return node.kind === 233 /* ModuleDeclaration */; + } + ts.isModuleDeclaration = isModuleDeclaration; + function isModuleBlock(node) { + return node.kind === 234 /* ModuleBlock */; + } + ts.isModuleBlock = isModuleBlock; + function isCaseBlock(node) { + return node.kind === 235 /* CaseBlock */; + } + ts.isCaseBlock = isCaseBlock; + function isNamespaceExportDeclaration(node) { + return node.kind === 236 /* NamespaceExportDeclaration */; + } + ts.isNamespaceExportDeclaration = isNamespaceExportDeclaration; + function isImportEqualsDeclaration(node) { + return node.kind === 237 /* ImportEqualsDeclaration */; + } + ts.isImportEqualsDeclaration = isImportEqualsDeclaration; + function isImportDeclaration(node) { + return node.kind === 238 /* ImportDeclaration */; + } + ts.isImportDeclaration = isImportDeclaration; + function isImportClause(node) { + return node.kind === 239 /* ImportClause */; + } + ts.isImportClause = isImportClause; + function isNamespaceImport(node) { + return node.kind === 240 /* NamespaceImport */; + } + ts.isNamespaceImport = isNamespaceImport; + function isNamedImports(node) { + return node.kind === 241 /* NamedImports */; + } + ts.isNamedImports = isNamedImports; + function isImportSpecifier(node) { + return node.kind === 242 /* ImportSpecifier */; + } + ts.isImportSpecifier = isImportSpecifier; + function isExportAssignment(node) { + return node.kind === 243 /* ExportAssignment */; + } + ts.isExportAssignment = isExportAssignment; + function isExportDeclaration(node) { + return node.kind === 244 /* ExportDeclaration */; + } + ts.isExportDeclaration = isExportDeclaration; + function isNamedExports(node) { + return node.kind === 245 /* NamedExports */; + } + ts.isNamedExports = isNamedExports; + function isExportSpecifier(node) { + return node.kind === 246 /* ExportSpecifier */; + } + ts.isExportSpecifier = isExportSpecifier; + function isMissingDeclaration(node) { + return node.kind === 247 /* MissingDeclaration */; + } + ts.isMissingDeclaration = isMissingDeclaration; + // Module References + function isExternalModuleReference(node) { + return node.kind === 248 /* ExternalModuleReference */; + } + ts.isExternalModuleReference = isExternalModuleReference; + // JSX + function isJsxElement(node) { + return node.kind === 249 /* JsxElement */; + } + ts.isJsxElement = isJsxElement; + function isJsxSelfClosingElement(node) { + return node.kind === 250 /* JsxSelfClosingElement */; + } + ts.isJsxSelfClosingElement = isJsxSelfClosingElement; + function isJsxOpeningElement(node) { + return node.kind === 251 /* JsxOpeningElement */; + } + ts.isJsxOpeningElement = isJsxOpeningElement; + function isJsxClosingElement(node) { + return node.kind === 252 /* JsxClosingElement */; + } + ts.isJsxClosingElement = isJsxClosingElement; + function isJsxAttribute(node) { + return node.kind === 253 /* JsxAttribute */; + } + ts.isJsxAttribute = isJsxAttribute; + function isJsxAttributes(node) { + return node.kind === 254 /* JsxAttributes */; + } + ts.isJsxAttributes = isJsxAttributes; + function isJsxSpreadAttribute(node) { + return node.kind === 255 /* JsxSpreadAttribute */; + } + ts.isJsxSpreadAttribute = isJsxSpreadAttribute; + function isJsxExpression(node) { + return node.kind === 256 /* JsxExpression */; + } + ts.isJsxExpression = isJsxExpression; + // Clauses + function isCaseClause(node) { + return node.kind === 257 /* CaseClause */; + } + ts.isCaseClause = isCaseClause; + function isDefaultClause(node) { + return node.kind === 258 /* DefaultClause */; + } + ts.isDefaultClause = isDefaultClause; + function isHeritageClause(node) { + return node.kind === 259 /* HeritageClause */; + } + ts.isHeritageClause = isHeritageClause; + function isCatchClause(node) { + return node.kind === 260 /* CatchClause */; + } + ts.isCatchClause = isCatchClause; + // Property assignments + function isPropertyAssignment(node) { + return node.kind === 261 /* PropertyAssignment */; + } + ts.isPropertyAssignment = isPropertyAssignment; + function isShorthandPropertyAssignment(node) { + return node.kind === 262 /* ShorthandPropertyAssignment */; + } + ts.isShorthandPropertyAssignment = isShorthandPropertyAssignment; + function isSpreadAssignment(node) { + return node.kind === 263 /* SpreadAssignment */; + } + ts.isSpreadAssignment = isSpreadAssignment; + // Enum + function isEnumMember(node) { + return node.kind === 264 /* EnumMember */; + } + ts.isEnumMember = isEnumMember; + // Top-level nodes + function isSourceFile(node) { + return node.kind === 265 /* SourceFile */; + } + ts.isSourceFile = isSourceFile; + function isBundle(node) { + return node.kind === 266 /* Bundle */; + } + ts.isBundle = isBundle; + // JSDoc + function isJSDocTypeExpression(node) { + return node.kind === 267 /* JSDocTypeExpression */; + } + ts.isJSDocTypeExpression = isJSDocTypeExpression; + function isJSDocAllType(node) { + return node.kind === 268 /* JSDocAllType */; + } + ts.isJSDocAllType = isJSDocAllType; + function isJSDocUnknownType(node) { + return node.kind === 269 /* JSDocUnknownType */; + } + ts.isJSDocUnknownType = isJSDocUnknownType; + function isJSDocArrayType(node) { + return node.kind === 270 /* JSDocArrayType */; + } + ts.isJSDocArrayType = isJSDocArrayType; + function isJSDocUnionType(node) { + return node.kind === 271 /* JSDocUnionType */; + } + ts.isJSDocUnionType = isJSDocUnionType; + function isJSDocTupleType(node) { + return node.kind === 272 /* JSDocTupleType */; + } + ts.isJSDocTupleType = isJSDocTupleType; + function isJSDocNullableType(node) { + return node.kind === 273 /* JSDocNullableType */; + } + ts.isJSDocNullableType = isJSDocNullableType; + function isJSDocNonNullableType(node) { + return node.kind === 274 /* JSDocNonNullableType */; + } + ts.isJSDocNonNullableType = isJSDocNonNullableType; + function isJSDocRecordType(node) { + return node.kind === 275 /* JSDocRecordType */; + } + ts.isJSDocRecordType = isJSDocRecordType; + function isJSDocRecordMember(node) { + return node.kind === 276 /* JSDocRecordMember */; + } + ts.isJSDocRecordMember = isJSDocRecordMember; + function isJSDocTypeReference(node) { + return node.kind === 277 /* JSDocTypeReference */; + } + ts.isJSDocTypeReference = isJSDocTypeReference; + function isJSDocOptionalType(node) { + return node.kind === 278 /* JSDocOptionalType */; + } + ts.isJSDocOptionalType = isJSDocOptionalType; + function isJSDocFunctionType(node) { + return node.kind === 279 /* JSDocFunctionType */; + } + ts.isJSDocFunctionType = isJSDocFunctionType; + function isJSDocVariadicType(node) { + return node.kind === 280 /* JSDocVariadicType */; + } + ts.isJSDocVariadicType = isJSDocVariadicType; + function isJSDocConstructorType(node) { + return node.kind === 281 /* JSDocConstructorType */; + } + ts.isJSDocConstructorType = isJSDocConstructorType; + function isJSDocThisType(node) { + return node.kind === 282 /* JSDocThisType */; + } + ts.isJSDocThisType = isJSDocThisType; + function isJSDoc(node) { + return node.kind === 283 /* JSDocComment */; + } + ts.isJSDoc = isJSDoc; + function isJSDocAugmentsTag(node) { + return node.kind === 285 /* JSDocAugmentsTag */; + } + ts.isJSDocAugmentsTag = isJSDocAugmentsTag; + function isJSDocParameterTag(node) { + return node.kind === 287 /* JSDocParameterTag */; + } + ts.isJSDocParameterTag = isJSDocParameterTag; + function isJSDocReturnTag(node) { + return node.kind === 288 /* JSDocReturnTag */; + } + ts.isJSDocReturnTag = isJSDocReturnTag; + function isJSDocTypeTag(node) { + return node.kind === 289 /* JSDocTypeTag */; + } + ts.isJSDocTypeTag = isJSDocTypeTag; + function isJSDocTemplateTag(node) { + return node.kind === 290 /* JSDocTemplateTag */; + } + ts.isJSDocTemplateTag = isJSDocTemplateTag; + function isJSDocTypedefTag(node) { + return node.kind === 291 /* JSDocTypedefTag */; + } + ts.isJSDocTypedefTag = isJSDocTypedefTag; + function isJSDocPropertyTag(node) { + return node.kind === 292 /* JSDocPropertyTag */; + } + ts.isJSDocPropertyTag = isJSDocPropertyTag; + function isJSDocTypeLiteral(node) { + return node.kind === 293 /* JSDocTypeLiteral */; + } + ts.isJSDocTypeLiteral = isJSDocTypeLiteral; + function isJSDocLiteralType(node) { + return node.kind === 294 /* JSDocLiteralType */; + } + ts.isJSDocLiteralType = isJSDocLiteralType; +})(ts || (ts = {})); +// Node tests +// +// All node tests in the following list should *not* reference parent pointers so that +// they may be used with transformations. +(function (ts) { + /* @internal */ + function isNode(node) { + return isNodeKind(node.kind); + } + ts.isNode = isNode; + /* @internal */ + function isNodeKind(kind) { + return kind >= 143 /* FirstNode */; + } + ts.isNodeKind = isNodeKind; + /** + * True if node is of some token syntax kind. + * For example, this is true for an IfKeyword but not for an IfStatement. + */ + function isToken(n) { + return n.kind >= 0 /* FirstToken */ && n.kind <= 142 /* LastToken */; + } + ts.isToken = isToken; + // Node Arrays + /* @internal */ + function isNodeArray(array) { + return array.hasOwnProperty("pos") + && array.hasOwnProperty("end"); + } + ts.isNodeArray = isNodeArray; + // Literals + /* @internal */ + function isLiteralKind(kind) { + return 8 /* FirstLiteralToken */ <= kind && kind <= 13 /* LastLiteralToken */; + } + ts.isLiteralKind = isLiteralKind; + function isLiteralExpression(node) { + return isLiteralKind(node.kind); + } + ts.isLiteralExpression = isLiteralExpression; + // Pseudo-literals + /* @internal */ + function isTemplateLiteralKind(kind) { + return 13 /* FirstTemplateToken */ <= kind && kind <= 16 /* LastTemplateToken */; + } + ts.isTemplateLiteralKind = isTemplateLiteralKind; + function isTemplateMiddleOrTemplateTail(node) { + var kind = node.kind; + return kind === 15 /* TemplateMiddle */ + || kind === 16 /* TemplateTail */; + } + ts.isTemplateMiddleOrTemplateTail = isTemplateMiddleOrTemplateTail; + // Identifiers + /* @internal */ + function isGeneratedIdentifier(node) { + // Using `>` here catches both `GeneratedIdentifierKind.None` and `undefined`. + return ts.isIdentifier(node) && node.autoGenerateKind > 0 /* None */; + } + ts.isGeneratedIdentifier = isGeneratedIdentifier; + // Keywords + /* @internal */ + function isModifierKind(token) { + switch (token) { + case 117 /* AbstractKeyword */: + case 120 /* AsyncKeyword */: + case 76 /* ConstKeyword */: + case 124 /* DeclareKeyword */: + case 79 /* DefaultKeyword */: + case 84 /* ExportKeyword */: + case 114 /* PublicKeyword */: + case 112 /* PrivateKeyword */: + case 113 /* ProtectedKeyword */: + case 131 /* ReadonlyKeyword */: + case 115 /* StaticKeyword */: + return true; + } + return false; + } + ts.isModifierKind = isModifierKind; + function isModifier(node) { + return isModifierKind(node.kind); + } + ts.isModifier = isModifier; + function isEntityName(node) { + var kind = node.kind; + return kind === 143 /* QualifiedName */ + || kind === 71 /* Identifier */; + } + ts.isEntityName = isEntityName; + function isPropertyName(node) { + var kind = node.kind; + return kind === 71 /* Identifier */ + || kind === 9 /* StringLiteral */ + || kind === 8 /* NumericLiteral */ + || kind === 144 /* ComputedPropertyName */; + } + ts.isPropertyName = isPropertyName; + function isBindingName(node) { + var kind = node.kind; + return kind === 71 /* Identifier */ + || kind === 174 /* ObjectBindingPattern */ + || kind === 175 /* ArrayBindingPattern */; + } + ts.isBindingName = isBindingName; + // Functions + function isFunctionLike(node) { + return node && isFunctionLikeKind(node.kind); + } + ts.isFunctionLike = isFunctionLike; + /* @internal */ + function isFunctionLikeKind(kind) { + switch (kind) { + case 152 /* Constructor */: + case 186 /* FunctionExpression */: + case 228 /* FunctionDeclaration */: + case 187 /* ArrowFunction */: + case 151 /* MethodDeclaration */: + case 150 /* MethodSignature */: + case 153 /* GetAccessor */: + case 154 /* SetAccessor */: + case 155 /* CallSignature */: + case 156 /* ConstructSignature */: + case 157 /* IndexSignature */: + case 160 /* FunctionType */: + case 161 /* ConstructorType */: + return true; + } + return false; + } + ts.isFunctionLikeKind = isFunctionLikeKind; + // Classes + function isClassElement(node) { + var kind = node.kind; + return kind === 152 /* Constructor */ + || kind === 149 /* PropertyDeclaration */ + || kind === 151 /* MethodDeclaration */ + || kind === 153 /* GetAccessor */ + || kind === 154 /* SetAccessor */ + || kind === 157 /* IndexSignature */ + || kind === 206 /* SemicolonClassElement */ + || kind === 247 /* MissingDeclaration */; + } + ts.isClassElement = isClassElement; + function isClassLike(node) { + return node && (node.kind === 229 /* ClassDeclaration */ || node.kind === 199 /* ClassExpression */); + } + ts.isClassLike = isClassLike; + function isAccessor(node) { + return node && (node.kind === 153 /* GetAccessor */ || node.kind === 154 /* SetAccessor */); + } + ts.isAccessor = isAccessor; + // Type members + function isTypeElement(node) { + var kind = node.kind; + return kind === 156 /* ConstructSignature */ + || kind === 155 /* CallSignature */ + || kind === 148 /* PropertySignature */ + || kind === 150 /* MethodSignature */ + || kind === 157 /* IndexSignature */ + || kind === 247 /* MissingDeclaration */; + } + ts.isTypeElement = isTypeElement; + function isObjectLiteralElementLike(node) { + var kind = node.kind; + return kind === 261 /* PropertyAssignment */ + || kind === 262 /* ShorthandPropertyAssignment */ + || kind === 263 /* SpreadAssignment */ + || kind === 151 /* MethodDeclaration */ + || kind === 153 /* GetAccessor */ + || kind === 154 /* SetAccessor */ + || kind === 247 /* MissingDeclaration */; + } + ts.isObjectLiteralElementLike = isObjectLiteralElementLike; + // Type + function isTypeNodeKind(kind) { + return (kind >= 158 /* FirstTypeNode */ && kind <= 173 /* LastTypeNode */) + || kind === 119 /* AnyKeyword */ + || kind === 133 /* NumberKeyword */ + || kind === 134 /* ObjectKeyword */ + || kind === 122 /* BooleanKeyword */ + || kind === 136 /* StringKeyword */ + || kind === 137 /* SymbolKeyword */ + || kind === 99 /* ThisKeyword */ + || kind === 105 /* VoidKeyword */ + || kind === 139 /* UndefinedKeyword */ + || kind === 95 /* NullKeyword */ + || kind === 130 /* NeverKeyword */ + || kind === 201 /* ExpressionWithTypeArguments */; + } + /** + * Node test that determines whether a node is a valid type node. + * This differs from the `isPartOfTypeNode` function which determines whether a node is *part* + * of a TypeNode. + */ + function isTypeNode(node) { + return isTypeNodeKind(node.kind); + } + ts.isTypeNode = isTypeNode; + function isFunctionOrConstructorTypeNode(node) { + switch (node.kind) { + case 160 /* FunctionType */: + case 161 /* ConstructorType */: + return true; + } + return false; + } + ts.isFunctionOrConstructorTypeNode = isFunctionOrConstructorTypeNode; + // Binding patterns + /* @internal */ + function isBindingPattern(node) { + if (node) { + var kind = node.kind; + return kind === 175 /* ArrayBindingPattern */ + || kind === 174 /* ObjectBindingPattern */; + } + return false; + } + ts.isBindingPattern = isBindingPattern; + /* @internal */ + function isAssignmentPattern(node) { + var kind = node.kind; + return kind === 177 /* ArrayLiteralExpression */ + || kind === 178 /* ObjectLiteralExpression */; + } + ts.isAssignmentPattern = isAssignmentPattern; + /* @internal */ + function isArrayBindingElement(node) { + var kind = node.kind; + return kind === 176 /* BindingElement */ + || kind === 200 /* OmittedExpression */; + } + ts.isArrayBindingElement = isArrayBindingElement; + /** + * Determines whether the BindingOrAssignmentElement is a BindingElement-like declaration + */ + /* @internal */ + function isDeclarationBindingElement(bindingElement) { + switch (bindingElement.kind) { + case 226 /* VariableDeclaration */: + case 146 /* Parameter */: + case 176 /* BindingElement */: + return true; + } + return false; + } + ts.isDeclarationBindingElement = isDeclarationBindingElement; + /** + * Determines whether a node is a BindingOrAssignmentPattern + */ + /* @internal */ + function isBindingOrAssignmentPattern(node) { + return isObjectBindingOrAssignmentPattern(node) + || isArrayBindingOrAssignmentPattern(node); + } + ts.isBindingOrAssignmentPattern = isBindingOrAssignmentPattern; + /** + * Determines whether a node is an ObjectBindingOrAssignmentPattern + */ + /* @internal */ + function isObjectBindingOrAssignmentPattern(node) { + switch (node.kind) { + case 174 /* ObjectBindingPattern */: + case 178 /* ObjectLiteralExpression */: + return true; + } + return false; + } + ts.isObjectBindingOrAssignmentPattern = isObjectBindingOrAssignmentPattern; + /** + * Determines whether a node is an ArrayBindingOrAssignmentPattern + */ + /* @internal */ + function isArrayBindingOrAssignmentPattern(node) { + switch (node.kind) { + case 175 /* ArrayBindingPattern */: + case 177 /* ArrayLiteralExpression */: + return true; + } + return false; + } + ts.isArrayBindingOrAssignmentPattern = isArrayBindingOrAssignmentPattern; + // Expression + function isPropertyAccessOrQualifiedName(node) { + var kind = node.kind; + return kind === 179 /* PropertyAccessExpression */ + || kind === 143 /* QualifiedName */; + } + ts.isPropertyAccessOrQualifiedName = isPropertyAccessOrQualifiedName; + function isCallLikeExpression(node) { + switch (node.kind) { + case 251 /* JsxOpeningElement */: + case 250 /* JsxSelfClosingElement */: + case 181 /* CallExpression */: + case 182 /* NewExpression */: + case 183 /* TaggedTemplateExpression */: + case 147 /* Decorator */: + return true; + default: + return false; + } + } + ts.isCallLikeExpression = isCallLikeExpression; + function isCallOrNewExpression(node) { + return node.kind === 181 /* CallExpression */ || node.kind === 182 /* NewExpression */; + } + ts.isCallOrNewExpression = isCallOrNewExpression; + function isTemplateLiteral(node) { + var kind = node.kind; + return kind === 196 /* TemplateExpression */ + || kind === 13 /* NoSubstitutionTemplateLiteral */; + } + ts.isTemplateLiteral = isTemplateLiteral; function isLeftHandSideExpressionKind(kind) { return kind === 179 /* PropertyAccessExpression */ || kind === 180 /* ElementAccessExpression */ @@ -10219,6 +11567,7 @@ var ts; || kind === 203 /* NonNullExpression */ || kind === 204 /* MetaProperty */; } + /* @internal */ function isLeftHandSideExpression(node) { return isLeftHandSideExpressionKind(ts.skipPartiallyEmittedExpressions(node).kind); } @@ -10233,6 +11582,7 @@ var ts; || kind === 184 /* TypeAssertionExpression */ || isLeftHandSideExpressionKind(kind); } + /* @internal */ function isUnaryExpression(node) { return isUnaryExpressionKind(ts.skipPartiallyEmittedExpressions(node).kind); } @@ -10245,8 +11595,10 @@ var ts; || kind === 198 /* SpreadElement */ || kind === 202 /* AsExpression */ || kind === 200 /* OmittedExpression */ + || kind === 298 /* CommaListExpression */ || isUnaryExpressionKind(kind); } + /* @internal */ function isExpression(node) { return isExpressionKind(ts.skipPartiallyEmittedExpressions(node).kind); } @@ -10257,59 +11609,61 @@ var ts; || kind === 202 /* AsExpression */; } ts.isAssertionExpression = isAssertionExpression; + /* @internal */ function isPartiallyEmittedExpression(node) { - return node.kind === 296 /* PartiallyEmittedExpression */; + return node.kind === 297 /* PartiallyEmittedExpression */; } ts.isPartiallyEmittedExpression = isPartiallyEmittedExpression; + /* @internal */ function isNotEmittedStatement(node) { - return node.kind === 295 /* NotEmittedStatement */; + return node.kind === 296 /* NotEmittedStatement */; } ts.isNotEmittedStatement = isNotEmittedStatement; + /* @internal */ function isNotEmittedOrPartiallyEmittedNode(node) { return isNotEmittedStatement(node) || isPartiallyEmittedExpression(node); } ts.isNotEmittedOrPartiallyEmittedNode = isNotEmittedOrPartiallyEmittedNode; - function isOmittedExpression(node) { - return node.kind === 200 /* OmittedExpression */; + // Statement + function isIterationStatement(node, lookInLabeledStatements) { + switch (node.kind) { + case 214 /* ForStatement */: + case 215 /* ForInStatement */: + case 216 /* ForOfStatement */: + case 212 /* DoStatement */: + case 213 /* WhileStatement */: + return true; + case 222 /* LabeledStatement */: + return lookInLabeledStatements && isIterationStatement(node.statement, lookInLabeledStatements); + } + return false; } - ts.isOmittedExpression = isOmittedExpression; - // Misc - function isTemplateSpan(node) { - return node.kind === 205 /* TemplateSpan */; + ts.isIterationStatement = isIterationStatement; + /* @internal */ + function isForInOrOfStatement(node) { + return node.kind === 215 /* ForInStatement */ || node.kind === 216 /* ForOfStatement */; } - ts.isTemplateSpan = isTemplateSpan; + ts.isForInOrOfStatement = isForInOrOfStatement; // Element - function isBlock(node) { - return node.kind === 207 /* Block */; - } - ts.isBlock = isBlock; + /* @internal */ function isConciseBody(node) { - return isBlock(node) + return ts.isBlock(node) || isExpression(node); } ts.isConciseBody = isConciseBody; + /* @internal */ function isFunctionBody(node) { - return isBlock(node); + return ts.isBlock(node); } ts.isFunctionBody = isFunctionBody; + /* @internal */ function isForInitializer(node) { - return isVariableDeclarationList(node) + return ts.isVariableDeclarationList(node) || isExpression(node); } ts.isForInitializer = isForInitializer; - function isVariableDeclaration(node) { - return node.kind === 226 /* VariableDeclaration */; - } - ts.isVariableDeclaration = isVariableDeclaration; - function isVariableDeclarationList(node) { - return node.kind === 227 /* VariableDeclarationList */; - } - ts.isVariableDeclarationList = isVariableDeclarationList; - function isCaseBlock(node) { - return node.kind === 235 /* CaseBlock */; - } - ts.isCaseBlock = isCaseBlock; + /* @internal */ function isModuleBody(node) { var kind = node.kind; return kind === 234 /* ModuleBlock */ @@ -10317,44 +11671,28 @@ var ts; || kind === 71 /* Identifier */; } ts.isModuleBody = isModuleBody; + /* @internal */ function isNamespaceBody(node) { var kind = node.kind; return kind === 234 /* ModuleBlock */ || kind === 233 /* ModuleDeclaration */; } ts.isNamespaceBody = isNamespaceBody; + /* @internal */ function isJSDocNamespaceBody(node) { var kind = node.kind; return kind === 71 /* Identifier */ || kind === 233 /* ModuleDeclaration */; } ts.isJSDocNamespaceBody = isJSDocNamespaceBody; - function isImportEqualsDeclaration(node) { - return node.kind === 237 /* ImportEqualsDeclaration */; - } - ts.isImportEqualsDeclaration = isImportEqualsDeclaration; - function isImportClause(node) { - return node.kind === 239 /* ImportClause */; - } - ts.isImportClause = isImportClause; + /* @internal */ function isNamedImportBindings(node) { var kind = node.kind; return kind === 241 /* NamedImports */ || kind === 240 /* NamespaceImport */; } ts.isNamedImportBindings = isNamedImportBindings; - function isImportSpecifier(node) { - return node.kind === 242 /* ImportSpecifier */; - } - ts.isImportSpecifier = isImportSpecifier; - function isNamedExports(node) { - return node.kind === 245 /* NamedExports */; - } - ts.isNamedExports = isNamedExports; - function isExportSpecifier(node) { - return node.kind === 246 /* ExportSpecifier */; - } - ts.isExportSpecifier = isExportSpecifier; + /* @internal */ function isModuleOrEnumDeclaration(node) { return node.kind === 233 /* ModuleDeclaration */ || node.kind === 232 /* EnumDeclaration */; } @@ -10390,7 +11728,7 @@ var ts; || kind === 231 /* TypeAliasDeclaration */ || kind === 145 /* TypeParameter */ || kind === 226 /* VariableDeclaration */ - || kind === 290 /* JSDocTypedefTag */; + || kind === 291 /* JSDocTypedefTag */; } function isDeclarationStatementKind(kind) { return kind === 228 /* FunctionDeclaration */ @@ -10425,508 +11763,111 @@ var ts; || kind === 208 /* VariableStatement */ || kind === 213 /* WhileStatement */ || kind === 220 /* WithStatement */ - || kind === 295 /* NotEmittedStatement */ - || kind === 298 /* EndOfDeclarationMarker */ - || kind === 297 /* MergeDeclarationMarker */; - } - function isDeclaration(node) { - return isDeclarationKind(node.kind); - } - ts.isDeclaration = isDeclaration; - function isDeclarationStatement(node) { - return isDeclarationStatementKind(node.kind); - } - ts.isDeclarationStatement = isDeclarationStatement; - /** - * Determines whether the node is a statement that is not also a declaration - */ - function isStatementButNotDeclaration(node) { - return isStatementKindButNotDeclarationKind(node.kind); - } - ts.isStatementButNotDeclaration = isStatementButNotDeclaration; - function isStatement(node) { - var kind = node.kind; - return isStatementKindButNotDeclarationKind(kind) - || isDeclarationStatementKind(kind) - || kind === 207 /* Block */; + || kind === 296 /* NotEmittedStatement */ + || kind === 300 /* EndOfDeclarationMarker */ + || kind === 299 /* MergeDeclarationMarker */; } - ts.isStatement = isStatement; - // Module references - function isModuleReference(node) { - var kind = node.kind; - return kind === 248 /* ExternalModuleReference */ - || kind === 143 /* QualifiedName */ - || kind === 71 /* Identifier */; - } - ts.isModuleReference = isModuleReference; - // JSX - function isJsxOpeningElement(node) { - return node.kind === 251 /* JsxOpeningElement */; - } - ts.isJsxOpeningElement = isJsxOpeningElement; - function isJsxClosingElement(node) { - return node.kind === 252 /* JsxClosingElement */; - } - ts.isJsxClosingElement = isJsxClosingElement; - function isJsxTagNameExpression(node) { - var kind = node.kind; - return kind === 99 /* ThisKeyword */ - || kind === 71 /* Identifier */ - || kind === 179 /* PropertyAccessExpression */; - } - ts.isJsxTagNameExpression = isJsxTagNameExpression; - function isJsxChild(node) { - var kind = node.kind; - return kind === 249 /* JsxElement */ - || kind === 256 /* JsxExpression */ - || kind === 250 /* JsxSelfClosingElement */ - || kind === 10 /* JsxText */; - } - ts.isJsxChild = isJsxChild; - function isJsxAttributes(node) { - var kind = node.kind; - return kind === 254 /* JsxAttributes */; - } - ts.isJsxAttributes = isJsxAttributes; - function isJsxAttributeLike(node) { - var kind = node.kind; - return kind === 253 /* JsxAttribute */ - || kind === 255 /* JsxSpreadAttribute */; - } - ts.isJsxAttributeLike = isJsxAttributeLike; - function isJsxSpreadAttribute(node) { - return node.kind === 255 /* JsxSpreadAttribute */; - } - ts.isJsxSpreadAttribute = isJsxSpreadAttribute; - function isJsxAttribute(node) { - return node.kind === 253 /* JsxAttribute */; - } - ts.isJsxAttribute = isJsxAttribute; - function isStringLiteralOrJsxExpression(node) { - var kind = node.kind; - return kind === 9 /* StringLiteral */ - || kind === 256 /* JsxExpression */; - } - ts.isStringLiteralOrJsxExpression = isStringLiteralOrJsxExpression; - function isJsxOpeningLikeElement(node) { - var kind = node.kind; - return kind === 251 /* JsxOpeningElement */ - || kind === 250 /* JsxSelfClosingElement */; - } - ts.isJsxOpeningLikeElement = isJsxOpeningLikeElement; - // Clauses - function isCaseOrDefaultClause(node) { - var kind = node.kind; - return kind === 257 /* CaseClause */ - || kind === 258 /* DefaultClause */; - } - ts.isCaseOrDefaultClause = isCaseOrDefaultClause; - function isHeritageClause(node) { - return node.kind === 259 /* HeritageClause */; - } - ts.isHeritageClause = isHeritageClause; - function isCatchClause(node) { - return node.kind === 260 /* CatchClause */; - } - ts.isCatchClause = isCatchClause; - // Property assignments - function isPropertyAssignment(node) { - return node.kind === 261 /* PropertyAssignment */; - } - ts.isPropertyAssignment = isPropertyAssignment; - function isShorthandPropertyAssignment(node) { - return node.kind === 262 /* ShorthandPropertyAssignment */; - } - ts.isShorthandPropertyAssignment = isShorthandPropertyAssignment; - // Enum - function isEnumMember(node) { - return node.kind === 264 /* EnumMember */; - } - ts.isEnumMember = isEnumMember; - // Top-level nodes - function isSourceFile(node) { - return node.kind === 265 /* SourceFile */; - } - ts.isSourceFile = isSourceFile; - function isWatchSet(options) { - // Firefox has Object.prototype.watch - return options.watch && options.hasOwnProperty("watch"); - } - ts.isWatchSet = isWatchSet; -})(ts || (ts = {})); -(function (ts) { - function getDefaultLibFileName(options) { - switch (options.target) { - case 5 /* ESNext */: - return "lib.esnext.full.d.ts"; - case 4 /* ES2017 */: - return "lib.es2017.full.d.ts"; - case 3 /* ES2016 */: - return "lib.es2016.full.d.ts"; - case 2 /* ES2015 */: - return "lib.es6.d.ts"; // We don't use lib.es2015.full.d.ts due to breaking change. - default: - return "lib.d.ts"; - } - } - ts.getDefaultLibFileName = getDefaultLibFileName; - function textSpanEnd(span) { - return span.start + span.length; - } - ts.textSpanEnd = textSpanEnd; - function textSpanIsEmpty(span) { - return span.length === 0; - } - ts.textSpanIsEmpty = textSpanIsEmpty; - function textSpanContainsPosition(span, position) { - return position >= span.start && position < textSpanEnd(span); - } - ts.textSpanContainsPosition = textSpanContainsPosition; - // Returns true if 'span' contains 'other'. - function textSpanContainsTextSpan(span, other) { - return other.start >= span.start && textSpanEnd(other) <= textSpanEnd(span); - } - ts.textSpanContainsTextSpan = textSpanContainsTextSpan; - function textSpanOverlapsWith(span, other) { - var overlapStart = Math.max(span.start, other.start); - var overlapEnd = Math.min(textSpanEnd(span), textSpanEnd(other)); - return overlapStart < overlapEnd; - } - ts.textSpanOverlapsWith = textSpanOverlapsWith; - function textSpanOverlap(span1, span2) { - var overlapStart = Math.max(span1.start, span2.start); - var overlapEnd = Math.min(textSpanEnd(span1), textSpanEnd(span2)); - if (overlapStart < overlapEnd) { - return createTextSpanFromBounds(overlapStart, overlapEnd); - } - return undefined; - } - ts.textSpanOverlap = textSpanOverlap; - function textSpanIntersectsWithTextSpan(span, other) { - return other.start <= textSpanEnd(span) && textSpanEnd(other) >= span.start; - } - ts.textSpanIntersectsWithTextSpan = textSpanIntersectsWithTextSpan; - function textSpanIntersectsWith(span, start, length) { - var end = start + length; - return start <= textSpanEnd(span) && end >= span.start; - } - ts.textSpanIntersectsWith = textSpanIntersectsWith; - function decodedTextSpanIntersectsWith(start1, length1, start2, length2) { - var end1 = start1 + length1; - var end2 = start2 + length2; - return start2 <= end1 && end2 >= start1; - } - ts.decodedTextSpanIntersectsWith = decodedTextSpanIntersectsWith; - function textSpanIntersectsWithPosition(span, position) { - return position <= textSpanEnd(span) && position >= span.start; - } - ts.textSpanIntersectsWithPosition = textSpanIntersectsWithPosition; - function textSpanIntersection(span1, span2) { - var intersectStart = Math.max(span1.start, span2.start); - var intersectEnd = Math.min(textSpanEnd(span1), textSpanEnd(span2)); - if (intersectStart <= intersectEnd) { - return createTextSpanFromBounds(intersectStart, intersectEnd); - } - return undefined; - } - ts.textSpanIntersection = textSpanIntersection; - function createTextSpan(start, length) { - if (start < 0) { - throw new Error("start < 0"); - } - if (length < 0) { - throw new Error("length < 0"); - } - return { start: start, length: length }; - } - ts.createTextSpan = createTextSpan; - function createTextSpanFromBounds(start, end) { - return createTextSpan(start, end - start); - } - ts.createTextSpanFromBounds = createTextSpanFromBounds; - function textChangeRangeNewSpan(range) { - return createTextSpan(range.span.start, range.newLength); - } - ts.textChangeRangeNewSpan = textChangeRangeNewSpan; - function textChangeRangeIsUnchanged(range) { - return textSpanIsEmpty(range.span) && range.newLength === 0; - } - ts.textChangeRangeIsUnchanged = textChangeRangeIsUnchanged; - function createTextChangeRange(span, newLength) { - if (newLength < 0) { - throw new Error("newLength < 0"); + /* @internal */ + function isDeclaration(node) { + if (node.kind === 145 /* TypeParameter */) { + return node.parent.kind !== 290 /* JSDocTemplateTag */ || ts.isInJavaScriptFile(node); } - return { span: span, newLength: newLength }; + return isDeclarationKind(node.kind); } - ts.createTextChangeRange = createTextChangeRange; - ts.unchangedTextChangeRange = createTextChangeRange(createTextSpan(0, 0), 0); + ts.isDeclaration = isDeclaration; + /* @internal */ + function isDeclarationStatement(node) { + return isDeclarationStatementKind(node.kind); + } + ts.isDeclarationStatement = isDeclarationStatement; /** - * Called to merge all the changes that occurred across several versions of a script snapshot - * into a single change. i.e. if a user keeps making successive edits to a script we will - * have a text change from V1 to V2, V2 to V3, ..., Vn. - * - * This function will then merge those changes into a single change range valid between V1 and - * Vn. + * Determines whether the node is a statement that is not also a declaration */ - function collapseTextChangeRangesAcrossMultipleVersions(changes) { - if (changes.length === 0) { - return ts.unchangedTextChangeRange; - } - if (changes.length === 1) { - return changes[0]; - } - // We change from talking about { { oldStart, oldLength }, newLength } to { oldStart, oldEnd, newEnd } - // as it makes things much easier to reason about. - var change0 = changes[0]; - var oldStartN = change0.span.start; - var oldEndN = textSpanEnd(change0.span); - var newEndN = oldStartN + change0.newLength; - for (var i = 1; i < changes.length; i++) { - var nextChange = changes[i]; - // Consider the following case: - // i.e. two edits. The first represents the text change range { { 10, 50 }, 30 }. i.e. The span starting - // at 10, with length 50 is reduced to length 30. The second represents the text change range { { 30, 30 }, 40 }. - // i.e. the span starting at 30 with length 30 is increased to length 40. - // - // 0 10 20 30 40 50 60 70 80 90 100 - // ------------------------------------------------------------------------------------------------------- - // | / - // | /---- - // T1 | /---- - // | /---- - // | /---- - // ------------------------------------------------------------------------------------------------------- - // | \ - // | \ - // T2 | \ - // | \ - // | \ - // ------------------------------------------------------------------------------------------------------- - // - // Merging these turns out to not be too difficult. First, determining the new start of the change is trivial - // it's just the min of the old and new starts. i.e.: - // - // 0 10 20 30 40 50 60 70 80 90 100 - // ------------------------------------------------------------*------------------------------------------ - // | / - // | /---- - // T1 | /---- - // | /---- - // | /---- - // ----------------------------------------$-------------------$------------------------------------------ - // . | \ - // . | \ - // T2 . | \ - // . | \ - // . | \ - // ----------------------------------------------------------------------*-------------------------------- - // - // (Note the dots represent the newly inferred start. - // Determining the new and old end is also pretty simple. Basically it boils down to paying attention to the - // absolute positions at the asterisks, and the relative change between the dollar signs. Basically, we see - // which if the two $'s precedes the other, and we move that one forward until they line up. in this case that - // means: - // - // 0 10 20 30 40 50 60 70 80 90 100 - // --------------------------------------------------------------------------------*---------------------- - // | / - // | /---- - // T1 | /---- - // | /---- - // | /---- - // ------------------------------------------------------------$------------------------------------------ - // . | \ - // . | \ - // T2 . | \ - // . | \ - // . | \ - // ----------------------------------------------------------------------*-------------------------------- - // - // In other words (in this case), we're recognizing that the second edit happened after where the first edit - // ended with a delta of 20 characters (60 - 40). Thus, if we go back in time to where the first edit started - // that's the same as if we started at char 80 instead of 60. - // - // As it so happens, the same logic applies if the second edit precedes the first edit. In that case rather - // than pushing the first edit forward to match the second, we'll push the second edit forward to match the - // first. - // - // In this case that means we have { oldStart: 10, oldEnd: 80, newEnd: 70 } or, in TextChangeRange - // semantics: { { start: 10, length: 70 }, newLength: 60 } - // - // The math then works out as follows. - // If we have { oldStart1, oldEnd1, newEnd1 } and { oldStart2, oldEnd2, newEnd2 } then we can compute the - // final result like so: - // - // { - // oldStart3: Min(oldStart1, oldStart2), - // oldEnd3 : Max(oldEnd1, oldEnd1 + (oldEnd2 - newEnd1)), - // newEnd3 : Max(newEnd2, newEnd2 + (newEnd1 - oldEnd2)) - // } - var oldStart1 = oldStartN; - var oldEnd1 = oldEndN; - var newEnd1 = newEndN; - var oldStart2 = nextChange.span.start; - var oldEnd2 = textSpanEnd(nextChange.span); - var newEnd2 = oldStart2 + nextChange.newLength; - oldStartN = Math.min(oldStart1, oldStart2); - oldEndN = Math.max(oldEnd1, oldEnd1 + (oldEnd2 - newEnd1)); - newEndN = Math.max(newEnd2, newEnd2 + (newEnd1 - oldEnd2)); - } - return createTextChangeRange(createTextSpanFromBounds(oldStartN, oldEndN), /*newLength*/ newEndN - oldStartN); + /* @internal */ + function isStatementButNotDeclaration(node) { + return isStatementKindButNotDeclarationKind(node.kind); } - ts.collapseTextChangeRangesAcrossMultipleVersions = collapseTextChangeRangesAcrossMultipleVersions; - function getTypeParameterOwner(d) { - if (d && d.kind === 145 /* TypeParameter */) { - for (var current = d; current; current = current.parent) { - if (ts.isFunctionLike(current) || ts.isClassLike(current) || current.kind === 230 /* InterfaceDeclaration */) { - return current; - } - } - } + ts.isStatementButNotDeclaration = isStatementButNotDeclaration; + /* @internal */ + function isStatement(node) { + var kind = node.kind; + return isStatementKindButNotDeclarationKind(kind) + || isDeclarationStatementKind(kind) + || kind === 207 /* Block */; } - ts.getTypeParameterOwner = getTypeParameterOwner; - function isParameterPropertyDeclaration(node) { - return ts.hasModifier(node, 92 /* ParameterPropertyModifier */) && node.parent.kind === 152 /* Constructor */ && ts.isClassLike(node.parent.parent); + ts.isStatement = isStatement; + // Module references + /* @internal */ + function isModuleReference(node) { + var kind = node.kind; + return kind === 248 /* ExternalModuleReference */ + || kind === 143 /* QualifiedName */ + || kind === 71 /* Identifier */; } - ts.isParameterPropertyDeclaration = isParameterPropertyDeclaration; - function walkUpBindingElementsAndPatterns(node) { - while (node && (node.kind === 176 /* BindingElement */ || ts.isBindingPattern(node))) { - node = node.parent; - } - return node; + ts.isModuleReference = isModuleReference; + // JSX + /* @internal */ + function isJsxTagNameExpression(node) { + var kind = node.kind; + return kind === 99 /* ThisKeyword */ + || kind === 71 /* Identifier */ + || kind === 179 /* PropertyAccessExpression */; } - function getCombinedModifierFlags(node) { - node = walkUpBindingElementsAndPatterns(node); - var flags = ts.getModifierFlags(node); - if (node.kind === 226 /* VariableDeclaration */) { - node = node.parent; - } - if (node && node.kind === 227 /* VariableDeclarationList */) { - flags |= ts.getModifierFlags(node); - node = node.parent; - } - if (node && node.kind === 208 /* VariableStatement */) { - flags |= ts.getModifierFlags(node); - } - return flags; + ts.isJsxTagNameExpression = isJsxTagNameExpression; + /* @internal */ + function isJsxChild(node) { + var kind = node.kind; + return kind === 249 /* JsxElement */ + || kind === 256 /* JsxExpression */ + || kind === 250 /* JsxSelfClosingElement */ + || kind === 10 /* JsxText */; } - ts.getCombinedModifierFlags = getCombinedModifierFlags; - // Returns the node flags for this node and all relevant parent nodes. This is done so that - // nodes like variable declarations and binding elements can returned a view of their flags - // that includes the modifiers from their container. i.e. flags like export/declare aren't - // stored on the variable declaration directly, but on the containing variable statement - // (if it has one). Similarly, flags for let/const are store on the variable declaration - // list. By calling this function, all those flags are combined so that the client can treat - // the node as if it actually had those flags. - function getCombinedNodeFlags(node) { - node = walkUpBindingElementsAndPatterns(node); - var flags = node.flags; - if (node.kind === 226 /* VariableDeclaration */) { - node = node.parent; - } - if (node && node.kind === 227 /* VariableDeclarationList */) { - flags |= node.flags; - node = node.parent; - } - if (node && node.kind === 208 /* VariableStatement */) { - flags |= node.flags; - } - return flags; + ts.isJsxChild = isJsxChild; + /* @internal */ + function isJsxAttributeLike(node) { + var kind = node.kind; + return kind === 253 /* JsxAttribute */ + || kind === 255 /* JsxSpreadAttribute */; } - ts.getCombinedNodeFlags = getCombinedNodeFlags; - /** - * Checks to see if the locale is in the appropriate format, - * and if it is, attempts to set the appropriate language. - */ - function validateLocaleAndSetLanguage(locale, sys, errors) { - var matchResult = /^([a-z]+)([_\-]([a-z]+))?$/.exec(locale.toLowerCase()); - if (!matchResult) { - if (errors) { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Locale_must_be_of_the_form_language_or_language_territory_For_example_0_or_1, "en", "ja-jp")); - } - return; - } - var language = matchResult[1]; - var territory = matchResult[3]; - // First try the entire locale, then fall back to just language if that's all we have. - // Either ways do not fail, and fallback to the English diagnostic strings. - if (!trySetLanguageAndTerritory(language, territory, errors)) { - trySetLanguageAndTerritory(language, /*territory*/ undefined, errors); - } - function trySetLanguageAndTerritory(language, territory, errors) { - var compilerFilePath = ts.normalizePath(sys.getExecutingFilePath()); - var containingDirectoryPath = ts.getDirectoryPath(compilerFilePath); - var filePath = ts.combinePaths(containingDirectoryPath, language); - if (territory) { - filePath = filePath + "-" + territory; - } - filePath = sys.resolvePath(ts.combinePaths(filePath, "diagnosticMessages.generated.json")); - if (!sys.fileExists(filePath)) { - return false; - } - // TODO: Add codePage support for readFile? - var fileContents = ""; - try { - fileContents = sys.readFile(filePath); - } - catch (e) { - if (errors) { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Unable_to_open_file_0, filePath)); - } - return false; - } - try { - ts.localizedDiagnosticMessages = JSON.parse(fileContents); - } - catch (e) { - if (errors) { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Corrupted_locale_file_0, filePath)); - } - return false; - } - return true; - } + ts.isJsxAttributeLike = isJsxAttributeLike; + /* @internal */ + function isStringLiteralOrJsxExpression(node) { + var kind = node.kind; + return kind === 9 /* StringLiteral */ + || kind === 256 /* JsxExpression */; } - ts.validateLocaleAndSetLanguage = validateLocaleAndSetLanguage; - function getOriginalNode(node, nodeTest) { - if (node) { - while (node.original !== undefined) { - node = node.original; - } - } - return !nodeTest || nodeTest(node) ? node : undefined; + ts.isStringLiteralOrJsxExpression = isStringLiteralOrJsxExpression; + function isJsxOpeningLikeElement(node) { + var kind = node.kind; + return kind === 251 /* JsxOpeningElement */ + || kind === 250 /* JsxSelfClosingElement */; } - ts.getOriginalNode = getOriginalNode; - /** - * Gets a value indicating whether a node originated in the parse tree. - * - * @param node The node to test. - */ - function isParseTreeNode(node) { - return (node.flags & 8 /* Synthesized */) === 0; + ts.isJsxOpeningLikeElement = isJsxOpeningLikeElement; + // Clauses + function isCaseOrDefaultClause(node) { + var kind = node.kind; + return kind === 257 /* CaseClause */ + || kind === 258 /* DefaultClause */; } - ts.isParseTreeNode = isParseTreeNode; - function getParseTreeNode(node, nodeTest) { - if (node === undefined || isParseTreeNode(node)) { - return node; - } - node = getOriginalNode(node); - if (isParseTreeNode(node) && (!nodeTest || nodeTest(node))) { - return node; - } - return undefined; + ts.isCaseOrDefaultClause = isCaseOrDefaultClause; + // JSDoc + /** True if node is of some JSDoc syntax kind. */ + /* @internal */ + function isJSDocNode(node) { + return node.kind >= 267 /* FirstJSDocNode */ && node.kind <= 294 /* LastJSDocNode */; } - ts.getParseTreeNode = getParseTreeNode; - /** - * Remove extra underscore from escaped identifier text content. - * - * @param identifier The escaped identifier text. - * @returns The unescaped identifier text. - */ - function unescapeIdentifier(identifier) { - return identifier.length >= 3 && identifier.charCodeAt(0) === 95 /* _ */ && identifier.charCodeAt(1) === 95 /* _ */ && identifier.charCodeAt(2) === 95 /* _ */ ? identifier.substr(1) : identifier; + ts.isJSDocNode = isJSDocNode; + /** True if node is of a kind that may contain comment text. */ + function isJSDocCommentContainingNode(node) { + return node.kind === 283 /* JSDocComment */ || isJSDocTag(node); } - ts.unescapeIdentifier = unescapeIdentifier; + ts.isJSDocCommentContainingNode = isJSDocCommentContainingNode; + // TODO: determine what this does before making it public. + /* @internal */ + function isJSDocTag(node) { + return node.kind >= 284 /* FirstJSDocTagNode */ && node.kind <= 294 /* LastJSDocTagNode */; + } + ts.isJSDocTag = isJSDocTag; })(ts || (ts = {})); /// /// @@ -11019,16 +11960,24 @@ var ts; node.textSourceNode = sourceNode; return node; } - // Identifiers - function createIdentifier(text) { + function createIdentifier(text, typeArguments) { var node = createSynthesizedNode(71 /* Identifier */); node.text = ts.escapeIdentifier(text); node.originalKeywordKind = text ? ts.stringToToken(text) : 0 /* Unknown */; node.autoGenerateKind = 0 /* None */; node.autoGenerateId = 0; + if (typeArguments) { + node.typeArguments = createNodeArray(typeArguments); + } return node; } ts.createIdentifier = createIdentifier; + function updateIdentifier(node, typeArguments) { + return node.typeArguments !== typeArguments + ? updateNode(createIdentifier(node.text, typeArguments), node) + : node; + } + ts.updateIdentifier = updateIdentifier; var nextAutoGenerateId = 0; /** Create a unique temporary variable. */ function createTempVariable(recordTempVariable) { @@ -11123,228 +12072,13 @@ var ts; : node; } ts.updateComputedPropertyName = updateComputedPropertyName; - // Type Elements - function createSignatureDeclaration(kind, typeParameters, parameters, type) { - var signatureDeclaration = createSynthesizedNode(kind); - signatureDeclaration.typeParameters = asNodeArray(typeParameters); - signatureDeclaration.parameters = asNodeArray(parameters); - signatureDeclaration.type = type; - return signatureDeclaration; - } - ts.createSignatureDeclaration = createSignatureDeclaration; - function updateSignatureDeclaration(node, typeParameters, parameters, type) { - return node.typeParameters !== typeParameters - || node.parameters !== parameters - || node.type !== type - ? updateNode(createSignatureDeclaration(node.kind, typeParameters, parameters, type), node) - : node; - } - function createFunctionTypeNode(typeParameters, parameters, type) { - return createSignatureDeclaration(160 /* FunctionType */, typeParameters, parameters, type); - } - ts.createFunctionTypeNode = createFunctionTypeNode; - function updateFunctionTypeNode(node, typeParameters, parameters, type) { - return updateSignatureDeclaration(node, typeParameters, parameters, type); - } - ts.updateFunctionTypeNode = updateFunctionTypeNode; - function createConstructorTypeNode(typeParameters, parameters, type) { - return createSignatureDeclaration(161 /* ConstructorType */, typeParameters, parameters, type); - } - ts.createConstructorTypeNode = createConstructorTypeNode; - function updateConstructorTypeNode(node, typeParameters, parameters, type) { - return updateSignatureDeclaration(node, typeParameters, parameters, type); - } - ts.updateConstructorTypeNode = updateConstructorTypeNode; - function createCallSignatureDeclaration(typeParameters, parameters, type) { - return createSignatureDeclaration(155 /* CallSignature */, typeParameters, parameters, type); - } - ts.createCallSignatureDeclaration = createCallSignatureDeclaration; - function updateCallSignatureDeclaration(node, typeParameters, parameters, type) { - return updateSignatureDeclaration(node, typeParameters, parameters, type); - } - ts.updateCallSignatureDeclaration = updateCallSignatureDeclaration; - function createConstructSignatureDeclaration(typeParameters, parameters, type) { - return createSignatureDeclaration(156 /* ConstructSignature */, typeParameters, parameters, type); - } - ts.createConstructSignatureDeclaration = createConstructSignatureDeclaration; - function updateConstructSignatureDeclaration(node, typeParameters, parameters, type) { - return updateSignatureDeclaration(node, typeParameters, parameters, type); - } - ts.updateConstructSignatureDeclaration = updateConstructSignatureDeclaration; - function createMethodSignature(typeParameters, parameters, type, name, questionToken) { - var methodSignature = createSignatureDeclaration(150 /* MethodSignature */, typeParameters, parameters, type); - methodSignature.name = asName(name); - methodSignature.questionToken = questionToken; - return methodSignature; - } - ts.createMethodSignature = createMethodSignature; - function updateMethodSignature(node, typeParameters, parameters, type, name, questionToken) { - return node.typeParameters !== typeParameters - || node.parameters !== parameters - || node.type !== type - || node.name !== name - || node.questionToken !== questionToken - ? updateNode(createMethodSignature(typeParameters, parameters, type, name, questionToken), node) - : node; - } - ts.updateMethodSignature = updateMethodSignature; - // Types - function createKeywordTypeNode(kind) { - return createSynthesizedNode(kind); - } - ts.createKeywordTypeNode = createKeywordTypeNode; - function createThisTypeNode() { - return createSynthesizedNode(169 /* ThisType */); - } - ts.createThisTypeNode = createThisTypeNode; - function createLiteralTypeNode(literal) { - var literalTypeNode = createSynthesizedNode(173 /* LiteralType */); - literalTypeNode.literal = literal; - return literalTypeNode; - } - ts.createLiteralTypeNode = createLiteralTypeNode; - function updateLiteralTypeNode(node, literal) { - return node.literal !== literal - ? updateNode(createLiteralTypeNode(literal), node) - : node; - } - ts.updateLiteralTypeNode = updateLiteralTypeNode; - function createTypeReferenceNode(typeName, typeArguments) { - var typeReference = createSynthesizedNode(159 /* TypeReference */); - typeReference.typeName = asName(typeName); - typeReference.typeArguments = asNodeArray(typeArguments); - return typeReference; - } - ts.createTypeReferenceNode = createTypeReferenceNode; - function updateTypeReferenceNode(node, typeName, typeArguments) { - return node.typeName !== typeName - || node.typeArguments !== typeArguments - ? updateNode(createTypeReferenceNode(typeName, typeArguments), node) - : node; - } - ts.updateTypeReferenceNode = updateTypeReferenceNode; - function createTypePredicateNode(parameterName, type) { - var typePredicateNode = createSynthesizedNode(158 /* TypePredicate */); - typePredicateNode.parameterName = asName(parameterName); - typePredicateNode.type = type; - return typePredicateNode; - } - ts.createTypePredicateNode = createTypePredicateNode; - function updateTypePredicateNode(node, parameterName, type) { - return node.parameterName !== parameterName - || node.type !== type - ? updateNode(createTypePredicateNode(parameterName, type), node) - : node; - } - ts.updateTypePredicateNode = updateTypePredicateNode; - function createTypeQueryNode(exprName) { - var typeQueryNode = createSynthesizedNode(162 /* TypeQuery */); - typeQueryNode.exprName = exprName; - return typeQueryNode; - } - ts.createTypeQueryNode = createTypeQueryNode; - function updateTypeQueryNode(node, exprName) { - return node.exprName !== exprName ? updateNode(createTypeQueryNode(exprName), node) : node; - } - ts.updateTypeQueryNode = updateTypeQueryNode; - function createArrayTypeNode(elementType) { - var arrayTypeNode = createSynthesizedNode(164 /* ArrayType */); - arrayTypeNode.elementType = elementType; - return arrayTypeNode; - } - ts.createArrayTypeNode = createArrayTypeNode; - function updateArrayTypeNode(node, elementType) { - return node.elementType !== elementType - ? updateNode(createArrayTypeNode(elementType), node) - : node; - } - ts.updateArrayTypeNode = updateArrayTypeNode; - function createUnionOrIntersectionTypeNode(kind, types) { - var unionTypeNode = createSynthesizedNode(kind); - unionTypeNode.types = createNodeArray(types); - return unionTypeNode; - } - ts.createUnionOrIntersectionTypeNode = createUnionOrIntersectionTypeNode; - function updateUnionOrIntersectionTypeNode(node, types) { - return node.types !== types - ? updateNode(createUnionOrIntersectionTypeNode(node.kind, types), node) - : node; - } - ts.updateUnionOrIntersectionTypeNode = updateUnionOrIntersectionTypeNode; - function createTypeLiteralNode(members) { - var typeLiteralNode = createSynthesizedNode(163 /* TypeLiteral */); - typeLiteralNode.members = createNodeArray(members); - return typeLiteralNode; - } - ts.createTypeLiteralNode = createTypeLiteralNode; - function updateTypeLiteralNode(node, members) { - return node.members !== members - ? updateNode(createTypeLiteralNode(members), node) - : node; - } - ts.updateTypeLiteralNode = updateTypeLiteralNode; - function createTupleTypeNode(elementTypes) { - var tupleTypeNode = createSynthesizedNode(165 /* TupleType */); - tupleTypeNode.elementTypes = createNodeArray(elementTypes); - return tupleTypeNode; - } - ts.createTupleTypeNode = createTupleTypeNode; - function updateTypleTypeNode(node, elementTypes) { - return node.elementTypes !== elementTypes - ? updateNode(createTupleTypeNode(elementTypes), node) - : node; - } - ts.updateTypleTypeNode = updateTypleTypeNode; - function createMappedTypeNode(readonlyToken, typeParameter, questionToken, type) { - var mappedTypeNode = createSynthesizedNode(172 /* MappedType */); - mappedTypeNode.readonlyToken = readonlyToken; - mappedTypeNode.typeParameter = typeParameter; - mappedTypeNode.questionToken = questionToken; - mappedTypeNode.type = type; - return mappedTypeNode; - } - ts.createMappedTypeNode = createMappedTypeNode; - function updateMappedTypeNode(node, readonlyToken, typeParameter, questionToken, type) { - return node.readonlyToken !== readonlyToken - || node.typeParameter !== typeParameter - || node.questionToken !== questionToken - || node.type !== type - ? updateNode(createMappedTypeNode(readonlyToken, typeParameter, questionToken, type), node) - : node; - } - ts.updateMappedTypeNode = updateMappedTypeNode; - function createTypeOperatorNode(type) { - var typeOperatorNode = createSynthesizedNode(170 /* TypeOperator */); - typeOperatorNode.operator = 127 /* KeyOfKeyword */; - typeOperatorNode.type = type; - return typeOperatorNode; - } - ts.createTypeOperatorNode = createTypeOperatorNode; - function updateTypeOperatorNode(node, type) { - return node.type !== type ? updateNode(createTypeOperatorNode(type), node) : node; - } - ts.updateTypeOperatorNode = updateTypeOperatorNode; - function createIndexedAccessTypeNode(objectType, indexType) { - var indexedAccessTypeNode = createSynthesizedNode(171 /* IndexedAccessType */); - indexedAccessTypeNode.objectType = objectType; - indexedAccessTypeNode.indexType = indexType; - return indexedAccessTypeNode; - } - ts.createIndexedAccessTypeNode = createIndexedAccessTypeNode; - function updateIndexedAccessTypeNode(node, objectType, indexType) { - return node.objectType !== objectType - || node.indexType !== indexType - ? updateNode(createIndexedAccessTypeNode(objectType, indexType), node) - : node; - } - ts.updateIndexedAccessTypeNode = updateIndexedAccessTypeNode; - // Type Declarations + // Signature elements function createTypeParameterDeclaration(name, constraint, defaultType) { - var typeParameter = createSynthesizedNode(145 /* TypeParameter */); - typeParameter.name = asName(name); - typeParameter.constraint = constraint; - typeParameter.default = defaultType; - return typeParameter; + var node = createSynthesizedNode(145 /* TypeParameter */); + node.name = asName(name); + node.constraint = constraint; + node.default = defaultType; + return node; } ts.createTypeParameterDeclaration = createTypeParameterDeclaration; function updateTypeParameterDeclaration(node, name, constraint, defaultType) { @@ -11355,44 +12089,6 @@ var ts; : node; } ts.updateTypeParameterDeclaration = updateTypeParameterDeclaration; - // Signature elements - function createPropertySignature(name, questionToken, type, initializer) { - var propertySignature = createSynthesizedNode(148 /* PropertySignature */); - propertySignature.name = asName(name); - propertySignature.questionToken = questionToken; - propertySignature.type = type; - propertySignature.initializer = initializer; - return propertySignature; - } - ts.createPropertySignature = createPropertySignature; - function updatePropertySignature(node, name, questionToken, type, initializer) { - return node.name !== name - || node.questionToken !== questionToken - || node.type !== type - || node.initializer !== initializer - ? updateNode(createPropertySignature(name, questionToken, type, initializer), node) - : node; - } - ts.updatePropertySignature = updatePropertySignature; - function createIndexSignatureDeclaration(decorators, modifiers, parameters, type) { - var indexSignature = createSynthesizedNode(157 /* IndexSignature */); - indexSignature.decorators = asNodeArray(decorators); - indexSignature.modifiers = asNodeArray(modifiers); - indexSignature.parameters = createNodeArray(parameters); - indexSignature.type = type; - return indexSignature; - } - ts.createIndexSignatureDeclaration = createIndexSignatureDeclaration; - function updateIndexSignatureDeclaration(node, decorators, modifiers, parameters, type) { - return node.parameters !== parameters - || node.type !== type - || node.decorators !== decorators - || node.modifiers !== modifiers - ? updateNode(createIndexSignatureDeclaration(decorators, modifiers, parameters, type), node) - : node; - } - ts.updateIndexSignatureDeclaration = updateIndexSignatureDeclaration; - // Signature elements function createParameter(decorators, modifiers, dotDotDotToken, name, questionToken, type, initializer) { var node = createSynthesizedNode(146 /* Parameter */); node.decorators = asNodeArray(decorators); @@ -11429,7 +12125,27 @@ var ts; : node; } ts.updateDecorator = updateDecorator; - // Type members + // Type Elements + function createPropertySignature(modifiers, name, questionToken, type, initializer) { + var node = createSynthesizedNode(148 /* PropertySignature */); + node.modifiers = asNodeArray(modifiers); + node.name = asName(name); + node.questionToken = questionToken; + node.type = type; + node.initializer = initializer; + return node; + } + ts.createPropertySignature = createPropertySignature; + function updatePropertySignature(node, modifiers, name, questionToken, type, initializer) { + return node.modifiers !== modifiers + || node.name !== name + || node.questionToken !== questionToken + || node.type !== type + || node.initializer !== initializer + ? updateNode(createPropertySignature(modifiers, name, questionToken, type, initializer), node) + : node; + } + ts.updatePropertySignature = updatePropertySignature; function createProperty(decorators, modifiers, name, questionToken, type, initializer) { var node = createSynthesizedNode(149 /* PropertyDeclaration */); node.decorators = asNodeArray(decorators); @@ -11451,7 +12167,24 @@ var ts; : node; } ts.updateProperty = updateProperty; - function createMethodDeclaration(decorators, modifiers, asteriskToken, name, questionToken, typeParameters, parameters, type, body) { + function createMethodSignature(typeParameters, parameters, type, name, questionToken) { + var node = createSignatureDeclaration(150 /* MethodSignature */, typeParameters, parameters, type); + node.name = asName(name); + node.questionToken = questionToken; + return node; + } + ts.createMethodSignature = createMethodSignature; + function updateMethodSignature(node, typeParameters, parameters, type, name, questionToken) { + return node.typeParameters !== typeParameters + || node.parameters !== parameters + || node.type !== type + || node.name !== name + || node.questionToken !== questionToken + ? updateNode(createMethodSignature(typeParameters, parameters, type, name, questionToken), node) + : node; + } + ts.updateMethodSignature = updateMethodSignature; + function createMethod(decorators, modifiers, asteriskToken, name, questionToken, typeParameters, parameters, type, body) { var node = createSynthesizedNode(151 /* MethodDeclaration */); node.decorators = asNodeArray(decorators); node.modifiers = asNodeArray(modifiers); @@ -11464,7 +12197,7 @@ var ts; node.body = body; return node; } - ts.createMethodDeclaration = createMethodDeclaration; + ts.createMethod = createMethod; function updateMethod(node, decorators, modifiers, asteriskToken, name, questionToken, typeParameters, parameters, type, body) { return node.decorators !== decorators || node.modifiers !== modifiers @@ -11474,7 +12207,7 @@ var ts; || node.parameters !== parameters || node.type !== type || node.body !== body - ? updateNode(createMethodDeclaration(decorators, modifiers, asteriskToken, name, questionToken, typeParameters, parameters, type, body), node) + ? updateNode(createMethod(decorators, modifiers, asteriskToken, name, questionToken, typeParameters, parameters, type, body), node) : node; } ts.updateMethod = updateMethod; @@ -11542,6 +12275,251 @@ var ts; : node; } ts.updateSetAccessor = updateSetAccessor; + function createCallSignature(typeParameters, parameters, type) { + return createSignatureDeclaration(155 /* CallSignature */, typeParameters, parameters, type); + } + ts.createCallSignature = createCallSignature; + function updateCallSignature(node, typeParameters, parameters, type) { + return updateSignatureDeclaration(node, typeParameters, parameters, type); + } + ts.updateCallSignature = updateCallSignature; + function createConstructSignature(typeParameters, parameters, type) { + return createSignatureDeclaration(156 /* ConstructSignature */, typeParameters, parameters, type); + } + ts.createConstructSignature = createConstructSignature; + function updateConstructSignature(node, typeParameters, parameters, type) { + return updateSignatureDeclaration(node, typeParameters, parameters, type); + } + ts.updateConstructSignature = updateConstructSignature; + function createIndexSignature(decorators, modifiers, parameters, type) { + var node = createSynthesizedNode(157 /* IndexSignature */); + node.decorators = asNodeArray(decorators); + node.modifiers = asNodeArray(modifiers); + node.parameters = createNodeArray(parameters); + node.type = type; + return node; + } + ts.createIndexSignature = createIndexSignature; + function updateIndexSignature(node, decorators, modifiers, parameters, type) { + return node.parameters !== parameters + || node.type !== type + || node.decorators !== decorators + || node.modifiers !== modifiers + ? updateNode(createIndexSignature(decorators, modifiers, parameters, type), node) + : node; + } + ts.updateIndexSignature = updateIndexSignature; + /* @internal */ + function createSignatureDeclaration(kind, typeParameters, parameters, type) { + var node = createSynthesizedNode(kind); + node.typeParameters = asNodeArray(typeParameters); + node.parameters = asNodeArray(parameters); + node.type = type; + return node; + } + ts.createSignatureDeclaration = createSignatureDeclaration; + function updateSignatureDeclaration(node, typeParameters, parameters, type) { + return node.typeParameters !== typeParameters + || node.parameters !== parameters + || node.type !== type + ? updateNode(createSignatureDeclaration(node.kind, typeParameters, parameters, type), node) + : node; + } + // Types + function createKeywordTypeNode(kind) { + return createSynthesizedNode(kind); + } + ts.createKeywordTypeNode = createKeywordTypeNode; + function createTypePredicateNode(parameterName, type) { + var node = createSynthesizedNode(158 /* TypePredicate */); + node.parameterName = asName(parameterName); + node.type = type; + return node; + } + ts.createTypePredicateNode = createTypePredicateNode; + function updateTypePredicateNode(node, parameterName, type) { + return node.parameterName !== parameterName + || node.type !== type + ? updateNode(createTypePredicateNode(parameterName, type), node) + : node; + } + ts.updateTypePredicateNode = updateTypePredicateNode; + function createTypeReferenceNode(typeName, typeArguments) { + var node = createSynthesizedNode(159 /* TypeReference */); + node.typeName = asName(typeName); + node.typeArguments = typeArguments && ts.parenthesizeTypeParameters(typeArguments); + return node; + } + ts.createTypeReferenceNode = createTypeReferenceNode; + function updateTypeReferenceNode(node, typeName, typeArguments) { + return node.typeName !== typeName + || node.typeArguments !== typeArguments + ? updateNode(createTypeReferenceNode(typeName, typeArguments), node) + : node; + } + ts.updateTypeReferenceNode = updateTypeReferenceNode; + function createFunctionTypeNode(typeParameters, parameters, type) { + return createSignatureDeclaration(160 /* FunctionType */, typeParameters, parameters, type); + } + ts.createFunctionTypeNode = createFunctionTypeNode; + function updateFunctionTypeNode(node, typeParameters, parameters, type) { + return updateSignatureDeclaration(node, typeParameters, parameters, type); + } + ts.updateFunctionTypeNode = updateFunctionTypeNode; + function createConstructorTypeNode(typeParameters, parameters, type) { + return createSignatureDeclaration(161 /* ConstructorType */, typeParameters, parameters, type); + } + ts.createConstructorTypeNode = createConstructorTypeNode; + function updateConstructorTypeNode(node, typeParameters, parameters, type) { + return updateSignatureDeclaration(node, typeParameters, parameters, type); + } + ts.updateConstructorTypeNode = updateConstructorTypeNode; + function createTypeQueryNode(exprName) { + var node = createSynthesizedNode(162 /* TypeQuery */); + node.exprName = exprName; + return node; + } + ts.createTypeQueryNode = createTypeQueryNode; + function updateTypeQueryNode(node, exprName) { + return node.exprName !== exprName + ? updateNode(createTypeQueryNode(exprName), node) + : node; + } + ts.updateTypeQueryNode = updateTypeQueryNode; + function createTypeLiteralNode(members) { + var node = createSynthesizedNode(163 /* TypeLiteral */); + node.members = createNodeArray(members); + return node; + } + ts.createTypeLiteralNode = createTypeLiteralNode; + function updateTypeLiteralNode(node, members) { + return node.members !== members + ? updateNode(createTypeLiteralNode(members), node) + : node; + } + ts.updateTypeLiteralNode = updateTypeLiteralNode; + function createArrayTypeNode(elementType) { + var node = createSynthesizedNode(164 /* ArrayType */); + node.elementType = ts.parenthesizeElementTypeMember(elementType); + return node; + } + ts.createArrayTypeNode = createArrayTypeNode; + function updateArrayTypeNode(node, elementType) { + return node.elementType !== elementType + ? updateNode(createArrayTypeNode(elementType), node) + : node; + } + ts.updateArrayTypeNode = updateArrayTypeNode; + function createTupleTypeNode(elementTypes) { + var node = createSynthesizedNode(165 /* TupleType */); + node.elementTypes = createNodeArray(elementTypes); + return node; + } + ts.createTupleTypeNode = createTupleTypeNode; + function updateTypleTypeNode(node, elementTypes) { + return node.elementTypes !== elementTypes + ? updateNode(createTupleTypeNode(elementTypes), node) + : node; + } + ts.updateTypleTypeNode = updateTypleTypeNode; + function createUnionTypeNode(types) { + return createUnionOrIntersectionTypeNode(166 /* UnionType */, types); + } + ts.createUnionTypeNode = createUnionTypeNode; + function updateUnionTypeNode(node, types) { + return updateUnionOrIntersectionTypeNode(node, types); + } + ts.updateUnionTypeNode = updateUnionTypeNode; + function createIntersectionTypeNode(types) { + return createUnionOrIntersectionTypeNode(167 /* IntersectionType */, types); + } + ts.createIntersectionTypeNode = createIntersectionTypeNode; + function updateIntersectionTypeNode(node, types) { + return updateUnionOrIntersectionTypeNode(node, types); + } + ts.updateIntersectionTypeNode = updateIntersectionTypeNode; + function createUnionOrIntersectionTypeNode(kind, types) { + var node = createSynthesizedNode(kind); + node.types = ts.parenthesizeElementTypeMembers(types); + return node; + } + ts.createUnionOrIntersectionTypeNode = createUnionOrIntersectionTypeNode; + function updateUnionOrIntersectionTypeNode(node, types) { + return node.types !== types + ? updateNode(createUnionOrIntersectionTypeNode(node.kind, types), node) + : node; + } + function createParenthesizedType(type) { + var node = createSynthesizedNode(168 /* ParenthesizedType */); + node.type = type; + return node; + } + ts.createParenthesizedType = createParenthesizedType; + function updateParenthesizedType(node, type) { + return node.type !== type + ? updateNode(createParenthesizedType(type), node) + : node; + } + ts.updateParenthesizedType = updateParenthesizedType; + function createThisTypeNode() { + return createSynthesizedNode(169 /* ThisType */); + } + ts.createThisTypeNode = createThisTypeNode; + function createTypeOperatorNode(type) { + var node = createSynthesizedNode(170 /* TypeOperator */); + node.operator = 127 /* KeyOfKeyword */; + node.type = ts.parenthesizeElementTypeMember(type); + return node; + } + ts.createTypeOperatorNode = createTypeOperatorNode; + function updateTypeOperatorNode(node, type) { + return node.type !== type ? updateNode(createTypeOperatorNode(type), node) : node; + } + ts.updateTypeOperatorNode = updateTypeOperatorNode; + function createIndexedAccessTypeNode(objectType, indexType) { + var node = createSynthesizedNode(171 /* IndexedAccessType */); + node.objectType = ts.parenthesizeElementTypeMember(objectType); + node.indexType = indexType; + return node; + } + ts.createIndexedAccessTypeNode = createIndexedAccessTypeNode; + function updateIndexedAccessTypeNode(node, objectType, indexType) { + return node.objectType !== objectType + || node.indexType !== indexType + ? updateNode(createIndexedAccessTypeNode(objectType, indexType), node) + : node; + } + ts.updateIndexedAccessTypeNode = updateIndexedAccessTypeNode; + function createMappedTypeNode(readonlyToken, typeParameter, questionToken, type) { + var node = createSynthesizedNode(172 /* MappedType */); + node.readonlyToken = readonlyToken; + node.typeParameter = typeParameter; + node.questionToken = questionToken; + node.type = type; + return node; + } + ts.createMappedTypeNode = createMappedTypeNode; + function updateMappedTypeNode(node, readonlyToken, typeParameter, questionToken, type) { + return node.readonlyToken !== readonlyToken + || node.typeParameter !== typeParameter + || node.questionToken !== questionToken + || node.type !== type + ? updateNode(createMappedTypeNode(readonlyToken, typeParameter, questionToken, type), node) + : node; + } + ts.updateMappedTypeNode = updateMappedTypeNode; + function createLiteralTypeNode(literal) { + var node = createSynthesizedNode(173 /* LiteralType */); + node.literal = literal; + return node; + } + ts.createLiteralTypeNode = createLiteralTypeNode; + function updateLiteralTypeNode(node, literal) { + return node.literal !== literal + ? updateNode(createLiteralTypeNode(literal), node) + : node; + } + ts.updateLiteralTypeNode = updateLiteralTypeNode; // Binding Patterns function createObjectBindingPattern(elements) { var node = createSynthesizedNode(174 /* ObjectBindingPattern */); @@ -11589,9 +12567,8 @@ var ts; function createArrayLiteral(elements, multiLine) { var node = createSynthesizedNode(177 /* ArrayLiteralExpression */); node.elements = ts.parenthesizeListElements(createNodeArray(elements)); - if (multiLine) { + if (multiLine) node.multiLine = true; - } return node; } ts.createArrayLiteral = createArrayLiteral; @@ -11604,9 +12581,8 @@ var ts; function createObjectLiteral(properties, multiLine) { var node = createSynthesizedNode(178 /* ObjectLiteralExpression */); node.properties = createNodeArray(properties); - if (multiLine) { + if (multiLine) node.multiLine = true; - } return node; } ts.createObjectLiteral = createObjectLiteral; @@ -11656,9 +12632,9 @@ var ts; } ts.createCall = createCall; function updateCall(node, expression, typeArguments, argumentsArray) { - return expression !== node.expression - || typeArguments !== node.typeArguments - || argumentsArray !== node.arguments + return node.expression !== expression + || node.typeArguments !== typeArguments + || node.arguments !== argumentsArray ? updateNode(createCall(expression, typeArguments, argumentsArray), node) : node; } @@ -11848,10 +12824,10 @@ var ts; return node; } ts.createBinary = createBinary; - function updateBinary(node, left, right) { + function updateBinary(node, left, right, operator) { return node.left !== left || node.right !== right - ? updateNode(createBinary(left, node.operatorToken, right), node) + ? updateNode(createBinary(left, operator || node.operatorToken, right), node) : node; } ts.updateBinary = updateBinary; @@ -11978,6 +12954,19 @@ var ts; : node; } ts.updateNonNullExpression = updateNonNullExpression; + function createMetaProperty(keywordToken, name) { + var node = createSynthesizedNode(204 /* MetaProperty */); + node.keywordToken = keywordToken; + node.name = name; + return node; + } + ts.createMetaProperty = createMetaProperty; + function updateMetaProperty(node, name) { + return node.name !== name + ? updateNode(createMetaProperty(node.keywordToken, name), node) + : node; + } + ts.updateMetaProperty = updateMetaProperty; // Misc function createTemplateSpan(expression, literal) { var node = createSynthesizedNode(205 /* TemplateSpan */); @@ -11993,6 +12982,10 @@ var ts; : node; } ts.updateTemplateSpan = updateTemplateSpan; + function createSemicolonClassElement() { + return createSynthesizedNode(206 /* SemicolonClassElement */); + } + ts.createSemicolonClassElement = createSemicolonClassElement; // Element function createBlock(statements, multiLine) { var block = createSynthesizedNode(207 /* Block */); @@ -12003,7 +12996,7 @@ var ts; } ts.createBlock = createBlock; function updateBlock(node, statements) { - return statements !== node.statements + return node.statements !== statements ? updateNode(createBlock(statements, node.multiLine), node) : node; } @@ -12023,35 +13016,6 @@ var ts; : node; } ts.updateVariableStatement = updateVariableStatement; - function createVariableDeclarationList(declarations, flags) { - var node = createSynthesizedNode(227 /* VariableDeclarationList */); - node.flags |= flags; - node.declarations = createNodeArray(declarations); - return node; - } - ts.createVariableDeclarationList = createVariableDeclarationList; - function updateVariableDeclarationList(node, declarations) { - return node.declarations !== declarations - ? updateNode(createVariableDeclarationList(declarations, node.flags), node) - : node; - } - ts.updateVariableDeclarationList = updateVariableDeclarationList; - function createVariableDeclaration(name, type, initializer) { - var node = createSynthesizedNode(226 /* VariableDeclaration */); - node.name = asName(name); - node.type = type; - node.initializer = initializer !== undefined ? ts.parenthesizeExpressionForList(initializer) : undefined; - return node; - } - ts.createVariableDeclaration = createVariableDeclaration; - function updateVariableDeclaration(node, name, type, initializer) { - return node.name !== name - || node.type !== type - || node.initializer !== initializer - ? updateNode(createVariableDeclaration(name, type, initializer), node) - : node; - } - ts.updateVariableDeclaration = updateVariableDeclaration; function createEmptyStatement() { return createSynthesizedNode(209 /* EmptyStatement */); } @@ -12270,6 +13234,39 @@ var ts; : node; } ts.updateTry = updateTry; + function createDebuggerStatement() { + return createSynthesizedNode(225 /* DebuggerStatement */); + } + ts.createDebuggerStatement = createDebuggerStatement; + function createVariableDeclaration(name, type, initializer) { + var node = createSynthesizedNode(226 /* VariableDeclaration */); + node.name = asName(name); + node.type = type; + node.initializer = initializer !== undefined ? ts.parenthesizeExpressionForList(initializer) : undefined; + return node; + } + ts.createVariableDeclaration = createVariableDeclaration; + function updateVariableDeclaration(node, name, type, initializer) { + return node.name !== name + || node.type !== type + || node.initializer !== initializer + ? updateNode(createVariableDeclaration(name, type, initializer), node) + : node; + } + ts.updateVariableDeclaration = updateVariableDeclaration; + function createVariableDeclarationList(declarations, flags) { + var node = createSynthesizedNode(227 /* VariableDeclarationList */); + node.flags |= flags & 3 /* BlockScoped */; + node.declarations = createNodeArray(declarations); + return node; + } + ts.createVariableDeclarationList = createVariableDeclarationList; + function updateVariableDeclarationList(node, declarations) { + return node.declarations !== declarations + ? updateNode(createVariableDeclarationList(declarations, node.flags), node) + : node; + } + ts.updateVariableDeclarationList = updateVariableDeclarationList; function createFunctionDeclaration(decorators, modifiers, asteriskToken, name, typeParameters, parameters, type, body) { var node = createSynthesizedNode(228 /* FunctionDeclaration */); node.decorators = asNodeArray(decorators); @@ -12318,6 +13315,48 @@ var ts; : node; } ts.updateClassDeclaration = updateClassDeclaration; + function createInterfaceDeclaration(decorators, modifiers, name, typeParameters, heritageClauses, members) { + var node = createSynthesizedNode(230 /* InterfaceDeclaration */); + node.decorators = asNodeArray(decorators); + node.modifiers = asNodeArray(modifiers); + node.name = asName(name); + node.typeParameters = asNodeArray(typeParameters); + node.heritageClauses = asNodeArray(heritageClauses); + node.members = createNodeArray(members); + return node; + } + ts.createInterfaceDeclaration = createInterfaceDeclaration; + function updateInterfaceDeclaration(node, decorators, modifiers, name, typeParameters, heritageClauses, members) { + return node.decorators !== decorators + || node.modifiers !== modifiers + || node.name !== name + || node.typeParameters !== typeParameters + || node.heritageClauses !== heritageClauses + || node.members !== members + ? updateNode(createInterfaceDeclaration(decorators, modifiers, name, typeParameters, heritageClauses, members), node) + : node; + } + ts.updateInterfaceDeclaration = updateInterfaceDeclaration; + function createTypeAliasDeclaration(decorators, modifiers, name, typeParameters, type) { + var node = createSynthesizedNode(231 /* TypeAliasDeclaration */); + node.decorators = asNodeArray(decorators); + node.modifiers = asNodeArray(modifiers); + node.name = asName(name); + node.typeParameters = asNodeArray(typeParameters); + node.type = type; + return node; + } + ts.createTypeAliasDeclaration = createTypeAliasDeclaration; + function updateTypeAliasDeclaration(node, decorators, modifiers, name, typeParameters, type) { + return node.decorators !== decorators + || node.modifiers !== modifiers + || node.name !== name + || node.typeParameters !== typeParameters + || node.type !== type + ? updateNode(createTypeAliasDeclaration(decorators, modifiers, name, typeParameters, type), node) + : node; + } + ts.updateTypeAliasDeclaration = updateTypeAliasDeclaration; function createEnumDeclaration(decorators, modifiers, name, members) { var node = createSynthesizedNode(232 /* EnumDeclaration */); node.decorators = asNodeArray(decorators); @@ -12338,7 +13377,7 @@ var ts; ts.updateEnumDeclaration = updateEnumDeclaration; function createModuleDeclaration(decorators, modifiers, name, body, flags) { var node = createSynthesizedNode(233 /* ModuleDeclaration */); - node.flags |= flags; + node.flags |= flags & (16 /* Namespace */ | 4 /* NestedNamespace */ | 512 /* GlobalAugmentation */); node.decorators = asNodeArray(decorators); node.modifiers = asNodeArray(modifiers); node.name = name; @@ -12379,6 +13418,18 @@ var ts; : node; } ts.updateCaseBlock = updateCaseBlock; + function createNamespaceExportDeclaration(name) { + var node = createSynthesizedNode(236 /* NamespaceExportDeclaration */); + node.name = asName(name); + return node; + } + ts.createNamespaceExportDeclaration = createNamespaceExportDeclaration; + function updateNamespaceExportDeclaration(node, name) { + return node.name !== name + ? updateNode(createNamespaceExportDeclaration(name), node) + : node; + } + ts.updateNamespaceExportDeclaration = updateNamespaceExportDeclaration; function createImportEqualsDeclaration(decorators, modifiers, name, moduleReference) { var node = createSynthesizedNode(237 /* ImportEqualsDeclaration */); node.decorators = asNodeArray(decorators); @@ -12409,7 +13460,8 @@ var ts; function updateImportDeclaration(node, decorators, modifiers, importClause, moduleSpecifier) { return node.decorators !== decorators || node.modifiers !== modifiers - || node.importClause !== importClause || node.moduleSpecifier !== moduleSpecifier + || node.importClause !== importClause + || node.moduleSpecifier !== moduleSpecifier ? updateNode(createImportDeclaration(decorators, modifiers, importClause, moduleSpecifier), node) : node; } @@ -12597,19 +13649,6 @@ var ts; : node; } ts.updateJsxClosingElement = updateJsxClosingElement; - function createJsxAttributes(properties) { - var jsxAttributes = createSynthesizedNode(254 /* JsxAttributes */); - jsxAttributes.properties = createNodeArray(properties); - return jsxAttributes; - } - ts.createJsxAttributes = createJsxAttributes; - function updateJsxAttributes(jsxAttributes, properties) { - if (jsxAttributes.properties !== properties) { - return updateNode(createJsxAttributes(properties), jsxAttributes); - } - return jsxAttributes; - } - ts.updateJsxAttributes = updateJsxAttributes; function createJsxAttribute(name, initializer) { var node = createSynthesizedNode(253 /* JsxAttribute */); node.name = name; @@ -12624,6 +13663,18 @@ var ts; : node; } ts.updateJsxAttribute = updateJsxAttribute; + function createJsxAttributes(properties) { + var node = createSynthesizedNode(254 /* JsxAttributes */); + node.properties = createNodeArray(properties); + return node; + } + ts.createJsxAttributes = createJsxAttributes; + function updateJsxAttributes(node, properties) { + return node.properties !== properties + ? updateNode(createJsxAttributes(properties), node) + : node; + } + ts.updateJsxAttributes = updateJsxAttributes; function createJsxSpreadAttribute(expression) { var node = createSynthesizedNode(255 /* JsxSpreadAttribute */); node.expression = expression; @@ -12650,20 +13701,6 @@ var ts; } ts.updateJsxExpression = updateJsxExpression; // Clauses - function createHeritageClause(token, types) { - var node = createSynthesizedNode(259 /* HeritageClause */); - node.token = token; - node.types = createNodeArray(types); - return node; - } - ts.createHeritageClause = createHeritageClause; - function updateHeritageClause(node, types) { - if (node.types !== types) { - return updateNode(createHeritageClause(node.token, types), node); - } - return node; - } - ts.updateHeritageClause = updateHeritageClause; function createCaseClause(expression, statements) { var node = createSynthesizedNode(257 /* CaseClause */); node.expression = ts.parenthesizeExpressionForList(expression); @@ -12672,10 +13709,10 @@ var ts; } ts.createCaseClause = createCaseClause; function updateCaseClause(node, expression, statements) { - if (node.expression !== expression || node.statements !== statements) { - return updateNode(createCaseClause(expression, statements), node); - } - return node; + return node.expression !== expression + || node.statements !== statements + ? updateNode(createCaseClause(expression, statements), node) + : node; } ts.updateCaseClause = updateCaseClause; function createDefaultClause(statements) { @@ -12685,12 +13722,24 @@ var ts; } ts.createDefaultClause = createDefaultClause; function updateDefaultClause(node, statements) { - if (node.statements !== statements) { - return updateNode(createDefaultClause(statements), node); - } - return node; + return node.statements !== statements + ? updateNode(createDefaultClause(statements), node) + : node; } ts.updateDefaultClause = updateDefaultClause; + function createHeritageClause(token, types) { + var node = createSynthesizedNode(259 /* HeritageClause */); + node.token = token; + node.types = createNodeArray(types); + return node; + } + ts.createHeritageClause = createHeritageClause; + function updateHeritageClause(node, types) { + return node.types !== types + ? updateNode(createHeritageClause(node.token, types), node) + : node; + } + ts.updateHeritageClause = updateHeritageClause; function createCatchClause(variableDeclaration, block) { var node = createSynthesizedNode(260 /* CatchClause */); node.variableDeclaration = typeof variableDeclaration === "string" ? createVariableDeclaration(variableDeclaration) : variableDeclaration; @@ -12699,10 +13748,10 @@ var ts; } ts.createCatchClause = createCatchClause; function updateCatchClause(node, variableDeclaration, block) { - if (node.variableDeclaration !== variableDeclaration || node.block !== block) { - return updateNode(createCatchClause(variableDeclaration, block), node); - } - return node; + return node.variableDeclaration !== variableDeclaration + || node.block !== block + ? updateNode(createCatchClause(variableDeclaration, block), node) + : node; } ts.updateCatchClause = updateCatchClause; // Property assignments @@ -12715,10 +13764,10 @@ var ts; } ts.createPropertyAssignment = createPropertyAssignment; function updatePropertyAssignment(node, name, initializer) { - if (node.name !== name || node.initializer !== initializer) { - return updateNode(createPropertyAssignment(name, initializer), node); - } - return node; + return node.name !== name + || node.initializer !== initializer + ? updateNode(createPropertyAssignment(name, initializer), node) + : node; } ts.updatePropertyAssignment = updatePropertyAssignment; function createShorthandPropertyAssignment(name, objectAssignmentInitializer) { @@ -12729,10 +13778,10 @@ var ts; } ts.createShorthandPropertyAssignment = createShorthandPropertyAssignment; function updateShorthandPropertyAssignment(node, name, objectAssignmentInitializer) { - if (node.name !== name || node.objectAssignmentInitializer !== objectAssignmentInitializer) { - return updateNode(createShorthandPropertyAssignment(name, objectAssignmentInitializer), node); - } - return node; + return node.name !== name + || node.objectAssignmentInitializer !== objectAssignmentInitializer + ? updateNode(createShorthandPropertyAssignment(name, objectAssignmentInitializer), node) + : node; } ts.updateShorthandPropertyAssignment = updateShorthandPropertyAssignment; function createSpreadAssignment(expression) { @@ -12742,10 +13791,9 @@ var ts; } ts.createSpreadAssignment = createSpreadAssignment; function updateSpreadAssignment(node, expression) { - if (node.expression !== expression) { - return updateNode(createSpreadAssignment(expression), node); - } - return node; + return node.expression !== expression + ? updateNode(createSpreadAssignment(expression), node) + : node; } ts.updateSpreadAssignment = updateSpreadAssignment; // Enum @@ -12845,7 +13893,7 @@ var ts; * @param original The original statement. */ function createNotEmittedStatement(original) { - var node = createSynthesizedNode(295 /* NotEmittedStatement */); + var node = createSynthesizedNode(296 /* NotEmittedStatement */); node.original = original; setTextRange(node, original); return node; @@ -12857,7 +13905,7 @@ var ts; */ /* @internal */ function createEndOfDeclarationMarker(original) { - var node = createSynthesizedNode(298 /* EndOfDeclarationMarker */); + var node = createSynthesizedNode(300 /* EndOfDeclarationMarker */); node.emitNode = {}; node.original = original; return node; @@ -12869,7 +13917,7 @@ var ts; */ /* @internal */ function createMergeDeclarationMarker(original) { - var node = createSynthesizedNode(297 /* MergeDeclarationMarker */); + var node = createSynthesizedNode(299 /* MergeDeclarationMarker */); node.emitNode = {}; node.original = original; return node; @@ -12884,7 +13932,7 @@ var ts; * @param location The location for the expression. Defaults to the positions from "original" if provided. */ function createPartiallyEmittedExpression(expression, original) { - var node = createSynthesizedNode(296 /* PartiallyEmittedExpression */); + var node = createSynthesizedNode(297 /* PartiallyEmittedExpression */); node.expression = expression; node.original = original; setTextRange(node, original); @@ -12898,6 +13946,29 @@ var ts; return node; } ts.updatePartiallyEmittedExpression = updatePartiallyEmittedExpression; + function flattenCommaElements(node) { + if (ts.nodeIsSynthesized(node) && !ts.isParseTreeNode(node) && !node.original && !node.emitNode && !node.id) { + if (node.kind === 298 /* CommaListExpression */) { + return node.elements; + } + if (ts.isBinaryExpression(node) && node.operatorToken.kind === 26 /* CommaToken */) { + return [node.left, node.right]; + } + } + return node; + } + function createCommaList(elements) { + var node = createSynthesizedNode(298 /* CommaListExpression */); + node.elements = createNodeArray(ts.sameFlatMap(elements, flattenCommaElements)); + return node; + } + ts.createCommaList = createCommaList; + function updateCommaList(node, elements) { + return node.elements !== elements + ? updateNode(createCommaList(elements), node) + : node; + } + ts.updateCommaList = updateCommaList; function createBundle(sourceFiles) { var node = ts.createNode(266 /* Bundle */); node.sourceFiles = sourceFiles; @@ -12911,7 +13982,18 @@ var ts; return node; } ts.updateBundle = updateBundle; - // Compound nodes + function createImmediatelyInvokedFunctionExpression(statements, param, paramValue) { + return createCall(createFunctionExpression( + /*modifiers*/ undefined, + /*asteriskToken*/ undefined, + /*name*/ undefined, + /*typeParameters*/ undefined, + /*parameters*/ param ? [param] : [], + /*type*/ undefined, createBlock(statements, /*multiLine*/ true)), + /*typeArguments*/ undefined, + /*argumentsArray*/ paramValue ? [paramValue] : []); + } + ts.createImmediatelyInvokedFunctionExpression = createImmediatelyInvokedFunctionExpression; function createComma(left, right) { return createBinary(left, 26 /* CommaToken */, right); } @@ -13064,6 +14146,14 @@ var ts; return node; } ts.setSourceMapRange = setSourceMapRange; + var SourceMapSource; + /** + * Create an external source map source file reference + */ + function createSourceMapSource(fileName, text, skipTrivia) { + return new (SourceMapSource || (SourceMapSource = ts.objectAllocator.getSourceMapSourceConstructor()))(fileName, text, skipTrivia); + } + ts.createSourceMapSource = createSourceMapSource; /** * Gets the TextRange to use for source maps for a token of a node. */ @@ -13245,6 +14335,7 @@ var ts; var flags = sourceEmitNode.flags, leadingComments = sourceEmitNode.leadingComments, trailingComments = sourceEmitNode.trailingComments, commentRange = sourceEmitNode.commentRange, sourceMapRange = sourceEmitNode.sourceMapRange, tokenSourceMapRanges = sourceEmitNode.tokenSourceMapRanges, constantValue = sourceEmitNode.constantValue, helpers = sourceEmitNode.helpers; if (!destEmitNode) destEmitNode = {}; + // We are using `.slice()` here in case `destEmitNode.leadingComments` is pushed to later. if (leadingComments) destEmitNode.leadingComments = ts.addRange(leadingComments.slice(), destEmitNode.leadingComments); if (trailingComments) @@ -13274,7 +14365,25 @@ var ts; })(ts || (ts = {})); /* @internal */ (function (ts) { - // Compound nodes + ts.nullTransformationContext = { + enableEmitNotification: ts.noop, + enableSubstitution: ts.noop, + endLexicalEnvironment: function () { return undefined; }, + getCompilerOptions: ts.notImplemented, + getEmitHost: ts.notImplemented, + getEmitResolver: ts.notImplemented, + hoistFunctionDeclaration: ts.noop, + hoistVariableDeclaration: ts.noop, + isEmitNotificationEnabled: ts.notImplemented, + isSubstitutionEnabled: ts.notImplemented, + onEmitNode: ts.noop, + onSubstituteNode: ts.notImplemented, + readEmitHelpers: ts.notImplemented, + requestEmitHelper: ts.noop, + resumeLexicalEnvironment: ts.noop, + startLexicalEnvironment: ts.noop, + suspendLexicalEnvironment: ts.noop + }; function createTypeCheck(value, tag) { return tag === "undefined" ? ts.createStrictEquality(value, ts.createVoidZero()) @@ -13536,7 +14645,11 @@ var ts; } ts.createCallBinding = createCallBinding; function inlineExpressions(expressions) { - return ts.reduceLeft(expressions, ts.createComma); + // Avoid deeply nested comma expressions as traversing them during emit can result in "Maximum call + // stack size exceeded" errors. + return expressions.length > 10 + ? ts.createCommaList(expressions) + : ts.reduceLeft(expressions, ts.createComma); } ts.inlineExpressions = inlineExpressions; function createExpressionFromEntityName(node) { @@ -13767,6 +14880,18 @@ var ts; return ts.isBlock(node) ? node : ts.setTextRange(ts.createBlock([ts.setTextRange(ts.createReturn(node), node)], multiLine), node); } ts.convertToFunctionBody = convertToFunctionBody; + function convertFunctionDeclarationToExpression(node) { + ts.Debug.assert(!!node.body); + var updated = ts.createFunctionExpression(node.modifiers, node.asteriskToken, node.name, node.typeParameters, node.parameters, node.type, node.body); + ts.setOriginalNode(updated, node); + ts.setTextRange(updated, node); + if (node.startsOnNewLine) { + updated.startsOnNewLine = true; + } + ts.aggregateTransformFlags(updated); + return updated; + } + ts.convertFunctionDeclarationToExpression = convertFunctionDeclarationToExpression; function isUseStrictPrologue(node) { return node.expression.text === "use strict"; } @@ -13871,16 +14996,6 @@ var ts; return statements; } ts.ensureUseStrict = ensureUseStrict; - function parenthesizeConditionalHead(condition) { - var conditionalPrecedence = ts.getOperatorPrecedence(195 /* ConditionalExpression */, 55 /* QuestionToken */); - var emittedCondition = skipPartiallyEmittedExpressions(condition); - var conditionPrecedence = ts.getExpressionPrecedence(emittedCondition); - if (ts.compareValues(conditionPrecedence, conditionalPrecedence) === -1 /* LessThan */) { - return ts.createParen(condition); - } - return condition; - } - ts.parenthesizeConditionalHead = parenthesizeConditionalHead; /** * Wraps the operand to a BinaryExpression in parentheses if they are needed to preserve the intended * order of operations. @@ -14144,7 +15259,7 @@ var ts; if (kind === 186 /* FunctionExpression */ || kind === 187 /* ArrowFunction */) { var mutableCall = ts.getMutableClone(emittedExpression); mutableCall.expression = ts.setTextRange(ts.createParen(callee), callee); - return recreatePartiallyEmittedExpressions(expression, mutableCall); + return recreateOuterExpressions(expression, mutableCall, 4 /* PartiallyEmittedExpressions */); } } else { @@ -14156,20 +15271,34 @@ var ts; return expression; } ts.parenthesizeExpressionForExpressionStatement = parenthesizeExpressionForExpressionStatement; - /** - * Clones a series of not-emitted expressions with a new inner expression. - * - * @param originalOuterExpression The original outer expression. - * @param newInnerExpression The new inner expression. - */ - function recreatePartiallyEmittedExpressions(originalOuterExpression, newInnerExpression) { - if (ts.isPartiallyEmittedExpression(originalOuterExpression)) { - var clone_1 = ts.getMutableClone(originalOuterExpression); - clone_1.expression = recreatePartiallyEmittedExpressions(clone_1.expression, newInnerExpression); - return clone_1; + function parenthesizeElementTypeMember(member) { + switch (member.kind) { + case 166 /* UnionType */: + case 167 /* IntersectionType */: + case 160 /* FunctionType */: + case 161 /* ConstructorType */: + return ts.createParenthesizedType(member); + } + return member; + } + ts.parenthesizeElementTypeMember = parenthesizeElementTypeMember; + function parenthesizeElementTypeMembers(members) { + return ts.createNodeArray(ts.sameMap(members, parenthesizeElementTypeMember)); + } + ts.parenthesizeElementTypeMembers = parenthesizeElementTypeMembers; + function parenthesizeTypeParameters(typeParameters) { + if (ts.some(typeParameters)) { + var nodeArray = ts.createNodeArray(); + for (var i = 0; i < typeParameters.length; ++i) { + var entry = typeParameters[i]; + nodeArray.push(i === 0 && ts.isFunctionOrConstructorTypeNode(entry) && entry.typeParameters ? + ts.createParenthesizedType(entry) : + entry); + } + return nodeArray; } - return newInnerExpression; } + ts.parenthesizeTypeParameters = parenthesizeTypeParameters; function getLeftmostExpression(node) { while (true) { switch (node.kind) { @@ -14187,7 +15316,7 @@ var ts; case 179 /* PropertyAccessExpression */: node = node.expression; continue; - case 296 /* PartiallyEmittedExpression */: + case 297 /* PartiallyEmittedExpression */: node = node.expression; continue; } @@ -14208,6 +15337,21 @@ var ts; OuterExpressionKinds[OuterExpressionKinds["PartiallyEmittedExpressions"] = 4] = "PartiallyEmittedExpressions"; OuterExpressionKinds[OuterExpressionKinds["All"] = 7] = "All"; })(OuterExpressionKinds = ts.OuterExpressionKinds || (ts.OuterExpressionKinds = {})); + function isOuterExpression(node, kinds) { + if (kinds === void 0) { kinds = 7 /* All */; } + switch (node.kind) { + case 185 /* ParenthesizedExpression */: + return (kinds & 1 /* Parentheses */) !== 0; + case 184 /* TypeAssertionExpression */: + case 202 /* AsExpression */: + case 203 /* NonNullExpression */: + return (kinds & 2 /* Assertions */) !== 0; + case 297 /* PartiallyEmittedExpression */: + return (kinds & 4 /* PartiallyEmittedExpressions */) !== 0; + } + return false; + } + ts.isOuterExpression = isOuterExpression; function skipOuterExpressions(node, kinds) { if (kinds === void 0) { kinds = 7 /* All */; } var previousNode; @@ -14234,19 +15378,36 @@ var ts; } ts.skipParentheses = skipParentheses; function skipAssertions(node) { - while (ts.isAssertionExpression(node)) { + while (ts.isAssertionExpression(node) || node.kind === 203 /* NonNullExpression */) { node = node.expression; } return node; } ts.skipAssertions = skipAssertions; function skipPartiallyEmittedExpressions(node) { - while (node.kind === 296 /* PartiallyEmittedExpression */) { + while (node.kind === 297 /* PartiallyEmittedExpression */) { node = node.expression; } return node; } ts.skipPartiallyEmittedExpressions = skipPartiallyEmittedExpressions; + function updateOuterExpression(outerExpression, expression) { + switch (outerExpression.kind) { + case 185 /* ParenthesizedExpression */: return ts.updateParen(outerExpression, expression); + case 184 /* TypeAssertionExpression */: return ts.updateTypeAssertion(outerExpression, outerExpression.type, expression); + case 202 /* AsExpression */: return ts.updateAsExpression(outerExpression, expression, outerExpression.type); + case 203 /* NonNullExpression */: return ts.updateNonNullExpression(outerExpression, expression); + case 297 /* PartiallyEmittedExpression */: return ts.updatePartiallyEmittedExpression(outerExpression, expression); + } + } + function recreateOuterExpressions(outerExpression, innerExpression, kinds) { + if (kinds === void 0) { kinds = 7 /* All */; } + if (outerExpression && isOuterExpression(outerExpression, kinds)) { + return updateOuterExpression(outerExpression, recreateOuterExpressions(outerExpression.expression, innerExpression)); + } + return innerExpression; + } + ts.recreateOuterExpressions = recreateOuterExpressions; function startOnNewLine(node) { node.startsOnNewLine = true; return node; @@ -14258,23 +15419,33 @@ var ts; return emitNode && emitNode.externalHelpersModuleName; } ts.getExternalHelpersModuleName = getExternalHelpersModuleName; - function getOrCreateExternalHelpersModuleNameIfNeeded(node, compilerOptions) { - if (compilerOptions.importHelpers && (ts.isExternalModule(node) || compilerOptions.isolatedModules)) { + function getOrCreateExternalHelpersModuleNameIfNeeded(node, compilerOptions, hasExportStarsToExportValues) { + if (compilerOptions.importHelpers && ts.isEffectiveExternalModule(node, compilerOptions)) { var externalHelpersModuleName = getExternalHelpersModuleName(node); if (externalHelpersModuleName) { return externalHelpersModuleName; } - var helpers = ts.getEmitHelpers(node); - if (helpers) { - for (var _i = 0, helpers_2 = helpers; _i < helpers_2.length; _i++) { - var helper = helpers_2[_i]; - if (!helper.scoped) { - var parseNode = ts.getOriginalNode(node, ts.isSourceFile); - var emitNode = ts.getOrCreateEmitNode(parseNode); - return emitNode.externalHelpersModuleName || (emitNode.externalHelpersModuleName = ts.createUniqueName(ts.externalHelpersModuleNameText)); + var moduleKind = ts.getEmitModuleKind(compilerOptions); + var create = hasExportStarsToExportValues + && moduleKind !== ts.ModuleKind.System + && moduleKind !== ts.ModuleKind.ES2015; + if (!create) { + var helpers = ts.getEmitHelpers(node); + if (helpers) { + for (var _i = 0, helpers_2 = helpers; _i < helpers_2.length; _i++) { + var helper = helpers_2[_i]; + if (!helper.scoped) { + create = true; + break; + } } } } + if (create) { + var parseNode = ts.getOriginalNode(node, ts.isSourceFile); + var emitNode = ts.getOrCreateEmitNode(parseNode); + return emitNode.externalHelpersModuleName || (emitNode.externalHelpersModuleName = ts.createUniqueName(ts.externalHelpersModuleNameText)); + } } } ts.getOrCreateExternalHelpersModuleNameIfNeeded = getOrCreateExternalHelpersModuleNameIfNeeded; @@ -14336,7 +15507,7 @@ var ts; if (file.moduleName) { return ts.createLiteral(file.moduleName); } - if (!ts.isDeclarationFile(file) && (options.out || options.outFile)) { + if (!file.isDeclarationFile && (options.out || options.outFile)) { return ts.createLiteral(ts.getExternalModuleNameFromPath(host, file.fileName)); } return undefined; @@ -14377,7 +15548,7 @@ var ts; // `1` in `[[a] = 1] = ...` return bindingElement.right; } - if (ts.isSpreadExpression(bindingElement)) { + if (ts.isSpreadElement(bindingElement)) { // Recovery consistent with existing emit. return getInitializerOfBindingOrAssignmentElement(bindingElement.expression); } @@ -14439,7 +15610,7 @@ var ts; // `a[0]` in `[a[0] = 1] = ...` return getTargetOfBindingOrAssignmentElement(bindingElement.left); } - if (ts.isSpreadExpression(bindingElement)) { + if (ts.isSpreadElement(bindingElement)) { // `a` in `[...a] = ...` return getTargetOfBindingOrAssignmentElement(bindingElement.expression); } @@ -14603,13 +15774,6 @@ var ts; var hasExportDefault = false; var exportEquals = undefined; var hasExportStarsToExportValues = false; - var externalHelpersModuleName = getOrCreateExternalHelpersModuleNameIfNeeded(sourceFile, compilerOptions); - var externalHelpersImportDeclaration = externalHelpersModuleName && ts.createImportDeclaration( - /*decorators*/ undefined, - /*modifiers*/ undefined, ts.createImportClause(/*name*/ undefined, ts.createNamespaceImport(externalHelpersModuleName)), ts.createLiteral(ts.externalHelpersModuleNameText)); - if (externalHelpersImportDeclaration) { - externalImports.push(externalHelpersImportDeclaration); - } for (var _i = 0, _a = sourceFile.statements; _i < _a.length; _i++) { var node = _a[_i]; switch (node.kind) { @@ -14712,6 +15876,13 @@ var ts; break; } } + var externalHelpersModuleName = getOrCreateExternalHelpersModuleNameIfNeeded(sourceFile, compilerOptions, hasExportStarsToExportValues); + var externalHelpersImportDeclaration = externalHelpersModuleName && ts.createImportDeclaration( + /*decorators*/ undefined, + /*modifiers*/ undefined, ts.createImportClause(/*name*/ undefined, ts.createNamespaceImport(externalHelpersModuleName)), ts.createLiteral(ts.externalHelpersModuleNameText)); + if (externalHelpersImportDeclaration) { + externalImports.unshift(externalHelpersImportDeclaration); + } return { externalImports: externalImports, exportSpecifiers: exportSpecifiers, exportEquals: exportEquals, hasExportStarsToExportValues: hasExportStarsToExportValues, exportedBindings: exportedBindings, exportedNames: exportedNames, externalHelpersImportDeclaration: externalHelpersImportDeclaration }; } ts.collectExternalModuleInfo = collectExternalModuleInfo; @@ -14760,7 +15931,7 @@ var ts; else if (kind === 71 /* Identifier */) { return new (IdentifierConstructor || (IdentifierConstructor = ts.objectAllocator.getIdentifierConstructor()))(kind, pos, end); } - else if (kind < 143 /* FirstNode */) { + else if (!ts.isNodeKind(kind)) { return new (TokenConstructor || (TokenConstructor = ts.objectAllocator.getTokenConstructor()))(kind, pos, end); } else { @@ -14789,10 +15960,16 @@ var ts; } } } - // Invokes a callback for each child of the given node. The 'cbNode' callback is invoked for all child nodes - // stored in properties. If a 'cbNodes' callback is specified, it is invoked for embedded arrays; otherwise, - // embedded arrays are flattened and the 'cbNode' callback is invoked for each element. If a callback returns - // a truthy value, iteration stops and that value is returned. Otherwise, undefined is returned. + /** + * Invokes a callback for each child of the given node. The 'cbNode' callback is invoked for all child nodes + * stored in properties. If a 'cbNodes' callback is specified, it is invoked for embedded arrays; otherwise, + * embedded arrays are flattened and the 'cbNode' callback is invoked for each element. If a callback returns + * a truthy value, iteration stops and that value is returned. Otherwise, undefined is returned. + * + * @param node a given node to visit its children + * @param cbNode a callback to be invoked for all child nodes + * @param cbNodeArray a callback to be invoked for embedded array + */ function forEachChild(node, cbNode, cbNodeArray) { if (!node) { return; @@ -15104,6 +16281,8 @@ var ts; return visitNode(cbNode, node.expression); case 247 /* MissingDeclaration */: return visitNodes(cbNodes, node.decorators); + case 298 /* CommaListExpression */: + return visitNodes(cbNodes, node.elements); case 249 /* JsxElement */: return visitNode(cbNode, node.openingElement) || visitNodes(cbNodes, node.children) || @@ -15157,31 +16336,31 @@ var ts; visitNode(cbNode, node.type); case 283 /* JSDocComment */: return visitNodes(cbNodes, node.tags); - case 286 /* JSDocParameterTag */: + case 287 /* JSDocParameterTag */: return visitNode(cbNode, node.preParameterName) || visitNode(cbNode, node.typeExpression) || visitNode(cbNode, node.postParameterName); - case 287 /* JSDocReturnTag */: + case 288 /* JSDocReturnTag */: return visitNode(cbNode, node.typeExpression); - case 288 /* JSDocTypeTag */: + case 289 /* JSDocTypeTag */: return visitNode(cbNode, node.typeExpression); case 285 /* JSDocAugmentsTag */: return visitNode(cbNode, node.typeExpression); - case 289 /* JSDocTemplateTag */: + case 290 /* JSDocTemplateTag */: return visitNodes(cbNodes, node.typeParameters); - case 290 /* JSDocTypedefTag */: + case 291 /* JSDocTypedefTag */: return visitNode(cbNode, node.typeExpression) || visitNode(cbNode, node.fullName) || visitNode(cbNode, node.name) || visitNode(cbNode, node.jsDocTypeLiteral); - case 292 /* JSDocTypeLiteral */: + case 293 /* JSDocTypeLiteral */: return visitNodes(cbNodes, node.jsDocPropertyTags); - case 291 /* JSDocPropertyTag */: + case 292 /* JSDocPropertyTag */: return visitNode(cbNode, node.typeExpression) || visitNode(cbNode, node.name); - case 296 /* PartiallyEmittedExpression */: + case 297 /* PartiallyEmittedExpression */: return visitNode(cbNode, node.expression); - case 293 /* JSDocLiteralType */: + case 294 /* JSDocLiteralType */: return visitNode(cbNode, node.literal); } } @@ -15214,7 +16393,11 @@ var ts; // becoming detached from any SourceFile). It is recommended that this SourceFile not // be used once 'update' is called on it. function updateSourceFile(sourceFile, newText, textChangeRange, aggressiveChecks) { - return IncrementalParser.updateSourceFile(sourceFile, newText, textChangeRange, aggressiveChecks); + var newSourceFile = IncrementalParser.updateSourceFile(sourceFile, newText, textChangeRange, aggressiveChecks); + // Because new source file node is created, it may not have the flag PossiblyContainDynamicImport. This is the case if there is no new edit to add dynamic import. + // We will manually port the flag to the new source file. + newSourceFile.flags |= (sourceFile.flags & 524288 /* PossiblyContainsDynamicImport */); + return newSourceFile; } ts.updateSourceFile = updateSourceFile; /* @internal */ @@ -15393,7 +16576,7 @@ var ts; processReferenceComments(sourceFile); sourceFile.statements = parseList(0 /* SourceElements */, parseStatement); ts.Debug.assert(token() === 1 /* EndOfFileToken */); - sourceFile.endOfFileToken = parseTokenNode(); + sourceFile.endOfFileToken = addJSDocComment(parseTokenNode()); setExternalModuleIndicator(sourceFile); sourceFile.nodeCount = nodeCount; sourceFile.identifierCount = identifierCount; @@ -15738,7 +16921,7 @@ var ts; if (!(pos >= 0)) { pos = scanner.getStartPos(); } - return kind >= 143 /* FirstNode */ ? new NodeConstructor(kind, pos, pos) : + return ts.isNodeKind(kind) ? new NodeConstructor(kind, pos, pos) : kind === 71 /* Identifier */ ? new IdentifierConstructor(kind, pos, pos) : new TokenConstructor(kind, pos, pos); } @@ -15861,12 +17044,12 @@ var ts; if (token() === 84 /* ExportKeyword */) { nextToken(); if (token() === 79 /* DefaultKeyword */) { - return lookAhead(nextTokenIsClassOrFunctionOrAsync); + return lookAhead(nextTokenCanFollowDefaultKeyword); } return token() !== 39 /* AsteriskToken */ && token() !== 118 /* AsKeyword */ && token() !== 17 /* OpenBraceToken */ && canFollowModifier(); } if (token() === 79 /* DefaultKeyword */) { - return nextTokenIsClassOrFunctionOrAsync(); + return nextTokenCanFollowDefaultKeyword(); } if (token() === 115 /* StaticKeyword */) { nextToken(); @@ -15884,9 +17067,10 @@ var ts; || token() === 24 /* DotDotDotToken */ || isLiteralPropertyName(); } - function nextTokenIsClassOrFunctionOrAsync() { + function nextTokenCanFollowDefaultKeyword() { nextToken(); return token() === 75 /* ClassKeyword */ || token() === 89 /* FunctionKeyword */ || + token() === 109 /* InterfaceKeyword */ || (token() === 117 /* AbstractKeyword */ && lookAhead(nextTokenIsClassKeywordOnSameLine)) || (token() === 120 /* AsyncKeyword */ && lookAhead(nextTokenIsFunctionKeywordOnSameLine)); } @@ -16864,7 +18048,7 @@ var ts; if (token() === 19 /* OpenParenToken */ || token() === 27 /* LessThanToken */) { return parseSignatureMember(155 /* CallSignature */); } - if (token() === 94 /* NewKeyword */ && lookAhead(isStartOfConstructSignature)) { + if (token() === 94 /* NewKeyword */ && lookAhead(nextTokenIsOpenParenOrLessThan)) { return parseSignatureMember(156 /* ConstructSignature */); } var fullStart = getNodePos(); @@ -16874,7 +18058,7 @@ var ts; } return parsePropertyOrMethodSignature(fullStart, modifiers); } - function isStartOfConstructSignature() { + function nextTokenIsOpenParenOrLessThan() { nextToken(); return token() === 19 /* OpenParenToken */ || token() === 27 /* LessThanToken */; } @@ -17201,6 +18385,8 @@ var ts; case 63 /* SlashEqualsToken */: case 71 /* Identifier */: return true; + case 91 /* ImportKeyword */: + return lookAhead(nextTokenIsOpenParenOrLessThan); default: return isIdentifier(); } @@ -17841,10 +19027,10 @@ var ts; * 5) --UnaryExpression[?Yield] */ if (isUpdateExpression()) { - var incrementExpression = parseIncrementExpression(); + var updateExpression = parseUpdateExpression(); return token() === 40 /* AsteriskAsteriskToken */ ? - parseBinaryExpressionRest(getBinaryOperatorPrecedence(), incrementExpression) : - incrementExpression; + parseBinaryExpressionRest(getBinaryOperatorPrecedence(), updateExpression) : + updateExpression; } /** * ES7 UnaryExpression: @@ -17908,7 +19094,7 @@ var ts; } // falls through default: - return parseIncrementExpression(); + return parseUpdateExpression(); } } /** @@ -17923,7 +19109,7 @@ var ts; */ function isUpdateExpression() { // This function is called inside parseUnaryExpression to decide - // whether to call parseSimpleUnaryExpression or call parseIncrementExpression directly + // whether to call parseSimpleUnaryExpression or call parseUpdateExpression directly switch (token()) { case 37 /* PlusToken */: case 38 /* MinusToken */: @@ -17946,9 +19132,9 @@ var ts; } } /** - * Parse ES7 IncrementExpression. IncrementExpression is used instead of ES6's PostFixExpression. + * Parse ES7 UpdateExpression. UpdateExpression is used instead of ES6's PostFixExpression. * - * ES7 IncrementExpression[yield]: + * ES7 UpdateExpression[yield]: * 1) LeftHandSideExpression[?yield] * 2) LeftHandSideExpression[?yield] [[no LineTerminator here]]++ * 3) LeftHandSideExpression[?yield] [[no LineTerminator here]]-- @@ -17956,7 +19142,7 @@ var ts; * 5) --LeftHandSideExpression[?yield] * In TypeScript (2), (3) are parsed as PostfixUnaryExpression. (4), (5) are parsed as PrefixUnaryExpression */ - function parseIncrementExpression() { + function parseUpdateExpression() { if (token() === 43 /* PlusPlusToken */ || token() === 44 /* MinusMinusToken */) { var node = createNode(192 /* PrefixUnaryExpression */); node.operator = token(); @@ -18002,23 +19188,33 @@ var ts; // CallExpression Arguments // CallExpression[Expression] // CallExpression.IdentifierName - // super ( ArgumentListopt ) + // import (AssignmentExpression) + // super Arguments // super.IdentifierName // - // Because of the recursion in these calls, we need to bottom out first. There are two - // bottom out states we can run into. Either we see 'super' which must start either of - // the last two CallExpression productions. Or we have a MemberExpression which either - // completes the LeftHandSideExpression, or starts the beginning of the first four - // CallExpression productions. - var expression = token() === 97 /* SuperKeyword */ - ? parseSuperExpression() - : parseMemberExpressionOrHigher(); + // Because of the recursion in these calls, we need to bottom out first. There are three + // bottom out states we can run into: 1) We see 'super' which must start either of + // the last two CallExpression productions. 2) We see 'import' which must start import call. + // 3)we have a MemberExpression which either completes the LeftHandSideExpression, + // or starts the beginning of the first four CallExpression productions. + var expression; + if (token() === 91 /* ImportKeyword */ && lookAhead(nextTokenIsOpenParenOrLessThan)) { + // We don't want to eagerly consume all import keyword as import call expression so we look a head to find "(" + // For example: + // var foo3 = require("subfolder + // import * as foo1 from "module-from-node -> we want this import to be a statement rather than import call expression + sourceFile.flags |= 524288 /* PossiblyContainsDynamicImport */; + expression = parseTokenNode(); + } + else { + expression = token() === 97 /* SuperKeyword */ ? parseSuperExpression() : parseMemberExpressionOrHigher(); + } // Now, we *may* be complete. However, we might have consumed the start of a // CallExpression. As such, we need to consume the rest of it here to be complete. return parseCallExpressionRest(expression); } function parseMemberExpressionOrHigher() { - // Note: to make our lives simpler, we decompose the the NewExpression productions and + // Note: to make our lives simpler, we decompose the NewExpression productions and // place ObjectCreationExpression and FunctionExpression into PrimaryExpression. // like so: // @@ -18414,7 +19610,7 @@ var ts; case 48 /* AmpersandToken */: // foo & case 49 /* BarToken */: // foo | case 18 /* CloseBraceToken */: // foo } - case 1 /* EndOfFileToken */: + case 1 /* EndOfFileToken */:// foo // these cases can't legally follow a type arg list. However, they're not legal // expressions either. The user is probably in the middle of a generic type. So // treat it as such. @@ -18979,9 +20175,10 @@ var ts; case 74 /* CatchKeyword */: case 87 /* FinallyKeyword */: return true; + case 91 /* ImportKeyword */: + return isStartOfDeclaration() || lookAhead(nextTokenIsOpenParenOrLessThan); case 76 /* ConstKeyword */: case 84 /* ExportKeyword */: - case 91 /* ImportKeyword */: return isStartOfDeclaration(); case 120 /* AsyncKeyword */: case 124 /* DeclareKeyword */: @@ -19389,7 +20586,7 @@ var ts; case 27 /* LessThanToken */: // Generic Method declaration case 56 /* ColonToken */: // Type Annotation for declaration case 58 /* EqualsToken */: // Initializer for declaration - case 55 /* QuestionToken */: + case 55 /* QuestionToken */:// Not valid, but permitted so that it gets caught later on. return true; default: // Covers @@ -20116,7 +21313,10 @@ var ts; case 17 /* OpenBraceToken */: return parseJSDocRecordType(); case 89 /* FunctionKeyword */: - return parseJSDocFunctionType(); + if (lookAhead(nextTokenIsOpenParen)) { + return parseJSDocFunctionType(); + } + break; case 24 /* DotDotDotToken */: return parseJSDocVariadicType(); case 94 /* NewKeyword */: @@ -20132,7 +21332,6 @@ var ts; case 95 /* NullKeyword */: case 139 /* UndefinedKeyword */: case 130 /* NeverKeyword */: - case 134 /* ObjectKeyword */: return parseTokenNode(); case 9 /* StringLiteral */: case 8 /* NumericLiteral */: @@ -20272,7 +21471,7 @@ var ts; return finishNode(result); } function parseJSDocLiteralType() { - var result = createNode(293 /* JSDocLiteralType */); + var result = createNode(294 /* JSDocLiteralType */); result.literal = parseLiteralTypeNode(); return finishNode(result); } @@ -20321,10 +21520,17 @@ var ts; if (comment) { comment.parent = parent; } + if (ts.isInJavaScriptFile(parent)) { + if (!sourceFile.jsDocDiagnostics) { + sourceFile.jsDocDiagnostics = []; + } + (_a = sourceFile.jsDocDiagnostics).push.apply(_a, parseDiagnostics); + } currentToken = saveToken; parseDiagnostics.length = saveParseDiagnosticsLength; parseErrorBeforeNextFinishedNode = saveParseErrorBeforeNextFinishedNode; return comment; + var _a; } JSDocParser.parseJSDocComment = parseJSDocComment; var JSDocState; @@ -20490,8 +21696,14 @@ var ts; case "augments": tag = parseAugmentsTag(atToken, tagName); break; + case "class": + case "constructor": + tag = parseClassTag(atToken, tagName); + break; + case "arg": + case "argument": case "param": - tag = parseParamTag(atToken, tagName); + tag = parseParameterOrPropertyTag(atToken, tagName, /*shouldParseParamTag*/ true); break; case "return": case "returns": @@ -20605,29 +21817,25 @@ var ts; return parseJSDocTypeExpression(); }); } - function parseParamTag(atToken, tagName) { - var typeExpression = tryParseTypeExpression(); - skipWhitespace(); - var name; - var isBracketed; + function parseBracketNameInPropertyAndParamTag() { // Looking for something like '[foo]' or 'foo' - if (parseOptionalToken(21 /* OpenBracketToken */)) { - name = parseJSDocIdentifierName(); + var isBracketed = parseOptional(21 /* OpenBracketToken */); + var name = parseJSDocIdentifierName(/*createIfMissing*/ true); + if (isBracketed) { skipWhitespace(); - isBracketed = true; // May have an optional default, e.g. '[foo = 42]' if (parseOptionalToken(58 /* EqualsToken */)) { parseExpression(); } parseExpected(22 /* CloseBracketToken */); } - else if (ts.tokenIsIdentifierOrKeyword(token())) { - name = parseJSDocIdentifierName(); - } - if (!name) { - parseErrorAtPosition(scanner.getStartPos(), 0, ts.Diagnostics.Identifier_expected); - return undefined; - } + return { name: name, isBracketed: isBracketed }; + } + function parseParameterOrPropertyTag(atToken, tagName, shouldParseParamTag) { + var typeExpression = tryParseTypeExpression(); + skipWhitespace(); + var _a = parseBracketNameInPropertyAndParamTag(), name = _a.name, isBracketed = _a.isBracketed; + skipWhitespace(); var preName, postName; if (typeExpression) { postName = name; @@ -20638,52 +21846,38 @@ var ts; if (!typeExpression) { typeExpression = tryParseTypeExpression(); } - var result = createNode(286 /* JSDocParameterTag */, atToken.pos); + var result = shouldParseParamTag ? + createNode(287 /* JSDocParameterTag */, atToken.pos) : + createNode(292 /* JSDocPropertyTag */, atToken.pos); result.atToken = atToken; result.tagName = tagName; result.preParameterName = preName; result.typeExpression = typeExpression; result.postParameterName = postName; - result.parameterName = postName || preName; + result.name = postName || preName; result.isBracketed = isBracketed; return finishNode(result); } function parseReturnTag(atToken, tagName) { - if (ts.forEach(tags, function (t) { return t.kind === 287 /* JSDocReturnTag */; })) { + if (ts.forEach(tags, function (t) { return t.kind === 288 /* JSDocReturnTag */; })) { parseErrorAtPosition(tagName.pos, scanner.getTokenPos() - tagName.pos, ts.Diagnostics._0_tag_already_specified, tagName.text); } - var result = createNode(287 /* JSDocReturnTag */, atToken.pos); + var result = createNode(288 /* JSDocReturnTag */, atToken.pos); result.atToken = atToken; result.tagName = tagName; result.typeExpression = tryParseTypeExpression(); return finishNode(result); } function parseTypeTag(atToken, tagName) { - if (ts.forEach(tags, function (t) { return t.kind === 288 /* JSDocTypeTag */; })) { + if (ts.forEach(tags, function (t) { return t.kind === 289 /* JSDocTypeTag */; })) { parseErrorAtPosition(tagName.pos, scanner.getTokenPos() - tagName.pos, ts.Diagnostics._0_tag_already_specified, tagName.text); } - var result = createNode(288 /* JSDocTypeTag */, atToken.pos); + var result = createNode(289 /* JSDocTypeTag */, atToken.pos); result.atToken = atToken; result.tagName = tagName; result.typeExpression = tryParseTypeExpression(); return finishNode(result); } - function parsePropertyTag(atToken, tagName) { - var typeExpression = tryParseTypeExpression(); - skipWhitespace(); - var name = parseJSDocIdentifierName(); - skipWhitespace(); - if (!name) { - parseErrorAtPosition(scanner.getStartPos(), /*length*/ 0, ts.Diagnostics.Identifier_expected); - return undefined; - } - var result = createNode(291 /* JSDocPropertyTag */, atToken.pos); - result.atToken = atToken; - result.tagName = tagName; - result.name = name; - result.typeExpression = typeExpression; - return finishNode(result); - } function parseAugmentsTag(atToken, tagName) { var typeExpression = tryParseTypeExpression(); var result = createNode(285 /* JSDocAugmentsTag */, atToken.pos); @@ -20692,10 +21886,16 @@ var ts; result.typeExpression = typeExpression; return finishNode(result); } + function parseClassTag(atToken, tagName) { + var tag = createNode(286 /* JSDocClassTag */, atToken.pos); + tag.atToken = atToken; + tag.tagName = tagName; + return finishNode(tag); + } function parseTypedefTag(atToken, tagName) { var typeExpression = tryParseTypeExpression(); skipWhitespace(); - var typedefTag = createNode(290 /* JSDocTypedefTag */, atToken.pos); + var typedefTag = createNode(291 /* JSDocTypedefTag */, atToken.pos); typedefTag.atToken = atToken; typedefTag.tagName = tagName; typedefTag.fullName = parseJSDocTypeNameWithNamespace(/*flags*/ 0); @@ -20718,7 +21918,7 @@ var ts; var jsDocTypeReference = typeExpression.type; if (jsDocTypeReference.name.kind === 71 /* Identifier */) { var name = jsDocTypeReference.name; - if (name.text === "Object") { + if (name.text === "Object" || name.text === "object") { typedefTag.jsDocTypeLiteral = scanChildTags(); } } @@ -20732,7 +21932,7 @@ var ts; } return finishNode(typedefTag); function scanChildTags() { - var jsDocTypeLiteral = createNode(292 /* JSDocTypeLiteral */, scanner.getStartPos()); + var jsDocTypeLiteral = createNode(293 /* JSDocTypeLiteral */, scanner.getStartPos()); var resumePos = scanner.getStartPos(); var canParseTag = true; var seenAsterisk = false; @@ -20778,7 +21978,7 @@ var ts; jsDocNamespaceNode.flags |= flags; jsDocNamespaceNode.name = typeNameOrNamespaceName; jsDocNamespaceNode.body = parseJSDocTypeNameWithNamespace(4 /* NestedNamespace */); - return jsDocNamespaceNode; + return finishNode(jsDocNamespaceNode); } if (typeNameOrNamespaceName && flags & 4 /* NestedNamespace */) { typeNameOrNamespaceName.isInJSDocNamespace = true; @@ -20806,7 +22006,7 @@ var ts; return true; case "prop": case "property": - var propertyTag = parsePropertyTag(atToken, tagName); + var propertyTag = parseParameterOrPropertyTag(atToken, tagName, /*shouldParseParamTag*/ false); if (propertyTag) { if (!parentTag.jsDocPropertyTags) { parentTag.jsDocPropertyTags = []; @@ -20820,7 +22020,7 @@ var ts; return false; } function parseTemplateTag(atToken, tagName) { - if (ts.forEach(tags, function (t) { return t.kind === 289 /* JSDocTemplateTag */; })) { + if (ts.forEach(tags, function (t) { return t.kind === 290 /* JSDocTemplateTag */; })) { parseErrorAtPosition(tagName.pos, scanner.getTokenPos() - tagName.pos, ts.Diagnostics._0_tag_already_specified, tagName.text); } // Type parameter list looks like '@template T,U,V' @@ -20844,7 +22044,7 @@ var ts; break; } } - var result = createNode(289 /* JSDocTemplateTag */, atToken.pos); + var result = createNode(290 /* JSDocTemplateTag */, atToken.pos); result.atToken = atToken; result.tagName = tagName; result.typeParameters = typeParameters; @@ -20855,13 +22055,19 @@ var ts; function nextJSDocToken() { return currentToken = scanner.scanJSDocToken(); } - function parseJSDocIdentifierName() { - return createJSDocIdentifier(ts.tokenIsIdentifierOrKeyword(token())); + function parseJSDocIdentifierName(createIfMissing) { + if (createIfMissing === void 0) { createIfMissing = false; } + return createJSDocIdentifier(ts.tokenIsIdentifierOrKeyword(token()), createIfMissing); } - function createJSDocIdentifier(isIdentifier) { + function createJSDocIdentifier(isIdentifier, createIfMissing) { if (!isIdentifier) { - parseErrorAtCurrentToken(ts.Diagnostics.Identifier_expected); - return undefined; + if (createIfMissing) { + return createMissingNode(71 /* Identifier */, /*reportAtCurrentPosition*/ true, ts.Diagnostics.Identifier_expected); + } + else { + parseErrorAtCurrentToken(ts.Diagnostics.Identifier_expected); + return undefined; + } } var pos = scanner.getTokenPos(); var end = scanner.getTextPos(); @@ -21477,7 +22683,7 @@ var ts; inStrictMode = bindInStrictMode(file, opts); classifiableNames = ts.createMap(); symbolCount = 0; - skipTransformFlagAggregation = ts.isDeclarationFile(file); + skipTransformFlagAggregation = file.isDeclarationFile; Symbol = ts.objectAllocator.getSymbolConstructor(); if (!file.locals) { bind(file); @@ -21505,7 +22711,7 @@ var ts; } return bindSourceFile; function bindInStrictMode(file, opts) { - if ((opts.alwaysStrict === undefined ? opts.strict : opts.alwaysStrict) && !ts.isDeclarationFile(file)) { + if ((opts.alwaysStrict === undefined ? opts.strict : opts.alwaysStrict) && !file.isDeclarationFile) { // bind in strict mode source files with alwaysStrict option return true; } @@ -21574,18 +22780,9 @@ var ts; case 243 /* ExportAssignment */: return node.isExportEquals ? "export=" : "default"; case 194 /* BinaryExpression */: - switch (ts.getSpecialPropertyAssignmentKind(node)) { - case 2 /* ModuleExports */: - // module.exports = ... - return "export="; - case 1 /* ExportsProperty */: - case 4 /* ThisProperty */: - case 5 /* Property */: - // exports.x = ... or this.y = ... - return node.left.name.text; - case 3 /* PrototypeProperty */: - // className.prototype.methodName = ... - return node.left.expression.name.text; + if (ts.getSpecialPropertyAssignmentKind(node) === 2 /* ModuleExports */) { + // module.exports = ... + return "export="; } ts.Debug.fail("Unknown binary declaration kind"); break; @@ -21601,7 +22798,7 @@ var ts; var functionType = node.parent; var index = ts.indexOf(functionType.parameters, node); return "arg" + index; - case 290 /* JSDocTypedefTag */: + case 291 /* JSDocTypedefTag */: var parentNode = node.parent && node.parent.parent; var nameFromParentNode = void 0; if (parentNode && parentNode.kind === 208 /* VariableStatement */) { @@ -21737,7 +22934,9 @@ var ts; // during global merging in the checker. Why? The only case when ambient module is permitted inside another module is module augmentation // and this case is specially handled. Module augmentations should only be merged with original module definition // and should never be merged directly with other augmentation, and the latter case would be possible if automatic merge is allowed. - var isJSDocTypedefInJSDocNamespace = node.kind === 290 /* JSDocTypedefTag */ && + if (node.kind === 291 /* JSDocTypedefTag */) + ts.Debug.assert(ts.isInJavaScriptFile(node)); // We shouldn't add symbols for JSDoc nodes if not in a JS file. + var isJSDocTypedefInJSDocNamespace = node.kind === 291 /* JSDocTypedefTag */ && node.name && node.name.kind === 71 /* Identifier */ && node.name.isInJSDocNamespace; @@ -21895,8 +23094,19 @@ var ts; // Binding of JsDocComment should be done before the current block scope container changes. // because the scope of JsDocComment should not be affected by whether the current node is a // container or not. - if (ts.isInJavaScriptFile(node) && node.jsDoc) { - ts.forEach(node.jsDoc, bind); + if (node.jsDoc) { + if (ts.isInJavaScriptFile(node)) { + for (var _i = 0, _a = node.jsDoc; _i < _a.length; _i++) { + var j = _a[_i]; + bind(j); + } + } + else { + for (var _b = 0, _c = node.jsDoc; _b < _c.length; _b++) { + var j = _c[_b]; + setParentPointers(node, j); + } + } } if (checkUnreachable(node)) { bindEachChild(node); @@ -21966,7 +23176,7 @@ var ts; case 283 /* JSDocComment */: bindJSDocComment(node); break; - case 290 /* JSDocTypedefTag */: + case 291 /* JSDocTypedefTag */: bindJSDocTypedefTag(node); break; default: @@ -22582,13 +23792,13 @@ var ts; } function bindVariableDeclarationFlow(node) { bindEachChild(node); - if (node.initializer || node.parent.parent.kind === 215 /* ForInStatement */ || node.parent.parent.kind === 216 /* ForOfStatement */) { + if (node.initializer || ts.isForInOrOfStatement(node.parent.parent)) { bindInitializedVariableFlow(node); } } function bindJSDocComment(node) { ts.forEachChild(node, function (n) { - if (n.kind !== 290 /* JSDocTypedefTag */) { + if (n.kind !== 291 /* JSDocTypedefTag */) { bind(n); } }); @@ -22634,7 +23844,7 @@ var ts; case 232 /* EnumDeclaration */: case 178 /* ObjectLiteralExpression */: case 163 /* TypeLiteral */: - case 292 /* JSDocTypeLiteral */: + case 293 /* JSDocTypeLiteral */: case 275 /* JSDocRecordType */: case 254 /* JsxAttributes */: return 1 /* IsContainer */; @@ -22726,7 +23936,7 @@ var ts; case 178 /* ObjectLiteralExpression */: case 230 /* InterfaceDeclaration */: case 275 /* JSDocRecordType */: - case 292 /* JSDocTypeLiteral */: + case 293 /* JSDocTypeLiteral */: case 254 /* JsxAttributes */: // Interface/Object-types always have their children added to the 'members' of // their container. They are only accessible through an instance of their @@ -22753,7 +23963,7 @@ var ts; // All the children of these container types are never visible through another // symbol (i.e. through another symbol's 'exports' or 'members'). Instead, // they're only accessed 'lexically' (i.e. from code that exists underneath - // their container in the tree. To accomplish this, we simply add their declared + // their container in the tree). To accomplish this, we simply add their declared // symbol to the 'locals' of the container. These symbols can then be found as // the type checker walks up the containers, checking them for matching names. return declareSymbol(container.locals, /*parent*/ undefined, node, symbolFlags, symbolExcludes); @@ -23083,9 +24293,8 @@ var ts; // Here the current node is "foo", which is a container, but the scope of "MyType" should // not be inside "foo". Therefore we always bind @typedef before bind the parent node, // and skip binding this tag later when binding all the other jsdoc tags. - if (ts.isInJavaScriptFile(node)) { + if (ts.isInJavaScriptFile(node)) bindJSDocTypedefTagIfAny(node); - } // First we bind declaration nodes to a symbol if possible. We'll both create a symbol // and then potentially add the symbol to an appropriate symbol table. Possible // destination symbol tables are: @@ -23130,7 +24339,7 @@ var ts; } for (var _b = 0, _c = jsDoc.tags; _b < _c.length; _b++) { var tag = _c[_b]; - if (tag.kind === 290 /* JSDocTypedefTag */) { + if (tag.kind === 291 /* JSDocTypedefTag */) { var savedParent = parent; parent = jsDoc; bind(tag); @@ -23169,7 +24378,7 @@ var ts; // current "blockScopeContainer" needs to be set to its immediate namespace parent. if (node.isInJSDocNamespace) { var parentNode = node.parent; - while (parentNode && parentNode.kind !== 290 /* JSDocTypedefTag */) { + while (parentNode && parentNode.kind !== 291 /* JSDocTypedefTag */) { parentNode = parentNode.parent; } bindBlockScopedDeclaration(parentNode, 524288 /* TypeAlias */, 793064 /* TypeAliasExcludes */); @@ -23237,10 +24446,7 @@ var ts; return bindVariableDeclarationOrBindingElement(node); case 149 /* PropertyDeclaration */: case 148 /* PropertySignature */: - case 276 /* JSDocRecordMember */: - return bindPropertyOrMethodOrAccessor(node, 4 /* Property */ | (node.questionToken ? 67108864 /* Optional */ : 0 /* None */), 0 /* PropertyExcludes */); - case 291 /* JSDocPropertyTag */: - return bindJSDocProperty(node); + return bindPropertyWorker(node); case 261 /* PropertyAssignment */: case 262 /* ShorthandPropertyAssignment */: return bindPropertyOrMethodOrAccessor(node, 4 /* Property */, 0 /* PropertyExcludes */); @@ -23282,13 +24488,10 @@ var ts; return bindPropertyOrMethodOrAccessor(node, 65536 /* SetAccessor */, 74687 /* SetAccessorExcludes */); case 160 /* FunctionType */: case 161 /* ConstructorType */: - case 279 /* JSDocFunctionType */: return bindFunctionOrConstructorType(node); case 163 /* TypeLiteral */: case 172 /* MappedType */: - case 292 /* JSDocTypeLiteral */: - case 275 /* JSDocRecordType */: - return bindAnonymousDeclaration(node, 2048 /* TypeLiteral */, "__type"); + return bindAnonymousTypeWorker(node); case 178 /* ObjectLiteralExpression */: return bindObjectLiteralExpression(node); case 186 /* FunctionExpression */: @@ -23307,11 +24510,6 @@ var ts; return bindClassLikeDeclaration(node); case 230 /* InterfaceDeclaration */: return bindBlockScopedDeclaration(node, 64 /* Interface */, 792968 /* InterfaceExcludes */); - case 290 /* JSDocTypedefTag */: - if (!node.fullName || node.fullName.kind === 71 /* Identifier */) { - return bindBlockScopedDeclaration(node, 524288 /* TypeAlias */, 793064 /* TypeAliasExcludes */); - } - break; case 231 /* TypeAliasDeclaration */: return bindBlockScopedDeclaration(node, 524288 /* TypeAlias */, 793064 /* TypeAliasExcludes */); case 232 /* EnumDeclaration */: @@ -23347,8 +24545,31 @@ var ts; // falls through case 234 /* ModuleBlock */: return updateStrictModeStatementList(node.statements); + case 276 /* JSDocRecordMember */: + return bindPropertyWorker(node); + case 292 /* JSDocPropertyTag */: + return declareSymbolAndAddToSymbolTable(node, node.isBracketed || (node.typeExpression && node.typeExpression.type.kind === 278 /* JSDocOptionalType */) ? + 4 /* Property */ | 67108864 /* Optional */ : 4 /* Property */, 0 /* PropertyExcludes */); + case 279 /* JSDocFunctionType */: + return bindFunctionOrConstructorType(node); + case 293 /* JSDocTypeLiteral */: + case 275 /* JSDocRecordType */: + return bindAnonymousTypeWorker(node); + case 291 /* JSDocTypedefTag */: { + var fullName = node.fullName; + if (!fullName || fullName.kind === 71 /* Identifier */) { + return bindBlockScopedDeclaration(node, 524288 /* TypeAlias */, 793064 /* TypeAliasExcludes */); + } + break; + } } } + function bindPropertyWorker(node) { + return bindPropertyOrMethodOrAccessor(node, 4 /* Property */ | (node.questionToken ? 67108864 /* Optional */ : 0 /* None */), 0 /* PropertyExcludes */); + } + function bindAnonymousTypeWorker(node) { + return bindAnonymousDeclaration(node, 2048 /* TypeLiteral */, "__type"); + } function checkTypePredicate(node) { var parameterName = node.parameterName, type = node.type; if (parameterName && parameterName.kind === 71 /* Identifier */) { @@ -23459,7 +24680,7 @@ var ts; // A common practice in node modules is to set 'export = module.exports = {}', this ensures that 'exports' // is still pointing to 'module.exports'. // We do not want to consider this as 'export=' since a module can have only one of these. - // Similarlly we do not want to treat 'module.exports = exports' as an 'export='. + // Similarly we do not want to treat 'module.exports = exports' as an 'export='. var assignedExpression = ts.getRightMostAssignedExpression(node.right); if (ts.isEmptyObjectLiteral(assignedExpression) || isExportsOrModuleExportsOrAlias(assignedExpression)) { // Mark it as a module in case there are no other exports in the file @@ -23618,7 +24839,7 @@ var ts; } } function bindParameter(node) { - if (inStrictMode) { + if (inStrictMode && !ts.isInAmbientContext(node)) { // It is a SyntaxError if the identifier eval or arguments appears within a FormalParameterList of a // strict mode FunctionLikeDeclaration or FunctionExpression(13.1) checkStrictModeEvalOrArguments(node, node.name); @@ -23637,7 +24858,7 @@ var ts; } } function bindFunctionDeclaration(node) { - if (!ts.isDeclarationFile(file) && !ts.isInAmbientContext(node)) { + if (!file.isDeclarationFile && !ts.isInAmbientContext(node)) { if (ts.isAsyncFunction(node)) { emitFlags |= 1024 /* HasAsyncFunctions */; } @@ -23652,7 +24873,7 @@ var ts; } } function bindFunctionExpression(node) { - if (!ts.isDeclarationFile(file) && !ts.isInAmbientContext(node)) { + if (!file.isDeclarationFile && !ts.isInAmbientContext(node)) { if (ts.isAsyncFunction(node)) { emitFlags |= 1024 /* HasAsyncFunctions */; } @@ -23665,10 +24886,8 @@ var ts; return bindAnonymousDeclaration(node, 16 /* Function */, bindingName); } function bindPropertyOrMethodOrAccessor(node, symbolFlags, symbolExcludes) { - if (!ts.isDeclarationFile(file) && !ts.isInAmbientContext(node)) { - if (ts.isAsyncFunction(node)) { - emitFlags |= 1024 /* HasAsyncFunctions */; - } + if (!file.isDeclarationFile && !ts.isInAmbientContext(node) && ts.isAsyncFunction(node)) { + emitFlags |= 1024 /* HasAsyncFunctions */; } if (currentFlow && ts.isObjectLiteralOrClassExpressionMethod(node)) { node.flowNode = currentFlow; @@ -23677,9 +24896,6 @@ var ts; ? bindAnonymousDeclaration(node, symbolFlags, "__computed") : declareSymbolAndAddToSymbolTable(node, symbolFlags, symbolExcludes); } - function bindJSDocProperty(node) { - return declareSymbolAndAddToSymbolTable(node, 4 /* Property */, 0 /* PropertyExcludes */); - } // reachability checks function shouldReportErrorOnModuleDeclaration(node) { var instanceState = getModuleInstanceState(node); @@ -23801,6 +25017,9 @@ var ts; // node. transformFlags |= 192 /* AssertES2015 */; } + if (expression.kind === 91 /* ImportKeyword */) { + transformFlags |= 67108864 /* ContainsDynamicImport */; + } node.transformFlags = transformFlags | 536870912 /* HasComputedFlags */; return transformFlags & ~537396545 /* ArrayLiteralOrCallOrNewExcludes */; } @@ -24348,6 +25567,7 @@ var ts; case 171 /* IndexedAccessType */: case 172 /* MappedType */: case 173 /* LiteralType */: + case 236 /* NamespaceExportDeclaration */: // Types and signatures are TypeScript syntax, and exclude all other facts. transformFlags = 3 /* AssertTypeScript */; excludeFlags = -3 /* TypeExcludes */; @@ -24520,6 +25740,14 @@ var ts; } } ts.getTransformFlagsSubtreeExclusions = getTransformFlagsSubtreeExclusions; + /** + * "Binds" JSDoc nodes in TypeScript code. + * Since we will never create symbols for JSDoc, we just set parent pointers instead. + */ + function setParentPointers(parent, child) { + child.parent = parent; + ts.forEachChild(child, function (childsChild) { return setParentPointers(child, childsChild); }); + } })(ts || (ts = {})); /// /// @@ -24552,13 +25780,11 @@ var ts; ts.Debug.assert(ts.extensionIsTypeScript(resolved.extension)); return resolved.path; } - /** Adds `isExernalLibraryImport` to a Resolved to get a ResolvedModule. */ - function resolvedModuleFromResolved(_a, isExternalLibraryImport) { - var path = _a.path, extension = _a.extension; - return { resolvedFileName: path, extension: extension, isExternalLibraryImport: isExternalLibraryImport }; - } function createResolvedModuleWithFailedLookupLocations(resolved, isExternalLibraryImport, failedLookupLocations) { - return { resolvedModule: resolved && resolvedModuleFromResolved(resolved, isExternalLibraryImport), failedLookupLocations: failedLookupLocations }; + return { + resolvedModule: resolved && { resolvedFileName: resolved.path, extension: resolved.extension, isExternalLibraryImport: isExternalLibraryImport }, + failedLookupLocations: failedLookupLocations + }; } function moduleHasNonRelativeName(moduleName) { return !(ts.isRootedDiskPath(moduleName) || ts.isExternalModuleNameRelative(moduleName)); @@ -24886,6 +26112,8 @@ var ts; case ts.ModuleResolutionKind.Classic: result = classicNameResolver(moduleName, containingFile, compilerOptions, host, cache); break; + default: + ts.Debug.fail("Unexpected moduleResolution: " + moduleResolution); } if (perFolderCache) { perFolderCache.set(moduleName, result); @@ -25070,11 +26298,13 @@ var ts; if (state.traceEnabled) { trace(state.host, ts.Diagnostics.Trying_substitution_0_candidate_module_location_Colon_1, subst, path); } - // A path mapping may have a ".ts" extension; in contrast to an import, which should omit it. - var tsExtension = ts.tryGetExtensionFromPath(candidate); - if (tsExtension !== undefined) { + // A path mapping may have an extension, in contrast to an import, which should omit it. + var extension = ts.tryGetExtensionFromPath(candidate); + if (extension !== undefined) { var path_1 = tryFile(candidate, failedLookupLocations, /*onlyRecordFailures*/ false, state); - return path_1 && { path: path_1, extension: tsExtension }; + if (path_1 !== undefined) { + return { path: path_1, extension: extension }; + } } return loader(extensions, candidate, failedLookupLocations, !directoryProbablyExists(ts.getDirectoryPath(candidate), state.host), state); }); @@ -25088,13 +26318,24 @@ var ts; } } function nodeModuleNameResolver(moduleName, containingFile, compilerOptions, host, cache) { - return nodeModuleNameResolverWorker(moduleName, containingFile, compilerOptions, host, cache, /*jsOnly*/ false); + return nodeModuleNameResolverWorker(moduleName, ts.getDirectoryPath(containingFile), compilerOptions, host, cache, /*jsOnly*/ false); } ts.nodeModuleNameResolver = nodeModuleNameResolver; + /** + * Expose resolution logic to allow us to use Node module resolution logic from arbitrary locations. + * No way to do this with `require()`: https://github.com/nodejs/node/issues/5963 + * Throws an error if the module can't be resolved. + */ /* @internal */ - function nodeModuleNameResolverWorker(moduleName, containingFile, compilerOptions, host, cache, jsOnly) { - if (jsOnly === void 0) { jsOnly = false; } - var containingDirectory = ts.getDirectoryPath(containingFile); + function resolveJavaScriptModule(moduleName, initialDir, host) { + var _a = nodeModuleNameResolverWorker(moduleName, initialDir, { moduleResolution: ts.ModuleResolutionKind.NodeJs, allowJs: true }, host, /*cache*/ undefined, /*jsOnly*/ true), resolvedModule = _a.resolvedModule, failedLookupLocations = _a.failedLookupLocations; + if (!resolvedModule) { + throw new Error("Could not resolve JS module " + moduleName + " starting at " + initialDir + ". Looked in: " + failedLookupLocations.join(", ")); + } + return resolvedModule.resolvedFileName; + } + ts.resolveJavaScriptModule = resolveJavaScriptModule; + function nodeModuleNameResolverWorker(moduleName, containingDirectory, compilerOptions, host, cache, jsOnly) { var traceEnabled = isTraceEnabled(compilerOptions, host); var failedLookupLocations = []; var state = { compilerOptions: compilerOptions, host: host, traceEnabled: traceEnabled }; @@ -25125,7 +26366,6 @@ var ts; } } } - ts.nodeModuleNameResolverWorker = nodeModuleNameResolverWorker; function realpath(path, host, traceEnabled) { if (!host.realpath) { return path; @@ -25345,10 +26585,12 @@ var ts; return loadModuleFromNodeModulesFolder(Extensions.DtsOnly, mangleScopedPackage(moduleName, state), nodeModulesAtTypes_1, nodeModulesAtTypesExists, failedLookupLocations, state); } } + /** Double underscores are used in DefinitelyTyped to delimit scoped packages. */ + var mangledScopedPackageSeparator = "__"; /** For a scoped package, we must look in `@types/foo__bar` instead of `@types/@foo/bar`. */ function mangleScopedPackage(moduleName, state) { if (ts.startsWith(moduleName, "@")) { - var replaceSlash = moduleName.replace(ts.directorySeparator, "__"); + var replaceSlash = moduleName.replace(ts.directorySeparator, mangledScopedPackageSeparator); if (replaceSlash !== moduleName) { var mangled = replaceSlash.slice(1); // Take off the "@" if (state.traceEnabled) { @@ -25359,6 +26601,17 @@ var ts; } return moduleName; } + /* @internal */ + function getPackageNameFromAtTypesDirectory(mangledName) { + var withoutAtTypePrefix = ts.removePrefix(mangledName, "@types/"); + if (withoutAtTypePrefix !== mangledName) { + return withoutAtTypePrefix.indexOf("__") !== -1 ? + "@" + withoutAtTypePrefix.replace(mangledScopedPackageSeparator, ts.directorySeparator) : + withoutAtTypePrefix; + } + return mangledName; + } + ts.getPackageNameFromAtTypesDirectory = getPackageNameFromAtTypesDirectory; function tryFindNonRelativeModuleNameInCache(cache, moduleName, containingDirectory, traceEnabled, host) { var result = cache && cache.get(containingDirectory); if (result) { @@ -25488,6 +26741,7 @@ var ts; var Signature = ts.objectAllocator.getSignatureConstructor(); var typeCount = 0; var symbolCount = 0; + var enumCount = 0; var symbolInstantiationDepth = 0; var emptyArray = []; var emptySymbols = ts.createMap(); @@ -25639,13 +26893,21 @@ var ts; // since we are only interested in declarations of the module itself return tryFindAmbientModule(moduleName, /*withAugmentations*/ false); }, - getApparentType: getApparentType + getApparentType: getApparentType, + getAllPossiblePropertiesOfType: getAllPossiblePropertiesOfType, + getSuggestionForNonexistentProperty: getSuggestionForNonexistentProperty, + getSuggestionForNonexistentSymbol: getSuggestionForNonexistentSymbol, + getBaseConstraintOfType: getBaseConstraintOfType, + getJsxNamespace: getJsxNamespace, + resolveNameAtLocation: function (location, name, meaning) { + location = ts.getParseTreeNode(location); + return resolveName(location, name, meaning, /*nameNotFoundMessage*/ undefined, name); + }, }; var tupleTypes = []; var unionTypes = ts.createMap(); var intersectionTypes = ts.createMap(); - var stringLiteralTypes = ts.createMap(); - var numericLiteralTypes = ts.createMap(); + var literalTypes = ts.createMap(); var indexedAccessTypes = ts.createMap(); var evolvingArrayTypes = []; var unknownSymbol = createSymbol(4 /* Property */, "unknown"); @@ -25728,11 +26990,13 @@ var ts; var flowLoopStart = 0; var flowLoopCount = 0; var visitedFlowCount = 0; - var emptyStringType = getLiteralTypeForText(32 /* StringLiteral */, ""); - var zeroType = getLiteralTypeForText(64 /* NumberLiteral */, "0"); + var emptyStringType = getLiteralType(""); + var zeroType = getLiteralType(0); var resolutionTargets = []; var resolutionResults = []; var resolutionPropertyNames = []; + var suggestionCount = 0; + var maximumSuggestionCount = 10; var mergedSymbols = []; var symbolLinks = []; var nodeLinks = []; @@ -26089,9 +27353,6 @@ var ts; function getObjectFlags(type) { return type.flags & 32768 /* Object */ ? type.objectFlags : 0; } - function getCheckFlags(symbol) { - return symbol.flags & 134217728 /* Transient */ ? symbol.checkFlags : 0; - } function isGlobalSourceFile(node) { return node.kind === 265 /* SourceFile */ && !ts.isExternalOrCommonJsModule(node); } @@ -26099,7 +27360,7 @@ var ts; if (meaning) { var symbol = symbols.get(name); if (symbol) { - ts.Debug.assert((getCheckFlags(symbol) & 1 /* Instantiated */) === 0, "Should never get an instantiated symbol here."); + ts.Debug.assert((ts.getCheckFlags(symbol) & 1 /* Instantiated */) === 0, "Should never get an instantiated symbol here."); if (symbol.flags & meaning) { return symbol; } @@ -26136,6 +27397,7 @@ var ts; if (declarationFile !== useFile) { if ((modulekind && (declarationFile.externalModuleIndicator || useFile.externalModuleIndicator)) || (!compilerOptions.outFile && !compilerOptions.out) || + isInTypeQuery(usage) || ts.isInAmbientContext(declaration)) { // nodes are in different files and order cannot be determined return true; @@ -26192,15 +27454,8 @@ var ts; } break; } - switch (declaration.parent.parent.kind) { - case 215 /* ForInStatement */: - case 216 /* ForOfStatement */: - // ForIn/ForOf case - use site should not be used in expression part - if (isSameScopeDescendentOf(usage, declaration.parent.parent.expression, container)) { - return true; - } - } - return false; + // ForIn/ForOf case - use site should not be used in expression part + return ts.isForInOrOfStatement(declaration.parent.parent) && isSameScopeDescendentOf(usage, declaration.parent.parent.expression, container); } function isUsedInFunctionOrInstanceProperty(usage, declaration, container) { return !!ts.findAncestor(usage, function (current) { @@ -26232,7 +27487,11 @@ var ts; // Resolve a given name for a given meaning at a given location. An error is reported if the name was not found and // the nameNotFoundMessage argument is not undefined. Returns the resolved symbol, or undefined if no symbol with // the given name can be found. - function resolveName(location, name, meaning, nameNotFoundMessage, nameArg) { + function resolveName(location, name, meaning, nameNotFoundMessage, nameArg, suggestedNameNotFoundMessage) { + return resolveNameHelper(location, name, meaning, nameNotFoundMessage, nameArg, getSymbol, suggestedNameNotFoundMessage); + } + function resolveNameHelper(location, name, meaning, nameNotFoundMessage, nameArg, lookup, suggestedNameNotFoundMessage) { + var originalLocation = location; // needed for did-you-mean error reporting, which gathers candidates starting from the original location var result; var lastLocation; var propertyWithInvalidInitializer; @@ -26242,7 +27501,7 @@ var ts; loop: while (location) { // Locals of a source file are not in scope (because they get merged into the global symbol table) if (location.locals && !isGlobalSourceFile(location)) { - if (result = getSymbol(location.locals, name, meaning)) { + if (result = lookup(location.locals, name, meaning)) { var useResult = true; if (ts.isFunctionLike(location) && lastLocation && lastLocation !== location.body) { // symbol lookup restrictions for function-like declarations @@ -26313,12 +27572,12 @@ var ts; break; } } - if (result = getSymbol(moduleExports, name, meaning & 8914931 /* ModuleMember */)) { + if (result = lookup(moduleExports, name, meaning & 8914931 /* ModuleMember */)) { break loop; } break; case 232 /* EnumDeclaration */: - if (result = getSymbol(getSymbolOfNode(location).exports, name, meaning & 8 /* EnumMember */)) { + if (result = lookup(getSymbolOfNode(location).exports, name, meaning & 8 /* EnumMember */)) { break loop; } break; @@ -26333,7 +27592,7 @@ var ts; if (ts.isClassLike(location.parent) && !(ts.getModifierFlags(location) & 32 /* Static */)) { var ctor = findConstructorDeclaration(location.parent); if (ctor && ctor.locals) { - if (getSymbol(ctor.locals, name, meaning & 107455 /* Value */)) { + if (lookup(ctor.locals, name, meaning & 107455 /* Value */)) { // Remember the property node, it will be used later to report appropriate error propertyWithInvalidInitializer = location; } @@ -26343,7 +27602,7 @@ var ts; case 229 /* ClassDeclaration */: case 199 /* ClassExpression */: case 230 /* InterfaceDeclaration */: - if (result = getSymbol(getSymbolOfNode(location).members, name, meaning & 793064 /* Type */)) { + if (result = lookup(getSymbolOfNode(location).members, name, meaning & 793064 /* Type */)) { if (!isTypeParameterSymbolDeclaredInContainer(result, location)) { // ignore type parameters not declared in this container result = undefined; @@ -26378,7 +27637,7 @@ var ts; grandparent = location.parent.parent; if (ts.isClassLike(grandparent) || grandparent.kind === 230 /* InterfaceDeclaration */) { // A reference to this grandparent's type parameters would be an error - if (result = getSymbol(getSymbolOfNode(grandparent).members, name, meaning & 793064 /* Type */)) { + if (result = lookup(getSymbolOfNode(grandparent).members, name, meaning & 793064 /* Type */)) { error(errorLocation, ts.Diagnostics.A_computed_property_name_cannot_reference_a_type_parameter_from_its_containing_type); return undefined; } @@ -26439,7 +27698,7 @@ var ts; result.isReferenced = true; } if (!result) { - result = getSymbol(globals, name, meaning); + result = lookup(globals, name, meaning); } if (!result) { if (nameNotFoundMessage) { @@ -26449,7 +27708,17 @@ var ts; !checkAndReportErrorForUsingTypeAsNamespace(errorLocation, name, meaning) && !checkAndReportErrorForUsingTypeAsValue(errorLocation, name, meaning) && !checkAndReportErrorForUsingNamespaceModuleAsValue(errorLocation, name, meaning)) { - error(errorLocation, nameNotFoundMessage, typeof nameArg === "string" ? nameArg : ts.declarationNameToString(nameArg)); + var suggestion = void 0; + if (suggestedNameNotFoundMessage && suggestionCount < maximumSuggestionCount) { + suggestion = getSuggestionForNonexistentSymbol(originalLocation, name, meaning); + if (suggestion) { + error(errorLocation, suggestedNameNotFoundMessage, typeof nameArg === "string" ? nameArg : ts.declarationNameToString(nameArg), suggestion); + } + } + if (!suggestion) { + error(errorLocation, nameNotFoundMessage, typeof nameArg === "string" ? nameArg : ts.declarationNameToString(nameArg)); + } + suggestionCount++; } } return undefined; @@ -26463,7 +27732,7 @@ var ts; error(errorLocation, ts.Diagnostics.Initializer_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor, ts.declarationNameToString(propertyName), typeof nameArg === "string" ? nameArg : ts.declarationNameToString(nameArg)); return undefined; } - // Only check for block-scoped variable if we are looking for the + // Only check for block-scoped variable if we have an error location and are looking for the // name with variable meaning // For example, // declare module foo { @@ -26474,8 +27743,9 @@ var ts; // block-scoped variable and namespace module. However, only when we // try to resolve name in /*1*/ which is used in variable position, // we want to check for block-scoped - if (meaning & 2 /* BlockScopedVariable */ || - ((meaning & 32 /* Class */ || meaning & 384 /* Enum */) && (meaning & 107455 /* Value */) === 107455 /* Value */)) { + if (errorLocation && + (meaning & 2 /* BlockScopedVariable */ || + ((meaning & 32 /* Class */ || meaning & 384 /* Enum */) && (meaning & 107455 /* Value */) === 107455 /* Value */))) { var exportOrLocalSymbol = getExportSymbolOfValueSymbolIfExported(result); if (exportOrLocalSymbol.flags & 2 /* BlockScopedVariable */ || exportOrLocalSymbol.flags & 32 /* Class */ || exportOrLocalSymbol.flags & 384 /* Enum */) { checkResolvedBlockScopedVariable(exportOrLocalSymbol, errorLocation); @@ -26568,6 +27838,10 @@ var ts; } function checkAndReportErrorForUsingTypeAsValue(errorLocation, name, meaning) { if (meaning & (107455 /* Value */ & ~1024 /* NamespaceModule */)) { + if (name === "any" || name === "string" || name === "number" || name === "boolean" || name === "never") { + error(errorLocation, ts.Diagnostics._0_only_refers_to_a_type_but_is_being_used_as_a_value_here, name); + return true; + } var symbol = resolveSymbol(resolveName(errorLocation, name, 793064 /* Type */ & ~107455 /* Value */, /*nameNotFoundMessage*/ undefined, /*nameArg*/ undefined)); if (symbol && !(symbol.flags & 1024 /* NamespaceModule */)) { error(errorLocation, ts.Diagnostics._0_only_refers_to_a_type_but_is_being_used_as_a_value_here, name); @@ -26605,7 +27879,7 @@ var ts; else if (result.flags & 32 /* Class */) { error(errorLocation, ts.Diagnostics.Class_0_used_before_its_declaration, ts.declarationNameToString(ts.getNameOfDeclaration(declaration))); } - else if (result.flags & 384 /* Enum */) { + else if (result.flags & 256 /* RegularEnum */) { error(errorLocation, ts.Diagnostics.Enum_0_used_before_its_declaration, ts.declarationNameToString(ts.getNameOfDeclaration(declaration))); } } @@ -26622,7 +27896,7 @@ var ts; if (node.kind === 237 /* ImportEqualsDeclaration */) { return node; } - return ts.findAncestor(node, function (n) { return n.kind === 238 /* ImportDeclaration */; }); + return ts.findAncestor(node, ts.isImportDeclaration); } } function getDeclarationOfAliasSymbol(symbol) { @@ -26679,6 +27953,9 @@ var ts; // An 'import { Point } from "graphics"' needs to create a symbol that combines the value side 'Point' // property with the type/namespace side interface 'Point'. function combineValueAndTypeSymbols(valueSymbol, typeSymbol) { + if (valueSymbol === unknownSymbol && typeSymbol === unknownSymbol) { + return unknownSymbol; + } if (valueSymbol.flags & (793064 /* Type */ | 1920 /* Namespace */)) { return valueSymbol; } @@ -26746,10 +28023,10 @@ var ts; function getTargetOfNamespaceExportDeclaration(node, dontResolveAlias) { return resolveExternalModuleSymbol(node.parent.symbol, dontResolveAlias); } - function getTargetOfExportSpecifier(node, dontResolveAlias) { + function getTargetOfExportSpecifier(node, meaning, dontResolveAlias) { return node.parent.parent.moduleSpecifier ? getExternalModuleMember(node.parent.parent, node, dontResolveAlias) : - resolveEntityName(node.propertyName || node.name, 107455 /* Value */ | 793064 /* Type */ | 1920 /* Namespace */, /*ignoreErrors*/ false, dontResolveAlias); + resolveEntityName(node.propertyName || node.name, meaning, /*ignoreErrors*/ false, dontResolveAlias); } function getTargetOfExportAssignment(node, dontResolveAlias) { return resolveEntityName(node.expression, 107455 /* Value */ | 793064 /* Type */ | 1920 /* Namespace */, /*ignoreErrors*/ false, dontResolveAlias); @@ -26765,15 +28042,22 @@ var ts; case 242 /* ImportSpecifier */: return getTargetOfImportSpecifier(node, dontRecursivelyResolve); case 246 /* ExportSpecifier */: - return getTargetOfExportSpecifier(node, dontRecursivelyResolve); + return getTargetOfExportSpecifier(node, 107455 /* Value */ | 793064 /* Type */ | 1920 /* Namespace */, dontRecursivelyResolve); case 243 /* ExportAssignment */: return getTargetOfExportAssignment(node, dontRecursivelyResolve); case 236 /* NamespaceExportDeclaration */: return getTargetOfNamespaceExportDeclaration(node, dontRecursivelyResolve); } } + /** + * Indicates that a symbol is an alias that does not merge with a local declaration. + */ + function isNonLocalAlias(symbol, excludes) { + if (excludes === void 0) { excludes = 107455 /* Value */ | 793064 /* Type */ | 1920 /* Namespace */; } + return symbol && (symbol.flags & (8388608 /* Alias */ | excludes)) === 8388608 /* Alias */; + } function resolveSymbol(symbol, dontResolveAlias) { - var shouldResolve = !dontResolveAlias && symbol && symbol.flags & 8388608 /* Alias */ && !(symbol.flags & (107455 /* Value */ | 793064 /* Type */ | 1920 /* Namespace */)); + var shouldResolve = !dontResolveAlias && isNonLocalAlias(symbol); return shouldResolve ? resolveAlias(symbol) : symbol; } function resolveAlias(symbol) { @@ -26914,7 +28198,7 @@ var ts; else { ts.Debug.fail("Unknown entity name kind."); } - ts.Debug.assert((getCheckFlags(symbol) & 1 /* Instantiated */) === 0, "Should never get an instantiated symbol here."); + ts.Debug.assert((ts.getCheckFlags(symbol) & 1 /* Instantiated */) === 0, "Should never get an instantiated symbol here."); return (symbol.flags & meaning) || dontResolveAlias ? symbol : resolveAlias(symbol); } function resolveExternalModuleName(location, moduleReferenceExpression) { @@ -26936,6 +28220,11 @@ var ts; if (moduleName === undefined) { return; } + if (ts.startsWith(moduleReference, "@types/")) { + var diag = ts.Diagnostics.Cannot_import_type_declaration_files_Consider_importing_0_instead_of_1; + var withoutAtTypePrefix = ts.removePrefix(moduleReference, "@types/"); + error(errorNode, diag, withoutAtTypePrefix, moduleReference); + } var ambientModule = tryFindAmbientModule(moduleName, /*withAugmentations*/ true); if (ambientModule) { return ambientModule; @@ -26968,7 +28257,9 @@ var ts; error(errorNode, diag, moduleReference, resolvedModule.resolvedFileName); } else if (noImplicitAny && moduleNotFoundError) { - error(errorNode, ts.Diagnostics.Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type, moduleReference, resolvedModule.resolvedFileName); + var errorInfo = ts.chainDiagnosticMessages(/*details*/ undefined, ts.Diagnostics.Try_npm_install_types_Slash_0_if_it_exists_or_add_a_new_declaration_d_ts_file_containing_declare_module_0, moduleReference); + errorInfo = ts.chainDiagnosticMessages(errorInfo, ts.Diagnostics.Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type, moduleReference, resolvedModule.resolvedFileName); + diagnostics.add(ts.createDiagnosticForNodeFromMessageChain(errorNode, errorInfo)); } // Failed imports and untyped modules are both treated in an untyped manner; only difference is whether we give a diagnostic first. return undefined; @@ -27003,7 +28294,6 @@ var ts; var symbol = resolveExternalModuleSymbol(moduleSymbol, dontResolveAlias); if (!dontResolveAlias && symbol && !(symbol.flags & (1536 /* Module */ | 3 /* Variable */))) { error(moduleReferenceExpression, ts.Diagnostics.Module_0_resolves_to_a_non_module_entity_and_cannot_be_imported_using_this_construct, symbolToString(moduleSymbol)); - symbol = undefined; } return symbol; } @@ -27122,8 +28412,8 @@ var ts; } function findConstructorDeclaration(node) { var members = node.members; - for (var _i = 0, members_1 = members; _i < members_1.length; _i++) { - var member = members_1[_i]; + for (var _i = 0, members_2 = members; _i < members_2.length; _i++) { + var member = members_2[_i]; if (member.kind === 152 /* Constructor */ && ts.nodeIsPresent(member.body)) { return member; } @@ -27153,7 +28443,7 @@ var ts; return type; } function createTypeofType() { - return getUnionType(ts.convertToArray(typeofEQFacts.keys(), function (s) { return getLiteralTypeForText(32 /* StringLiteral */, s); })); + return getUnionType(ts.convertToArray(typeofEQFacts.keys(), getLiteralType)); } // A reserved member name starts with two underscores, but the third character cannot be an underscore // or the @ symbol. A third underscore indicates an escaped form of an identifer that started @@ -27264,7 +28554,7 @@ var ts; // Is this external alias, then use it to name ts.forEach(symbolFromSymbolTable.declarations, ts.isExternalModuleImportEqualsDeclaration)) { var resolvedImportedSymbol = resolveAlias(symbolFromSymbolTable); - if (isAccessible(symbolFromSymbolTable, resolveAlias(symbolFromSymbolTable))) { + if (isAccessible(symbolFromSymbolTable, resolvedImportedSymbol)) { return [symbolFromSymbolTable]; } // Look in the exported members, if we can find accessibleSymbolChain, symbol is accessible using this chain @@ -27483,34 +28773,59 @@ var ts; return result; } function typeToString(type, enclosingDeclaration, flags) { - var writer = ts.getSingleLineStringWriter(); - getSymbolDisplayBuilder().buildTypeDisplay(type, writer, enclosingDeclaration, flags); - var result = writer.string(); - ts.releaseStringWriter(writer); - var maxLength = compilerOptions.noErrorTruncation || flags & 4 /* NoTruncation */ ? undefined : 100; + var typeNode = nodeBuilder.typeToTypeNode(type, enclosingDeclaration, toNodeBuilderFlags(flags) | ts.NodeBuilderFlags.IgnoreErrors | ts.NodeBuilderFlags.WriteTypeParametersInQualifiedName); + ts.Debug.assert(typeNode !== undefined, "should always get typenode"); + var options = { removeComments: true }; + var writer = ts.createTextWriter(""); + var printer = ts.createPrinter(options); + var sourceFile = enclosingDeclaration && ts.getSourceFileOfNode(enclosingDeclaration); + printer.writeNode(3 /* Unspecified */, typeNode, /*sourceFile*/ sourceFile, writer); + var result = writer.getText(); + var maxLength = compilerOptions.noErrorTruncation || flags & 8 /* NoTruncation */ ? undefined : 100; if (maxLength && result.length >= maxLength) { - result = result.substr(0, maxLength - "...".length) + "..."; + return result.substr(0, maxLength - "...".length) + "..."; } return result; + function toNodeBuilderFlags(flags) { + var result = ts.NodeBuilderFlags.None; + if (!flags) { + return result; + } + if (flags & 8 /* NoTruncation */) { + result |= ts.NodeBuilderFlags.NoTruncation; + } + if (flags & 256 /* UseFullyQualifiedType */) { + result |= ts.NodeBuilderFlags.UseFullyQualifiedType; + } + if (flags & 4096 /* SuppressAnyReturnType */) { + result |= ts.NodeBuilderFlags.SuppressAnyReturnType; + } + if (flags & 1 /* WriteArrayAsGenericType */) { + result |= ts.NodeBuilderFlags.WriteArrayAsGenericType; + } + if (flags & 64 /* WriteTypeArgumentsOfSignature */) { + result |= ts.NodeBuilderFlags.WriteTypeArgumentsOfSignature; + } + return result; + } } function createNodeBuilder() { - var context; return { typeToTypeNode: function (type, enclosingDeclaration, flags) { - context = createNodeBuilderContext(enclosingDeclaration, flags); - var resultingNode = typeToTypeNodeHelper(type); + var context = createNodeBuilderContext(enclosingDeclaration, flags); + var resultingNode = typeToTypeNodeHelper(type, context); var result = context.encounteredError ? undefined : resultingNode; return result; }, indexInfoToIndexSignatureDeclaration: function (indexInfo, kind, enclosingDeclaration, flags) { - context = createNodeBuilderContext(enclosingDeclaration, flags); - var resultingNode = indexInfoToIndexSignatureDeclarationHelper(indexInfo, kind); + var context = createNodeBuilderContext(enclosingDeclaration, flags); + var resultingNode = indexInfoToIndexSignatureDeclarationHelper(indexInfo, kind, context); var result = context.encounteredError ? undefined : resultingNode; return result; }, signatureToSignatureDeclaration: function (signature, kind, enclosingDeclaration, flags) { - context = createNodeBuilderContext(enclosingDeclaration, flags); - var resultingNode = signatureToSignatureDeclarationHelper(signature, kind); + var context = createNodeBuilderContext(enclosingDeclaration, flags); + var resultingNode = signatureToSignatureDeclarationHelper(signature, kind, context); var result = context.encounteredError ? undefined : resultingNode; return result; } @@ -27520,15 +28835,14 @@ var ts; enclosingDeclaration: enclosingDeclaration, flags: flags, encounteredError: false, - inObjectTypeLiteral: false, - checkAlias: true, symbolStack: undefined }; } - function typeToTypeNodeHelper(type) { + function typeToTypeNodeHelper(type, context) { + var inTypeAlias = context.flags & ts.NodeBuilderFlags.InTypeAlias; + context.flags &= ~ts.NodeBuilderFlags.InTypeAlias; if (!type) { context.encounteredError = true; - // TODO(aozgaa): should we return implict any (undefined) or explicit any (keywordtypenode)? return undefined; } if (type.flags & 1 /* Any */) { @@ -27543,23 +28857,25 @@ var ts; if (type.flags & 8 /* Boolean */) { return ts.createKeywordTypeNode(122 /* BooleanKeyword */); } - if (type.flags & 16 /* Enum */) { - var name = symbolToName(type.symbol, /*expectsIdentifier*/ false); + if (type.flags & 256 /* EnumLiteral */ && !(type.flags & 65536 /* Union */)) { + var parentSymbol = getParentOfSymbol(type.symbol); + var parentName = symbolToName(parentSymbol, context, 793064 /* Type */, /*expectsIdentifier*/ false); + var enumLiteralName = getDeclaredTypeOfSymbol(parentSymbol) === type ? parentName : ts.createQualifiedName(parentName, getNameOfSymbol(type.symbol, context)); + return ts.createTypeReferenceNode(enumLiteralName, /*typeArguments*/ undefined); + } + if (type.flags & 272 /* EnumLike */) { + var name = symbolToName(type.symbol, context, 793064 /* Type */, /*expectsIdentifier*/ false); return ts.createTypeReferenceNode(name, /*typeArguments*/ undefined); } if (type.flags & (32 /* StringLiteral */)) { - return ts.createLiteralTypeNode((ts.createLiteral(type.text))); + return ts.createLiteralTypeNode(ts.setEmitFlags(ts.createLiteral(type.value), 16777216 /* NoAsciiEscaping */)); } if (type.flags & (64 /* NumberLiteral */)) { - return ts.createLiteralTypeNode((ts.createNumericLiteral(type.text))); + return ts.createLiteralTypeNode((ts.createLiteral(type.value))); } if (type.flags & 128 /* BooleanLiteral */) { return type.intrinsicName === "true" ? ts.createTrue() : ts.createFalse(); } - if (type.flags & 256 /* EnumLiteral */) { - var name = symbolToName(type.symbol, /*expectsIdentifier*/ false); - return ts.createTypeReferenceNode(name, /*typeArguments*/ undefined); - } if (type.flags & 1024 /* Void */) { return ts.createKeywordTypeNode(105 /* VoidKeyword */); } @@ -27579,8 +28895,8 @@ var ts; return ts.createKeywordTypeNode(134 /* ObjectKeyword */); } if (type.flags & 16384 /* TypeParameter */ && type.isThisType) { - if (context.inObjectTypeLiteral) { - if (!context.encounteredError && !(context.flags & ts.NodeBuilderFlags.allowThisInObjectLiteral)) { + if (context.flags & ts.NodeBuilderFlags.InObjectTypeLiteral) { + if (!context.encounteredError && !(context.flags & ts.NodeBuilderFlags.AllowThisInObjectLiteral)) { context.encounteredError = true; } } @@ -27591,39 +28907,31 @@ var ts; ts.Debug.assert(!!(type.flags & 32768 /* Object */)); return typeReferenceToTypeNode(type); } - if (objectFlags & 3 /* ClassOrInterface */) { - ts.Debug.assert(!!(type.flags & 32768 /* Object */)); - var name = symbolToName(type.symbol, /*expectsIdentifier*/ false); - // TODO(aozgaa): handle type arguments. - return ts.createTypeReferenceNode(name, /*typeArguments*/ undefined); - } - if (type.flags & 16384 /* TypeParameter */) { - var name = symbolToName(type.symbol, /*expectsIdentifier*/ false); + if (type.flags & 16384 /* TypeParameter */ || objectFlags & 3 /* ClassOrInterface */) { + var name = symbolToName(type.symbol, context, 793064 /* Type */, /*expectsIdentifier*/ false); // Ignore constraint/default when creating a usage (as opposed to declaration) of a type parameter. return ts.createTypeReferenceNode(name, /*typeArguments*/ undefined); } - if (context.checkAlias && type.aliasSymbol) { - var name = symbolToName(type.aliasSymbol, /*expectsIdentifier*/ false); - var typeArgumentNodes = type.aliasTypeArguments && mapToTypeNodeArray(type.aliasTypeArguments); + if (!inTypeAlias && type.aliasSymbol && + isSymbolAccessible(type.aliasSymbol, context.enclosingDeclaration, 793064 /* Type */, /*shouldComputeAliasesToMakeVisible*/ false).accessibility === 0 /* Accessible */) { + var name = symbolToTypeReferenceName(type.aliasSymbol); + var typeArgumentNodes = mapToTypeNodes(type.aliasTypeArguments, context); return ts.createTypeReferenceNode(name, typeArgumentNodes); } - context.checkAlias = false; - if (type.flags & 65536 /* Union */) { - var formattedUnionTypes = formatUnionTypes(type.types); - var unionTypeNodes = formattedUnionTypes && mapToTypeNodeArray(formattedUnionTypes); - if (unionTypeNodes && unionTypeNodes.length > 0) { - return ts.createUnionOrIntersectionTypeNode(166 /* UnionType */, unionTypeNodes); + if (type.flags & (65536 /* Union */ | 131072 /* Intersection */)) { + var types = type.flags & 65536 /* Union */ ? formatUnionTypes(type.types) : type.types; + var typeNodes = mapToTypeNodes(types, context); + if (typeNodes && typeNodes.length > 0) { + var unionOrIntersectionTypeNode = ts.createUnionOrIntersectionTypeNode(type.flags & 65536 /* Union */ ? 166 /* UnionType */ : 167 /* IntersectionType */, typeNodes); + return unionOrIntersectionTypeNode; } else { - if (!context.encounteredError && !(context.flags & ts.NodeBuilderFlags.allowEmptyUnionOrIntersection)) { + if (!context.encounteredError && !(context.flags & ts.NodeBuilderFlags.AllowEmptyUnionOrIntersection)) { context.encounteredError = true; } return undefined; } } - if (type.flags & 131072 /* Intersection */) { - return ts.createUnionOrIntersectionTypeNode(167 /* IntersectionType */, mapToTypeNodeArray(type.types)); - } if (objectFlags & (16 /* Anonymous */ | 32 /* Mapped */)) { ts.Debug.assert(!!(type.flags & 32768 /* Object */)); // The type is an object literal type. @@ -27631,35 +28939,23 @@ var ts; } if (type.flags & 262144 /* Index */) { var indexedType = type.type; - var indexTypeNode = typeToTypeNodeHelper(indexedType); + var indexTypeNode = typeToTypeNodeHelper(indexedType, context); return ts.createTypeOperatorNode(indexTypeNode); } if (type.flags & 524288 /* IndexedAccess */) { - var objectTypeNode = typeToTypeNodeHelper(type.objectType); - var indexTypeNode = typeToTypeNodeHelper(type.indexType); + var objectTypeNode = typeToTypeNodeHelper(type.objectType, context); + var indexTypeNode = typeToTypeNodeHelper(type.indexType, context); return ts.createIndexedAccessTypeNode(objectTypeNode, indexTypeNode); } ts.Debug.fail("Should be unreachable."); - function mapToTypeNodeArray(types) { - var result = []; - for (var _i = 0, types_1 = types; _i < types_1.length; _i++) { - var type_1 = types_1[_i]; - var typeNode = typeToTypeNodeHelper(type_1); - if (typeNode) { - result.push(typeNode); - } - } - return result; - } function createMappedTypeNodeFromType(type) { ts.Debug.assert(!!(type.flags & 32768 /* Object */)); - var typeParameter = getTypeParameterFromMappedType(type); - var typeParameterNode = typeParameterToDeclaration(typeParameter); - var templateType = getTemplateTypeFromMappedType(type); - var templateTypeNode = typeToTypeNodeHelper(templateType); var readonlyToken = type.declaration && type.declaration.readonlyToken ? ts.createToken(131 /* ReadonlyKeyword */) : undefined; var questionToken = type.declaration && type.declaration.questionToken ? ts.createToken(55 /* QuestionToken */) : undefined; - return ts.createMappedTypeNode(readonlyToken, typeParameterNode, questionToken, templateTypeNode); + var typeParameterNode = typeParameterToDeclaration(getTypeParameterFromMappedType(type), context); + var templateTypeNode = typeToTypeNodeHelper(getTemplateTypeFromMappedType(type), context); + var mappedTypeNode = ts.createMappedTypeNode(readonlyToken, typeParameterNode, questionToken, templateTypeNode); + return ts.setEmitFlags(mappedTypeNode, 1 /* SingleLine */); } function createAnonymousTypeNode(type) { var symbol = type.symbol; @@ -27668,14 +28964,14 @@ var ts; if (symbol.flags & 32 /* Class */ && !getBaseTypeVariableOfClass(symbol) || symbol.flags & (384 /* Enum */ | 512 /* ValueModule */) || shouldWriteTypeOfFunctionSymbol()) { - return createTypeQueryNodeFromSymbol(symbol); + return createTypeQueryNodeFromSymbol(symbol, 107455 /* Value */); } else if (ts.contains(context.symbolStack, symbol)) { // If type is an anonymous type literal in a type alias declaration, use type alias name var typeAlias = getTypeAliasForTypeLiteral(type); if (typeAlias) { // The specified symbol flags need to be reinterpreted as type flags - var entityName = symbolToName(typeAlias, /*expectsIdentifier*/ false); + var entityName = symbolToName(typeAlias, context, 793064 /* Type */, /*expectsIdentifier*/ false); return ts.createTypeReferenceNode(entityName, /*typeArguments*/ undefined); } else { @@ -27721,41 +29017,53 @@ var ts; var resolved = resolveStructuredTypeMembers(type); if (!resolved.properties.length && !resolved.stringIndexInfo && !resolved.numberIndexInfo) { if (!resolved.callSignatures.length && !resolved.constructSignatures.length) { - return ts.createTypeLiteralNode(/*members*/ undefined); + return ts.setEmitFlags(ts.createTypeLiteralNode(/*members*/ undefined), 1 /* SingleLine */); } if (resolved.callSignatures.length === 1 && !resolved.constructSignatures.length) { var signature = resolved.callSignatures[0]; - return signatureToSignatureDeclarationHelper(signature, 160 /* FunctionType */); + var signatureNode = signatureToSignatureDeclarationHelper(signature, 160 /* FunctionType */, context); + return signatureNode; } if (resolved.constructSignatures.length === 1 && !resolved.callSignatures.length) { var signature = resolved.constructSignatures[0]; - return signatureToSignatureDeclarationHelper(signature, 161 /* ConstructorType */); + var signatureNode = signatureToSignatureDeclarationHelper(signature, 161 /* ConstructorType */, context); + return signatureNode; } } - var saveInObjectTypeLiteral = context.inObjectTypeLiteral; - context.inObjectTypeLiteral = true; + var savedFlags = context.flags; + context.flags |= ts.NodeBuilderFlags.InObjectTypeLiteral; var members = createTypeNodesFromResolvedType(resolved); - context.inObjectTypeLiteral = saveInObjectTypeLiteral; - return ts.createTypeLiteralNode(members); + context.flags = savedFlags; + var typeLiteralNode = ts.createTypeLiteralNode(members); + return ts.setEmitFlags(typeLiteralNode, 1 /* SingleLine */); } - function createTypeQueryNodeFromSymbol(symbol) { - var entityName = symbolToName(symbol, /*expectsIdentifier*/ false); + function createTypeQueryNodeFromSymbol(symbol, symbolFlags) { + var entityName = symbolToName(symbol, context, symbolFlags, /*expectsIdentifier*/ false); return ts.createTypeQueryNode(entityName); } + function symbolToTypeReferenceName(symbol) { + // Unnamed function expressions and arrow functions have reserved names that we don't want to display + var entityName = symbol.flags & 32 /* Class */ || !isReservedMemberName(symbol.name) ? symbolToName(symbol, context, 793064 /* Type */, /*expectsIdentifier*/ false) : ts.createIdentifier(""); + return entityName; + } function typeReferenceToTypeNode(type) { var typeArguments = type.typeArguments || emptyArray; if (type.target === globalArrayType) { - var elementType = typeToTypeNodeHelper(typeArguments[0]); + if (context.flags & ts.NodeBuilderFlags.WriteArrayAsGenericType) { + var typeArgumentNode = typeToTypeNodeHelper(typeArguments[0], context); + return ts.createTypeReferenceNode("Array", [typeArgumentNode]); + } + var elementType = typeToTypeNodeHelper(typeArguments[0], context); return ts.createArrayTypeNode(elementType); } else if (type.target.objectFlags & 8 /* Tuple */) { if (typeArguments.length > 0) { - var tupleConstituentNodes = mapToTypeNodeArray(typeArguments.slice(0, getTypeReferenceArity(type))); + var tupleConstituentNodes = mapToTypeNodes(typeArguments.slice(0, getTypeReferenceArity(type)), context); if (tupleConstituentNodes && tupleConstituentNodes.length > 0) { return ts.createTupleTypeNode(tupleConstituentNodes); } } - if (!context.encounteredError && !(context.flags & ts.NodeBuilderFlags.allowEmptyTuple)) { + if (!context.encounteredError && !(context.flags & ts.NodeBuilderFlags.AllowEmptyTuple)) { context.encounteredError = true; } return undefined; @@ -27763,7 +29071,7 @@ var ts; else { var outerTypeParameters = type.target.outerTypeParameters; var i = 0; - var qualifiedName = undefined; + var qualifiedName = void 0; if (outerTypeParameters) { var length_1 = outerTypeParameters.length; while (i < length_1) { @@ -27776,48 +29084,72 @@ var ts; // When type parameters are their own type arguments for the whole group (i.e. we have // the default outer type arguments), we don't show the group. if (!ts.rangeEquals(outerTypeParameters, typeArguments, start, i)) { - var qualifiedNamePart = symbolToName(parent, /*expectsIdentifier*/ true); - if (!qualifiedName) { - qualifiedName = ts.createQualifiedName(qualifiedNamePart, /*right*/ undefined); - } - else { + var typeArgumentSlice = mapToTypeNodes(typeArguments.slice(start, i), context); + var typeArgumentNodes_1 = typeArgumentSlice && ts.createNodeArray(typeArgumentSlice); + var namePart = symbolToTypeReferenceName(parent); + (namePart.kind === 71 /* Identifier */ ? namePart : namePart.right).typeArguments = typeArgumentNodes_1; + if (qualifiedName) { ts.Debug.assert(!qualifiedName.right); - qualifiedName.right = qualifiedNamePart; + qualifiedName = addToQualifiedNameMissingRightIdentifier(qualifiedName, namePart); qualifiedName = ts.createQualifiedName(qualifiedName, /*right*/ undefined); } + else { + qualifiedName = ts.createQualifiedName(namePart, /*right*/ undefined); + } } } } var entityName = undefined; - var nameIdentifier = symbolToName(type.symbol, /*expectsIdentifier*/ true); + var nameIdentifier = symbolToTypeReferenceName(type.symbol); if (qualifiedName) { ts.Debug.assert(!qualifiedName.right); - qualifiedName.right = nameIdentifier; + qualifiedName = addToQualifiedNameMissingRightIdentifier(qualifiedName, nameIdentifier); entityName = qualifiedName; } else { entityName = nameIdentifier; } - var typeParameterCount = (type.target.typeParameters || emptyArray).length; - var typeArgumentNodes = ts.some(typeArguments) ? mapToTypeNodeArray(typeArguments.slice(i, typeParameterCount - i)) : undefined; + var typeArgumentNodes = void 0; + if (typeArguments.length > 0) { + var typeParameterCount = (type.target.typeParameters || emptyArray).length; + typeArgumentNodes = mapToTypeNodes(typeArguments.slice(i, typeParameterCount), context); + } + if (typeArgumentNodes) { + var lastIdentifier = entityName.kind === 71 /* Identifier */ ? entityName : entityName.right; + lastIdentifier.typeArguments = undefined; + } return ts.createTypeReferenceNode(entityName, typeArgumentNodes); } } + function addToQualifiedNameMissingRightIdentifier(left, right) { + ts.Debug.assert(left.right === undefined); + if (right.kind === 71 /* Identifier */) { + left.right = right; + return left; + } + var rightPart = right; + while (rightPart.left.kind !== 71 /* Identifier */) { + rightPart = rightPart.left; + } + left.right = rightPart.left; + rightPart.left = left; + return right; + } function createTypeNodesFromResolvedType(resolvedType) { var typeElements = []; for (var _i = 0, _a = resolvedType.callSignatures; _i < _a.length; _i++) { var signature = _a[_i]; - typeElements.push(signatureToSignatureDeclarationHelper(signature, 155 /* CallSignature */)); + typeElements.push(signatureToSignatureDeclarationHelper(signature, 155 /* CallSignature */, context)); } for (var _b = 0, _c = resolvedType.constructSignatures; _b < _c.length; _b++) { var signature = _c[_b]; - typeElements.push(signatureToSignatureDeclarationHelper(signature, 156 /* ConstructSignature */)); + typeElements.push(signatureToSignatureDeclarationHelper(signature, 156 /* ConstructSignature */, context)); } if (resolvedType.stringIndexInfo) { - typeElements.push(indexInfoToIndexSignatureDeclarationHelper(resolvedType.stringIndexInfo, 0 /* String */)); + typeElements.push(indexInfoToIndexSignatureDeclarationHelper(resolvedType.stringIndexInfo, 0 /* String */, context)); } if (resolvedType.numberIndexInfo) { - typeElements.push(indexInfoToIndexSignatureDeclarationHelper(resolvedType.numberIndexInfo, 1 /* Number */)); + typeElements.push(indexInfoToIndexSignatureDeclarationHelper(resolvedType.numberIndexInfo, 1 /* Number */, context)); } var properties = resolvedType.properties; if (!properties) { @@ -27826,86 +29158,141 @@ var ts; for (var _d = 0, properties_2 = properties; _d < properties_2.length; _d++) { var propertySymbol = properties_2[_d]; var propertyType = getTypeOfSymbol(propertySymbol); - var oldDeclaration = propertySymbol.declarations && propertySymbol.declarations[0]; - if (!oldDeclaration) { - return; - } - var propertyName = oldDeclaration.name; + var saveEnclosingDeclaration = context.enclosingDeclaration; + context.enclosingDeclaration = undefined; + var propertyName = symbolToName(propertySymbol, context, 107455 /* Value */, /*expectsIdentifier*/ true); + context.enclosingDeclaration = saveEnclosingDeclaration; var optionalToken = propertySymbol.flags & 67108864 /* Optional */ ? ts.createToken(55 /* QuestionToken */) : undefined; if (propertySymbol.flags & (16 /* Function */ | 8192 /* Method */) && !getPropertiesOfObjectType(propertyType).length) { var signatures = getSignaturesOfType(propertyType, 0 /* Call */); for (var _e = 0, signatures_1 = signatures; _e < signatures_1.length; _e++) { var signature = signatures_1[_e]; - var methodDeclaration = signatureToSignatureDeclarationHelper(signature, 150 /* MethodSignature */); + var methodDeclaration = signatureToSignatureDeclarationHelper(signature, 150 /* MethodSignature */, context); methodDeclaration.name = propertyName; methodDeclaration.questionToken = optionalToken; typeElements.push(methodDeclaration); } } else { - // TODO(aozgaa): should we create a node with explicit or implict any? - var propertyTypeNode = propertyType ? typeToTypeNodeHelper(propertyType) : ts.createKeywordTypeNode(119 /* AnyKeyword */); - typeElements.push(ts.createPropertySignature(propertyName, optionalToken, propertyTypeNode, - /*initializer*/ undefined)); + var propertyTypeNode = propertyType ? typeToTypeNodeHelper(propertyType, context) : ts.createKeywordTypeNode(119 /* AnyKeyword */); + var modifiers = isReadonlySymbol(propertySymbol) ? [ts.createToken(131 /* ReadonlyKeyword */)] : undefined; + var propertySignature = ts.createPropertySignature(modifiers, propertyName, optionalToken, propertyTypeNode, + /*initializer*/ undefined); + typeElements.push(propertySignature); } } return typeElements.length ? typeElements : undefined; } } - function indexInfoToIndexSignatureDeclarationHelper(indexInfo, kind) { + function mapToTypeNodes(types, context) { + if (ts.some(types)) { + var result = []; + for (var i = 0; i < types.length; ++i) { + var type = types[i]; + var typeNode = typeToTypeNodeHelper(type, context); + if (typeNode) { + result.push(typeNode); + } + } + return result; + } + } + function indexInfoToIndexSignatureDeclarationHelper(indexInfo, kind, context) { + var name = ts.getNameFromIndexInfo(indexInfo) || "x"; var indexerTypeNode = ts.createKeywordTypeNode(kind === 0 /* String */ ? 136 /* StringKeyword */ : 133 /* NumberKeyword */); - var name = ts.getNameFromIndexInfo(indexInfo); var indexingParameter = ts.createParameter( /*decorators*/ undefined, /*modifiers*/ undefined, /*dotDotDotToken*/ undefined, name, /*questionToken*/ undefined, indexerTypeNode, /*initializer*/ undefined); - var typeNode = typeToTypeNodeHelper(indexInfo.type); - return ts.createIndexSignatureDeclaration( + var typeNode = typeToTypeNodeHelper(indexInfo.type, context); + return ts.createIndexSignature( /*decorators*/ undefined, indexInfo.isReadonly ? [ts.createToken(131 /* ReadonlyKeyword */)] : undefined, [indexingParameter], typeNode); } - function signatureToSignatureDeclarationHelper(signature, kind) { - var typeParameters = signature.typeParameters && signature.typeParameters.map(function (parameter) { return typeParameterToDeclaration(parameter); }); - var parameters = signature.parameters.map(function (parameter) { return symbolToParameterDeclaration(parameter); }); + function signatureToSignatureDeclarationHelper(signature, kind, context) { + var typeParameters = signature.typeParameters && signature.typeParameters.map(function (parameter) { return typeParameterToDeclaration(parameter, context); }); + var parameters = signature.parameters.map(function (parameter) { return symbolToParameterDeclaration(parameter, context); }); + if (signature.thisParameter) { + var thisParameter = symbolToParameterDeclaration(signature.thisParameter, context); + parameters.unshift(thisParameter); + } var returnTypeNode; if (signature.typePredicate) { var typePredicate = signature.typePredicate; - var parameterName = typePredicate.kind === 1 /* Identifier */ ? ts.createIdentifier(typePredicate.parameterName) : ts.createThisTypeNode(); - var typeNode = typeToTypeNodeHelper(typePredicate.type); + var parameterName = typePredicate.kind === 1 /* Identifier */ ? + ts.setEmitFlags(ts.createIdentifier(typePredicate.parameterName), 16777216 /* NoAsciiEscaping */) : + ts.createThisTypeNode(); + var typeNode = typeToTypeNodeHelper(typePredicate.type, context); returnTypeNode = ts.createTypePredicateNode(parameterName, typeNode); } else { var returnType = getReturnTypeOfSignature(signature); - returnTypeNode = returnType && typeToTypeNodeHelper(returnType); + returnTypeNode = returnType && typeToTypeNodeHelper(returnType, context); + } + if (context.flags & ts.NodeBuilderFlags.SuppressAnyReturnType) { + if (returnTypeNode && returnTypeNode.kind === 119 /* AnyKeyword */) { + returnTypeNode = undefined; + } + } + else if (!returnTypeNode) { + returnTypeNode = ts.createKeywordTypeNode(119 /* AnyKeyword */); } - var returnTypeNodeExceptAny = returnTypeNode && returnTypeNode.kind !== 119 /* AnyKeyword */ ? returnTypeNode : undefined; - return ts.createSignatureDeclaration(kind, typeParameters, parameters, returnTypeNodeExceptAny); + return ts.createSignatureDeclaration(kind, typeParameters, parameters, returnTypeNode); } - function typeParameterToDeclaration(type) { + function typeParameterToDeclaration(type, context) { + var name = symbolToName(type.symbol, context, 793064 /* Type */, /*expectsIdentifier*/ true); var constraint = getConstraintFromTypeParameter(type); - var constraintNode = constraint && typeToTypeNodeHelper(constraint); + var constraintNode = constraint && typeToTypeNodeHelper(constraint, context); var defaultParameter = getDefaultFromTypeParameter(type); - var defaultParameterNode = defaultParameter && typeToTypeNodeHelper(defaultParameter); - var name = symbolToName(type.symbol, /*expectsIdentifier*/ true); + var defaultParameterNode = defaultParameter && typeToTypeNodeHelper(defaultParameter, context); return ts.createTypeParameterDeclaration(name, constraintNode, defaultParameterNode); } - function symbolToParameterDeclaration(parameterSymbol) { + function symbolToParameterDeclaration(parameterSymbol, context) { var parameterDeclaration = ts.getDeclarationOfKind(parameterSymbol, 146 /* Parameter */); + if (isTransientSymbol(parameterSymbol) && parameterSymbol.isRestParameter) { + // special-case synthetic rest parameters in JS files + return ts.createParameter( + /*decorators*/ undefined, + /*modifiers*/ undefined, parameterSymbol.isRestParameter ? ts.createToken(24 /* DotDotDotToken */) : undefined, "args", + /*questionToken*/ undefined, typeToTypeNodeHelper(anyArrayType, context), + /*initializer*/ undefined); + } + var modifiers = parameterDeclaration.modifiers && parameterDeclaration.modifiers.map(ts.getSynthesizedClone); + var dotDotDotToken = ts.isRestParameter(parameterDeclaration) ? ts.createToken(24 /* DotDotDotToken */) : undefined; + var name = parameterDeclaration.name ? + parameterDeclaration.name.kind === 71 /* Identifier */ ? + ts.setEmitFlags(ts.getSynthesizedClone(parameterDeclaration.name), 16777216 /* NoAsciiEscaping */) : + cloneBindingName(parameterDeclaration.name) : + parameterSymbol.name; + var questionToken = isOptionalParameter(parameterDeclaration) ? ts.createToken(55 /* QuestionToken */) : undefined; var parameterType = getTypeOfSymbol(parameterSymbol); - var parameterTypeNode = typeToTypeNodeHelper(parameterType); - // TODO(aozgaa): In the future, check initializer accessibility. - var parameterNode = ts.createParameter(parameterDeclaration.decorators, parameterDeclaration.modifiers, parameterDeclaration.dotDotDotToken && ts.createToken(24 /* DotDotDotToken */), - // Clone name to remove trivia. - ts.getSynthesizedClone(parameterDeclaration.name), parameterDeclaration.questionToken && ts.createToken(55 /* QuestionToken */), parameterTypeNode, parameterDeclaration.initializer); + if (isRequiredInitializedParameter(parameterDeclaration)) { + parameterType = getNullableType(parameterType, 2048 /* Undefined */); + } + var parameterTypeNode = typeToTypeNodeHelper(parameterType, context); + var parameterNode = ts.createParameter( + /*decorators*/ undefined, modifiers, dotDotDotToken, name, questionToken, parameterTypeNode, + /*initializer*/ undefined); return parameterNode; + function cloneBindingName(node) { + return elideInitializerAndSetEmitFlags(node); + function elideInitializerAndSetEmitFlags(node) { + var visited = ts.visitEachChild(node, elideInitializerAndSetEmitFlags, ts.nullTransformationContext, /*nodesVisitor*/ undefined, elideInitializerAndSetEmitFlags); + var clone = ts.nodeIsSynthesized(visited) ? visited : ts.getSynthesizedClone(visited); + if (clone.kind === 176 /* BindingElement */) { + clone.initializer = undefined; + } + return ts.setEmitFlags(clone, 1 /* SingleLine */ | 16777216 /* NoAsciiEscaping */); + } + } } - function symbolToName(symbol, expectsIdentifier) { + function symbolToName(symbol, context, meaning, expectsIdentifier) { // Try to get qualified name if the symbol is not a type parameter and there is an enclosing declaration. var chain; var isTypeParameter = symbol.flags & 262144 /* TypeParameter */; - if (!isTypeParameter && context.enclosingDeclaration) { - chain = getSymbolChain(symbol, 0 /* None */, /*endOfChain*/ true); + if (!isTypeParameter && (context.enclosingDeclaration || context.flags & ts.NodeBuilderFlags.UseFullyQualifiedType)) { + chain = getSymbolChain(symbol, meaning, /*endOfChain*/ true); ts.Debug.assert(chain && chain.length > 0); } else { @@ -27913,19 +29300,18 @@ var ts; } if (expectsIdentifier && chain.length !== 1 && !context.encounteredError - && !(context.flags & ts.NodeBuilderFlags.allowQualifedNameInPlaceOfIdentifier)) { + && !(context.flags & ts.NodeBuilderFlags.AllowQualifedNameInPlaceOfIdentifier)) { context.encounteredError = true; } return createEntityNameFromSymbolChain(chain, chain.length - 1); function createEntityNameFromSymbolChain(chain, index) { ts.Debug.assert(chain && 0 <= index && index < chain.length); - // const parentIndex = index - 1; var symbol = chain[index]; - var typeParameterString = ""; - if (index > 0) { + var typeParameterNodes; + if (context.flags & ts.NodeBuilderFlags.WriteTypeParametersInQualifiedName && index > 0) { var parentSymbol = chain[index - 1]; var typeParameters = void 0; - if (getCheckFlags(symbol) & 1 /* Instantiated */) { + if (ts.getCheckFlags(symbol) & 1 /* Instantiated */) { typeParameters = getTypeParametersOfClassOrInterface(parentSymbol); } else { @@ -27934,20 +29320,10 @@ var ts; typeParameters = getLocalTypeParametersOfClassOrInterfaceOrTypeAlias(symbol); } } - if (typeParameters && typeParameters.length > 0) { - if (!context.encounteredError && !(context.flags & ts.NodeBuilderFlags.allowTypeParameterInQualifiedName)) { - context.encounteredError = true; - } - var writer = ts.getSingleLineStringWriter(); - var displayBuilder = getSymbolDisplayBuilder(); - displayBuilder.buildDisplayForTypeParametersAndDelimiters(typeParameters, writer, context.enclosingDeclaration, 0); - typeParameterString = writer.string(); - ts.releaseStringWriter(writer); - } + typeParameterNodes = mapToTypeNodes(typeParameters, context); } - var symbolName = getNameOfSymbol(symbol); - var symbolNameWithTypeParameters = typeParameterString.length > 0 ? symbolName + "<" + typeParameterString + ">" : symbolName; - var identifier = ts.createIdentifier(symbolNameWithTypeParameters); + var symbolName = getNameOfSymbol(symbol, context); + var identifier = ts.setEmitFlags(ts.createIdentifier(symbolName, typeParameterNodes), 16777216 /* NoAsciiEscaping */); return index > 0 ? ts.createQualifiedName(createEntityNameFromSymbolChain(chain, index - 1), identifier) : identifier; } /** @param endOfChain Set to false for recursive calls; non-recursive calls should always output something. */ @@ -27979,29 +29355,29 @@ var ts; return [symbol]; } } - function getNameOfSymbol(symbol) { - var declaration = ts.firstOrUndefined(symbol.declarations); - if (declaration) { - var name = ts.getNameOfDeclaration(declaration); - if (name) { - return ts.declarationNameToString(name); - } - if (declaration.parent && declaration.parent.kind === 226 /* VariableDeclaration */) { - return ts.declarationNameToString(declaration.parent.name); - } - if (!context.encounteredError && !(context.flags & ts.NodeBuilderFlags.allowAnonymousIdentifier)) { - context.encounteredError = true; - } - switch (declaration.kind) { - case 199 /* ClassExpression */: - return "(Anonymous class)"; - case 186 /* FunctionExpression */: - case 187 /* ArrowFunction */: - return "(Anonymous function)"; - } + } + function getNameOfSymbol(symbol, context) { + var declaration = ts.firstOrUndefined(symbol.declarations); + if (declaration) { + var name = ts.getNameOfDeclaration(declaration); + if (name) { + return ts.declarationNameToString(name); + } + if (declaration.parent && declaration.parent.kind === 226 /* VariableDeclaration */) { + return ts.declarationNameToString(declaration.parent.name); + } + if (!context.encounteredError && !(context.flags & ts.NodeBuilderFlags.AllowAnonymousIdentifier)) { + context.encounteredError = true; + } + switch (declaration.kind) { + case 199 /* ClassExpression */: + return "(Anonymous class)"; + case 186 /* FunctionExpression */: + case 187 /* ArrowFunction */: + return "(Anonymous function)"; } - return symbol.name; } + return symbol.name; } } function typePredicateToString(typePredicate, enclosingDeclaration, flags) { @@ -28019,12 +29395,14 @@ var ts; flags |= t.flags; if (!(t.flags & 6144 /* Nullable */)) { if (t.flags & (128 /* BooleanLiteral */ | 256 /* EnumLiteral */)) { - var baseType = t.flags & 128 /* BooleanLiteral */ ? booleanType : t.baseType; - var count = baseType.types.length; - if (i + count <= types.length && types[i + count - 1] === baseType.types[count - 1]) { - result.push(baseType); - i += count - 1; - continue; + var baseType = t.flags & 128 /* BooleanLiteral */ ? booleanType : getBaseTypeOfEnumLiteralType(t); + if (baseType.flags & 65536 /* Union */) { + var count = baseType.types.length; + if (i + count <= types.length && types[i + count - 1] === baseType.types[count - 1]) { + result.push(baseType); + i += count - 1; + continue; + } } } result.push(t); @@ -28060,7 +29438,7 @@ var ts; ts.isExternalModuleAugmentation(node.parent.parent); } function literalTypeToString(type) { - return type.flags & 32 /* StringLiteral */ ? "\"" + ts.escapeString(type.text) + "\"" : type.text; + return type.flags & 32 /* StringLiteral */ ? "\"" + ts.escapeString(type.value) + "\"" : "" + type.value; } function getNameOfSymbol(symbol) { if (symbol.declarations && symbol.declarations.length) { @@ -28124,8 +29502,9 @@ var ts; if (parentSymbol) { // Write type arguments of instantiated class/interface here if (flags & 1 /* WriteTypeParametersOrArguments */) { - if (getCheckFlags(symbol) & 1 /* Instantiated */) { - buildDisplayForTypeArgumentsAndDelimiters(getTypeParametersOfClassOrInterface(parentSymbol), symbol.mapper, writer, enclosingDeclaration); + if (ts.getCheckFlags(symbol) & 1 /* Instantiated */) { + var params = getTypeParametersOfClassOrInterface(parentSymbol.flags & 8388608 /* Alias */ ? resolveAlias(parentSymbol) : parentSymbol); + buildDisplayForTypeArgumentsAndDelimiters(params, symbol.mapper, writer, enclosingDeclaration); } else { buildTypeParameterDisplayFromSymbol(parentSymbol, writer, enclosingDeclaration); @@ -28177,7 +29556,7 @@ var ts; // and there is an enclosing declaration or we specifically // asked for it var isTypeParameter = symbol.flags & 262144 /* TypeParameter */; - var typeFormatFlag = 128 /* UseFullyQualifiedType */ & typeFlags; + var typeFormatFlag = 256 /* UseFullyQualifiedType */ & typeFlags; if (!isTypeParameter && (enclosingDeclaration || typeFormatFlag)) { walkSymbol(symbol, meaning, /*endOfChain*/ true); } @@ -28186,15 +29565,15 @@ var ts; } } function buildTypeDisplay(type, writer, enclosingDeclaration, globalFlags, symbolStack) { - var globalFlagsToPass = globalFlags & 16 /* WriteOwnNameForAnyLike */; + var globalFlagsToPass = globalFlags & (32 /* WriteOwnNameForAnyLike */ | 16384 /* WriteClassExpressionAsTypeLiteral */); var inObjectTypeLiteral = false; return writeType(type, globalFlags); function writeType(type, flags) { - var nextFlags = flags & ~512 /* InTypeAlias */; + var nextFlags = flags & ~1024 /* InTypeAlias */; // Write undefined/null type as any if (type.flags & 16793231 /* Intrinsic */) { // Special handling for unknown / resolving types, they should show up as any and not unknown or __resolving - writer.writeKeyword(!(globalFlags & 16 /* WriteOwnNameForAnyLike */) && isTypeAny(type) + writer.writeKeyword(!(globalFlags & 32 /* WriteOwnNameForAnyLike */) && isTypeAny(type) ? "any" : type.intrinsicName); } @@ -28207,16 +29586,21 @@ var ts; else if (getObjectFlags(type) & 4 /* Reference */) { writeTypeReference(type, nextFlags); } - else if (type.flags & 256 /* EnumLiteral */) { - buildSymbolDisplay(getParentOfSymbol(type.symbol), writer, enclosingDeclaration, 793064 /* Type */, 0 /* None */, nextFlags); - writePunctuation(writer, 23 /* DotToken */); - appendSymbolNameOnly(type.symbol, writer); + else if (type.flags & 256 /* EnumLiteral */ && !(type.flags & 65536 /* Union */)) { + var parent = getParentOfSymbol(type.symbol); + buildSymbolDisplay(parent, writer, enclosingDeclaration, 793064 /* Type */, 0 /* None */, nextFlags); + // In a literal enum type with a single member E { A }, E and E.A denote the + // same type. We always display this type simply as E. + if (getDeclaredTypeOfSymbol(parent) !== type) { + writePunctuation(writer, 23 /* DotToken */); + appendSymbolNameOnly(type.symbol, writer); + } } - else if (getObjectFlags(type) & 3 /* ClassOrInterface */ || type.flags & (16 /* Enum */ | 16384 /* TypeParameter */)) { + else if (getObjectFlags(type) & 3 /* ClassOrInterface */ || type.flags & (272 /* EnumLike */ | 16384 /* TypeParameter */)) { // The specified symbol flags need to be reinterpreted as type flags buildSymbolDisplay(type.symbol, writer, enclosingDeclaration, 793064 /* Type */, 0 /* None */, nextFlags); } - else if (!(flags & 512 /* InTypeAlias */) && type.aliasSymbol && + else if (!(flags & 1024 /* InTypeAlias */) && type.aliasSymbol && isSymbolAccessible(type.aliasSymbol, enclosingDeclaration, 793064 /* Type */, /*shouldComputeAliasesToMakeVisible*/ false).accessibility === 0 /* Accessible */) { var typeArguments = type.aliasTypeArguments; writeSymbolTypeReference(type.aliasSymbol, typeArguments, 0, ts.length(typeArguments), nextFlags); @@ -28231,12 +29615,18 @@ var ts; writer.writeStringLiteral(literalTypeToString(type)); } else if (type.flags & 262144 /* Index */) { + if (flags & 128 /* InElementType */) { + writePunctuation(writer, 19 /* OpenParenToken */); + } writer.writeKeyword("keyof"); writeSpace(writer); - writeType(type.type, 64 /* InElementType */); + writeType(type.type, 128 /* InElementType */); + if (flags & 128 /* InElementType */) { + writePunctuation(writer, 20 /* CloseParenToken */); + } } else if (type.flags & 524288 /* IndexedAccess */) { - writeType(type.objectType, 64 /* InElementType */); + writeType(type.objectType, 128 /* InElementType */); writePunctuation(writer, 21 /* OpenBracketToken */); writeType(type.indexType, 0 /* None */); writePunctuation(writer, 22 /* CloseBracketToken */); @@ -28260,7 +29650,7 @@ var ts; writePunctuation(writer, delimiter); writeSpace(writer); } - writeType(types[i], delimiter === 26 /* CommaToken */ ? 0 /* None */ : 64 /* InElementType */); + writeType(types[i], delimiter === 26 /* CommaToken */ ? 0 /* None */ : 128 /* InElementType */); } } function writeSymbolTypeReference(symbol, typeArguments, pos, end, flags) { @@ -28270,7 +29660,7 @@ var ts; } if (pos < end) { writePunctuation(writer, 27 /* LessThanToken */); - writeType(typeArguments[pos], 256 /* InFirstTypeArgument */); + writeType(typeArguments[pos], 512 /* InFirstTypeArgument */); pos++; while (pos < end) { writePunctuation(writer, 26 /* CommaToken */); @@ -28284,7 +29674,7 @@ var ts; function writeTypeReference(type, flags) { var typeArguments = type.typeArguments || emptyArray; if (type.target === globalArrayType && !(flags & 1 /* WriteArrayAsGenericType */)) { - writeType(typeArguments[0], 64 /* InElementType */); + writeType(typeArguments[0], 128 /* InElementType */); writePunctuation(writer, 21 /* OpenBracketToken */); writePunctuation(writer, 22 /* CloseBracketToken */); } @@ -28293,6 +29683,11 @@ var ts; writeTypeList(type.typeArguments.slice(0, getTypeReferenceArity(type)), 26 /* CommaToken */); writePunctuation(writer, 22 /* CloseBracketToken */); } + else if (flags & 16384 /* WriteClassExpressionAsTypeLiteral */ && + type.symbol.valueDeclaration && + type.symbol.valueDeclaration.kind === 199 /* ClassExpression */) { + writeAnonymousType(getDeclaredTypeOfClassOrInterface(type.symbol), flags); + } else { // Write the type reference in the format f.g.C where A and B are type arguments // for outer type parameters, and f and g are the respective declaring containers of those @@ -28321,7 +29716,7 @@ var ts; } } function writeUnionOrIntersectionType(type, flags) { - if (flags & 64 /* InElementType */) { + if (flags & 128 /* InElementType */) { writePunctuation(writer, 19 /* OpenParenToken */); } if (type.flags & 65536 /* Union */) { @@ -28330,7 +29725,7 @@ var ts; else { writeTypeList(type.types, 48 /* AmpersandToken */); } - if (flags & 64 /* InElementType */) { + if (flags & 128 /* InElementType */) { writePunctuation(writer, 20 /* CloseParenToken */); } } @@ -28338,7 +29733,9 @@ var ts; var symbol = type.symbol; if (symbol) { // Always use 'typeof T' for type of class, enum, and module objects - if (symbol.flags & 32 /* Class */ && !getBaseTypeVariableOfClass(symbol) || + if (symbol.flags & 32 /* Class */ && + !getBaseTypeVariableOfClass(symbol) && + !(symbol.valueDeclaration.kind === 199 /* ClassExpression */ && flags & 16384 /* WriteClassExpressionAsTypeLiteral */) || symbol.flags & (384 /* Enum */ | 512 /* ValueModule */)) { writeTypeOfSymbol(type, flags); } @@ -28360,12 +29757,23 @@ var ts; else { // Since instantiations of the same anonymous type have the same symbol, tracking symbols instead // of types allows us to catch circular references to instantiations of the same anonymous type + // However, in case of class expressions, we want to write both the static side and the instance side. + // We skip adding the static side so that the instance side has a chance to be written + // before checking for circular references. if (!symbolStack) { symbolStack = []; } - symbolStack.push(symbol); - writeLiteralType(type, flags); - symbolStack.pop(); + var isConstructorObject = type.flags & 32768 /* Object */ && + getObjectFlags(type) & 16 /* Anonymous */ && + type.symbol && type.symbol.flags & 32 /* Class */; + if (isConstructorObject) { + writeLiteralType(type, flags); + } + else { + symbolStack.push(symbol); + writeLiteralType(type, flags); + symbolStack.pop(); + } } } else { @@ -28382,7 +29790,7 @@ var ts; })); if (isStaticMethodSymbol || isNonLocalFunctionSymbol) { // typeof is allowed only for static/non local functions - return !!(flags & 2 /* UseTypeOfFunction */) || + return !!(flags & 4 /* UseTypeOfFunction */) || (ts.contains(symbolStack, symbol)); // it is type of the symbol uses itself recursively } } @@ -28403,12 +29811,12 @@ var ts; } } function shouldAddParenthesisAroundFunctionType(callSignature, flags) { - if (flags & 64 /* InElementType */) { + if (flags & 128 /* InElementType */) { return true; } - else if (flags & 256 /* InFirstTypeArgument */) { + else if (flags & 512 /* InFirstTypeArgument */) { // Add parenthesis around function type for the first type argument to avoid ambiguity - var typeParameters = callSignature.target && (flags & 32 /* WriteTypeArgumentsOfSignature */) ? + var typeParameters = callSignature.target && (flags & 64 /* WriteTypeArgumentsOfSignature */) ? callSignature.target.typeParameters : callSignature.typeParameters; return typeParameters && typeParameters.length !== 0; } @@ -28433,20 +29841,20 @@ var ts; if (parenthesizeSignature) { writePunctuation(writer, 19 /* OpenParenToken */); } - buildSignatureDisplay(resolved.callSignatures[0], writer, enclosingDeclaration, globalFlagsToPass | 8 /* WriteArrowStyleSignature */, /*kind*/ undefined, symbolStack); + buildSignatureDisplay(resolved.callSignatures[0], writer, enclosingDeclaration, globalFlagsToPass | 16 /* WriteArrowStyleSignature */, /*kind*/ undefined, symbolStack); if (parenthesizeSignature) { writePunctuation(writer, 20 /* CloseParenToken */); } return; } if (resolved.constructSignatures.length === 1 && !resolved.callSignatures.length) { - if (flags & 64 /* InElementType */) { + if (flags & 128 /* InElementType */) { writePunctuation(writer, 19 /* OpenParenToken */); } writeKeyword(writer, 94 /* NewKeyword */); writeSpace(writer); - buildSignatureDisplay(resolved.constructSignatures[0], writer, enclosingDeclaration, globalFlagsToPass | 8 /* WriteArrowStyleSignature */, /*kind*/ undefined, symbolStack); - if (flags & 64 /* InElementType */) { + buildSignatureDisplay(resolved.constructSignatures[0], writer, enclosingDeclaration, globalFlagsToPass | 16 /* WriteArrowStyleSignature */, /*kind*/ undefined, symbolStack); + if (flags & 128 /* InElementType */) { writePunctuation(writer, 20 /* CloseParenToken */); } return; @@ -28479,6 +29887,14 @@ var ts; buildIndexSignatureDisplay(resolved.numberIndexInfo, writer, 1 /* Number */, enclosingDeclaration, globalFlags, symbolStack); for (var _d = 0, _e = resolved.properties; _d < _e.length; _d++) { var p = _e[_d]; + if (globalFlags & 16384 /* WriteClassExpressionAsTypeLiteral */) { + if (p.flags & 16777216 /* Prototype */) { + continue; + } + if (ts.getDeclarationModifierFlagsFromSymbol(p) & (8 /* Private */ | 16 /* Protected */)) { + writer.reportPrivateInBaseOfClassExpression(p.name); + } + } var t = getTypeOfSymbol(p); if (p.flags & (16 /* Function */ | 8192 /* Method */) && !getPropertiesOfObjectType(t).length) { var signatures = getSignaturesOfType(t, 0 /* Call */); @@ -28494,7 +29910,7 @@ var ts; writePropertyWithModifiers(p); writePunctuation(writer, 56 /* ColonToken */); writeSpace(writer); - writeType(t, 0 /* None */); + writeType(t, globalFlags & 16384 /* WriteClassExpressionAsTypeLiteral */); writePunctuation(writer, 25 /* SemicolonToken */); writer.writeLine(); } @@ -28568,7 +29984,7 @@ var ts; writeSpace(writer); var type = getTypeOfSymbol(p); if (parameterNode && isRequiredInitializedParameter(parameterNode)) { - type = includeFalsyTypes(type, 2048 /* Undefined */); + type = getNullableType(type, 2048 /* Undefined */); } buildTypeDisplay(type, writer, enclosingDeclaration, flags, symbolStack); } @@ -28628,7 +30044,7 @@ var ts; function buildDisplayForTypeArgumentsAndDelimiters(typeParameters, mapper, writer, enclosingDeclaration) { if (typeParameters && typeParameters.length) { writePunctuation(writer, 27 /* LessThanToken */); - var flags = 256 /* InFirstTypeArgument */; + var flags = 512 /* InFirstTypeArgument */; for (var i = 0; i < typeParameters.length; i++) { if (i > 0) { writePunctuation(writer, 26 /* CommaToken */); @@ -28668,10 +30084,10 @@ var ts; } function buildReturnTypeDisplay(signature, writer, enclosingDeclaration, flags, symbolStack) { var returnType = getReturnTypeOfSignature(signature); - if (flags & 2048 /* SuppressAnyReturnType */ && isTypeAny(returnType)) { + if (flags & 4096 /* SuppressAnyReturnType */ && isTypeAny(returnType)) { return; } - if (flags & 8 /* WriteArrowStyleSignature */) { + if (flags & 16 /* WriteArrowStyleSignature */) { writeSpace(writer); writePunctuation(writer, 36 /* EqualsGreaterThanToken */); } @@ -28691,7 +30107,7 @@ var ts; writeKeyword(writer, 94 /* NewKeyword */); writeSpace(writer); } - if (signature.target && (flags & 32 /* WriteTypeArgumentsOfSignature */)) { + if (signature.target && (flags & 64 /* WriteTypeArgumentsOfSignature */)) { // Instantiated signature, write type arguments instead // This is achieved by passing in the mapper separately buildDisplayForTypeArgumentsAndDelimiters(signature.target.typeParameters, signature.mapper, writer, enclosingDeclaration); @@ -28835,10 +30251,7 @@ var ts; exportSymbol = resolveName(node.parent, node.text, 107455 /* Value */ | 793064 /* Type */ | 1920 /* Namespace */ | 8388608 /* Alias */, ts.Diagnostics.Cannot_find_name_0, node); } else if (node.parent.kind === 246 /* ExportSpecifier */) { - var exportSpecifier = node.parent; - exportSymbol = exportSpecifier.parent.parent.moduleSpecifier ? - getExternalModuleMember(exportSpecifier.parent.parent, exportSpecifier) : - resolveEntityName(exportSpecifier.propertyName || exportSpecifier.name, 107455 /* Value */ | 793064 /* Type */ | 1920 /* Namespace */ | 8388608 /* Alias */); + exportSymbol = getTargetOfExportSpecifier(node.parent, 107455 /* Value */ | 793064 /* Type */ | 1920 /* Namespace */ | 8388608 /* Alias */); } var result = []; if (exportSymbol) { @@ -28981,7 +30394,7 @@ var ts; for (var _a = 0, _b = getPropertiesOfType(source); _a < _b.length; _a++) { var prop = _b[_a]; var inNamesToRemove = names.has(prop.name); - var isPrivate = getDeclarationModifierFlagsFromSymbol(prop) & (8 /* Private */ | 16 /* Protected */); + var isPrivate = ts.getDeclarationModifierFlagsFromSymbol(prop) & (8 /* Private */ | 16 /* Protected */); var isSetOnlyAccessor = prop.flags & 65536 /* SetAccessor */ && !(prop.flags & 32768 /* GetAccessor */); if (!inNamesToRemove && !isPrivate && !isClassMethod(prop) && !isSetOnlyAccessor) { members.set(prop.name, prop); @@ -29050,7 +30463,7 @@ var ts; // This elementType will be used if the specific property corresponding to this index is not // present (aka the tuple element property). This call also checks that the parentType is in // fact an iterable or array (depending on target language). - var elementType = checkIteratedTypeOrElementType(parentType, pattern, /*allowStringInput*/ false, /*allowAsyncIterable*/ false); + var elementType = checkIteratedTypeOrElementType(parentType, pattern, /*allowStringInput*/ false, /*allowAsyncIterables*/ false); if (declaration.dotDotDotToken) { // Rest element has an array type with the same element type as the parent type type = createArrayType(elementType); @@ -29097,19 +30510,10 @@ var ts; return expr.kind === 177 /* ArrayLiteralExpression */ && expr.elements.length === 0; } function addOptionality(type, optional) { - return strictNullChecks && optional ? includeFalsyTypes(type, 2048 /* Undefined */) : type; + return strictNullChecks && optional ? getNullableType(type, 2048 /* Undefined */) : type; } // Return the inferred type for a variable, parameter, or property declaration function getTypeForVariableLikeDeclaration(declaration, includeOptionality) { - if (declaration.flags & 65536 /* JavaScriptFile */) { - // If this is a variable in a JavaScript file, then use the JSDoc type (if it has - // one as its type), otherwise fallback to the below standard TS codepaths to - // try to figure it out. - var type = getTypeForDeclarationFromJSDocComment(declaration); - if (type && type !== unknownType) { - return type; - } - } // A variable declared in a for..in statement is of type string, or of type keyof T when the // right hand expression is of a type parameter type. if (declaration.parent.parent.kind === 215 /* ForInStatement */) { @@ -29128,8 +30532,9 @@ var ts; return getTypeForBindingElement(declaration); } // Use type from type annotation if one is present - if (declaration.type) { - var declaredType = getTypeFromTypeNode(declaration.type); + var typeNode = ts.getEffectiveTypeAnnotationNode(declaration); + if (typeNode) { + var declaredType = getTypeFromTypeNode(typeNode); return addOptionality(declaredType, /*optional*/ declaration.questionToken && includeOptionality); } if ((noImplicitAny || declaration.flags & 65536 /* JavaScriptFile */) && @@ -29200,6 +30605,7 @@ var ts; var types = []; var definedInConstructor = false; var definedInMethod = false; + var jsDocType; for (var _i = 0, _a = symbol.declarations; _i < _a.length; _i++) { var declaration = _a[_i]; var expression = declaration.kind === 194 /* BinaryExpression */ ? declaration : @@ -29216,17 +30622,25 @@ var ts; definedInMethod = true; } } - if (expression.flags & 65536 /* JavaScriptFile */) { - // If there is a JSDoc type, use it - var type = getTypeForDeclarationFromJSDocComment(expression.parent); - if (type && type !== unknownType) { - types.push(getWidenedType(type)); - continue; + // If there is a JSDoc type, use it + var type_1 = getTypeForDeclarationFromJSDocComment(expression.parent); + if (type_1) { + var declarationType = getWidenedType(type_1); + if (!jsDocType) { + jsDocType = declarationType; + } + else if (jsDocType !== unknownType && declarationType !== unknownType && !isTypeIdenticalTo(jsDocType, declarationType)) { + var name = ts.getNameOfDeclaration(declaration); + error(name, ts.Diagnostics.Subsequent_variable_declarations_must_have_the_same_type_Variable_0_must_be_of_type_1_but_here_has_type_2, ts.declarationNameToString(name), typeToString(jsDocType), typeToString(declarationType)); } } - types.push(getWidenedLiteralType(checkExpressionCached(expression.right))); + else if (!jsDocType) { + // If we don't have an explicit JSDoc type, get the type from the expression. + types.push(getWidenedLiteralType(checkExpressionCached(expression.right))); + } } - return getWidenedType(addOptionality(getUnionType(types, /*subtypeReduction*/ true), definedInMethod && !definedInConstructor)); + var type = jsDocType || getUnionType(types, /*subtypeReduction*/ true); + return getWidenedType(addOptionality(type, definedInMethod && !definedInConstructor)); } // Return the type implied by a binding pattern element. This is the type of the initializer of the element if // one is present. Otherwise, if the element is itself a binding pattern, it is the type implied by the binding @@ -29357,7 +30771,7 @@ var ts; if (declaration.kind === 243 /* ExportAssignment */) { return links.type = checkExpression(declaration.expression); } - if (declaration.flags & 65536 /* JavaScriptFile */ && declaration.kind === 291 /* JSDocPropertyTag */ && declaration.typeExpression) { + if (declaration.flags & 65536 /* JavaScriptFile */ && declaration.kind === 292 /* JSDocPropertyTag */ && declaration.typeExpression) { return links.type = getTypeFromTypeNode(declaration.typeExpression.type); } // Handle variable, parameter or property @@ -29387,10 +30801,11 @@ var ts; function getAnnotatedAccessorType(accessor) { if (accessor) { if (accessor.kind === 153 /* GetAccessor */) { - return accessor.type && getTypeFromTypeNode(accessor.type); + var getterTypeAnnotation = ts.getEffectiveReturnTypeNode(accessor); + return getterTypeAnnotation && getTypeFromTypeNode(getterTypeAnnotation); } else { - var setterTypeAnnotation = ts.getSetAccessorTypeAnnotationNode(accessor); + var setterTypeAnnotation = ts.getEffectiveSetAccessorTypeAnnotationNode(accessor); return setterTypeAnnotation && getTypeFromTypeNode(setterTypeAnnotation); } } @@ -29476,7 +30891,7 @@ var ts; links.type = baseTypeVariable ? getIntersectionType([type, baseTypeVariable]) : type; } else { - links.type = strictNullChecks && symbol.flags & 67108864 /* Optional */ ? includeFalsyTypes(type, 2048 /* Undefined */) : type; + links.type = strictNullChecks && symbol.flags & 67108864 /* Optional */ ? getNullableType(type, 2048 /* Undefined */) : type; } } } @@ -29528,7 +30943,7 @@ var ts; } function reportCircularityError(symbol) { // Check if variable has type annotation that circularly references the variable itself - if (symbol.valueDeclaration.type) { + if (ts.getEffectiveTypeAnnotationNode(symbol.valueDeclaration)) { error(symbol.valueDeclaration, ts.Diagnostics._0_is_referenced_directly_or_indirectly_in_its_own_type_annotation, symbolToString(symbol)); return unknownType; } @@ -29539,7 +30954,7 @@ var ts; return anyType; } function getTypeOfSymbol(symbol) { - if (getCheckFlags(symbol) & 1 /* Instantiated */) { + if (ts.getCheckFlags(symbol) & 1 /* Instantiated */) { return getTypeOfInstantiatedSymbol(symbol); } if (symbol.flags & (3 /* Variable */ | 4 /* Property */)) { @@ -29671,11 +31086,8 @@ var ts; } function getInstantiatedConstructorsForTypeArguments(type, typeArgumentNodes, location) { var signatures = getConstructorsForTypeArguments(type, typeArgumentNodes, location); - if (typeArgumentNodes) { - var typeArguments_1 = ts.map(typeArgumentNodes, getTypeFromTypeNode); - signatures = ts.map(signatures, function (sig) { return getSignatureInstantiation(sig, typeArguments_1); }); - } - return signatures; + var typeArguments = ts.map(typeArgumentNodes, getTypeFromTypeNode); + return ts.sameMap(signatures, function (sig) { return ts.some(sig.typeParameters) ? getSignatureInstantiation(sig, typeArguments) : sig; }); } /** * The base constructor of a class can resolve to @@ -29738,6 +31150,7 @@ var ts; return; } var baseTypeNode = getBaseTypeNodeOfClass(type); + var typeArgs = typeArgumentsFromTypeReferenceNode(baseTypeNode); var baseType; var originalBaseType = baseConstructorType && baseConstructorType.symbol ? getDeclaredTypeOfSymbol(baseConstructorType.symbol) : undefined; if (baseConstructorType.symbol && baseConstructorType.symbol.flags & 32 /* Class */ && @@ -29745,7 +31158,7 @@ var ts; // When base constructor type is a class with no captured type arguments we know that the constructors all have the same type parameters as the // class and all return the instance type of the class. There is no need for further checks and we can apply the // type arguments in the same manner as a type reference to get the same error reporting experience. - baseType = getTypeFromClassOrInterfaceReference(baseTypeNode, baseConstructorType.symbol); + baseType = getTypeFromClassOrInterfaceReference(baseTypeNode, baseConstructorType.symbol, typeArgs); } else if (baseConstructorType.flags & 1 /* Any */) { baseType = baseConstructorType; @@ -29897,7 +31310,7 @@ var ts; if (!pushTypeResolution(symbol, 2 /* DeclaredType */)) { return unknownType; } - var declaration = ts.getDeclarationOfKind(symbol, 290 /* JSDocTypedefTag */); + var declaration = ts.getDeclarationOfKind(symbol, 291 /* JSDocTypedefTag */); var type = void 0; if (declaration) { if (declaration.jsDocTypeLiteral) { @@ -29929,77 +31342,80 @@ var ts; } return links.declaredType; } - function isLiteralEnumMember(symbol, member) { + function isLiteralEnumMember(member) { var expr = member.initializer; if (!expr) { return !ts.isInAmbientContext(member); } - return expr.kind === 8 /* NumericLiteral */ || + return expr.kind === 9 /* StringLiteral */ || expr.kind === 8 /* NumericLiteral */ || expr.kind === 192 /* PrefixUnaryExpression */ && expr.operator === 38 /* MinusToken */ && expr.operand.kind === 8 /* NumericLiteral */ || - expr.kind === 71 /* Identifier */ && !!symbol.exports.get(expr.text); + expr.kind === 71 /* Identifier */ && (ts.nodeIsMissing(expr) || !!getSymbolOfNode(member.parent).exports.get(expr.text)); } - function enumHasLiteralMembers(symbol) { + function getEnumKind(symbol) { + var links = getSymbolLinks(symbol); + if (links.enumKind !== undefined) { + return links.enumKind; + } + var hasNonLiteralMember = false; for (var _i = 0, _a = symbol.declarations; _i < _a.length; _i++) { var declaration = _a[_i]; if (declaration.kind === 232 /* EnumDeclaration */) { for (var _b = 0, _c = declaration.members; _b < _c.length; _b++) { var member = _c[_b]; - if (!isLiteralEnumMember(symbol, member)) { - return false; + if (member.initializer && member.initializer.kind === 9 /* StringLiteral */) { + return links.enumKind = 1 /* Literal */; + } + if (!isLiteralEnumMember(member)) { + hasNonLiteralMember = true; } } } } - return true; + return links.enumKind = hasNonLiteralMember ? 0 /* Numeric */ : 1 /* Literal */; } - function createEnumLiteralType(symbol, baseType, text) { - var type = createType(256 /* EnumLiteral */); - type.symbol = symbol; - type.baseType = baseType; - type.text = text; - return type; + function getBaseTypeOfEnumLiteralType(type) { + return type.flags & 256 /* EnumLiteral */ && !(type.flags & 65536 /* Union */) ? getDeclaredTypeOfSymbol(getParentOfSymbol(type.symbol)) : type; } function getDeclaredTypeOfEnum(symbol) { var links = getSymbolLinks(symbol); - if (!links.declaredType) { - var enumType = links.declaredType = createType(16 /* Enum */); - enumType.symbol = symbol; - if (enumHasLiteralMembers(symbol)) { - var memberTypeList = []; - var memberTypes = []; - for (var _i = 0, _a = enumType.symbol.declarations; _i < _a.length; _i++) { - var declaration = _a[_i]; - if (declaration.kind === 232 /* EnumDeclaration */) { - computeEnumMemberValues(declaration); - for (var _b = 0, _c = declaration.members; _b < _c.length; _b++) { - var member = _c[_b]; - var memberSymbol = getSymbolOfNode(member); - var value = getEnumMemberValue(member); - if (!memberTypes[value]) { - var memberType = memberTypes[value] = createEnumLiteralType(memberSymbol, enumType, "" + value); - memberTypeList.push(memberType); - } - } + if (links.declaredType) { + return links.declaredType; + } + if (getEnumKind(symbol) === 1 /* Literal */) { + enumCount++; + var memberTypeList = []; + for (var _i = 0, _a = symbol.declarations; _i < _a.length; _i++) { + var declaration = _a[_i]; + if (declaration.kind === 232 /* EnumDeclaration */) { + for (var _b = 0, _c = declaration.members; _b < _c.length; _b++) { + var member = _c[_b]; + var memberType = getLiteralType(getEnumMemberValue(member), enumCount, getSymbolOfNode(member)); + getSymbolLinks(getSymbolOfNode(member)).declaredType = memberType; + memberTypeList.push(memberType); } } - enumType.memberTypes = memberTypes; - if (memberTypeList.length > 1) { - enumType.flags |= 65536 /* Union */; - enumType.types = memberTypeList; - unionTypes.set(getTypeListId(memberTypeList), enumType); + } + if (memberTypeList.length) { + var enumType_1 = getUnionType(memberTypeList, /*subtypeReduction*/ false, symbol, /*aliasTypeArguments*/ undefined); + if (enumType_1.flags & 65536 /* Union */) { + enumType_1.flags |= 256 /* EnumLiteral */; + enumType_1.symbol = symbol; } + return links.declaredType = enumType_1; } } - return links.declaredType; + var enumType = createType(16 /* Enum */); + enumType.symbol = symbol; + return links.declaredType = enumType; } function getDeclaredTypeOfEnumMember(symbol) { var links = getSymbolLinks(symbol); if (!links.declaredType) { var enumType = getDeclaredTypeOfEnum(getParentOfSymbol(symbol)); - links.declaredType = enumType.flags & 65536 /* Union */ ? - enumType.memberTypes[getEnumMemberValue(symbol.valueDeclaration)] : - enumType; + if (!links.declaredType) { + links.declaredType = enumType; + } } return links.declaredType; } @@ -30079,13 +31495,17 @@ var ts; // A variable-like declaration is considered independent (free of this references) if it has a type annotation // that specifies an independent type, or if it has no type annotation and no initializer (and thus of type any). function isIndependentVariableLikeDeclaration(node) { - return node.type && isIndependentType(node.type) || !node.type && !node.initializer; + var typeNode = ts.getEffectiveTypeAnnotationNode(node); + return typeNode ? isIndependentType(typeNode) : !node.initializer; } // A function-like declaration is considered independent (free of this references) if it has a return type // annotation that is considered independent and if each parameter is considered independent. function isIndependentFunctionLikeDeclaration(node) { - if (node.kind !== 152 /* Constructor */ && (!node.type || !isIndependentType(node.type))) { - return false; + if (node.kind !== 152 /* Constructor */) { + var typeNode = ts.getEffectiveReturnTypeNode(node); + if (!typeNode || !isIndependentType(typeNode)) { + return false; + } } for (var _i = 0, _a = node.parameters; _i < _a.length; _i++) { var parameter = _a[_i]; @@ -30246,7 +31666,7 @@ var ts; } var baseTypeNode = getBaseTypeNodeOfClass(classType); var isJavaScript = ts.isInJavaScriptFile(baseTypeNode); - var typeArguments = ts.map(baseTypeNode.typeArguments, getTypeFromTypeNode); + var typeArguments = typeArgumentsFromTypeReferenceNode(baseTypeNode); var typeArgCount = ts.length(typeArguments); var result = []; for (var _i = 0, baseSignatures_1 = baseSignatures; _i < baseSignatures_1.length; _i++) { @@ -30333,8 +31753,8 @@ var ts; function getUnionIndexInfo(types, kind) { var indexTypes = []; var isAnyReadonly = false; - for (var _i = 0, types_2 = types; _i < types_2.length; _i++) { - var type = types_2[_i]; + for (var _i = 0, types_1 = types; _i < types_1.length; _i++) { + var type = types_1[_i]; var indexInfo = getIndexInfoOfType(type, kind); if (!indexInfo) { return undefined; @@ -30508,7 +31928,7 @@ var ts; // If the current iteration type constituent is a string literal type, create a property. // Otherwise, for type string create a string index signature. if (t.flags & 32 /* StringLiteral */) { - var propName = t.text; + var propName = t.value; var modifiersProp = getPropertyOfType(modifiersType, propName); var isOptional = templateOptional || !!(modifiersProp && modifiersProp.flags & 67108864 /* Optional */); var prop = createSymbol(4 /* Property */ | (isOptional ? 67108864 /* Optional */ : 0), propName); @@ -30516,6 +31936,7 @@ var ts; prop.type = propType; if (propertySymbol) { prop.syntheticOrigin = propertySymbol; + prop.declarations = propertySymbol.declarations; } members.set(propName, prop); } @@ -30640,6 +32061,27 @@ var ts; getPropertiesOfUnionOrIntersectionType(type) : getPropertiesOfObjectType(type); } + function getAllPossiblePropertiesOfType(type) { + if (type.flags & 65536 /* Union */) { + var props = ts.createMap(); + for (var _i = 0, _a = type.types; _i < _a.length; _i++) { + var memberType = _a[_i]; + if (memberType.flags & 8190 /* Primitive */) { + continue; + } + for (var _b = 0, _c = getPropertiesOfType(memberType); _b < _c.length; _b++) { + var name = _c[_b].name; + if (!props.has(name)) { + props.set(name, createUnionOrIntersectionProperty(type, name)); + } + } + } + return ts.arrayFrom(props.values()); + } + else { + return getPropertiesOfType(type); + } + } function getConstraintOfType(type) { return type.flags & 16384 /* TypeParameter */ ? getConstraintOfTypeParameter(type) : type.flags & 524288 /* IndexedAccess */ ? getConstraintOfIndexedAccess(type) : @@ -30701,8 +32143,8 @@ var ts; if (t.flags & 196608 /* UnionOrIntersection */) { var types = t.types; var baseTypes = []; - for (var _i = 0, types_3 = types; _i < types_3.length; _i++) { - var type_2 = types_3[_i]; + for (var _i = 0, types_2 = types; _i < types_2.length; _i++) { + var type_2 = types_2[_i]; var baseType = getBaseConstraint(type_2); if (baseType) { baseTypes.push(baseType); @@ -30743,7 +32185,7 @@ var ts; typeParameter.default = targetDefault ? instantiateType(targetDefault, typeParameter.mapper) : noConstraintType; } else { - var defaultDeclaration = typeParameter.symbol && ts.forEach(typeParameter.symbol.declarations, function (decl) { return ts.isTypeParameter(decl) && decl.default; }); + var defaultDeclaration = typeParameter.symbol && ts.forEach(typeParameter.symbol.declarations, function (decl) { return ts.isTypeParameterDeclaration(decl) && decl.default; }); typeParameter.default = defaultDeclaration ? getTypeFromTypeNode(defaultDeclaration) : noConstraintType; } } @@ -30758,7 +32200,7 @@ var ts; var t = type.flags & 540672 /* TypeVariable */ ? getBaseConstraintOfType(type) || emptyObjectType : type; return t.flags & 131072 /* Intersection */ ? getApparentTypeOfIntersectionType(t) : t.flags & 262178 /* StringLike */ ? globalStringType : - t.flags & 340 /* NumberLike */ ? globalNumberType : + t.flags & 84 /* NumberLike */ ? globalNumberType : t.flags & 136 /* BooleanLike */ ? globalBooleanType : t.flags & 512 /* ESSymbol */ ? getGlobalESSymbolType(/*reportErrors*/ languageVersion >= 2 /* ES2015 */) : t.flags & 16777216 /* NonPrimitive */ ? emptyObjectType : @@ -30773,12 +32215,12 @@ var ts; var commonFlags = isUnion ? 0 /* None */ : 67108864 /* Optional */; var syntheticFlag = 4 /* SyntheticMethod */; var checkFlags = 0; - for (var _i = 0, types_4 = types; _i < types_4.length; _i++) { - var current = types_4[_i]; + for (var _i = 0, types_3 = types; _i < types_3.length; _i++) { + var current = types_3[_i]; var type = getApparentType(current); if (type !== unknownType) { var prop = getPropertyOfType(type, name); - var modifiers = prop ? getDeclarationModifierFlagsFromSymbol(prop) : 0; + var modifiers = prop ? ts.getDeclarationModifierFlagsFromSymbol(prop) : 0; if (prop && !(modifiers & excludeModifiers)) { commonFlags &= prop.flags; if (!props) { @@ -30850,7 +32292,7 @@ var ts; function getPropertyOfUnionOrIntersectionType(type, name) { var property = getUnionOrIntersectionProperty(type, name); // We need to filter out partial properties in union types - return property && !(getCheckFlags(property) & 16 /* Partial */) ? property : undefined; + return property && !(ts.getCheckFlags(property) & 16 /* Partial */) ? property : undefined; } /** * Return the symbol for the property with the given name in the given type. Creates synthetic union properties when @@ -30930,22 +32372,16 @@ var ts; } return undefined; } - function getTypeParametersFromJSDocTemplate(declaration) { - if (declaration.flags & 65536 /* JavaScriptFile */) { - var templateTag = ts.getJSDocTemplateTag(declaration); - if (templateTag) { - return getTypeParametersFromDeclaration(templateTag.typeParameters); - } - } - return undefined; - } // Return list of type parameters with duplicates removed (duplicate identifier errors are generated in the actual // type checking functions). - function getTypeParametersFromDeclaration(typeParameterDeclarations) { - var result = []; - ts.forEach(typeParameterDeclarations, function (node) { + function getTypeParametersFromDeclaration(declaration) { + var result; + ts.forEach(ts.getEffectiveTypeParameterDeclarations(declaration), function (node) { var tp = getDeclaredTypeOfTypeParameter(node.symbol); if (!ts.contains(result, tp)) { + if (!result) { + result = []; + } result.push(tp); } }); @@ -31124,14 +32560,21 @@ var ts; var classType = declaration.kind === 152 /* Constructor */ ? getDeclaredTypeOfClassOrInterface(getMergedSymbol(declaration.parent.symbol)) : undefined; - var typeParameters = classType ? classType.localTypeParameters : - declaration.typeParameters ? getTypeParametersFromDeclaration(declaration.typeParameters) : - getTypeParametersFromJSDocTemplate(declaration); + var typeParameters = classType ? classType.localTypeParameters : getTypeParametersFromDeclaration(declaration); var returnType = getSignatureReturnTypeFromDeclaration(declaration, isJSConstructSignature, classType); var typePredicate = declaration.type && declaration.type.kind === 158 /* TypePredicate */ ? createTypePredicateFromTypePredicateNode(declaration.type) : undefined; - links.resolvedSignature = createSignature(declaration, typeParameters, thisParameter, parameters, returnType, typePredicate, minArgumentCount, ts.hasRestParameter(declaration), hasLiteralTypes); + // JS functions get a free rest parameter if they reference `arguments` + var hasRestLikeParameter = ts.hasRestParameter(declaration); + if (!hasRestLikeParameter && ts.isInJavaScriptFile(declaration) && !ts.hasJSDocParameterTags(declaration) && containsArgumentsReference(declaration)) { + hasRestLikeParameter = true; + var syntheticArgsSymbol = createSymbol(3 /* Variable */, "args"); + syntheticArgsSymbol.type = anyArrayType; + syntheticArgsSymbol.isRestParameter = true; + parameters.push(syntheticArgsSymbol); + } + links.resolvedSignature = createSignature(declaration, typeParameters, thisParameter, parameters, returnType, typePredicate, minArgumentCount, hasRestLikeParameter, hasLiteralTypes); } return links.resolvedSignature; } @@ -31142,14 +32585,9 @@ var ts; else if (classType) { return classType; } - else if (declaration.type) { - return getTypeFromTypeNode(declaration.type); - } - if (declaration.flags & 65536 /* JavaScriptFile */) { - var type = getReturnTypeFromJSDocComment(declaration); - if (type && type !== unknownType) { - return type; - } + var typeNode = ts.getEffectiveReturnTypeNode(declaration); + if (typeNode) { + return getTypeFromTypeNode(typeNode); } // TypeScript 1.0 spec (April 2014): // If only one accessor includes a type annotation, the other behaves as if it had the same type annotation. @@ -31395,8 +32833,8 @@ var ts; // that care about the presence of such types at arbitrary depth in a containing type. function getPropagatingFlagsOfTypes(types, excludeKinds) { var result = 0; - for (var _i = 0, types_5 = types; _i < types_5.length; _i++) { - var type = types_5[_i]; + for (var _i = 0, types_4 = types; _i < types_4.length; _i++) { + var type = types_4[_i]; if (!(type.flags & excludeKinds)) { result |= type.flags; } @@ -31426,8 +32864,10 @@ var ts; function getTypeReferenceArity(type) { return ts.length(type.target.typeParameters); } - // Get type from reference to class or interface - function getTypeFromClassOrInterfaceReference(node, symbol) { + /** + * Get type from type-reference that reference to class or interface + */ + function getTypeFromClassOrInterfaceReference(node, symbol, typeArgs) { var type = getDeclaredTypeOfSymbol(getMergedSymbol(symbol)); var typeParameters = type.localTypeParameters; if (typeParameters) { @@ -31442,7 +32882,7 @@ var ts; // In a type reference, the outer type parameters of the referenced class or interface are automatically // supplied as type arguments and the type reference only specifies arguments for the local type parameters // of the class or interface. - var typeArguments = ts.concatenate(type.outerTypeParameters, fillMissingTypeArguments(ts.map(node.typeArguments, getTypeFromTypeNode), typeParameters, minTypeArgumentCount, node)); + var typeArguments = ts.concatenate(type.outerTypeParameters, fillMissingTypeArguments(typeArgs, typeParameters, minTypeArgumentCount, node)); return createTypeReference(type, typeArguments); } if (node.typeArguments) { @@ -31462,10 +32902,12 @@ var ts; } return instantiation; } - // Get type from reference to type alias. When a type alias is generic, the declared type of the type alias may include - // references to the type parameters of the alias. We replace those with the actual type arguments by instantiating the - // declared type. Instantiations are cached using the type identities of the type arguments as the key. - function getTypeFromTypeAliasReference(node, symbol) { + /** + * Get type from reference to type alias. When a type alias is generic, the declared type of the type alias may include + * references to the type parameters of the alias. We replace those with the actual type arguments by instantiating the + * declared type. Instantiations are cached using the type identities of the type arguments as the key. + */ + function getTypeFromTypeAliasReference(node, symbol, typeArguments) { var type = getDeclaredTypeOfSymbol(symbol); var typeParameters = getSymbolLinks(symbol).typeParameters; if (typeParameters) { @@ -31477,7 +32919,6 @@ var ts; : ts.Diagnostics.Generic_type_0_requires_between_1_and_2_type_arguments, symbolToString(symbol), minTypeArgumentCount, typeParameters.length); return unknownType; } - var typeArguments = ts.map(node.typeArguments, getTypeFromTypeNode); return getTypeAliasInstantiation(symbol, typeArguments); } if (node.typeArguments) { @@ -31486,7 +32927,9 @@ var ts; } return type; } - // Get type from reference to named type that cannot be generic (enum or type parameter) + /** + * Get type from reference to named type that cannot be generic (enum or type parameter) + */ function getTypeFromNonGenericTypeReference(node, symbol) { if (node.typeArguments) { error(node, ts.Diagnostics.Type_0_is_not_generic, symbolToString(symbol)); @@ -31510,29 +32953,48 @@ var ts; } return undefined; } - function resolveTypeReferenceName(typeReferenceName) { + function resolveTypeReferenceName(typeReferenceName, meaning) { if (!typeReferenceName) { return unknownSymbol; } - return resolveEntityName(typeReferenceName, 793064 /* Type */) || unknownSymbol; + return resolveEntityName(typeReferenceName, meaning) || unknownSymbol; } function getTypeReferenceType(node, symbol) { + var typeArguments = typeArgumentsFromTypeReferenceNode(node); // Do unconditionally so we mark type arguments as referenced. if (symbol === unknownSymbol) { return unknownType; } + var type = getTypeReferenceTypeWorker(node, symbol, typeArguments); + if (type) { + return type; + } + if (symbol.flags & 107455 /* Value */ && node.kind === 277 /* JSDocTypeReference */) { + // A JSDocTypeReference may have resolved to a value (as opposed to a type). If + // the symbol is a constructor function, return the inferred class type; otherwise, + // the type of this reference is just the type of the value we resolved to. + var valueType = getTypeOfSymbol(symbol); + if (valueType.symbol && !isInferredClassType(valueType)) { + var referenceType = getTypeReferenceTypeWorker(node, valueType.symbol, typeArguments); + if (referenceType) { + return referenceType; + } + } + // Resolve the type reference as a Type for the purpose of reporting errors. + resolveTypeReferenceName(getTypeReferenceName(node), 793064 /* Type */); + return valueType; + } + return getTypeFromNonGenericTypeReference(node, symbol); + } + function getTypeReferenceTypeWorker(node, symbol, typeArguments) { if (symbol.flags & (32 /* Class */ | 64 /* Interface */)) { - return getTypeFromClassOrInterfaceReference(node, symbol); + return getTypeFromClassOrInterfaceReference(node, symbol, typeArguments); } if (symbol.flags & 524288 /* TypeAlias */) { - return getTypeFromTypeAliasReference(node, symbol); + return getTypeFromTypeAliasReference(node, symbol, typeArguments); } - if (symbol.flags & 107455 /* Value */ && node.kind === 277 /* JSDocTypeReference */) { - // A JSDocTypeReference may have resolved to a value (as opposed to a type). In - // that case, the type of this reference is just the type of the value we resolved - // to. - return getTypeOfSymbol(symbol); + if (symbol.flags & 16 /* Function */ && node.kind === 277 /* JSDocTypeReference */ && (symbol.members || ts.getJSDocClassTag(symbol.valueDeclaration))) { + return getInferredClassType(symbol); } - return getTypeFromNonGenericTypeReference(node, symbol); } function getPrimitiveTypeFromJSDocTypeReference(node) { if (ts.isIdentifier(node.name)) { @@ -31552,7 +33014,8 @@ var ts; case "Object": return anyType; case "Function": - return anyFunctionType; + case "function": + return globalFunctionType; case "Array": case "array": return !node.typeArguments || !node.typeArguments.length ? createArrayType(anyType) : undefined; @@ -31571,26 +33034,14 @@ var ts; if (!links.resolvedType) { var symbol = void 0; var type = void 0; + var meaning = 793064 /* Type */; if (node.kind === 277 /* JSDocTypeReference */) { type = getPrimitiveTypeFromJSDocTypeReference(node); - if (!type) { - var typeReferenceName = getTypeReferenceName(node); - symbol = resolveTypeReferenceName(typeReferenceName); - type = getTypeReferenceType(node, symbol); - } + meaning |= 107455 /* Value */; } - else { - // We only support expressions that are simple qualified names. For other expressions this produces undefined. - var typeNameOrExpression = node.kind === 159 /* TypeReference */ - ? node.typeName - : ts.isEntityNameExpression(node.expression) - ? node.expression - : undefined; - symbol = typeNameOrExpression && resolveEntityName(typeNameOrExpression, 793064 /* Type */) || unknownSymbol; - type = symbol === unknownSymbol ? unknownType : - symbol.flags & (32 /* Class */ | 64 /* Interface */) ? getTypeFromClassOrInterfaceReference(node, symbol) : - symbol.flags & 524288 /* TypeAlias */ ? getTypeFromTypeAliasReference(node, symbol) : - getTypeFromNonGenericTypeReference(node, symbol); + if (!type) { + symbol = resolveTypeReferenceName(getTypeReferenceName(node), meaning); + type = getTypeReferenceType(node, symbol); } // Cache both the resolved symbol and the resolved type. The resolved symbol is needed in when we check the // type reference in checkTypeReferenceOrExpressionWithTypeArguments. @@ -31599,6 +33050,9 @@ var ts; } return links.resolvedType; } + function typeArgumentsFromTypeReferenceNode(node) { + return ts.map(node.typeArguments, getTypeFromTypeNode); + } function getTypeFromTypeQueryNode(node) { var links = getNodeLinks(node); if (!links.resolvedType) { @@ -31840,14 +33294,14 @@ var ts; // Add the given types to the given type set. Order is preserved, duplicates are removed, // and nested types of the given kind are flattened into the set. function addTypesToUnion(typeSet, types) { - for (var _i = 0, types_6 = types; _i < types_6.length; _i++) { - var type = types_6[_i]; + for (var _i = 0, types_5 = types; _i < types_5.length; _i++) { + var type = types_5[_i]; addTypeToUnion(typeSet, type); } } function containsIdenticalType(types, type) { - for (var _i = 0, types_7 = types; _i < types_7.length; _i++) { - var t = types_7[_i]; + for (var _i = 0, types_6 = types; _i < types_6.length; _i++) { + var t = types_6[_i]; if (isTypeIdenticalTo(t, type)) { return true; } @@ -31855,8 +33309,8 @@ var ts; return false; } function isSubtypeOfAny(candidate, types) { - for (var _i = 0, types_8 = types; _i < types_8.length; _i++) { - var type = types_8[_i]; + for (var _i = 0, types_7 = types; _i < types_7.length; _i++) { + var type = types_7[_i]; if (candidate !== type && isTypeSubtypeOf(candidate, type)) { return true; } @@ -31968,10 +33422,13 @@ var ts; else if (type.flags & 1 /* Any */) { typeSet.containsAny = true; } + else if (type.flags & 8192 /* Never */) { + typeSet.containsNever = true; + } else if (getObjectFlags(type) & 16 /* Anonymous */ && isEmptyObjectType(type)) { typeSet.containsEmptyObject = true; } - else if (!(type.flags & 8192 /* Never */) && (strictNullChecks || !(type.flags & 6144 /* Nullable */)) && !ts.contains(typeSet, type)) { + else if ((strictNullChecks || !(type.flags & 6144 /* Nullable */)) && !ts.contains(typeSet, type)) { if (type.flags & 32768 /* Object */) { typeSet.containsObjectType = true; } @@ -31987,8 +33444,8 @@ var ts; // Add the given types to the given type set. Order is preserved, duplicates are removed, // and nested types of the given kind are flattened into the set. function addTypesToIntersection(typeSet, types) { - for (var _i = 0, types_9 = types; _i < types_9.length; _i++) { - var type = types_9[_i]; + for (var _i = 0, types_8 = types; _i < types_8.length; _i++) { + var type = types_8[_i]; addTypeToIntersection(typeSet, type); } } @@ -32008,6 +33465,9 @@ var ts; } var typeSet = []; addTypesToIntersection(typeSet, types); + if (typeSet.containsNever) { + return neverType; + } if (typeSet.containsAny) { return anyType; } @@ -32052,9 +33512,9 @@ var ts; return type.resolvedIndexType; } function getLiteralTypeFromPropertyName(prop) { - return getDeclarationModifierFlagsFromSymbol(prop) & 24 /* NonPublicAccessibilityModifier */ || ts.startsWith(prop.name, "__@") ? + return ts.getDeclarationModifierFlagsFromSymbol(prop) & 24 /* NonPublicAccessibilityModifier */ || ts.startsWith(prop.name, "__@") ? neverType : - getLiteralTypeForText(32 /* StringLiteral */, ts.unescapeIdentifier(prop.name)); + getLiteralType(ts.unescapeIdentifier(prop.name)); } function getLiteralTypeFromPropertyNames(type) { return getUnionType(ts.map(getPropertiesOfType(type), getLiteralTypeFromPropertyName)); @@ -32084,12 +33544,12 @@ var ts; } function getPropertyTypeForIndexType(objectType, indexType, accessNode, cacheSymbol) { var accessExpression = accessNode && accessNode.kind === 180 /* ElementAccessExpression */ ? accessNode : undefined; - var propName = indexType.flags & (32 /* StringLiteral */ | 64 /* NumberLiteral */ | 256 /* EnumLiteral */) ? - indexType.text : + var propName = indexType.flags & 96 /* StringOrNumberLiteral */ ? + "" + indexType.value : accessExpression && checkThatExpressionIsProperSymbolReference(accessExpression.argumentExpression, indexType, /*reportError*/ false) ? ts.getPropertyNameForKnownSymbolName(accessExpression.argumentExpression.name.text) : undefined; - if (propName) { + if (propName !== undefined) { var prop = getPropertyOfType(objectType, propName); if (prop) { if (accessExpression) { @@ -32104,11 +33564,11 @@ var ts; return getTypeOfSymbol(prop); } } - if (isTypeAnyOrAllConstituentTypesHaveKind(indexType, 262178 /* StringLike */ | 340 /* NumberLike */ | 512 /* ESSymbol */)) { + if (isTypeAnyOrAllConstituentTypesHaveKind(indexType, 262178 /* StringLike */ | 84 /* NumberLike */ | 512 /* ESSymbol */)) { if (isTypeAny(objectType)) { return anyType; } - var indexInfo = isTypeAnyOrAllConstituentTypesHaveKind(indexType, 340 /* NumberLike */) && getIndexInfoOfType(objectType, 1 /* Number */) || + var indexInfo = isTypeAnyOrAllConstituentTypesHaveKind(indexType, 84 /* NumberLike */) && getIndexInfoOfType(objectType, 1 /* Number */) || getIndexInfoOfType(objectType, 0 /* String */) || undefined; if (indexInfo) { @@ -32133,7 +33593,7 @@ var ts; if (accessNode) { var indexNode = accessNode.kind === 180 /* ElementAccessExpression */ ? accessNode.argumentExpression : accessNode.indexType; if (indexType.flags & (32 /* StringLiteral */ | 64 /* NumberLiteral */)) { - error(indexNode, ts.Diagnostics.Property_0_does_not_exist_on_type_1, indexType.text, typeToString(objectType)); + error(indexNode, ts.Diagnostics.Property_0_does_not_exist_on_type_1, "" + indexType.value, typeToString(objectType)); } else if (indexType.flags & (2 /* String */ | 4 /* Number */)) { error(indexNode, ts.Diagnostics.Type_0_has_no_matching_index_signature_for_type_1, typeToString(objectType), typeToString(indexType)); @@ -32252,11 +33712,9 @@ var ts; if (left.flags & 1 /* Any */ || right.flags & 1 /* Any */) { return anyType; } - left = filterType(left, function (t) { return !(t.flags & 6144 /* Nullable */); }); if (left.flags & 8192 /* Never */) { return right; } - right = filterType(right, function (t) { return !(t.flags & 6144 /* Nullable */); }); if (right.flags & 8192 /* Never */) { return left; } @@ -32286,7 +33744,7 @@ var ts; var rightProp = _a[_i]; // we approximate own properties as non-methods plus methods that are inside the object literal var isSetterWithoutGetter = rightProp.flags & 65536 /* SetAccessor */ && !(rightProp.flags & 32768 /* GetAccessor */); - if (getDeclarationModifierFlagsFromSymbol(rightProp) & (8 /* Private */ | 16 /* Protected */)) { + if (ts.getDeclarationModifierFlagsFromSymbol(rightProp) & (8 /* Private */ | 16 /* Protected */)) { skippedPrivateMembers.set(rightProp.name, true); } else if (!isClassMethod(rightProp) && !isSetterWithoutGetter) { @@ -32303,7 +33761,7 @@ var ts; if (members.has(leftProp.name)) { var rightProp = members.get(leftProp.name); var rightType = getTypeOfSymbol(rightProp); - if (maybeTypeOfKind(rightType, 2048 /* Undefined */) || rightProp.flags & 67108864 /* Optional */) { + if (rightProp.flags & 67108864 /* Optional */) { var declarations = ts.concatenate(leftProp.declarations, rightProp.declarations); var flags = 4 /* Property */ | (leftProp.flags & 67108864 /* Optional */); var result = createSymbol(flags, leftProp.name); @@ -32334,15 +33792,16 @@ var ts; function isClassMethod(prop) { return prop.flags & 8192 /* Method */ && ts.find(prop.declarations, function (decl) { return ts.isClassLike(decl.parent); }); } - function createLiteralType(flags, text) { + function createLiteralType(flags, value, symbol) { var type = createType(flags); - type.text = text; + type.symbol = symbol; + type.value = value; return type; } function getFreshTypeOfLiteralType(type) { if (type.flags & 96 /* StringOrNumberLiteral */ && !(type.flags & 1048576 /* FreshLiteral */)) { if (!type.freshType) { - var freshType = createLiteralType(type.flags | 1048576 /* FreshLiteral */, type.text); + var freshType = createLiteralType(type.flags | 1048576 /* FreshLiteral */, type.value, type.symbol); freshType.regularType = type; type.freshType = freshType; } @@ -32353,11 +33812,17 @@ var ts; function getRegularTypeOfLiteralType(type) { return type.flags & 96 /* StringOrNumberLiteral */ && type.flags & 1048576 /* FreshLiteral */ ? type.regularType : type; } - function getLiteralTypeForText(flags, text) { - var map = flags & 32 /* StringLiteral */ ? stringLiteralTypes : numericLiteralTypes; - var type = map.get(text); + function getLiteralType(value, enumId, symbol) { + // We store all literal types in a single map with keys of the form '#NNN' and '@SSS', + // where NNN is the text representation of a numeric literal and SSS are the characters + // of a string literal. For literal enum members we use 'EEE#NNN' and 'EEE@SSS', where + // EEE is a unique id for the containing enum type. + var qualifier = typeof value === "number" ? "#" : "@"; + var key = enumId ? enumId + qualifier + value : qualifier + value; + var type = literalTypes.get(key); if (!type) { - map.set(text, type = createLiteralType(flags, text)); + var flags = (typeof value === "number" ? 64 /* NumberLiteral */ : 32 /* StringLiteral */) | (enumId ? 256 /* EnumLiteral */ : 0); + literalTypes.set(key, type = createLiteralType(flags, value, symbol)); } return type; } @@ -32432,7 +33897,7 @@ var ts; return getTypeFromThisTypeNode(node); case 173 /* LiteralType */: return getTypeFromLiteralTypeNode(node); - case 293 /* JSDocLiteralType */: + case 294 /* JSDocLiteralType */: return getTypeFromLiteralTypeNode(node.literal); case 159 /* TypeReference */: case 277 /* JSDocTypeReference */: @@ -32466,7 +33931,7 @@ var ts; case 160 /* FunctionType */: case 161 /* ConstructorType */: case 163 /* TypeLiteral */: - case 292 /* JSDocTypeLiteral */: + case 293 /* JSDocTypeLiteral */: case 279 /* JSDocFunctionType */: return getTypeFromTypeLiteralOrFunctionOrConstructorTypeNode(node); case 170 /* TypeOperator */: @@ -32545,23 +34010,13 @@ var ts; mapper.mappedTypes = typeParameters; return mapper; } - function getInferenceMapper(context) { - if (!context.mapper) { - var mapper = function (t) { - var typeParameters = context.signature.typeParameters; - for (var i = 0; i < typeParameters.length; i++) { - if (t === typeParameters[i]) { - context.inferences[i].isFixed = true; - return getInferredType(context, i); - } - } - return t; - }; - mapper.mappedTypes = context.signature.typeParameters; - mapper.context = context; - context.mapper = mapper; - } - return context.mapper; + function isInferenceContext(mapper) { + return !!mapper.signature; + } + function cloneTypeMapper(mapper) { + return mapper && isInferenceContext(mapper) ? + createInferenceContext(mapper.signature, mapper.flags | 2 /* NoDefault */, mapper.inferences) : + mapper; } function identityMapper(type) { return type; @@ -32615,13 +34070,14 @@ var ts; if (signature.typePredicate) { freshTypePredicate = cloneTypePredicate(signature.typePredicate, mapper); } - var result = createSignature(signature.declaration, freshTypeParameters, signature.thisParameter && instantiateSymbol(signature.thisParameter, mapper), instantiateList(signature.parameters, mapper, instantiateSymbol), instantiateType(signature.resolvedReturnType, mapper), freshTypePredicate, signature.minArgumentCount, signature.hasRestParameter, signature.hasLiteralTypes); + var result = createSignature(signature.declaration, freshTypeParameters, signature.thisParameter && instantiateSymbol(signature.thisParameter, mapper), instantiateList(signature.parameters, mapper, instantiateSymbol), + /*resolvedReturnType*/ undefined, freshTypePredicate, signature.minArgumentCount, signature.hasRestParameter, signature.hasLiteralTypes); result.target = signature; result.mapper = mapper; return result; } function instantiateSymbol(symbol, mapper) { - if (getCheckFlags(symbol) & 1 /* Instantiated */) { + if (ts.getCheckFlags(symbol) & 1 /* Instantiated */) { var links = getSymbolLinks(symbol); // If symbol being instantiated is itself a instantiation, fetch the original target and combine the // type mappers. This ensures that original type identities are properly preserved and that aliases @@ -32714,10 +34170,10 @@ var ts; case 199 /* ClassExpression */: case 230 /* InterfaceDeclaration */: case 231 /* TypeAliasDeclaration */: - var declaration = node; - if (declaration.typeParameters) { - for (var _i = 0, _a = declaration.typeParameters; _i < _a.length; _i++) { - var d = _a[_i]; + var typeParameters = ts.getEffectiveTypeParameterDeclarations(node); + if (typeParameters) { + for (var _i = 0, typeParameters_1 = typeParameters; _i < typeParameters_1.length; _i++) { + var d = typeParameters_1[_i]; if (ts.contains(mappedTypes, getDeclaredTypeOfTypeParameter(getSymbolOfNode(d)))) { return true; } @@ -32737,8 +34193,8 @@ var ts; break; case 279 /* JSDocFunctionType */: var func = node; - for (var _b = 0, _c = func.parameters; _b < _c.length; _b++) { - var p = _c[_b]; + for (var _a = 0, _b = func.parameters; _a < _b.length; _a++) { + var p = _b[_a]; if (ts.contains(mappedTypes, getTypeOfNode(p))) { return true; } @@ -32866,7 +34322,7 @@ var ts; return false; } // Functions with any parameters that lack type annotations are context sensitive. - if (ts.forEach(node.parameters, function (p) { return !p.type; })) { + if (ts.forEach(node.parameters, function (p) { return !ts.getEffectiveTypeAnnotationNode(p); })) { return true; } // For arrow functions we now know we're not context sensitive. @@ -32925,6 +34381,12 @@ var ts; /** * This is *not* a bi-directional relationship. * If one needs to check both directions for comparability, use a second call to this function or 'checkTypeComparableTo'. + * + * A type S is comparable to a type T if some (but not necessarily all) of the possible values of S are also possible values of T. + * It is used to check following cases: + * - the types of the left and right sides of equality/inequality operators (`===`, `!==`, `==`, `!=`). + * - the types of `case` clause expressions and their respective `switch` expressions. + * - the type of an expression in a type assertion with the type being asserted. */ function isTypeComparableTo(source, target) { return isTypeRelatedTo(source, target, comparableRelation); @@ -32932,9 +34394,6 @@ var ts; function areTypesComparable(type1, type2) { return isTypeComparableTo(type1, type2) || isTypeComparableTo(type2, type1); } - function checkTypeSubtypeOf(source, target, errorNode, headMessage, containingMessageChain) { - return checkTypeRelatedTo(source, target, subtypeRelation, errorNode, headMessage, containingMessageChain); - } function checkTypeAssignableTo(source, target, errorNode, headMessage, containingMessageChain) { return checkTypeRelatedTo(source, target, assignableRelation, errorNode, headMessage, containingMessageChain); } @@ -32946,12 +34405,13 @@ var ts; return checkTypeRelatedTo(source, target, comparableRelation, errorNode, headMessage, containingMessageChain); } function isSignatureAssignableTo(source, target, ignoreReturnTypes) { - return compareSignaturesRelated(source, target, ignoreReturnTypes, /*reportErrors*/ false, /*errorReporter*/ undefined, compareTypesAssignable) !== 0 /* False */; + return compareSignaturesRelated(source, target, /*checkAsCallback*/ false, ignoreReturnTypes, /*reportErrors*/ false, + /*errorReporter*/ undefined, compareTypesAssignable) !== 0 /* False */; } /** * See signatureRelatedTo, compareSignaturesIdentical */ - function compareSignaturesRelated(source, target, ignoreReturnTypes, reportErrors, errorReporter, compareTypes) { + function compareSignaturesRelated(source, target, checkAsCallback, ignoreReturnTypes, reportErrors, errorReporter, compareTypes) { // TODO (drosen): De-duplicate code between related functions. if (source === target) { return -1 /* True */; @@ -32959,10 +34419,9 @@ var ts; if (!target.hasRestParameter && source.minArgumentCount > target.parameters.length) { return 0 /* False */; } - // Spec 1.0 Section 3.8.3 & 3.8.4: - // M and N (the signatures) are instantiated using type Any as the type argument for all type parameters declared by M and N - source = getErasedSignature(source); - target = getErasedSignature(target); + if (source.typeParameters) { + source = instantiateSignatureInContextOf(source, target); + } var result = -1 /* True */; var sourceThisType = getThisTypeOfSignature(source); if (sourceThisType && sourceThisType !== voidType) { @@ -32986,9 +34445,23 @@ var ts; var sourceParams = source.parameters; var targetParams = target.parameters; for (var i = 0; i < checkCount; i++) { - var s = i < sourceMax ? getTypeOfParameter(sourceParams[i]) : getRestTypeOfSignature(source); - var t = i < targetMax ? getTypeOfParameter(targetParams[i]) : getRestTypeOfSignature(target); - var related = compareTypes(s, t, /*reportErrors*/ false) || compareTypes(t, s, reportErrors); + var sourceType = i < sourceMax ? getTypeOfParameter(sourceParams[i]) : getRestTypeOfSignature(source); + var targetType = i < targetMax ? getTypeOfParameter(targetParams[i]) : getRestTypeOfSignature(target); + var sourceSig = getSingleCallSignature(getNonNullableType(sourceType)); + var targetSig = getSingleCallSignature(getNonNullableType(targetType)); + // In order to ensure that any generic type Foo is at least co-variant with respect to T no matter + // how Foo uses T, we need to relate parameters bi-variantly (given that parameters are input positions, + // they naturally relate only contra-variantly). However, if the source and target parameters both have + // function types with a single call signature, we known we are relating two callback parameters. In + // that case it is sufficient to only relate the parameters of the signatures co-variantly because, + // similar to return values, callback parameters are output positions. This means that a Promise, + // where T is used only in callback parameter positions, will be co-variant (as opposed to bi-variant) + // with respect to T. + var callbacks = sourceSig && targetSig && !sourceSig.typePredicate && !targetSig.typePredicate && + (getFalsyFlags(sourceType) & 6144 /* Nullable */) === (getFalsyFlags(targetType) & 6144 /* Nullable */); + var related = callbacks ? + compareSignaturesRelated(targetSig, sourceSig, /*checkAsCallback*/ true, /*ignoreReturnTypes*/ false, reportErrors, errorReporter, compareTypes) : + !checkAsCallback && compareTypes(sourceType, targetType, /*reportErrors*/ false) || compareTypes(targetType, sourceType, reportErrors); if (!related) { if (reportErrors) { errorReporter(ts.Diagnostics.Types_of_parameters_0_and_1_are_incompatible, sourceParams[i < sourceMax ? i : sourceMax].name, targetParams[i < targetMax ? i : targetMax].name); @@ -33016,7 +34489,11 @@ var ts; } } else { - result &= compareTypes(sourceReturnType, targetReturnType, reportErrors); + // When relating callback signatures, we still need to relate return types bi-variantly as otherwise + // the containing type wouldn't be co-variant. For example, interface Foo { add(cb: () => T): void } + // wouldn't be co-variant for T without this rule. + result &= checkAsCallback && compareTypes(targetReturnType, sourceReturnType, /*reportErrors*/ false) || + compareTypes(sourceReturnType, targetReturnType, reportErrors); } } return result; @@ -33092,33 +34569,32 @@ var ts; } function isEmptyObjectType(type) { return type.flags & 32768 /* Object */ ? isEmptyResolvedType(resolveStructuredTypeMembers(type)) : - type.flags & 65536 /* Union */ ? ts.forEach(type.types, isEmptyObjectType) : - type.flags & 131072 /* Intersection */ ? !ts.forEach(type.types, function (t) { return !isEmptyObjectType(t); }) : - false; + type.flags & 16777216 /* NonPrimitive */ ? true : + type.flags & 65536 /* Union */ ? ts.forEach(type.types, isEmptyObjectType) : + type.flags & 131072 /* Intersection */ ? !ts.forEach(type.types, function (t) { return !isEmptyObjectType(t); }) : + false; } - function isEnumTypeRelatedTo(source, target, errorReporter) { - if (source === target) { + function isEnumTypeRelatedTo(sourceSymbol, targetSymbol, errorReporter) { + if (sourceSymbol === targetSymbol) { return true; } - var id = source.id + "," + target.id; + var id = getSymbolId(sourceSymbol) + "," + getSymbolId(targetSymbol); var relation = enumRelation.get(id); if (relation !== undefined) { return relation; } - if (source.symbol.name !== target.symbol.name || - !(source.symbol.flags & 256 /* RegularEnum */) || !(target.symbol.flags & 256 /* RegularEnum */) || - (source.flags & 65536 /* Union */) !== (target.flags & 65536 /* Union */)) { + if (sourceSymbol.name !== targetSymbol.name || !(sourceSymbol.flags & 256 /* RegularEnum */) || !(targetSymbol.flags & 256 /* RegularEnum */)) { enumRelation.set(id, false); return false; } - var targetEnumType = getTypeOfSymbol(target.symbol); - for (var _i = 0, _a = getPropertiesOfType(getTypeOfSymbol(source.symbol)); _i < _a.length; _i++) { + var targetEnumType = getTypeOfSymbol(targetSymbol); + for (var _i = 0, _a = getPropertiesOfType(getTypeOfSymbol(sourceSymbol)); _i < _a.length; _i++) { var property = _a[_i]; if (property.flags & 8 /* EnumMember */) { var targetProperty = getPropertyOfType(targetEnumType, property.name); if (!targetProperty || !(targetProperty.flags & 8 /* EnumMember */)) { if (errorReporter) { - errorReporter(ts.Diagnostics.Property_0_is_missing_in_type_1, property.name, typeToString(target, /*enclosingDeclaration*/ undefined, 128 /* UseFullyQualifiedType */)); + errorReporter(ts.Diagnostics.Property_0_is_missing_in_type_1, property.name, typeToString(getDeclaredTypeOfSymbol(targetSymbol), /*enclosingDeclaration*/ undefined, 256 /* UseFullyQualifiedType */)); } enumRelation.set(id, false); return false; @@ -33129,42 +34605,50 @@ var ts; return true; } function isSimpleTypeRelatedTo(source, target, relation, errorReporter) { - if (target.flags & 8192 /* Never */) + var s = source.flags; + var t = target.flags; + if (t & 8192 /* Never */) return false; - if (target.flags & 1 /* Any */ || source.flags & 8192 /* Never */) + if (t & 1 /* Any */ || s & 8192 /* Never */) return true; - if (source.flags & 262178 /* StringLike */ && target.flags & 2 /* String */) + if (s & 262178 /* StringLike */ && t & 2 /* String */) return true; - if (source.flags & 340 /* NumberLike */ && target.flags & 4 /* Number */) + if (s & 32 /* StringLiteral */ && s & 256 /* EnumLiteral */ && + t & 32 /* StringLiteral */ && !(t & 256 /* EnumLiteral */) && + source.value === target.value) return true; - if (source.flags & 136 /* BooleanLike */ && target.flags & 8 /* Boolean */) + if (s & 84 /* NumberLike */ && t & 4 /* Number */) return true; - if (source.flags & 256 /* EnumLiteral */ && target.flags & 16 /* Enum */ && source.baseType === target) + if (s & 64 /* NumberLiteral */ && s & 256 /* EnumLiteral */ && + t & 64 /* NumberLiteral */ && !(t & 256 /* EnumLiteral */) && + source.value === target.value) return true; - if (source.flags & 16 /* Enum */ && target.flags & 16 /* Enum */ && isEnumTypeRelatedTo(source, target, errorReporter)) + if (s & 136 /* BooleanLike */ && t & 8 /* Boolean */) return true; - if (source.flags & 2048 /* Undefined */ && (!strictNullChecks || target.flags & (2048 /* Undefined */ | 1024 /* Void */))) + if (s & 16 /* Enum */ && t & 16 /* Enum */ && isEnumTypeRelatedTo(source.symbol, target.symbol, errorReporter)) + return true; + if (s & 256 /* EnumLiteral */ && t & 256 /* EnumLiteral */) { + if (s & 65536 /* Union */ && t & 65536 /* Union */ && isEnumTypeRelatedTo(source.symbol, target.symbol, errorReporter)) + return true; + if (s & 224 /* Literal */ && t & 224 /* Literal */ && + source.value === target.value && + isEnumTypeRelatedTo(getParentOfSymbol(source.symbol), getParentOfSymbol(target.symbol), errorReporter)) + return true; + } + if (s & 2048 /* Undefined */ && (!strictNullChecks || t & (2048 /* Undefined */ | 1024 /* Void */))) return true; - if (source.flags & 4096 /* Null */ && (!strictNullChecks || target.flags & 4096 /* Null */)) + if (s & 4096 /* Null */ && (!strictNullChecks || t & 4096 /* Null */)) return true; - if (source.flags & 32768 /* Object */ && target.flags & 16777216 /* NonPrimitive */) + if (s & 32768 /* Object */ && t & 16777216 /* NonPrimitive */) return true; if (relation === assignableRelation || relation === comparableRelation) { - if (source.flags & 1 /* Any */) + if (s & 1 /* Any */) return true; - if ((source.flags & 4 /* Number */ | source.flags & 64 /* NumberLiteral */) && target.flags & 272 /* EnumLike */) + // Type number or any numeric literal type is assignable to any numeric enum type or any + // numeric enum literal type. This rule exists for backwards compatibility reasons because + // bit-flag enum types sometimes look like literal enum types with numeric literal values. + if (s & (4 /* Number */ | 64 /* NumberLiteral */) && !(s & 256 /* EnumLiteral */) && (t & 16 /* Enum */ || t & 64 /* NumberLiteral */ && t & 256 /* EnumLiteral */)) return true; - if (source.flags & 256 /* EnumLiteral */ && - target.flags & 256 /* EnumLiteral */ && - source.text === target.text && - isEnumTypeRelatedTo(source.baseType, target.baseType, errorReporter)) { - return true; - } - if (source.flags & 256 /* EnumLiteral */ && - target.flags & 16 /* Enum */ && - isEnumTypeRelatedTo(target, source.baseType, errorReporter)) { - return true; - } } return false; } @@ -33208,6 +34692,7 @@ var ts; var expandingFlags; var depth = 0; var overflow = false; + var isIntersectionConstituent = false; ts.Debug.assert(relation !== identityRelation || !errorNode, "no error reporting in identity checking"); var result = isRelatedTo(source, target, /*reportErrors*/ !!errorNode, headMessage); if (overflow) { @@ -33228,8 +34713,8 @@ var ts; var sourceType = typeToString(source); var targetType = typeToString(target); if (sourceType === targetType) { - sourceType = typeToString(source, /*enclosingDeclaration*/ undefined, 128 /* UseFullyQualifiedType */); - targetType = typeToString(target, /*enclosingDeclaration*/ undefined, 128 /* UseFullyQualifiedType */); + sourceType = typeToString(source, /*enclosingDeclaration*/ undefined, 256 /* UseFullyQualifiedType */); + targetType = typeToString(target, /*enclosingDeclaration*/ undefined, 256 /* UseFullyQualifiedType */); } if (!message) { if (relation === comparableRelation) { @@ -33280,7 +34765,6 @@ var ts; * * Ternary.False if they are not related. */ function isRelatedTo(source, target, reportErrors, headMessage) { - var result; if (source.flags & 96 /* StringOrNumberLiteral */ && source.flags & 1048576 /* FreshLiteral */) { source = source.regularType; } @@ -33310,31 +34794,38 @@ var ts; source = getRegularTypeOfObjectLiteral(source); } } + if (relation !== comparableRelation && + !(source.flags & 196608 /* UnionOrIntersection */) && + !(target.flags & 65536 /* Union */) && + !isIntersectionConstituent && + source !== globalObjectType && + getPropertiesOfType(source).length > 0 && + isWeakType(target) && + !hasCommonProperties(source, target)) { + if (reportErrors) { + reportError(ts.Diagnostics.Type_0_has_no_properties_in_common_with_type_1, typeToString(source), typeToString(target)); + } + return 0 /* False */; + } + var result = 0 /* False */; var saveErrorInfo = errorInfo; + var saveIsIntersectionConstituent = isIntersectionConstituent; + isIntersectionConstituent = false; // Note that these checks are specifically ordered to produce correct results. In particular, // we need to deconstruct unions before intersections (because unions are always at the top), // and we need to handle "each" relations before "some" relations for the same kind of type. if (source.flags & 65536 /* Union */) { - if (relation === comparableRelation) { - result = someTypeRelatedToType(source, target, reportErrors && !(source.flags & 8190 /* Primitive */)); - } - else { - result = eachTypeRelatedToType(source, target, reportErrors && !(source.flags & 8190 /* Primitive */)); - } - if (result) { - return result; - } + result = relation === comparableRelation ? + someTypeRelatedToType(source, target, reportErrors && !(source.flags & 8190 /* Primitive */)) : + eachTypeRelatedToType(source, target, reportErrors && !(source.flags & 8190 /* Primitive */)); } else { if (target.flags & 65536 /* Union */) { - if (result = typeRelatedToSomeType(source, target, reportErrors && !(source.flags & 8190 /* Primitive */) && !(target.flags & 8190 /* Primitive */))) { - return result; - } + result = typeRelatedToSomeType(source, target, reportErrors && !(source.flags & 8190 /* Primitive */) && !(target.flags & 8190 /* Primitive */)); } else if (target.flags & 131072 /* Intersection */) { - if (result = typeRelatedToEachType(source, target, reportErrors)) { - return result; - } + isIntersectionConstituent = true; + result = typeRelatedToEachType(source, target, reportErrors); } else if (source.flags & 131072 /* Intersection */) { // Check to see if any constituents of the intersection are immediately related to the target. @@ -33350,18 +34841,16 @@ var ts; // // - For a primitive type or type parameter (such as 'number = A & B') there is no point in // breaking the intersection apart. - if (result = someTypeRelatedToType(source, target, /*reportErrors*/ false)) { - return result; - } + result = someTypeRelatedToType(source, target, /*reportErrors*/ false); } - if (source.flags & 1032192 /* StructuredOrTypeVariable */ || target.flags & 1032192 /* StructuredOrTypeVariable */) { + if (!result && (source.flags & 1032192 /* StructuredOrTypeVariable */ || target.flags & 1032192 /* StructuredOrTypeVariable */)) { if (result = recursiveTypeRelatedTo(source, target, reportErrors)) { errorInfo = saveErrorInfo; - return result; } } } - if (reportErrors) { + isIntersectionConstituent = saveIsIntersectionConstituent; + if (!result && reportErrors) { if (source.flags & 32768 /* Object */ && target.flags & 8190 /* Primitive */) { tryElaborateErrorsForPrimitivesAndObjects(source, target); } @@ -33370,7 +34859,7 @@ var ts; } reportRelationError(headMessage, source, target); } - return 0 /* False */; + return result; } function isIdenticalTo(source, target) { var result; @@ -33394,8 +34883,7 @@ var ts; (isTypeSubsetOf(globalObjectType, target) || (!isComparingJsxAttributes && isEmptyObjectType(target)))) { return false; } - for (var _i = 0, _a = getPropertiesOfObjectType(source); _i < _a.length; _i++) { - var prop = _a[_i]; + var _loop_4 = function (prop) { if (!isKnownProperty(target, prop.name, isComparingJsxAttributes)) { if (reportErrors) { // We know *exactly* where things went wrong when comparing the types. @@ -33408,12 +34896,22 @@ var ts; reportError(ts.Diagnostics.Property_0_does_not_exist_on_type_1, symbolToString(prop), typeToString(target)); } else { - errorNode = prop.valueDeclaration; + // use the property's value declaration if the property is assigned inside the literal itself + var objectLiteralDeclaration_1 = source.symbol && ts.firstOrUndefined(source.symbol.declarations); + if (prop.valueDeclaration && ts.findAncestor(prop.valueDeclaration, function (d) { return d === objectLiteralDeclaration_1; })) { + errorNode = prop.valueDeclaration; + } reportError(ts.Diagnostics.Object_literal_may_only_specify_known_properties_and_0_does_not_exist_in_type_1, symbolToString(prop), typeToString(target)); } } - return true; + return { value: true }; } + }; + for (var _i = 0, _a = getPropertiesOfObjectType(source); _i < _a.length; _i++) { + var prop = _a[_i]; + var state_2 = _loop_4(prop); + if (typeof state_2 === "object") + return state_2.value; } } return false; @@ -33775,10 +35273,10 @@ var ts; } } else if (!(targetProp.flags & 16777216 /* Prototype */)) { - var sourcePropFlags = getDeclarationModifierFlagsFromSymbol(sourceProp); - var targetPropFlags = getDeclarationModifierFlagsFromSymbol(targetProp); + var sourcePropFlags = ts.getDeclarationModifierFlagsFromSymbol(sourceProp); + var targetPropFlags = ts.getDeclarationModifierFlagsFromSymbol(targetProp); if (sourcePropFlags & 8 /* Private */ || targetPropFlags & 8 /* Private */) { - if (getCheckFlags(sourceProp) & 256 /* ContainsPrivate */) { + if (ts.getCheckFlags(sourceProp) & 256 /* ContainsPrivate */) { if (reportErrors) { reportError(ts.Diagnostics.Property_0_has_conflicting_declarations_and_is_inaccessible_in_type_1, symbolToString(sourceProp), typeToString(source)); } @@ -33837,6 +35335,33 @@ var ts; } return result; } + /** + * A type is 'weak' if it is an object type with at least one optional property + * and no required properties, call/construct signatures or index signatures + */ + function isWeakType(type) { + if (type.flags & 32768 /* Object */) { + var resolved = resolveStructuredTypeMembers(type); + return resolved.callSignatures.length === 0 && resolved.constructSignatures.length === 0 && + !resolved.stringIndexInfo && !resolved.numberIndexInfo && + resolved.properties.length > 0 && + ts.every(resolved.properties, function (p) { return !!(p.flags & 67108864 /* Optional */); }); + } + if (type.flags & 131072 /* Intersection */) { + return ts.every(type.types, isWeakType); + } + return false; + } + function hasCommonProperties(source, target) { + var isComparingJsxAttributes = !!(source.flags & 33554432 /* JsxAttributes */); + for (var _i = 0, _a = getPropertiesOfType(source); _i < _a.length; _i++) { + var prop = _a[_i]; + if (isKnownProperty(target, prop.name, isComparingJsxAttributes)) { + return true; + } + } + return false; + } function propertiesIdenticalTo(source, target) { if (!(source.flags & 32768 /* Object */ && target.flags & 32768 /* Object */)) { return 0 /* False */; @@ -33888,17 +35413,27 @@ var ts; var result = -1 /* True */; var saveErrorInfo = errorInfo; if (getObjectFlags(source) & 64 /* Instantiated */ && getObjectFlags(target) & 64 /* Instantiated */ && source.symbol === target.symbol) { - // We instantiations of the same anonymous type (which typically will be the type of a method). - // Simply do a pairwise comparison of the signatures in the two signature lists instead of the - // much more expensive N * M comparison matrix we explore below. + // We have instantiations of the same anonymous type (which typically will be the type of a + // method). Simply do a pairwise comparison of the signatures in the two signature lists instead + // of the much more expensive N * M comparison matrix we explore below. We erase type parameters + // as they are known to always be the same. for (var i = 0; i < targetSignatures.length; i++) { - var related = signatureRelatedTo(sourceSignatures[i], targetSignatures[i], reportErrors); + var related = signatureRelatedTo(sourceSignatures[i], targetSignatures[i], /*erase*/ true, reportErrors); if (!related) { return 0 /* False */; } result &= related; } } + else if (sourceSignatures.length === 1 && targetSignatures.length === 1) { + // For simple functions (functions with a single signature) we only erase type parameters for + // the comparable relation. Otherwise, if the source signature is generic, we instantiate it + // in the context of the target signature before checking the relationship. Ideally we'd do + // this regardless of the number of signatures, but the potential costs are prohibitive due + // to the quadratic nature of the logic below. + var eraseGenerics = relation === comparableRelation || compilerOptions.noStrictGenericChecks; + result = signatureRelatedTo(sourceSignatures[0], targetSignatures[0], eraseGenerics, reportErrors); + } else { outer: for (var _i = 0, targetSignatures_1 = targetSignatures; _i < targetSignatures_1.length; _i++) { var t = targetSignatures_1[_i]; @@ -33906,7 +35441,7 @@ var ts; var shouldElaborateErrors = reportErrors; for (var _a = 0, sourceSignatures_1 = sourceSignatures; _a < sourceSignatures_1.length; _a++) { var s = sourceSignatures_1[_a]; - var related = signatureRelatedTo(s, t, shouldElaborateErrors); + var related = signatureRelatedTo(s, t, /*erase*/ true, shouldElaborateErrors); if (related) { result &= related; errorInfo = saveErrorInfo; @@ -33925,8 +35460,9 @@ var ts; /** * See signatureAssignableTo, compareSignaturesIdentical */ - function signatureRelatedTo(source, target, reportErrors) { - return compareSignaturesRelated(source, target, /*ignoreReturnTypes*/ false, reportErrors, reportError, isRelatedTo); + function signatureRelatedTo(source, target, erase, reportErrors) { + return compareSignaturesRelated(erase ? getErasedSignature(source) : source, erase ? getErasedSignature(target) : target, + /*checkAsCallback*/ false, /*ignoreReturnTypes*/ false, reportErrors, reportError, isRelatedTo); } function signaturesIdenticalTo(source, target, kind) { var sourceSignatures = getSignaturesOfType(source, kind); @@ -34038,7 +35574,7 @@ var ts; // Invoke the callback for each underlying property symbol of the given symbol and return the first // value that isn't undefined. function forEachProperty(prop, callback) { - if (getCheckFlags(prop) & 6 /* Synthetic */) { + if (ts.getCheckFlags(prop) & 6 /* Synthetic */) { for (var _i = 0, _a = prop.containingType.types; _i < _a.length; _i++) { var t = _a[_i]; var p = getPropertyOfType(t, prop.name); @@ -34065,13 +35601,13 @@ var ts; } // Return true if source property is a valid override of protected parts of target property. function isValidOverrideOf(sourceProp, targetProp) { - return !forEachProperty(targetProp, function (tp) { return getDeclarationModifierFlagsFromSymbol(tp) & 16 /* Protected */ ? + return !forEachProperty(targetProp, function (tp) { return ts.getDeclarationModifierFlagsFromSymbol(tp) & 16 /* Protected */ ? !isPropertyInClassDerivedFrom(sourceProp, getDeclaringClass(tp)) : false; }); } // Return true if the given class derives from each of the declaring classes of the protected // constituents of the given property. function isClassDerivedFromDeclaringClasses(checkClass, prop) { - return forEachProperty(prop, function (p) { return getDeclarationModifierFlagsFromSymbol(p) & 16 /* Protected */ ? + return forEachProperty(prop, function (p) { return ts.getDeclarationModifierFlagsFromSymbol(p) & 16 /* Protected */ ? !hasBaseType(checkClass, getDeclaringClass(p)) : false; }) ? undefined : checkClass; } // Return true if the given type is the constructor type for an abstract class @@ -34120,8 +35656,8 @@ var ts; if (sourceProp === targetProp) { return -1 /* True */; } - var sourcePropAccessibility = getDeclarationModifierFlagsFromSymbol(sourceProp) & 24 /* NonPublicAccessibilityModifier */; - var targetPropAccessibility = getDeclarationModifierFlagsFromSymbol(targetProp) & 24 /* NonPublicAccessibilityModifier */; + var sourcePropAccessibility = ts.getDeclarationModifierFlagsFromSymbol(sourceProp) & 24 /* NonPublicAccessibilityModifier */; + var targetPropAccessibility = ts.getDeclarationModifierFlagsFromSymbol(targetProp) & 24 /* NonPublicAccessibilityModifier */; if (sourcePropAccessibility !== targetPropAccessibility) { return 0 /* False */; } @@ -34214,18 +35750,10 @@ var ts; function isRestParameterIndex(signature, parameterIndex) { return signature.hasRestParameter && parameterIndex >= signature.parameters.length - 1; } - function isSupertypeOfEach(candidate, types) { - for (var _i = 0, types_10 = types; _i < types_10.length; _i++) { - var t = types_10[_i]; - if (candidate !== t && !isTypeSubtypeOf(t, candidate)) - return false; - } - return true; - } function literalTypesWithSameBaseType(types) { var commonBaseType; - for (var _i = 0, types_11 = types; _i < types_11.length; _i++) { - var t = types_11[_i]; + for (var _i = 0, types_9 = types; _i < types_9.length; _i++) { + var t = types_9[_i]; var baseType = getBaseTypeOfLiteralType(t); if (!commonBaseType) { commonBaseType = baseType; @@ -34236,55 +35764,22 @@ var ts; } return true; } - // When the candidate types are all literal types with the same base type, the common - // supertype is a union of those literal types. Otherwise, the common supertype is the - // first type that is a supertype of each of the other types. + // When the candidate types are all literal types with the same base type, return a union + // of those literal types. Otherwise, return the leftmost type for which no type to the + // right is a supertype. function getSupertypeOrUnion(types) { - return literalTypesWithSameBaseType(types) ? getUnionType(types) : ts.forEach(types, function (t) { return isSupertypeOfEach(t, types) ? t : undefined; }); + return literalTypesWithSameBaseType(types) ? + getUnionType(types) : + ts.reduceLeft(types, function (s, t) { return isTypeSubtypeOf(s, t) ? t : s; }); } function getCommonSupertype(types) { if (!strictNullChecks) { return getSupertypeOrUnion(types); } var primaryTypes = ts.filter(types, function (t) { return !(t.flags & 6144 /* Nullable */); }); - if (!primaryTypes.length) { - return getUnionType(types, /*subtypeReduction*/ true); - } - var supertype = getSupertypeOrUnion(primaryTypes); - return supertype && includeFalsyTypes(supertype, getFalsyFlagsOfTypes(types) & 6144 /* Nullable */); - } - function reportNoCommonSupertypeError(types, errorLocation, errorMessageChainHead) { - // The downfallType/bestSupertypeDownfallType is the first type that caused a particular candidate - // to not be the common supertype. So if it weren't for this one downfallType (and possibly others), - // the type in question could have been the common supertype. - var bestSupertype; - var bestSupertypeDownfallType; - var bestSupertypeScore = 0; - for (var i = 0; i < types.length; i++) { - var score = 0; - var downfallType = undefined; - for (var j = 0; j < types.length; j++) { - if (isTypeSubtypeOf(types[j], types[i])) { - score++; - } - else if (!downfallType) { - downfallType = types[j]; - } - } - ts.Debug.assert(!!downfallType, "If there is no common supertype, each type should have a downfallType"); - if (score > bestSupertypeScore) { - bestSupertype = types[i]; - bestSupertypeDownfallType = downfallType; - bestSupertypeScore = score; - } - // types.length - 1 is the maximum score, given that getCommonSupertype returned false - if (bestSupertypeScore === types.length - 1) { - break; - } - } - // In the following errors, the {1} slot is before the {0} slot because checkTypeSubtypeOf supplies the - // subtype as the first argument to the error - checkTypeSubtypeOf(bestSupertypeDownfallType, bestSupertype, errorLocation, ts.Diagnostics.Type_argument_candidate_1_is_not_a_valid_type_argument_because_it_is_not_a_supertype_of_candidate_0, errorMessageChainHead); + return primaryTypes.length ? + getNullableType(getSupertypeOrUnion(primaryTypes), getFalsyFlagsOfTypes(types) & 6144 /* Nullable */) : + getUnionType(types, /*subtypeReduction*/ true); } function isArrayType(type) { return getObjectFlags(type) & 4 /* Reference */ && type.target === globalArrayType; @@ -34299,27 +35794,27 @@ var ts; return !!getPropertyOfType(type, "0"); } function isUnitType(type) { - return (type.flags & (480 /* Literal */ | 2048 /* Undefined */ | 4096 /* Null */)) !== 0; + return (type.flags & (224 /* Literal */ | 2048 /* Undefined */ | 4096 /* Null */)) !== 0; } function isLiteralType(type) { return type.flags & 8 /* Boolean */ ? true : - type.flags & 65536 /* Union */ ? type.flags & 16 /* Enum */ ? true : !ts.forEach(type.types, function (t) { return !isUnitType(t); }) : + type.flags & 65536 /* Union */ ? type.flags & 256 /* EnumLiteral */ ? true : !ts.forEach(type.types, function (t) { return !isUnitType(t); }) : isUnitType(type); } function getBaseTypeOfLiteralType(type) { - return type.flags & 32 /* StringLiteral */ ? stringType : - type.flags & 64 /* NumberLiteral */ ? numberType : - type.flags & 128 /* BooleanLiteral */ ? booleanType : - type.flags & 256 /* EnumLiteral */ ? type.baseType : - type.flags & 65536 /* Union */ && !(type.flags & 16 /* Enum */) ? getUnionType(ts.sameMap(type.types, getBaseTypeOfLiteralType)) : + return type.flags & 256 /* EnumLiteral */ ? getBaseTypeOfEnumLiteralType(type) : + type.flags & 32 /* StringLiteral */ ? stringType : + type.flags & 64 /* NumberLiteral */ ? numberType : + type.flags & 128 /* BooleanLiteral */ ? booleanType : + type.flags & 65536 /* Union */ ? getUnionType(ts.sameMap(type.types, getBaseTypeOfLiteralType)) : type; } function getWidenedLiteralType(type) { - return type.flags & 32 /* StringLiteral */ && type.flags & 1048576 /* FreshLiteral */ ? stringType : - type.flags & 64 /* NumberLiteral */ && type.flags & 1048576 /* FreshLiteral */ ? numberType : - type.flags & 128 /* BooleanLiteral */ ? booleanType : - type.flags & 256 /* EnumLiteral */ ? type.baseType : - type.flags & 65536 /* Union */ && !(type.flags & 16 /* Enum */) ? getUnionType(ts.sameMap(type.types, getWidenedLiteralType)) : + return type.flags & 256 /* EnumLiteral */ ? getBaseTypeOfEnumLiteralType(type) : + type.flags & 32 /* StringLiteral */ && type.flags & 1048576 /* FreshLiteral */ ? stringType : + type.flags & 64 /* NumberLiteral */ && type.flags & 1048576 /* FreshLiteral */ ? numberType : + type.flags & 128 /* BooleanLiteral */ ? booleanType : + type.flags & 65536 /* Union */ ? getUnionType(ts.sameMap(type.types, getWidenedLiteralType)) : type; } /** @@ -34331,8 +35826,8 @@ var ts; } function getFalsyFlagsOfTypes(types) { var result = 0; - for (var _i = 0, types_12 = types; _i < types_12.length; _i++) { - var t = types_12[_i]; + for (var _i = 0, types_10 = types; _i < types_10.length; _i++) { + var t = types_10[_i]; result |= getFalsyFlags(t); } return result; @@ -34342,35 +35837,35 @@ var ts; // no flags for all other types (including non-falsy literal types). function getFalsyFlags(type) { return type.flags & 65536 /* Union */ ? getFalsyFlagsOfTypes(type.types) : - type.flags & 32 /* StringLiteral */ ? type.text === "" ? 32 /* StringLiteral */ : 0 : - type.flags & 64 /* NumberLiteral */ ? type.text === "0" ? 64 /* NumberLiteral */ : 0 : + type.flags & 32 /* StringLiteral */ ? type.value === "" ? 32 /* StringLiteral */ : 0 : + type.flags & 64 /* NumberLiteral */ ? type.value === 0 ? 64 /* NumberLiteral */ : 0 : type.flags & 128 /* BooleanLiteral */ ? type === falseType ? 128 /* BooleanLiteral */ : 0 : type.flags & 7406 /* PossiblyFalsy */; } - function includeFalsyTypes(type, flags) { - if ((getFalsyFlags(type) & flags) === flags) { - return type; - } - var types = [type]; - if (flags & 262178 /* StringLike */) - types.push(emptyStringType); - if (flags & 340 /* NumberLike */) - types.push(zeroType); - if (flags & 136 /* BooleanLike */) - types.push(falseType); - if (flags & 1024 /* Void */) - types.push(voidType); - if (flags & 2048 /* Undefined */) - types.push(undefinedType); - if (flags & 4096 /* Null */) - types.push(nullType); - return getUnionType(types); - } function removeDefinitelyFalsyTypes(type) { return getFalsyFlags(type) & 7392 /* DefinitelyFalsy */ ? filterType(type, function (t) { return !(getFalsyFlags(t) & 7392 /* DefinitelyFalsy */); }) : type; } + function extractDefinitelyFalsyTypes(type) { + return mapType(type, getDefinitelyFalsyPartOfType); + } + function getDefinitelyFalsyPartOfType(type) { + return type.flags & 2 /* String */ ? emptyStringType : + type.flags & 4 /* Number */ ? zeroType : + type.flags & 8 /* Boolean */ || type === falseType ? falseType : + type.flags & (1024 /* Void */ | 2048 /* Undefined */ | 4096 /* Null */) || + type.flags & 32 /* StringLiteral */ && type.value === "" || + type.flags & 64 /* NumberLiteral */ && type.value === 0 ? type : + neverType; + } + function getNullableType(type, flags) { + var missing = (flags & ~type.flags) & (2048 /* Undefined */ | 4096 /* Null */); + return missing === 0 ? type : + missing === 2048 /* Undefined */ ? getUnionType([type, undefinedType]) : + missing === 4096 /* Null */ ? getUnionType([type, nullType]) : + getUnionType([type, undefinedType, nullType]); + } function getNonNullableType(type) { return strictNullChecks ? getTypeWithFacts(type, 524288 /* NEUndefinedOrNull */) : type; } @@ -34567,22 +36062,42 @@ var ts; callback(getTypeAtPosition(source, i), getTypeAtPosition(target, i)); } } - function createInferenceContext(signature, inferUnionTypes, useAnyForNoInferences) { - var inferences = ts.map(signature.typeParameters, createTypeInferencesObject); + function createInferenceContext(signature, flags, baseInferences) { + var inferences = baseInferences ? ts.map(baseInferences, cloneInferenceInfo) : ts.map(signature.typeParameters, createInferenceInfo); + var context = mapper; + context.mappedTypes = signature.typeParameters; + context.signature = signature; + context.inferences = inferences; + context.flags = flags; + return context; + function mapper(t) { + for (var i = 0; i < inferences.length; i++) { + if (t === inferences[i].typeParameter) { + inferences[i].isFixed = true; + return getInferredType(context, i); + } + } + return t; + } + } + function createInferenceInfo(typeParameter) { return { - signature: signature, - inferUnionTypes: inferUnionTypes, - inferences: inferences, - inferredTypes: new Array(signature.typeParameters.length), - useAnyForNoInferences: useAnyForNoInferences + typeParameter: typeParameter, + candidates: undefined, + inferredType: undefined, + priority: undefined, + topLevel: true, + isFixed: false }; } - function createTypeInferencesObject() { + function cloneInferenceInfo(inference) { return { - primary: undefined, - secondary: undefined, - topLevel: true, - isFixed: false, + typeParameter: inference.typeParameter, + candidates: inference.candidates && inference.candidates.slice(), + inferredType: inference.inferredType, + priority: inference.priority, + topLevel: inference.topLevel, + isFixed: inference.isFixed }; } // Return true if the given type could possibly reference a type parameter for which @@ -34592,7 +36107,7 @@ var ts; var objectFlags = getObjectFlags(type); return !!(type.flags & 540672 /* TypeVariable */ || objectFlags & 4 /* Reference */ && ts.forEach(type.typeArguments, couldContainTypeVariables) || - objectFlags & 16 /* Anonymous */ && type.symbol && type.symbol.flags & (8192 /* Method */ | 2048 /* TypeLiteral */ | 32 /* Class */) || + objectFlags & 16 /* Anonymous */ && type.symbol && type.symbol.flags & (16 /* Function */ | 8192 /* Method */ | 2048 /* TypeLiteral */ | 32 /* Class */) || objectFlags & 32 /* Mapped */ || type.flags & 196608 /* UnionOrIntersection */ && couldUnionOrIntersectionContainTypeVariables(type)); } @@ -34615,14 +36130,13 @@ var ts; if (properties.length === 0 && !indexInfo) { return undefined; } - var typeVariable = getIndexedAccessType(getConstraintTypeFromMappedType(target).type, getTypeParameterFromMappedType(target)); - var typeVariableArray = [typeVariable]; - var typeInferences = createTypeInferencesObject(); - var typeInferencesArray = [typeInferences]; + var typeParameter = getIndexedAccessType(getConstraintTypeFromMappedType(target).type, getTypeParameterFromMappedType(target)); + var inference = createInferenceInfo(typeParameter); + var inferences = [inference]; var templateType = getTemplateTypeFromMappedType(target); var readonlyMask = target.declaration.readonlyToken ? false : true; var optionalMask = target.declaration.questionToken ? 0 : 67108864 /* Optional */; - var members = createSymbolTable(properties); + var members = ts.createMap(); for (var _i = 0, properties_5 = properties; _i < properties_5.length; _i++) { var prop = properties_5[_i]; var inferredPropType = inferTargetType(getTypeOfSymbol(prop)); @@ -34644,31 +36158,16 @@ var ts; } return createAnonymousType(undefined, members, emptyArray, emptyArray, indexInfo, undefined); function inferTargetType(sourceType) { - typeInferences.primary = undefined; - typeInferences.secondary = undefined; - inferTypes(typeVariableArray, typeInferencesArray, sourceType, templateType); - var inferences = typeInferences.primary || typeInferences.secondary; - return inferences && getUnionType(inferences, /*subtypeReduction*/ true); + inference.candidates = undefined; + inferTypes(inferences, sourceType, templateType); + return inference.candidates && getUnionType(inference.candidates, /*subtypeReduction*/ true); } } - function inferTypesWithContext(context, originalSource, originalTarget) { - inferTypes(context.signature.typeParameters, context.inferences, originalSource, originalTarget); - } - function inferTypes(typeVariables, typeInferences, originalSource, originalTarget) { - var sourceStack; - var targetStack; - var depth = 0; - var inferiority = 0; - var visited = ts.createMap(); + function inferTypes(inferences, originalSource, originalTarget, priority) { + if (priority === void 0) { priority = 0; } + var symbolStack; + var visited; inferFromTypes(originalSource, originalTarget); - function isInProcess(source, target) { - for (var i = 0; i < depth; i++) { - if (source === sourceStack[i] && target === targetStack[i]) { - return true; - } - } - return false; - } function inferFromTypes(source, target) { if (!couldContainTypeVariables(target)) { return; @@ -34683,7 +36182,7 @@ var ts; } return; } - if (source.flags & 65536 /* Union */ && target.flags & 65536 /* Union */ && !(source.flags & 16 /* Enum */ && target.flags & 16 /* Enum */) || + if (source.flags & 65536 /* Union */ && target.flags & 65536 /* Union */ && !(source.flags & 256 /* EnumLiteral */ && target.flags & 256 /* EnumLiteral */) || source.flags & 131072 /* Intersection */ && target.flags & 131072 /* Intersection */) { // Source and target are both unions or both intersections. If source and target // are the same type, just relate each constituent type to itself. @@ -34728,32 +36227,26 @@ var ts; // Because the anyFunctionType is internal, it should not be exposed to the user by adding // it as an inference candidate. Hopefully, a better candidate will come along that does // not contain anyFunctionType when we come back to this argument for its second round - // of inference. - if (source.flags & 8388608 /* ContainsAnyFunctionType */) { + // of inference. Also, we exclude inferences for silentNeverType which is used as a wildcard + // when constructing types from type parameters that had no inference candidates. + if (source.flags & 8388608 /* ContainsAnyFunctionType */ || source === silentNeverType) { return; } - for (var i = 0; i < typeVariables.length; i++) { - if (target === typeVariables[i]) { - var inferences = typeInferences[i]; - if (!inferences.isFixed) { - // Any inferences that are made to a type parameter in a union type are inferior - // to inferences made to a flat (non-union) type. This is because if we infer to - // T | string[], we really don't know if we should be inferring to T or not (because - // the correct constituent on the target side could be string[]). Therefore, we put - // such inferior inferences into a secondary bucket, and only use them if the primary - // bucket is empty. - var candidates = inferiority ? - inferences.secondary || (inferences.secondary = []) : - inferences.primary || (inferences.primary = []); - if (!ts.contains(candidates, source)) { - candidates.push(source); - } - if (target.flags & 16384 /* TypeParameter */ && !isTypeParameterAtTopLevel(originalTarget, target)) { - inferences.topLevel = false; - } + var inference = getInferenceInfoForType(target); + if (inference) { + if (!inference.isFixed) { + if (!inference.candidates || priority < inference.priority) { + inference.candidates = [source]; + inference.priority = priority; + } + else if (priority === inference.priority) { + inference.candidates.push(source); + } + if (!(priority & 4 /* ReturnType */) && target.flags & 16384 /* TypeParameter */ && !isTypeParameterAtTopLevel(originalTarget, target)) { + inference.topLevel = false; } - return; } + return; } } else if (getObjectFlags(source) & 4 /* Reference */ && getObjectFlags(target) & 4 /* Reference */ && source.target === target.target) { @@ -34772,7 +36265,7 @@ var ts; // First infer to each type in union or intersection that isn't a type variable for (var _d = 0, targetTypes_3 = targetTypes; _d < targetTypes_3.length; _d++) { var t = targetTypes_3[_d]; - if (t.flags & 540672 /* TypeVariable */ && ts.contains(typeVariables, t)) { + if (getInferenceInfoForType(t)) { typeVariable = t; typeVariableCount++; } @@ -34784,9 +36277,10 @@ var ts; // variable. This gives meaningful results for union types in co-variant positions and intersection // types in contra-variant positions (such as callback parameters). if (typeVariableCount === 1) { - inferiority++; + var savePriority = priority; + priority |= 1 /* NakedTypeVariable */; inferFromTypes(source, typeVariable); - inferiority--; + priority = savePriority; } } else if (source.flags & 196608 /* UnionOrIntersection */) { @@ -34800,28 +36294,42 @@ var ts; else { source = getApparentType(source); if (source.flags & 32768 /* Object */) { - if (isInProcess(source, target)) { + var key = source.id + "," + target.id; + if (visited && visited.get(key)) { return; } - if (isDeeplyNestedType(source, sourceStack, depth) && isDeeplyNestedType(target, targetStack, depth)) { - return; + (visited || (visited = ts.createMap())).set(key, true); + // If we are already processing another target type with the same associated symbol (such as + // an instantiation of the same generic type), we do not explore this target as it would yield + // no further inferences. We exclude the static side of classes from this check since it shares + // its symbol with the instance side which would lead to false positives. + var isNonConstructorObject = target.flags & 32768 /* Object */ && + !(getObjectFlags(target) & 16 /* Anonymous */ && target.symbol && target.symbol.flags & 32 /* Class */); + var symbol = isNonConstructorObject ? target.symbol : undefined; + if (symbol) { + if (ts.contains(symbolStack, symbol)) { + return; + } + (symbolStack || (symbolStack = [])).push(symbol); + inferFromObjectTypes(source, target); + symbolStack.pop(); } - var key = source.id + "," + target.id; - if (visited.get(key)) { - return; + else { + inferFromObjectTypes(source, target); } - visited.set(key, true); - if (depth === 0) { - sourceStack = []; - targetStack = []; + } + } + } + function getInferenceInfoForType(type) { + if (type.flags & 540672 /* TypeVariable */) { + for (var _i = 0, inferences_1 = inferences; _i < inferences_1.length; _i++) { + var inference = inferences_1[_i]; + if (type === inference.typeParameter) { + return inference; } - sourceStack[depth] = source; - targetStack[depth] = target; - depth++; - inferFromObjectTypes(source, target); - depth--; } } + return undefined; } function inferFromObjectTypes(source, target) { if (getObjectFlags(target) & 32 /* Mapped */) { @@ -34831,13 +36339,14 @@ var ts; // where T is a type variable. Use inferTypeForHomomorphicMappedType to infer a suitable source // type and then make a secondary inference from that type to T. We make a secondary inference // such that direct inferences to T get priority over inferences to Partial, for example. - var index = ts.indexOf(typeVariables, constraintType.type); - if (index >= 0 && !typeInferences[index].isFixed) { + var inference = getInferenceInfoForType(constraintType.type); + if (inference && !inference.isFixed) { var inferredType = inferTypeForHomomorphicMappedType(source, target); if (inferredType) { - inferiority++; - inferFromTypes(inferredType, typeVariables[index]); - inferiority--; + var savePriority = priority; + priority |= 2 /* MappedType */; + inferFromTypes(inferredType, inference.typeParameter); + priority = savePriority; } } return; @@ -34908,8 +36417,8 @@ var ts; } } function typeIdenticalToSomeType(type, types) { - for (var _i = 0, types_13 = types; _i < types_13.length; _i++) { - var t = types_13[_i]; + for (var _i = 0, types_11 = types; _i < types_11.length; _i++) { + var t = types_11[_i]; if (isTypeIdenticalTo(t, type)) { return true; } @@ -34930,33 +36439,33 @@ var ts; } return type.flags & 65536 /* Union */ ? getUnionType(reducedTypes) : getIntersectionType(reducedTypes); } - function getInferenceCandidates(context, index) { - var inferences = context.inferences[index]; - return inferences.primary || inferences.secondary || emptyArray; - } function hasPrimitiveConstraint(type) { var constraint = getConstraintOfTypeParameter(type); return constraint && maybeTypeOfKind(constraint, 8190 /* Primitive */ | 262144 /* Index */); } function getInferredType(context, index) { - var inferredType = context.inferredTypes[index]; - var inferenceSucceeded; + var inference = context.inferences[index]; + var inferredType = inference.inferredType; if (!inferredType) { - var inferences = getInferenceCandidates(context, index); - if (inferences.length) { + if (inference.candidates) { // We widen inferred literal types if // all inferences were made to top-level ocurrences of the type parameter, and // the type parameter has no constraint or its constraint includes no primitive or literal types, and // the type parameter was fixed during inference or does not occur at top-level in the return type. var signature = context.signature; - var widenLiteralTypes = context.inferences[index].topLevel && - !hasPrimitiveConstraint(signature.typeParameters[index]) && - (context.inferences[index].isFixed || !isTypeParameterAtTopLevel(getReturnTypeOfSignature(signature), signature.typeParameters[index])); - var baseInferences = widenLiteralTypes ? ts.sameMap(inferences, getWidenedLiteralType) : inferences; - // Infer widened union or supertype, or the unknown type for no common supertype - var unionOrSuperType = context.inferUnionTypes ? getUnionType(baseInferences, /*subtypeReduction*/ true) : getCommonSupertype(baseInferences); - inferredType = unionOrSuperType ? getWidenedType(unionOrSuperType) : unknownType; - inferenceSucceeded = !!unionOrSuperType; + var widenLiteralTypes = inference.topLevel && + !hasPrimitiveConstraint(inference.typeParameter) && + (inference.isFixed || !isTypeParameterAtTopLevel(getReturnTypeOfSignature(signature), inference.typeParameter)); + var baseCandidates = widenLiteralTypes ? ts.sameMap(inference.candidates, getWidenedLiteralType) : inference.candidates; + // Infer widened union or supertype, or the unknown type for no common supertype. We infer union types + // for inferences coming from return types in order to avoid common supertype failures. + var unionOrSuperType = context.flags & 1 /* InferUnionTypes */ || inference.priority & 4 /* ReturnType */ ? + getUnionType(baseCandidates, /*subtypeReduction*/ true) : getCommonSupertype(baseCandidates); + inferredType = getWidenedType(unionOrSuperType); + } + else if (context.flags & 2 /* NoDefault */) { + // We use silentNeverType as the wildcard that signals no inferences. + inferredType = silentNeverType; } else { // Infer either the default or the empty object type when no inferences were @@ -34964,48 +36473,39 @@ var ts; // succeeds, meaning there is no error for not having inference candidates. An // inference error only occurs when there are *conflicting* candidates, i.e. // candidates with no common supertype. - var defaultType = getDefaultFromTypeParameter(context.signature.typeParameters[index]); + var defaultType = getDefaultFromTypeParameter(inference.typeParameter); if (defaultType) { // Instantiate the default type. Any forward reference to a type // parameter should be instantiated to the empty object type. - inferredType = instantiateType(defaultType, combineTypeMappers(createBackreferenceMapper(context.signature.typeParameters, index), getInferenceMapper(context))); + inferredType = instantiateType(defaultType, combineTypeMappers(createBackreferenceMapper(context.signature.typeParameters, index), context)); } else { - inferredType = context.useAnyForNoInferences ? anyType : emptyObjectType; + inferredType = context.flags & 4 /* AnyDefault */ ? anyType : emptyObjectType; } - inferenceSucceeded = true; } - context.inferredTypes[index] = inferredType; - // Only do the constraint check if inference succeeded (to prevent cascading errors) - if (inferenceSucceeded) { - var constraint = getConstraintOfTypeParameter(context.signature.typeParameters[index]); - if (constraint) { - var instantiatedConstraint = instantiateType(constraint, getInferenceMapper(context)); - if (!isTypeAssignableTo(inferredType, getTypeWithThisArgument(instantiatedConstraint, inferredType))) { - context.inferredTypes[index] = inferredType = instantiatedConstraint; - } + inference.inferredType = inferredType; + var constraint = getConstraintOfTypeParameter(context.signature.typeParameters[index]); + if (constraint) { + var instantiatedConstraint = instantiateType(constraint, context); + if (!isTypeAssignableTo(inferredType, getTypeWithThisArgument(instantiatedConstraint, inferredType))) { + inference.inferredType = inferredType = instantiatedConstraint; } } - else if (context.failedTypeParameterIndex === undefined || context.failedTypeParameterIndex > index) { - // If inference failed, it is necessary to record the index of the failed type parameter (the one we are on). - // It might be that inference has already failed on a later type parameter on a previous call to inferTypeArguments. - // So if this failure is on preceding type parameter, this type parameter is the new failure index. - context.failedTypeParameterIndex = index; - } } return inferredType; } function getInferredTypes(context) { - for (var i = 0; i < context.inferredTypes.length; i++) { - getInferredType(context, i); + var result = []; + for (var i = 0; i < context.inferences.length; i++) { + result.push(getInferredType(context, i)); } - return context.inferredTypes; + return result; } // EXPRESSION TYPE CHECKING function getResolvedSymbol(node) { var links = getNodeLinks(node); if (!links.resolvedSymbol) { - links.resolvedSymbol = !ts.nodeIsMissing(node) && resolveName(node, node.text, 107455 /* Value */ | 1048576 /* ExportValue */, ts.Diagnostics.Cannot_find_name_0, node) || unknownSymbol; + links.resolvedSymbol = !ts.nodeIsMissing(node) && resolveName(node, node.text, 107455 /* Value */ | 1048576 /* ExportValue */, ts.Diagnostics.Cannot_find_name_0, node, ts.Diagnostics.Cannot_find_name_0_Did_you_mean_1) || unknownSymbol; } return links.resolvedSymbol; } @@ -35018,11 +36518,13 @@ var ts; // Return the flow cache key for a "dotted name" (i.e. a sequence of identifiers // separated by dots). The key consists of the id of the symbol referenced by the // leftmost identifier followed by zero or more property names separated by dots. - // The result is undefined if the reference isn't a dotted name. + // The result is undefined if the reference isn't a dotted name. We prefix nodes + // occurring in an apparent type position with '@' because the control flow type + // of such nodes may be based on the apparent type instead of the declared type. function getFlowCacheKey(node) { if (node.kind === 71 /* Identifier */) { var symbol = getResolvedSymbol(node); - return symbol !== unknownSymbol ? "" + getSymbolId(symbol) : undefined; + return symbol !== unknownSymbol ? (isApparentTypePosition(node) ? "@" : "") + getSymbolId(symbol) : undefined; } if (node.kind === 99 /* ThisKeyword */) { return "0"; @@ -35091,7 +36593,7 @@ var ts; function isDiscriminantProperty(type, name) { if (type && type.flags & 65536 /* Union */) { var prop = getUnionOrIntersectionProperty(type, name); - if (prop && getCheckFlags(prop) & 2 /* SyntheticProperty */) { + if (prop && ts.getCheckFlags(prop) & 2 /* SyntheticProperty */) { if (prop.isDiscriminantProperty === undefined) { prop.isDiscriminantProperty = prop.checkFlags & 32 /* HasNonUniformType */ && isLiteralType(getTypeOfSymbol(prop)); } @@ -35154,8 +36656,8 @@ var ts; } function getTypeFactsOfTypes(types) { var result = 0 /* None */; - for (var _i = 0, types_14 = types; _i < types_14.length; _i++) { - var t = types_14[_i]; + for (var _i = 0, types_12 = types; _i < types_12.length; _i++) { + var t = types_12[_i]; result |= getTypeFacts(t); } return result; @@ -35173,15 +36675,16 @@ var ts; return strictNullChecks ? 4079361 /* StringStrictFacts */ : 4194049 /* StringFacts */; } if (flags & 32 /* StringLiteral */) { + var isEmpty = type.value === ""; return strictNullChecks ? - type.text === "" ? 3030785 /* EmptyStringStrictFacts */ : 1982209 /* NonEmptyStringStrictFacts */ : - type.text === "" ? 3145473 /* EmptyStringFacts */ : 4194049 /* NonEmptyStringFacts */; + isEmpty ? 3030785 /* EmptyStringStrictFacts */ : 1982209 /* NonEmptyStringStrictFacts */ : + isEmpty ? 3145473 /* EmptyStringFacts */ : 4194049 /* NonEmptyStringFacts */; } if (flags & (4 /* Number */ | 16 /* Enum */)) { return strictNullChecks ? 4079234 /* NumberStrictFacts */ : 4193922 /* NumberFacts */; } - if (flags & (64 /* NumberLiteral */ | 256 /* EnumLiteral */)) { - var isZero = type.text === "0"; + if (flags & 64 /* NumberLiteral */) { + var isZero = type.value === 0; return strictNullChecks ? isZero ? 3030658 /* ZeroStrictFacts */ : 1982082 /* NonZeroStrictFacts */ : isZero ? 3145346 /* ZeroFacts */ : 4193922 /* NonZeroFacts */; @@ -35238,11 +36741,11 @@ var ts; } function getTypeOfDestructuredArrayElement(type, index) { return isTupleLikeType(type) && getTypeOfPropertyOfType(type, "" + index) || - checkIteratedTypeOrElementType(type, /*errorNode*/ undefined, /*allowStringInput*/ false, /*allowAsyncIterable*/ false) || + checkIteratedTypeOrElementType(type, /*errorNode*/ undefined, /*allowStringInput*/ false, /*allowAsyncIterables*/ false) || unknownType; } function getTypeOfDestructuredSpreadExpression(type) { - return createArrayType(checkIteratedTypeOrElementType(type, /*errorNode*/ undefined, /*allowStringInput*/ false, /*allowAsyncIterable*/ false) || unknownType); + return createArrayType(checkIteratedTypeOrElementType(type, /*errorNode*/ undefined, /*allowStringInput*/ false, /*allowAsyncIterables*/ false) || unknownType); } function getAssignedTypeOfBinaryExpression(node) { var isDestructuringDefaultAssignment = node.parent.kind === 177 /* ArrayLiteralExpression */ && isDestructuringAssignmentTarget(node.parent) || @@ -35388,7 +36891,7 @@ var ts; } return true; } - if (source.flags & 256 /* EnumLiteral */ && target.flags & 16 /* Enum */ && source.baseType === target) { + if (source.flags & 256 /* EnumLiteral */ && getBaseTypeOfEnumLiteralType(source) === target) { return true; } return containsType(target.types, source); @@ -35414,8 +36917,8 @@ var ts; var types = type.types; var mappedType; var mappedTypes; - for (var _i = 0, types_15 = types; _i < types_15.length; _i++) { - var current = types_15[_i]; + for (var _i = 0, types_13 = types; _i < types_13.length; _i++) { + var current = types_13[_i]; var t = mapper(current); if (t) { if (!mappedType) { @@ -35495,8 +36998,8 @@ var ts; } function isEvolvingArrayTypeList(types) { var hasEvolvingArrayType = false; - for (var _i = 0, types_16 = types; _i < types_16.length; _i++) { - var t = types_16[_i]; + for (var _i = 0, types_14 = types; _i < types_14.length; _i++) { + var t = types_14[_i]; if (!(t.flags & 8192 /* Never */)) { if (!(getObjectFlags(t) & 256 /* EvolvingArray */)) { return false; @@ -35527,7 +37030,7 @@ var ts; parent.parent.operatorToken.kind === 58 /* EqualsToken */ && parent.parent.left === parent && !ts.isAssignmentTarget(parent.parent) && - isTypeAnyOrAllConstituentTypesHaveKind(getTypeOfExpression(parent.argumentExpression), 340 /* NumberLike */ | 2048 /* Undefined */); + isTypeAnyOrAllConstituentTypesHaveKind(getTypeOfExpression(parent.argumentExpression), 84 /* NumberLike */ | 2048 /* Undefined */); return isLengthPushOrUnshift || isElementAssignment; } function maybeTypePredicateCall(node) { @@ -35553,7 +37056,7 @@ var ts; function getFlowTypeOfReference(reference, declaredType, initialType, flowContainer, couldBeUninitialized) { if (initialType === void 0) { initialType = declaredType; } var key; - if (!reference.flowNode || !couldBeUninitialized && !(declaredType.flags & 17810431 /* Narrowable */)) { + if (!reference.flowNode || !couldBeUninitialized && !(declaredType.flags & 17810175 /* Narrowable */)) { return declaredType; } var visitedFlowStart = visitedFlowCount; @@ -35695,7 +37198,7 @@ var ts; } else { var indexType = getTypeOfExpression(node.left.argumentExpression); - if (isTypeAnyOrAllConstituentTypesHaveKind(indexType, 340 /* NumberLike */ | 2048 /* Undefined */)) { + if (isTypeAnyOrAllConstituentTypesHaveKind(indexType, 84 /* NumberLike */ | 2048 /* Undefined */)) { evolvedType_1 = addEvolvingArrayElementType(evolvedType_1, node.right); } } @@ -36202,6 +37705,26 @@ var ts; !(getFalsyFlags(checkExpression(declaration.initializer)) & 2048 /* Undefined */); return annotationIncludesUndefined ? getTypeWithFacts(declaredType, 131072 /* NEUndefined */) : declaredType; } + function isApparentTypePosition(node) { + var parent = node.parent; + return parent.kind === 179 /* PropertyAccessExpression */ || + parent.kind === 181 /* CallExpression */ && parent.expression === node || + parent.kind === 180 /* ElementAccessExpression */ && parent.expression === node; + } + function typeHasNullableConstraint(type) { + return type.flags & 540672 /* TypeVariable */ && maybeTypeOfKind(getBaseConstraintOfType(type) || emptyObjectType, 6144 /* Nullable */); + } + function getDeclaredOrApparentType(symbol, node) { + // When a node is the left hand expression of a property access, element access, or call expression, + // and the type of the node includes type variables with constraints that are nullable, we fetch the + // apparent type of the node *before* performing control flow analysis such that narrowings apply to + // the constraint type. + var type = getTypeOfSymbol(symbol); + if (isApparentTypePosition(node) && forEachType(type, typeHasNullableConstraint)) { + return mapType(getWidenedType(type), getApparentType); + } + return type; + } function checkIdentifier(node) { var symbol = getResolvedSymbol(node); if (symbol === unknownSymbol) { @@ -36226,7 +37749,9 @@ var ts; getNodeLinks(container).flags |= 8192 /* CaptureArguments */; return getTypeOfSymbol(symbol); } - if (symbol.flags & 8388608 /* Alias */ && !isInTypeQuery(node) && !isConstEnumOrConstEnumOnlyModule(resolveAlias(symbol))) { + // We should only mark aliases as referenced if there isn't a local value declaration + // for the symbol. + if (isNonLocalAlias(symbol, /*excludes*/ 107455 /* Value */) && !isInTypeQuery(node) && !isConstEnumOrConstEnumOnlyModule(resolveAlias(symbol))) { markAliasSymbolAsReferenced(symbol); } var localOrExportSymbol = getExportSymbolOfValueSymbolIfExported(symbol); @@ -36268,7 +37793,7 @@ var ts; checkCollisionWithCapturedThisVariable(node, node); checkCollisionWithCapturedNewTargetVariable(node, node); checkNestedBlockScopedBinding(node, symbol); - var type = getTypeOfSymbol(localOrExportSymbol); + var type = getDeclaredOrApparentType(localOrExportSymbol, node); var declaration = localOrExportSymbol.valueDeclaration; var assignmentKind = ts.getAssignmentTargetKind(node); if (assignmentKind) { @@ -36306,10 +37831,11 @@ var ts; // declaration container are the same). var assumeInitialized = isParameter || isOuterVariable || type !== autoType && type !== autoArrayType && (!strictNullChecks || (type.flags & 1 /* Any */) !== 0 || isInTypeQuery(node) || node.parent.kind === 246 /* ExportSpecifier */) || + node.parent.kind === 203 /* NonNullExpression */ || ts.isInAmbientContext(declaration); var initialType = assumeInitialized ? (isParameter ? removeOptionalityFromDeclaredType(type, ts.getRootDeclaration(declaration)) : type) : type === autoType || type === autoArrayType ? undefinedType : - includeFalsyTypes(type, 2048 /* Undefined */); + getNullableType(type, 2048 /* Undefined */); var flowType = getFlowTypeOfReference(node, type, initialType, flowContainer, !assumeInitialized); // A variable is considered uninitialized when it is possible to analyze the entire control flow graph // from declaration to use, and when the variable's declared type doesn't include undefined but the @@ -36849,8 +38375,15 @@ var ts; function getContextualTypeForInitializerExpression(node) { var declaration = node.parent; if (node === declaration.initializer) { - if (declaration.type) { - return getTypeFromTypeNode(declaration.type); + var typeNode = ts.getEffectiveTypeAnnotationNode(declaration); + if (typeNode) { + return getTypeFromTypeNode(typeNode); + } + if (ts.isInJavaScriptFile(declaration)) { + var jsDocType = getTypeForDeclarationFromJSDocComment(declaration); + if (jsDocType) { + return jsDocType; + } } if (declaration.kind === 146 /* Parameter */) { var type = getContextuallyTypedParameterType(declaration); @@ -36864,12 +38397,13 @@ var ts; if (ts.isBindingPattern(declaration.parent)) { var parentDeclaration = declaration.parent.parent; var name = declaration.propertyName || declaration.name; - if (parentDeclaration.kind !== 176 /* BindingElement */ && - parentDeclaration.type && - !ts.isBindingPattern(name)) { - var text = ts.getTextOfPropertyName(name); - if (text) { - return getTypeOfPropertyOfType(getTypeFromTypeNode(parentDeclaration.type), text); + if (parentDeclaration.kind !== 176 /* BindingElement */) { + var parentTypeNode = ts.getEffectiveTypeAnnotationNode(parentDeclaration); + if (parentTypeNode && !ts.isBindingPattern(name)) { + var text = ts.getTextOfPropertyName(name); + if (text) { + return getTypeOfPropertyOfType(getTypeFromTypeNode(parentTypeNode), text); + } } } } @@ -36915,9 +38449,9 @@ var ts; function getContextualReturnType(functionDecl) { // If the containing function has a return type annotation, is a constructor, or is a get accessor whose // corresponding set accessor has a type annotation, return statements in the function are contextually typed - if (functionDecl.type || - functionDecl.kind === 152 /* Constructor */ || - functionDecl.kind === 153 /* GetAccessor */ && ts.getSetAccessorTypeAnnotationNode(ts.getDeclarationOfKind(functionDecl.symbol, 154 /* SetAccessor */))) { + if (functionDecl.kind === 152 /* Constructor */ || + ts.getEffectiveReturnTypeNode(functionDecl) || + isGetAccessorWithAnnotatedSetAccessor(functionDecl)) { return getReturnTypeOfSignature(getSignatureFromDeclaration(functionDecl)); } // Otherwise, if the containing function is contextually typed by a function type with exactly one call signature @@ -36947,7 +38481,7 @@ var ts; function getContextualTypeForBinaryOperand(node) { var binaryExpression = node.parent; var operator = binaryExpression.operatorToken.kind; - if (operator >= 58 /* FirstAssignment */ && operator <= 70 /* LastAssignment */) { + if (ts.isAssignmentOperator(operator)) { // Don't do this for special property assignments to avoid circularity if (ts.getSpecialPropertyAssignmentKind(binaryExpression) !== 0 /* None */) { return undefined; @@ -37027,7 +38561,7 @@ var ts; var index = ts.indexOf(arrayLiteral.elements, node); return getTypeOfPropertyOfContextualType(type, "" + index) || getIndexTypeOfContextualType(type, 1 /* Number */) - || getIteratedTypeOrElementType(type, /*errorNode*/ undefined, /*allowStringInput*/ false, /*allowAsyncIterable*/ false, /*checkAssignability*/ false); + || getIteratedTypeOrElementType(type, /*errorNode*/ undefined, /*allowStringInput*/ false, /*allowAsyncIterables*/ false, /*checkAssignability*/ false); } return undefined; } @@ -37132,6 +38666,8 @@ var ts; case 261 /* PropertyAssignment */: case 262 /* ShorthandPropertyAssignment */: return getContextualTypeForObjectLiteralElement(parent); + case 263 /* SpreadAssignment */: + return getApparentTypeOfContextualType(parent.parent); case 177 /* ArrayLiteralExpression */: return getContextualTypeForElementExpression(node); case 195 /* ConditionalExpression */: @@ -37156,13 +38692,13 @@ var ts; node = ts.findAncestor(node, function (n) { return !!n.contextualMapper; }); return node ? node.contextualMapper : identityMapper; } - // If the given type is an object or union type, if that type has a single signature, and if - // that signature is non-generic, return the signature. Otherwise return undefined. - function getNonGenericSignature(type, node) { + // If the given type is an object or union type with a single signature, and if that signature has at + // least as many parameters as the given function, return the signature. Otherwise return undefined. + function getContextualCallSignature(type, node) { var signatures = getSignaturesOfStructuredType(type, 0 /* Call */); if (signatures.length === 1) { var signature = signatures[0]; - if (!signature.typeParameters && !isAritySmaller(signature, node)) { + if (!isAritySmaller(signature, node)) { return signature; } } @@ -37208,13 +38744,13 @@ var ts; return undefined; } if (!(type.flags & 65536 /* Union */)) { - return getNonGenericSignature(type, node); + return getContextualCallSignature(type, node); } var signatureList; var types = type.types; - for (var _i = 0, types_17 = types; _i < types_17.length; _i++) { - var current = types_17[_i]; - var signature = getNonGenericSignature(current, node); + for (var _i = 0, types_15 = types; _i < types_15.length; _i++) { + var current = types_15[_i]; + var signature = getContextualCallSignature(current, node); if (signature) { if (!signatureList) { // This signature will contribute to contextual union signature @@ -37245,7 +38781,7 @@ var ts; checkExternalEmitHelpers(node, 1536 /* SpreadIncludes */); } var arrayOrIterableType = checkExpression(node.expression, checkMode); - return checkIteratedTypeOrElementType(arrayOrIterableType, node.expression, /*allowStringInput*/ false, /*allowAsyncIterable*/ false); + return checkIteratedTypeOrElementType(arrayOrIterableType, node.expression, /*allowStringInput*/ false, /*allowAsyncIterables*/ false); } function hasDefaultValue(node) { return (node.kind === 176 /* BindingElement */ && !!node.initializer) || @@ -37273,7 +38809,7 @@ var ts; // if there is no index type / iterated type. var restArrayType = checkExpression(e.expression, checkMode); var restElementType = getIndexTypeOfType(restArrayType, 1 /* Number */) || - getIteratedTypeOrElementType(restArrayType, /*errorNode*/ undefined, /*allowStringInput*/ false, /*allowAsyncIterable*/ false, /*checkAssignability*/ false); + getIteratedTypeOrElementType(restArrayType, /*errorNode*/ undefined, /*allowStringInput*/ false, /*allowAsyncIterables*/ false, /*checkAssignability*/ false); if (restElementType) { elementTypes.push(restElementType); } @@ -37327,7 +38863,7 @@ var ts; function isNumericComputedName(name) { // It seems odd to consider an expression of type Any to result in a numeric name, // but this behavior is consistent with checkIndexedAccess - return isTypeAnyOrAllConstituentTypesHaveKind(checkComputedPropertyName(name), 340 /* NumberLike */); + return isTypeAnyOrAllConstituentTypesHaveKind(checkComputedPropertyName(name), 84 /* NumberLike */); } function isTypeAnyOrAllConstituentTypesHaveKind(type, kind) { return isTypeAny(type) || isTypeOfKind(type, kind); @@ -37365,7 +38901,7 @@ var ts; links.resolvedType = checkExpression(node.expression); // This will allow types number, string, symbol or any. It will also allow enums, the unknown // type, and any union of these types (like string | number). - if (!isTypeAnyOrAllConstituentTypesHaveKind(links.resolvedType, 340 /* NumberLike */ | 262178 /* StringLike */ | 512 /* ESSymbol */)) { + if (!isTypeAnyOrAllConstituentTypesHaveKind(links.resolvedType, 84 /* NumberLike */ | 262178 /* StringLike */ | 512 /* ESSymbol */)) { error(node, ts.Diagnostics.A_computed_property_name_must_be_of_type_string_number_symbol_or_any); } else { @@ -37516,6 +39052,8 @@ var ts; if (spread.flags & 32768 /* Object */) { // only set the symbol and flags if this is a (fresh) object type spread.flags |= propagatedFlags; + spread.flags |= 1048576 /* FreshLiteral */; + spread.objectFlags |= 128 /* ObjectLiteral */; spread.symbol = node.symbol; } return spread; @@ -37642,18 +39180,15 @@ var ts; if (spread !== emptyObjectType) { if (attributesArray.length > 0) { spread = getSpreadType(spread, createJsxAttributesType(attributes.symbol, attributesTable)); - attributesArray = []; - attributesTable = ts.createMap(); } attributesArray = getPropertiesOfType(spread); } attributesTable = ts.createMap(); - if (attributesArray) { - ts.forEach(attributesArray, function (attr) { - if (!filter || filter(attr)) { - attributesTable.set(attr.name, attr); - } - }); + for (var _b = 0, attributesArray_1 = attributesArray; _b < attributesArray_1.length; _b++) { + var attr = attributesArray_1[_b]; + if (!filter || filter(attr)) { + attributesTable.set(attr.name, attr); + } } } // Handle children attribute @@ -37661,8 +39196,8 @@ var ts; // We have to check that openingElement of the parent is the one we are visiting as this may not be true for selfClosingElement if (parent && parent.openingElement === openingLikeElement && parent.children.length > 0) { var childrenTypes = []; - for (var _b = 0, _c = parent.children; _b < _c.length; _b++) { - var child = _c[_b]; + for (var _c = 0, _d = parent.children; _c < _d.length; _c++) { + var child = _d[_c]; // In React, JSX text that contains only whitespaces will be ignored so we don't want to type-check that // because then type of children property will have constituent of string type. if (child.kind === 10 /* JsxText */) { @@ -37986,7 +39521,7 @@ var ts; // Hello World var intrinsicElementsType = getJsxType(JsxNames.IntrinsicElements); if (intrinsicElementsType !== unknownType) { - var stringLiteralTypeName = elementType.text; + var stringLiteralTypeName = elementType.value; var intrinsicProp = getPropertyOfType(intrinsicElementsType, stringLiteralTypeName); if (intrinsicProp) { return getTypeOfSymbol(intrinsicProp); @@ -38177,7 +39712,7 @@ var ts; checkJsxPreconditions(node); // The reactNamespace/jsxFactory's root symbol should be marked as 'used' so we don't incorrectly elide its import. // And if there is no reactNamespace/jsxFactory's symbol in scope when targeting React emit, we should issue an error. - var reactRefErr = compilerOptions.jsx === 2 /* React */ ? ts.Diagnostics.Cannot_find_name_0 : undefined; + var reactRefErr = diagnostics && compilerOptions.jsx === 2 /* React */ ? ts.Diagnostics.Cannot_find_name_0 : undefined; var reactNamespace = getJsxNamespace(); var reactSym = resolveName(node.tagName, reactNamespace, 107455 /* Value */, reactRefErr, reactNamespace); if (reactSym) { @@ -38193,9 +39728,13 @@ var ts; } /** * Check if a property with the given name is known anywhere in the given type. In an object type, a property - * is considered known if the object type is empty and the check is for assignability, if the object type has - * index signatures, or if the property is actually declared in the object type. In a union or intersection - * type, a property is considered known if it is known in any constituent type. + * is considered known if + * 1. the object type is empty and the check is for assignability, or + * 2. if the object type has index signatures, or + * 3. if the property is actually declared in the object type + * (this means that 'toString', for example, is not usually a known property). + * 4. In a union or intersection type, + * a property is considered known if it is known in any constituent type. * @param targetType a type to search a given name in * @param name a property name to search * @param isComparingJsxAttributes a boolean flag indicating whether we are searching in JsxAttributesType @@ -38203,8 +39742,10 @@ var ts; function isKnownProperty(targetType, name, isComparingJsxAttributes) { if (targetType.flags & 32768 /* Object */) { var resolved = resolveStructuredTypeMembers(targetType); - if (resolved.stringIndexInfo || resolved.numberIndexInfo && isNumericLiteralName(name) || - getPropertyOfType(targetType, name) || isComparingJsxAttributes && !isUnhyphenatedJsxName(name)) { + if (resolved.stringIndexInfo || + resolved.numberIndexInfo && isNumericLiteralName(name) || + getPropertyOfObjectType(targetType, name) || + isComparingJsxAttributes && !isUnhyphenatedJsxName(name)) { // For JSXAttributes, if the attribute has a hyphenated name, consider that the attribute to be known. return true; } @@ -38280,29 +39821,11 @@ var ts; function getDeclarationKindFromSymbol(s) { return s.valueDeclaration ? s.valueDeclaration.kind : 149 /* PropertyDeclaration */; } - function getDeclarationModifierFlagsFromSymbol(s) { - if (s.valueDeclaration) { - var flags = ts.getCombinedModifierFlags(s.valueDeclaration); - return s.parent && s.parent.flags & 32 /* Class */ ? flags : flags & ~28 /* AccessibilityModifier */; - } - if (getCheckFlags(s) & 6 /* Synthetic */) { - var checkFlags = s.checkFlags; - var accessModifier = checkFlags & 256 /* ContainsPrivate */ ? 8 /* Private */ : - checkFlags & 64 /* ContainsPublic */ ? 4 /* Public */ : - 16 /* Protected */; - var staticModifier = checkFlags & 512 /* ContainsStatic */ ? 32 /* Static */ : 0; - return accessModifier | staticModifier; - } - if (s.flags & 16777216 /* Prototype */) { - return 4 /* Public */ | 32 /* Static */; - } - return 0; - } function getDeclarationNodeFlagsFromSymbol(s) { return s.valueDeclaration ? ts.getCombinedNodeFlags(s.valueDeclaration) : 0; } function isMethodLike(symbol) { - return !!(symbol.flags & 8192 /* Method */ || getCheckFlags(symbol) & 4 /* SyntheticMethod */); + return !!(symbol.flags & 8192 /* Method */ || ts.getCheckFlags(symbol) & 4 /* SyntheticMethod */); } /** * Check whether the requested property access is valid. @@ -38313,11 +39836,11 @@ var ts; * @param prop The symbol for the right hand side of the property access. */ function checkPropertyAccessibility(node, left, type, prop) { - var flags = getDeclarationModifierFlagsFromSymbol(prop); + var flags = ts.getDeclarationModifierFlagsFromSymbol(prop); var errorNode = node.kind === 179 /* PropertyAccessExpression */ || node.kind === 226 /* VariableDeclaration */ ? node.name : node.right; - if (getCheckFlags(prop) & 256 /* ContainsPrivate */) { + if (ts.getCheckFlags(prop) & 256 /* ContainsPrivate */) { // Synthetic property with private constituent property error(errorNode, ts.Diagnostics.Property_0_has_conflicting_declarations_and_is_inaccessible_in_type_1, symbolToString(prop), typeToString(type)); return false; @@ -38415,6 +39938,61 @@ var ts; function checkQualifiedName(node) { return checkPropertyAccessExpressionOrQualifiedName(node, node.left, node.right); } + function checkPropertyAccessExpressionOrQualifiedName(node, left, right) { + var type = checkNonNullExpression(left); + if (isTypeAny(type) || type === silentNeverType) { + return type; + } + var apparentType = getApparentType(getWidenedType(type)); + if (apparentType === unknownType || (type.flags & 16384 /* TypeParameter */ && isTypeAny(apparentType))) { + // handle cases when type is Type parameter with invalid or any constraint + return apparentType; + } + var prop = getPropertyOfType(apparentType, right.text); + if (!prop) { + var stringIndexType = getIndexTypeOfType(apparentType, 0 /* String */); + if (stringIndexType) { + return stringIndexType; + } + if (right.text && !checkAndReportErrorForExtendingInterface(node)) { + reportNonexistentProperty(right, type.flags & 16384 /* TypeParameter */ && type.isThisType ? apparentType : type); + } + return unknownType; + } + if (prop.valueDeclaration) { + if (isInPropertyInitializer(node) && + !isBlockScopedNameDeclaredBeforeUse(prop.valueDeclaration, right)) { + error(right, ts.Diagnostics.Block_scoped_variable_0_used_before_its_declaration, right.text); + } + if (prop.valueDeclaration.kind === 229 /* ClassDeclaration */ && + node.parent && node.parent.kind !== 159 /* TypeReference */ && + !ts.isInAmbientContext(prop.valueDeclaration) && + !isBlockScopedNameDeclaredBeforeUse(prop.valueDeclaration, right)) { + error(right, ts.Diagnostics.Class_0_used_before_its_declaration, right.text); + } + } + markPropertyAsReferenced(prop); + getNodeLinks(node).resolvedSymbol = prop; + checkPropertyAccessibility(node, left, apparentType, prop); + var propType = getDeclaredOrApparentType(prop, node); + var assignmentKind = ts.getAssignmentTargetKind(node); + if (assignmentKind) { + if (isReferenceToReadonlyEntity(node, prop) || isReferenceThroughNamespaceImport(node)) { + error(right, ts.Diagnostics.Cannot_assign_to_0_because_it_is_a_constant_or_a_read_only_property, right.text); + return unknownType; + } + } + // Only compute control flow type if this is a property access expression that isn't an + // assignment target, and the referenced property was declared as a variable, property, + // accessor, or optional method. + if (node.kind !== 179 /* PropertyAccessExpression */ || assignmentKind === 1 /* Definite */ || + !(prop.flags & (3 /* Variable */ | 4 /* Property */ | 98304 /* Accessor */)) && + !(prop.flags & 8192 /* Method */ && propType.flags & 65536 /* Union */)) { + return propType; + } + var flowType = getFlowTypeOfReference(node, propType); + return assignmentKind ? getBaseTypeOfLiteralType(flowType) : flowType; + } function reportNonexistentProperty(propNode, containingType) { var errorInfo; if (containingType.flags & 65536 /* Union */ && !(containingType.flags & 8190 /* Primitive */)) { @@ -38426,15 +40004,104 @@ var ts; } } } - errorInfo = ts.chainDiagnosticMessages(errorInfo, ts.Diagnostics.Property_0_does_not_exist_on_type_1, ts.declarationNameToString(propNode), typeToString(containingType)); + var suggestion = getSuggestionForNonexistentProperty(propNode, containingType); + if (suggestion) { + errorInfo = ts.chainDiagnosticMessages(errorInfo, ts.Diagnostics.Property_0_does_not_exist_on_type_1_Did_you_mean_2, ts.declarationNameToString(propNode), typeToString(containingType), suggestion); + } + else { + errorInfo = ts.chainDiagnosticMessages(errorInfo, ts.Diagnostics.Property_0_does_not_exist_on_type_1, ts.declarationNameToString(propNode), typeToString(containingType)); + } diagnostics.add(ts.createDiagnosticForNodeFromMessageChain(propNode, errorInfo)); } + function getSuggestionForNonexistentProperty(node, containingType) { + var suggestion = getSpellingSuggestionForName(node.text, getPropertiesOfObjectType(containingType), 107455 /* Value */); + return suggestion && suggestion.name; + } + function getSuggestionForNonexistentSymbol(location, name, meaning) { + var result = resolveNameHelper(location, name, meaning, /*nameNotFoundMessage*/ undefined, name, function (symbols, name, meaning) { + var symbol = getSymbol(symbols, name, meaning); + if (symbol) { + // Sometimes the symbol is found when location is a return type of a function: `typeof x` and `x` is declared in the body of the function + // So the table *contains* `x` but `x` isn't actually in scope. + // However, resolveNameHelper will continue and call this callback again, so we'll eventually get a correct suggestion. + return symbol; + } + return getSpellingSuggestionForName(name, ts.arrayFrom(symbols.values()), meaning); + }); + if (result) { + return result.name; + } + } + /** + * Given a name and a list of symbols whose names are *not* equal to the name, return a spelling suggestion if there is one that is close enough. + * Names less than length 3 only check for case-insensitive equality, not levenshtein distance. + * + * If there is a candidate that's the same except for case, return that. + * If there is a candidate that's within one edit of the name, return that. + * Otherwise, return the candidate with the smallest Levenshtein distance, + * except for candidates: + * * With no name + * * Whose meaning doesn't match the `meaning` parameter. + * * Whose length differs from the target name by more than 0.3 of the length of the name. + * * Whose levenshtein distance is more than 0.4 of the length of the name + * (0.4 allows 1 substitution/transposition for every 5 characters, + * and 1 insertion/deletion at 3 characters) + * Names longer than 30 characters don't get suggestions because Levenshtein distance is an n**2 algorithm. + */ + function getSpellingSuggestionForName(name, symbols, meaning) { + var worstDistance = name.length * 0.4; + var maximumLengthDifference = Math.min(3, name.length * 0.34); + var bestDistance = Number.MAX_VALUE; + var bestCandidate = undefined; + var justCheckExactMatches = false; + if (name.length > 30) { + return undefined; + } + name = name.toLowerCase(); + for (var _i = 0, symbols_3 = symbols; _i < symbols_3.length; _i++) { + var candidate = symbols_3[_i]; + if (candidate.flags & meaning && + candidate.name && + Math.abs(candidate.name.length - name.length) < maximumLengthDifference) { + var candidateName = candidate.name.toLowerCase(); + if (candidateName === name) { + return candidate; + } + if (justCheckExactMatches) { + continue; + } + if (candidateName.length < 3 || + name.length < 3 || + candidateName === "eval" || + candidateName === "intl" || + candidateName === "undefined" || + candidateName === "map" || + candidateName === "nan" || + candidateName === "set") { + continue; + } + var distance = ts.levenshtein(name, candidateName); + if (distance > worstDistance) { + continue; + } + if (distance < 3) { + justCheckExactMatches = true; + bestCandidate = candidate; + } + else if (distance < bestDistance) { + bestDistance = distance; + bestCandidate = candidate; + } + } + } + return bestCandidate; + } function markPropertyAsReferenced(prop) { if (prop && noUnusedIdentifiers && (prop.flags & 106500 /* ClassMember */) && prop.valueDeclaration && (ts.getModifierFlags(prop.valueDeclaration) & 8 /* Private */)) { - if (getCheckFlags(prop) & 1 /* Instantiated */) { + if (ts.getCheckFlags(prop) & 1 /* Instantiated */) { getSymbolLinks(prop).target.isReferenced = true; } else { @@ -38451,71 +40118,28 @@ var ts; } return false; } - function checkPropertyAccessExpressionOrQualifiedName(node, left, right) { - var type = checkNonNullExpression(left); - if (isTypeAny(type) || type === silentNeverType) { - return type; - } - var apparentType = getApparentType(getWidenedType(type)); - if (apparentType === unknownType || (type.flags & 16384 /* TypeParameter */ && isTypeAny(apparentType))) { - // handle cases when type is Type parameter with invalid or any constraint - return apparentType; - } - var prop = getPropertyOfType(apparentType, right.text); - if (!prop) { - var stringIndexType = getIndexTypeOfType(apparentType, 0 /* String */); - if (stringIndexType) { - return stringIndexType; - } - if (right.text && !checkAndReportErrorForExtendingInterface(node)) { - reportNonexistentProperty(right, type.flags & 16384 /* TypeParameter */ && type.isThisType ? apparentType : type); - } - return unknownType; - } - if (prop.valueDeclaration) { - if (isInPropertyInitializer(node) && - !isBlockScopedNameDeclaredBeforeUse(prop.valueDeclaration, right)) { - error(right, ts.Diagnostics.Block_scoped_variable_0_used_before_its_declaration, right.text); - } - if (prop.valueDeclaration.kind === 229 /* ClassDeclaration */ && - node.parent && node.parent.kind !== 159 /* TypeReference */ && - !ts.isInAmbientContext(prop.valueDeclaration) && - !isBlockScopedNameDeclaredBeforeUse(prop.valueDeclaration, right)) { - error(right, ts.Diagnostics.Class_0_used_before_its_declaration, right.text); - } - } - markPropertyAsReferenced(prop); - getNodeLinks(node).resolvedSymbol = prop; - checkPropertyAccessibility(node, left, apparentType, prop); - var propType = getTypeOfSymbol(prop); - var assignmentKind = ts.getAssignmentTargetKind(node); - if (assignmentKind) { - if (isReferenceToReadonlyEntity(node, prop) || isReferenceThroughNamespaceImport(node)) { - error(right, ts.Diagnostics.Cannot_assign_to_0_because_it_is_a_constant_or_a_read_only_property, right.text); - return unknownType; - } - } - // Only compute control flow type if this is a property access expression that isn't an - // assignment target, and the referenced property was declared as a variable, property, - // accessor, or optional method. - if (node.kind !== 179 /* PropertyAccessExpression */ || assignmentKind === 1 /* Definite */ || - !(prop.flags & (3 /* Variable */ | 4 /* Property */ | 98304 /* Accessor */)) && - !(prop.flags & 8192 /* Method */ && propType.flags & 65536 /* Union */)) { - return propType; - } - var flowType = getFlowTypeOfReference(node, propType); - return assignmentKind ? getBaseTypeOfLiteralType(flowType) : flowType; - } function isValidPropertyAccess(node, propertyName) { var left = node.kind === 179 /* PropertyAccessExpression */ ? node.expression : node.left; - var type = checkExpression(left); + return isValidPropertyAccessWithType(node, left, propertyName, getWidenedType(checkExpression(left))); + } + function isValidPropertyAccessWithType(node, left, propertyName, type) { if (type !== unknownType && !isTypeAny(type)) { - var prop = getPropertyOfType(getWidenedType(type), propertyName); + var prop = getPropertyOfType(type, propertyName); if (prop) { return checkPropertyAccessibility(node, left, type, prop); } + // In js files properties of unions are allowed in completion + if (ts.isInJavaScriptFile(left) && (type.flags & 65536 /* Union */)) { + for (var _i = 0, _a = type.types; _i < _a.length; _i++) { + var elementType = _a[_i]; + if (isValidPropertyAccessWithType(node, left, propertyName, elementType)) { + return true; + } + } + } + return false; } return true; } @@ -38628,7 +40252,16 @@ var ts; } return true; } + function callLikeExpressionMayHaveTypeArguments(node) { + // TODO: Also include tagged templates (https://github.com/Microsoft/TypeScript/issues/11947) + return ts.isCallOrNewExpression(node); + } function resolveUntypedCall(node) { + if (callLikeExpressionMayHaveTypeArguments(node)) { + // Check type arguments even though we will give an error that untyped calls may not accept type arguments. + // This gets us diagnostics for the type arguments and marks them as referenced. + ts.forEach(node.typeArguments, checkSourceElement); + } if (node.kind === 183 /* TaggedTemplateExpression */) { checkExpression(node.template); } @@ -38768,7 +40401,7 @@ var ts; // If spread arguments are present, check that they correspond to a rest parameter. If so, no // further checking is necessary. if (spreadArgIndex >= 0) { - return isRestParameterIndex(signature, spreadArgIndex); + return isRestParameterIndex(signature, spreadArgIndex) || spreadArgIndex >= signature.minArgumentCount; } // Too many arguments implies incorrect arity. if (!signature.hasRestParameter && argCount > signature.parameters.length) { @@ -38791,41 +40424,60 @@ var ts; } // Instantiate a generic signature in the context of a non-generic signature (section 3.8.5 in TypeScript spec) function instantiateSignatureInContextOf(signature, contextualSignature, contextualMapper) { - var context = createInferenceContext(signature, /*inferUnionTypes*/ true, /*useAnyForNoInferences*/ false); + var context = createInferenceContext(signature, 1 /* InferUnionTypes */); forEachMatchingParameterType(contextualSignature, signature, function (source, target) { // Type parameters from outer context referenced by source type are fixed by instantiation of the source type - inferTypesWithContext(context, instantiateType(source, contextualMapper), target); + inferTypes(context.inferences, instantiateType(source, contextualMapper || identityMapper), target); }); + if (!contextualMapper) { + inferTypes(context.inferences, getReturnTypeOfSignature(contextualSignature), getReturnTypeOfSignature(signature), 4 /* ReturnType */); + } return getSignatureInstantiation(signature, getInferredTypes(context)); } function inferTypeArguments(node, signature, args, excludeArgument, context) { - var typeParameters = signature.typeParameters; - var inferenceMapper = getInferenceMapper(context); + var inferences = context.inferences; // Clear out all the inference results from the last time inferTypeArguments was called on this context - for (var i = 0; i < typeParameters.length; i++) { + for (var i = 0; i < inferences.length; i++) { // As an optimization, we don't have to clear (and later recompute) inferred types // for type parameters that have already been fixed on the previous call to inferTypeArguments. // It would be just as correct to reset all of them. But then we'd be repeating the same work // for the type parameters that were fixed, namely the work done by getInferredType. - if (!context.inferences[i].isFixed) { - context.inferredTypes[i] = undefined; + if (!inferences[i].isFixed) { + inferences[i].inferredType = undefined; } } - // On this call to inferTypeArguments, we may get more inferences for certain type parameters that were not - // fixed last time. This means that a type parameter that failed inference last time may succeed this time, - // or vice versa. Therefore, the failedTypeParameterIndex is useless if it points to an unfixed type parameter, - // because it may change. So here we reset it. However, getInferredType will not revisit any type parameters - // that were previously fixed. So if a fixed type parameter failed previously, it will fail again because - // it will contain the exact same set of inferences. So if we reset the index from a fixed type parameter, - // we will lose information that we won't recover this time around. - if (context.failedTypeParameterIndex !== undefined && !context.inferences[context.failedTypeParameterIndex].isFixed) { - context.failedTypeParameterIndex = undefined; + // If a contextual type is available, infer from that type to the return type of the call expression. For + // example, given a 'function wrap(cb: (x: T) => U): (x: T) => U' and a call expression + // 'let f: (x: string) => number = wrap(s => s.length)', we infer from the declared type of 'f' to the + // return type of 'wrap'. + if (ts.isExpression(node)) { + var contextualType = getContextualType(node); + if (contextualType) { + // We clone the contextual mapper to avoid disturbing a resolution in progress for an + // outer call expression. Effectively we just want a snapshot of whatever has been + // inferred for any outer call expression so far. + var instantiatedType = instantiateType(contextualType, cloneTypeMapper(getContextualMapper(node))); + // If the contextual type is a generic function type with a single call signature, we + // instantiate the type with its own type parameters and type arguments. This ensures that + // the type parameters are not erased to type any during type inference such that they can + // be inferred as actual types from the contextual type. For example: + // declare function arrayMap(f: (x: T) => U): (a: T[]) => U[]; + // const boxElements: (a: A[]) => { value: A }[] = arrayMap(value => ({ value })); + // Above, the type of the 'value' parameter is inferred to be 'A'. + var contextualSignature = getSingleCallSignature(instantiatedType); + var inferenceSourceType = contextualSignature && contextualSignature.typeParameters ? + getOrCreateTypeFromSignature(getSignatureInstantiation(contextualSignature, contextualSignature.typeParameters)) : + instantiatedType; + var inferenceTargetType = getReturnTypeOfSignature(signature); + // Inferences made from return types have lower priority than all other inferences. + inferTypes(context.inferences, inferenceSourceType, inferenceTargetType, 4 /* ReturnType */); + } } var thisType = getThisTypeOfSignature(signature); if (thisType) { var thisArgumentNode = getThisArgumentOfCall(node); var thisArgumentType = thisArgumentNode ? checkExpression(thisArgumentNode) : voidType; - inferTypesWithContext(context, thisArgumentType, thisType); + inferTypes(context.inferences, thisArgumentType, thisType); } // We perform two passes over the arguments. In the first pass we infer from all arguments, but use // wildcards for all context sensitive function expressions. @@ -38841,10 +40493,10 @@ var ts; if (argType === undefined) { // For context sensitive arguments we pass the identityMapper, which is a signal to treat all // context sensitive function expressions as wildcards - var mapper = excludeArgument && excludeArgument[i] !== undefined ? identityMapper : inferenceMapper; + var mapper = excludeArgument && excludeArgument[i] !== undefined ? identityMapper : context; argType = checkExpressionWithContextualType(arg, paramType, mapper); } - inferTypesWithContext(context, argType, paramType); + inferTypes(context.inferences, argType, paramType); } } // In the second pass we visit only context sensitive arguments, and only those that aren't excluded, this @@ -38858,11 +40510,11 @@ var ts; if (excludeArgument[i] === false) { var arg = args[i]; var paramType = getTypeAtPosition(signature, i); - inferTypesWithContext(context, checkExpressionWithContextualType(arg, paramType, inferenceMapper), paramType); + inferTypes(context.inferences, checkExpressionWithContextualType(arg, paramType, context), paramType); } } } - getInferredTypes(context); + return getInferredTypes(context); } function checkTypeArguments(signature, typeArgumentNodes, typeArgumentTypes, reportErrors, headMessage) { var typeParameters = signature.typeParameters; @@ -39139,7 +40791,7 @@ var ts; case 71 /* Identifier */: case 8 /* NumericLiteral */: case 9 /* StringLiteral */: - return getLiteralTypeForText(32 /* StringLiteral */, element.name.text); + return getLiteralType(element.name.text); case 144 /* ComputedPropertyName */: var nameType = checkComputedPropertyName(element.name); if (isTypeOfKind(nameType, 512 /* ESSymbol */)) { @@ -39249,7 +40901,7 @@ var ts; return arg; } } - function resolveCall(node, signatures, candidatesOutArray, headMessage) { + function resolveCall(node, signatures, candidatesOutArray, fallbackError) { var isTaggedTemplate = node.kind === 183 /* TaggedTemplateExpression */; var isDecorator = node.kind === 147 /* Decorator */; var isJsxOpeningOrSelfClosingElement = ts.isJsxOpeningLikeElement(node); @@ -39261,25 +40913,11 @@ var ts; ts.forEach(typeArguments, checkSourceElement); } } - if (signatures.length === 1) { - var declaration = signatures[0].declaration; - if (declaration && ts.isInJavaScriptFile(declaration) && !ts.hasJSDocParameterTags(declaration)) { - if (containsArgumentsReference(declaration)) { - var signatureWithRest = cloneSignature(signatures[0]); - var syntheticArgsSymbol = createSymbol(3 /* Variable */, "args"); - syntheticArgsSymbol.type = anyArrayType; - syntheticArgsSymbol.isRestParameter = true; - signatureWithRest.parameters = ts.concatenate(signatureWithRest.parameters, [syntheticArgsSymbol]); - signatureWithRest.hasRestParameter = true; - signatures = [signatureWithRest]; - } - } - } var candidates = candidatesOutArray || []; // reorderCandidates fills up the candidates array directly reorderCandidates(signatures, candidates); if (!candidates.length) { - reportError(ts.Diagnostics.Supplied_parameters_do_not_match_any_signature_of_call_target); + diagnostics.add(ts.createDiagnosticForNode(node, ts.Diagnostics.Call_target_does_not_contain_any_signatures)); return resolveErrorCall(node); } var args = getEffectiveCallArguments(node); @@ -39317,9 +40955,9 @@ var ts; // was fine. So if there is any overload that is only incorrect because of an // argument, we will report an error on that one. // - // function foo(s: string) {} - // function foo(n: number) {} // Report argument error on this overload - // function foo() {} + // function foo(s: string): void; + // function foo(n: number): void; // Report argument error on this overload + // function foo(): void; // foo(true); // // If none of the overloads even made it that far, there are two possibilities. @@ -39327,13 +40965,12 @@ var ts; // report an error on that. Or none of the overloads even had correct arity, // in which case give an arity error. // - // function foo(x: T, y: T) {} // Report type argument inference error - // function foo() {} - // foo(0, true); + // function foo(x: T): void; // Report type argument error + // function foo(): void; + // foo(0); // var candidateForArgumentError; var candidateForTypeArgumentError; - var resultOfFailedInference; var result; // If we are in signature help, a trailing comma indicates that we intend to provide another argument, // so we will only accept overloads with arity at least 1 higher than the current number of provided arguments. @@ -39352,10 +40989,6 @@ var ts; result = chooseOverload(candidates, subtypeRelation, signatureHelpTrailingComma); } if (!result) { - // Reinitialize these pointers for round two - candidateForArgumentError = undefined; - candidateForTypeArgumentError = undefined; - resultOfFailedInference = undefined; result = chooseOverload(candidates, assignableRelation, signatureHelpTrailingComma); } if (result) { @@ -39378,24 +41011,42 @@ var ts; checkApplicableSignature(node, args, candidateForArgumentError, assignableRelation, /*excludeArgument*/ undefined, /*reportErrors*/ true); } else if (candidateForTypeArgumentError) { - if (!isTaggedTemplate && !isDecorator && typeArguments) { - var typeArguments_2 = node.typeArguments; - checkTypeArguments(candidateForTypeArgumentError, typeArguments_2, ts.map(typeArguments_2, getTypeFromTypeNode), /*reportErrors*/ true, headMessage); - } - else { - ts.Debug.assert(resultOfFailedInference.failedTypeParameterIndex >= 0); - var failedTypeParameter = candidateForTypeArgumentError.typeParameters[resultOfFailedInference.failedTypeParameterIndex]; - var inferenceCandidates = getInferenceCandidates(resultOfFailedInference, resultOfFailedInference.failedTypeParameterIndex); - var diagnosticChainHead = ts.chainDiagnosticMessages(/*details*/ undefined, // details will be provided by call to reportNoCommonSupertypeError - ts.Diagnostics.The_type_argument_for_type_parameter_0_cannot_be_inferred_from_the_usage_Consider_specifying_the_type_arguments_explicitly, typeToString(failedTypeParameter)); - if (headMessage) { - diagnosticChainHead = ts.chainDiagnosticMessages(diagnosticChainHead, headMessage); - } - reportNoCommonSupertypeError(inferenceCandidates, node.tagName || node.expression || node.tag, diagnosticChainHead); - } - } - else { - reportError(ts.Diagnostics.Supplied_parameters_do_not_match_any_signature_of_call_target); + var typeArguments_1 = node.typeArguments; + checkTypeArguments(candidateForTypeArgumentError, typeArguments_1, ts.map(typeArguments_1, getTypeFromTypeNode), /*reportErrors*/ true, fallbackError); + } + else if (typeArguments && ts.every(signatures, function (sig) { return ts.length(sig.typeParameters) !== typeArguments.length; })) { + var min = Number.POSITIVE_INFINITY; + var max = Number.NEGATIVE_INFINITY; + for (var _i = 0, signatures_5 = signatures; _i < signatures_5.length; _i++) { + var sig = signatures_5[_i]; + min = Math.min(min, getMinTypeArgumentCount(sig.typeParameters)); + max = Math.max(max, ts.length(sig.typeParameters)); + } + var paramCount = min < max ? min + "-" + max : min; + diagnostics.add(ts.createDiagnosticForNode(node, ts.Diagnostics.Expected_0_type_arguments_but_got_1, paramCount, typeArguments.length)); + } + else if (args) { + var min = Number.POSITIVE_INFINITY; + var max = Number.NEGATIVE_INFINITY; + for (var _a = 0, signatures_6 = signatures; _a < signatures_6.length; _a++) { + var sig = signatures_6[_a]; + min = Math.min(min, sig.minArgumentCount); + max = Math.max(max, sig.parameters.length); + } + var hasRestParameter_1 = ts.some(signatures, function (sig) { return sig.hasRestParameter; }); + var hasSpreadArgument = getSpreadArgumentIndex(args) > -1; + var paramCount = hasRestParameter_1 ? min : + min < max ? min + "-" + max : + min; + var argCount = args.length - (hasSpreadArgument ? 1 : 0); + var error_1 = hasRestParameter_1 && hasSpreadArgument ? ts.Diagnostics.Expected_at_least_0_arguments_but_got_a_minimum_of_1 : + hasRestParameter_1 ? ts.Diagnostics.Expected_at_least_0_arguments_but_got_1 : + hasSpreadArgument ? ts.Diagnostics.Expected_0_arguments_but_got_a_minimum_of_1 : + ts.Diagnostics.Expected_0_arguments_but_got_1; + diagnostics.add(ts.createDiagnosticForNode(node, error_1, paramCount, argCount)); + } + else if (fallbackError) { + diagnostics.add(ts.createDiagnosticForNode(node, fallbackError)); } // No signature was applicable. We have already reported the errors for the invalid signature. // If this is a type resolution session, e.g. Language Service, try to get better information that anySignature. @@ -39403,8 +41054,8 @@ var ts; // declare function f(a: { xa: number; xb: number; }); // f({ | if (!produceDiagnostics) { - for (var _i = 0, candidates_1 = candidates; _i < candidates_1.length; _i++) { - var candidate = candidates_1[_i]; + for (var _b = 0, candidates_1 = candidates; _b < candidates_1.length; _b++) { + var candidate = candidates_1[_b]; if (hasCorrectArity(node, args, candidate)) { if (candidate.typeParameters && typeArguments) { candidate = getSignatureInstantiation(candidate, ts.map(typeArguments, getTypeFromTypeNode)); @@ -39414,45 +41065,37 @@ var ts; } } return resolveErrorCall(node); - function reportError(message, arg0, arg1, arg2) { - var errorInfo; - errorInfo = ts.chainDiagnosticMessages(errorInfo, message, arg0, arg1, arg2); - if (headMessage) { - errorInfo = ts.chainDiagnosticMessages(errorInfo, headMessage); - } - diagnostics.add(ts.createDiagnosticForNodeFromMessageChain(node, errorInfo)); - } function chooseOverload(candidates, relation, signatureHelpTrailingComma) { if (signatureHelpTrailingComma === void 0) { signatureHelpTrailingComma = false; } + candidateForArgumentError = undefined; + candidateForTypeArgumentError = undefined; for (var _i = 0, candidates_2 = candidates; _i < candidates_2.length; _i++) { var originalCandidate = candidates_2[_i]; if (!hasCorrectArity(node, args, originalCandidate, signatureHelpTrailingComma)) { continue; } var candidate = void 0; - var typeArgumentsAreValid = void 0; - var inferenceContext = originalCandidate.typeParameters - ? createInferenceContext(originalCandidate, /*inferUnionTypes*/ false, /*useAnyForNoInferences*/ ts.isInJavaScriptFile(node)) - : undefined; + var inferenceContext = originalCandidate.typeParameters ? + createInferenceContext(originalCandidate, /*flags*/ ts.isInJavaScriptFile(node) ? 4 /* AnyDefault */ : 0) : + undefined; while (true) { candidate = originalCandidate; if (candidate.typeParameters) { var typeArgumentTypes = void 0; if (typeArguments) { typeArgumentTypes = fillMissingTypeArguments(ts.map(typeArguments, getTypeFromTypeNode), candidate.typeParameters, getMinTypeArgumentCount(candidate.typeParameters)); - typeArgumentsAreValid = checkTypeArguments(candidate, typeArguments, typeArgumentTypes, /*reportErrors*/ false); + if (!checkTypeArguments(candidate, typeArguments, typeArgumentTypes, /*reportErrors*/ false)) { + candidateForTypeArgumentError = originalCandidate; + break; + } } else { - inferTypeArguments(node, candidate, args, excludeArgument, inferenceContext); - typeArgumentTypes = inferenceContext.inferredTypes; - typeArgumentsAreValid = inferenceContext.failedTypeParameterIndex === undefined; - } - if (!typeArgumentsAreValid) { - break; + typeArgumentTypes = inferTypeArguments(node, candidate, args, excludeArgument, inferenceContext); } candidate = getSignatureInstantiation(candidate, typeArgumentTypes); } if (!checkApplicableSignature(node, args, candidate, relation, excludeArgument, /*reportErrors*/ false)) { + candidateForArgumentError = candidate; break; } var index = excludeArgument ? ts.indexOf(excludeArgument, /*value*/ true) : -1; @@ -39461,27 +41104,6 @@ var ts; } excludeArgument[index] = false; } - // A post-mortem of this iteration of the loop. The signature was not applicable, - // so we want to track it as a candidate for reporting an error. If the candidate - // had no type parameters, or had no issues related to type arguments, we can - // report an error based on the arguments. If there was an issue with type - // arguments, then we can only report an error based on the type arguments. - if (originalCandidate.typeParameters) { - var instantiatedCandidate = candidate; - if (typeArgumentsAreValid) { - candidateForArgumentError = instantiatedCandidate; - } - else { - candidateForTypeArgumentError = originalCandidate; - if (!typeArguments) { - resultOfFailedInference = inferenceContext; - } - } - } - else { - ts.Debug.assert(originalCandidate === candidate); - candidateForArgumentError = originalCandidate; - } } return undefined; } @@ -39619,7 +41241,7 @@ var ts; var callSignatures = getSignaturesOfType(expressionType, 0 /* Call */); if (callSignatures.length) { var signature = resolveCall(node, callSignatures, candidatesOutArray); - if (getReturnTypeOfSignature(signature) !== voidType) { + if (!isJavaScriptConstructor(signature.declaration) && getReturnTypeOfSignature(signature) !== voidType) { error(node, ts.Diagnostics.Only_a_void_function_can_be_called_with_the_new_keyword); } if (getThisTypeOfSignature(signature) === voidType) { @@ -39756,8 +41378,8 @@ var ts; if (elementType.flags & 65536 /* Union */) { var types = elementType.types; var result = void 0; - for (var _i = 0, types_18 = types; _i < types_18.length; _i++) { - var type = types_18[_i]; + for (var _i = 0, types_16 = types; _i < types_16.length; _i++) { + var type = types_16[_i]; result = result || resolveStatelessJsxOpeningLikeElement(openingLikeElement, type, candidatesOutArray); } return result; @@ -39817,13 +41439,35 @@ var ts; // that could cause infinite recursion. Instead, return anySignature. return getNodeLinks(node).resolvedSignature === resolvingSignature ? resolvingSignature : getResolvedSignature(node); } + /** + * Indicates whether a declaration can be treated as a constructor in a JavaScript + * file. + */ + function isJavaScriptConstructor(node) { + if (ts.isInJavaScriptFile(node)) { + // If the node has a @class tag, treat it like a constructor. + if (ts.getJSDocClassTag(node)) + return true; + // If the symbol of the node has members, treat it like a constructor. + var symbol = ts.isFunctionDeclaration(node) || ts.isFunctionExpression(node) ? getSymbolOfNode(node) : + ts.isVariableDeclaration(node) && ts.isFunctionExpression(node.initializer) ? getSymbolOfNode(node.initializer) : + undefined; + return symbol && symbol.members !== undefined; + } + return false; + } function getInferredClassType(symbol) { var links = getSymbolLinks(symbol); if (!links.inferredClassType) { - links.inferredClassType = createAnonymousType(symbol, symbol.members, emptyArray, emptyArray, /*stringIndexType*/ undefined, /*numberIndexType*/ undefined); + links.inferredClassType = createAnonymousType(symbol, symbol.members || emptySymbols, emptyArray, emptyArray, /*stringIndexType*/ undefined, /*numberIndexType*/ undefined); } return links.inferredClassType; } + function isInferredClassType(type) { + return type.symbol + && getObjectFlags(type) & 16 /* Anonymous */ + && getSymbolLinks(type.symbol).inferredClassType === type; + } /** * Syntactically and semantically checks a call or new expression. * @param node The call/new expression to be checked. @@ -39854,7 +41498,7 @@ var ts; if (funcSymbol && ts.isDeclarationOfFunctionOrClassExpression(funcSymbol)) { funcSymbol = getSymbolOfNode(funcSymbol.valueDeclaration.initializer); } - if (funcSymbol && funcSymbol.members && funcSymbol.flags & 16 /* Function */) { + if (funcSymbol && funcSymbol.flags & 16 /* Function */ && (funcSymbol.members || ts.getJSDocClassTag(funcSymbol.valueDeclaration))) { return getInferredClassType(funcSymbol); } else if (noImplicitAny) { @@ -39869,6 +41513,31 @@ var ts; } return getReturnTypeOfSignature(signature); } + function checkImportCallExpression(node) { + // Check grammar of dynamic import + checkGrammarArguments(node, node.arguments) || checkGrammarImportCallExpression(node); + if (node.arguments.length === 0) { + return createPromiseReturnType(node, anyType); + } + var specifier = node.arguments[0]; + var specifierType = checkExpressionCached(specifier); + // Even though multiple arugments is grammatically incorrect, type-check extra arguments for completion + for (var i = 1; i < node.arguments.length; ++i) { + checkExpressionCached(node.arguments[i]); + } + if (specifierType.flags & 2048 /* Undefined */ || specifierType.flags & 4096 /* Null */ || !isTypeAssignableTo(specifierType, stringType)) { + error(specifier, ts.Diagnostics.Dynamic_import_s_specifier_must_be_of_type_string_but_here_has_type_0, typeToString(specifierType)); + } + // resolveExternalModuleName will return undefined if the moduleReferenceExpression is not a string literal + var moduleSymbol = resolveExternalModuleName(node, specifier); + if (moduleSymbol) { + var esModuleSymbol = resolveESModuleSymbol(moduleSymbol, specifier, /*dontRecursivelyResolve*/ true); + if (esModuleSymbol) { + return createPromiseReturnType(node, getTypeOfSymbol(esModuleSymbol)); + } + } + return createPromiseReturnType(node, anyType); + } function isCommonJsRequire(node) { if (!ts.isRequireCall(node, /*checkArgumentIsStringLiteral*/ true)) { return false; @@ -39934,7 +41603,7 @@ var ts; if (strictNullChecks) { var declaration = symbol.valueDeclaration; if (declaration && declaration.initializer) { - return includeFalsyTypes(type, 2048 /* Undefined */); + return getNullableType(type, 2048 /* Undefined */); } } return type; @@ -39947,37 +41616,42 @@ var ts; function getTypeOfFirstParameterOfSignature(signature) { return signature.parameters.length > 0 ? getTypeAtPosition(signature, 0) : neverType; } - function assignContextualParameterTypes(signature, context, mapper, checkMode) { + function inferFromAnnotatedParameters(signature, context, mapper) { var len = signature.parameters.length - (signature.hasRestParameter ? 1 : 0); - if (checkMode === 2 /* Inferential */) { - for (var i = 0; i < len; i++) { - var declaration = signature.parameters[i].valueDeclaration; - if (declaration.type) { - inferTypesWithContext(mapper.context, getTypeFromTypeNode(declaration.type), getTypeAtPosition(context, i)); + for (var i = 0; i < len; i++) { + var declaration = signature.parameters[i].valueDeclaration; + if (declaration.type) { + var typeNode = ts.getEffectiveTypeAnnotationNode(declaration); + if (typeNode) { + inferTypes(mapper.inferences, getTypeFromTypeNode(typeNode), getTypeAtPosition(context, i)); } } } + } + function assignContextualParameterTypes(signature, context) { + signature.typeParameters = context.typeParameters; if (context.thisParameter) { var parameter = signature.thisParameter; if (!parameter || parameter.valueDeclaration && !parameter.valueDeclaration.type) { if (!parameter) { signature.thisParameter = createSymbolWithType(context.thisParameter, /*type*/ undefined); } - assignTypeToParameterAndFixTypeParameters(signature.thisParameter, getTypeOfSymbol(context.thisParameter), mapper, checkMode); + assignTypeToParameterAndFixTypeParameters(signature.thisParameter, getTypeOfSymbol(context.thisParameter)); } } + var len = signature.parameters.length - (signature.hasRestParameter ? 1 : 0); for (var i = 0; i < len; i++) { var parameter = signature.parameters[i]; - if (!parameter.valueDeclaration.type) { + if (!ts.getEffectiveTypeAnnotationNode(parameter.valueDeclaration)) { var contextualParameterType = getTypeAtPosition(context, i); - assignTypeToParameterAndFixTypeParameters(parameter, contextualParameterType, mapper, checkMode); + assignTypeToParameterAndFixTypeParameters(parameter, contextualParameterType); } } if (signature.hasRestParameter && isRestParameterIndex(context, signature.parameters.length - 1)) { var parameter = ts.lastOrUndefined(signature.parameters); - if (!parameter.valueDeclaration.type) { + if (!ts.getEffectiveTypeAnnotationNode(parameter.valueDeclaration)) { var contextualParameterType = getTypeOfSymbol(ts.lastOrUndefined(context.parameters)); - assignTypeToParameterAndFixTypeParameters(parameter, contextualParameterType, mapper, checkMode); + assignTypeToParameterAndFixTypeParameters(parameter, contextualParameterType); } } } @@ -39996,10 +41670,10 @@ var ts; } } } - function assignTypeToParameterAndFixTypeParameters(parameter, contextualType, mapper, checkMode) { + function assignTypeToParameterAndFixTypeParameters(parameter, contextualType) { var links = getSymbolLinks(parameter); if (!links.type) { - links.type = instantiateType(contextualType, mapper); + links.type = contextualType; var name = ts.getNameOfDeclaration(parameter.valueDeclaration); // if inference didn't come up with anything but {}, fall back to the binding pattern if present. if (links.type === emptyObjectType && @@ -40008,45 +41682,6 @@ var ts; } assignBindingElementTypes(parameter.valueDeclaration); } - else if (checkMode === 2 /* Inferential */) { - // Even if the parameter already has a type, it might be because it was given a type while - // processing the function as an argument to a prior signature during overload resolution. - // If this was the case, it may have caused some type parameters to be fixed. So here, - // we need to ensure that type parameters at the same positions get fixed again. This is - // done by calling instantiateType to attach the mapper to the contextualType, and then - // calling inferTypes to force a walk of contextualType so that all the correct fixing - // happens. The choice to pass in links.type may seem kind of arbitrary, but it serves - // to make sure that all the correct positions in contextualType are reached by the walk. - // Here is an example: - // - // interface Base { - // baseProp; - // } - // interface Derived extends Base { - // toBase(): Base; - // } - // - // var derived: Derived; - // - // declare function foo(x: T, func: (p: T) => T): T; - // declare function foo(x: T, func: (p: T) => T): T; - // - // var result = foo(derived, d => d.toBase()); - // - // We are typing d while checking the second overload. But we've already given d - // a type (Derived) from the first overload. However, we still want to fix the - // T in the second overload so that we do not infer Base as a candidate for T - // (inferring Base would make type argument inference inconsistent between the two - // overloads). - inferTypesWithContext(mapper.context, links.type, instantiateType(contextualType, mapper)); - } - } - function getReturnTypeFromJSDocComment(func) { - var returnTag = ts.getJSDocReturnTag(func); - if (returnTag && returnTag.typeExpression) { - return getTypeFromTypeNode(returnTag.typeExpression.type); - } - return undefined; } function createPromiseType(promisedType) { // creates a `Promise` type where `T` is the promisedType argument @@ -40061,11 +41696,15 @@ var ts; function createPromiseReturnType(func, promisedType) { var promiseType = createPromiseType(promisedType); if (promiseType === emptyObjectType) { - error(func, ts.Diagnostics.An_async_function_or_method_must_return_a_Promise_Make_sure_you_have_a_declaration_for_Promise_or_include_ES2015_in_your_lib_option); + error(func, ts.isImportCall(func) ? + ts.Diagnostics.A_dynamic_import_call_returns_a_Promise_Make_sure_you_have_a_declaration_for_Promise_or_include_ES2015_in_your_lib_option : + ts.Diagnostics.An_async_function_or_method_must_return_a_Promise_Make_sure_you_have_a_declaration_for_Promise_or_include_ES2015_in_your_lib_option); return unknownType; } else if (!getGlobalPromiseConstructorSymbol(/*reportErrors*/ true)) { - error(func, ts.Diagnostics.An_async_function_or_method_in_ES5_SlashES3_requires_the_Promise_constructor_Make_sure_you_have_a_declaration_for_the_Promise_constructor_or_include_ES2015_in_your_lib_option); + error(func, ts.isImportCall(func) ? + ts.Diagnostics.A_dynamic_import_call_in_ES5_SlashES3_requires_the_Promise_constructor_Make_sure_you_have_a_declaration_for_the_Promise_constructor_or_include_ES2015_in_your_lib_option : + ts.Diagnostics.An_async_function_or_method_in_ES5_SlashES3_requires_the_Promise_constructor_Make_sure_you_have_a_declaration_for_the_Promise_constructor_or_include_ES2015_in_your_lib_option); } return promiseType; } @@ -40248,16 +41887,16 @@ var ts; } var hasExplicitReturn = func.flags & 256 /* HasExplicitReturn */; if (returnType && returnType.flags & 8192 /* Never */) { - error(func.type, ts.Diagnostics.A_function_returning_never_cannot_have_a_reachable_end_point); + error(ts.getEffectiveReturnTypeNode(func), ts.Diagnostics.A_function_returning_never_cannot_have_a_reachable_end_point); } else if (returnType && !hasExplicitReturn) { // minimal check: function has syntactic return type annotation and no explicit return statements in the body // this function does not conform to the specification. // NOTE: having returnType !== undefined is a precondition for entering this branch so func.type will always be present - error(func.type, ts.Diagnostics.A_function_whose_declared_type_is_neither_void_nor_any_must_return_a_value); + error(ts.getEffectiveReturnTypeNode(func), ts.Diagnostics.A_function_whose_declared_type_is_neither_void_nor_any_must_return_a_value); } else if (returnType && strictNullChecks && !isTypeAssignableTo(undefinedType, returnType)) { - error(func.type, ts.Diagnostics.Function_lacks_ending_return_statement_and_return_type_does_not_include_undefined); + error(ts.getEffectiveReturnTypeNode(func), ts.Diagnostics.Function_lacks_ending_return_statement_and_return_type_does_not_include_undefined); } else if (compilerOptions.noImplicitReturns) { if (!returnType) { @@ -40272,7 +41911,7 @@ var ts; return; } } - error(func.type || func, ts.Diagnostics.Not_all_code_paths_return_a_value); + error(ts.getEffectiveReturnTypeNode(func) || func, ts.Diagnostics.Not_all_code_paths_return_a_value); } } function checkFunctionExpressionOrObjectLiteralMethod(node, checkMode) { @@ -40289,35 +41928,34 @@ var ts; } var links = getNodeLinks(node); var type = getTypeOfSymbol(node.symbol); - var contextSensitive = isContextSensitive(node); - var mightFixTypeParameters = contextSensitive && checkMode === 2 /* Inferential */; // Check if function expression is contextually typed and assign parameter types if so. - // See the comment in assignTypeToParameterAndFixTypeParameters to understand why we need to - // check mightFixTypeParameters. - if (mightFixTypeParameters || !(links.flags & 1024 /* ContextChecked */)) { + if (!(links.flags & 1024 /* ContextChecked */)) { var contextualSignature = getContextualSignature(node); // If a type check is started at a function expression that is an argument of a function call, obtaining the // contextual type may recursively get back to here during overload resolution of the call. If so, we will have // already assigned contextual types. - var contextChecked = !!(links.flags & 1024 /* ContextChecked */); - if (mightFixTypeParameters || !contextChecked) { + if (!(links.flags & 1024 /* ContextChecked */)) { links.flags |= 1024 /* ContextChecked */; if (contextualSignature) { var signature = getSignaturesOfType(type, 0 /* Call */)[0]; - if (contextSensitive) { - assignContextualParameterTypes(signature, contextualSignature, getContextualMapper(node), checkMode); + if (isContextSensitive(node)) { + var contextualMapper = getContextualMapper(node); + if (checkMode === 2 /* Inferential */) { + inferFromAnnotatedParameters(signature, contextualSignature, contextualMapper); + } + var instantiatedContextualSignature = contextualMapper === identityMapper ? + contextualSignature : instantiateSignature(contextualSignature, contextualMapper); + assignContextualParameterTypes(signature, instantiatedContextualSignature); } - if (mightFixTypeParameters || !node.type && !signature.resolvedReturnType) { + if (!ts.getEffectiveReturnTypeNode(node) && !signature.resolvedReturnType) { var returnType = getReturnTypeFromBody(node, checkMode); if (!signature.resolvedReturnType) { signature.resolvedReturnType = returnType; } } } - if (!contextChecked) { - checkSignatureDeclaration(node); - checkNodeDeferred(node); - } + checkSignatureDeclaration(node); + checkNodeDeferred(node); } } if (produceDiagnostics && node.kind !== 151 /* MethodDeclaration */) { @@ -40330,16 +41968,17 @@ var ts; function checkFunctionExpressionOrObjectLiteralMethodDeferred(node) { ts.Debug.assert(node.kind !== 151 /* MethodDeclaration */ || ts.isObjectLiteralMethod(node)); var functionFlags = ts.getFunctionFlags(node); - var returnOrPromisedType = node.type && + var returnTypeNode = ts.getEffectiveReturnTypeNode(node); + var returnOrPromisedType = returnTypeNode && ((functionFlags & 3 /* AsyncGenerator */) === 2 /* Async */ ? checkAsyncFunctionReturnType(node) : - getTypeFromTypeNode(node.type)); // AsyncGenerator function, Generator function, or normal function + getTypeFromTypeNode(returnTypeNode)); // AsyncGenerator function, Generator function, or normal function if ((functionFlags & 1 /* Generator */) === 0) { // return is not necessary in the body of generators checkAllCodePathsInNonVoidFunctionReturnOrThrow(node, returnOrPromisedType); } if (node.body) { - if (!node.type) { + if (!returnTypeNode) { // There are some checks that are only performed in getReturnTypeFromBody, that may produce errors // we need. An example is the noImplicitAny errors resulting from widening the return expression // of a function. Because checking of function expression bodies is deferred, there was never an @@ -40371,7 +42010,7 @@ var ts; } } function checkArithmeticOperandType(operand, type, diagnostic) { - if (!isTypeAnyOrAllConstituentTypesHaveKind(type, 340 /* NumberLike */)) { + if (!isTypeAnyOrAllConstituentTypesHaveKind(type, 84 /* NumberLike */)) { error(operand, diagnostic); return false; } @@ -40384,8 +42023,8 @@ var ts; // Get accessors without matching set accessors // Enum members // Unions and intersections of the above (unions and intersections eagerly set isReadonly on creation) - return !!(getCheckFlags(symbol) & 8 /* Readonly */ || - symbol.flags & 4 /* Property */ && getDeclarationModifierFlagsFromSymbol(symbol) & 64 /* Readonly */ || + return !!(ts.getCheckFlags(symbol) & 8 /* Readonly */ || + symbol.flags & 4 /* Property */ && ts.getDeclarationModifierFlagsFromSymbol(symbol) & 64 /* Readonly */ || symbol.flags & 3 /* Variable */ && getDeclarationNodeFlagsFromSymbol(symbol) & 2 /* Const */ || symbol.flags & 98304 /* Accessor */ && !(symbol.flags & 65536 /* SetAccessor */) || symbol.flags & 8 /* EnumMember */); @@ -40398,8 +42037,9 @@ var ts; expr.expression.kind === 99 /* ThisKeyword */) { // Look for if this is the constructor for the class that `symbol` is a property of. var func = ts.getContainingFunction(expr); - if (!(func && func.kind === 152 /* Constructor */)) + if (!(func && func.kind === 152 /* Constructor */)) { return true; + } // If func.parent is a class and symbol is a (readonly) property of that class, or // if func is a constructor and symbol is a (readonly) parameter property declared in it, // then symbol is writeable here. @@ -40424,7 +42064,7 @@ var ts; } function checkReferenceExpression(expr, invalidReferenceMessage) { // References are combinations of identifiers, parentheses, and property accesses. - var node = ts.skipParentheses(expr); + var node = ts.skipOuterExpressions(expr, 2 /* Assertions */ | 1 /* Parentheses */); if (node.kind !== 71 /* Identifier */ && node.kind !== 179 /* PropertyAccessExpression */ && node.kind !== 180 /* ElementAccessExpression */) { error(expr, invalidReferenceMessage); return false; @@ -40472,7 +42112,7 @@ var ts; return silentNeverType; } if (node.operator === 38 /* MinusToken */ && node.operand.kind === 8 /* NumericLiteral */) { - return getFreshTypeOfLiteralType(getLiteralTypeForText(64 /* NumberLiteral */, "" + -node.operand.text)); + return getFreshTypeOfLiteralType(getLiteralType(-node.operand.text)); } switch (node.operator) { case 37 /* PlusToken */: @@ -40519,8 +42159,8 @@ var ts; } if (type.flags & 196608 /* UnionOrIntersection */) { var types = type.types; - for (var _i = 0, types_19 = types; _i < types_19.length; _i++) { - var t = types_19[_i]; + for (var _i = 0, types_17 = types; _i < types_17.length; _i++) { + var t = types_17[_i]; if (maybeTypeOfKind(t, kind)) { return true; } @@ -40537,8 +42177,8 @@ var ts; } if (type.flags & 65536 /* Union */) { var types = type.types; - for (var _i = 0, types_20 = types; _i < types_20.length; _i++) { - var t = types_20[_i]; + for (var _i = 0, types_18 = types; _i < types_18.length; _i++) { + var t = types_18[_i]; if (!isTypeOfKind(t, kind)) { return false; } @@ -40547,8 +42187,8 @@ var ts; } if (type.flags & 131072 /* Intersection */) { var types = type.types; - for (var _a = 0, types_21 = types; _a < types_21.length; _a++) { - var t = types_21[_a]; + for (var _a = 0, types_19 = types; _a < types_19.length; _a++) { + var t = types_19[_a]; if (isTypeOfKind(t, kind)) { return true; } @@ -40593,7 +42233,7 @@ var ts; // The in operator requires the left operand to be of type Any, the String primitive type, or the Number primitive type, // and the right operand to be of type Any, an object type, or a type parameter type. // The result is always of the Boolean primitive type. - if (!(isTypeComparableTo(leftType, stringType) || isTypeOfKind(leftType, 340 /* NumberLike */ | 512 /* ESSymbol */))) { + if (!(isTypeComparableTo(leftType, stringType) || isTypeOfKind(leftType, 84 /* NumberLike */ | 512 /* ESSymbol */))) { error(left, ts.Diagnostics.The_left_hand_side_of_an_in_expression_must_be_of_type_any_string_number_or_symbol); } if (!isTypeAnyOrAllConstituentTypesHaveKind(rightType, 32768 /* Object */ | 540672 /* TypeVariable */ | 16777216 /* NonPrimitive */)) { @@ -40662,7 +42302,7 @@ var ts; // This elementType will be used if the specific property corresponding to this index is not // present (aka the tuple element property). This call also checks that the parentType is in // fact an iterable or array (depending on target language). - var elementType = checkIteratedTypeOrElementType(sourceType, node, /*allowStringInput*/ false, /*allowAsyncIterable*/ false) || unknownType; + var elementType = checkIteratedTypeOrElementType(sourceType, node, /*allowStringInput*/ false, /*allowAsyncIterables*/ false) || unknownType; var elements = node.elements; for (var i = 0; i < elements.length; i++) { checkArrayLiteralDestructuringElementAssignment(node, sourceType, i, elementType, checkMode); @@ -40888,7 +42528,7 @@ var ts; rightType = checkNonNullType(rightType, right); } var resultType = void 0; - if (isTypeOfKind(leftType, 340 /* NumberLike */) && isTypeOfKind(rightType, 340 /* NumberLike */)) { + if (isTypeOfKind(leftType, 84 /* NumberLike */) && isTypeOfKind(rightType, 84 /* NumberLike */)) { // Operands of an enum type are treated as having the primitive type Number. // If both operands are of the Number primitive type, the result is of the Number primitive type. resultType = numberType; @@ -40948,7 +42588,7 @@ var ts; return checkInExpression(left, right, leftType, rightType); case 53 /* AmpersandAmpersandToken */: return getTypeFacts(leftType) & 1048576 /* Truthy */ ? - includeFalsyTypes(rightType, getFalsyFlags(strictNullChecks ? leftType : getBaseTypeOfLiteralType(rightType))) : + getUnionType([extractDefinitelyFalsyTypes(strictNullChecks ? leftType : getBaseTypeOfLiteralType(rightType)), rightType]) : leftType; case 54 /* BarBarToken */: return getTypeFacts(leftType) & 2097152 /* Falsy */ ? @@ -40993,7 +42633,7 @@ var ts; } } function checkAssignmentOperator(valueType) { - if (produceDiagnostics && operator >= 58 /* FirstAssignment */ && operator <= 70 /* LastAssignment */) { + if (produceDiagnostics && ts.isAssignmentOperator(operator)) { // TypeScript 1.0 spec (April 2014): 4.17 // An assignment of the form // VarExpr = ValueExpr @@ -41063,8 +42703,9 @@ var ts; // There is no point in doing an assignability check if the function // has no explicit return type because the return type is directly computed // from the yield expressions. - if (func.type) { - var signatureElementType = getIteratedTypeOfGenerator(getTypeFromTypeNode(func.type), (functionFlags & 2 /* Async */) !== 0) || anyType; + var returnType = ts.getEffectiveReturnTypeNode(func); + if (returnType) { + var signatureElementType = getIteratedTypeOfGenerator(getTypeFromTypeNode(returnType), (functionFlags & 2 /* Async */) !== 0) || anyType; if (nodeIsYieldStar) { checkTypeAssignableTo(functionFlags & 2 /* Async */ ? getAwaitedType(expressionElementType, node.expression, ts.Diagnostics.Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member) @@ -41095,9 +42736,9 @@ var ts; } switch (node.kind) { case 9 /* StringLiteral */: - return getFreshTypeOfLiteralType(getLiteralTypeForText(32 /* StringLiteral */, node.text)); + return getFreshTypeOfLiteralType(getLiteralType(node.text)); case 8 /* NumericLiteral */: - return getFreshTypeOfLiteralType(getLiteralTypeForText(64 /* NumberLiteral */, node.text)); + return getFreshTypeOfLiteralType(getLiteralType(+node.text)); case 101 /* TrueKeyword */: return trueType; case 86 /* FalseKeyword */: @@ -41162,7 +42803,7 @@ var ts; } contextualType = constraint; } - return maybeTypeOfKind(contextualType, (480 /* Literal */ | 262144 /* Index */)); + return maybeTypeOfKind(contextualType, (224 /* Literal */ | 262144 /* Index */)); } return false; } @@ -41197,7 +42838,7 @@ var ts; if (signature && signature.typeParameters) { var contextualType = getApparentTypeOfContextualType(node); if (contextualType) { - var contextualSignature = getSingleCallSignature(contextualType); + var contextualSignature = getSingleCallSignature(getNonNullableType(contextualType)); if (contextualSignature && !contextualSignature.typeParameters) { return getOrCreateTypeFromSignature(instantiateSignatureInContextOf(signature, contextualSignature, getContextualMapper(node))); } @@ -41301,6 +42942,10 @@ var ts; case 180 /* ElementAccessExpression */: return checkIndexedAccess(node); case 181 /* CallExpression */: + if (node.expression.kind === 91 /* ImportKeyword */) { + return checkImportCallExpression(node); + } + /* falls through */ case 182 /* NewExpression */: return checkCallExpression(node); case 183 /* TaggedTemplateExpression */: @@ -41524,12 +43169,14 @@ var ts; } checkTypeParameters(node.typeParameters); ts.forEach(node.parameters, checkParameter); + // TODO(rbuckton): Should we start checking JSDoc types? if (node.type) { checkSourceElement(node.type); } if (produceDiagnostics) { checkCollisionWithArgumentsInGeneratedCode(node); - if (noImplicitAny && !node.type) { + var returnTypeNode = ts.getEffectiveReturnTypeNode(node); + if (noImplicitAny && !returnTypeNode) { switch (node.kind) { case 156 /* ConstructSignature */: error(node, ts.Diagnostics.Construct_signature_which_lacks_return_type_annotation_implicitly_has_an_any_return_type); @@ -41539,12 +43186,12 @@ var ts; break; } } - if (node.type) { + if (returnTypeNode) { var functionFlags_1 = ts.getFunctionFlags(node); if ((functionFlags_1 & (4 /* Invalid */ | 1 /* Generator */)) === 1 /* Generator */) { - var returnType = getTypeFromTypeNode(node.type); + var returnType = getTypeFromTypeNode(returnTypeNode); if (returnType === voidType) { - error(node.type, ts.Diagnostics.A_generator_cannot_have_a_void_type_annotation); + error(returnTypeNode, ts.Diagnostics.A_generator_cannot_have_a_void_type_annotation); } else { var generatorElementType = getIteratedTypeOfGenerator(returnType, (functionFlags_1 & 2 /* Async */) !== 0) || anyType; @@ -41557,7 +43204,7 @@ var ts; // interface BadGenerator extends Iterable, Iterator { } // function* g(): BadGenerator { } // Iterable and Iterator have different types! // - checkTypeAssignableTo(iterableIteratorInstantiation, returnType, node.type); + checkTypeAssignableTo(iterableIteratorInstantiation, returnType, returnTypeNode); } } else if ((functionFlags_1 & 3 /* AsyncGenerator */) === 2 /* Async */) { @@ -41925,7 +43572,7 @@ var ts; checkTypeArgumentConstraints(typeParameters, node.typeArguments); } } - if (type.flags & 16 /* Enum */ && !type.memberTypes && getNodeLinks(node).resolvedSymbol.flags & 8 /* EnumMember */) { + if (type.flags & 16 /* Enum */ && getNodeLinks(node).resolvedSymbol.flags & 8 /* EnumMember */) { error(node, ts.Diagnostics.Enum_type_0_has_members_with_initializers_that_are_not_literals, typeToString(type)); } } @@ -41968,7 +43615,7 @@ var ts; } // Check if we're indexing with a numeric type and the object type is a generic // type with a constraint that has a numeric index signature. - if (maybeTypeOfKind(objectType, 540672 /* TypeVariable */) && isTypeOfKind(indexType, 340 /* NumberLike */)) { + if (maybeTypeOfKind(objectType, 540672 /* TypeVariable */) && isTypeOfKind(indexType, 84 /* NumberLike */)) { var constraint = getBaseConstraintOfType(objectType); if (constraint && getIndexInfoOfType(constraint, 1 /* Number */)) { return type; @@ -42186,8 +43833,8 @@ var ts; if (bodyDeclaration) { var signatures = getSignaturesOfSymbol(symbol); var bodySignature = getSignatureFromDeclaration(bodyDeclaration); - for (var _a = 0, signatures_5 = signatures; _a < signatures_5.length; _a++) { - var signature = signatures_5[_a]; + for (var _a = 0, signatures_7 = signatures; _a < signatures_7.length; _a++) { + var signature = signatures_7[_a]; if (!isImplementationCompatibleWithOverload(bodySignature, signature)) { error(signature.declaration, ts.Diagnostics.Overload_signature_is_not_compatible_with_function_implementation); break; @@ -42471,7 +44118,8 @@ var ts; // then(...): Promise; // } // - var returnType = getTypeFromTypeNode(node.type); + var returnTypeNode = ts.getEffectiveReturnTypeNode(node); + var returnType = getTypeFromTypeNode(returnTypeNode); if (languageVersion >= 2 /* ES2015 */) { if (returnType === unknownType) { return unknownType; @@ -42480,29 +44128,29 @@ var ts; if (globalPromiseType !== emptyGenericType && !isReferenceToType(returnType, globalPromiseType)) { // The promise type was not a valid type reference to the global promise type, so we // report an error and return the unknown type. - error(node.type, ts.Diagnostics.The_return_type_of_an_async_function_or_method_must_be_the_global_Promise_T_type); + error(returnTypeNode, ts.Diagnostics.The_return_type_of_an_async_function_or_method_must_be_the_global_Promise_T_type); return unknownType; } } else { // Always mark the type node as referenced if it points to a value - markTypeNodeAsReferenced(node.type); + markTypeNodeAsReferenced(returnTypeNode); if (returnType === unknownType) { return unknownType; } - var promiseConstructorName = ts.getEntityNameFromTypeNode(node.type); + var promiseConstructorName = ts.getEntityNameFromTypeNode(returnTypeNode); if (promiseConstructorName === undefined) { - error(node.type, ts.Diagnostics.Type_0_is_not_a_valid_async_function_return_type_in_ES5_SlashES3_because_it_does_not_refer_to_a_Promise_compatible_constructor_value, typeToString(returnType)); + error(returnTypeNode, ts.Diagnostics.Type_0_is_not_a_valid_async_function_return_type_in_ES5_SlashES3_because_it_does_not_refer_to_a_Promise_compatible_constructor_value, typeToString(returnType)); return unknownType; } var promiseConstructorSymbol = resolveEntityName(promiseConstructorName, 107455 /* Value */, /*ignoreErrors*/ true); var promiseConstructorType = promiseConstructorSymbol ? getTypeOfSymbol(promiseConstructorSymbol) : unknownType; if (promiseConstructorType === unknownType) { if (promiseConstructorName.kind === 71 /* Identifier */ && promiseConstructorName.text === "Promise" && getTargetType(returnType) === getGlobalPromiseType(/*reportErrors*/ false)) { - error(node.type, ts.Diagnostics.An_async_function_or_method_in_ES5_SlashES3_requires_the_Promise_constructor_Make_sure_you_have_a_declaration_for_the_Promise_constructor_or_include_ES2015_in_your_lib_option); + error(returnTypeNode, ts.Diagnostics.An_async_function_or_method_in_ES5_SlashES3_requires_the_Promise_constructor_Make_sure_you_have_a_declaration_for_the_Promise_constructor_or_include_ES2015_in_your_lib_option); } else { - error(node.type, ts.Diagnostics.Type_0_is_not_a_valid_async_function_return_type_in_ES5_SlashES3_because_it_does_not_refer_to_a_Promise_compatible_constructor_value, ts.entityNameToString(promiseConstructorName)); + error(returnTypeNode, ts.Diagnostics.Type_0_is_not_a_valid_async_function_return_type_in_ES5_SlashES3_because_it_does_not_refer_to_a_Promise_compatible_constructor_value, ts.entityNameToString(promiseConstructorName)); } return unknownType; } @@ -42510,10 +44158,10 @@ var ts; if (globalPromiseConstructorLikeType === emptyObjectType) { // If we couldn't resolve the global PromiseConstructorLike type we cannot verify // compatibility with __awaiter. - error(node.type, ts.Diagnostics.Type_0_is_not_a_valid_async_function_return_type_in_ES5_SlashES3_because_it_does_not_refer_to_a_Promise_compatible_constructor_value, ts.entityNameToString(promiseConstructorName)); + error(returnTypeNode, ts.Diagnostics.Type_0_is_not_a_valid_async_function_return_type_in_ES5_SlashES3_because_it_does_not_refer_to_a_Promise_compatible_constructor_value, ts.entityNameToString(promiseConstructorName)); return unknownType; } - if (!checkTypeAssignableTo(promiseConstructorType, globalPromiseConstructorLikeType, node.type, ts.Diagnostics.Type_0_is_not_a_valid_async_function_return_type_in_ES5_SlashES3_because_it_does_not_refer_to_a_Promise_compatible_constructor_value)) { + if (!checkTypeAssignableTo(promiseConstructorType, globalPromiseConstructorLikeType, returnTypeNode, ts.Diagnostics.Type_0_is_not_a_valid_async_function_return_type_in_ES5_SlashES3_because_it_does_not_refer_to_a_Promise_compatible_constructor_value)) { return unknownType; } // Verify there is no local declaration that could collide with the promise constructor. @@ -42566,7 +44214,9 @@ var ts; * marked as referenced to prevent import elision. */ function markTypeNodeAsReferenced(node) { - var typeName = node && ts.getEntityNameFromTypeNode(node); + markEntityNameOrEntityExpressionAsReference(node && ts.getEntityNameFromTypeNode(node)); + } + function markEntityNameOrEntityExpressionAsReference(typeName) { var rootName = typeName && getFirstIdentifier(typeName); var rootSymbol = rootName && resolveName(rootName, rootName.text, (typeName.kind === 71 /* Identifier */ ? 793064 /* Type */ : 1920 /* Namespace */) | 8388608 /* Alias */, /*nameNotFoundMessage*/ undefined, /*nameArg*/ undefined); if (rootSymbol @@ -42576,8 +44226,60 @@ var ts; markAliasSymbolAsReferenced(rootSymbol); } } + /** + * This function marks the type used for metadata decorator as referenced if it is import + * from external module. + * This is different from markTypeNodeAsReferenced because it tries to simplify type nodes in + * union and intersection type + * @param node + */ + function markDecoratorMedataDataTypeNodeAsReferenced(node) { + var entityName = getEntityNameForDecoratorMetadata(node); + if (entityName && ts.isEntityName(entityName)) { + markEntityNameOrEntityExpressionAsReference(entityName); + } + } + function getEntityNameForDecoratorMetadata(node) { + if (node) { + switch (node.kind) { + case 167 /* IntersectionType */: + case 166 /* UnionType */: + var commonEntityName = void 0; + for (var _i = 0, _a = node.types; _i < _a.length; _i++) { + var typeNode = _a[_i]; + var individualEntityName = getEntityNameForDecoratorMetadata(typeNode); + if (!individualEntityName) { + // Individual is something like string number + // So it would be serialized to either that type or object + // Safe to return here + return undefined; + } + if (commonEntityName) { + // Note this is in sync with the transformation that happens for type node. + // Keep this in sync with serializeUnionOrIntersectionType + // Verify if they refer to same entity and is identifier + // return undefined if they dont match because we would emit object + if (!ts.isIdentifier(commonEntityName) || + !ts.isIdentifier(individualEntityName) || + commonEntityName.text !== individualEntityName.text) { + return undefined; + } + } + else { + commonEntityName = individualEntityName; + } + } + return commonEntityName; + case 168 /* ParenthesizedType */: + return getEntityNameForDecoratorMetadata(node.type); + case 159 /* TypeReference */: + return node.typeName; + } + } + } function getParameterTypeNodeForDecoratorCheck(node) { - return node.dotDotDotToken ? ts.getRestParameterElementType(node.type) : node.type; + var typeNode = ts.getEffectiveTypeAnnotationNode(node); + return ts.isRestParameter(node) ? ts.getRestParameterElementType(typeNode) : typeNode; } /** Check the decorators of a node */ function checkDecorators(node) { @@ -42606,7 +44308,7 @@ var ts; if (constructor) { for (var _i = 0, _a = constructor.parameters; _i < _a.length; _i++) { var parameter = _a[_i]; - markTypeNodeAsReferenced(getParameterTypeNodeForDecoratorCheck(parameter)); + markDecoratorMedataDataTypeNodeAsReferenced(getParameterTypeNodeForDecoratorCheck(parameter)); } } break; @@ -42615,15 +44317,15 @@ var ts; case 154 /* SetAccessor */: for (var _b = 0, _c = node.parameters; _b < _c.length; _b++) { var parameter = _c[_b]; - markTypeNodeAsReferenced(getParameterTypeNodeForDecoratorCheck(parameter)); + markDecoratorMedataDataTypeNodeAsReferenced(getParameterTypeNodeForDecoratorCheck(parameter)); } - markTypeNodeAsReferenced(node.type); + markDecoratorMedataDataTypeNodeAsReferenced(ts.getEffectiveReturnTypeNode(node)); break; case 149 /* PropertyDeclaration */: - markTypeNodeAsReferenced(getParameterTypeNodeForDecoratorCheck(node)); + markDecoratorMedataDataTypeNodeAsReferenced(ts.getEffectiveTypeAnnotationNode(node)); break; case 146 /* Parameter */: - markTypeNodeAsReferenced(node.type); + markDecoratorMedataDataTypeNodeAsReferenced(getParameterTypeNodeForDecoratorCheck(node)); break; } } @@ -42631,7 +44333,8 @@ var ts; } function checkFunctionDeclaration(node) { if (produceDiagnostics) { - checkFunctionOrMethodDeclaration(node) || checkGrammarForGenerator(node); + checkFunctionOrMethodDeclaration(node); + checkGrammarForGenerator(node); checkCollisionWithCapturedSuperVariable(node, node.name); checkCollisionWithCapturedThisVariable(node, node.name); checkCollisionWithCapturedNewTargetVariable(node, node.name); @@ -42677,13 +44380,14 @@ var ts; } } checkSourceElement(node.body); + var returnTypeNode = ts.getEffectiveReturnTypeNode(node); if ((functionFlags & 1 /* Generator */) === 0) { - var returnOrPromisedType = node.type && (functionFlags & 2 /* Async */ + var returnOrPromisedType = returnTypeNode && (functionFlags & 2 /* Async */ ? checkAsyncFunctionReturnType(node) // Async function - : getTypeFromTypeNode(node.type)); // normal function + : getTypeFromTypeNode(returnTypeNode)); // normal function checkAllCodePathsInNonVoidFunctionReturnOrThrow(node, returnOrPromisedType); } - if (produceDiagnostics && !node.type) { + if (produceDiagnostics && !returnTypeNode) { // Report an implicit any error if there is no body, no explicit return type, and node is not a private method // in an ambient context if (noImplicitAny && ts.nodeIsMissing(node.body) && !isPrivateWithinAmbient(node)) { @@ -42782,9 +44486,7 @@ var ts; function errorUnusedLocal(node, name) { if (isIdentifierThatStartsWithUnderScore(node)) { var declaration = ts.getRootDeclaration(node.parent); - if (declaration.kind === 226 /* VariableDeclaration */ && - (declaration.parent.parent.kind === 215 /* ForInStatement */ || - declaration.parent.parent.kind === 216 /* ForOfStatement */)) { + if (declaration.kind === 226 /* VariableDeclaration */ && ts.isForInOrOfStatement(declaration.parent.parent)) { return; } } @@ -43411,26 +45113,26 @@ var ts; var expressionType = checkNonNullExpression(rhsExpression); return checkIteratedTypeOrElementType(expressionType, rhsExpression, /*allowStringInput*/ true, awaitModifier !== undefined); } - function checkIteratedTypeOrElementType(inputType, errorNode, allowStringInput, allowAsyncIterable) { + function checkIteratedTypeOrElementType(inputType, errorNode, allowStringInput, allowAsyncIterables) { if (isTypeAny(inputType)) { return inputType; } - return getIteratedTypeOrElementType(inputType, errorNode, allowStringInput, allowAsyncIterable, /*checkAssignability*/ true) || anyType; + return getIteratedTypeOrElementType(inputType, errorNode, allowStringInput, allowAsyncIterables, /*checkAssignability*/ true) || anyType; } /** * When consuming an iterable type in a for..of, spread, or iterator destructuring assignment * we want to get the iterated type of an iterable for ES2015 or later, or the iterated type * of a iterable (if defined globally) or element type of an array like for ES2015 or earlier. */ - function getIteratedTypeOrElementType(inputType, errorNode, allowStringInput, allowAsyncIterable, checkAssignability) { + function getIteratedTypeOrElementType(inputType, errorNode, allowStringInput, allowAsyncIterables, checkAssignability) { var uplevelIteration = languageVersion >= 2 /* ES2015 */; var downlevelIteration = !uplevelIteration && compilerOptions.downlevelIteration; // Get the iterated type of an `Iterable` or `IterableIterator` only in ES2015 // or higher, when inside of an async generator or for-await-if, or when // downlevelIteration is requested. - if (uplevelIteration || downlevelIteration || allowAsyncIterable) { + if (uplevelIteration || downlevelIteration || allowAsyncIterables) { // We only report errors for an invalid iterable type in ES2015 or higher. - var iteratedType = getIteratedTypeOfIterable(inputType, uplevelIteration ? errorNode : undefined, allowAsyncIterable, allowAsyncIterable, checkAssignability); + var iteratedType = getIteratedTypeOfIterable(inputType, uplevelIteration ? errorNode : undefined, allowAsyncIterables, /*allowSyncIterables*/ true, checkAssignability); if (iteratedType || uplevelIteration) { return iteratedType; } @@ -43535,70 +45237,65 @@ var ts; * For a **for-await-of** statement or a `yield*` in an async generator we will look for * the `[Symbol.asyncIterator]()` method first, and then the `[Symbol.iterator]()` method. */ - function getIteratedTypeOfIterable(type, errorNode, isAsyncIterable, allowNonAsyncIterables, checkAssignability) { + function getIteratedTypeOfIterable(type, errorNode, allowAsyncIterables, allowSyncIterables, checkAssignability) { if (isTypeAny(type)) { return undefined; } - var typeAsIterable = type; - if (isAsyncIterable ? typeAsIterable.iteratedTypeOfAsyncIterable : typeAsIterable.iteratedTypeOfIterable) { - return isAsyncIterable ? typeAsIterable.iteratedTypeOfAsyncIterable : typeAsIterable.iteratedTypeOfIterable; - } - if (isAsyncIterable) { - // As an optimization, if the type is an instantiation of the global `AsyncIterable` - // or the global `AsyncIterableIterator` then just grab its type argument. - if (isReferenceToType(type, getGlobalAsyncIterableType(/*reportErrors*/ false)) || - isReferenceToType(type, getGlobalAsyncIterableIteratorType(/*reportErrors*/ false))) { - return typeAsIterable.iteratedTypeOfAsyncIterable = type.typeArguments[0]; - } - } - if (!isAsyncIterable || allowNonAsyncIterables) { - // As an optimization, if the type is an instantiation of the global `Iterable` or - // `IterableIterator` then just grab its type argument. - if (isReferenceToType(type, getGlobalIterableType(/*reportErrors*/ false)) || - isReferenceToType(type, getGlobalIterableIteratorType(/*reportErrors*/ false))) { - return isAsyncIterable - ? typeAsIterable.iteratedTypeOfAsyncIterable = type.typeArguments[0] - : typeAsIterable.iteratedTypeOfIterable = type.typeArguments[0]; - } - } - var iteratorMethodSignatures; - var isNonAsyncIterable = false; - if (isAsyncIterable) { - var iteratorMethod = getTypeOfPropertyOfType(type, ts.getPropertyNameForKnownSymbolName("asyncIterator")); - if (isTypeAny(iteratorMethod)) { + return mapType(type, getIteratedType); + function getIteratedType(type) { + var typeAsIterable = type; + if (allowAsyncIterables) { + if (typeAsIterable.iteratedTypeOfAsyncIterable) { + return typeAsIterable.iteratedTypeOfAsyncIterable; + } + // As an optimization, if the type is an instantiation of the global `AsyncIterable` + // or the global `AsyncIterableIterator` then just grab its type argument. + if (isReferenceToType(type, getGlobalAsyncIterableType(/*reportErrors*/ false)) || + isReferenceToType(type, getGlobalAsyncIterableIteratorType(/*reportErrors*/ false))) { + return typeAsIterable.iteratedTypeOfAsyncIterable = type.typeArguments[0]; + } + } + if (allowSyncIterables) { + if (typeAsIterable.iteratedTypeOfIterable) { + return typeAsIterable.iteratedTypeOfIterable; + } + // As an optimization, if the type is an instantiation of the global `Iterable` or + // `IterableIterator` then just grab its type argument. + if (isReferenceToType(type, getGlobalIterableType(/*reportErrors*/ false)) || + isReferenceToType(type, getGlobalIterableIteratorType(/*reportErrors*/ false))) { + return typeAsIterable.iteratedTypeOfIterable = type.typeArguments[0]; + } + } + var asyncMethodType = allowAsyncIterables && getTypeOfPropertyOfType(type, ts.getPropertyNameForKnownSymbolName("asyncIterator")); + var methodType = asyncMethodType || (allowSyncIterables && getTypeOfPropertyOfType(type, ts.getPropertyNameForKnownSymbolName("iterator"))); + if (isTypeAny(methodType)) { return undefined; } - iteratorMethodSignatures = iteratorMethod && getSignaturesOfType(iteratorMethod, 0 /* Call */); - } - if (!isAsyncIterable || (allowNonAsyncIterables && !ts.some(iteratorMethodSignatures))) { - var iteratorMethod = getTypeOfPropertyOfType(type, ts.getPropertyNameForKnownSymbolName("iterator")); - if (isTypeAny(iteratorMethod)) { + var signatures = methodType && getSignaturesOfType(methodType, 0 /* Call */); + if (!ts.some(signatures)) { + if (errorNode) { + error(errorNode, allowAsyncIterables + ? ts.Diagnostics.Type_must_have_a_Symbol_asyncIterator_method_that_returns_an_async_iterator + : ts.Diagnostics.Type_must_have_a_Symbol_iterator_method_that_returns_an_iterator); + // only report on the first error + errorNode = undefined; + } return undefined; } - iteratorMethodSignatures = iteratorMethod && getSignaturesOfType(iteratorMethod, 0 /* Call */); - isNonAsyncIterable = true; - } - if (ts.some(iteratorMethodSignatures)) { - var iteratorMethodReturnType = getUnionType(ts.map(iteratorMethodSignatures, getReturnTypeOfSignature), /*subtypeReduction*/ true); - var iteratedType = getIteratedTypeOfIterator(iteratorMethodReturnType, errorNode, /*isAsyncIterator*/ !isNonAsyncIterable); + var returnType = getUnionType(ts.map(signatures, getReturnTypeOfSignature), /*subtypeReduction*/ true); + var iteratedType = getIteratedTypeOfIterator(returnType, errorNode, /*isAsyncIterator*/ !!asyncMethodType); if (checkAssignability && errorNode && iteratedType) { // If `checkAssignability` was specified, we were called from // `checkIteratedTypeOrElementType`. As such, we need to validate that // the type passed in is actually an Iterable. - checkTypeAssignableTo(type, isNonAsyncIterable - ? createIterableType(iteratedType) - : createAsyncIterableType(iteratedType), errorNode); + checkTypeAssignableTo(type, asyncMethodType + ? createAsyncIterableType(iteratedType) + : createIterableType(iteratedType), errorNode); } - return isAsyncIterable + return asyncMethodType ? typeAsIterable.iteratedTypeOfAsyncIterable = iteratedType : typeAsIterable.iteratedTypeOfIterable = iteratedType; } - if (errorNode) { - error(errorNode, isAsyncIterable - ? ts.Diagnostics.Type_must_have_a_Symbol_asyncIterator_method_that_returns_an_async_iterator - : ts.Diagnostics.Type_must_have_a_Symbol_iterator_method_that_returns_an_iterator); - } - return undefined; } /** * This function has very similar logic as getIteratedTypeOfIterable, except that it operates on @@ -43687,7 +45384,7 @@ var ts; if (isTypeAny(returnType)) { return undefined; } - return getIteratedTypeOfIterable(returnType, /*errorNode*/ undefined, isAsyncGenerator, /*allowNonAsyncIterables*/ false, /*checkAssignability*/ false) + return getIteratedTypeOfIterable(returnType, /*errorNode*/ undefined, /*allowAsyncIterables*/ isAsyncGenerator, /*allowSyncIterables*/ !isAsyncGenerator, /*checkAssignability*/ false) || getIteratedTypeOfIterator(returnType, /*errorNode*/ undefined, isAsyncGenerator); } function checkBreakOrContinueStatement(node) { @@ -43696,7 +45393,8 @@ var ts; // TODO: Check that target label is valid } function isGetAccessorWithAnnotatedSetAccessor(node) { - return !!(node.kind === 153 /* GetAccessor */ && ts.getSetAccessorTypeAnnotationNode(ts.getDeclarationOfKind(node.symbol, 154 /* SetAccessor */))); + return node.kind === 153 /* GetAccessor */ + && ts.getEffectiveSetAccessorTypeAnnotationNode(ts.getDeclarationOfKind(node.symbol, 154 /* SetAccessor */)) !== undefined; } function isUnwrappedReturnTypeVoidOrAny(func, returnType) { var unwrappedReturnType = (ts.getFunctionFlags(func) & 3 /* AsyncGenerator */) === 2 /* Async */ @@ -43736,7 +45434,7 @@ var ts; error(node, ts.Diagnostics.Return_type_of_constructor_signature_must_be_assignable_to_the_instance_type_of_the_class); } } - else if (func.type || isGetAccessorWithAnnotatedSetAccessor(func)) { + else if (ts.getEffectiveReturnTypeNode(func) || isGetAccessorWithAnnotatedSetAccessor(func)) { if (functionFlags & 2 /* Async */) { var promisedType = getPromisedTypeOfPromise(returnType); var awaitedType = checkAwaitedType(exprType, node, ts.Diagnostics.The_return_type_of_an_async_function_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member); @@ -44101,7 +45799,7 @@ var ts; var staticBaseType = getApparentType(baseConstructorType); checkBaseTypeAccessibility(staticBaseType, baseTypeNode); checkSourceElement(baseTypeNode.expression); - if (baseTypeNode.typeArguments) { + if (ts.some(baseTypeNode.typeArguments)) { ts.forEach(baseTypeNode.typeArguments, checkSourceElement); for (var _i = 0, _a = getConstructorsForTypeArguments(staticBaseType, baseTypeNode.typeArguments, baseTypeNode); _i < _a.length; _i++) { var constructor = _a[_i]; @@ -44169,7 +45867,7 @@ var ts; function getTargetSymbol(s) { // if symbol is instantiated its flags are not copied from the 'target' // so we'll need to get back original 'target' symbol to work with correct set of flags - return getCheckFlags(s) & 1 /* Instantiated */ ? s.target : s; + return ts.getCheckFlags(s) & 1 /* Instantiated */ ? s.target : s; } function getClassLikeDeclarationOfSymbol(symbol) { return ts.forEach(symbol.declarations, function (d) { return ts.isClassLike(d) ? d : undefined; }); @@ -44202,7 +45900,7 @@ var ts; continue; } var derived = getTargetSymbol(getPropertyOfObjectType(type, base.name)); - var baseDeclarationFlags = getDeclarationModifierFlagsFromSymbol(base); + var baseDeclarationFlags = ts.getDeclarationModifierFlagsFromSymbol(base); ts.Debug.assert(!!derived, "derived should point to something, even if it is the base class' declaration."); if (derived) { // In order to resolve whether the inherited method was overridden in the base class or not, @@ -44225,15 +45923,11 @@ var ts; } else { // derived overrides base. - var derivedDeclarationFlags = getDeclarationModifierFlagsFromSymbol(derived); + var derivedDeclarationFlags = ts.getDeclarationModifierFlagsFromSymbol(derived); if (baseDeclarationFlags & 8 /* Private */ || derivedDeclarationFlags & 8 /* Private */) { // either base or derived property is private - not override, skip it continue; } - if ((baseDeclarationFlags & 32 /* Static */) !== (derivedDeclarationFlags & 32 /* Static */)) { - // value of 'static' is not the same for properties - not override, skip it - continue; - } if (isMethodLike(base) && isMethodLike(derived) || base.flags & 98308 /* PropertyOrAccessor */ && derived.flags & 98308 /* PropertyOrAccessor */) { // method is overridden with method or property/accessor is overridden with property/accessor - correct case continue; @@ -44258,9 +45952,6 @@ var ts; } } } - function isAccessor(kind) { - return kind === 153 /* GetAccessor */ || kind === 154 /* SetAccessor */; - } function checkInheritedPropertiesAreIdentical(type, typeNode) { var baseTypes = getBaseTypes(type); if (baseTypes.length < 2) { @@ -44340,97 +46031,88 @@ var ts; function computeEnumMemberValues(node) { var nodeLinks = getNodeLinks(node); if (!(nodeLinks.flags & 16384 /* EnumValuesComputed */)) { - var enumSymbol = getSymbolOfNode(node); - var enumType = getDeclaredTypeOfSymbol(enumSymbol); - var autoValue = 0; // set to undefined when enum member is non-constant - var ambient = ts.isInAmbientContext(node); - var enumIsConst = ts.isConst(node); + nodeLinks.flags |= 16384 /* EnumValuesComputed */; + var autoValue = 0; for (var _i = 0, _a = node.members; _i < _a.length; _i++) { var member = _a[_i]; - if (isComputedNonLiteralName(member.name)) { - error(member.name, ts.Diagnostics.Computed_property_names_are_not_allowed_in_enums); - } - else { - var text = ts.getTextOfPropertyName(member.name); - if (isNumericLiteralName(text) && !isInfinityOrNaNString(text)) { - error(member.name, ts.Diagnostics.An_enum_member_cannot_have_a_numeric_name); - } - } - var previousEnumMemberIsNonConstant = autoValue === undefined; - var initializer = member.initializer; - if (initializer) { - autoValue = computeConstantValueForEnumMemberInitializer(initializer, enumType, enumIsConst, ambient); - } - else if (ambient && !enumIsConst) { - // In ambient enum declarations that specify no const modifier, enum member declarations - // that omit a value are considered computed members (as opposed to having auto-incremented values assigned). - autoValue = undefined; - } - else if (previousEnumMemberIsNonConstant) { - // If the member declaration specifies no value, the member is considered a constant enum member. - // If the member is the first member in the enum declaration, it is assigned the value zero. - // Otherwise, it is assigned the value of the immediately preceding member plus one, - // and an error occurs if the immediately preceding member is not a constant enum member - error(member.name, ts.Diagnostics.Enum_member_must_have_initializer); - } - if (autoValue !== undefined) { - getNodeLinks(member).enumMemberValue = autoValue; - autoValue++; - } + var value = computeMemberValue(member, autoValue); + getNodeLinks(member).enumMemberValue = value; + autoValue = typeof value === "number" ? value + 1 : undefined; } - nodeLinks.flags |= 16384 /* EnumValuesComputed */; } - function computeConstantValueForEnumMemberInitializer(initializer, enumType, enumIsConst, ambient) { - // Controls if error should be reported after evaluation of constant value is completed - // Can be false if another more precise error was already reported during evaluation. - var reportError = true; - var value = evalConstant(initializer); - if (reportError) { - if (value === undefined) { - if (enumIsConst) { - error(initializer, ts.Diagnostics.In_const_enum_declarations_member_initializer_must_be_constant_expression); - } - else if (ambient) { - error(initializer, ts.Diagnostics.In_ambient_enum_declarations_member_initializer_must_be_constant_expression); - } - else { - // Only here do we need to check that the initializer is assignable to the enum type. - checkTypeAssignableTo(checkExpression(initializer), enumType, initializer, /*headMessage*/ undefined); - } - } - else if (enumIsConst) { - if (isNaN(value)) { - error(initializer, ts.Diagnostics.const_enum_member_initializer_was_evaluated_to_disallowed_value_NaN); - } - else if (!isFinite(value)) { - error(initializer, ts.Diagnostics.const_enum_member_initializer_was_evaluated_to_a_non_finite_value); - } - } + } + function computeMemberValue(member, autoValue) { + if (isComputedNonLiteralName(member.name)) { + error(member.name, ts.Diagnostics.Computed_property_names_are_not_allowed_in_enums); + } + else { + var text = ts.getTextOfPropertyName(member.name); + if (isNumericLiteralName(text) && !isInfinityOrNaNString(text)) { + error(member.name, ts.Diagnostics.An_enum_member_cannot_have_a_numeric_name); } - return value; - function evalConstant(e) { - switch (e.kind) { - case 192 /* PrefixUnaryExpression */: - var value_1 = evalConstant(e.operand); - if (value_1 === undefined) { - return undefined; - } - switch (e.operator) { + } + if (member.initializer) { + return computeConstantValue(member); + } + // In ambient enum declarations that specify no const modifier, enum member declarations that omit + // a value are considered computed members (as opposed to having auto-incremented values). + if (ts.isInAmbientContext(member.parent) && !ts.isConst(member.parent)) { + return undefined; + } + // If the member declaration specifies no value, the member is considered a constant enum member. + // If the member is the first member in the enum declaration, it is assigned the value zero. + // Otherwise, it is assigned the value of the immediately preceding member plus one, and an error + // occurs if the immediately preceding member is not a constant enum member. + if (autoValue !== undefined) { + return autoValue; + } + error(member.name, ts.Diagnostics.Enum_member_must_have_initializer); + return undefined; + } + function computeConstantValue(member) { + var enumKind = getEnumKind(getSymbolOfNode(member.parent)); + var isConstEnum = ts.isConst(member.parent); + var initializer = member.initializer; + var value = enumKind === 1 /* Literal */ && !isLiteralEnumMember(member) ? undefined : evaluate(initializer); + if (value !== undefined) { + if (isConstEnum && typeof value === "number" && !isFinite(value)) { + error(initializer, isNaN(value) ? + ts.Diagnostics.const_enum_member_initializer_was_evaluated_to_disallowed_value_NaN : + ts.Diagnostics.const_enum_member_initializer_was_evaluated_to_a_non_finite_value); + } + } + else if (enumKind === 1 /* Literal */) { + error(initializer, ts.Diagnostics.Computed_values_are_not_permitted_in_an_enum_with_string_valued_members); + return 0; + } + else if (isConstEnum) { + error(initializer, ts.Diagnostics.In_const_enum_declarations_member_initializer_must_be_constant_expression); + } + else if (ts.isInAmbientContext(member.parent)) { + error(initializer, ts.Diagnostics.In_ambient_enum_declarations_member_initializer_must_be_constant_expression); + } + else { + // Only here do we need to check that the initializer is assignable to the enum type. + checkTypeAssignableTo(checkExpression(initializer), getDeclaredTypeOfSymbol(getSymbolOfNode(member.parent)), initializer, /*headMessage*/ undefined); + } + return value; + function evaluate(expr) { + switch (expr.kind) { + case 192 /* PrefixUnaryExpression */: + var value_1 = evaluate(expr.operand); + if (typeof value_1 === "number") { + switch (expr.operator) { case 37 /* PlusToken */: return value_1; case 38 /* MinusToken */: return -value_1; case 52 /* TildeToken */: return ~value_1; } - return undefined; - case 194 /* BinaryExpression */: - var left = evalConstant(e.left); - if (left === undefined) { - return undefined; - } - var right = evalConstant(e.right); - if (right === undefined) { - return undefined; - } - switch (e.operatorToken.kind) { + } + break; + case 194 /* BinaryExpression */: + var left = evaluate(expr.left); + var right = evaluate(expr.right); + if (typeof left === "number" && typeof right === "number") { + switch (expr.operatorToken.kind) { case 49 /* BarToken */: return left | right; case 48 /* AmpersandToken */: return left & right; case 46 /* GreaterThanGreaterThanToken */: return left >> right; @@ -44443,81 +46125,53 @@ var ts; case 38 /* MinusToken */: return left - right; case 42 /* PercentToken */: return left % right; } - return undefined; - case 8 /* NumericLiteral */: - checkGrammarNumericLiteral(e); - return +e.text; - case 185 /* ParenthesizedExpression */: - return evalConstant(e.expression); - case 71 /* Identifier */: - case 180 /* ElementAccessExpression */: - case 179 /* PropertyAccessExpression */: - var member = initializer.parent; - var currentType = getTypeOfSymbol(getSymbolOfNode(member.parent)); - var enumType_1; - var propertyName = void 0; - if (e.kind === 71 /* Identifier */) { - // unqualified names can refer to member that reside in different declaration of the enum so just doing name resolution won't work. - // instead pick current enum type and later try to fetch member from the type - enumType_1 = currentType; - propertyName = e.text; - } - else { - var expression = void 0; - if (e.kind === 180 /* ElementAccessExpression */) { - if (e.argumentExpression === undefined || - e.argumentExpression.kind !== 9 /* StringLiteral */) { - return undefined; - } - expression = e.expression; - propertyName = e.argumentExpression.text; - } - else { - expression = e.expression; - propertyName = e.name.text; - } - // expression part in ElementAccess\PropertyAccess should be either identifier or dottedName - var current = expression; - while (current) { - if (current.kind === 71 /* Identifier */) { - break; - } - else if (current.kind === 179 /* PropertyAccessExpression */) { - current = current.expression; - } - else { - return undefined; - } - } - enumType_1 = getTypeOfExpression(expression); - // allow references to constant members of other enums - if (!(enumType_1.symbol && (enumType_1.symbol.flags & 384 /* Enum */))) { - return undefined; - } - } - if (propertyName === undefined) { - return undefined; - } - var property = getPropertyOfObjectType(enumType_1, propertyName); - if (!property || !(property.flags & 8 /* EnumMember */)) { - return undefined; - } - var propertyDecl = property.valueDeclaration; - // self references are illegal - if (member === propertyDecl) { - return undefined; - } - // illegal case: forward reference - if (!isBlockScopedNameDeclaredBeforeUse(propertyDecl, member)) { - reportError = false; - error(e, ts.Diagnostics.A_member_initializer_in_a_enum_declaration_cannot_reference_members_declared_after_it_including_members_defined_in_other_enums); - return undefined; + } + break; + case 9 /* StringLiteral */: + return expr.text; + case 8 /* NumericLiteral */: + checkGrammarNumericLiteral(expr); + return +expr.text; + case 185 /* ParenthesizedExpression */: + return evaluate(expr.expression); + case 71 /* Identifier */: + return ts.nodeIsMissing(expr) ? 0 : evaluateEnumMember(expr, getSymbolOfNode(member.parent), expr.text); + case 180 /* ElementAccessExpression */: + case 179 /* PropertyAccessExpression */: + if (isConstantMemberAccess(expr)) { + var type = getTypeOfExpression(expr.expression); + if (type.symbol && type.symbol.flags & 384 /* Enum */) { + var name = expr.kind === 179 /* PropertyAccessExpression */ ? + expr.name.text : + expr.argumentExpression.text; + return evaluateEnumMember(expr, type.symbol, name); } - return getNodeLinks(propertyDecl).enumMemberValue; + } + break; + } + return undefined; + } + function evaluateEnumMember(expr, enumSymbol, name) { + var memberSymbol = enumSymbol.exports.get(name); + if (memberSymbol) { + var declaration = memberSymbol.valueDeclaration; + if (declaration !== member) { + if (isBlockScopedNameDeclaredBeforeUse(declaration, member)) { + return getNodeLinks(declaration).enumMemberValue; + } + error(expr, ts.Diagnostics.A_member_initializer_in_a_enum_declaration_cannot_reference_members_declared_after_it_including_members_defined_in_other_enums); + return 0; } } + return undefined; } } + function isConstantMemberAccess(node) { + return node.kind === 71 /* Identifier */ || + node.kind === 179 /* PropertyAccessExpression */ && isConstantMemberAccess(node.expression) || + node.kind === 180 /* ElementAccessExpression */ && isConstantMemberAccess(node.expression) && + node.argumentExpression.kind === 9 /* StringLiteral */; + } function checkEnumDeclaration(node) { if (!produceDiagnostics) { return; @@ -44807,6 +46461,13 @@ var ts; ts.Diagnostics.Import_declaration_conflicts_with_local_declaration_of_0; error(node, message, symbolToString(symbol)); } + // Don't allow to re-export something with no value side when `--isolatedModules` is set. + if (compilerOptions.isolatedModules + && node.kind === 246 /* ExportSpecifier */ + && !(target.flags & 107455 /* Value */) + && !ts.isInAmbientContext(node)) { + error(node, ts.Diagnostics.Cannot_re_export_a_type_when_the_isolatedModules_flag_is_provided); + } } } function checkImportBinding(node) { @@ -44900,6 +46561,9 @@ var ts; if (moduleSymbol && hasExportAssignmentSymbol(moduleSymbol)) { error(node.moduleSpecifier, ts.Diagnostics.Module_0_uses_export_and_cannot_be_used_with_export_Asterisk, symbolToString(moduleSymbol)); } + if (modulekind !== ts.ModuleKind.System && modulekind !== ts.ModuleKind.ES2015) { + checkExternalEmitHelpers(node, 32768 /* ExportStar */); + } } } } @@ -45482,6 +47146,15 @@ var ts; return entityNameSymbol; } } + if (entityName.parent.kind === 287 /* JSDocParameterTag */) { + var parameter = ts.getParameterFromJSDoc(entityName.parent); + return parameter && parameter.symbol; + } + if (entityName.parent.kind === 145 /* TypeParameter */ && entityName.parent.parent.kind === 290 /* JSDocTemplateTag */) { + ts.Debug.assert(!ts.isInJavaScriptFile(entityName)); // Otherwise `isDeclarationName` would have been true. + var typeParameter = ts.getTypeParameterFromJsDoc(entityName.parent); + return typeParameter && typeParameter.symbol; + } if (ts.isPartOfExpression(entityName)) { if (ts.nodeIsMissing(entityName)) { // Missing entity name. @@ -45529,7 +47202,7 @@ var ts; // We cannot answer semantic questions within a with block, do not proceed any further return undefined; } - if (ts.isDeclarationName(node)) { + if (isDeclarationNameOrImportPropertyName(node)) { // This is a declaration, call getSymbolOfNode return getSymbolOfNode(node.parent); } @@ -45577,14 +47250,12 @@ var ts; } return undefined; case 9 /* StringLiteral */: - // External module name in an import declaration - if ((ts.isExternalModuleImportEqualsDeclaration(node.parent.parent) && - ts.getExternalModuleImportEqualsDeclarationExpression(node.parent.parent) === node) || - ((node.parent.kind === 238 /* ImportDeclaration */ || node.parent.kind === 244 /* ExportDeclaration */) && - node.parent.moduleSpecifier === node)) { - return resolveExternalModuleName(node, node); - } - if (ts.isInJavaScriptFile(node) && ts.isRequireCall(node.parent, /*checkArgumentIsStringLiteral*/ false)) { + // 1). import x = require("./mo/*gotToDefinitionHere*/d") + // 2). External module name in an import declaration + // 3). Dynamic import call or require in javascript + if ((ts.isExternalModuleImportEqualsDeclaration(node.parent.parent) && ts.getExternalModuleImportEqualsDeclarationExpression(node.parent.parent) === node) || + ((node.parent.kind === 238 /* ImportDeclaration */ || node.parent.kind === 244 /* ExportDeclaration */) && node.parent.moduleSpecifier === node) || + ((ts.isInJavaScriptFile(node) && ts.isRequireCall(node.parent, /*checkArgumentIsStringLiteral*/ false)) || ts.isImportCall(node.parent))) { return resolveExternalModuleName(node, node); } // falls through @@ -45657,7 +47328,7 @@ var ts; var symbol = getSymbolOfNode(node); return getTypeOfSymbol(symbol); } - if (ts.isDeclarationName(node)) { + if (isDeclarationNameOrImportPropertyName(node)) { var symbol = getSymbolAtLocation(node); return symbol && getTypeOfSymbol(symbol); } @@ -45702,7 +47373,7 @@ var ts; ts.Debug.assert(expr.parent.kind === 177 /* ArrayLiteralExpression */); // [{ property1: p1, property2 }] = elems; var typeOfArrayLiteral = getTypeOfArrayLiteralOrObjectLiteralDestructuringAssignment(expr.parent); - var elementType = checkIteratedTypeOrElementType(typeOfArrayLiteral || unknownType, expr.parent, /*allowStringInput*/ false, /*allowAsyncIterable*/ false) || unknownType; + var elementType = checkIteratedTypeOrElementType(typeOfArrayLiteral || unknownType, expr.parent, /*allowStringInput*/ false, /*allowAsyncIterables*/ false) || unknownType; return checkArrayLiteralDestructuringElementAssignment(expr.parent, typeOfArrayLiteral, ts.indexOf(expr.parent.elements, expr), elementType || unknownType); } // Gets the property symbol corresponding to the property in destructuring assignment @@ -45747,24 +47418,24 @@ var ts; return getNamedMembers(propsByName); } function getRootSymbols(symbol) { - if (getCheckFlags(symbol) & 6 /* Synthetic */) { - var symbols_3 = []; + if (ts.getCheckFlags(symbol) & 6 /* Synthetic */) { + var symbols_4 = []; var name_2 = symbol.name; ts.forEach(getSymbolLinks(symbol).containingType.types, function (t) { var symbol = getPropertyOfType(t, name_2); if (symbol) { - symbols_3.push(symbol); + symbols_4.push(symbol); } }); - return symbols_3; + return symbols_4; } else if (symbol.flags & 134217728 /* Transient */) { - if (symbol.leftSpread) { - var links = symbol; - return getRootSymbols(links.leftSpread).concat(getRootSymbols(links.rightSpread)); + var transient = symbol; + if (transient.leftSpread) { + return getRootSymbols(transient.leftSpread).concat(getRootSymbols(transient.rightSpread)); } - if (symbol.syntheticOrigin) { - return getRootSymbols(symbol.syntheticOrigin); + if (transient.syntheticOrigin) { + return getRootSymbols(transient.syntheticOrigin); } var target = void 0; var next = symbol; @@ -45857,7 +47528,9 @@ var ts; node = ts.getParseTreeNode(node, ts.isIdentifier); if (node) { var symbol = getReferencedValueSymbol(node); - if (symbol && symbol.flags & 8388608 /* Alias */) { + // We should only get the declaration of an alias if there isn't a local value + // declaration for the symbol + if (isNonLocalAlias(symbol, /*excludes*/ 107455 /* Value */)) { return getDeclarationOfAliasSymbol(symbol); } } @@ -46010,6 +47683,12 @@ var ts; parameter.initializer && !(ts.getModifierFlags(parameter) & 92 /* ParameterPropertyModifier */); } + function isOptionalUninitializedParameterProperty(parameter) { + return strictNullChecks && + isOptionalParameter(parameter) && + !parameter.initializer && + !!(ts.getModifierFlags(parameter) & 92 /* ParameterPropertyModifier */); + } function getNodeCheckFlags(node) { return getNodeLinks(node).flags; } @@ -46074,7 +47753,7 @@ var ts; else if (isTypeOfKind(type, 136 /* BooleanLike */)) { return ts.TypeReferenceSerializationKind.BooleanType; } - else if (isTypeOfKind(type, 340 /* NumberLike */)) { + else if (isTypeOfKind(type, 84 /* NumberLike */)) { return ts.TypeReferenceSerializationKind.NumberLikeType; } else if (isTypeOfKind(type, 262178 /* StringLike */)) { @@ -46102,8 +47781,8 @@ var ts; var type = symbol && !(symbol.flags & (2048 /* TypeLiteral */ | 131072 /* Signature */)) ? getWidenedLiteralType(getTypeOfSymbol(symbol)) : unknownType; - if (flags & 4096 /* AddUndefined */) { - type = includeFalsyTypes(type, 2048 /* Undefined */); + if (flags & 8192 /* AddUndefined */) { + type = getNullableType(type, 2048 /* Undefined */); } getSymbolDisplayBuilder().buildTypeDisplay(type, writer, enclosingDeclaration, flags); } @@ -46197,6 +47876,7 @@ var ts; isDeclarationVisible: isDeclarationVisible, isImplementationOfOverload: isImplementationOfOverload, isRequiredInitializedParameter: isRequiredInitializedParameter, + isOptionalUninitializedParameterProperty: isOptionalUninitializedParameterProperty, writeTypeOfDeclaration: writeTypeOfDeclaration, writeReturnTypeOfSignatureDeclaration: writeReturnTypeOfSignatureDeclaration, writeTypeOfExpression: writeTypeOfExpression, @@ -46367,7 +48047,7 @@ var ts; var helpersModule = resolveHelpersModule(sourceFile, location); if (helpersModule !== unknownSymbol) { var uncheckedHelpers = helpers & ~requestedExternalEmitHelpers; - for (var helper = 1 /* FirstEmitHelper */; helper <= 16384 /* LastEmitHelper */; helper <<= 1) { + for (var helper = 1 /* FirstEmitHelper */; helper <= 32768 /* LastEmitHelper */; helper <<= 1) { if (uncheckedHelpers & helper) { var name = getHelperName(helper); var symbol = getSymbol(helpersModule.exports, ts.escapeIdentifier(name), 107455 /* Value */); @@ -46398,7 +48078,8 @@ var ts; case 4096 /* AsyncGenerator */: return "__asyncGenerator"; case 8192 /* AsyncDelegator */: return "__asyncDelegator"; case 16384 /* AsyncValues */: return "__asyncValues"; - default: ts.Debug.fail("Unrecognized helper."); + case 32768 /* ExportStar */: return "__exportStar"; + default: ts.Debug.fail("Unrecognized helper"); } } function resolveHelpersModule(node, errorNode) { @@ -46830,6 +48511,10 @@ var ts; var sourceFile = ts.getSourceFileOfNode(node); return grammarErrorAtPos(sourceFile, types.pos, 0, ts.Diagnostics._0_list_cannot_be_empty, listType); } + return ts.forEach(types, checkGrammarExpressionWithTypeArguments); + } + function checkGrammarExpressionWithTypeArguments(node) { + return checkGrammarTypeArguments(node, node.typeArguments); } function checkGrammarClassDeclarationHeritageClauses(node) { var seenExtendsClause = false; @@ -47437,7 +49122,7 @@ var ts; function checkGrammarStatementInAmbientContext(node) { if (ts.isInAmbientContext(node)) { // An accessors is already reported about the ambient context - if (isAccessor(node.parent.kind)) { + if (ts.isAccessor(node.parent)) { return getNodeLinks(node).hasReportedStatementInAmbientContext = true; } // Find containing block which is either Block, ModuleBlock, SourceFile @@ -47501,8 +49186,35 @@ var ts; }); return result; } + function checkGrammarImportCallExpression(node) { + if (modulekind === ts.ModuleKind.ES2015) { + return grammarErrorOnNode(node, ts.Diagnostics.Dynamic_import_cannot_be_used_when_targeting_ECMAScript_2015_modules); + } + if (node.typeArguments) { + return grammarErrorOnNode(node, ts.Diagnostics.Dynamic_import_cannot_have_type_arguments); + } + var nodeArguments = node.arguments; + if (nodeArguments.length !== 1) { + return grammarErrorOnNode(node, ts.Diagnostics.Dynamic_import_must_have_one_specifier_as_an_argument); + } + // see: parseArgumentOrArrayLiteralElement...we use this function which parse arguments of callExpression to parse specifier for dynamic import. + // parseArgumentOrArrayLiteralElement allows spread element to be in an argument list which is not allowed as specifier in dynamic import. + if (ts.isSpreadElement(nodeArguments[0])) { + return grammarErrorOnNode(nodeArguments[0], ts.Diagnostics.Specifier_of_dynamic_import_cannot_be_spread_element); + } + } } ts.createTypeChecker = createTypeChecker; + /** Like 'isDeclarationName', but returns true for LHS of `import { x as y }` or `export { x as y }`. */ + function isDeclarationNameOrImportPropertyName(name) { + switch (name.parent.kind) { + case 242 /* ImportSpecifier */: + case 246 /* ExportSpecifier */: + return true; + default: + return ts.isDeclarationName(name); + } + } })(ts || (ts = {})); /// /// @@ -47640,79 +49352,73 @@ var ts; if ((kind > 0 /* FirstToken */ && kind <= 142 /* LastToken */) || kind === 169 /* ThisType */) { return node; } - switch (node.kind) { - case 206 /* SemicolonClassElement */: - case 209 /* EmptyStatement */: - case 200 /* OmittedExpression */: - case 225 /* DebuggerStatement */: - case 298 /* EndOfDeclarationMarker */: - case 247 /* MissingDeclaration */: - // No need to visit nodes with no children. - return node; + switch (kind) { // Names + case 71 /* Identifier */: + return ts.updateIdentifier(node, nodesVisitor(node.typeArguments, visitor, ts.isTypeNode)); case 143 /* QualifiedName */: return ts.updateQualifiedName(node, visitNode(node.left, visitor, ts.isEntityName), visitNode(node.right, visitor, ts.isIdentifier)); case 144 /* ComputedPropertyName */: return ts.updateComputedPropertyName(node, visitNode(node.expression, visitor, ts.isExpression)); - // Signatures and Signature Elements - case 160 /* FunctionType */: - return ts.updateFunctionTypeNode(node, nodesVisitor(node.typeParameters, visitor, ts.isTypeParameter), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode)); - case 161 /* ConstructorType */: - return ts.updateConstructorTypeNode(node, nodesVisitor(node.typeParameters, visitor, ts.isTypeParameter), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode)); - case 155 /* CallSignature */: - return ts.updateCallSignatureDeclaration(node, nodesVisitor(node.typeParameters, visitor, ts.isTypeParameter), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode)); - case 156 /* ConstructSignature */: - return ts.updateConstructSignatureDeclaration(node, nodesVisitor(node.typeParameters, visitor, ts.isTypeParameter), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode)); - case 150 /* MethodSignature */: - return ts.updateMethodSignature(node, nodesVisitor(node.typeParameters, visitor, ts.isTypeParameter), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode), visitNode(node.name, visitor, ts.isPropertyName), visitNode(node.questionToken, tokenVisitor, ts.isToken)); - case 157 /* IndexSignature */: - return ts.updateIndexSignatureDeclaration(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode)); + // Signature elements + case 145 /* TypeParameter */: + return ts.updateTypeParameterDeclaration(node, visitNode(node.name, visitor, ts.isIdentifier), visitNode(node.constraint, visitor, ts.isTypeNode), visitNode(node.default, visitor, ts.isTypeNode)); case 146 /* Parameter */: return ts.updateParameter(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.dotDotDotToken, tokenVisitor, ts.isToken), visitNode(node.name, visitor, ts.isBindingName), visitNode(node.questionToken, tokenVisitor, ts.isToken), visitNode(node.type, visitor, ts.isTypeNode), visitNode(node.initializer, visitor, ts.isExpression)); case 147 /* Decorator */: return ts.updateDecorator(node, visitNode(node.expression, visitor, ts.isExpression)); + // Type elements + case 148 /* PropertySignature */: + return ts.updatePropertySignature(node, nodesVisitor(node.modifiers, visitor, ts.isToken), visitNode(node.name, visitor, ts.isPropertyName), visitNode(node.questionToken, tokenVisitor, ts.isToken), visitNode(node.type, visitor, ts.isTypeNode), visitNode(node.initializer, visitor, ts.isExpression)); + case 149 /* PropertyDeclaration */: + return ts.updateProperty(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isPropertyName), visitNode(node.type, visitor, ts.isTypeNode), visitNode(node.initializer, visitor, ts.isExpression)); + case 150 /* MethodSignature */: + return ts.updateMethodSignature(node, nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), nodesVisitor(node.parameters, visitor, ts.isParameterDeclaration), visitNode(node.type, visitor, ts.isTypeNode), visitNode(node.name, visitor, ts.isPropertyName), visitNode(node.questionToken, tokenVisitor, ts.isToken)); + case 151 /* MethodDeclaration */: + return ts.updateMethod(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.asteriskToken, tokenVisitor, ts.isToken), visitNode(node.name, visitor, ts.isPropertyName), visitNode(node.questionToken, tokenVisitor, ts.isToken), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode), visitFunctionBody(node.body, visitor, context)); + case 152 /* Constructor */: + return ts.updateConstructor(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitFunctionBody(node.body, visitor, context)); + case 153 /* GetAccessor */: + return ts.updateGetAccessor(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isPropertyName), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode), visitFunctionBody(node.body, visitor, context)); + case 154 /* SetAccessor */: + return ts.updateSetAccessor(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isPropertyName), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitFunctionBody(node.body, visitor, context)); + case 155 /* CallSignature */: + return ts.updateCallSignature(node, nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), nodesVisitor(node.parameters, visitor, ts.isParameterDeclaration), visitNode(node.type, visitor, ts.isTypeNode)); + case 156 /* ConstructSignature */: + return ts.updateConstructSignature(node, nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), nodesVisitor(node.parameters, visitor, ts.isParameterDeclaration), visitNode(node.type, visitor, ts.isTypeNode)); + case 157 /* IndexSignature */: + return ts.updateIndexSignature(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), nodesVisitor(node.parameters, visitor, ts.isParameterDeclaration), visitNode(node.type, visitor, ts.isTypeNode)); // Types - case 159 /* TypeReference */: - return ts.updateTypeReferenceNode(node, visitNode(node.typeName, visitor, ts.isEntityName), nodesVisitor(node.typeArguments, visitor, ts.isTypeNode)); case 158 /* TypePredicate */: return ts.updateTypePredicateNode(node, visitNode(node.parameterName, visitor), visitNode(node.type, visitor, ts.isTypeNode)); + case 159 /* TypeReference */: + return ts.updateTypeReferenceNode(node, visitNode(node.typeName, visitor, ts.isEntityName), nodesVisitor(node.typeArguments, visitor, ts.isTypeNode)); + case 160 /* FunctionType */: + return ts.updateFunctionTypeNode(node, nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), nodesVisitor(node.parameters, visitor, ts.isParameterDeclaration), visitNode(node.type, visitor, ts.isTypeNode)); + case 161 /* ConstructorType */: + return ts.updateConstructorTypeNode(node, nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), nodesVisitor(node.parameters, visitor, ts.isParameterDeclaration), visitNode(node.type, visitor, ts.isTypeNode)); case 162 /* TypeQuery */: return ts.updateTypeQueryNode(node, visitNode(node.exprName, visitor, ts.isEntityName)); case 163 /* TypeLiteral */: - return ts.updateTypeLiteralNode(node, nodesVisitor(node.members, visitor)); + return ts.updateTypeLiteralNode(node, nodesVisitor(node.members, visitor, ts.isTypeElement)); case 164 /* ArrayType */: return ts.updateArrayTypeNode(node, visitNode(node.elementType, visitor, ts.isTypeNode)); case 165 /* TupleType */: return ts.updateTypleTypeNode(node, nodesVisitor(node.elementTypes, visitor, ts.isTypeNode)); case 166 /* UnionType */: + return ts.updateUnionTypeNode(node, nodesVisitor(node.types, visitor, ts.isTypeNode)); case 167 /* IntersectionType */: - return ts.updateUnionOrIntersectionTypeNode(node, nodesVisitor(node.types, visitor, ts.isTypeNode)); + return ts.updateIntersectionTypeNode(node, nodesVisitor(node.types, visitor, ts.isTypeNode)); case 168 /* ParenthesizedType */: - throw ts.Debug.fail("not implemented."); + return ts.updateParenthesizedType(node, visitNode(node.type, visitor, ts.isTypeNode)); case 170 /* TypeOperator */: return ts.updateTypeOperatorNode(node, visitNode(node.type, visitor, ts.isTypeNode)); case 171 /* IndexedAccessType */: return ts.updateIndexedAccessTypeNode(node, visitNode(node.objectType, visitor, ts.isTypeNode), visitNode(node.indexType, visitor, ts.isTypeNode)); case 172 /* MappedType */: - return ts.updateMappedTypeNode(node, visitNode(node.readonlyToken, tokenVisitor, ts.isToken), visitNode(node.typeParameter, visitor, ts.isTypeParameter), visitNode(node.questionToken, tokenVisitor, ts.isToken), visitNode(node.type, visitor, ts.isTypeNode)); + return ts.updateMappedTypeNode(node, visitNode(node.readonlyToken, tokenVisitor, ts.isToken), visitNode(node.typeParameter, visitor, ts.isTypeParameterDeclaration), visitNode(node.questionToken, tokenVisitor, ts.isToken), visitNode(node.type, visitor, ts.isTypeNode)); case 173 /* LiteralType */: return ts.updateLiteralTypeNode(node, visitNode(node.literal, visitor, ts.isExpression)); - // Type Declarations - case 145 /* TypeParameter */: - return ts.updateTypeParameterDeclaration(node, visitNode(node.name, visitor, ts.isIdentifier), visitNode(node.constraint, visitor, ts.isTypeNode), visitNode(node.default, visitor, ts.isTypeNode)); - // Type members - case 148 /* PropertySignature */: - return ts.updatePropertySignature(node, visitNode(node.name, visitor, ts.isPropertyName), visitNode(node.questionToken, tokenVisitor, ts.isToken), visitNode(node.type, visitor, ts.isTypeNode), visitNode(node.initializer, visitor, ts.isExpression)); - case 149 /* PropertyDeclaration */: - return ts.updateProperty(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isPropertyName), visitNode(node.type, visitor, ts.isTypeNode), visitNode(node.initializer, visitor, ts.isExpression)); - case 151 /* MethodDeclaration */: - return ts.updateMethod(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.asteriskToken, tokenVisitor, ts.isToken), visitNode(node.name, visitor, ts.isPropertyName), visitNode(node.questionToken, tokenVisitor, ts.isToken), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameter), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode), visitFunctionBody(node.body, visitor, context)); - case 152 /* Constructor */: - return ts.updateConstructor(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitFunctionBody(node.body, visitor, context)); - case 153 /* GetAccessor */: - return ts.updateGetAccessor(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isPropertyName), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode), visitFunctionBody(node.body, visitor, context)); - case 154 /* SetAccessor */: - return ts.updateSetAccessor(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isPropertyName), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitFunctionBody(node.body, visitor, context)); // Binding patterns case 174 /* ObjectBindingPattern */: return ts.updateObjectBindingPattern(node, nodesVisitor(node.elements, visitor, ts.isBindingElement)); @@ -47740,9 +49446,9 @@ var ts; case 185 /* ParenthesizedExpression */: return ts.updateParen(node, visitNode(node.expression, visitor, ts.isExpression)); case 186 /* FunctionExpression */: - return ts.updateFunctionExpression(node, nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.asteriskToken, tokenVisitor, ts.isToken), visitNode(node.name, visitor, ts.isIdentifier), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameter), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode), visitFunctionBody(node.body, visitor, context)); + return ts.updateFunctionExpression(node, nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.asteriskToken, tokenVisitor, ts.isToken), visitNode(node.name, visitor, ts.isIdentifier), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode), visitFunctionBody(node.body, visitor, context)); case 187 /* ArrowFunction */: - return ts.updateArrowFunction(node, nodesVisitor(node.modifiers, visitor, ts.isModifier), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameter), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode), visitFunctionBody(node.body, visitor, context)); + return ts.updateArrowFunction(node, nodesVisitor(node.modifiers, visitor, ts.isModifier), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode), visitFunctionBody(node.body, visitor, context)); case 188 /* DeleteExpression */: return ts.updateDelete(node, visitNode(node.expression, visitor, ts.isExpression)); case 189 /* TypeOfExpression */: @@ -47751,12 +49457,12 @@ var ts; return ts.updateVoid(node, visitNode(node.expression, visitor, ts.isExpression)); case 191 /* AwaitExpression */: return ts.updateAwait(node, visitNode(node.expression, visitor, ts.isExpression)); - case 194 /* BinaryExpression */: - return ts.updateBinary(node, visitNode(node.left, visitor, ts.isExpression), visitNode(node.right, visitor, ts.isExpression)); case 192 /* PrefixUnaryExpression */: return ts.updatePrefix(node, visitNode(node.operand, visitor, ts.isExpression)); case 193 /* PostfixUnaryExpression */: return ts.updatePostfix(node, visitNode(node.operand, visitor, ts.isExpression)); + case 194 /* BinaryExpression */: + return ts.updateBinary(node, visitNode(node.left, visitor, ts.isExpression), visitNode(node.right, visitor, ts.isExpression), visitNode(node.operatorToken, visitor, ts.isToken)); case 195 /* ConditionalExpression */: return ts.updateConditional(node, visitNode(node.condition, visitor, ts.isExpression), visitNode(node.whenTrue, visitor, ts.isExpression), visitNode(node.whenFalse, visitor, ts.isExpression)); case 196 /* TemplateExpression */: @@ -47766,13 +49472,15 @@ var ts; case 198 /* SpreadElement */: return ts.updateSpread(node, visitNode(node.expression, visitor, ts.isExpression)); case 199 /* ClassExpression */: - return ts.updateClassExpression(node, nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isIdentifier), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameter), nodesVisitor(node.heritageClauses, visitor, ts.isHeritageClause), nodesVisitor(node.members, visitor, ts.isClassElement)); + return ts.updateClassExpression(node, nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isIdentifier), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), nodesVisitor(node.heritageClauses, visitor, ts.isHeritageClause), nodesVisitor(node.members, visitor, ts.isClassElement)); case 201 /* ExpressionWithTypeArguments */: return ts.updateExpressionWithTypeArguments(node, nodesVisitor(node.typeArguments, visitor, ts.isTypeNode), visitNode(node.expression, visitor, ts.isExpression)); case 202 /* AsExpression */: return ts.updateAsExpression(node, visitNode(node.expression, visitor, ts.isExpression), visitNode(node.type, visitor, ts.isTypeNode)); case 203 /* NonNullExpression */: return ts.updateNonNullExpression(node, visitNode(node.expression, visitor, ts.isExpression)); + case 204 /* MetaProperty */: + return ts.updateMetaProperty(node, visitNode(node.name, visitor, ts.isIdentifier)); // Misc case 205 /* TemplateSpan */: return ts.updateTemplateSpan(node, visitNode(node.expression, visitor, ts.isExpression), visitNode(node.literal, visitor, ts.isTemplateMiddleOrTemplateTail)); @@ -47816,9 +49524,13 @@ var ts; case 227 /* VariableDeclarationList */: return ts.updateVariableDeclarationList(node, nodesVisitor(node.declarations, visitor, ts.isVariableDeclaration)); case 228 /* FunctionDeclaration */: - return ts.updateFunctionDeclaration(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.asteriskToken, tokenVisitor, ts.isToken), visitNode(node.name, visitor, ts.isIdentifier), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameter), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode), visitFunctionBody(node.body, visitor, context)); + return ts.updateFunctionDeclaration(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.asteriskToken, tokenVisitor, ts.isToken), visitNode(node.name, visitor, ts.isIdentifier), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), visitParameterList(node.parameters, visitor, context, nodesVisitor), visitNode(node.type, visitor, ts.isTypeNode), visitFunctionBody(node.body, visitor, context)); case 229 /* ClassDeclaration */: - return ts.updateClassDeclaration(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isIdentifier), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameter), nodesVisitor(node.heritageClauses, visitor, ts.isHeritageClause), nodesVisitor(node.members, visitor, ts.isClassElement)); + return ts.updateClassDeclaration(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isIdentifier), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), nodesVisitor(node.heritageClauses, visitor, ts.isHeritageClause), nodesVisitor(node.members, visitor, ts.isClassElement)); + case 230 /* InterfaceDeclaration */: + return ts.updateInterfaceDeclaration(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isIdentifier), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), nodesVisitor(node.heritageClauses, visitor, ts.isHeritageClause), nodesVisitor(node.members, visitor, ts.isTypeElement)); + case 231 /* TypeAliasDeclaration */: + return ts.updateTypeAliasDeclaration(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isIdentifier), nodesVisitor(node.typeParameters, visitor, ts.isTypeParameterDeclaration), visitNode(node.type, visitor, ts.isTypeNode)); case 232 /* EnumDeclaration */: return ts.updateEnumDeclaration(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isIdentifier), nodesVisitor(node.members, visitor, ts.isEnumMember)); case 233 /* ModuleDeclaration */: @@ -47827,6 +49539,8 @@ var ts; return ts.updateModuleBlock(node, nodesVisitor(node.statements, visitor, ts.isStatement)); case 235 /* CaseBlock */: return ts.updateCaseBlock(node, nodesVisitor(node.clauses, visitor, ts.isCaseOrDefaultClause)); + case 236 /* NamespaceExportDeclaration */: + return ts.updateNamespaceExportDeclaration(node, visitNode(node.name, visitor, ts.isIdentifier)); case 237 /* ImportEqualsDeclaration */: return ts.updateImportEqualsDeclaration(node, nodesVisitor(node.decorators, visitor, ts.isDecorator), nodesVisitor(node.modifiers, visitor, ts.isModifier), visitNode(node.name, visitor, ts.isIdentifier), visitNode(node.moduleReference, visitor, ts.isModuleReference)); case 238 /* ImportDeclaration */: @@ -47853,8 +49567,6 @@ var ts; // JSX case 249 /* JsxElement */: return ts.updateJsxElement(node, visitNode(node.openingElement, visitor, ts.isJsxOpeningElement), nodesVisitor(node.children, visitor, ts.isJsxChild), visitNode(node.closingElement, visitor, ts.isJsxClosingElement)); - case 254 /* JsxAttributes */: - return ts.updateJsxAttributes(node, nodesVisitor(node.properties, visitor, ts.isJsxAttributeLike)); case 250 /* JsxSelfClosingElement */: return ts.updateJsxSelfClosingElement(node, visitNode(node.tagName, visitor, ts.isJsxTagNameExpression), visitNode(node.attributes, visitor, ts.isJsxAttributes)); case 251 /* JsxOpeningElement */: @@ -47863,6 +49575,8 @@ var ts; return ts.updateJsxClosingElement(node, visitNode(node.tagName, visitor, ts.isJsxTagNameExpression)); case 253 /* JsxAttribute */: return ts.updateJsxAttribute(node, visitNode(node.name, visitor, ts.isIdentifier), visitNode(node.initializer, visitor, ts.isStringLiteralOrJsxExpression)); + case 254 /* JsxAttributes */: + return ts.updateJsxAttributes(node, nodesVisitor(node.properties, visitor, ts.isJsxAttributeLike)); case 255 /* JsxSpreadAttribute */: return ts.updateJsxSpreadAttribute(node, visitNode(node.expression, visitor, ts.isExpression)); case 256 /* JsxExpression */: @@ -47890,9 +49604,12 @@ var ts; case 265 /* SourceFile */: return ts.updateSourceFileNode(node, visitLexicalEnvironment(node.statements, visitor, context)); // Transformation nodes - case 296 /* PartiallyEmittedExpression */: + case 297 /* PartiallyEmittedExpression */: return ts.updatePartiallyEmittedExpression(node, visitNode(node.expression, visitor, ts.isExpression)); + case 298 /* CommaListExpression */: + return ts.updateCommaList(node, nodesVisitor(node.elements, visitor, ts.isExpression)); default: + // No need to visit nodes with no children. return node; } } @@ -47945,7 +49662,7 @@ var ts; case 209 /* EmptyStatement */: case 200 /* OmittedExpression */: case 225 /* DebuggerStatement */: - case 295 /* NotEmittedStatement */: + case 296 /* NotEmittedStatement */: // No need to visit nodes with no children. break; // Names @@ -47968,6 +49685,13 @@ var ts; result = reduceNode(node.expression, cbNode, result); break; // Type member + case 148 /* PropertySignature */: + result = reduceNodes(node.modifiers, cbNodes, result); + result = reduceNode(node.name, cbNode, result); + result = reduceNode(node.questionToken, cbNode, result); + result = reduceNode(node.type, cbNode, result); + result = reduceNode(node.initializer, cbNode, result); + break; case 149 /* PropertyDeclaration */: result = reduceNodes(node.decorators, cbNodes, result); result = reduceNodes(node.modifiers, cbNodes, result); @@ -48315,9 +50039,12 @@ var ts; result = reduceNodes(node.statements, cbNodes, result); break; // Transformation nodes - case 296 /* PartiallyEmittedExpression */: + case 297 /* PartiallyEmittedExpression */: result = reduceNode(node.expression, cbNode, result); break; + case 298 /* CommaListExpression */: + result = reduceNodes(node.elements, cbNodes, result); + break; default: break; } @@ -48406,37 +50133,69 @@ var ts; } var Debug; (function (Debug) { + var isDebugInfoEnabled = false; Debug.failBadSyntaxKind = Debug.shouldAssert(1 /* Normal */) - ? function (node, message) { return Debug.assert(false, message || "Unexpected node.", function () { return "Node " + ts.formatSyntaxKind(node.kind) + " was unexpected."; }); } + ? function (node, message) { return Debug.fail((message || "Unexpected node.") + "\r\nNode " + ts.formatSyntaxKind(node.kind) + " was unexpected.", Debug.failBadSyntaxKind); } : ts.noop; Debug.assertEachNode = Debug.shouldAssert(1 /* Normal */) - ? function (nodes, test, message) { return Debug.assert(test === undefined || ts.every(nodes, test), message || "Unexpected node.", function () { return "Node array did not pass test '" + getFunctionName(test) + "'."; }); } + ? function (nodes, test, message) { return Debug.assert(test === undefined || ts.every(nodes, test), message || "Unexpected node.", function () { return "Node array did not pass test '" + Debug.getFunctionName(test) + "'."; }, Debug.assertEachNode); } : ts.noop; Debug.assertNode = Debug.shouldAssert(1 /* Normal */) - ? function (node, test, message) { return Debug.assert(test === undefined || test(node), message || "Unexpected node.", function () { return "Node " + ts.formatSyntaxKind(node.kind) + " did not pass test '" + getFunctionName(test) + "'."; }); } + ? function (node, test, message) { return Debug.assert(test === undefined || test(node), message || "Unexpected node.", function () { return "Node " + ts.formatSyntaxKind(node.kind) + " did not pass test '" + Debug.getFunctionName(test) + "'."; }, Debug.assertNode); } : ts.noop; Debug.assertOptionalNode = Debug.shouldAssert(1 /* Normal */) - ? function (node, test, message) { return Debug.assert(test === undefined || node === undefined || test(node), message || "Unexpected node.", function () { return "Node " + ts.formatSyntaxKind(node.kind) + " did not pass test '" + getFunctionName(test) + "'."; }); } + ? function (node, test, message) { return Debug.assert(test === undefined || node === undefined || test(node), message || "Unexpected node.", function () { return "Node " + ts.formatSyntaxKind(node.kind) + " did not pass test '" + Debug.getFunctionName(test) + "'."; }, Debug.assertOptionalNode); } : ts.noop; Debug.assertOptionalToken = Debug.shouldAssert(1 /* Normal */) - ? function (node, kind, message) { return Debug.assert(kind === undefined || node === undefined || node.kind === kind, message || "Unexpected node.", function () { return "Node " + ts.formatSyntaxKind(node.kind) + " was not a '" + ts.formatSyntaxKind(kind) + "' token."; }); } + ? function (node, kind, message) { return Debug.assert(kind === undefined || node === undefined || node.kind === kind, message || "Unexpected node.", function () { return "Node " + ts.formatSyntaxKind(node.kind) + " was not a '" + ts.formatSyntaxKind(kind) + "' token."; }, Debug.assertOptionalToken); } : ts.noop; Debug.assertMissingNode = Debug.shouldAssert(1 /* Normal */) - ? function (node, message) { return Debug.assert(node === undefined, message || "Unexpected node.", function () { return "Node " + ts.formatSyntaxKind(node.kind) + " was unexpected'."; }); } + ? function (node, message) { return Debug.assert(node === undefined, message || "Unexpected node.", function () { return "Node " + ts.formatSyntaxKind(node.kind) + " was unexpected'."; }, Debug.assertMissingNode); } : ts.noop; - function getFunctionName(func) { - if (typeof func !== "function") { - return ""; - } - else if (func.hasOwnProperty("name")) { - return func.name; - } - else { - var text = Function.prototype.toString.call(func); - var match = /^function\s+([\w\$]+)\s*\(/.exec(text); - return match ? match[1] : ""; + /** + * Injects debug information into frequently used types. + */ + function enableDebugInfo() { + if (isDebugInfoEnabled) + return; + // Add additional properties in debug mode to assist with debugging. + Object.defineProperties(ts.objectAllocator.getSymbolConstructor().prototype, { + "__debugFlags": { get: function () { return ts.formatSymbolFlags(this.flags); } } + }); + Object.defineProperties(ts.objectAllocator.getTypeConstructor().prototype, { + "__debugFlags": { get: function () { return ts.formatTypeFlags(this.flags); } }, + "__debugObjectFlags": { get: function () { return this.flags & 32768 /* Object */ ? ts.formatObjectFlags(this.objectFlags) : ""; } }, + "__debugTypeToString": { value: function () { return this.checker.typeToString(this); } }, + }); + var nodeConstructors = [ + ts.objectAllocator.getNodeConstructor(), + ts.objectAllocator.getIdentifierConstructor(), + ts.objectAllocator.getTokenConstructor(), + ts.objectAllocator.getSourceFileConstructor() + ]; + for (var _i = 0, nodeConstructors_1 = nodeConstructors; _i < nodeConstructors_1.length; _i++) { + var ctor = nodeConstructors_1[_i]; + if (!ctor.prototype.hasOwnProperty("__debugKind")) { + Object.defineProperties(ctor.prototype, { + "__debugKind": { get: function () { return ts.formatSyntaxKind(this.kind); } }, + "__debugModifierFlags": { get: function () { return ts.formatModifierFlags(ts.getModifierFlagsNoCache(this)); } }, + "__debugTransformFlags": { get: function () { return ts.formatTransformFlags(this.transformFlags); } }, + "__debugEmitFlags": { get: function () { return ts.formatEmitFlags(ts.getEmitFlags(this)); } }, + "__debugGetText": { + value: function (includeTrivia) { + if (ts.nodeIsSynthesized(this)) + return ""; + var parseNode = ts.getParseTreeNode(this); + var sourceFile = parseNode && ts.getSourceFileOfNode(parseNode); + return sourceFile ? ts.getSourceTextOfNodeFromSourceFile(sourceFile, parseNode, includeTrivia) : ""; + } + } + }); + } } + isDebugInfoEnabled = true; } + Debug.enableDebugInfo = enableDebugInfo; })(Debug = ts.Debug || (ts.Debug = {})); })(ts || (ts = {})); /// @@ -48897,6 +50656,22 @@ var ts; /* Enables substitutions for unqualified enum members */ TypeScriptSubstitutionFlags[TypeScriptSubstitutionFlags["NonQualifiedEnumMembers"] = 8] = "NonQualifiedEnumMembers"; })(TypeScriptSubstitutionFlags || (TypeScriptSubstitutionFlags = {})); + var ClassFacts; + (function (ClassFacts) { + ClassFacts[ClassFacts["None"] = 0] = "None"; + ClassFacts[ClassFacts["HasStaticInitializedProperties"] = 1] = "HasStaticInitializedProperties"; + ClassFacts[ClassFacts["HasConstructorDecorators"] = 2] = "HasConstructorDecorators"; + ClassFacts[ClassFacts["HasMemberDecorators"] = 4] = "HasMemberDecorators"; + ClassFacts[ClassFacts["IsExportOfNamespace"] = 8] = "IsExportOfNamespace"; + ClassFacts[ClassFacts["IsNamedExternalExport"] = 16] = "IsNamedExternalExport"; + ClassFacts[ClassFacts["IsDefaultExternalExport"] = 32] = "IsDefaultExternalExport"; + ClassFacts[ClassFacts["HasExtendsClause"] = 64] = "HasExtendsClause"; + ClassFacts[ClassFacts["UseImmediatelyInvokedFunctionExpression"] = 128] = "UseImmediatelyInvokedFunctionExpression"; + ClassFacts[ClassFacts["HasAnyDecorators"] = 6] = "HasAnyDecorators"; + ClassFacts[ClassFacts["NeedsName"] = 5] = "NeedsName"; + ClassFacts[ClassFacts["MayNeedImmediatelyInvokedFunctionExpression"] = 7] = "MayNeedImmediatelyInvokedFunctionExpression"; + ClassFacts[ClassFacts["IsExported"] = 56] = "IsExported"; + })(ClassFacts || (ClassFacts = {})); function transformTypeScript(context) { var startLexicalEnvironment = context.startLexicalEnvironment, resumeLexicalEnvironment = context.resumeLexicalEnvironment, endLexicalEnvironment = context.endLexicalEnvironment, hoistVariableDeclaration = context.hoistVariableDeclaration; var resolver = context.getEmitResolver(); @@ -48940,7 +50715,7 @@ var ts; * @param node A SourceFile node. */ function transformSourceFile(node) { - if (ts.isDeclarationFile(node)) { + if (node.isDeclarationFile) { return node; } currentSourceFile = node; @@ -49174,7 +50949,9 @@ var ts; case 231 /* TypeAliasDeclaration */: // TypeScript type-only declarations are elided. case 149 /* PropertyDeclaration */: - // TypeScript property declarations are elided. + // TypeScript property declarations are elided. + case 236 /* NamespaceExportDeclaration */: + // TypeScript namespace export declarations are elided. return undefined; case 152 /* Constructor */: return visitConstructor(node); @@ -49300,6 +51077,26 @@ var ts; function shouldEmitDecorateCallForParameter(parameter) { return parameter.decorators !== undefined && parameter.decorators.length > 0; } + function getClassFacts(node, staticProperties) { + var facts = 0 /* None */; + if (ts.some(staticProperties)) + facts |= 1 /* HasStaticInitializedProperties */; + if (ts.getClassExtendsHeritageClauseElement(node)) + facts |= 64 /* HasExtendsClause */; + if (shouldEmitDecorateCallForClass(node)) + facts |= 2 /* HasConstructorDecorators */; + if (ts.childIsDecorated(node)) + facts |= 4 /* HasMemberDecorators */; + if (isExportOfNamespace(node)) + facts |= 8 /* IsExportOfNamespace */; + else if (isDefaultExternalModuleExport(node)) + facts |= 32 /* IsDefaultExternalExport */; + else if (isNamedExternalModuleExport(node)) + facts |= 16 /* IsNamedExternalExport */; + if (languageVersion <= 1 /* ES5 */ && (facts & 7 /* MayNeedImmediatelyInvokedFunctionExpression */)) + facts |= 128 /* UseImmediatelyInvokedFunctionExpression */; + return facts; + } /** * Transforms a class declaration with TypeScript syntax into compatible ES6. * @@ -49313,44 +51110,73 @@ var ts; */ function visitClassDeclaration(node) { var staticProperties = getInitializedProperties(node, /*isStatic*/ true); - var hasExtendsClause = ts.getClassExtendsHeritageClauseElement(node) !== undefined; - var isDecoratedClass = shouldEmitDecorateCallForClass(node); - // emit name if - // - node has a name - // - node has static initializers - // - node has a member that is decorated - // - var name = node.name; - if (!name && (staticProperties.length > 0 || ts.childIsDecorated(node))) { - name = ts.getGeneratedNameForNode(node); - } - var classStatement = isDecoratedClass - ? createClassDeclarationHeadWithDecorators(node, name, hasExtendsClause) - : createClassDeclarationHeadWithoutDecorators(node, name, hasExtendsClause, staticProperties.length > 0); + var facts = getClassFacts(node, staticProperties); + if (facts & 128 /* UseImmediatelyInvokedFunctionExpression */) { + context.startLexicalEnvironment(); + } + var name = node.name || (facts & 5 /* NeedsName */ ? ts.getGeneratedNameForNode(node) : undefined); + var classStatement = facts & 2 /* HasConstructorDecorators */ + ? createClassDeclarationHeadWithDecorators(node, name, facts) + : createClassDeclarationHeadWithoutDecorators(node, name, facts); var statements = [classStatement]; // Emit static property assignment. Because classDeclaration is lexically evaluated, // it is safe to emit static property assignment after classDeclaration // From ES6 specification: // HasLexicalDeclaration (N) : Determines if the argument identifier has a binding in this environment record that was created using // a lexical declaration such as a LexicalDeclaration or a ClassDeclaration. - if (staticProperties.length) { - addInitializedPropertyStatements(statements, staticProperties, ts.getLocalName(node)); + if (facts & 1 /* HasStaticInitializedProperties */) { + addInitializedPropertyStatements(statements, staticProperties, facts & 128 /* UseImmediatelyInvokedFunctionExpression */ ? ts.getInternalName(node) : ts.getLocalName(node)); } // Write any decorators of the node. addClassElementDecorationStatements(statements, node, /*isStatic*/ false); addClassElementDecorationStatements(statements, node, /*isStatic*/ true); addConstructorDecorationStatement(statements, node); + if (facts & 128 /* UseImmediatelyInvokedFunctionExpression */) { + // When we emit a TypeScript class down to ES5, we must wrap it in an IIFE so that the + // 'es2015' transformer can properly nest static initializers and decorators. The result + // looks something like: + // + // var C = function () { + // class C { + // } + // C.static_prop = 1; + // return C; + // }(); + // + var closingBraceLocation = ts.createTokenRange(ts.skipTrivia(currentSourceFile.text, node.members.end), 18 /* CloseBraceToken */); + var localName = ts.getInternalName(node); + // The following partially-emitted expression exists purely to align our sourcemap + // emit with the original emitter. + var outer = ts.createPartiallyEmittedExpression(localName); + outer.end = closingBraceLocation.end; + ts.setEmitFlags(outer, 1536 /* NoComments */); + var statement = ts.createReturn(outer); + statement.pos = closingBraceLocation.pos; + ts.setEmitFlags(statement, 1536 /* NoComments */ | 384 /* NoTokenSourceMaps */); + statements.push(statement); + ts.addRange(statements, context.endLexicalEnvironment()); + var varStatement = ts.createVariableStatement( + /*modifiers*/ undefined, ts.createVariableDeclarationList([ + ts.createVariableDeclaration(ts.getLocalName(node, /*allowComments*/ false, /*allowSourceMaps*/ false), + /*type*/ undefined, ts.createImmediatelyInvokedFunctionExpression(statements)) + ])); + ts.setOriginalNode(varStatement, node); + ts.setCommentRange(varStatement, node); + ts.setSourceMapRange(varStatement, ts.moveRangePastDecorators(node)); + ts.startOnNewLine(varStatement); + statements = [varStatement]; + } // If the class is exported as part of a TypeScript namespace, emit the namespace export. // Otherwise, if the class was exported at the top level and was decorated, emit an export // declaration or export default for the class. - if (isNamespaceExport(node)) { + if (facts & 8 /* IsExportOfNamespace */) { addExportMemberAssignment(statements, node); } - else if (isDecoratedClass) { - if (isDefaultExternalModuleExport(node)) { + else if (facts & 128 /* UseImmediatelyInvokedFunctionExpression */ || facts & 2 /* HasConstructorDecorators */) { + if (facts & 32 /* IsDefaultExternalExport */) { statements.push(ts.createExportDefault(ts.getLocalName(node, /*allowComments*/ false, /*allowSourceMaps*/ true))); } - else if (isNamedExternalModuleExport(node)) { + else if (facts & 16 /* IsNamedExternalExport */) { statements.push(ts.createExternalModuleExport(ts.getLocalName(node, /*allowComments*/ false, /*allowSourceMaps*/ true))); } } @@ -49366,20 +51192,23 @@ var ts; * * @param node A ClassDeclaration node. * @param name The name of the class. - * @param hasExtendsClause A value indicating whether the class has an extends clause. - * @param hasStaticProperties A value indicating whether the class has static properties. + * @param facts Precomputed facts about the class. */ - function createClassDeclarationHeadWithoutDecorators(node, name, hasExtendsClause, hasStaticProperties) { + function createClassDeclarationHeadWithoutDecorators(node, name, facts) { // ${modifiers} class ${name} ${heritageClauses} { // ${members} // } + // we do not emit modifiers on the declaration if we are emitting an IIFE + var modifiers = !(facts & 128 /* UseImmediatelyInvokedFunctionExpression */) + ? ts.visitNodes(node.modifiers, modifierVisitor, ts.isModifier) + : undefined; var classDeclaration = ts.createClassDeclaration( - /*decorators*/ undefined, ts.visitNodes(node.modifiers, modifierVisitor, ts.isModifier), name, - /*typeParameters*/ undefined, ts.visitNodes(node.heritageClauses, visitor, ts.isHeritageClause), transformClassMembers(node, hasExtendsClause)); + /*decorators*/ undefined, modifiers, name, + /*typeParameters*/ undefined, ts.visitNodes(node.heritageClauses, visitor, ts.isHeritageClause), transformClassMembers(node, (facts & 64 /* HasExtendsClause */) !== 0)); // To better align with the old emitter, we should not emit a trailing source map // entry if the class has static properties. var emitFlags = ts.getEmitFlags(node); - if (hasStaticProperties) { + if (facts & 1 /* HasStaticInitializedProperties */) { emitFlags |= 32 /* NoTrailingSourceMap */; } ts.setTextRange(classDeclaration, node); @@ -49390,13 +51219,8 @@ var ts; /** * Transforms a decorated class declaration and appends the resulting statements. If * the class requires an alias to avoid issues with double-binding, the alias is returned. - * - * @param statements A statement list to which to add the declaration. - * @param node A ClassDeclaration node. - * @param name The name of the class. - * @param hasExtendsClause A value indicating whether the class has an extends clause. */ - function createClassDeclarationHeadWithDecorators(node, name, hasExtendsClause) { + function createClassDeclarationHeadWithDecorators(node, name, facts) { // When we emit an ES6 class that has a class decorator, we must tailor the // emit to certain specific cases. // @@ -49489,7 +51313,7 @@ var ts; // ${members} // } var heritageClauses = ts.visitNodes(node.heritageClauses, visitor, ts.isHeritageClause); - var members = transformClassMembers(node, hasExtendsClause); + var members = transformClassMembers(node, (facts & 64 /* HasExtendsClause */) !== 0); var classExpression = ts.createClassExpression(/*modifiers*/ undefined, name, /*typeParameters*/ undefined, heritageClauses, members); ts.setOriginalNode(classExpression, node); ts.setTextRange(classExpression, location); @@ -49990,8 +51814,8 @@ var ts; function generateClassElementDecorationExpressions(node, isStatic) { var members = getDecoratedClassElements(node, isStatic); var expressions; - for (var _i = 0, members_2 = members; _i < members_2.length; _i++) { - var member = members_2[_i]; + for (var _i = 0, members_3 = members; _i < members_3.length; _i++) { + var member = members_3[_i]; var expression = generateClassElementDecorationExpression(node, member); if (expression) { if (!expressions) { @@ -50359,21 +52183,17 @@ var ts; return ts.createIdentifier("Object"); } function serializeUnionOrIntersectionType(node) { + // Note when updating logic here also update getEntityNameForDecoratorMetadata + // so that aliases can be marked as referenced var serializedUnion; for (var _i = 0, _a = node.types; _i < _a.length; _i++) { var typeNode = _a[_i]; var serializedIndividual = serializeTypeNode(typeNode); - if (ts.isVoidExpression(serializedIndividual)) { - // If we dont have any other type already set, set the initial type - if (!serializedUnion) { - serializedUnion = serializedIndividual; - } - } - else if (ts.isIdentifier(serializedIndividual) && serializedIndividual.text === "Object") { + if (ts.isIdentifier(serializedIndividual) && serializedIndividual.text === "Object") { // One of the individual is global object, return immediately return serializedIndividual; } - else if (serializedUnion && !ts.isVoidExpression(serializedUnion)) { + else if (serializedUnion) { // Different types if (!ts.isIdentifier(serializedUnion) || !ts.isIdentifier(serializedIndividual) || @@ -50664,7 +52484,7 @@ var ts; /*decorators*/ undefined, ts.visitNodes(node.modifiers, modifierVisitor, ts.isModifier), node.asteriskToken, node.name, /*typeParameters*/ undefined, ts.visitParameterList(node.parameters, visitor, context), /*type*/ undefined, ts.visitFunctionBody(node.body, visitor, context) || ts.createBlock([])); - if (isNamespaceExport(node)) { + if (isExportOfNamespace(node)) { var statements = [updated]; addExportMemberAssignment(statements, node); return statements; @@ -50734,7 +52554,7 @@ var ts; * - The node is exported from a TypeScript namespace. */ function visitVariableStatement(node) { - if (isNamespaceExport(node)) { + if (isExportOfNamespace(node)) { var variables = ts.getInitializedVariables(node.declarationList); if (variables.length === 0) { // elide statement if there are no initialized variables. @@ -50903,7 +52723,12 @@ var ts; // we pass false as 'generateNameForComputedPropertyName' for a backward compatibility purposes // old emitter always generate 'expression' part of the name as-is. var name = getExpressionForPropertyName(member, /*generateNameForComputedPropertyName*/ false); - return ts.setTextRange(ts.createStatement(ts.setTextRange(ts.createAssignment(ts.createElementAccess(currentNamespaceContainerName, ts.createAssignment(ts.createElementAccess(currentNamespaceContainerName, name), transformEnumMemberDeclarationValue(member))), name), member)), member); + var valueExpression = transformEnumMemberDeclarationValue(member); + var innerAssignment = ts.createAssignment(ts.createElementAccess(currentNamespaceContainerName, name), valueExpression); + var outerAssignment = valueExpression.kind === 9 /* StringLiteral */ ? + innerAssignment : + ts.createAssignment(ts.createElementAccess(currentNamespaceContainerName, innerAssignment), name); + return ts.setTextRange(ts.createStatement(ts.setTextRange(outerAssignment, member)), member); } /** * Transforms the value of an enum member. @@ -50938,7 +52763,7 @@ var ts; * or `exports.x`). */ function hasNamespaceQualifiedExportName(node) { - return isNamespaceExport(node) + return isExportOfNamespace(node) || (isExternalModuleExport(node) && moduleKind !== ts.ModuleKind.ES2015 && moduleKind !== ts.ModuleKind.System); @@ -50978,10 +52803,12 @@ var ts; * Adds a leading VariableStatement for a enum or module declaration. */ function addVarForEnumOrModuleDeclaration(statements, node) { - // Emit a variable statement for the module. - var statement = ts.createVariableStatement(ts.visitNodes(node.modifiers, modifierVisitor, ts.isModifier), [ + // Emit a variable statement for the module. We emit top-level enums as a `var` + // declaration to avoid static errors in global scripts scripts due to redeclaration. + // enums in any other scope are emitted as a `let` declaration. + var statement = ts.createVariableStatement(ts.visitNodes(node.modifiers, modifierVisitor, ts.isModifier), ts.createVariableDeclarationList([ ts.createVariableDeclaration(ts.getLocalName(node, /*allowComments*/ false, /*allowSourceMaps*/ true)) - ]); + ], currentScope.kind === 265 /* SourceFile */ ? 0 /* None */ : 1 /* Let */)); ts.setOriginalNode(statement, node); recordEmittedDeclarationInScope(node); if (isFirstEmittedDeclarationInScope(node)) { @@ -51238,7 +53065,7 @@ var ts; function visitExportDeclaration(node) { if (!node.exportClause) { // Elide a star export if the module it references does not export a value. - return resolver.moduleExportsSomeValue(node.moduleSpecifier) ? node : undefined; + return compilerOptions.isolatedModules || resolver.moduleExportsSomeValue(node.moduleSpecifier) ? node : undefined; } if (!resolver.isValueAliasDeclaration(node)) { // Elide the export declaration if it does not export a value. @@ -51302,7 +53129,7 @@ var ts; } var moduleReference = ts.createExpressionFromEntityName(node.moduleReference); ts.setEmitFlags(moduleReference, 1536 /* NoComments */ | 2048 /* NoNestedComments */); - if (isNamedExternalModuleExport(node) || !isNamespaceExport(node)) { + if (isNamedExternalModuleExport(node) || !isExportOfNamespace(node)) { // export var ${name} = ${moduleReference}; // var ${name} = ${moduleReference}; return ts.setOriginalNode(ts.setTextRange(ts.createVariableStatement(ts.visitNodes(node.modifiers, modifierVisitor, ts.isModifier), ts.createVariableDeclarationList([ @@ -51320,7 +53147,7 @@ var ts; * * @param node The node to test. */ - function isNamespaceExport(node) { + function isExportOfNamespace(node) { return currentNamespace !== undefined && ts.hasModifier(node, 1 /* Export */); } /** @@ -51524,10 +53351,10 @@ var ts; if (declaration) { var classAlias = classAliases[declaration.id]; if (classAlias) { - var clone_2 = ts.getSynthesizedClone(classAlias); - ts.setSourceMapRange(clone_2, node); - ts.setCommentRange(clone_2, node); - return clone_2; + var clone_1 = ts.getSynthesizedClone(classAlias); + ts.setSourceMapRange(clone_1, node); + ts.setCommentRange(clone_1, node); + return clone_1; } } } @@ -51667,7 +53494,7 @@ var ts; context.onSubstituteNode = onSubstituteNode; return transformSourceFile; function transformSourceFile(node) { - if (ts.isDeclarationFile(node)) { + if (node.isDeclarationFile) { return node; } currentSourceFile = node; @@ -52004,7 +53831,7 @@ var ts; var enclosingSuperContainerFlags = 0; return transformSourceFile; function transformSourceFile(node) { - if (ts.isDeclarationFile(node)) { + if (node.isDeclarationFile) { return node; } var visited = ts.visitEachChild(node, visitor, context); @@ -52230,8 +54057,10 @@ var ts; return ts.setEmitFlags(ts.setTextRange(ts.createBlock(ts.setTextRange(ts.createNodeArray(statements), statementsLocation), /*multiLine*/ true), bodyLocation), 48 /* NoSourceMap */ | 384 /* NoTokenSourceMaps */); } - function awaitAsYield(expression) { - return ts.createYield(/*asteriskToken*/ undefined, enclosingFunctionFlags & 1 /* Generator */ ? createAwaitHelper(context, expression) : expression); + function createDownlevelAwait(expression) { + return enclosingFunctionFlags & 1 /* Generator */ + ? ts.createYield(/*asteriskToken*/ undefined, createAwaitHelper(context, expression)) + : ts.createAwait(expression); } function transformForAwaitOfStatement(node, outermostLabeledStatement) { var expression = ts.visitNode(node.expression, visitor, ts.isExpression); @@ -52252,9 +54081,9 @@ var ts; ts.setTextRange(ts.createVariableDeclaration(iterator, /*type*/ undefined, callValues), node.expression), ts.createVariableDeclaration(result) ]), node.expression), 2097152 /* NoHoisting */), - /*condition*/ ts.createComma(ts.createAssignment(result, awaitAsYield(callNext)), ts.createLogicalNot(getDone)), + /*condition*/ ts.createComma(ts.createAssignment(result, createDownlevelAwait(callNext)), ts.createLogicalNot(getDone)), /*incrementor*/ undefined, - /*statement*/ convertForOfStatementHead(node, awaitAsYield(getValue))), + /*statement*/ convertForOfStatementHead(node, createDownlevelAwait(getValue))), /*location*/ node), 256 /* NoTokenTrailingSourceMaps */); return ts.createTry(ts.createBlock([ ts.restoreEnclosingLabel(forStatement, outermostLabeledStatement) @@ -52265,7 +54094,7 @@ var ts; ]), 1 /* SingleLine */)), ts.createBlock([ ts.createTry( /*tryBlock*/ ts.createBlock([ - ts.setEmitFlags(ts.createIf(ts.createLogicalAnd(ts.createLogicalAnd(result, ts.createLogicalNot(getDone)), ts.createAssignment(returnMethod, ts.createPropertyAccess(iterator, "return"))), ts.createStatement(awaitAsYield(callReturn))), 1 /* SingleLine */) + ts.setEmitFlags(ts.createIf(ts.createLogicalAnd(ts.createLogicalAnd(result, ts.createLogicalNot(getDone)), ts.createAssignment(returnMethod, ts.createPropertyAccess(iterator, "return"))), ts.createStatement(createDownlevelAwait(callReturn))), 1 /* SingleLine */) ]), /*catchClause*/ undefined, /*finallyBlock*/ ts.setEmitFlags(ts.createBlock([ @@ -52614,7 +54443,7 @@ var ts; * @param node A SourceFile node. */ function transformSourceFile(node) { - if (ts.isDeclarationFile(node)) { + if (node.isDeclarationFile) { return node; } var visited = ts.visitEachChild(node, visitor, context); @@ -53099,7 +54928,7 @@ var ts; var hoistVariableDeclaration = context.hoistVariableDeclaration; return transformSourceFile; function transformSourceFile(node) { - if (ts.isDeclarationFile(node)) { + if (node.isDeclarationFile) { return node; } return ts.visitEachChild(node, visitor, context); @@ -53306,7 +55135,7 @@ var ts; var enabledSubstitutions; return transformSourceFile; function transformSourceFile(node) { - if (ts.isDeclarationFile(node)) { + if (node.isDeclarationFile) { return node; } currentSourceFile = node; @@ -53343,11 +55172,58 @@ var ts; && node.kind === 219 /* ReturnStatement */ && !node.expression; } + function isClassLikeVariableStatement(node) { + if (!ts.isVariableStatement(node)) + return false; + var variable = ts.singleOrUndefined(node.declarationList.declarations); + return variable + && variable.initializer + && ts.isIdentifier(variable.name) + && (ts.isClassLike(variable.initializer) + || (ts.isAssignmentExpression(variable.initializer) + && ts.isIdentifier(variable.initializer.left) + && ts.isClassLike(variable.initializer.right))); + } + function isTypeScriptClassWrapper(node) { + var call = ts.tryCast(node, ts.isCallExpression); + if (!call || ts.isParseTreeNode(call) || + ts.some(call.typeArguments) || + ts.some(call.arguments)) { + return false; + } + var func = ts.tryCast(ts.skipOuterExpressions(call.expression), ts.isFunctionExpression); + if (!func || ts.isParseTreeNode(func) || + ts.some(func.typeParameters) || + ts.some(func.parameters) || + func.type || + !func.body) { + return false; + } + var statements = func.body.statements; + if (statements.length < 2) { + return false; + } + var firstStatement = statements[0]; + if (ts.isParseTreeNode(firstStatement) || + !ts.isClassLike(firstStatement) && + !isClassLikeVariableStatement(firstStatement)) { + return false; + } + var lastStatement = ts.elementAt(statements, -1); + var returnStatement = ts.tryCast(ts.isVariableStatement(lastStatement) ? ts.elementAt(statements, -2) : lastStatement, ts.isReturnStatement); + if (!returnStatement || + !returnStatement.expression || + !ts.isIdentifier(ts.skipOuterExpressions(returnStatement.expression))) { + return false; + } + return true; + } function shouldVisitNode(node) { return (node.transformFlags & 128 /* ContainsES2015 */) !== 0 || convertedLoopState !== undefined || (hierarchyFacts & 4096 /* ConstructorWithCapturedSuper */ && ts.isStatement(node)) - || (ts.isIterationStatement(node, /*lookInLabeledStatements*/ false) && shouldConvertIterationStatementBody(node)); + || (ts.isIterationStatement(node, /*lookInLabeledStatements*/ false) && shouldConvertIterationStatementBody(node)) + || isTypeScriptClassWrapper(node); } function visitor(node) { if (shouldVisitNode(node)) { @@ -54584,12 +56460,13 @@ var ts; } else { assignment = ts.createBinary(decl.name, 58 /* EqualsToken */, ts.visitNode(decl.initializer, visitor, ts.isExpression)); + ts.setTextRange(assignment, decl); } assignments = ts.append(assignments, assignment); } } if (assignments) { - updated = ts.setTextRange(ts.createStatement(ts.reduceLeft(assignments, function (acc, v) { return ts.createBinary(v, 26 /* CommaToken */, acc); })), node); + updated = ts.setTextRange(ts.createStatement(ts.inlineExpressions(assignments)), node); } else { // none of declarations has initializer - the entire variable statement can be deleted @@ -54612,9 +56489,9 @@ var ts; if (node.flags & 3 /* BlockScoped */) { enableSubstitutionsForBlockScopedBindings(); } - var declarations = ts.flatten(ts.map(node.declarations, node.flags & 1 /* Let */ + var declarations = ts.flatMap(node.declarations, node.flags & 1 /* Let */ ? visitVariableDeclarationInLetDeclarationList - : visitVariableDeclaration)); + : visitVariableDeclaration); var declarationList = ts.createVariableDeclarationList(declarations); ts.setOriginalNode(declarationList, node); ts.setTextRange(declarationList, node); @@ -54707,9 +56584,9 @@ var ts; return visitVariableDeclaration(node); } if (!node.initializer && shouldEmitExplicitInitializerForLetDeclaration(node)) { - var clone_3 = ts.getMutableClone(node); - clone_3.initializer = ts.createVoidZero(); - return clone_3; + var clone_2 = ts.getMutableClone(node); + clone_2.initializer = ts.createVoidZero(); + return clone_2; } return ts.visitEachChild(node, visitor, context); } @@ -55160,17 +57037,17 @@ var ts; loop = convert(node, outermostLabeledStatement, convertedLoopBodyStatements); } else { - var clone_4 = ts.getMutableClone(node); + var clone_3 = ts.getMutableClone(node); // clean statement part - clone_4.statement = undefined; + clone_3.statement = undefined; // visit childnodes to transform initializer/condition/incrementor parts - clone_4 = ts.visitEachChild(clone_4, visitor, context); + clone_3 = ts.visitEachChild(clone_3, visitor, context); // set loop statement - clone_4.statement = ts.createBlock(convertedLoopBodyStatements, /*multiline*/ true); + clone_3.statement = ts.createBlock(convertedLoopBodyStatements, /*multiline*/ true); // reset and re-aggregate the transform flags - clone_4.transformFlags = 0; - ts.aggregateTransformFlags(clone_4); - loop = ts.restoreEnclosingLabel(clone_4, outermostLabeledStatement, convertedLoopState && resetLabel); + clone_3.transformFlags = 0; + ts.aggregateTransformFlags(clone_3); + loop = ts.restoreEnclosingLabel(clone_3, outermostLabeledStatement, convertedLoopState && resetLabel); } statements.push(loop); return statements; @@ -55477,12 +57354,122 @@ var ts; * @param node a CallExpression. */ function visitCallExpression(node) { + if (isTypeScriptClassWrapper(node)) { + return visitTypeScriptClassWrapper(node); + } if (node.transformFlags & 64 /* ES2015 */) { return visitCallExpressionWithPotentialCapturedThisAssignment(node, /*assignToCapturedThis*/ true); } return ts.updateCall(node, ts.visitNode(node.expression, callExpressionVisitor, ts.isExpression), /*typeArguments*/ undefined, ts.visitNodes(node.arguments, visitor, ts.isExpression)); } + function visitTypeScriptClassWrapper(node) { + // This is a call to a class wrapper function (an IIFE) created by the 'ts' transformer. + // The wrapper has a form similar to: + // + // (function() { + // class C { // 1 + // } + // C.x = 1; // 2 + // return C; + // }()) + // + // When we transform the class, we end up with something like this: + // + // (function () { + // var C = (function () { // 3 + // function C() { + // } + // return C; // 4 + // }()); + // C.x = 1; + // return C; + // }()) + // + // We want to simplify the two nested IIFEs to end up with something like this: + // + // (function () { + // function C() { + // } + // C.x = 1; + // return C; + // }()) + // We skip any outer expressions in a number of places to get to the innermost + // expression, but we will restore them later to preserve comments and source maps. + var body = ts.cast(ts.skipOuterExpressions(node.expression), ts.isFunctionExpression).body; + // The class statements are the statements generated by visiting the first statement of the + // body (1), while all other statements are added to remainingStatements (2) + var classStatements = ts.visitNodes(body.statements, visitor, ts.isStatement, 0, 1); + var remainingStatements = ts.visitNodes(body.statements, visitor, ts.isStatement, 1, body.statements.length - 1); + var varStatement = ts.cast(ts.firstOrUndefined(classStatements), ts.isVariableStatement); + // We know there is only one variable declaration here as we verified this in an + // earlier call to isTypeScriptClassWrapper + var variable = varStatement.declarationList.declarations[0]; + var initializer = ts.skipOuterExpressions(variable.initializer); + // Under certain conditions, the 'ts' transformer may introduce a class alias, which + // we see as an assignment, for example: + // + // (function () { + // var C = C_1 = (function () { + // function C() { + // } + // C.x = function () { return C_1; } + // return C; + // }()); + // C = C_1 = __decorate([dec], C); + // return C; + // var C_1; + // }()) + // + var aliasAssignment = ts.tryCast(initializer, ts.isAssignmentExpression); + // The underlying call (3) is another IIFE that may contain a '_super' argument. + var call = ts.cast(aliasAssignment ? ts.skipOuterExpressions(aliasAssignment.right) : initializer, ts.isCallExpression); + var func = ts.cast(ts.skipOuterExpressions(call.expression), ts.isFunctionExpression); + var funcStatements = func.body.statements; + var classBodyStart = 0; + var classBodyEnd = -1; + var statements = []; + if (aliasAssignment) { + // If we have a class alias assignment, we need to move it to the down-level constructor + // function we generated for the class. + var extendsCall = ts.tryCast(funcStatements[classBodyStart], ts.isExpressionStatement); + if (extendsCall) { + statements.push(extendsCall); + classBodyStart++; + } + // The next statement is the function declaration. + statements.push(funcStatements[classBodyStart]); + classBodyStart++; + // Add the class alias following the declaration. + statements.push(ts.createStatement(ts.createAssignment(aliasAssignment.left, ts.cast(variable.name, ts.isIdentifier)))); + } + // Find the trailing 'return' statement (4) + while (!ts.isReturnStatement(ts.elementAt(funcStatements, classBodyEnd))) { + classBodyEnd--; + } + // When we extract the statements of the inner IIFE, we exclude the 'return' statement (4) + // as we already have one that has been introduced by the 'ts' transformer. + ts.addRange(statements, funcStatements, classBodyStart, classBodyEnd); + if (classBodyEnd < -1) { + // If there were any hoisted declarations following the return statement, we should + // append them. + ts.addRange(statements, funcStatements, classBodyEnd + 1); + } + // Add the remaining statements of the outer wrapper. + ts.addRange(statements, remainingStatements); + // The 'es2015' class transform may add an end-of-declaration marker. If so we will add it + // after the remaining statements from the 'ts' transformer. + ts.addRange(statements, classStatements, /*start*/ 1); + // Recreate any outer parentheses or partially-emitted expressions to preserve source map + // and comment locations. + return ts.recreateOuterExpressions(node.expression, ts.recreateOuterExpressions(variable.initializer, ts.recreateOuterExpressions(aliasAssignment && aliasAssignment.right, ts.updateCall(call, ts.recreateOuterExpressions(call.expression, ts.updateFunctionExpression(func, + /*modifiers*/ undefined, + /*asteriskToken*/ undefined, + /*name*/ undefined, + /*typeParameters*/ undefined, func.parameters, + /*type*/ undefined, ts.updateBlock(func.body, statements))), + /*typeArguments*/ undefined, call.arguments)))); + } function visitImmediateSuperCallInBody(node) { return visitCallExpressionWithPotentialCapturedThisAssignment(node, /*assignToCapturedThis*/ false); } @@ -55586,7 +57573,7 @@ var ts; else { if (segments.length === 1) { var firstElement = elements[0]; - return needsUniqueCopy && ts.isSpreadExpression(firstElement) && firstElement.expression.kind !== 177 /* ArrayLiteralExpression */ + return needsUniqueCopy && ts.isSpreadElement(firstElement) && firstElement.expression.kind !== 177 /* ArrayLiteralExpression */ ? ts.createArraySlice(segments[0]) : segments[0]; } @@ -55595,7 +57582,7 @@ var ts; } } function partitionSpread(node) { - return ts.isSpreadExpression(node) + return ts.isSpreadElement(node) ? visitSpanOfSpreads : visitSpanOfNonSpreads; } @@ -55946,9 +57933,7 @@ var ts; return false; } if (ts.isClassElement(currentNode) && currentNode.parent === declaration) { - // we are in the class body, but we treat static fields as outside of the class body - return currentNode.kind !== 149 /* PropertyDeclaration */ - || (ts.getModifierFlags(currentNode) & 32 /* Static */) === 0; + return true; } currentNode = currentNode.parent; } @@ -56358,8 +58343,7 @@ var ts; var withBlockStack; // A stack containing `with` blocks. return transformSourceFile; function transformSourceFile(node) { - if (ts.isDeclarationFile(node) - || (node.transformFlags & 512 /* ContainsGenerator */) === 0) { + if (node.isDeclarationFile || (node.transformFlags & 512 /* ContainsGenerator */) === 0) { return node; } currentSourceFile = node; @@ -56661,7 +58645,7 @@ var ts; if (variables.length === 0) { return undefined; } - return ts.createStatement(ts.inlineExpressions(ts.map(variables, transformInitializedVariable))); + return ts.setSourceMapRange(ts.createStatement(ts.inlineExpressions(ts.map(variables, transformInitializedVariable))), node); } } /** @@ -56767,10 +58751,10 @@ var ts; // _a = a(); // .yield resumeLabel // _a + %sent% + c() - var clone_5 = ts.getMutableClone(node); - clone_5.left = cacheExpression(ts.visitNode(node.left, visitor, ts.isExpression)); - clone_5.right = ts.visitNode(node.right, visitor, ts.isExpression); - return clone_5; + var clone_4 = ts.getMutableClone(node); + clone_4.left = cacheExpression(ts.visitNode(node.left, visitor, ts.isExpression)); + clone_4.right = ts.visitNode(node.right, visitor, ts.isExpression); + return clone_4; } return ts.visitEachChild(node, visitor, context); } @@ -57031,10 +59015,10 @@ var ts; // .yield resumeLabel // .mark resumeLabel // a = _a[%sent%] - var clone_6 = ts.getMutableClone(node); - clone_6.expression = cacheExpression(ts.visitNode(node.expression, visitor, ts.isLeftHandSideExpression)); - clone_6.argumentExpression = ts.visitNode(node.argumentExpression, visitor, ts.isExpression); - return clone_6; + var clone_5 = ts.getMutableClone(node); + clone_5.expression = cacheExpression(ts.visitNode(node.expression, visitor, ts.isLeftHandSideExpression)); + clone_5.argumentExpression = ts.visitNode(node.argumentExpression, visitor, ts.isExpression); + return clone_5; } return ts.visitEachChild(node, visitor, context); } @@ -57173,7 +59157,7 @@ var ts; return undefined; } function transformInitializedVariable(node) { - return ts.createAssignment(ts.getSynthesizedClone(node.name), ts.visitNode(node.initializer, visitor, ts.isExpression)); + return ts.setSourceMapRange(ts.createAssignment(ts.setSourceMapRange(ts.getSynthesizedClone(node.name), node.name), ts.visitNode(node.initializer, visitor, ts.isExpression)), node); } function transformAndEmitIfStatement(node) { if (containsYield(node)) { @@ -57724,10 +59708,10 @@ var ts; if (declaration) { var name = renamedCatchVariableDeclarations[ts.getOriginalNodeId(declaration)]; if (name) { - var clone_7 = ts.getMutableClone(name); - ts.setSourceMapRange(clone_7, node); - ts.setCommentRange(clone_7, node); - return clone_7; + var clone_6 = ts.getMutableClone(name); + ts.setSourceMapRange(clone_6, node); + ts.setCommentRange(clone_6, node); + return clone_6; } } } @@ -58805,6 +60789,7 @@ var ts; var currentSourceFile; // The current file. var currentModuleInfo; // The ExternalModuleInfo for the current file. var noSubstitution; // Set of nodes for which substitution rules should be ignored. + var needUMDDynamicImportHelper; return transformSourceFile; /** * Transforms the module aspects of a SourceFile. @@ -58812,7 +60797,7 @@ var ts; * @param node The SourceFile node. */ function transformSourceFile(node) { - if (ts.isDeclarationFile(node) || !(ts.isExternalModule(node) || compilerOptions.isolatedModules)) { + if (node.isDeclarationFile || !(ts.isExternalModule(node) || compilerOptions.isolatedModules || node.transformFlags & 67108864 /* ContainsDynamicImport */)) { return node; } currentSourceFile = node; @@ -58823,6 +60808,7 @@ var ts; var updated = transformModule(node); currentSourceFile = undefined; currentModuleInfo = undefined; + needUMDDynamicImportHelper = false; return ts.aggregateTransformFlags(updated); } function shouldEmitUnderscoreUnderscoreESModule() { @@ -58849,11 +60835,12 @@ var ts; addExportEqualsIfNeeded(statements, /*emitAsReturn*/ false); ts.addRange(statements, endLexicalEnvironment()); var updated = ts.updateSourceFileNode(node, ts.setTextRange(ts.createNodeArray(statements), node.statements)); - if (currentModuleInfo.hasExportStarsToExportValues) { + if (currentModuleInfo.hasExportStarsToExportValues && !compilerOptions.importHelpers) { // If we have any `export * from ...` declarations // we need to inform the emitter to add the __export helper. ts.addEmitHelper(updated, exportStarHelper); } + ts.addEmitHelpers(updated, context.readEmitHelpers()); return updated; } /** @@ -59052,11 +61039,14 @@ var ts; // and merge any new lexical declarations. ts.addRange(statements, endLexicalEnvironment()); var body = ts.createBlock(statements, /*multiLine*/ true); - if (currentModuleInfo.hasExportStarsToExportValues) { + if (currentModuleInfo.hasExportStarsToExportValues && !compilerOptions.importHelpers) { // If we have any `export * from ...` declarations // we need to inform the emitter to add the __export helper. ts.addEmitHelper(body, exportStarHelper); } + if (needUMDDynamicImportHelper) { + ts.addEmitHelper(body, dynamicImportUMDHelper); + } return body; } /** @@ -59107,16 +61097,92 @@ var ts; return visitFunctionDeclaration(node); case 229 /* ClassDeclaration */: return visitClassDeclaration(node); - case 297 /* MergeDeclarationMarker */: + case 299 /* MergeDeclarationMarker */: return visitMergeDeclarationMarker(node); - case 298 /* EndOfDeclarationMarker */: + case 300 /* EndOfDeclarationMarker */: return visitEndOfDeclarationMarker(node); default: - // This visitor does not descend into the tree, as export/import statements - // are only transformed at the top level of a file. - return node; + return ts.visitEachChild(node, importCallExpressionVisitor, context); + } + } + function importCallExpressionVisitor(node) { + // This visitor does not need to descend into the tree if there is no dynamic import, + // as export/import statements are only transformed at the top level of a file. + if (!(node.transformFlags & 67108864 /* ContainsDynamicImport */)) { + return node; + } + if (ts.isImportCall(node)) { + return visitImportCallExpression(node); + } + else { + return ts.visitEachChild(node, importCallExpressionVisitor, context); + } + } + function visitImportCallExpression(node) { + switch (compilerOptions.module) { + case ts.ModuleKind.AMD: + return transformImportCallExpressionAMD(node); + case ts.ModuleKind.UMD: + return transformImportCallExpressionUMD(node); + case ts.ModuleKind.CommonJS: + default: + return transformImportCallExpressionCommonJS(node); } } + function transformImportCallExpressionUMD(node) { + // (function (factory) { + // ... (regular UMD) + // } + // })(function (require, exports, useSyncRequire) { + // "use strict"; + // Object.defineProperty(exports, "__esModule", { value: true }); + // var __syncRequire = typeof module === "object" && typeof module.exports === "object"; + // var __resolved = new Promise(function (resolve) { resolve(); }); + // ..... + // __syncRequire + // ? __resolved.then(function () { return require(x); }) /*CommonJs Require*/ + // : new Promise(function (_a, _b) { require([x], _a, _b); }); /*Amd Require*/ + // }); + needUMDDynamicImportHelper = true; + return ts.createConditional( + /*condition*/ ts.createIdentifier("__syncRequire"), + /*whenTrue*/ transformImportCallExpressionCommonJS(node), + /*whenFalse*/ transformImportCallExpressionAMD(node)); + } + function transformImportCallExpressionAMD(node) { + // improt("./blah") + // emit as + // define(["require", "exports", "blah"], function (require, exports) { + // ... + // new Promise(function (_a, _b) { require([x], _a, _b); }); /*Amd Require*/ + // }); + var resolve = ts.createUniqueName("resolve"); + var reject = ts.createUniqueName("reject"); + return ts.createNew(ts.createIdentifier("Promise"), + /*typeArguments*/ undefined, [ts.createFunctionExpression( + /*modifiers*/ undefined, + /*asteriskToken*/ undefined, + /*name*/ undefined, + /*typeParameters*/ undefined, [ts.createParameter(/*decorator*/ undefined, /*modifiers*/ undefined, /*dotDotDotToken*/ undefined, /*name*/ resolve), + ts.createParameter(/*decorator*/ undefined, /*modifiers*/ undefined, /*dotDotDotToken*/ undefined, /*name*/ reject)], + /*type*/ undefined, ts.createBlock([ts.createStatement(ts.createCall(ts.createIdentifier("require"), + /*typeArguments*/ undefined, [ts.createArrayLiteral([ts.firstOrUndefined(node.arguments) || ts.createOmittedExpression()]), resolve, reject]))]))]); + } + function transformImportCallExpressionCommonJS(node) { + // import("./blah") + // emit as + // Promise.resolve().then(function () { return require(x); }) /*CommonJs Require*/ + // We have to wrap require in then callback so that require is done in asynchronously + // if we simply do require in resolve callback in Promise constructor. We will execute the loading immediately + return ts.createCall(ts.createPropertyAccess(ts.createCall(ts.createPropertyAccess(ts.createIdentifier("Promise"), "resolve"), /*typeArguments*/ undefined, /*argumentsArray*/ []), "then"), + /*typeArguments*/ undefined, [ts.createFunctionExpression( + /*modifiers*/ undefined, + /*asteriskToken*/ undefined, + /*name*/ undefined, + /*typeParameters*/ undefined, + /*parameters*/ undefined, + /*type*/ undefined, ts.createBlock([ts.createReturn(ts.createCall(ts.createIdentifier("require"), /*typeArguments*/ undefined, node.arguments))]))]); + } /** * Visits an ImportDeclaration node. * @@ -59254,12 +61320,7 @@ var ts; } else { // export * from "mod"; - return ts.setTextRange(ts.createStatement(ts.createCall(ts.createIdentifier("__export"), - /*typeArguments*/ undefined, [ - moduleKind !== ts.ModuleKind.AMD - ? createRequireCall(node) - : generatedName - ])), node); + return ts.setTextRange(ts.createStatement(createExportStarHelper(context, moduleKind !== ts.ModuleKind.AMD ? createRequireCall(node) : generatedName)), node); } } /** @@ -59293,13 +61354,13 @@ var ts; if (ts.hasModifier(node, 1 /* Export */)) { statements = ts.append(statements, ts.setOriginalNode(ts.setTextRange(ts.createFunctionDeclaration( /*decorators*/ undefined, ts.visitNodes(node.modifiers, modifierVisitor, ts.isModifier), node.asteriskToken, ts.getDeclarationName(node, /*allowComments*/ true, /*allowSourceMaps*/ true), - /*typeParameters*/ undefined, node.parameters, - /*type*/ undefined, node.body), + /*typeParameters*/ undefined, ts.visitNodes(node.parameters, importCallExpressionVisitor), + /*type*/ undefined, ts.visitEachChild(node.body, importCallExpressionVisitor, context)), /*location*/ node), /*original*/ node)); } else { - statements = ts.append(statements, node); + statements = ts.append(statements, ts.visitEachChild(node, importCallExpressionVisitor, context)); } if (hasAssociatedEndOfDeclarationMarker(node)) { // Defer exports until we encounter an EndOfDeclarationMarker node @@ -59321,10 +61382,10 @@ var ts; if (ts.hasModifier(node, 1 /* Export */)) { statements = ts.append(statements, ts.setOriginalNode(ts.setTextRange(ts.createClassDeclaration( /*decorators*/ undefined, ts.visitNodes(node.modifiers, modifierVisitor, ts.isModifier), ts.getDeclarationName(node, /*allowComments*/ true, /*allowSourceMaps*/ true), - /*typeParameters*/ undefined, node.heritageClauses, node.members), node), node)); + /*typeParameters*/ undefined, ts.visitNodes(node.heritageClauses, importCallExpressionVisitor), node.members), node), node)); } else { - statements = ts.append(statements, node); + statements = ts.append(statements, ts.visitEachChild(node, importCallExpressionVisitor, context)); } if (hasAssociatedEndOfDeclarationMarker(node)) { // Defer exports until we encounter an EndOfDeclarationMarker node @@ -59369,7 +61430,7 @@ var ts; } } else { - statements = ts.append(statements, node); + statements = ts.append(statements, ts.visitEachChild(node, importCallExpressionVisitor, context)); } if (hasAssociatedEndOfDeclarationMarker(node)) { // Defer exports until we encounter an EndOfDeclarationMarker node @@ -59388,13 +61449,13 @@ var ts; */ function transformInitializedVariable(node) { if (ts.isBindingPattern(node.name)) { - return ts.flattenDestructuringAssignment(node, + return ts.flattenDestructuringAssignment(ts.visitNode(node, importCallExpressionVisitor), /*visitor*/ undefined, context, 0 /* All */, /*needsValue*/ false, createExportExpression); } else { return ts.createAssignment(ts.setTextRange(ts.createPropertyAccess(ts.createIdentifier("exports"), node.name), - /*location*/ node.name), node.initializer); + /*location*/ node.name), ts.visitNode(node.initializer, importCallExpressionVisitor)); } } /** @@ -59867,7 +61928,19 @@ var ts; var exportStarHelper = { name: "typescript:export-star", scoped: true, - text: "\n function __export(m) {\n for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];\n }" + text: "\n function __export(m) {\n for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];\n }\n " + }; + function createExportStarHelper(context, module) { + var compilerOptions = context.getCompilerOptions(); + return compilerOptions.importHelpers + ? ts.createCall(ts.getHelperName("__exportStar"), /*typeArguments*/ undefined, [module, ts.createIdentifier("exports")]) + : ts.createCall(ts.createIdentifier("__export"), /*typeArguments*/ undefined, [module]); + } + // emit helper for dynamic import + var dynamicImportUMDHelper = { + name: "typescript:dynamicimport-sync-require", + scoped: true, + text: "\n var __syncRequire = typeof module === \"object\" && typeof module.exports === \"object\";" }; })(ts || (ts = {})); /// @@ -59908,9 +61981,7 @@ var ts; * @param node The SourceFile node. */ function transformSourceFile(node) { - if (ts.isDeclarationFile(node) - || !(ts.isExternalModule(node) - || compilerOptions.isolatedModules)) { + if (node.isDeclarationFile || !(ts.isEffectiveExternalModule(node, compilerOptions) || node.transformFlags & 67108864 /* ContainsDynamicImport */)) { return node; } var id = ts.getOriginalNodeId(node); @@ -60341,7 +62412,7 @@ var ts; // Elide `export=` as it is illegal in a SystemJS module. return undefined; } - var expression = ts.visitNode(node.expression, destructuringVisitor, ts.isExpression); + var expression = ts.visitNode(node.expression, destructuringAndImportCallVisitor, ts.isExpression); var original = node.original; if (original && hasAssociatedEndOfDeclarationMarker(original)) { // Defer exports until we encounter an EndOfDeclarationMarker node @@ -60360,11 +62431,11 @@ var ts; function visitFunctionDeclaration(node) { if (ts.hasModifier(node, 1 /* Export */)) { hoistedStatements = ts.append(hoistedStatements, ts.updateFunctionDeclaration(node, node.decorators, ts.visitNodes(node.modifiers, modifierVisitor, ts.isModifier), node.asteriskToken, ts.getDeclarationName(node, /*allowComments*/ true, /*allowSourceMaps*/ true), - /*typeParameters*/ undefined, ts.visitNodes(node.parameters, destructuringVisitor, ts.isParameterDeclaration), - /*type*/ undefined, ts.visitNode(node.body, destructuringVisitor, ts.isBlock))); + /*typeParameters*/ undefined, ts.visitNodes(node.parameters, destructuringAndImportCallVisitor, ts.isParameterDeclaration), + /*type*/ undefined, ts.visitNode(node.body, destructuringAndImportCallVisitor, ts.isBlock))); } else { - hoistedStatements = ts.append(hoistedStatements, node); + hoistedStatements = ts.append(hoistedStatements, ts.visitEachChild(node, destructuringAndImportCallVisitor, context)); } if (hasAssociatedEndOfDeclarationMarker(node)) { // Defer exports until we encounter an EndOfDeclarationMarker node @@ -60389,7 +62460,7 @@ var ts; // Rewrite the class declaration into an assignment of a class expression. statements = ts.append(statements, ts.setTextRange(ts.createStatement(ts.createAssignment(name, ts.setTextRange(ts.createClassExpression( /*modifiers*/ undefined, node.name, - /*typeParameters*/ undefined, ts.visitNodes(node.heritageClauses, destructuringVisitor, ts.isHeritageClause), ts.visitNodes(node.members, destructuringVisitor, ts.isClassElement)), node))), node)); + /*typeParameters*/ undefined, ts.visitNodes(node.heritageClauses, destructuringAndImportCallVisitor, ts.isHeritageClause), ts.visitNodes(node.members, destructuringAndImportCallVisitor, ts.isClassElement)), node))), node)); if (hasAssociatedEndOfDeclarationMarker(node)) { // Defer exports until we encounter an EndOfDeclarationMarker node var id = ts.getOriginalNodeId(node); @@ -60408,7 +62479,7 @@ var ts; */ function visitVariableStatement(node) { if (!shouldHoistVariableDeclarationList(node.declarationList)) { - return ts.visitNode(node, destructuringVisitor, ts.isStatement); + return ts.visitNode(node, destructuringAndImportCallVisitor, ts.isStatement); } var expressions; var isExportedDeclaration = ts.hasModifier(node, 1 /* Export */); @@ -60474,9 +62545,9 @@ var ts; function transformInitializedVariable(node, isExportedDeclaration) { var createAssignment = isExportedDeclaration ? createExportedVariableAssignment : createNonExportedVariableAssignment; return ts.isBindingPattern(node.name) - ? ts.flattenDestructuringAssignment(node, destructuringVisitor, context, 0 /* All */, + ? ts.flattenDestructuringAssignment(node, destructuringAndImportCallVisitor, context, 0 /* All */, /*needsValue*/ false, createAssignment) - : createAssignment(node.name, ts.visitNode(node.initializer, destructuringVisitor, ts.isExpression)); + : createAssignment(node.name, ts.visitNode(node.initializer, destructuringAndImportCallVisitor, ts.isExpression)); } /** * Creates an assignment expression for an exported variable declaration. @@ -60798,12 +62869,12 @@ var ts; return visitCatchClause(node); case 207 /* Block */: return visitBlock(node); - case 297 /* MergeDeclarationMarker */: + case 299 /* MergeDeclarationMarker */: return visitMergeDeclarationMarker(node); - case 298 /* EndOfDeclarationMarker */: + case 300 /* EndOfDeclarationMarker */: return visitEndOfDeclarationMarker(node); default: - return destructuringVisitor(node); + return destructuringAndImportCallVisitor(node); } } /** @@ -60814,7 +62885,7 @@ var ts; function visitForStatement(node) { var savedEnclosingBlockScopedContainer = enclosingBlockScopedContainer; enclosingBlockScopedContainer = node; - node = ts.updateFor(node, visitForInitializer(node.initializer), ts.visitNode(node.condition, destructuringVisitor, ts.isExpression), ts.visitNode(node.incrementor, destructuringVisitor, ts.isExpression), ts.visitNode(node.statement, nestedElementVisitor, ts.isStatement)); + node = ts.updateFor(node, visitForInitializer(node.initializer), ts.visitNode(node.condition, destructuringAndImportCallVisitor, ts.isExpression), ts.visitNode(node.incrementor, destructuringAndImportCallVisitor, ts.isExpression), ts.visitNode(node.statement, nestedElementVisitor, ts.isStatement)); enclosingBlockScopedContainer = savedEnclosingBlockScopedContainer; return node; } @@ -60826,7 +62897,7 @@ var ts; function visitForInStatement(node) { var savedEnclosingBlockScopedContainer = enclosingBlockScopedContainer; enclosingBlockScopedContainer = node; - node = ts.updateForIn(node, visitForInitializer(node.initializer), ts.visitNode(node.expression, destructuringVisitor, ts.isExpression), ts.visitNode(node.statement, nestedElementVisitor, ts.isStatement, ts.liftToBlock)); + node = ts.updateForIn(node, visitForInitializer(node.initializer), ts.visitNode(node.expression, destructuringAndImportCallVisitor, ts.isExpression), ts.visitNode(node.statement, nestedElementVisitor, ts.isStatement, ts.liftToBlock)); enclosingBlockScopedContainer = savedEnclosingBlockScopedContainer; return node; } @@ -60838,7 +62909,7 @@ var ts; function visitForOfStatement(node) { var savedEnclosingBlockScopedContainer = enclosingBlockScopedContainer; enclosingBlockScopedContainer = node; - node = ts.updateForOf(node, node.awaitModifier, visitForInitializer(node.initializer), ts.visitNode(node.expression, destructuringVisitor, ts.isExpression), ts.visitNode(node.statement, nestedElementVisitor, ts.isStatement, ts.liftToBlock)); + node = ts.updateForOf(node, node.awaitModifier, visitForInitializer(node.initializer), ts.visitNode(node.expression, destructuringAndImportCallVisitor, ts.isExpression), ts.visitNode(node.statement, nestedElementVisitor, ts.isStatement, ts.liftToBlock)); enclosingBlockScopedContainer = savedEnclosingBlockScopedContainer; return node; } @@ -60879,7 +62950,7 @@ var ts; * @param node The node to visit. */ function visitDoStatement(node) { - return ts.updateDo(node, ts.visitNode(node.statement, nestedElementVisitor, ts.isStatement, ts.liftToBlock), ts.visitNode(node.expression, destructuringVisitor, ts.isExpression)); + return ts.updateDo(node, ts.visitNode(node.statement, nestedElementVisitor, ts.isStatement, ts.liftToBlock), ts.visitNode(node.expression, destructuringAndImportCallVisitor, ts.isExpression)); } /** * Visits the body of a WhileStatement to hoist declarations. @@ -60887,7 +62958,7 @@ var ts; * @param node The node to visit. */ function visitWhileStatement(node) { - return ts.updateWhile(node, ts.visitNode(node.expression, destructuringVisitor, ts.isExpression), ts.visitNode(node.statement, nestedElementVisitor, ts.isStatement, ts.liftToBlock)); + return ts.updateWhile(node, ts.visitNode(node.expression, destructuringAndImportCallVisitor, ts.isExpression), ts.visitNode(node.statement, nestedElementVisitor, ts.isStatement, ts.liftToBlock)); } /** * Visits the body of a LabeledStatement to hoist declarations. @@ -60903,7 +62974,7 @@ var ts; * @param node The node to visit. */ function visitWithStatement(node) { - return ts.updateWith(node, ts.visitNode(node.expression, destructuringVisitor, ts.isExpression), ts.visitNode(node.statement, nestedElementVisitor, ts.isStatement, ts.liftToBlock)); + return ts.updateWith(node, ts.visitNode(node.expression, destructuringAndImportCallVisitor, ts.isExpression), ts.visitNode(node.statement, nestedElementVisitor, ts.isStatement, ts.liftToBlock)); } /** * Visits the body of a SwitchStatement to hoist declarations. @@ -60911,7 +62982,7 @@ var ts; * @param node The node to visit. */ function visitSwitchStatement(node) { - return ts.updateSwitch(node, ts.visitNode(node.expression, destructuringVisitor, ts.isExpression), ts.visitNode(node.caseBlock, nestedElementVisitor, ts.isCaseBlock)); + return ts.updateSwitch(node, ts.visitNode(node.expression, destructuringAndImportCallVisitor, ts.isExpression), ts.visitNode(node.caseBlock, nestedElementVisitor, ts.isCaseBlock)); } /** * Visits the body of a CaseBlock to hoist declarations. @@ -60931,7 +63002,7 @@ var ts; * @param node The node to visit. */ function visitCaseClause(node) { - return ts.updateCaseClause(node, ts.visitNode(node.expression, destructuringVisitor, ts.isExpression), ts.visitNodes(node.statements, nestedElementVisitor, ts.isStatement)); + return ts.updateCaseClause(node, ts.visitNode(node.expression, destructuringAndImportCallVisitor, ts.isExpression), ts.visitNodes(node.statements, nestedElementVisitor, ts.isStatement)); } /** * Visits the body of a DefaultClause to hoist declarations. @@ -60981,18 +63052,35 @@ var ts; * * @param node The node to visit. */ - function destructuringVisitor(node) { + function destructuringAndImportCallVisitor(node) { if (node.transformFlags & 1024 /* DestructuringAssignment */ && node.kind === 194 /* BinaryExpression */) { return visitDestructuringAssignment(node); } - else if (node.transformFlags & 2048 /* ContainsDestructuringAssignment */) { - return ts.visitEachChild(node, destructuringVisitor, context); + else if (ts.isImportCall(node)) { + return visitImportCallExpression(node); + } + else if ((node.transformFlags & 2048 /* ContainsDestructuringAssignment */) || (node.transformFlags & 67108864 /* ContainsDynamicImport */)) { + return ts.visitEachChild(node, destructuringAndImportCallVisitor, context); } else { return node; } } + function visitImportCallExpression(node) { + // import("./blah") + // emit as + // System.register([], function (_export, _context) { + // return { + // setters: [], + // execute: () => { + // _context.import('./blah'); + // } + // }; + // }); + return ts.createCall(ts.createPropertyAccess(contextObject, ts.createIdentifier("import")), + /*typeArguments*/ undefined, node.arguments); + } /** * Visits a DestructuringAssignment to flatten destructuring to exported symbols. * @@ -61000,10 +63088,10 @@ var ts; */ function visitDestructuringAssignment(node) { if (hasExportedReferenceInDestructuringTarget(node.left)) { - return ts.flattenDestructuringAssignment(node, destructuringVisitor, context, 0 /* All */, + return ts.flattenDestructuringAssignment(node, destructuringAndImportCallVisitor, context, 0 /* All */, /*needsValue*/ true); } - return ts.visitEachChild(node, destructuringVisitor, context); + return ts.visitEachChild(node, destructuringAndImportCallVisitor, context); } /** * Determines whether the target of a destructuring assigment refers to an exported symbol. @@ -61014,7 +63102,7 @@ var ts; if (ts.isAssignmentExpression(node, /*excludeCompoundAssignment*/ true)) { return hasExportedReferenceInDestructuringTarget(node.left); } - else if (ts.isSpreadExpression(node)) { + else if (ts.isSpreadElement(node)) { return hasExportedReferenceInDestructuringTarget(node.expression); } else if (ts.isObjectLiteralExpression(node)) { @@ -61282,7 +63370,7 @@ var ts; var currentSourceFile; return transformSourceFile; function transformSourceFile(node) { - if (ts.isDeclarationFile(node)) { + if (node.isDeclarationFile) { return node; } if (ts.isExternalModule(node) || compilerOptions.isolatedModules) { @@ -61381,6 +63469,7 @@ var ts; (function (ts) { function getModuleTransformer(moduleKind) { switch (moduleKind) { + case ts.ModuleKind.ESNext: case ts.ModuleKind.ES2015: return ts.transformES2015Module; case ts.ModuleKind.System: @@ -61445,7 +63534,7 @@ var ts; * @param allowDtsFiles A value indicating whether to allow the transformation of .d.ts files. */ function transformNodes(resolver, host, options, nodes, transformers, allowDtsFiles) { - var enabledSyntaxKindFeatures = new Array(299 /* Count */); + var enabledSyntaxKindFeatures = new Array(301 /* Count */); var lexicalEnvironmentVariableDeclarations; var lexicalEnvironmentFunctionDeclarations; var lexicalEnvironmentVariableDeclarationsStack = []; @@ -61510,7 +63599,7 @@ var ts; dispose: dispose }; function transformRoot(node) { - return node && (!ts.isSourceFile(node) || !ts.isDeclarationFile(node)) ? transformation(node) : node; + return node && (!ts.isSourceFile(node) || !node.isDeclarationFile) ? transformation(node) : node; } /** * Enables expression substitutions in the pretty printer for the provided SyntaxKind. @@ -61576,7 +63665,7 @@ var ts; function hoistVariableDeclaration(name) { ts.Debug.assert(state > 0 /* Uninitialized */, "Cannot modify the lexical environment during initialization."); ts.Debug.assert(state < 2 /* Completed */, "Cannot modify the lexical environment after transformation has completed."); - var decl = ts.createVariableDeclaration(name); + var decl = ts.setEmitFlags(ts.createVariableDeclaration(name), 64 /* NoNestedSourceMaps */); if (!lexicalEnvironmentVariableDeclarations) { lexicalEnvironmentVariableDeclarations = [decl]; } @@ -61713,7 +63802,7 @@ var ts; function createSourceMapWriter(host, writer) { var compilerOptions = host.getCompilerOptions(); var extendedDiagnostics = compilerOptions.extendedDiagnostics; - var currentSourceFile; + var currentSource; var currentSourceText; var sourceMapDir; // The directory in which sourcemap will be // Current source map file and its index in the sources list @@ -61736,6 +63825,12 @@ var ts; getText: getText, getSourceMappingURL: getSourceMappingURL, }; + /** + * Skips trivia such as comments and white-space that can optionally overriden by the source map source + */ + function skipSourceTrivia(pos) { + return currentSource.skipTrivia ? currentSource.skipTrivia(pos) : ts.skipTrivia(currentSourceText, pos); + } /** * Initialize the SourceMapWriter for a new output file. * @@ -61750,7 +63845,7 @@ var ts; if (sourceMapData) { reset(); } - currentSourceFile = undefined; + currentSource = undefined; currentSourceText = undefined; // Current source map file and its index in the sources list sourceMapSourceIndex = -1; @@ -61807,7 +63902,7 @@ var ts; if (disabled) { return; } - currentSourceFile = undefined; + currentSource = undefined; sourceMapDir = undefined; sourceMapSourceIndex = undefined; lastRecordedSourceMapSpan = undefined; @@ -61867,7 +63962,7 @@ var ts; if (extendedDiagnostics) { ts.performance.mark("beforeSourcemap"); } - var sourceLinePos = ts.getLineAndCharacterOfPosition(currentSourceFile, pos); + var sourceLinePos = ts.getLineAndCharacterOfPosition(currentSource, pos); // Convert the location to be one-based. sourceLinePos.line++; sourceLinePos.character++; @@ -61916,12 +64011,21 @@ var ts; if (node) { var emitNode = node.emitNode; var emitFlags = emitNode && emitNode.flags; - var _a = emitNode && emitNode.sourceMapRange || node, pos = _a.pos, end = _a.end; - if (node.kind !== 295 /* NotEmittedStatement */ + var range = emitNode && emitNode.sourceMapRange; + var _a = range || node, pos = _a.pos, end = _a.end; + var source = range && range.source; + var oldSource = currentSource; + if (source === oldSource) + source = undefined; + if (source) + setSourceFile(source); + if (node.kind !== 296 /* NotEmittedStatement */ && (emitFlags & 16 /* NoLeadingSourceMap */) === 0 && pos >= 0) { - emitPos(ts.skipTrivia(currentSourceText, pos)); + emitPos(skipSourceTrivia(pos)); } + if (source) + setSourceFile(oldSource); if (emitFlags & 64 /* NoNestedSourceMaps */) { disabled = true; emitCallback(hint, node); @@ -61930,11 +64034,15 @@ var ts; else { emitCallback(hint, node); } - if (node.kind !== 295 /* NotEmittedStatement */ + if (source) + setSourceFile(source); + if (node.kind !== 296 /* NotEmittedStatement */ && (emitFlags & 32 /* NoTrailingSourceMap */) === 0 && end >= 0) { emitPos(end); } + if (source) + setSourceFile(oldSource); } } /** @@ -61952,7 +64060,7 @@ var ts; var emitNode = node && node.emitNode; var emitFlags = emitNode && emitNode.flags; var range = emitNode && emitNode.tokenSourceMapRanges && emitNode.tokenSourceMapRanges[token]; - tokenPos = ts.skipTrivia(currentSourceText, range ? range.pos : tokenPos); + tokenPos = skipSourceTrivia(range ? range.pos : tokenPos); if ((emitFlags & 128 /* NoTokenLeadingSourceMaps */) === 0 && tokenPos >= 0) { emitPos(tokenPos); } @@ -61973,22 +64081,22 @@ var ts; if (disabled) { return; } - currentSourceFile = sourceFile; - currentSourceText = currentSourceFile.text; + currentSource = sourceFile; + currentSourceText = currentSource.text; // Add the file to tsFilePaths // If sourceroot option: Use the relative path corresponding to the common directory path // otherwise source locations relative to map file location var sourcesDirectoryPath = compilerOptions.sourceRoot ? host.getCommonSourceDirectory() : sourceMapDir; - var source = ts.getRelativePathToDirectoryOrUrl(sourcesDirectoryPath, currentSourceFile.fileName, host.getCurrentDirectory(), host.getCanonicalFileName, + var source = ts.getRelativePathToDirectoryOrUrl(sourcesDirectoryPath, currentSource.fileName, host.getCurrentDirectory(), host.getCanonicalFileName, /*isAbsolutePathAnUrl*/ true); sourceMapSourceIndex = ts.indexOf(sourceMapData.sourceMapSources, source); if (sourceMapSourceIndex === -1) { sourceMapSourceIndex = sourceMapData.sourceMapSources.length; sourceMapData.sourceMapSources.push(source); // The one that can be used from program to get the actual source file - sourceMapData.inputSourceFileNames.push(currentSourceFile.fileName); + sourceMapData.inputSourceFileNames.push(currentSource.fileName); if (compilerOptions.inlineSources) { - sourceMapData.sourceMapSourcesContent.push(currentSourceFile.text); + sourceMapData.sourceMapSourcesContent.push(currentSource.text); } } } @@ -62105,9 +64213,11 @@ var ts; if (extendedDiagnostics) { ts.performance.mark("preEmitNodeWithComment"); } - var isEmittedNode = node.kind !== 295 /* NotEmittedStatement */; - var skipLeadingComments = pos < 0 || (emitFlags & 512 /* NoLeadingComments */) !== 0; - var skipTrailingComments = end < 0 || (emitFlags & 1024 /* NoTrailingComments */) !== 0; + var isEmittedNode = node.kind !== 296 /* NotEmittedStatement */; + // We have to explicitly check that the node is JsxText because if the compilerOptions.jsx is "preserve" we will not do any transformation. + // It is expensive to walk entire tree just to set one kind of node to have no comments. + var skipLeadingComments = pos < 0 || (emitFlags & 512 /* NoLeadingComments */) !== 0 || node.kind === 10 /* JsxText */; + var skipTrailingComments = end < 0 || (emitFlags & 1024 /* NoTrailingComments */) !== 0 || node.kind === 10 /* JsxText */; // Emit leading comments if the position is not synthesized and the node // has not opted out from emitting leading comments. if (!skipLeadingComments) { @@ -62566,7 +64676,7 @@ var ts; var writer = ts.createTextWriter(newLine); writer.trackSymbol = trackSymbol; writer.reportInaccessibleThisError = reportInaccessibleThisError; - writer.reportIllegalExtends = reportIllegalExtends; + writer.reportPrivateInBaseOfClassExpression = reportPrivateInBaseOfClassExpression; writer.writeKeyword = writer.write; writer.writeOperator = writer.write; writer.writePunctuation = writer.write; @@ -62674,10 +64784,10 @@ var ts; handleSymbolAccessibilityError(resolver.isSymbolAccessible(symbol, enclosingDeclaration, meaning, /*shouldComputeAliasesToMakeVisible*/ true)); recordTypeReferenceDirectivesIfNecessary(resolver.getTypeReferenceDirectivesForSymbol(symbol, meaning)); } - function reportIllegalExtends() { + function reportPrivateInBaseOfClassExpression(propertyName) { if (errorNameNode) { reportedDeclarationError = true; - emitterDiagnostics.add(ts.createDiagnosticForNode(errorNameNode, ts.Diagnostics.extends_clause_of_exported_class_0_refers_to_a_type_whose_name_cannot_be_referenced, ts.declarationNameToString(errorNameNode))); + emitterDiagnostics.add(ts.createDiagnosticForNode(errorNameNode, ts.Diagnostics.Property_0_of_exported_class_expression_may_not_be_private_or_protected, propertyName)); } } function reportInaccessibleThisError() { @@ -62690,17 +64800,22 @@ var ts; writer.getSymbolAccessibilityDiagnostic = getSymbolAccessibilityDiagnostic; write(": "); // use the checker's type, not the declared type, - // for non-optional initialized parameters that aren't a parameter property + // for optional parameter properties + // and also for non-optional initialized parameters that aren't a parameter property + // these types may need to add `undefined`. var shouldUseResolverType = declaration.kind === 146 /* Parameter */ && - resolver.isRequiredInitializedParameter(declaration); + (resolver.isRequiredInitializedParameter(declaration) || + resolver.isOptionalUninitializedParameterProperty(declaration)); if (type && !shouldUseResolverType) { // Write the type emitType(type); } else { errorNameNode = declaration.name; - var format = 2 /* UseTypeOfFunction */ | 1024 /* UseTypeAliasValue */ | - (shouldUseResolverType ? 4096 /* AddUndefined */ : 0); + var format = 4 /* UseTypeOfFunction */ | + 16384 /* WriteClassExpressionAsTypeLiteral */ | + 2048 /* UseTypeAliasValue */ | + (shouldUseResolverType ? 8192 /* AddUndefined */ : 0); resolver.writeTypeOfDeclaration(declaration, enclosingDeclaration, format, writer); errorNameNode = undefined; } @@ -62714,7 +64829,7 @@ var ts; } else { errorNameNode = signature.name; - resolver.writeReturnTypeOfSignatureDeclaration(signature, enclosingDeclaration, 2 /* UseTypeOfFunction */ | 1024 /* UseTypeAliasValue */, writer); + resolver.writeReturnTypeOfSignatureDeclaration(signature, enclosingDeclaration, 4 /* UseTypeOfFunction */ | 2048 /* UseTypeAliasValue */ | 16384 /* WriteClassExpressionAsTypeLiteral */, writer); errorNameNode = undefined; } } @@ -62923,7 +65038,7 @@ var ts; currentIdentifiers = node.identifiers; isCurrentFileExternalModule = ts.isExternalModule(node); enclosingDeclaration = node; - ts.emitDetachedComments(currentText, currentLineMap, writer, ts.writeCommentRange, node, newLine, /*removeComents*/ true); + ts.emitDetachedComments(currentText, currentLineMap, writer, ts.writeCommentRange, node, newLine, /*removeComments*/ true); emitLines(node.statements); } // Return a temp variable name to be used in `export default`/`export class ... extends` statements. @@ -62952,7 +65067,7 @@ var ts; write(tempVarName); write(": "); writer.getSymbolAccessibilityDiagnostic = function () { return diagnostic; }; - resolver.writeTypeOfExpression(expr, enclosingDeclaration, 2 /* UseTypeOfFunction */ | 1024 /* UseTypeAliasValue */, writer); + resolver.writeTypeOfExpression(expr, enclosingDeclaration, 4 /* UseTypeOfFunction */ | 2048 /* UseTypeAliasValue */ | 16384 /* WriteClassExpressionAsTypeLiteral */, writer); write(";"); writeLine(); return tempVarName; @@ -63287,7 +65402,7 @@ var ts; var enumMemberValue = resolver.getConstantValue(node); if (enumMemberValue !== undefined) { write(" = "); - write(enumMemberValue.toString()); + write(ts.getTextOfConstantValue(enumMemberValue)); } write(","); writeLine(); @@ -63544,7 +65659,8 @@ var ts; ts.Diagnostics.Exported_variable_0_has_or_is_using_name_1_from_private_module_2 : ts.Diagnostics.Exported_variable_0_has_or_is_using_private_name_1; } - else if (node.kind === 149 /* PropertyDeclaration */ || node.kind === 148 /* PropertySignature */) { + else if (node.kind === 149 /* PropertyDeclaration */ || node.kind === 148 /* PropertySignature */ || + (node.kind === 146 /* Parameter */ && ts.hasModifier(node.parent, 8 /* Private */))) { // TODO(jfreeman): Deal with computed properties in error reporting. if (ts.hasModifier(node, 32 /* Static */)) { return symbolAccessibilityResult.errorModuleName ? @@ -63553,7 +65669,7 @@ var ts; ts.Diagnostics.Public_static_property_0_of_exported_class_has_or_is_using_name_1_from_private_module_2 : ts.Diagnostics.Public_static_property_0_of_exported_class_has_or_is_using_private_name_1; } - else if (node.parent.kind === 229 /* ClassDeclaration */) { + else if (node.parent.kind === 229 /* ClassDeclaration */ || node.kind === 146 /* Parameter */) { return symbolAccessibilityResult.errorModuleName ? symbolAccessibilityResult.accessibility === 2 /* CannotBeNamed */ ? ts.Diagnostics.Public_property_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named : @@ -63763,6 +65879,11 @@ var ts; write("["); } else { + if (node.kind === 152 /* Constructor */ && ts.hasModifier(node, 8 /* Private */)) { + write("();"); + writeLine(); + return; + } // Construct signature or constructor type write new Signature if (node.kind === 156 /* ConstructSignature */ || node.kind === 161 /* ConstructorType */) { write("new "); @@ -64069,7 +66190,7 @@ var ts; function writeReferencePath(referencedFile, addBundledFileReference, emitOnlyDtsFiles) { var declFileName; var addedBundledEmitReference = false; - if (ts.isDeclarationFile(referencedFile)) { + if (referencedFile.isDeclarationFile) { // Declaration file, use declaration file name declFileName = referencedFile.fileName; } @@ -64253,7 +66374,7 @@ var ts; for (var i = 0; i < numNodes; i++) { var currentNode = bundle ? bundle.sourceFiles[i] : node; var sourceFile = ts.isSourceFile(currentNode) ? currentNode : currentSourceFile; - var shouldSkip = compilerOptions.noEmitHelpers || (sourceFile && ts.getExternalHelpersModuleName(sourceFile) !== undefined); + var shouldSkip = compilerOptions.noEmitHelpers || ts.getExternalHelpersModuleName(sourceFile) !== undefined; var shouldBundle = ts.isSourceFile(currentNode) && !isOwnFileEmit; var helpers = ts.getEmitHelpers(currentNode); if (helpers) { @@ -64290,7 +66411,7 @@ var ts; function createPrinter(printerOptions, handlers) { if (printerOptions === void 0) { printerOptions = {}; } if (handlers === void 0) { handlers = {}; } - var hasGlobalName = handlers.hasGlobalName, onEmitSourceMapOfNode = handlers.onEmitSourceMapOfNode, onEmitSourceMapOfToken = handlers.onEmitSourceMapOfToken, onEmitSourceMapOfPosition = handlers.onEmitSourceMapOfPosition, onEmitNode = handlers.onEmitNode, onEmitHelpers = handlers.onEmitHelpers, onSetSourceFile = handlers.onSetSourceFile, substituteNode = handlers.substituteNode, onBeforeEmitNodeArray = handlers.onBeforeEmitNodeArray, onAfterEmitNodeArray = handlers.onAfterEmitNodeArray; + var hasGlobalName = handlers.hasGlobalName, onEmitSourceMapOfNode = handlers.onEmitSourceMapOfNode, onEmitSourceMapOfToken = handlers.onEmitSourceMapOfToken, onEmitSourceMapOfPosition = handlers.onEmitSourceMapOfPosition, onEmitNode = handlers.onEmitNode, onEmitHelpers = handlers.onEmitHelpers, onSetSourceFile = handlers.onSetSourceFile, substituteNode = handlers.substituteNode, onBeforeEmitNodeArray = handlers.onBeforeEmitNodeArray, onAfterEmitNodeArray = handlers.onAfterEmitNodeArray, onBeforeEmitToken = handlers.onBeforeEmitToken, onAfterEmitToken = handlers.onAfterEmitToken; var newLine = ts.getNewLineCharacter(printerOptions); var comments = ts.createCommentWriter(printerOptions, onEmitSourceMapOfPosition); var emitNodeWithComments = comments.emitNodeWithComments, emitBodyWithDetachedComments = comments.emitBodyWithDetachedComments, emitTrailingCommentsOfPosition = comments.emitTrailingCommentsOfPosition, emitLeadingCommentsOfPosition = comments.emitLeadingCommentsOfPosition; @@ -64378,7 +66499,9 @@ var ts; return text; } function print(hint, node, sourceFile) { - setSourceFile(sourceFile); + if (sourceFile) { + setSourceFile(sourceFile); + } pipelineEmitWithNotification(hint, node); } function setSourceFile(sourceFile) { @@ -64457,7 +66580,7 @@ var ts; // Strict mode reserved words // Contextual keywords if (ts.isKeyword(kind)) { - writeTokenText(kind); + writeTokenNode(node); return; } switch (kind) { @@ -64609,6 +66732,8 @@ var ts; return emitModuleBlock(node); case 235 /* CaseBlock */: return emitCaseBlock(node); + case 236 /* NamespaceExportDeclaration */: + return emitNamespaceExportDeclaration(node); case 237 /* ImportEqualsDeclaration */: return emitImportEqualsDeclaration(node); case 238 /* ImportDeclaration */: @@ -64675,7 +66800,7 @@ var ts; return pipelineEmitExpression(trySubstituteNode(1 /* Expression */, node)); } if (ts.isToken(node)) { - writeTokenText(kind); + writeTokenNode(node); return; } } @@ -64698,7 +66823,8 @@ var ts; case 97 /* SuperKeyword */: case 101 /* TrueKeyword */: case 99 /* ThisKeyword */: - writeTokenText(kind); + case 91 /* ImportKeyword */: + writeTokenNode(node); return; // Expressions case 177 /* ArrayLiteralExpression */: @@ -64761,8 +66887,10 @@ var ts; case 250 /* JsxSelfClosingElement */: return emitJsxSelfClosingElement(node); // Transformation nodes - case 296 /* PartiallyEmittedExpression */: + case 297 /* PartiallyEmittedExpression */: return emitPartiallyEmittedExpression(node); + case 298 /* CommaListExpression */: + return emitCommaList(node); } } function trySubstituteNode(hint, node) { @@ -64801,6 +66929,7 @@ var ts; // function emitIdentifier(node) { write(getTextOfNode(node, /*includeTrivia*/ false)); + emitTypeArguments(node, node.typeArguments); } // // Names @@ -64829,6 +66958,7 @@ var ts; function emitTypeParameter(node) { emit(node.name); emitWithPrefix(" extends ", node.constraint); + emitWithPrefix(" = ", node.default); } function emitParameter(node) { emitDecorators(node, node.decorators); @@ -64858,6 +66988,7 @@ var ts; emitDecorators(node, node.decorators); emitModifiers(node, node.modifiers); emit(node.name); + writeIfPresent(node.questionToken, "?"); emitWithPrefix(": ", node.type); emitExpressionWithPrefix(" = ", node.initializer); write(";"); @@ -64877,6 +67008,7 @@ var ts; emitModifiers(node, node.modifiers); writeIfPresent(node.asteriskToken, "*"); emit(node.name); + writeIfPresent(node.questionToken, "?"); emitSignatureAndBody(node, emitSignatureHead); } function emitConstructor(node) { @@ -64939,7 +67071,7 @@ var ts; function emitConstructorType(node) { write("new "); emitTypeParameters(node, node.typeParameters); - emitParametersForArrow(node, node.parameters); + emitParameters(node, node.parameters); write(" => "); emit(node.type); } @@ -64949,7 +67081,10 @@ var ts; } function emitTypeLiteral(node) { write("{"); - emitList(node, node.members, 65 /* TypeLiteralMembers */); + // If the literal is empty, do not add spaces between braces. + if (node.members.length > 0) { + emitList(node, node.members, ts.getEmitFlags(node) & 1 /* SingleLine */ ? 448 /* SingleLineTypeLiteralMembers */ : 65 /* MultiLineTypeLiteralMembers */); + } write("}"); } function emitArrayType(node) { @@ -64987,9 +67122,15 @@ var ts; write("]"); } function emitMappedType(node) { + var emitFlags = ts.getEmitFlags(node); write("{"); - writeLine(); - increaseIndent(); + if (emitFlags & 1 /* SingleLine */) { + write(" "); + } + else { + writeLine(); + increaseIndent(); + } writeIfPresent(node.readonlyToken, "readonly "); write("["); emit(node.typeParameter.name); @@ -65000,8 +67141,13 @@ var ts; write(": "); emit(node.type); write(";"); - writeLine(); - decreaseIndent(); + if (emitFlags & 1 /* SingleLine */) { + write(" "); + } + else { + writeLine(); + decreaseIndent(); + } write("}"); } function emitLiteralType(node) { @@ -65101,7 +67247,7 @@ var ts; // check if constant enum value is integer var constantValue = ts.getConstantValue(expression); // isFinite handles cases when constantValue is undefined - return isFinite(constantValue) + return typeof constantValue === "number" && isFinite(constantValue) && Math.floor(constantValue) === constantValue && printerOptions.removeComments; } @@ -65204,7 +67350,7 @@ var ts; var indentAfterOperator = needsIndentation(node, node.operatorToken, node.right); emitExpression(node.left); increaseIndentIf(indentBeforeOperator, isCommaOperator ? " " : undefined); - writeTokenText(node.operatorToken.kind); + writeTokenNode(node.operatorToken); increaseIndentIf(indentAfterOperator, " "); emitExpression(node.right); decreaseIndentIf(indentBeforeOperator, indentAfterOperator); @@ -65726,6 +67872,11 @@ var ts; } write(";"); } + function emitNamespaceExportDeclaration(node) { + write("export as namespace "); + emit(node.name); + write(";"); + } function emitNamedExports(node) { emitNamedImportsOrExports(node); } @@ -65838,6 +67989,21 @@ var ts; ts.nodeIsSynthesized(parentNode) || ts.nodeIsSynthesized(statements[0]) || ts.rangeStartPositionsAreOnSameLine(parentNode, statements[0], currentSourceFile)); + // e.g: + // case 0: // Zero + // case 1: // One + // case 2: // two + // return "hi"; + // If there is no statements, emitNodeWithComments of the parentNode which is caseClause will take care of trailing comment. + // So in example above, comment "// Zero" and "// One" will be emit in emitTrailingComments in emitNodeWithComments. + // However, for "case 2", because parentNode which is caseClause has an "end" property to be end of the statements (in this case return statement) + // comment "// two" will not be emitted in emitNodeWithComments. + // Therefore, we have to do the check here to emit such comment. + if (statements.length > 0) { + // We use emitTrailingCommentsOfPosition instead of emitLeadingCommentsOfPosition because leading comments is defined as comments before the node after newline character separating it from previous line + // Note: we can't use parentNode.end as such position includes statements. + emitTrailingCommentsOfPosition(statements.pos); + } if (emitAsSingleStatement) { write(" "); emit(statements[0]); @@ -65932,6 +68098,9 @@ var ts; function emitPartiallyEmittedExpression(node) { emitExpression(node.expression); } + function emitCommaList(node) { + emitExpressionList(node, node.elements, 272 /* CommaListElements */); + } /** * Emits any prologue directives at the start of a Statement list, returning the * number of prologue directives written to the output. @@ -65996,7 +68165,7 @@ var ts; // function emitModifiers(node, modifiers) { if (modifiers && modifiers.length) { - emitList(node, modifiers, 256 /* Modifiers */); + emitList(node, modifiers, 131328 /* Modifiers */); write(" "); } } @@ -66042,11 +68211,24 @@ var ts; function emitParameters(parentNode, parameters) { emitList(parentNode, parameters, 1360 /* Parameters */); } + function canEmitSimpleArrowHead(parentNode, parameters) { + var parameter = ts.singleOrUndefined(parameters); + return parameter + && parameter.pos === parentNode.pos // may not have parsed tokens between parent and parameter + && !(ts.isArrowFunction(parentNode) && parentNode.type) // arrow function may not have return type annotation + && !ts.some(parentNode.decorators) // parent may not have decorators + && !ts.some(parentNode.modifiers) // parent may not have modifiers + && !ts.some(parentNode.typeParameters) // parent may not have type parameters + && !ts.some(parameter.decorators) // parameter may not have decorators + && !ts.some(parameter.modifiers) // parameter may not have modifiers + && !parameter.dotDotDotToken // parameter may not be rest + && !parameter.questionToken // parameter may not be optional + && !parameter.type // parameter may not have a type annotation + && !parameter.initializer // parameter may not have an initializer + && ts.isIdentifier(parameter.name); // parameter name must be identifier + } function emitParametersForArrow(parentNode, parameters) { - if (parameters && - parameters.length === 1 && - parameters[0].type === undefined && - parameters[0].pos === parentNode.pos) { + if (canEmitSimpleArrowHead(parentNode, parameters)) { emit(parameters[0]); } else { @@ -66213,6 +68395,15 @@ var ts; ? onEmitSourceMapOfToken(contextNode, token, pos, writeTokenText) : writeTokenText(token, pos); } + function writeTokenNode(node) { + if (onBeforeEmitToken) { + onBeforeEmitToken(node); + } + writeTokenText(node.kind); + if (onAfterEmitToken) { + onAfterEmitToken(node); + } + } function writeTokenText(token, pos) { var tokenString = ts.tokenToString(token); write(tokenString); @@ -66395,7 +68586,9 @@ var ts; if (node.kind === 9 /* StringLiteral */ && node.textSourceNode) { var textSourceNode = node.textSourceNode; if (ts.isIdentifier(textSourceNode)) { - return "\"" + ts.escapeNonAsciiCharacters(ts.escapeString(getTextOfNode(textSourceNode))) + "\""; + return ts.getEmitFlags(node) & 16777216 /* NoAsciiEscaping */ ? + "\"" + ts.escapeString(getTextOfNode(textSourceNode)) + "\"" : + "\"" + ts.escapeNonAsciiString(getTextOfNode(textSourceNode)) + "\""; } else { return getLiteralTextOfNode(textSourceNode); @@ -66673,9 +68866,10 @@ var ts; ListFormat[ListFormat["NoTrailingNewLine"] = 65536] = "NoTrailingNewLine"; ListFormat[ListFormat["NoInterveningComments"] = 131072] = "NoInterveningComments"; // Precomputed Formats - ListFormat[ListFormat["Modifiers"] = 256] = "Modifiers"; + ListFormat[ListFormat["Modifiers"] = 131328] = "Modifiers"; ListFormat[ListFormat["HeritageClauses"] = 256] = "HeritageClauses"; - ListFormat[ListFormat["TypeLiteralMembers"] = 65] = "TypeLiteralMembers"; + ListFormat[ListFormat["SingleLineTypeLiteralMembers"] = 448] = "SingleLineTypeLiteralMembers"; + ListFormat[ListFormat["MultiLineTypeLiteralMembers"] = 65] = "MultiLineTypeLiteralMembers"; ListFormat[ListFormat["TupleTypeElements"] = 336] = "TupleTypeElements"; ListFormat[ListFormat["UnionTypeConstituents"] = 260] = "UnionTypeConstituents"; ListFormat[ListFormat["IntersectionTypeConstituents"] = 264] = "IntersectionTypeConstituents"; @@ -66683,6 +68877,7 @@ var ts; ListFormat[ListFormat["ArrayBindingPatternElements"] = 304] = "ArrayBindingPatternElements"; ListFormat[ListFormat["ObjectLiteralExpressionProperties"] = 978] = "ObjectLiteralExpressionProperties"; ListFormat[ListFormat["ArrayLiteralExpressionElements"] = 4466] = "ArrayLiteralExpressionElements"; + ListFormat[ListFormat["CommaListElements"] = 272] = "CommaListElements"; ListFormat[ListFormat["CallExpressionArguments"] = 1296] = "CallExpressionArguments"; ListFormat[ListFormat["NewExpressionArguments"] = 9488] = "NewExpressionArguments"; ListFormat[ListFormat["TemplateExpressionSpans"] = 131072] = "TemplateExpressionSpans"; @@ -66909,6 +69104,90 @@ var ts; return output; } ts.formatDiagnostics = formatDiagnostics; + var redForegroundEscapeSequence = "\u001b[91m"; + var yellowForegroundEscapeSequence = "\u001b[93m"; + var blueForegroundEscapeSequence = "\u001b[93m"; + var gutterStyleSequence = "\u001b[100;30m"; + var gutterSeparator = " "; + var resetEscapeSequence = "\u001b[0m"; + var ellipsis = "..."; + function getCategoryFormat(category) { + switch (category) { + case ts.DiagnosticCategory.Warning: return yellowForegroundEscapeSequence; + case ts.DiagnosticCategory.Error: return redForegroundEscapeSequence; + case ts.DiagnosticCategory.Message: return blueForegroundEscapeSequence; + } + } + function formatAndReset(text, formatStyle) { + return formatStyle + text + resetEscapeSequence; + } + function padLeft(s, length) { + while (s.length < length) { + s = " " + s; + } + return s; + } + function formatDiagnosticsWithColorAndContext(diagnostics, host) { + var output = ""; + for (var _i = 0, diagnostics_2 = diagnostics; _i < diagnostics_2.length; _i++) { + var diagnostic = diagnostics_2[_i]; + if (diagnostic.file) { + var start = diagnostic.start, length_5 = diagnostic.length, file = diagnostic.file; + var _a = ts.getLineAndCharacterOfPosition(file, start), firstLine = _a.line, firstLineChar = _a.character; + var _b = ts.getLineAndCharacterOfPosition(file, start + length_5), lastLine = _b.line, lastLineChar = _b.character; + var lastLineInFile = ts.getLineAndCharacterOfPosition(file, file.text.length).line; + var relativeFileName = host ? ts.convertToRelativePath(file.fileName, host.getCurrentDirectory(), function (fileName) { return host.getCanonicalFileName(fileName); }) : file.fileName; + var hasMoreThanFiveLines = (lastLine - firstLine) >= 4; + var gutterWidth = (lastLine + 1 + "").length; + if (hasMoreThanFiveLines) { + gutterWidth = Math.max(ellipsis.length, gutterWidth); + } + output += ts.sys.newLine; + for (var i = firstLine; i <= lastLine; i++) { + // If the error spans over 5 lines, we'll only show the first 2 and last 2 lines, + // so we'll skip ahead to the second-to-last line. + if (hasMoreThanFiveLines && firstLine + 1 < i && i < lastLine - 1) { + output += formatAndReset(padLeft(ellipsis, gutterWidth), gutterStyleSequence) + gutterSeparator + ts.sys.newLine; + i = lastLine - 1; + } + var lineStart = ts.getPositionOfLineAndCharacter(file, i, 0); + var lineEnd = i < lastLineInFile ? ts.getPositionOfLineAndCharacter(file, i + 1, 0) : file.text.length; + var lineContent = file.text.slice(lineStart, lineEnd); + lineContent = lineContent.replace(/\s+$/g, ""); // trim from end + lineContent = lineContent.replace("\t", " "); // convert tabs to single spaces + // Output the gutter and the actual contents of the line. + output += formatAndReset(padLeft(i + 1 + "", gutterWidth), gutterStyleSequence) + gutterSeparator; + output += lineContent + ts.sys.newLine; + // Output the gutter and the error span for the line using tildes. + output += formatAndReset(padLeft("", gutterWidth), gutterStyleSequence) + gutterSeparator; + output += redForegroundEscapeSequence; + if (i === firstLine) { + // If we're on the last line, then limit it to the last character of the last line. + // Otherwise, we'll just squiggle the rest of the line, giving 'slice' no end position. + var lastCharForLine = i === lastLine ? lastLineChar : undefined; + output += lineContent.slice(0, firstLineChar).replace(/\S/g, " "); + output += lineContent.slice(firstLineChar, lastCharForLine).replace(/./g, "~"); + } + else if (i === lastLine) { + output += lineContent.slice(0, lastLineChar).replace(/./g, "~"); + } + else { + // Squiggle the entire line. + output += lineContent.replace(/./g, "~"); + } + output += resetEscapeSequence; + output += ts.sys.newLine; + } + output += ts.sys.newLine; + output += relativeFileName + "(" + (firstLine + 1) + "," + (firstLineChar + 1) + "): "; + } + var categoryColor = getCategoryFormat(diagnostic.category); + var category = ts.DiagnosticCategory[diagnostic.category].toLowerCase(); + output += formatAndReset(category, categoryColor) + " TS" + diagnostic.code + ": " + flattenDiagnosticMessageText(diagnostic.messageText, ts.sys.newLine); + } + return output; + } + ts.formatDiagnosticsWithColorAndContext = formatDiagnosticsWithColorAndContext; function flattenDiagnosticMessageText(messageText, newLine) { if (typeof messageText === "string") { return messageText; @@ -66951,6 +69230,19 @@ var ts; } return resolutions; } + /** + * Create a new 'Program' instance. A Program is an immutable collection of 'SourceFile's and a 'CompilerOptions' + * that represent a compilation unit. + * + * Creating a program proceeds from a set of root files, expanding the set of inputs by following imports and + * triple-slash-reference-path directives transitively. '@types' and triple-slash-reference-types are also pulled in. + * + * @param rootNames - A set of root files. + * @param options - The compiler options which should be used. + * @param host - The host interacts with the underlying file system. + * @param oldProgram - Reuses an old program structure. + * @returns A 'Program' object. + */ function createProgram(rootNames, options, host, oldProgram) { var program; var files = []; @@ -66958,6 +69250,7 @@ var ts; var diagnosticsProducingTypeChecker; var noDiagnosticsTypeChecker; var classifiableNames; + var modifiedFilePaths; var cachedSemanticDiagnosticsForFile = {}; var cachedDeclarationDiagnosticsForFile = {}; var resolvedTypeReferenceDirectives = ts.createMap(); @@ -67014,7 +69307,8 @@ var ts; // stores 'filename -> file association' ignoring case // used to track cases when two file names differ only in casing var filesByNameIgnoreCase = host.useCaseSensitiveFileNames() ? ts.createFileMap(function (fileName) { return fileName.toLowerCase(); }) : undefined; - if (!tryReuseStructureFromOldProgram()) { + var structuralIsReused = tryReuseStructureFromOldProgram(); + if (structuralIsReused !== 2 /* Completely */) { ts.forEach(rootNames, function (name) { return processRootFile(name, /*isDefaultLib*/ false); }); // load type declarations specified via 'types' argument or implicitly from types/ and node_modules/@types folders var typeReferences = ts.getAutomaticTypeDirectiveNames(options, host); @@ -67073,7 +69367,8 @@ var ts; getFileProcessingDiagnostics: function () { return fileProcessingDiagnostics; }, getResolvedTypeReferenceDirectives: function () { return resolvedTypeReferenceDirectives; }, isSourceFileFromExternalLibrary: isSourceFileFromExternalLibrary, - dropDiagnosticsProducingTypeChecker: dropDiagnosticsProducingTypeChecker + dropDiagnosticsProducingTypeChecker: dropDiagnosticsProducingTypeChecker, + getSourceFileFromReference: getSourceFileFromReference, }; verifyCompilerOptions(); ts.performance.mark("afterProgram"); @@ -67111,76 +69406,100 @@ var ts; return classifiableNames; } function resolveModuleNamesReusingOldState(moduleNames, containingFile, file, oldProgramState) { - if (!oldProgramState && !file.ambientModuleNames.length) { - // if old program state is not supplied and file does not contain locally defined ambient modules - // then the best we can do is fallback to the default logic + if (structuralIsReused === 0 /* Not */ && !file.ambientModuleNames.length) { + // If the old program state does not permit reusing resolutions and `file` does not contain locally defined ambient modules, + // the best we can do is fallback to the default logic. return resolveModuleNamesWorker(moduleNames, containingFile); } - // at this point we know that either + var oldSourceFile = oldProgramState.program && oldProgramState.program.getSourceFile(containingFile); + if (oldSourceFile !== file && file.resolvedModules) { + // `file` was created for the new program. + // + // We only set `file.resolvedModules` via work from the current function, + // so it is defined iff we already called the current function on `file`. + // That call happened no later than the creation of the `file` object, + // which per above occured during the current program creation. + // Since we assume the filesystem does not change during program creation, + // it is safe to reuse resolutions from the earlier call. + var result_4 = []; + for (var _i = 0, moduleNames_1 = moduleNames; _i < moduleNames_1.length; _i++) { + var moduleName = moduleNames_1[_i]; + var resolvedModule = file.resolvedModules.get(moduleName); + result_4.push(resolvedModule); + } + return result_4; + } + // At this point, we know at least one of the following hold: // - file has local declarations for ambient modules - // OR // - old program state is available - // OR - // - both of items above - // With this it is possible that we can tell how some module names from the initial list will be resolved - // without doing actual resolution (in particular if some name was resolved to ambient module). - // Such names should be excluded from the list of module names that will be provided to `resolveModuleNamesWorker` - // since we don't want to resolve them again. - // this is a list of modules for which we cannot predict resolution so they should be actually resolved + // With this information, we can infer some module resolutions without performing resolution. + /** An ordered list of module names for which we cannot recover the resolution. */ var unknownModuleNames; - // this is a list of combined results assembles from predicted and resolved results. - // Order in this list matches the order in the original list of module names `moduleNames` which is important - // so later we can split results to resolutions of modules and resolutions of module augmentations. + /** + * The indexing of elements in this list matches that of `moduleNames`. + * + * Before combining results, result[i] is in one of the following states: + * * undefined: needs to be recomputed, + * * predictedToResolveToAmbientModuleMarker: known to be an ambient module. + * Needs to be reset to undefined before returning, + * * ResolvedModuleFull instance: can be reused. + */ var result; - // a transient placeholder that is used to mark predicted resolution in the result list + /** A transient placeholder used to mark predicted resolution in the result list. */ var predictedToResolveToAmbientModuleMarker = {}; for (var i = 0; i < moduleNames.length; i++) { var moduleName = moduleNames[i]; - // module name is known to be resolved to ambient module if - // - module name is contained in the list of ambient modules that are locally declared in the file - // - in the old program module name was resolved to ambient module whose declaration is in non-modified file + // If we want to reuse resolutions more aggressively, we can refine this to check for whether the + // text of the corresponding modulenames has changed. + if (file === oldSourceFile) { + var oldResolvedModule = oldSourceFile && oldSourceFile.resolvedModules.get(moduleName); + if (oldResolvedModule) { + if (ts.isTraceEnabled(options, host)) { + ts.trace(host, ts.Diagnostics.Reusing_resolution_of_module_0_to_file_1_from_old_program, moduleName, containingFile); + } + (result || (result = new Array(moduleNames.length)))[i] = oldResolvedModule; + continue; + } + } + // We know moduleName resolves to an ambient module provided that moduleName: + // - is in the list of ambient modules locally declared in the current source file. + // - resolved to an ambient module in the old program whose declaration is in an unmodified file // (so the same module declaration will land in the new program) - var isKnownToResolveToAmbientModule = false; + var resolvesToAmbientModuleInNonModifiedFile = false; if (ts.contains(file.ambientModuleNames, moduleName)) { - isKnownToResolveToAmbientModule = true; + resolvesToAmbientModuleInNonModifiedFile = true; if (ts.isTraceEnabled(options, host)) { ts.trace(host, ts.Diagnostics.Module_0_was_resolved_as_locally_declared_ambient_module_in_file_1, moduleName, containingFile); } } else { - isKnownToResolveToAmbientModule = checkModuleNameResolvedToAmbientModuleInNonModifiedFile(moduleName, oldProgramState); + resolvesToAmbientModuleInNonModifiedFile = moduleNameResolvesToAmbientModuleInNonModifiedFile(moduleName, oldProgramState); } - if (isKnownToResolveToAmbientModule) { - if (!unknownModuleNames) { - // found a first module name for which result can be prediced - // this means that this module name should not be passed to `resolveModuleNamesWorker`. - // We'll use a separate list for module names that are definitely unknown. - result = new Array(moduleNames.length); - // copy all module names that appear before the current one in the list - // since they are known to be unknown - unknownModuleNames = moduleNames.slice(0, i); - } - // mark prediced resolution in the result list - result[i] = predictedToResolveToAmbientModuleMarker; + if (resolvesToAmbientModuleInNonModifiedFile) { + (result || (result = new Array(moduleNames.length)))[i] = predictedToResolveToAmbientModuleMarker; } - else if (unknownModuleNames) { - // found unknown module name and we are already using separate list for those - add it to the list - unknownModuleNames.push(moduleName); + else { + // Resolution failed in the old program, or resolved to an ambient module for which we can't reuse the result. + (unknownModuleNames || (unknownModuleNames = [])).push(moduleName); } } - if (!unknownModuleNames) { - // we've looked throught the list but have not seen any predicted resolution - // use default logic - return resolveModuleNamesWorker(moduleNames, containingFile); - } - var resolutions = unknownModuleNames.length + var resolutions = unknownModuleNames && unknownModuleNames.length ? resolveModuleNamesWorker(unknownModuleNames, containingFile) : emptyArray; - // combine results of resolutions and predicted results + // Combine results of resolutions and predicted results + if (!result) { + // There were no unresolved/ambient resolutions. + ts.Debug.assert(resolutions.length === moduleNames.length); + return resolutions; + } var j = 0; for (var i = 0; i < result.length; i++) { - if (result[i] === predictedToResolveToAmbientModuleMarker) { - result[i] = undefined; + if (result[i]) { + // `result[i]` is either a `ResolvedModuleFull` or a marker. + // If it is the former, we can leave it as is. + if (result[i] === predictedToResolveToAmbientModuleMarker) { + result[i] = undefined; + } } else { result[i] = resolutions[j]; @@ -67189,16 +69508,15 @@ var ts; } ts.Debug.assert(j === resolutions.length); return result; - function checkModuleNameResolvedToAmbientModuleInNonModifiedFile(moduleName, oldProgramState) { - if (!oldProgramState) { - return false; - } + // If we change our policy of rechecking failed lookups on each program create, + // we should adjust the value returned here. + function moduleNameResolvesToAmbientModuleInNonModifiedFile(moduleName, oldProgramState) { var resolutionToFile = ts.getResolvedModule(oldProgramState.file, moduleName); if (resolutionToFile) { // module used to be resolved to file - ignore it return false; } - var ambientModule = oldProgram.getTypeChecker().tryFindAmbientModuleWithoutAugmentations(moduleName); + var ambientModule = oldProgramState.program && oldProgramState.program.getTypeChecker().tryFindAmbientModuleWithoutAugmentations(moduleName); if (!(ambientModule && ambientModule.declarations)) { return false; } @@ -67218,84 +69536,94 @@ var ts; } function tryReuseStructureFromOldProgram() { if (!oldProgram) { - return false; + return 0 /* Not */; } // check properties that can affect structure of the program or module resolution strategy // if any of these properties has changed - structure cannot be reused var oldOptions = oldProgram.getCompilerOptions(); if (ts.changesAffectModuleResolution(oldOptions, options)) { - return false; + return oldProgram.structureIsReused = 0 /* Not */; } - ts.Debug.assert(!oldProgram.structureIsReused); + ts.Debug.assert(!(oldProgram.structureIsReused & (2 /* Completely */ | 1 /* SafeModules */))); // there is an old program, check if we can reuse its structure var oldRootNames = oldProgram.getRootFileNames(); if (!ts.arrayIsEqualTo(oldRootNames, rootNames)) { - return false; + return oldProgram.structureIsReused = 0 /* Not */; } if (!ts.arrayIsEqualTo(options.types, oldOptions.types)) { - return false; + return oldProgram.structureIsReused = 0 /* Not */; } // check if program source files has changed in the way that can affect structure of the program var newSourceFiles = []; var filePaths = []; var modifiedSourceFiles = []; + oldProgram.structureIsReused = 2 /* Completely */; for (var _i = 0, _a = oldProgram.getSourceFiles(); _i < _a.length; _i++) { var oldSourceFile = _a[_i]; var newSourceFile = host.getSourceFileByPath ? host.getSourceFileByPath(oldSourceFile.fileName, oldSourceFile.path, options.target) : host.getSourceFile(oldSourceFile.fileName, options.target); if (!newSourceFile) { - return false; + return oldProgram.structureIsReused = 0 /* Not */; } newSourceFile.path = oldSourceFile.path; filePaths.push(newSourceFile.path); if (oldSourceFile !== newSourceFile) { + // The `newSourceFile` object was created for the new program. if (oldSourceFile.hasNoDefaultLib !== newSourceFile.hasNoDefaultLib) { // value of no-default-lib has changed // this will affect if default library is injected into the list of files - return false; + oldProgram.structureIsReused = 1 /* SafeModules */; } // check tripleslash references if (!ts.arrayIsEqualTo(oldSourceFile.referencedFiles, newSourceFile.referencedFiles, fileReferenceIsEqualTo)) { // tripleslash references has changed - return false; + oldProgram.structureIsReused = 1 /* SafeModules */; } // check imports and module augmentations collectExternalModuleReferences(newSourceFile); if (!ts.arrayIsEqualTo(oldSourceFile.imports, newSourceFile.imports, moduleNameIsEqualTo)) { // imports has changed - return false; + oldProgram.structureIsReused = 1 /* SafeModules */; } if (!ts.arrayIsEqualTo(oldSourceFile.moduleAugmentations, newSourceFile.moduleAugmentations, moduleNameIsEqualTo)) { // moduleAugmentations has changed - return false; + oldProgram.structureIsReused = 1 /* SafeModules */; + } + if ((oldSourceFile.flags & 524288 /* PossiblyContainsDynamicImport */) !== (newSourceFile.flags & 524288 /* PossiblyContainsDynamicImport */)) { + // dynamicImport has changed + oldProgram.structureIsReused = 1 /* SafeModules */; } if (!ts.arrayIsEqualTo(oldSourceFile.typeReferenceDirectives, newSourceFile.typeReferenceDirectives, fileReferenceIsEqualTo)) { // 'types' references has changed - return false; + oldProgram.structureIsReused = 1 /* SafeModules */; } // tentatively approve the file modifiedSourceFiles.push({ oldFile: oldSourceFile, newFile: newSourceFile }); } - else { - // file has no changes - use it as is - newSourceFile = oldSourceFile; - } // if file has passed all checks it should be safe to reuse it newSourceFiles.push(newSourceFile); } - var modifiedFilePaths = modifiedSourceFiles.map(function (f) { return f.newFile.path; }); + if (oldProgram.structureIsReused !== 2 /* Completely */) { + return oldProgram.structureIsReused; + } + modifiedFilePaths = modifiedSourceFiles.map(function (f) { return f.newFile.path; }); // try to verify results of module resolution for (var _b = 0, modifiedSourceFiles_1 = modifiedSourceFiles; _b < modifiedSourceFiles_1.length; _b++) { var _c = modifiedSourceFiles_1[_b], oldSourceFile = _c.oldFile, newSourceFile = _c.newFile; var newSourceFilePath = ts.getNormalizedAbsolutePath(newSourceFile.fileName, currentDirectory); if (resolveModuleNamesWorker) { var moduleNames = ts.map(ts.concatenate(newSourceFile.imports, newSourceFile.moduleAugmentations), getTextOfLiteral); - var resolutions = resolveModuleNamesReusingOldState(moduleNames, newSourceFilePath, newSourceFile, { file: oldSourceFile, program: oldProgram, modifiedFilePaths: modifiedFilePaths }); + var oldProgramState = { program: oldProgram, file: oldSourceFile, modifiedFilePaths: modifiedFilePaths }; + var resolutions = resolveModuleNamesReusingOldState(moduleNames, newSourceFilePath, newSourceFile, oldProgramState); // ensure that module resolution results are still correct var resolutionsChanged = ts.hasChangesInResolutions(moduleNames, resolutions, oldSourceFile.resolvedModules, ts.moduleResolutionIsEqualTo); if (resolutionsChanged) { - return false; + oldProgram.structureIsReused = 1 /* SafeModules */; + newSourceFile.resolvedModules = ts.zipToMap(moduleNames, resolutions); + } + else { + newSourceFile.resolvedModules = oldSourceFile.resolvedModules; } } if (resolveTypeReferenceDirectiveNamesWorker) { @@ -67304,12 +69632,16 @@ var ts; // ensure that types resolutions are still correct var resolutionsChanged = ts.hasChangesInResolutions(typesReferenceDirectives, resolutions, oldSourceFile.resolvedTypeReferenceDirectiveNames, ts.typeDirectiveIsEqualTo); if (resolutionsChanged) { - return false; + oldProgram.structureIsReused = 1 /* SafeModules */; + newSourceFile.resolvedTypeReferenceDirectiveNames = ts.zipToMap(typesReferenceDirectives, resolutions); + } + else { + newSourceFile.resolvedTypeReferenceDirectiveNames = oldSourceFile.resolvedTypeReferenceDirectiveNames; } } - // pass the cache of module/types resolutions from the old source file - newSourceFile.resolvedModules = oldSourceFile.resolvedModules; - newSourceFile.resolvedTypeReferenceDirectiveNames = oldSourceFile.resolvedTypeReferenceDirectiveNames; + } + if (oldProgram.structureIsReused !== 2 /* Completely */) { + return oldProgram.structureIsReused; } // update fileName -> file mapping for (var i = 0; i < newSourceFiles.length; i++) { @@ -67322,8 +69654,7 @@ var ts; fileProcessingDiagnostics.reattachFileDiagnostics(modifiedFile.newFile); } resolvedTypeReferenceDirectives = oldProgram.getResolvedTypeReferenceDirectives(); - oldProgram.structureIsReused = true; - return true; + return oldProgram.structureIsReused = 2 /* Completely */; } function getEmitHost(writeFileCallback) { return { @@ -67406,14 +69737,12 @@ var ts; if (sourceFile) { return getDiagnostics(sourceFile, cancellationToken); } - var allDiagnostics = []; - ts.forEach(program.getSourceFiles(), function (sourceFile) { + return ts.sortAndDeduplicateDiagnostics(ts.flatMap(program.getSourceFiles(), function (sourceFile) { if (cancellationToken) { cancellationToken.throwIfCancellationRequested(); } - ts.addRange(allDiagnostics, getDiagnostics(sourceFile, cancellationToken)); - }); - return ts.sortAndDeduplicateDiagnostics(allDiagnostics); + return getDiagnostics(sourceFile, cancellationToken); + })); } function getSyntacticDiagnostics(sourceFile, cancellationToken) { return getDiagnosticsHelper(sourceFile, getSyntacticDiagnosticsForFile, cancellationToken); @@ -67437,6 +69766,9 @@ var ts; if (ts.isSourceFileJavaScript(sourceFile)) { if (!sourceFile.additionalSyntacticDiagnostics) { sourceFile.additionalSyntacticDiagnostics = getJavaScriptSyntacticDiagnosticsForFile(sourceFile); + if (ts.isCheckJsEnabledForFile(sourceFile, options)) { + sourceFile.additionalSyntacticDiagnostics = ts.concatenate(sourceFile.additionalSyntacticDiagnostics, sourceFile.jsDocDiagnostics); + } } return ts.concatenate(sourceFile.additionalSyntacticDiagnostics, sourceFile.parseDiagnostics); } @@ -67476,10 +69808,10 @@ var ts; } var typeChecker = getDiagnosticsProducingTypeChecker(); ts.Debug.assert(!!sourceFile.bindDiagnostics); - var bindDiagnostics = sourceFile.bindDiagnostics; // For JavaScript files, we don't want to report semantic errors unless explicitly requested. - var includeCheckDiagnostics = !ts.isSourceFileJavaScript(sourceFile) || ts.isCheckJsEnabledForFile(sourceFile, options); - var checkDiagnostics = includeCheckDiagnostics ? typeChecker.getDiagnostics(sourceFile, cancellationToken) : []; + var includeBindAndCheckDiagnostics = !ts.isSourceFileJavaScript(sourceFile) || ts.isCheckJsEnabledForFile(sourceFile, options); + var bindDiagnostics = includeBindAndCheckDiagnostics ? sourceFile.bindDiagnostics : emptyArray; + var checkDiagnostics = includeBindAndCheckDiagnostics ? typeChecker.getDiagnostics(sourceFile, cancellationToken) : emptyArray; var fileProcessingDiagnosticsInFile = fileProcessingDiagnostics.getDiagnostics(sourceFile.fileName); var programDiagnosticsInFile = programDiagnostics.getDiagnostics(sourceFile.fileName); var diagnostics = bindDiagnostics.concat(checkDiagnostics, fileProcessingDiagnosticsInFile, programDiagnosticsInFile); @@ -67711,18 +70043,13 @@ var ts; return result; } function getDeclarationDiagnosticsForFile(sourceFile, cancellationToken) { - return ts.isDeclarationFile(sourceFile) ? [] : getDeclarationDiagnosticsWorker(sourceFile, cancellationToken); + return sourceFile.isDeclarationFile ? [] : getDeclarationDiagnosticsWorker(sourceFile, cancellationToken); } function getOptionsDiagnostics() { - var allDiagnostics = []; - ts.addRange(allDiagnostics, fileProcessingDiagnostics.getGlobalDiagnostics()); - ts.addRange(allDiagnostics, programDiagnostics.getGlobalDiagnostics()); - return ts.sortAndDeduplicateDiagnostics(allDiagnostics); + return ts.sortAndDeduplicateDiagnostics(ts.concatenate(fileProcessingDiagnostics.getGlobalDiagnostics(), programDiagnostics.getGlobalDiagnostics())); } function getGlobalDiagnostics() { - var allDiagnostics = []; - ts.addRange(allDiagnostics, getDiagnosticsProducingTypeChecker().getGlobalDiagnostics()); - return ts.sortAndDeduplicateDiagnostics(allDiagnostics); + return ts.sortAndDeduplicateDiagnostics(getDiagnosticsProducingTypeChecker().getGlobalDiagnostics().slice()); } function processRootFile(fileName, isDefaultLib) { processSourceFile(ts.normalizePath(fileName), isDefaultLib); @@ -67742,7 +70069,7 @@ var ts; } var isJavaScriptFile = ts.isSourceFileJavaScript(file); var isExternalModuleFile = ts.isExternalModule(file); - var isDtsFile = ts.isDeclarationFile(file); + // file.imports may not be undefined if there exists dynamic import var imports; var moduleAugmentations; var ambientModules; @@ -67761,8 +70088,8 @@ var ts; for (var _i = 0, _a = file.statements; _i < _a.length; _i++) { var node = _a[_i]; collectModuleReferences(node, /*inAmbientModule*/ false); - if (isJavaScriptFile) { - collectRequireCalls(node); + if ((file.flags & 524288 /* PossiblyContainsDynamicImport */) || isJavaScriptFile) { + collectDynamicImportOrRequireCalls(node); } } file.imports = imports || emptyArray; @@ -67789,7 +70116,7 @@ var ts; } break; case 233 /* ModuleDeclaration */: - if (ts.isAmbientModule(node) && (inAmbientModule || ts.hasModifier(node, 2 /* Ambient */) || ts.isDeclarationFile(file))) { + if (ts.isAmbientModule(node) && (inAmbientModule || ts.hasModifier(node, 2 /* Ambient */) || file.isDeclarationFile)) { var moduleName = node.name; // Ambient module declarations can be interpreted as augmentations for some existing external modules. // This will happen in two cases: @@ -67800,7 +70127,7 @@ var ts; (moduleAugmentations || (moduleAugmentations = [])).push(moduleName); } else if (!inAmbientModule) { - if (isDtsFile) { + if (file.isDeclarationFile) { // for global .d.ts files record name of ambient module (ambientModules || (ambientModules = [])).push(moduleName.text); } @@ -67820,55 +70147,65 @@ var ts; } } } - function collectRequireCalls(node) { + function collectDynamicImportOrRequireCalls(node) { if (ts.isRequireCall(node, /*checkArgumentIsStringLiteral*/ true)) { (imports || (imports = [])).push(node.arguments[0]); } + else if (ts.isImportCall(node) && node.arguments.length === 1 && node.arguments[0].kind === 9 /* StringLiteral */) { + (imports || (imports = [])).push(node.arguments[0]); + } else { - ts.forEachChild(node, collectRequireCalls); + ts.forEachChild(node, collectDynamicImportOrRequireCalls); } } } - function processSourceFile(fileName, isDefaultLib, refFile, refPos, refEnd) { - var diagnosticArgument; - var diagnostic; + /** This should have similar behavior to 'processSourceFile' without diagnostics or mutation. */ + function getSourceFileFromReference(referencingFile, ref) { + return getSourceFileFromReferenceWorker(resolveTripleslashReference(ref.fileName, referencingFile.fileName), function (fileName) { return filesByName.get(ts.toPath(fileName, currentDirectory, getCanonicalFileName)); }); + } + function getSourceFileFromReferenceWorker(fileName, getSourceFile, fail, refFile) { if (ts.hasExtension(fileName)) { if (!options.allowNonTsExtensions && !ts.forEach(supportedExtensions, function (extension) { return ts.fileExtensionIs(host.getCanonicalFileName(fileName), extension); })) { - diagnostic = ts.Diagnostics.File_0_has_unsupported_extension_The_only_supported_extensions_are_1; - diagnosticArgument = [fileName, "'" + supportedExtensions.join("', '") + "'"]; - } - else if (!findSourceFile(fileName, ts.toPath(fileName, currentDirectory, getCanonicalFileName), isDefaultLib, refFile, refPos, refEnd)) { - diagnostic = ts.Diagnostics.File_0_not_found; - diagnosticArgument = [fileName]; - } - else if (refFile && host.getCanonicalFileName(fileName) === host.getCanonicalFileName(refFile.fileName)) { - diagnostic = ts.Diagnostics.A_file_cannot_have_a_reference_to_itself; - diagnosticArgument = [fileName]; + if (fail) + fail(ts.Diagnostics.File_0_has_unsupported_extension_The_only_supported_extensions_are_1, fileName, "'" + supportedExtensions.join("', '") + "'"); + return undefined; } - } - else { - var nonTsFile = options.allowNonTsExtensions && findSourceFile(fileName, ts.toPath(fileName, currentDirectory, getCanonicalFileName), isDefaultLib, refFile, refPos, refEnd); - if (!nonTsFile) { - if (options.allowNonTsExtensions) { - diagnostic = ts.Diagnostics.File_0_not_found; - diagnosticArgument = [fileName]; + var sourceFile = getSourceFile(fileName); + if (fail) { + if (!sourceFile) { + fail(ts.Diagnostics.File_0_not_found, fileName); } - else if (!ts.forEach(supportedExtensions, function (extension) { return findSourceFile(fileName + extension, ts.toPath(fileName + extension, currentDirectory, getCanonicalFileName), isDefaultLib, refFile, refPos, refEnd); })) { - diagnostic = ts.Diagnostics.File_0_not_found; - fileName += ".ts"; - diagnosticArgument = [fileName]; + else if (refFile && host.getCanonicalFileName(fileName) === host.getCanonicalFileName(refFile.fileName)) { + fail(ts.Diagnostics.A_file_cannot_have_a_reference_to_itself, fileName); } } + return sourceFile; } - if (diagnostic) { - if (refFile !== undefined && refEnd !== undefined && refPos !== undefined) { - fileProcessingDiagnostics.add(ts.createFileDiagnostic.apply(void 0, [refFile, refPos, refEnd - refPos, diagnostic].concat(diagnosticArgument))); - } - else { - fileProcessingDiagnostics.add(ts.createCompilerDiagnostic.apply(void 0, [diagnostic].concat(diagnosticArgument))); + else { + var sourceFileNoExtension = options.allowNonTsExtensions && getSourceFile(fileName); + if (sourceFileNoExtension) + return sourceFileNoExtension; + if (fail && options.allowNonTsExtensions) { + fail(ts.Diagnostics.File_0_not_found, fileName); + return undefined; } + var sourceFileWithAddedExtension = ts.forEach(supportedExtensions, function (extension) { return getSourceFile(fileName + extension); }); + if (fail && !sourceFileWithAddedExtension) + fail(ts.Diagnostics.File_0_not_found, fileName + ".ts"); + return sourceFileWithAddedExtension; } } + /** This has side effects through `findSourceFile`. */ + function processSourceFile(fileName, isDefaultLib, refFile, refPos, refEnd) { + getSourceFileFromReferenceWorker(fileName, function (fileName) { return findSourceFile(fileName, ts.toPath(fileName, currentDirectory, getCanonicalFileName), isDefaultLib, refFile, refPos, refEnd); }, function (diagnostic) { + var args = []; + for (var _i = 1; _i < arguments.length; _i++) { + args[_i - 1] = arguments[_i]; + } + fileProcessingDiagnostics.add(refFile !== undefined && refEnd !== undefined && refPos !== undefined + ? ts.createFileDiagnostic.apply(void 0, [refFile, refPos, refEnd - refPos, diagnostic].concat(args)) : ts.createCompilerDiagnostic.apply(void 0, [diagnostic].concat(args))); + }, refFile); + } function reportFileNamesDifferOnlyInCasingError(fileName, existingFileName, refFile, refPos, refEnd) { if (refFile !== undefined && refPos !== undefined && refEnd !== undefined) { fileProcessingDiagnostics.add(ts.createFileDiagnostic(refFile, refPos, refEnd - refPos, ts.Diagnostics.File_name_0_differs_from_already_included_file_name_1_only_in_casing, fileName, existingFileName)); @@ -68020,11 +70357,11 @@ var ts; function processImportedModules(file) { collectExternalModuleReferences(file); if (file.imports.length || file.moduleAugmentations.length) { - file.resolvedModules = ts.createMap(); // Because global augmentation doesn't have string literal name, we can check for global augmentation as such. var nonGlobalAugmentation = ts.filter(file.moduleAugmentations, function (moduleAugmentation) { return moduleAugmentation.kind === 9 /* StringLiteral */; }); var moduleNames = ts.map(ts.concatenate(file.imports, nonGlobalAugmentation), getTextOfLiteral); - var resolutions = resolveModuleNamesReusingOldState(moduleNames, ts.getNormalizedAbsolutePath(file.fileName, currentDirectory), file); + var oldProgramState = { program: oldProgram, file: file, modifiedFilePaths: modifiedFilePaths }; + var resolutions = resolveModuleNamesReusingOldState(moduleNames, ts.getNormalizedAbsolutePath(file.fileName, currentDirectory), file, oldProgramState); ts.Debug.assert(resolutions.length === moduleNames.length); for (var i = 0; i < moduleNames.length; i++) { var resolution = resolutions[i]; @@ -68081,7 +70418,7 @@ var ts; var absoluteRootDirectoryPath = host.getCanonicalFileName(ts.getNormalizedAbsolutePath(rootDirectory, currentDirectory)); for (var _i = 0, sourceFiles_3 = sourceFiles; _i < sourceFiles_3.length; _i++) { var sourceFile = sourceFiles_3[_i]; - if (!ts.isDeclarationFile(sourceFile)) { + if (!sourceFile.isDeclarationFile) { var absoluteSourceFilePath = host.getCanonicalFileName(ts.getNormalizedAbsolutePath(sourceFile.fileName, currentDirectory)); if (absoluteSourceFilePath.indexOf(absoluteRootDirectoryPath) !== 0) { programDiagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.File_0_is_not_under_rootDir_1_rootDir_is_expected_to_contain_all_source_files, sourceFile.fileName, options.rootDir)); @@ -68179,12 +70516,12 @@ var ts; } var languageVersion = options.target || 0 /* ES3 */; var outFile = options.outFile || options.out; - var firstNonAmbientExternalModuleSourceFile = ts.forEach(files, function (f) { return ts.isExternalModule(f) && !ts.isDeclarationFile(f) ? f : undefined; }); + var firstNonAmbientExternalModuleSourceFile = ts.forEach(files, function (f) { return ts.isExternalModule(f) && !f.isDeclarationFile ? f : undefined; }); if (options.isolatedModules) { if (options.module === ts.ModuleKind.None && languageVersion < 2 /* ES2015 */) { programDiagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_isolatedModules_can_only_be_used_when_either_option_module_is_provided_or_option_target_is_ES2015_or_higher)); } - var firstNonExternalModuleSourceFile = ts.forEach(files, function (f) { return !ts.isExternalModule(f) && !ts.isDeclarationFile(f) ? f : undefined; }); + var firstNonExternalModuleSourceFile = ts.forEach(files, function (f) { return !ts.isExternalModule(f) && !f.isDeclarationFile ? f : undefined; }); if (firstNonExternalModuleSourceFile) { var span_7 = ts.getErrorSpanForNode(firstNonExternalModuleSourceFile, firstNonExternalModuleSourceFile); programDiagnostics.add(ts.createFileDiagnostic(firstNonExternalModuleSourceFile, span_7.start, span_7.length, ts.Diagnostics.Cannot_compile_namespaces_when_the_isolatedModules_flag_is_provided)); @@ -68408,11 +70745,12 @@ var ts; "umd": ts.ModuleKind.UMD, "es6": ts.ModuleKind.ES2015, "es2015": ts.ModuleKind.ES2015, + "esnext": ts.ModuleKind.ESNext }), paramType: ts.Diagnostics.KIND, showInSimplifiedHelpView: true, category: ts.Diagnostics.Basic_Options, - description: ts.Diagnostics.Specify_module_code_generation_Colon_commonjs_amd_system_umd_or_es2015, + description: ts.Diagnostics.Specify_module_code_generation_Colon_commonjs_amd_system_umd_es2015_or_ESNext, }, { name: "lib", @@ -68447,6 +70785,7 @@ var ts; "es2017.object": "lib.es2017.object.d.ts", "es2017.sharedmemory": "lib.es2017.sharedmemory.d.ts", "es2017.string": "lib.es2017.string.d.ts", + "es2017.intl": "lib.es2017.intl.d.ts", "esnext.asynciterable": "lib.esnext.asynciterable.d.ts", }), }, @@ -68918,6 +71257,12 @@ var ts; category: ts.Diagnostics.Advanced_Options, description: ts.Diagnostics.The_maximum_dependency_depth_to_search_under_node_modules_and_load_JavaScript_files }, + { + name: "noStrictGenericChecks", + type: "boolean", + category: ts.Diagnostics.Advanced_Options, + description: ts.Diagnostics.Disable_strict_checking_of_generic_signatures_in_function_types, + }, { // A list of plugins to load in the language service name: "plugins", @@ -69317,7 +71662,7 @@ var ts; for (var i = 0; i < nameColumn.length; i++) { var optionName = nameColumn[i]; var description = descriptionColumn[i]; - result.push(tab + tab + optionName + makePadding(marginLength - optionName.length + 2) + description); + result.push(optionName && "" + tab + tab + optionName + (description && (makePadding(marginLength - optionName.length + 2) + description))); } if (configurations.files && configurations.files.length) { result.push(tab + "},"); @@ -69365,57 +71710,37 @@ var ts; * @param host Instance of ParseConfigHost used to enumerate files in folder. * @param basePath A root directory to resolve relative path entries in the config * file to. e.g. outDir + * @param resolutionStack Only present for backwards-compatibility. Should be empty. */ function parseJsonConfigFileContent(json, host, basePath, existingOptions, configFileName, resolutionStack, extraFileExtensions) { if (existingOptions === void 0) { existingOptions = {}; } if (resolutionStack === void 0) { resolutionStack = []; } if (extraFileExtensions === void 0) { extraFileExtensions = []; } var errors = []; - basePath = ts.normalizeSlashes(basePath); - var getCanonicalFileName = ts.createGetCanonicalFileName(host.useCaseSensitiveFileNames); - var resolvedPath = ts.toPath(configFileName || "", basePath, getCanonicalFileName); - if (resolutionStack.indexOf(resolvedPath) >= 0) { - return { - options: {}, - fileNames: [], - typeAcquisition: {}, - raw: json, - errors: [ts.createCompilerDiagnostic(ts.Diagnostics.Circularity_detected_while_resolving_configuration_Colon_0, resolutionStack.concat([resolvedPath]).join(" -> "))], - wildcardDirectories: {} - }; - } - var options = convertCompilerOptionsFromJsonWorker(json["compilerOptions"], basePath, errors, configFileName); - // typingOptions has been deprecated and is only supported for backward compatibility purposes. - // It should be removed in future releases - use typeAcquisition instead. - var jsonOptions = json["typeAcquisition"] || json["typingOptions"]; - var typeAcquisition = convertTypeAcquisitionFromJsonWorker(jsonOptions, basePath, errors, configFileName); - var baseCompileOnSave; - if (json["extends"]) { - var _a = [undefined, undefined, undefined, {}], include = _a[0], exclude = _a[1], files = _a[2], baseOptions = _a[3]; - if (typeof json["extends"] === "string") { - _b = (tryExtendsName(json["extends"]) || [include, exclude, files, baseCompileOnSave, baseOptions]), include = _b[0], exclude = _b[1], files = _b[2], baseCompileOnSave = _b[3], baseOptions = _b[4]; + var options = (function () { + var _a = parseConfig(json, host, basePath, configFileName, resolutionStack, errors), include = _a.include, exclude = _a.exclude, files = _a.files, options = _a.options, compileOnSave = _a.compileOnSave; + if (include) { + json.include = include; } - else { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Compiler_option_0_requires_a_value_of_type_1, "extends", "string")); - } - if (include && !json["include"]) { - json["include"] = include; + if (exclude) { + json.exclude = exclude; } - if (exclude && !json["exclude"]) { - json["exclude"] = exclude; + if (files) { + json.files = files; } - if (files && !json["files"]) { - json["files"] = files; + if (compileOnSave !== undefined) { + json.compileOnSave = compileOnSave; } - options = ts.assign({}, baseOptions, options); - } + return options; + })(); options = ts.extend(existingOptions, options); options.configFilePath = configFileName; - var _c = getFileNames(errors), fileNames = _c.fileNames, wildcardDirectories = _c.wildcardDirectories; + // typingOptions has been deprecated and is only supported for backward compatibility purposes. + // It should be removed in future releases - use typeAcquisition instead. + var jsonOptions = json["typeAcquisition"] || json["typingOptions"]; + var typeAcquisition = convertTypeAcquisitionFromJsonWorker(jsonOptions, basePath, errors, configFileName); + var _a = getFileNames(), fileNames = _a.fileNames, wildcardDirectories = _a.wildcardDirectories; var compileOnSave = convertCompileOnSaveOptionFromJson(json, basePath, errors); - if (baseCompileOnSave && json[ts.compileOnSaveCommandLineOption.name] === undefined) { - compileOnSave = baseCompileOnSave; - } return { options: options, fileNames: fileNames, @@ -69425,39 +71750,7 @@ var ts; wildcardDirectories: wildcardDirectories, compileOnSave: compileOnSave }; - function tryExtendsName(extendedConfig) { - // If the path isn't a rooted or relative path, don't try to resolve it (we reserve the right to special case module-id like paths in the future) - if (!(ts.isRootedDiskPath(extendedConfig) || ts.startsWith(ts.normalizeSlashes(extendedConfig), "./") || ts.startsWith(ts.normalizeSlashes(extendedConfig), "../"))) { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.A_path_in_an_extends_option_must_be_relative_or_rooted_but_0_is_not, extendedConfig)); - return; - } - var extendedConfigPath = ts.toPath(extendedConfig, basePath, getCanonicalFileName); - if (!host.fileExists(extendedConfigPath) && !ts.endsWith(extendedConfigPath, ".json")) { - extendedConfigPath = extendedConfigPath + ".json"; - if (!host.fileExists(extendedConfigPath)) { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.File_0_does_not_exist, extendedConfig)); - return; - } - } - var extendedResult = readConfigFile(extendedConfigPath, function (path) { return host.readFile(path); }); - if (extendedResult.error) { - errors.push(extendedResult.error); - return; - } - var extendedDirname = ts.getDirectoryPath(extendedConfigPath); - var relativeDifference = ts.convertToRelativePath(extendedDirname, basePath, getCanonicalFileName); - var updatePath = function (path) { return ts.isRootedDiskPath(path) ? path : ts.combinePaths(relativeDifference, path); }; - // Merge configs (copy the resolution stack so it is never reused between branches in potential diamond-problem scenarios) - var result = parseJsonConfigFileContent(extendedResult.config, host, extendedDirname, /*existingOptions*/ undefined, ts.getBaseFileName(extendedConfigPath), resolutionStack.concat([resolvedPath])); - errors.push.apply(errors, result.errors); - var _a = ts.map(["include", "exclude", "files"], function (key) { - if (!json[key] && extendedResult.config[key]) { - return ts.map(extendedResult.config[key], updatePath); - } - }), include = _a[0], exclude = _a[1], files = _a[2]; - return [include, exclude, files, result.compileOnSave, result.options]; - } - function getFileNames(errors) { + function getFileNames() { var fileNames; if (ts.hasProperty(json, "files")) { if (ts.isArray(json["files"])) { @@ -69488,9 +71781,6 @@ var ts; errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Compiler_option_0_requires_a_value_of_type_1, "exclude", "Array")); } } - else if (ts.hasProperty(json, "excludes")) { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Unknown_option_excludes_Did_you_mean_exclude)); - } else { // If no includes were specified, exclude common package folders and the outDir excludeSpecs = includeSpecs ? [] : ["node_modules", "bower_components", "jspm_packages"]; @@ -69508,9 +71798,73 @@ var ts; } return result; } - var _b; } ts.parseJsonConfigFileContent = parseJsonConfigFileContent; + /** + * This *just* extracts options/include/exclude/files out of a config file. + * It does *not* resolve the included files. + */ + function parseConfig(json, host, basePath, configFileName, resolutionStack, errors) { + basePath = ts.normalizeSlashes(basePath); + var getCanonicalFileName = ts.createGetCanonicalFileName(host.useCaseSensitiveFileNames); + var resolvedPath = ts.toPath(configFileName || "", basePath, getCanonicalFileName); + if (resolutionStack.indexOf(resolvedPath) >= 0) { + errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Circularity_detected_while_resolving_configuration_Colon_0, resolutionStack.concat([resolvedPath]).join(" -> "))); + return { include: undefined, exclude: undefined, files: undefined, options: {}, compileOnSave: undefined }; + } + if (ts.hasProperty(json, "excludes")) { + errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Unknown_option_excludes_Did_you_mean_exclude)); + } + var options = convertCompilerOptionsFromJsonWorker(json.compilerOptions, basePath, errors, configFileName); + var include = json.include, exclude = json.exclude, files = json.files; + var compileOnSave = json.compileOnSave; + if (json.extends) { + // copy the resolution stack so it is never reused between branches in potential diamond-problem scenarios. + resolutionStack = resolutionStack.concat([resolvedPath]); + var base = getExtendedConfig(json.extends, host, basePath, getCanonicalFileName, resolutionStack, errors); + if (base) { + include = include || base.include; + exclude = exclude || base.exclude; + files = files || base.files; + if (compileOnSave === undefined) { + compileOnSave = base.compileOnSave; + } + options = ts.assign({}, base.options, options); + } + } + return { include: include, exclude: exclude, files: files, options: options, compileOnSave: compileOnSave }; + } + function getExtendedConfig(extended, // Usually a string. + host, basePath, getCanonicalFileName, resolutionStack, errors) { + if (typeof extended !== "string") { + errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Compiler_option_0_requires_a_value_of_type_1, "extends", "string")); + return undefined; + } + extended = ts.normalizeSlashes(extended); + // If the path isn't a rooted or relative path, don't try to resolve it (we reserve the right to special case module-id like paths in the future) + if (!(ts.isRootedDiskPath(extended) || ts.startsWith(extended, "./") || ts.startsWith(extended, "../"))) { + errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.A_path_in_an_extends_option_must_be_relative_or_rooted_but_0_is_not, extended)); + return undefined; + } + var extendedConfigPath = ts.toPath(extended, basePath, getCanonicalFileName); + if (!host.fileExists(extendedConfigPath) && !ts.endsWith(extendedConfigPath, ".json")) { + extendedConfigPath = extendedConfigPath + ".json"; + if (!host.fileExists(extendedConfigPath)) { + errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.File_0_does_not_exist, extended)); + return undefined; + } + } + var extendedResult = readConfigFile(extendedConfigPath, function (path) { return host.readFile(path); }); + if (extendedResult.error) { + errors.push(extendedResult.error); + return undefined; + } + var extendedDirname = ts.getDirectoryPath(extendedConfigPath); + var relativeDifference = ts.convertToRelativePath(extendedDirname, basePath, getCanonicalFileName); + var updatePath = function (path) { return ts.isRootedDiskPath(path) ? path : ts.combinePaths(relativeDifference, path); }; + var _a = parseConfig(extendedResult.config, host, extendedDirname, ts.getBaseFileName(extendedConfigPath), resolutionStack, errors), include = _a.include, exclude = _a.exclude, files = _a.files, options = _a.options, compileOnSave = _a.compileOnSave; + return { include: ts.map(include, updatePath), exclude: ts.map(exclude, updatePath), files: ts.map(files, updatePath), compileOnSave: compileOnSave, options: options }; + } function convertCompileOnSaveOptionFromJson(jsonOption, basePath, errors) { if (!ts.hasProperty(jsonOption, ts.compileOnSaveCommandLineOption.name)) { return false; @@ -69806,7 +72160,7 @@ var ts; } } // Remove any subpaths under an existing recursively watched directory. - for (var key in wildcardDirectories) + for (var key in wildcardDirectories) { if (ts.hasProperty(wildcardDirectories, key)) { for (var _a = 0, recursiveKeys_1 = recursiveKeys; _a < recursiveKeys_1.length; _a++) { var recursiveKey = recursiveKeys_1[_a]; @@ -69815,6 +72169,7 @@ var ts; } } } + } } return wildcardDirectories; } @@ -69891,23 +72246,24 @@ var ts; /* @internal */ function convertCompilerOptionsForTelemetry(opts) { var out = {}; - for (var key in opts) + for (var key in opts) { if (opts.hasOwnProperty(key)) { var type = getOptionFromName(key); if (type !== undefined) { out[key] = getOptionValueWithEmptyStrings(opts[key], type); } } + } return out; } ts.convertCompilerOptionsForTelemetry = convertCompilerOptionsForTelemetry; function getOptionValueWithEmptyStrings(value, option) { switch (option.type) { - case "object": + case "object":// "paths". Can't get any useful information from the value since we blank out strings, so just return "". return ""; - case "string": + case "string":// Could be any arbitrary string -- use empty string instead. return ""; - case "number": + case "number":// Allow numbers, but be sure to check it's actually a number. return typeof value === "number" ? value : ""; case "boolean": return typeof value === "boolean" ? value : ""; @@ -70106,31 +72462,31 @@ var ts; var ClassificationTypeNames = (function () { function ClassificationTypeNames() { } + ClassificationTypeNames.comment = "comment"; + ClassificationTypeNames.identifier = "identifier"; + ClassificationTypeNames.keyword = "keyword"; + ClassificationTypeNames.numericLiteral = "number"; + ClassificationTypeNames.operator = "operator"; + ClassificationTypeNames.stringLiteral = "string"; + ClassificationTypeNames.whiteSpace = "whitespace"; + ClassificationTypeNames.text = "text"; + ClassificationTypeNames.punctuation = "punctuation"; + ClassificationTypeNames.className = "class name"; + ClassificationTypeNames.enumName = "enum name"; + ClassificationTypeNames.interfaceName = "interface name"; + ClassificationTypeNames.moduleName = "module name"; + ClassificationTypeNames.typeParameterName = "type parameter name"; + ClassificationTypeNames.typeAliasName = "type alias name"; + ClassificationTypeNames.parameterName = "parameter name"; + ClassificationTypeNames.docCommentTagName = "doc comment tag name"; + ClassificationTypeNames.jsxOpenTagName = "jsx open tag name"; + ClassificationTypeNames.jsxCloseTagName = "jsx close tag name"; + ClassificationTypeNames.jsxSelfClosingTagName = "jsx self closing tag name"; + ClassificationTypeNames.jsxAttribute = "jsx attribute"; + ClassificationTypeNames.jsxText = "jsx text"; + ClassificationTypeNames.jsxAttributeStringLiteralValue = "jsx attribute string literal value"; return ClassificationTypeNames; }()); - ClassificationTypeNames.comment = "comment"; - ClassificationTypeNames.identifier = "identifier"; - ClassificationTypeNames.keyword = "keyword"; - ClassificationTypeNames.numericLiteral = "number"; - ClassificationTypeNames.operator = "operator"; - ClassificationTypeNames.stringLiteral = "string"; - ClassificationTypeNames.whiteSpace = "whitespace"; - ClassificationTypeNames.text = "text"; - ClassificationTypeNames.punctuation = "punctuation"; - ClassificationTypeNames.className = "class name"; - ClassificationTypeNames.enumName = "enum name"; - ClassificationTypeNames.interfaceName = "interface name"; - ClassificationTypeNames.moduleName = "module name"; - ClassificationTypeNames.typeParameterName = "type parameter name"; - ClassificationTypeNames.typeAliasName = "type alias name"; - ClassificationTypeNames.parameterName = "parameter name"; - ClassificationTypeNames.docCommentTagName = "doc comment tag name"; - ClassificationTypeNames.jsxOpenTagName = "jsx open tag name"; - ClassificationTypeNames.jsxCloseTagName = "jsx close tag name"; - ClassificationTypeNames.jsxSelfClosingTagName = "jsx self closing tag name"; - ClassificationTypeNames.jsxAttribute = "jsx attribute"; - ClassificationTypeNames.jsxText = "jsx text"; - ClassificationTypeNames.jsxAttributeStringLiteralValue = "jsx attribute string literal value"; ts.ClassificationTypeNames = ClassificationTypeNames; var ClassificationType; (function (ClassificationType) { @@ -70183,7 +72539,6 @@ var ts; case 148 /* PropertySignature */: case 261 /* PropertyAssignment */: case 262 /* ShorthandPropertyAssignment */: - case 264 /* EnumMember */: case 151 /* MethodDeclaration */: case 150 /* MethodSignature */: case 152 /* Constructor */: @@ -70200,8 +72555,11 @@ var ts; case 231 /* TypeAliasDeclaration */: case 163 /* TypeLiteral */: return 2 /* Type */; + case 291 /* JSDocTypedefTag */: + // If it has no name node, it shares the name with the value declaration below it. + return node.name === undefined ? 1 /* Value */ | 2 /* Type */ : 2 /* Type */; + case 264 /* EnumMember */: case 229 /* ClassDeclaration */: - case 232 /* EnumDeclaration */: return 1 /* Value */ | 2 /* Type */; case 233 /* ModuleDeclaration */: if (ts.isAmbientModule(node)) { @@ -70213,18 +72571,19 @@ var ts; else { return 4 /* Namespace */; } + case 232 /* EnumDeclaration */: case 241 /* NamedImports */: case 242 /* ImportSpecifier */: case 237 /* ImportEqualsDeclaration */: case 238 /* ImportDeclaration */: case 243 /* ExportAssignment */: case 244 /* ExportDeclaration */: - return 1 /* Value */ | 2 /* Type */ | 4 /* Namespace */; + return 7 /* All */; // An external module can be a Value case 265 /* SourceFile */: return 4 /* Namespace */ | 1 /* Value */; } - return 1 /* Value */ | 2 /* Type */ | 4 /* Namespace */; + return 7 /* All */; } ts.getMeaningFromDeclaration = getMeaningFromDeclaration; function getMeaningFromLocation(node) { @@ -70232,9 +72591,9 @@ var ts; return 1 /* Value */; } else if (node.parent.kind === 243 /* ExportAssignment */) { - return 1 /* Value */ | 2 /* Type */ | 4 /* Namespace */; + return 7 /* All */; } - else if (isInRightSideOfImport(node)) { + else if (isInRightSideOfInternalImportEqualsDeclaration(node)) { return getMeaningFromRightHandSideOfImportEquals(node); } else if (ts.isDeclarationName(node)) { @@ -70246,6 +72605,10 @@ var ts; else if (isNamespaceReference(node)) { return 4 /* Namespace */; } + else if (ts.isTypeParameterDeclaration(node.parent)) { + ts.Debug.assert(ts.isJSDocTemplateTag(node.parent.parent)); // Else would be handled by isDeclarationName + return 2 /* Type */; + } else { return 1 /* Value */; } @@ -70263,12 +72626,13 @@ var ts; } return 4 /* Namespace */; } - function isInRightSideOfImport(node) { + function isInRightSideOfInternalImportEqualsDeclaration(node) { while (node.parent.kind === 143 /* QualifiedName */) { node = node.parent; } return ts.isInternalModuleImportEqualsDeclaration(node.parent) && node.parent.moduleReference === node; } + ts.isInRightSideOfInternalImportEqualsDeclaration = isInRightSideOfInternalImportEqualsDeclaration; function isNamespaceReference(node) { return isQualifiedNameNamespaceReference(node) || isPropertyAccessNamespaceReference(node); } @@ -70303,10 +72667,20 @@ var ts; if (ts.isRightSideOfQualifiedNameOrPropertyAccess(node)) { node = node.parent; } - return node.parent.kind === 159 /* TypeReference */ || - (node.parent.kind === 201 /* ExpressionWithTypeArguments */ && !ts.isExpressionWithTypeArgumentsInClassExtendsClause(node.parent)) || - (node.kind === 99 /* ThisKeyword */ && !ts.isPartOfExpression(node)) || - node.kind === 169 /* ThisType */; + switch (node.kind) { + case 99 /* ThisKeyword */: + return !ts.isPartOfExpression(node); + case 169 /* ThisType */: + return true; + } + switch (node.parent.kind) { + case 159 /* TypeReference */: + case 277 /* JSDocTypeReference */: + return true; + case 201 /* ExpressionWithTypeArguments */: + return !ts.isExpressionWithTypeArgumentsInClassExtendsClause(node.parent); + } + return false; } function isCallExpressionTarget(node) { return isCallOrNewExpressionTarget(node, 181 /* CallExpression */); @@ -70393,36 +72767,6 @@ var ts; ts.getExternalModuleImportEqualsDeclarationExpression(node.parent.parent) === node; } ts.isExpressionOfExternalModuleImportEqualsDeclaration = isExpressionOfExternalModuleImportEqualsDeclaration; - /** Returns true if the position is within a comment */ - function isInsideComment(sourceFile, token, position) { - // The position has to be: 1. in the leading trivia (before token.getStart()), and 2. within a comment - return position <= token.getStart(sourceFile) && - (isInsideCommentRange(ts.getTrailingCommentRanges(sourceFile.text, token.getFullStart())) || - isInsideCommentRange(ts.getLeadingCommentRanges(sourceFile.text, token.getFullStart()))); - function isInsideCommentRange(comments) { - return ts.forEach(comments, function (comment) { - // either we are 1. completely inside the comment, or 2. at the end of the comment - if (comment.pos < position && position < comment.end) { - return true; - } - else if (position === comment.end) { - var text = sourceFile.text; - var width = comment.end - comment.pos; - // is single line comment or just /* - if (width <= 2 || text.charCodeAt(comment.pos + 1) === 47 /* slash */) { - return true; - } - else { - // is unterminated multi-line comment - return !(text.charCodeAt(comment.end - 1) === 47 /* slash */ && - text.charCodeAt(comment.end - 2) === 42 /* asterisk */); - } - } - return false; - }); - } - } - ts.isInsideComment = isInsideComment; function getContainerNode(node) { while (true) { node = node.parent; @@ -70487,7 +72831,7 @@ var ts; case 246 /* ExportSpecifier */: case 240 /* NamespaceImport */: return ts.ScriptElementKind.alias; - case 290 /* JSDocTypedefTag */: + case 291 /* JSDocTypedefTag */: return ts.ScriptElementKind.typeElement; default: return ts.ScriptElementKind.unknown; @@ -70714,7 +73058,7 @@ var ts; // for the position of the relevant node (or comma). var syntaxList = ts.forEach(node.parent.getChildren(), function (c) { // find syntax list that covers the span of the node - if (c.kind === 294 /* SyntaxList */ && c.pos <= node.pos && c.end >= node.end) { + if (c.kind === 295 /* SyntaxList */ && c.pos <= node.pos && c.end >= node.end) { return c; } }); @@ -70727,78 +73071,56 @@ var ts; * position >= start and (position < end or (position === end && token is keyword or identifier)) */ function getTouchingWord(sourceFile, position, includeJsDocComment) { - if (includeJsDocComment === void 0) { includeJsDocComment = false; } - return getTouchingToken(sourceFile, position, function (n) { return isWord(n.kind); }, includeJsDocComment); + return getTouchingToken(sourceFile, position, includeJsDocComment, function (n) { return isWord(n.kind); }); } ts.getTouchingWord = getTouchingWord; /* Gets the token whose text has range [start, end) and position >= start * and (position < end or (position === end && token is keyword or identifier or numeric/string literal)) */ function getTouchingPropertyName(sourceFile, position, includeJsDocComment) { - if (includeJsDocComment === void 0) { includeJsDocComment = false; } - return getTouchingToken(sourceFile, position, function (n) { return isPropertyName(n.kind); }, includeJsDocComment); + return getTouchingToken(sourceFile, position, includeJsDocComment, function (n) { return isPropertyName(n.kind); }); } ts.getTouchingPropertyName = getTouchingPropertyName; - /** Returns the token if position is in [start, end) or if position === end and includeItemAtEndPosition(token) === true */ - function getTouchingToken(sourceFile, position, includeItemAtEndPosition, includeJsDocComment) { - if (includeJsDocComment === void 0) { includeJsDocComment = false; } - return getTokenAtPositionWorker(sourceFile, position, /*allowPositionInLeadingTrivia*/ false, includeItemAtEndPosition, includeJsDocComment); + /** + * Returns the token if position is in [start, end). + * If position === end, returns the preceding token if includeItemAtEndPosition(previousToken) === true + */ + function getTouchingToken(sourceFile, position, includeJsDocComment, includePrecedingTokenAtEndPosition) { + return getTokenAtPositionWorker(sourceFile, position, /*allowPositionInLeadingTrivia*/ false, includePrecedingTokenAtEndPosition, /*includeEndPosition*/ false, includeJsDocComment); } ts.getTouchingToken = getTouchingToken; /** Returns a token if position is in [start-of-leading-trivia, end) */ - function getTokenAtPosition(sourceFile, position, includeJsDocComment) { - if (includeJsDocComment === void 0) { includeJsDocComment = false; } - return getTokenAtPositionWorker(sourceFile, position, /*allowPositionInLeadingTrivia*/ true, /*includeItemAtEndPosition*/ undefined, includeJsDocComment); + function getTokenAtPosition(sourceFile, position, includeJsDocComment, includeEndPosition) { + return getTokenAtPositionWorker(sourceFile, position, /*allowPositionInLeadingTrivia*/ true, /*includePrecedingTokenAtEndPosition*/ undefined, includeEndPosition, includeJsDocComment); } ts.getTokenAtPosition = getTokenAtPosition; /** Get the token whose text contains the position */ - function getTokenAtPositionWorker(sourceFile, position, allowPositionInLeadingTrivia, includeItemAtEndPosition, includeJsDocComment) { - if (includeJsDocComment === void 0) { includeJsDocComment = false; } + function getTokenAtPositionWorker(sourceFile, position, allowPositionInLeadingTrivia, includePrecedingTokenAtEndPosition, includeEndPosition, includeJsDocComment) { var current = sourceFile; outer: while (true) { if (ts.isToken(current)) { // exit early return current; } - if (includeJsDocComment) { - var jsDocChildren = ts.filter(current.getChildren(), ts.isJSDocNode); - for (var _i = 0, jsDocChildren_1 = jsDocChildren; _i < jsDocChildren_1.length; _i++) { - var jsDocChild = jsDocChildren_1[_i]; - var start = allowPositionInLeadingTrivia ? jsDocChild.getFullStart() : jsDocChild.getStart(sourceFile, includeJsDocComment); - if (start <= position) { - var end = jsDocChild.getEnd(); - if (position < end || (position === end && jsDocChild.kind === 1 /* EndOfFileToken */)) { - current = jsDocChild; - continue outer; - } - else if (includeItemAtEndPosition && end === position) { - var previousToken = findPrecedingToken(position, sourceFile, jsDocChild); - if (previousToken && includeItemAtEndPosition(previousToken)) { - return previousToken; - } - } - } - } - } // find the child that contains 'position' - for (var _a = 0, _b = current.getChildren(); _a < _b.length; _a++) { - var child = _b[_a]; - // all jsDocComment nodes were already visited - if (ts.isJSDocNode(child)) { + for (var _i = 0, _a = current.getChildren(); _i < _a.length; _i++) { + var child = _a[_i]; + if (!includeJsDocComment && ts.isJSDocNode(child)) { continue; } var start = allowPositionInLeadingTrivia ? child.getFullStart() : child.getStart(sourceFile, includeJsDocComment); - if (start <= position) { - var end = child.getEnd(); - if (position < end || (position === end && child.kind === 1 /* EndOfFileToken */)) { - current = child; - continue outer; - } - else if (includeItemAtEndPosition && end === position) { - var previousToken = findPrecedingToken(position, sourceFile, child); - if (previousToken && includeItemAtEndPosition(previousToken)) { - return previousToken; - } + if (start > position) { + continue; + } + var end = child.getEnd(); + if (position < end || (position === end && (child.kind === 1 /* EndOfFileToken */ || includeEndPosition))) { + current = child; + continue outer; + } + else if (includePrecedingTokenAtEndPosition && end === position) { + var previousToken = findPrecedingToken(position, sourceFile, child); + if (previousToken && includePrecedingTokenAtEndPosition(previousToken)) { + return previousToken; } } } @@ -70816,7 +73138,7 @@ var ts; function findTokenOnLeftOfPosition(file, position) { // Ideally, getTokenAtPosition should return a token. However, it is currently // broken, so we do a check to make sure the result was indeed a token. - var tokenAtPosition = getTokenAtPosition(file, position); + var tokenAtPosition = getTokenAtPosition(file, position, /*includeJsDocComment*/ false); if (ts.isToken(tokenAtPosition) && position > tokenAtPosition.getStart(file) && position < tokenAtPosition.getEnd()) { return tokenAtPosition; } @@ -70846,7 +73168,7 @@ var ts; } } ts.findNextToken = findNextToken; - function findPrecedingToken(position, sourceFile, startNode) { + function findPrecedingToken(position, sourceFile, startNode, includeJsDoc) { return find(startNode || sourceFile); function findRightmostToken(n) { if (ts.isToken(n)) { @@ -70872,7 +73194,7 @@ var ts; // NOTE: JsxText is a weird kind of node that can contain only whitespaces (since they are not counted as trivia). // if this is the case - then we should assume that token in question is located in previous child. if (position < child.end && (nodeHasTokens(child) || child.kind === 10 /* JsxText */)) { - var start = child.getStart(sourceFile); + var start = child.getStart(sourceFile, includeJsDoc); var lookInPreviousChild = (start >= position) || (child.kind === 10 /* JsxText */ && start === child.end); // whitespace only JsxText if (lookInPreviousChild) { @@ -70886,7 +73208,7 @@ var ts; } } } - ts.Debug.assert(startNode !== undefined || n.kind === 265 /* SourceFile */); + ts.Debug.assert(startNode !== undefined || n.kind === 265 /* SourceFile */ || ts.isJSDocCommentContainingNode(n)); // Here we know that none of child token nodes embrace the position, // the only known case is when position is at the end of the file. // Try to find the rightmost token in the file without filtering. @@ -70925,15 +73247,11 @@ var ts; return false; } ts.isInString = isInString; - function isInComment(sourceFile, position) { - return isInCommentHelper(sourceFile, position, /*predicate*/ undefined); - } - ts.isInComment = isInComment; /** * returns true if the position is in between the open and close elements of an JSX expression. */ function isInsideJsxElementOrAttribute(sourceFile, position) { - var token = getTokenAtPosition(sourceFile, position); + var token = getTokenAtPosition(sourceFile, position, /*includeJsDocComment*/ false); if (!token) { return false; } @@ -70962,18 +73280,32 @@ var ts; } ts.isInsideJsxElementOrAttribute = isInsideJsxElementOrAttribute; function isInTemplateString(sourceFile, position) { - var token = getTokenAtPosition(sourceFile, position); + var token = getTokenAtPosition(sourceFile, position, /*includeJsDocComment*/ false); return ts.isTemplateLiteralKind(token.kind) && position > token.getStart(sourceFile); } ts.isInTemplateString = isInTemplateString; /** - * Returns true if the cursor at position in sourceFile is within a comment that additionally - * satisfies predicate, and false otherwise. + * Returns true if the cursor at position in sourceFile is within a comment. + * + * @param tokenAtPosition Must equal `getTokenAtPosition(sourceFile, position) + * @param predicate Additional predicate to test on the comment range. */ - function isInCommentHelper(sourceFile, position, predicate) { - var token = getTokenAtPosition(sourceFile, position); - if (token && position <= token.getStart(sourceFile)) { - var commentRanges = ts.getLeadingCommentRanges(sourceFile.text, token.pos); + function isInComment(sourceFile, position, tokenAtPosition, predicate) { + if (tokenAtPosition === void 0) { tokenAtPosition = getTokenAtPosition(sourceFile, position, /*includeJsDocComment*/ false); } + return position <= tokenAtPosition.getStart(sourceFile) && + (isInCommentRange(ts.getLeadingCommentRanges(sourceFile.text, tokenAtPosition.pos)) || + isInCommentRange(ts.getTrailingCommentRanges(sourceFile.text, tokenAtPosition.pos))); + function isInCommentRange(commentRanges) { + return ts.forEach(commentRanges, function (c) { return isPositionInCommentRange(c, position, sourceFile.text) && (!predicate || predicate(c)); }); + } + } + ts.isInComment = isInComment; + function isPositionInCommentRange(_a, position, text) { + var pos = _a.pos, end = _a.end, kind = _a.kind; + if (pos < position && position < end) { + return true; + } + else if (position === end) { // The end marker of a single-line comment does not include the newline character. // In the following case, we are inside a comment (^ denotes the cursor position): // @@ -70984,18 +73316,16 @@ var ts; // /* asdf */^ // // Internally, we represent the end of the comment at the newline and closing '/', respectively. - return predicate ? - ts.forEach(commentRanges, function (c) { return c.pos < position && - (c.kind === 2 /* SingleLineCommentTrivia */ ? position <= c.end : position < c.end) && - predicate(c); }) : - ts.forEach(commentRanges, function (c) { return c.pos < position && - (c.kind === 2 /* SingleLineCommentTrivia */ ? position <= c.end : position < c.end); }); + return kind === 2 /* SingleLineCommentTrivia */ || + // true for unterminated multi-line comment + !(text.charCodeAt(end - 1) === 47 /* slash */ && text.charCodeAt(end - 2) === 42 /* asterisk */); + } + else { + return false; } - return false; } - ts.isInCommentHelper = isInCommentHelper; function hasDocComment(sourceFile, position) { - var token = getTokenAtPosition(sourceFile, position); + var token = getTokenAtPosition(sourceFile, position, /*includeJsDocComment*/ false); // First, we have to see if this position actually landed in a comment. var commentRanges = ts.getLeadingCommentRanges(sourceFile.text, token.pos); return ts.forEach(commentRanges, jsDocPrefix); @@ -71005,42 +73335,6 @@ var ts; } } ts.hasDocComment = hasDocComment; - /** - * Get the corresponding JSDocTag node if the position is in a jsDoc comment - */ - function getJsDocTagAtPosition(sourceFile, position) { - var node = ts.getTokenAtPosition(sourceFile, position); - if (ts.isToken(node)) { - switch (node.kind) { - case 104 /* VarKeyword */: - case 110 /* LetKeyword */: - case 76 /* ConstKeyword */: - // if the current token is var, let or const, skip the VariableDeclarationList - node = node.parent === undefined ? undefined : node.parent.parent; - break; - default: - node = node.parent; - break; - } - } - if (node) { - if (node.jsDoc) { - for (var _i = 0, _a = node.jsDoc; _i < _a.length; _i++) { - var jsDoc = _a[_i]; - if (jsDoc.tags) { - for (var _b = 0, _c = jsDoc.tags; _b < _c.length; _b++) { - var tag = _c[_b]; - if (tag.pos <= position && position <= tag.end) { - return tag; - } - } - } - } - } - } - return undefined; - } - ts.getJsDocTagAtPosition = getJsDocTagAtPosition; function nodeHasTokens(n) { // If we have a token or node that has a non-zero width, it must have tokens. // Note, that getWidth() does not take trivia into account. @@ -71167,25 +73461,27 @@ var ts; } ts.hasTrailingDirectorySeparator = hasTrailingDirectorySeparator; function isInReferenceComment(sourceFile, position) { - return isInCommentHelper(sourceFile, position, isReferenceComment); - function isReferenceComment(c) { + return isInComment(sourceFile, position, /*tokenAtPosition*/ undefined, function (c) { var commentText = sourceFile.text.substring(c.pos, c.end); return tripleSlashDirectivePrefixRegex.test(commentText); - } + }); } ts.isInReferenceComment = isInReferenceComment; function isInNonReferenceComment(sourceFile, position) { - return isInCommentHelper(sourceFile, position, isNonReferenceComment); - function isNonReferenceComment(c) { + return isInComment(sourceFile, position, /*tokenAtPosition*/ undefined, function (c) { var commentText = sourceFile.text.substring(c.pos, c.end); return !tripleSlashDirectivePrefixRegex.test(commentText); - } + }); } ts.isInNonReferenceComment = isInNonReferenceComment; function createTextSpanFromNode(node, sourceFile) { return ts.createTextSpanFromBounds(node.getStart(sourceFile), node.getEnd()); } ts.createTextSpanFromNode = createTextSpanFromNode; + function createTextSpanFromRange(range) { + return ts.createTextSpanFromBounds(range.pos, range.end); + } + ts.createTextSpanFromRange = createTextSpanFromRange; function isTypeKeyword(kind) { switch (kind) { case 119 /* AnyKeyword */: @@ -71247,7 +73543,7 @@ var ts; clear: resetWriter, trackSymbol: ts.noop, reportInaccessibleThisError: ts.noop, - reportIllegalExtends: ts.noop + reportPrivateInBaseOfClassExpression: ts.noop, }; function writeIndent() { if (lineStart) { @@ -71466,8 +73762,8 @@ var ts; // also, the emitted result will have "(" in the beginning and ");" in the end. We need to strip these // as well var trimmedOutput = outputText.trim(); - for (var _i = 0, diagnostics_2 = diagnostics; _i < diagnostics_2.length; _i++) { - var diagnostic = diagnostics_2[_i]; + for (var _i = 0, diagnostics_3 = diagnostics; _i < diagnostics_3.length; _i++) { + var diagnostic = diagnostics_3[_i]; diagnostic.start = diagnostic.start - 1; } var _b = ts.parseConfigFileTextToJson(configFileName, trimmedOutput.substring(1, trimmedOutput.length - 2), /*stripComments*/ false), config = _b.config, error = _b.error; @@ -71490,7 +73786,7 @@ var ts; } ts.getOpenBrace = getOpenBrace; function getOpenBraceOfClassLike(declaration, sourceFile) { - return ts.getTokenAtPosition(sourceFile, declaration.members.pos - 1); + return ts.getTokenAtPosition(sourceFile, declaration.members.pos - 1, /*includeJsDocComment*/ false); } ts.getOpenBraceOfClassLike = getOpenBraceOfClassLike; })(ts || (ts = {})); @@ -71562,7 +73858,7 @@ var ts; var lastEnd = 0; for (var i = 0; i < dense.length; i += 3) { var start = dense[i]; - var length_5 = dense[i + 1]; + var length_6 = dense[i + 1]; var type = dense[i + 2]; // Make a whitespace entry between the last item and this one. if (lastEnd >= 0) { @@ -71571,8 +73867,8 @@ var ts; entries.push({ length: whitespaceLength_1, classification: ts.TokenClass.Whitespace }); } } - entries.push({ length: length_5, classification: convertClassification(type) }); - lastEnd = start + length_5; + entries.push({ length: length_6, classification: convertClassification(type) }); + lastEnd = start + length_6; } var whitespaceLength = text.length - lastEnd; if (whitespaceLength > 0) { @@ -72112,9 +74408,9 @@ var ts; pushClassification(start, width, 1 /* comment */); continue; } - // for the ======== add a comment for the first line, and then lex all - // subsequent lines up until the end of the conflict marker. - ts.Debug.assert(ch === 61 /* equals */); + // for the ||||||| and ======== markers, add a comment for the first line, + // and then lex all subsequent lines up until the end of the conflict marker. + ts.Debug.assert(ch === 124 /* bar */ || ch === 61 /* equals */); classifyDisabledMergeCode(text, start, end); } } @@ -72146,20 +74442,20 @@ var ts; if (tag.pos !== pos) { pushCommentRange(pos, tag.pos - pos); } - pushClassification(tag.atToken.pos, tag.atToken.end - tag.atToken.pos, 10 /* punctuation */); - pushClassification(tag.tagName.pos, tag.tagName.end - tag.tagName.pos, 18 /* docCommentTagName */); + pushClassification(tag.atToken.pos, tag.atToken.end - tag.atToken.pos, 10 /* punctuation */); // "@" + pushClassification(tag.tagName.pos, tag.tagName.end - tag.tagName.pos, 18 /* docCommentTagName */); // e.g. "param" pos = tag.tagName.end; switch (tag.kind) { - case 286 /* JSDocParameterTag */: + case 287 /* JSDocParameterTag */: processJSDocParameterTag(tag); break; - case 289 /* JSDocTemplateTag */: + case 290 /* JSDocTemplateTag */: processJSDocTemplateTag(tag); break; - case 288 /* JSDocTypeTag */: + case 289 /* JSDocTypeTag */: processElement(tag.typeExpression); break; - case 287 /* JSDocReturnTag */: + case 288 /* JSDocReturnTag */: processElement(tag.typeExpression); break; } @@ -72195,8 +74491,8 @@ var ts; } } function classifyDisabledMergeCode(text, start, end) { - // Classify the line that the ======= marker is on as a comment. Then just lex - // all further tokens and add them to the result. + // Classify the line that the ||||||| or ======= marker is on as a comment. + // Then just lex all further tokens and add them to the result. var i; for (i = start; i < end; i++) { if (ts.isLineBreak(text.charCodeAt(i))) { @@ -72223,7 +74519,7 @@ var ts; * False will mean that node is not classified and traverse routine should recurse into node contents. */ function tryClassifyNode(node) { - if (ts.isJSDocTag(node)) { + if (ts.isJSDoc(node)) { return true; } if (ts.nodeIsMissing(node)) { @@ -72581,8 +74877,8 @@ var ts; continue; } var start = completePrefix.length; - var length_6 = normalizedMatch.length - start - normalizedSuffix.length; - result.push(ts.removeFileExtension(normalizedMatch.substr(start, length_6))); + var length_7 = normalizedMatch.length - start - normalizedSuffix.length; + result.push(ts.removeFileExtension(normalizedMatch.substr(start, length_7))); } return result; } @@ -72596,24 +74892,21 @@ var ts; var moduleNameFragment = isNestedModule ? fragment.substr(0, fragment.lastIndexOf(ts.directorySeparator)) : undefined; // Get modules that the type checker picked up var ambientModules = ts.map(typeChecker.getAmbientModules(), function (sym) { return ts.stripQuotes(sym.name); }); - var nonRelativeModules = ts.filter(ambientModules, function (moduleName) { return ts.startsWith(moduleName, fragment); }); + var nonRelativeModuleNames = ts.filter(ambientModules, function (moduleName) { return ts.startsWith(moduleName, fragment); }); // Nested modules of the form "module-name/sub" need to be adjusted to only return the string // after the last '/' that appears in the fragment because that's where the replacement span // starts if (isNestedModule) { var moduleNameWithSeperator_1 = ts.ensureTrailingDirectorySeparator(moduleNameFragment); - nonRelativeModules = ts.map(nonRelativeModules, function (moduleName) { - if (ts.startsWith(fragment, moduleNameWithSeperator_1)) { - return moduleName.substr(moduleNameWithSeperator_1.length); - } - return moduleName; + nonRelativeModuleNames = ts.map(nonRelativeModuleNames, function (nonRelativeModuleName) { + return ts.removePrefix(nonRelativeModuleName, moduleNameWithSeperator_1); }); } if (!options.moduleResolution || options.moduleResolution === ts.ModuleResolutionKind.NodeJs) { for (var _i = 0, _a = enumerateNodeModulesVisibleToScript(host, scriptPath); _i < _a.length; _i++) { var visibleModule = _a[_i]; if (!isNestedModule) { - nonRelativeModules.push(visibleModule.moduleName); + nonRelativeModuleNames.push(visibleModule.moduleName); } else if (ts.startsWith(visibleModule.moduleName, moduleNameFragment)) { var nestedFiles = tryReadDirectory(host, visibleModule.moduleDir, ts.supportedTypeScriptExtensions, /*exclude*/ undefined, /*include*/ ["./*"]); @@ -72622,16 +74915,16 @@ var ts; var f = nestedFiles_1[_b]; f = ts.normalizePath(f); var nestedModule = ts.removeFileExtension(ts.getBaseFileName(f)); - nonRelativeModules.push(nestedModule); + nonRelativeModuleNames.push(nestedModule); } } } } } - return ts.deduplicate(nonRelativeModules); + return ts.deduplicate(nonRelativeModuleNames); } function getTripleSlashReferenceCompletion(sourceFile, position, compilerOptions, host) { - var token = ts.getTokenAtPosition(sourceFile, position); + var token = ts.getTokenAtPosition(sourceFile, position, /*includeJsDocComment*/ false); if (!token) { return undefined; } @@ -72873,14 +75166,29 @@ var ts; if (!completionData) { return undefined; } - var symbols = completionData.symbols, isGlobalCompletion = completionData.isGlobalCompletion, isMemberCompletion = completionData.isMemberCompletion, isNewIdentifierLocation = completionData.isNewIdentifierLocation, location = completionData.location, requestJsDocTagName = completionData.requestJsDocTagName, requestJsDocTag = completionData.requestJsDocTag; - if (requestJsDocTagName) { - // If the current position is a jsDoc tag name, only tag names should be provided for completion - return { isGlobalCompletion: false, isMemberCompletion: false, isNewIdentifierLocation: false, entries: ts.JsDoc.getJSDocTagNameCompletions() }; + var symbols = completionData.symbols, isGlobalCompletion = completionData.isGlobalCompletion, isMemberCompletion = completionData.isMemberCompletion, isNewIdentifierLocation = completionData.isNewIdentifierLocation, location = completionData.location, request = completionData.request, hasFilteredClassMemberKeywords = completionData.hasFilteredClassMemberKeywords; + if (sourceFile.languageVariant === 1 /* JSX */ && + location && location.parent && location.parent.kind === 252 /* JsxClosingElement */) { + // In the TypeScript JSX element, if such element is not defined. When users query for completion at closing tag, + // instead of simply giving unknown value, the completion will return the tag-name of an associated opening-element. + // For example: + // var x =
completion list at "1" will contain "div" with type any + var tagName = location.parent.parent.openingElement.tagName; + return { isGlobalCompletion: false, isMemberCompletion: true, isNewIdentifierLocation: false, + entries: [{ + name: tagName.getFullText(), + kind: ts.ScriptElementKind.classElement, + kindModifiers: undefined, + sortText: "0", + }] }; } - if (requestJsDocTag) { - // If the current position is a jsDoc tag, only tags should be provided for completion - return { isGlobalCompletion: false, isMemberCompletion: false, isNewIdentifierLocation: false, entries: ts.JsDoc.getJSDocTagCompletions() }; + if (request) { + var entries_2 = request.kind === "JsDocTagName" + ? ts.JsDoc.getJSDocTagNameCompletions() + : request.kind === "JsDocTag" + ? ts.JsDoc.getJSDocTagCompletions() + : ts.JsDoc.getJSDocParameterNameCompletions(request.tag); + return { isGlobalCompletion: false, isMemberCompletion: false, isNewIdentifierLocation: false, entries: entries_2 }; } var entries = []; if (ts.isSourceFileJavaScript(sourceFile)) { @@ -72889,28 +75197,16 @@ var ts; } else { if (!symbols || symbols.length === 0) { - if (sourceFile.languageVariant === 1 /* JSX */ && - location.parent && location.parent.kind === 252 /* JsxClosingElement */) { - // In the TypeScript JSX element, if such element is not defined. When users query for completion at closing tag, - // instead of simply giving unknown value, the completion will return the tag-name of an associated opening-element. - // For example: - // var x =
completion list at "1" will contain "div" with type any - var tagName = location.parent.parent.openingElement.tagName; - entries.push({ - name: tagName.text, - kind: undefined, - kindModifiers: undefined, - sortText: "0", - }); - } - else { + if (!hasFilteredClassMemberKeywords) { return undefined; } } getCompletionEntriesFromSymbols(symbols, entries, location, /*performCharacterChecks*/ true, typeChecker, compilerOptions.target, log); } - // Add keywords if this is not a member completion list - if (!isMemberCompletion && !requestJsDocTag && !requestJsDocTagName) { + if (hasFilteredClassMemberKeywords) { + ts.addRange(entries, classMemberKeywordCompletions); + } + else if (!isMemberCompletion) { ts.addRange(entries, keywordCompletions); } return { isGlobalCompletion: isGlobalCompletion, isMemberCompletion: isMemberCompletion, isNewIdentifierLocation: isNewIdentifierLocation, entries: entries }; @@ -72966,8 +75262,8 @@ var ts; var start = ts.timestamp(); var uniqueNames = ts.createMap(); if (symbols) { - for (var _i = 0, symbols_4 = symbols; _i < symbols_4.length; _i++) { - var symbol = symbols_4[_i]; + for (var _i = 0, symbols_5 = symbols; _i < symbols_5.length; _i++) { + var symbol = symbols_5[_i]; var entry = createCompletionEntry(symbol, location, performCharacterChecks, typeChecker, target); if (entry) { var id = ts.escapeIdentifier(entry.name); @@ -73057,10 +75353,11 @@ var ts; function getStringLiteralCompletionEntriesFromCallExpression(argumentInfo, typeChecker) { var candidates = []; var entries = []; + var uniques = ts.createMap(); typeChecker.getResolvedSignature(argumentInfo.invocation, candidates); for (var _i = 0, candidates_3 = candidates; _i < candidates_3.length; _i++) { var candidate = candidates_3[_i]; - addStringLiteralCompletionsFromType(typeChecker.getParameterType(candidate, argumentInfo.argumentIndex), entries, typeChecker); + addStringLiteralCompletionsFromType(typeChecker.getParameterType(candidate, argumentInfo.argumentIndex), entries, typeChecker, uniques); } if (entries.length) { return { isGlobalCompletion: false, isMemberCompletion: false, isNewIdentifierLocation: true, entries: entries }; @@ -73088,9 +75385,10 @@ var ts; } return undefined; } - function addStringLiteralCompletionsFromType(type, result, typeChecker) { + function addStringLiteralCompletionsFromType(type, result, typeChecker, uniques) { + if (uniques === void 0) { uniques = ts.createMap(); } if (type && type.flags & 16384 /* TypeParameter */) { - type = typeChecker.getApparentType(type); + type = typeChecker.getBaseConstraintOfType(type); } if (!type) { return; @@ -73098,16 +75396,20 @@ var ts; if (type.flags & 65536 /* Union */) { for (var _i = 0, _a = type.types; _i < _a.length; _i++) { var t = _a[_i]; - addStringLiteralCompletionsFromType(t, result, typeChecker); + addStringLiteralCompletionsFromType(t, result, typeChecker, uniques); } } else if (type.flags & 32 /* StringLiteral */) { - result.push({ - name: type.text, - kindModifiers: ts.ScriptElementKindModifier.none, - kind: ts.ScriptElementKind.variableElement, - sortText: "0" - }); + var name = type.value; + if (!uniques.has(name)) { + uniques.set(name, true); + result.push({ + name: name, + kindModifiers: ts.ScriptElementKindModifier.none, + kind: ts.ScriptElementKind.variableElement, + sortText: "0" + }); + } } } function getCompletionEntryDetails(typeChecker, log, compilerOptions, sourceFile, position, entryName) { @@ -73163,23 +75465,22 @@ var ts; Completions.getCompletionEntrySymbol = getCompletionEntrySymbol; function getCompletionData(typeChecker, log, sourceFile, position) { var isJavaScriptFile = ts.isSourceFileJavaScript(sourceFile); - // JsDoc tag-name is just the name of the JSDoc tagname (exclude "@") - var requestJsDocTagName = false; - // JsDoc tag includes both "@" and tag-name - var requestJsDocTag = false; + var request; var start = ts.timestamp(); - var currentToken = ts.getTokenAtPosition(sourceFile, position); + var currentToken = ts.getTokenAtPosition(sourceFile, position, /*includeJsDocComment*/ false); + // We will check for jsdoc comments with insideComment and getJsDocTagAtPosition. (TODO: that seems rather inefficient to check the same thing so many times.) log("getCompletionData: Get current token: " + (ts.timestamp() - start)); start = ts.timestamp(); // Completion not allowed inside comments, bail out if this is the case - var insideComment = ts.isInsideComment(sourceFile, currentToken, position); + var insideComment = ts.isInComment(sourceFile, position, currentToken); log("getCompletionData: Is inside comment: " + (ts.timestamp() - start)); + var insideJsDocTagTypeExpression = false; if (insideComment) { if (ts.hasDocComment(sourceFile, position)) { - // The current position is next to the '@' sign, when no tag name being provided yet. - // Provide a full list of tag names if (sourceFile.text.charCodeAt(position - 1) === 64 /* at */) { - requestJsDocTagName = true; + // The current position is next to the '@' sign, when no tag name being provided yet. + // Provide a full list of tag names + request = { kind: "JsDocTagName" }; } else { // When completion is requested without "@", we will have check to make sure that @@ -73199,33 +75500,37 @@ var ts; // * |c| // */ var lineStart = ts.getLineStartPositionForPosition(position, sourceFile); - requestJsDocTag = !(sourceFile.text.substring(lineStart, position).match(/[^\*|\s|(/\*\*)]/)); + if (!(sourceFile.text.substring(lineStart, position).match(/[^\*|\s|(/\*\*)]/))) { + request = { kind: "JsDocTag" }; + } } } // Completion should work inside certain JsDoc tags. For example: // /** @type {number | string} */ // Completion should work in the brackets - var insideJsDocTagExpression = false; - var tag = ts.getJsDocTagAtPosition(sourceFile, position); + var tag = getJsDocTagAtPosition(currentToken, position); if (tag) { if (tag.tagName.pos <= position && position <= tag.tagName.end) { - requestJsDocTagName = true; + request = { kind: "JsDocTagName" }; } - switch (tag.kind) { - case 288 /* JSDocTypeTag */: - case 286 /* JSDocParameterTag */: - case 287 /* JSDocReturnTag */: - var tagWithExpression = tag; - if (tagWithExpression.typeExpression) { - insideJsDocTagExpression = tagWithExpression.typeExpression.pos < position && position < tagWithExpression.typeExpression.end; - } - break; + if (isTagWithTypeExpression(tag) && tag.typeExpression) { + currentToken = ts.getTokenAtPosition(sourceFile, position, /*includeJsDocComment*/ true); + if (!currentToken || + (!ts.isDeclarationName(currentToken) && + (currentToken.parent.kind !== 292 /* JSDocPropertyTag */ || + currentToken.parent.name !== currentToken))) { + // Use as type location if inside tag's type expression + insideJsDocTagTypeExpression = isCurrentlyEditingNode(tag.typeExpression); + } + } + if (ts.isJSDocParameterTag(tag) && (ts.nodeIsMissing(tag.name) || tag.name.pos <= position && position <= tag.name.end)) { + request = { kind: "JsDocParameterName", tag: tag }; } } - if (requestJsDocTagName || requestJsDocTag) { - return { symbols: undefined, isGlobalCompletion: false, isMemberCompletion: false, isNewIdentifierLocation: false, location: undefined, isRightOfDot: false, requestJsDocTagName: requestJsDocTagName, requestJsDocTag: requestJsDocTag }; + if (request) { + return { symbols: undefined, isGlobalCompletion: false, isMemberCompletion: false, isNewIdentifierLocation: false, location: undefined, isRightOfDot: false, request: request, hasFilteredClassMemberKeywords: false }; } - if (!insideJsDocTagExpression) { + if (!insideJsDocTagTypeExpression) { // Proceed if the current position is in jsDoc tag expression; otherwise it is a normal // comment or the plain text part of a jsDoc comment, so no completion should be available log("Returning an empty list because completion was inside a regular comment or plain text part of a JsDoc comment."); @@ -73233,7 +75538,7 @@ var ts; } } start = ts.timestamp(); - var previousToken = ts.findPrecedingToken(position, sourceFile); + var previousToken = ts.findPrecedingToken(position, sourceFile, /*startNode*/ undefined, insideJsDocTagTypeExpression); log("getCompletionData: Get previous token 1: " + (ts.timestamp() - start)); // The decision to provide completion depends on the contextToken, which is determined through the previousToken. // Note: 'previousToken' (and thus 'contextToken') can be undefined if we are the beginning of the file @@ -73242,7 +75547,7 @@ var ts; // Skip this partial identifier and adjust the contextToken to the token that precedes it. if (contextToken && position <= contextToken.end && ts.isWord(contextToken.kind)) { var start_2 = ts.timestamp(); - contextToken = ts.findPrecedingToken(contextToken.getFullStart(), sourceFile); + contextToken = ts.findPrecedingToken(contextToken.getFullStart(), sourceFile, /*startNode*/ undefined, insideJsDocTagTypeExpression); log("getCompletionData: Get previous token 2: " + (ts.timestamp() - start_2)); } // Find the node where completion is requested on. @@ -73252,7 +75557,7 @@ var ts; var isRightOfDot = false; var isRightOfOpenTag = false; var isStartingCloseTag = false; - var location = ts.getTouchingPropertyName(sourceFile, position); + var location = ts.getTouchingPropertyName(sourceFile, position, insideJsDocTagTypeExpression); // TODO: GH#15853 if (contextToken) { // Bail out if this is a known invalid completion location if (isCompletionListBlocker(contextToken)) { @@ -73311,6 +75616,7 @@ var ts; var isGlobalCompletion = false; var isMemberCompletion; var isNewIdentifierLocation; + var hasFilteredClassMemberKeywords = false; var symbols = []; if (isRightOfDot) { getTypeScriptMemberSymbols(); @@ -73344,12 +75650,26 @@ var ts; } } log("getCompletionData: Semantic work: " + (ts.timestamp() - semanticStart)); - return { symbols: symbols, isGlobalCompletion: isGlobalCompletion, isMemberCompletion: isMemberCompletion, isNewIdentifierLocation: isNewIdentifierLocation, location: location, isRightOfDot: (isRightOfDot || isRightOfOpenTag), requestJsDocTagName: requestJsDocTagName, requestJsDocTag: requestJsDocTag }; + return { symbols: symbols, isGlobalCompletion: isGlobalCompletion, isMemberCompletion: isMemberCompletion, isNewIdentifierLocation: isNewIdentifierLocation, location: location, isRightOfDot: (isRightOfDot || isRightOfOpenTag), request: request, hasFilteredClassMemberKeywords: hasFilteredClassMemberKeywords }; + function isTagWithTypeExpression(tag) { + switch (tag.kind) { + case 285 /* JSDocAugmentsTag */: + case 287 /* JSDocParameterTag */: + case 292 /* JSDocPropertyTag */: + case 288 /* JSDocReturnTag */: + case 289 /* JSDocTypeTag */: + case 291 /* JSDocTypedefTag */: + return true; + } + } function getTypeScriptMemberSymbols() { // Right of dot member completion list isGlobalCompletion = false; isMemberCompletion = true; isNewIdentifierLocation = false; + // Since this is qualified name check its a type node location + var isTypeLocation = ts.isPartOfTypeNode(node.parent) || insideJsDocTagTypeExpression; + var isRhsOfImportDeclaration = ts.isInRightSideOfInternalImportEqualsDeclaration(node); if (node.kind === 71 /* Identifier */ || node.kind === 143 /* QualifiedName */ || node.kind === 179 /* PropertyAccessExpression */) { var symbol = typeChecker.getSymbolAtLocation(node); // This is an alias, follow what it aliases @@ -73359,15 +75679,23 @@ var ts; if (symbol && symbol.flags & 1952 /* HasExports */) { // Extract module or enum members var exportedSymbols = typeChecker.getExportsOfModule(symbol); + var isValidValueAccess_1 = function (symbol) { return typeChecker.isValidPropertyAccess((node.parent), symbol.name); }; + var isValidTypeAccess_1 = function (symbol) { return symbolCanbeReferencedAtTypeLocation(symbol); }; + var isValidAccess_1 = isRhsOfImportDeclaration ? + // Any kind is allowed when dotting off namespace in internal import equals declaration + function (symbol) { return isValidTypeAccess_1(symbol) || isValidValueAccess_1(symbol); } : + isTypeLocation ? isValidTypeAccess_1 : isValidValueAccess_1; ts.forEach(exportedSymbols, function (symbol) { - if (typeChecker.isValidPropertyAccess((node.parent), symbol.name)) { + if (isValidAccess_1(symbol)) { symbols.push(symbol); } }); } } - var type = typeChecker.getTypeAtLocation(node); - addTypeProperties(type); + if (!isTypeLocation) { + var type = typeChecker.getTypeAtLocation(node); + addTypeProperties(type); + } } function addTypeProperties(type) { if (type) { @@ -73395,6 +75723,7 @@ var ts; function tryGetGlobalSymbols() { var objectLikeContainer; var namedImportsOrExports; + var classLikeContainer; var jsxContainer; if (objectLikeContainer = tryGetObjectLikeCompletionContainer(contextToken)) { return tryGetObjectLikeCompletionSymbols(objectLikeContainer); @@ -73404,6 +75733,11 @@ var ts; // try to show exported member for imported module return tryGetImportOrExportClauseCompletionSymbols(namedImportsOrExports); } + if (classLikeContainer = tryGetClassLikeCompletionContainer(contextToken)) { + // cursor inside class declaration + getGetClassLikeCompletionSymbols(classLikeContainer); + return true; + } if (jsxContainer = tryGetContainingJsxElement(contextToken)) { var attrsType = void 0; if ((jsxContainer.kind === 250 /* JsxSelfClosingElement */) || (jsxContainer.kind === 251 /* JsxOpeningElement */)) { @@ -73459,11 +75793,73 @@ var ts; scopeNode.kind === 256 /* JsxExpression */ || ts.isStatement(scopeNode); } - /// TODO filter meaning based on the current context var symbolMeanings = 793064 /* Type */ | 107455 /* Value */ | 1920 /* Namespace */ | 8388608 /* Alias */; - symbols = typeChecker.getSymbolsInScope(scopeNode, symbolMeanings); + symbols = filterGlobalCompletion(typeChecker.getSymbolsInScope(scopeNode, symbolMeanings)); return true; } + function filterGlobalCompletion(symbols) { + return ts.filter(symbols, function (symbol) { + if (!ts.isSourceFile(location)) { + // export = /**/ here we want to get all meanings, so any symbol is ok + if (ts.isExportAssignment(location.parent)) { + return true; + } + // This is an alias, follow what it aliases + if (symbol && symbol.flags & 8388608 /* Alias */) { + symbol = typeChecker.getAliasedSymbol(symbol); + } + // import m = /**/ <-- It can only access namespace (if typing import = x. this would get member symbols and not namespace) + if (ts.isInRightSideOfInternalImportEqualsDeclaration(location)) { + return !!(symbol.flags & 1920 /* Namespace */); + } + if (insideJsDocTagTypeExpression || + (!isContextTokenValueLocation(contextToken) && + (ts.isPartOfTypeNode(location) || isContextTokenTypeLocation(contextToken)))) { + // Its a type, but you can reach it by namespace.type as well + return symbolCanbeReferencedAtTypeLocation(symbol); + } + } + // expressions are value space (which includes the value namespaces) + return !!(symbol.flags & 107455 /* Value */); + }); + } + function isContextTokenValueLocation(contextToken) { + return contextToken && + contextToken.kind === 103 /* TypeOfKeyword */ && + contextToken.parent.kind === 162 /* TypeQuery */; + } + function isContextTokenTypeLocation(contextToken) { + if (contextToken) { + var parentKind = contextToken.parent.kind; + switch (contextToken.kind) { + case 56 /* ColonToken */: + return parentKind === 149 /* PropertyDeclaration */ || + parentKind === 148 /* PropertySignature */ || + parentKind === 146 /* Parameter */ || + parentKind === 226 /* VariableDeclaration */ || + ts.isFunctionLikeKind(parentKind); + case 58 /* EqualsToken */: + return parentKind === 231 /* TypeAliasDeclaration */; + case 118 /* AsKeyword */: + return parentKind === 202 /* AsExpression */; + } + } + } + function symbolCanbeReferencedAtTypeLocation(symbol) { + // This is an alias, follow what it aliases + if (symbol && symbol.flags & 8388608 /* Alias */) { + symbol = typeChecker.getAliasedSymbol(symbol); + } + if (symbol.flags & 793064 /* Type */) { + return true; + } + if (symbol.flags & (512 /* ValueModule */ | 1024 /* NamespaceModule */)) { + var exportedSymbols = typeChecker.getExportsOfModule(symbol); + // If the exported symbols contains type, + // symbol can be referenced at locations where type is allowed + return ts.forEach(exportedSymbols, symbolCanbeReferencedAtTypeLocation); + } + } /** * Finds the first node that "embraces" the position, so that one may * accurately aggregate locals from the closest containing scope. @@ -73520,7 +75916,7 @@ var ts; || containingNodeKind === 157 /* IndexSignature */ // [ | : string ] || containingNodeKind === 144 /* ComputedPropertyName */; // [ | /* this can become an index signature */ case 128 /* ModuleKeyword */: // module | - case 129 /* NamespaceKeyword */: + case 129 /* NamespaceKeyword */:// namespace | return true; case 23 /* DotToken */: return containingNodeKind === 233 /* ModuleDeclaration */; // module A.| @@ -73577,53 +75973,48 @@ var ts; function tryGetObjectLikeCompletionSymbols(objectLikeContainer) { // We're looking up possible property names from contextual/inferred/declared type. isMemberCompletion = true; - var typeForObject; + var typeMembers; var existingMembers; if (objectLikeContainer.kind === 178 /* ObjectLiteralExpression */) { // We are completing on contextual types, but may also include properties // other than those within the declared type. isNewIdentifierLocation = true; - // If the object literal is being assigned to something of type 'null | { hello: string }', - // it clearly isn't trying to satisfy the 'null' type. So we grab the non-nullable type if possible. - typeForObject = typeChecker.getContextualType(objectLikeContainer); - typeForObject = typeForObject && typeForObject.getNonNullableType(); + var typeForObject = typeChecker.getContextualType(objectLikeContainer); + if (!typeForObject) + return false; + typeMembers = typeChecker.getAllPossiblePropertiesOfType(typeForObject); existingMembers = objectLikeContainer.properties; } - else if (objectLikeContainer.kind === 174 /* ObjectBindingPattern */) { + else { + ts.Debug.assert(objectLikeContainer.kind === 174 /* ObjectBindingPattern */); // We are *only* completing on properties from the type being destructured. isNewIdentifierLocation = false; var rootDeclaration = ts.getRootDeclaration(objectLikeContainer.parent); - if (ts.isVariableLike(rootDeclaration)) { - // We don't want to complete using the type acquired by the shape - // of the binding pattern; we are only interested in types acquired - // through type declaration or inference. - // Also proceed if rootDeclaration is a parameter and if its containing function expression/arrow function is contextually typed - - // type of parameter will flow in from the contextual type of the function - var canGetType = !!(rootDeclaration.initializer || rootDeclaration.type); - if (!canGetType && rootDeclaration.kind === 146 /* Parameter */) { - if (ts.isExpression(rootDeclaration.parent)) { - canGetType = !!typeChecker.getContextualType(rootDeclaration.parent); - } - else if (rootDeclaration.parent.kind === 151 /* MethodDeclaration */ || rootDeclaration.parent.kind === 154 /* SetAccessor */) { - canGetType = ts.isExpression(rootDeclaration.parent.parent) && !!typeChecker.getContextualType(rootDeclaration.parent.parent); - } - } - if (canGetType) { - typeForObject = typeChecker.getTypeAtLocation(objectLikeContainer); - existingMembers = objectLikeContainer.elements; - } - } - else { - ts.Debug.fail("Root declaration is not variable-like."); + if (!ts.isVariableLike(rootDeclaration)) + throw ts.Debug.fail("Root declaration is not variable-like."); + // We don't want to complete using the type acquired by the shape + // of the binding pattern; we are only interested in types acquired + // through type declaration or inference. + // Also proceed if rootDeclaration is a parameter and if its containing function expression/arrow function is contextually typed - + // type of parameter will flow in from the contextual type of the function + var canGetType = rootDeclaration.initializer || rootDeclaration.type || rootDeclaration.parent.parent.kind === 216 /* ForOfStatement */; + if (!canGetType && rootDeclaration.kind === 146 /* Parameter */) { + if (ts.isExpression(rootDeclaration.parent)) { + canGetType = !!typeChecker.getContextualType(rootDeclaration.parent); + } + else if (rootDeclaration.parent.kind === 151 /* MethodDeclaration */ || rootDeclaration.parent.kind === 154 /* SetAccessor */) { + canGetType = ts.isExpression(rootDeclaration.parent.parent) && !!typeChecker.getContextualType(rootDeclaration.parent.parent); + } + } + if (canGetType) { + var typeForObject = typeChecker.getTypeAtLocation(objectLikeContainer); + if (!typeForObject) + return false; + // In a binding pattern, get only known properties. Everywhere else we will get all possible properties. + typeMembers = typeChecker.getPropertiesOfType(typeForObject); + existingMembers = objectLikeContainer.elements; } } - else { - ts.Debug.fail("Expected object literal or binding pattern, got " + objectLikeContainer.kind); - } - if (!typeForObject) { - return false; - } - var typeMembers = typeChecker.getPropertiesOfType(typeForObject); if (typeMembers && typeMembers.length > 0) { // Add filtered items to the completion list symbols = filterObjectMembersList(typeMembers, existingMembers); @@ -73665,6 +76056,53 @@ var ts; symbols = filterNamedImportOrExportCompletionItems(exports, namedImportsOrExports.elements); return true; } + /** + * Aggregates relevant symbols for completion in class declaration + * Relevant symbols are stored in the captured 'symbols' variable. + */ + function getGetClassLikeCompletionSymbols(classLikeDeclaration) { + // We're looking up possible property names from parent type. + isMemberCompletion = true; + // Declaring new property/method/accessor + isNewIdentifierLocation = true; + // Has keywords for class elements + hasFilteredClassMemberKeywords = true; + var baseTypeNode = ts.getClassExtendsHeritageClauseElement(classLikeDeclaration); + var implementsTypeNodes = ts.getClassImplementsHeritageClauseElements(classLikeDeclaration); + if (baseTypeNode || implementsTypeNodes) { + var classElement = contextToken.parent; + var classElementModifierFlags = ts.isClassElement(classElement) && ts.getModifierFlags(classElement); + // If this is context token is not something we are editing now, consider if this would lead to be modifier + if (contextToken.kind === 71 /* Identifier */ && !isCurrentlyEditingNode(contextToken)) { + switch (contextToken.getText()) { + case "private": + classElementModifierFlags = classElementModifierFlags | 8 /* Private */; + break; + case "static": + classElementModifierFlags = classElementModifierFlags | 32 /* Static */; + break; + } + } + // No member list for private methods + if (!(classElementModifierFlags & 8 /* Private */)) { + var baseClassTypeToGetPropertiesFrom = void 0; + if (baseTypeNode) { + baseClassTypeToGetPropertiesFrom = typeChecker.getTypeAtLocation(baseTypeNode); + if (classElementModifierFlags & 32 /* Static */) { + // Use static class to get property symbols from + baseClassTypeToGetPropertiesFrom = typeChecker.getTypeOfSymbolAtLocation(baseClassTypeToGetPropertiesFrom.symbol, classLikeDeclaration); + } + } + var implementedInterfaceTypePropertySymbols = (classElementModifierFlags & 32 /* Static */) ? + undefined : + ts.flatMap(implementsTypeNodes, function (typeNode) { return typeChecker.getPropertiesOfType(typeChecker.getTypeAtLocation(typeNode)); }); + // List of property symbols of base type that are not private and already implemented + symbols = filterClassMembersList(baseClassTypeToGetPropertiesFrom ? + typeChecker.getPropertiesOfType(baseClassTypeToGetPropertiesFrom) : + undefined, implementedInterfaceTypePropertySymbols, classLikeDeclaration.members, classElementModifierFlags); + } + } + } /** * Returns the immediate owning object literal or binding pattern of a context token, * on the condition that one exists and that the context implies completion should be given. @@ -73673,9 +76111,9 @@ var ts; if (contextToken) { switch (contextToken.kind) { case 17 /* OpenBraceToken */: // const x = { | - case 26 /* CommaToken */: + case 26 /* CommaToken */:// const x = { a: 0, | var parent = contextToken.parent; - if (parent && (parent.kind === 178 /* ObjectLiteralExpression */ || parent.kind === 174 /* ObjectBindingPattern */)) { + if (ts.isObjectLiteralExpression(parent) || ts.isObjectBindingPattern(parent)) { return parent; } break; @@ -73691,7 +76129,7 @@ var ts; if (contextToken) { switch (contextToken.kind) { case 17 /* OpenBraceToken */: // import { | - case 26 /* CommaToken */: + case 26 /* CommaToken */:// import { a as 0, | switch (contextToken.parent.kind) { case 241 /* NamedImports */: case 245 /* NamedExports */: @@ -73701,6 +76139,44 @@ var ts; } return undefined; } + function isFromClassElementDeclaration(node) { + return ts.isClassElement(node.parent) && ts.isClassLike(node.parent.parent); + } + /** + * Returns the immediate owning class declaration of a context token, + * on the condition that one exists and that the context implies completion should be given. + */ + function tryGetClassLikeCompletionContainer(contextToken) { + if (contextToken) { + switch (contextToken.kind) { + case 17 /* OpenBraceToken */:// class c { | + if (ts.isClassLike(contextToken.parent)) { + return contextToken.parent; + } + break; + // class c {getValue(): number; | } + case 26 /* CommaToken */: + case 25 /* SemicolonToken */: + // class c { method() { } | } + case 18 /* CloseBraceToken */: + if (ts.isClassLike(location)) { + return location; + } + break; + default: + if (isFromClassElementDeclaration(contextToken) && + (isClassMemberCompletionKeyword(contextToken.kind) || + isClassMemberCompletionKeywordText(contextToken.getText()))) { + return contextToken.parent.parent; + } + } + } + // class c { method() { } | method2() { } } + if (location && location.kind === 295 /* SyntaxList */ && ts.isClassLike(location.parent)) { + return location.parent; + } + return undefined; + } function tryGetContainingJsxElement(contextToken) { if (contextToken) { var parent = contextToken.parent; @@ -73758,19 +76234,6 @@ var ts; } return undefined; } - function isFunction(kind) { - if (!ts.isFunctionLikeKind(kind)) { - return false; - } - switch (kind) { - case 152 /* Constructor */: - case 161 /* ConstructorType */: - case 160 /* FunctionType */: - return false; - default: - return true; - } - } /** * @returns true if we are certain that the currently edited location must define a new location; false otherwise. */ @@ -73782,7 +76245,7 @@ var ts; containingNodeKind === 227 /* VariableDeclarationList */ || containingNodeKind === 208 /* VariableStatement */ || containingNodeKind === 232 /* EnumDeclaration */ || - isFunction(containingNodeKind) || + isFunctionLikeButNotConstructor(containingNodeKind) || containingNodeKind === 229 /* ClassDeclaration */ || containingNodeKind === 199 /* ClassExpression */ || containingNodeKind === 230 /* InterfaceDeclaration */ || @@ -73796,7 +76259,7 @@ var ts; return containingNodeKind === 175 /* ArrayBindingPattern */; // var [x| case 19 /* OpenParenToken */: return containingNodeKind === 260 /* CatchClause */ || - isFunction(containingNodeKind); + isFunctionLikeButNotConstructor(containingNodeKind); case 17 /* OpenBraceToken */: return containingNodeKind === 232 /* EnumDeclaration */ || containingNodeKind === 230 /* InterfaceDeclaration */ || @@ -73811,9 +76274,9 @@ var ts; containingNodeKind === 199 /* ClassExpression */ || containingNodeKind === 230 /* InterfaceDeclaration */ || containingNodeKind === 231 /* TypeAliasDeclaration */ || - isFunction(containingNodeKind); + ts.isFunctionLikeKind(containingNodeKind); case 115 /* StaticKeyword */: - return containingNodeKind === 149 /* PropertyDeclaration */; + return containingNodeKind === 149 /* PropertyDeclaration */ && !ts.isClassLike(contextToken.parent.parent); case 24 /* DotDotDotToken */: return containingNodeKind === 146 /* Parameter */ || (contextToken.parent && contextToken.parent.parent && @@ -73826,20 +76289,30 @@ var ts; return containingNodeKind === 242 /* ImportSpecifier */ || containingNodeKind === 246 /* ExportSpecifier */ || containingNodeKind === 240 /* NamespaceImport */; + case 125 /* GetKeyword */: + case 135 /* SetKeyword */: + if (isFromClassElementDeclaration(contextToken)) { + return false; + } + // falls through case 75 /* ClassKeyword */: case 83 /* EnumKeyword */: case 109 /* InterfaceKeyword */: case 89 /* FunctionKeyword */: case 104 /* VarKeyword */: - case 125 /* GetKeyword */: - case 135 /* SetKeyword */: case 91 /* ImportKeyword */: case 110 /* LetKeyword */: case 76 /* ConstKeyword */: case 116 /* YieldKeyword */: - case 138 /* TypeKeyword */: + case 138 /* TypeKeyword */:// type htm| return true; } + // If the previous token is keyword correspoding to class member completion keyword + // there will be completion available here + if (isClassMemberCompletionKeywordText(contextToken.getText()) && + isFromClassElementDeclaration(contextToken)) { + return false; + } // Previous token may have been a keyword that was converted to an identifier. switch (contextToken.getText()) { case "abstract": @@ -73861,6 +76334,9 @@ var ts; } return false; } + function isFunctionLikeButNotConstructor(kind) { + return ts.isFunctionLikeKind(kind) && kind !== 152 /* Constructor */; + } function isDotOfNumericLiteral(contextToken) { if (contextToken.kind === 8 /* NumericLiteral */) { var text = contextToken.getFullText(); @@ -73882,7 +76358,7 @@ var ts; for (var _i = 0, namedImportsOrExports_1 = namedImportsOrExports; _i < namedImportsOrExports_1.length; _i++) { var element = namedImportsOrExports_1[_i]; // If this is the current item we are editing right now, do not filter it out - if (element.getStart() <= position && position <= element.getEnd()) { + if (isCurrentlyEditingNode(element)) { continue; } var name = element.propertyName || element.name; @@ -73916,7 +76392,7 @@ var ts; continue; } // If this is the current item we are editing right now, do not filter it out - if (m.getStart() <= position && position <= m.getEnd()) { + if (isCurrentlyEditingNode(m)) { continue; } var existingName = void 0; @@ -73936,6 +76412,49 @@ var ts; } return ts.filter(contextualMemberSymbols, function (m) { return !existingMemberNames.get(m.name); }); } + /** + * Filters out completion suggestions for class elements. + * + * @returns Symbols to be suggested in an class element depending on existing memebers and symbol flags + */ + function filterClassMembersList(baseSymbols, implementingTypeSymbols, existingMembers, currentClassElementModifierFlags) { + var existingMemberNames = ts.createMap(); + for (var _i = 0, existingMembers_2 = existingMembers; _i < existingMembers_2.length; _i++) { + var m = existingMembers_2[_i]; + // Ignore omitted expressions for missing members + if (m.kind !== 149 /* PropertyDeclaration */ && + m.kind !== 151 /* MethodDeclaration */ && + m.kind !== 153 /* GetAccessor */ && + m.kind !== 154 /* SetAccessor */) { + continue; + } + // If this is the current item we are editing right now, do not filter it out + if (isCurrentlyEditingNode(m)) { + continue; + } + // Dont filter member even if the name matches if it is declared private in the list + if (ts.hasModifier(m, 8 /* Private */)) { + continue; + } + // do not filter it out if the static presence doesnt match + var mIsStatic = ts.hasModifier(m, 32 /* Static */); + var currentElementIsStatic = !!(currentClassElementModifierFlags & 32 /* Static */); + if ((mIsStatic && !currentElementIsStatic) || + (!mIsStatic && currentElementIsStatic)) { + continue; + } + var existingName = ts.getPropertyNameForPropertyNameNode(m.name); + if (existingName) { + existingMemberNames.set(existingName, true); + } + } + return ts.concatenate(ts.filter(baseSymbols, function (baseProperty) { return isValidProperty(baseProperty, 8 /* Private */); }), ts.filter(implementingTypeSymbols, function (implementingProperty) { return isValidProperty(implementingProperty, 24 /* NonPublicAccessibilityModifier */); })); + function isValidProperty(propertySymbol, inValidModifierFlags) { + return !existingMemberNames.get(propertySymbol.name) && + propertySymbol.getDeclarations() && + !(ts.getDeclarationModifierFlagsFromSymbol(propertySymbol) & inValidModifierFlags); + } + } /** * Filters out completion suggestions from 'symbols' according to existing JSX attributes. * @@ -73947,7 +76466,7 @@ var ts; for (var _i = 0, attributes_1 = attributes; _i < attributes_1.length; _i++) { var attr = attributes_1[_i]; // If this is the current item we are editing right now, do not filter it out - if (attr.getStart() <= position && position <= attr.getEnd()) { + if (isCurrentlyEditingNode(attr)) { continue; } if (attr.kind === 253 /* JsxAttribute */) { @@ -73956,6 +76475,9 @@ var ts; } return ts.filter(symbols, function (a) { return !seenNames.get(a.name); }); } + function isCurrentlyEditingNode(node) { + return node.getStart() <= position && position <= node.getEnd(); + } } /** * Get the name to be display in completion from a given symbol. @@ -74008,6 +76530,27 @@ var ts; sortText: "0" }); } + function isClassMemberCompletionKeyword(kind) { + switch (kind) { + case 114 /* PublicKeyword */: + case 113 /* ProtectedKeyword */: + case 112 /* PrivateKeyword */: + case 117 /* AbstractKeyword */: + case 115 /* StaticKeyword */: + case 123 /* ConstructorKeyword */: + case 131 /* ReadonlyKeyword */: + case 125 /* GetKeyword */: + case 135 /* SetKeyword */: + case 120 /* AsyncKeyword */: + return true; + } + } + function isClassMemberCompletionKeywordText(text) { + return isClassMemberCompletionKeyword(ts.stringToToken(text)); + } + var classMemberKeywordCompletions = ts.filter(keywordCompletions, function (entry) { + return isClassMemberCompletionKeywordText(entry.name); + }); function isEqualityExpression(node) { return ts.isBinaryExpression(node) && isEqualityOperatorKind(node.operatorToken.kind); } @@ -74017,6 +76560,36 @@ var ts; kind === 34 /* EqualsEqualsEqualsToken */ || kind === 35 /* ExclamationEqualsEqualsToken */; } + /** Get the corresponding JSDocTag node if the position is in a jsDoc comment */ + function getJsDocTagAtPosition(node, position) { + var jsDoc = getJsDocHavingNode(node).jsDoc; + if (!jsDoc) + return undefined; + for (var _i = 0, jsDoc_1 = jsDoc; _i < jsDoc_1.length; _i++) { + var _a = jsDoc_1[_i], pos = _a.pos, end = _a.end, tags = _a.tags; + if (!tags || position < pos || position > end) + continue; + for (var i = tags.length - 1; i >= 0; i--) { + var tag = tags[i]; + if (position >= tag.pos) { + return tag; + } + } + } + } + function getJsDocHavingNode(node) { + if (!ts.isToken(node)) + return node; + switch (node.kind) { + case 104 /* VarKeyword */: + case 110 /* LetKeyword */: + case 76 /* ConstKeyword */: + // if the current token is var, let or const, skip the VariableDeclarationList + return node.parent.parent; + default: + return node.parent; + } + } })(Completions = ts.Completions || (ts.Completions = {})); })(ts || (ts = {})); /* @internal */ @@ -74024,22 +76597,31 @@ var ts; (function (ts) { var DocumentHighlights; (function (DocumentHighlights) { - function getDocumentHighlights(typeChecker, cancellationToken, sourceFile, position, sourceFilesToSearch) { - var node = ts.getTouchingWord(sourceFile, position); - return node && (getSemanticDocumentHighlights(node, typeChecker, cancellationToken, sourceFilesToSearch) || getSyntacticDocumentHighlights(node, sourceFile)); + function getDocumentHighlights(program, cancellationToken, sourceFile, position, sourceFilesToSearch) { + var node = ts.getTouchingWord(sourceFile, position, /*includeJsDocComment*/ true); + if (!node) + return undefined; + if (ts.isJsxOpeningElement(node.parent) && node.parent.tagName === node || ts.isJsxClosingElement(node.parent)) { + // For a JSX element, just highlight the matching tag, not all references. + var _a = node.parent.parent, openingElement = _a.openingElement, closingElement = _a.closingElement; + var highlightSpans = [openingElement, closingElement].map(function (_a) { + var tagName = _a.tagName; + return getHighlightSpanForNode(tagName, sourceFile); + }); + return [{ fileName: sourceFile.fileName, highlightSpans: highlightSpans }]; + } + return getSemanticDocumentHighlights(node, program, cancellationToken, sourceFilesToSearch) || getSyntacticDocumentHighlights(node, sourceFile); } DocumentHighlights.getDocumentHighlights = getDocumentHighlights; function getHighlightSpanForNode(node, sourceFile) { - var start = node.getStart(sourceFile); - var end = node.getEnd(); return { fileName: sourceFile.fileName, - textSpan: ts.createTextSpanFromBounds(start, end), + textSpan: ts.createTextSpanFromNode(node, sourceFile), kind: ts.HighlightSpanKind.none }; } - function getSemanticDocumentHighlights(node, typeChecker, cancellationToken, sourceFilesToSearch) { - var referenceEntries = ts.FindAllReferences.getReferenceEntriesForNode(node, sourceFilesToSearch, typeChecker, cancellationToken); + function getSemanticDocumentHighlights(node, program, cancellationToken, sourceFilesToSearch) { + var referenceEntries = ts.FindAllReferences.getReferenceEntriesForNode(node, program, sourceFilesToSearch, cancellationToken); return referenceEntries && convertReferencedSymbols(referenceEntries); } function convertReferencedSymbols(referenceEntries) { @@ -74707,7 +77289,7 @@ var ts; } function handleDirectImports(exportingModuleSymbol) { var theseDirectImports = getDirectImports(exportingModuleSymbol); - if (theseDirectImports) + if (theseDirectImports) { for (var _i = 0, theseDirectImports_1 = theseDirectImports; _i < theseDirectImports_1.length; _i++) { var direct = theseDirectImports_1[_i]; if (!markSeenDirectImport(direct)) { @@ -74753,6 +77335,7 @@ var ts; break; } } + } } function handleNamespaceImport(importDeclaration, name, isReExport) { if (exportKind === 2 /* ExportEquals */) { @@ -74786,11 +77369,12 @@ var ts; var moduleSymbol = checker.getMergedSymbol(sourceFileLike.symbol); ts.Debug.assert(!!(moduleSymbol.flags & 1536 /* Module */)); var directImports = getDirectImports(moduleSymbol); - if (directImports) + if (directImports) { for (var _i = 0, directImports_1 = directImports; _i < directImports_1.length; _i++) { var directImport = directImports_1[_i]; addIndirectUsers(getSourceFileLikeForImportDeclaration(directImport)); } + } } function getDirectImports(moduleSymbol) { return allDirectImports.get(ts.getSymbolId(moduleSymbol).toString()); @@ -74808,11 +77392,12 @@ var ts; function addSearch(location, symbol) { importSearches.push([location, symbol]); } - if (directImports) + if (directImports) { for (var _i = 0, directImports_2 = directImports; _i < directImports_2.length; _i++) { var decl = directImports_2[_i]; handleImport(decl); } + } return { importSearches: importSearches, singleReferences: singleReferences }; function handleImport(decl) { if (decl.kind === 237 /* ImportEqualsDeclaration */) { @@ -74873,7 +77458,7 @@ var ts; } } function searchForNamedImport(namedBindings) { - if (namedBindings) + if (namedBindings) { for (var _i = 0, _a = namedBindings.elements; _i < _a.length; _i++) { var element = _a[_i]; var name = element.name, propertyName = element.propertyName; @@ -74895,6 +77480,7 @@ var ts; addSearch(name, localSymbol); } } + } } } /** Returns 'true' is the namespace 'name' is re-exported from this module, and 'false' if it is only used locally. */ @@ -74914,11 +77500,42 @@ var ts; } }); } + function findModuleReferences(program, sourceFiles, searchModuleSymbol) { + var refs = []; + var checker = program.getTypeChecker(); + for (var _i = 0, sourceFiles_4 = sourceFiles; _i < sourceFiles_4.length; _i++) { + var referencingFile = sourceFiles_4[_i]; + var searchSourceFile = searchModuleSymbol.valueDeclaration; + if (searchSourceFile.kind === 265 /* SourceFile */) { + for (var _a = 0, _b = referencingFile.referencedFiles; _a < _b.length; _a++) { + var ref = _b[_a]; + if (program.getSourceFileFromReference(referencingFile, ref) === searchSourceFile) { + refs.push({ kind: "reference", referencingFile: referencingFile, ref: ref }); + } + } + for (var _c = 0, _d = referencingFile.typeReferenceDirectives; _c < _d.length; _c++) { + var ref = _d[_c]; + var referenced = program.getResolvedTypeReferenceDirectives().get(ref.fileName); + if (referenced !== undefined && referenced.resolvedFileName === searchSourceFile.fileName) { + refs.push({ kind: "reference", referencingFile: referencingFile, ref: ref }); + } + } + } + forEachImport(referencingFile, function (_importDecl, moduleSpecifier) { + var moduleSymbol = checker.getSymbolAtLocation(moduleSpecifier); + if (moduleSymbol === searchModuleSymbol) { + refs.push({ kind: "import", literal: moduleSpecifier }); + } + }); + } + return refs; + } + FindAllReferences.findModuleReferences = findModuleReferences; /** Returns a map from a module symbol Id to all import statements that directly reference the module. */ function getDirectImportsMap(sourceFiles, checker, cancellationToken) { var map = ts.createMap(); - for (var _i = 0, sourceFiles_4 = sourceFiles; _i < sourceFiles_4.length; _i++) { - var sourceFile = sourceFiles_4[_i]; + for (var _i = 0, sourceFiles_5 = sourceFiles; _i < sourceFiles_5.length; _i++) { + var sourceFile = sourceFiles_5[_i]; cancellationToken.throwIfCancellationRequested(); forEachImport(sourceFile, function (importDecl, moduleSpecifier) { var moduleSymbol = checker.getSymbolAtLocation(moduleSpecifier); @@ -74942,7 +77559,7 @@ var ts; } /** Calls `action` for each import, re-export, or require() in a file. */ function forEachImport(sourceFile, action) { - if (sourceFile.externalModuleIndicator) { + if (sourceFile.externalModuleIndicator || sourceFile.imports !== undefined) { for (var _i = 0, _a = sourceFile.imports; _i < _a.length; _i++) { var moduleSpecifier = _a[_i]; action(importerFromModuleSpecifier(moduleSpecifier), moduleSpecifier); @@ -74970,26 +77587,20 @@ var ts; } } }); - if (sourceFile.flags & 65536 /* JavaScriptFile */) { - // Find all 'require()' calls. - sourceFile.forEachChild(function recur(node) { - if (ts.isRequireCall(node, /*checkArgumentIsStringLiteral*/ true)) { - action(node, node.arguments[0]); - } - else { - node.forEachChild(recur); - } - }); - } } } function importerFromModuleSpecifier(moduleSpecifier) { var decl = moduleSpecifier.parent; - if (decl.kind === 238 /* ImportDeclaration */ || decl.kind === 244 /* ExportDeclaration */) { - return decl; + switch (decl.kind) { + case 181 /* CallExpression */: + case 238 /* ImportDeclaration */: + case 244 /* ExportDeclaration */: + return decl; + case 248 /* ExternalModuleReference */: + return decl.parent; + default: + ts.Debug.fail("Unexpected module specifier parent: " + decl.kind); } - ts.Debug.assert(decl.kind === 248 /* ExternalModuleReference */); - return decl.parent; } /** * Given a local reference, we might notice that it's an import/export and recursively search for references of that. @@ -75006,7 +77617,7 @@ var ts; if (parent.kind === 179 /* PropertyAccessExpression */) { // When accessing an export of a JS module, there's no alias. The symbol will still be flagged as an export even though we're at the use. // So check that we are at the declaration. - return symbol.declarations.some(function (d) { return d === parent; }) && parent.parent.kind === 194 /* BinaryExpression */ + return symbol.declarations.some(function (d) { return d === parent; }) && ts.isBinaryExpression(parent.parent) ? getSpecialPropertyExport(parent.parent, /*useLhsSymbol*/ false) : undefined; } @@ -75019,7 +77630,7 @@ var ts; else { var exportNode = getExportNode(parent); if (exportNode && ts.hasModifier(exportNode, 1 /* Export */)) { - if (exportNode.kind === 237 /* ImportEqualsDeclaration */ && exportNode.moduleReference === node) { + if (ts.isImportEqualsDeclaration(exportNode) && exportNode.moduleReference === node) { // We're at `Y` in `export import X = Y`. This is not the exported symbol, the left-hand-side is. So treat this as an import statement. if (comingFromExport) { return undefined; @@ -75031,19 +77642,25 @@ var ts; return exportInfo(symbol, getExportKindForDeclaration(exportNode)); } } - else if (parent.kind === 243 /* ExportAssignment */) { - // Get the symbol for the `export =` node; its parent is the module it's the export of. - var exportingModuleSymbol = parent.symbol.parent; - ts.Debug.assert(!!exportingModuleSymbol); - return { kind: 1 /* Export */, symbol: symbol, exportInfo: { exportingModuleSymbol: exportingModuleSymbol, exportKind: 2 /* ExportEquals */ } }; + else if (ts.isExportAssignment(parent)) { + return getExportAssignmentExport(parent); + } + else if (ts.isExportAssignment(parent.parent)) { + return getExportAssignmentExport(parent.parent); } - else if (parent.kind === 194 /* BinaryExpression */) { + else if (ts.isBinaryExpression(parent)) { return getSpecialPropertyExport(parent, /*useLhsSymbol*/ true); } - else if (parent.parent.kind === 194 /* BinaryExpression */) { + else if (ts.isBinaryExpression(parent.parent)) { return getSpecialPropertyExport(parent.parent, /*useLhsSymbol*/ true); } } + function getExportAssignmentExport(ex) { + // Get the symbol for the `export =` node; its parent is the module it's the export of. + var exportingModuleSymbol = ex.symbol.parent; + ts.Debug.assert(!!exportingModuleSymbol); + return { kind: 1 /* Export */, symbol: symbol, exportInfo: { exportingModuleSymbol: exportingModuleSymbol, exportKind: 2 /* ExportEquals */ } }; + } function getSpecialPropertyExport(node, useLhsSymbol) { var kind; switch (ts.getSpecialPropertyAssignmentKind(node)) { @@ -75063,19 +77680,19 @@ var ts; function getImport() { var isImport = isNodeImport(node); if (!isImport) - return; + return undefined; // A symbol being imported is always an alias. So get what that aliases to find the local symbol. var importedSymbol = checker.getImmediateAliasedSymbol(symbol); - if (importedSymbol) { - // Search on the local symbol in the exporting module, not the exported symbol. - importedSymbol = skipExportSpecifierSymbol(importedSymbol, checker); - // Similarly, skip past the symbol for 'export =' - if (importedSymbol.name === "export=") { - importedSymbol = checker.getImmediateAliasedSymbol(importedSymbol); - } - if (symbolName(importedSymbol) === symbol.name) { - return __assign({ kind: 0 /* Import */, symbol: importedSymbol }, isImport); - } + if (!importedSymbol) + return undefined; + // Search on the local symbol in the exporting module, not the exported symbol. + importedSymbol = skipExportSpecifierSymbol(importedSymbol, checker); + // Similarly, skip past the symbol for 'export =' + if (importedSymbol.name === "export=") { + importedSymbol = getExportEqualsLocalSymbol(importedSymbol, checker); + } + if (symbolName(importedSymbol) === symbol.name) { + return __assign({ kind: 0 /* Import */, symbol: importedSymbol }, isImport); } } function exportInfo(symbol, kind) { @@ -75088,6 +77705,20 @@ var ts; } } FindAllReferences.getImportOrExportSymbol = getImportOrExportSymbol; + function getExportEqualsLocalSymbol(importedSymbol, checker) { + if (importedSymbol.flags & 8388608 /* Alias */) { + return checker.getImmediateAliasedSymbol(importedSymbol); + } + var decl = importedSymbol.valueDeclaration; + if (ts.isExportAssignment(decl)) { + return decl.expression.symbol; + } + else if (ts.isBinaryExpression(decl)) { + return decl.right.symbol; + } + ts.Debug.fail(); + } + // If a reference is a class expression, the exported node would be its parent. // If a reference is a variable declaration, the exported node would be the variable statement. function getExportNode(parent) { if (parent.kind === 226 /* VariableDeclaration */) { @@ -75126,23 +77757,25 @@ var ts; if (symbol.name !== "default") { return symbol.name; } - var name = ts.forEach(symbol.declarations, function (decl) { + return ts.forEach(symbol.declarations, function (decl) { + if (ts.isExportAssignment(decl)) { + return ts.isIdentifier(decl.expression) ? decl.expression.text : undefined; + } var name = ts.getNameOfDeclaration(decl); return name && name.kind === 71 /* Identifier */ && name.text; }); - ts.Debug.assert(!!name); - return name; } /** If at an export specifier, go to the symbol it refers to. */ function skipExportSpecifierSymbol(symbol, checker) { // For `export { foo } from './bar", there's nothing to skip, because it does not create a new alias. But `export { foo } does. - if (symbol.declarations) + if (symbol.declarations) { for (var _i = 0, _a = symbol.declarations; _i < _a.length; _i++) { var declaration = _a[_i]; if (ts.isExportSpecifier(declaration) && !declaration.propertyName && !declaration.parent.parent.moduleSpecifier) { return checker.getExportSpecifierLocalTargetSymbol(declaration); } } + } return symbol; } function getContainingModuleSymbol(importer, checker) { @@ -75178,12 +77811,13 @@ var ts; return { type: "node", node: node, isInString: isInString }; } FindAllReferences.nodeEntry = nodeEntry; - function findReferencedSymbols(checker, cancellationToken, sourceFiles, sourceFile, position) { - var referencedSymbols = findAllReferencedSymbols(checker, cancellationToken, sourceFiles, sourceFile, position); + function findReferencedSymbols(program, cancellationToken, sourceFiles, sourceFile, position) { + var referencedSymbols = findAllReferencedSymbols(program, cancellationToken, sourceFiles, sourceFile, position); if (!referencedSymbols || !referencedSymbols.length) { return undefined; } var out = []; + var checker = program.getTypeChecker(); for (var _i = 0, referencedSymbols_1 = referencedSymbols; _i < referencedSymbols_1.length; _i++) { var _a = referencedSymbols_1[_i], definition = _a.definition, references = _a.references; // Only include referenced symbols that have a valid definition. @@ -75194,44 +77828,50 @@ var ts; return out; } FindAllReferences.findReferencedSymbols = findReferencedSymbols; - function getImplementationsAtPosition(checker, cancellationToken, sourceFiles, sourceFile, position) { - var node = ts.getTouchingPropertyName(sourceFile, position); - var referenceEntries = getImplementationReferenceEntries(checker, cancellationToken, sourceFiles, node); + function getImplementationsAtPosition(program, cancellationToken, sourceFiles, sourceFile, position) { + // A node in a JSDoc comment can't have an implementation anyway. + var node = ts.getTouchingPropertyName(sourceFile, position, /*includeJsDocComment*/ false); + var referenceEntries = getImplementationReferenceEntries(program, cancellationToken, sourceFiles, node); + var checker = program.getTypeChecker(); return ts.map(referenceEntries, function (entry) { return toImplementationLocation(entry, checker); }); } FindAllReferences.getImplementationsAtPosition = getImplementationsAtPosition; - function getImplementationReferenceEntries(typeChecker, cancellationToken, sourceFiles, node) { + function getImplementationReferenceEntries(program, cancellationToken, sourceFiles, node) { + if (node.kind === 265 /* SourceFile */) { + return undefined; + } + var checker = program.getTypeChecker(); // If invoked directly on a shorthand property assignment, then return // the declaration of the symbol being assigned (not the symbol being assigned to). if (node.parent.kind === 262 /* ShorthandPropertyAssignment */) { - var result_4 = []; - FindAllReferences.Core.getReferenceEntriesForShorthandPropertyAssignment(node, typeChecker, function (node) { return result_4.push(nodeEntry(node)); }); - return result_4; + var result_5 = []; + FindAllReferences.Core.getReferenceEntriesForShorthandPropertyAssignment(node, checker, function (node) { return result_5.push(nodeEntry(node)); }); + return result_5; } else if (node.kind === 97 /* SuperKeyword */ || ts.isSuperProperty(node.parent)) { // References to and accesses on the super keyword only have one possible implementation, so no // need to "Find all References" - var symbol = typeChecker.getSymbolAtLocation(node); + var symbol = checker.getSymbolAtLocation(node); return symbol.valueDeclaration && [nodeEntry(symbol.valueDeclaration)]; } else { // Perform "Find all References" and retrieve only those that are implementations - return getReferenceEntriesForNode(node, sourceFiles, typeChecker, cancellationToken, { implementations: true }); + return getReferenceEntriesForNode(node, program, sourceFiles, cancellationToken, { implementations: true }); } } - function findReferencedEntries(checker, cancellationToken, sourceFiles, sourceFile, position, options) { - var x = flattenEntries(findAllReferencedSymbols(checker, cancellationToken, sourceFiles, sourceFile, position, options)); + function findReferencedEntries(program, cancellationToken, sourceFiles, sourceFile, position, options) { + var x = flattenEntries(findAllReferencedSymbols(program, cancellationToken, sourceFiles, sourceFile, position, options)); return ts.map(x, toReferenceEntry); } FindAllReferences.findReferencedEntries = findReferencedEntries; - function getReferenceEntriesForNode(node, sourceFiles, checker, cancellationToken, options) { + function getReferenceEntriesForNode(node, program, sourceFiles, cancellationToken, options) { if (options === void 0) { options = {}; } - return flattenEntries(FindAllReferences.Core.getReferencedSymbolsForNode(node, sourceFiles, checker, cancellationToken, options)); + return flattenEntries(FindAllReferences.Core.getReferencedSymbolsForNode(node, program, sourceFiles, cancellationToken, options)); } FindAllReferences.getReferenceEntriesForNode = getReferenceEntriesForNode; - function findAllReferencedSymbols(checker, cancellationToken, sourceFiles, sourceFile, position, options) { + function findAllReferencedSymbols(program, cancellationToken, sourceFiles, sourceFile, position, options) { var node = ts.getTouchingPropertyName(sourceFile, position, /*includeJsDocComment*/ true); - return FindAllReferences.Core.getReferencedSymbolsForNode(node, sourceFiles, checker, cancellationToken, options); + return FindAllReferences.Core.getReferencedSymbolsForNode(node, program, sourceFiles, cancellationToken, options); } function flattenEntries(referenceSymbols) { return referenceSymbols && ts.flatMap(referenceSymbols, function (r) { return r.references; }); @@ -75241,10 +77881,6 @@ var ts; switch (def.type) { case "symbol": { var symbol = def.symbol, node_2 = def.node; - var declarations = symbol.declarations; - if (!declarations || declarations.length === 0) { - return undefined; - } var _a = getDefinitionKindAndDisplayParts(symbol, node_2, checker), displayParts_1 = _a.displayParts, kind_1 = _a.kind; var name_3 = displayParts_1.map(function (p) { return p.text; }).join(""); return { node: node_2, name: name_3, kind: kind_1, displayParts: displayParts_1 }; @@ -75298,7 +77934,7 @@ var ts; fileName: node.getSourceFile().fileName, textSpan: getTextSpan(node), isWriteAccess: isWriteAccess(node), - isDefinition: ts.isDeclarationName(node) || ts.isLiteralComputedPropertyDeclarationName(node), + isDefinition: ts.isAnyDeclarationName(node) || ts.isLiteralComputedPropertyDeclarationName(node), isInString: isInString }; } @@ -75360,20 +77996,19 @@ var ts; } /** A node is considered a writeAccess iff it is a name of a declaration or a target of an assignment */ function isWriteAccess(node) { - if (node.kind === 71 /* Identifier */ && ts.isDeclarationName(node)) { + if (ts.isAnyDeclarationName(node)) { return true; } var parent = node.parent; - if (parent) { - if (parent.kind === 193 /* PostfixUnaryExpression */ || parent.kind === 192 /* PrefixUnaryExpression */) { + switch (parent && parent.kind) { + case 193 /* PostfixUnaryExpression */: + case 192 /* PrefixUnaryExpression */: return true; - } - else if (parent.kind === 194 /* BinaryExpression */ && parent.left === node) { - var operator = parent.operatorToken.kind; - return 58 /* FirstAssignment */ <= operator && operator <= 70 /* LastAssignment */; - } + case 194 /* BinaryExpression */: + return parent.left === node && ts.isAssignmentOperator(parent.operatorToken.kind); + default: + return false; } - return false; } })(FindAllReferences = ts.FindAllReferences || (ts.FindAllReferences = {})); })(ts || (ts = {})); @@ -75385,7 +78020,7 @@ var ts; var Core; (function (Core) { /** Core find-all-references algorithm. Handles special cases before delegating to `getReferencedSymbolsForSymbol`. */ - function getReferencedSymbolsForNode(node, sourceFiles, checker, cancellationToken, options) { + function getReferencedSymbolsForNode(node, program, sourceFiles, cancellationToken, options) { if (options === void 0) { options = {}; } if (node.kind === 265 /* SourceFile */) { return undefined; @@ -75396,6 +78031,7 @@ var ts; return special; } } + var checker = program.getTypeChecker(); var symbol = checker.getSymbolAtLocation(node); // Could not find a symbol e.g. unknown identifier if (!symbol) { @@ -75406,13 +78042,60 @@ var ts; // Can't have references to something that we have no symbol for. return undefined; } - // The symbol was an internal symbol and does not have a declaration e.g. undefined symbol - if (!symbol.declarations || !symbol.declarations.length) { - return undefined; + if (symbol.flags & 1536 /* Module */ && isModuleReferenceLocation(node)) { + return getReferencedSymbolsForModule(program, symbol, sourceFiles); } return getReferencedSymbolsForSymbol(symbol, node, sourceFiles, checker, cancellationToken, options); } Core.getReferencedSymbolsForNode = getReferencedSymbolsForNode; + function isModuleReferenceLocation(node) { + if (node.kind !== 9 /* StringLiteral */) { + return false; + } + switch (node.parent.kind) { + case 233 /* ModuleDeclaration */: + case 248 /* ExternalModuleReference */: + case 238 /* ImportDeclaration */: + case 244 /* ExportDeclaration */: + return true; + case 181 /* CallExpression */: + return ts.isRequireCall(node.parent, /*checkArgumentIsStringLiteral*/ false) || ts.isImportCall(node.parent); + default: + return false; + } + } + function getReferencedSymbolsForModule(program, symbol, sourceFiles) { + ts.Debug.assert(!!symbol.valueDeclaration); + var references = FindAllReferences.findModuleReferences(program, sourceFiles, symbol).map(function (reference) { + if (reference.kind === "import") { + return { type: "node", node: reference.literal }; + } + else { + return { + type: "span", + fileName: reference.referencingFile.fileName, + textSpan: ts.createTextSpanFromRange(reference.ref), + }; + } + }); + for (var _i = 0, _a = symbol.declarations; _i < _a.length; _i++) { + var decl = _a[_i]; + switch (decl.kind) { + case 265 /* SourceFile */: + // Don't include the source file itself. (This may not be ideal behavior, but awkward to include an entire file as a reference.) + break; + case 233 /* ModuleDeclaration */: + references.push({ type: "node", node: decl.name }); + break; + default: + ts.Debug.fail("Expected a module symbol to be declared by a SourceFile or ModuleDeclaration."); + } + } + return [{ + definition: { type: "symbol", symbol: symbol, node: symbol.valueDeclaration }, + references: references + }]; + } /** getReferencedSymbols for special node kinds. */ function getReferencedSymbolsSpecial(node, sourceFiles, cancellationToken) { if (ts.isTypeKeyword(node.kind)) { @@ -75445,7 +78128,7 @@ var ts; // Compute the meaning from the location and the symbol it references var searchMeaning = getIntersectingMeaningFromDeclarations(ts.getMeaningFromLocation(node), symbol.declarations); var result = []; - var state = createState(sourceFiles, node, checker, cancellationToken, searchMeaning, options, result); + var state = new State(sourceFiles, /*isForConstructor*/ node.kind === 123 /* ConstructorKeyword */, checker, cancellationToken, searchMeaning, options, result); var search = state.createSearch(node, symbol, /*comingFrom*/ undefined, { allSearchSymbols: populateSearchSymbolSet(symbol, node, checker, options.implementations) }); // Try to get the smallest valid scope that we can limit our search to; // otherwise we'll need to search globally (i.e. include each file). @@ -75475,53 +78158,94 @@ var ts; } return symbol; } - function createState(sourceFiles, originalLocation, checker, cancellationToken, searchMeaning, options, result) { - var symbolIdToReferences = []; - var inheritsFromCache = ts.createMap(); - // Source file ID → symbol ID → Whether the symbol has been searched for in the source file. - var sourceFileToSeenSymbols = []; - var isForConstructor = originalLocation.kind === 123 /* ConstructorKeyword */; - var importTracker; - return __assign({}, options, { sourceFiles: sourceFiles, isForConstructor: isForConstructor, checker: checker, cancellationToken: cancellationToken, searchMeaning: searchMeaning, inheritsFromCache: inheritsFromCache, getImportSearches: getImportSearches, createSearch: createSearch, referenceAdder: referenceAdder, addStringOrCommentReference: addStringOrCommentReference, - markSearchedSymbol: markSearchedSymbol, markSeenContainingTypeReference: ts.nodeSeenTracker(), markSeenReExportRHS: ts.nodeSeenTracker() }); - function getImportSearches(exportSymbol, exportInfo) { - if (!importTracker) - importTracker = FindAllReferences.createImportTracker(sourceFiles, checker, cancellationToken); - return importTracker(exportSymbol, exportInfo, options.isForRename); - } - function createSearch(location, symbol, comingFrom, searchOptions) { + /** + * Holds all state needed for the finding references. + * Unlike `Search`, there is only one `State`. + */ + var State = (function () { + function State(sourceFiles, + /** True if we're searching for constructor references. */ + isForConstructor, checker, cancellationToken, searchMeaning, options, result) { + this.sourceFiles = sourceFiles; + this.isForConstructor = isForConstructor; + this.checker = checker; + this.cancellationToken = cancellationToken; + this.searchMeaning = searchMeaning; + this.options = options; + this.result = result; + /** Cache for `explicitlyinheritsFrom`. */ + this.inheritsFromCache = ts.createMap(); + /** + * Type nodes can contain multiple references to the same type. For example: + * let x: Foo & (Foo & Bar) = ... + * Because we are returning the implementation locations and not the identifier locations, + * duplicate entries would be returned here as each of the type references is part of + * the same implementation. For that reason, check before we add a new entry. + */ + this.markSeenContainingTypeReference = ts.nodeSeenTracker(); + /** + * It's possible that we will encounter the right side of `export { foo as bar } from "x";` more than once. + * For example: + * // b.ts + * export { foo as bar } from "./a"; + * import { bar } from "./b"; + * + * Normally at `foo as bar` we directly add `foo` and do not locally search for it (since it doesn't declare a local). + * But another reference to it may appear in the same source file. + * See `tests/cases/fourslash/transitiveExportImports3.ts`. + */ + this.markSeenReExportRHS = ts.nodeSeenTracker(); + this.symbolIdToReferences = []; + // Source file ID → symbol ID → Whether the symbol has been searched for in the source file. + this.sourceFileToSeenSymbols = []; + } + /** Gets every place to look for references of an exported symbols. See `ImportsResult` in `importTracker.ts` for more documentation. */ + State.prototype.getImportSearches = function (exportSymbol, exportInfo) { + if (!this.importTracker) + this.importTracker = FindAllReferences.createImportTracker(this.sourceFiles, this.checker, this.cancellationToken); + return this.importTracker(exportSymbol, exportInfo, this.options.isForRename); + }; + /** @param allSearchSymbols set of additinal symbols for use by `includes`. */ + State.prototype.createSearch = function (location, symbol, comingFrom, searchOptions) { if (searchOptions === void 0) { searchOptions = {}; } // Note: if this is an external module symbol, the name doesn't include quotes. - var _a = searchOptions.text, text = _a === void 0 ? ts.stripQuotes(ts.getDeclaredName(checker, symbol, location)) : _a, _b = searchOptions.allSearchSymbols, allSearchSymbols = _b === void 0 ? undefined : _b; + var _a = searchOptions.text, text = _a === void 0 ? ts.stripQuotes(ts.getDeclaredName(this.checker, symbol, location)) : _a, _b = searchOptions.allSearchSymbols, allSearchSymbols = _b === void 0 ? undefined : _b; var escapedText = ts.escapeIdentifier(text); - var parents = options.implementations && getParentSymbolsOfPropertyAccess(location, symbol, checker); - return { location: location, symbol: symbol, comingFrom: comingFrom, text: text, escapedText: escapedText, parents: parents, includes: includes }; - function includes(referenceSymbol) { - return allSearchSymbols ? ts.contains(allSearchSymbols, referenceSymbol) : referenceSymbol === symbol; - } - } - function referenceAdder(referenceSymbol, searchLocation) { - var symbolId = ts.getSymbolId(referenceSymbol); - var references = symbolIdToReferences[symbolId]; + var parents = this.options.implementations && getParentSymbolsOfPropertyAccess(location, symbol, this.checker); + return { + location: location, symbol: symbol, comingFrom: comingFrom, text: text, escapedText: escapedText, parents: parents, + includes: function (referenceSymbol) { return allSearchSymbols ? ts.contains(allSearchSymbols, referenceSymbol) : referenceSymbol === symbol; }, + }; + }; + /** + * Callback to add references for a particular searched symbol. + * This initializes a reference group, so only call this if you will add at least one reference. + */ + State.prototype.referenceAdder = function (searchSymbol, searchLocation) { + var symbolId = ts.getSymbolId(searchSymbol); + var references = this.symbolIdToReferences[symbolId]; if (!references) { - references = symbolIdToReferences[symbolId] = []; - result.push({ definition: { type: "symbol", symbol: referenceSymbol, node: searchLocation }, references: references }); + references = this.symbolIdToReferences[symbolId] = []; + this.result.push({ definition: { type: "symbol", symbol: searchSymbol, node: searchLocation }, references: references }); } return function (node) { return references.push(FindAllReferences.nodeEntry(node)); }; - } - function addStringOrCommentReference(fileName, textSpan) { - result.push({ + }; + /** Add a reference with no associated definition. */ + State.prototype.addStringOrCommentReference = function (fileName, textSpan) { + this.result.push({ definition: undefined, references: [{ type: "span", fileName: fileName, textSpan: textSpan }] }); - } - function markSearchedSymbol(sourceFile, symbol) { + }; + /** Returns `true` the first time we search for a symbol in a file and `false` afterwards. */ + State.prototype.markSearchedSymbol = function (sourceFile, symbol) { var sourceId = ts.getNodeId(sourceFile); var symbolId = ts.getSymbolId(symbol); - var seenSymbols = sourceFileToSeenSymbols[sourceId] || (sourceFileToSeenSymbols[sourceId] = []); + var seenSymbols = this.sourceFileToSeenSymbols[sourceId] || (this.sourceFileToSeenSymbols[sourceId] = []); return !seenSymbols[symbolId] && (seenSymbols[symbolId] = true); - } - } + }; + return State; + }()); /** Search for all imports of a given exported symbol using `State.getImportSearches`. */ function searchForImportsOfExport(exportLocation, exportSymbol, exportInfo, state) { var _a = state.getImportSearches(exportSymbol, exportInfo), importSearches = _a.importSearches, singleReferences = _a.singleReferences, indirectUsers = _a.indirectUsers; @@ -75546,7 +78270,7 @@ var ts; break; case 1 /* Default */: // Search for a property access to '.default'. This can't be renamed. - indirectSearch = state.isForRename ? undefined : state.createSearch(exportLocation, exportSymbol, 1 /* Export */, { text: "default" }); + indirectSearch = state.options.isForRename ? undefined : state.createSearch(exportLocation, exportSymbol, 1 /* Export */, { text: "default" }); break; case 2 /* ExportEquals */: break; @@ -75610,10 +78334,12 @@ var ts; } // If this is private property or method, the scope is the containing class if (flags & (4 /* Property */ | 8192 /* Method */)) { - var privateDeclaration = ts.find(declarations, function (d) { return !!(ts.getModifierFlags(d) & 8 /* Private */); }); + var privateDeclaration = ts.find(declarations, function (d) { return ts.hasModifier(d, 8 /* Private */); }); if (privateDeclaration) { return ts.getAncestor(privateDeclaration, 229 /* ClassDeclaration */); } + // Else this is a public property and could be accessed from anywhere. + return undefined; } // If symbol is of object binding pattern element without property name we would want to // look for property too and that could be anywhere @@ -75626,10 +78352,6 @@ var ts; if (parent && !((parent.flags & 1536 /* Module */) && ts.isExternalModuleSymbol(parent) && !parent.globalExports)) { return undefined; } - // If this is a synthetic property, it's a property and must be searched for globally. - if ((flags & 134217728 /* Transient */ && symbol.checkFlags & 6 /* Synthetic */)) { - return undefined; - } var scope; for (var _i = 0, declarations_10 = declarations; _i < declarations_10.length; _i++) { var declaration = declarations_10[_i]; @@ -75653,7 +78375,8 @@ var ts; // So we must search the whole source file. (Because we will mark the source file as seen, we we won't return to it when searching for imports.) return parent ? scope.getSourceFile() : scope; } - function getPossibleSymbolReferencePositions(sourceFile, symbolName, start, end) { + function getPossibleSymbolReferencePositions(sourceFile, symbolName, container) { + if (container === void 0) { container = sourceFile; } var positions = []; /// TODO: Cache symbol existence for files to save text search // Also, need to make this work for unicode escapes. @@ -75664,10 +78387,10 @@ var ts; var text = sourceFile.text; var sourceLength = text.length; var symbolNameLength = symbolName.length; - var position = text.indexOf(symbolName, start); + var position = text.indexOf(symbolName, container.pos); while (position >= 0) { // If we are past the end, stop looking - if (position > end) + if (position > container.end) break; // We found a match. Make sure it's not part of a larger word (i.e. the char // before and after it have to be a non-identifier char). @@ -75685,16 +78408,12 @@ var ts; var references = []; var sourceFile = container.getSourceFile(); var labelName = targetLabel.text; - var possiblePositions = getPossibleSymbolReferencePositions(sourceFile, labelName, container.getStart(), container.getEnd()); + var possiblePositions = getPossibleSymbolReferencePositions(sourceFile, labelName, container); for (var _i = 0, possiblePositions_1 = possiblePositions; _i < possiblePositions_1.length; _i++) { var position = possiblePositions_1[_i]; - var node = ts.getTouchingWord(sourceFile, position); - if (!node || node.getWidth() !== labelName.length) { - continue; - } + var node = ts.getTouchingWord(sourceFile, position, /*includeJsDocComment*/ false); // Only pick labels that are either the target label, or have a target that is the target label - if (node === targetLabel || - (ts.isJumpStatementTarget(node) && ts.getTargetLabel(node, labelName) === targetLabel)) { + if (node && (node === targetLabel || (ts.isJumpStatementTarget(node) && ts.getTargetLabel(node, labelName) === targetLabel))) { references.push(FindAllReferences.nodeEntry(node)); } } @@ -75704,31 +78423,30 @@ var ts; // Compare the length so we filter out strict superstrings of the symbol we are looking for switch (node && node.kind) { case 71 /* Identifier */: - return node.getWidth() === searchSymbolName.length; + return ts.unescapeIdentifier(node.text).length === searchSymbolName.length; case 9 /* StringLiteral */: return (ts.isLiteralNameOfPropertyDeclarationOrIndexAccess(node) || isNameOfExternalModuleImportOrDeclaration(node)) && - // For string literals we have two additional chars for the quotes - node.getWidth() === searchSymbolName.length + 2; + node.text.length === searchSymbolName.length; case 8 /* NumericLiteral */: - return ts.isLiteralNameOfPropertyDeclarationOrIndexAccess(node) && node.getWidth() === searchSymbolName.length; + return ts.isLiteralNameOfPropertyDeclarationOrIndexAccess(node) && node.text.length === searchSymbolName.length; default: return false; } } function getAllReferencesForKeyword(sourceFiles, keywordKind, cancellationToken) { var references = []; - for (var _i = 0, sourceFiles_5 = sourceFiles; _i < sourceFiles_5.length; _i++) { - var sourceFile = sourceFiles_5[_i]; + for (var _i = 0, sourceFiles_6 = sourceFiles; _i < sourceFiles_6.length; _i++) { + var sourceFile = sourceFiles_6[_i]; cancellationToken.throwIfCancellationRequested(); addReferencesForKeywordInFile(sourceFile, keywordKind, ts.tokenToString(keywordKind), references); } return references.length ? [{ definition: { type: "keyword", node: references[0].node }, references: references }] : undefined; } function addReferencesForKeywordInFile(sourceFile, kind, searchText, references) { - var possiblePositions = getPossibleSymbolReferencePositions(sourceFile, searchText, sourceFile.getStart(), sourceFile.getEnd()); + var possiblePositions = getPossibleSymbolReferencePositions(sourceFile, searchText, sourceFile); for (var _i = 0, possiblePositions_2 = possiblePositions; _i < possiblePositions_2.length; _i++) { var position = possiblePositions_2[_i]; - var referenceLocation = ts.getTouchingPropertyName(sourceFile, position); + var referenceLocation = ts.getTouchingPropertyName(sourceFile, position, /*includeJsDocComment*/ true); if (referenceLocation.kind === kind) { references.push(FindAllReferences.nodeEntry(referenceLocation)); } @@ -75747,20 +78465,18 @@ var ts; if (!state.markSearchedSymbol(sourceFile, search.symbol)) { return; } - var start = state.findInComments ? container.getFullStart() : container.getStart(); - var possiblePositions = getPossibleSymbolReferencePositions(sourceFile, search.text, start, container.getEnd()); - for (var _i = 0, possiblePositions_3 = possiblePositions; _i < possiblePositions_3.length; _i++) { - var position = possiblePositions_3[_i]; + for (var _i = 0, _a = getPossibleSymbolReferencePositions(sourceFile, search.text, container); _i < _a.length; _i++) { + var position = _a[_i]; getReferencesAtLocation(sourceFile, position, search, state); } } function getReferencesAtLocation(sourceFile, position, search, state) { - var referenceLocation = ts.getTouchingPropertyName(sourceFile, position); + var referenceLocation = ts.getTouchingPropertyName(sourceFile, position, /*includeJsDocComment*/ true); if (!isValidReferencePosition(referenceLocation, search.text)) { // This wasn't the start of a token. Check to see if it might be a // match in a comment or string if that's what the caller is asking // for. - if (!state.implementations && (state.findInStrings && ts.isInString(sourceFile, position) || state.findInComments && ts.isInNonReferenceComment(sourceFile, position))) { + if (!state.options.implementations && (state.options.findInStrings && ts.isInString(sourceFile, position) || state.options.findInComments && ts.isInNonReferenceComment(sourceFile, position))) { // In the case where we're looking inside comments/strings, we don't have // an actual definition. So just use 'undefined' here. Features like // 'Rename' won't care (as they ignore the definitions), and features like @@ -75815,7 +78531,7 @@ var ts; if (!exportDeclaration.moduleSpecifier) { addRef(); } - if (!state.isForRename && state.markSeenReExportRHS(name)) { + if (!state.options.isForRename && state.markSeenReExportRHS(name)) { addReference(name, referenceSymbol, name, state); } } @@ -75825,7 +78541,7 @@ var ts; } } // For `export { foo as bar }`, rename `foo`, but not `bar`. - if (!(referenceLocation === propertyName && state.isForRename)) { + if (!(referenceLocation === propertyName && state.options.isForRename)) { var exportKind = referenceLocation.originalKeywordKind === 79 /* DefaultKeyword */ ? 1 /* Default */ : 0 /* Named */; var exportInfo = FindAllReferences.getExportInfo(referenceSymbol, exportKind, state.checker); ts.Debug.assert(!!exportInfo); @@ -75861,7 +78577,7 @@ var ts; return; var symbol = importOrExport.symbol; if (importOrExport.kind === 0 /* Import */) { - if (!state.isForRename || importOrExport.isNamedImport) { + if (!state.options.isForRename || importOrExport.isNamedImport) { searchForImportedSymbol(symbol, state); } } @@ -75886,7 +78602,7 @@ var ts; } function addReference(referenceLocation, relatedSymbol, searchLocation, state) { var addRef = state.referenceAdder(relatedSymbol, searchLocation); - if (state.implementations) { + if (state.options.implementations) { addImplementationReferences(referenceLocation, addRef, state); } else { @@ -76147,10 +78863,10 @@ var ts; } var references = []; var sourceFile = searchSpaceNode.getSourceFile(); - var possiblePositions = getPossibleSymbolReferencePositions(sourceFile, "super", searchSpaceNode.getStart(), searchSpaceNode.getEnd()); - for (var _i = 0, possiblePositions_4 = possiblePositions; _i < possiblePositions_4.length; _i++) { - var position = possiblePositions_4[_i]; - var node = ts.getTouchingWord(sourceFile, position); + var possiblePositions = getPossibleSymbolReferencePositions(sourceFile, "super", searchSpaceNode); + for (var _i = 0, possiblePositions_3 = possiblePositions; _i < possiblePositions_3.length; _i++) { + var position = possiblePositions_3[_i]; + var node = ts.getTouchingWord(sourceFile, position, /*includeJsDocComment*/ false); if (!node || node.kind !== 97 /* SuperKeyword */) { continue; } @@ -76201,13 +78917,13 @@ var ts; if (searchSpaceNode.kind === 265 /* SourceFile */) { ts.forEach(sourceFiles, function (sourceFile) { cancellationToken.throwIfCancellationRequested(); - possiblePositions = getPossibleSymbolReferencePositions(sourceFile, "this", sourceFile.getStart(), sourceFile.getEnd()); + possiblePositions = getPossibleSymbolReferencePositions(sourceFile, "this"); getThisReferencesInFile(sourceFile, sourceFile, possiblePositions, references); }); } else { var sourceFile = searchSpaceNode.getSourceFile(); - possiblePositions = getPossibleSymbolReferencePositions(sourceFile, "this", searchSpaceNode.getStart(), searchSpaceNode.getEnd()); + possiblePositions = getPossibleSymbolReferencePositions(sourceFile, "this", searchSpaceNode); getThisReferencesInFile(sourceFile, searchSpaceNode, possiblePositions, references); } return [{ @@ -76216,7 +78932,7 @@ var ts; }]; function getThisReferencesInFile(sourceFile, searchSpaceNode, possiblePositions, result) { ts.forEach(possiblePositions, function (position) { - var node = ts.getTouchingWord(sourceFile, position); + var node = ts.getTouchingWord(sourceFile, position, /*includeJsDocComment*/ false); if (!node || !ts.isThis(node)) { return; } @@ -76253,10 +78969,10 @@ var ts; } function getReferencesForStringLiteral(node, sourceFiles, cancellationToken) { var references = []; - for (var _i = 0, sourceFiles_6 = sourceFiles; _i < sourceFiles_6.length; _i++) { - var sourceFile = sourceFiles_6[_i]; + for (var _i = 0, sourceFiles_7 = sourceFiles; _i < sourceFiles_7.length; _i++) { + var sourceFile = sourceFiles_7[_i]; cancellationToken.throwIfCancellationRequested(); - var possiblePositions = getPossibleSymbolReferencePositions(sourceFile, node.text, sourceFile.getStart(), sourceFile.getEnd()); + var possiblePositions = getPossibleSymbolReferencePositions(sourceFile, node.text); getReferencesForStringLiteralInFile(sourceFile, node.text, possiblePositions, references); } return [{ @@ -76264,9 +78980,9 @@ var ts; references: references }]; function getReferencesForStringLiteralInFile(sourceFile, searchText, possiblePositions, references) { - for (var _i = 0, possiblePositions_5 = possiblePositions; _i < possiblePositions_5.length; _i++) { - var position = possiblePositions_5[_i]; - var node_7 = ts.getTouchingWord(sourceFile, position); + for (var _i = 0, possiblePositions_4 = possiblePositions; _i < possiblePositions_4.length; _i++) { + var position = possiblePositions_4[_i]; + var node_7 = ts.getTouchingWord(sourceFile, position, /*includeJsDocComment*/ false); if (node_7 && node_7.kind === 9 /* StringLiteral */ && node_7.text === searchText) { references.push(FindAllReferences.nodeEntry(node_7, /*isInString*/ true)); } @@ -76462,20 +79178,20 @@ var ts; var contextualType = checker.getContextualType(objectLiteral); var name = getNameFromObjectLiteralElement(node); if (name && contextualType) { - var result_5 = []; + var result_6 = []; var symbol = contextualType.getProperty(name); if (symbol) { - result_5.push(symbol); + result_6.push(symbol); } if (contextualType.flags & 65536 /* Union */) { ts.forEach(contextualType.types, function (t) { var symbol = t.getProperty(name); if (symbol) { - result_5.push(symbol); + result_6.push(symbol); } }); } - return result_5; + return result_6; } return undefined; } @@ -76610,7 +79326,7 @@ var ts; if (referenceFile) { return [getDefinitionInfoForFileReference(comment.fileName, referenceFile.fileName)]; } - return undefined; + // Might still be on jsdoc, so keep looking. } // Type reference directives var typeReferenceDirective = findReferenceInPosition(sourceFile.typeReferenceDirectives, position); @@ -76619,7 +79335,7 @@ var ts; return referenceFile && referenceFile.resolvedFileName && [getDefinitionInfoForFileReference(typeReferenceDirective.fileName, referenceFile.resolvedFileName)]; } - var node = ts.getTouchingPropertyName(sourceFile, position); + var node = ts.getTouchingPropertyName(sourceFile, position, /*includeJsDocComment*/ true); if (node === sourceFile) { return undefined; } @@ -76644,17 +79360,10 @@ var ts; // get the aliased symbol instead. This allows for goto def on an import e.g. // import {A, B} from "mod"; // to jump to the implementation directly. - if (symbol.flags & 8388608 /* Alias */) { - var declaration = symbol.declarations[0]; - // Go to the original declaration for cases: - // - // (1) when the aliased symbol was declared in the location(parent). - // (2) when the aliased symbol is originating from a named import. - // - if (node.kind === 71 /* Identifier */ && - (node.parent === declaration || - (declaration.kind === 242 /* ImportSpecifier */ && declaration.parent && declaration.parent.kind === 241 /* NamedImports */))) { - symbol = typeChecker.getAliasedSymbol(symbol); + if (symbol.flags & 8388608 /* Alias */ && shouldSkipAlias(node, symbol.declarations[0])) { + var aliased = typeChecker.getAliasedSymbol(symbol); + if (aliased.declarations) { + symbol = aliased; } } // Because name in short-hand property assignment has two different meanings: property name and property value, @@ -76673,16 +79382,6 @@ var ts; var shorthandContainerName_1 = typeChecker.symbolToString(symbol.parent, node); return ts.map(shorthandDeclarations, function (declaration) { return createDefinitionInfo(declaration, shorthandSymbolKind_1, shorthandSymbolName_1, shorthandContainerName_1); }); } - if (ts.isJsxOpeningLikeElement(node.parent)) { - // If there are errors when trying to figure out stateless component function, just return the first declaration - // For example: - // declare function /*firstSource*/MainButton(buttonProps: ButtonProps): JSX.Element; - // declare function /*secondSource*/MainButton(linkProps: LinkProps): JSX.Element; - // declare function /*thirdSource*/MainButton(props: ButtonProps | LinkProps): JSX.Element; - // let opt =
; // Error - We get undefined for resolved signature indicating an error, then just return the first declaration - var _a = getSymbolInfo(typeChecker, symbol, node), symbolName = _a.symbolName, symbolKind = _a.symbolKind, containerName = _a.containerName; - return [createDefinitionInfo(symbol.valueDeclaration, symbolKind, symbolName, containerName)]; - } // If the current location we want to find its definition is in an object literal, try to get the contextual type for the // object literal, lookup the property symbol in the contextual type, and use this for goto-definition. // For example @@ -76693,23 +79392,17 @@ var ts; // function Foo(arg: Props) {} // Foo( { pr/*1*/op1: 10, prop2: true }) var element = ts.getContainingObjectLiteralElement(node); - if (element) { - if (typeChecker.getContextualType(element.parent)) { - var result = []; - var propertySymbols = ts.getPropertySymbolsFromContextualType(typeChecker, element); - for (var _i = 0, propertySymbols_1 = propertySymbols; _i < propertySymbols_1.length; _i++) { - var propertySymbol = propertySymbols_1[_i]; - result.push.apply(result, getDefinitionFromSymbol(typeChecker, propertySymbol, node)); - } - return result; - } + if (element && typeChecker.getContextualType(element.parent)) { + return ts.flatMap(ts.getPropertySymbolsFromContextualType(typeChecker, element), function (propertySymbol) { + return getDefinitionFromSymbol(typeChecker, propertySymbol, node); + }); } return getDefinitionFromSymbol(typeChecker, symbol, node); } GoToDefinition.getDefinitionAtPosition = getDefinitionAtPosition; /// Goto type function getTypeDefinitionAtPosition(typeChecker, sourceFile, position) { - var node = ts.getTouchingPropertyName(sourceFile, position); + var node = ts.getTouchingPropertyName(sourceFile, position, /*includeJsDocComment*/ true); if (node === sourceFile) { return undefined; } @@ -76722,13 +79415,13 @@ var ts; return undefined; } if (type.flags & 65536 /* Union */ && !(type.flags & 16 /* Enum */)) { - var result_6 = []; + var result_7 = []; ts.forEach(type.types, function (t) { if (t.symbol) { - ts.addRange(/*to*/ result_6, /*from*/ getDefinitionFromSymbol(typeChecker, t.symbol, node)); + ts.addRange(/*to*/ result_7, /*from*/ getDefinitionFromSymbol(typeChecker, t.symbol, node)); } }); - return result_6; + return result_7; } if (!type.symbol) { return undefined; @@ -76736,6 +79429,28 @@ var ts; return getDefinitionFromSymbol(typeChecker, type.symbol, node); } GoToDefinition.getTypeDefinitionAtPosition = getTypeDefinitionAtPosition; + // Go to the original declaration for cases: + // + // (1) when the aliased symbol was declared in the location(parent). + // (2) when the aliased symbol is originating from an import. + // + function shouldSkipAlias(node, declaration) { + if (node.kind !== 71 /* Identifier */) { + return false; + } + if (node.parent === declaration) { + return true; + } + switch (declaration.kind) { + case 239 /* ImportClause */: + case 237 /* ImportEqualsDeclaration */: + return true; + case 242 /* ImportSpecifier */: + return declaration.parent.kind === 241 /* NamedImports */; + default: + return false; + } + } function getDefinitionFromSymbol(typeChecker, symbol, node) { var result = []; var declarations = symbol.getDeclarations(); @@ -76834,7 +79549,7 @@ var ts; function findReferenceInPosition(refs, pos) { for (var _i = 0, refs_1 = refs; _i < refs_1.length; _i++) { var ref = refs_1[_i]; - if (ref.pos <= pos && pos < ref.end) { + if (ref.pos <= pos && pos <= ref.end) { return ref; } } @@ -76906,6 +79621,7 @@ var ts; "namespace", "param", "private", + "prop", "property", "public", "requires", @@ -76916,8 +79632,6 @@ var ts; "throws", "type", "typedef", - "property", - "prop", "version" ]; var jsDocTagNameCompletionEntries; @@ -77012,6 +79726,24 @@ var ts; })); } JsDoc.getJSDocTagCompletions = getJSDocTagCompletions; + function getJSDocParameterNameCompletions(tag) { + var nameThusFar = tag.name.text; + var jsdoc = tag.parent; + var fn = jsdoc.parent; + if (!ts.isFunctionLike(fn)) + return []; + return ts.mapDefined(fn.parameters, function (param) { + if (!ts.isIdentifier(param.name)) + return undefined; + var name = param.name.text; + if (jsdoc.tags.some(function (t) { return t !== tag && ts.isJSDocParameterTag(t) && t.name.text === name; }) + || nameThusFar !== undefined && !ts.startsWith(name, nameThusFar)) { + return undefined; + } + return { name: name, kind: ts.ScriptElementKind.parameterElement, kindModifiers: "", sortText: "0" }; + }); + } + JsDoc.getJSDocParameterNameCompletions = getJSDocParameterNameCompletions; /** * Checks if position points to a valid position to add JSDoc comments, and if so, * returns the appropriate template. Otherwise returns an empty string. @@ -77037,7 +79769,7 @@ var ts; if (ts.isInString(sourceFile, position) || ts.isInComment(sourceFile, position) || ts.hasDocComment(sourceFile, position)) { return undefined; } - var tokenAtPos = ts.getTokenAtPosition(sourceFile, position); + var tokenAtPos = ts.getTokenAtPosition(sourceFile, position, /*includeJsDocComment*/ false); var tokenStart = tokenAtPos.getStart(); if (!tokenAtPos || tokenStart < position) { return undefined; @@ -77300,7 +80032,7 @@ var ts; var inferredTypingNames = ts.map(jsFileNames, function (f) { return ts.removeFileExtension(ts.getBaseFileName(f.toLowerCase())); }); var cleanedTypingNames = ts.map(inferredTypingNames, function (f) { return f.replace(/((?:\.|-)min(?=\.|$))|((?:-|\.)\d+)/g, ""); }); if (safeList !== EmptySafeList) { - mergeTypings(ts.filter(cleanedTypingNames, function (f) { return safeList.has(f); })); + mergeTypings(ts.mapDefined(cleanedTypingNames, function (f) { return safeList.get(f); })); } var hasJsxFile = ts.forEach(fileNames, function (f) { return ts.ensureScriptKind(f, ts.getScriptKindFromFileName(f)) === 2 /* JSX */; }); if (hasJsxFile) { @@ -77365,7 +80097,7 @@ var ts; function getNavigateToItems(sourceFiles, checker, cancellationToken, searchValue, maxResultCount, excludeDtsFiles) { var patternMatcher = ts.createPatternMatcher(searchValue); var rawItems = []; - var _loop_4 = function (sourceFile) { + var _loop_5 = function (sourceFile) { cancellationToken.throwIfCancellationRequested(); if (excludeDtsFiles && ts.fileExtensionIs(sourceFile.fileName, ".d.ts")) { return "continue"; @@ -77400,9 +80132,9 @@ var ts; }); }; // Search the declarations in all files and output matched NavigateToItem into array of NavigateToItem[] - for (var _i = 0, sourceFiles_7 = sourceFiles; _i < sourceFiles_7.length; _i++) { - var sourceFile = sourceFiles_7[_i]; - _loop_4(sourceFile); + for (var _i = 0, sourceFiles_8 = sourceFiles; _i < sourceFiles_8.length; _i++) { + var sourceFile = sourceFiles_8[_i]; + _loop_5(sourceFile); } // Remove imports when the imported declaration is already in the list and has the same name. rawItems = ts.filter(rawItems, function (item) { @@ -77777,7 +80509,7 @@ var ts; default: ts.forEach(node.jsDoc, function (jsDoc) { ts.forEach(jsDoc.tags, function (tag) { - if (tag.kind === 290 /* JSDocTypedefTag */) { + if (tag.kind === 291 /* JSDocTypedefTag */) { addLeafNode(tag); } }); @@ -77888,7 +80620,7 @@ var ts; case 187 /* ArrowFunction */: case 199 /* ClassExpression */: return getFunctionOrClassName(node); - case 290 /* JSDocTypedefTag */: + case 291 /* JSDocTypedefTag */: return getJSDocTypedefTagName(node); default: return undefined; @@ -77931,7 +80663,7 @@ var ts; return "()"; case 157 /* IndexSignature */: return "[]"; - case 290 /* JSDocTypedefTag */: + case 291 /* JSDocTypedefTag */: return getJSDocTypedefTagName(node); default: return ""; @@ -77979,7 +80711,7 @@ var ts; case 233 /* ModuleDeclaration */: case 265 /* SourceFile */: case 231 /* TypeAliasDeclaration */: - case 290 /* JSDocTypedefTag */: + case 291 /* JSDocTypedefTag */: return true; case 152 /* Constructor */: case 151 /* MethodDeclaration */: @@ -78936,7 +81668,15 @@ var ts; var token = ts.scanner.getToken(); if (token === 91 /* ImportKeyword */) { token = nextToken(); - if (token === 9 /* StringLiteral */) { + if (token === 19 /* OpenParenToken */) { + token = nextToken(); + if (token === 9 /* StringLiteral */) { + // import("mod"); + recordModuleName(); + return true; + } + } + else if (token === 9 /* StringLiteral */) { // import "mod"; recordModuleName(); return true; @@ -79120,7 +81860,7 @@ var ts; // import * as NS from "mod" // import d, {a, b as B} from "mod" // import i = require("mod"); - // + // import("mod"); // export * from "mod" // export {a as b} from "mod" // export import i = require("mod") @@ -79276,138 +82016,6 @@ var ts; (function (ts) { var SignatureHelp; (function (SignatureHelp) { - // A partially written generic type expression is not guaranteed to have the correct syntax tree. the expression could be parsed as less than/greater than expression or a comma expression - // or some other combination depending on what the user has typed so far. For the purposes of signature help we need to consider any location after "<" as a possible generic type reference. - // To do this, the method will back parse the expression starting at the position required. it will try to parse the current expression as a generic type expression, if it did succeed it - // will return the generic identifier that started the expression (e.g. "foo" in "foo 1) { displayParts.push(ts.spacePart()); displayParts.push(ts.punctuationPart(19 /* OpenParenToken */)); @@ -80445,7 +83060,7 @@ var ts; ts.addRange(/*to*/ diagnostics, /*from*/ program.getOptionsDiagnostics()); } // Emit - program.emit(); + program.emit(/*targetSourceFile*/ undefined, /*writeFile*/ undefined, /*cancellationToken*/ undefined, /*emitOnlyDtsFiles*/ undefined, transpileOptions.transformers); ts.Debug.assert(outputText !== undefined, "Output generation failed"); return { outputText: outputText, diagnostics: diagnostics, sourceMapText: sourceMapText }; } @@ -80469,7 +83084,7 @@ var ts; return typeof o.type === "object" && !ts.forEachEntry(o.type, function (v) { return typeof v !== "number"; }); }); options = ts.clone(options); - var _loop_5 = function (opt) { + var _loop_6 = function (opt) { if (!ts.hasProperty(options, opt.name)) { return "continue"; } @@ -80488,7 +83103,7 @@ var ts; }; for (var _i = 0, commandLineOptionsStringToEnum_1 = commandLineOptionsStringToEnum; _i < commandLineOptionsStringToEnum_1.length; _i++) { var opt = commandLineOptionsStringToEnum_1[_i]; - _loop_5(opt); + _loop_6(opt); } return options; } @@ -80984,9 +83599,9 @@ var ts; } return true; }; + RuleOperationContext.Any = new RuleOperationContext(); return RuleOperationContext; }()); - RuleOperationContext.Any = new RuleOperationContext(); formatting.RuleOperationContext = RuleOperationContext; })(formatting = ts.formatting || (ts.formatting = {})); })(ts || (ts = {})); @@ -81022,7 +83637,7 @@ var ts; this.NoSpaceBeforeDot = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 23 /* DotToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsNonJsxSameLineTokenContext), 8 /* Delete */)); this.NoSpaceAfterDot = new formatting.Rule(formatting.RuleDescriptor.create3(23 /* DotToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsNonJsxSameLineTokenContext), 8 /* Delete */)); // No space before and after indexer - this.NoSpaceBeforeOpenBracket = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 21 /* OpenBracketToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsNonJsxSameLineTokenContext), 8 /* Delete */)); + this.NoSpaceBeforeOpenBracket = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.AnyExcept(120 /* AsyncKeyword */), 21 /* OpenBracketToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsNonJsxSameLineTokenContext), 8 /* Delete */)); this.NoSpaceAfterCloseBracket = new formatting.Rule(formatting.RuleDescriptor.create3(22 /* CloseBracketToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsNonJsxSameLineTokenContext, Rules.IsNotBeforeBlockInFunctionDeclarationContext), 8 /* Delete */)); // Place a space before open brace in a function declaration this.FunctionOpenBraceLeftTokenRange = formatting.Shared.TokenRange.AnyIncludingMultilineComments; @@ -81064,6 +83679,7 @@ var ts; this.SpaceAfterSubtractWhenFollowedByPredecrement = new formatting.Rule(formatting.RuleDescriptor.create1(38 /* MinusToken */, 44 /* MinusMinusToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsNonJsxSameLineTokenContext, Rules.IsBinaryOpContext), 2 /* Space */)); this.NoSpaceBeforeComma = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 26 /* CommaToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsNonJsxSameLineTokenContext), 8 /* Delete */)); this.SpaceAfterCertainKeywords = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.FromTokens([104 /* VarKeyword */, 100 /* ThrowKeyword */, 94 /* NewKeyword */, 80 /* DeleteKeyword */, 96 /* ReturnKeyword */, 103 /* TypeOfKeyword */, 121 /* AwaitKeyword */]), formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsNonJsxSameLineTokenContext), 2 /* Space */)); + this.NoSpaceAfterNewKeywordOnConstructorSignature = new formatting.Rule(formatting.RuleDescriptor.create1(94 /* NewKeyword */, 19 /* OpenParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsNonJsxSameLineTokenContext, Rules.IsConstructorSignatureContext), 8 /* Delete */)); this.SpaceAfterLetConstInVariableDeclaration = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.FromTokens([110 /* LetKeyword */, 76 /* ConstKeyword */]), formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsNonJsxSameLineTokenContext, Rules.IsStartOfVariableDeclarationList), 2 /* Space */)); this.NoSpaceBeforeOpenParenInFuncCall = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 19 /* OpenParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsNonJsxSameLineTokenContext, Rules.IsFunctionCallOrNewContext, Rules.IsPreviousTokenNotComma), 8 /* Delete */)); this.SpaceAfterFunctionInFuncDecl = new formatting.Rule(formatting.RuleDescriptor.create3(89 /* FunctionKeyword */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsFunctionDeclContext), 2 /* Space */)); @@ -81224,7 +83840,8 @@ var ts; this.SpaceBeforeAt, this.NoSpaceAfterAt, this.SpaceAfterDecorator, - this.NoSpaceBeforeNonNullAssertionOperator + this.NoSpaceBeforeNonNullAssertionOperator, + this.NoSpaceAfterNewKeywordOnConstructorSignature ]; // These rules are applied after high priority rules. this.UserConfigurableRules = [ @@ -81396,7 +84013,7 @@ var ts; // case SyntaxKind.ConstructorDeclaration: // case SyntaxKind.SimpleArrowFunctionExpression: // case SyntaxKind.ParenthesizedArrowFunctionExpression: - case 230 /* InterfaceDeclaration */: + case 230 /* InterfaceDeclaration */:// This one is not truly a function, but for formatting purposes, it acts just like one return true; } return false; @@ -81528,6 +84145,9 @@ var ts; Rules.IsObjectTypeContext = function (context) { return context.contextNode.kind === 163 /* TypeLiteral */; // && context.contextNode.parent.kind !== SyntaxKind.InterfaceDeclaration; }; + Rules.IsConstructorSignatureContext = function (context) { + return context.contextNode.kind === 156 /* ConstructSignature */; + }; Rules.IsTypeArgumentOrParameterOrAssertion = function (token, parent) { if (token.kind !== 27 /* LessThanToken */ && token.kind !== 29 /* GreaterThanToken */) { return false; @@ -81612,8 +84232,7 @@ var ts; }; RulesMap.prototype.FillRule = function (rule, rulesBucketConstructionStateList) { var _this = this; - var specificRule = rule.Descriptor.LeftTokenRange !== formatting.Shared.TokenRange.Any && - rule.Descriptor.RightTokenRange !== formatting.Shared.TokenRange.Any; + var specificRule = rule.Descriptor.LeftTokenRange.isSpecific() && rule.Descriptor.RightTokenRange.isSpecific(); rule.Descriptor.LeftTokenRange.GetTokens().forEach(function (left) { rule.Descriptor.RightTokenRange.GetTokens().forEach(function (right) { var rulesBucketIndex = _this.GetRuleBucketIndex(left, right); @@ -81738,27 +84357,14 @@ var ts; (function (formatting) { var Shared; (function (Shared) { - var TokenRangeAccess = (function () { - function TokenRangeAccess(from, to, except) { - this.tokens = []; - for (var token = from; token <= to; token++) { - if (ts.indexOf(except, token) < 0) { - this.tokens.push(token); - } - } - } - TokenRangeAccess.prototype.GetTokens = function () { - return this.tokens; - }; - TokenRangeAccess.prototype.Contains = function (token) { - return this.tokens.indexOf(token) >= 0; - }; - return TokenRangeAccess; - }()); - Shared.TokenRangeAccess = TokenRangeAccess; + var allTokens = []; + for (var token = 0 /* FirstToken */; token <= 142 /* LastToken */; token++) { + allTokens.push(token); + } var TokenValuesAccess = (function () { - function TokenValuesAccess(tks) { - this.tokens = tks && tks.length ? tks : []; + function TokenValuesAccess(tokens) { + if (tokens === void 0) { tokens = []; } + this.tokens = tokens; } TokenValuesAccess.prototype.GetTokens = function () { return this.tokens; @@ -81766,9 +84372,9 @@ var ts; TokenValuesAccess.prototype.Contains = function (token) { return this.tokens.indexOf(token) >= 0; }; + TokenValuesAccess.prototype.isSpecific = function () { return true; }; return TokenValuesAccess; }()); - Shared.TokenValuesAccess = TokenValuesAccess; var TokenSingleValueAccess = (function () { function TokenSingleValueAccess(token) { this.token = token; @@ -81779,18 +84385,14 @@ var ts; TokenSingleValueAccess.prototype.Contains = function (tokenValue) { return tokenValue === this.token; }; + TokenSingleValueAccess.prototype.isSpecific = function () { return true; }; return TokenSingleValueAccess; }()); - Shared.TokenSingleValueAccess = TokenSingleValueAccess; var TokenAllAccess = (function () { function TokenAllAccess() { } TokenAllAccess.prototype.GetTokens = function () { - var result = []; - for (var token = 0 /* FirstToken */; token <= 142 /* LastToken */; token++) { - result.push(token); - } - return result; + return allTokens; }; TokenAllAccess.prototype.Contains = function () { return true; @@ -81798,51 +84400,80 @@ var ts; TokenAllAccess.prototype.toString = function () { return "[allTokens]"; }; + TokenAllAccess.prototype.isSpecific = function () { return false; }; return TokenAllAccess; }()); - Shared.TokenAllAccess = TokenAllAccess; - var TokenRange = (function () { - function TokenRange(tokenAccess) { - this.tokenAccess = tokenAccess; + var TokenAllExceptAccess = (function () { + function TokenAllExceptAccess(except) { + this.except = except; } - TokenRange.FromToken = function (token) { - return new TokenRange(new TokenSingleValueAccess(token)); - }; - TokenRange.FromTokens = function (tokens) { - return new TokenRange(new TokenValuesAccess(tokens)); - }; - TokenRange.FromRange = function (f, to, except) { - if (except === void 0) { except = []; } - return new TokenRange(new TokenRangeAccess(f, to, except)); + TokenAllExceptAccess.prototype.GetTokens = function () { + var _this = this; + return allTokens.filter(function (t) { return t !== _this.except; }); }; - TokenRange.AllTokens = function () { - return new TokenRange(new TokenAllAccess()); + TokenAllExceptAccess.prototype.Contains = function (token) { + return token !== this.except; }; - TokenRange.prototype.GetTokens = function () { - return this.tokenAccess.GetTokens(); - }; - TokenRange.prototype.Contains = function (token) { - return this.tokenAccess.Contains(token); - }; - TokenRange.prototype.toString = function () { - return this.tokenAccess.toString(); - }; - return TokenRange; + TokenAllExceptAccess.prototype.isSpecific = function () { return false; }; + return TokenAllExceptAccess; }()); - TokenRange.Any = TokenRange.AllTokens(); - TokenRange.AnyIncludingMultilineComments = TokenRange.FromTokens(TokenRange.Any.GetTokens().concat([3 /* MultiLineCommentTrivia */])); - TokenRange.Keywords = TokenRange.FromRange(72 /* FirstKeyword */, 142 /* LastKeyword */); - TokenRange.BinaryOperators = TokenRange.FromRange(27 /* FirstBinaryOperator */, 70 /* LastBinaryOperator */); - TokenRange.BinaryKeywordOperators = TokenRange.FromTokens([92 /* InKeyword */, 93 /* InstanceOfKeyword */, 142 /* OfKeyword */, 118 /* AsKeyword */, 126 /* IsKeyword */]); - TokenRange.UnaryPrefixOperators = TokenRange.FromTokens([43 /* PlusPlusToken */, 44 /* MinusMinusToken */, 52 /* TildeToken */, 51 /* ExclamationToken */]); - TokenRange.UnaryPrefixExpressions = TokenRange.FromTokens([8 /* NumericLiteral */, 71 /* Identifier */, 19 /* OpenParenToken */, 21 /* OpenBracketToken */, 17 /* OpenBraceToken */, 99 /* ThisKeyword */, 94 /* NewKeyword */]); - TokenRange.UnaryPreincrementExpressions = TokenRange.FromTokens([71 /* Identifier */, 19 /* OpenParenToken */, 99 /* ThisKeyword */, 94 /* NewKeyword */]); - TokenRange.UnaryPostincrementExpressions = TokenRange.FromTokens([71 /* Identifier */, 20 /* CloseParenToken */, 22 /* CloseBracketToken */, 94 /* NewKeyword */]); - TokenRange.UnaryPredecrementExpressions = TokenRange.FromTokens([71 /* Identifier */, 19 /* OpenParenToken */, 99 /* ThisKeyword */, 94 /* NewKeyword */]); - TokenRange.UnaryPostdecrementExpressions = TokenRange.FromTokens([71 /* Identifier */, 20 /* CloseParenToken */, 22 /* CloseBracketToken */, 94 /* NewKeyword */]); - TokenRange.Comments = TokenRange.FromTokens([2 /* SingleLineCommentTrivia */, 3 /* MultiLineCommentTrivia */]); - TokenRange.TypeNames = TokenRange.FromTokens([71 /* Identifier */, 133 /* NumberKeyword */, 136 /* StringKeyword */, 122 /* BooleanKeyword */, 137 /* SymbolKeyword */, 105 /* VoidKeyword */, 119 /* AnyKeyword */]); - Shared.TokenRange = TokenRange; + var TokenRange; + (function (TokenRange) { + function FromToken(token) { + return new TokenSingleValueAccess(token); + } + TokenRange.FromToken = FromToken; + function FromTokens(tokens) { + return new TokenValuesAccess(tokens); + } + TokenRange.FromTokens = FromTokens; + function FromRange(from, to, except) { + if (except === void 0) { except = []; } + var tokens = []; + for (var token = from; token <= to; token++) { + if (ts.indexOf(except, token) < 0) { + tokens.push(token); + } + } + return new TokenValuesAccess(tokens); + } + TokenRange.FromRange = FromRange; + function AnyExcept(token) { + return new TokenAllExceptAccess(token); + } + TokenRange.AnyExcept = AnyExcept; + TokenRange.Any = new TokenAllAccess(); + TokenRange.AnyIncludingMultilineComments = TokenRange.FromTokens(allTokens.concat([3 /* MultiLineCommentTrivia */])); + TokenRange.Keywords = TokenRange.FromRange(72 /* FirstKeyword */, 142 /* LastKeyword */); + TokenRange.BinaryOperators = TokenRange.FromRange(27 /* FirstBinaryOperator */, 70 /* LastBinaryOperator */); + TokenRange.BinaryKeywordOperators = TokenRange.FromTokens([ + 92 /* InKeyword */, 93 /* InstanceOfKeyword */, 142 /* OfKeyword */, 118 /* AsKeyword */, 126 /* IsKeyword */ + ]); + TokenRange.UnaryPrefixOperators = TokenRange.FromTokens([ + 43 /* PlusPlusToken */, 44 /* MinusMinusToken */, 52 /* TildeToken */, 51 /* ExclamationToken */ + ]); + TokenRange.UnaryPrefixExpressions = TokenRange.FromTokens([ + 8 /* NumericLiteral */, 71 /* Identifier */, 19 /* OpenParenToken */, 21 /* OpenBracketToken */, + 17 /* OpenBraceToken */, 99 /* ThisKeyword */, 94 /* NewKeyword */ + ]); + TokenRange.UnaryPreincrementExpressions = TokenRange.FromTokens([ + 71 /* Identifier */, 19 /* OpenParenToken */, 99 /* ThisKeyword */, 94 /* NewKeyword */ + ]); + TokenRange.UnaryPostincrementExpressions = TokenRange.FromTokens([ + 71 /* Identifier */, 20 /* CloseParenToken */, 22 /* CloseBracketToken */, 94 /* NewKeyword */ + ]); + TokenRange.UnaryPredecrementExpressions = TokenRange.FromTokens([ + 71 /* Identifier */, 19 /* OpenParenToken */, 99 /* ThisKeyword */, 94 /* NewKeyword */ + ]); + TokenRange.UnaryPostdecrementExpressions = TokenRange.FromTokens([ + 71 /* Identifier */, 20 /* CloseParenToken */, 22 /* CloseBracketToken */, 94 /* NewKeyword */ + ]); + TokenRange.Comments = TokenRange.FromTokens([2 /* SingleLineCommentTrivia */, 3 /* MultiLineCommentTrivia */]); + TokenRange.TypeNames = TokenRange.FromTokens([ + 71 /* Identifier */, 133 /* NumberKeyword */, 136 /* StringKeyword */, 122 /* BooleanKeyword */, + 137 /* SymbolKeyword */, 105 /* VoidKeyword */, 119 /* AnyKeyword */ + ]); + })(TokenRange = Shared.TokenRange || (Shared.TokenRange = {})); })(Shared = formatting.Shared || (formatting.Shared = {})); })(formatting = ts.formatting || (ts.formatting = {})); })(ts || (ts = {})); @@ -83135,9 +85766,7 @@ var ts; if (node.kind === 20 /* CloseParenToken */) { return -1 /* Unknown */; } - if (node.parent && (node.parent.kind === 181 /* CallExpression */ || - node.parent.kind === 182 /* NewExpression */) && - node.parent.expression !== node) { + if (node.parent && ts.isCallOrNewExpression(node.parent) && node.parent.expression !== node) { var fullCallOrNewExpression = node.parent.expression; var startingExpression = getStartingExpression(fullCallOrNewExpression); if (fullCallOrNewExpression === startingExpression) { @@ -83451,7 +86080,7 @@ var ts; return this; } if (index !== containingList.length - 1) { - var nextToken = ts.getTokenAtPosition(sourceFile, node.end); + var nextToken = ts.getTokenAtPosition(sourceFile, node.end, /*includeJsDocComment*/ false); if (nextToken && isSeparator(node, nextToken)) { // find first non-whitespace position in the leading trivia of the node var startPosition = ts.skipTrivia(sourceFile.text, getAdjustedStartPosition(sourceFile, node, {}, Position.FullStart), /*stopAfterLineBreak*/ false, /*stopAtComments*/ true); @@ -83463,7 +86092,7 @@ var ts; } } else { - var previousToken = ts.getTokenAtPosition(sourceFile, containingList[index - 1].end); + var previousToken = ts.getTokenAtPosition(sourceFile, containingList[index - 1].end, /*includeJsDocComment*/ false); if (previousToken && isSeparator(node, previousToken)) { this.deleteNodeRange(sourceFile, previousToken, node); } @@ -83540,7 +86169,7 @@ var ts; if (index !== containingList.length - 1) { // any element except the last one // use next sibling as an anchor - var nextToken = ts.getTokenAtPosition(sourceFile, after.end); + var nextToken = ts.getTokenAtPosition(sourceFile, after.end, /*includeJsDocComment*/ false); if (nextToken && isSeparator(after, nextToken)) { // for list // a, b, c @@ -83731,7 +86360,7 @@ var ts; }()); textChanges.ChangeTracker = ChangeTracker; function getNonformattedText(node, sourceFile, newLine) { - var options = { newLine: newLine, target: sourceFile.languageVersion }; + var options = { newLine: newLine, target: sourceFile && sourceFile.languageVersion }; var writer = new Writer(ts.getNewLineCharacter(options)); var printer = ts.createPrinter(options, writer); printer.writeNode(3 /* Unspecified */, node, sourceFile, writer); @@ -83760,27 +86389,8 @@ var ts; function isTrivia(s) { return ts.skipTrivia(s, 0) === s.length; } - var nullTransformationContext = { - enableEmitNotification: ts.noop, - enableSubstitution: ts.noop, - endLexicalEnvironment: function () { return undefined; }, - getCompilerOptions: ts.notImplemented, - getEmitHost: ts.notImplemented, - getEmitResolver: ts.notImplemented, - hoistFunctionDeclaration: ts.noop, - hoistVariableDeclaration: ts.noop, - isEmitNotificationEnabled: ts.notImplemented, - isSubstitutionEnabled: ts.notImplemented, - onEmitNode: ts.noop, - onSubstituteNode: ts.notImplemented, - readEmitHelpers: ts.notImplemented, - requestEmitHelper: ts.noop, - resumeLexicalEnvironment: ts.noop, - startLexicalEnvironment: ts.noop, - suspendLexicalEnvironment: ts.noop - }; function assignPositionsToNode(node) { - var visited = ts.visitEachChild(node, assignPositionsToNode, nullTransformationContext, assignPositionsToNodeArray, assignPositionsToNode); + var visited = ts.visitEachChild(node, assignPositionsToNode, ts.nullTransformationContext, assignPositionsToNodeArray, assignPositionsToNode); // create proxy node for non synthesized nodes var newNode = ts.nodeIsSynthesized(visited) ? visited @@ -83825,6 +86435,16 @@ var ts; setEnd(nodes, _this.lastNonTriviaPosition); } }; + this.onBeforeEmitToken = function (node) { + if (node) { + setPos(node, _this.lastNonTriviaPosition); + } + }; + this.onAfterEmitToken = function (node) { + if (node) { + setEnd(node, _this.lastNonTriviaPosition); + } + }; } Writer.prototype.setLastNonTriviaPosition = function (s, force) { if (force || !isTrivia(s)) { @@ -83893,14 +86513,14 @@ var ts; var codefix; (function (codefix) { var codeFixes = []; - function registerCodeFix(action) { - ts.forEach(action.errorCodes, function (error) { + function registerCodeFix(codeFix) { + ts.forEach(codeFix.errorCodes, function (error) { var fixes = codeFixes[error]; if (!fixes) { fixes = []; codeFixes[error] = fixes; } - fixes.push(action); + fixes.push(codeFix); }); } codefix.registerCodeFix = registerCodeFix; @@ -83924,6 +86544,45 @@ var ts; })(ts || (ts = {})); /* @internal */ var ts; +(function (ts) { + var refactor; + (function (refactor_1) { + // A map with the refactor code as key, the refactor itself as value + // e.g. nonSuggestableRefactors[refactorCode] -> the refactor you want + var refactors = ts.createMap(); + function registerRefactor(refactor) { + refactors.set(refactor.name, refactor); + } + refactor_1.registerRefactor = registerRefactor; + function getApplicableRefactors(context) { + var results; + var refactorList = []; + refactors.forEach(function (refactor) { + refactorList.push(refactor); + }); + for (var _i = 0, refactorList_1 = refactorList; _i < refactorList_1.length; _i++) { + var refactor_2 = refactorList_1[_i]; + if (context.cancellationToken && context.cancellationToken.isCancellationRequested()) { + return results; + } + var infos = refactor_2.getAvailableActions(context); + if (infos && infos.length) { + (_a = (results || (results = []))).push.apply(_a, infos); + } + } + return results; + var _a; + } + refactor_1.getApplicableRefactors = getApplicableRefactors; + function getEditsForRefactor(context, refactorName, actionName) { + var refactor = refactors.get(refactorName); + return refactor && refactor.getEditsForAction(context, actionName); + } + refactor_1.getEditsForRefactor = getEditsForRefactor; + })(refactor = ts.refactor || (ts.refactor = {})); +})(ts || (ts = {})); +/* @internal */ +var ts; (function (ts) { var codefix; (function (codefix) { @@ -83934,7 +86593,7 @@ var ts; function getActionForClassLikeIncorrectImplementsInterface(context) { var sourceFile = context.sourceFile; var start = context.span.start; - var token = ts.getTokenAtPosition(sourceFile, start); + var token = ts.getTokenAtPosition(sourceFile, start, /*includeJsDocComment*/ false); var checker = context.program.getTypeChecker(); var classDeclaration = ts.getContainingClass(token); if (!classDeclaration) { @@ -83990,89 +86649,123 @@ var ts; var codefix; (function (codefix) { codefix.registerCodeFix({ - errorCodes: [ts.Diagnostics.Property_0_does_not_exist_on_type_1.code], + errorCodes: [ts.Diagnostics.Property_0_does_not_exist_on_type_1.code, + ts.Diagnostics.Property_0_does_not_exist_on_type_1_Did_you_mean_2.code], getCodeActions: getActionsForAddMissingMember }); function getActionsForAddMissingMember(context) { - var sourceFile = context.sourceFile; + var tokenSourceFile = context.sourceFile; var start = context.span.start; - // This is the identifier of the missing property. eg: + // The identifier of the missing property. eg: // this.missing = 1; // ^^^^^^^ - var token = ts.getTokenAtPosition(sourceFile, start); + var token = ts.getTokenAtPosition(tokenSourceFile, start, /*includeJsDocComment*/ false); if (token.kind !== 71 /* Identifier */) { return undefined; } - if (!ts.isPropertyAccessExpression(token.parent) || token.parent.expression.kind !== 99 /* ThisKeyword */) { + if (!ts.isPropertyAccessExpression(token.parent)) { return undefined; } - var classMemberDeclaration = ts.getThisContainer(token, /*includeArrowFunctions*/ false); - if (!ts.isClassElement(classMemberDeclaration)) { - return undefined; + var tokenName = token.getText(tokenSourceFile); + var makeStatic = false; + var classDeclaration; + if (token.parent.expression.kind === 99 /* ThisKeyword */) { + var containingClassMemberDeclaration = ts.getThisContainer(token, /*includeArrowFunctions*/ false); + if (!ts.isClassElement(containingClassMemberDeclaration)) { + return undefined; + } + classDeclaration = containingClassMemberDeclaration.parent; + // Property accesses on `this` in a static method are accesses of a static member. + makeStatic = classDeclaration && ts.hasModifier(containingClassMemberDeclaration, 32 /* Static */); + } + else { + var checker = context.program.getTypeChecker(); + var leftExpression = token.parent.expression; + var leftExpressionType = checker.getTypeAtLocation(leftExpression); + if (leftExpressionType.flags & 32768 /* Object */) { + var symbol = leftExpressionType.symbol; + if (symbol.flags & 32 /* Class */) { + classDeclaration = symbol.declarations && symbol.declarations[0]; + if (leftExpressionType !== checker.getDeclaredTypeOfSymbol(symbol)) { + // The expression is a class symbol but the type is not the instance-side. + makeStatic = true; + } + } + } } - var classDeclaration = classMemberDeclaration.parent; if (!classDeclaration || !ts.isClassLike(classDeclaration)) { return undefined; } - var isStatic = ts.hasModifier(classMemberDeclaration, 32 /* Static */); - return ts.isInJavaScriptFile(sourceFile) ? getActionsForAddMissingMemberInJavaScriptFile() : getActionsForAddMissingMemberInTypeScriptFile(); - function getActionsForAddMissingMemberInJavaScriptFile() { - var memberName = token.getText(); - if (isStatic) { + var classDeclarationSourceFile = ts.getSourceFileOfNode(classDeclaration); + var classOpenBrace = ts.getOpenBraceOfClassLike(classDeclaration, classDeclarationSourceFile); + return ts.isInJavaScriptFile(classDeclarationSourceFile) ? + getActionsForAddMissingMemberInJavaScriptFile(classDeclaration, makeStatic) : + getActionsForAddMissingMemberInTypeScriptFile(classDeclaration, makeStatic); + function getActionsForAddMissingMemberInJavaScriptFile(classDeclaration, makeStatic) { + var actions; + var methodCodeAction = getActionForMethodDeclaration(/*includeTypeScriptSyntax*/ false); + if (methodCodeAction) { + actions = [methodCodeAction]; + } + if (makeStatic) { if (classDeclaration.kind === 199 /* ClassExpression */) { - return undefined; + return actions; } var className = classDeclaration.name.getText(); - return [{ - description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(ts.Diagnostics.Initialize_static_property_0), [memberName]), - changes: [{ - fileName: sourceFile.fileName, - textChanges: [{ - span: { start: classDeclaration.getEnd(), length: 0 }, - newText: "" + context.newLineCharacter + className + "." + memberName + " = undefined;" + context.newLineCharacter - }] - }] - }]; + var staticInitialization = ts.createStatement(ts.createAssignment(ts.createPropertyAccess(ts.createIdentifier(className), tokenName), ts.createIdentifier("undefined"))); + var staticInitializationChangeTracker = ts.textChanges.ChangeTracker.fromCodeFixContext(context); + staticInitializationChangeTracker.insertNodeAfter(classDeclarationSourceFile, classDeclaration, staticInitialization, { suffix: context.newLineCharacter }); + var initializeStaticAction = { + description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(ts.Diagnostics.Initialize_static_property_0), [tokenName]), + changes: staticInitializationChangeTracker.getChanges() + }; + (actions || (actions = [])).push(initializeStaticAction); + return actions; } else { var classConstructor = ts.getFirstConstructorWithBody(classDeclaration); if (!classConstructor) { - return undefined; + return actions; } - return [{ - description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(ts.Diagnostics.Initialize_property_0_in_the_constructor), [memberName]), - changes: [{ - fileName: sourceFile.fileName, - textChanges: [{ - span: { start: classConstructor.body.getEnd() - 1, length: 0 }, - newText: "this." + memberName + " = undefined;" + context.newLineCharacter - }] - }] - }]; + var propertyInitialization = ts.createStatement(ts.createAssignment(ts.createPropertyAccess(ts.createThis(), tokenName), ts.createIdentifier("undefined"))); + var propertyInitializationChangeTracker = ts.textChanges.ChangeTracker.fromCodeFixContext(context); + propertyInitializationChangeTracker.insertNodeAt(classDeclarationSourceFile, classConstructor.body.getEnd() - 1, propertyInitialization, { prefix: context.newLineCharacter, suffix: context.newLineCharacter }); + var initializeAction = { + description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(ts.Diagnostics.Initialize_property_0_in_the_constructor), [tokenName]), + changes: propertyInitializationChangeTracker.getChanges() + }; + (actions || (actions = [])).push(initializeAction); + return actions; } } - function getActionsForAddMissingMemberInTypeScriptFile() { + function getActionsForAddMissingMemberInTypeScriptFile(classDeclaration, makeStatic) { + var actions; + var methodCodeAction = getActionForMethodDeclaration(/*includeTypeScriptSyntax*/ true); + if (methodCodeAction) { + actions = [methodCodeAction]; + } var typeNode; if (token.parent.parent.kind === 194 /* BinaryExpression */) { var binaryExpression = token.parent.parent; + var otherExpression = token.parent === binaryExpression.left ? binaryExpression.right : binaryExpression.left; var checker = context.program.getTypeChecker(); - var widenedType = checker.getWidenedType(checker.getBaseTypeOfLiteralType(checker.getTypeAtLocation(binaryExpression.right))); + var widenedType = checker.getWidenedType(checker.getBaseTypeOfLiteralType(checker.getTypeAtLocation(otherExpression))); typeNode = checker.typeToTypeNode(widenedType, classDeclaration); } typeNode = typeNode || ts.createKeywordTypeNode(119 /* AnyKeyword */); - var openBrace = ts.getOpenBraceOfClassLike(classDeclaration, sourceFile); var property = ts.createProperty( /*decorators*/ undefined, - /*modifiers*/ isStatic ? [ts.createToken(115 /* StaticKeyword */)] : undefined, token.getText(sourceFile), + /*modifiers*/ makeStatic ? [ts.createToken(115 /* StaticKeyword */)] : undefined, tokenName, /*questionToken*/ undefined, typeNode, /*initializer*/ undefined); var propertyChangeTracker = ts.textChanges.ChangeTracker.fromCodeFixContext(context); - propertyChangeTracker.insertNodeAfter(sourceFile, openBrace, property, { suffix: context.newLineCharacter }); - var actions = [{ - description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(ts.Diagnostics.Add_declaration_for_missing_property_0), [token.getText()]), - changes: propertyChangeTracker.getChanges() - }]; - if (!isStatic) { + propertyChangeTracker.insertNodeAfter(classDeclarationSourceFile, classOpenBrace, property, { suffix: context.newLineCharacter }); + (actions || (actions = [])).push({ + description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(ts.Diagnostics.Declare_property_0), [tokenName]), + changes: propertyChangeTracker.getChanges() + }); + if (!makeStatic) { + // Index signatures cannot have the static modifier. var stringTypeNode = ts.createKeywordTypeNode(136 /* StringKeyword */); var indexingParameter = ts.createParameter( /*decorators*/ undefined, @@ -84080,18 +86773,86 @@ var ts; /*dotDotDotToken*/ undefined, "x", /*questionToken*/ undefined, stringTypeNode, /*initializer*/ undefined); - var indexSignature = ts.createIndexSignatureDeclaration( + var indexSignature = ts.createIndexSignature( /*decorators*/ undefined, /*modifiers*/ undefined, [indexingParameter], typeNode); var indexSignatureChangeTracker = ts.textChanges.ChangeTracker.fromCodeFixContext(context); - indexSignatureChangeTracker.insertNodeAfter(sourceFile, openBrace, indexSignature, { suffix: context.newLineCharacter }); + indexSignatureChangeTracker.insertNodeAfter(classDeclarationSourceFile, classOpenBrace, indexSignature, { suffix: context.newLineCharacter }); actions.push({ - description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(ts.Diagnostics.Add_index_signature_for_missing_property_0), [token.getText()]), + description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(ts.Diagnostics.Add_index_signature_for_property_0), [tokenName]), changes: indexSignatureChangeTracker.getChanges() }); } return actions; } + function getActionForMethodDeclaration(includeTypeScriptSyntax) { + if (token.parent.parent.kind === 181 /* CallExpression */) { + var callExpression = token.parent.parent; + var methodDeclaration = codefix.createMethodFromCallExpression(callExpression, tokenName, includeTypeScriptSyntax, makeStatic); + var methodDeclarationChangeTracker = ts.textChanges.ChangeTracker.fromCodeFixContext(context); + methodDeclarationChangeTracker.insertNodeAfter(classDeclarationSourceFile, classOpenBrace, methodDeclaration, { suffix: context.newLineCharacter }); + return { + description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(makeStatic ? + ts.Diagnostics.Declare_method_0 : + ts.Diagnostics.Declare_static_method_0), [tokenName]), + changes: methodDeclarationChangeTracker.getChanges() + }; + } + } + } + })(codefix = ts.codefix || (ts.codefix = {})); +})(ts || (ts = {})); +/* @internal */ +var ts; +(function (ts) { + var codefix; + (function (codefix) { + codefix.registerCodeFix({ + errorCodes: [ts.Diagnostics.Property_0_does_not_exist_on_type_1_Did_you_mean_2.code, + ts.Diagnostics.Cannot_find_name_0_Did_you_mean_1.code], + getCodeActions: getActionsForCorrectSpelling + }); + function getActionsForCorrectSpelling(context) { + var sourceFile = context.sourceFile; + // This is the identifier of the misspelled word. eg: + // this.speling = 1; + // ^^^^^^^ + var node = ts.getTokenAtPosition(sourceFile, context.span.start, /*includeJsDocComment*/ false); // TODO: GH#15852 + var checker = context.program.getTypeChecker(); + var suggestion; + if (node.kind === 71 /* Identifier */ && ts.isPropertyAccessExpression(node.parent)) { + var containingType = checker.getTypeAtLocation(node.parent.expression); + suggestion = checker.getSuggestionForNonexistentProperty(node, containingType); + } + else { + var meaning = ts.getMeaningFromLocation(node); + suggestion = checker.getSuggestionForNonexistentSymbol(node, ts.getTextOfNode(node), convertSemanticMeaningToSymbolFlags(meaning)); + } + if (suggestion) { + return [{ + description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(ts.Diagnostics.Change_spelling_to_0), [suggestion]), + changes: [{ + fileName: sourceFile.fileName, + textChanges: [{ + span: { start: node.getStart(), length: node.getWidth() }, + newText: suggestion + }], + }], + }]; + } + } + function convertSemanticMeaningToSymbolFlags(meaning) { + var flags = 0; + if (meaning & 4 /* Namespace */) { + flags |= 1920 /* Namespace */; + } + if (meaning & 2 /* Type */) { + flags |= 793064 /* Type */; + } + if (meaning & 1 /* Value */) { + flags |= 107455 /* Value */; + } + return flags; } })(codefix = ts.codefix || (ts.codefix = {})); })(ts || (ts = {})); @@ -84113,7 +86874,7 @@ var ts; var start = context.span.start; // This is the identifier in the case of a class declaration // or the class keyword token in the case of a class expression. - var token = ts.getTokenAtPosition(sourceFile, start); + var token = ts.getTokenAtPosition(sourceFile, start, /*includeJsDocComment*/ false); var checker = context.program.getTypeChecker(); if (ts.isClassLike(token.parent)) { var classDeclaration = token.parent; @@ -84151,7 +86912,7 @@ var ts; errorCodes: [ts.Diagnostics.super_must_be_called_before_accessing_this_in_the_constructor_of_a_derived_class.code], getCodeActions: function (context) { var sourceFile = context.sourceFile; - var token = ts.getTokenAtPosition(sourceFile, context.span.start); + var token = ts.getTokenAtPosition(sourceFile, context.span.start, /*includeJsDocComment*/ false); if (token.kind !== 99 /* ThisKeyword */) { return undefined; } @@ -84199,7 +86960,7 @@ var ts; errorCodes: [ts.Diagnostics.Constructors_for_derived_classes_must_contain_a_super_call.code], getCodeActions: function (context) { var sourceFile = context.sourceFile; - var token = ts.getTokenAtPosition(sourceFile, context.span.start); + var token = ts.getTokenAtPosition(sourceFile, context.span.start, /*includeJsDocComment*/ false); if (token.kind !== 123 /* ConstructorKeyword */) { return undefined; } @@ -84224,7 +86985,7 @@ var ts; getCodeActions: function (context) { var sourceFile = context.sourceFile; var start = context.span.start; - var token = ts.getTokenAtPosition(sourceFile, start); + var token = ts.getTokenAtPosition(sourceFile, start, /*includeJsDocComment*/ false); var classDeclNode = ts.getContainingClass(token); if (!(token.kind === 71 /* Identifier */ && ts.isClassLike(classDeclNode))) { return undefined; @@ -84264,7 +87025,7 @@ var ts; errorCodes: [ts.Diagnostics.Cannot_find_name_0_Did_you_mean_the_instance_member_this_0.code], getCodeActions: function (context) { var sourceFile = context.sourceFile; - var token = ts.getTokenAtPosition(sourceFile, context.span.start); + var token = ts.getTokenAtPosition(sourceFile, context.span.start, /*includeJsDocComment*/ false); if (token.kind !== 71 /* Identifier */) { return undefined; } @@ -84291,138 +87052,146 @@ var ts; getCodeActions: function (context) { var sourceFile = context.sourceFile; var start = context.span.start; - var token = ts.getTokenAtPosition(sourceFile, start); + var token = ts.getTokenAtPosition(sourceFile, start, /*includeJsDocComment*/ false); // this handles var ["computed"] = 12; if (token.kind === 21 /* OpenBracketToken */) { - token = ts.getTokenAtPosition(sourceFile, start + 1); + token = ts.getTokenAtPosition(sourceFile, start + 1, /*includeJsDocComment*/ false); } switch (token.kind) { case 71 /* Identifier */: - switch (token.parent.kind) { - case 226 /* VariableDeclaration */: - switch (token.parent.parent.parent.kind) { - case 214 /* ForStatement */: - var forStatement = token.parent.parent.parent; - var forInitializer = forStatement.initializer; - if (forInitializer.declarations.length === 1) { - return deleteNode(forInitializer); - } - else { - return deleteNodeInList(token.parent); - } - case 216 /* ForOfStatement */: - var forOfStatement = token.parent.parent.parent; - if (forOfStatement.initializer.kind === 227 /* VariableDeclarationList */) { - var forOfInitializer = forOfStatement.initializer; - return replaceNode(forOfInitializer.declarations[0], ts.createObjectLiteral()); - } - break; - case 215 /* ForInStatement */: - // There is no valid fix in the case of: - // for .. in - return undefined; - case 260 /* CatchClause */: - var catchClause = token.parent.parent; - var parameter = catchClause.variableDeclaration.getChildren()[0]; - return deleteNode(parameter); - default: - var variableStatement = token.parent.parent.parent; - if (variableStatement.declarationList.declarations.length === 1) { - return deleteNode(variableStatement); - } - else { - return deleteNodeInList(token.parent); - } - } - // TODO: #14885 - // falls through - case 145 /* TypeParameter */: - var typeParameters = token.parent.parent.typeParameters; - if (typeParameters.length === 1) { - var previousToken = ts.getTokenAtPosition(sourceFile, typeParameters.pos - 1); - if (!previousToken || previousToken.kind !== 27 /* LessThanToken */) { - return deleteRange(typeParameters); - } - var nextToken = ts.getTokenAtPosition(sourceFile, typeParameters.end); - if (!nextToken || nextToken.kind !== 29 /* GreaterThanToken */) { - return deleteRange(typeParameters); - } - return deleteNodeRange(previousToken, nextToken); - } - else { - return deleteNodeInList(token.parent); - } - case 146 /* Parameter */: - var functionDeclaration = token.parent.parent; - if (functionDeclaration.parameters.length === 1) { - return deleteNode(token.parent); - } - else { - return deleteNodeInList(token.parent); - } - // handle case where 'import a = A;' - case 237 /* ImportEqualsDeclaration */: - var importEquals = ts.getAncestor(token, 237 /* ImportEqualsDeclaration */); - return deleteNode(importEquals); - case 242 /* ImportSpecifier */: - var namedImports = token.parent.parent; - if (namedImports.elements.length === 1) { - // Only 1 import and it is unused. So the entire declaration should be removed. - var importSpec = ts.getAncestor(token, 238 /* ImportDeclaration */); - return deleteNode(importSpec); - } - else { - // delete import specifier - return deleteNodeInList(token.parent); - } - // handle case where "import d, * as ns from './file'" - // or "'import {a, b as ns} from './file'" - case 239 /* ImportClause */: - var importClause = token.parent; - if (!importClause.namedBindings) { - var importDecl = ts.getAncestor(importClause, 238 /* ImportDeclaration */); - return deleteNode(importDecl); - } - else { - // import |d,| * as ns from './file' - var start_4 = importClause.name.getStart(sourceFile); - var nextToken = ts.getTokenAtPosition(sourceFile, importClause.name.end); - if (nextToken && nextToken.kind === 26 /* CommaToken */) { - // shift first non-whitespace position after comma to the start position of the node - return deleteRange({ pos: start_4, end: ts.skipTrivia(sourceFile.text, nextToken.end, /*stopAfterLineBreaks*/ false, /*stopAtComments*/ true) }); - } - else { - return deleteNode(importClause.name); - } - } - case 240 /* NamespaceImport */: - var namespaceImport = token.parent; - if (namespaceImport.name === token && !namespaceImport.parent.name) { - var importDecl = ts.getAncestor(namespaceImport, 238 /* ImportDeclaration */); - return deleteNode(importDecl); - } - else { - var previousToken = ts.getTokenAtPosition(sourceFile, namespaceImport.pos - 1); - if (previousToken && previousToken.kind === 26 /* CommaToken */) { - var startPosition = ts.textChanges.getAdjustedStartPosition(sourceFile, previousToken, {}, ts.textChanges.Position.FullStart); - return deleteRange({ pos: startPosition, end: namespaceImport.end }); - } - return deleteRange(namespaceImport); - } - } - break; + return deleteIdentifierOrPrefixWithUnderscore(token); case 149 /* PropertyDeclaration */: case 240 /* NamespaceImport */: + return [deleteNode(token.parent)]; + default: + return [deleteDefault()]; + } + function deleteDefault() { + if (ts.isDeclarationName(token)) { return deleteNode(token.parent); + } + else if (ts.isLiteralComputedPropertyDeclarationName(token)) { + return deleteNode(token.parent.parent); + } + else { + return undefined; + } } - if (ts.isDeclarationName(token)) { - return deleteNode(token.parent); + function prefixIdentifierWithUnderscore(identifier) { + var startPosition = identifier.getStart(sourceFile, /*includeJsDocComment*/ false); + return { + description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(ts.Diagnostics.Prefix_0_with_an_underscore), { 0: token.getText() }), + changes: [{ + fileName: sourceFile.path, + textChanges: [{ + span: { start: startPosition, length: 0 }, + newText: "_" + }] + }] + }; } - else if (ts.isLiteralComputedPropertyDeclarationName(token)) { - return deleteNode(token.parent.parent); + function deleteIdentifierOrPrefixWithUnderscore(identifier) { + var parent = identifier.parent; + switch (parent.kind) { + case 226 /* VariableDeclaration */: + return deleteVariableDeclarationOrPrefixWithUnderscore(identifier, parent); + case 145 /* TypeParameter */: + var typeParameters = parent.parent.typeParameters; + if (typeParameters.length === 1) { + var previousToken = ts.getTokenAtPosition(sourceFile, typeParameters.pos - 1, /*includeJsDocComment*/ false); + var nextToken = ts.getTokenAtPosition(sourceFile, typeParameters.end, /*includeJsDocComment*/ false); + ts.Debug.assert(previousToken.kind === 27 /* LessThanToken */); + ts.Debug.assert(nextToken.kind === 29 /* GreaterThanToken */); + return [deleteNodeRange(previousToken, nextToken)]; + } + else { + return [deleteNodeInList(parent)]; + } + case 146 /* Parameter */: + var functionDeclaration = parent.parent; + return [functionDeclaration.parameters.length === 1 ? deleteNode(parent) : deleteNodeInList(parent), + prefixIdentifierWithUnderscore(identifier)]; + // handle case where 'import a = A;' + case 237 /* ImportEqualsDeclaration */: + var importEquals = ts.getAncestor(identifier, 237 /* ImportEqualsDeclaration */); + return [deleteNode(importEquals)]; + case 242 /* ImportSpecifier */: + var namedImports = parent.parent; + if (namedImports.elements.length === 1) { + // Only 1 import and it is unused. So the entire declaration should be removed. + var importSpec = ts.getAncestor(identifier, 238 /* ImportDeclaration */); + return [deleteNode(importSpec)]; + } + else { + // delete import specifier + return [deleteNodeInList(parent)]; + } + // handle case where "import d, * as ns from './file'" + // or "'import {a, b as ns} from './file'" + case 239 /* ImportClause */:// this covers both 'import |d|' and 'import |d,| *' + var importClause = parent; + if (!importClause.namedBindings) { + var importDecl = ts.getAncestor(importClause, 238 /* ImportDeclaration */); + return [deleteNode(importDecl)]; + } + else { + // import |d,| * as ns from './file' + var start_4 = importClause.name.getStart(sourceFile); + var nextToken = ts.getTokenAtPosition(sourceFile, importClause.name.end, /*includeJsDocComment*/ false); + if (nextToken && nextToken.kind === 26 /* CommaToken */) { + // shift first non-whitespace position after comma to the start position of the node + return [deleteRange({ pos: start_4, end: ts.skipTrivia(sourceFile.text, nextToken.end, /*stopAfterLineBreaks*/ false, /*stopAtComments*/ true) })]; + } + else { + return [deleteNode(importClause.name)]; + } + } + case 240 /* NamespaceImport */: + var namespaceImport = parent; + if (namespaceImport.name === identifier && !namespaceImport.parent.name) { + var importDecl = ts.getAncestor(namespaceImport, 238 /* ImportDeclaration */); + return [deleteNode(importDecl)]; + } + else { + var previousToken = ts.getTokenAtPosition(sourceFile, namespaceImport.pos - 1, /*includeJsDocComment*/ false); + if (previousToken && previousToken.kind === 26 /* CommaToken */) { + var startPosition = ts.textChanges.getAdjustedStartPosition(sourceFile, previousToken, {}, ts.textChanges.Position.FullStart); + return [deleteRange({ pos: startPosition, end: namespaceImport.end })]; + } + return [deleteRange(namespaceImport)]; + } + default: + return [deleteDefault()]; + } } - else { - return undefined; + // token.parent is a variableDeclaration + function deleteVariableDeclarationOrPrefixWithUnderscore(identifier, varDecl) { + switch (varDecl.parent.parent.kind) { + case 214 /* ForStatement */: + var forStatement = varDecl.parent.parent; + var forInitializer = forStatement.initializer; + return [forInitializer.declarations.length === 1 ? deleteNode(forInitializer) : deleteNodeInList(varDecl)]; + case 216 /* ForOfStatement */: + var forOfStatement = varDecl.parent.parent; + ts.Debug.assert(forOfStatement.initializer.kind === 227 /* VariableDeclarationList */); + var forOfInitializer = forOfStatement.initializer; + return [ + replaceNode(forOfInitializer.declarations[0], ts.createObjectLiteral()), + prefixIdentifierWithUnderscore(identifier) + ]; + case 215 /* ForInStatement */: + // There is no valid fix in the case of: + // for .. in + return [prefixIdentifierWithUnderscore(identifier)]; + default: + var variableStatement = varDecl.parent.parent; + if (variableStatement.declarationList.declarations.length === 1) { + return [deleteNode(variableStatement)]; + } + else { + return [deleteNodeInList(varDecl)]; + } + } } function deleteNode(n) { return makeChange(ts.textChanges.ChangeTracker.fromCodeFixContext(context).deleteNode(sourceFile, n)); @@ -84440,10 +87209,10 @@ var ts; return makeChange(ts.textChanges.ChangeTracker.fromCodeFixContext(context).replaceNode(sourceFile, n, newNode)); } function makeChange(changeTracker) { - return [{ - description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(ts.Diagnostics.Remove_declaration_for_Colon_0), { 0: token.getText() }), - changes: changeTracker.getChanges() - }]; + return { + description: ts.formatStringFromArgs(ts.getLocaleSpecificMessage(ts.Diagnostics.Remove_declaration_for_Colon_0), { 0: token.getText() }), + changes: changeTracker.getChanges() + }; } } }); @@ -84454,6 +87223,15 @@ var ts; (function (ts) { var codefix; (function (codefix) { + codefix.registerCodeFix({ + errorCodes: [ + ts.Diagnostics.Cannot_find_name_0.code, + ts.Diagnostics.Cannot_find_name_0_Did_you_mean_1.code, + ts.Diagnostics.Cannot_find_namespace_0.code, + ts.Diagnostics._0_refers_to_a_UMD_global_but_the_current_file_is_a_module_Consider_adding_an_import_instead.code + ], + getCodeActions: getImportCodeActions + }); var ModuleSpecifierComparison; (function (ModuleSpecifierComparison) { ModuleSpecifierComparison[ModuleSpecifierComparison["Better"] = 0] = "Better"; @@ -84551,400 +87329,408 @@ var ts; }; return ImportCodeActionMap; }()); - codefix.registerCodeFix({ - errorCodes: [ - ts.Diagnostics.Cannot_find_name_0.code, - ts.Diagnostics.Cannot_find_namespace_0.code, - ts.Diagnostics._0_refers_to_a_UMD_global_but_the_current_file_is_a_module_Consider_adding_an_import_instead.code - ], - getCodeActions: function (context) { - var sourceFile = context.sourceFile; - var checker = context.program.getTypeChecker(); - var allSourceFiles = context.program.getSourceFiles(); - var useCaseSensitiveFileNames = context.host.useCaseSensitiveFileNames ? context.host.useCaseSensitiveFileNames() : false; - var token = ts.getTokenAtPosition(sourceFile, context.span.start); - var name = token.getText(); - var symbolIdActionMap = new ImportCodeActionMap(); - // this is a module id -> module import declaration map - var cachedImportDeclarations = []; - var lastImportDeclaration; - var currentTokenMeaning = ts.getMeaningFromLocation(token); - if (context.errorCode === ts.Diagnostics._0_refers_to_a_UMD_global_but_the_current_file_is_a_module_Consider_adding_an_import_instead.code) { - var symbol = checker.getAliasedSymbol(checker.getSymbolAtLocation(token)); - return getCodeActionForImport(symbol, /*isDefault*/ false, /*isNamespaceImport*/ true); - } - var candidateModules = checker.getAmbientModules(); - for (var _i = 0, allSourceFiles_1 = allSourceFiles; _i < allSourceFiles_1.length; _i++) { - var otherSourceFile = allSourceFiles_1[_i]; - if (otherSourceFile !== sourceFile && ts.isExternalOrCommonJsModule(otherSourceFile)) { - candidateModules.push(otherSourceFile.symbol); - } - } - for (var _a = 0, candidateModules_1 = candidateModules; _a < candidateModules_1.length; _a++) { - var moduleSymbol = candidateModules_1[_a]; - context.cancellationToken.throwIfCancellationRequested(); - // check the default export - var defaultExport = checker.tryGetMemberInModuleExports("default", moduleSymbol); - if (defaultExport) { - var localSymbol = ts.getLocalSymbolForExportDefault(defaultExport); - if (localSymbol && localSymbol.name === name && checkSymbolHasMeaning(localSymbol, currentTokenMeaning)) { - // check if this symbol is already used - var symbolId = getUniqueSymbolId(localSymbol); - symbolIdActionMap.addActions(symbolId, getCodeActionForImport(moduleSymbol, /*isDefault*/ true)); - } - } - // check exports with the same name - var exportSymbolWithIdenticalName = checker.tryGetMemberInModuleExports(name, moduleSymbol); - if (exportSymbolWithIdenticalName && checkSymbolHasMeaning(exportSymbolWithIdenticalName, currentTokenMeaning)) { - var symbolId = getUniqueSymbolId(exportSymbolWithIdenticalName); - symbolIdActionMap.addActions(symbolId, getCodeActionForImport(moduleSymbol)); - } - } - return symbolIdActionMap.getAllActions(); - function getImportDeclarations(moduleSymbol) { - var moduleSymbolId = getUniqueSymbolId(moduleSymbol); - var cached = cachedImportDeclarations[moduleSymbolId]; - if (cached) { - return cached; + function getImportCodeActions(context) { + var sourceFile = context.sourceFile; + var checker = context.program.getTypeChecker(); + var allSourceFiles = context.program.getSourceFiles(); + var useCaseSensitiveFileNames = context.host.useCaseSensitiveFileNames ? context.host.useCaseSensitiveFileNames() : false; + var token = ts.getTokenAtPosition(sourceFile, context.span.start, /*includeJsDocComment*/ false); + var name = token.getText(); + var symbolIdActionMap = new ImportCodeActionMap(); + // this is a module id -> module import declaration map + var cachedImportDeclarations = []; + var lastImportDeclaration; + var currentTokenMeaning = ts.getMeaningFromLocation(token); + if (context.errorCode === ts.Diagnostics._0_refers_to_a_UMD_global_but_the_current_file_is_a_module_Consider_adding_an_import_instead.code) { + var umdSymbol = checker.getSymbolAtLocation(token); + var symbol = void 0; + var symbolName = void 0; + if (umdSymbol.flags & 8388608 /* Alias */) { + symbol = checker.getAliasedSymbol(umdSymbol); + symbolName = name; + } + else if (ts.isJsxOpeningLikeElement(token.parent) && token.parent.tagName === token) { + // The error wasn't for the symbolAtLocation, it was for the JSX tag itself, which needs access to e.g. `React`. + symbol = checker.getAliasedSymbol(checker.resolveNameAtLocation(token, checker.getJsxNamespace(), 107455 /* Value */)); + symbolName = symbol.name; + } + else { + ts.Debug.fail("Either the symbol or the JSX namespace should be a UMD global if we got here"); + } + return getCodeActionForImport(symbol, symbolName, /*isDefault*/ false, /*isNamespaceImport*/ true); + } + var candidateModules = checker.getAmbientModules(); + for (var _i = 0, allSourceFiles_1 = allSourceFiles; _i < allSourceFiles_1.length; _i++) { + var otherSourceFile = allSourceFiles_1[_i]; + if (otherSourceFile !== sourceFile && ts.isExternalOrCommonJsModule(otherSourceFile)) { + candidateModules.push(otherSourceFile.symbol); + } + } + for (var _a = 0, candidateModules_1 = candidateModules; _a < candidateModules_1.length; _a++) { + var moduleSymbol = candidateModules_1[_a]; + context.cancellationToken.throwIfCancellationRequested(); + // check the default export + var defaultExport = checker.tryGetMemberInModuleExports("default", moduleSymbol); + if (defaultExport) { + var localSymbol = ts.getLocalSymbolForExportDefault(defaultExport); + if (localSymbol && localSymbol.name === name && checkSymbolHasMeaning(localSymbol, currentTokenMeaning)) { + // check if this symbol is already used + var symbolId = getUniqueSymbolId(localSymbol); + symbolIdActionMap.addActions(symbolId, getCodeActionForImport(moduleSymbol, name, /*isDefault*/ true)); } - var existingDeclarations = []; - for (var _i = 0, _a = sourceFile.imports; _i < _a.length; _i++) { - var importModuleSpecifier = _a[_i]; - var importSymbol = checker.getSymbolAtLocation(importModuleSpecifier); - if (importSymbol === moduleSymbol) { - existingDeclarations.push(getImportDeclaration(importModuleSpecifier)); - } + } + // check exports with the same name + var exportSymbolWithIdenticalName = checker.tryGetMemberInModuleExports(name, moduleSymbol); + if (exportSymbolWithIdenticalName && checkSymbolHasMeaning(exportSymbolWithIdenticalName, currentTokenMeaning)) { + var symbolId = getUniqueSymbolId(exportSymbolWithIdenticalName); + symbolIdActionMap.addActions(symbolId, getCodeActionForImport(moduleSymbol, name)); + } + } + return symbolIdActionMap.getAllActions(); + function getImportDeclarations(moduleSymbol) { + var moduleSymbolId = getUniqueSymbolId(moduleSymbol); + var cached = cachedImportDeclarations[moduleSymbolId]; + if (cached) { + return cached; + } + var existingDeclarations = []; + for (var _i = 0, _a = sourceFile.imports; _i < _a.length; _i++) { + var importModuleSpecifier = _a[_i]; + var importSymbol = checker.getSymbolAtLocation(importModuleSpecifier); + if (importSymbol === moduleSymbol) { + existingDeclarations.push(getImportDeclaration(importModuleSpecifier)); } - cachedImportDeclarations[moduleSymbolId] = existingDeclarations; - return existingDeclarations; - function getImportDeclaration(moduleSpecifier) { - var node = moduleSpecifier; - while (node) { - if (node.kind === 238 /* ImportDeclaration */) { - return node; - } - if (node.kind === 237 /* ImportEqualsDeclaration */) { - return node; - } - node = node.parent; + } + cachedImportDeclarations[moduleSymbolId] = existingDeclarations; + return existingDeclarations; + function getImportDeclaration(moduleSpecifier) { + var node = moduleSpecifier; + while (node) { + if (node.kind === 238 /* ImportDeclaration */) { + return node; } - return undefined; + if (node.kind === 237 /* ImportEqualsDeclaration */) { + return node; + } + node = node.parent; } + return undefined; } - function getUniqueSymbolId(symbol) { - if (symbol.flags & 8388608 /* Alias */) { - return ts.getSymbolId(checker.getAliasedSymbol(symbol)); - } - return ts.getSymbolId(symbol); + } + function getUniqueSymbolId(symbol) { + if (symbol.flags & 8388608 /* Alias */) { + return ts.getSymbolId(checker.getAliasedSymbol(symbol)); } - function checkSymbolHasMeaning(symbol, meaning) { - var declarations = symbol.getDeclarations(); - return declarations ? ts.some(symbol.declarations, function (decl) { return !!(ts.getMeaningFromDeclaration(decl) & meaning); }) : false; + return ts.getSymbolId(symbol); + } + function checkSymbolHasMeaning(symbol, meaning) { + var declarations = symbol.getDeclarations(); + return declarations ? ts.some(symbol.declarations, function (decl) { return !!(ts.getMeaningFromDeclaration(decl) & meaning); }) : false; + } + function getCodeActionForImport(moduleSymbol, symbolName, isDefault, isNamespaceImport) { + var existingDeclarations = getImportDeclarations(moduleSymbol); + if (existingDeclarations.length > 0) { + // With an existing import statement, there are more than one actions the user can do. + return getCodeActionsForExistingImport(existingDeclarations); } - function getCodeActionForImport(moduleSymbol, isDefault, isNamespaceImport) { - var existingDeclarations = getImportDeclarations(moduleSymbol); - if (existingDeclarations.length > 0) { - // With an existing import statement, there are more than one actions the user can do. - return getCodeActionsForExistingImport(existingDeclarations); - } - else { - return [getCodeActionForNewImport()]; - } - function getCodeActionsForExistingImport(declarations) { - var actions = []; - // It is possible that multiple import statements with the same specifier exist in the file. - // e.g. - // - // import * as ns from "foo"; - // import { member1, member2 } from "foo"; - // - // member3/**/ <-- cusor here - // - // in this case we should provie 2 actions: - // 1. change "member3" to "ns.member3" - // 2. add "member3" to the second import statement's import list - // and it is up to the user to decide which one fits best. - var namespaceImportDeclaration; - var namedImportDeclaration; - var existingModuleSpecifier; - for (var _i = 0, declarations_14 = declarations; _i < declarations_14.length; _i++) { - var declaration = declarations_14[_i]; - if (declaration.kind === 238 /* ImportDeclaration */) { - var namedBindings = declaration.importClause && declaration.importClause.namedBindings; - if (namedBindings && namedBindings.kind === 240 /* NamespaceImport */) { - // case: - // import * as ns from "foo" - namespaceImportDeclaration = declaration; - } - else { - // cases: - // import default from "foo" - // import { bar } from "foo" or combination with the first one - // import "foo" - namedImportDeclaration = declaration; - } - existingModuleSpecifier = declaration.moduleSpecifier.getText(); - } - else { + else { + return [getCodeActionForNewImport()]; + } + function getCodeActionsForExistingImport(declarations) { + var actions = []; + // It is possible that multiple import statements with the same specifier exist in the file. + // e.g. + // + // import * as ns from "foo"; + // import { member1, member2 } from "foo"; + // + // member3/**/ <-- cusor here + // + // in this case we should provie 2 actions: + // 1. change "member3" to "ns.member3" + // 2. add "member3" to the second import statement's import list + // and it is up to the user to decide which one fits best. + var namespaceImportDeclaration; + var namedImportDeclaration; + var existingModuleSpecifier; + for (var _i = 0, declarations_14 = declarations; _i < declarations_14.length; _i++) { + var declaration = declarations_14[_i]; + if (declaration.kind === 238 /* ImportDeclaration */) { + var namedBindings = declaration.importClause && declaration.importClause.namedBindings; + if (namedBindings && namedBindings.kind === 240 /* NamespaceImport */) { // case: - // import foo = require("foo") + // import * as ns from "foo" namespaceImportDeclaration = declaration; - existingModuleSpecifier = getModuleSpecifierFromImportEqualsDeclaration(declaration); } + else { + // cases: + // import default from "foo" + // import { bar } from "foo" or combination with the first one + // import "foo" + namedImportDeclaration = declaration; + } + existingModuleSpecifier = declaration.moduleSpecifier.getText(); } - if (namespaceImportDeclaration) { - actions.push(getCodeActionForNamespaceImport(namespaceImportDeclaration)); + else { + // case: + // import foo = require("foo") + namespaceImportDeclaration = declaration; + existingModuleSpecifier = getModuleSpecifierFromImportEqualsDeclaration(declaration); } - if (!isNamespaceImport && namedImportDeclaration && namedImportDeclaration.importClause && - (namedImportDeclaration.importClause.name || namedImportDeclaration.importClause.namedBindings)) { - /** - * If the existing import declaration already has a named import list, just - * insert the identifier into that list. - */ - var fileTextChanges = getTextChangeForImportClause(namedImportDeclaration.importClause); - var moduleSpecifierWithoutQuotes = ts.stripQuotes(namedImportDeclaration.moduleSpecifier.getText()); - actions.push(createCodeAction(ts.Diagnostics.Add_0_to_existing_import_declaration_from_1, [name, moduleSpecifierWithoutQuotes], fileTextChanges, "InsertingIntoExistingImport", moduleSpecifierWithoutQuotes)); + } + if (namespaceImportDeclaration) { + actions.push(getCodeActionForNamespaceImport(namespaceImportDeclaration)); + } + if (!isNamespaceImport && namedImportDeclaration && namedImportDeclaration.importClause && + (namedImportDeclaration.importClause.name || namedImportDeclaration.importClause.namedBindings)) { + /** + * If the existing import declaration already has a named import list, just + * insert the identifier into that list. + */ + var fileTextChanges = getTextChangeForImportClause(namedImportDeclaration.importClause); + var moduleSpecifierWithoutQuotes = ts.stripQuotes(namedImportDeclaration.moduleSpecifier.getText()); + actions.push(createCodeAction(ts.Diagnostics.Add_0_to_existing_import_declaration_from_1, [name, moduleSpecifierWithoutQuotes], fileTextChanges, "InsertingIntoExistingImport", moduleSpecifierWithoutQuotes)); + } + else { + // we need to create a new import statement, but the existing module specifier can be reused. + actions.push(getCodeActionForNewImport(existingModuleSpecifier)); + } + return actions; + function getModuleSpecifierFromImportEqualsDeclaration(declaration) { + if (declaration.moduleReference && declaration.moduleReference.kind === 248 /* ExternalModuleReference */) { + return declaration.moduleReference.expression.getText(); + } + return declaration.moduleReference.getText(); + } + function getTextChangeForImportClause(importClause) { + var importList = importClause.namedBindings; + var newImportSpecifier = ts.createImportSpecifier(/*propertyName*/ undefined, ts.createIdentifier(name)); + // case 1: + // original text: import default from "module" + // change to: import default, { name } from "module" + // case 2: + // original text: import {} from "module" + // change to: import { name } from "module" + if (!importList || importList.elements.length === 0) { + var newImportClause = ts.createImportClause(importClause.name, ts.createNamedImports([newImportSpecifier])); + return createChangeTracker().replaceNode(sourceFile, importClause, newImportClause).getChanges(); + } + /** + * If the import list has one import per line, preserve that. Otherwise, insert on same line as last element + * import { + * foo + * } from "./module"; + */ + return createChangeTracker().insertNodeInListAfter(sourceFile, importList.elements[importList.elements.length - 1], newImportSpecifier).getChanges(); + } + function getCodeActionForNamespaceImport(declaration) { + var namespacePrefix; + if (declaration.kind === 238 /* ImportDeclaration */) { + namespacePrefix = declaration.importClause.namedBindings.name.getText(); } else { - // we need to create a new import statement, but the existing module specifier can be reused. - actions.push(getCodeActionForNewImport(existingModuleSpecifier)); + namespacePrefix = declaration.name.getText(); } - return actions; - function getModuleSpecifierFromImportEqualsDeclaration(declaration) { - if (declaration.moduleReference && declaration.moduleReference.kind === 248 /* ExternalModuleReference */) { - return declaration.moduleReference.expression.getText(); - } - return declaration.moduleReference.getText(); - } - function getTextChangeForImportClause(importClause) { - var importList = importClause.namedBindings; - var newImportSpecifier = ts.createImportSpecifier(/*propertyName*/ undefined, ts.createIdentifier(name)); - // case 1: - // original text: import default from "module" - // change to: import default, { name } from "module" - // case 2: - // original text: import {} from "module" - // change to: import { name } from "module" - if (!importList || importList.elements.length === 0) { - var newImportClause = ts.createImportClause(importClause.name, ts.createNamedImports([newImportSpecifier])); - return createChangeTracker().replaceNode(sourceFile, importClause, newImportClause).getChanges(); - } - /** - * If the import list has one import per line, preserve that. Otherwise, insert on same line as last element - * import { - * foo - * } from "./module"; - */ - return createChangeTracker().insertNodeInListAfter(sourceFile, importList.elements[importList.elements.length - 1], newImportSpecifier).getChanges(); - } - function getCodeActionForNamespaceImport(declaration) { - var namespacePrefix; - if (declaration.kind === 238 /* ImportDeclaration */) { - namespacePrefix = declaration.importClause.namedBindings.name.getText(); - } - else { - namespacePrefix = declaration.name.getText(); - } - namespacePrefix = ts.stripQuotes(namespacePrefix); - /** - * Cases: - * import * as ns from "mod" - * import default, * as ns from "mod" - * import ns = require("mod") - * - * Because there is no import list, we alter the reference to include the - * namespace instead of altering the import declaration. For example, "foo" would - * become "ns.foo" - */ - return createCodeAction(ts.Diagnostics.Change_0_to_1, [name, namespacePrefix + "." + name], createChangeTracker().replaceNode(sourceFile, token, ts.createPropertyAccess(ts.createIdentifier(namespacePrefix), name)).getChanges(), "CodeChange"); - } - } - function getCodeActionForNewImport(moduleSpecifier) { - if (!lastImportDeclaration) { - // insert after any existing imports - for (var i = sourceFile.statements.length - 1; i >= 0; i--) { - var statement = sourceFile.statements[i]; - if (statement.kind === 237 /* ImportEqualsDeclaration */ || statement.kind === 238 /* ImportDeclaration */) { - lastImportDeclaration = statement; - break; - } + namespacePrefix = ts.stripQuotes(namespacePrefix); + /** + * Cases: + * import * as ns from "mod" + * import default, * as ns from "mod" + * import ns = require("mod") + * + * Because there is no import list, we alter the reference to include the + * namespace instead of altering the import declaration. For example, "foo" would + * become "ns.foo" + */ + return createCodeAction(ts.Diagnostics.Change_0_to_1, [name, namespacePrefix + "." + name], createChangeTracker().replaceNode(sourceFile, token, ts.createPropertyAccess(ts.createIdentifier(namespacePrefix), name)).getChanges(), "CodeChange"); + } + } + function getCodeActionForNewImport(moduleSpecifier) { + if (!lastImportDeclaration) { + // insert after any existing imports + for (var i = sourceFile.statements.length - 1; i >= 0; i--) { + var statement = sourceFile.statements[i]; + if (statement.kind === 237 /* ImportEqualsDeclaration */ || statement.kind === 238 /* ImportDeclaration */) { + lastImportDeclaration = statement; + break; } } - var getCanonicalFileName = ts.createGetCanonicalFileName(useCaseSensitiveFileNames); - var moduleSpecifierWithoutQuotes = ts.stripQuotes(moduleSpecifier || getModuleSpecifierForNewImport()); - var changeTracker = createChangeTracker(); - var importClause = isDefault - ? ts.createImportClause(ts.createIdentifier(name), /*namedBindings*/ undefined) - : isNamespaceImport - ? ts.createImportClause(/*name*/ undefined, ts.createNamespaceImport(ts.createIdentifier(name))) - : ts.createImportClause(/*name*/ undefined, ts.createNamedImports([ts.createImportSpecifier(/*propertyName*/ undefined, ts.createIdentifier(name))])); - var importDecl = ts.createImportDeclaration(/*decorators*/ undefined, /*modifiers*/ undefined, importClause, ts.createLiteral(moduleSpecifierWithoutQuotes)); - if (!lastImportDeclaration) { - changeTracker.insertNodeAt(sourceFile, sourceFile.getStart(), importDecl, { suffix: "" + context.newLineCharacter + context.newLineCharacter }); - } - else { - changeTracker.insertNodeAfter(sourceFile, lastImportDeclaration, importDecl, { suffix: context.newLineCharacter }); + } + var getCanonicalFileName = ts.createGetCanonicalFileName(useCaseSensitiveFileNames); + var moduleSpecifierWithoutQuotes = ts.stripQuotes(moduleSpecifier || getModuleSpecifierForNewImport()); + var changeTracker = createChangeTracker(); + var importClause = isDefault + ? ts.createImportClause(ts.createIdentifier(symbolName), /*namedBindings*/ undefined) + : isNamespaceImport + ? ts.createImportClause(/*name*/ undefined, ts.createNamespaceImport(ts.createIdentifier(symbolName))) + : ts.createImportClause(/*name*/ undefined, ts.createNamedImports([ts.createImportSpecifier(/*propertyName*/ undefined, ts.createIdentifier(symbolName))])); + var importDecl = ts.createImportDeclaration(/*decorators*/ undefined, /*modifiers*/ undefined, importClause, ts.createLiteral(moduleSpecifierWithoutQuotes)); + if (!lastImportDeclaration) { + changeTracker.insertNodeAt(sourceFile, sourceFile.getStart(), importDecl, { suffix: "" + context.newLineCharacter + context.newLineCharacter }); + } + else { + changeTracker.insertNodeAfter(sourceFile, lastImportDeclaration, importDecl, { suffix: context.newLineCharacter }); + } + // if this file doesn't have any import statements, insert an import statement and then insert a new line + // between the only import statement and user code. Otherwise just insert the statement because chances + // are there are already a new line seperating code and import statements. + return createCodeAction(ts.Diagnostics.Import_0_from_1, [symbolName, "\"" + moduleSpecifierWithoutQuotes + "\""], changeTracker.getChanges(), "NewImport", moduleSpecifierWithoutQuotes); + function getModuleSpecifierForNewImport() { + var fileName = sourceFile.fileName; + var moduleFileName = moduleSymbol.valueDeclaration.getSourceFile().fileName; + var sourceDirectory = ts.getDirectoryPath(fileName); + var options = context.program.getCompilerOptions(); + return tryGetModuleNameFromAmbientModule() || + tryGetModuleNameFromTypeRoots() || + tryGetModuleNameAsNodeModule() || + tryGetModuleNameFromBaseUrl() || + tryGetModuleNameFromRootDirs() || + ts.removeFileExtension(getRelativePath(moduleFileName, sourceDirectory)); + function tryGetModuleNameFromAmbientModule() { + var decl = moduleSymbol.valueDeclaration; + if (ts.isModuleDeclaration(decl) && ts.isStringLiteral(decl.name)) { + return decl.name.text; + } } - // if this file doesn't have any import statements, insert an import statement and then insert a new line - // between the only import statement and user code. Otherwise just insert the statement because chances - // are there are already a new line seperating code and import statements. - return createCodeAction(ts.Diagnostics.Import_0_from_1, [name, "\"" + moduleSpecifierWithoutQuotes + "\""], changeTracker.getChanges(), "NewImport", moduleSpecifierWithoutQuotes); - function getModuleSpecifierForNewImport() { - var fileName = sourceFile.fileName; - var moduleFileName = moduleSymbol.valueDeclaration.getSourceFile().fileName; - var sourceDirectory = ts.getDirectoryPath(fileName); - var options = context.program.getCompilerOptions(); - return tryGetModuleNameFromAmbientModule() || - tryGetModuleNameFromTypeRoots() || - tryGetModuleNameAsNodeModule() || - tryGetModuleNameFromBaseUrl() || - tryGetModuleNameFromRootDirs() || - ts.removeFileExtension(getRelativePath(moduleFileName, sourceDirectory)); - function tryGetModuleNameFromAmbientModule() { - if (moduleSymbol.valueDeclaration.kind !== 265 /* SourceFile */) { - return moduleSymbol.name; - } + function tryGetModuleNameFromBaseUrl() { + if (!options.baseUrl) { + return undefined; } - function tryGetModuleNameFromBaseUrl() { - if (!options.baseUrl) { - return undefined; - } - var relativeName = getRelativePathIfInDirectory(moduleFileName, options.baseUrl); - if (!relativeName) { - return undefined; - } - var relativeNameWithIndex = ts.removeFileExtension(relativeName); - relativeName = removeExtensionAndIndexPostFix(relativeName); - if (options.paths) { - for (var key in options.paths) { - for (var _i = 0, _a = options.paths[key]; _i < _a.length; _i++) { - var pattern = _a[_i]; - var indexOfStar = pattern.indexOf("*"); - if (indexOfStar === 0 && pattern.length === 1) { - continue; - } - else if (indexOfStar !== -1) { - var prefix = pattern.substr(0, indexOfStar); - var suffix = pattern.substr(indexOfStar + 1); - if (relativeName.length >= prefix.length + suffix.length && - ts.startsWith(relativeName, prefix) && - ts.endsWith(relativeName, suffix)) { - var matchedStar = relativeName.substr(prefix.length, relativeName.length - suffix.length); - return key.replace("\*", matchedStar); - } - } - else if (pattern === relativeName || pattern === relativeNameWithIndex) { - return key; + var relativeName = getRelativePathIfInDirectory(moduleFileName, options.baseUrl); + if (!relativeName) { + return undefined; + } + var relativeNameWithIndex = ts.removeFileExtension(relativeName); + relativeName = removeExtensionAndIndexPostFix(relativeName); + if (options.paths) { + for (var key in options.paths) { + for (var _i = 0, _a = options.paths[key]; _i < _a.length; _i++) { + var pattern = _a[_i]; + var indexOfStar = pattern.indexOf("*"); + if (indexOfStar === 0 && pattern.length === 1) { + continue; + } + else if (indexOfStar !== -1) { + var prefix = pattern.substr(0, indexOfStar); + var suffix = pattern.substr(indexOfStar + 1); + if (relativeName.length >= prefix.length + suffix.length && + ts.startsWith(relativeName, prefix) && + ts.endsWith(relativeName, suffix)) { + var matchedStar = relativeName.substr(prefix.length, relativeName.length - suffix.length); + return key.replace("\*", matchedStar); } } + else if (pattern === relativeName || pattern === relativeNameWithIndex) { + return key; + } } } - return relativeName; } - function tryGetModuleNameFromRootDirs() { - if (options.rootDirs) { - var normalizedTargetPath = getPathRelativeToRootDirs(moduleFileName, options.rootDirs); - var normalizedSourcePath = getPathRelativeToRootDirs(sourceDirectory, options.rootDirs); - if (normalizedTargetPath !== undefined) { - var relativePath = normalizedSourcePath !== undefined ? getRelativePath(normalizedTargetPath, normalizedSourcePath) : normalizedTargetPath; - return ts.removeFileExtension(relativePath); - } + return relativeName; + } + function tryGetModuleNameFromRootDirs() { + if (options.rootDirs) { + var normalizedTargetPath = getPathRelativeToRootDirs(moduleFileName, options.rootDirs); + var normalizedSourcePath = getPathRelativeToRootDirs(sourceDirectory, options.rootDirs); + if (normalizedTargetPath !== undefined) { + var relativePath = normalizedSourcePath !== undefined ? getRelativePath(normalizedTargetPath, normalizedSourcePath) : normalizedTargetPath; + return ts.removeFileExtension(relativePath); } - return undefined; } - function tryGetModuleNameFromTypeRoots() { - var typeRoots = ts.getEffectiveTypeRoots(options, context.host); - if (typeRoots) { - var normalizedTypeRoots = ts.map(typeRoots, function (typeRoot) { return ts.toPath(typeRoot, /*basePath*/ undefined, getCanonicalFileName); }); - for (var _i = 0, normalizedTypeRoots_1 = normalizedTypeRoots; _i < normalizedTypeRoots_1.length; _i++) { - var typeRoot = normalizedTypeRoots_1[_i]; - if (ts.startsWith(moduleFileName, typeRoot)) { - var relativeFileName = moduleFileName.substring(typeRoot.length + 1); - return removeExtensionAndIndexPostFix(relativeFileName); - } + return undefined; + } + function tryGetModuleNameFromTypeRoots() { + var typeRoots = ts.getEffectiveTypeRoots(options, context.host); + if (typeRoots) { + var normalizedTypeRoots = ts.map(typeRoots, function (typeRoot) { return ts.toPath(typeRoot, /*basePath*/ undefined, getCanonicalFileName); }); + for (var _i = 0, normalizedTypeRoots_1 = normalizedTypeRoots; _i < normalizedTypeRoots_1.length; _i++) { + var typeRoot = normalizedTypeRoots_1[_i]; + if (ts.startsWith(moduleFileName, typeRoot)) { + var relativeFileName = moduleFileName.substring(typeRoot.length + 1); + return removeExtensionAndIndexPostFix(relativeFileName); } } } - function tryGetModuleNameAsNodeModule() { - if (ts.getEmitModuleResolutionKind(options) !== ts.ModuleResolutionKind.NodeJs) { - // nothing to do here - return undefined; - } - var indexOfNodeModules = moduleFileName.indexOf("node_modules"); - if (indexOfNodeModules < 0) { - return undefined; - } - var relativeFileName; - if (sourceDirectory.indexOf(moduleFileName.substring(0, indexOfNodeModules - 1)) === 0) { - // if node_modules folder is in this folder or any of its parent folder, no need to keep it. - relativeFileName = moduleFileName.substring(indexOfNodeModules + 13 /* "node_modules\".length */); - } - else { - relativeFileName = getRelativePath(moduleFileName, sourceDirectory); - } - relativeFileName = ts.removeFileExtension(relativeFileName); - if (ts.endsWith(relativeFileName, "/index")) { - relativeFileName = ts.getDirectoryPath(relativeFileName); - } - else { - try { - var moduleDirectory = ts.getDirectoryPath(moduleFileName); - var packageJsonContent = JSON.parse(context.host.readFile(ts.combinePaths(moduleDirectory, "package.json"))); - if (packageJsonContent) { - var mainFile = packageJsonContent.main || packageJsonContent.typings; - if (mainFile) { - var mainExportFile = ts.toPath(mainFile, moduleDirectory, getCanonicalFileName); - if (ts.removeFileExtension(mainExportFile) === ts.removeFileExtension(moduleFileName)) { - relativeFileName = ts.getDirectoryPath(relativeFileName); - } + } + function tryGetModuleNameAsNodeModule() { + if (ts.getEmitModuleResolutionKind(options) !== ts.ModuleResolutionKind.NodeJs) { + // nothing to do here + return undefined; + } + var indexOfNodeModules = moduleFileName.indexOf("node_modules"); + if (indexOfNodeModules < 0) { + return undefined; + } + var relativeFileName; + if (sourceDirectory.indexOf(moduleFileName.substring(0, indexOfNodeModules - 1)) === 0) { + // if node_modules folder is in this folder or any of its parent folder, no need to keep it. + relativeFileName = moduleFileName.substring(indexOfNodeModules + 13 /* "node_modules\".length */); + } + else { + relativeFileName = getRelativePath(moduleFileName, sourceDirectory); + } + relativeFileName = ts.removeFileExtension(relativeFileName); + if (ts.endsWith(relativeFileName, "/index")) { + relativeFileName = ts.getDirectoryPath(relativeFileName); + } + else { + try { + var moduleDirectory = ts.getDirectoryPath(moduleFileName); + var packageJsonContent = JSON.parse(context.host.readFile(ts.combinePaths(moduleDirectory, "package.json"))); + if (packageJsonContent) { + var mainFile = packageJsonContent.main || packageJsonContent.typings; + if (mainFile) { + var mainExportFile = ts.toPath(mainFile, moduleDirectory, getCanonicalFileName); + if (ts.removeFileExtension(mainExportFile) === ts.removeFileExtension(moduleFileName)) { + relativeFileName = ts.getDirectoryPath(relativeFileName); } } } - catch (e) { } - } - return relativeFileName; - } - } - function getPathRelativeToRootDirs(path, rootDirs) { - for (var _i = 0, rootDirs_2 = rootDirs; _i < rootDirs_2.length; _i++) { - var rootDir = rootDirs_2[_i]; - var relativeName = getRelativePathIfInDirectory(path, rootDir); - if (relativeName !== undefined) { - return relativeName; } + catch (e) { } } - return undefined; + return ts.getPackageNameFromAtTypesDirectory(relativeFileName); } - function removeExtensionAndIndexPostFix(fileName) { - fileName = ts.removeFileExtension(fileName); - if (ts.endsWith(fileName, "/index")) { - fileName = fileName.substr(0, fileName.length - 6 /* "/index".length */); + } + function getPathRelativeToRootDirs(path, rootDirs) { + for (var _i = 0, rootDirs_2 = rootDirs; _i < rootDirs_2.length; _i++) { + var rootDir = rootDirs_2[_i]; + var relativeName = getRelativePathIfInDirectory(path, rootDir); + if (relativeName !== undefined) { + return relativeName; } - return fileName; - } - function getRelativePathIfInDirectory(path, directoryPath) { - var relativePath = ts.getRelativePathToDirectoryOrUrl(directoryPath, path, directoryPath, getCanonicalFileName, /*isAbsolutePathAnUrl*/ false); - return ts.isRootedDiskPath(relativePath) || ts.startsWith(relativePath, "..") ? undefined : relativePath; } - function getRelativePath(path, directoryPath) { - var relativePath = ts.getRelativePathToDirectoryOrUrl(directoryPath, path, directoryPath, getCanonicalFileName, /*isAbsolutePathAnUrl*/ false); - return ts.moduleHasNonRelativeName(relativePath) ? "./" + relativePath : relativePath; + return undefined; + } + function removeExtensionAndIndexPostFix(fileName) { + fileName = ts.removeFileExtension(fileName); + if (ts.endsWith(fileName, "/index")) { + fileName = fileName.substr(0, fileName.length - 6 /* "/index".length */); } + return fileName; + } + function getRelativePathIfInDirectory(path, directoryPath) { + var relativePath = ts.getRelativePathToDirectoryOrUrl(directoryPath, path, directoryPath, getCanonicalFileName, /*isAbsolutePathAnUrl*/ false); + return ts.isRootedDiskPath(relativePath) || ts.startsWith(relativePath, "..") ? undefined : relativePath; + } + function getRelativePath(path, directoryPath) { + var relativePath = ts.getRelativePathToDirectoryOrUrl(directoryPath, path, directoryPath, getCanonicalFileName, /*isAbsolutePathAnUrl*/ false); + return ts.moduleHasNonRelativeName(relativePath) ? "./" + relativePath : relativePath; } - } - function createChangeTracker() { - return ts.textChanges.ChangeTracker.fromCodeFixContext(context); - } - function createCodeAction(description, diagnosticArgs, changes, kind, moduleSpecifier) { - return { - description: ts.formatMessage.apply(undefined, [undefined, description].concat(diagnosticArgs)), - changes: changes, - kind: kind, - moduleSpecifier: moduleSpecifier - }; } } - }); + function createChangeTracker() { + return ts.textChanges.ChangeTracker.fromCodeFixContext(context); + } + function createCodeAction(description, diagnosticArgs, changes, kind, moduleSpecifier) { + return { + description: ts.formatMessage.apply(undefined, [undefined, description].concat(diagnosticArgs)), + changes: changes, + kind: kind, + moduleSpecifier: moduleSpecifier + }; + } + } })(codefix = ts.codefix || (ts.codefix = {})); })(ts || (ts = {})); /* @internal */ @@ -84971,7 +87757,7 @@ var ts; // We also want to check if the previous line holds a comment for a node on the next line // if so, we do not want to separate the node from its comment if we can. if (!ts.isInComment(sourceFile, startPosition) && !ts.isInString(sourceFile, startPosition) && !ts.isInTemplateString(sourceFile, startPosition)) { - var token = ts.getTouchingToken(sourceFile, startPosition); + var token = ts.getTouchingToken(sourceFile, startPosition, /*includeJsDocComment*/ false); var tokenLeadingCommnets = ts.getLeadingCommentRangesOfNode(token, sourceFile); if (!tokenLeadingCommnets || !tokenLeadingCommnets.length || tokenLeadingCommnets[0].pos >= startPosition) { return { @@ -85134,7 +87920,7 @@ var ts; return undefined; } function signatureToMethodDeclaration(signature, enclosingDeclaration, body) { - var signatureDeclaration = checker.signatureToSignatureDeclaration(signature, 151 /* MethodDeclaration */, enclosingDeclaration); + var signatureDeclaration = checker.signatureToSignatureDeclaration(signature, 151 /* MethodDeclaration */, enclosingDeclaration, ts.NodeBuilderFlags.SuppressAnyReturnType); if (signatureDeclaration) { signatureDeclaration.decorators = undefined; signatureDeclaration.modifiers = modifiers; @@ -85145,6 +87931,41 @@ var ts; return signatureDeclaration; } } + function createMethodFromCallExpression(callExpression, methodName, includeTypeScriptSyntax, makeStatic) { + var parameters = createDummyParameters(callExpression.arguments.length, /*names*/ undefined, /*minArgumentCount*/ undefined, includeTypeScriptSyntax); + var typeParameters; + if (includeTypeScriptSyntax) { + var typeArgCount = ts.length(callExpression.typeArguments); + for (var i = 0; i < typeArgCount; i++) { + var name = typeArgCount < 8 ? String.fromCharCode(84 /* T */ + i) : "T" + i; + var typeParameter = ts.createTypeParameterDeclaration(name, /*constraint*/ undefined, /*defaultType*/ undefined); + (typeParameters ? typeParameters : typeParameters = []).push(typeParameter); + } + } + var newMethod = ts.createMethod( + /*decorators*/ undefined, + /*modifiers*/ makeStatic ? [ts.createToken(115 /* StaticKeyword */)] : undefined, + /*asteriskToken*/ undefined, methodName, + /*questionToken*/ undefined, typeParameters, parameters, + /*type*/ includeTypeScriptSyntax ? ts.createKeywordTypeNode(119 /* AnyKeyword */) : undefined, createStubbedMethodBody()); + return newMethod; + } + codefix.createMethodFromCallExpression = createMethodFromCallExpression; + function createDummyParameters(argCount, names, minArgumentCount, addAnyType) { + var parameters = []; + for (var i = 0; i < argCount; i++) { + var newParameter = ts.createParameter( + /*decorators*/ undefined, + /*modifiers*/ undefined, + /*dotDotDotToken*/ undefined, + /*name*/ names && names[i] || "arg" + i, + /*questionToken*/ minArgumentCount !== undefined && i >= minArgumentCount ? ts.createToken(55 /* QuestionToken */) : undefined, + /*type*/ addAnyType ? ts.createKeywordTypeNode(119 /* AnyKeyword */) : undefined, + /*initializer*/ undefined); + parameters.push(newParameter); + } + return parameters; + } function createMethodImplementingSignatures(signatures, name, optional, modifiers) { /** This is *a* signature with the maximal number of arguments, * such that if there is a "maximal" signature without rest arguments, @@ -85165,17 +87986,7 @@ var ts; } var maxNonRestArgs = maxArgsSignature.parameters.length - (maxArgsSignature.hasRestParameter ? 1 : 0); var maxArgsParameterSymbolNames = maxArgsSignature.parameters.map(function (symbol) { return symbol.getName(); }); - var parameters = []; - for (var i = 0; i < maxNonRestArgs; i++) { - var anyType = ts.createKeywordTypeNode(119 /* AnyKeyword */); - var newParameter = ts.createParameter( - /*decorators*/ undefined, - /*modifiers*/ undefined, - /*dotDotDotToken*/ undefined, maxArgsParameterSymbolNames[i], - /*questionToken*/ i >= minArgumentCount ? ts.createToken(55 /* QuestionToken */) : undefined, anyType, - /*initializer*/ undefined); - parameters.push(newParameter); - } + var parameters = createDummyParameters(maxNonRestArgs, maxArgsParameterSymbolNames, minArgumentCount, /*addAnyType*/ true); if (someSigHasRestParameter) { var anyArrayType = ts.createArrayTypeNode(ts.createKeywordTypeNode(119 /* AnyKeyword */)); var restParameter = ts.createParameter( @@ -85190,7 +88001,7 @@ var ts; /*returnType*/ undefined); } function createStubbedMethod(modifiers, name, optional, typeParameters, parameters, returnType) { - return ts.createMethodDeclaration( + return ts.createMethod( /*decorators*/ undefined, modifiers, /*asteriskToken*/ undefined, name, optional ? ts.createToken(55 /* QuestionToken */) : undefined, typeParameters, parameters, returnType, createStubbedMethodBody()); } @@ -85213,15 +88024,215 @@ var ts; })(ts || (ts = {})); /// /// +/// /// /// /// /// /// -/// +/// /// /// /// +/* @internal */ +var ts; +(function (ts) { + var refactor; + (function (refactor) { + var actionName = "convert"; + var convertFunctionToES6Class = { + name: "Convert to ES2015 class", + description: ts.Diagnostics.Convert_function_to_an_ES2015_class.message, + getEditsForAction: getEditsForAction, + getAvailableActions: getAvailableActions + }; + refactor.registerRefactor(convertFunctionToES6Class); + function getAvailableActions(context) { + var start = context.startPosition; + var node = ts.getTokenAtPosition(context.file, start, /*includeJsDocComment*/ false); + var checker = context.program.getTypeChecker(); + var symbol = checker.getSymbolAtLocation(node); + if (symbol && ts.isDeclarationOfFunctionOrClassExpression(symbol)) { + symbol = symbol.valueDeclaration.initializer.symbol; + } + if (symbol && (symbol.flags & 16 /* Function */) && symbol.members && (symbol.members.size > 0)) { + return [ + { + name: convertFunctionToES6Class.name, + description: convertFunctionToES6Class.description, + actions: [ + { + description: convertFunctionToES6Class.description, + name: actionName + } + ] + } + ]; + } + } + function getEditsForAction(context, action) { + // Somehow wrong action got invoked? + if (actionName !== action) { + return undefined; + } + var start = context.startPosition; + var sourceFile = context.file; + var checker = context.program.getTypeChecker(); + var token = ts.getTokenAtPosition(sourceFile, start, /*includeJsDocComment*/ false); + var ctorSymbol = checker.getSymbolAtLocation(token); + var newLine = context.rulesProvider.getFormatOptions().newLineCharacter; + var deletedNodes = []; + var deletes = []; + if (!(ctorSymbol.flags & (16 /* Function */ | 3 /* Variable */))) { + return undefined; + } + var ctorDeclaration = ctorSymbol.valueDeclaration; + var changeTracker = ts.textChanges.ChangeTracker.fromCodeFixContext(context); + var precedingNode; + var newClassDeclaration; + switch (ctorDeclaration.kind) { + case 228 /* FunctionDeclaration */: + precedingNode = ctorDeclaration; + deleteNode(ctorDeclaration); + newClassDeclaration = createClassFromFunctionDeclaration(ctorDeclaration); + break; + case 226 /* VariableDeclaration */: + precedingNode = ctorDeclaration.parent.parent; + if (ctorDeclaration.parent.declarations.length === 1) { + deleteNode(precedingNode); + } + else { + deleteNode(ctorDeclaration, /*inList*/ true); + } + newClassDeclaration = createClassFromVariableDeclaration(ctorDeclaration); + break; + } + if (!newClassDeclaration) { + return undefined; + } + // Because the preceding node could be touched, we need to insert nodes before delete nodes. + changeTracker.insertNodeAfter(sourceFile, precedingNode, newClassDeclaration, { suffix: newLine }); + for (var _i = 0, deletes_1 = deletes; _i < deletes_1.length; _i++) { + var deleteCallback = deletes_1[_i]; + deleteCallback(); + } + return { + edits: changeTracker.getChanges() + }; + function deleteNode(node, inList) { + if (inList === void 0) { inList = false; } + if (deletedNodes.some(function (n) { return ts.isNodeDescendantOf(node, n); })) { + // Parent node has already been deleted; do nothing + return; + } + deletedNodes.push(node); + if (inList) { + deletes.push(function () { return changeTracker.deleteNodeInList(sourceFile, node); }); + } + else { + deletes.push(function () { return changeTracker.deleteNode(sourceFile, node); }); + } + } + function createClassElementsFromSymbol(symbol) { + var memberElements = []; + // all instance members are stored in the "member" array of symbol + if (symbol.members) { + symbol.members.forEach(function (member) { + var memberElement = createClassElement(member, /*modifiers*/ undefined); + if (memberElement) { + memberElements.push(memberElement); + } + }); + } + // all static members are stored in the "exports" array of symbol + if (symbol.exports) { + symbol.exports.forEach(function (member) { + var memberElement = createClassElement(member, [ts.createToken(115 /* StaticKeyword */)]); + if (memberElement) { + memberElements.push(memberElement); + } + }); + } + return memberElements; + function shouldConvertDeclaration(_target, source) { + // Right now the only thing we can convert are function expressions - other values shouldn't get + // transformed. We can update this once ES public class properties are available. + return ts.isFunctionLike(source); + } + function createClassElement(symbol, modifiers) { + // both properties and methods are bound as property symbols + if (!(symbol.flags & 4 /* Property */)) { + return; + } + var memberDeclaration = symbol.valueDeclaration; + var assignmentBinaryExpression = memberDeclaration.parent; + if (!shouldConvertDeclaration(memberDeclaration, assignmentBinaryExpression.right)) { + return; + } + // delete the entire statement if this expression is the sole expression to take care of the semicolon at the end + var nodeToDelete = assignmentBinaryExpression.parent && assignmentBinaryExpression.parent.kind === 210 /* ExpressionStatement */ + ? assignmentBinaryExpression.parent : assignmentBinaryExpression; + deleteNode(nodeToDelete); + if (!assignmentBinaryExpression.right) { + return ts.createProperty([], modifiers, symbol.name, /*questionToken*/ undefined, + /*type*/ undefined, /*initializer*/ undefined); + } + switch (assignmentBinaryExpression.right.kind) { + case 186 /* FunctionExpression */: + var functionExpression = assignmentBinaryExpression.right; + return ts.createMethod(/*decorators*/ undefined, modifiers, /*asteriskToken*/ undefined, memberDeclaration.name, /*questionToken*/ undefined, + /*typeParameters*/ undefined, functionExpression.parameters, /*type*/ undefined, functionExpression.body); + case 187 /* ArrowFunction */: + var arrowFunction = assignmentBinaryExpression.right; + var arrowFunctionBody = arrowFunction.body; + var bodyBlock = void 0; + // case 1: () => { return [1,2,3] } + if (arrowFunctionBody.kind === 207 /* Block */) { + bodyBlock = arrowFunctionBody; + } + else { + var expression = arrowFunctionBody; + bodyBlock = ts.createBlock([ts.createReturn(expression)]); + } + return ts.createMethod(/*decorators*/ undefined, modifiers, /*asteriskToken*/ undefined, memberDeclaration.name, /*questionToken*/ undefined, + /*typeParameters*/ undefined, arrowFunction.parameters, /*type*/ undefined, bodyBlock); + default: + // Don't try to declare members in JavaScript files + if (ts.isSourceFileJavaScript(sourceFile)) { + return; + } + return ts.createProperty(/*decorators*/ undefined, modifiers, memberDeclaration.name, /*questionToken*/ undefined, + /*type*/ undefined, assignmentBinaryExpression.right); + } + } + } + function createClassFromVariableDeclaration(node) { + var initializer = node.initializer; + if (!initializer || initializer.kind !== 186 /* FunctionExpression */) { + return undefined; + } + if (node.name.kind !== 71 /* Identifier */) { + return undefined; + } + var memberElements = createClassElementsFromSymbol(initializer.symbol); + if (initializer.body) { + memberElements.unshift(ts.createConstructor(/*decorators*/ undefined, /*modifiers*/ undefined, initializer.parameters, initializer.body)); + } + return ts.createClassDeclaration(/*decorators*/ undefined, /*modifiers*/ undefined, node.name, + /*typeParameters*/ undefined, /*heritageClauses*/ undefined, memberElements); + } + function createClassFromFunctionDeclaration(node) { + var memberElements = createClassElementsFromSymbol(ctorSymbol); + if (node.body) { + memberElements.unshift(ts.createConstructor(/*decorators*/ undefined, /*modifiers*/ undefined, node.parameters, node.body)); + } + return ts.createClassDeclaration(/*decorators*/ undefined, /*modifiers*/ undefined, node.name, + /*typeParameters*/ undefined, /*heritageClauses*/ undefined, memberElements); + } + } + })(refactor = ts.refactor || (ts.refactor = {})); +})(ts || (ts = {})); +/// /// /// /// @@ -85248,7 +88259,9 @@ var ts; /// /// /// +/// /// +/// var ts; (function (ts) { /** The version of the language service API */ @@ -85256,7 +88269,7 @@ var ts; /* @internal */ var ruleProvider; function createNode(kind, pos, end, parent) { - var node = kind >= 143 /* FirstNode */ ? new NodeObject(kind, pos, end) : + var node = ts.isNodeKind(kind) ? new NodeObject(kind, pos, end) : kind === 71 /* Identifier */ ? new IdentifierObject(71 /* Identifier */, pos, end) : new TokenObject(kind, pos, end); node.parent = parent; @@ -85301,10 +88314,11 @@ var ts; } return sourceFile.text.substring(this.getStart(sourceFile), this.getEnd()); }; - NodeObject.prototype.addSyntheticNodes = function (nodes, pos, end, useJSDocScanner) { + NodeObject.prototype.addSyntheticNodes = function (nodes, pos, end) { ts.scanner.setTextPos(pos); while (pos < end) { - var token = useJSDocScanner ? ts.scanner.scanJSDocToken() : ts.scanner.scan(); + var token = ts.scanner.scan(); + ts.Debug.assert(token !== 1 /* EndOfFileToken */); // Else it would infinitely loop var textPos = ts.scanner.getTextPos(); if (textPos <= end) { nodes.push(createNode(token, pos, textPos, this)); @@ -85314,7 +88328,7 @@ var ts; return pos; }; NodeObject.prototype.createSyntaxList = function (nodes) { - var list = createNode(294 /* SyntaxList */, nodes.pos, nodes.end, this); + var list = createNode(295 /* SyntaxList */, nodes.pos, nodes.end, this); list._children = []; var pos = nodes.pos; for (var _i = 0, nodes_9 = nodes; _i < nodes_9.length; _i++) { @@ -85332,47 +88346,49 @@ var ts; }; NodeObject.prototype.createChildren = function (sourceFile) { var _this = this; - var children; - if (this.kind >= 143 /* FirstNode */) { - ts.scanner.setText((sourceFile || this.getSourceFile()).text); - children = []; - var pos_3 = this.pos; - var useJSDocScanner_1 = this.kind >= 283 /* FirstJSDocTagNode */ && this.kind <= 293 /* LastJSDocTagNode */; - var processNode = function (node) { - var isJSDocTagNode = ts.isJSDocTag(node); - if (!isJSDocTagNode && pos_3 < node.pos) { - pos_3 = _this.addSyntheticNodes(children, pos_3, node.pos, useJSDocScanner_1); - } - children.push(node); - if (!isJSDocTagNode) { - pos_3 = node.end; - } - }; - var processNodes = function (nodes) { - if (pos_3 < nodes.pos) { - pos_3 = _this.addSyntheticNodes(children, pos_3, nodes.pos, useJSDocScanner_1); - } - children.push(_this.createSyntaxList(nodes)); - pos_3 = nodes.end; - }; - // jsDocComments need to be the first children - if (this.jsDoc) { - for (var _i = 0, _a = this.jsDoc; _i < _a.length; _i++) { - var jsDocComment = _a[_i]; - processNode(jsDocComment); - } + if (!ts.isNodeKind(this.kind)) { + this._children = ts.emptyArray; + return; + } + if (ts.isJSDocCommentContainingNode(this)) { + /** Don't add trivia for "tokens" since this is in a comment. */ + var children_3 = []; + this.forEachChild(function (child) { children_3.push(child); }); + this._children = children_3; + return; + } + var children = []; + ts.scanner.setText((sourceFile || this.getSourceFile()).text); + var pos = this.pos; + var processNode = function (node) { + pos = _this.addSyntheticNodes(children, pos, node.pos); + children.push(node); + pos = node.end; + }; + var processNodes = function (nodes) { + if (pos < nodes.pos) { + pos = _this.addSyntheticNodes(children, pos, nodes.pos); } - // For syntactic classifications, all trivia are classcified together, including jsdoc comments. - // For that to work, the jsdoc comments should still be the leading trivia of the first child. - // Restoring the scanner position ensures that. - pos_3 = this.pos; - ts.forEachChild(this, processNode, processNodes); - if (pos_3 < this.end) { - this.addSyntheticNodes(children, pos_3, this.end); + children.push(_this.createSyntaxList(nodes)); + pos = nodes.end; + }; + // jsDocComments need to be the first children + if (this.jsDoc) { + for (var _i = 0, _a = this.jsDoc; _i < _a.length; _i++) { + var jsDocComment = _a[_i]; + processNode(jsDocComment); } - ts.scanner.setText(undefined); } - this._children = children || ts.emptyArray; + // For syntactic classifications, all trivia are classcified together, including jsdoc comments. + // For that to work, the jsdoc comments should still be the leading trivia of the first child. + // Restoring the scanner position ensures that. + pos = this.pos; + ts.forEachChild(this, processNode, processNodes); + if (pos < this.end) { + this.addSyntheticNodes(children, pos, this.end); + } + ts.scanner.setText(undefined); + this._children = children; }; NodeObject.prototype.getChildCount = function (sourceFile) { if (!this._children) @@ -85394,7 +88410,7 @@ var ts; if (!children.length) { return undefined; } - var child = ts.find(children, function (kid) { return kid.kind < 267 /* FirstJSDocNode */ || kid.kind > 293 /* LastJSDocNode */; }); + var child = ts.find(children, function (kid) { return kid.kind < 267 /* FirstJSDocNode */ || kid.kind > 294 /* LastJSDocNode */; }); return child.kind < 143 /* FirstNode */ ? child : child.getFirstToken(sourceFile); @@ -85641,9 +88657,9 @@ var ts; function getDeclarationName(declaration) { var name = ts.getNameOfDeclaration(declaration); if (name) { - var result_7 = getTextOfIdentifierOrLiteral(name); - if (result_7 !== undefined) { - return result_7; + var result_8 = getTextOfIdentifierOrLiteral(name); + if (result_8 !== undefined) { + return result_8; } if (name.kind === 144 /* ComputedPropertyName */) { var expr = name.expression; @@ -85721,8 +88737,9 @@ var ts; ts.forEachChild(decl.name, visit); break; } - if (decl.initializer) + if (decl.initializer) { visit(decl.initializer); + } } // falls through case 264 /* EnumMember */: @@ -85765,6 +88782,17 @@ var ts; }; return SourceFileObject; }(NodeObject)); + var SourceMapSourceObject = (function () { + function SourceMapSourceObject(fileName, text, skipTrivia) { + this.fileName = fileName; + this.text = text; + this.skipTrivia = skipTrivia; + } + SourceMapSourceObject.prototype.getLineAndCharacterOfPosition = function (pos) { + return ts.getLineAndCharacterOfPosition(this, pos); + }; + return SourceMapSourceObject; + }()); function getServicesObjectAllocator() { return { getNodeConstructor: function () { return NodeObject; }, @@ -85774,6 +88802,7 @@ var ts; getSymbolConstructor: function () { return SymbolObject; }, getTypeConstructor: function () { return TypeObject; }, getSignatureConstructor: function () { return SignatureObject; }, + getSourceMapSourceConstructor: function () { return SourceMapSourceObject; }, }; } function toEditorSettings(optionsAsMap) { @@ -85825,7 +88854,6 @@ var ts; var HostCache = (function () { function HostCache(host, getCanonicalFileName) { this.host = host; - this.getCanonicalFileName = getCanonicalFileName; // script id => script index this.currentDirectory = host.getCurrentDirectory(); this.fileNameToEntry = ts.createFileMap(); @@ -85855,19 +88883,15 @@ var ts; this.fileNameToEntry.set(path, entry); return entry; }; - HostCache.prototype.getEntry = function (path) { + HostCache.prototype.getEntryByPath = function (path) { return this.fileNameToEntry.get(path); }; - HostCache.prototype.contains = function (path) { + HostCache.prototype.containsEntryByPath = function (path) { return this.fileNameToEntry.contains(path); }; - HostCache.prototype.getOrCreateEntry = function (fileName) { - var path = ts.toPath(fileName, this.currentDirectory, this.getCanonicalFileName); - return this.getOrCreateEntryByPath(fileName, path); - }; HostCache.prototype.getOrCreateEntryByPath = function (fileName, path) { - return this.contains(path) - ? this.getEntry(path) + return this.containsEntryByPath(path) + ? this.getEntryByPath(path) : this.createEntry(fileName, path); }; HostCache.prototype.getRootFileNames = function () { @@ -85880,11 +88904,11 @@ var ts; return fileNames; }; HostCache.prototype.getVersion = function (path) { - var file = this.getEntry(path); + var file = this.getEntryByPath(path); return file && file.version; }; HostCache.prototype.getScriptSnapshot = function (path) { - var file = this.getEntry(path); + var file = this.getEntryByPath(path); return file && file.scriptSnapshot; }; return HostCache; @@ -86112,12 +89136,19 @@ var ts; getCurrentDirectory: function () { return currentDirectory; }, fileExists: function (fileName) { // stub missing host functionality - return hostCache.getOrCreateEntry(fileName) !== undefined; + var path = ts.toPath(fileName, currentDirectory, getCanonicalFileName); + return hostCache.containsEntryByPath(path) ? + !!hostCache.getEntryByPath(path) : + (host.fileExists && host.fileExists(fileName)); }, readFile: function (fileName) { // stub missing host functionality - var entry = hostCache.getOrCreateEntry(fileName); - return entry && entry.scriptSnapshot.getText(0, entry.scriptSnapshot.getLength()); + var path = ts.toPath(fileName, currentDirectory, getCanonicalFileName); + if (hostCache.containsEntryByPath(path)) { + var entry = hostCache.getEntryByPath(path); + return entry && entry.scriptSnapshot.getText(0, entry.scriptSnapshot.getLength()); + } + return host.readFile && host.readFile(fileName); }, directoryExists: function (directoryName) { return ts.directoryProbablyExists(directoryName, host); @@ -86250,7 +89281,9 @@ var ts; ts.forEach(program.getSourceFiles(), function (f) { return documentRegistry.releaseDocument(f.fileName, program.getCompilerOptions()); }); + program = undefined; } + host = undefined; } /// Diagnostics function getSyntacticDiagnostics(fileName) { @@ -86293,7 +89326,7 @@ var ts; function getQuickInfoAtPosition(fileName, position) { synchronizeHostData(); var sourceFile = getValidSourceFile(fileName); - var node = ts.getTouchingPropertyName(sourceFile, position); + var node = ts.getTouchingPropertyName(sourceFile, position, /*includeJsDocComment*/ true); if (node === sourceFile) { return undefined; } @@ -86348,7 +89381,7 @@ var ts; /// Goto implementation function getImplementationAtPosition(fileName, position) { synchronizeHostData(); - return ts.FindAllReferences.getImplementationsAtPosition(program.getTypeChecker(), cancellationToken, program.getSourceFiles(), getValidSourceFile(fileName), position); + return ts.FindAllReferences.getImplementationsAtPosition(program, cancellationToken, program.getSourceFiles(), getValidSourceFile(fileName), position); } /// References and Occurrences function getOccurrencesAtPosition(fileName, position) { @@ -86365,7 +89398,7 @@ var ts; synchronizeHostData(); var sourceFilesToSearch = ts.map(filesToSearch, function (f) { return program.getSourceFile(f); }); var sourceFile = getValidSourceFile(fileName); - return ts.DocumentHighlights.getDocumentHighlights(program.getTypeChecker(), cancellationToken, sourceFile, position, sourceFilesToSearch); + return ts.DocumentHighlights.getDocumentHighlights(program, cancellationToken, sourceFile, position, sourceFilesToSearch); } function getOccurrencesAtPositionCore(fileName, position) { return convertDocumentHighlights(getDocumentHighlights(fileName, position, [fileName])); @@ -86398,11 +89431,11 @@ var ts; } function getReferences(fileName, position, options) { synchronizeHostData(); - return ts.FindAllReferences.findReferencedEntries(program.getTypeChecker(), cancellationToken, program.getSourceFiles(), getValidSourceFile(fileName), position, options); + return ts.FindAllReferences.findReferencedEntries(program, cancellationToken, program.getSourceFiles(), getValidSourceFile(fileName), position, options); } function findReferences(fileName, position) { synchronizeHostData(); - return ts.FindAllReferences.findReferencedSymbols(program.getTypeChecker(), cancellationToken, program.getSourceFiles(), getValidSourceFile(fileName), position); + return ts.FindAllReferences.findReferencedSymbols(program, cancellationToken, program.getSourceFiles(), getValidSourceFile(fileName), position); } /// NavigateTo function getNavigateToItems(searchValue, maxResultCount, fileName, excludeDtsFiles) { @@ -86447,7 +89480,7 @@ var ts; function getNameOrDottedNameSpan(fileName, startPos, _endPos) { var sourceFile = syntaxTreeCache.getCurrentSourceFile(fileName); // Get node at the location - var node = ts.getTouchingPropertyName(sourceFile, startPos); + var node = ts.getTouchingPropertyName(sourceFile, startPos, /*includeJsDocComment*/ false); if (node === sourceFile) { return; } @@ -86541,7 +89574,7 @@ var ts; function getBraceMatchingAtPosition(fileName, position) { var sourceFile = syntaxTreeCache.getCurrentSourceFile(fileName); var result = []; - var token = ts.getTouchingToken(sourceFile, position); + var token = ts.getTouchingToken(sourceFile, position, /*includeJsDocComment*/ false); if (token.getStart(sourceFile) === position) { var matchKind = getMatchingTokenKind(token); // Ensure that there is a corresponding token to match ours. @@ -86705,8 +89738,7 @@ var ts; var matchPosition = matchArray.index + preamble.length; // OK, we have found a match in the file. This is only an acceptable match if // it is contained within a comment. - var token = ts.getTokenAtPosition(sourceFile, matchPosition); - if (!ts.isInsideComment(sourceFile, token, matchPosition)) { + if (!ts.isInComment(sourceFile, matchPosition)) { continue; } var descriptor = undefined; @@ -86794,6 +89826,28 @@ var ts; var defaultLibFileName = host.getDefaultLibFileName(host.getCompilationSettings()); return ts.Rename.getRenameInfo(program.getTypeChecker(), defaultLibFileName, getCanonicalFileName, getValidSourceFile(fileName), position); } + function getRefactorContext(file, positionOrRange, formatOptions) { + var _a = typeof positionOrRange === "number" ? [positionOrRange, undefined] : [positionOrRange.pos, positionOrRange.end], startPosition = _a[0], endPosition = _a[1]; + return { + file: file, + startPosition: startPosition, + endPosition: endPosition, + program: getProgram(), + newLineCharacter: host.getNewLine(), + rulesProvider: getRuleProvider(formatOptions), + cancellationToken: cancellationToken + }; + } + function getApplicableRefactors(fileName, positionOrRange) { + synchronizeHostData(); + var file = getValidSourceFile(fileName); + return ts.refactor.getApplicableRefactors(getRefactorContext(file, positionOrRange)); + } + function getEditsForRefactor(fileName, formatOptions, positionOrRange, refactorName, actionName) { + synchronizeHostData(); + var file = getValidSourceFile(fileName); + return ts.refactor.getEditsForRefactor(getRefactorContext(file, positionOrRange, formatOptions), refactorName, actionName); + } return { dispose: dispose, cleanupSemanticCache: cleanupSemanticCache, @@ -86836,7 +89890,9 @@ var ts; getEmitOutput: getEmitOutput, getNonBoundSourceFile: getNonBoundSourceFile, getSourceFile: getSourceFile, - getProgram: getProgram + getProgram: getProgram, + getApplicableRefactors: getApplicableRefactors, + getEditsForRefactor: getEditsForRefactor, }; } ts.createLanguageService = createLanguageService; @@ -86924,20 +89980,20 @@ var ts; var contextualType = typeChecker.getContextualType(objectLiteral); var name = ts.getTextOfPropertyName(node.name); if (name && contextualType) { - var result_8 = []; + var result_9 = []; var symbol = contextualType.getProperty(name); if (contextualType.flags & 65536 /* Union */) { ts.forEach(contextualType.types, function (t) { var symbol = t.getProperty(name); if (symbol) { - result_8.push(symbol); + result_9.push(symbol); } }); - return result_8; + return result_9; } if (symbol) { - result_8.push(symbol); - return result_8; + result_9.push(symbol); + return result_9; } } return undefined; @@ -86980,7 +90036,7 @@ var ts; if (sourceFile.isDeclarationFile) { return undefined; } - var tokenAtLocation = ts.getTokenAtPosition(sourceFile, position); + var tokenAtLocation = ts.getTokenAtPosition(sourceFile, position, /*includeJsDocComment*/ false); var lineOfPosition = sourceFile.getLineAndCharacterOfPosition(position).line; if (sourceFile.getLineAndCharacterOfPosition(tokenAtLocation.getStart(sourceFile)).line > lineOfPosition) { // Get previous token if the token is returned starts on new line @@ -88371,7 +91427,7 @@ var TypeScript; // 'toolsVersion' gets consumed by the managed side, so it's not unused. // TODO: it should be moved into a namespace though. /* @internal */ -var toolsVersion = "2.3"; +var toolsVersion = "2.4"; // MONACOCHANGE // Defining the entire module name because r.js has an issue and cannot bundle this file diff --git a/package.json b/package.json index 42002258..6fbf58d1 100644 --- a/package.json +++ b/package.json @@ -27,6 +27,6 @@ "monaco-editor-core": "^0.9.0", "object-assign": "^4.1.0", "rimraf": "^2.5.2", - "typescript": "2.3.4" + "typescript": "2.4.1" } } diff --git a/src/mode.ts b/src/mode.ts index d81107c1..45533480 100644 --- a/src/mode.ts +++ b/src/mode.ts @@ -33,7 +33,7 @@ export function setupJavaScript(defaults:LanguageServiceDefaultsImpl): void { ); } -export function getJavaScriptWorker(): Promise { +export function getJavaScriptWorker(): Promise<(first: Uri, ...more: Uri[]) => Promise> { return new monaco.Promise((resolve, reject) => { if (!javaScriptWorker) { return reject("JavaScript not registered!"); @@ -43,7 +43,7 @@ export function getJavaScriptWorker(): Promise { }); } -export function getTypeScriptWorker(): Promise { +export function getTypeScriptWorker(): Promise<(first: Uri, ...more: Uri[]) => Promise> { return new monaco.Promise((resolve, reject) => { if (!typeScriptWorker) { return reject("TypeScript not registered!");