mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-11-29 17:51:46 +00:00
WIP
WIP WIP WIP WIP WIP WIP: Remove trailing newlines WIP WIP WIP WIP WIP WIP WIP WIP: All tests pass WIP WIP WIP
This commit is contained in:
Vendored
+30
-30
@@ -1436,7 +1436,7 @@ declare namespace angular {
|
||||
(data: any, headersGetter: IHttpHeadersGetter, status: number): any;
|
||||
}
|
||||
|
||||
type HttpHeaderType = {[requestType: string]:string|((config:IRequestConfig) => string)};
|
||||
type HttpHeaderType = {[requestType: string]: string|((config: IRequestConfig) => string)};
|
||||
|
||||
interface IHttpRequestConfigHeaders {
|
||||
[requestType: string]: any;
|
||||
@@ -1529,7 +1529,7 @@ declare namespace angular {
|
||||
* @returns {boolean|Object} If a value is specified, returns the $httpProvider for chaining.
|
||||
* otherwise, returns the current configured value.
|
||||
*/
|
||||
useLegacyPromiseExtensions(value:boolean) : boolean | IHttpProvider;
|
||||
useLegacyPromiseExtensions(value: boolean): boolean | IHttpProvider;
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
@@ -1852,7 +1852,7 @@ declare namespace angular {
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
// AUTO module (angular.js)
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
export module auto {
|
||||
export namespace auto {
|
||||
|
||||
///////////////////////////////////////////////////////////////////////
|
||||
// InjectorService
|
||||
@@ -1862,33 +1862,33 @@ declare namespace angular {
|
||||
annotate(fn: Function, strictDi?: boolean): string[];
|
||||
annotate(inlineAnnotatedFunction: any[]): string[];
|
||||
get<T>(name: string, caller?: string): T;
|
||||
get(name: '$anchorScroll'): IAnchorScrollService
|
||||
get(name: '$cacheFactory'): ICacheFactoryService
|
||||
get(name: '$compile'): ICompileService
|
||||
get(name: '$controller'): IControllerService
|
||||
get(name: '$document'): IDocumentService
|
||||
get(name: '$exceptionHandler'): IExceptionHandlerService
|
||||
get(name: '$filter'): IFilterService
|
||||
get(name: '$http'): IHttpService
|
||||
get(name: '$httpBackend'): IHttpBackendService
|
||||
get(name: '$httpParamSerializer'): IHttpParamSerializer
|
||||
get(name: '$httpParamSerializerJQLike'): IHttpParamSerializer
|
||||
get(name: '$interpolate'): IInterpolateService
|
||||
get(name: '$interval'): IIntervalService
|
||||
get(name: '$locale'): ILocaleService
|
||||
get(name: '$location'): ILocationService
|
||||
get(name: '$log'): ILogService
|
||||
get(name: '$parse'): IParseService
|
||||
get(name: '$q'): IQService
|
||||
get(name: '$rootElement'): IRootElementService
|
||||
get(name: '$rootScope'): IRootScopeService
|
||||
get(name: '$sce'): ISCEService
|
||||
get(name: '$sceDelegate'): ISCEDelegateService
|
||||
get(name: '$templateCache'): ITemplateCacheService
|
||||
get(name: '$templateRequest'): ITemplateRequestService
|
||||
get(name: '$timeout'): ITimeoutService
|
||||
get(name: '$window'): IWindowService
|
||||
get<T>(name: '$xhrFactory'): IXhrFactory<T>
|
||||
get(name: '$anchorScroll'): IAnchorScrollService;
|
||||
get(name: '$cacheFactory'): ICacheFactoryService;
|
||||
get(name: '$compile'): ICompileService;
|
||||
get(name: '$controller'): IControllerService;
|
||||
get(name: '$document'): IDocumentService;
|
||||
get(name: '$exceptionHandler'): IExceptionHandlerService;
|
||||
get(name: '$filter'): IFilterService;
|
||||
get(name: '$http'): IHttpService;
|
||||
get(name: '$httpBackend'): IHttpBackendService;
|
||||
get(name: '$httpParamSerializer'): IHttpParamSerializer;
|
||||
get(name: '$httpParamSerializerJQLike'): IHttpParamSerializer;
|
||||
get(name: '$interpolate'): IInterpolateService;
|
||||
get(name: '$interval'): IIntervalService;
|
||||
get(name: '$locale'): ILocaleService;
|
||||
get(name: '$location'): ILocationService;
|
||||
get(name: '$log'): ILogService;
|
||||
get(name: '$parse'): IParseService;
|
||||
get(name: '$q'): IQService;
|
||||
get(name: '$rootElement'): IRootElementService;
|
||||
get(name: '$rootScope'): IRootScopeService;
|
||||
get(name: '$sce'): ISCEService;
|
||||
get(name: '$sceDelegate'): ISCEDelegateService;
|
||||
get(name: '$templateCache'): ITemplateCacheService;
|
||||
get(name: '$templateRequest'): ITemplateRequestService;
|
||||
get(name: '$timeout'): ITimeoutService;
|
||||
get(name: '$window'): IWindowService;
|
||||
get<T>(name: '$xhrFactory'): IXhrFactory<T>;
|
||||
has(name: string): boolean;
|
||||
instantiate<T>(typeConstructor: Function, locals?: any): T;
|
||||
invoke(inlineAnnotatedFunction: any[]): any;
|
||||
|
||||
Vendored
+6
-6
@@ -10,7 +10,7 @@ declare var angular: ng.IAngularStatic;
|
||||
|
||||
// Support for painless dependency injection
|
||||
interface Function {
|
||||
$inject:string[];
|
||||
$inject: string[];
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
@@ -93,8 +93,8 @@ declare namespace ng {
|
||||
constant(object: Object): IModule;
|
||||
controller(name: string, controllerConstructor: Function): IModule;
|
||||
controller(name: string, inlineAnnotadedConstructor: any[]): IModule;
|
||||
controller(object : Object): IModule;
|
||||
directive(name: string, directiveFactory: (...params:any[])=> IDirective): IModule;
|
||||
controller(object: Object): IModule;
|
||||
directive(name: string, directiveFactory: (...params: any[]) => IDirective): IModule;
|
||||
directive(name: string, inlineAnnotadedFunction: any[]): IModule;
|
||||
directive(object: Object): IModule;
|
||||
factory(name: string, serviceFactoryFunction: Function): IModule;
|
||||
@@ -125,7 +125,7 @@ declare namespace ng {
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
interface IAttributes {
|
||||
$set(name: string, value: any): void;
|
||||
$observe(name: string, fn:(value?:any)=>any):void;
|
||||
$observe(name: string, fn: (value?: any) => any): void;
|
||||
$attr: any;
|
||||
}
|
||||
|
||||
@@ -669,7 +669,7 @@ declare namespace ng {
|
||||
// and http://docs.angularjs.org/guide/directive
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
|
||||
interface IDirective{
|
||||
interface IDirective {
|
||||
priority?: number;
|
||||
template?: any;
|
||||
templateUrl?: any;
|
||||
@@ -722,7 +722,7 @@ declare namespace ng {
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
// AUTO module (angular.js)
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
export module auto {
|
||||
export namespace auto {
|
||||
|
||||
///////////////////////////////////////////////////////////////////////
|
||||
// InjectorService
|
||||
|
||||
Vendored
+6
-6
@@ -164,7 +164,7 @@ declare namespace ng {
|
||||
* @param controllerConstructor Controller constructor fn (optionally decorated with DI annotations in the array notation).
|
||||
*/
|
||||
controller(name: string, inlineAnnotatedConstructor: any[]): IModule;
|
||||
controller(object : Object): IModule;
|
||||
controller(object: Object): IModule;
|
||||
directive(name: string, directiveFactory: IDirectiveFactory): IModule;
|
||||
directive(name: string, inlineAnnotatedFunction: any[]): IModule;
|
||||
directive(object: Object): IModule;
|
||||
@@ -245,7 +245,7 @@ declare namespace ng {
|
||||
// The observer function will be invoked once during the next $digest
|
||||
// following compilation. The observer is then invoked whenever the
|
||||
// interpolated value changes.
|
||||
$observe(name: string, fn:(value?:any)=>any): Function;
|
||||
$observe(name: string, fn: (value?: any) => any): Function;
|
||||
|
||||
// A map of DOM element attribute names to the normalized name. This is needed
|
||||
// to do reverse lookup from normalized name back to actual name.
|
||||
@@ -347,7 +347,7 @@ declare namespace ng {
|
||||
$watchCollection(watchExpression: (scope: IScope) => any, listener: (newValue: any, oldValue: any, scope: IScope) => any): Function;
|
||||
|
||||
$watchGroup(watchExpressions: any[], listener: (newValue: any, oldValue: any, scope: IScope) => any): Function;
|
||||
$watchGroup(watchExpressions: {(scope: IScope) : any}[], listener: (newValue: any, oldValue: any, scope: IScope) => any): Function;
|
||||
$watchGroup(watchExpressions: {(scope: IScope): any}[], listener: (newValue: any, oldValue: any, scope: IScope) => any): Function;
|
||||
|
||||
$parent: IScope;
|
||||
|
||||
@@ -647,13 +647,13 @@ declare namespace ng {
|
||||
catch<TResult>(onRejected: (reason: any) => IPromise<TResult>): IPromise<TResult>;
|
||||
catch<TResult>(onRejected: (reason: any) => TResult): IPromise<TResult>;
|
||||
|
||||
finally<TResult>(finallyCallback: ()=>any):IPromise<TResult>;
|
||||
finally<TResult>(finallyCallback: () => any): IPromise<TResult>;
|
||||
}
|
||||
|
||||
interface IDeferred<T> {
|
||||
resolve(value?: T): void;
|
||||
reject(reason?: any): void;
|
||||
notify(state?:any): void;
|
||||
notify(state?: any): void;
|
||||
promise: IPromise<T>;
|
||||
}
|
||||
|
||||
@@ -1127,7 +1127,7 @@ declare namespace ng {
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
// AUTO module (angular.js)
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
export module auto {
|
||||
export namespace auto {
|
||||
|
||||
///////////////////////////////////////////////////////////////////////
|
||||
// InjectorService
|
||||
|
||||
Vendored
+6
-6
@@ -293,8 +293,8 @@ declare namespace angular {
|
||||
* @param name The name of the service to decorate
|
||||
* @param decorator This function will be invoked when the service needs to be instantiated and should return the decorated service instance. The function is called using the injector.invoke method and is therefore fully injectable. Local injection arguments: $delegate - The original service instance, which can be monkey patched, configured, decorated or delegated to.
|
||||
*/
|
||||
decorator(name:string, decoratorConstructor: Function): IModule;
|
||||
decorator(name:string, inlineAnnotatedConstructor: any[]): IModule;
|
||||
decorator(name: string, decoratorConstructor: Function): IModule;
|
||||
decorator(name: string, inlineAnnotatedConstructor: any[]): IModule;
|
||||
|
||||
// Properties
|
||||
name: string;
|
||||
@@ -1504,7 +1504,7 @@ declare namespace angular {
|
||||
* @returns {boolean|Object} If a value is specified, returns the $httpProvider for chaining.
|
||||
* otherwise, returns the current configured value.
|
||||
*/
|
||||
useLegacyPromiseExtensions(value:boolean) : boolean | IHttpProvider;
|
||||
useLegacyPromiseExtensions(value: boolean): boolean | IHttpProvider;
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
@@ -1715,7 +1715,7 @@ declare namespace angular {
|
||||
* Whether transclusion is enabled. Enabled by default.
|
||||
*/
|
||||
transclude?: boolean;
|
||||
require? : Object;
|
||||
require?: Object;
|
||||
$canActivate?: () => boolean;
|
||||
$routeConfig?: RouteDefinition[];
|
||||
}
|
||||
@@ -1766,7 +1766,7 @@ declare namespace angular {
|
||||
name?: string;
|
||||
priority?: number;
|
||||
replace?: boolean;
|
||||
require? : any;
|
||||
require?: any;
|
||||
restrict?: string;
|
||||
scope?: any;
|
||||
template?: string | Function;
|
||||
@@ -1814,7 +1814,7 @@ declare namespace angular {
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
// AUTO module (angular.js)
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
export module auto {
|
||||
export namespace auto {
|
||||
|
||||
///////////////////////////////////////////////////////////////////////
|
||||
// InjectorService
|
||||
|
||||
+1
-1
@@ -133,7 +133,7 @@ declare namespace ng {
|
||||
whenPUT(url: RegExp, data?: RegExp, headers?: any): mock.IRequestHandler;
|
||||
}
|
||||
|
||||
export module mock {
|
||||
export namespace mock {
|
||||
|
||||
// returned interface by the the mocked HttpBackendService expect/when methods
|
||||
interface IRequestHandler {
|
||||
|
||||
+1
-1
@@ -209,7 +209,7 @@ declare namespace ng {
|
||||
whenPUT(url: RegExp, data?: Object, headers?: Object): mock.IRequestHandler;
|
||||
}
|
||||
|
||||
export module mock {
|
||||
export namespace mock {
|
||||
|
||||
// returned interface by the the mocked HttpBackendService expect/when methods
|
||||
interface IRequestHandler {
|
||||
|
||||
+8
-9
@@ -59,7 +59,7 @@ declare namespace ng.resource {
|
||||
// Also, static calls always return the IResource (or IResourceArray) retrieved
|
||||
// https://github.com/angular/angular.js/blob/v1.2.0/src/ngResource/resource.js#L538-L549
|
||||
interface IResourceClass<T> {
|
||||
new(dataOrParams? : any) : T;
|
||||
new(dataOrParams?: any): T;
|
||||
get(): T;
|
||||
get(params: Object): T;
|
||||
get(success: Function, error?: Function): T;
|
||||
@@ -115,8 +115,8 @@ declare namespace ng.resource {
|
||||
$delete(success: Function, error?: Function): ng.IPromise<T>;
|
||||
|
||||
/** the promise of the original server interaction that created this instance. **/
|
||||
$promise : ng.IPromise<T>;
|
||||
$resolved : boolean;
|
||||
$promise: ng.IPromise<T>;
|
||||
$resolved: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -124,8 +124,8 @@ declare namespace ng.resource {
|
||||
*/
|
||||
interface IResourceArray<T> extends Array<T> {
|
||||
/** the promise of the original server interaction that created this collection. **/
|
||||
$promise : ng.IPromise<IResourceArray<T>>;
|
||||
$resolved : boolean;
|
||||
$promise: ng.IPromise<IResourceArray<T>>;
|
||||
$resolved: boolean;
|
||||
}
|
||||
|
||||
/** when creating a resource factory via IModule.factory */
|
||||
@@ -144,9 +144,8 @@ declare namespace ng {
|
||||
}
|
||||
}
|
||||
|
||||
interface Array<T>
|
||||
{
|
||||
interface Array<T> {
|
||||
/** the promise of the original server interaction that created this collection. **/
|
||||
$promise : ng.IPromise<Array<T>>;
|
||||
$resolved : boolean;
|
||||
$promise: ng.IPromise<Array<T>>;
|
||||
$resolved: boolean;
|
||||
}
|
||||
|
||||
+9
-10
@@ -82,7 +82,7 @@ declare namespace angular.resource {
|
||||
// Also, static calls always return the IResource (or IResourceArray) retrieved
|
||||
// https://github.com/angular/angular.js/blob/v1.2.0/src/ngResource/resource.js#L538-L549
|
||||
interface IResourceClass<T> {
|
||||
new(dataOrParams? : any) : T;
|
||||
new(dataOrParams?: any): T;
|
||||
get(): T;
|
||||
get(params: Object): T;
|
||||
get(success: Function, error?: Function): T;
|
||||
@@ -138,11 +138,11 @@ declare namespace angular.resource {
|
||||
$delete(success: Function, error?: Function): angular.IPromise<T>;
|
||||
|
||||
/** the promise of the original server interaction that created this instance. **/
|
||||
$promise : angular.IPromise<T>;
|
||||
$resolved : boolean;
|
||||
$promise: angular.IPromise<T>;
|
||||
$resolved: boolean;
|
||||
toJSON: () => {
|
||||
[index: string]: any;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -150,8 +150,8 @@ declare namespace angular.resource {
|
||||
*/
|
||||
interface IResourceArray<T> extends Array<T & IResource<T>> {
|
||||
/** the promise of the original server interaction that created this collection. **/
|
||||
$promise : angular.IPromise<IResourceArray<T>>;
|
||||
$resolved : boolean;
|
||||
$promise: angular.IPromise<IResourceArray<T>>;
|
||||
$resolved: boolean;
|
||||
}
|
||||
|
||||
/** when creating a resource factory via IModule.factory */
|
||||
@@ -177,9 +177,8 @@ declare namespace angular {
|
||||
}
|
||||
}
|
||||
|
||||
interface Array<T>
|
||||
{
|
||||
interface Array<T> {
|
||||
/** the promise of the original server interaction that created this collection. **/
|
||||
$promise : angular.IPromise<Array<T>>;
|
||||
$resolved : boolean;
|
||||
$promise: angular.IPromise<Array<T>>;
|
||||
$resolved: boolean;
|
||||
}
|
||||
|
||||
+1
-1
@@ -23,7 +23,7 @@ declare namespace ng.sanitize {
|
||||
// Filters included with the ngSanitize
|
||||
// see https://code.angularjs.org/1.2.26/docs/api/ngSanitize/filter
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
export module filter {
|
||||
export namespace filter {
|
||||
|
||||
// Finds links in text input and turns them into html links.
|
||||
// Supports http/https/ftp/mailto and plain email address links.
|
||||
|
||||
+2
-2
@@ -61,7 +61,7 @@ declare namespace angularScenario {
|
||||
toBeGreaterThan(value: any): void;
|
||||
}
|
||||
|
||||
export interface CustomMatchers extends Matchers{
|
||||
export interface CustomMatchers extends Matchers {
|
||||
}
|
||||
|
||||
export interface Expect extends CustomMatchers {
|
||||
@@ -97,7 +97,7 @@ declare namespace angularScenario {
|
||||
export interface Element {
|
||||
count(): Future;
|
||||
click(): any;
|
||||
query(callback: (selectedDOMElements: any[], callbackWhenDone: (objNull: any, futureValue: any) => any) =>any): any;
|
||||
query(callback: (selectedDOMElements: any[], callbackWhenDone: (objNull: any, futureValue: any) => any) => any): any;
|
||||
val(): Future;
|
||||
text(): Future;
|
||||
html(): Future;
|
||||
|
||||
Reference in New Issue
Block a user