diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index bf1115d1da..8dd947b6e0 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -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) @@ -43,6 +44,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam * [: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) @@ -183,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) @@ -202,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) @@ -219,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) @@ -231,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) @@ -243,8 +249,8 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam * [:link:](easy-jsend/easy-jsend.d.ts) [easy-jsend](https://github.com/DeadAlready/easy-jsend) by [Karl Düüna](https://github.com/DeadAlready) * [:link:](easy-session/easy-session.d.ts) [easy-session](https://github.com/DeadAlready/node-easy-session) by [Karl Düüna](https://github.com/DeadAlready) * [:link:](easy-table/easy-table.d.ts) [easy-table](https://github.com/eldargab/easy-table) by [Bart van der Schoor](https://github.com/Bartvds) -* [:link:](easy-x-headers/easy-x-headers.d.ts) [easy-x-headers](https://github.com/DeadAlready/easy-x-headers) by [Karl Düüna](https://github.com/DeadAlready) * [:link:](easy-xapi-supertest/easy-xapi-supertest.d.ts) [easy-x-headers](https://github.com/DeadAlready/easy-x-headers) by [Karl Düüna](https://github.com/DeadAlready) +* [:link:](easy-x-headers/easy-x-headers.d.ts) [easy-x-headers](https://github.com/DeadAlready/easy-x-headers) by [Karl Düüna](https://github.com/DeadAlready) * [:link:](easy-xapi/easy-xapi.d.ts) [easy-xapi](https://github.com/DeadAlready/easy-xapi) by [Karl Düüna](https://github.com/DeadAlready) * [:link:](easystarjs/easystarjs.d.ts) [EasyStar.js](http://easystarjs.com) by [Magnus Gustafsson](https://github.com/borundin) * [:link:](egg.js/egg.js.d.ts) [Egg.js](https://github.com/mikeflynn/egg.js) by [Markus Peloso](https://github.com/ToastHawaii) @@ -274,7 +280,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam * [: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) @@ -305,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) @@ -363,9 +370,9 @@ 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/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:](gsap/Core.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) * [:link:](gulp-concat/gulp-concat.d.ts) [gulp-concat](http://github.com/wearefractal/gulp-concat) by [Keita Kagurazaka](https://github.com/k-kagurazaka) @@ -379,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) @@ -419,15 +427,15 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam * [:link:](html2canvas/html2canvas.d.ts) [html2canvas.js](https://github.com/niklasvh/html2canvas) by [Richard Hepburn](https://github.com/rwhepburn) * [:link:](htmlparser2/htmlparser2.d.ts) [htmlparser2 v3.7.x](https://github.com/fb55/htmlparser2) by [James Roland Cabresos](https://github.com/staticfunction) * [:link:](htmltojsx/htmltojsx.d.ts) [htmltojsx](https://www.npmjs.com/package/htmltojsx) by [Basarat Ali Syed](https://github.com/basarat) -* [:link:](http-errors/http-errors.d.ts) [http-errors](https://github.com/jshttp/http-errors) by [Tanguy Krotoff](https://github.com/tkrotoff) * [:link:](statuses/statuses.d.ts) [http-errors](https://github.com/jshttp/statuses) by [Tanguy Krotoff](https://github.com/tkrotoff) +* [:link:](http-errors/http-errors.d.ts) [http-errors](https://github.com/jshttp/http-errors) by [Tanguy Krotoff](https://github.com/tkrotoff) * [:link:](http-status/http-status.d.ts) [http-status](https://github.com/wdavidw/node-http-status) by [Michael Zabka](https://github.com/misak113) * [:link:](http-string-parser/http-string-parser.d.ts) [http-string-parser](https://github.com/apiaryio/http-string-parser) by [MIZUNE Pine](https://github.com/pine613) * [: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) @@ -472,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) @@ -544,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) @@ -583,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) @@ -672,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) @@ -698,16 +709,16 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam * [:link:](mkdirp/mkdirp.d.ts) [mkdirp](http://github.com/substack/node-mkdirp) by [Bart van der Schoor](https://github.com/Bartvds) * [:link:](mkpath/mkpath.d.ts) [mkpath](https://www.npmjs.com/package/mkpath) by [Jared Klopper](https://github.com/optical) * [:link:](mobile-detect/mobile-detect.d.ts) [mobile-detect](http://hgoebl.github.io/mobile-detect.js) by [Martin McWhorter](https://github.com/martinmcwhorter) -* [:link:](mocha/mocha.d.ts) [mocha](http://mochajs.org) by [Kazi Manzur Rashid](https://github.com/kazimanzurrashid), [otiai10](https://github.com/otiai10), [jt000](https://github.com/jt000), [Vadim Macagon](https://github.com/enlight) * [:link:](mocha/mocha-node.d.ts) [mocha](http://mochajs.org) by [Vadim Macagon](https://github.com/enlight), [vvakame](https://github.com/vvakame) +* [:link:](mocha/mocha.d.ts) [mocha](http://mochajs.org) by [Kazi Manzur Rashid](https://github.com/kazimanzurrashid), [otiai10](https://github.com/otiai10), [jt000](https://github.com/jt000), [Vadim Macagon](https://github.com/enlight) * [:link:](mocha-phantomjs/mocha-phantomjs.d.ts) [mocha-phantomjs](http://metaskills.net/mocha-phantomjs) by [Erik Schierboom](https://github.com/ErikSchierboom) * [:link:](mock-fs/mock-fs.d.ts) [mock-fs](https://github.com/tschaub/mock-fs) by [Wim Looman](https://github.com/Nemo157) * [: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) @@ -781,8 +792,8 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam * [:link:](nopt/nopt.d.ts) [nopt](https://github.com/npm/nopt) by [jbondc](https://github.com/jbondc) * [:link:](notifyjs/notifyjs.d.ts) [notify.js](https://github.com/alexgibson/notify.js) by [soundTricker](https://github.com/soundTricker) * [:link:](notify/notify.d.ts) [Notify.js](https://github.com/jpillora/notifyjs) by [Xiaohan Zhang](https://github.com/hellochar) -* [:link:](nouislider/nouislider.d.ts) [nouislider](https://github.com/leongersen/noUiSlider) by [Corey Jepperson](https://github.com/acoreyj) * [:link:](wnumb/wnumb.d.ts) [nouislider](https://github.com/leongersen/wnumb) by [Corey Jepperson](https://github.com/acoreyj) +* [:link:](nouislider/nouislider.d.ts) [nouislider](https://github.com/leongersen/noUiSlider) by [Corey Jepperson](https://github.com/acoreyj) * [:link:](noVNC/noVNC.d.ts) [noVNC](https://github.com/kanaka/noVNC) by [Ken Smith](https://github.com/smithkl42) * [:link:](npm/npm.d.ts) [npm](https://github.com/npm/npm) by [Maxime LUCE](https://github.com/SomaticIT) * [:link:](nprogress/NProgress.d.ts) [NProgress](https://github.com/rstacruz/nprogress) by [Judah Gabriel Himango](http://debuggerdotbreak.wordpress.com) @@ -807,6 +818,7 @@ This document generated by [dt-contributors-generator](https://github.com/vvakam * [: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) @@ -814,10 +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) @@ -846,7 +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) +* [: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) @@ -878,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) @@ -891,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) @@ -932,7 +948,9 @@ 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) @@ -960,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) @@ -1000,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) @@ -1013,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) @@ -1032,6 +1053,7 @@ 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) @@ -1083,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) @@ -1144,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) diff --git a/PayPal-Cordova-Plugin/PayPal-Cordova-Plugin-test.ts b/PayPal-Cordova-Plugin/PayPal-Cordova-Plugin-test.ts new file mode 100644 index 0000000000..dca1f93120 --- /dev/null +++ b/PayPal-Cordova-Plugin/PayPal-Cordova-Plugin-test.ts @@ -0,0 +1,115 @@ + +/// + +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) => {}); \ No newline at end of file diff --git a/PayPal-Cordova-Plugin/PayPal-Cordova-Plugin.d.ts b/PayPal-Cordova-Plugin/PayPal-Cordova-Plugin.d.ts new file mode 100644 index 0000000000..07c172d558 --- /dev/null +++ b/PayPal-Cordova-Plugin/PayPal-Cordova-Plugin.d.ts @@ -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 +// 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 diff --git a/angular-ui-bootstrap/angular-ui-bootstrap-tests.ts b/angular-ui-bootstrap/angular-ui-bootstrap-tests.ts index 9a5c1cd7c4..efb63d006f 100644 --- a/angular-ui-bootstrap/angular-ui-bootstrap-tests.ts +++ b/angular-ui-bootstrap/angular-ui-bootstrap-tests.ts @@ -31,18 +31,23 @@ 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; - $datepickerConfig.shortcutPropagation = true; + + /** @@ -53,9 +58,12 @@ 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'; /** @@ -72,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; /** @@ -122,6 +134,7 @@ testApp.config(( animation: false, popupDelay: 1000, appendToBody: true, + trigger: 'mouseenter hover', useContentExp: true }); $tooltipProvider.setTriggers({ @@ -148,6 +161,7 @@ testApp.controller('TestCtrl', ( controller: 'ModalTestCtrl', controllerAs: 'vm', keyboard: true, + openedClass: 'modal-open my-modal', resolve: { items: ()=> { return [1, 2, 3, 4, 5]; diff --git a/angular-ui-bootstrap/angular-ui-bootstrap.d.ts b/angular-ui-bootstrap/angular-ui-bootstrap.d.ts index 6ed8be8e3e..1a36d21a2d 100644 --- a/angular-ui-bootstrap/angular-ui-bootstrap.d.ts +++ b/angular-ui-bootstrap/angular-ui-bootstrap.d.ts @@ -1,4 +1,4 @@ -// Type definitions for Angular UI Bootstrap 0.13.2 +// Type definitions for Angular UI Bootstrap 0.13.3 // Project: https://github.com/angular-ui/bootstrap // Definitions by: Brian Surowiec // 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. @@ -122,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. @@ -131,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. * @@ -172,6 +209,13 @@ declare module angular.ui.bootstrap { * @default true */ showButtonBar?: boolean; + + /** + * Whether to focus the datepicker popup upon opening. + * + * @default true + */ + onOpenFocus?: boolean; } @@ -318,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 { @@ -354,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. */ @@ -392,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. * @@ -440,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 { @@ -450,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. * @@ -467,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. * @@ -654,7 +676,7 @@ 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 */ diff --git a/bluebird/bluebird-1.0.d.ts b/bluebird/bluebird-1.0.d.ts index 210032f864..69a4f9152d 100644 --- a/bluebird/bluebird-1.0.d.ts +++ b/bluebird/bluebird-1.0.d.ts @@ -20,8 +20,7 @@ declare class Promise implements Promise.Thenable { /** * 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) => void, reject: (error: any) => void) => void); - constructor(callback: (resolve: (result: R) => void, reject: (error: any) => void) => void); + constructor(callback: (resolve: (thenableOrResult: R | Promise.Thenable) => 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. diff --git a/bluebird/bluebird.d.ts b/bluebird/bluebird.d.ts index cd21d77e92..8876f69817 100644 --- a/bluebird/bluebird.d.ts +++ b/bluebird/bluebird.d.ts @@ -20,8 +20,7 @@ declare class Promise implements Promise.Thenable, Promise.Inspection { /** * 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) => void, reject: (error: any) => void) => void); - constructor(callback: (resolve: (result: R) => void, reject: (error: any) => void) => void); + constructor(callback: (resolve: (thenableOrResult: R | Promise.Thenable) => 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. diff --git a/chance/chance.d.ts b/chance/chance.d.ts index 2af960efec..e79304c8d5 100644 --- a/chance/chance.d.ts +++ b/chance/chance.d.ts @@ -127,7 +127,7 @@ declare module Chance { guid(): string; hash(opts?: Options): string; n(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; diff --git a/cheerio/cheerio.d.ts b/cheerio/cheerio.d.ts index af708cf0a4..fc8e5a70ff 100644 --- a/cheerio/cheerio.d.ts +++ b/cheerio/cheerio.d.ts @@ -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; diff --git a/chrome/chrome.d.ts b/chrome/chrome.d.ts index 41bea3052b..2fc2fb6fc6 100755 --- a/chrome/chrome.d.ts +++ b/chrome/chrome.d.ts @@ -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; } diff --git a/chui/chui-tests.ts b/chui/chui-tests.ts index ce24f36815..98070b4333 100644 --- a/chui/chui-tests.ts +++ b/chui/chui-tests.ts @@ -1,4 +1,4 @@ -/// +/// /// $(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; }); @@ -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", placeholder: "Looking?", results: 10 }); - var carouselPanels = $('li'); + var carouselPanels = $("
  • 1
  • 2
  • 3
  • "); $.UISetupCarousel({target: "#carousel", panels: carouselPanels}); $.UIBindData(); $.UIBindData("#myBoundData"); diff --git a/chui/chui.d.ts b/chui/chui.d.ts index 614b9bb8bb..2f68ae4540 100644 --- a/chui/chui.d.ts +++ b/chui/chui.d.ts @@ -1,14 +1,16 @@ -// Type definitions for chui v3.8.10 +// Type definitions for chui v3.9.0 // Project: https://github.com/chocolatechipui/chocolatechip-ui // Definitions by: Robert Biggs // Definitions: https://github.com/borisyankov/DefinitelyTyped +// ChocolateChip-UI 3.9.0 /** - These TypeScript delcarations for ChocolateChip-UI contain interfaces for both jQuery and ChocolateChipJS. Depending on which library you are using, you will get the type interfaces appropriate for it. + These TypeScript delcarations for ChocolateChip-UI contain interfaces for both ChocolateChipJS and jQuery. Depending on which library you are using, you will get the type interfaces appropriate for it. */ + /** * Interface for ChocolateChipJS. */ -interface ChocolateChipStatic extends ChuiDetectors { +interface ChocolateChipStatic { /** * This method will concatenate strings or values as a cleaner alternative to using the '+' operator. * @@ -16,18 +18,15 @@ interface ChocolateChipStatic extends ChuiDetectors { * @return string */ concat(...string: string[]): string; - - + /** - * This function replicates normal array iteration with the context first, followed by the index. - * Usage: $.forEach([1,2,3], function(ctx, idx) { console.log(ctx + "is: " + (idx + 1)) }); - * - * @param obj An array-like object. This will usually be an array of HTML elements. - * @param callback A callback to execute with each iteration of the object. - * @param args Any extra arguments you wish to pass. - * @return void + * The method will iterate over an array. + * + * @param obj An iterable object. + * @param callback A callback to execute on each loop. + * @param args Any arguments you need to pass to the callback. */ - forEach(obj: T[], callback: (ctx: T, idx?: number) => any, args?: any): any; + forEach(obj: Array, callback: Function, args?: any): any; /** * Alias for cross-platform events: pointerdown, MSPointerDown, touchstart and mousedown. @@ -49,21 +48,39 @@ interface ChocolateChipStatic extends ChuiDetectors { */ eventCancel: ChUIEventInterface; + /** + * Whether browser is Microsoft Edge or not. + */ + isIEEdge: boolean; + + /** + * Whether screen is at least 960 pixels wide. + */ + isWideScreen: boolean; + + /** + * Whether screen is at least 960 pixels wide and in portrait orientation. + */ + isWideScreenPortrait: boolean; /** * Return the version of the current browser. * - * @return string The current browser version. + * @return number Returns the current browser's version. */ browserVersion(): number; /** * Hide the navigation bar, raising up the content below it. + * + * @return void */ UIHideNavBar(): void; /** * If the navigation bar is hidden, show it, pushing down the content to make room. + * + * @return void */ UIShowNavBar(): void; @@ -76,11 +93,14 @@ interface ChocolateChipStatic extends ChuiDetectors { * Navigate to the article indicated by the provided destination ID. This enters the destination into the navigation history array. * * param destination An id for the article to navigate to. + * @return void */ UIGoToArticle(destination: string): void; /** * Go back to the previous article from whence you came. This resets the navigation history array. + * + * @return void */ UIGoBack(): void; @@ -90,14 +110,17 @@ interface ChocolateChipStatic extends ChuiDetectors { UIGoBackToArticle(articleID: string): void; /** - * Display a transparent screen over the UI. This takes an optional, decimal-based number for opacity: .5 for 50%. + * Display a transparent screen over the UI. * * @param opacity The percentage of opacity for the screen. + * @return void */ UIBlock(opacity?: number): void; /** * Remove the transparent screen covering the UI. + * + * @return void */ UIUnblock(): void; @@ -107,17 +130,32 @@ interface ChocolateChipStatic extends ChuiDetectors { * * param options UIPopupOptions */ - UIPopup(options: UIPopupOptions): void; + UIPopup(options?: { + id?: string; + title?: string; + message?: string; + cancelButton?: string; + continueButton?: string; + callback?: Function; + empty?: boolean; + }): void; /** * Create and show a Popover. Options: {id: "#myPopover", title: "Whatever", callback: function() {console.log('Blah!');}}. * * param options UIPopoverOptions + * @return void */ - UIPopover(options: UIPopoverOptions): void; + UIPopover(options?: { + id?: string; + callback?: Function; + title?: string; + }): void; /** * Close any currently visible popovers. + * + * @return void */ UIPopoverClose(): void; @@ -126,26 +164,44 @@ interface ChocolateChipStatic extends ChuiDetectors { * * param: options UICreateSegmentedOptions */ - UICreateSegmented(options: UICreateSegmentedOptions): ChocolateChipElementArray; + UICreateSegmented(options?: { + id?: string; + className?: string; + labels?: string[]; + selected?: number + }): ChocolateChipElementArray; /** * Initialize a horiontal or vertical paging control. This uses a segmented control in the navigation bar with a class * like "segmented paging horizontal" or "segmented paging vertical". It uses a single article with multiple sections to paginate. + * + * @return void */ UIPaging(): void; /** * Creates a sheet. Minimum option is an id: {id : 'starTrek', listClass :'enterprise', background: 'transparent', handle: false } + * + * @return void */ - UISheet(options: UISheetOptions): void; + UISheet(options: { + id: string; + listClass?: string; + background?: string; + handle?: boolean; + }): void; /** * Show a sheet by passing this its ID. + * + * @return void */ - UIShowSheet(id?: string): void; + UIShowSheet(id: string): void; /** * Hide any currently displayed sheets. + * + * @return void */ UIHideSheet(): void; @@ -162,41 +218,91 @@ interface ChocolateChipStatic extends ChuiDetectors { /** * Creates and initializes a slide out menu. Possible options: {dynamic: true, callback: function() { alert("Woohoo!");}} */ - UISlideout: UISlideoutInterface; + UISlideout: { + /** + * Creates and initializes a slide out menu. Possible options: {dynamic: true, callback: function() { alert("Woohoo!");}} + * + * @return void + */ + (options?: { + dynamic?: boolean; + callback?: (args?: any) => any; + }): any; + + /** + * Populates a slideout menu. + * + * @return void + */ + populate(array: Object[]): void; + }; /** - * Reset the value of the stepper to its defaults at initialization. Pass it a reference to the stepper to reset. It takes a stepper element: $("#myStepper"). - * - * @param stepper A stepper to reset. + * Reset the value of the stepper to its defaults at initialization. Pass it a reference to the stepper to reset. + * + * @return void */ - UIResetStepper(stepper: ChocolateChipElementArray): void; + UIResetStepper(stepper: HTMLElement[]): void; /** * Create a switch control. Possible options: { id: '#myId', name: 'fruit.mango', state: 'on', value: 'Mango', checked: 'on', style: 'traditional', callback: function() { alert('hi');}} + * + * @return void */ - UICreateSwitch(options: UICreateSwitchOptions): void; + UICreateSwitch(options?: { + id?: string; + name?: string; + state?: string; + value?: string | number; + checked?: string; + style?: string; + callback?: () => any; + }): void; /** * Creates a tabbar. On iOS this is at the bottom of the screen. On Android and Windows, it is at the top. * Options: {id: 'mySpecialTabbar', tabs: 4, labels: ["Refresh", "Add", "Info", "Downloads", "Favorite"], icons: ["refresh", "add", "info", "downloads", "favorite"], selected: 2 } + * + * @return void */ - UITabbar(options: UITabbarOptions): void; + UITabbar(options?: { + id?: string; + tabs: number; + labels: string[]; + icons?: string[]; + selected?: number; + }): void; /** * Create a search bar for an article. Options: { articleId: '#products', id: 'productSearch', placeholder: 'Find a product', results: 5 } + * + * @return void */ - UISearch(options: UISearchOptions): void; + UISearch(options?: { + articleId?: any; + id?: string; + placeholder?: string; + results?: number; + }): void; /** * Create and initialize a swipable carousel. Options: {target : '#myCarousel', panels: ['

    stuff

    ','

    more

    '], loop: true, pagination: true } + * + * @return void */ - UISetupCarousel(options: UISetupCarouselOptions): void; + UISetupCarousel(options: { + target: any; + panels: ChocolateChipElementArray; + loop?: boolean; + pagination?: boolean; + }): void; /** * Bind the values of data-models to elements with data-controllers:

    . * You can bind a single model to its controller by providing its name as the argument: $.UIBindData('input-value'); * * @param controller A string indicating the controller whose value a model is bound to. + * @return void */ UIBindData(controller?: string): void; @@ -205,18 +311,21 @@ interface ChocolateChipStatic extends ChuiDetectors { * If you provide a controller name as the argument, only that controller will be unbound. * * @param controller A controller to unbind. + * @return void */ UIUnBindData(controller?: string): void; } /** - * Interface for ChocolateChipJS Element Array. + * Interface for ChocolateChipJS HTMLElement Array. */ interface ChocolateChipElementArray { /** * Iterate over an Array object, executing a function for each matched element. + * + * @return void */ forEach(func: (ctx: any, idx: number) => void): void; @@ -226,6 +335,7 @@ interface ChocolateChipElementArray { * if it matches the given arguments. * * @param selector A string containing a selector expression to match elements against. + * @return HTMLElement[] */ iz(selector: string): ChocolateChipElementArray; @@ -234,6 +344,7 @@ interface ChocolateChipElementArray { * if it matches the given arguments. * * @param elements One or more elements to match the current set of elements against. + * @return HTMLElement[] */ iz(element: any): ChocolateChipElementArray; @@ -242,6 +353,7 @@ interface ChocolateChipElementArray { * if it does not match the given arguments. * * @param selector A string containing a selector expression to match elements against. + * @return HTMLElement[] */ iznt(selector: string): ChocolateChipElementArray; @@ -250,6 +362,7 @@ interface ChocolateChipElementArray { * if it does not match the given arguments. * * @param elements One or more elements to match the current set of elements against. + * @return HTMLElement[] */ iznt(element: any): ChocolateChipElementArray; @@ -257,32 +370,37 @@ interface ChocolateChipElementArray { * Reduce the set of matched elements to those that have a descendant that matches the selector or DOM element. * * @param selector A string containing a selector expression to match elements against. + * @return HTMLElement[] */ haz(selector: string): ChocolateChipElementArray; /** * Reduce the set of matched elements to those that have a descendant that matches the selector or DOM element. * - * @param element A DOM element to match elements against. + * @param contained A DOM element to match elements against. + * @return HTMLElement[] */ - haz(element: Element): ChocolateChipElementArray; + haz(contained: HTMLElement): ChocolateChipElementArray; /** * Reduce the set of matched elements to those that have a descendant that does not match the selector or DOM element. * * @param selector A string containing a selector expression to match elements against. + * @return HTMLElement[] */ haznt(selector: string): ChocolateChipElementArray; /** * Reduce the set of matched elements to those that have a descendant that does not match the selector or DOM element. * - * @param element A DOM element to match elements against. + * @param contained A DOM element to match elements against. + * @return HTMLElement[] */ - haznt(element: Element): ChocolateChipElementArray; + haznt(contained: HTMLElement): ChocolateChipElementArray; /** * Return any of the matched elements that have the given class. * * @param className The class name to search for. + * @return HTMLElement[] */ hazClass(className: string): ChocolateChipElementArray; @@ -290,6 +408,7 @@ interface ChocolateChipElementArray { * Return any of the matched elements that do not have the given class. * * @param className The class name to search for. + * @return HTMLElement[] */ hazntClass(className: string): ChocolateChipElementArray; @@ -298,6 +417,7 @@ interface ChocolateChipElementArray { * Return any of the matched elements that have the given attribute. * * @param className The class name to search for. + * @return HTMLElement[] */ hazAttr(attributeName: string): ChocolateChipElementArray; @@ -305,6 +425,7 @@ interface ChocolateChipElementArray { * Return any of the matched elements that do not have the given attribute. * * @param className The class name to search for. + * @return HTMLElement[] */ hazntAttr(attributeName: string): ChocolateChipElementArray; @@ -314,6 +435,7 @@ interface ChocolateChipElementArray { * @param eventType A string containing one or more DOM event types, such as "click" or "submit," or custom event names. * @param handler A function to execute each time the event is triggered. * @param useCapture Setting the third argument to true will trigger event bubbling. The default is false. + * @return ChocolateChipStatic */ bind(eventType: string | ChUIEventInterface, handler: (eventObject: Event) => any, useCapture?: boolean): ChocolateChipStatic; @@ -323,8 +445,9 @@ interface ChocolateChipElementArray { * @param eventType A string containing one or more DOM event types, such as "click" or "submit," or custom event names. * @param handler A function to execute each time the event is triggered. * @param useCapture Setting the third argument to true will trigger event bubbling. The default is false. + * @return ChocolateChipStatic */ - unbind(eventType: string | ChUIEventInterface, handler?: (eventObject: Event) => any, useCapture?: boolean): ChocolateChipStatic; + unbind(eventType: string | ChUIEventInterface, handler: (eventObject: Event) => any, useCapture?: boolean): ChocolateChipStatic; /** * Add a delegated event to listen for the provided event on the descendant elements. @@ -334,6 +457,7 @@ interface ChocolateChipElementArray { * @param handler A function to execute each time the event is triggered. The keyword "this" will refer * to the element receiving the event. * @param useCapture Setting the third argument to true will trigger event bubbling. The default is false. + * @return ChocolateChipStatic */ delegate(selector: any, eventType: string | ChUIEventInterface, handler: (eventObject: Event) => any, useCapture?: boolean): ChocolateChipStatic; @@ -344,6 +468,7 @@ interface ChocolateChipElementArray { * @param eventType A string containing one or more DOM event types, such as "click" or "submit," or custom event names. * @param handler A function handler assigned to this event. * @param useCapture Setting the third argument to true will trigger event bubbling. The default is false. + * @return ChocolateChipStatic */ undelegate(selector: any, eventType: string | ChUIEventInterface, handler: (eventObject: Event) => any, useCapture?: boolean): ChocolateChipStatic; @@ -354,6 +479,7 @@ interface ChocolateChipElementArray { * @param selector A string defining the descendant elements are listening for the event. * @param handler A function handler assigned to this event. * @param useCapture Setting the third argument to true will trigger event bubbling. The default is false. + * @return ChocolateChipStatic */ on( eventType: string | ChUIEventInterface, selector: any, handler?: (eventObject: Event) => any, capturePhase?: boolean): ChocolateChipStatic; @@ -365,6 +491,7 @@ interface ChocolateChipElementArray { * @param selector A string defining the descendant elements are listening for the event. * @param handler A function handler assigned to this event. * @param useCapture Setting the third argument to true will trigger event bubbling. The default is false. + * @return ChocolateChipStatic */ off( eventType?: string | ChUIEventInterface, selector?: any, handler?: (eventObject: Event) => any, capturePhase?: boolean): ChocolateChipStatic; @@ -385,49 +512,89 @@ interface ChocolateChipElementArray { * @param color The color for the busy indicator: "#ff0000". * @param position Optional positioning, such as "align-flush". * @param duration The time for the busy indicator to display: "500ms". + * @return void */ - UIBusy(options: UIBusyOptions): void; + UIBusy(options?: { + size?: string; + color?: string; + position?: string | boolean; + duration?: string; + }): void; /** * Close the currently displayed Popup. This is executed on the popup: $('#myPopup').UIPopupClose(). + * + * @return void */ UIPopupClose(): void; /** * Initialize a segmented control. Options: {selected: 2, callback: function() {console.log('Blah');}} + * + * @return void */ - UISegmented(options: UISegmentedOptions): void; + UISegmented(options?: { + selected?: number; + callback?: Function; + }): void; /** * This method allows the user to use a segmented control to toggle a set of panels. It is executed on the segmented control. * The options id is the contain of the panels. The options callback is to execute when the user toggles a panel. + * + * @return void */ UIPanelToggle(panelsContainer: string, callback: () => any): void; /** * Make a list editable. This can be enabling changing the order of list items, or deleting them, or both. Options: {editLabel: "Edit", doneLabel: "Done", * deleteLabel: "Delete", callback: function() {alert('Bye bye!');}, deletable: true, movable: true}. + * + * @return void */ - UIEditList(options: UIEditListOptions): void; + UIEditList(options?: { + editLabel?: string; + doneLabel?: string; + deleteLabel?: string; + callback?: Function; + deletable?: boolean; + movable?: boolean; + }): void; /** * Convert a simple list into a selection list. This converts the list into a radio button group, meaning only one can be selected at any time. * You can name the radios buttons using the options name. Options: {name: "selectedNamesGroup", selected: 2, callback: function() {alert('hi');}} + * + * @return void */ - UISelectList(): void; + UISelectList(options?: { + name?: string; + selected?: number; + callback?: Function; + }): void; /** * Create a stepper control by executing it on a span with the class "stepper". Possible options: {start: 0, end: 10, defaultValue: 3}. + * + * @return void */ - UIStepper(options: UIStepperOptions): void; + UIStepper(options: { + start: number; + end: number; + defaultValue: number; + }): void; /** * Initialize any existing switch controls: $('.switch').UISwitch(); + * + * @return void */ UISwitch(): void; /** * Execute this on a range control to initialize it. + * + * @return void */ UIRange(): void; } @@ -435,8 +602,7 @@ interface ChocolateChipElementArray { /** * Interface for jQuery */ - -interface JQueryStatic extends ChuiDetectors { +interface JQueryStatic { /** * This method will concatenate strings or values as a cleaner alternative to using the '+' operator. * @@ -444,17 +610,15 @@ interface JQueryStatic extends ChuiDetectors { * @return string */ concat(...string: string[]): string; - + /** - * This function replicates normal array iteration with the context first, followed by the index. - * Usage: $.forEach([1,2,3], function(ctx, idx) { console.log(ctx + "is: " + (idx + 1)) }); - * - * @param obj An array-like object. This will usually be an array of HTML elements. - * @param callback A callback to execute with each iteration of the object. - * @param args Any extra arguments you wish to pass. - * @return void + * The method will iterate over an array. + * + * @param obj An iterable object. + * @param callback A callback to execute on each loop. + * @param args Any arguments you need to pass to the callback. */ - forEach(obj: T[], callback: (ctx: T, idx?: number) => any, args?: any): any; + forEach(obj: Array, callback: Function, args?: any): any; /** * Alias for cross-platform events: pointerdown, MSPointerDown, touchstart and mousedown. @@ -476,660 +640,6 @@ interface JQueryStatic extends ChuiDetectors { */ eventCancel: ChUIEventInterface; - /** - * Return the version of the current browser. - */ - browserVersion(): number; - - /** - * Hide the navigation bar, raising up the content below it. - */ - UIHideNavBar(): void; - - /** - * If the navigation bar is hidden, show it, pushing down the content to make room. - */ - UIShowNavBar(): void; - - /** - * Determine whether navigation is in progress or not. - */ - isNavigating: boolean; - - /** - * Navigate to the article indicated by the provided destination ID. This enters the destination into the navigation history array. - * - * param destination An id for the article to navigate to. - */ - UIGoToArticle(destination: string): void; - - /** - * Go back to the previous article from whence you came. This resets the navigation history array. - */ - UIGoBack(): void; - - /** - * Go back to the article indicated by the provided ID. This is for non-linear back navigation. This will reset the navigation history array to match the current state. - */ - UIGoBackToArticle(articleID: string): void; - - /** - * Display a transparent screen over the UI. This takes an optional, decimal-based number for opacity: .5 for 50%. - * - * @param opacity The percentage of opacity for the screen. - */ - UIBlock(opacity?: number): void; - - /** - * Remove the transparent screen covering the UI. - */ - UIUnblock(): void; - - /** - * Create and show a Popup with title and message. Possible options: {id: "#myPopup", title: "My Popup", - * message: "Woohoo!", cancelButton: "Forget It!", contiueButton: "Whatever", callback: function() {console.log('Blah!');}, empty: false }. - * - * param options UIPopupOptions - */ - UIPopup(options: UIPopupOptions): void; - - /** - * Create and show a Popover. Options: {id: "#myPopover", title: "Whatever", callback: function() {console.log('Blah!');}}. - * - * param options UIPopoverOptions - */ - UIPopover(options: UIPopoverOptions): void; - - /** - * Close any currently visible popovers. - */ - UIPopoverClose(): void; - - /** - * Create a segmented control: {id: "mySegments", className: "seggie", labels: ["one", "two","three"], selected: 1} - * - * param: options UICreateSegmentedOptions - */ - UICreateSegmented(options: UICreateSegmentedOptions): JQuery; - - /** - * Initialize a horiontal or vertical paging control. This uses a segmented control in the navigation bar with a class - * like "segmented paging horizontal" or "segmented paging vertical". It uses a single article with multiple sections to paginate. - */ - UIPaging(): void; - - /** - * Creates a sheet. Minimum option is an id: {id : 'starTrek', listClass :'enterprise', background: 'transparent', handle: false } - */ - UISheet(options: UISheetOptions): void; - - /** - * Show a sheet by passing this its ID. - */ - UIShowSheet(id: string): void; - - /** - * Hide any currently displayed sheets. - */ - UIHideSheet(): void; - - /** - * The body tag wrapped and ready to use: $.body.css('background-color','orange') - */ - body: JQuery; - - /** - * An array of the navigation history. Do not manipulate this. For examination only. This is used by navigation lists, etc. - */ - UINavigationHistory: string[]; - - /** - * Creates and initializes a slide out menu. Possible options: {dynamic: true, callback: function() { alert("Woohoo!");}} - */ - UISlideout: UISlideoutInterface; - - /** - * Reset the value of the stepper to its defaults at initialization. Pass it a reference to the stepper to reset. - */ - UIResetStepper(stepper: JQuery): void; - - /** - * Create a switch control. Possible options: { id: '#myId', name: 'fruit.mango', state: 'on', value: 'Mango', checked: 'on', style: 'traditional', callback: function() { alert('hi');}} - */ - UICreateSwitch(options: UICreateSwitchOptions): void; - - /** - * Creates a tabbar. On iOS this is at the bottom of the screen. On Android and Windows, it is at the top. - * Options: {id: 'mySpecialTabbar', tabs: 4, labels: ["Refresh", "Add", "Info", "Downloads", "Favorite"], icons: ["refresh", "add", "info", "downloads", "favorite"], selected: 2 } - */ - UITabbar(options: UITabbarOptions): void; - - /** - * Create a search bar for an article. Options: { articleId: '#products', id: 'productSearch', placeholder: 'Find a product', results: 5 } - */ - UISearch(options: UISearchOptions): void; - - /** - * Create and initialize a swipable carousel. Options: {target : '#myCarousel', panels: ['

    stuff

    ','

    more

    '], loop: true, pagination: true } - */ - UISetupCarousel(options: UISetupCarouselOptions): void; - - /** - * Bind the values of data-models to elements with data-controllers:

    . - * You can bind a single model to its controller by providing its name as the argument: $.UIBindData('input-value'); - * - * @param controller A string indicating the controller whose value a model is bound to. - */ - UIBindData(controller?: string): void; - - /** - * Unbind the values of data-models from their data-controllers. - * If you provide a controller name as the argument, only that controller will be unbound. - * - * @param controller A controller to unbind. - */ - UIUnBindData(controller?: string): void; - -} - -/** - * Interface for jQuery - */ -interface JQuery { - - /** - * Iterate over an Array object, executing a function for each matched element. - */ - //forEach(func: (ctx: any, idx: number) => void, JQuery: any): void; - forEach(callback: (ctx: Element, idx: number) => any): JQuery; - - /** - * Check the current matched set of elements against a selector or element and return it - * if it matches the given arguments. - * - * @param selector A string containing a selector expression to match elements against. - */ - iz(selector: string): JQuery; - - /** - * Check the current matched set of elements against a selector or element and return it - * if it matches the given arguments. - * - * @param elements One or more elements to match the current set of elements against. - */ - iz(element: any): JQuery; - - /** - * Check the current matched set of elements against a selector or element and return it - * if it does not match the given arguments. - * - * @param selector A string containing a selector expression to match elements against. - */ - iznt(selector: string): JQuery; - - /** - * Check the current matched set of elements against a selector or element and return it - * if it does not match the given arguments. - * - * @param elements One or more elements to match the current set of elements against. - */ - iznt(element: any): JQuery; - - /** - * Reduce the set of matched elements to those that have a descendant that matches the selector or DOM element. - * - * @param selector A string containing a selector expression to match elements against. - */ - haz(selector: string): JQuery; - /** - * Reduce the set of matched elements to those that have a descendant that matches the selector or DOM element. - * - * @param contained A DOM element to match elements against. - */ - haz(contained: Element): JQuery; - - /** - * Reduce the set of matched elements to those that have a descendant that does not match the selector or DOM element. - * - * @param selector A string containing a selector expression to match elements against. - */ - haznt(selector: string): JQuery; - /** - * Reduce the set of matched elements to those that have a descendant that does not match the selector or DOM element. - * - * @param contained A DOM element to match elements against. - */ - haznt(contained: Element): JQuery; - - /** - * Return any of the matched elements that have the given class. - * - * @param className The class name to search for. - */ - hazClass(className: string): JQuery; - - /** - * Return any of the matched elements that do not have the given class. - * - * @param className The class name to search for. - */ - hazntClass(className: string): JQuery; - - - /** - * Return any of the matched elements that have the given attribute. - * - * @param className The class name to search for. - */ - hazAttr(attributeName: string): JQuery; - - /** - * Return any of the matched elements that do not have the given attribute. - * - * @param className The class name to search for. - */ - hazntAttr(attributeName: string): JQuery; - - /** - * Center an element to the screen. - */ - UICenter(): void; - - /** - * Display a busy indicator. Posible options: {size: "100px", color: "#ff0000", position: "align-flush", duration: "2s"}. - * - * @param size The size as a string with length identifier: "40px". - * @param color The color for the busy indicator: "#ff0000". - * @param position Optional positioning, such as "align-flush". - * @param duration The time for the busy indicator to display: "500ms". - */ - UIBusy(options: UIBusyOptions): void; - - /** - * Close the currently displayed Popup. This is executed on the popup: $('#myPopup').UIPopupClose(). - */ - UIPopupClose(): void; - - /** - * Initialize a segmented control. Options: {selected: 2, callback: function() {console.log('Blah');}} - */ - UISegmented(options: UISegmentedOptions): void; - - /** - * This method allows the user to use a segmented control to toggle a set of panels. It is executed on the segmented control. - * The options id is the contain of the panels. The options callback is to execute when the user toggles a panel. - */ - UIPanelToggle(panelsContainer: string, callback: () => any): void; - - /** - * Make a list editable. This can be enabling changing the order of list items, or deleting them, or both. Options: {editLabel: "Edit", doneLabel: "Done", - * deleteLabel: "Delete", callback: function() {alert('Bye bye!');}, deletable: true, movable: true}. - */ - UIEditList(options: UIEditListOptions): void; - - /** - * Convert a simple list into a selection list. This converts the list into a radio button group, meaning only one can be selected at any time. - * You can name the radios buttons using the options name. Options: {name: "selectedNamesGroup", selected: 2, callback: function() {alert('hi');}} - */ - UISelectList(): void; - - /** - * Create a stepper control by executing it on a span with the class "stepper". Possible options: {start: 0, end: 10, defaultValue: 3}. - */ - UIStepper(options: UIStepperOptions): void; - - /** - * Initialize any existing switch controls: $('.switch').UISwitch(); - */ - UISwitch(): void; - - /** - * Execute this on a range control to initialize it. - */ - UIRange(): void; - - - /** - * Attach a handler to an event for the elements. - * - * @param eventType A string containing one or more DOM event types, such as "click" or "submit," or custom event names. - * @param eventData An object containing data that will be passed to the event handler. - * @param handler A function to execute each time the event is triggered. - */ - bind(eventType: string | ChUIEventInterface, eventData: any, handler: (eventObject: JQueryEventObject) => any): JQuery; - /** - * Attach a handler to an event for the elements. - * - * @param eventType A string containing one or more DOM event types, such as "click" or "submit," or custom event names. - * @param handler A function to execute each time the event is triggered. - */ - bind(eventType: string | ChUIEventInterface, handler: (eventObject: JQueryEventObject) => any): JQuery; - /** - * Attach a handler to an event for the elements. - * - * @param eventType A string containing one or more DOM event types, such as "click" or "submit," or custom event names. - * @param eventData An object containing data that will be passed to the event handler. - * @param preventBubble Setting the third argument to false will attach a function that prevents the default action from occurring and stops the event from bubbling. The default is true. - */ - bind(eventType: string | ChUIEventInterface, eventData: any, preventBubble: boolean): JQuery; - /** - * Attach a handler to an event for the elements. - * - * @param eventType A string containing one or more DOM event types, such as "click" or "submit," or custom event names. - * @param preventBubble Setting the third argument to false will attach a function that prevents the default action from occurring and stops the event from bubbling. The default is true. - */ - bind(eventType: string | ChUIEventInterface, preventBubble: boolean): JQuery; - - - delegate(selector: any, eventType: string | ChUIEventInterface, handler: (eventObject: JQueryEventObject) => any): JQuery; - delegate(selector: any, eventType: string | ChUIEventInterface, eventData: any, handler: (eventObject: JQueryEventObject) => any): JQuery; - - /** - * Remove an event handler. - * - * @param events One or more space-separated event types and optional namespaces, or just namespaces, such as "click", "keydown.myPlugin", or ".myPlugin". - * @param selector A selector which should match the one originally passed to .on() when attaching event handlers. - * @param handler A handler function previously attached for the event(s), or the special value false. - */ - off(events: string | ChUIEventInterface, selector?: string, handler?: (eventObject: JQueryEventObject) => any): JQuery; - /** - * Remove an event handler. - * - * @param events One or more space-separated event types and optional namespaces, or just namespaces, such as "click", "keydown.myPlugin", or ".myPlugin". - * @param handler A handler function previously attached for the event(s), or the special value false. - */ - off(events: string | ChUIEventInterface, handler: (eventObject: JQueryEventObject) => any): JQuery; - - /** - * Attach an event handler function for one or more events to the selected elements. - * - * @param events One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". - * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. Rest parameter args is for optional parameters passed to jQuery.trigger(). Note that the actual parameters on the event handler function must be marked as optional (? syntax). - */ - on(events: string | ChUIEventInterface, handler: (eventObject: JQueryEventObject, ...args: any[]) => any): JQuery; - /** - * Attach an event handler function for one or more events to the selected elements. - * - * @param events One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". - * @param data Data to be passed to the handler in event.data when an event is triggered. - * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. - */ - on(events: string | ChUIEventInterface, data : any, handler: (eventObject: JQueryEventObject, ...args: any[]) => any): JQuery; - /** - * Attach an event handler function for one or more events to the selected elements. - * - * @param events One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". - * @param selector A selector string to filter the descendants of the selected elements that trigger the event. If the selector is null or omitted, the event is always triggered when it reaches the selected element. - * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. - */ - on(events: string | ChUIEventInterface, selector: string, handler: (eventObject: JQueryEventObject, ...eventData: any[]) => any): JQuery; - /** - * Attach an event handler function for one or more events to the selected elements. - * - * @param events One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". - * @param selector A selector string to filter the descendants of the selected elements that trigger the event. If the selector is null or omitted, the event is always triggered when it reaches the selected element. - * @param data Data to be passed to the handler in event.data when an event is triggered. - * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. - */ - on(events: string | ChUIEventInterface, selector: string, data: any, handler: (eventObject: JQueryEventObject, ...eventData: any[]) => any): JQuery; - - /** - * Attach a handler to an event for the elements. The handler is executed at most once per element per event type. - * - * @param events A string containing one or more JavaScript event types, such as "click" or "submit," or custom event names. - * @param handler A function to execute at the time the event is triggered. - */ - one(events: string | ChUIEventInterface, handler: (eventObject: JQueryEventObject) => any): JQuery; - /** - * Attach a handler to an event for the elements. The handler is executed at most once per element per event type. - * - * @param events A string containing one or more JavaScript event types, such as "click" or "submit," or custom event names. - * @param data An object containing data that will be passed to the event handler. - * @param handler A function to execute at the time the event is triggered. - */ - one(events: string | ChUIEventInterface, data: Object, handler: (eventObject: JQueryEventObject) => any): JQuery; - - /** - * Attach a handler to an event for the elements. The handler is executed at most once per element per event type. - * - * @param events One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". - * @param selector A selector string to filter the descendants of the selected elements that trigger the event. If the selector is null or omitted, the event is always triggered when it reaches the selected element. - * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. - */ - one(events: string | ChUIEventInterface, selector: string, handler: (eventObject: JQueryEventObject) => any): JQuery; - /** - * Attach a handler to an event for the elements. The handler is executed at most once per element per event type. - * - * @param events One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". - * @param selector A selector string to filter the descendants of the selected elements that trigger the event. If the selector is null or omitted, the event is always triggered when it reaches the selected element. - * @param data Data to be passed to the handler in event.data when an event is triggered. - * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. - */ - one(events: string | ChUIEventInterface, selector: string, data: any, handler: (eventObject: JQueryEventObject) => any): JQuery; - - /** - * Execute all handlers and behaviors attached to the matched elements for the given event type. - * - * @param eventType A string containing a JavaScript event type, such as click or submit. - * @param extraParameters Additional parameters to pass along to the event handler. - */ - trigger(eventType: string | ChUIEventInterface, extraParameters?: any[]|Object): JQuery; - - /** - * Execute all handlers attached to an element for an event. - * - * @param eventType A string containing a JavaScript event type, such as click or submit. - * @param extraParameters An array of additional parameters to pass along to the event handler. - */ - triggerHandler(eventType: string | ChUIEventInterface, ...extraParameters: any[]): Object; - - /** - * Remove a previously-attached event handler from the elements. - * - * @param eventType A string containing a JavaScript event type, such as click or submit. - * @param handler The function that is to be no longer executed. - */ - unbind(eventType?: string | ChUIEventInterface, handler?: (eventObject: JQueryEventObject) => any): JQuery; - /** - * Remove a previously-attached event handler from the elements. - * - * @param eventType A string containing a JavaScript event type, such as click or submit. - * @param fls Unbinds the corresponding 'return false' function that was bound using .bind( eventType, false ). - */ - unbind(eventType: string | ChUIEventInterface, fls: boolean): JQuery; - - /** - * Remove a handler from the event for all elements which match the current selector, based upon a specific set of root elements. - * - * @param selector A selector which will be used to filter the event results. - * @param eventType A string containing a JavaScript event type, such as "click" or "keydown" - * @param handler A function to execute at the time the event is triggered. - */ - undelegate(selector: string | ChUIEventInterface, eventType: string, handler?: (eventObject: JQueryEventObject) => any): JQuery; - /** - * Remove a handler from the event for all elements which match the current selector, based upon a specific set of root elements. - * - * @param selector A selector which will be used to filter the event results. - * @param events An object of one or more event types and previously bound functions to unbind from them. - */ - undelegate(selector: string | ChUIEventInterface, events: Object): JQuery; -} - -interface UISetupCarouselOptions { - target: string; - panels: HTMLElement[] | JQuery; - loop?: boolean; - pagination?: boolean; -} - -interface UISearchOptions { - articleId?: string; - id?: string; - placeholder?: string; - results?: number; -} - -interface UITabbarOptions { - id?: string; - tabs: number; - labels: string[]; - icons?: string[]; - selected?: number; -} - -interface UICreateSwitchOptions { - id?: string; - name?: string; - state?: string; - value?: string | number; - checked?: string; - style?: string; - callback?: () => any; -} - -/** - * Interface for UISlideout. - */ -interface UISlideoutInterface { - /** - * Creates and initializes a slide out menu. Possible options: {dynamic: true, callback: function() { alert("Woohoo!");}} - */ - (options: UISlideoutOptions): void; - - /** - * Populates a slideout menu. - */ - populate(array: Object[]): void; -} - -interface UIStepperOptions { - start: number; - end: number; - defaultValue?: number; -} - -interface ChUIEventInterface { - eventStart: string; - eventEnd: string; - eventMove: string; - eventCancel: string; -} - -interface UIBusyOptions { - size?: string; - color?: string; - position?: string | boolean; - duration?: string; -} - -interface UIPopupOptions { - id?: string; - title?: string; - message?: string; - cancelButton?: string; - continueButton?: string; - callback?: Function; - empty?: boolean; -} - -interface UIPopoverOptions { - id?: string; - callback?: Function; - title?: string; -} - -interface UICreateSegmentedOptions { - id?: string; - className?: string; - labels?: string[]; - selected?: number -} - -interface UISegmentedOptions { - selected?: number; - callback?: Function; -} - -interface UIEditListOptions { - editLabel?: string; - doneLabel?: string; - deleteLabel?: string; - callback?: Function; - deletable?: boolean; - movable?: boolean; -} - -interface UISelectListOptions { - name?: string; - selected?: number; - callback?: Function; -} - -interface UISheetOptions { - id?: string; - listClass?: string; - background?: string; - handle?: boolean; -} - -interface UISlideoutOptions { - dynamic?: boolean; - callback?: Function; - position?: string; -} - - -/** - * The interface used to construct jQuery events (with $.Event). It is - * defined separately instead of inline in JQueryStatic to allow - * overriding the construction function with specific strings - * returning specific event objects. - */ -interface JQueryEventConstructor { - (name: string, eventProperties?: any): JQueryEventObject; - new (name: string, eventProperties?: any): JQueryEventObject; -} - -interface JQueryEventInterface { - Event: JQueryEventConstructor; -} - -/** - * Interface of the JQuery extension of the W3C event object - */ -interface BaseJQueryEventObject extends Event { - -} -interface JQueryEventObject extends BaseJQueryEventObject, JQueryInputEventObject, JQueryMouseEventObject, JQueryKeyEventObject { -} - -/** - * Interface of the JQuery extension of the W3C event object - */ -interface BaseJQueryEventObject extends Event { - -} - -interface JQueryInputEventObject extends BaseJQueryEventObject { - -} - -interface JQueryMouseEventObject extends JQueryInputEventObject { - -} - -interface JQueryKeyEventObject extends JQueryInputEventObject { - -} - -interface JQueryEventObject extends BaseJQueryEventObject, JQueryInputEventObject, JQueryMouseEventObject, JQueryKeyEventObject { -} - -/** - * Interface for detectors. - */ - interface ChuiDetectors { - /** * Whether device is iPhone. */ @@ -1180,21 +690,16 @@ interface JQueryEventObject extends BaseJQueryEventObject, JQueryInputEventObjec */ isStandalone: boolean; + /** + * Whether OS is iOS 6. + */ + isiOS6: boolean; + /** * Whether OS i iOS 7. */ isiOS7: boolean; - /** - * Whether OS i iOS 7. - */ - isiOS8: boolean; - - /** - * Whether OS i iOS 7. - */ - isiOS9: boolean; - /** * Whether OS is Windows. */ @@ -1258,4 +763,716 @@ interface JQueryEventObject extends BaseJQueryEventObject, JQueryInputEventObjec * Whether screen is at least 960 pixels wide and in portrait orientation. */ isWideScreenPortrait: boolean; - } \ No newline at end of file + + /** + * Return the version of the current browser. + */ + browserVersion(): number; + + /** + * Hide the navigation bar, raising up the content below it. + */ + UIHideNavBar(): void; + + /** + * If the navigation bar is hidden, show it, pushing down the content to make room. + */ + UIShowNavBar(): void; + + /** + * Determine whether navigation is in progress or not. + */ + isNavigating: boolean; + + /** + * Navigate to the article indicated by the provided destination ID. This enters the destination into the navigation history array. + * + * @param destination An id for the article to navigate to. + * @return void + */ + UIGoToArticle(destination: string): void; + + /** + * Go back to the previous article from whence you came. This resets the navigation history array. + * + * @return void + */ + UIGoBack(): void; + + /** + * Go back to the article indicated by the provided ID. This is for non-linear back navigation. This will reset the navigation history array to match the current state. + * + * @return void + */ + UIGoBackToArticle(articleID: string): void; + + /** + * Display a transparent screen over the UI. + * + * @param opacity The percentage of opacity for the screen. + * @return void + */ + UIBlock(opacity?: number): void; + + /** + * Remove the transparent screen covering the UI. + * + * @return void + */ + UIUnblock(): void; + + /** + * Create and show a Popup with title and message. Possible options: {id: "#myPopup", title: "My Popup", + * message: "Woohoo!", cancelButton: "Forget It!", contiueButton: "Whatever", callback: function() {console.log('Blah!');}, empty: false }. + * + * @param options UIPopupOptions + * @return void + */ + UIPopup(options?: { + id?: string; + title?: string; + message?: string; + cancelButton?: string; + continueButton?: string; + callback?: Function; + empty?: boolean; + }): void; + + /** + * Create and show a Popover. Options: {id: "#myPopover", title: "Whatever", callback: function() {console.log('Blah!');}}. + * + * @param options UIPopoverOptions + * @return void + */ + UIPopover(options?: { + id?: string; + callback?: Function; + title?: string; + }): void; + + /** + * Close any currently visible popovers. + * + * @return void + */ + UIPopoverClose(): void; + + /** + * Create a segmented control: {id: "mySegments", className: "seggie", labels: ["one", "two","three"], selected: 1} + * + * @param: options UICreateSegmentedOptions + * @return JQuery + */ + UICreateSegmented(options: { + id?: string; + className?: string; + labels?: string[]; + selected?: number + }): JQuery; + + /** + * Initialize a horiontal or vertical paging control. This uses a segmented control in the navigation bar with a class + * like "segmented paging horizontal" or "segmented paging vertical". It uses a single article with multiple sections to paginate. + * + * @return void + */ + UIPaging(): void; + + /** + * Creates a sheet. Minimum option is an id: {id : 'starTrek', listClass :'enterprise', background: 'transparent', handle: false } + * + * @return void + */ + UISheet(options: { + id: string; + listClass?: string; + background?: string; + handle?: boolean; + }): void; + + /** + * Show a sheet by passing this its ID. + * + * @return void + */ + UIShowSheet(id: string): void; + + /** + * Hide any currently displayed sheets. + * + * @return void + */ + UIHideSheet(): void; + + /** + * The body tag wrapped and ready to use: $.body.css('background-color','orange') + */ + body: JQuery; + + /** + * An array of the navigation history. Do not manipulate this. For examination only. This is used by navigation lists, etc. + */ + UINavigationHistory: string[]; + + /** + * Creates and initializes a slide out menu. Possible options: {dynamic: true, callback: function() { alert("Woohoo!");}} + */ + UISlideout: { + /** + * Creates and initializes a slide out menu. Possible options: {dynamic: true, callback: function() { alert("Woohoo!");}} + * + * @return void + */ + (options?: { + dynamic?: boolean; + callback?: (args?: any) => any; + }): any; + + /** + * Populates a slideout menu. + * + * @return void + */ + populate(array: Object[]): void; + }; + + /** + * Reset the value of the stepper to its defaults at initialization. Pass it a reference to the stepper to reset. + * + * @return void + */ + UIResetStepper(stepper: JQuery): void; + + /** + * Create a switch control. Possible options: { id: '#myId', name: 'fruit.mango', state: 'on', value: 'Mango', checked: 'on', style: 'traditional', callback: function() { alert('hi');}} + * + * @return void + */ + UICreateSwitch(options?: { + id?: string; + name?: string; + state?: string; + value?: string | number; + checked?: string; + style?: string; + callback?: () => any; + }): void; + + /** + * Creates a tabbar. On iOS this is at the bottom of the screen. On Android and Windows, it is at the top. + * Options: {id: 'mySpecialTabbar', tabs: 4, labels: ["Refresh", "Add", "Info", "Downloads", "Favorite"], icons: ["refresh", "add", "info", "downloads", "favorite"], selected: 2 } + * + * @return void + */ + UITabbar(options?: { + id?: string; + tabs: number; + labels: string[]; + icons?: string[]; + selected?: number; + }): void; + + /** + * Create a search bar for an article. Options: { articleId: '#products', id: 'productSearch', placeholder: 'Find a product', results: 5 } + * + * @return void + */ + UISearch(options?: { + articleId?: any; + id?: string; + placeholder?: string; + results?: number; + }): void; + + /** + * Create and initialize a swipable carousel. Options: {target : '#myCarousel', panels: ['

    stuff

    ','

    more

    '], loop: true, pagination: true } + * + * @return void + */ + UISetupCarousel(options: { + target: any; + panels: JQuery; + loop?: boolean; + pagination?: boolean; + }): void; + + /** + * Bind the values of data-models to elements with data-controllers:

    . + * You can bind a single model to its controller by providing its name as the argument: $.UIBindData('input-value'); + * + * @param controller A string indicating the controller whose value a model is bound to. + * @return void + */ + UIBindData(controller?: string): void; + + /** + * Unbind the values of data-models from their data-controllers. + * If you provide a controller name as the argument, only that controller will be unbound. + * + * @param controller A controller to unbind. + * @return void + */ + UIUnBindData(controller?: string): void; + +} + +/** + * Interface for jQuery + */ +interface JQuery { + + /** + * Iterate over an Array object, executing a function for each matched element. + * + * @param callback A function to execute while looping over an interable. This takes to arguments: ctx: HTMLElement and idx: number. + * @return JQuery + */ + forEach(callback: (ctx: HTMLElement, idx: number) => any): JQuery; + + /** + * Check the current matched set of elements against a selector or element and return it + * if it matches the given arguments. + * + * @param selector A string containing a selector expression to match elements against. + * @return JQuery + */ + iz(selector: string): JQuery; + + /** + * Check the current matched set of elements against a selector or element and return it + * if it matches the given arguments. + * + * @param elements One or more elements to match the current set of elements against. + * @return JQuery + */ + iz(element: any): JQuery; + + /** + * Check the current matched set of elements against a selector or element and return it + * if it does not match the given arguments. + * + * @param selector A string containing a selector expression to match elements against. + * @return JQuery + */ + iznt(selector: string): JQuery; + + /** + * Check the current matched set of elements against a selector or element and return it + * if it does not match the given arguments. + * + * @param elements One or more elements to match the current set of elements against. + * @return JQuery + */ + iznt(element: any): JQuery; + + /** + * Reduce the set of matched elements to those that have a descendant that matches the selector or DOM element. + * + * @param selector A string containing a selector expression to match elements against. + * @return JQuery + */ + haz(selector: string): JQuery; + /** + * Reduce the set of matched elements to those that have a descendant that matches the selector or DOM element. + * + * @param contained A DOM element to match elements against. + * @return JQuery + */ + haz(contained: HTMLElement): JQuery; + + /** + * Reduce the set of matched elements to those that have a descendant that does not match the selector or DOM element. + * + * @param selector A string containing a selector expression to match elements against. + * @return JQuery + */ + haznt(selector: string): JQuery; + /** + * Reduce the set of matched elements to those that have a descendant that does not match the selector or DOM element. + * + * @param contained A DOM element to match elements against. + * @return JQuery + */ + haznt(contained: HTMLElement): JQuery; + + /** + * Return any of the matched elements that have the given class. + * + * @param className The class name to search for. + * @return JQuery + */ + hazClass(className: string): JQuery; + + /** + * Return any of the matched elements that do not have the given class. + * + * @param className The class name to search for. + * @return JQuery + */ + hazntClass(className: string): JQuery; + + + /** + * Return any of the matched elements that have the given attribute. + * + * @param className The class name to search for. + * @return JQuery + */ + hazAttr(attributeName: string): JQuery; + + /** + * Return any of the matched elements that do not have the given attribute. + * + * @param className The class name to search for. + * @return JQuery + */ + hazntAttr(attributeName: string): JQuery; + + /** + * Center an element to the screen. + * + * @return void + */ + UICenter(): void; + + /** + * Display a busy indicator. Posible options: {size: "100px", color: "#ff0000", position: "align-flush", duration: "2s"}. + * + * @param size The size as a string with length identifier: "40px". + * @param color The color for the busy indicator: "#ff0000". + * @param position Optional positioning, such as "align-flush". + * @param duration The time for the busy indicator to display: "500ms". + * @return void + */ + UIBusy(options?: { + size?: string; + color?: string; + position?: string | boolean; + duration?: string; + }): void; + + /** + * Close the currently displayed Popup. This is executed on the popup: $('#myPopup').UIPopupClose(). + * + * @return void + */ + UIPopupClose(): void; + + /** + * Initialize a segmented control. Options: {selected: 2, callback: function() {console.log('Blah');}} + * + * @return void + */ + UISegmented(options?: { + selected?: number; + callback?: Function; + }): void; + + /** + * This method allows the user to use a segmented control to toggle a set of panels. It is executed on the segmented control. + * The options id is the contain of the panels. The options callback is to execute when the user toggles a panel. + * + * @return void + */ + UIPanelToggle(panelsContainer: string, callback: () => any): void; + + /** + * Make a list editable. This can be enabling changing the order of list items, or deleting them, or both. Options: {editLabel: "Edit", doneLabel: "Done", + * deleteLabel: "Delete", callback: function() {alert('Bye bye!');}, deletable: true, movable: true}. + * + * @return void + */ + UIEditList(options?: { + editLabel?: string; + doneLabel?: string; + deleteLabel?: string; + callback?: Function; + deletable?: boolean; + movable?: boolean; + }): void; + + /** + * Convert a simple list into a selection list. This converts the list into a radio button group, meaning only one can be selected at any time. + * You can name the radios buttons using the options name. Options: {name: "selectedNamesGroup", selected: 2, callback: function() {alert('hi');}} + * + * @return void + */ + UISelectList(options?: { + name?: string; + selected?: number; + callback?: Function; + }): void; + + /** + * Create a stepper control by executing it on a span with the class "stepper". Possible options: {start: 0, end: 10, defaultValue: 3}. + * + * @return void + */ + UIStepper(options: { + start: number; + end: number; + defaultValue: number; + }): void; + + /** + * Initialize any existing switch controls: $('.switch').UISwitch(); + * + * @return void + */ + UISwitch(): void; + + /** + * Execute this on a range control to initialize it. + * + * @return void + */ + UIRange(): void; + + + /** + * Attach a handler to an event for the elements. + * + * @param eventType A string containing one or more DOM event types, such as "click" or "submit," or custom event names. + * @param eventData An object containing data that will be passed to the event handler. + * @param handler A function to execute each time the event is triggered. + */ + bind(eventType: string | ChUIEventInterface, eventData: any, handler: (eventObject: JQueryEventObject) => any): JQuery; + /** + * Attach a handler to an event for the elements. + * + * @param eventType A string containing one or more DOM event types, such as "click" or "submit," or custom event names. + * @param handler A function to execute each time the event is triggered. + * @return JQuery + */ + bind(eventType: string | ChUIEventInterface, handler: (eventObject: JQueryEventObject) => any): JQuery; + /** + * Attach a handler to an event for the elements. + * + * @param eventType A string containing one or more DOM event types, such as "click" or "submit," or custom event names. + * @param eventData An object containing data that will be passed to the event handler. + * @param preventBubble Setting the third argument to false will attach a function that prevents the default action from occurring and stops the event from bubbling. The default is true. + * @return JQuery + */ + bind(eventType: string | ChUIEventInterface, eventData: any, preventBubble: boolean): JQuery; + /** + * Attach a handler to an event for the elements. + * + * @param eventType A string containing one or more DOM event types, such as "click" or "submit," or custom event names. + * @param preventBubble Setting the third argument to false will attach a function that prevents the default action from occurring and stops the event from bubbling. The default is true. + * @return JQuery + */ + bind(eventType: string | ChUIEventInterface, preventBubble: boolean): JQuery; + + + delegate(selector: any, eventType: string | ChUIEventInterface, handler: (eventObject: JQueryEventObject) => any): JQuery; + delegate(selector: any, eventType: string | ChUIEventInterface, eventData: any, handler: (eventObject: JQueryEventObject) => any): JQuery; + + /** + * Remove an event handler. + * + * @param events One or more space-separated event types and optional namespaces, or just namespaces, such as "click", "keydown.myPlugin", or ".myPlugin". + * @param selector A selector which should match the one originally passed to .on() when attaching event handlers. + * @param handler A handler function previously attached for the event(s), or the special value false. + * @return JQuery + */ + off(events: string | ChUIEventInterface, selector?: string, handler?: (eventObject: JQueryEventObject) => any): JQuery; + /** + * Remove an event handler. + * + * @param events One or more space-separated event types and optional namespaces, or just namespaces, such as "click", "keydown.myPlugin", or ".myPlugin". + * @param handler A handler function previously attached for the event(s), or the special value false. + * @return JQuery + */ + off(events: string | ChUIEventInterface, handler: (eventObject: JQueryEventObject) => any): JQuery; + + /** + * Attach an event handler function for one or more events to the selected elements. + * + * @param events One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". + * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. Rest parameter args is for optional parameters passed to jQuery.trigger(). Note that the actual parameters on the event handler function must be marked as optional (? syntax). + * @return JQuery + */ + on(events: string | ChUIEventInterface, handler: (eventObject: JQueryEventObject, ...args: any[]) => any): JQuery; + /** + * Attach an event handler function for one or more events to the selected elements. + * + * @param events One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". + * @param data Data to be passed to the handler in event.data when an event is triggered. + * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. + * @return JQuery + */ + on(events: string | ChUIEventInterface, data : any, handler: (eventObject: JQueryEventObject, ...args: any[]) => any): JQuery; + /** + * Attach an event handler function for one or more events to the selected elements. + * + * @param events One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". + * @param selector A selector string to filter the descendants of the selected elements that trigger the event. If the selector is null or omitted, the event is always triggered when it reaches the selected element. + * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. + * @return JQuery + */ + on(events: string | ChUIEventInterface, selector: string, handler: (eventObject: JQueryEventObject, ...eventData: any[]) => any): JQuery; + /** + * Attach an event handler function for one or more events to the selected elements. + * + * @param events One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". + * @param selector A selector string to filter the descendants of the selected elements that trigger the event. If the selector is null or omitted, the event is always triggered when it reaches the selected element. + * @param data Data to be passed to the handler in event.data when an event is triggered. + * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. + * @return JQuery + */ + on(events: string | ChUIEventInterface, selector: string, data: any, handler: (eventObject: JQueryEventObject, ...eventData: any[]) => any): JQuery; + + /** + * Attach a handler to an event for the elements. The handler is executed at most once per element per event type. + * + * @param events A string containing one or more JavaScript event types, such as "click" or "submit," or custom event names. + * @param handler A function to execute at the time the event is triggered. + * @return JQuery + */ + one(events: string | ChUIEventInterface, handler: (eventObject: JQueryEventObject) => any): JQuery; + /** + * Attach a handler to an event for the elements. The handler is executed at most once per element per event type. + * + * @param events A string containing one or more JavaScript event types, such as "click" or "submit," or custom event names. + * @param data An object containing data that will be passed to the event handler. + * @param handler A function to execute at the time the event is triggered. + * @return JQuery + */ + one(events: string | ChUIEventInterface, data: Object, handler: (eventObject: JQueryEventObject) => any): JQuery; + + /** + * Attach a handler to an event for the elements. The handler is executed at most once per element per event type. + * + * @param events One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". + * @param selector A selector string to filter the descendants of the selected elements that trigger the event. If the selector is null or omitted, the event is always triggered when it reaches the selected element. + * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. + * @return JQuery + */ + one(events: string | ChUIEventInterface, selector: string, handler: (eventObject: JQueryEventObject) => any): JQuery; + /** + * Attach a handler to an event for the elements. The handler is executed at most once per element per event type. + * + * @param events One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". + * @param selector A selector string to filter the descendants of the selected elements that trigger the event. If the selector is null or omitted, the event is always triggered when it reaches the selected element. + * @param data Data to be passed to the handler in event.data when an event is triggered. + * @param handler A function to execute when the event is triggered. The value false is also allowed as a shorthand for a function that simply does return false. + * @return JQuery + */ + one(events: string | ChUIEventInterface, selector: string, data: any, handler: (eventObject: JQueryEventObject) => any): JQuery; + + /** + * Execute all handlers and behaviors attached to the matched elements for the given event type. + * + * @param eventType A string containing a JavaScript event type, such as click or submit. + * @param extraParameters Additional parameters to pass along to the event handler. + * @return JQuery + */ + trigger(eventType: string | ChUIEventInterface, extraParameters?: any[]|Object): JQuery; + + /** + * Execute all handlers attached to an element for an event. + * + * @param eventType A string containing a JavaScript event type, such as click or submit. + * @param extraParameters An array of additional parameters to pass along to the event handler. + * @return Object + */ + triggerHandler(eventType: string | ChUIEventInterface, ...extraParameters: any[]): Object; + + /** + * Remove a previously-attached event handler from the elements. + * + * @param eventType A string containing a JavaScript event type, such as click or submit. + * @param handler The function that is to be no longer executed. + * @return JQuery + */ + unbind(eventType?: string | ChUIEventInterface, handler?: (eventObject: JQueryEventObject) => any): JQuery; + /** + * Remove a previously-attached event handler from the elements. + * + * @param eventType A string containing a JavaScript event type, such as click or submit. + * @param fls Unbinds the corresponding 'return false' function that was bound using .bind( eventType, false ). + * @return JQuery + */ + unbind(eventType: string | ChUIEventInterface, fls: boolean): JQuery; + + /** + * Remove a handler from the event for all elements which match the current selector, based upon a specific set of root elements. + * + * @param selector A selector which will be used to filter the event results. + * @param eventType A string containing a JavaScript event type, such as "click" or "keydown" + * @param handler A function to execute at the time the event is triggered. + * @return JQuery + */ + undelegate(selector: string | ChUIEventInterface, eventType: string, handler?: (eventObject: JQueryEventObject) => any): JQuery; + /** + * Remove a handler from the event for all elements which match the current selector, based upon a specific set of root elements. + * + * @param selector A selector which will be used to filter the event results. + * @param events An object of one or more event types and previously bound functions to unbind from them. + * @return JQuery + */ + undelegate(selector: string | ChUIEventInterface, events: Object): JQuery; +} + +interface ChUIEventInterface { + eventStart: string; + eventEnd: string; + eventMove: string; + eventCancel: string; + tap: string; + singletap: string; + doubletap: string; + longtap: string; + swipe: string; + swipeleft: string; + swiperight: string; + swipeup: string; + swipedown: string; +} + + +/** + * The interface used to construct jQuery events (with $.Event). It is + * defined separately instead of inline in JQueryStatic to allow + * overriding the construction function with specific strings + * returning specific event objects. + */ +interface JQueryEventConstructor { + (name: string, eventProperties?: any): JQueryEventObject; + new (name: string, eventProperties?: any): JQueryEventObject; +} + +interface JQueryEventInterface { + Event: JQueryEventConstructor; +} + +/** + * Interface of the JQuery extension of the W3C event object + */ +interface BaseJQueryEventObject extends Event { + +} +interface JQueryEventObject extends BaseJQueryEventObject, JQueryInputEventObject, JQueryMouseEventObject, JQueryKeyEventObject { +} + +/** + * Interface of the JQuery extension of the W3C event object + */ +interface BaseJQueryEventObject extends Event { + +} + +interface JQueryInputEventObject extends BaseJQueryEventObject { + +} + +interface JQueryMouseEventObject extends JQueryInputEventObject { + +} + +interface JQueryKeyEventObject extends JQueryInputEventObject { + +} + +interface JQueryEventObject extends BaseJQueryEventObject, JQueryInputEventObject, JQueryMouseEventObject, JQueryKeyEventObject { +} \ No newline at end of file diff --git a/cordova/plugins/Contacts.d.ts b/cordova/plugins/Contacts.d.ts index 29a9a596cf..275e8f2fd0 100644 --- a/cordova/plugins/Contacts.d.ts +++ b/cordova/plugins/Contacts.d.ts @@ -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. diff --git a/cors/cors-tests.ts b/cors/cors-tests.ts new file mode 100644 index 0000000000..a3f5ea10e1 --- /dev/null +++ b/cors/cors-tests.ts @@ -0,0 +1,11 @@ +/// + +import express = require('express'); +import cors = require('cors'); + +var app = express(); +app.use(cors()); +app.use(cors({ + maxAge: 100, + credentials: true +})); diff --git a/cors/cors.d.ts b/cors/cors.d.ts new file mode 100644 index 0000000000..92fdd9634e --- /dev/null +++ b/cors/cors.d.ts @@ -0,0 +1,24 @@ +// Type definitions for cors +// Project: https://github.com/troygoode/node-cors/ +// Definitions by: Mihhail Lapushkin +// Definitions: https://github.com/borisyankov/DefinitelyTyped + +/// + +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; +} \ No newline at end of file diff --git a/d3/d3.d.ts b/d3/d3.d.ts index 2b6caeddfb..ef3909e9fc 100644 --- a/d3/d3.d.ts +++ b/d3/d3.d.ts @@ -830,7 +830,7 @@ declare module d3 { style(name: string, value: (datum: Datum, index: number, outerIndex: number) => Primitive, priority?: string): Transition; style(obj: { [key: string]: Primitive | ((datum: Datum, index: number, outerIndex: number) => Primitive) }, priority?: string): Transition; - styleTween(name: string, tween: (datum: Datum, index: number, attr: string) => Primitive, priority?: string): Transition; + styleTween(name: string, tween: (datum: Datum, index: number, attr: string) => (t: number) => Primitive, priority?: string): Transition; text(value: Primitive): Transition; text(value: (datum: Datum, index: number, outerIndex: number) => Primitive): Transition; diff --git a/diff-match-patch/diff-match-patch-tests.ts b/diff-match-patch/diff-match-patch-tests.ts new file mode 100644 index 0000000000..f1e5d2d42e --- /dev/null +++ b/diff-match-patch/diff-match-patch-tests.ts @@ -0,0 +1,32 @@ +/// + +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; +}); diff --git a/diff-match-patch/diff-match-patch.d.ts b/diff-match-patch/diff-match-patch.d.ts new file mode 100644 index 0000000000..63bf7eaa07 --- /dev/null +++ b/diff-match-patch/diff-match-patch.d.ts @@ -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 +// 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; +} diff --git a/firebase-client/firebase-client-tests.ts b/firebase-client/firebase-client-tests.ts new file mode 100644 index 0000000000..bc4ef06a8e --- /dev/null +++ b/firebase-client/firebase-client-tests.ts @@ -0,0 +1,50 @@ +/// + +//Class definitions for type safety +class Name{ + first:string; + last:string; +} + +class User{ + name:Name; +} + +//Connect to service +var client = new FirebaseClient({ + url : "https://fb-client-test.firebaseio.com/", + auth : null +}); + +var newUser:User = new User(); +newUser.name = { + first: "Fred", + last: "Flinstone" +}; + +client.push("users", newUser) + .then(function (result){ + console.log(result.name); + var newUser2:User = new User(); + newUser2.name = { + first: "Fred", + last: "Rockington" + } + return client.update("users/" + result.name, newUser2); + }).then(function (result){ + console.log(result.name.last); + var newUser3:User = new User(); + newUser3.name = { + first: "Axe", + last: "Steel" + }; + return client.set("users/AXESTEEL", newUser3); + }).then(function (result){ + console.log(result.name.first); + return client.get(); + }).then(function (result){ + console.log(result); + return client.get("users/AXESTEEL") + }).then(function (result){ + console.log(result.name.first); + }); \ No newline at end of file diff --git a/firebase-client/firebase-client.d.ts b/firebase-client/firebase-client.d.ts new file mode 100644 index 0000000000..15839deee4 --- /dev/null +++ b/firebase-client/firebase-client.d.ts @@ -0,0 +1,75 @@ +// Type definitions for Firebase Client 0.1.0 +// Project: https://www.github.com/jpstevens/firebase-client +// Definitions by: Andrew Breen +// Definitions: https://github.com/borisyankov/DefinitelyTyped +/// + +interface PushResponse { + /** + * Name ref (key) of the child resource + */ + name : string; +} + +interface FirebaseConfig { + /** + * path for the Firebase instance + */ + url : string; + + /** + * Token for authorisation + */ + auth: string; +} + +interface FirebaseClient { + /** + * Creates a new FirebaseClient given the provided configuration + */ + new (config : FirebaseConfig) : FirebaseClient; + + /** + * Retrieves all objects at the base path + */ + get() : Q.Promise; + + /** + * Retrieves an object + * @param path Relative path from the base for the resource + */ + get(path : string) : Q.Promise; + + /** + * Returns a promise of the HTTP response from setting the value at the given path + * @param path Relative path from the base for the resource + * @param data Data to be set as the value for the given path + */ + set(path : string, data : T) : Q.Promise; + + /** + * Update a node at a given path + * @param path Relative path from the base for the resource + * @param value Value of the response + */ + update(path : string, value : T) : Q.Promise; + + /** + * Deletes the resource at a given path + * @param path Relative path from the base for the resource + */ + delete(path : string) : Q.Promise; + + /** + * @param path Relative path from the base for the resource + * @param value Object to push to the path + */ + push(path : string, value : T) : Q.Promise; +} + +declare var FirebaseClient: FirebaseClient; + +declare module 'firebase-client' { + export = FirebaseClient; +} + diff --git a/iso8601-localizer/iso8601-localizer-tests.ts b/iso8601-localizer/iso8601-localizer-tests.ts index 592799388d..d532d7af01 100644 --- a/iso8601-localizer/iso8601-localizer-tests.ts +++ b/iso8601-localizer/iso8601-localizer-tests.ts @@ -3,3 +3,5 @@ new ISO8601Localizer('2015-06-02T14:13:12').localize(); new ISO8601Localizer('2015-06-02T14:13:12').to(-5).localize(); + +new ISO8601Localizer('2015-06-02T14:13:12').to(-5).returnAs('object').localize(); diff --git a/iso8601-localizer/iso8601-localizer.d.ts b/iso8601-localizer/iso8601-localizer.d.ts index 0fdc1b4cb6..7d7c526261 100644 --- a/iso8601-localizer/iso8601-localizer.d.ts +++ b/iso8601-localizer/iso8601-localizer.d.ts @@ -1,15 +1,17 @@ -// Type definitions for ISO8601-Localizer v1.0.5 +// Type definitions for ISO8601-Localizer v1.2.0 // Project: https://github.com/avielfedida/ISO8601-Localizer // Definitions by: Aviel Fedida // Definitions: https://github.com/borisyankov/DefinitelyTyped interface localizer { to(offset: number): localizer, + returnAs(as: string): localizer; localize(): string; } declare class ISO8601Localizer implements localizer { constructor(userISO8601: string); to(offset: number): localizer; + returnAs(as: string): localizer; localize(): string; } diff --git a/lodash/lodash-tests.ts b/lodash/lodash-tests.ts index d36b5dfc4e..d7d4b6f71a 100644 --- a/lodash/lodash-tests.ts +++ b/lodash/lodash-tests.ts @@ -121,11 +121,11 @@ result = <_.LoDashObjectWrapper<_.Dictionary>>_(<{ [index: string]: stri //Wrapped array shortcut methods result = <_.LoDashArrayWrapper>_([1, 2, 3, 4]).concat(5, 6); -result = <_.LoDashWrapper>_([1, 2, 3, 4]).join(','); -result = <_.LoDashWrapper>_([1, 2, 3, 4]).pop(); +result = _([1, 2, 3, 4]).join(','); +result = _([1, 2, 3, 4]).pop(); _([1, 2, 3, 4]).push(5, 6, 7); result = <_.LoDashArrayWrapper>_([1, 2, 3, 4]).reverse(); -result = <_.LoDashWrapper>_([1, 2, 3, 4]).shift(); +result = _([1, 2, 3, 4]).shift(); result = <_.LoDashArrayWrapper>_([1, 2, 3, 4]).slice(1, 2); result = <_.LoDashArrayWrapper>_([1, 2, 3, 4]).slice(2); result = <_.LoDashArrayWrapper>_([1, 2, 3, 4]).sort((a, b) => 1); @@ -1060,6 +1060,15 @@ result = _(1).gte(2); result = _([]).gte(2); result = _({}).gte(2); +// _.isMatch +var testIsMatchCustiomizerFn: (value: any, other: any, indexOrKey: number|string) => boolean; +result = _.isMatch({}, {}); +result = _.isMatch({}, {}, testIsMatchCustiomizerFn); +result = _.isMatch({}, {}, testIsMatchCustiomizerFn, {}); +result = _({}).isMatch({}); +result = _({}).isMatch({}, testIsMatchCustiomizerFn); +result = _({}).isMatch({}, testIsMatchCustiomizerFn, {}); + // _.lt result = _.lt(1, 2); result = _(1).lt(2); @@ -1086,6 +1095,14 @@ result = _([1]).toPlainObject(); result = _([]).toPlainObject(); result = _({}).toPlainObject(); +/******** + * Math * + ********/ + +// _.add +result = _.add(1, 1); +result = _(1).add(1); + /********** * Objects * ***********/ @@ -1113,6 +1130,25 @@ result = <_.LoDashObjectWrapper>_({ 'name': 'moe' }).extend({ 'age': 40 return typeof a == 'undefined' ? b : a; }); +// _.create +interface TestCreateProto { + a: number; +} +interface TestCreateProps { + b: string; +} +interface TestCreateTResult extends TestCreateProto, TestCreateProps {} +var testCreateProto: TestCreateProto; +var testCreateProps: TestCreateProps; +result = <{}>_.create(testCreateProto); +result = <{}>_.create(testCreateProto, testCreateProps); +result = _.create(testCreateProto); +result = _.create(testCreateProto, testCreateProps); +result = <{}>_(testCreateProto).create().value(); +result = <{}>_(testCreateProto).create(testCreateProps).value(); +result = _(testCreateProto).create().value(); +result = _(testCreateProto).create(testCreateProps).value(); + result = _.clone(stoogesAges); result = _.clone(stoogesAges, true); result = _.clone(stoogesAges, true, function (value) { @@ -1439,6 +1475,17 @@ result = _.result(object, 'stuff'); var tempObject = {}; result = _.runInContext(tempObject); +// _.propertyOf +interface TestPropertyOfObject { + a: { + b: number[]; + } +} +var testPropertyOfObject: TestPropertyOfObject; +result = <(path: string|string[]) => any>_.propertyOf({}); +result = <(path: string|string[]) => any>_.propertyOf(testPropertyOfObject); +result = <(path: string|string[]) => any>_({}).propertyOf().value(); + result = <_.TemplateExecutor>_.template('hello <%= name %>'); result = _.template('<%- value %>', { 'value': '