forked from DefinitelyTyped/DefinitelyTyped
-
Notifications
You must be signed in to change notification settings - Fork 0
/
angular-scroll.d.ts
44 lines (31 loc) · 1.98 KB
/
angular-scroll.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
39
40
41
42
43
44
// Type definitions for angular-scroll
// Project: https://github.com/oblador/angular-scroll
// Definitions by: Sam Herrmann <https://github.com/samherrmann>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
/// <reference path="../angularjs/angular.d.ts" />
declare module duScroll {
/**
* Extends the angular.element object returned by the $document sercive with a few jQuery like functions.
* see https://github.com/oblador/angular-scroll#angularelement-scroll-api
*/
interface IDocumentService extends ng.IDocumentService {
duScrollTo(left: number, top: number): void;
duScrollTo(left: number, top: number, duration: number, easing?: Function): ng.IPromise<void>;
duScrollTo(element: ng.IAugmentedJQuery, offset?: number): void;
duScrollTo(element: ng.IAugmentedJQuery, offset: number, duration: number, easing?: Function): ng.IPromise<void>;
duScrollToElement(element: ng.IAugmentedJQuery, offset?: number): void;
duScrollToElement(element: ng.IAugmentedJQuery, offset: number, duration: number, easing?: Function): ng.IPromise<void>;
duScrollToElementAnimated(element: ng.IAugmentedJQuery, offset?: number): ng.IPromise<void>;
duScrollToElementAnimated(element: ng.IAugmentedJQuery, offset: number, duration: number, easing?: Function): ng.IPromise<void>;
duScrollTop(top: number): void;
duScrollTop(top: number, duration: number, easing?: Function): ng.IPromise<void>;
duScrollTopAnimated(top: number): ng.IPromise<void>;
duScrollTopAnimated(top: number, duration: number, easing?: Function): ng.IPromise<void>;
duScrollLeft(left: number): void;
duScrollLeft(left: number, duration: number, easing?: Function): ng.IPromise<void>;
duScrollLeftAnimated(left: number): ng.IPromise<void>;
duScrollLeftAnimated(left: number, duration: number, easing?: Function): ng.IPromise<void>;
duScrollTop(): number;
duScrollLeft(): number;
}
}