mirror of
https://github.com/FlipsideCrypto/DefinitelyTyped.git
synced 2026-02-06 10:56:53 +00:00
Switch dependency on lib.scripthost.d.ts to activex-interop
This commit is contained in:
parent
aaddad9441
commit
38f44407b1
2
types/activex-access/index.d.ts
vendored
2
types/activex-access/index.d.ts
vendored
@ -4,6 +4,7 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.6
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
/// <reference types="activex-office" />
|
||||
/// <reference types="activex-dao" />
|
||||
/// <reference types="activex-vbide" />
|
||||
@ -8882,7 +8883,6 @@ interface ActiveXObject {
|
||||
Access.OptionButton | Access.OptionGroup | Access.Page | Access.SubForm | Access.TabControl | Access.TextBox | Access.ToggleButton | Access.WebBrowserControl,
|
||||
propertyName: 'accName' | 'accValue', parameterTypes: [any], newValue: string): void;
|
||||
set(obj: Access._ControlInReportEvents | Access.ComboBox | Access.Control | Access.ListBox, propertyName: 'Selected', parameterTypes: [number], newValue: number): void;
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,5 +1,8 @@
|
||||
// Note -- running these tests under cscript requires some ES5 polyfills
|
||||
|
||||
/// <reference types="windows-script-host" />
|
||||
/// <reference types="activex-scripting" />
|
||||
|
||||
const collectionToArray = <T>(col: { Item(key: any): T }): T[] => {
|
||||
const results: T[] = [];
|
||||
const enumerator = new Enumerator<T>(col);
|
||||
@ -12,9 +15,9 @@ const collectionToArray = <T>(col: { Item(key: any): T }): T[] => {
|
||||
};
|
||||
|
||||
const toSafeArray = <T>(...items: T[]): SafeArray<T> => {
|
||||
const dict = new ActiveXObject('Scripting.Dictionary');
|
||||
const dict: Scripting.Dictionary<number, T> = new ActiveXObject('Scripting.Dictionary');
|
||||
items.forEach((x, index) => dict.Add(index, x));
|
||||
return dict.Items() as SafeArray<T>;
|
||||
return dict.Items();
|
||||
};
|
||||
|
||||
const toConnectionString = (o: { [index: string]: any }) => {
|
||||
|
||||
3
types/activex-adodb/index.d.ts
vendored
3
types/activex-adodb/index.d.ts
vendored
@ -4,6 +4,8 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.6
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
|
||||
declare namespace ADODB {
|
||||
const enum ADCPROP_ASYNCTHREADPRIORITY_ENUM {
|
||||
adPriorityAboveNormal = 4,
|
||||
@ -1094,7 +1096,6 @@ declare namespace ADODB {
|
||||
}
|
||||
|
||||
interface ActiveXObject {
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
on(obj: ADODB.Connection, event: 'BeginTransComplete', argNames: ['TransactionLevel', 'pError', 'adStatus', 'pConnection'], handler: (this: ADODB.Connection, parameter: {readonly TransactionLevel: number, readonly pError: ADODB.Error, adStatus: ADODB.EventStatusEnum, readonly pConnection: ADODB.Connection}) => void): void;
|
||||
on(obj: ADODB.Connection, event: 'CommitTransComplete' | 'ConnectComplete' | 'InfoMessage' | 'RollbackTransComplete', argNames: ['pError', 'adStatus', 'pConnection'], handler: (this: ADODB.Connection, parameter: {readonly pError: ADODB.Error, adStatus: ADODB.EventStatusEnum, readonly pConnection: ADODB.Connection}) => void): void;
|
||||
on(obj: ADODB.Connection, event: 'Disconnect', argNames: ['adStatus', 'pConnection'], handler: (this: ADODB.Connection, parameter: {adStatus: ADODB.EventStatusEnum, readonly pConnection: ADODB.Connection}) => void): void;
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,3 +1,5 @@
|
||||
/// <reference types="windows-script-host" />
|
||||
|
||||
const collectionToArray = <T>(col: { Item(key: any): T }): T[] => {
|
||||
const results: T[] = [];
|
||||
const enumerator = new Enumerator<T>(col);
|
||||
|
||||
5
types/activex-adox/index.d.ts
vendored
5
types/activex-adox/index.d.ts
vendored
@ -4,6 +4,7 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.6
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
/// <reference types="activex-adodb" />
|
||||
|
||||
declare namespace ADOX {
|
||||
@ -320,10 +321,6 @@ declare namespace ADOX {
|
||||
}
|
||||
}
|
||||
|
||||
interface ActiveXObject {
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
'ADOX.Catalog': ADOX.Catalog;
|
||||
'ADOX.Column': ADOX.Column;
|
||||
|
||||
@ -1,8 +1,9 @@
|
||||
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": ["es5", "scripthost"],
|
||||
"lib": [
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
|
||||
@ -1,3 +1,5 @@
|
||||
/// <reference types="windows-script-host" />
|
||||
|
||||
const collectionToArray = <T>(col: { Item(key: any): T }): T[] => {
|
||||
const results: T[] = [];
|
||||
const enumerator = new Enumerator<T>(col);
|
||||
|
||||
6
types/activex-dao/index.d.ts
vendored
6
types/activex-dao/index.d.ts
vendored
@ -4,6 +4,8 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.6
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
|
||||
declare namespace DAO {
|
||||
const enum _DAOSuppHelp {
|
||||
KeepLocal = 0,
|
||||
@ -883,10 +885,6 @@ declare namespace DAO {
|
||||
}
|
||||
}
|
||||
|
||||
interface ActiveXObject {
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
'DAO.DBEngine': DAO.DBEngine;
|
||||
'DAO.Field': DAO.Field;
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
7
types/activex-diskquota/index.d.ts
vendored
7
types/activex-diskquota/index.d.ts
vendored
@ -4,6 +4,8 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.5
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
|
||||
declare namespace DiskQuotaTypeLibrary {
|
||||
// tslint:disable-next-line no-const-enum
|
||||
const enum AccountStatusConstants {
|
||||
@ -136,7 +138,6 @@ interface ActiveXObject {
|
||||
on(
|
||||
obj: DiskQuotaTypeLibrary.DiskQuotaControl, event: 'OnUserNameChanged', argNames: ['pUser'], handler: (
|
||||
this: DiskQuotaTypeLibrary.DiskQuotaControl, parameter: {readonly pUser: DiskQuotaTypeLibrary.DIDiskQuotaUser}) => void): void;
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
@ -146,7 +147,3 @@ interface ActiveXObjectNameMap {
|
||||
interface EnumeratorConstructor {
|
||||
new(col: DiskQuotaTypeLibrary.DiskQuotaControl): Enumerator<DiskQuotaTypeLibrary.DIDiskQuotaUser>;
|
||||
}
|
||||
|
||||
interface SafeArray<T = any> {
|
||||
_brand: SafeArray<T>;
|
||||
}
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,11 +1,12 @@
|
||||
/// <reference types="windows-script-host" />
|
||||
/// <reference types="activex-msforms" />
|
||||
/// <reference types="activex-scripting" />
|
||||
|
||||
// some helpers
|
||||
const toSafeArray = <T>(...items: T[]): SafeArray<T> => {
|
||||
const dict = new ActiveXObject('Scripting.Dictionary');
|
||||
const dict: Scripting.Dictionary<number, T> = new ActiveXObject('Scripting.Dictionary');
|
||||
items.forEach((x, index) => dict.Add(index, x));
|
||||
return dict.Items() as SafeArray<T>;
|
||||
return dict.Items();
|
||||
};
|
||||
const inCollection = <T = any>(collection: { Item(index: any): T }, index: string | number): T | undefined => {
|
||||
let item: T | undefined;
|
||||
|
||||
1
types/activex-excel/index.d.ts
vendored
1
types/activex-excel/index.d.ts
vendored
@ -9723,7 +9723,6 @@ interface ActiveXObject {
|
||||
set(obj: Excel.Workbook, propertyName: 'Colors', parameterTypes: [any], newValue: any): void;
|
||||
set(obj: Excel.Range, propertyName: 'Value', parameterTypes: [Excel.XlRangeValueDataType], newValue: any): void;
|
||||
set(obj: Excel.Range, propertyName: 'Value', newValue: any): void; // because Value is defined on the type as a method, not a property
|
||||
new <K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,4 +1,5 @@
|
||||
/// <reference types="activex-iwshruntimelibrary" />
|
||||
/// <reference types="windows-script-host" />
|
||||
/// <reference types="activex-scripting" />
|
||||
|
||||
const collectionToArray = <T>(col: { Item(index: any): T } | SafeArray<T>) => {
|
||||
const results: T[] = [];
|
||||
@ -12,9 +13,9 @@ const collectionToArray = <T>(col: { Item(index: any): T } | SafeArray<T>) => {
|
||||
};
|
||||
|
||||
const toSafeArray = <T>(...items: T[]): SafeArray<T> => {
|
||||
const dict = new ActiveXObject('Scripting.Dictionary');
|
||||
const dict: Scripting.Dictionary<number, T> = new ActiveXObject('Scripting.Dictionary');
|
||||
items.forEach((x, index) => dict.Add(index, x));
|
||||
return dict.Items() as SafeArray<T>;
|
||||
return dict.Items();
|
||||
};
|
||||
|
||||
const VB = {
|
||||
|
||||
1
types/activex-faxcomexlib/index.d.ts
vendored
1
types/activex-faxcomexlib/index.d.ts
vendored
@ -2011,7 +2011,6 @@ interface ActiveXObject {
|
||||
this: FAXCOMEXLib.FaxServer, parameter: {readonly riid: stdole.GUID, ppvObj: undefined}) => void): void;
|
||||
on(obj: FAXCOMEXLib.FaxAccount, event: 'AddRef' | 'Release', handler: (this: FAXCOMEXLib.FaxAccount, parameter: {}) => void): void;
|
||||
on(obj: FAXCOMEXLib.FaxServer, event: 'AddRef' | 'Release', handler: (this: FAXCOMEXLib.FaxServer, parameter: {}) => void): void;
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
1
types/activex-infopath/index.d.ts
vendored
1
types/activex-infopath/index.d.ts
vendored
@ -1168,7 +1168,6 @@ interface ActiveXObject {
|
||||
on(obj: InfoPath.Button, event: 'AddRef' | 'Release', handler: (this: InfoPath.Button, parameter: {}) => void): void;
|
||||
on(obj: InfoPath.DataDOM, event: 'AddRef' | 'Release', handler: (this: InfoPath.DataDOM, parameter: {}) => void): void;
|
||||
on(obj: InfoPath.XDocument, event: 'AddRef' | 'Release', handler: (this: InfoPath.XDocument, parameter: {}) => void): void;
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,3 +1,5 @@
|
||||
/// <reference types="windows-script-host" />
|
||||
|
||||
(() => {
|
||||
// https://wiki.openoffice.org/wiki/Documentation/DevGuide/ProUNO/Bridge/Automation_Bridge
|
||||
|
||||
|
||||
5
types/activex-libreoffice/index.d.ts
vendored
5
types/activex-libreoffice/index.d.ts
vendored
@ -4,6 +4,8 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.3
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
|
||||
declare class type {
|
||||
private typekey: type;
|
||||
}
|
||||
@ -12,9 +14,6 @@ declare class sequence<T = any> {
|
||||
private typekey: sequence<T>;
|
||||
}
|
||||
|
||||
// tslint:disable-next-line no-empty-interface
|
||||
interface SafeArray<T = any> {}
|
||||
|
||||
declare namespace com.sun.star {
|
||||
namespace accessibility {
|
||||
/**
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
1
types/activex-msforms/index.d.ts
vendored
1
types/activex-msforms/index.d.ts
vendored
@ -1564,7 +1564,6 @@ interface ActiveXObject {
|
||||
set(obj: MSForms.ComboBox | MSForms.ListBox, propertyName: 'Column' | 'List', parameterTypes: [number, number] | [number], newValue: any): void;
|
||||
set(obj: MSForms.ComboBox | MSForms.ListBox, propertyName: 'Column' | 'List', parameterTypes: number[], newValue: SafeArray): void;
|
||||
set(obj: MSForms.ListBox, propertyName: 'Selected', parameterTypes: [any], newValue: boolean): void;
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,3 +1,5 @@
|
||||
/// <reference types="windows-script-host" />
|
||||
|
||||
let htmlfile = new ActiveXObject('htmlfile');
|
||||
let htmldoc = htmlfile.createDocumentFromUrl('https://msdn.microsoft.com/en-us/library/aa741317(v=vs.85).aspx', 'null');
|
||||
let length = htmldoc.all.length;
|
||||
|
||||
1
types/activex-mshtml/index.d.ts
vendored
1
types/activex-mshtml/index.d.ts
vendored
@ -35570,7 +35570,6 @@ interface ActiveXObject {
|
||||
on(obj: MSHTML.SVGTSpanElement, event: 'onactivate' | 'onafterupdate' | 'onbeforeactivate' | 'onbeforecopy' | 'onbeforecut' | 'onbeforedeactivate' | 'onbeforeeditfocus' | 'onbeforepaste' | 'onbeforeupdate' | 'onblur' | 'oncellchange' | 'onclick' | 'oncontextmenu' | 'oncontrolselect' | 'oncopy' | 'oncut' | 'ondataavailable' | 'ondatasetchanged' | 'ondatasetcomplete' | 'ondblclick' | 'ondeactivate' | 'ondrag' | 'ondragend' | 'ondragenter' | 'ondragleave' | 'ondragover' | 'ondragstart' | 'ondrop' | 'onerrorupdate' | 'onfilterchange' | 'onfocus' | 'onfocusin' | 'onfocusout' | 'onhelp' | 'onkeydown' | 'onkeypress' | 'onkeyup' | 'onlayoutcomplete' | 'onlosecapture' | 'onmousedown' | 'onmouseenter' | 'onmouseleave' | 'onmousemove' | 'onmouseout' | 'onmouseover' | 'onmouseup' | 'onmousewheel' | 'onmove' | 'onmoveend' | 'onmovestart' | 'onpage' | 'onpaste' | 'onpropertychange' | 'onreadystatechange' | 'onresize' | 'onresizeend' | 'onresizestart' | 'onrowenter' | 'onrowexit' | 'onrowsdelete' | 'onrowsinserted' | 'onscroll' | 'onselectstart', handler: (this: MSHTML.SVGTSpanElement, parameter: {}) => void): void;
|
||||
on(obj: MSHTML.SVGUseElement, event: 'onactivate' | 'onafterupdate' | 'onbeforeactivate' | 'onbeforecopy' | 'onbeforecut' | 'onbeforedeactivate' | 'onbeforeeditfocus' | 'onbeforepaste' | 'onbeforeupdate' | 'onblur' | 'oncellchange' | 'onclick' | 'oncontextmenu' | 'oncontrolselect' | 'oncopy' | 'oncut' | 'ondataavailable' | 'ondatasetchanged' | 'ondatasetcomplete' | 'ondblclick' | 'ondeactivate' | 'ondrag' | 'ondragend' | 'ondragenter' | 'ondragleave' | 'ondragover' | 'ondragstart' | 'ondrop' | 'onerrorupdate' | 'onfilterchange' | 'onfocus' | 'onfocusin' | 'onfocusout' | 'onhelp' | 'onkeydown' | 'onkeypress' | 'onkeyup' | 'onlayoutcomplete' | 'onlosecapture' | 'onmousedown' | 'onmouseenter' | 'onmouseleave' | 'onmousemove' | 'onmouseout' | 'onmouseover' | 'onmouseup' | 'onmousewheel' | 'onmove' | 'onmoveend' | 'onmovestart' | 'onpage' | 'onpaste' | 'onpropertychange' | 'onreadystatechange' | 'onresize' | 'onresizeend' | 'onresizestart' | 'onrowenter' | 'onrowexit' | 'onrowsdelete' | 'onrowsinserted' | 'onscroll' | 'onselectstart', handler: (this: MSHTML.SVGUseElement, parameter: {}) => void): void;
|
||||
on(obj: MSHTML.SVGViewElement, event: 'onactivate' | 'onafterupdate' | 'onbeforeactivate' | 'onbeforecopy' | 'onbeforecut' | 'onbeforedeactivate' | 'onbeforeeditfocus' | 'onbeforepaste' | 'onbeforeupdate' | 'onblur' | 'oncellchange' | 'onclick' | 'oncontextmenu' | 'oncontrolselect' | 'oncopy' | 'oncut' | 'ondataavailable' | 'ondatasetchanged' | 'ondatasetcomplete' | 'ondblclick' | 'ondeactivate' | 'ondrag' | 'ondragend' | 'ondragenter' | 'ondragleave' | 'ondragover' | 'ondragstart' | 'ondrop' | 'onerrorupdate' | 'onfilterchange' | 'onfocus' | 'onfocusin' | 'onfocusout' | 'onhelp' | 'onkeydown' | 'onkeypress' | 'onkeyup' | 'onlayoutcomplete' | 'onlosecapture' | 'onmousedown' | 'onmouseenter' | 'onmouseleave' | 'onmousemove' | 'onmouseout' | 'onmouseover' | 'onmouseup' | 'onmousewheel' | 'onmove' | 'onmoveend' | 'onmovestart' | 'onpage' | 'onpaste' | 'onpropertychange' | 'onreadystatechange' | 'onresize' | 'onresizeend' | 'onresizestart' | 'onrowenter' | 'onrowexit' | 'onrowsdelete' | 'onrowsinserted' | 'onscroll' | 'onselectstart', handler: (this: MSHTML.SVGViewElement, parameter: {}) => void): void;
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,3 +1,5 @@
|
||||
/// <reference types="windows-script-host" />
|
||||
|
||||
// https://msdn.microsoft.com/en-us/library/ms764708(v=vs.85).aspx
|
||||
{
|
||||
const dom = new ActiveXObject('Msxml2.DOMDocument.6.0');
|
||||
|
||||
3
types/activex-msxml2/index.d.ts
vendored
3
types/activex-msxml2/index.d.ts
vendored
@ -4,6 +4,8 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.3
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
|
||||
declare namespace MSXML2 {
|
||||
/** Schema Object Model Content Types */
|
||||
const enum _SCHEMACONTENTTYPE {
|
||||
@ -2775,7 +2777,6 @@ declare namespace MSXML2 {
|
||||
interface ActiveXObject {
|
||||
on(obj: MSXML2.DOMDocument60, event: 'ondataavailable' | 'onreadystatechange', handler: (this: MSXML2.DOMDocument60, parameter: {}) => void): void;
|
||||
on(obj: MSXML2.FreeThreadedDOMDocument60, event: 'ondataavailable' | 'onreadystatechange', handler: (this: MSXML2.FreeThreadedDOMDocument60, parameter: {}) => void): void;
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
/// <reference types="windows-script-host" />
|
||||
/// <reference types="activex-word" />
|
||||
|
||||
const collectionToArray = <T>(col: { Item(key: any): T }): T[] => {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
2
types/activex-outlook/index.d.ts
vendored
2
types/activex-outlook/index.d.ts
vendored
@ -4,6 +4,7 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.6
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
/// <reference types="activex-stdole" />
|
||||
/// <reference types="activex-office" />
|
||||
|
||||
@ -5855,7 +5856,6 @@ interface ActiveXObject {
|
||||
on(obj: Outlook.TaskRequestDeclineItem, event: 'AfterWrite' | 'BeforeRead' | 'Read' | 'Unload', handler: (this: Outlook.TaskRequestDeclineItem, parameter: {}) => void): void;
|
||||
on(obj: Outlook.TaskRequestItem, event: 'AfterWrite' | 'BeforeRead' | 'Read' | 'Unload', handler: (this: Outlook.TaskRequestItem, parameter: {}) => void): void;
|
||||
on(obj: Outlook.TaskRequestUpdateItem, event: 'AfterWrite' | 'BeforeRead' | 'Read' | 'Unload', handler: (this: Outlook.TaskRequestUpdateItem, parameter: {}) => void): void;
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
// tslint:disable-next-line no-unnecessary-generics
|
||||
const collectionToArray = <T>(col: any): T[] => {
|
||||
const collectionToArray = <T>(col: {Item(index: any): T}): T[] => {
|
||||
const results: T[] = [];
|
||||
const enumerator = new Enumerator<T>(col);
|
||||
enumerator.moveFirst();
|
||||
@ -13,8 +13,8 @@ const collectionToArray = <T>(col: any): T[] => {
|
||||
const app = new ActiveXObject('PowerPoint.Application');
|
||||
(() => {
|
||||
// delete empty textboxes in PowerPoint
|
||||
collectionToArray<PowerPoint.Slide>(app.ActivePresentation.Slides).forEach(slide => {
|
||||
collectionToArray<PowerPoint.Shape>(slide.Shapes).filter(shape =>
|
||||
collectionToArray(app.ActivePresentation.Slides).forEach(slide => {
|
||||
collectionToArray(slide.Shapes).filter(shape =>
|
||||
shape.Type === Office.MsoShapeType.msoTextBox
|
||||
&& shape.TextFrame.TextRange.Text.trim() === ''
|
||||
).forEach(shape => shape.Delete());
|
||||
|
||||
1
types/activex-powerpoint/index.d.ts
vendored
1
types/activex-powerpoint/index.d.ts
vendored
@ -5374,7 +5374,6 @@ interface ActiveXObject {
|
||||
this: PowerPoint.Application, parameter: {readonly Sel: PowerPoint.Selection, Cancel: boolean}) => void): void;
|
||||
on(obj: PowerPoint.Application, event: 'WindowSelectionChange', argNames: ['Sel'], handler: (this: PowerPoint.Application, parameter: {readonly Sel: PowerPoint.Selection}) => void): void;
|
||||
on(obj: PowerPoint.OLEControl, event: 'GotFocus' | 'LostFocus', handler: (this: PowerPoint.OLEControl, parameter: {}) => void): void;
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,3 +1,5 @@
|
||||
/// <reference types="windows-script-host" />
|
||||
|
||||
// Note -- running these tests under cscript requires some ES5 polyfills
|
||||
|
||||
const collectionToArray = <T>(col: { Item(key: any): T }): T[] => {
|
||||
|
||||
3
types/activex-scripting/index.d.ts
vendored
3
types/activex-scripting/index.d.ts
vendored
@ -4,6 +4,8 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.6
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
|
||||
declare namespace Scripting {
|
||||
// tslint:disable-next-line:no-const-enum
|
||||
const enum CompareMethod {
|
||||
@ -489,7 +491,6 @@ declare namespace Scripting {
|
||||
}
|
||||
|
||||
interface ActiveXObject {
|
||||
new <K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
set(obj: Scripting.Dictionary, propertyName: 'Item', parameterTypes: [any], newValue: any): void;
|
||||
}
|
||||
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
7
types/activex-shdocvw/index.d.ts
vendored
7
types/activex-shdocvw/index.d.ts
vendored
@ -4,6 +4,8 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.6
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
|
||||
declare namespace SHDocVw {
|
||||
// tslint:disable-next-line no-const-enum
|
||||
const enum BrowserBarConstants {
|
||||
@ -1562,7 +1564,6 @@ interface ActiveXObject {
|
||||
on(obj: SHDocVw.ShellNameSpace, event: 'DoubleClick' | 'Initialized' | 'SelectionChange', handler: (this: SHDocVw.ShellNameSpace, parameter: {}) => void): void;
|
||||
on(obj: SHDocVw.WebBrowser, event: 'DownloadBegin' | 'DownloadComplete' | 'OnQuit', handler: (this: SHDocVw.WebBrowser, parameter: {}) => void): void;
|
||||
on(obj: SHDocVw.WebBrowser_V1, event: 'DownloadBegin' | 'DownloadComplete' | 'WindowActivate' | 'WindowMove' | 'WindowResize', handler: (this: SHDocVw.WebBrowser_V1, parameter: {}) => void): void;
|
||||
new <K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
@ -1571,7 +1572,3 @@ interface ActiveXObjectNameMap {
|
||||
'Shell.UIHelper': SHDocVw.ShellUIHelper;
|
||||
'ShellNameSpace.ShellNameSpace': SHDocVw.ShellNameSpace;
|
||||
}
|
||||
|
||||
interface EnumeratorConstructor {
|
||||
new(col: SHDocVw.ShellWindows): Enumerator<SHDocVw.InternetExplorer>;
|
||||
}
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
/// <reference types="activex-iwshruntimelibrary" />
|
||||
/// <reference types="windows-script-host" />
|
||||
|
||||
const shell = new ActiveXObject('Shell.Application');
|
||||
|
||||
|
||||
1
types/activex-shell/index.d.ts
vendored
1
types/activex-shell/index.d.ts
vendored
@ -1001,7 +1001,6 @@ interface ActiveXObject {
|
||||
on(
|
||||
obj: Shell32.ShellFolderViewOC, event: 'BeginDrag' | 'DefaultVerbInvoked' | 'EnumDone' | 'SelectionChanged' | 'VerbInvoked',
|
||||
handler: (this: Shell32.ShellFolderViewOC, parameter: {}) => void): void;
|
||||
new <K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
3
types/activex-stdole/index.d.ts
vendored
3
types/activex-stdole/index.d.ts
vendored
@ -4,6 +4,8 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.6
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
|
||||
declare namespace stdole {
|
||||
type IPictureDisp = StdPicture;
|
||||
|
||||
@ -79,7 +81,6 @@ declare namespace stdole {
|
||||
|
||||
interface ActiveXObject {
|
||||
on(obj: stdole.StdFont, event: 'FontChanged', argNames: ['PropertyName'], handler: (this: stdole.StdFont, parameter: {readonly PropertyName: string}) => void): void;
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
/// <reference types="windows-script-host" />
|
||||
/// <reference types="activex-word" />
|
||||
|
||||
const collectionToArray = <T>(col: { Item(key: any): T }): T[] => {
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,3 +1,5 @@
|
||||
/// <reference types="windows-script-host" />
|
||||
|
||||
// Note -- running these tests under cscript requires some ES5 polyfills
|
||||
|
||||
const collectionToArray = <T>(col: { Item(key: any): T }): T[] => {
|
||||
|
||||
3
types/activex-wia/index.d.ts
vendored
3
types/activex-wia/index.d.ts
vendored
@ -4,6 +4,8 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.6
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
|
||||
declare namespace WIA {
|
||||
/** String versions of globally unique identifiers (GUIDs) that identify common Device and Item commands. */
|
||||
const enum CommandID {
|
||||
@ -791,7 +793,6 @@ declare namespace WIA {
|
||||
}
|
||||
|
||||
interface ActiveXObject {
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
on(obj: WIA.DeviceManager, event: 'OnEvent', argNames: ['EventID', 'DeviceID', 'ItemID'], handler: (
|
||||
this: WIA.DeviceManager, parameter: { readonly EventID: string, readonly DeviceID: string, readonly ItemID: string }) => void): void;
|
||||
set<TItem>(obj: WIA.Vector<TItem>, propertyName: 'Item', parameterTypes: [number], newValue: TItem): void;
|
||||
|
||||
@ -2,8 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
"es5"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
|
||||
@ -1,5 +1,7 @@
|
||||
/// <reference types="windows-script-host" />
|
||||
|
||||
// tslint:disable-next-line no-unnecessary-generics
|
||||
const collectionToArray = <T>(col: any): T[] => {
|
||||
const collectionToArray = <T>(col: {Item(index: any): T}): T[] => {
|
||||
const results: T[] = [];
|
||||
const enumerator = new Enumerator<T>(col);
|
||||
enumerator.moveFirst();
|
||||
@ -233,7 +235,7 @@ const activeDoc = app.ActiveDocument;
|
||||
|
||||
// looping through a collection -- https://msdn.microsoft.com/en-us/vba/word-vba/articles/looping-through-a-collection
|
||||
(() => {
|
||||
collectionToArray<Word.Document>(app.Documents)
|
||||
collectionToArray(app.Documents)
|
||||
.forEach(openDocument => WScript.Echo(openDocument.Name));
|
||||
|
||||
const strMarks = collectionToArray<Word.Bookmark>(activeDoc.Bookmarks)
|
||||
|
||||
2
types/activex-word/index.d.ts
vendored
2
types/activex-word/index.d.ts
vendored
@ -4,6 +4,7 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.6
|
||||
|
||||
/// <reference types="activex-interop" />
|
||||
/// <reference types="activex-office" />
|
||||
/// <reference types="activex-vbide" />
|
||||
/// <reference types="activex-stdole" />
|
||||
@ -12496,7 +12497,6 @@ interface ActiveXObject {
|
||||
set(obj: Word.Document, propertyName: 'ActiveWritingStyle', parameterTypes: [any], newValue: string): void;
|
||||
set(obj: Word.Document, propertyName: 'Compatibility', parameterTypes: [Word.WdCompatibility], newValue: boolean): void;
|
||||
set(obj: Word.System, propertyName: 'PrivateProfileString', parameterTypes: [string, string, string], newValue: string): void;
|
||||
new<K extends keyof ActiveXObjectNameMap = any>(progid: K): ActiveXObjectNameMap[K];
|
||||
}
|
||||
|
||||
interface ActiveXObjectNameMap {
|
||||
|
||||
@ -1,10 +1,7 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es5",
|
||||
"scripthost"
|
||||
],
|
||||
"lib": ["es5"],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user