Merge pull request #2738 from Biegal/AngularSpinnerDefinitions

Definitions for angular-spinner directive
This commit is contained in:
Masahiro Wakame
2014-08-30 02:28:11 +09:00
3 changed files with 39 additions and 0 deletions
+1
View File
@@ -13,6 +13,7 @@ All definitions files include a header with the author and editors, so at some p
* [AngularFire](https://www.firebase.com/docs/angular/reference.html) (by [Dénes Harmath](https://github.com/thSoft))
* [AngularJS](http://angularjs.org) (by [Diego Vilar](https://github.com/diegovilar)) ([wiki](https://github.com/borisyankov/DefinitelyTyped/wiki/AngularJS-Definitions-Usage-Notes))
* [angularLocalStorage](https://github.com/agrublev/angularLocalStorage) (by [Hiroki Horiuchi](https://github.com/horiuchi/))
* [angular-spinner](https://github.com/urish/angular-spinner) (by [Marcin Biegała](https://github.com/Biegal))
* [AngularUI](http://angular-ui.github.io/) (by [Michel Salib](https://github.com/michelsalib))
* [Angular Hotkeys](https://github.com/chieffancypants/angular-hotkeys/) (by [Jason Zhao](https://github.com/jlz27))
* [Angular Protractor](https://github.com/angular/protractor) (by [Bill Armstrong](https://github.com/BillArmstrong))
+12
View File
@@ -0,0 +1,12 @@
/// <reference path="angular-spinner.d.ts" />
var myApp = angular.module('testModule');
module AngularSpinnerTest {
var app = angular.module("angularSpinnerTest", ["angular-spinner"]);
app.config(['usSpinnerService', function(usSpinnerService: ISpinnerService) {
usSpinnerService.spin('key1');
usSpinnerService.stop('key2');
}]);
}
+26
View File
@@ -0,0 +1,26 @@
// Type definitions for angular-spinner.js 0.5.1
// Project: https://github.com/urish/angular-spinner
// Definitions by: Marcin Biegała <https://github.com/Biegal>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
/// <reference path="../angularjs/angular.d.ts" />
/**
* SpinnerService
* see https://github.com/urish/angular-spinner
*/
interface ISpinnerService {
/**
* Start selected spinner
*
* @param spinner key
*/
spin(key: string): void;
/**
* Stop selected spinner
*
* @param spinner key
*/
stop(key: string): void;
}