forked from jbaroudi/DefinitelyTyped
-
Notifications
You must be signed in to change notification settings - Fork 0
/
angular-modal.d.ts
38 lines (29 loc) · 1.35 KB
/
angular-modal.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
// Type definitions for angular-modal 0.5.0
// Project: https://github.com/btford/angular-modal
// Definitions by: Paul Lessing <https://github.com/paullessing>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
/// <reference path="../angularjs/angular.d.ts" />
/// <reference path="../jquery/jquery.d.ts" />
declare module angularModal {
type AngularModalControllerDefinition = (new (...args: any[]) => any) | Function | string; // Possible arguments to IControllerService
type AngularModalJQuerySelector = string | Element | Element[] | JQuery | Function | any[] | {}; // Possible arguments to IAugmentedJQueryStatic
interface AngularModalSettings {
controller?: AngularModalControllerDefinition;
controllerAs?: string;
container?: AngularModalJQuerySelector;
}
export interface AngularModalSettingsWithTemplate extends AngularModalSettings {
template: any;
}
export interface AngularModalSettingsWithTemplateUrl extends AngularModalSettings {
templateUrl: string;
}
export interface AngularModal {
activate(): angular.IPromise<void>;
deactivate(): angular.IPromise<void>;
active(): boolean;
}
export interface AngularModalFactory {
(settings: AngularModalSettingsWithTemplate | AngularModalSettingsWithTemplateUrl): AngularModal;
}
}