mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-09-09 11:13:57 +08:00
Merge remote-tracking branch 'borisyankov/master'
This commit is contained in:
+57
-14
@@ -13,6 +13,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](amcharts/AmCharts.d.ts) [amCharts](http://www.amcharts.com) by [aleksey-bykov](https://github.com/aleksey-bykov)
|
||||
* [:link:](amplifyjs/amplifyjs.d.ts) [AmplifyJs](http://amplifyjs.com) by [Jonas Eriksson](https://github.com/joeriks)
|
||||
* [:link:](amqp-rpc/amqp-rpc.d.ts) [amqp-rpc](https://github.com/demchenkoe/node-amqp-rpc) by [Wonshik Kim](https://github.com/wokim)
|
||||
* [:link:](amqplib/amqplib.d.ts) [amqplib 0.3.x](https://github.com/squaremo/amqp.node) by [Michael Nahkies](https://github.com/mnahkies)
|
||||
* [:link:](angular2/router.d.ts) [Angular](http://angular.io) by [angular team](https://github.com/angular)
|
||||
* [:link:](angular2/angular2.d.ts) [Angular](http://angular.io) by [angular team](https://github.com/angular)
|
||||
* [:link:](angular-file-upload/angular-file-upload.d.ts) [Angular File Upload](https://github.com/danialfarid/ng-file-upload) by [John Reilly](https://github.com/johnnyreilly)
|
||||
@@ -40,8 +41,10 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](angular-jwt/angular-jwt.d.ts) [angular-jwt](https://github.com/auth0/angular-jwt) by [Reto Rezzonico](https://github.com/rerezz)
|
||||
* [:link:](angular-local-storage/angular-local-storage.d.ts) [angular-local-storage](https://github.com/grevory/angular-local-storage) by [Ken Fukuyama](https://github.com/kenfdev)
|
||||
* [:link:](angular-localForage/angular-localForage.d.ts) [angular-localForage](https://github.com/ocombe/angular-localForage) by [Stefan Steinhart](https://github.com/reppners)
|
||||
* [:link:](angular-notifications/angular-notifications.d.ts) [angular-notifications](https://github.com/DerekRies/angular-notifications) by [Tomasz Ducin](https://github.com/ducin/DefinitelyTyped)
|
||||
* [:link:](angular-notify/angular-notify.d.ts) [angular-notify](https://github.com/cgross/angular-notify) by [Suwato](https://github.com/Suwato/DefinitelyTyped)
|
||||
* [:link:](angular-scroll/angular-scroll.d.ts) [angular-scroll](https://github.com/oblador/angular-scroll) by [Sam Herrmann](https://github.com/samherrmann)
|
||||
* [:link:](angular-signalr-hub/angular-signalr-hub.d.ts) [angular-signalr-hub](https://github.com/JustMaier/angular-signalr-hub) by [Adam Santaniello](https://github.com/AdamSantaniello)
|
||||
* [:link:](angular-spinner/angular-spinner.d.ts) [angular-spinner.js](https://github.com/urish/angular-spinner) by [Marcin Biegała](https://github.com/Biegal)
|
||||
* [:link:](angular-storage/angular-storage.d.ts) [angular-storage](https://github.com/auth0/angular-storage) by [Matthew DeKrey](https://github.com/mdekrey)
|
||||
* [:link:](angular.throttle/angular.throttle.d.ts) [angular.throttle](https://github.com/BaggersIO/angular.throttle) by [Stefan Steinhart](https://github.com/reppners)
|
||||
@@ -79,7 +82,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](auth0/auth0.d.ts) [Auth0.js](http://auth0.com) by [Robert McLaws](https://github.com/advancedrei)
|
||||
* [:link:](auth0.lock/auth0.lock.d.ts) [Auth0Widget.js](http://auth0.com) by [Robert McLaws](https://github.com/advancedrei)
|
||||
* [:link:](auth0.widget/auth0.widget.d.ts) [Auth0Widget.js](http://auth0.com) by [Robert McLaws](https://github.com/advancedrei)
|
||||
* [:link:](autobahn/autobahn.d.ts) [AutobahnJS](http://autobahn.ws/js) by [Elad Zelingher](https://github.com/darkl)
|
||||
* [:link:](autobahn/autobahn.d.ts) [AutobahnJS](http://autobahn.ws/js) by [Elad Zelingher](https://github.com/darkl), [Andy Hawkins](https://github.com/a904guy/,http://a904guy.com/,http://www.bmbsqd.com)
|
||||
* [:link:](autoprefixer-core/autoprefixer-core.d.ts) [Autoprefixer Core](https://github.com/postcss/autoprefixer-core) by [Asana](https://asana.com)
|
||||
* [:link:](aws-sdk/aws-sdk.d.ts) [aws-sdk](https://github.com/aws/aws-sdk-js) by [midknight41](https://github.com/midknight41)
|
||||
* [:link:](axios/axios.d.ts) [axios](https://github.com/mzabriskie/axios) by [Marcel Buesing](https://github.com/marcelbuesing)
|
||||
@@ -106,7 +109,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](blueimp-md5/blueimp-md5.d.ts) [blueimp-md5](https://github.com/blueimp/JavaScript-MD5) by [Ray Martone](https://github.com/rmartone)
|
||||
* [:link:](body-parser/body-parser.d.ts) [body-parser](http://expressjs.com) by [Santi Albo](https://github.com/santialbo), [VILIC VANE](https://vilic.info), [Jonathan Häberle](https://github.com/dreampulse)
|
||||
* [:link:](boom/boom.d.ts) [boom](http://github.com/hapijs/boom) by [Igor Rogatty](http://github.com/rogatty)
|
||||
* [:link:](bootbox/bootbox.d.ts) [Bootbox](https://github.com/makeusabrew/bootbox) by [Vincent Bortone](https://github.com/vbortone), [Kon Pik](https://github.com/konpikwastaken), [Anup Kattel](https://github.com/kanup)
|
||||
* [:link:](bootbox/bootbox.d.ts) [Bootbox](https://github.com/makeusabrew/bootbox) by [Vincent Bortone](https://github.com/vbortone), [Kon Pik](https://github.com/konpikwastaken), [Anup Kattel](https://github.com/kanup), [Dominik Schroeter](https://github.com/icereed)
|
||||
* [:link:](bootstrap/bootstrap.d.ts) [Bootstrap](http://twitter.github.com/bootstrap) by [Boris Yankov](https://github.com/borisyankov)
|
||||
* [:link:](bootstrap.v3.datetimepicker/bootstrap.v3.datetimepicker.d.ts) [Bootstrap datetimepicker v3](http://eonasdan.github.io/bootstrap-datetimepicker) by [Jesica N. Fera](https://github.com/bayitajesi)
|
||||
* [:link:](bootstrap-touchspin/bootstrap-touchspin.d.ts) [Bootstrap TouchSpin](http://www.virtuosoft.eu/code/bootstrap-touchspin) by [Albin Sunnanbo](https://github.com/albinsunnanbo)
|
||||
@@ -114,8 +117,8 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](bootstrap-slider/bootstrap-slider.d.ts) [bootstrap-slider.js](https://github.com/seiyria/bootstrap-slider) by [Daniel Beckwith](https://github.com/dbeckwith)
|
||||
* [:link:](bootstrap.datepicker/bootstrap.datepicker.d.ts) [bootstrap.datepicker](https://github.com/eternicode/bootstrap-datepicker) by [Boris Yankov](https://github.com/borisyankov)
|
||||
* [:link:](bootstrap.paginator/bootstrap.paginator.d.ts) [bootstrap.paginator](https://github.com/lyonlai/bootstrap-paginator) by [derikwhittaker](https://github.com/derikwhittaker)
|
||||
* [:link:](box2d/box2dweb.d.ts) [bootstrap.timepicker](http://code.google.com/p/box2dweb) by [jbaldwin](https://github.com/jbaldwin)
|
||||
* [:link:](bootstrap.timepicker/bootstrap.timepicker.d.ts) [bootstrap.timepicker](https://github.com/jdewit/bootstrap-timepicker) by [derikwhittaker](https://github.com/derikwhittaker)
|
||||
* [:link:](box2d/box2dweb.d.ts) [bootstrap.timepicker](http://code.google.com/p/box2dweb) by [jbaldwin](https://github.com/jbaldwin)
|
||||
* [:link:](breeze/breeze.d.ts) [Breeze 1.5.x](http://www.breezejs.com) by [Boris Yankov](https://github.com/borisyankov), [IdeaBlade](https://github.com/IdeaBlade/Breeze)
|
||||
* [:link:](browser-harness/browser-harness.d.ts) [Browser Harness](https://github.com/scriby/browser-harness) by [Chris Scribner](https://github.com/scriby)
|
||||
* [:link:](browser-sync/browser-sync.d.ts) [browser-sync](http://www.browsersync.io) by [Asana](https://asana.com)
|
||||
@@ -127,6 +130,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](bufferstream/bufferstream.d.ts) [bufferstream](https://github.com/dodo/node-bufferstream) by [Bart van der Schoor](https://github.com/Bartvds)
|
||||
* [:link:](bunyan-prettystream/bunyan-prettystream.d.ts) [bunyan-prettystream](https://www.npmjs.com/package/bunyan-prettystream) by [Jason Swearingen](https://github.com/jasonswearingen), [Vadim Macagon](https://github.com/enlight)
|
||||
* [:link:](business-rules-engine/business-rules-engine.d.ts) [business-rules-engine](https://github.com/rsamec/form) by [Roman Samec](https://github.com/rsamec)
|
||||
* [:link:](dw-bxslider-4/dw-bxslider-4.d.ts) [bxSlider](https://github.com/stevenwanderski/bxslider-4) by [Piotr Sałkowski](https://github.com/namerci)
|
||||
* [:link:](byline/byline.d.ts) [byline](https://github.com/jahewson/node-byline) by [Stefan Steinhart](https://github.com/reppners)
|
||||
* [:link:](calq/calq.d.ts) [calq](https://calq.io/docs/client/javascript/reference) by [Eirik Hoem](https://github.com/eirikhm)
|
||||
* [:link:](camel-case/camel-case.d.ts) [camel-case](https://github.com/blakeembrey/camel-case) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
@@ -181,6 +185,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](cordova-ionic/plugins/keyboard.d.ts) [Cordova Keyboard plugin](https://github.com/driftyco/ionic-plugins-keyboard) by [Hendrik Maus](https://github.com/hendrikmaus)
|
||||
* [:link:](cordovarduino/cordovarduino.d.ts) [Cordovarduino plugin](https://github.com/stereolux/cordovarduino) by [Hendrik Maus](https://github.com/hendrikmaus)
|
||||
* [:link:](core-js/core-js.d.ts) [core-js](https://github.com/zloirock/core-js) by [Ron Buckton](http://github.com/rbuckton)
|
||||
* [:link:](cors/cors.d.ts) [cors](https://github.com/troygoode/node-cors) by [Mihhail Lapushkin](https://github.com/mihhail-lapushkin)
|
||||
* [:link:](couchbase/couchbase.d.ts) [Couchbase Couchnode](https://github.com/couchbase/couchnode) by [Basarat Ali Syed](https://github.com/basarat)
|
||||
* [:link:](createjs/createjs.d.ts) [CreateJS](http://www.createjs.com) by [Pedro Ferreira](https://bitbucket.org/drk4), [Chris Smith](https://github.com/evilangelist), [Satoru Kimura](https://github.com/gyohk)
|
||||
* [:link:](cron/cron.d.ts) [cron](https://www.npmjs.com/package/cron) by [Hiroki Horiuchi](https://github.com/horiuchi)
|
||||
@@ -200,6 +205,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](dagre/dagre.d.ts) [dagre](https://github.com/cpettitt/dagre) by [Qinfeng Chen](https://github.com/qinfchen)
|
||||
* [:link:](dagre-d3/dagre-d3.d.ts) [dagre-d3.core.js](https://github.com/cpettitt/dagre-d3) by [Mark Wong Siang Kai](https://github.com/markwongsk)
|
||||
* [:link:](dat-gui/dat-gui.d.ts) [dat.GUI](https://github.com/dataarts/dat.gui) by [Satoru Kimura](https://github.com/gyohk)
|
||||
* [:link:](data-driven/data-driven.d.ts) [data-driven.js](https://github.com/fluentsoftware/data-driven) by [Adam Babcock](https://github.com/mrhen)
|
||||
* [:link:](DataStream.js/DataStream.js.d.ts) [DataStream.js](https://github.com/kig/DataStream.js) by [Tat](https://github.com/tatchx)
|
||||
* [:link:](date.format.js/date.format.d.ts) [Date Format](http://blog.stevenlevithan.com/archives/date-time-format) by [Rob Stutton](https://github.com/balrob)
|
||||
* [:link:](datejs/datejs.d.ts) [DateJS](http://www.datejs.com) by [David Khristepher Santos](http://github.com/rupertavery)
|
||||
@@ -217,6 +223,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](dhtmlxscheduler/dhtmlxscheduler.d.ts) [dhtmlxScheduler](http://dhtmlx.com/docs/products/dhtmlxScheduler) by [Maksim Kozhukh](http://github.com/mkozhukh)
|
||||
* [:link:](di-lite/di-lite.d.ts) [di-lite](https://github.com/NickQiZhu/di.js) by [Timothy Morris](https://github.com/dcrusader)
|
||||
* [:link:](diff/diff.d.ts) [diff](https://github.com/kpdecker/jsdiff) by [vvakame](https://github.com/vvakame)
|
||||
* [:link:](diff-match-patch/diff-match-patch.d.ts) [diff-match-patch](https://www.npmjs.com/package/diff-match-patch) by [Asana](https://asana.com)
|
||||
* [:link:](docCookies/docCookies.d.ts) [docCookies](https://developer.mozilla.org/en-US/docs/Web/API/document.cookie) by [Jon Egerton](https://github.com/jonegerton)
|
||||
* [:link:](dock-spawn/dock-spawn.d.ts) [Dock Spawn](http://dockspawn.com) by [Drew Noakes](https://drewnoakes.com)
|
||||
* [:link:](documentdb/documentdb.d.ts) [DocumentDB](https://github.com/Azure/azure-documentdb-node) by [Noel Abrahams](https://github.com/NoelAbrahams), [Brett Gutstein](https://github.com/brettferdosi)
|
||||
@@ -229,9 +236,10 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](dot-case/dot-case.d.ts) [dot-case](https://github.com/blakeembrey/dot-case) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
* [:link:](dotdotdot/dotdotdot.d.ts) [dotdotdot](http://dotdotdot.frebsite.nl) by [Milan Jaros](https://github.com/milanjaros)
|
||||
* [:link:](doublearray/doublearray.d.ts) [doublearray](https://github.com/takuyaa/doublearray) by [MIZUSHIMA Junki](https://github.com/mzsm)
|
||||
* [:link:](dragula/dragula.d.ts) [dragula](http://bevacqua.github.io/dragula) by [Paul Welter](https://github.com/pwelter34)
|
||||
* [:link:](drop/drop.d.ts) [Drop](http://github.hubspot.com/drop) by [Adi Dahiya](https://github.com/adidahiya)
|
||||
* [:link:](dropboxjs/dropboxjs.d.ts) [dropbox-js](https://github.com/dropbox/dropbox-js) by [Steve Fenton](https://github.com/Steve-Fenton), [Pedro Casaubon](https://github.com/xperiments)
|
||||
* [:link:](dropzone/dropzone.d.ts) [Dropzone](http://www.dropzonejs.com) by [Natan Vivo](https://github.com/nvivo)
|
||||
* [:link:](dropzone/dropzone.d.ts) [Dropzone](http://www.dropzonejs.com) by [Natan Vivo](https://github.com/nvivo), [Andy Hawkins](https://github.com/a904guy/,http://a904guy.com/,http://www.bmbsqd.com)
|
||||
* [:link:](dsv/dsv.d.ts) [dsv](https://www.npmjs.com/package/dsv) by [Jason Swearingen](https://jasonswearingen.github.io)
|
||||
* [:link:](dts-bundle/dts-bundle.d.ts) [dts-bundle](https://github.com/TypeStrong/dts-bundle) by [Asana](https://asana.com)
|
||||
* [:link:](durandal/durandal.d.ts) [Durandal](http://durandaljs.com) by [Blue Spire](https://github.com/BlueSpire)
|
||||
@@ -249,6 +257,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](ejs-locals/ejs-locals.d.ts) [ejs-locals](https://github.com/randometc/ejs-locals) by [jt000](https://github.com/jt000)
|
||||
* [:link:](jquery.elang/jquery.elang.d.ts) [eLang](https://github.com/sumegizoltan/ELang) by [Zoltan Sumegi](https://github.com/sumegizoltan)
|
||||
* [:link:](github-electron/github-electron.d.ts) [Electron (shared between main and rederer processes)](http://electron.atom.io) by [jedmao](https://github.com/jedmao)
|
||||
* [:link:](github-electron/electron-prebuilt.d.ts) [electron-prebuilt](https://github.com/mafintosh/electron-prebuilt) by [rhysd](https://github.com/rhysd)
|
||||
* [:link:](element-resize-event/element-resize-event.d.ts) [element-resize-event](https://github.com/KyleAMathews/element-resize-event) by [Rogier Schouten](https://github.com/rogierschouten)
|
||||
* [:link:](elm/elm.d.ts) [Elm](http://elm-lang.org) by [Dénes Harmath](https://github.com/thSoft)
|
||||
* [:link:](ember/ember.d.ts) [Ember.js](http://emberjs.com) by [Jed Mao](https://github.com/jedmao)
|
||||
@@ -263,13 +272,15 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](es6-shim/es6-shim.d.ts) [es6-shim](https://github.com/paulmillr/es6-shim) by [Ron Buckton](http://github.com/rbuckton)
|
||||
* [:link:](escape-latex/escape-latex.d.ts) [escape-latex](https://github.com/dangmai/escape-latex) by [Oliver Schneider](https://github.com/olsio)
|
||||
* [:link:](esprima/esprima.d.ts) [Esprima](http://esprima.org) by [teppeis](https://github.com/teppeis), [RReverser](https://github.com/RReverser)
|
||||
* [:link:](estree/flow.d.ts) [ESTree AST extensions for Facebook Flow](https://github.com/estree/estree) by [RReverser](https://github.com/RReverser)
|
||||
* [:link:](estree/estree.d.ts) [ESTree AST specification](https://github.com/estree/estree) by [RReverser](https://github.com/RReverser)
|
||||
* [:link:](event-kit/event-kit.d.ts) [event-kit](https://github.com/atom/event-kit) by [Vadim Macagon](https://github.com/enlight)
|
||||
* [:link:](event-loop-lag/event-loop-lag.d.ts) [event-loop-lag](https://github.com/pebble/event-loop-lag) by [Rogier Schouten](https://github.com/rogierschouten)
|
||||
* [:link:](eventemitter2/eventemitter2.d.ts) [EventEmitter2](https://github.com/asyncly/EventEmitter2) by [ryiwamoto](https://github.com/ryiwamoto)
|
||||
* [:link:](eventemitter3/eventemitter3.d.ts) [EventEmitter3](https://github.com/primus/eventemitter3) by [Yuichi Murata](https://github.com/mrk21)
|
||||
* [:link:](evernote/evernote.d.ts) [evernote v](https://www.npmjs.com/package/evernote) by [Zachary Collins](https://github.com/corps)
|
||||
* [:link:](exit/exit.d.ts) [exit](https://github.com/cowboy/node-exit) by [Bart van der Schoor](https://github.com/Bartvds)
|
||||
* [:link:](expect.js/expect.js.d.ts) [expect.js](https://github.com/LearnBoost/expect.js) by [Teppei Sato](https://github.com/teppeis)
|
||||
* [:link:](expect.js/expect.js.d.ts) [expect.js](https://github.com/Automattic/expect.js) by [Teppei Sato](https://github.com/teppeis)
|
||||
* [:link:](expectations/expectations.d.ts) [expectations.js](https://github.com/spmason/expectations) by [vvakame](https://github.com/vvakame)
|
||||
* [:link:](express/express.d.ts) [Express 4.x](http://expressjs.com) by [Boris Yankov](https://github.com/borisyankov)
|
||||
* [:link:](express-debug/express-debug.d.ts) [express-debug](https://github.com/devoidfury/express-debug) by [Federico Bond](https://github.com/federicobond)
|
||||
@@ -284,6 +295,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](eyes/eyes.d.ts) [eyes](https://github.com/cloudhead/eyes.js) by [bryn austin bellomy](https://github.com/brynbellomy)
|
||||
* [:link:](fabricjs/fabricjs.d.ts) [FabricJS](http://fabricjs.com) by [Oliver Klemencic](https://github.com/oklemencic), [Joseph Livecchi](https://github.com/joewashear007)
|
||||
* [:link:](fbsdk/fbsdk.d.ts) [Facebook Javascript SDK](https://developers.facebook.com/docs/javascript) by [Joshua Strobl](https://github.com/JoshStrobl)
|
||||
* [:link:](famous/famous.d.ts) [Famous Engine](http://famous.org) by [Boris Vasilenko](https://github.com/borisvasilenko)
|
||||
* [:link:](fancybox/fancybox.d.ts) [fancyBox](https://github.com/fancyapps/fancyBox) by [Boris Yankov](https://github.com/borisyankov)
|
||||
* [:link:](farbtastic/farbtastic.d.ts) [Farbtastic: jQuery Color Wheel](http://mattfarina.github.io/farbtastic) by [Matt Brooks](https://github.com/EnableSoftware)
|
||||
* [:link:](fast-stats/fast-stats.d.ts) [fast-stats](https://github.com/bluesmoon/node-faststats) by [Rogier Schouten](https://github.com/rogierschouten)
|
||||
@@ -299,6 +311,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](fingerprintjs/fingerprint.d.ts) [fingerprintjs](https://github.com/Valve/fingerprintjs) by [Shunsuke Ohtani](https://github.com/zaneli)
|
||||
* [:link:](state-machine/state-machine.d.ts) [Finite State Machine](https://github.com/jakesgordon/javascript-state-machine) by [Boris Yankov](https://github.com/borisyankov), [Maarten Docter](https://github.com/mdocter), [William Sears](https://github.com/MrBigDog2U)
|
||||
* [:link:](firebase/firebase.d.ts) [Firebase API](https://www.firebase.com/docs/javascript/firebase) by [Vincent Botone](https://github.com/vbortone), [Shin1 Kashimura](https://github.com/in-async)
|
||||
* [:link:](firebase-client/firebase-client.d.ts) [Firebase Client](https://www.github.com/jpstevens/firebase-client) by [Andrew Breen](https://github.com/fpsscarecrow)
|
||||
* [:link:](firebase/firebase-simplelogin.d.ts) [Firebase Simple Login](https://www.firebase.com/docs/security/simple-login-overview.html) by [Wilker Lucio](http://github.com/wilkerlucio)
|
||||
* [:link:](first-mate/first-mate.d.ts) [first-mate](https://github.com/atom/first-mate) by [Vadim Macagon](https://github.com/enlight)
|
||||
* [:link:](flexSlider/flexSlider.d.ts) [FlexSlider 2 jquery plugin](https://github.com/woothemes/FlexSlider) by [Diullei Gomes](https://github.com/diullei)
|
||||
@@ -357,8 +370,8 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](greensock/greensock.d.ts) [GreenSock Animation Platform](http://www.greensock.com/get-started-js) by [Robert S](https://github.com/codebelt)
|
||||
* [:link:](gridfs-stream/gridfs-stream.d.ts) [gridfs-stream](https://github.com/aheckmann/gridfs-stream) by [Lior Mualem](https://github.com/liorm)
|
||||
* [:link:](gruntjs/gruntjs.d.ts) [Grunt 0.4.x](http://gruntjs.com) by [Jeff May](https://github.com/jeffmay), [Basarat Ali Syed](https://github.com/basarat)
|
||||
* [:link:](gsap/Ease.d.ts) [GSAP](http://greensock.com) by [VILIC VANE](https://vilic.github.io)
|
||||
* [:link:](gsap/Core.d.ts) [GSAP](http://greensock.com) by [VILIC VANE](https://vilic.github.io)
|
||||
* [:link:](gsap/Ease.d.ts) [GSAP](http://greensock.com) by [VILIC VANE](https://vilic.github.io)
|
||||
* [:link:](gsap/TweenLite.d.ts) [GSAP](http://greensock.com) by [VILIC VANE](https://vilic.github.io)
|
||||
* [:link:](gulp/gulp.d.ts) [Gulp v3.8.x](http://gulpjs.com) by [Drew Noakes](https://drewnoakes.com)
|
||||
* [:link:](gulp-autoprefixer/gulp-autoprefixer.d.ts) [gulp-autoprefixer](https://github.com/sindresorhus/gulp-autoprefixer) by [Asana](https://asana.com)
|
||||
@@ -373,6 +386,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](gulp-istanbul/gulp-istanbul.d.ts) [gulp-istanbul](https://github.com/SBoudrias/gulp-istanbul) by [Asana](https://asana.com)
|
||||
* [:link:](gulp-jasmine-browser/gulp-jasmine-browser.d.ts) [gulp-jasmine-browser](https://github.com/jasmine/gulp-jasmine-browser) by [Tanguy Krotoff](https://github.com/tkrotoff)
|
||||
* [:link:](gulp-less/gulp-less.d.ts) [gulp-less](https://github.com/plus3network/gulp-less) by [Keita Kagurazaka](https://github.com/k-kagurazaka)
|
||||
* [:link:](gulp-load-plugins/gulp-load-plugins.d.ts) [gulp-load-plugins](https://github.com/jackfranklin/gulp-load-plugins) by [Joe Skeen](http://github.com/joeskeen)
|
||||
* [:link:](gulp-minify-css/gulp-minify-css.d.ts) [gulp-minify-css](https://github.com/jonathanepollack/gulp-minify-css) by [Keita Kagurazaka](https://github.com/k-kagurazaka)
|
||||
* [:link:](gulp-minify-html/gulp-minify-html.d.ts) [gulp-minify-html](https://github.com/murphydanger/gulp-minify-html) by [Tanguy Krotoff](https://github.com/tkrotoff)
|
||||
* [:link:](gulp-mocha/gulp-mocha.d.ts) [gulp-mocha](https://github.com/sindresorhus/gulp-mocha) by [Asana](https://asana.com)
|
||||
@@ -380,6 +394,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](gulp-rename/gulp-rename.d.ts) [gulp-rename](https://github.com/hparra/gulp-rename) by [Asana](https://asana.com)
|
||||
* [:link:](gulp-replace/gulp-replace.d.ts) [gulp-replace](https://github.com/lazd/gulp-replace) by [Asana](https://asana.com)
|
||||
* [:link:](gulp-rev-replace/gulp-rev-replace.d.ts) [gulp-rev-replace](https://github.com/jamesknelson/gulp-rev-replace) by [Tanguy Krotoff](https://github.com/tkrotoff)
|
||||
* [:link:](gulp-ruby-sass/gulp-ruby-sass.d.ts) [gulp-ruby-sass](https://github.com/sindresorhus/gulp-ruby-sass) by [Agnislav Onufrijchuk](https://github.com/agnislav)
|
||||
* [:link:](gulp-sass/gulp-sass.d.ts) [gulp-sass](https://github.com/dlmanning/gulp-sass) by [Asana](https://asana.com)
|
||||
* [:link:](gulp-size/gulp-size.d.ts) [gulp-size](https://github.com/sindresorhus/gulp-size) by [Tanguy Krotoff](https://github.com/tkrotoff)
|
||||
* [:link:](gulp-sourcemaps/gulp-sourcemaps.d.ts) [gulp-sourcemaps](https://github.com/floridoo/gulp-sourcemaps) by [Asana](https://asana.com)
|
||||
@@ -396,7 +411,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](hapi/hapi.d.ts) [hapi](http://github.com/spumko/hapi) by [Jason Swearingen](http://github.com/jasonswearingen)
|
||||
* [:link:](hasher/hasher.d.ts) [Hasher.js](https://github.com/millermedeiros/hasher) by [flyfishMT](https://github.com/flyfishMT)
|
||||
* [:link:](hashids/hashids.d.ts) [Hashids.js 1.x](https://github.com/ivanakimov/hashids.node.js) by [Paulo Cesar](https://github.com/pocesar)
|
||||
* [:link:](hashmap/hashmap.d.ts) [HashMap](https://github.com/flesler/hashmap) by [Rafał Wrzeszcz](http://wrzasq.pl)
|
||||
* [:link:](hashmap/hashmap.d.ts) [HashMap](https://github.com/flesler/hashmap) by [Rafał Wrzeszcz](http://wrzasq.pl), [Vasya Aksyonov](https://github.com/outring)
|
||||
* [:link:](he/he.d.ts) [he](https://github.com/mathiasbynens/he) by [Simon Edwards](https://github.com/sedwards2009)
|
||||
* [:link:](Headroom/headroom.d.ts) [headroom.js](http://wicky.nillia.ms/headroom.js) by [Jakub Olek](https://github.com/hakubo)
|
||||
* [:link:](heap/heap.d.ts) [heap](https://github.com/qiao/heap.js) by [Ryan McNamara](https://github.com/ryan10132)
|
||||
@@ -419,8 +434,8 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](humane/humane.d.ts) [Humane](http://wavded.github.com/humane-js) by [jmvrbanac](https://github.com/jmvrbanac)
|
||||
* [:link:](hypertext-application-language/hypertext-application-language.d.ts) [Hypertext Application Language Draft 6](https://tools.ietf.org/html/draft-kelly-json-hal-06) by [Maks3w](https://github.com/maks3w)
|
||||
* [:link:](i18n-node/i18n-node.d.ts) [i18n-node](https://github.com/mashpie/i18n-node) by [Maxime LUCE](https://github.com/SomaticIT)
|
||||
* [:link:](ng-i18next/ng-i18next.d.ts) [i18next](https://github.com/i18next/ng-i18next) by [Cyril Schumacher](https://github.com/cyrilschumacher)
|
||||
* [:link:](i18next/i18next.d.ts) [i18next](http://i18next.com) by [Maarten Docter](https://github.com/mdocter)
|
||||
* [:link:](ng-i18next/ng-i18next.d.ts) [i18next](https://github.com/i18next/ng-i18next) by [Cyril Schumacher](https://github.com/cyrilschumacher)
|
||||
* [:link:](iban/iban.d.ts) [iban.js](https://github.com/arhs/iban.js) by [Cyril Schumacher](https://github.com/cyrilschumacher)
|
||||
* [:link:](icheck/icheck.d.ts) [iCheck](http://damirfoy.com/iCheck) by [Dániel Tar](https://github.com/qcz)
|
||||
* [:link:](imagemagick/imagemagick.d.ts) [imagemagick](http://github.com/rsms/node-imagemagick) by [Carlos Ballesteros Velasco](https://github.com/soywiz)
|
||||
@@ -438,6 +453,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](cordova-ionic/cordova-ionic.d.ts) [Ionic Cordova plugins](https://github.com/driftyco) by [Hendrik Maus](https://github.com/hendrikmaus)
|
||||
* [:link:](irc/irc.d.ts) [irc](https://github.com/martynsmith/node-irc) by [phillips1012](https://github.com/phillips1012)
|
||||
* [:link:](is-lower-case/is-lower-case.d.ts) [is-lower-case](https://github.com/blakeembrey/is-lower-case) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
* [:link:](is-upper-case/is-upper-case.d.ts) [is-upper-case](https://github.com/blakeembrey/is-upper-case) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
* [:link:](is_js/is_js.d.ts) [is.js](http://arasatasaygin.github.io/is.js) by [Rodrigo Cabral](https://github.com/cabralRodrigo)
|
||||
* [:link:](iscroll/iscroll.d.ts) [iScroll](http://cubiq.org/iscroll-4) by [Boris Yankov](https://github.com/borisyankov), [Christiaan Rakowski](https://github.com/csrakowski)
|
||||
* [:link:](iscroll/iscroll-5.d.ts) [iScroll 5](http://cubiq.org/iscroll-5-ready-for-beta-test) by [Christiaan Rakowski](https://github.com/csrakowski)
|
||||
@@ -464,7 +480,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](jjve/jjve.d.ts) [JJVE](https://github.com/silas/jjve) by [Wim Looman](https://github.com/Nemo157)
|
||||
* [:link:](joData/joData.d.ts) [joData](https://github.com/mccow002/joData) by [Chris Wrench](https://github.com/cgwrench)
|
||||
* [:link:](johnny-five/johnny-five.d.ts) [johnny-five](https://github.com/rwaldron/johnny-five) by [Toshiya Nakakura](https://github.com/nakakura)
|
||||
* [:link:](joi/joi.d.ts) [joi](https://github.com/spumko/joi) by [Bart van der Schoor](https://github.com/Bartvds)
|
||||
* [:link:](joi/joi.d.ts) [joi](https://github.com/spumko/joi) by [Bart van der Schoor](https://github.com/Bartvds), [Laurence Dougal Myers](https://github.com/laurence-myers)
|
||||
* [:link:](jointjs/jointjs.d.ts) [Joint JS](http://www.jointjs.com) by [Aidan Reel](http://github.com/areel), [David Durman](http://github.com/DavidDurman), [Ewout Van Gossum](https://github.com/DenEwout)
|
||||
* [:link:](jqrangeslider/jqrangeslider.d.ts) [jQRangeSlider](http://ghusse.github.com/jQRangeSlider) by [Dániel Tar](https://github.com/qcz)
|
||||
* [:link:](jquery/jquery.d.ts) [jQuery 1.10.x / 2.0.x](http://jquery.com) by [Boris Yankov](https://github.com/borisyankov), [Christian Hoffmeister](https://github.com/choffmeister), [Steve Fenton](https://github.com/Steve-Fenton), [Diullei Gomes](https://github.com/Diullei), [Tass Iliopoulos](https://github.com/tasoili), [Jason Swearingen](https://github.com/jasons-novaleaf), [Sean Hill](https://github.com/seanski), [Guus Goossens](https://github.com/Guuz), [Kelly Summerlin](https://github.com/ksummerlin), [Basarat Ali Syed](https://github.com/basarat), [Nicholas Wolverson](https://github.com/nwolverson), [Derek Cicerone](https://github.com/derekcicerone), [Andrew Gaspar](https://github.com/AndrewGaspar), [James Harrison Fisher](https://github.com/jameshfisher), [Seikichi Kondo](https://github.com/seikichi), [Benjamin Jackman](https://github.com/benjaminjackman), [Poul Sorensen](https://github.com/s093294), [Josh Strobl](https://github.com/JoshStrobl), [John Reilly](https://github.com/johnnyreilly), [Dick van den Brink](https://github.com/DickvdBrink)
|
||||
@@ -536,6 +552,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](jquery.timer/jquery.timer.d.ts) [jQueryTimer](https://github.com/jchavannes/jquery-timer) by [Joshua Strobl](https://github.com/JoshStrobl)
|
||||
* [:link:](jquery.total-storage/jquery.total-storage.d.ts) [jQueryTotalStorage](https://github.com/Upstatement/jquery-total-storage) by [Jeremy Brooks](https://github.com/JeremyCBrooks)
|
||||
* [:link:](jqueryui/jqueryui.d.ts) [jQueryUI](http://jqueryui.com) by [Boris Yankov](https://github.com/borisyankov), [John Reilly](https://github.com/johnnyreilly)
|
||||
* [:link:](ua-parser-js/ua-parser-js.d.ts) [js-cookie](https://github.com/faisalman/ua-parser-js) by [Viktor Miroshnikov](https://github.com/superduper)
|
||||
* [:link:](js-cookie/js-cookie.d.ts) [js-cookie](https://github.com/js-cookie/js-cookie) by [Theodore Brown](https://github.com/theodorejb)
|
||||
* [:link:](js-fixtures/fixtures.d.ts) [js-fixtures](https://github.com/badunk/js-fixtures) by [Kazi Manzur Rashid](https://github.com/kazimanzurrashid)
|
||||
* [:link:](js-git/js-git.d.ts) [js-git](https://github.com/creationix/js-git) by [Bart van der Schoor](https://github.com/Bartvds)
|
||||
@@ -575,6 +592,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](kafka-node/kafka-node.d.ts) [kafka-node](https://github.com/SOHU-Co/kafka-node) by [Daniel Imrie-Situnayake](https://github.com/dansitu)
|
||||
* [:link:](karma/karma.d.ts) [karma](https://github.com/karma-runner/karma) by [Tanguy Krotoff](https://github.com/tkrotoff)
|
||||
* [:link:](karma-jasmine/karma-jasmine.d.ts) [karma-jasmine plugin](https://github.com/karma-runner/karma-jasmine) by [Michel Salib](https://github.com/michelsalib)
|
||||
* [:link:](katex/katex.d.ts) [KaTeX v.0.5.0](http://khan.github.io/KaTeX) by [Michael Randolph](https://github.com/mrand01)
|
||||
* [:link:](kendo-ui/kendo-ui.d.ts) [Kendo UI Professional](http://www.telerik.com/kendo-ui) by [Telerik](https://github.com/telerik)
|
||||
* [:link:](keyboardjs/keyboardjs.d.ts) [KeyboardJS](https://github.com/RobertWHurst/KeyboardJS) by [Vincent Bortone](https://github.com/vbortone)
|
||||
* [:link:](keymaster/keymaster.d.ts) [keymaster](https://github.com/madrobby/keymaster) by [Martin W. Kirst](https://github.com/nitram509)
|
||||
@@ -620,7 +638,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](linq/linq.jquery.d.ts) [linq.jquery (from linq.js)](http://linqjs.codeplex.com) by [neuecc](http://www.codeplex.com/site/users/view/neuecc)
|
||||
* [:link:](linq/linq.d.ts) [linq.js](http://linqjs.codeplex.com) by [Marcin Najder](https://github.com/marcinnajder), [Sebastiaan Dammann](https://github.com/Sebazzz)
|
||||
* [:link:](jquery.livestampjs/jquery.livestampjs.d.ts) [Livestamp.js](http://mattbradley.github.com/livestampjs) by [Vincent Bortone](https://github.com/vbortone)
|
||||
* [:link:](lodash/lodash.d.ts) [Lo-Dash](http://lodash.com) by [Brian Zengel](https://github.com/bczengel)
|
||||
* [:link:](lodash/lodash.d.ts) [Lo-Dash](http://lodash.com) by [Brian Zengel](https://github.com/bczengel), [Ilya Mochalov](https://github.com/chrootsu)
|
||||
* [:link:](lockfile/lockfile.d.ts) [lockfile](https://github.com/isaacs/lockfile) by [Bart van der Schoor](https://github.com/Bartvds)
|
||||
* [:link:](log4javascript/log4javascript.d.ts) [log4javascript](http://log4javascript.org) by [Markus Wagner](https://github.com/Ritzlgrmft)
|
||||
* [:link:](log4js/log4js.d.ts) [log4js](https://github.com/nomiddlename/log4js-node) by [Kentaro Okuno](http://github.com/armorik83)
|
||||
@@ -633,6 +651,8 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](long/long.d.ts) [Long.js](https://github.com/dcodeIO/Long.js) by [Peter Kooijmans](https://github.com/peterkooijmans)
|
||||
* [:link:](lory.js/lory.js.d.ts) [lory](https://github.com/meandmax/lory) by [kubosho](https://github.com/kubosho)
|
||||
* [:link:](lovefield/lovefield.d.ts) [Lovefield](http://google.github.io/lovefield) by [freshp86](https://github.com/freshp86)
|
||||
* [:link:](lower-case/lower-case.d.ts) [lower-case](https://github.com/blakeembrey/lower-case) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
* [:link:](lower-case-first/lower-case-first.d.ts) [lower-case-first](https://github.com/blakeembrey/lower-case-first) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
* [:link:](lru-cache/lru-cache.d.ts) [lru-cache](https://github.com/isaacs/node-lru-cache) by [Bart van der Schoor](https://github.com/Bartvds)
|
||||
* [:link:](lscache/lscache.d.ts) [lscache](https://github.com/pamelafox/lscache) by [Chris Martinez](https://github.com/Chris-Martinezz)
|
||||
* [:link:](luaparse/luaparse.d.ts) [luaparse](https://github.com/oxyc/luaparse) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
@@ -662,6 +682,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](messenger/messenger.d.ts) [Messenger.js](https://github.com/HubSpot/messenger) by [Derek Cicerone](https://github.com/derekcicerone)
|
||||
* [:link:](meteor/meteor.d.ts) [Meteor](http://www.meteor.com) by [Dave Allen](https://github.com/fullflavedave)
|
||||
* [:link:](method-override/method-override.d.ts) [method-override](https://github.com/expressjs/method-override) by [Santi Albo](https://github.com/santialbo)
|
||||
* [:link:](metismenu/metismenu.d.ts) [metisMenu](http://github.com/onokumus/metisMenu) by [onokums](https://github.com/onokumus)
|
||||
* [:link:](microsoft-ajax/microsoft.ajax.d.ts) [Microsoft ASP.NET Ajax client side library](http://msdn.microsoft.com/en-us/library/ee341002(v=vs.100).aspx) by [Patrick Magee](https://github.com/pjmagee)
|
||||
* [:link:](xrm/xrm.d.ts) [Microsoft Dynamics xRM API](http://www.microsoft.com/en-us/download/details.aspx?id=44567) by [David Berry](https://github.com/6ix4our), [Matt Ngan](https://github.com/mattngan)
|
||||
* [:link:](xrm/xrm-6.d.ts) [Microsoft Dynamics xRM API v6](http://msdn.microsoft.com/en-us/library/gg328255.aspx) by [David Berry](https://github.com/6ix4our)
|
||||
@@ -695,8 +716,9 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](mockery/mockery.d.ts) [mockery](https://github.com/mfncooper/mockery) by [jt000](https://github.com/jt000)
|
||||
* [:link:](modernizr/modernizr.d.ts) [Modernizr](http://modernizr.com) by [Boris Yankov](https://github.com/borisyankov), [Theodore Brown](https://github.com/theodorejb)
|
||||
* [:link:](moment-timezone/moment-timezone.d.ts) [moment-timezone.js](http://momentjs.com/timezone) by [Michel Salib](https://github.com/michelsalib)
|
||||
* [:link:](moment/moment-node.d.ts) [Moment.js](https://github.com/timrwood/moment) by [Michael Lakerveld](https://github.com/Lakerfield), [Aaron King](https://github.com/kingdango), [Hiroki Horiuchi](https://github.com/horiuchi), [Dick van den Brink](https://github.com/DickvdBrink), [Adi Dahiya](https://github.com/adidahiya)
|
||||
* [:link:](moment/moment.d.ts) [Moment.js](https://github.com/timrwood/moment) by [Michael Lakerveld](https://github.com/Lakerfield), [Aaron King](https://github.com/kingdango), [Hiroki Horiuchi](https://github.com/horiuchi), [Dick van den Brink](https://github.com/DickvdBrink), [Adi Dahiya](https://github.com/adidahiya)
|
||||
* [:link:](moment-range/moment-range.d.ts) [Moment.js](https://github.com/gf3/moment-range) by [Bart van den Burg](https://github.com/Burgov), [Wilgert Velinga](https://github.com/wilgert)
|
||||
* [:link:](moment/moment.d.ts) [Moment.js](https://github.com/timrwood/moment) by [Michael Lakerveld](https://github.com/Lakerfield), [Aaron King](https://github.com/kingdango), [Hiroki Horiuchi](https://github.com/horiuchi), [Dick van den Brink](https://github.com/DickvdBrink), [Adi Dahiya](https://github.com/adidahiya), [Matt Brooks](https://github.com/EnableSoftware)
|
||||
* [:link:](moment/moment-node.d.ts) [Moment.js](https://github.com/timrwood/moment) by [Michael Lakerveld](https://github.com/Lakerfield), [Aaron King](https://github.com/kingdango), [Hiroki Horiuchi](https://github.com/horiuchi), [Dick van den Brink](https://github.com/DickvdBrink), [Adi Dahiya](https://github.com/adidahiya), [Matt Brooks](https://github.com/EnableSoftware)
|
||||
* [:link:](mongodb/mongodb.d.ts) [MongoDB](https://github.com/mongodb/node-mongodb-native) by [Boris Yankov](https://github.com/borisyankov)
|
||||
* [:link:](mongoose/mongoose.d.ts) [Mongoose](http://mongoosejs.com) by [horiuchi](https://github.com/horiuchi)
|
||||
* [:link:](mongoose-mock/mongoose-mock.d.ts) [mongoose-mock](https://github.com/JohanObrink/mongoose-mock) by [jt000](https://github.com/jt000)
|
||||
@@ -762,6 +784,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](nodemailer/nodemailer.d.ts) [Nodemailer](https://github.com/andris9/Nodemailer) by [Rogier Schouten](https://github.com/rogierschouten)
|
||||
* [:link:](nodemailer/nodemailer-types.d.ts) [Nodemailer](https://github.com/andris9/Nodemailer) by [Rogier Schouten](https://github.com/rogierschouten)
|
||||
* [:link:](nodemailer-direct-transport/nodemailer-direct-transport.d.ts) [nodemailer-direct-transport](https://github.com/andris9/nodemailer-direct-transport) by [Rogier Schouten](https://github.com/rogierschouten)
|
||||
* [:link:](nodemailer-pickup-transport/nodemailer-pickup-transport.d.ts) [nodemailer-pickup-transport](https://www.npmjs.com/package/nodemailer-pickup-transport) by [Peter Snider](https://github.com/psnider)
|
||||
* [:link:](nodemailer-smtp-pool/nodemailer-smtp-pool.d.ts) [nodemailer-smtp-pool](https://github.com/andris9/nodemailer-smtp-pool) by [Rogier Schouten](https://github.com/rogierschouten)
|
||||
* [:link:](nodemailer-smtp-transport/nodemailer-smtp-transport.d.ts) [nodemailer-smtp-transport](https://github.com/andris9/nodemailer-smtp-transport) by [Rogier Schouten](https://github.com/rogierschouten)
|
||||
* [:link:](nodeunit/nodeunit.d.ts) [nodeunit](https://github.com/caolan/nodeunit) by [Jeff Goddard](https://github.com/jedigo)
|
||||
@@ -787,12 +810,15 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](openlayers/openlayers.d.ts) [OpenLayers](http://openlayers.org) by [Wouter Goedhart](https://github.com/woutergd)
|
||||
* [:link:](opn/opn.d.ts) [opn](https://github.com/sindresorhus/opn) by [Shinnosuke Watanabe](https://github.com/shinnn)
|
||||
* [:link:](optimist/optimist.d.ts) [optimist](https://github.com/substack/node-optimist) by [Carlos Ballesteros Velasco](https://github.com/soywiz)
|
||||
* [:link:](owlcarousel/owlcarousel.d.ts) [OwlCarousel v.1.3.3](https://github.com/OwlFonk/OwlCarousel) by [Damian Piątkowski](https://github.com/dpiatkowski)
|
||||
* [:link:](packery/packery.d.ts) [Packery](http://packery.metafizzy.co) by [Piraveen Kamalathas from Kilix](https://github.com/piraveen)
|
||||
* [:link:](page/page.d.ts) [page](http://visionmedia.github.io/page.js) by [Alan Norbauer](http://alan.norbauer.com)
|
||||
* [:link:](papaparse/papaparse.d.ts) [PapaParse](https://github.com/mholt/PapaParse) by [Pedro Flemming](https://github.com/torpedro)
|
||||
* [:link:](parallel/parallel.d.ts) [parallel.js](http://adambom.github.io/parallel.js) by [Josh Baldwin](https://github.com/jbaldwin)
|
||||
* [:link:](param-case/param-case.d.ts) [param-case](https://github.com/blakeembrey/param-case) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
* [:link:](parse/parse.d.ts) [Parse](https://parse.com) by [Ullisen Media Group](http://ullisenmedia.com)
|
||||
* [:link:](parsimmon/parsimmon.d.ts) [Parsimmon](https://github.com/jneen/parsimmon) by [Bart van der Schoor](https://github.com/Bartvds)
|
||||
* [:link:](pascal-case/pascal-case.d.ts) [pascal-case](https://github.com/blakeembrey/pascal-case) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
* [:link:](passport/passport.d.ts) [Passport](http://passportjs.org) by [Horiuchi_H](https://github.com/horiuchi)
|
||||
* [:link:](passport-strategy/passport-strategy.d.ts) [Passport Strategy module](https://github.com/jaredhanson/passport-strategy) by [Lior Mualem](https://github.com/liorm)
|
||||
* [:link:](passport-twitter/passport-twitter.d.ts) [passport-facebook](https://github.com/jaredhanson/passport-facebook) by [James Roland Cabresos](https://github.com/staticfunction)
|
||||
@@ -800,9 +826,12 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](passport-facebook/passport-facebook.d.ts) [passport-facebook](https://github.com/jaredhanson/passport-facebook) by [James Roland Cabresos](https://github.com/staticfunction)
|
||||
* [:link:](passport-facebook-token/passport-facebook-token.d.ts) [passport-facebook-token](https://github.com/drudge/passport-facebook-token) by [Ray Martone](https://github.com/rmartone)
|
||||
* [:link:](passport-local/passport-local.d.ts) [passport-local](https://github.com/jaredhanson/passport-local) by [Maxime LUCE](https://github.com/SomaticIT)
|
||||
* [:link:](path-case/path-case.d.ts) [path-case](https://github.com/blakeembrey/path-case) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
* [:link:](path-exists/path-exists.d.ts) [path-exists](https://github.com/sindresorhus/path-exists) by [Shogo Iwano](https://github.com/shiwano)
|
||||
* [:link:](path-to-regexp/path-to-regexp.d.ts) [path-to-regexp](https://github.com/pillarjs/path-to-regexp) by [xica](https://github.com/xica)
|
||||
* [:link:](pathjs/pathjs.d.ts) [Pathjs](https://github.com/mtrpcic/pathjs) by [Lokesh Peta](https://github.com/lokeshpeta)
|
||||
* [:link:](pathwatcher/pathwatcher.d.ts) [pathwatcher](https://github.com/atom/node-pathwatcher) by [vvakame](https://github.com/vvakame)
|
||||
* [:link:](PayPal-Cordova-Plugin/PayPal-Cordova-Plugin.d.ts) [PayPal-Cordova-Plugin](https://github.com/paypal/PayPal-Cordova-Plugin) by [Justin Unterreiner](https://github.com/Justin-Credible)
|
||||
* [:link:](pdf/pdf.d.ts) [PDF.js](https://github.com/mozilla/pdf.js) by [Josh Baldwin](https://github.com/jbaldwin)
|
||||
* [:link:](pdfkit/pdfkit.d.ts) [Pdfkit](http://pdfkit.org) by [Eric Hillah](https://github.com/erichillah)
|
||||
* [:link:](peerjs/peerjs.d.ts) [PeerJS](http://peerjs.com) by [Toshiya Nakakura](https://github.com/nakakura)
|
||||
@@ -831,6 +860,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](polyline/polyline.d.ts) [Polyline](https://github.com/mapbox/polyline) by [Arseniy Maximov](https://github.com/Kern0)
|
||||
* [:link:](polymer/polymer.d.ts) [polymer](https://github.com/Polymer/polymer) by [Louis Grignon](https://github.com/lgrignon), [Suguru Inatomi](https://github.com/laco0416)
|
||||
* [:link:](popcorn/popcorn.d.ts) [Popcorn](https://github.com/mozilla/popcorn-js) by [grapswiz](https://github.com/grapswiz)
|
||||
* [:link:](postal/postal.d.ts) [Postal](https://github.com/postaljs/postal.js) by [Lokesh Peta](https://github.com/lokeshpeta), [Paul Jolly](https://github.com/myitcv)
|
||||
* [:link:](pouchDB/pouch.d.ts) [Pouch](http://pouchdb.com) by [Bill Sears](https://github.com/MrBigDog2U)
|
||||
* [:link:](power-assert/power-assert.d.ts) [power-assert](https://github.com/twada/power-assert) by [vvakame](https://github.com/vvakame)
|
||||
* [:link:](power-assert-formatter/power-assert-formatter.d.ts) [power-assert-formatter](https://github.com/twada/power-assert-formatter) by [vvakame](https://github.com/vvakame)
|
||||
@@ -862,6 +892,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](raygun4js/raygun4js.d.ts) [raygun4js](https://github.com/MindscapeHQ/raygun4js) by [Brian Surowiec](https://github.com/xt0rted)
|
||||
* [:link:](react/react.d.ts) [React (external module)](http://facebook.github.io/react) by [Asana](https://asana.com), [AssureSign](http://www.assuresign.com), [Microsoft](https://microsoft.com)
|
||||
* [:link:](react/react-global.d.ts) [React (internal module)](http://facebook.github.io/react) by [Asana](https://asana.com), [AssureSign](http://www.assuresign.com), [Microsoft](https://microsoft.com)
|
||||
* [:link:](react-dnd/react-dnd.d.ts) [React DnD](https://github.com/gaearon/react-dnd) by [Asana](https://asana.com)
|
||||
* [:link:](react-router/react-router.d.ts) [React Router](https://github.com/rackt/react-router) by [Yuichi Murata](https://github.com/mrk21), [Václav Ostrožlík](https://github.com/vasek17)
|
||||
* [:link:](react/react-addons.d.ts) [ReactWithAddons (external module)](http://facebook.github.io/react) by [Asana](https://asana.com), [AssureSign](http://www.assuresign.com)
|
||||
* [:link:](react/react-addons-global.d.ts) [ReactWithAddons (internal module)](http://facebook.github.io/react) by [Asana](https://asana.com), [AssureSign](http://www.assuresign.com)
|
||||
@@ -875,6 +906,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](request/request.d.ts) [request](https://github.com/mikeal/request) by [Carlos Ballesteros Velasco](https://github.com/soywiz), [bonnici](https://github.com/bonnici), [Bart van der Schoor](https://github.com/Bartvds)
|
||||
* [:link:](request-promise/request-promise.d.ts) [request-promise](https://www.npmjs.com/package/request-promise) by [Christopher Glantschnig](https://github.com/cglantschnig)
|
||||
* [:link:](requirejs/require.d.ts) [RequireJS](http://requirejs.org) by [Josh Baldwin](https://github.com/jbaldwin)
|
||||
* [:link:](resemblejs/resemblejs.d.ts) [Resemble.js](http://huddle.github.io/Resemble.js) by [Tim Perry](https://github.com/pimterry)
|
||||
* [:link:](response-time/response-time.d.ts) [response-time](https://github.com/expressjs/response-time) by [Uros Smolnik](https://github.com/urossmolnik)
|
||||
* [:link:](rest/rest.d.ts) [rest.js](https://github.com/cujojs/rest) by [Wim Looman](https://github.com/Nemo157)
|
||||
* [:link:](restangular/restangular.d.ts) [Restangular](https://github.com/mgonto/restangular) by [Boris Yankov](https://github.com/borisyankov)
|
||||
@@ -916,11 +948,14 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](selenium-webdriver/selenium-webdriver.d.ts) [Selenium WebDriverJS](https://code.google.com/p/selenium) by [Bill Armstrong](https://github.com/BillArmstrong)
|
||||
* [:link:](semver/semver.d.ts) [semver](https://github.com/isaacs/node-semver) by [Bart van der Schoor](https://github.com/Bartvds)
|
||||
* [:link:](sendgrid/sendgrid.d.ts) [sendgrid](https://github.com/sendgrid/sendgrid-nodejs) by [Maxime LUCE](https://github.com/SomaticIT)
|
||||
* [:link:](sentence-case/sentence-case.d.ts) [sentence-case](https://github.com/blakeembrey/sentence-case) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
* [:link:](sequelize/sequelize.d.ts) [Sequelize 2.0.0 dev13](http://sequelizejs.com) by [samuelneff](https://github.com/samuelneff), [Peter Harris](https://github.com/codeanimal)
|
||||
* [:link:](sequelize-fixtures/sequelize-fixtures.d.ts) [Sequelize-Fixtures](https://github.com/domasx2/sequelize-fixtures) by [Christian Schwarz](https://github.com/cschwarz)
|
||||
* [:link:](on-headers/on-headers.d.ts) [serve-favicon](https://github.com/jshttp/on-headers) by [John Jeffery](https://github.com/jjeffery)
|
||||
* [:link:](serve-favicon/serve-favicon.d.ts) [serve-favicon](https://github.com/expressjs/serve-favicon) by [Uros Smolnik](https://github.com/urossmolnik)
|
||||
* [:link:](serve-static/serve-static.d.ts) [serve-static](https://github.com/expressjs/serve-static) by [Uros Smolnik](https://github.com/urossmolnik)
|
||||
* [:link:](sharedworker/SharedWorker.d.ts) [SharedWorker](http://www.w3.org/TR/workers) by [Toshiya Nakakura](https://github.com/nakakura)
|
||||
* [:link:](sharepoint/SharePoint.d.ts) [SharePoint 2010 and 2013](http://sptypescript.codeplex.com) by [Stanislav Vyshchepan](http://blog.gandjustas.ru), [Andrey Markeev](http://markeev.com)
|
||||
* [:link:](shelljs/shelljs.d.ts) [ShellJS](http://shelljs.org) by [Niklas Mollenhauer](https://github.com/nikeee)
|
||||
* [:link:](shortid/shortid.d.ts) [shortid](https://github.com/dylang/shortid) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
* [:link:](should-promised/should-promised.d.ts) [should-promised](https://github.com/shouldjs/promised) by [Yaroslav Admin](https://github.com/devoto13)
|
||||
@@ -934,6 +969,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](jquery.simplemodal/jquery.simplemodal.d.ts) [SimpleModal](http://www.ericmmartin.com/projects/simplemodal) by [Friedrich von Never](https://github.com/ForNeVeR)
|
||||
* [:link:](sinon/sinon.d.ts) [Sinon](http://sinonjs.org) by [William Sears](https://github.com/mrbigdog2u)
|
||||
* [:link:](sinon-chai/sinon-chai.d.ts) [sinon-chai](https://github.com/domenic/sinon-chai) by [Kazi Manzur Rashid](https://github.com/kazimanzurrashid), [Jed Mao](https://github.com/jedmao)
|
||||
* [:link:](sinon-chrome/sinon-chrome.d.ts) [Sinon-Chrome](https://github.com/vitalets/sinon-chrome) by [Tim Perry](https://github.com/pimterry)
|
||||
* [:link:](sipml/sipml.d.ts) [SIPml5](http://sipml5.org) by [A. Groenenboom](https://github.com/chookies)
|
||||
* [:link:](sjcl/sjcl.d.ts) [sjcl](http://crypto.stanford.edu/sjcl) by [Eugene Chernyshov](https://github.com/Evgenus)
|
||||
* [:link:](skyway/skyway.d.ts) [SkyWay](http://nttcom.github.io/skyway) by [Toshiya Nakakura](https://github.com/nakakura)
|
||||
@@ -942,6 +978,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](slickgrid/slick.headerbuttons.d.ts) [SlickGrid HeaderButtons Plugin](https://github.com/mleibman/SlickGrid) by [Derek Cicerone](https://github.com/derekcicerone)
|
||||
* [:link:](slickgrid/slick.rowselectionmodel.d.ts) [SlickGrid RowSelectionModel Plugin](https://github.com/mleibman/SlickGrid) by [Derek Cicerone](https://github.com/derekcicerone)
|
||||
* [:link:](smoothie/smoothie.d.ts) [Smoothie Charts](https://github.com/joewalnes/smoothie) by [Drew Noakes](https://drewnoakes.com), [Mike H. Hawley](https://github.com/mikehhawley)
|
||||
* [:link:](snake-case/snake-case.d.ts) [snake-case](https://github.com/blakeembrey/snake-case) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
* [:link:](snapsvg/snapsvg.d.ts) [Snap-SVG](https://github.com/adobe-webplatform/Snap.svg) by [Lars Klein](https://github.com/lhk)
|
||||
* [:link:](socket.io/socket.io.d.ts) [socket.io](http://socket.io) by [PROGRE](https://github.com/progre), [Damian Connolly](https://github.com/divillysausages)
|
||||
* [:link:](socket.io-client/socket.io-client.d.ts) [socket.io-client](http://socket.io) by [PROGRE](https://github.com/progre), [Damian Connolly](https://github.com/divillysausages)
|
||||
@@ -956,7 +993,6 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](split/split.d.ts) [split](https://github.com/dominictarr/split) by [Marcin Porębski](https://github.com/marcinporebski)
|
||||
* [:link:](sprintf-js/sprintf-js.d.ts) [sprintf-js](https://www.npmjs.com/package/sprintf-js) by [Jason Swearingen](https://jasonswearingen.github.io)
|
||||
* [:link:](sprintf/sprintf.d.ts) [sprintff](https://github.com/maritz/node-sprintff) by [Carlos Ballesteros Velasco](https://github.com/soywiz)
|
||||
* [:link:](sharepoint/SharePoint.d.ts) [sptypescript](http://sptypescript.codeplex.com) by [Stanislav Vyshchepan](http://gandjustas.blogspot.ru), [Andrey Markeev](http://markeev.com)
|
||||
* [:link:](sqlite3/sqlite3.d.ts) [sqlite3](https://github.com/mapbox/node-sqlite3) by [Nick Malaguti](https://github.com/nmalaguti)
|
||||
* [:link:](squirejs/squirejs.d.ts) [Squire](https://github.com/iammerrick/Squire.js) by [Bradley Ayers](https://github.com/bradleyayers)
|
||||
* [:link:](stack-mapper/stack-mapper.d.ts) [stack-mapper](https://github.com/thlorenz/stack-mapper) by [Rogier Schouten](https://github.com/rogierschouten)
|
||||
@@ -983,6 +1019,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](svg2png/svg2png.d.ts) [svg2png node package](https://github.com/domenic/svg2png) by [hans windhoff](https://github.com/hansrwindhoff)
|
||||
* [:link:](svgjs.draggable/svgjs.draggable.d.ts) [svgjs.draggable](http://www.svgjs.com) by [Luigi Trabacchin](https://github.com/LiFeleSs)
|
||||
* [:link:](swag/swag.d.ts) [swag](https://github.com/elving/swag) by [Shogo Iwano](https://github.com/shiwano)
|
||||
* [:link:](swap-case/swap-case.d.ts) [swap-case](https://github.com/blakeembrey/swap-case) by [Sam Saint-Pettersen](https://github.com/stpettersens)
|
||||
* [:link:](sweetalert/sweetalert.d.ts) [SweetAlert](https://github.com/t4t5/sweetalert) by [Markus Peloso](https://github.com/ToastHawaii)
|
||||
* [:link:](swfobject/swfobject.d.ts) [swfobject](https://code.google.com/p/swfobject) by [rou](https://github.com/rou)
|
||||
* [:link:](swig/swig.d.ts) [swig](http://github.com/paularmstrong/swig) by [Peter Harris](https://github.com/CodeAnimal), [Carlos Ballesteros Velasco](https://github.com/soywiz)
|
||||
@@ -996,6 +1033,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](tape/tape.d.ts) [tape](https://github.com/substack/tape) by [Bart van der Schoor](https://github.com/Bartvds)
|
||||
* [:link:](tar/tar.d.ts) [tar](https://github.com/npm/node-tar) by [Maxime LUCE](https://github.com/SomaticIT)
|
||||
* [:link:](tcomb/tcomb.d.ts) [tcomb](http://gcanti.github.io/tcomb/guide/index.html) by [Hans Windhoff](https://github.com/hansrwindhoff)
|
||||
* [:link:](tea-merge/tea-merge.d.ts) [tea-merge](https://github.com/qualiancy/tea-merge) by [Mihhail Lapushkin](https://github.com/mihhail-lapushkin)
|
||||
* [:link:](tedious/tedious.d.ts) [tedious](https://pekim.github.io/tedious) by [Rogier Schouten](https://github.com/rogierschouten)
|
||||
* [:link:](tedious-connection-pool/tedious-connection-pool.d.ts) [tedious-connection-pool](https://github.com/pekim/tedious-connection-pool) by [Cyprien Autexier](https://github.com/sandorfr)
|
||||
* [:link:](teechart/teechart.d.ts) [TeeChart](http://www.steema.com) by [Steema Software](https://steema.com)
|
||||
@@ -1015,9 +1053,11 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](threejs/three-renderpass.d.ts) [three.js (RenderPass.js)](https://github.com/mrdoob/three.js/blob/r68/examples/js/postprocessing/RenderPass.js) by [Satoru Kimura](https://github.com/gyohk)
|
||||
* [:link:](threejs/three-shaderpass.d.ts) [three.js (ShaderPass.js)](https://github.com/mrdoob/three.js/blob/r68/examples/js/postprocessing/ShaderPass.js) by [Satoru Kimura](https://github.com/gyohk)
|
||||
* [:link:](threejs/three-trackballcontrols.d.ts) [three.js (TrackballControls.js)](https://github.com/mrdoob/three.js/blob/master/examples/js/controls/TrackballControls.js) by [Satoru Kimura](https://github.com/gyohk)
|
||||
* [:link:](threejs/three-transformcontrols.d.ts) [three.js (TransformControls.js)](https://github.com/mrdoob/three.js/blob/master/examples/js/controls/TransformControls.js) by [Stefan Profanter](https://github.com/Pro)
|
||||
* [:link:](threejs/three-vrcontrols.d.ts) [three.js (VRControls.js)](https://github.com/mrdoob/three.js/blob/master/examples/js/controls/VRControls.js) by [Toshiya Nakakura](https://github.com/nakakura)
|
||||
* [:link:](threejs/three-vreffect.d.ts) [three.js (VREffect.js)](https://github.com/mrdoob/three.js/blob/master/examples/js/effects/VREffect.js) by [Toshiya Nakakura](https://github.com/nakakura)
|
||||
* [:link:](threejs/three.d.ts) [three.js r71](http://mrdoob.github.com/three.js) by [Kon](http://phyzkit.net), [Satoru Kimura](https://github.com/gyohk)
|
||||
* [:link:](thrift/thrift.d.ts) [thrift](https://www.npmjs.com/package/thrift) by [Zachary Collins](https://github.com/corps)
|
||||
* [:link:](through/through.d.ts) [through](https://github.com/dominictarr/through) by [Andrew Gaspar](https://github.com/AndrewGaspar)
|
||||
* [:link:](through2/through2.d.ts) [through2 v](https://github.com/rvagg/through2) by [Bart van der Schoor](https://github.com/Bartvds), [jedmao](https://github.com/jedmao)
|
||||
* [:link:](timelinejs/timelinejs.d.ts) [timelinejs](https://github.com/NUKnightLab/TimelineJS) by [Roland Zwaga](https://github.com/rolandzwaga)
|
||||
@@ -1032,6 +1072,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](toastr/toastr.d.ts) [Toastr](https://github.com/CodeSeven/toastr) by [Boris Yankov](https://github.com/borisyankov)
|
||||
* [:link:](sencha_touch/SenchaTouch.d.ts) [Touch](http://www.sencha.com/products/touch) by [Brian Kotek](https://github.com/brian428)
|
||||
* [:link:](traceback/traceback.d.ts) [Traceback](http://github.com/iriscouch/traceback) by [Michael Zabka](https://github.com/misak113)
|
||||
* [:link:](traverson/traverson.d.ts) [Traverson](https://github.com/basti1302/traverson) by [Marcin Porębski](https://github.com/marcinporebski)
|
||||
* [:link:](trunk8/trunk8.d.ts) [trunk8](https://github.com/rviscomi/trunk8) by [Blake Niemyjski](https://github.com/niemyjski)
|
||||
* [:link:](tsmonad/tsmonad.d.ts) [TsMonad](https://github.com/cbowdon/TsMonad) by [Chris Bowdon](https://github.com/cbowdon)
|
||||
* [:link:](tspromise/tspromise.d.ts) [tspromise](https://github.com/soywiz/tspromise) by [Carlos Ballesteros Velasco](https://github.com/soywiz)
|
||||
@@ -1064,12 +1105,14 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](js-url/js-url.d.ts) [url](https://github.com/websanova/js-url) by [MIZUNE Pine](https://github.com/pine613)
|
||||
* [:link:](urlrouter/urlrouter.d.ts) [urlrouter](https://github.com/fengmk2/urlrouter) by [soywiz](https://github.com/soywiz)
|
||||
* [:link:](urlsafe-base64/urlsafe-base64.d.ts) [urlsafe-base64](https://github.com/RGBboy/urlsafe-base64) by [Tanguy Krotoff](https://github.com/tkrotoff)
|
||||
* [:link:](usage/usage.d.ts) [usage](https://github.com/arunoda/node-usage) by [Pascal Vomhoff](https://github.com/pvomhoff)
|
||||
* [:link:](UUID/UUID.d.ts) [UUID.js core](https://github.com/LiosK/UUID.js) by [Jason Jarrett](https://github.com/staxmanade)
|
||||
* [:link:](valerie/valerie.d.ts) [valerie](https://github.com/davewatts/valerie) by [Howard Richards](https://github.com/conficient)
|
||||
* [:link:](validator/validator.d.ts) [validator.js](https://github.com/chriso/validator.js) by [tgfjt](https://github.com/tgfjt)
|
||||
* [:link:](vega/vega.d.ts) [Vega](http://trifacta.github.io/vega) by [Tom Crockett](http://github.com/pelotom)
|
||||
* [:link:](velocity-animate/velocity-animate.d.ts) [Velocity](http://velocityjs.org) by [Greg Smith](https://github.com/smrq)
|
||||
* [:link:](vex-js/vex-js.d.ts) [Vex](https://github.com/HubSpot/vex) by [Greg Cohan](https://github.com/gdcohan)
|
||||
* [:link:](vexflow/vexflow.d.ts) [VexFlow](http://vexflow.com) by [Roman Quiring](https://github.com/rquiring)
|
||||
* [:link:](victor/victor.d.ts) [Victor.js](http://victorjs.org) by [Ivane Gegia](https://twitter.com/ivanegegia)
|
||||
* [:link:](videojs/videojs.d.ts) [Video.js](https://github.com/zencoder/video-js) by [Vincent Bortone](https://github.com/vbortone)
|
||||
* [:link:](vimeo/froogaloop.d.ts) [Vimeo](http://developer.vimeo.com/player/js-api) by [Daz Wilkin](https://github.com/DazWilkin)
|
||||
@@ -1125,7 +1168,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam
|
||||
* [:link:](node_zeromq/zmq.d.ts) [ZeroMQ Node](https://github.com/JustinTulloss/zeromq.node) by [Dave McKeown](http://github.com/davemckeown)
|
||||
* [:link:](zip.js/zip.js.d.ts) [zip.js 2.x](https://github.com/gildas-lormeau/zip.js) by [Louis Grignon](https://github.com/lgrignon)
|
||||
* [:link:](scroller/easyscroller.d.ts) [Zynga EasyScroller](https://github.com/zynga/scroller) by [Boris Yankov](https://github.com/borisyankov)
|
||||
* [:link:](zynga-scroller/zynga-scroller.d.ts) [Zynga Scroller](http://zynga.github.com/scroller) by [Marcelo Haskell Camargo](https://github.com/haskellcamargo)
|
||||
* [:link:](scroller/scroller.d.ts) [Zynga Scroller](https://github.com/zynga/scroller) by [Boris Yankov](https://github.com/borisyankov)
|
||||
* [:link:](zynga-scroller/zynga-scroller.d.ts) [Zynga Scroller](http://zynga.github.com/scroller) by [Marcelo Haskell Camargo](https://github.com/haskellcamargo)
|
||||
* [:link:](viewporter/viewporter.d.ts) [Zynga Viewporter](https://github.com/zynga/viewporter) by [Boris Yankov](https://github.com/borisyankov)
|
||||
|
||||
|
||||
@@ -0,0 +1,115 @@
|
||||
|
||||
/// <reference path="PayPal-Cordova-Plugin.d.ts"/>
|
||||
|
||||
var item: PayPalItem;
|
||||
item = new PayPalItem("name", 10, "25.00", "USD");
|
||||
item = new PayPalItem("name", 10, "25.00", "USD", null);
|
||||
item = new PayPalItem("name", 10, "25.00", "USD", "SKU_ID");
|
||||
|
||||
var item_name: string = item.name;
|
||||
var item_quantity: number = item.quantity;
|
||||
var item_price: string = item.price;
|
||||
var item_currency: string = item.currency;
|
||||
var item_sku: string = item.sku;
|
||||
|
||||
|
||||
|
||||
var paymentDetails: PayPalPaymentDetails;
|
||||
paymentDetails = new PayPalPaymentDetails("10.50", "2.50", "1.25");
|
||||
|
||||
var paymentDetails_subtotal: string = paymentDetails.subtotal;
|
||||
var paymentDetails_shipping: string = paymentDetails.shipping;
|
||||
var paymentDetails_tax: string = paymentDetails.tax;
|
||||
|
||||
|
||||
|
||||
var shippingAddress: PayPalShippingAddress;
|
||||
shippingAddress = new PayPalShippingAddress("name", "line1", "line2", "city", "state", "postalCode", "countryCode");
|
||||
|
||||
var shippingAddress_recipientName: string = shippingAddress.recipientName;
|
||||
var shippingAddress_line1: string = shippingAddress.line1;
|
||||
var shippingAddress_line2: string = shippingAddress.line2;
|
||||
var shippingAddress_city: string = shippingAddress.city;
|
||||
var shippingAddress_state: string = shippingAddress.state;
|
||||
var shippingAddress_postalCode: string = shippingAddress.postalCode;
|
||||
var shippingAddress_countryCode: string = shippingAddress.countryCode;
|
||||
|
||||
|
||||
|
||||
var payment: PayPalPayment;
|
||||
payment = new PayPalPayment("10.00", "USD", "description", "Auth");
|
||||
payment = new PayPalPayment("10.00", "USD", "description", "Auth", paymentDetails);
|
||||
|
||||
var payment_amount: string = payment.amount;
|
||||
var payment_currency: string = payment.currency;
|
||||
var payment_shortDescription: string = payment.shortDescription;
|
||||
var payment_intent: string = payment.intent;
|
||||
var payment_details: PayPalPaymentDetails = payment.details;
|
||||
var payment_invoiceNumber: string = payment.invoiceNumber;
|
||||
var payment_custom: string = payment.custom;
|
||||
var payment_softDescriptor: string = payment.softDescriptor;
|
||||
var payment_bnCode: string = payment.bnCode;
|
||||
var payment_items: PayPalItem[] = [item, item, item];
|
||||
var payment_shippingAddress: PayPalShippingAddress = shippingAddress;
|
||||
|
||||
|
||||
|
||||
var configOptions: PayPalConfigurationOptions = {
|
||||
defaultUserEmail: "email",
|
||||
defaultUserPhoneCountryCode: "countryCode",
|
||||
defaultUserPhoneNumber: "phoneNumber",
|
||||
merchantName: "merchantName",
|
||||
merchantPrivacyPolicyURL: "merchantPrivacyPolicyURL",
|
||||
merchantUserAgreementURL: "merchantUserAgreementURL",
|
||||
acceptCreditCards: true,
|
||||
payPalShippingAddressOption: 10,
|
||||
rememberUser: true,
|
||||
languageOrLocale: "languageOrLocal",
|
||||
disableBlurWhenBackgrounding: true,
|
||||
presentingInPopover: true,
|
||||
forceDefaultsInSandbox: true,
|
||||
sandboxUserPassword: "sandboxUserPassword",
|
||||
sandboxUserPin: "sandboxUserPin"
|
||||
};
|
||||
|
||||
|
||||
|
||||
var config: PayPalConfiguration;
|
||||
config = new PayPalConfiguration();
|
||||
config = new PayPalConfiguration(null);
|
||||
config = new PayPalConfiguration(configOptions);
|
||||
|
||||
var config_defaultUserEmail: string = config.defaultUserEmail;
|
||||
var config_defaultUserPhoneCountryCode: string = config.defaultUserPhoneCountryCode;
|
||||
var config_defaultUserPhoneNumber: string = config.defaultUserPhoneNumber;
|
||||
var config_merchantName: string = config.merchantName;
|
||||
var config_merchantPrivacyPolicyURL: string = config.merchantPrivacyPolicyURL;
|
||||
var config_merchantUserAgreementURL: string = config.merchantUserAgreementURL;
|
||||
var config_acceptCreditCards: boolean = config.acceptCreditCards;
|
||||
var config_payPalShippingAddressOption: number = config.payPalShippingAddressOption;
|
||||
var config_rememberUser: boolean = config.rememberUser;
|
||||
var config_languageOrLocale: string = config.languageOrLocale;
|
||||
var config_disableBlurWhenBackgrounding: boolean = config.disableBlurWhenBackgrounding;
|
||||
var config_presentingInPopover: boolean = config.presentingInPopover;
|
||||
var config_forceDefaultsInSandbox: boolean = config.forceDefaultsInSandbox;
|
||||
var config_sandboxUserPasword: string = config.sandboxUserPassword;
|
||||
var config_sandboxUserPin: string = config.sandboxUserPin;
|
||||
|
||||
|
||||
|
||||
var clientIds: PayPalCordovaPlugin.PayPalClientIds = {
|
||||
PayPalEnvironmentProduction: "",
|
||||
PayPalEnvironmentSandbox: ""
|
||||
};
|
||||
|
||||
|
||||
|
||||
var apiModule: PayPalCordovaPlugin.PayPalMobileStatic = PayPalMobile;
|
||||
apiModule.version((result: string) => {});
|
||||
apiModule.init(clientIds, () => {});
|
||||
apiModule.prepareToRender("environment", config, () => {});
|
||||
apiModule.renderSinglePaymentUI(payment, (result: any) => {}, (cancelReason: string) => {});
|
||||
apiModule.applicationCorrelationIDForEnvironment("environment", (applicationCorrelationId: string) => {});
|
||||
apiModule.clientMetadataID((clientMetadataId: string) => {});
|
||||
apiModule.renderFuturePaymentUI((result: any) => {}, (cancelReason: string) => {});
|
||||
apiModule.renderProfileSharingUI(["openid", "profile", "email"], (result: any) => {}, (cancelReason: string) => {});
|
||||
+615
@@ -0,0 +1,615 @@
|
||||
// Type definitions for PayPal-Cordova-Plugin 3.1.10
|
||||
// Project: https://github.com/paypal/PayPal-Cordova-Plugin
|
||||
// Definitions by: Justin Unterreiner <https://github.com/Justin-Credible>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
//#region paypal-mobile-js-helper.js
|
||||
|
||||
/**
|
||||
* The PayPalItem class defines an optional itemization for a payment.
|
||||
*
|
||||
* @see https://developer.paypal.com/docs/api/#item-object for more details.
|
||||
*/
|
||||
declare class PayPalItem {
|
||||
|
||||
/**
|
||||
* @param name Name of the item. 127 characters max.
|
||||
* @param quantity Number of units. 10 characters max.
|
||||
* @param price Unit price for this item 10 characters max.
|
||||
* May be negative for "coupon" etc.
|
||||
* @param currency ISO standard currency code.
|
||||
* @param sku The stock keeping unit for this item. 50 characters max (optional).
|
||||
*/
|
||||
constructor(name: string, quantity: number, price: string, currency: string, sku?: string);
|
||||
|
||||
/**
|
||||
* Name of the item. 127 characters max.
|
||||
*/
|
||||
name: string;
|
||||
|
||||
/**
|
||||
* Number of units. 10 characters max.
|
||||
*/
|
||||
quantity: number;
|
||||
|
||||
/**
|
||||
* Unit price for this item 10 characters max.
|
||||
* May be negative for "coupon" etc.
|
||||
*/
|
||||
price: string;
|
||||
|
||||
/**
|
||||
* ISO standard currency code.
|
||||
*/
|
||||
currency: string;
|
||||
|
||||
/**
|
||||
* The stock keeping unit for this item. 50 characters max (optional).
|
||||
*/
|
||||
sku: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* The PayPalPaymentDetails class defines optional amount details.
|
||||
*
|
||||
* @see https://developer.paypal.com/webapps/developer/docs/api/#details-object for more details.
|
||||
*/
|
||||
declare class PayPalPaymentDetails {
|
||||
|
||||
/**
|
||||
* @param subtotal Sub-total (amount) of items being paid for. 10 characters max with support for 2 decimal places.
|
||||
* @param shipping Amount charged for shipping. 10 characters max with support for 2 decimal places.
|
||||
* @param tax Amount charged for tax. 10 characters max with support for 2 decimal places.
|
||||
*/
|
||||
constructor(subtotal: string, shipping: string, tax: string);
|
||||
|
||||
/**
|
||||
* Sub-total (amount) of items being paid for. 10 characters max with support for 2 decimal places.
|
||||
*/
|
||||
subtotal: string;
|
||||
|
||||
/**
|
||||
* Amount charged for shipping. 10 characters max with support for 2 decimal places.
|
||||
*/
|
||||
shipping: string;
|
||||
|
||||
/**
|
||||
* Amount charged for tax. 10 characters max with support for 2 decimal places.
|
||||
*/
|
||||
tax: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* Convenience constructor. Returns a PayPalPayment with the specified amount, currency code, and short description.
|
||||
*/
|
||||
declare class PayPalPayment {
|
||||
|
||||
/**
|
||||
* @param amount The amount of the payment.
|
||||
* @param currencyCode The ISO 4217 currency for the payment.
|
||||
* @param shortDescription A short descripton of the payment.
|
||||
* @param intent • "Sale" for an immediate payment.
|
||||
* • "Auth" for payment authorization only, to be captured separately at a later time.
|
||||
* • "Order" for taking an order, with authorization and capture to be done separately at a later time.
|
||||
* @param details PayPalPaymentDetails object (optional).
|
||||
*/
|
||||
constructor(amount: string, currency: string, shortDescription: string, intent: string, details?: PayPalPaymentDetails);
|
||||
|
||||
/**
|
||||
* The amount of the payment.
|
||||
*/
|
||||
amount: string;
|
||||
|
||||
/**
|
||||
* The ISO 4217 currency for the payment.
|
||||
*/
|
||||
currency: string;
|
||||
|
||||
/**
|
||||
* A short descripton of the payment.
|
||||
*/
|
||||
shortDescription: string;
|
||||
|
||||
/**
|
||||
* • "Sale" for an immediate payment.
|
||||
* • "Auth" for payment authorization only, to be captured separately at a later time.
|
||||
* • "Order" for taking an order, with authorization and capture to be done separately at a later time.
|
||||
*/
|
||||
intent: string;
|
||||
|
||||
/**
|
||||
* PayPalPaymentDetails object (optional).
|
||||
*/
|
||||
details: PayPalPaymentDetails;
|
||||
|
||||
/**
|
||||
* Optional invoice number, for your tracking purposes. (up to 256 characters).
|
||||
*/
|
||||
invoiceNumber: string;
|
||||
|
||||
/**
|
||||
* Optional text, for your tracking purposes. (up to 256 characters).
|
||||
*/
|
||||
custom: string;
|
||||
|
||||
/**
|
||||
* Optional text which will appear on the customer's credit card statement. (up to 22 characters).
|
||||
*/
|
||||
softDescriptor: string;
|
||||
|
||||
/**
|
||||
* Optional Build Notation code ("BN code"), obtained from partnerprogram@paypal.com, for your tracking purposes.
|
||||
*/
|
||||
bnCode: string;
|
||||
|
||||
/**
|
||||
* Optional array of PayPalItem objects.
|
||||
* @see PayPalItem
|
||||
* @note If you provide one or more items, be sure that the various prices correctly sum to the payment `amount` or to `paymentDetails.subtotal`.
|
||||
*/
|
||||
items: PayPalItem[];
|
||||
|
||||
/**
|
||||
* Optional customer shipping address, if your app wishes to provide this to the SDK.
|
||||
* @note make sure to set `payPalShippingAddressOption` in PayPalConfiguration to 1 or 3.
|
||||
*/
|
||||
shippingAddress: PayPalShippingAddress;
|
||||
}
|
||||
|
||||
declare class PayPalShippingAddress {
|
||||
|
||||
/**
|
||||
* @param recipientName Name of the recipient at this address. 50 characters max.
|
||||
* @param line1 Line 1 of the address (e.g., Number, street, etc). 100 characters max.
|
||||
* @param line2 Line 2 of the address (e.g., Suite, apt #, etc). 100 characters max. Optional.
|
||||
* @param city City name. 50 characters max.
|
||||
* @param state 2-letter code for US states, and the equivalent for other countries. 100 characters max. Required in certain countries.
|
||||
* @param postalCode ZIP code or equivalent is usually required for countries that have them. 20 characters max. Required in certain countries.
|
||||
* @param countryCode 2-letter country code. 2 characters max.
|
||||
*/
|
||||
constructor(recipientName: string, line1: string, line2: string, city: string, state: string, postalCode: string, countryCode: string);
|
||||
|
||||
/**
|
||||
* Name of the recipient at this address. 50 characters max.
|
||||
*/
|
||||
recipientName: string;
|
||||
|
||||
/**
|
||||
* Line 1 of the address (e.g., Number, street, etc). 100 characters max.
|
||||
*/
|
||||
line1: string;
|
||||
|
||||
/**
|
||||
* Line 2 of the address (e.g., Suite, apt #, etc). 100 characters max. Optional.
|
||||
*/
|
||||
line2: string;
|
||||
|
||||
/**
|
||||
* City name. 50 characters max.
|
||||
*/
|
||||
city: string;
|
||||
|
||||
/**
|
||||
* 2-letter code for US states, and the equivalent for other countries. 100 characters max. Required in certain countries.
|
||||
*/
|
||||
state: string;
|
||||
|
||||
/**
|
||||
* ZIP code or equivalent is usually required for countries that have them. 20 characters max. Required in certain countries.
|
||||
*/
|
||||
postalCode: string;
|
||||
|
||||
/**
|
||||
* 2-letter country code. 2 characters max.
|
||||
*/
|
||||
countryCode: string;
|
||||
}
|
||||
|
||||
declare class PayPalConfiguration {
|
||||
|
||||
/**
|
||||
* @param options A set of options to use. Any options not specified will assume default values.
|
||||
*/
|
||||
constructor(options?: PayPalConfigurationOptions);
|
||||
|
||||
/**
|
||||
* Will be overridden by email used in most recent PayPal login.
|
||||
*/
|
||||
defaultUserEmail: string;
|
||||
|
||||
/**
|
||||
* Will be overridden by phone country code used in most recent PayPal login
|
||||
*/
|
||||
defaultUserPhoneCountryCode: string;
|
||||
|
||||
/**
|
||||
* Will be overridden by phone number used in most recent PayPal login.
|
||||
* @note If you set defaultUserPhoneNumber, be sure to also set defaultUserPhoneCountryCode.
|
||||
*/
|
||||
defaultUserPhoneNumber: string;
|
||||
|
||||
/**
|
||||
* Your company name, as it should be displayed to the user
|
||||
* when requesting consent via a PayPalFuturePaymentViewController.
|
||||
*/
|
||||
merchantName: string;
|
||||
|
||||
/**
|
||||
* URL of your company's privacy policy, which will be offered to the user
|
||||
* when requesting consent via a PayPalFuturePaymentViewController.
|
||||
*/
|
||||
merchantPrivacyPolicyURL: string;
|
||||
|
||||
/**
|
||||
* URL of your company's user agreement, which will be offered to the user
|
||||
* when requesting consent via a PayPalFuturePaymentViewController.
|
||||
*/
|
||||
merchantUserAgreementURL: string;
|
||||
|
||||
/**
|
||||
* If set to false, the SDK will only support paying with PayPal, not with credit cards.
|
||||
* This applies only to single payments (via PayPalPaymentViewController).
|
||||
* Future payments (via PayPalFuturePaymentViewController) always use PayPal.
|
||||
* Defaults to true.
|
||||
*/
|
||||
acceptCreditCards: boolean;
|
||||
|
||||
/**
|
||||
* For single payments, options for the shipping address.
|
||||
*
|
||||
* - 0 - PayPalShippingAddressOptionNone: no shipping address applies.
|
||||
*
|
||||
* - 1 - PayPalShippingAddressOptionProvided: shipping address will be provided by your app,
|
||||
* in the shippingAddress property of PayPalPayment.
|
||||
*
|
||||
* - 2 - PayPalShippingAddressOptionPayPal: user will choose from shipping addresses on file
|
||||
* for their PayPal account.
|
||||
*
|
||||
* - 3 - PayPalShippingAddressOptionBoth: user will choose from the shipping address provided by your app,
|
||||
* in the shippingAddress property of PayPalPayment, plus the shipping addresses on file for the user's PayPal account.
|
||||
*
|
||||
* Defaults to 0 (PayPalShippingAddressOptionNone).
|
||||
*/
|
||||
payPalShippingAddressOption: number;
|
||||
|
||||
/**
|
||||
* If set to true, then if the user pays via their PayPal account,
|
||||
* the SDK will remember the user's PayPal username or phone number;
|
||||
* if the user pays via their credit card, then the SDK will remember
|
||||
* the PayPal Vault token representing the user's credit card.
|
||||
*
|
||||
* If set to false, then any previously-remembered username, phone number, or
|
||||
* credit card token will be erased, and subsequent payment information will
|
||||
* not be remembered.
|
||||
*
|
||||
* Defaults to true.
|
||||
*/
|
||||
rememberUser: boolean;
|
||||
|
||||
/**
|
||||
* If not set, or if set to nil, defaults to the device's current language setting.
|
||||
*
|
||||
* Can be specified as a language code ("en", "fr", "zh-Hans", etc.) or as a locale ("en_AU", "fr_FR", "zh-Hant_HK", etc.).
|
||||
* If the library does not contain localized strings for a specified locale, then will fall back to the language. E.g., "es_CO" -> "es".
|
||||
* If the library does not contain localized strings for a specified language, then will fall back to American English.
|
||||
*
|
||||
* If you specify only a language code, and that code matches the device's currently preferred language,
|
||||
* then the library will attempt to use the device's current region as well.
|
||||
* E.g., specifying "en" on a device set to "English" and "United Kingdom" will result in "en_GB".
|
||||
*
|
||||
* These localizations are currently included:
|
||||
* da,de,en,en_AU,en_GB,en_SV,es,es_MX,fr,he,it,ja,ko,nb,nl,pl,pt,pt_BR,ru,sv,tr,zh-Hans,zh-Hant_HK,zh-Hant_TW.
|
||||
*/
|
||||
languageOrLocale: string;
|
||||
|
||||
/**
|
||||
* Normally, the SDK blurs the screen when the app is backgrounded,
|
||||
* to obscure credit card or PayPal account details in the iOS-saved screenshot.
|
||||
* If your app already does its own blurring upon backgrounding, you might choose to disable this.
|
||||
* Defaults to false.
|
||||
*/
|
||||
disableBlurWhenBackgrounding: boolean;
|
||||
|
||||
/**
|
||||
* If you will present the SDK's view controller within a popover, then set this property to true.
|
||||
* Defaults to false. (iOS only)
|
||||
*/
|
||||
presentingInPopover: boolean;
|
||||
|
||||
/**
|
||||
* Sandbox credentials can be difficult to type on a mobile device. Setting this flag to true will
|
||||
* cause the sandboxUserPassword and sandboxUserPin to always be pre-populated into login fields.
|
||||
*
|
||||
* This setting will have no effect if the operation mode is production.
|
||||
* Defaults to false.
|
||||
*/
|
||||
forceDefaultsInSandbox: boolean;
|
||||
|
||||
/**
|
||||
* Password to use for sandbox if 'forceDefaultsInSandbox' is set.
|
||||
*/
|
||||
sandboxUserPassword: string;
|
||||
|
||||
/**
|
||||
* PIN to use for sandbox if 'forceDefaultsInSandbox' is set.
|
||||
*/
|
||||
sandboxUserPin: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* Describes the options that can be passed into the PayPalConfiguration class constructor.
|
||||
*/
|
||||
interface PayPalConfigurationOptions {
|
||||
|
||||
/**
|
||||
* Will be overridden by email used in most recent PayPal login.
|
||||
*/
|
||||
defaultUserEmail?: string;
|
||||
|
||||
/**
|
||||
* Will be overridden by phone country code used in most recent PayPal login
|
||||
*/
|
||||
defaultUserPhoneCountryCode?: string;
|
||||
|
||||
/**
|
||||
* Will be overridden by phone number used in most recent PayPal login.
|
||||
* @note If you set defaultUserPhoneNumber, be sure to also set defaultUserPhoneCountryCode.
|
||||
*/
|
||||
defaultUserPhoneNumber?: string;
|
||||
|
||||
/**
|
||||
* Your company name, as it should be displayed to the user
|
||||
* when requesting consent via a PayPalFuturePaymentViewController.
|
||||
*/
|
||||
merchantName?: string;
|
||||
|
||||
/**
|
||||
* URL of your company's privacy policy, which will be offered to the user
|
||||
* when requesting consent via a PayPalFuturePaymentViewController.
|
||||
*/
|
||||
merchantPrivacyPolicyURL?: string;
|
||||
|
||||
/**
|
||||
* URL of your company's user agreement, which will be offered to the user
|
||||
* when requesting consent via a PayPalFuturePaymentViewController.
|
||||
*/
|
||||
merchantUserAgreementURL?: string;
|
||||
|
||||
/**
|
||||
* If set to false, the SDK will only support paying with PayPal, not with credit cards.
|
||||
* This applies only to single payments (via PayPalPaymentViewController).
|
||||
* Future payments (via PayPalFuturePaymentViewController) always use PayPal.
|
||||
* Defaults to true.
|
||||
*/
|
||||
acceptCreditCards?: boolean;
|
||||
|
||||
/**
|
||||
* For single payments, options for the shipping address.
|
||||
*
|
||||
* - 0 - PayPalShippingAddressOptionNone?: no shipping address applies.
|
||||
*
|
||||
* - 1 - PayPalShippingAddressOptionProvided?: shipping address will be provided by your app,
|
||||
* in the shippingAddress property of PayPalPayment.
|
||||
*
|
||||
* - 2 - PayPalShippingAddressOptionPayPal?: user will choose from shipping addresses on file
|
||||
* for their PayPal account.
|
||||
*
|
||||
* - 3 - PayPalShippingAddressOptionBoth?: user will choose from the shipping address provided by your app,
|
||||
* in the shippingAddress property of PayPalPayment, plus the shipping addresses on file for the user's PayPal account.
|
||||
*
|
||||
* Defaults to 0 (PayPalShippingAddressOptionNone).
|
||||
*/
|
||||
payPalShippingAddressOption?: number;
|
||||
|
||||
/**
|
||||
* If set to true, then if the user pays via their PayPal account,
|
||||
* the SDK will remember the user's PayPal username or phone number;
|
||||
* if the user pays via their credit card, then the SDK will remember
|
||||
* the PayPal Vault token representing the user's credit card.
|
||||
*
|
||||
* If set to false, then any previously-remembered username, phone number, or
|
||||
* credit card token will be erased, and subsequent payment information will
|
||||
* not be remembered.
|
||||
*
|
||||
* Defaults to true.
|
||||
*/
|
||||
rememberUser?: boolean;
|
||||
|
||||
/**
|
||||
* If not set, or if set to nil, defaults to the device's current language setting.
|
||||
*
|
||||
* Can be specified as a language code ("en", "fr", "zh-Hans", etc.) or as a locale ("en_AU", "fr_FR", "zh-Hant_HK", etc.).
|
||||
* If the library does not contain localized strings for a specified locale, then will fall back to the language. E.g., "es_CO" -> "es".
|
||||
* If the library does not contain localized strings for a specified language, then will fall back to American English.
|
||||
*
|
||||
* If you specify only a language code, and that code matches the device's currently preferred language,
|
||||
* then the library will attempt to use the device's current region as well.
|
||||
* E.g., specifying "en" on a device set to "English" and "United Kingdom" will result in "en_GB".
|
||||
*
|
||||
* These localizations are currently included:
|
||||
* da,de,en,en_AU,en_GB,en_SV,es,es_MX,fr,he,it,ja,ko,nb,nl,pl,pt,pt_BR,ru,sv,tr,zh-Hans,zh-Hant_HK,zh-Hant_TW.
|
||||
*/
|
||||
languageOrLocale?: string;
|
||||
|
||||
/**
|
||||
* Normally, the SDK blurs the screen when the app is backgrounded,
|
||||
* to obscure credit card or PayPal account details in the iOS-saved screenshot.
|
||||
* If your app already does its own blurring upon backgrounding, you might choose to disable this.
|
||||
* Defaults to false.
|
||||
*/
|
||||
disableBlurWhenBackgrounding?: boolean;
|
||||
|
||||
/**
|
||||
* If you will present the SDK's view controller within a popover, then set this property to true.
|
||||
* Defaults to false. (iOS only)
|
||||
*/
|
||||
presentingInPopover?: boolean;
|
||||
|
||||
/**
|
||||
* Sandbox credentials can be difficult to type on a mobile device. Setting this flag to true will
|
||||
* cause the sandboxUserPassword and sandboxUserPin to always be pre-populated into login fields.
|
||||
*
|
||||
* This setting will have no effect if the operation mode is production.
|
||||
* Defaults to false.
|
||||
*/
|
||||
forceDefaultsInSandbox?: boolean;
|
||||
|
||||
/**
|
||||
* Password to use for sandbox if 'forceDefaultsInSandbox' is set.
|
||||
*/
|
||||
sandboxUserPassword?: string;
|
||||
|
||||
/**
|
||||
* PIN to use for sandbox if 'forceDefaultsInSandbox' is set.
|
||||
*/
|
||||
sandboxUserPin?: string;
|
||||
}
|
||||
|
||||
//#endregion
|
||||
|
||||
//#region cdv-plugin-paypal-mobile-sdk.js
|
||||
|
||||
declare module PayPalCordovaPlugin {
|
||||
|
||||
export interface PayPalClientIds {
|
||||
PayPalEnvironmentProduction: string;
|
||||
PayPalEnvironmentSandbox: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* Represents the portion of an object that is common to all responses.
|
||||
*/
|
||||
export interface BaseResult {
|
||||
client: Client;
|
||||
response_type: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* Represents the client portion of the response.
|
||||
*/
|
||||
export interface Client {
|
||||
paypal_sdk_version: string;
|
||||
environment: string;
|
||||
platform: string;
|
||||
product_name: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* Represents the response for a successful callback from renderSinglePaymentUI().
|
||||
*/
|
||||
export interface SinglePaymentResult extends BaseResult {
|
||||
response: {
|
||||
intent: string;
|
||||
id: string;
|
||||
state: string;
|
||||
authorization_id: string;
|
||||
create_time: string;
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* Represents the response for a successful callback from renderFuturePaymentUI().
|
||||
*/
|
||||
export interface FuturePaymentResult extends BaseResult {
|
||||
response: {
|
||||
code: string;
|
||||
};
|
||||
}
|
||||
|
||||
export interface PayPalMobileStatic {
|
||||
/**
|
||||
* Retrieve the version of the PayPal iOS SDK library. Useful when contacting support.
|
||||
*
|
||||
* @param completionCallback a callback function accepting a string
|
||||
*/
|
||||
version(completionCallback: (result: string) => void): void;
|
||||
|
||||
/**
|
||||
* You MUST call this method to initialize the PayPal Mobile SDK.
|
||||
*
|
||||
* The PayPal Mobile SDK can operate in different environments to facilitate development and testing.
|
||||
*
|
||||
* @param clientIdsForEnvironments set of client ids for environments
|
||||
* Example: var clientIdsForEnvironments = {
|
||||
* PayPalEnvironmentProduction : @"my-client-id-for-Production",
|
||||
* PayPalEnvironmentSandbox : @"my-client-id-for-Sandbox"
|
||||
* }
|
||||
* @param completionCallback a callback function on success
|
||||
*/
|
||||
init(clientIdsForEnvironments: PayPalCordovaPlugin.PayPalClientIds, completionCallback: () => void): void;
|
||||
|
||||
/**
|
||||
* You must preconnect to PayPal to prepare the device for processing payments.
|
||||
* This improves the user experience, by making the presentation of the
|
||||
* UI faster. The preconnect is valid for a limited time, so
|
||||
* the recommended time to preconnect is on page load.
|
||||
*
|
||||
* @param environment available options are "PayPalEnvironmentNoNetwork", "PayPalEnvironmentProduction" and "PayPalEnvironmentSandbox"
|
||||
* @param configuration PayPalConfiguration object, for Future Payments merchantName, merchantPrivacyPolicyURL
|
||||
* and merchantUserAgreementURL must be set be set
|
||||
* @param completionCallback a callback function on success
|
||||
*/
|
||||
prepareToRender(environment: string, configuration: PayPalConfiguration, completionCallback: () => void): void;
|
||||
|
||||
/**
|
||||
* Start PayPal UI to collect payment from the user.
|
||||
* See https://developer.paypal.com/webapps/developer/docs/integration/mobile/ios-integration-guide/
|
||||
* for more documentation of the params.
|
||||
*
|
||||
* @param payment PayPalPayment object
|
||||
* @param completionCallback a callback function accepting a js object, called when the user has completed payment
|
||||
* @param cancelCallback a callback function accepting a reason string, called when the user cancels the payment
|
||||
*/
|
||||
renderSinglePaymentUI(payment: PayPalPayment, completionCallback: (result: PayPalCordovaPlugin.SinglePaymentResult) => void, cancelCallback: (cancelReason: string) => void): void;
|
||||
|
||||
/**
|
||||
* @deprecated
|
||||
* Once a user has consented to future payments, when the user subsequently initiates a PayPal payment
|
||||
* from their device to be completed by your server, PayPal uses a Correlation ID to verify that the
|
||||
* payment is originating from a valid, user-consented device+application.
|
||||
* This helps reduce fraud and decrease declines.
|
||||
* This method MUST be called prior to initiating a pre-consented payment (a "future payment") from a mobile device.
|
||||
* Pass the result to your server, to include in the payment request sent to PayPal.
|
||||
* Do not otherwise cache or store this value.
|
||||
*
|
||||
* @param environment available options are "PayPalEnvironmentNoNetwork", "PayPalEnvironmentProduction" and "PayPalEnvironmentSandbox"
|
||||
* @param callback applicationCorrelationID Your server will send this to PayPal in a 'Paypal-Application-Correlation-Id' header.
|
||||
*/
|
||||
applicationCorrelationIDForEnvironment(environment: string, completionCallback: (applicationCorrelationId: string) => void): void;
|
||||
|
||||
/**
|
||||
* Once a user has consented to future payments, when the user subsequently initiates a PayPal payment
|
||||
* from their device to be completed by your server, PayPal uses a Correlation ID to verify that the
|
||||
* payment is originating from a valid, user-consented device+application.
|
||||
* This helps reduce fraud and decrease declines.
|
||||
* This method MUST be called prior to initiating a pre-consented payment (a "future payment") from a mobile device.
|
||||
* Pass the result to your server, to include in the payment request sent to PayPal.
|
||||
* Do not otherwise cache or store this value.
|
||||
*
|
||||
* @param callback clientMetadataID Your server will send this to PayPal in a 'PayPal-Client-Metadata-Id' header.
|
||||
*/
|
||||
clientMetadataID(completionCallback: (clientMetadataId: string) => void): void;
|
||||
|
||||
/**
|
||||
* Please Read Docs on Future Payments at https://github.com/paypal/PayPal-iOS-SDK#future-payments
|
||||
*
|
||||
* @param completionCallback a callback function accepting a js object with future payment authorization
|
||||
* @param cancelCallback a callback function accepting a reason string, called when the user canceled without agreement
|
||||
*/
|
||||
renderFuturePaymentUI(completionCallback: (result: PayPalCordovaPlugin.FuturePaymentResult) => void, cancelCallback: (cancelReason: string) => void): void;
|
||||
|
||||
/**
|
||||
* Please Read Docs on Profile Sharing at https://github.com/paypal/PayPal-iOS-SDK#profile-sharing
|
||||
*
|
||||
* @param scopes scopes Set of requested scope-values. Accepted scopes are: openid, profile, address, email, phone, futurepayments and paypalattributes
|
||||
* See https://developer.paypal.com/docs/integration/direct/identity/attributes/ for more details
|
||||
* @param completionCallback a callback function accepting a js object with future payment authorization
|
||||
* @param cancelCallback a callback function accepting a reason string, called when the user canceled without agreement
|
||||
*/
|
||||
renderProfileSharingUI(scopes: string[], completionCallback: (result: any) => void, cancelCallback: (cancelReason: string) => void): void;
|
||||
}
|
||||
}
|
||||
|
||||
declare var PayPalMobile: PayPalCordovaPlugin.PayPalMobileStatic;
|
||||
|
||||
//#endregion
|
||||
Vendored
+13
-1
@@ -47,7 +47,19 @@ interface AccWizardOptions {
|
||||
nextText: string;
|
||||
|
||||
/**
|
||||
* @summary Text for back button
|
||||
* @summary Text for back button.
|
||||
* @type {string}
|
||||
*/
|
||||
backText: string;
|
||||
|
||||
/**
|
||||
* @summary HTML input type for next button. (default: "submit")
|
||||
* @type {string}
|
||||
*/
|
||||
nextType: string;
|
||||
|
||||
/**
|
||||
* @summary HTML input type for back button. (default: "reset")
|
||||
* @type {string}
|
||||
*/
|
||||
backType: string;
|
||||
|
||||
@@ -14,7 +14,7 @@ var string: string;
|
||||
// acorn
|
||||
string = acorn.version;
|
||||
program = acorn.parse('code');
|
||||
program = acorn.parse('code', {range: true, onToken: tokens, onComment: comments});
|
||||
program = acorn.parse('code', {ranges: true, onToken: tokens, onComment: comments});
|
||||
program = acorn.parse('code', {
|
||||
ranges: true,
|
||||
onToken: (token) => tokens.push(token),
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
/// <reference path="amqplib.d.ts" />
|
||||
|
||||
import amqp = require("amqplib");
|
||||
|
||||
var msg = "Hello World";
|
||||
|
||||
amqp.connect("amqp://localhost")
|
||||
.then(connection => {
|
||||
return connection.createChannel()
|
||||
.tap(channel => channel.checkQueue("myQueue"))
|
||||
.then(channel => channel.sendToQueue("myQueue", new Buffer(msg)))
|
||||
.ensure(() => connection.close());
|
||||
});
|
||||
|
||||
amqp.connect("amqp://localhost")
|
||||
.then(connection => {
|
||||
return connection.createChannel()
|
||||
.tap(channel => channel.checkQueue("myQueue"))
|
||||
.then(channel => channel.consume("myQueue", newMsg => console.log("New Message: " + newMsg.content.toString())))
|
||||
.ensure(() => connection.close());
|
||||
});
|
||||
Vendored
+144
@@ -0,0 +1,144 @@
|
||||
// Type definitions for amqplib 0.3.x
|
||||
// Project: https://github.com/squaremo/amqp.node
|
||||
// Definitions by: Michael Nahkies <https://github.com/mnahkies>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
/// <reference path="../when/when.d.ts" />
|
||||
/// <reference path="../node/node.d.ts" />
|
||||
|
||||
declare module "amqplib" {
|
||||
|
||||
import events = require("events");
|
||||
import when = require("when");
|
||||
|
||||
interface Connection extends events.EventEmitter {
|
||||
close(): when.Promise<void>;
|
||||
createChannel(): when.Promise<Channel>;
|
||||
createConfirmChannel(): when.Promise<Channel>;
|
||||
}
|
||||
|
||||
module Replies {
|
||||
interface Empty {
|
||||
}
|
||||
interface AssertQueue {
|
||||
queue: string;
|
||||
messageCount: number;
|
||||
consumerCount: number;
|
||||
}
|
||||
interface DeleteQueue {
|
||||
messageCount: number;
|
||||
}
|
||||
interface AssertExchange {
|
||||
exchange: string;
|
||||
}
|
||||
interface Consume {
|
||||
consumerTag: string;
|
||||
}
|
||||
}
|
||||
|
||||
module Options {
|
||||
interface AssertQueue {
|
||||
exclusive?: boolean;
|
||||
durable?: boolean;
|
||||
autoDelete?: boolean;
|
||||
arguments?: any;
|
||||
messageTtl?: number;
|
||||
expires?: number;
|
||||
deadLetterExchange?: string;
|
||||
maxLength?: number;
|
||||
}
|
||||
interface DeleteQueue {
|
||||
ifUnused?: boolean;
|
||||
ifEmpty?: boolean;
|
||||
}
|
||||
interface AssertExchange {
|
||||
durable?: boolean;
|
||||
internal?: boolean;
|
||||
autoDelete?: boolean;
|
||||
alternateExchange?: string;
|
||||
arguments?: any;
|
||||
}
|
||||
interface DeleteExchange {
|
||||
ifUnused?: boolean;
|
||||
}
|
||||
interface Publish {
|
||||
expiration?: string;
|
||||
userId?: string;
|
||||
CC?: string | string[];
|
||||
|
||||
mandatory?: boolean;
|
||||
persistent?: boolean;
|
||||
deliveryMode?: boolean | number;
|
||||
BCC?: string | string[];
|
||||
|
||||
contentType?: string;
|
||||
contentEncoding?: string;
|
||||
headers?: Object;
|
||||
priority?: number;
|
||||
correlationId?: string;
|
||||
replyTo?: string;
|
||||
messageId?: string;
|
||||
timestamp?: number;
|
||||
type?: string;
|
||||
appId?: string;
|
||||
}
|
||||
interface Consume {
|
||||
consumerTag?: string;
|
||||
noLocal?: boolean;
|
||||
noAck?: boolean;
|
||||
exclusive?: boolean;
|
||||
priority?: number;
|
||||
arguments?: Object;
|
||||
}
|
||||
interface Get {
|
||||
noAck?: boolean;
|
||||
}
|
||||
}
|
||||
|
||||
interface Message {
|
||||
content: Buffer;
|
||||
fields: Object;
|
||||
properties: Object;
|
||||
}
|
||||
|
||||
interface Channel extends events.EventEmitter {
|
||||
close(): when.Promise<void>;
|
||||
|
||||
assertQueue(queue: string, options?: Options.AssertQueue): when.Promise<Replies.AssertQueue>;
|
||||
checkQueue(queue: string): when.Promise<Replies.AssertQueue>;
|
||||
|
||||
deleteQueue(queue: string, options?: Options.DeleteQueue): when.Promise<Replies.DeleteQueue>;
|
||||
purgeQueue(queue: string): when.Promise<Replies.DeleteQueue>;
|
||||
|
||||
bindQueue(queue: string, source: string, pattern: string, args?: any): when.Promise<Replies.Empty>;
|
||||
unbindQueue(queue: string, source: string, pattern: string, args?: any): when.Promise<Replies.Empty>;
|
||||
|
||||
assertExchange(exchange: string, type: string, options?: Options.AssertExchange): when.Promise<Replies.AssertExchange>;
|
||||
checkExchange(exchange: string): when.Promise<Replies.Empty>;
|
||||
|
||||
deleteExchange(exchange: string, options?: Options.DeleteExchange): when.Promise<Replies.Empty>;
|
||||
|
||||
bindExchange(destination: string, source: string, pattern: string, args?: any): when.Promise<Replies.Empty>;
|
||||
unbindExchange(destination: string, source: string, pattern: string, args?: any): when.Promise<Replies.Empty>;
|
||||
|
||||
publish(exchange: string, routingKey: string, content: Buffer, options?: Options.Publish): boolean;
|
||||
sendToQueue(queue: string, content: Buffer, options?: Options.Publish): boolean;
|
||||
|
||||
consume(queue: string, onMessage: (msg: Message) => any, options?: Options.Consume): when.Promise<Replies.Consume>;
|
||||
|
||||
cancel(consumerTag: string): when.Promise<Replies.Empty>;
|
||||
get(queue: string, options?: Options.Get): when.Promise<Message | boolean>;
|
||||
|
||||
ack(message: Message, allUpTo?: boolean): void;
|
||||
ackAll(): void;
|
||||
|
||||
nack(message: Message, allUpTo?: boolean, requeue?: boolean): void;
|
||||
nackAll(requeue?: boolean): void;
|
||||
reject(message: Message, requeue?: boolean): void;
|
||||
|
||||
prefetch(count: number, global?: boolean): when.Promise<Replies.Empty>;
|
||||
recover(): when.Promise<Replies.Empty>;
|
||||
}
|
||||
|
||||
function connect(url: string, socketOptions?: any): when.Promise<Connection>;
|
||||
}
|
||||
+2
-26
@@ -3,30 +3,6 @@
|
||||
// Definitions by: John Reilly <https://github.com/johnnyreilly>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
/// <reference path="../angularjs/angular.d.ts" />
|
||||
/// <reference path="../ng-file-upload/ng-file-upload.d.ts" />
|
||||
|
||||
declare module angular.angularFileUpload {
|
||||
|
||||
interface IUploadService {
|
||||
|
||||
http<T>(config: IRequestConfig): IUploadPromise<T>;
|
||||
upload<T>(config: IFileUploadConfig): IUploadPromise<T>;
|
||||
}
|
||||
|
||||
interface IUploadPromise<T> extends IHttpPromise<T> {
|
||||
abort(): IUploadPromise<T>;
|
||||
progress(callback: IHttpPromiseCallback<T>): IUploadPromise<T>;
|
||||
xhr(callback: IHttpPromiseCallback<T>): IUploadPromise<T>;
|
||||
}
|
||||
|
||||
interface IFileUploadConfig extends IRequestConfig {
|
||||
|
||||
file: File;
|
||||
fileName?: string;
|
||||
}
|
||||
|
||||
interface IFileProgressEvent extends ProgressEvent {
|
||||
|
||||
config: IFileUploadConfig;
|
||||
}
|
||||
}
|
||||
// THIS FILE WILL REMOVE IF angular-file-upload.d.ts incoming.
|
||||
|
||||
@@ -124,3 +124,18 @@ $localForage.iterate(function (value, key) {
|
||||
}
|
||||
}).then(function (data) {
|
||||
});
|
||||
|
||||
$localForage.bind($rootScope, 'key').then(function(data) {
|
||||
});
|
||||
|
||||
$localForage.bind($rootScope, {key: 'key'}).then(function(data) {
|
||||
});
|
||||
|
||||
$localForage.bind($rootScope, {key: 'key', defaultValue: 'defaultValue'}).then(function(data) {
|
||||
});
|
||||
|
||||
$localForage.bind($rootScope, {key: 'key', scopeKey: 'scopeKey'}).then(function(data) {
|
||||
});
|
||||
|
||||
$localForage.bind($rootScope, {key: 'key', name: 'name'}).then(function(data) {
|
||||
});
|
||||
|
||||
+5
-5
@@ -46,14 +46,14 @@ declare module angular.localForage {
|
||||
|
||||
iterate<T>(iteratorCallback:(value:string | number, key:string)=>T):angular.IPromise<T>;
|
||||
|
||||
bind($scope:ng.IScope, key:string):void;
|
||||
bind($scope:ng.IScope, key:string):angular.IPromise<any>;
|
||||
|
||||
bind($scope:ng.IScope, config:{
|
||||
key:string;
|
||||
defaultValue:any;
|
||||
scopeKey:string;
|
||||
name:string;
|
||||
}):void;
|
||||
defaultValue?:any;
|
||||
scopeKey?:string;
|
||||
name?:string;
|
||||
}):angular.IPromise<any>;
|
||||
|
||||
unbind($scope:ng.IScope, key:string, scopeKey?:string):void;
|
||||
|
||||
|
||||
+1
@@ -122,6 +122,7 @@ declare module angular.material {
|
||||
theme(theme: string): T;
|
||||
hideDelay(delay: number): T;
|
||||
position(position: string): T;
|
||||
parent(parent?: string|Element|JQuery): T; // default: root node
|
||||
}
|
||||
|
||||
interface ISimpleToastPreset extends IToastPreset<ISimpleToastPreset> {
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
/// <reference path="angular-notifications.d.ts" />
|
||||
|
||||
var myapp = angular.module("myapp", ["notifications"]);
|
||||
|
||||
myapp.controller("MyController", ["$scope", "notifications",
|
||||
function ($scope:ng.IScope, notifications:angular.notifications.INotificationFactory) { // <-- Inject notifications
|
||||
|
||||
var userData = {'some': 'data', 'optional': true};
|
||||
notifications.info("Something happened", "here is the content of what happened", userData);
|
||||
|
||||
}
|
||||
]);
|
||||
@@ -0,0 +1,82 @@
|
||||
// Type definitions for angular-notifications
|
||||
// Project: https://github.com/DerekRies/angular-notifications
|
||||
// Definitions by: Tomasz Ducin <https://github.com/ducin/DefinitelyTyped>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
/// <reference path="../angularjs/angular.d.ts" />
|
||||
|
||||
declare module angular.notifications {
|
||||
|
||||
interface IAnimation {
|
||||
duration: number;
|
||||
enabled: boolean;
|
||||
}
|
||||
|
||||
interface ISettings {
|
||||
info: IAnimation;
|
||||
warning: IAnimation;
|
||||
error: IAnimation;
|
||||
success: IAnimation;
|
||||
progress: IAnimation;
|
||||
custom: IAnimation;
|
||||
details: boolean;
|
||||
localStorage: boolean;
|
||||
html5Mode: boolean;
|
||||
html5DefaultIcon: string;
|
||||
}
|
||||
|
||||
interface INotification {
|
||||
type: string;
|
||||
image: string;
|
||||
icon: string;
|
||||
title: string;
|
||||
content: string;
|
||||
timestamp: string;
|
||||
userData: string;
|
||||
}
|
||||
|
||||
interface INotificationFactory extends angular.IModule {
|
||||
|
||||
/* ========== SETTINGS RELATED METHODS =============*/
|
||||
|
||||
disableHtml5Mode(): void;
|
||||
disableType(notificationType: string): void;
|
||||
enableHtml5Mode(): void;
|
||||
enableType(notificationType: string): void;
|
||||
getSettings(): ISettings;
|
||||
toggleType(notificationType: string): void;
|
||||
toggleHtml5Mode(): void;
|
||||
requestHtml5ModePermissions(): boolean;
|
||||
|
||||
/* ============ QUERYING RELATED METHODS ============*/
|
||||
|
||||
getAll(): Array<INotification>;
|
||||
getQueue(): Array<INotification>;
|
||||
|
||||
/* ============== NOTIFICATION METHODS ==============*/
|
||||
|
||||
info(title: string): INotification;
|
||||
info(title: string, content: string): INotification;
|
||||
info(title: string, content: string, userData: any): INotification;
|
||||
error(title: string): INotification;
|
||||
error(title: string, content: string): INotification;
|
||||
error(title: string, content: string, userData: any): INotification;
|
||||
success(title: string): INotification;
|
||||
success(title: string, content: string): INotification;
|
||||
success(title: string, content: string, userData: any): INotification;
|
||||
warning(title: string): INotification;
|
||||
warning(title: string, content: string): INotification;
|
||||
warning(title: string, content: string, userData: any): INotification;
|
||||
awesomeNotify(type: string, icon: string, title: string, content: string, userData: any): INotification;
|
||||
notify(image: string, title: string, content: string, userData: any): INotification;
|
||||
makeNotification(type: string, image: string, icon: string, title: string, content: string, userData: any): INotification;
|
||||
|
||||
/* ============ PERSISTENCE METHODS ============ */
|
||||
|
||||
save(): void;
|
||||
restore(): void;
|
||||
clear(): void;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,77 @@
|
||||
/// <reference path='angular-signalr-hub.d.ts' />
|
||||
/// <reference path='../angularjs/angular.d.ts' />
|
||||
|
||||
angular
|
||||
.module('app', ['SignalR'])
|
||||
.factory('Employees', ngSignalrTest.EmployeesFactory);
|
||||
|
||||
module ngSignalrTest {
|
||||
export class EmployeesFactory {
|
||||
static $inject = ['$rootScope', 'Hub', '$timeout'];
|
||||
private hub: ngSignalr.Hub;
|
||||
public all: Array<Employee>;
|
||||
|
||||
constructor($rootScope: ng.IRootScopeService, Hub: ngSignalr.HubFactory, $timeout: ng.ITimeoutService) {
|
||||
// declaring the hub connection
|
||||
this.hub = new Hub('employee', {
|
||||
// client-side methods
|
||||
listeners: {
|
||||
'lockEmployee': (id: number) => {
|
||||
var employee = this.find(id);
|
||||
employee.Locked = true;
|
||||
$rootScope.$apply();
|
||||
},
|
||||
'unlockEmployee': (id: number) => {
|
||||
var employee = this.find(id);
|
||||
employee.Locked = false;
|
||||
$rootScope.$apply();
|
||||
}
|
||||
},
|
||||
|
||||
// server-side methods
|
||||
methods: ['lock', 'unlock'],
|
||||
|
||||
// query params sent on initial connection
|
||||
queryParams:{
|
||||
'token': 'exampletoken'
|
||||
},
|
||||
|
||||
// handle connection error
|
||||
errorHandler: (message: string) => {
|
||||
console.error(message);
|
||||
},
|
||||
|
||||
stateChanged: (state: SignalRStateChange) => {
|
||||
// your code here
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private find(id: number) {
|
||||
for (var i = 0; i < this.all.length; i++) {
|
||||
if (this.all[i].Id === id) return this.all[i];
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
public edit = (employee: Employee) => {
|
||||
employee.Edit = true;
|
||||
this.hub.invoke('lock', employee.Id);
|
||||
};
|
||||
|
||||
public done = (employee: Employee) => {
|
||||
employee.Edit = false;
|
||||
this.hub.invoke('unlock', employee.Id);
|
||||
}
|
||||
}
|
||||
|
||||
interface Employee {
|
||||
Id: number;
|
||||
Name: string;
|
||||
Email: string;
|
||||
Salary: number;
|
||||
Edit: boolean;
|
||||
Locked: boolean;
|
||||
}
|
||||
}
|
||||
+73
@@ -0,0 +1,73 @@
|
||||
// Type definitions for angular-signalr-hub v1.5.0
|
||||
// Project: https://github.com/JustMaier/angular-signalr-hub
|
||||
// Definitions by: Adam Santaniello <https://github.com/AdamSantaniello>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
/// <reference path='../signalr/signalr.d.ts' />
|
||||
|
||||
declare module ngSignalr {
|
||||
interface HubFactory {
|
||||
/**
|
||||
* Creates a new Hub connection
|
||||
*/
|
||||
new(hubName: string, options: HubOptions) : Hub
|
||||
}
|
||||
|
||||
class Hub {
|
||||
hubName: string;
|
||||
connection: SignalR;
|
||||
proxy: HubProxy;
|
||||
|
||||
on(event: string, fn: ((...args: any[]) => void)): void;
|
||||
invoke(method: string, ...args: any[]): JQueryDeferred<any>;
|
||||
disconnect(): void;
|
||||
connect(): JQueryPromise<any>;
|
||||
}
|
||||
|
||||
interface HubOptions {
|
||||
/**
|
||||
* Collection of client side callbacks
|
||||
*/
|
||||
listeners?: { [index: string] : (...args: any[]) => void };
|
||||
|
||||
/**
|
||||
* String array of server side methods which the client can call
|
||||
*/
|
||||
methods?: Array<string>;
|
||||
|
||||
/**
|
||||
* Sets the root path for the SignalR web service
|
||||
*/
|
||||
rootPath?: string;
|
||||
|
||||
/**
|
||||
* Object representing additional query params to be sent on connection
|
||||
*/
|
||||
queryParams?: { [index: string] : string };
|
||||
|
||||
/**
|
||||
* Function to handle hub connection errors
|
||||
*/
|
||||
errorHandler?: (error: string) => void;
|
||||
|
||||
/**
|
||||
* Enable/disable logging
|
||||
*/
|
||||
logging?: boolean;
|
||||
|
||||
/**
|
||||
* Use a shared global connection or create a new one just for this hub, defaults to true
|
||||
*/
|
||||
useSharedConnection?: boolean;
|
||||
|
||||
/**
|
||||
* Sets transport method (e.g 'longPolling' or ['webSockets', 'longPolling'] )
|
||||
*/
|
||||
transport?: any;
|
||||
|
||||
/**
|
||||
* Function to handle hub connection state changed event
|
||||
*/
|
||||
stateChanged?: (state: SignalRStateChange) => void;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,76 @@
|
||||
/// <reference path="angular-toasty.d.ts" />
|
||||
|
||||
interface AngularToastyTestControllerScope extends ng.IScope {
|
||||
button:string;
|
||||
options:toasty.IToastyConfig;
|
||||
runToasts(): void;
|
||||
runQuickToasts(): void;
|
||||
newToast(): void;
|
||||
clearToasts(): void;
|
||||
}
|
||||
|
||||
class AngularToastyTestController {
|
||||
|
||||
static $inject = ['$scope', 'toasty'];
|
||||
|
||||
constructor($scope:AngularToastyTestControllerScope, toasty:toasty.IToastyService) {
|
||||
|
||||
var options: toasty.IToastyConfig = {
|
||||
title: 'Toast It!',
|
||||
msg: 'Mmmm, tasties...',
|
||||
showClose: true,
|
||||
clickToClose: false,
|
||||
timeout: 5000,
|
||||
sound: true,
|
||||
html: false,
|
||||
shake: false,
|
||||
theme: 'bootstrap',
|
||||
onAdd: function () {
|
||||
console.log('Toasty ' + this.id + ' has been added!', this);
|
||||
},
|
||||
onRemove: function () {
|
||||
console.log('Toasty ' + this.id + ' has been removed!', this);
|
||||
},
|
||||
onClick: function () {
|
||||
console.log('Toasty ' + this.id + ' has been clicked!', this);
|
||||
}
|
||||
};
|
||||
|
||||
$scope.runToasts = function () {
|
||||
toasty(options);
|
||||
toasty.default(options);
|
||||
toasty.info(options);
|
||||
toasty.success(options);
|
||||
toasty.wait(options);
|
||||
toasty.error(options);
|
||||
toasty.warning(options);
|
||||
};
|
||||
|
||||
$scope.runQuickToasts = function () {
|
||||
var title = 'Toast it!'
|
||||
toasty(title);
|
||||
toasty.default(title);
|
||||
toasty.info(title);
|
||||
toasty.success(title);
|
||||
toasty.wait(title);
|
||||
toasty.error(title);
|
||||
toasty.warning(title);
|
||||
};
|
||||
|
||||
$scope.clearToasts = function () {
|
||||
toasty.clear();
|
||||
};
|
||||
}
|
||||
};
|
||||
|
||||
angular
|
||||
.module('main', ['angular-toasty'])
|
||||
.config(['toastyConfigProvider', (toastyConfigProvider:toasty.IToastyConfigProvider) => {
|
||||
toastyConfigProvider.setConfig({
|
||||
title: 'global',
|
||||
limit: 10,
|
||||
sound: false,
|
||||
shake: true
|
||||
});
|
||||
}])
|
||||
.controller('MainController', AngularToastyTestController);
|
||||
Vendored
+251
@@ -0,0 +1,251 @@
|
||||
// Type definitions for Angular Toasty v1.0.2
|
||||
// Project: https://github.com/invertase/angular-toasty
|
||||
// Definitions by: Dominik Muench <https://github.com/muenchdo>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
/// <reference path="../angularjs/angular.d.ts" />
|
||||
|
||||
declare module toasty {
|
||||
|
||||
interface IToastyService {
|
||||
/**
|
||||
* Create a toast with the given options and type.
|
||||
* @param options
|
||||
* @param type
|
||||
*/
|
||||
(options: IToastyConfig, type?: string): void;
|
||||
|
||||
/**
|
||||
* Create a default "quick toast" with the given title.
|
||||
* @param title
|
||||
*/
|
||||
(title: string|number): void;
|
||||
|
||||
/**
|
||||
* Create a default toast with the given options.
|
||||
* @param options
|
||||
*/
|
||||
default(options: IToastyConfig): void;
|
||||
|
||||
/**
|
||||
* Create a default "quick toast" with the given title.
|
||||
* @param title
|
||||
*/
|
||||
default(title: string|number): void;
|
||||
|
||||
/**
|
||||
* Create an info toast with the given options.
|
||||
* @param options
|
||||
*/
|
||||
info(options: IToastyConfig): void;
|
||||
|
||||
/**
|
||||
* Create an info "quick toast" with the given title.
|
||||
* @param title
|
||||
*/
|
||||
info(title: string|number): void;
|
||||
|
||||
/**
|
||||
* Create a wait toast with the given options.
|
||||
* @param options
|
||||
*/
|
||||
wait(options: IToastyConfig): void;
|
||||
|
||||
/**
|
||||
* Create a wait "quick toast" with the given title.
|
||||
* @param title
|
||||
*/
|
||||
wait(title: string|number): void;
|
||||
|
||||
/**
|
||||
* Create a success toast with the given options.
|
||||
* @param options
|
||||
*/
|
||||
success(options: IToastyConfig): void;
|
||||
|
||||
/**
|
||||
* Create a success "quick toast" with the given title.
|
||||
* @param title
|
||||
*/
|
||||
success(title: string|number): void;
|
||||
|
||||
/**
|
||||
* Create an error toast with the given options.
|
||||
* @param options
|
||||
*/
|
||||
error(options: IToastyConfig): void;
|
||||
|
||||
/**
|
||||
* Create an error "quick toast" with the given title.
|
||||
* @param title
|
||||
*/
|
||||
error(title: string|number): void;
|
||||
|
||||
/**
|
||||
* Create a warning toast with the given options.
|
||||
* @param options
|
||||
*/
|
||||
warning(options: IToastyConfig): void;
|
||||
|
||||
/**
|
||||
* Create a warning "quick toast" with the given title.
|
||||
* @param title
|
||||
*/
|
||||
warning(title: string|number): void;
|
||||
|
||||
/**
|
||||
* Clear toast(s).
|
||||
* @param id Optional ID to clear a specific toast.
|
||||
*/
|
||||
clear(id?: number): void;
|
||||
|
||||
/**
|
||||
* Get the global config.
|
||||
*/
|
||||
getGlobalConfig(): IGlobalConfig;
|
||||
|
||||
}
|
||||
|
||||
interface IToastyConfig {
|
||||
/**
|
||||
* The toast's title.
|
||||
*/
|
||||
title: string;
|
||||
|
||||
/**
|
||||
* The toast's message.
|
||||
*/
|
||||
msg?: string;
|
||||
|
||||
/**
|
||||
* Whether to show the 'X' icon to close the toast.
|
||||
*/
|
||||
showClose?: boolean;
|
||||
|
||||
/**
|
||||
* Whether clicking the toast closes it.
|
||||
*/
|
||||
clickToClose?: boolean;
|
||||
|
||||
/**
|
||||
* How long (in milliseconds) the toast shows before it's removed. Set to false to disable.
|
||||
*/
|
||||
timeout?: number;
|
||||
|
||||
/**
|
||||
* Whether to play a sound when a toast is added.
|
||||
*/
|
||||
sound?: boolean;
|
||||
|
||||
/**
|
||||
* Whether HTML is allowed in toasts.
|
||||
*/
|
||||
html?: boolean;
|
||||
|
||||
/**
|
||||
* Whether to shake the toasts.
|
||||
*/
|
||||
shake?: boolean;
|
||||
|
||||
/**
|
||||
* What theme to use.
|
||||
* - 'default'
|
||||
* - 'material'
|
||||
* - 'bootstrap'
|
||||
*/
|
||||
theme?: string;
|
||||
|
||||
/**
|
||||
* The toast's type:
|
||||
* - 'default'
|
||||
* - 'info'
|
||||
* - 'success'
|
||||
* - 'wait'
|
||||
* - 'error'
|
||||
* - 'warning'
|
||||
*/
|
||||
type?: string;
|
||||
|
||||
/**
|
||||
* Add event handler.
|
||||
*/
|
||||
onAdd?: Function;
|
||||
|
||||
/**
|
||||
* Remove event handler.
|
||||
*/
|
||||
onRemove?: Function;
|
||||
|
||||
/**
|
||||
* Click event handler.
|
||||
*/
|
||||
onClick?: Function;
|
||||
}
|
||||
|
||||
interface IGlobalConfig {
|
||||
|
||||
/**
|
||||
* Maximum number of toasts to show at once.
|
||||
*/
|
||||
limit?: number;
|
||||
|
||||
/**
|
||||
* The toast's title.
|
||||
*/
|
||||
title?: string;
|
||||
|
||||
/**
|
||||
* The toast's message.
|
||||
*/
|
||||
msg?: string;
|
||||
|
||||
/**
|
||||
* Whether to show the 'X' icon to close the toast.
|
||||
*/
|
||||
showClose?: boolean;
|
||||
|
||||
/**
|
||||
* Whether clicking the toast closes it.
|
||||
*/
|
||||
clickToClose?: boolean;
|
||||
|
||||
/**
|
||||
* The window position where the toast pops up.
|
||||
*
|
||||
*/
|
||||
position?: string;
|
||||
|
||||
/**
|
||||
* How long (in miliseconds) the toast shows before it's removed. Set to false to disable.
|
||||
*/
|
||||
timeout?: number|boolean;
|
||||
|
||||
/**
|
||||
* Whether to play a sound when a toast is added.
|
||||
*/
|
||||
sound?: boolean;
|
||||
|
||||
/**
|
||||
* Whether HTML is allowed in toast.
|
||||
*/
|
||||
html?: boolean;
|
||||
|
||||
/**
|
||||
* Whether to shake the toast.
|
||||
*/
|
||||
shake?: boolean;
|
||||
|
||||
/**
|
||||
* What theme to use.
|
||||
* - 'default'
|
||||
* - 'material'
|
||||
* - 'bootstrap'
|
||||
*/
|
||||
theme?: string;
|
||||
}
|
||||
|
||||
interface IToastyConfigProvider {
|
||||
setConfig(override: IGlobalConfig): void;
|
||||
$get(): IGlobalConfig;
|
||||
}
|
||||
}
|
||||
@@ -2,6 +2,14 @@
|
||||
|
||||
var app = angular.module('at', ['pascalprecht.translate']);
|
||||
|
||||
app.factory('customLoader', ($q:angular.IQService) => {
|
||||
return (options:any) => {
|
||||
var dfd:angular.IDeferred<string> = $q.defer();
|
||||
dfd.resolve('whatever you wanted to translate, I simply know nothing about the language with the key ' + options.key);
|
||||
return dfd.promise;
|
||||
}
|
||||
});
|
||||
|
||||
app.config(($translateProvider: angular.translate.ITranslateProvider) => {
|
||||
$translateProvider.translations('en', {
|
||||
TITLE: 'Hello',
|
||||
@@ -16,6 +24,8 @@ app.config(($translateProvider: angular.translate.ITranslateProvider) => {
|
||||
BUTTON_LANG_DE: 'deutsch'
|
||||
});
|
||||
$translateProvider.preferredLanguage('en');
|
||||
|
||||
$translateProvider.useLoader('customLoader');
|
||||
});
|
||||
|
||||
interface Scope extends ng.IScope {
|
||||
|
||||
+2
-2
@@ -13,7 +13,7 @@ declare module "angular-translate" {
|
||||
declare module angular.translate {
|
||||
|
||||
interface ITranslationTable {
|
||||
[key: string]: string;
|
||||
[key: string]: any;
|
||||
}
|
||||
|
||||
interface ILanguageKeyAlias {
|
||||
@@ -93,7 +93,7 @@ declare module angular.translate {
|
||||
storageKey(key: string): void; // JeroMiya - the library should probably return ITranslateProvider but it doesn't here
|
||||
useUrlLoader(url: string): ITranslateProvider;
|
||||
useStaticFilesLoader(options: IStaticFilesLoaderOptions): ITranslateProvider;
|
||||
useLoader(loaderFactory: string, options: any): ITranslateProvider;
|
||||
useLoader(loaderFactory: string, options?: any): ITranslateProvider;
|
||||
useLocalStorage(): ITranslateProvider;
|
||||
useCookieStorage(): ITranslateProvider;
|
||||
useStorage(storageFactory: any): ITranslateProvider;
|
||||
|
||||
@@ -7,6 +7,7 @@ testApp.config((
|
||||
$buttonConfig: ng.ui.bootstrap.IButtonConfig,
|
||||
$datepickerConfig: ng.ui.bootstrap.IDatepickerConfig,
|
||||
$datepickerPopupConfig: ng.ui.bootstrap.IDatepickerPopupConfig,
|
||||
$modalProvider: ng.ui.bootstrap.IModalProvider,
|
||||
$paginationConfig: ng.ui.bootstrap.IPaginationConfig,
|
||||
$pagerConfig: ng.ui.bootstrap.IPagerConfig,
|
||||
$progressConfig: ng.ui.bootstrap.IProgressConfig,
|
||||
@@ -30,19 +31,25 @@ testApp.config((
|
||||
/**
|
||||
* $datepickerConfig tests
|
||||
*/
|
||||
$datepickerConfig.dayFormat = 'd';
|
||||
$datepickerConfig.dayHeaderFormat = 'E';
|
||||
$datepickerConfig.dayTitleFormat = 'dd-MM-yyyy';
|
||||
$datepickerConfig.datepickerMode = 'month';
|
||||
$datepickerConfig.formatDay = 'd';
|
||||
$datepickerConfig.formatDayHeader = 'E';
|
||||
$datepickerConfig.formatDayTitle = 'dd-MM-yyyy';
|
||||
$datepickerConfig.formatMonth = 'M';
|
||||
$datepickerConfig.formatMonthTitle = 'yy';
|
||||
$datepickerConfig.formatYear = 'y';
|
||||
$datepickerConfig.maxDate = '1389586124979';
|
||||
$datepickerConfig.maxMode = 'month';
|
||||
$datepickerConfig.minDate = '1389586124979';
|
||||
$datepickerConfig.monthFormat = 'M';
|
||||
$datepickerConfig.monthTitleFormat = 'yy';
|
||||
$datepickerConfig.minMode = 'month';
|
||||
$datepickerConfig.shortcutPropagation = true;
|
||||
$datepickerConfig.showWeeks = false;
|
||||
$datepickerConfig.startingDay = 1;
|
||||
$datepickerConfig.yearFormat = 'y';
|
||||
$datepickerConfig.yearRange = 10;
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* $datepickerPopupConfig tests
|
||||
*/
|
||||
@@ -51,9 +58,18 @@ testApp.config((
|
||||
$datepickerPopupConfig.clearText = 'Reset Selection';
|
||||
$datepickerPopupConfig.closeOnDateSelection = false;
|
||||
$datepickerPopupConfig.closeText = 'Finished';
|
||||
$datepickerPopupConfig.dateFormat = 'dd-MM-yyyy';
|
||||
$datepickerPopupConfig.datepickerPopup = 'dd-MM-yyyy';
|
||||
$datepickerPopupConfig.datepickerPopupTemplateUrl = 'template.html';
|
||||
$datepickerPopupConfig.datepickerTemplateUrl = 'template.html';
|
||||
$datepickerPopupConfig.html5Types.date = 'MM-dd-yyyy';
|
||||
$datepickerPopupConfig.onOpenFocus = false;
|
||||
$datepickerPopupConfig.showButtonBar = false;
|
||||
$datepickerPopupConfig.toggleWeeksText = 'Show Weeks';
|
||||
|
||||
|
||||
/**
|
||||
* $modalProvider tests
|
||||
*/
|
||||
$modalProvider.options.animation = false;
|
||||
|
||||
|
||||
/**
|
||||
@@ -64,9 +80,13 @@ testApp.config((
|
||||
$paginationConfig.firstText = 'First Page';
|
||||
$paginationConfig.itemsPerPage = 25;
|
||||
$paginationConfig.lastText = 'Last Page';
|
||||
$paginationConfig.maxSize = 13;
|
||||
$paginationConfig.numPages = 13;
|
||||
$paginationConfig.nextText = 'Next Page';
|
||||
$paginationConfig.previousText = 'Previous Page';
|
||||
$paginationConfig.rotate = false;
|
||||
$paginationConfig.templateUrl = 'template.html';
|
||||
$paginationConfig.totalItems = 13;
|
||||
|
||||
|
||||
/**
|
||||
@@ -91,6 +111,7 @@ testApp.config((
|
||||
$ratingConfig.max = 10;
|
||||
$ratingConfig.stateOff = 'rating-state-off';
|
||||
$ratingConfig.stateOn = 'rating-state-on';
|
||||
$ratingConfig.titles = ['1', '2', '3', '4', '5'];
|
||||
|
||||
|
||||
/**
|
||||
@@ -102,6 +123,8 @@ testApp.config((
|
||||
$timepickerConfig.mousewheel = false;
|
||||
$timepickerConfig.readonlyInput = true;
|
||||
$timepickerConfig.showMeridian = false;
|
||||
$timepickerConfig.arrowkeys = false;
|
||||
$timepickerConfig.showSpinners = false;
|
||||
|
||||
/**
|
||||
* $tooltipProvider tests
|
||||
@@ -110,7 +133,9 @@ testApp.config((
|
||||
placement: 'bottom',
|
||||
animation: false,
|
||||
popupDelay: 1000,
|
||||
appendtoBody: true
|
||||
appendToBody: true,
|
||||
trigger: 'mouseenter hover',
|
||||
useContentExp: true
|
||||
});
|
||||
$tooltipProvider.setTriggers({
|
||||
'customOpenTrigger': 'customCloseTrigger'
|
||||
@@ -129,10 +154,14 @@ testApp.controller('TestCtrl', (
|
||||
* test the $modal service
|
||||
*/
|
||||
var modalInstance = $modal.open({
|
||||
animation: false,
|
||||
backdrop: 'static',
|
||||
backdropClass: 'modal-backdrop-test',
|
||||
bindToController: true,
|
||||
controller: 'ModalTestCtrl',
|
||||
controllerAs: 'vm',
|
||||
keyboard: true,
|
||||
openedClass: 'modal-open my-modal',
|
||||
resolve: {
|
||||
items: ()=> {
|
||||
return [1, 2, 3, 4, 5];
|
||||
@@ -141,7 +170,6 @@ testApp.controller('TestCtrl', (
|
||||
scope: $scope,
|
||||
template: "<div>i'm a template!</div>",
|
||||
templateUrl: '/templates/modal.html',
|
||||
backdropClass: 'modal-backdrop-test',
|
||||
windowClass: 'modal-test'
|
||||
});
|
||||
|
||||
@@ -149,12 +177,23 @@ testApp.controller('TestCtrl', (
|
||||
$log.log('modal opened');
|
||||
});
|
||||
|
||||
modalInstance.rendered.then(() => {
|
||||
$log.log('modal rendered');
|
||||
});
|
||||
|
||||
modalInstance.result.then((closeResult:any)=> {
|
||||
$log.log('modal closed', closeResult);
|
||||
}, (dismissResult:any)=> {
|
||||
$log.log('modal dismissed', dismissResult);
|
||||
});
|
||||
|
||||
$modal.open({
|
||||
backdrop: 'static'
|
||||
});
|
||||
|
||||
$modal.open({
|
||||
templateUrl: () => '/templates/modal.html'
|
||||
});
|
||||
|
||||
/**
|
||||
* test the $modalStack service
|
||||
|
||||
+157
-69
@@ -1,4 +1,4 @@
|
||||
// Type definitions for Angular UI Bootstrap 0.11.0
|
||||
// Type definitions for Angular UI Bootstrap 0.13.3
|
||||
// Project: https://github.com/angular-ui/bootstrap
|
||||
// Definitions by: Brian Surowiec <https://github.com/xt0rted>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
@@ -36,42 +36,63 @@ declare module angular.ui.bootstrap {
|
||||
*
|
||||
* @default 'dd'
|
||||
*/
|
||||
dayFormat?: string;
|
||||
formatDay?: string;
|
||||
|
||||
/**
|
||||
* Format of month in year.
|
||||
*
|
||||
* @default 'MMM'
|
||||
*/
|
||||
monthFormat?: string;
|
||||
formatMonth?: string;
|
||||
|
||||
/**
|
||||
* Format of year in year range.
|
||||
*
|
||||
* @default 'yyyy'
|
||||
*/
|
||||
yearFormat?: string;
|
||||
formatYear?: string;
|
||||
|
||||
/**
|
||||
* Format of day in week header.
|
||||
*
|
||||
* @default 'EEE'
|
||||
*/
|
||||
dayHeaderFormat?: string;
|
||||
formatDayHeader?: string;
|
||||
|
||||
/**
|
||||
* Format of title when selecting day.
|
||||
*
|
||||
* @default 'MMM yyyy'
|
||||
*/
|
||||
dayTitleFormat?: string;
|
||||
formatDayTitle?: string;
|
||||
|
||||
/**
|
||||
* Format of title when selecting month.
|
||||
*
|
||||
* @default 'yyyy'
|
||||
*/
|
||||
monthTitleFormat?: string;
|
||||
formatMonthTitle?: string;
|
||||
|
||||
/**
|
||||
* Current mode of the datepicker (day|month|year). Can be used to initialize datepicker to specific mode.
|
||||
*
|
||||
* @default 'day'
|
||||
*/
|
||||
datepickerMode?: string;
|
||||
|
||||
/**
|
||||
* Set a lower limit for mode.
|
||||
*
|
||||
* @default 'day'
|
||||
*/
|
||||
minMode?: string;
|
||||
|
||||
/**
|
||||
* Set an upper limit for mode.
|
||||
*
|
||||
* @default 'year'
|
||||
*/
|
||||
maxMode?: string;
|
||||
|
||||
/**
|
||||
* Whether to display week numbers.
|
||||
@@ -107,6 +128,13 @@ declare module angular.ui.bootstrap {
|
||||
* @default null
|
||||
*/
|
||||
maxDate?: any;
|
||||
|
||||
/**
|
||||
* An option to disable or enable shortcut's event propagation
|
||||
*
|
||||
* @default false
|
||||
*/
|
||||
shortcutPropagation?: boolean;
|
||||
}
|
||||
|
||||
interface IDatepickerPopupConfig {
|
||||
@@ -115,7 +143,30 @@ declare module angular.ui.bootstrap {
|
||||
*
|
||||
* @default 'yyyy-MM-dd'
|
||||
*/
|
||||
dateFormat?: string;
|
||||
datepickerPopup?: string;
|
||||
|
||||
/**
|
||||
* Allows overriding of default template of the popup.
|
||||
*
|
||||
* @default 'template/datepicker/popup.html'
|
||||
*/
|
||||
datepickerPopupTemplateUrl?: string;
|
||||
|
||||
/**
|
||||
* Allows overriding of default template of the datepicker used in popup.
|
||||
*
|
||||
* @default 'template/datepicker/popup.html'
|
||||
*/
|
||||
datepickerTemplateUrl?: string;
|
||||
|
||||
/**
|
||||
* Allows overriding of the default format for html5 date inputs.
|
||||
*/
|
||||
html5Types?: {
|
||||
date?: string;
|
||||
'datetime-local'?: string;
|
||||
month?: string;
|
||||
};
|
||||
|
||||
/**
|
||||
* The text to display for the current day button.
|
||||
@@ -124,13 +175,6 @@ declare module angular.ui.bootstrap {
|
||||
*/
|
||||
currentText?: string;
|
||||
|
||||
/**
|
||||
* The text to display for the toggling week numbers button.
|
||||
*
|
||||
* @default 'Weeks'
|
||||
*/
|
||||
toggleWeeksText?: string;
|
||||
|
||||
/**
|
||||
* The text to display for the clear button.
|
||||
*
|
||||
@@ -165,9 +209,23 @@ declare module angular.ui.bootstrap {
|
||||
* @default true
|
||||
*/
|
||||
showButtonBar?: boolean;
|
||||
|
||||
/**
|
||||
* Whether to focus the datepicker popup upon opening.
|
||||
*
|
||||
* @default true
|
||||
*/
|
||||
onOpenFocus?: boolean;
|
||||
}
|
||||
|
||||
|
||||
interface IModalProvider {
|
||||
/**
|
||||
* Default options all modals will use.
|
||||
*/
|
||||
options: IModalSettings;
|
||||
}
|
||||
|
||||
interface IModalService {
|
||||
/**
|
||||
* @param {IModalSettings} options
|
||||
@@ -178,47 +236,52 @@ declare module angular.ui.bootstrap {
|
||||
|
||||
interface IModalServiceInstance {
|
||||
/**
|
||||
* a method that can be used to close a modal, passing a result
|
||||
* A method that can be used to close a modal, passing a result. If `preventDefault` is called on the `modal.closing` event then the modal will remain open.
|
||||
*/
|
||||
close(result?: any): void;
|
||||
|
||||
/**
|
||||
* a method that can be used to dismiss a modal, passing a reason
|
||||
* A method that can be used to dismiss a modal, passing a reason. If `preventDefault` is called on the `modal.closing` event then the modal will remain open.
|
||||
*/
|
||||
dismiss(reason?: any): void;
|
||||
|
||||
/**
|
||||
* a promise that is resolved when a modal is closed and rejected when a modal is dismissed
|
||||
* A promise that is resolved when a modal is closed and rejected when a modal is dismissed.
|
||||
*/
|
||||
result: angular.IPromise<any>;
|
||||
|
||||
/**
|
||||
* a promise that is resolved when a modal gets opened after downloading content's template and resolving all variables
|
||||
* A promise that is resolved when a modal gets opened after downloading content's template and resolving all variables.
|
||||
*/
|
||||
opened: angular.IPromise<any>;
|
||||
|
||||
/**
|
||||
* A promise that is resolved when a modal is rendered.
|
||||
*/
|
||||
rendered: angular.IPromise<any>;
|
||||
}
|
||||
|
||||
interface IModalScope extends angular.IScope {
|
||||
/**
|
||||
* Those methods make it easy to close a modal window without a need to create a dedicated controller
|
||||
* Dismiss the dialog without assigning a value to the promise output. If `preventDefault` is called on the `modal.closing` event then the modal will remain open.
|
||||
*
|
||||
* @returns true if the modal was closed; otherwise false
|
||||
*/
|
||||
$dismiss(reason?: any): boolean;
|
||||
|
||||
/**
|
||||
* Dismiss the dialog without assigning a value to the promise output
|
||||
* Close the dialog resolving the promise to the given value. If `preventDefault` is called on the `modal.closing` event then the modal will remain open.
|
||||
*
|
||||
* @returns true if the modal was closed; otherwise false
|
||||
*/
|
||||
$dismiss(reason?: any): void;
|
||||
|
||||
/**
|
||||
* Close the dialog resolving the promise to the given value
|
||||
*/
|
||||
$close(result?: any): void;
|
||||
$close(result?: any): boolean;
|
||||
}
|
||||
|
||||
interface IModalSettings {
|
||||
/**
|
||||
* a path to a template representing modal's content
|
||||
*/
|
||||
templateUrl?: string;
|
||||
templateUrl?: string | (() => string);
|
||||
|
||||
/**
|
||||
* inline template representing the modal's content
|
||||
@@ -243,11 +306,25 @@ declare module angular.ui.bootstrap {
|
||||
*/
|
||||
controllerAs?: string;
|
||||
|
||||
/**
|
||||
* When used with controllerAs and set to true, it will bind the controller properties onto the $scope directly.
|
||||
*
|
||||
* @default false
|
||||
*/
|
||||
bindToController?: boolean;
|
||||
|
||||
/**
|
||||
* members that will be resolved and passed to the controller as locals; it is equivalent of the `resolve` property for AngularJS routes
|
||||
*/
|
||||
resolve?: any;
|
||||
|
||||
/**
|
||||
* Set to false to disable animations on new modal/backdrop. Does not toggle animations for modals/backdrops that are already displayed.
|
||||
*
|
||||
* @default true
|
||||
*/
|
||||
animation?: boolean;
|
||||
|
||||
/**
|
||||
* controls the presence of a backdrop
|
||||
* Allowed values:
|
||||
@@ -257,10 +334,12 @@ declare module angular.ui.bootstrap {
|
||||
*
|
||||
* @default true
|
||||
*/
|
||||
backdrop?: any;
|
||||
backdrop?: boolean | string;
|
||||
|
||||
/**
|
||||
* indicates whether the dialog should be closable by hitting the ESC key, defaults to true
|
||||
* indicates whether the dialog should be closable by hitting the ESC key
|
||||
*
|
||||
* @default true
|
||||
*/
|
||||
keyboard?: boolean;
|
||||
|
||||
@@ -275,7 +354,7 @@ declare module angular.ui.bootstrap {
|
||||
windowClass?: string;
|
||||
|
||||
/**
|
||||
* optional size of modal window. Allowed values: 'sm' (small) or 'lg' (large). Requires Bootstrap 3.1.0 or later
|
||||
* Optional suffix of modal window class. The value used is appended to the `modal-` class, i.e. a value of `sm` gives `modal-sm`.
|
||||
*/
|
||||
size?: string;
|
||||
|
||||
@@ -283,6 +362,13 @@ declare module angular.ui.bootstrap {
|
||||
* a path to a template overriding modal's window template
|
||||
*/
|
||||
windowTemplateUrl?: string;
|
||||
|
||||
/**
|
||||
* The class added to the body element when the modal is opened.
|
||||
*
|
||||
* @default 'model-open'
|
||||
*/
|
||||
openedClass?: string;
|
||||
}
|
||||
|
||||
interface IModalStackService {
|
||||
@@ -319,11 +405,6 @@ declare module angular.ui.bootstrap {
|
||||
|
||||
|
||||
interface IPaginationConfig {
|
||||
/**
|
||||
* Current page number. First page is 1.
|
||||
*/
|
||||
page?: number;
|
||||
|
||||
/**
|
||||
* Total number of items in all pages.
|
||||
*/
|
||||
@@ -357,13 +438,6 @@ declare module angular.ui.bootstrap {
|
||||
*/
|
||||
rotate?: boolean;
|
||||
|
||||
/**
|
||||
* An optional expression called when a page is selected having the page number as argument.
|
||||
*
|
||||
* @default null
|
||||
*/
|
||||
onSelectPage?(page: number): void;
|
||||
|
||||
/**
|
||||
* Whether to display Previous / Next buttons.
|
||||
*
|
||||
@@ -405,6 +479,13 @@ declare module angular.ui.bootstrap {
|
||||
* @default 'Last'
|
||||
*/
|
||||
lastText?: string;
|
||||
|
||||
/**
|
||||
* Override the template for the component with a custom provided template.
|
||||
*
|
||||
* @default 'template/pagination/pagination.html'
|
||||
*/
|
||||
templateUrl?: string;
|
||||
}
|
||||
|
||||
interface IPagerConfig {
|
||||
@@ -415,16 +496,6 @@ declare module angular.ui.bootstrap {
|
||||
*/
|
||||
align?: boolean;
|
||||
|
||||
/**
|
||||
* Current page number. First page is 1.
|
||||
*/
|
||||
page?: number;
|
||||
|
||||
/**
|
||||
* Total number of items in all pages.
|
||||
*/
|
||||
totalItems?: number;
|
||||
|
||||
/**
|
||||
* Maximum number of items per page. A value less than one indicates all items on one page.
|
||||
*
|
||||
@@ -432,20 +503,6 @@ declare module angular.ui.bootstrap {
|
||||
*/
|
||||
itemsPerPage?: number;
|
||||
|
||||
/**
|
||||
* An optional expression assigned the total number of pages to display.
|
||||
*
|
||||
* @default angular.noop
|
||||
*/
|
||||
numPages?: number;
|
||||
|
||||
/**
|
||||
* An optional expression called when a page is selected having the page number as argument.
|
||||
*
|
||||
* @default null
|
||||
*/
|
||||
onSelectPage?(page: number): void;
|
||||
|
||||
/**
|
||||
* Text for Previous button.
|
||||
*
|
||||
@@ -520,6 +577,13 @@ declare module angular.ui.bootstrap {
|
||||
* @default: null
|
||||
*/
|
||||
stateOff?: string;
|
||||
|
||||
/**
|
||||
* An array of strings defining titles for all icons.
|
||||
*
|
||||
* @default: ["one", "two", "three", "four", "five"]
|
||||
*/
|
||||
titles?: Array<string>;
|
||||
}
|
||||
|
||||
|
||||
@@ -565,6 +629,20 @@ declare module angular.ui.bootstrap {
|
||||
* @default true
|
||||
*/
|
||||
mousewheel?: boolean;
|
||||
|
||||
/**
|
||||
* Whether the user can use up/down arrowkeys inside the hours & minutes input to increase or decrease it's values.
|
||||
*
|
||||
* @default true
|
||||
*/
|
||||
arrowkeys?: boolean;
|
||||
|
||||
/**
|
||||
* Shows spinner arrows above and below the inputs.
|
||||
*
|
||||
* @default true
|
||||
*/
|
||||
showSpinners?: boolean;
|
||||
}
|
||||
|
||||
|
||||
@@ -577,7 +655,7 @@ declare module angular.ui.bootstrap {
|
||||
placement?: string;
|
||||
|
||||
/**
|
||||
* Should it fade in and out?
|
||||
* Should the modal fade in and out?
|
||||
*
|
||||
* @default true
|
||||
*/
|
||||
@@ -598,11 +676,18 @@ declare module angular.ui.bootstrap {
|
||||
appendToBody?: boolean;
|
||||
|
||||
/**
|
||||
* Determines the default open triggers for tooltips and popovers
|
||||
* What should trigger a show of the tooltip? Supports a space separated list of event names.
|
||||
*
|
||||
* @default 'mouseenter' for tooltip, 'click' for popover
|
||||
*/
|
||||
trigger?: string;
|
||||
|
||||
/**
|
||||
* Should an expression on the scope be used to load the content?
|
||||
*
|
||||
* @default false
|
||||
*/
|
||||
useContentExp?: boolean;
|
||||
}
|
||||
|
||||
interface ITooltipProvider {
|
||||
@@ -618,6 +703,9 @@ declare module angular.ui.bootstrap {
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* WARNING: $transition is now deprecated. Use $animate from ngAnimate instead.
|
||||
*/
|
||||
interface ITransitionService {
|
||||
/**
|
||||
* The browser specific animation event name.
|
||||
|
||||
@@ -50,7 +50,7 @@ myApp.config((
|
||||
.state('state1.list', {
|
||||
url: "/list",
|
||||
templateUrl: "partials/state1.list.html",
|
||||
controller: function ($scope: MyAppScope) {
|
||||
controller: function ($scope: MyAppScope) {
|
||||
$scope.items = ["A", "List", "Of", "Items"];
|
||||
}
|
||||
})
|
||||
@@ -61,7 +61,7 @@ myApp.config((
|
||||
.state('state2.list', {
|
||||
url: "/list",
|
||||
templateUrl: "partials/state2.list.html",
|
||||
controller: function ($scope: MyAppScope) {
|
||||
controller: function ($scope: MyAppScope) {
|
||||
$scope.things = ["A", "Set", "Of", "Things"];
|
||||
}
|
||||
})
|
||||
@@ -70,7 +70,14 @@ myApp.config((
|
||||
url: "/list",
|
||||
templateUrl: "partials/state3.list.html",
|
||||
controller: function ($scope: MyAppScope) {
|
||||
$scope.things = ["A", "Set", "Of", "Things"];
|
||||
$scope.things = ["A", "Set", "Of", "Things"];
|
||||
}
|
||||
})
|
||||
.state('state4', {
|
||||
url: "/state4",
|
||||
templateUrl: function($stateParams: ng.ui.IStateParamsService){
|
||||
//Logic could go here based on $stateParams
|
||||
return "partials/state4.html";
|
||||
}
|
||||
})
|
||||
.state('index', {
|
||||
@@ -148,6 +155,10 @@ class UrlLocatorTestService implements IUrlLocatorTestService {
|
||||
this.$state.get("myState");
|
||||
this.$state.get();
|
||||
this.$state.reload();
|
||||
|
||||
// Accesses the currently resolved values for the current state
|
||||
// http://stackoverflow.com/questions/28026620/is-there-a-way-to-access-resolved-state-dependencies-besides-injecting-them-into/28027023#28027023
|
||||
var resolvedValues = this.$state.$current.locals.globals;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+21
-4
@@ -5,6 +5,12 @@
|
||||
|
||||
/// <reference path="../angularjs/angular.d.ts" />
|
||||
|
||||
// Support for AMD require
|
||||
declare module 'angular-ui-router' {
|
||||
var _: string;
|
||||
export = _;
|
||||
}
|
||||
|
||||
declare module angular.ui {
|
||||
|
||||
interface IState {
|
||||
@@ -16,7 +22,7 @@ declare module angular.ui {
|
||||
/**
|
||||
* String URL path to template file OR Function, returns URL path string
|
||||
*/
|
||||
templateUrl?: string | {(): string};
|
||||
templateUrl?: string | {(params: IStateParamsService): string};
|
||||
/**
|
||||
* Function, returns HTML content string
|
||||
*/
|
||||
@@ -53,12 +59,12 @@ declare module angular.ui {
|
||||
abstract?: boolean;
|
||||
/**
|
||||
* Callback function for when a state is entered. Good way to trigger an action or dispatch an event, such as opening a dialog.
|
||||
* If minifying your scripts, make sure to explictly annotate this function, because it won't be automatically annotated by your build tools.
|
||||
* If minifying your scripts, make sure to explicitly annotate this function, because it won't be automatically annotated by your build tools.
|
||||
*/
|
||||
onEnter?: Function|(string|Function)[];
|
||||
/**
|
||||
* Callback functions for when a state is entered and exited. Good way to trigger an action or dispatch an event, such as opening a dialog.
|
||||
* If minifying your scripts, make sure to explictly annotate this function, because it won't be automatically annotated by your build tools.
|
||||
* If minifying your scripts, make sure to explicitly annotate this function, because it won't be automatically annotated by your build tools.
|
||||
*/
|
||||
onExit?: Function|(string|Function)[];
|
||||
/**
|
||||
@@ -66,7 +72,7 @@ declare module angular.ui {
|
||||
*/
|
||||
data?: any;
|
||||
/**
|
||||
* Boolean (default true). If false will not retrigger the same state just because a search/query parameter has changed. Useful for when you'd like to modify $location.search() without triggering a reload.
|
||||
* Boolean (default true). If false will not re-trigger the same state just because a search/query parameter has changed. Useful for when you'd like to modify $location.search() without triggering a reload.
|
||||
*/
|
||||
reloadOnSearch?: boolean;
|
||||
}
|
||||
@@ -168,6 +174,17 @@ declare module angular.ui {
|
||||
current: IState;
|
||||
params: IStateParamsService;
|
||||
reload(): void;
|
||||
|
||||
$current: IResolvedState;
|
||||
}
|
||||
|
||||
interface IResolvedState {
|
||||
locals: {
|
||||
/**
|
||||
* Currently resolved "resolve" values from the current state
|
||||
*/
|
||||
globals: { [key: string]: any; };
|
||||
};
|
||||
}
|
||||
|
||||
interface IStateParamsService {
|
||||
|
||||
+6310
File diff suppressed because it is too large
Load Diff
+6564
File diff suppressed because it is too large
Load Diff
Vendored
+2237
-1716
File diff suppressed because it is too large
Load Diff
Vendored
+469
@@ -0,0 +1,469 @@
|
||||
// Type definitions for Angular v2.0.0-alpha.34
|
||||
// Project: http://angular.io/
|
||||
// Definitions by: angular team <https://github.com/angular/>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
// ***********************************************************
|
||||
// This file is generated by the Angular build process.
|
||||
// Please do not create manual edits or send pull requests
|
||||
// modifying this file.
|
||||
// ***********************************************************
|
||||
///<reference path="./angular2-2.0.0-alpha.34.d.ts"/>
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* @module
|
||||
* @description
|
||||
* Maps application URLs into application states, to support deep-linking and navigation.
|
||||
*/
|
||||
declare module ng {
|
||||
|
||||
/**
|
||||
* # Router
|
||||
* The router is responsible for mapping URLs to components.
|
||||
*
|
||||
* You can see the state of the router by inspecting the read-only field `router.navigating`.
|
||||
* This may be useful for showing a spinner, for instance.
|
||||
*
|
||||
* ## Concepts
|
||||
* Routers and component instances have a 1:1 correspondence.
|
||||
*
|
||||
* The router holds reference to a number of "outlets." An outlet is a placeholder that the
|
||||
* router dynamically fills in depending on the current URL.
|
||||
*
|
||||
* When the router navigates from a URL, it must first recognizes it and serialize it into an
|
||||
* `Instruction`.
|
||||
* The router uses the `RouteRegistry` to get an `Instruction`.
|
||||
*/
|
||||
class Router {
|
||||
|
||||
navigating: boolean;
|
||||
|
||||
lastNavigationAttempt: string;
|
||||
|
||||
registry: RouteRegistry;
|
||||
|
||||
parent: Router;
|
||||
|
||||
hostComponent: any;
|
||||
|
||||
|
||||
/**
|
||||
* Constructs a child router. You probably don't need to use this unless you're writing a reusable
|
||||
* component.
|
||||
*/
|
||||
childRouter(hostComponent: any): Router;
|
||||
|
||||
|
||||
/**
|
||||
* Register an object to notify of route changes. You probably don't need to use this unless
|
||||
* you're writing a reusable component.
|
||||
*/
|
||||
registerOutlet(outlet: RouterOutlet): Promise<boolean>;
|
||||
|
||||
|
||||
/**
|
||||
* Dynamically update the routing configuration and trigger a navigation.
|
||||
*
|
||||
* # Usage
|
||||
*
|
||||
* ```
|
||||
* router.config([
|
||||
* { 'path': '/', 'component': IndexComp },
|
||||
* { 'path': '/user/:id', 'component': UserComp },
|
||||
* ]);
|
||||
* ```
|
||||
*/
|
||||
config(definitions: List<RouteDefinition>): Promise<any>;
|
||||
|
||||
|
||||
/**
|
||||
* Navigate to a URL. Returns a promise that resolves when navigation is complete.
|
||||
*
|
||||
* If the given URL begins with a `/`, router will navigate absolutely.
|
||||
* If the given URL does not begin with `/`, the router will navigate relative to this component.
|
||||
*/
|
||||
navigate(url: string, _skipLocationChange?: boolean): Promise<any>;
|
||||
|
||||
|
||||
/**
|
||||
* Updates this router and all descendant routers according to the given instruction
|
||||
*/
|
||||
commit(instruction: Instruction, _skipLocationChange?: boolean): Promise<any>;
|
||||
|
||||
|
||||
/**
|
||||
* Subscribe to URL updates from the router
|
||||
*/
|
||||
subscribe(onNext: (value: any) => void): void;
|
||||
|
||||
|
||||
/**
|
||||
* Removes the contents of this router's outlet and all descendant outlets
|
||||
*/
|
||||
deactivate(instruction: Instruction): Promise<any>;
|
||||
|
||||
|
||||
/**
|
||||
* Given a URL, returns an instruction representing the component graph
|
||||
*/
|
||||
recognize(url: string): Promise<Instruction>;
|
||||
|
||||
|
||||
/**
|
||||
* Navigates to either the last URL successfully navigated to, or the last URL requested if the
|
||||
* router has yet to successfully navigate.
|
||||
*/
|
||||
renavigate(): Promise<any>;
|
||||
|
||||
|
||||
/**
|
||||
* Generate a URL from a component name and optional map of parameters. The URL is relative to the
|
||||
* app's base href.
|
||||
*/
|
||||
generate(linkParams: List<any>): string;
|
||||
}
|
||||
|
||||
class RootRouter extends Router {
|
||||
|
||||
commit(instruction: Instruction, _skipLocationChange?: boolean): Promise<any>;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* A router outlet is a placeholder that Angular dynamically fills based on the application's route.
|
||||
*
|
||||
* ## Use
|
||||
*
|
||||
* ```
|
||||
* <router-outlet></router-outlet>
|
||||
* ```
|
||||
*/
|
||||
class RouterOutlet {
|
||||
|
||||
childRouter: Router;
|
||||
|
||||
|
||||
/**
|
||||
* Given an instruction, update the contents of this outlet.
|
||||
*/
|
||||
commit(instruction: Instruction): Promise<any>;
|
||||
|
||||
|
||||
/**
|
||||
* Called by Router during recognition phase
|
||||
*/
|
||||
canDeactivate(nextInstruction: Instruction): Promise<boolean>;
|
||||
|
||||
|
||||
/**
|
||||
* Called by Router during recognition phase
|
||||
*/
|
||||
canReuse(nextInstruction: Instruction): Promise<boolean>;
|
||||
|
||||
deactivate(nextInstruction: Instruction): Promise<any>;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* The RouterLink directive lets you link to specific parts of your app.
|
||||
*
|
||||
* Consider the following route configuration:
|
||||
*
|
||||
* ```
|
||||
* @RouteConfig([
|
||||
* { path: '/user', component: UserCmp, as: 'user' }
|
||||
* ]);
|
||||
* class MyComp {}
|
||||
* ```
|
||||
*
|
||||
* When linking to this `user` route, you can write:
|
||||
*
|
||||
* ```
|
||||
* <a [router-link]="['./user']">link to user component</a>
|
||||
* ```
|
||||
*
|
||||
* RouterLink expects the value to be an array of route names, followed by the params
|
||||
* for that level of routing. For instance `['/team', {teamId: 1}, 'user', {userId: 2}]`
|
||||
* means that we want to generate a link for the `team` route with params `{teamId: 1}`,
|
||||
* and with a child route `user` with params `{userId: 2}`.
|
||||
*
|
||||
* The first route name should be prepended with `/`, `./`, or `../`.
|
||||
* If the route begins with `/`, the router will look up the route from the root of the app.
|
||||
* If the route begins with `./`, the router will instead look in the current component's
|
||||
* children for the route. And if the route begins with `../`, the router will look at the
|
||||
* current component's parent.
|
||||
*/
|
||||
class RouterLink {
|
||||
|
||||
visibleHref: string;
|
||||
|
||||
routeParams: void;
|
||||
|
||||
onClick(): boolean;
|
||||
}
|
||||
|
||||
class RouteParams {
|
||||
|
||||
params: StringMap<string, string>;
|
||||
|
||||
get(param: string): string;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* The RouteRegistry holds route configurations for each component in an Angular app.
|
||||
* It is responsible for creating Instructions from URLs, and generating URLs based on route and
|
||||
* parameters.
|
||||
*/
|
||||
class RouteRegistry {
|
||||
|
||||
|
||||
/**
|
||||
* Given a component and a configuration object, add the route to this registry
|
||||
*/
|
||||
config(parentComponent: any, config: RouteDefinition, isRootLevelRoute?: boolean): void;
|
||||
|
||||
|
||||
/**
|
||||
* Reads the annotations of a component and configures the registry based on them
|
||||
*/
|
||||
configFromComponent(component: any, isRootComponent?: boolean): void;
|
||||
|
||||
|
||||
/**
|
||||
* Given a URL and a parent component, return the most specific instruction for navigating
|
||||
* the application into the state specified by the url
|
||||
*/
|
||||
recognize(url: string, parentComponent: any): Promise<Instruction>;
|
||||
|
||||
|
||||
/**
|
||||
* Given a normalized list with component names and params like: `['user', {id: 3 }]`
|
||||
* generates a url with a leading slash relative to the provided `parentComponent`.
|
||||
*/
|
||||
generate(linkParams: List<any>, parentComponent: any): string;
|
||||
}
|
||||
|
||||
class LocationStrategy {
|
||||
|
||||
path(): string;
|
||||
|
||||
pushState(ctx: any, title: string, url: string): void;
|
||||
|
||||
forward(): void;
|
||||
|
||||
back(): void;
|
||||
|
||||
onPopState(fn: (_: any) => any): void;
|
||||
|
||||
getBaseHref(): string;
|
||||
}
|
||||
|
||||
class HashLocationStrategy extends LocationStrategy {
|
||||
|
||||
onPopState(fn: EventListener): void;
|
||||
|
||||
getBaseHref(): string;
|
||||
|
||||
path(): string;
|
||||
|
||||
pushState(state: any, title: string, url: string): void;
|
||||
|
||||
forward(): void;
|
||||
|
||||
back(): void;
|
||||
}
|
||||
|
||||
class HTML5LocationStrategy extends LocationStrategy {
|
||||
|
||||
onPopState(fn: EventListener): void;
|
||||
|
||||
getBaseHref(): string;
|
||||
|
||||
path(): string;
|
||||
|
||||
pushState(state: any, title: string, url: string): void;
|
||||
|
||||
forward(): void;
|
||||
|
||||
back(): void;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This is the service that an application developer will directly interact with.
|
||||
*
|
||||
* Responsible for normalizing the URL against the application's base href.
|
||||
* A normalized URL is absolute from the URL host, includes the application's base href, and has no
|
||||
* trailing slash:
|
||||
* - `/my/app/user/123` is normalized
|
||||
* - `my/app/user/123` **is not** normalized
|
||||
* - `/my/app/user/123/` **is not** normalized
|
||||
*/
|
||||
class Location {
|
||||
|
||||
path(): string;
|
||||
|
||||
normalize(url: string): string;
|
||||
|
||||
normalizeAbsolutely(url: string): string;
|
||||
|
||||
go(url: string): void;
|
||||
|
||||
forward(): void;
|
||||
|
||||
back(): void;
|
||||
|
||||
subscribe(onNext: (value: any) => void, onThrow?: (exception: any) => void, onReturn?: () => void): void;
|
||||
}
|
||||
|
||||
const appBaseHrefToken : OpaqueToken ;
|
||||
|
||||
|
||||
/**
|
||||
* Responsible for performing each step of navigation.
|
||||
* "Steps" are conceptually similar to "middleware"
|
||||
*/
|
||||
class Pipeline {
|
||||
|
||||
steps: List<Function>;
|
||||
|
||||
process(instruction: Instruction): Promise<any>;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Defines route lifecycle method [onActivate]
|
||||
*/
|
||||
interface OnActivate {
|
||||
|
||||
onActivate(nextInstruction: Instruction, prevInstruction: Instruction): any;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Defines route lifecycle method [onDeactivate]
|
||||
*/
|
||||
interface OnDeactivate {
|
||||
|
||||
onDeactivate(nextInstruction: Instruction, prevInstruction: Instruction): any;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Defines route lifecycle method [onReuse]
|
||||
*/
|
||||
interface OnReuse {
|
||||
|
||||
onReuse(nextInstruction: Instruction, prevInstruction: Instruction): any;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Defines route lifecycle method [canDeactivate]
|
||||
*/
|
||||
interface CanDeactivate {
|
||||
|
||||
canDeactivate(nextInstruction: Instruction, prevInstruction: Instruction): any;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Defines route lifecycle method [canReuse]
|
||||
*/
|
||||
interface CanReuse {
|
||||
|
||||
canReuse(nextInstruction: Instruction, prevInstruction: Instruction): any;
|
||||
}
|
||||
|
||||
var CanActivate : (hook: (next: Instruction, prev: Instruction) => Promise<boolean>| boolean) => ClassDecorator ;
|
||||
|
||||
|
||||
/**
|
||||
* An `Instruction` represents the component hierarchy of the application based on a given route
|
||||
*/
|
||||
class Instruction {
|
||||
|
||||
accumulatedUrl: string;
|
||||
|
||||
reuse: boolean;
|
||||
|
||||
specificity: number;
|
||||
|
||||
component: any;
|
||||
|
||||
capturedUrl: string;
|
||||
|
||||
child: Instruction;
|
||||
|
||||
params(): StringMap<string, string>;
|
||||
}
|
||||
|
||||
const routerDirectives : List<any> ;
|
||||
|
||||
var routerInjectables : List<any> ;
|
||||
|
||||
class Route implements RouteDefinition {
|
||||
|
||||
path: string;
|
||||
|
||||
component: Type;
|
||||
|
||||
as: string;
|
||||
|
||||
loader: Function;
|
||||
|
||||
redirectTo: string;
|
||||
}
|
||||
|
||||
class Redirect implements RouteDefinition {
|
||||
|
||||
path: string;
|
||||
|
||||
redirectTo: string;
|
||||
|
||||
as: string;
|
||||
}
|
||||
|
||||
class AsyncRoute implements RouteDefinition {
|
||||
|
||||
path: string;
|
||||
|
||||
loader: Function;
|
||||
|
||||
as: string;
|
||||
}
|
||||
|
||||
interface RouteDefinition {
|
||||
|
||||
path: string;
|
||||
|
||||
component?: Type | ComponentDefinition;
|
||||
|
||||
loader?: Function;
|
||||
|
||||
redirectTo?: string;
|
||||
|
||||
as?: string;
|
||||
}
|
||||
|
||||
var RouteConfig : (configs: List<RouteDefinition>) => ClassDecorator ;
|
||||
|
||||
interface ComponentDefinition {
|
||||
|
||||
type: string;
|
||||
|
||||
loader?: Function;
|
||||
|
||||
component?: Type;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
declare module "angular2/router" {
|
||||
export = ng;
|
||||
}
|
||||
|
||||
|
||||
Vendored
+191
-181
@@ -1,4 +1,4 @@
|
||||
// Type definitions for Angular v2.0.0-alpha.31
|
||||
// Type definitions for Angular v2.0.0-alpha.34
|
||||
// Project: http://angular.io/
|
||||
// Definitions by: angular team <https://github.com/angular/>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
@@ -18,120 +18,56 @@
|
||||
* Maps application URLs into application states, to support deep-linking and navigation.
|
||||
*/
|
||||
declare module ng {
|
||||
interface List<T> extends Array<T> {}
|
||||
interface Map<K,V> {}
|
||||
interface StringMap<K,V> extends Map<K,V> {}
|
||||
|
||||
export class Instruction {
|
||||
// "capturedUrl" is the part of the URL captured by this instruction
|
||||
// "accumulatedUrl" is the part of the URL captured by this instruction and all children
|
||||
accumulatedUrl: string;
|
||||
reuse: boolean;
|
||||
specificity: number;
|
||||
|
||||
private _params: StringMap<string, string>;
|
||||
|
||||
constructor (component: any, capturedUrl: string,
|
||||
_recognizer: PathRecognizer, child: Instruction);
|
||||
|
||||
params(): StringMap<string, string>;
|
||||
}
|
||||
|
||||
class TouchMap {
|
||||
map: StringMap<string, string>;
|
||||
keys: StringMap<string, boolean>;
|
||||
|
||||
constructor(map: StringMap<string, any>);
|
||||
|
||||
get(key: string): string;
|
||||
|
||||
getUnused(): StringMap<string, any>;
|
||||
}
|
||||
|
||||
export class Segment {
|
||||
name: string;
|
||||
regex: string;
|
||||
generate(params: TouchMap): string;
|
||||
}
|
||||
|
||||
export class PathRecognizer {
|
||||
segments: List<Segment>;
|
||||
regex: RegExp;
|
||||
specificity: number;
|
||||
terminal: boolean;
|
||||
path: string;
|
||||
handler: RouteHandler;
|
||||
|
||||
constructor(path: string, handler: RouteHandler);
|
||||
|
||||
parseParams(url: string): StringMap<string, string>;
|
||||
|
||||
generate(params: StringMap<string, any>): string;
|
||||
|
||||
resolveComponentType(): Promise<any>;
|
||||
}
|
||||
|
||||
|
||||
export interface RouteHandler {
|
||||
componentType: Function;
|
||||
resolveComponentType(): Promise<any>;
|
||||
}
|
||||
|
||||
/**
|
||||
* # Router
|
||||
* The router is responsible for mapping URLs to components.
|
||||
*
|
||||
*
|
||||
* You can see the state of the router by inspecting the read-only field `router.navigating`.
|
||||
* This may be useful for showing a spinner, for instance.
|
||||
*
|
||||
*
|
||||
* ## Concepts
|
||||
* Routers and component instances have a 1:1 correspondence.
|
||||
*
|
||||
*
|
||||
* The router holds reference to a number of "outlets." An outlet is a placeholder that the
|
||||
* router dynamically fills in depending on the current URL.
|
||||
*
|
||||
*
|
||||
* When the router navigates from a URL, it must first recognizes it and serialize it into an
|
||||
* `Instruction`.
|
||||
* The router uses the `RouteRegistry` to get an `Instruction`.
|
||||
*/
|
||||
class Router {
|
||||
|
||||
|
||||
navigating: boolean;
|
||||
|
||||
|
||||
lastNavigationAttempt: string;
|
||||
|
||||
|
||||
registry: RouteRegistry;
|
||||
|
||||
|
||||
parent: Router;
|
||||
|
||||
|
||||
hostComponent: any;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Constructs a child router. You probably don't need to use this unless you're writing a reusable
|
||||
* component.
|
||||
*/
|
||||
childRouter(hostComponent: any): Router;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Register an object to notify of route changes. You probably don't need to use this unless
|
||||
* you're writing a reusable component.
|
||||
*/
|
||||
registerOutlet(outlet: RouterOutlet): Promise<boolean>;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Dynamically update the routing configuration and trigger a navigation.
|
||||
*
|
||||
*
|
||||
* # Usage
|
||||
*
|
||||
* ```
|
||||
* router.config({ 'path': '/', 'component': IndexCmp});
|
||||
* ```
|
||||
*
|
||||
* Or:
|
||||
*
|
||||
*
|
||||
* ```
|
||||
* router.config([
|
||||
* { 'path': '/', 'component': IndexComp },
|
||||
@@ -139,48 +75,48 @@ declare module ng {
|
||||
* ]);
|
||||
* ```
|
||||
*/
|
||||
config(config: StringMap<string, any>| List<StringMap<string, any>>): Promise<any>;
|
||||
|
||||
config(definitions: List<RouteDefinition>): Promise<any>;
|
||||
|
||||
|
||||
/**
|
||||
* Navigate to a URL. Returns a promise that resolves when navigation is complete.
|
||||
*
|
||||
*
|
||||
* If the given URL begins with a `/`, router will navigate absolutely.
|
||||
* If the given URL does not begin with `/`, the router will navigate relative to this component.
|
||||
*/
|
||||
navigate(url: string): Promise<any>;
|
||||
|
||||
navigate(url: string, _skipLocationChange?: boolean): Promise<any>;
|
||||
|
||||
|
||||
/**
|
||||
* Updates this router and all descendant routers according to the given instruction
|
||||
*/
|
||||
commit(instruction: Instruction): Promise<any>;
|
||||
|
||||
commit(instruction: Instruction, _skipLocationChange?: boolean): Promise<any>;
|
||||
|
||||
|
||||
/**
|
||||
* Subscribe to URL updates from the router
|
||||
*/
|
||||
subscribe(onNext: any): void;
|
||||
|
||||
subscribe(onNext: (value: any) => void): void;
|
||||
|
||||
|
||||
/**
|
||||
* Removes the contents of this router's outlet and all descendant outlets
|
||||
*/
|
||||
deactivate(instruction: Instruction): Promise<any>;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Given a URL, returns an instruction representing the component graph
|
||||
*/
|
||||
recognize(url: string): Promise<Instruction>;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Navigates to either the last URL successfully navigated to, or the last URL requested if the
|
||||
* router has yet to successfully navigate.
|
||||
*/
|
||||
renavigate(): Promise<any>;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Generate a URL from a component name and optional map of parameters. The URL is relative to the
|
||||
@@ -188,71 +124,71 @@ declare module ng {
|
||||
*/
|
||||
generate(linkParams: List<any>): string;
|
||||
}
|
||||
|
||||
|
||||
class RootRouter extends Router {
|
||||
|
||||
commit(instruction: any): Promise<any>;
|
||||
|
||||
commit(instruction: Instruction, _skipLocationChange?: boolean): Promise<any>;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* A router outlet is a placeholder that Angular dynamically fills based on the application's route.
|
||||
*
|
||||
*
|
||||
* ## Use
|
||||
*
|
||||
*
|
||||
* ```
|
||||
* <router-outlet></router-outlet>
|
||||
* ```
|
||||
*/
|
||||
class RouterOutlet {
|
||||
|
||||
|
||||
childRouter: Router;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Given an instruction, update the contents of this outlet.
|
||||
*/
|
||||
commit(instruction: Instruction): Promise<any>;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Called by Router during recognition phase
|
||||
*/
|
||||
canDeactivate(nextInstruction: Instruction): Promise<boolean>;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Called by Router during recognition phase
|
||||
*/
|
||||
canReuse(nextInstruction: Instruction): Promise<boolean>;
|
||||
|
||||
|
||||
deactivate(nextInstruction: Instruction): Promise<any>;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* The RouterLink directive lets you link to specific parts of your app.
|
||||
*
|
||||
*
|
||||
* Consider the following route configuration:
|
||||
*
|
||||
*
|
||||
* ```
|
||||
* @RouteConfig({
|
||||
* path: '/user', component: UserCmp, as: 'user'
|
||||
* });
|
||||
* @RouteConfig([
|
||||
* { path: '/user', component: UserCmp, as: 'user' }
|
||||
* ]);
|
||||
* class MyComp {}
|
||||
* ```
|
||||
*
|
||||
*
|
||||
* When linking to this `user` route, you can write:
|
||||
*
|
||||
*
|
||||
* ```
|
||||
* <a [router-link]="['./user']">link to user component</a>
|
||||
* ```
|
||||
*
|
||||
*
|
||||
* RouterLink expects the value to be an array of route names, followed by the params
|
||||
* for that level of routing. For instance `['/team', {teamId: 1}, 'user', {userId: 2}]`
|
||||
* means that we want to generate a link for the `team` route with params `{teamId: 1}`,
|
||||
* and with a child route `user` with params `{userId: 2}`.
|
||||
*
|
||||
*
|
||||
* The first route name should be prepended with `/`, `./`, or `../`.
|
||||
* If the route begins with `/`, the router will look up the route from the root of the app.
|
||||
* If the route begins with `./`, the router will instead look in the current component's
|
||||
@@ -260,21 +196,21 @@ declare module ng {
|
||||
* current component's parent.
|
||||
*/
|
||||
class RouterLink {
|
||||
|
||||
|
||||
visibleHref: string;
|
||||
|
||||
|
||||
routeParams: void;
|
||||
|
||||
|
||||
onClick(): boolean;
|
||||
}
|
||||
|
||||
|
||||
class RouteParams {
|
||||
|
||||
|
||||
params: StringMap<string, string>;
|
||||
|
||||
|
||||
get(param: string): string;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* The RouteRegistry holds route configurations for each component in an Angular app.
|
||||
@@ -282,26 +218,26 @@ declare module ng {
|
||||
* parameters.
|
||||
*/
|
||||
class RouteRegistry {
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Given a component and a configuration object, add the route to this registry
|
||||
*/
|
||||
config(parentComponent: any, config: StringMap<string, any>): void;
|
||||
|
||||
config(parentComponent: any, config: RouteDefinition, isRootLevelRoute?: boolean): void;
|
||||
|
||||
|
||||
/**
|
||||
* Reads the annotations of a component and configures the registry based on them
|
||||
*/
|
||||
configFromComponent(component: any): void;
|
||||
|
||||
configFromComponent(component: any, isRootComponent?: boolean): void;
|
||||
|
||||
|
||||
/**
|
||||
* Given a URL and a parent component, return the most specific instruction for navigating
|
||||
* the application into the state specified by the url
|
||||
*/
|
||||
recognize(url: string, parentComponent: any): Promise<Instruction>;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Given a normalized list with component names and params like: `['user', {id: 3 }]`
|
||||
@@ -309,56 +245,56 @@ declare module ng {
|
||||
*/
|
||||
generate(linkParams: List<any>, parentComponent: any): string;
|
||||
}
|
||||
|
||||
|
||||
class LocationStrategy {
|
||||
|
||||
|
||||
path(): string;
|
||||
|
||||
|
||||
pushState(ctx: any, title: string, url: string): void;
|
||||
|
||||
|
||||
forward(): void;
|
||||
|
||||
|
||||
back(): void;
|
||||
|
||||
onPopState(fn: any): void;
|
||||
|
||||
|
||||
onPopState(fn: (_: any) => any): void;
|
||||
|
||||
getBaseHref(): string;
|
||||
}
|
||||
|
||||
|
||||
class HashLocationStrategy extends LocationStrategy {
|
||||
|
||||
|
||||
onPopState(fn: EventListener): void;
|
||||
|
||||
|
||||
getBaseHref(): string;
|
||||
|
||||
|
||||
path(): string;
|
||||
|
||||
|
||||
pushState(state: any, title: string, url: string): void;
|
||||
|
||||
|
||||
forward(): void;
|
||||
|
||||
|
||||
back(): void;
|
||||
}
|
||||
|
||||
|
||||
class HTML5LocationStrategy extends LocationStrategy {
|
||||
|
||||
|
||||
onPopState(fn: EventListener): void;
|
||||
|
||||
|
||||
getBaseHref(): string;
|
||||
|
||||
|
||||
path(): string;
|
||||
|
||||
|
||||
pushState(state: any, title: string, url: string): void;
|
||||
|
||||
|
||||
forward(): void;
|
||||
|
||||
|
||||
back(): void;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* This is the service that an application developer will directly interact with.
|
||||
*
|
||||
*
|
||||
* Responsible for normalizing the URL against the application's base href.
|
||||
* A normalized URL is absolute from the URL host, includes the application's base href, and has no
|
||||
* trailing slash:
|
||||
@@ -367,93 +303,167 @@ declare module ng {
|
||||
* - `/my/app/user/123/` **is not** normalized
|
||||
*/
|
||||
class Location {
|
||||
|
||||
|
||||
path(): string;
|
||||
|
||||
|
||||
normalize(url: string): string;
|
||||
|
||||
|
||||
normalizeAbsolutely(url: string): string;
|
||||
|
||||
|
||||
go(url: string): void;
|
||||
|
||||
|
||||
forward(): void;
|
||||
|
||||
|
||||
back(): void;
|
||||
|
||||
subscribe(onNext: any, onThrow?: any, onReturn?: any): void;
|
||||
|
||||
subscribe(onNext: (value: any) => void, onThrow?: (exception: any) => void, onReturn?: () => void): void;
|
||||
}
|
||||
|
||||
var appBaseHrefToken : OpaqueToken ;
|
||||
|
||||
|
||||
const appBaseHrefToken : OpaqueToken ;
|
||||
|
||||
|
||||
/**
|
||||
* Responsible for performing each step of navigation.
|
||||
* "Steps" are conceptually similar to "middleware"
|
||||
*/
|
||||
class Pipeline {
|
||||
|
||||
|
||||
steps: List<Function>;
|
||||
|
||||
|
||||
process(instruction: Instruction): Promise<any>;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Defines route lifecycle method [onActivate]
|
||||
*/
|
||||
interface OnActivate {
|
||||
|
||||
|
||||
onActivate(nextInstruction: Instruction, prevInstruction: Instruction): any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Defines route lifecycle method [onDeactivate]
|
||||
*/
|
||||
interface OnDeactivate {
|
||||
|
||||
|
||||
onDeactivate(nextInstruction: Instruction, prevInstruction: Instruction): any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Defines route lifecycle method [onReuse]
|
||||
*/
|
||||
interface OnReuse {
|
||||
|
||||
|
||||
onReuse(nextInstruction: Instruction, prevInstruction: Instruction): any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Defines route lifecycle method [canDeactivate]
|
||||
*/
|
||||
interface CanDeactivate {
|
||||
|
||||
|
||||
canDeactivate(nextInstruction: Instruction, prevInstruction: Instruction): any;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Defines route lifecycle method [canReuse]
|
||||
*/
|
||||
interface CanReuse {
|
||||
|
||||
|
||||
canReuse(nextInstruction: Instruction, prevInstruction: Instruction): any;
|
||||
}
|
||||
|
||||
var CanActivate : (hook: (next: Instruction, prev: Instruction) => Promise<boolean>| boolean) => ClassDecorator ;
|
||||
|
||||
|
||||
var CanActivate:any;
|
||||
|
||||
var routerDirectives : List<any> ;
|
||||
|
||||
/**
|
||||
* An `Instruction` represents the component hierarchy of the application based on a given route
|
||||
*/
|
||||
class Instruction {
|
||||
|
||||
accumulatedUrl: string;
|
||||
|
||||
reuse: boolean;
|
||||
|
||||
specificity: number;
|
||||
|
||||
component: any;
|
||||
|
||||
capturedUrl: string;
|
||||
|
||||
child: Instruction;
|
||||
|
||||
params(): StringMap<string, string>;
|
||||
}
|
||||
|
||||
const routerDirectives : List<any> ;
|
||||
|
||||
var routerInjectables : List<any> ;
|
||||
|
||||
var RouteConfig:any;
|
||||
|
||||
|
||||
class Route implements RouteDefinition {
|
||||
|
||||
path: string;
|
||||
|
||||
component: Type;
|
||||
|
||||
as: string;
|
||||
|
||||
loader: Function;
|
||||
|
||||
redirectTo: string;
|
||||
}
|
||||
|
||||
class Redirect implements RouteDefinition {
|
||||
|
||||
path: string;
|
||||
|
||||
redirectTo: string;
|
||||
|
||||
as: string;
|
||||
}
|
||||
|
||||
class AsyncRoute implements RouteDefinition {
|
||||
|
||||
path: string;
|
||||
|
||||
loader: Function;
|
||||
|
||||
as: string;
|
||||
}
|
||||
|
||||
interface RouteDefinition {
|
||||
|
||||
path: string;
|
||||
|
||||
component?: Type | ComponentDefinition;
|
||||
|
||||
loader?: Function;
|
||||
|
||||
redirectTo?: string;
|
||||
|
||||
as?: string;
|
||||
}
|
||||
|
||||
var RouteConfig : (configs: List<RouteDefinition>) => ClassDecorator ;
|
||||
|
||||
interface ComponentDefinition {
|
||||
|
||||
type: string;
|
||||
|
||||
loader?: Function;
|
||||
|
||||
component?: Type;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
declare module "angular2/router" {
|
||||
export = ng;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Executable → Regular
+56
-2
@@ -30,7 +30,7 @@ class AuthService {
|
||||
'$rootScope', '$injector', <any>function($rootScope: ng.IScope, $injector: ng.auto.IInjectorService) {
|
||||
var $http: ng.IHttpService; //initialized later because of circular dependency problem
|
||||
function retry(config: ng.IRequestConfig, deferred: ng.IDeferred<any>) {
|
||||
$http = $http || $injector.get('$http');
|
||||
$http = $http || $injector.get<ng.IHttpService>('$http');
|
||||
$http(config).then(function (response) {
|
||||
deferred.resolve(response);
|
||||
});
|
||||
@@ -242,6 +242,18 @@ foo.then((x) => {
|
||||
x.toFixed();
|
||||
});
|
||||
|
||||
// $q signature tests
|
||||
module TestQ {
|
||||
var $q: ng.IQService;
|
||||
var promise1: ng.IPromise<any>;
|
||||
var promise2: ng.IPromise<any>;
|
||||
|
||||
// $q.all
|
||||
$q.all([promise1, promise2]).then((results: any[]) => {});
|
||||
$q.all<number>([promise1, promise2]).then((results: number[]) => {});
|
||||
$q.all({a: promise1, b: promise2}).then((results: {[id: string]: any;}) => {});
|
||||
$q.all<{a: number; b: string;}>({a: promise1, b: promise2}).then((results: {a: number; b: string;}) => {});
|
||||
}
|
||||
|
||||
var httpFoo: ng.IHttpPromise<number>;
|
||||
httpFoo.then((x) => {
|
||||
@@ -260,6 +272,48 @@ httpFoo.success((data, status, headers, config) => {
|
||||
hs["content-type"].charAt(1);
|
||||
});
|
||||
|
||||
|
||||
// Promise signature tests
|
||||
module TestPromise {
|
||||
var result: any;
|
||||
var any: any;
|
||||
|
||||
interface TResult {
|
||||
a: number;
|
||||
b: string;
|
||||
c: boolean;
|
||||
}
|
||||
|
||||
var promise: angular.IPromise<TResult>;
|
||||
interface IPromiseSuccessCallback<T, U> {
|
||||
(promiseValue: T): angular.IHttpPromise<U>|angular.IPromise<U>|U|angular.IPromise<void>;
|
||||
}
|
||||
var successCallbackAnyFn: IPromiseSuccessCallback<TResult, any>;
|
||||
var successCallbackTResultFn: IPromiseSuccessCallback<TResult, TResult>;
|
||||
interface IPromiseErrorCallback<T> {
|
||||
(error: any): angular.IHttpPromise<T>|angular.IPromise<T>|T;
|
||||
}
|
||||
var errorCallbackAnyFn: IPromiseErrorCallback<any>;
|
||||
var errorCallbackTResultFn: IPromiseErrorCallback<TResult>;
|
||||
|
||||
// promise.then
|
||||
result = <angular.IPromise<any>>promise.then(successCallbackAnyFn);
|
||||
result = <angular.IPromise<any>>promise.then(successCallbackAnyFn, (any) => any);
|
||||
result = <angular.IPromise<any>>promise.then(successCallbackAnyFn, (any) => any, (any) => any);
|
||||
result = <angular.IPromise<TResult>>promise.then<TResult>(successCallbackTResultFn);
|
||||
result = <angular.IPromise<TResult>>promise.then<TResult>(successCallbackTResultFn, (any) => any);
|
||||
result = <angular.IPromise<TResult>>promise.then<TResult>(successCallbackTResultFn, (any) => any, (any) => any);
|
||||
|
||||
// promise.catch
|
||||
result = <angular.IPromise<any>>promise.catch(errorCallbackAnyFn);
|
||||
result = <angular.IPromise<TResult>>promise.catch<TResult>(errorCallbackTResultFn);
|
||||
|
||||
// promise.finally
|
||||
result = <angular.IPromise<any>>promise.finally(() => any);
|
||||
result = <angular.IPromise<TResult>>promise.finally<TResult>(() => any);
|
||||
}
|
||||
|
||||
|
||||
function test_angular_forEach() {
|
||||
var values: { [key: string]: string } = { name: 'misko', gender: 'male' };
|
||||
var log: string[] = [];
|
||||
@@ -285,7 +339,7 @@ test_IAttributes({
|
||||
$addClass: function (classVal){},
|
||||
$removeClass: function(classVal){},
|
||||
$set: function(key, value){},
|
||||
$observe: function(name, fn){
|
||||
$observe: function(name: any, fn: any){
|
||||
return fn;
|
||||
},
|
||||
$attr: {}
|
||||
|
||||
+18
-16
@@ -237,7 +237,7 @@ declare module angular {
|
||||
forEach(obj: any, iterator: (value: any, key: any) => any, context?: any): any;
|
||||
|
||||
fromJson(json: string): any;
|
||||
identity(arg?: any): any;
|
||||
identity<T>(arg?: T): T;
|
||||
injector(modules?: any[], strictDi?: boolean): auto.IInjectorService;
|
||||
isArray(value: any): boolean;
|
||||
isDate(value: any): boolean;
|
||||
@@ -453,7 +453,7 @@ declare module angular {
|
||||
* following compilation. The observer is then invoked whenever the
|
||||
* interpolated value changes.
|
||||
*/
|
||||
$observe(name: string, fn: (value?: any) => any): Function;
|
||||
$observe<T>(name: string, fn: (value?: T) => any): Function;
|
||||
|
||||
/**
|
||||
* A map of DOM element attribute names to the normalized name. This is needed
|
||||
@@ -617,12 +617,12 @@ declare module angular {
|
||||
$on(name: string, listener: (event: IAngularEvent, ...args: any[]) => any): Function;
|
||||
|
||||
$watch(watchExpression: string, listener?: string, objectEquality?: boolean): Function;
|
||||
$watch(watchExpression: string, listener?: (newValue: any, oldValue: any, scope: IScope) => any, objectEquality?: boolean): Function;
|
||||
$watch<T>(watchExpression: string, listener?: (newValue: T, oldValue: T, scope: IScope) => any, objectEquality?: boolean): Function;
|
||||
$watch(watchExpression: (scope: IScope) => any, listener?: string, objectEquality?: boolean): Function;
|
||||
$watch(watchExpression: (scope: IScope) => any, listener?: (newValue: any, oldValue: any, scope: IScope) => any, objectEquality?: boolean): Function;
|
||||
$watch<T>(watchExpression: (scope: IScope) => T, listener?: (newValue: T, oldValue: T, scope: IScope) => any, objectEquality?: boolean): Function;
|
||||
|
||||
$watchCollection(watchExpression: string, listener: (newValue: any, oldValue: any, scope: IScope) => any): Function;
|
||||
$watchCollection(watchExpression: (scope: IScope) => any, listener: (newValue: any, oldValue: any, scope: IScope) => any): Function;
|
||||
$watchCollection<T>(watchExpression: string, listener: (newValue: T, oldValue: T, scope: IScope) => any): Function;
|
||||
$watchCollection<T>(watchExpression: (scope: IScope) => T, listener: (newValue: T, oldValue: T, 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;
|
||||
@@ -725,7 +725,7 @@ declare module angular {
|
||||
// see http://docs.angularjs.org/api/ng.$timeout
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
interface ITimeoutService {
|
||||
(func: Function, delay?: number, invokeApply?: boolean): IPromise<any>;
|
||||
<T>(func: (...args: any[]) => T, delay?: number, invokeApply?: boolean): IPromise<T>;
|
||||
cancel(promise: IPromise<any>): boolean;
|
||||
}
|
||||
|
||||
@@ -996,8 +996,7 @@ declare module angular {
|
||||
* See http://docs.angularjs.org/api/ng/service/$q
|
||||
*/
|
||||
interface IQService {
|
||||
new (resolver: (resolve: IQResolveReject<any>) => any): IPromise<any>;
|
||||
new (resolver: (resolve: IQResolveReject<any>, reject: IQResolveReject<any>) => any): IPromise<any>;
|
||||
new <T>(resolver: (resolve: IQResolveReject<T>) => any): IPromise<T>;
|
||||
new <T>(resolver: (resolve: IQResolveReject<T>, reject: IQResolveReject<any>) => any): IPromise<T>;
|
||||
|
||||
/**
|
||||
@@ -1007,7 +1006,7 @@ declare module angular {
|
||||
*
|
||||
* @param promises An array of promises.
|
||||
*/
|
||||
all(promises: IPromise<any>[]): IPromise<any[]>;
|
||||
all<T>(promises: IPromise<any>[]): IPromise<T[]>;
|
||||
/**
|
||||
* Combines multiple promises into a single promise that is resolved when all of the input promises are resolved.
|
||||
*
|
||||
@@ -1016,6 +1015,7 @@ declare module angular {
|
||||
* @param promises A hash of promises.
|
||||
*/
|
||||
all(promises: { [id: string]: IPromise<any>; }): IPromise<{ [id: string]: any; }>;
|
||||
all<T extends {}>(promises: { [id: string]: IPromise<any>; }): IPromise<T>;
|
||||
/**
|
||||
* Creates a Deferred object which represents a task which will finish in the future.
|
||||
*/
|
||||
@@ -1156,7 +1156,7 @@ declare module angular {
|
||||
*
|
||||
* @param key the key of the data to be retrieved
|
||||
*/
|
||||
get(key: string): any;
|
||||
get<T>(key: string): T;
|
||||
|
||||
/**
|
||||
* Removes an entry from the Cache object.
|
||||
@@ -1227,8 +1227,8 @@ declare module angular {
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
interface IControllerService {
|
||||
// Although the documentation doesn't state this, locals are optional
|
||||
(controllerConstructor: Function, locals?: any): any;
|
||||
(controllerName: string, locals?: any): any;
|
||||
(controllerConstructor: Function, locals?: any, bindToController?: any): any;
|
||||
(controllerName: string, locals?: any, bindToController?: any): any;
|
||||
}
|
||||
|
||||
interface IControllerProvider extends IServiceProvider {
|
||||
@@ -1540,6 +1540,8 @@ declare module angular {
|
||||
interface ISCEDelegateProvider extends IServiceProvider {
|
||||
resourceUrlBlacklist(blacklist: any[]): void;
|
||||
resourceUrlWhitelist(whitelist: any[]): void;
|
||||
resourceUrlBlacklist(): any[];
|
||||
resourceUrlWhitelist(): any[];
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1585,7 +1587,7 @@ declare module angular {
|
||||
scope: IScope,
|
||||
instanceElement: IAugmentedJQuery,
|
||||
instanceAttributes: IAttributes,
|
||||
controller: any,
|
||||
controller: {},
|
||||
transclude: ITranscludeFunction
|
||||
): void;
|
||||
}
|
||||
@@ -1680,9 +1682,9 @@ declare module angular {
|
||||
interface IInjectorService {
|
||||
annotate(fn: Function): string[];
|
||||
annotate(inlineAnnotatedFunction: any[]): string[];
|
||||
get(name: string): any;
|
||||
get<T>(name: string): T;
|
||||
has(name: string): boolean;
|
||||
instantiate(typeConstructor: Function, locals?: any): any;
|
||||
instantiate<T>(typeConstructor: Function, locals?: any): T;
|
||||
invoke(inlineAnnotatedFunction: any[]): any;
|
||||
invoke(func: Function, context?: any, locals?: any): any;
|
||||
}
|
||||
|
||||
Vendored
+1
@@ -27,6 +27,7 @@ interface Auth0LockOptions {
|
||||
forceJSONP?: boolean;
|
||||
gravatar?: boolean;
|
||||
integratedWindowsLogin?: boolean;
|
||||
icon?: string;
|
||||
loginAfterSignup?: boolean;
|
||||
popup?: boolean;
|
||||
popupOptions?: Auth0LockPopupOptions;
|
||||
|
||||
Vendored
+1
-1
@@ -33,7 +33,7 @@ interface Auth0Static {
|
||||
interface Auth0ClientOptions {
|
||||
clientID: string;
|
||||
callbackURL: string;
|
||||
callbackOnLoactionHash?: boolean;
|
||||
callbackOnLocationHash?: boolean;
|
||||
domain: string;
|
||||
forceJSONP?: boolean;
|
||||
}
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
/// <reference path="autobahn.d.ts"/>
|
||||
|
||||
import autobahn = require("autobahn");
|
||||
|
||||
class MyClass {
|
||||
add2Count: number = 0;
|
||||
session: autobahn.Session;
|
||||
@@ -44,4 +46,4 @@ function test_client() {
|
||||
};
|
||||
|
||||
connection.open();
|
||||
}
|
||||
}
|
||||
|
||||
Vendored
+153
-148
@@ -1,195 +1,200 @@
|
||||
// Type definitions for AutobahnJS v0.9.6
|
||||
// Type definitions for AutobahnJS v0.9.6
|
||||
// Project: http://autobahn.ws/js/
|
||||
// Definitions by: Elad Zelingher <https://github.com/darkl/>
|
||||
// Definitions by: Elad Zelingher <https://github.com/darkl/>, Andy Hawkins <https://github.com/a904guy/,http://a904guy.com/,http://www.bmbsqd.com>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
/// <reference path="../when/when.d.ts" />
|
||||
|
||||
declare module autobahn {
|
||||
|
||||
export class Session {
|
||||
id: number;
|
||||
realm: string;
|
||||
isOpen: boolean;
|
||||
features: any;
|
||||
caller_disclose_me: boolean;
|
||||
publisher_disclose_me: boolean;
|
||||
subscriptions: ISubscription[][];
|
||||
registrations: IRegistration[];
|
||||
export class Session {
|
||||
id: number;
|
||||
realm: string;
|
||||
isOpen: boolean;
|
||||
features: any;
|
||||
caller_disclose_me: boolean;
|
||||
publisher_disclose_me: boolean;
|
||||
subscriptions: ISubscription[][];
|
||||
registrations: IRegistration[];
|
||||
|
||||
constructor(transport: ITransport, defer: DeferFactory, challenge: OnChallengeHandler);
|
||||
constructor(transport: ITransport, defer: DeferFactory, challenge: OnChallengeHandler);
|
||||
|
||||
join(realm: string, authmethods: string[], authid: string): void;
|
||||
join(realm: string, authmethods: string[], authid: string): void;
|
||||
|
||||
leave(reason: string, message: string): void;
|
||||
leave(reason: string, message: string): void;
|
||||
|
||||
call<TResult>(procedure: string, args?: any[], kwargs?: any, options?: ICallOptions): When.Promise<TResult>;
|
||||
call<TResult>(procedure: string, args?: any[], kwargs?: any, options?: ICallOptions): When.Promise<TResult>;
|
||||
|
||||
publish(topic: string, args?: any[], kwargs?: any, options?: IPublishOptions): When.Promise<IPublication>;
|
||||
publish(topic: string, args?: any[], kwargs?: any, options?: IPublishOptions): When.Promise<IPublication>;
|
||||
|
||||
subscribe(topic: string, handler: SubscribeHandler, options?: ISubscribeOptions): When.Promise<ISubscription>;
|
||||
subscribe(topic: string, handler: SubscribeHandler, options?: ISubscribeOptions): When.Promise<ISubscription>;
|
||||
|
||||
register(procedure: string, endpoint: RegisterEndpoint, options?: IRegisterOptions): When.Promise<IRegistration>;
|
||||
register(procedure: string, endpoint: RegisterEndpoint, options?: IRegisterOptions): When.Promise<IRegistration>;
|
||||
|
||||
unsubscribe(subscription: ISubscription): When.Promise<any>;
|
||||
unsubscribe(subscription: ISubscription): When.Promise<any>;
|
||||
|
||||
unregister(registration: IRegistration): When.Promise<any>;
|
||||
unregister(registration: IRegistration): When.Promise<any>;
|
||||
|
||||
prefix(prefix: string, uri: string): void;
|
||||
prefix(prefix: string, uri: string): void;
|
||||
|
||||
resolve(curie: string): string;
|
||||
resolve(curie: string): string;
|
||||
|
||||
onjoin: (roleFeatures: any) => void;
|
||||
onleave: (reason: string, details: any) => void;
|
||||
}
|
||||
onjoin: (roleFeatures: any) => void;
|
||||
onleave: (reason: string, details: any) => void;
|
||||
}
|
||||
|
||||
interface IInvocation {
|
||||
caller?: number;
|
||||
progress?: boolean;
|
||||
procedure: string;
|
||||
}
|
||||
interface IInvocation {
|
||||
caller?: number;
|
||||
progress?: boolean;
|
||||
procedure: string;
|
||||
}
|
||||
|
||||
interface IEvent {
|
||||
publication: number;
|
||||
publisher?: number;
|
||||
topic: string;
|
||||
}
|
||||
interface IEvent {
|
||||
publication: number;
|
||||
publisher?: number;
|
||||
topic: string;
|
||||
}
|
||||
|
||||
interface IResult {
|
||||
args: any[];
|
||||
kwargs: any;
|
||||
}
|
||||
interface IResult {
|
||||
args: any[];
|
||||
kwargs: any;
|
||||
}
|
||||
|
||||
interface IError {
|
||||
error: string;
|
||||
args: any[];
|
||||
kwargs: any;
|
||||
}
|
||||
interface IError {
|
||||
error: string;
|
||||
args: any[];
|
||||
kwargs: any;
|
||||
}
|
||||
|
||||
type SubscribeHandler = (args?: any[], kwargs?: any, details?: IEvent) => void;
|
||||
type SubscribeHandler = (args?: any[], kwargs?: any, details?: IEvent) => void;
|
||||
|
||||
interface ISubscription {
|
||||
topic: string;
|
||||
handler: SubscribeHandler;
|
||||
options: ISubscribeOptions;
|
||||
session: Session;
|
||||
id: number;
|
||||
active: boolean;
|
||||
unsubscribe(): When.Promise<any>;
|
||||
}
|
||||
interface ISubscription {
|
||||
topic: string;
|
||||
handler: SubscribeHandler;
|
||||
options: ISubscribeOptions;
|
||||
session: Session;
|
||||
id: number;
|
||||
active: boolean;
|
||||
unsubscribe(): When.Promise<any>;
|
||||
}
|
||||
|
||||
type RegisterEndpoint = (args?: any[], kwargs?: any, details?: IInvocation) => void;
|
||||
type RegisterEndpoint = (args?: any[], kwargs?: any, details?: IInvocation) => void;
|
||||
|
||||
interface IRegistration {
|
||||
procedure: string;
|
||||
endpoint: RegisterEndpoint;
|
||||
options: IRegisterOptions;
|
||||
session: Session;
|
||||
id: number;
|
||||
active: boolean;
|
||||
unregister(): When.Promise<any>;
|
||||
}
|
||||
interface IRegistration {
|
||||
procedure: string;
|
||||
endpoint: RegisterEndpoint;
|
||||
options: IRegisterOptions;
|
||||
session: Session;
|
||||
id: number;
|
||||
active: boolean;
|
||||
unregister(): When.Promise<any>;
|
||||
}
|
||||
|
||||
interface IPublication {
|
||||
id: number;
|
||||
}
|
||||
interface IPublication {
|
||||
id: number;
|
||||
}
|
||||
|
||||
interface ICallOptions {
|
||||
timeout?: number;
|
||||
receive_progress?: boolean;
|
||||
disclose_me?: boolean;
|
||||
}
|
||||
interface ICallOptions {
|
||||
timeout?: number;
|
||||
receive_progress?: boolean;
|
||||
disclose_me?: boolean;
|
||||
}
|
||||
|
||||
interface IPublishOptions {
|
||||
exclude?: number[];
|
||||
eligible?: number[];
|
||||
disclose_me? : Boolean;
|
||||
}
|
||||
interface IPublishOptions {
|
||||
exclude?: number[];
|
||||
eligible?: number[];
|
||||
disclose_me? : Boolean;
|
||||
}
|
||||
|
||||
interface ISubscribeOptions {
|
||||
match? : string;
|
||||
}
|
||||
interface ISubscribeOptions {
|
||||
match? : string;
|
||||
}
|
||||
|
||||
interface IRegisterOptions {
|
||||
disclose_caller?: boolean;
|
||||
}
|
||||
interface IRegisterOptions {
|
||||
disclose_caller?: boolean;
|
||||
}
|
||||
|
||||
export class Connection {
|
||||
constructor(options?: IConnectionOptions);
|
||||
export class Connection {
|
||||
constructor(options?: IConnectionOptions);
|
||||
|
||||
open(): void;
|
||||
open(): void;
|
||||
|
||||
close(reason: string, message: string): void;
|
||||
close(reason: string, message: string): void;
|
||||
|
||||
onopen: (session: Session, details: any) => void;
|
||||
onclose: (reason: string, details: any) => boolean;
|
||||
}
|
||||
onopen: (session: Session, details: any) => void;
|
||||
onclose: (reason: string, details: any) => boolean;
|
||||
}
|
||||
|
||||
interface ITransportDefinition {
|
||||
url?: string;
|
||||
protocols?: string[];
|
||||
type: string;
|
||||
}
|
||||
interface ITransportDefinition {
|
||||
url?: string;
|
||||
protocols?: string[];
|
||||
type: string;
|
||||
}
|
||||
|
||||
type DeferFactory = () => any;
|
||||
type DeferFactory = () => any;
|
||||
|
||||
type OnChallengeHandler = (session: Session, method: string, extra: any) => When.Promise<string>;
|
||||
type OnChallengeHandler = (session: Session, method: string, extra: any) => When.Promise<string>;
|
||||
|
||||
interface IConnectionOptions {
|
||||
use_es6_promises?: boolean;
|
||||
// use explicit deferred factory, e.g. jQuery.Deferred or Q.defer
|
||||
use_deferred?: DeferFactory;
|
||||
transports?: ITransportDefinition[];
|
||||
retry_if_unreachable?: boolean;
|
||||
max_retries?: number;
|
||||
initial_retry_delay?: number;
|
||||
max_retry_delay?: number;
|
||||
retry_delay_growth?: number;
|
||||
retry_delay_jitter?: number;
|
||||
url?: string;
|
||||
protocols?: string[];
|
||||
onchallenge?: (session: Session, method: string, extra: any) => OnChallengeHandler;
|
||||
realm?: string;
|
||||
authmethods?: string[];
|
||||
authid?: string;
|
||||
}
|
||||
interface IConnectionOptions {
|
||||
use_es6_promises?: boolean;
|
||||
// use explicit deferred factory, e.g. jQuery.Deferred or Q.defer
|
||||
use_deferred?: DeferFactory;
|
||||
transports?: ITransportDefinition[];
|
||||
retry_if_unreachable?: boolean;
|
||||
max_retries?: number;
|
||||
initial_retry_delay?: number;
|
||||
max_retry_delay?: number;
|
||||
retry_delay_growth?: number;
|
||||
retry_delay_jitter?: number;
|
||||
url?: string;
|
||||
protocols?: string[];
|
||||
onchallenge?: (session: Session, method: string, extra: any) => OnChallengeHandler;
|
||||
realm?: string;
|
||||
authmethods?: string[];
|
||||
authid?: string;
|
||||
}
|
||||
|
||||
interface ICloseEventDetails {
|
||||
wasClean: boolean;
|
||||
reason: string;
|
||||
code: number;
|
||||
}
|
||||
interface ICloseEventDetails {
|
||||
wasClean: boolean;
|
||||
reason: string;
|
||||
code: number;
|
||||
}
|
||||
|
||||
interface ITransport {
|
||||
onopen: () => void;
|
||||
onmessage: (message: any[]) => void;
|
||||
onclose: (details: ICloseEventDetails) => void;
|
||||
interface ITransport {
|
||||
onopen: () => void;
|
||||
onmessage: (message: any[]) => void;
|
||||
onclose: (details: ICloseEventDetails) => void;
|
||||
|
||||
send(message: any[]): void;
|
||||
close(errorCode: number, reason?: string): void;
|
||||
}
|
||||
send(message: any[]): void;
|
||||
close(errorCode: number, reason?: string): void;
|
||||
}
|
||||
|
||||
interface ITransportFactory {
|
||||
//constructor(options: any);
|
||||
type: string;
|
||||
create(): ITransport;
|
||||
}
|
||||
interface ITransportFactory {
|
||||
//constructor(options: any);
|
||||
type: string;
|
||||
create(): ITransport;
|
||||
}
|
||||
|
||||
interface ITransports {
|
||||
register(name: string, factory: any): void;
|
||||
isRegistered(name: string): boolean;
|
||||
get(name: string): any;
|
||||
list(): any[];
|
||||
}
|
||||
interface ITransports {
|
||||
register(name: string, factory: any): void;
|
||||
isRegistered(name: string): boolean;
|
||||
get(name: string): any;
|
||||
list(): any[];
|
||||
}
|
||||
|
||||
interface ILog {
|
||||
debug(...args: any[]): void;
|
||||
}
|
||||
interface ILog {
|
||||
debug(...args: any[]): void;
|
||||
}
|
||||
|
||||
interface IUtil {
|
||||
assert(condition: boolean, message: string): void;
|
||||
}
|
||||
interface IUtil {
|
||||
assert(condition: boolean, message: string): void;
|
||||
}
|
||||
|
||||
var util: IUtil;
|
||||
var log: ILog;
|
||||
var transports: ITransports;
|
||||
}
|
||||
var util: IUtil;
|
||||
var log: ILog;
|
||||
var transports: ITransports;
|
||||
}
|
||||
|
||||
declare module "autobahn" {
|
||||
export = autobahn;
|
||||
}
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
|
||||
Vendored
+8
-12
@@ -148,7 +148,7 @@ declare module Backbone {
|
||||
unset(attribute: string, options?: Silenceable): Model;
|
||||
validate(attributes: any, options?: any): any;
|
||||
|
||||
private _validate(attrs: any, options: any): boolean;
|
||||
private _validate(attributes: any, options: any): boolean;
|
||||
|
||||
// mixins from underscore
|
||||
|
||||
@@ -173,8 +173,8 @@ declare module Backbone {
|
||||
models: TModel[];
|
||||
length: number;
|
||||
|
||||
constructor(models?: TModel[], options?: any);
|
||||
initialize(models?: TModel[], options?: any): void;
|
||||
constructor(models?: TModel[] | Object[], options?: any);
|
||||
initialize(models?: TModel[] | Object[], options?: any): void;
|
||||
|
||||
fetch(options?: CollectionFetchOptions): JQueryXHR;
|
||||
|
||||
@@ -187,9 +187,7 @@ declare module Backbone {
|
||||
/**
|
||||
* Get a model from a collection, specified by an id, a cid, or by passing in a model.
|
||||
**/
|
||||
get(id: number): TModel;
|
||||
get(id: string): TModel;
|
||||
get(id: Model): TModel;
|
||||
get(id: number|string|Model): TModel;
|
||||
create(attributes: any, options?: ModelSaveOptions): TModel;
|
||||
pluck(attribute: string): any[];
|
||||
push(model: TModel, options?: AddOptions): TModel;
|
||||
@@ -201,10 +199,10 @@ declare module Backbone {
|
||||
shift(options?: Silenceable): TModel;
|
||||
sort(options?: Silenceable): Collection<TModel>;
|
||||
unshift(model: TModel, options?: AddOptions): TModel;
|
||||
where(properies: any): TModel[];
|
||||
where(properties: any): TModel[];
|
||||
findWhere(properties: any): TModel;
|
||||
|
||||
private _prepareModel(attrs?: any, options?: any): any;
|
||||
private _prepareModel(attributes?: any, options?: any): any;
|
||||
private _removeReference(model: TModel): void;
|
||||
private _onModelEvent(event: string, model: TModel, collection: Collection<TModel>, options: any): void;
|
||||
|
||||
@@ -278,8 +276,7 @@ declare module Backbone {
|
||||
|
||||
constructor(options?: RouterOptions);
|
||||
initialize(options?: RouterOptions): void;
|
||||
route(route: string, name: string, callback?: Function): Router;
|
||||
route(route: RegExp, name: string, callback?: Function): Router;
|
||||
route(route: string|RegExp, name: string, callback?: Function): Router;
|
||||
navigate(fragment: string, options?: NavigateOptions): Router;
|
||||
navigate(fragment: string, trigger?: boolean): Router;
|
||||
|
||||
@@ -341,8 +338,7 @@ declare module Backbone {
|
||||
model: TModel;
|
||||
collection: Collection<TModel>;
|
||||
//template: (json, options?) => string;
|
||||
setElement(element: HTMLElement, delegate?: boolean): View<TModel>;
|
||||
setElement(element: JQuery, delegate?: boolean): View<TModel>;
|
||||
setElement(element: HTMLElement|JQuery, delegate?: boolean): View<TModel>;
|
||||
id: string;
|
||||
cid: string;
|
||||
className: string;
|
||||
|
||||
+1
-14
@@ -9,7 +9,7 @@ declare module Microsoft.Maps.AdvancedShapes {
|
||||
|
||||
export class EntityCollection {
|
||||
|
||||
constructor(options: EntityCollectionOptions);
|
||||
constructor(options?: EntityCollectionOptions);
|
||||
|
||||
clear(): void;
|
||||
get(index: number): Entity;
|
||||
@@ -24,10 +24,6 @@ declare module Microsoft.Maps.AdvancedShapes {
|
||||
removeAt(index: number): Entity;
|
||||
setOptions(options: EntityCollectionOptions): void;
|
||||
toString(): string;
|
||||
|
||||
entityAdded: (args: EntityChangeArgs) => any;
|
||||
entityChanged: (args: EntityChangeArgs) => any;
|
||||
entityRemoved: (args: EntityChangeArgs) => any;
|
||||
}
|
||||
|
||||
export class Polygon implements Entity {
|
||||
@@ -43,15 +39,6 @@ declare module Microsoft.Maps.AdvancedShapes {
|
||||
setLocations(locations: Location[]): void;
|
||||
setOptions(options: PolylineOptions): void;
|
||||
toString(): string;
|
||||
|
||||
click: (eventArgs: MouseEventArgs) => void;
|
||||
dbclick: (eventArgs: MouseEventArgs) => void;
|
||||
entitychanged: (entity: Entity) => void;
|
||||
mousedown: (eventArgs: MouseEventArgs) => void;
|
||||
mouseout: (eventArgs: MouseEventArgs) => void;
|
||||
mouseover: (eventArgs: MouseEventArgs) => void;
|
||||
mouseup: (eventArgs: MouseEventArgs) => void;
|
||||
rightclick: (eventArgs: MouseEventArgs) => void;
|
||||
}
|
||||
|
||||
}
|
||||
-25
@@ -79,10 +79,6 @@ declare module Microsoft.Maps.Directions {
|
||||
isExactLocation(): boolean;
|
||||
isViapoint(): boolean;
|
||||
setOptions(options: WaypointOptions): void;
|
||||
|
||||
changed: (args: WaypointEventArgs) => void;
|
||||
geocoded: (args: WaypointEventArgs) => void;
|
||||
reverseGeocoded: (args: WaypointEventArgs) => void;
|
||||
}
|
||||
|
||||
export interface DirectionsRenderOptions {
|
||||
@@ -185,27 +181,6 @@ declare module Microsoft.Maps.Directions {
|
||||
setMapView(): void;
|
||||
setRenderOptions(options: DirectionsRenderOptions): void;
|
||||
setRequestOptions(options: DirectionsRequestOptions): void;
|
||||
|
||||
afterRouteSelectorRender: (args: RouteSelectorRenderEventArgs) => void;
|
||||
afterStepRender: (args: DirectionsStepRenderEventArgs) => void;
|
||||
afterSummaryRender: (args: RouteSummaryRenderEventArgs) => void;
|
||||
afterWaypointRender: (args: WaypointRenderEventArgs) => void;
|
||||
beforeDisambiguationRender: (args: DisambiguationRenderEventArgs) => void;
|
||||
beforeRouteSelectorRender: (args: RouteSelectorRenderEventArgs) => void;
|
||||
beforeStepRender: (args: DirectionsStepRenderEventArgs) => void;
|
||||
beforeSummaryRender: (args: RouteSummaryRenderEventArgs) => void;
|
||||
beforeWaypointRender: (args: WaypointRenderEventArgs) => void;
|
||||
directionsError: (args: DirectionsErrorEventArgs) => void;
|
||||
directionsUpdated: (args: DirectionsEventArgs) => void;
|
||||
dragDropCompleted: () => void;
|
||||
itineraryStepClicked: (args: DirectionsStepEventArgs) => void;
|
||||
mouseEnterRouteSelector: (args: RouteSelectorEventArgs) => void;
|
||||
mouseEnterStep: (args: DirectionsStepEventArgs) => void;
|
||||
mouseLeaveRouteSelector: (args: RouteSelectorEventArgs) => void;
|
||||
mouseLeaveStep: (args: DirectionsStepEventArgs) => void;
|
||||
routeSelectorClicked: (args: RouteSelectorEventArgs) => void;
|
||||
waypointAdded: (args: WaypointEventArgs) => void;
|
||||
waypointRemoved: (args: WaypointEventArgs) => void;
|
||||
}
|
||||
|
||||
export interface DirectionsStepEventArgs {
|
||||
|
||||
Vendored
+22
-22
@@ -6,7 +6,7 @@
|
||||
/// <reference path="Microsoft.Maps.d.ts"/>
|
||||
|
||||
declare module Microsoft.Maps.Search {
|
||||
|
||||
|
||||
export interface Address {
|
||||
addressLine: string;
|
||||
adminDistrict: string;
|
||||
@@ -25,12 +25,12 @@ declare module Microsoft.Maps.Search {
|
||||
}
|
||||
|
||||
export interface GeocodeRequestOptions {
|
||||
bounds: LocationRect;
|
||||
callback: (result: GeocodeResult, userData: any) => any;
|
||||
bounds?: LocationRect;
|
||||
callback?: (result: GeocodeResult, userData: any) => any;
|
||||
count: number;
|
||||
errorCallback: (options: GeocodeRequestOptions) => any;
|
||||
timeout: number;
|
||||
userData: any;
|
||||
errorCallback?: (options: GeocodeRequestOptions) => any;
|
||||
timeout?: number;
|
||||
userData?: any;
|
||||
where:string;
|
||||
}
|
||||
|
||||
@@ -71,15 +71,15 @@ declare module Microsoft.Maps.Search {
|
||||
}
|
||||
|
||||
export interface ReverseGeocodeRequestOptions {
|
||||
callback: (result: PlaceResult, userData: any) => any;
|
||||
errorCallback: (options: ReverseGeocodeRequestOptions) => any;
|
||||
location: Location;
|
||||
timeout: number;
|
||||
userData:any;
|
||||
callback?: (result: PlaceResult, userData: any) => any;
|
||||
errorCallback?: (options: ReverseGeocodeRequestOptions) => any;
|
||||
location?: Location;
|
||||
timeout?: number;
|
||||
userData?:any;
|
||||
}
|
||||
|
||||
export class SearchManager {
|
||||
|
||||
|
||||
constructor(map: Map);
|
||||
|
||||
geocode(request: GeocodeRequestOptions): void;
|
||||
@@ -104,16 +104,16 @@ declare module Microsoft.Maps.Search {
|
||||
}
|
||||
|
||||
export interface SearchRequestOptions {
|
||||
callback:(result: SearchResponse, userData: any)=>any;
|
||||
callback?:(result: SearchResponse, userData: any)=>any;
|
||||
count: number;
|
||||
errorCallback:(options: SearchRequestOptions)=>any;
|
||||
query: string;
|
||||
startIndex: number;
|
||||
timeout: number;
|
||||
entityType: string;
|
||||
userData: any;
|
||||
what: string;
|
||||
where:string;
|
||||
errorCallback?:(options: SearchRequestOptions)=>any;
|
||||
query?: string;
|
||||
startIndex?: number;
|
||||
timeout?: number;
|
||||
entityType?: string;
|
||||
userData?: any;
|
||||
what?: string;
|
||||
where?:string;
|
||||
}
|
||||
|
||||
export interface SearchResponse {
|
||||
@@ -149,4 +149,4 @@ declare module Microsoft.Maps.Search {
|
||||
website:string;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
+15
-18
@@ -11,20 +11,23 @@ declare module Microsoft.Maps.VenueMaps {
|
||||
eventArgs: MouseEventArgs;
|
||||
}
|
||||
|
||||
export interface PrimitiveResponse {
|
||||
eventArgs: Primitive;
|
||||
}
|
||||
|
||||
export interface Directory {
|
||||
|
||||
addToDOM(div: HTMLElement, sortOrder: DirectorySortOrder, to_group_or_not: DirectoryGrouping): void;
|
||||
createUIElements(): void;
|
||||
handleMouseClick(response: MouseResponse): void;
|
||||
handleMouseOut(response: MouseResponse): void;
|
||||
handleMouseOver(response: MouseResponse): void;
|
||||
handleMouseClick(e: (response: MouseResponse) => void): void;
|
||||
handleMouseClick(e: (response: PrimitiveResponse) => void): void;
|
||||
handleMouseOut(e: (response: MouseResponse) => void): void;
|
||||
handleMouseOut(e: (response: PrimitiveResponse) => void): void;
|
||||
handleMouseOver(e: (response: MouseResponse) => void): void;
|
||||
handleMouseOver(e: (response: PrimitiveResponse) => void): void;
|
||||
isInDOM(): boolean;
|
||||
removeFromDOM(): void;
|
||||
setHeight(height: number): void;
|
||||
|
||||
click: (eventArgs: MouseEventArgs) => any;
|
||||
mouseOut: (eventArgs: MouseEventArgs) => any;
|
||||
mouseOver: (eventArgs: MouseEventArgs) => any;
|
||||
}
|
||||
|
||||
export enum DirectoryGrouping {
|
||||
@@ -67,10 +70,10 @@ declare module Microsoft.Maps.VenueMaps {
|
||||
}
|
||||
|
||||
export interface NearbyVenueOptions {
|
||||
callback: (maps: Array<VenueMap>) => any;
|
||||
location: Location;
|
||||
map: Map;
|
||||
radius: number;
|
||||
callback?: (maps: Array<VenueMap>) => any;
|
||||
location?: Location;
|
||||
map?: Map;
|
||||
radius?: number;
|
||||
}
|
||||
|
||||
export interface Polygon {
|
||||
@@ -116,12 +119,6 @@ declare module Microsoft.Maps.VenueMaps {
|
||||
hide(): void;
|
||||
setActiveFloor(floor: string): void;
|
||||
show(): void;
|
||||
|
||||
click: (eventArgs: Primitive) => any;
|
||||
close: () => any;
|
||||
footprintclick: (eventArgs: Primitive) => any;
|
||||
mouseout: (eventArgs: Primitive) => any;
|
||||
mouseover: (eventArgs: Primitive) => any;
|
||||
}
|
||||
|
||||
export interface VenueMapCreationOptions {
|
||||
@@ -138,4 +135,4 @@ declare module Microsoft.Maps.VenueMaps {
|
||||
getNearbyVenues(options: NearbyVenueOptions): void;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Vendored
+35
-74
@@ -45,7 +45,7 @@ declare module Microsoft.Maps {
|
||||
getNorth(): number;
|
||||
getNorthwest(): Location;
|
||||
getSouth(): number;
|
||||
getSouthEast(): Location;
|
||||
getSoutheast(): Location;
|
||||
getWest(): number;
|
||||
intersects(rect: LocationRect): boolean;
|
||||
toString(): string;
|
||||
@@ -96,7 +96,8 @@ declare module Microsoft.Maps {
|
||||
|
||||
export class Map {
|
||||
|
||||
constructor(containerElement: HTMLElement, options: MapOptions);
|
||||
constructor(containerElement: HTMLElement, options?: MapOptions);
|
||||
constructor(containerElement: HTMLElement, options?: ViewOptions);
|
||||
|
||||
entities: EntityCollection;
|
||||
|
||||
@@ -137,39 +138,25 @@ declare module Microsoft.Maps {
|
||||
setMapType(mapTypeId: MapTypeId): void;
|
||||
setOptions(options: MapOptions): void;
|
||||
setView(options: ViewOptions): void;
|
||||
tryLocationToPixel(locations: Array<Location>, reference?: PixelReference): any;
|
||||
tryPixelToLocation(points: Array<Point>, reference?: PixelReference): any;
|
||||
|
||||
click: (eventArgs: MouseEventArgs) => void;
|
||||
copyrightchanged: () => void;
|
||||
dblclick: (eventArgs: MouseEventArgs) => void;
|
||||
imagerychanged: () => void;
|
||||
keydown: (eventArgs: KeyEventArgs) => void;
|
||||
keypress: (eventArgs: KeyEventArgs) => void;
|
||||
keyup: (eventArgs: KeyEventArgs) => void;
|
||||
maptypechanged: () => void;
|
||||
mousedown: (eventArgs: MouseEventArgs) => void;
|
||||
mousemove: (eventArgs: MouseEventArgs) => void;
|
||||
mouseout: (eventArgs: MouseEventArgs) => void;
|
||||
mouseover: (eventArgs: MouseEventArgs) => void;
|
||||
mouseup: (eventArgs: MouseEventArgs) => void;
|
||||
mousewheel: (eventArgs: MouseEventArgs) => void;
|
||||
rightlick: (eventArgs: MouseEventArgs) => void;
|
||||
targetviewchanged: () => void;
|
||||
tiledownloadcomplete: () => void;
|
||||
viewchange: () => void;
|
||||
viewchangeend: () => void;
|
||||
viewchangestart: () => void;
|
||||
tryLocationToPixel(locations: Location, reference?: PixelReference): Point;
|
||||
tryLocationToPixel(locations: Array<Location>, reference?: PixelReference): Array<Point>;
|
||||
tryPixelToLocation(points: Point, reference?: PixelReference): Location;
|
||||
tryPixelToLocation(points: Array<Point>, reference?: PixelReference): Array<Location>;
|
||||
}
|
||||
|
||||
export class MapMode {
|
||||
|
||||
getDrawShapesInSingleLayer(): boolean;
|
||||
getShouldClipPolygons(): boolean;
|
||||
setOptions(options: MapOptions): void;
|
||||
setOptions(options: MapModeOptions): void;
|
||||
setViewChangeEndDelay(delay: number): void;
|
||||
}
|
||||
|
||||
export interface MapModeOptions {
|
||||
shouldClipPolygons?: boolean;
|
||||
drawShapesInSingleLayer?:boolean;
|
||||
}
|
||||
|
||||
export interface MapOptions {
|
||||
|
||||
backgroundColor?: Color;
|
||||
@@ -272,14 +259,14 @@ declare module Microsoft.Maps {
|
||||
}
|
||||
|
||||
export interface EntityCollectionOptions {
|
||||
bubble: boolean;
|
||||
visible: boolean;
|
||||
zIndex: number;
|
||||
bubble?: boolean;
|
||||
visible?: boolean;
|
||||
zIndex?: number;
|
||||
}
|
||||
|
||||
export class EntityCollection {
|
||||
|
||||
constructor(options: EntityCollectionOptions);
|
||||
constructor(options?: EntityCollectionOptions);
|
||||
|
||||
clear(): void;
|
||||
get(index: number): Entity;
|
||||
@@ -295,9 +282,6 @@ declare module Microsoft.Maps {
|
||||
setOptions(options: EntityCollectionOptions): void;
|
||||
toString(): string;
|
||||
|
||||
entityAdded: (args: EntityChangeArgs) => any;
|
||||
entityChanged: (args: EntityChangeArgs) => any;
|
||||
entityRemoved: (args: EntityChangeArgs) => any;
|
||||
}
|
||||
|
||||
export class Infobox {
|
||||
@@ -325,11 +309,6 @@ declare module Microsoft.Maps {
|
||||
setLocation(location: Location): void;
|
||||
setOptions(options: InfoboxOptions): void;
|
||||
toString(): string;
|
||||
|
||||
click: (eventArgs: MouseEventArgs) => void;
|
||||
entitychanged: (entity: Entity) => void;
|
||||
mouseenter: (eventArgs: MouseEventArgs) => void;
|
||||
mouseleave: (eventArgs: MouseEventArgs) => void;
|
||||
}
|
||||
|
||||
export interface Action {
|
||||
@@ -378,15 +357,11 @@ declare module Microsoft.Maps {
|
||||
setLocations(locations: Array<Location>): void;
|
||||
setOptions(options: PolylineOptions): void;
|
||||
toString(): string;
|
||||
}
|
||||
|
||||
click: (eventArgs: MouseEventArgs) => void;
|
||||
dblclick: (eventArgs: MouseEventArgs) => void;
|
||||
entitychanged: (entity: Entity) => void;
|
||||
mousedown: (eventArgs: MouseEventArgs) => void;
|
||||
mouseout: (eventArgs: MouseEventArgs) => void;
|
||||
mouseover: (eventArgs: MouseEventArgs) => void;
|
||||
mouseup: (eventArgs: MouseEventArgs) => void;
|
||||
rightclick: (eventArgs: MouseEventArgs) => void;
|
||||
export class Position {
|
||||
coords: Coordinates;
|
||||
timestamp: string;
|
||||
}
|
||||
|
||||
export interface PolylineOptions {
|
||||
@@ -409,20 +384,11 @@ declare module Microsoft.Maps {
|
||||
setLocations(locations: Location[]): void;
|
||||
setOptions(options: PolylineOptions): void;
|
||||
toString(): string;
|
||||
|
||||
click: (eventArgs: MouseEventArgs) => void;
|
||||
dbclick: (eventArgs: MouseEventArgs) => void;
|
||||
entitychanged: (entity: Entity) => void;
|
||||
mousedown: (eventArgs: MouseEventArgs) => void;
|
||||
mouseout: (eventArgs: MouseEventArgs) => void;
|
||||
mouseover: (eventArgs: MouseEventArgs) => void;
|
||||
mouseup: (eventArgs: MouseEventArgs) => void;
|
||||
rightclick: (eventArgs: MouseEventArgs) => void;
|
||||
}
|
||||
|
||||
export interface PolygonOptions {
|
||||
fillColor?: Color;
|
||||
infoBox?: Infobox;
|
||||
infobox?: Infobox;
|
||||
strokeColor?: Color;
|
||||
strokeDashArray?: string;
|
||||
strokeThickness?: number;
|
||||
@@ -446,18 +412,6 @@ declare module Microsoft.Maps {
|
||||
setLocation(location: Location): void;
|
||||
setOptions(options: PushpinOptions): void;
|
||||
toString(): string;
|
||||
|
||||
click: (eventArgs: MouseEventArgs) => void;
|
||||
dblclick: (eventArgs: MouseEventArgs) => void;
|
||||
drag: (object: Pushpin) => any;
|
||||
dragend: (eventArgs: MouseEventArgs) => void;
|
||||
dragstart: (eventArgs: MouseEventArgs) => void;
|
||||
entitychanged: (object: { entity: Entity; }) => any;
|
||||
mousedown: (eventArgs: MouseEventArgs) => void;
|
||||
mouseout: (eventArgs: MouseEventArgs) => void;
|
||||
mouseover: (eventArgs: MouseEventArgs) => void;
|
||||
mouseup: (eventArgs: MouseEventArgs) => void;
|
||||
rightclick: (eventArgs: MouseEventArgs) => void;
|
||||
}
|
||||
|
||||
export enum EntityState {
|
||||
@@ -487,13 +441,11 @@ declare module Microsoft.Maps {
|
||||
|
||||
constructor(options: TileLayerOptions);
|
||||
|
||||
getOpacty(): number;
|
||||
getOpacity(): number;
|
||||
getTileSource(projection: string): TileSource;
|
||||
getZIndex(): number;
|
||||
setOptions(options: TileLayerOptions): void;
|
||||
toString(): string;
|
||||
|
||||
tiledownloadcomplete: () => void;
|
||||
}
|
||||
|
||||
export class TileSource {
|
||||
@@ -509,7 +461,7 @@ declare module Microsoft.Maps {
|
||||
export interface TileSourceOptions {
|
||||
|
||||
height?: number;
|
||||
uriConstructor: string;
|
||||
uriConstructor: any;
|
||||
width?: number;
|
||||
}
|
||||
|
||||
@@ -550,9 +502,18 @@ declare module Microsoft.Maps {
|
||||
removeAccuracyCircle(): void;
|
||||
}
|
||||
|
||||
export interface PositionOptionsErrorCallbackResult {
|
||||
internalError: PositionError;
|
||||
errorCode:number;
|
||||
}
|
||||
export interface PositionOptions {
|
||||
enableHighAccuracy?: boolean;
|
||||
errorCallback?:(result:PositionOptionsErrorCallbackResult)=>void;
|
||||
}
|
||||
|
||||
export interface PositionCircleOptions {
|
||||
polygonOptions: PolygonOptions;
|
||||
showOnMap: boolean;
|
||||
showOnMap?: boolean;
|
||||
}
|
||||
|
||||
export class PositionError {
|
||||
@@ -567,7 +528,7 @@ declare module Microsoft.Maps {
|
||||
homeRegion?: string;
|
||||
}
|
||||
|
||||
export function loadModule(moduleKey: string, options: ModuleOptions): void;
|
||||
export function loadModule(moduleKey: string, options?: ModuleOptions): void;
|
||||
export function moduleLoaded(moduleKey: string): void;
|
||||
export function registerModule(moduleKey: string, scriptUrl: string, options?: ModuleOptions): void;
|
||||
}
|
||||
|
||||
Vendored
+1
-2
@@ -20,8 +20,7 @@ declare class Promise<R> implements Promise.Thenable<R> {
|
||||
/**
|
||||
* Create a new promise. The passed in function will receive functions `resolve` and `reject` as its arguments which can be called to seal the fate of the created promise.
|
||||
*/
|
||||
constructor(callback: (resolve: (thenable: Promise.Thenable<R>) => void, reject: (error: any) => void) => void);
|
||||
constructor(callback: (resolve: (result: R) => void, reject: (error: any) => void) => void);
|
||||
constructor(callback: (resolve: (thenableOrResult: R | Promise.Thenable<R>) => void, reject: (error: any) => void) => void);
|
||||
|
||||
/**
|
||||
* Promises/A+ `.then()` with progress handler. Returns a new promise chained from this promise. The new promise will be rejected or resolved dedefer on the passed `fulfilledHandler`, `rejectedHandler` and the state of this promise.
|
||||
|
||||
Vendored
+2
-3
@@ -20,8 +20,7 @@ declare class Promise<R> implements Promise.Thenable<R>, Promise.Inspection<R> {
|
||||
/**
|
||||
* Create a new promise. The passed in function will receive functions `resolve` and `reject` as its arguments which can be called to seal the fate of the created promise.
|
||||
*/
|
||||
constructor(callback: (resolve: (thenable: Promise.Thenable<R>) => void, reject: (error: any) => void) => void);
|
||||
constructor(callback: (resolve: (result: R) => void, reject: (error: any) => void) => void);
|
||||
constructor(callback: (resolve: (thenableOrResult: R | Promise.Thenable<R>) => void, reject: (error: any) => void) => void);
|
||||
|
||||
/**
|
||||
* Promises/A+ `.then()` with progress handler. Returns a new promise chained from this promise. The new promise will be rejected or resolved dedefer on the passed `fulfilledHandler`, `rejectedHandler` and the state of this promise.
|
||||
@@ -416,7 +415,7 @@ declare class Promise<R> implements Promise.Thenable<R>, Promise.Inspection<R> {
|
||||
* Note that the original methods on the object are not overwritten but new methods are created with the `Async`-postfix. For example, if you `promisifyAll()` the node.js `fs` object use `fs.statAsync()` to call the promisified `stat` method.
|
||||
*/
|
||||
// TODO how to model promisifyAll?
|
||||
static promisifyAll(target: Object): Object;
|
||||
static promisifyAll(target: Object, options?: Object): Object;
|
||||
|
||||
/**
|
||||
* Returns a function that can use `yield` to run asynchronous code synchronously. This feature requires the support of generators which are drafted in the next version of the language. Node version greater than `0.11.2` is required and needs to be executed with the `--harmony-generators` (or `--harmony`) command-line switch.
|
||||
|
||||
Vendored
+1
-1
@@ -6,7 +6,7 @@
|
||||
/// <reference path="../express/express.d.ts" />
|
||||
|
||||
declare module "body-parser" {
|
||||
import express = require('express');
|
||||
import * as express from "express";
|
||||
|
||||
/**
|
||||
* bodyParser: use individual json/urlencoded middlewares
|
||||
|
||||
Vendored
+2
-1
@@ -6,7 +6,8 @@
|
||||
/// <reference path="../node/node.d.ts" />
|
||||
|
||||
declare module Boom {
|
||||
interface BoomError {
|
||||
|
||||
export interface BoomError {
|
||||
data: any;
|
||||
reformat: () => void;
|
||||
isBoom: boolean;
|
||||
|
||||
@@ -27,14 +27,12 @@ bootbox.prompt("Enter 'ok' to pass test", function (result) {
|
||||
console.log(result);
|
||||
});
|
||||
bootbox.prompt({
|
||||
title: "Wassup?",
|
||||
message: "Enter 'ok' to pass test", callback: function (result) {
|
||||
console.log(result);
|
||||
}
|
||||
});
|
||||
bootbox.prompt({
|
||||
size: "large",
|
||||
title: "Wassup?",
|
||||
message: "Enter 'ok' to pass test", callback: function (result) {
|
||||
console.log(result);
|
||||
}
|
||||
@@ -42,6 +40,7 @@ bootbox.prompt({
|
||||
|
||||
|
||||
bootbox.dialog({
|
||||
title: "Wassup?",
|
||||
message: "Test Dialog",
|
||||
callback: function (result) { }
|
||||
});
|
||||
|
||||
Vendored
+7
-3
@@ -1,6 +1,6 @@
|
||||
// Type definitions for Bootbox 4.4.0
|
||||
// Project: https://github.com/makeusabrew/bootbox
|
||||
// Definitions by: Vincent Bortone <https://github.com/vbortone/>, Kon Pik <https://github.com/konpikwastaken/>, Anup Kattel <https://github.com/kanup/>
|
||||
// Definitions by: Vincent Bortone <https://github.com/vbortone/>, Kon Pik <https://github.com/konpikwastaken/>, Anup Kattel <https://github.com/kanup/>, Dominik Schroeter <https://github.com/icereed/>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
/// <reference path="../jquery/jquery.d.ts" />
|
||||
@@ -28,6 +28,10 @@ interface BootboxButton {
|
||||
callback?: () => any;
|
||||
}
|
||||
|
||||
interface BootboxButtonMap {
|
||||
[key: string]: BootboxButton | Function;
|
||||
}
|
||||
|
||||
interface BootboxDialogOptions {
|
||||
message: string | Element;
|
||||
title?: string | Element;
|
||||
@@ -40,7 +44,7 @@ interface BootboxDialogOptions {
|
||||
animate?: boolean;
|
||||
className?: string;
|
||||
size?: string;
|
||||
buttons?: Object; // complex object where each key is of type BootboxButton
|
||||
buttons?: BootboxButtonMap; // complex object where each key is of type BootboxButton
|
||||
}
|
||||
|
||||
interface BootboxDefaultOptions {
|
||||
@@ -69,7 +73,7 @@ interface BootboxStatic {
|
||||
dialog(options: BootboxDialogOptions): JQuery;
|
||||
setDefaults(options: BootboxDefaultOptions): void;
|
||||
hideAll(): void;
|
||||
|
||||
|
||||
addLocale(name: string, values: BootboxLocaleValues): void;
|
||||
removeLocale(name: string): void;
|
||||
setLocale(name: string): void;
|
||||
|
||||
@@ -57,7 +57,7 @@ var log = bunyan.createLogger(options);
|
||||
log.addSerializers(bunyan.stdSerializers);
|
||||
var child = log.child({name: 'child'});
|
||||
child.reopenFileStreams();
|
||||
log.addStream({path: '/dev/null', name: 'stream1'});
|
||||
log.addStream({path: '/dev/null'});
|
||||
child.level(bunyan.DEBUG);
|
||||
child.level('debug');
|
||||
child.levels(0, bunyan.ERROR);
|
||||
|
||||
Vendored
+177
-160
@@ -108,7 +108,7 @@ declare module CanvasJS {
|
||||
*/
|
||||
animationEnabled?: boolean;
|
||||
/**
|
||||
* While exporting any chart, “Chart” is used as the default fine name with corresponding extension “jpg” or “png”. You can override this name using exportFileName property.
|
||||
* While exporting any chart, "Chart" is used as the default fine name with corresponding extension "jpg" or "png". You can override this name using exportFileName property.
|
||||
* Default: Chart
|
||||
*/
|
||||
exportFileName?: string;
|
||||
@@ -126,25 +126,25 @@ declare module CanvasJS {
|
||||
zoomEnabled?: boolean;
|
||||
/**
|
||||
* Sets the theme of the Chart. Various predefined themes are bundled along with the library. User can easily switch these themes by changing theme property to the below mentioned options.
|
||||
* Default: “theme1″
|
||||
* Options: “theme1″,”theme2″, “theme3″
|
||||
* Default: "theme1"
|
||||
* Options: "theme1","theme2", "theme3"
|
||||
*/
|
||||
theme?: string;
|
||||
/**
|
||||
* Sets the background color of entire Chart Area. Values can be “HTML Color Name”, “hex code” or “rgba values”
|
||||
* Default: “white”
|
||||
* Example: “yellow”, “#F5DEB3″..
|
||||
* Sets the background color of entire Chart Area. Values can be "HTML Color Name", "hex code" or "rgba values"
|
||||
* Default: "white"
|
||||
* Example: "yellow", "#F5DEB3"..
|
||||
*/
|
||||
backgroundColor?: string;
|
||||
/**
|
||||
* Sets the colorSet of the Chart. Color Set is an array of colors that are used to render data. Various predefined Color Sets are bundled along with the library. You can either choose from the pre-defined Color Sets or define your own Color Set.
|
||||
* Default: “colorset1″ or as defined in the selected theme
|
||||
* Example: “colorSet1″, “colorSet2″, “colorSet3″
|
||||
* Default: "colorset1" or as defined in the selected theme
|
||||
* Example: "colorSet1", "colorSet2", "colorSet3"
|
||||
*/
|
||||
colorSet?: string;
|
||||
/**
|
||||
* CanvasJS allows you to localize various culture / language / country specific elements in the Chart like number formatting style – where you can choose which character to use as a decimal separator and as a digit group separator (also referred to as a thousand separator). By default CanvasJS is set to Neutral English Culture – “en”.
|
||||
* Default: “en”
|
||||
* CanvasJS allows you to localize various culture / language / country specific elements in the Chart like number formatting style – where you can choose which character to use as a decimal separator and as a digit group separator (also referred to as a thousand separator). By default CanvasJS is set to Neutral English Culture – "en".
|
||||
* Default: "en"
|
||||
*/
|
||||
culture?: string;
|
||||
/**
|
||||
@@ -190,19 +190,19 @@ declare module CanvasJS {
|
||||
/**
|
||||
* Sets the Title’s text.
|
||||
* Default: null
|
||||
* Example: “Chart title”
|
||||
* Example: "Chart title"
|
||||
*/
|
||||
text?: string;
|
||||
/**
|
||||
* This property lets you align the Chart Title vertically.
|
||||
* Default: “top”
|
||||
* Options: “top”, “center”, “bottom”
|
||||
* Default: "top"
|
||||
* Options: "top", "center", "bottom"
|
||||
*/
|
||||
verticalAlign?: string;
|
||||
/**
|
||||
* This property lets you align the Chart Title horizontally.
|
||||
* Default: “center”
|
||||
* Options: “left”, “right”, “center”
|
||||
* Default: "center"
|
||||
* Options: "left", "right", "center"
|
||||
*/
|
||||
horizontalAlign?: string;
|
||||
/**
|
||||
@@ -213,26 +213,26 @@ declare module CanvasJS {
|
||||
fontSize?: number;
|
||||
/**
|
||||
* Sets the Font Family of Chart Title.
|
||||
* Default: “Calibri, Optima, Candara, Verdana, Geneva, sans-serif”
|
||||
* Example: “arial” , “tahoma”, “verdana” ..
|
||||
* Default: "Calibri, Optima, Candara, Verdana, Geneva, sans-serif"
|
||||
* Example: "arial" , "tahoma", "verdana" ..
|
||||
*/
|
||||
fontFamily?: string;
|
||||
/**
|
||||
* Sets the Font Weight used in the Chart Title.
|
||||
* Default: “bold”
|
||||
* Options: “lighter”, “normal”, “bold” , “bolder”
|
||||
* Default: "bold"
|
||||
* Options: "lighter", "normal", "bold" , "bolder"
|
||||
*/
|
||||
fontWeight?: string;
|
||||
/**
|
||||
* Sets the font color of Chart Title. The value of fontColor can be a “HTML Color Name” or “hex” code .
|
||||
* Default: “#3A3A3A”
|
||||
* Example: “red”, “#FAC003″ ..
|
||||
* Sets the font color of Chart Title. The value of fontColor can be a "HTML Color Name" or "hex" code .
|
||||
* Default: "#3A3A3A"
|
||||
* Example: "red", "#FAC003" ..
|
||||
*/
|
||||
fontColor?: string;
|
||||
/**
|
||||
* Sets the fontStyle of Chart Title. fontStyle can be set to one of the below options.
|
||||
* Default: “normal”
|
||||
* Options: “normal”, “italic” , “oblique”
|
||||
* Default: "normal"
|
||||
* Options: "normal", "italic" , "oblique"
|
||||
*/
|
||||
fontStyle?: string;
|
||||
/**
|
||||
@@ -248,15 +248,15 @@ declare module CanvasJS {
|
||||
*/
|
||||
cornerRadius?: number;
|
||||
/**
|
||||
* Sets the color of border around Chart Title. Values of borderColor can be “HTML Color Name” or “hex” code .
|
||||
* Default: “black”
|
||||
* Example: “red”, “#FF0000″ ..
|
||||
* Sets the color of border around Chart Title. Values of borderColor can be "HTML Color Name" or "hex" code .
|
||||
* Default: "black"
|
||||
* Example: "red", "#FF0000" ..
|
||||
*/
|
||||
borderColor?: string;
|
||||
/**
|
||||
* Sets the background color of Chart Title. Values can be “HTML Color Name” or “hex” code.
|
||||
* Sets the background color of Chart Title. Values can be "HTML Color Name" or "hex" code.
|
||||
* Default: null
|
||||
* Example: “red”, “#FF0000″ ..
|
||||
* Example: "red", "#FF0000" ..
|
||||
*/
|
||||
backgroundColor?: string;
|
||||
/**
|
||||
@@ -274,6 +274,13 @@ declare module CanvasJS {
|
||||
}
|
||||
|
||||
interface ChartLegendOptions {
|
||||
/**
|
||||
* Sets the cursor type for legend items.
|
||||
* Default: "default"
|
||||
* Examples: "pointer", "crosshair" ..
|
||||
*/
|
||||
cursor?: string;
|
||||
|
||||
/**
|
||||
* Sets the font Size of Legend Text in pixels.
|
||||
* Default: 12
|
||||
@@ -282,38 +289,38 @@ declare module CanvasJS {
|
||||
fontSize?: number;
|
||||
/**
|
||||
* Sets the Font Family of Legend Text.
|
||||
* Default: “calibri”
|
||||
* Example: “arial” , “tahoma”, “verdana” ..
|
||||
* Default: "calibri"
|
||||
* Example: "arial" , "tahoma", "verdana" ..
|
||||
*/
|
||||
fontFamily?: string;
|
||||
/**
|
||||
* Sets the font color of Legend Text . The value of fontColor can be a “HTML Color Name” or “hex” code .
|
||||
* Default: “black”
|
||||
* Example: “red”, “#FAC003″ ..
|
||||
* Sets the font color of Legend Text . The value of fontColor can be a "HTML Color Name" or "hex" code .
|
||||
* Default: "black"
|
||||
* Example: "red", "#FAC003" ..
|
||||
*/
|
||||
fontColor?: string;
|
||||
/**
|
||||
* Sets the Font Weight of Legend Text.
|
||||
* Default: “normal”
|
||||
* Example: “lighter”, “normal”, “bold” , “bolder”
|
||||
* Default: "normal"
|
||||
* Example: "lighter", "normal", "bold" , "bolder"
|
||||
*/
|
||||
fontWeight?: string;
|
||||
/**
|
||||
* Sets the fontStyle of Legend Text. fontStyle can be set to one of the below options.
|
||||
* Default: “normal”
|
||||
* Example: “normal”, “italic” , “oblique”
|
||||
* Default: "normal"
|
||||
* Example: "normal", "italic" , "oblique"
|
||||
*/
|
||||
fontStyle?: string;
|
||||
/**
|
||||
* This property lets you align the Legend Position vertically.
|
||||
* Default: “bottom”
|
||||
* Example: “top”, “center”, “bottom”
|
||||
* Default: "bottom"
|
||||
* Example: "top", "center", "bottom"
|
||||
*/
|
||||
verticalAlign?: string;
|
||||
/**
|
||||
* This property lets you align the Legend Position horizontally.
|
||||
* Default: “right”
|
||||
* Example: “left”, “right”, “center”
|
||||
* Default: "right"
|
||||
* Example: "left", "right", "center"
|
||||
*/
|
||||
horizontalAlign?: string;
|
||||
/**
|
||||
@@ -373,13 +380,13 @@ declare module CanvasJS {
|
||||
/**
|
||||
* Sets the Axis Title.
|
||||
* Default: null
|
||||
* Example: “Axis X Title”
|
||||
* Example: "Axis X Title"
|
||||
*/
|
||||
title?: string;
|
||||
/**
|
||||
* Sets the Font Color of Axis Title. The value of titleFontColor can be a “HTML Color Name” or “hex” code .
|
||||
* Default: “#666666″
|
||||
* Example: “red”, “#006400″ .
|
||||
* Sets the Font Color of Axis Title. The value of titleFontColor can be a "HTML Color Name" or "hex" code .
|
||||
* Default: "#666666"
|
||||
* Example: "red", "#006400" .
|
||||
*/
|
||||
titleFontColor?: string;
|
||||
/**
|
||||
@@ -390,20 +397,20 @@ declare module CanvasJS {
|
||||
titleFontSize?: number;
|
||||
/**
|
||||
* Sets the Font Family of Axis Title.
|
||||
* Default: “Calibri, Optima, Candara, Verdana, Geneva, sans-serif”
|
||||
* Example: “calibri”, “tahoma, “verdana” ..
|
||||
* Default: "Calibri, Optima, Candara, Verdana, Geneva, sans-serif"
|
||||
* Example: "calibri", "tahoma, "verdana" ..
|
||||
*/
|
||||
titleFontFamily?: string;
|
||||
/**
|
||||
* Sets the Font Weight used in the Axis Title. It can be set to one of the options below.
|
||||
* Default: “normal”
|
||||
* Options: “lighter”, “normal”, “bold” , “bolder”
|
||||
* Default: "normal"
|
||||
* Options: "lighter", "normal", "bold" , "bolder"
|
||||
*/
|
||||
titleFontWeight?: string;
|
||||
/**
|
||||
* Sets the Font Style of Axis Title. It can be set to one of the below options.
|
||||
* Default: “normal”
|
||||
* Options: “normal”, “italic” , “oblique”
|
||||
* Default: "normal"
|
||||
* Options: "normal", "italic" , "oblique"
|
||||
*/
|
||||
titleFontStyle?: string;
|
||||
/**
|
||||
@@ -419,9 +426,9 @@ declare module CanvasJS {
|
||||
*/
|
||||
labelAngle?: number;
|
||||
/**
|
||||
* Sets the Axis Label color. The value of labelFontColor can be a “HTML Color Name” or “hex” code .
|
||||
* Default: “grey”
|
||||
* Example: “red”, “#FAC003″ ..
|
||||
* Sets the Axis Label color. The value of labelFontColor can be a "HTML Color Name" or "hex" code .
|
||||
* Default: "grey"
|
||||
* Example: "red", "#FAC003" ..
|
||||
*/
|
||||
labelFontColor?: string;
|
||||
/**
|
||||
@@ -432,32 +439,32 @@ declare module CanvasJS {
|
||||
labelFontSize?: number;
|
||||
/**
|
||||
* Sets the Font Family of Axis labels.
|
||||
* Default: “Calibri, Optima, Candara, Verdana, Geneva, sans-serif”
|
||||
* Example: “calibri”, “tahoma”, “verdana” ..
|
||||
* Default: "Calibri, Optima, Candara, Verdana, Geneva, sans-serif"
|
||||
* Example: "calibri", "tahoma", "verdana" ..
|
||||
*/
|
||||
labelFontFamily?: string;
|
||||
/**
|
||||
* Set the font Weight used in Axis Labels. It can be set to one of the options below.
|
||||
* Default: “normal”
|
||||
* Options: “lighter”, “normal”, “bold” , “bolder”
|
||||
* Default: "normal"
|
||||
* Options: "lighter", "normal", "bold" , "bolder"
|
||||
*/
|
||||
labelFontWeight?: string;
|
||||
/**
|
||||
* Sets the Font Style of Axis Labels. It can be set to one of the below options.
|
||||
* Default: “normal”
|
||||
* Options: “italic”, “oblique”, “normal”
|
||||
* Default: "normal"
|
||||
* Options: "italic", "oblique", "normal"
|
||||
*/
|
||||
labelFontStyle?: string;
|
||||
/**
|
||||
* A string that prepends all the labels on axisX.
|
||||
* Default: null
|
||||
* Example: “$”,”cat”..
|
||||
* Example: "$","cat"..
|
||||
*/
|
||||
prefix?: string;
|
||||
/**
|
||||
* A string that appends all the labels on axisX.
|
||||
* Default: null
|
||||
* Example: “$”,”cat”..
|
||||
* Example: "$","cat"..
|
||||
*/
|
||||
suffix?: string;
|
||||
/**
|
||||
@@ -483,10 +490,10 @@ declare module CanvasJS {
|
||||
*/
|
||||
interval?: number;
|
||||
/**
|
||||
* intervalType is the unit of interval property. intervalType is by default set to “number” and hence you need to specify the interval type (eg “week”, “month”, etc) depending on the type of interval you intend to set. If required interval is 3 months, you need to provide interval as 3 and intervalType as “month”
|
||||
* Default: Automatically handled when interval property is not set. Defaults to “number” when you set the interval.
|
||||
* Option: “number”,”millisecond” ,”second”,” minute”, “hour”, “day”, “month” ,”year”
|
||||
* Example: for interval as 15 minutes, set interval as 15, and set intervalType as “minute”,
|
||||
* intervalType is the unit of interval property. intervalType is by default set to "number" and hence you need to specify the interval type (eg "week", "month", etc) depending on the type of interval you intend to set. If required interval is 3 months, you need to provide interval as 3 and intervalType as "month"
|
||||
* Default: Automatically handled when interval property is not set. Defaults to "number" when you set the interval.
|
||||
* Option: "number","millisecond" ,"second"," minute", "hour", "day", "month" ,"year"
|
||||
* Example: for interval as 15 minutes, set interval as 15, and set intervalType as "minute",
|
||||
*/
|
||||
intervalType?: string;
|
||||
/**
|
||||
@@ -496,9 +503,9 @@ declare module CanvasJS {
|
||||
*/
|
||||
tickLength?: number;
|
||||
/**
|
||||
* Sets the color of Tick Marks drawn on the axis. The value of tickColor can be a “HTML Color Name” or “hex” code .
|
||||
* Default: “#BBBBBB”
|
||||
* Example: “red”, “#006400″.
|
||||
* Sets the color of Tick Marks drawn on the axis. The value of tickColor can be a "HTML Color Name" or "hex" code .
|
||||
* Default: "#BBBBBB"
|
||||
* Example: "red", "#006400".
|
||||
*/
|
||||
tickColor?: string;
|
||||
/**
|
||||
@@ -508,9 +515,9 @@ declare module CanvasJS {
|
||||
*/
|
||||
tickThickness?: number;
|
||||
/**
|
||||
* Sets the color of Axis line. Axis line color can be a “HTML Color Name” or “hex” code .
|
||||
* Default: “#BBBBBB”
|
||||
* Example: “blue”,”#21AB13″..
|
||||
* Sets the color of Axis line. Axis line color can be a "HTML Color Name" or "hex" code .
|
||||
* Default: "#BBBBBB"
|
||||
* Example: "blue","#21AB13"..
|
||||
*/
|
||||
lineColor?: string;
|
||||
/**
|
||||
@@ -520,9 +527,9 @@ declare module CanvasJS {
|
||||
*/
|
||||
lineThickness?: string;
|
||||
/**
|
||||
* Sets the Interlacing Color that alternates between the set interval. If the interval is not set explicitly, then the auto calculated interval is considered. The value of interlacedColor can be a “HTML Color Name” or “hex” code .
|
||||
* Sets the Interlacing Color that alternates between the set interval. If the interval is not set explicitly, then the auto calculated interval is considered. The value of interlacedColor can be a "HTML Color Name" or "hex" code .
|
||||
* Default: null
|
||||
* Example: “#F8F1E4″, “#FEFDDF” ….
|
||||
* Example: "#F8F1E4", "#FEFDDF" ….
|
||||
*/
|
||||
interlaceColor?: string;
|
||||
/**
|
||||
@@ -532,11 +539,21 @@ declare module CanvasJS {
|
||||
*/
|
||||
gridThickness?: number;
|
||||
/**
|
||||
* Sets the Color of Grid Lines. Value of gridColor can be a “HTML Color Name” or “hex” code .
|
||||
* Default: “#BBBBBB”
|
||||
* Example: “red”, “#FEFDDF” ..
|
||||
* Sets the Color of Grid Lines. Value of gridColor can be a "HTML Color Name" or "hex" code .
|
||||
* Default: "#BBBBBB"
|
||||
* Example: "red", "#FEFDDF" ..
|
||||
*/
|
||||
gridColor?: string;
|
||||
|
||||
/**
|
||||
* Sets the Interlacing Color that alternates between the set interval.
|
||||
* If the interval is not set explicitly, then the auto calculated interval is considered.
|
||||
* The value of interlacedColor can be an "HTML Color Name" or "hex" code.
|
||||
* Default: null
|
||||
* Example: "#F8F1E4", "#FEFDDF"
|
||||
*/
|
||||
interlacedColor?: string;
|
||||
|
||||
/**
|
||||
* Strip Lines are vertical or horizontal lines used to highlight/mark a certain region on the plot area. You can choose whether to draw a line at a specific position or shade a region on the plot area. Strip Lines are sometimes referred to as trend lines.
|
||||
* If you want to just mark a certain position on the axis, you can set the value attribute and it’ll draw a line at that position with the set thickness. If you want to shade a region instead, you need to set startValue and endValue attributes. This will fill the area within the specified range.
|
||||
@@ -573,32 +590,32 @@ declare module CanvasJS {
|
||||
thickness?: number;
|
||||
/**
|
||||
* Sets the color of the stripLine.
|
||||
* Default: “orange”
|
||||
* Example: “green”, “#23EA23″
|
||||
* Default: "orange"
|
||||
* Example: "green", "#23EA23"
|
||||
*/
|
||||
color?: string;
|
||||
/**
|
||||
* Sets the label of the stripLine. These are shown on top of axis labels.
|
||||
* Default: “” (empty string)
|
||||
* Example: “Threshold”, “Deaths in 1920″
|
||||
* Default: "" (empty string)
|
||||
* Example: "Threshold", "Deaths in 1920"
|
||||
*/
|
||||
label?: string;
|
||||
/**
|
||||
* Sets the background color of stripLine’s label.
|
||||
* Default: “#eeeeee”
|
||||
* Example: “red”,”#fabd76″
|
||||
* Default: "#eeeeee"
|
||||
* Example: "red","#fabd76"
|
||||
*/
|
||||
labelBackgroundColor?: string;
|
||||
/**
|
||||
* Sets the font-family of stripLine’s label. If the first font is not found in the system from the specified font-family list, it tries to use the next font in the list.
|
||||
* Default: “arial”
|
||||
* Example: “Arial, Trebuchet MS, Tahoma, sans-serif”
|
||||
* Default: "arial"
|
||||
* Example: "Arial, Trebuchet MS, Tahoma, sans-serif"
|
||||
*/
|
||||
labelFontFamily?: string;
|
||||
/**
|
||||
* Sets the font color of label.
|
||||
* Default: “orange”
|
||||
* Example: “blue”,”#4135e9″
|
||||
* Default: "orange"
|
||||
* Example: "blue","#4135e9"
|
||||
*/
|
||||
labelFontColor?: string;
|
||||
/**
|
||||
@@ -609,14 +626,14 @@ declare module CanvasJS {
|
||||
labelFontSize?: number;
|
||||
/**
|
||||
* Sets the font weight of stripLine’s label.
|
||||
* Default: “normal”
|
||||
* Example: “lighter”,”normal”,”bold”,”bolder”
|
||||
* Default: "normal"
|
||||
* Example: "lighter","normal","bold","bolder"
|
||||
*/
|
||||
labelFontWeight?: string;
|
||||
/**
|
||||
* Sets the font style of stripLine’s label.
|
||||
* Default: “normal”
|
||||
* Example: “normal”,”italic”,”oblique”
|
||||
* Default: "normal"
|
||||
* Example: "normal","italic","oblique"
|
||||
*/
|
||||
labelFontStyle?: string;
|
||||
}
|
||||
@@ -657,7 +674,7 @@ declare module CanvasJS {
|
||||
/**
|
||||
* Sets the border color around Tool Tip. When not set it takes the color of corresponding dataSeries or dataPoint.
|
||||
* Default: dataSeries color/ dataPoint color
|
||||
* Example: “red”, “#808080″..
|
||||
* Example: "red", "#808080"..
|
||||
*/
|
||||
borderColor?: string;
|
||||
}
|
||||
@@ -665,53 +682,53 @@ declare module CanvasJS {
|
||||
interface ChartDataCommon {
|
||||
/**
|
||||
* Sets the dataPoint Name. dataPoint name is shown in various places like toolTip & legend unless overridden.
|
||||
* Default: Automatically Named (“dataPoint 1″, “dataPoint 2″ .. )
|
||||
* Example: “apple”, “mango” ..
|
||||
* Default: Automatically Named ("dataPoint 1", "dataPoint 2" .. )
|
||||
* Example: "apple", "mango" ..
|
||||
*/
|
||||
name?: string;
|
||||
/**
|
||||
* Sets the color of dataSeries. The value of tickColor can be a “HTML Color Name” or “Hex Code”.
|
||||
* Sets the color of dataSeries. The value of tickColor can be a "HTML Color Name" or "Hex Code".
|
||||
* Default: Automatically set from Theme.
|
||||
* Example: “red”, “green” ..
|
||||
* Example: "red", "green" ..
|
||||
*/
|
||||
color?: string;
|
||||
/**
|
||||
* Instead of setting string values for all indexLabels, you can also use keywords like x, y, etc that will automatically show corresponding properties as indexLabel. This will allow you to define indexLabel at the series level once. While setting indexLabel you specify a keyword by enclosing it in flower brackets like {x}, {y}, {color}, etc.
|
||||
* Range Charts have two indexLabels – one for each y value. This requires the use of a special keyword #index to show index label on either sides of the column/bar/area.
|
||||
* eg: indexLabel: “{x}: {y[#index]}”
|
||||
* eg: indexLabel: "{x}: {y[#index]}"
|
||||
* Important keywords to keep in mind are. {x}, {y}, {name}, {label}.
|
||||
* Default: null
|
||||
* Example: “{label}”, “Win”, “x: {x}, y: {y} ”
|
||||
* Example: "{label}", "Win", "x: {x}, y: {y} "
|
||||
*/
|
||||
indexLabel?: string;
|
||||
/**
|
||||
* Using this property you can define whether to render indexLabel “inside” or “outside” the dataPoint.
|
||||
* Default: “outside”
|
||||
* Example: “outside”, “inside”
|
||||
* Using this property you can define whether to render indexLabel "inside" or "outside" the dataPoint.
|
||||
* Default: "outside"
|
||||
* Example: "outside", "inside"
|
||||
*/
|
||||
indexLabelPlacement?: string;
|
||||
/**
|
||||
* Sets the Orientation of indexLabel to “horizontal” or “vertical”.
|
||||
* Default: “horizontal”
|
||||
* Options: “horizontal”, “vertical”
|
||||
* Sets the Orientation of indexLabel to "horizontal" or "vertical".
|
||||
* Default: "horizontal"
|
||||
* Options: "horizontal", "vertical"
|
||||
*/
|
||||
indexLabelOrientation?: string;
|
||||
/**
|
||||
* Sets the Background color of Index Labels. The value of indexLabelBackgroundColor can be a “HTML Color Name” or “Hex Code”.
|
||||
* Sets the Background color of Index Labels. The value of indexLabelBackgroundColor can be a "HTML Color Name" or "Hex Code".
|
||||
* Default: null
|
||||
* Example: “red”, “#FAC003″ ..
|
||||
* Example: "red", "#FAC003" ..
|
||||
*/
|
||||
indexLabelBackgroundColor?: string;
|
||||
/**
|
||||
* Sets the Index Label’s Font Style. It can be set to one of the below options.
|
||||
* Default: “normal”
|
||||
* Options: “italic”, “oblique”, “normal”
|
||||
* Default: "normal"
|
||||
* Options: "italic", "oblique", "normal"
|
||||
*/
|
||||
indexLabelFontStyle?: string;
|
||||
/**
|
||||
* Sets the Index Label’s Font color. The value of IndexLabelFontColor can be a “HTML Color Name” or “Hex Code”.
|
||||
* Default: “grey”
|
||||
* Example: “red”, “#FAC003″ ..
|
||||
* Sets the Index Label’s Font color. The value of IndexLabelFontColor can be a "HTML Color Name" or "Hex Code".
|
||||
* Default: "grey"
|
||||
* Example: "red", "#FAC003" ..
|
||||
*/
|
||||
indexLabelFontColor?: string;
|
||||
/**
|
||||
@@ -722,24 +739,24 @@ declare module CanvasJS {
|
||||
indexLabelFontSize?: number;
|
||||
/**
|
||||
* Sets the Index Label’s Font Family.
|
||||
* Default: “Calibri, Optima, Candara, Verdana, Geneva, sans-serif”
|
||||
* Example: “calibri”, “tahoma”, “verdana”..
|
||||
* Default: "Calibri, Optima, Candara, Verdana, Geneva, sans-serif"
|
||||
* Example: "calibri", "tahoma", "verdana"..
|
||||
*/
|
||||
indexLabelFontFamily?: string;
|
||||
/**
|
||||
* Sets the Index Label’s Font Weight. It can be set to one of the below options.
|
||||
* Default: “normal”
|
||||
* Example: “lighter”, “normal” ,”bold” , “bolder”
|
||||
* Default: "normal"
|
||||
* Example: "lighter", "normal" ,"bold" , "bolder"
|
||||
*/
|
||||
indexLabelFontWeight?: string;
|
||||
/**
|
||||
* Sets the color of line connecting index labels with their dataPoint. It is only applicable for pie and doughnut chart when indexLabelPlacment is outside. The value of indexLineColor can be a “HTML Color Name” or “Hex Code”.
|
||||
* Default: “lightgrey”
|
||||
* Example: “red”, “#FAC003″ ..
|
||||
* Sets the color of line connecting index labels with their dataPoint. It is only applicable for pie and doughnut chart when indexLabelPlacment is outside. The value of indexLineColor can be a "HTML Color Name" or "Hex Code".
|
||||
* Default: "lightgrey"
|
||||
* Example: "red", "#FAC003" ..
|
||||
*/
|
||||
indexLabelLineColor?: string;
|
||||
/**
|
||||
* Sets the thickness of line connecting indexLabel with its corresponding dataPoint. It is only applicable for pie and doughnut chart when indexLabelPlacement is set to “outside”.
|
||||
* Sets the thickness of line connecting indexLabel with its corresponding dataPoint. It is only applicable for pie and doughnut chart when indexLabelPlacement is set to "outside".
|
||||
* Default: 2
|
||||
* Example: 4, 6
|
||||
*/
|
||||
@@ -752,14 +769,14 @@ declare module CanvasJS {
|
||||
/**
|
||||
* Sets marker type to be rendered at each dataPoint. While markers are helpful in highlighting individual dataPoints, they do not help much when the dataPoints are crowded. In case of large number of dataPoints it is recommended to disable markers in order to improve the appearance and performance of chart.
|
||||
* Same marker type is also used in legend unless overridden by legendMarkerType property.
|
||||
* Default: “circle”
|
||||
* Options: “none”, “circle”, “square”, “triangle” and “cross”
|
||||
* Default: "circle"
|
||||
* Options: "none", "circle", "square", "triangle" and "cross"
|
||||
*/
|
||||
markerType?: string;
|
||||
/**
|
||||
* Sets the color of marker that is displayed on the Chart. Legend Marker for the series uses the same Color as set here unless overridden using legendMarkerColor property.
|
||||
* Default: dataSeries Color
|
||||
* Example: “red”, “#008000″ ..
|
||||
* Example: "red", "#008000" ..
|
||||
*/
|
||||
markerColor?: string;
|
||||
/**
|
||||
@@ -769,9 +786,9 @@ declare module CanvasJS {
|
||||
*/
|
||||
markerSize?: number;
|
||||
/**
|
||||
* Sets the border color around marker. Value of markerBorderColor can be “HTML Color Name” or “hex code”.
|
||||
* Sets the border color around marker. Value of markerBorderColor can be "HTML Color Name" or "hex code".
|
||||
* Default: dataSeries color.
|
||||
* Example: “red”, “#008000″ ..
|
||||
* Example: "red", "#008000" ..
|
||||
*/
|
||||
markerBorderColor?: string;
|
||||
/**
|
||||
@@ -782,14 +799,14 @@ declare module CanvasJS {
|
||||
markerBorderThickness?: number;
|
||||
/**
|
||||
* Sets the text that describes the dataSeries in legend.
|
||||
* Default: “DataSeries 1″, “DataSeries 2″ ..etc
|
||||
* Example: “2010″, “2011″..
|
||||
* Default: "DataSeries 1", "DataSeries 2" ..etc
|
||||
* Example: "2010", "2011"..
|
||||
*/
|
||||
legendText?: string;
|
||||
/**
|
||||
* Sets the Legend Marker to one of the options below. This property is used to override the default marker in legend, which is same as dataSeries Marker Type.
|
||||
* Default: same as markerType
|
||||
* Options: “circle”, “square”, “cross” and “triangle”
|
||||
* Options: "circle", "square", "cross" and "triangle"
|
||||
*/
|
||||
legendMarkerType?: string;
|
||||
/**
|
||||
@@ -798,9 +815,9 @@ declare module CanvasJS {
|
||||
*/
|
||||
click?: (event: ChartEvent) => void;
|
||||
/**
|
||||
* Sets the color of marker that is displayed on legend. This property overrides default Marker’s Color in Legend, which is same as dataSeries Marker Color. Value of legendMarkerColor can be “HTML Color Name” or “hex code”.
|
||||
* Sets the color of marker that is displayed on legend. This property overrides default Marker’s Color in Legend, which is same as dataSeries Marker Color. Value of legendMarkerColor can be "HTML Color Name" or "hex code".
|
||||
* Default: dataSeries marker color
|
||||
* Example: “red”, “#008000″ ..
|
||||
* Example: "red", "#008000" ..
|
||||
*/
|
||||
legendMarkerColor?: string;
|
||||
/**
|
||||
@@ -829,39 +846,39 @@ declare module CanvasJS {
|
||||
visible?: boolean;
|
||||
/**
|
||||
* Sets the type of chart to be rendered for corresponding dataSeries. One can choose from the following options.
|
||||
* Default: “column”
|
||||
* Default: "column"
|
||||
* Options:
|
||||
* “line”
|
||||
* “column”
|
||||
* “bar”
|
||||
* “area”
|
||||
* “spline”
|
||||
* “splineArea”
|
||||
* “stepLine”
|
||||
* “scatter”
|
||||
* “bubble”
|
||||
* “stackedColumn”
|
||||
* “stackedBar”
|
||||
* “stackedArea”
|
||||
* “stackedColumn100″
|
||||
* “stackedBar100″
|
||||
* “stackedArea100″
|
||||
* “pie”
|
||||
* “doughnut”
|
||||
* "line"
|
||||
* "column"
|
||||
* "bar"
|
||||
* "area"
|
||||
* "spline"
|
||||
* "splineArea"
|
||||
* "stepLine"
|
||||
* "scatter"
|
||||
* "bubble"
|
||||
* "stackedColumn"
|
||||
* "stackedBar"
|
||||
* "stackedArea"
|
||||
* "stackedColumn100"
|
||||
* "stackedBar100"
|
||||
* "stackedArea100"
|
||||
* "pie"
|
||||
* "doughnut"
|
||||
*/
|
||||
type?: string;
|
||||
/**
|
||||
* Setting axisYType lets you choose between primary and secondary Y Axis for a dataSeries to plot against. By choosing “secondary” Axis you can plot the series against axisY2.
|
||||
* Setting axisYType lets you choose between primary and secondary Y Axis for a dataSeries to plot against. By choosing "secondary" Axis you can plot the series against axisY2.
|
||||
* In case of Multi-Series or Combinational Charts, one can assign primary axis to some series and secondary axis to other series.
|
||||
* This is helpful when dataSeries objects use different unit of measurement or range of data. By default, all series are plotted against primary Y axis.
|
||||
* Default: “primary”
|
||||
* Options: “primary”, “secondary”
|
||||
* Default: "primary"
|
||||
* Options: "primary", "secondary"
|
||||
*/
|
||||
axisYType?: string;
|
||||
/**
|
||||
* This defines the data type of x values. Data Type is normally figured out by default based on the object type that is assigned to x. But if you are providing time stamp (which is integer) values instead of Date objects, you’ll have to explicitly set the xValueType to “dateTime”.
|
||||
* This defines the data type of x values. Data Type is normally figured out by default based on the object type that is assigned to x. But if you are providing time stamp (which is integer) values instead of Date objects, you’ll have to explicitly set the xValueType to "dateTime".
|
||||
* Default: Automatically Calculated
|
||||
* Options: “number”, “dateTime”
|
||||
* Options: "number", "dateTime"
|
||||
*/
|
||||
xValueType?: string;
|
||||
/**
|
||||
@@ -878,8 +895,8 @@ declare module CanvasJS {
|
||||
zValueFormatString?: string;
|
||||
/**
|
||||
* Sets the bevel property, which creates a chiselled effect at the corners of a Column Charts and Bar Charts.
|
||||
* Default: “true”
|
||||
* Example: “true”, “false”
|
||||
* Default: "true"
|
||||
* Example: "true", "false"
|
||||
*/
|
||||
bevelEnabled?: boolean;
|
||||
/**
|
||||
@@ -907,8 +924,8 @@ declare module CanvasJS {
|
||||
showInLegend?: boolean;
|
||||
/**
|
||||
* In candle Stick chart, when Closing Price is greater than Opening price, the body is filled with white by default and it can be overridden by risingColor property.
|
||||
* Default: “white”
|
||||
* Options: “red”, “#DD7E86″, etc.
|
||||
* Default: "white"
|
||||
* Options: "red", "#DD7E86", etc.
|
||||
*/
|
||||
risingColor?: string;
|
||||
/**
|
||||
@@ -940,7 +957,7 @@ declare module CanvasJS {
|
||||
/**
|
||||
* Sets label value of a dataPoint. The value appears next to the dataPoint on axisX Line. If not provided, it takes x value for label.
|
||||
* Default: x value
|
||||
* Example: “label1″, “label2″..
|
||||
* Example: "label1", "label2"..
|
||||
*/
|
||||
label?: string;
|
||||
/**
|
||||
@@ -950,9 +967,9 @@ declare module CanvasJS {
|
||||
*/
|
||||
exploded?: boolean;
|
||||
/**
|
||||
* Sets the color of marker that is displayed on legend. This property works only with Pie and Doughnut charts. Value of legendMarkerColor can be “HTML Color Name” or “hex” code.
|
||||
* Sets the color of marker that is displayed on legend. This property works only with Pie and Doughnut charts. Value of legendMarkerColor can be "HTML Color Name" or "hex" code.
|
||||
* Default: dataSeries marker color
|
||||
* Example: “red”, “#008000″..
|
||||
* Example: "red", "#008000"..
|
||||
*/
|
||||
legendMarkerColor?: string;
|
||||
}
|
||||
|
||||
+1
-1
@@ -115,7 +115,7 @@ function exist() {
|
||||
should.not.exist(void (0));
|
||||
}
|
||||
|
||||
function arguments() {
|
||||
function argumentsTest() {
|
||||
var args = arguments;
|
||||
expect(args).to.be.arguments;
|
||||
args.should.be.arguments;
|
||||
|
||||
Vendored
+1
-1
@@ -127,7 +127,7 @@ declare module Chance {
|
||||
guid(): string;
|
||||
hash(opts?: Options): string;
|
||||
n<T>(generator: () => T, count: number, opts?: Options): T[];
|
||||
normal(opts?: Options): string;
|
||||
normal(opts?: Options): number;
|
||||
radio(opts?: Options): string;
|
||||
rpg(dice: string): number[];
|
||||
rpg(dice: string, opts?: Options): number[]|number;
|
||||
|
||||
Vendored
+2
@@ -74,6 +74,8 @@ interface Cheerio {
|
||||
|
||||
children(selector?: string): Cheerio;
|
||||
|
||||
contents(): Cheerio;
|
||||
|
||||
each(func: (index: number, element: CheerioElement) => any): Cheerio;
|
||||
map(func: (index: number, element: CheerioElement) => any): Cheerio;
|
||||
|
||||
|
||||
@@ -16,7 +16,6 @@ var nodeName = divTag2[0].nodeName;
|
||||
var version = $.version;
|
||||
var libraryName = $.libraryName;
|
||||
var els = $('li');
|
||||
var listItems = $.slice(els);
|
||||
var madeEls = $.make('<p>Stuff</p>');
|
||||
var moreEls = $.html('<p>Stuff</p>');
|
||||
var oldTag = $('#oldTag');
|
||||
@@ -241,109 +240,145 @@ var myPromise = new Promise(function(resolve, reject) {
|
||||
myPromise.then(function(value) {
|
||||
// Success:
|
||||
console.log(value);
|
||||
},
|
||||
// Opps! There was a problem:
|
||||
function(reason) {
|
||||
console.log(reason);
|
||||
});
|
||||
},
|
||||
// Opps! There was a problem:
|
||||
function(reason) {
|
||||
console.log(reason);
|
||||
});
|
||||
|
||||
// Ajax:
|
||||
$.ajax({
|
||||
url: "announcement.html",
|
||||
dataType: "html",
|
||||
success: function(data) {
|
||||
// Insert the fragment into the page:
|
||||
$("#content").html(data);
|
||||
},
|
||||
error: function(data) {
|
||||
$("#content").html("<h4>There was an error while trying to get the file.</h4>");
|
||||
}
|
||||
// Fetch API
|
||||
//===========
|
||||
// GET:
|
||||
interface WineObject {
|
||||
data: Array<WineInterface>;
|
||||
}
|
||||
interface WineInterface {
|
||||
wine: {
|
||||
name: string;
|
||||
}
|
||||
}
|
||||
fetch('../data/wines.json')
|
||||
.then($.json)
|
||||
.then(function<WineObject>(obj: any):any {
|
||||
$('#message_ajax').empty();
|
||||
obj.data.forEach(function(wine: any) {
|
||||
$('#message_ajax').append('<li>' + wine.name + '</li>');
|
||||
})
|
||||
});
|
||||
$.ajax({
|
||||
url: "me.json",
|
||||
success: function(data) {
|
||||
// Before using a JSON object, you need to parse it.
|
||||
// Here we parse it and assign it to a variable:
|
||||
var me = JSON.parse(data);
|
||||
// Here we access the properties of the JSON object:
|
||||
$("#content").html(me.firstName + " " + me.lastName);
|
||||
},
|
||||
error: function(data) {
|
||||
$('#content').html("<h4>There was an error while trying to get the file.</h4>");
|
||||
}
|
||||
});
|
||||
var myData = {
|
||||
"name": "Bozo the Clown",
|
||||
"occupation": "Clown"
|
||||
};
|
||||
var mySuccessCallback = function() {
|
||||
console.log('The post was a success!');
|
||||
};
|
||||
var myErrorCallback = function() {
|
||||
console.log('Ooops! There was a problem posting this.');
|
||||
};
|
||||
$.ajax({
|
||||
url: "/path/to/controller",
|
||||
method: 'POST',
|
||||
headers: {
|
||||
"Content-Type": "application/x-www-form-urlencoded",
|
||||
"async": true,
|
||||
"Access-Control-Allow-Origin": "*",
|
||||
"Accept": "text/plain"
|
||||
},
|
||||
data: myData,
|
||||
success: mySuccessCallback,
|
||||
error: myErrorCallback
|
||||
});
|
||||
$.get('http://my.com/data/stuff.html')
|
||||
.then(function(response) {
|
||||
console.log("Success!", response);
|
||||
}, function(error) {
|
||||
console.error("Failed!", error);
|
||||
});
|
||||
|
||||
$.get('http://my.com/data/stuff.html')
|
||||
.then(function(response) {
|
||||
console.log("Success!", response);
|
||||
})
|
||||
.catch(function(error) {
|
||||
console.error("Failed!", error);
|
||||
});
|
||||
$.get('story.json')
|
||||
.then(JSON.parse)
|
||||
.then(function(response) {
|
||||
console.log("Yey JSON!", response);
|
||||
});
|
||||
$.getJSON('/data/deserts.json', function(desserts: Array<any>) {
|
||||
desserts.forEach(function(dessert) {
|
||||
$('#deserts').append('<li>' + dessert.name + '</li>');
|
||||
});
|
||||
});
|
||||
$.post("updateUser.php",
|
||||
{ "name": "Joe", "time": "10PM" },
|
||||
function() {
|
||||
console.log('The POST was successful.')
|
||||
},
|
||||
"json"
|
||||
);
|
||||
$.JSONP({ url: 'https://api.github.com/users/yui?callback=?' })
|
||||
.then(function(users) {
|
||||
$('.list').append('<li><h3>The name of the library</h3><h4>' + users.data.name + '</h4></li>');
|
||||
})
|
||||
.catch(function(err) {
|
||||
console.log('Unable to get data.')
|
||||
});
|
||||
|
||||
$.JSONP({
|
||||
url: 'http://www.geonames.org/postalCodeLookupJSON?postalcode=94102&'
|
||||
// POST:
|
||||
interface postData {
|
||||
email: string;
|
||||
name: string;
|
||||
msg: string;
|
||||
}
|
||||
var formData = $.serialize($('form')[0]);
|
||||
fetch('../controllers/php-post.php', {
|
||||
method: 'post',
|
||||
headers: {
|
||||
"Content-type": "application/x-www-form-urlencoded; charset=UTF-8"
|
||||
},
|
||||
body: formData
|
||||
})
|
||||
.then(function(data) {
|
||||
$('.list').append('<li><h3>My Location</h3><h4>' + data.postalcodes[0].adminName2 + ', ' + data.postalcodes[0].adminName1 + '</h4></li>');
|
||||
.then($.json)
|
||||
.then(function<postData>(data: any): any {
|
||||
if(data.email_check == "valid"){
|
||||
$("#message_ajax").html("<div class='successMessage'>" + data.email + " is a valid e-mail address. Thank you, " + data.name + ".</div>");
|
||||
$("#message_ajax").append('<p>' + data.msg + '</p>');
|
||||
} else {
|
||||
$("#message_ajax").html("<div class='errorMessage'>Sorry " + data.name + ", " + data.email + " is NOT a valid e-mail address. Try again.</div>");
|
||||
}
|
||||
});
|
||||
// PUT:
|
||||
interface putData {
|
||||
base: string;
|
||||
result: string;
|
||||
fileName: string;
|
||||
}
|
||||
var putData = $('#fileText').val();
|
||||
fetch('../controllers/php-put.php', {
|
||||
method: 'put',
|
||||
headers: {
|
||||
"Content-type": "application/x-www-form-urlencoded; charset=UTF-8"
|
||||
},
|
||||
body: putData
|
||||
})
|
||||
.then($.json)
|
||||
.then(function<putData>(data:any): any {
|
||||
console.dir(data.base);
|
||||
$("#message_ajax").append('<p>' + data.result + '</p>');
|
||||
$("#message_ajax").append('<p>The file name is: ' + data.fileName + '</p>');
|
||||
})
|
||||
.catch(function(error:Error) {
|
||||
console.log(error);
|
||||
$("#message_ajax").html("<div class='errorMessage'>Sorry, put was not successful.</div>");
|
||||
});
|
||||
|
||||
|
||||
// DELETE:
|
||||
interface deleteData {
|
||||
result: string;
|
||||
}
|
||||
var file = $('#fileName').val();
|
||||
fetch('../controllers/php-delete.php', {
|
||||
method: 'delete',
|
||||
headers: {
|
||||
"Content-type": "application/x-www-form-urlencoded; charset=UTF-8"
|
||||
},
|
||||
body: file
|
||||
})
|
||||
.then($.json)
|
||||
.then(function<deleteData>(data: any): any {
|
||||
$("#message_ajax").html("<div>DELETE was sent to the server successfully.</div>");
|
||||
$("#message_ajax").append('<p>' + data.result + '</p>');
|
||||
},
|
||||
function(data: any) {
|
||||
console.log('PROBLEM')
|
||||
console.log(data);
|
||||
})
|
||||
.catch(function(error: any) {
|
||||
$("#message_ajax").html("<div class='errorMessage'>Sorry, 'DELETE' was not successful.</div>");
|
||||
error.reject();
|
||||
});
|
||||
|
||||
// Timeout:
|
||||
var formData2 = $.serialize($('form')[0]);
|
||||
fetch('../controllers/php-post.php', {
|
||||
method: 'post',
|
||||
headers: {
|
||||
"Content-type": "application/x-www-form-urlencoded; charset=UTF-8"
|
||||
},
|
||||
body: formData,
|
||||
// Set timeout:
|
||||
timeout: 10000
|
||||
})
|
||||
.then($.json)
|
||||
.then(function <postData>(data: any): any {
|
||||
if (data.email_check == "valid") {
|
||||
$("#message_ajax").html("<div class='successMessage'>" + data.email + " is a valid e-mail address. Thank you, " + data.name + ".</div>");
|
||||
$("#message_ajax").append('<p>' + data.msg + '</p>');
|
||||
} else {
|
||||
$("#message_ajax").html("<div class='errorMessage'>Sorry " + data.name + ", " + data.email + " is NOT a valid e-mail address. Try again.</div>");
|
||||
}
|
||||
})
|
||||
.catch(function(err) {
|
||||
console.log('Unable to get data.')
|
||||
// Catch timeout:
|
||||
.catch(function(error) {
|
||||
console.log(error);
|
||||
});
|
||||
|
||||
// $.jsonp:
|
||||
$.jsonp('https://api.github.com/users/rbiggs/repos?name=chipper', {timeout: 10000})
|
||||
.then($.json)
|
||||
.then(function(obj: any): any {
|
||||
console.log(obj);
|
||||
obj.data.forEach(function(repo: any): any {
|
||||
$('#message_ajax').append("<li>" + repo.name + "</li>");
|
||||
});
|
||||
})
|
||||
.catch(function(error: any): any {
|
||||
$('#message_ajax').append("<li>" + error.message + "</li>")
|
||||
});
|
||||
|
||||
// Templates:
|
||||
var myTemplate = '<li>Name: [[= data.name]]</li>';
|
||||
var userInfo = {
|
||||
@@ -376,10 +411,10 @@ var repeaterTmplate2 = '<li>[[= data.firstName ]], [[= data.lastName]]</li>';
|
||||
$.template.repeater($('#objectArrayList'), repeaterTmplate2, luminaries.persons);
|
||||
|
||||
// Pub/Sub:
|
||||
var arraySubscriber = function(topic: string, data: any) {
|
||||
var arraySubscriber = function(topic: string, data: any): any {
|
||||
$('.list').append('<li><h3>' + topic + '</h3><h4>' + data + '</h4></li>');
|
||||
var newsSubscription = $.subscribe('news/update', arraySubscriber);
|
||||
};
|
||||
var newsSubscription = $.subscribe('news/update', arraySubscriber);
|
||||
$.publish('news/update', 'The New York Stock Exchange rose an unprecedented 1000 points in just three minutes. Analysts and investors are confused and uncertain how to respond.');
|
||||
$.unsubscribe('news/update');
|
||||
// Due to being unsubscribed above, this does nothing:
|
||||
|
||||
Vendored
+1335
-1323
File diff suppressed because it is too large
Load Diff
@@ -197,3 +197,55 @@ function proxySettings() {
|
||||
// clear with a scope set
|
||||
chrome.proxy.settings.clear({ scope: 'regular' });
|
||||
}
|
||||
|
||||
// https://developer.chrome.com/extensions/examples/api/contentSettings/popup.js
|
||||
function contentSettings() {
|
||||
var incognito;
|
||||
var url;
|
||||
|
||||
function settingChanged() {
|
||||
var type = this.id;
|
||||
var setting = this.value;
|
||||
var pattern = /^file:/.test(url) ? url : url.replace(/\/[^\/]*?$/, '/*');
|
||||
console.log(type+' setting for '+pattern+': '+setting);
|
||||
// HACK: [type] is not recognised by the docserver's sample crawler, so
|
||||
// mention an explicit
|
||||
// type: chrome.contentSettings.cookies.set - See http://crbug.com/299634
|
||||
chrome.contentSettings[type].set({
|
||||
'primaryPattern': pattern,
|
||||
'setting': setting,
|
||||
'scope': (incognito ? 'incognito_session_only' : 'regular')
|
||||
});
|
||||
}
|
||||
|
||||
document.addEventListener('DOMContentLoaded', function () {
|
||||
chrome.tabs.query({active: true, currentWindow: true, url: ['http://*/*', 'https://*/*'] }, function(tabs) {
|
||||
var current = tabs[0];
|
||||
incognito = current.incognito;
|
||||
url = current.url;
|
||||
var types = ['cookies', 'images', 'javascript', 'location', 'plugins',
|
||||
'popups', 'notifications', 'fullscreen', 'mouselock',
|
||||
'microphone', 'camera', 'unsandboxedPlugins',
|
||||
'automaticDownloads'];
|
||||
types.forEach(function(type) {
|
||||
// HACK: [type] is not recognised by the docserver's sample crawler, so
|
||||
// mention an explicit
|
||||
// type: chrome.contentSettings.cookies.get - See http://crbug.com/299634
|
||||
chrome.contentSettings[type] && chrome.contentSettings[type].get({
|
||||
'primaryUrl': url,
|
||||
'incognito': incognito
|
||||
},
|
||||
function(details) {
|
||||
var input = <HTMLInputElement>document.getElementById(type);
|
||||
input.disabled = false;
|
||||
input.value = details.setting;
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
var selects = document.querySelectorAll('select');
|
||||
for (var i = 0; i < selects.length; i++) {
|
||||
selects[i].addEventListener('change', settingChanged);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Vendored
+3
-3
@@ -869,7 +869,7 @@ declare module chrome.events {
|
||||
addListener(callback: Function): void;
|
||||
getRules(callback: (rules: Rule[]) => void): void;
|
||||
getRules(ruleIdentifiers: string[], callback: (rules: Rule[]) => void): void;
|
||||
hasListener(callback: Function): void;
|
||||
hasListener(callback: Function): boolean;
|
||||
removeRules(ruleIdentifiers?: string[], callback?: Function): void;
|
||||
addRules(rules: Rule[], callback?: (rules: Rule[]) => void): void;
|
||||
removeListener(callback: Function): void;
|
||||
@@ -1822,7 +1822,7 @@ declare module chrome.tabCapture {
|
||||
videoConstraints?: MediaTrackConstraints;
|
||||
}
|
||||
|
||||
export function capture(options: CaptureOptions, callback: (stream: LocalMediaStream) => void): void;
|
||||
export function capture(options: CaptureOptions, callback: (stream: MediaStream) => void): void;
|
||||
export function getCapturedTabs(callback: (result: CaptureInfo[]) => void): void;
|
||||
}
|
||||
|
||||
@@ -1900,7 +1900,7 @@ declare module chrome.tabs {
|
||||
active?: boolean;
|
||||
index?: number;
|
||||
title?: string;
|
||||
url?: string;
|
||||
url?: string | string[];
|
||||
currentWindow?: boolean;
|
||||
highlighted?: boolean;
|
||||
pinned?: boolean;
|
||||
|
||||
+10
-10
@@ -1,4 +1,4 @@
|
||||
/// <reference path="../chocolatechipjs/chocolatechipjs.d.ts"/>
|
||||
/// <reference path="../jquery/jquery.d.ts"/>
|
||||
/// <reference path="chui.d.ts"/>
|
||||
|
||||
$(function() {
|
||||
@@ -7,10 +7,10 @@ $(function() {
|
||||
* Test static methods:
|
||||
*/
|
||||
var concatenatedText = $.concat("This", "is", "text", "to", "contatenate.");
|
||||
$.forEach([1,2,3], function(ctx) {
|
||||
$.forEach([1,2,3], function(ctx: number) {
|
||||
return ctx;
|
||||
});
|
||||
$.forEach([1,2,3], function(ctx, idx) {
|
||||
$.forEach([1,2,3], function(ctx: number, idx: number) {
|
||||
return idx;
|
||||
});
|
||||
|
||||
@@ -41,8 +41,8 @@ $(function() {
|
||||
$.UIBlock(.5);
|
||||
$.UIUnblock();
|
||||
$.UIPopup({id: "myPopup", message: 'Hello!!!'});
|
||||
$.UIPopup({message: 'Hello!!!', title: "Whatever", callback: $.noop});
|
||||
$.UIPopup({message: 'Hello!!!', cancleButton: "Forget It!", continueButton: "OK"});
|
||||
$.UIPopup({ message: 'Hello!!!', title: "Whatever", callback: $.noop });
|
||||
$.UIPopup({ message: 'Hello!!!', cancelButton: "Forget It!", continueButton: "OK" });
|
||||
$.UIPopover({id: "myPopover"});
|
||||
$.UIPopover({callback: function() {}});
|
||||
$.UIPopover({title: "Whatever"});
|
||||
@@ -53,13 +53,13 @@ $(function() {
|
||||
$.UISheet({id: "mySheet", listClass: "specialList", background: 'red', handle: false});
|
||||
$.UIShowSheet("#mySheet");
|
||||
$.UIHideSheet();
|
||||
$.UISlideout({position: "right", dynamic: false, callback: $.noop});
|
||||
$.UISlideout({dynamic: false, callback: $.noop});
|
||||
var myStepper = $('#myStepper');
|
||||
$.UIResetStepper(myStepper);
|
||||
$.UICreateSwitch({id: "mySwitch", value: 5, checked: "true", callback: $.noop});
|
||||
$.UITabbar({tabs: 3, labels: ["one", "two", "three"], selected: 2});
|
||||
$.UISearch({articleId: "#main", placehold: "Looking?", results: 10});
|
||||
var carouselPanels = $('li');
|
||||
$.UITabbar({ tabs: 3, labels: ["one", "two", "three"], selected: 2 });
|
||||
$.UISearch({ articleId: "#main", placeholder: "Looking?", results: 10 });
|
||||
var carouselPanels = $("<li>1</li><li>2</li><li>3</li>");
|
||||
$.UISetupCarousel({target: "#carousel", panels: carouselPanels});
|
||||
$.UIBindData();
|
||||
$.UIBindData("#myBoundData");
|
||||
@@ -90,7 +90,7 @@ $(function() {
|
||||
$("#panelToggler").UIPanelToggle("#togglePanels", $.noop);
|
||||
$('#editList').UIEditList({callback: $.noop, deletable: false, movable: true});
|
||||
$('#mySelectList').UISelectList();
|
||||
$('#myStepper').UIStepper({start: 1, end: 10, defautValue: 5});
|
||||
$('#myStepper').UIStepper({ start: 1, end: 10, defaultValue: 5 });
|
||||
$('#mySwitch').UISwitch();
|
||||
$('#myRangeControl').UIRange();
|
||||
|
||||
|
||||
Vendored
+933
-716
File diff suppressed because it is too large
Load Diff
Vendored
+180
-147
@@ -7,8 +7,8 @@ declare function CodeMirror(host: HTMLElement, options?: CodeMirror.EditorConfig
|
||||
declare function CodeMirror(callback: (host: HTMLElement) => void , options?: CodeMirror.EditorConfiguration): CodeMirror.Editor;
|
||||
|
||||
declare module CodeMirror {
|
||||
export var Doc : CodeMirror.Doc;
|
||||
export var Pos: CodeMirror.Position;
|
||||
export var Doc : CodeMirror.DocConstructor;
|
||||
export var Pos: CodeMirror.PositionConstructor;
|
||||
export var Pass: any;
|
||||
|
||||
function fromTextArea(host: HTMLTextAreaElement, options?: EditorConfiguration): CodeMirror.EditorFromTextArea;
|
||||
@@ -88,84 +88,84 @@ declare module CodeMirror {
|
||||
or the line the widget is on require the widget to be redrawn. */
|
||||
function on(line: LineWidget, eventName: 'redraw', handler: () => void ): void;
|
||||
function off(line: LineWidget, eventName: 'redraw', handler: () => void ): void;
|
||||
|
||||
/** Various CodeMirror-related objects emit events, which allow client code to react to various situations.
|
||||
Handlers for such events can be registered with the on and off methods on the objects that the event fires on.
|
||||
|
||||
/** Various CodeMirror-related objects emit events, which allow client code to react to various situations.
|
||||
Handlers for such events can be registered with the on and off methods on the objects that the event fires on.
|
||||
To fire your own events, use CodeMirror.signal(target, name, args...), where target is a non-DOM-node object. */
|
||||
function signal(target: any, name: string, ...args: any[]): void;
|
||||
|
||||
interface Editor {
|
||||
|
||||
|
||||
/** Tells you whether the editor currently has focus. */
|
||||
hasFocus(): boolean;
|
||||
|
||||
|
||||
/** Used to find the target position for horizontal cursor motion.start is a { line , ch } object,
|
||||
amount an integer(may be negative), and unit one of the string "char", "column", or "word".
|
||||
Will return a position that is produced by moving amount times the distance specified by unit.
|
||||
When visually is true , motion in right - to - left text will be visual rather than logical.
|
||||
When the motion was clipped by hitting the end or start of the document, the returned value will have a hitSide property set to true. */
|
||||
findPosH(start: CodeMirror.Position, amount: number, unit: string, visually: boolean): { line: number; ch: number; hitSide?: boolean; };
|
||||
|
||||
|
||||
/** Similar to findPosH , but used for vertical motion.unit may be "line" or "page".
|
||||
The other arguments and the returned value have the same interpretation as they have in findPosH. */
|
||||
findPosV(start: CodeMirror.Position, amount: number, unit: string): { line: number; ch: number; hitSide?: boolean; };
|
||||
|
||||
|
||||
|
||||
|
||||
/** Change the configuration of the editor. option should the name of an option, and value should be a valid value for that option. */
|
||||
setOption(option: string, value: any): void;
|
||||
|
||||
|
||||
/** Retrieves the current value of the given option for this editor instance. */
|
||||
getOption(option: string): any;
|
||||
|
||||
|
||||
/** Attach an additional keymap to the editor.
|
||||
This is mostly useful for add - ons that need to register some key handlers without trampling on the extraKeys option.
|
||||
Maps added in this way have a higher precedence than the extraKeys and keyMap options, and between them,
|
||||
the maps added earlier have a lower precedence than those added later, unless the bottom argument was passed,
|
||||
in which case they end up below other keymaps added with this method. */
|
||||
addKeyMap(map: any, bottom?: boolean): void;
|
||||
|
||||
|
||||
/** Disable a keymap added with addKeyMap.Either pass in the keymap object itself , or a string,
|
||||
which will be compared against the name property of the active keymaps. */
|
||||
removeKeyMap(map: any): void;
|
||||
|
||||
|
||||
/** Enable a highlighting overlay.This is a stateless mini - mode that can be used to add extra highlighting.
|
||||
For example, the search add - on uses it to highlight the term that's currently being searched.
|
||||
mode can be a mode spec or a mode object (an object with a token method). The options parameter is optional. If given, it should be an object.
|
||||
Currently, only the opaque option is recognized. This defaults to off, but can be given to allow the overlay styling, when not null,
|
||||
to override the styling of the base mode entirely, instead of the two being applied together. */
|
||||
addOverlay(mode: any, options?: any): void;
|
||||
|
||||
|
||||
/** Pass this the exact argument passed for the mode parameter to addOverlay to remove an overlay again. */
|
||||
removeOverlay(mode: any): void;
|
||||
|
||||
|
||||
|
||||
|
||||
/** Retrieve the currently active document from an editor. */
|
||||
getDoc(): CodeMirror.Doc;
|
||||
|
||||
|
||||
/** Attach a new document to the editor. Returns the old document, which is now no longer associated with an editor. */
|
||||
swapDoc(doc: CodeMirror.Doc): CodeMirror.Doc;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/** Sets the gutter marker for the given gutter (identified by its CSS class, see the gutters option) to the given value.
|
||||
Value can be either null, to clear the marker, or a DOM element, to set it. The DOM element will be shown in the specified gutter next to the specified line. */
|
||||
setGutterMarker(line: any, gutterID: string, value: HTMLElement): CodeMirror.LineHandle;
|
||||
|
||||
|
||||
/** Remove all gutter markers in the gutter with the given ID. */
|
||||
clearGutter(gutterID: string): void;
|
||||
|
||||
|
||||
/** Set a CSS class name for the given line.line can be a number or a line handle.
|
||||
where determines to which element this class should be applied, can can be one of "text" (the text element, which lies in front of the selection),
|
||||
"background"(a background element that will be behind the selection),
|
||||
or "wrap" (the wrapper node that wraps all of the line's elements, including gutter elements).
|
||||
class should be the name of the class to apply. */
|
||||
addLineClass(line: any, where: string, _class_: string): CodeMirror.LineHandle;
|
||||
|
||||
|
||||
/** Remove a CSS class from a line.line can be a line handle or number.
|
||||
where should be one of "text", "background", or "wrap"(see addLineClass).
|
||||
class can be left off to remove all classes for the specified node, or be a string to remove only a specific class. */
|
||||
removeLineClass(line: any, where: string, class_: string): CodeMirror.LineHandle;
|
||||
|
||||
|
||||
/** Returns the line number, text content, and marker status of the given line, which can be either a number or a line handle. */
|
||||
lineInfo(line: any): {
|
||||
line: any;
|
||||
@@ -179,12 +179,12 @@ declare module CodeMirror {
|
||||
/** Array of line widgets attached to this line. */
|
||||
widgets: any;
|
||||
};
|
||||
|
||||
|
||||
/** Puts node, which should be an absolutely positioned DOM node, into the editor, positioned right below the given { line , ch } position.
|
||||
When scrollIntoView is true, the editor will ensure that the entire node is visible (if possible).
|
||||
To remove the widget again, simply use DOM methods (move it somewhere else, or call removeChild on its parent). */
|
||||
addWidget(pos: CodeMirror.Position, node: HTMLElement, scrollIntoView: boolean): void;
|
||||
|
||||
|
||||
/** Adds a line widget, an element shown below a line, spanning the whole of the editor's width, and moving the lines below it downwards.
|
||||
line should be either an integer or a line handle, and node should be a DOM node, which will be displayed below the given line.
|
||||
options, when given, should be an object that configures the behavior of the widget.
|
||||
@@ -199,16 +199,16 @@ declare module CodeMirror {
|
||||
/** When true, will cause the widget to be rendered even if the line it is associated with is hidden. */
|
||||
showIfHidden: boolean;
|
||||
}): CodeMirror.LineWidget;
|
||||
|
||||
|
||||
|
||||
|
||||
/** Programatically set the size of the editor (overriding the applicable CSS rules).
|
||||
width and height height can be either numbers(interpreted as pixels) or CSS units ("100%", for example).
|
||||
You can pass null for either of them to indicate that that dimension should not be changed. */
|
||||
setSize(width: any, height: any): void;
|
||||
|
||||
|
||||
/** Scroll the editor to a given(pixel) position.Both arguments may be left as null or undefined to have no effect. */
|
||||
scrollTo(x: number, y: number): void;
|
||||
|
||||
|
||||
/** Get an { left , top , width , height , clientWidth , clientHeight } object that represents the current scroll position, the size of the scrollable area,
|
||||
and the size of the visible area(minus scrollbars). */
|
||||
getScrollInfo(): {
|
||||
@@ -219,53 +219,53 @@ declare module CodeMirror {
|
||||
clientWidth: any;
|
||||
clientHeight: any;
|
||||
}
|
||||
|
||||
|
||||
/** Scrolls the given element into view. pos is a { line , ch } position, referring to a given character, null, to refer to the cursor.
|
||||
The margin parameter is optional. When given, it indicates the amount of pixels around the given area that should be made visible as well. */
|
||||
scrollIntoView(pos: CodeMirror.Position, margin?: number): void;
|
||||
|
||||
|
||||
/** Scrolls the given element into view. pos is a { left , top , right , bottom } object, in editor-local coordinates.
|
||||
The margin parameter is optional. When given, it indicates the amount of pixels around the given area that should be made visible as well. */
|
||||
scrollIntoView(pos: { left: number; top: number; right: number; bottom: number; }, margin: number): void;
|
||||
|
||||
|
||||
/** Returns an { left , top , bottom } object containing the coordinates of the cursor position.
|
||||
If mode is "local" , they will be relative to the top-left corner of the editable document.
|
||||
If it is "page" or not given, they are relative to the top-left corner of the page.
|
||||
where is a boolean indicating whether you want the start(true) or the end(false) of the selection. */
|
||||
cursorCoords(where: boolean, mode: string): { left: number; top: number; bottom: number; };
|
||||
|
||||
|
||||
/** Returns an { left , top , bottom } object containing the coordinates of the cursor position.
|
||||
If mode is "local" , they will be relative to the top-left corner of the editable document.
|
||||
If it is "page" or not given, they are relative to the top-left corner of the page.
|
||||
where specifies the precise position at which you want to measure. */
|
||||
cursorCoords(where: CodeMirror.Position, mode: string): { left: number; top: number; bottom: number; };
|
||||
|
||||
|
||||
/** Returns the position and dimensions of an arbitrary character.pos should be a { line , ch } object.
|
||||
This differs from cursorCoords in that it'll give the size of the whole character,
|
||||
rather than just the position that the cursor would have when it would sit at that position. */
|
||||
charCoords(pos: CodeMirror.Position, mode: string): { left: number; right: number; top: number; bottom: number; };
|
||||
|
||||
|
||||
/** Given an { left , top } object , returns the { line , ch } position that corresponds to it.
|
||||
The optional mode parameter determines relative to what the coordinates are interpreted. It may be "window" , "page"(the default) , or "local". */
|
||||
coordsChar(object: { left: number; top: number; }, mode?: string): CodeMirror.Position;
|
||||
|
||||
|
||||
/** Returns the line height of the default font for the editor. */
|
||||
defaultTextHeight(): number;
|
||||
|
||||
|
||||
/** Returns the pixel width of an 'x' in the default font for the editor.
|
||||
(Note that for non - monospace fonts , this is mostly useless, and even for monospace fonts, non - ascii characters might have a different width). */
|
||||
defaultCharWidth(): number;
|
||||
|
||||
|
||||
/** Returns a { from , to } object indicating the start (inclusive) and end (exclusive) of the currently rendered part of the document.
|
||||
In big documents, when most content is scrolled out of view, CodeMirror will only render the visible part, and a margin around it.
|
||||
See also the viewportChange event. */
|
||||
getViewport(): { from: number; to: number };
|
||||
|
||||
|
||||
/** If your code does something to change the size of the editor element (window resizes are already listened for), or unhides it,
|
||||
you should probably follow up by calling this method to ensure CodeMirror is still looking as intended. */
|
||||
refresh(): void;
|
||||
|
||||
|
||||
|
||||
|
||||
/** Retrieves information about the token the current mode found before the given position (a {line, ch} object). */
|
||||
getTokenAt(pos: CodeMirror.Position): {
|
||||
/** The character(on the given line) at which the token starts. */
|
||||
@@ -277,20 +277,20 @@ declare module CodeMirror {
|
||||
/** The token type the mode assigned to the token, such as "keyword" or "comment" (may also be null). */
|
||||
type: string;
|
||||
/** The mode's state at the end of this token. */
|
||||
state: any;
|
||||
state: any;
|
||||
};
|
||||
|
||||
|
||||
/** Returns the mode's parser state, if any, at the end of the given line number.
|
||||
If no line number is given, the state at the end of the document is returned.
|
||||
This can be useful for storing parsing errors in the state, or getting other kinds of contextual information for a line. */
|
||||
getStateAfter(line?: number): any;
|
||||
|
||||
|
||||
/** CodeMirror internally buffers changes and only updates its DOM structure after it has finished performing some operation.
|
||||
If you need to perform a lot of operations on a CodeMirror instance, you can call this method with a function argument.
|
||||
It will call the function, buffering up all changes, and only doing the expensive update after the function returns.
|
||||
This can be a lot faster. The return value from this method will be the return value of your function. */
|
||||
operation<T>(fn: ()=> T): T;
|
||||
|
||||
|
||||
/** Adjust the indentation of the given line.
|
||||
The second argument (which defaults to "smart") may be one of:
|
||||
"prev" Base indentation on the indentation of the previous line.
|
||||
@@ -298,35 +298,42 @@ declare module CodeMirror {
|
||||
"add" Increase the indentation of the line by one indent unit.
|
||||
"subtract" Reduce the indentation of the line. */
|
||||
indentLine(line: number, dir?: string): void;
|
||||
|
||||
|
||||
|
||||
|
||||
/** Give the editor focus. */
|
||||
focus(): void;
|
||||
|
||||
|
||||
/** Returns the hidden textarea used to read input. */
|
||||
getInputField(): HTMLTextAreaElement;
|
||||
|
||||
|
||||
/** Returns the DOM node that represents the editor, and controls its size. Remove this from your tree to delete an editor instance. */
|
||||
getWrapperElement(): HTMLElement;
|
||||
|
||||
|
||||
/** Returns the DOM node that is responsible for the scrolling of the editor. */
|
||||
getScrollerElement(): HTMLElement;
|
||||
|
||||
|
||||
/** Fetches the DOM node that contains the editor gutters. */
|
||||
getGutterElement(): HTMLElement;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/** Events are registered with the on method (and removed with the off method).
|
||||
These are the events that fire on the instance object. The name of the event is followed by the arguments that will be passed to the handler.
|
||||
The instance argument always refers to the editor instance. */
|
||||
on(eventName: string, handler: (instance: CodeMirror.Editor) => void ): void;
|
||||
off(eventName: string, handler: (instance: CodeMirror.Editor) => void ): void;
|
||||
|
||||
|
||||
/** Fires every time the content of the editor is changed. */
|
||||
on(eventName: 'change', handler: (instance: CodeMirror.Editor, change: CodeMirror.EditorChangeLinkedList) => void ): void;
|
||||
off(eventName: 'change', handler: (instance: CodeMirror.Editor, change: CodeMirror.EditorChangeLinkedList) => void ): void;
|
||||
|
||||
|
||||
/** Like the "change" event, but batched per operation, passing an
|
||||
* array containing all the changes that happened in the operation.
|
||||
* This event is fired after the operation finished, and display
|
||||
* changes it makes will trigger a new operation. */
|
||||
on(eventName: 'changes', handler: (instance: CodeMirror.Editor, change: CodeMirror.EditorChangeLinkedList[]) => void ): void;
|
||||
off(eventName: 'changes', handler: (instance: CodeMirror.Editor, change: CodeMirror.EditorChangeLinkedList[]) => void ): void;
|
||||
|
||||
/** This event is fired before a change is applied, and its handler may choose to modify or cancel the change.
|
||||
The changeObj never has a next property, since this is fired for each individual change, and not batched per operation.
|
||||
Note: you may not do anything from a "beforeChange" handler that would cause changes to the document or its visualization.
|
||||
@@ -334,64 +341,67 @@ declare module CodeMirror {
|
||||
probably cause the editor to become corrupted. */
|
||||
on(eventName: 'beforeChange', handler: (instance: CodeMirror.Editor, change: CodeMirror.EditorChangeCancellable) => void ): void;
|
||||
off(eventName: 'beforeChange', handler: (instance: CodeMirror.Editor, change: CodeMirror.EditorChangeCancellable) => void ): void;
|
||||
|
||||
|
||||
/** Will be fired when the cursor or selection moves, or any change is made to the editor content. */
|
||||
on(eventName: 'cursorActivity', handler: (instance: CodeMirror.Editor) => void ): void;
|
||||
off(eventName: 'cursorActivity', handler: (instance: CodeMirror.Editor) => void ): void;
|
||||
|
||||
|
||||
/** This event is fired before the selection is moved. Its handler may modify the resulting selection head and anchor.
|
||||
Handlers for this event have the same restriction as "beforeChange" handlers � they should not do anything to directly update the state of the editor. */
|
||||
on(eventName: 'beforeSelectionChange', handler: (instance: CodeMirror.Editor, selection: { head: CodeMirror.Position; anchor: CodeMirror.Position; }) => void ): void;
|
||||
off(eventName: 'beforeSelectionChange', handler: (instance: CodeMirror.Editor, selection: { head: CodeMirror.Position; anchor: CodeMirror.Position; }) => void ): void;
|
||||
|
||||
|
||||
/** Fires whenever the view port of the editor changes (due to scrolling, editing, or any other factor).
|
||||
The from and to arguments give the new start and end of the viewport. */
|
||||
on(eventName: 'viewportChange', handler: (instance: CodeMirror.Editor, from: number, to: number) => void ): void;
|
||||
off(eventName: 'viewportChange', handler: (instance: CodeMirror.Editor, from: number, to: number) => void ): void;
|
||||
|
||||
|
||||
/** Fires when the editor gutter (the line-number area) is clicked. Will pass the editor instance as first argument,
|
||||
the (zero-based) number of the line that was clicked as second argument, the CSS class of the gutter that was clicked as third argument,
|
||||
and the raw mousedown event object as fourth argument. */
|
||||
on(eventName: 'gutterClick', handler: (instance: CodeMirror.Editor, line: number, gutter: string, clickEvent: Event) => void ): void;
|
||||
off(eventName: 'gutterClick', handler: (instance: CodeMirror.Editor, line: number, gutter: string, clickEvent: Event) => void ): void;
|
||||
|
||||
|
||||
/** Fires whenever the editor is focused. */
|
||||
on(eventName: 'focus', handler: (instance: CodeMirror.Editor) => void ): void;
|
||||
off(eventName: 'focus', handler: (instance: CodeMirror.Editor) => void ): void;
|
||||
|
||||
|
||||
/** Fires whenever the editor is unfocused. */
|
||||
on(eventName: 'blur', handler: (instance: CodeMirror.Editor) => void ): void;
|
||||
off(eventName: 'blur', handler: (instance: CodeMirror.Editor) => void ): void;
|
||||
|
||||
|
||||
/** Fires when the editor is scrolled. */
|
||||
on(eventName: 'scroll', handler: (instance: CodeMirror.Editor) => void ): void;
|
||||
off(eventName: 'scroll', handler: (instance: CodeMirror.Editor) => void ): void;
|
||||
|
||||
|
||||
/** Will be fired whenever CodeMirror updates its DOM display. */
|
||||
on(eventName: 'update', handler: (instance: CodeMirror.Editor) => void ): void;
|
||||
off(eventName: 'update', handler: (instance: CodeMirror.Editor) => void ): void;
|
||||
|
||||
|
||||
/** Fired whenever a line is (re-)rendered to the DOM. Fired right after the DOM element is built, before it is added to the document.
|
||||
The handler may mess with the style of the resulting element, or add event handlers, but should not try to change the state of the editor. */
|
||||
on(eventName: 'renderLine', handler: (instance: CodeMirror.Editor, line: number, element: HTMLElement) => void ): void;
|
||||
off(eventName: 'renderLine', handler: (instance: CodeMirror.Editor, line: number, element: HTMLElement) => void ): void;
|
||||
}
|
||||
|
||||
|
||||
interface EditorFromTextArea extends Editor {
|
||||
|
||||
|
||||
/** Copy the content of the editor into the textarea. */
|
||||
save(): void;
|
||||
|
||||
|
||||
/** Remove the editor, and restore the original textarea (with the editor's current content). */
|
||||
toTextArea(): void;
|
||||
|
||||
|
||||
/** Returns the textarea that the instance was based on. */
|
||||
getTextArea(): HTMLTextAreaElement;
|
||||
}
|
||||
|
||||
interface Doc {
|
||||
new (text: string, mode?: any, firstLineNumber?: number): Doc;
|
||||
interface DocConstructor {
|
||||
new (text: string, mode?: any, firstLineNumber?: number, lineSep?: string): Doc;
|
||||
(text: string, mode?: any, firstLineNumber?: number, lineSep?: string): Doc;
|
||||
}
|
||||
|
||||
interface Doc {
|
||||
/** Get the current editor content. You can pass it an optional argument to specify the string to be used to separate lines (defaults to "\n"). */
|
||||
getValue(seperator?: string): string;
|
||||
|
||||
@@ -461,6 +471,10 @@ declare module CodeMirror {
|
||||
It may be "start" , "end" , "head"(the side of the selection that moves when you press shift + arrow),
|
||||
or "anchor"(the fixed side of the selection).Omitting the argument is the same as passing "head".A { line , ch } object will be returned. */
|
||||
getCursor(start?: string): CodeMirror.Position;
|
||||
|
||||
/** Retrieves a list of all current selections. These will always be sorted, and never overlap (overlapping selections are merged).
|
||||
Each object in the array contains anchor and head properties referring to {line, ch} objects. */
|
||||
listSelections(): { anchor: CodeMirror.Position; head: CodeMirror.Position }[];
|
||||
|
||||
/** Return true if any text is selected. */
|
||||
somethingSelected(): boolean;
|
||||
@@ -551,7 +565,7 @@ declare module CodeMirror {
|
||||
|
||||
/** Returns an array of all the bookmarks and marked ranges present at the given position. */
|
||||
findMarksAt(pos: CodeMirror.Position): TextMarker[];
|
||||
|
||||
|
||||
/** Returns an array containing all marked ranges in the document. */
|
||||
getAllMarks(): CodeMirror.TextMarker[];
|
||||
|
||||
@@ -602,7 +616,7 @@ declare module CodeMirror {
|
||||
/** Array of strings representing the text that replaced the changed range (split by line). */
|
||||
text: string[];
|
||||
/** Text that used to be between from and to, which is overwritten by this change. */
|
||||
removed: string;
|
||||
removed: string[];
|
||||
/** String representing the origin of the change event and wether it can be merged with history */
|
||||
origin: string;
|
||||
}
|
||||
@@ -619,8 +633,12 @@ declare module CodeMirror {
|
||||
cancel(): void;
|
||||
}
|
||||
|
||||
interface Position {
|
||||
interface PositionConstructor {
|
||||
new (line: number, ch: number): Position;
|
||||
(line: number, ch: number): Position;
|
||||
}
|
||||
|
||||
interface Position {
|
||||
ch: number;
|
||||
line: number;
|
||||
}
|
||||
@@ -654,7 +672,7 @@ declare module CodeMirror {
|
||||
/** Configures whether the editor should re-indent the current line when a character is typed
|
||||
that might change its proper indentation (only works if the mode supports indentation). Default is true. */
|
||||
electricChars?: boolean;
|
||||
|
||||
|
||||
/** Determines whether horizontal cursor movement through right-to-left (Arabic, Hebrew) text
|
||||
is visual (pressing the left arrow moves the cursor left)
|
||||
or logical (pressing the left arrow moves to the next lower index in the string, which is visually right in right-to-left text).
|
||||
@@ -664,16 +682,16 @@ declare module CodeMirror {
|
||||
/** Configures the keymap to use. The default is "default", which is the only keymap defined in codemirror.js itself.
|
||||
Extra keymaps are found in the keymap directory. See the section on keymaps for more information. */
|
||||
keyMap?: string;
|
||||
|
||||
|
||||
/** Can be used to specify extra keybindings for the editor, alongside the ones defined by keyMap. Should be either null, or a valid keymap value. */
|
||||
extraKeys?: any;
|
||||
|
||||
|
||||
/** Whether CodeMirror should scroll or wrap for long lines. Defaults to false (scroll). */
|
||||
lineWrapping?: boolean;
|
||||
|
||||
|
||||
/** Whether to show line numbers to the left of the editor. */
|
||||
lineNumbers?: boolean;
|
||||
|
||||
|
||||
/** At which number to start counting lines. Default is 1. */
|
||||
firstLineNumber?: number;
|
||||
|
||||
@@ -686,23 +704,23 @@ declare module CodeMirror {
|
||||
May include the CodeMirror-linenumbers class, in order to explicitly set the position of the line number gutter
|
||||
(it will default to be to the right of all other gutters). These class names are the keys passed to setGutterMarker. */
|
||||
gutters?: string[];
|
||||
|
||||
|
||||
/** Determines whether the gutter scrolls along with the content horizontally (false)
|
||||
or whether it stays fixed during horizontal scrolling (true, the default). */
|
||||
fixedGutter?: boolean;
|
||||
|
||||
|
||||
/** boolean|string. This disables editing of the editor content by the user. If the special value "nocursor" is given (instead of simply true), focusing of the editor is also disallowed. */
|
||||
readOnly?: any;
|
||||
|
||||
|
||||
/**Whether the cursor should be drawn when a selection is active. Defaults to false. */
|
||||
showCursorWhenSelecting?: boolean;
|
||||
|
||||
|
||||
/** The maximum number of undo levels that the editor stores. Defaults to 40. */
|
||||
undoDepth?: number;
|
||||
|
||||
|
||||
/** The period of inactivity (in milliseconds) that will cause a new history event to be started when typing or deleting. Defaults to 500. */
|
||||
historyEventDelay?: number;
|
||||
|
||||
|
||||
/** The tab index to assign to the editor. If not given, no tab index will be assigned. */
|
||||
tabindex?: number;
|
||||
|
||||
@@ -766,58 +784,73 @@ declare module CodeMirror {
|
||||
This affects the amount of updates needed when scrolling, and the amount of work that such an update does.
|
||||
You should usually leave it at its default, 10. Can be set to Infinity to make sure the whole document is always rendered,
|
||||
and thus the browser's text search works on it. This will have bad effects on performance of big documents. */
|
||||
viewportMargin?: number;
|
||||
|
||||
/** Optional lint configuration to be used in conjunction with CodeMirror's linter addon. */
|
||||
viewportMargin?: number;
|
||||
|
||||
/** Optional lint configuration to be used in conjunction with CodeMirror's linter addon. */
|
||||
lint?: LintOptions;
|
||||
}
|
||||
|
||||
interface TextMarkerOptions {
|
||||
/** Assigns a CSS class to the marked stretch of text. */
|
||||
className?: string;
|
||||
|
||||
|
||||
/** Determines whether text inserted on the left of the marker will end up inside or outside of it. */
|
||||
inclusiveLeft?: boolean;
|
||||
|
||||
|
||||
/** Like inclusiveLeft , but for the right side. */
|
||||
inclusiveRight?: boolean;
|
||||
|
||||
/** Atomic ranges act as a single unit when cursor movement is concerned � i.e. it is impossible to place the cursor inside of them.
|
||||
In atomic ranges, inclusiveLeft and inclusiveRight have a different meaning � they will prevent the cursor from being placed
|
||||
|
||||
/** Atomic ranges act as a single unit when cursor movement is concerned — i.e. it is impossible to place the cursor inside of them.
|
||||
In atomic ranges, inclusiveLeft and inclusiveRight have a different meaning — they will prevent the cursor from being placed
|
||||
respectively directly before and directly after the range. */
|
||||
atomic?: boolean;
|
||||
|
||||
|
||||
/** Collapsed ranges do not show up in the display.Setting a range to be collapsed will automatically make it atomic. */
|
||||
collapsed?: boolean;
|
||||
|
||||
|
||||
/** When enabled, will cause the mark to clear itself whenever the cursor enters its range.
|
||||
This is mostly useful for text - replacement widgets that need to 'snap open' when the user tries to edit them.
|
||||
The "clear" event fired on the range handle can be used to be notified when this happens. */
|
||||
clearOnEnter?: boolean;
|
||||
|
||||
|
||||
/** Determines whether the mark is automatically cleared when it becomes empty. Default is true. */
|
||||
clearWhenEmpty?: boolean;
|
||||
|
||||
/** Use a given node to display this range.Implies both collapsed and atomic.
|
||||
The given DOM node must be an inline element(as opposed to a block element). */
|
||||
replacedWith?: HTMLElement;
|
||||
|
||||
|
||||
/** When replacedWith is given, this determines whether the editor will
|
||||
* capture mouse and drag events occurring in this widget. Default is
|
||||
* false—the events will be left alone for the default browser handler,
|
||||
* or specific handlers on the widget, to capture. */
|
||||
handleMouseEvents?: boolean;
|
||||
|
||||
/** A read - only span can, as long as it is not cleared, not be modified except by calling setValue to reset the whole document.
|
||||
Note: adding a read - only span currently clears the undo history of the editor,
|
||||
because existing undo events being partially nullified by read - only spans would corrupt the history (in the current implementation). */
|
||||
readOnly?: boolean;
|
||||
|
||||
|
||||
/** When set to true (default is false), adding this marker will create an event in the undo history that can be individually undone(clearing the marker). */
|
||||
addToHistory?: boolean;
|
||||
|
||||
|
||||
/** Can be used to specify an extra CSS class to be applied to the leftmost span that is part of the marker. */
|
||||
startStyle?: string;
|
||||
|
||||
|
||||
/** Equivalent to startStyle, but for the rightmost span. */
|
||||
endStyle?: string;
|
||||
|
||||
|
||||
/** A string of CSS to be applied to the covered text. For example "color: #fe3". */
|
||||
css?: string;
|
||||
|
||||
/** When given, will give the nodes created for this span a HTML title attribute with the given value. */
|
||||
title?: string;
|
||||
|
||||
/** When the target document is linked to other documents, you can set shared to true to make the marker appear in all documents.
|
||||
By default, a marker appears only in its target document. */
|
||||
shared?: boolean;
|
||||
}
|
||||
|
||||
|
||||
interface StringStream {
|
||||
lastColumnPos: number;
|
||||
lastColumnValue: number;
|
||||
@@ -1012,48 +1045,48 @@ declare module CodeMirror {
|
||||
* Both modes get to parse all of the text, but when both assign a non-null style to a piece of code, the overlay wins, unless
|
||||
* the combine argument was true and not overridden, or state.overlay.combineTokens was true, in which case the styles are combined.
|
||||
*/
|
||||
function overlayMode<T, S>(base: Mode<T>, overlay: Mode<S>, combine?: boolean): Mode<any>
|
||||
|
||||
/**
|
||||
* async specifies that the lint process runs asynchronously. hasGutters specifies that lint errors should be displayed in the CodeMirror
|
||||
* gutter, note that you must use this in conjunction with [ "CodeMirror-lint-markers" ] as an element in the gutters argument on
|
||||
* initialization of the CodeMirror instance.
|
||||
*/
|
||||
interface LintStateOptions {
|
||||
async: boolean;
|
||||
hasGutters: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* Adds the getAnnotations callback to LintStateOptions which may be overridden by the user if they choose use their own
|
||||
* linter.
|
||||
*/
|
||||
interface LintOptions extends LintStateOptions {
|
||||
getAnnotations: AnnotationsCallback;
|
||||
}
|
||||
|
||||
/**
|
||||
* A function that calls the updateLintingCallback with any errors found during the linting process.
|
||||
*/
|
||||
interface AnnotationsCallback {
|
||||
(content: string, updateLintingCallback: UpdateLintingCallback, options: LintStateOptions, codeMirror: Editor): void;
|
||||
}
|
||||
|
||||
/**
|
||||
* A function that, given an array of annotations, updates the CodeMirror linting GUI with those annotations
|
||||
*/
|
||||
interface UpdateLintingCallback {
|
||||
(codeMirror: Editor, annotations: Annotation[]): void;
|
||||
}
|
||||
|
||||
/**
|
||||
* An annotation contains a description of a lint error, detailing the location of the error within the code, the severity of the error,
|
||||
* and an explaination as to why the error was thrown.
|
||||
*/
|
||||
interface Annotation {
|
||||
from: Position;
|
||||
message?: string;
|
||||
severity?: string;
|
||||
to?: Position;
|
||||
function overlayMode<T, S>(base: Mode<T>, overlay: Mode<S>, combine?: boolean): Mode<any>
|
||||
|
||||
/**
|
||||
* async specifies that the lint process runs asynchronously. hasGutters specifies that lint errors should be displayed in the CodeMirror
|
||||
* gutter, note that you must use this in conjunction with [ "CodeMirror-lint-markers" ] as an element in the gutters argument on
|
||||
* initialization of the CodeMirror instance.
|
||||
*/
|
||||
interface LintStateOptions {
|
||||
async: boolean;
|
||||
hasGutters: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* Adds the getAnnotations callback to LintStateOptions which may be overridden by the user if they choose use their own
|
||||
* linter.
|
||||
*/
|
||||
interface LintOptions extends LintStateOptions {
|
||||
getAnnotations: AnnotationsCallback;
|
||||
}
|
||||
|
||||
/**
|
||||
* A function that calls the updateLintingCallback with any errors found during the linting process.
|
||||
*/
|
||||
interface AnnotationsCallback {
|
||||
(content: string, updateLintingCallback: UpdateLintingCallback, options: LintStateOptions, codeMirror: Editor): void;
|
||||
}
|
||||
|
||||
/**
|
||||
* A function that, given an array of annotations, updates the CodeMirror linting GUI with those annotations
|
||||
*/
|
||||
interface UpdateLintingCallback {
|
||||
(codeMirror: Editor, annotations: Annotation[]): void;
|
||||
}
|
||||
|
||||
/**
|
||||
* An annotation contains a description of a lint error, detailing the location of the error within the code, the severity of the error,
|
||||
* and an explaination as to why the error was thrown.
|
||||
*/
|
||||
interface Annotation {
|
||||
from: Position;
|
||||
message?: string;
|
||||
severity?: string;
|
||||
to?: Position;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ context.settings({compress: true});
|
||||
context.attach('#test', [
|
||||
{header: 'header 1'},
|
||||
{divider: true},
|
||||
{text:'foobar', submenu: [
|
||||
{text:'foobar', subMenu: [
|
||||
{text:'sub1'},
|
||||
{text:'sub2'}
|
||||
]}
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
|
||||
Vendored
+1
-1
@@ -32,7 +32,7 @@ interface Contacts {
|
||||
*/
|
||||
find(fields: string[],
|
||||
onSuccess: (contacts: Contact[]) => void,
|
||||
onError: (error: ContactError) => void,
|
||||
onError?: (error: ContactError) => void,
|
||||
options?: ContactFindOptions): void;
|
||||
/**
|
||||
* The navigator.contacts.pickContact method launches the Contact Picker to select a single contact.
|
||||
|
||||
Binary file not shown.
@@ -0,0 +1,11 @@
|
||||
/// <reference path="cors.d.ts" />
|
||||
|
||||
import express = require('express');
|
||||
import cors = require('cors');
|
||||
|
||||
var app = express();
|
||||
app.use(cors());
|
||||
app.use(cors({
|
||||
maxAge: 100,
|
||||
credentials: true
|
||||
}));
|
||||
Vendored
+24
@@ -0,0 +1,24 @@
|
||||
// Type definitions for cors
|
||||
// Project: https://github.com/troygoode/node-cors/
|
||||
// Definitions by: Mihhail Lapushkin <https://github.com/mihhail-lapushkin/>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
/// <reference path="../express/express.d.ts" />
|
||||
|
||||
declare module "cors" {
|
||||
import express = require('express');
|
||||
|
||||
module e {
|
||||
interface CorsOptions {
|
||||
origin?: any;
|
||||
methods?: any;
|
||||
allowedHeaders?: any;
|
||||
exposedHeaders?: any;
|
||||
credentials?: boolean;
|
||||
maxAge?: number;
|
||||
}
|
||||
}
|
||||
|
||||
function e(options?: e.CorsOptions): express.RequestHandler;
|
||||
export = e;
|
||||
}
|
||||
Vendored
+2
-2
@@ -6,9 +6,9 @@
|
||||
declare module "cron" {
|
||||
|
||||
interface CronJobStatic {
|
||||
new(cronTime: string|Date, onTick: () => void, onComplete?: () => void, start?: boolean, timezone?: string, context?: any): CronJob;
|
||||
new(cronTime: string|Date, onTick: () => void, onComplete?: () => void, start?: boolean, timeZone?: string, context?: any): CronJob;
|
||||
new(options: {
|
||||
cronTime: string|Date; onTick: () => void; onComplete?: () => void; start?: boolean; timezone?: string; context?: any
|
||||
cronTime: string|Date; onTick: () => void; onComplete?: () => void; start?: boolean; timeZone?: string; context?: any
|
||||
}): CronJob;
|
||||
}
|
||||
interface CronJob {
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
|
||||
Vendored
+5
-8
@@ -830,7 +830,7 @@ declare module d3 {
|
||||
style(name: string, value: (datum: Datum, index: number, outerIndex: number) => Primitive, priority?: string): Transition<Datum>;
|
||||
style(obj: { [key: string]: Primitive | ((datum: Datum, index: number, outerIndex: number) => Primitive) }, priority?: string): Transition<Datum>;
|
||||
|
||||
styleTween(name: string, tween: (datum: Datum, index: number, attr: string) => Primitive, priority?: string): Transition<Datum>;
|
||||
styleTween(name: string, tween: (datum: Datum, index: number, attr: string) => (t: number) => Primitive, priority?: string): Transition<Datum>;
|
||||
|
||||
text(value: Primitive): Transition<Datum>;
|
||||
text(value: (datum: Datum, index: number, outerIndex: number) => Primitive): Transition<Datum>;
|
||||
@@ -2196,8 +2196,7 @@ declare module d3 {
|
||||
interpolate(interpolate: "cardinal-open"): Line<T>;
|
||||
interpolate(interpolate: "cardinal-closed"): Line<T>;
|
||||
interpolate(interpolate: "monotone"): Line<T>;
|
||||
interpolate(interpolate: string): Line<T>;
|
||||
interpolate(interpolate: (points: Array<[number, number]>) => string): Line<T>;
|
||||
interpolate(interpolate: string | ((points: Array<[number, number]>) => string)): Line<T>;
|
||||
|
||||
tension(): number;
|
||||
tension(tension: number): Line<T>;
|
||||
@@ -2235,8 +2234,7 @@ declare module d3 {
|
||||
interpolate(interpolate: "cardinal-open"): Radial<T>;
|
||||
interpolate(interpolate: "cardinal-closed"): Radial<T>;
|
||||
interpolate(interpolate: "monotone"): Radial<T>;
|
||||
interpolate(interpolate: string): Radial<T>;
|
||||
interpolate(interpolate: (points: Array<[number, number]>) => string): Radial<T>;
|
||||
interpolate(interpolate: string | ((points: Array<[number, number]>) => string)): Radial<T>;
|
||||
|
||||
tension(): number;
|
||||
tension(tension: number): Radial<T>;
|
||||
@@ -2286,7 +2284,7 @@ declare module d3 {
|
||||
interpolate(interpolate: "cardinal"): Area<T>;
|
||||
interpolate(interpolate: "cardinal-open"): Area<T>;
|
||||
interpolate(interpolate: "monotone"): Area<T>;
|
||||
interpolate(interpolate: string): Area<T>;
|
||||
interpolate(interpolate: string | ((points: Array<[number, number]>) => string)): Area<T>;
|
||||
|
||||
tension(): number;
|
||||
tension(tension: number): Area<T>;
|
||||
@@ -2336,8 +2334,7 @@ declare module d3 {
|
||||
interpolate(interpolate: "cardinal"): Radial<T>;
|
||||
interpolate(interpolate: "cardinal-open"): Radial<T>;
|
||||
interpolate(interpolate: "monotone"): Radial<T>;
|
||||
interpolate(interpolate: string): Radial<T>;
|
||||
interpolate(interpolate: (points: Array<[number, number]>) => string): Radial<T>;
|
||||
interpolate(interpolate: string | ((points: Array<[number, number]>) => string)): Radial<T>;
|
||||
|
||||
tension(): number;
|
||||
tension(tension: number): Radial<T>;
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
/// <reference path="data-driven.d.ts" />
|
||||
|
||||
import data_driven = require('data-driven');
|
||||
|
||||
data_driven([
|
||||
{key:"value"},
|
||||
{key:"foobar"}
|
||||
],() => {});
|
||||
Vendored
+9
@@ -0,0 +1,9 @@
|
||||
// Type definitions for data-driven.js
|
||||
// Project: https://github.com/fluentsoftware/data-driven
|
||||
// Definitions by: Adam Babcock <https://github.com/mrhen>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
declare module "data-driven" {
|
||||
function data_driven<T>(data:T[], callback:()=>any):any;
|
||||
export = data_driven
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
///<reference path="./diff-match-patch.d.ts" />
|
||||
|
||||
import DiffMatchPatch = require("diff-match-patch");
|
||||
|
||||
var oldValue = "hello world, how are you?";
|
||||
var newValue = "hello again world. how have you been?";
|
||||
|
||||
var diffEngine = new DiffMatchPatch.diff_match_patch();
|
||||
var diffs = diffEngine.diff_main(oldValue, newValue);
|
||||
diffEngine.diff_cleanupSemantic(diffs);
|
||||
|
||||
var changes = "";
|
||||
var pattern = "";
|
||||
|
||||
diffs.forEach(function(diff) {
|
||||
var operation = diff[0]; // Operation (insert, delete, equal)
|
||||
var text = diff[1]; // Text of change
|
||||
|
||||
switch (operation) {
|
||||
case DiffMatchPatch.DIFF_INSERT:
|
||||
pattern += "I";
|
||||
break;
|
||||
case DiffMatchPatch.DIFF_DELETE:
|
||||
pattern += "D";
|
||||
break;
|
||||
case DiffMatchPatch.DIFF_EQUAL:
|
||||
pattern += "E";
|
||||
break;
|
||||
}
|
||||
|
||||
changes += text;
|
||||
});
|
||||
+39
@@ -0,0 +1,39 @@
|
||||
// Type definitions for diff-match-patch v1.0.0
|
||||
// Project: https://www.npmjs.com/package/diff-match-patch
|
||||
// Definitions by: Asana <https://asana.com>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
declare module "diff-match-patch" {
|
||||
type Diff = [number, string];
|
||||
|
||||
export class diff_match_patch {
|
||||
static new (): diff_match_patch;
|
||||
|
||||
Diff_Timeout: number;
|
||||
Diff_EditCost: number;
|
||||
Match_Threshold: number;
|
||||
Match_Distance: number;
|
||||
Patch_DeleteThreshold: number;
|
||||
Patch_Margin: number;
|
||||
Match_MaxBits: number;
|
||||
|
||||
diff_main(text1: string, text2: string, opt_checklines?: boolean, opt_deadline?: number): Diff[];
|
||||
diff_commonPrefix(text1: string, text2: string): number;
|
||||
diff_commonSuffix(text1: string, text2: string): number;
|
||||
diff_cleanupSemantic(diffs: Diff[]): void;
|
||||
diff_cleanupSemanticLossless(diffs: Diff[]): void;
|
||||
diff_cleanupEfficiency(diffs: Diff[]): void;
|
||||
diff_cleanupMerge(diffs: Diff[]): void;
|
||||
diff_xIndex(diffs: Diff[], loc: number): number;
|
||||
diff_prettyHtml(diffs: Diff[]): string;
|
||||
diff_text1(diffs: Diff[]): string;
|
||||
diff_text2(diffs: Diff[]): string;
|
||||
diff_levenshtein(diffs: Diff[]): number;
|
||||
diff_toDelta(diffs: Diff[]): string;
|
||||
diff_fromDelta(text1: string, delta: string): Diff[];
|
||||
}
|
||||
|
||||
export var DIFF_DELETE: number;
|
||||
export var DIFF_INSERT: number;
|
||||
export var DIFF_EQUAL: number;
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
import dragula = require("dragula");
|
||||
|
||||
// containers
|
||||
var d1 = dragula([document.querySelector('#left'), document.querySelector('#right')]);
|
||||
|
||||
// all options
|
||||
var d2 = dragula({
|
||||
isContainer: function (el) {
|
||||
return false;
|
||||
},
|
||||
moves: function (el, container, handle) {
|
||||
return true;
|
||||
},
|
||||
accepts: function (el, target, source, sibling) {
|
||||
return true;
|
||||
},
|
||||
invalid: function (el, target) {
|
||||
return el.tagName === 'A' || el.tagName === 'BUTTON';
|
||||
},
|
||||
direction: 'vertical',
|
||||
copy: false,
|
||||
revertOnSpill: false,
|
||||
removeOnSpill: false,
|
||||
delay: false,
|
||||
mirrorContainer: document.body
|
||||
});
|
||||
|
||||
// empty call
|
||||
var d3 = dragula();
|
||||
|
||||
|
||||
// drake API
|
||||
var drake = dragula({
|
||||
copy: true
|
||||
});
|
||||
|
||||
drake.containers.push(document.querySelector('#container'));
|
||||
@@ -0,0 +1,31 @@
|
||||
/// <reference path="dragula.d.ts" />
|
||||
|
||||
var d1 = dragula([document.querySelector('#left'), document.querySelector('#right')]);
|
||||
|
||||
var d2 = dragula({
|
||||
isContainer: function (el) {
|
||||
return false;
|
||||
},
|
||||
moves: function (el, container, handle) {
|
||||
return true;
|
||||
},
|
||||
accepts: function (el, target, source, sibling) {
|
||||
return true;
|
||||
},
|
||||
invalid: function (el, target) {
|
||||
return el.tagName === 'A' || el.tagName === 'BUTTON';
|
||||
},
|
||||
direction: 'vertical',
|
||||
copy: false,
|
||||
revertOnSpill: false,
|
||||
removeOnSpill: false,
|
||||
delay: false,
|
||||
mirrorContainer: document.body
|
||||
});
|
||||
|
||||
var d3 = dragula();
|
||||
|
||||
var drake = dragula({
|
||||
copy: true
|
||||
});
|
||||
drake.containers.push(document.querySelector('#container'));
|
||||
Vendored
+46
@@ -0,0 +1,46 @@
|
||||
// Type definitions for dragula v2.1.2
|
||||
// Project: http://bevacqua.github.io/dragula/
|
||||
// Definitions by: Paul Welter <https://github.com/pwelter34/>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
declare module dragula {
|
||||
interface DragulaOptions {
|
||||
containers?: Element[];
|
||||
isContainer?: (el?: Element) => boolean;
|
||||
moves?: (el?: Element, container?: Element, handle?: Element) => boolean;
|
||||
accepts?: (el?: Element, target?: Element, source?: Element, sibling?: Element) => boolean;
|
||||
invalid?: (el?: Element, target?: Element) => boolean;
|
||||
direction?: string;
|
||||
copy?: boolean;
|
||||
revertOnSpill?: boolean;
|
||||
removeOnSpill?: boolean;
|
||||
delay?: boolean | number;
|
||||
mirrorContainer?: Element;
|
||||
}
|
||||
|
||||
interface Drake {
|
||||
containers: Element[];
|
||||
dragging: boolean;
|
||||
start(item:Element): void;
|
||||
end(): void;
|
||||
cancel(revert:boolean): void;
|
||||
cancel(): void;
|
||||
remove(): void;
|
||||
on(events: string, callback: Function): void;
|
||||
destroy(): void;
|
||||
}
|
||||
|
||||
interface Dragula {
|
||||
(containers: Element[], options: DragulaOptions): Drake;
|
||||
(containers: Element, options: DragulaOptions): Drake;
|
||||
(containers: Element[]): Drake;
|
||||
(options: DragulaOptions): Drake;
|
||||
(): Drake;
|
||||
}
|
||||
}
|
||||
|
||||
declare var dragula: dragula.Dragula;
|
||||
|
||||
declare module "dragula" {
|
||||
export = dragula;
|
||||
}
|
||||
Vendored
+106
-73
@@ -1,95 +1,128 @@
|
||||
// Type definitions for Dropzone 3.7.1
|
||||
// Type definitions for Dropzone 4.0.1
|
||||
// Project: http://www.dropzonejs.com/
|
||||
// Definitions by: Natan Vivo <https://github.com/nvivo>
|
||||
// Definitions by: Natan Vivo <https://github.com/nvivo>, Andy Hawkins <https://github.com/a904guy/,http://a904guy.com/,http://www.bmbsqd.com>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
/// <reference path="../jquery/jquery.d.ts"/>
|
||||
|
||||
interface DropzoneFile extends File {
|
||||
previewElement: HTMLElement;
|
||||
previewTemplate: HTMLElement;
|
||||
previewsContainer: HTMLElement;
|
||||
status: string;
|
||||
accepted: boolean;
|
||||
previewElement: HTMLElement;
|
||||
previewTemplate: HTMLElement;
|
||||
previewsContainer: HTMLElement;
|
||||
status: string;
|
||||
accepted: boolean;
|
||||
}
|
||||
|
||||
interface DropzoneOptions {
|
||||
url?: string;
|
||||
method?: string;
|
||||
withCredentials?: boolean;
|
||||
parallelUploads?: number;
|
||||
maxFilesize?: number;
|
||||
paramName?: string;
|
||||
uploadMultiple?: boolean;
|
||||
headers?: any;
|
||||
addRemoveLinks?: boolean;
|
||||
previewsContainer?: string;
|
||||
clickable?: any;
|
||||
createImageThumbnails?: boolean;
|
||||
maxThumbnailFilesize?: number;
|
||||
thumbnailWidth?: number;
|
||||
thumbnailHeight?: number;
|
||||
maxFiles?: number;
|
||||
resize?: (file?: any) => any;
|
||||
init?: () => void;
|
||||
acceptedFiles?: string;
|
||||
accept?: (file: DropzoneFile, doneCallback: (...args) => void) => void;
|
||||
autoProcessQueue?: boolean;
|
||||
previewTemplate?: string;
|
||||
forceFallback?: boolean;
|
||||
fallback?: () => void;
|
||||
url?: string;
|
||||
method?: string;
|
||||
withCredentials?: boolean;
|
||||
parallelUploads?: number;
|
||||
maxFilesize?: number;
|
||||
paramName?: string;
|
||||
uploadMultiple?: boolean;
|
||||
headers?: any;
|
||||
addRemoveLinks?: boolean;
|
||||
previewsContainer?: string;
|
||||
clickable?: any;
|
||||
createImageThumbnails?: boolean;
|
||||
maxThumbnailFilesize?: number;
|
||||
thumbnailWidth?: number;
|
||||
thumbnailHeight?: number;
|
||||
maxFiles?: number;
|
||||
resize?: ( file?: any ) => any;
|
||||
init?: () => void;
|
||||
acceptedFiles?: string;
|
||||
accept?: ( file: DropzoneFile, doneCallback: ( ...args ) => void ) => void;
|
||||
autoProcessQueue?: boolean;
|
||||
previewTemplate?: string;
|
||||
forceFallback?: boolean;
|
||||
fallback?: () => void;
|
||||
|
||||
// dictionary options
|
||||
dictDefaultMessage?: string;
|
||||
dictFallbackMessage?: string;
|
||||
dictFallbackText?: string;
|
||||
dictInvalidFileType?: string;
|
||||
dictFileTooBig?: string;
|
||||
dictResponseError?: string;
|
||||
dictCancelUpload?: string;
|
||||
dictCancelUploadConfirmation?: string;
|
||||
dictRemoveFile?: string;
|
||||
dictRemoveFileConfirmation?: string;
|
||||
dictMaxFilesExceeded?: string;
|
||||
// dictionary options
|
||||
dictDefaultMessage?: string;
|
||||
dictFallbackMessage?: string;
|
||||
dictFallbackText?: string;
|
||||
dictInvalidFileType?: string;
|
||||
dictFileTooBig?: string;
|
||||
dictResponseError?: string;
|
||||
dictCancelUpload?: string;
|
||||
dictCancelUploadConfirmation?: string;
|
||||
dictRemoveFile?: string;
|
||||
dictRemoveFileConfirmation?: string;
|
||||
dictMaxFilesExceeded?: string;
|
||||
}
|
||||
|
||||
declare class Dropzone {
|
||||
constructor(container: string, options?: DropzoneOptions);
|
||||
constructor(container: HTMLElement, options?: DropzoneOptions);
|
||||
static autoDiscover: boolean;
|
||||
static options: any;
|
||||
static confirm: (question: string, accepted: () => void, rejected?: () => void) => void;
|
||||
constructor( container: string, options?: DropzoneOptions );
|
||||
constructor( container: HTMLElement, options?: DropzoneOptions );
|
||||
|
||||
files: DropzoneFile[];
|
||||
static autoDiscover: boolean;
|
||||
static options: any;
|
||||
static confirm: ( question: string, accepted: () => void, rejected?: () => void ) => void;
|
||||
|
||||
on(eventName, callback: (...args) => any);
|
||||
off(eventName): void;
|
||||
files: DropzoneFile[];
|
||||
|
||||
removeFile(file: DropzoneFile): void;
|
||||
removeAllFiles(cancelIfNecessary?: boolean): void;
|
||||
processQueue(): void;
|
||||
getAcceptedFiles(): DropzoneFile[];
|
||||
getRejectedFiles(): DropzoneFile[];
|
||||
getQueuedFiles(): DropzoneFile[];
|
||||
getUploadingFiles(): DropzoneFile[];
|
||||
enable(): void;
|
||||
disable(): void;
|
||||
destroy(): Dropzone;
|
||||
|
||||
emit(eventName: string, file: DropzoneFile, str?: string);
|
||||
emit(eventName: "thumbnail", file: DropzoneFile, path: string);
|
||||
emit(eventName: "addedfile", file: DropzoneFile);
|
||||
emit(eventName: "removedfile", file: DropzoneFile);
|
||||
emit(eventName: "processing", file: DropzoneFile);
|
||||
emit(eventName: "canceled", file: DropzoneFile);
|
||||
emit(eventName: "complete", file: DropzoneFile);
|
||||
on( eventName, callback: ( ...args ) => any );
|
||||
|
||||
emit(eventName: string, e: Event);
|
||||
emit(eventName: "drop", e: Event);
|
||||
emit(eventName: "dragstart", e: Event);
|
||||
emit(eventName: "dragend", e: Event);
|
||||
emit(eventName: "dragenter", e: Event);
|
||||
emit(eventName: "dragover", e: Event);
|
||||
emit(eventName: "dragleave", e: Event);
|
||||
off( eventName ): void;
|
||||
|
||||
addFile( file: DropzoneFile ): void;
|
||||
|
||||
removeFile( file: DropzoneFile ): void;
|
||||
|
||||
removeAllFiles( cancelIfNecessary?: boolean ): void;
|
||||
|
||||
processQueue(): void;
|
||||
|
||||
cancelUpload( file: DropzoneFile ): void;
|
||||
|
||||
processFiles ( files: DropzoneFile[] ): void;
|
||||
processFile( file: DropzoneFile ): void;
|
||||
|
||||
uploadFile( file: DropzoneFile ): void;
|
||||
|
||||
getAcceptedFiles(): DropzoneFile[];
|
||||
|
||||
getRejectedFiles(): DropzoneFile[];
|
||||
|
||||
getQueuedFiles(): DropzoneFile[];
|
||||
|
||||
getUploadingFiles(): DropzoneFile[];
|
||||
|
||||
accept( file: DropzoneFile, done: ( error?: string ) => {} ):void;
|
||||
getActiveFiles(): DropzoneFile[];
|
||||
getFilesWithStatus( status: string ): DropzoneFile[];
|
||||
enqueueFile( file: DropzoneFile ): void;
|
||||
enqueueFiles( file: DropzoneFile[] ): void;
|
||||
createThumbnail( file: DropzoneFile, callback?: (...any) => {}): any;
|
||||
createThumbnailFromUrl( file: DropzoneFile, url: string, callback?: ( ...any ) => any ): any;
|
||||
|
||||
emit( eventName: string, file: DropzoneFile, str?: string );
|
||||
emit( eventName: "thumbnail", file: DropzoneFile, path: string );
|
||||
emit( eventName: "addedfile", file: DropzoneFile );
|
||||
emit( eventName: "removedfile", file: DropzoneFile );
|
||||
emit( eventName: "processing", file: DropzoneFile );
|
||||
emit( eventName: "canceled", file: DropzoneFile );
|
||||
emit( eventName: "complete", file: DropzoneFile );
|
||||
|
||||
emit( eventName: string, e: Event );
|
||||
emit( eventName: "drop", e: Event );
|
||||
emit( eventName: "dragstart", e: Event );
|
||||
emit( eventName: "dragend", e: Event );
|
||||
emit( eventName: "dragenter", e: Event );
|
||||
emit( eventName: "dragover", e: Event );
|
||||
emit( eventName: "dragleave", e: Event );
|
||||
}
|
||||
|
||||
interface JQuery {
|
||||
dropzone(options: DropzoneOptions): Dropzone;
|
||||
dropzone( options: DropzoneOptions ): Dropzone;
|
||||
}
|
||||
|
||||
declare module "dropzone" {
|
||||
export = Dropzone;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,214 @@
|
||||
/// <reference path="../jquery/jquery.d.ts" />
|
||||
/// <reference path="dw-bxslider-4.d.ts" />
|
||||
|
||||
// examples from http://bxslider.com/examples
|
||||
|
||||
$(document).ready(function() {
|
||||
$('.bxslider1').bxSlider({
|
||||
mode: 'fade',
|
||||
captions: true
|
||||
});
|
||||
|
||||
$('.bxslider2').bxSlider({
|
||||
auto: true,
|
||||
autoControls: true
|
||||
});
|
||||
|
||||
$('.bxslider3').bxSlider({
|
||||
infiniteLoop: false,
|
||||
hideControlOnEnd: true
|
||||
});
|
||||
|
||||
$('.bxslider4').bxSlider({
|
||||
adaptiveHeight: true,
|
||||
mode: 'fade'
|
||||
});
|
||||
|
||||
$('.slider1').bxSlider({
|
||||
slideWidth: 200,
|
||||
minSlides: 2,
|
||||
maxSlides: 3,
|
||||
slideMargin: 10
|
||||
});
|
||||
|
||||
$('.slider2').bxSlider({
|
||||
slideWidth: 300,
|
||||
minSlides: 2,
|
||||
maxSlides: 2,
|
||||
slideMargin: 10
|
||||
});
|
||||
|
||||
$('.slider3').bxSlider({
|
||||
slideWidth: 5000,
|
||||
minSlides: 2,
|
||||
maxSlides: 4,
|
||||
slideMargin: 10
|
||||
});
|
||||
|
||||
$('.slider4').bxSlider({
|
||||
slideWidth: 300,
|
||||
minSlides: 2,
|
||||
maxSlides: 3,
|
||||
moveSlides: 1,
|
||||
slideMargin: 10
|
||||
});
|
||||
|
||||
$('.slider5').bxSlider({
|
||||
slideWidth: 300,
|
||||
minSlides: 3,
|
||||
maxSlides: 3,
|
||||
moveSlides: 3,
|
||||
slideMargin: 10
|
||||
});
|
||||
|
||||
$('.slider6').bxSlider({
|
||||
slideWidth: 300,
|
||||
minSlides: 2,
|
||||
maxSlides: 3,
|
||||
startSlide: 2,
|
||||
slideMargin: 10
|
||||
});
|
||||
|
||||
$('.slider7').bxSlider({
|
||||
slideWidth: 200,
|
||||
minSlides: 4,
|
||||
maxSlides: 5,
|
||||
slideMargin: 10
|
||||
});
|
||||
|
||||
$('.slider8').bxSlider({
|
||||
mode: 'vertical',
|
||||
slideWidth: 300,
|
||||
minSlides: 2,
|
||||
slideMargin: 10
|
||||
});
|
||||
|
||||
$('.bxslider6').bxSlider({
|
||||
minSlides: 2,
|
||||
maxSlides: 2,
|
||||
slideWidth: 360,
|
||||
slideMargin: 10
|
||||
});
|
||||
|
||||
$('.bxslider7').bxSlider({
|
||||
minSlides: 3,
|
||||
maxSlides: 4,
|
||||
slideWidth: 170,
|
||||
slideMargin: 10
|
||||
});
|
||||
|
||||
$('.bxslider8').bxSlider({
|
||||
pagerCustom: '#bx-pager'
|
||||
});
|
||||
$('.bxslider9').bxSlider({
|
||||
buildPager: function(slideIndex) {
|
||||
switch (slideIndex) {
|
||||
case 0:
|
||||
return '<img src="/images/thumbs/tree_root.jpg">';
|
||||
case 1:
|
||||
return '<img src="/images/thumbs/houses.jpg">';
|
||||
case 2:
|
||||
return '<img src="/images/thumbs/hill_fence.jpg">';
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
$('.bxslider10').bxSlider({
|
||||
mode: 'vertical',
|
||||
slideMargin: 5
|
||||
});
|
||||
|
||||
$('.bxslider11').bxSlider({
|
||||
nextSelector: '#slider-next',
|
||||
prevSelector: '#slider-prev',
|
||||
nextText: 'Onward →',
|
||||
prevText: '← Go back'
|
||||
});
|
||||
|
||||
$('.bxslider12a').bxSlider({
|
||||
mode: 'fade',
|
||||
auto: true,
|
||||
autoControls: true,
|
||||
pause: 2000
|
||||
});
|
||||
|
||||
$('.bxslider12b').bxSlider({
|
||||
auto: true,
|
||||
autoControls: true,
|
||||
pause: 3000,
|
||||
slideMargin: 20
|
||||
});
|
||||
|
||||
$('.bxslider13').bxSlider({
|
||||
onSliderLoad: function() {
|
||||
// do funky JS stuff here
|
||||
alert('Slider has finished loading. Click OK to continue!');
|
||||
},
|
||||
onSlideAfter: function() {
|
||||
// do mind-blowing JS stuff here
|
||||
alert('A slide has finished transitioning. Bravo. Click OK to continue!');
|
||||
}
|
||||
});
|
||||
|
||||
var slider = $('.bxslider14').bxSlider({
|
||||
mode: 'fade'
|
||||
});
|
||||
|
||||
$('#slider-next').click(function() {
|
||||
slider.goToNextSlide();
|
||||
return false;
|
||||
});
|
||||
|
||||
$('#slider-count').click(function() {
|
||||
var count = slider.getSlideCount();
|
||||
alert('Slide count: ' + count);
|
||||
return false;
|
||||
});
|
||||
|
||||
$('.bxslider15').bxSlider({
|
||||
video: true,
|
||||
useCSS: false
|
||||
});
|
||||
|
||||
$('.bxslider16').bxSlider({
|
||||
minSlides: 4,
|
||||
maxSlides: 4,
|
||||
slideWidth: 170,
|
||||
slideMargin: 10,
|
||||
ticker: true,
|
||||
speed: 6000
|
||||
});
|
||||
|
||||
$('.bxslider17').bxSlider({
|
||||
mode: 'horizontal',
|
||||
useCSS: false,
|
||||
infiniteLoop: false,
|
||||
hideControlOnEnd: true,
|
||||
easing: 'easeOutElastic',
|
||||
speed: 2000
|
||||
});
|
||||
|
||||
var slider = $('.bxslider18').bxSlider({
|
||||
mode: 'horizontal'
|
||||
});
|
||||
|
||||
$('#reload-slider').click(function(e) {
|
||||
e.preventDefault();
|
||||
$('.bxslider').append('<li><img src="/images/730_200/trees.jpg"></li>');
|
||||
slider.reloadSlider();
|
||||
});
|
||||
|
||||
var slider = $('.bxslider19').bxSlider({
|
||||
mode: 'horizontal'
|
||||
});
|
||||
|
||||
$('#reload-slider').click(function(e) {
|
||||
e.preventDefault();
|
||||
slider.reloadSlider({
|
||||
mode: 'fade',
|
||||
auto: true,
|
||||
pause: 1000,
|
||||
speed: 500
|
||||
});
|
||||
});
|
||||
});
|
||||
Vendored
+623
@@ -0,0 +1,623 @@
|
||||
// Type definitions for bxSlider v4.2.5
|
||||
// Project: https://github.com/stevenwanderski/bxslider-4
|
||||
// Definitions by: Piotr Sałkowski <https://github.com/namerci>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
///<reference path="../jquery/jquery.d.ts"/>
|
||||
|
||||
interface bxSliderOptions {
|
||||
/**
|
||||
* mode Type of transition between slides
|
||||
*
|
||||
* default: 'horizontal'
|
||||
* options: 'horizontal', 'vertical', 'fade'
|
||||
*/
|
||||
mode?: string
|
||||
|
||||
/**
|
||||
* speed Slide transition duration (in ms)
|
||||
*
|
||||
* default: 500
|
||||
* options: integer
|
||||
*/
|
||||
speed?: number
|
||||
|
||||
/**
|
||||
* slideMargin Margin between each slide
|
||||
*
|
||||
* default: 0
|
||||
* options: integer
|
||||
*/
|
||||
slideMargin?: number
|
||||
|
||||
/**
|
||||
* startSlide Starting slide index (zero-based)
|
||||
*
|
||||
* default: 0
|
||||
* options: integer
|
||||
*/
|
||||
startSlide?: number
|
||||
|
||||
/**
|
||||
* randomStart Start slider on a random slide
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
randomStart?: boolean
|
||||
|
||||
/**
|
||||
* slideSelector Element to use as slides (ex. 'div.slide').
|
||||
* Note: by default, bxSlider will use all immediate children of the slider element
|
||||
*
|
||||
* default: ''
|
||||
* options: jQuery selector
|
||||
*/
|
||||
slideSelector?: string
|
||||
|
||||
/**
|
||||
* infiniteLoop If true, clicking "Next" while on the last slide will transition to the first slide and vice-versa
|
||||
*
|
||||
* default: true
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
infiniteLoop?: boolean
|
||||
|
||||
/**
|
||||
* hideControlOnEnd If true, "Prev" and "Next" controls will receive a class disabled when slide is the first or the last
|
||||
* Note: Only used when infiniteLoop: false
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
hideControlOnEnd?: boolean
|
||||
|
||||
/**
|
||||
* easing The type of "easing" to use during transitions. If using CSS transitions, include a value for the transition-timing-function property. If not using CSS transitions, you may include plugins/jquery.easing.1.3.js for many options.
|
||||
* See http://gsgd.co.uk/sandbox/jquery/easing/ for more info.
|
||||
*
|
||||
* default: null
|
||||
* options: if using CSS: 'linear', 'ease', 'ease-in', 'ease-out', 'ease-in-out', 'cubic-bezier(n,n,n,n)'. If not using CSS: 'swing', 'linear' (see the above file for more options)
|
||||
*/
|
||||
easing?: string
|
||||
|
||||
/**
|
||||
* captions Include image captions. Captions are derived from the image's title attribute
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
captions?: boolean
|
||||
|
||||
/**
|
||||
* ticker Use slider in ticker mode (similar to a news ticker)
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
ticker?: boolean
|
||||
|
||||
/**
|
||||
* tickerHover Ticker will pause when mouse hovers over slider. Note: this functionality does NOT work if using CSS transitions!
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
tickerHover?: boolean
|
||||
|
||||
/**
|
||||
* adaptiveHeight Dynamically adjust slider height based on each slide's height
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
adaptiveHeight?: boolean
|
||||
|
||||
/**
|
||||
* adaptiveHeightSpeed Slide height transition duration (in ms). Note: only used if adaptiveHeight: true
|
||||
*
|
||||
* default: 500
|
||||
* options: integer
|
||||
*/
|
||||
adaptiveHeightSpeed?: number
|
||||
|
||||
/**
|
||||
* video If any slides contain video, set this to true. Also, include plugins/jquery.fitvids.js
|
||||
* See http://fitvidsjs.com/ for more info
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
video?: boolean
|
||||
|
||||
/**
|
||||
* responsive Enable or disable auto resize of the slider. Useful if you need to use fixed width sliders.
|
||||
*
|
||||
* default: true
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
responsive?: boolean
|
||||
|
||||
/**
|
||||
* useCSS If true, CSS transitions will be used for horizontal and vertical slide animations (this uses native hardware acceleration). If false, jQuery animate() will be used.
|
||||
*
|
||||
* default: true
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
useCSS?: boolean
|
||||
|
||||
/**
|
||||
* preloadImages If 'all', preloads all images before starting the slider. If 'visible', preloads only images in the initially visible slides before starting the slider (tip: use 'visible' if all slides are identical dimensions)
|
||||
*
|
||||
* default: 'visible'
|
||||
* options: 'all', 'visible'
|
||||
*/
|
||||
preloadImages?: string
|
||||
|
||||
/**
|
||||
* touchEnabled If true, slider will allow touch swipe transitions
|
||||
*
|
||||
* default: true
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
touchEnabled?: boolean
|
||||
|
||||
/**
|
||||
* swipeThreshold Amount of pixels a touch swipe needs to exceed in order to execute a slide transition. Note: only used if touchEnabled: true
|
||||
*
|
||||
* default: 50
|
||||
* options: integer
|
||||
*/
|
||||
swipeThreshold?: number
|
||||
|
||||
/**
|
||||
* oneToOneTouch If true, non-fade slides follow the finger as it swipes
|
||||
*
|
||||
* default: true
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
oneToOneTouch?: boolean
|
||||
|
||||
/**
|
||||
* preventDefaultSwipeX If true, touch screen will not move along the x-axis as the finger swipes
|
||||
*
|
||||
* default: true
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
preventDefaultSwipeX?: boolean
|
||||
|
||||
/**
|
||||
* preventDefaultSwipeY If true, touch screen will not move along the y-axis as the finger swipes
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
preventDefaultSwipeY?: boolean
|
||||
|
||||
/**
|
||||
* wrapperClass Class to wrap the slider in. Change to prevent from using default bxSlider styles.
|
||||
*
|
||||
* default: 'bx-wrapper'
|
||||
* options: string
|
||||
*/
|
||||
wrapperClass?: string
|
||||
|
||||
/**
|
||||
* pager If true, a pager will be added
|
||||
*
|
||||
* default: true
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
pager?: boolean
|
||||
|
||||
/**
|
||||
* pagerType If 'full', a pager link will be generated for each slide. If 'short', a x / y pager will be used (ex. 1 / 5)
|
||||
*
|
||||
* default: 'full'
|
||||
* options: 'full', 'short'
|
||||
*/
|
||||
pagerType?: string
|
||||
|
||||
/**
|
||||
* pagerShortSeparator If pagerType: 'short', pager will use this value as the separating character
|
||||
*
|
||||
* default: ' / '
|
||||
* options: string
|
||||
*/
|
||||
pagerShortSeparator?: string
|
||||
|
||||
/**
|
||||
* pagerSelector Element used to populate the populate the pager. By default, the pager is appended to the bx-viewport
|
||||
*
|
||||
* default: ''
|
||||
* options: jQuery selector
|
||||
*/
|
||||
pagerSelector?: string
|
||||
|
||||
/**
|
||||
* pagerCustom Parent element to be used as the pager. Parent element must contain a <a data-slide-index="x"> element for each slide. See example here. Not for use with dynamic carousels.
|
||||
*
|
||||
* default: null
|
||||
* options: jQuery selector
|
||||
*/
|
||||
pagerCustom?: string
|
||||
|
||||
/**
|
||||
* buildPager If supplied, function is called on every slide element, and the returned value is used as the pager item markup.
|
||||
* See examples for detailed implementation
|
||||
*
|
||||
* default: null
|
||||
* options: functoin(slideIndex)
|
||||
*/
|
||||
buildPager?: (slideIndex: number) => void;
|
||||
|
||||
|
||||
/**
|
||||
* controls If true, "Next" / "Prev" controls will be added
|
||||
*
|
||||
* default: true
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
controls?: boolean
|
||||
|
||||
/**
|
||||
* nextText Text to be used for the "Next" control
|
||||
*
|
||||
* default: 'Next'
|
||||
* options: string
|
||||
*/
|
||||
nextText?: string
|
||||
|
||||
/**
|
||||
* prevText Text to be used for the "Prev" control
|
||||
*
|
||||
* default: 'Prev'
|
||||
* options: string
|
||||
*/
|
||||
prevText?: string
|
||||
|
||||
/**
|
||||
* nextSelector Element used to populate the "Next" control
|
||||
*
|
||||
* default: null
|
||||
* options: jQuery selector
|
||||
*/
|
||||
nextSelector?: string
|
||||
|
||||
/**
|
||||
* prevSelector Element used to populate the "Prev" control
|
||||
*
|
||||
* default: null
|
||||
* options: jQuery selector
|
||||
*/
|
||||
prevSelector?: string
|
||||
|
||||
/**
|
||||
* autoControls If true, "Start" / "Stop" controls will be added
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
autoControls?: boolean
|
||||
|
||||
/**
|
||||
* startText Text to be used for the "Start" control
|
||||
*
|
||||
* default: 'Start'
|
||||
* options: string
|
||||
*/
|
||||
startText?: string
|
||||
|
||||
/**
|
||||
* stopText Text to be used for the "Stop" control
|
||||
*
|
||||
* default: 'Stop'
|
||||
* options: string
|
||||
*/
|
||||
stopText?: string
|
||||
|
||||
/**
|
||||
* autoControlsCombine When slideshow is playing only "Stop" control is displayed and vice-versa
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
autoControlsCombine?: boolean
|
||||
|
||||
/**
|
||||
* autoControlsSelector Element used to populate the auto controls
|
||||
*
|
||||
* default: null
|
||||
* options: jQuery selector
|
||||
*/
|
||||
autoControlsSelector?: string
|
||||
|
||||
/**
|
||||
* keyboardEnabled Allows for keyboard control of visible slider. Keypress ignored if slider not visible.
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
keyboardEnabled?: boolean
|
||||
|
||||
/**
|
||||
* auto Slides will automatically transition
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
auto?: boolean
|
||||
|
||||
/**
|
||||
* stopAutoOnClick Auto will stop on interaction with controls
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
stopAutoOnClick?: boolean
|
||||
|
||||
/**
|
||||
* pause The amount of time (in ms) between each auto transition
|
||||
*
|
||||
* default: 4000
|
||||
* options: integer
|
||||
*/
|
||||
pause?: number
|
||||
|
||||
/**
|
||||
* autoStart Auto show starts playing on load. If false, slideshow will start when the "Start" control is clicked
|
||||
*
|
||||
* default: true
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
autoStart?: boolean
|
||||
|
||||
/**
|
||||
* autoDirection The direction of auto show slide transitions
|
||||
*
|
||||
* default: 'next'
|
||||
* options: 'next', 'prev'
|
||||
*/
|
||||
autoDirection?: string
|
||||
|
||||
/**
|
||||
* autoHover Auto show will pause when mouse hovers over slider
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
autoHover?: boolean
|
||||
|
||||
/**
|
||||
* autoDelay Time (in ms) auto show should wait before starting
|
||||
*
|
||||
* default: 0
|
||||
* options: integer
|
||||
*/
|
||||
autoDelay?: number
|
||||
|
||||
/**
|
||||
* minSlides The minimum number of slides to be shown. Slides will be sized down if carousel becomes smaller than the original size.
|
||||
*
|
||||
* default: 1
|
||||
* options: integer
|
||||
*/
|
||||
minSlides?: number
|
||||
|
||||
/**
|
||||
* maxSlides The maximum number of slides to be shown. Slides will be sized up if carousel becomes larger than the original size.
|
||||
*
|
||||
* default: 1
|
||||
* options: integer
|
||||
*/
|
||||
maxSlides?: number
|
||||
|
||||
/**
|
||||
* moveSlides The number of slides to move on transition. This value must be >= minSlides, and <= maxSlides. If zero (default), the number of fully-visible slides will be used.
|
||||
*
|
||||
* default: 0
|
||||
* options: integer
|
||||
*/
|
||||
moveSlides?: number
|
||||
|
||||
/**
|
||||
* slideWidth The width of each slide. This setting is required for all horizontal carousels!
|
||||
*
|
||||
* default: 0
|
||||
* options: integer
|
||||
*/
|
||||
slideWidth?: number
|
||||
|
||||
/**
|
||||
* shrinkItems The Carousel will only show whole items and shrink the images to fit the viewport based on maxSlides/MinSlides.
|
||||
*
|
||||
* default: false
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
shrinkItems?: boolean
|
||||
|
||||
/**
|
||||
* ariaLive Adds Aria Live attribute to slider.
|
||||
*
|
||||
* default: true
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
ariaLive?: boolean
|
||||
|
||||
/**
|
||||
* ariaHidden Adds Aria Hidden attribute to any nonvisible slides.
|
||||
*
|
||||
* default: true
|
||||
* options: boolean (true / false)
|
||||
*/
|
||||
ariaHidden?: boolean
|
||||
|
||||
/**
|
||||
* onSliderLoad Executes immediately after the slider is fully loaded
|
||||
*
|
||||
* default: function(){}
|
||||
* options: function(currentIndex){ // your code here }
|
||||
* arguments:
|
||||
* currentIndex: element index of the current slide
|
||||
*/
|
||||
onSliderLoad?: (currentIndex?: number) => void;
|
||||
|
||||
/**
|
||||
* onSliderResize Executes immediately after the slider is resized
|
||||
*
|
||||
* default: function(){}
|
||||
* options: function(currentIndex){ // your code here }
|
||||
* arguments:
|
||||
* currentIndex: element index of the current slide
|
||||
*/
|
||||
onSliderResize?: (currentIndex?: number) => void;
|
||||
|
||||
/**
|
||||
* onSlideBefore Executes immediately before each slide transition.
|
||||
*
|
||||
* default: function(){}
|
||||
* options: function($slideElement, oldIndex, newIndex){ // your code here }
|
||||
* arguments:
|
||||
* $slideElement: jQuery element of the destination element
|
||||
* oldIndex: element index of the previous slide (before the transition)
|
||||
* newIndex: element index of the destination slide (after the transition)
|
||||
*/
|
||||
onSlideBefore?: ($slideElement?: JQuery, oldIndex?: number, newIndex?: number) => void;
|
||||
|
||||
/**
|
||||
* onSlideAfter Executes immediately after each slide transition. Function argument is the current slide element (when transition completes).
|
||||
*
|
||||
* default: function(){}
|
||||
* options: function($slideElement, oldIndex, newIndex){ // your code here }
|
||||
* arguments:
|
||||
* $slideElement: jQuery element of the destination element
|
||||
* oldIndex: element index of the previous slide (before the transition)
|
||||
* newIndex: element index of the destination slide (after the transition)
|
||||
*/
|
||||
onSlideAfter?: ($slideElement?: JQuery, oldIndex?: number, newIndex?: number) => void;
|
||||
|
||||
/**
|
||||
* onSlideNext Executes immediately before each "Next" slide transition. Function argument is the target (next) slide element.
|
||||
*
|
||||
* default: function(){}
|
||||
* options: function($slideElement, oldIndex, newIndex){ // your code here }
|
||||
* arguments:
|
||||
* $slideElement: jQuery element of the destination element
|
||||
* oldIndex: element index of the previous slide (before the transition)
|
||||
* newIndex: element index of the destination slide (after the transition)
|
||||
*/
|
||||
onSlideNext?: ($slideElement?: JQuery, oldIndex?: number, newIndex?: number) => void;
|
||||
|
||||
/**
|
||||
* onSlidePrev Executes immediately before each "Prev" slide transition. Function argument is the target (prev) slide element.
|
||||
*
|
||||
* default: function(){}
|
||||
* options: function($slideElement, oldIndex, newIndex){ // your code here }
|
||||
* arguments:
|
||||
* $slideElement: jQuery element of the destination element
|
||||
* oldIndex: element index of the previous slide (before the transition)
|
||||
* newIndex: element index of the destination slide (after the transition)
|
||||
*/
|
||||
onSlidePrev?: ($slideElement?: JQuery, oldIndex?: number, newIndex?: number) => void;
|
||||
}
|
||||
|
||||
interface bxSlider {
|
||||
|
||||
/**
|
||||
* goToSlide Performs a slide transition to the supplied slide index (zero-based)
|
||||
*
|
||||
* example:
|
||||
* slider = $('.bxslider').bxSlider();
|
||||
* slider.goToSlide(3);
|
||||
*/
|
||||
goToSlide: (index: number) => void;
|
||||
|
||||
/**
|
||||
* goToNextSlide Performs a "Next" slide transition
|
||||
*
|
||||
* example:
|
||||
* slider = $('.bxslider').bxSlider();
|
||||
* slider.goToNextSlide();
|
||||
*/
|
||||
goToNextSlide: () => void;
|
||||
|
||||
/**
|
||||
* goToPrevSlide Performs a "Prev" slide transition
|
||||
*
|
||||
* example:
|
||||
* slider = $('.bxslider').bxSlider();
|
||||
* slider.goToPrevSlide();
|
||||
*/
|
||||
goToPrevSlide: () => void;
|
||||
|
||||
/**
|
||||
* startAuto Starts the auto show. Provide an argument false to prevent the auto controls from being updated.
|
||||
*
|
||||
* example:
|
||||
* slider = $('.bxslider').bxSlider();
|
||||
* slider.startAuto();
|
||||
*/
|
||||
startAuto: (preventControlUpdate?: boolean) => void;
|
||||
|
||||
/**
|
||||
* stopAuto Stops the auto show. Provide an argument false to prevent the auto controls from being updated.
|
||||
*
|
||||
* example:
|
||||
* slider = $('.bxslider').bxSlider();
|
||||
* slider.stopAuto();
|
||||
*/
|
||||
stopAuto: (preventControlUpdate?: boolean) => void;
|
||||
|
||||
/**
|
||||
* getCurrentSlide Returns the current active slide
|
||||
*
|
||||
* example:
|
||||
* slider = $('.bxslider').bxSlider();
|
||||
* var current = slider.getCurrentSlide();
|
||||
*/
|
||||
getCurrentSlide: () => number;
|
||||
|
||||
/**
|
||||
* getSlideCount Returns the total number of slides in the slider
|
||||
*
|
||||
* example:
|
||||
* slider = $('.bxslider').bxSlider();
|
||||
* var slideQty = slider.getSlideCount();
|
||||
*/
|
||||
getSlideCount: () => number;
|
||||
|
||||
/**
|
||||
* redrawSlider Redraw the slider. Useful when needing to redraw a hidden slider after it is unhidden.
|
||||
*
|
||||
* example:
|
||||
* slider = $('.bxslider').bxSlider();
|
||||
* slider.redrawSlider();
|
||||
*/
|
||||
redrawSlider: () => void;
|
||||
|
||||
/**
|
||||
* reloadSlider Reload the slider. Useful when adding slides on the fly. Accepts an optional settings object. See here for an example.
|
||||
*
|
||||
* example:
|
||||
* slider = $('.bxslider').bxSlider();
|
||||
* slider.reloadSlider();
|
||||
*/
|
||||
reloadSlider: (settings?: bxSliderOptions) => void;
|
||||
|
||||
/**
|
||||
* destroySlider Destroy the slider. This reverts all slider elements back to their original state (before calling the slider).
|
||||
*
|
||||
* example:
|
||||
* slider = $('.bxslider').bxSlider();
|
||||
* slider.destroySlider();
|
||||
*/
|
||||
destroySlider: () => void;
|
||||
}
|
||||
|
||||
interface JQuery {
|
||||
/**
|
||||
* Creates a bxSlider from the current element.
|
||||
* @param options
|
||||
*/
|
||||
bxSlider(options?:bxSliderOptions): bxSlider;
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
/// <reference path="eqjs.d.ts" />
|
||||
/// <reference path="eq.js.d.ts" />
|
||||
/// <reference path="../jquery/jquery.d.ts" />
|
||||
|
||||
var nodes = document.getElementsByClassName(".test-container");
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
--noImplicitAny --module commonjs --target es5
|
||||
@@ -1 +0,0 @@
|
||||
--noImplicitAny --module commonjs --target es5
|
||||
Vendored
+84
-14
@@ -6,29 +6,99 @@
|
||||
/// <reference path="../estree/estree.d.ts" />
|
||||
|
||||
declare module esprima {
|
||||
var version: string
|
||||
function parse(code: string, options?: Options): ESTree.Program
|
||||
function tokenize(code: string, options?: Options): Array<Token>
|
||||
|
||||
const version: string;
|
||||
|
||||
function parse(code: string, options?: Options): ESTree.Program;
|
||||
function tokenize(code: string, options?: Options): Array<Token>;
|
||||
|
||||
interface Token {
|
||||
type: string
|
||||
value: string
|
||||
type: string;
|
||||
value: string;
|
||||
}
|
||||
|
||||
interface Comment extends ESTree.Node {
|
||||
value: string
|
||||
value: string;
|
||||
}
|
||||
|
||||
interface Options {
|
||||
loc?: boolean
|
||||
range?: boolean
|
||||
raw?: boolean
|
||||
tokens?: boolean
|
||||
comment?: boolean
|
||||
attachComment?: boolean
|
||||
tolerant?: boolean
|
||||
source?: boolean
|
||||
loc?: boolean;
|
||||
range?: boolean;
|
||||
raw?: boolean;
|
||||
tokens?: boolean;
|
||||
comment?: boolean;
|
||||
attachComment?: boolean;
|
||||
tolerant?: boolean;
|
||||
source?: boolean;
|
||||
}
|
||||
|
||||
const Syntax: {
|
||||
AssignmentExpression: string,
|
||||
AssignmentPattern: string,
|
||||
ArrayExpression: string,
|
||||
ArrayPattern: string,
|
||||
ArrowFunctionExpression: string,
|
||||
BlockStatement: string,
|
||||
BinaryExpression: string,
|
||||
BreakStatement: string,
|
||||
CallExpression: string,
|
||||
CatchClause: string,
|
||||
ClassBody: string,
|
||||
ClassDeclaration: string,
|
||||
ClassExpression: string,
|
||||
ConditionalExpression: string,
|
||||
ContinueStatement: string,
|
||||
DoWhileStatement: string,
|
||||
DebuggerStatement: string,
|
||||
EmptyStatement: string,
|
||||
ExportAllDeclaration: string,
|
||||
ExportDefaultDeclaration: string,
|
||||
ExportNamedDeclaration: string,
|
||||
ExportSpecifier: string,
|
||||
ExpressionStatement: string,
|
||||
ForStatement: string,
|
||||
ForOfStatement: string,
|
||||
ForInStatement: string,
|
||||
FunctionDeclaration: string,
|
||||
FunctionExpression: string,
|
||||
Identifier: string,
|
||||
IfStatement: string,
|
||||
ImportDeclaration: string,
|
||||
ImportDefaultSpecifier: string,
|
||||
ImportNamespaceSpecifier: string,
|
||||
ImportSpecifier: string,
|
||||
Literal: string,
|
||||
LabeledStatement: string,
|
||||
LogicalExpression: string,
|
||||
MemberExpression: string,
|
||||
MethodDefinition: string,
|
||||
NewExpression: string,
|
||||
ObjectExpression: string,
|
||||
ObjectPattern: string,
|
||||
Program: string,
|
||||
Property: string,
|
||||
RestElement: string,
|
||||
ReturnStatement: string,
|
||||
SequenceExpression: string,
|
||||
SpreadElement: string,
|
||||
Super: string,
|
||||
SwitchCase: string,
|
||||
SwitchStatement: string,
|
||||
TaggedTemplateExpression: string,
|
||||
TemplateElement: string,
|
||||
TemplateLiteral: string,
|
||||
ThisExpression: string,
|
||||
ThrowStatement: string,
|
||||
TryStatement: string,
|
||||
UnaryExpression: string,
|
||||
UpdateExpression: string,
|
||||
VariableDeclaration: string,
|
||||
VariableDeclarator: string,
|
||||
WhileStatement: string,
|
||||
WithStatement: string,
|
||||
YieldExpression: string
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
declare module "esprima" {
|
||||
|
||||
@@ -59,7 +59,6 @@ expression = withStatement.object;
|
||||
var switchStatement: ESTree.SwitchStatement;
|
||||
expression = switchStatement.discriminant;
|
||||
switchCase = switchStatement.cases[0];
|
||||
boolean = switchStatement.lexical;
|
||||
|
||||
// ReturnStatement
|
||||
var returnStatement: ESTree.ReturnStatement;
|
||||
@@ -164,7 +163,6 @@ statement = switchCase.consequent[0];
|
||||
// CatchClause
|
||||
string = catchClause.type;
|
||||
pattern = catchClause.param;
|
||||
expression = catchClause.guard;
|
||||
blockStatement = catchClause.body;
|
||||
|
||||
// Misc
|
||||
|
||||
Vendored
+20
-21
@@ -22,7 +22,7 @@ declare module ESTree {
|
||||
}
|
||||
|
||||
interface Program extends Node {
|
||||
body: Array<Statement>;
|
||||
body: Array<Statement | ModuleDeclaration>;
|
||||
sourceType: string;
|
||||
}
|
||||
|
||||
@@ -72,7 +72,6 @@ declare module ESTree {
|
||||
interface SwitchStatement extends Statement {
|
||||
discriminant: Expression;
|
||||
cases: Array<SwitchCase>;
|
||||
lexical: boolean;
|
||||
}
|
||||
|
||||
interface ReturnStatement extends Statement {
|
||||
@@ -215,7 +214,6 @@ declare module ESTree {
|
||||
|
||||
interface CatchClause extends Node {
|
||||
param: Pattern;
|
||||
guard: any;
|
||||
body: BlockStatement;
|
||||
}
|
||||
|
||||
@@ -227,7 +225,7 @@ declare module ESTree {
|
||||
value?: string | boolean | number | RegExp;
|
||||
}
|
||||
|
||||
interface RegexLiteral extends Literal {
|
||||
interface RegExpLiteral extends Literal {
|
||||
regex: {
|
||||
pattern: string;
|
||||
flags: string;
|
||||
@@ -258,6 +256,7 @@ declare module ESTree {
|
||||
|
||||
interface YieldExpression extends Expression {
|
||||
argument?: Expression;
|
||||
delegate: boolean;
|
||||
}
|
||||
|
||||
interface TemplateLiteral extends Expression {
|
||||
@@ -274,7 +273,7 @@ declare module ESTree {
|
||||
tail: boolean;
|
||||
value: {
|
||||
cooked: string;
|
||||
value: string;
|
||||
raw: string;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -312,7 +311,7 @@ declare module ESTree {
|
||||
}
|
||||
|
||||
interface MethodDefinition extends Node {
|
||||
key: Identifier;
|
||||
key: Expression;
|
||||
value: FunctionExpression;
|
||||
kind: string;
|
||||
computed: boolean;
|
||||
@@ -330,40 +329,40 @@ declare module ESTree {
|
||||
property: Identifier;
|
||||
}
|
||||
|
||||
interface ImportDeclaration extends Node {
|
||||
interface ModuleDeclaration extends Node {}
|
||||
|
||||
interface ModuleSpecifier extends Node {
|
||||
local: Identifier;
|
||||
}
|
||||
|
||||
interface ImportDeclaration extends ModuleDeclaration {
|
||||
specifiers: Array<ImportSpecifier | ImportDefaultSpecifier | ImportNamespaceSpecifier>;
|
||||
source: Literal;
|
||||
}
|
||||
|
||||
interface ImportSpecifier {
|
||||
interface ImportSpecifier extends ModuleSpecifier {
|
||||
imported: Identifier;
|
||||
local: Identifier;
|
||||
}
|
||||
|
||||
interface ImportDefaultSpecifier {
|
||||
local: Identifier;
|
||||
}
|
||||
interface ImportDefaultSpecifier extends ModuleSpecifier {}
|
||||
|
||||
interface ImportNamespaceSpecifier {
|
||||
local: Identifier;
|
||||
}
|
||||
interface ImportNamespaceSpecifier extends ModuleSpecifier {}
|
||||
|
||||
interface ExportNamedDeclaration extends Node {
|
||||
interface ExportNamedDeclaration extends ModuleDeclaration {
|
||||
declaration?: Declaration;
|
||||
specifiers: Array<ExportSpecifier>;
|
||||
source?: Literal;
|
||||
}
|
||||
|
||||
interface ExportSpecifier {
|
||||
interface ExportSpecifier extends ModuleSpecifier {
|
||||
exported: Identifier;
|
||||
local: Identifier;
|
||||
}
|
||||
|
||||
interface ExportDefaultDeclaration extends Node {
|
||||
interface ExportDefaultDeclaration extends ModuleDeclaration {
|
||||
declaration: Declaration | Expression;
|
||||
}
|
||||
|
||||
interface ExportAllDeclaration extends Node {
|
||||
interface ExportAllDeclaration extends ModuleDeclaration {
|
||||
source: Literal;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Vendored
+174
@@ -0,0 +1,174 @@
|
||||
// Type definitions for ESTree AST extensions for Facebook Flow
|
||||
// Project: https://github.com/estree/estree
|
||||
// Definitions by: RReverser <https://github.com/RReverser>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
/// <reference path="./estree.d.ts" />
|
||||
|
||||
declare module ESTree {
|
||||
interface FlowTypeAnnotation extends Node {}
|
||||
|
||||
interface FlowBaseTypeAnnotation extends FlowTypeAnnotation {}
|
||||
|
||||
interface FlowLiteralTypeAnnotation extends FlowTypeAnnotation, Literal {}
|
||||
|
||||
interface FlowDeclaration extends Declaration {}
|
||||
|
||||
interface AnyTypeAnnotation extends FlowBaseTypeAnnotation {}
|
||||
|
||||
interface ArrayTypeAnnotation extends FlowTypeAnnotation {
|
||||
elementType: FlowTypeAnnotation;
|
||||
}
|
||||
|
||||
interface BooleanLiteralTypeAnnotation extends FlowLiteralTypeAnnotation {}
|
||||
|
||||
interface BooleanTypeAnnotation extends FlowBaseTypeAnnotation {}
|
||||
|
||||
interface ClassImplements extends Node {
|
||||
id: Identifier;
|
||||
typeParameters?: TypeParameterInstantiation;
|
||||
}
|
||||
|
||||
interface ClassProperty {
|
||||
key: Expression;
|
||||
value?: Expression;
|
||||
typeAnnotation?: TypeAnnotation;
|
||||
computed: boolean;
|
||||
static: boolean;
|
||||
}
|
||||
|
||||
interface DeclareClass extends FlowDeclaration {
|
||||
id: Identifier;
|
||||
typeParameters?: TypeParameterDeclaration;
|
||||
body: ObjectTypeAnnotation;
|
||||
extends: Array<InterfaceExtends>;
|
||||
}
|
||||
|
||||
interface DeclareFunction extends FlowDeclaration {
|
||||
id: Identifier;
|
||||
}
|
||||
|
||||
interface DeclareModule extends FlowDeclaration {
|
||||
id: Literal | Identifier;
|
||||
body: BlockStatement;
|
||||
}
|
||||
|
||||
interface DeclareVariable extends FlowDeclaration {
|
||||
id: Identifier;
|
||||
}
|
||||
|
||||
interface FunctionTypeAnnotation extends FlowTypeAnnotation {
|
||||
params: Array<FunctionTypeParam>;
|
||||
returnType: FlowTypeAnnotation;
|
||||
rest?: FunctionTypeParam;
|
||||
typeParameters?: TypeParameterDeclaration;
|
||||
}
|
||||
|
||||
interface FunctionTypeParam {
|
||||
name: Identifier;
|
||||
typeAnnotation: FlowTypeAnnotation;
|
||||
optional: boolean;
|
||||
}
|
||||
|
||||
interface GenericTypeAnnotation extends FlowTypeAnnotation {
|
||||
id: Identifier | QualifiedTypeIdentifier;
|
||||
typeParameters?: TypeParameterInstantiation;
|
||||
}
|
||||
|
||||
interface InterfaceExtends extends Node {
|
||||
id: Identifier | QualifiedTypeIdentifier;
|
||||
typeParameters?: TypeParameterInstantiation;
|
||||
}
|
||||
|
||||
interface InterfaceDeclaration extends FlowDeclaration {
|
||||
id: Identifier;
|
||||
typeParameters?: TypeParameterDeclaration;
|
||||
extends: Array<InterfaceExtends>;
|
||||
body: ObjectTypeAnnotation;
|
||||
}
|
||||
|
||||
interface IntersectionTypeAnnotation extends FlowTypeAnnotation {
|
||||
types: Array<FlowTypeAnnotation>;
|
||||
}
|
||||
|
||||
interface MixedTypeAnnotation extends FlowBaseTypeAnnotation {}
|
||||
|
||||
interface NullableTypeAnnotation extends FlowTypeAnnotation {
|
||||
typeAnnotation: TypeAnnotation;
|
||||
}
|
||||
|
||||
interface NumberLiteralTypeAnnotation extends FlowLiteralTypeAnnotation {}
|
||||
|
||||
interface NumberTypeAnnotation extends FlowBaseTypeAnnotation {}
|
||||
|
||||
interface StringLiteralTypeAnnotation extends FlowLiteralTypeAnnotation {}
|
||||
|
||||
interface StringTypeAnnotation extends FlowBaseTypeAnnotation {}
|
||||
|
||||
interface TupleTypeAnnotation extends FlowTypeAnnotation {
|
||||
types: Array<FlowTypeAnnotation>;
|
||||
}
|
||||
|
||||
interface TypeofTypeAnnotation extends FlowTypeAnnotation {
|
||||
argument: FlowTypeAnnotation;
|
||||
}
|
||||
|
||||
interface TypeAlias extends FlowDeclaration {
|
||||
id: Identifier;
|
||||
typeParameters?: TypeParameterDeclaration;
|
||||
right: FlowTypeAnnotation;
|
||||
}
|
||||
|
||||
interface TypeAnnotation extends Node {
|
||||
typeAnnotation: FlowTypeAnnotation;
|
||||
}
|
||||
|
||||
interface TypeCastExpression extends Expression {
|
||||
expression: Expression;
|
||||
typeAnnotation: TypeAnnotation;
|
||||
}
|
||||
|
||||
interface TypeParameterDeclaration extends Node {
|
||||
params: Array<Identifier>;
|
||||
}
|
||||
|
||||
interface TypeParameterInstantiation extends Node {
|
||||
params: Array<FlowTypeAnnotation>;
|
||||
}
|
||||
|
||||
interface ObjectTypeAnnotation extends FlowTypeAnnotation {
|
||||
properties: Array<ObjectTypeProperty>;
|
||||
indexers: Array<ObjectTypeIndexer>;
|
||||
callProperties: Array<ObjectTypeCallProperty>;
|
||||
}
|
||||
|
||||
interface ObjectTypeCallProperty extends Node {
|
||||
value: FunctionTypeAnnotation;
|
||||
static: boolean;
|
||||
}
|
||||
|
||||
interface ObjectTypeIndexer extends Node {
|
||||
id: Identifier;
|
||||
key: FlowTypeAnnotation;
|
||||
value: FlowTypeAnnotation;
|
||||
static: boolean;
|
||||
}
|
||||
|
||||
interface ObjectTypeProperty extends Node {
|
||||
key: Expression;
|
||||
value: FlowTypeAnnotation;
|
||||
optional: boolean;
|
||||
static: boolean;
|
||||
}
|
||||
|
||||
interface QualifiedTypeIdentifier extends Node {
|
||||
qualification: Identifier | QualifiedTypeIdentifier;
|
||||
id: Identifier;
|
||||
}
|
||||
|
||||
interface UnionTypeAnnotation extends FlowTypeAnnotation {
|
||||
types: Array<FlowTypeAnnotation>;
|
||||
}
|
||||
|
||||
interface VoidTypeAnnotation extends FlowBaseTypeAnnotation {}
|
||||
}
|
||||
Vendored
+14
-12
@@ -4,7 +4,8 @@
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
declare module EventEmitter3 {
|
||||
export class EventEmitter {
|
||||
// __Base is hack for https://github.com/Microsoft/TypeScript/issues/3602
|
||||
class __Base {
|
||||
/**
|
||||
* Minimal EventEmitter interface that is molded against the Node.js
|
||||
* EventEmitter interface.
|
||||
@@ -13,7 +14,7 @@ declare module EventEmitter3 {
|
||||
* @api public
|
||||
*/
|
||||
constructor();
|
||||
|
||||
|
||||
/**
|
||||
* Return a list of assigned event listeners.
|
||||
*
|
||||
@@ -22,7 +23,7 @@ declare module EventEmitter3 {
|
||||
* @api public
|
||||
*/
|
||||
listeners(event: string): Function[];
|
||||
|
||||
|
||||
/**
|
||||
* Emit an event to all registered event listeners.
|
||||
*
|
||||
@@ -31,7 +32,7 @@ declare module EventEmitter3 {
|
||||
* @api public
|
||||
*/
|
||||
emit(event: string, ...args: any[]): boolean;
|
||||
|
||||
|
||||
/**
|
||||
* Register a new EventListener for the given event.
|
||||
*
|
||||
@@ -41,7 +42,7 @@ declare module EventEmitter3 {
|
||||
* @api public
|
||||
*/
|
||||
on(event: string, fn: Function, context?: any): EventEmitter;
|
||||
|
||||
|
||||
/**
|
||||
* Add an EventListener that's only called once.
|
||||
*
|
||||
@@ -51,7 +52,7 @@ declare module EventEmitter3 {
|
||||
* @api public
|
||||
*/
|
||||
once(event: string, fn: Function, context?: any): EventEmitter;
|
||||
|
||||
|
||||
/**
|
||||
* Remove event listeners.
|
||||
*
|
||||
@@ -61,7 +62,7 @@ declare module EventEmitter3 {
|
||||
* @api public
|
||||
*/
|
||||
removeListener(event: string, fn: Function, once?: boolean): EventEmitter;
|
||||
|
||||
|
||||
/**
|
||||
* Remove all listeners or only the listeners for the specified event.
|
||||
*
|
||||
@@ -69,25 +70,26 @@ declare module EventEmitter3 {
|
||||
* @api public
|
||||
*/
|
||||
removeAllListeners(event: string): EventEmitter;
|
||||
|
||||
|
||||
//
|
||||
// Alias methods names because people roll like that.
|
||||
//
|
||||
off(event: string, fn: Function, once?: boolean): EventEmitter;
|
||||
addListener(event: string, fn: Function, context?: any): EventEmitter;
|
||||
|
||||
|
||||
//
|
||||
// This function doesn't apply anymore.
|
||||
//
|
||||
setMaxListeners(): EventEmitter;
|
||||
}
|
||||
export class EventEmitter extends __Base { }
|
||||
export module EventEmitter {
|
||||
//
|
||||
// Expose the module.
|
||||
//
|
||||
export class EventEmitter extends EventEmitter3.EventEmitter {}
|
||||
export class EventEmitter2 extends EventEmitter3.EventEmitter {}
|
||||
export class EventEmitter3 extends EventEmitter3.EventEmitter {}
|
||||
export class EventEmitter extends __Base {}
|
||||
export class EventEmitter2 extends __Base {}
|
||||
export class EventEmitter3 extends __Base {}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
/// <reference path="evernote.d.ts"/>
|
||||
|
||||
import { Evernote } from "evernote";
|
||||
|
||||
var client = new Evernote.Client({ token: "abcdef", sandbox: true });
|
||||
Vendored
+6322
File diff suppressed because it is too large
Load Diff
@@ -103,6 +103,12 @@ function test_throwException() {
|
||||
expect(fn).to.not.throwException();
|
||||
}
|
||||
|
||||
function test_withArgs() {
|
||||
var fn = () => {};
|
||||
expect(fn).withArgs().to.throwException();
|
||||
expect(fn).withArgs(true, 1, '').to.throwException();
|
||||
}
|
||||
|
||||
function test_within() {
|
||||
expect(1).to.be.within(0, Infinity);
|
||||
}
|
||||
|
||||
@@ -101,6 +101,12 @@ function test_throwException() {
|
||||
expect(fn).to.not.throwException();
|
||||
}
|
||||
|
||||
function test_withArgs() {
|
||||
var fn = () => {};
|
||||
expect(fn).withArgs().to.throwException();
|
||||
expect(fn).withArgs(true, 1, '').to.throwException();
|
||||
}
|
||||
|
||||
function test_within() {
|
||||
expect(1).to.be.within(0, Infinity);
|
||||
}
|
||||
|
||||
Vendored
+7
-2
@@ -1,5 +1,5 @@
|
||||
// Type definitions for expect.js 0.2.0
|
||||
// Project: https://github.com/LearnBoost/expect.js
|
||||
// Type definitions for expect.js 0.3.1
|
||||
// Project: https://github.com/Automattic/expect.js
|
||||
// Definitions by: Teppei Sato <https://github.com/teppeis>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
@@ -12,6 +12,11 @@ declare module Expect {
|
||||
*/
|
||||
ok(): void;
|
||||
|
||||
/**
|
||||
* Creates an anonymous function which calls fn with arguments.
|
||||
*/
|
||||
withArgs(...args: any[]): Root;
|
||||
|
||||
/**
|
||||
* Assert that the function throws.
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/// <reference path="express.d.ts" />
|
||||
|
||||
import express = require('express');
|
||||
import * as express from 'express';
|
||||
var app = express();
|
||||
|
||||
app.engine('jade', require('jade').__express);
|
||||
|
||||
Vendored
+5
-3
@@ -5,7 +5,7 @@
|
||||
|
||||
/* =================== USAGE ===================
|
||||
|
||||
import express = require('express');
|
||||
import * as express from "express";
|
||||
var app = express();
|
||||
|
||||
=============================================== */
|
||||
@@ -24,8 +24,8 @@ declare module Express {
|
||||
|
||||
|
||||
declare module "express" {
|
||||
import http = require('http');
|
||||
import serveStatic = require('serve-static');
|
||||
import * as http from "http";
|
||||
import * as serveStatic from "serve-static";
|
||||
|
||||
function e(): e.Express;
|
||||
|
||||
@@ -40,6 +40,7 @@ declare module "express" {
|
||||
delete(...handler: RequestHandler[]): IRoute;
|
||||
patch(...handler: RequestHandler[]): IRoute;
|
||||
options(...handler: RequestHandler[]): IRoute;
|
||||
head(...handler: RequestHandler[]): IRoute;
|
||||
}
|
||||
|
||||
interface IRouterMatcher<T> {
|
||||
@@ -97,6 +98,7 @@ declare module "express" {
|
||||
delete: IRouterMatcher<T>;
|
||||
patch: IRouterMatcher<T>;
|
||||
options: IRouterMatcher<T>;
|
||||
head: IRouterMatcher<T>;
|
||||
|
||||
route(path: string): IRoute;
|
||||
|
||||
|
||||
@@ -70,7 +70,7 @@ function sample2() {
|
||||
//
|
||||
// Rendering canvas #2
|
||||
//
|
||||
var canvas2 = new fabric.Canvas('c2', { backgroundColor: "#000", renderOnAddition: false }),
|
||||
var canvas2 = new fabric.Canvas('c2', { backgroundColor: "#000", renderOnAddRemove: false }),
|
||||
results2 = document.getElementById('results-c2');
|
||||
|
||||
startTimer();
|
||||
@@ -84,7 +84,7 @@ function sample2() {
|
||||
canvas2.add(dot);
|
||||
}
|
||||
canvas2.renderAll(); // Note, calling renderAll() is important in this case
|
||||
results2.innerHTML = 'Rendering 1000 elements using canvas.renderOnAddition = false in ' + stopTimer() + 'ms';
|
||||
results2.innerHTML = 'Rendering 1000 elements using canvas.renderOnAddRemove = false in ' + stopTimer() + 'ms';
|
||||
}
|
||||
|
||||
function sample3() {
|
||||
|
||||
@@ -0,0 +1,88 @@
|
||||
/// <reference path="./famous.d.ts" />
|
||||
|
||||
import { Node, Size, FamousEngine } from 'famous/core'
|
||||
import { DOMElement } from 'famous/dom-renderables'
|
||||
import { PhysicsEngine, Box, RotationalSpring } from 'famous/physics'
|
||||
import { Vec3, Quaternion } from 'famous/math'
|
||||
|
||||
function test_seed() {
|
||||
FamousEngine.init();
|
||||
|
||||
var logo = FamousEngine.createScene().addChild();
|
||||
|
||||
new DOMElement(logo, { tagName: 'img' })
|
||||
.setAttribute('src', './images/famous_logo.png');
|
||||
|
||||
logo
|
||||
.setSizeMode('absolute', 'absolute', 'absolute')
|
||||
.setAbsoluteSize(250, 250)
|
||||
.setAlign(0.5, 0.5)
|
||||
.setMountPoint(0.5, 0.5)
|
||||
.setOrigin(0.5, 0.5);
|
||||
|
||||
var spinner = logo.addComponent({
|
||||
onUpdate: function(time: number) {
|
||||
logo.setRotation(0, time / 1000, 0);
|
||||
logo.requestUpdateOnNextTick(spinner);
|
||||
}
|
||||
});
|
||||
|
||||
logo.requestUpdate(spinner);
|
||||
}
|
||||
|
||||
function test_physics() {
|
||||
let button = new Node()
|
||||
.setSizeMode(Size.ABSOLUTE, Size.ABSOLUTE)
|
||||
.setAbsoluteSize(120, 40)
|
||||
.setAlign(.5, .5)
|
||||
.setMountPoint(.5, .5)
|
||||
.setOrigin(.5, .4);
|
||||
|
||||
button.addUIEvent('mousedown');
|
||||
button.addUIEvent('touchstart');
|
||||
button.addUIEvent('mouseup');
|
||||
button.addUIEvent('touchend');
|
||||
|
||||
let engine = new PhysicsEngine();
|
||||
let box = new Box({
|
||||
mass: .25,
|
||||
size: [1, 1, 1]
|
||||
});
|
||||
engine.add(box);
|
||||
|
||||
let anchor = new Quaternion();
|
||||
let rotationalSpring = new RotationalSpring(null, box, {
|
||||
period: 0.5,
|
||||
dampingRatio: 0.3,
|
||||
anchor: anchor
|
||||
});
|
||||
engine.add(rotationalSpring);
|
||||
|
||||
let started = false;
|
||||
let id = button.addComponent({
|
||||
onUpdate: (time: number) => {
|
||||
engine.update(time);
|
||||
|
||||
if (box.getAngularVelocity().length() < 1e-7) {
|
||||
return;
|
||||
}
|
||||
|
||||
let t = engine.getTransform(box);
|
||||
button.setRotation(t.rotation[0], t.rotation[1], t.rotation[2], t.rotation[3]);
|
||||
|
||||
button.requestUpdateOnNextTick(id);
|
||||
},
|
||||
onReceive: (event: string) => {
|
||||
if (event == 'mousedown' || event == 'touchstart') {
|
||||
anchor.fromEuler(Math.PI, 0, 0);
|
||||
started = true;
|
||||
button.requestUpdate(id);
|
||||
}
|
||||
|
||||
if (event == 'mouseup' || event == 'touchend') {
|
||||
anchor.fromEuler(0, 0, 0);
|
||||
started = false;
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user